reset upstream subtrees to yocto 2.6

Reset the following subtrees on thud HEAD:

  poky: 87e3a9739d
  meta-openembedded: 6094ae18c8
  meta-security: 31dc4e7532
  meta-raspberrypi: a48743dc36
  meta-xilinx: c42016e2e6

Also re-apply backports that didn't make it into thud:
  poky:
    17726d0 systemd-systemctl-native: handle Install wildcards

  meta-openembedded:
    4321a5d libtinyxml2: update to 7.0.1
    042f0a3 libcereal: Add native and nativesdk classes
    e23284f libcereal: Allow empty package
    030e8d4 rsyslog: curl-less build with fmhttp PACKAGECONFIG
    179a1b9 gtest: update to 1.8.1

Squashed OpenBMC subtree compatibility updates:
  meta-aspeed:
    Brad Bishop (1):
          aspeed: add yocto 2.6 compatibility

  meta-ibm:
    Brad Bishop (1):
          ibm: prepare for yocto 2.6

  meta-ingrasys:
    Brad Bishop (1):
          ingrasys: set layer compatibility to yocto 2.6

  meta-openpower:
    Brad Bishop (1):
          openpower: set layer compatibility to yocto 2.6

  meta-phosphor:
    Brad Bishop (3):
          phosphor: set layer compatibility to thud
          phosphor: libgpg-error: drop patches
          phosphor: react to fitimage artifact rename

    Ed Tanous (4):
          Dropbear: upgrade options for latest upgrade
          yocto2.6: update openssl options
          busybox: remove upstream watchdog patch
          systemd: Rebase CONFIG_CGROUP_BPF patch

Change-Id: I7b1fe71cca880d0372a82d94b5fd785323e3a9e7
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
diff --git a/meta-aspeed/conf/layer.conf b/meta-aspeed/conf/layer.conf
index dcd420b..98fd9e9 100644
--- a/meta-aspeed/conf/layer.conf
+++ b/meta-aspeed/conf/layer.conf
@@ -7,6 +7,6 @@
 BBFILE_COLLECTIONS += "aspeed-layer"
 BBFILE_PATTERN_aspeed-layer = ""
 LAYERVERSION_aspeed-layer = "1"
-LAYERSERIES_COMPAT_aspeed-layer = "sumo"
+LAYERSERIES_COMPAT_aspeed-layer = "sumo thud"
 
 ASPEEDBASE = '${@os.path.normpath("${LAYERDIR}/")}'
diff --git a/meta-ibm/conf/layer.conf b/meta-ibm/conf/layer.conf
index 434f616..fd05fc4 100644
--- a/meta-ibm/conf/layer.conf
+++ b/meta-ibm/conf/layer.conf
@@ -7,7 +7,7 @@
 
 BBFILE_COLLECTIONS += "ibm-layer"
 BBFILE_PATTERN_ibm-layer = ""
-LAYERSERIES_COMPAT_ibm-layer = "sumo"
+LAYERSERIES_COMPAT_ibm-layer = "thud"
 
 # Provide a variable that points the base of the ibm layer.
 IBMBASE = '${@os.path.normpath("${LAYERDIR}/")}'
diff --git a/meta-ibm/meta-palmetto/conf/layer.conf b/meta-ibm/meta-palmetto/conf/layer.conf
index 58de44f..61c7538 100644
--- a/meta-ibm/meta-palmetto/conf/layer.conf
+++ b/meta-ibm/meta-palmetto/conf/layer.conf
@@ -7,4 +7,4 @@
 
 BBFILE_COLLECTIONS += "palmetto-layer"
 BBFILE_PATTERN_palmetto-layer = ""
-LAYERSERIES_COMPAT_palmetto-layer = "sumo"
+LAYERSERIES_COMPAT_palmetto-layer = "thud"
diff --git a/meta-ibm/meta-romulus/conf/layer.conf b/meta-ibm/meta-romulus/conf/layer.conf
index fa58c44..d1eb838 100644
--- a/meta-ibm/meta-romulus/conf/layer.conf
+++ b/meta-ibm/meta-romulus/conf/layer.conf
@@ -7,4 +7,4 @@
 
 BBFILE_COLLECTIONS += "romulus-layer"
 BBFILE_PATTERN_romulus-layer = ""
-LAYERSERIES_COMPAT_romulus-layer = "sumo"
+LAYERSERIES_COMPAT_romulus-layer = "thud"
diff --git a/meta-ibm/meta-witherspoon/conf/layer.conf b/meta-ibm/meta-witherspoon/conf/layer.conf
index 7ace31d..7dd1f0b 100644
--- a/meta-ibm/meta-witherspoon/conf/layer.conf
+++ b/meta-ibm/meta-witherspoon/conf/layer.conf
@@ -7,4 +7,4 @@
 
 BBFILE_COLLECTIONS += "witherspoon-layer"
 BBFILE_PATTERN_witherspoon-layer = ""
-LAYERSERIES_COMPAT_witherspoon-layer = "sumo"
+LAYERSERIES_COMPAT_witherspoon-layer = "thud"
diff --git a/meta-ibm/recipes-httpd/nginx/nginx_%.bbappend b/meta-ibm/recipes-httpd/nginx/nginx_%.bbappend
index 7acc986..ee5ffd5 100644
--- a/meta-ibm/recipes-httpd/nginx/nginx_%.bbappend
+++ b/meta-ibm/recipes-httpd/nginx/nginx_%.bbappend
@@ -10,7 +10,7 @@
     "
 
 RDEPENDS_${PN} += " \
-        openssl \
+        openssl-bin \
         ${VIRTUAL-RUNTIME_base-utils} \
         "
 
diff --git a/meta-ingrasys/conf/layer.conf b/meta-ingrasys/conf/layer.conf
index 05c40a9..eaa0582 100644
--- a/meta-ingrasys/conf/layer.conf
+++ b/meta-ingrasys/conf/layer.conf
@@ -3,7 +3,7 @@
 
 BBFILE_COLLECTIONS += "ingrasys"
 BBFILE_PATTERN_ingrasys = ""
-LAYERSERIES_COMPAT_ingrasys = "sumo"
+LAYERSERIES_COMPAT_ingrasys = "thud"
 
 # Provide a variable that points the base of the ingrasys layer.
 INGRASYSBASE = '${@os.path.normpath("${LAYERDIR}/")}'
diff --git a/meta-ingrasys/meta-zaius/conf/layer.conf b/meta-ingrasys/meta-zaius/conf/layer.conf
index 7467aa5..d57aea0 100644
--- a/meta-ingrasys/meta-zaius/conf/layer.conf
+++ b/meta-ingrasys/meta-zaius/conf/layer.conf
@@ -7,4 +7,4 @@
 
 BBFILE_COLLECTIONS += "zaius"
 BBFILE_PATTERN_zaius = ""
-LAYERSERIES_COMPAT_zaius = "sumo"
+LAYERSERIES_COMPAT_zaius = "thud"
diff --git a/meta-openembedded/README b/meta-openembedded/README
index 204966a..a716801 100644
--- a/meta-openembedded/README
+++ b/meta-openembedded/README
@@ -1,4 +1,7 @@
 Collection of layers for the OE-core universe
 
-Please see the respective READMEs in the layer subdirectories
+Thud maintainer: Armin Kuster  <akuster808@gmail.com>
 
+This repository is a collection of layers to suppliment OE-Core
+with additional packages, Each layer have designated maintainer
+Please see the respective READMEs in the layer subdirectories
diff --git a/meta-openembedded/meta-filesystems/README b/meta-openembedded/meta-filesystems/README
index 97d0e94..ac0035a 100644
--- a/meta-openembedded/meta-filesystems/README
+++ b/meta-openembedded/meta-filesystems/README
@@ -10,30 +10,30 @@
 This layer depends on:
 
   URI: git://git.openembedded.org/bitbake
-  branch: master
+  branch: 1.40
 
   URI: git://git.openembedded.org/openembedded-core
   layers: meta
-  branch: master
+  branch: thud
 
   URI: git://git.openembedded.org/meta-openembedded
   layers: meta-oe
-  branch: master
+  branch: thud
 
 Patches
 =======
 
 Please submit any patches against the filesystems layer to the
 OpenEmbedded development mailing list (openembedded-devel@lists.openembedded.org)
-with '[meta-filesystems]' in the subject.
+with '[meta-filesystems][thud]' in the subject.
 
-Layer maintainer: Armin Kuster <akuster808@gmail.com>
+Thud maintainer: Armin Kuster <akuster808@gmail.com>
 
 When sending single patches, please use something like:
 
    git send-email -1 -M \
         --to openembedded-devel@lists.openembedded.org \
-        --subject-prefix=meta-filesystems][PATCH
+        --subject-prefix=meta-filesystems][thud][PATCH
 
 
 Table of Contents
diff --git a/meta-openembedded/meta-filesystems/conf/layer.conf b/meta-openembedded/meta-filesystems/conf/layer.conf
index dbcff42..002f099 100644
--- a/meta-openembedded/meta-filesystems/conf/layer.conf
+++ b/meta-openembedded/meta-filesystems/conf/layer.conf
@@ -15,4 +15,4 @@
 
 LAYERDEPENDS_filesystems-layer = "core openembedded-layer"
 
-LAYERSERIES_COMPAT_filesystems-layer = "sumo"
+LAYERSERIES_COMPAT_filesystems-layer = "thud"
diff --git a/meta-openembedded/meta-filesystems/recipes-filesystems/logfsprogs/logfsprogs/0001-include-sys-sysmacros.h-for-major-minor-definition.patch b/meta-openembedded/meta-filesystems/recipes-filesystems/logfsprogs/logfsprogs/0001-include-sys-sysmacros.h-for-major-minor-definition.patch
new file mode 100644
index 0000000..86bb0b5
--- /dev/null
+++ b/meta-openembedded/meta-filesystems/recipes-filesystems/logfsprogs/logfsprogs/0001-include-sys-sysmacros.h-for-major-minor-definition.patch
@@ -0,0 +1,24 @@
+From 3b02acbb3d5bc93422a6821ce47568633ef4ae5e Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 11 Aug 2018 15:09:24 -0700
+Subject: [PATCH] include sys/sysmacros.h for major/minor definition
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ mkfs.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/mkfs.c b/mkfs.c
+index e612cbd..b6aa63d 100644
+--- a/mkfs.c
++++ b/mkfs.c
+@@ -21,6 +21,7 @@
+ #include <sys/ioctl.h>
+ #include <sys/stat.h>
+ #include <sys/types.h>
++#include <sys/sysmacros.h>
+ #define __USE_UNIX98
+ #include <unistd.h>
+ #include <zlib.h>
diff --git a/meta-openembedded/meta-filesystems/recipes-filesystems/logfsprogs/logfsprogs_git.bb b/meta-openembedded/meta-filesystems/recipes-filesystems/logfsprogs/logfsprogs_git.bb
index 1b4d97d..d9864ac 100644
--- a/meta-openembedded/meta-filesystems/recipes-filesystems/logfsprogs/logfsprogs_git.bb
+++ b/meta-openembedded/meta-filesystems/recipes-filesystems/logfsprogs/logfsprogs_git.bb
@@ -14,6 +14,7 @@
 SRC_URI = "git://github.com/prasad-joshi/logfsprogs.git \
            file://0001-Add-LDFLAGS-to-linker-cmdline.patch \
            file://0001-btree-Avoid-conflicts-with-libc-namespace-about-setk.patch \
+           file://0001-include-sys-sysmacros.h-for-major-minor-definition.patch \
            "
 SRCREV = "45b72c81ce3c6fa17ca19bafc207ea93e76312f4"
 
diff --git a/meta-openembedded/meta-filesystems/recipes-filesystems/ntfs-3g-ntfsprogs/ntfs-3g-ntfsprogs_2017.3.23.bb b/meta-openembedded/meta-filesystems/recipes-filesystems/ntfs-3g-ntfsprogs/ntfs-3g-ntfsprogs_2017.3.23.bb
index 9e77766..addb4d3 100644
--- a/meta-openembedded/meta-filesystems/recipes-filesystems/ntfs-3g-ntfsprogs/ntfs-3g-ntfsprogs_2017.3.23.bb
+++ b/meta-openembedded/meta-filesystems/recipes-filesystems/ntfs-3g-ntfsprogs/ntfs-3g-ntfsprogs_2017.3.23.bb
@@ -13,6 +13,9 @@
 SRC_URI[md5sum] = "d97474ae1954f772c6d2fa386a6f462c"
 SRC_URI[sha256sum] = "3e5a021d7b761261836dcb305370af299793eedbded731df3d6943802e1262d5"
 
+UPSTREAM_CHECK_URI = "https://www.tuxera.com/community/open-source-ntfs-3g/"
+UPSTREAM_CHECK_REGEX = "ntfs-3g_ntfsprogs-(?P<pver>\d+(\.\d+)+)\.tgz"
+
 inherit autotools pkgconfig
 
 PACKAGECONFIG ??= ""
diff --git a/meta-openembedded/meta-filesystems/recipes-filesystems/owfs/owfs/0001-include-sys-sysmacros.h-for-major.patch b/meta-openembedded/meta-filesystems/recipes-filesystems/owfs/owfs/0001-include-sys-sysmacros.h-for-major.patch
new file mode 100644
index 0000000..0a990ac
--- /dev/null
+++ b/meta-openembedded/meta-filesystems/recipes-filesystems/owfs/owfs/0001-include-sys-sysmacros.h-for-major.patch
@@ -0,0 +1,46 @@
+From dd1af7541f18399bcdcb129a8b6618c18ebd9d63 Mon Sep 17 00:00:00 2001
+From: Tomasz Torcz <tomek@pipebreaker.pl>
+Date: Sat, 17 Mar 2018 12:56:04 +0100
+Subject: [PATCH] include <sys/sysmacros.h> for major()
+
+  Linux glibc ceased to include it in sys/types.h:
+https://sourceware.org/ml/libc-alpha/2015-11/msg00253.html
+
+Upstream-Status: Backport
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ configure.ac                  | 2 +-
+ module/owlib/src/include/ow.h | 6 +++++-
+ 2 files changed, 6 insertions(+), 2 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 86751bf7..d625d3f0 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -180,7 +180,7 @@ m4_include([src/scripts/m4/acx_pthread.m4])
+ # Checks for header files.
+ AC_HEADER_DIRENT
+ AC_HEADER_STDC
+-AC_CHECK_HEADERS([asm/types.h arpa/inet.h sys/ioctl.h sys/mkdev.h sys/socket.h sys/time.h sys/times.h sys/types.h sys/param.h sys/uio.h feature_tests.h fcntl.h netinet/in.h stdlib.h string.h strings.h sys/file.h syslog.h termios.h unistd.h limits.h stdint.h features.h getopt.h resolv.h semaphore.h])
++AC_CHECK_HEADERS([asm/types.h arpa/inet.h sys/ioctl.h sys/mkdev.h sys/socket.h sys/sysmacros.h sys/time.h sys/times.h sys/types.h sys/param.h sys/uio.h feature_tests.h fcntl.h netinet/in.h stdlib.h string.h strings.h sys/file.h syslog.h termios.h unistd.h limits.h stdint.h features.h getopt.h resolv.h semaphore.h])
+ AC_CHECK_HEADERS([linux/limits.h linux/types.h netdb.h dlfcn.h])
+ AC_CHECK_HEADERS(sys/event.h sys/inotify.h)
+ 
+diff --git a/module/owlib/src/include/ow.h b/module/owlib/src/include/ow.h
+index 9dbec5f3..0a310552 100644
+--- a/module/owlib/src/include/ow.h
++++ b/module/owlib/src/include/ow.h
+@@ -188,8 +188,12 @@
+ #include <netdb.h>				/* for getaddrinfo */
+ #endif							/* HAVE_NETDB_H */
+ 
++#ifdef HAVE_SYS_SYSMACROS_H
++#include <sys/sysmacros.h>			/* for major() */
++#endif							/* HAVE_SYS_SYSMACROS_H */
++
+ #ifdef HAVE_SYS_MKDEV_H
+-#include <sys/mkdev.h>			/* for major() */
++#include <sys/mkdev.h>			/* for major() on Solaris */
+ #endif							/* HAVE_SYS_MKDEV_H */
+ 
+ #include <stddef.h> // for offsetof()
diff --git a/meta-openembedded/meta-filesystems/recipes-filesystems/owfs/owfs_2.9p1.bb b/meta-openembedded/meta-filesystems/recipes-filesystems/owfs/owfs_2.9p1.bb
deleted file mode 100644
index 21fd7e9..0000000
--- a/meta-openembedded/meta-filesystems/recipes-filesystems/owfs/owfs_2.9p1.bb
+++ /dev/null
@@ -1,68 +0,0 @@
-SUMMARY = "1-Wire file system"
-DESCRIPTION = "OWFS is an easy way to use the powerful 1-wire system of Dallas/Maxim"
-HOMEPAGE = "http://www.owfs.org/"
-SECTION = "console/network"
-
-LICENSE = "GPLv2 & LGPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=a0bc427f423a41220ab79a0b392218bd \
-                    file://COPYING.LIB;md5=865c4bd642d9e04f43925ad7e929ae87"
-
-DEPENDS = "fuse virtual/libusb0"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/owfs/owfs-${PV}.tar.gz \
-           file://owhttpd \
-           file://owserver "
-SRC_URI[md5sum] = "56ba145be208002e58775a7203369851"
-SRC_URI[sha256sum] = "9d22dbff72d235476688c02669f7171b23e21dffadf40bbdd3b8263908218424"
-
-inherit autotools-brokensep update-rc.d
-
-EXTRA_OECONF = " \
-                 --with-fuseinclude=${STAGING_INCDIR} \
-                 --with-fuselib=${STAGING_LIBDIR} \
-                 --enable-owfs \
-                 --enable-owhttpd \
-                 --enable-w1 \
-                 --disable-swig \
-                 --disable-owtcl \
-                 --disable-owphp \
-                 --disable-owpython \
-                 --disable-owperl \
-"
-
-do_install_prepend() {
-    install -d ${D}${sysconfdir}/default/
-    install -d ${D}${sysconfdir}/init.d/
-    install -m 0755 ${WORKDIR}/owhttpd ${D}${sysconfdir}/init.d/owhttpd
-    install -m 0755 ${WORKDIR}/owserver ${D}${sysconfdir}/init.d/owserver
-}
-
-PACKAGES =+ "owftpd owhttpd owserver owshell libowcapi libow libownet owmon owtap"
-
-DESCRIPTION_owftpd = "Anoymous FTP server for 1-wire access"
-DESCRIPTION_owhttpd = "Tiny webserver for 1-wire control"
-DESCRIPTION_owserver = "Backend server (daemon) for 1-wire control"
-DESCRIPTION_owshell = "owdir owread owwrite owpresent owget - lightweight owserver access"
-DESCRIPTION_libowcapi = "easy C-language 1-wire interface "
-DESCRIPTION_libow = "easy C-language 1-wire interface to the owserver protocol"
-DESCRIPTION_libownet = "easy C-language 1-wire interface to the owserver protocol"
-DESCRIPTION_owmon = "Monitor for owserver settings and statistics"
-DESCRIPTION_owtap = "Packet sniffer for the owserver protocol"
-
-FILES_owftpd = "${bindir}/owftpd"
-FILES_owhttpd = "${bindir}/owhttpd ${sysconfdir}/init.d/owhttpd"
-FILES_owserver = "${bindir}/owserver ${sysconfdir}/init.d/owserver"
-FILES_owshell = "${bindir}/owread ${bindir}/owwrite \
-                 ${bindir}/owdir ${bindir}/owpresent \
-                 ${bindir}/owget ${bindir}/owside"
-FILES_owmon = "${bindir}/owmon"
-FILES_owtap = "${bindir}/owtap"
-FILES_libowcapi = "${libdir}/libowcapi-*"
-FILES_libow = "${libdir}/libow-*"
-FILES_libownet = "${libdir}/libownet-*"
-
-INITSCRIPT_PACKAGES = "owhttpd owserver"
-INITSCRIPT_NAME_owserver = "owserver"
-INITSCRIPT_NAME_owhttpd = "owhttpd"
-INITSCRIPT_PARAMS_owserver = "defaults 20"
-INITSCRIPT_PARAMS_owhttpd = "defaults 21"
diff --git a/meta-openembedded/meta-filesystems/recipes-filesystems/owfs/owfs_3.2p2.bb b/meta-openembedded/meta-filesystems/recipes-filesystems/owfs/owfs_3.2p2.bb
new file mode 100644
index 0000000..50865cc
--- /dev/null
+++ b/meta-openembedded/meta-filesystems/recipes-filesystems/owfs/owfs_3.2p2.bb
@@ -0,0 +1,71 @@
+SUMMARY = "1-Wire file system"
+DESCRIPTION = "OWFS is an easy way to use the powerful 1-wire system of Dallas/Maxim"
+HOMEPAGE = "http://www.owfs.org/"
+SECTION = "console/network"
+
+LICENSE = "GPLv2 & LGPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=12a64df1cc87275e940cab05ee75c37d \
+                    file://COPYING.LIB;md5=16ff3ffebed582e19ea7a4f48ec77b42"
+
+DEPENDS = "fuse virtual/libusb0"
+# v3.2p2
+SRCREV = "93c1f36d9ac481075287da331d5184f590f8c0fa"
+SRC_URI = "git://github.com/owfs/owfs \
+           file://owhttpd \
+           file://owserver \
+           file://0001-include-sys-sysmacros.h-for-major.patch \
+           "
+
+S = "${WORKDIR}/git"
+
+inherit autotools-brokensep update-rc.d pkgconfig
+
+EXTRA_OECONF = " \
+                 --with-fuseinclude=${STAGING_INCDIR} \
+                 --with-fuselib=${STAGING_LIBDIR} \
+                 --enable-owfs \
+                 --enable-owhttpd \
+                 --enable-w1 \
+                 --disable-swig \
+                 --disable-owtcl \
+                 --disable-owphp \
+                 --disable-owpython \
+                 --disable-owperl \
+"
+
+do_install_prepend() {
+    install -d ${D}${sysconfdir}/default/
+    install -d ${D}${sysconfdir}/init.d/
+    install -m 0755 ${WORKDIR}/owhttpd ${D}${sysconfdir}/init.d/owhttpd
+    install -m 0755 ${WORKDIR}/owserver ${D}${sysconfdir}/init.d/owserver
+}
+
+PACKAGES =+ "owftpd owhttpd owserver owshell libowcapi libow libownet owmon owtap"
+
+DESCRIPTION_owftpd = "Anoymous FTP server for 1-wire access"
+DESCRIPTION_owhttpd = "Tiny webserver for 1-wire control"
+DESCRIPTION_owserver = "Backend server (daemon) for 1-wire control"
+DESCRIPTION_owshell = "owdir owread owwrite owpresent owget - lightweight owserver access"
+DESCRIPTION_libowcapi = "easy C-language 1-wire interface "
+DESCRIPTION_libow = "easy C-language 1-wire interface to the owserver protocol"
+DESCRIPTION_libownet = "easy C-language 1-wire interface to the owserver protocol"
+DESCRIPTION_owmon = "Monitor for owserver settings and statistics"
+DESCRIPTION_owtap = "Packet sniffer for the owserver protocol"
+
+FILES_owftpd = "${bindir}/owftpd"
+FILES_owhttpd = "${bindir}/owhttpd ${sysconfdir}/init.d/owhttpd"
+FILES_owserver = "${bindir}/owserver ${sysconfdir}/init.d/owserver"
+FILES_owshell = "${bindir}/owread ${bindir}/owwrite \
+                 ${bindir}/owdir ${bindir}/owpresent \
+                 ${bindir}/owget ${bindir}/owside"
+FILES_owmon = "${bindir}/owmon"
+FILES_owtap = "${bindir}/owtap"
+FILES_libowcapi = "${libdir}/libowcapi-*"
+FILES_libow = "${libdir}/libow-*"
+FILES_libownet = "${libdir}/libownet-*"
+
+INITSCRIPT_PACKAGES = "owhttpd owserver"
+INITSCRIPT_NAME_owserver = "owserver"
+INITSCRIPT_NAME_owhttpd = "owhttpd"
+INITSCRIPT_PARAMS_owserver = "defaults 20"
+INITSCRIPT_PARAMS_owhttpd = "defaults 21"
diff --git a/meta-openembedded/meta-filesystems/recipes-filesystems/yaffs2/yaffs2-utils_git.bb b/meta-openembedded/meta-filesystems/recipes-filesystems/yaffs2/yaffs2-utils_git.bb
index 67c926b..6095e27 100644
--- a/meta-openembedded/meta-filesystems/recipes-filesystems/yaffs2/yaffs2-utils_git.bb
+++ b/meta-openembedded/meta-filesystems/recipes-filesystems/yaffs2/yaffs2-utils_git.bb
@@ -5,7 +5,9 @@
 HOMEPAGE = "http://www.yaffs.net"
 
 LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://utils/mkyaffs2image.c;beginline=12;endline=14;md5=5f5464f9b3e981ca574e65b00e438561"
+LIC_FILES_CHKSUM = "file://utils/mkyaffs2image.c;beginline=11;endline=13;md5=5f5464f9b3e981ca574e65b00e438561 \
+                    file://utils/mkyaffsimage.c;beginline=10;endline=12;md5=5f5464f9b3e981ca574e65b00e438561 \
+                    "
 
 PV = "0.0+git${SRCPV}"
 
@@ -17,7 +19,10 @@
            file://0001-define-loff_t-if-not-already-defined.patch \
            "
 
-SRCREV = "bc76682d93955cfb33051beb503ad9f8a5450578"
+SRCREV = "3439fa4e60dd9799766b2c101f799ed9e565b632"
+
+UPSTREAM_CHECK_COMMITS = "1"
+
 S = "${WORKDIR}/git"
 
 CFLAGS_append = " -I.. -DCONFIG_YAFFS_UTIL -DCONFIG_YAFFS_DEFINES_TYPES"
diff --git a/meta-openembedded/meta-filesystems/recipes-support/fuse/files/CVE-2018-10906-1.patch b/meta-openembedded/meta-filesystems/recipes-support/fuse/files/CVE-2018-10906-1.patch
deleted file mode 100644
index 83bef30..0000000
--- a/meta-openembedded/meta-filesystems/recipes-support/fuse/files/CVE-2018-10906-1.patch
+++ /dev/null
@@ -1,52 +0,0 @@
-From 28bdae3d113ef479c1660a581ef720cdc33bf466 Mon Sep 17 00:00:00 2001
-From: Jann Horn <jannh@google.com>
-Date: Fri, 13 Jul 2018 15:15:36 -0700
-Subject: [PATCH] fusermount: don't feed "escaped commas" into mount options
-
-The old code permits the following behavior:
-
-$ _FUSE_COMMFD=10000 priv_strace -etrace=mount -s200 fusermount -o 'foobar=\,allow_other' mount
-mount("/dev/fuse", ".", "fuse", MS_NOSUID|MS_NODEV, "foobar=\\,allow_other,fd=3,rootmode=40000,user_id=1000,group_id=1000") = -1 EINVAL (Invalid argument)
-
-However, backslashes do not have any special meaning for the kernel here.
-
-As it happens, you can't abuse this because there is no FUSE mount option
-that takes a string value that can contain backslashes; but this is very
-brittle. Don't interpret "escape characters" in places where they don't
-work.
-
-CVE: CVE-2018-10906
-Upstream-Status: Backport [https://github.com/libfuse/libfuse/commit/28bdae3d113ef479c1660a581ef720cdc33bf466]
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- util/fusermount.c | 5 ++++-
- 1 file changed, 4 insertions(+), 1 deletion(-)
-
-diff --git a/util/fusermount.c b/util/fusermount.c
-index 0e1d34d..143bd4a 100644
---- a/util/fusermount.c
-+++ b/util/fusermount.c
-@@ -29,6 +29,7 @@
- #include <sys/socket.h>
- #include <sys/utsname.h>
- #include <sched.h>
-+#include <stdbool.h>
- 
- #define FUSE_COMMFD_ENV		"_FUSE_COMMFD"
- 
-@@ -754,8 +755,10 @@ static int do_mount(const char *mnt, char **typep, mode_t rootmode,
- 		unsigned len;
- 		const char *fsname_str = "fsname=";
- 		const char *subtype_str = "subtype=";
-+		bool escape_ok = begins_with(s, fsname_str) ||
-+				 begins_with(s, subtype_str);
- 		for (len = 0; s[len]; len++) {
--			if (s[len] == '\\' && s[len + 1])
-+			if (escape_ok && s[len] == '\\' && s[len + 1])
- 				len++;
- 			else if (s[len] == ',')
- 				break;
--- 
-2.13.3
-
diff --git a/meta-openembedded/meta-filesystems/recipes-support/fuse/files/CVE-2018-10906-2.patch b/meta-openembedded/meta-filesystems/recipes-support/fuse/files/CVE-2018-10906-2.patch
deleted file mode 100644
index 104aa17..0000000
--- a/meta-openembedded/meta-filesystems/recipes-support/fuse/files/CVE-2018-10906-2.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-From 5018a0c016495155ee598b7e0167b43d5d902414 Mon Sep 17 00:00:00 2001
-From: Jann Horn <jannh@google.com>
-Date: Sat, 14 Jul 2018 03:47:50 -0700
-Subject: [PATCH] fusermount: refuse unknown options
-
-Blacklists are notoriously fragile; especially if the kernel wishes to add
-some security-critical mount option at a later date, all existing systems
-with older versions of fusermount installed will suddenly have a security
-problem.
-Additionally, if the kernel's option parsing became a tiny bit laxer, the
-blacklist could probably be bypassed.
-
-Whitelist known-harmless flags instead, even if it's slightly more
-inconvenient.
-
-CVE: CVE-2018-10906
-Upstream-Status: Backport [https://github.com/libfuse/libfuse/commit/5018a0c016495155ee598b7e0167b43d5d902414]
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- util/fusermount.c | 8 +++++++-
- 1 file changed, 7 insertions(+), 1 deletion(-)
-
-diff --git a/util/fusermount.c b/util/fusermount.c
-index 4e0f51a..2792407 100644
---- a/util/fusermount.c
-+++ b/util/fusermount.c
-@@ -819,10 +819,16 @@ static int do_mount(const char *mnt, char **typep, mode_t rootmode,
- 						flags |= flag;
- 					else
- 						flags  &= ~flag;
--				} else {
-+				} else if (opt_eq(s, len, "default_permissions") ||
-+					   opt_eq(s, len, "allow_other") ||
-+					   begins_with(s, "max_read=") ||
-+					   begins_with(s, "blksize=")) {
- 					memcpy(d, s, len);
- 					d += len;
- 					*d++ = ',';
-+				} else {
-+					fprintf(stderr, "%s: unknown option '%.*s'\n", progname, len, s);
-+					exit(1);
- 				}
- 			}
- 		}
--- 
-2.13.3
-
diff --git a/meta-openembedded/meta-filesystems/recipes-support/fuse/fuse_2.9.7.bb b/meta-openembedded/meta-filesystems/recipes-support/fuse/fuse_2.9.7.bb
deleted file mode 100644
index 1eb9b70..0000000
--- a/meta-openembedded/meta-filesystems/recipes-support/fuse/fuse_2.9.7.bb
+++ /dev/null
@@ -1,71 +0,0 @@
-SUMMARY = "Implementation of a fully functional filesystem in a userspace program"
-DESCRIPTION = "FUSE (Filesystem in Userspace) is a simple interface for userspace \
-               programs to export a virtual filesystem to the Linux kernel. FUSE \
-               also aims to provide a secure method for non privileged users to \
-               create and mount their own filesystem implementations. \
-              "
-HOMEPAGE = "https://github.com/libfuse/libfuse"
-SECTION = "libs"
-LICENSE = "GPLv2 & LGPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-                    file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c"
-
-SRC_URI = "https://github.com/libfuse/libfuse/releases/download/${BP}/${BP}.tar.gz \
-           file://gold-unversioned-symbol.patch \
-           file://aarch64.patch \
-           file://0001-fuse-fix-the-return-value-of-help-option.patch \
-           file://fuse.conf \
-           file://CVE-2018-10906-1.patch \
-           file://CVE-2018-10906-2.patch \
-"
-SRC_URI[md5sum] = "9bd4ce8184745fd3d000ca2692adacdb"
-SRC_URI[sha256sum] = "832432d1ad4f833c20e13b57cf40ce5277a9d33e483205fc63c78111b3358874"
-
-inherit autotools pkgconfig update-rc.d systemd
-
-INITSCRIPT_NAME = "fuse"
-INITSCRIPT_PARAMS = "start 3 S . stop 20 0 6 ."
-
-SYSTEMD_SERVICE_${PN} = ""
-
-DEPENDS = "gettext-native"
-
-PACKAGES =+ "fuse-utils-dbg fuse-utils libulockmgr libulockmgr-dev libulockmgr-dbg"
-
-RRECOMMENDS_${PN}_class-target = "kernel-module-fuse libulockmgr fuse-utils"
-
-FILES_${PN} += "${libdir}/libfuse.so.*"
-FILES_${PN}-dev += "${libdir}/libfuse*.la"
-
-FILES_libulockmgr = "${libdir}/libulockmgr.so.*"
-FILES_libulockmgr-dev += "${libdir}/libulock*.la"
-FILES_libulockmgr-dbg += "${libdir}/.debug/libulock*"
-
-# Forbid auto-renaming to libfuse-utils
-FILES_fuse-utils = "${bindir} ${base_sbindir}"
-FILES_fuse-utils-dbg = "${bindir}/.debug ${base_sbindir}/.debug"
-DEBIAN_NOAUTONAME_fuse-utils = "1"
-DEBIAN_NOAUTONAME_fuse-utils-dbg = "1"
-
-do_configure_prepend() {
-    # Make this explicit so overriding base_sbindir propagates properly.
-    export MOUNT_FUSE_PATH="${base_sbindir}"
-}
-
-do_install_append() {
-    rm -rf ${D}${base_prefix}/dev
-
-    # systemd class remove the sysv_initddir only if systemd_system_unitdir
-    # contains anything, but it's not needed if sysvinit is not in DISTRO_FEATURES
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'false', 'true', d)}; then
-        rm -rf ${D}${sysconfdir}/init.d/
-    fi
-
-    # Install systemd related configuration file
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-        install -d ${D}${sysconfdir}/modules-load.d
-        install -m 0644 ${WORKDIR}/fuse.conf ${D}${sysconfdir}/modules-load.d
-    fi
-}
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-filesystems/recipes-support/fuse/fuse_2.9.8.bb b/meta-openembedded/meta-filesystems/recipes-support/fuse/fuse_2.9.8.bb
new file mode 100644
index 0000000..caa75c7
--- /dev/null
+++ b/meta-openembedded/meta-filesystems/recipes-support/fuse/fuse_2.9.8.bb
@@ -0,0 +1,72 @@
+SUMMARY = "Implementation of a fully functional filesystem in a userspace program"
+DESCRIPTION = "FUSE (Filesystem in Userspace) is a simple interface for userspace \
+               programs to export a virtual filesystem to the Linux kernel. FUSE \
+               also aims to provide a secure method for non privileged users to \
+               create and mount their own filesystem implementations. \
+              "
+HOMEPAGE = "https://github.com/libfuse/libfuse"
+SECTION = "libs"
+LICENSE = "GPLv2 & LGPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                    file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c"
+
+SRC_URI = "https://github.com/libfuse/libfuse/releases/download/${BP}/${BP}.tar.gz \
+           file://gold-unversioned-symbol.patch \
+           file://aarch64.patch \
+           file://0001-fuse-fix-the-return-value-of-help-option.patch \
+           file://fuse.conf \
+"
+SRC_URI[md5sum] = "f365e848a82504edb0b7a33df790ca78"
+SRC_URI[sha256sum] = "5e84f81d8dd527ea74f39b6bc001c874c02bad6871d7a9b0c14efb57430eafe3"
+
+UPSTREAM_CHECK_URI = "https://github.com/libfuse/libfuse/releases"
+UPSTREAM_CHECK_REGEX = "fuse\-(?P<pver>2(\.\d+)+).tar.gz"
+
+inherit autotools pkgconfig update-rc.d systemd
+
+INITSCRIPT_NAME = "fuse"
+INITSCRIPT_PARAMS = "start 3 S . stop 20 0 6 ."
+
+SYSTEMD_SERVICE_${PN} = ""
+
+DEPENDS = "gettext-native"
+
+PACKAGES =+ "fuse-utils libulockmgr libulockmgr-dev"
+
+RPROVIDES_${PN}-dbg += "fuse-utils-dbg libulockmgr-dbg"
+
+RRECOMMENDS_${PN}_class-target = "kernel-module-fuse libulockmgr fuse-utils"
+
+FILES_${PN} += "${libdir}/libfuse.so.*"
+FILES_${PN}-dev += "${libdir}/libfuse*.la"
+
+FILES_libulockmgr = "${libdir}/libulockmgr.so.*"
+FILES_libulockmgr-dev += "${libdir}/libulock*.la"
+
+# Forbid auto-renaming to libfuse-utils
+FILES_fuse-utils = "${bindir} ${base_sbindir}"
+DEBIAN_NOAUTONAME_fuse-utils = "1"
+DEBIAN_NOAUTONAME_${PN}-dbg = "1"
+
+do_configure_prepend() {
+    # Make this explicit so overriding base_sbindir propagates properly.
+    export MOUNT_FUSE_PATH="${base_sbindir}"
+}
+
+do_install_append() {
+    rm -rf ${D}${base_prefix}/dev
+
+    # systemd class remove the sysv_initddir only if systemd_system_unitdir
+    # contains anything, but it's not needed if sysvinit is not in DISTRO_FEATURES
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'false', 'true', d)}; then
+        rm -rf ${D}${sysconfdir}/init.d/
+    fi
+
+    # Install systemd related configuration file
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+        install -d ${D}${sysconfdir}/modules-load.d
+        install -m 0644 ${WORKDIR}/fuse.conf ${D}${sysconfdir}/modules-load.d
+    fi
+}
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-filesystems/recipes-support/physfs/physfs_2.0.3.bb b/meta-openembedded/meta-filesystems/recipes-support/physfs/physfs_2.0.3.bb
deleted file mode 100644
index dc2c106..0000000
--- a/meta-openembedded/meta-filesystems/recipes-support/physfs/physfs_2.0.3.bb
+++ /dev/null
@@ -1,13 +0,0 @@
-SUMMARY = "PhysicsFS is a library to provide abstract access to various archives"
-HOMEAPAGE = "http://icculus.org/physfs"
-LICENSE = "Zlib"
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=5d94e3eaaa10b00ca803ba35a3e87cde"
-DEPENDS = "readline zlib"
-
-inherit cmake
-
-PE = "1"
-
-SRC_URI = "http://icculus.org/${BPN}/downloads/${BP}.tar.bz2"
-SRC_URI[md5sum] = "c2c727a8a8deb623b521b52d0080f613"
-SRC_URI[sha256sum] = "ca862097c0fb451f2cacd286194d071289342c107b6fe69079c079883ff66b69"
diff --git a/meta-openembedded/meta-filesystems/recipes-support/physfs/physfs_3.0.1.bb b/meta-openembedded/meta-filesystems/recipes-support/physfs/physfs_3.0.1.bb
new file mode 100644
index 0000000..cc97dea
--- /dev/null
+++ b/meta-openembedded/meta-filesystems/recipes-support/physfs/physfs_3.0.1.bb
@@ -0,0 +1,13 @@
+SUMMARY = "PhysicsFS is a library to provide abstract access to various archives"
+HOMEAPAGE = "http://icculus.org/physfs"
+LICENSE = "Zlib"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=2668e2fb051c3e564198e146a9a2d9f0"
+DEPENDS = "readline zlib"
+
+inherit cmake
+
+PE = "1"
+
+SRC_URI = "http://icculus.org/${BPN}/downloads/${BP}.tar.bz2"
+SRC_URI[md5sum] = "359f102bcbd62accf84ef32f4863255d"
+SRC_URI[sha256sum] = "b77b9f853168d9636a44f75fca372b363106f52d789d18a2f776397bf117f2f1"
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/aufs-util/aufs-util/0001-libau-Define-STRIP-weakly.patch b/meta-openembedded/meta-filesystems/recipes-utils/aufs-util/aufs-util/0001-libau-Define-STRIP-weakly.patch
deleted file mode 100644
index 6732dc4..0000000
--- a/meta-openembedded/meta-filesystems/recipes-utils/aufs-util/aufs-util/0001-libau-Define-STRIP-weakly.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From daf04dc9ca1f2e4c65ec338ab439e0a792e1a8ac Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 5 Sep 2017 10:36:52 -0700
-Subject: [PATCH] libau: Define STRIP weakly
-
-STRIP can be set on environment to use cross version of strip utility
-hardcoding to strip is not working in cross environment
-
-Upstream-Status: Submitted
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
----
- libau/Makefile | 3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
-diff --git a/libau/Makefile b/libau/Makefile
-index 81520ac..c25eef2 100644
---- a/libau/Makefile
-+++ b/libau/Makefile
-@@ -25,6 +25,7 @@ LibSoHdr = libau.h rdu.h
- LibSoExport = $(addsuffix .exp, $(basename ${LibSoObj}))
- LibSoExportErr = $(addsuffix .err, ${LibSoExport})
- LibSoVerScript = verscript
-+STRIP ?= strip
- 
- all: ${LibSo}
- 
-@@ -77,7 +78,7 @@ ${LibSo}.${LibSoMajor}.${LibSoMinor}: ${LibSoObj}
- 	${CC} --shared -Wl,-soname,${LibSo}.${LibSoMajor} \
- 		-Wl,--version-script,${LibSoVerScript} \
- 		${LDFLAGS} -o $@ $^ ${LDLIBS}
--	strip -R EXP $@
-+	${STRIP} -R EXP $@
- #	readelf --syms --use-dynamic libau.so
- 
- install_ulib: File = ${LibSo}.${LibSoMajor}.${LibSoMinor}
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/aufs-util/aufs-util_git.bb b/meta-openembedded/meta-filesystems/recipes-utils/aufs-util/aufs-util_git.bb
index 2e855e3..6d71fc0 100644
--- a/meta-openembedded/meta-filesystems/recipes-utils/aufs-util/aufs-util_git.bb
+++ b/meta-openembedded/meta-filesystems/recipes-utils/aufs-util/aufs-util_git.bb
@@ -7,17 +7,18 @@
 DEPENDS = "coreutils-native aufs-util-native"
 DEPENDS_class-native = ""
 
-SRCREV = "89afb1806c3d2eed8db2666ae254b77518ae3ceb"
-SRC_URI = "git://git.code.sf.net/p/aufs/aufs-util;protocol=git;branch=aufs4.4 \
-           https://raw.githubusercontent.com/sfjro/aufs4-linux/aufs4.4/include/uapi/linux/aufs_type.h;name=aufs_type \
+SRCREV = "8f35db59ef83078f87879ec2828e0bb45719e0ef"
+SRC_URI = "git://git.code.sf.net/p/aufs/aufs-util;protocol=git;branch=aufs4.9 \
+           https://raw.githubusercontent.com/sfjro/aufs4-linux/aufs4.9/include/uapi/linux/aufs_type.h;name=aufs_type \
            file://aufs-util-don-t-strip-executables.patch \
            file://aufs-util-add-tool-concept-to-Makefile-for-cross-com.patch \
-           file://0001-libau-Define-STRIP-weakly.patch \
 "
-SRC_URI[aufs_type.md5sum] = "f7b4a255dcb55fe7b0967f5f59b44f19"
-SRC_URI[aufs_type.sha256sum] = "85bc8e4c1a94a7d526c382e4b047b4256cab8c4a65fc0396291707ad9a327a18"
+SRC_URI[aufs_type.md5sum] = "b37129ef0703de72a852db7e48bdedc6"
+SRC_URI[aufs_type.sha256sum] = "7ff6566adb9c7a3b6862cdc85a690ab546f1d0bc81ddd595fd663c0a69031683"
 
-PV = "4.4+git${SRCPV}"
+UPSTREAM_CHECK_COMMITS = "1"
+
+PV = "4.9+git${SRCPV}"
 
 S = "${WORKDIR}/git"
 
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/f2fs-tools/f2fs-tools/0001-f2fs-tools-Use-srcdir-prefix-to-denote-include-path.patch b/meta-openembedded/meta-filesystems/recipes-utils/f2fs-tools/f2fs-tools/0001-f2fs-tools-Use-srcdir-prefix-to-denote-include-path.patch
new file mode 100644
index 0000000..0a3261b
--- /dev/null
+++ b/meta-openembedded/meta-filesystems/recipes-utils/f2fs-tools/f2fs-tools/0001-f2fs-tools-Use-srcdir-prefix-to-denote-include-path.patch
@@ -0,0 +1,29 @@
+From 0fb9d6bc25e903f7831a38468845ea143fb5afd5 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 11 Aug 2018 18:49:03 -0700
+Subject: [PATCH] f2fs-tools: Use srcdir prefix to denote include path
+
+This helps builds when builddir != srcdir
+
+Upstream-Status: Submitted [https://lkml.org/lkml/2018/8/12/1]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ tools/sg_write_buffer/Makefile.am | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/tools/sg_write_buffer/Makefile.am b/tools/sg_write_buffer/Makefile.am
+index 922c328..19c438d 100644
+--- a/tools/sg_write_buffer/Makefile.am
++++ b/tools/sg_write_buffer/Makefile.am
+@@ -1,7 +1,7 @@
+ ## Makefile.am
+ 
+ if LINUX
+-AM_CPPFLAGS = -I./include
++AM_CPPFLAGS = -I$(srcdir)/include
+ AM_CFLAGS = -Wall
+ sbin_PROGRAMS = sg_write_buffer
+ sg_write_buffer_SOURCES = sg_write_buffer.c \
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/f2fs-tools/f2fs-tools/0002-Fix-mkfs-out-of-tree-builds.patch b/meta-openembedded/meta-filesystems/recipes-utils/f2fs-tools/f2fs-tools/0002-Fix-mkfs-out-of-tree-builds.patch
deleted file mode 100644
index 9e561cb..0000000
--- a/meta-openembedded/meta-filesystems/recipes-utils/f2fs-tools/f2fs-tools/0002-Fix-mkfs-out-of-tree-builds.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From 0731eefd389e01419f78a115e1363ed0c28cfd3a Mon Sep 17 00:00:00 2001
-From: "Yong, Jonathan" <jonathan.yong@intel.com>
-Date: Thu, 30 Mar 2017 08:03:37 +0000
-Subject: [PATCH] Fix mkfs out of tree builds
-
-Libraries are built in builddir, not srcdir, fix Makefile.am
-accordingly.
-
-Signed-off-by: Yong, Jonathan <jonathan.yong@intel.com>
-Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
-
-The patch was imported from the f2fs-tools repo
-(git://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs-tools.git)
-commit ID 0731eefd389e01419f78a115e1363ed0c28cfd3a.
-
-Upstream-Status: Accepted, expected to be included in 1.9.0.
-
-Signed-off-by: Yong, Jonathan <jonathan.yong@intel.com>
-
----
- mkfs/Makefile.am | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/mkfs/Makefile.am b/mkfs/Makefile.am
-index 162a0cf..0ea8b49 100644
---- a/mkfs/Makefile.am
-+++ b/mkfs/Makefile.am
-@@ -10,5 +10,5 @@ lib_LTLIBRARIES = libf2fs_format.la
- libf2fs_format_la_SOURCES = f2fs_format_main.c f2fs_format.c f2fs_format_utils.c
- libf2fs_format_la_CFLAGS = -DWITH_BLKDISCARD
- libf2fs_format_la_CPPFLAGS = -I$(top_srcdir)/include
--libf2fs_format_la_LDFLAGS = -luuid -L$(top_srcdir)/lib -lf2fs \
-+libf2fs_format_la_LDFLAGS = -luuid -L$(top_builddir)/lib -lf2fs \
- 	-version-info $(FMT_CURRENT):$(FMT_REVISION):$(FMT_AGE)
--- 
-2.10.2
-
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/f2fs-tools/f2fs-tools_1.11.0.bb b/meta-openembedded/meta-filesystems/recipes-utils/f2fs-tools/f2fs-tools_1.11.0.bb
new file mode 100644
index 0000000..2240049
--- /dev/null
+++ b/meta-openembedded/meta-filesystems/recipes-utils/f2fs-tools/f2fs-tools_1.11.0.bb
@@ -0,0 +1,20 @@
+SUMMARY = "Tools for Flash-Friendly File System (F2FS)"
+HOMEPAGE = "http://sourceforge.net/projects/f2fs-tools/"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=362b4b2594cd362b874a97718faa51d3"
+
+# to provide libuuid
+DEPENDS = "util-linux"
+
+# v1.11.0
+SRCREV = "b98fab3666e498c2e27ad9dcda6874c9b683f06b"
+SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs-tools.git \
+           file://0001-Remove-AC_CHECK_FILE-for-cross-compilation.patch \
+           file://0001-f2fs-tools-Use-srcdir-prefix-to-denote-include-path.patch \
+           "
+S = "${WORKDIR}/git"
+
+inherit pkgconfig autotools
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/f2fs-tools/f2fs-tools_1.8.0.bb b/meta-openembedded/meta-filesystems/recipes-utils/f2fs-tools/f2fs-tools_1.8.0.bb
deleted file mode 100644
index 691cb6e..0000000
--- a/meta-openembedded/meta-filesystems/recipes-utils/f2fs-tools/f2fs-tools_1.8.0.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-SUMMARY = "Tools for Flash-Friendly File System (F2FS)"
-HOMEPAGE = "http://sourceforge.net/projects/f2fs-tools/"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=362b4b2594cd362b874a97718faa51d3"
-
-# to provide libuuid
-DEPENDS = "util-linux"
-
-SRCREV = "1e7aedf99b85d16f94d1d8ad2fcf846403bb2174"
-SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs-tools.git \
-    file://0001-Remove-AC_CHECK_FILE-for-cross-compilation.patch \
-    file://0002-Fix-mkfs-out-of-tree-builds.patch"
-S = "${WORKDIR}/git"
-
-inherit pkgconfig autotools
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0001-Include-fcntl.h-for-O_EXCL.patch b/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0001-Include-fcntl.h-for-O_EXCL.patch
deleted file mode 100644
index 660468d..0000000
--- a/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0001-Include-fcntl.h-for-O_EXCL.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From 8cf48da5f645dd7bbb1ccbeab5bb0964f40f17f7 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 13 Jul 2017 23:18:47 -0700
-Subject: [PATCH 1/5] Include fcntl.h for O_EXCL
-
-Fix
-error: 'O_CREAT' undeclared (first use in this function)
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- invutil/invidx.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/invutil/invidx.c b/invutil/invidx.c
-index 67efdf7..325a9a1 100644
---- a/invutil/invidx.c
-+++ b/invutil/invidx.c
-@@ -27,6 +27,7 @@
- #include <sys/stat.h>
- #include <string.h>
- #include <uuid/uuid.h>
-+#include <fcntl.h>
- 
- #include "types.h"
- #include "mlog.h"
--- 
-2.13.2
-
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0001-xfsdump-Use-c99-defined-int64_t-instead-of-__int64_t.patch b/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0001-xfsdump-Use-c99-defined-int64_t-instead-of-__int64_t.patch
deleted file mode 100644
index 1fe1bde..0000000
--- a/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0001-xfsdump-Use-c99-defined-int64_t-instead-of-__int64_t.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From f1e822d546e08cc195eaeb38ca172bd0c3800aa9 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 9 Sep 2017 07:48:48 -0700
-Subject: [PATCH] xfsdump: Use c99 defined int64_t instead of __int64_t
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Submitted
-
- common/hsmapi.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/common/hsmapi.c b/common/hsmapi.c
-index 6054773..0709dbe 100644
---- a/common/hsmapi.c
-+++ b/common/hsmapi.c
-@@ -585,7 +585,7 @@ HsmModifyExtentMap(
- 	struct getbmapx	*bmap)
- {
- 	dmf_f_ctxt_t	*dmf_f_ctxtp = (dmf_f_ctxt_t *)contextp;
--	__int64_t	length;
-+	int64_t		length;
- 
- 	if (bmap[0].bmv_entries <= 0) {
- 		return 1;	/* caller must already be at EOF */
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0002-Replace-__uint32_t-with-uint32_t.patch b/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0002-Replace-__uint32_t-with-uint32_t.patch
deleted file mode 100644
index ed3e0a9..0000000
--- a/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0002-Replace-__uint32_t-with-uint32_t.patch
+++ /dev/null
@@ -1,122 +0,0 @@
-From f76d2142905f0e5bd830d5d576c235af1171c6ac Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 13 Jul 2017 23:23:31 -0700
-Subject: [PATCH 2/5] Replace __uint32_t with uint32_t
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- common/content_inode.h | 4 ++--
- doc/xfsdump.html       | 8 ++++----
- inventory/inv_oref.h   | 2 +-
- inventory/inv_priv.h   | 4 ++--
- inventory/inventory.h  | 2 +-
- 5 files changed, 10 insertions(+), 10 deletions(-)
-
-diff --git a/common/content_inode.h b/common/content_inode.h
-index a69a9a0..6936e05 100644
---- a/common/content_inode.h
-+++ b/common/content_inode.h
-@@ -191,10 +191,10 @@ typedef struct bstat bstat_t;
-  * and using two 16bit values to hold new 32bit projid was choosen
-  * to retain compatibility with "old" filesystems).
-  */
--static inline __uint32_t
-+static inline uint32_t
- bstat_projid(struct bstat *bs)
- {
--        return (__uint32_t)bs->bs_projid_hi << 16 | bs->bs_projid_lo;
-+        return (uint32_t)bs->bs_projid_hi << 16 | bs->bs_projid_lo;
- }
- 
- 
-diff --git a/doc/xfsdump.html b/doc/xfsdump.html
-index 9c6722e..f85128f 100644
---- a/doc/xfsdump.html
-+++ b/doc/xfsdump.html
-@@ -1935,7 +1935,7 @@ The files are constructed like so:
- <pre>
- typedef struct invt_counter {
-     INVT_COUNTER_FIELDS
--        __uint32_t    ic_vernum;/* on disk version number for posterity */\
-+        uint32_t    ic_vernum;/* on disk version number for posterity */\
-         u_int         ic_curnum;/* number of sessions/invindices recorded \
-                                    so far */                              \
-         u_int         ic_maxnum;/* maximum number of sessions/inv_indices \
-@@ -1975,7 +1975,7 @@ typedef struct invt_fstab {
- <pre>
- typedef struct invt_counter {
-     INVT_COUNTER_FIELDS
--        __uint32_t    ic_vernum;/* on disk version number for posterity */\
-+        uint32_t    ic_vernum;/* on disk version number for posterity */\
-         u_int         ic_curnum;/* number of sessions/invindices recorded \
-                                    so far */                              \
-         u_int         ic_maxnum;/* maximum number of sessions/inv_indices \
-@@ -2012,7 +2012,7 @@ typedef struct invt_entry {
- <pre>
- typedef struct invt_sescounter {
-     INVT_COUNTER_FIELDS
--        __uint32_t    ic_vernum;/* on disk version number for posterity */\
-+        uint32_t    ic_vernum;/* on disk version number for posterity */\
-         u_int         ic_curnum;/* number of sessions/invindices recorded \
-                                    so far */                              \
-         u_int         ic_maxnum;/* maximum number of sessions/inv_indices \
-@@ -2034,7 +2034,7 @@ typedef struct invt_seshdr {
-     off64_t    sh_streams_off; /* offset to start of the set of
-                                   stream hdrs */
-     time_t     sh_time;        /* time of the dump */
--    __uint32_t sh_flag;        /* for misc flags */
-+    uint32_t sh_flag;        /* for misc flags */
-     u_char     sh_level;       /* dump level */
-     u_char     sh_pruned;      /* pruned by invutil flag */
-     char       sh_padding[22];
-diff --git a/inventory/inv_oref.h b/inventory/inv_oref.h
-index e16684d..38303a4 100644
---- a/inventory/inv_oref.h
-+++ b/inventory/inv_oref.h
-@@ -46,7 +46,7 @@
- 
- 
- 
--typedef __uint32_t	invt_objtype_t;
-+typedef uint32_t	invt_objtype_t;
- 
- #define INVT_LOCKED		0x0001
- 
-diff --git a/inventory/inv_priv.h b/inventory/inv_priv.h
-index 1690271..364ffbc 100644
---- a/inventory/inv_priv.h
-+++ b/inventory/inv_priv.h
-@@ -120,7 +120,7 @@ typedef struct invt_seshdr {
- 	off64_t		sh_streams_off; /* offset to start of the set of 
- 					   stream hdrs */
- 	time32_t	sh_time;        /* time of the dump */
--	__uint32_t	sh_flag;        /* for misc flags */
-+	uint32_t	sh_flag;        /* for misc flags */
- 	u_char		sh_level;       /* dump level */
- 	u_char		sh_pruned;      /* pruned by invutil flag */
- 	char		sh_padding[22];
-@@ -184,7 +184,7 @@ typedef struct invt_entry {
- 
- /* Cheap Inheritance, and an attempt to avoid a nested type */
- #define INVT_COUNTER_FIELDS  \
--        __uint32_t    ic_vernum;/* on disk version number for posterity */\
-+        uint32_t    ic_vernum;/* on disk version number for posterity */\
- 	uint	      ic_curnum;/* number of sessions/invindices recorded \
- 				   so far */				  \
- 	uint	      ic_maxnum;/* maximum number of sessions/inv_indices \
-diff --git a/inventory/inventory.h b/inventory/inventory.h
-index 134b9ba..c1d7403 100644
---- a/inventory/inventory.h
-+++ b/inventory/inventory.h
-@@ -43,7 +43,7 @@
- /* length of labels, mntpts, etc */
- #define INV_STRLEN              GLOBAL_HDR_STRING_SZ
- 
--typedef __uint32_t		inv_version_t;
-+typedef uint32_t		inv_version_t;
- 
- /* This is the general inventory version. 
-  */
--- 
-2.13.2
-
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0003-replace-use-of-SIGCLD-with-SIGCHLD.patch b/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0003-replace-use-of-SIGCLD-with-SIGCHLD.patch
deleted file mode 100644
index 31303d8..0000000
--- a/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0003-replace-use-of-SIGCLD-with-SIGCHLD.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From fcc0cf15a309947103a0695b8a1f4865b820eb5c Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 13 Jul 2017 23:26:03 -0700
-Subject: [PATCH 3/5] replace use of SIGCLD with SIGCHLD
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- common/main.c    | 2 +-
- doc/xfsdump.html | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/common/main.c b/common/main.c
-index 3848499..faa66ee 100644
---- a/common/main.c
-+++ b/common/main.c
-@@ -2225,7 +2225,7 @@ static sig_printmap_t sig_printmap[ ] = {
- 	{SIGTERM,	"SIGTERM"},
- 	{SIGUSR1,	"SIGUSR1"},
- 	{SIGUSR2,	"SIGUSR2"},
--	{SIGCLD,	"SIGCLD"},
-+	{SIGCHLD,	"SIGCHLD"},
- 	{SIGPWR,	"SIGPWR"},
- 	{SIGURG,	"SIGURG"},
- 	{SIGPOLL,	"SIGPOLL"},
-diff --git a/doc/xfsdump.html b/doc/xfsdump.html
-index f85128f..d96f037 100644
---- a/doc/xfsdump.html
-+++ b/doc/xfsdump.html
-@@ -334,7 +334,7 @@ the ring buffer. It ignores signals and does not terminate until it
- receives a RING_OP_DIE message. It then exits 0.
- <p>
- The main process sleeps waiting for any of its children to die
--(ie. waiting for a SIGCLD). All children that it cares about (stream
-+(ie. waiting for a SIGCHLD). All children that it cares about (stream
- managers and ring buffer slaves) are registered through the child
- manager abstraction. When a child dies wait status and other info is
- stored with its entry in the child manager. main() ignores the deaths
--- 
-2.13.2
-
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0004-include-limit.h-for-PATH_MAX.patch b/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0004-include-limit.h-for-PATH_MAX.patch
deleted file mode 100644
index 62ea15b..0000000
--- a/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0004-include-limit.h-for-PATH_MAX.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From 98c7d96f0f2c6eddf60aa4a1a08d7d4467645930 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 13 Jul 2017 23:28:10 -0700
-Subject: [PATCH 4/5] include limit.h for PATH_MAX
-
-fixed
-var.c:42:12: error: 'PATH_MAX' undeclared (first use in this function); did you mean 'RAND_MAX'?
-  char path[PATH_MAX];`
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- dump/var.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/dump/var.c b/dump/var.c
-index 645caab..8156d37 100644
---- a/dump/var.c
-+++ b/dump/var.c
-@@ -16,6 +16,7 @@
-  * Inc.,  51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
-  */
- 
-+#include <limits.h>
- #include <unistd.h>
- #include <stdlib.h>
- #include <sys/stat.h>
--- 
-2.13.2
-
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0005-include-sys-types.h-for-u_int32_t-in-attr-attributes.patch b/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0005-include-sys-types.h-for-u_int32_t-in-attr-attributes.patch
deleted file mode 100644
index fb6e467..0000000
--- a/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/files/0005-include-sys-types.h-for-u_int32_t-in-attr-attributes.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From d95f494de1aa8123c74170ffebaed8ea89649da2 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 13 Jul 2017 23:33:44 -0700
-Subject: [PATCH 5/5] include sys/types.h for u_int32_t in attr/attributes.h
-
-error: unknown type name 'u_int32_t'
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- restore/content.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/restore/content.c b/restore/content.c
-index 7c4a81f..1d5de1b 100644
---- a/restore/content.c
-+++ b/restore/content.c
-@@ -24,6 +24,7 @@
- #include <sys/param.h>
- #include <sys/stat.h>
- #include <sys/ioctl.h>
-+#include <sys/types.h>
- #include <attr/attributes.h>
- #include <xfs/handle.h>
- #include <time.h>
--- 
-2.13.2
-
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/xfsdump_3.1.7.bb b/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/xfsdump_3.1.7.bb
deleted file mode 100644
index 39f1189..0000000
--- a/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/xfsdump_3.1.7.bb
+++ /dev/null
@@ -1,46 +0,0 @@
-SUMMARY = "XFS Filesystem Dump Utility"
-DESCRIPTION = "The xfsdump package contains xfsdump, xfsrestore and a \
-               number of other utilities for administering XFS filesystems.\
-               xfsdump examines files in a filesystem, determines which \
-               need to be backed up, and copies those files to a \
-               specified disk, tape or other storage medium."
-HOMEPAGE = "http://oss.sgi.com/projects/xfs"
-SECTION = "base"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://doc/COPYING;md5=15c832894d10ddd00dfcf57bee490ecc"
-DEPENDS = "xfsprogs attr"
-
-SRC_URI = "https://www.kernel.org/pub/linux/utils/fs/xfs/xfsdump/${BP}.tar.xz \
-           file://remove-install-as-user.patch \
-           file://0001-Include-fcntl.h-for-O_EXCL.patch \
-           file://0002-Replace-__uint32_t-with-uint32_t.patch \
-           file://0003-replace-use-of-SIGCLD-with-SIGCHLD.patch \
-           file://0004-include-limit.h-for-PATH_MAX.patch \
-           file://0005-include-sys-types.h-for-u_int32_t-in-attr-attributes.patch \
-           file://0001-xfsdump-Use-c99-defined-int64_t-instead-of-__int64_t.patch \
-           "
-SRC_URI[md5sum] = "c6e91f2ac8b76c796db2d236f5ca5947"
-SRC_URI[sha256sum] = "99e6d4df257ebc6d29ca9e970ca20672c2ea03481ad949bc68f98de3e4d56dce"
-
-inherit autotools-brokensep
-
-PARALLEL_MAKE = ""
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[gettext] = "--enable-gettext=yes,--enable-gettext=no,gettext"
-
-CFLAGS += "-D_FILE_OFFSET_BITS=64"
-
-EXTRA_OEMAKE += "'LIBTOOL=${HOST_SYS}-libtool' V=1"
-
-do_configure () {
-    export DEBUG="-DNDEBUG"
-    install -m 0755 ${STAGING_DATADIR_NATIVE}/gnu-config/config.guess ${S}
-    install -m 0755 ${STAGING_DATADIR_NATIVE}/gnu-config/config.sub ${S}
-    oe_runconf
-}
-
-do_install () {
-    export DIST_ROOT=${D}
-    oe_runmake install
-    oe_runmake install-dev
-}
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/xfsdump_3.1.8.bb b/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/xfsdump_3.1.8.bb
new file mode 100644
index 0000000..54ab30c
--- /dev/null
+++ b/meta-openembedded/meta-filesystems/recipes-utils/xfsdump/xfsdump_3.1.8.bb
@@ -0,0 +1,40 @@
+SUMMARY = "XFS Filesystem Dump Utility"
+DESCRIPTION = "The xfsdump package contains xfsdump, xfsrestore and a \
+               number of other utilities for administering XFS filesystems.\
+               xfsdump examines files in a filesystem, determines which \
+               need to be backed up, and copies those files to a \
+               specified disk, tape or other storage medium."
+HOMEPAGE = "http://oss.sgi.com/projects/xfs"
+SECTION = "base"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://doc/COPYING;md5=15c832894d10ddd00dfcf57bee490ecc"
+DEPENDS = "xfsprogs attr"
+
+SRC_URI = "https://www.kernel.org/pub/linux/utils/fs/xfs/xfsdump/${BP}.tar.xz \
+           file://remove-install-as-user.patch \
+           "
+SRC_URI[md5sum] = "84d3bc287b4a2bb5d16b2320a47049a7"
+SRC_URI[sha256sum] = "ed14e67ae5b273c2698e767b43a46f033d361e540fe13feaaf9b110ee0edc585"
+
+inherit autotools-brokensep
+
+PARALLEL_MAKE = ""
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[gettext] = "--enable-gettext=yes,--enable-gettext=no,gettext"
+
+CFLAGS += "-D_FILE_OFFSET_BITS=64"
+
+EXTRA_OEMAKE += "'LIBTOOL=${HOST_SYS}-libtool' V=1"
+
+do_configure () {
+    export DEBUG="-DNDEBUG"
+    install -m 0755 ${STAGING_DATADIR_NATIVE}/gnu-config/config.guess ${S}
+    install -m 0755 ${STAGING_DATADIR_NATIVE}/gnu-config/config.sub ${S}
+    oe_runconf
+}
+
+do_install () {
+    export DIST_ROOT=${D}
+    oe_runmake install
+    oe_runmake install-dev
+}
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/files/0001-Check-for-MAP_SYNC-in-sys-mman.h.patch b/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/files/0001-Check-for-MAP_SYNC-in-sys-mman.h.patch
new file mode 100644
index 0000000..75b227a
--- /dev/null
+++ b/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/files/0001-Check-for-MAP_SYNC-in-sys-mman.h.patch
@@ -0,0 +1,52 @@
+From f41ef1f06d428c81fcdef73d896dfc7ceda1809c Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 23 Aug 2018 04:59:39 +0000
+Subject: [PATCH] Check for MAP_SYNC in sys/mman.h
+
+Not all arches have wired MAP_SYNC e.g. mips
+which have conflicts with definition, so checking
+a generic file is going to mis-configure xfsprogs
+for such arches.
+
+libc now has added the relevant macros to
+sys/mman.h, and returns the right values for arches
+where its implemented and nothing for others
+unlike asm-generic/mman.h which only checks
+for kernel headers and ignored arches
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ include/linux.h       | 3 +--
+ m4/package_libcdev.m4 | 3 +--
+ 2 files changed, 2 insertions(+), 4 deletions(-)
+
+diff --git a/include/linux.h b/include/linux.h
+index 1998941..7e5c9ab 100644
+--- a/include/linux.h
++++ b/include/linux.h
+@@ -331,8 +331,7 @@ fsmap_advance(
+ #define MAP_SYNC 0
+ #define MAP_SHARED_VALIDATE 0
+ #else
+-#include <asm-generic/mman.h>
+-#include <asm-generic/mman-common.h>
++#include <sys/mman.h>
+ #endif /* HAVE_MAP_SYNC */
+ 
+ #endif	/* __XFS_LINUX_H__ */
+diff --git a/m4/package_libcdev.m4 b/m4/package_libcdev.m4
+index 0a6b514..2b47d2f 100644
+--- a/m4/package_libcdev.m4
++++ b/m4/package_libcdev.m4
+@@ -335,8 +335,7 @@ AC_DEFUN([AC_HAVE_STATFS_FLAGS],
+ AC_DEFUN([AC_HAVE_MAP_SYNC],
+   [ AC_MSG_CHECKING([for MAP_SYNC])
+     AC_TRY_COMPILE([
+-#include <asm-generic/mman.h>
+-#include <asm-generic/mman-common.h>
++#include <sys/mman.h>
+     ], [
+         int flags = MAP_SYNC | MAP_SHARED_VALIDATE;
+     ], have_map_sync=yes
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/files/0001-build-Check-for-sync_file_range-libc-function.patch b/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/files/0001-build-Check-for-sync_file_range-libc-function.patch
index d8ff555..231da80 100644
--- a/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/files/0001-build-Check-for-sync_file_range-libc-function.patch
+++ b/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/files/0001-build-Check-for-sync_file_range-libc-function.patch
@@ -1,14 +1,14 @@
-From ae7172194d3fbb563ff8bbe7c02d34f1bd0e5ec9 Mon Sep 17 00:00:00 2001
+From f8a22f16c03e51d3c779b12f37d362faaa0ecf31 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Wed, 31 Jan 2018 21:28:53 -0800
 Subject: [PATCH] build: Check for sync_file_range libc function
 
 glibc 2.27 now has sync_file_range()
 
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
 Upstream-Status: Pending
 
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
  include/builddefs.in | 1 +
  io/Makefile          | 5 ++++-
  io/io.h              | 2 +-
@@ -16,10 +16,10 @@
  4 files changed, 9 insertions(+), 2 deletions(-)
 
 diff --git a/include/builddefs.in b/include/builddefs.in
-index 92d5076..504225a 100644
+index b895949..a388c83 100644
 --- a/include/builddefs.in
 +++ b/include/builddefs.in
-@@ -105,6 +105,7 @@ HAVE_FIEMAP = @have_fiemap@
+@@ -95,6 +95,7 @@ HAVE_FIEMAP = @have_fiemap@
  HAVE_PREADV = @have_preadv@
  HAVE_PWRITEV2 = @have_pwritev2@
  HAVE_COPY_FILE_RANGE = @have_copy_file_range@
@@ -28,10 +28,10 @@
  HAVE_SYNCFS = @have_syncfs@
  HAVE_READDIR = @have_readdir@
 diff --git a/io/Makefile b/io/Makefile
-index 6725936..1876e95 100644
+index 00ede48..dd001b0 100644
 --- a/io/Makefile
 +++ b/io/Makefile
-@@ -59,10 +59,13 @@ CFILES += inject.c resblks.c
+@@ -60,10 +60,13 @@ CFILES += inject.c resblks.c
  LCFLAGS += -DHAVE_INJECT -DHAVE_RESBLKS
  endif
  
@@ -47,10 +47,10 @@
  ifeq ($(HAVE_SYNC_FILE_RANGE),yes)
  CFILES += sync_file_range.c
 diff --git a/io/io.h b/io/io.h
-index 3862985..79ddc7b 100644
+index e1f3d95..fe2e6a2 100644
 --- a/io/io.h
 +++ b/io/io.h
-@@ -158,7 +158,7 @@ extern void		fiemap_init(void);
+@@ -151,7 +151,7 @@ extern void		fiemap_init(void);
  #define fiemap_init()	do { } while (0)
  #endif
  
@@ -60,23 +60,20 @@
  #else
  #define copy_range_init()	do { } while (0)
 diff --git a/io/sync_file_range.c b/io/sync_file_range.c
-index 7e4f3e6..aafea01 100644
+index 30bbc93..6c49d73 100644
 --- a/io/sync_file_range.c
 +++ b/io/sync_file_range.c
-@@ -16,6 +16,7 @@
-  * Inc.,  51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+@@ -4,6 +4,7 @@
+  * All Rights Reserved.
   */
  
 +#ifndef HAVE_COPY_FILE_RANGE
  #include "command.h"
  #include "input.h"
  #include "init.h"
-@@ -104,3 +105,5 @@ sync_range_init(void)
+@@ -92,3 +93,5 @@ sync_range_init(void)
  
  	add_command(&sync_range_cmd);
  }
 +
 +#endif
--- 
-2.16.1
-
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/files/0002-include-include-xfs-linux.h-after-sys-mman.h.patch b/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/files/0002-include-include-xfs-linux.h-after-sys-mman.h.patch
new file mode 100644
index 0000000..f924cd1
--- /dev/null
+++ b/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/files/0002-include-include-xfs-linux.h-after-sys-mman.h.patch
@@ -0,0 +1,33 @@
+From 11a42df394de3dc520e72a016296dcc6dea02a7a Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 23 Aug 2018 05:33:57 +0000
+Subject: [PATCH] include include/xfs/linux.h after <sys/mman.h>
+
+This helps compiling with musl which goes ahead and undefines MAP_SYNC
+for mips and other architectures where its not wired in kernel
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ io/mmap.c | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/io/mmap.c b/io/mmap.c
+index dbfcca5..ca00df1 100644
+--- a/io/mmap.c
++++ b/io/mmap.c
+@@ -4,10 +4,11 @@
+  * All Rights Reserved.
+  */
+ 
+-#include "command.h"
+-#include "input.h"
+ #include <sys/mman.h>
+ #include <signal.h>
++
++#include "command.h"
++#include "input.h"
+ #include "init.h"
+ #include "io.h"
+ 
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/files/disable-xfs_scrub-build.patch b/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/files/disable-xfs_scrub-build.patch
new file mode 100644
index 0000000..c07b4b5
--- /dev/null
+++ b/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/files/disable-xfs_scrub-build.patch
@@ -0,0 +1,30 @@
+From 2bd40e5ed4df0b0a42beff8806b1ec5daa372c48 Mon Sep 17 00:00:00 2001
+From: Yi Zhao <yi.zhao@windriver.com>
+Date: Thu, 19 Jul 2018 16:49:41 +0800
+Subject: [PATCH] Disable xfs_scrub build
+
+Disable xfs_scrub build since it is experimental.
+
+Upstream-Status: Inappropriate [embedded specific]
+
+Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
+---
+ Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/Makefile b/Makefile
+index 7ddfa31..cd60319 100644
+--- a/Makefile
++++ b/Makefile
+@@ -48,7 +48,7 @@ LIBFROG_SUBDIR = libfrog
+ DLIB_SUBDIRS = libxlog libxcmd libhandle
+ LIB_SUBDIRS = libxfs $(DLIB_SUBDIRS)
+ TOOL_SUBDIRS = copy db estimate fsck growfs io logprint mkfs quota \
+-		mdrestore repair rtcp m4 man doc debian spaceman scrub
++		mdrestore repair rtcp m4 man doc debian spaceman
+ 
+ ifneq ("$(PKG_PLATFORM)","darwin")
+ TOOL_SUBDIRS += fsr
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/xfsprogs_4.14.0.bb b/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/xfsprogs_4.14.0.bb
deleted file mode 100644
index 5d76afe..0000000
--- a/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/xfsprogs_4.14.0.bb
+++ /dev/null
@@ -1,63 +0,0 @@
-SUMMARY = "XFS Filesystem Utilities"
-HOMEPAGE = "http://oss.sgi.com/projects/xfs"
-SECTION = "base"
-LICENSE = "GPLv2 & LGPLv2.1"
-LICENSE_libhandle = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://doc/COPYING;md5=102f7fec3d53c7c8f0b7baf9bf9d76a8"
-DEPENDS = "util-linux util-linux-native"
-SRC_URI = "https://www.kernel.org/pub/linux/utils/fs/xfs/xfsprogs/${BP}.tar.xz \
-           file://remove_flags_from_build_flags.patch \
-           file://0001-build-Check-for-sync_file_range-libc-function.patch \
-           "
-SRC_URI[md5sum] = "2d50e3751cc98e6c9364bc3d2297b9fd"
-SRC_URI[sha256sum] = "b1b710b268bc95d6f45eca06e1262c29eb38865a19cd4404e48ba446e043b7ec"
-
-inherit autotools-brokensep
-
-PACKAGES =+ "${PN}-fsck ${PN}-mkfs ${PN}-repair libhandle"
-
-DEPENDS += "util-linux"
-
-RDEPENDS_${PN} = "${PN}-fsck ${PN}-mkfs ${PN}-repair"
-
-FILES_${PN}-fsck = "${base_sbindir}/fsck.xfs"
-FILES_${PN}-mkfs = "${base_sbindir}/mkfs.xfs"
-FILES_${PN}-repair = "${base_sbindir}/xfs_repair"
-
-FILES_libhandle = "${base_libdir}/libhandle${SOLIBS}"
-
-EXTRA_OECONF = "--enable-gettext=no \
-                INSTALL_USER=root \
-                INSTALL_GROUP=root \
-                ac_cv_header_aio_h=yes \
-                ac_cv_lib_rt_lio_listio=yes \
-"
-
-DISABLE_STATIC = ""
-EXTRA_AUTORECONF += "-I ${S}/m4 --exclude=autoheader"
-
-PACKAGECONFIG ??= "readline blkid"
-
-PACKAGECONFIG[readline] = "--enable-readline=yes,--enable-readline=no,readline"
-PACKAGECONFIG[blkid] = "--enable-blkid=yes,--enable-blkid=no,util-linux"
-
-export DEBUG="-DNDEBUG"
-export BUILD_VERBOSE="1"
-export tagname="CC"
-
-EXTRA_OEMAKE = "DIST_ROOT='${D}'"
-
-do_configure_prepend () {
-    export BUILD_CC="${BUILD_CC} ${BUILD_CFLAGS}"
-    # Prevent Makefile from calling configure without arguments,
-    # when do_configure gets called for a second time.
-    rm -f ${B}/include/builddefs ${B}/include/platform_defs.h ${B}/configure
-    # Recreate configure script.
-    oe_runmake configure
-}
-
-do_install_append() {
-        oe_runmake 'DESTDIR=${D}' install-dev
-        rm ${D}${libdir}/*.la
-        rmdir --ignore-fail-on-non-empty ${D}${libdir}
-}
diff --git a/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/xfsprogs_4.18.0.bb b/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/xfsprogs_4.18.0.bb
new file mode 100644
index 0000000..0a1bacb
--- /dev/null
+++ b/meta-openembedded/meta-filesystems/recipes-utils/xfsprogs/xfsprogs_4.18.0.bb
@@ -0,0 +1,68 @@
+SUMMARY = "XFS Filesystem Utilities"
+HOMEPAGE = "http://oss.sgi.com/projects/xfs"
+SECTION = "base"
+LICENSE = "GPLv2 & LGPLv2.1"
+LICENSE_libhandle = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://LICENSES/GPL-2.0;md5=74274e8a218423e49eefdea80bc55038 \
+                    file://LICENSES/LGPL-2.1;md5=b370887980db5dd40659b50909238dbd"
+DEPENDS = "util-linux util-linux-native"
+SRC_URI = "https://www.kernel.org/pub/linux/utils/fs/xfs/xfsprogs/${BP}.tar.xz \
+           file://remove_flags_from_build_flags.patch \
+           file://0001-build-Check-for-sync_file_range-libc-function.patch \
+           file://disable-xfs_scrub-build.patch \
+           file://0001-Check-for-MAP_SYNC-in-sys-mman.h.patch \
+           file://0002-include-include-xfs-linux.h-after-sys-mman.h.patch \
+           "
+SRC_URI[md5sum] = "5f80b631b68df89a8b9283307e96d2e8"
+SRC_URI[sha256sum] = "397dc96f51aeeff73d021d3418d3172377b2685f2740ca60525096c070aa3df1"
+
+inherit autotools-brokensep
+
+PACKAGES =+ "${PN}-fsck ${PN}-mkfs ${PN}-repair libhandle"
+
+DEPENDS += "util-linux"
+
+RDEPENDS_${PN} = "${PN}-fsck ${PN}-mkfs ${PN}-repair"
+
+FILES_${PN}-fsck = "${base_sbindir}/fsck.xfs"
+FILES_${PN}-mkfs = "${base_sbindir}/mkfs.xfs"
+FILES_${PN}-repair = "${base_sbindir}/xfs_repair"
+
+FILES_libhandle = "${base_libdir}/libhandle${SOLIBS}"
+
+EXTRA_OECONF = "--enable-gettext=no \
+                INSTALL_USER=root \
+                INSTALL_GROUP=root \
+                ac_cv_header_aio_h=yes \
+                ac_cv_lib_rt_lio_listio=yes \
+"
+
+DISABLE_STATIC = ""
+EXTRA_AUTORECONF += "-I ${S}/m4 --exclude=autoheader"
+
+PACKAGECONFIG ??= "readline blkid"
+
+PACKAGECONFIG[readline] = "--enable-readline=yes,--enable-readline=no,readline"
+PACKAGECONFIG[blkid] = "--enable-blkid=yes,--enable-blkid=no,util-linux"
+
+export DEBUG="-DNDEBUG"
+export BUILD_VERBOSE="1"
+export tagname="CC"
+
+EXTRA_OEMAKE = "DIST_ROOT='${D}'"
+
+do_configure () {
+    export BUILD_CC="${BUILD_CC} ${BUILD_CFLAGS}"
+    # Prevent Makefile from calling configure without arguments,
+    # when do_configure gets called for a second time.
+    rm -f ${B}/include/builddefs ${B}/include/platform_defs.h ${B}/configure
+    # Recreate configure script.
+    oe_runmake configure
+    oe_runconf
+}
+
+do_install_append() {
+        oe_runmake 'DESTDIR=${D}' install-dev
+        rm ${D}${libdir}/*.la
+        rmdir --ignore-fail-on-non-empty ${D}${libdir}
+}
diff --git a/meta-openembedded/meta-gnome/README b/meta-openembedded/meta-gnome/README
index 2a682e7..84d4f73 100644
--- a/meta-openembedded/meta-gnome/README
+++ b/meta-openembedded/meta-gnome/README
@@ -23,16 +23,16 @@
 This layer depends on:
 
 URI: git://github.com/openembedded/oe-core.git
-branch: master
+branch: thud
 revision: HEAD
 
 URI: git://github.com/openembedded/meta-oe.git
-branch: master
+branch: thud
 revision: HEAD
 
-Send pull requests to openembedded-devel@lists.openembedded.org with '[meta-gnome]' in the subject'
+Send pull requests to openembedded-devel@lists.openembedded.org with '[meta-gnome][thud]' in the subject'
 
 When sending single patches, please using something like:
-'git send-email -M -1 --to openembedded-devel@lists.openembedded.org --subject-prefix=meta-gnome][PATCH'
+'git send-email -M -1 --to openembedded-devel@lists.openembedded.org --subject-prefix=meta-gnome][thud][PATCH'
 
-Layer maintainer: Andreas Müller <schnitzeltony@googlemail.com>
+Thud maintainer: Armin Kuster <akuster808@gmail.com>
diff --git a/meta-openembedded/meta-gnome/conf/layer.conf b/meta-openembedded/meta-gnome/conf/layer.conf
index e6e9532..e9d0785 100644
--- a/meta-openembedded/meta-gnome/conf/layer.conf
+++ b/meta-openembedded/meta-gnome/conf/layer.conf
@@ -14,7 +14,7 @@
 
 LAYERDEPENDS_gnome-layer = "core openembedded-layer networking-layer"
 
-LAYERSERIES_COMPAT_gnome-layer = "sumo"
+LAYERSERIES_COMPAT_gnome-layer = "thud"
 
 # Sanity check for meta-gnome layer.
 # Setting SKIP_META_GNOME_SANITY_CHECK to "1" would skip the bbappend files check.
diff --git a/meta-openembedded/meta-gnome/recipes-connectivity/network-manager-applet/network-manager-applet_1.8.10.bb b/meta-openembedded/meta-gnome/recipes-connectivity/network-manager-applet/network-manager-applet_1.8.10.bb
deleted file mode 100644
index dc2b964..0000000
--- a/meta-openembedded/meta-gnome/recipes-connectivity/network-manager-applet/network-manager-applet_1.8.10.bb
+++ /dev/null
@@ -1,45 +0,0 @@
-SUMMARY = "GTK+ applet for NetworkManager"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552"
-
-DEPENDS = "gtk+3 libnotify libsecret networkmanager dbus-glib \
-           gconf libgnome-keyring iso-codes nss \
-           intltool-native \
-"
-
-inherit distro_features_check gnomebase gsettings gtk-icon-cache gobject-introspection
-
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI[archive.md5sum] = "eae3be75e77ff1a7ea3174be25e62d03"
-SRC_URI[archive.sha256sum] = "0adc4bfae8b49f7a1d929c22ef20933bd41fb4a8b458280f44c65f9e45b4c9c3"
-
-PACKAGECONFIG[modemmanager] = "--with-wwan,--without-wwan,modemmanager"
-PACKAGECONFIG ??= ""
-
-EXTRA_OECONF = " \
-    --without-selinux \
-"
-
-do_configure_append() {
-    # Sigh... --enable-compile-warnings=no doesn't actually turn off -Werror
-    for i in $(find ${B} -name "Makefile") ; do
-        sed -i -e s%-Werror[^[:space:]]*%%g $i
-    done
-}
-
-# gobject-introspection related
-GI_DATA_ENABLED_libc-musl = "False"
-
-do_compile_prepend() {
-    export GIR_EXTRA_LIBS_PATH="${B}/src/libnma/.libs:${B}/src/libnm-gtk/.libs"
-}
-
-RDEPENDS_${PN} =+ "networkmanager"
-
-FILES_${PN} += " \
-    ${datadir}/appdata \
-    ${datadir}/nm-applet/ \
-    ${datadir}/libnm-gtk/wifi.ui \
-    ${datadir}/libnma/wifi.ui \
-"
diff --git a/meta-openembedded/meta-gnome/recipes-connectivity/network-manager-applet/network-manager-applet_1.8.18.bb b/meta-openembedded/meta-gnome/recipes-connectivity/network-manager-applet/network-manager-applet_1.8.18.bb
new file mode 100644
index 0000000..0184000
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-connectivity/network-manager-applet/network-manager-applet_1.8.18.bb
@@ -0,0 +1,52 @@
+SUMMARY = "GTK+ applet for NetworkManager"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552"
+
+DEPENDS = "gtk+3 libnotify libsecret networkmanager dbus-glib \
+           gconf libgnome-keyring iso-codes nss \
+           intltool-native \
+"
+
+GNOMEBASEBUILDCLASS = "autotools-brokensep"
+inherit distro_features_check gnomebase gsettings gtk-icon-cache gobject-introspection
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI[archive.md5sum] = "34923579b39360db64649342ee6735d8"
+SRC_URI[archive.sha256sum] = "23dc1404f1e0622b7c4718b6d978b101d5e4d9be0b92133b3863a4dc29786178"
+
+PACKAGECONFIG[modemmanager] = "--with-wwan,--without-wwan,modemmanager"
+PACKAGECONFIG[mobile-provider-info] = "--enable-mobile-broadband-provider-info,--disable-mobile-broadband-provider-info,mobile-broadband-provider-info,mobile-broadband-provider-info"
+PACKAGECONFIG ??= ""
+
+EXTRA_OECONF = " \
+    --without-selinux \
+"
+
+do_configure_append() {
+    # Sigh... --enable-compile-warnings=no doesn't actually turn off -Werror
+    for i in $(find ${B} -name "Makefile") ; do
+        sed -i -e s%-Werror[^[:space:]]*%%g $i
+    done
+}
+
+# gobject-introspection related
+GI_DATA_ENABLED_libc-musl = "False"
+
+do_compile_prepend() {
+    export GIR_EXTRA_LIBS_PATH="${B}/src/libnma/.libs:${B}/src/libnm-gtk/.libs"
+}
+
+RDEPENDS_${PN} =+ "networkmanager"
+
+FILES_${PN} += " \
+    ${datadir}/nm-applet/ \
+    ${datadir}/libnm-gtk/wifi.ui \
+    ${datadir}/libnma/wifi.ui \
+    ${datadir}/metainfo \
+"
+
+# musl builds generate gir files which otherwise go un-packaged
+FILES_${PN}-dev += " \
+    ${datadir}/gir-1.0 \
+"
diff --git a/meta-openembedded/meta-gnome/recipes-connectivity/networkmanager/networkmanager_%.bbappend b/meta-openembedded/meta-gnome/recipes-connectivity/networkmanager/networkmanager_%.bbappend
new file mode 100644
index 0000000..291a616
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-connectivity/networkmanager/networkmanager_%.bbappend
@@ -0,0 +1,3 @@
+# networkmanager-applet requires glib support
+PACKAGECONFIG_append = "glib"
+
diff --git a/meta-openembedded/meta-gnome/recipes-connectivity/obex/obexd/ssize_t_definition.patch b/meta-openembedded/meta-gnome/recipes-connectivity/obex/obexd/ssize_t_definition.patch
deleted file mode 100644
index 570cb9e..0000000
--- a/meta-openembedded/meta-gnome/recipes-connectivity/obex/obexd/ssize_t_definition.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From fb5056fea9559b3ec3bb61967a112b6c793b700d Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 8 Jan 2013 21:33:34 -0800
-Subject: [PATCH] include unistd.h to get ssize_t definitions
-
-Fixes errors like
-
-| In file included from plugins/mas.c:36:0:
-| ./src/obex.h:39:1: error: unknown type name 'ssize_t'
-| ./src/obex.h:49:1: error: unknown type name 'ssize_t'
-| ./src/obex.h:50:1: error: unknown type name 'ssize_t'
-| In file included from plugins/mas.c:38:0:
-| ./src/mimetype.h:36:2: error: expected specifier-qualifier-list before 'ssize_t'
-| In file included from plugins/mas.c:39:0:
-| plugins/filesystem.h:24:1: error: unknown type name 'ssize_t'
-| plugins/mas.c:550:1: error: unknown type name 'ssize_t'
-| plugins/mas.c:557:1: error: unknown type name 'ssize_t'
-| plugins/mas.c: In function 'any_read':
-| plugins/mas.c:560:2: error: unknown type name 'ssize_t'
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
----
- plugins/mas.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/plugins/mas.c b/plugins/mas.c
-index 1b18059..b519507 100644
---- a/plugins/mas.c
-+++ b/plugins/mas.c
-@@ -30,6 +30,7 @@
- #include <glib.h>
- #include <fcntl.h>
- #include <inttypes.h>
-+#include <unistd.h>
- 
- #include <gobex/gobex.h>
- #include <gobex/gobex-apparam.h>
diff --git a/meta-openembedded/meta-gnome/recipes-connectivity/obex/obexd_0.48.bb b/meta-openembedded/meta-gnome/recipes-connectivity/obex/obexd_0.48.bb
deleted file mode 100644
index 6096bed..0000000
--- a/meta-openembedded/meta-gnome/recipes-connectivity/obex/obexd_0.48.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-SUMMARY = "OBEX Server and Client"
-# obexd was integrated into bluez5
-DEPENDS = "glib-2.0 dbus libical"
-DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES','bluez5','bluez5','bluez4',d)}"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e"
-
-SRC_URI = "http://www.kernel.org/pub/linux/bluetooth/obexd-${PV}.tar.gz \
-           file://ssize_t_definition.patch \
-"
-SRC_URI[md5sum] = "d03cf9bad2983243837f4f6d76ef14a6"
-SRC_URI[sha256sum] = "eaa9d8d9542700e6750918d72a3ce00f8cf3a2771d3e2516efd1be5a05f78582"
-
-inherit autotools-brokensep pkgconfig
-
-PACKAGES =+ "obex-client obex-plugins"
-
-FILES_${PN} += "${datadir}/dbus-1/services/${PN}.service"
-FILES_obex-client = "${libexecdir}/obex-client \
-                     ${datadir}/dbus-1/services/obex-client.service"
-# currently the plugins are empty
-FILES_obex-plugins = "${libdir}/obex/plugins"
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/abiword/abiword/0001-Bug-13770-Require-C-11-from-now-on.patch b/meta-openembedded/meta-gnome/recipes-gnome/abiword/abiword/0001-Bug-13770-Require-C-11-from-now-on.patch
new file mode 100644
index 0000000..3731a23
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-gnome/abiword/abiword/0001-Bug-13770-Require-C-11-from-now-on.patch
@@ -0,0 +1,180 @@
+From f6d0dc338fe867c1b064682ae7f15bffe019b306 Mon Sep 17 00:00:00 2001
+From: Hubert Figuiere <hub@figuiere.net>
+Date: Tue, 12 Apr 2016 02:55:47 +0000
+Subject: [PATCH] Bug 13770 - Require C++11 from now on.
+
+git-svn-id: svn+ssh://svn.abisource.com/svnroot/abiword/trunk@35197 bcba8976-2d24-0410-9c9c-aab3bd5fdfd6
+
+Upstream-Status: Backport
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ ax_cxx_compile_stdcxx_11.m4  | 133 +++++++++++++++++++++++++++++++++++
+ configure.ac                 |   1 +
+ src/wp/ap/gtk/ap_UnixApp.cpp |   2 +-
+ 3 files changed, 135 insertions(+), 1 deletion(-)
+ create mode 100644 ax_cxx_compile_stdcxx_11.m4
+
+diff --git a/ax_cxx_compile_stdcxx_11.m4 b/ax_cxx_compile_stdcxx_11.m4
+new file mode 100644
+index 0000000..af37acd
+--- /dev/null
++++ b/ax_cxx_compile_stdcxx_11.m4
+@@ -0,0 +1,133 @@
++# ============================================================================
++#  http://www.gnu.org/software/autoconf-archive/ax_cxx_compile_stdcxx_11.html
++# ============================================================================
++#
++# SYNOPSIS
++#
++#   AX_CXX_COMPILE_STDCXX_11([ext|noext],[mandatory|optional])
++#
++# DESCRIPTION
++#
++#   Check for baseline language coverage in the compiler for the C++11
++#   standard; if necessary, add switches to CXXFLAGS to enable support.
++#
++#   The first argument, if specified, indicates whether you insist on an
++#   extended mode (e.g. -std=gnu++11) or a strict conformance mode (e.g.
++#   -std=c++11).  If neither is specified, you get whatever works, with
++#   preference for an extended mode.
++#
++#   The second argument, if specified 'mandatory' or if left unspecified,
++#   indicates that baseline C++11 support is required and that the macro
++#   should error out if no mode with that support is found.  If specified
++#   'optional', then configuration proceeds regardless, after defining
++#   HAVE_CXX11 if and only if a supporting mode is found.
++#
++# LICENSE
++#
++#   Copyright (c) 2008 Benjamin Kosnik <bkoz@redhat.com>
++#   Copyright (c) 2012 Zack Weinberg <zackw@panix.com>
++#   Copyright (c) 2013 Roy Stogner <roystgnr@ices.utexas.edu>
++#
++#   Copying and distribution of this file, with or without modification, are
++#   permitted in any medium without royalty provided the copyright notice
++#   and this notice are preserved. This file is offered as-is, without any
++#   warranty.
++
++#serial 3
++
++m4_define([_AX_CXX_COMPILE_STDCXX_11_testbody], [
++  template <typename T>
++    struct check
++    {
++      static_assert(sizeof(int) <= sizeof(T), "not big enough");
++    };
++
++    typedef check<check<bool>> right_angle_brackets;
++
++    int a;
++    decltype(a) b;
++
++    typedef check<int> check_type;
++    check_type c;
++    check_type&& cr = static_cast<check_type&&>(c);
++
++    auto d = a;
++])
++
++AC_DEFUN([AX_CXX_COMPILE_STDCXX_11], [dnl
++  m4_if([$1], [], [],
++        [$1], [ext], [],
++        [$1], [noext], [],
++        [m4_fatal([invalid argument `$1' to AX_CXX_COMPILE_STDCXX_11])])dnl
++  m4_if([$2], [], [ax_cxx_compile_cxx11_required=true],
++        [$2], [mandatory], [ax_cxx_compile_cxx11_required=true],
++        [$2], [optional], [ax_cxx_compile_cxx11_required=false],
++        [m4_fatal([invalid second argument `$2' to AX_CXX_COMPILE_STDCXX_11])])dnl
++  AC_LANG_PUSH([C++])dnl
++  ac_success=no
++  AC_CACHE_CHECK(whether $CXX supports C++11 features by default,
++  ax_cv_cxx_compile_cxx11,
++  [AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_11_testbody])],
++    [ax_cv_cxx_compile_cxx11=yes],
++    [ax_cv_cxx_compile_cxx11=no])])
++  if test x$ax_cv_cxx_compile_cxx11 = xyes; then
++    ac_success=yes
++  fi
++
++  m4_if([$1], [noext], [], [dnl
++  if test x$ac_success = xno; then
++    for switch in -std=gnu++11 -std=gnu++0x; do
++      cachevar=AS_TR_SH([ax_cv_cxx_compile_cxx11_$switch])
++      AC_CACHE_CHECK(whether $CXX supports C++11 features with $switch,
++                     $cachevar,
++        [ac_save_CXXFLAGS="$CXXFLAGS"
++         CXXFLAGS="$CXXFLAGS $switch"
++         AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_11_testbody])],
++          [eval $cachevar=yes],
++          [eval $cachevar=no])
++         CXXFLAGS="$ac_save_CXXFLAGS"])
++      if eval test x\$$cachevar = xyes; then
++        CXXFLAGS="$CXXFLAGS $switch"
++        ac_success=yes
++        break
++      fi
++    done
++  fi])
++
++  m4_if([$1], [ext], [], [dnl
++  if test x$ac_success = xno; then
++    for switch in -std=c++11 -std=c++0x; do
++      cachevar=AS_TR_SH([ax_cv_cxx_compile_cxx11_$switch])
++      AC_CACHE_CHECK(whether $CXX supports C++11 features with $switch,
++                     $cachevar,
++        [ac_save_CXXFLAGS="$CXXFLAGS"
++         CXXFLAGS="$CXXFLAGS $switch"
++         AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_11_testbody])],
++          [eval $cachevar=yes],
++          [eval $cachevar=no])
++         CXXFLAGS="$ac_save_CXXFLAGS"])
++      if eval test x\$$cachevar = xyes; then
++        CXXFLAGS="$CXXFLAGS $switch"
++        ac_success=yes
++        break
++      fi
++    done
++  fi])
++  AC_LANG_POP([C++])
++  if test x$ax_cxx_compile_cxx11_required = xtrue; then
++    if test x$ac_success = xno; then
++      AC_MSG_ERROR([*** A compiler with support for C++11 language features is required.])
++    fi
++  else
++    if test x$ac_success = xno; then
++      HAVE_CXX11=0
++      AC_MSG_NOTICE([No compiler with C++11 support was found])
++    else
++      HAVE_CXX11=1
++      AC_DEFINE(HAVE_CXX11,1,
++                [define if the compiler supports basic C++11 syntax])
++    fi
++
++    AC_SUBST(HAVE_CXX11)
++  fi
++])
+diff --git a/configure.ac b/configure.ac
+index 48228be..f7be7de 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -131,6 +131,7 @@ win_pkgs="$enchant_req"
+ 
+ AC_PROG_CC
+ AC_PROG_CXX
++AX_CXX_COMPILE_STDCXX_11(noext,mandatory)
+ #AC_PROG_OBJC
+ AC_PROG_INSTALL
+ # For libtool 1.5.x compatability (AC_PROG_LIBTOOL is deprecated version of LT_INIT)
+diff --git a/src/wp/ap/gtk/ap_UnixApp.cpp b/src/wp/ap/gtk/ap_UnixApp.cpp
+index 061a304..260f8e5 100644
+--- a/src/wp/ap/gtk/ap_UnixApp.cpp
++++ b/src/wp/ap/gtk/ap_UnixApp.cpp
+@@ -863,7 +863,7 @@ static bool is_so (const char *file) {
+ 	if (len < (strlen(G_MODULE_SUFFIX) + 2)) // this is ".so" and at least one char for the filename
+ 		return false;
+ 	const char *suffix = file+(len-3);
+-	if(0 == strcmp (suffix, "."G_MODULE_SUFFIX))
++	if(0 == strcmp (suffix, "." G_MODULE_SUFFIX))
+ 		return true;
+ 	return false;
+ }
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/abiword/abiword_3.0.2.bb b/meta-openembedded/meta-gnome/recipes-gnome/abiword/abiword_3.0.2.bb
index d2c0186..36b056f 100644
--- a/meta-openembedded/meta-gnome/recipes-gnome/abiword/abiword_3.0.2.bb
+++ b/meta-openembedded/meta-gnome/recipes-gnome/abiword/abiword_3.0.2.bb
@@ -8,7 +8,7 @@
     gtk+ \
     gtkmathview \
     wv \
-    libfribidi \
+    fribidi \
     jpeg \
     libpng \
     librsvg \
@@ -24,10 +24,10 @@
 "
 RCONFLICTS_${PN} = "${PN}-embedded"
 
-SRC_URI = " \
-    http://www.abisource.com/downloads/${BPN}/${PV}/source/${BP}.tar.gz \
-    file://0001-plugins-aiksaurus-Makefile.am-remove-uncomplete-opti.patch \
-"
+SRC_URI = "http://www.abisource.com/downloads/${BPN}/${PV}/source/${BP}.tar.gz \
+           file://0001-plugins-aiksaurus-Makefile.am-remove-uncomplete-opti.patch \
+           file://0001-Bug-13770-Require-C-11-from-now-on.patch \
+           "
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=c5edcc3ccd864b19004d14e9c1c9a26a"
 
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/dconf/dconf-editor_3.28.0.bb b/meta-openembedded/meta-gnome/recipes-gnome/dconf/dconf-editor_3.28.0.bb
new file mode 100644
index 0000000..70f917e
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-gnome/dconf/dconf-editor_3.28.0.bb
@@ -0,0 +1,17 @@
+SUMMARY = "Configuration editor for dconf"
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=1ebbd3e34237af26da5dc08a4e440464"
+
+GNOMEBASEBUILDCLASS = "meson"
+
+DEPENDS = "dconf gtk+3"
+
+inherit gnomebase vala gettext gsettings bash-completion
+
+SRC_URI[archive.md5sum] = "cc9eb8020cc848812972d8519c3d05cf"
+SRC_URI[archive.sha256sum] = "455b53d827820efd28a176ee52e13eda5cda8cdf4e31e0145cfdd69931bf0c5a"
+
+FILES_${PN} += " \
+    ${datadir}/dbus-1 \
+    ${datadir}/metainfo \
+"
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/dconf/dconf_0.18.0.bb b/meta-openembedded/meta-gnome/recipes-gnome/dconf/dconf_0.18.0.bb
deleted file mode 100644
index e24bde4..0000000
--- a/meta-openembedded/meta-gnome/recipes-gnome/dconf/dconf_0.18.0.bb
+++ /dev/null
@@ -1,36 +0,0 @@
-SUMMARY = "configuation database system"
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=2d5025d4aa3495befef8f17206a5b0a1"
-
-SECTION = "x11/gnome"
-
-inherit gnomebase gsettings
-SRC_URI[archive.md5sum] = "69a12ed68893f2e1e81ac4e531bc1515"
-SRC_URI[archive.sha256sum] = "109b1bc6078690af1ed88cb144ef5c5aee7304769d8bdc82ed48c3696f10c955"
-GNOME_COMPRESS_TYPE = "xz"
-
-DEPENDS = "dbus glib-2.0 libxml2 intltool-native"
-
-inherit vala gtk-doc distro_features_check
-
-PACKAGECONFIG ??= "${@bb.utils.contains("DISTRO_FEATURES", "x11", "editor", "", d)}"
-
-#note: editor will be removed in version 0.23.1
-PACKAGECONFIG[editor] = "--enable-editor,--disable-editor,gtk+3"
-
-REQUIRED_DISTRO_FEATURES = "${@bb.utils.contains("PACKAGECONFIG", "editor", "x11", "", d)}"
-
-EXTRA_OECONF += "--disable-man"
-
-PACKAGES =+ "${@bb.utils.contains("DISTRO_FEATURES", "x11", "dconf-editor", "", d)}"
-
-FILES_${PN} += " \
-    ${datadir}/dbus-1 \
-    ${libdir}/gio/modules/*.so \
-    ${datadir}/bash-completion \
-"
-FILES_dconf-editor = " \
-    ${bindir}/dconf-editor \
-    ${datadir}/icons \
-"
-FILES_${PN}-dbg += "${libdir}/gio/modules/.debug/libdconfsettings.so"
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/dconf/dconf_0.28.0.bb b/meta-openembedded/meta-gnome/recipes-gnome/dconf/dconf_0.28.0.bb
new file mode 100644
index 0000000..99292a8
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-gnome/dconf/dconf_0.28.0.bb
@@ -0,0 +1,18 @@
+SUMMARY = "configuation database system"
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=2d5025d4aa3495befef8f17206a5b0a1"
+SECTION = "x11/gnome"
+
+SRC_URI[archive.md5sum] = "81faa8e68e5ea71ff0ee75050fc0759c"
+SRC_URI[archive.sha256sum] = "61d3b3865ef58b729c3b39aa0979f886c014aa8362f93dcfc74bf5648ed9c742"
+
+DEPENDS = "dbus glib-2.0 intltool-native"
+
+GNOMEBASEBUILDCLASS = "meson"
+
+inherit gnomebase gsettings bash-completion vala
+
+FILES_${PN} += " \
+    ${datadir}/dbus-1 \
+    ${libdir}/gio/modules/*.so \
+"
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/eds/evolution-data-server/0004-Use-recommended-way-to-handle-the-icu-namespace.patch b/meta-openembedded/meta-gnome/recipes-gnome/eds/evolution-data-server/0004-Use-recommended-way-to-handle-the-icu-namespace.patch
new file mode 100644
index 0000000..d3b0ac6
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-gnome/eds/evolution-data-server/0004-Use-recommended-way-to-handle-the-icu-namespace.patch
@@ -0,0 +1,46 @@
+From 698a0e104dcbe4b630df848fd4af7c59f76cdc37 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 5 May 2018 17:46:52 -0700
+Subject: [PATCH] Use recommended way to handle the icu namespace
+
+Fixes build with icu >= 61
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/libedataserver/e-alphabet-index-private.cpp | 2 ++
+ src/libedataserver/e-transliterator-private.cpp | 2 ++
+ 2 files changed, 4 insertions(+)
+
+diff --git a/src/libedataserver/e-alphabet-index-private.cpp b/src/libedataserver/e-alphabet-index-private.cpp
+index d3e44f4..ddffd99 100644
+--- a/src/libedataserver/e-alphabet-index-private.cpp
++++ b/src/libedataserver/e-alphabet-index-private.cpp
+@@ -33,9 +33,11 @@
+ 
+ /* ICU headers */
+ #include <unicode/alphaindex.h>
++#include <unicode/ustring.h>
+ 
+ using icu::AlphabeticIndex;
+ using icu::Locale;
++using U_ICU_NAMESPACE::UnicodeString;
+ 
+ struct _EAlphabetIndex {
+ 	AlphabeticIndex *priv;
+diff --git a/src/libedataserver/e-transliterator-private.cpp b/src/libedataserver/e-transliterator-private.cpp
+index bb15593..573446f 100644
+--- a/src/libedataserver/e-transliterator-private.cpp
++++ b/src/libedataserver/e-transliterator-private.cpp
+@@ -33,8 +33,10 @@
+ 
+ /* ICU headers */
+ #include <unicode/translit.h>
++#include <unicode/ustring.h>
+ 
+ using icu::Transliterator;
++using U_ICU_NAMESPACE::UnicodeString;
+ 
+ struct _ETransliterator {
+ 	Transliterator *priv;
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/eds/evolution-data-server_3.26.3.bb b/meta-openembedded/meta-gnome/recipes-gnome/eds/evolution-data-server_3.26.3.bb
deleted file mode 100644
index 2303b8f..0000000
--- a/meta-openembedded/meta-gnome/recipes-gnome/eds/evolution-data-server_3.26.3.bb
+++ /dev/null
@@ -1,130 +0,0 @@
-SUMMARY = "Evolution database backend server"
-HOMEPAGE = "http://www.gnome.org/projects/evolution/"
-BUGTRACKER = "https://bugzilla.gnome.org/"
-
-LICENSE = "LGPLv2 & LGPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=6a6e689d19255cf0557f3fe7d7068212 \
-                    file://src/camel/camel.h;endline=24;md5=342fc5e9357254bc30c24e43ae47d9a1 \
-                    file://src/libedataserver/e-data-server-util.h;endline=20;md5=8f21a9c80ea82a4fb80b5f959f672543 \
-                    file://src/calendar/libecal/e-cal.h;endline=24;md5=e699ec3866f73f129f7a4ffffdcfc196"
-
-DEPENDS = " \
-    intltool-native gperf-native \
-    glib-2.0 gtk+3 gconf libgnome-keyring libgdata \
-    dbus db virtual/libiconv zlib libsoup-2.4 libical nss libsecret \
-"
-
-inherit distro_features_check gnomebase cmake gtk-doc gettext gobject-introspection perlnative pythonnative
-
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI += " \
-    file://0001-CMakeLists.txt-Remove-TRY_RUN-for-iconv.patch \
-    file://0002-CMakeLists.txt-remove-CHECK_C_SOURCE_RUNS-check.patch \
-    file://0003-contact-Replace-the-Novell-sample-contact-with-somet.patch \
-    file://iconv-detect.h \
-"
-SRC_URI[archive.md5sum] = "568a21a4df4e0ec985c849b38fc66908"
-SRC_URI[archive.sha256sum] = "63b1ae5f76be818862f455bf841b5ebb1ec3e1f4df6d3a16dc2be348b7e0a1c5"
-
-LKSTRFTIME = "HAVE_LKSTRFTIME=ON"
-LKSTRFTIME_libc-musl = "HAVE_LKSTRFTIME=OFF"
-
-EXTRA_OECMAKE = " \
-    -DWITH_KRB5=OFF \
-    -DENABLE_GOA=OFF \
-    -DENABLE_UOA=OFF \
-    -DENABLE_GOOGLE_AUTH=OFF \
-    -DENABLE_WEATHER=OFF \
-    -D${LKSTRFTIME} \
-"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[openldap] = "-DWITH_OPENLDAP=ON,-DWITH_OPENLDAP=OFF,openldap"
-
-EXTRA_OECONF = "--with-libdb=${STAGING_DIR_HOST}${prefix} \
-                --disable-nntp --disable-gtk-doc"
-
-# -ldb needs this on some platforms
-LDFLAGS += "-lpthread -lgmodule-2.0 -lgthread-2.0"
-
-do_configure_append () {
-    cp ${WORKDIR}/iconv-detect.h ${S}/src
-
-    # fix native perl shebang
-    sed -i 's:${STAGING_BINDIR_NATIVE}/perl-native:${bindir}:' ${B}/src/tools/addressbook-export/csv2vcard
-}
-
-do_compile_prepend() {
-    export GIR_EXTRA_LIBS_PATH="${B}/camel/.libs:${B}/libedataserver/.libs"
-}
-
-
-PACKAGES =+ "libcamel libcamel-dev libebook libebook-dev libecal libecal-dev \
-             libedata-book libedata-book-dev libedata-cal libedata-cal-dev \
-             libedataserver libedataserver-dev \
-             libedataserverui libedataserverui-dev"
-
-FILES_${PN} =+ "${systemd_user_unitdir} \
-                ${datadir}/dbus-1 \
-                ${datadir}/evolution-data-server-*/ui/"
-RDEPENDS_${PN} += "perl"
-
-FILES_${PN}-dev =+ "${libdir}/pkgconfig/evolution-data-server-*.pc"
-FILES_${PN}-dbg =+ "${libdir}/evolution-data-server*/camel-providers/.debug \
-                    ${libdir}/evolution-data-server*/calendar-backends/.debug \
-                    ${libdir}/evolution-data-server*/addressbook-backends/.debug \
-                    ${libdir}/evolution-data-server*/extensions/.debug/"
-
-RRECOMMENDS_${PN}-dev += "libecal-dev libebook-dev"
-
-FILES_libcamel = "${libdir}/libcamel-*.so.* \
-                  ${libdir}/libcamel-provider-*.so.* \
-                  ${libdir}/evolution-data-server*/camel-providers/*.so \
-                  ${libdir}/evolution-data-server*/camel-providers/*.urls"
-FILES_libcamel-dev = "${libdir}/libcamel-*.so ${libdir}/libcamel-provider-*.so \
-                      ${libdir}/pkgconfig/camel*pc \
-                      ${libdir}/evolution-data-server*/camel-providers/*.la \
-                      ${includedir}/evolution-data-server*/camel"
-
-FILES_libebook = "${libdir}/libebook-*.so.*"
-FILES_libebook-dev = "${libdir}/libebook-1.2.so \
-                      ${libdir}/pkgconfig/libebook-*.pc \
-                      ${includedir}/evolution-data-server*/libebook/*.h"
-RRECOMMENDS_libebook = "libedata-book"
-
-FILES_libecal = "${libdir}/libecal-*.so.* \
-                 ${datadir}/evolution-data-server-1.4/zoneinfo"
-FILES_libecal-dev = "${libdir}/libecal-*.so ${libdir}/pkgconfig/libecal-*.pc \
-                     ${includedir}/evolution-data-server*/libecal/*.h \
-                     ${includedir}/evolution-data-server*/libical/*.h"
-RRECOMMENDS_libecal = "libedata-cal tzdata"
-
-FILES_libedata-book = "${libexecdir}/e-addressbook-factory \
-                       ${datadir}/dbus-1/services/*.AddressBook.service \
-                       ${libdir}/libedata-book-*.so.* \
-                       ${libdir}/evolution-data-server-*/extensions/libebook*.so \
-                       ${datadir}/evolution-data-server-1.4/weather/Locations.xml"
-FILES_libedata-book-dev = "${libdir}/libedata-book-*.so \
-                           ${libdir}/pkgconfig/libedata-book-*.pc \
-                           ${libdir}/evolution-data-server-*/extensions/libebook*.la \
-                           ${includedir}/evolution-data-server-*/libedata-book"
-
-FILES_libedata-cal = "${libexecdir}/e-calendar-factory \
-                      ${datadir}/dbus-1/services/*.Calendar.service \
-                      ${libdir}/libedata-cal-*.so.* \
-                      ${libdir}/evolution-data-server-*/extensions/libecal*.so"
-FILES_libedata-cal-dev = "${libdir}/libedata-cal-*.so \
-                          ${libdir}/pkgconfig/libedata-cal-*.pc \
-                          ${includedir}/evolution-data-server-*/libedata-cal \
-                          ${libdir}/evolution-data-server-*/extensions/libecal*.la"
-
-FILES_libedataserver = "${libdir}/libedataserver-*.so.*"
-FILES_libedataserver-dev = "${libdir}/libedataserver-*.so \
-                            ${libdir}/pkgconfig/libedataserver-*.pc \
-                            ${includedir}/evolution-data-server-*/libedataserver/*.h"
-
-FILES_libedataserverui = "${libdir}/libedataserverui-*.so.* ${datadir}/evolution-data-server-1.4/glade/*.glade"
-FILES_libedataserverui-dev = "${libdir}/libedataserverui-*.so \
-                              ${libdir}/pkgconfig/libedataserverui-*.pc \
-                              ${includedir}/evolution-data-server-*/libedataserverui/*.h"
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/eds/evolution-data-server_3.26.6.bb b/meta-openembedded/meta-gnome/recipes-gnome/eds/evolution-data-server_3.26.6.bb
new file mode 100644
index 0000000..db5dca9
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-gnome/eds/evolution-data-server_3.26.6.bb
@@ -0,0 +1,131 @@
+SUMMARY = "Evolution database backend server"
+HOMEPAGE = "http://www.gnome.org/projects/evolution/"
+BUGTRACKER = "https://bugzilla.gnome.org/"
+
+LICENSE = "LGPLv2 & LGPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=6a6e689d19255cf0557f3fe7d7068212 \
+                    file://src/camel/camel.h;endline=24;md5=342fc5e9357254bc30c24e43ae47d9a1 \
+                    file://src/libedataserver/e-data-server-util.h;endline=20;md5=8f21a9c80ea82a4fb80b5f959f672543 \
+                    file://src/calendar/libecal/e-cal.h;endline=24;md5=e699ec3866f73f129f7a4ffffdcfc196"
+
+DEPENDS = " \
+    intltool-native gperf-native \
+    glib-2.0 gtk+3 gconf libgnome-keyring libgdata \
+    dbus db virtual/libiconv zlib libsoup-2.4 libical nss libsecret \
+"
+
+inherit distro_features_check gnomebase cmake gtk-doc gettext gobject-introspection perlnative pythonnative
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI = "${GNOME_MIRROR}/${GNOMEBN}/${@gnome_verdir("${PV}")}/${GNOMEBN}-${PV}.tar.${GNOME_COMPRESS_TYPE};name=archive \
+           file://0001-CMakeLists.txt-Remove-TRY_RUN-for-iconv.patch \
+           file://0002-CMakeLists.txt-remove-CHECK_C_SOURCE_RUNS-check.patch \
+           file://0003-contact-Replace-the-Novell-sample-contact-with-somet.patch \
+           file://iconv-detect.h \
+           file://0004-Use-recommended-way-to-handle-the-icu-namespace.patch \
+           "
+SRC_URI[archive.md5sum] = "ae7bbf543b2c3ff79af27e0edea5d472"
+SRC_URI[archive.sha256sum] = "e43aa1847ddc02965f560261ef88d18fb8704eddaa55555bf96b884a33e510ec"
+
+LKSTRFTIME = "HAVE_LKSTRFTIME=ON"
+LKSTRFTIME_libc-musl = "HAVE_LKSTRFTIME=OFF"
+
+EXTRA_OECMAKE = " \
+    -DWITH_KRB5=OFF \
+    -DENABLE_GOA=OFF \
+    -DENABLE_UOA=OFF \
+    -DENABLE_GOOGLE_AUTH=OFF \
+    -DENABLE_WEATHER=OFF \
+    -D${LKSTRFTIME} \
+"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[openldap] = "-DWITH_OPENLDAP=ON,-DWITH_OPENLDAP=OFF,openldap"
+
+EXTRA_OECONF = "--with-libdb=${STAGING_DIR_HOST}${prefix} \
+                --disable-nntp --disable-gtk-doc"
+
+# -ldb needs this on some platforms
+LDFLAGS += "-lpthread -lgmodule-2.0 -lgthread-2.0"
+
+do_configure_append () {
+    cp ${WORKDIR}/iconv-detect.h ${S}/src
+
+    # fix native perl shebang
+    sed -i 's:${STAGING_BINDIR_NATIVE}/perl-native:${bindir}:' ${B}/src/tools/addressbook-export/csv2vcard
+}
+
+do_compile_prepend() {
+    export GIR_EXTRA_LIBS_PATH="${B}/camel/.libs:${B}/libedataserver/.libs"
+}
+
+
+PACKAGES =+ "libcamel libcamel-dev libebook libebook-dev libecal libecal-dev \
+             libedata-book libedata-book-dev libedata-cal libedata-cal-dev \
+             libedataserver libedataserver-dev \
+             libedataserverui libedataserverui-dev"
+
+FILES_${PN} =+ "${systemd_user_unitdir} \
+                ${datadir}/dbus-1 \
+                ${datadir}/evolution-data-server-*/ui/"
+RDEPENDS_${PN} += "perl"
+
+FILES_${PN}-dev =+ "${libdir}/pkgconfig/evolution-data-server-*.pc"
+FILES_${PN}-dbg =+ "${libdir}/evolution-data-server*/camel-providers/.debug \
+                    ${libdir}/evolution-data-server*/calendar-backends/.debug \
+                    ${libdir}/evolution-data-server*/addressbook-backends/.debug \
+                    ${libdir}/evolution-data-server*/extensions/.debug/"
+
+RRECOMMENDS_${PN}-dev += "libecal-dev libebook-dev"
+
+FILES_libcamel = "${libdir}/libcamel-*.so.* \
+                  ${libdir}/libcamel-provider-*.so.* \
+                  ${libdir}/evolution-data-server*/camel-providers/*.so \
+                  ${libdir}/evolution-data-server*/camel-providers/*.urls"
+FILES_libcamel-dev = "${libdir}/libcamel-*.so ${libdir}/libcamel-provider-*.so \
+                      ${libdir}/pkgconfig/camel*pc \
+                      ${libdir}/evolution-data-server*/camel-providers/*.la \
+                      ${includedir}/evolution-data-server*/camel"
+
+FILES_libebook = "${libdir}/libebook-*.so.*"
+FILES_libebook-dev = "${libdir}/libebook-1.2.so \
+                      ${libdir}/pkgconfig/libebook-*.pc \
+                      ${includedir}/evolution-data-server*/libebook/*.h"
+RRECOMMENDS_libebook = "libedata-book"
+
+FILES_libecal = "${libdir}/libecal-*.so.* \
+                 ${datadir}/evolution-data-server-1.4/zoneinfo"
+FILES_libecal-dev = "${libdir}/libecal-*.so ${libdir}/pkgconfig/libecal-*.pc \
+                     ${includedir}/evolution-data-server*/libecal/*.h \
+                     ${includedir}/evolution-data-server*/libical/*.h"
+RRECOMMENDS_libecal = "libedata-cal tzdata"
+
+FILES_libedata-book = "${libexecdir}/e-addressbook-factory \
+                       ${datadir}/dbus-1/services/*.AddressBook.service \
+                       ${libdir}/libedata-book-*.so.* \
+                       ${libdir}/evolution-data-server-*/extensions/libebook*.so \
+                       ${datadir}/evolution-data-server-1.4/weather/Locations.xml"
+FILES_libedata-book-dev = "${libdir}/libedata-book-*.so \
+                           ${libdir}/pkgconfig/libedata-book-*.pc \
+                           ${libdir}/evolution-data-server-*/extensions/libebook*.la \
+                           ${includedir}/evolution-data-server-*/libedata-book"
+
+FILES_libedata-cal = "${libexecdir}/e-calendar-factory \
+                      ${datadir}/dbus-1/services/*.Calendar.service \
+                      ${libdir}/libedata-cal-*.so.* \
+                      ${libdir}/evolution-data-server-*/extensions/libecal*.so"
+FILES_libedata-cal-dev = "${libdir}/libedata-cal-*.so \
+                          ${libdir}/pkgconfig/libedata-cal-*.pc \
+                          ${includedir}/evolution-data-server-*/libedata-cal \
+                          ${libdir}/evolution-data-server-*/extensions/libecal*.la"
+
+FILES_libedataserver = "${libdir}/libedataserver-*.so.*"
+FILES_libedataserver-dev = "${libdir}/libedataserver-*.so \
+                            ${libdir}/pkgconfig/libedataserver-*.pc \
+                            ${includedir}/evolution-data-server-*/libedataserver/*.h"
+
+FILES_libedataserverui = "${libdir}/libedataserverui-*.so.* ${datadir}/evolution-data-server-1.4/glade/*.glade"
+FILES_libedataserverui-dev = "${libdir}/libedataserverui-*.so \
+                              ${libdir}/pkgconfig/libedataserverui-*.pc \
+                              ${includedir}/evolution-data-server-*/libedataserverui/*.h"
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/evince/evince/0001-add-a-formatting-attribute-check.patch b/meta-openembedded/meta-gnome/recipes-gnome/evince/evince/0001-add-a-formatting-attribute-check.patch
new file mode 100644
index 0000000..e87da90
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-gnome/evince/evince/0001-add-a-formatting-attribute-check.patch
@@ -0,0 +1,34 @@
+From ef170dda7fbab53682c9bc287dec93fa86130bc9 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 9 Sep 2018 21:49:59 -0700
+Subject: [PATCH] add a formatting attribute check
+
+Tell Clang that parameter is a printf style format using the
+attribute flag
+
+This helps in avoiding below warnings seen with clang
+
+unarr.c:106:22: error: format string is not a string literal
+[-Werror,-Wformat-nonliteral]
+|     vfprintf(stderr, msg, args);
+|                      ^~~
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ cut-n-paste/unarr/common/unarr.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/cut-n-paste/unarr/common/unarr.c b/cut-n-paste/unarr/common/unarr.c
+index 97ec92a..9e6e3ad 100644
+--- a/cut-n-paste/unarr/common/unarr.c
++++ b/cut-n-paste/unarr/common/unarr.c
+@@ -92,7 +92,7 @@ size_t ar_get_global_comment(ar_archive *ar, void *buffer, size_t count)
+     return ar->get_comment(ar, buffer, count);
+ }
+ 
+-void ar_log(const char *prefix, const char *file, int line, const char *msg, ...)
++void __attribute__((__format__ (__printf__, 4, 0))) ar_log(const char *prefix, const char *file, int line, const char *msg, ...)
+ {
+     va_list args;
+     va_start(args, msg);
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/evince/evince_3.24.0.bb b/meta-openembedded/meta-gnome/recipes-gnome/evince/evince_3.24.0.bb
deleted file mode 100644
index c7ecf2b..0000000
--- a/meta-openembedded/meta-gnome/recipes-gnome/evince/evince_3.24.0.bb
+++ /dev/null
@@ -1,66 +0,0 @@
-SUMMARY = "Evince is a document viewer for document formats like pdf, ps, djvu"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=96f2f8d5ee576a2163977938ea36fa7b"
-SECTION = "x11/office"
-DEPENDS = "gtk+3 libsecret ${@bb.utils.contains('DISTRO_FEATURES','x11','gnome-desktop3','',d)} poppler gstreamer1.0-plugins-base orc adwaita-icon-theme intltool-native gnome-common-native"
-PR = "r5"
-
-inherit gnome pkgconfig gtk-icon-cache gsettings gobject-introspection distro_features_check systemd
-
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI = "${GNOME_MIRROR}/${GNOMEBN}/${@gnome_verdir("${PV}")}/${GNOMEBN}-${PV}.tar.${GNOME_COMPRESS_TYPE};name=archive \
-           file://0001-help-remove-YELP-macro.patch \
-           file://0001-Add-format-attribute-to-_synctex_malloc.patch \
-           "
-SRC_URI[archive.md5sum] = "3fb65ff46de191dc49c481f1fc66201c"
-SRC_URI[archive.sha256sum] = "043895af7bbd6f1b57f9ab8778e78cf9c0af5dfcc347eaa94a17bf864c04dc8f"
-
-EXTRA_OECONF = " --enable-thumbnailer \
-"
-
-do_compile_prepend() {
-        export GIR_EXTRA_LIBS_PATH="${B}/libdocument/.libs"
-}
-
-
-do_install_append() {
-    install -d ${D}${datadir}/pixmaps
-    install -m 0755 ${S}/data/icons/48x48/apps/evince.png ${D}${datadir}/pixmaps/
-    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}
-    then
-        install -d ${D}${systemd_unitdir}/system
-        mv ${D}${systemd_user_unitdir}/evince.service ${D}${systemd_system_unitdir}/evince.service
-    else
-        rm -rf ${D}${libdir}/systemd/user/evince.service
-    fi
-    rmdir --ignore-fail-on-non-empty ${D}${systemd_user_unitdir}
-    rmdir --ignore-fail-on-non-empty ${D}${nonarch_libdir}/systemd
-    rmdir --ignore-fail-on-non-empty ${D}${nonarch_libdir}
-}
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[nautilus] = "--enable-nautilus,--disable-nautilus,nautilus"
-PACKAGECONFIG[browser-plugin] = "--enable-browser-plugin,--disable-browser-plugin,"
-
-SYSTEMD_SERVICE_${PN} = "evince.service"
-
-RDEPENDS_${PN} += "glib-2.0-utils"
-RRECOMMMENDS_${PN} = "adwaita-icon-theme"
-
-PACKAGES =+ "${PN}-nautilus-extension"
-PACKAGES =+ "${PN}-browser-plugin"
-
-FILES_${PN} += "${datadir}/dbus-1 \
-                ${datadir}/appdata \
-                ${datadir}/thumbnailers \
-                ${systemd_unitdir}/systemd/user/evince.service \
-               "
-FILES_${PN}-dbg += "${libdir}/*/*/.debug \
-                    ${libdir}/*/*/*/.debug"
-FILES_${PN}-dev += "${libdir}/nautilus/extensions-2.0/*.la \
-                    ${libdir}/evince/*/backends/*.la"
-FILES_${PN}-staticdev += "${libdir}/nautilus/extensions-2.0/*.a \
-                          ${libdir}/evince/*/backends/*.a"
-FILES_${PN}-nautilus-extension = "${libdir}/nautilus/*/*so"
-FILES_${PN}-browser-plugin = "${libdir}/mozilla/*/*so"
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/evince/evince_3.28.2.bb b/meta-openembedded/meta-gnome/recipes-gnome/evince/evince_3.28.2.bb
new file mode 100644
index 0000000..8bf8a04
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-gnome/evince/evince_3.28.2.bb
@@ -0,0 +1,65 @@
+SUMMARY = "Evince is a document viewer for document formats like pdf, ps, djvu"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=96f2f8d5ee576a2163977938ea36fa7b"
+SECTION = "x11/office"
+DEPENDS = "gtk+3 libsecret ${@bb.utils.contains('DISTRO_FEATURES','x11','gnome-desktop3','',d)} poppler gstreamer1.0-plugins-base orc adwaita-icon-theme intltool-native gnome-common-native"
+
+inherit gnome pkgconfig gtk-icon-cache gsettings gobject-introspection distro_features_check systemd
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI = "${GNOME_MIRROR}/${GNOMEBN}/${@gnome_verdir("${PV}")}/${GNOMEBN}-${PV}.tar.${GNOME_COMPRESS_TYPE};name=archive \
+           file://0001-help-remove-YELP-macro.patch \
+           file://0001-Add-format-attribute-to-_synctex_malloc.patch \
+           file://0001-add-a-formatting-attribute-check.patch \
+           "
+SRC_URI[archive.md5sum] = "66aa1766eaaa37536e48def11a0e67a3"
+SRC_URI[archive.sha256sum] = "0955d22d85c9f6d322b6cbb464f1cc4c352db619017ec95dad4cc5c3440f73e1"
+
+EXTRA_OECONF = "--enable-thumbnailer"
+
+do_compile_prepend() {
+    export GIR_EXTRA_LIBS_PATH="${B}/libdocument/.libs"
+}
+
+
+do_install_append() {
+    install -d ${D}${datadir}/pixmaps
+    install -m 0755 ${S}/data/icons/48x48/apps/evince.png ${D}${datadir}/pixmaps/
+    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}
+    then
+        install -d ${D}${systemd_unitdir}/system
+        mv ${D}${systemd_user_unitdir}/evince.service ${D}${systemd_system_unitdir}/evince.service
+    else
+        rm -rf ${D}${libdir}/systemd/user/evince.service
+    fi
+    rmdir --ignore-fail-on-non-empty ${D}${systemd_user_unitdir}
+    rmdir --ignore-fail-on-non-empty ${D}${nonarch_libdir}/systemd
+    rmdir --ignore-fail-on-non-empty ${D}${nonarch_libdir}
+}
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[nautilus] = "--enable-nautilus,--disable-nautilus,nautilus"
+PACKAGECONFIG[browser-plugin] = "--enable-browser-plugin,--disable-browser-plugin,"
+
+SYSTEMD_SERVICE_${PN} = "evince.service"
+
+RDEPENDS_${PN} += "glib-2.0-utils"
+RRECOMMMENDS_${PN} = "adwaita-icon-theme"
+
+PACKAGES =+ "${PN}-nautilus-extension"
+PACKAGES =+ "${PN}-browser-plugin"
+
+FILES_${PN} += "${datadir}/dbus-1 \
+                ${datadir}/metainfo \
+                ${datadir}/thumbnailers \
+                ${systemd_unitdir}/systemd/user/evince.service \
+               "
+FILES_${PN}-dbg += "${libdir}/*/*/.debug \
+                    ${libdir}/*/*/*/.debug"
+FILES_${PN}-dev += "${libdir}/nautilus/extensions-2.0/*.la \
+                    ${libdir}/evince/*/backends/*.la"
+FILES_${PN}-staticdev += "${libdir}/nautilus/extensions-2.0/*.a \
+                          ${libdir}/evince/*/backends/*.a"
+FILES_${PN}-nautilus-extension = "${libdir}/nautilus/*/*so"
+FILES_${PN}-browser-plugin = "${libdir}/mozilla/*/*so"
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/gnome-desktop/gnome-desktop/0001-Disable-libseccomp-sycall-filtering-mechanism.patch b/meta-openembedded/meta-gnome/recipes-gnome/gnome-desktop/gnome-desktop/0001-Disable-libseccomp-sycall-filtering-mechanism.patch
new file mode 100644
index 0000000..aa11e8a
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-gnome/gnome-desktop/gnome-desktop/0001-Disable-libseccomp-sycall-filtering-mechanism.patch
@@ -0,0 +1,45 @@
+From 96753d85d8b53dd8f87b8f444892efffdbfab388 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Thu, 5 Oct 2017 14:54:17 +0300
+Subject: [PATCH] Disable libseccomp (sycall filtering mechanism)
+
+Upstream forgot to make it optional, and it is not currently used in Yocto
+
+Upstream-Status: Inappropriate [oe-core specific]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+---
+ configure.ac | 20 --------------------
+ 1 file changed, 20 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 118d04f..47c8894 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -151,26 +151,6 @@ fi
+ 
+ SECCOMP_PKG=""
+ enable_seccomp="no"
+-dnl Check for bubblewrap compatible platform
+-case $host_os in
+-  linux*)
+-    case $host_cpu in
+-      alpha|ia64|m68k|sh4|sparc64)
+-        enable_seccomp="no (not available on this architecture)"
+-        AC_MSG_WARN("seccomp not available on this architecture")
+-        ;;
+-      *)
+-        PKG_CHECK_MODULES(LIBSECCOMP, [libseccomp])
+-        SECCOMP_PKG="libseccomp"
+-        AC_DEFINE([ENABLE_SECCOMP], [1], [Define if using seccomp])
+-        enable_seccomp="yes"
+-        ;;
+-    esac
+-    AC_DEFINE_UNQUOTED(_GNU_SOURCE, 1, [Define to include GNU extensions])
+-    AC_DEFINE_UNQUOTED(HAVE_BWRAP, 1, [Define to 1 if Bubblewrap support is available])
+-    AC_DEFINE_UNQUOTED(INSTALL_PREFIX, "$prefix", [Path to library install prefix])
+-    ;;
+-esac
+ 
+ dnl pkg-config dependency checks
+ 
diff --git a/poky/meta/recipes-gnome/gnome-desktop/gnome-desktop/gnome-desktop-thumbnail-don-t-assume-time_t-is-long.patch b/meta-openembedded/meta-gnome/recipes-gnome/gnome-desktop/gnome-desktop/gnome-desktop-thumbnail-don-t-assume-time_t-is-long.patch
similarity index 100%
rename from poky/meta/recipes-gnome/gnome-desktop/gnome-desktop/gnome-desktop-thumbnail-don-t-assume-time_t-is-long.patch
rename to meta-openembedded/meta-gnome/recipes-gnome/gnome-desktop/gnome-desktop/gnome-desktop-thumbnail-don-t-assume-time_t-is-long.patch
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/gnome-desktop/gnome-desktop3_3.28.1.bb b/meta-openembedded/meta-gnome/recipes-gnome/gnome-desktop/gnome-desktop3_3.28.1.bb
new file mode 100644
index 0000000..39b3491
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-gnome/gnome-desktop/gnome-desktop3_3.28.1.bb
@@ -0,0 +1,28 @@
+SUMMARY = "GNOME library for reading .desktop files"
+SECTION = "x11/gnome"
+LICENSE = "GPLv2 & LGPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                    file://COPYING.LIB;md5=5f30f0716dfdd0d91eb439ebec522ec2"
+
+BPN = "gnome-desktop"
+
+inherit gnome pkgconfig upstream-version-is-even gobject-introspection
+SRC_URI[archive.md5sum] = "bcbf906d94eb08060c60a7364384d678"
+SRC_URI[archive.sha256sum] = "78a397a2be47586e6dc075d6a7fc5659aae3d10713d76994ce1b46086e7ecb9a"
+
+SRC_URI += " \
+           file://gnome-desktop-thumbnail-don-t-assume-time_t-is-long.patch \
+           file://0001-Disable-libseccomp-sycall-filtering-mechanism.patch \
+           "
+
+DEPENDS += "intltool-native gsettings-desktop-schemas gconf virtual/libx11 gtk+3 glib-2.0 startup-notification xkeyboard-config iso-codes udev"
+
+inherit distro_features_check gtk-doc
+REQUIRED_DISTRO_FEATURES = "x11"
+
+EXTRA_OECONF = "--disable-desktop-docs"
+
+PACKAGES =+ "libgnome-desktop3"
+FILES_libgnome-desktop3 = "${libdir}/lib*${SOLIBS} ${datadir}/libgnome-desktop*/pnp.ids ${datadir}/gnome/*xml"
+
+RRECOMMENDS_libgnome-desktop3 += "gsettings-desktop-schemas"
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/gnome-keyring/libgnome-keyring_3.12.0.bb b/meta-openembedded/meta-gnome/recipes-gnome/gnome-keyring/libgnome-keyring_3.12.0.bb
index 82abe33..ba69e2e 100644
--- a/meta-openembedded/meta-gnome/recipes-gnome/gnome-keyring/libgnome-keyring_3.12.0.bb
+++ b/meta-openembedded/meta-gnome/recipes-gnome/gnome-keyring/libgnome-keyring_3.12.0.bb
@@ -15,3 +15,15 @@
 
 SRC_URI[archive.md5sum] = "6696e4f2e9aed4625cdc3af30bd8c238"
 SRC_URI[archive.sha256sum] = "c4c178fbb05f72acc484d22ddb0568f7532c409b0a13e06513ff54b91e947783"
+
+
+# Fails to build with thumb-1 (qemuarm)
+#| {standard input}: Assembler messages:
+#| {standard input}:823: Error: shifts in CMP/MOV instructions are only supported in unified syntax -- `mov r12,r12,ror#3'
+#| {standard input}:823: Error: shifts in CMP/MOV instructions are only supported in unified syntax -- `mov r12,r12,ror#13'
+#| {standard input}:824: Error: shifts in CMP/MOV instructions are only supported in unified syntax -- `mov r12,r12,ror#29'
+#| {standard input}:824: Error: shifts in CMP/MOV instructions are only supported in unified syntax -- `mov r12,r12,ror#19'
+#| {standard input}:825: Error: lo register required -- `orr r10,r10,r10'
+ARM_INSTRUCTION_SET_armv5 = "arm"
+ARM_INSTRUCTION_SET_armv4 = "arm"
+
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/gtksourceview/gtksourceview3_3.24.6.bb b/meta-openembedded/meta-gnome/recipes-gnome/gtksourceview/gtksourceview3_3.24.6.bb
deleted file mode 100644
index 87e48ed..0000000
--- a/meta-openembedded/meta-gnome/recipes-gnome/gtksourceview/gtksourceview3_3.24.6.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-SUMMARY = "Portable C library for multiline text editing"
-HOMEPAGE = "http://projects.gnome.org/gtksourceview/"
-
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=fbc093901857fcd118f065f900982c24"
-
-DEPENDS = "gtk+3 libxml2 intltool-native gnome-common-native glib-2.0-native"
-
-PNAME = "gtksourceview"
-
-S = "${WORKDIR}/${PNAME}-${PV}"
-
-inherit gnomebase lib_package gettext distro_features_check gtk-doc gobject-introspection
-
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI = "http://ftp.gnome.org/pub/gnome/sources/gtksourceview/3.24/${PNAME}-${PV}.tar.xz"
-SRC_URI[md5sum] = "c09ccfc80f78083841f8fe266c1ac52a"
-SRC_URI[sha256sum] = "7aa6bdfebcdc73a763dddeaa42f190c40835e6f8495bb9eb8f78587e2577c188"
-
-FILES_${PN} += " ${datadir}/gtksourceview-3.0"
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/gtksourceview/gtksourceview3_3.24.8.bb b/meta-openembedded/meta-gnome/recipes-gnome/gtksourceview/gtksourceview3_3.24.8.bb
new file mode 100644
index 0000000..7cb8866
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-gnome/gtksourceview/gtksourceview3_3.24.8.bb
@@ -0,0 +1,21 @@
+SUMMARY = "Portable C library for multiline text editing"
+HOMEPAGE = "http://projects.gnome.org/gtksourceview/"
+
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=fbc093901857fcd118f065f900982c24"
+
+DEPENDS = "gtk+3 libxml2 intltool-native gnome-common-native glib-2.0-native"
+
+PNAME = "gtksourceview"
+
+S = "${WORKDIR}/${PNAME}-${PV}"
+
+inherit gnomebase lib_package gettext distro_features_check gtk-doc gobject-introspection
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI = "http://ftp.gnome.org/pub/gnome/sources/gtksourceview/3.24/${PNAME}-${PV}.tar.xz"
+SRC_URI[md5sum] = "52f8c83ad21ad75e9ee6cca03ce2e63f"
+SRC_URI[sha256sum] = "1e9bb8ff190db705deb916dd23ff681f0e8803aec407bf0fd64c7e615ac436fe"
+
+FILES_${PN} += " ${datadir}/gtksourceview-3.0"
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/gvfs/gvfs_1.36.0.bb b/meta-openembedded/meta-gnome/recipes-gnome/gvfs/gvfs_1.36.0.bb
deleted file mode 100644
index 5f73912..0000000
--- a/meta-openembedded/meta-gnome/recipes-gnome/gvfs/gvfs_1.36.0.bb
+++ /dev/null
@@ -1,68 +0,0 @@
-DESCRIPTION = "gvfs is a userspace virtual filesystem"
-LICENSE = "LGPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=05df38dd77c35ec8431f212410a3329e"
-
-inherit gnome bash-completion gettext
-
-DEPENDS += "libsecret glib-2.0 gconf intltool-native libgudev udisks2 polkit shadow-native"
-
-SRC_URI = "https://download.gnome.org/sources/${BPN}/${@gnome_verdir("${PV}")}/${BPN}-${PV}.tar.xz;name=archive"
-
-SRC_URI[archive.md5sum] = "216d461c5e96e2cea74253be407af6dc"
-SRC_URI[archive.sha256sum] = "9ec388afeb373a213f2cc489184f76a17ae273a000e8a4ec720c1995943256bb"
-
-do_configure_prepend() {
-    # make automake happy..
-    touch ${S}/ABOUT-NLS
-}
-
-EXTRA_OECONF = " \
-    --disable-gdu \
-    --enable-udisks2 \
-    --disable-documentation \
-"
-
-PACKAGES =+ "gvfsd-ftp gvfsd-sftp gvfsd-trash"
-
-FILES_${PN} += " \
-    ${datadir}/glib-2.0 \
-    ${datadir}/GConf \
-    ${datadir}/dbus-1/services \
-    ${libdir}/gio/modules/*.so \
-    ${libdir}/tmpfiles.d \
-    ${systemd_user_unitdir} \
-"
-RDEPENDS_${PN} = "udisks2"
-
-FILES_${PN}-dbg += "${libdir}/gio/modules/.debug/*"
-FILES_${PN}-dev += "${libdir}/gio/modules/*.la"
-
-FILES_gvfsd-ftp = "${libexecdir}/gvfsd-ftp ${datadir}/gvfs/mounts/ftp.mount"
-FILES_gvfsd-sftp = "${libexecdir}/gvfsd-sftp ${datadir}/gvfs/mounts/sftp.mount"
-FILES_gvfsd-trash = "${libexecdir}/gvfsd-trash ${datadir}/gvfs/mounts/trash.mount"
-
-RRECOMMENDS_gvfsd-ftp += "openssh-sftp openssh-ssh"
-
-PACKAGECONFIG ?= "libgphoto2 ${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
-
-PACKAGECONFIG[afc] = "--enable-afc, --disable-afc, libimobiledevice libplist"
-PACKAGECONFIG[archive] = "--enable-archive, --disable-archive, libarchive"
-PACKAGECONFIG[avahi] = "--enable-avahi, --disable-avahi, avahi"
-PACKAGECONFIG[gcr] = "--enable-gcr, --disable-gcr, gcr"
-PACKAGECONFIG[http] = "--enable-http, --disable-http, libsoup-2.4"
-PACKAGECONFIG[libmtp] = "--enable-libmtp, --disable-libmtp, libmtp"
-PACKAGECONFIG[libgphoto2] = "--enable-gphoto2, --disable-gphoto2, libgphoto2"
-PACKAGECONFIG[samba] = "--enable-samba, --disable-samba, samba"
-PACKAGECONFIG[systemd] = "--with-systemduserunitdir=${systemd_user_unitdir},--without-systemduserunitdir,systemd"
-
-# needs meta-filesystems
-PACKAGECONFIG[fuse] = "--enable-fuse, --disable-fuse, fuse"
-
-# libcdio-paranoia recipe doesn't exist yet
-PACKAGECONFIG[cdda] = "--enable-cdda, --disable-cdda, libcdio-paranoia"
-
-# Fix up permissions on polkit rules.d to work with rpm4 constraints
-do_install_append() {
-	chmod 700 ${D}/${datadir}/polkit-1/rules.d
-	chown polkitd:root ${D}/${datadir}/polkit-1/rules.d
-}
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/gvfs/gvfs_1.39.1.bb b/meta-openembedded/meta-gnome/recipes-gnome/gvfs/gvfs_1.39.1.bb
new file mode 100644
index 0000000..ca1eb6a
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-gnome/gvfs/gvfs_1.39.1.bb
@@ -0,0 +1,70 @@
+DESCRIPTION = "gvfs is a userspace virtual filesystem"
+LICENSE = "LGPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=05df38dd77c35ec8431f212410a3329e"
+
+GNOMEBASEBUILDCLASS = "meson"
+inherit gnome bash-completion gettext
+
+DEPENDS += "libsecret glib-2.0 gconf intltool-native libgudev udisks2 polkit shadow-native"
+
+SRC_URI = "https://download.gnome.org/sources/${BPN}/${@gnome_verdir("${PV}")}/${BPN}-${PV}.tar.xz;name=archive"
+
+SRC_URI[archive.md5sum] = "4c68899cfd80d57a153771534193bb9a"
+SRC_URI[archive.sha256sum] = "6e7213570389b17b67433695f515f3b17705ba976168a4c8828fc177cce50223"
+
+
+EXTRA_OEMESON = " \
+    -Dbluray=false \
+    -Dgdu=false \
+    -Dgoa=false \
+    -Dgoogle=false \
+    -Dnfs=false \
+    -Dudisks2=true \
+    -Ddocumentation=false \
+"
+
+PACKAGES =+ "gvfsd-ftp gvfsd-sftp gvfsd-trash"
+
+FILES_${PN} += " \
+    ${datadir}/glib-2.0 \
+    ${datadir}/GConf \
+    ${datadir}/dbus-1/services \
+    ${libdir}/gio/modules/*.so \
+    ${libdir}/tmpfiles.d \
+    ${systemd_user_unitdir} \
+"
+RDEPENDS_${PN} = "udisks2"
+
+FILES_${PN}-dbg += "${libdir}/gio/modules/.debug/*"
+FILES_${PN}-dev += "${libdir}/gio/modules/*.la"
+
+FILES_gvfsd-ftp = "${libexecdir}/gvfsd-ftp ${datadir}/gvfs/mounts/ftp.mount"
+FILES_gvfsd-sftp = "${libexecdir}/gvfsd-sftp ${datadir}/gvfs/mounts/sftp.mount"
+FILES_gvfsd-trash = "${libexecdir}/gvfsd-trash ${datadir}/gvfs/mounts/trash.mount"
+
+RRECOMMENDS_gvfsd-ftp += "openssh-sftp openssh-ssh"
+
+PACKAGECONFIG ?= "libgphoto2 ${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
+
+PACKAGECONFIG[afc] = "-Dafc=true, -Dafc=false, libimobiledevice libplist"
+PACKAGECONFIG[archive] = "-Darchive=true, -Darchive=false, libarchive"
+PACKAGECONFIG[dnssd] = "-Ddnssd=true, -Ddnssd=false, avahi"
+PACKAGECONFIG[gcr] = "-Dgcr=true, -Dgcr=false, gcr"
+PACKAGECONFIG[http] = "-Dhttp=true, -Dhttp=false, libsoup-2.4"
+PACKAGECONFIG[libmtp] = "-Dmtp=true, -Dmtp=false, libmtp"
+PACKAGECONFIG[logind] = "-Dlogind=true, -Dlogind=false, systemd"
+PACKAGECONFIG[libgphoto2] = "-Dgphoto2=true, -Dgphoto2=false, libgphoto2"
+PACKAGECONFIG[samba] = "-Dsmb=true, -Dsmb=false, samba"
+PACKAGECONFIG[systemd] = "-Dsystemduserunitdir=${systemd_user_unitdir} -Dtmpfilesdir=${libdir}/tmpfiles.d, -Dsystemduserunitdir=no -Dtmpfilesdir=no, systemd"
+
+# needs meta-filesystems
+PACKAGECONFIG[fuse] = "-Dfuse=true, -Dfuse=false, fuse"
+
+# libcdio-paranoia recipe doesn't exist yet
+PACKAGECONFIG[cdda] = "-Dcdda=true, -Dcdda=false, libcdio-paranoia"
+
+# Fix up permissions on polkit rules.d to work with rpm4 constraints
+do_install_append() {
+	chmod 700 ${D}/${datadir}/polkit-1/rules.d
+	chown polkitd:root ${D}/${datadir}/polkit-1/rules.d
+}
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/libgnome/libgnomekbd_3.22.0.bb b/meta-openembedded/meta-gnome/recipes-gnome/libgnome/libgnomekbd_3.22.0.bb
deleted file mode 100644
index 40249fd..0000000
--- a/meta-openembedded/meta-gnome/recipes-gnome/libgnome/libgnomekbd_3.22.0.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-SUMMARY = "GNOME keyboard library"
-LICENSE = "LGPLv2"
-LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=6e29c688d912da12b66b73e32b03d812"
-
-SECTION = "x11/gnome/libs"
-
-DEPENDS = "gconf glib-2.0 libxklavier gtk+3 intltool-native"
-
-inherit distro_features_check gnome gobject-introspection gettext
-
-REQUIRED_DISTRO_FEATURES = "x11"
-
-GNOME_COMPRESS_TYPE = "xz"
-
-SRC_URI[archive.md5sum] = "7b1ebf99f4254c99922163c262c7ff04"
-SRC_URI[archive.sha256sum] = "340b30dabfebbd4e0e6c0fe34a378966dd5640b5d44595ab8a19b0be255d77df"
-
-EXTRA_OECONF_remove = "--disable-schemas-install"
-
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/libgnome/libgnomekbd_3.26.0.bb b/meta-openembedded/meta-gnome/recipes-gnome/libgnome/libgnomekbd_3.26.0.bb
new file mode 100644
index 0000000..456a744
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-gnome/libgnome/libgnomekbd_3.26.0.bb
@@ -0,0 +1,19 @@
+SUMMARY = "GNOME keyboard library"
+LICENSE = "LGPLv2"
+LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=6e29c688d912da12b66b73e32b03d812"
+
+SECTION = "x11/gnome/libs"
+
+DEPENDS = "gconf glib-2.0 libxklavier gtk+3 intltool-native"
+
+inherit distro_features_check gnome gobject-introspection gettext
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+GNOME_COMPRESS_TYPE = "xz"
+
+SRC_URI[archive.md5sum] = "8b9d13d46255cde910b3db5a6ebb4727"
+SRC_URI[archive.sha256sum] = "ea3b418c57c30615f7ee5b6f718def7c9d09ce34637324361150744258968875"
+
+EXTRA_OECONF_remove = "--disable-schemas-install"
+
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/libwnck/libwnck3_3.20.1.bb b/meta-openembedded/meta-gnome/recipes-gnome/libwnck/libwnck3_3.20.1.bb
deleted file mode 100644
index 02149fb..0000000
--- a/meta-openembedded/meta-gnome/recipes-gnome/libwnck/libwnck3_3.20.1.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-SUMMARY = "Window navigation construction toolkit"
-LICENSE = "LGPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2"
-
-BPN = "libwnck"
-
-SECTION = "x11/libs"
-DEPENDS = "intltool-native gnome-common-native gtk+3 gdk-pixbuf-native libxres"
-
-PACKAGECONFIG ??= "startup-notification"
-PACKAGECONFIG[startup-notification] = "--enable-startup-notification,--disable-startup-notification,startup-notification"
-
-inherit gnomebase gobject-introspection gtk-doc
-SRC_URI[archive.md5sum] = "487938d65d4bfae1f2501052b1bd7492"
-SRC_URI[archive.sha256sum] = "1cb03716bc477058dfdf3ebfa4f534de3b13b1aa067fcd064d0b7813291cba72"
-
-inherit distro_features_check
-# libxres means x11 only
-REQUIRED_DISTRO_FEATURES = "x11"
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/libwnck/libwnck3_3.30.0.bb b/meta-openembedded/meta-gnome/recipes-gnome/libwnck/libwnck3_3.30.0.bb
new file mode 100644
index 0000000..9cee9c9
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-gnome/libwnck/libwnck3_3.30.0.bb
@@ -0,0 +1,20 @@
+SUMMARY = "Window navigation construction toolkit"
+LICENSE = "LGPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2"
+
+BPN = "libwnck"
+
+SECTION = "x11/libs"
+DEPENDS = "intltool-native gnome-common-native gtk+3 gdk-pixbuf-native libxres"
+
+PACKAGECONFIG ??= "startup-notification"
+PACKAGECONFIG[startup-notification] = "--enable-startup-notification,--disable-startup-notification,startup-notification"
+
+inherit gnomebase gobject-introspection gtk-doc gettext
+
+SRC_URI[archive.md5sum] = "60109c2ab0b07da1099ee57980054de1"
+SRC_URI[archive.sha256sum] = "ac6d0d2646aa80676d3066651e73abb7bff7ed79be238c9b21a0083e2adc3439"
+
+inherit distro_features_check
+# libxres means x11 only
+REQUIRED_DISTRO_FEATURES = "x11"
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/metacity/metacity_3.28.0.bb b/meta-openembedded/meta-gnome/recipes-gnome/metacity/metacity_3.28.0.bb
new file mode 100644
index 0000000..189f6ec
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-gnome/metacity/metacity_3.28.0.bb
@@ -0,0 +1,41 @@
+SECTION = "x11/wm"
+SUMMARY = "Metacity is the boring window manager for the adult in you"
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b4cce53560b8e619ffa7c830fb8761aa \
+                    file://src/include/main.h;endline=24;md5=72148ede07a6dadd01de6a882d20a9ad"
+
+PE = "1"
+
+DEPENDS = "gsettings-desktop-schemas startup-notification \
+           gnome-doc-utils gdk-pixbuf-native \
+           gtk+3 glib-2.0 libcanberra libgtop intltool-native"
+
+inherit autotools gettext gnomebase distro_features_check
+# depends on startup-notification which depends on virtual/libx11
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI = "git://github.com/GNOME/metacity.git;branch=master \
+           file://0001-drop-zenity-detection.patch \
+"
+
+S = "${WORKDIR}/git"
+SRCREV = "c0d4b2fc0fcd6f2d3c37da935923f9e9ed5eb99f"
+
+EXTRA_OECONF += "--disable-xinerama"
+
+PACKAGECONFIG ?= ""
+
+# enable as neccessary until new warnings are dealt with
+PACKAGECONFIG[werror] = "--enable-Werror,--disable-Werror,,"
+
+do_configure_prepend() {
+    cd ${S}
+    aclocal --install || exit 1
+    autoreconf --verbose --force --install -Wno-portability || exit 1
+    cd -
+
+}
+
+FILES_${PN} += "${datadir}/themes ${datadir}/gnome-control-center ${datadir}/gnome"
+RDEPENDS_${PN} += "gsettings-desktop-schemas"
+
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/metacity/metacity_3.38.0.bb b/meta-openembedded/meta-gnome/recipes-gnome/metacity/metacity_3.38.0.bb
deleted file mode 100644
index 48fc914..0000000
--- a/meta-openembedded/meta-gnome/recipes-gnome/metacity/metacity_3.38.0.bb
+++ /dev/null
@@ -1,34 +0,0 @@
-SECTION = "x11/wm"
-SUMMARY = "Metacity is the boring window manager for the adult in you"
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b4cce53560b8e619ffa7c830fb8761aa \
-                    file://src/include/main.h;endline=24;md5=72148ede07a6dadd01de6a882d20a9ad"
-
-DEPENDS = "gsettings-desktop-schemas startup-notification \
-           gnome-doc-utils gdk-pixbuf-native \
-           gtk+3 glib-2.0 libcanberra libgtop intltool-native"
-
-inherit autotools gettext gnomebase distro_features_check
-# depends on startup-notification which depends on virtual/libx11
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI = "git://github.com/GNOME/metacity.git;branch=master \
-           file://0001-drop-zenity-detection.patch \
-"
-
-S = "${WORKDIR}/git"
-SRCREV = "c0d4b2fc0fcd6f2d3c37da935923f9e9ed5eb99f"
-
-EXTRA_OECONF += "--disable-xinerama"
-
-do_configure_prepend() {
-    cd ${S}
-    aclocal --install || exit 1
-    autoreconf --verbose --force --install -Wno-portability || exit 1
-    cd -
-
-}
-
-FILES_${PN} += "${datadir}/themes ${datadir}/gnome-control-center ${datadir}/gnome"
-RDEPENDS_${PN} += "gsettings-desktop-schemas"
-
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/nautilus/nautilus/0001-nautilus-drop-gnome-desktop-thumbnail-API-with-new-g.patch b/meta-openembedded/meta-gnome/recipes-gnome/nautilus/nautilus/0001-nautilus-drop-gnome-desktop-thumbnail-API-with-new-g.patch
new file mode 100644
index 0000000..f19eb49
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-gnome/nautilus/nautilus/0001-nautilus-drop-gnome-desktop-thumbnail-API-with-new-g.patch
@@ -0,0 +1,40 @@
+From a4ed38e95cbe07f02028249b8b315565a5ac1e43 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 5 May 2018 22:32:45 -0700
+Subject: [PATCH] nautilus: drop gnome-desktop thumbnail API with new
+ gdk-pixbuf
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+If gdk-pixbuf >= 2.36.5 is available, its scaling API can do what we
+want, so we don’t need to use the deprecated gnome-desktop one.
+
+Also fixes compile errors seen on master
+nautilus-properties-window.c:5101: undefined reference to `gnome_desktop_thumbnail_scale_down_pixbuf'
+
+Upstream-Status: Backport
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/nautilus-properties-window.c | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/src/nautilus-properties-window.c b/src/nautilus-properties-window.c
+index dea8b0f..fad9bd1 100644
+--- a/src/nautilus-properties-window.c
++++ b/src/nautilus-properties-window.c
+@@ -5098,10 +5098,11 @@ update_preview_callback (GtkFileChooser *icon_chooser,
+ 			scale = (double)gdk_pixbuf_get_height (pixbuf) /
+ 				gdk_pixbuf_get_width (pixbuf);
+ 
+-			scaled_pixbuf = gnome_desktop_thumbnail_scale_down_pixbuf
++			scaled_pixbuf = gdk_pixbuf_scale_simple
+ 				(pixbuf,
+ 				 PREVIEW_IMAGE_WIDTH,
+-				 scale * PREVIEW_IMAGE_WIDTH);
++				 scale * PREVIEW_IMAGE_WIDTH,
++				 GDK_INTERP_HYPER);
+ 			g_object_unref (pixbuf);
+ 			pixbuf = scaled_pixbuf;
+ 		}
diff --git a/meta-openembedded/meta-gnome/recipes-gnome/nautilus/nautilus_3.18.5.bb b/meta-openembedded/meta-gnome/recipes-gnome/nautilus/nautilus_3.18.5.bb
index 8fdbf6a..bdb2f3c 100644
--- a/meta-openembedded/meta-gnome/recipes-gnome/nautilus/nautilus_3.18.5.bb
+++ b/meta-openembedded/meta-gnome/recipes-gnome/nautilus/nautilus_3.18.5.bb
@@ -6,14 +6,18 @@
                     file://COPYING.EXTENSIONS;md5=7579d6678402a1868631bf82c93ff0d4 \
                     file://COPYING.LIB;md5=f30a9716ef3762e3467a2f62bf790f0a"
 
-SRC_URI = "http://ftp.gnome.org/pub/GNOME/sources/nautilus/3.18/nautilus-${PV}.tar.xz"
+inherit distro_features_check autotools pkgconfig gobject-introspection
+
+MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}"
+SRC_URI = "http://ftp.gnome.org/pub/GNOME/sources/nautilus/${MAJ_VER}/nautilus-${PV}.tar.xz \
+           file://0001-nautilus-drop-gnome-desktop-thumbnail-API-with-new-g.patch \
+           "
 
 SRC_URI[md5sum] = "0f578bda5655c0ce204befafca5803d7"
 SRC_URI[sha256sum] = "60a927c0522b4cced9d8f62baed2ee5e2fd4305be4523eb5bc44805971a6cc15"
 
 DEPENDS = "gtk+3 gnome-desktop3 gsettings-desktop-schemas glib-2.0-native intltool-native pango"
 
-inherit distro_features_check autotools pkgconfig gobject-introspection
 REQUIRED_DISTRO_FEATURES = "x11"
 
 EXTRA_OECONF = " \
@@ -23,7 +27,7 @@
     --enable-tracker=no \
     --disable-schemas-compile \
     --enable-xmp=no \
-    --enable-libexif=no \ 
+    --enable-libexif=no \
 "
 
 FILES_${PN} += "${datadir}/*"
diff --git a/poky/meta/recipes-extended/libuser/libuser/0001-Check-for-issetugid.patch b/meta-openembedded/meta-gnome/recipes-support/libuser/libuser/0001-Check-for-issetugid.patch
similarity index 100%
rename from poky/meta/recipes-extended/libuser/libuser/0001-Check-for-issetugid.patch
rename to meta-openembedded/meta-gnome/recipes-support/libuser/libuser/0001-Check-for-issetugid.patch
diff --git a/poky/meta/recipes-extended/libuser/libuser/0001-modules-files.c-parse_field-fix-string-formating-in-.patch b/meta-openembedded/meta-gnome/recipes-support/libuser/libuser/0001-modules-files.c-parse_field-fix-string-formating-in-.patch
similarity index 100%
rename from poky/meta/recipes-extended/libuser/libuser/0001-modules-files.c-parse_field-fix-string-formating-in-.patch
rename to meta-openembedded/meta-gnome/recipes-support/libuser/libuser/0001-modules-files.c-parse_field-fix-string-formating-in-.patch
diff --git a/poky/meta/recipes-extended/libuser/libuser/0002-remove-unused-execinfo.h.patch b/meta-openembedded/meta-gnome/recipes-support/libuser/libuser/0002-remove-unused-execinfo.h.patch
similarity index 100%
rename from poky/meta/recipes-extended/libuser/libuser/0002-remove-unused-execinfo.h.patch
rename to meta-openembedded/meta-gnome/recipes-support/libuser/libuser/0002-remove-unused-execinfo.h.patch
diff --git a/poky/meta/recipes-extended/libuser/libuser_0.62.bb b/meta-openembedded/meta-gnome/recipes-support/libuser/libuser_0.62.bb
similarity index 100%
rename from poky/meta/recipes-extended/libuser/libuser_0.62.bb
rename to meta-openembedded/meta-gnome/recipes-support/libuser/libuser_0.62.bb
diff --git a/meta-openembedded/meta-gnome/recipes-support/usermode/usermode/0001-Include-sys-sysmacros.h-for-major-minor.patch b/meta-openembedded/meta-gnome/recipes-support/usermode/usermode/0001-Include-sys-sysmacros.h-for-major-minor.patch
new file mode 100644
index 0000000..277f6e2
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-support/usermode/usermode/0001-Include-sys-sysmacros.h-for-major-minor.patch
@@ -0,0 +1,25 @@
+From 75539659396b18110d5a52a8a32845254b4d8eca Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 11 Aug 2018 18:25:47 -0700
+Subject: [PATCH] Include sys/sysmacros.h for major/minor
+
+usermount.c:238: undefined reference to `major'
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ usermount.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/usermount.c b/usermount.c
+index 4107027..21ef77f 100644
+--- a/usermount.c
++++ b/usermount.c
+@@ -40,6 +40,7 @@
+ #include <sys/stat.h>
+ #include <sys/time.h>
+ #include <sys/types.h>
++#include <sys/sysmacros.h>
+ #include <errno.h>
+ #include <glob.h>
+ #include <libintl.h>
diff --git a/meta-openembedded/meta-gnome/recipes-support/usermode/usermode/0001-Missing-n-in-translated-string.patch b/meta-openembedded/meta-gnome/recipes-support/usermode/usermode/0001-Missing-n-in-translated-string.patch
new file mode 100644
index 0000000..9db700e
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-support/usermode/usermode/0001-Missing-n-in-translated-string.patch
@@ -0,0 +1,28 @@
+From 7cbc6441cd06e0c0bb51ac37c8f22b0fd51f12f2 Mon Sep 17 00:00:00 2001
+From: Jiri Kucera <jkucera@redhat.com>
+Date: Wed, 11 Apr 2018 17:13:44 +0200
+Subject: [PATCH] Missing \n in translated string
+
+Upstream-Status: Backport
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ po/tr.po | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/po/tr.po b/po/tr.po
+index 84e5021..a28e947 100644
+--- a/po/tr.po
++++ b/po/tr.po
+@@ -408,7 +408,7 @@ msgstr "Grafik pencere açılamadı ve uçbirim denetimi bulunamadı.\n"
+ #: ../../po/../userpasswd.c:37
+ #, c-format
+ msgid "Unexpected command-line arguments\n"
+-msgstr "Beklenmeyen komut satırı argümanları"
++msgstr "Beklenmeyen komut satırı argümanları\n"
+ 
+ #: ../../po/../userinfo.c:411
+ #, c-format
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-gnome/recipes-support/usermode/usermode/0001-formatting-issues.patch b/meta-openembedded/meta-gnome/recipes-support/usermode/usermode/0001-formatting-issues.patch
deleted file mode 100644
index 9d512d4..0000000
--- a/meta-openembedded/meta-gnome/recipes-support/usermode/usermode/0001-formatting-issues.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From 7a316dad0697af2ef4e8079a5af51565a8195aa6 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Mon, 24 Jul 2017 01:42:30 -0400
-Subject: [PATCH] userhelper.c: fix formatting issues
-
-Fixed when compile with "-Wformat -Wformat-security -Werror=format-security":
-|../usermode-1.111/userhelper.c:585:4: error: format not a string
-literal and no format arguments [-Werror=format-security]
-|    text = g_strdup_printf(dgettext(data->domain, data->banner));
-|    ^~~~
-
-Upstream-Status: Pending
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- userhelper.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/userhelper.c b/userhelper.c
-index 76ad492..ee0da49 100644
---- a/userhelper.c
-+++ b/userhelper.c
-@@ -582,7 +582,7 @@ converse_console(int num_msg, const struct pam_message **msg,
- 
- 	if (banner == 0) {
- 		if ((data->banner != NULL) && (data->domain != NULL)) {
--			text = g_strdup_printf(dgettext(data->domain, data->banner));
-+			text = g_strdup_printf("%s", dgettext(data->domain, data->banner));
- 		} else {
- 			if ((service != NULL) && (strlen(service) > 0)) {
- 				if (data->fallback_allowed) {
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-gnome/recipes-support/usermode/usermode_1.111.bb b/meta-openembedded/meta-gnome/recipes-support/usermode/usermode_1.111.bb
deleted file mode 100644
index 3aea2e6..0000000
--- a/meta-openembedded/meta-gnome/recipes-support/usermode/usermode_1.111.bb
+++ /dev/null
@@ -1,30 +0,0 @@
-DESCRIPTION = "The usermode contains the userhelper program, which can be used to allow configured \
-programs to be run with superuser privileges by ordinary users, and several \
-graphical tools for users: \
-* userinfo allows users to change their finger information. \
-* usermount lets users mount, unmount, and format filesystems. \
-* userpasswd allows users to change their passwords. \
-"
-HOMEPAGE = "https://pagure.io/usermode"
-LICENSE = "GPLv2+"
-DEPENDS = "libuser ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)} \
-           gtk+ desktop-file-utils-native \
-           startup-notification intltool-native \
-           util-linux \
-"
-
-SRC_URI = "https://releases.pagure.org/${BPN}/${BPN}-${PV}.tar.xz \
-           file://0001-formatting-issues.patch \
-           file://0001-fix-compile-failure-against-musl-C-library.patch \
-           file://0001-Makefile.am-Link-with-libm-for-powl-API.patch \
-           "
-SRC_URI[md5sum] = "28ba510fbd8da9f4e86e57d6c31cff29"
-SRC_URI[sha256sum] = "3dd0b9639b5bd396b7ea5fada6aaa694dbfdaa3ad06eb95a6eabcdfd02f875c6"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552"
-
-inherit distro_features_check autotools gettext pkgconfig
-
-EXTRA_OEMAKE += "INSTALL='install -p'"
-
-REQUIRED_DISTRO_FEATURES = "x11 pam"
diff --git a/meta-openembedded/meta-gnome/recipes-support/usermode/usermode_1.112.bb b/meta-openembedded/meta-gnome/recipes-support/usermode/usermode_1.112.bb
new file mode 100644
index 0000000..82ccf3e
--- /dev/null
+++ b/meta-openembedded/meta-gnome/recipes-support/usermode/usermode_1.112.bb
@@ -0,0 +1,31 @@
+DESCRIPTION = "The usermode contains the userhelper program, which can be used to allow configured \
+programs to be run with superuser privileges by ordinary users, and several \
+graphical tools for users: \
+* userinfo allows users to change their finger information. \
+* usermount lets users mount, unmount, and format filesystems. \
+* userpasswd allows users to change their passwords. \
+"
+HOMEPAGE = "https://pagure.io/usermode"
+LICENSE = "GPLv2+"
+DEPENDS = "libuser ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)} \
+           gtk+ desktop-file-utils-native \
+           startup-notification intltool-native \
+           util-linux \
+"
+
+SRC_URI = "https://releases.pagure.org/${BPN}/${BPN}-${PV}.tar.xz \
+           file://0001-fix-compile-failure-against-musl-C-library.patch \
+           file://0001-Makefile.am-Link-with-libm-for-powl-API.patch \
+           file://0001-Missing-n-in-translated-string.patch \
+           file://0001-Include-sys-sysmacros.h-for-major-minor.patch \
+           "
+SRC_URI[md5sum] = "a766a9f7600f573fb6de4655d4162196"
+SRC_URI[sha256sum] = "37c4d667209da14082c08df6e48fe955d1532efebd5322f13f94683c6cc10370"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552"
+
+inherit distro_features_check autotools gettext pkgconfig
+
+EXTRA_OEMAKE += "INSTALL='install -p'"
+
+REQUIRED_DISTRO_FEATURES = "x11 pam"
diff --git a/meta-openembedded/meta-initramfs/README b/meta-openembedded/meta-initramfs/README
index 7185383..ba2ba5f 100644
--- a/meta-openembedded/meta-initramfs/README
+++ b/meta-openembedded/meta-initramfs/README
@@ -12,7 +12,7 @@
 This layer depends on:
 
 URI: git://github.com/openembedded/oe-core.git
-branch: master
+branch: thud
 revision: HEAD
 
 
@@ -20,12 +20,12 @@
 -----------
 
 Send patches / pull requests to openembedded-devel@lists.openembedded.org
-with '[meta-initramfs]' in the subject.
+with '[meta-initramfs][thud]' in the subject.
 
 When sending single patches, please using something like:
-'git send-email -M -1 --to openembedded-devel@lists.openembedded.org --subject-prefix=meta-initramfs][PATCH'
+'git send-email -M -1 --to openembedded-devel@lists.openembedded.org --subject-prefix=meta-initramfs][thud][PATCH'
 
-Interm layer maintainer: Armin Kuster <akuster808@gmail.com>
+Thud maintainer: Armin Kuster <akuster808@gmail.com>
 
 
 License
diff --git a/meta-openembedded/meta-initramfs/conf/layer.conf b/meta-openembedded/meta-initramfs/conf/layer.conf
index 97afc93..bd92ddf 100644
--- a/meta-openembedded/meta-initramfs/conf/layer.conf
+++ b/meta-openembedded/meta-initramfs/conf/layer.conf
@@ -16,7 +16,7 @@
 BBFILE_PRIORITY_meta-initramfs = "8"
 LAYERDEPENDS_meta-initramfs = "core"
 
-LAYERSERIES_COMPAT_meta-initramfs = "sumo"
+LAYERSERIES_COMPAT_meta-initramfs = "thud"
 
 SIGGEN_EXCLUDE_SAFE_RECIPE_DEPS += " \
   dracut->virtual/kernel \
diff --git a/meta-openembedded/meta-initramfs/recipes-bsp/kexecboot/kexecboot-cfg_0.2.bb b/meta-openembedded/meta-initramfs/recipes-bsp/kexecboot/kexecboot-cfg_0.2.bb
index 804ec32..f90e234 100644
--- a/meta-openembedded/meta-initramfs/recipes-bsp/kexecboot/kexecboot-cfg_0.2.bb
+++ b/meta-openembedded/meta-initramfs/recipes-bsp/kexecboot/kexecboot-cfg_0.2.bb
@@ -19,9 +19,15 @@
 # Specify full kernel path on target.
 KERNEL=/boot/${KERNEL_IMAGETYPE}
 #
+# Specify which device tree blob to use
+# DTB=/boot/my-own-dtb
+#
 # Append this tags to the kernel cmdline.
 APPEND=${CMDLINE} ${CMDLINE_DEBUG}
 #
+# Overwrite kernel command line instead of appending to it
+# CMDLINE=console=/dev/tty0 root=/dev/sdb1
+#
 # Specify optional initrd/initramfs.
 # INITRD=/boot/initramfs.cpio.gz
 #
diff --git a/meta-openembedded/meta-initramfs/recipes-bsp/kexecboot/kexecboot_git.bb b/meta-openembedded/meta-initramfs/recipes-bsp/kexecboot/kexecboot_git.bb
index 9f5dad7..6d79e8f 100644
--- a/meta-openembedded/meta-initramfs/recipes-bsp/kexecboot/kexecboot_git.bb
+++ b/meta-openembedded/meta-initramfs/recipes-bsp/kexecboot/kexecboot_git.bb
@@ -1,36 +1,3 @@
-###########################
-# Configure options:
-#
-#  --enable-static-linking compile kexecboot as static executable [default=no]
-#  --enable-fbui           support framebuffer menu [default=yes]
-#  --enable-fbui-width     limit FB UI width to specified value [default=no]
-#  --enable-fbui-height    limit FB UI height to specified value [default=no]
-#  --enable-textui         support console text user interface [default=no]
-#  --enable-cfgfiles       support config files [default=yes]
-#  --enable-icons          support custom icons (depends on fbui) [default=yes]
-#  --enable-zaurus         compile Sharp Zaurus specific code [default=no]
-#  --enable-zimage         compile with zImage support [default=yes]
-#  --enable-uimage         compile with uImage support [default=no]
-#  --enable-machine-kernel look for machine-specific zImage kernel [default=no]
-#  --enable-devices-recreating
-#                          enable devices re-creating [default=yes]
-#  --enable-debug          enable debug output [default=no]
-#  --enable-host-debug     allow for non-destructive executing of kexecboot on
-#                            host system [default=no]
-#  --enable-numkeys        enable menu item selection by keys [0-9] [default=yes]
-#  --enable-bg-buffer      enable buffer for pre-drawed FB GUI background
-#
-#  --enable-timeout        allow to boot 1st kernel after timeout in seconds
-#                            [default=no]
-#  --enable-delay          specify delay before device scanning, allowing
-#                            initialization of old CF/SD cards [default=1]
-#  --enable-bpp            enable support of specified bpp modes
-#                            (all,32,24,18,16,4,2,1) [default=all]
-#  --enable-evdev-rate     change evdev (keyboard/mouse) repeat rate
-#                            in milliseconds e.g. "1000,250" [default=no]
-#  --with-kexec-binary     look for kexec binary at path
-#                            [default="/usr/sbin/kexec"]
-##########################
 SUMMARY = "kexecboot linux-as-bootloader"
 DESCRIPTION = "kexecboot is a graphical linux-as-bootloader implementation based on kexec."
 HOMEPAGE = "http://kexecboot.org"
@@ -39,14 +6,13 @@
 PV = "0.6+git${SRCPV}"
 S = "${WORKDIR}/git"
 SRC_URI = "git://github.com/kexecboot/kexecboot.git"
-SRCREV = "4c4f127e79ac5b8d6b6e2fbb938ccbf12b04c531"
+SRCREV = "4c01d6960aa6a9d03675605062469ab777fa2b01"
 inherit autotools
 
 EXTRA_OECONF = "--enable-textui --enable-delay=2 --enable-evdev-rate=1000,250"
 
 do_install () {
-    install -d ${D}${bindir}
-    install -m 0755 kexecboot ${D}${bindir}
+    install -D -m 0755 ${B}/src/kexecboot ${D}${bindir}/kexecboot
     install -d ${D}/proc
     install -d ${D}/mnt
     install -d ${D}/dev
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/dracut/dracut_git.bb b/meta-openembedded/meta-initramfs/recipes-devtools/dracut/dracut_git.bb
index ccf9f6a..dd2e8bb 100644
--- a/meta-openembedded/meta-initramfs/recipes-devtools/dracut/dracut_git.bb
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/dracut/dracut_git.bb
@@ -6,10 +6,10 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
 
 PE = "1"
-PV = "046+git${SRCREV}"
+PV = "049"
 
-# v046 tag
-SRCREV = "a0799ffb554487a370c2a1adafaedd2021b6dc8c"
+# v048 tag
+SRCREV = "225e4b94cbdb702cf512490dcd2ad9ca5f5b22c1"
 SRC_URI = "git://git.kernel.org/pub/scm/boot/dracut/dracut.git;protocol=http \
            file://0001-util.h-include-sys-reg.h-when-libc-glibc.patch \
            "
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/grubby/grubby/0001-Add-another-variable-LIBS-to-provides-libraries-from.patch b/meta-openembedded/meta-initramfs/recipes-devtools/grubby/grubby/0001-Add-another-variable-LIBS-to-provides-libraries-from.patch
index 1b1a993..dfbe7ba 100644
--- a/meta-openembedded/meta-initramfs/recipes-devtools/grubby/grubby/0001-Add-another-variable-LIBS-to-provides-libraries-from.patch
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/grubby/grubby/0001-Add-another-variable-LIBS-to-provides-libraries-from.patch
@@ -1,26 +1,24 @@
-From 22afaa21b4b258082be591e54c99e1ba6fbd7748 Mon Sep 17 00:00:00 2001
+From b7b3caa9b5c8abcd3c371d0683001cd681e104b3 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sat, 15 Jul 2017 10:19:22 -0700
 Subject: [PATCH 1/2] Add another variable LIBS to provides libraries from env
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
 ---
  Makefile | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/Makefile b/Makefile
-index ac14404..92a8e73 100644
+index cc7e823..ae30a07 100644
 --- a/Makefile
 +++ b/Makefile
-@@ -27,7 +27,7 @@ RPM_OPT_FLAGS ?= -O2 -g -pipe -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector
- CFLAGS += $(RPM_OPT_FLAGS) -std=gnu99 -Wall -Werror -Wno-error=unused-function -Wno-unused-function -ggdb
- LDFLAGS := 
+@@ -31,7 +31,7 @@ ifneq ($(VERBOSE_TEST),)
+ 	VERBOSE_TEST="--verbose"
+ endif
  
 -grubby_LIBS = -lblkid -lpopt
 +grubby_LIBS = -lblkid -lpopt ${LIBS}
  
  all: grubby
  
--- 
-2.13.3
-
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/grubby/grubby/grubby-rename-grub2-editenv-to-grub-editenv.patch b/meta-openembedded/meta-initramfs/recipes-devtools/grubby/grubby/grubby-rename-grub2-editenv-to-grub-editenv.patch
index d936249..e693916 100644
--- a/meta-openembedded/meta-initramfs/recipes-devtools/grubby/grubby/grubby-rename-grub2-editenv-to-grub-editenv.patch
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/grubby/grubby/grubby-rename-grub2-editenv-to-grub-editenv.patch
@@ -1,4 +1,4 @@
-From 0841706a5b5280e501c8e392c70c466c5fbcf0aa Mon Sep 17 00:00:00 2001
+From 15f0572f2f456c2c1b700bc790d9ce7a5c13cc74 Mon Sep 17 00:00:00 2001
 From: Jackie Huang <jackie.huang@windriver.com>
 Date: Tue, 4 Aug 2015 23:54:41 -0700
 Subject: [PATCH] rename grub2-editenv to grub-editenv
@@ -8,38 +8,48 @@
 Upstream-Status: Inappropriate
 
 Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
+
 ---
  grubby.c | 4 ++--
- test.sh  | 6 +++---
- 2 files changed, 5 insertions(+), 5 deletions(-)
+ test.sh  | 8 ++++----
+ 2 files changed, 6 insertions(+), 6 deletions(-)
 
 diff --git a/grubby.c b/grubby.c
-index d4ebb86..47a1a15 100644
+index 396041a..3ceae69 100644
 --- a/grubby.c
 +++ b/grubby.c
-@@ -290,7 +290,7 @@ static char *grub2GetEnv(struct configFileInfo *info, char *name)
-     char *s = NULL;
-     char *ret = NULL;
-     char *envFile = info->envFile ? info->envFile : "/boot/grub2/grubenv";
--    int rc = asprintf(&s, "grub2-editenv %s list | grep '^%s='", envFile, name);
-+    int rc = asprintf(&s, "grub-editenv %s list | grep '^%s='", envFile, name);
+@@ -301,7 +301,7 @@ static char *grub2GetEnv(struct configFileInfo *info, char *name)
+ 	char *ret = NULL;
+ 	char *envFile = info->envFile ? info->envFile : "/boot/grub2/grubenv";
+ 	int rc =
+-	    asprintf(&s, "grub2-editenv %s list | grep '^%s='", envFile, name);
++	    asprintf(&s, "grub-editenv %s list | grep '^%s='", envFile, name);
  
-     if (rc < 0)
- 	return NULL;
-@@ -361,7 +361,7 @@ static int grub2SetEnv(struct configFileInfo *info, char *name, char *value)
-     if (!value)
- 	    return -1;
+ 	if (rc < 0)
+ 		return NULL;
+@@ -373,7 +373,7 @@ static int grub2SetEnv(struct configFileInfo *info, char *name, char *value)
+ 	if (!value)
+ 		return -1;
  
--    rc = asprintf(&s, "grub2-editenv %s set '%s=%s'", envFile, name, value);
-+    rc = asprintf(&s, "grub-editenv %s set '%s=%s'", envFile, name, value);
-     free(value);
-     if (rc <0)
- 	return -1;
+-	rc = asprintf(&s, "grub2-editenv %s set '%s=%s'", envFile, name, value);
++	rc = asprintf(&s, "grub-editenv %s set '%s=%s'", envFile, name, value);
+ 	free(value);
+ 	if (rc < 0)
+ 		return -1;
 diff --git a/test.sh b/test.sh
-index 6379698..f738388 100755
+index 33d24cf..009479c 100755
 --- a/test.sh
 +++ b/test.sh
-@@ -574,7 +574,7 @@ if [ "$testgrub2" == "y" ]; then
+@@ -573,7 +573,7 @@ if [ "$testgrub2" == "y" ]; then
+         --remove-kernel=/boot/vmlinuz-2.6.38.2-9.fc15.x86_64 \
+         --boot-filesystem=/boot/
+     commandTest "saved_default output" \
+-        "grub2-editenv test/grub2-support_files/env_temp list" \
++        "grub-editenv test/grub2-support_files/env_temp list" \
+         "saved_entry=Linux, with Fedora 2.6.38.8-32.fc15.x86_64"
+ 
+     # copy a stanza and add arguments as well, while using --set-index=
+@@ -627,7 +627,7 @@ if [ "$testgrub2" == "y" ]; then
          --title='title' --initrd=/boot/new-initrd --boot-filesystem=/boot/ \
          --copy-default
      commandTest "saved_default output" \
@@ -48,7 +58,7 @@
          "saved_entry=Linux, with Fedora 2.6.38.8-32.fc15.x86_64"
  
      testing="GRUB2 add kernel with default=saved_entry and a terrible title"
-@@ -587,13 +587,13 @@ if [ "$testgrub2" == "y" ]; then
+@@ -640,13 +640,13 @@ if [ "$testgrub2" == "y" ]; then
      testing="GRUB2 set default with default=saved_entry and a terrible name"
      grub2Test grub2.9 add/g2-1.9 --env grubenv.1 --set-default-index=0
      commandTest "saved_default output" \
@@ -64,6 +74,3 @@
          "saved_entry=title"
  
      testing="GRUB2 --default-index with default=saved_entry"
--- 
-2.3.5
-
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/grubby/grubby_git.bb b/meta-openembedded/meta-initramfs/recipes-devtools/grubby/grubby_git.bb
new file mode 100644
index 0000000..8430b7e
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/grubby/grubby_git.bb
@@ -0,0 +1,40 @@
+SUMMARY = "A command line tool for updating and displaying info about boot loaders"
+DESCRIPTION = "grubby is a command line tool for updating and displaying information \
+about the configuration files for the grub, lilo, elilo (ia64), yaboot (powerpc) and \
+zipl (s390) boot loaders. It is primarily designed to be used from scripts which install \
+new kernels and need to find information about the current boot environment. \
+"
+HOMEPAGE = "https://github.com/rhboot/grubby"
+LICENSE = "GPLv2+"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=892f569a555ba9c07a568a7c0c4fa63a"
+
+DEPENDS = "popt util-linux"
+DEPENDS_append_libc-musl = " libexecinfo"
+
+S = "${WORKDIR}/git"
+SRCREV = "a1d2ae93408c3408e672d7eba4550fdf27fb0201"
+SRC_URI = "git://github.com/rhboot/grubby.git;protocol=https; \
+           file://grubby-rename-grub2-editenv-to-grub-editenv.patch \
+           file://run-ptest \
+           file://0001-Add-another-variable-LIBS-to-provides-libraries-from.patch \
+           file://0002-include-paths.h-for-_PATH_MOUNTED.patch \
+           "
+
+RDEPENDS_${PN} += "dracut"
+
+inherit autotools-brokensep ptest
+
+EXTRA_OEMAKE = "-e 'CC=${CC}' 'LDFLAGS=${LDFLAGS}' LIBS='${LIBS}'"
+
+LIBS_libc-musl = "-lexecinfo"
+LIBS ?= ""
+do_install_ptest() {
+    install -d ${D}${PTEST_PATH}
+    cp -r ${S}/test ${S}/test.sh ${D}${PTEST_PATH}
+    sed -i 's|./grubby|grubby|' ${D}${PTEST_PATH}/test.sh
+}
+
+RDEPENDS_${PN}-ptest = "util-linux-getopt bash"
+
+COMPATIBLE_HOST = '(x86_64.*|i.86.*)-(linux|freebsd.*)'
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-2.0.4/0001-klibc-Kbuild-Accept-EXTRA_KLIBCAFLAGS.patch b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-2.0.4/0001-klibc-Kbuild-Accept-EXTRA_KLIBCAFLAGS.patch
new file mode 100644
index 0000000..94818e3
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-2.0.4/0001-klibc-Kbuild-Accept-EXTRA_KLIBCAFLAGS.patch
@@ -0,0 +1,28 @@
+From cdc6edc2cfcd0ce88d6e66654d605dad303b1a75 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 11 Sep 2018 17:03:36 -0700
+Subject: [PATCH] klibc/Kbuild: Accept EXTRA_KLIBCAFLAGS
+
+For passing additional assembler flags
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ usr/klibc/Kbuild | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/usr/klibc/Kbuild b/usr/klibc/Kbuild
+index 98caf2e9..b34521e0 100644
+--- a/usr/klibc/Kbuild
++++ b/usr/klibc/Kbuild
+@@ -168,7 +168,8 @@ $(SOHASH): $(SOLIB) $(SOLIB).hash
+ targets += interp.o
+ 
+ quiet_cmd_interp = BUILD   $@
+-      cmd_interp = $(KLIBCCC) $(klibccflags) -D__ASSEMBLY__     \
++      cmd_interp = $(KLIBCCC) $(klibccflags) $(EXTRA_KLIBCAFLAGS) \
++                             -D__ASSEMBLY__     \
+                              -DLIBDIR=\"$(SHLIBDIR)\"         \
+ 			     -DSOHASH=\"$(SOLIBHASH)\" \
+ 			     -c -o $@ $<
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-2.0.4/0001-klibc-add-getrandom-syscall.patch b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-2.0.4/0001-klibc-add-getrandom-syscall.patch
new file mode 100644
index 0000000..0768f6d
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-2.0.4/0001-klibc-add-getrandom-syscall.patch
@@ -0,0 +1,27 @@
+From e4d5d5224609d7d5c824dd231f5baec868befdfa Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Tue, 4 Sep 2018 23:56:00 +0200
+Subject: [PATCH 1/1] klibc: add getrandom() syscall
+
+needed by latest kexec-tools for qemuarm64 (kashan)
+
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+---
+ usr/klibc/SYSCALLS.def | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/usr/klibc/SYSCALLS.def b/usr/klibc/SYSCALLS.def
+index 6b3bf4c..d4184ba 100644
+--- a/usr/klibc/SYSCALLS.def
++++ b/usr/klibc/SYSCALLS.def
+@@ -274,6 +274,7 @@ int syslog::klogctl(int, char *, int);
+ int sysinfo(struct sysinfo *);
+ long kexec_load(void *, unsigned long, struct kexec_segment *, unsigned long);
+ <x86_64,ppc64,s390x> long kexec_file_load(int, int, unsigned long, const char *, unsigned long);
++ssize_t getrandom(void *, size_t, unsigned int);
+ 
+ /*
+  * Low-level I/O (generally architecture-specific);
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-2.0.4/0001-klibc-static-utils-do-not-build-shared-binaries.patch b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-2.0.4/0001-klibc-static-utils-do-not-build-shared-binaries.patch
new file mode 100644
index 0000000..2f7cd35
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-2.0.4/0001-klibc-static-utils-do-not-build-shared-binaries.patch
@@ -0,0 +1,213 @@
+From c034dceae17b7d8d437871afe5eba55a55434222 Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Wed, 10 Oct 2018 00:48:31 +0200
+Subject: [PATCH] klibc-static-utils: do not build shared binaries
+
+We were building some shared utilities and this was leading to linker errors
+for x86 with security flags enabled.
+
+Fix
+ i586-oe-linux-musl-ld.bfd: discarded output section: `.got.plt'
+
+Upstream-Status: Inappropriate [Embedded Specific]
+
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+---
+ usr/dash/Kbuild           | 6 +-----
+ usr/kinit/Kbuild          | 4 +---
+ usr/kinit/fstype/Kbuild   | 4 +---
+ usr/kinit/ipconfig/Kbuild | 4 +---
+ usr/kinit/nfsmount/Kbuild | 4 +---
+ usr/kinit/resume/Kbuild   | 5 +----
+ usr/kinit/run-init/Kbuild | 5 +----
+ usr/utils/Kbuild          | 7 ++-----
+ 8 files changed, 9 insertions(+), 30 deletions(-)
+
+diff --git a/usr/dash/Kbuild b/usr/dash/Kbuild
+index 1a6920a..b3a4e64 100644
+--- a/usr/dash/Kbuild
++++ b/usr/dash/Kbuild
+@@ -25,12 +25,8 @@ gen-h-files := builtins.h nodes.h syntax.h token.h
+ 
+ static-y := sh
+ 
+-# The shared binary
+-shared-y    := sh.shared
+-sh.shared-y := $(sh-y)
+-
+ # For cleaning
+-targets := sh sh.g sh.shared sh.shared.g $(gen-o-files)
++targets := sh sh.g $(gen-o-files)
+ 
+ # explicit dependency for all generated files
+ $(addprefix $(obj)/, $(sh-y)): $(addprefix $(obj)/, $(gen-h-files))
+diff --git a/usr/kinit/Kbuild b/usr/kinit/Kbuild
+index f7fdccd..8db06ab 100644
+--- a/usr/kinit/Kbuild
++++ b/usr/kinit/Kbuild
+@@ -18,8 +18,6 @@ kinit-y  += fstype/
+ kinit-y  += resume/
+ 
+ static-y := kinit
+-shared-y := kinit.shared
+-kinit.shared-y := $(kinit-y)
+ 
+ # Additional include paths files
+ KLIBCCFLAGS += -I$(srctree)/$(src)/fstype \
+@@ -29,7 +27,7 @@ KLIBCCFLAGS += -I$(srctree)/$(src)/fstype \
+  	       -I$(srctree)/$(src)/run-init
+ 
+ # Cleaning
+-targets += kinit kinit.g kinit.shared kinit.shared.g
++targets += kinit kinit.g
+ subdir- := fstype ipconfig nfsmount resume run-init
+ 
+ 
+diff --git a/usr/kinit/fstype/Kbuild b/usr/kinit/fstype/Kbuild
+index 367611d..8d453ea 100644
+--- a/usr/kinit/fstype/Kbuild
++++ b/usr/kinit/fstype/Kbuild
+@@ -3,7 +3,6 @@
+ #
+ 
+ static-y := static/fstype
+-shared-y := shared/fstype
+ 
+ # common .o files
+ objs := main.o fstype.o
+@@ -16,8 +15,7 @@ lib-y := $(objs)
+ 
+ # .o files used to built executables
+ static/fstype-y := $(objs)
+-shared/fstype-y := $(objs)
+ 
+ # Cleaning
+-clean-dirs := static shared
++clean-dirs := static
+ 
+diff --git a/usr/kinit/ipconfig/Kbuild b/usr/kinit/ipconfig/Kbuild
+index eb1d472..ef87e7e 100644
+--- a/usr/kinit/ipconfig/Kbuild
++++ b/usr/kinit/ipconfig/Kbuild
+@@ -3,7 +3,6 @@
+ #
+ 
+ static-y := static/ipconfig
+-shared-y := shared/ipconfig
+ 
+ # common .o files
+ objs := main.o netdev.o packet.o
+@@ -22,8 +21,7 @@ lib-y := $(objs)
+ 
+ # .o files used to built executables
+ static/ipconfig-y := $(objs)
+-shared/ipconfig-y := $(objs)
+ 
+ # Cleaning
+-clean-dirs := static shared
++clean-dirs := static
+ 
+diff --git a/usr/kinit/nfsmount/Kbuild b/usr/kinit/nfsmount/Kbuild
+index ba31708..01bedce 100644
+--- a/usr/kinit/nfsmount/Kbuild
++++ b/usr/kinit/nfsmount/Kbuild
+@@ -4,7 +4,6 @@
+ 
+ static-y := static/nfsmount
+ #FIXME - build is broken static-y := dummypmap
+-shared-y := shared/nfsmount
+ 
+ objs := main.o mount.o portmap.o dummypmap.o sunrpc.o
+ 
+@@ -13,7 +12,6 @@ lib-y := $(objs)
+ 
+ # .o files used for executables
+ static/nfsmount-y := $(objs)
+-shared/nfsmount-y := $(objs)
+ 
+ # dummypmap uses a single .o file (rename src file?)
+ dummypmap-y := dummypmap_test.o
+@@ -21,5 +19,5 @@ dummypmap-y := dummypmap_test.o
+ # TODO - do we want a stripped version
+ # TODO - do we want the static.g + shared.g directories?
+ 
+-clean-dirs := static shared
++clean-dirs := static
+ 
+diff --git a/usr/kinit/resume/Kbuild b/usr/kinit/resume/Kbuild
+index c1342e1..15b9590 100644
+--- a/usr/kinit/resume/Kbuild
++++ b/usr/kinit/resume/Kbuild
+@@ -3,7 +3,6 @@
+ #
+ 
+ static-y := static/resume
+-shared-y := shared/resume
+ 
+ # common .o files
+ objs := resume.o resumelib.o
+@@ -20,9 +19,7 @@ KLIBCCFLAGS += -I$(srctree)/$(src)/..
+ # .o files used to built executables
+ static/resume-y   := $(objs)
+ static/resume-lib := ../lib.a
+-shared/resume-y   := $(objs)
+-shared/resume-lib := ../lib.a
+ 
+ # Cleaning
+-clean-dirs := static shared
++clean-dirs := static
+ 
+diff --git a/usr/kinit/run-init/Kbuild b/usr/kinit/run-init/Kbuild
+index c153b0a..a1ea834 100644
+--- a/usr/kinit/run-init/Kbuild
++++ b/usr/kinit/run-init/Kbuild
+@@ -3,7 +3,6 @@
+ #
+ 
+ static-y := static/run-init
+-shared-y := shared/run-init
+ 
+ # common .o files
+ objs := run-init.o runinitlib.o
+@@ -24,9 +23,7 @@ KLIBCCFLAGS += -I$(srctree)/$(src)/..
+ # .o files used to built executables
+ static/run-init-y   := $(objs)
+ static/run-init-lib := ../lib.a
+-shared/run-init-y   := $(objs)
+-shared/run-init-lib := ../lib.a
+ 
+ # Cleaning
+-clean-dirs := static shared
++clean-dirs := static
+ 
+diff --git a/usr/utils/Kbuild b/usr/utils/Kbuild
+index 67d9486..1573363 100644
+--- a/usr/utils/Kbuild
++++ b/usr/utils/Kbuild
+@@ -7,7 +7,6 @@ progs += true false sleep ln mv nuke minips cat ls losetup
+ progs += uname halt kill readlink cpio sync dmesg
+ 
+ static-y := $(addprefix static/, $(progs))
+-shared-y := $(addprefix shared/, $(progs))
+ 
+ # The binary is placed in a subdir, so we need to tell kbuild this
+ static/chroot-y     := chroot.o
+@@ -62,13 +61,11 @@ static/losetup-y    := losetup.o
+ shared/losetup-y    := losetup.o
+ 
+ # Additionally linked targets
+-always := static/reboot static/poweroff shared/reboot shared/poweroff
++always := static/reboot static/poweroff
+ 
+ $(obj)/static/reboot $(obj)/static/poweroff: $(obj)/static/halt
+ 	$(call cmd,ln)
+-$(obj)/shared/reboot $(obj)/shared/poweroff: $(obj)/shared/halt
+-	$(call cmd,ln)
+ 
+ # Clean deletes the static and shared dir
+-clean-dirs := static shared
++clean-dirs := static
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-2.0.4/0001-klibc_2.0.4-add-kexec_file_load-syscall.patch b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-2.0.4/0001-klibc_2.0.4-add-kexec_file_load-syscall.patch
new file mode 100644
index 0000000..3d8d987
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-2.0.4/0001-klibc_2.0.4-add-kexec_file_load-syscall.patch
@@ -0,0 +1,27 @@
+From 90683d5eaabfa684a71411d6e3262153ac191ad8 Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Tue, 4 Sep 2018 23:44:30 +0200
+Subject: [PATCH 1/1] klibc_2.0.4: add kexec_file_load syscall
+
+for supported archs only (matched in kexec-tools)
+
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+---
+ usr/klibc/SYSCALLS.def | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/usr/klibc/SYSCALLS.def b/usr/klibc/SYSCALLS.def
+index c56e8f9..6b3bf4c 100644
+--- a/usr/klibc/SYSCALLS.def
++++ b/usr/klibc/SYSCALLS.def
+@@ -273,6 +273,7 @@ int reboot::__reboot(int, int, int, void *);
+ int syslog::klogctl(int, char *, int);
+ int sysinfo(struct sysinfo *);
+ long kexec_load(void *, unsigned long, struct kexec_segment *, unsigned long);
++<x86_64,ppc64,s390x> long kexec_file_load(int, int, unsigned long, const char *, unsigned long);
+ 
+ /*
+  * Low-level I/O (generally architecture-specific);
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-2.0.4/klcc-cross-accept-clang-options.patch b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-2.0.4/klcc-cross-accept-clang-options.patch
new file mode 100644
index 0000000..07703aa
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-2.0.4/klcc-cross-accept-clang-options.patch
@@ -0,0 +1,19 @@
+meta-clang passes this option to compiler defaults
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Index: git/klcc/klcc.in
+===================================================================
+--- git.orig/klcc/klcc.in
++++ git/klcc/klcc.in
+@@ -207,6 +207,9 @@ while ( defined($a = shift(@ARGV)) ) {
+     } elsif ( $a =~ /^--([sysroot=])(.*)$/ ) {
+ 	# Override gcc encoded sysroot
+ 	push(@ccopt, $a);
++    } elsif ( $a eq '-no-integrated-as' ) {
++	# Allow clang options
++	push(@ccopt, $a);
+     } else {
+ 	die "$0: unknown option: $a\n";
+     }
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-static-utils_2.0.4.bb b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-static-utils_2.0.4.bb
index c835fd6..1677863 100644
--- a/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-static-utils_2.0.4.bb
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-static-utils_2.0.4.bb
@@ -10,3 +10,9 @@
 
 require klibc-utils.inc
 require klibc.inc
+
+SRC_URI += "file://0001-klibc-static-utils-do-not-build-shared-binaries.patch"
+
+# avoid textrel if linking with -pie
+SECURITY_CFLAGS = ""
+SECURITY_LDFLAGS = ""
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-utils.inc b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-utils.inc
index 7df33d6..2aac9e6 100644
--- a/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-utils.inc
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc-utils.inc
@@ -1,16 +1,16 @@
 do_install() {
     install -d ${D}${base_bindir}
     install -d ${D}${base_sbindir}
-    # debian packages kinit + kinit.shared but only sh.shared
     if [ "${KLIBC_UTILS_VARIANT}" = "shared" ]; then
-        install -m 755 usr/kinit/kinit ${D}${base_bindir}/kinit
         install -m 755 usr/kinit/kinit.shared ${D}${base_bindir}/kinit.shared
         install -m 755 usr/dash/sh.shared ${D}${base_bindir}/sh.shared
     else
         install -m 755 usr/dash/sh ${D}${base_bindir}/sh
         install -m 755 usr/kinit/kinit ${D}${base_bindir}/kinit
+        install -m 755 usr/gzip/gzip ${D}${base_bindir}
+        ln -s gzip ${D}${base_bindir}/gunzip
+        ln -s gzip ${D}${base_bindir}/zcat
     fi
-    install -m 755 usr/gzip/gzip ${D}${base_bindir}
     install -m 755 usr/kinit/fstype/${KLIBC_UTILS_VARIANT}/fstype ${D}${base_bindir}
     install -m 755 usr/kinit/ipconfig/${KLIBC_UTILS_VARIANT}/ipconfig ${D}${base_bindir}
     install -m 755 usr/kinit/nfsmount/${KLIBC_UTILS_VARIANT}/nfsmount ${D}${base_bindir}
@@ -44,8 +44,6 @@
     install -m 755 usr/utils/${KLIBC_UTILS_VARIANT}/true ${D}${base_bindir}
     install -m 755 usr/utils/${KLIBC_UTILS_VARIANT}/umount ${D}${base_bindir}
     install -m 755 usr/utils/${KLIBC_UTILS_VARIANT}/uname ${D}${base_bindir}
-    ln -s gzip ${D}${base_bindir}/gunzip
-    ln -s gzip ${D}${base_bindir}/zcat
 }
 
 EXTRA_KLIBC_DEPS = "${@oe.utils.conditional('KLIBC_UTILS_VARIANT', 'shared', '${THIS_LIBKLIBC}', '', d)}"
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc.inc b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc.inc
index 30294b1..be01c2f 100644
--- a/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc.inc
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/klibc/klibc.inc
@@ -12,6 +12,7 @@
            file://klibc-linux-libc-dev.patch \
            file://staging.patch \
            file://klcc-consider-sysroot.patch \
+           file://klcc-cross-accept-clang-options.patch \
            file://0001-dash-Specify-format-string-in-fmtstr.patch \
            file://0001-Define-in_-structs-for-non-glibc-system-libs.patch \
            file://0001-include-linux-sysinfo.h-directly.patch \
@@ -20,7 +21,10 @@
            file://0001-Kbuild.klibc-Use-print-libgcc-file-name-instead-of-p.patch \
            file://0001-Kbuild.klibc-Add-path-to-compiler-headers-via-isyste.patch \
            file://0001-arm-Do-not-set-a-fallback-march-and-mtune.patch \
-"
+           file://0001-klibc_2.0.4-add-kexec_file_load-syscall.patch \
+           file://0001-klibc-add-getrandom-syscall.patch \
+           file://0001-klibc-Kbuild-Accept-EXTRA_KLIBCAFLAGS.patch \
+           "
 
 ARMPATCHES ?= ""
 
@@ -28,7 +32,6 @@
                   file://armv4-fix-v4bx.patch \
                  "
 
-
 S = "${WORKDIR}/git"
 
 PARALLEL_MAKE = ""
@@ -44,6 +47,8 @@
                 'KLIBCOPTFLAGS=${TUNE_CCARGS} -Os' \
                  V=1 \
                 "
+EXTRA_OEMAKE += "'EXTRA_KLIBCAFLAGS=${SECURITY_CFLAGS} -Wa,--noexecstack' \
+                 'EXTRA_KLIBCLDFLAGS=${SECURITY_LDFLAGS} -z noexecstack'"
 
 export FIX_ARMV4_EABI_BX = "${FIX_V4BX}"
 KLIBCTHUMB = "${@['CONFIG_KLIBC_THUMB=n', 'CONFIG_KLIBC_THUMB=y'][(d.getVar('ARM_INSTRUCTION_SET') == 'thumb')]}"
@@ -70,5 +75,7 @@
 KLIBC_ARCH_powerpc64 = "ppc64"
 THIS_LIBKLIBC = "libklibc (= ${PV}-${PR})"
 
-SECURITY_CFLAGS = "-fno-PIE -no-pie"
-SECURITY_LDFLAGS = "-no-pie"
+GCCPIE ?= ""
+SECURITY_LDFLAGS = "${@'-z relro -z now -pie' if '${GCCPIE}' else ''}"
+SECURITY_LDFLAGS_mips = ""
+SECURITY_LDFLAGS_mips64 = ""
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0001-Makefile-build-ubi-utils-only.patch b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0001-Makefile-build-ubi-utils-only.patch
deleted file mode 100644
index 6ac2cca..0000000
--- a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0001-Makefile-build-ubi-utils-only.patch
+++ /dev/null
@@ -1,87 +0,0 @@
-From 1c989e4c36d0bf76ab444f984bc73b98eeacd03f Mon Sep 17 00:00:00 2001
-From: Andrea Adami <andrea.adami@gmail.com>
-Date: Sun, 29 Jun 2014 00:32:29 +0200
-Subject: [PATCH 1/9] Makefile: build ubi-utils only
-
-We build all the static ubi-utils but actually only ubiattach is needed in
-a minimalistic initramfs for the mount of ubi volumes.
-
-More fixes are needed in order to build the full mtd-utils.
-The first issue is:
-
-| mkfs.jffs2.c:64:20: fatal error: libgen.h: No such file or directory
-|  #include <libgen.h>
-
-Removing the include then the second error is:
-
-| mkfs.jffs2.c:1570:22: error: '_SC_PAGESIZE' undeclared
-| (first use in this function)
-|   page_size = sysconf(_SC_PAGESIZE);
-
-Upstream-Status: Inappropriate [embedded specific]
-
-Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
----
- Makefile | 26 ++------------------------
- 1 file changed, 2 insertions(+), 24 deletions(-)
-
-diff --git a/Makefile b/Makefile
-index 3ce8587..8b79f71 100644
---- a/Makefile
-+++ b/Makefile
-@@ -16,28 +16,11 @@ endif
- 
- TESTS = tests
- 
--MTD_BINS = \
--	ftl_format flash_erase nanddump doc_loadbios \
--	ftl_check mkfs.jffs2 flash_lock flash_unlock \
--	flash_otp_info flash_otp_dump flash_otp_lock flash_otp_write \
--	mtd_debug flashcp nandwrite nandtest mtdpart \
--	jffs2dump \
--	nftldump nftl_format docfdisk \
--	rfddump rfdformat \
--	serve_image recv_image \
--	sumtool jffs2reader
- UBI_BINS = \
- 	ubiupdatevol ubimkvol ubirmvol ubicrc32 ubinfo ubiattach \
- 	ubidetach ubinize ubiformat ubirename mtdinfo ubirsvol ubiblock
- 
--BINS = $(MTD_BINS)
--BINS += mkfs.ubifs/mkfs.ubifs
--BINS += $(addprefix ubi-utils/,$(UBI_BINS))
--SCRIPTS = flash_eraseall
--
--TARGETS = $(BINS)
--TARGETS += lib/libmtd.a
--TARGETS += ubi-utils/libubi.a
-+BINS = $(addprefix ubi-utils/,$(UBI_BINS))
- 
- OBJDEPS = $(BUILDDIR)/include/version.h
- 
-@@ -61,12 +44,9 @@ endif
- 	rm -f $(BUILDDIR)/include/version.h
- 	$(MAKE) -C $(TESTS) clean
- 
--install:: $(addprefix $(BUILDDIR)/,${BINS}) ${SCRIPTS}
-+install:: $(addprefix $(BUILDDIR)/,${BINS})
- 	mkdir -p ${DESTDIR}/${SBINDIR}
- 	install -m 0755 $^ ${DESTDIR}/${SBINDIR}/
--	mkdir -p ${DESTDIR}/${MANDIR}/man1
--	install -m 0644 mkfs.jffs2.1 ${DESTDIR}/${MANDIR}/man1/
--	-gzip -9f ${DESTDIR}/${MANDIR}/man1/*.1
- 
- tests::
- 	$(MAKE) -C $(TESTS)
-@@ -91,8 +71,6 @@ LDLIBS_mkfs.jffs2  = -lz $(LZOLDLIBS)
- LDFLAGS_jffs2reader = $(ZLIBLDFLAGS) $(LZOLDFLAGS)
- LDLIBS_jffs2reader  = -lz $(LZOLDLIBS)
- 
--$(foreach v,$(MTD_BINS),$(eval $(call mkdep,,$(v))))
--
- #
- # Common libmtd
- #
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0002-common.mk-for-klibc-CC-is-klcc.patch b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0002-common.mk-for-klibc-CC-is-klcc.patch
deleted file mode 100644
index c23d11f..0000000
--- a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0002-common.mk-for-klibc-CC-is-klcc.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 89c76bbe82a2029a25b0654eb0a1d0b22d6e6877 Mon Sep 17 00:00:00 2001
-From: Andrea Adami <andrea.adami@gmail.com>
-Date: Sun, 29 Jun 2014 00:37:28 +0200
-Subject: [PATCH 2/9] common.mk: for klibc $(CC) is klcc
-
-Do not hardcode: assign the value to the variable if it is not already defined.
-
-Upstream-Status: Submitted
-
-Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
----
- common.mk | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/common.mk b/common.mk
-index ba87377..126d11a 100644
---- a/common.mk
-+++ b/common.mk
-@@ -1,4 +1,4 @@
--CC := $(CROSS)gcc
-+CC ?= $(CROSS)gcc
- AR := $(CROSS)ar
- RANLIB := $(CROSS)ranlib
- 
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0003-libubi.c-add-klibc-specific-fixes-for-ioctl.patch b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0003-libubi.c-add-klibc-specific-fixes-for-ioctl.patch
deleted file mode 100644
index 9ad4a5b..0000000
--- a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0003-libubi.c-add-klibc-specific-fixes-for-ioctl.patch
+++ /dev/null
@@ -1,76 +0,0 @@
-From fecbb7056d621a30f7106e67f5fe209763571b70 Mon Sep 17 00:00:00 2001
-From: Andrea Adami <andrea.adami@gmail.com>
-Date: Sun, 29 Jun 2014 00:40:15 +0200
-Subject: [PATCH 3/9] libubi.c: add klibc specific fixes for ioctl
-
-First issue is that ioctl() in klibc doesn't expect a constant as arg3.
-Second issue is that arg3 in klibc ioctl() implementation is not optional.
-
-Fixes:
-
-| ubi-utils/libubi.c: In function 'do_attach':
-| ubi-utils/libubi.c:698:8: warning: passing argument 3 of 'ioctl' discards
-| 'const' qualifier from pointer target type
-|   ret = ioctl(fd, UBI_IOCATT, r);
-|         ^
-| In file included from ubi-utils/libubi.c:32:0:
-| .../lib/klibc/include/sys/ioctl.h:15:14: note: expected 'void *' but argument
-| is of type 'const struct ubi_attach_req *'
-|  __extern int ioctl(int, int, void *);
-|               ^
-
-| ubi-utils/libubi.c: In function 'ubi_vol_block_create':
-| ubi-utils/libubi.c:1118:9: error: too few arguments to function 'ioctl'
-|   return ioctl(fd, UBI_IOCVOLCRBLK);
-|          ^
-| In file included from ubi-utils/libubi.c:32:0:
-| .../lib/klibc/include/sys/ioctl.h:15:14: note: declared here
-|  __extern int ioctl(int, int, void *);
-|               ^
-| ubi-utils/libubi.c: In function 'ubi_vol_block_remove':
-| ubi-utils/libubi.c:1123:9: error: too few arguments to function 'ioctl'
-|   return ioctl(fd, UBI_IOCVOLRMBLK);
-|          ^
-| In file included from ubi-utils/libubi.c:32:0:
-| .../usr/lib/klibc/include/sys/ioctl.h:15:14: note: declared here
-|  __extern int ioctl(int, int, void *);
-|               ^
-
-Upstream-Status: Accepted
-
-Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
----
- ubi-utils/libubi.c | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/ubi-utils/libubi.c b/ubi-utils/libubi.c
-index 97c0434..2b49833 100644
---- a/ubi-utils/libubi.c
-+++ b/ubi-utils/libubi.c
-@@ -687,7 +687,7 @@ void libubi_close(libubi_t desc)
-  * success and %-1 in case of failure. @r->ubi_num contains newly created UBI
-  * device number.
-  */
--static int do_attach(const char *node, const struct ubi_attach_req *r)
-+static int do_attach(const char *node, struct ubi_attach_req *r)
- {
- 	int fd, ret;
- 
-@@ -1115,12 +1115,12 @@ int ubi_rsvol(libubi_t desc, const char *node, int vol_id, long long bytes)
- 
- int ubi_vol_block_create(int fd)
- {
--	return ioctl(fd, UBI_IOCVOLCRBLK);
-+	return ioctl(fd, UBI_IOCVOLCRBLK, NULL);
- }
- 
- int ubi_vol_block_remove(int fd)
- {
--	return ioctl(fd, UBI_IOCVOLRMBLK);
-+	return ioctl(fd, UBI_IOCVOLRMBLK, NULL);
- }
- 
- int ubi_update_start(libubi_t desc, int fd, long long bytes)
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0004-Restore-compatibility-to-dietlibc-klibc-musl-libc-af.patch b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0004-Restore-compatibility-to-dietlibc-klibc-musl-libc-af.patch
deleted file mode 100644
index 2f31fb4..0000000
--- a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0004-Restore-compatibility-to-dietlibc-klibc-musl-libc-af.patch
+++ /dev/null
@@ -1,88 +0,0 @@
-From b668cb75cb7e72ff92055209130d4cd4b3cacbdb Mon Sep 17 00:00:00 2001
-From: Thorsten Glaser <tg@mirbsd.org>
-Date: Fri, 20 Jun 2014 10:56:27 +0000
-Subject: [PATCH 4/9] Restore compatibility to dietlibc, klibc, musl libc after
- commit 4f1b108
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Each C library has their own way to define off_t, and the <features.h>
-header is nonstandard and specific to the GNU libc and those that clone
-it (uClibc). Fefe’s dietlibc uses different flags, and klibc always uses
-a 64-bit off_t (like the BSDs); musl libc cannot be recognised using cpp
-instructions, so we assume 64 bit there (and on unknown C libraries) and
-leave it to the user to submit a follow-up fix if we guess wrong. I also
-added a static assertion to verify the 64 bit guess is correct.
-
-It would be really better using a configure script for this instead.
-
-Fixes:
-|   CC      lib/libmtd.o
-| In file included from ubi-utils/ubiutils-common.c:35:0:
-| ./include/common.h:29:22: fatal error: features.h: No such file or directory
-|  #include <features.h>
-|                       ^
-| compilation terminated.
-
-Upstream-Status: Submitted
-
-Signed-off-by: Thorsten Glaser <tg@mirbsd.org>
-Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
----
- include/common.h | 24 ++++++++++++++++++++++++
- 1 file changed, 24 insertions(+)
-
-diff --git a/include/common.h b/include/common.h
-index fb0ca83..5a20964 100644
---- a/include/common.h
-+++ b/include/common.h
-@@ -26,7 +26,9 @@
- #include <string.h>
- #include <fcntl.h>
- #include <errno.h>
-+#if defined(__GLIBC__) || defined(__UCLIBC__)
- #include <features.h>
-+#endif
- #include <inttypes.h>
- #include "version.h"
- 
-@@ -67,6 +69,21 @@ extern "C" {
- #endif
- 
- /* define a print format specifier for off_t */
-+#if defined(__KLIBC__)
-+/* always 64 bit on klibc */
-+#define PRIxoff_t PRIx64
-+#define PRIdoff_t PRId64
-+#elif defined(__dietlibc__)
-+/* depends on compiler flags on dietlibc */
-+#if defined(_FILE_OFFSET_BITS) && (_FILE_OFFSET_BITS == 64)
-+#define PRIxoff_t PRIx64
-+#define PRIdoff_t PRId64
-+#else
-+#define PRIxoff_t "l"PRIx32
-+#define PRIdoff_t "l"PRId32
-+#endif
-+#elif defined(__GLIBC__) || defined(__UCLIBC__)
-+/* depends on compiler flags on glibc and uClibc */
- #ifdef __USE_FILE_OFFSET64
- #define PRIxoff_t PRIx64
- #define PRIdoff_t PRId64
-@@ -74,6 +91,13 @@ extern "C" {
- #define PRIxoff_t "l"PRIx32
- #define PRIdoff_t "l"PRId32
- #endif
-+#else
-+/* unknown libc or musl */
-+#define PRIxoff_t PRIx64
-+#define PRIdoff_t PRId64
-+/* verify our guess of 64 bit is correct */
-+static char __PRIxoff_t_static_assert[sizeof(off_t) == 8 ? 1 : -1];
-+#endif
- 
- /* Verbose messages */
- #define bareverbose(verbose, fmt, ...) do {                        \
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0005-common.h-more-workarounds-for-klibc-compatibility.patch b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0005-common.h-more-workarounds-for-klibc-compatibility.patch
deleted file mode 100644
index 8309a72..0000000
--- a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0005-common.h-more-workarounds-for-klibc-compatibility.patch
+++ /dev/null
@@ -1,52 +0,0 @@
-From 5d4a66b502003ef385dab31a17012246407e7364 Mon Sep 17 00:00:00 2001
-From: Andrea Adami <andrea.adami@gmail.com>
-Date: Sun, 29 Jun 2014 00:44:03 +0200
-Subject: [PATCH 5/9] common.h: more workarounds for klibc compatibility
-
-Patch is addressing two issues:
-* First,  Klibc doesn't have rpmatch().
-* Second, Klibc lacks getline()
-
-Fixes:
-|   LD      ubi-utils/ubiformat
-| .../git/ubi-utils/ubiformat.o: In function `prompt':
-| .../git/./include/common.h:157: undefined reference to `getline'
-| .../git/./include/common.h:164: undefined reference to `rpmatch'
-| .../git/./include/common.h:157: undefined reference to `getline'
-| .../git/./include/common.h:164: undefined reference to `rpmatch'
-
-Upstream-Status: Submitted
-
-Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
----
- include/common.h | 8 +++++---
- 1 file changed, 5 insertions(+), 3 deletions(-)
-
-diff --git a/include/common.h b/include/common.h
-index 5a20964..2f51e1c 100644
---- a/include/common.h
-+++ b/include/common.h
-@@ -161,15 +161,17 @@ static inline int __rpmatch(const char *resp)
-  */
- static inline bool prompt(const char *msg, bool def)
- {
--	char *line = NULL;
--	size_t len;
-+	char *line;
- 	bool ret = def;
- 
-+	const int sizeof_line = 2;
-+	line = malloc(sizeof_line);
-+
- 	do {
- 		normsg_cont("%s (%c/%c) ", msg, def ? 'Y' : 'y', def ? 'n' : 'N');
- 		fflush(stdout);
- 
--		while (getline(&line, &len, stdin) == -1) {
-+		while (fgets(line, sizeof_line, stdin) == NULL) {
- 			printf("failed to read prompt; assuming '%s'\n",
- 				def ? "yes" : "no");
- 			break;
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0006-libiniparser-remove-unused-function-needing-float.patch b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0006-libiniparser-remove-unused-function-needing-float.patch
deleted file mode 100644
index d046f95..0000000
--- a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0006-libiniparser-remove-unused-function-needing-float.patch
+++ /dev/null
@@ -1,85 +0,0 @@
-From 2af30e9b2988111e45ed6ea6af55e49ec7cb1cb1 Mon Sep 17 00:00:00 2001
-From: Andrea Adami <andrea.adami@gmail.com>
-Date: Sun, 29 Jun 2014 00:44:57 +0200
-Subject: [PATCH 6/9] libiniparser: remove unused function needing float
-
-Fixes:
-|   LD      ubi-utils/ubiformat
-| .../git/ubi-utils/libiniparser.a(libiniparser.o): In function
-| `  LD      ubi-utils/ubirename
-| iniparser_getdouble':
-| .../git/ubi-utils/libiniparser.c:336: undefined reference to `atof'
-
-Grep doesn't reveal any occurrence of iniparser_getdouble(), using atof() so
-remove it: floating-point is not supported in klibc
-
-Upstream-Status: Accepted
-
-Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
----
- ubi-utils/include/libiniparser.h | 15 ---------------
- ubi-utils/libiniparser.c         | 22 ----------------------
- 2 files changed, 37 deletions(-)
-
-diff --git a/ubi-utils/include/libiniparser.h b/ubi-utils/include/libiniparser.h
-index be3c667..abd77aa 100644
---- a/ubi-utils/include/libiniparser.h
-+++ b/ubi-utils/include/libiniparser.h
-@@ -158,21 +158,6 @@ int iniparser_getint(dictionary * d, const char * key, int notfound);
- 
- /*-------------------------------------------------------------------------*/
- /**
--  @brief    Get the string associated to a key, convert to a double
--  @param    d Dictionary to search
--  @param    key Key string to look for
--  @param    notfound Value to return in case of error
--  @return   double
--
--  This function queries a dictionary for a key. A key as read from an
--  ini file is given as "section:key". If the key cannot be found,
--  the notfound value is returned.
-- */
--/*--------------------------------------------------------------------------*/
--double iniparser_getdouble(dictionary * d, char * key, double notfound);
--
--/*-------------------------------------------------------------------------*/
--/**
-   @brief    Get the string associated to a key, convert to a boolean
-   @param    d Dictionary to search
-   @param    key Key string to look for
-diff --git a/ubi-utils/libiniparser.c b/ubi-utils/libiniparser.c
-index 898f57f..ba70c08 100644
---- a/ubi-utils/libiniparser.c
-+++ b/ubi-utils/libiniparser.c
-@@ -316,28 +316,6 @@ int iniparser_getint(dictionary * d, const char * key, int notfound)
- 
- /*-------------------------------------------------------------------------*/
- /**
--  @brief    Get the string associated to a key, convert to a double
--  @param    d Dictionary to search
--  @param    key Key string to look for
--  @param    notfound Value to return in case of error
--  @return   double
--
--  This function queries a dictionary for a key. A key as read from an
--  ini file is given as "section:key". If the key cannot be found,
--  the notfound value is returned.
-- */
--/*--------------------------------------------------------------------------*/
--double iniparser_getdouble(dictionary * d, char * key, double notfound)
--{
--    char    *   str ;
--
--    str = iniparser_getstring(d, key, INI_INVALID_KEY);
--    if (str==INI_INVALID_KEY) return notfound ;
--    return atof(str);
--}
--
--/*-------------------------------------------------------------------------*/
--/**
-   @brief    Get the string associated to a key, convert to a boolean
-   @param    d Dictionary to search
-   @param    key Key string to look for
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0007-mtd-utils-common.c-convert-to-integer-arithmetic.patch b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0007-mtd-utils-common.c-convert-to-integer-arithmetic.patch
deleted file mode 100644
index 36b012f..0000000
--- a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0007-mtd-utils-common.c-convert-to-integer-arithmetic.patch
+++ /dev/null
@@ -1,64 +0,0 @@
-From 41e7c76b0853bf5241b38b8167dfd57c27fef1eb Mon Sep 17 00:00:00 2001
-From: Andrea Adami <andrea.adami@gmail.com>
-Date: Sun, 28 Jan 2018 21:47:59 +0100
-Subject: [PATCH 7/9] mtd-utils: common.c: convert to integer arithmetic
-
-We use floating point just to print out KiB, MiB, GiB.
-Avoid that to be klibc friendly.
-
-Fixes compilation for aarch64 against klibc:
-
-error: '-mgeneral-regs-only' is incompatible with floating-point argument
-|    printf("%s%.1f GiB", p, (double)bytes / (1024 * 1024 * 1024));
-etc.
-
-Note:
-* In the KiB case, we could apparently multiply by 100 before dividing
-  without risking overflow. This code simply avoids multiplications.
-
-Upstream-Status: Submitted
-
-Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
----
- ubi-utils/ubiutils-common.c | 18 ++++++++++++------
- 1 file changed, 12 insertions(+), 6 deletions(-)
-
-diff --git a/ubi-utils/ubiutils-common.c b/ubi-utils/ubiutils-common.c
-index 6609a6b..0ded2a4 100644
---- a/ubi-utils/ubiutils-common.c
-+++ b/ubi-utils/ubiutils-common.c
-@@ -107,6 +107,9 @@ long long ubiutils_get_bytes(const char *str)
- void ubiutils_print_bytes(long long bytes, int bracket)
- {
- 	const char *p;
-+	int GiB = 1024 * 1024 * 1024;
-+	int MiB = 1024 * 1024;
-+	int KiB = 1024;
- 
- 	if (bracket)
- 		p = " (";
-@@ -115,12 +118,15 @@ void ubiutils_print_bytes(long long bytes, int bracket)
- 
- 	printf("%lld bytes", bytes);
- 
--	if (bytes > 1024 * 1024 * 1024)
--		printf("%s%.1f GiB", p, (double)bytes / (1024 * 1024 * 1024));
--	else if (bytes > 1024 * 1024)
--		printf("%s%.1f MiB", p, (double)bytes / (1024 * 1024));
--	else if (bytes > 1024 && bytes != 0)
--		printf("%s%.1f KiB", p, (double)bytes / 1024);
-+	if (bytes > GiB)
-+		printf("%s%lld.%lld GiB", p,
-+		       bytes / GiB, bytes % GiB / (GiB / 10));
-+	else if (bytes > MiB)
-+		printf("%s%lld.%lld MiB", p,
-+		       bytes / MiB, bytes % MiB / (MiB / 10));
-+	else if (bytes > KiB && bytes != 0)
-+		printf("%s%lld.%lld KiB", p,
-+		       bytes / KiB, bytes % KiB / (KiB / 10));
- 	else
- 		return;
- 
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0008-ubi-utils-ubiformat.c-convert-to-integer-arithmetic.patch b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0008-ubi-utils-ubiformat.c-convert-to-integer-arithmetic.patch
deleted file mode 100644
index 5bd0574..0000000
--- a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0008-ubi-utils-ubiformat.c-convert-to-integer-arithmetic.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From e6f1a85c0a3df24fe3ca9a520dc697105e75a80c Mon Sep 17 00:00:00 2001
-From: Andrea Adami <andrea.adami@gmail.com>
-Date: Sat, 27 Jan 2018 09:39:26 +0100
-Subject: [PATCH 8/9] ubi-utils: ubiformat.c: convert to integer arithmetic
-
-Do not cast percent to double, it is just used as upper limit.
-Avoid floating point to fix compilation for aarch64 against klibc:
-
-error: '-mgeneral-regs-only' is incompatible with floating-point code
-|    int percent = ((double)si->ok_cnt)/si->good_cnt * 100;
-|        ^~~~~~~
-
-Notes:
-* The checks in the code above this line ensure that si->good_cnt is not 0.
-
-* The code assumes  si->good_cnt * 100  will not overflow, then we can use
-  (si->ok_cnt * 100) safely because the former is bigger.
-
-* The truncated result does not affect the logic:
-  i.e. a value of 49.9 is truncated to 49 and is still <50.
-
-Upstream-Status: Submitted
-
-Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
----
- ubi-utils/ubiformat.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/ubi-utils/ubiformat.c b/ubi-utils/ubiformat.c
-index 21409ca..d93164a 100644
---- a/ubi-utils/ubiformat.c
-+++ b/ubi-utils/ubiformat.c
-@@ -843,7 +843,7 @@ int main(int argc, char * const argv[])
- 	}
- 
- 	if (!args.override_ec && si->empty_cnt < si->good_cnt) {
--		int percent = ((double)si->ok_cnt)/si->good_cnt * 100;
-+		int percent = (si->ok_cnt * 100) / si->good_cnt;
- 
- 		/*
- 		 * Make sure the majority of eraseblocks have valid
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0009-Eliminate-warnings-about-implicit-non-const-casting-.patch b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0009-Eliminate-warnings-about-implicit-non-const-casting-.patch
deleted file mode 100644
index 658246a..0000000
--- a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-1.5.2/0009-Eliminate-warnings-about-implicit-non-const-casting-.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-From 2229f3b9fd4bad47794c28e558ad273173cea73d Mon Sep 17 00:00:00 2001
-From: Andrea Adami <andrea.adami@gmail.com>
-Date: Sat, 27 Jan 2018 09:52:46 +0100
-Subject: [PATCH 9/9] Eliminate warnings about implicit non-const casting in
- libmtd
-
-The mtd_get_dev_info1 function reads (among other things) name and type
-string into coresponding struct mtd_dev_info fields.
-
-The struct mtd_dev_info has the string fields marked const, requiring
-them to be cast to non-const version during initialization.
-
-This cast was previously omitted from the dev_read_data calls,
-triggering warnings during compilation.
-
-Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
-Signed-off-by: Richard Weinberger <richard@nod.at>
-
-Upstream-Status: Backport
-
-Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
----
- lib/libmtd.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/lib/libmtd.c b/lib/libmtd.c
-index 60b4782..5f0bcbc 100644
---- a/lib/libmtd.c
-+++ b/lib/libmtd.c
-@@ -746,13 +746,13 @@ int mtd_get_dev_info1(libmtd_t desc, int mtd_num, struct mtd_dev_info *mtd)
- 	if (dev_get_major(lib, mtd_num, &mtd->major, &mtd->minor))
- 		return -1;
- 
--	ret = dev_read_data(lib->mtd_name, mtd_num, &mtd->name,
-+	ret = dev_read_data(lib->mtd_name, mtd_num, (char *)&mtd->name,
- 			    MTD_NAME_MAX + 1);
- 	if (ret < 0)
- 		return -1;
- 	((char *)mtd->name)[ret - 1] = '\0';
- 
--	ret = dev_read_data(lib->mtd_type, mtd_num, &mtd->type_str,
-+	ret = dev_read_data(lib->mtd_type, mtd_num, (char *)&mtd->type_str,
- 			    MTD_TYPE_MAX + 1);
- 	if (ret < 0)
- 		return -1;
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-2.0.2/0001-libmissing.h-fix-klibc-build-when-using-glibc-toolch.patch b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-2.0.2/0001-libmissing.h-fix-klibc-build-when-using-glibc-toolch.patch
new file mode 100644
index 0000000..4ee9bd9
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-2.0.2/0001-libmissing.h-fix-klibc-build-when-using-glibc-toolch.patch
@@ -0,0 +1,40 @@
+From e596ae99059c28fa9bb3461e03e7ecaacbf41727 Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Wed, 23 May 2018 15:34:59 +0200
+Subject: [PATCH] libmissing.h: fix klibc build when using glibc toolchain
+
+klibc lacks execinfo.h so adda guard around it.
+Note: build with musl toolchain is ok even without this patch.
+
+Fix build error:
+
+| In file included from ../git/lib/execinfo.c:1:0:
+| ../git/include/libmissing.h:7:10: fatal error: execinfo.h: 
+ No such file or directory
+
+Upstream-Status: Inappropriate [klibc specific]
+
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+---
+ include/libmissing.h | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/include/libmissing.h b/include/libmissing.h
+index 0196033..832c372 100644
+--- a/include/libmissing.h
++++ b/include/libmissing.h
+@@ -3,9 +3,11 @@
+ 
+ #include "config.h"
+ 
++#ifndef __KLIBC__
+ #ifdef HAVE_EXECINFO_H
+ #include <execinfo.h>
+ #endif
++#endif
+ 
+ #ifndef HAVE_EXECINFO_H
+ int backtrace(void **buffer, int size);
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-2.0.2/0002-Instead-of-doing-preprocessor-magic-just-output-off_.patch b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-2.0.2/0002-Instead-of-doing-preprocessor-magic-just-output-off_.patch
new file mode 100644
index 0000000..5c6e097
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-2.0.2/0002-Instead-of-doing-preprocessor-magic-just-output-off_.patch
@@ -0,0 +1,326 @@
+From 01c98d5d5d044d9a125abcdbb2f3d771966365b0 Mon Sep 17 00:00:00 2001
+From: mirabilos <m@mirbsd.org>
+Date: Thu, 1 Feb 2018 15:34:07 +0100
+Subject: [PATCH] Instead of doing preprocessor magic, just output off_t as
+ long long
+
+Fix warnings abot PRIdoff_t in libmtd.c, in mtd_read (and mtd_write):
+
+In file included from ../git/lib/libmtd.c:40:0:
+../git/lib/libmtd.c: In function 'mtd_read':
+../git/include/common.h:110:18: warning: format '%ld' expects argument of
+ type 'long int', but argument 5 has type 'off_t {aka long long int}'
+ [-Wformat=]
+
+../git/include/common.h:120:2: note: in expansion of macro 'errmsg'
+  errmsg(fmt, ##__VA_ARGS__);                                         \
+  ^~~~~~
+../git/lib/libmtd.c:1082:10: note: in expansion of macro 'sys_errmsg'
+   return sys_errmsg("cannot seek mtd%d to offset %"PRIdoff_t,
+          ^~~~~~~~~~
+
+/usr/lib/klibc/include/inttypes.h:28:17: note: format string is defined here
+ #define PRId32 "d"
+
+Upstream-Status: Submitted
+
+Signed-off-by: Thorsten Glaser <tg@mirbsd.org>
+---
+ include/common.h                    | 18 ------------------
+ jffsX-utils/mkfs.jffs2.c            | 20 ++++++++++----------
+ lib/libmtd.c                        |  8 ++++----
+ misc-utils/flash_erase.c            |  6 +++---
+ misc-utils/flash_otp_write.c        |  2 +-
+ misc-utils/ftl_check.c              |  2 +-
+ misc-utils/mtd_debug.c              |  4 ++--
+ misc-utils/serve_image.c            |  4 ++--
+ tests/fs-tests/integrity/integck.c  |  4 ++--
+ tests/mtd-tests/nandpagetest.c      |  4 ++--
+ tests/ubi-tests/integ.c             |  6 +++---
+ ubifs-utils/mkfs.ubifs/mkfs.ubifs.c |  6 +++---
+ 12 files changed, 33 insertions(+), 51 deletions(-)
+
+diff --git a/include/common.h b/include/common.h
+index f8f72ea..642c212 100644
+--- a/include/common.h
++++ b/include/common.h
+@@ -70,24 +70,6 @@ extern "C" {
+ #define O_CLOEXEC 0
+ #endif
+ 
+-/* define a print format specifier for off_t */
+-#if (SIZEOF_OFF_T >= 8)
+-#define PRIxoff_t PRIx64
+-#define PRIdoff_t PRId64
+-#else
+-#define PRIxoff_t "l"PRIx32
+-#define PRIdoff_t "l"PRId32
+-#endif
+-
+-/* define a print format specifier for loff_t */
+-#if (SIZEOF_LOFF_T >= 8)
+-#define PRIxloff_t PRIx64
+-#define PRIdloff_t PRId64
+-#else
+-#define PRIxloff_t "l"PRIx32
+-#define PRIdloff_t "l"PRId32
+-#endif
+-
+ /* Verbose messages */
+ #define bareverbose(verbose, fmt, ...) do {                        \
+ 	if (verbose)                                               \
+diff --git a/jffsX-utils/mkfs.jffs2.c b/jffsX-utils/mkfs.jffs2.c
+index 9aa6c39..0661786 100644
+--- a/jffsX-utils/mkfs.jffs2.c
++++ b/jffsX-utils/mkfs.jffs2.c
+@@ -1237,8 +1237,8 @@ static void recursive_populate_directory(struct filesystem_entry *dir)
+ 		} else switch (e->sb.st_mode & S_IFMT) {
+ 			case S_IFDIR:
+ 				if (verbose) {
+-					printf("\td %04o %9" PRIdoff_t "             %5d:%-3d %s\n",
+-							e->sb.st_mode & ~S_IFMT, e->sb.st_size,
++					printf("\td %04o %9lld             %5d:%-3d %s\n",
++							e->sb.st_mode & ~S_IFMT, (long long)e->sb.st_size,
+ 							(int) (e->sb.st_uid), (int) (e->sb.st_gid),
+ 							e->name);
+ 				}
+@@ -1247,8 +1247,8 @@ static void recursive_populate_directory(struct filesystem_entry *dir)
+ 				break;
+ 			case S_IFSOCK:
+ 				if (verbose) {
+-					printf("\ts %04o %9" PRIdoff_t "             %5d:%-3d %s\n",
+-							e->sb.st_mode & ~S_IFMT, e->sb.st_size,
++					printf("\ts %04o %9lld             %5d:%-3d %s\n",
++							e->sb.st_mode & ~S_IFMT, (long long)e->sb.st_size,
+ 							(int) e->sb.st_uid, (int) e->sb.st_gid, e->name);
+ 				}
+ 				write_pipe(e);
+@@ -1256,8 +1256,8 @@ static void recursive_populate_directory(struct filesystem_entry *dir)
+ 				break;
+ 			case S_IFIFO:
+ 				if (verbose) {
+-					printf("\tp %04o %9" PRIdoff_t "             %5d:%-3d %s\n",
+-							e->sb.st_mode & ~S_IFMT, e->sb.st_size,
++					printf("\tp %04o %9lld             %5d:%-3d %s\n",
++							e->sb.st_mode & ~S_IFMT, (long long)e->sb.st_size,
+ 							(int) e->sb.st_uid, (int) e->sb.st_gid, e->name);
+ 				}
+ 				write_pipe(e);
+@@ -1285,8 +1285,8 @@ static void recursive_populate_directory(struct filesystem_entry *dir)
+ 				break;
+ 			case S_IFLNK:
+ 				if (verbose) {
+-					printf("\tl %04o %9" PRIdoff_t "             %5d:%-3d %s -> %s\n",
+-							e->sb.st_mode & ~S_IFMT, e->sb.st_size,
++					printf("\tl %04o %9lld             %5d:%-3d %s -> %s\n",
++							e->sb.st_mode & ~S_IFMT, (long long)e->sb.st_size,
+ 							(int) e->sb.st_uid, (int) e->sb.st_gid, e->name,
+ 							e->link);
+ 				}
+@@ -1297,8 +1297,8 @@ static void recursive_populate_directory(struct filesystem_entry *dir)
+ 				wrote = write_regular_file(e);
+ 				write_xattr_entry(e);
+ 				if (verbose) {
+-					printf("\tf %04o %9" PRIdoff_t " (%9u) %5d:%-3d %s\n",
+-							e->sb.st_mode & ~S_IFMT, e->sb.st_size, wrote,
++					printf("\tf %04o %9lld (%9u) %5d:%-3d %s\n",
++							e->sb.st_mode & ~S_IFMT, (long long)e->sb.st_size, wrote,
+ 							(int) e->sb.st_uid, (int) e->sb.st_gid, e->name);
+ 				}
+ 				break;
+diff --git a/lib/libmtd.c b/lib/libmtd.c
+index 86c89ae..f375381 100644
+--- a/lib/libmtd.c
++++ b/lib/libmtd.c
+@@ -1079,8 +1079,8 @@ int mtd_read(const struct mtd_dev_info *mtd, int fd, int eb, int offs,
+ 	/* Seek to the beginning of the eraseblock */
+ 	seek = (off_t)eb * mtd->eb_size + offs;
+ 	if (lseek(fd, seek, SEEK_SET) != seek)
+-		return sys_errmsg("cannot seek mtd%d to offset %"PRIdoff_t,
+-				  mtd->mtd_num, seek);
++		return sys_errmsg("cannot seek mtd%d to offset %lld",
++				  mtd->mtd_num, (long long)seek);
+ 
+ 	while (rd < len) {
+ 		ret = read(fd, buf + rd, len - rd);
+@@ -1188,8 +1188,8 @@ int mtd_write(libmtd_t desc, const struct mtd_dev_info *mtd, int fd, int eb,
+ 	if (data) {
+ 		/* Seek to the beginning of the eraseblock */
+ 		if (lseek(fd, seek, SEEK_SET) != seek)
+-			return sys_errmsg("cannot seek mtd%d to offset %"PRIdoff_t,
+-					mtd->mtd_num, seek);
++			return sys_errmsg("cannot seek mtd%d to offset %lld",
++					mtd->mtd_num, (long long)seek);
+ 		ret = write(fd, data, len);
+ 		if (ret != len)
+ 			return sys_errmsg("cannot write %d bytes to mtd%d "
+diff --git a/misc-utils/flash_erase.c b/misc-utils/flash_erase.c
+index 0c9449f..ec4b2e1 100644
+--- a/misc-utils/flash_erase.c
++++ b/misc-utils/flash_erase.c
+@@ -53,8 +53,8 @@ int target_endian = __BYTE_ORDER;
+ static void show_progress(struct mtd_dev_info *mtd, off_t start, int eb,
+ 			  int eb_start, int eb_cnt)
+ {
+-	bareverbose(!quiet, "\rErasing %d Kibyte @ %"PRIxoff_t" -- %2i %% complete ",
+-		mtd->eb_size / 1024, start, ((eb - eb_start) * 100) / eb_cnt);
++	bareverbose(!quiet, "\rErasing %d Kibyte @ %llx -- %2i %% complete ",
++		mtd->eb_size / 1024, (unsigned long long)start, ((eb - eb_start) * 100) / eb_cnt);
+ 	fflush(stdout);
+ }
+ 
+@@ -210,7 +210,7 @@ int main(int argc, char *argv[])
+ 		if (!noskipbad) {
+ 			int ret = mtd_is_bad(&mtd, fd, eb);
+ 			if (ret > 0) {
+-				verbose(!quiet, "Skipping bad block at %08"PRIxoff_t, offset);
++				verbose(!quiet, "Skipping bad block at %08llx", (unsigned long long)offset);
+ 				continue;
+ 			} else if (ret < 0) {
+ 				if (errno == EOPNOTSUPP) {
+diff --git a/misc-utils/flash_otp_write.c b/misc-utils/flash_otp_write.c
+index b02d0b0..04c96c6 100644
+--- a/misc-utils/flash_otp_write.c
++++ b/misc-utils/flash_otp_write.c
+@@ -76,7 +76,7 @@ int main(int argc,char *argv[])
+ 		return errno;
+ 	}
+ 
+-	printf("Writing OTP user data on %s at offset 0x%"PRIxoff_t"\n", argv[2], offset);
++	printf("Writing OTP user data on %s at offset 0x%llx\n", argv[2], (unsigned long long)offset);
+ 
+ 	if (mtd_type_is_nand_user(&mtdInfo))
+ 		len = mtdInfo.writesize;
+diff --git a/misc-utils/ftl_check.c b/misc-utils/ftl_check.c
+index a853cf4..e854922 100644
+--- a/misc-utils/ftl_check.c
++++ b/misc-utils/ftl_check.c
+@@ -131,7 +131,7 @@ static void check_partition(int fd)
+ 			perror("read failed");
+ 			break;
+ 		}
+-		printf("\nErase unit %"PRIdoff_t":\n", i);
++		printf("\nErase unit %lld:\n", (long long)i);
+ 		if ((hdr2.FormattedSize != hdr.FormattedSize) ||
+ 				(hdr2.NumEraseUnits != hdr.NumEraseUnits) ||
+ 				(hdr2.SerialNumber != hdr.SerialNumber))
+diff --git a/misc-utils/mtd_debug.c b/misc-utils/mtd_debug.c
+index ac37e23..d65ad36 100644
+--- a/misc-utils/mtd_debug.c
++++ b/misc-utils/mtd_debug.c
+@@ -160,7 +160,7 @@ retry:
+ 	if (buf != NULL)
+ 		free(buf);
+ 	close(outfd);
+-	printf("Copied %zu bytes from address 0x%.8"PRIxoff_t" in flash to %s\n", len, offset, filename);
++	printf("Copied %zu bytes from address 0x%.8llx in flash to %s\n", len, (unsigned long long)offset, filename);
+ 	return 0;
+ 
+ err2:
+@@ -225,7 +225,7 @@ retry:
+ 	if (buf != NULL)
+ 		free(buf);
+ 	fclose(fp);
+-	printf("Copied %d bytes from %s to address 0x%.8"PRIxoff_t" in flash\n", len, filename, offset);
++	printf("Copied %d bytes from %s to address 0x%.8llx in flash\n", len, filename, (unsigned long long)offset);
+ 	return 0;
+ }
+ 
+diff --git a/misc-utils/serve_image.c b/misc-utils/serve_image.c
+index f2475d6..6c8c8fb 100644
+--- a/misc-utils/serve_image.c
++++ b/misc-utils/serve_image.c
+@@ -129,8 +129,8 @@ int main(int argc, char **argv)
+ 	}
+ 
+ 	if (st.st_size % erasesize) {
+-		fprintf(stderr, "Image size %" PRIdoff_t " bytes is not a multiple of erasesize %d bytes\n",
+-				st.st_size, erasesize);
++		fprintf(stderr, "Image size %lld bytes is not a multiple of erasesize %d bytes\n",
++				(long long)st.st_size, erasesize);
+ 		exit(1);
+ 	}
+ 	image = mmap(NULL, st.st_size, PROT_READ, MAP_PRIVATE, rfd, 0);
+diff --git a/tests/fs-tests/integrity/integck.c b/tests/fs-tests/integrity/integck.c
+index 84753d6..0a7f142 100644
+--- a/tests/fs-tests/integrity/integck.c
++++ b/tests/fs-tests/integrity/integck.c
+@@ -897,8 +897,8 @@ static ssize_t file_write_data(struct file_info *file, int fd, off_t offset,
+ 	remains = size;
+ 	actual = 0;
+ 	written = IO_BUFFER_SIZE;
+-	v("write %zd bytes, offset %"PRIdoff_t", file %s",
+-	  size, offset, get_file_name(file));
++	v("write %zd bytes, offset %lld, file %s",
++	  size, (long long)offset, get_file_name(file));
+ 	while (remains) {
+ 		/* Fill up buffer with random data */
+ 		if (written < IO_BUFFER_SIZE) {
+diff --git a/tests/mtd-tests/nandpagetest.c b/tests/mtd-tests/nandpagetest.c
+index c6812df..465e548 100644
+--- a/tests/mtd-tests/nandpagetest.c
++++ b/tests/mtd-tests/nandpagetest.c
+@@ -232,8 +232,8 @@ static int verify_eraseblock(int ebnum)
+ 			return err;
+ 
+ 		if (lseek(fd, addr, SEEK_SET) != addr) {
+-			fprintf(stderr, "cannot seek mtd%d to offset %"PRIdloff_t,
+-	 				mtd.mtd_num, addr);
++			fprintf(stderr, "cannot seek mtd%d to offset %lld",
++	 				mtd.mtd_num, (long long)addr);
+ 			return -1;
+ 		}
+ 
+diff --git a/tests/ubi-tests/integ.c b/tests/ubi-tests/integ.c
+index 26c2ce5..1cd0649 100644
+--- a/tests/ubi-tests/integ.c
++++ b/tests/ubi-tests/integ.c
+@@ -243,7 +243,7 @@ static void check_erase_block(struct erase_block_info *erase_block, int fd)
+ 			while (size)
+ 				if (read_buffer[--size] != 0xff) {
+ 					fprintf(stderr, "block no. = %d\n" , erase_block->block_number);
+-					fprintf(stderr, "offset = %"PRIdoff_t"\n" , gap_start);
++					fprintf(stderr, "offset = %lld\n" , (long long)gap_start);
+ 					fprintf(stderr, "size = %ld\n" , (long) bytes_read);
+ 					error_exit("verify 0xff failed");
+ 				}
+@@ -254,7 +254,7 @@ static void check_erase_block(struct erase_block_info *erase_block, int fd)
+ 		errno = 0;
+ 		bytes_read = read(fd, read_buffer, w->size);
+ 		if (bytes_read != w->size) {
+-			fprintf(stderr, "offset = %"PRIdoff_t"\n" , w->offset);
++			fprintf(stderr, "offset = %lld\n" , (long long)w->offset);
+ 			fprintf(stderr, "size = %ld\n" , (long) w->size);
+ 			fprintf(stderr, "bytes_read = %ld\n" , (long) bytes_read);
+ 			error_exit("read failed");
+@@ -279,7 +279,7 @@ static void check_erase_block(struct erase_block_info *erase_block, int fd)
+ 		while (size)
+ 			if (read_buffer[--size] != 0xff) {
+ 				fprintf(stderr, "block no. = %d\n" , erase_block->block_number);
+-				fprintf(stderr, "offset = %"PRIdoff_t"\n" , gap_start);
++				fprintf(stderr, "offset = %lld\n" , (long long)gap_start);
+ 				fprintf(stderr, "size = %ld\n" , (long) bytes_read);
+ 				error_exit("verify 0xff failed!");
+ 			}
+diff --git a/ubifs-utils/mkfs.ubifs/mkfs.ubifs.c b/ubifs-utils/mkfs.ubifs/mkfs.ubifs.c
+index c916f48..f0237ab 100644
+--- a/ubifs-utils/mkfs.ubifs/mkfs.ubifs.c
++++ b/ubifs-utils/mkfs.ubifs/mkfs.ubifs.c
+@@ -772,11 +772,11 @@ int write_leb(int lnum, int len, void *buf)
+ 			return sys_err_msg("ubi_leb_change_start failed");
+ 
+ 	if (lseek(out_fd, pos, SEEK_SET) != pos)
+-		return sys_err_msg("lseek failed seeking %"PRIdoff_t, pos);
++		return sys_err_msg("lseek failed seeking %lld", (long long)pos);
+ 
+ 	if (write(out_fd, buf, c->leb_size) != c->leb_size)
+-		return sys_err_msg("write failed writing %d bytes at pos %"PRIdoff_t,
+-				   c->leb_size, pos);
++		return sys_err_msg("write failed writing %d bytes at pos %lld",
++				   c->leb_size, (long long)pos);
+ 
+ 	return 0;
+ }
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-2.0.2/0003-Makefile.am-only-build-ubi-utils.patch b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-2.0.2/0003-Makefile.am-only-build-ubi-utils.patch
new file mode 100644
index 0000000..38ab7a9
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-2.0.2/0003-Makefile.am-only-build-ubi-utils.patch
@@ -0,0 +1,34 @@
+From 139d93bc405272a3261d57be26da842e737fe4d0 Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Sun, 28 Jan 2018 23:10:34 +0100
+Subject: [PATCH] Makefile.am: only build ubi-utils
+
+We only target the ubi-utils, static, small.
+
+Upstream-Status: Inappropriate [embedded specific]
+
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+---
+ Makefile.am | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/Makefile.am b/Makefile.am
+index 5a6e77c..98715dd 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -34,9 +34,9 @@ EXTRA_DIST += $(GLOBAL_HEADER) $(GLOBAL_EXTRA)
+ 
+ include lib/Makemodule.am
+ include ubi-utils/Makemodule.am
+-include misc-utils/Makemodule.am
+-include nand-utils/Makemodule.am
+-include nor-utils/Makemodule.am
++#include misc-utils/Makemodule.am
++#include nand-utils/Makemodule.am
++#include nor-utils/Makemodule.am
+ 
+ if BUILD_UBIFS
+ include ubifs-utils/Makemodule.am
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-2.0.2/0004-mtd-utils-common.h-no-features.h-for-klibc-builds.patch b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-2.0.2/0004-mtd-utils-common.h-no-features.h-for-klibc-builds.patch
new file mode 100644
index 0000000..2844a50
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-2.0.2/0004-mtd-utils-common.h-no-features.h-for-klibc-builds.patch
@@ -0,0 +1,38 @@
+From ae1cf6d0eb1833e46549328a4473222c259723d7 Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Thu, 1 Feb 2018 00:25:00 +0100
+Subject: [PATCH] mtd-utils: common.h: no features.h for klibc builds
+
+Add guard around features.h to fix missing include (here first error):
+
+ ../git/include/common.h:29:10:
+ fatal error: features.h: No such file or directory
+  #include <features.h>
+           ^~~~~~~~~~~~
+ compilation terminated
+
+Upstream-Status: Submitted
+
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+---
+ include/common.h | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/include/common.h b/include/common.h
+index 642c212..f7c71fe 100644
+--- a/include/common.h
++++ b/include/common.h
+@@ -26,7 +26,10 @@
+ #include <string.h>
+ #include <fcntl.h>
+ #include <errno.h>
++#if defined(__KLIBC__)
++#else
+ #include <features.h>
++#endif
+ #include <inttypes.h>
+ #include <unistd.h>
+ #include <sys/sysmacros.h>
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-2.0.2/0005-common.h-replace-getline-with-fgets.patch b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-2.0.2/0005-common.h-replace-getline-with-fgets.patch
new file mode 100644
index 0000000..a556ed3
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc-2.0.2/0005-common.h-replace-getline-with-fgets.patch
@@ -0,0 +1,56 @@
+From 2137eb1a6cd0326510bd3b9faf8037d9bf34ca3d Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Wed, 23 May 2018 15:52:34 +0200
+Subject: [PATCH] common.h: replace getline() with fgets
+
+There is an unofficial upstream patch adding a simple getline()
+to libmissing.h. Unfortunately the patch creates issues if the
+toolchain is using glibc (autotools cache?) so for the moment
+keep the old hack and wait for commits upstream.
+
+Fix:
+
+| ubi-utils/ubiformat.o: In function `prompt.constprop.4':
+| ubiformat.c:(.text+0x70): undefined reference to `getline'
+
+Upstream-Status: Inappropriate [klibc specific]
+
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+---
+ include/common.h | 11 +++++++++++
+ 1 file changed, 11 insertions(+)
+
+diff --git a/include/common.h b/include/common.h
+index a1d59d0..96b0bdb 100644
+--- a/include/common.h
++++ b/include/common.h
+@@ -126,15 +126,26 @@ extern "C" {
+  */
+ static inline bool prompt(const char *msg, bool def)
+ {
++
++#ifndef __KLIBC__
+ 	char *line = NULL;
+ 	size_t len;
++#else
++	char *line;
++	const int sizeof_line = 2;
++	line = malloc(sizeof_line);
++#endif
+ 	bool ret = def;
+ 
+ 	do {
+ 		normsg_cont("%s (%c/%c) ", msg, def ? 'Y' : 'y', def ? 'n' : 'N');
+ 		fflush(stdout);
+ 
++#ifndef __KLIBC__
+ 		while (getline(&line, &len, stdin) == -1) {
++#else
++		while (fgets(line, sizeof_line, stdin) == NULL) {
++#endif
+ 			printf("failed to read prompt; assuming '%s'\n",
+ 				def ? "yes" : "no");
+ 			break;
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc_1.5.2.bb b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc_1.5.2.bb
deleted file mode 100644
index abb0d4b..0000000
--- a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc_1.5.2.bb
+++ /dev/null
@@ -1,51 +0,0 @@
-SUMMARY = "UBI utils statically compiled against klibc"
-DESCRIPTION = "Small sized tools from mtd-utils for use with initramfs."
-SECTION = "base"
-DEPENDS = "zlib lzo e2fsprogs util-linux"
-HOMEPAGE = "http://www.linux-mtd.infradead.org/"
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3 \
-                    file://include/common.h;beginline=1;endline=17;md5=ba05b07912a44ea2bf81ce409380049c"
-
-inherit klibc
-
-SRCREV = "aea36417067dade75192bafa03af70b6eb2677b1"
-SRC_URI = "git://git.infradead.org/mtd-utils.git \
-             file://0001-Makefile-build-ubi-utils-only.patch \
-             file://0002-common.mk-for-klibc-CC-is-klcc.patch \
-             file://0003-libubi.c-add-klibc-specific-fixes-for-ioctl.patch \
-             file://0004-Restore-compatibility-to-dietlibc-klibc-musl-libc-af.patch \
-             file://0005-common.h-more-workarounds-for-klibc-compatibility.patch \
-             file://0006-libiniparser-remove-unused-function-needing-float.patch \
-             file://0007-mtd-utils-common.c-convert-to-integer-arithmetic.patch \
-             file://0008-ubi-utils-ubiformat.c-convert-to-integer-arithmetic.patch \
-             file://0009-Eliminate-warnings-about-implicit-non-const-casting-.patch \
-             "
-
-S = "${WORKDIR}/git/"
-
-EXTRA_OEMAKE = "'CC=${CC}' 'RANLIB=${RANLIB}' 'AR=${AR}' 'CFLAGS=${CFLAGS} -I${S}include -DWITHOUT_XATTR' 'BUILDDIR=${S}'"
-
-do_install () {
-	oe_runmake install DESTDIR=${D} SBINDIR=${sbindir} MANDIR=${mandir} INCLUDEDIR=${includedir}
-}
-
-PACKAGES = "ubi-utils-klibc-dbg"
-
-PACKAGES =+ "mtdinfo-klibc ubiattach-klibc ubiblock-klibc ubicrc32-klibc ubidetach-klibc \
-             ubiformat-klibc ubimkvol-klibc ubinfo-klibc ubinize-klibc ubirename-klibc \
-             ubirmvol-klibc ubirsvol-klibc ubiupdatevol-klibc"
-
-FILES_mtdinfo-klibc = "${sbindir}/mtdinfo"
-FILES_ubiattach-klibc = "${sbindir}/ubiattach"
-FILES_ubiblock-klibc = "${sbindir}/ubiblock"
-FILES_ubicrc32-klibc = "${sbindir}/ubicrc32"
-FILES_ubidetach-klibc = "${sbindir}/ubidetach"
-FILES_ubiformat-klibc = "${sbindir}/ubiformat"
-FILES_ubimkvol-klibc = "${sbindir}/ubimkvol"
-FILES_ubinfo-klibc = "${sbindir}/ubinfo"
-FILES_ubinize-klibc = "${sbindir}/ubinize"
-FILES_ubirename-klibc = "${sbindir}/ubirename"
-FILES_ubirmvol-klibc = "${sbindir}/ubirmvol"
-FILES_ubirsvol-klibc = "${sbindir}/ubirsvol"
-FILES_ubiupdatevol-klibc = "${sbindir}/ubiupdatevol"
diff --git a/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc_2.0.2.bb b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc_2.0.2.bb
new file mode 100644
index 0000000..0475cbe
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc_2.0.2.bb
@@ -0,0 +1,52 @@
+SUMMARY = "UBI utils statically compiled against klibc"
+DESCRIPTION = "Small sized tools from mtd-utils for use with initramfs."
+SECTION = "base"
+DEPENDS = "zlib lzo e2fsprogs util-linux"
+HOMEPAGE = "http://www.linux-mtd.infradead.org/"
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3 \
+                    file://include/common.h;beginline=1;endline=17;md5=ba05b07912a44ea2bf81ce409380049c"
+
+inherit autotools pkgconfig klibc
+
+SRCREV = "64f61a9dc71b158c7084006cbce4ea23886f0b47"
+SRC_URI = "git://git.infradead.org/mtd-utils.git \
+             file://0001-libmissing.h-fix-klibc-build-when-using-glibc-toolch.patch \
+             file://0002-Instead-of-doing-preprocessor-magic-just-output-off_.patch \
+             file://0003-Makefile.am-only-build-ubi-utils.patch \
+             file://0004-mtd-utils-common.h-no-features.h-for-klibc-builds.patch \
+             file://0005-common.h-replace-getline-with-fgets.patch \
+             "
+
+S = "${WORKDIR}/git/"
+
+EXTRA_OECONF += "--disable-tests --without-jffs --without-ubifs"
+
+PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'xattr', d)}"
+PACKAGECONFIG[xattr] = ",,acl,"
+
+EXTRA_OEMAKE = "'CC=${CC}' 'RANLIB=${RANLIB}' 'AR=${AR}' 'CFLAGS=${CFLAGS} ${@bb.utils.contains('PACKAGECONFIG', 'xattr', '', '-DWITHOUT_XATTR', d)} -I${S}/include' 'BUILDDIR=${S}'"
+
+do_install () {
+	oe_runmake install DESTDIR=${D} SBINDIR=${sbindir} MANDIR=${mandir} INCLUDEDIR=${includedir}
+}
+
+PACKAGES = "ubi-utils-klibc-dbg ubi-utils-klibc-doc"
+
+PACKAGES =+ "mtdinfo-klibc ubiattach-klibc ubiblock-klibc ubicrc32-klibc ubidetach-klibc \
+             ubiformat-klibc ubimkvol-klibc ubinfo-klibc ubinize-klibc ubirename-klibc \
+             ubirmvol-klibc ubirsvol-klibc ubiupdatevol-klibc"
+
+FILES_mtdinfo-klibc = "${sbindir}/mtdinfo"
+FILES_ubiattach-klibc = "${sbindir}/ubiattach"
+FILES_ubiblock-klibc = "${sbindir}/ubiblock"
+FILES_ubicrc32-klibc = "${sbindir}/ubicrc32"
+FILES_ubidetach-klibc = "${sbindir}/ubidetach"
+FILES_ubiformat-klibc = "${sbindir}/ubiformat"
+FILES_ubimkvol-klibc = "${sbindir}/ubimkvol"
+FILES_ubinfo-klibc = "${sbindir}/ubinfo"
+FILES_ubinize-klibc = "${sbindir}/ubinize"
+FILES_ubirename-klibc = "${sbindir}/ubirename"
+FILES_ubirmvol-klibc = "${sbindir}/ubirmvol"
+FILES_ubirsvol-klibc = "${sbindir}/ubirsvol"
+FILES_ubiupdatevol-klibc = "${sbindir}/ubiupdatevol"
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/0001-Adjust-the-order-of-headers-to-fix-build-for-musl.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/0001-Adjust-the-order-of-headers-to-fix-build-for-musl.patch
deleted file mode 100644
index a7600b3..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/0001-Adjust-the-order-of-headers-to-fix-build-for-musl.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 86b962e7c0de43b20b6210d059e4855ce87078bc Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 13 Jul 2017 16:20:08 -0700
-Subject: [PATCH] Adjust the order of headers to fix build for musl
-
-Fixes
-kexec/ifdown.c:33:16: error: storage size of 'ifc' isn't known
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- kexec/ifdown.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/kexec/ifdown.c b/kexec/ifdown.c
-index 2215798..e13f777 100644
---- a/kexec/ifdown.c
-+++ b/kexec/ifdown.c
-@@ -16,8 +16,8 @@ char *v_ifdown = "@(#)ifdown.c  1.11  02-Jun-1998  miquels@cistron.nl";
- #include <sys/time.h>
- #include <errno.h>
- 
--#include <net/if.h>
- #include <netinet/in.h>
-+#include <net/if.h>
- 
- #define MAX_IFS	64
- 
--- 
-2.13.2
-
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/arm_crashdump.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/arm_crashdump.patch
deleted file mode 100644
index 0ff61e5..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/arm_crashdump.patch
+++ /dev/null
@@ -1,12 +0,0 @@
---- a/kexec/arch/arm/crashdump-arm.c
-+++ b/kexec/arch/arm/crashdump-arm.c
-@@ -20,7 +20,7 @@
-  * along with this program; if not, write to the Free Software
-  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-  */
--#include <elf.h>
-+#include "../../../include/elf.h"
- #include <errno.h>
- #include <stdio.h>
- #include <stdlib.h>
-
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/cflags_static.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/cflags_static.patch
deleted file mode 100644
index 35100a3..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/cflags_static.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -46,7 +46,7 @@
- # where necessary.
- CPPFLAGS	= @CPPFLAGS@ -I$(srcdir)/include -I$(srcdir)/util_lib/include \
-			-Iinclude/
--CFLAGS		= @CFLAGS@ -fno-strict-aliasing -Wall -Wstrict-prototypes
-+CFLAGS		= @CFLAGS@ -static -fno-strict-aliasing -Wall -Wstrict-prototypes
- PURGATORY_EXTRA_CFLAGS = @PURGATORY_EXTRA_CFLAGS@
- ASFLAGS		= @ASFLAGS@
- LDFLAGS		= @LDFLAGS@
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/fix-out-of-tree-build.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/fix-out-of-tree-build.patch
deleted file mode 100644
index ccbb24d..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/fix-out-of-tree-build.patch
+++ /dev/null
@@ -1,54 +0,0 @@
-From 37737527725e465833be649101c4a6f8352c5d5e Mon Sep 17 00:00:00 2001
-From: Tyler Hall <tylerwhall@gmail.com>
-Date: Tue, 7 Feb 2012 18:50:05 -0500
-Subject: Fix out-of-tree build
-
-Use automatic variables for prerequisites when copying man pages and
-include a makefile relative to $(srcdir).
-
-Backported to 2.0.2-klibc
-
-Signed-off-by: Tyler Hall <tylerwhall@gmail.com>
-Signed-off-by: Simon Horman <horms@verge.net.au>
-
-diff --git a/kdump/Makefile b/kdump/Makefile
-index 1e2b72c..5dfa928 100644
---- a/kdump/Makefile
-+++ b/kdump/Makefile
-@@ -22,7 +22,7 @@ $(KDUMP): $(KDUMP_OBJS)
- 
- $(KDUMP_MANPAGE): kdump/kdump.8
- 	$(MKDIR) -p     $(MANDIR)/man8
--	cp kdump/kdump.8 $(KDUMP_MANPAGE)
-+	cp $^ $(KDUMP_MANPAGE)
- echo::
- 	@echo "KDUMP_SRCS $(KDUMP_SRCS)"
- 	@echo "KDUMP_DEPS $(KDUMP_DEPS)"
-diff --git a/kexec/Makefile b/kexec/Makefile
-index 2137cab..8c815b5 100644
---- a/kexec/Makefile
-+++ b/kexec/Makefile
-@@ -82,7 +82,7 @@ $(KEXEC): CPPFLAGS+=-I$(srcdir)/kexec/arch/$(ARCH)/include
- 
- $(KEXEC_MANPAGE): kexec/kexec.8
- 	@$(MKDIR) -p     $(MANDIR)/man8
--	cp kexec/kexec.8 $(KEXEC_MANPAGE)
-+	cp $^ $(KEXEC_MANPAGE)
- echo::
- 	@echo "KEXEC_SRCS $(KEXEC_SRCS)"
- 	@echo "KEXEC_DEPS $(KEXEC_DEPS)"
-diff --git a/kexec/arch/ppc/Makefile b/kexec/arch/ppc/Makefile
-index 3dba7cf..41242a5 100644
---- a/kexec/arch/ppc/Makefile
-+++ b/kexec/arch/ppc/Makefile
-@@ -1,7 +1,7 @@
- #
- # kexec ppc (linux booting linux)
- #
--include kexec/arch/ppc/libfdt/Makefile.libfdt
-+include $(srcdir)/kexec/arch/ppc/libfdt/Makefile.libfdt
- 
- ppc_KEXEC_SRCS =  kexec/arch/ppc/kexec-ppc.c
- ppc_KEXEC_SRCS += kexec/arch/ppc/kexec-elf-ppc.c
-
-
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/ifdown_errno.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/ifdown_errno.patch
deleted file mode 100644
index 7f8cddd..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/ifdown_errno.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/kexec/ifdown.c
-+++ b/kexec/ifdown.c
-@@ -14,7 +14,7 @@
- #include <sys/ioctl.h>
- #include <sys/socket.h>
- #include <sys/time.h>
--#include <sys/errno.h>
-+#include <errno.h>
- 
- #include <net/if.h>
- #include <netinet/in.h>
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/kexec-elf-rel.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/kexec-elf-rel.patch
deleted file mode 100644
index c666afc..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/kexec-elf-rel.patch
+++ /dev/null
@@ -1,61 +0,0 @@
---- a/kexec/kexec-elf-rel.c
-+++ b/kexec/kexec-elf-rel.c
-@@ -4,7 +4,7 @@
- #include <stdio.h>
- #include <errno.h>
- #include <stdlib.h>
--#include "elf.h"
-+#include "../include/elf.h"
- #include <boot/elf_boot.h>
- #include "kexec.h"
- #include "kexec-elf.h"
-
---- a/kexec/arch/arm/kexec-elf-rel-arm.c
-+++ b/kexec/arch/arm/kexec-elf-rel-arm.c
-@@ -1,5 +1,5 @@
- #include <stdio.h>
--#include <elf.h>
-+#include "../../../include/elf.h"
- #include "../../kexec.h"
- #include "../../kexec-elf.h"
- 
-
---- a/kexec/arch/i386/kexec-elf-rel-x86.c
-+++ b/kexec/arch/i386/kexec-elf-rel-x86.c
-@@ -1,5 +1,5 @@
- #include <stdio.h>
--#include <elf.h>
-+#include "../../../include/elf.h"
- #include "../../kexec.h"
- #include "../../kexec-elf.h"
- 
-
---- a/kexec/arch/ppc/kexec-elf-rel-ppc.c
-+++ b/kexec/arch/ppc/kexec-elf-rel-ppc.c
-@@ -1,5 +1,5 @@
- #include <stdio.h>
--#include <elf.h>
-+#include "../../../include/elf.h"
- #include "../../kexec.h"
- #include "../../kexec-elf.h"
- 
-
---- a/kexec/arch/ppc64/kexec-elf-rel-ppc64.c
-+++ b/kexec/arch/ppc64/kexec-elf-rel-ppc64.c
-@@ -1,5 +1,5 @@
- #include <stdio.h>
--#include <elf.h>
-+#include "../../../include/elf.h"
- #include <string.h>
- #include "../../kexec.h"
- #include "../../kexec-elf.h"
-
---- a/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
-+++ b/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
-@@ -1,5 +1,5 @@
- #include <stdio.h>
--#include <elf.h>
-+#include "../../../include/elf.h"
- #include "../../kexec.h"
- #include "../../kexec-elf.h"
- 
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/kexec-syscall.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/kexec-syscall.patch
deleted file mode 100644
index 081de1b..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/kexec-syscall.patch
+++ /dev/null
@@ -1,44 +0,0 @@
---- a/kexec/kexec-syscall.h
-+++ b/kexec/kexec-syscall.h
-@@ -2,7 +2,7 @@
- #define KEXEC_SYSCALL_H
- 
- #define __LIBRARY__
--#include <syscall.h>
-+/*#include <syscall.h>*/
- #include <sys/syscall.h>
- #include <unistd.h>
- 
-@@ -23,6 +23,7 @@
- #define LINUX_REBOOT_CMD_KEXEC		0x45584543
- 
- #ifndef __NR_kexec_load
-+/*
- #ifdef __i386__
- #define __NR_kexec_load		283
- #endif
-@@ -61,19 +62,21 @@
- #ifndef __NR_kexec_load
- #error Unknown processor architecture.  Needs a kexec_load syscall number.
- #endif
-+*/
- #endif /*ifndef __NR_kexec_load*/
- 
- struct kexec_segment;
--
-+/*
- static inline long kexec_load(void *entry, unsigned long nr_segments,
- 			struct kexec_segment *segments, unsigned long flags)
- {
- 	return (long) syscall(__NR_kexec_load, entry, nr_segments, segments, flags);
- }
--
-+*/
- static inline long kexec_reboot(void)
- {
--	return (long) syscall(__NR_reboot, LINUX_REBOOT_MAGIC1, LINUX_REBOOT_MAGIC2, LINUX_REBOOT_CMD_KEXEC, 0);
-+	//return (long) syscall(__NR_reboot, LINUX_REBOOT_MAGIC1, LINUX_REBOOT_MAGIC2, LINUX_REBOOT_CMD_KEXEC, 0);
-+	return __reboot(LINUX_REBOOT_MAGIC1, LINUX_REBOOT_MAGIC2, LINUX_REBOOT_CMD_KEXEC, 0);
- }
- 
- 
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/ppc__lshrdi3.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/ppc__lshrdi3.patch
deleted file mode 100644
index 56cdfb0..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/ppc__lshrdi3.patch
+++ /dev/null
@@ -1,18 +0,0 @@
---- a/purgatory/arch/ppc/crt.S
-+++ b/purgatory/arch/ppc/crt.S
-@@ -249,6 +249,7 @@
-  *
-  */
- 
-+/* already defined in misc.S
- _GLOBAL(__lshrdi3)
- 	subfic	6,5,32
- 	srw	4,4,5	# LSW = count > 31 ? 0 : LSW >> count
-@@ -259,5 +260,7 @@
- 	srw	3,3,5	# MSW = MSW >> count
- 	or	4,4,7	# LSW |= t2
- 	blr
-+*/
-+
- #endif
- #endif
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/purgatory_flags.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/purgatory_flags.patch
deleted file mode 100644
index 41fc116..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/purgatory_flags.patch
+++ /dev/null
@@ -1,21 +0,0 @@
---- a/purgatory/Makefile
-+++ b/purgatory/Makefile
-@@ -47,7 +47,7 @@
- $(PURGATORY): CC=$(TARGET_CC)
- $(PURGATORY): CFLAGS+=$(PURGATORY_EXTRA_CFLAGS) \
-		      $($(ARCH)_PURGATORY_EXTRA_CFLAGS) \
--		      -Os -fno-builtin -ffreestanding
-+		      -Os -fno-builtin -ffreestanding -nostdinc
- 
- $(PURGATORY): CPPFLAGS=$($(ARCH)_PURGATORY_EXTRA_CFLAGS) \
-			-I$(srcdir)/purgatory/include \
-@@ -61,7 +61,8 @@
- 
- $(PURGATORY): $(PURGATORY_OBJS)
-	$(MKDIR) -p $(@D)
--	$(CC) $(LDFLAGS) -o $@ $^
-+#	$(CC) $(LDFLAGS) -o $@ $^
-+	$(LD) $(LDFLAGS) -o $@ $^
- 
- #	$(LD) $(LDFLAGS) $(EXTRA_LDFLAGS) --no-undefined -e purgatory_start -r -o $@ $(PURGATORY_OBJS) $(UTIL_LIB)
-
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/purgatory_string.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/purgatory_string.patch
deleted file mode 100644
index 5710561..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/purgatory_string.patch
+++ /dev/null
@@ -1,9 +0,0 @@
---- a/purgatory/string.c
-+++ b/purgatory/string.c
-@@ -1,5 +1,5 @@
- #include <stddef.h>
--#include <string.h>
-+/* #include <string.h> */
- 
- size_t strnlen(const char *s, size_t max)
- {
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/sha256.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/sha256.patch
deleted file mode 100644
index 85bf7aa..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/sha256.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/util_lib/include/sha256.h
-+++ b/util_lib/include/sha256.h
-@@ -1,7 +1,8 @@
- #ifndef SHA256_H
- #define SHA256_H
- 
--#include <sys/types.h>
-+//#include <sys/types.h>
-+#include <stddef.h>
- #include <stdint.h>
- 
- typedef struct
-
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/sysconf_nrprocessors.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/sysconf_nrprocessors.patch
deleted file mode 100644
index 04a97e6..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/sysconf_nrprocessors.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/kexec/crashdump-elf.c
-+++ b/kexec/crashdump-elf.c
-@@ -47,7 +47,8 @@
-	if (xen_present())
-		nr_cpus = xen_get_nr_phys_cpus();
-	else
--		nr_cpus = sysconf(_SC_NPROCESSORS_CONF);
-+		/*nr_cpus = sysconf(_SC_NPROCESSORS_CONF);*/
-+		nr_cpus = 1;
- 
-	if (nr_cpus < 0) {
-		return -1;
-
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/x86_basename.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/x86_basename.patch
deleted file mode 100644
index 77a1c01..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/x86_basename.patch
+++ /dev/null
@@ -1,14 +0,0 @@
---- a/kexec/arch/i386/x86-linux-setup.c
-+++ b/kexec/arch/i386/x86-linux-setup.c
-@@ -280,9 +280,9 @@ static int add_edd_entry(struct x86_linu
-	memset(edd_info, 0, sizeof(struct edd_info));
- 
- 	/* extract the device number */
--	if (sscanf(basename(sysfs_name), "int13_dev%hhx", &devnum) != 1) {
-+	if (sscanf(strrchr(sysfs_name,'/') + 1, "int13_dev%hhx", &devnum) != 1) {
- 		fprintf(stderr, "Invalid format of int13_dev dir "
--				"entry: %s\n", basename(sysfs_name));
-+				"entry: %s\n", strrchr(sysfs_name,'/') + 1);
- 		return -1;
- 	}
- 
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/x86_kexec_test.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/x86_kexec_test.patch
deleted file mode 100644
index 9500bd6..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/x86_kexec_test.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -106,8 +106,8 @@
- 
- MAN_PAGES:= kexec/kexec.8
- MAN_PAGES+= kdump/kdump.8
--BINARIES_i386:=  $(SBINDIR)/kexec $(PKGLIBDIR)/kexec_test
--BINARIES_x86_64:=$(SBINDIR)/kexec $(PKGLIBDIR)/kexec_test
-+BINARIES_i386:=  $(SBINDIR)/kexec
-+BINARIES_x86_64:=$(SBINDIR)/kexec
- BINARIES:=$(SBINDIR)/kexec $(SBINDIR)/kdump $(BINARIES_$(ARCH))
- 
- TARGETS:=$(BINARIES) $(MAN_PAGES)
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/x86_sys_io.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/x86_sys_io.patch
deleted file mode 100644
index a497c9a..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/x86_sys_io.patch
+++ /dev/null
@@ -1,21 +0,0 @@
---- a/purgatory/arch/i386/pic.c
-+++ b/purgatory/arch/i386/pic.c
-@@ -16,7 +16,7 @@
-  * along with this program; if not, write to the Free Software
-  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-  */
--#include <sys/io.h>
-+#include "include/arch/io.h"
- #include <purgatory.h>
- #include "purgatory-x86.h"
- 
-
---- a/purgatory/arch/i386/vga.c
-+++ b/purgatory/arch/i386/vga.c
-@@ -1,4 +1,4 @@
--#include <sys/io.h>
-+#include "include/arch/io.h"
- #include <purgatory.h>
- #include "purgatory-x86.h"
- 
-
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/x86_vfscanf.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/x86_vfscanf.patch
deleted file mode 100644
index cad6951..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc-2.0.2/x86_vfscanf.patch
+++ /dev/null
@@ -1,27 +0,0 @@
---- a/kexec/arch/i386/x86-linux-setup.c
-+++ b/kexec/arch/i386/x86-linux-setup.c
-@@ -176,6 +176,8 @@ static int file_scanf(const char *dir, c
- 	FILE *fp;
- 	int retno;
- 	char filename[PATH_MAX];
-+	long line_size = MAX_LINE;
-+	char *line;
- 
- 	snprintf(filename, PATH_MAX, "%s/%s", dir, file);
- 	filename[PATH_MAX-1] = 0;
-@@ -186,7 +188,14 @@ static int file_scanf(const char *dir, c
- 	}
- 
- 	va_start(argptr, scanf_line);
--	retno = vfscanf(fp, scanf_line, argptr);
-+
-+	line = xmalloc(sizeof(line) * line_size);
-+	while(fgets(line, sizeof(line), fp) != NULL ) {
-+		line_size += MAX_LINE;
-+		line = xrealloc(line,line_size);
-+	}
-+	retno = vsscanf(line, scanf_line, argptr);
-+
- 	va_end(argptr);
- 
- 	fclose(fp);
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0001-force-static-build.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0001-force-static-build.patch
new file mode 100644
index 0000000..4744e7a
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0001-force-static-build.patch
@@ -0,0 +1,25 @@
+From d6af515cfcc8185f423860f80ff28719975b701f Mon Sep 17 00:00:00 2001
+From: OpenEmbedded <oe.patch@oe>
+Date: Wed, 11 Apr 2018 22:51:00 +0200
+Subject: [PATCH] force static build
+
+Upstream-Status: Inappropriate [embedded specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ Makefile.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index 54c206f..79188d8 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -47,7 +47,7 @@ TARGET_CFLAGS	= @TARGET_CFLAGS@
+ # where necessary.
+ CPPFLAGS	= @CPPFLAGS@ -I$(srcdir)/include -I$(srcdir)/util_lib/include \
+ 			-Iinclude/ $($(ARCH)_CPPFLAGS)
+-CFLAGS		= @CFLAGS@ -fno-strict-aliasing -Wall -Wstrict-prototypes
++CFLAGS		= @CFLAGS@ -static -fno-strict-aliasing -Wall -Wstrict-prototypes
+ PURGATORY_EXTRA_CFLAGS = @PURGATORY_EXTRA_CFLAGS@
+ ASFLAGS		= @ASFLAGS@ $($(ARCH)_ASFLAGS)
+ LDFLAGS		= @LDFLAGS@
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0002-Adjust-the-order-of-headers-to-fix-build-for-musl.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0002-Adjust-the-order-of-headers-to-fix-build-for-musl.patch
new file mode 100644
index 0000000..1d96a2b
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0002-Adjust-the-order-of-headers-to-fix-build-for-musl.patch
@@ -0,0 +1,29 @@
+From 0976d2d5be1ed44c2324b609c7d16c1e93181c4b Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 13 Jul 2017 16:20:08 -0700
+Subject: [PATCH] Adjust the order of headers to fix build for musl
+
+Fixes
+ kexec/ifdown.c:33:16: error: storage size of 'ifc' isn't known
+
+Upstream-Status: Inappropriate [embedded specific]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+---
+ kexec/ifdown.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/kexec/ifdown.c b/kexec/ifdown.c
+index 9679ad7..82c6141 100644
+--- a/kexec/ifdown.c
++++ b/kexec/ifdown.c
+@@ -16,8 +16,8 @@ char *v_ifdown = "@(#)ifdown.c  1.11  02-Jun-1998  miquels@cistron.nl";
+ #include <sys/socket.h>
+ #include <sys/time.h>
+ 
+-#include <net/if.h>
+ #include <netinet/in.h>
++#include <net/if.h>
+ 
+ /*
+  *  First, we find all shaper devices and down them. Then we
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0003-kexec-elf-rel-use-our-elf.h.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0003-kexec-elf-rel-use-our-elf.h.patch
new file mode 100644
index 0000000..ae9e7bb
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0003-kexec-elf-rel-use-our-elf.h.patch
@@ -0,0 +1,92 @@
+From 7f91875d65778154709e4fa0ccb23f3b2a98b0dc Mon Sep 17 00:00:00 2001
+From: OpenEmbedded <oe.patch@oe>
+Date: Wed, 11 Apr 2018 22:51:00 +0200
+Subject: [PATCH] kexec-elf-rel: use our elf.h
+
+Fix:
+
+ kexec-elf-rel.c: In function 'elf_rel_load':
+ kexec-elf-rel.c:386:39: error: 'STT_NOTYPE' undeclared
+
+and similar.
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ kexec/arch/arm/kexec-elf-rel-arm.c       | 2 +-
+ kexec/arch/i386/kexec-elf-rel-x86.c      | 2 +-
+ kexec/arch/ppc/kexec-elf-rel-ppc.c       | 2 +-
+ kexec/arch/ppc64/kexec-elf-rel-ppc64.c   | 2 +-
+ kexec/arch/x86_64/kexec-elf-rel-x86_64.c | 2 +-
+ kexec/kexec-elf-rel.c                    | 2 +-
+ 6 files changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/kexec/arch/arm/kexec-elf-rel-arm.c b/kexec/arch/arm/kexec-elf-rel-arm.c
+index a939cf4..2551dc0 100644
+--- a/kexec/arch/arm/kexec-elf-rel-arm.c
++++ b/kexec/arch/arm/kexec-elf-rel-arm.c
+@@ -1,5 +1,5 @@
+ #include <stdio.h>
+-#include <elf.h>
++#include "../../../include/elf.h"
+ #include "../../kexec.h"
+ #include "../../kexec-elf.h"
+ 
+diff --git a/kexec/arch/i386/kexec-elf-rel-x86.c b/kexec/arch/i386/kexec-elf-rel-x86.c
+index 55a214e..e7583d1 100644
+--- a/kexec/arch/i386/kexec-elf-rel-x86.c
++++ b/kexec/arch/i386/kexec-elf-rel-x86.c
+@@ -1,5 +1,5 @@
+ #include <stdio.h>
+-#include <elf.h>
++#include "../../../include/elf.h"
+ #include "../../kexec.h"
+ #include "../../kexec-elf.h"
+ 
+diff --git a/kexec/arch/ppc/kexec-elf-rel-ppc.c b/kexec/arch/ppc/kexec-elf-rel-ppc.c
+index 1acbd86..a60c66c 100644
+--- a/kexec/arch/ppc/kexec-elf-rel-ppc.c
++++ b/kexec/arch/ppc/kexec-elf-rel-ppc.c
+@@ -1,5 +1,5 @@
+ #include <stdio.h>
+-#include <elf.h>
++#include "../../../include/elf.h"
+ #include "../../kexec.h"
+ #include "../../kexec-elf.h"
+ 
+diff --git a/kexec/arch/ppc64/kexec-elf-rel-ppc64.c b/kexec/arch/ppc64/kexec-elf-rel-ppc64.c
+index 5f8e3f2..765bf6e 100644
+--- a/kexec/arch/ppc64/kexec-elf-rel-ppc64.c
++++ b/kexec/arch/ppc64/kexec-elf-rel-ppc64.c
+@@ -1,5 +1,5 @@
+ #include <stdio.h>
+-#include <elf.h>
++#include "../../../include/elf.h"
+ #include <string.h>
+ #include "../../kexec.h"
+ #include "../../kexec-elf.h"
+diff --git a/kexec/arch/x86_64/kexec-elf-rel-x86_64.c b/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
+index 7fdde73..cd5d729 100644
+--- a/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
++++ b/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
+@@ -1,5 +1,5 @@
+ #include <stdio.h>
+-#include <elf.h>
++#include "../../../include/elf.h"
+ #include "../../kexec.h"
+ #include "../../kexec-elf.h"
+ 
+diff --git a/kexec/kexec-elf-rel.c b/kexec/kexec-elf-rel.c
+index 9a6e63d..a856636 100644
+--- a/kexec/kexec-elf-rel.c
++++ b/kexec/kexec-elf-rel.c
+@@ -4,7 +4,7 @@
+ #include <stdio.h>
+ #include <errno.h>
+ #include <stdlib.h>
+-#include "elf.h"
++#include "../include/elf.h"
+ #include <boot/elf_boot.h>
+ #include "kexec.h"
+ #include "kexec-elf.h"
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0004-kexec-elf-exec.c-replace-with-our-err.h.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0004-kexec-elf-exec.c-replace-with-our-err.h.patch
new file mode 100644
index 0000000..1080e8b
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0004-kexec-elf-exec.c-replace-with-our-err.h.patch
@@ -0,0 +1,30 @@
+From 8b9da93ac9a4ea79ae953f80f6fe6e4f080341f2 Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Tue, 17 Apr 2018 10:57:23 +0200
+Subject: [PATCH] kexec-elf-exec.c: replace with our elf.h
+
+Fix
+
+ kexec-elf-exec.c: In function 'elf_exec_load':
+ error: 'EM_AARCH64' undeclared
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ kexec/kexec-elf-exec.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/kexec/kexec-elf-exec.c b/kexec/kexec-elf-exec.c
+index a9329ac..0dd0700 100644
+--- a/kexec/kexec-elf-exec.c
++++ b/kexec/kexec-elf-exec.c
+@@ -4,7 +4,7 @@
+ #include <stdio.h>
+ #include <errno.h>
+ #include <stdlib.h>
+-#include "elf.h"
++#include "../include/elf.h"
+ #include <boot/elf_boot.h>
+ #include "kexec.h"
+ #include "kexec-elf.h"
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0005-crashdump-elf.c-work-around-for-sysconf-_SC_NPROCESS.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0005-crashdump-elf.c-work-around-for-sysconf-_SC_NPROCESS.patch
new file mode 100644
index 0000000..4f7506d
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0005-crashdump-elf.c-work-around-for-sysconf-_SC_NPROCESS.patch
@@ -0,0 +1,134 @@
+From 1cfee75d9662c3382bb7cb8f1c952333837598ae Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Wed, 18 Apr 2018 02:21:30 +0200
+Subject: [PATCH] crashdump-elf.c: work around for _SC_NPROCESSORS_CONF
+
+klibc sysconf lacks this so the implementation
+of Linus Torvalds was taken (simplified):
+
+https://sourceware.org/ml/libc-alpha/2011-06/msg00079.html
+
+Have fun reding the thread!
+
+Fix
+
+ crashdump-elf.c:117:21: error: '_SC_NPROCESSORS_CONF' undeclared
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ kexec/crashdump-elf.c | 92 +++++++++++++++++++++++++++++++++++++++++++++++++++
+ 1 file changed, 92 insertions(+)
+
+diff --git a/kexec/crashdump-elf.c b/kexec/crashdump-elf.c
+index b8bb686..7e6767c 100644
+--- a/kexec/crashdump-elf.c
++++ b/kexec/crashdump-elf.c
+@@ -25,6 +25,94 @@ do {									\
+ } while(0)
+ #endif
+ 
++#ifdef __KLIBC__
++#ifndef KLIBC_SYSFS_CPU_H
++#define KLIBC_SYSFS_CPU_H
++
++
++static int __get_sysfs_cpus(const char *path);
++int __get_nprocs (void);
++int __get_nprocs_conf (void);
++
++
++
++static int __get_sysfs_cpus(const char *path)
++{
++	FILE *file;
++	int nr_cpus = 0;
++	int prev = -1;
++	char *p;
++	char line[10];
++
++
++	file = fopen(path, "r");
++	if (!file)
++		return -1;
++	for (;;) {
++		char sep;
++		int cpu;
++		int n;
++
++		/* int n = fscanf(file, "%u%c", &cpu, &sep); */
++		p = fgets(line, sizeof(line), file);
++		if (p == NULL)
++			return -1;
++		else
++			n = sscanf(line, "%u%c", &cpu, &sep);
++
++		if (n <= 0)
++			break;
++
++		/* EOF == EOLN */
++		if (n == 1)
++			sep = '\n';
++
++		/* Was the previous CPU a range? */
++		if (prev >= 0) {
++			nr_cpus += cpu - prev + 1;
++			prev = -1;
++		} else if (sep == '-')
++			prev = cpu;
++		else
++		nr_cpus++;
++
++		if (sep == '\n')
++			break;
++	}
++	fclose(file);
++	return nr_cpus;
++}
++
++int __get_nprocs ()
++{
++	long ret;
++	static int cached = -1;
++
++	ret = cached;
++	if (ret < 0)
++	{
++		ret = __get_sysfs_cpus("/sys/devices/system/cpu/online");
++		cached = ret;
++	}
++	return ret;
++}
++
++int __get_nprocs_conf ()
++{
++	long ret;
++	static int cached = -1;
++
++	ret = cached;
++	if (ret < 0)
++	{
++		ret = __get_sysfs_cpus("/sys/devices/system/cpu/possible");
++		cached = ret;
++	}
++	return ret;
++}
++#endif
++#endif
++
+ /* Prepares the crash memory headers and stores in supplied buffer. */
+ int FUNC(struct kexec_info *info,
+ 	 struct crash_elf_info *elf_info,
+@@ -46,7 +134,11 @@ int FUNC(struct kexec_info *info,
+ 	if (xen_present())
+ 		nr_cpus = xen_get_nr_phys_cpus();
+ 	else
++#ifndef __KLIBC__
+ 		nr_cpus = sysconf(_SC_NPROCESSORS_CONF);
++#else
++		nr_cpus = __get_nprocs_conf();
++#endif
+ 
+ 	if (nr_cpus < 0) {
+ 		return -1;
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0006-kexec-syscall.h-work-around-missing-syscall-wrapper.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0006-kexec-syscall.h-work-around-missing-syscall-wrapper.patch
new file mode 100644
index 0000000..3020f76
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0006-kexec-syscall.h-work-around-missing-syscall-wrapper.patch
@@ -0,0 +1,71 @@
+From 45a80fe7d247898d83edfeabe32b9de80a50a6be Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Fri, 31 Aug 2018 11:33:51 +0200
+Subject: [PATCH] kexec-syscall.h: work around missing syscall() wrapper
+
+Fix
+
+ kexec-syscall.h: In function 'kexec_load':
+ kexec-syscall.h:80:16: warning: implicit declaration of function 'syscall'
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ kexec/kexec-syscall.h | 21 +++++++++++++++++++++
+ 1 file changed, 21 insertions(+)
+
+diff --git a/kexec/kexec-syscall.h b/kexec/kexec-syscall.h
+index 33638c2..204007d 100644
+--- a/kexec/kexec-syscall.h
++++ b/kexec/kexec-syscall.h
+@@ -74,11 +74,16 @@
+ 
+ struct kexec_segment;
+ 
++#ifndef __KLIBC__
+ static inline long kexec_load(void *entry, unsigned long nr_segments,
+ 			struct kexec_segment *segments, unsigned long flags)
+ {
+ 	return (long) syscall(__NR_kexec_load, entry, nr_segments, segments, flags);
+ }
++#else
++extern long kexec_load(void *entry, unsigned long nr_segments,
++			struct kexec_segment *segments, unsigned long flags);
++#endif
+ 
+ static inline int is_kexec_file_load_implemented(void) {
+ 	if (__NR_kexec_file_load != 0xffffffff)
+@@ -86,6 +91,21 @@ static inline int is_kexec_file_load_implemented(void) {
+ 	return 0;
+ }
+ 
++#ifdef __KLIBC__
++/* Stub provided by klibc only for the following archs */
++#if defined (__x86_64__) || defined (__powerpc_64__) || defined (__s390x__)
++extern long kexec_file_load(int kernel_fd, int initrd_fd,
++			unsigned long cmdline_len, const char *cmdline_ptr,
++			unsigned long flags);
++#else
++static inline long kexec_file_load(int kernel_fd, int initrd_fd,
++			unsigned long cmdline_len, const char *cmdline_ptr,
++			unsigned long flags)
++{
++	return -1;
++}
++#endif
++#else
+ static inline long kexec_file_load(int kernel_fd, int initrd_fd,
+ 			unsigned long cmdline_len, const char *cmdline_ptr,
+ 			unsigned long flags)
+@@ -93,6 +113,7 @@ static inline long kexec_file_load(int kernel_fd, int initrd_fd,
+ 	return (long) syscall(__NR_kexec_file_load, kernel_fd, initrd_fd,
+ 				cmdline_len, cmdline_ptr, flags);
+ }
++#endif
+ 
+ #define KEXEC_ON_CRASH		0x00000001
+ #define KEXEC_PRESERVE_CONTEXT	0x00000002
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0007-kexec.c-add-guard-around-ENOTSUP.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0007-kexec.c-add-guard-around-ENOTSUP.patch
new file mode 100644
index 0000000..3d44683
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0007-kexec.c-add-guard-around-ENOTSUP.patch
@@ -0,0 +1,37 @@
+From e6bd7a1bcfbd3e54efc81fbd7d60d915f9af0632 Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Tue, 17 Apr 2018 11:35:14 +0200
+Subject: [PATCH] kexec.c: add guard around ENOTSUP
+
+Fix
+
+ kexec.c: In function 'main':
+ kexec.c:1515:11: error: 'ENOTSUP' undeclared
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ kexec/kexec.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/kexec/kexec.c b/kexec/kexec.c
+index 313d9fe..b5a8a1e 100644
+--- a/kexec/kexec.c
++++ b/kexec/kexec.c
+@@ -1501,6 +1501,7 @@ int main(int argc, char *argv[])
+ 					 */
+ 				case -EINVAL:
+ 				case -ENOEXEC:
++#ifndef __KLIBC__
+ 					 /*
+ 					  * ENOTSUP can be unsupported image
+ 					  * type or unsupported PE signature
+@@ -1513,6 +1514,7 @@ int main(int argc, char *argv[])
+ 					  * kernel bug
+ 					  */
+ 				case -ENOTSUP:
++#endif
+ 					do_kexec_file_syscall = 0;
+ 					break;
+ 			}
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0008-kexec.c-replace-mising-BLKGETSIZE64.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0008-kexec.c-replace-mising-BLKGETSIZE64.patch
new file mode 100644
index 0000000..cfc51cf
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0008-kexec.c-replace-mising-BLKGETSIZE64.patch
@@ -0,0 +1,32 @@
+From 12c7b09c3152f2b3475d081691a26bd1a5633256 Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Tue, 17 Apr 2018 11:38:42 +0200
+Subject: [PATCH] kexec.c: replace missing BLKGETSIZE64
+
+Fix
+
+ kexec.c: In function 'slurp_file_generic':
+ kexec.c:564:19: error: 'BLKGETSIZE64' undeclared
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ kexec/kexec.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/kexec/kexec.c b/kexec/kexec.c
+index b5a8a1e..7842f8b 100644
+--- a/kexec/kexec.c
++++ b/kexec/kexec.c
+@@ -54,6 +54,10 @@
+ #define KEXEC_LOADED_PATH "/sys/kernel/kexec_loaded"
+ #define KEXEC_CRASH_LOADED_PATH "/sys/kernel/kexec_crash_loaded"
+ 
++#ifndef BLKGETSIZE64
++#define BLKGETSIZE64	_IOR(0x12,114,size_t)
++#endif
++
+ unsigned long long mem_min = 0;
+ unsigned long long mem_max = ULONG_MAX;
+ static unsigned long kexec_flags = 0;
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0009-vmcore-dmesg.c-work-around-missing-imaxdiv.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0009-vmcore-dmesg.c-work-around-missing-imaxdiv.patch
new file mode 100644
index 0000000..df980b1
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0009-vmcore-dmesg.c-work-around-missing-imaxdiv.patch
@@ -0,0 +1,57 @@
+From ad598a71ffff6f86462211f252ac0c7b5de53869 Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Tue, 17 Apr 2018 13:14:12 +0200
+Subject: [PATCH] vmcore-dmesg.c: work around missing imaxdiv()
+
+Convert to integer arithmetic for klibc.
+
+Fix
+
+ vmcore-dmesg.c: In function 'dump_dmesg_structured':
+ vmcore-dmesg.c:578:2: error: unknown type name 'imaxdiv_t'
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ vmcore-dmesg/vmcore-dmesg.c | 13 ++++++++++++-
+ 1 file changed, 12 insertions(+), 1 deletion(-)
+
+diff --git a/vmcore-dmesg/vmcore-dmesg.c b/vmcore-dmesg/vmcore-dmesg.c
+index e340ef4..1b27b71 100644
+--- a/vmcore-dmesg/vmcore-dmesg.c
++++ b/vmcore-dmesg/vmcore-dmesg.c
+@@ -575,8 +575,11 @@ static void dump_dmesg_structured(int fd)
+ 	ssize_t ret;
+ 	char *msg;
+ 	uint16_t text_len;
++#ifndef __KLIBC__
+ 	imaxdiv_t imaxdiv_sec, imaxdiv_usec;
+-
++#else
++	int64_t imaxdiv_sec, imaxdiv_usec;
++#endif
+ 	if (!log_buf_vaddr) {
+ 		fprintf(stderr, "Missing the log_buf symbol\n");
+ 		exit(60);
+@@ -645,12 +648,20 @@ static void dump_dmesg_structured(int fd)
+ 			exit(65);
+ 		}
+ 		ts_nsec = struct_val_u64(buf, log_offset_ts_nsec);
++#ifndef __KLIBC__
+ 		imaxdiv_sec = imaxdiv(ts_nsec, 1000000000);
+ 		imaxdiv_usec = imaxdiv(imaxdiv_sec.rem, 1000);
+ 
+ 		len += sprintf(out_buf + len, "[%5llu.%06llu] ",
+ 			(long long unsigned int)imaxdiv_sec.quot,
+ 			(long long unsigned int)imaxdiv_usec.quot);
++#else
++		imaxdiv_sec = ts_nsec / 1000000000;
++		imaxdiv_usec = (ts_nsec % 1000000000) / 1000;
++		len += sprintf(out_buf + len, "[%5llu.%06llu] ",
++			(long long unsigned int)imaxdiv_sec,
++			(long long unsigned int)imaxdiv_usec);
++#endif
+ 
+ 		/* escape non-printable characters */
+ 		text_len = struct_val_u16(buf, log_offset_text_len);
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0010-fs2dt.c-work-around-missing-getline.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0010-fs2dt.c-work-around-missing-getline.patch
new file mode 100644
index 0000000..cff1485
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0010-fs2dt.c-work-around-missing-getline.patch
@@ -0,0 +1,47 @@
+From edefda702d906d472ee7a675f6b506d5cfca7ac8 Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Tue, 17 Apr 2018 13:48:25 +0200
+Subject: [PATCH] fs2dt.c: work around missing getline()
+
+This simple case can be rewrtten with fgets()
+
+Fix
+
+ fs2dt.c: In function 'dt_copy_old_root_param':
+ fs2dt.c:541:6: warning: implicit declaration of function 'getline'
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ kexec/fs2dt.c | 8 ++++++++
+ 1 file changed, 8 insertions(+)
+
+diff --git a/kexec/fs2dt.c b/kexec/fs2dt.c
+index 07a5e2f..d635636 100644
+--- a/kexec/fs2dt.c
++++ b/kexec/fs2dt.c
+@@ -531,6 +531,9 @@ static void dt_copy_old_root_param(void)
+ 	char *last_cmdline = NULL;
+ 	char *p, *old_param;
+ 	size_t len = 0;
++#ifdef __KLIBC__
++	char buf[512];
++#endif
+ 
+ 	strcpy(filename, pathname);
+ 	strcat(filename, "bootargs");
+@@ -538,8 +541,13 @@ static void dt_copy_old_root_param(void)
+ 	if (!fp)
+ 		return;
+ 
++#ifndef __KLIBC__
+ 	if (getline(&last_cmdline, &len, fp) == -1)
+ 		die("unable to read %s\n", filename);
++#else
++	last_cmdline = fgets(buf, 200, fp);
++	last_cmdline[strlen(last_cmdline) - 1] = '\0';
++#endif
+ 
+ 	p = strstr(last_cmdline, "root=");
+ 	if (p) {
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0011-purgatory-Makefile-adapt-to-klcc.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0011-purgatory-Makefile-adapt-to-klcc.patch
new file mode 100644
index 0000000..636151b
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0011-purgatory-Makefile-adapt-to-klcc.patch
@@ -0,0 +1,38 @@
+From 9b6866b106eb3ad11115bd591a23e65a68dd847d Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Tue, 21 Aug 2018 16:31:44 +0200
+Subject: [PATCH 11/11] purgatory Makefile: adapt to klcc
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+---
+ purgatory/Makefile | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/purgatory/Makefile b/purgatory/Makefile
+index 49ce80a..72eefaa 100644
+--- a/purgatory/Makefile
++++ b/purgatory/Makefile
+@@ -47,7 +47,7 @@ purgatory/sha256.o: $(srcdir)/util_lib/sha256.c
+ $(PURGATORY): CC=$(TARGET_CC)
+ $(PURGATORY): CFLAGS+=$(PURGATORY_EXTRA_CFLAGS) \
+ 		      $($(ARCH)_PURGATORY_EXTRA_CFLAGS) \
+-		      -Os -fno-builtin -ffreestanding \
++		      -Os -fno-builtin -ffreestanding -nostdinc \
+ 		      -fno-zero-initialized-in-bss \
+ 		      -fno-PIC -fno-PIE -fno-stack-protector
+ 
+@@ -59,8 +59,8 @@ $(PURGATORY): CPPFLAGS=$($(ARCH)_PURGATORY_EXTRA_CFLAGS) \
+ 			-Iinclude \
+ 			-I$(shell $(CC) -print-file-name=include)
+ $(PURGATORY): LDFLAGS=$($(ARCH)_PURGATORY_EXTRA_CFLAGS)\
+-			-Wl,--no-undefined -nostartfiles -nostdlib \
+-			-nodefaultlibs -e purgatory_start -r \
++			-Wl,--no-undefined -Wl,-no-pie -Wl,-nostartfiles -Wl,-nostdlib \
++			-Wl,-nodefaultlibs -Wl,--entry=purgatory_start -Wl,-r \
+ 			-Wl,-Map=$(PURGATORY_MAP)
+ 
+ $(PURGATORY): $(PURGATORY_OBJS)
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0012-purgatory-string.c-avoid-inclusion-of-string.h.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0012-purgatory-string.c-avoid-inclusion-of-string.h.patch
new file mode 100644
index 0000000..20934da
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0012-purgatory-string.c-avoid-inclusion-of-string.h.patch
@@ -0,0 +1,31 @@
+From 2d2ad16f9328a7cbb3f5b8479ae93eb923a0727f Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Thu, 19 Apr 2018 00:28:14 +0200
+Subject: [PATCH] purgatory/string.c: avoid inclusion of string.h
+
+Fix
+
+ purgatory/string.c:39:5: error: conflicting types for 'memcmp'
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ purgatory/string.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/purgatory/string.c b/purgatory/string.c
+index f06c460..c5e978a 100644
+--- a/purgatory/string.c
++++ b/purgatory/string.c
+@@ -1,5 +1,7 @@
+ #include <stddef.h>
++#ifndef __KLIBC__
+ #include <string.h>
++#endif
+ 
+ size_t strnlen(const char *s, size_t max)
+ {
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0013-sha256.h-avoid-inclusion-of-sys-types.h.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0013-sha256.h-avoid-inclusion-of-sys-types.h.patch
new file mode 100644
index 0000000..5d1664f
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0013-sha256.h-avoid-inclusion-of-sys-types.h.patch
@@ -0,0 +1,36 @@
+From ec6000b9f287e62cb0746e26cfa4372c7ea528f4 Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Thu, 19 Apr 2018 23:26:43 +0200
+Subject: [PATCH] sha256.h: avoid inclusion of sys/types.h
+
+Fix
+
+ purgatory/printf.c:2:10: fatal error: limits.h:
+ No such file or directory
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ util_lib/include/sha256.h | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/util_lib/include/sha256.h b/util_lib/include/sha256.h
+index 467fb22..40fd3ed 100644
+--- a/util_lib/include/sha256.h
++++ b/util_lib/include/sha256.h
+@@ -1,7 +1,11 @@
+ #ifndef SHA256_H
+ #define SHA256_H
+ 
++#ifndef __KLIBC__
+ #include <sys/types.h>
++#else
++#include <stddef.h>
++#endif
+ #include <stdint.h>
+ 
+ typedef struct
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0014-add-if_nameindex-from-musl.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0014-add-if_nameindex-from-musl.patch
new file mode 100644
index 0000000..ad21266
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0014-add-if_nameindex-from-musl.patch
@@ -0,0 +1,152 @@
+From b15e9610b4ab52c381e712241d50dea96d50d873 Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Wed, 2 May 2018 23:14:19 +0200
+Subject: [PATCH 14/14] add if_nameindex from musl
+
+Taken from musl, minimal changes.
+klibc lacks struct and func
+
+Fix
+
+ ifdown.o: In function `ifdown':
+ ifdown.c (.text+0x30): undefined reference to `if_nameindex'
+
+While there add klibc-specific guard and include sys/types.h
+to fix :
+
+ /kexec/if_nameindex.c:2:
+ /usr/lib/klibc/include/linux/types.h:22:0:
+ warning: "__bitwise" redefined
+ #define __bitwise __bitwise__
+
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+---
+ kexec/Makefile       |  2 +-
+ kexec/if_nameindex.c | 64 ++++++++++++++++++++++++++++++++++++++++++++++++++++
+ kexec/if_nameindex.h | 15 ++++++++++++
+ kexec/ifdown.c       |  3 +++
+ 4 files changed, 83 insertions(+), 1 deletion(-)
+ create mode 100644 kexec/if_nameindex.c
+ create mode 100644 kexec/if_nameindex.h
+
+diff --git a/kexec/Makefile b/kexec/Makefile
+index 4db84d8..fb7520b 100644
+--- a/kexec/Makefile
++++ b/kexec/Makefile
+@@ -11,7 +11,7 @@ KEXEC_SRCS = $(KEXEC_SRCS_base)
+ KEXEC_GENERATED_SRCS =
+ 
+ KEXEC_SRCS_base += kexec/kexec.c
+-KEXEC_SRCS_base += kexec/ifdown.c
++KEXEC_SRCS_base += kexec/if_nameindex kexec/ifdown.c
+ KEXEC_SRCS_base += kexec/kexec-elf.c
+ KEXEC_SRCS_base += kexec/kexec-elf-exec.c
+ KEXEC_SRCS_base += kexec/kexec-elf-core.c
+diff --git a/kexec/if_nameindex.c b/kexec/if_nameindex.c
+new file mode 100644
+index 0000000..e586e41
+--- /dev/null
++++ b/kexec/if_nameindex.c
+@@ -0,0 +1,64 @@
++#define _GNU_SOURCE
++#ifdef __KLIBC__
++#include <sys/types.h>
++#endif
++#include <netinet/in.h>
++#include <net/if.h>
++#include <stdlib.h>
++#include <sys/socket.h>
++#include <sys/ioctl.h>
++#include <errno.h>
++#include <sys/syscall.h>
++#include <stdio.h>
++#ifdef __KLIBC__
++#include "if_nameindex.h"
++#endif
++
++static void *do_nameindex(int s, size_t n)
++{
++	size_t i, len, k;
++	struct ifconf conf;
++	struct if_nameindex *idx;
++
++	idx = malloc(n * (sizeof(struct if_nameindex)+sizeof(struct ifreq)));
++	if (!idx) return 0;
++
++	conf.ifc_buf = (void *)&idx[n];
++	conf.ifc_len = len = n * sizeof(struct ifreq);
++	if (ioctl(s, SIOCGIFCONF, &conf) < 0) {
++		free(idx);
++		return 0;
++	}
++	if (conf.ifc_len == len) {
++		free(idx);
++		return (void *)-1;
++	}
++
++	n = conf.ifc_len / sizeof(struct ifreq);
++	for (i=k=0; i<n; i++) {
++		if (ioctl(s, SIOCGIFINDEX, &conf.ifc_req[i]) < 0) {
++			k++;
++			continue;
++		}
++		idx[i-k].if_index = conf.ifc_req[i].ifr_ifindex;
++		idx[i-k].if_name = conf.ifc_req[i].ifr_name;
++	}
++	idx[i-k].if_name = 0;
++	idx[i-k].if_index = 0;
++
++	return idx;
++}
++
++struct if_nameindex *if_nameindex()
++{
++	size_t n;
++	void *p = 0;
++	int s = socket(AF_UNIX, SOCK_DGRAM, 0);
++	if (s>=0) {
++		for (n=0; (p=do_nameindex(s, n)) == (void *)-1; n++);
++/*		__syscall(SYS_close, s); */
++		close(s);
++	}
++	errno = ENOBUFS;
++	return p;
++}
+diff --git a/kexec/if_nameindex.h b/kexec/if_nameindex.h
+new file mode 100644
+index 0000000..1725fbd
+--- /dev/null
++++ b/kexec/if_nameindex.h
+@@ -0,0 +1,15 @@
++#ifndef _NET_IF__NAMEINDEX_H
++#define _NET_IF_NAMEINDEX_H
++
++struct if_nameindex
++{
++    unsigned int if_index;
++    char *if_name;
++};
++
++unsigned int if_nametoindex (const char *);
++char *if_indextoname (unsigned int, char *);
++struct if_nameindex *if_nameindex (void);
++void if_freenameindex (struct if_nameindex *);
++
++#endif
+diff --git a/kexec/ifdown.c b/kexec/ifdown.c
+index 82c6141..cc3ca9f 100644
+--- a/kexec/ifdown.c
++++ b/kexec/ifdown.c
+@@ -18,6 +18,9 @@ char *v_ifdown = "@(#)ifdown.c  1.11  02-Jun-1998  miquels@cistron.nl";
+ 
+ #include <netinet/in.h>
+ #include <net/if.h>
++#ifdef __KLIBC__
++#include "if_nameindex.h"
++#endif
+ 
+ /*
+  *  First, we find all shaper devices and down them. Then we
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0015-vmcore-dmesg-fix-warning.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0015-vmcore-dmesg-fix-warning.patch
new file mode 100644
index 0000000..0b88b94
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/0015-vmcore-dmesg-fix-warning.patch
@@ -0,0 +1,29 @@
+From 3294266c6a875c5009065c1ae5d0b86200c4147c Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Sun, 29 Apr 2018 00:52:31 +0200
+Subject: [PATCH 6/6] vmcore-dmesg: fix warning
+
+ # define __bitwise
+
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+---
+ vmcore-dmesg/vmcore-dmesg.c | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/vmcore-dmesg/vmcore-dmesg.c b/vmcore-dmesg/vmcore-dmesg.c
+index e340ef4..91e4789 100644
+--- a/vmcore-dmesg/vmcore-dmesg.c
++++ b/vmcore-dmesg/vmcore-dmesg.c
+@@ -2,6 +2,9 @@
+ #define _GNU_SOURCE
+ #define _LARGEFILE_SOURCE 1
+ #define _FILE_OFFSET_BITS 64
++#ifdef __KLIBC__
++#include <sys/types.h>
++#endif
+ #include <endian.h>
+ #include <byteswap.h>
+ #include <stdio.h>
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/arm64-crashdump-arm64.c-fix-warning.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/arm64-crashdump-arm64.c-fix-warning.patch
new file mode 100644
index 0000000..24be4dd
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/arm64-crashdump-arm64.c-fix-warning.patch
@@ -0,0 +1,34 @@
+From 6f69f489a442b3a192e4c08748ee8c4d31c75dae Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Sun, 29 Apr 2018 00:46:16 +0200
+Subject: [PATCH 5/6] arm64: crashdump-arm64.c: fix warning
+
+                 from ../git/kexec/kexec.h:6,
+                 from ../git/kexec/arch/arm64/crashdump-arm64.c:18:
+/tmp/build/tmp-musl/work/aarch64-oe-linux-musl/kexec-tools-klibc/0.6+gitAUTOINC+
+0481e9ed61-r0/recipe-sysroot/usr/lib/klibc/include/klibc/compiler.h:144:0: warni
+ng: "__bitwise" redefined
+ # define __bitwise
+
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+---
+ kexec/arch/arm64/crashdump-arm64.c | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/kexec/arch/arm64/crashdump-arm64.c b/kexec/arch/arm64/crashdump-arm64.c
+index 4fd7aa8..890d88f 100644
+--- a/kexec/arch/arm64/crashdump-arm64.c
++++ b/kexec/arch/arm64/crashdump-arm64.c
+@@ -13,6 +13,9 @@
+ #define _GNU_SOURCE
+ 
+ #include <errno.h>
++#ifdef __KLIBC__
++#include <sys/types.h>
++#endif
+ #include <linux/elf.h>
+ 
+ #include "kexec.h"
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/arm64_kexec-arm64.c-workaround-for-getrandom-syscall.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/arm64_kexec-arm64.c-workaround-for-getrandom-syscall.patch
new file mode 100644
index 0000000..b22ac3a
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/arm64_kexec-arm64.c-workaround-for-getrandom-syscall.patch
@@ -0,0 +1,61 @@
+From 10afeecd10499fbd64b2c68d3b076c6906df441f Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Wed, 5 Sep 2018 17:07:48 +0200
+Subject: [PATCH] kexec-arm64.c: workaround for getrandom() syscall
+
+The syscall was added to OE's klibc.
+Fix
+
+| ../git/kexec/arch/arm64/kexec-arm64.c:19:10: fatal error: syscall.h: No such file or directory
+|  #include <syscall.h>
+
+and
+
+| ../git/kexec/arch/arm64/kexec-arm64.c: In function 'setup_2nd_dtb':
+| ../git/kexec/arch/arm64/kexec-arm64.c:499:12: warning: implicit declaration of function 'getrandom'; did you mean 'srandom'? [-Wimplicit-function-declaration]
+|    result = getrandom(&fdt_val64,
+
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+---
+ kexec/arch/arm64/kexec-arm64.c | 12 +++++++++++-
+ 1 file changed, 11 insertions(+), 1 deletion(-)
+
+diff --git a/kexec/arch/arm64/kexec-arm64.c b/kexec/arch/arm64/kexec-arm64.c
+index 7a12479..8a7f5c5 100644
+--- a/kexec/arch/arm64/kexec-arm64.c
++++ b/kexec/arch/arm64/kexec-arm64.c
+@@ -16,7 +16,11 @@
+ #include <elf.h>
+ 
+ #include <unistd.h>
++
++#ifndef __KLIBC__
+ #include <syscall.h>
++#endif
++
+ #include <errno.h>
+ #include <linux/random.h>
+ 
+@@ -487,10 +491,16 @@ static int setup_2nd_dtb(struct dtb *dtb, char *command_line, int on_crash)
+ 		 * have a valid random seed to pass to the
+ 		 * secondary kernel.
+ 		 */
++#ifndef __KLIBC__
+ 		result = syscall(SYS_getrandom, &fdt_val64,
+ 				sizeof(fdt_val64),
+ 				GRND_NONBLOCK);
+-
++#else
++		extern ssize_t getrandom(void *, size_t, unsigned int);
++		result = getrandom(&fdt_val64,
++				sizeof(fdt_val64),
++				GRND_NONBLOCK);
++#endif
+ 		if(result == -1) {
+ 			dbgprintf("%s: Reading random bytes failed.\n",
+ 					__func__);
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/arm64_kexec-image-header.h-add-missing-le64toh.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/arm64_kexec-image-header.h-add-missing-le64toh.patch
new file mode 100644
index 0000000..7decbac
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/arm64_kexec-image-header.h-add-missing-le64toh.patch
@@ -0,0 +1,40 @@
+From af7d06a753a4c377b7ffe587da67a6ba56048bea Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Thu, 19 Apr 2018 10:47:17 +0200
+Subject: [PATCH 2/2] kexec/arm64: image-header.h: add macro for le64toh
+
+Fix
+
+ kexec-arm64.c:(.text+0x370): undefined reference to `le64toh'
+ kexec-arm64.c:(.text+0x380): undefined reference to `le64toh'
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ kexec/arch/arm64/image-header.h | 9 +++++++++
+ 1 file changed, 9 insertions(+)
+
+diff --git a/kexec/arch/arm64/image-header.h b/kexec/arch/arm64/image-header.h
+index 158d411..10ed2d6 100644
+--- a/kexec/arch/arm64/image-header.h
++++ b/kexec/arch/arm64/image-header.h
+@@ -8,6 +8,15 @@
+ #include <endian.h>
+ #include <stdint.h>
+ 
++#ifdef __KLIBC__
++#if __BYTE_ORDER == __LITTLE_ENDIAN
++#define le64toh(x) (x)
++#endif
++#if __BYTE_ORDER == __BIG_ENDIAN
++#define le64toh(x) __bswap_64(x)
++#endif
++#endif
++
+ /**
+  * struct arm64_image_header - arm64 kernel image header.
+  *
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/arm_crashdump-fix-buffer-align.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/arm_crashdump-fix-buffer-align.patch
new file mode 100644
index 0000000..c6afdfa
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/arm_crashdump-fix-buffer-align.patch
@@ -0,0 +1,44 @@
+From 06b0d43c20f7c6200902d4c6db3d33416877f71c Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Sun, 26 Aug 2018 21:40:06 +0200
+Subject: [PATCH 1/1] arm- backport from oe-core
+
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+---
+ kexec/arch/arm/crashdump-arm.c | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git a/kexec/arch/arm/crashdump-arm.c b/kexec/arch/arm/crashdump-arm.c
+index 2530b29..af2600d 100644
+--- a/kexec/arch/arm/crashdump-arm.c
++++ b/kexec/arch/arm/crashdump-arm.c
+@@ -240,6 +240,7 @@ int load_crashdump_segments(struct kexec_info *info, char *mod_cmdline)
+ 	void *buf;
+ 	int err;
+ 	int last_ranges;
++	unsigned short align_bit_shift = 20;
+ 
+ 	/*
+ 	 * First fetch all the memory (RAM) ranges that we are going to pass to
+@@ -281,6 +282,7 @@ int load_crashdump_segments(struct kexec_info *info, char *mod_cmdline)
+ 
+ 		/* for support LPAE enabled kernel*/
+ 		elf_info.class = ELFCLASS64;
++		align_bit_shift = 21;
+ 
+ 		err = crash_create_elf64_headers(info, &elf_info,
+ 					 usablemem_rgns.ranges,
+@@ -302,8 +304,9 @@ int load_crashdump_segments(struct kexec_info *info, char *mod_cmdline)
+ 	 * 1MB) so that available memory passed in kernel command line will be
+ 	 * aligned to 1MB. This is because kernel create_mapping() wants memory
+ 	 * regions to be aligned to SECTION_SIZE.
++	 * The SECTION_SIZE of LPAE kernel is '1UL << 21' defined in pgtable-3level.h
+ 	 */
+-	elfcorehdr = add_buffer_phys_virt(info, buf, bufsz, bufsz, 1 << 20,
++	elfcorehdr = add_buffer_phys_virt(info, buf, bufsz, bufsz, 1 << align_bit_shift,
+ 					  crash_kernel_mem.start,
+ 					  crash_kernel_mem.end, -1, 0);
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/arm_crashdump.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/arm_crashdump.patch
new file mode 100644
index 0000000..9596263
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/arm_crashdump.patch
@@ -0,0 +1,31 @@
+From 6dae4752a53973c152b3e91e8a4ca74a486dae8b Mon Sep 17 00:00:00 2001
+From: OpenEmbedded <oe.patch@oe>
+Date: Wed, 11 Apr 2018 22:51:00 +0200
+Subject: [PATCH] use our elf.h header
+
+Fix
+
+ kexec/arch/arm/crashdump-arm.c:70:13: error: 'EM_ARM' undeclared here
+ (not in a function); did you mean 'EM_860'?
+    .machine = EM_ARM,
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ kexec/arch/arm/crashdump-arm.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/kexec/arch/arm/crashdump-arm.c b/kexec/arch/arm/crashdump-arm.c
+index daa4788..2530b29 100644
+--- a/kexec/arch/arm/crashdump-arm.c
++++ b/kexec/arch/arm/crashdump-arm.c
+@@ -21,7 +21,7 @@
+  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+  */
+ #include <limits.h>
+-#include <elf.h>
++#include "../../../include/elf.h"
+ #include <errno.h>
+ #include <stdio.h>
+ #include <stdlib.h>
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/kexec-x32.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/kexec-x32.patch
new file mode 100644
index 0000000..26d18eb
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/kexec-x32.patch
@@ -0,0 +1,88 @@
+x86_64: Add support to build kexec-tools with x32 ABI
+
+Summary of changes,
+
+configure.ac: Add test for detect x32 ABI.
+purgatory/arch/x86_64/Makefile: Not use mcmodel large when
+	x32 ABI is set.
+kexec/arch/x86_64/kexec-elf-rel-x86_64.c: When x32 ABI is set
+	use ELFCLASS32 instead of ELFCLASS64.
+kexec/kexec-syscall.h: Add correct syscall number for x32 ABI.
+
+Upstream-Status: Submitted
+
+Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
+Signed-off-by: Mariano Lopez <mariano.lopez@linux.intel.com>
+
+---
+ configure.ac                             | 9 +++++++++
+ kexec/arch/x86_64/kexec-elf-rel-x86_64.c | 4 ++++
+ kexec/kexec-syscall.h                    | 4 ++++
+ purgatory/arch/x86_64/Makefile           | 4 +++-
+ 4 files changed, 20 insertions(+), 1 deletion(-)
+
+Index: kexec-tools-2.0.10/configure.ac
+===================================================================
+--- kexec-tools-2.0.10.orig/configure.ac
++++ kexec-tools-2.0.10/configure.ac
+@@ -56,6 +56,15 @@ case $target_cpu in
+ 		;;
+ 	ia64|x86_64|alpha|m68k )
+ 		ARCH="$target_cpu"
++
++		dnl ---Test for x32 ABI in x86_64
++		if test "x$ARCH" = "xx86_64" ; then
++			AC_EGREP_CPP(x32_test,
++			[#if defined(__x86_64__) && defined (__ILP32__)
++				x32_test
++			#endif
++			], SUBARCH='x32', SUBARCH='64')
++		fi
+ 		;;
+ 	* )
+ 		AC_MSG_ERROR([unsupported architecture $target_cpu])
+Index: kexec-tools-2.0.10/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
+===================================================================
+--- kexec-tools-2.0.10.orig/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
++++ kexec-tools-2.0.10/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
+@@ -8,7 +8,11 @@ int machine_verify_elf_rel(struct mem_eh
+ 	if (ehdr->ei_data != ELFDATA2LSB) {
+ 		return 0;
+ 	}
++#ifdef __ILP32__
++	if (ehdr->ei_class != ELFCLASS32) {
++#else
+ 	if (ehdr->ei_class != ELFCLASS64) {
++#endif
+ 		return 0;
+ 	}
+ 	if (ehdr->e_machine != EM_X86_64) {
+Index: kexec-tools-2.0.10/kexec/kexec-syscall.h
+===================================================================
+--- kexec-tools-2.0.10.orig/kexec/kexec-syscall.h
++++ kexec-tools-2.0.10/kexec/kexec-syscall.h
+@@ -31,8 +31,12 @@
+ #define __NR_kexec_load		268
+ #endif
+ #ifdef __x86_64__
++#ifdef __ILP32__
++#define __NR_kexec_load		528
++#else
+ #define __NR_kexec_load		246
+ #endif
++#endif
+ #ifdef __s390x__
+ #define __NR_kexec_load		277
+ #endif
+Index: kexec-tools-2.0.10/purgatory/arch/x86_64/Makefile
+===================================================================
+--- kexec-tools-2.0.10.orig/purgatory/arch/x86_64/Makefile
++++ kexec-tools-2.0.10/purgatory/arch/x86_64/Makefile
+@@ -23,4 +23,6 @@ x86_64_PURGATORY_SRCS += purgatory/arch/
+ x86_64_PURGATORY_SRCS += purgatory/arch/i386/vga.c
+ x86_64_PURGATORY_SRCS += purgatory/arch/i386/pic.c
+ 
+-x86_64_PURGATORY_EXTRA_CFLAGS = -mcmodel=large
++ifeq ($(SUBARCH),64)
++        x86_64_PURGATORY_EXTRA_CFLAGS = -mcmodel=large
++endif
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/powerpc-purgatory-Makefile-remove-unknown-flags.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/powerpc-purgatory-Makefile-remove-unknown-flags.patch
new file mode 100644
index 0000000..c3b2071
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/powerpc-purgatory-Makefile-remove-unknown-flags.patch
@@ -0,0 +1,34 @@
+From 709dfe457c07aa0275f3da14634cbce5cf1029dc Mon Sep 17 00:00:00 2001
+From: Andrea Adami <andrea.adami@gmail.com>
+Date: Thu, 19 Apr 2018 19:26:53 +0200
+Subject: [PATCH 3/3] powerpc/purgatory: Makefile: remove unknown flags for
+ powerpc
+
+Fix
+
+ powerpc-oe-linux-musl-ld: unrecognised emulation mode: soft-float
+ Supported emulations: elf32ppclinux elf32ppc elf32ppcsim elf32lppclinux
+                       elf32lppc elf32lppcsim elf64ppc elf64lppc
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+---
+ purgatory/arch/ppc/Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/purgatory/arch/ppc/Makefile b/purgatory/arch/ppc/Makefile
+index c85c58a..cd44a16 100644
+--- a/purgatory/arch/ppc/Makefile
++++ b/purgatory/arch/ppc/Makefile
+@@ -7,7 +7,7 @@ ppc_PURGATORY_SRCS += purgatory/arch/ppc/misc.S
+ ppc_PURGATORY_SRCS += purgatory/arch/ppc/purgatory-ppc.c
+ ppc_PURGATORY_SRCS += purgatory/arch/ppc/console-ppc.c
+ 
+-ppc_PURGATORY_EXTRA_CFLAGS += -msoft-float
++#ppc_PURGATORY_EXTRA_CFLAGS += -msoft-float
+ 
+ dist += purgatory/arch/ppc/Makefile $(ppc_PURGATORY_SRCS)		\
+ 	purgatory/arch/ppc/purgatory-ppc.h purgatory/arch/ppc/ppc_asm.h
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/powerpc_change-the-memory-size-limit.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/powerpc_change-the-memory-size-limit.patch
new file mode 100644
index 0000000..dc97d93
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/powerpc_change-the-memory-size-limit.patch
@@ -0,0 +1,35 @@
+From b19b68eab567aa534cf8dec79fe18e3dc0e14043 Mon Sep 17 00:00:00 2001
+From: Quanyang Wang <quanyang.wang@windriver.com>
+Date: Tue, 16 Jun 2015 12:59:57 +0800
+Subject: [PATCH] powerpc: change the memory size limit
+
+When run "kexec" in powerpc board, the kexec has a limit that
+the kernel text and bss size must be less than 24M. But now
+some kernel size exceed the limit. So we need to change the limit,
+else will get the error log as below:
+
+my_load:669: do
+Could not find a free area of memory of 0x12400 bytes...
+Could not find a free area of memory of 0x13000 bytes...
+locate_hole failed
+
+Upstream-Status: Pending
+
+Signed-off-by: Quanyang Wang <quanyang.wang@windriver.com>
+---
+ kexec/arch/ppc/kexec-ppc.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+Index: kexec-tools-2.0.10/kexec/arch/ppc/kexec-ppc.h
+===================================================================
+--- kexec-tools-2.0.10.orig/kexec/arch/ppc/kexec-ppc.h
++++ kexec-tools-2.0.10/kexec/arch/ppc/kexec-ppc.h
+@@ -42,7 +42,7 @@ void dol_ppc_usage(void);
+  * During inital setup the kernel does not map the whole memory but a part of
+  * it. On Book-E that is 64MiB, 601 24MiB or 256MiB (if possible).
+  */
+-#define KERNEL_ACCESS_TOP (24 * 1024 * 1024)
++#define KERNEL_ACCESS_TOP (36 * 1024 * 1024)
+ 
+ /* boot block version 17 as defined by the linux kernel */
+ struct bootblock {
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/x86_basename.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/x86_basename.patch
new file mode 100644
index 0000000..0d0ed23
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/x86_basename.patch
@@ -0,0 +1,30 @@
+From 5f47c30759684cea9a7a409646686c1a358b78ac Mon Sep 17 00:00:00 2001
+From: OpenEmbedded <oe.patch@oe>
+Date: Wed, 11 Apr 2018 22:51:05 +0200
+Subject: [PATCH] replace basename() with sscanf()
+
+klibc lacks basename()
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ kexec/arch/i386/x86-linux-setup.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/kexec/arch/i386/x86-linux-setup.c b/kexec/arch/i386/x86-linux-setup.c
+index 6c7d260..7850083 100644
+--- a/kexec/arch/i386/x86-linux-setup.c
++++ b/kexec/arch/i386/x86-linux-setup.c
+@@ -304,9 +304,9 @@ static int add_edd_entry(struct x86_linux_param_header *real_mode,
+ 	memset(edd_info, 0, sizeof(struct edd_info));
+ 
+ 	/* extract the device number */
+-	if (sscanf(basename(sysfs_name), "int13_dev%hhx", &devnum) != 1) {
++	if (sscanf(strrchr(sysfs_name,'/') + 1, "int13_dev%hhx", &devnum) != 1) {
+ 		fprintf(stderr, "Invalid format of int13_dev dir "
+-				"entry: %s\n", basename(sysfs_name));
++				"entry: %s\n", strrchr(sysfs_name,'/') + 1);
+ 		return -1;
+ 	}
+ 
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/x86_kexec_test.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/x86_kexec_test.patch
new file mode 100644
index 0000000..1c471f5
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/x86_kexec_test.patch
@@ -0,0 +1,30 @@
+From 9de68ec5af8db2eff352f12da28145fe5e96244d Mon Sep 17 00:00:00 2001
+From: OpenEmbedded <oe.patch@oe>
+Date: Wed, 11 Apr 2018 22:51:05 +0200
+Subject: [PATCH] do not build test
+
+The purpose of this recipe is to build the smallest
+binaries. kexek klibc-static for armv5 is around 86 KiB
+
+Upstream-Status: Inappropriate [embedded specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ Makefile.in | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index fb01134..440730d 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -173,8 +173,8 @@ PSRCS:=$(foreach s, $(SRCS), $(PACKAGE_NAME)-$(PACKAGE_VERSION)/$(s))
+ PGSRCS:=$(foreach s, $(GENERATED_SRCS), $(PACKAGE_NAME)-$(PACKAGE_VERSION)/$(s))
+ 
+ MAN_PAGES:=$(KEXEC_MANPAGE) $(VMCORE_DMESG_MANPAGE)
+-BINARIES_i386:=$(KEXEC_TEST)
+-BINARIES_x86_64:=$(KEXEC_TEST)
++#BINARIES_i386:=$(KEXEC_TEST)
++#BINARIES_x86_64:=$(KEXEC_TEST)
+ BINARIES:=$(KEXEC) $(VMCORE_DMESG) $(BINARIES_$(ARCH))
+ 
+ UNINSTALL_KDUMP = $(sbindir)/kdump
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/x86_sys_io.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/x86_sys_io.patch
new file mode 100644
index 0000000..493f298
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/x86_sys_io.patch
@@ -0,0 +1,36 @@
+From a992ee014efacdc98d5658be9930dcab0eaadfd7 Mon Sep 17 00:00:00 2001
+From: OpenEmbedded <oe.patch@oe>
+Date: Wed, 11 Apr 2018 22:51:04 +0200
+Subject: [PATCH] i386: replace with our io.h
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ purgatory/arch/i386/pic.c | 2 +-
+ purgatory/arch/i386/vga.c | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/purgatory/arch/i386/pic.c b/purgatory/arch/i386/pic.c
+index c23c459..c5f7046 100644
+--- a/purgatory/arch/i386/pic.c
++++ b/purgatory/arch/i386/pic.c
+@@ -16,7 +16,7 @@
+  * along with this program; if not, write to the Free Software
+  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+  */
+-#include <sys/io.h>
++#include "include/arch/io.h"
+ #include <purgatory.h>
+ #include "purgatory-x86.h"
+ 
+diff --git a/purgatory/arch/i386/vga.c b/purgatory/arch/i386/vga.c
+index e65976c..d079d96 100644
+--- a/purgatory/arch/i386/vga.c
++++ b/purgatory/arch/i386/vga.c
+@@ -1,4 +1,4 @@
+-#include <sys/io.h>
++#include "include/arch/io.h"
+ #include <purgatory.h>
+ #include "purgatory-x86.h"
+ 
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/x86_vfscanf.patch b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/x86_vfscanf.patch
new file mode 100644
index 0000000..2f0ad2e
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc/x86_vfscanf.patch
@@ -0,0 +1,43 @@
+From 423c3f6f41fe04f4512e2a97a130f072d53dd4cf Mon Sep 17 00:00:00 2001
+From: OpenEmbedded <oe.patch@oe>
+Date: Wed, 11 Apr 2018 22:51:05 +0200
+Subject: [PATCH] x86-linux-setup.c: replace vfscanf() with vsscanf()
+
+klibc lacks vfscanf()
+
+Upstream-Status: Inappropriate [klibc specific]
+Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
+
+---
+ kexec/arch/i386/x86-linux-setup.c | 11 ++++++++++-
+ 1 file changed, 10 insertions(+), 1 deletion(-)
+
+diff --git a/kexec/arch/i386/x86-linux-setup.c b/kexec/arch/i386/x86-linux-setup.c
+index 7850083..e190356 100644
+--- a/kexec/arch/i386/x86-linux-setup.c
++++ b/kexec/arch/i386/x86-linux-setup.c
+@@ -200,6 +200,8 @@ static int file_scanf(const char *dir, const char *file, const char *scanf_line,
+ 	FILE *fp;
+ 	int retno;
+ 	char filename[PATH_MAX];
++	long line_size = MAX_LINE;
++	char *line;
+ 
+ 	snprintf(filename, PATH_MAX, "%s/%s", dir, file);
+ 	filename[PATH_MAX-1] = 0;
+@@ -210,7 +212,14 @@ static int file_scanf(const char *dir, const char *file, const char *scanf_line,
+ 	}
+ 
+ 	va_start(argptr, scanf_line);
+-	retno = vfscanf(fp, scanf_line, argptr);
++
++	line = xmalloc(sizeof(line) * line_size);
++	while(fgets(line, sizeof(line), fp) != NULL ) {
++		line_size += MAX_LINE;
++		line = xrealloc(line,line_size);
++	}
++	retno = vsscanf(line, scanf_line, argptr);
++
+ 	va_end(argptr);
+ 
+ 	fclose(fp);
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc_2.0.2.bb b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc_2.0.2.bb
deleted file mode 100644
index 2e27033..0000000
--- a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc_2.0.2.bb
+++ /dev/null
@@ -1,69 +0,0 @@
-# the binaries are statically linked against klibc
-SUMMARY = "Kexec tools, statically compiled against klibc"
-AUTHOR = "Eric Biederman"
-HOMEPAGE = "http://kernel.org/pub/linux/utils/kernel/kexec/"
-SECTION = "kernel/userland"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=ea5bed2f60d357618ca161ad539f7c0a \
-                    file://kexec/kexec.c;beginline=1;endline=20;md5=af10f6ae4a8715965e648aa687ad3e09"
-DEPENDS = "zlib xz"
-
-PR = "r1"
-
-inherit klibc autotools
-
-FILESPATH =. "${FILE_DIRNAME}/kexec-tools-${PV}:"
-
-SRC_URI = "${KERNELORG_MIRROR}/linux/utils/kernel/kexec/kexec-tools-${PV}.tar.gz"
-
-SRC_URI += " \
-            file://kexec-elf-rel.patch \
-            file://kexec-syscall.patch \
-            file://cflags_static.patch  \
-            file://ifdown_errno.patch  \
-            file://purgatory_flags.patch \
-            file://purgatory_string.patch \
-            file://sha256.patch \
-            file://sysconf_nrprocessors.patch \
-            file://fix-out-of-tree-build.patch \
-            file://0001-Adjust-the-order-of-headers-to-fix-build-for-musl.patch \
-            "
-
-SRC_URI[md5sum] = "92eff93b097475b7767f8c98df84408a"
-SRC_URI[sha256sum] = "09e180ff36dee087182cdc939ba6c6917b6adbb5fc12d589f31fd3659b6471f2"
-
-SRC_URI_append_arm = " file://arm_crashdump.patch"
-SRC_URI_append_powerpc = " file://ppc__lshrdi3.patch"
-SRC_URI_append_x86 = " file://x86_sys_io.patch file://x86_basename.patch file://x86_vfscanf.patch file://x86_kexec_test.patch"
-SRC_URI_append_x86-64 = " file://x86_sys_io.patch file://x86_basename.patch file://x86_vfscanf.patch file://x86_kexec_test.patch"
-
-S = "${WORKDIR}/kexec-tools-${PV}"
-
-EXTRA_OECONF += "--without-zlib --without-lzma --without-xen"
-
-CFLAGS += "-I${STAGING_DIR_HOST}${libdir}/klibc/include -I${STAGING_DIR_HOST}${libdir}/klibc/include/bits32"
-CFLAGS_x86-64 += "-I${STAGING_DIR_HOST}${libdir}/klibc/include -I${STAGING_DIR_HOST}${libdir}/klibc/include/bits64"
-
-do_compile_prepend() {
-    # Remove the prepackaged config.h from the source tree as it overrides
-    # the same file generated by configure and placed in the build tree
-    rm -f ${S}/include/config.h
-
-    # Remove the '*.d' file to make sure the recompile is OK
-    for dep in `find ${B} -type f -name '*.d'`; do
-        dep_no_d="`echo $dep | sed 's#.d$##'`"
-        # Remove file.d when there is a file.o
-        if [ -f "$dep_no_d.o" ]; then
-            rm -f $dep
-        fi
-    done
-}
-
-PACKAGES =+ "kexec-klibc kdump-klibc"
-
-FILES_kexec-klibc = "${sbindir}/kexec"
-FILES_kdump-klibc = "${sbindir}/kdump"
-
-INSANE_SKIP_${PN} = "arch"
-
-COMPATIBLE_HOST = '(x86_64.*|i.86.*|arm.*|aarch64.*|powerpc.*|mips.*)-(linux|freebsd.*)'
diff --git a/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc_git.bb b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc_git.bb
new file mode 100644
index 0000000..25f5da4
--- /dev/null
+++ b/meta-openembedded/meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc_git.bb
@@ -0,0 +1,94 @@
+# the binaries are statically linked against klibc
+SUMMARY = "Kexec tools, statically compiled against klibc"
+AUTHOR = "Eric Biederman"
+HOMEPAGE = "http://kernel.org/pub/linux/utils/kernel/kexec/"
+SECTION = "kernel/userland"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=ea5bed2f60d357618ca161ad539f7c0a \
+                    file://kexec/kexec.c;beginline=1;endline=20;md5=af10f6ae4a8715965e648aa687ad3e09"
+PV = "2.0.17+git${SRCPV}"
+
+DEPENDS = "zlib xz"
+
+inherit klibc autotools
+
+SRC_URI = "git://git.kernel.org/pub/scm/utils/kernel/kexec/kexec-tools.git"
+SRCREV = "b9de21ef51a7ceab7122a707c188602eae22c4ee"
+
+BUILD_PATCHES = "file://0001-force-static-build.patch \
+                 file://0002-Adjust-the-order-of-headers-to-fix-build-for-musl.patch"
+
+KLIBC_PATCHES += " \
+            file://0003-kexec-elf-rel-use-our-elf.h.patch \
+            file://0004-kexec-elf-exec.c-replace-with-our-err.h.patch \
+            file://0005-crashdump-elf.c-work-around-for-sysconf-_SC_NPROCESS.patch \
+            file://0006-kexec-syscall.h-work-around-missing-syscall-wrapper.patch \
+            file://0007-kexec.c-add-guard-around-ENOTSUP.patch \
+            file://0008-kexec.c-replace-mising-BLKGETSIZE64.patch \
+            file://0009-vmcore-dmesg.c-work-around-missing-imaxdiv.patch \
+            file://0010-fs2dt.c-work-around-missing-getline.patch \
+            file://0011-purgatory-Makefile-adapt-to-klcc.patch \
+            file://0012-purgatory-string.c-avoid-inclusion-of-string.h.patch \
+            file://0013-sha256.h-avoid-inclusion-of-sys-types.h.patch \
+            file://0014-add-if_nameindex-from-musl.patch \
+            file://0015-vmcore-dmesg-fix-warning.patch"
+
+WARNING_FIXES = ""
+FROM_OE_CORE = "file://arm_crashdump-fix-buffer-align.patch \
+                file://powerpc_change-the-memory-size-limit.patch \
+                file://kexec-x32.patch"
+
+SRC_URI += "${BUILD_PATCHES} ${KLIBC_PATCHES} ${WARNING_FIXES} ${FROM_OE_CORE}"
+
+SRC_URI_append_arm = " file://arm_crashdump.patch"
+
+SRC_URI_append_x86 = " file://x86_sys_io.patch file://x86_basename.patch \
+                       file://x86_vfscanf.patch file://x86_kexec_test.patch"
+
+SRC_URI_append_x86-64 = " file://x86_sys_io.patch file://x86_basename.patch \
+                          file://x86_vfscanf.patch file://x86_kexec_test.patch"
+
+SRC_URI_append_aarch64 = " file://arm64_kexec-image-header.h-add-missing-le64toh.patch \
+                           file://arm64-crashdump-arm64.c-fix-warning.patch \
+                           file://arm64_kexec-arm64.c-workaround-for-getrandom-syscall.patch"
+
+SRC_URI_append_powerpc = " file://powerpc-purgatory-Makefile-remove-unknown-flags.patch"
+
+S = "${WORKDIR}/git"
+
+EXTRA_OECONF += "--without-zlib --without-lzma --without-xen"
+
+# fix purgatory/printf.c:2:10: fatal error: limits.h: No such file or directory
+# fix include/limits.h:42:10: fatal error: bitsize/limits.h: No such file or directory
+COMMON_CFLAGS += "-O2 -I${STAGING_DIR_HOST}${libdir}/klibc/include -I${S}/purgatory/include"
+CFLAGS_x86_append = " ${COMMON_CFLAGS} -I${STAGING_DIR_HOST}${libdir}/klibc/include/bits32"
+CFLAGS_x86-64_append = " ${COMMON_CFLAGS} -I${STAGING_DIR_HOST}${libdir}/klibc/include/bits64"
+CFLAGS_arm_append = " ${COMMON_CFLAGS} -I${STAGING_DIR_HOST}${libdir}/klibc/include/bits32"
+CFLAGS_aarch64_append = "${COMMON_CFLAGS} -I${STAGING_DIR_HOST}${libdir}/klibc/include/bits64"
+CFLAGS_mips_append = " ${COMMON_CFLAGS} -I${STAGING_DIR_HOST}${libdir}/klibc/include/bits32"
+CFLAGS_mips64_append = " ${COMMON_CFLAGS} -I${STAGING_DIR_HOST}${libdir}/klibc/include/bits64"
+CFLAGS_powerpc_append = " ${COMMON_CFLAGS} -I${STAGING_DIR_HOST}${libdir}/klibc/include/bits32"
+
+do_compile_prepend() {
+    # Remove the prepackaged config.h from the source tree as it overrides
+    # the same file generated by configure and placed in the build tree
+    rm -f ${S}/include/config.h
+
+    # Remove the '*.d' file to make sure the recompile is OK
+    for dep in `find ${B} -type f -name '*.d'`; do
+        dep_no_d="`echo $dep | sed 's#.d$##'`"
+        # Remove file.d when there is a file.o
+        if [ -f "$dep_no_d.o" ]; then
+            rm -f $dep
+        fi
+    done
+}
+
+PACKAGES =+ "kexec-klibc vmcore-dmesg-klibc"
+
+FILES_kexec-klibc = "${sbindir}/kexec"
+FILES_vmcore-dmesg-klibc = "${sbindir}/vmcore-dmesg"
+
+INSANE_SKIP_${PN} = "arch"
+
+COMPATIBLE_HOST = '(x86_64.*|i.86.*|arm.*|aarch64.*|powerpc.*|mips.*)-(linux|freebsd.*)'
diff --git a/meta-openembedded/meta-multimedia/README b/meta-openembedded/meta-multimedia/README
index 20f4fb8..050392d 100644
--- a/meta-openembedded/meta-multimedia/README
+++ b/meta-openembedded/meta-multimedia/README
@@ -1,19 +1,19 @@
 This layer depends on:
 
 URI: git://github.com/openembedded/oe-core.git
-branch: master
+branch: thud
 revision: HEAD
 
 URI: git://github.com/openembedded/meta-oe.git
 layers: meta-oe
-branch: master
+branch: thud
 revision: HEAD
 
-Send pull requests to openembedded-devel@lists.openembedded.org with '[meta-multimedia]' in the subject'
+Send pull requests to openembedded-devel@lists.openembedded.org with '[meta-multimedia][thud]' in the subject'
 
 When sending single patches, please use something like:
-'git send-email -M -1 --to openembedded-devel@lists.openembedded.org --subject-prefix=meta-multimedia][PATCH
+'git send-email -M -1 --to openembedded-devel@lists.openembedded.org --subject-prefix=meta-multimedia][thud][PATCH
 
 You are encouraged to fork the mirror on github https://github.com/openembedded/meta-oe/ to share your patches, this is preferred for patch sets consisting of more than one patch. Other services like gitorious, repo.or.cz or self hosted setups are of course accepted as well, 'git fetch <remote>' works the same on all of them. We recommend github because it is free, easy to use, has been proven to be reliable and has a really good web GUI.
 
-Layer maintainer: Andreas Müller <schnitzeltony@googlemail.com>
+Thud maintainer: Armin Kuster <akuster808@gmail.com>
diff --git a/meta-openembedded/meta-multimedia/conf/layer.conf b/meta-openembedded/meta-multimedia/conf/layer.conf
index a1dfed4..e2a7701 100644
--- a/meta-openembedded/meta-multimedia/conf/layer.conf
+++ b/meta-openembedded/meta-multimedia/conf/layer.conf
@@ -27,6 +27,6 @@
 # cause compatibility issues with other layers
 LAYERVERSION_multimedia-layer = "1"
 
-LAYERDEPENDS_multimedia-layer = "core openembedded-layer"
+LAYERDEPENDS_multimedia-layer = "core"
 
-LAYERSERIES_COMPAT_multimedia-layer = "sumo"
+LAYERSERIES_COMPAT_multimedia-layer = "thud"
diff --git a/meta-openembedded/meta-multimedia/recipes-connectivity/rygel/rygel_0.34.0.bb b/meta-openembedded/meta-multimedia/recipes-connectivity/rygel/rygel_0.34.0.bb
index f13f5ce..21331ff 100644
--- a/meta-openembedded/meta-multimedia/recipes-connectivity/rygel/rygel_0.34.0.bb
+++ b/meta-openembedded/meta-multimedia/recipes-connectivity/rygel/rygel_0.34.0.bb
@@ -8,7 +8,7 @@
 LICENSE = "LGPL-2.1"
 LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
 
-DEPENDS = "libxml2 glib-2.0 gssdp gupnp gupnp-av gupnp-dlna gstreamer1.0 gstreamer1.0-plugins-base ossp-uuid libgee libsoup-2.4 libmediaart-2.0 libunistring sqlite3 intltool-native"
+DEPENDS = "libxml2 glib-2.0 gssdp gupnp gupnp-av gupnp-dlna gstreamer1.0 gstreamer1.0-plugins-base libgee libsoup-2.4 libmediaart-2.0 libunistring sqlite3 intltool-native"
 RDEPENDS_${PN} = "gstreamer1.0-plugins-base-playback shared-mime-info"
 RRECOMMENDS_${PN} = "rygel-plugin-media-export"
 
diff --git a/meta-openembedded/meta-multimedia/recipes-dvb/oscam/oscam/0001-include-sys-sysmacros.h-for-major-minor-definitions.patch b/meta-openembedded/meta-multimedia/recipes-dvb/oscam/oscam/0001-include-sys-sysmacros.h-for-major-minor-definitions.patch
new file mode 100644
index 0000000..d3d89e3
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-dvb/oscam/oscam/0001-include-sys-sysmacros.h-for-major-minor-definitions.patch
@@ -0,0 +1,26 @@
+From a372fe467495a674ad6244b67e83dfbfa8455f51 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 11 Aug 2018 13:54:32 -0700
+Subject: [PATCH] include sys/sysmacros.h for major/minor definitions
+
+csctapi/ifd_db2com.c:27: undefined reference to `minor'
+collect2: error: ld returned 1 exit status
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ globals.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/globals.h b/globals.h
+index bd12244..9e10225 100644
+--- a/globals.h
++++ b/globals.h
+@@ -36,6 +36,7 @@
+ #include <termios.h>
+ #include <inttypes.h>
+ #include <sys/utsname.h>
++#include <sys/sysmacros.h>
+ 
+ /*
+  * The following hack is taken from Linux: include/linux/kconfig.h
diff --git a/meta-openembedded/meta-multimedia/recipes-dvb/oscam/oscam/respect-cflags.patch b/meta-openembedded/meta-multimedia/recipes-dvb/oscam/oscam/respect-cflags.patch
deleted file mode 100644
index 179d04a..0000000
--- a/meta-openembedded/meta-multimedia/recipes-dvb/oscam/oscam/respect-cflags.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-Upstream-Status: Backport
-http://www.streamboard.tv/oscam/changeset/10068
-http://www.streamboard.tv/oscam/changeset/10070
-
-Index: /CMakeLists.txt
-===================================================================
---- a/CMakeLists.txt	(revision 10067)
-+++ b/CMakeLists.txt	(revision 10068)
-@@ -625,8 +625,8 @@
-     list(GET GCC_VERSION_COMPONENTS 0 GCC_MINOR)
-     add_definitions ("-W -Wall ")
--    set (CMAKE_C_FLAGS "-Wall -O2")
--	set (CMAKE_CXX_FLAGS "-Wall -O2")
--    set (CMAKE_C_FLAGS_DEBUG "-O0 -ggdb")
--    set (CMAKE_CXX_FLAGS_DEBUG "-O0 -ggdb")
-+    set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -O2")
-+	set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -O2")
-+    set (CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -O0 -ggdb")
-+    set (CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -O0 -ggdb")
- endif (CMAKE_COMPILER_IS_GNUCC)
- # some optimisations
-Index: /csctapi/CMakeLists.txt
-===================================================================
---- a/csctapi/CMakeLists.txt	(revision 10069)
-+++ b/csctapi/CMakeLists.txt	(revision 10070)
-@@ -6,8 +6,8 @@
-     list(GET GCC_VERSION_COMPONENTS 0 GCC_MINOR)
-     add_definitions ("-W -Wall ")
--    set (CMAKE_C_FLAGS "-Wall -O2")
--	set (CMAKE_CXX_FLAGS "-Wall -O2")
--    set (CMAKE_C_FLAGS_DEBUG "-O0 -ggdb")
--    set (CMAKE_CXX_FLAGS_DEBUG "-O0 -ggdb")
-+    set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -O2")
-+	set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -O2")
-+    set (CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -O0 -ggdb")
-+    set (CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -O0 -ggdb")
- endif (CMAKE_COMPILER_IS_GNUCC)
- # Mac extra removes to avoid ranlib warnings in some situations
diff --git a/meta-openembedded/meta-multimedia/recipes-dvb/oscam/oscam_svn.bb b/meta-openembedded/meta-multimedia/recipes-dvb/oscam/oscam_svn.bb
index cac517f..a8aec11 100644
--- a/meta-openembedded/meta-multimedia/recipes-dvb/oscam/oscam_svn.bb
+++ b/meta-openembedded/meta-multimedia/recipes-dvb/oscam/oscam_svn.bb
@@ -4,12 +4,12 @@
 LICENSE = "GPLv3"
 LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
 
-DEPENDS = "libusb1 openssl pcsc-lite"
+DEPENDS = "libusb1 openssl10 pcsc-lite"
 
 SRC_URI = "svn://www.streamboard.tv/svn/oscam;module=trunk;protocol=http \
-    file://respect-cflags.patch \
-"
-SRCREV = "9164"
+           file://0001-include-sys-sysmacros.h-for-major-minor-definitions.patch \
+           "
+SRCREV = "11431"
 PV = "1.10+${SRCPV}"
 
 S = "${WORKDIR}/trunk"
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/jsonschemabuilder-native.bb b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/jsonschemabuilder-native.bb
deleted file mode 100644
index fdb7699..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/jsonschemabuilder-native.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-SUMMARY = "Kodi Media Center"
-
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://JsonSchemaBuilder.cpp;beginline=2;endline=18;md5=1f67721215c03f66545390f6e45b99c7"
-
-SRCREV = "661dd08d221f5b2bf509a696a6aca5ee7d45bb27"
-
-PV = "17.1+gitr${SRCPV}"
-SRC_URI = "git://github.com/xbmc/xbmc.git;branch=Krypton"
-
-inherit autotools-brokensep gettext native
-
-S = "${WORKDIR}/git/tools/depends/native/JsonSchemaBuilder/src"
-
-do_compile_prepend() {
-    for i in $(find . -name "Makefile") ; do
-        sed -i -e 's:I/usr/include:I${STAGING_INCDIR}:g' $i
-    done
-
-    for i in $(find . -name "*.mak*" -o    -name "Makefile") ; do
-        sed -i -e 's:I/usr/include:I${STAGING_INCDIR}:g' -e 's:-rpath \$(libdir):-rpath ${libdir}:g' $i
-    done
-}
-
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0001-Fix-file_Emu-on-musl.patch b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0001-Fix-file_Emu-on-musl.patch
deleted file mode 100644
index 20b6377..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0001-Fix-file_Emu-on-musl.patch
+++ /dev/null
@@ -1,496 +0,0 @@
-From 7ae4fcf290ffb0b76374efafeaee575456ac9023 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 6 Nov 2016 23:08:27 -0800
-Subject: [PATCH 01/10] Fix file_Emu on musl
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- xbmc/cores/DllLoader/exports/emu_msvcrt.cpp        |  28 ++--
- xbmc/cores/DllLoader/exports/emu_msvcrt.h          |   2 +-
- .../DllLoader/exports/util/EmuFileWrapper.cpp      | 172 +++++++++------------
- xbmc/cores/DllLoader/exports/util/EmuFileWrapper.h |  27 ++--
- xbmc/cores/DllLoader/exports/wrapper.c             |   4 +-
- 5 files changed, 99 insertions(+), 134 deletions(-)
-
-diff --git a/xbmc/cores/DllLoader/exports/emu_msvcrt.cpp b/xbmc/cores/DllLoader/exports/emu_msvcrt.cpp
-index ab14942..a39014a 100644
---- a/xbmc/cores/DllLoader/exports/emu_msvcrt.cpp
-+++ b/xbmc/cores/DllLoader/exports/emu_msvcrt.cpp
-@@ -51,6 +51,7 @@
- #include <fcntl.h>
- #include <time.h>
- #include <signal.h>
-+#include <paths.h>
- #ifdef TARGET_POSIX
- #include "PlatformDefs.h" // for __stat64
- #include "XFileUtils.h"
-@@ -476,13 +477,10 @@ extern "C"
-     EmuFileObject* o = g_emuFileWrapper.GetFileObjectByDescriptor(fd);
-     if (o)
-     {
--      if(!o->used)
--        return NULL;
--
-       int nmode = convert_fmode(mode);
-       if( (o->mode & nmode) != nmode)
-         CLog::Log(LOGWARNING, "dll_fdopen - mode 0x%x differs from fd mode 0x%x", nmode, o->mode);
--      return &o->file_emu;
-+      return g_emuFileWrapper.GetStreamByFileObject(o);
-     }
-     else if (!IS_STD_DESCRIPTOR(fd))
-     {
-@@ -545,7 +543,7 @@ extern "C"
-         return -1;
-       }
-       object->mode = iMode;
--      return g_emuFileWrapper.GetDescriptorByStream(&object->file_emu);
-+      return g_emuFileWrapper.GetDescriptorByFileObject(object);
-     }
-     delete pFile;
-     return -1;
-@@ -1214,8 +1212,8 @@ extern "C"
-   {
-     FILE* file = NULL;
- #if defined(TARGET_LINUX) && !defined(TARGET_ANDROID)
--    if (strcmp(filename, MOUNTED) == 0
--    ||  strcmp(filename, MNTTAB) == 0)
-+    if (strcmp(filename, _PATH_MOUNTED) == 0
-+    ||  strcmp(filename, _PATH_MNTTAB) == 0)
-     {
-       CLog::Log(LOGINFO, "%s - something opened the mount file, let's hope it knows what it's doing", __FUNCTION__);
-       return fopen(filename, mode);
-@@ -1622,7 +1620,7 @@ extern "C"
-     int ret;
- 
-     ret = dll_fgetpos64(stream, &tmpPos);
--#if !defined(TARGET_POSIX) || defined(TARGET_DARWIN) || defined(TARGET_FREEBSD) || defined(TARGET_ANDROID)
-+#if !defined(__GLIBC__) || defined(TARGET_DARWIN) || defined(TARGET_FREEBSD) || defined(TARGET_ANDROID)
-     *pos = (fpos_t)tmpPos;
- #else
-     pos->__pos = (off_t)tmpPos.__pos;
-@@ -1635,8 +1633,9 @@ extern "C"
-     CFile* pFile = g_emuFileWrapper.GetFileXbmcByStream(stream);
-     if (pFile != NULL)
-     {
--#if !defined(TARGET_POSIX) || defined(TARGET_DARWIN) || defined(TARGET_FREEBSD) || defined(TARGET_ANDROID)
--      *pos = pFile->GetPosition();
-+#if !defined(__GLIBC__) || defined(TARGET_DARWIN) || defined(TARGET_FREEBSD) || defined(TARGET_ANDROID)
-+      uint64_t *ppos = (uint64_t *) pos;
-+      *ppos = pFile->GetPosition();
- #else
-       pos->__pos = pFile->GetPosition();
- #endif
-@@ -1657,8 +1656,9 @@ extern "C"
-     int fd = g_emuFileWrapper.GetDescriptorByStream(stream);
-     if (fd >= 0)
-     {
--#if !defined(TARGET_POSIX) || defined(TARGET_DARWIN) || defined(TARGET_FREEBSD) || defined(TARGET_ANDROID)
--      if (dll_lseeki64(fd, *pos, SEEK_SET) >= 0)
-+#if !defined(__GLIBC__) || defined(TARGET_DARWIN) || defined(TARGET_FREEBSD) || defined(TARGET_ANDROID)
-+      const uint64_t *ppos = (const uint64_t *) pos;
-+      if (dll_lseeki64(fd, *ppos, SEEK_SET) >= 0)
- #else
-       if (dll_lseeki64(fd, (__off64_t)pos->__pos, SEEK_SET) >= 0)
- #endif
-@@ -1674,7 +1674,7 @@ extern "C"
-     {
-       // it might be something else than a file, or the file is not emulated
-       // let the operating system handle it
--#if !defined(TARGET_POSIX) || defined(TARGET_DARWIN) || defined(TARGET_FREEBSD) || defined(TARGET_ANDROID)
-+#if !defined(__GLIBC__) || defined(TARGET_DARWIN) || defined(TARGET_FREEBSD) || defined(TARGET_ANDROID)
-       return fsetpos(stream, pos);
- #else
-       return fsetpos64(stream, pos);
-@@ -1690,7 +1690,7 @@ extern "C"
-     if (fd >= 0)
-     {
-       fpos64_t tmpPos;
--#if !defined(TARGET_POSIX) || defined(TARGET_DARWIN) || defined(TARGET_FREEBSD) || defined(TARGET_ANDROID)
-+#if !defined(__GLIBC__) || defined(TARGET_DARWIN) || defined(TARGET_FREEBSD) || defined(TARGET_ANDROID)
-       tmpPos= *pos;
- #else
-       tmpPos.__pos = (off64_t)(pos->__pos);
-diff --git a/xbmc/cores/DllLoader/exports/emu_msvcrt.h b/xbmc/cores/DllLoader/exports/emu_msvcrt.h
-index 3294d9a..c7c483f 100644
---- a/xbmc/cores/DllLoader/exports/emu_msvcrt.h
-+++ b/xbmc/cores/DllLoader/exports/emu_msvcrt.h
-@@ -24,7 +24,7 @@
- #define _onexit_t void*
- #endif
- 
--#if defined(TARGET_DARWIN) || defined(TARGET_FREEBSD) || defined(TARGET_ANDROID)
-+#if defined(TARGET_DARWIN) || defined(TARGET_FREEBSD) || defined(TARGET_ANDROID) || !defined(__GLIBC__)
- typedef off_t __off_t;
- typedef int64_t off64_t;
- typedef off64_t __off64_t;
-diff --git a/xbmc/cores/DllLoader/exports/util/EmuFileWrapper.cpp b/xbmc/cores/DllLoader/exports/util/EmuFileWrapper.cpp
-index 8927d41..e9a2ab0 100644
---- a/xbmc/cores/DllLoader/exports/util/EmuFileWrapper.cpp
-+++ b/xbmc/cores/DllLoader/exports/util/EmuFileWrapper.cpp
-@@ -52,16 +52,7 @@ constexpr bool isValidFilePtr(FILE* f)
- }
- CEmuFileWrapper::CEmuFileWrapper()
- {
--  // since we always use dlls we might just initialize it directly
--  for (int i = 0; i < MAX_EMULATED_FILES; i++)
--  {
--    memset(&m_files[i], 0, sizeof(EmuFileObject));
--    m_files[i].used = false;
--#if defined(TARGET_WINDOWS) && (_MSC_VER >= 1900)
--    m_files[i].file_emu._Placeholder = new kodi_iobuf();
--#endif
--    FileDescriptor(m_files[i].file_emu)->_file = -1;
--  }
-+  memset(m_files, 0, sizeof(m_files));
- }
- 
- CEmuFileWrapper::~CEmuFileWrapper()
-@@ -73,29 +64,7 @@ void CEmuFileWrapper::CleanUp()
- {
-   CSingleLock lock(m_criticalSection);
-   for (int i = 0; i < MAX_EMULATED_FILES; i++)
--  {
--    if (m_files[i].used)
--    {
--      m_files[i].file_xbmc->Close();
--      delete m_files[i].file_xbmc;
--
--      if (m_files[i].file_lock)
--      {
--        delete m_files[i].file_lock;
--        m_files[i].file_lock = nullptr;
--      }
--#if !defined(TARGET_WINDOWS)
--      //Don't memset on Windows as it overwrites our pointer
--      memset(&m_files[i], 0, sizeof(EmuFileObject));
--#endif
--      m_files[i].used = false;
--      FileDescriptor(m_files[i].file_emu)->_file = -1;
--    }
--#if defined(TARGET_WINDOWS) && (_MSC_VER >= 1900)
--    delete static_cast<kodi_iobuf*>(m_files[i].file_emu._Placeholder);
--    m_files[i].file_emu._Placeholder = nullptr;
--#endif
--  }
-+    UnRegisterFileObject(&m_files[i], true);
- }
- 
- EmuFileObject* CEmuFileWrapper::RegisterFileObject(XFILE::CFile* pFile)
-@@ -106,13 +75,11 @@ EmuFileObject* CEmuFileWrapper::RegisterFileObject(XFILE::CFile* pFile)
- 
-   for (int i = 0; i < MAX_EMULATED_FILES; i++)
-   {
--    if (!m_files[i].used)
-+    if (!m_files[i].file_xbmc)
-     {
-       // found a free location
-       object = &m_files[i];
--      object->used = true;
-       object->file_xbmc = pFile;
--      FileDescriptor(object->file_emu)->_file = (i + FILE_WRAPPER_OFFSET);
-       object->file_lock = new CCriticalSection();
-       break;
-     }
-@@ -121,82 +88,74 @@ EmuFileObject* CEmuFileWrapper::RegisterFileObject(XFILE::CFile* pFile)
-   return object;
- }
- 
--void CEmuFileWrapper::UnRegisterFileObjectByDescriptor(int fd)
-+void CEmuFileWrapper::UnRegisterFileObject(EmuFileObject *object, bool free_file)
-+
- {
--  int i = fd - FILE_WRAPPER_OFFSET;
--  if (! (i >= 0 && i < MAX_EMULATED_FILES))
--    return;
-+  if (object && object->file_xbmc)
-+  {
-+    if (object->file_xbmc && free_file)
-+    {
-+      object->file_xbmc->Close();
-+      delete object->file_xbmc;
-+    }
-+    if (object->file_lock)
-+    {
-+      delete object->file_lock;
-+    }
- 
--  if (!m_files[i].used)
--    return;
-+    memset(object, 0, sizeof(*object));
-+   }
-+}
- 
-+void CEmuFileWrapper::UnRegisterFileObjectByDescriptor(int fd)
-+{
-   CSingleLock lock(m_criticalSection);
--
--  // we assume the emulated function alreay deleted the CFile object
--  if (m_files[i].file_lock)
--  {
--    delete m_files[i].file_lock;
--    m_files[i].file_lock = nullptr;
--  }
--#if !defined(TARGET_WINDOWS)
--  //Don't memset on Windows as it overwrites our pointer
--  memset(&m_files[i], 0, sizeof(EmuFileObject));
--#endif
--  m_files[i].used = false;
--  FileDescriptor(m_files[i].file_emu)->_file = -1;
-+  UnRegisterFileObject(GetFileObjectByDescriptor(fd), false);
- }
- 
- void CEmuFileWrapper::UnRegisterFileObjectByStream(FILE* stream)
- {
-   if (isValidFilePtr(stream))
-   {
--    return UnRegisterFileObjectByDescriptor(FileDescriptor(*stream)->_file);
-+    CSingleLock lock(m_criticalSection);
-+    UnRegisterFileObject(GetFileObjectByStream(stream), false);
-   }
- }
- 
- void CEmuFileWrapper::LockFileObjectByDescriptor(int fd)
- {
--  int i = fd - FILE_WRAPPER_OFFSET;
--  if (i >= 0 && i < MAX_EMULATED_FILES)
-+  EmuFileObject* object = GetFileObjectByDescriptor(fd);
-+  if (object && object->file_xbmc)
-   {
--    if (m_files[i].used)
--    {
--      m_files[i].file_lock->lock();
--    }
-+    object->file_lock->lock();
-   }
- }
- 
- bool CEmuFileWrapper::TryLockFileObjectByDescriptor(int fd)
- {
--  int i = fd - FILE_WRAPPER_OFFSET;
--  if (i >= 0 && i < MAX_EMULATED_FILES)
-+  EmuFileObject* object = GetFileObjectByDescriptor(fd);
-+  if (object && object->file_xbmc)
-   {
--    if (m_files[i].used)
--    {
--      return m_files[i].file_lock->try_lock();
--    }
-+    return object->file_lock->try_lock();
-   }
-   return false;
- }
- 
- void CEmuFileWrapper::UnlockFileObjectByDescriptor(int fd)
- {
--  int i = fd - FILE_WRAPPER_OFFSET;
--  if (i >= 0 && i < MAX_EMULATED_FILES)
-+  EmuFileObject* object = GetFileObjectByDescriptor(fd);
-+  if (object && object->file_xbmc)
-   {
--    if (m_files[i].used)
--    {
--      m_files[i].file_lock->unlock();
--    }
-+    object->file_lock->unlock();
-   }
- }
- 
- EmuFileObject* CEmuFileWrapper::GetFileObjectByDescriptor(int fd)
- {
--  int i = fd - FILE_WRAPPER_OFFSET;
-+  int i = fd - 0x7000000;
-   if (i >= 0 && i < MAX_EMULATED_FILES)
-   {
--    if (m_files[i].used)
-+    if (m_files[i].file_xbmc)
-     {
-       return &m_files[i];
-     }
-@@ -204,20 +163,39 @@ EmuFileObject* CEmuFileWrapper::GetFileObjectByDescriptor(int fd)
-   return nullptr;
- }
- 
-+int CEmuFileWrapper::GetDescriptorByFileObject(EmuFileObject *object)
-+{
-+  int i = object - m_files;
-+  if (i >= 0 && i < MAX_EMULATED_FILES)
-+  {
-+    return 0x7000000 + i;
-+  }
-+
-+  return -1;
-+}
-+
- EmuFileObject* CEmuFileWrapper::GetFileObjectByStream(FILE* stream)
- {
--  if (isValidFilePtr(stream))
-+  EmuFileObject *object = (EmuFileObject*) stream;
-+  if (object >= &m_files[0] || object < &m_files[MAX_EMULATED_FILES])
-   {
--    return GetFileObjectByDescriptor(FileDescriptor(*stream)->_file);
-+    if (object->file_xbmc)
-+    {
-+      return object;
-+    }
-   }
-+  return NULL;
-+}
- 
--  return nullptr;
-+FILE* CEmuFileWrapper::GetStreamByFileObject(EmuFileObject *object)
-+{
-+  return (FILE*) object;
- }
- 
- XFILE::CFile* CEmuFileWrapper::GetFileXbmcByDescriptor(int fd)
- {
-   auto object = GetFileObjectByDescriptor(fd);
--  if (object != nullptr && object->used)
-+  if (object != nullptr)
-   {
-     return object->file_xbmc;
-   }
-@@ -228,8 +206,9 @@ XFILE::CFile* CEmuFileWrapper::GetFileXbmcByStream(FILE* stream)
- {
-   if (isValidFilePtr(stream))
-   {
--    auto object = GetFileObjectByDescriptor(FileDescriptor(*stream)->_file);
--    if (object != nullptr && object->used)
-+    EmuFileObject* object = GetFileObjectByStream(stream);
-+    if (object != NULL)
-+
-     {
-       return object->file_xbmc;
-     }
-@@ -239,32 +218,21 @@ XFILE::CFile* CEmuFileWrapper::GetFileXbmcByStream(FILE* stream)
- 
- int CEmuFileWrapper::GetDescriptorByStream(FILE* stream)
- {
--  if (isValidFilePtr(stream))
--  {
--    int i = FileDescriptor(*stream)->_file - FILE_WRAPPER_OFFSET;
--    if (i >= 0 && i < MAX_EMULATED_FILES)
--    {
--      return i + FILE_WRAPPER_OFFSET;
--    }
--  }
--  return -1;
-+  return GetDescriptorByFileObject(GetFileObjectByStream(stream));
- }
- 
- FILE* CEmuFileWrapper::GetStreamByDescriptor(int fd)
- {
--  auto object = GetFileObjectByDescriptor(fd);
--  if (object != nullptr && object->used)
--  {
--    return &object->file_emu;
--  }
--  return nullptr;
-+  return GetStreamByFileObject(GetFileObjectByDescriptor(fd));
-+}
-+
-+bool CEmuFileWrapper::DescriptorIsEmulatedFile(int fd)
-+{
-+  return GetFileObjectByDescriptor(fd) != NULL;
- }
- 
- bool CEmuFileWrapper::StreamIsEmulatedFile(FILE* stream)
- {
--  if (isValidFilePtr(stream))
--  {
--    return DescriptorIsEmulatedFile(FileDescriptor(*stream)->_file);
--  }
--  return false;
-+  return GetFileObjectByStream(stream) != NULL;
- }
-+
-diff --git a/xbmc/cores/DllLoader/exports/util/EmuFileWrapper.h b/xbmc/cores/DllLoader/exports/util/EmuFileWrapper.h
-index 786fa85..311a5cf 100644
---- a/xbmc/cores/DllLoader/exports/util/EmuFileWrapper.h
-+++ b/xbmc/cores/DllLoader/exports/util/EmuFileWrapper.h
-@@ -25,14 +25,14 @@
- #include "system.h"
- #include "threads/CriticalSection.h"
- 
--#if defined(TARGET_POSIX) && !defined(TARGET_DARWIN) && !defined(TARGET_FREEBSD) && !defined(TARGET_ANDROID) && !defined(__UCLIBC__)
--#define _file _fileno
--#elif defined(__UCLIBC__)
--#define _file __filedes
--#endif
-+//#if defined(TARGET_POSIX) && !defined(TARGET_DARWIN) && !defined(TARGET_FREEBSD) && !defined(TARGET_ANDROID) && !defined(__UCLIBC__)
-+//#define _file _fileno
-+//#elif defined(__UCLIBC__)
-+//#define _file __filedes
-+//#endif
- 
- #define MAX_EMULATED_FILES    50
--#define FILE_WRAPPER_OFFSET   0x00000200
-+//#define FILE_WRAPPER_OFFSET   0x00000200
- 
- namespace XFILE
- {
-@@ -47,12 +47,9 @@ struct kodi_iobuf {
- 
- typedef struct stEmuFileObject
- {
--  FILE    file_emu;
-   XFILE::CFile*  file_xbmc;
-   CCriticalSection *file_lock;
-   int mode;
--  //Stick this last to avoid 3-7 bytes of padding
--  bool    used;
- } EmuFileObject;
- 
- class CEmuFileWrapper
-@@ -67,22 +64,22 @@ public:
-   void CleanUp();
- 
-   EmuFileObject* RegisterFileObject(XFILE::CFile* pFile);
-+  void UnRegisterFileObject(EmuFileObject*, bool free_file);
-   void UnRegisterFileObjectByDescriptor(int fd);
-   void UnRegisterFileObjectByStream(FILE* stream);
-   void LockFileObjectByDescriptor(int fd);
-   bool TryLockFileObjectByDescriptor(int fd);
-   void UnlockFileObjectByDescriptor(int fd);
-   EmuFileObject* GetFileObjectByDescriptor(int fd);
-+  int GetDescriptorByFileObject(EmuFileObject*);
-   EmuFileObject* GetFileObjectByStream(FILE* stream);
-+  FILE* GetStreamByFileObject(EmuFileObject*);
-   XFILE::CFile* GetFileXbmcByDescriptor(int fd);
-   XFILE::CFile* GetFileXbmcByStream(FILE* stream);
--  static int GetDescriptorByStream(FILE* stream);
-+  int GetDescriptorByStream(FILE* stream);
-   FILE* GetStreamByDescriptor(int fd);
--  static constexpr bool DescriptorIsEmulatedFile(int fd)
--  {
--    return fd >= FILE_WRAPPER_OFFSET && fd < FILE_WRAPPER_OFFSET + MAX_EMULATED_FILES;
--  }
--  static bool StreamIsEmulatedFile(FILE* stream);
-+  bool DescriptorIsEmulatedFile(int fd);
-+  bool StreamIsEmulatedFile(FILE* stream);
- private:
-   EmuFileObject m_files[MAX_EMULATED_FILES];
-   CCriticalSection m_criticalSection;
-diff --git a/xbmc/cores/DllLoader/exports/wrapper.c b/xbmc/cores/DllLoader/exports/wrapper.c
-index e363662..07825f3 100644
---- a/xbmc/cores/DllLoader/exports/wrapper.c
-+++ b/xbmc/cores/DllLoader/exports/wrapper.c
-@@ -39,13 +39,13 @@
- #endif
- #include <dlfcn.h>
- 
--#if defined(TARGET_DARWIN) || defined(TARGET_FREEBSD) || defined(TARGET_ANDROID)
-+#if defined(TARGET_DARWIN) || defined(TARGET_FREEBSD) || defined(TARGET_ANDROID) || !defined(__GLIBC__)
- typedef off_t     __off_t;
- typedef int64_t   off64_t;
- typedef off64_t   __off64_t;
- typedef fpos_t    fpos64_t;
- #define stat64    stat
--#if defined(TARGET_DARWIN) || defined(TARGET_ANDROID)
-+#if defined(TARGET_DARWIN) || defined(TARGET_ANDROID) || !defined(__GLIBC__)
- #define _G_va_list va_list
- #endif
- #endif
--- 
-2.10.2
-
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0001-change-order-of-detecting-libegl-and-libgles2.patch b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0001-change-order-of-detecting-libegl-and-libgles2.patch
deleted file mode 100644
index 12a6c06..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0001-change-order-of-detecting-libegl-and-libgles2.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From 21524598110e7a55113205dda4bc1a6d5987111c Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 9 May 2017 06:41:33 +0000
-Subject: [PATCH] change order of detecting libegl and libgles2
-
-This actually helps building it on rpi/userland
-where libEGL depends on few functions from libGLESv2
-see
-https://www.raspberrypi.org/forums/viewtopic.php?t=7090
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- configure.ac | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/configure.ac b/configure.ac
-index b9e4240..1ca0297 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -951,8 +951,8 @@ if test "$use_gles" = "yes"; then
-       AC_MSG_RESULT(== WARNING: OpenGLES support is assumed.)
-       LIBS="$LIBS -lEGL -lGLESv2 -lbcm_host -lvcos -lvchiq_arm -lmmal -lmmal_core -lmmal_util -lvcsm"
-     else
--      AC_CHECK_LIB([EGL],   [main],, AC_MSG_ERROR($missing_library))
-       AC_CHECK_LIB([GLESv2],[main],, AC_MSG_ERROR($missing_library))
-+      AC_CHECK_LIB([EGL],   [main],, AC_MSG_ERROR($missing_library))
-     fi
-   fi
- else
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0002-Remove-FILEWRAP.patch b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0002-Remove-FILEWRAP.patch
deleted file mode 100644
index 463a5c4..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0002-Remove-FILEWRAP.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-From ad1977a358319093b305df6d84be6db676ef1e4a Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 6 Nov 2016 22:35:16 -0800
-Subject: [PATCH 02/10] Remove FILEWRAP
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- xbmc/utils/posix/PosixInterfaceForCLog.cpp | 6 +-----
- xbmc/utils/posix/PosixInterfaceForCLog.h   | 4 +---
- 2 files changed, 2 insertions(+), 8 deletions(-)
-
-Index: git/xbmc/utils/posix/PosixInterfaceForCLog.cpp
-===================================================================
---- git.orig/xbmc/utils/posix/PosixInterfaceForCLog.cpp
-+++ git/xbmc/utils/posix/PosixInterfaceForCLog.cpp
-@@ -29,10 +29,6 @@
- #include "platform/android/activity/XBMCApp.h"
- #endif // TARGET_ANDROID
- 
--struct FILEWRAP : public FILE
--{};
--
--
- CPosixInterfaceForCLog::CPosixInterfaceForCLog() :
-   m_file(NULL)
- { }
-@@ -52,7 +48,7 @@ bool CPosixInterfaceForCLog::OpenLogFile
-   (void)remove(backupOldLogToFilename.c_str()); // if it's failed, try to continue
-   (void)rename(logFilename.c_str(), backupOldLogToFilename.c_str()); // if it's failed, try to continue
- 
--  m_file = (FILEWRAP*)fopen(logFilename.c_str(), "wb");
-+  m_file = fopen(logFilename.c_str(), "wb");
-   if (!m_file)
-     return false; // error, can't open log file
- 
-Index: git/xbmc/utils/posix/PosixInterfaceForCLog.h
-===================================================================
---- git.orig/xbmc/utils/posix/PosixInterfaceForCLog.h
-+++ git/xbmc/utils/posix/PosixInterfaceForCLog.h
-@@ -34,5 +34,5 @@ public:
-   void PrintDebugString(const std::string& debugString);
-   static void GetCurrentLocalTime(int& hour, int& minute, int& second, double& millisecond);
- private:
--  FILEWRAP* m_file;
-+  FILE* m_file;
- };
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0003-configure-don-t-try-to-run-stuff-to-find-tinyxml.patch b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0003-configure-don-t-try-to-run-stuff-to-find-tinyxml.patch
deleted file mode 100644
index 49217a4..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0003-configure-don-t-try-to-run-stuff-to-find-tinyxml.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From a91a3ba229dc5903935f7dd98dd03bbb4fe5ac1f Mon Sep 17 00:00:00 2001
-From: Koen Kooi <koen@dominion.thruhere.net>
-Date: Sat, 6 Feb 2016 15:43:01 +0100
-Subject: [PATCH 03/10] configure: don't try to run stuff to find tinyxml
-
----
- configure.ac | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/configure.ac b/configure.ac
-index 34fe643..3132dc1 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -1043,7 +1043,7 @@ fi
- AC_LANG_PUSH([C++])
- PKG_CHECK_MODULES([TINYXML], [tinyxml >= 2.6.2],
-   [INCLUDES="$INCLUDES $TINYXML_CFLAGS"; LIBS="$LIBS $TINYXML_LIBS"],
--  [AC_RUN_IFELSE(
-+  [AC_COMPILE_IFELSE(
-    [AC_LANG_SOURCE([[
- #include <stdlib.h>
- #include <tinyxml.h>
--- 
-2.10.2
-
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0004-handle-SIGTERM.patch b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0004-handle-SIGTERM.patch
deleted file mode 100644
index dc37439..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0004-handle-SIGTERM.patch
+++ /dev/null
@@ -1,163 +0,0 @@
-From 49046c1685465a5486fe9e1c04b99c585aab6862 Mon Sep 17 00:00:00 2001
-From: Stefan Saraev <stefan@saraev.ca>
-Date: Wed, 2 Nov 2016 11:28:34 -0700
-Subject: [PATCH 04/10] handle SIGTERM
-
-0. CApplication::Stop cant be trusted. (deadlocks crashes and boo)
-
-so, when shutdown/reboot is requested:
-
-1. save an exit code (for CEC...)
-2. call CPowerManager::{Reboot,PowerDown}
-3. ... then systemd sends TERM and waits xx seconds before sending KILL
-4. CApplication::Stop has xx seconds to save guisettings.xml and boo
-5. CEC thread has xx seconds to switch off after it received OnQuit
-6. addons / pvrmanager / cec / everything else.. are free to deadlock / crash now, we dont care
-7. KILL
-
-Signed-off-by: Stefan Saraev <stefan@saraev.ca>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- xbmc/Application.cpp         | 17 ++++++++++++-----
- xbmc/Application.h           |  1 +
- xbmc/XBApplicationEx.cpp     |  1 +
- xbmc/XBApplicationEx.h       |  1 +
- xbmc/platform/posix/main.cpp | 15 +++++++++++++++
- 5 files changed, 30 insertions(+), 5 deletions(-)
-
-diff --git a/xbmc/Application.cpp b/xbmc/Application.cpp
-index 100a2f2..fda892d 100644
---- a/xbmc/Application.cpp
-+++ b/xbmc/Application.cpp
-@@ -2426,12 +2426,12 @@ void CApplication::OnApplicationMessage(ThreadMessage* pMsg)
-   switch (pMsg->dwMessage)
-   {
-   case TMSG_POWERDOWN:
--    Stop(EXITCODE_POWERDOWN);
-+    SetExitCode(EXITCODE_POWERDOWN);
-     g_powerManager.Powerdown();
-     break;
- 
-   case TMSG_QUIT:
--    Stop(EXITCODE_QUIT);
-+    SetExitCode(EXITCODE_QUIT);
-     break;
-   
-   case TMSG_SHUTDOWN:
-@@ -2452,12 +2452,13 @@ void CApplication::OnApplicationMessage(ThreadMessage* pMsg)
- 
-   case TMSG_RESTART:
-   case TMSG_RESET:
--    Stop(EXITCODE_REBOOT);
-+    SetExitCode(EXITCODE_REBOOT);
-     g_powerManager.Reboot();
-     break;
- 
-   case TMSG_RESTARTAPP:
- #if defined(TARGET_WINDOWS) || defined(TARGET_LINUX)
-+    SetExitCode(EXITCODE_RESTARTAPP);
-     Stop(EXITCODE_RESTARTAPP);
- #endif
-     break;
-@@ -2881,6 +2882,13 @@ bool CApplication::Cleanup()
-   }
- }
- 
-+void CApplication::SetExitCode(int exitCode)
-+{
-+  // save it for CEC
-+  m_ExitCode = exitCode;
-+  m_ExitCodeSet = true;
-+}
-+
- void CApplication::Stop(int exitCode)
- {
-   try
-@@ -2888,7 +2896,7 @@ void CApplication::Stop(int exitCode)
-     m_frameMoveGuard.unlock();
- 
-     CVariant vExitCode(CVariant::VariantTypeObject);
--    vExitCode["exitcode"] = exitCode;
-+    vExitCode["exitcode"] = m_ExitCode;
-     CAnnouncementManager::GetInstance().Announce(System, "xbmc", "OnQuit", vExitCode);
- 
-     // Abort any active screensaver
-@@ -2922,7 +2930,6 @@ void CApplication::Stop(int exitCode)
- 
-     m_bStop = true;
-     m_AppFocused = false;
--    m_ExitCode = exitCode;
-     CLog::Log(LOGNOTICE, "stop all");
- 
-     // cancel any jobs from the jobmanager
-diff --git a/xbmc/Application.h b/xbmc/Application.h
-index a9d9bf5..e536deb 100644
---- a/xbmc/Application.h
-+++ b/xbmc/Application.h
-@@ -159,6 +159,7 @@ public:
-   void StopPVRManager();
-   void ReinitPVRManager();
-   bool IsCurrentThread() const;
-+  void SetExitCode(int exitCode);
-   void Stop(int exitCode);
-   void RestartApp();
-   void UnloadSkin(bool forReload = false);
-diff --git a/xbmc/XBApplicationEx.cpp b/xbmc/XBApplicationEx.cpp
-index 035aed2..34102f5 100644
---- a/xbmc/XBApplicationEx.cpp
-+++ b/xbmc/XBApplicationEx.cpp
-@@ -46,6 +46,7 @@ CXBApplicationEx::CXBApplicationEx()
-   m_bStop = false;
-   m_AppFocused = true;
-   m_ExitCode = EXITCODE_QUIT;
-+  m_ExitCodeSet = false;
-   m_renderGUI = false;
- }
- 
-diff --git a/xbmc/XBApplicationEx.h b/xbmc/XBApplicationEx.h
-index 9bc14fa..f696b89 100644
---- a/xbmc/XBApplicationEx.h
-+++ b/xbmc/XBApplicationEx.h
-@@ -42,6 +42,7 @@ public:
-   // Variables for timing
-   bool m_bStop;
-   int  m_ExitCode;
-+  bool m_ExitCodeSet;
-   bool m_AppFocused;
-   bool m_renderGUI;
- 
-diff --git a/xbmc/platform/posix/main.cpp b/xbmc/platform/posix/main.cpp
-index a8b64e5..3d80032 100644
---- a/xbmc/platform/posix/main.cpp
-+++ b/xbmc/platform/posix/main.cpp
-@@ -41,12 +41,27 @@
- #include "input/linux/LIRC.h"
- #endif
- #include "platform/XbmcContext.h"
-+#include "Application.h"
-+
-+void xbmc_term_handler(int signum)
-+{
-+  CLog::Log(LOGINFO, "Received SIGTERM...");
-+  if (!g_application.m_ExitCodeSet)
-+    g_application.SetExitCode(EXITCODE_RESTARTAPP);
-+  g_application.Stop(EXITCODE_RESTARTAPP);
-+}
- 
- #ifdef __cplusplus
- extern "C"
- #endif
- int main(int argc, char* argv[])
- {
-+  // SIGTERM handler
-+  struct sigaction action;
-+  memset(&action, 0, sizeof(struct sigaction));
-+  action.sa_handler = xbmc_term_handler;
-+  sigaction(SIGTERM, &action, NULL);
-+
-   // set up some xbmc specific relationships
-   XBMC::Context context;
- 
--- 
-2.10.2
-
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0005-add-support-to-read-frequency-output-if-using-intel-.patch b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0005-add-support-to-read-frequency-output-if-using-intel-.patch
deleted file mode 100644
index ee10c40..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0005-add-support-to-read-frequency-output-if-using-intel-.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-From 4d1368d20f04216aec9551d9845b305f96a21015 Mon Sep 17 00:00:00 2001
-From: Stephan Raue <stephan@openelec.tv>
-Date: Mon, 1 Sep 2014 03:16:37 +0200
-Subject: [PATCH 05/10] add support to read frequency output if using intel's
- pstate driver
-
----
- xbmc/utils/CPUInfo.cpp | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/xbmc/utils/CPUInfo.cpp b/xbmc/utils/CPUInfo.cpp
-index 5e2ebbd..fd04d5a 100644
---- a/xbmc/utils/CPUInfo.cpp
-+++ b/xbmc/utils/CPUInfo.cpp
-@@ -274,6 +274,8 @@ CCPUInfo::CCPUInfo(void)
-     m_fProcTemperature = fopen("/sys/class/thermal/thermal_zone0/temp", "r");  // On Raspberry PIs
- 
-   m_fCPUFreq = fopen ("/sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq", "r");
-+  if (m_fCPUFreq == NULL)
-+    m_fCPUFreq = fopen ("/sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_cur_freq", "r");
-   if (!m_fCPUFreq)
-   {
-     m_cpuInfoForFreq = true;
--- 
-2.10.2
-
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0006-Disable-DVD-support.patch b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0006-Disable-DVD-support.patch
deleted file mode 100644
index 08dfac3..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0006-Disable-DVD-support.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From 3d3ec391038c6ee73897a7fab753b11b589de1ed Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 2 Nov 2016 12:39:20 -0700
-Subject: [PATCH 06/10] Disable DVD support
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- Makefile.in | 4 +---
- 1 file changed, 1 insertion(+), 3 deletions(-)
-
-diff --git a/Makefile.in b/Makefile.in
-index 0d70e9b..050c7ca 100644
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -10,8 +10,7 @@ EC_DIRS= \
- 	tools/EventClients
- 
- DVDPCODECS_DIRS= \
--	lib \
--	lib/libdvd
-+	lib
- 
- VideoPlayer_ARCHIVES=xbmc/cores/VideoPlayer/VideoPlayer.a \
-                    xbmc/cores/VideoPlayer/DVDCodecs/DVDCodecs.a \
-@@ -347,7 +346,6 @@ libaddon: exports
- 	$(MAKE) -C lib/addons/library.xbmc.pvr
- 	$(MAKE) -C lib/addons/library.kodi.inputstream
- dvdpcodecs: dllloader
--	$(MAKE) -C lib/libdvd
- 
- dvdpextcodecs:
- 
--- 
-2.10.2
-
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0007-Always-compile-libcpluff-as-PIC.patch b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0007-Always-compile-libcpluff-as-PIC.patch
deleted file mode 100644
index 8fd7ece..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0007-Always-compile-libcpluff-as-PIC.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From d989cbdb7686c3b95dc749967f89b93e47f955a6 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 3 Nov 2016 13:10:00 -0700
-Subject: [PATCH 07/10] Always compile libcpluff as PIC
-
-Fixes errors e.g.
-
-ld: lib/cpluff/libcpluff/.libs/libcpluff.a(pcontrol.o): relocation R_X86_64_PC32 against symbol `cp_stop_plugins' can not be used when making a shared object; recompile with -fPIC
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- configure.ac | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/configure.ac b/configure.ac
-index 3132dc1..ab4eea3 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -2385,7 +2385,7 @@ XB_CONFIG_MODULE([lib/cpluff], [
-     --prefix="${prefix}" --includedir="${includedir}" --libdir="${libdir}" --datadir="${datadir}" \
-     --host=$host_alias \
-     --build=$build_alias \
--    --target=$target_alias CFLAGS="$CFLAGS" CC="$CC" CXX="$CXX" LDFLAGS="$LDFLAGS" LIBS=""
-+    --target=$target_alias --with-pic=yes CFLAGS="$CFLAGS" CC="$CC" CXX="$CXX" LDFLAGS="$LDFLAGS" LIBS=""
-     #LDFLAGS="$LDFLAGS -Wl,-read_only_relocs,suppress"
- ], [0])
- 
--- 
-2.10.2
-
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0008-kodi-config.cmake-use-CMAKE_FIND_ROOT_PATH-to-fix-cr.patch b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0008-kodi-config.cmake-use-CMAKE_FIND_ROOT_PATH-to-fix-cr.patch
deleted file mode 100644
index 9390144..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0008-kodi-config.cmake-use-CMAKE_FIND_ROOT_PATH-to-fix-cr.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 51cd8d5f084013360b29fe497193288ebde2f4f9 Mon Sep 17 00:00:00 2001
-From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
-Date: Wed, 29 Jul 2015 23:13:33 +0200
-Subject: [PATCH 08/10] kodi-config.cmake: use CMAKE_FIND_ROOT_PATH to fix
- cross-compilation
-
-When cross-compiling, the location at build time of the libraries is
-not the same as the one at run-time. The CMAKE_FIND_ROOT_PATH variable
-is here to handle this difference, so use it in kodi-config.cmake.
-
-Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
----
- project/cmake/KodiConfig.cmake.in | 5 +++--
- 1 file changed, 3 insertions(+), 2 deletions(-)
-
-diff --git a/project/cmake/KodiConfig.cmake.in b/project/cmake/KodiConfig.cmake.in
-index c02a680..9d6a566 100644
---- a/project/cmake/KodiConfig.cmake.in
-+++ b/project/cmake/KodiConfig.cmake.in
-@@ -7,10 +7,10 @@ if(NOT @APP_NAME_UC@_PREFIX)
-   set(@APP_NAME_UC@_PREFIX @APP_PREFIX@)
- endif()
- if(NOT @APP_NAME_UC@_INCLUDE_DIR)
--  set(@APP_NAME_UC@_INCLUDE_DIR @APP_INCLUDE_DIR@)
-+  set(@APP_NAME_UC@_INCLUDE_DIR ${CMAKE_FIND_ROOT_PATH}/@APP_INCLUDE_DIR@)
- endif()
- if(NOT @APP_NAME_UC@_LIB_DIR)
--  set(@APP_NAME_UC@_LIB_DIR @APP_LIB_DIR@)
-+  set(@APP_NAME_UC@_LIB_DIR ${CMAKE_FIND_ROOT_PATH}/@APP_LIB_DIR@)
- endif()
- if(NOT @APP_NAME_UC@_DATA_DIR)
-   set(@APP_NAME_UC@_DATA_DIR @APP_DATA_DIR@)
-@@ -19,6 +19,7 @@ if(NOT WIN32)
-   set(CMAKE_CXX_FLAGS "$ENV{CXXFLAGS} @CXX11_SWITCH@")
- endif()
- list(APPEND CMAKE_MODULE_PATH @APP_LIB_DIR@ @APP_DATA_DIR@/cmake)
-+list(APPEND CMAKE_MODULE_PATH ${CMAKE_FIND_ROOT_PATH}/@APP_LIB_DIR@ ${CMAKE_FIND_ROOT_PATH}/@APP_DATA_DIR@/cmake)
- 
- string(REPLACE ";" " " ARCH_DEFINES "@ARCH_DEFINES@")
- add_definitions(${ARCH_DEFINES} -DBUILD_KODI_ADDON)
--- 
-2.10.2
-
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0009-build-Add-support-for-musl-triplets.patch b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0009-build-Add-support-for-musl-triplets.patch
deleted file mode 100644
index f3e739a..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0009-build-Add-support-for-musl-triplets.patch
+++ /dev/null
@@ -1,180 +0,0 @@
-From 8b2bad58585af0f829fb06e19c9bd2b6caf30808 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 6 Nov 2016 11:54:41 -0800
-Subject: [PATCH 09/10] build: Add support for musl triplets
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- configure.ac               | 12 ++++++------
- m4/xbmc_arch.m4            | 22 +++++++++++-----------
- tools/depends/configure.ac | 12 ++++++------
- 3 files changed, 23 insertions(+), 23 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index ab4eea3..925466a 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -526,7 +526,7 @@ case $host in
-      use_x11=no
-      build_shared_lib=yes
-      ;;
--  i*86*-linux-gnu*|i*86*-*-linux-uclibc*)
-+  i*86*-linux-gnu*|i*86*-*-linux-uclibc*|i*86*-*-linux-musl*)
-      target_platform=target_linux
-      CORE_SYSTEM_NAME=linux
-      ARCH="i486-linux"
-@@ -549,7 +549,7 @@ case $host in
-        fi
-      fi
-      ;;
--  x86_64-*-linux-gnu*|x86_64-*-linux-uclibc*)
-+  x86_64-*-linux-gnu*|x86_64-*-linux-uclibc*|x86_64-*-linux-musl*)
-      target_platform=target_linux
-      CORE_SYSTEM_NAME=linux
-      ARCH="x86_64-linux"
-@@ -601,17 +601,17 @@ case $host in
-      DEPENDS_ROOT_FOR_XCODE=$(echo ${prefix%/*})
-      AC_SUBST([DEPENDS_ROOT_FOR_XCODE])
-      ;;
--  powerpc-*-linux-gnu*|powerpc-*-linux-uclibc*)
-+  powerpc-*-linux-gnu*|powerpc-*-linux-uclibc*|powerpc-*-linux-musl*)
-      target_platform=target_linux
-      CORE_SYSTEM_NAME=linux
-      ARCH="powerpc-linux"
-      ;;
--  powerpc64*-*-linux-gnu*|powerpc64*-*-linux-uclibc*)
-+  powerpc64*-*-linux-gnu*|powerpc64*-*-linux-uclibc*|powerpc64*-*-linux-musl*)
-      target_platform=target_linux
-      CORE_SYSTEM_NAME=linux
-      ARCH="powerpc64-linux"
-      ;;
--  arm*-*-linux-gnu*|arm*-*-linux-uclibc*)
-+  arm*-*-linux-gnu*|arm*-*-linux-uclibc*|arm*-*-linux-musl*)
-      target_platform=target_linux
-      CORE_SYSTEM_NAME=linux
-      ARCH="arm"
-@@ -621,7 +621,7 @@ case $host in
-      use_gl=no
-      USE_STATIC_FFMPEG=1
-      ;;
--  aarch64*-*-linux-gnu*|aarch64*-*-linux-uclibc*)
-+  aarch64*-*-linux-gnu*|aarch64*-*-linux-uclibc*|aarch64*-*-linux-musl*)
-      target_platform=target_linux
-      ARCH="aarch64"
-      use_arch="aarch64"
-diff --git a/m4/xbmc_arch.m4 b/m4/xbmc_arch.m4
-index d28f263..ff5dc20 100644
---- a/m4/xbmc_arch.m4
-+++ b/m4/xbmc_arch.m4
-@@ -2,10 +2,10 @@ AC_DEFUN([XBMC_SETUP_ARCH_DEFINES],[
- 
- # build detection and setup - this is the native arch
- case $build in
--  i*86*-linux-gnu*|i*86*-*-linux-uclibc*)
-+  i*86*-linux-gnu*|i*86*-*-linux-uclibc*|i*86*-*-linux-musl*)
-      AC_SUBST(NATIVE_ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_LINUX -D_LINUX")
-      ;;
--  x86_64-*-linux-gnu*|x86_64-*-linux-uclibc*)
-+  x86_64-*-linux-gnu*|x86_64-*-linux-uclibc*|x86_64-*-linux-musl*)
-      AC_SUBST(NATIVE_ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_LINUX -D_LINUX")
-      ;;
-   i386-*-freebsd*)
-@@ -17,13 +17,13 @@ case $build in
-   *86*-apple-darwin*)
-      AC_SUBST(NATIVE_ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_DARWIN -DTARGET_DARWIN_OSX -D_LINUX")
-      ;;
--  powerpc-*-linux-gnu*|powerpc-*-linux-uclibc*)
-+  powerpc-*-linux-gnu*|powerpc-*-linux-uclibc*|powerpc-*-linux-musl*)
-      AC_SUBST(NATIVE_ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_LINUX -D_LINUX -D_POWERPC")
-      ;;
--  powerpc64-*-linux-gnu*|powerpc64-*-linux-uclibc*)
-+  powerpc64-*-linux-gnu*|powerpc64-*-linux-uclibc*|powerpc64-*-linux-musl*)
-      AC_SUBST(NATIVE_ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_LINUX -D_LINUX -D_POWERPC64")
-      ;;
--  arm*-*-linux-gnu*|arm*-*-linux-uclibc*)
-+  arm*-*-linux-gnu*|arm*-*-linux-uclibc*|arm*-*-linux-musl*)
-      AC_SUBST(NATIVE_ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_LINUX -D_LINUX")
-      ;;
-   *)
-@@ -33,10 +33,10 @@ esac
- 
- # host detection and setup - this is the target arch
- case $host in
--  i*86*-linux-gnu*|i*86*-*-linux-uclibc*)
-+  i*86*-linux-gnu*|i*86*-*-linux-uclibc*|i*86*-*-linux-musl*)
-      AC_SUBST(ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_LINUX -D_LINUX")
-      ;;
--  x86_64-*-linux-gnu*|x86_64-*-linux-uclibc*)
-+  x86_64-*-linux-gnu*|x86_64-*-linux-uclibc*|x86_64-*-linux-musl*)
-      AC_SUBST(ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_LINUX -D_LINUX")
-      ;;
-   i386-*-freebsd*)
-@@ -54,16 +54,16 @@ case $host in
-   powerpc-apple-darwin*)
-      AC_SUBST(ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_DARWIN -DTARGET_DARWIN_OSX -D_LINUX")
-      ;;
--  powerpc-*-linux-gnu*|powerpc-*-linux-uclibc*)
-+  powerpc-*-linux-gnu*|powerpc-*-linux-uclibc*|powerpc-*-linux-musl*)
-      AC_SUBST(ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_LINUX -D_LINUX -D_POWERPC")
-      ;;
--  powerpc64*-*-linux-gnu*|powerpc64*-*-linux-uclibc*)
-+  powerpc64*-*-linux-gnu*|powerpc64*-*-linux-uclibc*|powerpc64*-*-linux-musl*)
-      AC_SUBST(ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_LINUX -D_LINUX -D_POWERPC64")
-      ;;
--  arm*-*-linux-gnu*|arm*-*-linux-uclibc*|aarch64*-*-linux-gnu*|aarch64*-*-linux-uclibc*)
-+  arm*-*-linux-gnu*|arm*-*-linux-uclibc*|arm*-*-linux-musl*|aarch64*-*-linux-gnu*|aarch64*-*-linux-uclibc*|aarch64*-*-linux-musl*)
-      AC_SUBST(ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_LINUX -D_LINUX")
-      ;;
--  mips*-*-linux-gnu*|mips*-*-linux-uclibc*)
-+  mips*-*-linux-gnu*|mips*-*-linux-uclibc*|mips*-*-linux-musl*)
-      AC_SUBST(ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_LINUX -D_LINUX")
-      ;;
-   *-*linux-android*)
-diff --git a/tools/depends/configure.ac b/tools/depends/configure.ac
-index f438e5d..409f4d7 100644
---- a/tools/depends/configure.ac
-+++ b/tools/depends/configure.ac
-@@ -120,13 +120,13 @@ platform_cc=gcc
- platform_cxx=g++
- 
- case $build in
--  arm*-*-linux-gnu*|arm*-*-linux-uclibc*)
-+  arm*-*-linux-gnu*|arm*-*-linux-uclibc*|arm*-*-linux-musl*)
-     build_os="linux"
-   ;;
--  *i686*-linux-gnu*|i*86*-*-linux-uclibc*)
-+  *i686*-linux-gnu*|i*86*-*-linux-uclibc*|i*86*-*-linux-musl*)
-     build_os="linux"
-   ;;
--  x86_64*-linux-gnu*|x86_64-*-linux-uclibc*)
-+  x86_64*-linux-gnu*|x86_64-*-linux-uclibc*|x86_64-*-linux-musl*)
-     build_os="linux"
-   ;;
-   *darwin*)
-@@ -186,7 +186,7 @@ case $host in
-     #android builds are always cross
-     cross_compiling="yes"
-   ;;
--  arm*-*-linux-gnu*|arm*-*-linux-uclibc*)
-+  arm*-*-linux-gnu*|arm*-*-linux-uclibc*|arm*-*-linux-musl*)
-     if test "$use_platform" = "auto"; then
-       if test "x$use_cpu" = "xauto"; then
-         use_cpu=$host_cpu
-@@ -210,12 +210,12 @@ case $host in
-       platform_os="linux"
-     fi
-   ;;
--  *i686*-linux-gnu*|i*86*-*-linux-uclibc*)
-+  *i686*-linux-gnu*|i*86*-*-linux-uclibc*|i*86*-*-linux-musl*)
-     use_cpu=$host_cpu
-     use_toolchain="${use_toolchain:-/usr}"
-     platform_os="linux"
-   ;;
--  x86_64*-linux-gnu*|x86_64-*-linux-uclibc*)
-+  x86_64*-linux-gnu*|x86_64-*-linux-uclibc*|x86_64-*-linux-musl*)
-     use_cpu=$host_cpu
-     use_toolchain="${use_toolchain:-/usr}"
-     platform_cflags="-fPIC -DPIC"
--- 
-2.10.2
-
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0010-RssReader-Fix-compiler-warning-comparing-pointer-to-.patch b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0010-RssReader-Fix-compiler-warning-comparing-pointer-to-.patch
deleted file mode 100644
index e34a5b7..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0010-RssReader-Fix-compiler-warning-comparing-pointer-to-.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From 55233024648b5673dbf223586968e71cc4c70711 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 16 Nov 2016 18:49:36 -0800
-Subject: [PATCH 10/10] RssReader: Fix compiler warning comparing pointer to
- zero
-
-Clang finds this warning
-RssReader.cpp:272:19: error: ordered comparison between pointer and zero ('TiXmlElement *' and 'int')
-  while (itemNode > 0)
-         ~~~~~~~~ ^ ~
-RssReader.cpp:276:22: error: ordered comparison between pointer and zero ('TiXmlNode *' and 'int')
-    while (childNode > 0)
-           ~~~~~~~~~ ^ ~
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- xbmc/utils/RssReader.cpp | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/xbmc/utils/RssReader.cpp b/xbmc/utils/RssReader.cpp
-index 9186f56..2494dc8 100644
---- a/xbmc/utils/RssReader.cpp
-+++ b/xbmc/utils/RssReader.cpp
-@@ -269,11 +269,11 @@ void CRssReader::GetNewsItems(TiXmlElement* channelXmlNode, int iFeed)
-   if (m_tagSet.empty())
-     AddTag("title");
- 
--  while (itemNode > 0)
-+  while (itemNode != NULL)
-   {
-     TiXmlNode* childNode = itemNode->FirstChild();
-     mTagElements.clear();
--    while (childNode > 0)
-+    while (childNode != NULL)
-     {
-       std::string strName = childNode->ValueStr();
- 
--- 
-2.10.2
-
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0011-Let-configure-pass-on-unknown-architectures-setting-.patch b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0011-Let-configure-pass-on-unknown-architectures-setting-.patch
deleted file mode 100644
index 7ee44f1..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0011-Let-configure-pass-on-unknown-architectures-setting-.patch
+++ /dev/null
@@ -1,54 +0,0 @@
-From 19a1ffc1450bd3ecfb7419d74c733b2e16bf47f3 Mon Sep 17 00:00:00 2001
-From: Balint Reczey <balint@balintreczey.hu>
-Date: Wed, 26 Aug 2015 08:14:41 +0200
-Subject: [PATCH 11/12] Let configure pass on unknown architectures setting
- sane defaults
-
-This helps porting Kodi to new architectures while emitting warnings about
-entering uncharted territory.
----
- configure.ac    | 3 ++-
- m4/xbmc_arch.m4 | 6 ++++--
- 2 files changed, 6 insertions(+), 3 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index 925466a..8369615 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -658,7 +658,8 @@ case $host in
-      USE_STATIC_FFMPEG=1
-      ;;
-   *)
--     AC_MSG_ERROR(unsupported host ($host))
-+    ARCH=$host_cpu"-"$host_os
-+    AC_MSG_WARN([unsupported host ($host), guessing ARCH as $ARCH.])
- esac
- AC_SUBST([ARCH])
- 
-diff --git a/m4/xbmc_arch.m4 b/m4/xbmc_arch.m4
-index ff5dc20..dfb45fd 100644
---- a/m4/xbmc_arch.m4
-+++ b/m4/xbmc_arch.m4
-@@ -27,7 +27,8 @@ case $build in
-      AC_SUBST(NATIVE_ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_LINUX -D_LINUX")
-      ;;
-   *)
--     AC_MSG_ERROR(unsupported native build platform: $build)
-+     AC_MSG_WARN([unsupported native build platform: $build])
-+     AC_SUBST(NATIVE_ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_LINUX -D_LINUX")
- esac
- 
- 
-@@ -70,7 +71,8 @@ case $host in
-      AC_SUBST(ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_LINUX -D_LINUX -DTARGET_ANDROID")
-      ;;
-   *)
--     AC_MSG_ERROR(unsupported build target: $host)
-+     AC_MSG_WARN([unsupported native build platform: $build])
-+     AC_SUBST(ARCH_DEFINES, "-DTARGET_POSIX -DTARGET_LINUX -D_LINUX")
- esac
- 
- if test "$target_platform" = "target_android" ; then
--- 
-2.10.2
-
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0012-Revert-droid-fix-builds-with-AML-disabled.patch b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0012-Revert-droid-fix-builds-with-AML-disabled.patch
deleted file mode 100644
index 8d70b3f..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0012-Revert-droid-fix-builds-with-AML-disabled.patch
+++ /dev/null
@@ -1,87 +0,0 @@
-From 9e88aa086083b80c05b2bf057b92682186c4e6dc Mon Sep 17 00:00:00 2001
-From: Balint Reczey <balint@balintreczey.hu>
-Date: Thu, 6 Oct 2016 18:12:18 +0200
-Subject: [PATCH 12/12] Revert "[droid] fix builds with AML disabled"
-
-This reverts commit 4733383b8f1c1dd0b95e9e5358425d8a0b7ba8fc.
----
- xbmc/utils/SystemInfo.cpp         |  4 ----
- xbmc/windowing/egl/EGLWrapper.cpp | 16 ++++++----------
- 2 files changed, 6 insertions(+), 14 deletions(-)
-
-diff --git a/xbmc/utils/SystemInfo.cpp b/xbmc/utils/SystemInfo.cpp
-index fcc6733..52e7fa3 100644
---- a/xbmc/utils/SystemInfo.cpp
-+++ b/xbmc/utils/SystemInfo.cpp
-@@ -57,10 +57,8 @@
- #include "utils/XMLUtils.h"
- #if defined(TARGET_ANDROID)
- #include "platform/android/jni/Build.h"
--#if defined(HAS_LIBAMCODEC)
- #include "utils/AMLUtils.h"
- #endif
--#endif
- 
- /* Platform identification */
- #if defined(TARGET_DARWIN)
-@@ -873,11 +871,9 @@ bool CSysInfo::IsAeroDisabled()
- bool CSysInfo::HasHW3DInterlaced()
- {
- #if defined(TARGET_ANDROID)
--#if defined(HAS_LIBAMCODEC)
-   if (aml_hw3d_present())
-     return true;
- #endif
--#endif
-   return false;
- }
- 
-diff --git a/xbmc/windowing/egl/EGLWrapper.cpp b/xbmc/windowing/egl/EGLWrapper.cpp
-index 30f5757..583d43a 100644
---- a/xbmc/windowing/egl/EGLWrapper.cpp
-+++ b/xbmc/windowing/egl/EGLWrapper.cpp
-@@ -24,19 +24,15 @@
- #include <assert.h>
- #if defined(TARGET_ANDROID)
-   #include "EGLNativeTypeAndroid.h"
--#if defined(HAS_LIBAMCODEC)
-   #include "EGLNativeTypeAmlAndroid.h"
- #endif
--#endif
- #if defined(TARGET_RASPBERRY_PI)
-   #include "EGLNativeTypeRaspberryPI.h"
- #endif
- #if defined(HAS_IMXVPU)
-   #include "EGLNativeTypeIMX.h"
- #endif
--#if defined(TARGET_LINUX) && defined(HAS_LIBAMCODEC)
- #include "EGLNativeTypeAmlogic.h"
--#endif
- #include "EGLWrapper.h"
- 
- #define CheckError() m_result = eglGetError(); if(m_result != EGL_SUCCESS) CLog::Log(LOGERROR, "EGL error in %s: %x",__FUNCTION__, m_result);
-@@ -91,15 +87,15 @@ bool CEGLWrapper::Initialize(const std::string &implementation)
-   // Try to create each backend in sequence and go with the first one
-   // that we know will work
-   if (
--#if defined(TARGET_ANDROID) && defined(HAS_LIBAMCODEC)
--      (nativeGuess = CreateEGLNativeType<CEGLNativeTypeAmlAndroid>(implementation))
--#elif defined(TARGET_ANDROID)
--      (nativeGuess = CreateEGLNativeType<CEGLNativeTypeAndroid>(implementation))
--#elif defined(TARGET_RASPBERRY_PI)
-+#if defined(TARGET_ANDROID)
-+      (nativeGuess = CreateEGLNativeType<CEGLNativeTypeAmlAndroid>(implementation)) ||
-+      (nativeGuess = CreateEGLNativeType<CEGLNativeTypeAndroid>(implementation)) ||
-+#endif
-+#if defined(TARGET_RASPBERRY_PI)
-       (nativeGuess = CreateEGLNativeType<CEGLNativeTypeRaspberryPI>(implementation))
- #elif defined(HAS_IMXVPU)
-       (nativeGuess = CreateEGLNativeType<CEGLNativeTypeIMX>(implementation))
--#elif defined(TARGET_LINUX) && defined(HAS_LIBAMCODEC)
-+#else
-       (nativeGuess = CreateEGLNativeType<CEGLNativeTypeAmlogic>(implementation))
- #endif
-       )
--- 
-2.10.2
-
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0013-FTPParse.cpp-use-std-string.patch b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0013-FTPParse.cpp-use-std-string.patch
deleted file mode 100644
index c9c9066..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-17/0013-FTPParse.cpp-use-std-string.patch
+++ /dev/null
@@ -1,96 +0,0 @@
-From 5fa10ff6b1b60abee172296d9c1dec8dfc10615c Mon Sep 17 00:00:00 2001
-From: Stefan Saraev <stefan@saraev.ca>
-Date: Sun, 7 May 2017 17:30:47 +0300
-Subject: [PATCH] FTPParse.cpp: use std::string
-
-Fixes build with newer gcc versions.
-
-Taken from [1]
-
-Upstream-Status: Backport [2]
-
-[1] https://git.busybox.net/buildroot/plain/package/kodi/0003-FTPParse.cpp-use-std-string.patch?id=e2f03a6bde19766a1ac047c5ccfb049b5c4f61ca
-[2] https://github.com/xbmc/xbmc/commit/5fa10ff6b1b60abee172296d9c1dec8dfc10615c
-
-Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
----
- xbmc/filesystem/FTPParse.cpp | 44 ++++++++++++++++++++++----------------------
- 1 file changed, 22 insertions(+), 22 deletions(-)
-
-diff --git a/xbmc/filesystem/FTPParse.cpp b/xbmc/filesystem/FTPParse.cpp
-index cfcc7c64ed..b0f676ae1a 100644
---- a/xbmc/filesystem/FTPParse.cpp
-+++ b/xbmc/filesystem/FTPParse.cpp
-@@ -34,7 +34,7 @@ CFTPParse::CFTPParse()
-   m_time = 0;
- }
- 
--string CFTPParse::getName()
-+std::string CFTPParse::getName()
- {
-   return m_name;
- }
-@@ -59,16 +59,16 @@ time_t CFTPParse::getTime()
-   return m_time;
- }
- 
--void CFTPParse::setTime(string str)
-+void CFTPParse::setTime(std::string str)
- {
-   /* Variables used to capture patterns via the regexes */
--  string month;
--  string day;
--  string year;
--  string hour;
--  string minute;
--  string second;
--  string am_or_pm;
-+  std::string month;
-+  std::string day;
-+  std::string year;
-+  std::string hour;
-+  std::string minute;
-+  std::string second;
-+  std::string am_or_pm;
- 
-   /* time struct used to set the time_t variable */
-   struct tm time_struct = {};
-@@ -338,21 +338,21 @@ int CFTPParse::getDayOfWeek(int month, int date, int year)
-   return day_of_week;
- }
- 
--int CFTPParse::FTPParse(string str)
-+int CFTPParse::FTPParse(std::string str)
- {
-   /* Various variable to capture patterns via the regexes */
--  string permissions;
--  string link_count;
--  string owner;
--  string group;
--  string size;
--  string date;
--  string name;
--  string type;
--  string stuff;
--  string facts;
--  string version;
--  string file_id;
-+  std::string permissions;
-+  std::string link_count;
-+  std::string owner;
-+  std::string group;
-+  std::string size;
-+  std::string date;
-+  std::string name;
-+  std::string type;
-+  std::string stuff;
-+  std::string facts;
-+  std::string version;
-+  std::string file_id;
- 
-   /* Regex for standard Unix listing formats */
-   pcrecpp::RE unix_re("^([-bcdlps])" // type
--- 
-2.11.0
-
-
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-startup/kodi.service b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-startup/kodi.service
deleted file mode 100644
index 29d0394..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi-startup/kodi.service
+++ /dev/null
@@ -1,14 +0,0 @@
-[Unit]
-Description=Kodi media thing
-
-[Service]
-User=root
-Type=simple
-SuccessExitStatus=0 1
-IOSchedulingClass=realtime
-IOSchedulingPriority=0
-
-ExecStart=/usr/bin/xinit /usr/bin/kodi-standalone -- /usr/bin/X :0 
-
-[Install]
-WantedBy=basic.target
diff --git a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi_17.bb b/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi_17.bb
deleted file mode 100644
index 2956189..0000000
--- a/meta-openembedded/meta-multimedia/recipes-mediacenter/kodi/kodi_17.bb
+++ /dev/null
@@ -1,216 +0,0 @@
-SUMMARY = "Kodi Media Center"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://LICENSE.GPL;md5=930e2a5f63425d8dd72dbd7391c43c46"
-
-FILESPATH =. "${FILE_DIRNAME}/kodi-17:"
-
-DEPENDS = " \
-    cmake-native \
-    curl-native \
-    gperf-native \
-    jsonschemabuilder-native \
-    nasm-native \
-    swig-native \
-    unzip-native \
-    yasm-native \
-    zip-native \
-    avahi \
-    boost \
-    bzip2 \
-    crossguid \
-    curl \
-    dcadec \
-    enca \
-    expat \
-    faad2 \
-    ffmpeg \
-    fontconfig \
-    fribidi \
-    giflib \
-    jasper \
-    libass \
-    libcdio \
-    libcec \
-    libmad \
-    libmicrohttpd \
-    libmms \
-    libmms \
-    libmodplug \
-    libpcre \
-    libplist \
-    libsamplerate0 \
-    libsdl-image \
-    libsdl-mixer \
-    libsquish \
-    libssh \
-    libtinyxml \
-    libusb1 \
-    libxslt \
-    lzo \
-    mpeg2dec \
-    python \
-    sqlite3 \
-    taglib \
-    virtual/egl \
-    virtual/libsdl \
-    wavpack \
-    yajl \
-    zlib \
-    ${@enable_glew(bb, d)} \
-"
-
-PROVIDES = "xbmc"
-
-SRCREV = "6abeebd5ba371547c8f04272296433f5e4e28e86"
-PV = "17.3+gitr${SRCPV}"
-ADDONSPV = "17.1"
-SRC_URI = "git://github.com/xbmc/xbmc.git;branch=Krypton \
-    https://repo.voidlinux.eu/distfiles/${BPN}-${ADDONSPV}-generated-addons.tar.xz;name=addons;unpack=0 \
-    file://0003-configure-don-t-try-to-run-stuff-to-find-tinyxml.patch \
-    file://0004-handle-SIGTERM.patch \
-    file://0005-add-support-to-read-frequency-output-if-using-intel-.patch \
-    file://0006-Disable-DVD-support.patch \
-    file://0007-Always-compile-libcpluff-as-PIC.patch \
-    file://0008-kodi-config.cmake-use-CMAKE_FIND_ROOT_PATH-to-fix-cr.patch \
-    file://0009-build-Add-support-for-musl-triplets.patch \
-    file://0010-RssReader-Fix-compiler-warning-comparing-pointer-to-.patch \
-    file://0011-Let-configure-pass-on-unknown-architectures-setting-.patch \
-    file://0012-Revert-droid-fix-builds-with-AML-disabled.patch \
-    file://0001-change-order-of-detecting-libegl-and-libgles2.patch \
-    file://0013-FTPParse.cpp-use-std-string.patch \
-"
-
-SRC_URI_append_libc-musl = " \
-    file://0001-Fix-file_Emu-on-musl.patch \
-    file://0002-Remove-FILEWRAP.patch \
-"
-SRC_URI[addons.md5sum] = "719614fa764011a18665d08af5c8c92f"
-SRC_URI[addons.sha256sum] = "350da57408c27473eaf40e7f544bc94841bf101dc4346085260c5c4af0adac97"
-
-inherit autotools-brokensep gettext pythonnative distro_features_check
-
-REQUIRED_DISTRO_FEATURES += "opengl"
-
-S = "${WORKDIR}/git"
-
-# breaks compilation
-ASNEEDED = ""
-
-ACCEL ?= ""
-ACCEL_x86 = "vaapi vdpau"
-ACCEL_x86-64 = "vaapi vdpau"
-
-PACKAGECONFIG ??= "${ACCEL} opengl \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', 'openglesv2', d)} \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'samba', '', d)} \
-"
-
-PACKAGECONFIG[opengl] = "--enable-gl,--enable-gles,"
-PACKAGECONFIG[openglesv2] = "--enable-gles,--enable-gl,virtual/egl"
-PACKAGECONFIG[vaapi] = "--enable-vaapi,--disable-vaapi,libva"
-PACKAGECONFIG[vdpau] = "--enable-vdpau,--disable-vdpau,libvdpau"
-PACKAGECONFIG[mysql] = "--enable-mysql,--disable-mysql,mysql5"
-PACKAGECONFIG[x11] = "--enable-x11,--disable-x11,libxinerama libxmu libxrandr libxtst"
-PACKAGECONFIG[pulseaudio] = "--enable-pulse,--disable-pulse,pulseaudio"
-PACKAGECONFIG[lcms] = "--enable-lcms2,--disable-lcms2,lcms"
-PACKAGECONFIG[samba] = "--enable-samba,--disable-samba,samba"
-
-EXTRA_OECONF = " \
-    --disable-debug \
-    --disable-libcap \
-    --disable-ccache \
-    --disable-mid \
-    --enable-libusb \
-    --enable-alsa \
-    --enable-airplay \
-    --disable-optical-drive \
-    --with-ffmpeg=shared \
-    --enable-texturepacker=no \
-    ac_cv_path_JAVA_EXE=/bin/true \
-"
-
-FULL_OPTIMIZATION_armv7a = "-fexpensive-optimizations -fomit-frame-pointer -O3 -ffast-math"
-FULL_OPTIMIZATION_armv7ve = "-fexpensive-optimizations -fomit-frame-pointer -O3 -ffast-math"
-BUILD_OPTIMIZATION = "${FULL_OPTIMIZATION}"
-
-LDFLAGS_append_mips = " -latomic"
-LDFLAGS_append_mipsel = " -latomic"
-LDFLAGS_append_powerpc = " -latomic"
-LDFLAGS_append_arm = " -latomic"
-
-EXTRA_OECONF_append = " LIBTOOL=${STAGING_BINDIR_CROSS}/${HOST_SYS}-libtool"
-
-# for python modules
-export HOST_SYS
-export BUILD_SYS
-export STAGING_LIBDIR
-export STAGING_INCDIR
-export PYTHON_DIR
-
-def enable_glew(bb, d):
-    if bb.utils.contains('PACKAGECONFIG', 'x11', True, False, d) and bb.utils.contains('DISTRO_FEATURES', 'opengl', True, False, d):
-        return "glew"
-    return ""
-
-do_configure() {
-    tar xf ${WORKDIR}/${BPN}-${ADDONSPV}-generated-addons.tar.xz -C ${S}/
-
-    ( for i in $(find ${S} -name configure.ac -or -name configure.in|grep -v ".pc") ; do
-       cd $(dirname $i) && gnu-configize --force || true
-    done )
-    ( for f in ${S}/xbmc/interfaces/python/generated/*.cpp; do
-       touch `echo $f|sed -e 's/.cpp$/.xml/g'`
-    done )
-
-    BOOTSTRAP_STANDALONE=1 make -f bootstrap.mk JSON_BUILDER="${STAGING_BINDIR_NATIVE}/JsonSchemaBuilder"
-    BOOTSTRAP_STANDALONE=1 make JAVA=/bin/true -f codegenerator.mk JSON_BUILDER="${STAGING_BINDIR_NATIVE}/JsonSchemaBuilder"
-    oe_runconf
-}
-
-do_compile_prepend() {
-    for i in $(find . -name "Makefile") ; do
-        sed -i -e 's:I/usr/include:I${STAGING_INCDIR}:g' $i
-    done
-
-    for i in $(find . -name "*.mak*" -o    -name "Makefile") ; do
-        sed -i -e 's:I/usr/include:I${STAGING_INCDIR}:g' -e 's:-rpath \$(libdir):-rpath ${libdir}:g' $i
-    done
-}
-
-INSANE_SKIP_${PN} = "rpaths"
-
-FILES_${PN} += "${datadir}/xsessions ${datadir}/icons ${libdir}/xbmc ${datadir}/xbmc"
-FILES_${PN}-dbg += "${libdir}/kodi/.debug ${libdir}/kodi/*/.debug ${libdir}/kodi/*/*/.debug ${libdir}/kodi/*/*/*/.debug"
-
-# kodi uses some kind of dlopen() method for libcec so we need to add it manually
-# OpenGL builds need glxinfo, that's in mesa-demos
-RRECOMMENDS_${PN}_append = " \
-    libcec \
-    python \
-    python-ctypes \
-    python-lang \
-    python-re \
-    python-netclient \
-    python-html \
-    python-difflib \
-    python-json \
-    python-zlib \
-    python-shell \
-    python-sqlite3 \
-    python-compression \
-    libcurl \
-    ${@bb.utils.contains('PACKAGECONFIG', 'x11', 'xrandr xdpyinfo', '', d)} \
-"
-RRECOMMENDS_${PN}_append_libc-glibc = " \
-    glibc-charmap-ibm850 \
-    glibc-gconv-ibm850 \
-    glibc-gconv-unicode \
-    glibc-gconv-utf-32 \
-    glibc-charmap-utf-8 \
-    glibc-localedata-en-us \
-"
-
-RPROVIDES_${PN} += "xbmc"
-
-TOOLCHAIN = "gcc"
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/faac/faac_1.29.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/faac/faac_1.29.bb
index 4765c6c..d36f2f4 100644
--- a/meta-openembedded/meta-multimedia/recipes-multimedia/faac/faac_1.29.bb
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/faac/faac_1.29.bb
@@ -1,9 +1,12 @@
 SUMMARY = "Freeware Advanced Audio Coder (MPEG2-AAC, MPEG4-AAC)"
 SECTION = "libs"
 LICENSE = "LGPLv2+"
+HOMEPAGE = "http://www.audiocoding.com/faac.html"
 LIC_FILES_CHKSUM = "file://COPYING;md5=3bf50002aefd002f49e7bb854063f7e7 \
                     file://libfaac/coder.h;beginline=5;endline=17;md5=fa1fd6a5fa8cdc877d63a12530d273e0"
 
+LICENSE_FLAGS = "commercial"
+
 inherit autotools
 
 SRC_URI = " \
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/fluidsynth/fluidsynth_1.1.10.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/fluidsynth/fluidsynth_1.1.10.bb
deleted file mode 100644
index 0ec4c49..0000000
--- a/meta-openembedded/meta-multimedia/recipes-multimedia/fluidsynth/fluidsynth_1.1.10.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-SUMMARY = "Fluidsynth is a software synthesizer"
-HOMEPAGE = "http://www.fluidsynth.org/"
-SECTION = "libs/multimedia"
-LICENSE = "LGPL-2.1"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=fc178bcd425090939a8b634d1d6a9594"
-
-DEPENDS = "alsa-lib ncurses glib-2.0"
-
-SRC_URI = " \
-    git://github.com/FluidSynth/fluidsynth.git;branch=1.1.x \
-    file://0001-Use-ARM-NEON-accelaration-for-float-multithreaded-se.patch \
-"
-SRCREV = "f5a0fee6f7f2b2ab4c866df1acb649333464b3fd"
-S = "${WORKDIR}/git"
-
-inherit cmake pkgconfig lib_package
-
-EXTRA_OECMAKE = "-Denable-floats=ON -DLIB_SUFFIX=${@d.getVar('baselib').replace('lib', '')}"
-
-PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'pulseaudio', d)}"
-PACKAGECONFIG[sndfile] = "-Denable-libsndfile-support=ON,-Denable-libsndfile-support=OFF,libsndfile1"
-PACKAGECONFIG[jack] = "-Denable-jack-support=ON,-Denable-jack-support=OFF,jack"
-PACKAGECONFIG[pulseaudio] = "-Denable-pulseaudio=ON,--Denable-pulseaudio=OFF,pulseaudio"
-PACKAGECONFIG[portaudio] = "-Denable-portaudio=ON,-Denable-portaudio=OFF,portaudio-v19"
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/fluidsynth/fluidsynth_1.1.11.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/fluidsynth/fluidsynth_1.1.11.bb
new file mode 100644
index 0000000..4df3102
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/fluidsynth/fluidsynth_1.1.11.bb
@@ -0,0 +1,24 @@
+SUMMARY = "Fluidsynth is a software synthesizer"
+HOMEPAGE = "http://www.fluidsynth.org/"
+SECTION = "libs/multimedia"
+LICENSE = "LGPL-2.1"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=fc178bcd425090939a8b634d1d6a9594"
+
+DEPENDS = "alsa-lib ncurses glib-2.0"
+
+SRC_URI = " \
+    git://github.com/FluidSynth/fluidsynth.git;branch=1.1.x \
+    file://0001-Use-ARM-NEON-accelaration-for-float-multithreaded-se.patch \
+"
+SRCREV = "f65c6ba25fb2c7e37c89fc6a4afc5aa645e208c2"
+S = "${WORKDIR}/git"
+
+inherit cmake pkgconfig lib_package
+
+EXTRA_OECMAKE = "-Denable-floats=ON -DLIB_SUFFIX=${@d.getVar('baselib').replace('lib', '')}"
+
+PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'pulseaudio', d)}"
+PACKAGECONFIG[sndfile] = "-Denable-libsndfile-support=ON,-Denable-libsndfile-support=OFF,libsndfile1"
+PACKAGECONFIG[jack] = "-Denable-jack-support=ON,-Denable-jack-support=OFF,jack"
+PACKAGECONFIG[pulseaudio] = "-Denable-pulseaudio=ON,-Denable-pulseaudio=OFF,pulseaudio"
+PACKAGECONFIG[portaudio] = "-Denable-portaudio=ON,-Denable-portaudio=OFF,portaudio-v19"
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-0.10/gstreamer_0.10.36.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-0.10/gstreamer_0.10.36.bb
index 5f97a20..56d8220 100644
--- a/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-0.10/gstreamer_0.10.36.bb
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-0.10/gstreamer_0.10.36.bb
@@ -45,9 +45,6 @@
 #    mv ${WORKDIR}/gstregistrybinary.[ch] ${S}/gst/
 #}
 
-RRECOMMENDS_${PN}_qemux86    += "kernel-module-snd-ens1370 kernel-module-snd-rawmidi"
-RRECOMMENDS_${PN}_qemux86-64 += "kernel-module-snd-ens1370 kernel-module-snd-rawmidi"
-
 FILES_${PN} += " ${libdir}/gstreamer-0.10/*.so"
 FILES_${PN}-dev += " ${libdir}/gstreamer-0.10/*.la ${libdir}/gstreamer-0.10/*.a"
 FILES_${PN}-dbg += " ${libdir}/gstreamer-0.10/.debug/ ${libexecdir}/gstreamer-0.10/.debug/"
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-1.0/gst-shark_0.2.1.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-1.0/gst-shark_0.2.1.bb
new file mode 100644
index 0000000..5409f32
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-1.0/gst-shark_0.2.1.bb
@@ -0,0 +1,38 @@
+SUMMARY = "Gst-Shark Tracers"
+DESCRIPTION = "Benchmarks and profiling tools for GStreamer"
+HOMEPAGE = "https://developer.ridgerun.com/wiki/index.php?title=GstShark"
+SECTION = "multimedia"
+LICENSE = "GPLv2+"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=e1caa368743492879002ad032445fa97"
+
+DEPENDS = "gstreamer1.0 gstreamer1.0-plugins-base gstreamer1.0-plugins-bad "
+
+SRCBRANCH ?= "master"
+
+SRCREV_base = "a60b3996fe3376d42334fc89014e9d6f6af62899"
+SRCREV_common = "b64f03f6090245624608beb5d2fff335e23a01c0"
+
+SRC_URI = " \
+    git://github.com/RidgeRun/gst-shark.git;protocol=https;branch=${SRCBRANCH};name=base \
+    git://anongit.freedesktop.org/git/gstreamer/common.git;protocol=https;destsuffix=git/common;name=common; \
+    "
+
+S = "${WORKDIR}/git"
+
+PACKAGECONFIG_CONFARGS = " \
+       --disable-graphviz \
+       --enable-gtk-doc=no \
+"
+
+FILES_${PN} += "\
+       ${libdir}/gstreamer-1.0/libgstsharktracers.so  \
+       ${libdir}/gstreamer-1.0/libgstsharktracers.la \
+"
+
+inherit autotools gettext
+
+do_configure() {
+        ${S}/autogen.sh --noconfigure
+        oe_runconf
+}
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-1.0/gstd.inc b/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-1.0/gstd.inc
index 10ee5bc..455d896 100644
--- a/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-1.0/gstd.inc
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-1.0/gstd.inc
@@ -7,19 +7,15 @@
 DEPENDS = "gstreamer1.0 gstreamer1.0-plugins-base gstreamer1.0-plugins-bad gstreamer1.0-rtsp-server json-glib libdaemon"
 
 SRCBRANCH ?= "master"
-SRCREV = "097a086a8606dcb368c7d38c7ec4fefc2497401b"
+SRCREV = "3526d0ffdbccc375db7d5fe33a72c68b134657c2"
 SRC_URI = "git://git@github.com/RidgeRun/gstd-1.x.git;protocol=https;branch=${SRCBRANCH} \
-	   file://0001-gstd-yocto-compatibility.patch"
-
+           file://0001-gstd-yocto-compatibility.patch \
+           file://0001-Look-for-gtk-doc.make-in-builddir.patch \
+           "
 S = "${WORKDIR}/git"
 
-PACKAGECONFIG_CONFARGS = " \
-	--disable-gtk-doc \
-"
+inherit autotools pkgconfig gettext gtk-doc
 
-inherit autotools pkgconfig gettext
-
-do_configure() {
-${S}/autogen.sh
-oe_runconf
+do_configure_prepend() {
+	sed -i -e "s|include \$(top_builddir)/docs/gtk-doc.make||g" ${S}/docs/reference/gstd/Makefile.am
 }
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-1.0/gstd/0001-Look-for-gtk-doc.make-in-builddir.patch b/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-1.0/gstd/0001-Look-for-gtk-doc.make-in-builddir.patch
new file mode 100644
index 0000000..5a28616
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-1.0/gstd/0001-Look-for-gtk-doc.make-in-builddir.patch
@@ -0,0 +1,32 @@
+From a84e9a6e1dca685eda072d58b58556b5b35cb4c8 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 10 Sep 2018 21:16:50 -0700
+Subject: [PATCH] Look for gtk-doc.make in builddir
+
+this is evident when S != B because gtkdocize
+generates this file and its actually built into
+build area
+
+Upstream-Status: Submitted [https://github.com/RidgeRun/gstd-1.x/pull/39]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ docs/reference/gstd/Makefile.am | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/docs/reference/gstd/Makefile.am b/docs/reference/gstd/Makefile.am
+index f860fa1..62870da 100644
+--- a/docs/reference/gstd/Makefile.am
++++ b/docs/reference/gstd/Makefile.am
+@@ -66,7 +66,7 @@ GTKDOC_LIBS=$(top_builddir)/gstd/libgstd-core.la
+ 
+ 
+ # This includes the standard gtk-doc make rules, copied by gtkdocize.
+-include $(top_srcdir)/docs/gtk-doc.make
++include $(top_builddir)/docs/gtk-doc.make
+ 
+ # Comment this out if you want 'make check' to test you doc status
+ # and run some sanity checks
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-1.0/gstd/0001-gstd-yocto-compatibility.patch b/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-1.0/gstd/0001-gstd-yocto-compatibility.patch
index ddc1831..ffcc6ea 100644
--- a/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-1.0/gstd/0001-gstd-yocto-compatibility.patch
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/gstreamer-1.0/gstd/0001-gstd-yocto-compatibility.patch
@@ -4,47 +4,9 @@
 Subject: [PATCH] gstd:yocto compatibility
 
 ---
- autogen.sh                      | 8 +++++++-
- docs/reference/gstd/Makefile.am | 2 +-
  gstd/Makefile.am                | 2 +-
  3 files changed, 9 insertions(+), 3 deletions(-)
 
-diff --git a/autogen.sh b/autogen.sh
-index 66dbd42..793ee2f 100755
---- a/autogen.sh
-+++ b/autogen.sh
-@@ -21,7 +21,11 @@
- # ACLOCAL, AUTOPOINT and/or LIBTOOLIZE to the right versions, or leave them
- # unset and get the defaults
- 
--gtkdocize || exit 1
-+test -n "$srcdir" || srcdir=`dirname "$0"`
-+test -n "$srcdir" || srcdir=.
-+
-+olddir=`pwd`
-+cd "$srcdir"
- 
- autoreconf --verbose --force --install || {
-  echo 'autogen.sh failed';
-@@ -31,3 +35,5 @@ autoreconf --verbose --force --install || {
- echo
- echo "Now run './configure' with your system settings followed by 'make' to compile this module."
- echo
-+
-+cd "$olddir"
-diff --git a/docs/reference/gstd/Makefile.am b/docs/reference/gstd/Makefile.am
-index f860fa1..153a13b 100644
---- a/docs/reference/gstd/Makefile.am
-+++ b/docs/reference/gstd/Makefile.am
-@@ -66,7 +66,7 @@ GTKDOC_LIBS=$(top_builddir)/gstd/libgstd-core.la
- 
- 
- # This includes the standard gtk-doc make rules, copied by gtkdocize.
--include $(top_srcdir)/docs/gtk-doc.make
-+# include $(top_srcdir)/docs/gtk-doc.make
- 
- # Comment this out if you want 'make check' to test you doc status
- # and run some sanity checks
 diff --git a/gstd/Makefile.am b/gstd/Makefile.am
 index 13c551d..11fe202 100644
 --- a/gstd/Makefile.am
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/libdc1394/libdc1394_git.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/libdc1394/libdc1394_git.bb
index 8a9e9a1..b6bb447 100755
--- a/meta-openembedded/meta-multimedia/recipes-multimedia/libdc1394/libdc1394_git.bb
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/libdc1394/libdc1394_git.bb
@@ -7,7 +7,8 @@
 # libsdl to provide sdl.m4 with AM_PATH_SDL
 DEPENDS += "libusb1 libraw1394 libsdl \
             ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'libxv virtual/libx11', '', d)} \
-            ${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'virtual/libgl libglu', '', d)} \
+            ${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'virtual/libgl', '', d)} \
+            ${@bb.utils.contains('DISTRO_FEATURES', 'opengl x11', 'libglu', '', d)} \
 "
 
 PV = "2.2.5+gitr${SRCPV}"
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/libopenmpt/files/run-ptest b/meta-openembedded/meta-multimedia/recipes-multimedia/libopenmpt/files/run-ptest
new file mode 100644
index 0000000..84981b2
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/libopenmpt/files/run-ptest
@@ -0,0 +1,9 @@
+#!/bin/sh
+
+./libopenmpttest >/dev/null 2>&1
+
+if [ $? -eq 0 ]; then
+   echo "PASS: libopenmpttest"
+else
+   echo "FAIL: libopenmpttest"
+fi
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/libopenmpt/libopenmpt_0.3.10.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/libopenmpt/libopenmpt_0.3.10.bb
new file mode 100644
index 0000000..d14246f
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/libopenmpt/libopenmpt_0.3.10.bb
@@ -0,0 +1,104 @@
+SUMMARY = "C and C++ cross-platform library for decoding tracked music files (modules)"
+DESCRIPTION = "libopenmpt is a cross-platform C++ and C library to decode tracked \
+music files (modules) into a raw PCM audio stream. It also comes with openmpt123, a \
+cross-platform command-line or terminal based module file player, and libopenmpt_modplug, \
+a wrapper around libopenmpt that provides an interface that is ABI compatile with \
+libmodplug. libopenmpt is based on the player code of the OpenMPT project."
+HOMEPAGE = "https://lib.openmpt.org/libopenmpt/"
+SECTION = "libs"
+
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=e804150573f149befef6c07e173f20c3"
+
+DEPENDS = "virtual/libiconv"
+
+SRC_URI = "https://lib.openmpt.org/files/libopenmpt/src/libopenmpt-${PV}+release.autotools.tar.gz \
+           file://run-ptest \
+          "
+SRC_URI[md5sum] = "66bbc6fbb5f27a554cb145d805e9ef9d"
+SRC_URI[sha256sum] = "14a137b8d1a20e1b6a5e67cbc9467ab7e5e4e67d5aa38a247afc825685c53939"
+
+S = "${WORKDIR}/libopenmpt-${PV}+release.autotools"
+
+inherit autotools pkgconfig ptest
+
+PACKAGECONFIG ??= " \
+    libopenmpt-modplug openmpt123 \
+    ${@bb.utils.contains('PTEST_ENABLED', '1', 'tests', '', d)} \
+    flac mpg123 ogg sndfile vorbis vorbisfile zlib \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'pulseaudio', d)} \
+"
+
+# libopenmpt_modplug is a library that wraps libopenmpt calls into
+# functions that are ABI compatible with libmodplug. This allows for
+# using modplug headers and linking against libopenmpt_modplug
+# instead of against the original libmodplug library.
+# NOTE: The wrapper is compatible to the ABI from libmodplug version
+# 0.8.8 and newer.
+PACKAGECONFIG[libopenmpt-modplug] = "--enable-libopenmpt_modplug,--disable-libopenmpt_modplug"
+PACKAGECONFIG[openmpt123]         = "--enable-openmpt123,--disable-openmpt123"
+PACKAGECONFIG[tests]              = "--enable-tests,--disable-tests"
+
+# These packageconfigs affect openmpt123
+PACKAGECONFIG[flac]               = "--with-flac,--without-flac,flac"
+PACKAGECONFIG[mpg123]             = "--with-mpg123,--without-mpg123,mpg123"
+PACKAGECONFIG[ogg]                = "--with-ogg,--without-ogg,libogg"
+PACKAGECONFIG[portaudio]          = "--with-portaudio,--without-portaudio,portaudio-v19"
+PACKAGECONFIG[pulseaudio]         = "--with-pulseaudio,--without-pulseaudio,pulseaudio"
+PACKAGECONFIG[sdl]                = "--with-sdl,--without-sdl,virtual/libsdl"
+PACKAGECONFIG[sdl2]               = "--with-sdl2,--without-sdl2,virtual/libsdl2"
+PACKAGECONFIG[sndfile]            = "--with-sndfile,--without-sndfile,libsndfile1"
+PACKAGECONFIG[vorbis]             = "--with-vorbis,--without-vorbis,libvorbis"
+PACKAGECONFIG[vorbisfile]         = "--with-vorbisfile,--without-vorbisfile,libvorbis"
+PACKAGECONFIG[zlib]               = "--with-zlib,--without-zlib,zlib"
+
+# --disable-libmodplug is necessary, since otherwise we'd
+# have a collision with the libmodplug package, because of the
+# libmodplug.so file. (libmodplug.so from libopenmpt isintended
+# to be used as a drop-in replacement, and according to the
+# documentation, is not complete.)
+EXTRA_OECONF += " \
+    --disable-doxygen-doc \
+    --disable-examples \
+    --disable-libmodplug \
+    --without-portaudiocpp \
+"
+
+do_compile_ptest() {
+    oe_runmake ${PARALLEL_MAKE} libopenmpttest
+}
+
+do_install_ptest() {
+    install -d ${D}${PTEST_PATH}/test
+    install -m 0755 ${B}/libopenmpttest ${D}${PTEST_PATH}
+    install -m 0644 ${S}/test/test.mptm ${D}${PTEST_PATH}/test
+    install -m 0644 ${S}/test/test.s3m ${D}${PTEST_PATH}/test
+    install -m 0644 ${S}/test/test.xm ${D}${PTEST_PATH}/test
+
+    install -d ${D}${PTEST_PATH}/libopenmpt
+    install -m 0644 ${S}/libopenmpt/libopenmpt_version.mk ${D}${PTEST_PATH}/libopenmpt
+}
+
+python __anonymous() {
+    packageconfig = (d.getVar("PACKAGECONFIG") or "").split()
+    if ("sdl" in packageconfig) and ("sdl2" in packageconfig):
+        bb.error("sdl and sdl2 packageconfigs cannot be both enabled")
+}
+
+PACKAGES =+ "${PN}-modplug ${PN}-openmpt123 ${PN}-openmpt123-doc"
+FILES_${PN}-modplug = "${libdir}/libopenmpt_modplug.so.*"
+FILES_${PN}-openmpt123 = "${bindir}/openmpt123"
+FILES_${PN}-openmpt123-doc = "${mandir}/man1/openmpt123*"
+
+# Since version 0.3, libopenmpt uses SemVer 2.0.0 versioning.
+# The SemVer versioning scheme is incompatible with Debian/Ubuntu
+# package version names.
+DEBIAN_NOAUTONAME_${PN} = "1"
+DEBIAN_NOAUTONAME_${PN}-modplug = "1"
+
+RDEPENDS_${PN}_libc-glibc = " \
+    glibc-gconv-cp1252 \
+    glibc-gconv-ibm437 \
+    glibc-gconv-iso8859-1 \
+    glibc-gconv-iso8859-15 \
+"
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/minidlna/minidlna.inc b/meta-openembedded/meta-multimedia/recipes-multimedia/minidlna/minidlna.inc
new file mode 100644
index 0000000..187ff53
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/minidlna/minidlna.inc
@@ -0,0 +1,41 @@
+DESCRIPTION = "MiniDLNA (aka ReadyDLNA) is server software with the aim of \
+being fully compliant with DLNA/UPnP-AV clients."
+LICENSE = "GPL-2.0|BSD"
+DEPENDS = "ffmpeg flac libav jpeg sqlite3 libexif libogg libid3tag libvorbis"
+
+# because it depends on libav which has commercial flag
+LICENSE_FLAGS = "commercial"
+
+inherit gettext autotools-brokensep update-rc.d systemd
+
+SRC_URI = "git://git.code.sf.net/p/minidlna/git;branch=master;module=git \
+           file://minidlna-daemon.init.d \
+           file://minidlna.service \
+           file://0001-Update-Gettext-version.patch \
+           "
+
+S = "${WORKDIR}/git"
+
+# This remove "--exclude=autopoint" option from autoreconf argument to avoid
+# configure.ac:30: error: required file './ABOUT-NLS' not found
+EXTRA_AUTORECONF = ""
+
+do_install_append(){
+    install -d ${D}${sysconfdir}
+    install -m 0755 minidlna.conf ${D}${sysconfdir}
+
+# Systemd script
+    install -d ${D}${nonarch_base_libdir}/systemd/system
+    install -m 0755 ${WORKDIR}/minidlna.service ${D}${nonarch_base_libdir}/systemd/system
+
+# Sysvinit script
+    install -d ${D}${sysconfdir}/init.d
+    install -m 0755 ${WORKDIR}/minidlna-daemon.init.d ${D}${sysconfdir}/init.d/minidlna
+
+}
+
+SYSTEMD_SERVICE_${PN} = "minidlna.service"
+
+INITSCRIPT_NAME = "minidlna"
+INITSCRIPT_PARAMS = "defaults 90"
+
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/minidlna/minidlna/0001-Update-Gettext-version.patch b/meta-openembedded/meta-multimedia/recipes-multimedia/minidlna/minidlna/0001-Update-Gettext-version.patch
new file mode 100644
index 0000000..c18095d
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/minidlna/minidlna/0001-Update-Gettext-version.patch
@@ -0,0 +1,34 @@
+From a4290bf1887f9203288858ca76bdd20b2edf337a Mon Sep 17 00:00:00 2001
+From: Baptiste Durand <baptiste.durand@gmail.com>
+Date: Sun, 9 Sep 2018 20:50:41 +0200
+Subject: [PATCH] Update Gettext version
+
+Upstream-Status: Inappropriate [oe-core specific]
+
+Signed-off-by: Baptiste Durand <baptiste.durand@gmail.com>
+---
+ configure.ac | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index f343d21..a556b33 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -14,7 +14,7 @@
+ # License along with MiniDLNA; if not, write to the Free Software
+ # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ # USA.
+-AC_INIT(MiniDLNA,1.1.3,,minidlna)
++AC_INIT(MiniDLNA,1.2.1,,minidlna)
+ #LT_INIT
+ 
+ AC_CANONICAL_TARGET
+@@ -28,7 +28,7 @@ m4_ifdef([AC_USE_SYSTEM_EXTENSIONS], [AC_USE_SYSTEM_EXTENSIONS])
+ 
+ AM_ICONV
+ AM_GNU_GETTEXT([external])
+-AM_GNU_GETTEXT_VERSION(0.18)
++AM_GNU_GETTEXT_VERSION(0.19)
+ 
+ # Checks for programs.
+ AC_PROG_AWK
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/minidlna/minidlna/minidlna-daemon.init.d b/meta-openembedded/meta-multimedia/recipes-multimedia/minidlna/minidlna/minidlna-daemon.init.d
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-multimedia/minidlna/minidlna/minidlna-daemon.init.d
rename to meta-openembedded/meta-multimedia/recipes-multimedia/minidlna/minidlna/minidlna-daemon.init.d
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/minidlna/minidlna/minidlna.service b/meta-openembedded/meta-multimedia/recipes-multimedia/minidlna/minidlna/minidlna.service
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-multimedia/minidlna/minidlna/minidlna.service
rename to meta-openembedded/meta-multimedia/recipes-multimedia/minidlna/minidlna/minidlna.service
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/minidlna/minidlna_1.2.1.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/minidlna/minidlna_1.2.1.bb
new file mode 100644
index 0000000..999d85c
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/minidlna/minidlna_1.2.1.bb
@@ -0,0 +1,4 @@
+require ${BPN}.inc
+
+SRCREV = "c760a338e07ebd11d62fef701e3de824a91f8625"
+LIC_FILES_CHKSUM = "file://LICENCE.miniupnpd;md5=b0dabf9d8e0f871554e309d62ead8d2b"
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/musicbrainz/libmusicbrainz_git.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/musicbrainz/libmusicbrainz_git.bb
index 16e5213..ca9d94a 100644
--- a/meta-openembedded/meta-multimedia/recipes-multimedia/musicbrainz/libmusicbrainz_git.bb
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/musicbrainz/libmusicbrainz_git.bb
@@ -22,10 +22,12 @@
     git clean -dfx -e /.pc/ -e /patches/ .
     mkdir build-native
     cd build-native
-    cmake -DCMAKE_C_FLAGS=${BUILD_CFLAGS} \
+    LDFLAGS="${BUILD_LDFLAGS}" \
+          cmake -DCMAKE_C_FLAGS=${BUILD_CFLAGS} \
           -DCMAKE_C_COMPILER=${BUILD_CC} \
           -DCMAKE_CXX_FLAGS=${BUILD_CXXFLAGS} \
           -DCMAKE_CXX_COMPILER=${BUILD_CXX} \
+          -DCMAKE_EXE_LINKER_FLAGS=${BUILD_LDFLAGS} \
           ..
     make make-c-interface
     cd ..
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/musicpd/libmpdclient_2.16.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/musicpd/libmpdclient_2.16.bb
new file mode 100644
index 0000000..455e76f
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/musicpd/libmpdclient_2.16.bb
@@ -0,0 +1,22 @@
+SUMMARY = "C client library for the Music Player Daemon"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=06b9dfd2f197dc514d8ef06549684b77"
+HOMEPAGE = "https://www.musicpd.org/libs/libmpdclient/"
+
+inherit meson
+
+SRC_URI = " \
+    git://github.com/MusicPlayerDaemon/libmpdclient \
+"
+SRCREV = "4e8d990eb5239566ee948f1cd79b7248e008620a"
+S = "${WORKDIR}/git"
+
+PACKAGECONFIG ??= "tcp"
+PACKAGECONFIG[tcp] = "-Dtcp=true,-Dtcp=false"
+
+do_install_append() {
+    # libmpdclient's Vala bindings are outdated and unmaintained; it
+    # is likely that nobody will ever use them, so let's not install
+    # them
+    rm -rf ${D}${datadir}/vala
+}
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/musicpd/mpc_0.31.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/musicpd/mpc_0.31.bb
new file mode 100644
index 0000000..41abe71
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/musicpd/mpc_0.31.bb
@@ -0,0 +1,16 @@
+SUMMARY = "A minimalist command line interface to the Music Player Daemon"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
+HOMEPAGE = "https://www.musicpd.org/clients/mpc/"
+
+inherit meson
+
+DEPENDS += " \
+    libmpdclient \
+"
+
+SRC_URI = " \
+    git://github.com/MusicPlayerDaemon/mpc \
+"
+SRCREV = "59875acdf34e5f0eac0c11453c49daef54f78413"
+S = "${WORKDIR}/git"
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/musicpd/mpd_0.20.18.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/musicpd/mpd_0.20.18.bb
deleted file mode 100644
index 6754f34..0000000
--- a/meta-openembedded/meta-multimedia/recipes-multimedia/musicpd/mpd_0.20.18.bb
+++ /dev/null
@@ -1,100 +0,0 @@
-SUMMARY = "Music Player Daemon"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
-HOMEPAGE ="http://www.musicpd.org"
-
-inherit autotools useradd systemd pkgconfig
-
-DEPENDS += " \
-    alsa-lib \
-    libsamplerate0 \
-    libsndfile1 \
-    libvorbis \
-    libogg \
-    faad2 \
-    ffmpeg \
-    curl \
-    sqlite \
-    bzip2 \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'pulseaudio', d)} \
-    tcp-wrappers \
-    openal-soft \
-    yajl \
-    jack \
-    faad2 \
-    flac \
-    libao \
-    fluidsynth \
-    libcdio \
-    wavpack \
-    libopus \
-    mpg123 \
-    libmms \
-    libmodplug \
-    boost \
-    icu \
-    dbus \
-    expat \
-    zlib \
-    libupnp \
-"
-
-# While this item does not require it, it depends on mpg123 which does
-LICENSE_FLAGS = "commercial"
-
-SRC_URI = " \
-    http://www.musicpd.org/download/${BPN}/0.20/${BP}.tar.xz \
-    file://mpd.conf.in \
-"
-SRC_URI[md5sum] = "8dc87ba95473fd738f2aff9bd69cc212"
-SRC_URI[sha256sum] = "6a582dc2ae90b94ff3853f9ffd7d80b2c2b5fe2e2c35cb1da0b36f3f3dfad434"
-
-EXTRA_OECONF = "enable_bzip2=yes"
-EXTRA_OECONF += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '--with-systemdsystemunitdir=${systemd_unitdir}/system/', '--without-systemdsystemunitdir', d)}"
-
-PACKAGECONFIG[audiofile] = "--enable-audiofile,--disable-audiofile,audiofile"
-PACKAGECONFIG[cdioparanoia] = "--enable-cdio-paranoia,--disable-cdio-paranoia,libcdio-paranoia"
-PACKAGECONFIG[mad] = "--enable-mad,--disable-mad,libmad"
-PACKAGECONFIG[id3tag] = "--enable-id3,--disable-id3,libid3tag"
-PACKAGECONFIG[lame] = "--enable-lame-encoder,--disable-lame-encoder,lame"
-PACKAGECONFIG[smb] = "--enable-smbclient,--disable-smbclient,samba"
-
-do_configure_prepend() {
-    sed -i -e 's|libsystemd-daemon|libsystemd|' ${S}/configure.ac
-}
-
-do_install_append() {
-    install -d ${D}/${localstatedir}/lib/mpd/music
-    chmod 775 ${D}/${localstatedir}/lib/mpd/music
-    install -d ${D}/${localstatedir}/lib/mpd/playlists
-    chown -R mpd ${D}/${localstatedir}/lib/mpd
-    chown mpd:mpd ${D}/${localstatedir}/lib/mpd/music
-
-    install -d ${D}/${sysconfdir}
-    install -m 644 ${WORKDIR}/mpd.conf.in ${D}/${sysconfdir}/mpd.conf
-    sed -i \
-        -e 's|%music_directory%|${localstatedir}/lib/mpd/music|' \
-        -e 's|%playlist_directory%|${localstatedir}/lib/mpd/playlists|' \
-        -e 's|%db_file%|${localstatedir}/lib/mpd/mpd.db|' \
-        -e 's|%log_file%|${localstatedir}/log/mpd.log|' \
-        -e 's|%state_file%|${localstatedir}/lib/mpd/state|' \
-        ${D}/${sysconfdir}/mpd.conf
-
-    if [ -e ${D}/${systemd_unitdir}/system/mpd.service ] ; then
-        sed -i \
-            's|^ExecStart=.*|ExecStart=${bindir}/mpd --no-daemon|' \
-            ${D}/${systemd_unitdir}/system/mpd.service
-    fi
-}
-
-RPROVIDES_${PN} += "${PN}-systemd"
-RREPLACES_${PN} += "${PN}-systemd"
-RCONFLICTS_${PN} += "${PN}-systemd"
-SYSTEMD_SERVICE_${PN} = "mpd.socket"
-
-USERADD_PACKAGES = "${PN}"
-USERADD_PARAM_${PN} = " \
-    --system --no-create-home \
-    --home ${localstatedir}/lib/mpd \
-    --groups audio \
-    --user-group mpd"
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/musicpd/mpd_0.20.22.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/musicpd/mpd_0.20.22.bb
new file mode 100644
index 0000000..6c6ad42
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/musicpd/mpd_0.20.22.bb
@@ -0,0 +1,99 @@
+SUMMARY = "Music Player Daemon"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
+HOMEPAGE ="http://www.musicpd.org"
+
+inherit autotools useradd systemd pkgconfig
+
+DEPENDS += " \
+    curl \
+    sqlite3 \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'pulseaudio', d)} \
+    yajl \
+    boost \
+    icu \
+    dbus \
+    expat \
+"
+
+SRC_URI = " \
+    git://github.com/MusicPlayerDaemon/MPD;branch=v0.20.x \
+    file://mpd.conf.in \
+"
+SRCREV = "9274bc15bc41bbe490fde847f8422468cc20375d"
+S = "${WORKDIR}/git"
+
+EXTRA_OECONF += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '--with-systemdsystemunitdir=${systemd_unitdir}/system/', '--without-systemdsystemunitdir', d)}"
+
+PACKAGECONFIG ??= "alsa ao bzip2 daemon ffmpeg fifo flac fluidsynth iso9660 jack libsamplerate libwrap httpd mms mpg123 modplug sndfile upnp openal opus oss recorder vorbis wavpack zlib"
+PACKAGECONFIG += "${@bb.utils.contains('LICENSE_FLAGS', 'commercial', 'aac', '', d)}"
+
+PACKAGECONFIG[aac] = "--enable-aac,--disable-aac,faad2"
+PACKAGECONFIG[alsa] = "--enable-alsa,--disable-alsa,alsa-lib"
+PACKAGECONFIG[ao] = "--enable-ao,--disable-ao,libao"
+PACKAGECONFIG[audiofile] = "--enable-audiofile,--disable-audiofile,audiofile"
+PACKAGECONFIG[bzip2] = "--enable-bzip2,--disable-bzip2,bzip2"
+PACKAGECONFIG[cdioparanoia] = "--enable-cdio-paranoia,--disable-cdio-paranoia,libcdio-paranoia"
+PACKAGECONFIG[daemon] = "--enable-daemon,--disable-daemon"
+PACKAGECONFIG[ffmpeg] = "--enable-ffmpeg,--disable-ffmpeg,ffmpeg"
+PACKAGECONFIG[fifo] = "--enable-fifo,--disable-fifo"
+PACKAGECONFIG[flac] = "--enable-flac,--disable-flac,flac"
+PACKAGECONFIG[fluidsynth] = "--enable-fluidsynth,--disable-fluidsynth,fluidsynth"
+PACKAGECONFIG[httpd] = "--enable-httpd-output,--disable-httpd-output"
+PACKAGECONFIG[id3tag] = "--enable-id3,--disable-id3,libid3tag"
+PACKAGECONFIG[iso9660] = "--enable-iso9660,--disable-iso9660,libcdio"
+PACKAGECONFIG[jack] = "--enable-jack,--disable-jack,jack"
+PACKAGECONFIG[lame] = "--enable-lame-encoder,--disable-lame-encoder,lame"
+PACKAGECONFIG[libsamplerate] = "--enable-lsr,--disable-lsr,libsamplerate0"
+PACKAGECONFIG[libwrap] = "--enable-libwrap,--disable-libwrap,tcp-wrappers"
+PACKAGECONFIG[mad] = "--enable-mad,--disable-mad,libmad"
+PACKAGECONFIG[mms] = "--enable-mms,--disable-mms,libmms"
+PACKAGECONFIG[modplug] = "--enable-modplug,--disable-modplug,libmodplug"
+PACKAGECONFIG[mpg123] = "--enable-mpg123,--disable-mpg123,mpg123"
+PACKAGECONFIG[openal] = "--enable-openal,--disable-openal,openal-soft"
+PACKAGECONFIG[opus] = "--enable-opus,--disable-opus,libopus libogg"
+PACKAGECONFIG[oss] = "--enable-oss,--disable-oss,"
+PACKAGECONFIG[recorder] = "--enable-recorder-output,--disable-recorder-output"
+PACKAGECONFIG[smb] = "--enable-smbclient,--disable-smbclient,samba"
+PACKAGECONFIG[sndfile] = "--enable-sndfile,--disable-sndfile,libsndfile1"
+PACKAGECONFIG[upnp] = "--enable-upnp,--disable-upnp,libupnp"
+PACKAGECONFIG[vorbis] = "--enable-vorbis,--disable-vorbis,libvorbis libogg"
+PACKAGECONFIG[wavpack] = "--enable-wavpack,--disable-wavpack,wavpack"
+PACKAGECONFIG[zlib] = "--enable-zlib,--disable-zlib,zlib"
+
+do_configure_prepend() {
+    sed -i -e 's|libsystemd-daemon|libsystemd|' ${S}/configure.ac
+}
+
+do_install_append() {
+    install -o mpd -d \
+        ${D}/${localstatedir}/lib/mpd \
+        ${D}/${localstatedir}/lib/mpd/playlists
+    install -m775 -o mpd -g mpd -d \
+        ${D}/${localstatedir}/lib/mpd/music
+
+    install -d ${D}/${sysconfdir}
+    install -m 644 ${WORKDIR}/mpd.conf.in ${D}/${sysconfdir}/mpd.conf
+    sed -i \
+        -e 's|%music_directory%|${localstatedir}/lib/mpd/music|' \
+        -e 's|%playlist_directory%|${localstatedir}/lib/mpd/playlists|' \
+        -e 's|%db_file%|${localstatedir}/lib/mpd/mpd.db|' \
+        -e 's|%log_file%|${localstatedir}/log/mpd.log|' \
+        -e 's|%state_file%|${localstatedir}/lib/mpd/state|' \
+        ${D}/${sysconfdir}/mpd.conf
+
+    # we don't need the icon
+    rm -rf ${D}${datadir}/icons
+}
+
+RPROVIDES_${PN} += "${PN}-systemd"
+RREPLACES_${PN} += "${PN}-systemd"
+RCONFLICTS_${PN} += "${PN}-systemd"
+SYSTEMD_SERVICE_${PN} = "mpd.socket"
+
+USERADD_PACKAGES = "${PN}"
+USERADD_PARAM_${PN} = " \
+    --system --no-create-home \
+    --home ${localstatedir}/lib/mpd \
+    --groups audio \
+    --user-group mpd"
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/musicpd/ncmpc_0.33.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/musicpd/ncmpc_0.33.bb
new file mode 100644
index 0000000..8468d12
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/musicpd/ncmpc_0.33.bb
@@ -0,0 +1,37 @@
+SUMMARY = "A curses client for the Music Player Daemon"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
+HOMEPAGE = "https://www.musicpd.org/clients/ncmpc/"
+
+inherit meson
+
+DEPENDS += " \
+    boost \
+    ncurses \
+    libmpdclient \
+"
+
+PACKAGECONFIG ??= "colors locale mouse nls regex help_screen artist_screen search_screen song_screen key_screen lyrics_screen outputs_screen"
+
+PACKAGECONFIG[colors] = "-Dcolors=true,-Dcolors=false"
+PACKAGECONFIG[lirc] = "-Dlirc=enabled,-Dlirc=disabled,lirc"
+PACKAGECONFIG[locale] = "-Dlocale=enabled,-Dlocale=disabled"
+PACKAGECONFIG[mini] = "-Dmini=true,-Dmini=false"
+PACKAGECONFIG[mouse] = "-Dmouse=enabled,-Dmouse=disabled"
+PACKAGECONFIG[nls] = "-Dnls=enabled,-Dnls=disabled,gettext-native"
+PACKAGECONFIG[regex] = "-Dregex=enabled,-Dregex=disabled,pcre"
+
+PACKAGECONFIG[help_screen] = "-Dhelp_screen=true,-Dhelp_screen=false"
+PACKAGECONFIG[artist_screen] = "-Dartist_screen=true,-Dartist_screen=false"
+PACKAGECONFIG[search_screen] = "-Dsearch_screen=true,-Dsearch_screen=false"
+PACKAGECONFIG[song_screen] = "-Dsong_screen=true,-Dsong_screen=false"
+PACKAGECONFIG[key_screen] = "-Dkey_screen=true,-Dkey_screen=false"
+PACKAGECONFIG[lyrics_screen] = "-Dlyrics_screen=true,-Dlyrics_screen=false"
+PACKAGECONFIG[outputs_screen] = "-Doutputs_screen=true,-Doutputs_screen=false"
+PACKAGECONFIG[chat_screen] = "-Dchat_screen=true,-Dchat_screen=false"
+
+SRC_URI = " \
+    git://github.com/MusicPlayerDaemon/ncmpc \
+"
+SRCREV = "8e98f89ff07b140e6357dab2a9a9f6432ae0e521"
+S = "${WORKDIR}/git"
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/rtmpdump/rtmpdump/fix-racing-build-issue.patch b/meta-openembedded/meta-multimedia/recipes-multimedia/rtmpdump/rtmpdump/fix-racing-build-issue.patch
index bb3d8b0..6e11c97 100644
--- a/meta-openembedded/meta-multimedia/recipes-multimedia/rtmpdump/rtmpdump/fix-racing-build-issue.patch
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/rtmpdump/rtmpdump/fix-racing-build-issue.patch
@@ -8,11 +8,11 @@
 ===================================================================
 --- git.orig/librtmp/Makefile
 +++ git/librtmp/Makefile
-@@ -107,6 +107,7 @@ install_base:	librtmp.a librtmp.pc
+@@ -115,6 +115,7 @@ install_base:	librtmp.a librtmp.pc
  	cp librtmp.3 $(MANDIR)/man3
  
- install_so:	librtmp.$(SO_EXT)
+ install_so:	librtmp$(SO_EXT)
 +	-mkdir -p $(SODIR)
- 	cp librtmp.$(SO_EXT) $(SODIR)
- 	cd $(SODIR); ln -sf librtmp.$(SO_EXT) librtmp.$(SOX)
- 
+ 	cp librtmp$(SO_EXT) $(SODIR)
+ 	$(INSTALL_IMPLIB)
+ 	cd $(SODIR); ln -sf librtmp$(SO_EXT) librtmp.$(SOX)
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/rtmpdump/rtmpdump_2.4.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/rtmpdump/rtmpdump_2.4.bb
index c5513b0..a72b0d6 100644
--- a/meta-openembedded/meta-multimedia/recipes-multimedia/rtmpdump/rtmpdump_2.4.bb
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/rtmpdump/rtmpdump_2.4.bb
@@ -5,9 +5,9 @@
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
 
-DEPENDS = "openssl zlib"
+DEPENDS = "openssl10 zlib"
 
-SRCREV = "3121324046e4ca1934e7e28293fc8326475d5053"
+SRCREV = "fa8646daeb19dfd12c181f7d19de708d623704c0"
 SRC_URI = " \
     git://git.ffmpeg.org/rtmpdump \
     file://fix-racing-build-issue.patch"
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/tinyalsa/tinyalsa.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/tinyalsa/tinyalsa.bb
new file mode 100644
index 0000000..157e4c9
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/tinyalsa/tinyalsa.bb
@@ -0,0 +1,24 @@
+DESCRIPTION = "TinyALSA is a small library to interface with ALSA in \
+the Linux kernel. It is a lightweight alternative to libasound."
+HOMEPAGE = "https://github.com/tinyalsa/tinyalsa"
+SECTION = "libs/multimedia"
+
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://NOTICE;md5=dbdefe400d894b510a9de14813181d0b"
+
+SRCREV = "67b9210d344c34e8d1aa0cfe638abce71c5221ca"
+SRC_URI = "git://github.com/tinyalsa/tinyalsa"
+PV = "1.1.1+git${SRCPV}"
+
+S = "${WORKDIR}/git"
+
+inherit cmake
+
+# tinyalsa is built as a static library. Enable PIC to avoid relocation
+# errors like these:
+#
+#    unresolvable R_AARCH64_ADR_PREL_PG_HI21 relocation against symbol `stderr@@GLIBC_2.17'
+CFLAGS += " -fPIC -DPIC "
+
+PACKAGES =+ "${PN}-tools"
+FILES_${PN}-tools = "${bindir}/*"
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/tinyalsa/tinyalsa_1.1.1.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/tinyalsa/tinyalsa_1.1.1.bb
deleted file mode 100644
index 66b95db..0000000
--- a/meta-openembedded/meta-multimedia/recipes-multimedia/tinyalsa/tinyalsa_1.1.1.bb
+++ /dev/null
@@ -1,28 +0,0 @@
-DESCRIPTION = "TinyALSA is a small library to interface with ALSA in \
-the Linux kernel. It is a lightweight alternative to libasound."
-HOMEPAGE = "https://github.com/tinyalsa/tinyalsa"
-SECTION = "libs/multimedia"
-
-LICENSE = "BSD-3-Clause"
-LIC_FILES_CHKSUM = "file://NOTICE;md5=dbdefe400d894b510a9de14813181d0b"
-
-S = "${WORKDIR}/git"
-SRCREV = "df11091086b56e5fb71887f2fa320e1d2ffeff58"
-SRC_URI = "git://github.com/tinyalsa/tinyalsa.git;protocol=https;"
-
-do_configure() {
-    :
-}
-
-do_compile() {
-    oe_runmake CC='${CC}' LD='${CC}' AR='${AR}'
-}
-
-do_install() {
-    oe_runmake install \
-        PREFIX="${prefix}" DESTDIR="${D}" INCDIR="${includedir}/tinyalsa" \
-        LIBDIR="${libdir}" BINDIR="${bindir}" MANDIR="${mandir}"
-}
-
-PACKAGES =+ "${PN}-tools"
-FILES_${PN}-tools = "${bindir}/*"
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/vlc/vlc.inc b/meta-openembedded/meta-multimedia/recipes-multimedia/vlc/vlc.inc
index 8e82b3b..f13c0ea 100644
--- a/meta-openembedded/meta-multimedia/recipes-multimedia/vlc/vlc.inc
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/vlc/vlc.inc
@@ -5,7 +5,7 @@
 LICENSE = "GPL-2.0"
 LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
 
-DEPENDS = "libfribidi libtool libgcrypt libgcrypt-native \
+DEPENDS = "fribidi libtool libgcrypt libgcrypt-native \
    dbus dbus-glib libxml2 gnutls \
    tremor faad2 ffmpeg flac fluidsynth alsa-lib \
    lua-native lua libidn \
diff --git a/meta-openembedded/meta-multimedia/recipes-multimedia/vorbis-tools/vorbis-tools_1.4.0.bb b/meta-openembedded/meta-multimedia/recipes-multimedia/vorbis-tools/vorbis-tools_1.4.0.bb
index e43cb40..8e9914b 100644
--- a/meta-openembedded/meta-multimedia/recipes-multimedia/vorbis-tools/vorbis-tools_1.4.0.bb
+++ b/meta-openembedded/meta-multimedia/recipes-multimedia/vorbis-tools/vorbis-tools_1.4.0.bb
@@ -8,7 +8,7 @@
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
 
-DEPENDS = "libogg libvorbis curl libao"
+DEPENDS = "libogg libvorbis"
 
 SRC_URI = "http://downloads.xiph.org/releases/vorbis/${BP}.tar.gz \
            file://0001-oggenc-Fix-large-alloca-on-bad-AIFF-input.patch \
@@ -20,6 +20,7 @@
 
 inherit autotools pkgconfig gettext
 
-PACKAGECONFIG ??= "flac"
+PACKAGECONFIG ??= "flac ogg123"
 PACKAGECONFIG[flac] = ",--without-flac,flac,libflac"
 PACKAGECONFIG[speex] = ",--without-speex,speex,speex"
+PACKAGECONFIG[ogg123] = "--enable-ogg123,--disable-ogg123,libao curl"
diff --git a/meta-openembedded/meta-multimedia/recipes-support/gst-instruments/gst-instruments_0.2.3.bb b/meta-openembedded/meta-multimedia/recipes-support/gst-instruments/gst-instruments_0.2.3.bb
deleted file mode 100644
index 07d0c55..0000000
--- a/meta-openembedded/meta-multimedia/recipes-support/gst-instruments/gst-instruments_0.2.3.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-SUMMARY = "Profiling utilities for GStreamer 1.0 pipelines"
-HOMEPAGE = "https://github.com/kirushyk/gst-instruments"
-SECTION = "multimedia"
-
-LICENSE = "LGPL-3.0"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=e6a600fd5e1d9cbde2d983680233ad02"
-
-DEPENDS = "gstreamer1.0"
-
-S = "${WORKDIR}/git"
-SRCREV = "4ce8092636ee6572148b5fa044080734cf5a6b8d"
-SRC_URI = "git://github.com/kirushyk/gst-instruments.git;protocol=https;"
-
-FILES_${PN}-staticdev += "${libdir}/gstreamer-1.0/*a"
-FILES_${PN} += "${libdir}/*"
-
-INSANE_SKIP_${PN} = "dev-so"
-
-inherit autotools pkgconfig
-
diff --git a/meta-openembedded/meta-multimedia/recipes-support/gst-instruments/gst-instruments_git.bb b/meta-openembedded/meta-multimedia/recipes-support/gst-instruments/gst-instruments_git.bb
new file mode 100644
index 0000000..feffa9f
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-support/gst-instruments/gst-instruments_git.bb
@@ -0,0 +1,20 @@
+SUMMARY = "Profiling utilities for GStreamer 1.0 pipelines"
+HOMEPAGE = "https://github.com/kirushyk/gst-instruments"
+SECTION = "multimedia"
+
+LICENSE = "LGPL-3.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=e6a600fd5e1d9cbde2d983680233ad02"
+
+DEPENDS = "gstreamer1.0"
+
+S = "${WORKDIR}/git"
+SRCREV = "3b862e52e5c53ad1023dc6808effa4cb75572c4b"
+SRC_URI = "git://github.com/kirushyk/gst-instruments.git;protocol=https;"
+
+FILES_${PN}-staticdev += "${libdir}/gstreamer-1.0/*a"
+FILES_${PN} += "${libdir}/*"
+
+INSANE_SKIP_${PN} = "dev-so"
+
+inherit autotools pkgconfig
+
diff --git a/meta-openembedded/meta-multimedia/recipes-support/libsrtp/libsrtp_1.5.2.bb b/meta-openembedded/meta-multimedia/recipes-support/libsrtp/libsrtp_1.5.2.bb
deleted file mode 100644
index ee8c68b..0000000
--- a/meta-openembedded/meta-multimedia/recipes-support/libsrtp/libsrtp_1.5.2.bb
+++ /dev/null
@@ -1,22 +0,0 @@
-DESCRIPTION = "library implementing Secure RTP (RFC 3711)"
-HOMEPAGE = "https://github.com/cisco/libsrtp"
-SECTION = "libs"
-
-LICENSE = "BSD-3-Clause"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=15bc16b9d2e305974dde47e733883714"
-
-S = "${WORKDIR}/git"
-SRCREV = "e806a66bad35f4b215b7a825c24ef0ec4cc19569"
-SRC_URI = "git://github.com/cisco/libsrtp.git;protocol=https; \
-           file://0001-Rename-conflicting-variable-mips.patch \
-           "
-
-inherit autotools
-
-do_install[postfuncs] += " rm_unused_bindir "
-
-rm_unused_bindir() {
-    rmdir ${D}/${bindir}
-}
-
-ALLOW_EMPTY_${PN} = "1"
diff --git a/meta-openembedded/meta-multimedia/recipes-support/libsrtp/libsrtp_1.6.0.bb b/meta-openembedded/meta-multimedia/recipes-support/libsrtp/libsrtp_1.6.0.bb
new file mode 100644
index 0000000..d3ab5b7
--- /dev/null
+++ b/meta-openembedded/meta-multimedia/recipes-support/libsrtp/libsrtp_1.6.0.bb
@@ -0,0 +1,16 @@
+DESCRIPTION = "library implementing Secure RTP (RFC 3711)"
+HOMEPAGE = "https://github.com/cisco/libsrtp"
+SECTION = "libs"
+
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=15bc16b9d2e305974dde47e733883714"
+
+S = "${WORKDIR}/git"
+SRCREV = "2b091a4fb21c9b06fc5d4b5763bdaec97542fcd7"
+SRC_URI = "git://github.com/cisco/libsrtp.git;protocol=https;branch=1_6_x_throttle; \
+           file://0001-Rename-conflicting-variable-mips.patch \
+           "
+
+inherit autotools
+
+ALLOW_EMPTY_${PN} = "1"
diff --git a/meta-openembedded/meta-networking/MAINTAINERS b/meta-openembedded/meta-networking/MAINTAINERS
index bbb2d1b..945ee86 100644
--- a/meta-openembedded/meta-networking/MAINTAINERS
+++ b/meta-openembedded/meta-networking/MAINTAINERS
@@ -2,34 +2,12 @@
 
 Please submit any patches against meta-networking to the OpenEmbedded
 development mailing list (openembedded-devel@lists.openembedded.org) with
-'[meta-networking]' in the subject.
+'[meta-networking][thud]' in the subject.
 
 When sending single patches, please use something like:
 
    git send-email -1 -M \
         --to openembedded-devel@lists.openembedded.org \
-        --subject-prefix=meta-networking][PATCH
+        --subject-prefix=meta-networking][thud][PATCH
 
-You may also contact the maintainers directly.
-
-Descriptions of section entries:
-
-        M: Mail patches to: FullName <address@domain>
-        F: Files and directories with wildcard patterns.
-           A trailing slash includes all files and subdirectory files.
-           F: recipes-devtools/    all files in and below recipes-devtools
-           F: recipes-selinux/*    all files in recipes-selinux, but not below
-           One pattern per line.  Multiple F: lines acceptable.
-
-Please keep this list in alphabetical order.
-
-Maintainers List (try to look for most precise areas first)
-
-COMMON
-M:      Joe MacDonald <joe_macdonald@mentor.com>
-F:      conf
-F:      recipes-*
-
-NETKIT
-M:      Armin Kuster <akuster808@gmail.com>
-F:      recipes-netkit
+Thud Maintainer:      Armin Kuster <akuster808@gmail.com>
diff --git a/meta-openembedded/meta-networking/README b/meta-openembedded/meta-networking/README
index e1ba27d..7a4aca4 100644
--- a/meta-openembedded/meta-networking/README
+++ b/meta-openembedded/meta-networking/README
@@ -18,19 +18,19 @@
 This layer depends on:
 
 URI: git://github.com/openembedded/openembedded-core.git
-branch: master
+branch: thud
 revision: HEAD
 
 For some recipes, the meta-oe layer is required:
 
 URI: git://github.com/openembedded/meta-openembedded.git
 subdirectory: meta-oe
-branch: master
+branch: thud
 revision: HEAD
 
 URI: git://github.com/openembedded/meta-openembedded.git
 subdirectory: meta-python
-branch: master
+branch: thud
 revision: HEAD
 
 Maintenance
diff --git a/meta-openembedded/meta-networking/classes/kernel_wireless_regdb.bbclass b/meta-openembedded/meta-networking/classes/kernel_wireless_regdb.bbclass
new file mode 100644
index 0000000..1238172
--- /dev/null
+++ b/meta-openembedded/meta-networking/classes/kernel_wireless_regdb.bbclass
@@ -0,0 +1,20 @@
+# Linux kernels before v4.15, allowed to be compiled with static
+# regulatory database if it was put under net/wireless/db.txt.
+#
+# This class copies the regulatory plaintext database to kernel sources before
+# compiling.
+#
+# Usage:
+# 1. The class should be inherited by kernel recipe (e.g. in
+#    linux-yocto_%.bbappend).
+# 2. For Linux kernels up to v4.14, build kernel with CONFIG_EXPERT and
+#    CONFIG_CFG80211_INTERNAL_REGDB.
+
+DEPENDS += "wireless-regdb-native"
+
+SRCTREECOVEREDTASKS += "do_kernel_add_regdb"
+do_kernel_add_regdb() {
+    cp ${STAGING_LIBDIR_NATIVE}/crda/db.txt ${S}/net/wireless/db.txt
+}
+do_kernel_add_regdb[dirs] = "${S}"
+addtask kernel_add_regdb before do_build after do_configure
diff --git a/meta-openembedded/meta-networking/conf/layer.conf b/meta-openembedded/meta-networking/conf/layer.conf
index e594b7b..d36ff5b 100644
--- a/meta-openembedded/meta-networking/conf/layer.conf
+++ b/meta-openembedded/meta-networking/conf/layer.conf
@@ -17,7 +17,7 @@
 LAYERDEPENDS_networking-layer += "openembedded-layer"
 LAYERDEPENDS_networking-layer += "meta-python"
 
-LAYERSERIES_COMPAT_networking-layer = "sumo"
+LAYERSERIES_COMPAT_networking-layer = "thud"
 
 LICENSE_PATH += "${LAYERDIR}/licenses"
 
diff --git a/meta-openembedded/meta-networking/files/waf-cross-answers/cross-answers-armeb.txt b/meta-openembedded/meta-networking/files/waf-cross-answers/cross-answers-armeb.txt
new file mode 100644
index 0000000..a5cd998
--- /dev/null
+++ b/meta-openembedded/meta-networking/files/waf-cross-answers/cross-answers-armeb.txt
@@ -0,0 +1,40 @@
+Checking uname sysname type: "Linux"
+Checking uname version type: "# Wed May 20 10:34:39 UTC 2015"
+Checking simple C program: "hello world"
+rpath library support: OK
+-Wl,--version-script support: OK
+Checking getconf LFS_CFLAGS: NO
+Checking correct behavior of strtoll: NO
+Checking for working strptime: OK
+Checking for C99 vsnprintf: "1"
+Checking for HAVE_SHARED_MMAP: OK
+Checking for HAVE_MREMAP: OK
+Checking for HAVE_SECURE_MKSTEMP: OK
+Checking for HAVE_IFACE_GETIFADDRS: NO
+Checking for HAVE_IFACE_IFCONF: NO
+Checking for HAVE_IFACE_IFREQ: NO
+Checking for large file support without additional flags: NO
+Checking for -D_FILE_OFFSET_BITS=64: OK
+Checking for HAVE_INCOHERENT_MMAP: NO
+Checking value of NSIG: "65"
+Checking value of _NSIG: "65"
+Checking value of SIGRTMAX: "64"
+Checking value of SIGRTMIN: "34"
+Checking whether the WRFILE -keytab is supported: OK
+Checking for kernel change notify support: OK
+Checking for Linux kernel oplocks: OK
+Checking for kernel share modes: OK
+Checking whether POSIX capabilities are available: OK
+Checking if can we convert from CP850 to UCS-2LE: OK
+Checking if can we convert from UTF-8 to UCS-2LE: OK
+vfs_fileid checking for statfs() and struct statfs.f_fsid: OK
+Checking whether we can use Linux thread-specific credentials with 32-bit system calls: OK
+Checking whether fcntl locking is available: OK
+Checking for the maximum value of the 'time_t' type: NO
+Checking whether the realpath function allows a NULL argument: OK
+Checking for ftruncate extend: OK
+getcwd takes a NULL argument: OK
+Checking for small off_t: NO
+Checking whether blkcnt_t is 32 bit: NO
+Checking whether blkcnt_t is 64 bit: OK
+Checking whether fcntl lock supports open file description locks: OK
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/blueman/blueman/0001-Search-for-cython3.patch b/meta-openembedded/meta-networking/recipes-connectivity/blueman/blueman/0001-Search-for-cython3.patch
new file mode 100644
index 0000000..269174b
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/blueman/blueman/0001-Search-for-cython3.patch
@@ -0,0 +1,31 @@
+From 77db892cdee265e971270c06ca1ffbaeea6449a3 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
+Date: Tue, 26 Jun 2018 00:27:40 +0200
+Subject: [PATCH] Search for cython3
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Upstream-Status: Pending
+
+Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index 727089d1..6b565cdc 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -58,7 +58,7 @@ AC_SUBST([PYGOBJECT_LIBS])
+ 
+ AC_ARG_VAR([CYTHONEXEC], [Cython compiler])
+ if test "x$CYTHONEXEC" = "x"; then
+-   AC_PATH_PROG([CYTHONEXEC],[cython])
++   AC_PATH_PROG([CYTHONEXEC],[cython3])
+ fi
+ AC_SUBST([CYTHONEXEC])
+ AC_MSG_CHECKING([for cython executable])
+-- 
+2.14.3
+
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/blueman/blueman_git.bb b/meta-openembedded/meta-networking/recipes-connectivity/blueman/blueman_git.bb
new file mode 100644
index 0000000..947db78
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/blueman/blueman_git.bb
@@ -0,0 +1,41 @@
+DESCRIPTION = "Blueman is a GTK+ Bluetooth Manager"
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
+
+DEPENDS = "bluez5 python3-pygobject python3-cython-native python3-setuptools-native intltool-native"
+
+inherit autotools systemd gsettings python3native gtk-icon-cache
+
+SRC_URI = " \
+    git://github.com/blueman-project/blueman.git \
+    file://0001-Search-for-cython3.patch \
+"
+SRCREV = "c4a03417e81e21543d4568e8e7f7de307582eb50"
+PV = "2.0.5+git${SRCPV}"
+S = "${WORKDIR}/git"
+
+EXTRA_OECONF = " \
+    --disable-runtime-deps-check \
+    --disable-schemas-compile \
+"
+
+SYSTEMD_SERVICE_${PN} = "${BPN}-mechanism.service"
+SYSTEMD_AUTO_ENABLE_${PN} = "disable"
+
+RRECOMENDS_${PN} += "adwaita-icon-theme"
+RDEPENDS_${PN} += " \
+    python3-dbus \
+    packagegroup-tools-bluetooth \
+"
+
+PACKAGECONFIG[thunar] = "--enable-thunar-sendto,--disable-thunar-sendto,,thunar"
+
+FILES_${PN} += " \
+    ${datadir}/dbus-1 \
+    ${datadir}/Thunar \
+    ${systemd_user_unitdir} \
+    ${exec_prefix}${systemd_system_unitdir} \
+    ${PYTHON_SITEPACKAGES_DIR} \
+"
+
+FILES_${PN}-staticdev += "${PYTHON_SITEPACKAGES_DIR}/_blueman.a"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/civetweb/civetweb/0001-Unittest-Link-librt-and-libm-using-l-option.patch b/meta-openembedded/meta-networking/recipes-connectivity/civetweb/civetweb/0001-Unittest-Link-librt-and-libm-using-l-option.patch
new file mode 100644
index 0000000..eecbc14
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/civetweb/civetweb/0001-Unittest-Link-librt-and-libm-using-l-option.patch
@@ -0,0 +1,40 @@
+From 21e9a4bb214648ffd43c66b535fbf096bfcc9f4f Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 24 Jun 2018 00:04:37 -0700
+Subject: [PATCH] Unittest: Link librt and libm using -l option
+
+cmake'ry forces full path to .so files when found using
+find_package and since we have proper sysrooted toolchain
+-lm and -lrt is all we need
+
+Upstream-Status: Inappropriate [Cross compile specific]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ unittest/CMakeLists.txt | 10 ++--------
+ 1 file changed, 2 insertions(+), 8 deletions(-)
+
+diff --git a/unittest/CMakeLists.txt b/unittest/CMakeLists.txt
+index c4cdf229..e1b63caf 100644
+--- a/unittest/CMakeLists.txt
++++ b/unittest/CMakeLists.txt
+@@ -57,14 +57,8 @@ elseif (WIN32)
+ else()
+   set(CHECK_LIBRARIES "${CHECK_INSTALL_DIR}/lib/libcheck.a")
+ endif()
+-find_package(LibM)
+-if (LIBM_FOUND)
+-  set(CHECK_LIBRARIES "${CHECK_LIBRARIES};LIBM::LIBM")
+-endif()
+-find_package(LibRt)
+-if (LIBRT_FOUND)
+-  set(CHECK_LIBRARIES "${CHECK_LIBRARIES};LIBRT::LIBRT")
+-endif()
++set(CHECK_LIBRARIES "${CHECK_LIBRARIES};-lm")
++set(CHECK_LIBRARIES "${CHECK_LIBRARIES};-lrt")
+ 
+ # Build the C unit tests
+ add_library(shared-c-unit-tests STATIC shared.c)
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/civetweb/civetweb/0001-undefine-macro-before-redefining.patch b/meta-openembedded/meta-networking/recipes-connectivity/civetweb/civetweb/0001-undefine-macro-before-redefining.patch
new file mode 100644
index 0000000..8653302
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/civetweb/civetweb/0001-undefine-macro-before-redefining.patch
@@ -0,0 +1,26 @@
+From 59f65235a7a690f50d1686e9977908c053697d8c Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 28 Aug 2018 22:59:13 -0700
+Subject: [PATCH] undefine macro before redefining
+
+Fixes
+src/main.c:89:9: error: 'printf' macro redefined [-Werror,-Wmacro-redefined]
+
+Upstream-Stats: Submitted [https://github.com/civetweb/civetweb/pull/649]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/main.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/main.c b/src/main.c
+index bbcb0aec..01191a3c 100644
+--- a/src/main.c
++++ b/src/main.c
+@@ -86,6 +86,7 @@
+ 
+ #include "civetweb.h"
+ 
++#undef printf
+ #define printf                                                                 \
+ 	DO_NOT_USE_THIS_FUNCTION__USE_fprintf /* Required for unit testing */
+ 
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/civetweb/civetweb_git.bb b/meta-openembedded/meta-networking/recipes-connectivity/civetweb/civetweb_git.bb
new file mode 100644
index 0000000..d681f7f
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/civetweb/civetweb_git.bb
@@ -0,0 +1,43 @@
+SUMMARY = "Civetweb embedded web server"
+HOMEPAGE = "https://github.com/civetweb/civetweb"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE.md;md5=6f28fdcba0dda735eed62bac6a397562"
+
+SRCREV = "19f31ba8dd8443e86c7028a4b4c37f4b299aa68c"
+PV = "1.10+git${SRCPV}"
+SRC_URI = "git://github.com/civetweb/civetweb.git \
+           file://0001-Unittest-Link-librt-and-libm-using-l-option.patch \
+           file://0001-undefine-macro-before-redefining.patch \
+           "
+
+S = "${WORKDIR}/git"
+
+# civetweb supports building with make or cmake (although cmake lacks few features)
+inherit cmake
+
+# Disable Lua and Duktape because they do not compile from CMake (as of v1.8, v1.9 and v1.10).
+# Disable ASAN as it is included only in Debug build.
+EXTRA_OECMAKE = " \
+    -DBUILD_SHARED_LIBS=ON \
+    -DCIVETWEB_ENABLE_DUKTAPE=OFF \
+    -DCIVETWEB_ENABLE_LUA=OFF \
+    -DCIVETWEB_ENABLE_ASAN=OFF \
+    -DCIVETWEB_BUILD_TESTING=OFF \
+"
+
+# Building with ninja fails on missing third_party/lib/libcheck.a (which
+# should come from external CMake project)
+OECMAKE_GENERATOR = "Unix Makefiles"
+
+PACKAGECONFIG ??= "caching ipv6 server ssl websockets"
+PACKAGECONFIG[caching] = "-DCIVETWEB_DISABLE_CACHING=OFF,-DCIVETWEB_DISABLE_CACHING=ON,"
+PACKAGECONFIG[cgi] = "-DCIVETWEB_DISABLE_CGI=OFF,-DCIVETWEB_DISABLE_CGI=ON,"
+PACKAGECONFIG[cpp] = "-DCIVETWEB_ENABLE_CXX=ON,-DCIVETWEB_ENABLE_CXX=OFF,"
+PACKAGECONFIG[debug] = "-DCIVETWEB_ENABLE_MEMORY_DEBUGGING=ON,-DCIVETWEB_ENABLE_MEMORY_DEBUGGING=OFF,"
+PACKAGECONFIG[ipv6] = "-DCIVETWEB_ENABLE_IPV6=ON,-DCIVETWEB_ENABLE_IPV6=OFF,"
+PACKAGECONFIG[server] = "-DCIVETWEB_INSTALL_EXECUTABLE=ON,-DCIVETWEB_INSTALL_EXECUTABLE=OFF,"
+PACKAGECONFIG[ssl] = "-DCIVETWEB_ENABLE_SSL=ON -DCIVETWEB_SSL_OPENSSL_API_1_1=OFF -DCIVETWEB_ENABLE_SSL_DYNAMIC_LOADING=OFF,-DCIVETWEB_ENABLE_SSL=OFF,openssl (=1.0.2%),"
+PACKAGECONFIG[websockets] = "-DCIVETWEB_ENABLE_WEBSOCKETS=ON,-DCIVETWEB_ENABLE_WEBSOCKETS=OFF,"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/crda/crda_3.18.bb b/meta-openembedded/meta-networking/recipes-connectivity/crda/crda_3.18.bb
index 82a297b..d5d2ab6 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/crda/crda_3.18.bb
+++ b/meta-openembedded/meta-networking/recipes-connectivity/crda/crda_3.18.bb
@@ -4,7 +4,10 @@
 LICENSE = "copyleft-next-0.3.0"
 LIC_FILES_CHKSUM = "file://copyleft-next-0.3.0;md5=8743a2c359037d4d329a31e79eabeffe"
 
-DEPENDS = "python-m2crypto-native python-typing-native python-native libgcrypt libnl openssl"
+DEPENDS = "python-m2crypto-native python-typing-native python-native libnl \
+           ${@oe.utils.conditional("DEFAULT_CRYPT", "gcrypt", "libgcrypt", "", d)} \
+           ${@oe.utils.conditional("DEFAULT_CRYPT", "openssl", "openssl10", "", d)} \
+          "
 
 SRC_URI = "https://www.kernel.org/pub/software/network/${BPN}/${BP}.tar.xz \
            file://do-not-run-ldconfig-if-destdir-is-set.patch \
@@ -18,10 +21,15 @@
 SRC_URI[md5sum] = "0431fef3067bf503dfb464069f06163a"
 SRC_URI[sha256sum] = "43fcb9679f8b75ed87ad10944a506292def13e4afb194afa7aa921b01e8ecdbf"
 
-inherit python-dir pythonnative
+inherit python-dir pythonnative siteinfo
+
+# "gcrypt" or "openssl"
+DEFAULT_CRYPT ??= "gcrypt"
+
 # Recursive make problem
-EXTRA_OEMAKE = "MAKEFLAGS= DESTDIR=${D} LIBDIR=${libdir}/crda LDLIBREG='-Wl,-rpath,${libdir}/crda -lreg'"
-EXTRA_OEMAKE_append = " USE_OPENSSL=1"
+EXTRA_OEMAKE = "MAKEFLAGS= DESTDIR=${D} LIBDIR=${libdir}/crda LDLIBREG='-Wl,-rpath,${libdir}/crda -lreg' \
+                UDEV_RULE_DIR=${nonarch_libdir}/udev/rules.d/"
+EXTRA_OEMAKE_append = " ${@oe.utils.conditional("DEFAULT_CRYPT", "openssl", "USE_OPENSSL=1", "", d)}"
 TARGET_BITS = "${SITEINFO_BITS}"
 export TARGET_BITS
 
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/daq/daq_2.0.6.bb b/meta-openembedded/meta-networking/recipes-connectivity/daq/daq_2.0.6.bb
index ec35175..42ffb17 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/daq/daq_2.0.6.bb
+++ b/meta-openembedded/meta-networking/recipes-connectivity/daq/daq_2.0.6.bb
@@ -6,7 +6,7 @@
 
 PARALLEL_MAKE = ""
 
-DEPENDS = "libpcap libpcre libdnet"
+DEPENDS = "libpcap libpcre libdnet bison-native"
 
 SRC_URI = "http://fossies.org/linux/misc/daq-${PV}.tar.gz \
            file://disable-run-test-program-while-cross-compiling.patch \
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/freeradius/files/0001-freeradius-correct-version-number-of-libssl-defect.patch b/meta-openembedded/meta-networking/recipes-connectivity/freeradius/files/0001-freeradius-correct-version-number-of-libssl-defect.patch
new file mode 100644
index 0000000..9e1f5b2
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/freeradius/files/0001-freeradius-correct-version-number-of-libssl-defect.patch
@@ -0,0 +1,44 @@
+From fecf974b63f72eeb12d3b43522e948ca2bc704d4 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Thu, 11 Oct 2018 09:45:52 +0800
+Subject: [PATCH] freeradius: correct version number of libssl defect
+
+Upstream-Status: Backport [https://github.com/FreeRADIUS/freeradius-server
+                 /commit/ad039347beca4ded297813a1da6eabb61fcf2ddd]
+
+upstream have refactored this part code into
+src/lib/tls/base.c, and problem also have fixed
+by commit ad039347beca
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ src/main/tls.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/src/main/tls.c b/src/main/tls.c
+index acbfe79..d9c91f1 100644
+--- a/src/main/tls.c
++++ b/src/main/tls.c
+@@ -72,15 +72,15 @@ typedef struct libssl_defect {
+ static libssl_defect_t libssl_defects[] =
+ {
+ 	{
+-		.low		= 0x01010101f,		/* 1.1.0a */
+-		.high		= 0x01010101f,		/* 1.1.0a */
++		.low		= 0x01010001f,		/* 1.1.0a */
++		.high		= 0x01010001f,		/* 1.1.0a */
+ 		.id		= "CVE-2016-6309",
+ 		.name		= "OCSP status request extension",
+ 		.comment	= "For more information see https://www.openssl.org/news/secadv/20160926.txt"
+ 	},
+ 	{
+-		.low		= 0x01010100f,		/* 1.1.0  */
+-		.high		= 0x01010100f,		/* 1.1.0  */
++		.low		= 0x010100000f,		/* 1.1.0  */
++		.high		= 0x01010000f,		/* 1.1.0  */
+ 		.id		= "CVE-2016-6304",
+ 		.name		= "OCSP status request extension",
+ 		.comment	= "For more information see https://www.openssl.org/news/secadv/20160922.txt"
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/freeradius/files/freeradius-configure.ac-allow-cross-compilation.patch b/meta-openembedded/meta-networking/recipes-connectivity/freeradius/files/freeradius-configure.ac-allow-cross-compilation.patch
index 30497a6..38e7c36 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/freeradius/files/freeradius-configure.ac-allow-cross-compilation.patch
+++ b/meta-openembedded/meta-networking/recipes-connectivity/freeradius/files/freeradius-configure.ac-allow-cross-compilation.patch
@@ -1,3 +1,6 @@
+From 0780b7053fb0d33d721aa70ab2ecd75299e5ba31 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Tue, 24 Jul 2018 15:03:39 +0800
 Subject: [PATCH] configure.ac: allow cross-compilation
 
 The checking OpenSSL library and header version consistency will
@@ -8,17 +11,20 @@
 
 Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
 Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
+
+update to new version 3.0.17 to fix patch warning
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
 ---
  src/modules/rlm_krb5/configure.ac | 3 ++-
  1 file changed, 2 insertions(+), 1 deletion(-)
 
 diff --git a/src/modules/rlm_krb5/configure.ac b/src/modules/rlm_krb5/configure.ac
-index eb43534..113a079 100644
+index efc9f29..98a97e4 100644
 --- a/src/modules/rlm_krb5/configure.ac
 +++ b/src/modules/rlm_krb5/configure.ac
 @@ -137,7 +137,8 @@ if test x$with_[]modname != xno; then
  		FR_SMART_CHECK_LIB(krb5, krb5_is_thread_safe)
- 		if test "x$ac_cv_lib_krb5_krb5_is_thread_safe" == xyes; then
+ 		if test "x$ac_cv_lib_krb5_krb5_is_thread_safe" = xyes; then
  			AC_RUN_IFELSE([AC_LANG_PROGRAM([[#include <krb5.h>]], [[return krb5_is_thread_safe() ? 0 : 1]])],
 -				[krb5threadsafe="-DKRB5_IS_THREAD_SAFE"], [AC_MSG_WARN([[libkrb5 is not threadsafe]])])
 +				[krb5threadsafe="-DKRB5_IS_THREAD_SAFE"], [AC_MSG_WARN([[libkrb5 is not threadsafe]])],
@@ -27,5 +33,5 @@
  	else
  		krb5threadsafe=""
 -- 
-2.10.2
+2.7.4
 
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/freeradius/files/freeradius-fix-issues-related-to-m4-include-path.patch b/meta-openembedded/meta-networking/recipes-connectivity/freeradius/files/freeradius-fix-issues-related-to-m4-include-path.patch
index d29b2ac..638d950 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/freeradius/files/freeradius-fix-issues-related-to-m4-include-path.patch
+++ b/meta-openembedded/meta-networking/recipes-connectivity/freeradius/files/freeradius-fix-issues-related-to-m4-include-path.patch
@@ -1,32 +1,33 @@
-From d8e251ef97869ab2c1c82bd374016f402083997c Mon Sep 17 00:00:00 2001
-From: Jorge Pereira <jpereiran@gmail.com>
-Date: Mon, 7 Dec 2015 16:51:07 -0200
-Subject: [PATCH] Fixing issues related to m4 include path
+From 69cb6d4bb5dd56a48695c0581a7d853e427b0ea3 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Tue, 24 Jul 2018 14:54:41 +0800
+Subject: [PATCH] freeradius: Fixing issues related to m4 include path
 
 Upstream-Status: Submitted [1]
 
 [1]: https://github.com/FreeRADIUS/freeradius-server/pull/1428
 
 Submmited by: Jorge Pereira <jpereiran@gmail.com>
+
+Update to version 3.0.17
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
 ---
- src/modules/rlm_example/config.h.in                | 39 ++--------------------
- src/modules/rlm_ldap/configure                     |  2 +-
- src/modules/rlm_pam/config.h.in                    |  3 ++
- src/modules/rlm_perl/config.h.in                   |  3 ++
- src/modules/rlm_perl/configure.ac                  |  2 +-
- src/modules/rlm_radutmp/config.h.in                |  3 ++
- src/modules/rlm_ruby/configure                     |  1 +
- src/modules/rlm_ruby/configure.ac                  |  9 ++---
- src/modules/rlm_smsotp/config.h.in                 |  3 ++
- .../rlm_sql/drivers/rlm_sql_mysql/config.h.in      |  3 ++
- src/modules/rlm_unix/config.h.in                   |  6 ++++
- 11 files changed, 32 insertions(+), 42 deletions(-)
+ src/modules/rlm_example/config.h.in | 35 +++--------------------------------
+ src/modules/rlm_pam/config.h.in     |  3 +++
+ src/modules/rlm_perl/config.h.in    |  3 +++
+ src/modules/rlm_perl/configure.ac   |  2 +-
+ src/modules/rlm_radutmp/config.h.in |  3 +++
+ src/modules/rlm_ruby/configure.ac   |  8 ++++----
+ src/modules/rlm_smsotp/config.h.in  |  3 +++
+ src/modules/rlm_unix/config.h.in    |  3 +++
+ 8 files changed, 23 insertions(+), 37 deletions(-)
 
 diff --git a/src/modules/rlm_example/config.h.in b/src/modules/rlm_example/config.h.in
-index 2a81ef5..f80de9c 100644
+index 2a81ef5..4dbb8f4 100644
 --- a/src/modules/rlm_example/config.h.in
 +++ b/src/modules/rlm_example/config.h.in
-@@ -1,38 +1,5 @@
+@@ -1,37 +1,5 @@
  /* config.h.in.  Generated from configure.ac by autoheader.  */
  
 -/* Define to 1 if you have the <inttypes.h> header file. */
@@ -61,11 +62,10 @@
 -
 -/* Define to 1 if you have the <unistd.h> header file. */
 -#undef HAVE_UNISTD_H
--
+ 
  /* Define to the address where bug reports for this package should be sent. */
  #undef PACKAGE_BUGREPORT
- 
-@@ -45,8 +12,8 @@
+@@ -45,6 +13,9 @@
  /* Define to the one symbol short name of this package. */
  #undef PACKAGE_TARNAME
  
@@ -74,22 +74,7 @@
 +
  /* Define to the version of this package. */
  #undef PACKAGE_VERSION
--
--/* Define to 1 if you have the ANSI C header files. */
--#undef STDC_HEADERS
-diff --git a/src/modules/rlm_ldap/configure b/src/modules/rlm_ldap/configure
-index e0c15d9..cdf96d5 100755
---- a/src/modules/rlm_ldap/configure
-+++ b/src/modules/rlm_ldap/configure
-@@ -3992,7 +3992,7 @@ smart_prefix=
- $as_echo "#define WITH_SASL 1" >>confdefs.h
  
- 	    SASL=sasl.c
--          fi
-+	  fi
- 	fi
- 
- 	targetname=rlm_ldap
 diff --git a/src/modules/rlm_pam/config.h.in b/src/modules/rlm_pam/config.h.in
 index 32ef6ff..1ad20c5 100644
 --- a/src/modules/rlm_pam/config.h.in
@@ -118,7 +103,7 @@
  /* Define to the version of this package. */
  #undef PACKAGE_VERSION
 diff --git a/src/modules/rlm_perl/configure.ac b/src/modules/rlm_perl/configure.ac
-index 44c5fc9..6b2a043 100644
+index 4b3ff42..69c79cb 100644
 --- a/src/modules/rlm_perl/configure.ac
 +++ b/src/modules/rlm_perl/configure.ac
 @@ -3,7 +3,7 @@ AC_INIT(rlm_perl.c)
@@ -144,23 +129,11 @@
  /* Define to the version of this package. */
  #undef PACKAGE_VERSION
  
-diff --git a/src/modules/rlm_ruby/configure b/src/modules/rlm_ruby/configure
-index 15868ab..c728af2 100755
---- a/src/modules/rlm_ruby/configure
-+++ b/src/modules/rlm_ruby/configure
-@@ -1875,6 +1875,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
- 
- 
- 
-+
- # ===========================================================================
- #    http://www.gnu.org/software/autoconf-archive/ax_compare_version.html
- # ===========================================================================
 diff --git a/src/modules/rlm_ruby/configure.ac b/src/modules/rlm_ruby/configure.ac
-index 9306382..f1c8118 100644
+index 9306382..ae86a14 100644
 --- a/src/modules/rlm_ruby/configure.ac
 +++ b/src/modules/rlm_ruby/configure.ac
-@@ -3,15 +3,16 @@ AC_INIT(rlm_ruby.c)
+@@ -3,15 +3,15 @@ AC_INIT(rlm_ruby.c)
  AC_REVISION($Revision: 1.9 $)
  AC_DEFUN(modname,[rlm_ruby])
  
@@ -174,7 +147,6 @@
 -m4_include([ax_compare_version.m4])
 -m4_include([ax_prog_ruby_version.m4])
 -m4_include([ax_ruby_devel.m4])
-+
 +m4_include([m4/ax_compare_version.m4])
 +m4_include([m4/ax_prog_ruby_version.m4])
 +m4_include([m4/ax_ruby_devel.m4])
@@ -195,33 +167,11 @@
  /* Define to the version of this package. */
  #undef PACKAGE_VERSION
  
-diff --git a/src/modules/rlm_sql/drivers/rlm_sql_mysql/config.h.in b/src/modules/rlm_sql/drivers/rlm_sql_mysql/config.h.in
-index e03d1a9..6262c48 100644
---- a/src/modules/rlm_sql/drivers/rlm_sql_mysql/config.h.in
-+++ b/src/modules/rlm_sql/drivers/rlm_sql_mysql/config.h.in
-@@ -18,5 +18,8 @@
- /* Define to the one symbol short name of this package. */
- #undef PACKAGE_TARNAME
- 
-+/* Define to the home page for this package. */
-+#undef PACKAGE_URL
-+
- /* Define to the version of this package. */
- #undef PACKAGE_VERSION
 diff --git a/src/modules/rlm_unix/config.h.in b/src/modules/rlm_unix/config.h.in
-index dcb9aa2..70b4680 100644
+index dcb9aa2..16107b8 100644
 --- a/src/modules/rlm_unix/config.h.in
 +++ b/src/modules/rlm_unix/config.h.in
-@@ -1,5 +1,8 @@
- /* config.h.in.  Generated from configure.ac by autoheader.  */
- 
-+/* Define to 1 if you have the `getpwnam' function. */
-+#undef HAVE_GETPWNAM
-+
- /* Define to 1 if you have the `getspnam' function. */
- #undef HAVE_GETSPNAM
- 
-@@ -54,6 +57,9 @@
+@@ -54,6 +54,9 @@
  /* Define to the one symbol short name of this package. */
  #undef PACKAGE_TARNAME
  
@@ -232,5 +182,5 @@
  #undef PACKAGE_VERSION
  
 -- 
-2.3.5
+2.7.4
 
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/freeradius/freeradius_3.0.15.bb b/meta-openembedded/meta-networking/recipes-connectivity/freeradius/freeradius_3.0.15.bb
deleted file mode 100644
index 4155a40..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/freeradius/freeradius_3.0.15.bb
+++ /dev/null
@@ -1,222 +0,0 @@
-DESCRIPTION = "FreeRADIUS is an Internet authentication daemon, which implements the RADIUS \
-protocol, as defined in RFC 2865 (and others). It allows Network Access \
-Servers (NAS boxes) to perform authentication for dial-up users. There are \
-also RADIUS clients available for Web servers, firewalls, Unix logins, and \
-more.  Using RADIUS allows authentication and authorization for a network to \
-be centralized, and minimizes the amount of re-configuration which has to be \
-done when adding or deleting new users."
-
-SUMMARY = "High-performance and highly configurable RADIUS server"
-HOMEPAGE = "http://www.freeradius.org/"
-SECTION = "System/Servers"
-LICENSE = "GPLv2 & LGPLv2+"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=eb723b61539feef013de476e68b5c50a"
-DEPENDS = "openssl-native openssl libidn libtool libpcap libtalloc"
-
-SRC_URI = "ftp://ftp.freeradius.org/pub/freeradius/freeradius-server-${PV}.tar.bz2 \
-    file://freeradius \
-    file://volatiles.58_radiusd \
-    file://freeradius-enble-user-in-conf.patch \
-    file://freeradius-configure.ac-allow-cross-compilation.patch \
-    file://freeradius-fix-issues-related-to-m4-include-path.patch \
-    file://freeradius-libtool-detection.patch \
-    file://freeradius-configure.ac-add-option-for-libcap.patch \
-    file://freeradius-avoid-searching-host-dirs.patch \
-    file://freeradius-rlm_python-add-PY_INC_DIR.patch \
-    file://freeradius-libtool-do-not-use-jlibtool.patch \
-    file://freeradius-fix-quoting-for-BUILT_WITH.patch \
-    file://freeradius-fix-error-for-expansion-of-macro.patch \
-    file://0001-rlm_mschap-Use-includedir-instead-of-hardcoding-usr-.patch \
-    file://radiusd.service \
-    file://radiusd-volatiles.conf \
-"
-SRC_URI[md5sum] = "0c81a4464ccf1d04f7ef1218a029d37a"
-SRC_URI[sha256sum] = "23267d8505e7b2909f5bdbf3938ca077c1fe122290dc969304d4f3b594f7e3ba"
-
-PARALLEL_MAKE = ""
-
-S = "${WORKDIR}/freeradius-server-${PV}"
-
-EXTRA_OECONF = " --enable-strict-dependencies \
-        --with-docdir=${docdir}/freeradius-${PV} \
-        --with-openssl-includes=${STAGING_INCDIR} \
-        --with-openssl-libraries=${STAGING_LIBDIR} \
-        --without-rlm_ippool \
-        --without-rlm_cache_memcached \
-        --without-rlm_counter \
-        --without-rlm_couchbase \
-        --without-rlm_dbm \
-        --without-rlm_eap_tnc \
-        --without-rlm_eap_ikev2 \
-        --without-rlm_opendirectory \
-        --without-rlm_redis \
-        --without-rlm_rediswho \
-        --without-rlm_sql_db2 \
-        --without-rlm_sql_firebird \
-        --without-rlm_sql_freetds \
-        --without-rlm_sql_iodbc \
-        --without-rlm_sql_oracle \
-        --without-rlm_sql_sybase \
-        --without-rlm_sqlhpwippool \
-        ac_cv_path_PERL=${bindir}/perl \
-        ax_cv_cc_builtin_choose_expr=no \
-        ax_cv_cc_builtin_types_compatible_p=no \
-        ax_cv_cc_builtin_bswap64=no \
-        ax_cv_cc_bounded_attribute=no \
-"
-
-PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'pam', '', d)} \
-                   pcre libcap \
-"
-
-PACKAGECONFIG[krb5] = "--with-rlm_krb5,--without-rlm_krb5,krb5"
-PACKAGECONFIG[pam] = "--with-rlm_pam,--without-rlm_pam,libpam"
-PACKAGECONFIG[libcap] = "--with-libcap,--without-libcap,libcap"
-PACKAGECONFIG[ldap] = "--with-rlm_ldap,--without-rlm_ldap,openldap"
-PACKAGECONFIG[mysql] = "--with-rlm_sql_mysql,--without-rlm_sql_mysql,mysql5"
-PACKAGECONFIG[sqlite] = "--with-rlm_sql_sqlite,--without-rlm_sql_sqlite,sqlite3"
-PACKAGECONFIG[unixodbc] = "--with-rlm_sql_unixodbc,--without-rlm_sql_unixodbc,unixodbc"
-PACKAGECONFIG[postgresql] = "--with-rlm_sql_postgresql,--without-rlm_sql_postgresql,postgresql"
-PACKAGECONFIG[pcre] = "--with-pcre,--without-pcre,libpcre"
-PACKAGECONFIG[perl] = "--with-perl=${STAGING_BINDIR_NATIVE}/perl-native/perl --with-rlm_perl,--without-rlm_perl,perl-native perl,perl"
-PACKAGECONFIG[python] = "--with-rlm_python --with-rlm-python-bin=${STAGING_BINDIR_NATIVE}/python-native/python --with-rlm-python-include-dir=${STAGING_INCDIR}/${PYTHON_DIR},--without-rlm_python,python-native python"
-PACKAGECONFIG[rest] = "--with-rlm_rest,--without-rlm_rest,curl json-c"
-PACKAGECONFIG[ruby] = "--with-rlm_ruby,--without-rlm_ruby,ruby"
-
-inherit useradd autotools-brokensep update-rc.d systemd
-
-# This is not a cpan or python based package, but it needs some definitions
-# from cpan-base and python-dir bbclasses for building rlm_perl and rlm_python
-# correctly.
-inherit cpan-base python-dir
-
-# The modules subdirs also need to be processed by autoreconf. Use autogen.sh
-# in order to handle the subdirs correctly.
-do_configure () {
-    ./autogen.sh
-
-    # the configure of rlm_perl needs this to get correct
-    # mod_cflags and mod_ldflags
-    if ${@bb.utils.contains('PACKAGECONFIG', 'perl', 'true', 'false', d)}; then
-        export PERL5LIB="${STAGING_LIBDIR}${PERL_OWN_DIR}/perl/${@get_perl_version(d)}"
-    fi
-
-    oe_runconf
-
-    # we don't need dhcpclient
-    sed -i -e 's/dhcpclient.mk//' ${S}/src/modules/proto_dhcp/all.mk
-}
-
-INITSCRIPT_NAME = "radiusd"
-
-SYSTEMD_SERVICE_${PN} = "radiusd.service"
-
-USERADD_PACKAGES = "${PN}"
-USERADD_PARAM_${PN} = "--system --no-create-home --shell /bin/false --user-group radiusd"
-
-do_install() {
-    rm -rf ${D}
-    mkdir -p ${D}/${sysconfdir}/logrotate.d
-    mkdir -p ${D}/${sysconfdir}/pam.d
-    mkdir -p ${D}/${sysconfdir}/init.d
-    mkdir -p ${D}/${localstatedir}/lib/radiusd
-    mkdir -p ${D}${sysconfdir}/default/volatiles
-
-    export LD_LIBRARY_PATH=${D}/${libdir}
-    oe_runmake install R=${D} INSTALLSTRIP=""
-
-    # remove unsupported config files
-    rm -f ${D}/${sysconfdir}/raddb/experimental.conf
-
-    # remove scripts that required Perl(DBI)
-    rm -rf ${D}/${bindir}/radsqlrelay
-
-    cp -f ${WORKDIR}/freeradius ${D}/etc/init.d/radiusd
-    rm -f ${D}/${sbindir}/rc.radiusd
-    chmod +x ${D}/${sysconfdir}/init.d/radiusd
-    rm -rf ${D}/${localstatedir}/run/
-    install -m 0644 ${WORKDIR}/volatiles.58_radiusd  ${D}${sysconfdir}/default/volatiles/58_radiusd
-
-    chown -R radiusd:radiusd ${D}/${sysconfdir}/raddb/
-    chown -R radiusd:radiusd ${D}/${localstatedir}/lib/radiusd
-
-    # For systemd
-    install -d ${D}${systemd_unitdir}/system
-    install -m 0644 ${WORKDIR}/radiusd.service ${D}${systemd_unitdir}/system
-    sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
-           -e 's,@SBINDIR@,${sbindir},g' \
-           -e 's,@STATEDIR@,${localstatedir},g' \
-           -e 's,@SYSCONFDIR@,${sysconfdir},g' \
-           ${D}${systemd_unitdir}/system/radiusd.service
-
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-        install -d ${D}${sysconfdir}/tmpfiles.d/
-        install -m 0644 ${WORKDIR}/radiusd-volatiles.conf ${D}${sysconfdir}/tmpfiles.d/
-    fi
-}
-
-# This is only needed when we install/update on a running target.
-#
-pkg_postinst_${PN} () {
-    if [ -z "$D" ]; then
-        if command -v systemd-tmpfiles >/dev/null; then
-            # create /var/log/radius, /var/run/radiusd
-            systemd-tmpfiles --create ${sysconfdir}/tmpfiles.d/radiusd-volatiles.conf
-        elif [ -e ${sysconfdir}/init.d/populate-volatile.sh ]; then
-            ${sysconfdir}/init.d/populate-volatile.sh update
-        fi
-
-        # Fix ownership for /etc/raddb/*, /var/lib/radiusd
-        chown -R radiusd:radiusd ${sysconfdir}/raddb
-        chown -R radiusd:radiusd ${localstatedir}/lib/radiusd
-    fi
-}
-
-# We really need the symlink :(
-INSANE_SKIP_${PN} = "dev-so"
-INSANE_SKIP_${PN}-krb5 = "dev-so"
-INSANE_SKIP_${PN}-ldap = "dev-so"
-INSANE_SKIP_${PN}-mysql = "dev-so"
-INSANE_SKIP_${PN}-perl = "dev-so"
-INSANE_SKIP_${PN}-postgresql = "dev-so"
-INSANE_SKIP_${PN}-python = "dev-so"
-INSANE_SKIP_${PN}-unixodbc = "dev-so"
-
-PACKAGES =+ "${PN}-utils ${PN}-ldap ${PN}-krb5 ${PN}-perl \
-    ${PN}-python ${PN}-mysql ${PN}-postgresql ${PN}-unixodbc"
-
-FILES_${PN}-utils = "${bindir}/*"
-
-FILES_${PN}-ldap = "${libdir}/rlm_ldap.so* \
-    ${sysconfdir}/raddb/mods-available/ldap \
-"
-
-FILES_${PN}-krb5 = "${libdir}/rlm_krb5.so* \
-    ${sysconfdir}/raddb/mods-available/krb5 \
-"
-
-FILES_${PN}-perl = "${libdir}/rlm_perl.so* \
-    ${sysconfdir}/raddb/mods-config/perl \
-    ${sysconfdir}/raddb/mods-available/perl \
-"
-
-FILES_${PN}-python = "${libdir}/rlm_python.so* \
-    ${sysconfdir}/raddb/mods-config/python \
-    ${sysconfdir}/raddb/mods-available/python \
-"
-
-FILES_${PN}-mysql = "${libdir}/rlm_sql_mysql.so* \
-    ${sysconfdir}/raddb/mods-config/sql/*/mysql \
-    ${sysconfdir}/raddb/mods-available/sql \
-"
-
-FILES_${PN}-postgresql = "${libdir}/rlm_sql_postgresql.so* \
-    ${sysconfdir}/raddb/mods-config/sql/*/postgresql \
-"
-
-FILES_${PN}-unixodbc = "${libdir}/rlm_sql_unixodbc.so*"
-
-FILES_${PN} =+ "${libdir}/rlm_*.so* ${libdir}/proto_*so*"
-
-RDEPENDS_${PN} += "perl"
-RDEPENDS_${PN}-utils = "${PN}"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/freeradius/freeradius_3.0.17.bb b/meta-openembedded/meta-networking/recipes-connectivity/freeradius/freeradius_3.0.17.bb
new file mode 100644
index 0000000..c17d56d
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/freeradius/freeradius_3.0.17.bb
@@ -0,0 +1,223 @@
+DESCRIPTION = "FreeRADIUS is an Internet authentication daemon, which implements the RADIUS \
+protocol, as defined in RFC 2865 (and others). It allows Network Access \
+Servers (NAS boxes) to perform authentication for dial-up users. There are \
+also RADIUS clients available for Web servers, firewalls, Unix logins, and \
+more.  Using RADIUS allows authentication and authorization for a network to \
+be centralized, and minimizes the amount of re-configuration which has to be \
+done when adding or deleting new users."
+
+SUMMARY = "High-performance and highly configurable RADIUS server"
+HOMEPAGE = "http://www.freeradius.org/"
+SECTION = "System/Servers"
+LICENSE = "GPLv2 & LGPLv2+"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=eb723b61539feef013de476e68b5c50a"
+DEPENDS = "openssl-native openssl libidn libtool libpcap libtalloc"
+
+SRC_URI = "ftp://ftp.freeradius.org/pub/freeradius/freeradius-server-${PV}.tar.bz2 \
+    file://freeradius \
+    file://volatiles.58_radiusd \
+    file://freeradius-enble-user-in-conf.patch \
+    file://freeradius-configure.ac-allow-cross-compilation.patch \
+    file://freeradius-fix-issues-related-to-m4-include-path.patch \
+    file://freeradius-libtool-detection.patch \
+    file://freeradius-configure.ac-add-option-for-libcap.patch \
+    file://freeradius-avoid-searching-host-dirs.patch \
+    file://freeradius-rlm_python-add-PY_INC_DIR.patch \
+    file://freeradius-libtool-do-not-use-jlibtool.patch \
+    file://freeradius-fix-quoting-for-BUILT_WITH.patch \
+    file://freeradius-fix-error-for-expansion-of-macro.patch \
+    file://0001-rlm_mschap-Use-includedir-instead-of-hardcoding-usr-.patch \
+    file://radiusd.service \
+    file://radiusd-volatiles.conf \
+    file://0001-freeradius-correct-version-number-of-libssl-defect.patch \
+"
+SRC_URI[md5sum] = "1f4ad38f32101a7d50d818afa6f17339"
+SRC_URI[sha256sum] = "3f03404b6e4a4f410e1f15ea2ababfec7f8a7ae8a49836d8a0c137436d913b96"
+
+PARALLEL_MAKE = ""
+
+S = "${WORKDIR}/freeradius-server-${PV}"
+
+EXTRA_OECONF = " --enable-strict-dependencies \
+        --with-docdir=${docdir}/freeradius-${PV} \
+        --with-openssl-includes=${STAGING_INCDIR} \
+        --with-openssl-libraries=${STAGING_LIBDIR} \
+        --without-rlm_ippool \
+        --without-rlm_cache_memcached \
+        --without-rlm_counter \
+        --without-rlm_couchbase \
+        --without-rlm_dbm \
+        --without-rlm_eap_tnc \
+        --without-rlm_eap_ikev2 \
+        --without-rlm_opendirectory \
+        --without-rlm_redis \
+        --without-rlm_rediswho \
+        --without-rlm_sql_db2 \
+        --without-rlm_sql_firebird \
+        --without-rlm_sql_freetds \
+        --without-rlm_sql_iodbc \
+        --without-rlm_sql_oracle \
+        --without-rlm_sql_sybase \
+        --without-rlm_sqlhpwippool \
+        ac_cv_path_PERL=${bindir}/perl \
+        ax_cv_cc_builtin_choose_expr=no \
+        ax_cv_cc_builtin_types_compatible_p=no \
+        ax_cv_cc_builtin_bswap64=no \
+        ax_cv_cc_bounded_attribute=no \
+"
+
+PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'pam', '', d)} \
+                   pcre libcap \
+"
+
+PACKAGECONFIG[krb5] = "--with-rlm_krb5,--without-rlm_krb5,krb5"
+PACKAGECONFIG[pam] = "--with-rlm_pam,--without-rlm_pam,libpam"
+PACKAGECONFIG[libcap] = "--with-libcap,--without-libcap,libcap"
+PACKAGECONFIG[ldap] = "--with-rlm_ldap,--without-rlm_ldap,openldap"
+PACKAGECONFIG[mysql] = "--with-rlm_sql_mysql,--without-rlm_sql_mysql,mysql5"
+PACKAGECONFIG[sqlite] = "--with-rlm_sql_sqlite,--without-rlm_sql_sqlite,sqlite3"
+PACKAGECONFIG[unixodbc] = "--with-rlm_sql_unixodbc,--without-rlm_sql_unixodbc,unixodbc"
+PACKAGECONFIG[postgresql] = "--with-rlm_sql_postgresql,--without-rlm_sql_postgresql,postgresql"
+PACKAGECONFIG[pcre] = "--with-pcre,--without-pcre,libpcre"
+PACKAGECONFIG[perl] = "--with-perl=${STAGING_BINDIR_NATIVE}/perl-native/perl --with-rlm_perl,--without-rlm_perl,perl-native perl,perl"
+PACKAGECONFIG[python] = "--with-rlm_python --with-rlm-python-bin=${STAGING_BINDIR_NATIVE}/python-native/python --with-rlm-python-include-dir=${STAGING_INCDIR}/${PYTHON_DIR},--without-rlm_python,python-native python"
+PACKAGECONFIG[rest] = "--with-rlm_rest,--without-rlm_rest,curl json-c"
+PACKAGECONFIG[ruby] = "--with-rlm_ruby,--without-rlm_ruby,ruby"
+
+inherit useradd autotools-brokensep update-rc.d systemd
+
+# This is not a cpan or python based package, but it needs some definitions
+# from cpan-base and python-dir bbclasses for building rlm_perl and rlm_python
+# correctly.
+inherit cpan-base python-dir
+
+# The modules subdirs also need to be processed by autoreconf. Use autogen.sh
+# in order to handle the subdirs correctly.
+do_configure () {
+    ./autogen.sh
+
+    # the configure of rlm_perl needs this to get correct
+    # mod_cflags and mod_ldflags
+    if ${@bb.utils.contains('PACKAGECONFIG', 'perl', 'true', 'false', d)}; then
+        export PERL5LIB="${STAGING_LIBDIR}${PERL_OWN_DIR}/perl/${@get_perl_version(d)}"
+    fi
+
+    oe_runconf
+
+    # we don't need dhcpclient
+    sed -i -e 's/dhcpclient.mk//' ${S}/src/modules/proto_dhcp/all.mk
+}
+
+INITSCRIPT_NAME = "radiusd"
+
+SYSTEMD_SERVICE_${PN} = "radiusd.service"
+
+USERADD_PACKAGES = "${PN}"
+USERADD_PARAM_${PN} = "--system --no-create-home --shell /bin/false --user-group radiusd"
+
+do_install() {
+    rm -rf ${D}
+    mkdir -p ${D}/${sysconfdir}/logrotate.d
+    mkdir -p ${D}/${sysconfdir}/pam.d
+    mkdir -p ${D}/${sysconfdir}/init.d
+    mkdir -p ${D}/${localstatedir}/lib/radiusd
+    mkdir -p ${D}${sysconfdir}/default/volatiles
+
+    export LD_LIBRARY_PATH=${D}/${libdir}
+    oe_runmake install R=${D} INSTALLSTRIP=""
+
+    # remove unsupported config files
+    rm -f ${D}/${sysconfdir}/raddb/experimental.conf
+
+    # remove scripts that required Perl(DBI)
+    rm -rf ${D}/${bindir}/radsqlrelay
+
+    cp -f ${WORKDIR}/freeradius ${D}/etc/init.d/radiusd
+    rm -f ${D}/${sbindir}/rc.radiusd
+    chmod +x ${D}/${sysconfdir}/init.d/radiusd
+    rm -rf ${D}/${localstatedir}/run/
+    install -m 0644 ${WORKDIR}/volatiles.58_radiusd  ${D}${sysconfdir}/default/volatiles/58_radiusd
+
+    chown -R radiusd:radiusd ${D}/${sysconfdir}/raddb/
+    chown -R radiusd:radiusd ${D}/${localstatedir}/lib/radiusd
+
+    # For systemd
+    install -d ${D}${systemd_unitdir}/system
+    install -m 0644 ${WORKDIR}/radiusd.service ${D}${systemd_unitdir}/system
+    sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
+           -e 's,@SBINDIR@,${sbindir},g' \
+           -e 's,@STATEDIR@,${localstatedir},g' \
+           -e 's,@SYSCONFDIR@,${sysconfdir},g' \
+           ${D}${systemd_unitdir}/system/radiusd.service
+
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+        install -d ${D}${sysconfdir}/tmpfiles.d/
+        install -m 0644 ${WORKDIR}/radiusd-volatiles.conf ${D}${sysconfdir}/tmpfiles.d/
+    fi
+}
+
+# This is only needed when we install/update on a running target.
+#
+pkg_postinst_${PN} () {
+    if [ -z "$D" ]; then
+        if command -v systemd-tmpfiles >/dev/null; then
+            # create /var/log/radius, /var/run/radiusd
+            systemd-tmpfiles --create ${sysconfdir}/tmpfiles.d/radiusd-volatiles.conf
+        elif [ -e ${sysconfdir}/init.d/populate-volatile.sh ]; then
+            ${sysconfdir}/init.d/populate-volatile.sh update
+        fi
+
+        # Fix ownership for /etc/raddb/*, /var/lib/radiusd
+        chown -R radiusd:radiusd ${sysconfdir}/raddb
+        chown -R radiusd:radiusd ${localstatedir}/lib/radiusd
+    fi
+}
+
+# We really need the symlink :(
+INSANE_SKIP_${PN} = "dev-so"
+INSANE_SKIP_${PN}-krb5 = "dev-so"
+INSANE_SKIP_${PN}-ldap = "dev-so"
+INSANE_SKIP_${PN}-mysql = "dev-so"
+INSANE_SKIP_${PN}-perl = "dev-so"
+INSANE_SKIP_${PN}-postgresql = "dev-so"
+INSANE_SKIP_${PN}-python = "dev-so"
+INSANE_SKIP_${PN}-unixodbc = "dev-so"
+
+PACKAGES =+ "${PN}-utils ${PN}-ldap ${PN}-krb5 ${PN}-perl \
+    ${PN}-python ${PN}-mysql ${PN}-postgresql ${PN}-unixodbc"
+
+FILES_${PN}-utils = "${bindir}/*"
+
+FILES_${PN}-ldap = "${libdir}/rlm_ldap.so* \
+    ${sysconfdir}/raddb/mods-available/ldap \
+"
+
+FILES_${PN}-krb5 = "${libdir}/rlm_krb5.so* \
+    ${sysconfdir}/raddb/mods-available/krb5 \
+"
+
+FILES_${PN}-perl = "${libdir}/rlm_perl.so* \
+    ${sysconfdir}/raddb/mods-config/perl \
+    ${sysconfdir}/raddb/mods-available/perl \
+"
+
+FILES_${PN}-python = "${libdir}/rlm_python.so* \
+    ${sysconfdir}/raddb/mods-config/python \
+    ${sysconfdir}/raddb/mods-available/python \
+"
+
+FILES_${PN}-mysql = "${libdir}/rlm_sql_mysql.so* \
+    ${sysconfdir}/raddb/mods-config/sql/*/mysql \
+    ${sysconfdir}/raddb/mods-available/sql \
+"
+
+FILES_${PN}-postgresql = "${libdir}/rlm_sql_postgresql.so* \
+    ${sysconfdir}/raddb/mods-config/sql/*/postgresql \
+"
+
+FILES_${PN}-unixodbc = "${libdir}/rlm_sql_unixodbc.so*"
+
+FILES_${PN} =+ "${libdir}/rlm_*.so* ${libdir}/proto_*so*"
+
+RDEPENDS_${PN} += "perl"
+RDEPENDS_${PN}-utils = "${PN}"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/inetutils/inetutils_1.9.4.bb b/meta-openembedded/meta-networking/recipes-connectivity/inetutils/inetutils_1.9.4.bb
index 190cd5f..a27dbae 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/inetutils/inetutils_1.9.4.bb
+++ b/meta-openembedded/meta-networking/recipes-connectivity/inetutils/inetutils_1.9.4.bb
@@ -4,7 +4,7 @@
 talkd, telnet, telnetd, tftp, tftpd, and uucpd."
 HOMEPAGE = "http://www.gnu.org/software/inetutils"
 SECTION = "net"
-DEPENDS = "ncurses netbase readline"
+DEPENDS = "ncurses netbase readline virtual/crypt"
 
 LICENSE = "GPLv3"
 
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/kea/files/0001-Fix-error-call-of-overloaded-distance-is-ambiguous.patch b/meta-openembedded/meta-networking/recipes-connectivity/kea/files/0001-Fix-error-call-of-overloaded-distance-is-ambiguous.patch
new file mode 100644
index 0000000..fb16ecb
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/kea/files/0001-Fix-error-call-of-overloaded-distance-is-ambiguous.patch
@@ -0,0 +1,89 @@
+From 8ea2ee451a1af7c5b5c8f4b36c1f77d44442064d Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 7 Sep 2018 13:02:35 -0700
+Subject: [PATCH] Fix error: call of overloaded distance is ambiguous
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+The boost::iterators::distance function template is an adapted version
+of std::distance for the Boost iterator traversal in 2.68 it has started
+to fail with argument dependent lookup and compiler is erroring out
+
+with
+
+error: call of overloaded ‘distance'
+
+boost implementation of distance is protected against being found by ADL
+
+The way function is called in libdhcp means it will be found via ADL and
+all namespaces will be considered which is providing problematic since
+its getting it from both std:: and boost:: namespaces
+
+so let it not rely on ADL by qualifying then calls with std:: namespace
+
+Upstream-Status: Submitted [https://github.com/isc-projects/kea/pull/103]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/lib/dhcp/libdhcp++.cc | 12 ++++++------
+ 1 file changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/src/lib/dhcp/libdhcp++.cc b/src/lib/dhcp/libdhcp++.cc
+index 330c02b..ced705d 100644
+--- a/src/lib/dhcp/libdhcp++.cc
++++ b/src/lib/dhcp/libdhcp++.cc
+@@ -419,14 +419,14 @@ size_t LibDHCP::unpackOptions6(const OptionBuffer& buf,
+         // We previously did the lookup only for dhcp6 option space, but with the
+         // addition of S46 options, we now do it for every space.
+         range = idx.equal_range(opt_type);
+-        num_defs = distance(range.first, range.second);
++        num_defs = std::distance(range.first, range.second);
+ 
+         // Standard option definitions do not include the definition for
+         // our option or we're searching for non-standard option. Try to
+         // find the definition among runtime option definitions.
+         if (num_defs == 0) {
+             range = runtime_idx.equal_range(opt_type);
+-            num_defs = distance(range.first, range.second);
++            num_defs = std::distance(range.first, range.second);
+         }
+ 
+         OptionPtr opt;
+@@ -538,14 +538,14 @@ size_t LibDHCP::unpackOptions4(const OptionBuffer& buf,
+         // may be standard options in other spaces (e.g. radius). So we now do
+         // the lookup for every space.
+         range = idx.equal_range(opt_type);
+-        num_defs = distance(range.first, range.second);
++        num_defs = std::distance(range.first, range.second);
+ 
+         // Standard option definitions do not include the definition for
+         // our option or we're searching for non-standard option. Try to
+         // find the definition among runtime option definitions.
+         if (num_defs == 0) {
+             range = runtime_idx.equal_range(opt_type);
+-            num_defs = distance(range.first, range.second);
++            num_defs = std::distance(range.first, range.second);
+         }
+ 
+         // Check if option unpacking must be deferred
+@@ -638,7 +638,7 @@ size_t LibDHCP::unpackVendorOptions6(const uint32_t vendor_id,
+                 idx->equal_range(opt_type);
+             // Get the number of returned option definitions for the
+             // option code.
+-            size_t num_defs = distance(range.first, range.second);
++            size_t num_defs = std::distance(range.first, range.second);
+ 
+             if (num_defs > 1) {
+                 // Multiple options of the same code are not supported
+@@ -746,7 +746,7 @@ size_t LibDHCP::unpackVendorOptions4(const uint32_t vendor_id, const OptionBuffe
+                     idx->equal_range(opt_type);
+                 // Get the number of returned option definitions for
+                 // the option code.
+-                size_t num_defs = distance(range.first, range.second);
++                size_t num_defs = std::distance(range.first, range.second);
+ 
+                 if (num_defs > 1) {
+                     // Multiple options of the same code are not
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/kea/files/0003-Makefile.am-update-hooksdir-for-lease_cmds.patch b/meta-openembedded/meta-networking/recipes-connectivity/kea/files/0003-Makefile.am-update-hooksdir-for-lease_cmds.patch
new file mode 100644
index 0000000..381a3a7
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/kea/files/0003-Makefile.am-update-hooksdir-for-lease_cmds.patch
@@ -0,0 +1,31 @@
+From cd902b8b588681a27d5321f1ee078a1c8f6e6935 Mon Sep 17 00:00:00 2001
+From: Mingli Yu <Mingli.Yu@windriver.com>
+Date: Wed, 21 Mar 2018 06:01:38 +0000
+Subject: [PATCH 3/3] Makefile.am: update hooksdir for lease_cmds
+
+update hooksdir for lease_cmds
+
+Upstream-Status: Pending
+
+Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
+
+---
+ src/hooks/dhcp/lease_cmds/Makefile.am | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/hooks/dhcp/lease_cmds/Makefile.am b/src/hooks/dhcp/lease_cmds/Makefile.am
+index cfd6779..22cc4a9 100644
+--- a/src/hooks/dhcp/lease_cmds/Makefile.am
++++ b/src/hooks/dhcp/lease_cmds/Makefile.am
+@@ -37,7 +37,7 @@ liblease_cmds_la_CXXFLAGS = $(AM_CXXFLAGS)
+ liblease_cmds_la_CPPFLAGS = $(AM_CPPFLAGS)
+ 
+ # install the shared object into $(libdir)/hooks
+-lib_hooksdir = $(libdir)/hooks
++lib_hooksdir = $(libdir)/kea/hooks
+ lib_hooks_LTLIBRARIES = libdhcp_lease_cmds.la
+ 
+ libdhcp_lease_cmds_la_SOURCES  =
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/kea/files/kea-dhcp-ddns.service b/meta-openembedded/meta-networking/recipes-connectivity/kea/files/kea-dhcp-ddns.service
new file mode 100644
index 0000000..91aa2eb
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/kea/files/kea-dhcp-ddns.service
@@ -0,0 +1,13 @@
+[Unit]
+Description=Kea DHCP-DDNS Server
+Wants=network-online.target
+After=network-online.target
+After=time-sync.target
+
+[Service]
+ExecStartPre=@BASE_BINDIR@/mkdir -p @LOCALSTATEDIR@/run/kea/
+ExecStartPre=@BASE_BINDIR@/mkdir -p @LOCALSTATEDIR@/kea
+ExecStart=@SBINDIR@/kea-dhcp-ddns -c @SYSCONFDIR@/kea/kea-dhcp-ddns.conf
+
+[Install]
+WantedBy=multi-user.target
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/kea/files/kea-dhcp4.service b/meta-openembedded/meta-networking/recipes-connectivity/kea/files/kea-dhcp4.service
new file mode 100644
index 0000000..f32edcb
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/kea/files/kea-dhcp4.service
@@ -0,0 +1,13 @@
+[Unit]
+Description=Kea DHCPv4 Server
+Wants=network-online.target
+After=network-online.target
+After=time-sync.target
+
+[Service]
+ExecStartPre=@BASE_BINDIR@/mkdir -p @LOCALSTATEDIR@/run/kea/
+ExecStartPre=@BASE_BINDIR@/mkdir -p @LOCALSTATEDIR@/kea
+ExecStart=@SBINDIR@/kea-dhcp4 -c @SYSCONFDIR@/kea/kea-dhcp4.conf
+
+[Install]
+WantedBy=multi-user.target
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/kea/files/kea-dhcp6.service b/meta-openembedded/meta-networking/recipes-connectivity/kea/files/kea-dhcp6.service
new file mode 100644
index 0000000..26d2205
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/kea/files/kea-dhcp6.service
@@ -0,0 +1,13 @@
+[Unit]
+Description=Kea DHCPv6 Server
+Wants=network-online.target
+After=network-online.target
+After=time-sync.target
+
+[Service]
+ExecStartPre=@BASE_BINDIR@/mkdir -p @LOCALSTATEDIR@/run/kea/
+ExecStartPre=@BASE_BINDIR@/mkdir -p @LOCALSTATEDIR@/kea
+ExecStart=@SBINDIR@/kea-dhcp6 -c @SYSCONFDIR@/kea/kea-dhcp6.conf
+
+[Install]
+WantedBy=multi-user.target
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/kea/kea_1.4.0.bb b/meta-openembedded/meta-networking/recipes-connectivity/kea/kea_1.4.0.bb
new file mode 100644
index 0000000..67de07b
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/kea/kea_1.4.0.bb
@@ -0,0 +1,52 @@
+SUMMARY = "ISC Kea DHCP Server"
+DESCRIPTION = "Kea is the next generation of DHCP software developed by ISC. It supports both DHCPv4 and DHCPv6 protocols along with their extensions, e.g. prefix delegation and dynamic updates to DNS."
+HOMEPAGE = "http://kea.isc.org"
+SECTION = "connectivity"
+LICENSE = "MPL-2.0 & Apache-2.0"
+LIC_FILES_CHKSUM = "file://COPYING;md5=1666a9c4bb55adbc8939d85643096bd3"
+
+DEPENDS += "kea-native"
+
+SRC_URI = "\
+    http://ftp.isc.org/isc/kea/${PV}/${BP}.tar.gz \
+    file://0003-Makefile.am-update-hooksdir-for-lease_cmds.patch \
+    file://0001-Fix-error-call-of-overloaded-distance-is-ambiguous.patch \
+    file://kea-dhcp4.service \
+    file://kea-dhcp6.service \
+    file://kea-dhcp-ddns.service \
+"
+SRC_URI[md5sum] = "26eedd749101642757d788431605aaa5"
+SRC_URI[sha256sum] = "c0f8ecb93657adfc5ab970c91706754e601084828493f053f159661d21b31128"
+
+inherit autotools systemd
+
+SYSTEMD_SERVICE_${PN} = "kea-dhcp4.service kea-dhcp6.service kea-dhcp-ddns.service"
+SYSTEMD_AUTO_ENABLE = "disable"
+
+do_configure_prepend_class-target() {
+    mkdir -p ${B}/src/lib/log/compiler/
+    ln -sf ${STAGING_BINDIR_NATIVE}/kea-msg-compiler ${B}/src/lib/log/compiler/kea-msg-compiler
+}
+
+do_install_append_class-target() {
+    install -d ${D}${systemd_system_unitdir}
+    install -m 0644 ${WORKDIR}/kea-dhcp*service ${D}${systemd_system_unitdir}
+    sed -i -e 's,@SBINDIR@,${sbindir},g' -e 's,@BASE_BINDIR@,${base_bindir},g' \
+           -e 's,@LOCALSTATEDIR@,${localstatedir},g' -e 's,@SYSCONFDIR@,${sysconfdir},g' \
+           ${D}${systemd_system_unitdir}/kea-dhcp*service
+}
+
+do_install_append() {
+    rm -rf "${D}${localstatedir}"
+}
+
+PACKAGECONFIG ??= "openssl log4cplus boost"
+
+PACKAGECONFIG[openssl] = "--with-openssl=${STAGING_DIR_TARGET}${prefix},,openssl,openssl"
+PACKAGECONFIG[log4cplus] = "--with-log4cplus=${STAGING_DIR_TARGET}${prefix},,log4cplus,log4cplus"
+PACKAGECONFIG[boost] = "--with-boost-include=${STAGING_INCDIR} --with-boost-lib-dir=${STAGING_LIBDIR} --with-boost-libs=-lboost_system,,boost,boost"
+
+FILES_${PN}-staticdev += "${libdir}/kea/hooks/*.a ${libdir}/hooks/*.a"
+FILES_${PN} += "${libdir}/hooks/*.so"
+
+BBCLASSEXTEND += "native"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/lftp/lftp_4.7.7.bb b/meta-openembedded/meta-networking/recipes-connectivity/lftp/lftp_4.7.7.bb
deleted file mode 100644
index b6b65da..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/lftp/lftp_4.7.7.bb
+++ /dev/null
@@ -1,34 +0,0 @@
-DESCRIPTION = "LFTP is a sophisticated file transfer program with \
-               command line interface. It supports FTP, HTTP, \
-               FISH, SFTP, HTTPS and FTPS protocols"
-HOMEPAGE = "http://lftp.yar.ru/"
-SECTION = "console/network"
-LICENSE = "GPLv3"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
-
-SRC_URI = "http://lftp.yar.ru/ftp/lftp-${PV}.tar.bz2 \
-           file://fix-gcc-6-conflicts-signbit.patch \
-          "
-SRC_URI[md5sum] = "3701e7675baa5619c92622eb141c8301"
-SRC_URI[sha256sum] = "fe441f20a9a317cfb99a8b8e628ba0457df472b6d93964d17374d5b5ebdf9280"
-
-inherit autotools gettext pkgconfig
-
-acpaths = "-I ./m4"
-
-EXTRA_OECONF += "--with-modules"
-
-PACKAGECONFIG ??= "libidn openssl zlib gnutls readline expat"
-PACKAGECONFIG[libidn] = "--with-libidn, --without-libidn, libidn"
-PACKAGECONFIG[openssl] = "--with-openssl, --without-openssl, openssl"
-PACKAGECONFIG[zlib] = "--with-zlib=${STAGING_INCDIR}/.., --without-zlib, zlib"
-PACKAGECONFIG[gnutls] = "--with-gnutls, --without-gnutls, gnutls"
-PACKAGECONFIG[readline] = "--with-readline=${STAGING_INCDIR}/.. --with-readline-inc=${STAGING_INCDIR} --with-readline-lib=-lreadline, --with-readline=no, readline"
-PACKAGECONFIG[expat] = "--with-expat=${STAGING_INCDIR}/.. --with-expat-inc=${STAGING_INCDIR} --with-expat-lib=-lexpat, , expat"
-
-do_install_append() {
-	rm -rf ${D}${libdir}/charset.alias
-}
-
-FILES_${PN}-dbg += "${libdir}/lftp/${PV}/.debug"
-RDEPENDS_${PN} = "perl bash readline"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/lftp/lftp_4.8.4.bb b/meta-openembedded/meta-networking/recipes-connectivity/lftp/lftp_4.8.4.bb
new file mode 100644
index 0000000..bf793d9
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/lftp/lftp_4.8.4.bb
@@ -0,0 +1,33 @@
+DESCRIPTION = "LFTP is a sophisticated file transfer program with \
+               command line interface. It supports FTP, HTTP, \
+               FISH, SFTP, HTTPS and FTPS protocols"
+HOMEPAGE = "http://lftp.yar.ru/"
+SECTION = "console/network"
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
+
+SRC_URI = "http://lftp.yar.ru/ftp/lftp-${PV}.tar.bz2 \
+           file://fix-gcc-6-conflicts-signbit.patch \
+          "
+SRC_URI[md5sum] = "a56b5047dbfda052df4c1dfd197aa092"
+SRC_URI[sha256sum] = "a853edbd075b008c315679c7882b6dcc6821ed2365d2ed843a412acd3d40da0e"
+
+inherit autotools gettext pkgconfig
+
+acpaths = "-I ./m4"
+
+EXTRA_OECONF += "--with-modules --disable-rpath"
+
+PACKAGECONFIG ??= "openssl zlib gnutls readline expat"
+PACKAGECONFIG[openssl] = "--with-openssl, --without-openssl, openssl"
+PACKAGECONFIG[zlib] = "--with-zlib=${STAGING_INCDIR}/.., --without-zlib, zlib"
+PACKAGECONFIG[gnutls] = "--with-gnutls, --without-gnutls, gnutls"
+PACKAGECONFIG[readline] = "--with-readline=${STAGING_INCDIR}/.. --with-readline-inc=${STAGING_INCDIR} --with-readline-lib=-lreadline, --with-readline=no, readline"
+PACKAGECONFIG[expat] = "--with-expat=${STAGING_INCDIR}/.. --with-expat-inc=${STAGING_INCDIR} --with-expat-lib=-lexpat, , expat"
+
+do_install_append() {
+	rm -rf ${D}${libdir}/charset.alias
+}
+FILES_${PN} += "${datadir}/icons/hicolor"
+FILES_${PN}-dbg += "${libdir}/lftp/${PV}/.debug"
+RDEPENDS_${PN} = "perl bash readline"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/libdnet/libdnet_1.12.bb b/meta-openembedded/meta-networking/recipes-connectivity/libdnet/libdnet_1.12.bb
index e579de5..53ba25e 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/libdnet/libdnet_1.12.bb
+++ b/meta-openembedded/meta-networking/recipes-connectivity/libdnet/libdnet_1.12.bb
@@ -7,6 +7,8 @@
 SRC_URI = "git://github.com/dugsong/libdnet.git;nobranch=1"
 SRCREV = "12fca29a6d4e99d1b923d6820887fe7b24226904"
 
+UPSTREAM_CHECK_GITTAGREGEX = "libdnet-(?P<pver>\d+(\.\d+)+)"
+
 S = "${WORKDIR}/git"
 
 inherit autotools
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/mbedtls/mbedtls_2.13.0.bb b/meta-openembedded/meta-networking/recipes-connectivity/mbedtls/mbedtls_2.13.0.bb
new file mode 100644
index 0000000..ff3f7f0
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/mbedtls/mbedtls_2.13.0.bb
@@ -0,0 +1,42 @@
+SUMMARY = "Lightweight crypto and SSL/TLS library"
+DESCRIPTION = "mbedtls is a lean open source crypto library          \
+for providing SSL and TLS support in your programs. It offers        \
+an intuitive API and documented header files, so you can actually    \
+understand what the code does. It features:                          \
+                                                                     \
+ - Symmetric algorithms, like AES, Blowfish, Triple-DES, DES, ARC4,  \
+   Camellia and XTEA                                                 \
+ - Hash algorithms, like SHA-1, SHA-2, RIPEMD-160 and MD5            \
+ - Entropy pool and random generators, like CTR-DRBG and HMAC-DRBG   \
+ - Public key algorithms, like RSA, Elliptic Curves, Diffie-Hellman, \
+   ECDSA and ECDH                                                    \
+ - SSL v3 and TLS 1.0, 1.1 and 1.2                                   \
+ - Abstraction layers for ciphers, hashes, public key operations,    \
+   platform abstraction and threading                                \
+"
+
+HOMEPAGE = "https://tls.mbed.org/"
+
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=302d50a6369f5f22efdb674db908167a"
+
+SECTION = "libs"
+
+SRC_URI = "https://tls.mbed.org/download/mbedtls-${PV}-apache.tgz"
+
+SRC_URI[md5sum] = "659d96bb03012ca6db414a9137fcdbd6"
+SRC_URI[sha256sum] = "593b4e4d2e1629fc407ab4750d69fa309a0ddb66565dc3deb5b60eddbdeb06da"
+
+inherit cmake
+
+PACKAGECONFIG ??= "shared-libs programs"
+PACKAGECONFIG[shared-libs] = "-DUSE_SHARED_MBEDTLS_LIBRARY=ON,-USE_SHARED_MBEDTLS_LIBRARY=OFF"
+PACKAGECONFIG[programs] = "-DENABLE_PROGRAMS=ON,-DENABLE_PROGRAMS=OFF"
+
+EXTRA_OECMAKE = "-DENABLE_TESTING=OFF -DLIB_INSTALL_DIR:STRING=${libdir}"
+
+PROVIDES += "polarssl"
+RPROVIDES_${PN} = "polarssl"
+
+PACKAGES =+ "${PN}-programs"
+FILES_${PN}-programs = "${bindir}/"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/mbedtls/mbedtls_2.8.0.bb b/meta-openembedded/meta-networking/recipes-connectivity/mbedtls/mbedtls_2.8.0.bb
deleted file mode 100644
index 736cce1..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/mbedtls/mbedtls_2.8.0.bb
+++ /dev/null
@@ -1,42 +0,0 @@
-SUMMARY = "Lightweight crypto and SSL/TLS library"
-DESCRIPTION = "mbedtls is a lean open source crypto library          \
-for providing SSL and TLS support in your programs. It offers        \
-an intuitive API and documented header files, so you can actually    \
-understand what the code does. It features:                          \
-                                                                     \
- - Symmetric algorithms, like AES, Blowfish, Triple-DES, DES, ARC4,  \
-   Camellia and XTEA                                                 \
- - Hash algorithms, like SHA-1, SHA-2, RIPEMD-160 and MD5            \
- - Entropy pool and random generators, like CTR-DRBG and HMAC-DRBG   \
- - Public key algorithms, like RSA, Elliptic Curves, Diffie-Hellman, \
-   ECDSA and ECDH                                                    \
- - SSL v3 and TLS 1.0, 1.1 and 1.2                                   \
- - Abstraction layers for ciphers, hashes, public key operations,    \
-   platform abstraction and threading                                \
-"
-
-HOMEPAGE = "https://tls.mbed.org/"
-
-LICENSE = "Apache-2.0"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=302d50a6369f5f22efdb674db908167a"
-
-SECTION = "libdevel"
-
-SRC_URI = "https://tls.mbed.org/download/mbedtls-${PV}-apache.tgz"
-
-SRC_URI[md5sum] = "2d4b0e2cb844efde1e73d3bcd9731fef"
-SRC_URI[sha256sum] = "ab8b62b995781bcf22e87a265ed06267f87c3041198e996b44441223d19fa9c3"
-
-inherit cmake
-
-PACKAGECONFIG ??= "shared-libs programs"
-PACKAGECONFIG[shared-libs] = "-DUSE_SHARED_MBEDTLS_LIBRARY=ON,-USE_SHARED_MBEDTLS_LIBRARY=OFF"
-PACKAGECONFIG[programs] = "-DENABLE_PROGRAMS=ON,-DENABLE_PROGRAMS=OFF"
-
-EXTRA_OECMAKE = "-DENABLE_TESTING=OFF -DLIB_INSTALL_DIR:STRING=${libdir}"
-
-PROVIDES += "polarssl"
-RPROVIDES_${PN} = "polarssl"
-
-PACKAGES =+ "${PN}-programs"
-FILES_${PN}-programs = "${bindir}/"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/miniupnpd/files/miniupnpd.service b/meta-openembedded/meta-networking/recipes-connectivity/miniupnpd/files/miniupnpd.service
new file mode 100644
index 0000000..e7bfad0
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/miniupnpd/files/miniupnpd.service
@@ -0,0 +1,14 @@
+[Unit]
+Description=Lightweight UPnP IGD daemon
+Documentation=man:miniupnpd(8)
+After=network.target
+
+[Service]
+Type=forking
+ExecStartPre=/etc/miniupnpd/iptables_init.sh
+ExecStart=/usr/sbin/miniupnpd -f /etc/miniupnpd/miniupnpd.conf
+ExecStopPost=/etc/miniupnpd/iptables_removeall.sh
+PIDFile=/run/miniupnpd.pid
+
+[Install]
+WantedBy=network.target
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/miniupnpd/miniupnpd_2.0.20180203.bb b/meta-openembedded/meta-networking/recipes-connectivity/miniupnpd/miniupnpd_2.0.20180203.bb
new file mode 100644
index 0000000..04b5cd5
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/miniupnpd/miniupnpd_2.0.20180203.bb
@@ -0,0 +1,43 @@
+SUMMARY = "Lightweight UPnP IGD daemon"
+DESCRIPTION = "The miniUPnP daemon is an UPnP IGD (internet gateway device) \
+which provide NAT traversal services to any UPnP enabled client on \
+the network."
+
+SECTION = "networking"
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=91ac00c6b9f5c106e89291e196fe0234"
+
+inherit autotools gettext pkgconfig systemd
+
+DEPENDS += "iptables net-tools util-linux libmnl libnetfilter-conntrack"
+
+SRC_URI = "http://miniupnp.tuxfamily.org/files/download.php?file=${P}.tar.gz;downloadfilename=${P}.tar.gz \
+           file://miniupnpd.service"
+
+SRC_URI[md5sum] = "b4c7c938915edeee6ca4c65dd021f212"
+SRC_URI[sha256sum] = "860c15f2f8340fd69546b01cffe4c7fcff3e63a7bdfe5a2af6b2346f0e074bb6"
+
+IPV6 = "${@bb.utils.contains('DISTRO_FEATURES', 'ipv6', '--ipv6', '', d)}"
+
+do_compile() {
+    cd ${S}
+    CONFIG_OPTIONS="${IPV6} --leasefile --vendorcfg" oe_runmake -f Makefile.linux
+}
+
+do_install() {
+    install -d ${D}/${sbindir}
+    install ${S}/miniupnpd ${D}/${sbindir}
+    install -d ${D}/${sysconfdir}/${BPN}
+    install ${S}/netfilter/iptables_init.sh ${D}/${sysconfdir}/${BPN}
+    install ${S}/netfilter/iptables_removeall.sh ${D}/${sysconfdir}/${BPN}
+    install ${S}/netfilter/ip6tables_init.sh ${D}/${sysconfdir}/${BPN}
+    install ${S}/netfilter/ip6tables_removeall.sh ${D}/${sysconfdir}/${BPN}
+    install -m 0644 -b ${S}/miniupnpd.conf ${D}/${sysconfdir}/${BPN}
+    install -d ${D}/${sysconfdir}/init.d
+    install ${S}/linux/miniupnpd.init.d.script ${D}/${sysconfdir}/init.d/miniupnpd
+
+    install -d ${D}${systemd_unitdir}/system
+    install -m 0644 ${WORKDIR}/miniupnpd.service ${D}${systemd_unitdir}/system/
+}
+
+SYSTEMD_SERVICE_${PN} = "miniupnpd.service"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/miniupnpd/miniupnpd_2.0.bb b/meta-openembedded/meta-networking/recipes-connectivity/miniupnpd/miniupnpd_2.0.bb
deleted file mode 100644
index c6f36e1..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/miniupnpd/miniupnpd_2.0.bb
+++ /dev/null
@@ -1,37 +0,0 @@
-SUMMARY = "Lightweight UPnP IGD daemon"
-DESCRIPTION = "The miniUPnP daemon is an UPnP IGD (internet gateway device) \
-which provide NAT traversal services to any UPnP enabled client on \
-the network."
-
-SECTION = "networking"
-LICENSE = "BSD-3-Clause"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=aa71c78c373ccfe0ff207af0cd966d91"
-
-inherit autotools gettext pkgconfig
-
-DEPENDS += "iptables net-tools util-linux libmnl libnetfilter-conntrack"
-
-SRC_URI = "http://miniupnp.tuxfamily.org/files/download.php?file=${P}.tar.gz;downloadfilename=${P}.tar.gz \
-"
-SRC_URI[md5sum] = "1c07a215dd9b362e75a9efc05e2fb3b4"
-SRC_URI[sha256sum] = "d96aa3a00e0f5490826bba3cb97e68cd27479e5839adac4b9bcb66eae786bfb7"
-
-IPV6 = "${@bb.utils.contains('DISTRO_FEATURES', 'ipv6', '--ipv6', '', d)}"
-
-do_compile() {
-    cd ${S}
-    CONFIG_OPTIONS="${IPV6} --leasefile --vendorcfg" oe_runmake -f Makefile.linux
-}
-
-do_install() {
-    install -d ${D}/${sbindir}
-    install ${S}/miniupnpd ${D}/${sbindir}
-    install -d ${D}/${sysconfdir}/${BPN}
-    install ${S}/netfilter/iptables_init.sh ${D}/${sysconfdir}/${BPN}
-    install ${S}/netfilter/iptables_removeall.sh ${D}/${sysconfdir}/${BPN}
-    install ${S}/netfilter/ip6tables_init.sh ${D}/${sysconfdir}/${BPN}
-    install ${S}/netfilter/ip6tables_removeall.sh ${D}/${sysconfdir}/${BPN}
-    install -m 0644 -b ${S}/miniupnpd.conf ${D}/${sysconfdir}/${BPN}
-    install -d ${D}/${sysconfdir}/init.d
-    install ${S}/linux/miniupnpd.init.d.script ${D}/${sysconfdir}/init.d/miniupnpd
-}
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/mosquitto/files/0002-uthash-remove-in-tree-version.patch b/meta-openembedded/meta-networking/recipes-connectivity/mosquitto/files/0002-uthash-remove-in-tree-version.patch
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-connectivity/mosquitto/files/0002-uthash-remove-in-tree-version.patch
rename to meta-openembedded/meta-networking/recipes-connectivity/mosquitto/files/0002-uthash-remove-in-tree-version.patch
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/mosquitto/files/mosquitto.init b/meta-openembedded/meta-networking/recipes-connectivity/mosquitto/files/mosquitto.init
new file mode 100644
index 0000000..6a0c127
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/mosquitto/files/mosquitto.init
@@ -0,0 +1,89 @@
+#! /bin/sh
+
+# Based on the Debian initscript for mosquitto
+
+### BEGIN INIT INFO
+# Provides:         mosquitto
+# Required-Start:   $remote_fs $syslog
+# Required-Stop:    $remote_fs $syslog
+# Default-Start:    2 3 4 5
+# Default-Stop:     0 1 6
+# Short-Description:    mosquitto MQTT message broker
+# Description: 
+#  This is a message broker that supports version 3.1/3.1.1 of the MQ Telemetry
+#  Transport (MQTT) protocol.
+#  
+#  MQTT provides a method of carrying out messaging using a publish/subscribe
+#  model. It is lightweight, both in terms of bandwidth usage and ease of
+#  implementation. This makes it particularly useful at the edge of the network
+#  where a sensor or other simple device may be implemented using an arduino for
+#  example.
+### END INIT INFO
+
+set -e
+
+PIDFILE=@LOCALSTATEDIR@/run/mosquitto.pid
+DAEMON=@SBINDIR@/mosquitto
+
+# start and stop the mosquitto MQTT message broker
+
+test -x ${DAEMON} || exit 0
+
+umask 022
+
+. @SYSCONFDIR@/init.d/functions
+
+export PATH="${PATH:+$PATH:}@SBINDIR@:@BASE_SBINDIR@"
+
+case "$1" in
+    start)
+        echo "Starting Mosquitto message broker" "mosquitto"
+        if start-stop-daemon --start --quiet --oknodo --background  --make-pidfile --pidfile ${PIDFILE} --exec ${DAEMON} ; then
+            exit 0
+        else
+            exit 1
+        fi
+        ;;
+    stop)
+        echo "Stopping Mosquitto message broker" "mosquitto"
+        if start-stop-daemon --stop --quiet --oknodo --pidfile ${PIDFILE}; then
+            rm -f ${PIDFILE}
+            exit 0
+        else
+            exit 1
+        fi
+        ;;
+
+
+    reload|force-reload)
+        if [ -f ${PIDFILE} ] ; then
+            echo "Reloading configuration for mosquitto"
+            pid=`cat ${PIDFILE}`
+            kill -HUP $pid
+        else
+            echo "mosquitto does not seem to be running"
+        fi
+        ;;
+
+    restart)
+        echo "Restarting Mosquitto message broker" "mosquitto"
+        if start-stop-daemon --stop --quiet --oknodo --retry 30 --pidfile ${PIDFILE}; then
+            rm -f ${PIDFILE}
+        fi
+        if start-stop-daemon --start --quiet --oknodo --background --make-pidfile --pidfile ${PIDFILE} --exec ${DAEMON} -- -c @SYSCONFDIR@/mosquitto/mosquitto.conf ; then
+            exit 0
+        else
+            exit 1
+        fi
+        ;;
+
+    status)
+        status ${DAEMON} && exit 0 || exit $?
+        ;;
+
+    *)
+        echo "Usage: $0 {start|stop|reload|force-reload|restart|status}"
+        exit 1
+esac
+
+exit 0
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/mosquitto/mosquitto_1.5.1.bb b/meta-openembedded/meta-networking/recipes-connectivity/mosquitto/mosquitto_1.5.1.bb
new file mode 100644
index 0000000..b4adfda
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/mosquitto/mosquitto_1.5.1.bb
@@ -0,0 +1,96 @@
+SUMMARY = "Open source MQTT v3.1/3.1.1 implemention"
+DESCRIPTION = "Mosquitto is an open source (Eclipse licensed) message broker that implements the MQ Telemetry Transport protocol version 3.1 and 3.1.1. MQTT provides a lightweight method of carrying out messaging using a publish/subscribe model. "
+HOMEPAGE = "http://mosquitto.org/"
+SECTION = "console/network"
+LICENSE = "EPL-1.0 | EDL-1.0"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=62ddc846179e908dc0c8efec4a42ef20 \
+                    file://edl-v10;md5=c09f121939f063aeb5235972be8c722c \
+                    file://epl-v10;md5=8d383c379e91d20ba18a52c3e7d3a979 \
+                    file://notice.html;md5=a00d6f9ab542be7babc2d8b80d5d2a4c \
+"
+DEPENDS = "uthash"
+
+SRC_URI = "http://mosquitto.org/files/source/mosquitto-${PV}.tar.gz \
+           file://0002-uthash-remove-in-tree-version.patch \
+           file://mosquitto.init \
+"
+
+SRC_URI[md5sum] = "f98c99998a36a234f3a9d9b402b991db"
+SRC_URI[sha256sum] = "8557bc7ae34dfaf32a0fb56d2491b7a7f731269c88337227233013502df4d5b0"
+
+inherit systemd update-rc.d useradd
+
+PACKAGECONFIG ??= "ssl uuid \
+                  ${@bb.utils.filter('DISTRO_FEATURES','systemd', d)} \
+                  "
+
+PACKAGECONFIG[dns-srv] = ",,c-ares"
+PACKAGECONFIG[ssl] = ",,openssl"
+PACKAGECONFIG[uuid] = ",,util-linux"
+PACKAGECONFIG[systemd] = "WITH_SYSTEMD=yes,WITH_SYSTEMD=no,systemd"
+PACKAGECONFIG[websockets] = ",,libwebsockets"
+
+EXTRA_OEMAKE = " \
+    prefix=${prefix} \
+    mandir=${mandir} \
+    localedir=${localedir} \
+    ${@bb.utils.contains('PACKAGECONFIG', 'dns-srv', 'WITH_SRV=yes', 'WITH_SRV=no', d)} \
+    ${@bb.utils.contains('PACKAGECONFIG', 'ssl', 'WITH_TLS=yes WITH_TLS_PSK=yes', 'WITH_TLS=no WITH_TLS_PSK=no', d)} \
+    ${@bb.utils.contains('PACKAGECONFIG', 'uuid', 'WITH_UUID=yes', 'WITH_UUID=no', d)} \
+    ${@bb.utils.contains('PACKAGECONFIG', 'websockets', 'WITH_WEBSOCKETS=yes', 'WITH_WEBSOCKETS=no', d)} \
+    STRIP=/bin/true \
+    WITH_DOCS=no \
+"
+
+export LIB_SUFFIX = "${@d.getVar('baselib', True).replace('lib', '')}"
+
+do_install() {
+    oe_runmake 'DESTDIR=${D}' install
+
+    install -d ${D}${systemd_unitdir}/system/
+    install -m 0644 ${S}/service/systemd/mosquitto.service.notify ${D}${systemd_unitdir}/system/mosquitto.service
+
+    install -d ${D}${sysconfdir}/mosquitto
+    install -m 0644 ${D}${sysconfdir}/mosquitto/mosquitto.conf.example \
+                    ${D}${sysconfdir}/mosquitto/mosquitto.conf
+
+    install -d ${D}${sysconfdir}/init.d/
+    install -m 0755 ${WORKDIR}/mosquitto.init ${D}${sysconfdir}/init.d/mosquitto
+    sed -i -e 's,@SBINDIR@,${sbindir},g' \
+        -e 's,@BASE_SBINDIR@,${base_sbindir},g' \
+        -e 's,@LOCALSTATEDIR@,${localstatedir},g' \
+        -e 's,@SYSCONFDIR@,${sysconfdir},g' \
+        ${D}${sysconfdir}/init.d/mosquitto
+}
+
+PACKAGES += "libmosquitto1 libmosquittopp1 ${PN}-clients"
+
+PACKAGE_BEFORE_PN = "${PN}-examples"
+
+FILES_${PN} = "${sbindir}/mosquitto \
+               ${bindir}/mosquitto_passwd \
+               ${sysconfdir}/mosquitto \
+               ${sysconfdir}/init.d \
+               ${systemd_unitdir}/system/mosquitto.service \
+"
+
+CONFFILES_${PN} += "${sysconfdir}/mosquitto/mosquitto.conf"
+
+FILES_libmosquitto1 = "${libdir}/libmosquitto.so.1"
+
+FILES_libmosquittopp1 = "${libdir}/libmosquittopp.so.1"
+
+FILES_${PN}-clients = "${bindir}/mosquitto_pub \
+                       ${bindir}/mosquitto_sub \
+"
+
+FILES_${PN}-examples = "${sysconfdir}/mosquitto/*.example"
+
+SYSTEMD_SERVICE_${PN} = "mosquitto.service"
+
+INITSCRIPT_NAME = "mosquitto"
+INITSCRIPT_PARAMS = "defaults 30"
+
+USERADD_PACKAGES = "${PN}"
+USERADD_PARAM_${PN} = "--system --no-create-home --shell /bin/false \
+                       --user-group mosquitto"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/nanomsg/nanomsg_1.1.4.bb b/meta-openembedded/meta-networking/recipes-connectivity/nanomsg/nanomsg_1.1.4.bb
new file mode 100644
index 0000000..fa6b43a
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/nanomsg/nanomsg_1.1.4.bb
@@ -0,0 +1,28 @@
+SUMMARY = "nanomsg socket library"
+DESCRIPTION = "nanomsg is a socket library that provides several common \
+communication patterns. It aims to make the networking layer fast, scalable, \
+and easy to use. Implemented in C, it works on a wide range of operating \
+systems with no further dependencies."
+HOMEPAGE = "https://nanomsg.org/"
+LICENSE = "MIT-X"
+LIC_FILES_CHKSUM = "file://COPYING;md5=587b3fd7fd291e418ff4d2b8f3904755"
+
+SECTION = "libs/networking"
+
+SRC_URI = "git://github.com/nanomsg/nanomsg.git;protocol=https"
+SRCREV = "e7f8a751316b942d8962cd0232c2d606c1d9a9db"
+
+S = "${WORKDIR}/git"
+
+inherit cmake pkgconfig
+
+# nanomsg documentation generation requires asciidoctor,
+# not asciidoc, and currently there's no asciidoctor-native
+# recipe anywhere in openembedded-core or meta-openembedded
+EXTRA_OECMAKE = " -DNN_ENABLE_DOC=OFF "
+
+# we don't want nanomsg-tools to be renamed to libnanomsg-tools
+DEBIAN_NOAUTONAME_${PN}-tools = "1"
+
+PACKAGES =+ "${PN}-tools"
+FILES_${PN}-tools = "${bindir}/*"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager-openvpn_1.2.10.bb b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager-openvpn_1.2.10.bb
new file mode 100644
index 0000000..9159fcb
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager-openvpn_1.2.10.bb
@@ -0,0 +1,40 @@
+SUMMARY = "NetworkManager-openvpn-plugin"
+SECTION = "net/misc"
+
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=100d5a599bead70ddcd70dcd73f2e29c"
+
+DEPENDS = "dbus dbus-glib networkmanager openvpn intltool-native glib-2.0-native"
+
+inherit gnomebase useradd gettext systemd
+
+SRC_URI = "${GNOME_MIRROR}/NetworkManager-openvpn/${@gnome_verdir("${PV}")}/NetworkManager-openvpn-${PV}.tar.xz"
+
+SRC_URI[md5sum] = "f118226ed2bfbacfd64ac4d1e0bd0383"
+SRC_URI[sha256sum] = "ac86a7a539d78df90095676e9183f2d422fb93dbfe4b3afef22f81825d303d61"
+
+S = "${WORKDIR}/NetworkManager-openvpn-${PV}"
+
+PACKAGECONFIG[gnome] = "--with-gnome,--without-gnome"
+
+do_install_append () {
+    rm -rf ${D}${libdir}/NetworkManager/*.la
+}
+
+# Create user and group nm-openvpn that are needed since version 1.0.6
+USERADD_PACKAGES = "${PN}"
+USERADD_PARAM_${PN} = "--system nm-openvpn"
+
+FILES_${PN} += " \
+    ${libdir}/NetworkManager/*.so \
+    ${nonarch_libdir}/NetworkManager/VPN/nm-openvpn-service.name \
+"
+
+FILES_${PN}-staticdev += " \
+    ${libdir}/NetworkManager/*.a \
+"
+
+RDEPENDS_${PN} = " \
+    networkmanager \
+    openvpn \
+"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager-openvpn_1.2.8.bb b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager-openvpn_1.2.8.bb
deleted file mode 100644
index 1b604ad..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager-openvpn_1.2.8.bb
+++ /dev/null
@@ -1,39 +0,0 @@
-SUMMARY = "NetworkManager-openvpn-plugin"
-SECTION = "net/misc"
-
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=100d5a599bead70ddcd70dcd73f2e29c"
-
-DEPENDS = "dbus dbus-glib networkmanager openvpn intltool-native glib-2.0-native"
-
-inherit gnomebase useradd gettext systemd
-
-SRC_URI = "${GNOME_MIRROR}/NetworkManager-openvpn/${@gnome_verdir("${PV}")}/NetworkManager-openvpn-${PV}.tar.xz"
-SRC_URI[md5sum] = "9f325be386aa906ff9b0b7c0bdf2a59a"
-SRC_URI[sha256sum] = "3e0b4007f248d96df4b8eb5d0f937536044af7053debbbf525e67c9bc5d30654"
-
-S = "${WORKDIR}/NetworkManager-openvpn-${PV}"
-
-PACKAGECONFIG[gnome] = "--with-gnome,--without-gnome"
-
-do_install_append () {
-    rm -rf ${D}${libdir}/NetworkManager/*.la
-}
-
-# Create user and group nm-openvpn that are needed since version 1.0.6
-USERADD_PACKAGES = "${PN}"
-USERADD_PARAM_${PN} = "--system nm-openvpn"
-
-FILES_${PN} += " \
-    ${libdir}/NetworkManager/*.so \
-    ${nonarch_libdir}/NetworkManager/VPN/nm-openvpn-service.name \
-"
-
-FILES_${PN}-staticdev += " \
-    ${libdir}/NetworkManager/*.a \
-"
-
-RDEPENDS_${PN} = " \
-    networkmanager \
-    openvpn \
-"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/0001-Do-not-include-net-ethernet.h-and-linux-if_ether.h.patch b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/0001-Do-not-include-net-ethernet.h-and-linux-if_ether.h.patch
new file mode 100644
index 0000000..0c415bc
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/0001-Do-not-include-net-ethernet.h-and-linux-if_ether.h.patch
@@ -0,0 +1,53 @@
+From 3f4b6319701834182304c4079119780f4ae5b49b Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 7 Nov 2018 11:30:44 -0800
+Subject: [PATCH] Do not include net/ethernet.h and linux/if_ether.h
+
+They conflict when used together especially with musl
+removing them still keeps it working so it seems they are redundant
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ shared/n-acd/src/n-acd.c              | 1 -
+ src/platform/wpan/nm-wpan-utils.h     | 2 --
+ src/settings/nm-settings-connection.h | 2 --
+ 3 files changed, 5 deletions(-)
+
+diff --git a/shared/n-acd/src/n-acd.c b/shared/n-acd/src/n-acd.c
+index 9164f95..9538e50 100644
+--- a/shared/n-acd/src/n-acd.c
++++ b/shared/n-acd/src/n-acd.c
+@@ -23,7 +23,6 @@
+ #include <errno.h>
+ #include <limits.h>
+ #include <linux/filter.h>
+-#include <linux/if_ether.h>
+ #include <linux/if_packet.h>
+ #include <net/ethernet.h>
+ #include <netinet/if_ether.h>
+diff --git a/src/platform/wpan/nm-wpan-utils.h b/src/platform/wpan/nm-wpan-utils.h
+index f7d0c03..e1c81f5 100644
+--- a/src/platform/wpan/nm-wpan-utils.h
++++ b/src/platform/wpan/nm-wpan-utils.h
+@@ -20,8 +20,6 @@
+ #ifndef __WPAN_UTILS_H__
+ #define __WPAN_UTILS_H__
+ 
+-#include <net/ethernet.h>
+-
+ #include "nm-dbus-interface.h"
+ #include "platform/nm-netlink.h"
+ 
+diff --git a/src/settings/nm-settings-connection.h b/src/settings/nm-settings-connection.h
+index e796b71..c01fef6 100644
+--- a/src/settings/nm-settings-connection.h
++++ b/src/settings/nm-settings-connection.h
+@@ -22,8 +22,6 @@
+ #ifndef __NETWORKMANAGER_SETTINGS_CONNECTION_H__
+ #define __NETWORKMANAGER_SETTINGS_CONNECTION_H__
+ 
+-#include <net/ethernet.h>
+-
+ #include "nm-dbus-object.h"
+ #include "nm-connection.h"
+ 
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/0001-sd-lldp.h-Remove-net-ethernet.h-seems-to-be-over-spe.patch b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/0001-sd-lldp.h-Remove-net-ethernet.h-seems-to-be-over-spe.patch
index 7194423..49a0735 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/0001-sd-lldp.h-Remove-net-ethernet.h-seems-to-be-over-spe.patch
+++ b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/0001-sd-lldp.h-Remove-net-ethernet.h-seems-to-be-over-spe.patch
@@ -1,8 +1,7 @@
 From 18f71c1b48730b8602826517f2b5b088283ae948 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 31 Mar 2017 16:48:00 -0700
-Subject: [PATCH 5/7] sd-lldp.h: Remove net/ethernet.h seems to be over
- specified
+Subject: [PATCH] sd-lldp.h: Remove net/ethernet.h seems to be over specified
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 ---
@@ -14,7 +13,7 @@
 index 31e2448..7721cc2 100644
 --- a/src/systemd/src/libsystemd-network/sd-lldp.c
 +++ b/src/systemd/src/libsystemd-network/sd-lldp.c
-@@ -21,6 +21,7 @@
+@@ -3,6 +3,7 @@
  #include "nm-sd-adapt.h"
  
  #include <arpa/inet.h>
@@ -26,7 +25,7 @@
 index 3f35eeb..61b0e45 100644
 --- a/src/systemd/src/systemd/sd-lldp.h
 +++ b/src/systemd/src/systemd/sd-lldp.h
-@@ -22,7 +22,7 @@
+@@ -18,7 +18,7 @@
  ***/
  
  #include <inttypes.h>
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/0002-Fixed-configure.ac-Fix-pkgconfig-sysroot-locations.patch b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/0002-Fixed-configure.ac-Fix-pkgconfig-sysroot-locations.patch
index 28848d3..351f264 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/0002-Fixed-configure.ac-Fix-pkgconfig-sysroot-locations.patch
+++ b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/0002-Fixed-configure.ac-Fix-pkgconfig-sysroot-locations.patch
@@ -1,7 +1,7 @@
 From 583f0448fb7e9aba2b410c06eec6f420b41a6a0c Mon Sep 17 00:00:00 2001
 From: Pablo Saavedra <psaavedra@igalia.com>
 Date: Tue, 13 Mar 2018 17:36:20 +0100
-Subject: [PATCH 7/7] Fixed configure.ac: Fix pkgconfig sysroot locations
+Subject: [PATCH] Fixed configure.ac: Fix pkgconfig sysroot locations
 
 ---
  configure.ac | 2 +-
@@ -11,7 +11,7 @@
 index 51e5eb6..c9d3e56 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -669,7 +669,7 @@ else
+@@ -572,7 +572,7 @@ if test "$have_jansson" = "yes"; then
  	AC_DEFINE(WITH_JANSSON, 1, [Define if JANSSON is enabled])
  
  	AC_CHECK_TOOLS(READELF, [eu-readelf readelf])
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/0003-Do-not-create-settings-settings-property-documentati.patch b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/0003-Do-not-create-settings-settings-property-documentati.patch
index 92485f0..c50293c 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/0003-Do-not-create-settings-settings-property-documentati.patch
+++ b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/0003-Do-not-create-settings-settings-property-documentati.patch
@@ -13,15 +13,15 @@
 
 Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
 ---
- Makefile.am  | 18 ++----------------
- configure.ac |  4 ----
- 2 files changed, 2 insertions(+), 20 deletions(-)
+ Makefile.am  | 20 --------------------
+ configure.ac |  5 -----
+ 2 files changed, 25 deletions(-)
 
 diff --git a/Makefile.am b/Makefile.am
-index 639921d..314a61d 100644
+index 1e100f6..d31e3c1 100644
 --- a/Makefile.am
 +++ b/Makefile.am
-@@ -961,9 +961,7 @@ endif
+@@ -1115,9 +1115,7 @@ EXTRA_DIST += \
  if HAVE_INTROSPECTION
  
  libnm_noinst_data = \
@@ -31,37 +31,39 @@
  	libnm/nm-settings-keyfile-docs.xml \
  	libnm/nm-settings-ifcfg-rh-docs.xml
  
-@@ -3317,23 +3315,11 @@ $(clients_common_libnmc_base_la_OBJECTS): $(libnm_core_lib_h_pub_mkenums)
+@@ -3692,27 +3690,9 @@ $(clients_common_libnmc_base_la_OBJECTS): $(libnm_lib_h_pub_mkenums)
  $(clients_common_libnmc_base_la_OBJECTS): clients/common/.dirstamp
  
- clients_common_settings_doc_c = clients/common/settings-docs.c
+ clients_common_settings_doc_h = clients/common/settings-docs.h
 -if HAVE_INTROSPECTION
--$(clients_common_settings_doc_c): clients/common/settings-docs.xsl libnm/nm-property-docs.xml clients/common/.dirstamp
+-$(clients_common_settings_doc_h): clients/common/settings-docs.xsl libnm/nm-property-docs.xml clients/common/.dirstamp
 -	$(AM_V_GEN) $(XSLTPROC) --output $@ $< $(word 2,$^)
--DISTCLEANFILES += $(clients_common_settings_doc_c)
--check-local-settings-docs: $(clients_common_settings_doc_c)
--	@if test -z "$$NMTST_NO_CHECK_SETTINGS_DOCS" ; then  \
--		if ! cmp -s "$(srcdir)/$(clients_common_settings_doc_c).in" "$(builddir)/$(clients_common_settings_doc_c)" ; then \
--			echo "The generated file \"$(builddir)/$(clients_common_settings_doc_c)\" differs from the source file \"$(srcdir)/$(clients_common_settings_doc_c).in\". You probably should copy the generated file over to the source file. You can skip this test by setting \$$NMTST_NO_CHECK_SETTINGS_DOCS=yes"; \
--			false; \
+-DISTCLEANFILES += $(clients_common_settings_doc_h)
+-check-local-settings-docs: $(clients_common_settings_doc_h)
+-	@if test -z "$$NMTST_NO_CHECK_SETTINGS_DOCS" ; then \
+-		if ! cmp -s "$(srcdir)/$(clients_common_settings_doc_h).in" "$(builddir)/$(clients_common_settings_doc_h)" ; then \
+-			if test "$$NM_TEST_REGENERATE" == 1 ; then \
+-				cp -f "$(builddir)/$(clients_common_settings_doc_h)" "$(srcdir)/$(clients_common_settings_doc_h).in"; \
+-			else \
+-				echo "The generated file \"$(builddir)/$(clients_common_settings_doc_h)\" differs from the source file \"$(srcdir)/$(clients_common_settings_doc_h).in\". You probably should copy the generated file over to the source file. You can skip this test by setting \$$NMTST_NO_CHECK_SETTINGS_DOCS=yes". You can also automatically copy the file by rerunning the test with \$$NM_TEST_REGENERATE=1 ; \
+-				false; \
+-			fi; \
 -		fi;\
 -	fi
 -check_local += check-local-settings-docs
 -else
-+
- $(clients_common_settings_doc_c): $(clients_common_settings_doc_c).in clients/common/.dirstamp
- 	$(AM_V_GEN) cp "$(srcdir)/$(clients_common_settings_doc_c).in" "$(builddir)/$(clients_common_settings_doc_c)"
+ $(clients_common_settings_doc_h): $(clients_common_settings_doc_h).in clients/common/.dirstamp
+ 	$(AM_V_GEN) cp "$(srcdir)/$(clients_common_settings_doc_h).in" "$(builddir)/$(clients_common_settings_doc_h)"
  check-local-settings-docs:
 -endif
-+
  EXTRA_DIST += \
- 	$(clients_common_settings_doc_c) \
- 	$(clients_common_settings_doc_c).in
+ 	$(clients_common_settings_doc_h) \
+ 	$(clients_common_settings_doc_h).in
 diff --git a/configure.ac b/configure.ac
-index c9d3e56..407222e 100644
+index 79dc3b9..23d14a6 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -1286,10 +1286,6 @@ GTK_DOC_CHECK(1.0)
+@@ -1195,11 +1195,6 @@ GTK_DOC_CHECK(1.0)
  # check if we can build setting property documentation
  build_docs=no
  if test -n "$INTROSPECTION_MAKEFILE"; then
@@ -69,9 +71,10 @@
 -	if ! "$PYTHON" -c 'from gi.repository import GObject' >& /dev/null; then
 -		AC_MSG_ERROR(["--enable-introspection aims to build the settings documentation. This requires GObject introspection for python (pygobject)])
 -	fi
- 
+-
  	AC_PATH_PROG(PERL, perl)
  	if test -z "$PERL"; then
+ 		AC_MSG_ERROR([--enable-introspection requires perl])
 -- 
-2.14.3
+2.14.5
 
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0001-musl-basic.patch b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0001-musl-basic.patch
index 9d208e1..00dda5b 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0001-musl-basic.patch
+++ b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0001-musl-basic.patch
@@ -1,7 +1,7 @@
 From e92de7409a3e107f90d108a9c5d49bd0418296dd Mon Sep 17 00:00:00 2001
 From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
 Date: Thu, 22 Mar 2018 17:54:10 +0100
-Subject: [PATCH 1/4] Usual fix for musl libc
+Subject: [PATCH] Usual fix for musl libc
 MIME-Version: 1.0
 Content-Type: text/plain; charset=UTF-8
 Content-Transfer-Encoding: 8bit
@@ -13,18 +13,19 @@
 [1] https://github.com/voidlinux/void-packages/tree/master/srcpkgs/NetworkManager/patches
 
 Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
+
 ---
  src/systemd/src/basic/stdio-util.h | 2 ++
  src/systemd/src/basic/util.h       | 5 +++++
  2 files changed, 7 insertions(+)
 
 diff --git a/src/systemd/src/basic/stdio-util.h b/src/systemd/src/basic/stdio-util.h
-index bd1144b..9eafacb 100644
+index 73c0327..e1ce64f 100644
 --- a/src/systemd/src/basic/stdio-util.h
 +++ b/src/systemd/src/basic/stdio-util.h
-@@ -19,7 +19,9 @@
-   along with systemd; If not, see <http://www.gnu.org/licenses/>.
- ***/
+@@ -1,7 +1,9 @@
+ /* SPDX-License-Identifier: LGPL-2.1+ */
+ #pragma once
  
 +#if defined(__GLIBC__)
  #include <printf.h>
@@ -36,7 +37,7 @@
 index b31dfd1..9b7032c 100644
 --- a/src/systemd/src/basic/util.h
 +++ b/src/systemd/src/basic/util.h
-@@ -46,6 +46,11 @@
+@@ -28,6 +28,11 @@
  #include "missing.h"
  #include "time-util.h"
  
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0002-musl-dlopen-configure-ac.patch b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0002-musl-dlopen-configure-ac.patch
index 548cccb..c162c1d 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0002-musl-dlopen-configure-ac.patch
+++ b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0002-musl-dlopen-configure-ac.patch
@@ -1,7 +1,7 @@
 From 57239fda56b68a8f3e413f7b6af5290ba0d86636 Mon Sep 17 00:00:00 2001
 From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
 Date: Thu, 22 Mar 2018 18:18:06 +0100
-Subject: [PATCH 2/4] musl: dlopen is included so LD_LIBS="" instead of
+Subject: [PATCH] musl: dlopen is included so LD_LIBS="" instead of
  LD_LIBS="none required"
 MIME-Version: 1.0
 Content-Type: text/plain; charset=UTF-8
@@ -22,7 +22,7 @@
 index 487a266..96ae4f7 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -305,6 +305,7 @@ dnl
+@@ -235,6 +235,7 @@ dnl
  dnl Checks for libdl - on certain platforms its part of libc
  dnl
  AC_SEARCH_LIBS([dlopen], [dl dld], [], [ac_cv_search_dlopen=])
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0003-musl-network-support.patch b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0003-musl-network-support.patch
index 5dd17b6..9a58c0e 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0003-musl-network-support.patch
+++ b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0003-musl-network-support.patch
@@ -1,7 +1,7 @@
 From 714b4731a238653e9c7d885c0dee10677b0a4df3 Mon Sep 17 00:00:00 2001
 From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
 Date: Thu, 22 Mar 2018 18:24:07 +0100
-Subject: [PATCH 3/4] musl: network support
+Subject: [PATCH] musl: network support
 MIME-Version: 1.0
 Content-Type: text/plain; charset=UTF-8
 Content-Transfer-Encoding: 8bit
@@ -15,7 +15,7 @@
 Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
 ---
  libnm-core/nm-utils.h               | 4 ++++
- src/platform/wifi/wifi-utils.h      | 4 ++++
+ src/platform/wifi/nm-wifi-utils.h   | 4 ++++
  src/systemd/src/basic/socket-util.h | 5 +++++
  3 files changed, 13 insertions(+)
 
@@ -35,10 +35,10 @@
  #include <linux/if_infiniband.h>
  
  #include "nm-core-enum-types.h"
-diff --git a/src/platform/wifi/wifi-utils.h b/src/platform/wifi/wifi-utils.h
+diff --git a/src/platform/wifi/nm-wifi-utils.h b/src/platform/wifi/nm-wifi-utils.h
 index 705717b..da3edc4 100644
---- a/src/platform/wifi/wifi-utils.h
-+++ b/src/platform/wifi/wifi-utils.h
+--- a/src/platform/wifi/nm-wifi-utils.h
++++ b/src/platform/wifi/nm-wifi-utils.h
 @@ -22,7 +22,11 @@
  #ifndef __WIFI_UTILS_H__
  #define __WIFI_UTILS_H__
@@ -50,12 +50,12 @@
 +#endif
  
  #include "nm-dbus-interface.h"
- 
+ #include "nm-setting-wireless.h"
 diff --git a/src/systemd/src/basic/socket-util.h b/src/systemd/src/basic/socket-util.h
 index d7e2d85..d109c84 100644
 --- a/src/systemd/src/basic/socket-util.h
 +++ b/src/systemd/src/basic/socket-util.h
-@@ -29,6 +29,11 @@
+@@ -11,6 +11,11 @@
  #include <linux/netlink.h>
  #include <linux/if_infiniband.h>
  #include <linux/if_packet.h>
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0004-musl-process-util.patch b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0004-musl-process-util.patch
index fc55ce8..9e5c943 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0004-musl-process-util.patch
+++ b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0004-musl-process-util.patch
@@ -1,7 +1,7 @@
 From d513c8bfc982dbd976617178b040c512c95710b6 Mon Sep 17 00:00:00 2001
 From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
-Date: Thu, 22 Mar 2018 18:29:00 +0100
-Subject: [PATCH 4/4] musl: process-util
+Date: Thu, 25 Oct 2018 09:57:07 +0200
+Subject: [PATCH] musl: process-util
 MIME-Version: 1.0
 Content-Type: text/plain; charset=UTF-8
 Content-Transfer-Encoding: 8bit
@@ -18,10 +18,10 @@
  1 file changed, 9 insertions(+)
 
 diff --git a/src/systemd/src/basic/process-util.c b/src/systemd/src/basic/process-util.c
-index 272030d..485f1db 100644
+index 1412f03..45f5049 100644
 --- a/src/systemd/src/basic/process-util.c
 +++ b/src/systemd/src/basic/process-util.c
-@@ -36,6 +36,9 @@
+@@ -21,6 +21,9 @@
  #include <sys/wait.h>
  #include <syslog.h>
  #include <unistd.h>
@@ -31,7 +31,7 @@
  #if 0 /* NM_IGNORED */
  #if HAVE_VALGRIND_VALGRIND_H
  #include <valgrind/valgrind.h>
-@@ -1015,11 +1018,13 @@ static void reset_cached_pid(void) {
+@@ -1153,11 +1156,13 @@ void reset_cached_pid(void) {
          cached_pid = CACHED_PID_UNSET;
  }
  
@@ -39,24 +39,24 @@
  /* We use glibc __register_atfork() + __dso_handle directly here, as they are not included in the glibc
   * headers. __register_atfork() is mostly equivalent to pthread_atfork(), but doesn't require us to link against
   * libpthread, as it is part of glibc anyway. */
- extern int __register_atfork(void (*prepare) (void), void (*parent) (void), void (*child) (void), void * __dso_handle);
+ extern int __register_atfork(void (*prepare) (void), void (*parent) (void), void (*child) (void), void *dso_handle);
  extern void* __dso_handle __attribute__ ((__weak__));
 +#endif
  
  pid_t getpid_cached(void) {
-         pid_t current_value;
-@@ -1042,7 +1047,11 @@ pid_t getpid_cached(void) {
- 
-                 new_pid = getpid();
+         static bool installed = false;
+@@ -1186,7 +1191,11 @@ pid_t getpid_cached(void) {
+                          * only half-documented (glibc doesn't document it but LSB does — though only superficially)
+                          * we'll check for errors only in the most generic fashion possible. */
  
 +#ifdef __GLIBC__
-                 if (__register_atfork(NULL, NULL, reset_cached_pid, __dso_handle) != 0) {
+                         if (__register_atfork(NULL, NULL, reset_cached_pid, __dso_handle) != 0) {
 +#else
-+                if (pthread_atfork(NULL, NULL, reset_cached_pid) != 0) {
++                        if (pthread_atfork(NULL, NULL, reset_cached_pid) != 0) {
 +#endif
-                         /* OOM? Let's try again later */
-                         cached_pid = CACHED_PID_UNSET;
-                         return new_pid;
+                                 /* OOM? Let's try again later */
+                                 cached_pid = CACHED_PID_UNSET;
+                                 return new_pid;
 -- 
-2.14.3
+2.14.5
 
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0005-musl-avoid-further-conflicts-by-including-net-ethern.patch b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0005-musl-avoid-further-conflicts-by-including-net-ethern.patch
index 752fe4f..6bca95e 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0005-musl-avoid-further-conflicts-by-including-net-ethern.patch
+++ b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0005-musl-avoid-further-conflicts-by-including-net-ethern.patch
@@ -17,10 +17,10 @@
  4 files changed, 8 insertions(+)
 
 diff --git a/src/systemd/src/systemd/sd-dhcp-client.h b/src/systemd/src/systemd/sd-dhcp-client.h
-index 5e46d8d..18a613f 100644
+index e388552..9c4dde8 100644
 --- a/src/systemd/src/systemd/sd-dhcp-client.h
 +++ b/src/systemd/src/systemd/sd-dhcp-client.h
-@@ -21,7 +21,9 @@
+@@ -20,7 +20,9 @@
  ***/
  
  #include <inttypes.h>
@@ -31,10 +31,10 @@
  #include <sys/types.h>
  
 diff --git a/src/systemd/src/systemd/sd-dhcp-lease.h b/src/systemd/src/systemd/sd-dhcp-lease.h
-index 7ab99cc..85acdf2 100644
+index 2a60145..19d1814 100644
 --- a/src/systemd/src/systemd/sd-dhcp-lease.h
 +++ b/src/systemd/src/systemd/sd-dhcp-lease.h
-@@ -22,7 +22,9 @@
+@@ -19,7 +19,9 @@
  ***/
  
  #include <inttypes.h>
@@ -45,24 +45,24 @@
  #include <sys/types.h>
  
 diff --git a/src/systemd/src/systemd/sd-dhcp6-client.h b/src/systemd/src/systemd/sd-dhcp6-client.h
-index 7819f0d..35f30ee 100644
+index fa36dca..2d25010 100644
 --- a/src/systemd/src/systemd/sd-dhcp6-client.h
 +++ b/src/systemd/src/systemd/sd-dhcp6-client.h
-@@ -21,7 +21,9 @@
+@@ -20,7 +20,9 @@
  ***/
  
  #include <inttypes.h>
 +#if defined(__GLIBC__)
  #include <net/ethernet.h>
 +#endif
+ #include <stdbool.h>
  #include <sys/types.h>
  
- #include "sd-dhcp6-lease.h"
 diff --git a/src/systemd/src/systemd/sd-ipv4ll.h b/src/systemd/src/systemd/sd-ipv4ll.h
-index 5ba9208..c90eca6 100644
+index 71bd4cf..1c667ba 100644
 --- a/src/systemd/src/systemd/sd-ipv4ll.h
 +++ b/src/systemd/src/systemd/sd-ipv4ll.h
-@@ -20,7 +20,9 @@
+@@ -19,7 +19,9 @@
    along with systemd; If not, see <http://www.gnu.org/licenses/>.
  ***/
  
@@ -73,5 +73,5 @@
  
  #include "sd-event.h"
 -- 
-2.14.3
+2.14.5
 
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0006-Add-a-strndupa-replacement-for-musl.patch b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0006-Add-a-strndupa-replacement-for-musl.patch
index 8ed7ee6..023a4d9 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0006-Add-a-strndupa-replacement-for-musl.patch
+++ b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager/musl/0006-Add-a-strndupa-replacement-for-musl.patch
@@ -18,7 +18,7 @@
 index 2a02d90..a57c360 100644
 --- a/src/systemd/src/basic/in-addr-util.c
 +++ b/src/systemd/src/basic/in-addr-util.c
-@@ -30,6 +30,7 @@
+@@ -13,6 +13,7 @@
  #include "in-addr-util.h"
  #include "macro.h"
  #include "parse-util.h"
@@ -30,7 +30,7 @@
 index 4c94b18..a6dc446 100644
 --- a/src/systemd/src/basic/string-util.h
 +++ b/src/systemd/src/basic/string-util.h
-@@ -44,6 +44,11 @@
+@@ -26,6 +26,11 @@
  #define strcaseeq(a,b) (strcasecmp((a),(b)) == 0)
  #define strncaseeq(a, b, n) (strncasecmp((a), (b), (n)) == 0)
  
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager_1.10.6.bb b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager_1.10.6.bb
deleted file mode 100644
index 09c5dbd..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager_1.10.6.bb
+++ /dev/null
@@ -1,143 +0,0 @@
-SUMMARY = "NetworkManager"
-HOMEPAGE = "https://wiki.gnome.org/Projects/NetworkManager"
-SECTION = "net/misc"
-
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=cbbffd568227ada506640fe950a4823b \
-                    file://libnm-util/COPYING;md5=1c4fa765d6eb3cd2fbd84344a1b816cd \
-                    file://docs/api/html/license.html;md5=77b9e362690c149da196aefe7712db30 \
-"
-
-DEPENDS = " \
-    intltool-native \
-    libxslt-native \
-    libnl \
-    dbus \
-    dbus-glib \
-    dbus-glib-native \
-    libgudev \
-    util-linux \
-    libndp \
-    libnewt \
-    polkit \
-    jansson \
-    curl \
-"
-
-inherit gnomebase gettext systemd bluetooth bash-completion vala gobject-introspection gtk-doc
-
-SRC_URI = " \
-    ${GNOME_MIRROR}/NetworkManager/${@gnome_verdir("${PV}")}/NetworkManager-${PV}.tar.xz \
-    file://0001-sd-lldp.h-Remove-net-ethernet.h-seems-to-be-over-spe.patch \
-    file://0002-Fixed-configure.ac-Fix-pkgconfig-sysroot-locations.patch \
-    file://0003-Do-not-create-settings-settings-property-documentati.patch \
-    file://musl/0001-musl-basic.patch \
-    file://musl/0002-musl-dlopen-configure-ac.patch \
-    file://musl/0003-musl-network-support.patch \
-    file://musl/0004-musl-process-util.patch \
-    file://musl/0005-musl-avoid-further-conflicts-by-including-net-ethern.patch \
-    file://musl/0006-Add-a-strndupa-replacement-for-musl.patch \
-"
-SRC_URI[md5sum] = "de3c7147a693da6f80eb22f126086a14"
-SRC_URI[sha256sum] = "6af0b1e856a3725f88791f55c4fbb04105dc0b20dbf182aaec8aad16481fac76"
-
-S = "${WORKDIR}/NetworkManager-${PV}"
-
-EXTRA_OECONF = " \
-    --disable-ifcfg-rh \
-    --disable-ifnet \
-    --disable-ifcfg-suse \
-    --disable-more-warnings \
-    --with-iptables=${sbindir}/iptables \
-    --with-tests \
-    --with-nmtui=yes \
-"
-
-# gobject-introspection related
-GI_DATA_ENABLED_libc-musl = "False"
-
-# stolen from https://github.com/voidlinux/void-packages/blob/master/srcpkgs/NetworkManager/template
-CFLAGS_libc-musl_append = " \
-    -DHAVE_SECURE_GETENV -Dsecure_getenv=getenv \
-    -D__USE_POSIX199309 -DRTLD_DEEPBIND=0 \
-"
-
-do_compile_prepend() {
-    export GIR_EXTRA_LIBS_PATH="${B}/libnm/.libs:${B}/libnm-glib/.libs:${B}/libnm-util/.libs"
-}
-
-PACKAGECONFIG ??= "nss ifupdown netconfig dhclient dnsmasq \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', bb.utils.contains('DISTRO_FEATURES', 'x11', 'consolekit', '', d), d)} \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', '${BLUEZ}', '', d)} \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'wifi', d)} \
-"
-PACKAGECONFIG[systemd] = " \
-    --with-systemdsystemunitdir=${systemd_unitdir}/system --with-session-tracking=systemd --enable-polkit, \
-    --without-systemdsystemunitdir, \
-    polkit \
-"
-PACKAGECONFIG[bluez5] = "--enable-bluez5-dun,--disable-bluez5-dun,bluez5"
-# consolekit is not picked by shlibs, so add it to RDEPENDS too
-PACKAGECONFIG[consolekit] = "--with-session-tracking=consolekit,,consolekit,consolekit"
-PACKAGECONFIG[modemmanager] = "--with-modem-manager-1=yes,--with-modem-manager-1=no,modemmanager"
-PACKAGECONFIG[ppp] = "--enable-ppp,--disable-ppp,ppp,ppp"
-# Use full featured dhcp client instead of internal one
-PACKAGECONFIG[dhclient] = "--with-dhclient=${base_sbindir}/dhclient,,,dhcp-client"
-PACKAGECONFIG[dnsmasq] = "--with-dnsmasq=${bindir}/dnsmasq"
-PACKAGECONFIG[nss] = "--with-crypto=nss,,nss"
-PACKAGECONFIG[gnutls] = "--with-crypto=gnutls,,gnutls"
-PACKAGECONFIG[wifi] = "--enable-wifi=yes,--enable-wifi=no,wireless-tools,wpa-supplicant wireless-tools"
-PACKAGECONFIG[ifupdown] = "--enable-ifupdown,--disable-ifupdown"
-PACKAGECONFIG[netconfig] = "--with-netconfig=yes,--with-netconfig=no"
-PACKAGECONFIG[qt4-x11-free] = "--enable-qt,--disable-qt,qt4-x11-free"
-
-PACKAGES =+ "libnmutil libnmglib libnmglib-vpn \
-  ${PN}-nmtui ${PN}-nmtui-doc \
-  ${PN}-adsl \
-"
-
-FILES_libnmutil += "${libdir}/libnm-util.so.*"
-FILES_libnmglib += "${libdir}/libnm-glib.so.*"
-FILES_libnmglib-vpn += "${libdir}/libnm-glib-vpn.so.*"
-
-FILES_${PN}-adsl = "${libdir}/NetworkManager/libnm-device-plugin-adsl.so"
-
-FILES_${PN} += " \
-    ${libexecdir} \
-    ${libdir}/pppd/*/nm-pppd-plugin.so \
-    ${libdir}/NetworkManager/*.so \
-    ${nonarch_libdir}/NetworkManager/VPN \
-    ${nonarch_libdir}/NetworkManager/conf.d \
-    ${datadir}/polkit-1 \
-    ${datadir}/dbus-1 \
-    ${base_libdir}/udev/* \
-    ${systemd_unitdir}/system \
-"
-
-RRECOMMENDS_${PN} += "iptables \
-    ${@bb.utils.filter('PACKAGECONFIG', 'dnsmasq', d)} \
-"
-RCONFLICTS_${PN} = "connman"
-
-FILES_${PN}-dev += " \
-    ${datadir}/NetworkManager/gdb-cmd \
-    ${libdir}/pppd/*/*.la \
-    ${libdir}/NetworkManager/*.la \
-"
-
-FILES_${PN}-nmtui = " \
-    ${bindir}/nmtui \
-    ${bindir}/nmtui-edit \
-    ${bindir}/nmtui-connect \
-    ${bindir}/nmtui-hostname \
-"
-
-FILES_${PN}-nmtui-doc = " \
-    ${mandir}/man1/nmtui* \
-"
-
-SYSTEMD_SERVICE_${PN} = "NetworkManager.service NetworkManager-dispatcher.service"
-
-do_install_append() {
-    rm -rf ${D}/run ${D}${localstatedir}/run
-}
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager_1.14.4.bb b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager_1.14.4.bb
new file mode 100644
index 0000000..4cc4dba
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/networkmanager/networkmanager_1.14.4.bb
@@ -0,0 +1,142 @@
+SUMMARY = "NetworkManager"
+HOMEPAGE = "https://wiki.gnome.org/Projects/NetworkManager"
+SECTION = "net/misc"
+
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=cbbffd568227ada506640fe950a4823b \
+                    file://libnm-util/COPYING;md5=1c4fa765d6eb3cd2fbd84344a1b816cd \
+                    file://docs/api/html/license.html;md5=2d56a1b0c42e388aa86aef59b154e8c3 \
+"
+
+DEPENDS = " \
+    intltool-native \
+    libxslt-native \
+    libnl \
+    libgudev \
+    util-linux \
+    libndp \
+    libnewt \
+    polkit \
+    jansson \
+    curl \
+"
+
+inherit gnomebase gettext systemd bluetooth bash-completion vala gobject-introspection gtk-doc
+
+SRC_URI = " \
+    ${GNOME_MIRROR}/NetworkManager/${@gnome_verdir("${PV}")}/NetworkManager-${PV}.tar.xz \
+    file://0001-sd-lldp.h-Remove-net-ethernet.h-seems-to-be-over-spe.patch \
+    file://0002-Fixed-configure.ac-Fix-pkgconfig-sysroot-locations.patch \
+    file://0003-Do-not-create-settings-settings-property-documentati.patch \
+    file://0001-Do-not-include-net-ethernet.h-and-linux-if_ether.h.patch \
+    file://musl/0001-musl-basic.patch \
+    file://musl/0002-musl-dlopen-configure-ac.patch \
+    file://musl/0003-musl-network-support.patch \
+    file://musl/0004-musl-process-util.patch \
+    file://musl/0005-musl-avoid-further-conflicts-by-including-net-ethern.patch \
+    file://musl/0006-Add-a-strndupa-replacement-for-musl.patch \
+"
+SRC_URI[md5sum] = "54ce62f0aa18ef6c5e754eaac47494ac"
+SRC_URI[sha256sum] = "35a3ede4c7d12d6212033c9e44cb82b7692f38063b53a067567f02f5937c8c18"
+
+UPSTREAM_CHECK_URI = "${GNOME_MIRROR}/NetworkManager/1.10/"
+UPSTREAM_CHECK_REGEX = "NetworkManager\-(?P<pver>1\.10(\.\d+)+).tar.xz"
+
+S = "${WORKDIR}/NetworkManager-${PV}"
+
+EXTRA_OECONF = " \
+    --disable-ifcfg-rh \
+    --disable-more-warnings \
+    --with-iptables=${sbindir}/iptables \
+    --with-tests \
+    --with-nmtui=yes \
+"
+
+# gobject-introspection related
+GI_DATA_ENABLED_libc-musl = "False"
+
+# stolen from https://github.com/voidlinux/void-packages/blob/master/srcpkgs/NetworkManager/template
+CFLAGS_libc-musl_append = " \
+    -DHAVE_SECURE_GETENV -Dsecure_getenv=getenv \
+    -D__USE_POSIX199309 -DRTLD_DEEPBIND=0 \
+"
+
+do_compile_prepend() {
+    export GIR_EXTRA_LIBS_PATH="${B}/libnm/.libs:${B}/libnm-glib/.libs:${B}/libnm-util/.libs"
+}
+
+PACKAGECONFIG ??= "nss ifupdown dhclient dnsmasq \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', bb.utils.contains('DISTRO_FEATURES', 'x11', 'consolekit', '', d), d)} \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', '${BLUEZ}', '', d)} \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'wifi', d)} \
+"
+PACKAGECONFIG[systemd] = " \
+    --with-systemdsystemunitdir=${systemd_unitdir}/system --with-session-tracking=systemd --enable-polkit, \
+    --without-systemdsystemunitdir, \
+    polkit \
+"
+PACKAGECONFIG[bluez5] = "--enable-bluez5-dun,--disable-bluez5-dun,bluez5"
+# consolekit is not picked by shlibs, so add it to RDEPENDS too
+PACKAGECONFIG[consolekit] = "--with-session-tracking=consolekit,,consolekit,consolekit"
+PACKAGECONFIG[modemmanager] = "--with-modem-manager-1=yes,--with-modem-manager-1=no,modemmanager"
+PACKAGECONFIG[ppp] = "--enable-ppp,--disable-ppp,ppp,ppp"
+# Use full featured dhcp client instead of internal one
+PACKAGECONFIG[dhclient] = "--with-dhclient=${base_sbindir}/dhclient,,,dhcp-client"
+PACKAGECONFIG[dnsmasq] = "--with-dnsmasq=${bindir}/dnsmasq"
+PACKAGECONFIG[nss] = "--with-crypto=nss,,nss"
+PACKAGECONFIG[glib] = "--with-libnm-glib,,dbus-glib-native dbus-glib"
+PACKAGECONFIG[gnutls] = "--with-crypto=gnutls,,gnutls"
+PACKAGECONFIG[wifi] = "--enable-wifi=yes,--enable-wifi=no,,wpa-supplicant"
+PACKAGECONFIG[ifupdown] = "--enable-ifupdown,--disable-ifupdown"
+PACKAGECONFIG[qt4-x11-free] = "--enable-qt,--disable-qt,qt4-x11-free"
+
+PACKAGES =+ "libnmutil libnmglib libnmglib-vpn \
+  ${PN}-nmtui ${PN}-nmtui-doc \
+  ${PN}-adsl \
+"
+
+FILES_libnmutil += "${libdir}/libnm-util.so.*"
+FILES_libnmglib += "${libdir}/libnm-glib.so.*"
+FILES_libnmglib-vpn += "${libdir}/libnm-glib-vpn.so.*"
+
+FILES_${PN}-adsl = "${libdir}/NetworkManager/libnm-device-plugin-adsl.so"
+
+FILES_${PN} += " \
+    ${libexecdir} \
+    ${libdir}/NetworkManager/${PV}/*.so \
+    ${nonarch_libdir}/NetworkManager/VPN \
+    ${nonarch_libdir}/NetworkManager/conf.d \
+    ${datadir}/polkit-1 \
+    ${datadir}/dbus-1 \
+    ${base_libdir}/udev/* \
+    ${systemd_unitdir}/system \
+"
+
+RRECOMMENDS_${PN} += "iptables \
+    ${@bb.utils.filter('PACKAGECONFIG', 'dnsmasq', d)} \
+"
+RCONFLICTS_${PN} = "connman"
+
+FILES_${PN}-dev += " \
+    ${datadir}/NetworkManager/gdb-cmd \
+    ${libdir}/pppd/*/*.la \
+    ${libdir}/NetworkManager/*.la \
+    ${libdir}/NetworkManager/${PV}/*.la \
+"
+
+FILES_${PN}-nmtui = " \
+    ${bindir}/nmtui \
+    ${bindir}/nmtui-edit \
+    ${bindir}/nmtui-connect \
+    ${bindir}/nmtui-hostname \
+"
+
+FILES_${PN}-nmtui-doc = " \
+    ${mandir}/man1/nmtui* \
+"
+
+SYSTEMD_SERVICE_${PN} = "NetworkManager.service NetworkManager-dispatcher.service"
+
+do_install_append() {
+    rm -rf ${D}/run ${D}${localstatedir}/run
+}
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/rdist/rdist_6.1.5.bb b/meta-openembedded/meta-networking/recipes-connectivity/rdist/rdist_6.1.5.bb
index cea1f08..4fe6893 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/rdist/rdist_6.1.5.bb
+++ b/meta-openembedded/meta-networking/recipes-connectivity/rdist/rdist_6.1.5.bb
@@ -30,8 +30,14 @@
             file://rdist-6.1.5-makefile-add-ldflags.patch \
 "
 
+UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/rdist/files/rdist/"
+UPSTREAM_CHECK_REGEX = "/rdist/(?P<pver>\d+(\.\d+)+)"
+
 DEPENDS = "bison-native"
 
 inherit autotools-brokensep
 
 EXTRA_OEMAKE = "BIN_GROUP=root MAN_GROUP=root RDIST_MODE=755 RDISTD_MODE=755 MAN_MODE=644"
+
+# http://errors.yoctoproject.org/Errors/Details/186972/
+EXCLUDE_FROM_WORLD_libc-musl = "1"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/0001-ldb-Refuse-to-build-Samba-against-a-newer-minor-vers.patch b/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/0001-ldb-Refuse-to-build-Samba-against-a-newer-minor-vers.patch
new file mode 100644
index 0000000..4c94831
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/0001-ldb-Refuse-to-build-Samba-against-a-newer-minor-vers.patch
@@ -0,0 +1,86 @@
+From 0bc8bc4143a58f91f6d7ce228b6763f377fdf45a Mon Sep 17 00:00:00 2001
+From: Andrew Bartlett <abartlet@samba.org>
+Date: Thu, 12 Jul 2018 12:34:56 +1200
+Subject: [PATCH] ldb: Refuse to build Samba against a newer minor version of
+ ldb
+
+Samba is not compatible with new versions of ldb (except release versions)
+
+Other users would not notice the breakages, but Samba makes many
+more assuptions about the LDB internals than any other package.
+
+(Specifically, LDB 1.2 and 1.4 broke builds against released
+Samba versions)
+
+BUG: https://bugzilla.samba.org/show_bug.cgi?id=13519
+
+Signed-off-by: Andrew Bartlett <abartlet@samba.org>
+Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
+(cherry picked from commit 52efa796538ae004ca62ea32fc8c833472991be6)
+---
+ lib/ldb/wscript | 32 ++++++++++++++++++++++----------
+ 1 file changed, 22 insertions(+), 10 deletions(-)
+
+diff --git a/lib/ldb/wscript b/lib/ldb/wscript
+index d94086b..2bb0832 100644
+--- a/lib/ldb/wscript
++++ b/lib/ldb/wscript
+@@ -62,23 +62,33 @@ def configure(conf):
+     conf.env.standalone_ldb = conf.IN_LAUNCH_DIR()
+ 
+     if not conf.env.standalone_ldb:
++        max_ldb_version = [int(x) for x in VERSION.split(".")]
++        max_ldb_version[2] = 999
++        max_ldb_version_dots = "%d.%d.%d" % tuple(max_ldb_version)
++
+         if conf.env.disable_python:
+-            if conf.CHECK_BUNDLED_SYSTEM_PKG('ldb', minversion=VERSION,
+-                                         onlyif='talloc tdb tevent',
+-                                         implied_deps='replace talloc tdb tevent'):
++            if conf.CHECK_BUNDLED_SYSTEM_PKG('ldb',
++                                             minversion=VERSION,
++                                             maxversion=max_ldb_version_dots,
++                                             onlyif='talloc tdb tevent',
++                                             implied_deps='replace talloc tdb tevent'):
+                 conf.define('USING_SYSTEM_LDB', 1)
+         else:
+             using_system_pyldb_util = True
+-            if not conf.CHECK_BUNDLED_SYSTEM_PKG('pyldb-util', minversion=VERSION,
+-                                             onlyif='talloc tdb tevent',
+-                                             implied_deps='replace talloc tdb tevent ldb'):
++            if not conf.CHECK_BUNDLED_SYSTEM_PKG('pyldb-util',
++                                                 minversion=VERSION,
++                                                 maxversion=max_ldb_version_dots,
++                                                 onlyif='talloc tdb tevent',
++                                                 implied_deps='replace talloc tdb tevent ldb'):
+                 using_system_pyldb_util = False
+ 
+             # We need to get a pyldb-util for all the python versions
+             # we are building for
+             if conf.env['EXTRA_PYTHON']:
+                 name = 'pyldb-util' + conf.all_envs['extrapython']['PYTHON_SO_ABI_FLAG']
+-                if not conf.CHECK_BUNDLED_SYSTEM_PKG(name, minversion=VERSION,
++                if not conf.CHECK_BUNDLED_SYSTEM_PKG(name,
++                                                     minversion=VERSION,
++                                                     maxversion=max_ldb_version_dots,
+                                                      onlyif='talloc tdb tevent',
+                                                      implied_deps='replace talloc tdb tevent ldb'):
+                     using_system_pyldb_util = False
+@@ -86,9 +96,11 @@ def configure(conf):
+             if using_system_pyldb_util:
+                 conf.define('USING_SYSTEM_PYLDB_UTIL', 1)
+ 
+-            if conf.CHECK_BUNDLED_SYSTEM_PKG('ldb', minversion=VERSION,
+-                                         onlyif='talloc tdb tevent pyldb-util',
+-                                         implied_deps='replace talloc tdb tevent'):
++            if conf.CHECK_BUNDLED_SYSTEM_PKG('ldb',
++                                             minversion=VERSION,
++                                             maxversion=max_ldb_version_dots,
++                                             onlyif='talloc tdb tevent pyldb-util',
++                                             implied_deps='replace talloc tdb tevent'):
+                 conf.define('USING_SYSTEM_LDB', 1)
+ 
+     if conf.CONFIG_SET('USING_SYSTEM_LDB'):
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/0001-packaging-Avoid-timeout-for-nmbd-if-started-offline-.patch b/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/0001-packaging-Avoid-timeout-for-nmbd-if-started-offline-.patch
deleted file mode 100644
index 0e89a9b..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/0001-packaging-Avoid-timeout-for-nmbd-if-started-offline-.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-Upstream-Status: Submitted [https://github.com/samba-team/samba/pull/70]
-
-Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
-
-From 50eac4fd30944e5e1d83060757633fe0ed572723 Mon Sep 17 00:00:00 2001
-From: Andreas Oberritter <obi@opendreambox.org>
-Date: Wed, 30 Nov 2016 16:25:06 +0100
-Subject: [PATCH] packaging: Avoid timeout for nmbd if started offline with
- systemd
-
-If no network connection appears within DefaultTimeoutStartSec
-(~ 90s) after startup, nmbd fails to notify systemd and will
-therefore get killed.
-
-Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
-
----
- packaging/systemd/nmb.service | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/packaging/systemd/nmb.service b/packaging/systemd/nmb.service
-index 71c93d6..f3d2fc2 100644
---- a/packaging/systemd/nmb.service
-+++ b/packaging/systemd/nmb.service
-@@ -10,6 +10,7 @@ EnvironmentFile=-/etc/sysconfig/samba
- ExecStart=/usr/sbin/nmbd --foreground --no-process-group $NMBDOPTIONS
- ExecReload=/usr/bin/kill -HUP $MAINPID
- LimitCORE=infinity
-+TimeoutStartSec=0
- 
- [Install]
- WantedBy=multi-user.target
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/0006-avoid-using-colon-in-the-checking-msg.patch b/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/0006-avoid-using-colon-in-the-checking-msg.patch
deleted file mode 100644
index cdf7a38..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/0006-avoid-using-colon-in-the-checking-msg.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From 5413f97290d3126262eb309ecbcf7769509f2a11 Mon Sep 17 00:00:00 2001
-From: Jackie Huang <jackie.huang@windriver.com>
-Date: Tue, 10 Nov 2015 00:48:35 -0500
-Subject: [PATCH 6/7] avoid using colon in the checking msg
-
-Upstream-Status: Pending
-
-colon is used as the separator when parse from
-a answers file, the colon here makes it never
-get the right answer.
-
-Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
----
- wscript_configure_system_mitkrb5 | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/wscript_configure_system_mitkrb5 b/wscript_configure_system_mitkrb5
-index a62d00b..a2d89f0 100644
---- a/wscript_configure_system_mitkrb5
-+++ b/wscript_configure_system_mitkrb5
-@@ -240,7 +240,7 @@ conf.CHECK_CODE('''
-        ''',
-     'HAVE_WRFILE_KEYTAB',
-     headers='krb5.h', lib='krb5', execute=True,
--    msg="Checking whether the WRFILE:-keytab is supported");
-+    msg="Checking whether the WRFILE -keytab is supported");
- # Check for KRB5_DEPRECATED handling
- conf.CHECK_CODE('''#define KRB5_DEPRECATED 1
-        #include <krb5.h>''',
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/samba-4.3.9-remove-getpwent_r.patch b/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/samba-4.3.9-remove-getpwent_r.patch
index 71db99c..a75ac2b 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/samba-4.3.9-remove-getpwent_r.patch
+++ b/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/samba-4.3.9-remove-getpwent_r.patch
@@ -1,15 +1,23 @@
-Musl does not have _r versions of getent() and getpwent() APIs
+From 02e0b14d8fa025a5db410d60a7c0dfebd536aaeb Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 6 Nov 2016 23:40:54 -0800
+Subject: [PATCH] Musl does not have _r versions of getent() and getpwent()
+ APIs
 
 Taken from gentoo
 http://data.gpo.zugaina.org/musl/net-fs/samba/files/samba-4.3.9-remove-getpwent_r.patch
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
-Index: samba-4.4.5/source4/torture/local/nss_tests.c
-===================================================================
---- samba-4.4.5.orig/source4/torture/local/nss_tests.c
-+++ samba-4.4.5/source4/torture/local/nss_tests.c
-@@ -247,7 +247,6 @@ static bool test_getgrnam_r(struct tortu
+---
+ source4/torture/local/nss_tests.c | 13 ++++++++-----
+ 1 file changed, 8 insertions(+), 5 deletions(-)
+
+diff --git a/source4/torture/local/nss_tests.c b/source4/torture/local/nss_tests.c
+index 2cd6122..04f13c6 100644
+--- a/source4/torture/local/nss_tests.c
++++ b/source4/torture/local/nss_tests.c
+@@ -247,7 +247,6 @@ static bool test_getgrnam_r(struct torture_context *tctx,
  	return true;
  }
  
@@ -17,7 +25,7 @@
  static bool test_getgrgid(struct torture_context *tctx,
  			  gid_t gid,
  			  struct group *grp_p)
-@@ -333,6 +332,7 @@ static bool test_enum_passwd(struct tort
+@@ -333,6 +332,7 @@ static bool test_enum_passwd(struct torture_context *tctx,
  	return true;
  }
  
@@ -25,7 +33,7 @@
  static bool test_enum_r_passwd(struct torture_context *tctx,
  			       struct passwd **pwd_array_p,
  			       size_t *num_pwd_p)
-@@ -381,6 +381,7 @@ static bool test_enum_r_passwd(struct to
+@@ -381,6 +381,7 @@ static bool test_enum_r_passwd(struct torture_context *tctx,
  
  	return true;
  }
@@ -33,7 +41,7 @@
  
  static bool torture_assert_passwd_equal(struct torture_context *tctx,
  					const struct passwd *p1,
-@@ -432,7 +433,7 @@ static bool test_passwd_r(struct torture
+@@ -432,7 +433,7 @@ static bool test_passwd_r(struct torture_context *tctx)
  	struct passwd *pwd, pwd1, pwd2;
  	size_t num_pwd;
  
@@ -42,7 +50,7 @@
  						"failed to enumerate passwd");
  
  	for (i=0; i < num_pwd; i++) {
-@@ -460,7 +461,7 @@ static bool test_passwd_r_cross(struct t
+@@ -460,7 +461,7 @@ static bool test_passwd_r_cross(struct torture_context *tctx)
  	struct passwd *pwd, pwd1, pwd2, pwd3, pwd4;
  	size_t num_pwd;
  
@@ -51,7 +59,7 @@
  						"failed to enumerate passwd");
  
  	for (i=0; i < num_pwd; i++) {
-@@ -531,6 +532,7 @@ static bool test_enum_group(struct tortu
+@@ -531,6 +532,7 @@ static bool test_enum_group(struct torture_context *tctx,
  	return true;
  }
  
@@ -59,7 +67,7 @@
  static bool test_enum_r_group(struct torture_context *tctx,
  			      struct group **grp_array_p,
  			      size_t *num_grp_p)
-@@ -579,6 +581,7 @@ static bool test_enum_r_group(struct tor
+@@ -579,6 +581,7 @@ static bool test_enum_r_group(struct torture_context *tctx,
  
  	return true;
  }
@@ -67,7 +75,7 @@
  
  static bool torture_assert_group_equal(struct torture_context *tctx,
  				       const struct group *g1,
-@@ -635,7 +638,7 @@ static bool test_group_r(struct torture_
+@@ -635,7 +638,7 @@ static bool test_group_r(struct torture_context *tctx)
  	struct group *grp, grp1, grp2;
  	size_t num_grp;
  
@@ -76,7 +84,7 @@
  					       "failed to enumerate group");
  
  	for (i=0; i < num_grp; i++) {
-@@ -663,7 +666,7 @@ static bool test_group_r_cross(struct to
+@@ -663,7 +666,7 @@ static bool test_group_r_cross(struct torture_context *tctx)
  	struct group *grp, grp1, grp2, grp3, grp4;
  	size_t num_grp;
  
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/samba-pam.patch b/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/samba-pam.patch
index 0cbacb6..27b40f2 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/samba-pam.patch
+++ b/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/samba-pam.patch
@@ -1,14 +1,21 @@
-Lifted from gentoo and ported to 4.4.5
+From 54a5279cb33abd23ef7c094d51f16078ece2da0c Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 6 Nov 2016 23:40:54 -0800
+Subject: [PATCH] Lifted from gentoo and ported to 4.4.5
 
 http://data.gpo.zugaina.org/musl/net-fs/samba/files/samba-4.2.7-pam.patch
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
-Index: samba-4.7.0/source3/wscript
-===================================================================
---- samba-4.7.0.orig/source3/wscript
-+++ samba-4.7.0/source3/wscript
-@@ -875,7 +875,7 @@ msg.msg_accrightslen = sizeof(fd);
+---
+ source3/wscript | 13 ++++++++++++-
+ 1 file changed, 12 insertions(+), 1 deletion(-)
+
+diff --git a/source3/wscript b/source3/wscript
+index 5436db2..864f614 100644
+--- a/source3/wscript
++++ b/source3/wscript
+@@ -879,7 +879,7 @@ msg.msg_accrightslen = sizeof(fd);
          if conf.env.with_iconv:
              conf.DEFINE('HAVE_ICONV', 1)
  
@@ -17,7 +24,7 @@
          use_pam=True
          conf.CHECK_HEADERS('security/pam_appl.h pam/pam_appl.h')
          if not conf.CONFIG_SET('HAVE_SECURITY_PAM_APPL_H') and not conf.CONFIG_SET('HAVE_PAM_PAM_APPL_H'):
-@@ -952,6 +952,17 @@ int i; i = PAM_RADIO_TYPE;
+@@ -956,6 +956,17 @@ int i; i = PAM_RADIO_TYPE;
                         "or headers not found. Use --without-pam to disable "
                         "PAM support.");
  
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/smb.conf b/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/smb.conf
new file mode 100644
index 0000000..a0b87c3
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/smb.conf
@@ -0,0 +1,254 @@
+#
+# Sample configuration file for the Samba suite for Debian GNU/Linux.
+#
+#
+# This is the main Samba configuration file. You should read the
+# smb.conf(5) manual page in order to understand the options listed
+# here. Samba has a huge number of configurable options most of which 
+# are not shown in this example
+#
+# Some options that are often worth tuning have been included as
+# commented-out examples in this file.
+#  - When such options are commented with ";", the proposed setting
+#    differs from the default Samba behaviour
+#  - When commented with "#", the proposed setting is the default
+#    behaviour of Samba but the option is considered important
+#    enough to be mentioned here
+#
+# NOTE: Whenever you modify this file you should run the command
+# "testparm" to check that you have not made any basic syntactic 
+# errors. 
+
+#======================= Global Settings =======================
+
+[global]
+
+## Browsing/Identification ###
+
+# Change this to the workgroup/NT-domain name your Samba server will part of
+   workgroup = WORKGROUP
+
+# Windows Internet Name Serving Support Section:
+# WINS Support - Tells the NMBD component of Samba to enable its WINS Server
+#   wins support = no
+
+# WINS Server - Tells the NMBD components of Samba to be a WINS Client
+# Note: Samba can be either a WINS Server, or a WINS Client, but NOT both
+;   wins server = w.x.y.z
+
+# This will prevent nmbd to search for NetBIOS names through DNS.
+   dns proxy = no
+
+#### Networking ####
+
+# The specific set of interfaces / networks to bind to
+# This can be either the interface name or an IP address/netmask;
+# interface names are normally preferred
+;   interfaces = 127.0.0.0/8 eth0
+
+# Only bind to the named interfaces and/or networks; you must use the
+# 'interfaces' option above to use this.
+# It is recommended that you enable this feature if your Samba machine is
+# not protected by a firewall or is a firewall itself.  However, this
+# option cannot handle dynamic or non-broadcast interfaces correctly.
+;   bind interfaces only = yes
+
+
+
+#### Debugging/Accounting ####
+
+# This tells Samba to use a separate log file for each machine
+# that connects
+   log file = /var/log/samba/log.%m
+
+# Cap the size of the individual log files (in KiB).
+   max log size = 1000
+
+# If you want Samba to only log through syslog then set the following
+# parameter to 'yes'.
+#   syslog only = no
+
+# We want Samba to log a minimum amount of information to syslog. Everything
+# should go to /var/log/samba/log.{smbd,nmbd} instead. If you want to log
+# through syslog you should set the following parameter to something higher.
+   syslog = 0
+
+# Do something sensible when Samba crashes: mail the admin a backtrace
+   panic action = /usr/share/samba/panic-action %d
+
+
+####### Authentication #######
+
+# Server role. Defines in which mode Samba will operate. Possible
+# values are "standalone server", "member server", "classic primary
+# domain controller", "classic backup domain controller", "active
+# directory domain controller". 
+#
+# Most people will want "standalone server" or "member server".
+# Running as "active directory domain controller" will require first
+# running "samba-tool domain provision" to wipe databases and create a
+# new domain.
+   server role = standalone server
+
+# If you are using encrypted passwords, Samba will need to know what
+# password database type you are using.  
+   passdb backend = tdbsam
+
+   obey pam restrictions = yes
+
+# This boolean parameter controls whether Samba attempts to sync the Unix
+# password with the SMB password when the encrypted SMB password in the
+# passdb is changed.
+   unix password sync = yes
+
+# For Unix password sync to work on a Debian GNU/Linux system, the following
+# parameters must be set (thanks to Ian Kahan <<kahan@informatik.tu-muenchen.de> for
+# sending the correct chat script for the passwd program in Debian Sarge).
+   passwd program = /usr/bin/passwd %u
+   passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .
+
+# This boolean controls whether PAM will be used for password changes
+# when requested by an SMB client instead of the program listed in
+# 'passwd program'. The default is 'no'.
+   pam password change = yes
+
+# This option controls how unsuccessful authentication attempts are mapped
+# to anonymous connections
+   map to guest = bad user
+
+########## Domains ###########
+
+#
+# The following settings only takes effect if 'server role = primary
+# classic domain controller', 'server role = backup domain controller'
+# or 'domain logons' is set 
+#
+
+# It specifies the location of the user's
+# profile directory from the client point of view) The following
+# required a [profiles] share to be setup on the samba server (see
+# below)
+;   logon path = \\%N\profiles\%U
+# Another common choice is storing the profile in the user's home directory
+# (this is Samba's default)
+#   logon path = \\%N\%U\profile
+
+# The following setting only takes effect if 'domain logons' is set
+# It specifies the location of a user's home directory (from the client
+# point of view)
+;   logon drive = H:
+#   logon home = \\%N\%U
+
+# The following setting only takes effect if 'domain logons' is set
+# It specifies the script to run during logon. The script must be stored
+# in the [netlogon] share
+# NOTE: Must be store in 'DOS' file format convention
+;   logon script = logon.cmd
+
+# This allows Unix users to be created on the domain controller via the SAMR
+# RPC pipe.  The example command creates a user account with a disabled Unix
+# password; please adapt to your needs
+; add user script = /usr/sbin/adduser --quiet --disabled-password --gecos "" %u
+
+# This allows machine accounts to be created on the domain controller via the 
+# SAMR RPC pipe.  
+# The following assumes a "machines" group exists on the system
+; add machine script  = /usr/sbin/useradd -g machines -c "%u machine account" -d /var/lib/samba -s /bin/false %u
+
+# This allows Unix groups to be created on the domain controller via the SAMR
+# RPC pipe.  
+; add group script = /usr/sbin/addgroup --force-badname %g
+
+############ Misc ############
+
+# Using the following line enables you to customise your configuration
+# on a per machine basis. The %m gets replaced with the netbios name
+# of the machine that is connecting
+;   include = /home/samba/etc/smb.conf.%m
+
+# Some defaults for winbind (make sure you're not using the ranges
+# for something else.)
+;   idmap uid = 10000-20000
+;   idmap gid = 10000-20000
+;   template shell = /bin/bash
+
+# Setup usershare options to enable non-root users to share folders
+# with the net usershare command.
+
+# Maximum number of usershare. 0 (default) means that usershare is disabled.
+;   usershare max shares = 100
+
+# Allow users who've been granted usershare privileges to create
+# public shares, not just authenticated ones
+   usershare allow guests = yes
+
+#======================= Share Definitions =======================
+
+[homes]
+   comment = Home Directories
+   browseable = no
+
+# By default, the home directories are exported read-only. Change the
+# next parameter to 'no' if you want to be able to write to them.
+   read only = yes
+
+# File creation mask is set to 0700 for security reasons. If you want to
+# create files with group=rw permissions, set next parameter to 0775.
+   create mask = 0700
+
+# Directory creation mask is set to 0700 for security reasons. If you want to
+# create dirs. with group=rw permissions, set next parameter to 0775.
+   directory mask = 0700
+
+# By default, \\server\username shares can be connected to by anyone
+# with access to the samba server.
+# The following parameter makes sure that only "username" can connect
+# to \\server\username
+# This might need tweaking when using external authentication schemes
+   valid users = %S
+
+# Un-comment the following and create the netlogon directory for Domain Logons
+# (you need to configure Samba to act as a domain controller too.)
+;[netlogon]
+;   comment = Network Logon Service
+;   path = /home/samba/netlogon
+;   guest ok = yes
+;   read only = yes
+
+# Un-comment the following and create the profiles directory to store
+# users profiles (see the "logon path" option above)
+# (you need to configure Samba to act as a domain controller too.)
+# The path below should be writable by all users so that their
+# profile directory may be created the first time they log on
+;[profiles]
+;   comment = Users profiles
+;   path = /home/samba/profiles
+;   guest ok = no
+;   browseable = no
+;   create mask = 0600
+;   directory mask = 0700
+
+[printers]
+   comment = All Printers
+   browseable = no
+   path = /var/spool/samba
+   printable = yes
+   guest ok = no
+   read only = yes
+   create mask = 0700
+
+# Windows clients look for this share name as a source of downloadable
+# printer drivers
+[print$]
+   comment = Printer Drivers
+   path = /var/lib/samba/printers
+   browseable = yes
+   read only = yes
+   guest ok = no
+# Uncomment to allow remote administration of Windows print drivers.
+# You may need to replace 'lpadmin' with the name of the group your
+# admin users are members of.
+# Please note that you also need to set appropriate Unix permissions
+# to the drivers directory for these users to have write rights in it
+;   write list = root, @lpadmin
+
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/smb_conf-4.7.0.patch b/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/smb_conf-4.7.0.patch
index 77c8b36..6ae2928 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/smb_conf-4.7.0.patch
+++ b/meta-openembedded/meta-networking/recipes-connectivity/samba/samba/smb_conf-4.7.0.patch
@@ -1,4 +1,7 @@
-samba: correct log files location
+From f99b6a8617df6a46f41fb68ffafb2608dbb6681e Mon Sep 17 00:00:00 2001
+From: Joe Slater <joe.slater@windriver.com>
+Date: Wed, 8 Nov 2017 11:58:05 -0800
+Subject: [PATCH] samba: correct log files location
 
 We use /var/log/samba.
 
@@ -6,9 +9,15 @@
 
 Signed-off-by: Joe Slater <joe.slater@windriver.com>
 
---- a/packaging/RHEL/setup/smb.conf
-+++ b/packaging/RHEL/setup/smb.conf
-@@ -63,7 +63,7 @@
+---
+ examples/smb.conf.default | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/examples/smb.conf.default b/examples/smb.conf.default
+index 2f20720..44c1aa8 100644
+--- a/examples/smb.conf.default
++++ b/examples/smb.conf.default
+@@ -52,7 +52,7 @@
  
  # this tells Samba to use a separate log file for each machine
  # that connects
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/samba/samba_4.7.6.bb b/meta-openembedded/meta-networking/recipes-connectivity/samba/samba_4.7.6.bb
deleted file mode 100644
index a8517c5..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/samba/samba_4.7.6.bb
+++ /dev/null
@@ -1,318 +0,0 @@
-HOMEPAGE = "https://www.samba.org/"
-SECTION = "console/network"
-
-LICENSE = "GPL-3.0+ & LGPL-3.0+ & GPL-2.0+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
-                    file://${COREBASE}/meta/files/common-licenses/LGPL-3.0;md5=bfccfe952269fff2b407dd11f2f3083b \
-                    file://${COREBASE}/meta/files/common-licenses/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6 "
-
-SAMBA_MIRROR = "http://samba.org/samba/ftp"
-MIRRORS += "\
-${SAMBA_MIRROR}    http://mirror.internode.on.net/pub/samba \n \
-${SAMBA_MIRROR}    http://www.mirrorservice.org/sites/ftp.samba.org \n \
-"
-
-SRC_URI = "${SAMBA_MIRROR}/stable/samba-${PV}.tar.gz \
-           file://16-do-not-check-xsltproc-manpages.patch \
-           file://20-do-not-import-target-module-while-cross-compile.patch \
-           file://21-add-config-option-without-valgrind.patch \
-           file://0001-packaging-Avoid-timeout-for-nmbd-if-started-offline-.patch \
-           file://0006-avoid-using-colon-in-the-checking-msg.patch \
-           file://netdb_defines.patch \
-           file://glibc_only.patch \
-           file://iconv-4.7.0.patch \
-           file://dnsserver-4.7.0.patch \
-           file://smb_conf-4.7.0.patch \
-           file://volatiles.03_samba \
-          "
-SRC_URI_append_libc-musl = " \
-           file://samba-pam.patch \
-           file://samba-4.3.9-remove-getpwent_r.patch \
-          "
-
-SRC_URI[md5sum] = "0253021a45c479cec1e135b004a0177a"
-SRC_URI[sha256sum] = "1eede30fc8ef6504e24602fb72b00baa0a7b73b59f16d25cb0771dc8c7c57d6e"
-
-inherit systemd waf-samba cpan-base perlnative update-rc.d
-# remove default added RDEPENDS on perl
-RDEPENDS_${PN}_remove = "perl"
-
-DEPENDS += "readline virtual/libiconv zlib popt libtalloc libtdb libtevent libldb libbsd libaio libpam"
-
-inherit distro_features_check
-REQUIRED_DISTRO_FEATURES = "pam"
-
-DEPENDS_append_libc-musl = " libtirpc"
-CFLAGS_append_libc-musl = " -I${STAGING_INCDIR}/tirpc"
-LDFLAGS_append_libc-musl = " -ltirpc"
-
-LSB = ""
-LSB_linuxstdbase = "lsb"
-
-INITSCRIPT_NAME = "samba"
-INITSCRIPT_PARAMS = "start 20 3 5 . stop 20 0 1 6 ."
-
-SYSTEMD_PACKAGES = "${PN}-base ${PN}-ad-dc winbind"
-SYSTEMD_SERVICE_${PN}-base = "nmb.service smb.service"
-SYSTEMD_SERVICE_${PN}-ad-dc = "${@bb.utils.contains('PACKAGECONFIG', 'ad-dc', 'samba.service', '', d)}"
-SYSTEMD_SERVICE_winbind = "winbind.service"
-
-# There are prerequisite settings to enable ad-dc, so disable the service by default.
-# Reference:
-# https://wiki.samba.org/index.php/Setting_up_Samba_as_an_Active_Directory_Domain_Controller
-SYSTEMD_AUTO_ENABLE_${PN}-ad-dc = "disable"
-
-# Use krb5.  Build active domain controller.
-#
-PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd zeroconf', d)} \
-                   acl ad-dc cups gnutls ldap mitkrb5 \
-"
-
-RDEPENDS_${PN}-base += "${LSB}"
-RDEPENDS_${PN}-ctdb-tests += "bash util-linux-getopt"
-
-PACKAGECONFIG[acl] = "--with-acl-support,--without-acl-support,acl"
-PACKAGECONFIG[fam] = "--with-fam,--without-fam,gamin"
-PACKAGECONFIG[cups] = "--enable-cups,--disable-cups,cups"
-PACKAGECONFIG[ldap] = "--with-ldap,--without-ldap,openldap"
-PACKAGECONFIG[sasl] = ",,cyrus-sasl"
-PACKAGECONFIG[systemd] = "--with-systemd,--without-systemd,systemd"
-PACKAGECONFIG[dmapi] = "--with-dmapi,--without-dmapi,dmapi"
-PACKAGECONFIG[zeroconf] = "--enable-avahi,--disable-avahi,avahi"
-PACKAGECONFIG[valgrind] = ",--without-valgrind,valgrind,"
-PACKAGECONFIG[lttng] = "--with-lttng, --without-lttng,lttng-ust"
-PACKAGECONFIG[archive] = "--with-libarchive, --without-libarchive, libarchive"
-
-# Building the AD (Active Directory) DC (Domain Controller) requires GnuTLS,
-# And ad-dc doesn't work with mitkrb5 for versions prior to 4.7.0 according to:
-# http://samba.2283325.n4.nabble.com/samba-4-6-6-Unknown-dependency-kdc-in-service-kdc-objlist-td4722096.html
-# So the working combination is:
-# 1) ad-dc: enable, gnutls: enable, mitkrb5: disable
-# 2) ad-dc: disable, gnutls: enable/disable, mitkrb5: enable
-#
-# We are now at 4.7.0, so take the above with a grain of salt. We do not need to know where
-# krb5kdc is unless ad-dc is enabled, but we tell configure anyhow.
-#
-PACKAGECONFIG[ad-dc] = ",--without-ad-dc,,"
-PACKAGECONFIG[gnutls] = "--enable-gnutls,--disable-gnutls,gnutls,"
-PACKAGECONFIG[mitkrb5] = "--with-system-mitkrb5 --with-system-mitkdc=/usr/sbin/krb5kdc,,krb5,"
-
-SAMBA4_IDMAP_MODULES="idmap_ad,idmap_rid,idmap_adex,idmap_hash,idmap_tdb2"
-SAMBA4_PDB_MODULES="pdb_tdbsam,${@bb.utils.contains('PACKAGECONFIG', 'ldap', 'pdb_ldap,', '', d)}pdb_ads,pdb_smbpasswd,pdb_wbc_sam,pdb_samba4"
-SAMBA4_AUTH_MODULES="auth_unix,auth_wbc,auth_server,auth_netlogond,auth_script,auth_samba4"
-SAMBA4_MODULES="${SAMBA4_IDMAP_MODULES},${SAMBA4_PDB_MODULES},${SAMBA4_AUTH_MODULES}"
-
-# These libraries are supposed to replace others supplied by packages, but decorate the names of
-# .so files so there will not be a conflict.  This is not done consistantly, so be very careful
-# when adding to this list.
-#
-SAMBA4_LIBS="heimdal,cmocka,NONE"
-
-EXTRA_OECONF += "--enable-fhs \
-                 --with-piddir=/run \
-                 --with-sockets-dir=/run/samba \
-                 --with-modulesdir=${libdir}/samba \
-                 --with-lockdir=${localstatedir}/lib/samba \
-                 --with-cachedir=${localstatedir}/lib/samba \
-                 --disable-rpath-install \
-                 --with-shared-modules=${SAMBA4_MODULES} \
-                 --bundled-libraries=${SAMBA4_LIBS} \
-                 ${@oe.utils.conditional('TARGET_ARCH', 'x86_64', '', '--disable-glusterfs', d)} \
-                 --with-cluster-support \
-                 --with-profiling-data \
-                 --with-libiconv=${STAGING_DIR_HOST}${prefix} \
-                 --with-pam --with-pammodulesdir=${base_libdir}/security \
-                "
-
-LDFLAGS += "-Wl,-z,relro,-z,now ${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-gold', ' -fuse-ld=bfd ', '', d)}"
-
-do_install_append() {
-    for section in 1 5 7; do
-        install -d ${D}${mandir}/man$section
-        install -m 0644 ctdb/doc/*.$section ${D}${mandir}/man$section
-    done
-    for section in 1 5 7 8; do
-        install -d ${D}${mandir}/man$section
-        install -m 0644 docs/manpages/*.$section ${D}${mandir}/man$section
-    done
-
-    install -d ${D}${systemd_system_unitdir}
-    install -m 0644 packaging/systemd/*.service ${D}${systemd_system_unitdir}
-    sed -e 's,\(ExecReload=\).*\(/kill\),\1${base_bindir}\2,' \
-        -e 's,/etc/sysconfig/samba,${sysconfdir}/default/samba,' \
-        -i ${D}${systemd_system_unitdir}/*.service
-
-    if [ "${@bb.utils.contains('PACKAGECONFIG', 'ad-dc', 'yes', 'no', d)}" = "no" ]; then
-        rm -f ${D}${systemd_system_unitdir}/samba.service
-    fi
-
-    install -d ${D}${sysconfdir}/tmpfiles.d
-    install -m644 packaging/systemd/samba.conf.tmp ${D}${sysconfdir}/tmpfiles.d/samba.conf
-    echo "d ${localstatedir}/log/samba 0755 root root -" \
-        >> ${D}${sysconfdir}/tmpfiles.d/samba.conf
-    if [ "${LSB}" = "lsb" ]; then
-        install -d ${D}${sysconfdir}/init.d
-        install -m 0755 packaging/LSB/samba.sh ${D}${sysconfdir}/init.d/samba
-    else
-        install -d ${D}${sysconfdir}/init.d
-        install -m 0755 packaging/sysv/samba.init ${D}${sysconfdir}/init.d/samba
-        sed -e 's,/opt/samba/bin,${sbindir},g' \
-            -e 's,/opt/samba/smb.conf,${sysconfdir}/samba/smb.conf,g' \
-            -e 's,/opt/samba/log,${localstatedir}/log/samba,g' \
-            -e 's,/etc/init.d/samba.server,${sysconfdir}/init.d/samba,g' \
-            -e 's,/usr/bin,${base_bindir},g' \
-            -i ${D}${sysconfdir}/init.d/samba
-    fi
-
-    install -d ${D}${sysconfdir}/samba
-    echo "127.0.0.1 localhost" > ${D}${sysconfdir}/samba/lmhosts
-    install -m644 packaging/RHEL/setup/smb.conf ${D}${sysconfdir}/samba/smb.conf
-    install -D -m 644 ${WORKDIR}/volatiles.03_samba ${D}${sysconfdir}/default/volatiles/03_samba
-
-    install -d ${D}${sysconfdir}/default
-    install -m644 packaging/systemd/samba.sysconfig ${D}${sysconfdir}/default/samba
-
-    # install ctdb config file and test cases
-    install -D -m 0644 ${S}/ctdb/tests/onnode/nodes ${D}${sysconfdir}/ctdb/nodes
-    # the items are from ctdb/tests/run_tests.sh
-    for d in onnode takeover tool eventscripts cunit simple complex; do
-        testdir=${D}${datadir}/ctdb-tests/$d
-        install -d $testdir
-        cp ${S}/ctdb/tests/$d/*.sh $testdir
-        cp -r ${S}/ctdb/tests/$d/scripts ${S}/ctdb/tests/$d/stubs $testdir || true
-    done
-
-    # fix file-rdeps qa warning
-    if [ -f ${D}${bindir}/onnode ]; then
-        sed -i 's:\(#!/bin/\)bash:\1sh:' ${D}${bindir}/onnode
-    fi
-
-    chmod 0750 ${D}${sysconfdir}/sudoers.d
-    rm -rf ${D}/run ${D}${localstatedir}/run ${D}${localstatedir}/log
-}
-
-PACKAGES =+ "${PN}-python ${PN}-pidl \
-             ${PN}-dsdb-modules ${PN}-testsuite registry-tools \
-             winbind \
-             ${PN}-common ${PN}-base ${PN}-ad-dc ${PN}-ctdb-tests \
-             smbclient ${PN}-client ${PN}-server ${PN}-test"
-
-python samba_populate_packages() {
-    def module_hook(file, pkg, pattern, format, basename):
-        pn = d.getVar('PN', True)
-        d.appendVar('RRECOMMENDS_%s-base' % pn, ' %s' % pkg)
-
-    mlprefix = d.getVar('MLPREFIX', True) or ''
-    pam_libdir = d.expand('${base_libdir}/security')
-    pam_pkgname = mlprefix + 'pam-plugin%s'
-    do_split_packages(d, pam_libdir, '^pam_(.*)\.so$', pam_pkgname, 'PAM plugin for %s', extra_depends='', prepend=True)
-
-    libdir = d.getVar('libdir', True)
-    do_split_packages(d, libdir, '^lib(.*)\.so\..*$', 'lib%s', 'Samba %s library', extra_depends='${PN}-common', prepend=True, allow_links=True)
-    pkglibdir = '%s/samba' % libdir
-    do_split_packages(d, pkglibdir, '^lib(.*)\.so$', 'lib%s', 'Samba %s library', extra_depends='${PN}-common', prepend=True)
-    moduledir = '%s/samba/auth' % libdir
-    do_split_packages(d, moduledir, '^(.*)\.so$', 'samba-auth-%s', 'Samba %s authentication backend', hook=module_hook, extra_depends='', prepend=True)
-    moduledir = '%s/samba/pdb' % libdir
-    do_split_packages(d, moduledir, '^(.*)\.so$', 'samba-pdb-%s', 'Samba %s password backend', hook=module_hook, extra_depends='', prepend=True)
-}
-
-PACKAGESPLITFUNCS_prepend = "samba_populate_packages "
-
-RDEPENDS_${PN} += "${PN}-base ${PN}-python ${PN}-dsdb-modules"
-RDEPENDS_${PN}-python += "pytalloc python-tdb"
-
-FILES_${PN}-base = "${sbindir}/nmbd \
-                    ${sbindir}/smbd \
-                    ${sysconfdir}/init.d \
-                    ${localstatedir}/lib/samba \
-                    ${localstatedir}/nmbd \
-                    ${localstatedir}/spool/samba \
-                    ${systemd_system_unitdir}/nmb.service \
-                    ${systemd_system_unitdir}/smb.service"
-
-FILES_${PN}-ad-dc = "${sbindir}/samba \
-                     ${systemd_system_unitdir}/samba.service \
-                     ${libdir}/krb5/plugins/kdb/samba.so \
-                    "
-RDEPENDS_${PN}-ad-dc = "krb5-kdc"
-
-FILES_${PN}-ctdb-tests = "${bindir}/ctdb_run_tests \
-                          ${bindir}/ctdb_run_cluster_tests \
-                          ${sysconfdir}/ctdb/nodes \
-                          ${datadir}/ctdb-tests \
-                          ${datadir}/ctdb/tests \
-                         "
-
-FILES_${BPN}-common = "${sysconfdir}/default \
-                       ${sysconfdir}/samba \
-                       ${sysconfdir}/tmpfiles.d \
-"
-
-FILES_${PN} += "${libdir}/vfs/*.so \
-                ${libdir}/charset/*.so \
-                ${libdir}/*.dat \
-                ${libdir}/auth/*.so \
-"
-
-FILES_${PN}-dsdb-modules = "${libdir}/samba/ldb"
-
-FILES_${PN}-testsuite = "${bindir}/gentest \
-                         ${bindir}/locktest \
-                         ${bindir}/masktest \
-                         ${bindir}/ndrdump \
-                         ${bindir}/smbtorture"
-
-FILES_registry-tools = "${bindir}/regdiff \
-                        ${bindir}/regpatch \
-                        ${bindir}/regshell \
-                        ${bindir}/regtree"
-
-FILES_winbind = "${sbindir}/winbindd \
-                 ${bindir}/wbinfo \
-                 ${bindir}/ntlm_auth \
-                 ${libdir}/samba/idmap \
-                 ${libdir}/samba/nss_info \
-                 ${libdir}/winbind_krb5_locator.so \
-                 ${sysconfdir}/init.d/winbind \
-                 ${systemd_system_unitdir}/winbind.service"
-
-FILES_${PN}-python = "${PYTHON_SITEPACKAGES_DIR}"
-
-FILES_smbclient = "${bindir}/cifsdd \
-                   ${bindir}/rpcclient \
-                   ${bindir}/smbcacls \
-                   ${bindir}/smbclient \
-                   ${bindir}/smbcquotas \
-                   ${bindir}/smbget \
-                   ${bindir}/smbspool \
-                   ${bindir}/smbtar \
-                   ${bindir}/smbtree \
-                   ${libdir}/samba/smbspool_krb5_wrapper"
-
-RDEPENDS_${PN}-pidl_append = " perl"
-FILES_${PN}-pidl = "${bindir}/pidl ${datadir}/perl5/Parse"
-
-RDEPENDS_${PN}-client = "\
-    smbclient \
-    winbind \
-    registry-tools \
-    ${PN}-pidl \
-    " 
-
-ALLOW_EMPTY_${PN}-client = "1"
-
-RDEPENDS_${PN}-server = "\
-    ${PN} \
-    winbind \
-    registry-tools \
-    " 
-
-ALLOW_EMPTY_${PN}-server = "1"
-
-RDEPENDS_${PN}-test = "\
-    ${PN}-ctdb-tests \
-    ${PN}-testsuite \
-    "
-
-ALLOW_EMPTY_${PN}-test = "1"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/samba/samba_4.8.4.bb b/meta-openembedded/meta-networking/recipes-connectivity/samba/samba_4.8.4.bb
new file mode 100644
index 0000000..da0ac32
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/samba/samba_4.8.4.bb
@@ -0,0 +1,313 @@
+HOMEPAGE = "https://www.samba.org/"
+SECTION = "console/network"
+
+LICENSE = "GPL-3.0+ & LGPL-3.0+ & GPL-2.0+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
+                    file://${COREBASE}/meta/files/common-licenses/LGPL-3.0;md5=bfccfe952269fff2b407dd11f2f3083b \
+                    file://${COREBASE}/meta/files/common-licenses/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6 "
+
+SAMBA_MIRROR = "http://samba.org/samba/ftp"
+MIRRORS += "\
+${SAMBA_MIRROR}    http://mirror.internode.on.net/pub/samba \n \
+${SAMBA_MIRROR}    http://www.mirrorservice.org/sites/ftp.samba.org \n \
+"
+
+SRC_URI = "${SAMBA_MIRROR}/stable/samba-${PV}.tar.gz \
+           file://smb.conf \
+           file://16-do-not-check-xsltproc-manpages.patch \
+           file://20-do-not-import-target-module-while-cross-compile.patch \
+           file://21-add-config-option-without-valgrind.patch \
+           file://netdb_defines.patch \
+           file://glibc_only.patch \
+           file://iconv-4.7.0.patch \
+           file://dnsserver-4.7.0.patch \
+           file://smb_conf-4.7.0.patch \
+           file://volatiles.03_samba \
+           file://0001-ldb-Refuse-to-build-Samba-against-a-newer-minor-vers.patch \
+           "
+SRC_URI_append_libc-musl = " \
+           file://samba-pam.patch \
+           file://samba-4.3.9-remove-getpwent_r.patch \
+          "
+
+SRC_URI[md5sum] = "ca5bfbebd8d9eb95506e16594b2bbee2"
+SRC_URI[sha256sum] = "f5044d149e01894a08b1d114b8b69aed78171a7bb19608bd1fd771453b9a5406"
+
+UPSTREAM_CHECK_REGEX = "samba\-(?P<pver>4\.8(\.\d+)+).tar.gz"
+
+inherit systemd waf-samba cpan-base perlnative update-rc.d
+# remove default added RDEPENDS on perl
+RDEPENDS_${PN}_remove = "perl"
+
+DEPENDS += "readline virtual/libiconv zlib popt libtalloc libtdb libtevent libbsd libaio libpam"
+
+inherit distro_features_check
+REQUIRED_DISTRO_FEATURES = "pam"
+
+DEPENDS_append_libc-musl = " libtirpc"
+CFLAGS_append_libc-musl = " -I${STAGING_INCDIR}/tirpc"
+LDFLAGS_append_libc-musl = " -ltirpc"
+
+INITSCRIPT_NAME = "samba"
+INITSCRIPT_PARAMS = "start 20 3 5 . stop 20 0 1 6 ."
+
+SYSTEMD_PACKAGES = "${PN}-base ${PN}-ad-dc winbind"
+SYSTEMD_SERVICE_${PN}-base = "nmb.service smb.service"
+SYSTEMD_SERVICE_${PN}-ad-dc = "${@bb.utils.contains('PACKAGECONFIG', 'ad-dc', 'samba.service', '', d)}"
+SYSTEMD_SERVICE_winbind = "winbind.service"
+
+# There are prerequisite settings to enable ad-dc, so disable the service by default.
+# Reference:
+# https://wiki.samba.org/index.php/Setting_up_Samba_as_an_Active_Directory_Domain_Controller
+SYSTEMD_AUTO_ENABLE_${PN}-ad-dc = "disable"
+
+# Use krb5.  Build active domain controller.
+#
+PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd zeroconf', d)} \
+                   acl ad-dc cups gnutls ldap mitkrb5 \
+"
+
+RDEPENDS_${PN}-ctdb-tests += "bash util-linux-getopt"
+
+PACKAGECONFIG[acl] = "--with-acl-support,--without-acl-support,acl"
+PACKAGECONFIG[fam] = "--with-fam,--without-fam,gamin"
+PACKAGECONFIG[cups] = "--enable-cups,--disable-cups,cups"
+PACKAGECONFIG[ldap] = "--with-ldap,--without-ldap,openldap"
+PACKAGECONFIG[sasl] = ",,cyrus-sasl"
+PACKAGECONFIG[systemd] = "--with-systemd,--without-systemd,systemd"
+PACKAGECONFIG[dmapi] = "--with-dmapi,--without-dmapi,dmapi"
+PACKAGECONFIG[zeroconf] = "--enable-avahi,--disable-avahi,avahi"
+PACKAGECONFIG[valgrind] = ",--without-valgrind,valgrind,"
+PACKAGECONFIG[lttng] = "--with-lttng, --without-lttng,lttng-ust"
+PACKAGECONFIG[archive] = "--with-libarchive, --without-libarchive, libarchive"
+
+# Building the AD (Active Directory) DC (Domain Controller) requires GnuTLS,
+# And ad-dc doesn't work with mitkrb5 for versions prior to 4.7.0 according to:
+# http://samba.2283325.n4.nabble.com/samba-4-6-6-Unknown-dependency-kdc-in-service-kdc-objlist-td4722096.html
+# So the working combination is:
+# 1) ad-dc: enable, gnutls: enable, mitkrb5: disable
+# 2) ad-dc: disable, gnutls: enable/disable, mitkrb5: enable
+#
+# We are now at 4.7.0, so take the above with a grain of salt. We do not need to know where
+# krb5kdc is unless ad-dc is enabled, but we tell configure anyhow.
+#
+PACKAGECONFIG[ad-dc] = ",--without-ad-dc,,"
+PACKAGECONFIG[gnutls] = "--enable-gnutls,--disable-gnutls,gnutls,"
+PACKAGECONFIG[mitkrb5] = "--with-system-mitkrb5 --with-system-mitkdc=/usr/sbin/krb5kdc,,krb5,"
+
+SAMBA4_IDMAP_MODULES="idmap_ad,idmap_rid,idmap_adex,idmap_hash,idmap_tdb2"
+SAMBA4_PDB_MODULES="pdb_tdbsam,${@bb.utils.contains('PACKAGECONFIG', 'ldap', 'pdb_ldap,', '', d)}pdb_ads,pdb_smbpasswd,pdb_wbc_sam,pdb_samba4"
+SAMBA4_AUTH_MODULES="auth_unix,auth_wbc,auth_server,auth_netlogond,auth_script,auth_samba4"
+SAMBA4_MODULES="${SAMBA4_IDMAP_MODULES},${SAMBA4_PDB_MODULES},${SAMBA4_AUTH_MODULES}"
+
+# These libraries are supposed to replace others supplied by packages, but decorate the names of
+# .so files so there will not be a conflict.  This is not done consistantly, so be very careful
+# when adding to this list.
+#
+SAMBA4_LIBS="heimdal,cmocka,ldb,pyldb-util,NONE"
+
+EXTRA_OECONF += "--enable-fhs \
+                 --with-piddir=/run \
+                 --with-sockets-dir=/run/samba \
+                 --with-modulesdir=${libdir}/samba \
+                 --with-lockdir=${localstatedir}/lib/samba \
+                 --with-cachedir=${localstatedir}/lib/samba \
+                 --disable-rpath-install \
+                 --with-shared-modules=${SAMBA4_MODULES} \
+                 --bundled-libraries=${SAMBA4_LIBS} \
+                 ${@oe.utils.conditional('TARGET_ARCH', 'x86_64', '', '--disable-glusterfs', d)} \
+                 --with-cluster-support \
+                 --with-profiling-data \
+                 --with-libiconv=${STAGING_DIR_HOST}${prefix} \
+                 --with-pam --with-pammodulesdir=${base_libdir}/security \
+                "
+
+LDFLAGS += "-Wl,-z,relro,-z,now ${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-gold', ' -fuse-ld=bfd ', '', d)}"
+
+do_install_append() {
+    for section in 1 5 7; do
+        install -d ${D}${mandir}/man$section
+        install -m 0644 ctdb/doc/*.$section ${D}${mandir}/man$section
+    done
+    for section in 1 5 7 8; do
+        install -d ${D}${mandir}/man$section
+        install -m 0644 docs/manpages/*.$section ${D}${mandir}/man$section
+    done
+
+    install -d ${D}${systemd_system_unitdir}
+    install -m 0644 ${S}/bin/default/packaging/systemd/*.service ${D}${systemd_system_unitdir}/
+    sed -e 's,\(ExecReload=\).*\(/kill\),\1${base_bindir}\2,' \
+        -e 's,/etc/sysconfig/samba,${sysconfdir}/default/samba,' \
+        -i ${D}${systemd_system_unitdir}/*.service
+
+    if [ "${@bb.utils.contains('PACKAGECONFIG', 'ad-dc', 'yes', 'no', d)}" = "no" ]; then
+        rm -f ${D}${systemd_system_unitdir}/samba.service
+    fi
+
+    install -d ${D}${sysconfdir}/tmpfiles.d
+    install -m644 packaging/systemd/samba.conf.tmp ${D}${sysconfdir}/tmpfiles.d/samba.conf
+    echo "d ${localstatedir}/log/samba 0755 root root -" \
+        >> ${D}${sysconfdir}/tmpfiles.d/samba.conf
+    install -d ${D}${sysconfdir}/init.d
+    install -m 0755 packaging/sysv/samba.init ${D}${sysconfdir}/init.d/samba
+    sed -e 's,/opt/samba/bin,${sbindir},g' \
+        -e 's,/opt/samba/smb.conf,${sysconfdir}/samba/smb.conf,g' \
+        -e 's,/opt/samba/log,${localstatedir}/log/samba,g' \
+        -e 's,/etc/init.d/samba.server,${sysconfdir}/init.d/samba,g' \
+        -e 's,/usr/bin,${base_bindir},g' \
+        -i ${D}${sysconfdir}/init.d/samba
+
+    install -d ${D}${sysconfdir}/samba
+    echo "127.0.0.1 localhost" > ${D}${sysconfdir}/samba/lmhosts
+    install -m644 ${WORKDIR}/smb.conf ${D}${sysconfdir}/samba/smb.conf
+    install -D -m 644 ${WORKDIR}/volatiles.03_samba ${D}${sysconfdir}/default/volatiles/03_samba
+
+    install -d ${D}${sysconfdir}/default
+    install -m644 packaging/systemd/samba.sysconfig ${D}${sysconfdir}/default/samba
+
+    # install ctdb config file and test cases
+    install -D -m 0644 ${S}/ctdb/tests/onnode/nodes ${D}${sysconfdir}/ctdb/nodes
+    # the items are from ctdb/tests/run_tests.sh
+    for d in onnode takeover tool eventscripts cunit simple complex; do
+        testdir=${D}${datadir}/ctdb-tests/$d
+        install -d $testdir
+        cp ${S}/ctdb/tests/$d/*.sh $testdir
+        cp -r ${S}/ctdb/tests/$d/scripts ${S}/ctdb/tests/$d/stubs $testdir || true
+    done
+
+    # fix file-rdeps qa warning
+    if [ -f ${D}${bindir}/onnode ]; then
+        sed -i 's:\(#!/bin/\)bash:\1sh:' ${D}${bindir}/onnode
+    fi
+
+    chmod 0750 ${D}${sysconfdir}/sudoers.d
+    rm -rf ${D}/run ${D}${localstatedir}/run ${D}${localstatedir}/log
+}
+
+PACKAGES =+ "${PN}-python ${PN}-pidl \
+             ${PN}-dsdb-modules ${PN}-testsuite registry-tools \
+             winbind \
+             ${PN}-common ${PN}-base ${PN}-ad-dc ${PN}-ctdb-tests \
+             smbclient ${PN}-client ${PN}-server ${PN}-test"
+
+python samba_populate_packages() {
+    def module_hook(file, pkg, pattern, format, basename):
+        pn = d.getVar('PN', True)
+        d.appendVar('RRECOMMENDS_%s-base' % pn, ' %s' % pkg)
+
+    mlprefix = d.getVar('MLPREFIX', True) or ''
+    pam_libdir = d.expand('${base_libdir}/security')
+    pam_pkgname = mlprefix + 'pam-plugin%s'
+    do_split_packages(d, pam_libdir, '^pam_(.*)\.so$', pam_pkgname, 'PAM plugin for %s', extra_depends='', prepend=True)
+
+    libdir = d.getVar('libdir', True)
+    do_split_packages(d, libdir, '^lib(.*)\.so\..*$', 'lib%s', 'Samba %s library', extra_depends='${PN}-common', prepend=True, allow_links=True)
+    pkglibdir = '%s/samba' % libdir
+    do_split_packages(d, pkglibdir, '^lib(.*)\.so$', 'lib%s', 'Samba %s library', extra_depends='${PN}-common', prepend=True)
+    moduledir = '%s/samba/auth' % libdir
+    do_split_packages(d, moduledir, '^(.*)\.so$', 'samba-auth-%s', 'Samba %s authentication backend', hook=module_hook, extra_depends='', prepend=True)
+    moduledir = '%s/samba/pdb' % libdir
+    do_split_packages(d, moduledir, '^(.*)\.so$', 'samba-pdb-%s', 'Samba %s password backend', hook=module_hook, extra_depends='', prepend=True)
+}
+
+PACKAGESPLITFUNCS_prepend = "samba_populate_packages "
+PACKAGES_DYNAMIC = "samba-auth-.* samba-pdb-.*"
+
+RDEPENDS_${PN} += "${PN}-base ${PN}-python ${PN}-dsdb-modules"
+RDEPENDS_${PN}-python += "pytalloc python-tdb"
+
+FILES_${PN}-base = "${sbindir}/nmbd \
+                    ${sbindir}/smbd \
+                    ${sysconfdir}/init.d \
+                    ${localstatedir}/lib/samba \
+                    ${localstatedir}/nmbd \
+                    ${localstatedir}/spool/samba \
+                    ${systemd_system_unitdir}/nmb.service \
+                    ${systemd_system_unitdir}/smb.service"
+
+FILES_${PN}-ad-dc = "${sbindir}/samba \
+                     ${systemd_system_unitdir}/samba.service \
+                     ${libdir}/krb5/plugins/kdb/samba.so \
+                    "
+RDEPENDS_${PN}-ad-dc = "krb5-kdc"
+
+FILES_${PN}-ctdb-tests = "${bindir}/ctdb_run_tests \
+                          ${bindir}/ctdb_run_cluster_tests \
+                          ${sysconfdir}/ctdb/nodes \
+                          ${datadir}/ctdb-tests \
+                          ${datadir}/ctdb/tests \
+                         "
+
+FILES_${BPN}-common = "${sysconfdir}/default \
+                       ${sysconfdir}/samba \
+                       ${sysconfdir}/tmpfiles.d \
+"
+
+FILES_${PN} += "${libdir}/vfs/*.so \
+                ${libdir}/charset/*.so \
+                ${libdir}/*.dat \
+                ${libdir}/auth/*.so \
+"
+
+FILES_${PN}-dsdb-modules = "${libdir}/samba/ldb"
+
+FILES_${PN}-testsuite = "${bindir}/gentest \
+                         ${bindir}/locktest \
+                         ${bindir}/masktest \
+                         ${bindir}/ndrdump \
+                         ${bindir}/smbtorture"
+
+FILES_registry-tools = "${bindir}/regdiff \
+                        ${bindir}/regpatch \
+                        ${bindir}/regshell \
+                        ${bindir}/regtree"
+
+FILES_winbind = "${sbindir}/winbindd \
+                 ${bindir}/wbinfo \
+                 ${bindir}/ntlm_auth \
+                 ${libdir}/samba/idmap \
+                 ${libdir}/samba/nss_info \
+                 ${libdir}/winbind_krb5_locator.so \
+                 ${libdir}/winbind-krb5-localauth.so \
+                 ${sysconfdir}/init.d/winbind \
+                 ${systemd_system_unitdir}/winbind.service"
+
+FILES_${PN}-python = "${PYTHON_SITEPACKAGES_DIR}"
+
+FILES_smbclient = "${bindir}/cifsdd \
+                   ${bindir}/rpcclient \
+                   ${bindir}/smbcacls \
+                   ${bindir}/smbclient \
+                   ${bindir}/smbcquotas \
+                   ${bindir}/smbget \
+                   ${bindir}/smbspool \
+                   ${bindir}/smbtar \
+                   ${bindir}/smbtree \
+                   ${libdir}/samba/smbspool_krb5_wrapper"
+
+RDEPENDS_${PN}-pidl_append = " perl"
+FILES_${PN}-pidl = "${bindir}/pidl ${datadir}/perl5/Parse"
+
+RDEPENDS_${PN}-client = "\
+    smbclient \
+    winbind \
+    registry-tools \
+    ${PN}-pidl \
+    " 
+
+ALLOW_EMPTY_${PN}-client = "1"
+
+RDEPENDS_${PN}-server = "\
+    ${PN} \
+    winbind \
+    registry-tools \
+    " 
+
+ALLOW_EMPTY_${PN}-server = "1"
+
+RDEPENDS_${PN}-test = "\
+    ${PN}-ctdb-tests \
+    ${PN}-testsuite \
+    "
+
+ALLOW_EMPTY_${PN}-test = "1"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/0001-fix-do_package-failed-since-snort-2.9.7.0.patch b/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/0001-fix-do_package-failed-since-snort-2.9.7.0.patch
deleted file mode 100644
index 047caec..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/0001-fix-do_package-failed-since-snort-2.9.7.0.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 4335c4c61877c0b65ff4ec767e8ad3ad8c73c32d Mon Sep 17 00:00:00 2001
-From: Zhiquan Li <zhiquan.li@windriver.com>
-Date: Fri, 13 Nov 2015 17:40:24 +0800
-Subject: [PATCH] fix do_package failed since snort 2.9.7.0
-
-Remove redundant '/' as a workround for below error:
-/lib/rpm/bin/debugedit: canonicalization unexpectedly shrank by one character
-
-It's a rpm debugedit bug:
-* http://sourceforge.net/p/snort/mailman/message/34130268/
-* https://bugzilla.redhat.com/show_bug.cgi?id=304121
-
-Upstream-Status:Inappropriate [embedded specific]
-
-Signed-off-by: Zhiquan Li <zhiquan.li@windriver.com>
-
----
- src/snort.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/snort.h b/src/snort.h
-index 8308e57..499d157 100644
---- a/src/snort.h
-+++ b/src/snort.h
-@@ -39,7 +39,7 @@
- #include "sfdaq.h"
- #include "sf_types.h"
- #include "sfutil/sflsq.h"
--#include "sfutil//sfActionQueue.h"
-+#include "sfutil/sfActionQueue.h"
- #include "profiler.h"
- #include "rules.h"
- #include "treenodes.h"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/disable-dap-address-space-id.patch b/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/disable-dap-address-space-id.patch
deleted file mode 100644
index 6aa0b73..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/disable-dap-address-space-id.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-From 5a53260a819e2873f58165e96852529719101c53 Mon Sep 17 00:00:00 2001
-From: Chunrong Guo <B40290@freescale.com>
-Date: Mon, 4 Nov 2013 10:39:56 +0800
-Subject: [PATCH] snort: add recipe
-
-Upstream-Status:Inappropriate [embedded specific]
-
-fix the below error:
-checking for dap address space id... configure:
-configure: error: cannot run test program while cross compiling
-
-Signed-off-by: Chunrong Guo <B40290@freescale.com>
-
----
- configure.in | 34 +++++++++++++++++-----------------
- 1 file changed, 17 insertions(+), 17 deletions(-)
-
-diff --git a/configure.in b/configure.in
-index 6fe5d68..e7636ce 100644
---- a/configure.in
-+++ b/configure.in
-@@ -698,23 +698,23 @@ if test "x$ac_cv_func_daq_dp_add_dc" = "xyes"; then
- 
- fi
- 
--AC_MSG_CHECKING([for daq address space ID])
--AC_RUN_IFELSE(
--[AC_LANG_PROGRAM(
--[[
--#include <daq.h>
--]],
--[[
--   DAQ_PktHdr_t hdr;
--   hdr.address_space_id = 0;
--]])],
--[have_daq_address_space_id="yes"],
--[have_daq_address_space_id="no"])
--AC_MSG_RESULT($have_daq_address_space_id)
--if test "x$have_daq_address_space_id" = "xyes"; then
--    AC_DEFINE([HAVE_DAQ_ADDRESS_SPACE_ID],[1],
--        [DAQ version supports address space ID in header.])
--fi
-+#AC_MSG_CHECKING([for daq address space ID])
-+#AC_RUN_IFELSE(
-+#[AC_LANG_PROGRAM(
-+#[[
-+##include <daq.h>
-+#]],
-+#[[
-+#   DAQ_PktHdr_t hdr;
-+#   hdr.address_space_id = 0;
-+#]])],
-+have_daq_address_space_id="yes"
-+#[have_daq_address_space_id="no"])
-+#AC_MSG_RESULT($have_daq_address_space_id)
-+#if test "x$have_daq_address_space_id" = "xyes"; then
-+#    AC_DEFINE([HAVE_DAQ_ADDRESS_SPACE_ID],[1],
-+#        [DAQ version supports address space ID in header.])
-+#fi
- 
- AC_MSG_CHECKING([for daq flow ID])
- AC_RUN_IFELSE(
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/disable-daq-flow-id.patch b/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/disable-daq-flow-id.patch
deleted file mode 100644
index 04df37c..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/disable-daq-flow-id.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-From 5aa42a3137c657b5eddd4608343aa1854bd7cd27 Mon Sep 17 00:00:00 2001
-From: Zhiquan Li <zhiquan.li@windriver.com>
-Date: Mon, 16 Nov 2015 10:23:00 +0800
-Subject: [PATCH] snort: 2.9.6.0 -> 2.9.7.5
-
-Upstream-Status:Inappropriate [embedded specific]
-
-fix the below error:
-checking for daq flow ID... configure:
-configure: error: cannot run test program while cross compiling
-
----
- configure.in | 34 +++++++++++++++++-----------------
- 1 file changed, 17 insertions(+), 17 deletions(-)
-
-diff --git a/configure.in b/configure.in
-index e7636ce..2fbd298 100644
---- a/configure.in
-+++ b/configure.in
-@@ -716,23 +716,23 @@ have_daq_address_space_id="yes"
- #        [DAQ version supports address space ID in header.])
- #fi
- 
--AC_MSG_CHECKING([for daq flow ID])
--AC_RUN_IFELSE(
--[AC_LANG_PROGRAM(
--[[
--#include <daq.h>
--]],
--[[
--   DAQ_PktHdr_t hdr;
--   hdr.flow_id = 0;
--]])],
--[have_daq_flow_id="yes"],
--[have_daq_flow_id="no"])
--AC_MSG_RESULT($have_daq_flow_id)
--if test "x$have_daq_flow_id" = "xyes"; then
--    AC_DEFINE([HAVE_DAQ_FLOW_ID],[1],
--        [DAQ version supports flow ID in header.])
--fi
-+#AC_MSG_CHECKING([for daq flow ID])
-+#AC_RUN_IFELSE(
-+#[AC_LANG_PROGRAM(
-+#[[
-+##include <daq.h>
-+#]],
-+#[[
-+#   DAQ_PktHdr_t hdr;
-+#   hdr.flow_id = 0;
-+#]])],
-+have_daq_flow_id="yes"
-+#[have_daq_flow_id="no"])
-+#AC_MSG_RESULT($have_daq_flow_id)
-+#if test "x$have_daq_flow_id" = "xyes"; then
-+#    AC_DEFINE([HAVE_DAQ_FLOW_ID],[1],
-+#        [DAQ version supports flow ID in header.])
-+#fi
- 
- AC_MSG_CHECKING([for DAQ_VERDICT_RETRY])
- AC_RUN_IFELSE(
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/disable-daq-verdict-retry.patch b/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/disable-daq-verdict-retry.patch
deleted file mode 100644
index 15958a7..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/disable-daq-verdict-retry.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-From b916443d43f2e1eeacfbed0033274a0270ef634d Mon Sep 17 00:00:00 2001
-From: Zhiquan Li <zhiquan.li@windriver.com>
-Date: Mon, 16 Nov 2015 10:23:00 +0800
-Subject: [PATCH] snort: 2.9.6.0 -> 2.9.7.5
-
-Upstream-Status:Inappropriate [embedded specific]
-
-fix the below error:
-checking for DAQ_VERDICT_RETRY... configure:
-configure: error: cannot run test program while cross compiling
-
----
- configure.in | 34 +++++++++++++++++-----------------
- 1 file changed, 17 insertions(+), 17 deletions(-)
-
-diff --git a/configure.in b/configure.in
-index 2fbd298..62573a8 100644
---- a/configure.in
-+++ b/configure.in
-@@ -734,23 +734,23 @@ have_daq_flow_id="yes"
- #        [DAQ version supports flow ID in header.])
- #fi
- 
--AC_MSG_CHECKING([for DAQ_VERDICT_RETRY])
--AC_RUN_IFELSE(
--[AC_LANG_PROGRAM(
--[[
--#include <daq.h>
--]],
--[[
--   DAQ_Verdict verdict;
--   verdict = DAQ_VERDICT_RETRY;
--]])],
--[have_daq_verdict_retry="yes"],
--[have_daq_verdict_retry="no"])
--AC_MSG_RESULT($have_daq_verdict_retry)
--if test "x$have_daq_verdict_retry" = "xyes"; then
--    AC_DEFINE([HAVE_DAQ_VERDICT_RETRY],[1],
--        [DAQ version supports DAQ_VERDICT_RETRY in DAQ_Verdict.])
--fi
-+#AC_MSG_CHECKING([for DAQ_VERDICT_RETRY])
-+#AC_RUN_IFELSE(
-+#[AC_LANG_PROGRAM(
-+#[[
-+##include <daq.h>
-+#]],
-+#[[
-+#   DAQ_Verdict verdict;
-+#   verdict = DAQ_VERDICT_RETRY;
-+#]])],
-+have_daq_verdict_retry="yes"
-+#[have_daq_verdict_retry="no"])
-+#AC_MSG_RESULT($have_daq_verdict_retry)
-+#if test "x$have_daq_verdict_retry" = "xyes"; then
-+#    AC_DEFINE([HAVE_DAQ_VERDICT_RETRY],[1],
-+#        [DAQ version supports DAQ_VERDICT_RETRY in DAQ_Verdict.])
-+#fi
- 
- # any sparc platform has to have this one defined.
- AC_MSG_CHECKING(for sparc)
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/disable-inaddr-none.patch b/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/disable-inaddr-none.patch
deleted file mode 100644
index 79e9f07..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/disable-inaddr-none.patch
+++ /dev/null
@@ -1,85 +0,0 @@
-From a1fdbced4166cb0f35d23b63a59312d86860485a Mon Sep 17 00:00:00 2001
-From: Chunrong Guo <B40290@freescale.com>
-Date: Mon, 4 Nov 2013 10:39:56 +0800
-Subject: [PATCH] snort: add recipe
-
-Upstream-Status: Inappropriate [embedded specific]
-
-fix the below error:
-checking for INADDR_NONE... configure:
-configure: error: cannot run test program while cross compiling
-
-Signed-off-by: Chunrong Guo <B40290@freescale.com>
-
----
- configure.in | 50 ++++++++++++++++----------------------------------
- 1 file changed, 16 insertions(+), 34 deletions(-)
-
-diff --git a/configure.in b/configure.in
-index 20d15eb..6fe5d68 100644
---- a/configure.in
-+++ b/configure.in
-@@ -274,25 +274,7 @@ AC_CHECK_TYPES([int8_t,int16_t,int32_t,int64_t])
- AC_CHECK_TYPES([boolean])
- 
- # In case INADDR_NONE is not defined (like on Solaris)
--have_inaddr_none="no"
--AC_MSG_CHECKING([for INADDR_NONE])
--AC_RUN_IFELSE(
--[AC_LANG_PROGRAM(
--[[
--#include <sys/types.h>
--#include <netinet/in.h>
--#include <arpa/inet.h>
--]],
--[[
--	if (inet_addr("10,5,2") == INADDR_NONE);
--    return 0;
--]])],
--[have_inaddr_none="yes"],
--[have_inaddr_none="no"])
--AC_MSG_RESULT($have_inaddr_none)
--if test "x$have_inaddr_none" = "xno"; then
--	AC_DEFINE([INADDR_NONE],[-1],[For INADDR_NONE definition])
--fi
-+have_inaddr_none="yes"
- 
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
- #include <stdio.h>
-@@ -421,21 +403,21 @@ if test "x$LPCAP" = "xno"; then
-   fi
- fi
- 
--AC_MSG_CHECKING([for pcap_lex_destroy])
--AC_RUN_IFELSE(
--[AC_LANG_PROGRAM(
--[[
--#include <pcap.h>
--]],
--[[
--   pcap_lex_destroy();
--]])],
--[have_pcap_lex_destroy="yes"],
--[have_pcap_lex_destroy="no"])
--AC_MSG_RESULT($have_pcap_lex_destroy)
--if test "x$have_pcap_lex_destroy" = "xyes"; then
--    AC_DEFINE([HAVE_PCAP_LEX_DESTROY],[1],[Can cleanup lex buffer stack created by pcap bpf filter])
--fi
-+#AC_MSG_CHECKING([for pcap_lex_destroy])
-+#AC_RUN_IFELSE(
-+#[AC_LANG_PROGRAM(
-+#[[
-+##include <pcap.h>
-+#]],
-+#[[
-+#   pcap_lex_destroy();
-+#]])],
-+have_pcap_lex_destroy="yes"
-+#[have_pcap_lex_destroy="no"])
-+#AC_MSG_RESULT($have_pcap_lex_destroy)
-+#if test "x$have_pcap_lex_destroy" = "xyes"; then
-+#    AC_DEFINE([HAVE_PCAP_LEX_DESTROY],[1],[Can cleanup lex buffer stack created by pcap bpf filter])
-+#fi
- 
- AC_MSG_CHECKING([for pcap_lib_version])
- AC_LINK_IFELSE(
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/disable-run-test-program-while-cross-compiling.patch b/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/disable-run-test-program-while-cross-compiling.patch
new file mode 100644
index 0000000..037962f
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/snort/snort/disable-run-test-program-while-cross-compiling.patch
@@ -0,0 +1,254 @@
+From dc390837bc7adc205bb955d0922040a7e365d8dd Mon Sep 17 00:00:00 2001
+From: Yi Zhao <yi.zhao@windriver.com>
+Date: Mon, 23 Jul 2018 13:54:07 +0800
+Subject: [PATCH] Disable run test program while cross compiling
+
+fix configure error:
+configure: error: cannot run test program while cross compiling
+
+Upstream-Status:Inappropriate [embedded specific]
+
+Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
+---
+ configure.in | 148 +++++------------------------------------------------------
+ 1 file changed, 12 insertions(+), 136 deletions(-)
+
+diff --git a/configure.in b/configure.in
+index 4b3a5db..a6c5498 100644
+--- a/configure.in
++++ b/configure.in
+@@ -284,19 +284,7 @@ AC_CHECK_TYPES([boolean])
+ # In case INADDR_NONE is not defined (like on Solaris)
+ have_inaddr_none="no"
+ AC_MSG_CHECKING([for INADDR_NONE])
+-AC_RUN_IFELSE(
+-[AC_LANG_PROGRAM(
+-[[
+-#include <sys/types.h>
+-#include <netinet/in.h>
+-#include <arpa/inet.h>
+-]],
+-[[
+-	if (inet_addr("10,5,2") == INADDR_NONE);
+-    return 0;
+-]])],
+-[have_inaddr_none="yes"],
+-[have_inaddr_none="no"])
++have_inaddr_none="yes"
+ AC_MSG_RESULT($have_inaddr_none)
+ if test "x$have_inaddr_none" = "xno"; then
+ 	AC_DEFINE([INADDR_NONE],[-1],[For INADDR_NONE definition])
+@@ -429,16 +417,7 @@ if test "x$LPCAP" = "xno"; then
+ fi
+ 
+ AC_MSG_CHECKING([for pcap_lex_destroy])
+-AC_RUN_IFELSE(
+-[AC_LANG_PROGRAM(
+-[[
+-#include <pcap.h>
+-]],
+-[[
+-   pcap_lex_destroy();
+-]])],
+-[have_pcap_lex_destroy="yes"],
+-[have_pcap_lex_destroy="no"])
++have_pcap_lex_destroy="yes"
+ AC_MSG_RESULT($have_pcap_lex_destroy)
+ if test "x$have_pcap_lex_destroy" = "xyes"; then
+     AC_DEFINE([HAVE_PCAP_LEX_DESTROY],[1],[Can cleanup lex buffer stack created by pcap bpf filter])
+@@ -716,17 +695,7 @@ fi
+ AC_CHECK_FUNCS([daq_hup_apply] [daq_acquire_with_meta] [daq_dp_add_dc])
+ 
+ AC_MSG_CHECKING([for daq real addresses])
+-AC_RUN_IFELSE(
+-[AC_LANG_PROGRAM(
+-[[
+-#include <daq.h>
+-]],
+-[[
+-   DAQ_PktHdr_t hdr;
+-   hdr.n_real_dPort = 0;
+-]])],
+-[have_daq_real_addresses="yes"],
+-[have_daq_real_addresses="no"])
++have_daq_real_addresses="no"
+ AC_MSG_RESULT($have_daq_real_addresses)
+ if test "x$have_daq_real_addresses" = "xyes"; then
+     AC_DEFINE([HAVE_DAQ_REAL_ADDRESSES],[1],
+@@ -754,17 +723,7 @@ if test "x$ac_cv_func_daq_dp_add_dc" = "xyes"; then
+ fi
+ 
+ AC_MSG_CHECKING([for daq address space ID])
+-AC_RUN_IFELSE(
+-[AC_LANG_PROGRAM(
+-[[
+-#include <daq.h>
+-]],
+-[[
+-   DAQ_PktHdr_t hdr;
+-   hdr.address_space_id = 0;
+-]])],
+-[have_daq_address_space_id="yes"],
+-[have_daq_address_space_id="no"])
++have_daq_address_space_id="yes"
+ AC_MSG_RESULT($have_daq_address_space_id)
+ if test "x$have_daq_address_space_id" = "xyes"; then
+     AC_DEFINE([HAVE_DAQ_ADDRESS_SPACE_ID],[1],
+@@ -772,17 +731,7 @@ if test "x$have_daq_address_space_id" = "xyes"; then
+ fi
+ 
+ AC_MSG_CHECKING([for daq flow ID])
+-AC_RUN_IFELSE(
+-[AC_LANG_PROGRAM(
+-[[
+-#include <daq.h>
+-]],
+-[[
+-   DAQ_PktHdr_t hdr;
+-   hdr.flow_id = 0;
+-]])],
+-[have_daq_flow_id="yes"],
+-[have_daq_flow_id="no"])
++have_daq_flow_id="yes"
+ AC_MSG_RESULT($have_daq_flow_id)
+ if test "x$have_daq_flow_id" = "xyes"; then
+     AC_DEFINE([HAVE_DAQ_FLOW_ID],[1],
+@@ -790,19 +739,7 @@ if test "x$have_daq_flow_id" = "xyes"; then
+ fi
+ 
+ AC_MSG_CHECKING([for daq extended flow modifiers])
+-AC_RUN_IFELSE(
+-[AC_LANG_PROGRAM(
+-[[
+-#include <daq.h>
+-]],
+-[[
+-   DAQ_ModFlow_t mod;
+-   mod.type = 0;
+-   mod.length = 0;
+-   mod.value = NULL;
+-]])],
+-[have_daq_ext_modflow="yes"],
+-[have_daq_ext_modflow="no"])
++have_daq_ext_modflow="no"
+ AC_MSG_RESULT($have_daq_ext_modflow)
+ if test "x$have_daq_ext_modflow" = "xyes"; then
+     CCONFIGFLAGS="${CCONFIGFLAGS} -DHAVE_DAQ_EXT_MODFLOW"
+@@ -811,19 +748,7 @@ if test "x$have_daq_ext_modflow" = "xyes"; then
+ fi
+ 
+ AC_MSG_CHECKING([for daq query flow])
+-AC_RUN_IFELSE(
+-[AC_LANG_PROGRAM(
+-[[
+-#include <daq.h>
+-]],
+-[[
+-   DAQ_QueryFlow_t mod;
+-   mod.type = 0;
+-   mod.length = 0;
+-   mod.value = NULL;
+-]])],
+-[have_daq_queryflow="yes"],
+-[have_daq_queryflow="no"])
++have_daq_queryflow="no"
+ AC_MSG_RESULT($have_daq_queryflow)
+ if test "x$have_daq_queryflow" = "xyes"; then
+     CCONFIGFLAGS="${CCONFIGFLAGS} -DHAVE_DAQ_QUERYFLOW"
+@@ -832,16 +757,7 @@ if test "x$have_daq_queryflow" = "xyes"; then
+ fi
+ 
+ AC_MSG_CHECKING([for daq data channel flags])
+-AC_RUN_IFELSE(
+-[AC_LANG_PROGRAM(
+-[[
+-#include <daq.h>
+-]],
+-[[
+-   DAQ_Data_Channel_Params_t params;
+-]])],
+-[have_daq_data_channel_flags="yes"],
+-[have_daq_data_channel_flags="no"])
++have_daq_data_channel_flags="no"
+ AC_MSG_RESULT($have_daq_data_channel_flags)
+ if test "x$have_daq_data_channel_flags" = "xyes"; then
+     CCONFIGFLAGS="${CCONFIGFLAGS} -DHAVE_DAQ_DATA_CHANNEL_PARAMS"
+@@ -850,17 +766,7 @@ if test "x$have_daq_data_channel_flags" = "xyes"; then
+ fi
+ 
+ AC_MSG_CHECKING([for separate IP versions on pinhole endpoints])
+-AC_RUN_IFELSE(
+-[AC_LANG_PROGRAM(
+-[[
+-#include <daq.h>
+-]],
+-[[
+-   DAQ_DP_key_t dpKey;
+-   dpKey.src_af = 0;
+-]])],
+-[have_daq_data_channel_separate_ip_versions="yes"],
+-[have_daq_data_channel_separate_ip_versions="no"])
++have_daq_data_channel_separate_ip_versions="no"
+ AC_MSG_RESULT($have_daq_data_channel_separate_ip_versions)
+ if test "x$have_daq_data_channel_separate_ip_versions" = "xyes"; then
+     CCONFIGFLAGS="${CCONFIGFLAGS} -DHAVE_DAQ_DATA_CHANNEL_SEPARATE_IP_VERSIONS"
+@@ -869,17 +775,7 @@ if test "x$have_daq_data_channel_separate_ip_versions" = "xyes"; then
+ fi
+ 
+ AC_MSG_CHECKING([for DAQ_VERDICT_RETRY])
+-AC_RUN_IFELSE(
+-[AC_LANG_PROGRAM(
+-[[
+-#include <daq.h>
+-]],
+-[[
+-   DAQ_Verdict verdict;
+-   verdict = DAQ_VERDICT_RETRY;
+-]])],
+-[have_daq_verdict_retry="yes"],
+-[have_daq_verdict_retry="no"])
++have_daq_verdict_retry="yes"
+ AC_MSG_RESULT($have_daq_verdict_retry)
+ if test "x$have_daq_verdict_retry" = "xyes"; then
+     AC_DEFINE([HAVE_DAQ_VERDICT_RETRY],[1],
+@@ -887,17 +783,7 @@ if test "x$have_daq_verdict_retry" = "xyes"; then
+ fi
+ 
+ AC_MSG_CHECKING([for daq packet trace])
+-AC_RUN_IFELSE(
+-[AC_LANG_PROGRAM(
+-[[
+-#include <daq.h>
+-]],
+-[[
+-   DAQ_PktHdr_t hdr;
+-   hdr.flags = DAQ_PKT_FLAG_TRACE_ENABLED;
+-]])],
+-[have_daq_packet_trace="yes"],
+-[have_daq_packet_trace="no"])
++have_daq_packet_trace="yes"
+ AC_MSG_RESULT($have_daq_packet_trace)
+ if test "x$have_daq_packet_trace" = "xyes"; then
+     AC_DEFINE([HAVE_DAQ_PKT_TRACE],[1],
+@@ -907,17 +793,7 @@ else
+ fi
+ 
+ AC_MSG_CHECKING([for daq verdict reason])
+-AC_RUN_IFELSE(
+-[AC_LANG_PROGRAM(
+-[[
+-#include <daq.h>
+-]],
+-[[
+-   DAQ_ModFlow_t fl;
+-   fl.type = DAQ_MODFLOW_TYPE_VER_REASON;
+-]])],
+-[have_daq_verdict_reason="yes"],
+-[have_daq_verdict_reason="no"])
++have_daq_verdict_reason="yes"
+ AC_MSG_RESULT($have_daq_verdict_reason)
+ if test "x$have_daq_verdict_reason" = "xyes"; then
+     AC_DEFINE([HAVE_DAQ_VERDICT_REASON],[1],
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/snort/snort_2.9.11.1.bb b/meta-openembedded/meta-networking/recipes-connectivity/snort/snort_2.9.11.1.bb
new file mode 100644
index 0000000..a99138d
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/snort/snort_2.9.11.1.bb
@@ -0,0 +1,103 @@
+DESCRIPTION = "snort - a free lightweight network intrusion detection system for UNIX and Windows."
+HOMEPAGE = "http://www.snort.org/"
+SECTION = "net"
+LICENSE = "GPL-2.0"
+LIC_FILES_CHKSUM = "file://COPYING;md5=78fa8ef966b48fbf9095e13cc92377c5"
+
+DEPENDS = "xz libpcap libpcre daq libdnet util-linux daq-native libtirpc bison-native"
+
+SRC_URI = "https://www.snort.org/downloads/archive/snort/${BP}.tar.gz \
+    file://snort.init \
+    file://0001-libpcap-search-sysroot-for-headers.patch \
+    file://fix-host-contamination-when-enable-static-daq.patch \
+    file://disable-run-test-program-while-cross-compiling.patch \
+"
+
+SRC_URI[md5sum] = "378e3938b2b5c8e358f942d0ffce18cc"
+SRC_URI[sha256sum] = "9f6b3aeac5a109f55504bd370564ac431cb1773507929dc461626898f33f46cd"
+
+UPSTREAM_CHECK_URI = "https://www.snort.org/downloads"
+UPSTREAM_CHECK_REGEX = "snort-(?P<pver>\d+(\.\d+)+)\.tar"
+
+inherit autotools gettext update-rc.d pkgconfig
+
+INITSCRIPT_NAME = "snort"
+INITSCRIPT_PARAMS = "defaults"
+
+EXTRA_OECONF = " \
+    --enable-gre \
+    --enable-linux-smp-stats \
+    --enable-reload \
+    --enable-reload-error-restart \
+    --enable-targetbased \
+    --enable-static-daq \
+    --with-dnet-includes=${STAGING_INCDIR} \
+    --with-dnet-libraries=${STAGING_LIBDIR} \
+    --with-libpcre-includes=${STAGING_INCDIR} \
+    --with-libpcre-libraries=${STAGING_LIBDIR} \
+    --with-daq-includes=${STAGING_INCDIR} \
+    --with-daq-libraries=${STAGING_LIBDIR} \
+"
+
+# if you want to disable it, you need to patch configure.in first
+# AC_CHECK_HEADERS([openssl/sha.h],, SHA_H="no")
+# is called even with --without-openssl-includes
+PACKAGECONFIG ?= "openssl lzma"
+PACKAGECONFIG[openssl] = "--with-openssl-includes=${STAGING_INCDIR} --with-openssl-libraries=${STAGING_LIBDIR}, --without-openssl-includes --without-openssl-libraries, openssl,"
+PACKAGECONFIG[lzma] = "--with-lzma-includes=${STAGING_INCDIR} --with-lzma-libraries=${STAGING_LIBDIR}, --without-lzma-includes --without-lzma-libraries, xz,"
+
+CFLAGS += "-I${STAGING_INCDIR}/tirpc"
+LDFLAGS += " -ltirpc"
+
+do_install_append() {
+    install -d ${D}${sysconfdir}/snort/rules
+    install -d ${D}${sysconfdir}/snort/preproc_rules
+    install -d ${D}${sysconfdir}/init.d
+    for i in map config conf dtd; do
+        cp ${S}/etc/*.$i ${D}${sysconfdir}/snort/
+    done
+
+    # fix the hardcoded path and lib name
+    # comment out the rules that are not provided
+    sed -i -e 's#/usr/local/lib#${libdir}#' \
+           -e 's#\.\./\(.*rules\)#${sysconfdir}/snort/\1#' \
+           -e 's#\(libsf_engine.so\)#\1.0#' \
+           -e 's/^\(include $RULE_PATH\)/#\1/' \
+           -e 's/^\(dynamicdetection\)/#\1/' \
+           -e '/preprocessor reputation/,/blacklist/ s/^/#/' \
+           ${D}${sysconfdir}/snort/snort.conf
+
+    cp ${S}/preproc_rules/*.rules ${D}${sysconfdir}/snort/preproc_rules/
+    install -m 755 ${WORKDIR}/snort.init ${D}${sysconfdir}/init.d/snort
+    mkdir -p ${D}${localstatedir}/log/snort
+    install -d ${D}/var/log/snort
+
+    sed -i 's/-fdebug-prefix-map[^ ]*//g; s#${STAGING_DIR_TARGET}##g' ${D}${libdir}/pkgconfig/*.pc
+}
+
+FILES_${PN} += " \
+    ${libdir}/snort_dynamicengine/*.so.* \
+    ${libdir}/snort_dynamicpreprocessor/*.so.* \
+    ${libdir}/snort_dynamicrules/*.so.* \
+"
+FILES_${PN}-dbg += " \
+    ${libdir}/snort_dynamicengine/.debug \
+    ${libdir}/snort_dynamicpreprocessor/.debug \
+    ${libdir}/snort_dynamicrules/.debug \
+"
+FILES_${PN}-staticdev += " \
+    ${libdir}/snort_dynamicengine/*.a \
+    ${libdir}/snort_dynamicpreprocessor/*.a \
+    ${libdir}/snort_dynamicrules/*.a \
+    ${libdir}/snort/dynamic_preproc/*.a \
+    ${libdir}/snort/dynamic_output/*.a \
+"
+FILES_${PN}-dev += " \
+    ${libdir}/snort_dynamicengine/*.la \
+    ${libdir}/snort_dynamicpreprocessor/*.la \
+    ${libdir}/snort_dynamicrules/*.la \
+    ${libdir}/snort_dynamicengine/*.so \
+    ${libdir}/snort_dynamicpreprocessor/*.so \
+    ${libdir}/snort_dynamicrules/*.so \
+    ${prefix}/src/snort_dynamicsrc \
+"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/snort/snort_2.9.7.5.bb b/meta-openembedded/meta-networking/recipes-connectivity/snort/snort_2.9.7.5.bb
deleted file mode 100644
index 2034b85..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/snort/snort_2.9.7.5.bb
+++ /dev/null
@@ -1,105 +0,0 @@
-DESCRIPTION = "snort - a free lightweight network intrusion detection system for UNIX and Windows."
-HOMEPAGE = "http://www.snort.org/"
-SECTION = "net"
-LICENSE = "GPL-2.0"
-LIC_FILES_CHKSUM = "file://COPYING;md5=78fa8ef966b48fbf9095e13cc92377c5"
-
-DEPENDS = "xz libpcap libpcre daq libdnet util-linux daq-native"
-DEPENDS_append_libc-musl = " libtirpc"
-
-SRC_URI = " ${GENTOO_MIRROR}/${BP}.tar.gz;name=tarball \
-    file://snort.init \
-    file://disable-inaddr-none.patch \
-    file://disable-dap-address-space-id.patch \
-    file://disable-daq-flow-id.patch \
-    file://disable-daq-verdict-retry.patch \
-    file://0001-libpcap-search-sysroot-for-headers.patch \
-    file://0001-fix-do_package-failed-since-snort-2.9.7.0.patch \
-    file://fix-host-contamination-when-enable-static-daq.patch \
-"
-
-SRC_URI[tarball.md5sum] = "fd271788c0f8876be87a858a9142f202"
-SRC_URI[tarball.sha256sum] = "ad03f11b5301b16642199a86aa90388eaa53f5003f83b0c5595745a490047be1"
-
-inherit autotools gettext update-rc.d pkgconfig
-
-INITSCRIPT_NAME = "snort"
-INITSCRIPT_PARAMS = "defaults"
-
-EXTRA_OECONF = " \
-    --enable-gre \
-    --enable-linux-smp-stats \
-    --enable-reload \
-    --enable-reload-error-restart \
-    --enable-targetbased \
-    --enable-static-daq \
-    --with-dnet-includes=${STAGING_INCDIR} \
-    --with-dnet-libraries=${STAGING_LIBDIR} \
-    --with-libpcre-includes=${STAGING_INCDIR} \
-    --with-libpcre-libraries=${STAGING_LIBDIR} \
-    --with-daq-includes=${STAGING_INCDIR} \
-    --with-daq-libraries=${STAGING_LIBDIR} \
-"
-
-# if you want to disable it, you need to patch configure.in first
-# AC_CHECK_HEADERS([openssl/sha.h],, SHA_H="no")
-# is called even with --without-openssl-includes
-PACKAGECONFIG ?= "openssl lzma"
-PACKAGECONFIG[openssl] = "--with-openssl-includes=${STAGING_INCDIR} --with-openssl-libraries=${STAGING_LIBDIR}, --without-openssl-includes --without-openssl-libraries, openssl,"
-PACKAGECONFIG[lzma] = "--with-lzma-includes=${STAGING_INCDIR} --with-lzma-libraries=${STAGING_LIBDIR}, --without-lzma-includes --without-lzma-libraries, xz,"
-
-CFLAGS_append_libc-musl = " -I${STAGING_INCDIR}/tirpc"
-LDFLAGS_append_libc-musl = " -ltirpc"
-
-do_install_append() {
-    install -d ${D}${sysconfdir}/snort/rules
-    install -d ${D}${sysconfdir}/snort/preproc_rules
-    install -d ${D}${sysconfdir}/init.d
-    for i in map config conf dtd; do
-        cp ${S}/etc/*.$i ${D}${sysconfdir}/snort/
-    done
-
-    # fix the hardcoded path and lib name
-    # comment out the rules that are not provided
-    sed -i -e 's#/usr/local/lib#${libdir}#' \
-           -e 's#\.\./\(.*rules\)#${sysconfdir}/snort/\1#' \
-           -e 's#\(libsf_engine.so\)#\1.0#' \
-           -e 's/^\(include $RULE_PATH\)/#\1/' \
-           -e 's/^\(dynamicdetection\)/#\1/' \
-           -e '/preprocessor reputation/,/blacklist/ s/^/#/' \
-           ${D}${sysconfdir}/snort/snort.conf
-
-    cp ${S}/preproc_rules/*.rules ${D}${sysconfdir}/snort/preproc_rules/
-    install -m 755 ${WORKDIR}/snort.init ${D}${sysconfdir}/init.d/snort
-    mkdir -p ${D}${localstatedir}/log/snort
-    install -d ${D}/var/log/snort
-
-    sed -i 's/-fdebug-prefix-map[^ ]*//g; s#${STAGING_DIR_TARGET}##g' ${D}${libdir}/pkgconfig/*.pc
-}
-
-FILES_${PN} += " \
-    ${libdir}/snort_dynamicengine/*.so.* \
-    ${libdir}/snort_dynamicpreprocessor/*.so.* \
-    ${libdir}/snort_dynamicrules/*.so.* \
-"
-FILES_${PN}-dbg += " \
-    ${libdir}/snort_dynamicengine/.debug \
-    ${libdir}/snort_dynamicpreprocessor/.debug \
-    ${libdir}/snort_dynamicrules/.debug \
-"
-FILES_${PN}-staticdev += " \
-    ${libdir}/snort_dynamicengine/*.a \
-    ${libdir}/snort_dynamicpreprocessor/*.a \
-    ${libdir}/snort_dynamicrules/*.a \
-    ${libdir}/snort/dynamic_preproc/*.a \
-    ${libdir}/snort/dynamic_output/*.a \
-"
-FILES_${PN}-dev += " \
-    ${libdir}/snort_dynamicengine/*.la \
-    ${libdir}/snort_dynamicpreprocessor/*.la \
-    ${libdir}/snort_dynamicrules/*.la \
-    ${libdir}/snort_dynamicengine/*.so \
-    ${libdir}/snort_dynamicpreprocessor/*.so \
-    ${libdir}/snort_dynamicrules/*.so \
-    ${prefix}/src/snort_dynamicsrc \
-"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/umip/files/0001-Add-format-string-to-fprintf-call.patch b/meta-openembedded/meta-networking/recipes-connectivity/umip/umip/0001-Add-format-string-to-fprintf-call.patch
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-connectivity/umip/files/0001-Add-format-string-to-fprintf-call.patch
rename to meta-openembedded/meta-networking/recipes-connectivity/umip/umip/0001-Add-format-string-to-fprintf-call.patch
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/umip/umip/0001-replace-SIGCLD-with-SIGCHLD-and-include-sys-types.h.patch b/meta-openembedded/meta-networking/recipes-connectivity/umip/umip/0001-replace-SIGCLD-with-SIGCHLD-and-include-sys-types.h.patch
new file mode 100644
index 0000000..153bced
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/umip/umip/0001-replace-SIGCLD-with-SIGCHLD-and-include-sys-types.h.patch
@@ -0,0 +1,38 @@
+From f567740cf64978ac9db014c786b6d0267b244f33 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 4 Mar 2018 22:30:30 -0800
+Subject: [PATCH 1/2] replace SIGCLD with SIGCHLD and include sys/types.h
+
+Fixes
+main.c:129:10: error: 'SIGCLD' undeclared (first use in this function); did you mean 'SIGCHLD'?
+   signal(SIGCLD, sig_child);
+          ^~~~~~
+          SIGCHLD
+
+main.c:125:2: warning: implicit declaration of function 'umask' [-Wimplicit-function-declaration]
+  umask(0);
+  ^~~~~
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ src/main.c | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+Index: git/src/main.c
+===================================================================
+--- git.orig/src/main.c
++++ git/src/main.c
+@@ -133,9 +133,9 @@ static void daemon_start(int ignsigcld)
+ 
+ 	if (ignsigcld) {
+ #ifdef SIGTSTP
+-		signal(SIGCLD, sig_child);
++		signal(SIGCHLD, sig_child);
+ #else
+-		signal(SIGCLD, SIG_IGN);
++		signal(SIGCHLD, SIG_IGN);
+ #endif
+ 	}
+ }
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/umip/umip/0001-support-openssl-1.1.x.patch b/meta-openembedded/meta-networking/recipes-connectivity/umip/umip/0001-support-openssl-1.1.x.patch
new file mode 100644
index 0000000..d8355e2
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/umip/umip/0001-support-openssl-1.1.x.patch
@@ -0,0 +1,88 @@
+From 62784e8b6df8ff3a907c1f816154808bea9d7064 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Tue, 25 Sep 2018 14:38:14 +0800
+Subject: [PATCH] support openssl 1.1.x
+
+Long time no maintain from upstream since 2013
+(git://git.umip.org/umip/umip.git), backport a
+fix from openSUSE
+
+Upstream-Status: Backport [openSUSE]
+http://ftp.gwdg.de/pub/opensuse/source/distribution/leap/15.0/repo/oss/src/mipv6d-2.0.2.umip.0.4-lp150.1.2.src.rpm
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ src/keygen.c | 12 ++++++++++++
+ src/mh.c     | 17 ++++++++++++++++-
+ 2 files changed, 28 insertions(+), 1 deletion(-)
+
+diff --git a/src/keygen.c b/src/keygen.c
+index e434a38..b902644 100644
+--- a/src/keygen.c
++++ b/src/keygen.c
+@@ -172,6 +172,7 @@ static void build_kgen_token(struct in6_addr *addr, uint8_t *nonce,
+ 	uint8_t tmp[20];
+ #ifdef HAVE_LIBCRYPTO
+ 	unsigned int len = 20;
++#if defined(OPENSSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER < 0x1010006fL
+ 	HMAC_CTX ctx;
+ 
+ 	HMAC_CTX_init(&ctx);
+@@ -182,6 +183,17 @@ static void build_kgen_token(struct in6_addr *addr, uint8_t *nonce,
+ 	HMAC_Final(&ctx, tmp, &len);
+ 	HMAC_CTX_cleanup(&ctx);
+ #else
++	HMAC_CTX *ctx;
++	ctx = HMAC_CTX_new();
++	HMAC_Init_ex(ctx, key_cn, sizeof(key_cn), EVP_sha1(), NULL);
++	HMAC_Update(ctx, (unsigned char *)addr, sizeof(*addr));
++	HMAC_Update(ctx, nonce, NONCE_LENGTH);
++	HMAC_Update(ctx, &id, sizeof(id));
++	HMAC_Final(ctx, tmp, &len);
++	HMAC_CTX_free(ctx);
++#endif // End of defined(OPENSSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER < 0x1010006fL
++
++#else
+ 	HMAC_SHA1_CTX ctx;
+ 
+ 	HMAC_SHA1_init(&ctx, key_cn, sizeof(key_cn));
+diff --git a/src/mh.c b/src/mh.c
+index cba9a33..212eb5a 100644
+--- a/src/mh.c
++++ b/src/mh.c
+@@ -518,9 +518,10 @@ static int calculate_auth_data(const struct iovec *iov, int iovlen,
+ 
+ #ifdef HAVE_LIBCRYPTO
+ 	unsigned int len = HMAC_SHA1_HASH_LEN;
+-	HMAC_CTX ctx;
+ 	const EVP_MD *evp_md = EVP_sha1();
+ 
++#if defined(OPENSSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER < 0x1010006fL
++	HMAC_CTX ctx;
+ 	HMAC_CTX_init(&ctx);
+ 	HMAC_Init_ex(&ctx, key, HMAC_SHA1_KEY_SIZE, evp_md, NULL);
+ 
+@@ -532,6 +533,20 @@ static int calculate_auth_data(const struct iovec *iov, int iovlen,
+ 	HMAC_Final(&ctx, buf, &len);
+ 	HMAC_CTX_cleanup(&ctx);
+ #else
++	HMAC_CTX *ctx;
++	ctx = HMAC_CTX_new();
++	HMAC_Init_ex(ctx, key, HMAC_SHA1_KEY_SIZE, evp_md, NULL);
++
++	HMAC_Update(ctx, (uint8_t *)coa, sizeof(*coa));
++	HMAC_Update(ctx, (uint8_t *)cn, sizeof(*coa));
++	for (i = 0; i < iovlen; i++) {
++		HMAC_Update(ctx, (uint8_t *)iov[i].iov_base, iov[i].iov_len);
++	}
++	HMAC_Final(ctx, buf, &len);
++	HMAC_CTX_free(ctx);
++#endif
++
++#else
+ 	HMAC_SHA1_CTX ctx;
+ 
+ 	HMAC_SHA1_init(&ctx, key, HMAC_SHA1_KEY_SIZE);
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/umip/files/0002-replace-PTHREAD_MUTEX_FAST_NP-with-PTHREAD_MUTEX_NOR.patch b/meta-openembedded/meta-networking/recipes-connectivity/umip/umip/0002-replace-PTHREAD_MUTEX_FAST_NP-with-PTHREAD_MUTEX_NOR.patch
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-connectivity/umip/files/0002-replace-PTHREAD_MUTEX_FAST_NP-with-PTHREAD_MUTEX_NOR.patch
rename to meta-openembedded/meta-networking/recipes-connectivity/umip/umip/0002-replace-PTHREAD_MUTEX_FAST_NP-with-PTHREAD_MUTEX_NOR.patch
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/umip/files/add-dependency-to-support-parallel-compilation.patch b/meta-openembedded/meta-networking/recipes-connectivity/umip/umip/add-dependency-to-support-parallel-compilation.patch
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-connectivity/umip/files/add-dependency-to-support-parallel-compilation.patch
rename to meta-openembedded/meta-networking/recipes-connectivity/umip/umip/add-dependency-to-support-parallel-compilation.patch
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/umip/files/mip6d b/meta-openembedded/meta-networking/recipes-connectivity/umip/umip/mip6d
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-connectivity/umip/files/mip6d
rename to meta-openembedded/meta-networking/recipes-connectivity/umip/umip/mip6d
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/umip/files/mip6d.service b/meta-openembedded/meta-networking/recipes-connectivity/umip/umip/mip6d.service
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-connectivity/umip/files/mip6d.service
rename to meta-openembedded/meta-networking/recipes-connectivity/umip/umip/mip6d.service
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/umip/umip_1.0.bb b/meta-openembedded/meta-networking/recipes-connectivity/umip/umip_1.0.bb
new file mode 100644
index 0000000..e2abc02
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/umip/umip_1.0.bb
@@ -0,0 +1,43 @@
+SUMMARY = "Mobile IPv6 and NEMO for Linux"
+DESCRIPTION = "UMIP is an open source implementation of Mobile IPv6 and NEMO \
+Basic Support for Linux. It is released under the GPLv2 license. It supports \
+the following IETF RFC: RFC6275 (Mobile IPv6), RFC3963 (NEMO), RFC3776 and \
+RFC4877 (IPsec and IKEv2)."
+HOMEPAGE = "http://umip.org/"
+SECTION = "System Environment/Base"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=073dc31ccb2ebed70db54f1e8aeb4c33"
+DEPENDS = "openssl ipsec-tools radvd indent-native bison-native"
+
+SRC_URI = "git://git.umip.org/umip/umip.git \
+           file://add-dependency-to-support-parallel-compilation.patch \
+           file://mip6d \
+           file://mip6d.service \
+           file://0001-Add-format-string-to-fprintf-call.patch \
+           file://0001-replace-SIGCLD-with-SIGCHLD-and-include-sys-types.h.patch \
+           file://0002-replace-PTHREAD_MUTEX_FAST_NP-with-PTHREAD_MUTEX_NOR.patch \
+           file://0001-support-openssl-1.1.x.patch \
+           "
+SRCREV = "cbd441c5db719db554ff2b4fcb02fef88ae2f791"
+
+S = "${WORKDIR}/git"
+
+EXTRA_OECONF = "--enable-vt"
+
+inherit autotools-brokensep systemd update-rc.d
+
+INITSCRIPT_NAME = "mip6d"
+INITSCRIPT_PARAMS = "start 64 . stop 36 0 1 2 3 4 5 6 ."
+
+SYSTEMD_SERVICE_${PN} = "mip6d.service"
+SYSTEMD_AUTO_ENABLE = "disable"
+
+do_install_append() {
+	install -D -m 0755 ${WORKDIR}/mip6d ${D}${sysconfdir}/init.d/mip6d
+	install -D -m 0644 ${WORKDIR}/mip6d.service ${D}${systemd_system_unitdir}/mip6d.service
+	sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' \
+	    -e 's,@SBINDIR@,${sbindir},g' \
+	    ${D}${systemd_system_unitdir}/mip6d.service
+}
+
+RRECOMMENDS_${PN} = "kernel-module-mip6 kernel-module-ipv6"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/vlan/vlan_1.9.bb b/meta-openembedded/meta-networking/recipes-connectivity/vlan/vlan_1.9.bb
index 7eea5d1..4c3d95b 100644
--- a/meta-openembedded/meta-networking/recipes-connectivity/vlan/vlan_1.9.bb
+++ b/meta-openembedded/meta-networking/recipes-connectivity/vlan/vlan_1.9.bb
@@ -4,7 +4,7 @@
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://vconfig.c;beginline=1;endline=19;md5=094ca47de36c20c598b15b32c270ce0a"
 
-SRC_URI = "http://${BPN}.sourcearchive.com/downloads/${PV}-3ubuntu9/${BPN}_${PV}.orig.tar.gz \
+SRC_URI = "https://launchpad.net/ubuntu/+archive/primary/+sourcefiles/vlan/1.9-3ubuntu10.6/${BPN}_${PV}.orig.tar.gz \
            file://no-HOME-includes.patch \
            file://0001-Add-printf-format-and-silence-format-security-warnin.patch \
 "
@@ -12,6 +12,9 @@
 SRC_URI[md5sum] = "5f0c6060b33956fb16e11a15467dd394"
 SRC_URI[sha256sum] = "3b8f0a1bf0d3642764e5f646e1f3bbc8b1eeec474a77392d9aeb4868842b4cca"
 
+UPSTREAM_CHECK_URI = "http://vlan.sourcearchive.com/"
+UPSTREAM_CHECK_REGEX = "/(?P<pver>\d+(\.\d+)+)/"
+
 S = "${WORKDIR}/${BPN}"
 
 inherit update-alternatives
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/wireless-regdb/wireless-regdb_2016.06.10.bb b/meta-openembedded/meta-networking/recipes-connectivity/wireless-regdb/wireless-regdb_2016.06.10.bb
deleted file mode 100644
index 64e9401..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/wireless-regdb/wireless-regdb_2016.06.10.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-SUMMARY = "Wireless Central Regulatory Domain Database"
-HOMEPAGE = "http://wireless.kernel.org/en/developers/Regulatory/CRDA"
-SECTION = "net"
-LICENSE = "ISC"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=07c4f6dea3845b02a18dc00c8c87699c"
-
-SRC_URI = "https://www.kernel.org/pub/software/network/${BPN}/${BP}.tar.xz"
-SRC_URI[md5sum] = "d282cce92b6e692e8673e2bd97adf33b"
-SRC_URI[sha256sum] = "cfedf1c3521b3c8f32602f25ed796e96e687c3441a00e7c050fedf7fd4f1b8b7"
-
-inherit bin_package
-
-do_install() {
-    install -d -m0755 ${D}${libdir}/crda
-    install -d -m0755 ${D}${sysconfdir}/wireless-regdb/pubkeys
-    install -m 0644 regulatory.bin ${D}${libdir}/crda/regulatory.bin
-    install -m 0644 sforshee.key.pub.pem ${D}${sysconfdir}/wireless-regdb/pubkeys/sforshee.key.pub.pem
-}
-
-RSUGGESTS_${PN} = "crda"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/wireless-regdb/wireless-regdb_2018.05.31.bb b/meta-openembedded/meta-networking/recipes-connectivity/wireless-regdb/wireless-regdb_2018.05.31.bb
new file mode 100644
index 0000000..2b990db
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/wireless-regdb/wireless-regdb_2018.05.31.bb
@@ -0,0 +1,42 @@
+SUMMARY = "Wireless Central Regulatory Domain Database"
+HOMEPAGE = "http://wireless.kernel.org/en/developers/Regulatory/CRDA"
+SECTION = "net"
+LICENSE = "ISC"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=07c4f6dea3845b02a18dc00c8c87699c"
+
+SRC_URI = "https://www.kernel.org/pub/software/network/${BPN}/${BP}.tar.xz"
+SRC_URI[md5sum] = "0cbbdc21186c76cf58aba01b03f3dc5b"
+SRC_URI[sha256sum] = "e1dfbc3b97771373077f430c3c05082fae883145b37db5b2cfd12c56676fbe7b"
+
+inherit bin_package allarch
+
+do_install() {
+    install -d -m0755 ${D}${nonarch_libdir}/crda
+    install -d -m0755 ${D}${sysconfdir}/wireless-regdb/pubkeys
+    install -m 0644 regulatory.bin ${D}${nonarch_libdir}/crda/regulatory.bin
+    install -m 0644 sforshee.key.pub.pem ${D}${sysconfdir}/wireless-regdb/pubkeys/sforshee.key.pub.pem
+
+    install -m 0644 -D regulatory.db ${D}${nonarch_base_libdir}/firmware/regulatory.db
+    install -m 0644 regulatory.db.p7s ${D}${nonarch_base_libdir}/firmware/regulatory.db.p7s
+}
+
+# Install static regulatory DB in /lib/firmware for kernel to load.
+# This requires Linux kernel >= v4.15.
+# For kernel <= v4.14, inherit the kernel_wireless_regdb.bbclass in kernel's recipe.
+PACKAGES =+ "${PN}-static"
+RCONFLICTS_${PN} = "${PN}-static"
+
+FILES_${PN}-static = " \
+    ${nonarch_base_libdir}/firmware/regulatory.db \
+    ${nonarch_base_libdir}/firmware/regulatory.db.p7s \
+"
+
+# Native users might want to use the source of regulatory DB.
+# This is for example used by Linux kernel <= v4.14 and kernel_wireless_regdb.bbclass.
+do_install_append_class-native() {
+    install -m 0644 -D db.txt ${D}${libdir}/crda/db.txt
+}
+
+RSUGGESTS_${PN} = "crda"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/wolfssl/wolfssl_3.12.0.bb b/meta-openembedded/meta-networking/recipes-connectivity/wolfssl/wolfssl_3.12.0.bb
deleted file mode 100644
index 9290651..0000000
--- a/meta-openembedded/meta-networking/recipes-connectivity/wolfssl/wolfssl_3.12.0.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-SUMMARY = "wolfSSL Lightweight, Embedded SSL Library"
-DESCRIPTION = "wolfSSL, formerly CyaSSL, is a lightweight SSL library written in C and \
-               optimized for embedded and RTOS environments. It can be \
-               Up to 20 times smaller than OpenSSL while still supporting \
-               a full TLS 1.2 client and server."
-HOMEPAGE = "http://www.wolfssl.com/yaSSL/Products-wolfssl.html"
-BUGTRACKER = "http://github.com/wolfssl/wolfssl/issues"
-SECTION = "libs"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-
-PROVIDES += "cyassl"
-RPROVIDES_${PN} = "cyassl"
-
-S = "${WORKDIR}/git"
-SRCREV = "d195009dcb62d8712195661bd1d50f8dd6831044"
-SRC_URI = "git://github.com/wolfSSL/wolfssl.git;protocol=https; \
-           file://0001-fix-no-rule-to-make-cyassl-options.h.patch \
-          "
-
-inherit autotools
-
-PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}"
-PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
diff --git a/meta-openembedded/meta-networking/recipes-connectivity/wolfssl/wolfssl_3.14.4.bb b/meta-openembedded/meta-networking/recipes-connectivity/wolfssl/wolfssl_3.14.4.bb
new file mode 100644
index 0000000..dc9094d
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-connectivity/wolfssl/wolfssl_3.14.4.bb
@@ -0,0 +1,24 @@
+SUMMARY = "wolfSSL Lightweight, Embedded SSL Library"
+DESCRIPTION = "wolfSSL, formerly CyaSSL, is a lightweight SSL library written in C and \
+               optimized for embedded and RTOS environments. It can be \
+               Up to 20 times smaller than OpenSSL while still supporting \
+               a full TLS 1.2 client and server."
+HOMEPAGE = "http://www.wolfssl.com/yaSSL/Products-wolfssl.html"
+BUGTRACKER = "http://github.com/wolfssl/wolfssl/issues"
+SECTION = "libs"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+PROVIDES += "cyassl"
+RPROVIDES_${PN} = "cyassl"
+
+S = "${WORKDIR}/git"
+SRCREV = "1196a3b64d9fabffc8273b87f6f69ac0e75d2eb7"
+SRC_URI = "git://github.com/wolfSSL/wolfssl.git;protocol=https; \
+           file://0001-fix-no-rule-to-make-cyassl-options.h.patch \
+          "
+
+inherit autotools
+
+PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}"
+PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
diff --git a/meta-openembedded/meta-networking/recipes-daemons/autofs/autofs/0001-Do-not-hardcode-path-for-pkg.m4.patch b/meta-openembedded/meta-networking/recipes-daemons/autofs/autofs/0001-Do-not-hardcode-path-for-pkg.m4.patch
new file mode 100644
index 0000000..f3f25f4
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/autofs/autofs/0001-Do-not-hardcode-path-for-pkg.m4.patch
@@ -0,0 +1,28 @@
+From 6d24365f0828185fd1bb4d199209ca07eb95c41d Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 24 Aug 2018 06:24:36 +0000
+Subject: [PATCH] Do not hardcode path for pkg.m4
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ configure.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.in b/configure.in
+index 50aed15..f81767c 100644
+--- a/configure.in
++++ b/configure.in
+@@ -12,7 +12,7 @@ define([AC_CACHE_SAVE], )dnl
+ AC_INIT(.autofs-5.1.4)
+ 
+ # for pkg-config macros
+-m4_include([/usr/share/aclocal/pkg.m4])
++m4_include([pkg.m4])
+ 
+ #
+ # autofs installs by default in /usr
+-- 
+1.9.1
+
diff --git a/meta-openembedded/meta-networking/recipes-daemons/autofs/autofs/autofs-5.1.2-libtirpc-as-need.patch b/meta-openembedded/meta-networking/recipes-daemons/autofs/autofs/autofs-5.1.2-libtirpc-as-need.patch
deleted file mode 100644
index 18ce193..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/autofs/autofs/autofs-5.1.2-libtirpc-as-need.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From b31decac4acb194b020c621d2d11019f636a45e0 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 24 Apr 2017 20:41:25 -0700
-Subject: [PATCH] autofs: Upgrade to 5.1.2 release
-
-Make configure compatible with -Wl,--as-needed following
-https://wiki.gentoo.org/wiki/Project:Quality_Assurance/As-needed#Failure_in_..2Fconfigure
-
-2016-07-05 Martin von Gagern
-
----
- aclocal.m4 | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/aclocal.m4 b/aclocal.m4
-index 0e4a624..2e620cd 100644
---- a/aclocal.m4
-+++ b/aclocal.m4
-@@ -415,9 +415,9 @@ AC_DEFUN([AF_CHECK_LIBTIRPC],
- [
- # save current flags
- af_check_libtirpc_save_cflags="$CFLAGS"
--af_check_libtirpc_save_ldflags="$LDFLAGS"
-+af_check_libtirpc_save_libs="$LIBS"
- CFLAGS="$CFLAGS -I=/usr/include/tirpc"
--LDFLAGS="$LDFLAGS -ltirpc"
-+LIBS="$LIBS -ltirpc"
- 
- AC_TRY_LINK(
-     [ #include <rpc/rpc.h> ],
-@@ -440,7 +440,7 @@ AC_CHECK_FUNCS([getrpcbyname getservbyname])
- 
- # restore flags
- CFLAGS="$af_check_libtirpc_save_cflags"
--LDFLAGS="$af_check_libtirpc_save_ldflags"
-+LIBS="$af_check_libtirpc_save_libs"
- ])
- 
- AC_DEFUN([AF_WITH_LIBTIRPC],
diff --git a/meta-openembedded/meta-networking/recipes-daemons/autofs/autofs/libtirpc.patch b/meta-openembedded/meta-networking/recipes-daemons/autofs/autofs/libtirpc.patch
deleted file mode 100644
index 0a2d502..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/autofs/autofs/libtirpc.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From cb6a4f61adb027f2366318f2c08c8264ebf39218 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 5 Jan 2013 19:53:10 -0800
-
----
- Makefile.rules | 2 +-
- aclocal.m4     | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/Makefile.rules b/Makefile.rules
-index 6fa3e02..709dd04 100644
---- a/Makefile.rules
-+++ b/Makefile.rules
-@@ -46,7 +46,7 @@ CFLAGS += -D_REENTRANT -D_FILE_OFFSET_BITS=64
- LIBS += -lpthread
- 
- ifdef TIRPCLIB
--CFLAGS += -I/usr/include/tirpc
-+CFLAGS += -I=/usr/include/tirpc
- LIBS += $(TIRPCLIB)
- endif
- 
-diff --git a/aclocal.m4 b/aclocal.m4
-index 2a9a802..0e4a624 100644
---- a/aclocal.m4
-+++ b/aclocal.m4
-@@ -416,7 +416,7 @@ AC_DEFUN([AF_CHECK_LIBTIRPC],
- # save current flags
- af_check_libtirpc_save_cflags="$CFLAGS"
- af_check_libtirpc_save_ldflags="$LDFLAGS"
--CFLAGS="$CFLAGS -I/usr/include/tirpc"
-+CFLAGS="$CFLAGS -I=/usr/include/tirpc"
- LDFLAGS="$LDFLAGS -ltirpc"
- 
- AC_TRY_LINK(
diff --git a/meta-openembedded/meta-networking/recipes-daemons/autofs/autofs_5.1.2.bb b/meta-openembedded/meta-networking/recipes-daemons/autofs/autofs_5.1.2.bb
deleted file mode 100644
index 68c64fd..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/autofs/autofs_5.1.2.bb
+++ /dev/null
@@ -1,77 +0,0 @@
-SUMMARY = "Kernel based automounter for linux"
-SECTION = "utils"
-LICENSE = "GPL-2.0"
-LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3"
-
-DEPENDS += "libtirpc flex-native bison-native e2fsprogs openssl libxml2 util-linux cyrus-sasl libnsl2"
-
-CFLAGS += "-I${STAGING_INCDIR}/tirpc"
-
-inherit autotools-brokensep systemd update-rc.d pkgconfig
-
-SRC_URI = "${KERNELORG_MIRROR}/linux/daemons/autofs/v5/autofs-${PV}.tar.gz \
-           file://autofs-5.0.7-include-linux-nfs.h-directly-in-rpc_sub.patch \
-           file://no-bash.patch \
-           file://cross.patch \
-           file://libtirpc.patch \
-           file://autofs-5.0.7-do-not-check-for-modprobe.patch \
-           file://fix_disable_ldap.patch \
-           file://autofs-5.0.7-fix-lib-deps.patch \
-           file://add-the-needed-stdarg.h.patch \
-           file://using-pkg-config-to-detect-libxml-2.0-and-krb5.patch \
-           file://force-STRIP-to-emtpy.patch \
-           file://remove-bashism.patch \
-           file://fix-the-YACC-rule-to-fix-a-building-failure.patch \
-           file://0001-Define-__SWORD_TYPE-and-_PATH_NSSWITCH_CONF.patch \
-           file://0002-Replace-__S_IEXEC-with-S_IEXEC.patch \
-           file://autofs-5.1.2-libtirpc-as-need.patch \
-           file://pkgconfig-libnsl.patch \
-           file://0001-modules-lookup_multi.c-Replace-__S_IEXEC-with-S_IEXE.patch \
-           "
-SRC_URI[md5sum] = "28cf88f99eff553a8500659ba5d45a76"
-SRC_URI[sha256sum] = "0d57e4138c2ec8058ca92164d035546f68ce4af93acb893369993d67c7056a10"
-
-INITSCRIPT_NAME = "autofs"
-INITSCRIPT_PARAMS = "defaults"
-
-# FIXME: modules/Makefile has crappy rules that don't obey LDFLAGS
-#CFLAGS += "${LDFLAGS}"
-
-PACKAGECONFIG[systemd] = "--with-systemd=${systemd_unitdir}/system,--without-systemd,systemd"
-
-PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
-
-EXTRA_OEMAKE = "DONTSTRIP=1"
-EXTRA_OECONF += "--disable-mount-locking \
-                --enable-ignore-busy --with-openldap=no \
-                --with-sasl=no --with-libtirpc \
-                --with-path=${STAGING_BINDIR_NATIVE} \
-"
-CACHED_CONFIGUREVARS = "ac_cv_path_RANLIB=${RANLIB} \
-                        ac_cv_path_RPCGEN=rpcgen \
-"
-
-do_configure_prepend () {
-    sed -e "s:filagdir:flagdir:" -i ${S}/configure.in
-    if [ ! -e ${S}/acinclude.m4 ]; then
-        cp ${S}/aclocal.m4 ${S}/acinclude.m4
-    fi
-}
-
-do_install_append () {
-    if [ -d ${D}/run ]; then
-        rmdir ${D}/run
-    fi
-    if [ -d ${D}${localstatedir}/run ]; then
-        rmdir ${D}${localstatedir}/run
-    fi
-}
-SECURITY_CFLAGS = "${SECURITY_NO_PIE_CFLAGS}"
-
-INSANE_SKIP_${PN} = "dev-so"
-
-RPROVIDES_${PN} += "${PN}-systemd"
-RREPLACES_${PN} += "${PN}-systemd"
-RCONFLICTS_${PN} += "${PN}-systemd"
-SYSTEMD_SERVICE_${PN} = "autofs.service"
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/autofs/autofs_5.1.4.bb b/meta-openembedded/meta-networking/recipes-daemons/autofs/autofs_5.1.4.bb
new file mode 100644
index 0000000..8a1bcad
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/autofs/autofs_5.1.4.bb
@@ -0,0 +1,80 @@
+SUMMARY = "Kernel based automounter for linux"
+SECTION = "utils"
+LICENSE = "GPL-2.0"
+LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3"
+
+DEPENDS += "libtirpc flex-native bison-native e2fsprogs openssl libxml2 util-linux cyrus-sasl libnsl2"
+
+CFLAGS += "-I${STAGING_INCDIR}/tirpc"
+
+inherit autotools-brokensep systemd update-rc.d pkgconfig
+
+SRC_URI = "${KERNELORG_MIRROR}/linux/daemons/autofs/v5/autofs-${PV}.tar.gz \
+           file://autofs-5.0.7-include-linux-nfs.h-directly-in-rpc_sub.patch \
+           file://no-bash.patch \
+           file://cross.patch \
+           file://autofs-5.0.7-do-not-check-for-modprobe.patch \
+           file://fix_disable_ldap.patch \
+           file://autofs-5.0.7-fix-lib-deps.patch \
+           file://add-the-needed-stdarg.h.patch \
+           file://using-pkg-config-to-detect-libxml-2.0-and-krb5.patch \
+           file://force-STRIP-to-emtpy.patch \
+           file://remove-bashism.patch \
+           file://fix-the-YACC-rule-to-fix-a-building-failure.patch \
+           file://0001-Define-__SWORD_TYPE-and-_PATH_NSSWITCH_CONF.patch \
+           file://0002-Replace-__S_IEXEC-with-S_IEXEC.patch \
+           file://pkgconfig-libnsl.patch \
+           file://0001-modules-lookup_multi.c-Replace-__S_IEXEC-with-S_IEXE.patch \
+           file://0001-Do-not-hardcode-path-for-pkg.m4.patch \
+           "
+SRC_URI[md5sum] = "17bc9d371cf39d99f400ebadfc2289bb"
+SRC_URI[sha256sum] = "8d1c9964c8286ccb08262ad47c60bb6343492902def5399fd36d79a0ccb0e718"
+
+UPSTREAM_CHECK_URI = "${KERNELORG_MIRROR}/linux/daemons/autofs/v5/"
+
+INITSCRIPT_NAME = "autofs"
+INITSCRIPT_PARAMS = "defaults"
+
+# FIXME: modules/Makefile has crappy rules that don't obey LDFLAGS
+#CFLAGS += "${LDFLAGS}"
+
+PACKAGECONFIG[systemd] = "--with-systemd=${systemd_unitdir}/system,--without-systemd,systemd"
+
+PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
+
+EXTRA_OEMAKE = "DONTSTRIP=1"
+EXTRA_OECONF += "--disable-mount-locking \
+                --enable-ignore-busy --with-openldap=no \
+                --with-sasl=no --with-libtirpc \
+                --with-path=${STAGING_BINDIR_NATIVE} \
+                --with-fifodir=${localstatedir}/run \
+                --with-flagdir=${localstatedir}/run \
+"
+CACHED_CONFIGUREVARS = "ac_cv_path_RANLIB=${RANLIB} \
+                        ac_cv_path_RPCGEN=rpcgen \
+"
+
+do_configure_prepend () {
+    if [ ! -e ${S}/acinclude.m4 ]; then
+        cp ${S}/aclocal.m4 ${S}/acinclude.m4
+    fi
+    cp ${STAGING_DATADIR_NATIVE}/aclocal/pkg.m4 .
+}
+
+do_install_append () {
+    if [ -d ${D}/run ]; then
+        rmdir ${D}/run
+    fi
+    if [ -d ${D}${localstatedir}/run ]; then
+        rmdir ${D}${localstatedir}/run
+    fi
+}
+SECURITY_CFLAGS = "${SECURITY_NO_PIE_CFLAGS}"
+
+INSANE_SKIP_${PN} = "dev-so"
+
+RPROVIDES_${PN} += "${PN}-systemd"
+RREPLACES_${PN} += "${PN}-systemd"
+RCONFLICTS_${PN} += "${PN}-systemd"
+SYSTEMD_SERVICE_${PN} = "autofs.service"
+
diff --git a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/0001-Allow-saslauthd-to-be-built-outside-of-source-tree-w.patch b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/0001-Allow-saslauthd-to-be-built-outside-of-source-tree-w.patch
new file mode 100644
index 0000000..c89822c
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/0001-Allow-saslauthd-to-be-built-outside-of-source-tree-w.patch
@@ -0,0 +1,41 @@
+From 6515f3e7656d97d40a6a1cf4eb3ada193a698309 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Wed, 12 Sep 2018 23:18:12 +0800
+Subject: [PATCH] Allow saslauthd to be built outside of source tree while
+ configuring with `--enable-ldapdb'
+
+[snip]
+| powerpc-wrs-linux-gcc [snip] -I../common
+|../../git/saslauthd/lak.c:58:10: fatal error: crypto-compat.h:
+No such file or directory
+[snip]
+
+The crypto-compat.h locates in git/common/, it should be                                                                                                                           |
+`-I../../git/common'
+
+Remove useless `-I$(top_srcdir)/../include' which was incorrectly
+added by commit `faae590 cleanup misc INCLUDES for different build paths'
+
+Upstream-Status: Submitted [https://github.com/cyrusimap/cyrus-sasl]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ saslauthd/Makefile.am | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/saslauthd/Makefile.am b/saslauthd/Makefile.am
+index d7244be..864b29b 100644
+--- a/saslauthd/Makefile.am
++++ b/saslauthd/Makefile.am
+@@ -34,7 +34,7 @@ saslcache_SOURCES = saslcache.c
+ 
+ EXTRA_DIST	= saslauthd.8 saslauthd.mdoc include \
+ 		  getnameinfo.c getaddrinfo.c LDAP_SASLAUTHD
+-AM_CPPFLAGS	= -I$(top_srcdir)/include -I$(top_builddir)/include -I$(top_srcdir)/../include -I$(top_builddir)/common
++AM_CPPFLAGS	= -I$(top_srcdir)/include -I$(top_builddir)/include -I$(top_builddir)/common -I$(top_srcdir)/common
+ DEFS            = @DEFS@ -DSASLAUTHD_CONF_FILE_DEFAULT=\"@sysconfdir@/saslauthd.conf\" -I. -I$(srcdir) -I..
+ 
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/0001-makeinit.sh-fix-parallel-build-issue.patch b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/0001-makeinit.sh-fix-parallel-build-issue.patch
new file mode 100644
index 0000000..bf232ac
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/0001-makeinit.sh-fix-parallel-build-issue.patch
@@ -0,0 +1,95 @@
+From bb693db0e1d1d693e8ca31fcbc4f46d1674eeca1 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 13 Sep 2018 14:20:57 +0800
+Subject: [PATCH] makeinit.sh: fix parallel build issue
+
+While building plugins, each <plugin>.c requires a <plugin>_init.c,
+and the <plugin>_init.c is dynamically generated by makeinit.sh.
+
+But the makeinit.sh generates all *_init.c (13 mechanism plugins,
+3 auxprop plugins) at one time, if there are multiple plugins,
+there will be multiple makeinit.sh invoking.
+
+It caused a parallel issue, the *_init.c files will be generated
+repeatedly.
+
+It occasionally generate dapdb_init.c incorrectly
+[snip plugins/ldapdb_init.c]
+SASL_CANONUSER_PLUG_INIT( ldapdb )
+SASL_CANONUSER_PLUG_INIT( ldapdb )
+SASL_CANONUSER_PLUG_INIT( ldapdb )
+[snip plugins/ldapdb_init.c]
+
+Let makeinit.sh generate the expected <plugin>_init.c which
+is exactly required by <plugin>.c.
+
+Upstream-Status: Submitted [https://github.com/cyrusimap/cyrus-sasl/pull/532]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ plugins/Makefile.am |  2 +-
+ plugins/makeinit.sh | 19 ++++++++++++++-----
+ 2 files changed, 15 insertions(+), 6 deletions(-)
+
+diff --git a/plugins/Makefile.am b/plugins/Makefile.am
+index 929f6a4..81e7f0b 100644
+--- a/plugins/Makefile.am
++++ b/plugins/Makefile.am
+@@ -149,4 +149,4 @@ passdss_init.c sasldb_init.c sql_init.c ldapdb_init.c
+ CLEANFILES=$(init_src)
+ 
+ ${init_src}: $(srcdir)/makeinit.sh
+-	$(SHELL) $(srcdir)/makeinit.sh
++	$(SHELL) $(srcdir)/makeinit.sh $@
+diff --git a/plugins/makeinit.sh b/plugins/makeinit.sh
+index cc65f7d..3131877 100644
+--- a/plugins/makeinit.sh
++++ b/plugins/makeinit.sh
+@@ -1,7 +1,9 @@
++plugin_init="$1"
+ # mechanism plugins
+ for mech in anonymous crammd5 digestmd5 scram gssapiv2 kerberos4 login ntlm otp passdss plain srp gs2; do
++    if [ ${plugin_init} = "${mech}_init.c" ];then
+ 
+-echo "
++        echo "
+ #include <config.h>
+ 
+ #include <string.h>
+@@ -43,13 +45,16 @@ BOOL APIENTRY DllMain( HANDLE hModule,
+ 
+ SASL_CLIENT_PLUG_INIT( $mech )
+ SASL_SERVER_PLUG_INIT( $mech )
+-" > ${mech}_init.c
++"       > ${mech}_init.c
++        echo "generating $1"
++    fi # End of `if [ ${plugin_init} = "${mech}_init.c" ];then'
+ done
+ 
+ # auxprop plugins
+ for auxprop in sasldb sql ldapdb; do
++    if [ ${plugin_init} = "${auxprop}_init.c" ];then
+ 
+-echo "
++        echo "
+ #include <config.h>
+ 
+ #include <string.h>
+@@ -86,8 +91,12 @@ BOOL APIENTRY DllMain( HANDLE hModule,
+ #endif
+ 
+ SASL_AUXPROP_PLUG_INIT( $auxprop )
+-" > ${auxprop}_init.c
++"       > ${auxprop}_init.c
++        echo "generating $1"
++    fi # End of `if [ ${plugin_init} = "${auxprop}_init.c" ];then'
+ done
+ 
+ # ldapdb is also a canon_user plugin
+-echo "SASL_CANONUSER_PLUG_INIT( ldapdb )" >> ldapdb_init.c
++if [ ${plugin_init} = "ldapdb_init.c" ];then
++    echo "SASL_CANONUSER_PLUG_INIT( ldapdb )" >> ldapdb_init.c
++fi
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/0004-configure.ac-fix-condition-for-suppliment-snprintf-i.patch b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/0004-configure.ac-fix-condition-for-suppliment-snprintf-i.patch
new file mode 100644
index 0000000..68d09c3
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/0004-configure.ac-fix-condition-for-suppliment-snprintf-i.patch
@@ -0,0 +1,28 @@
+From 98082f81da1b49876081ff1ab340e952755f985a Mon Sep 17 00:00:00 2001
+From: OBATA Akio <obache@users.noreply.github.com>
+Date: Fri, 11 May 2018 18:36:26 +0900
+Subject: [PATCH] configure.ac: fix condition for suppliment snprintf
+ implementation
+
+$sasl_cv_snprintf means requremnt of suppliment snprintf
+implementation, not existence of system snprintf implementation,
+
+Upstream-Status: Submitted [https://github.com/cyrusimap/cyrus-sasl/pull/512]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index ac59f14..9804e98 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -1264,7 +1264,7 @@ SNPRINTFOBJS=""
+ LTSNPRINTFOBJS=""
+ AC_CHECK_FUNC(snprintf, [AC_DEFINE(HAVE_SNPRINTF,[],[Does the system have snprintf()?])], [sasl_cv_snprintf=yes])
+ AC_CHECK_FUNC(vsnprintf, [AC_DEFINE(HAVE_VSNPRINTF,[],[Does the system have vsnprintf()?])], [sasl_cv_snprintf=yes])
+-if test $sasl_cv_snprintf = no; then
++if test $sasl_cv_snprintf = yes; then
+        AC_LIBOBJ(snprintf)
+        SNPRINTFOBJS="snprintf.o"
+        LTSNPRINTFOBJS="snprintf.lo"
diff --git a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/Fix-hardcoded-libdir.patch b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/Fix-hardcoded-libdir.patch
index 3fa8431..f172362 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/Fix-hardcoded-libdir.patch
+++ b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/Fix-hardcoded-libdir.patch
@@ -1,25 +1,26 @@
-Fix hardcoded libdir.
+From 188ad4497947259811ad32faeee95c20f9a44046 Mon Sep 17 00:00:00 2001
+From: "Roy.Li" <rongqing.li@windriver.com>
+Date: Fri, 19 Jul 2013 14:29:31 +0800
+Subject: [PATCH] Fix hardcoded libdir.
 
-Upstream-Status: Pending 
+Upstream-Status: Pending
 
 Signed-off-by: Roy.Li <rongqing.li@windriver.com>
+
 ---
- plugins/Makefile.am |    2 +-
- 1 files changed, 1 insertions(+), 1 deletions(-)
+ plugins/Makefile.am | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/plugins/Makefile.am b/plugins/Makefile.am
-index b00915f..25262a1 100644
+index 2b02a52..929f6a4 100644
 --- a/plugins/Makefile.am
 +++ b/plugins/Makefile.am
-@@ -62,7 +62,7 @@ plugindir = @plugindir@
+@@ -65,7 +65,7 @@ LIB_MYSQL = @LIB_MYSQL@
  
- common_sources = plugin_common.c plugin_common.h
+ plugindir = @plugindir@
  
 -sasldir = $(prefix)/lib/sasl2
 +sasldir = $(libdir)/sasl2
  sasl_LTLIBRARIES = @SASL_MECHS@
  EXTRA_LTLIBRARIES = libplain.la libanonymous.la libkerberos4.la libcrammd5.la \
  	libgs2.la libgssapiv2.la libdigestmd5.la liblogin.la libsrp.la libotp.la \
--- 
-1.7.4.1
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/avoid-to-call-AC_TRY_RUN.patch b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/avoid-to-call-AC_TRY_RUN.patch
index 6407721..aa271b8 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/avoid-to-call-AC_TRY_RUN.patch
+++ b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/avoid-to-call-AC_TRY_RUN.patch
@@ -1,4 +1,7 @@
-Avoid to call AC_TRY_RUN
+From 288430d3c2d3f36a4c9d40c4fffa85288f44549a Mon Sep 17 00:00:00 2001
+From: "Roy.Li" <rongqing.li@windriver.com>
+Date: Tue, 25 Jun 2013 09:22:59 +0800
+Subject: [PATCH] Avoid to call AC_TRY_RUN
 
 Upstream-Status: Inappropriate [configuration]
 
@@ -6,18 +9,20 @@
 on cross-compile environment by definition AC_ARG_ENABLE enable-spnego
 
 Signed-off-by: Roy.Li <rongqing.li@windriver.com>
----
- cmulocal/sasl2.m4 |   13 ++++++++++++-
- 1 file changed, 12 insertions(+), 1 deletion(-)
 
-diff --git a/cmulocal/sasl2.m4 b/cmulocal/sasl2.m4
-index 3c2841a..a5ecf81 100644
---- a/cmulocal/sasl2.m4
-+++ b/cmulocal/sasl2.m4
-@@ -281,6 +281,17 @@ if test "$gssapi" != no; then
- 
+---
+ m4/sasl2.m4 | 15 +++++++++++++--
+ 1 file changed, 13 insertions(+), 2 deletions(-)
+
+diff --git a/m4/sasl2.m4 b/m4/sasl2.m4
+index 56e0504..cf62607 100644
+--- a/m4/sasl2.m4
++++ b/m4/sasl2.m4
+@@ -314,7 +314,18 @@ if test "$gssapi" != no; then
    cmu_save_LIBS="$LIBS"
    LIBS="$LIBS $GSSAPIBASE_LIBS"
+ 
+-  AC_MSG_CHECKING([for SPNEGO support in GSSAPI libraries])
 +  AC_ARG_ENABLE([spnego],
 +              [AC_HELP_STRING([--enable-spnego=<DIR>],
 +                              [enable SPNEGO support in GSSAPI libraries [no]])],
@@ -29,10 +34,11 @@
 +  elif test "$spnego" = yes; then
 +       AC_DEFINE(HAVE_GSS_SPNEGO,,[Define if your GSSAPI implementation supports SPNEGO])
 +  else
-   AC_MSG_CHECKING([for SPNEGO support in GSSAPI libraries])
++       AC_MSG_CHECKING([for SPNEGO support in GSSAPI libraries])
    AC_TRY_RUN([
  #ifdef HAVE_GSSAPI_H
-@@ -308,7 +319,7 @@ int main(void)
+ #include <gssapi.h>
+@@ -341,7 +352,7 @@ int main(void)
  	AC_MSG_RESULT(yes) ],
  	AC_MSG_RESULT(no))
    LIBS="$cmu_save_LIBS"
@@ -41,6 +47,3 @@
  else
    AC_MSG_RESULT([disabled])
  fi
--- 
-1.7.10.4
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/debian_patches_0009_sasldb_al.diff b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/debian_patches_0009_sasldb_al.diff
deleted file mode 100644
index 8eff5a8..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/debian_patches_0009_sasldb_al.diff
+++ /dev/null
@@ -1,14 +0,0 @@
-Author: Fabian Fagerholm <fabbe@debian.org>
-Description: Fix linking with libsasldb.a when saslauthd is built with sasldb
-support.
---- a/saslauthd/configure.in
-+++ b/saslauthd/configure.in
-@@ -77,7 +77,7 @@ if test "$authsasldb" != no; then
-   AC_DEFINE(AUTH_SASLDB,[],[Include SASLdb Support])
-   SASL_DB_PATH_CHECK()
-   SASL_DB_CHECK()
--  SASL_DB_LIB="$SASL_DB_LIB ../sasldb/.libs/libsasldb.al"
-+  SASL_DB_LIB="$SASL_DB_LIB ../sasldb/.libs/libsasldb.a"
- fi
- 
- AC_ARG_ENABLE(httpform, [  --enable-httpform       enable HTTP form authentication [[no]] ],
diff --git a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/debian_patches_0014_avoid_pic_overwrite.diff b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/debian_patches_0014_avoid_pic_overwrite.diff
index 2e5b175..0479acf 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/debian_patches_0014_avoid_pic_overwrite.diff
+++ b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/debian_patches_0014_avoid_pic_overwrite.diff
@@ -1,27 +1,28 @@
-Author: Fabian Fagerholm <fabbe@debian.org>
+From 1a5f3004e9081eab6263a29cd5be792f06441e36 Mon Sep 17 00:00:00 2001
+From: Fabian Fagerholm <fabbe@debian.org>
+Date: Wed, 24 Jul 2013 11:38:25 -0400
+Subject: [PATCH] cyrus-sasl: Add patches from Debian to fix linking
+
 Description: This patch makes sure the non-PIC version of libsasldb.a, which
 is created out of non-PIC objects, is not going to overwrite the PIC version,
 which is created out of PIC objects. The PIC version is placed in .libs, and
 the non-PIC version in the current directory.  This ensures that both non-PIC
 and PIC versions are available in the correct locations.
+
+---
+ lib/Makefile.am | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/lib/Makefile.am b/lib/Makefile.am
+index a158ca3..3137e19 100644
 --- a/lib/Makefile.am
 +++ b/lib/Makefile.am
-@@ -78,7 +78,7 @@ endif
+@@ -99,7 +99,7 @@ endif
  
  libsasl2.a: libsasl2.la $(SASL_STATIC_OBJS)
  	@echo adding static plugins and dependencies
 -	$(AR) cru .libs/$@ $(SASL_STATIC_OBJS)
 +	$(AR) cru $@ $(SASL_STATIC_OBJS)
- 	@for i in ./libsasl2.la ../sasldb/libsasldb.la ../plugins/lib*.la; do \
+ 	@for i in ./libsasl2.la ../common/libplugin_common.la ../sasldb/libsasldb.la ../plugins/lib*.la; do \
  	if test ! -f $$i; then continue; fi; . $$i; \
  	for j in $$dependency_libs foo; do \
---- a/sasldb/Makefile.am
-+++ b/sasldb/Makefile.am
-@@ -63,6 +63,6 @@ libsasldb_a_SOURCES =
- EXTRA_libsasldb_a_SOURCES =
- 
- libsasldb.a: libsasldb.la $(SASL_DB_BACKEND_STATIC)
--	$(AR) cru .libs/$@ $(SASL_DB_BACKEND_STATIC)
-+	$(AR) cru $@ $(SASL_DB_BACKEND_STATIC)
- 
- 
diff --git a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/sasl.h-include-stddef.h-for-size_t-on-NetBSD.patch b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/sasl.h-include-stddef.h-for-size_t-on-NetBSD.patch
deleted file mode 100644
index ecbab84..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/sasl.h-include-stddef.h-for-size_t-on-NetBSD.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 92d72789c811b0d55f624a8bac5ccc4412f5996e Mon Sep 17 00:00:00 2001
-From: Ken Murchison <murch@andrew.cmu.edu>
-Date: Thu, 20 Dec 2012 18:14:50 -0500
-Subject: [PATCH] sasl.h: #include <stddef.h> for size_t on NetBSD
-
-This patch was imported from git://git.cyrusimap.org/cyrus-sasl
-commit 67a188693796a14e3a76ac603104807fbbfddfc4
-
-Upstream-Status: Backport
-
-Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com>
----
- include/sasl.h | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/include/sasl.h b/include/sasl.h
-index fef4d51..8b8a63f 100755
---- a/include/sasl.h
-+++ b/include/sasl.h
-@@ -121,6 +121,8 @@
- #ifndef SASL_H
- #define SASL_H 1
- 
-+#include <stddef.h>  /* For size_t */
-+
- /* Keep in sync with win32/common.mak */
- #define SASL_VERSION_MAJOR 2
- #define SASL_VERSION_MINOR 1
--- 
-1.8.3.2
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl_2.1.26.bb b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl_2.1.26.bb
deleted file mode 100644
index 6dbff87..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl_2.1.26.bb
+++ /dev/null
@@ -1,96 +0,0 @@
-SUMMARY = "Generic client/server library for SASL authentication"
-SECTION = "libs"
-HOMEPAGE = "http://asg.web.cmu.edu/sasl/"
-DEPENDS = "openssl db"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=3f55e0974e3d6db00ca6f57f2d206396"
-
-SRC_URI = "ftp://ftp.cyrusimap.org/cyrus-sasl/cyrus-sasl-${PV}.tar.gz \
-    file://avoid-to-call-AC_TRY_RUN.patch \
-    file://Fix-hardcoded-libdir.patch \
-    file://debian_patches_0009_sasldb_al.diff \
-    file://debian_patches_0014_avoid_pic_overwrite.diff \
-    file://sasl.h-include-stddef.h-for-size_t-on-NetBSD.patch \
-    file://saslauthd.service \
-    file://saslauthd.conf \
-"
-
-inherit autotools-brokensep pkgconfig useradd systemd
-
-EXTRA_OECONF += "--with-dblib=berkeley \
-                 --with-bdb-libdir=${STAGING_LIBDIR} \
-                 --with-bdb-incdir=${STAGING_INCDIR} \
-                 --with-bdb=db-5.3 \
-                 --with-plugindir="${libdir}/sasl2" \
-                 andrew_cv_runpath_switch=none"
-
-PACKAGECONFIG ??= "ntlm \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6 ldap pam', d)} \
-"
-PACKAGECONFIG[gssapi] = "--enable-gssapi=yes,--enable-gssapi=no,krb5,"
-PACKAGECONFIG[pam] = "--with-pam,--without-pam,libpam,"
-PACKAGECONFIG[opie] = "--with-opie,--without-opie,opie,"
-PACKAGECONFIG[des] = "--with-des,--without-des,,"
-PACKAGECONFIG[ldap] = "--with-ldap=${STAGING_LIBDIR} --enable-ldapdb,--without-ldap --disable-ldapdb,openldap,"
-PACKAGECONFIG[ntlm] = "--with-ntlm,--without-ntlm,,"
-PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
-
-CFLAGS += "-fPIC"
-
-do_configure_prepend () {
-    rm -f acinclude.m4 config/libtool.m4
-
-    # make it be able to work with db 5.0 version
-    local sed_files="sasldb/db_berkeley.c utils/dbconverter-2.c"
-    for sed_file in $sed_files; do
-        sed -i 's#DB_VERSION_MAJOR == 4.*#(&) || DB_VERSION_MAJOR == 5#' $sed_file
-    done
-}
-
-do_compile_prepend () {
-    cd include
-    ${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS} makemd5.c -o makemd5
-    touch makemd5.o makemd5.lo makemd5
-    cd ..
-}
-
-do_install_append() {
-    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
-        install -d ${D}${systemd_unitdir}/system
-        install -m 0644 ${WORKDIR}/saslauthd.service ${D}${systemd_unitdir}/system
-
-        sed -i -e 's#@SBINDIR@#${sbindir}#g' ${D}${systemd_unitdir}/system/saslauthd.service
-        sed -i -e 's#@LOCALSTATEDIR@#${localstatedir}#g' ${D}${systemd_unitdir}/system/saslauthd.service
-        sed -i -e 's#@SYSCONFDIR@#${sysconfdir}#g' ${D}${systemd_unitdir}/system/saslauthd.service
-
-        install -d ${D}${sysconfdir}/tmpfiles.d
-        echo "d /run/saslauthd/ - - - -" > ${D}${sysconfdir}/tmpfiles.d/saslauthd.conf
-
-        install -d ${D}${sysconfdir}/default/
-        install -m 0644 ${WORKDIR}/saslauthd.conf ${D}${sysconfdir}/default/saslauthd
-        sed -i -e 's#@LOCALSTATEDIR@#${localstatedir}#g' ${D}${sysconfdir}/default/saslauthd
-    fi
-}
-
-USERADD_PACKAGES = "${PN}-bin"
-USERADD_PARAM_${PN}-bin = "--system --home=/var/spool/mail -g mail cyrus"
-
-SYSTEMD_PACKAGES = "${PN}-bin"
-SYSTEMD_SERVICE_${PN}-bin = "saslauthd.service"
-SYSTEMD_AUTO_ENABLE = "disable"
-
-SRC_URI[md5sum] = "a7f4e5e559a0e37b3ffc438c9456e425"
-SRC_URI[sha256sum] = "8fbc5136512b59bb793657f36fadda6359cae3b08f01fd16b3d406f1345b7bc3"
-
-PACKAGES =+ "${PN}-bin"
-
-FILES_${PN}           += "${libdir}/sasl2/*.so*"
-FILES_${PN}-bin       += "${bindir} \
-                          ${sysconfdir}/default/saslauthd \
-                          ${systemd_unitdir}/system/saslauthd.service \
-                          ${sysconfdir}/tmpfiles.d/saslauthd.conf"
-FILES_${PN}-dev       += "${libdir}/sasl2/*.la"
-FILES_${PN}-dbg       += "${libdir}/sasl2/.debug"
-FILES_${PN}-staticdev += "${libdir}/sasl2/*.a"
-
-INSANE_SKIP_${PN} += "dev-so"
diff --git a/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl_2.1.27.bb b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl_2.1.27.bb
new file mode 100644
index 0000000..594e55d
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl_2.1.27.bb
@@ -0,0 +1,97 @@
+SUMMARY = "Generic client/server library for SASL authentication"
+SECTION = "libs"
+HOMEPAGE = "http://asg.web.cmu.edu/sasl/"
+DEPENDS = "openssl db groff-native"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=3f55e0974e3d6db00ca6f57f2d206396"
+
+SRCREV = "e41cfb986c1b1935770de554872247453fdbb079"
+
+SRC_URI = "git://github.com/cyrusimap/cyrus-sasl;protocol=https \
+           file://avoid-to-call-AC_TRY_RUN.patch \
+           file://Fix-hardcoded-libdir.patch \
+           file://debian_patches_0014_avoid_pic_overwrite.diff \
+           file://saslauthd.service \
+           file://saslauthd.conf \
+           file://0004-configure.ac-fix-condition-for-suppliment-snprintf-i.patch \
+           file://0001-Allow-saslauthd-to-be-built-outside-of-source-tree-w.patch \
+           file://0001-makeinit.sh-fix-parallel-build-issue.patch \
+           "
+
+UPSTREAM_CHECK_URI = "https://github.com/cyrusimap/cyrus-sasl/archives"
+
+S = "${WORKDIR}/git"
+
+inherit autotools pkgconfig useradd systemd
+
+EXTRA_OECONF += "--with-dblib=berkeley \
+                 --with-plugindir='${libdir}/sasl2' \
+                 andrew_cv_runpath_switch=none"
+
+PACKAGECONFIG ??= "ntlm \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'ldap pam', d)} \
+"
+PACKAGECONFIG[gssapi] = "--enable-gssapi=yes,--enable-gssapi=no,krb5,"
+PACKAGECONFIG[pam] = "--with-pam,--without-pam,libpam,"
+PACKAGECONFIG[opie] = "--with-opie,--without-opie,opie,"
+PACKAGECONFIG[des] = "--with-des,--without-des,,"
+PACKAGECONFIG[ldap] = "--with-ldap=${STAGING_LIBDIR} --enable-ldapdb,--without-ldap --disable-ldapdb,openldap,"
+PACKAGECONFIG[ntlm] = "--enable-ntlm=yes,--enable-ntlm=no,,"
+
+CFLAGS += "-fPIC"
+
+do_configure_prepend () {
+    # make it be able to work with db 5.0 version
+    local sed_files="sasldb/db_berkeley.c utils/dbconverter-2.c"
+    for sed_file in $sed_files; do
+        sed -i 's#DB_VERSION_MAJOR == 4.*#(&) || DB_VERSION_MAJOR == 5#' ${S}/$sed_file
+    done
+}
+
+do_compile_prepend () {
+    cd include
+    ${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS} ${S}/include/makemd5.c -o makemd5
+    touch makemd5.o makemd5.lo makemd5
+    cd ..
+}
+
+do_install_append() {
+    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
+        install -d ${D}${systemd_unitdir}/system
+        install -m 0644 ${WORKDIR}/saslauthd.service ${D}${systemd_unitdir}/system
+
+        sed -i -e 's#@SBINDIR@#${sbindir}#g' ${D}${systemd_unitdir}/system/saslauthd.service
+        sed -i -e 's#@LOCALSTATEDIR@#${localstatedir}#g' ${D}${systemd_unitdir}/system/saslauthd.service
+        sed -i -e 's#@SYSCONFDIR@#${sysconfdir}#g' ${D}${systemd_unitdir}/system/saslauthd.service
+
+        install -d ${D}${sysconfdir}/tmpfiles.d
+        echo "d /run/saslauthd/ - - - -" > ${D}${sysconfdir}/tmpfiles.d/saslauthd.conf
+
+        install -d ${D}${sysconfdir}/default/
+        install -m 0644 ${WORKDIR}/saslauthd.conf ${D}${sysconfdir}/default/saslauthd
+        sed -i -e 's#@LOCALSTATEDIR@#${localstatedir}#g' ${D}${sysconfdir}/default/saslauthd
+    fi
+}
+
+USERADD_PACKAGES = "${PN}-bin"
+USERADD_PARAM_${PN}-bin = "--system --home=/var/spool/mail -g mail cyrus"
+
+SYSTEMD_PACKAGES = "${PN}-bin"
+SYSTEMD_SERVICE_${PN}-bin = "saslauthd.service"
+SYSTEMD_AUTO_ENABLE = "disable"
+
+SRC_URI[md5sum] = "a7f4e5e559a0e37b3ffc438c9456e425"
+SRC_URI[sha256sum] = "8fbc5136512b59bb793657f36fadda6359cae3b08f01fd16b3d406f1345b7bc3"
+
+PACKAGES =+ "${PN}-bin"
+
+FILES_${PN}           += "${libdir}/sasl2/*.so*"
+FILES_${PN}-bin       += "${bindir} \
+                          ${sysconfdir}/default/saslauthd \
+                          ${systemd_unitdir}/system/saslauthd.service \
+                          ${sysconfdir}/tmpfiles.d/saslauthd.conf"
+FILES_${PN}-dev       += "${libdir}/sasl2/*.la"
+FILES_${PN}-dbg       += "${libdir}/sasl2/.debug"
+FILES_${PN}-staticdev += "${libdir}/sasl2/*.a"
+
+INSANE_SKIP_${PN} += "dev-so"
diff --git a/meta-openembedded/meta-networking/recipes-daemons/ippool/ippool/0003-musl-fixes.patch b/meta-openembedded/meta-networking/recipes-daemons/ippool/ippool/0003-musl-fixes.patch
index 3cd5259..952e4f0 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/ippool/ippool/0003-musl-fixes.patch
+++ b/meta-openembedded/meta-networking/recipes-daemons/ippool/ippool/0003-musl-fixes.patch
@@ -12,10 +12,10 @@
  4 files changed, 208 insertions(+), 6 deletions(-)
  create mode 100644 net/ppp_defs.h
 
-diff --git a/cli/cli_readline.c b/cli/cli_readline.c
-index 2812e6e..542935c 100644
---- a/cli/cli_readline.c
-+++ b/cli/cli_readline.c
+Index: ippool-1.3/cli/cli_readline.c
+===================================================================
+--- ippool-1.3.orig/cli/cli_readline.c
++++ ippool-1.3/cli/cli_readline.c
 @@ -17,13 +17,14 @@
   *  Boston, MA 02110-1301 USA
   *
@@ -33,7 +33,7 @@
  #include <signal.h>
  
  #include <readline/readline.h>
-@@ -630,7 +631,7 @@ static void cli_rl_uninstall_signal_handlers(void)
+@@ -630,7 +631,7 @@ static void cli_rl_uninstall_signal_hand
  
  static int cli_rl_install_signal_handlers(void)
  {
@@ -42,11 +42,11 @@
  
  	rl_catch_signals = 0;
  	rl_clear_signals();
-diff --git a/ippool_api.c b/ippool_api.c
-index 2c10c47..d1127a9 100644
---- a/ippool_api.c
-+++ b/ippool_api.c
-@@ -181,10 +181,13 @@ int ippool_api_rpc_check_request(SVCXPRT *xprt)
+Index: ippool-1.3/ippool_api.c
+===================================================================
+--- ippool-1.3.orig/ippool_api.c
++++ ippool-1.3/ippool_api.c
+@@ -181,10 +181,13 @@ int ippool_api_rpc_check_request(SVCXPRT
  	 * non-loopback interface, reject the request.
  	 */
  	if ((!ippool_opt_remote_rpc) &&
@@ -63,210 +63,10 @@
  		}
  		svcerr_auth(xprt, AUTH_TOOWEAK);
  		return -EPERM;
-diff --git a/net/ppp_defs.h b/net/ppp_defs.h
-new file mode 100644
-index 0000000..b06eda5
---- /dev/null
-+++ b/net/ppp_defs.h
-@@ -0,0 +1,194 @@
-+/*	$Id: ppp_defs.h,v 1.17 2002/12/06 09:49:15 paulus Exp $	*/
-+
-+/*
-+ * ppp_defs.h - PPP definitions.
-+ *
-+ * Copyright (c) 1984 Paul Mackerras. All rights reserved.
-+ *
-+ * Redistribution and use in source and binary forms, with or without
-+ * modification, are permitted provided that the following conditions
-+ * are met:
-+ *
-+ * 1. Redistributions of source code must retain the above copyright
-+ *    notice, this list of conditions and the following disclaimer.
-+ *
-+ * 2. 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.
-+ *
-+ * 3. The name(s) of the authors of this software must not be used to
-+ *    endorse or promote products derived from this software without
-+ *    prior written permission.
-+ *
-+ * 4. Redistributions of any form whatsoever must retain the following
-+ *    acknowledgment:
-+ *    "This product includes software developed by Paul Mackerras
-+ *     <paulus@samba.org>".
-+ *
-+ * THE AUTHORS OF THIS SOFTWARE DISCLAIM ALL WARRANTIES WITH REGARD TO
-+ * THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
-+ * AND FITNESS, IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY
-+ * SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
-+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
-+ * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
-+ * OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
-+ */
-+
-+#ifndef _PPP_DEFS_H_
-+#define _PPP_DEFS_H_
-+
-+/*
-+ * The basic PPP frame.
-+ */
-+#define PPP_HDRLEN	4	/* octets for standard ppp header */
-+#define PPP_FCSLEN	2	/* octets for FCS */
-+
-+/*
-+ * Packet sizes
-+ *
-+ * Note - lcp shouldn't be allowed to negotiate stuff outside these
-+ *	  limits.  See lcp.h in the pppd directory.
-+ * (XXX - these constants should simply be shared by lcp.c instead
-+ *	  of living in lcp.h)
-+ */
-+#define	PPP_MTU		1500	/* Default MTU (size of Info field) */
-+#define PPP_MAXMTU	65535 - (PPP_HDRLEN + PPP_FCSLEN)
-+#define PPP_MINMTU	64
-+#define PPP_MRU		1500	/* default MRU = max length of info field */
-+#define PPP_MAXMRU	65000	/* Largest MRU we allow */
-+#define PPP_MINMRU	128
-+
-+#define PPP_ADDRESS(p)	(((u_char *)(p))[0])
-+#define PPP_CONTROL(p)	(((u_char *)(p))[1])
-+#define PPP_PROTOCOL(p)	((((u_char *)(p))[2] << 8) + ((u_char *)(p))[3])
-+
-+/*
-+ * Significant octet values.
-+ */
-+#define	PPP_ALLSTATIONS	0xff	/* All-Stations broadcast address */
-+#define	PPP_UI		0x03	/* Unnumbered Information */
-+#define	PPP_FLAG	0x7e	/* Flag Sequence */
-+#define	PPP_ESCAPE	0x7d	/* Asynchronous Control Escape */
-+#define	PPP_TRANS	0x20	/* Asynchronous transparency modifier */
-+
-+/*
-+ * Protocol field values.
-+ */
-+#define PPP_IP		0x21	/* Internet Protocol */
-+#define PPP_AT		0x29	/* AppleTalk Protocol */
-+#define PPP_IPX		0x2b	/* IPX protocol */
-+#define	PPP_VJC_COMP	0x2d	/* VJ compressed TCP */
-+#define	PPP_VJC_UNCOMP	0x2f	/* VJ uncompressed TCP */
-+#define PPP_IPV6	0x57	/* Internet Protocol Version 6 */
-+#define PPP_COMP	0xfd	/* compressed packet */
-+#define PPP_IPCP	0x8021	/* IP Control Protocol */
-+#define PPP_ATCP	0x8029	/* AppleTalk Control Protocol */
-+#define PPP_IPXCP	0x802b	/* IPX Control Protocol */
-+#define PPP_IPV6CP	0x8057	/* IPv6 Control Protocol */
-+#define PPP_CCP		0x80fd	/* Compression Control Protocol */
-+#define PPP_ECP		0x8053	/* Encryption Control Protocol */
-+#define PPP_LCP		0xc021	/* Link Control Protocol */
-+#define PPP_PAP		0xc023	/* Password Authentication Protocol */
-+#define PPP_LQR		0xc025	/* Link Quality Report protocol */
-+#define PPP_CHAP	0xc223	/* Cryptographic Handshake Auth. Protocol */
-+#define PPP_CBCP	0xc029	/* Callback Control Protocol */
-+#define PPP_EAP		0xc227	/* Extensible Authentication Protocol */
-+
-+/*
-+ * Values for FCS calculations.
-+ */
-+#define PPP_INITFCS	0xffff	/* Initial FCS value */
-+#define PPP_GOODFCS	0xf0b8	/* Good final FCS value */
-+#define PPP_FCS(fcs, c)	(((fcs) >> 8) ^ fcstab[((fcs) ^ (c)) & 0xff])
-+
-+/*
-+ * A 32-bit unsigned integral type.
-+ */
-+
-+#if !defined(__BIT_TYPES_DEFINED__) && !defined(_BITYPES) \
-+ && !defined(__FreeBSD__) && (NS_TARGET < 40)
-+#ifdef	UINT32_T
-+typedef UINT32_T	u_int32_t;
-+#else
-+typedef unsigned int	u_int32_t;
-+typedef unsigned short  u_int16_t;
-+#endif
-+#endif
-+
-+/*
-+ * Extended asyncmap - allows any character to be escaped.
-+ */
-+typedef u_int32_t	ext_accm[8];
-+
-+/*
-+ * What to do with network protocol (NP) packets.
-+ */
-+enum NPmode {
-+    NPMODE_PASS,		/* pass the packet through */
-+    NPMODE_DROP,		/* silently drop the packet */
-+    NPMODE_ERROR,		/* return an error */
-+    NPMODE_QUEUE		/* save it up for later. */
-+};
-+
-+/*
-+ * Statistics.
-+ */
-+struct pppstat	{
-+    unsigned int ppp_ibytes;	/* bytes received */
-+    unsigned int ppp_ipackets;	/* packets received */
-+    unsigned int ppp_ierrors;	/* receive errors */
-+    unsigned int ppp_obytes;	/* bytes sent */
-+    unsigned int ppp_opackets;	/* packets sent */
-+    unsigned int ppp_oerrors;	/* transmit errors */
-+};
-+
-+struct vjstat {
-+    unsigned int vjs_packets;	/* outbound packets */
-+    unsigned int vjs_compressed; /* outbound compressed packets */
-+    unsigned int vjs_searches;	/* searches for connection state */
-+    unsigned int vjs_misses;	/* times couldn't find conn. state */
-+    unsigned int vjs_uncompressedin; /* inbound uncompressed packets */
-+    unsigned int vjs_compressedin; /* inbound compressed packets */
-+    unsigned int vjs_errorin;	/* inbound unknown type packets */
-+    unsigned int vjs_tossed;	/* inbound packets tossed because of error */
-+};
-+
-+struct ppp_stats {
-+    struct pppstat p;		/* basic PPP statistics */
-+    struct vjstat vj;		/* VJ header compression statistics */
-+};
-+
-+struct compstat {
-+    unsigned int unc_bytes;	/* total uncompressed bytes */
-+    unsigned int unc_packets;	/* total uncompressed packets */
-+    unsigned int comp_bytes;	/* compressed bytes */
-+    unsigned int comp_packets;	/* compressed packets */
-+    unsigned int inc_bytes;	/* incompressible bytes */
-+    unsigned int inc_packets;	/* incompressible packets */
-+    unsigned int ratio;		/* recent compression ratio << 8 */
-+};
-+
-+struct ppp_comp_stats {
-+    struct compstat c;		/* packet compression statistics */
-+    struct compstat d;		/* packet decompression statistics */
-+};
-+
-+/*
-+ * The following structure records the time in seconds since
-+ * the last NP packet was sent or received.
-+ */
-+struct ppp_idle {
-+    time_t xmit_idle;		/* time since last NP packet sent */
-+    time_t recv_idle;		/* time since last NP packet received */
-+};
-+
-+#ifndef __P
-+#ifdef __STDC__
-+#define __P(x)	x
-+#else
-+#define __P(x)	()
-+#endif
-+#endif
-+
-+#endif /* _PPP_DEFS_H_ */
-diff --git a/usl/usl.h b/usl/usl.h
-index cdc16db..88d2714 100644
---- a/usl/usl.h
-+++ b/usl/usl.h
+Index: ippool-1.3/usl/usl.h
+===================================================================
+--- ippool-1.3.orig/usl/usl.h
++++ ippool-1.3/usl/usl.h
 @@ -38,6 +38,10 @@
  #include "usl_fsm.h"
  #include "usl_list.h"
@@ -278,6 +78,3 @@
  #define USL_VERSION	"0.6"
  
  #ifdef DEBUG
--- 
-2.13.3
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/ippool/ippool_1.3.bb b/meta-openembedded/meta-networking/recipes-daemons/ippool/ippool_1.3.bb
index 6e47483..6fa4690 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/ippool/ippool_1.3.bb
+++ b/meta-openembedded/meta-networking/recipes-daemons/ippool/ippool_1.3.bb
@@ -24,8 +24,6 @@
            file://0001-read-returns-ssize_t.patch \
            file://0002-Mark-first-element-of-a-string-as-null.patch \
            file://0003-cli-Mark-return-of-strtol-as-long-int.patch \
-           "
-SRC_URI_append_libc-musl = "\
            file://0002-link-with-libtirpc.patch \
            file://0003-musl-fixes.patch \
            "
@@ -36,8 +34,7 @@
 
 inherit systemd
 
-DEPENDS = "readline ppp ncurses gzip-native"
-DEPENDS_append_libc-musl = " libtirpc"
+DEPENDS = "readline ppp ncurses gzip-native rpcsvc-proto-native libtirpc"
 RDEPENDS_${PN} = "rpcbind"
 
 EXTRA_OEMAKE = "CC='${CC}' AS='${AS}' LD='${LD}' AR='${AR}' NM='${NM}' STRIP='${STRIP}'"
@@ -45,8 +42,7 @@
 # enable self tests
 EXTRA_OEMAKE += "IPPOOL_TEST=y"
 
-CPPFLAGS += "${SELECTED_OPTIMIZATION}"
-CPPFLAGS_append_libc-musl = " -I${STAGING_INCDIR}/tirpc"
+CPPFLAGS += "${SELECTED_OPTIMIZATION} -I${STAGING_INCDIR}/tirpc"
 
 SYSTEMD_SERVICE_${PN} = "ippool.service"
 SYSTEMD_AUTO_ENABLE = "disable"
diff --git a/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0001-libopeniscsiusr-Include-limit.h-for-PATH_MAX.patch b/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0001-libopeniscsiusr-Include-limit.h-for-PATH_MAX.patch
deleted file mode 100644
index f5e1bec..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0001-libopeniscsiusr-Include-limit.h-for-PATH_MAX.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From cfee58d5863a535b61aa54690ae205b876f57944 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 2 Feb 2018 22:53:29 -0800
-Subject: [PATCH 1/2] libopeniscsiusr: Include limit.h for PATH_MAX
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- libopeniscsiusr/iface.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/libopeniscsiusr/iface.c b/libopeniscsiusr/iface.c
-index 79898df..a48ef36 100644
---- a/libopeniscsiusr/iface.c
-+++ b/libopeniscsiusr/iface.c
-@@ -30,6 +30,7 @@
- #include <netdb.h>
- #include <assert.h>
- #include <inttypes.h>
-+#include <limits.h>
- 
- #include "libopeniscsiusr/libopeniscsiusr.h"
- #include "misc.h"
--- 
-2.16.1
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0001-qedi.c-Removed-unused-linux-ethtool.h.patch b/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0001-qedi.c-Removed-unused-linux-ethtool.h.patch
deleted file mode 100644
index 174aa50..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0001-qedi.c-Removed-unused-linux-ethtool.h.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 197713ad7e3e944102bbd792e1ab9ec4a67100c0 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 2 Feb 2018 23:25:21 -0800
-Subject: [PATCH 1/4] qedi.c: Removed unused linux/ethtool.h
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- iscsiuio/src/unix/libs/qedi.c | 1 -
- 1 file changed, 1 deletion(-)
-
-diff --git a/iscsiuio/src/unix/libs/qedi.c b/iscsiuio/src/unix/libs/qedi.c
-index b81fecd..24cb89a 100644
---- a/iscsiuio/src/unix/libs/qedi.c
-+++ b/iscsiuio/src/unix/libs/qedi.c
-@@ -49,7 +49,6 @@
- #include <arpa/inet.h>
- #include <linux/types.h>
- #include <linux/sockios.h>
--#include <linux/ethtool.h>
- #include <linux/netlink.h>
- #include <sys/mman.h>
- #include <sys/ioctl.h>
--- 
-2.16.1
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0002-idbm.c-Include-fcnl.h-for-O_RDWR-and-O_CREAT-definit.patch b/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0002-idbm.c-Include-fcnl.h-for-O_RDWR-and-O_CREAT-definit.patch
deleted file mode 100644
index aecede6..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0002-idbm.c-Include-fcnl.h-for-O_RDWR-and-O_CREAT-definit.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 2b39f85dcf020647544002cb0b0e734748391dfb Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 2 Feb 2018 23:27:25 -0800
-Subject: [PATCH 2/4] idbm.c: Include fcnl.h for O_RDWR and O_CREAT definitions
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- usr/idbm.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/usr/idbm.c b/usr/idbm.c
-index 5532202..0a51b85 100644
---- a/usr/idbm.c
-+++ b/usr/idbm.c
-@@ -27,6 +27,7 @@
- #include <errno.h>
- #include <dirent.h>
- #include <limits.h>
-+#include <fcntl.h>
- #include <sys/stat.h>
- #include <sys/file.h>
- 
--- 
-2.16.1
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0002-libopeniscsiusr-Add-CFLAGS-to-linker-cmdline.patch b/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0002-libopeniscsiusr-Add-CFLAGS-to-linker-cmdline.patch
deleted file mode 100644
index 836ed60..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0002-libopeniscsiusr-Add-CFLAGS-to-linker-cmdline.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From 29571f71692e28ce9a17d1450097a98492f3b465 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 2 Feb 2018 22:54:04 -0800
-Subject: [PATCH 2/2] libopeniscsiusr: Add CFLAGS to linker cmdline
-
-This will ensure that -fPIC is passed to linker as
-well
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- libopeniscsiusr/Makefile | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/libopeniscsiusr/Makefile b/libopeniscsiusr/Makefile
-index 8b9b523..4f1d0d6 100644
---- a/libopeniscsiusr/Makefile
-+++ b/libopeniscsiusr/Makefile
-@@ -49,7 +49,7 @@ LIBADD =
- all: $(LIBS) $(LIBS_MAJOR) $(TESTS) doc
- 
- $(LIBS): $(OBJS)
--	$(CC) $(LDFLAGS) -shared -Wl,-soname=$@ -o $@ $(OBJS) $(LIBADD)
-+	$(CC) $(CFLAGS) $(LDFLAGS) -shared -Wl,-soname=$@ -o $@ $(OBJS) $(LIBADD)
- 	ln -sf $@ $(DEVLIB)
- 
- $(LIBS_MAJOR): $(LIBS)
--- 
-2.16.1
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0003-bnx2x.c-Reorder-the-includes-to-avoid-duplicate-defi.patch b/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0003-bnx2x.c-Reorder-the-includes-to-avoid-duplicate-defi.patch
deleted file mode 100644
index 0ce155f..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0003-bnx2x.c-Reorder-the-includes-to-avoid-duplicate-defi.patch
+++ /dev/null
@@ -1,49 +0,0 @@
-From 9b7a32903b56ce4d41f264a345ca59a0b00d53b3 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 2 Feb 2018 23:28:33 -0800
-Subject: [PATCH 3/4] bnx2x.c: Reorder the includes to avoid duplicate defines
- with musl
-
-including nic.h before linux/ethtool.h avoids redefinitions of
-eth structs
-
-/mnt/a/oe/build/tmp/work/cortexa7t2hf-neon-vfpv4-bec-linux-musleabi/iscsi-initiator-utils/2.0.876-r0/recipe-sysroot/
-usr/include/netinet/if_ether.h:104:8: error: redefinition of 'struct ethhdr'
- struct ethhdr {
-        ^~~~~~
-In file included from /mnt/a/oe/build/tmp/work/cortexa7t2hf-neon-vfpv4-bec-linux-musleabi/iscsi-initiator-utils/2.0.
-876-r0/recipe-sysroot/usr/include/linux/ethtool.h:19:0,
-                 from qedi.c:52:
-/mnt/a/oe/build/tmp/work/cortexa7t2hf-neon-vfpv4-bec-linux-musleabi/iscsi-initiator-utils/2.0.876-r0/recipe-sysroot/
-usr/include/linux/if_ether.h:154:8: note: originally defined here
- struct ethhdr {
-        ^~~~~~
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- iscsiuio/src/unix/libs/bnx2x.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/iscsiuio/src/unix/libs/bnx2x.c b/iscsiuio/src/unix/libs/bnx2x.c
-index 3df6d5f..62530d1 100644
---- a/iscsiuio/src/unix/libs/bnx2x.c
-+++ b/iscsiuio/src/unix/libs/bnx2x.c
-@@ -36,6 +36,7 @@
-  * bnx2x.c - bnx2x user space driver
-  *
-  */
-+#include "nic.h"
- #include <errno.h>
- #include <stdio.h>
- #include <string.h>
-@@ -58,7 +59,6 @@
- #include "bnx2x.h"
- #include "cnic.h"
- #include "logger.h"
--#include "nic.h"
- #include "nic_id.h"
- #include "nic_utils.h"
- #include "options.h"
--- 
-2.16.1
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0004-fwparam_ppc.c-Do-not-use-__compar_fn_t.patch b/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0004-fwparam_ppc.c-Do-not-use-__compar_fn_t.patch
deleted file mode 100644
index 57bdc8c..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/files/0004-fwparam_ppc.c-Do-not-use-__compar_fn_t.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From 6f9c1a04d250388d1574cfaf20a1ff66a64beb48 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 2 Feb 2018 23:42:12 -0800
-Subject: [PATCH 4/4] fwparam_ppc.c: Do not use __compar_fn_t
-
-__compar_fn_t is not defined in musl
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- utils/fwparam_ibft/fwparam_ppc.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/utils/fwparam_ibft/fwparam_ppc.c b/utils/fwparam_ibft/fwparam_ppc.c
-index c298b8c..391faa2 100644
---- a/utils/fwparam_ibft/fwparam_ppc.c
-+++ b/utils/fwparam_ibft/fwparam_ppc.c
-@@ -356,7 +356,7 @@ static int loop_devs(const char *devtree)
- 	 * Sort the nics into "natural" order.	The proc fs
- 	 * device-tree has them in somewhat random, or reversed order.
- 	 */
--	qsort(niclist, nic_count, sizeof(char *), (__compar_fn_t)nic_cmp);
-+	qsort(niclist, nic_count, sizeof(char *), nic_cmp);
- 
- 	snprintf(prefix, sizeof(prefix), "%s/%s", devtree, "aliases");
- 	dev_count = 0;
--- 
-2.16.1
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/iscsi-initiator-utils_2.0.876.bb b/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/iscsi-initiator-utils_2.0.876.bb
index 823227c..e6a87a3 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/iscsi-initiator-utils_2.0.876.bb
+++ b/meta-openembedded/meta-networking/recipes-daemons/iscsi-initiator-utils/iscsi-initiator-utils_2.0.876.bb
@@ -11,25 +11,21 @@
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
 
-SRCREV ?= "24580adc4c174bbc5dde3ae7594a46d57635e906"
+SRCREV ?= "bd79e4ed1004a6035d2538a308c5930890421a22"
 
 SRC_URI = "git://github.com/open-iscsi/open-iscsi \
-    file://initd.debian \
-    file://99_iscsi-initiator-utils \
-    file://iscsi-initiator \
-    file://iscsi-initiator.service \
-    file://iscsi-initiator-targets.service \
-    file://set_initiatorname \
-    file://0001-libopeniscsiusr-Include-limit.h-for-PATH_MAX.patch \
-    file://0002-libopeniscsiusr-Add-CFLAGS-to-linker-cmdline.patch \
-    file://0001-qedi.c-Removed-unused-linux-ethtool.h.patch \
-    file://0002-idbm.c-Include-fcnl.h-for-O_RDWR-and-O_CREAT-definit.patch \
-    file://0003-bnx2x.c-Reorder-the-includes-to-avoid-duplicate-defi.patch \
-    file://0004-fwparam_ppc.c-Do-not-use-__compar_fn_t.patch \
-"
+           file://initd.debian \
+           file://99_iscsi-initiator-utils \
+           file://iscsi-initiator \
+           file://iscsi-initiator.service \
+           file://iscsi-initiator-targets.service \
+           file://set_initiatorname \
+           "
 S = "${WORKDIR}/git"
 B = "${WORKDIR}/build"
 
+PV .= "+git${SRCPV}"
+
 inherit update-rc.d systemd autotools
 
 EXTRA_OECONF = " \
diff --git a/meta-openembedded/meta-networking/recipes-daemons/keepalived/keepalived_1.4.2.bb b/meta-openembedded/meta-networking/recipes-daemons/keepalived/keepalived_1.4.2.bb
index 36417b7..31c50ff 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/keepalived/keepalived_1.4.2.bb
+++ b/meta-openembedded/meta-networking/recipes-daemons/keepalived/keepalived_1.4.2.bb
@@ -16,7 +16,7 @@
 
 DEPENDS = "libnfnetlink openssl"
 
-inherit autotools pkgconfig systemd update-rc.d
+inherit autotools pkgconfig systemd
 
 PACKAGECONFIG ??= "libnl snmp \
     ${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} \
@@ -41,8 +41,5 @@
 
 FILES_${PN} += "${datadir}/snmp/mibs/KEEPALIVED-MIB.txt"
 
-INITSCRIPT_NAME = "keepalived"
-INITSCRIPT_PARAMS = "remove"
-
 SYSTEMD_SERVICE_${PN} = "keepalived.service"
 SYSTEMD_AUTO_ENABLE ?= "disable"
diff --git a/meta-openembedded/meta-networking/recipes-daemons/networkd-dispatcher/networkd-dispatcher.bb b/meta-openembedded/meta-networking/recipes-daemons/networkd-dispatcher/networkd-dispatcher.bb
new file mode 100644
index 0000000..050a938
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/networkd-dispatcher/networkd-dispatcher.bb
@@ -0,0 +1,34 @@
+python __anonymous() {
+    features = d.getVar('DISTRO_FEATURES')
+    if not features or 'systemd' not in features:
+        raise bb.parse.SkipPackage('networkd-dispatcher needs systemd in DISTRO_FEATURES')
+}
+
+SUMMARY = "Dispatcher service for systemd-networkd connection status changes"
+DESCRIPTION = "This daemon is similar to NetworkManager-dispatcher, but is much \
+more limited in the types of events it supports due to the limited nature of \
+systemd-networkd(8)."
+AUTHOR = "Clayton Craft and others"
+
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=84dcc94da3adb52b53ae4fa38fe49e5d"
+
+RDEPENDS_${PN} = "systemd python3 python3-pygobject python3-dbus"
+
+SRC_URI = "git://gitlab.com/craftyguy/networkd-dispatcher.git;protocol=https"
+SRCREV = "c7e25623a161b64618ea778541c064d2a1df086b"
+PV = "1.7+git${SRCPV}"
+
+S = "${WORKDIR}/git"
+
+# Nothing to build, just a python script to install
+do_configure[noexec] = "1"
+do_compile[noexec] = "1"
+
+do_install() {
+    install -D -m 0755 ${S}/networkd-dispatcher ${D}${sbindir}/networkd-dispatcher
+    install -D -m 0644 ${S}/networkd-dispatcher.service ${D}/${systemd_system_unitdir}/networkd-dispatcher.service
+    install -D -m 0644 ${S}/networkd-dispatcher.conf ${D}/${sysconfdir}/conf.d/networkd-dispatcher.conf
+}
+
+FILES_${PN} += "${systemd_system_unitdir}/networkd-dispatcher.service"
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-Do-not-poke-at-build-host-s-etc-os-release.patch b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-Do-not-poke-at-build-host-s-etc-os-release.patch
new file mode 100644
index 0000000..ab9b25f
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-Do-not-poke-at-build-host-s-etc-os-release.patch
@@ -0,0 +1,27 @@
+From 2bc5c6367a7f70ca5bff177ec95bcad3b1c2b66b Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 6 Sep 2018 18:15:10 -0700
+Subject: [PATCH] Do not poke at build host's /etc/os-release
+
+During cross compile we are interested in target distro and not host
+distro therefore do not check for it.
+
+Upstream-Status: Inappropriate [Cross compile specific]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+Index: openhpi-3.8.0/configure.ac
+===================================================================
+--- openhpi-3.8.0.orig/configure.ac
++++ openhpi-3.8.0/configure.ac
+@@ -194,7 +194,6 @@ AC_SUBST(JSON_C_LIB)
+ AC_SUBST(JSON_C_INCLUDE)
+ AC_CHECK_LIB([rabbitmq],[amqp_new_connection],[RABBITMQ_LIB=-lrabbitmq],[RABBITMQ_LIB=])
+ AC_SUBST(RABBITMQ_LIB)
+-AC_CHECK_FILE([/etc/os-release],[DISTRO=`grep "^ID=" /etc/os-release | awk -F"\"" '{ print $2 }'`])
+ 
+ AC_CHECK_HEADERS([amqp.h],[have_rabbitmq=yes],[have_rabbitmq=no])
+ 
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-Fix-build-failures-with-gcc7.patch b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-Fix-build-failures-with-gcc7.patch
deleted file mode 100644
index 4f493f7..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-Fix-build-failures-with-gcc7.patch
+++ /dev/null
@@ -1,49 +0,0 @@
-From 398c6db66c643ed6133cc2b028ab1e27a17c5295 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 1 May 2017 19:10:09 +0000
-Subject: [PATCH] Fix build failures with gcc7
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- plugins/ipmidirect/ipmi_mc_vendor.cpp | 2 +-
- plugins/ipmidirect/ipmi_resource.cpp  | 4 ++--
- 2 files changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/plugins/ipmidirect/ipmi_mc_vendor.cpp b/plugins/ipmidirect/ipmi_mc_vendor.cpp
-index 2c6c090..557771c 100644
---- a/plugins/ipmidirect/ipmi_mc_vendor.cpp
-+++ b/plugins/ipmidirect/ipmi_mc_vendor.cpp
-@@ -322,7 +322,7 @@ cIpmiMcVendor::CreateResources( cIpmiDomain *domain, cIpmiMc *source_mc, cIpmiSd
-       if ( addr.m_channel != source_mc->GetChannel() ) 
-           stdlog << "WARNING : SDR channel " << addr.m_channel << " NOT equal to MC channel " << source_mc->GetChannel() << "\n";
- 
--       if ( FindOrCreateResource( domain, source_mc, fru_id, sdr, sdrs ) == false ) {
-+       if ( !FindOrCreateResource( domain, source_mc, fru_id, sdr, sdrs ) ) {
- 	    return false;
- 	}
-      }
-diff --git a/plugins/ipmidirect/ipmi_resource.cpp b/plugins/ipmidirect/ipmi_resource.cpp
-index c438e74..2552673 100644
---- a/plugins/ipmidirect/ipmi_resource.cpp
-+++ b/plugins/ipmidirect/ipmi_resource.cpp
-@@ -73,7 +73,7 @@ cIpmiResource::SendCommandReadLock( const cIpmiMsg &msg, cIpmiMsg &rsp,
- 
-   domain->ReadLock();
- 
--  if ( domain->VerifyResource( resource ) == false )
-+  if ( !domain->VerifyResource( resource ) )
-        return SA_ERR_HPI_NOT_PRESENT;
- 
-   return rv;
-@@ -91,7 +91,7 @@ cIpmiResource::SendCommandReadLock( cIpmiRdr *rdr, const cIpmiMsg &msg, cIpmiMsg
-   
-   domain->ReadLock();
-   
--  if ( domain->VerifyRdr( rdr ) == false )
-+  if ( !domain->VerifyRdr( rdr ) )
-        return SA_ERR_HPI_NOT_PRESENT;
- 
-   return rv;
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-include-iostream-for-cout.patch b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-include-iostream-for-cout.patch
new file mode 100644
index 0000000..c78ec28
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-include-iostream-for-cout.patch
@@ -0,0 +1,41 @@
+From 8f47adc3b9085d589e62cb5eb560dd23a703036a Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 8 Sep 2018 12:47:49 -0700
+Subject: [PATCH] include iostream for cout
+
+End cout with endl
+
+Fixes
+plugins/dynamic_simulator/thread.cpp:241:3: error: 'cout' was not declared in this scope
+   cout<<"PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP is Defined"
+   ^~~~
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ plugins/dynamic_simulator/thread.cpp | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/plugins/dynamic_simulator/thread.cpp b/plugins/dynamic_simulator/thread.cpp
+index b971502..61eaf42 100644
+--- a/plugins/dynamic_simulator/thread.cpp
++++ b/plugins/dynamic_simulator/thread.cpp
+@@ -26,7 +26,7 @@
+  */
+ 
+ #include "thread.h"
+-#include <stdio.h>
++#include <iostream>
+ #include <sys/time.h>
+ #include <errno.h>
+ 
+@@ -238,7 +238,7 @@ cThreadLock::cThreadLock()
+   pthread_mutexattr_settype( &attr, PTHREAD_MUTEX_RECURSIVE );
+   pthread_mutex_init( &m_lock, &attr );
+   pthread_mutexattr_destroy( &attr );
+-  cout<<"PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP is Defined"
++  std::cout<<"PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP is Defined"<<std::endl;
+ }
+ #else
+ static pthread_mutex_t lock_tmpl = PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP;
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-ipmidirect-Replace-__STRING.patch b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-ipmidirect-Replace-__STRING.patch
deleted file mode 100644
index 4d56f65..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-ipmidirect-Replace-__STRING.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From be40b3f11460cf495bbbef45692e7763afda0c2b Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 14 Sep 2017 17:56:31 -0700
-Subject: [PATCH] ipmidirect: Replace __STRING
-
-__STRING is not universally available e.g.
-musl does not define it
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Pending
-
- plugins/ipmidirect/t/test.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/plugins/ipmidirect/t/test.h b/plugins/ipmidirect/t/test.h
-index 8d71381..978d5ff 100644
---- a/plugins/ipmidirect/t/test.h
-+++ b/plugins/ipmidirect/t/test.h
-@@ -22,7 +22,7 @@ TestFunction( const char *str, const char *file, int line, bool expr )
- }
- 
- 
--#define Test(expr) TestFunction( __STRING(expr), __FILE__, __LINE__, expr )
-+#define Test(expr) TestFunction( #expr, __FILE__, __LINE__, expr )
- 
- 
- static int
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-plugins-Check-for-PTHREAD_RECURSIVE_MUTEX_INITIALIZE.patch b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-plugins-Check-for-PTHREAD_RECURSIVE_MUTEX_INITIALIZE.patch
deleted file mode 100644
index 0f033ac..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-plugins-Check-for-PTHREAD_RECURSIVE_MUTEX_INITIALIZE.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From be665d9513cca7e8b64c79ae424cf44ac166b052 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 14 Sep 2017 17:07:58 -0700
-Subject: [PATCH] plugins: Check for PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP
- before use
-
-musl does not define PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP
-so we can not assume that all Linux systems support PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP
-its a glibc specific define so check for it being defined before using it
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Pending
-
- plugins/dynamic_simulator/thread.cpp | 2 +-
- plugins/ipmidirect/thread.cpp        | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/plugins/dynamic_simulator/thread.cpp b/plugins/dynamic_simulator/thread.cpp
-index d663be0..9210fd7 100644
---- a/plugins/dynamic_simulator/thread.cpp
-+++ b/plugins/dynamic_simulator/thread.cpp
-@@ -229,7 +229,7 @@ cThread::Exit( void *rv )
- /**
-  * Constructor
-  **/
--#if ( defined(__sun) && defined(__SVR4) ) || defined(__FreeBSD__)
-+#ifndef PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP
- cThreadLock::cThreadLock()
- {
-   pthread_mutexattr_t attr;
-diff --git a/plugins/ipmidirect/thread.cpp b/plugins/ipmidirect/thread.cpp
-index 5c52557..48e83fa 100644
---- a/plugins/ipmidirect/thread.cpp
-+++ b/plugins/ipmidirect/thread.cpp
-@@ -167,7 +167,7 @@ cThread::Exit( void *rv )
- //                  cThreadLock
- //////////////////////////////////////////////////
- 
--#if ( defined(__sun) && defined(__SVR4) ) || defined(__FreeBSD__)
-+#ifndef PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP
- cThreadLock::cThreadLock()
- {
-   pthread_mutexattr_t attr;
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-session-close-socket.patch b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-session-close-socket.patch
new file mode 100644
index 0000000..2cefd55
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/0001-session-close-socket.patch
@@ -0,0 +1,37 @@
+From b8bc6bfdb5e7fb5b46d3a830e04632939bee6b98 Mon Sep 17 00:00:00 2001
+From: Catalin Enache <catalin.enache@windriver.com>
+Date: Fri, 9 Feb 2018 16:35:11 +0200
+Subject: [PATCH] saHpiSessionClose: close socket
+
+saHpiSessionClose leaks file descriptors
+
+Upstream issue: https://github.com/open-hpi/openhpi/issues/1918
+
+Upstream-Status: Pending
+
+Signed-off-by: Catalin Enache <catalin.enache@windriver.com>
+Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
+---
+ baselib/session.cpp | 6 ++++++
+ 1 file changed, 6 insertions(+)
+
+diff --git a/baselib/session.cpp b/baselib/session.cpp
+index c5edfc8..4ece1b7 100644
+--- a/baselib/session.cpp
++++ b/baselib/session.cpp
+@@ -126,6 +126,12 @@ cSession::cSession()
+ 
+ cSession::~cSession()
+ {
++	cClientStreamSock * sock;
++	gpointer ptr = wrap_g_static_private_get( &m_sockets );
++	if ( ptr ) {
++	    sock = reinterpret_cast<cClientStreamSock *>(ptr);
++	    sock->Close();
++	}
+     wrap_g_static_private_free( &m_sockets );
+ }
+ 
+-- 
+2.10.2
+
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/c++11.patch b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/c++11.patch
index 0549d59..5eff86b 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/c++11.patch
+++ b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/c++11.patch
@@ -1,11 +1,21 @@
-Index: openhpi-3.6.1/configure.ac
-===================================================================
---- openhpi-3.6.1.orig/configure.ac
-+++ openhpi-3.6.1/configure.ac
-@@ -44,6 +44,7 @@ AC_PROG_CPP
- AC_PROG_INSTALL
- AC_PROG_LN_S
+From ed51168dfd6844deeaebf7d5f6c65898aafb6299 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 27 Aug 2017 12:12:04 -0700
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ configure.ac | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/configure.ac b/configure.ac
+index c29a31f..f7fe0f7 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -46,6 +46,7 @@ AC_PROG_LN_S
  AC_PROG_MAKE_SET
+ AC_PROG_AWK
+ AC_PROG_GREP
 +AX_CXX_COMPILE_STDCXX_11([noext],[mandatory])
  
  enabled_non32bit="no"
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/clang-c++11.patch b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/clang-c++11.patch
index 9b35a0c..7958a07 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/clang-c++11.patch
+++ b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/clang-c++11.patch
@@ -1,3 +1,7 @@
+Support build with Clang
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
 Index: openhpi-3.6.1/plugins/dynamic_simulator/new_sim.cpp
 ===================================================================
 --- openhpi-3.6.1.orig/plugins/dynamic_simulator/new_sim.cpp
@@ -1273,16 +1277,3 @@
  
  static SaErrorT
  IpmiResetWatchdog(void *hnd,
-Index: openhpi-3.6.1/plugins/ipmidirect/ipmi_auth.h
-===================================================================
---- openhpi-3.6.1.orig/plugins/ipmidirect/ipmi_auth.h
-+++ openhpi-3.6.1/plugins/ipmidirect/ipmi_auth.h
-@@ -32,7 +32,7 @@ class cIpmiAuthSg
- {
- public:
-   void *data; /* NULL to terminate. */
--  int   len;
-+  unsigned int   len;
- };
- 
- 
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/cross_899198.patch b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/cross_899198.patch
new file mode 100644
index 0000000..3161140
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/cross_899198.patch
@@ -0,0 +1,98 @@
+From: Helmut Grohne <helmut@subdivi.de>
+Subject: fix cross compilation
+
+The OH_SET_SIZES macro relies on the usual autoconf sizeof cache variables
+during cross compilation, but it never ensure that they are initialized.
+
+pkg-config must be called with $ac_tool_prefix and PKG_PROG_PKG_CONFIG takes
+care of that. Setting PKG_CONFIG_PATH breaks the pkg-config-cross-wrapper.
+Don't do that.
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Index: openhpi-3.8.0/acinclude.m4
+===================================================================
+--- openhpi-3.8.0.orig/acinclude.m4
++++ openhpi-3.8.0/acinclude.m4
+@@ -22,30 +22,39 @@ AC_DEFUN([OH_SET_SIZES],
+ 
+     if test "x$cross_compiling" != "xno"; then
+         if test "x$OH_SIZEOF_UCHAR" = x; then
++	    AC_CHECK_SIZEOF([unsigned char])
+             OH_SIZEOF_UCHAR=$ac_cv_sizeof_uchar
+         fi
+         if test "x$OH_SIZEOF_USHORT" = x; then
++	    AC_CHECK_SIZEOF([unsigned short])
+             OH_SIZEOF_USHORT=$ac_cv_sizeof_ushort
+         fi
+         if test "x$OH_SIZEOF_UINT" = x; then
++	    AC_CHECK_SIZEOF([unsigned int])
+             OH_SIZEOF_UINT=$ac_cv_sizeof_uint
+         fi
+         if test "x$OH_SIZEOF_CHAR" = x; then
++	    AC_CHECK_SIZEOF([char])
+             OH_SIZEOF_CHAR=$ac_cv_sizeof_char
+         fi
+         if test "x$OH_SIZEOF_SHORT" = x; then
++	    AC_CHECK_SIZEOF([short])
+             OH_SIZEOF_SHORT=$ac_cv_sizeof_short
+         fi
+         if test "x$OH_SIZEOF_INT" = x; then
++	    AC_CHECK_SIZEOF([int])
+             OH_SIZEOF_INT=$ac_cv_sizeof_int
+         fi
+         if test "x$OH_SIZEOF_LLONG" = x; then
++	    AC_CHECK_SIZEOF([long long])
+             OH_SIZEOF_LLONG=$ac_cv_sizeof_longlong
+         fi
+         if test "x$OH_SIZEOF_FLOAT" = x; then
++	    AC_CHECK_SIZEOF([float])
+             OH_SIZEOF_FLOAT=$ac_cv_sizeof_float
+         fi
+         if test "x$OH_SIZEOF_DOUBLE" = x; then
++	    AC_CHECK_SIZEOF([double])
+             OH_SIZEOF_DOUBLE=$ac_cv_sizeof_double
+         fi
+     else
+Index: openhpi-3.8.0/configure.ac
+===================================================================
+--- openhpi-3.8.0.orig/configure.ac
++++ openhpi-3.8.0/configure.ac
+@@ -87,9 +87,9 @@ have_rtas_lib=no
+ 
+ dnl Check for GLIB
+ 
+-AC_CHECK_PROG([found_pkg_config],[pkg-config],[yes])
++PKG_PROG_PKG_CONFIG
+ 
+-if test "x$found_pkg_config" != "xyes"; then
++if test "x$PKG_CONFIG" = "x"; then
+     OH_CHECK_FAIL(pkg-config,pkg-config)
+ fi
+ PKG_CFG_SETPATH
+@@ -105,7 +105,7 @@ GLIB=glib-2.0
+ GTHREAD=gthread-2.0
+ GMODULE=gmodule-2.0
+ 
+-if pkg-config --atleast-version $GLIB_REQUIRED_VERSION $GLIB; then
++if $PKG_CONFIG --atleast-version $GLIB_REQUIRED_VERSION $GLIB; then
+    :
+ else
+    AC_MSG_ERROR([
+@@ -268,12 +268,12 @@ dnl
+ dnl We really need to make ipmi enablement be contigent on OpenIPMI
+ dnl
+ 
+-if PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig pkg-config --atleast-version 1.4.20 OpenIPMI; then
++if $PKG_CONFIG --atleast-version 1.4.20 OpenIPMI; then
+     have_openipmi=yes
+     AC_CHECK_LIB([OpenIPMI], [ipmi_smi_setup_con], [have_openipmi=yes])
+-    OPENIPMI_CFLAGS=`PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig pkg-config --cflags OpenIPMI`
++    OPENIPMI_CFLAGS=`$PKG_CONFIG --cflags OpenIPMI`
+     AC_SUBST(OPENIPMI_CFLAGS)
+-    OPENIPMI_LIBS=`PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig pkg-config --libs OpenIPMI`
++    OPENIPMI_LIBS=`$PKG_CONFIG --libs OpenIPMI`
+     AC_SUBST(OPENIPMI_LIBS)
+ fi
+ 
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/no-md2.patch b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/no-md2.patch
new file mode 100644
index 0000000..c4dd23e
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/no-md2.patch
@@ -0,0 +1,37 @@
+Description: Fix FTBFS with OpenSSL 1.1 by honouring OPENSSL_NO_MD2
+Author: Adrian Bunk <bunk@debian.org>
+Bug-Debian: https://bugs.debian.org/859543
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Index: openhpi-3.8.0/plugins/ipmidirect/ipmi_auth.cpp
+===================================================================
+--- openhpi-3.8.0.orig/plugins/ipmidirect/ipmi_auth.cpp
++++ openhpi-3.8.0/plugins/ipmidirect/ipmi_auth.cpp
+@@ -21,6 +21,7 @@
+ #include "ipmi_auth.h"
+ #include <string.h>
+ #include <errno.h>
++#include <openssl/opensslconf.h>
+ 
+ 
+ cIpmiAuth *
+@@ -32,7 +33,7 @@ IpmiAuthFactory( tIpmiAuthType type )
+             return new cIpmiAuthNone;
+ 
+        case eIpmiAuthTypeMd2:
+-#ifdef HAVE_OPENSSL_MD2_H
++#if defined(HAVE_OPENSSL_MD2_H) && !defined(OPENSSL_NO_MD2)
+             return new cIpmiAuthMd2;
+ #else
+             break;
+@@ -78,7 +79,7 @@ cIpmiAuthNone::Check( cIpmiAuthSg /*d*/[
+ }
+ 
+ 
+-#ifdef HAVE_OPENSSL_MD2_H
++#if defined(HAVE_OPENSSL_MD2_H) && !defined(OPENSSL_NO_MD2)
+ #include <openssl/md2.h>
+ 
+ 
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-3.6.1-ssl.patch b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-3.6.1-ssl.patch
new file mode 100644
index 0000000..ca522bc
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-3.6.1-ssl.patch
@@ -0,0 +1,20 @@
+Link with libssl
+
+fixed build with openssl-1.1.x
+
+Taken from Fedora
+https://src.fedoraproject.org/rpms/openhpi/c/be77f5484b0206f8946a85b29424ea10bf863063
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Unknown
+
+diff -up openhpi-3.6.1/ssl/Makefile.am.than openhpi-3.6.1/ssl/Makefile.am
+--- openhpi-3.6.1/ssl/Makefile.am.than	2017-02-21 12:21:12.114814698 -0500
++++ openhpi-3.6.1/ssl/Makefile.am	2017-02-21 12:22:44.576454262 -0500
+@@ -19,5 +19,5 @@ lib_LTLIBRARIES		= libopenhpi_ssl.la
+ libopenhpi_ssl_la_SOURCES = oh_ssl.c oh_ssl.h
+ 
+ libopenhpi_ssl_la_LDFLAGS = -version-info @HPI_LIB_VERSION@
+-libopenhpi_ssl_la_LIBADD  = @CRYPTO_LIB@
++libopenhpi_ssl_la_LIBADD  = -lssl @CRYPTO_LIB@
+ 
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-hpi-shell-thread-fix.patch b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-hpi-shell-thread-fix.patch
deleted file mode 100644
index cc21ff8..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-hpi-shell-thread-fix.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-commit e9f9a73c9dba8dd59f3d6c3acd9988ec8361d55a
-Author: Aws Ismail <aws.ismail@windriver.com>
-Date:   Mon Dec 17 16:23:45 2012 -0500
-
-    Correct dangling g_thread_exit in session.c
-    
-    hpi_shell's session.c has its progress_bar
-    thread created using pthread_create but
-    exited using g_thread_exit. Use pthread_exit
-    instead to avoid unpredictable GLIB thread
-    errors.
-    
-    Upstream-Status: Pending
-    
-    Signed-off-by: Aws Ismail <aws.ismail@windriver.com>
-
-Index: openhpi-3.6.1/hpi_shell/session.c
-===================================================================
---- openhpi-3.6.1.orig/hpi_shell/session.c
-+++ openhpi-3.6.1/hpi_shell/session.c
-@@ -73,7 +73,7 @@ static void* progress_bar(void *unused)
- 		if (i < (PROGRESS_BUF_SIZE - mes_len - 1)) i++;
- 		t++;
- 	};
--        g_thread_exit(0);
-+        pthread_exit(0);
- 	return (void *)1;
- }
- 
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-libxml2-cross-compile.patch b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-libxml2-cross-compile.patch
index c848b35..160eeed 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-libxml2-cross-compile.patch
+++ b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-libxml2-cross-compile.patch
@@ -1,4 +1,7 @@
-Fix libxml2 for cross-compiling
+From afe545e77f9d841b7777d859e7e8108492fece96 Mon Sep 17 00:00:00 2001
+From: Jackie Huang <jackie.huang@windriver.com>
+Date: Wed, 26 Apr 2017 16:22:00 +0800
+Subject: [PATCH] Fix libxml2 for cross-compiling
 
 Use proper XML2_INCLUDE path when cross-compiling
 
@@ -6,16 +9,20 @@
 
 Signed-of-by: Aws Ismail <aws.ismail@windriver.com>
 
-Index: openhpi-3.6.1/configure.ac
-===================================================================
---- openhpi-3.6.1.orig/configure.ac
-+++ openhpi-3.6.1/configure.ac
-@@ -177,7 +177,7 @@ AC_CHECK_HEADERS([openssl/md2.h openssl/
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index 6242cbf..4fb6b69 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -179,7 +179,7 @@ AC_CHECK_HEADERS([openssl/md2.h openssl/md5.h openssl/bio.h openssl/ssl.h openss
  
  dnl xml is used for XML-based communication in ilo2_ribcl and oa_soap
  AC_CHECK_LIB([xml2],[xmlParseMemory],[XML2_LIB=-lxml2],[XML2_LIB=])
--AC_CHECK_HEADERS([libxml2/libxml/xmlexports.h],[XML2_INCLUDE="-I/usr/include/libxml2"],[XML2_INCLUDE])
-+AC_CHECK_HEADERS([libxml2/libxml/xmlexports.h],[XML2_INCLUDE="$XML2_INCLUDE"],[XML2_INCLUDE])
+-AC_CHECK_HEADERS([libxml2/libxml/xmlexports.h],[XML2_INCLUDE="-I/usr/include/libxml2"],[XML2_INCLUDE=])
++AC_CHECK_HEADERS([libxml2/libxml/xmlexports.h],[XML2_INCLUDE="$XML2_INCLUDE"],[XML2_INCLUDE=])
  AC_SUBST(XML2_LIB)
  AC_SUBST(XML2_INCLUDE)
  
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-netsnmp-cross-compile.patch b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-netsnmp-cross-compile.patch
index 95b0abc..293c8d9 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-netsnmp-cross-compile.patch
+++ b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-netsnmp-cross-compile.patch
@@ -13,36 +13,33 @@
  configure    | 4 ++--
  2 files changed, 4 insertions(+), 4 deletions(-)
 
-diff --git a/acinclude.m4 b/acinclude.m4
-index 82c33f6..727e461 100644
---- a/acinclude.m4
-+++ b/acinclude.m4
+Index: openhpi-3.8.0/acinclude.m4
+===================================================================
+--- openhpi-3.8.0.orig/acinclude.m4
++++ openhpi-3.8.0/acinclude.m4
 @@ -160,8 +160,8 @@ AC_DEFUN([OH_CHECK_NETSNMP],
      ],
      [
          have_netsnmp=yes
--        SNMPFLAGS=`${net_snmp_config:-net-snmp-config} --cflags | perl -p -e 's/-O\S*//g'`
+-        SNMPFLAGS=`${net_snmp_config:-net-snmp-config} --cflags | perl -p -e 's/ -O\S*//g'`
 -        SNMPLIBS=`${net_snmp_config:-net-snmp-config} --libs`
 +        SNMPFLAGS=""
 +        SNMPLIBS=""
          AC_MSG_RESULT(yes)
      ],
      [AC_MSG_RESULT(no.  No SNMP based plugins can be built!)])
-diff --git a/configure b/configure
-index 00067bc..36b913c 100755
---- a/configure
-+++ b/configure
-@@ -15949,8 +15949,8 @@ _ACEOF
+Index: openhpi-3.8.0/configure
+===================================================================
+--- openhpi-3.8.0.orig/configure
++++ openhpi-3.8.0/configure
+@@ -16062,8 +16062,8 @@ _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
          have_netsnmp=yes
--        SNMPFLAGS=`${net_snmp_config:-net-snmp-config} --cflags | perl -p -e 's/-O\S*//g'`
+-        SNMPFLAGS=`${net_snmp_config:-net-snmp-config} --cflags | perl -p -e 's/ -O\S*//g'`
 -        SNMPLIBS=`${net_snmp_config:-net-snmp-config} --libs`
 +        SNMPFLAGS=""
 +        SNMPLIBS=""
          { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  $as_echo "yes" >&6; }
  
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-use-serial-tests-config-needed-by-ptest.patch b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-use-serial-tests-config-needed-by-ptest.patch
index 3e09180..472318b 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-use-serial-tests-config-needed-by-ptest.patch
+++ b/meta-openembedded/meta-networking/recipes-daemons/openhpi/files/openhpi-use-serial-tests-config-needed-by-ptest.patch
@@ -1,4 +1,4 @@
-From 36fbaa27e7299f63c1324b0ad22b970e9365d6a7 Mon Sep 17 00:00:00 2001
+From 5e0ae172586f5aeb270a8f9b012dd3e36536a2a9 Mon Sep 17 00:00:00 2001
 From: Jackie Huang <jackie.huang@windriver.com>
 Date: Wed, 24 Dec 2014 10:54:59 +0800
 Subject: [PATCH] openhpi: use serial-tests config needed by ptest
@@ -9,17 +9,18 @@
 Upstream-Status: Inappropriate [default automake behavior incompatible with ptest]
 
 Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
----
- configure.ac |    2 +-
- 1 files changed, 1 insertions(+), 1 deletions(-)
 
-Index: openhpi-3.6.1/configure.ac
-===================================================================
---- openhpi-3.6.1.orig/configure.ac
-+++ openhpi-3.6.1/configure.ac
-@@ -7,7 +7,7 @@ dnl   various hacks by Sean Dague <http:
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index 89d8104..c29a31f 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -7,7 +7,7 @@ dnl   various hacks by Sean Dague <http://dague.net/sean> 4/23/03
  AC_PREREQ(2.57)
- AC_INIT(openhpi, 3.6.1)
+ AC_INIT(openhpi, 3.8.0)
  AC_CONFIG_SRCDIR(openhpi.spec.in)
 -AM_INIT_AUTOMAKE([1.8])
 +AM_INIT_AUTOMAKE([1.8 serial-tests])
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/openhpi_3.6.1.bb b/meta-openembedded/meta-networking/recipes-daemons/openhpi/openhpi_3.6.1.bb
deleted file mode 100644
index ecf71d7..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/openhpi/openhpi_3.6.1.bb
+++ /dev/null
@@ -1,115 +0,0 @@
-SUMMARY = "Hardware Platform Interface Library and Tools"
-
-DESCRIPTION = "\
-OpenHPI is an open source project created with the intent of providing an \
-implementation of the SA Forum's Hardware Platform Interface (HPI). HPI \
-provides an abstracted interface to managing computer hardware, typically for \
-chassis and rack based servers. HPI includes resource modeling; access to and \
-control over sensor, control, watchdog, and inventory data associated with \
-resources; abstracted System Event Log interfaces; hardware events and alerts; \
-and a managed hotswap interface. \
-\
-OpenHPI provides a modular mechanism for adding new hardware and device support \
-easily. Many plugins exist in the OpenHPI source tree to provide access to \
-various types of hardware. This includes, but is not limited to, IPMI based \
-servers, Blade Center, and machines which export data via sysfs. \
-"
-
-HOMEPAGE = "http://openhpi.sourceforge.net/Home"
-SECTION = "net"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=e3c772a32386888ccb5ae1c0ba95f1a4"
-
-DEPENDS = "net-snmp libxml2 ncurses openssl glib-2.0 popt e2fsprogs autoconf-archive-native"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BP}.tar.gz \
-           file://openhpi.init \
-           file://openhpid.service \
-           file://run-ptest \
-           file://openhpi-netsnmp-cross-compile.patch \
-           file://openhpi-sysfs-cross-compile.patch \
-           file://openhpi-libxml2-cross-compile.patch \
-           file://openhpi-glib-cross-compile.patch \
-           file://openhpi-linkfix.patch \
-           file://openhpi-fix-host-gcc.patch \
-           file://openhpi-hpi-shell-thread-fix.patch \
-           file://openhpi-fix-testfail-errors.patch \
-           file://openhpi-add-libnetsnmp-when-link.patch \
-           file://openhpi-invalide-session.patch \
-           file://openhpi-use-serial-tests-config-needed-by-ptest.patch \
-           file://openhpi-fix-alignment-issue.patch \
-           file://0001-Fix-build-failures-with-gcc7.patch \
-           file://c++11.patch \
-           file://clang-c++11.patch \
-           file://fix-narrowing-warning.patch \
-           file://0001-plugins-Check-for-PTHREAD_RECURSIVE_MUTEX_INITIALIZE.patch \
-           file://0001-ipmidirect-Replace-__STRING.patch \
-           "
-
-SRC_URI[md5sum] = "4718b16e0f749b5ad214a9b04f45dd23"
-SRC_URI[sha256sum] = "e0a810cb401c4bdcfc9551f2e6afd5a8ca4b411f5ee3bc60c19f82fd6e84a3dc"
-
-inherit autotools pkgconfig ptest update-rc.d systemd
-
-PACKAGES =+ "${PN}-libs"
-
-FILES_${PN}-libs = "${libdir}/${BPN}/*.so /usr/lib/${BPN}/*.so"
-
-INSANE_SKIP_${PN}-libs = "dev-so"
-RDEPENDS_${PN} += "${PN}-libs"
-
-PACKAGECONFIG ??= "libgcrypt non32bit"
-PACKAGECONFIG[sysfs] = "--enable-sysfs,--disable-sysfs,sysfsutils,"
-PACKAGECONFIG[libgcrypt] = "--enable-encryption,--disable-encryption,libgcrypt,"
-PACKAGECONFIG[non32bit] = "--enable-non32bit-int,--disable-non32bit-int,,"
-
-do_install_append () {
-    install -m 0755 -d ${D}${sysconfdir}/${BPN}
-    install -m 0755 ${S}/openhpiclient.conf.example ${D}${sysconfdir}/${BPN}/openhpiclient.conf
-    install -m 0700 ${S}/openhpi.conf.example ${D}${sysconfdir}/${BPN}/openhpi.conf
-    install -m 0755 ${S}/simulation.data.example ${D}${sysconfdir}/${BPN}/simulation.data
-    install -m 0755 ${S}/test_agent.data.example ${D}${sysconfdir}/${BPN}/test_agent.data
-    install -m 0755 ${WORKDIR}/openhpi.init ${D}${sysconfdir}/init.d/openhpid
-
-    install -d ${D}${systemd_unitdir}/system
-    install -m 0644 ${WORKDIR}/openhpid.service ${D}${systemd_unitdir}/system
-    sed -i -e "s,@SBINDIR@,${sbindir},g" -e "s,@SYSCONFDIR@,${sysconfdir},g" \
-        ${D}${systemd_unitdir}/system/openhpid.service
-}
-
-do_compile_ptest () {
-    for x in `find ${B} -name Makefile -exec grep -l buildtest-TESTS {} \;`; do
-        dir=`dirname ${x}`
-        upper=`dirname ${dir}`
-        if [ `basename ${upper}` != "cpp" ]; then
-            oe_runmake -C ${dir} buildtest-TESTS
-        fi
-    done
-}
-
-do_install_ptest () {
-    cp -rf ${B}/openhpid/t/ohpi/.libs/* ${B}/openhpid/t/ohpi/
-    TESTS="utils marshal openhpid"
-    for subtest in ${TESTS}; do
-        mkdir -p ${D}${PTEST_PATH}/${subtest}/t
-        cp -rf ${B}/${subtest}/t/* ${D}${PTEST_PATH}/${subtest}/t
-    done
-
-    for x in `find ${D}${PTEST_PATH} -name Makefile`; do
-        sed -i "s:${S}:${PTEST_PATH}/:g" ${x};
-        sed -i "s/^Makefile:/MM:/g" ${x};
-    done;
-
-    mkdir -p ${D}${PTEST_PATH}/plugins/watchdog/
-    cp -L ${D}/${libdir}/${BPN}/libwatchdog.so ${D}${PTEST_PATH}/plugins/watchdog/
-    cp -L ${D}/${libdir}/${BPN}/libsimulator.so ${D}${PTEST_PATH}/plugins/watchdog/
-    find ${D}${PTEST_PATH}/ -name "*.c" -exec rm {} \;
-    find ${D}${PTEST_PATH}/ -name "*.o" -exec rm {} \;
-    find ${D}${PTEST_PATH}/ -name "*.h" -exec rm {} \;
-}
-
-INITSCRIPT_NAME = "openhpid"
-INITSCRIPT_PARAMS = "start 30 . stop 70 0 1 2 3 4 5 6 ."
-
-SYSTEMD_SERVICE_${PN} = "openhpid.service"
-SYSTEMD_AUTO_ENABLE = "disable"
diff --git a/meta-openembedded/meta-networking/recipes-daemons/openhpi/openhpi_3.8.0.bb b/meta-openembedded/meta-networking/recipes-daemons/openhpi/openhpi_3.8.0.bb
new file mode 100644
index 0000000..c4b3309
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/openhpi/openhpi_3.8.0.bb
@@ -0,0 +1,119 @@
+SUMMARY = "Hardware Platform Interface Library and Tools"
+
+DESCRIPTION = "\
+OpenHPI is an open source project created with the intent of providing an \
+implementation of the SA Forum's Hardware Platform Interface (HPI). HPI \
+provides an abstracted interface to managing computer hardware, typically for \
+chassis and rack based servers. HPI includes resource modeling; access to and \
+control over sensor, control, watchdog, and inventory data associated with \
+resources; abstracted System Event Log interfaces; hardware events and alerts; \
+and a managed hotswap interface. \
+\
+OpenHPI provides a modular mechanism for adding new hardware and device support \
+easily. Many plugins exist in the OpenHPI source tree to provide access to \
+various types of hardware. This includes, but is not limited to, IPMI based \
+servers, Blade Center, and machines which export data via sysfs. \
+"
+
+HOMEPAGE = "http://openhpi.sourceforge.net/Home"
+SECTION = "net"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=e3c772a32386888ccb5ae1c0ba95f1a4"
+
+DEPENDS = "net-snmp libxml2 ncurses openssl glib-2.0 popt e2fsprogs \
+           autoconf-archive-native os-release"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BP}.tar.gz \
+           file://openhpi.init \
+           file://openhpid.service \
+           file://run-ptest \
+           file://openhpi-netsnmp-cross-compile.patch \
+           file://openhpi-sysfs-cross-compile.patch \
+           file://openhpi-libxml2-cross-compile.patch \
+           file://openhpi-glib-cross-compile.patch \
+           file://openhpi-linkfix.patch \
+           file://openhpi-fix-host-gcc.patch \
+           file://openhpi-fix-testfail-errors.patch \
+           file://openhpi-add-libnetsnmp-when-link.patch \
+           file://openhpi-invalide-session.patch \
+           file://openhpi-use-serial-tests-config-needed-by-ptest.patch \
+           file://openhpi-fix-alignment-issue.patch \
+           file://c++11.patch \
+           file://clang-c++11.patch \
+           file://fix-narrowing-warning.patch \
+           file://0001-session-close-socket.patch \
+           file://openhpi-3.6.1-ssl.patch \
+           file://0001-Do-not-poke-at-build-host-s-etc-os-release.patch \
+           file://cross_899198.patch \
+           file://no-md2.patch \
+           file://0001-include-iostream-for-cout.patch \
+           "
+SRC_URI[md5sum] = "fffda3deea8a0d3671a72eea9d13a4df"
+SRC_URI[sha256sum] = "c94332a29160dd75cb799c027e614690c00263b0fabed87417707bec04c38723"
+
+inherit autotools pkgconfig ptest update-rc.d systemd
+
+PACKAGES =+ "${PN}-libs"
+
+FILES_${PN}-libs = "${libdir}/${BPN}/*.so /usr/lib/${BPN}/*.so"
+
+INSANE_SKIP_${PN}-libs = "dev-so"
+RDEPENDS_${PN} += "${PN}-libs"
+
+PACKAGECONFIG ??= "libgcrypt non32bit"
+PACKAGECONFIG[sysfs] = "--enable-sysfs,--disable-sysfs,sysfsutils,"
+PACKAGECONFIG[libgcrypt] = "--enable-encryption,--disable-encryption,libgcrypt,"
+PACKAGECONFIG[non32bit] = "--enable-non32bit-int,--disable-non32bit-int,,"
+
+export DISTRO
+
+do_install_append () {
+    install -m 0755 -d ${D}${sysconfdir}/${BPN}
+    install -m 0755 ${S}/openhpiclient.conf.example ${D}${sysconfdir}/${BPN}/openhpiclient.conf
+    install -m 0700 ${S}/openhpi.conf.example ${D}${sysconfdir}/${BPN}/openhpi.conf
+    install -m 0755 ${S}/simulation.data.example ${D}${sysconfdir}/${BPN}/simulation.data
+    install -m 0755 ${S}/test_agent.data.example ${D}${sysconfdir}/${BPN}/test_agent.data
+    install -m 0755 ${WORKDIR}/openhpi.init ${D}${sysconfdir}/init.d/openhpid
+
+    install -d ${D}${systemd_unitdir}/system
+    install -m 0644 ${WORKDIR}/openhpid.service ${D}${systemd_unitdir}/system
+    sed -i -e "s,@SBINDIR@,${sbindir},g" -e "s,@SYSCONFDIR@,${sysconfdir},g" \
+        ${D}${systemd_unitdir}/system/openhpid.service
+}
+
+do_compile_ptest () {
+    for x in `find ${B} -name Makefile -exec grep -l buildtest-TESTS {} \;`; do
+        dir=`dirname ${x}`
+        upper=`dirname ${dir}`
+        if [ `basename ${upper}` != "cpp" ]; then
+            oe_runmake -C ${dir} buildtest-TESTS
+        fi
+    done
+}
+
+do_install_ptest () {
+    cp -rf ${B}/openhpid/t/ohpi/.libs/* ${B}/openhpid/t/ohpi/
+    TESTS="utils marshal openhpid"
+    for subtest in ${TESTS}; do
+        mkdir -p ${D}${PTEST_PATH}/${subtest}/t
+        cp -rf ${B}/${subtest}/t/* ${D}${PTEST_PATH}/${subtest}/t
+    done
+
+    for x in `find ${D}${PTEST_PATH} -name Makefile`; do
+        sed -i "s:${S}:${PTEST_PATH}/:g" ${x};
+        sed -i "s/^Makefile:/MM:/g" ${x};
+    done;
+
+    mkdir -p ${D}${PTEST_PATH}/plugins/watchdog/
+    cp -L ${D}/${libdir}/${BPN}/libwatchdog.so ${D}${PTEST_PATH}/plugins/watchdog/
+    cp -L ${D}/${libdir}/${BPN}/libsimulator.so ${D}${PTEST_PATH}/plugins/watchdog/
+    find ${D}${PTEST_PATH}/ -name "*.c" -exec rm {} \;
+    find ${D}${PTEST_PATH}/ -name "*.o" -exec rm {} \;
+    find ${D}${PTEST_PATH}/ -name "*.h" -exec rm {} \;
+}
+
+INITSCRIPT_NAME = "openhpid"
+INITSCRIPT_PARAMS = "start 30 . stop 70 0 1 2 3 4 5 6 ."
+
+SYSTEMD_SERVICE_${PN} = "openhpid.service"
+SYSTEMD_AUTO_ENABLE = "disable"
diff --git a/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-Catch-std-ifstream-failure-by-reference.patch b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-Catch-std-ifstream-failure-by-reference.patch
new file mode 100644
index 0000000..30fdb8b
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-Catch-std-ifstream-failure-by-reference.patch
@@ -0,0 +1,67 @@
+From 38c5343f84799fc5041575f3ec808f7476b6eea3 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 16 Apr 2018 14:33:35 -0700
+Subject: [PATCH] Catch std::ifstream::failure by reference
+
+Fixes
+error: catching polymorphic type 'class std::ios_base::failure' by value
+[-Werror=catch-value=]
+   } catch (std::ofstream::failure) {
+                           ^~~~~~~
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+---
+ src/base/conf.cc           | 4 ++--
+ src/dtm/dtmnd/dtm_main.cc  | 2 +-
+ src/dtm/dtmnd/multicast.cc | 2 +-
+ 3 files changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/src/base/conf.cc b/src/base/conf.cc
+index d5755a1..4820357 100644
+--- a/src/base/conf.cc
++++ b/src/base/conf.cc
+@@ -189,7 +189,7 @@ std::string Conf::ReadFile(const std::string& path_name,
+   try {
+     str.open(path_name);
+     str >> contents;
+-  } catch (std::ifstream::failure) {
++  } catch (std::ifstream::failure& e) {
+     contents.clear();
+   }
+   return (str.fail() || contents.empty()) ? default_contents : contents;
+@@ -203,7 +203,7 @@ void Conf::WriteFileAtomically(const std::string& path_name,
+   try {
+     str.open(tmp_file, std::ofstream::out | std::ofstream::trunc);
+     str << contents << std::endl;
+-  } catch (std::ofstream::failure) {
++  } catch (std::ofstream::failure& e) {
+     success = false;
+   }
+   str.close();
+diff --git a/src/dtm/dtmnd/dtm_main.cc b/src/dtm/dtmnd/dtm_main.cc
+index 585e11e..5cf6ad7 100644
+--- a/src/dtm/dtmnd/dtm_main.cc
++++ b/src/dtm/dtmnd/dtm_main.cc
+@@ -367,7 +367,7 @@ void UpdateNodeIdFile(DTM_INTERNODE_CB *cb) {
+       try {
+         str.open(PKGLOCALSTATEDIR "/node_id", std::ofstream::out);
+         str << std::hex << node_id << std::endl;
+-      } catch (std::ofstream::failure) {
++      } catch (std::ofstream::failure& e) {
+       }
+       str.close();
+     }
+diff --git a/src/dtm/dtmnd/multicast.cc b/src/dtm/dtmnd/multicast.cc
+index cadc002..7c25fea 100644
+--- a/src/dtm/dtmnd/multicast.cc
++++ b/src/dtm/dtmnd/multicast.cc
+@@ -199,7 +199,7 @@ bool Multicast::GetPeersFromFile(const std::string &path_name) {
+         }
+       }
+     }
+-  } catch (std::ifstream::failure) {
++  } catch (std::ifstream::failure& e) {
+     LOG_ER("Caught std::ifstream::failure when reading file '%s', peers=%zu",
+            path_name.c_str(), static_cast<size_t>(peers_.size()));
+     peers_.clear();
diff --git a/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-Fix-string-overflow-in-snprintf.patch b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-Fix-string-overflow-in-snprintf.patch
new file mode 100644
index 0000000..db6796d
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-Fix-string-overflow-in-snprintf.patch
@@ -0,0 +1,76 @@
+From ae7178a78aba2e5766b70191617113487fd7ad0b Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 16 Apr 2018 18:29:17 -0700
+Subject: [PATCH] Fix string overflow in snprintf
+
+Fixes errors like
+error: '%s' dir
+ective output may be truncated writing up to 255 bytes into a region of size 32 [-Werror=forma
+t-truncation=]
+   snprintf(reinterpret_cast<char *>(Healthy.key), sizeof(Healthy.key), "%s",
+                                                                        ^~~~
+            hlth_str);
+            ~~~~~~~~
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+---
+ src/log/logd/lgs_util.cc           | 4 ++--
+ src/rde/rded/rde_amf.cc            | 2 +-
+ src/smf/smfd/SmfUpgradeCampaign.cc | 4 ++--
+ 3 files changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/src/log/logd/lgs_util.cc b/src/log/logd/lgs_util.cc
+index ac93d5a..cce80f3 100644
+--- a/src/log/logd/lgs_util.cc
++++ b/src/log/logd/lgs_util.cc
+@@ -200,12 +200,12 @@ char *lgs_get_time(time_t *time_in) {
+ 
+   stringSize = 5 * sizeof(char);
+   snprintf(srcString, (size_t)stringSize, "%d",
+-           (timeStampData->tm_year + START_YEAR));
++           (timeStampData->tm_year + START_YEAR) & 0x4dU);
+ 
+   strncpy(timeStampString, srcString, stringSize);
+ 
+   stringSize = 3 * sizeof(char);
+-  snprintf(srcString, (size_t)stringSize, "%02d", (timeStampData->tm_mon + 1));
++  snprintf(srcString, (size_t)stringSize, "%02d", (timeStampData->tm_mon + 1) & 0x2dU);
+ 
+   strncat(timeStampString, srcString, stringSize);
+ 
+diff --git a/src/rde/rded/rde_amf.cc b/src/rde/rded/rde_amf.cc
+index 81e521e..d53cc48 100644
+--- a/src/rde/rded/rde_amf.cc
++++ b/src/rde/rded/rde_amf.cc
+@@ -102,7 +102,7 @@ static uint32_t rde_amf_healthcheck_start(RDE_AMF_CB *rde_amf_cb) {
+   SaAmfHealthcheckKeyT Healthy;
+   SaNameT SaCompName;
+   char *phlth_ptr;
+-  char hlth_str[256];
++  char hlth_str[32];
+ 
+   TRACE_ENTER();
+ 
+diff --git a/src/smf/smfd/SmfUpgradeCampaign.cc b/src/smf/smfd/SmfUpgradeCampaign.cc
+index 45cdce8..6761bcf 100644
+--- a/src/smf/smfd/SmfUpgradeCampaign.cc
++++ b/src/smf/smfd/SmfUpgradeCampaign.cc
+@@ -447,7 +447,7 @@ SaAisErrorT SmfUpgradeCampaign::tooManyRestarts(bool *o_result) {
+   TRACE_ENTER();
+   SaAisErrorT rc = SA_AIS_OK;
+   SaImmAttrValuesT_2 **attributes;
+-  int curCnt = 0;
++  short int curCnt = 0;
+ 
+   /* Read the SmfCampRestartInfo object smfCampRestartCnt attr */
+   std::string obj = "smfRestartInfo=info," +
+@@ -473,7 +473,7 @@ SaAisErrorT SmfUpgradeCampaign::tooManyRestarts(bool *o_result) {
+     attrsmfCampRestartCnt.setName("smfCampRestartCnt");
+     attrsmfCampRestartCnt.setType("SA_IMM_ATTR_SAUINT32T");
+     char buf[5];
+-    snprintf(buf, 4, "%d", curCnt);
++    snprintf(buf, 4, "%hd", curCnt);
+     attrsmfCampRestartCnt.addValue(buf);
+     imoCampRestartInfo.addValue(attrsmfCampRestartCnt);
+ 
diff --git a/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-configure-Disable-format-overflow-if-supported-by-gc.patch b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-configure-Disable-format-overflow-if-supported-by-gc.patch
index effe25c..be0a587 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-configure-Disable-format-overflow-if-supported-by-gc.patch
+++ b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-configure-Disable-format-overflow-if-supported-by-gc.patch
@@ -1,20 +1,21 @@
-From ab00d6f5793b2d850f975bcb6d5d0aa6d7a9eaa4 Mon Sep 17 00:00:00 2001
+From c2668f7f2ea82a61115b7cae56ed081b41ff5153 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sat, 22 Apr 2017 12:34:37 -0700
 Subject: [PATCH] configure: Disable format-overflow if supported by gcc
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
 ---
- Makefile.am                 |  6 ++--
- configure.ac                |  2 ++
- m4/ax_check_compile_flag.m4 | 74 +++++++++++++++++++++++++++++++++++++++++++++
+ Makefile.am                 |  6 +--
+ configure.ac                |  2 +
+ m4/ax_check_compile_flag.m4 | 74 +++++++++++++++++++++++++++++++++++++
  3 files changed, 79 insertions(+), 3 deletions(-)
  create mode 100644 m4/ax_check_compile_flag.m4
 
-Index: opensaf-5.18.02/Makefile.am
-===================================================================
---- opensaf-5.18.02.orig/Makefile.am
-+++ opensaf-5.18.02/Makefile.am
+diff --git a/Makefile.am b/Makefile.am
+index b3d6553..5607fc2 100644
+--- a/Makefile.am
++++ b/Makefile.am
 @@ -52,10 +52,10 @@ AM_CPPFLAGS = \
  	-pthread \
  	-D_GNU_SOURCE -DINTERNAL_VERSION_ID='"@INTERNAL_VERSION_ID@"' \
@@ -29,11 +30,11 @@
  
  if ENABLE_GCOV
  AM_CFLAGS += --coverage
-Index: opensaf-5.18.02/configure.ac
-===================================================================
---- opensaf-5.18.02.orig/configure.ac
-+++ opensaf-5.18.02/configure.ac
-@@ -593,6 +593,8 @@ if test -z "$OSAF_HARDEN_FLAGS"; then
+diff --git a/configure.ac b/configure.ac
+index 5b86730..47d1002 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -600,6 +600,8 @@ if test -z "$OSAF_HARDEN_FLAGS"; then
  fi
  AC_SUBST(OSAF_HARDEN_FLAGS)
  
@@ -42,10 +43,11 @@
  #############################################
  # List the output Makefiles
  #############################################
-Index: opensaf-5.18.02/m4/ax_check_compile_flag.m4
-===================================================================
+diff --git a/m4/ax_check_compile_flag.m4 b/m4/ax_check_compile_flag.m4
+new file mode 100644
+index 0000000..dcabb92
 --- /dev/null
-+++ opensaf-5.18.02/m4/ax_check_compile_flag.m4
++++ b/m4/ax_check_compile_flag.m4
 @@ -0,0 +1,74 @@
 +# ===========================================================================
 +#  https://www.gnu.org/software/autoconf-archive/ax_check_compile_flag.html
diff --git a/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-configure-Pass-linker-specific-options-with-Wl.patch b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-configure-Pass-linker-specific-options-with-Wl.patch
index 5756a02..e4bbb4c 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-configure-Pass-linker-specific-options-with-Wl.patch
+++ b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-configure-Pass-linker-specific-options-with-Wl.patch
@@ -1,4 +1,4 @@
-From 6248b717b4861d16b80235fd8e57d64e4f636428 Mon Sep 17 00:00:00 2001
+From 979b2b6a1aa574a26e8b736049c4207d568f60f3 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Thu, 13 Apr 2017 17:39:07 -0700
 Subject: [PATCH] configure: Pass linker specific options with -Wl
@@ -7,15 +7,16 @@
 and we can use non-gcc compilers
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
 ---
  configure.ac | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/configure.ac b/configure.ac
-index df4fc58..02771c6 100644
+index 12a5d5c..5b86730 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -553,7 +553,7 @@ if test -z "$OSAF_HARDEN_FLAGS"; then
+@@ -596,7 +596,7 @@ if test -z "$OSAF_HARDEN_FLAGS"; then
  	if echo "${CFLAGS} ${CXXFLAGS}" | grep -q -- -O0; then
  		OSAF_HARDEN_FLAGS=""
  	fi
@@ -24,6 +25,3 @@
  fi
  AC_SUBST(OSAF_HARDEN_FLAGS)
  
--- 
-2.12.2
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-immpbe_dump.cc-Use-sys-wait.h-instead-of-wait.h.patch b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-immpbe_dump.cc-Use-sys-wait.h-instead-of-wait.h.patch
index 76c47c6..e40d2b3 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-immpbe_dump.cc-Use-sys-wait.h-instead-of-wait.h.patch
+++ b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-immpbe_dump.cc-Use-sys-wait.h-instead-of-wait.h.patch
@@ -1,4 +1,4 @@
-From 508ea7c0d67243feb1684eaa83569cb687561d64 Mon Sep 17 00:00:00 2001
+From c21f77d592415f316138c05f581192a1f061e735 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 15 Sep 2017 10:09:03 -0700
 Subject: [PATCH] immpbe_dump.cc: Use sys/wait.h instead of wait.h
@@ -7,12 +7,13 @@
 redirecting incorrect #include <wait.h> to <sys/wait.h>
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
 ---
  src/imm/common/immpbe_dump.cc | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/src/imm/common/immpbe_dump.cc b/src/imm/common/immpbe_dump.cc
-index 100222f37..33e47ce3c 100644
+index e6b3cc5..3956028 100644
 --- a/src/imm/common/immpbe_dump.cc
 +++ b/src/imm/common/immpbe_dump.cc
 @@ -26,12 +26,12 @@
@@ -27,8 +28,5 @@
  #include <sys/stat.h>
 +#include <sys/wait.h>
  #include <libgen.h>
- 
- #include <saAis.h>
--- 
-2.14.1
-
+ #include <set>
+ #include <vector>
diff --git a/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-src-Add-missing-header-limits.h-for-_POSIX_HOST_NAME.patch b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-src-Add-missing-header-limits.h-for-_POSIX_HOST_NAME.patch
index 4a2a825..e4a3975 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-src-Add-missing-header-limits.h-for-_POSIX_HOST_NAME.patch
+++ b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0001-src-Add-missing-header-limits.h-for-_POSIX_HOST_NAME.patch
@@ -1,4 +1,4 @@
-From 6442b57a855e273aa5a3d93e8596783cea128073 Mon Sep 17 00:00:00 2001
+From 7fb393c66df33110fef0cbabac7d304f12eb82e4 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 15 Sep 2017 09:39:40 -0700
 Subject: [PATCH] src: Add missing header limits.h for _POSIX_HOST_NAME_MAX
@@ -7,6 +7,7 @@
 Do not use the deprecated headers under include/sys
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
 ---
  src/base/os_defs.h        | 5 +++--
  src/mds/mds_dt_tcp.c      | 1 -
@@ -18,7 +19,7 @@
  7 files changed, 6 insertions(+), 8 deletions(-)
 
 diff --git a/src/base/os_defs.h b/src/base/os_defs.h
-index 50a9bf5fc..af6842863 100644
+index a570c43..3559b19 100644
 --- a/src/base/os_defs.h
 +++ b/src/base/os_defs.h
 @@ -47,17 +47,18 @@
@@ -43,7 +44,7 @@
  #include <pthread.h>
  
 diff --git a/src/mds/mds_dt_tcp.c b/src/mds/mds_dt_tcp.c
-index 1407eb1ab..a87c22faa 100644
+index 1407eb1..a87c22f 100644
 --- a/src/mds/mds_dt_tcp.c
 +++ b/src/mds/mds_dt_tcp.c
 @@ -27,7 +27,6 @@
@@ -55,7 +56,7 @@
  #include <sys/types.h>
  #include <unistd.h>
 diff --git a/src/mds/mds_dt_tcp_disc.h b/src/mds/mds_dt_tcp_disc.h
-index a6249d73e..574f52681 100644
+index a6249d7..574f526 100644
 --- a/src/mds/mds_dt_tcp_disc.h
 +++ b/src/mds/mds_dt_tcp_disc.h
 @@ -24,7 +24,7 @@
@@ -68,7 +69,7 @@
  /*  mds_indentifire + mds_version   + msg_type + scope_type + server_type +
     server_instance_lower + server_instance_upper + sub_ref_val + sub_ref_val  +
 diff --git a/src/mds/mds_dt_tipc.c b/src/mds/mds_dt_tipc.c
-index 37745e7f0..9b3255567 100644
+index 7714175..a0ed3b6 100644
 --- a/src/mds/mds_dt_tipc.c
 +++ b/src/mds/mds_dt_tipc.c
 @@ -35,7 +35,6 @@
@@ -80,7 +81,7 @@
  #include <sys/types.h>
  #include <unistd.h>
 diff --git a/src/mds/mds_dt_tipc.h b/src/mds/mds_dt_tipc.h
-index e73a11b09..401d208c2 100644
+index e73a11b..401d208 100644
 --- a/src/mds/mds_dt_tipc.h
 +++ b/src/mds/mds_dt_tipc.h
 @@ -32,7 +32,7 @@
@@ -93,7 +94,7 @@
  #include <errno.h>
  #include <fcntl.h>
 diff --git a/src/mds/mds_dt_trans.c b/src/mds/mds_dt_trans.c
-index 6f621e04e..5aacbd33e 100644
+index 6f621e0..5aacbd3 100644
 --- a/src/mds/mds_dt_trans.c
 +++ b/src/mds/mds_dt_trans.c
 @@ -26,7 +26,6 @@
@@ -105,7 +106,7 @@
  
  #define MDS_PROT_TCP 0xA0
 diff --git a/src/ntf/ntfd/NtfLogger.cc b/src/ntf/ntfd/NtfLogger.cc
-index 84014b578..31b1ccc6c 100644
+index fd17c58..1120008 100644
 --- a/src/ntf/ntfd/NtfLogger.cc
 +++ b/src/ntf/ntfd/NtfLogger.cc
 @@ -20,7 +20,7 @@
@@ -117,6 +118,3 @@
  
  #include "base/osaf_utility.h"
  #include <saAis.h>
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0002-Fix-format-truncation-errors.patch b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0002-Fix-format-truncation-errors.patch
new file mode 100644
index 0000000..f98e28d
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0002-Fix-format-truncation-errors.patch
@@ -0,0 +1,100 @@
+From c5034fe42df8923bcefc10e163151997d70b6241 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 16 Apr 2018 14:56:47 -0700
+Subject: [PATCH] Fix format-truncation errors
+
+Fixes errors with gcc8 eg.
+error: '%u' directive output may be truncated writing between 1 and 10 bytes into a region of size between 0 and 254 [-Werror=format-truncation=]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+---
+ src/base/daemon.c  | 4 ++--
+ src/mds/mds_c_db.c | 8 ++++----
+ src/mds/mds_core.h | 4 ++--
+ src/mds/mds_dt2c.h | 2 +-
+ 4 files changed, 9 insertions(+), 9 deletions(-)
+
+diff --git a/src/base/daemon.c b/src/base/daemon.c
+index 361dd8d..4001b73 100644
+--- a/src/base/daemon.c
++++ b/src/base/daemon.c
+@@ -95,11 +95,11 @@ static int __create_pidfile(const char *pidfile)
+ {
+ 	FILE *file = NULL;
+ 	int fd, rc = 0;
+-	char pidfiletmp[NAME_MAX] = {0};
++	char pidfiletmp[NAME_MAX+12] = {0};
+ 	pid_t pid;
+ 
+ 	pid = getpid();
+-	snprintf(pidfiletmp, NAME_MAX, "%s.%u.tmp", pidfile, pid);
++	snprintf(pidfiletmp, NAME_MAX+12, "%s.%u.tmp", pidfile, pid);
+ 
+ 	/* open the file and associate a stream with it */
+ 	if (((fd = open(pidfiletmp, O_RDWR | O_CREAT, 0644)) == -1) ||
+diff --git a/src/mds/mds_c_db.c b/src/mds/mds_c_db.c
+index e6b95cd..3d4a222 100644
+--- a/src/mds/mds_c_db.c
++++ b/src/mds/mds_c_db.c
+@@ -124,10 +124,10 @@ void get_adest_details(MDS_DEST adest, char *adest_details)
+ 	}
+ 
+ 	if (remote == true)
+-		snprintf(adest_details, MDS_MAX_PROCESS_NAME_LEN,
++		snprintf(adest_details, MDS_MAX_PROCESS_NAME_LEN+24,
+ 			 "<rem_nodeid[0x%" PRIx32 "]:%s>", ncs_node_id, process_name);
+ 	else
+-		snprintf(adest_details, MDS_MAX_PROCESS_NAME_LEN,
++		snprintf(adest_details, MDS_MAX_PROCESS_NAME_LEN+24,
+ 			 "<nodeid[0x%" PRIx32 "]:%s>", ncs_node_id, process_name);
+ 
+ 	m_MDS_LOG_DBG("MDS:DB: adest_details: %s ", adest_details);
+@@ -207,10 +207,10 @@ void get_subtn_adest_details(MDS_PWE_HDL pwe_hdl, MDS_SVC_ID svc_id,
+ 	}
+ 
+ 	if (remote == true)
+-		snprintf(adest_details, MDS_MAX_PROCESS_NAME_LEN,
++		snprintf(adest_details, MDS_MAX_PROCESS_NAME_LEN+24,
+ 			 "<rem_node[0x%" PRIx32 "]:%s>", ncs_node_id, process_name);
+ 	else
+-		snprintf(adest_details, MDS_MAX_PROCESS_NAME_LEN,
++		snprintf(adest_details, MDS_MAX_PROCESS_NAME_LEN+24,
+ 			 "<node[0x%" PRIx32 "]:%s>", ncs_node_id, process_name);
+ done:
+ 	m_MDS_LOG_DBG("MDS:DB: adest_details: %s ", adest_details);
+diff --git a/src/mds/mds_core.h b/src/mds/mds_core.h
+index 37696d4..7f5225d 100644
+--- a/src/mds/mds_core.h
++++ b/src/mds/mds_core.h
+@@ -163,7 +163,7 @@ typedef struct mds_subscription_results_info {
+   uint32_t msg_snd_cnt; /* Message send count to this destination */
+   uint32_t msg_rcv_cnt; /* Message rcv count from this destination */
+   char sub_adest_details
+-      [MDS_MAX_PROCESS_NAME_LEN]; /* <node[slotno]:processname[pid]> */
++      [MDS_MAX_PROCESS_NAME_LEN+24]; /* <node[slotno]:processname[pid]> */
+ 
+ } MDS_SUBSCRIPTION_RESULTS_INFO;
+ 
+@@ -194,7 +194,7 @@ typedef struct mds_subscription_info {
+     count is grater than ZERO bcast (multi-unicast) */
+   uint32_t prev_ver_sub_count;
+   char sub_adest_details
+-      [MDS_MAX_PROCESS_NAME_LEN]; /* <node[slotno]:processname[pid]> */
++      [MDS_MAX_PROCESS_NAME_LEN+24]; /* <node[slotno]:processname[pid]> */
+ 
+ } MDS_SUBSCRIPTION_INFO;
+ 
+diff --git a/src/mds/mds_dt2c.h b/src/mds/mds_dt2c.h
+index 012999c..006b722 100644
+--- a/src/mds/mds_dt2c.h
++++ b/src/mds/mds_dt2c.h
+@@ -143,7 +143,7 @@ typedef struct mdtm_send_req {
+                        */
+   MDS_DEST adest;      /* MDTM to do local/remote routing, destination adest */
+   char sub_adest_details
+-      [MDS_MAX_PROCESS_NAME_LEN]; /* <node[nodeid]:processname[pid]> */
++      [MDS_MAX_PROCESS_NAME_LEN+24]; /* <node[nodeid]:processname[pid]> */
+   MDS_SEND_PRIORITY_TYPE pri;
+   MDS_CLIENT_MSG_FORMAT_VER
+       msg_fmt_ver; /* message format version specification */
diff --git a/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0008-check-for-size-before-using-strncpy.patch b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0008-check-for-size-before-using-strncpy.patch
new file mode 100644
index 0000000..497bb07
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf/0008-check-for-size-before-using-strncpy.patch
@@ -0,0 +1,33 @@
+From 29510dd81e3a5e96151afdb0702863cbfd640766 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 22 Jun 2018 18:58:59 -0700
+Subject: [PATCH] check for size before using strncpy
+
+ensures that size is never execeding the string length
+that execPath can hold
+
+Fixes
+error: '__builtin___strncpy_chk' specified size between 18446744071562067968 and 18446744073709551615 exceeds maximum object size 9223372036854775807 [-Werror=stringop-overflow=]
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/imm/immnd/immnd_proc.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/src/imm/immnd/immnd_proc.c b/src/imm/immnd/immnd_proc.c
+index 015932a..c8f115e 100644
+--- a/src/imm/immnd/immnd_proc.c
++++ b/src/imm/immnd/immnd_proc.c
+@@ -1902,6 +1902,10 @@ static int immnd_forkPbe(IMMND_CB *cb)
+ 		LOG_ER("Pathname too long: %u max is 1023", newLen);
+ 		return -1;
+ 	}
++	if (execDirLen > 1023 || execDirLen < 0) {
++		LOG_ER("Execdir name too long: %u max is 1023", execDirLen);
++		return -1;
++	}
+ 
+ 	strncpy(execPath, cb->mProgName, execDirLen);
+ 	execPath[execDirLen] = 0;
diff --git a/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf_5.18.02.bb b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf_5.18.02.bb
deleted file mode 100644
index 4b556ce..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf_5.18.02.bb
+++ /dev/null
@@ -1,67 +0,0 @@
-SUMMARY = "OpenSAF is an open source implementation of the SAF AIS specification"
-DESCRIPTION = "OpenSAF is an open source project established to develop a base platform \
-middleware consistent with Service Availability Forum (SA Forum) \
-specifications, under the LGPLv2.1 license. The OpenSAF Foundation was \
-established by leading Communications and Enterprise Computing Companies to \
-facilitate the OpenSAF Project and to accelerate the adoption of the OpenSAF \
-code base in commercial products. \
-The OpenSAF project was launched in mid 2007 and has been under development by \
-an informal group of supporters of the OpenSAF initiative. The OpenSAF \
-Foundation was founded on January 22nd 2008 with Emerson Network Power, \
-Ericsson, Nokia Siemens Networks, HP and Sun Microsystems as founding members."
-HOMEPAGE = "http://www.opensaf.org"
-SECTION = "admin"
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=a916467b91076e631dd8edb7424769c7"
-
-DEPENDS = "libxml2 python"
-TOOLCHAIN = "gcc"
-
-SECURITY_CFLAGS = "${SECURITY_NO_PIE_CFLAGS}"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/releases/${BPN}-${PV}.tar.gz \
-           file://0001-configure-Pass-linker-specific-options-with-Wl.patch \
-           file://0001-configure-Disable-format-overflow-if-supported-by-gc.patch \
-           file://0001-src-Add-missing-header-limits.h-for-_POSIX_HOST_NAME.patch \
-           file://0001-immpbe_dump.cc-Use-sys-wait.h-instead-of-wait.h.patch \
-"
-SRC_URI[md5sum] = "42064f5ddbc7f560bfc5ff93ea9eecc7"
-SRC_URI[sha256sum] = "f9e24897f9cfd63bb3115f6275c706de1702d3d9bae2fc423227db72b23c37f0"
-
-inherit autotools useradd systemd pkgconfig
-
-USERADD_PACKAGES = "${PN}"
-GROUPADD_PARAM_${PN} = "-f -r opensaf"
-USERADD_PARAM_${PN} =  "-r -g opensaf -d ${datadir}/opensaf/ -s ${sbindir}/nologin -c \"OpenSAF\" opensaf"
-
-SYSTEMD_SERVICE_${PN} += "opensafd.service"
-SYSTEMD_AUTO_ENABLE = "disable"
-
-PACKAGECONFIG[systemd] = ",,systemd"
-PACKAGECONFIG[openhpi] = "--with-hpi-interface=B03 --enable-ais-plm,,openhpi"
-
-PACKAGECONFIG_append = "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', ' systemd', '', d)}"
-
-PKGLIBDIR="${libdir}"
-
-LDFLAGS += "-Wl,--as-needed -latomic -Wl,--no-as-needed"
-
-do_install_append() {
-    cp -av --no-preserve=ownership ${B}/lib/.libs/*.so* ${D}${libdir}
-    rm -fr "${D}${localstatedir}/lock"
-    rm -fr "${D}${localstatedir}/run"
-    rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
-    rmdir --ignore-fail-on-non-empty "${D}${datadir}/java"
-    if [ ! -d "${D}${sysconfdir}/init.d" ]; then
-        install -d ${D}${sysconfdir}/init.d
-        install -m 0755 ${B}/osaf/services/infrastructure/nid/scripts/opensafd ${D}${sysconfdir}/init.d/
-    fi
-}
-
-FILES_${PN} += "${systemd_unitdir}/system/*.service"
-FILES_${PN}-staticdev += "${PKGLIBDIR}/*.a"
-
-INSANE_SKIP_${PN} = "dev-so"
-
-RDEPENDS_${PN} += "bash python"
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf_5.18.04.bb b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf_5.18.04.bb
new file mode 100644
index 0000000..c534c62
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/opensaf/opensaf_5.18.04.bb
@@ -0,0 +1,74 @@
+SUMMARY = "OpenSAF is an open source implementation of the SAF AIS specification"
+DESCRIPTION = "OpenSAF is an open source project established to develop a base platform \
+middleware consistent with Service Availability Forum (SA Forum) \
+specifications, under the LGPLv2.1 license. The OpenSAF Foundation was \
+established by leading Communications and Enterprise Computing Companies to \
+facilitate the OpenSAF Project and to accelerate the adoption of the OpenSAF \
+code base in commercial products. \
+The OpenSAF project was launched in mid 2007 and has been under development by \
+an informal group of supporters of the OpenSAF initiative. The OpenSAF \
+Foundation was founded on January 22nd 2008 with Emerson Network Power, \
+Ericsson, Nokia Siemens Networks, HP and Sun Microsystems as founding members."
+HOMEPAGE = "http://www.opensaf.org"
+SECTION = "admin"
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=a916467b91076e631dd8edb7424769c7"
+
+DEPENDS = "libxml2 python"
+TOOLCHAIN = "gcc"
+
+SECURITY_CFLAGS = "${SECURITY_NO_PIE_CFLAGS}"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/releases/${BPN}-${PV}.tar.gz \
+           file://0001-configure-Pass-linker-specific-options-with-Wl.patch \
+           file://0001-configure-Disable-format-overflow-if-supported-by-gc.patch \
+           file://0001-src-Add-missing-header-limits.h-for-_POSIX_HOST_NAME.patch \
+           file://0001-immpbe_dump.cc-Use-sys-wait.h-instead-of-wait.h.patch \
+           file://0001-Catch-std-ifstream-failure-by-reference.patch \
+           file://0002-Fix-format-truncation-errors.patch \
+           file://0001-Fix-string-overflow-in-snprintf.patch \
+           file://0008-check-for-size-before-using-strncpy.patch \
+           "
+SRC_URI[md5sum] = "21836e43b13ad33bed9bd0ed391e5a6e"
+SRC_URI[sha256sum] = "e55dc2645487fb22938e8386b99eef6eb7aff43a246ce3e92488daf6ee46247a"
+
+inherit autotools useradd systemd pkgconfig
+
+USERADD_PACKAGES = "${PN}"
+GROUPADD_PARAM_${PN} = "-f -r opensaf"
+USERADD_PARAM_${PN} =  "-r -g opensaf -d ${datadir}/opensaf/ -s ${sbindir}/nologin -c \"OpenSAF\" opensaf"
+
+SYSTEMD_SERVICE_${PN} += "opensafd.service"
+SYSTEMD_AUTO_ENABLE = "disable"
+
+PACKAGECONFIG[systemd] = ",,systemd"
+PACKAGECONFIG[openhpi] = "--with-hpi-interface=B03,,openhpi"
+PACKAGECONFIG[plm] = "--enable-ais-plm,--disable-ais-plm,libvirt openhpi"
+
+PACKAGECONFIG ?= "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', ' systemd', '', d)}"
+
+PKGLIBDIR="${libdir}"
+
+LDFLAGS += "-Wl,--as-needed -latomic -Wl,--no-as-needed"
+
+do_install_append() {
+    cp -av --no-preserve=ownership ${B}/lib/.libs/*.so* ${D}${libdir}
+    rm -fr "${D}${localstatedir}/lock"
+    rm -fr "${D}${localstatedir}/run"
+    rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
+    rmdir --ignore-fail-on-non-empty "${D}${datadir}/java"
+    if [ ! -d "${D}${sysconfdir}/init.d" ]; then
+        install -d ${D}${sysconfdir}/init.d
+        install -m 0755 ${B}/osaf/services/infrastructure/nid/scripts/opensafd ${D}${sysconfdir}/init.d/
+    fi
+}
+
+FILES_${PN} += "${systemd_unitdir}/system/*.service"
+FILES_${PN}-staticdev += "${PKGLIBDIR}/*.a"
+
+INSANE_SKIP_${PN} = "dev-so"
+
+RDEPENDS_${PN} += "bash python"
+
+# http://errors.yoctoproject.org/Errors/Details/186970/
+EXCLUDE_FROM_WORLD_libc-musl = "1"
diff --git a/meta-openembedded/meta-networking/recipes-daemons/postfix/files/0001-Check-for-glibc-before-setting-CANT_USE_SEND_RECV_MS.patch b/meta-openembedded/meta-networking/recipes-daemons/postfix/files/0001-Check-for-glibc-before-setting-CANT_USE_SEND_RECV_MS.patch
deleted file mode 100644
index 6b86e39..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/postfix/files/0001-Check-for-glibc-before-setting-CANT_USE_SEND_RECV_MS.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-From 63619acf25151d4dade6d65732722ec4a710a5ac Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 15 Jul 2017 09:54:25 -0700
-Subject: [PATCH] Check for glibc before setting CANT_USE_SEND_RECV_MSG
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/util/sys_defs.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/util/sys_defs.h b/src/util/sys_defs.h
-index f720e2a..7314c63 100644
---- a/src/util/sys_defs.h
-+++ b/src/util/sys_defs.h
-@@ -813,7 +813,7 @@ extern int initgroups(const char *, int);
- #define KERNEL_VERSION(a,b,c) (LINUX_VERSION_CODE + 1)
- #endif
- #if (LINUX_VERSION_CODE < KERNEL_VERSION(2,2,0)) \
--	|| (__GLIBC__ < 2)
-+	|| (defined(__GLIBC__) && (__GLIBC__ < 2))
- #define CANT_USE_SEND_RECV_MSG
- #define DEF_SMTP_CACHE_DEMAND	0
- #else
--- 
-2.13.3
-
diff --git a/meta-openembedded/meta-networking/recipes-daemons/postfix/files/0001-makedefs-add-lnsl-and-lresolv-to-SYSLIBS-by-default.patch b/meta-openembedded/meta-networking/recipes-daemons/postfix/files/0001-makedefs-add-lnsl-and-lresolv-to-SYSLIBS-by-default.patch
new file mode 100644
index 0000000..5650984
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/postfix/files/0001-makedefs-add-lnsl-and-lresolv-to-SYSLIBS-by-default.patch
@@ -0,0 +1,58 @@
+From 4caa18feb70f8f3d133657c1250a53f4e292bb42 Mon Sep 17 00:00:00 2001
+From: Yi Zhao <yi.zhao@windriver.com>
+Date: Fri, 12 Oct 2018 12:38:02 +0800
+Subject: [PATCH] makedefs: add -lnsl and -lresolv to SYSLIBS by default
+
+We don't need to check libnsl.so and libresolv.so since the libnsl2 is
+specified in DEPENDS and libresolv.so is from c libarary.
+
+Upstream-Status: Inappropriate [embedded specific]
+
+Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
+---
+ makedefs | 22 ++--------------------
+ 1 file changed, 2 insertions(+), 20 deletions(-)
+
+diff --git a/makedefs b/makedefs
+index 2683bce..8f1b3f4 100644
+--- a/makedefs
++++ b/makedefs
+@@ -484,16 +484,7 @@ case "$SYSTEM.$RELEASE" in
+ 		    SYSLIBS="$SYSLIBS -ldb"
+ 		    ;;
+ 		esac
+-		for name in nsl resolv $GDBM_LIBS
+-		do
+-		    for lib in $BUILD_SYSROOT_NSL_PATH
+-		    do
+-			test -e $lib/lib$name.a -o -e $lib/lib$name.so && {
+-			    SYSLIBS="$SYSLIBS -l$name"
+-			    break
+-			}
+-		    done
+-		done
++		SYSLIBS="$SYSLIBS -lnsl -lresolv"
+ 		# Kernel 2.4 added IPv6
+ 		case "$RELEASE" in
+ 		2.[0-3].*) CCARGS="$CCARGS -DNO_IPV6";;
+@@ -561,16 +552,7 @@ EOF
+ 		    SYSLIBS="$SYSLIBS -ldb"
+ 		    ;;
+ 		esac
+-		for name in nsl resolv
+-		do
+-		    for lib in $BUILD_SYSROOT_NSL_PATH
+-		    do
+-			test -e $lib/lib$name.a -o -e $lib/lib$name.so && {
+-			    SYSLIBS="$SYSLIBS -l$name"
+-			    break
+-			}
+-		    done
+-		done
++		SYSLIBS="$SYSLIBS -lnsl -lresolv"
+ 		SYSLIBS="$SYSLIBS -ldl"
+ 		: ${SHLIB_SUFFIX=.so}
+ 		: ${SHLIB_CFLAGS=-fPIC}
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-daemons/postfix/postfix.inc b/meta-openembedded/meta-networking/recipes-daemons/postfix/postfix.inc
index 09447d5..3d4f1df 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/postfix/postfix.inc
+++ b/meta-openembedded/meta-networking/recipes-daemons/postfix/postfix.inc
@@ -6,14 +6,13 @@
 
 HOMEPAGE= "http://www.postfix.org"
 SECTION = "mail"
-DEPENDS = "db icu libpcre openssl postfix-native \
+DEPENDS = "db icu libpcre libnsl2 openssl postfix-native \
     ${@bb.utils.contains('DISTRO_FEATURES', 'ldap', 'openldap', '', d)} \
     ${@bb.utils.contains('DISTRO_FEATURES', 'sasl', 'cyrus-sasl', '', d)} \
 "
-DEPENDS_class-native = "db-native icu-native openssl-native libpcre-native"
 
-LICENSE = "IPL-1.0"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=64375f37431336ea1b1b3005fe3fa354"
+LICENSE = "IPL-1.0 | EPL-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=b181651ad99a7dc4cc8c4ce2f491ed1a"
 
 SRC_URI = "ftp://ftp.porcupine.org/mirrors/postfix-release/official/postfix-${PV}.tar.gz \
     file://makedefs.patch \
@@ -77,7 +76,6 @@
 export AUXLIBS = "-lpcre -lssl -lcrypto ${AUXLIBS-sasl} ${AUXLIBS-ldap}"
 export POSTCONF = "${STAGING_DIR_NATIVE}${sbindir_native}/postconf"
 
-export CCARGS-nonis_libc-musl = "-DNO_NIS"
 # OPT,DEBUG is aready in CFLAGS
 # ignore the OPTS="CC=$CC" in Makefile it will not use the CC=$CC $CCARGS
 EXTRA_OEMAKE += "OPT= DEBUG= OPTS= "
@@ -99,27 +97,9 @@
             "s:\$(SHELL) makedefs):\$(SHELL) makedefs $SYSTEM $RELEASE):" \
             ${S}/Makefile.in
         export BUILD_SYSROOT="${STAGING_DIR_HOST}"
-        export BUILD_SYSROOT_NSL_PATH="${STAGING_BASELIBDIR} \
-                                       ${STAGING_LIBDIR}"
     else
         # native build
         export BUILD_SYSROOT="${STAGING_DIR_NATIVE}"
-
-        # ubuntu x86 host: /lib/x86_64-linux-gnu(64) /lib/i386-linux-gnu (32)
-        #             on 64 bits, 32 libs in i386-linux-gnu
-        # let makedefs finds nsl and resolv libs, host CC will link
-        # the correct libraries
-        BUILD_SYSROOT_NSL_PATH="$(${CC} -print-search-dirs 2>/dev/null | \
-                      sed -n '/^libraries: =/s/libraries: =//p' | \
-                      sed -e 's/:/\n/g' | xargs -n1 readlink -f | \
-                      grep -v 'gcc\|/[0-9.]\+$' | sort -u)"
-        if [ -z "$BUILD_SYSROOT_NSL_PATH" ]; then
-            BUILD_SYSROOT_NSL_PATH="/usr/lib64 /lib64 \
-                                    /lib/x86_64-linux-gnu \
-                                    /usr/lib   /lib \
-                                    /lib/i386-linux-gnu"
-        fi
-        export BUILD_SYSROOT_NSL_PATH
     fi
 
     oe_runmake makefiles
@@ -207,6 +187,8 @@
     chown :postdrop ${D}${sbindir}/postdrop
     chmod g+s ${D}${sbindir}/postqueue
     chmod g+s ${D}${sbindir}/postdrop
+
+    rm -rf ${D}/etc/postfix/makedefs.out
 }
 
 do_install_append_class-native() {
@@ -214,14 +196,12 @@
     ln -sf ../sbin/sendmail.postfix ${D}${bindir}/mailq
 }
 
-do_install_append_class-target() {
-    # Remove references to buildmachine paths in target makedefs.out
-    sed -i 's:-fdebug-prefix-map[^ ]*::g; s:--sysroot=${STAGING_DIR_TARGET}::g' ${D}/etc/postfix/makedefs.out
-}
-
-ALTERNATIVE_${PN} = "sendmail"
+ALTERNATIVE_${PN} += "sendmail mailq newaliases"
+ALTERNATIVE_TARGET[mailq] = "${bindir}/mailq"
+ALTERNATIVE_TARGET[newaliases] = "${bindir}/newaliases"
 ALTERNATIVE_TARGET[sendmail] = "${sbindir}/sendmail.postfix"
 ALTERNATIVE_LINK_NAME[sendmail] = "${sbindir}/sendmail"
+
 ALTERNATIVE_PRIORITY = "120"
 
 ALTERNATIVE_${PN}-doc += "mailq.1 newaliases.1 sendmail.1"
@@ -248,10 +228,10 @@
         # This can fail depending on host setup
         if ! newaliases -C $D/etc/postfix/main.cf -oA$D/etc/aliases; then
             $INTERCEPT_DIR/postinst_intercept delay_to_first_boot ${PKG} mlprefix=${MLPREFIX}
-            exit 0
+        else
+            touch $D/etc/postfix/virtual_alias
+            postmap -c $D/etc/postfix $D/etc/postfix/virtual_alias
         fi
-        touch $D/etc/postfix/virtual_alias
-        postmap -c $D/etc/postfix $D/etc/postfix/virtual_alias
 
     fi
 }
diff --git a/meta-openembedded/meta-networking/recipes-daemons/postfix/postfix_3.2.2.bb b/meta-openembedded/meta-networking/recipes-daemons/postfix/postfix_3.2.2.bb
deleted file mode 100644
index 89af406..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/postfix/postfix_3.2.2.bb
+++ /dev/null
@@ -1,9 +0,0 @@
-require postfix.inc
-
-SRC_URI += "file://0001-Check-for-glibc-before-setting-CANT_USE_SEND_RECV_MS.patch \
-            file://0001-makedefs-Use-native-compiler-to-build-makedefs.test.patch \
-            file://postfix-install.patch \
-            file://icu-config.patch \
-           "
-SRC_URI[md5sum] = "aea073a9b0bea5bdb590460a270a4aa0"
-SRC_URI[sha256sum] = "d06849418d119d09366997b2b481bb23f737629769b4e4a52da42fb3ad8b0576"
diff --git a/meta-openembedded/meta-networking/recipes-daemons/postfix/postfix_3.3.1.bb b/meta-openembedded/meta-networking/recipes-daemons/postfix/postfix_3.3.1.bb
new file mode 100644
index 0000000..6718b7e
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/postfix/postfix_3.3.1.bb
@@ -0,0 +1,12 @@
+require postfix.inc
+
+SRC_URI += "file://0001-makedefs-Use-native-compiler-to-build-makedefs.test.patch \
+            file://postfix-install.patch \
+            file://icu-config.patch \
+            file://0001-makedefs-add-lnsl-and-lresolv-to-SYSLIBS-by-default.patch \
+           "
+
+SRC_URI[md5sum] = "4381c6492f415e4a69cf5099d4acea76"
+SRC_URI[sha256sum] = "54f514dae42b5275cb4bc9c69283f16c06200b71813d0bb696568c4ba7ae7e3b"
+
+UPSTREAM_CHECK_REGEX = "postfix\-(?P<pver>3\.3(\.\d+)+).tar.gz"
diff --git a/meta-openembedded/meta-networking/recipes-daemons/pure-ftpd/pure-ftpd_1.0.42.bb b/meta-openembedded/meta-networking/recipes-daemons/pure-ftpd/pure-ftpd_1.0.42.bb
index c1f1504..e5c5616 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/pure-ftpd/pure-ftpd_1.0.42.bb
+++ b/meta-openembedded/meta-networking/recipes-daemons/pure-ftpd/pure-ftpd_1.0.42.bb
@@ -5,7 +5,7 @@
 LICENSE = "BSD"
 LIC_FILES_CHKSUM = "file://COPYING;md5=90352fb2bfe17f4261687a0d6e09f489"
 
-DEPENDS = "libcap"
+DEPENDS = "libcap virtual/crypt"
 
 
 SRC_URI = "http://download.pureftpd.org/pub/pure-ftpd/releases/pure-ftpd-${PV}.tar.gz \
diff --git a/meta-openembedded/meta-networking/recipes-daemons/radvd/radvd.inc b/meta-openembedded/meta-networking/recipes-daemons/radvd/radvd.inc
index 06d16a4..59a07d7 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/radvd/radvd.inc
+++ b/meta-openembedded/meta-networking/recipes-daemons/radvd/radvd.inc
@@ -20,7 +20,7 @@
            file://volatiles.03_radvd \
            file://radvd.default"
 
-inherit autotools update-rc.d useradd pkgconfig systemd
+inherit autotools useradd pkgconfig systemd
 
 SYSTEMD_SERVICE_${PN} = "radvd.service"
 SYSTEMD_AUTO_ENABLE = "disable"
@@ -36,7 +36,7 @@
     sed -i 's!/var/!${localstatedir}/!g' ${D}${sysconfdir}/init.d/radvd
     sed -i 's!^PATH=.*!PATH=${base_sbindir}:${base_bindir}:${sbindir}:${bindir}!' ${D}${sysconfdir}/init.d/radvd
 
-    install -m 0644 ${WORKDIR}/volatiles.03_radvd ${D}${sysconfdir}/default/volatiles/volatiles.03_radvd
+    install -m 0644 ${WORKDIR}/volatiles.03_radvd ${D}${sysconfdir}/default/volatiles/03_radvd
 
     # Install systemd service files
     install -d ${D}${systemd_unitdir}/system
@@ -54,9 +54,6 @@
     done
 }
 
-INITSCRIPT_NAME = "radvd"
-INITSCRIPT_PARAMS = "defaults 20 80"
-
 USERADD_PACKAGES = "${PN}"
 USERADD_PARAM_${PN} = "--system --home ${localstatedir}/run/radvd/ -M -g nogroup radvd"
 
diff --git a/meta-openembedded/meta-networking/recipes-daemons/squid/files/0001-Bug-4843-pt1-ext_edirectory_userip_acl-refactoring-f.patch b/meta-openembedded/meta-networking/recipes-daemons/squid/files/0001-Bug-4843-pt1-ext_edirectory_userip_acl-refactoring-f.patch
new file mode 100644
index 0000000..001d9e9
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/squid/files/0001-Bug-4843-pt1-ext_edirectory_userip_acl-refactoring-f.patch
@@ -0,0 +1,506 @@
+From 01a44c96dbd04936e9cb2501745a834a0b09d504 Mon Sep 17 00:00:00 2001
+From: Amos Jeffries <yadij@users.noreply.github.com>
+Date: Sun, 13 May 2018 06:57:41 +0000
+Subject: [PATCH] Bug 4843 pt1: ext_edirectory_userip_acl refactoring for GCC-8
+ (#204)
+
+Proposed changes to this helper to fix strcat / strncat buffer
+overread / overflow issues.
+
+The approach takes three parts:
+
+* adds a makeHexString function to replace many for-loops
+  catenating bits of strings together with hex conversion into a
+  second buffer. Replacing with a snprintf() and buffer overflow
+  handling.
+
+* a copy of Ip::Address::lookupHostIp to convert the input
+  string into IP address binary format, then generate the hex
+  string using the above new hex function instead of looped
+  sub-string concatenations across several buffers.
+  This removes all the "00" and "0000" strncat() calls and
+  allows far simpler code even with added buffer overflow
+  handling.
+
+* replace multiple string part concatenations with a few simpler
+  calls to snprintf() for all the search_ip buffer constructions.
+  Adding buffer overflow handling as needed for the new calls.
+---
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Backport
+
+ .../ext_edirectory_userip_acl.cc              | 376 ++++++------------
+ 1 file changed, 120 insertions(+), 256 deletions(-)
+
+diff --git a/helpers/external_acl/eDirectory_userip/ext_edirectory_userip_acl.cc b/helpers/external_acl/eDirectory_userip/ext_edirectory_userip_acl.cc
+index 63609e4..ad16bfd 100644
+--- a/helpers/external_acl/eDirectory_userip/ext_edirectory_userip_acl.cc
++++ b/helpers/external_acl/eDirectory_userip/ext_edirectory_userip_acl.cc
+@@ -67,6 +67,9 @@
+ #ifdef HAVE_LDAP_H
+ #include <ldap.h>
+ #endif
++#ifdef HAVE_NETDB_H
++#include <netdb.h>
++#endif
+ 
+ #ifdef HELPER_INPUT_BUFFER
+ #define EDUI_MAXLEN     HELPER_INPUT_BUFFER
+@@ -714,11 +717,14 @@ BindLDAP(edui_ldap_t *l, char *dn, char *pw, unsigned int t)
+ 
+     /* Copy details - dn and pw CAN be NULL for anonymous and/or TLS */
+     if (dn != NULL) {
++        if (strlen(dn) >= sizeof(l->dn))
++            return LDAP_ERR_OOB; /* DN too large */
++
+         if ((l->basedn[0] != '\0') && (strstr(dn, l->basedn) == NULL)) {
+             /* We got a basedn, but it's not part of dn */
+-            xstrncpy(l->dn, dn, sizeof(l->dn));
+-            strncat(l->dn, ",", 1);
+-            strncat(l->dn, l->basedn, strlen(l->basedn));
++            const int x = snprintf(l->dn, sizeof(l->dn)-1, "%s,%s", dn, l->basedn);
++            if (x < 0 || static_cast<size_t>(x) >= sizeof(l->dn))
++                return LDAP_ERR_OOB; /* DN too large */
+         } else
+             xstrncpy(l->dn, dn, sizeof(l->dn));
+     }
+@@ -778,24 +784,73 @@ BindLDAP(edui_ldap_t *l, char *dn, char *pw, unsigned int t)
+     }
+ }
+ 
++// XXX: duplicate (partial) of Ip::Address::lookupHostIp
++/**
++ * Convert the IP address string representation in src to
++ * its binary representation.
++ *
++ * \return binary representation of the src IP address.
++ *         Must be free'd using freeaddrinfo().
++ */
++static struct addrinfo *
++makeIpBinary(const char *src)
++{
++    struct addrinfo want;
++    memset(&want, 0, sizeof(want));
++    want.ai_flags = AI_NUMERICHOST; // prevent actual DNS lookups!
++
++    struct addrinfo *dst = nullptr;
++    if (getaddrinfo(src, nullptr, &want, &dst) != 0) {
++        // not an IP address
++        /* free any memory getaddrinfo() dynamically allocated. */
++        if (dst)
++            freeaddrinfo(dst);
++        return nullptr;
++    }
++
++    return dst;
++}
++
++/**
++ * Convert srcLen bytes from src into HEX and store into dst, which
++ * has a maximum content size of dstSize including c-string terminator.
++ * The dst value produced will be a 0-terminated c-string.
++ *
++ * \retval   N  length of dst written (excluding c-string terminator)
++ * \retval -11  (LDAP_ERR_OOB) buffer overflow detected
++ */
++static int
++makeHexString(char *dst, const int dstSize, const char *src, const int srcLen)
++{
++    // HEX encoding doubles the amount of bytes/octets copied
++    if ((srcLen*2) >= dstSize)
++        return LDAP_ERR_OOB; // cannot copy that many
++
++    *dst = 0;
++
++    for (int k = 0; k < srcLen; ++k) {
++        int c = static_cast<int>(src[k]);
++        if (c < 0)
++            c = c + 256;
++        char hexc[4];
++        const int hlen = snprintf(hexc, sizeof(hexc), "%02X", c);
++        if (hlen < 0 || static_cast<size_t>(hlen) > sizeof(hexc)) // should be impossible
++            return LDAP_ERR_OOB;
++        strcat(dst, hexc);
++    }
++    return strlen(dst);
++}
++
+ /*
+  * ConvertIP() - <edui_ldap_t> <ip>
+  *
+  * Take an IPv4 address in dot-decimal or IPv6 notation, and convert to 2-digit HEX stored in l->search_ip
+  * This is the networkAddress that we search LDAP for.
+- *
+- * PENDING -- CHANGE OVER TO inet*_pton, but inet6_pton does not provide the correct syntax
+- *
+  */
+ static int
+ ConvertIP(edui_ldap_t *l, char *ip)
+ {
+-    char bufa[EDUI_MAXLEN], bufb[EDUI_MAXLEN], obj[EDUI_MAXLEN];
+-    char hexc[4], *p;
+     void *y, *z;
+-    size_t s;
+-    long x;
+-    int i, j, t, swi;                           /* IPv6 "::" cut over toggle */
+     if (l == NULL) return LDAP_ERR_NULL;
+     if (ip == NULL) return LDAP_ERR_PARAM;
+     if (!(l->status & LDAP_INIT_S)) return LDAP_ERR_INIT;       /* Not initalized */
+@@ -831,183 +886,22 @@ ConvertIP(edui_ldap_t *l, char *ip)
+             l->status |= (LDAP_IPV4_S);
+         z = NULL;
+     }
+-    s = strlen(ip);
+-    *(bufa) = '\0';
+-    *(bufb) = '\0';
+-    *(obj) = '\0';
+-    /* StringSplit() will zero out bufa & obj at each call */
+-    memset(l->search_ip, '\0', sizeof(l->search_ip));
+-    xstrncpy(bufa, ip, sizeof(bufa));                       /* To avoid segfaults, use bufa instead of ip */
+-    swi = 0;
+-    if (l->status & LDAP_IPV6_S) {
+-        /* Search for :: in string */
+-        if ((bufa[0] == ':') && (bufa[1] == ':')) {
+-            /* bufa starts with a ::, so just copy and clear */
+-            xstrncpy(bufb, bufa, sizeof(bufb));
+-            *(bufa) = '\0';
+-            ++swi;                              /* Indicates that there is a bufb */
+-        } else if ((bufa[0] == ':') && (bufa[1] != ':')) {
+-            /* bufa starts with a :, a typo so just fill in a ':', cat and clear */
+-            bufb[0] = ':';
+-            strncat(bufb, bufa, strlen(bufa));
+-            *(bufa) = '\0';
+-            ++swi;                              /* Indicates that there is a bufb */
+-        } else {
+-            p = strstr(bufa, "::");
+-            if (p != NULL) {
+-                /* Found it, break bufa down and split into bufb here */
+-                *(bufb) = '\0';
+-                i = strlen(p);
+-                memcpy(bufb, p, i);
+-                *p = '\0';
+-                bufb[i] = '\0';
+-                ++swi;                              /* Indicates that there is a bufb */
+-            }
+-        }
+-    }
+-    s = strlen(bufa);
+-    if (s < 1)
+-        s = strlen(bufb);
+-    while (s > 0) {
+-        if ((l->status & LDAP_IPV4_S) && (swi == 0)) {
+-            /* Break down IPv4 address  */
+-            t = StringSplit(bufa, '.', obj, sizeof(obj));
+-            if (t > 0) {
+-                errno = 0;
+-                x = strtol(obj, (char **)NULL, 10);
+-                if (((x < 0) || (x > 255)) || ((errno != 0) && (x == 0)) || ((obj[0] != '0') && (x == 0)))
+-                    return LDAP_ERR_OOB;                        /* Out of bounds -- Invalid address */
+-                memset(hexc, '\0', sizeof(hexc));
+-                int hlen = snprintf(hexc, sizeof(hexc), "%02X", (int)x);
+-                strncat(l->search_ip, hexc, hlen);
+-            } else
+-                break;                              /* reached end of octet */
+-        } else if (l->status & LDAP_IPV6_S) {
+-            /* Break down IPv6 address */
+-            if (swi > 1)
+-                t = StringSplit(bufb, ':', obj, sizeof(obj));           /* After "::" */
+-            else
+-                t = StringSplit(bufa, ':', obj, sizeof(obj));           /* Before "::" */
+-            /* Convert octet by size (t) - and fill 0's */
+-            switch (t) {                            /* IPv6 is already in HEX, copy contents */
+-            case 4:
+-                hexc[0] = (char) toupper((int)obj[0]);
+-                i = (int)hexc[0];
+-                if (!isxdigit(i))
+-                    return LDAP_ERR_OOB;                    /* Out of bounds */
+-                hexc[1] = (char) toupper((int)obj[1]);
+-                i = (int)hexc[1];
+-                if (!isxdigit(i))
+-                    return LDAP_ERR_OOB;                    /* Out of bounds */
+-                hexc[2] = '\0';
+-                strncat(l->search_ip, hexc, 2);
+-                hexc[0] = (char) toupper((int)obj[2]);
+-                i = (int)hexc[0];
+-                if (!isxdigit(i))
+-                    return LDAP_ERR_OOB;                    /* Out of bounds */
+-                hexc[1] = (char) toupper((int)obj[3]);
+-                i = (int)hexc[1];
+-                if (!isxdigit(i))
+-                    return LDAP_ERR_OOB;                    /* Out of bounds */
+-                hexc[2] = '\0';
+-                strncat(l->search_ip, hexc, 2);
+-                break;
+-            case 3:
+-                hexc[0] = '0';
+-                hexc[1] = (char) toupper((int)obj[0]);
+-                i = (int)hexc[1];
+-                if (!isxdigit(i))
+-                    return LDAP_ERR_OOB;                    /* Out of bounds */
+-                hexc[2] = '\0';
+-                strncat(l->search_ip, hexc, 2);
+-                hexc[0] = (char) toupper((int)obj[1]);
+-                i = (int)hexc[0];
+-                if (!isxdigit(i))
+-                    return LDAP_ERR_OOB;                    /* Out of bounds */
+-                hexc[1] = (char) toupper((int)obj[2]);
+-                i = (int)hexc[1];
+-                if (!isxdigit(i))
+-                    return LDAP_ERR_OOB;                    /* Out of bounds */
+-                hexc[2] = '\0';
+-                strncat(l->search_ip, hexc, 2);
+-                break;
+-            case 2:
+-                strncat(l->search_ip, "00", 2);
+-                hexc[0] = (char) toupper((int)obj[0]);
+-                i = (int)hexc[0];
+-                if (!isxdigit(i))
+-                    return LDAP_ERR_OOB;                    /* Out of bounds */
+-                hexc[1] = (char) toupper((int)obj[1]);
+-                i = (int)hexc[1];
+-                if (!isxdigit(i))
+-                    return LDAP_ERR_OOB;                    /* Out of bounds */
+-                hexc[2] = '\0';
+-                strncat(l->search_ip, hexc, 2);
+-                break;
+-            case 1:
+-                strncat(l->search_ip, "00", 2);
+-                hexc[0] = '0';
+-                hexc[1] = (char) toupper((int)obj[0]);
+-                i = (int)hexc[1];
+-                if (!isxdigit(i))
+-                    return LDAP_ERR_OOB;                    /* Out of bounds */
+-                hexc[2] = '\0';
+-                strncat(l->search_ip, hexc, 2);
+-                break;
+-            default:
+-                if (t > 4)
+-                    return LDAP_ERR_OOB;
+-                break;
+-            }
+-            /* Code to pad the address with 0's between a '::' */
+-            if ((strlen(bufa) == 0) && (swi == 1)) {
+-                /* We are *AT* the split, pad in some 0000 */
+-                t = strlen(bufb);
+-                /* How many ':' exist in bufb ? */
+-                j = 0;
+-                for (i = 0; i < t; ++i) {
+-                    if (bufb[i] == ':')
+-                        ++j;
+-                }
+-                --j;                                /* Preceding "::" doesn't count */
+-                t = 8 - (strlen(l->search_ip) / 4) - j;         /* Remainder */
+-                if (t > 0) {
+-                    for (i = 0; i < t; ++i)
+-                        strncat(l->search_ip, "0000", 4);
+-                }
+-            }
+-        }
+-        if ((bufa[0] == '\0') && (swi > 0)) {
+-            s = strlen(bufb);
+-            ++swi;
+-        } else
+-            s = strlen(bufa);
+-    }
+-    s = strlen(l->search_ip);
+ 
+-    /* CHECK sizes of address, truncate or pad */
+-    /* if "::" is at end of ip, then pad another block or two */
+-    while ((l->status & LDAP_IPV6_S) && (s < 32)) {
+-        strncat(l->search_ip, "0000", 4);
+-        s = strlen(l->search_ip);
+-    }
+-    if ((l->status & LDAP_IPV6_S) && (s > 32)) {
+-        /* Too long, truncate */
+-        l->search_ip[32] = '\0';
+-        s = strlen(l->search_ip);
+-    }
+-    /* If at end of ip, and its not long enough, then pad another block or two */
+-    while ((l->status & LDAP_IPV4_S) && (s < 8)) {
+-        strncat(l->search_ip, "00", 2);
+-        s = strlen(l->search_ip);
+-    }
+-    if ((l->status & LDAP_IPV4_S) && (s > 8)) {
+-        /* Too long, truncate */
+-        l->search_ip[8] = '\0';
+-        s = strlen(l->search_ip);
++    size_t s = LDAP_ERR_INVALID;
++    if (struct addrinfo *dst = makeIpBinary(ip)) {
++        if (dst->ai_family == AF_INET6) {
++            struct sockaddr_in6 *sia = reinterpret_cast<struct sockaddr_in6 *>(dst->ai_addr);
++            const char *ia = reinterpret_cast<const char *>(sia->sin6_addr.s6_addr);
++            s = makeHexString(l->search_ip, sizeof(l->search_ip), ia, 16); // IPv6 = 16-byte address
++
++        } else if (dst->ai_family == AF_INET) {
++            struct sockaddr_in *sia = reinterpret_cast<struct sockaddr_in *>(dst->ai_addr);
++            const char *ia = reinterpret_cast<const char *>(&(sia->sin_addr));
++            s = makeHexString(l->search_ip, sizeof(l->search_ip), ia, 4);  // IPv4 = 4-byte address
++        } // else leave s with LDAP_ERR_INVALID value
++        freeaddrinfo(dst);
+     }
+ 
+-    /* Completed, s is length of address in HEX */
+     return s;
+ }
+ 
+@@ -1099,48 +993,42 @@ SearchFilterLDAP(edui_ldap_t *l, char *group)
+     }
+     if (group == NULL) {
+         /* No groupMembership= to add, yay! */
+-        xstrncpy(bufa, "(&", sizeof(bufa));
+-        strncat(bufa, edui_conf.search_filter, strlen(edui_conf.search_filter));
+         /* networkAddress */
+-        snprintf(bufb, sizeof(bufb), "(|(networkAddress=1\\23%s)", bufc);
+         if (l->status & LDAP_IPV4_S) {
+-            int ln = snprintf(bufd, sizeof(bufd), "(networkAddress=8\\23\\00\\00%s)(networkAddress=9\\23\\00\\00%s))", \
+-                              bufc, bufc);
+-            strncat(bufb, bufd, ln);
++            const int ln = snprintf(bufd, sizeof(bufd), "(networkAddress=8\\23\\00\\00%s)(networkAddress=9\\23\\00\\00%s)", bufc, bufc);
++            if (ln < 0 || static_cast<size_t>(ln) >= sizeof(bufd))
++                return LDAP_ERR_OOB;
++
+         } else if (l->status & LDAP_IPV6_S) {
+-            int ln = snprintf(bufd, sizeof(bufd), "(networkAddress=10\\23\\00\\00%s)(networkAddress=11\\23\\00\\00%s))", \
+-                              bufc, bufc);
+-            strncat(bufb, bufd, ln);
+-        } else
+-            strncat(bufb, ")", 1);
+-        strncat(bufa, bufb, strlen(bufb));
+-        strncat(bufa, ")", 1);
++            const int ln = snprintf(bufd, sizeof(bufd), "(networkAddress=10\\23\\00\\00%s)(networkAddress=11\\23\\00\\00%s)", bufc, bufc);
++            if (ln < 0 || static_cast<size_t>(ln) >= sizeof(bufd))
++                return LDAP_ERR_OOB;
++        }
++        const int x = snprintf(bufa, sizeof(bufa), "(&%s(|(networkAddress=1\\23%s)%s))", edui_conf.search_filter, bufc, bufd);
++        if (x < 0 || static_cast<size_t>(x) >= sizeof(bufa))
++            return LDAP_ERR_OOB;
++
+     } else {
+         /* Needs groupMembership= to add... */
+-        xstrncpy(bufa, "(&(&", sizeof(bufa));
+-        strncat(bufa, edui_conf.search_filter, strlen(edui_conf.search_filter));
+         /* groupMembership -- NOTE: Squid *MUST* provide "cn=" from squid.conf */
+-        snprintf(bufg, sizeof(bufg), "(groupMembership=%s", group);
+         if ((l->basedn[0] != '\0') && (strstr(group, l->basedn) == NULL)) {
+-            strncat(bufg, ",", 1);
+-            strncat(bufg, l->basedn, strlen(l->basedn));
++            const int ln = snprintf(bufg, sizeof(bufg), ",%s", l->basedn);
++            if (ln < 0 || static_cast<size_t>(ln) >= sizeof(bufd))
++                return LDAP_ERR_OOB;
+         }
+-        strncat(bufg, ")", 1);
+-        strncat(bufa, bufg, strlen(bufg));
+         /* networkAddress */
+-        snprintf(bufb, sizeof(bufb), "(|(networkAddress=1\\23%s)", bufc);
+         if (l->status & LDAP_IPV4_S) {
+-            int ln = snprintf(bufd, sizeof(bufd), "(networkAddress=8\\23\\00\\00%s)(networkAddress=9\\23\\00\\00%s))", \
+-                              bufc, bufc);
+-            strncat(bufb, bufd, ln);
++            const int ln = snprintf(bufd, sizeof(bufd), "(networkAddress=8\\23\\00\\00%s)(networkAddress=9\\23\\00\\00%s)", bufc, bufc);
++            if (ln < 0 || static_cast<size_t>(ln) >= sizeof(bufd))
++                return LDAP_ERR_OOB;
+         } else if (l->status & LDAP_IPV6_S) {
+-            int ln = snprintf(bufd, sizeof(bufd), "(networkAddress=10\\23\\00\\00%s)(networkAddress=11\\23\\00\\00%s))", \
+-                              bufc, bufc);
+-            strncat(bufb, bufd, ln);
+-        } else
+-            strncat(bufb, ")", 1);
+-        strncat(bufa, bufb, strlen(bufb));
+-        strncat(bufa, "))", 2);
++            const int ln = snprintf(bufd, sizeof(bufd), "(networkAddress=10\\23\\00\\00%s)(networkAddress=11\\23\\00\\00%s)", bufc, bufc);
++            if (ln < 0 || static_cast<size_t>(ln) >= sizeof(bufd))
++                return LDAP_ERR_OOB;
++        }
++        const int x = snprintf(bufa, sizeof(bufa), "(&(&%s(groupMembership=%s%s)(|(networkAddress=1\\23%s)%s)))", edui_conf.search_filter, group, bufg, bufc, bufd);
++        if (x < 0 || static_cast<size_t>(x) >= sizeof(bufa))
++            return LDAP_ERR_OOB;
+     }
+     s = strlen(bufa);
+     xstrncpy(l->search_filter, bufa, sizeof(l->search_filter));
+@@ -1212,10 +1100,10 @@ static int
+ SearchIPLDAP(edui_ldap_t *l)
+ {
+     ber_len_t i, x;
+-    ber_len_t j, k;
+-    ber_len_t y, z;
+-    int c;
+-    char bufa[EDUI_MAXLEN], bufb[EDUI_MAXLEN], hexc[4];
++    ber_len_t j;
++    ber_len_t z;
++    char bufa[EDUI_MAXLEN];
++    char bufb[EDUI_MAXLEN];
+     LDAPMessage *ent;
+     if (l == NULL) return LDAP_ERR_NULL;
+     if (l->lp == NULL) return LDAP_ERR_POINTER;
+@@ -1273,19 +1161,11 @@ SearchIPLDAP(edui_ldap_t *l)
+                         /* bufa is the address, just compare it */
+                         if (!(l->status & LDAP_IPV4_S) || (l->status & LDAP_IPV6_S))
+                             break;                          /* Not looking for IPv4 */
+-                        for (k = 0; k < z; ++k) {
+-                            c = (int) bufa[k];
+-                            if (c < 0)
+-                                c = c + 256;
+-                            int hlen = snprintf(hexc, sizeof(hexc), "%02X", c);
+-                            if (k == 0)
+-                                xstrncpy(bufb, hexc, sizeof(bufb));
+-                            else
+-                                strncat(bufb, hexc, hlen);
+-                        }
+-                        y = strlen(bufb);
++                        const int blen = makeHexString(bufb, sizeof(bufb), bufa, z);
++                        if (blen < 0)
++                            return blen;
+                         /* Compare value with IP */
+-                        if (memcmp(l->search_ip, bufb, y) == 0) {
++                        if (memcmp(l->search_ip, bufb, blen) == 0) {
+                             /* We got a match! - Scan 'ber' for 'cn' values */
+                             z = ldap_count_values_len(ber);
+                             for (j = 0; j < z; ++j) {
+@@ -1308,19 +1188,11 @@ SearchIPLDAP(edui_ldap_t *l)
+                         /* bufa + 2 is the address (skip 2 digit port) */
+                         if (!(l->status & LDAP_IPV4_S) || (l->status & LDAP_IPV6_S))
+                             break;                          /* Not looking for IPv4 */
+-                        for (k = 2; k < z; ++k) {
+-                            c = (int) bufa[k];
+-                            if (c < 0)
+-                                c = c + 256;
+-                            int hlen = snprintf(hexc, sizeof(hexc), "%02X", c);
+-                            if (k == 2)
+-                                xstrncpy(bufb, hexc, sizeof(bufb));
+-                            else
+-                                strncat(bufb, hexc, hlen);
+-                        }
+-                        y = strlen(bufb);
++                        const int blen = makeHexString(bufb, sizeof(bufb), &bufa[2], z);
++                        if (blen < 0)
++                            return blen;
+                         /* Compare value with IP */
+-                        if (memcmp(l->search_ip, bufb, y) == 0) {
++                        if (memcmp(l->search_ip, bufb, blen) == 0) {
+                             /* We got a match! - Scan 'ber' for 'cn' values */
+                             z = ldap_count_values_len(ber);
+                             for (j = 0; j < z; ++j) {
+@@ -1343,19 +1215,11 @@ SearchIPLDAP(edui_ldap_t *l)
+                         /* bufa + 2 is the address (skip 2 digit port) */
+                         if (!(l->status & LDAP_IPV6_S))
+                             break;                          /* Not looking for IPv6 */
+-                        for (k = 2; k < z; ++k) {
+-                            c = (int) bufa[k];
+-                            if (c < 0)
+-                                c = c + 256;
+-                            int hlen = snprintf(hexc, sizeof(hexc), "%02X", c);
+-                            if (k == 2)
+-                                xstrncpy(bufb, hexc, sizeof(bufb));
+-                            else
+-                                strncat(bufb, hexc, hlen);
+-                        }
+-                        y = strlen(bufb);
++                        const int blen = makeHexString(bufb, sizeof(bufb), &bufa[2], z);
++                        if (blen < 0)
++                            return blen;
+                         /* Compare value with IP */
+-                        if (memcmp(l->search_ip, bufb, y) == 0) {
++                        if (memcmp(l->search_ip, bufb, blen) == 0) {
+                             /* We got a match! - Scan 'ber' for 'cn' values */
+                             z = ldap_count_values_len(ber);
+                             for (j = 0; j < z; ++j) {
diff --git a/meta-openembedded/meta-networking/recipes-daemons/squid/files/0001-SquidNew-use-noexcept-instead-of-throw-for-C-11-comp.patch b/meta-openembedded/meta-networking/recipes-daemons/squid/files/0001-SquidNew-use-noexcept-instead-of-throw-for-C-11-comp.patch
deleted file mode 100644
index f482f80..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/squid/files/0001-SquidNew-use-noexcept-instead-of-throw-for-C-11-comp.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-From 27e10667bf27baf5f119a791e3473bb9435a786a Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 23 Apr 2017 10:28:28 -0700
-Subject: [PATCH] SquidNew: use noexcept instead of throw for C++11 compilers
-
-Fixes errors with gcc7 which is more pedantic about c++11
-conformance regarding deprecated features
-
-include/SquidNew.h:21:51: error: dynamic exception specifications are deprecated in C++11
-_SQUID_EXTERNNEW_ void *operator new[] (size_t size) throw (std::bad_alloc)
-                                                       ^~~~~
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
----
- include/SquidNew.h | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/include/SquidNew.h b/include/SquidNew.h
-index 39fcee0..c960347 100644
---- a/include/SquidNew.h
-+++ b/include/SquidNew.h
-@@ -18,19 +18,19 @@
-  */
- #include <new>
- 
--_SQUID_EXTERNNEW_ void *operator new(size_t size) throw (std::bad_alloc)
-+_SQUID_EXTERNNEW_ void *operator new(size_t size) noexcept(false)
- {
-     return xmalloc(size);
- }
--_SQUID_EXTERNNEW_ void operator delete (void *address) throw()
-+_SQUID_EXTERNNEW_ void operator delete (void *address) noexcept(true)
- {
-     xfree(address);
- }
--_SQUID_EXTERNNEW_ void *operator new[] (size_t size) throw (std::bad_alloc)
-+_SQUID_EXTERNNEW_ void *operator new[] (size_t size) noexcept(false)
- {
-     return xmalloc(size);
- }
--_SQUID_EXTERNNEW_ void operator delete[] (void *address) throw()
-+_SQUID_EXTERNNEW_ void operator delete[] (void *address) noexcept(true)
- {
-     xfree(address);
- }
diff --git a/meta-openembedded/meta-networking/recipes-daemons/squid/files/0002-smblib-fix-buffer-over-read.patch b/meta-openembedded/meta-networking/recipes-daemons/squid/files/0002-smblib-fix-buffer-over-read.patch
new file mode 100644
index 0000000..c8f0c47
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/squid/files/0002-smblib-fix-buffer-over-read.patch
@@ -0,0 +1,39 @@
+From a6b1e0fd14311587186e40d09bff5c8c3aada2e4 Mon Sep 17 00:00:00 2001
+From: Amos Jeffries <squid3@treenet.co.nz>
+Date: Sat, 25 Jul 2015 05:53:16 -0700
+Subject: [PATCH] smblib: fix buffer over-read
+
+When parsing SMB LanManager packets with invalid protocol ID and the
+default set of Squid supported protocols. It may access memory outside
+the buffer storing protocol names.
+
+smblib is only used by already deprecated helpers which are deprecated
+due to far more significant NTLM protocol issues. It will also only
+result in packets being rejected later with invalid protocol names. So
+this is a minor bug rather than a vulnerability.
+
+ Detected by Coverity Scan. Issue 1256165
+---
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Backport
+
+ lib/smblib/smblib-util.c | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+diff --git a/lib/smblib/smblib-util.c b/lib/smblib/smblib-util.c
+index 6139ae2..e722cbb 100644
+--- a/lib/smblib/smblib-util.c
++++ b/lib/smblib/smblib-util.c
+@@ -204,7 +204,11 @@ int SMB_Figure_Protocol(const char *dialects[], int prot_index)
+ {
+     int i;
+ 
+-    if (dialects == SMB_Prots) { /* The jobs is easy, just index into table */
++    // prot_index may be a value outside the table SMB_Types[]
++    // which holds data at offsets 0 to 11
++    int ourType = (prot_index < 0 || prot_index > 11);
++
++    if (ourType && dialects == SMB_Prots) { /* The jobs is easy, just index into table */
+ 
+         return(SMB_Types[prot_index]);
+     } else { /* Search through SMB_Prots looking for a match */
diff --git a/meta-openembedded/meta-networking/recipes-daemons/squid/files/gcc7-fixes.patch b/meta-openembedded/meta-networking/recipes-daemons/squid/files/gcc7-fixes.patch
deleted file mode 100644
index 2feca49..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/squid/files/gcc7-fixes.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-From 660fce9cfa00a57e5b7cec46116a31e21595c306 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 19 Jun 2017 23:47:01 -0700
-Subject: [PATCH] squid: Upgrade to 3.5.26
-
-../../squid-3.5.26/src/DiskIO/DiskThreads/aiops.cc: In function 'void squidaio_init()':                                                              ../../squid-3.5.26/src/DiskIO/DiskThreads/DiskThreads.h:30:50: error: '*' in boolean context, suggest '&&' instead [-Werror=int-in-bool-context]      #define NUMTHREADS (Config.cacheSwap.n_configured*16)
-
-Upstream-Status: Backport
-
----
- src/DiskIO/DiskThreads/aiops.cc | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/DiskIO/DiskThreads/aiops.cc b/src/DiskIO/DiskThreads/aiops.cc
-index b44adfa..e11f948 100644
---- a/src/DiskIO/DiskThreads/aiops.cc
-+++ b/src/DiskIO/DiskThreads/aiops.cc
-@@ -290,7 +290,7 @@ squidaio_init(void)
-     /* Create threads and get them to sit in their wait loop */
-     squidaio_thread_pool = memPoolCreate("aio_thread", sizeof(squidaio_thread_t));
- 
--    assert(NUMTHREADS);
-+    assert(NUMTHREADS != 0);
- 
-     for (i = 0; i < NUMTHREADS; ++i) {
-         threadp = (squidaio_thread_t *)squidaio_thread_pool->alloc();
diff --git a/meta-openembedded/meta-networking/recipes-daemons/squid/squid_3.5.26.bb b/meta-openembedded/meta-networking/recipes-daemons/squid/squid_3.5.26.bb
deleted file mode 100644
index 3ee96ab..0000000
--- a/meta-openembedded/meta-networking/recipes-daemons/squid/squid_3.5.26.bb
+++ /dev/null
@@ -1,114 +0,0 @@
-SUMMARY = "A fully-featured http proxy and web-cache daemon for Linux"
-DESCRIPTION = "A fully-featured http proxy and web-cache daemon for Linux. \
-Squid offers a rich access control, authorization and logging environment to \
-develop web proxy and content serving applications. \
-Squid offers a rich set of traffic optimization options, most of which are \
-enabled by default for simpler installation and high performance. \
-"
-HOMEPAGE = "http://www.squid-cache.org"
-SECTION = "web"
-LICENSE = "GPLv2+"
-
-MAJ_VER = "${@oe.utils.trim_version("${PV}", 1)}"
-MIN_VER = "${@oe.utils.trim_version("${PV}", 2)}"
-
-SRC_URI = "http://www.squid-cache.org/Versions/v${MAJ_VER}/${MIN_VER}/${BPN}-${PV}.tar.bz2 \
-           file://Set-up-for-cross-compilation.patch \
-           file://Skip-AC_RUN_IFELSE-tests.patch \
-           file://Fix-flawed-dynamic-ldb-link-test-in-configure.patch \
-           file://squid-use-serial-tests-config-needed-by-ptest.patch \
-           file://run-ptest \
-           file://volatiles.03_squid \
-           file://set_sysroot_patch.patch \
-           file://squid-don-t-do-squid-conf-tests-at-build-time.patch \
-           file://0001-SquidNew-use-noexcept-instead-of-throw-for-C-11-comp.patch \
-           file://0001-configure-Check-for-Wno-error-format-truncation-comp.patch \
-           file://gcc7-fixes.patch \
-           file://0001-tools.cc-fixed-unused-result-warning.patch \
-           "
-
-SRC_URI_remove_toolchain-clang = "file://0001-configure-Check-for-Wno-error-format-truncation-comp.patch"
-
-SRC_URI[md5sum] = "dc1830cd361e077814aa39bcc3691d8b"
-SRC_URI[sha256sum] = "41d8845863dcd026c856508cd1599d417c8947ffd96e86e24085f9893cb8b8c2"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=c492e2d6d32ec5c1aad0e0609a141ce9 \
-                    file://errors/COPYRIGHT;md5=8861130fae91400bcf99b66f133172b3 \
-                   "
-DEPENDS = "libtool krb5 openldap db cyrus-sasl openssl expat libxml2"
-
-inherit autotools pkgconfig useradd ptest perlnative
-
-USERADD_PACKAGES = "${PN}"
-USERADD_PARAM_${PN} = "--system --no-create-home --home-dir /var/run/squid --shell /bin/false --user-group squid"
-
-PACKAGECONFIG ??= "${@bb.utils.contains('TARGET_ARCH', 'powerpc', 'noatomics', '', d)} \
-                   ${@bb.utils.contains('TARGET_ARCH', 'mips', 'noatomics', '', d)} \
-                   ${@bb.utils.contains('TARGET_ARCH', 'mipsel', 'noatomics', '', d)} \
-                   ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} \
-                  "
-PACKAGECONFIG[libnetfilter-conntrack] = "--with-netfilter-conntrack=${includedir}, --without-netfilter-conntrack, libnetfilter-conntrack"
-PACKAGECONFIG[noatomics] = "squid_cv_gnu_atomics=no,squid_cv_gnu_atomics=yes,,"
-PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
-
-BASIC_AUTH = "DB SASL LDAP"
-
-DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)}"
-BASIC_AUTH += "${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'PAM', '', d)}"
-
-EXTRA_OECONF += "--with-default-user=squid --enable-auth-basic='${BASIC_AUTH}' \
-                 --sysconfdir=${sysconfdir}/${BPN} \
-                 --with-logdir=${localstatedir}/log/${BPN} \
-                 'PERL=${USRBINPATH}/env perl'"
-
-export BUILDCXXFLAGS="${BUILD_CXXFLAGS}"
-
-TESTDIR = "test-suite"
-
-do_configure_prepend() {
-    export SYSROOT=$PKG_CONFIG_SYSROOT_DIR
-}
-
-do_compile_ptest() {
-    oe_runmake -C ${TESTDIR} buildtest-TESTS
-}
-
-do_install_ptest() {
-    cp -rf ${B}/${TESTDIR} ${D}${PTEST_PATH}
-    cp -rf ${S}/${TESTDIR} ${D}${PTEST_PATH}
-
-    # do NOT need to rebuild Makefile itself
-    sed -i 's/^Makefile:.*$/Makefile:/' ${D}${PTEST_PATH}/${TESTDIR}/Makefile
-
-    # Add squid-conf-tests for runtime tests
-    sed -e 's/^\(runtest-TESTS:\)/\1 squid-conf-tests/' \
-        -e "s/\(list=' \$(TESTS)\)/\1 squid-conf-tests/" \
-        -i ${D}${PTEST_PATH}/${TESTDIR}/Makefile
-
-    # Ensure the path for command true is correct
-    sed -i 's:^TRUE = .*$:TRUE = /bin/true:' ${D}${PTEST_PATH}/${TESTDIR}/Makefile
-}
-
-do_install_append() {
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-        install -d ${D}${sysconfdir}/tmpfiles.d
-        echo "d ${localstatedir}/run/${BPN} 0755 squid squid -" >> ${D}${sysconfdir}/tmpfiles.d/${BPN}.conf
-        echo "d ${localstatedir}/log/${BPN} 0750 squid squid -" >> ${D}${sysconfdir}/tmpfiles.d/${BPN}.conf
-    fi
-
-    install -d ${D}${sysconfdir}/default/volatiles
-    install -m 0644 ${WORKDIR}/volatiles.03_squid ${D}${sysconfdir}/default/volatiles/03_squid
-
-    rmdir "${D}${localstatedir}/run/${BPN}"
-    rmdir --ignore-fail-on-non-empty "${D}${localstatedir}/run"
-
-    rmdir "${D}${localstatedir}/log/${BPN}"
-    rmdir --ignore-fail-on-non-empty "${D}${localstatedir}/log"
-}
-
-FILES_${PN} += "${libdir} ${datadir}/errors ${datadir}/icons"
-FILES_${PN}-dbg += "/usr/src/debug"
-FILES_${PN}-doc += "${datadir}/*.txt"
-
-RDEPENDS_${PN} += "perl"
-RDEPENDS_${PN}-ptest += "make"
diff --git a/meta-openembedded/meta-networking/recipes-daemons/squid/squid_3.5.27.bb b/meta-openembedded/meta-networking/recipes-daemons/squid/squid_3.5.27.bb
new file mode 100644
index 0000000..1557c4b
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-daemons/squid/squid_3.5.27.bb
@@ -0,0 +1,115 @@
+SUMMARY = "A fully-featured http proxy and web-cache daemon for Linux"
+DESCRIPTION = "A fully-featured http proxy and web-cache daemon for Linux. \
+Squid offers a rich access control, authorization and logging environment to \
+develop web proxy and content serving applications. \
+Squid offers a rich set of traffic optimization options, most of which are \
+enabled by default for simpler installation and high performance. \
+"
+HOMEPAGE = "http://www.squid-cache.org"
+SECTION = "web"
+LICENSE = "GPLv2+"
+
+MAJ_VER = "${@oe.utils.trim_version("${PV}", 1)}"
+MIN_VER = "${@oe.utils.trim_version("${PV}", 2)}"
+
+SRC_URI = "http://www.squid-cache.org/Versions/v${MAJ_VER}/${MIN_VER}/${BPN}-${PV}.tar.bz2 \
+           file://Set-up-for-cross-compilation.patch \
+           file://Skip-AC_RUN_IFELSE-tests.patch \
+           file://Fix-flawed-dynamic-ldb-link-test-in-configure.patch \
+           file://squid-use-serial-tests-config-needed-by-ptest.patch \
+           file://run-ptest \
+           file://volatiles.03_squid \
+           file://set_sysroot_patch.patch \
+           file://squid-don-t-do-squid-conf-tests-at-build-time.patch \
+           file://0001-configure-Check-for-Wno-error-format-truncation-comp.patch \
+           file://0001-tools.cc-fixed-unused-result-warning.patch \
+           file://0001-Bug-4843-pt1-ext_edirectory_userip_acl-refactoring-f.patch \
+           file://0002-smblib-fix-buffer-over-read.patch \
+           "
+
+SRC_URI_remove_toolchain-clang = "file://0001-configure-Check-for-Wno-error-format-truncation-comp.patch"
+
+SRC_URI[md5sum] = "c17a3ed3a40cd59c23f48b8539dafcd8"
+SRC_URI[sha256sum] = "467da134eaf0f7962ba5881793d106772fb05fefa4aea7d9569eec0412c52433"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=c492e2d6d32ec5c1aad0e0609a141ce9 \
+                    file://errors/COPYRIGHT;md5=8861130fae91400bcf99b66f133172b3 \
+                   "
+DEPENDS = "libtool krb5 openldap db cyrus-sasl openssl expat libxml2"
+
+inherit autotools pkgconfig useradd ptest perlnative
+
+USERADD_PACKAGES = "${PN}"
+USERADD_PARAM_${PN} = "--system --no-create-home --home-dir /var/run/squid --shell /bin/false --user-group squid"
+
+PACKAGECONFIG ??= "${@bb.utils.contains('TARGET_ARCH', 'powerpc', 'noatomics', '', d)} \
+                   ${@bb.utils.contains('TARGET_ARCH', 'mips', 'noatomics', '', d)} \
+                   ${@bb.utils.contains('TARGET_ARCH', 'mipsel', 'noatomics', '', d)} \
+                   ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} \
+                  "
+PACKAGECONFIG[libnetfilter-conntrack] = "--with-netfilter-conntrack=${includedir}, --without-netfilter-conntrack, libnetfilter-conntrack"
+PACKAGECONFIG[noatomics] = "squid_cv_gnu_atomics=no,squid_cv_gnu_atomics=yes,,"
+PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
+PACKAGECONFIG[werror] = "--enable-strict-error-checking,--disable-strict-error-checking,"
+
+BASIC_AUTH = "DB SASL LDAP"
+
+DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)}"
+BASIC_AUTH += "${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'PAM', '', d)}"
+
+EXTRA_OECONF += "--with-default-user=squid --enable-auth-basic='${BASIC_AUTH}' \
+                 --sysconfdir=${sysconfdir}/${BPN} \
+                 --with-logdir=${localstatedir}/log/${BPN} \
+                 'PERL=${USRBINPATH}/env perl'"
+
+export BUILDCXXFLAGS="${BUILD_CXXFLAGS}"
+
+TESTDIR = "test-suite"
+
+do_configure_prepend() {
+    export SYSROOT=$PKG_CONFIG_SYSROOT_DIR
+}
+
+do_compile_ptest() {
+    oe_runmake -C ${TESTDIR} buildtest-TESTS
+}
+
+do_install_ptest() {
+    cp -rf ${B}/${TESTDIR} ${D}${PTEST_PATH}
+    cp -rf ${S}/${TESTDIR} ${D}${PTEST_PATH}
+
+    # do NOT need to rebuild Makefile itself
+    sed -i 's/^Makefile:.*$/Makefile:/' ${D}${PTEST_PATH}/${TESTDIR}/Makefile
+
+    # Add squid-conf-tests for runtime tests
+    sed -e 's/^\(runtest-TESTS:\)/\1 squid-conf-tests/' \
+        -e "s/\(list=' \$(TESTS)\)/\1 squid-conf-tests/" \
+        -i ${D}${PTEST_PATH}/${TESTDIR}/Makefile
+
+    # Ensure the path for command true is correct
+    sed -i 's:^TRUE = .*$:TRUE = /bin/true:' ${D}${PTEST_PATH}/${TESTDIR}/Makefile
+}
+
+do_install_append() {
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+        install -d ${D}${sysconfdir}/tmpfiles.d
+        echo "d ${localstatedir}/run/${BPN} 0755 squid squid -" >> ${D}${sysconfdir}/tmpfiles.d/${BPN}.conf
+        echo "d ${localstatedir}/log/${BPN} 0750 squid squid -" >> ${D}${sysconfdir}/tmpfiles.d/${BPN}.conf
+    fi
+
+    install -d ${D}${sysconfdir}/default/volatiles
+    install -m 0644 ${WORKDIR}/volatiles.03_squid ${D}${sysconfdir}/default/volatiles/03_squid
+
+    rmdir "${D}${localstatedir}/run/${BPN}"
+    rmdir --ignore-fail-on-non-empty "${D}${localstatedir}/run"
+
+    rmdir "${D}${localstatedir}/log/${BPN}"
+    rmdir --ignore-fail-on-non-empty "${D}${localstatedir}/log"
+}
+
+FILES_${PN} += "${libdir} ${datadir}/errors ${datadir}/icons"
+FILES_${PN}-dbg += "/usr/src/debug"
+FILES_${PN}-doc += "${datadir}/*.txt"
+
+RDEPENDS_${PN} += "perl"
+RDEPENDS_${PN}-ptest += "make"
diff --git a/meta-openembedded/meta-networking/recipes-daemons/vblade/vblade_22.bb b/meta-openembedded/meta-networking/recipes-daemons/vblade/vblade_22.bb
index d7b1dfa..a51a8c3 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/vblade/vblade_22.bb
+++ b/meta-openembedded/meta-networking/recipes-daemons/vblade/vblade_22.bb
@@ -16,6 +16,8 @@
 SRC_URI[md5sum] = "510d98ba0f231284a5fbe2da11cb2d6e"
 SRC_URI[sha256sum] = "a990378f273f10eb431e42954a871aed52714035bbab28c54cef600c458356bb"
 
+UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/aoetools/files/vblade/"
+
 inherit autotools-brokensep update-rc.d systemd
 
 do_install() {
diff --git a/meta-openembedded/meta-networking/recipes-daemons/vsftpd/vsftpd_3.0.3.bb b/meta-openembedded/meta-networking/recipes-daemons/vsftpd/vsftpd_3.0.3.bb
index 7a20356..2e3e0e8 100644
--- a/meta-openembedded/meta-networking/recipes-daemons/vsftpd/vsftpd_3.0.3.bb
+++ b/meta-openembedded/meta-networking/recipes-daemons/vsftpd/vsftpd_3.0.3.bb
@@ -24,6 +24,9 @@
            file://0001-sysdeputil.c-Fix-with-musl-which-does-not-have-utmpx.patch \
            "
 
+UPSTREAM_CHECK_URI = "${DEBIAN_MIRROR}/main/v/vsftpd/"
+UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)\.orig\.tar"
+
 LIC_FILES_CHKSUM = "file://COPYING;md5=a6067ad950b28336613aed9dd47b1271 \
                         file://COPYRIGHT;md5=04251b2eb0f298dae376d92454f6f72e \
                         file://LICENSE;md5=654df2042d44b8cac8a5654fc5be63eb"
@@ -44,7 +47,7 @@
 
 CONFFILES_${PN} = "${sysconfdir}/vsftpd.conf"
 LDFLAGS_append =" -lcrypt -lcap"
-
+CFLAGS_append_libc-musl = " -D_GNU_SOURCE -include fcntl.h"
 EXTRA_OEMAKE = "-e MAKEFLAGS="
 
 do_configure() {
diff --git a/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc/0001-CMakeLists.txt-Fix-grpc_cpp_plugin-path-during-cross.patch b/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc/0001-CMakeLists.txt-Fix-grpc_cpp_plugin-path-during-cross.patch
index 5774e62..54e0b99 100644
--- a/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc/0001-CMakeLists.txt-Fix-grpc_cpp_plugin-path-during-cross.patch
+++ b/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc/0001-CMakeLists.txt-Fix-grpc_cpp_plugin-path-during-cross.patch
@@ -1,34 +1,36 @@
-From cc6dbabea0e452ebc93682df860a79ed9a45722e Mon Sep 17 00:00:00 2001
+From 6d606f1101c1a172fb6d738d6f1865aa61849e68 Mon Sep 17 00:00:00 2001
 From: Alexey Firago <alexey_firago@mentor.com>
 Date: Fri, 20 Oct 2017 00:04:19 +0300
 Subject: [PATCH] CMakeLists.txt: Fix grpc_cpp_plugin path during
- cross-compilation
+ cross-compiling or native build
 
 Signed-off-by: Alexey Firago <alexey_firago@mentor.com>
+Signed-off-by: Hiram Lew <lew@avast.com>
+Signed-off-by: Jan Kaisrlik <jan.kaisrlik@avast.com>
 ---
  CMakeLists.txt                    | 9 ++++++++-
  templates/CMakeLists.txt.template | 9 ++++++++-
  2 files changed, 16 insertions(+), 2 deletions(-)
 
 diff --git a/CMakeLists.txt b/CMakeLists.txt
-index f9cd630..9663934 100644
+index a59fd81..cd90424 100644
 --- a/CMakeLists.txt
 +++ b/CMakeLists.txt
-@@ -328,6 +328,13 @@ function(protobuf_generate_grpc_cpp)
+@@ -160,6 +160,13 @@ function(protobuf_generate_grpc_cpp)
      return()
    endif()
-
-+  #if cross-compiling, find host plugin
+ 
++  #if cross-compiling or nativesdk, find host plugin
 +  if(CMAKE_CROSSCOMPILING)
 +      find_program(gRPC_CPP_PLUGIN grpc_cpp_plugin)
 +  else()
 +      set(gRPC_CPP_PLUGIN $<TARGET_FILE:grpc_cpp_plugin>)
 +  endif()
 +
-   set(_protobuf_include_path -I . -I ${PROTOBUF_WELLKNOWN_IMPORT_DIR})
+   set(_protobuf_include_path -I . -I ${_gRPC_PROTOBUF_WELLKNOWN_INCLUDE_DIR})
    foreach(FIL ${ARGN})
      get_filename_component(ABS_FIL ${FIL} ABSOLUTE)
-@@ -345,7 +352,7 @@ function(protobuf_generate_grpc_cpp)
+@@ -177,7 +184,7 @@ function(protobuf_generate_grpc_cpp)
        COMMAND ${_gRPC_PROTOBUF_PROTOC_EXECUTABLE}
        ARGS --grpc_out=generate_mock_code=true:${_gRPC_PROTO_GENS_DIR}
             --cpp_out=${_gRPC_PROTO_GENS_DIR}
@@ -38,24 +40,24 @@
             ${REL_FIL}
        DEPENDS ${ABS_FIL} ${_gRPC_PROTOBUF_PROTOC} grpc_cpp_plugin
 diff --git a/templates/CMakeLists.txt.template b/templates/CMakeLists.txt.template
-index 64daf04..a7e8629 100644
+index de13d02..b22bd5c 100644
 --- a/templates/CMakeLists.txt.template
 +++ b/templates/CMakeLists.txt.template
-@@ -373,6 +373,13 @@
+@@ -209,6 +209,13 @@
        return()
      endif()
-
-+    #if cross-compiling, find host plugin
+ 
++    #if cross-compiling or nativesdk, find host plugin
 +    if(CMAKE_CROSSCOMPILING)
 +        find_program(gRPC_CPP_PLUGIN grpc_cpp_plugin)
 +    else()
 +        set(gRPC_CPP_PLUGIN $<TARGET_FILE:grpc_cpp_plugin>)
 +    endif()
 +
-     set(_protobuf_include_path -I . -I <%text>${PROTOBUF_WELLKNOWN_IMPORT_DIR}</%text>)
+     set(_protobuf_include_path -I . -I <%text>${_gRPC_PROTOBUF_WELLKNOWN_INCLUDE_DIR}</%text>)
      foreach(FIL <%text>${ARGN}</%text>)
        get_filename_component(ABS_FIL <%text>${FIL}</%text> ABSOLUTE)
-@@ -390,7 +397,7 @@
+@@ -226,7 +233,7 @@
          COMMAND <%text>${_gRPC_PROTOBUF_PROTOC_EXECUTABLE}</%text>
          ARGS --grpc_out=<%text>generate_mock_code=true:${_gRPC_PROTO_GENS_DIR}</%text>
               --cpp_out=<%text>${_gRPC_PROTO_GENS_DIR}</%text>
@@ -64,5 +66,6 @@
               <%text>${_protobuf_include_path}</%text>
               <%text>${REL_FIL}</%text>
          DEPENDS <%text>${ABS_FIL}</%text> <%text>${_gRPC_PROTOBUF_PROTOC}</%text> grpc_cpp_plugin
---
+-- 
 2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc/0001-CMakeLists.txt-Fix-libraries-installation-for-Linux.patch b/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc/0001-CMakeLists.txt-Fix-libraries-installation-for-Linux.patch
index f8d9652..459dc45 100644
--- a/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc/0001-CMakeLists.txt-Fix-libraries-installation-for-Linux.patch
+++ b/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc/0001-CMakeLists.txt-Fix-libraries-installation-for-Linux.patch
@@ -1,7 +1,7 @@
-From 8e9bf962a45a82f1c2eb5858e29fa89a3a60b564 Mon Sep 17 00:00:00 2001
+From 2279e30be5796e9b185545543ea54fe68633cbdd Mon Sep 17 00:00:00 2001
 From: Alexey Firago <alexey_firago@mentor.com>
 Date: Mon, 30 Oct 2017 23:24:49 +0300
-Subject: [PATCH 1/4] CMakeLists.txt: Fix libraries installation for Linux
+Subject: [PATCH] CMakeLists.txt: Fix libraries installation for Linux
 
 * Set libs versions as in Makefile
 
@@ -9,21 +9,19 @@
 
 %% original patch: 0001-CMakeLists.txt-Fix-libraries-installation-for-Linux.patch
 ---
- CMakeLists.txt                        | 55 +++++++++++++++++++++++++++++++++++
- CMakeLists.txt => CMakeLists.txt.orig |  0
- 2 files changed, 55 insertions(+)
- copy CMakeLists.txt => CMakeLists.txt.orig (100%)
+ CMakeLists.txt | 59 ++++++++++++++++++++++++++++++++++++++++++++++++++
+ 1 file changed, 59 insertions(+)
 
 diff --git a/CMakeLists.txt b/CMakeLists.txt
-index b1a49df..13e64ac 100644
+index a59fd818e3..5066f44a32 100644
 --- a/CMakeLists.txt
 +++ b/CMakeLists.txt
 @@ -30,6 +30,15 @@ set(PACKAGE_TARNAME   "${PACKAGE_NAME}-${PACKAGE_VERSION}")
  set(PACKAGE_BUGREPORT "https://github.com/grpc/grpc/issues/")
  project(${PACKAGE_NAME} C CXX)
  
-+set (CORE_VERSION_MAJOR "4")
-+set (CORE_VERSION "4.0.0")
++set (CORE_VERSION_MAJOR "6")
++set (CORE_VERSION "6.0.0")
 +
 +set (CPP_VERSION_MAJOR "1")
 +set (CPP_VERSION "${PACKAGE_VERSION}")
@@ -31,10 +29,21 @@
 +set (CSHARP_VERSION_MAJOR "1")
 +set (CSHARP_VERSION "${PACKAGE_VERSION}")
 +
- set(gRPC_INSTALL_BINDIR "${CMAKE_INSTALL_PREFIX}/bin" CACHE PATH "Installation directory for executables")
- set(gRPC_INSTALL_LIBDIR "${CMAKE_INSTALL_PREFIX}/lib" CACHE PATH "Installation directory for libraries")
- set(gRPC_INSTALL_INCLUDEDIR "${CMAKE_INSTALL_PREFIX}/include" CACHE PATH "Installation directory for headers")
-@@ -841,6 +850,10 @@ if(WIN32 AND MSVC)
+ set(gRPC_INSTALL_BINDIR "bin" CACHE STRING "Installation directory for executables")
+ set(gRPC_INSTALL_LIBDIR "lib" CACHE STRING "Installation directory for libraries")
+ set(gRPC_INSTALL_INCLUDEDIR "include" CACHE STRING "Installation directory for headers")
+@@ -702,6 +711,10 @@ if(WIN32 AND MSVC)
+   endif()
+ endif()
+ 
++if(_gRPC_PLATFORM_LINUX)
++  set_property(TARGET address_sorting PROPERTY VERSION ${CORE_VERSION})
++  set_property(TARGET address_sorting PROPERTY SOVERSION ${CORE_VERSION_MAJOR})
++endif()
+ 
+ target_include_directories(address_sorting
+   PUBLIC $<INSTALL_INTERFACE:${gRPC_INSTALL_INCLUDEDIR}> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
+@@ -825,6 +838,10 @@ if(WIN32 AND MSVC)
    endif()
  endif()
  
@@ -45,7 +54,7 @@
  
  target_include_directories(gpr
    PUBLIC $<INSTALL_INTERFACE:${gRPC_INSTALL_INCLUDEDIR}> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
-@@ -1221,6 +1234,10 @@ if(WIN32 AND MSVC)
+@@ -1259,6 +1276,10 @@ if(WIN32 AND MSVC)
    endif()
  endif()
  
@@ -56,7 +65,7 @@
  
  target_include_directories(grpc
    PUBLIC $<INSTALL_INTERFACE:${gRPC_INSTALL_INCLUDEDIR}> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
-@@ -1535,6 +1552,10 @@ if(WIN32 AND MSVC)
+@@ -1633,6 +1654,10 @@ if(WIN32 AND MSVC)
    endif()
  endif()
  
@@ -67,7 +76,7 @@
  
  target_include_directories(grpc_cronet
    PUBLIC $<INSTALL_INTERFACE:${gRPC_INSTALL_INCLUDEDIR}> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
-@@ -2377,6 +2398,10 @@ if(WIN32 AND MSVC)
+@@ -2575,6 +2600,10 @@ if(WIN32 AND MSVC)
    endif()
  endif()
  
@@ -78,7 +87,7 @@
  
  target_include_directories(grpc_unsecure
    PUBLIC $<INSTALL_INTERFACE:${gRPC_INSTALL_INCLUDEDIR}> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
-@@ -2592,6 +2617,10 @@ if(WIN32 AND MSVC)
+@@ -2791,6 +2820,10 @@ if(WIN32 AND MSVC)
    endif()
  endif()
  
@@ -89,7 +98,7 @@
  
  target_include_directories(grpc++
    PUBLIC $<INSTALL_INTERFACE:${gRPC_INSTALL_INCLUDEDIR}> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
-@@ -3078,6 +3107,10 @@ if(WIN32 AND MSVC)
+@@ -3357,6 +3390,10 @@ if(WIN32 AND MSVC)
    endif()
  endif()
  
@@ -100,7 +109,7 @@
  
  target_include_directories(grpc++_cronet
    PUBLIC $<INSTALL_INTERFACE:${gRPC_INSTALL_INCLUDEDIR}> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
-@@ -3282,6 +3315,11 @@ protobuf_generate_grpc_cpp(
+@@ -3630,6 +3667,11 @@ protobuf_generate_grpc_cpp(
    src/proto/grpc/status/status.proto
  )
  
@@ -112,7 +121,7 @@
  target_include_directories(grpc++_error_details
    PUBLIC $<INSTALL_INTERFACE:${gRPC_INSTALL_INCLUDEDIR}> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
    PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}
-@@ -3408,6 +3446,11 @@ protobuf_generate_grpc_cpp(
+@@ -3762,6 +3804,11 @@ protobuf_generate_grpc_cpp(
    src/proto/grpc/reflection/v1alpha/reflection.proto
  )
  
@@ -124,7 +133,7 @@
  target_include_directories(grpc++_reflection
    PUBLIC $<INSTALL_INTERFACE:${gRPC_INSTALL_INCLUDEDIR}> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
    PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}
-@@ -3827,6 +3870,10 @@ if(WIN32 AND MSVC)
+@@ -4265,6 +4312,10 @@ if(WIN32 AND MSVC)
    endif()
  endif()
  
@@ -135,7 +144,7 @@
  
  target_include_directories(grpc++_unsecure
    PUBLIC $<INSTALL_INTERFACE:${gRPC_INSTALL_INCLUDEDIR}> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
-@@ -4140,6 +4187,10 @@ if(WIN32 AND MSVC)
+@@ -4649,6 +4700,10 @@ if(WIN32 AND MSVC)
    endif()
  endif()
  
@@ -146,7 +155,7 @@
  
  target_include_directories(grpc_plugin_support
    PUBLIC $<INSTALL_INTERFACE:${gRPC_INSTALL_INCLUDEDIR}> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
-@@ -4649,6 +4700,10 @@ if(WIN32 AND MSVC)
+@@ -5184,6 +5239,10 @@ if(WIN32 AND MSVC)
    endif()
  endif()
  
@@ -157,10 +166,6 @@
  
  target_include_directories(grpc_csharp_ext
    PUBLIC $<INSTALL_INTERFACE:${gRPC_INSTALL_INCLUDEDIR}> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
-diff --git a/CMakeLists.txt b/CMakeLists.txt.orig
-similarity index 100%
-copy from CMakeLists.txt
-copy to CMakeLists.txt.orig
 -- 
-2.16.1
+2.17.1
 
diff --git a/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc/0004-CMakeLists.txt-Find-c-ares-in-target-sysroot-alone.patch b/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc/0004-CMakeLists.txt-Find-c-ares-in-target-sysroot-alone.patch
deleted file mode 100644
index 8985022..0000000
--- a/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc/0004-CMakeLists.txt-Find-c-ares-in-target-sysroot-alone.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From a498b56ba96948015f0f2784b2ab8296946716ee Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 1 Feb 2018 23:28:17 -0800
-Subject: [PATCH 4/4] CMakeLists.txt: Find c-ares in target sysroot alone
-
-Current code lets it look into native sysroot as well
-which is then preferred during cross compile and it adds
-absolute path to libcares into linker flags
-on heterogenous architectures linker complains and build
-fails
-
-| /mnt/a/oe/build/tmp/work/cortexa7t2hf-neon-vfpv4-bec-linux-gnueabi/grpc/1.8.5-r0/recipe-sysroot-native/usr/lib/lib
-cares.so.2.2.0: file not recognized: File format not recognized
-| collect2: error: ld returned 1 exit status
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- CMakeLists.txt | 6 ++----
- 1 file changed, 2 insertions(+), 4 deletions(-)
-
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 1d7eef1..058423d 100644
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -153,10 +153,8 @@ if("${gRPC_CARES_PROVIDER}" STREQUAL "module")
-     set(gRPC_INSTALL FALSE)
-   endif()
- elseif("${gRPC_CARES_PROVIDER}" STREQUAL "package")
--  find_package(c-ares REQUIRED CONFIG)
--  if(TARGET c-ares::cares)
--    set(_gRPC_CARES_LIBRARIES c-ares::cares)
--  endif()
-+  find_package(c-ares REQUIRED)
-+  set(_gRPC_CARES_LIBRARIES cares)
-   set(_gRPC_FIND_CARES "if(NOT c-ares_FOUND)\n  find_package(c-ares CONFIG)\nendif()")
- endif()
- 
--- 
-2.16.1
-
diff --git a/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc_1.14.1.bb b/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc_1.14.1.bb
new file mode 100644
index 0000000..d236714
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc_1.14.1.bb
@@ -0,0 +1,42 @@
+DESCRIPTION = "A high performance, open source, general-purpose RPC framework. \
+Provides gRPC libraries for multiple languages written on top of shared C core library \
+(C++, Node.js, Python, Ruby, Objective-C, PHP, C#)"
+HOMEPAGE = "https://github.com/grpc/grpc"
+SECTION = "libs"
+LICENSE = "Apache-2"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
+
+DEPENDS = "gflags c-ares protobuf protobuf-native protobuf-c protobuf-c-native openssl"
+DEPENDS_append_class-target = " gtest grpc-native "
+DEPENDS_append_class-nativesdk = " grpc-native "
+
+S = "${WORKDIR}/git"
+SRCREV = "d8020cb6daa87f1a3bb3b0c299bc081c4a3de1e8"
+BRANCH = "v1.14.x"
+SRC_URI = "git://github.com/grpc/grpc.git;protocol=https;branch=${BRANCH} \
+           file://0001-CMakeLists.txt-Fix-libraries-installation-for-Linux.patch \
+           "
+SRC_URI_append_class-target = " file://0001-CMakeLists.txt-Fix-grpc_cpp_plugin-path-during-cross.patch"
+SRC_URI_append_class-nativesdk = " file://0001-CMakeLists.txt-Fix-grpc_cpp_plugin-path-during-cross.patch"
+
+# Fixes build with older compilers 4.8 especially on ubuntu 14.04
+CXXFLAGS_append_class-native = " -Wl,--no-as-needed"
+
+inherit cmake
+
+EXTRA_OECMAKE = " \
+    -DgRPC_CARES_PROVIDER=package \
+    -DgRPC_ZLIB_PROVIDER=package \
+    -DgRPC_SSL_PROVIDER=package \
+    -DgRPC_PROTOBUF_PROVIDER=package \
+    -DgRPC_GFLAGS_PROVIDER=package \
+    -DgRPC_INSTALL=ON \
+    -DCMAKE_CROSSCOMPILING=ON \
+    -DBUILD_SHARED_LIBS=ON \
+    "
+
+BBCLASSEXTEND = "native nativesdk"
+
+SYSROOT_DIRS_BLACKLIST_append_class-target = "${libdir}/cmake/grpc"
+
+FILES_${PN}-dev += "${bindir}"
diff --git a/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc_1.8.5.bb b/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc_1.8.5.bb
deleted file mode 100644
index 0883ec1..0000000
--- a/meta-openembedded/meta-networking/recipes-devtools/grpc/grpc_1.8.5.bb
+++ /dev/null
@@ -1,36 +0,0 @@
-DESCRIPTION = "A high performance, open source, general-purpose RPC framework. \
-Provides gRPC libraries for multiple languages written on top of shared C core library \
-(C++, Node.js, Python, Ruby, Objective-C, PHP, C#)"
-HOMEPAGE = "https://github.com/grpc/grpc"
-SECTION = "libs"
-LICENSE = "Apache-2"
-
-DEPENDS = "gflags c-ares protobuf protobuf-native protobuf-c protobuf-c-native openssl"
-DEPENDS_append_class-target = " gtest grpc-native "
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
-
-SRC_URI = "https://github.com/grpc/grpc/archive/v${PV}.tar.gz \
-           file://0001-CMakeLists.txt-Fix-libraries-installation-for-Linux.patch \
-           file://0004-CMakeLists.txt-Find-c-ares-in-target-sysroot-alone.patch \
-           "
-SRC_URI[md5sum] = "b565fa6787e42f4969395870c2ad436e"
-SRC_URI[sha256sum] = "df9168da760fd2ee970c74c9d1b63377e0024be248deaa844e784d0df47599de"
-
-SRC_URI_append_class-target = " file://0001-CMakeLists.txt-Fix-grpc_cpp_plugin-path-during-cross.patch"
-
-inherit cmake
-
-EXTRA_OECMAKE = " \
-    -DgRPC_CARES_PROVIDER=package \
-    -DgRPC_ZLIB_PROVIDER=package \
-    -DgRPC_SSL_PROVIDER=package \
-    -DgRPC_PROTOBUF_PROVIDER=package \
-    -DgRPC_GFLAGS_PROVIDER=package \
-    -DgRPC_INSTALL=1 \
-    -DBUILD_SHARED_LIBS=ON \
-    "
-
-FILES_${PN}-dev += "${libdir}/cmake"
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-networking/recipes-devtools/python/python-ldap_2.4.41.bb b/meta-openembedded/meta-networking/recipes-devtools/python/python-ldap_2.4.41.bb
deleted file mode 100644
index 3dbc8b1..0000000
--- a/meta-openembedded/meta-networking/recipes-devtools/python/python-ldap_2.4.41.bb
+++ /dev/null
@@ -1,29 +0,0 @@
-#
-# Copyright (C) 2012 Wind River Systems, Inc.
-#
-SUMMARY = "Provides a wrapper in Python to LDAP"
-DESCRIPTION = "This module provides access to the LDAP \
-(Lightweight Directory Access Protocol) through Python operations \
-instead of C API. The module mainly acts as a wrapper for the \
-OpenLDAP 2.x libraries. Errors will appear as exceptions."
-
-LICENSE = "PSF"
-HOMEPAGE = "http://www.python-ldap.org/"
-DEPENDS = "python openldap cyrus-sasl"
-
-PYPI_PACKAGE = "python-ldap"
-inherit pypi setuptools
-
-LIC_FILES_CHKSUM = "file://LICENCE;md5=a41c82edffa04912007cae1d20cac555"
-SRC_URI[md5sum] = "18db2d009150ec1864710fea3ed76173"
-SRC_URI[sha256sum] = "6d430ecf040f2fc704ee316d3390cb1f5419c191371e1e131baef54a0e42cef0"
-
-do_configure_prepend() {
-    sed -i -e 's:^library_dirs =.*::' setup.cfg
-    sed -i -e 's:^include_dirs =.*:include_dirs = =/usr/include/sasl/:' setup.cfg
-}
-
-RDEPENDS_${PN} = " \
-    ${PYTHON_PN}-pprint \
-    ${PYTHON_PN}-threading \
-"
diff --git a/meta-openembedded/meta-networking/recipes-devtools/python/python-ldap_2.4.45.bb b/meta-openembedded/meta-networking/recipes-devtools/python/python-ldap_2.4.45.bb
new file mode 100644
index 0000000..dde8a52
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-devtools/python/python-ldap_2.4.45.bb
@@ -0,0 +1,29 @@
+#
+# Copyright (C) 2012 Wind River Systems, Inc.
+#
+SUMMARY = "Provides a wrapper in Python to LDAP"
+DESCRIPTION = "This module provides access to the LDAP \
+(Lightweight Directory Access Protocol) through Python operations \
+instead of C API. The module mainly acts as a wrapper for the \
+OpenLDAP 2.x libraries. Errors will appear as exceptions."
+
+LICENSE = "PSF"
+HOMEPAGE = "http://www.python-ldap.org/"
+DEPENDS = "python openldap cyrus-sasl"
+
+PYPI_PACKAGE = "python-ldap"
+inherit pypi setuptools
+
+LIC_FILES_CHKSUM = "file://LICENCE;md5=36ce9d726d0321b73c1521704d07db1b"
+SRC_URI[md5sum] = "6108e189a44eea8bc7d1cc281c222978"
+SRC_URI[sha256sum] = "824fde180a53772e23edc031c4dd64ac1af4a3eade78f00d9d510937d562f64e"
+
+do_configure_prepend() {
+    sed -i -e 's:^library_dirs =.*::' setup.cfg
+    sed -i -e 's:^include_dirs =.*:include_dirs = =/usr/include/sasl/:' setup.cfg
+}
+
+RDEPENDS_${PN} = " \
+    ${PYTHON_PN}-pprint \
+    ${PYTHON_PN}-threading \
+"
diff --git a/meta-openembedded/meta-networking/recipes-extended/corosync/corosync/corosync.conf b/meta-openembedded/meta-networking/recipes-extended/corosync/corosync/corosync.conf
new file mode 100644
index 0000000..6aef9de
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-extended/corosync/corosync/corosync.conf
@@ -0,0 +1,58 @@
+# Starting point for cluster with pacemaker/openais
+compatibility: none
+
+corosync {
+	 user:  root
+	 group: root
+}
+
+aisexec {
+	with Pacemaker
+	user:  root
+	group: root
+}
+
+service {
+	name: pacemaker
+	ver: 1
+}
+
+totem {
+	version: 2
+	secauth: off
+	threads: 0
+	interface {
+		ringnumber: 0
+		# Cluster network address
+		bindnetaddr: 192.168.10.0
+		# Should be fine in most cases, don't forget to allow
+		# packets for this address/port in netfilter if there
+		# is restrictive policy set for cluster network
+		mcastaddr: 226.94.1.1
+		mcastport: 5405
+	}
+}
+
+logging {
+	fileline: off
+	to_stderr: no
+	to_logfile: yes
+	to_syslog: yes
+	logfile: /var/log/cluster/corosync.log
+	debug: off
+	timestamp: on
+	logger_subsys {
+		subsys: AMF
+		debug: off
+	}
+}
+
+amf {
+	mode: disabled
+}
+
+quorum {
+	# Quorum for the Pacemaker Cluster Resource Manager
+	provider: corosync_votequorum
+	expected_votes: 1
+}
diff --git a/meta-openembedded/meta-networking/recipes-extended/corosync/corosync_2.4.3.bb b/meta-openembedded/meta-networking/recipes-extended/corosync/corosync_2.4.3.bb
deleted file mode 100644
index 9673fa3..0000000
--- a/meta-openembedded/meta-networking/recipes-extended/corosync/corosync_2.4.3.bb
+++ /dev/null
@@ -1,79 +0,0 @@
-SUMMARY = "The Corosync Cluster Engine and Application Programming Interfaces"
-DESCRIPTION = "This package contains the Corosync Cluster Engine Executive, several default \
-APIs and libraries, default configuration files, and an init script."
-HOMEPAGE = "http://corosync.github.io/corosync/"
-
-SECTION = "base"
-
-inherit autotools pkgconfig systemd useradd
-
-SRC_URI = "http://build.clusterlabs.org/corosync/releases/${BP}.tar.gz"
-
-SRC_URI[md5sum] = "bf0ede13018aadc8a046183bc593b0e0"
-SRC_URI[sha256sum] = "b1e7e422e8d2f7af8e5315fa329b1dbd1175fff32efaa55e8054584c80a2c597"
-
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=a85eb4ce24033adb6088dd1d6ffc5e5d"
-
-DEPENDS = "groff-native nss libqb"
-
-SYSTEMD_SERVICE_${PN} = "corosync.service corosync-notifyd.service \
-                         ${@bb.utils.contains('PACKAGECONFIG', 'qdevice', 'corosync-qdevice.service', '', d)} \
-                         ${@bb.utils.contains('PACKAGECONFIG', 'qnetd', 'corosync-qnetd.service', '', d)} \
-"
-SYSTEMD_AUTO_ENABLE = "disable"
-
-INITSCRIPT_NAME = "corosync-daemon"
-
-PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} \
-                   dbus qdevice qnetd snmp \
-"
-
-PACKAGECONFIG[dbus] = "--enable-dbus,--disable-dbus,dbus"
-PACKAGECONFIG[qdevice] = "--enable-qdevices,--disable-qdevices"
-PACKAGECONFIG[qnetd] = "--enable-qnetd,--disable-qnetd"
-PACKAGECONFIG[rdma] = "--enable-rdma,--disable-rdma"
-PACKAGECONFIG[snmp] = "--enable-snmp,--disable-snmp,net-snmp"
-PACKAGECONFIG[systemd] = "--enable-systemd --with-systemddir=${systemd_system_unitdir},--disable-systemd --without-systemddir,systemd"
-
-EXTRA_OECONF = "ac_cv_path_BASHPATH=${base_bindir}/bash ap_cv_cc_pie=no"
-EXTRA_OEMAKE = "tmpfilesdir_DATA="
-
-do_configure_prepend() {
-    ( cd ${S}
-    ${S}/autogen.sh )
-}
-
-do_install_append() {
-    install -d ${D}${sysconfdir}/sysconfig/
-    install -m 0644 ${S}/init/corosync.sysconfig.example ${D}${sysconfdir}/sysconfig/corosync
-    install -m 0644 ${S}/tools/corosync-notifyd.sysconfig.example ${D}${sysconfdir}/sysconfig/corosync-notifyd
-
-    rm -rf "${D}${localstatedir}/run"
-
-    install -d ${D}${sysconfdir}/default/volatiles
-    echo "d root root 0755 ${localstatedir}/log/cluster none" > ${D}${sysconfdir}/default/volatiles/05_corosync
-
-    if [ ${@bb.utils.filter('PACKAGECONFIG', 'qnetd', d)} ]; then
-        chown -R coroqnetd:coroqnetd ${D}${sysconfdir}/${BPN}/qnetd
-        echo "d coroqnetd coroqnetd 0770 /var/run/corosync-qnetd none" >> ${D}${sysconfdir}/default/volatiles/05_corosync
-    fi
-
-    if [ ${@bb.utils.filter('DISTRO_FEATURES','systemd',d)} ]; then
-        install -d ${D}${sysconfdir}/tmpfiles.d
-        echo "d ${localstatedir}/log/cluster - - - -" > ${D}${sysconfdir}/tmpfiles.d/corosync.conf
-
-        if [ ${@bb.utils.filter('PACKAGECONFIG', 'qnetd', d)} ]; then
-            install -m 0644 ${S}/conf/tmpfiles.d/corosync-qnetd.conf ${D}${sysconfdir}/tmpfiles.d
-        fi
-    fi
-}
-
-RDEPENDS_${PN} += "bash ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'sysvinit-pidof', 'procps', d)}"
-
-FILES_${PN}-dbg += "${libexecdir}/lcrso/.debug"
-FILES_${PN}-doc += "${datadir}/snmp/mibs/COROSYNC-MIB.txt"
-
-USERADD_PACKAGES = "${PN}"
-GROUPADD_PARAM_${PN} = "--system coroqnetd"
-USERADD_PARAM_${PN} = "--system -d / -M -s /bin/nologin -c 'User for corosync-qnetd' -g coroqnetd coroqnetd"
diff --git a/meta-openembedded/meta-networking/recipes-extended/corosync/corosync_2.4.4.bb b/meta-openembedded/meta-networking/recipes-extended/corosync/corosync_2.4.4.bb
new file mode 100644
index 0000000..23a3d14
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-extended/corosync/corosync_2.4.4.bb
@@ -0,0 +1,80 @@
+SUMMARY = "The Corosync Cluster Engine and Application Programming Interfaces"
+DESCRIPTION = "This package contains the Corosync Cluster Engine Executive, several default \
+APIs and libraries, default configuration files, and an init script."
+HOMEPAGE = "http://corosync.github.io/corosync/"
+
+SECTION = "base"
+
+inherit autotools pkgconfig systemd useradd
+
+SRC_URI = "http://build.clusterlabs.org/corosync/releases/${BP}.tar.gz \
+           file://corosync.conf \
+          "
+
+SRC_URI[md5sum] = "69db29ff4bc035936946be44fc8be5cd"
+SRC_URI[sha256sum] = "9bd4707bb271df16f8d543ec782eb4c35ec0330b7be696b797da4bd8f058a25d"
+
+UPSTREAM_CHECK_REGEX = "(?P<pver>\d+\.(?!99)\d+(\.\d+)+)"
+
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=a85eb4ce24033adb6088dd1d6ffc5e5d"
+
+DEPENDS = "groff-native nss libqb"
+
+SYSTEMD_SERVICE_${PN} = "corosync.service corosync-notifyd.service \
+                         ${@bb.utils.contains('PACKAGECONFIG', 'qdevice', 'corosync-qdevice.service', '', d)} \
+                         ${@bb.utils.contains('PACKAGECONFIG', 'qnetd', 'corosync-qnetd.service', '', d)} \
+"
+SYSTEMD_AUTO_ENABLE = "disable"
+
+INITSCRIPT_NAME = "corosync-daemon"
+
+PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} \
+                   dbus qdevice qnetd snmp \
+"
+
+PACKAGECONFIG[dbus] = "--enable-dbus,--disable-dbus,dbus"
+PACKAGECONFIG[qdevice] = "--enable-qdevices,--disable-qdevices"
+PACKAGECONFIG[qnetd] = "--enable-qnetd,--disable-qnetd"
+PACKAGECONFIG[rdma] = "--enable-rdma,--disable-rdma"
+PACKAGECONFIG[snmp] = "--enable-snmp,--disable-snmp,net-snmp"
+PACKAGECONFIG[systemd] = "--enable-systemd --with-systemddir=${systemd_system_unitdir},--disable-systemd --without-systemddir,systemd"
+
+EXTRA_OECONF = "ac_cv_path_BASHPATH=${base_bindir}/bash ap_cv_cc_pie=no"
+EXTRA_OEMAKE = "tmpfilesdir_DATA="
+
+do_configure_prepend() {
+    ( cd ${S}
+    ${S}/autogen.sh )
+}
+
+do_install_append() {
+    install -D -m 0644 ${WORKDIR}/corosync.conf ${D}/${sysconfdir}/corosync/corosync.conf.example
+    install -d ${D}${sysconfdir}/sysconfig/
+    install -m 0644 ${S}/init/corosync.sysconfig.example ${D}${sysconfdir}/sysconfig/corosync
+    install -m 0644 ${S}/tools/corosync-notifyd.sysconfig.example ${D}${sysconfdir}/sysconfig/corosync-notifyd
+
+    rm -rf "${D}${localstatedir}/run"
+
+    install -d ${D}${sysconfdir}/default/volatiles
+    echo "d root root 0755 ${localstatedir}/log/cluster none" > ${D}${sysconfdir}/default/volatiles/05_corosync
+
+    if [ ${@bb.utils.filter('PACKAGECONFIG', 'qnetd', d)} ]; then
+        chown -R coroqnetd:coroqnetd ${D}${sysconfdir}/${BPN}/qnetd
+        echo "d coroqnetd coroqnetd 0770 /var/run/corosync-qnetd none" >> ${D}${sysconfdir}/default/volatiles/05_corosync
+    fi
+
+    if [ ${@bb.utils.filter('DISTRO_FEATURES','systemd',d)} ]; then
+        install -d ${D}${sysconfdir}/tmpfiles.d
+        echo "d ${localstatedir}/log/cluster - - - -" > ${D}${sysconfdir}/tmpfiles.d/corosync.conf
+    fi
+}
+
+RDEPENDS_${PN} += "bash ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'sysvinit-pidof', 'procps', d)}"
+
+FILES_${PN}-dbg += "${libexecdir}/lcrso/.debug"
+FILES_${PN}-doc += "${datadir}/snmp/mibs/COROSYNC-MIB.txt"
+
+USERADD_PACKAGES = "${PN}"
+GROUPADD_PARAM_${PN} = "--system coroqnetd"
+USERADD_PARAM_${PN} = "--system -d / -M -s /bin/nologin -c 'User for corosync-qnetd' -g coroqnetd coroqnetd"
diff --git a/meta-openembedded/meta-networking/recipes-extended/dlm/dlm/0001-Include-sys-sysmacros.h-for-major-minor-macros-in-gl.patch b/meta-openembedded/meta-networking/recipes-extended/dlm/dlm/0001-Include-sys-sysmacros.h-for-major-minor-macros-in-gl.patch
new file mode 100644
index 0000000..6f9a0a4
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-extended/dlm/dlm/0001-Include-sys-sysmacros.h-for-major-minor-macros-in-gl.patch
@@ -0,0 +1,41 @@
+From a55ab8a07770296bf6a622df14f2f0445be16327 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 19 Aug 2018 15:58:49 -0700
+Subject: [PATCH] Include sys/sysmacros.h for major/minor macros in glibc 2.25+
+
+sys/sysmacros.h was included though sys/types.h until 2.28
+glibc release removed it therefore it must be included
+explicitly now.
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ dlm_controld/action.c | 2 ++
+ libdlm/libdlm.c       | 1 +
+ 2 files changed, 3 insertions(+)
+
+diff --git a/dlm_controld/action.c b/dlm_controld/action.c
+index 84637f1..2b8ad6c 100644
+--- a/dlm_controld/action.c
++++ b/dlm_controld/action.c
+@@ -8,6 +8,8 @@
+ 
+ #include "dlm_daemon.h"
+ 
++#include <sys/sysmacros.h>
++
+ #include <corosync/corotypes.h>
+ #include <corosync/cmap.h>
+ 
+diff --git a/libdlm/libdlm.c b/libdlm/libdlm.c
+index a9e6195..499eb6a 100644
+--- a/libdlm/libdlm.c
++++ b/libdlm/libdlm.c
+@@ -14,6 +14,7 @@
+ #include <sys/ioctl.h>
+ #include <sys/param.h>
+ #include <sys/stat.h>
++#include <sys/sysmacros.h>
+ #include <stdint.h>
+ #include <stdlib.h>
+ #include <inttypes.h>
diff --git a/meta-openembedded/meta-networking/recipes-extended/dlm/dlm/0001-dlm-fix-compile-error-since-xml2-config-should-not-b.patch b/meta-openembedded/meta-networking/recipes-extended/dlm/dlm/0001-dlm-fix-compile-error-since-xml2-config-should-not-b.patch
new file mode 100644
index 0000000..0a2f31d
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-extended/dlm/dlm/0001-dlm-fix-compile-error-since-xml2-config-should-not-b.patch
@@ -0,0 +1,36 @@
+From 9107f3bd68aef6ae456a3cad664223b4f3d00131 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Tue, 24 Jul 2018 17:04:39 +0800
+Subject: [PATCH] dlm: fix compile error since xml2-config should not be used
+
+xml2-config is disabled, so change Makefile to use pkgconfig
+to find libxml2.
+
+Upstream-Status: Inappropriate
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ fence/Makefile | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/fence/Makefile b/fence/Makefile
+index 77bf0fd..cca0b2c 100644
+--- a/fence/Makefile
++++ b/fence/Makefile
+@@ -30,11 +30,11 @@ BIN_CFLAGS += -D_GNU_SOURCE -O2 -ggdb \
+ 	-fdiagnostics-show-option \
+ 
+ BIN_CFLAGS += -fPIE -DPIE
+-BIN_CFLAGS += `xml2-config --cflags`
++BIN_CFLAGS += `pkg-config libxml-2.0 --cflags`
+ BIN_CFLAGS += -I../include
+ 
+ BIN_LDFLAGS += -Wl,-z,now -Wl,-z,relro -pie
+-BIN_LDFLAGS += `xml2-config --libs`
++BIN_LDFLAGS += `pkg-config libxml-2.0 --libs`
+ BIN_LDFLAGS += -ldl
+ 
+ all: $(BIN_TARGET)
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-extended/dlm/dlm/0001-dlm-fix-package-qa-error.patch b/meta-openembedded/meta-networking/recipes-extended/dlm/dlm/0001-dlm-fix-package-qa-error.patch
new file mode 100644
index 0000000..3e384f7
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-extended/dlm/dlm/0001-dlm-fix-package-qa-error.patch
@@ -0,0 +1,32 @@
+From 1fb68433bde97d571fc781b52c9521b17fbb8df0 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Tue, 24 Jul 2018 17:42:43 +0800
+Subject: [PATCH] dlm: fix package qa error
+
+pass LDFLAG to makefile to fix below error:
+do_package_qa: QA Issue: No GNU_HASH in the elf binary:
+/packages-split/dlm/usr/sbin/dlm_stonith' [ldflags]
+
+Upstream-Status: Inappropriate[oe-specific]
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ fence/Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/fence/Makefile b/fence/Makefile
+index cca0b2c..2b3963c 100644
+--- a/fence/Makefile
++++ b/fence/Makefile
+@@ -33,7 +33,7 @@ BIN_CFLAGS += -fPIE -DPIE
+ BIN_CFLAGS += `pkg-config libxml-2.0 --cflags`
+ BIN_CFLAGS += -I../include
+ 
+-BIN_LDFLAGS += -Wl,-z,now -Wl,-z,relro -pie
++BIN_LDFLAGS += $(LDFLAGS) -Wl,-z,now -Wl,-z,relro -pie
+ BIN_LDFLAGS += `pkg-config libxml-2.0 --libs`
+ BIN_LDFLAGS += -ldl
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-extended/dlm/dlm/respect-ldflags-also-from-bin_ldflags.patch b/meta-openembedded/meta-networking/recipes-extended/dlm/dlm/respect-ldflags-also-from-bin_ldflags.patch
index 69b2f90..6f01b21 100644
--- a/meta-openembedded/meta-networking/recipes-extended/dlm/dlm/respect-ldflags-also-from-bin_ldflags.patch
+++ b/meta-openembedded/meta-networking/recipes-extended/dlm/dlm/respect-ldflags-also-from-bin_ldflags.patch
@@ -1,7 +1,23 @@
-diff -uNr dlm-4.0.2.orig/dlm_controld/Makefile dlm-4.0.2/dlm_controld/Makefile
---- dlm-4.0.2.orig/dlm_controld/Makefile	2017-04-04 10:49:23.661320260 +0200
-+++ dlm-4.0.2/dlm_controld/Makefile	2017-04-04 10:50:36.121326429 +0200
-@@ -55,7 +55,7 @@
+From 34a9182814ae565d6f430f85cfe80c05fa9f2dda Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Tue, 24 Jul 2018 17:55:32 +0800
+Subject: [PATCH] respect-ldflags-also-from-bin_ldflags
+
+Upstream-Status: Inappropriate[oe-specific]
+
+update original patch to version 4.0.7
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ dlm_controld/Makefile | 4 ++--
+ dlm_tool/Makefile     | 2 +-
+ 2 files changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/dlm_controld/Makefile b/dlm_controld/Makefile
+index cf556c9..3381730 100644
+--- a/dlm_controld/Makefile
++++ b/dlm_controld/Makefile
+@@ -55,11 +55,11 @@ BIN_CFLAGS += -D_GNU_SOURCE -O2 -ggdb \
  BIN_CFLAGS += -fPIE -DPIE
  BIN_CFLAGS += -I../include -I../libdlm
  
@@ -10,10 +26,16 @@
  BIN_LDFLAGS += -lpthread -lrt -lcpg -lcmap -lcfg -lquorum
  
  LIB_CFLAGS += $(BIN_CFLAGS)
-diff -uNr dlm-4.0.2.orig/dlm_tool/Makefile dlm-4.0.2/dlm_tool/Makefile
---- dlm-4.0.2.orig/dlm_tool/Makefile	2013-07-31 17:50:26.000000000 +0200
-+++ dlm-4.0.2/dlm_tool/Makefile	2017-04-04 10:50:44.617327153 +0200
-@@ -32,7 +32,7 @@
+-LIB_LDFLAGS += -Wl,-z,relro -pie
++LIB_LDFLAGS += $(LDFLAGS) -Wl,-z,relro -pie
+ 
+ ifeq ($(USE_SD_NOTIFY),yes)
+ 	BIN_CFLAGS += $(shell pkg-config --cflags libsystemd) \
+diff --git a/dlm_tool/Makefile b/dlm_tool/Makefile
+index c16d8f5..a48a26f 100644
+--- a/dlm_tool/Makefile
++++ b/dlm_tool/Makefile
+@@ -32,7 +32,7 @@ BIN_CFLAGS += -D_GNU_SOURCE -O2 -ggdb \
  BIN_CFLAGS += -fPIE -DPIE
  BIN_CFLAGS += -I../include -I../libdlm -I../dlm_controld
  
@@ -22,15 +44,6 @@
  BIN_LDFLAGS += -L../libdlm -L../dlm_controld
  BIN_LDFLAGS += -lpthread -ldlm -ldlmcontrol
  
-diff -uNr dlm-4.0.2.orig/dlm_controld/Makefile dlm-4.0.2/dlm_controld/Makefile
---- dlm-4.0.2.orig/dlm_controld/Makefile	2017-04-04 11:02:58.578389641 +0200
-+++ dlm-4.0.2/dlm_controld/Makefile	2017-04-04 11:07:55.672414935 +0200
-@@ -59,7 +59,7 @@
- BIN_LDFLAGS += -lpthread -lrt -lcpg -lcmap -lcfg -lquorum
- 
- LIB_CFLAGS += $(BIN_CFLAGS)
--LIB_LDFLAGS += -Wl,-z,relro -pie
-+LIB_LDFLAGS += $(LDFLAGS) -Wl,-z,relro -pie
- 
- ifeq ($(USE_SD_NOTIFY),yes)
- 	BIN_CFLAGS += $(shell pkg-config --cflags libsystemd-daemon) \
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-extended/dlm/dlm_4.0.2.bb b/meta-openembedded/meta-networking/recipes-extended/dlm/dlm_4.0.2.bb
deleted file mode 100644
index 31e411e..0000000
--- a/meta-openembedded/meta-networking/recipes-extended/dlm/dlm_4.0.2.bb
+++ /dev/null
@@ -1,51 +0,0 @@
-DESCRIPTION = "dlm control daemon and tool"
-
-SECTION = "utils"
-HOMEPAGE = "https://fedorahosted.org/cluster/wiki/HomePage"
-
-REQUIRED_DISTRO_FEATURES = "systemd"
-
-SRC_URI = "https://git.fedorahosted.org/cgit/dlm.git/snapshot/${BP}.tar.xz \
-    file://respect-ldflags-also-from-bin_ldflags.patch \
-"
-
-SRC_URI[md5sum] = "efc2ee6093aa6aa0a88aaad83e998a3f"
-SRC_URI[sha256sum] = "b89bc557aaffbab0ac005398025f247718a5589cff6574d902eaffe2b20e683e"
-
-LICENSE = "LGPLv2+ & GPLv2 & GPLv2+"
-LIC_FILES_CHKSUM = "file://README.license;md5=8f0bbcdd678df1bce9863492b6c8832d"
-
-DEPENDS = "corosync systemd"
-
-inherit pkgconfig systemd distro_features_check
-
-SYSTEMD_SERVICE_${PN} = "dlm.service"
-SYSTEMD_AUTO_ENABLE = "enable"
-
-export EXTRA_OEMAKE = ""
-
-do_compile_prepend() {
-    sed -i "s/libsystemd-daemon/libsystemd/g" ${S}/dlm_controld/Makefile
-}
-
-do_compile () {
-    oe_runmake 'CC=${CC}'
-}
-
-do_install_append (){
-    install -d ${D}${sysconfdir}/sysconfig/
-    install -d ${D}${sysconfdir}/init.d/
-    install -m 0644 ${S}/init/dlm.sysconfig ${D}${sysconfdir}/sysconfig/dlm
-    install -m 0644 ${S}/init/dlm.init ${D}${sysconfdir}/init.d/dlm
-
-    # install systemd unit files
-    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
-        install -d ${D}${systemd_unitdir}/system
-        install -m 0644 ${S}/init/dlm.service ${D}${systemd_unitdir}/system
-    fi
-}
-
-do_install() {
-    oe_runmake install DESTDIR=${D} LIBDIR=${libdir}
-}
-
diff --git a/meta-openembedded/meta-networking/recipes-extended/dlm/dlm_4.0.7.bb b/meta-openembedded/meta-networking/recipes-extended/dlm/dlm_4.0.7.bb
new file mode 100644
index 0000000..027864a
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-extended/dlm/dlm_4.0.7.bb
@@ -0,0 +1,64 @@
+DESCRIPTION = "dlm control daemon and tool"
+
+SECTION = "utils"
+HOMEPAGE = "https://fedorahosted.org/cluster/wiki/HomePage"
+
+REQUIRED_DISTRO_FEATURES = "systemd"
+
+SRC_URI = "https://releases.pagure.org/dlm/${BP}.tar.gz \
+           file://respect-ldflags-also-from-bin_ldflags.patch \
+           file://0001-dlm-fix-compile-error-since-xml2-config-should-not-b.patch \
+           file://0001-dlm-fix-package-qa-error.patch \
+           file://0001-Include-sys-sysmacros.h-for-major-minor-macros-in-gl.patch \
+           "
+
+SRC_URI[md5sum] = "aa604a10d5ac2d3414eb89ec6984cd12"
+SRC_URI[sha256sum] = "639ddfc82369272a68d56816689736c00b8f1b6b2869a6b66b7dbf6dad86469a"
+
+UPSTREAM_CHECK_URI = "https://pagure.io/dlm/releases"
+UPSTREAM_CHECK_REGEX = "dlm-(?P<pver>\d+(\.\d+)+)"
+
+LICENSE = "LGPLv2+ & GPLv2 & GPLv2+"
+LIC_FILES_CHKSUM = "file://README.license;md5=8f0bbcdd678df1bce9863492b6c8832d"
+
+DEPENDS = "corosync systemd"
+
+inherit pkgconfig systemd distro_features_check
+
+PACKAGECONFIG ??= ""
+
+PACKAGECONFIG[pacemaker] = ",,pacemaker"
+
+SYSTEMD_SERVICE_${PN} = "dlm.service"
+SYSTEMD_AUTO_ENABLE = "enable"
+
+export EXTRA_OEMAKE = ""
+
+DONTBUILD = "${@bb.utils.contains('PACKAGECONFIG', 'pacemaker', '', 'fence', d)}"
+
+do_compile_prepend() {
+    sed -i "s/libsystemd-daemon/libsystemd/g" ${S}/dlm_controld/Makefile
+    sed -i -e "s/ ${DONTBUILD}//g" ${S}/Makefile
+}
+
+do_compile () {
+    oe_runmake 'CC=${CC}'
+}
+
+do_install_append (){
+    install -d ${D}${sysconfdir}/sysconfig/
+    install -d ${D}${sysconfdir}/init.d/
+    install -m 0644 ${S}/init/dlm.sysconfig ${D}${sysconfdir}/sysconfig/dlm
+    install -m 0644 ${S}/init/dlm.init ${D}${sysconfdir}/init.d/dlm
+
+    # install systemd unit files
+    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
+        install -d ${D}${systemd_unitdir}/system
+        install -m 0644 ${S}/init/dlm.service ${D}${systemd_unitdir}/system
+    fi
+}
+
+do_install() {
+    oe_runmake install DESTDIR=${D} LIBDIR=${libdir}
+}
+
diff --git a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/0001-kernel-event-netlink_ack-now-requires-4-arguments.patch b/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/0001-kernel-event-netlink_ack-now-requires-4-arguments.patch
deleted file mode 100644
index 4426d35..0000000
--- a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/0001-kernel-event-netlink_ack-now-requires-4-arguments.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From cbc5f8151017f45231b75a826f18354a81c287c4 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 26 Aug 2017 07:52:59 -0700
-Subject: [PATCH] kernel/event: netlink_ack() now requires 4 arguments
-
-see https://patchwork.kernel.org/patch/9670181/
-
-event.c:32:4: error: too few arguments to function 'netlink_ack'
-|     netlink_ack(skb, nlh, 0);
-|     ^~~~~~~~~~~
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- kernel/event.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-Index: iscsitarget-1.4.20.3+svn502/kernel/event.c
-===================================================================
---- iscsitarget-1.4.20.3+svn502.orig/kernel/event.c
-+++ iscsitarget-1.4.20.3+svn502/kernel/event.c
-@@ -6,6 +6,7 @@
-  * Some functions are based on audit code.
-  */
- 
-+#include <linux/version.h>
- #include <linux/module.h>
- #include <net/tcp.h>
- #include "iet_u.h"
-@@ -29,7 +30,11 @@ static void event_recv_skb(struct sk_buf
- 		ietd_pid = NETLINK_CB(skb).portid;
- 		WARN_ON(ietd_pid == 0);
- 		if (nlh->nlmsg_flags & NLM_F_ACK)
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 12, 0)
-+			netlink_ack(skb, nlh, 0, NULL);
-+#else
- 			netlink_ack(skb, nlh, 0);
-+#endif
- 		skb_pull(skb, rlen);
- 	}
- }
diff --git a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/access-sk_v6_daddr-iff-IPV6-defined.patch b/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/access-sk_v6_daddr-iff-IPV6-defined.patch
deleted file mode 100644
index 4444234..0000000
--- a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/access-sk_v6_daddr-iff-IPV6-defined.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-The element skc_v6_daddr (in struct sock_common) is defined in 
-kernel source only when CONFIG_IPV6 is enabled. Hence, access 
-sk_v6_daddr element (i.e __sk_common.skc_v6_daddr) only when CONFIG_IPV6 
-is defined; to fix below error in world build:
-
--- snip --
-/home/jenkins/oe/world/shr-core/tmp-glibc/work-shared/qemux86/kernel-source/include/net/sock.h:330:33: error: 'struct sock_common' has no member named 'skc_v6_daddr'
--- CUT --
-
-Upstream-Status: Pending
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
-
---- iscsitarget-1.4.20.3+svn502_org/kernel/conn.c	2015-12-29 21:57:50.547932217 -0800
-+++ iscsitarget-1.4.20.3+svn502/kernel/conn.c	2015-12-29 22:47:25.254657627 -0800
-@@ -46,10 +46,12 @@ void conn_info_show(struct seq_file *seq
- 			snprintf(buf, sizeof(buf),
- 				 "%pI4", &inet_sk(sk)->inet_daddr);
- 			break;
-+#if defined(CONFIG_IPV6)
- 		case AF_INET6:
- 			snprintf(buf, sizeof(buf), "[%pI6]",
- 				 &(sk)->sk_v6_daddr);
- 			break;
-+#endif /* defined(CONFIG_IPV6) */
- 		default:
- 			break;
- 		}
diff --git a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/build_with_updated_bio_struct_of_linux_v4.3_and_above.patch b/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/build_with_updated_bio_struct_of_linux_v4.3_and_above.patch
deleted file mode 100644
index bce38ba..0000000
--- a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/build_with_updated_bio_struct_of_linux_v4.3_and_above.patch
+++ /dev/null
@@ -1,108 +0,0 @@
-Description: Fix source to compile with 4.3+ kernels
-  commit 4246a0b63bd8f56a1469b12eafeb875b1041a451
-    block: add a bi_error field to struct bio
-  -> Removes BIO_UPTODATE and error argument to bio_endio.
-  commit b54ffb73cadcdcff9cc1ae0e11f502407e3e2e4c
-    block: remove bio_get_nr_vecs()
-  -> Removed that call (always use BIO_MAX_PAGES)
-  commit 676d23690fb62b5d51ba5d659935e9f7d9da9f8e
-    net: Fix use after free by removing length arg from sk_data_ready callbacks.
-  -> Removes len argument from sk_data_ready() callback.
-Author: Stefan Bader <stefan.bader@canonical.com>
-
-The original patch is at http://launchpadlibrarian.net/227478885/iscsitarget_1.4.20.3+svn502-2ubuntu2_1.4.20.3+svn502-2ubuntu3.diff.gz,
-those changes were taken using #ifs to allow compilation of iscsitarget 
-package with kernel versions < 4.3.
-
-Upstream-Status: Submitted [http://launchpadlibrarian.net/227478885/iscsitarget_1.4.20.3+svn502-2ubuntu2_1.4.20.3+svn502-2ubuntu3.diff.gz]
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
-
-diff -Naurp iscsitarget-1.4.20.3+svn502_org/kernel/block-io.c iscsitarget-1.4.20.3+svn502/kernel/block-io.c
---- iscsitarget-1.4.20.3+svn502_org/kernel/block-io.c	2014-05-06 13:59:55.000000000 -0700
-+++ iscsitarget-1.4.20.3+svn502/kernel/block-io.c	2017-01-19 00:46:28.263951115 -0800
-@@ -29,14 +29,23 @@ struct tio_work {
- 	struct completion tio_complete;
- };
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 3, 0)
-+static void blockio_bio_endio(struct bio *bio)
-+#else
- static void blockio_bio_endio(struct bio *bio, int error)
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(4, 3, 0) */
- {
- 	struct tio_work *tio_work = bio->bi_private;
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 3, 0)
-+	if (bio->bi_error)
-+		atomic_set(&tio_work->error, bio->bi_error);
-+#else
- 	error = test_bit(BIO_UPTODATE, &bio->bi_flags) ? error : -EIO;
- 
- 	if (error)
- 		atomic_set(&tio_work->error, error);
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(4, 3, 0) */
- 
- 	/* If last bio signal completion */
- 	if (atomic_dec_and_test(&tio_work->bios_remaining))
-@@ -61,14 +70,20 @@ blockio_make_request(struct iet_volume *
- 	u32 size = tio->size;
- 	u32 tio_index = 0;
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 3, 0)
-+	int max_pages = bdev_q ? BIO_MAX_PAGES : 1;
-+#else
- 	int max_pages = 1;
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(4, 3, 0) */
- 	int err = 0;
- 
- 	loff_t ppos = tio->offset;
- 
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 3, 0)
- 	/* Calculate max_pages for bio_alloc (memory saver) */
- 	if (bdev_q)
- 		max_pages = bio_get_nr_vecs(bio_data->bdev);
-+#endif /* LINUX_VERSION_CODE < KERNEL_VERSION(4, 3, 0) */
- 
- 	tio_work = kzalloc(sizeof (*tio_work), GFP_KERNEL);
- 	if (!tio_work)
-diff -Naurp iscsitarget-1.4.20.3+svn502_org/kernel/conn.c iscsitarget-1.4.20.3+svn502/kernel/conn.c
---- iscsitarget-1.4.20.3+svn502_org/kernel/conn.c	2017-01-19 00:39:09.737117778 -0800
-+++ iscsitarget-1.4.20.3+svn502/kernel/conn.c	2017-01-19 00:52:30.037223901 -0800
-@@ -89,13 +89,21 @@ static void iet_state_change(struct sock
- 	target->nthread_info.old_state_change(sk);
- }
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 3, 0)
-+static void iet_data_ready(struct sock *sk)
-+#else
- static void iet_data_ready(struct sock *sk, int len)
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(4, 3, 0) */
- {
- 	struct iscsi_conn *conn = sk->sk_user_data;
- 	struct iscsi_target *target = conn->session->target;
- 
- 	nthread_wakeup(target);
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 3, 0)
-+	target->nthread_info.old_data_ready(sk);
-+#else
- 	target->nthread_info.old_data_ready(sk, len);
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(4, 3, 0) */
- }
- 
- /*
-diff -Naurp iscsitarget-1.4.20.3+svn502_org/kernel/iscsi.h iscsitarget-1.4.20.3+svn502/kernel/iscsi.h
---- iscsitarget-1.4.20.3+svn502_org/kernel/iscsi.h	2014-05-06 13:59:55.000000000 -0700
-+++ iscsitarget-1.4.20.3+svn502/kernel/iscsi.h	2017-01-19 00:48:02.102837260 -0800
-@@ -81,7 +81,11 @@ struct network_thread_info {
- 	spinlock_t nthread_lock;
- 
- 	void (*old_state_change)(struct sock *);
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 3, 0)
-+	void (*old_data_ready)(struct sock *);
-+#else
- 	void (*old_data_ready)(struct sock *, int);
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(4, 3, 0) */
- 	void (*old_write_space)(struct sock *);
- };
- 
diff --git a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/build_with_updated_interfaces_of_linux_v4.8_and_above.patch b/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/build_with_updated_interfaces_of_linux_v4.8_and_above.patch
deleted file mode 100644
index e508a5e..0000000
--- a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/build_with_updated_interfaces_of_linux_v4.8_and_above.patch
+++ /dev/null
@@ -1,475 +0,0 @@
-Resolve build error with linux kernel 4.8
-
-The below changes in kernel source, triggered iscsitarget
-build fail with linux kernel v4.8.
-
-1. An extra 'flags' argument has been passed to vfs_readv/vfs_writev
-   syscalls in v4.8. So, set this argument to "0" for now
-   (as there is no real need for that).
-   Ref: https://github.com/torvalds/linux/commit/793b80ef14af56d20c998265287648ad34239b6f
-   Solves:
-   -- snip --
-TOPDIR/tmp-glibc/work/qemux86-oe-linux/iscsitarget/1.4.20.3+svn502-r0/iscsitarget-1.4.20.3+svn502/kernel/nthread.c: In function 'write_data':
-TOPDIR/tmp-glibc/work/qemux86-oe-linux/iscsitarget/1.4.20.3+svn502-r0/iscsitarget-1.4.20.3+svn502/kernel/nthread.c:350:9: error: too few arguments to function 'vfs_writev'
-   res = vfs_writev(file, (struct iovec __user *) iop, count, &off);
-         ^~~~~~~~~~
-   -- snip --
-
-2. Redefine dropped PAGE_CACHE_* and page_cache_{get,release} definitions,
-   as they have been dropped with v4.8
-   Ref: https://github.com/torvalds/linux/commit/1fa64f198b9f8d6ec0f7aec7c18dc94684391140
-   Solves:
-   -- snip --
-TOPDIR/tmp-glibc/work/qemux86-oe-linux/iscsitarget/1.4.20.3+svn502-r0/iscsitarget-1.4.20.3+svn502/kernel/param.c: In function 'sess_param_check':
-TOPDIR/tmp-glibc/work/qemux86-oe-linux/iscsitarget/1.4.20.3+svn502-r0/iscsitarget-1.4.20.3+svn502/kernel/param.c:48:41: error: 'PAGE_CACHE_SIZE' undeclared (first use in this function)
-       (u32) ((ISCSI_CONN_IOV_MAX - 1) * PAGE_CACHE_SIZE));
-                                         ^
-   -- snip --
-
-3. Replace crypto_hash interfaces with crypto_ahash interfaces,
-   Ref: https://github.com/torvalds/linux/commit/896545098777564212b9e91af4c973f094649aa7
-   Ref: https://www.redhat.com/archives/dm-devel/2016-January/msg00244.html
-   Solves:
-   -- snip --
-TOPDIR/tmp-glibc/work/qemux86-oe-linux/iscsitarget/1.4.20.3+svn502-r0/iscsitarget-1.4.20.3+svn502/kernel/digest.c: In function 'digest_init':
-TOPDIR/tmp-glibc/work/qemux86-oe-linux/iscsitarget/1.4.20.3+svn502-r0/iscsitarget-1.4.20.3+svn502/kernel/digest.c:42:23: error: implicit declaration of function 'crypto_alloc_hash' [-Werror=implicit-function-declaration]
-   conn->rx_hash.tfm = crypto_alloc_hash("crc32c", 0,
-                       ^~~~~~~~~~~~~~~~~
-TOPDIR/tmp-glibc/work/qemux86-oe-linux/iscsitarget/1.4.20.3+svn502-r0/iscsitarget-1.4.20.3+svn502/kernel/digest.c: In function 'digest_cleanup':
-TOPDIR/tmp-glibc/work/qemux86-oe-linux/iscsitarget/1.4.20.3+svn502-r0/iscsitarget-1.4.20.3+svn502/kernel/digest.c:77:3: error: implicit declaration of function 'crypto_free_hash' [-Werror=implicit-function-declaration]
-   crypto_free_hash(conn->tx_hash.tfm);
-   ^~~~~~~~~~~~~~~~
-   -- snip --
-
-4. The earlier "rw" parameter has been set in "bi_rw" within
-   bio structure, hence remove "rw" argument.
-   Ref: https://github.com/torvalds/linux/commit/4e49ea4a3d276365bf7396c9b77b4d1d5923835a
-   Solves:
--- snip --
-TOPDIR/tmp-glibc/work/qemux86-oe-linux/iscsitarget/1.4.20.3+svn502-r0/iscsitarget-1.4.20.3+svn502/kernel/block-io.c:140:14: warning: passing argument 1 of 'submit_bio' makes pointer from integer without a cast [-Wint-conversion]
-   submit_bio(rw, bio);
-              ^~
--- snip --
-
-5. The 'len' argument from sk_data_ready() callback has been removed in
-   linux kernel v4.3 and above.
-   Ref: https://github.com/torvalds/linux/commit/676d23690fb62b5d51ba5d659935e9f7d9da9f8e
-   Solves:
--- snip --
-TOPDIR/tmp-glibc/work/qemux86-oe-linux/iscsitarget/1.4.20.3+svn502-r0/iscsitarget-1.4.20.3+svn502/kernel/conn.c: In function 'iet_socket_bind':
-TOPDIR/tmp-glibc/work/qemux86-oe-linux/iscsitarget/1.4.20.3+svn502-r0/iscsitarget-1.4.20.3+svn502/kernel/conn.c:143:38: error: assignment from incompatible pointer type [-Werror=incompatible-pointer-types]
-  target->nthread_info.old_data_ready = conn->sock->sk->sk_data_ready;
-                                      ^
-TOPDIR/tmp-glibc/work/qemux86-oe-linux/iscsitarget/1.4.20.3+svn502-r0/iscsitarget-1.4.20.3+svn502/kernel/conn.c:144:32: error: assignment from incompatible pointer type [-Werror=incompatible-pointer-types]
-  conn->sock->sk->sk_data_ready = iet_data_ready;
-                                ^
--- snip --
-
-6.
-   A. The "size" argument has been dropped from sock_recvmsg syscall in v4.8,
-      as all callers have it equal to msg_data_left(msg).
-   B. 'struct user_msghdr' is being used for userland-side msghdr instead
-      of 'struct msghdr', which is used for kernel-side msghdr in linux v3.19
-      and above, so typecase it while calling sock_recvmsg syscall.
-   Ref: https://github.com/torvalds/linux/commit/2da62906b1e298695e1bb725927041cd59942c98
-        https://github.com/torvalds/linux/commit/666547ff591cebdedc4679bf6b1b3f3383a8dea3
-   Solves:
-   -- snip --
-TOPDIR/tmp-glibc/work-shared/qemux86/kernel-source/include/linux/net.h:222:5: note: expected 'struct msghdr *' but argument is of type 'struct user_msghdr *'
- int sock_recvmsg(struct socket *sock, struct msghdr *msg, int flags);
-     ^~~~~~~~~~~~
-TOPDIR/tmp-glibc/work/qemux86-oe-linux/iscsitarget/1.4.20.3+svn502-r0/iscsitarget-1.4.20.3+svn502/kernel/nthread.c:129:8: error: too many arguments to function 'sock_recvmsg'
-  res = sock_recvmsg(conn->sock, &msg, len, MSG_DONTWAIT | MSG_NOSIGNAL);
-        ^~~~~~~~~~~~
-   -- snip --
-
-Detailed error log is at: http://errors.yoctoproject.org/Errors/Details/83334/
-
-Upstream-Status: Pending
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
-
-diff -Naurp iscsitarget-1.4.20.3+svn502_org/kernel/block-io.c iscsitarget-1.4.20.3+svn502/kernel/block-io.c
---- iscsitarget-1.4.20.3+svn502_org/kernel/block-io.c	2017-01-19 20:19:27.400507354 -0800
-+++ iscsitarget-1.4.20.3+svn502/kernel/block-io.c	2017-01-19 20:32:22.977988593 -0800
-@@ -104,7 +104,11 @@ blockio_make_request(struct iet_volume *
- 		/* bi_sector is ALWAYS in units of 512 bytes */
- 		bio->bi_iter.bi_sector = ppos >> 9;
- 		bio->bi_bdev = bio_data->bdev;
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+		bio->bi_end_io = (bio_end_io_t *) blockio_bio_endio;
-+#else
- 		bio->bi_end_io = blockio_bio_endio;
-+#endif
- 		bio->bi_private = tio_work;
- 
- 		if (tio_bio)
-@@ -139,7 +143,12 @@ blockio_make_request(struct iet_volume *
- 		tio_bio = tio_bio->bi_next;
- 		bio->bi_next = NULL;
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+		bio_set_op_attrs(bio, REQ_OP_WRITE, 0);
-+		submit_bio(bio);
-+#else
- 		submit_bio(rw, bio);
-+#endif
- 	}
- 
- 	blk_finish_plug(&plug);
-diff -Naurp iscsitarget-1.4.20.3+svn502_org/kernel/conn.c iscsitarget-1.4.20.3+svn502/kernel/conn.c
---- iscsitarget-1.4.20.3+svn502_org/kernel/conn.c	2017-01-19 20:19:27.400507354 -0800
-+++ iscsitarget-1.4.20.3+svn502/kernel/conn.c	2017-01-19 20:32:22.978988614 -0800
-@@ -148,8 +148,14 @@ static void iet_socket_bind(struct iscsi
- 	target->nthread_info.old_state_change = conn->sock->sk->sk_state_change;
- 	conn->sock->sk->sk_state_change = iet_state_change;
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	target->nthread_info.old_data_ready = (void (*) (struct sock *)) \
-+						conn->sock->sk->sk_data_ready;
-+	conn->sock->sk->sk_data_ready = (void (*) (struct sock *)) iet_data_ready;
-+#else
- 	target->nthread_info.old_data_ready = conn->sock->sk->sk_data_ready;
- 	conn->sock->sk->sk_data_ready = iet_data_ready;
-+#endif
- 
- 	target->nthread_info.old_write_space = conn->sock->sk->sk_write_space;
- 	conn->sock->sk->sk_write_space = iet_write_space;
-diff -Naurp iscsitarget-1.4.20.3+svn502_org/kernel/digest.c iscsitarget-1.4.20.3+svn502/kernel/digest.c
---- iscsitarget-1.4.20.3+svn502_org/kernel/digest.c	2014-05-06 13:59:55.000000000 -0700
-+++ iscsitarget-1.4.20.3+svn502/kernel/digest.c	2017-01-19 20:32:22.978988614 -0800
-@@ -30,6 +30,9 @@ void digest_alg_available(unsigned int *
- int digest_init(struct iscsi_conn *conn)
- {
- 	int err = 0;
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	struct crypto_ahash *tfm;
-+#endif
- 
- 	if (!(conn->hdigest_type & DIGEST_ALL))
- 		conn->hdigest_type = DIGEST_NONE;
-@@ -39,15 +42,40 @@ int digest_init(struct iscsi_conn *conn)
- 
- 	if (conn->hdigest_type & DIGEST_CRC32C ||
- 	    conn->ddigest_type & DIGEST_CRC32C) {
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+		tfm = crypto_alloc_ahash("crc32c", 0, CRYPTO_ALG_ASYNC);
-+		if (IS_ERR(tfm)) {
-+			tfm = NULL;
-+#else
- 		conn->rx_hash.tfm = crypto_alloc_hash("crc32c", 0,
- 						      CRYPTO_ALG_ASYNC);
- 		conn->rx_hash.flags = 0;
- 		if (IS_ERR(conn->rx_hash.tfm)) {
- 			conn->rx_hash.tfm = NULL;
-+#endif
- 			err = -ENOMEM;
- 			goto out;
- 		}
--
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+		conn->rx_hash = ahash_request_alloc(tfm, GFP_KERNEL);
-+		if (!conn->rx_hash) {
-+			pr_err("ahash_request_alloc() failed for conn->rx_hash\n");
-+			crypto_free_ahash(tfm);
-+			err = -ENOMEM;
-+			goto out;
-+		}
-+		ahash_request_set_callback(conn->rx_hash, 0, NULL, NULL);
-+		conn->tx_hash = ahash_request_alloc(tfm, GFP_KERNEL);
-+		if(!conn->tx_hash) {
-+			pr_err("ahash_request_alloc() failed for conn->tx_hash\n");
-+			ahash_request_free(conn->rx_hash);
-+			conn->rx_hash = NULL;
-+			crypto_free_ahash(tfm);
-+			err = -ENOMEM;
-+			goto out;
-+		}
-+		ahash_request_set_callback(conn->tx_hash, 0, NULL, NULL);
-+#else
- 		conn->tx_hash.tfm = crypto_alloc_hash("crc32c", 0,
- 						      CRYPTO_ALG_ASYNC);
- 		conn->tx_hash.flags = 0;
-@@ -56,6 +84,7 @@ int digest_init(struct iscsi_conn *conn)
- 			err = -ENOMEM;
- 			goto out;
- 		}
-+#endif
- 	}
- 
- out:
-@@ -73,10 +102,21 @@ out:
-  */
- void digest_cleanup(struct iscsi_conn *conn)
- {
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	ahash_request_free(conn->tx_hash);
-+	if (conn->rx_hash) {
-+		struct crypto_ahash *tfm;
-+		tfm = crypto_ahash_reqtfm(conn->rx_hash);
-+		ahash_request_free(conn->rx_hash);
-+		crypto_free_ahash(tfm);
-+	}
-+
-+#else
- 	if (conn->tx_hash.tfm)
- 		crypto_free_hash(conn->tx_hash.tfm);
- 	if (conn->rx_hash.tfm)
- 		crypto_free_hash(conn->rx_hash.tfm);
-+#endif
- }
- 
- /**
-@@ -160,8 +200,13 @@ static inline void __dbg_simulate_data_d
- 	}
- }
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+static void digest_header(struct ahash_request *hash, struct iscsi_pdu *pdu,
-+			  u8 *crc)
-+#else
- static void digest_header(struct hash_desc *hash, struct iscsi_pdu *pdu,
- 			  u8 *crc)
-+#endif
- {
- 	struct scatterlist sg[2];
- 	unsigned int nbytes = sizeof(struct iscsi_hdr);
-@@ -174,16 +219,27 @@ static void digest_header(struct hash_de
- 		nbytes += pdu->ahssize;
- 	}
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	crypto_ahash_init(hash);
-+	ahash_request_set_crypt(hash, sg, crc, nbytes);
-+	crypto_ahash_update(hash);
-+	crypto_ahash_digest(hash);
-+#else
- 	crypto_hash_init(hash);
- 	crypto_hash_update(hash, sg, nbytes);
- 	crypto_hash_final(hash, crc);
-+#endif
- }
- 
- int digest_rx_header(struct iscsi_cmnd *cmnd)
- {
- 	u32 crc;
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	digest_header(cmnd->conn->rx_hash, &cmnd->pdu, (u8 *) &crc);
-+#else
- 	digest_header(&cmnd->conn->rx_hash, &cmnd->pdu, (u8 *) &crc);
-+#endif
- 	if (crc != cmnd->hdigest)
- 		return -EIO;
- 
-@@ -192,11 +248,20 @@ int digest_rx_header(struct iscsi_cmnd *
- 
- void digest_tx_header(struct iscsi_cmnd *cmnd)
- {
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	digest_header(cmnd->conn->tx_hash, &cmnd->pdu, (u8 *) &cmnd->hdigest);
-+#else
- 	digest_header(&cmnd->conn->tx_hash, &cmnd->pdu, (u8 *) &cmnd->hdigest);
-+#endif
- }
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+static void digest_data(struct ahash_request *hash, struct iscsi_cmnd *cmnd,
-+			struct tio *tio, u32 offset, u8 *crc)
-+#else
- static void digest_data(struct hash_desc *hash, struct iscsi_cmnd *cmnd,
- 			struct tio *tio, u32 offset, u8 *crc)
-+#endif
- {
- 	struct scatterlist *sg = cmnd->conn->hash_sg;
- 	u32 size, length, npages;
-@@ -214,7 +279,11 @@ static void digest_data(struct hash_desc
- 	BUG_ON(npages > ISCSI_CONN_IOV_MAX);
- 
- 	sg_init_table(sg, ARRAY_SIZE(cmnd->conn->hash_sg));
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	crypto_ahash_init(hash);
-+#else
- 	crypto_hash_init(hash);
-+#endif
- 
- 	for (i = 0; size > 0; i++) {
- 		length = min_t(u32, PAGE_CACHE_SIZE - offset, size);
-@@ -225,8 +294,14 @@ static void digest_data(struct hash_desc
- 
- 	sg_mark_end(&sg[i - 1]);
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	ahash_request_set_crypt(hash, sg, crc, nbytes);
-+	crypto_ahash_update(hash);
-+	crypto_ahash_digest(hash);
-+#else
- 	crypto_hash_update(hash, sg, nbytes);
- 	crypto_hash_final(hash, crc);
-+#endif
- }
- 
- int digest_rx_data(struct iscsi_cmnd *cmnd)
-@@ -251,8 +326,11 @@ int digest_rx_data(struct iscsi_cmnd *cm
- 		tio = cmnd->tio;
- 		offset = 0;
- 	}
--
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	digest_data(cmnd->conn->rx_hash, cmnd, tio, offset, (u8 *) &crc);
-+#else
- 	digest_data(&cmnd->conn->rx_hash, cmnd, tio, offset, (u8 *) &crc);
-+#endif
- 
- 	if (!cmnd->conn->read_overflow &&
- 	    (cmnd_opcode(cmnd) != ISCSI_OP_PDU_REJECT)) {
-@@ -269,6 +347,11 @@ void digest_tx_data(struct iscsi_cmnd *c
- 	struct iscsi_data_out_hdr *req = (struct iscsi_data_out_hdr *)&cmnd->pdu.bhs;
- 
- 	assert(tio);
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	digest_data(cmnd->conn->tx_hash, cmnd, tio,
-+		    be32_to_cpu(req->buffer_offset), (u8 *) &cmnd->ddigest);
-+#else
- 	digest_data(&cmnd->conn->tx_hash, cmnd, tio,
- 		    be32_to_cpu(req->buffer_offset), (u8 *) &cmnd->ddigest);
-+#endif
- }
-diff -Naurp iscsitarget-1.4.20.3+svn502_org/kernel/iscsi.h iscsitarget-1.4.20.3+svn502/kernel/iscsi.h
---- iscsitarget-1.4.20.3+svn502_org/kernel/iscsi.h	2017-01-19 20:19:27.400507354 -0800
-+++ iscsitarget-1.4.20.3+svn502/kernel/iscsi.h	2017-01-19 20:32:22.979988634 -0800
-@@ -14,6 +14,7 @@
- #include <linux/pagemap.h>
- #include <linux/seq_file.h>
- #include <linux/mm.h>
-+#include <crypto/hash.h>
- #include <linux/crypto.h>
- #include <linux/scatterlist.h>
- #include <net/sock.h>
-@@ -275,8 +276,13 @@ struct iscsi_conn {
- 	u32 write_offset;
- 	int write_state;
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	struct ahash_request *rx_hash;
-+	struct ahash_request *tx_hash;
-+#else
- 	struct hash_desc rx_hash;
- 	struct hash_desc tx_hash;
-+#endif
- 	struct scatterlist hash_sg[ISCSI_CONN_IOV_MAX];
- };
- 
-@@ -552,4 +558,10 @@ enum cmnd_flags {
- #define PRODUCT_ID	"VIRTUAL-DISK"
- #define PRODUCT_REV	"0"
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+#define PAGE_CACHE_SHIFT	PAGE_SHIFT
-+#define PAGE_CACHE_SIZE	PAGE_SIZE
-+#define PAGE_CACHE_MASK	PAGE_MASK
-+#endif
-+
- #endif	/* __ISCSI_H__ */
-diff -Naurp iscsitarget-1.4.20.3+svn502_org/kernel/nthread.c iscsitarget-1.4.20.3+svn502/kernel/nthread.c
---- iscsitarget-1.4.20.3+svn502_org/kernel/nthread.c	2017-01-19 20:19:27.276504928 -0800
-+++ iscsitarget-1.4.20.3+svn502/kernel/nthread.c	2017-01-19 20:32:22.979988634 -0800
-@@ -155,7 +155,12 @@ static int do_recv(struct iscsi_conn *co
- 
- 	oldfs = get_fs();
- 	set_fs(get_ds());
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	res = sock_recvmsg(conn->sock, (struct msghdr *) &msg, \
-+				MSG_DONTWAIT | MSG_NOSIGNAL);
-+#else
- 	res = sock_recvmsg(conn->sock, &msg, len, MSG_DONTWAIT | MSG_NOSIGNAL);
-+#endif
- 	set_fs(oldfs);
- 
- 	if (res <= 0) {
-@@ -376,7 +381,11 @@ static int write_data(struct iscsi_conn
- 			;
- 		oldfs = get_fs();
- 		set_fs(KERNEL_DS);
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+		res = vfs_writev(file, (struct iovec __user *) iop, count, &off, 0);
-+#else
- 		res = vfs_writev(file, (struct iovec __user *) iop, count, &off);
-+#endif
- 		set_fs(oldfs);
- 		dprintk(D_DATA, "%#Lx:%u: %d(%ld)\n",
- 			(unsigned long long) conn->session->sid, conn->cid,
-@@ -503,7 +512,11 @@ static int tx_ddigest(struct iscsi_cmnd
- 	iov.iov_base = (char *) (&cmnd->ddigest) + (sizeof(u32) - rest);
- 	iov.iov_len = rest;
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	res = kernel_sendmsg(cmnd->conn->sock, (struct msghdr *) &msg, &iov, 1, rest);
-+#else
- 	res = kernel_sendmsg(cmnd->conn->sock, &msg, &iov, 1, rest);
-+#endif
- 
- 	if (res > 0) {
- 		cmnd->conn->write_size -= res;
-@@ -702,7 +715,12 @@ static void close_conn(struct iscsi_conn
- 
- 	write_lock_bh(&conn->sock->sk->sk_callback_lock);
- 	conn->sock->sk->sk_state_change = target->nthread_info.old_state_change;
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	conn->sock->sk->sk_data_ready = (void (*) (struct sock *)) \
-+					target->nthread_info.old_data_ready;
-+#else
- 	conn->sock->sk->sk_data_ready = target->nthread_info.old_data_ready;
-+#endif
- 	conn->sock->sk->sk_write_space = target->nthread_info.old_write_space;
- 	write_unlock_bh(&conn->sock->sk->sk_callback_lock);
- 
-diff -Naurp iscsitarget-1.4.20.3+svn502_org/kernel/volume.c iscsitarget-1.4.20.3+svn502/kernel/volume.c
---- iscsitarget-1.4.20.3+svn502_org/kernel/volume.c	2017-01-19 20:19:27.276504928 -0800
-+++ iscsitarget-1.4.20.3+svn502/kernel/volume.c	2017-01-19 20:32:22.979988634 -0800
-@@ -84,12 +84,25 @@ static int set_scsisn(struct iet_volume
- /* Generate a MD5 hash of the target IQN and LUN number */
- static void gen_scsiid(struct iet_volume *volume)
- {
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	struct ahash_request *hash;
-+	struct crypto_ahash *tfm;
-+#else
- 	struct hash_desc hash;
-+#endif
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	tfm = crypto_alloc_ahash("md5", 0, CRYPTO_ALG_ASYNC);
-+#else
- 	hash.tfm = crypto_alloc_hash("md5", 0, CRYPTO_ALG_ASYNC);
- 	hash.flags = 0;
-+#endif
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+	if (!IS_ERR(tfm)) {
-+#else
- 	if (!IS_ERR(hash.tfm)) {
-+#endif
- 		struct scatterlist sg[2];
- 		unsigned int nbytes = 0;
- 
-@@ -102,11 +115,19 @@ static void gen_scsiid(struct iet_volume
- 		sg_set_buf(&sg[1], &volume->lun, sizeof(volume->lun));
- 		nbytes += sizeof(volume->lun);
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
-+		crypto_ahash_init(hash);
-+		ahash_request_set_crypt(hash, sg, volume->scsi_id, nbytes);
-+		crypto_ahash_update(hash);
-+		crypto_ahash_digest(hash);
-+		crypto_free_ahash(tfm);
-+#else
- 		crypto_hash_init(&hash);
- 		crypto_hash_update(&hash, sg, nbytes);
- 		crypto_hash_final(&hash, volume->scsi_id);
- 
- 		crypto_free_hash(hash.tfm);
-+#endif
- 	} else {
- 		/* If no MD5 available set ID to TID and LUN */
- 		memcpy(volume->scsi_id, &volume->target->tid,
diff --git a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/fix-call-trace-of-ahash-API-calling.patch b/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/fix-call-trace-of-ahash-API-calling.patch
deleted file mode 100644
index c996834..0000000
--- a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/fix-call-trace-of-ahash-API-calling.patch
+++ /dev/null
@@ -1,85 +0,0 @@
-The previous build_with_updated_interfaces_of_linux_v4.8_and_above.patch
-does not alloc struct ahash_request before using it. This will cause the
-kernel call trace below when calling gen_scsiid on kernel 4.8 or later
-version.
-
-This patch normalizes the calling of ahash API according to the example
-in kernel doc Documentation/crypto/api-intro.txt.
-
-BUG: unable to handle kernel NULL pointer dereference at 0000000000000020
-IP: [<ffffffffa0008d45>] volume_add+0x625/0x7f0 [iscsi_trgt]
-PGD dd77067 PUD dd7c067 PMD 0 
-Oops: 0000 [#1] PREEMPT SMP
-Modules linked in: iscsi_trgt(O)
-CPU: 0 PID: 350 Comm: ietd Tainted: G           O    4.8.12-yocto-standard #1
-Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.9.3-0-ge2fc41e-prebuilt.qemu-project.org 04/01/2014
-task: ffff88000dfe2c00 task.stack: ffff88000de88000
-RIP: 0010:[<ffffffffa0008d45>]  [<ffffffffa0008d45>] volume_add+0x625/0x7f0 [iscsi_trgt]
-RSP: 0018:ffff88000de8bd90  EFLAGS: 00000206
-RAX: 000000000000ddfa RBX: ffff88000ddd1d78 RCX: ffffea0000000000
-RDX: 0000000000000600 RSI: 0000000000000000 RDI: ffff88000ddd1c14
-RBP: ffff88000de8be38 R08: ffff88000de44180 R09: ffff88000de8bdd0
-R10: 000000000000002c R11: 0000000000000000 R12: ffff88000ddfa600
-R13: 0000000000000000 R14: 0000000000000000 R15: ffff88000de92200
-FS:  00007f767548b700(0000) GS:ffff88000fc00000(0000) knlGS:0000000000000000
-CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
-CR2: 0000000000000020 CR3: 000000000dd2d000 CR4: 00000000000006f0
-Stack:
- ffff88000de8bdd0 ffff88000dc1b3d0 ffff88000ddfa650 ffff88000ddfa660
- ffff88000df8f000 ffff88000ddd1c00 ffff88000de44180 0000000000000000
- ffffea0000377440 0000000f00000c14 0000000000000000 0000000000000000
-Call Trace:
- [<ffffffffa0006547>] ioctl+0x217/0x390 [iscsi_trgt]
- [<ffffffff81192574>] do_vfs_ioctl+0x94/0x5c0
- [<ffffffff8117ff73>] ? vfs_read+0xf3/0x120
- [<ffffffff81192b19>] SyS_ioctl+0x79/0x90
- [<ffffffff8191a45b>] entry_SYSCALL_64_fastpath+0x13/0x8f
-Code: 4c 01 e0 0f 82 a2 01 00 00 48 b9 00 00 00 80 ff 77 00 00 48 01
-c8 45 31 f6 48 b9 00 00 00 00 00 ea ff ff 89 54 24 68 48 c1 e8 0c <49>
-8b 56 20 4c 89 44 24 20 4c 89 f7 48 c1 e0 06 c7 44 24 6c 04 
-RIP  [<ffffffffa0008d45>] volume_add+0x625/0x7f0 [iscsi_trgt]
- RSP <ffff88000de8bd90>
-CR2: 0000000000000020
-end trace cd2016297df21635 ]
-ietd_response_recv 200 0 -5
-Input/output error.
-
-Upstream-Status: Pending [This patch is based on the previous one which
-has not been merged upstream.]
-
-Signed-off-by: Zhe He <zhe.he@windriver.com>
-
---- iscsitarget-1.4.20.3+svn502_orig/kernel/volume.c	2017-01-18 08:57:56.752187402 +0800
-+++ iscsitarget-1.4.20.3+svn502/kernel/volume.c	2017-01-18 09:02:44.164195234 +0800
-@@ -93,13 +93,14 @@ static void gen_scsiid(struct iet_volume
- 
- #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
- 	tfm = crypto_alloc_ahash("md5", 0, CRYPTO_ALG_ASYNC);
-+	hash = ahash_request_alloc(tfm, GFP_ATOMIC);
- #else
- 	hash.tfm = crypto_alloc_hash("md5", 0, CRYPTO_ALG_ASYNC);
- 	hash.flags = 0;
- #endif
- 
- #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
--	if (!IS_ERR(tfm)) {
-+	if (tfm && !IS_ERR(tfm)) {
- #else
- 	if (!IS_ERR(hash.tfm)) {
- #endif
-@@ -116,10 +117,13 @@ static void gen_scsiid(struct iet_volume
- 		nbytes += sizeof(volume->lun);
- 
- #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
--		crypto_ahash_init(hash);
-+		ahash_request_set_callback(hash, 0, NULL, NULL);
- 		ahash_request_set_crypt(hash, sg, volume->scsi_id, nbytes);
--		crypto_ahash_update(hash);
- 		crypto_ahash_digest(hash);
-+		crypto_ahash_init(hash);
-+		crypto_ahash_update(hash);
-+		crypto_ahash_final(hash);
-+		ahash_request_free(hash);
- 		crypto_free_ahash(tfm);
- #else
- 		crypto_hash_init(&hash);
diff --git a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/fix-errors-observed-with-linux-3.19-and-greater.patch b/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/fix-errors-observed-with-linux-3.19-and-greater.patch
deleted file mode 100644
index 1e6a1d6..0000000
--- a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/fix-errors-observed-with-linux-3.19-and-greater.patch
+++ /dev/null
@@ -1,327 +0,0 @@
-Description: Fix source to compile on 3.19 kernels
-Author: Stefan Bader <stefan.bader@canonical.com>
-Forward: no
-
-Fixes below inconsistent crash when trying to login to iSCSI target
-server, observed with linux kernel v4.1.
-
--- snip --
-CPU: 1 PID: 29883 Comm: istd1 Tainted: G           O    4.1.35-rt40-yocto-standard #1
-Hardware name: To be filled by O.E.M. To be filled by O.E.M./Larne CRB, BIOS 4.6.5.4 09/18/2014
-task: ffff88020f1f30c0 ti: ffff8800d7f3c000 task.ti: ffff8800d7f3c000
-RIP: 0010:[<ffffffff8140d1ae>]  [<ffffffff8140d1ae>] copy_to_iter+0x3e/0x280
-RSP: 0018:ffff8800d7f3f728  EFLAGS: 00010246
-RAX: 00000000d7f3f928 RBX: 0000000000000030 RCX: 0000000000000030
-RDX: ffff8800d7f3f900 RSI: 0000000000000030 RDI: ffff8800d1501e82
-RBP: ffff8800d7f3f768 R08: 00000000c127d467 R09: 0000000000000000
-R10: ffff88020f29e118 R11: 0000000000000004 R12: ffff8800d7f3f900
-R13: 0000000000000030 R14: 0000000000000001 R15: 0000000000000246
-FS:  00007f86f9c4c700(0000) GS:ffff88021ec80000(0000) knlGS:00000000f7733700
-CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
-CR2: 000000000000024e CR3: 00000000d38b0000 CR4: 00000000000406e0
-Stack:
-ffff880214f14ec0 ffff8800d1501e82 ffff8800d7f3f748 0000000000000030
-ffff88020f122500 0000000000000030 0000000000000000 0000000000000030
-ffff8800d7f3f7c8 ffffffff81806981 ffff8800d7f3f798 ffffffff8105d72a
-Call Trace:
-[<ffffffff81806981>] skb_copy_datagram_iter+0x71/0x2b0
-[<ffffffff8105d72a>] ? __local_bh_enable_ip+0x4a/0xb0
-[<ffffffff8186c9c0>] tcp_recvmsg+0x5e0/0xbb0
-[<ffffffff81898ded>] inet_recvmsg+0x8d/0xb0
-[<ffffffff817f49f3>] sock_recvmsg+0x13/0x20
-[<ffffffffa01655c3>] do_recv+0xe3/0x1f0 [iscsi_trgt]
-[<ffffffff81153097>] ? __mod_zone_page_state+0x77/0xb0
-[<ffffffff81417613>] ? __this_cpu_preempt_check+0x13/0x20
-[<ffffffff81153097>] ? __mod_zone_page_state+0x77/0xb0
-[<ffffffff8140fed5>] ? find_next_bit+0x15/0x30
-[<ffffffff813fa8e0>] ? cpumask_next_and+0x30/0x50
-[<ffffffff8113f785>] ? __alloc_pages_nodemask+0x165/0x980
-[<ffffffff8107e370>] ? preempt_count_add+0xd0/0xf0
-[<ffffffff8195da8b>] ? _raw_spin_lock+0x1b/0x60
-[<ffffffff8109cfa8>] ? cpuacct_charge+0x58/0x70
-[<ffffffff81089039>] ? update_curr+0xb9/0x190
-[<ffffffff81417613>] ? __this_cpu_preempt_check+0x13/0x20
-[<ffffffff8112b43f>] ? __perf_event_task_sched_in+0x4f/0x90
-[<ffffffff8195dbbd>] ? _raw_spin_unlock_irq+0x1d/0x40
-[<ffffffff8107e223>] ? finish_task_switch+0x63/0xe0
-[<ffffffff81959e3b>] ? __schedule+0x38b/0x980
-[<ffffffff8107e370>] ? preempt_count_add+0xd0/0xf0
-[<ffffffffa0165c65>] istd+0x4d5/0x1390 [iscsi_trgt]
-[<ffffffff81959e3b>] ? __schedule+0x38b/0x980
-[<ffffffffa0165790>] ? nthread_wakeup+0x40/0x40 [iscsi_trgt]
-[<ffffffffa0165790>] ? nthread_wakeup+0x40/0x40 [iscsi_trgt]
-[<ffffffff8107748b>] kthread+0xbb/0xe0
-[<ffffffff81950000>] ? wireless_dev_seq_show+0x100/0x180
-[<ffffffff810773d0>] ? kthread_worker_fn+0x170/0x170
-[<ffffffff8195e7a2>] ret_from_fork+0x42/0x70
-[<ffffffff810773d0>] ? kthread_worker_fn+0x170/0x170
-Code: 5a 10 48 89 7d c8 48 39 f3 48 0f 47 de 48 85 db 0f 84 6f 01 00 00 8b 02 49 89
-d4 4c 8b 72 08 4c 8b 7a 18 a8 04 0f 85 a2 00 00 00 <4d> 8b 6f 08 4d 29 f5 49 39 dd 4c 0f 47 eb a8 02 0f 85 5c 01 00 
-RSP <ffff8800d7f3f728>
-CR2: 000000000000024e
-------------[ cut here ]------------
--- snip --
-
-The original patch is at
-http://launchpadlibrarian.net/218100509/iscsitarget_1.4.20.3+svn499-0ubuntu2_1.4.20.3+svn499-0ubuntu2.1.diff.gz,
-those changes were taken using #ifs, inorder to allow compilation of 
-iscsitarget package with linux kernels < 3.19.
-
-Upstream-Status: Submitted [http://launchpadlibrarian.net/218100509/iscsitarget_1.4.20.3+svn499-0ubuntu2_1.4.20.3+svn499-0ubuntu2.1.diff.gz]
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
-
-diff -Naurp iscsitarget-1.4.20.3+svn502_org/kernel/conn.c iscsitarget-1.4.20.3+svn502/kernel/conn.c
---- iscsitarget-1.4.20.3+svn502_org/kernel/conn.c	2017-01-18 22:27:02.713167436 -0800
-+++ iscsitarget-1.4.20.3+svn502/kernel/conn.c	2017-01-18 23:13:11.909214379 -0800
-@@ -129,7 +129,11 @@ static void iet_socket_bind(struct iscsi
- 
- 	dprintk(D_GENERIC, "%llu\n", (unsigned long long) session->sid);
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+	conn->sock = SOCKET_I(file_inode(conn->file));
-+#else
- 	conn->sock = SOCKET_I(conn->file->f_dentry->d_inode);
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- 	conn->sock->sk->sk_user_data = conn;
- 
- 	write_lock_bh(&conn->sock->sk->sk_callback_lock);
-diff -Naurp iscsitarget-1.4.20.3+svn502_org/kernel/file-io.c iscsitarget-1.4.20.3+svn502/kernel/file-io.c
---- iscsitarget-1.4.20.3+svn502_org/kernel/file-io.c	2014-05-06 13:59:55.000000000 -0700
-+++ iscsitarget-1.4.20.3+svn502/kernel/file-io.c	2017-01-18 23:54:38.505717079 -0800
-@@ -69,7 +69,11 @@ static int fileio_make_request(struct ie
- static int fileio_sync(struct iet_volume *lu, struct tio *tio)
- {
- 	struct fileio_data *p = lu->private;
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+	struct inode *inode = file_inode(p->filp);
-+#else
- 	struct inode *inode = p->filp->f_dentry->d_inode;
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- 	struct address_space *mapping = inode->i_mapping;
- 	loff_t ppos, count;
- 	int res;
-@@ -213,7 +217,11 @@ static int fileio_attach(struct iet_volu
- 		eprintk("%d\n", err);
- 		goto out;
- 	}
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+	inode = file_inode(p->filp);
-+#else
- 	inode = p->filp->f_dentry->d_inode;
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- 
- 	if (S_ISREG(inode->i_mode))
- 		;
-diff -Naurp iscsitarget-1.4.20.3+svn502_org/kernel/iscsi.c iscsitarget-1.4.20.3+svn502/kernel/iscsi.c
---- iscsitarget-1.4.20.3+svn502_org/kernel/iscsi.c	2014-05-06 13:59:55.000000000 -0700
-+++ iscsitarget-1.4.20.3+svn502/kernel/iscsi.c	2017-01-18 23:37:36.462970326 -0800
-@@ -489,8 +489,12 @@ static void cmnd_skip_pdu(struct iscsi_c
- 	}
- 	conn->read_iov[i].iov_base = addr;
- 	conn->read_iov[i].iov_len = size;
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+	iov_iter_init(&conn->read_msg.msg_iter, READ, conn->read_iov, ++i, conn->read_size);
-+#else
- 	conn->read_msg.msg_iov = conn->read_iov;
- 	conn->read_msg.msg_iovlen = ++i;
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- }
- 
- static void iscsi_cmnd_reject(struct iscsi_cmnd *req, int reason)
-@@ -718,7 +722,9 @@ static int cmnd_recv_pdu(struct iscsi_co
- 	idx = offset >> PAGE_CACHE_SHIFT;
- 	offset &= ~PAGE_CACHE_MASK;
- 
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 19, 0)
- 	conn->read_msg.msg_iov = conn->read_iov;
-+#endif	/* LINUX_VERSION_CODE < KERNEL_VERSION(3, 19, 0) */
- 	conn->read_size = size = (size + 3) & -4;
- 	conn->read_overflow = 0;
- 
-@@ -730,16 +736,25 @@ static int cmnd_recv_pdu(struct iscsi_co
- 		conn->read_iov[i].iov_base =  addr + offset;
- 		if (offset + size <= PAGE_CACHE_SIZE) {
- 			conn->read_iov[i].iov_len = size;
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+			iov_iter_init(&conn->read_msg.msg_iter, READ, conn->read_iov, ++i, conn->read_size);
-+#else
- 			conn->read_msg.msg_iovlen = ++i;
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- 			break;
- 		}
- 		conn->read_iov[i].iov_len = PAGE_CACHE_SIZE - offset;
- 		size -= conn->read_iov[i].iov_len;
- 		offset = 0;
- 		if (++i >= ISCSI_CONN_IOV_MAX) {
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 19, 0)
- 			conn->read_msg.msg_iovlen = i;
-+#endif /* LINUX_VERSION_CODE < KERNEL_VERSION(3, 19, 0) */
- 			conn->read_overflow = size;
- 			conn->read_size -= size;
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+			iov_iter_init(&conn->read_msg.msg_iter, READ, conn->read_iov, i, conn->read_size);
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- 			break;
- 		}
- 
-@@ -918,7 +933,9 @@ static int nop_out_start(struct iscsi_co
- 
- 	if ((size = cmnd->pdu.datasize)) {
- 		size = (size + 3) & -4;
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 19, 0)
- 		conn->read_msg.msg_iov = conn->read_iov;
-+#endif /* LINUX_VERSION_CODE < KERNEL_VERSION(3, 19, 0) */
- 		if (cmnd->pdu.bhs.itt != cpu_to_be32(ISCSI_RESERVED_TAG)) {
- 			struct tio *tio;
- 			int pg_cnt = get_pgcnt(size);
-@@ -946,7 +963,11 @@ static int nop_out_start(struct iscsi_co
- 		}
- 		assert(!size);
- 		conn->read_overflow = size;
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+		iov_iter_init(&conn->read_msg.msg_iter, READ, conn->read_iov, i, conn->read_size);
-+#else
- 		conn->read_msg.msg_iovlen = i;
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- 	}
- 
- out:
-@@ -986,7 +1007,11 @@ static void scsi_cmnd_start(struct iscsi
- 		set_cmnd_lunit(req);
- 
- 	switch (req_hdr->scb[0]) {
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+	case SERVICE_ACTION_IN_16:
-+#else
- 	case SERVICE_ACTION_IN:
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- 		if ((req_hdr->scb[1] & 0x1f) != 0x10)
- 			goto error;
- 	case INQUIRY:
-diff -Naurp iscsitarget-1.4.20.3+svn502_org/kernel/nthread.c iscsitarget-1.4.20.3+svn502/kernel/nthread.c
---- iscsitarget-1.4.20.3+svn502_org/kernel/nthread.c	2014-05-06 13:59:55.000000000 -0700
-+++ iscsitarget-1.4.20.3+svn502/kernel/nthread.c	2017-01-18 23:45:03.291033881 -0800
-@@ -42,9 +42,14 @@ static inline void iscsi_conn_init_read(
- 	len = (len + 3) & -4; // XXX ???
- 	conn->read_iov[0].iov_base = data;
- 	conn->read_iov[0].iov_len = len;
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 19, 0)
- 	conn->read_msg.msg_iov = conn->read_iov;
- 	conn->read_msg.msg_iovlen = 1;
-+#endif /* LINUX_VERSION_CODE < KERNEL_VERSION(3, 19, 0) */
- 	conn->read_size = (len + 3) & -4;
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+	iov_iter_init(&conn->read_msg.msg_iter, READ, conn->read_iov, 1, conn->read_size);
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- }
- 
- static void iscsi_conn_read_ahs(struct iscsi_conn *conn, struct iscsi_cmnd *cmnd)
-@@ -83,14 +88,31 @@ static int is_data_available(struct iscs
- 
- static void forward_iov(struct msghdr *msg, int len)
- {
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+	struct iovec *iov;
-+
-+	while (msg->msg_iter.iov->iov_len <= len) {
-+		len -= msg->msg_iter.iov->iov_len;
-+		msg->msg_iter.iov++;
-+		msg->msg_iter.nr_segs--;
-+	}
-+#else
- 	while (msg->msg_iov->iov_len <= len) {
- 		len -= msg->msg_iov->iov_len;
- 		msg->msg_iov++;
- 		msg->msg_iovlen--;
- 	}
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+	/* XXX: discards const ... */
-+	iov = msg->msg_iter.iov;
-+	iov->iov_base = (char *) msg->msg_iter.iov->iov_base + len;
-+	iov->iov_len -= len;
-+#else
- 	msg->msg_iov->iov_base = (char *) msg->msg_iov->iov_base + len;
- 	msg->msg_iov->iov_len -= len;
-+#endif	/* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- }
- 
- static int do_recv(struct iscsi_conn *conn, int state)
-@@ -98,6 +120,9 @@ static int do_recv(struct iscsi_conn *co
- 	mm_segment_t oldfs;
- 	struct msghdr msg;
- 	struct iovec iov[ISCSI_CONN_IOV_MAX];
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+	size_t iovlen = ISCSI_CONN_IOV_MAX;
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- 	int i, len, res;
- 
- 	if (!test_bit(CONN_ACTIVE, &conn->state)) {
-@@ -110,12 +135,23 @@ static int do_recv(struct iscsi_conn *co
- 		goto out;
- 	}
- 
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+	if (conn->read_msg.msg_iter.nr_segs < iovlen)
-+		iovlen = conn->read_msg.msg_iter.nr_segs;
-+
-+	for (i = 0, len = 0; i < iovlen; i++) {
-+		iov[i] = conn->read_msg.msg_iter.iov[i];
-+		len += iov[i].iov_len;
-+	}
-+	iov_iter_init(&msg.msg_iter, READ, iov, iovlen, len);
-+#else
- 	msg.msg_iov = iov;
- 	msg.msg_iovlen = min_t(size_t, conn->read_msg.msg_iovlen, ISCSI_CONN_IOV_MAX);
- 	for (i = 0, len = 0; i < msg.msg_iovlen; i++) {
- 		iov[i] = conn->read_msg.msg_iov[i];
- 		len += iov[i].iov_len;
- 	}
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- 
- 	oldfs = get_fs();
- 	set_fs(get_ds());
-diff -Naurp iscsitarget-1.4.20.3+svn502_org/kernel/target_disk.c iscsitarget-1.4.20.3+svn502/kernel/target_disk.c
---- iscsitarget-1.4.20.3+svn502_org/kernel/target_disk.c	2014-05-06 13:59:55.000000000 -0700
-+++ iscsitarget-1.4.20.3+svn502/kernel/target_disk.c	2017-01-18 23:45:51.451010417 -0800
-@@ -606,7 +606,11 @@ static int disk_execute_cmnd(struct iscs
- 	case REQUEST_SENSE:
- 		send_data_rsp(cmnd, build_request_sense_response);
- 		break;
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+	case SERVICE_ACTION_IN_16:
-+#else
- 	case SERVICE_ACTION_IN:
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- 		send_data_rsp(cmnd, build_service_action_in_response);
- 		break;
- 	case READ_6:
-diff -Naurp iscsitarget-1.4.20.3+svn502_org/kernel/volume.c iscsitarget-1.4.20.3+svn502/kernel/volume.c
---- iscsitarget-1.4.20.3+svn502_org/kernel/volume.c	2014-05-06 13:59:55.000000000 -0700
-+++ iscsitarget-1.4.20.3+svn502/kernel/volume.c	2017-01-18 23:47:07.957561600 -0800
-@@ -398,7 +398,11 @@ int is_volume_reserved(struct iet_volume
- 		case READ_CAPACITY:
- 			/* allowed commands when reserved */
- 			break;
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+		case SERVICE_ACTION_IN_16:
-+#else
- 		case SERVICE_ACTION_IN:
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- 			if ((scb[1] & 0x1F) == 0x10)
- 				break;
- 			/* fall through */
-@@ -465,7 +469,11 @@ int is_volume_reserved(struct iet_volume
- 		if (excl_access_ro && !registered)
- 			err = -EBUSY;
- 		break;
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0)
-+	case SERVICE_ACTION_IN_16:
-+#else
- 	case SERVICE_ACTION_IN:
-+#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) */
- 		if ((scb[1] & 0x1F) == 0x10)
- 			break;
- 		/* fall through */
diff --git a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/use-kernel-makefile-to-get-kernel-version.patch b/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/use-kernel-makefile-to-get-kernel-version.patch
deleted file mode 100644
index 95bd047..0000000
--- a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/files/use-kernel-makefile-to-get-kernel-version.patch
+++ /dev/null
@@ -1,67 +0,0 @@
-Get linux kernel version from Makefile of kernel source
-
-We get below messages while building iscsitarget,
-
--- snip --
-x86_64-poky-linux-gcc: error:
-/CGE7_SHDD/project_yocto_1.8/poky/build/tmp/work-shared/qemux86-64/kernel-source/include/linux/version.h:
-No such file or directory
-x86_64-poky-linux-gcc: fatal error: no input files
-compilation terminated.
-/bin/sh: line 0: [: too many arguments
-/bin/sh: line 0: [: too many arguments
-/bin/sh: line 0: [: too many arguments
-/bin/sh: line 0: [: too many arguments
-/bin/sh: line 0: [: too many arguments
-/bin/sh: line 0: [: too many arguments
-/bin/sh: line 0: [: too many arguments
-/bin/sh: line 0: [: too many arguments
-/bin/sh: line 0: [: too many arguments
-/bin/sh: line 0: [: too many arguments
-/bin/sh: line 0: [: too many arguments
-/bin/sh: line 0: [: too many arguments
--- CUT --
-
-These messages are due to absence of include/linux/version.h file in 
-kernel source directory and failed to compute linux kernel version.
-So, use kernel source Makefile ( i.e $(KSRC)/Makefile) to find out 
-actual kernel version.
-
-Upstream-Status: Pending
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
-
---- iscsitarget-1.4.20.3+svn499_org/Makefile	2014-01-27 00:00:45.000000000 +0530
-+++ iscsitarget-1.4.20.3+svn499/Makefile	2015-07-23 10:44:47.013600285 +0530
-@@ -18,27 +18,11 @@ ifeq ($(KSRC),)
- endif
- 
- 
--ifneq ($(wildcard $(KSRC)/include/generated/utsrelease.h),)
--	VERSION_FILE := $(KSRC)/include/generated/utsrelease.h
--else
--  ifneq ($(wildcard $(KSRC)/include/linux/utsrelease.h),)
--	  VERSION_FILE := $(KSRC)/include/linux/utsrelease.h
--  else
--	  VERSION_FILE := $(KSRC)/include/linux/version.h
--  endif
--endif
--
--KVER := $(shell $(CC) $(CFLAGS) $(LDFLAGS) -E -dM $(VERSION_FILE) | \
--	grep UTS_RELEASE | awk '{ print $$3 }' | sed 's/\"//g')
--
- KMOD := /lib/modules/$(KVER)/extra
--
--KMAJ := $(shell echo $(KVER) | \
--	sed -e 's/^\([0-9][0-9]*\)\.[0-9][0-9]*\.[0-9][0-9]*.*/\1/')
--KMIN := $(shell echo $(KVER) | \
--	sed -e 's/^[0-9][0-9]*\.\([0-9][0-9]*\)\.[0-9][0-9]*.*/\1/')
--KREV := $(shell echo $(KVER) | \
--	sed -e 's/^[0-9][0-9]*\.[0-9][0-9]*\.\([0-9][0-9]*\).*/\1/')
-+KMAJ := $(shell cat $(KSRC)/Makefile | grep ^VERSION | gawk -F " " '{ print $$NF }')
-+KMIN := $(shell cat $(KSRC)/Makefile | grep ^PATCHLEVEL | gawk -F " " '{ print $$NF }')
-+KREV := $(shell cat $(KSRC)/Makefile | grep ^SUBLEVEL | gawk -F " " '{ print $$NF }')
-+KVER := ${KMAJ}.${KMIN}.${KREV}
- 
- kver_eq = $(shell [ $(KMAJ) -eq $(1) -a $(KMIN) -eq $(2) -a $(KREV) -eq $(3) ] && \
- 	echo 1 || echo 0)
diff --git a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/iscsitarget_1.4.20.3+svn502.bb b/meta-openembedded/meta-networking/recipes-extended/iscsitarget/iscsitarget_1.4.20.3+svn502.bb
deleted file mode 100644
index 5d13591..0000000
--- a/meta-openembedded/meta-networking/recipes-extended/iscsitarget/iscsitarget_1.4.20.3+svn502.bb
+++ /dev/null
@@ -1,64 +0,0 @@
-DESCRIPTION = "iSCSI Enterprise Target is aimed to develop an \
-               open source iSCSI target with professional features, \
-               that works well in enterprise environment under real \
-               workload, and is scalable and versatile enough to meet the \
-               challenge of future storage needs and developments."
-HOMEPAGE = "http://iscsitarget.sourceforge.net/"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=6e233eda45c807aa29aeaa6d94bc48a2"
-DEPENDS = "openssl virtual/kernel"
-
-SRC_URI = "http://ftp.heanet.ie/mirrors/ubuntu/pool/universe/i/${BPN}/${BPN}_${PV}.orig.tar.gz \
-           file://use-kernel-makefile-to-get-kernel-version.patch \
-           file://fix-errors-observed-with-linux-3.19-and-greater.patch \
-           file://access-sk_v6_daddr-iff-IPV6-defined.patch \
-           file://build_with_updated_bio_struct_of_linux_v4.3_and_above.patch \
-           file://build_with_updated_interfaces_of_linux_v4.8_and_above.patch \
-           file://fix-call-trace-of-ahash-API-calling.patch \
-           file://0001-kernel-event-netlink_ack-now-requires-4-arguments.patch \
-           "
-
-SRC_URI[md5sum] = "ef9bc823bbabd3c772208c00d5f2d089"
-SRC_URI[sha256sum] = "d3196ccb78a43266dce28587bfe30d8ab4db7566d7bce96057dfbb84100babb5"
-
-inherit module
-
-do_configure[noexec] = "1"
-
-# make_scripts requires kernel source directory to create
-# kernel scripts
-do_make_scripts[depends] += "virtual/kernel:do_shared_workdir"
-
-do_compile() {
-    oe_runmake KSRC=${STAGING_KERNEL_DIR} LDFLAGS='' V=1 kernel
-    oe_runmake KSRC=${STAGING_KERNEL_DIR} usr
-}
-
-do_install() {
-    # Module
-    install -d ${D}/lib/modules/${KERNEL_VERSION}/kernel/iscsi
-    install -m 0644 kernel/iscsi_trgt.ko \
-    ${D}/lib/modules/${KERNEL_VERSION}/kernel/iscsi/iscsi_trgt.ko
-
-    # Userspace utilities
-    install -d ${D}${sbindir}
-    install -m 0755 usr/ietd ${D}${sbindir}/ietd
-    install -m 0755 usr/ietadm ${D}${sbindir}/ietadm
-
-    # Config files, init scripts
-    mkdir -p ${D}${sysconfdir}/iet
-    install -m 0644 etc/ietd.conf ${D}/${sysconfdir}/iet/ietd.conf
-    install -m 0644 etc/initiators.allow ${D}${sysconfdir}/iet/initiators.allow
-    install -m 0644 etc/targets.allow ${D}${sysconfdir}/iet/targets.allow
-    mkdir -p ${D}${sysconfdir}/init.d
-    install -m 0755 etc/initd/initd ${D}${sysconfdir}/init.d/iscsi-target
-    install -m 0644 etc/initiators.deny ${D}${sysconfdir}/iet/initiators.deny
-}
-
-FILES_${PN} += "${sbindir} \
-                ${sysconfdir}"
-
-RDEPENDS_${PN} = "kernel-module-iscsi-trgt"
-RRECOMMENDS_${PN} = "kernel-module-crc32c kernel-module-libcrc32c"
-
-PNBLACKLIST[iscsitarget] = "error: implicit declaration of function 'init_timer'; did you mean 'init_timers'?; 4.15 kernel issues"
diff --git a/meta-openembedded/meta-networking/recipes-filter/conntrack-tools/conntrack-tools_1.4.4.bb b/meta-openembedded/meta-networking/recipes-filter/conntrack-tools/conntrack-tools_1.4.4.bb
index 8b3490d..46168b0 100644
--- a/meta-openembedded/meta-networking/recipes-filter/conntrack-tools/conntrack-tools_1.4.4.bb
+++ b/meta-openembedded/meta-networking/recipes-filter/conntrack-tools/conntrack-tools_1.4.4.bb
@@ -4,11 +4,9 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=8ca43cbc842c2336e835926c2166c28b"
 
 DEPENDS = "libnfnetlink libnetfilter-conntrack libnetfilter-cttimeout \
-           libnetfilter-cthelper libnetfilter-queue bison-native"
+           libnetfilter-cthelper libnetfilter-queue bison-native libtirpc"
 
-DEPENDS_append_libc-musl = " libtirpc"
-CFLAGS_append_libc-musl = " -I${STAGING_INCDIR}/tirpc"
-LDFLAGS_append_libc-musl = " -ltirpc"
+EXTRA_OECONF += "LIBS=-ltirpc CPPFLAGS=-I${STAGING_INCDIR}/tirpc"
 
 SRC_URI = "http://www.netfilter.org/projects/conntrack-tools/files/conntrack-tools-${PV}.tar.bz2;name=tar \
     file://conntrack-failover \
diff --git a/meta-openembedded/meta-networking/recipes-filter/ebtables/ebtables_2.0.10-4.bb b/meta-openembedded/meta-networking/recipes-filter/ebtables/ebtables_2.0.10-4.bb
index b9dce69..f05bd61 100644
--- a/meta-openembedded/meta-networking/recipes-filter/ebtables/ebtables_2.0.10-4.bb
+++ b/meta-openembedded/meta-networking/recipes-filter/ebtables/ebtables_2.0.10-4.bb
@@ -36,6 +36,15 @@
 SRC_URI[md5sum] = "506742a3d44b9925955425a659c1a8d0"
 SRC_URI[sha256sum] = "dc6f7b484f207dc712bfca81645f45120cb6aee3380e77a1771e9c34a9a4455d"
 
+# It is using '-' but not '.' as delimiter for the version in the releases page,
+# which causes the version comparison unmatched.
+#UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/ebtables/files/ebtables/"
+#UPSTREAM_CHECK_REGEX = "ebtables-(?P<pver>\d+(\-\d+)+)"
+
+RECIPE_UPSTREAM_VERSION = "2.0.10-4"
+RECIPE_UPSTREAM_DATE = "Dec 15, 2011"
+CHECK_DATE = "May 25, 2018"
+
 S = "${WORKDIR}/ebtables-v${PV}"
 
 inherit update-rc.d systemd
diff --git a/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl/0001-Declare-the-define-visivility-attribute-together.patch b/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl/0001-Declare-the-define-visivility-attribute-together.patch
deleted file mode 100644
index e82b238..0000000
--- a/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl/0001-Declare-the-define-visivility-attribute-together.patch
+++ /dev/null
@@ -1,2949 +0,0 @@
-From bd01f785da5222d0662be3182fe2650e1c12f43e Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 10 Apr 2017 14:07:07 -0700
-Subject: [PATCH] Declare the define visivility attribute together
-
-clang ignores the visibility attribute if its not
-defined before the definition. As a result these
-symbols become hidden and consumers of this library
-fail to link due to these missing symbols
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- doxygen.cfg.in  |   2 +-
- include/utils.h |   5 +--
- src/batch.c     |  21 ++++-------
- src/chain.c     | 102 +++++++++++++++++---------------------------------
- src/common.c    |  21 ++++-------
- src/expr.c      |  51 +++++++++----------------
- src/gen.c       |  39 +++++++------------
- src/object.c    |  99 ++++++++++++++++--------------------------------
- src/rule.c      | 114 +++++++++++++++++++-------------------------------------
- src/ruleset.c   |  48 ++++++++----------------
- src/set.c       |  96 ++++++++++++++++-------------------------------
- src/set_elem.c  |  72 ++++++++++++-----------------------
- src/table.c     |  90 +++++++++++++++-----------------------------
- src/trace.c     |  27 +++++---------
- src/udata.c     |  48 ++++++++----------------
- 15 files changed, 279 insertions(+), 556 deletions(-)
-
-diff --git a/doxygen.cfg.in b/doxygen.cfg.in
-index 23fcad4..e49f28d 100644
---- a/doxygen.cfg.in
-+++ b/doxygen.cfg.in
-@@ -72,7 +72,7 @@ RECURSIVE              = YES
- EXCLUDE                = 
- EXCLUDE_SYMLINKS       = NO
- EXCLUDE_PATTERNS       = */.git/* .*.d
--EXCLUDE_SYMBOLS        = EXPORT_SYMBOL
-+EXCLUDE_SYMBOLS        =
- EXAMPLE_PATH           = 
- EXAMPLE_PATTERNS       = 
- EXAMPLE_RECURSIVE      = NO
-diff --git a/include/utils.h b/include/utils.h
-index 2f5cf34..ff8207e 100644
---- a/include/utils.h
-+++ b/include/utils.h
-@@ -9,10 +9,9 @@
- 
- #include "config.h"
- #ifdef HAVE_VISIBILITY_HIDDEN
--#	define __visible	__attribute__((visibility("default")))
--#	define EXPORT_SYMBOL(x)	typeof(x) (x) __visible;
-+#	define __EXPORTED	__attribute__((visibility("default")))
- #else
--#	define EXPORT_SYMBOL
-+#	define __EXPORT
- #endif
- 
- #define __noreturn	__attribute__((__noreturn__))
-diff --git a/src/batch.c b/src/batch.c
-index 5ee3fd7..3bedd26 100644
---- a/src/batch.c
-+++ b/src/batch.c
-@@ -57,7 +57,7 @@ static void nftnl_batch_add_page(struct nftnl_batch_page *page,
- 	list_add_tail(&page->head, &batch->page_list);
- }
- 
--struct nftnl_batch *nftnl_batch_alloc(uint32_t pg_size, uint32_t pg_overrun_size)
-+struct nftnl_batch __EXPORTED *nftnl_batch_alloc(uint32_t pg_size, uint32_t pg_overrun_size)
- {
- 	struct nftnl_batch *batch;
- 	struct nftnl_batch_page *page;
-@@ -80,9 +80,8 @@ err1:
- 	free(batch);
- 	return NULL;
- }
--EXPORT_SYMBOL(nftnl_batch_alloc);
- 
--void nftnl_batch_free(struct nftnl_batch *batch)
-+void __EXPORTED nftnl_batch_free(struct nftnl_batch *batch)
- {
- 	struct nftnl_batch_page *page, *next;
- 
-@@ -94,9 +93,8 @@ void nftnl_batch_free(struct nftnl_batch *batch)
- 
- 	free(batch);
- }
--EXPORT_SYMBOL(nftnl_batch_free);
- 
--int nftnl_batch_update(struct nftnl_batch *batch)
-+int __EXPORTED nftnl_batch_update(struct nftnl_batch *batch)
- {
- 	struct nftnl_batch_page *page;
- 	struct nlmsghdr *last_nlh;
-@@ -119,21 +117,18 @@ int nftnl_batch_update(struct nftnl_batch *batch)
- err1:
- 	return -1;
- }
--EXPORT_SYMBOL(nftnl_batch_update);
- 
--void *nftnl_batch_buffer(struct nftnl_batch *batch)
-+void __EXPORTED *nftnl_batch_buffer(struct nftnl_batch *batch)
- {
- 	return mnl_nlmsg_batch_current(batch->current_page->batch);
- }
--EXPORT_SYMBOL(nftnl_batch_buffer);
- 
--uint32_t nftnl_batch_buffer_len(struct nftnl_batch *batch)
-+uint32_t __EXPORTED nftnl_batch_buffer_len(struct nftnl_batch *batch)
- {
- 	return mnl_nlmsg_batch_size(batch->current_page->batch);
- }
--EXPORT_SYMBOL(nftnl_batch_buffer_len);
- 
--int nftnl_batch_iovec_len(struct nftnl_batch *batch)
-+int __EXPORTED nftnl_batch_iovec_len(struct nftnl_batch *batch)
- {
- 	int num_pages = batch->num_pages;
- 
-@@ -143,9 +138,8 @@ int nftnl_batch_iovec_len(struct nftnl_batch *batch)
- 
- 	return num_pages;
- }
--EXPORT_SYMBOL(nftnl_batch_iovec_len);
- 
--void nftnl_batch_iovec(struct nftnl_batch *batch, struct iovec *iov,
-+void __EXPORTED nftnl_batch_iovec(struct nftnl_batch *batch, struct iovec *iov,
- 		       uint32_t iovlen)
- {
- 	struct nftnl_batch_page *page;
-@@ -160,4 +154,3 @@ void nftnl_batch_iovec(struct nftnl_batch *batch, struct iovec *iov,
- 		i++;
- 	}
- }
--EXPORT_SYMBOL(nftnl_batch_iovec);
-diff --git a/src/chain.c b/src/chain.c
-index 29860c5..362fa0d 100644
---- a/src/chain.c
-+++ b/src/chain.c
-@@ -87,13 +87,12 @@ static const char *nftnl_hooknum2str(int family, int hooknum)
- 	return "unknown";
- }
- 
--struct nftnl_chain *nftnl_chain_alloc(void)
-+struct nftnl_chain __EXPORTED *nftnl_chain_alloc(void)
- {
- 	return calloc(1, sizeof(struct nftnl_chain));
- }
--EXPORT_SYMBOL(nftnl_chain_alloc);
- 
--void nftnl_chain_free(const struct nftnl_chain *c)
-+void __EXPORTED nftnl_chain_free(const struct nftnl_chain *c)
- {
- 	if (c->flags & (1 << NFTNL_CHAIN_NAME))
- 		xfree(c->name);
-@@ -105,15 +104,13 @@ void nftnl_chain_free(const struct nftnl_chain *c)
- 		xfree(c->dev);
- 	xfree(c);
- }
--EXPORT_SYMBOL(nftnl_chain_free);
- 
--bool nftnl_chain_is_set(const struct nftnl_chain *c, uint16_t attr)
-+bool __EXPORTED nftnl_chain_is_set(const struct nftnl_chain *c, uint16_t attr)
- {
- 	return c->flags & (1 << attr);
- }
--EXPORT_SYMBOL(nftnl_chain_is_set);
- 
--void nftnl_chain_unset(struct nftnl_chain *c, uint16_t attr)
-+void __EXPORTED nftnl_chain_unset(struct nftnl_chain *c, uint16_t attr)
- {
- 	if (!(c->flags & (1 << attr)))
- 		return;
-@@ -147,7 +144,6 @@ void nftnl_chain_unset(struct nftnl_chain *c, uint16_t attr)
- 
- 	c->flags &= ~(1 << attr);
- }
--EXPORT_SYMBOL(nftnl_chain_unset);
- 
- static uint32_t nftnl_chain_validate[NFTNL_CHAIN_MAX + 1] = {
- 	[NFTNL_CHAIN_HOOKNUM]	= sizeof(uint32_t),
-@@ -159,7 +155,7 @@ static uint32_t nftnl_chain_validate[NFTNL_CHAIN_MAX + 1] = {
- 	[NFTNL_CHAIN_FAMILY]		= sizeof(uint32_t),
- };
- 
--int nftnl_chain_set_data(struct nftnl_chain *c, uint16_t attr,
-+int __EXPORTED nftnl_chain_set_data(struct nftnl_chain *c, uint16_t attr,
- 			 const void *data, uint32_t data_len)
- {
- 	nftnl_assert_attr_exists(attr, NFTNL_CHAIN_MAX);
-@@ -226,45 +222,38 @@ int nftnl_chain_set_data(struct nftnl_chain *c, uint16_t attr,
- 	c->flags |= (1 << attr);
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_chain_set_data);
- 
--void nftnl_chain_set(struct nftnl_chain *c, uint16_t attr, const void *data)
-+void __EXPORTED nftnl_chain_set(struct nftnl_chain *c, uint16_t attr, const void *data)
- {
- 	nftnl_chain_set_data(c, attr, data, nftnl_chain_validate[attr]);
- }
--EXPORT_SYMBOL(nftnl_chain_set);
- 
--void nftnl_chain_set_u32(struct nftnl_chain *c, uint16_t attr, uint32_t data)
-+void __EXPORTED nftnl_chain_set_u32(struct nftnl_chain *c, uint16_t attr, uint32_t data)
- {
- 	nftnl_chain_set_data(c, attr, &data, sizeof(uint32_t));
- }
--EXPORT_SYMBOL(nftnl_chain_set_u32);
- 
--void nftnl_chain_set_s32(struct nftnl_chain *c, uint16_t attr, int32_t data)
-+void __EXPORTED nftnl_chain_set_s32(struct nftnl_chain *c, uint16_t attr, int32_t data)
- {
- 	nftnl_chain_set_data(c, attr, &data, sizeof(int32_t));
- }
--EXPORT_SYMBOL(nftnl_chain_set_s32);
- 
--void nftnl_chain_set_u64(struct nftnl_chain *c, uint16_t attr, uint64_t data)
-+void __EXPORTED nftnl_chain_set_u64(struct nftnl_chain *c, uint16_t attr, uint64_t data)
- {
- 	nftnl_chain_set_data(c, attr, &data, sizeof(uint64_t));
- }
--EXPORT_SYMBOL(nftnl_chain_set_u64);
- 
--void nftnl_chain_set_u8(struct nftnl_chain *c, uint16_t attr, uint8_t data)
-+void __EXPORTED nftnl_chain_set_u8(struct nftnl_chain *c, uint16_t attr, uint8_t data)
- {
- 	nftnl_chain_set_data(c, attr, &data, sizeof(uint8_t));
- }
--EXPORT_SYMBOL(nftnl_chain_set_u8);
- 
--int nftnl_chain_set_str(struct nftnl_chain *c, uint16_t attr, const char *str)
-+int __EXPORTED nftnl_chain_set_str(struct nftnl_chain *c, uint16_t attr, const char *str)
- {
- 	return nftnl_chain_set_data(c, attr, str, strlen(str) + 1);
- }
--EXPORT_SYMBOL(nftnl_chain_set_str);
- 
--const void *nftnl_chain_get_data(const struct nftnl_chain *c, uint16_t attr,
-+const void __EXPORTED *nftnl_chain_get_data(const struct nftnl_chain *c, uint16_t attr,
- 				 uint32_t *data_len)
- {
- 	if (!(c->flags & (1 << attr)))
-@@ -310,22 +299,19 @@ const void *nftnl_chain_get_data(const struct nftnl_chain *c, uint16_t attr,
- 	}
- 	return NULL;
- }
--EXPORT_SYMBOL(nftnl_chain_get_data);
- 
--const void *nftnl_chain_get(const struct nftnl_chain *c, uint16_t attr)
-+const void __EXPORTED *nftnl_chain_get(const struct nftnl_chain *c, uint16_t attr)
- {
- 	uint32_t data_len;
- 	return nftnl_chain_get_data(c, attr, &data_len);
- }
--EXPORT_SYMBOL(nftnl_chain_get);
- 
--const char *nftnl_chain_get_str(const struct nftnl_chain *c, uint16_t attr)
-+const char __EXPORTED *nftnl_chain_get_str(const struct nftnl_chain *c, uint16_t attr)
- {
- 	return nftnl_chain_get(c, attr);
- }
--EXPORT_SYMBOL(nftnl_chain_get_str);
- 
--uint32_t nftnl_chain_get_u32(const struct nftnl_chain *c, uint16_t attr)
-+uint32_t __EXPORTED nftnl_chain_get_u32(const struct nftnl_chain *c, uint16_t attr)
- {
- 	uint32_t data_len;
- 	const uint32_t *val = nftnl_chain_get_data(c, attr, &data_len);
-@@ -334,9 +320,8 @@ uint32_t nftnl_chain_get_u32(const struct nftnl_chain *c, uint16_t attr)
- 
- 	return val ? *val : 0;
- }
--EXPORT_SYMBOL(nftnl_chain_get_u32);
- 
--int32_t nftnl_chain_get_s32(const struct nftnl_chain *c, uint16_t attr)
-+int32_t __EXPORTED nftnl_chain_get_s32(const struct nftnl_chain *c, uint16_t attr)
- {
- 	uint32_t data_len;
- 	const int32_t *val = nftnl_chain_get_data(c, attr, &data_len);
-@@ -345,9 +330,8 @@ int32_t nftnl_chain_get_s32(const struct nftnl_chain *c, uint16_t attr)
- 
- 	return val ? *val : 0;
- }
--EXPORT_SYMBOL(nftnl_chain_get_s32);
- 
--uint64_t nftnl_chain_get_u64(const struct nftnl_chain *c, uint16_t attr)
-+uint64_t __EXPORTED nftnl_chain_get_u64(const struct nftnl_chain *c, uint16_t attr)
- {
- 	uint32_t data_len;
- 	const uint64_t *val = nftnl_chain_get_data(c, attr, &data_len);
-@@ -356,9 +340,8 @@ uint64_t nftnl_chain_get_u64(const struct nftnl_chain *c, uint16_t attr)
- 
- 	return val ? *val : 0;
- }
--EXPORT_SYMBOL(nftnl_chain_get_u64);
- 
--uint8_t nftnl_chain_get_u8(const struct nftnl_chain *c, uint16_t attr)
-+uint8_t __EXPORTED nftnl_chain_get_u8(const struct nftnl_chain *c, uint16_t attr)
- {
- 	uint32_t data_len;
- 	const uint8_t *val = nftnl_chain_get_data(c, attr, &data_len);
-@@ -367,9 +350,8 @@ uint8_t nftnl_chain_get_u8(const struct nftnl_chain *c, uint16_t attr)
- 
- 	return val ? *val : 0;
- }
--EXPORT_SYMBOL(nftnl_chain_get_u8);
- 
--void nftnl_chain_nlmsg_build_payload(struct nlmsghdr *nlh, const struct nftnl_chain *c)
-+void __EXPORTED nftnl_chain_nlmsg_build_payload(struct nlmsghdr *nlh, const struct nftnl_chain *c)
- {
- 	if (c->flags & (1 << NFTNL_CHAIN_TABLE))
- 		mnl_attr_put_strz(nlh, NFTA_CHAIN_TABLE, c->table);
-@@ -404,7 +386,6 @@ void nftnl_chain_nlmsg_build_payload(struct nlmsghdr *nlh, const struct nftnl_ch
- 	if (c->flags & (1 << NFTNL_CHAIN_TYPE))
- 		mnl_attr_put_strz(nlh, NFTA_CHAIN_TYPE, c->type);
- }
--EXPORT_SYMBOL(nftnl_chain_nlmsg_build_payload);
- 
- static int nftnl_chain_parse_attr_cb(const struct nlattr *attr, void *data)
- {
-@@ -529,7 +510,7 @@ static int nftnl_chain_parse_hook(struct nlattr *attr, struct nftnl_chain *c)
- 	return 0;
- }
- 
--int nftnl_chain_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_chain *c)
-+int __EXPORTED nftnl_chain_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_chain *c)
- {
- 	struct nlattr *tb[NFTA_CHAIN_MAX+1] = {};
- 	struct nfgenmsg *nfg = mnl_nlmsg_get_payload(nlh);
-@@ -590,7 +571,6 @@ int nftnl_chain_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_chain *c)
- 
- 	return ret;
- }
--EXPORT_SYMBOL(nftnl_chain_nlmsg_parse);
- 
- static inline int nftnl_str2hooknum(int family, const char *hook)
- {
-@@ -732,19 +712,17 @@ static int nftnl_chain_do_parse(struct nftnl_chain *c, enum nftnl_parse_type typ
- 	return ret;
- }
- 
--int nftnl_chain_parse(struct nftnl_chain *c, enum nftnl_parse_type type,
-+int __EXPORTED nftnl_chain_parse(struct nftnl_chain *c, enum nftnl_parse_type type,
- 		    const char *data, struct nftnl_parse_err *err)
- {
- 	return nftnl_chain_do_parse(c, type, data, err, NFTNL_PARSE_BUFFER);
- }
--EXPORT_SYMBOL(nftnl_chain_parse);
- 
--int nftnl_chain_parse_file(struct nftnl_chain *c, enum nftnl_parse_type type,
-+int __EXPORTED nftnl_chain_parse_file(struct nftnl_chain *c, enum nftnl_parse_type type,
- 			 FILE *fp, struct nftnl_parse_err *err)
- {
- 	return nftnl_chain_do_parse(c, type, fp, err, NFTNL_PARSE_FILE);
- }
--EXPORT_SYMBOL(nftnl_chain_parse_file);
- 
- static int nftnl_chain_export(char *buf, size_t size,
- 			      const struct nftnl_chain *c, int type)
-@@ -841,13 +819,12 @@ static int nftnl_chain_cmd_snprintf(char *buf, size_t size,
- 	return offset;
- }
- 
--int nftnl_chain_snprintf(char *buf, size_t size, const struct nftnl_chain *c,
-+int __EXPORTED nftnl_chain_snprintf(char *buf, size_t size, const struct nftnl_chain *c,
- 			 uint32_t type, uint32_t flags)
- {
- 	return nftnl_chain_cmd_snprintf(buf, size, c, nftnl_flag2cmd(flags), type,
- 				      flags);
- }
--EXPORT_SYMBOL(nftnl_chain_snprintf);
- 
- static int nftnl_chain_do_snprintf(char *buf, size_t size, const void *c,
- 				   uint32_t cmd, uint32_t type, uint32_t flags)
-@@ -855,19 +832,18 @@ static int nftnl_chain_do_snprintf(char *buf, size_t size, const void *c,
- 	return nftnl_chain_snprintf(buf, size, c, type, flags);
- }
- 
--int nftnl_chain_fprintf(FILE *fp, const struct nftnl_chain *c, uint32_t type,
-+int __EXPORTED nftnl_chain_fprintf(FILE *fp, const struct nftnl_chain *c, uint32_t type,
- 			uint32_t flags)
- {
- 	return nftnl_fprintf(fp, c, NFTNL_CMD_UNSPEC, type, flags,
- 			   nftnl_chain_do_snprintf);
- }
--EXPORT_SYMBOL(nftnl_chain_fprintf);
- 
- struct nftnl_chain_list {
- 	struct list_head list;
- };
- 
--struct nftnl_chain_list *nftnl_chain_list_alloc(void)
-+struct nftnl_chain_list __EXPORTED *nftnl_chain_list_alloc(void)
- {
- 	struct nftnl_chain_list *list;
- 
-@@ -879,9 +855,8 @@ struct nftnl_chain_list *nftnl_chain_list_alloc(void)
- 
- 	return list;
- }
--EXPORT_SYMBOL(nftnl_chain_list_alloc);
- 
--void nftnl_chain_list_free(struct nftnl_chain_list *list)
-+void __EXPORTED nftnl_chain_list_free(struct nftnl_chain_list *list)
- {
- 	struct nftnl_chain *r, *tmp;
- 
-@@ -891,33 +866,28 @@ void nftnl_chain_list_free(struct nftnl_chain_list *list)
- 	}
- 	xfree(list);
- }
--EXPORT_SYMBOL(nftnl_chain_list_free);
- 
--int nftnl_chain_list_is_empty(const struct nftnl_chain_list *list)
-+int __EXPORTED nftnl_chain_list_is_empty(const struct nftnl_chain_list *list)
- {
- 	return list_empty(&list->list);
- }
--EXPORT_SYMBOL(nftnl_chain_list_is_empty);
- 
--void nftnl_chain_list_add(struct nftnl_chain *r, struct nftnl_chain_list *list)
-+void __EXPORTED nftnl_chain_list_add(struct nftnl_chain *r, struct nftnl_chain_list *list)
- {
- 	list_add(&r->head, &list->list);
- }
--EXPORT_SYMBOL(nftnl_chain_list_add);
- 
--void nftnl_chain_list_add_tail(struct nftnl_chain *r, struct nftnl_chain_list *list)
-+void __EXPORTED nftnl_chain_list_add_tail(struct nftnl_chain *r, struct nftnl_chain_list *list)
- {
- 	list_add_tail(&r->head, &list->list);
- }
--EXPORT_SYMBOL(nftnl_chain_list_add_tail);
- 
--void nftnl_chain_list_del(struct nftnl_chain *r)
-+void __EXPORTED nftnl_chain_list_del(struct nftnl_chain *r)
- {
- 	list_del(&r->head);
- }
--EXPORT_SYMBOL(nftnl_chain_list_del);
- 
--int nftnl_chain_list_foreach(struct nftnl_chain_list *chain_list,
-+int __EXPORTED nftnl_chain_list_foreach(struct nftnl_chain_list *chain_list,
- 			   int (*cb)(struct nftnl_chain *r, void *data),
- 			   void *data)
- {
-@@ -931,14 +901,13 @@ int nftnl_chain_list_foreach(struct nftnl_chain_list *chain_list,
- 	}
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_chain_list_foreach);
- 
- struct nftnl_chain_list_iter {
- 	const struct nftnl_chain_list	*list;
- 	struct nftnl_chain		*cur;
- };
- 
--struct nftnl_chain_list_iter *
-+struct nftnl_chain_list_iter __EXPORTED *
- nftnl_chain_list_iter_create(const struct nftnl_chain_list *l)
- {
- 	struct nftnl_chain_list_iter *iter;
-@@ -955,9 +924,8 @@ nftnl_chain_list_iter_create(const struct nftnl_chain_list *l)
- 
- 	return iter;
- }
--EXPORT_SYMBOL(nftnl_chain_list_iter_create);
- 
--struct nftnl_chain *nftnl_chain_list_iter_next(struct nftnl_chain_list_iter *iter)
-+struct nftnl_chain __EXPORTED *nftnl_chain_list_iter_next(struct nftnl_chain_list_iter *iter)
- {
- 	struct nftnl_chain *r = iter->cur;
- 
-@@ -971,10 +939,8 @@ struct nftnl_chain *nftnl_chain_list_iter_next(struct nftnl_chain_list_iter *ite
- 
- 	return r;
- }
--EXPORT_SYMBOL(nftnl_chain_list_iter_next);
- 
--void nftnl_chain_list_iter_destroy(struct nftnl_chain_list_iter *iter)
-+void __EXPORTED nftnl_chain_list_iter_destroy(struct nftnl_chain_list_iter *iter)
- {
- 	xfree(iter);
- }
--EXPORT_SYMBOL(nftnl_chain_list_iter_destroy);
-diff --git a/src/common.c b/src/common.c
-index a95883c..68bce2e 100644
---- a/src/common.c
-+++ b/src/common.c
-@@ -43,15 +43,14 @@ static struct nlmsghdr *__nftnl_nlmsg_build_hdr(char *buf, uint16_t type,
- 	return nlh;
- }
- 
--struct nlmsghdr *nftnl_nlmsg_build_hdr(char *buf, uint16_t type, uint16_t family,
-+struct nlmsghdr __EXPORTED *nftnl_nlmsg_build_hdr(char *buf, uint16_t type, uint16_t family,
- 				       uint16_t flags, uint32_t seq)
- {
- 	return __nftnl_nlmsg_build_hdr(buf, (NFNL_SUBSYS_NFTABLES << 8) | type,
- 				       family, flags, seq, 0);
- }
--EXPORT_SYMBOL(nftnl_nlmsg_build_hdr);
- 
--struct nftnl_parse_err *nftnl_parse_err_alloc(void)
-+struct nftnl_parse_err __EXPORTED *nftnl_parse_err_alloc(void)
- {
- 	struct nftnl_parse_err *err;
- 
-@@ -63,15 +62,13 @@ struct nftnl_parse_err *nftnl_parse_err_alloc(void)
- 
- 	return err;
- }
--EXPORT_SYMBOL(nftnl_parse_err_alloc);
- 
--void nftnl_parse_err_free(struct nftnl_parse_err *err)
-+void __EXPORTED nftnl_parse_err_free(struct nftnl_parse_err *err)
- {
- 	xfree(err);
- }
--EXPORT_SYMBOL(nftnl_parse_err_free);
- 
--int nftnl_parse_perror(const char *msg, struct nftnl_parse_err *err)
-+int __EXPORTED nftnl_parse_perror(const char *msg, struct nftnl_parse_err *err)
- {
- 	switch (err->error) {
- 	case NFTNL_PARSE_EBADINPUT:
-@@ -89,7 +86,6 @@ int nftnl_parse_perror(const char *msg, struct nftnl_parse_err *err)
- 		return fprintf(stderr, "%s: Undefined error\n", msg);
- 	}
- }
--EXPORT_SYMBOL(nftnl_parse_perror);
- 
- int nftnl_cmd_header_snprintf(char *buf, size_t size, uint32_t cmd, uint32_t type,
- 			    uint32_t flags)
-@@ -165,21 +161,19 @@ int nftnl_cmd_footer_fprintf(FILE *fp, uint32_t cmd, uint32_t type,
- 			   nftnl_cmd_footer_fprintf_cb);
- }
- 
--struct nlmsghdr *nftnl_batch_begin(char *buf, uint32_t seq)
-+struct nlmsghdr __EXPORTED *nftnl_batch_begin(char *buf, uint32_t seq)
- {
- 	return __nftnl_nlmsg_build_hdr(buf, NFNL_MSG_BATCH_BEGIN, AF_UNSPEC,
- 				       0, seq, NFNL_SUBSYS_NFTABLES);
- }
--EXPORT_SYMBOL(nftnl_batch_begin);
- 
--struct nlmsghdr *nftnl_batch_end(char *buf, uint32_t seq)
-+struct nlmsghdr __EXPORTED *nftnl_batch_end(char *buf, uint32_t seq)
- {
- 	return __nftnl_nlmsg_build_hdr(buf, NFNL_MSG_BATCH_END, AF_UNSPEC,
- 				       0, seq, NFNL_SUBSYS_NFTABLES);
- }
--EXPORT_SYMBOL(nftnl_batch_end);
- 
--int nftnl_batch_is_supported(void)
-+int __EXPORTED nftnl_batch_is_supported(void)
- {
- 	struct mnl_socket *nl;
- 	struct mnl_nlmsg_batch *b;
-@@ -236,4 +230,3 @@ err:
- 	mnl_nlmsg_batch_stop(b);
- 	return -1;
- }
--EXPORT_SYMBOL(nftnl_batch_is_supported);
-diff --git a/src/expr.c b/src/expr.c
-index 10ba2c4..c7eb2b4 100644
---- a/src/expr.c
-+++ b/src/expr.c
-@@ -24,7 +24,7 @@
- 
- #include <libnftnl/expr.h>
- 
--struct nftnl_expr *nftnl_expr_alloc(const char *name)
-+struct nftnl_expr __EXPORTED *nftnl_expr_alloc(const char *name)
- {
- 	struct nftnl_expr *expr;
- 	struct expr_ops *ops;
-@@ -43,24 +43,21 @@ struct nftnl_expr *nftnl_expr_alloc(const char *name)
- 
- 	return expr;
- }
--EXPORT_SYMBOL(nftnl_expr_alloc);
- 
--void nftnl_expr_free(const struct nftnl_expr *expr)
-+void __EXPORTED nftnl_expr_free(const struct nftnl_expr *expr)
- {
- 	if (expr->ops->free)
- 		expr->ops->free(expr);
- 
- 	xfree(expr);
- }
--EXPORT_SYMBOL(nftnl_expr_free);
- 
--bool nftnl_expr_is_set(const struct nftnl_expr *expr, uint16_t type)
-+bool __EXPORTED nftnl_expr_is_set(const struct nftnl_expr *expr, uint16_t type)
- {
- 	return expr->flags & (1 << type);
- }
--EXPORT_SYMBOL(nftnl_expr_is_set);
- 
--int nftnl_expr_set(struct nftnl_expr *expr, uint16_t type,
-+int __EXPORTED nftnl_expr_set(struct nftnl_expr *expr, uint16_t type,
- 		   const void *data, uint32_t data_len)
- {
- 	switch(type) {
-@@ -73,43 +70,37 @@ int nftnl_expr_set(struct nftnl_expr *expr, uint16_t type,
- 	expr->flags |= (1 << type);
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_expr_set);
- 
--void
-+void __EXPORTED
- nftnl_expr_set_u8(struct nftnl_expr *expr, uint16_t type, uint8_t data)
- {
- 	nftnl_expr_set(expr, type, &data, sizeof(uint8_t));
- }
--EXPORT_SYMBOL(nftnl_expr_set_u8);
- 
--void
-+void __EXPORTED
- nftnl_expr_set_u16(struct nftnl_expr *expr, uint16_t type, uint16_t data)
- {
- 	nftnl_expr_set(expr, type, &data, sizeof(uint16_t));
- }
--EXPORT_SYMBOL(nftnl_expr_set_u16);
- 
--void
-+void __EXPORTED
- nftnl_expr_set_u32(struct nftnl_expr *expr, uint16_t type, uint32_t data)
- {
- 	nftnl_expr_set(expr, type, &data, sizeof(uint32_t));
- }
--EXPORT_SYMBOL(nftnl_expr_set_u32);
- 
--void
-+void __EXPORTED
- nftnl_expr_set_u64(struct nftnl_expr *expr, uint16_t type, uint64_t data)
- {
- 	nftnl_expr_set(expr, type, &data, sizeof(uint64_t));
- }
--EXPORT_SYMBOL(nftnl_expr_set_u64);
- 
--int nftnl_expr_set_str(struct nftnl_expr *expr, uint16_t type, const char *str)
-+int __EXPORTED nftnl_expr_set_str(struct nftnl_expr *expr, uint16_t type, const char *str)
- {
- 	return nftnl_expr_set(expr, type, str, strlen(str) + 1);
- }
--EXPORT_SYMBOL(nftnl_expr_set_str);
- 
--const void *nftnl_expr_get(const struct nftnl_expr *expr,
-+const void __EXPORTED *nftnl_expr_get(const struct nftnl_expr *expr,
- 			      uint16_t type, uint32_t *data_len)
- {
- 	const void *ret;
-@@ -129,9 +120,8 @@ const void *nftnl_expr_get(const struct nftnl_expr *expr,
- 
- 	return ret;
- }
--EXPORT_SYMBOL(nftnl_expr_get);
- 
--uint8_t nftnl_expr_get_u8(const struct nftnl_expr *expr, uint16_t type)
-+uint8_t __EXPORTED nftnl_expr_get_u8(const struct nftnl_expr *expr, uint16_t type)
- {
- 	const void *data;
- 	uint32_t data_len;
-@@ -145,9 +135,8 @@ uint8_t nftnl_expr_get_u8(const struct nftnl_expr *expr, uint16_t type)
- 
- 	return *((uint8_t *)data);
- }
--EXPORT_SYMBOL(nftnl_expr_get_u8);
- 
--uint16_t nftnl_expr_get_u16(const struct nftnl_expr *expr, uint16_t type)
-+uint16_t __EXPORTED nftnl_expr_get_u16(const struct nftnl_expr *expr, uint16_t type)
- {
- 	const void *data;
- 	uint32_t data_len;
-@@ -161,9 +150,8 @@ uint16_t nftnl_expr_get_u16(const struct nftnl_expr *expr, uint16_t type)
- 
- 	return *((uint16_t *)data);
- }
--EXPORT_SYMBOL(nftnl_expr_get_u16);
- 
--uint32_t nftnl_expr_get_u32(const struct nftnl_expr *expr, uint16_t type)
-+uint32_t __EXPORTED nftnl_expr_get_u32(const struct nftnl_expr *expr, uint16_t type)
- {
- 	const void *data;
- 	uint32_t data_len;
-@@ -177,9 +165,8 @@ uint32_t nftnl_expr_get_u32(const struct nftnl_expr *expr, uint16_t type)
- 
- 	return *((uint32_t *)data);
- }
--EXPORT_SYMBOL(nftnl_expr_get_u32);
- 
--uint64_t nftnl_expr_get_u64(const struct nftnl_expr *expr, uint16_t type)
-+uint64_t __EXPORTED nftnl_expr_get_u64(const struct nftnl_expr *expr, uint16_t type)
- {
- 	const void *data;
- 	uint32_t data_len;
-@@ -193,17 +180,15 @@ uint64_t nftnl_expr_get_u64(const struct nftnl_expr *expr, uint16_t type)
- 
- 	return *((uint64_t *)data);
- }
--EXPORT_SYMBOL(nftnl_expr_get_u64);
- 
--const char *nftnl_expr_get_str(const struct nftnl_expr *expr, uint16_t type)
-+const char __EXPORTED *nftnl_expr_get_str(const struct nftnl_expr *expr, uint16_t type)
- {
- 	uint32_t data_len;
- 
- 	return (const char *)nftnl_expr_get(expr, type, &data_len);
- }
--EXPORT_SYMBOL(nftnl_expr_get_str);
- 
--bool nftnl_expr_cmp(const struct nftnl_expr *e1, const struct nftnl_expr *e2)
-+bool __EXPORTED nftnl_expr_cmp(const struct nftnl_expr *e1, const struct nftnl_expr *e2)
- {
- 	if (e1->flags != e2->flags ||
- 	    strcmp(e1->ops->name, e2->ops->name) != 0)
-@@ -211,7 +196,6 @@ bool nftnl_expr_cmp(const struct nftnl_expr *e1, const struct nftnl_expr *e2)
- 
- 	return e1->ops->cmp(e1, e2);
- }
--EXPORT_SYMBOL(nftnl_expr_cmp);
- 
- void nftnl_expr_build_payload(struct nlmsghdr *nlh, struct nftnl_expr *expr)
- {
-@@ -275,7 +259,7 @@ err1:
- 	return NULL;
- }
- 
--int nftnl_expr_snprintf(char *buf, size_t size, const struct nftnl_expr *expr,
-+int __EXPORTED nftnl_expr_snprintf(char *buf, size_t size, const struct nftnl_expr *expr,
- 			uint32_t type, uint32_t flags)
- {
- 	int ret;
-@@ -289,4 +273,3 @@ int nftnl_expr_snprintf(char *buf, size_t size, const struct nftnl_expr *expr,
- 
- 	return offset;
- }
--EXPORT_SYMBOL(nftnl_expr_snprintf);
-diff --git a/src/gen.c b/src/gen.c
-index 213562e..8b45caa 100644
---- a/src/gen.c
-+++ b/src/gen.c
-@@ -29,25 +29,22 @@ struct nftnl_gen {
- 	uint32_t flags;
- };
- 
--struct nftnl_gen *nftnl_gen_alloc(void)
-+struct nftnl_gen __EXPORTED *nftnl_gen_alloc(void)
- {
- 	return calloc(1, sizeof(struct nftnl_gen));
- }
--EXPORT_SYMBOL(nftnl_gen_alloc);
- 
--void nftnl_gen_free(const struct nftnl_gen *gen)
-+void __EXPORTED nftnl_gen_free(const struct nftnl_gen *gen)
- {
- 	xfree(gen);
- }
--EXPORT_SYMBOL(nftnl_gen_free);
- 
--bool nftnl_gen_is_set(const struct nftnl_gen *gen, uint16_t attr)
-+bool __EXPORTED nftnl_gen_is_set(const struct nftnl_gen *gen, uint16_t attr)
- {
- 	return gen->flags & (1 << attr);
- }
--EXPORT_SYMBOL(nftnl_gen_is_set);
- 
--void nftnl_gen_unset(struct nftnl_gen *gen, uint16_t attr)
-+void __EXPORTED nftnl_gen_unset(struct nftnl_gen *gen, uint16_t attr)
- {
- 	if (!(gen->flags & (1 << attr)))
- 		return;
-@@ -58,13 +55,12 @@ void nftnl_gen_unset(struct nftnl_gen *gen, uint16_t attr)
- 	}
- 	gen->flags &= ~(1 << attr);
- }
--EXPORT_SYMBOL(nftnl_gen_unset);
- 
- static uint32_t nftnl_gen_validate[NFTNL_GEN_MAX + 1] = {
- 	[NFTNL_GEN_ID]	= sizeof(uint32_t),
- };
- 
--int nftnl_gen_set_data(struct nftnl_gen *gen, uint16_t attr,
-+int __EXPORTED nftnl_gen_set_data(struct nftnl_gen *gen, uint16_t attr,
- 		       const void *data, uint32_t data_len)
- {
- 	nftnl_assert_attr_exists(attr, NFTNL_GEN_MAX);
-@@ -78,21 +74,18 @@ int nftnl_gen_set_data(struct nftnl_gen *gen, uint16_t attr,
- 	gen->flags |= (1 << attr);
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_gen_set_data);
- 
--int nftnl_gen_set(struct nftnl_gen *gen, uint16_t attr, const void *data)
-+int __EXPORTED nftnl_gen_set(struct nftnl_gen *gen, uint16_t attr, const void *data)
- {
- 	return nftnl_gen_set_data(gen, attr, data, nftnl_gen_validate[attr]);
- }
--EXPORT_SYMBOL(nftnl_gen_set);
- 
--void nftnl_gen_set_u32(struct nftnl_gen *gen, uint16_t attr, uint32_t val)
-+void __EXPORTED nftnl_gen_set_u32(struct nftnl_gen *gen, uint16_t attr, uint32_t val)
- {
- 	nftnl_gen_set_data(gen, attr, &val, sizeof(uint32_t));
- }
--EXPORT_SYMBOL(nftnl_gen_set_u32);
- 
--const void *nftnl_gen_get_data(const struct nftnl_gen *gen, uint16_t attr,
-+const void __EXPORTED *nftnl_gen_get_data(const struct nftnl_gen *gen, uint16_t attr,
- 			       uint32_t *data_len)
- {
- 	if (!(gen->flags & (1 << attr)))
-@@ -105,21 +98,18 @@ const void *nftnl_gen_get_data(const struct nftnl_gen *gen, uint16_t attr,
- 	}
- 	return NULL;
- }
--EXPORT_SYMBOL(nftnl_gen_get_data);
- 
--const void *nftnl_gen_get(const struct nftnl_gen *gen, uint16_t attr)
-+const void __EXPORTED *nftnl_gen_get(const struct nftnl_gen *gen, uint16_t attr)
- {
- 	uint32_t data_len;
- 	return nftnl_gen_get_data(gen, attr, &data_len);
- }
--EXPORT_SYMBOL(nftnl_gen_get);
- 
--uint32_t nftnl_gen_get_u32(const struct nftnl_gen *gen, uint16_t attr)
-+uint32_t __EXPORTED nftnl_gen_get_u32(const struct nftnl_gen *gen, uint16_t attr)
- {
- 	const void *ret = nftnl_gen_get(gen, attr);
- 	return ret == NULL ? 0 : *((uint32_t *)ret);
- }
--EXPORT_SYMBOL(nftnl_gen_get_u32);
- 
- static int nftnl_gen_parse_attr_cb(const struct nlattr *attr, void *data)
- {
-@@ -140,7 +130,7 @@ static int nftnl_gen_parse_attr_cb(const struct nlattr *attr, void *data)
- 	return MNL_CB_OK;
- }
- 
--int nftnl_gen_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_gen *gen)
-+int __EXPORTED nftnl_gen_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_gen *gen)
- {
- 	struct nlattr *tb[NFTA_GEN_MAX + 1] = {};
- 	struct nfgenmsg *nfg = mnl_nlmsg_get_payload(nlh);
-@@ -154,7 +144,6 @@ int nftnl_gen_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_gen *gen)
- 	}
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_gen_nlmsg_parse);
- 
- static int nftnl_gen_snprintf_default(char *buf, size_t size,
- 				      const struct nftnl_gen *gen)
-@@ -186,13 +175,12 @@ static int nftnl_gen_cmd_snprintf(char *buf, size_t size,
- 	return offset;
- }
- 
--int nftnl_gen_snprintf(char *buf, size_t size, const struct nftnl_gen *gen,
-+int __EXPORTED nftnl_gen_snprintf(char *buf, size_t size, const struct nftnl_gen *gen,
- 		       uint32_t type, uint32_t flags)
- {;
- 	return nftnl_gen_cmd_snprintf(buf, size, gen, nftnl_flag2cmd(flags), type,
- 				    flags);
- }
--EXPORT_SYMBOL(nftnl_gen_snprintf);
- 
- static int nftnl_gen_do_snprintf(char *buf, size_t size, const void *gen,
- 				 uint32_t cmd, uint32_t type, uint32_t flags)
-@@ -200,10 +188,9 @@ static int nftnl_gen_do_snprintf(char *buf, size_t size, const void *gen,
- 	return nftnl_gen_snprintf(buf, size, gen, type, flags);
- }
- 
--int nftnl_gen_fprintf(FILE *fp, const struct nftnl_gen *gen, uint32_t type,
-+int __EXPORTED nftnl_gen_fprintf(FILE *fp, const struct nftnl_gen *gen, uint32_t type,
- 		      uint32_t flags)
- {
- 	return nftnl_fprintf(fp, gen, NFTNL_CMD_UNSPEC, type, flags,
- 			   nftnl_gen_do_snprintf);
- }
--EXPORT_SYMBOL(nftnl_gen_fprintf);
-diff --git a/src/object.c b/src/object.c
-index e1a5ac4..d409c6d 100644
---- a/src/object.c
-+++ b/src/object.c
-@@ -39,13 +39,12 @@ static struct obj_ops *nftnl_obj_ops_lookup(uint32_t type)
- 	return obj_ops[type];
- }
- 
--struct nftnl_obj *nftnl_obj_alloc(void)
-+struct nftnl_obj __EXPORTED *nftnl_obj_alloc(void)
- {
- 	return calloc(1, sizeof(struct nftnl_obj));
- }
--EXPORT_SYMBOL(nftnl_obj_alloc);
- 
--void nftnl_obj_free(const struct nftnl_obj *obj)
-+void __EXPORTED nftnl_obj_free(const struct nftnl_obj *obj)
- {
- 	if (obj->flags & (1 << NFTNL_OBJ_TABLE))
- 		xfree(obj->table);
-@@ -54,20 +53,18 @@ void nftnl_obj_free(const struct nftnl_obj *obj)
- 
- 	xfree(obj);
- }
--EXPORT_SYMBOL(nftnl_obj_free);
- 
--bool nftnl_obj_is_set(const struct nftnl_obj *obj, uint16_t attr)
-+bool __EXPORTED nftnl_obj_is_set(const struct nftnl_obj *obj, uint16_t attr)
- {
- 	return obj->flags & (1 << attr);
- }
--EXPORT_SYMBOL(nftnl_obj_is_set);
- 
- static uint32_t nftnl_obj_validate[NFTNL_OBJ_MAX + 1] = {
- 	[NFTNL_OBJ_FAMILY]	= sizeof(uint32_t),
- 	[NFTNL_OBJ_USE]		= sizeof(uint32_t),
- };
- 
--void nftnl_obj_set_data(struct nftnl_obj *obj, uint16_t attr,
-+void __EXPORTED nftnl_obj_set_data(struct nftnl_obj *obj, uint16_t attr,
- 			const void *data, uint32_t data_len)
- {
- 	if (attr < NFTNL_OBJ_MAX)
-@@ -100,45 +97,38 @@ void nftnl_obj_set_data(struct nftnl_obj *obj, uint16_t attr,
- 	}
- 	obj->flags |= (1 << attr);
- }
--EXPORT_SYMBOL(nftnl_obj_set_data);
- 
--void nftnl_obj_set(struct nftnl_obj *obj, uint16_t attr, const void *data)
-+void __EXPORTED nftnl_obj_set(struct nftnl_obj *obj, uint16_t attr, const void *data)
- {
- 	nftnl_obj_set_data(obj, attr, data, nftnl_obj_validate[attr]);
- }
--EXPORT_SYMBOL(nftnl_obj_set);
- 
--void nftnl_obj_set_u8(struct nftnl_obj *obj, uint16_t attr, uint8_t val)
-+void __EXPORTED nftnl_obj_set_u8(struct nftnl_obj *obj, uint16_t attr, uint8_t val)
- {
- 	nftnl_obj_set_data(obj, attr, &val, sizeof(uint8_t));
- }
--EXPORT_SYMBOL(nftnl_obj_set_u8);
- 
--void nftnl_obj_set_u16(struct nftnl_obj *obj, uint16_t attr, uint16_t val)
-+void __EXPORTED nftnl_obj_set_u16(struct nftnl_obj *obj, uint16_t attr, uint16_t val)
- {
- 	nftnl_obj_set_data(obj, attr, &val, sizeof(uint16_t));
- }
--EXPORT_SYMBOL(nftnl_obj_set_u16);
- 
--void nftnl_obj_set_u32(struct nftnl_obj *obj, uint16_t attr, uint32_t val)
-+void __EXPORTED nftnl_obj_set_u32(struct nftnl_obj *obj, uint16_t attr, uint32_t val)
- {
- 	nftnl_obj_set_data(obj, attr, &val, sizeof(uint32_t));
- }
--EXPORT_SYMBOL(nftnl_obj_set_u32);
- 
--void nftnl_obj_set_u64(struct nftnl_obj *obj, uint16_t attr, uint64_t val)
-+void __EXPORTED nftnl_obj_set_u64(struct nftnl_obj *obj, uint16_t attr, uint64_t val)
- {
- 	nftnl_obj_set_data(obj, attr, &val, sizeof(uint64_t));
- }
--EXPORT_SYMBOL(nftnl_obj_set_u64);
- 
--void nftnl_obj_set_str(struct nftnl_obj *obj, uint16_t attr, const char *str)
-+void __EXPORTED nftnl_obj_set_str(struct nftnl_obj *obj, uint16_t attr, const char *str)
- {
- 	nftnl_obj_set_data(obj, attr, str, 0);
- }
--EXPORT_SYMBOL(nftnl_obj_set_str);
- 
--const void *nftnl_obj_get_data(struct nftnl_obj *obj, uint16_t attr,
-+const void __EXPORTED *nftnl_obj_get_data(struct nftnl_obj *obj, uint16_t attr,
- 			       uint32_t *data_len)
- {
- 	if (!(obj->flags & (1 << attr)))
-@@ -168,50 +158,43 @@ const void *nftnl_obj_get_data(struct nftnl_obj *obj, uint16_t attr,
- 	}
- 	return NULL;
- }
--EXPORT_SYMBOL(nftnl_obj_get_data);
- 
--const void *nftnl_obj_get(struct nftnl_obj *obj, uint16_t attr)
-+const void __EXPORTED *nftnl_obj_get(struct nftnl_obj *obj, uint16_t attr)
- {
- 	uint32_t data_len;
- 	return nftnl_obj_get_data(obj, attr, &data_len);
- }
--EXPORT_SYMBOL(nftnl_obj_get);
- 
--uint8_t nftnl_obj_get_u8(struct nftnl_obj *obj, uint16_t attr)
-+uint8_t __EXPORTED nftnl_obj_get_u8(struct nftnl_obj *obj, uint16_t attr)
- {
- 	const void *ret = nftnl_obj_get(obj, attr);
- 	return ret == NULL ? 0 : *((uint8_t *)ret);
- }
--EXPORT_SYMBOL(nftnl_obj_get_u8);
- 
--uint16_t nftnl_obj_get_u16(struct nftnl_obj *obj, uint16_t attr)
-+uint16_t __EXPORTED nftnl_obj_get_u16(struct nftnl_obj *obj, uint16_t attr)
- {
- 	const void *ret = nftnl_obj_get(obj, attr);
- 	return ret == NULL ? 0 : *((uint16_t *)ret);
- }
--EXPORT_SYMBOL(nftnl_obj_get_u16);
- 
--uint32_t nftnl_obj_get_u32(struct nftnl_obj *obj, uint16_t attr)
-+uint32_t __EXPORTED nftnl_obj_get_u32(struct nftnl_obj *obj, uint16_t attr)
- {
- 	const void *ret = nftnl_obj_get(obj, attr);
- 	return ret == NULL ? 0 : *((uint32_t *)ret);
- }
--EXPORT_SYMBOL(nftnl_obj_get_u32);
- 
--uint64_t nftnl_obj_get_u64(struct nftnl_obj *obj, uint16_t attr)
-+uint64_t __EXPORTED nftnl_obj_get_u64(struct nftnl_obj *obj, uint16_t attr)
- {
- 	const void *ret = nftnl_obj_get(obj, attr);
- 	return ret == NULL ? 0 : *((uint64_t *)ret);
- }
--EXPORT_SYMBOL(nftnl_obj_get_u64);
- 
--const char *nftnl_obj_get_str(struct nftnl_obj *obj, uint16_t attr)
-+const char __EXPORTED *nftnl_obj_get_str(struct nftnl_obj *obj, uint16_t attr)
- {
- 	return nftnl_obj_get(obj, attr);
- }
--EXPORT_SYMBOL(nftnl_obj_get_str);
- 
--void nftnl_obj_nlmsg_build_payload(struct nlmsghdr *nlh,
-+void __EXPORTED nftnl_obj_nlmsg_build_payload(struct nlmsghdr *nlh,
- 				   const struct nftnl_obj *obj)
- {
- 	if (obj->flags & (1 << NFTNL_OBJ_TABLE))
-@@ -228,7 +211,6 @@ void nftnl_obj_nlmsg_build_payload(struct nlmsghdr *nlh,
- 		mnl_attr_nest_end(nlh, nest);
- 	}
- }
--EXPORT_SYMBOL(nftnl_obj_nlmsg_build_payload);
- 
- static int nftnl_obj_parse_attr_cb(const struct nlattr *attr, void *data)
- {
-@@ -258,7 +240,7 @@ static int nftnl_obj_parse_attr_cb(const struct nlattr *attr, void *data)
- 	return MNL_CB_OK;
- }
- 
--int nftnl_obj_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_obj *obj)
-+int __EXPORTED nftnl_obj_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_obj *obj)
- {
- 	struct nfgenmsg *nfg = mnl_nlmsg_get_payload(nlh);
- 	struct nlattr *tb[NFTA_OBJ_MAX + 1] = {};
-@@ -299,7 +281,6 @@ int nftnl_obj_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_obj *obj)
- 
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_obj_nlmsg_parse);
- 
- #ifdef JSON_PARSING
- static int nftnl_jansson_parse_obj(struct nftnl_obj *t, json_t *tree,
-@@ -377,19 +358,17 @@ static int nftnl_obj_do_parse(struct nftnl_obj *obj, enum nftnl_parse_type type,
- 	return ret;
- }
- 
--int nftnl_obj_parse(struct nftnl_obj *obj, enum nftnl_parse_type type,
-+int __EXPORTED nftnl_obj_parse(struct nftnl_obj *obj, enum nftnl_parse_type type,
- 		      const char *data, struct nftnl_parse_err *err)
- {
- 	return nftnl_obj_do_parse(obj, type, data, err, NFTNL_PARSE_BUFFER);
- }
--EXPORT_SYMBOL(nftnl_obj_parse);
- 
--int nftnl_obj_parse_file(struct nftnl_obj *obj, enum nftnl_parse_type type,
-+int __EXPORTED nftnl_obj_parse_file(struct nftnl_obj *obj, enum nftnl_parse_type type,
- 			   FILE *fp, struct nftnl_parse_err *err)
- {
- 	return nftnl_obj_do_parse(obj, type, fp, err, NFTNL_PARSE_FILE);
- }
--EXPORT_SYMBOL(nftnl_obj_parse_file);
- 
- static int nftnl_obj_export(char *buf, size_t size,
- 			    const struct nftnl_obj *obj,
-@@ -469,13 +448,12 @@ static int nftnl_obj_cmd_snprintf(char *buf, size_t size,
- 	return offset;
- }
- 
--int nftnl_obj_snprintf(char *buf, size_t size, const struct nftnl_obj *obj,
-+int __EXPORTED nftnl_obj_snprintf(char *buf, size_t size, const struct nftnl_obj *obj,
- 		       uint32_t type, uint32_t flags)
- {
- 	return nftnl_obj_cmd_snprintf(buf, size, obj, nftnl_flag2cmd(flags),
- 				      type, flags);
- }
--EXPORT_SYMBOL(nftnl_obj_snprintf);
- 
- static int nftnl_obj_do_snprintf(char *buf, size_t size, const void *obj,
- 				 uint32_t cmd, uint32_t type, uint32_t flags)
-@@ -483,19 +461,18 @@ static int nftnl_obj_do_snprintf(char *buf, size_t size, const void *obj,
- 	return nftnl_obj_snprintf(buf, size, obj, type, flags);
- }
- 
--int nftnl_obj_fprintf(FILE *fp, const struct nftnl_obj *obj, uint32_t type,
-+int __EXPORTED nftnl_obj_fprintf(FILE *fp, const struct nftnl_obj *obj, uint32_t type,
- 		      uint32_t flags)
- {
- 	return nftnl_fprintf(fp, obj, NFTNL_CMD_UNSPEC, type, flags,
- 			     nftnl_obj_do_snprintf);
- }
--EXPORT_SYMBOL(nftnl_obj_fprintf);
- 
- struct nftnl_obj_list {
- 	struct list_head list;
- };
- 
--struct nftnl_obj_list *nftnl_obj_list_alloc(void)
-+struct nftnl_obj_list __EXPORTED *nftnl_obj_list_alloc(void)
- {
- 	struct nftnl_obj_list *list;
- 
-@@ -507,9 +484,8 @@ struct nftnl_obj_list *nftnl_obj_list_alloc(void)
- 
- 	return list;
- }
--EXPORT_SYMBOL(nftnl_obj_list_alloc);
- 
--void nftnl_obj_list_free(struct nftnl_obj_list *list)
-+void __EXPORTED nftnl_obj_list_free(struct nftnl_obj_list *list)
- {
- 	struct nftnl_obj *r, *tmp;
- 
-@@ -519,34 +495,29 @@ void nftnl_obj_list_free(struct nftnl_obj_list *list)
- 	}
- 	xfree(list);
- }
--EXPORT_SYMBOL(nftnl_obj_list_free);
- 
--int nftnl_obj_list_is_empty(struct nftnl_obj_list *list)
-+int __EXPORTED nftnl_obj_list_is_empty(struct nftnl_obj_list *list)
- {
- 	return list_empty(&list->list);
- }
--EXPORT_SYMBOL(nftnl_obj_list_is_empty);
- 
--void nftnl_obj_list_add(struct nftnl_obj *r, struct nftnl_obj_list *list)
-+void __EXPORTED nftnl_obj_list_add(struct nftnl_obj *r, struct nftnl_obj_list *list)
- {
- 	list_add(&r->head, &list->list);
- }
--EXPORT_SYMBOL(nftnl_obj_list_add);
- 
--void nftnl_obj_list_add_tail(struct nftnl_obj *r,
-+void __EXPORTED nftnl_obj_list_add_tail(struct nftnl_obj *r,
- 			       struct nftnl_obj_list *list)
- {
- 	list_add_tail(&r->head, &list->list);
- }
--EXPORT_SYMBOL(nftnl_obj_list_add_tail);
- 
--void nftnl_obj_list_del(struct nftnl_obj *t)
-+void __EXPORTED nftnl_obj_list_del(struct nftnl_obj *t)
- {
- 	list_del(&t->head);
- }
--EXPORT_SYMBOL(nftnl_obj_list_del);
- 
--int nftnl_obj_list_foreach(struct nftnl_obj_list *table_list,
-+int __EXPORTED nftnl_obj_list_foreach(struct nftnl_obj_list *table_list,
- 			     int (*cb)(struct nftnl_obj *t, void *data),
- 			     void *data)
- {
-@@ -560,14 +531,13 @@ int nftnl_obj_list_foreach(struct nftnl_obj_list *table_list,
- 	}
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_obj_list_foreach);
- 
- struct nftnl_obj_list_iter {
- 	struct nftnl_obj_list	*list;
- 	struct nftnl_obj	*cur;
- };
- 
--struct nftnl_obj_list_iter *
-+struct nftnl_obj_list_iter __EXPORTED *
- nftnl_obj_list_iter_create(struct nftnl_obj_list *l)
- {
- 	struct nftnl_obj_list_iter *iter;
-@@ -584,9 +554,8 @@ nftnl_obj_list_iter_create(struct nftnl_obj_list *l)
- 
- 	return iter;
- }
--EXPORT_SYMBOL(nftnl_obj_list_iter_create);
- 
--struct nftnl_obj *nftnl_obj_list_iter_next(struct nftnl_obj_list_iter *iter)
-+struct nftnl_obj __EXPORTED *nftnl_obj_list_iter_next(struct nftnl_obj_list_iter *iter)
- {
- 	struct nftnl_obj *r = iter->cur;
- 
-@@ -600,10 +569,8 @@ struct nftnl_obj *nftnl_obj_list_iter_next(struct nftnl_obj_list_iter *iter)
- 
- 	return r;
- }
--EXPORT_SYMBOL(nftnl_obj_list_iter_next);
- 
--void nftnl_obj_list_iter_destroy(struct nftnl_obj_list_iter *iter)
-+void __EXPORTED nftnl_obj_list_iter_destroy(struct nftnl_obj_list_iter *iter)
- {
- 	xfree(iter);
- }
--EXPORT_SYMBOL(nftnl_obj_list_iter_destroy);
-diff --git a/src/rule.c b/src/rule.c
-index 6c22141..ad8609f 100644
---- a/src/rule.c
-+++ b/src/rule.c
-@@ -52,7 +52,7 @@ struct nftnl_rule {
- 	struct list_head expr_list;
- };
- 
--struct nftnl_rule *nftnl_rule_alloc(void)
-+struct nftnl_rule __EXPORTED *nftnl_rule_alloc(void)
- {
- 	struct nftnl_rule *r;
- 
-@@ -64,9 +64,8 @@ struct nftnl_rule *nftnl_rule_alloc(void)
- 
- 	return r;
- }
--EXPORT_SYMBOL(nftnl_rule_alloc);
- 
--void nftnl_rule_free(const struct nftnl_rule *r)
-+void __EXPORTED nftnl_rule_free(const struct nftnl_rule *r)
- {
- 	struct nftnl_expr *e, *tmp;
- 
-@@ -82,15 +81,13 @@ void nftnl_rule_free(const struct nftnl_rule *r)
- 
- 	xfree(r);
- }
--EXPORT_SYMBOL(nftnl_rule_free);
- 
--bool nftnl_rule_is_set(const struct nftnl_rule *r, uint16_t attr)
-+bool __EXPORTED nftnl_rule_is_set(const struct nftnl_rule *r, uint16_t attr)
- {
- 	return r->flags & (1 << attr);
- }
--EXPORT_SYMBOL(nftnl_rule_is_set);
- 
--void nftnl_rule_unset(struct nftnl_rule *r, uint16_t attr)
-+void __EXPORTED nftnl_rule_unset(struct nftnl_rule *r, uint16_t attr)
- {
- 	if (!(r->flags & (1 << attr)))
- 		return;
-@@ -116,7 +113,6 @@ void nftnl_rule_unset(struct nftnl_rule *r, uint16_t attr)
- 
- 	r->flags &= ~(1 << attr);
- }
--EXPORT_SYMBOL(nftnl_rule_unset);
- 
- static uint32_t nftnl_rule_validate[NFTNL_RULE_MAX + 1] = {
- 	[NFTNL_RULE_HANDLE]		= sizeof(uint64_t),
-@@ -127,7 +123,7 @@ static uint32_t nftnl_rule_validate[NFTNL_RULE_MAX + 1] = {
- 	[NFTNL_RULE_ID]			= sizeof(uint32_t),
- };
- 
--int nftnl_rule_set_data(struct nftnl_rule *r, uint16_t attr,
-+int __EXPORTED nftnl_rule_set_data(struct nftnl_rule *r, uint16_t attr,
- 			const void *data, uint32_t data_len)
- {
- 	nftnl_assert_attr_exists(attr, NFTNL_RULE_MAX);
-@@ -183,33 +179,28 @@ int nftnl_rule_set_data(struct nftnl_rule *r, uint16_t attr,
- 	r->flags |= (1 << attr);
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_rule_set_data);
- 
--int nftnl_rule_set(struct nftnl_rule *r, uint16_t attr, const void *data)
-+int __EXPORTED nftnl_rule_set(struct nftnl_rule *r, uint16_t attr, const void *data)
- {
- 	return nftnl_rule_set_data(r, attr, data, nftnl_rule_validate[attr]);
- }
--EXPORT_SYMBOL(nftnl_rule_set);
- 
--void nftnl_rule_set_u32(struct nftnl_rule *r, uint16_t attr, uint32_t val)
-+void __EXPORTED nftnl_rule_set_u32(struct nftnl_rule *r, uint16_t attr, uint32_t val)
- {
- 	nftnl_rule_set_data(r, attr, &val, sizeof(uint32_t));
- }
--EXPORT_SYMBOL(nftnl_rule_set_u32);
- 
--void nftnl_rule_set_u64(struct nftnl_rule *r, uint16_t attr, uint64_t val)
-+void __EXPORTED nftnl_rule_set_u64(struct nftnl_rule *r, uint16_t attr, uint64_t val)
- {
- 	nftnl_rule_set_data(r, attr, &val, sizeof(uint64_t));
- }
--EXPORT_SYMBOL(nftnl_rule_set_u64);
- 
--int nftnl_rule_set_str(struct nftnl_rule *r, uint16_t attr, const char *str)
-+int __EXPORTED nftnl_rule_set_str(struct nftnl_rule *r, uint16_t attr, const char *str)
- {
- 	return nftnl_rule_set_data(r, attr, str, strlen(str) + 1);
- }
--EXPORT_SYMBOL(nftnl_rule_set_str);
- 
--const void *nftnl_rule_get_data(const struct nftnl_rule *r, uint16_t attr,
-+const void __EXPORTED *nftnl_rule_get_data(const struct nftnl_rule *r, uint16_t attr,
- 				   uint32_t *data_len)
- {
- 	if (!(r->flags & (1 << attr)))
-@@ -246,22 +237,19 @@ const void *nftnl_rule_get_data(const struct nftnl_rule *r, uint16_t attr,
- 	}
- 	return NULL;
- }
--EXPORT_SYMBOL(nftnl_rule_get_data);
- 
--const void *nftnl_rule_get(const struct nftnl_rule *r, uint16_t attr)
-+const void __EXPORTED *nftnl_rule_get(const struct nftnl_rule *r, uint16_t attr)
- {
- 	uint32_t data_len;
- 	return nftnl_rule_get_data(r, attr, &data_len);
- }
--EXPORT_SYMBOL(nftnl_rule_get);
- 
--const char *nftnl_rule_get_str(const struct nftnl_rule *r, uint16_t attr)
-+const char __EXPORTED *nftnl_rule_get_str(const struct nftnl_rule *r, uint16_t attr)
- {
- 	return nftnl_rule_get(r, attr);
- }
--EXPORT_SYMBOL(nftnl_rule_get_str);
- 
--uint32_t nftnl_rule_get_u32(const struct nftnl_rule *r, uint16_t attr)
-+uint32_t __EXPORTED nftnl_rule_get_u32(const struct nftnl_rule *r, uint16_t attr)
- {
- 	uint32_t data_len;
- 	const uint32_t *val = nftnl_rule_get_data(r, attr, &data_len);
-@@ -270,9 +258,8 @@ uint32_t nftnl_rule_get_u32(const struct nftnl_rule *r, uint16_t attr)
- 
- 	return val ? *val : 0;
- }
--EXPORT_SYMBOL(nftnl_rule_get_u32);
- 
--uint64_t nftnl_rule_get_u64(const struct nftnl_rule *r, uint16_t attr)
-+uint64_t __EXPORTED nftnl_rule_get_u64(const struct nftnl_rule *r, uint16_t attr)
- {
- 	uint32_t data_len;
- 	const uint64_t *val = nftnl_rule_get_data(r, attr, &data_len);
-@@ -281,9 +268,8 @@ uint64_t nftnl_rule_get_u64(const struct nftnl_rule *r, uint16_t attr)
- 
- 	return val ? *val : 0;
- }
--EXPORT_SYMBOL(nftnl_rule_get_u64);
- 
--uint8_t nftnl_rule_get_u8(const struct nftnl_rule *r, uint16_t attr)
-+uint8_t __EXPORTED nftnl_rule_get_u8(const struct nftnl_rule *r, uint16_t attr)
- {
- 	uint32_t data_len;
- 	const uint8_t *val = nftnl_rule_get_data(r, attr, &data_len);
-@@ -292,9 +278,8 @@ uint8_t nftnl_rule_get_u8(const struct nftnl_rule *r, uint16_t attr)
- 
- 	return val ? *val : 0;
- }
--EXPORT_SYMBOL(nftnl_rule_get_u8);
- 
--void nftnl_rule_nlmsg_build_payload(struct nlmsghdr *nlh, struct nftnl_rule *r)
-+void __EXPORTED nftnl_rule_nlmsg_build_payload(struct nlmsghdr *nlh, struct nftnl_rule *r)
- {
- 	struct nftnl_expr *expr;
- 	struct nlattr *nest, *nest2;
-@@ -335,13 +320,11 @@ void nftnl_rule_nlmsg_build_payload(struct nlmsghdr *nlh, struct nftnl_rule *r)
- 	if (r->flags & (1 << NFTNL_RULE_ID))
- 		mnl_attr_put_u32(nlh, NFTA_RULE_ID, htonl(r->id));
- }
--EXPORT_SYMBOL(nftnl_rule_nlmsg_build_payload);
- 
--void nftnl_rule_add_expr(struct nftnl_rule *r, struct nftnl_expr *expr)
-+void __EXPORTED nftnl_rule_add_expr(struct nftnl_rule *r, struct nftnl_expr *expr)
- {
- 	list_add_tail(&expr->head, &r->expr_list);
- }
--EXPORT_SYMBOL(nftnl_rule_add_expr);
- 
- static int nftnl_rule_parse_attr_cb(const struct nlattr *attr, void *data)
- {
-@@ -441,7 +424,7 @@ static int nftnl_rule_parse_compat(struct nlattr *nest, struct nftnl_rule *r)
- 	return 0;
- }
- 
--int nftnl_rule_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_rule *r)
-+int __EXPORTED nftnl_rule_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_rule *r)
- {
- 	struct nlattr *tb[NFTA_RULE_MAX+1] = {};
- 	struct nfgenmsg *nfg = mnl_nlmsg_get_payload(nlh);
-@@ -510,7 +493,6 @@ int nftnl_rule_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_rule *r)
- 
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_rule_nlmsg_parse);
- 
- #ifdef JSON_PARSING
- int nftnl_jansson_parse_rule(struct nftnl_rule *r, json_t *tree,
-@@ -658,19 +640,17 @@ static int nftnl_rule_do_parse(struct nftnl_rule *r, enum nftnl_parse_type type,
- 
- 	return ret;
- }
--int nftnl_rule_parse(struct nftnl_rule *r, enum nftnl_parse_type type,
-+int __EXPORTED nftnl_rule_parse(struct nftnl_rule *r, enum nftnl_parse_type type,
- 		   const char *data, struct nftnl_parse_err *err)
- {
- 	return nftnl_rule_do_parse(r, type, data, err, NFTNL_PARSE_BUFFER);
- }
--EXPORT_SYMBOL(nftnl_rule_parse);
- 
--int nftnl_rule_parse_file(struct nftnl_rule *r, enum nftnl_parse_type type,
-+int __EXPORTED nftnl_rule_parse_file(struct nftnl_rule *r, enum nftnl_parse_type type,
- 			FILE *fp, struct nftnl_parse_err *err)
- {
- 	return nftnl_rule_do_parse(r, type, fp, err, NFTNL_PARSE_FILE);
- }
--EXPORT_SYMBOL(nftnl_rule_parse_file);
- 
- static int nftnl_rule_export(char *buf, size_t size,
- 			     const struct nftnl_rule *r,
-@@ -819,13 +799,12 @@ static int nftnl_rule_cmd_snprintf(char *buf, size_t size,
- 	return offset;
- }
- 
--int nftnl_rule_snprintf(char *buf, size_t size, const struct nftnl_rule *r,
-+int __EXPORTED nftnl_rule_snprintf(char *buf, size_t size, const struct nftnl_rule *r,
- 			uint32_t type, uint32_t flags)
- {
- 	return nftnl_rule_cmd_snprintf(buf, size, r, nftnl_flag2cmd(flags), type,
- 				     flags);
- }
--EXPORT_SYMBOL(nftnl_rule_snprintf);
- 
- static int nftnl_rule_do_snprintf(char *buf, size_t size, const void *r,
- 				  uint32_t cmd, uint32_t type, uint32_t flags)
-@@ -833,15 +812,14 @@ static int nftnl_rule_do_snprintf(char *buf, size_t size, const void *r,
- 	return nftnl_rule_snprintf(buf, size, r, type, flags);
- }
- 
--int nftnl_rule_fprintf(FILE *fp, const struct nftnl_rule *r, uint32_t type,
-+int __EXPORTED nftnl_rule_fprintf(FILE *fp, const struct nftnl_rule *r, uint32_t type,
- 		       uint32_t flags)
- {
- 	return nftnl_fprintf(fp, r, NFTNL_CMD_UNSPEC, type, flags,
- 			   nftnl_rule_do_snprintf);
- }
--EXPORT_SYMBOL(nftnl_rule_fprintf);
- 
--int nftnl_expr_foreach(struct nftnl_rule *r,
-+int __EXPORTED nftnl_expr_foreach(struct nftnl_rule *r,
-                           int (*cb)(struct nftnl_expr *e, void *data),
-                           void *data)
- {
-@@ -855,7 +833,6 @@ int nftnl_expr_foreach(struct nftnl_rule *r,
-        }
-        return 0;
- }
--EXPORT_SYMBOL(nftnl_expr_foreach);
- 
- struct nftnl_expr_iter {
- 	const struct nftnl_rule	*r;
-@@ -873,7 +850,7 @@ static void nftnl_expr_iter_init(const struct nftnl_rule *r,
- 				       head);
- }
- 
--struct nftnl_expr_iter *nftnl_expr_iter_create(const struct nftnl_rule *r)
-+struct nftnl_expr_iter __EXPORTED *nftnl_expr_iter_create(const struct nftnl_rule *r)
- {
- 	struct nftnl_expr_iter *iter;
- 
-@@ -885,9 +862,8 @@ struct nftnl_expr_iter *nftnl_expr_iter_create(const struct nftnl_rule *r)
- 
- 	return iter;
- }
--EXPORT_SYMBOL(nftnl_expr_iter_create);
- 
--struct nftnl_expr *nftnl_expr_iter_next(struct nftnl_expr_iter *iter)
-+struct nftnl_expr __EXPORTED *nftnl_expr_iter_next(struct nftnl_expr_iter *iter)
- {
- 	struct nftnl_expr *expr = iter->cur;
- 
-@@ -901,15 +877,13 @@ struct nftnl_expr *nftnl_expr_iter_next(struct nftnl_expr_iter *iter)
- 
- 	return expr;
- }
--EXPORT_SYMBOL(nftnl_expr_iter_next);
- 
--void nftnl_expr_iter_destroy(struct nftnl_expr_iter *iter)
-+void __EXPORTED nftnl_expr_iter_destroy(struct nftnl_expr_iter *iter)
- {
- 	xfree(iter);
- }
--EXPORT_SYMBOL(nftnl_expr_iter_destroy);
- 
--bool nftnl_rule_cmp(const struct nftnl_rule *r1, const struct nftnl_rule *r2)
-+bool __EXPORTED nftnl_rule_cmp(const struct nftnl_rule *r1, const struct nftnl_rule *r2)
- {
- 	struct nftnl_expr_iter it1, it2;
- 	struct nftnl_expr *e1, *e2;
-@@ -938,13 +912,12 @@ bool nftnl_rule_cmp(const struct nftnl_rule *r1, const struct nftnl_rule *r2)
- 
- 	return eq;
- }
--EXPORT_SYMBOL(nftnl_rule_cmp);
- 
- struct nftnl_rule_list {
- 	struct list_head list;
- };
- 
--struct nftnl_rule_list *nftnl_rule_list_alloc(void)
-+struct nftnl_rule_list __EXPORTED *nftnl_rule_list_alloc(void)
- {
- 	struct nftnl_rule_list *list;
- 
-@@ -956,9 +929,8 @@ struct nftnl_rule_list *nftnl_rule_list_alloc(void)
- 
- 	return list;
- }
--EXPORT_SYMBOL(nftnl_rule_list_alloc);
- 
--void nftnl_rule_list_free(struct nftnl_rule_list *list)
-+void __EXPORTED nftnl_rule_list_free(struct nftnl_rule_list *list)
- {
- 	struct nftnl_rule *r, *tmp;
- 
-@@ -968,33 +940,28 @@ void nftnl_rule_list_free(struct nftnl_rule_list *list)
- 	}
- 	xfree(list);
- }
--EXPORT_SYMBOL(nftnl_rule_list_free);
- 
--int nftnl_rule_list_is_empty(const struct nftnl_rule_list *list)
-+int __EXPORTED nftnl_rule_list_is_empty(const struct nftnl_rule_list *list)
- {
- 	return list_empty(&list->list);
- }
--EXPORT_SYMBOL(nftnl_rule_list_is_empty);
- 
--void nftnl_rule_list_add(struct nftnl_rule *r, struct nftnl_rule_list *list)
-+void __EXPORTED nftnl_rule_list_add(struct nftnl_rule *r, struct nftnl_rule_list *list)
- {
- 	list_add(&r->head, &list->list);
- }
--EXPORT_SYMBOL(nftnl_rule_list_add);
- 
--void nftnl_rule_list_add_tail(struct nftnl_rule *r, struct nftnl_rule_list *list)
-+void __EXPORTED nftnl_rule_list_add_tail(struct nftnl_rule *r, struct nftnl_rule_list *list)
- {
- 	list_add_tail(&r->head, &list->list);
- }
--EXPORT_SYMBOL(nftnl_rule_list_add_tail);
- 
--void nftnl_rule_list_del(struct nftnl_rule *r)
-+void __EXPORTED nftnl_rule_list_del(struct nftnl_rule *r)
- {
- 	list_del(&r->head);
- }
--EXPORT_SYMBOL(nftnl_rule_list_del);
- 
--int nftnl_rule_list_foreach(struct nftnl_rule_list *rule_list,
-+int __EXPORTED nftnl_rule_list_foreach(struct nftnl_rule_list *rule_list,
- 			  int (*cb)(struct nftnl_rule *r, void *data),
- 			  void *data)
- {
-@@ -1008,14 +975,13 @@ int nftnl_rule_list_foreach(struct nftnl_rule_list *rule_list,
- 	}
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_rule_list_foreach);
- 
- struct nftnl_rule_list_iter {
- 	const struct nftnl_rule_list	*list;
- 	struct nftnl_rule		*cur;
- };
- 
--struct nftnl_rule_list_iter *
-+struct nftnl_rule_list_iter __EXPORTED *
- nftnl_rule_list_iter_create(const struct nftnl_rule_list *l)
- {
- 	struct nftnl_rule_list_iter *iter;
-@@ -1032,15 +998,13 @@ nftnl_rule_list_iter_create(const struct nftnl_rule_list *l)
- 
- 	return iter;
- }
--EXPORT_SYMBOL(nftnl_rule_list_iter_create);
- 
--struct nftnl_rule *nftnl_rule_list_iter_cur(struct nftnl_rule_list_iter *iter)
-+struct nftnl_rule __EXPORTED *nftnl_rule_list_iter_cur(struct nftnl_rule_list_iter *iter)
- {
- 	return iter->cur;
- }
--EXPORT_SYMBOL(nftnl_rule_list_iter_cur);
- 
--struct nftnl_rule *nftnl_rule_list_iter_next(struct nftnl_rule_list_iter *iter)
-+struct nftnl_rule __EXPORTED *nftnl_rule_list_iter_next(struct nftnl_rule_list_iter *iter)
- {
- 	struct nftnl_rule *r = iter->cur;
- 
-@@ -1054,10 +1018,8 @@ struct nftnl_rule *nftnl_rule_list_iter_next(struct nftnl_rule_list_iter *iter)
- 
- 	return r;
- }
--EXPORT_SYMBOL(nftnl_rule_list_iter_next);
- 
--void nftnl_rule_list_iter_destroy(const struct nftnl_rule_list_iter *iter)
-+void __EXPORTED nftnl_rule_list_iter_destroy(const struct nftnl_rule_list_iter *iter)
- {
- 	xfree(iter);
- }
--EXPORT_SYMBOL(nftnl_rule_list_iter_destroy);
-diff --git a/src/ruleset.c b/src/ruleset.c
-index 6ef2956..10d48f6 100644
---- a/src/ruleset.c
-+++ b/src/ruleset.c
-@@ -55,13 +55,12 @@ struct nftnl_parse_ctx {
- 	uint16_t flags;
- };
- 
--struct nftnl_ruleset *nftnl_ruleset_alloc(void)
-+struct nftnl_ruleset __EXPORTED *nftnl_ruleset_alloc(void)
- {
- 	return calloc(1, sizeof(struct nftnl_ruleset));
- }
--EXPORT_SYMBOL(nftnl_ruleset_alloc);
- 
--void nftnl_ruleset_free(const struct nftnl_ruleset *r)
-+void __EXPORTED nftnl_ruleset_free(const struct nftnl_ruleset *r)
- {
- 	if (r->flags & (1 << NFTNL_RULESET_TABLELIST))
- 		nftnl_table_list_free(r->table_list);
-@@ -73,15 +72,13 @@ void nftnl_ruleset_free(const struct nftnl_ruleset *r)
- 		nftnl_rule_list_free(r->rule_list);
- 	xfree(r);
- }
--EXPORT_SYMBOL(nftnl_ruleset_free);
- 
--bool nftnl_ruleset_is_set(const struct nftnl_ruleset *r, uint16_t attr)
-+bool __EXPORTED nftnl_ruleset_is_set(const struct nftnl_ruleset *r, uint16_t attr)
- {
- 	return r->flags & (1 << attr);
- }
--EXPORT_SYMBOL(nftnl_ruleset_is_set);
- 
--void nftnl_ruleset_unset(struct nftnl_ruleset *r, uint16_t attr)
-+void __EXPORTED nftnl_ruleset_unset(struct nftnl_ruleset *r, uint16_t attr)
- {
- 	if (!(r->flags & (1 << attr)))
- 		return;
-@@ -102,9 +99,8 @@ void nftnl_ruleset_unset(struct nftnl_ruleset *r, uint16_t attr)
- 	}
- 	r->flags &= ~(1 << attr);
- }
--EXPORT_SYMBOL(nftnl_ruleset_unset);
- 
--void nftnl_ruleset_set(struct nftnl_ruleset *r, uint16_t attr, void *data)
-+void __EXPORTED nftnl_ruleset_set(struct nftnl_ruleset *r, uint16_t attr, void *data)
- {
- 	switch (attr) {
- 	case NFTNL_RULESET_TABLELIST:
-@@ -128,9 +124,8 @@ void nftnl_ruleset_set(struct nftnl_ruleset *r, uint16_t attr, void *data)
- 	}
- 	r->flags |= (1 << attr);
- }
--EXPORT_SYMBOL(nftnl_ruleset_set);
- 
--void *nftnl_ruleset_get(const struct nftnl_ruleset *r, uint16_t attr)
-+void __EXPORTED *nftnl_ruleset_get(const struct nftnl_ruleset *r, uint16_t attr)
- {
- 	if (!(r->flags & (1 << attr)))
- 		return NULL;
-@@ -148,9 +143,8 @@ void *nftnl_ruleset_get(const struct nftnl_ruleset *r, uint16_t attr)
- 		return NULL;
- 	}
- }
--EXPORT_SYMBOL(nftnl_ruleset_get);
- 
--void nftnl_ruleset_ctx_free(const struct nftnl_parse_ctx *ctx)
-+void __EXPORTED nftnl_ruleset_ctx_free(const struct nftnl_parse_ctx *ctx)
- {
- 	switch (ctx->type) {
- 	case NFTNL_RULESET_TABLE:
-@@ -171,15 +165,13 @@ void nftnl_ruleset_ctx_free(const struct nftnl_parse_ctx *ctx)
- 		break;
- 	}
- }
--EXPORT_SYMBOL(nftnl_ruleset_ctx_free);
- 
--bool nftnl_ruleset_ctx_is_set(const struct nftnl_parse_ctx *ctx, uint16_t attr)
-+bool __EXPORTED nftnl_ruleset_ctx_is_set(const struct nftnl_parse_ctx *ctx, uint16_t attr)
- {
- 	return ctx->flags & (1 << attr);
- }
--EXPORT_SYMBOL(nftnl_ruleset_ctx_is_set);
- 
--void *nftnl_ruleset_ctx_get(const struct nftnl_parse_ctx *ctx, uint16_t attr)
-+void __EXPORTED *nftnl_ruleset_ctx_get(const struct nftnl_parse_ctx *ctx, uint16_t attr)
- {
- 	if (!(ctx->flags & (1 << attr)))
- 		return NULL;
-@@ -203,14 +195,12 @@ void *nftnl_ruleset_ctx_get(const struct nftnl_parse_ctx *ctx, uint16_t attr)
- 		return NULL;
- 	}
- }
--EXPORT_SYMBOL(nftnl_ruleset_ctx_get);
- 
--uint32_t nftnl_ruleset_ctx_get_u32(const struct nftnl_parse_ctx *ctx, uint16_t attr)
-+uint32_t __EXPORTED nftnl_ruleset_ctx_get_u32(const struct nftnl_parse_ctx *ctx, uint16_t attr)
- {
- 	const void *ret = nftnl_ruleset_ctx_get(ctx, attr);
- 	return ret == NULL ? 0 : *((uint32_t *)ret);
- }
--EXPORT_SYMBOL(nftnl_ruleset_ctx_get_u32);
- 
- #if defined(JSON_PARSING)
- static void nftnl_ruleset_ctx_set(struct nftnl_parse_ctx *ctx, uint16_t attr,
-@@ -593,22 +583,20 @@ nftnl_ruleset_do_parse(enum nftnl_parse_type type, const void *data,
- 	return ret;
- }
- 
--int nftnl_ruleset_parse_file_cb(enum nftnl_parse_type type, FILE *fp,
-+int __EXPORTED nftnl_ruleset_parse_file_cb(enum nftnl_parse_type type, FILE *fp,
- 			      struct nftnl_parse_err *err, void *data,
- 			      int (*cb)(const struct nftnl_parse_ctx *ctx))
- {
- 	return nftnl_ruleset_do_parse(type, fp, err, NFTNL_PARSE_FILE, data, cb);
- }
--EXPORT_SYMBOL(nftnl_ruleset_parse_file_cb);
- 
--int nftnl_ruleset_parse_buffer_cb(enum nftnl_parse_type type, const char *buffer,
-+int __EXPORTED nftnl_ruleset_parse_buffer_cb(enum nftnl_parse_type type, const char *buffer,
- 				struct nftnl_parse_err *err, void *data,
- 				int (*cb)(const struct nftnl_parse_ctx *ctx))
- {
- 	return nftnl_ruleset_do_parse(type, buffer, err, NFTNL_PARSE_BUFFER, data,
- 				    cb);
- }
--EXPORT_SYMBOL(nftnl_ruleset_parse_buffer_cb);
- 
- static int nftnl_ruleset_cb(const struct nftnl_parse_ctx *ctx)
- {
-@@ -671,19 +659,17 @@ static int nftnl_ruleset_cb(const struct nftnl_parse_ctx *ctx)
- 	return 0;
- }
- 
--int nftnl_ruleset_parse(struct nftnl_ruleset *r, enum nftnl_parse_type type,
-+int __EXPORTED nftnl_ruleset_parse(struct nftnl_ruleset *r, enum nftnl_parse_type type,
- 		      const char *data, struct nftnl_parse_err *err)
- {
- 	return nftnl_ruleset_parse_buffer_cb(type, data, err, r, nftnl_ruleset_cb);
- }
--EXPORT_SYMBOL(nftnl_ruleset_parse);
- 
--int nftnl_ruleset_parse_file(struct nftnl_ruleset *rs, enum nftnl_parse_type type,
-+int __EXPORTED nftnl_ruleset_parse_file(struct nftnl_ruleset *rs, enum nftnl_parse_type type,
- 			   FILE *fp, struct nftnl_parse_err *err)
- {
- 	return nftnl_ruleset_parse_file_cb(type, fp, err, rs, nftnl_ruleset_cb);
- }
--EXPORT_SYMBOL(nftnl_ruleset_parse_file);
- 
- static const char *nftnl_ruleset_o_opentag(uint32_t type)
- {
-@@ -928,7 +914,7 @@ static int nftnl_ruleset_cmd_snprintf(char *buf, size_t size,
- 	}
- }
- 
--int nftnl_ruleset_snprintf(char *buf, size_t size, const struct nftnl_ruleset *r,
-+int __EXPORTED nftnl_ruleset_snprintf(char *buf, size_t size, const struct nftnl_ruleset *r,
- 			 uint32_t type, uint32_t flags)
- {
- 	switch (type) {
-@@ -943,7 +929,6 @@ int nftnl_ruleset_snprintf(char *buf, size_t size, const struct nftnl_ruleset *r
- 		return -1;
- 	}
- }
--EXPORT_SYMBOL(nftnl_ruleset_snprintf);
- 
- static int nftnl_ruleset_fprintf_tables(FILE *fp, const struct nftnl_ruleset *rs,
- 				      uint32_t type, uint32_t flags)
-@@ -1157,10 +1142,9 @@ static int nftnl_ruleset_cmd_fprintf(FILE *fp, const struct nftnl_ruleset *rs,
- 	return len;
- }
- 
--int nftnl_ruleset_fprintf(FILE *fp, const struct nftnl_ruleset *rs, uint32_t type,
-+int __EXPORTED nftnl_ruleset_fprintf(FILE *fp, const struct nftnl_ruleset *rs, uint32_t type,
- 			uint32_t flags)
- {
- 	return nftnl_ruleset_cmd_fprintf(fp, rs, nftnl_flag2cmd(flags), type,
- 				       flags);
- }
--EXPORT_SYMBOL(nftnl_ruleset_fprintf);
-diff --git a/src/set.c b/src/set.c
-index cce5e63..33a6794 100644
---- a/src/set.c
-+++ b/src/set.c
-@@ -27,7 +27,7 @@
- #include <libnftnl/set.h>
- #include <libnftnl/expr.h>
- 
--struct nftnl_set *nftnl_set_alloc(void)
-+struct nftnl_set __EXPORTED *nftnl_set_alloc(void)
- {
- 	struct nftnl_set *s;
- 
-@@ -38,9 +38,8 @@ struct nftnl_set *nftnl_set_alloc(void)
- 	INIT_LIST_HEAD(&s->element_list);
- 	return s;
- }
--EXPORT_SYMBOL(nftnl_set_alloc);
- 
--void nftnl_set_free(const struct nftnl_set *s)
-+void __EXPORTED nftnl_set_free(const struct nftnl_set *s)
- {
- 	struct nftnl_set_elem *elem, *tmp;
- 
-@@ -55,15 +54,13 @@ void nftnl_set_free(const struct nftnl_set *s)
- 	}
- 	xfree(s);
- }
--EXPORT_SYMBOL(nftnl_set_free);
- 
--bool nftnl_set_is_set(const struct nftnl_set *s, uint16_t attr)
-+bool __EXPORTED nftnl_set_is_set(const struct nftnl_set *s, uint16_t attr)
- {
- 	return s->flags & (1 << attr);
- }
--EXPORT_SYMBOL(nftnl_set_is_set);
- 
--void nftnl_set_unset(struct nftnl_set *s, uint16_t attr)
-+void __EXPORTED nftnl_set_unset(struct nftnl_set *s, uint16_t attr)
- {
- 	if (!(s->flags & (1 << attr)))
- 		return;
-@@ -97,7 +94,6 @@ void nftnl_set_unset(struct nftnl_set *s, uint16_t attr)
- 
- 	s->flags &= ~(1 << attr);
- }
--EXPORT_SYMBOL(nftnl_set_unset);
- 
- static uint32_t nftnl_set_validate[NFTNL_SET_MAX + 1] = {
- 	[NFTNL_SET_FLAGS]		= sizeof(uint32_t),
-@@ -113,7 +109,7 @@ static uint32_t nftnl_set_validate[NFTNL_SET_MAX + 1] = {
- 	[NFTNL_SET_GC_INTERVAL]	= sizeof(uint32_t),
- };
- 
--int nftnl_set_set_data(struct nftnl_set *s, uint16_t attr, const void *data,
-+int __EXPORTED nftnl_set_set_data(struct nftnl_set *s, uint16_t attr, const void *data,
- 		       uint32_t data_len)
- {
- 	nftnl_assert_attr_exists(attr, NFTNL_SET_MAX);
-@@ -186,33 +182,28 @@ int nftnl_set_set_data(struct nftnl_set *s, uint16_t attr, const void *data,
- 	s->flags |= (1 << attr);
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_set_set_data);
- 
--int nftnl_set_set(struct nftnl_set *s, uint16_t attr, const void *data)
-+int __EXPORTED nftnl_set_set(struct nftnl_set *s, uint16_t attr, const void *data)
- {
- 	return nftnl_set_set_data(s, attr, data, nftnl_set_validate[attr]);
- }
--EXPORT_SYMBOL(nftnl_set_set);
- 
--void nftnl_set_set_u32(struct nftnl_set *s, uint16_t attr, uint32_t val)
-+void __EXPORTED nftnl_set_set_u32(struct nftnl_set *s, uint16_t attr, uint32_t val)
- {
- 	nftnl_set_set(s, attr, &val);
- }
--EXPORT_SYMBOL(nftnl_set_set_u32);
- 
--void nftnl_set_set_u64(struct nftnl_set *s, uint16_t attr, uint64_t val)
-+void __EXPORTED nftnl_set_set_u64(struct nftnl_set *s, uint16_t attr, uint64_t val)
- {
- 	nftnl_set_set(s, attr, &val);
- }
--EXPORT_SYMBOL(nftnl_set_set_u64);
- 
--int nftnl_set_set_str(struct nftnl_set *s, uint16_t attr, const char *str)
-+int __EXPORTED nftnl_set_set_str(struct nftnl_set *s, uint16_t attr, const char *str)
- {
- 	return nftnl_set_set_data(s, attr, str, strlen(str) + 1);
- }
--EXPORT_SYMBOL(nftnl_set_set_str);
- 
--const void *nftnl_set_get_data(const struct nftnl_set *s, uint16_t attr,
-+const void __EXPORTED *nftnl_set_get_data(const struct nftnl_set *s, uint16_t attr,
- 			       uint32_t *data_len)
- {
- 	if (!(s->flags & (1 << attr)))
-@@ -267,22 +258,19 @@ const void *nftnl_set_get_data(const struct nftnl_set *s, uint16_t attr,
- 	}
- 	return NULL;
- }
--EXPORT_SYMBOL(nftnl_set_get_data);
- 
--const void *nftnl_set_get(const struct nftnl_set *s, uint16_t attr)
-+const void __EXPORTED *nftnl_set_get(const struct nftnl_set *s, uint16_t attr)
- {
- 	uint32_t data_len;
- 	return nftnl_set_get_data(s, attr, &data_len);
- }
--EXPORT_SYMBOL(nftnl_set_get);
- 
--const char *nftnl_set_get_str(const struct nftnl_set *s, uint16_t attr)
-+const char __EXPORTED *nftnl_set_get_str(const struct nftnl_set *s, uint16_t attr)
- {
- 	return nftnl_set_get(s, attr);
- }
--EXPORT_SYMBOL(nftnl_set_get_str);
- 
--uint32_t nftnl_set_get_u32(const struct nftnl_set *s, uint16_t attr)
-+uint32_t __EXPORTED nftnl_set_get_u32(const struct nftnl_set *s, uint16_t attr)
- {
- 	uint32_t data_len;
- 	const uint32_t *val = nftnl_set_get_data(s, attr, &data_len);
-@@ -291,9 +279,8 @@ uint32_t nftnl_set_get_u32(const struct nftnl_set *s, uint16_t attr)
- 
- 	return val ? *val : 0;
- }
--EXPORT_SYMBOL(nftnl_set_get_u32);
- 
--uint64_t nftnl_set_get_u64(const struct nftnl_set *s, uint16_t attr)
-+uint64_t __EXPORTED nftnl_set_get_u64(const struct nftnl_set *s, uint16_t attr)
- {
- 	uint32_t data_len;
- 	const uint64_t *val = nftnl_set_get_data(s, attr, &data_len);
-@@ -302,7 +289,6 @@ uint64_t nftnl_set_get_u64(const struct nftnl_set *s, uint16_t attr)
- 
- 	return val ? *val : 0;
- }
--EXPORT_SYMBOL(nftnl_set_get_u64);
- 
- struct nftnl_set *nftnl_set_clone(const struct nftnl_set *set)
- {
-@@ -351,7 +337,7 @@ nftnl_set_nlmsg_build_desc_payload(struct nlmsghdr *nlh, struct nftnl_set *s)
- 	mnl_attr_nest_end(nlh, nest);
- }
- 
--void nftnl_set_nlmsg_build_payload(struct nlmsghdr *nlh, struct nftnl_set *s)
-+void __EXPORTED nftnl_set_nlmsg_build_payload(struct nlmsghdr *nlh, struct nftnl_set *s)
- {
- 	if (s->flags & (1 << NFTNL_SET_TABLE))
- 		mnl_attr_put_strz(nlh, NFTA_SET_TABLE, s->table);
-@@ -383,7 +369,6 @@ void nftnl_set_nlmsg_build_payload(struct nlmsghdr *nlh, struct nftnl_set *s)
- 	if (s->flags & (1 << NFTNL_SET_USERDATA))
- 		mnl_attr_put(nlh, NFTA_SET_USERDATA, s->user.len, s->user.data);
- }
--EXPORT_SYMBOL(nftnl_set_nlmsg_build_payload);
- 
- static int nftnl_set_parse_attr_cb(const struct nlattr *attr, void *data)
- {
-@@ -463,7 +448,7 @@ static int nftnl_set_desc_parse(struct nftnl_set *s,
- 	return 0;
- }
- 
--int nftnl_set_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_set *s)
-+int __EXPORTED nftnl_set_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_set *s)
- {
- 	struct nlattr *tb[NFTA_SET_MAX+1] = {};
- 	struct nfgenmsg *nfg = mnl_nlmsg_get_payload(nlh);
-@@ -546,7 +531,6 @@ int nftnl_set_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_set *s)
- 
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_set_nlmsg_parse);
- 
- #ifdef JSON_PARSING
- static int nftnl_jansson_parse_set_info(struct nftnl_set *s, json_t *tree,
-@@ -718,19 +702,17 @@ static int nftnl_set_do_parse(struct nftnl_set *s, enum nftnl_parse_type type,
- 
- 	return ret;
- }
--int nftnl_set_parse(struct nftnl_set *s, enum nftnl_parse_type type,
-+int __EXPORTED nftnl_set_parse(struct nftnl_set *s, enum nftnl_parse_type type,
- 		  const char *data, struct nftnl_parse_err *err)
- {
- 	return nftnl_set_do_parse(s, type, data, err, NFTNL_PARSE_BUFFER);
- }
--EXPORT_SYMBOL(nftnl_set_parse);
- 
--int nftnl_set_parse_file(struct nftnl_set *s, enum nftnl_parse_type type,
-+int __EXPORTED nftnl_set_parse_file(struct nftnl_set *s, enum nftnl_parse_type type,
- 		       FILE *fp, struct nftnl_parse_err *err)
- {
- 	return nftnl_set_do_parse(s, type, fp, err, NFTNL_PARSE_FILE);
- }
--EXPORT_SYMBOL(nftnl_set_parse_file);
- 
- static int nftnl_set_snprintf_json(char *buf, size_t size,
- 				   const struct nftnl_set *s,
-@@ -918,13 +900,12 @@ static int nftnl_set_cmd_snprintf(char *buf, size_t size,
- 	return offset;
- }
- 
--int nftnl_set_snprintf(char *buf, size_t size, const struct nftnl_set *s,
-+int __EXPORTED nftnl_set_snprintf(char *buf, size_t size, const struct nftnl_set *s,
- 		       uint32_t type, uint32_t flags)
- {
- 	return nftnl_set_cmd_snprintf(buf, size, s, nftnl_flag2cmd(flags), type,
- 				    flags);
- }
--EXPORT_SYMBOL(nftnl_set_snprintf);
- 
- static int nftnl_set_do_snprintf(char *buf, size_t size, const void *s,
- 				 uint32_t cmd, uint32_t type, uint32_t flags)
-@@ -932,25 +913,23 @@ static int nftnl_set_do_snprintf(char *buf, size_t size, const void *s,
- 	return nftnl_set_snprintf(buf, size, s, type, flags);
- }
- 
--int nftnl_set_fprintf(FILE *fp, const struct nftnl_set *s, uint32_t type,
-+int __EXPORTED nftnl_set_fprintf(FILE *fp, const struct nftnl_set *s, uint32_t type,
- 		      uint32_t flags)
- {
- 	return nftnl_fprintf(fp, s, NFTNL_CMD_UNSPEC, type, flags,
- 			   nftnl_set_do_snprintf);
- }
--EXPORT_SYMBOL(nftnl_set_fprintf);
- 
--void nftnl_set_elem_add(struct nftnl_set *s, struct nftnl_set_elem *elem)
-+void __EXPORTED nftnl_set_elem_add(struct nftnl_set *s, struct nftnl_set_elem *elem)
- {
- 	list_add_tail(&elem->head, &s->element_list);
- }
--EXPORT_SYMBOL(nftnl_set_elem_add);
- 
- struct nftnl_set_list {
- 	struct list_head list;
- };
- 
--struct nftnl_set_list *nftnl_set_list_alloc(void)
-+struct nftnl_set_list __EXPORTED *nftnl_set_list_alloc(void)
- {
- 	struct nftnl_set_list *list;
- 
-@@ -962,9 +941,8 @@ struct nftnl_set_list *nftnl_set_list_alloc(void)
- 
- 	return list;
- }
--EXPORT_SYMBOL(nftnl_set_list_alloc);
- 
--void nftnl_set_list_free(struct nftnl_set_list *list)
-+void __EXPORTED nftnl_set_list_free(struct nftnl_set_list *list)
- {
- 	struct nftnl_set *s, *tmp;
- 
-@@ -974,33 +952,28 @@ void nftnl_set_list_free(struct nftnl_set_list *list)
- 	}
- 	xfree(list);
- }
--EXPORT_SYMBOL(nftnl_set_list_free);
- 
--int nftnl_set_list_is_empty(const struct nftnl_set_list *list)
-+int __EXPORTED nftnl_set_list_is_empty(const struct nftnl_set_list *list)
- {
- 	return list_empty(&list->list);
- }
--EXPORT_SYMBOL(nftnl_set_list_is_empty);
- 
--void nftnl_set_list_add(struct nftnl_set *s, struct nftnl_set_list *list)
-+void __EXPORTED nftnl_set_list_add(struct nftnl_set *s, struct nftnl_set_list *list)
- {
- 	list_add(&s->head, &list->list);
- }
--EXPORT_SYMBOL(nftnl_set_list_add);
- 
--void nftnl_set_list_add_tail(struct nftnl_set *s, struct nftnl_set_list *list)
-+void __EXPORTED nftnl_set_list_add_tail(struct nftnl_set *s, struct nftnl_set_list *list)
- {
- 	list_add_tail(&s->head, &list->list);
- }
--EXPORT_SYMBOL(nftnl_set_list_add_tail);
- 
--void nftnl_set_list_del(struct nftnl_set *s)
-+void __EXPORTED nftnl_set_list_del(struct nftnl_set *s)
- {
- 	list_del(&s->head);
- }
--EXPORT_SYMBOL(nftnl_set_list_del);
- 
--int nftnl_set_list_foreach(struct nftnl_set_list *set_list,
-+int __EXPORTED nftnl_set_list_foreach(struct nftnl_set_list *set_list,
- 			 int (*cb)(struct nftnl_set *t, void *data), void *data)
- {
- 	struct nftnl_set *cur, *tmp;
-@@ -1013,14 +986,13 @@ int nftnl_set_list_foreach(struct nftnl_set_list *set_list,
- 	}
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_set_list_foreach);
- 
- struct nftnl_set_list_iter {
- 	const struct nftnl_set_list	*list;
- 	struct nftnl_set		*cur;
- };
- 
--struct nftnl_set_list_iter *
-+struct nftnl_set_list_iter __EXPORTED *
- nftnl_set_list_iter_create(const struct nftnl_set_list *l)
- {
- 	struct nftnl_set_list_iter *iter;
-@@ -1037,16 +1009,14 @@ nftnl_set_list_iter_create(const struct nftnl_set_list *l)
- 
- 	return iter;
- }
--EXPORT_SYMBOL(nftnl_set_list_iter_create);
- 
--struct nftnl_set *
-+struct nftnl_set __EXPORTED *
- nftnl_set_list_iter_cur(const struct nftnl_set_list_iter *iter)
- {
- 	return iter->cur;
- }
--EXPORT_SYMBOL(nftnl_set_list_iter_cur);
- 
--struct nftnl_set *nftnl_set_list_iter_next(struct nftnl_set_list_iter *iter)
-+struct nftnl_set __EXPORTED *nftnl_set_list_iter_next(struct nftnl_set_list_iter *iter)
- {
- 	struct nftnl_set *s = iter->cur;
- 
-@@ -1060,13 +1030,11 @@ struct nftnl_set *nftnl_set_list_iter_next(struct nftnl_set_list_iter *iter)
- 
- 	return s;
- }
--EXPORT_SYMBOL(nftnl_set_list_iter_next);
- 
--void nftnl_set_list_iter_destroy(const struct nftnl_set_list_iter *iter)
-+void __EXPORTED nftnl_set_list_iter_destroy(const struct nftnl_set_list_iter *iter)
- {
- 	xfree(iter);
- }
--EXPORT_SYMBOL(nftnl_set_list_iter_destroy);
- 
- static struct nftnl_set *nftnl_set_lookup(const char *this_set_name,
- 				      struct nftnl_set_list *set_list)
-diff --git a/src/set_elem.c b/src/set_elem.c
-index 433b896..bd1e895 100644
---- a/src/set_elem.c
-+++ b/src/set_elem.c
-@@ -27,7 +27,7 @@
- #include <libnftnl/rule.h>
- #include <libnftnl/expr.h>
- 
--struct nftnl_set_elem *nftnl_set_elem_alloc(void)
-+struct nftnl_set_elem __EXPORTED *nftnl_set_elem_alloc(void)
- {
- 	struct nftnl_set_elem *s;
- 
-@@ -37,9 +37,8 @@ struct nftnl_set_elem *nftnl_set_elem_alloc(void)
- 
- 	return s;
- }
--EXPORT_SYMBOL(nftnl_set_elem_alloc);
- 
--void nftnl_set_elem_free(struct nftnl_set_elem *s)
-+void __EXPORTED nftnl_set_elem_free(struct nftnl_set_elem *s)
- {
- 	if (s->flags & (1 << NFTNL_SET_ELEM_CHAIN))
- 		xfree(s->data.chain);
-@@ -55,15 +54,13 @@ void nftnl_set_elem_free(struct nftnl_set_elem *s)
- 
- 	xfree(s);
- }
--EXPORT_SYMBOL(nftnl_set_elem_free);
- 
--bool nftnl_set_elem_is_set(const struct nftnl_set_elem *s, uint16_t attr)
-+bool __EXPORTED nftnl_set_elem_is_set(const struct nftnl_set_elem *s, uint16_t attr)
- {
- 	return s->flags & (1 << attr);
- }
--EXPORT_SYMBOL(nftnl_set_elem_is_set);
- 
--void nftnl_set_elem_unset(struct nftnl_set_elem *s, uint16_t attr)
-+void __EXPORTED nftnl_set_elem_unset(struct nftnl_set_elem *s, uint16_t attr)
- {
- 	if (!(s->flags & (1 << attr)))
- 		return;
-@@ -94,9 +91,8 @@ void nftnl_set_elem_unset(struct nftnl_set_elem *s, uint16_t attr)
- 
- 	s->flags &= ~(1 << attr);
- }
--EXPORT_SYMBOL(nftnl_set_elem_unset);
- 
--int nftnl_set_elem_set(struct nftnl_set_elem *s, uint16_t attr,
-+int __EXPORTED nftnl_set_elem_set(struct nftnl_set_elem *s, uint16_t attr,
- 		       const void *data, uint32_t data_len)
- {
- 	switch(attr) {
-@@ -147,27 +143,23 @@ int nftnl_set_elem_set(struct nftnl_set_elem *s, uint16_t attr,
- 	s->flags |= (1 << attr);
- 	return -1;
- }
--EXPORT_SYMBOL(nftnl_set_elem_set);
- 
--void nftnl_set_elem_set_u32(struct nftnl_set_elem *s, uint16_t attr, uint32_t val)
-+void __EXPORTED nftnl_set_elem_set_u32(struct nftnl_set_elem *s, uint16_t attr, uint32_t val)
- {
- 	nftnl_set_elem_set(s, attr, &val, sizeof(uint32_t));
- }
--EXPORT_SYMBOL(nftnl_set_elem_set_u32);
- 
--void nftnl_set_elem_set_u64(struct nftnl_set_elem *s, uint16_t attr, uint64_t val)
-+void __EXPORTED nftnl_set_elem_set_u64(struct nftnl_set_elem *s, uint16_t attr, uint64_t val)
- {
- 	nftnl_set_elem_set(s, attr, &val, sizeof(uint64_t));
- }
--EXPORT_SYMBOL(nftnl_set_elem_set_u64);
- 
--int nftnl_set_elem_set_str(struct nftnl_set_elem *s, uint16_t attr, const char *str)
-+int __EXPORTED nftnl_set_elem_set_str(struct nftnl_set_elem *s, uint16_t attr, const char *str)
- {
- 	return nftnl_set_elem_set(s, attr, str, strlen(str) + 1);
- }
--EXPORT_SYMBOL(nftnl_set_elem_set_str);
- 
--const void *nftnl_set_elem_get(struct nftnl_set_elem *s, uint16_t attr, uint32_t *data_len)
-+const void __EXPORTED *nftnl_set_elem_get(struct nftnl_set_elem *s, uint16_t attr, uint32_t *data_len)
- {
- 	if (!(s->flags & (1 << attr)))
- 		return NULL;
-@@ -205,31 +197,27 @@ const void *nftnl_set_elem_get(struct nftnl_set_elem *s, uint16_t attr, uint32_t
- 	}
- 	return NULL;
- }
--EXPORT_SYMBOL(nftnl_set_elem_get);
- 
--const char *nftnl_set_elem_get_str(struct nftnl_set_elem *s, uint16_t attr)
-+const char __EXPORTED *nftnl_set_elem_get_str(struct nftnl_set_elem *s, uint16_t attr)
- {
- 	uint32_t size;
- 
- 	return nftnl_set_elem_get(s, attr, &size);
- }
--EXPORT_SYMBOL(nftnl_set_elem_get_str);
- 
--uint32_t nftnl_set_elem_get_u32(struct nftnl_set_elem *s, uint16_t attr)
-+uint32_t __EXPORTED nftnl_set_elem_get_u32(struct nftnl_set_elem *s, uint16_t attr)
- {
- 	uint32_t size;
- 	uint32_t val = *((uint32_t *)nftnl_set_elem_get(s, attr, &size));
- 	return val;
- }
--EXPORT_SYMBOL(nftnl_set_elem_get_u32);
- 
--uint64_t nftnl_set_elem_get_u64(struct nftnl_set_elem *s, uint16_t attr)
-+uint64_t __EXPORTED nftnl_set_elem_get_u64(struct nftnl_set_elem *s, uint16_t attr)
- {
- 	uint32_t size;
- 	uint64_t val = *((uint64_t *)nftnl_set_elem_get(s, attr, &size));
- 	return val;
- }
--EXPORT_SYMBOL(nftnl_set_elem_get_u64);
- 
- struct nftnl_set_elem *nftnl_set_elem_clone(struct nftnl_set_elem *elem)
- {
-@@ -315,7 +303,7 @@ static struct nlattr *nftnl_set_elem_build(struct nlmsghdr *nlh,
- 	return nest2;
- }
- 
--void nftnl_set_elems_nlmsg_build_payload(struct nlmsghdr *nlh, struct nftnl_set *s)
-+void __EXPORTED nftnl_set_elems_nlmsg_build_payload(struct nlmsghdr *nlh, struct nftnl_set *s)
- {
- 	struct nftnl_set_elem *elem;
- 	struct nlattr *nest1;
-@@ -332,7 +320,6 @@ void nftnl_set_elems_nlmsg_build_payload(struct nlmsghdr *nlh, struct nftnl_set
- 
- 	mnl_attr_nest_end(nlh, nest1);
- }
--EXPORT_SYMBOL(nftnl_set_elems_nlmsg_build_payload);
- 
- static int nftnl_set_elem_parse_attr_cb(const struct nlattr *attr, void *data)
- {
-@@ -503,7 +490,7 @@ static int nftnl_set_elems_parse(struct nftnl_set *s, const struct nlattr *nest)
- 	return ret;
- }
- 
--int nftnl_set_elems_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_set *s)
-+int __EXPORTED nftnl_set_elems_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_set *s)
- {
- 	struct nlattr *tb[NFTA_SET_ELEM_LIST_MAX+1] = {};
- 	struct nfgenmsg *nfg = mnl_nlmsg_get_payload(nlh);
-@@ -546,7 +533,6 @@ int nftnl_set_elems_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_set *s)
- 
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_set_elems_nlmsg_parse);
- 
- static int nftnl_set_elem_json_parse(struct nftnl_set_elem *e, const void *json,
- 				   struct nftnl_parse_err *err,
-@@ -587,19 +573,17 @@ nftnl_set_elem_do_parse(struct nftnl_set_elem *e, enum nftnl_parse_type type,
- 
- 	return ret;
- }
--int nftnl_set_elem_parse(struct nftnl_set_elem *e, enum nftnl_parse_type type,
-+int __EXPORTED nftnl_set_elem_parse(struct nftnl_set_elem *e, enum nftnl_parse_type type,
- 		       const char *data, struct nftnl_parse_err *err)
- {
- 	return nftnl_set_elem_do_parse(e, type, data, err, NFTNL_PARSE_BUFFER);
- }
--EXPORT_SYMBOL(nftnl_set_elem_parse);
- 
--int nftnl_set_elem_parse_file(struct nftnl_set_elem *e, enum nftnl_parse_type type,
-+int __EXPORTED nftnl_set_elem_parse_file(struct nftnl_set_elem *e, enum nftnl_parse_type type,
- 			    FILE *fp, struct nftnl_parse_err *err)
- {
- 	return nftnl_set_elem_do_parse(e, type, fp, err, NFTNL_PARSE_FILE);
- }
--EXPORT_SYMBOL(nftnl_set_elem_parse_file);
- 
- static int nftnl_set_elem_snprintf_json(char *buf, size_t size,
- 					const struct nftnl_set_elem *e,
-@@ -719,14 +703,13 @@ static int nftnl_set_elem_cmd_snprintf(char *buf, size_t size,
- 	return offset;
- }
- 
--int nftnl_set_elem_snprintf(char *buf, size_t size,
-+int __EXPORTED nftnl_set_elem_snprintf(char *buf, size_t size,
- 			    const struct nftnl_set_elem *e,
- 			    uint32_t type, uint32_t flags)
- {
- 	return nftnl_set_elem_cmd_snprintf(buf, size, e, nftnl_flag2cmd(flags),
- 					 type, flags);
- }
--EXPORT_SYMBOL(nftnl_set_elem_snprintf);
- 
- static int nftnl_set_elem_do_snprintf(char *buf, size_t size, const void *e,
- 				      uint32_t cmd, uint32_t type,
-@@ -735,15 +718,14 @@ static int nftnl_set_elem_do_snprintf(char *buf, size_t size, const void *e,
- 	return nftnl_set_elem_snprintf(buf, size, e, type, flags);
- }
- 
--int nftnl_set_elem_fprintf(FILE *fp, struct nftnl_set_elem *se, uint32_t type,
-+int __EXPORTED nftnl_set_elem_fprintf(FILE *fp, struct nftnl_set_elem *se, uint32_t type,
- 			 uint32_t flags)
- {
- 	return nftnl_fprintf(fp, se, NFTNL_CMD_UNSPEC, type, flags,
- 			   nftnl_set_elem_do_snprintf);
- }
--EXPORT_SYMBOL(nftnl_set_elem_fprintf);
- 
--int nftnl_set_elem_foreach(struct nftnl_set *s,
-+int __EXPORTED nftnl_set_elem_foreach(struct nftnl_set *s,
- 			 int (*cb)(struct nftnl_set_elem *e, void *data),
- 			 void *data)
- {
-@@ -757,7 +739,6 @@ int nftnl_set_elem_foreach(struct nftnl_set *s,
- 	}
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_set_elem_foreach);
- 
- struct nftnl_set_elems_iter {
- 	const struct nftnl_set		*set;
-@@ -765,7 +746,7 @@ struct nftnl_set_elems_iter {
- 	struct nftnl_set_elem		*cur;
- };
- 
--struct nftnl_set_elems_iter *
-+struct nftnl_set_elems_iter __EXPORTED *
- nftnl_set_elems_iter_create(const struct nftnl_set *s)
- {
- 	struct nftnl_set_elems_iter *iter;
-@@ -784,16 +765,14 @@ nftnl_set_elems_iter_create(const struct nftnl_set *s)
- 
- 	return iter;
- }
--EXPORT_SYMBOL(nftnl_set_elems_iter_create);
- 
--struct nftnl_set_elem *
-+struct nftnl_set_elem __EXPORTED *
- nftnl_set_elems_iter_cur(const struct nftnl_set_elems_iter *iter)
- {
- 	return iter->cur;
- }
--EXPORT_SYMBOL(nftnl_set_elems_iter_cur);
- 
--struct nftnl_set_elem *nftnl_set_elems_iter_next(struct nftnl_set_elems_iter *iter)
-+struct nftnl_set_elem __EXPORTED *nftnl_set_elems_iter_next(struct nftnl_set_elems_iter *iter)
- {
- 	struct nftnl_set_elem *s = iter->cur;
- 
-@@ -806,13 +785,11 @@ struct nftnl_set_elem *nftnl_set_elems_iter_next(struct nftnl_set_elems_iter *it
- 
- 	return s;
- }
--EXPORT_SYMBOL(nftnl_set_elems_iter_next);
- 
--void nftnl_set_elems_iter_destroy(struct nftnl_set_elems_iter *iter)
-+void __EXPORTED nftnl_set_elems_iter_destroy(struct nftnl_set_elems_iter *iter)
- {
- 	xfree(iter);
- }
--EXPORT_SYMBOL(nftnl_set_elems_iter_destroy);
- 
- static bool nftnl_attr_nest_overflow(struct nlmsghdr *nlh,
- 				   const struct nlattr *from,
-@@ -831,7 +808,7 @@ static bool nftnl_attr_nest_overflow(struct nlmsghdr *nlh,
- 	return false;
- }
- 
--int nftnl_set_elems_nlmsg_build_payload_iter(struct nlmsghdr *nlh,
-+int __EXPORTED nftnl_set_elems_nlmsg_build_payload_iter(struct nlmsghdr *nlh,
- 					   struct nftnl_set_elems_iter *iter)
- {
- 	struct nftnl_set_elem *elem;
-@@ -861,4 +838,3 @@ int nftnl_set_elems_nlmsg_build_payload_iter(struct nlmsghdr *nlh,
- 
- 	return ret;
- }
--EXPORT_SYMBOL(nftnl_set_elems_nlmsg_build_payload_iter);
-diff --git a/src/table.c b/src/table.c
-index a7d5a8f..0e99f3c 100644
---- a/src/table.c
-+++ b/src/table.c
-@@ -36,28 +36,25 @@ struct nftnl_table {
- 	uint32_t	flags;
- };
- 
--struct nftnl_table *nftnl_table_alloc(void)
-+struct nftnl_table __EXPORTED *nftnl_table_alloc(void)
- {
- 	return calloc(1, sizeof(struct nftnl_table));
- }
--EXPORT_SYMBOL(nftnl_table_alloc);
- 
--void nftnl_table_free(const struct nftnl_table *t)
-+void __EXPORTED nftnl_table_free(const struct nftnl_table *t)
- {
- 	if (t->flags & (1 << NFTNL_TABLE_NAME))
- 		xfree(t->name);
- 
- 	xfree(t);
- }
--EXPORT_SYMBOL(nftnl_table_free);
- 
--bool nftnl_table_is_set(const struct nftnl_table *t, uint16_t attr)
-+bool __EXPORTED nftnl_table_is_set(const struct nftnl_table *t, uint16_t attr)
- {
- 	return t->flags & (1 << attr);
- }
--EXPORT_SYMBOL(nftnl_table_is_set);
- 
--void nftnl_table_unset(struct nftnl_table *t, uint16_t attr)
-+void __EXPORTED nftnl_table_unset(struct nftnl_table *t, uint16_t attr)
- {
- 	if (!(t->flags & (1 << attr)))
- 		return;
-@@ -74,14 +71,13 @@ void nftnl_table_unset(struct nftnl_table *t, uint16_t attr)
- 	}
- 	t->flags &= ~(1 << attr);
- }
--EXPORT_SYMBOL(nftnl_table_unset);
- 
- static uint32_t nftnl_table_validate[NFTNL_TABLE_MAX + 1] = {
- 	[NFTNL_TABLE_FLAGS]	= sizeof(uint32_t),
- 	[NFTNL_TABLE_FAMILY]	= sizeof(uint32_t),
- };
- 
--int nftnl_table_set_data(struct nftnl_table *t, uint16_t attr,
-+int __EXPORTED nftnl_table_set_data(struct nftnl_table *t, uint16_t attr,
- 			 const void *data, uint32_t data_len)
- {
- 	nftnl_assert_attr_exists(attr, NFTNL_TABLE_MAX);
-@@ -109,33 +105,28 @@ int nftnl_table_set_data(struct nftnl_table *t, uint16_t attr,
- 	t->flags |= (1 << attr);
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_table_set_data);
- 
--void nftnl_table_set(struct nftnl_table *t, uint16_t attr, const void *data)
-+void __EXPORTED nftnl_table_set(struct nftnl_table *t, uint16_t attr, const void *data)
- {
- 	nftnl_table_set_data(t, attr, data, nftnl_table_validate[attr]);
- }
--EXPORT_SYMBOL(nftnl_table_set);
- 
--void nftnl_table_set_u32(struct nftnl_table *t, uint16_t attr, uint32_t val)
-+void __EXPORTED nftnl_table_set_u32(struct nftnl_table *t, uint16_t attr, uint32_t val)
- {
- 	nftnl_table_set_data(t, attr, &val, sizeof(uint32_t));
- }
--EXPORT_SYMBOL(nftnl_table_set_u32);
- 
--void nftnl_table_set_u8(struct nftnl_table *t, uint16_t attr, uint8_t val)
-+void __EXPORTED nftnl_table_set_u8(struct nftnl_table *t, uint16_t attr, uint8_t val)
- {
- 	nftnl_table_set_data(t, attr, &val, sizeof(uint8_t));
- }
--EXPORT_SYMBOL(nftnl_table_set_u8);
- 
--int nftnl_table_set_str(struct nftnl_table *t, uint16_t attr, const char *str)
-+int __EXPORTED nftnl_table_set_str(struct nftnl_table *t, uint16_t attr, const char *str)
- {
- 	return nftnl_table_set_data(t, attr, str, strlen(str) + 1);
- }
--EXPORT_SYMBOL(nftnl_table_set_str);
- 
--const void *nftnl_table_get_data(const struct nftnl_table *t, uint16_t attr,
-+const void __EXPORTED *nftnl_table_get_data(const struct nftnl_table *t, uint16_t attr,
- 				 uint32_t *data_len)
- {
- 	if (!(t->flags & (1 << attr)))
-@@ -157,43 +148,37 @@ const void *nftnl_table_get_data(const struct nftnl_table *t, uint16_t attr,
- 	}
- 	return NULL;
- }
--EXPORT_SYMBOL(nftnl_table_get_data);
- 
--const void *nftnl_table_get(const struct nftnl_table *t, uint16_t attr)
-+const void __EXPORTED *nftnl_table_get(const struct nftnl_table *t, uint16_t attr)
- {
- 	uint32_t data_len;
- 	return nftnl_table_get_data(t, attr, &data_len);
- }
--EXPORT_SYMBOL(nftnl_table_get);
- 
--uint32_t nftnl_table_get_u32(const struct nftnl_table *t, uint16_t attr)
-+uint32_t __EXPORTED nftnl_table_get_u32(const struct nftnl_table *t, uint16_t attr)
- {
- 	const void *ret = nftnl_table_get(t, attr);
- 	return ret == NULL ? 0 : *((uint32_t *)ret);
- }
--EXPORT_SYMBOL(nftnl_table_get_u32);
- 
--uint8_t nftnl_table_get_u8(const struct nftnl_table *t, uint16_t attr)
-+uint8_t __EXPORTED nftnl_table_get_u8(const struct nftnl_table *t, uint16_t attr)
- {
- 	const void *ret = nftnl_table_get(t, attr);
- 	return ret == NULL ? 0 : *((uint8_t *)ret);
- }
--EXPORT_SYMBOL(nftnl_table_get_u8);
- 
--const char *nftnl_table_get_str(const struct nftnl_table *t, uint16_t attr)
-+const char __EXPORTED *nftnl_table_get_str(const struct nftnl_table *t, uint16_t attr)
- {
- 	return nftnl_table_get(t, attr);
- }
--EXPORT_SYMBOL(nftnl_table_get_str);
- 
--void nftnl_table_nlmsg_build_payload(struct nlmsghdr *nlh, const struct nftnl_table *t)
-+void __EXPORTED nftnl_table_nlmsg_build_payload(struct nlmsghdr *nlh, const struct nftnl_table *t)
- {
- 	if (t->flags & (1 << NFTNL_TABLE_NAME))
- 		mnl_attr_put_strz(nlh, NFTA_TABLE_NAME, t->name);
- 	if (t->flags & (1 << NFTNL_TABLE_FLAGS))
- 		mnl_attr_put_u32(nlh, NFTA_TABLE_FLAGS, htonl(t->table_flags));
- }
--EXPORT_SYMBOL(nftnl_table_nlmsg_build_payload);
- 
- static int nftnl_table_parse_attr_cb(const struct nlattr *attr, void *data)
- {
-@@ -219,7 +204,7 @@ static int nftnl_table_parse_attr_cb(const struct nlattr *attr, void *data)
- 	return MNL_CB_OK;
- }
- 
--int nftnl_table_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_table *t)
-+int __EXPORTED nftnl_table_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_table *t)
- {
- 	struct nlattr *tb[NFTA_TABLE_MAX+1] = {};
- 	struct nfgenmsg *nfg = mnl_nlmsg_get_payload(nlh);
-@@ -249,7 +234,6 @@ int nftnl_table_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_table *t)
- 
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_table_nlmsg_parse);
- 
- #ifdef JSON_PARSING
- int nftnl_jansson_parse_table(struct nftnl_table *t, json_t *tree,
-@@ -330,19 +314,17 @@ static int nftnl_table_do_parse(struct nftnl_table *t, enum nftnl_parse_type typ
- 	return ret;
- }
- 
--int nftnl_table_parse(struct nftnl_table *t, enum nftnl_parse_type type,
-+int __EXPORTED nftnl_table_parse(struct nftnl_table *t, enum nftnl_parse_type type,
- 		    const char *data, struct nftnl_parse_err *err)
- {
- 	return nftnl_table_do_parse(t, type, data, err, NFTNL_PARSE_BUFFER);
- }
--EXPORT_SYMBOL(nftnl_table_parse);
- 
--int nftnl_table_parse_file(struct nftnl_table *t, enum nftnl_parse_type type,
-+int __EXPORTED nftnl_table_parse_file(struct nftnl_table *t, enum nftnl_parse_type type,
- 			 FILE *fp, struct nftnl_parse_err *err)
- {
- 	return nftnl_table_do_parse(t, type, fp, err, NFTNL_PARSE_FILE);
- }
--EXPORT_SYMBOL(nftnl_table_parse_file);
- 
- static int nftnl_table_export(char *buf, size_t size,
- 			      const struct nftnl_table *t, int type)
-@@ -400,13 +382,12 @@ static int nftnl_table_cmd_snprintf(char *buf, size_t size,
- 	return offset;
- }
- 
--int nftnl_table_snprintf(char *buf, size_t size, const struct nftnl_table *t,
-+int __EXPORTED nftnl_table_snprintf(char *buf, size_t size, const struct nftnl_table *t,
- 			 uint32_t type, uint32_t flags)
- {
- 	return nftnl_table_cmd_snprintf(buf, size, t, nftnl_flag2cmd(flags), type,
- 				      flags);
- }
--EXPORT_SYMBOL(nftnl_table_snprintf);
- 
- static int nftnl_table_do_snprintf(char *buf, size_t size, const void *t,
- 				   uint32_t cmd, uint32_t type, uint32_t flags)
-@@ -414,19 +395,18 @@ static int nftnl_table_do_snprintf(char *buf, size_t size, const void *t,
- 	return nftnl_table_snprintf(buf, size, t, type, flags);
- }
- 
--int nftnl_table_fprintf(FILE *fp, const struct nftnl_table *t, uint32_t type,
-+int __EXPORTED nftnl_table_fprintf(FILE *fp, const struct nftnl_table *t, uint32_t type,
- 			uint32_t flags)
- {
- 	return nftnl_fprintf(fp, t, NFTNL_CMD_UNSPEC, type, flags,
- 			   nftnl_table_do_snprintf);
- }
--EXPORT_SYMBOL(nftnl_table_fprintf);
- 
- struct nftnl_table_list {
- 	struct list_head list;
- };
- 
--struct nftnl_table_list *nftnl_table_list_alloc(void)
-+struct nftnl_table_list __EXPORTED *nftnl_table_list_alloc(void)
- {
- 	struct nftnl_table_list *list;
- 
-@@ -438,9 +418,8 @@ struct nftnl_table_list *nftnl_table_list_alloc(void)
- 
- 	return list;
- }
--EXPORT_SYMBOL(nftnl_table_list_alloc);
- 
--void nftnl_table_list_free(struct nftnl_table_list *list)
-+void __EXPORTED nftnl_table_list_free(struct nftnl_table_list *list)
- {
- 	struct nftnl_table *r, *tmp;
- 
-@@ -450,33 +429,28 @@ void nftnl_table_list_free(struct nftnl_table_list *list)
- 	}
- 	xfree(list);
- }
--EXPORT_SYMBOL(nftnl_table_list_free);
- 
--int nftnl_table_list_is_empty(const struct nftnl_table_list *list)
-+int __EXPORTED nftnl_table_list_is_empty(const struct nftnl_table_list *list)
- {
- 	return list_empty(&list->list);
- }
--EXPORT_SYMBOL(nftnl_table_list_is_empty);
- 
--void nftnl_table_list_add(struct nftnl_table *r, struct nftnl_table_list *list)
-+void __EXPORTED nftnl_table_list_add(struct nftnl_table *r, struct nftnl_table_list *list)
- {
- 	list_add(&r->head, &list->list);
- }
--EXPORT_SYMBOL(nftnl_table_list_add);
- 
--void nftnl_table_list_add_tail(struct nftnl_table *r, struct nftnl_table_list *list)
-+void __EXPORTED nftnl_table_list_add_tail(struct nftnl_table *r, struct nftnl_table_list *list)
- {
- 	list_add_tail(&r->head, &list->list);
- }
--EXPORT_SYMBOL(nftnl_table_list_add_tail);
- 
--void nftnl_table_list_del(struct nftnl_table *t)
-+void __EXPORTED nftnl_table_list_del(struct nftnl_table *t)
- {
- 	list_del(&t->head);
- }
--EXPORT_SYMBOL(nftnl_table_list_del);
- 
--int nftnl_table_list_foreach(struct nftnl_table_list *table_list,
-+int __EXPORTED nftnl_table_list_foreach(struct nftnl_table_list *table_list,
- 			   int (*cb)(struct nftnl_table *t, void *data),
- 			   void *data)
- {
-@@ -490,14 +464,13 @@ int nftnl_table_list_foreach(struct nftnl_table_list *table_list,
- 	}
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_table_list_foreach);
- 
- struct nftnl_table_list_iter {
- 	const struct nftnl_table_list	*list;
- 	struct nftnl_table		*cur;
- };
- 
--struct nftnl_table_list_iter *
-+struct nftnl_table_list_iter __EXPORTED *
- nftnl_table_list_iter_create(const struct nftnl_table_list *l)
- {
- 	struct nftnl_table_list_iter *iter;
-@@ -514,9 +487,8 @@ nftnl_table_list_iter_create(const struct nftnl_table_list *l)
- 
- 	return iter;
- }
--EXPORT_SYMBOL(nftnl_table_list_iter_create);
- 
--struct nftnl_table *nftnl_table_list_iter_next(struct nftnl_table_list_iter *iter)
-+struct nftnl_table __EXPORTED *nftnl_table_list_iter_next(struct nftnl_table_list_iter *iter)
- {
- 	struct nftnl_table *r = iter->cur;
- 
-@@ -530,10 +502,8 @@ struct nftnl_table *nftnl_table_list_iter_next(struct nftnl_table_list_iter *ite
- 
- 	return r;
- }
--EXPORT_SYMBOL(nftnl_table_list_iter_next);
- 
--void nftnl_table_list_iter_destroy(const struct nftnl_table_list_iter *iter)
-+void __EXPORTED nftnl_table_list_iter_destroy(const struct nftnl_table_list_iter *iter)
- {
- 	xfree(iter);
- }
--EXPORT_SYMBOL(nftnl_table_list_iter_destroy);
-diff --git a/src/trace.c b/src/trace.c
-index bd05d3c..4739ef9 100644
---- a/src/trace.c
-+++ b/src/trace.c
-@@ -52,14 +52,12 @@ struct nftnl_trace {
- 	uint32_t flags;
- };
- 
--EXPORT_SYMBOL(nftnl_trace_alloc);
--struct nftnl_trace *nftnl_trace_alloc(void)
-+struct nftnl_trace __EXPORTED *nftnl_trace_alloc(void)
- {
- 	return calloc(1, sizeof(struct nftnl_trace));
- }
- 
--EXPORT_SYMBOL(nftnl_trace_free);
--void nftnl_trace_free(const struct nftnl_trace *t)
-+void __EXPORTED nftnl_trace_free(const struct nftnl_trace *t)
- {
- 	xfree(t->chain);
- 	xfree(t->table);
-@@ -70,8 +68,7 @@ void nftnl_trace_free(const struct nftnl_trace *t)
- 	xfree(t);
- }
- 
--EXPORT_SYMBOL(nftnl_trace_is_set);
--bool nftnl_trace_is_set(const struct nftnl_trace *t, uint16_t attr)
-+bool __EXPORTED nftnl_trace_is_set(const struct nftnl_trace *t, uint16_t attr)
- {
- 	return t->flags & (1 << attr);
- }
-@@ -130,8 +127,7 @@ static int nftnl_trace_parse_attr_cb(const struct nlattr *attr, void *data)
- 	return MNL_CB_OK;
- }
- 
--EXPORT_SYMBOL(nftnl_trace_get_data);
--const void *nftnl_trace_get_data(const struct nftnl_trace *trace,
-+const void __EXPORTED *nftnl_trace_get_data(const struct nftnl_trace *trace,
- 				 uint16_t type, uint32_t *data_len)
- {
- 	enum nftnl_trace_attr attr = type;
-@@ -201,8 +197,7 @@ const void *nftnl_trace_get_data(const struct nftnl_trace *trace,
- 	return NULL;
- }
- 
--EXPORT_SYMBOL(nftnl_trace_get_str);
--const char *nftnl_trace_get_str(const struct nftnl_trace *trace, uint16_t type)
-+const char __EXPORTED *nftnl_trace_get_str(const struct nftnl_trace *trace, uint16_t type)
- {
- 	if (!nftnl_trace_is_set(trace, type))
- 		return NULL;
-@@ -216,8 +211,7 @@ const char *nftnl_trace_get_str(const struct nftnl_trace *trace, uint16_t type)
- 	return NULL;
- }
- 
--EXPORT_SYMBOL(nftnl_trace_get_u16);
--uint16_t nftnl_trace_get_u16(const struct nftnl_trace *trace, uint16_t type)
-+uint16_t __EXPORTED nftnl_trace_get_u16(const struct nftnl_trace *trace, uint16_t type)
- {
- 	const uint16_t *d;
- 	uint32_t dlen;
-@@ -229,8 +223,7 @@ uint16_t nftnl_trace_get_u16(const struct nftnl_trace *trace, uint16_t type)
- 	return 0;
- }
- 
--EXPORT_SYMBOL(nftnl_trace_get_u32);
--uint32_t nftnl_trace_get_u32(const struct nftnl_trace *trace, uint16_t type)
-+uint32_t __EXPORTED nftnl_trace_get_u32(const struct nftnl_trace *trace, uint16_t type)
- {
- 	const uint32_t *d;
- 	uint32_t dlen;
-@@ -242,8 +235,7 @@ uint32_t nftnl_trace_get_u32(const struct nftnl_trace *trace, uint16_t type)
- 	return 0;
- }
- 
--EXPORT_SYMBOL(nftnl_trace_get_u64);
--uint64_t nftnl_trace_get_u64(const struct nftnl_trace *trace, uint16_t type)
-+uint64_t __EXPORTED nftnl_trace_get_u64(const struct nftnl_trace *trace, uint16_t type)
- {
- 	const uint64_t *d;
- 	uint32_t dlen;
-@@ -323,9 +315,8 @@ static int nftnl_trace_parse_verdict(const struct nlattr *attr,
- 	}
- 	return 0;
- }
--EXPORT_SYMBOL(nftnl_trace_nlmsg_parse);
- 
--int nftnl_trace_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_trace *t)
-+int __EXPORTED nftnl_trace_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_trace *t)
- {
- 	struct nfgenmsg *nfg = mnl_nlmsg_get_payload(nlh);
- 	struct nlattr *tb[NFTA_TRACE_MAX+1] = {};
-diff --git a/src/udata.c b/src/udata.c
-index d679dd0..7e2de0f 100644
---- a/src/udata.c
-+++ b/src/udata.c
-@@ -16,7 +16,7 @@
- #include <stdint.h>
- #include <string.h>
- 
--struct nftnl_udata_buf *nftnl_udata_buf_alloc(uint32_t data_size)
-+struct nftnl_udata_buf __EXPORTED *nftnl_udata_buf_alloc(uint32_t data_size)
- {
- 	struct nftnl_udata_buf *buf;
- 
-@@ -28,47 +28,40 @@ struct nftnl_udata_buf *nftnl_udata_buf_alloc(uint32_t data_size)
- 
- 	return buf;
- }
--EXPORT_SYMBOL(nftnl_udata_buf_alloc);
- 
--void nftnl_udata_buf_free(const struct nftnl_udata_buf *buf)
-+void __EXPORTED nftnl_udata_buf_free(const struct nftnl_udata_buf *buf)
- {
- 	xfree(buf);
- }
--EXPORT_SYMBOL(nftnl_udata_buf_free);
- 
--uint32_t nftnl_udata_buf_len(const struct nftnl_udata_buf *buf)
-+uint32_t __EXPORTED nftnl_udata_buf_len(const struct nftnl_udata_buf *buf)
- {
- 	return (uint32_t)(buf->end - buf->data);
- }
--EXPORT_SYMBOL(nftnl_udata_buf_len);
- 
--void *nftnl_udata_buf_data(const struct nftnl_udata_buf *buf)
-+void __EXPORTED *nftnl_udata_buf_data(const struct nftnl_udata_buf *buf)
- {
- 	return (void *)buf->data;
- }
--EXPORT_SYMBOL(nftnl_udata_buf_data);
- 
--void nftnl_udata_buf_put(struct nftnl_udata_buf *buf, const void *data,
-+void __EXPORTED nftnl_udata_buf_put(struct nftnl_udata_buf *buf, const void *data,
- 			 uint32_t len)
- {
- 	memcpy(buf->data, data, len <= buf->size ? len : buf->size);
- 	buf->end = buf->data + len;
- }
--EXPORT_SYMBOL(nftnl_udata_buf_put);
- 
--struct nftnl_udata *nftnl_udata_start(const struct nftnl_udata_buf *buf)
-+struct nftnl_udata __EXPORTED *nftnl_udata_start(const struct nftnl_udata_buf *buf)
- {
- 	return (struct nftnl_udata *)buf->data;
- }
--EXPORT_SYMBOL(nftnl_udata_start);
- 
--struct nftnl_udata *nftnl_udata_end(const struct nftnl_udata_buf *buf)
-+struct nftnl_udata __EXPORTED *nftnl_udata_end(const struct nftnl_udata_buf *buf)
- {
- 	return (struct nftnl_udata *)buf->end;
- }
--EXPORT_SYMBOL(nftnl_udata_end);
- 
--bool nftnl_udata_put(struct nftnl_udata_buf *buf, uint8_t type, uint32_t len,
-+bool __EXPORTED nftnl_udata_put(struct nftnl_udata_buf *buf, uint8_t type, uint32_t len,
- 		     const void *value)
- {
- 	struct nftnl_udata *attr;
-@@ -85,55 +78,47 @@ bool nftnl_udata_put(struct nftnl_udata_buf *buf, uint8_t type, uint32_t len,
- 
- 	return true;
- }
--EXPORT_SYMBOL(nftnl_udata_put);
- 
--bool nftnl_udata_put_strz(struct nftnl_udata_buf *buf, uint8_t type,
-+bool __EXPORTED nftnl_udata_put_strz(struct nftnl_udata_buf *buf, uint8_t type,
- 			  const char *strz)
- {
- 	return nftnl_udata_put(buf, type, strlen(strz) + 1, strz);
- }
--EXPORT_SYMBOL(nftnl_udata_put_strz);
- 
--bool nftnl_udata_put_u32(struct nftnl_udata_buf *buf, uint8_t type,
-+bool __EXPORTED nftnl_udata_put_u32(struct nftnl_udata_buf *buf, uint8_t type,
- 			 uint32_t data)
- {
- 	return nftnl_udata_put(buf, type, sizeof(data), &data);
- }
--EXPORT_SYMBOL(nftnl_udata_put_u32);
- 
--uint8_t nftnl_udata_type(const struct nftnl_udata *attr)
-+uint8_t __EXPORTED nftnl_udata_type(const struct nftnl_udata *attr)
- {
- 	return attr->type;
- }
--EXPORT_SYMBOL(nftnl_udata_type);
- 
--uint8_t nftnl_udata_len(const struct nftnl_udata *attr)
-+uint8_t __EXPORTED nftnl_udata_len(const struct nftnl_udata *attr)
- {
- 	return attr->len;
- }
--EXPORT_SYMBOL(nftnl_udata_len);
- 
--void *nftnl_udata_get(const struct nftnl_udata *attr)
-+void __EXPORTED *nftnl_udata_get(const struct nftnl_udata *attr)
- {
- 	return (void *)attr->value;
- }
--EXPORT_SYMBOL(nftnl_udata_get);
- 
--uint32_t nftnl_udata_get_u32(const struct nftnl_udata *attr)
-+uint32_t __EXPORTED nftnl_udata_get_u32(const struct nftnl_udata *attr)
- {
- 	uint32_t *data = (uint32_t *)attr->value;
- 
- 	return *data;
- }
--EXPORT_SYMBOL(nftnl_udata_get_u32);
- 
--struct nftnl_udata *nftnl_udata_next(const struct nftnl_udata *attr)
-+struct nftnl_udata __EXPORTED *nftnl_udata_next(const struct nftnl_udata *attr)
- {
- 	return (struct nftnl_udata *)&attr->value[attr->len];
- }
--EXPORT_SYMBOL(nftnl_udata_next);
- 
--int nftnl_udata_parse(const void *data, uint32_t data_len, nftnl_udata_cb_t cb,
-+int __EXPORTED nftnl_udata_parse(const void *data, uint32_t data_len, nftnl_udata_cb_t cb,
- 		      void *cb_data)
- {
- 	int ret = 0;
-@@ -147,4 +132,3 @@ int nftnl_udata_parse(const void *data, uint32_t data_len, nftnl_udata_cb_t cb,
- 
- 	return ret;
- }
--EXPORT_SYMBOL(nftnl_udata_parse);
--- 
-2.11.0 (Apple Git-81)
-
diff --git a/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl/0001-Move-exports-before-symbol-definition.patch b/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl/0001-Move-exports-before-symbol-definition.patch
new file mode 100644
index 0000000..995fd59
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl/0001-Move-exports-before-symbol-definition.patch
@@ -0,0 +1,289 @@
+From 21eb59fbd071ebffb8495232766824944fb521a0 Mon Sep 17 00:00:00 2001
+From: Alex Kiernan <alex.kiernan@gmail.com>
+Date: Wed, 7 Nov 2018 21:19:53 +0000
+Subject: [PATCH] Move exports before symbol definition
+
+Based on 7966020 ("src: Fix exporting symbols with clang"), when
+EXPORT_SYMBOL is located after function definition, clang won't properly
+export the function, resulting in a library with no symbols when built with
+clang.
+
+Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com>
+---
+ src/flowtable.c | 54 +++++++++++++++++++++++++++---------------------------
+ 1 file changed, 27 insertions(+), 27 deletions(-)
+
+diff --git a/src/flowtable.c b/src/flowtable.c
+index c1ddae4..d7434e3 100644
+--- a/src/flowtable.c
++++ b/src/flowtable.c
+@@ -34,12 +34,13 @@ struct nftnl_flowtable {
+ 	uint32_t		flags;
+ };
+ 
++EXPORT_SYMBOL(nftnl_flowtable_alloc);
+ struct nftnl_flowtable *nftnl_flowtable_alloc(void)
+ {
+ 	return calloc(1, sizeof(struct nftnl_flowtable));
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_alloc);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_free);
+ void nftnl_flowtable_free(const struct nftnl_flowtable *c)
+ {
+ 	int i;
+@@ -56,14 +57,14 @@ void nftnl_flowtable_free(const struct nftnl_flowtable *c)
+ 	}
+ 	xfree(c);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_free);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_is_set);
+ bool nftnl_flowtable_is_set(const struct nftnl_flowtable *c, uint16_t attr)
+ {
+ 	return c->flags & (1 << attr);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_is_set);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_unset);
+ void nftnl_flowtable_unset(struct nftnl_flowtable *c, uint16_t attr)
+ {
+ 	int i;
+@@ -96,7 +97,6 @@ void nftnl_flowtable_unset(struct nftnl_flowtable *c, uint16_t attr)
+ 
+ 	c->flags &= ~(1 << attr);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_unset);
+ 
+ static uint32_t nftnl_flowtable_validate[NFTNL_FLOWTABLE_MAX + 1] = {
+ 	[NFTNL_FLOWTABLE_HOOKNUM]	= sizeof(uint32_t),
+@@ -105,6 +105,7 @@ static uint32_t nftnl_flowtable_validate[NFTNL_FLOWTABLE_MAX + 1] = {
+ 	[NFTNL_FLOWTABLE_FLAGS]		= sizeof(uint32_t),
+ };
+ 
++EXPORT_SYMBOL(nftnl_flowtable_set_data);
+ int nftnl_flowtable_set_data(struct nftnl_flowtable *c, uint16_t attr,
+ 			     const void *data, uint32_t data_len)
+ {
+@@ -170,32 +171,32 @@ int nftnl_flowtable_set_data(struct nftnl_flowtable *c, uint16_t attr,
+ 	c->flags |= (1 << attr);
+ 	return 0;
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_set_data);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_set);
+ void nftnl_flowtable_set(struct nftnl_flowtable *c, uint16_t attr, const void *data)
+ {
+ 	nftnl_flowtable_set_data(c, attr, data, nftnl_flowtable_validate[attr]);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_set);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_set_u32);
+ void nftnl_flowtable_set_u32(struct nftnl_flowtable *c, uint16_t attr, uint32_t data)
+ {
+ 	nftnl_flowtable_set_data(c, attr, &data, sizeof(uint32_t));
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_set_u32);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_set_s32);
+ void nftnl_flowtable_set_s32(struct nftnl_flowtable *c, uint16_t attr, int32_t data)
+ {
+ 	nftnl_flowtable_set_data(c, attr, &data, sizeof(int32_t));
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_set_s32);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_set_str);
+ int nftnl_flowtable_set_str(struct nftnl_flowtable *c, uint16_t attr, const char *str)
+ {
+ 	return nftnl_flowtable_set_data(c, attr, str, strlen(str) + 1);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_set_str);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_get_data);
+ const void *nftnl_flowtable_get_data(const struct nftnl_flowtable *c,
+ 				     uint16_t attr, uint32_t *data_len)
+ {
+@@ -229,21 +230,21 @@ const void *nftnl_flowtable_get_data(const struct nftnl_flowtable *c,
+ 	}
+ 	return NULL;
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_get_data);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_get);
+ const void *nftnl_flowtable_get(const struct nftnl_flowtable *c, uint16_t attr)
+ {
+ 	uint32_t data_len;
+ 	return nftnl_flowtable_get_data(c, attr, &data_len);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_get);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_get_str);
+ const char *nftnl_flowtable_get_str(const struct nftnl_flowtable *c, uint16_t attr)
+ {
+ 	return nftnl_flowtable_get(c, attr);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_get_str);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_get_u32);
+ uint32_t nftnl_flowtable_get_u32(const struct nftnl_flowtable *c, uint16_t attr)
+ {
+ 	uint32_t data_len;
+@@ -253,8 +254,8 @@ uint32_t nftnl_flowtable_get_u32(const struct nftnl_flowtable *c, uint16_t attr)
+ 
+ 	return val ? *val : 0;
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_get_u32);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_get_s32);
+ int32_t nftnl_flowtable_get_s32(const struct nftnl_flowtable *c, uint16_t attr)
+ {
+ 	uint32_t data_len;
+@@ -264,8 +265,8 @@ int32_t nftnl_flowtable_get_s32(const struct nftnl_flowtable *c, uint16_t attr)
+ 
+ 	return val ? *val : 0;
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_get_s32);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_nlmsg_build_payload);
+ void nftnl_flowtable_nlmsg_build_payload(struct nlmsghdr *nlh,
+ 					 const struct nftnl_flowtable *c)
+ {
+@@ -301,7 +302,6 @@ void nftnl_flowtable_nlmsg_build_payload(struct nlmsghdr *nlh,
+ 	if (c->flags & (1 << NFTNL_FLOWTABLE_SIZE))
+ 		mnl_attr_put_u32(nlh, NFTA_FLOWTABLE_SIZE, htonl(c->size));
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_nlmsg_build_payload);
+ 
+ static int nftnl_flowtable_parse_attr_cb(const struct nlattr *attr, void *data)
+ {
+@@ -412,6 +412,7 @@ static int nftnl_flowtable_parse_hook(struct nlattr *attr, struct nftnl_flowtabl
+ 	return 0;
+ }
+ 
++EXPORT_SYMBOL(nftnl_flowtable_nlmsg_parse);
+ int nftnl_flowtable_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_flowtable *c)
+ {
+ 	struct nlattr *tb[NFTA_FLOWTABLE_MAX + 1] = {};
+@@ -460,7 +461,6 @@ int nftnl_flowtable_nlmsg_parse(const struct nlmsghdr *nlh, struct nftnl_flowtab
+ 
+ 	return ret;
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_nlmsg_parse);
+ 
+ static const char *nftnl_hooknum2str(int family, int hooknum)
+ {
+@@ -612,20 +612,20 @@ static int nftnl_flowtable_do_parse(struct nftnl_flowtable *c,
+ 	return ret;
+ }
+ 
++EXPORT_SYMBOL(nftnl_flowtable_parse);
+ int nftnl_flowtable_parse(struct nftnl_flowtable *c, enum nftnl_parse_type type,
+ 			  const char *data, struct nftnl_parse_err *err)
+ {
+ 	return nftnl_flowtable_do_parse(c, type, data, err, NFTNL_PARSE_BUFFER);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_parse);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_parse_file);
+ int nftnl_flowtable_parse_file(struct nftnl_flowtable *c,
+ 			       enum nftnl_parse_type type,
+ 			       FILE *fp, struct nftnl_parse_err *err)
+ {
+ 	return nftnl_flowtable_do_parse(c, type, fp, err, NFTNL_PARSE_FILE);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_parse_file);
+ 
+ static int nftnl_flowtable_export(char *buf, size_t size,
+ 				  const struct nftnl_flowtable *c, int type)
+@@ -720,6 +720,7 @@ static int nftnl_flowtable_cmd_snprintf(char *buf, size_t size,
+ 	return offset;
+ }
+ 
++EXPORT_SYMBOL(nftnl_flowtable_snprintf);
+ int nftnl_flowtable_snprintf(char *buf, size_t size, const struct nftnl_flowtable *c,
+ 			 uint32_t type, uint32_t flags)
+ {
+@@ -729,7 +730,6 @@ int nftnl_flowtable_snprintf(char *buf, size_t size, const struct nftnl_flowtabl
+ 	return nftnl_flowtable_cmd_snprintf(buf, size, c, nftnl_flag2cmd(flags),
+ 					    type, flags);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_snprintf);
+ 
+ static int nftnl_flowtable_do_snprintf(char *buf, size_t size, const void *c,
+ 				   uint32_t cmd, uint32_t type, uint32_t flags)
+@@ -737,18 +737,19 @@ static int nftnl_flowtable_do_snprintf(char *buf, size_t size, const void *c,
+ 	return nftnl_flowtable_snprintf(buf, size, c, type, flags);
+ }
+ 
++EXPORT_SYMBOL(nftnl_flowtable_fprintf);
+ int nftnl_flowtable_fprintf(FILE *fp, const struct nftnl_flowtable *c,
+ 			    uint32_t type, uint32_t flags)
+ {
+ 	return nftnl_fprintf(fp, c, NFTNL_CMD_UNSPEC, type, flags,
+ 			   nftnl_flowtable_do_snprintf);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_fprintf);
+ 
+ struct nftnl_flowtable_list {
+ 	struct list_head list;
+ };
+ 
++EXPORT_SYMBOL(nftnl_flowtable_list_alloc);
+ struct nftnl_flowtable_list *nftnl_flowtable_list_alloc(void)
+ {
+ 	struct nftnl_flowtable_list *list;
+@@ -761,8 +762,8 @@ struct nftnl_flowtable_list *nftnl_flowtable_list_alloc(void)
+ 
+ 	return list;
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_list_alloc);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_list_free);
+ void nftnl_flowtable_list_free(struct nftnl_flowtable_list *list)
+ {
+ 	struct nftnl_flowtable *s, *tmp;
+@@ -773,34 +774,34 @@ void nftnl_flowtable_list_free(struct nftnl_flowtable_list *list)
+ 	}
+ 	xfree(list);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_list_free);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_list_is_empty);
+ int nftnl_flowtable_list_is_empty(const struct nftnl_flowtable_list *list)
+ {
+ 	return list_empty(&list->list);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_list_is_empty);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_list_add);
+ void nftnl_flowtable_list_add(struct nftnl_flowtable *s,
+ 			      struct nftnl_flowtable_list *list)
+ {
+ 	list_add(&s->head, &list->list);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_list_add);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_list_add_tail);
+ void nftnl_flowtable_list_add_tail(struct nftnl_flowtable *s,
+ 				   struct nftnl_flowtable_list *list)
+ {
+ 	list_add_tail(&s->head, &list->list);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_list_add_tail);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_list_del);
+ void nftnl_flowtable_list_del(struct nftnl_flowtable *s)
+ {
+ 	list_del(&s->head);
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_list_del);
+ 
++EXPORT_SYMBOL(nftnl_flowtable_list_foreach);
+ int nftnl_flowtable_list_foreach(struct nftnl_flowtable_list *flowtable_list,
+ 				 int (*cb)(struct nftnl_flowtable *t, void *data), void *data)
+ {
+@@ -814,4 +815,3 @@ int nftnl_flowtable_list_foreach(struct nftnl_flowtable_list *flowtable_list,
+ 	}
+ 	return 0;
+ }
+-EXPORT_SYMBOL(nftnl_flowtable_list_foreach);
diff --git a/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl/0001-avoid-naming-local-function-as-one-of-printf-family.patch b/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl/0001-avoid-naming-local-function-as-one-of-printf-family.patch
deleted file mode 100644
index 06e6817..0000000
--- a/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl/0001-avoid-naming-local-function-as-one-of-printf-family.patch
+++ /dev/null
@@ -1,514 +0,0 @@
-From f840cc0da571d98beb17855c177e9986bd096b72 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 13 Apr 2017 11:46:09 -0700
-Subject: [PATCH] avoid naming local function as one of printf family
-
-Fixes build issues with clang
-error: no member named '__builtin___snprintf_chk' in 'struct expr_ops'
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- include/expr_ops.h   | 2 +-
- include/obj.h        | 2 +-
- src/buffer.c         | 2 +-
- src/expr.c           | 4 ++--
- src/expr/bitwise.c   | 2 +-
- src/expr/byteorder.c | 2 +-
- src/expr/cmp.c       | 2 +-
- src/expr/counter.c   | 2 +-
- src/expr/ct.c        | 2 +-
- src/expr/dup.c       | 2 +-
- src/expr/dynset.c    | 2 +-
- src/expr/exthdr.c    | 2 +-
- src/expr/fib.c       | 2 +-
- src/expr/fwd.c       | 2 +-
- src/expr/hash.c      | 2 +-
- src/expr/immediate.c | 2 +-
- src/expr/limit.c     | 2 +-
- src/expr/log.c       | 2 +-
- src/expr/lookup.c    | 2 +-
- src/expr/masq.c      | 2 +-
- src/expr/match.c     | 2 +-
- src/expr/meta.c      | 2 +-
- src/expr/nat.c       | 2 +-
- src/expr/numgen.c    | 2 +-
- src/expr/objref.c    | 2 +-
- src/expr/payload.c   | 2 +-
- src/expr/queue.c     | 2 +-
- src/expr/quota.c     | 2 +-
- src/expr/range.c     | 2 +-
- src/expr/redir.c     | 2 +-
- src/expr/reject.c    | 2 +-
- src/expr/rt.c        | 2 +-
- src/expr/target.c    | 2 +-
- src/obj/counter.c    | 2 +-
- src/obj/ct_helper.c  | 2 +-
- src/obj/quota.c      | 2 +-
- src/object.c         | 4 ++--
- 37 files changed, 39 insertions(+), 39 deletions(-)
-
-diff --git a/include/expr_ops.h b/include/expr_ops.h
-index e639390..c4fe050 100644
---- a/include/expr_ops.h
-+++ b/include/expr_ops.h
-@@ -18,7 +18,7 @@ struct expr_ops {
- 	const void *(*get)(const struct nftnl_expr *e, uint16_t type, uint32_t *data_len);
- 	int 	(*parse)(struct nftnl_expr *e, struct nlattr *attr);
- 	void	(*build)(struct nlmsghdr *nlh, const struct nftnl_expr *e);
--	int	(*snprintf)(char *buf, size_t len, uint32_t type, uint32_t flags, const struct nftnl_expr *e);
-+	int	(*snprintf_)(char *buf, size_t len, uint32_t type, uint32_t flags, const struct nftnl_expr *e);
- 	int	(*json_parse)(struct nftnl_expr *e, json_t *data,
- 			      struct nftnl_parse_err *err);
- };
-diff --git a/include/obj.h b/include/obj.h
-index d90919f..772caff 100644
---- a/include/obj.h
-+++ b/include/obj.h
-@@ -47,7 +47,7 @@ struct obj_ops {
- 	const void *(*get)(const struct nftnl_obj *e, uint16_t type, uint32_t *data_len);
- 	int	(*parse)(struct nftnl_obj *e, struct nlattr *attr);
- 	void	(*build)(struct nlmsghdr *nlh, const struct nftnl_obj *e);
--	int	(*snprintf)(char *buf, size_t len, uint32_t type, uint32_t flags, const struct nftnl_obj *e);
-+	int	(*snprintf_)(char *buf, size_t len, uint32_t type, uint32_t flags, const struct nftnl_obj *e);
- 	int	(*json_parse)(struct nftnl_obj *e, json_t *data,
- 			      struct nftnl_parse_err *err);
- };
-diff --git a/src/buffer.c b/src/buffer.c
-index f9d5a83..db656e2 100644
---- a/src/buffer.c
-+++ b/src/buffer.c
-@@ -206,7 +206,7 @@ int nftnl_buf_expr(struct nftnl_buf *b, int type, uint32_t flags,
- 	case NFTNL_OUTPUT_JSON:
- 		nftnl_buf_put(b, "{");
- 		nftnl_buf_str(b, type, expr->ops->name, TYPE);
--		ret = expr->ops->snprintf(b->buf + b->off, b->len, type, flags,
-+		ret = expr->ops->snprintf_(b->buf + b->off, b->len, type, flags,
- 					  expr);
- 		if (ret > 0)
- 			nftnl_buf_update(b, ret);
-diff --git a/src/expr.c b/src/expr.c
-index c7eb2b4..24f8f8c 100644
---- a/src/expr.c
-+++ b/src/expr.c
-@@ -265,10 +265,10 @@ int __EXPORTED nftnl_expr_snprintf(char *buf, size_t size, const struct nftnl_ex
- 	int ret;
- 	unsigned int offset = 0, len = size;
- 
--	if (!expr->ops->snprintf)
-+	if (!expr->ops->snprintf_)
- 		return 0;
- 
--	ret = expr->ops->snprintf(buf+offset, len, type, flags, expr);
-+	ret = expr->ops->snprintf_(buf+offset, len, type, flags, expr);
- 	SNPRINTF_BUFFER_SIZE(ret, size, len, offset);
- 
- 	return offset;
-diff --git a/src/expr/bitwise.c b/src/expr/bitwise.c
-index 0febc9d..9b48e79 100644
---- a/src/expr/bitwise.c
-+++ b/src/expr/bitwise.c
-@@ -299,6 +299,6 @@ struct expr_ops expr_ops_bitwise = {
- 	.get		= nftnl_expr_bitwise_get,
- 	.parse		= nftnl_expr_bitwise_parse,
- 	.build		= nftnl_expr_bitwise_build,
--	.snprintf	= nftnl_expr_bitwise_snprintf,
-+	.snprintf_	= nftnl_expr_bitwise_snprintf,
- 	.json_parse	= nftnl_expr_bitwise_json_parse,
- };
-diff --git a/src/expr/byteorder.c b/src/expr/byteorder.c
-index 3805307..079582f 100644
---- a/src/expr/byteorder.c
-+++ b/src/expr/byteorder.c
-@@ -314,6 +314,6 @@ struct expr_ops expr_ops_byteorder = {
- 	.get		= nftnl_expr_byteorder_get,
- 	.parse		= nftnl_expr_byteorder_parse,
- 	.build		= nftnl_expr_byteorder_build,
--	.snprintf	= nftnl_expr_byteorder_snprintf,
-+	.snprintf_	= nftnl_expr_byteorder_snprintf,
- 	.json_parse	= nftnl_expr_byteorder_json_parse,
- };
-diff --git a/src/expr/cmp.c b/src/expr/cmp.c
-index 353e907..99b497c 100644
---- a/src/expr/cmp.c
-+++ b/src/expr/cmp.c
-@@ -284,6 +284,6 @@ struct expr_ops expr_ops_cmp = {
- 	.get		= nftnl_expr_cmp_get,
- 	.parse		= nftnl_expr_cmp_parse,
- 	.build		= nftnl_expr_cmp_build,
--	.snprintf	= nftnl_expr_cmp_snprintf,
-+	.snprintf_	= nftnl_expr_cmp_snprintf,
- 	.json_parse	= nftnl_expr_cmp_json_parse,
- };
-diff --git a/src/expr/counter.c b/src/expr/counter.c
-index 21901e8..9fd7655 100644
---- a/src/expr/counter.c
-+++ b/src/expr/counter.c
-@@ -200,6 +200,6 @@ struct expr_ops expr_ops_counter = {
- 	.get		= nftnl_expr_counter_get,
- 	.parse		= nftnl_expr_counter_parse,
- 	.build		= nftnl_expr_counter_build,
--	.snprintf	= nftnl_expr_counter_snprintf,
-+	.snprintf_	= nftnl_expr_counter_snprintf,
- 	.json_parse	= nftnl_expr_counter_json_parse,
- };
-diff --git a/src/expr/ct.c b/src/expr/ct.c
-index cdd08e9..6ce5478 100644
---- a/src/expr/ct.c
-+++ b/src/expr/ct.c
-@@ -356,6 +356,6 @@ struct expr_ops expr_ops_ct = {
- 	.get		= nftnl_expr_ct_get,
- 	.parse		= nftnl_expr_ct_parse,
- 	.build		= nftnl_expr_ct_build,
--	.snprintf	= nftnl_expr_ct_snprintf,
-+	.snprintf_	= nftnl_expr_ct_snprintf,
- 	.json_parse	= nftnl_expr_ct_json_parse,
- };
-diff --git a/src/expr/dup.c b/src/expr/dup.c
-index 9aa332b..2f491d8 100644
---- a/src/expr/dup.c
-+++ b/src/expr/dup.c
-@@ -206,6 +206,6 @@ struct expr_ops expr_ops_dup = {
- 	.get		= nftnl_expr_dup_get,
- 	.parse		= nftnl_expr_dup_parse,
- 	.build		= nftnl_expr_dup_build,
--	.snprintf	= nftnl_expr_dup_snprintf,
-+	.snprintf_	= nftnl_expr_dup_snprintf,
- 	.json_parse	= nftnl_expr_dup_json_parse,
- };
-diff --git a/src/expr/dynset.c b/src/expr/dynset.c
-index f7b99ea..758f07c 100644
---- a/src/expr/dynset.c
-+++ b/src/expr/dynset.c
-@@ -368,6 +368,6 @@ struct expr_ops expr_ops_dynset = {
- 	.get		= nftnl_expr_dynset_get,
- 	.parse		= nftnl_expr_dynset_parse,
- 	.build		= nftnl_expr_dynset_build,
--	.snprintf	= nftnl_expr_dynset_snprintf,
-+	.snprintf_	= nftnl_expr_dynset_snprintf,
- 	.json_parse	= nftnl_expr_dynset_json_parse,
- };
-diff --git a/src/expr/exthdr.c b/src/expr/exthdr.c
-index d4f1665..a834782 100644
---- a/src/expr/exthdr.c
-+++ b/src/expr/exthdr.c
-@@ -356,6 +356,6 @@ struct expr_ops expr_ops_exthdr = {
- 	.get		= nftnl_expr_exthdr_get,
- 	.parse		= nftnl_expr_exthdr_parse,
- 	.build		= nftnl_expr_exthdr_build,
--	.snprintf	= nftnl_expr_exthdr_snprintf,
-+	.snprintf_	= nftnl_expr_exthdr_snprintf,
- 	.json_parse	= nftnl_expr_exthdr_json_parse,
- };
-diff --git a/src/expr/fib.c b/src/expr/fib.c
-index f3be081..3c353b2 100644
---- a/src/expr/fib.c
-+++ b/src/expr/fib.c
-@@ -272,6 +272,6 @@ struct expr_ops expr_ops_fib = {
- 	.get		= nftnl_expr_fib_get,
- 	.parse		= nftnl_expr_fib_parse,
- 	.build		= nftnl_expr_fib_build,
--	.snprintf	= nftnl_expr_fib_snprintf,
-+	.snprintf_	= nftnl_expr_fib_snprintf,
- 	.json_parse	= nftnl_expr_fib_json_parse,
- };
-diff --git a/src/expr/fwd.c b/src/expr/fwd.c
-index c30d494..f6e41f1 100644
---- a/src/expr/fwd.c
-+++ b/src/expr/fwd.c
-@@ -180,6 +180,6 @@ struct expr_ops expr_ops_fwd = {
- 	.get		= nftnl_expr_fwd_get,
- 	.parse		= nftnl_expr_fwd_parse,
- 	.build		= nftnl_expr_fwd_build,
--	.snprintf	= nftnl_expr_fwd_snprintf,
-+	.snprintf_	= nftnl_expr_fwd_snprintf,
- 	.json_parse	= nftnl_expr_fwd_json_parse,
- };
-diff --git a/src/expr/hash.c b/src/expr/hash.c
-index d870510..5acb66a 100644
---- a/src/expr/hash.c
-+++ b/src/expr/hash.c
-@@ -332,6 +332,6 @@ struct expr_ops expr_ops_hash = {
- 	.get		= nftnl_expr_hash_get,
- 	.parse		= nftnl_expr_hash_parse,
- 	.build		= nftnl_expr_hash_build,
--	.snprintf	= nftnl_expr_hash_snprintf,
-+	.snprintf_	= nftnl_expr_hash_snprintf,
- 	.json_parse	= nftnl_expr_hash_json_parse,
- };
-diff --git a/src/expr/immediate.c b/src/expr/immediate.c
-index 0b188cc..94bd6da 100644
---- a/src/expr/immediate.c
-+++ b/src/expr/immediate.c
-@@ -316,6 +316,6 @@ struct expr_ops expr_ops_immediate = {
- 	.get		= nftnl_expr_immediate_get,
- 	.parse		= nftnl_expr_immediate_parse,
- 	.build		= nftnl_expr_immediate_build,
--	.snprintf	= nftnl_expr_immediate_snprintf,
-+	.snprintf_	= nftnl_expr_immediate_snprintf,
- 	.json_parse	= nftnl_expr_immediate_json_parse,
- };
-diff --git a/src/expr/limit.c b/src/expr/limit.c
-index 856ab18..e71fc2f 100644
---- a/src/expr/limit.c
-+++ b/src/expr/limit.c
-@@ -285,6 +285,6 @@ struct expr_ops expr_ops_limit = {
- 	.get		= nftnl_expr_limit_get,
- 	.parse		= nftnl_expr_limit_parse,
- 	.build		= nftnl_expr_limit_build,
--	.snprintf	= nftnl_expr_limit_snprintf,
-+	.snprintf_	= nftnl_expr_limit_snprintf,
- 	.json_parse	= nftnl_expr_limit_json_parse,
- };
-diff --git a/src/expr/log.c b/src/expr/log.c
-index b642255..71dd83a 100644
---- a/src/expr/log.c
-+++ b/src/expr/log.c
-@@ -352,6 +352,6 @@ struct expr_ops expr_ops_log = {
- 	.get		= nftnl_expr_log_get,
- 	.parse		= nftnl_expr_log_parse,
- 	.build		= nftnl_expr_log_build,
--	.snprintf	= nftnl_expr_log_snprintf,
-+	.snprintf_	= nftnl_expr_log_snprintf,
- 	.json_parse	= nftnl_expr_log_json_parse,
- };
-diff --git a/src/expr/lookup.c b/src/expr/lookup.c
-index 861815f..6049913 100644
---- a/src/expr/lookup.c
-+++ b/src/expr/lookup.c
-@@ -293,6 +293,6 @@ struct expr_ops expr_ops_lookup = {
- 	.get		= nftnl_expr_lookup_get,
- 	.parse		= nftnl_expr_lookup_parse,
- 	.build		= nftnl_expr_lookup_build,
--	.snprintf	= nftnl_expr_lookup_snprintf,
-+	.snprintf_	= nftnl_expr_lookup_snprintf,
- 	.json_parse	= nftnl_expr_lookup_json_parse,
- };
-diff --git a/src/expr/masq.c b/src/expr/masq.c
-index 7c235d3..adec325 100644
---- a/src/expr/masq.c
-+++ b/src/expr/masq.c
-@@ -228,6 +228,6 @@ struct expr_ops expr_ops_masq = {
- 	.get		= nftnl_expr_masq_get,
- 	.parse		= nftnl_expr_masq_parse,
- 	.build		= nftnl_expr_masq_build,
--	.snprintf	= nftnl_expr_masq_snprintf,
-+	.snprintf_	= nftnl_expr_masq_snprintf,
- 	.json_parse	= nftnl_expr_masq_json_parse,
- };
-diff --git a/src/expr/match.c b/src/expr/match.c
-index dd09e1e..f0d8868 100644
---- a/src/expr/match.c
-+++ b/src/expr/match.c
-@@ -249,6 +249,6 @@ struct expr_ops expr_ops_match = {
- 	.get		= nftnl_expr_match_get,
- 	.parse		= nftnl_expr_match_parse,
- 	.build		= nftnl_expr_match_build,
--	.snprintf	= nftnl_expr_match_snprintf,
-+	.snprintf_	= nftnl_expr_match_snprintf,
- 	.json_parse 	= nftnl_expr_match_json_parse,
- };
-diff --git a/src/expr/meta.c b/src/expr/meta.c
-index 2c75841..907a677 100644
---- a/src/expr/meta.c
-+++ b/src/expr/meta.c
-@@ -290,6 +290,6 @@ struct expr_ops expr_ops_meta = {
- 	.get		= nftnl_expr_meta_get,
- 	.parse		= nftnl_expr_meta_parse,
- 	.build		= nftnl_expr_meta_build,
--	.snprintf	= nftnl_expr_meta_snprintf,
-+	.snprintf_	= nftnl_expr_meta_snprintf,
- 	.json_parse 	= nftnl_expr_meta_json_parse,
- };
-diff --git a/src/expr/nat.c b/src/expr/nat.c
-index 29bc3a2..d476283 100644
---- a/src/expr/nat.c
-+++ b/src/expr/nat.c
-@@ -383,6 +383,6 @@ struct expr_ops expr_ops_nat = {
- 	.get		= nftnl_expr_nat_get,
- 	.parse		= nftnl_expr_nat_parse,
- 	.build		= nftnl_expr_nat_build,
--	.snprintf	= nftnl_expr_nat_snprintf,
-+	.snprintf_	= nftnl_expr_nat_snprintf,
- 	.json_parse	= nftnl_expr_nat_json_parse,
- };
-diff --git a/src/expr/numgen.c b/src/expr/numgen.c
-index a15f03a..28ef741 100644
---- a/src/expr/numgen.c
-+++ b/src/expr/numgen.c
-@@ -264,6 +264,6 @@ struct expr_ops expr_ops_ng = {
- 	.get		= nftnl_expr_ng_get,
- 	.parse		= nftnl_expr_ng_parse,
- 	.build		= nftnl_expr_ng_build,
--	.snprintf	= nftnl_expr_ng_snprintf,
-+	.snprintf_	= nftnl_expr_ng_snprintf,
- 	.json_parse	= nftnl_expr_ng_json_parse,
- };
-diff --git a/src/expr/objref.c b/src/expr/objref.c
-index 4cfa3cb..c394290 100644
---- a/src/expr/objref.c
-+++ b/src/expr/objref.c
-@@ -278,6 +278,6 @@ struct expr_ops expr_ops_objref = {
- 	.get		= nftnl_expr_objref_get,
- 	.parse		= nftnl_expr_objref_parse,
- 	.build		= nftnl_expr_objref_build,
--	.snprintf	= nftnl_expr_objref_snprintf,
-+	.snprintf_	= nftnl_expr_objref_snprintf,
- 	.json_parse	= nftnl_expr_objref_json_parse,
- };
-diff --git a/src/expr/payload.c b/src/expr/payload.c
-index 91e1587..894ac08 100644
---- a/src/expr/payload.c
-+++ b/src/expr/payload.c
-@@ -348,6 +348,6 @@ struct expr_ops expr_ops_payload = {
- 	.get		= nftnl_expr_payload_get,
- 	.parse		= nftnl_expr_payload_parse,
- 	.build		= nftnl_expr_payload_build,
--	.snprintf	= nftnl_expr_payload_snprintf,
-+	.snprintf_	= nftnl_expr_payload_snprintf,
- 	.json_parse	= nftnl_expr_payload_json_parse,
- };
-diff --git a/src/expr/queue.c b/src/expr/queue.c
-index 8a9deda..389af83 100644
---- a/src/expr/queue.c
-+++ b/src/expr/queue.c
-@@ -276,6 +276,6 @@ struct expr_ops expr_ops_queue = {
- 	.get		= nftnl_expr_queue_get,
- 	.parse		= nftnl_expr_queue_parse,
- 	.build		= nftnl_expr_queue_build,
--	.snprintf	= nftnl_expr_queue_snprintf,
-+	.snprintf_	= nftnl_expr_queue_snprintf,
- 	.json_parse	= nftnl_expr_queue_json_parse,
- };
-diff --git a/src/expr/quota.c b/src/expr/quota.c
-index 667e6e1..ff5d182 100644
---- a/src/expr/quota.c
-+++ b/src/expr/quota.c
-@@ -203,6 +203,6 @@ struct expr_ops expr_ops_quota = {
- 	.get		= nftnl_expr_quota_get,
- 	.parse		= nftnl_expr_quota_parse,
- 	.build		= nftnl_expr_quota_build,
--	.snprintf	= nftnl_expr_quota_snprintf,
-+	.snprintf_	= nftnl_expr_quota_snprintf,
- 	.json_parse	= nftnl_expr_quota_json_parse,
- };
-diff --git a/src/expr/range.c b/src/expr/range.c
-index 8c8ce12..34d422b 100644
---- a/src/expr/range.c
-+++ b/src/expr/range.c
-@@ -283,6 +283,6 @@ struct expr_ops expr_ops_range = {
- 	.get		= nftnl_expr_range_get,
- 	.parse		= nftnl_expr_range_parse,
- 	.build		= nftnl_expr_range_build,
--	.snprintf	= nftnl_expr_range_snprintf,
-+	.snprintf_	= nftnl_expr_range_snprintf,
- 	.json_parse	= nftnl_expr_range_json_parse,
- };
-diff --git a/src/expr/redir.c b/src/expr/redir.c
-index 43538d5..8a21f93 100644
---- a/src/expr/redir.c
-+++ b/src/expr/redir.c
-@@ -242,6 +242,6 @@ struct expr_ops expr_ops_redir = {
- 	.get		= nftnl_expr_redir_get,
- 	.parse		= nftnl_expr_redir_parse,
- 	.build		= nftnl_expr_redir_build,
--	.snprintf	= nftnl_expr_redir_snprintf,
-+	.snprintf_	= nftnl_expr_redir_snprintf,
- 	.json_parse	= nftnl_expr_redir_json_parse,
- };
-diff --git a/src/expr/reject.c b/src/expr/reject.c
-index 11d8b20..b10e729 100644
---- a/src/expr/reject.c
-+++ b/src/expr/reject.c
-@@ -200,6 +200,6 @@ struct expr_ops expr_ops_reject = {
- 	.get		= nftnl_expr_reject_get,
- 	.parse		= nftnl_expr_reject_parse,
- 	.build		= nftnl_expr_reject_build,
--	.snprintf	= nftnl_expr_reject_snprintf,
-+	.snprintf_	= nftnl_expr_reject_snprintf,
- 	.json_parse	= nftnl_expr_reject_json_parse,
- };
-diff --git a/src/expr/rt.c b/src/expr/rt.c
-index 5088e66..9f44b29 100644
---- a/src/expr/rt.c
-+++ b/src/expr/rt.c
-@@ -238,6 +238,6 @@ struct expr_ops expr_ops_rt = {
- 	.get		= nftnl_expr_rt_get,
- 	.parse		= nftnl_expr_rt_parse,
- 	.build		= nftnl_expr_rt_build,
--	.snprintf	= nftnl_expr_rt_snprintf,
-+	.snprintf_	= nftnl_expr_rt_snprintf,
- 	.json_parse	= nftnl_expr_rt_json_parse,
- };
-diff --git a/src/expr/target.c b/src/expr/target.c
-index ed4bf7d..2ef4078 100644
---- a/src/expr/target.c
-+++ b/src/expr/target.c
-@@ -249,6 +249,6 @@ struct expr_ops expr_ops_target = {
- 	.get		= nftnl_expr_target_get,
- 	.parse		= nftnl_expr_target_parse,
- 	.build		= nftnl_expr_target_build,
--	.snprintf	= nftnl_expr_target_snprintf,
-+	.snprintf_	= nftnl_expr_target_snprintf,
- 	.json_parse	= nftnl_expr_target_json_parse,
- };
-diff --git a/src/obj/counter.c b/src/obj/counter.c
-index beadc93..8c4cc25 100644
---- a/src/obj/counter.c
-+++ b/src/obj/counter.c
-@@ -179,6 +179,6 @@ struct obj_ops obj_ops_counter = {
- 	.get		= nftnl_obj_counter_get,
- 	.parse		= nftnl_obj_counter_parse,
- 	.build		= nftnl_obj_counter_build,
--	.snprintf	= nftnl_obj_counter_snprintf,
-+	.snprintf_	= nftnl_obj_counter_snprintf,
- 	.json_parse	= nftnl_obj_counter_json_parse,
- };
-diff --git a/src/obj/ct_helper.c b/src/obj/ct_helper.c
-index d6d3111..4c7c88b 100644
---- a/src/obj/ct_helper.c
-+++ b/src/obj/ct_helper.c
-@@ -205,6 +205,6 @@ struct obj_ops obj_ops_ct_helper = {
- 	.get		= nftnl_obj_ct_helper_get,
- 	.parse		= nftnl_obj_ct_helper_parse,
- 	.build		= nftnl_obj_ct_helper_build,
--	.snprintf	= nftnl_obj_ct_helper_snprintf,
-+	.snprintf_	= nftnl_obj_ct_helper_snprintf,
- 	.json_parse	= nftnl_obj_quota_json_parse,
- };
-diff --git a/src/obj/quota.c b/src/obj/quota.c
-index d5757b2..e959ff8 100644
---- a/src/obj/quota.c
-+++ b/src/obj/quota.c
-@@ -200,6 +200,6 @@ struct obj_ops obj_ops_quota = {
- 	.get		= nftnl_obj_quota_get,
- 	.parse		= nftnl_obj_quota_parse,
- 	.build		= nftnl_obj_quota_build,
--	.snprintf	= nftnl_obj_quota_snprintf,
-+	.snprintf_	= nftnl_obj_quota_snprintf,
- 	.json_parse	= nftnl_obj_quota_json_parse,
- };
-diff --git a/src/object.c b/src/object.c
-index d409c6d..b938c97 100644
---- a/src/object.c
-+++ b/src/object.c
-@@ -389,7 +389,7 @@ static int nftnl_obj_export(char *buf, size_t size,
- 		nftnl_buf_u32(&b, type, obj->use, USE);
- 
- 	if (obj->ops)
--		ret = obj->ops->snprintf(buf + b.len, size - b.len, type,
-+		ret = obj->ops->snprintf_(buf + b.len, size - b.len, type,
- 					 flags, obj);
- 
- 	b.len += ret;
-@@ -410,7 +410,7 @@ static int nftnl_obj_snprintf_dflt(char *buf, size_t size,
- 	SNPRINTF_BUFFER_SIZE(ret, size, len, offset);
- 
- 	if (obj->ops) {
--		ret = obj->ops->snprintf(buf + offset, offset, type, flags, obj);
-+		ret = obj->ops->snprintf_(buf + offset, offset, type, flags, obj);
- 		SNPRINTF_BUFFER_SIZE(ret, size, len, offset);
- 	}
- 	ret = snprintf(buf + offset, offset, "]");
--- 
-2.12.2
-
diff --git a/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl/0002-avoid-naming-local-function-as-one-of-printf-family.patch b/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl/0002-avoid-naming-local-function-as-one-of-printf-family.patch
new file mode 100644
index 0000000..e7e8f6f
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl/0002-avoid-naming-local-function-as-one-of-printf-family.patch
@@ -0,0 +1,549 @@
+From 5ea9fa9d345005f2f53b1b598edb85f5f24ca9da Mon Sep 17 00:00:00 2001
+From: Alex Kiernan <alex.kiernan@gmail.com>
+Date: Wed, 7 Nov 2018 19:41:54 +0000
+Subject: [PATCH] avoid naming local function as one of printf family
+
+Fixes build issues with clang
+error: no member named '__builtin___snprintf_chk' in 'struct expr_ops'
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com>
+---
+ include/expr_ops.h      | 2 +-
+ include/obj.h           | 2 +-
+ src/expr.c              | 4 ++--
+ src/expr/bitwise.c      | 2 +-
+ src/expr/byteorder.c    | 2 +-
+ src/expr/cmp.c          | 2 +-
+ src/expr/connlimit.c    | 2 +-
+ src/expr/counter.c      | 2 +-
+ src/expr/ct.c           | 2 +-
+ src/expr/dup.c          | 2 +-
+ src/expr/dynset.c       | 2 +-
+ src/expr/exthdr.c       | 2 +-
+ src/expr/fib.c          | 2 +-
+ src/expr/flow_offload.c | 2 +-
+ src/expr/fwd.c          | 2 +-
+ src/expr/hash.c         | 2 +-
+ src/expr/immediate.c    | 2 +-
+ src/expr/limit.c        | 2 +-
+ src/expr/log.c          | 2 +-
+ src/expr/lookup.c       | 2 +-
+ src/expr/masq.c         | 2 +-
+ src/expr/match.c        | 2 +-
+ src/expr/meta.c         | 2 +-
+ src/expr/nat.c          | 2 +-
+ src/expr/numgen.c       | 2 +-
+ src/expr/objref.c       | 2 +-
+ src/expr/payload.c      | 2 +-
+ src/expr/queue.c        | 2 +-
+ src/expr/quota.c        | 2 +-
+ src/expr/range.c        | 2 +-
+ src/expr/redir.c        | 2 +-
+ src/expr/reject.c       | 2 +-
+ src/expr/rt.c           | 2 +-
+ src/expr/socket.c       | 2 +-
+ src/expr/target.c       | 2 +-
+ src/obj/counter.c       | 2 +-
+ src/obj/ct_helper.c     | 2 +-
+ src/obj/limit.c         | 2 +-
+ src/obj/quota.c         | 2 +-
+ src/object.c            | 4 ++--
+ 40 files changed, 42 insertions(+), 42 deletions(-)
+
+diff --git a/include/expr_ops.h b/include/expr_ops.h
+index e639390..c4fe050 100644
+--- a/include/expr_ops.h
++++ b/include/expr_ops.h
+@@ -18,7 +18,7 @@ struct expr_ops {
+ 	const void *(*get)(const struct nftnl_expr *e, uint16_t type, uint32_t *data_len);
+ 	int 	(*parse)(struct nftnl_expr *e, struct nlattr *attr);
+ 	void	(*build)(struct nlmsghdr *nlh, const struct nftnl_expr *e);
+-	int	(*snprintf)(char *buf, size_t len, uint32_t type, uint32_t flags, const struct nftnl_expr *e);
++	int	(*snprintf_)(char *buf, size_t len, uint32_t type, uint32_t flags, const struct nftnl_expr *e);
+ 	int	(*json_parse)(struct nftnl_expr *e, json_t *data,
+ 			      struct nftnl_parse_err *err);
+ };
+diff --git a/include/obj.h b/include/obj.h
+index 4a728c8..4c20bd1 100644
+--- a/include/obj.h
++++ b/include/obj.h
+@@ -55,7 +55,7 @@ struct obj_ops {
+ 	const void *(*get)(const struct nftnl_obj *e, uint16_t type, uint32_t *data_len);
+ 	int	(*parse)(struct nftnl_obj *e, struct nlattr *attr);
+ 	void	(*build)(struct nlmsghdr *nlh, const struct nftnl_obj *e);
+-	int	(*snprintf)(char *buf, size_t len, uint32_t type, uint32_t flags, const struct nftnl_obj *e);
++	int	(*snprintf_)(char *buf, size_t len, uint32_t type, uint32_t flags, const struct nftnl_obj *e);
+ 	int	(*json_parse)(struct nftnl_obj *e, json_t *data,
+ 			      struct nftnl_parse_err *err);
+ };
+diff --git a/src/expr.c b/src/expr.c
+index 62565e0..2489c30 100644
+--- a/src/expr.c
++++ b/src/expr.c
+@@ -285,10 +285,10 @@ int nftnl_expr_snprintf(char *buf, size_t size, const struct nftnl_expr *expr,
+ 	if (size)
+ 		buf[0] = '\0';
+ 
+-	if (!expr->ops->snprintf)
++	if (!expr->ops->snprintf_)
+ 		return 0;
+ 
+-	ret = expr->ops->snprintf(buf + offset, remain, type, flags, expr);
++	ret = expr->ops->snprintf_(buf + offset, remain, type, flags, expr);
+ 	SNPRINTF_BUFFER_SIZE(ret, remain, offset);
+ 
+ 	return offset;
+diff --git a/src/expr/bitwise.c b/src/expr/bitwise.c
+index a89734b..f8360b1 100644
+--- a/src/expr/bitwise.c
++++ b/src/expr/bitwise.c
+@@ -299,6 +299,6 @@ struct expr_ops expr_ops_bitwise = {
+ 	.get		= nftnl_expr_bitwise_get,
+ 	.parse		= nftnl_expr_bitwise_parse,
+ 	.build		= nftnl_expr_bitwise_build,
+-	.snprintf	= nftnl_expr_bitwise_snprintf,
++	.snprintf_	= nftnl_expr_bitwise_snprintf,
+ 	.json_parse	= nftnl_expr_bitwise_json_parse,
+ };
+diff --git a/src/expr/byteorder.c b/src/expr/byteorder.c
+index 47c04cf..61f733f 100644
+--- a/src/expr/byteorder.c
++++ b/src/expr/byteorder.c
+@@ -314,6 +314,6 @@ struct expr_ops expr_ops_byteorder = {
+ 	.get		= nftnl_expr_byteorder_get,
+ 	.parse		= nftnl_expr_byteorder_parse,
+ 	.build		= nftnl_expr_byteorder_build,
+-	.snprintf	= nftnl_expr_byteorder_snprintf,
++	.snprintf_	= nftnl_expr_byteorder_snprintf,
+ 	.json_parse	= nftnl_expr_byteorder_json_parse,
+ };
+diff --git a/src/expr/cmp.c b/src/expr/cmp.c
+index b26d0eb..522c7be 100644
+--- a/src/expr/cmp.c
++++ b/src/expr/cmp.c
+@@ -284,6 +284,6 @@ struct expr_ops expr_ops_cmp = {
+ 	.get		= nftnl_expr_cmp_get,
+ 	.parse		= nftnl_expr_cmp_parse,
+ 	.build		= nftnl_expr_cmp_build,
+-	.snprintf	= nftnl_expr_cmp_snprintf,
++	.snprintf_	= nftnl_expr_cmp_snprintf,
+ 	.json_parse	= nftnl_expr_cmp_json_parse,
+ };
+diff --git a/src/expr/connlimit.c b/src/expr/connlimit.c
+index 60965b5..4e41866 100644
+--- a/src/expr/connlimit.c
++++ b/src/expr/connlimit.c
+@@ -202,6 +202,6 @@ struct expr_ops expr_ops_connlimit = {
+ 	.get		= nftnl_expr_connlimit_get,
+ 	.parse		= nftnl_expr_connlimit_parse,
+ 	.build		= nftnl_expr_connlimit_build,
+-	.snprintf	= nftnl_expr_connlimit_snprintf,
++	.snprintf_	= nftnl_expr_connlimit_snprintf,
+ 	.json_parse	= nftnl_expr_connlimit_json_parse,
+ };
+diff --git a/src/expr/counter.c b/src/expr/counter.c
+index 21901e8..9fd7655 100644
+--- a/src/expr/counter.c
++++ b/src/expr/counter.c
+@@ -200,6 +200,6 @@ struct expr_ops expr_ops_counter = {
+ 	.get		= nftnl_expr_counter_get,
+ 	.parse		= nftnl_expr_counter_parse,
+ 	.build		= nftnl_expr_counter_build,
+-	.snprintf	= nftnl_expr_counter_snprintf,
++	.snprintf_	= nftnl_expr_counter_snprintf,
+ 	.json_parse	= nftnl_expr_counter_json_parse,
+ };
+diff --git a/src/expr/ct.c b/src/expr/ct.c
+index 39e9be6..b363f7c 100644
+--- a/src/expr/ct.c
++++ b/src/expr/ct.c
+@@ -357,6 +357,6 @@ struct expr_ops expr_ops_ct = {
+ 	.get		= nftnl_expr_ct_get,
+ 	.parse		= nftnl_expr_ct_parse,
+ 	.build		= nftnl_expr_ct_build,
+-	.snprintf	= nftnl_expr_ct_snprintf,
++	.snprintf_	= nftnl_expr_ct_snprintf,
+ 	.json_parse	= nftnl_expr_ct_json_parse,
+ };
+diff --git a/src/expr/dup.c b/src/expr/dup.c
+index ed8e620..8d603e3 100644
+--- a/src/expr/dup.c
++++ b/src/expr/dup.c
+@@ -206,6 +206,6 @@ struct expr_ops expr_ops_dup = {
+ 	.get		= nftnl_expr_dup_get,
+ 	.parse		= nftnl_expr_dup_parse,
+ 	.build		= nftnl_expr_dup_build,
+-	.snprintf	= nftnl_expr_dup_snprintf,
++	.snprintf_	= nftnl_expr_dup_snprintf,
+ 	.json_parse	= nftnl_expr_dup_json_parse,
+ };
+diff --git a/src/expr/dynset.c b/src/expr/dynset.c
+index 160d0e1..a43f4da 100644
+--- a/src/expr/dynset.c
++++ b/src/expr/dynset.c
+@@ -368,6 +368,6 @@ struct expr_ops expr_ops_dynset = {
+ 	.get		= nftnl_expr_dynset_get,
+ 	.parse		= nftnl_expr_dynset_parse,
+ 	.build		= nftnl_expr_dynset_build,
+-	.snprintf	= nftnl_expr_dynset_snprintf,
++	.snprintf_	= nftnl_expr_dynset_snprintf,
+ 	.json_parse	= nftnl_expr_dynset_json_parse,
+ };
+diff --git a/src/expr/exthdr.c b/src/expr/exthdr.c
+index 75cafbc..89ea7f5 100644
+--- a/src/expr/exthdr.c
++++ b/src/expr/exthdr.c
+@@ -385,6 +385,6 @@ struct expr_ops expr_ops_exthdr = {
+ 	.get		= nftnl_expr_exthdr_get,
+ 	.parse		= nftnl_expr_exthdr_parse,
+ 	.build		= nftnl_expr_exthdr_build,
+-	.snprintf	= nftnl_expr_exthdr_snprintf,
++	.snprintf_	= nftnl_expr_exthdr_snprintf,
+ 	.json_parse	= nftnl_expr_exthdr_json_parse,
+ };
+diff --git a/src/expr/fib.c b/src/expr/fib.c
+index b922b26..ece4645 100644
+--- a/src/expr/fib.c
++++ b/src/expr/fib.c
+@@ -274,6 +274,6 @@ struct expr_ops expr_ops_fib = {
+ 	.get		= nftnl_expr_fib_get,
+ 	.parse		= nftnl_expr_fib_parse,
+ 	.build		= nftnl_expr_fib_build,
+-	.snprintf	= nftnl_expr_fib_snprintf,
++	.snprintf_	= nftnl_expr_fib_snprintf,
+ 	.json_parse	= nftnl_expr_fib_json_parse,
+ };
+diff --git a/src/expr/flow_offload.c b/src/expr/flow_offload.c
+index a2001c9..9cdbc21 100644
+--- a/src/expr/flow_offload.c
++++ b/src/expr/flow_offload.c
+@@ -179,6 +179,6 @@ struct expr_ops expr_ops_flow = {
+ 	.get		= nftnl_expr_flow_get,
+ 	.parse		= nftnl_expr_flow_parse,
+ 	.build		= nftnl_expr_flow_build,
+-	.snprintf	= nftnl_expr_flow_snprintf,
++	.snprintf_	= nftnl_expr_flow_snprintf,
+ 	.json_parse	= nftnl_expr_flow_json_parse,
+ };
+diff --git a/src/expr/fwd.c b/src/expr/fwd.c
+index 9021606..7178f43 100644
+--- a/src/expr/fwd.c
++++ b/src/expr/fwd.c
+@@ -233,6 +233,6 @@ struct expr_ops expr_ops_fwd = {
+ 	.get		= nftnl_expr_fwd_get,
+ 	.parse		= nftnl_expr_fwd_parse,
+ 	.build		= nftnl_expr_fwd_build,
+-	.snprintf	= nftnl_expr_fwd_snprintf,
++	.snprintf_	= nftnl_expr_fwd_snprintf,
+ 	.json_parse	= nftnl_expr_fwd_json_parse,
+ };
+diff --git a/src/expr/hash.c b/src/expr/hash.c
+index 415537e..186c5b0 100644
+--- a/src/expr/hash.c
++++ b/src/expr/hash.c
+@@ -383,6 +383,6 @@ struct expr_ops expr_ops_hash = {
+ 	.get		= nftnl_expr_hash_get,
+ 	.parse		= nftnl_expr_hash_parse,
+ 	.build		= nftnl_expr_hash_build,
+-	.snprintf	= nftnl_expr_hash_snprintf,
++	.snprintf_	= nftnl_expr_hash_snprintf,
+ 	.json_parse	= nftnl_expr_hash_json_parse,
+ };
+diff --git a/src/expr/immediate.c b/src/expr/immediate.c
+index b0570bd..91ccbdc 100644
+--- a/src/expr/immediate.c
++++ b/src/expr/immediate.c
+@@ -316,6 +316,6 @@ struct expr_ops expr_ops_immediate = {
+ 	.get		= nftnl_expr_immediate_get,
+ 	.parse		= nftnl_expr_immediate_parse,
+ 	.build		= nftnl_expr_immediate_build,
+-	.snprintf	= nftnl_expr_immediate_snprintf,
++	.snprintf_	= nftnl_expr_immediate_snprintf,
+ 	.json_parse	= nftnl_expr_immediate_json_parse,
+ };
+diff --git a/src/expr/limit.c b/src/expr/limit.c
+index 856ab18..e71fc2f 100644
+--- a/src/expr/limit.c
++++ b/src/expr/limit.c
+@@ -285,6 +285,6 @@ struct expr_ops expr_ops_limit = {
+ 	.get		= nftnl_expr_limit_get,
+ 	.parse		= nftnl_expr_limit_parse,
+ 	.build		= nftnl_expr_limit_build,
+-	.snprintf	= nftnl_expr_limit_snprintf,
++	.snprintf_	= nftnl_expr_limit_snprintf,
+ 	.json_parse	= nftnl_expr_limit_json_parse,
+ };
+diff --git a/src/expr/log.c b/src/expr/log.c
+index 86d9651..5769c1c 100644
+--- a/src/expr/log.c
++++ b/src/expr/log.c
+@@ -353,6 +353,6 @@ struct expr_ops expr_ops_log = {
+ 	.get		= nftnl_expr_log_get,
+ 	.parse		= nftnl_expr_log_parse,
+ 	.build		= nftnl_expr_log_build,
+-	.snprintf	= nftnl_expr_log_snprintf,
++	.snprintf_	= nftnl_expr_log_snprintf,
+ 	.json_parse	= nftnl_expr_log_json_parse,
+ };
+diff --git a/src/expr/lookup.c b/src/expr/lookup.c
+index 5fcb81f..b2f0dd6 100644
+--- a/src/expr/lookup.c
++++ b/src/expr/lookup.c
+@@ -292,6 +292,6 @@ struct expr_ops expr_ops_lookup = {
+ 	.get		= nftnl_expr_lookup_get,
+ 	.parse		= nftnl_expr_lookup_parse,
+ 	.build		= nftnl_expr_lookup_build,
+-	.snprintf	= nftnl_expr_lookup_snprintf,
++	.snprintf_	= nftnl_expr_lookup_snprintf,
+ 	.json_parse	= nftnl_expr_lookup_json_parse,
+ };
+diff --git a/src/expr/masq.c b/src/expr/masq.c
+index 7c235d3..adec325 100644
+--- a/src/expr/masq.c
++++ b/src/expr/masq.c
+@@ -228,6 +228,6 @@ struct expr_ops expr_ops_masq = {
+ 	.get		= nftnl_expr_masq_get,
+ 	.parse		= nftnl_expr_masq_parse,
+ 	.build		= nftnl_expr_masq_build,
+-	.snprintf	= nftnl_expr_masq_snprintf,
++	.snprintf_	= nftnl_expr_masq_snprintf,
+ 	.json_parse	= nftnl_expr_masq_json_parse,
+ };
+diff --git a/src/expr/match.c b/src/expr/match.c
+index dd09e1e..f0d8868 100644
+--- a/src/expr/match.c
++++ b/src/expr/match.c
+@@ -249,6 +249,6 @@ struct expr_ops expr_ops_match = {
+ 	.get		= nftnl_expr_match_get,
+ 	.parse		= nftnl_expr_match_parse,
+ 	.build		= nftnl_expr_match_build,
+-	.snprintf	= nftnl_expr_match_snprintf,
++	.snprintf_	= nftnl_expr_match_snprintf,
+ 	.json_parse 	= nftnl_expr_match_json_parse,
+ };
+diff --git a/src/expr/meta.c b/src/expr/meta.c
+index de82105..91f1ebb 100644
+--- a/src/expr/meta.c
++++ b/src/expr/meta.c
+@@ -291,6 +291,6 @@ struct expr_ops expr_ops_meta = {
+ 	.get		= nftnl_expr_meta_get,
+ 	.parse		= nftnl_expr_meta_parse,
+ 	.build		= nftnl_expr_meta_build,
+-	.snprintf	= nftnl_expr_meta_snprintf,
++	.snprintf_	= nftnl_expr_meta_snprintf,
+ 	.json_parse 	= nftnl_expr_meta_json_parse,
+ };
+diff --git a/src/expr/nat.c b/src/expr/nat.c
+index 9271303..427c282 100644
+--- a/src/expr/nat.c
++++ b/src/expr/nat.c
+@@ -384,6 +384,6 @@ struct expr_ops expr_ops_nat = {
+ 	.get		= nftnl_expr_nat_get,
+ 	.parse		= nftnl_expr_nat_parse,
+ 	.build		= nftnl_expr_nat_build,
+-	.snprintf	= nftnl_expr_nat_snprintf,
++	.snprintf_	= nftnl_expr_nat_snprintf,
+ 	.json_parse	= nftnl_expr_nat_json_parse,
+ };
+diff --git a/src/expr/numgen.c b/src/expr/numgen.c
+index 5336fde..8e0479a 100644
+--- a/src/expr/numgen.c
++++ b/src/expr/numgen.c
+@@ -313,6 +313,6 @@ struct expr_ops expr_ops_ng = {
+ 	.get		= nftnl_expr_ng_get,
+ 	.parse		= nftnl_expr_ng_parse,
+ 	.build		= nftnl_expr_ng_build,
+-	.snprintf	= nftnl_expr_ng_snprintf,
++	.snprintf_	= nftnl_expr_ng_snprintf,
+ 	.json_parse	= nftnl_expr_ng_json_parse,
+ };
+diff --git a/src/expr/objref.c b/src/expr/objref.c
+index 64ee863..4504488 100644
+--- a/src/expr/objref.c
++++ b/src/expr/objref.c
+@@ -278,6 +278,6 @@ struct expr_ops expr_ops_objref = {
+ 	.get		= nftnl_expr_objref_get,
+ 	.parse		= nftnl_expr_objref_parse,
+ 	.build		= nftnl_expr_objref_build,
+-	.snprintf	= nftnl_expr_objref_snprintf,
++	.snprintf_	= nftnl_expr_objref_snprintf,
+ 	.json_parse	= nftnl_expr_objref_json_parse,
+ };
+diff --git a/src/expr/payload.c b/src/expr/payload.c
+index 91e1587..894ac08 100644
+--- a/src/expr/payload.c
++++ b/src/expr/payload.c
+@@ -348,6 +348,6 @@ struct expr_ops expr_ops_payload = {
+ 	.get		= nftnl_expr_payload_get,
+ 	.parse		= nftnl_expr_payload_parse,
+ 	.build		= nftnl_expr_payload_build,
+-	.snprintf	= nftnl_expr_payload_snprintf,
++	.snprintf_	= nftnl_expr_payload_snprintf,
+ 	.json_parse	= nftnl_expr_payload_json_parse,
+ };
+diff --git a/src/expr/queue.c b/src/expr/queue.c
+index a392a27..ee26c10 100644
+--- a/src/expr/queue.c
++++ b/src/expr/queue.c
+@@ -275,6 +275,6 @@ struct expr_ops expr_ops_queue = {
+ 	.get		= nftnl_expr_queue_get,
+ 	.parse		= nftnl_expr_queue_parse,
+ 	.build		= nftnl_expr_queue_build,
+-	.snprintf	= nftnl_expr_queue_snprintf,
++	.snprintf_	= nftnl_expr_queue_snprintf,
+ 	.json_parse	= nftnl_expr_queue_json_parse,
+ };
+diff --git a/src/expr/quota.c b/src/expr/quota.c
+index 667e6e1..ff5d182 100644
+--- a/src/expr/quota.c
++++ b/src/expr/quota.c
+@@ -203,6 +203,6 @@ struct expr_ops expr_ops_quota = {
+ 	.get		= nftnl_expr_quota_get,
+ 	.parse		= nftnl_expr_quota_parse,
+ 	.build		= nftnl_expr_quota_build,
+-	.snprintf	= nftnl_expr_quota_snprintf,
++	.snprintf_	= nftnl_expr_quota_snprintf,
+ 	.json_parse	= nftnl_expr_quota_json_parse,
+ };
+diff --git a/src/expr/range.c b/src/expr/range.c
+index b2789ff..8910f8a 100644
+--- a/src/expr/range.c
++++ b/src/expr/range.c
+@@ -283,6 +283,6 @@ struct expr_ops expr_ops_range = {
+ 	.get		= nftnl_expr_range_get,
+ 	.parse		= nftnl_expr_range_parse,
+ 	.build		= nftnl_expr_range_build,
+-	.snprintf	= nftnl_expr_range_snprintf,
++	.snprintf_	= nftnl_expr_range_snprintf,
+ 	.json_parse	= nftnl_expr_range_json_parse,
+ };
+diff --git a/src/expr/redir.c b/src/expr/redir.c
+index b2aa345..41b77ab 100644
+--- a/src/expr/redir.c
++++ b/src/expr/redir.c
+@@ -242,6 +242,6 @@ struct expr_ops expr_ops_redir = {
+ 	.get		= nftnl_expr_redir_get,
+ 	.parse		= nftnl_expr_redir_parse,
+ 	.build		= nftnl_expr_redir_build,
+-	.snprintf	= nftnl_expr_redir_snprintf,
++	.snprintf_	= nftnl_expr_redir_snprintf,
+ 	.json_parse	= nftnl_expr_redir_json_parse,
+ };
+diff --git a/src/expr/reject.c b/src/expr/reject.c
+index 11d8b20..b10e729 100644
+--- a/src/expr/reject.c
++++ b/src/expr/reject.c
+@@ -200,6 +200,6 @@ struct expr_ops expr_ops_reject = {
+ 	.get		= nftnl_expr_reject_get,
+ 	.parse		= nftnl_expr_reject_parse,
+ 	.build		= nftnl_expr_reject_build,
+-	.snprintf	= nftnl_expr_reject_snprintf,
++	.snprintf_	= nftnl_expr_reject_snprintf,
+ 	.json_parse	= nftnl_expr_reject_json_parse,
+ };
+diff --git a/src/expr/rt.c b/src/expr/rt.c
+index c3c92c7..688a042 100644
+--- a/src/expr/rt.c
++++ b/src/expr/rt.c
+@@ -235,6 +235,6 @@ struct expr_ops expr_ops_rt = {
+ 	.get		= nftnl_expr_rt_get,
+ 	.parse		= nftnl_expr_rt_parse,
+ 	.build		= nftnl_expr_rt_build,
+-	.snprintf	= nftnl_expr_rt_snprintf,
++	.snprintf_	= nftnl_expr_rt_snprintf,
+ 	.json_parse	= nftnl_expr_rt_json_parse,
+ };
+diff --git a/src/expr/socket.c b/src/expr/socket.c
+index db160a1..4c50011 100644
+--- a/src/expr/socket.c
++++ b/src/expr/socket.c
+@@ -204,5 +204,5 @@ struct expr_ops expr_ops_socket = {
+ 	.get		= nftnl_expr_socket_get,
+ 	.parse		= nftnl_expr_socket_parse,
+ 	.build		= nftnl_expr_socket_build,
+-	.snprintf	= nftnl_expr_socket_snprintf,
++	.snprintf_	= nftnl_expr_socket_snprintf,
+ };
+diff --git a/src/expr/target.c b/src/expr/target.c
+index ed4bf7d..2ef4078 100644
+--- a/src/expr/target.c
++++ b/src/expr/target.c
+@@ -249,6 +249,6 @@ struct expr_ops expr_ops_target = {
+ 	.get		= nftnl_expr_target_get,
+ 	.parse		= nftnl_expr_target_parse,
+ 	.build		= nftnl_expr_target_build,
+-	.snprintf	= nftnl_expr_target_snprintf,
++	.snprintf_	= nftnl_expr_target_snprintf,
+ 	.json_parse	= nftnl_expr_target_json_parse,
+ };
+diff --git a/src/obj/counter.c b/src/obj/counter.c
+index 332bb2b..edeb7be 100644
+--- a/src/obj/counter.c
++++ b/src/obj/counter.c
+@@ -182,6 +182,6 @@ struct obj_ops obj_ops_counter = {
+ 	.get		= nftnl_obj_counter_get,
+ 	.parse		= nftnl_obj_counter_parse,
+ 	.build		= nftnl_obj_counter_build,
+-	.snprintf	= nftnl_obj_counter_snprintf,
++	.snprintf_	= nftnl_obj_counter_snprintf,
+ 	.json_parse	= nftnl_obj_counter_json_parse,
+ };
+diff --git a/src/obj/ct_helper.c b/src/obj/ct_helper.c
+index 62569fe..69757ff 100644
+--- a/src/obj/ct_helper.c
++++ b/src/obj/ct_helper.c
+@@ -208,6 +208,6 @@ struct obj_ops obj_ops_ct_helper = {
+ 	.get		= nftnl_obj_ct_helper_get,
+ 	.parse		= nftnl_obj_ct_helper_parse,
+ 	.build		= nftnl_obj_ct_helper_build,
+-	.snprintf	= nftnl_obj_ct_helper_snprintf,
++	.snprintf_	= nftnl_obj_ct_helper_snprintf,
+ 	.json_parse	= nftnl_obj_quota_json_parse,
+ };
+diff --git a/src/obj/limit.c b/src/obj/limit.c
+index 7f8bcf7..25018b6 100644
+--- a/src/obj/limit.c
++++ b/src/obj/limit.c
+@@ -236,6 +236,6 @@ struct obj_ops obj_ops_limit = {
+ 	.get		= nftnl_obj_limit_get,
+ 	.parse		= nftnl_obj_limit_parse,
+ 	.build		= nftnl_obj_limit_build,
+-	.snprintf	= nftnl_obj_limit_snprintf,
++	.snprintf_	= nftnl_obj_limit_snprintf,
+ 	.json_parse	= nftnl_obj_limit_json_parse,
+ };
+diff --git a/src/obj/quota.c b/src/obj/quota.c
+index 6d36784..ecaa8b1 100644
+--- a/src/obj/quota.c
++++ b/src/obj/quota.c
+@@ -203,6 +203,6 @@ struct obj_ops obj_ops_quota = {
+ 	.get		= nftnl_obj_quota_get,
+ 	.parse		= nftnl_obj_quota_parse,
+ 	.build		= nftnl_obj_quota_build,
+-	.snprintf	= nftnl_obj_quota_snprintf,
++	.snprintf_	= nftnl_obj_quota_snprintf,
+ 	.json_parse	= nftnl_obj_quota_json_parse,
+ };
+diff --git a/src/object.c b/src/object.c
+index d8278f3..9654b7b 100644
+--- a/src/object.c
++++ b/src/object.c
+@@ -429,7 +429,7 @@ static int nftnl_obj_export(char *buf, size_t size,
+ 		nftnl_buf_u64(&b, type, obj->handle, HANDLE);
+ 
+ 	if (obj->ops)
+-		ret = obj->ops->snprintf(buf + b.len, size - b.len, type,
++		ret = obj->ops->snprintf_(buf + b.len, size - b.len, type,
+ 					 flags, obj);
+ 
+ 	b.len += ret;
+@@ -450,7 +450,7 @@ static int nftnl_obj_snprintf_dflt(char *buf, size_t size,
+ 	SNPRINTF_BUFFER_SIZE(ret, remain, offset);
+ 
+ 	if (obj->ops) {
+-		ret = obj->ops->snprintf(buf + offset, offset, type, flags,
++		ret = obj->ops->snprintf_(buf + offset, offset, type, flags,
+ 					 obj);
+ 		SNPRINTF_BUFFER_SIZE(ret, remain, offset);
+ 	}
diff --git a/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl_1.0.7.bb b/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl_1.0.7.bb
deleted file mode 100644
index ca01c0a..0000000
--- a/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl_1.0.7.bb
+++ /dev/null
@@ -1,17 +0,0 @@
-SUMMARY = "Library for low-level interaction with nftables Netlink's API over libmnl"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=79808397c3355f163c012616125c9e26"
-SECTION = "libs"
-DEPENDS = "libmnl"
-PV .= "+git${SRCPV}"
-SRCREV = "4b89c0cb0883f638ff1abbc2ff47c43cdc26aac5"
-SRC_URI = "git://git.netfilter.org/libnftnl \
-           file://0001-Declare-the-define-visivility-attribute-together.patch \
-           file://0001-avoid-naming-local-function-as-one-of-printf-family.patch \
-           "
-SRC_URI[md5sum] = "82183867168eb6644926c48b991b8aac"
-SRC_URI[sha256sum] = "9bb66ecbc64b8508249402f0093829f44177770ad99f6042b86b3a467d963982"
-
-S = "${WORKDIR}/git"
-
-inherit autotools pkgconfig
diff --git a/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl_1.1.1.bb b/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl_1.1.1.bb
new file mode 100644
index 0000000..77959a7
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-filter/libnftnl/libnftnl_1.1.1.bb
@@ -0,0 +1,15 @@
+SUMMARY = "Library for low-level interaction with nftables Netlink's API over libmnl"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=79808397c3355f163c012616125c9e26"
+SECTION = "libs"
+DEPENDS = "libmnl"
+PV .= "+git${SRCPV}"
+SRCREV = "d379dfcb6c94dcb93a8f16896572d6e162138e0f"
+SRC_URI = "git://git.netfilter.org/libnftnl \
+           file://0001-Move-exports-before-symbol-definition.patch \
+           file://0002-avoid-naming-local-function-as-one-of-printf-family.patch \
+           "
+
+S = "${WORKDIR}/git"
+
+inherit autotools pkgconfig
diff --git a/meta-openembedded/meta-networking/recipes-filter/nftables/files/0001-payload-explicit-network-ctx-assignment-for-icmp-icm.patch b/meta-openembedded/meta-networking/recipes-filter/nftables/files/0001-payload-explicit-network-ctx-assignment-for-icmp-icm.patch
deleted file mode 100644
index 86a3d53..0000000
--- a/meta-openembedded/meta-networking/recipes-filter/nftables/files/0001-payload-explicit-network-ctx-assignment-for-icmp-icm.patch
+++ /dev/null
@@ -1,323 +0,0 @@
-From 0011985554e269e1cc8f8e5b41eb9dcd795ebe8c Mon Sep 17 00:00:00 2001
-From: Arturo Borrero Gonzalez <arturo@debian.org>
-Date: Wed, 25 Jan 2017 12:51:08 +0100
-Subject: [PATCH] payload: explicit network ctx assignment for icmp/icmp6 in
- special families
-
-In the inet, bridge and netdev families, we can add rules like these:
-
-% nft add rule inet t c ip protocol icmp icmp type echo-request
-% nft add rule inet t c ip6 nexthdr icmpv6 icmpv6 type echo-request
-
-However, when we print the ruleset:
-
-% nft list ruleset
-table inet t {
-	chain c {
-		icmpv6 type echo-request
-		icmp type echo-request
-	}
-}
-
-These rules we obtain can't be added again:
-
-% nft add rule inet t c icmp type echo-request
-<cmdline>:1:19-27: Error: conflicting protocols specified: inet-service vs. icmp
-add rule inet t c icmp type echo-request
-                  ^^^^^^^^^
-
-% nft add rule inet t c icmpv6 type echo-request
-<cmdline>:1:19-29: Error: conflicting protocols specified: inet-service vs. icmpv6
-add rule inet t c icmpv6 type echo-request
-                  ^^^^^^^^^^^
-
-Since I wouldn't expect an IP packet carrying ICMPv6, or IPv6 packet
-carrying ICMP, if the link layer is inet, the network layer protocol context
-can be safely update to 'ip' or 'ip6'.
-
-Moreover, nft currently generates a 'meta nfproto ipvX' depedency when
-using icmp or icmp6 in the inet family, and similar in netdev and bridge
-families.
-
-While at it, a bit of code factorization is introduced.
-
-Fixes: https://bugzilla.netfilter.org/show_bug.cgi?id=1073
-Signed-off-by: Arturo Borrero Gonzalez <arturo@debian.org>
-Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
----
-Upstream-Status: Backport
-Signed-off-by: André Draszik <adraszik@tycoint.com>
- src/payload.c                       | 70 ++++++++++++++++---------------------
- tests/py/any/icmpX.t.netdev         |  8 +++++
- tests/py/any/icmpX.t.netdev.payload | 36 +++++++++++++++++++
- tests/py/bridge/icmpX.t             |  8 +++++
- tests/py/bridge/icmpX.t.payload     | 36 +++++++++++++++++++
- tests/py/inet/icmpX.t               |  8 +++++
- tests/py/inet/icmpX.t.payload       | 36 +++++++++++++++++++
- 7 files changed, 162 insertions(+), 40 deletions(-)
- create mode 100644 tests/py/any/icmpX.t.netdev
- create mode 100644 tests/py/any/icmpX.t.netdev.payload
- create mode 100644 tests/py/bridge/icmpX.t
- create mode 100644 tests/py/bridge/icmpX.t.payload
- create mode 100644 tests/py/inet/icmpX.t
- create mode 100644 tests/py/inet/icmpX.t.payload
-
-diff --git a/src/payload.c b/src/payload.c
-index af533b2..74f8254 100644
---- a/src/payload.c
-+++ b/src/payload.c
-@@ -223,6 +223,34 @@ static int payload_add_dependency(struct eval_ctx *ctx,
- 	return 0;
- }
- 
-+static const struct proto_desc *
-+payload_gen_special_dependency(struct eval_ctx *ctx, const struct expr *expr)
-+{
-+	switch (expr->payload.base) {
-+	case PROTO_BASE_LL_HDR:
-+		switch (ctx->pctx.family) {
-+		case NFPROTO_INET:
-+			return &proto_inet;
-+		case NFPROTO_BRIDGE:
-+			return &proto_eth;
-+		case NFPROTO_NETDEV:
-+			return &proto_netdev;
-+		default:
-+			break;
-+		}
-+		break;
-+	case PROTO_BASE_TRANSPORT_HDR:
-+		if (expr->payload.desc == &proto_icmp)
-+			return &proto_ip;
-+		if (expr->payload.desc == &proto_icmp6)
-+			return &proto_ip6;
-+		return &proto_inet_service;
-+	default:
-+		break;
-+	}
-+	return NULL;
-+}
-+
- /**
-  * payload_gen_dependency - generate match expression on payload dependency
-  *
-@@ -276,46 +304,8 @@ int payload_gen_dependency(struct eval_ctx *ctx, const struct expr *expr,
- 
- 	desc = ctx->pctx.protocol[expr->payload.base - 1].desc;
- 	/* Special case for mixed IPv4/IPv6 and bridge tables */
--	if (desc == NULL) {
--		switch (ctx->pctx.family) {
--		case NFPROTO_INET:
--			switch (expr->payload.base) {
--			case PROTO_BASE_LL_HDR:
--				desc = &proto_inet;
--				break;
--			case PROTO_BASE_TRANSPORT_HDR:
--				desc = &proto_inet_service;
--				break;
--			default:
--				break;
--			}
--			break;
--		case NFPROTO_BRIDGE:
--			switch (expr->payload.base) {
--			case PROTO_BASE_LL_HDR:
--				desc = &proto_eth;
--				break;
--			case PROTO_BASE_TRANSPORT_HDR:
--				desc = &proto_inet_service;
--				break;
--			default:
--				break;
--			}
--			break;
--		case NFPROTO_NETDEV:
--			switch (expr->payload.base) {
--			case PROTO_BASE_LL_HDR:
--				desc = &proto_netdev;
--				break;
--			case PROTO_BASE_TRANSPORT_HDR:
--				desc = &proto_inet_service;
--				break;
--			default:
--				break;
--			}
--			break;
--		}
--	}
-+	if (desc == NULL)
-+		desc = payload_gen_special_dependency(ctx, expr);
- 
- 	if (desc == NULL)
- 		return expr_error(ctx->msgs, expr,
-diff --git a/tests/py/any/icmpX.t.netdev b/tests/py/any/icmpX.t.netdev
-new file mode 100644
-index 0000000..a327ce6
---- /dev/null
-+++ b/tests/py/any/icmpX.t.netdev
-@@ -0,0 +1,8 @@
-+:ingress;type filter hook ingress device lo priority 0
-+
-+*netdev;test-netdev;ingress
-+
-+ip protocol icmp icmp type echo-request;ok;icmp type echo-request
-+icmp type echo-request;ok
-+ip6 nexthdr icmpv6 icmpv6 type echo-request;ok;icmpv6 type echo-request
-+icmpv6 type echo-request;ok
-diff --git a/tests/py/any/icmpX.t.netdev.payload b/tests/py/any/icmpX.t.netdev.payload
-new file mode 100644
-index 0000000..8b8107c
---- /dev/null
-+++ b/tests/py/any/icmpX.t.netdev.payload
-@@ -0,0 +1,36 @@
-+# ip protocol icmp icmp type echo-request
-+netdev test-netdev ingress
-+  [ meta load protocol => reg 1 ]
-+  [ cmp eq reg 1 0x00000008 ]
-+  [ payload load 1b @ network header + 9 => reg 1 ]
-+  [ cmp eq reg 1 0x00000001 ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x00000008 ]
-+
-+# icmp type echo-request
-+netdev test-netdev ingress
-+  [ meta load protocol => reg 1 ]
-+  [ cmp eq reg 1 0x00000008 ]
-+  [ payload load 1b @ network header + 9 => reg 1 ]
-+  [ cmp eq reg 1 0x00000001 ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x00000008 ]
-+
-+# ip6 nexthdr icmpv6 icmpv6 type echo-request
-+netdev test-netdev ingress
-+  [ meta load protocol => reg 1 ]
-+  [ cmp eq reg 1 0x0000dd86 ]
-+  [ payload load 1b @ network header + 6 => reg 1 ]
-+  [ cmp eq reg 1 0x0000003a ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x00000080 ]
-+
-+# icmpv6 type echo-request
-+netdev test-netdev ingress
-+  [ meta load protocol => reg 1 ]
-+  [ cmp eq reg 1 0x0000dd86 ]
-+  [ payload load 1b @ network header + 6 => reg 1 ]
-+  [ cmp eq reg 1 0x0000003a ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x00000080 ]
-+
-diff --git a/tests/py/bridge/icmpX.t b/tests/py/bridge/icmpX.t
-new file mode 100644
-index 0000000..8c0a597
---- /dev/null
-+++ b/tests/py/bridge/icmpX.t
-@@ -0,0 +1,8 @@
-+:input;type filter hook input priority 0
-+
-+*bridge;test-bridge;input
-+
-+ip protocol icmp icmp type echo-request;ok;icmp type echo-request
-+icmp type echo-request;ok
-+ip6 nexthdr icmpv6 icmpv6 type echo-request;ok;icmpv6 type echo-request
-+icmpv6 type echo-request;ok
-diff --git a/tests/py/bridge/icmpX.t.payload b/tests/py/bridge/icmpX.t.payload
-new file mode 100644
-index 0000000..19efdd8
---- /dev/null
-+++ b/tests/py/bridge/icmpX.t.payload
-@@ -0,0 +1,36 @@
-+# ip protocol icmp icmp type echo-request
-+bridge test-bridge input
-+  [ payload load 2b @ link header + 12 => reg 1 ]
-+  [ cmp eq reg 1 0x00000008 ]
-+  [ payload load 1b @ network header + 9 => reg 1 ]
-+  [ cmp eq reg 1 0x00000001 ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x00000008 ]
-+
-+# icmp type echo-request
-+bridge test-bridge input
-+  [ payload load 2b @ link header + 12 => reg 1 ]
-+  [ cmp eq reg 1 0x00000008 ]
-+  [ payload load 1b @ network header + 9 => reg 1 ]
-+  [ cmp eq reg 1 0x00000001 ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x00000008 ]
-+
-+# ip6 nexthdr icmpv6 icmpv6 type echo-request
-+bridge test-bridge input
-+  [ payload load 2b @ link header + 12 => reg 1 ]
-+  [ cmp eq reg 1 0x0000dd86 ]
-+  [ payload load 1b @ network header + 6 => reg 1 ]
-+  [ cmp eq reg 1 0x0000003a ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x00000080 ]
-+
-+# icmpv6 type echo-request
-+bridge test-bridge input
-+  [ payload load 2b @ link header + 12 => reg 1 ]
-+  [ cmp eq reg 1 0x0000dd86 ]
-+  [ payload load 1b @ network header + 6 => reg 1 ]
-+  [ cmp eq reg 1 0x0000003a ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x00000080 ]
-+
-diff --git a/tests/py/inet/icmpX.t b/tests/py/inet/icmpX.t
-new file mode 100644
-index 0000000..1b467a1
---- /dev/null
-+++ b/tests/py/inet/icmpX.t
-@@ -0,0 +1,8 @@
-+:input;type filter hook input priority 0
-+
-+*inet;test-inet;input
-+
-+ip protocol icmp icmp type echo-request;ok;icmp type echo-request
-+icmp type echo-request;ok
-+ip6 nexthdr icmpv6 icmpv6 type echo-request;ok;icmpv6 type echo-request
-+icmpv6 type echo-request;ok
-diff --git a/tests/py/inet/icmpX.t.payload b/tests/py/inet/icmpX.t.payload
-new file mode 100644
-index 0000000..81ca774
---- /dev/null
-+++ b/tests/py/inet/icmpX.t.payload
-@@ -0,0 +1,36 @@
-+# ip protocol icmp icmp type echo-request
-+inet test-inet input
-+  [ meta load nfproto => reg 1 ]
-+  [ cmp eq reg 1 0x00000002 ]
-+  [ payload load 1b @ network header + 9 => reg 1 ]
-+  [ cmp eq reg 1 0x00000001 ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x00000008 ]
-+
-+# icmp type echo-request
-+inet test-inet input
-+  [ meta load nfproto => reg 1 ]
-+  [ cmp eq reg 1 0x00000002 ]
-+  [ payload load 1b @ network header + 9 => reg 1 ]
-+  [ cmp eq reg 1 0x00000001 ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x00000008 ]
-+
-+# ip6 nexthdr icmpv6 icmpv6 type echo-request
-+inet test-inet input
-+  [ meta load nfproto => reg 1 ]
-+  [ cmp eq reg 1 0x0000000a ]
-+  [ payload load 1b @ network header + 6 => reg 1 ]
-+  [ cmp eq reg 1 0x0000003a ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x00000080 ]
-+
-+# icmpv6 type echo-request
-+inet test-inet input
-+  [ meta load nfproto => reg 1 ]
-+  [ cmp eq reg 1 0x0000000a ]
-+  [ payload load 1b @ network header + 6 => reg 1 ]
-+  [ cmp eq reg 1 0x0000003a ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x00000080 ]
-+
--- 
-2.11.0
-
diff --git a/meta-openembedded/meta-networking/recipes-filter/nftables/files/0002-proto-Add-some-exotic-ICMPv6-types.patch b/meta-openembedded/meta-networking/recipes-filter/nftables/files/0002-proto-Add-some-exotic-ICMPv6-types.patch
deleted file mode 100644
index 4d9e9d1..0000000
--- a/meta-openembedded/meta-networking/recipes-filter/nftables/files/0002-proto-Add-some-exotic-ICMPv6-types.patch
+++ /dev/null
@@ -1,147 +0,0 @@
-From 9ade8fb75f8963375b45b3f2973b8bb7aa66ad76 Mon Sep 17 00:00:00 2001
-From: Phil Sutter <phil@nwl.cc>
-Date: Thu, 16 Mar 2017 13:43:20 +0100
-Subject: [PATCH] proto: Add some exotic ICMPv6 types
-
-This adds support for matching on inverse ND messages as defined by
-RFC3122 (not implemented in Linux) and MLDv2 as defined by RFC3810.
-
-Note that ICMPV6_MLD2_REPORT macro is defined in linux/icmpv6.h but
-including that header leads to conflicts with symbols defined in
-netinet/icmp6.h.
-
-In addition to the above, "mld-listener-done" is introduced as an alias
-for "mld-listener-reduction".
-
-Signed-off-by: Phil Sutter <phil@nwl.cc>
-Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
----
-Upstream-Status: Backport
-Signed-off-by: André Draszik <adraszik@tycoint.com>
- src/proto.c                       |  8 ++++++++
- tests/py/ip6/icmpv6.t             |  8 ++++++--
- tests/py/ip6/icmpv6.t.payload.ip6 | 34 +++++++++++++++++++++++++++++++++-
- 3 files changed, 47 insertions(+), 3 deletions(-)
-
-diff --git a/src/proto.c b/src/proto.c
-index fb96530..79e9dbf 100644
---- a/src/proto.c
-+++ b/src/proto.c
-@@ -632,6 +632,10 @@ const struct proto_desc proto_ip = {
- 
- #include <netinet/icmp6.h>
- 
-+#define IND_NEIGHBOR_SOLICIT	141
-+#define IND_NEIGHBOR_ADVERT	142
-+#define ICMPV6_MLD2_REPORT	143
-+
- static const struct symbol_table icmp6_type_tbl = {
- 	.base		= BASE_DECIMAL,
- 	.symbols	= {
-@@ -643,6 +647,7 @@ static const struct symbol_table icmp6_type_tbl = {
- 		SYMBOL("echo-reply",			ICMP6_ECHO_REPLY),
- 		SYMBOL("mld-listener-query",		MLD_LISTENER_QUERY),
- 		SYMBOL("mld-listener-report",		MLD_LISTENER_REPORT),
-+		SYMBOL("mld-listener-done",		MLD_LISTENER_REDUCTION),
- 		SYMBOL("mld-listener-reduction",	MLD_LISTENER_REDUCTION),
- 		SYMBOL("nd-router-solicit",		ND_ROUTER_SOLICIT),
- 		SYMBOL("nd-router-advert",		ND_ROUTER_ADVERT),
-@@ -650,6 +655,9 @@ static const struct symbol_table icmp6_type_tbl = {
- 		SYMBOL("nd-neighbor-advert",		ND_NEIGHBOR_ADVERT),
- 		SYMBOL("nd-redirect",			ND_REDIRECT),
- 		SYMBOL("router-renumbering",		ICMP6_ROUTER_RENUMBERING),
-+		SYMBOL("ind-neighbor-solicit",		IND_NEIGHBOR_SOLICIT),
-+		SYMBOL("ind-neighbor-advert",		IND_NEIGHBOR_ADVERT),
-+		SYMBOL("mld2-listener-report",		ICMPV6_MLD2_REPORT),
- 		SYMBOL_LIST_END
- 	},
- };
-diff --git a/tests/py/ip6/icmpv6.t b/tests/py/ip6/icmpv6.t
-index afbd451..a898fe3 100644
---- a/tests/py/ip6/icmpv6.t
-+++ b/tests/py/ip6/icmpv6.t
-@@ -11,7 +11,8 @@ icmpv6 type echo-request accept;ok
- icmpv6 type echo-reply accept;ok
- icmpv6 type mld-listener-query accept;ok
- icmpv6 type mld-listener-report accept;ok
--icmpv6 type mld-listener-reduction accept;ok
-+icmpv6 type mld-listener-done accept;ok
-+icmpv6 type mld-listener-reduction accept;ok;icmpv6 type mld-listener-done accept
- icmpv6 type nd-router-solicit accept;ok
- icmpv6 type nd-router-advert accept;ok
- icmpv6 type nd-neighbor-solicit accept;ok
-@@ -19,8 +20,11 @@ icmpv6 type nd-neighbor-advert accept;ok
- icmpv6 type nd-redirect accept;ok
- icmpv6 type parameter-problem accept;ok
- icmpv6 type router-renumbering accept;ok
-+icmpv6 type ind-neighbor-solicit accept;ok
-+icmpv6 type ind-neighbor-advert accept;ok
-+icmpv6 type mld2-listener-report accept;ok
- icmpv6 type {destination-unreachable, time-exceeded, nd-router-solicit} accept;ok
--icmpv6 type {router-renumbering, mld-listener-reduction, time-exceeded, nd-router-solicit} accept;ok
-+icmpv6 type {router-renumbering, mld-listener-done, time-exceeded, nd-router-solicit} accept;ok
- icmpv6 type {mld-listener-query, time-exceeded, nd-router-advert} accept;ok
- icmpv6 type != {mld-listener-query, time-exceeded, nd-router-advert} accept;ok
- 
-diff --git a/tests/py/ip6/icmpv6.t.payload.ip6 b/tests/py/ip6/icmpv6.t.payload.ip6
-index 9fe2496..30f58ca 100644
---- a/tests/py/ip6/icmpv6.t.payload.ip6
-+++ b/tests/py/ip6/icmpv6.t.payload.ip6
-@@ -54,6 +54,14 @@ ip6 test-ip6 input
-   [ cmp eq reg 1 0x00000083 ]
-   [ immediate reg 0 accept ]
- 
-+# icmpv6 type mld-listener-done accept
-+ip6 test-ip6 input
-+  [ payload load 1b @ network header + 6 => reg 1 ]
-+  [ cmp eq reg 1 0x0000003a ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x00000084 ]
-+  [ immediate reg 0 accept ]
-+
- # icmpv6 type mld-listener-reduction accept
- ip6 test-ip6 input
-   [ payload load 1b @ network header + 6 => reg 1 ]
-@@ -118,6 +126,30 @@ ip6 test-ip6 input
-   [ cmp eq reg 1 0x0000008a ]
-   [ immediate reg 0 accept ]
- 
-+# icmpv6 type ind-neighbor-solicit accept
-+ip6 test-ip6 input
-+  [ payload load 1b @ network header + 6 => reg 1 ]
-+  [ cmp eq reg 1 0x0000003a ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x0000008d ]
-+  [ immediate reg 0 accept ]
-+
-+# icmpv6 type ind-neighbor-advert accept
-+ip6 test-ip6 input
-+  [ payload load 1b @ network header + 6 => reg 1 ]
-+  [ cmp eq reg 1 0x0000003a ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x0000008e ]
-+  [ immediate reg 0 accept ]
-+
-+# icmpv6 type mld2-listener-report accept
-+ip6 test-ip6 input
-+  [ payload load 1b @ network header + 6 => reg 1 ]
-+  [ cmp eq reg 1 0x0000003a ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x0000008f ]
-+  [ immediate reg 0 accept ]
-+
- # icmpv6 type {destination-unreachable, time-exceeded, nd-router-solicit} accept
- __set%d test-ip6 3
- __set%d test-ip6 0
-@@ -129,7 +161,7 @@ ip6 test-ip6 input
-   [ lookup reg 1 set __set%d ]
-   [ immediate reg 0 accept ]
- 
--# icmpv6 type {router-renumbering, mld-listener-reduction, time-exceeded, nd-router-solicit} accept
-+# icmpv6 type {router-renumbering, mld-listener-done, time-exceeded, nd-router-solicit} accept
- __set%d test-ip6 3
- __set%d test-ip6 0
- 	element 0000008a  : 0 [end]	element 00000084  : 0 [end]	element 00000003  : 0 [end]	element 00000085  : 0 [end]
--- 
-2.11.0
-
diff --git a/meta-openembedded/meta-networking/recipes-filter/nftables/files/0003-payload-split-ll-proto-dependency-into-helper.patch b/meta-openembedded/meta-networking/recipes-filter/nftables/files/0003-payload-split-ll-proto-dependency-into-helper.patch
deleted file mode 100644
index 50cac30..0000000
--- a/meta-openembedded/meta-networking/recipes-filter/nftables/files/0003-payload-split-ll-proto-dependency-into-helper.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-From 8d8cfe5ad6ca460a5262fb15fdbef3601058c784 Mon Sep 17 00:00:00 2001
-From: Florian Westphal <fw@strlen.de>
-Date: Thu, 18 May 2017 13:30:54 +0200
-Subject: [PATCH 1/4] payload: split ll proto dependency into helper
-
-will be re-used in folloup patch for icmp/icmpv6 depenency
-handling.
-
-Signed-off-by: Florian Westphal <fw@strlen.de>
----
-Upstream-Status: Backport
-Signed-off-by: André Draszik <adraszik@tycoint.com>
- src/payload.c | 29 ++++++++++++++++++-----------
- 1 file changed, 18 insertions(+), 11 deletions(-)
-
-diff --git a/src/payload.c b/src/payload.c
-index 55128fe..31e5a02 100644
---- a/src/payload.c
-+++ b/src/payload.c
-@@ -224,21 +224,28 @@ static int payload_add_dependency(struct eval_ctx *ctx,
- }
- 
- static const struct proto_desc *
-+payload_get_get_ll_hdr(const struct eval_ctx *ctx)
-+{
-+	switch (ctx->pctx.family) {
-+	case NFPROTO_INET:
-+		return &proto_inet;
-+	case NFPROTO_BRIDGE:
-+		return &proto_eth;
-+	case NFPROTO_NETDEV:
-+		return &proto_netdev;
-+	default:
-+		break;
-+	}
-+
-+	return NULL;
-+}
-+
-+static const struct proto_desc *
- payload_gen_special_dependency(struct eval_ctx *ctx, const struct expr *expr)
- {
- 	switch (expr->payload.base) {
- 	case PROTO_BASE_LL_HDR:
--		switch (ctx->pctx.family) {
--		case NFPROTO_INET:
--			return &proto_inet;
--		case NFPROTO_BRIDGE:
--			return &proto_eth;
--		case NFPROTO_NETDEV:
--			return &proto_netdev;
--		default:
--			break;
--		}
--		break;
-+		return payload_get_get_ll_hdr(ctx);
- 	case PROTO_BASE_TRANSPORT_HDR:
- 		if (expr->payload.desc == &proto_icmp)
- 			return &proto_ip;
--- 
-2.11.0
-
diff --git a/meta-openembedded/meta-networking/recipes-filter/nftables/files/0004-src-allow-update-of-net-base-w.-meta-l4proto-icmpv6.patch b/meta-openembedded/meta-networking/recipes-filter/nftables/files/0004-src-allow-update-of-net-base-w.-meta-l4proto-icmpv6.patch
deleted file mode 100644
index 180edb3..0000000
--- a/meta-openembedded/meta-networking/recipes-filter/nftables/files/0004-src-allow-update-of-net-base-w.-meta-l4proto-icmpv6.patch
+++ /dev/null
@@ -1,65 +0,0 @@
-From 9a1f2bbf3cd2417e0c10d18578e224abe2071d68 Mon Sep 17 00:00:00 2001
-From: Florian Westphal <fw@strlen.de>
-Date: Tue, 21 Mar 2017 19:47:22 +0100
-Subject: [PATCH 2/4] src: allow update of net base w. meta l4proto icmpv6
-
-nft add rule ip6 f i meta l4proto ipv6-icmp icmpv6 type nd-router-advert
-<cmdline>:1:50-60: Error: conflicting protocols specified: unknown vs. icmpv6
-
-add icmpv6 to nexthdr list so base gets updated correctly.
-
-Reported-by: Thomas Woerner <twoerner@redhat.com>
-Signed-off-by: Florian Westphal <fw@strlen.de>
----
-Upstream-Status: Backport
-Signed-off-by: André Draszik <adraszik@tycoint.com>
- src/proto.c                 | 1 +
- tests/py/any/meta.t         | 1 +
- tests/py/any/meta.t.payload | 7 +++++++
- 3 files changed, 9 insertions(+)
-
-diff --git a/src/proto.c b/src/proto.c
-index 79e9dbf..fcdfbe7 100644
---- a/src/proto.c
-+++ b/src/proto.c
-@@ -779,6 +779,7 @@ const struct proto_desc proto_inet_service = {
- 		PROTO_LINK(IPPROTO_TCP,		&proto_tcp),
- 		PROTO_LINK(IPPROTO_DCCP,	&proto_dccp),
- 		PROTO_LINK(IPPROTO_SCTP,	&proto_sctp),
-+		PROTO_LINK(IPPROTO_ICMPV6,	&proto_icmp6),
- 	},
- 	.templates	= {
- 		[0]	= PROTO_META_TEMPLATE("l4proto", &inet_protocol_type, NFT_META_L4PROTO, 8),
-diff --git a/tests/py/any/meta.t b/tests/py/any/meta.t
-index c3ac0a4..2ff942f 100644
---- a/tests/py/any/meta.t
-+++ b/tests/py/any/meta.t
-@@ -38,6 +38,7 @@ meta l4proto { 33, 55, 67, 88};ok;meta l4proto { 33, 55, 67, 88}
- meta l4proto != { 33, 55, 67, 88};ok
- meta l4proto { 33-55};ok
- meta l4proto != { 33-55};ok
-+meta l4proto ipv6-icmp icmpv6 type nd-router-advert;ok;icmpv6 type nd-router-advert
- 
- meta priority root;ok
- meta priority none;ok
-diff --git a/tests/py/any/meta.t.payload b/tests/py/any/meta.t.payload
-index e432656..871f1ad 100644
---- a/tests/py/any/meta.t.payload
-+++ b/tests/py/any/meta.t.payload
-@@ -187,6 +187,13 @@ ip test-ip4 input
-   [ byteorder reg 1 = hton(reg 1, 2, 1) ]
-   [ lookup reg 1 set __set%d 0x1 ]
- 
-+# meta l4proto ipv6-icmp icmpv6 type nd-router-advert
-+ip test-ip4 input
-+  [ meta load l4proto => reg 1 ]
-+  [ cmp eq reg 1 0x0000003a ]
-+  [ payload load 1b @ transport header + 0 => reg 1 ]
-+  [ cmp eq reg 1 0x00000086 ]
-+
- # meta mark 0x4
- ip test-ip4 input
-   [ meta load mark => reg 1 ]
--- 
-2.11.0
-
diff --git a/meta-openembedded/meta-networking/recipes-filter/nftables/files/0005-src-ipv6-switch-implicit-dependencies-to-meta-l4prot.patch b/meta-openembedded/meta-networking/recipes-filter/nftables/files/0005-src-ipv6-switch-implicit-dependencies-to-meta-l4prot.patch
deleted file mode 100644
index f600ae0..0000000
--- a/meta-openembedded/meta-networking/recipes-filter/nftables/files/0005-src-ipv6-switch-implicit-dependencies-to-meta-l4prot.patch
+++ /dev/null
@@ -1,98 +0,0 @@
-From 2366ed9ffcb4f5f5341f10f0a1d1a4688d37ad87 Mon Sep 17 00:00:00 2001
-From: Florian Westphal <fw@strlen.de>
-Date: Wed, 22 Mar 2017 15:08:48 +0100
-Subject: [PATCH 3/4] src: ipv6: switch implicit dependencies to meta l4proto
-
-when using rule like
-
-ip6 filter input tcp dport 22
-nft generates:
-  [ payload load 1b @ network header + 6 => reg 1 ]
-  [ cmp eq reg 1 0x00000006 ]
-  [ payload load 2b @ transport header + 2 => reg 1 ]
-  [ cmp eq reg 1 0x00001600 ]
-
-which is: ip6 filter input ip6 nexthdr tcp dport 22
-IOW, such a rule won't match if e.g. a fragment header is in place.
-
-This changes ip6_proto to use 'meta l4proto' which is the protocol header
-found by exthdr walk.
-
-A side effect is that for bridge we get a shorter dependency chain as it
-no longer needs to prepend 'ether proto ipv6' for old 'ip6 nexthdr' dep.
-
-Only problem:
-
-ip6 nexthdr tcp tcp dport 22
-will now inject a (useless) meta l4 dependency as ip6 nexthdr is no
-longer flagged as EXPR_F_PROTOCOL, to avoid this add a small helper
-that skips the unneded meta dependency in that case.
-
-Signed-off-by: Florian Westphal <fw@strlen.de>
----
-Upstream-Status: Backport
-Signed-off-by: André Draszik <adraszik@tycoint.com>
- src/payload.c | 19 ++++++++++++++++++-
- src/proto.c   |  2 +-
- 2 files changed, 19 insertions(+), 2 deletions(-)
-
-diff --git a/src/payload.c b/src/payload.c
-index 31e5a02..38db15e 100644
---- a/src/payload.c
-+++ b/src/payload.c
-@@ -117,6 +117,23 @@ static const struct expr_ops payload_expr_ops = {
- 	.pctx_update	= payload_expr_pctx_update,
- };
- 
-+/*
-+ * ipv6 is special case, we normally use 'meta l4proto' to fetch the last
-+ * l4 header of the ipv6 extension header chain so we will also match
-+ * tcp after a fragmentation header, for instance.
-+ *
-+ * If user specifically asks for nexthdr x, treat is as a full
-+ * dependency rather than injecting another (useless) meta l4 one.
-+ */
-+static bool proto_key_is_protocol(const struct proto_desc *desc, unsigned int type)
-+{
-+	if (type == desc->protocol_key ||
-+	    (desc == &proto_ip6 && type == IP6HDR_NEXTHDR))
-+		return true;
-+
-+	return false;
-+}
-+
- struct expr *payload_expr_alloc(const struct location *loc,
- 				const struct proto_desc *desc,
- 				unsigned int type)
-@@ -129,7 +146,7 @@ struct expr *payload_expr_alloc(const struct location *loc,
- 	if (desc != NULL) {
- 		tmpl = &desc->templates[type];
- 		base = desc->base;
--		if (type == desc->protocol_key)
-+		if (proto_key_is_protocol(desc, type))
- 			flags = EXPR_F_PROTOCOL;
- 	} else {
- 		tmpl = &proto_unknown_template;
-diff --git a/src/proto.c b/src/proto.c
-index fcdfbe7..3b20a5f 100644
---- a/src/proto.c
-+++ b/src/proto.c
-@@ -707,7 +707,6 @@ const struct proto_desc proto_icmp6 = {
- const struct proto_desc proto_ip6 = {
- 	.name		= "ip6",
- 	.base		= PROTO_BASE_NETWORK_HDR,
--	.protocol_key	= IP6HDR_NEXTHDR,
- 	.protocols	= {
- 		PROTO_LINK(IPPROTO_ESP,		&proto_esp),
- 		PROTO_LINK(IPPROTO_AH,		&proto_ah),
-@@ -720,6 +719,7 @@ const struct proto_desc proto_ip6 = {
- 		PROTO_LINK(IPPROTO_ICMPV6,	&proto_icmp6),
- 	},
- 	.templates	= {
-+		[0]	= PROTO_META_TEMPLATE("l4proto", &inet_protocol_type, NFT_META_L4PROTO, 8),
- 		[IP6HDR_VERSION]	= HDR_BITFIELD("version", &integer_type, 0, 4),
- 		[IP6HDR_DSCP]		= HDR_BITFIELD("dscp", &dscp_type, 4, 6),
- 		[IP6HDR_ECN]		= HDR_BITFIELD("ecn", &ecn_type, 10, 2),
--- 
-2.11.0
-
diff --git a/meta-openembedded/meta-networking/recipes-filter/nftables/files/0006-payload-enforce-ip-ip6-protocol-depending-on-icmp-or.patch b/meta-openembedded/meta-networking/recipes-filter/nftables/files/0006-payload-enforce-ip-ip6-protocol-depending-on-icmp-or.patch
deleted file mode 100644
index 00076d7..0000000
--- a/meta-openembedded/meta-networking/recipes-filter/nftables/files/0006-payload-enforce-ip-ip6-protocol-depending-on-icmp-or.patch
+++ /dev/null
@@ -1,84 +0,0 @@
-From f21a7a4849b50c30341ec571813bd7fe37040ad3 Mon Sep 17 00:00:00 2001
-From: Florian Westphal <fw@strlen.de>
-Date: Thu, 18 May 2017 13:30:54 +0200
-Subject: [PATCH 4/4] payload: enforce ip/ip6 protocol depending on icmp or
- icmpv6
-
-After some discussion with Pablo we agreed to treat icmp/icmpv6 specially.
-
-in the case of a rule like 'tcp dport 22' the inet, bridge and netdev
-families only care about the lower layer protocol.
-
-In the icmpv6 case however we'd like to also enforce an ipv6 protocol check
-(and ipv4 check in icmp case).
-
-This extends payload_gen_special_dependency() to consider this.
-With this patch:
-
-add rule $pf filter input meta l4proto icmpv6
-add rule $pf filter input meta l4proto icmpv6 icmpv6 type echo-request
-add rule $pf filter input icmpv6 type echo-request
-
-will work in all tables and all families.
-For inet/bridge/netdev, an ipv6 protocol dependency is added; this will
-not match ipv4 packets with ip->protocol == icmpv6, EXCEPT in the case
-of the ip family.
-
-Its still possible to match icmpv6-in-ipv4 in inet/bridge/netdev with an
-explicit dependency:
-
-add rule inet f i ip protocol ipv6-icmp meta l4proto ipv6-icmp icmpv6 type ...
-
-Implicit dependencies won't get removed at the moment, so
-  bridge ... icmp type echo-request
-will be shown as
-  ether type ip meta l4proto 1 icmp type echo-request
-
-Signed-off-by: Florian Westphal <fw@strlen.de>
----
-Upstream-Status: Backport
-Signed-off-by: André Draszik <adraszik@tycoint.com>
- src/payload.c | 27 +++++++++++++++++++++++----
- 1 file changed, 23 insertions(+), 4 deletions(-)
-
-diff --git a/src/payload.c b/src/payload.c
-index 38db15e..8796ee5 100644
---- a/src/payload.c
-+++ b/src/payload.c
-@@ -264,10 +264,29 @@ payload_gen_special_dependency(struct eval_ctx *ctx, const struct expr *expr)
- 	case PROTO_BASE_LL_HDR:
- 		return payload_get_get_ll_hdr(ctx);
- 	case PROTO_BASE_TRANSPORT_HDR:
--		if (expr->payload.desc == &proto_icmp)
--			return &proto_ip;
--		if (expr->payload.desc == &proto_icmp6)
--			return &proto_ip6;
-+		if (expr->payload.desc == &proto_icmp ||
-+		    expr->payload.desc == &proto_icmp6) {
-+			const struct proto_desc *desc, *desc_upper;
-+			struct stmt *nstmt;
-+
-+			desc = ctx->pctx.protocol[PROTO_BASE_LL_HDR].desc;
-+			if (!desc) {
-+				desc = payload_get_get_ll_hdr(ctx);
-+				if (!desc)
-+					break;
-+			}
-+
-+			desc_upper = &proto_ip6;
-+			if (expr->payload.desc == &proto_icmp)
-+				desc_upper = &proto_ip;
-+
-+			if (payload_add_dependency(ctx, desc, desc_upper,
-+						   expr, &nstmt) < 0)
-+				return NULL;
-+
-+			list_add_tail(&nstmt->list, &ctx->stmt->list);
-+			return desc_upper;
-+		}
- 		return &proto_inet_service;
- 	default:
- 		break;
--- 
-2.11.0
-
diff --git a/meta-openembedded/meta-networking/recipes-filter/nftables/files/0007-src-ip-switch-implicit-dependencies-to-meta-l4proto-.patch b/meta-openembedded/meta-networking/recipes-filter/nftables/files/0007-src-ip-switch-implicit-dependencies-to-meta-l4proto-.patch
deleted file mode 100644
index 5b72437..0000000
--- a/meta-openembedded/meta-networking/recipes-filter/nftables/files/0007-src-ip-switch-implicit-dependencies-to-meta-l4proto-.patch
+++ /dev/null
@@ -1,86 +0,0 @@
-From 0825c57d571bb7121e7048e198b9b023f7e7f358 Mon Sep 17 00:00:00 2001
-From: Florian Westphal <fw@strlen.de>
-Date: Sun, 7 May 2017 03:53:30 +0200
-Subject: [PATCH] src: ip: switch implicit dependencies to meta l4proto too
-
-after ip6 nexthdr also switch ip to meta l4proto instead of ip protocol.
-
-While its needed for ipv6 (due to extension headers) this isn't needed
-for ip but it has the advantage that
-
-tcp dport 22
-
-produces same expressions for ip/ip6/inet families.
-
-Signed-off-by: Florian Westphal <fw@strlen.de>
----
-Upstream-Status: Backport
-Signed-off-by: André Draszik <adraszik@tycoint.com>
- src/payload.c | 17 +++++++++++------
- src/proto.c   |  3 ++-
- 2 files changed, 13 insertions(+), 7 deletions(-)
-
-diff --git a/src/payload.c b/src/payload.c
-index 8796ee5..11b6df3 100644
---- a/src/payload.c
-+++ b/src/payload.c
-@@ -118,17 +118,22 @@ static const struct expr_ops payload_expr_ops = {
- };
- 
- /*
-- * ipv6 is special case, we normally use 'meta l4proto' to fetch the last
-- * l4 header of the ipv6 extension header chain so we will also match
-+ * We normally use 'meta l4proto' to fetch the last l4 header of the
-+ * ipv6 extension header chain so we will also match
-  * tcp after a fragmentation header, for instance.
-+ * For consistency we also use meta l4proto for ipv4.
-  *
-- * If user specifically asks for nexthdr x, treat is as a full
-- * dependency rather than injecting another (useless) meta l4 one.
-+ * If user specifically asks for nexthdr x, don't add another (useless)
-+ * meta dependency.
-  */
- static bool proto_key_is_protocol(const struct proto_desc *desc, unsigned int type)
- {
--	if (type == desc->protocol_key ||
--	    (desc == &proto_ip6 && type == IP6HDR_NEXTHDR))
-+	if (type == desc->protocol_key)
-+		return true;
-+
-+	if (desc == &proto_ip6 && type == IP6HDR_NEXTHDR)
-+		return true;
-+	if (desc == &proto_ip && type == IPHDR_PROTOCOL)
- 		return true;
- 
- 	return false;
-diff --git a/src/proto.c b/src/proto.c
-index 3b20a5f..2afedf7 100644
---- a/src/proto.c
-+++ b/src/proto.c
-@@ -587,7 +587,6 @@ const struct proto_desc proto_ip = {
- 	.name		= "ip",
- 	.base		= PROTO_BASE_NETWORK_HDR,
- 	.checksum_key	= IPHDR_CHECKSUM,
--	.protocol_key	= IPHDR_PROTOCOL,
- 	.protocols	= {
- 		PROTO_LINK(IPPROTO_ICMP,	&proto_icmp),
- 		PROTO_LINK(IPPROTO_ESP,		&proto_esp),
-@@ -600,6 +599,7 @@ const struct proto_desc proto_ip = {
- 		PROTO_LINK(IPPROTO_SCTP,	&proto_sctp),
- 	},
- 	.templates	= {
-+		[0]	= PROTO_META_TEMPLATE("l4proto", &inet_protocol_type, NFT_META_L4PROTO, 8),
- 		[IPHDR_VERSION]		= HDR_BITFIELD("version", &integer_type, 0, 4),
- 		[IPHDR_HDRLENGTH]	= HDR_BITFIELD("hdrlength", &integer_type, 4, 4),
- 		[IPHDR_DSCP]            = HDR_BITFIELD("dscp", &dscp_type, 8, 6),
-@@ -779,6 +779,7 @@ const struct proto_desc proto_inet_service = {
- 		PROTO_LINK(IPPROTO_TCP,		&proto_tcp),
- 		PROTO_LINK(IPPROTO_DCCP,	&proto_dccp),
- 		PROTO_LINK(IPPROTO_SCTP,	&proto_sctp),
-+		PROTO_LINK(IPPROTO_ICMP,	&proto_icmp),
- 		PROTO_LINK(IPPROTO_ICMPV6,	&proto_icmp6),
- 	},
- 	.templates	= {
--- 
-2.11.0
-
diff --git a/meta-openembedded/meta-networking/recipes-filter/nftables/files/fix-to-generate-ntf.8.patch b/meta-openembedded/meta-networking/recipes-filter/nftables/files/fix-to-generate-ntf.8.patch
deleted file mode 100644
index 8dce90a..0000000
--- a/meta-openembedded/meta-networking/recipes-filter/nftables/files/fix-to-generate-ntf.8.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-[PATCH] disable to make ntf.8 man
-
-Upstream-Status: Pending
-
-$DB2MAN do not support the xinclude parameter whether it is
-docbook2x-man or other, so disable to make ntf.8 man
-
-Signed-off-by: Roy Li <rongqing.li@windriver.com>
----
- doc/Makefile.am | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/doc/Makefile.am b/doc/Makefile.am
-index a92de7f..537c36b 100644
---- a/doc/Makefile.am
-+++ b/doc/Makefile.am
-@@ -1,5 +1,5 @@
- if BUILD_MAN
--man_MANS = nft.8
-+#man_MANS = nft.8
- endif
- 
- if BUILD_PDF
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-networking/recipes-filter/nftables/nftables_0.7.bb b/meta-openembedded/meta-networking/recipes-filter/nftables/nftables_0.7.bb
deleted file mode 100644
index 0ea7995..0000000
--- a/meta-openembedded/meta-networking/recipes-filter/nftables/nftables_0.7.bb
+++ /dev/null
@@ -1,27 +0,0 @@
-SUMMARY = "Netfilter Tables userspace utillites"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d1a78fdd879a263a5e0b42d1fc565e79"
-SECTION = "net"
-
-DEPENDS = "libmnl libnftnl readline gmp"
-RRECOMMENDS_${PN} += "kernel-module-nf-tables \
-    "
-
-SRC_URI = "http://www.netfilter.org/projects/nftables/files/${BP}.tar.bz2 \
-           file://fix-to-generate-ntf.8.patch \
-           \
-           file://0001-payload-explicit-network-ctx-assignment-for-icmp-icm.patch \
-           file://0002-proto-Add-some-exotic-ICMPv6-types.patch \
-           \
-           file://0003-payload-split-ll-proto-dependency-into-helper.patch \
-           file://0004-src-allow-update-of-net-base-w.-meta-l4proto-icmpv6.patch \
-           file://0005-src-ipv6-switch-implicit-dependencies-to-meta-l4prot.patch \
-           file://0006-payload-enforce-ip-ip6-protocol-depending-on-icmp-or.patch \
-           file://0007-src-ip-switch-implicit-dependencies-to-meta-l4proto-.patch \
-          "
-SRC_URI[md5sum] = "4c005e76a15a029afaba71d7db21d065"
-SRC_URI[sha256sum] = "fe639239d801ce5890397f6f4391c58a934bfc27d8b7d5ef922692de5ec4ed43"
-
-ASNEEDED = ""
-
-inherit autotools pkgconfig
diff --git a/meta-openembedded/meta-networking/recipes-filter/nftables/nftables_0.9.0.bb b/meta-openembedded/meta-networking/recipes-filter/nftables/nftables_0.9.0.bb
new file mode 100644
index 0000000..aadf4f7
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-filter/nftables/nftables_0.9.0.bb
@@ -0,0 +1,20 @@
+SUMMARY = "Netfilter Tables userspace utillites"
+SECTION = "net"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d1a78fdd879a263a5e0b42d1fc565e79"
+
+DEPENDS = "libmnl libnftnl readline gmp bison-native"
+
+SRC_URI = "http://www.netfilter.org/projects/nftables/files/${BP}.tar.bz2 \
+           "
+SRC_URI[md5sum] = "d4dcb61df80aa544b2e142e91d937635"
+SRC_URI[sha256sum] = "ad8181b5fcb9ca572f444bed54018749588522ee97e4c21922648bb78d7e7e91"
+
+inherit autotools manpages pkgconfig
+
+PACKAGECONFIG ?= ""
+PACKAGECONFIG[man] = "--enable--man-doc, --disable-man-doc"
+
+ASNEEDED = ""
+
+RRECOMMENDS_${PN} += "kernel-module-nf-tables"
diff --git a/meta-openembedded/meta-networking/recipes-irc/znc/znc_git.bb b/meta-openembedded/meta-networking/recipes-irc/znc/znc_git.bb
index c2d7156..8c6979c 100644
--- a/meta-openembedded/meta-networking/recipes-irc/znc/znc_git.bb
+++ b/meta-openembedded/meta-networking/recipes-irc/znc/znc_git.bb
@@ -5,13 +5,13 @@
 
 DEPENDS = "openssl zlib icu"
 
-PV = "1.6.0"
+PV = "1.7.1"
 
 SRC_URI = "git://github.com/znc/znc.git;name=znc \
            git://github.com/jimloco/Csocket.git;destsuffix=git/third_party/Csocket;name=Csocket \
           "
-SRCREV_znc = "f47e8465efa4e1cd948b9caae93ac401b4355df8"
-SRCREV_Csocket = "07b4437396122650e5b8fb3d014e820a5decf4ee"
+SRCREV_znc = "c426898b3a1b899dfe8a8b2a3eeb4b18d8be1bf2"
+SRCREV_Csocket = "e8d9e0bb248c521c2c7fa01e1c6a116d929c41b4"
 
 # This constructs a composite revision based on multiple SRCREV's.
 #
diff --git a/meta-openembedded/meta-networking/recipes-netkit/netkit-rpc/netkit-rpc_0.17.bb b/meta-openembedded/meta-networking/recipes-netkit/netkit-rpc/netkit-rpc_0.17.bb
index 9487fdc..ebe867d 100644
--- a/meta-openembedded/meta-networking/recipes-netkit/netkit-rpc/netkit-rpc_0.17.bb
+++ b/meta-openembedded/meta-networking/recipes-netkit/netkit-rpc/netkit-rpc_0.17.bb
@@ -4,15 +4,15 @@
 LICENSE = "SPL-1.0"
 LIC_FILES_CHKSUM = "file://rpcinfo/rpcinfo.c;beginline=2;endline=3;md5=3e6339e3ce266e1122c5ba293e04bc89"
 
-DEPENDS_append_libc-musl = " libtirpc"
+DEPENDS += "libtirpc"
 SRC_URI = "http://sources.openembedded.org/${BPN}-${PV}.tar.gz \
            file://gcc4.patch \
            file://0001-rpcgen-Fix-printf-formats.patch \
            "
 SRC_URI[md5sum] = "67212720482ea1aea9182a98653a9642"
 SRC_URI[sha256sum] = "421d63b414162237a72867061f1bd3e3752a0d962cd5d30b5e933ddad8a14d3b"
-CFLAGS_append_libc-musl = " -I${STAGING_INCDIR}/tirpc"
-LIBS_append_libc-musl = " -ltirpc"
+CFLAGS += "-I${STAGING_INCDIR}/tirpc"
+LIBS += "-ltirpc"
 
 do_configure () {
     ./configure --prefix=${prefix}
diff --git a/meta-openembedded/meta-networking/recipes-netkit/netkit-rsh/netkit-rsh_0.17.bb b/meta-openembedded/meta-networking/recipes-netkit/netkit-rsh/netkit-rsh_0.17.bb
index 3990f7b..03dd963 100644
--- a/meta-openembedded/meta-networking/recipes-netkit/netkit-rsh/netkit-rsh_0.17.bb
+++ b/meta-openembedded/meta-networking/recipes-netkit/netkit-rsh/netkit-rsh_0.17.bb
@@ -2,7 +2,7 @@
 SECTION = "net"
 HOMEPAGE="ftp://ftp.uk.linux.org/pub/linux/Networking/netkit"
 LICENSE = "BSD-4-Clause"
-DEPENDS = "xinetd libgcrypt"
+DEPENDS = "xinetd libgcrypt virtual/crypt"
 
 LIC_FILES_CHKSUM = "file://rsh/rsh.c;endline=32;md5=487b3c637bdc181d32b2a8543d41b606"
 
@@ -100,3 +100,6 @@
 
 RDEPENDS_${PN}-server = "xinetd"
 RDEPENDS_${PN}-server += "tcp-wrappers"
+
+# http://errors.yoctoproject.org/Errors/Details/186963/
+EXCLUDE_FROM_WORLD_libc-musl = "1"
diff --git a/meta-openembedded/meta-networking/recipes-netkit/netkit-rusers/netkit-rusers/0001-Link-with-libtirpc.patch b/meta-openembedded/meta-networking/recipes-netkit/netkit-rusers/netkit-rusers/0001-Link-with-libtirpc.patch
new file mode 100644
index 0000000..5592646
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-netkit/netkit-rusers/netkit-rusers/0001-Link-with-libtirpc.patch
@@ -0,0 +1,79 @@
+From 5746b68ba9dda87586b3ac88fe84031cbc0015f7 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 11 May 2018 12:20:03 -0700
+Subject: [PATCH] Link with libtirpc
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ configure                 | 2 +-
+ rpc.rusersd/rusers_proc.c | 7 +------
+ rpc.rusersd/rusersd.c     | 6 +-----
+ rup/rup.c                 | 2 +-
+ 4 files changed, 4 insertions(+), 13 deletions(-)
+
+diff --git a/configure b/configure
+index 85f6ca6..2d2d4b7 100755
+--- a/configure
++++ b/configure
+@@ -147,7 +147,7 @@ else
+ fi
+ 
+ LDFLAGS=
+-LIBS=
++LIBS="-ltirpc"
+ 
+ rm -f __conftest*
+ 
+diff --git a/rpc.rusersd/rusers_proc.c b/rpc.rusersd/rusers_proc.c
+index 9ae6306..f9e237c 100644
+--- a/rpc.rusersd/rusers_proc.c
++++ b/rpc.rusersd/rusers_proc.c
+@@ -57,12 +57,7 @@ char rp_rcsid[] =
+ 	#define RUT_TIME ut_time
+ #endif
+ 
+-/* Glibc strikes again */
+-#ifdef __GLIBC__
+-	#include <rpcsvc/rusers.h>
+-#else
+-	#include "rusers.h"
+-#endif 
++#include "rusers.h"
+ 
+ void rusers_service(struct svc_req *rqstp, SVCXPRT *transp);
+ 
+diff --git a/rpc.rusersd/rusersd.c b/rpc.rusersd/rusersd.c
+index 762be9b..dd355ac 100644
+--- a/rpc.rusersd/rusersd.c
++++ b/rpc.rusersd/rusersd.c
+@@ -38,11 +38,7 @@ char rusersd_rcsid[] =
+ #include <rpc/pmap_clnt.h>
+ #include <unistd.h>
+ #include <grp.h>
+-#ifdef __GLIBC__
+-	#include <rpcsvc/rusers.h>
+-#else
+-	#include "rusers.h"
+-#endif
++#include "rusers.h"
+ 
+ #include "../version.h"
+ 
+diff --git a/rup/rup.c b/rup/rup.c
+index e5669ff..887f89d 100644
+--- a/rup/rup.c
++++ b/rup/rup.c
+@@ -48,7 +48,7 @@ char rcsid[] = "$Id: rup.c,v 1.8 2000/07/22 19:51:40 dholland Exp $";
+ 
+ #undef FSHIFT			/* Use protocol's shift and scale values */
+ #undef FSCALE
+-#include <rpcsvc/rstat.h>
++#include "rstat.h"
+ 
+ #include "../version.h"
+ 
+-- 
+2.17.0
+
diff --git a/meta-openembedded/meta-networking/recipes-netkit/netkit-rusers/netkit-rusers_0.17.bb b/meta-openembedded/meta-networking/recipes-netkit/netkit-rusers/netkit-rusers_0.17.bb
index 459e39e..9b8af27 100644
--- a/meta-openembedded/meta-networking/recipes-netkit/netkit-rusers/netkit-rusers_0.17.bb
+++ b/meta-openembedded/meta-networking/recipes-netkit/netkit-rusers/netkit-rusers_0.17.bb
@@ -9,6 +9,7 @@
 SRC_URI = "http://http.debian.net/debian/pool/main/n/${BPN}/${BPN}_${PV}.orig.tar.gz;name=archive \
            http://http.debian.net/debian/pool/main/n/${BPN}/${BPN}_${PV}-8.diff.gz;name=patch8 \
            file://rpc.rusersd-Makefile-fix-parallel-build-issue.patch \
+           file://0001-Link-with-libtirpc.patch \
 "
 
 SRC_URI[archive.md5sum] = "dc99a80b9fde2ab427c874f88f1c1602"
@@ -18,10 +19,14 @@
 
 inherit autotools-brokensep
 
+CFLAGS += "-I${STAGING_INCDIR}/tirpc"
+LIBS += "-ltirpc"
+
 do_configure () {
     ./configure --prefix=${prefix}
     echo "LDFLAGS=${LDFLAGS}" >> MCONFIG
     echo "USE_GLIBC=1" >> MCONFIG
+    echo "LIBS=${LIBS}" >> MCONFIG
 }
 
 do_install () {
@@ -68,3 +73,6 @@
             ${bindir}/.debug ${sbindir}/.debug"
 
 RDEPENDS_${PN}-server = "tcp-wrappers xinetd rpcbind"
+
+# http://errors.yoctoproject.org/Errors/Details/186962/
+EXCLUDE_FROM_WORLD_libc-musl = "1"
diff --git a/meta-openembedded/meta-networking/recipes-netkit/netkit-telnet/files/0001-telnet-telnetd-Fix-deadlock-on-cleanup.patch b/meta-openembedded/meta-networking/recipes-netkit/netkit-telnet/files/0001-telnet-telnetd-Fix-deadlock-on-cleanup.patch
new file mode 100644
index 0000000..945785d
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-netkit/netkit-telnet/files/0001-telnet-telnetd-Fix-deadlock-on-cleanup.patch
@@ -0,0 +1,114 @@
+From 06ed6a6bf25a22902846097d6b6c97e070c2c326 Mon Sep 17 00:00:00 2001
+From: Seiichi Ishitsuka <ishitsuka.sc@ncos.nec.co.jp>
+Date: Fri, 1 Jun 2018 14:27:35 +0900
+Subject: [PATCH] telnetd: Fix deadlock on cleanup
+
+The cleanup function in telnetd is called both directly and on SIGCHLD
+signals. This, unfortunately, triggered a deadlock in eglibc 2.9 while
+running on a 2.6.31.11 kernel.
+
+What we were seeing is hangs like these:
+
+  (gdb) bt
+  #0  0xb7702424 in __kernel_vsyscall ()
+  #1  0xb7658e61 in __lll_lock_wait_private () from ./lib/libc.so.6
+  #2  0xb767e7b5 in _L_lock_15 () from ./lib/libc.so.6
+  #3  0xb767e6e0 in utmpname () from ./lib/libc.so.6
+  #4  0xb76bcde7 in logout () from ./lib/libutil.so.1
+  #5  0x0804c827 in cleanup ()
+  #6  <signal handler called>
+  #7  0xb7702424 in __kernel_vsyscall ()
+  #8  0xb7641003 in __fcntl_nocancel () from ./lib/libc.so.6
+  #9  0xb767e0c3 in getutline_r_file () from ./lib/libc.so.6
+  #10 0xb767d675 in getutline_r () from ./lib/libc.so.6
+  #11 0xb76bce42 in logout () from ./lib/libutil.so.1
+  #12 0x0804c827 in cleanup ()
+  #13 0x0804a0b5 in telnet ()
+  #14 0x0804a9c3 in main ()
+
+and what has happened here is that the user closes the telnet session
+via the escape character. This causes telnetd to call cleanup in frame
+the SIGCHLD signal is delivered while telnetd is executing cleanup.
+
+Telnetd then calls the signal handler for SIGCHLD, which is cleanup().
+Ouch. The actual deadlock is in libc. getutline_r in frame #10 gets the
+__libc_utmp_lock lock, and utmpname above does the same thing in frame
+
+The fix registers the SIGCHLD handler as cleanup_sighandler, and makes
+cleanup disable the SIGCHLD signal before calling cleanup_sighandler.
+
+Signed-off-by: Simon Kagstrom <simon.kagstrom@netinsight.net>
+
+The patch was imported from the Ubuntu netkit-telnet package.
+(https://bugs.launchpad.net/ubuntu/+source/netkit-telnet/+bug/507455)
+
+A previous patch declaring attributes of functions, but it is not used
+in upstream.
+
+Signed-off-by: Seiichi Ishitsuka <ishitsuka.sc@ncos.nec.co.jp>
+---
+ telnetd/ext.h      |  1 +
+ telnetd/sys_term.c | 17 ++++++++++++++++-
+ telnetd/telnetd.c  |  2 +-
+ 3 files changed, 18 insertions(+), 2 deletions(-)
+
+diff --git a/telnetd/ext.h b/telnetd/ext.h
+index b98d6ec..08f9d07 100644
+--- a/telnetd/ext.h
++++ b/telnetd/ext.h
+@@ -97,6 +97,7 @@ void add_slc(int, int, int);
+ void check_slc(void);
+ void change_slc(int, int, int);
+ void cleanup(int);
++void cleanup_sighandler(int);
+ void clientstat(int, int, int);
+ void copy_termbuf(char *, int);
+ void deferslc(void);
+diff --git a/telnetd/sys_term.c b/telnetd/sys_term.c
+index 5b4aa84..c4fb0f7 100644
+--- a/telnetd/sys_term.c
++++ b/telnetd/sys_term.c
+@@ -719,7 +719,7 @@ static void addarg(struct argv_stuff *avs, const char *val) {
+  * This is the routine to call when we are all through, to
+  * clean up anything that needs to be cleaned up.
+  */
+-void cleanup(int sig) {
++void cleanup_sighandler(int sig) {
+     char *p;
+     (void)sig;
+ 
+@@ -742,3 +742,18 @@ void cleanup(int sig) {
+     shutdown(net, 2);
+     exit(0);
+ }
++
++void cleanup(int sig) {
++    sigset_t mask, oldmask;
++
++    /* Set up the mask of signals to temporarily block. */
++    sigemptyset (&mask);
++    sigaddset (&mask, SIGCHLD);
++
++    /* Block SIGCHLD while running cleanup */
++    sigprocmask (SIG_BLOCK, &mask, &oldmask);
++
++    cleanup_sighandler(sig);
++    /* Technically not needed since cleanup_sighandler exits */
++    sigprocmask (SIG_UNBLOCK, &mask, NULL);
++}
+diff --git a/telnetd/telnetd.c b/telnetd/telnetd.c
+index 9ace838..788919c 100644
+--- a/telnetd/telnetd.c
++++ b/telnetd/telnetd.c
+@@ -833,7 +833,7 @@ void telnet(int f, int p)
+     signal(SIGTTOU, SIG_IGN);
+ #endif
+     
+-    signal(SIGCHLD, cleanup);
++    signal(SIGCHLD, cleanup_sighandler);
+     
+ #ifdef TIOCNOTTY
+     {
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-netkit/netkit-telnet/netkit-telnet_0.17.bb b/meta-openembedded/meta-networking/recipes-netkit/netkit-telnet/netkit-telnet_0.17.bb
index 807b566..db4b1c9 100644
--- a/meta-openembedded/meta-networking/recipes-netkit/netkit-telnet/netkit-telnet_0.17.bb
+++ b/meta-openembedded/meta-networking/recipes-netkit/netkit-telnet/netkit-telnet_0.17.bb
@@ -5,14 +5,18 @@
 LICENSE = "BSD"
 LIC_FILES_CHKSUM = "file://telnet/telnet.cc;beginline=2;endline=3;md5=780868e7b566313e70cb701560ca95ef"
 
-SRC_URI = "ftp://ftp.uk.linux.org/pub/linux/Networking/netkit/${BP}.tar.gz \
+SRC_URI = "http://ftp.linux.org.uk/pub/linux/Networking/netkit/${BP}.tar.gz \
            file://To-aviod-buffer-overflow-in-telnet.patch \
            file://Warning-fix-in-the-step-of-install.patch \
            file://telnet-xinetd \
            file://cross-compile.patch \
            file://0001-telnet-telnetd-Fix-print-format-strings.patch \
+           file://0001-telnet-telnetd-Fix-deadlock-on-cleanup.patch \
            "
 
+UPSTREAM_CHECK_URI = "${DEBIAN_MIRROR}/main/n/netkit-telnet/"
+UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)\.orig\.tar"
+
 EXTRA_OEMAKE = "INSTALLROOT=${D} SBINDIR=${sbindir} DAEMONMODE=755 \
     MANMODE=644 MANDIR=${mandir}"
 
@@ -46,16 +50,16 @@
     install -p -m644 ${WORKDIR}/telnet-xinetd ${D}/etc/xinetd.d/telnet
 }
 
-pkg_postinst_${PN} () {
-#!/bin/sh
-    update-alternatives --install ${bindir}/telnet telnet telnet.${PN} 100
-}
+inherit update-alternatives
 
-pkg_prerm_${PN} () {
-#!/bin/sh
-    update-alternatives --remove telnet telnet.${PN} 100
-}
+ALTERNATIVE_PRIORITY = "100"
+ALTERNATIVE_${PN} = "telnet"
+ALTERNATIVE_LINK_NAME[telnet] = "${bindir}/telnet"
+ALTERNATIVE_TARGET[telnet] = "${bindir}/telnet.${PN}"
 
 SRC_URI[md5sum] = "d6beabaaf53fe6e382c42ce3faa05a36"
 SRC_URI[sha256sum] = "9c80d5c7838361a328fb6b60016d503def9ce53ad3c589f3b08ff71a2bb88e00"
 FILES_${PN} += "${sbindir}/in.* ${libdir}/* ${sysconfdir}/xinetd.d/*"
+
+# http://errors.yoctoproject.org/Errors/Details/186954/
+EXCLUDE_FROM_WORLD_libc-musl = "1"
diff --git a/meta-openembedded/meta-networking/recipes-protocols/babeld/babeld_1.8.3.bb b/meta-openembedded/meta-networking/recipes-protocols/babeld/babeld_1.8.3.bb
new file mode 100644
index 0000000..8f02847
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-protocols/babeld/babeld_1.8.3.bb
@@ -0,0 +1,27 @@
+SUMMARY = "Babel is a loop-avoiding distance-vector routing protocol"
+DESCRIPTION = "\
+Babel is a loop-avoiding distance-vector routing protocol for IPv6 and \
+IPv4 with fast convergence properties. It is based on the ideas in DSDV, AODV \
+and Cisco's EIGRP, but is designed to work well not only in wired networks \
+but also in wireless mesh networks, and has been extended with support \
+for overlay networks. Babel is in the process of becoming an IETF Standard. \
+"
+HOMEPAGE = "https://www.irif.fr/~jch/software/babel/"
+SECTION = "net"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENCE;md5=411a48ac3c2e9e0911b8dd9aed26f754"
+
+SRC_URI = "git://github.com/jech/babeld.git;protocol=git"
+SRCREV = "535184173fcde5ddc43020cd197d01d1ea0e9a8b"
+
+S = "${WORKDIR}/git"
+
+do_compile () {
+	oe_runmake babeld
+}
+
+do_install () {
+	oe_runmake install.minimal PREFIX=${D}
+}
+
diff --git a/meta-openembedded/meta-networking/recipes-protocols/freediameter/files/0001-libfdcore-sctp.c-update-the-old-sctp-api-check.patch b/meta-openembedded/meta-networking/recipes-protocols/freediameter/files/0001-libfdcore-sctp.c-update-the-old-sctp-api-check.patch
new file mode 100644
index 0000000..d5e242a
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-protocols/freediameter/files/0001-libfdcore-sctp.c-update-the-old-sctp-api-check.patch
@@ -0,0 +1,97 @@
+From d527a0b7b63e43263384540b5525714484bb089f Mon Sep 17 00:00:00 2001
+From: Mingli Yu <Mingli.Yu@windriver.com>
+Date: Mon, 3 Sep 2018 14:40:56 +0800
+Subject: [PATCH] libfdcore/sctp.c: update the old sctp api check
+
+The initial sctp api check for freediameter as below:
+ ===
+ commit d3c5e991cb532ea09684d69fb4d0d58e9bc39a0c
+  Author: Sebastien Decugis <sdecugis@freediameter.net>
+  Date:   Mon Jun 3 12:05:37 2013 +0800
+    
+    Add some compliancy to RFC6458. Not tested however as Ubuntu does not support this yet
+    
+    [snip]
+    +/* Use old draft-ietf-tsvwg-sctpsocket-17 API ? If not defined, RFC6458 API will be used */
+    +/* #define OLD_SCTP_SOCKET_API */
+    +
+    +/* Automatically fallback to old API if some of the new symbols are not defined */
+    +#if (!defined(SCTP_CONNECTX_4_ARGS) || (!defined(SCTP_RECVRCVINFO)) || (!defined(SCTP_SNDINFO)))
+    +# define OLD_SCTP_SOCKET_API
+    +#endif
+ ===
+
+SCTP_RECVRCVINFO is defined in <linux/sctp.h>,
+but <linux/sctp.h> is't included in the source code
+previouly. So defined(SCTP_RECVRCVINFO) can be 0 
+and it make old sctp socket api definiton in effect 
+as below:
+ # define OLD_SCTP_SOCKET_API
+
+After lksctp-tools upgrade to 1.0.18, there is below
+commit introduced:
+===
+commit 3c8bd0d26b64611c690f33f5802c734b0642c1d8
+Author: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
+Date:   Tue Apr 17 20:17:14 2018 -0300
+
+    sctp.h: make use kernel UAPI header
+
+    and with that, remove tons of duplicated declarations. These were
+    lagging behind the kernel header, which is always the most updated one,
+    and as the library is intended to be run only on Linux, there is no
+    reason that we cannot re-use what is in there.
+
+    That said, this patch drops all duplicated declarations and includes
+    linux/sctp.h to bring them into lksctp-tools.
+
+    Signed-off-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
+
+ [snip]
+ #include <stdint.h>
+ #include <linux/types.h>
+ #include <sys/socket.h>
++#include <linux/sctp.h>
+ [snip]
+===
+
+And above logic make defined(SCTP_RECVRCVINFO) to
+be 1 and the old sctp socket api macro as below
+won't be defined.
+ # define OLD_SCTP_SOCKET_API
+
+And it encouters below build error:
+| /build/freediameter/1.2.1-r0/freeDiameter-1.2.1/libfdcore/sctp.c:1262:9: error: 'SCTP_SEND_FAILED_EVENT' undeclared (first use in this function); did you mean 'SCTP_SEND_FAILED'?
+    case SCTP_SEND_FAILED_EVENT:
+         ^~~~~~~~~~~~~~~~~~~~~~
+         SCTP_SEND_FAILED
+| /build/freediameter/1.2.1-r0/freeDiameter-1.2.1/libfdcore/sctp.c:1262:9: note: each undeclared identifier is reported only once for each function it appears in
+| /build/freediameter/1.2.1-r0/freeDiameter-1.2.1/libfdcore/sctp.c:1274:9: error: 'SCTP_NOTIFICATIONS_STOPPED_EVENT' undeclared (first use in this function); did you mean 'SCTP_AUTHENTICATION_EVENT'?
+    case SCTP_NOTIFICATIONS_STOPPED_EVENT:
+
+Update the old sctp socket api check to fix
+the above build error.
+
+Upstream-Status: Pending
+
+Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
+---
+ libfdcore/sctp.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/libfdcore/sctp.c b/libfdcore/sctp.c
+index c80a497..83440c7 100644
+--- a/libfdcore/sctp.c
++++ b/libfdcore/sctp.c
+@@ -48,7 +48,7 @@
+ /* #define OLD_SCTP_SOCKET_API */
+ 
+ /* Automatically fallback to old API if some of the new symbols are not defined */
+-#if (!defined(SCTP_CONNECTX_4_ARGS) || (!defined(SCTP_RECVRCVINFO)) || (!defined(SCTP_SNDINFO))) 
++#if (!defined(SCTP_CONNECTX_4_ARGS) || (!defined(SCTP_NOTIFICATIONS_STOPPED_EVENT)) || (!defined(SCTP_SNDINFO)))
+ # define OLD_SCTP_SOCKET_API
+ #endif
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-protocols/freediameter/freediameter_1.2.1.bb b/meta-openembedded/meta-networking/recipes-protocols/freediameter/freediameter_1.2.1.bb
index c556eb4..b8818fa 100644
--- a/meta-openembedded/meta-networking/recipes-protocols/freediameter/freediameter_1.2.1.bb
+++ b/meta-openembedded/meta-networking/recipes-protocols/freediameter/freediameter_1.2.1.bb
@@ -7,7 +7,7 @@
 
 HOMEPAGE = "http://www.freediameter.net"
 
-DEPENDS = "flex bison cmake-native libgcrypt gnutls libidn lksctp-tools virtual/kernel"
+DEPENDS = "flex bison cmake-native libgcrypt gnutls libidn lksctp-tools virtual/kernel bison-native"
 
 PACKAGE_ARCH = "${MACHINE_ARCH}"
 
@@ -20,6 +20,7 @@
     file://freediameter.init \
     ${@bb.utils.contains('DISTRO_FEATURES', 'ptest', 'file://install_test.patch file://run-ptest file://pass-ptest-env.patch', '', d)} \
     file://freeDiameter.conf \
+    file://0001-libfdcore-sctp.c-update-the-old-sctp-api-check.patch \
     "
 
 SRC_URI[md5sum] = "61b1062aa144b5f12eed514611e6d697"
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-BUG-a2584-Fix-snmptrap-to-use-clientaddr-from-snmp.c.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-BUG-a2584-Fix-snmptrap-to-use-clientaddr-from-snmp.c.patch
deleted file mode 100644
index b14b761..0000000
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-BUG-a2584-Fix-snmptrap-to-use-clientaddr-from-snmp.c.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-From a92628a163ebf1ea62220684736300461c003875 Mon Sep 17 00:00:00 2001
-From: Niels Baggesen <nba@users.sourceforge.net>
-Date: Mon, 26 Jan 2015 20:26:06 +0100
-Subject: [PATCH] BUG#a2584: Fix snmptrap to use clientaddr from snmp.conf.
- Thanks to rizwan
-
-Upstream-Status: backport
-
-Signed-off-by: Li Zhou <li.zhou@windriver.com>
----
- snmplib/transports/snmpUDPIPv6Domain.c | 21 +++++++++++++++++++++
- 1 file changed, 21 insertions(+)
-
-Index: net-snmp-5.7.3/snmplib/transports/snmpUDPIPv6Domain.c
-===================================================================
---- net-snmp-5.7.3.orig/snmplib/transports/snmpUDPIPv6Domain.c
-+++ net-snmp-5.7.3/snmplib/transports/snmpUDPIPv6Domain.c
-@@ -286,6 +286,27 @@ netsnmp_udp6_transport(struct sockaddr_i
-         return NULL;
- #endif /* NETSNMP_NO_LISTEN_SUPPORT */
-     } else {
-+        char           *client_socket = NULL;
-+        /*
-+         * This is a client session.  If we've been given a
-+         * client address to send from, then bind to that.
-+         * Otherwise the send will use "something sensible".
-+         */
-+
-+        client_socket = netsnmp_ds_get_string(NETSNMP_DS_LIBRARY_ID,
-+                                    NETSNMP_DS_LIB_CLIENT_ADDR);
-+        if (client_socket) {
-+            struct sockaddr_in6 client_addr;
-+            netsnmp_sockaddr_in6_2(&client_addr, client_socket, NULL);
-+            rc = bind(t->sock, (struct sockaddr *)&client_addr,
-+                              sizeof(struct sockaddr_in6));
-+            if ( rc != 0 ) {
-+                DEBUGMSGTL(("netsnmp_udp6", "failed to bind for clientaddr: %d %s\n",
-+                                 errno, strerror(errno)));
-+                netsnmp_socketbase_close(t);
-+                netsnmp_transport_free(t);
-+            }
-+        }
-         /*
-          * This is a client session.  Save the address in the
-          * transport-specific data pointer for later use by netsnmp_udp6_send.
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-Remove-U64-typedef.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-Remove-U64-typedef.patch
deleted file mode 100644
index 7314ab1..0000000
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-Remove-U64-typedef.patch
+++ /dev/null
@@ -1,2524 +0,0 @@
-net-snmp: remove U64 typedef
-
-From git://git.code.sf.net/p/net-snmp/code
-
-Upstream-Status: Backport (unmodified)
-
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
-
-From 477b4307ef12ddce3b6a9205e0bdddbfb2e0e9b6 Mon Sep 17 00:00:00 2001
-From: Bart Van Assche <bvanassche@acm.org>
-Date: Sat, 20 Feb 2016 18:58:18 -0800
-Subject: [PATCH 1/1] Remove U64 typedef
-
-The U64 typedef conflicts with a typedef in a Perl header file. Hence
-remove the U64 typedef from the Net-SNMP header files. This patch does
-not modify the Net-SNMP ABI.
----
- agent/mibgroup/if-mib/ifXTable/ifXTable.c          |  16 +-
- agent/mibgroup/if-mib/ifXTable/ifXTable.h          |  48 +-
- .../mibgroup/if-mib/ifXTable/ifXTable_interface.c  |  32 +-
- .../ip-mib/data_access/systemstats_common.c        |   2 +-
- .../ipIfStatsTable/ipIfStatsTable_data_get.c       |  28 +-
- .../ipIfStatsTable/ipIfStatsTable_data_get.h       |  28 +-
- .../ipIfStatsTable/ipIfStatsTable_interface.c      |  56 +-
- .../ip-mib/ipSystemStatsTable/ipSystemStatsTable.c |  28 +-
- .../ip-mib/ipSystemStatsTable/ipSystemStatsTable.h | 921 ++-------------------
- .../ipSystemStatsTable_interface.c                 |  56 +-
- include/net-snmp/data_access/ipstats.h             |  42 +-
- include/net-snmp/library/int64.h                   |  34 +-
- snmplib/int64.c                                    |  38 +-
- snmplib/read_config.c                              |   6 +-
- testing/fulltests/unit-tests/T015int64_clib.c      |  10 +-
- 15 files changed, 274 insertions(+), 1071 deletions(-)
-
-Index: net-snmp-5.7.3/agent/mibgroup/if-mib/ifXTable/ifXTable.c
-===================================================================
---- net-snmp-5.7.3.orig/agent/mibgroup/if-mib/ifXTable/ifXTable.c
-+++ net-snmp-5.7.3/agent/mibgroup/if-mib/ifXTable/ifXTable.c
-@@ -722,7 +722,7 @@ The total number of octets received on t
-  */
- int
- ifHCInOctets_get(ifXTable_rowreq_ctx * rowreq_ctx,
--                 U64 * ifHCInOctets_val_ptr)
-+                 struct counter64 *ifHCInOctets_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ifHCInOctets_val_ptr);
-@@ -779,7 +779,7 @@ The number of packets, delivered by this
-  */
- int
- ifHCInUcastPkts_get(ifXTable_rowreq_ctx * rowreq_ctx,
--                    U64 * ifHCInUcastPkts_val_ptr)
-+                    struct counter64 *ifHCInUcastPkts_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ifHCInUcastPkts_val_ptr);
-@@ -838,7 +838,7 @@ The number of packets, delivered by this
-  */
- int
- ifHCInMulticastPkts_get(ifXTable_rowreq_ctx * rowreq_ctx,
--                        U64 * ifHCInMulticastPkts_val_ptr)
-+                        struct counter64 *ifHCInMulticastPkts_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ifHCInMulticastPkts_val_ptr);
-@@ -897,7 +897,7 @@ The number of packets, delivered by this
-  */
- int
- ifHCInBroadcastPkts_get(ifXTable_rowreq_ctx * rowreq_ctx,
--                        U64 * ifHCInBroadcastPkts_val_ptr)
-+                        struct counter64 *ifHCInBroadcastPkts_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ifHCInBroadcastPkts_val_ptr);
-@@ -955,7 +955,7 @@ The total number of octets transmitted o
-  */
- int
- ifHCOutOctets_get(ifXTable_rowreq_ctx * rowreq_ctx,
--                  U64 * ifHCOutOctets_val_ptr)
-+                  struct counter64 *ifHCOutOctets_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ifHCOutOctets_val_ptr);
-@@ -1013,7 +1013,7 @@ The total number of packets that higher-
-  */
- int
- ifHCOutUcastPkts_get(ifXTable_rowreq_ctx * rowreq_ctx,
--                     U64 * ifHCOutUcastPkts_val_ptr)
-+                     struct counter64 *ifHCOutUcastPkts_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ifHCOutUcastPkts_val_ptr);
-@@ -1074,7 +1074,7 @@ The total number of packets that higher-
-  */
- int
- ifHCOutMulticastPkts_get(ifXTable_rowreq_ctx * rowreq_ctx,
--                         U64 * ifHCOutMulticastPkts_val_ptr)
-+                         struct counter64 *ifHCOutMulticastPkts_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ifHCOutMulticastPkts_val_ptr);
-@@ -1134,7 +1134,7 @@ The total number of packets that higher-
-  */
- int
- ifHCOutBroadcastPkts_get(ifXTable_rowreq_ctx * rowreq_ctx,
--                         U64 * ifHCOutBroadcastPkts_val_ptr)
-+                         struct counter64 *ifHCOutBroadcastPkts_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ifHCOutBroadcastPkts_val_ptr);
-Index: net-snmp-5.7.3/agent/mibgroup/if-mib/ifXTable/ifXTable.h
-===================================================================
---- net-snmp-5.7.3.orig/agent/mibgroup/if-mib/ifXTable/ifXTable.h
-+++ net-snmp-5.7.3/agent/mibgroup/if-mib/ifXTable/ifXTable.h
-@@ -143,28 +143,28 @@ config_require(if-mib/ifXTable/ifXTable_
-                                            u_long *
-                                            ifOutBroadcastPkts_val_ptr);
-     int             ifHCInOctets_get(ifXTable_rowreq_ctx * rowreq_ctx,
--                                     U64 * ifHCInOctets_val_ptr);
-+                                     struct counter64 *ifHCInOctets_val_ptr);
-     int             ifHCInUcastPkts_get(ifXTable_rowreq_ctx * rowreq_ctx,
--                                        U64 * ifHCInUcastPkts_val_ptr);
-+                                        struct counter64 *ifHCInUcastPkts_val_ptr);
-     int             ifHCInMulticastPkts_get(ifXTable_rowreq_ctx *
-                                             rowreq_ctx,
--                                            U64 *
-+                                            struct counter64 *
-                                             ifHCInMulticastPkts_val_ptr);
-     int             ifHCInBroadcastPkts_get(ifXTable_rowreq_ctx *
-                                             rowreq_ctx,
--                                            U64 *
-+                                            struct counter64 *
-                                             ifHCInBroadcastPkts_val_ptr);
-     int             ifHCOutOctets_get(ifXTable_rowreq_ctx * rowreq_ctx,
--                                      U64 * ifHCOutOctets_val_ptr);
-+                                      struct counter64 *ifHCOutOctets_val_ptr);
-     int             ifHCOutUcastPkts_get(ifXTable_rowreq_ctx * rowreq_ctx,
--                                         U64 * ifHCOutUcastPkts_val_ptr);
-+                                         struct counter64 *ifHCOutUcastPkts_val_ptr);
-     int             ifHCOutMulticastPkts_get(ifXTable_rowreq_ctx *
-                                              rowreq_ctx,
--                                             U64 *
-+                                             struct counter64 *
-                                              ifHCOutMulticastPkts_val_ptr);
-     int             ifHCOutBroadcastPkts_get(ifXTable_rowreq_ctx *
-                                              rowreq_ctx,
--                                             U64 *
-+                                             struct counter64 *
-                                              ifHCOutBroadcastPkts_val_ptr);
-     int             ifLinkUpDownTrapEnable_get(ifXTable_rowreq_ctx *
-                                                rowreq_ctx,
-@@ -284,86 +284,86 @@ config_require(if-mib/ifXTable/ifXTable_
- 
-     int             ifHCInOctets_check_value(ifXTable_rowreq_ctx *
-                                              rowreq_ctx,
--                                             U64 ifHCInOctets_val);
-+                                             struct counter64 ifHCInOctets_val);
-     int             ifHCInOctets_undo_setup(ifXTable_rowreq_ctx *
-                                             rowreq_ctx);
-     int             ifHCInOctets_set(ifXTable_rowreq_ctx * rowreq_ctx,
--                                     U64 ifHCInOctets_val);
-+                                     struct counter64 ifHCInOctets_val);
-     int             ifHCInOctets_undo(ifXTable_rowreq_ctx * rowreq_ctx);
- 
-     int             ifHCInUcastPkts_check_value(ifXTable_rowreq_ctx *
-                                                 rowreq_ctx,
--                                                U64 ifHCInUcastPkts_val);
-+                                                struct counter64 ifHCInUcastPkts_val);
-     int             ifHCInUcastPkts_undo_setup(ifXTable_rowreq_ctx *
-                                                rowreq_ctx);
-     int             ifHCInUcastPkts_set(ifXTable_rowreq_ctx * rowreq_ctx,
--                                        U64 ifHCInUcastPkts_val);
-+                                        struct counter64 ifHCInUcastPkts_val);
-     int             ifHCInUcastPkts_undo(ifXTable_rowreq_ctx * rowreq_ctx);
- 
-     int             ifHCInMulticastPkts_check_value(ifXTable_rowreq_ctx *
-                                                     rowreq_ctx,
--                                                    U64
-+                                                    struct counter64
-                                                     ifHCInMulticastPkts_val);
-     int             ifHCInMulticastPkts_undo_setup(ifXTable_rowreq_ctx *
-                                                    rowreq_ctx);
-     int             ifHCInMulticastPkts_set(ifXTable_rowreq_ctx *
-                                             rowreq_ctx,
--                                            U64 ifHCInMulticastPkts_val);
-+                                            struct counter64 ifHCInMulticastPkts_val);
-     int             ifHCInMulticastPkts_undo(ifXTable_rowreq_ctx *
-                                              rowreq_ctx);
- 
-     int             ifHCInBroadcastPkts_check_value(ifXTable_rowreq_ctx *
-                                                     rowreq_ctx,
--                                                    U64
-+                                                    struct counter64
-                                                     ifHCInBroadcastPkts_val);
-     int             ifHCInBroadcastPkts_undo_setup(ifXTable_rowreq_ctx *
-                                                    rowreq_ctx);
-     int             ifHCInBroadcastPkts_set(ifXTable_rowreq_ctx *
-                                             rowreq_ctx,
--                                            U64 ifHCInBroadcastPkts_val);
-+                                            struct counter64 ifHCInBroadcastPkts_val);
-     int             ifHCInBroadcastPkts_undo(ifXTable_rowreq_ctx *
-                                              rowreq_ctx);
- 
-     int             ifHCOutOctets_check_value(ifXTable_rowreq_ctx *
-                                               rowreq_ctx,
--                                              U64 ifHCOutOctets_val);
-+                                              struct counter64 ifHCOutOctets_val);
-     int             ifHCOutOctets_undo_setup(ifXTable_rowreq_ctx *
-                                              rowreq_ctx);
-     int             ifHCOutOctets_set(ifXTable_rowreq_ctx * rowreq_ctx,
--                                      U64 ifHCOutOctets_val);
-+                                      struct counter64 ifHCOutOctets_val);
-     int             ifHCOutOctets_undo(ifXTable_rowreq_ctx * rowreq_ctx);
- 
-     int             ifHCOutUcastPkts_check_value(ifXTable_rowreq_ctx *
-                                                  rowreq_ctx,
--                                                 U64 ifHCOutUcastPkts_val);
-+                                                 struct counter64 ifHCOutUcastPkts_val);
-     int             ifHCOutUcastPkts_undo_setup(ifXTable_rowreq_ctx *
-                                                 rowreq_ctx);
-     int             ifHCOutUcastPkts_set(ifXTable_rowreq_ctx * rowreq_ctx,
--                                         U64 ifHCOutUcastPkts_val);
-+                                         struct counter64 ifHCOutUcastPkts_val);
-     int             ifHCOutUcastPkts_undo(ifXTable_rowreq_ctx *
-                                           rowreq_ctx);
- 
-     int             ifHCOutMulticastPkts_check_value(ifXTable_rowreq_ctx *
-                                                      rowreq_ctx,
--                                                     U64
-+                                                     struct counter64
-                                                      ifHCOutMulticastPkts_val);
-     int             ifHCOutMulticastPkts_undo_setup(ifXTable_rowreq_ctx *
-                                                     rowreq_ctx);
-     int             ifHCOutMulticastPkts_set(ifXTable_rowreq_ctx *
-                                              rowreq_ctx,
--                                             U64 ifHCOutMulticastPkts_val);
-+                                             struct counter64 ifHCOutMulticastPkts_val);
-     int             ifHCOutMulticastPkts_undo(ifXTable_rowreq_ctx *
-                                               rowreq_ctx);
- 
-     int             ifHCOutBroadcastPkts_check_value(ifXTable_rowreq_ctx *
-                                                      rowreq_ctx,
--                                                     U64
-+                                                     struct counter64
-                                                      ifHCOutBroadcastPkts_val);
-     int             ifHCOutBroadcastPkts_undo_setup(ifXTable_rowreq_ctx *
-                                                     rowreq_ctx);
-     int             ifHCOutBroadcastPkts_set(ifXTable_rowreq_ctx *
-                                              rowreq_ctx,
--                                             U64 ifHCOutBroadcastPkts_val);
-+                                             struct counter64 ifHCOutBroadcastPkts_val);
-     int             ifHCOutBroadcastPkts_undo(ifXTable_rowreq_ctx *
-                                               rowreq_ctx);
- 
-Index: net-snmp-5.7.3/agent/mibgroup/if-mib/ifXTable/ifXTable_interface.c
-===================================================================
---- net-snmp-5.7.3.orig/agent/mibgroup/if-mib/ifXTable/ifXTable_interface.c
-+++ net-snmp-5.7.3/agent/mibgroup/if-mib/ifXTable/ifXTable_interface.c
-@@ -729,72 +729,72 @@ _ifXTable_get_column(ifXTable_rowreq_ctx
-          * ifHCInOctets(6)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IFHCINOCTETS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
--        rc = ifHCInOctets_get(rowreq_ctx, (U64 *) var->val.string);
-+        rc = ifHCInOctets_get(rowreq_ctx, (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-          * ifHCInUcastPkts(7)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IFHCINUCASTPKTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
--        rc = ifHCInUcastPkts_get(rowreq_ctx, (U64 *) var->val.string);
-+        rc = ifHCInUcastPkts_get(rowreq_ctx, (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-          * ifHCInMulticastPkts(8)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IFHCINMULTICASTPKTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
--        rc = ifHCInMulticastPkts_get(rowreq_ctx, (U64 *) var->val.string);
-+        rc = ifHCInMulticastPkts_get(rowreq_ctx, (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-          * ifHCInBroadcastPkts(9)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IFHCINBROADCASTPKTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
--        rc = ifHCInBroadcastPkts_get(rowreq_ctx, (U64 *) var->val.string);
-+        rc = ifHCInBroadcastPkts_get(rowreq_ctx, (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-          * ifHCOutOctets(10)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IFHCOUTOCTETS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
--        rc = ifHCOutOctets_get(rowreq_ctx, (U64 *) var->val.string);
-+        rc = ifHCOutOctets_get(rowreq_ctx, (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-          * ifHCOutUcastPkts(11)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IFHCOUTUCASTPKTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
--        rc = ifHCOutUcastPkts_get(rowreq_ctx, (U64 *) var->val.string);
-+        rc = ifHCOutUcastPkts_get(rowreq_ctx, (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-          * ifHCOutMulticastPkts(12)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IFHCOUTMULTICASTPKTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
--        rc = ifHCOutMulticastPkts_get(rowreq_ctx, (U64 *) var->val.string);
-+        rc = ifHCOutMulticastPkts_get(rowreq_ctx, (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-          * ifHCOutBroadcastPkts(13)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IFHCOUTBROADCASTPKTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
--        rc = ifHCOutBroadcastPkts_get(rowreq_ctx, (U64 *) var->val.string);
-+        rc = ifHCOutBroadcastPkts_get(rowreq_ctx, (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-Index: net-snmp-5.7.3/agent/mibgroup/ip-mib/data_access/systemstats_common.c
-===================================================================
---- net-snmp-5.7.3.orig/agent/mibgroup/ip-mib/data_access/systemstats_common.c
-+++ net-snmp-5.7.3/agent/mibgroup/ip-mib/data_access/systemstats_common.c
-@@ -264,7 +264,7 @@ _calculate_entries(netsnmp_systemstats_e
-            && entry->stats.columnAvail[IPSYSTEMSTATSTABLE_HCOUTFRAGCREATES]
-         && entry->stats.columnAvail[IPSYSTEMSTATSTABLE_HCOUTDISCARDS]) {
- 
--        U64 tmp, tmp2, tmp3;
-+        struct counter64 tmp, tmp2, tmp3;
-         tmp = entry->stats.HCOutRequests;
-         u64Incr(&tmp, &entry->stats.HCOutForwDatagrams);
-         u64Incr(&tmp, &entry->stats.HCOutFragCreates);
-Index: net-snmp-5.7.3/agent/mibgroup/ip-mib/ipIfStatsTable/ipIfStatsTable_data_get.c
-===================================================================
---- net-snmp-5.7.3.orig/agent/mibgroup/ip-mib/ipIfStatsTable/ipIfStatsTable_data_get.c
-+++ net-snmp-5.7.3/agent/mibgroup/ip-mib/ipIfStatsTable/ipIfStatsTable_data_get.c
-@@ -270,7 +270,7 @@ The total number of input IP datagrams r
-  */
- int
- ipIfStatsHCInReceives_get(ipIfStatsTable_rowreq_ctx * rowreq_ctx,
--                          U64 * ipIfStatsHCInReceives_val_ptr)
-+                          struct counter64 *ipIfStatsHCInReceives_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipIfStatsHCInReceives_val_ptr);
-@@ -395,7 +395,7 @@ The total number of octets received in i
-  */
- int
- ipIfStatsHCInOctets_get(ipIfStatsTable_rowreq_ctx * rowreq_ctx,
--                        U64 * ipIfStatsHCInOctets_val_ptr)
-+                        struct counter64 *ipIfStatsHCInOctets_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipIfStatsHCInOctets_val_ptr);
-@@ -862,7 +862,7 @@ The number of input datagrams for which
-  */
- int
- ipIfStatsHCInForwDatagrams_get(ipIfStatsTable_rowreq_ctx * rowreq_ctx,
--                               U64 * ipIfStatsHCInForwDatagrams_val_ptr)
-+                               struct counter64 *ipIfStatsHCInForwDatagrams_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipIfStatsHCInForwDatagrams_val_ptr);
-@@ -1267,7 +1267,7 @@ The total number of datagrams successful
-  */
- int
- ipIfStatsHCInDelivers_get(ipIfStatsTable_rowreq_ctx * rowreq_ctx,
--                          U64 * ipIfStatsHCInDelivers_val_ptr)
-+                          struct counter64 *ipIfStatsHCInDelivers_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipIfStatsHCInDelivers_val_ptr);
-@@ -1396,7 +1396,7 @@ The total number of IP datagrams that lo
-  */
- int
- ipIfStatsHCOutRequests_get(ipIfStatsTable_rowreq_ctx * rowreq_ctx,
--                           U64 * ipIfStatsHCOutRequests_val_ptr)
-+                           struct counter64 *ipIfStatsHCOutRequests_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipIfStatsHCOutRequests_val_ptr);
-@@ -1532,7 +1532,7 @@ The number of datagrams for which this e
-  */
- int
- ipIfStatsHCOutForwDatagrams_get(ipIfStatsTable_rowreq_ctx * rowreq_ctx,
--                                U64 * ipIfStatsHCOutForwDatagrams_val_ptr)
-+                                struct counter64 *ipIfStatsHCOutForwDatagrams_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipIfStatsHCOutForwDatagrams_val_ptr);
-@@ -1999,7 +1999,7 @@ The total number of IP datagrams that th
-  */
- int
- ipIfStatsHCOutTransmits_get(ipIfStatsTable_rowreq_ctx * rowreq_ctx,
--                            U64 * ipIfStatsHCOutTransmits_val_ptr)
-+                            struct counter64 *ipIfStatsHCOutTransmits_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipIfStatsHCOutTransmits_val_ptr);
-@@ -2123,7 +2123,7 @@ The total number of octets in IP datagra
-  */
- int
- ipIfStatsHCOutOctets_get(ipIfStatsTable_rowreq_ctx * rowreq_ctx,
--                         U64 * ipIfStatsHCOutOctets_val_ptr)
-+                         struct counter64 *ipIfStatsHCOutOctets_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipIfStatsHCOutOctets_val_ptr);
-@@ -2245,7 +2245,7 @@ The number of IP multicast datagrams rec
-  */
- int
- ipIfStatsHCInMcastPkts_get(ipIfStatsTable_rowreq_ctx * rowreq_ctx,
--                           U64 * ipIfStatsHCInMcastPkts_val_ptr)
-+                           struct counter64 *ipIfStatsHCInMcastPkts_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipIfStatsHCInMcastPkts_val_ptr);
-@@ -2372,7 +2372,7 @@ The total number of octets received in I
-  */
- int
- ipIfStatsHCInMcastOctets_get(ipIfStatsTable_rowreq_ctx * rowreq_ctx,
--                             U64 * ipIfStatsHCInMcastOctets_val_ptr)
-+                             struct counter64 *ipIfStatsHCInMcastOctets_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipIfStatsHCInMcastOctets_val_ptr);
-@@ -2497,7 +2497,7 @@ The number of IP multicast datagrams tra
-  */
- int
- ipIfStatsHCOutMcastPkts_get(ipIfStatsTable_rowreq_ctx * rowreq_ctx,
--                            U64 * ipIfStatsHCOutMcastPkts_val_ptr)
-+                            struct counter64 *ipIfStatsHCOutMcastPkts_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipIfStatsHCOutMcastPkts_val_ptr);
-@@ -2621,7 +2621,7 @@ The total number of octets transmitted i
-  */
- int
- ipIfStatsHCOutMcastOctets_get(ipIfStatsTable_rowreq_ctx * rowreq_ctx,
--                              U64 * ipIfStatsHCOutMcastOctets_val_ptr)
-+                              struct counter64 *ipIfStatsHCOutMcastOctets_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipIfStatsHCOutMcastOctets_val_ptr);
-@@ -2743,7 +2743,7 @@ The number of IP broadcast datagrams rec
-  */
- int
- ipIfStatsHCInBcastPkts_get(ipIfStatsTable_rowreq_ctx * rowreq_ctx,
--                           U64 * ipIfStatsHCInBcastPkts_val_ptr)
-+                           struct counter64 *ipIfStatsHCInBcastPkts_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipIfStatsHCInBcastPkts_val_ptr);
-@@ -2865,7 +2865,7 @@ The number of IP broadcast datagrams tra
-  */
- int
- ipIfStatsHCOutBcastPkts_get(ipIfStatsTable_rowreq_ctx * rowreq_ctx,
--                            U64 * ipIfStatsHCOutBcastPkts_val_ptr)
-+                            struct counter64 *ipIfStatsHCOutBcastPkts_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipIfStatsHCOutBcastPkts_val_ptr);
-Index: net-snmp-5.7.3/agent/mibgroup/ip-mib/ipIfStatsTable/ipIfStatsTable_data_get.h
-===================================================================
---- net-snmp-5.7.3.orig/agent/mibgroup/ip-mib/ipIfStatsTable/ipIfStatsTable_data_get.h
-+++ net-snmp-5.7.3/agent/mibgroup/ip-mib/ipIfStatsTable/ipIfStatsTable_data_get.h
-@@ -50,7 +50,7 @@ extern          "C" {
-                                             ipIfStatsInReceives_val_ptr);
-     int             ipIfStatsHCInReceives_get(ipIfStatsTable_rowreq_ctx *
-                                               rowreq_ctx,
--                                              U64 *
-+                                              struct counter64 *
-                                               ipIfStatsHCInReceives_val_ptr);
-     int             ipIfStatsInOctets_get(ipIfStatsTable_rowreq_ctx *
-                                           rowreq_ctx,
-@@ -58,7 +58,7 @@ extern          "C" {
-                                           ipIfStatsInOctets_val_ptr);
-     int             ipIfStatsHCInOctets_get(ipIfStatsTable_rowreq_ctx *
-                                             rowreq_ctx,
--                                            U64 *
-+                                            struct counter64 *
-                                             ipIfStatsHCInOctets_val_ptr);
-     int             ipIfStatsInHdrErrors_get(ipIfStatsTable_rowreq_ctx *
-                                              rowreq_ctx,
-@@ -87,7 +87,7 @@ extern          "C" {
-     int            
-         ipIfStatsHCInForwDatagrams_get(ipIfStatsTable_rowreq_ctx *
-                                        rowreq_ctx,
--                                       U64 *
-+                                       struct counter64 *
-                                        ipIfStatsHCInForwDatagrams_val_ptr);
-     int             ipIfStatsReasmReqds_get(ipIfStatsTable_rowreq_ctx *
-                                             rowreq_ctx,
-@@ -111,7 +111,7 @@ extern          "C" {
-                                             ipIfStatsInDelivers_val_ptr);
-     int             ipIfStatsHCInDelivers_get(ipIfStatsTable_rowreq_ctx *
-                                               rowreq_ctx,
--                                              U64 *
-+                                              struct counter64 *
-                                               ipIfStatsHCInDelivers_val_ptr);
-     int             ipIfStatsOutRequests_get(ipIfStatsTable_rowreq_ctx *
-                                              rowreq_ctx,
-@@ -119,7 +119,7 @@ extern          "C" {
-                                              ipIfStatsOutRequests_val_ptr);
-     int             ipIfStatsHCOutRequests_get(ipIfStatsTable_rowreq_ctx *
-                                                rowreq_ctx,
--                                               U64 *
-+                                               struct counter64 *
-                                                ipIfStatsHCOutRequests_val_ptr);
-     int             ipIfStatsOutForwDatagrams_get(ipIfStatsTable_rowreq_ctx
-                                                   * rowreq_ctx,
-@@ -128,7 +128,7 @@ extern          "C" {
-     int            
-         ipIfStatsHCOutForwDatagrams_get(ipIfStatsTable_rowreq_ctx *
-                                         rowreq_ctx,
--                                        U64 *
-+                                        struct counter64 *
-                                         ipIfStatsHCOutForwDatagrams_val_ptr);
-     int             ipIfStatsOutDiscards_get(ipIfStatsTable_rowreq_ctx *
-                                              rowreq_ctx,
-@@ -156,7 +156,7 @@ extern          "C" {
-                                               ipIfStatsOutTransmits_val_ptr);
-     int             ipIfStatsHCOutTransmits_get(ipIfStatsTable_rowreq_ctx *
-                                                 rowreq_ctx,
--                                                U64 *
-+                                                struct counter64 *
-                                                 ipIfStatsHCOutTransmits_val_ptr);
-     int             ipIfStatsOutOctets_get(ipIfStatsTable_rowreq_ctx *
-                                            rowreq_ctx,
-@@ -164,7 +164,7 @@ extern          "C" {
-                                            ipIfStatsOutOctets_val_ptr);
-     int             ipIfStatsHCOutOctets_get(ipIfStatsTable_rowreq_ctx *
-                                              rowreq_ctx,
--                                             U64 *
-+                                             struct counter64 *
-                                              ipIfStatsHCOutOctets_val_ptr);
-     int             ipIfStatsInMcastPkts_get(ipIfStatsTable_rowreq_ctx *
-                                              rowreq_ctx,
-@@ -172,7 +172,7 @@ extern          "C" {
-                                              ipIfStatsInMcastPkts_val_ptr);
-     int             ipIfStatsHCInMcastPkts_get(ipIfStatsTable_rowreq_ctx *
-                                                rowreq_ctx,
--                                               U64 *
-+                                               struct counter64 *
-                                                ipIfStatsHCInMcastPkts_val_ptr);
-     int             ipIfStatsInMcastOctets_get(ipIfStatsTable_rowreq_ctx *
-                                                rowreq_ctx,
-@@ -180,7 +180,7 @@ extern          "C" {
-                                                ipIfStatsInMcastOctets_val_ptr);
-     int             ipIfStatsHCInMcastOctets_get(ipIfStatsTable_rowreq_ctx
-                                                  * rowreq_ctx,
--                                                 U64 *
-+                                                 struct counter64 *
-                                                  ipIfStatsHCInMcastOctets_val_ptr);
-     int             ipIfStatsOutMcastPkts_get(ipIfStatsTable_rowreq_ctx *
-                                               rowreq_ctx,
-@@ -188,7 +188,7 @@ extern          "C" {
-                                               ipIfStatsOutMcastPkts_val_ptr);
-     int             ipIfStatsHCOutMcastPkts_get(ipIfStatsTable_rowreq_ctx *
-                                                 rowreq_ctx,
--                                                U64 *
-+                                                struct counter64 *
-                                                 ipIfStatsHCOutMcastPkts_val_ptr);
-     int             ipIfStatsOutMcastOctets_get(ipIfStatsTable_rowreq_ctx *
-                                                 rowreq_ctx,
-@@ -196,7 +196,7 @@ extern          "C" {
-                                                 ipIfStatsOutMcastOctets_val_ptr);
-     int             ipIfStatsHCOutMcastOctets_get(ipIfStatsTable_rowreq_ctx
-                                                   * rowreq_ctx,
--                                                  U64 *
-+                                                  struct counter64 *
-                                                   ipIfStatsHCOutMcastOctets_val_ptr);
-     int             ipIfStatsInBcastPkts_get(ipIfStatsTable_rowreq_ctx *
-                                              rowreq_ctx,
-@@ -204,7 +204,7 @@ extern          "C" {
-                                              ipIfStatsInBcastPkts_val_ptr);
-     int             ipIfStatsHCInBcastPkts_get(ipIfStatsTable_rowreq_ctx *
-                                                rowreq_ctx,
--                                               U64 *
-+                                               struct counter64 *
-                                                ipIfStatsHCInBcastPkts_val_ptr);
-     int             ipIfStatsOutBcastPkts_get(ipIfStatsTable_rowreq_ctx *
-                                               rowreq_ctx,
-@@ -212,7 +212,7 @@ extern          "C" {
-                                               ipIfStatsOutBcastPkts_val_ptr);
-     int             ipIfStatsHCOutBcastPkts_get(ipIfStatsTable_rowreq_ctx *
-                                                 rowreq_ctx,
--                                                U64 *
-+                                                struct counter64 *
-                                                 ipIfStatsHCOutBcastPkts_val_ptr);
-     int            
-         ipIfStatsDiscontinuityTime_get(ipIfStatsTable_rowreq_ctx *
-Index: net-snmp-5.7.3/agent/mibgroup/ip-mib/ipIfStatsTable/ipIfStatsTable_interface.c
-===================================================================
---- net-snmp-5.7.3.orig/agent/mibgroup/ip-mib/ipIfStatsTable/ipIfStatsTable_interface.c
-+++ net-snmp-5.7.3/agent/mibgroup/ip-mib/ipIfStatsTable/ipIfStatsTable_interface.c
-@@ -722,10 +722,10 @@ _ipIfStatsTable_get_column(ipIfStatsTabl
-          * ipIfStatsHCInReceives(4)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPIFSTATSHCINRECEIVES:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipIfStatsHCInReceives_get(rowreq_ctx,
--                                       (U64 *) var->val.string);
-+                                       (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -741,9 +741,9 @@ _ipIfStatsTable_get_column(ipIfStatsTabl
-          * ipIfStatsHCInOctets(6)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPIFSTATSHCINOCTETS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
--        rc = ipIfStatsHCInOctets_get(rowreq_ctx, (U64 *) var->val.string);
-+        rc = ipIfStatsHCInOctets_get(rowreq_ctx, (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -810,10 +810,10 @@ _ipIfStatsTable_get_column(ipIfStatsTabl
-          * ipIfStatsHCInForwDatagrams(13)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPIFSTATSHCINFORWDATAGRAMS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipIfStatsHCInForwDatagrams_get(rowreq_ctx,
--                                            (U64 *) var->val.string);
-+                                            (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -869,10 +869,10 @@ _ipIfStatsTable_get_column(ipIfStatsTabl
-          * ipIfStatsHCInDelivers(19)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPIFSTATSHCINDELIVERS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipIfStatsHCInDelivers_get(rowreq_ctx,
--                                       (U64 *) var->val.string);
-+                                       (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -889,10 +889,10 @@ _ipIfStatsTable_get_column(ipIfStatsTabl
-          * ipIfStatsHCOutRequests(21)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPIFSTATSHCOUTREQUESTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipIfStatsHCOutRequests_get(rowreq_ctx,
--                                        (U64 *) var->val.string);
-+                                        (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -909,10 +909,10 @@ _ipIfStatsTable_get_column(ipIfStatsTabl
-          * ipIfStatsHCOutForwDatagrams(24)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPIFSTATSHCOUTFORWDATAGRAMS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipIfStatsHCOutForwDatagrams_get(rowreq_ctx,
--                                             (U64 *) var->val.string);
-+                                             (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -979,10 +979,10 @@ _ipIfStatsTable_get_column(ipIfStatsTabl
-          * ipIfStatsHCOutTransmits(31)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPIFSTATSHCOUTTRANSMITS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipIfStatsHCOutTransmits_get(rowreq_ctx,
--                                         (U64 *) var->val.string);
-+                                         (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -999,9 +999,9 @@ _ipIfStatsTable_get_column(ipIfStatsTabl
-          * ipIfStatsHCOutOctets(33)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPIFSTATSHCOUTOCTETS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
--        rc = ipIfStatsHCOutOctets_get(rowreq_ctx, (U64 *) var->val.string);
-+        rc = ipIfStatsHCOutOctets_get(rowreq_ctx, (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -1018,10 +1018,10 @@ _ipIfStatsTable_get_column(ipIfStatsTabl
-          * ipIfStatsHCInMcastPkts(35)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPIFSTATSHCINMCASTPKTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipIfStatsHCInMcastPkts_get(rowreq_ctx,
--                                        (U64 *) var->val.string);
-+                                        (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -1038,10 +1038,10 @@ _ipIfStatsTable_get_column(ipIfStatsTabl
-          * ipIfStatsHCInMcastOctets(37)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPIFSTATSHCINMCASTOCTETS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipIfStatsHCInMcastOctets_get(rowreq_ctx,
--                                          (U64 *) var->val.string);
-+                                          (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -1058,10 +1058,10 @@ _ipIfStatsTable_get_column(ipIfStatsTabl
-          * ipIfStatsHCOutMcastPkts(39)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPIFSTATSHCOUTMCASTPKTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipIfStatsHCOutMcastPkts_get(rowreq_ctx,
--                                         (U64 *) var->val.string);
-+                                         (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -1078,10 +1078,10 @@ _ipIfStatsTable_get_column(ipIfStatsTabl
-          * ipIfStatsHCOutMcastOctets(41)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPIFSTATSHCOUTMCASTOCTETS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipIfStatsHCOutMcastOctets_get(rowreq_ctx,
--                                           (U64 *) var->val.string);
-+                                           (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -1098,10 +1098,10 @@ _ipIfStatsTable_get_column(ipIfStatsTabl
-          * ipIfStatsHCInBcastPkts(43)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPIFSTATSHCINBCASTPKTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipIfStatsHCInBcastPkts_get(rowreq_ctx,
--                                        (U64 *) var->val.string);
-+                                        (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -1118,10 +1118,10 @@ _ipIfStatsTable_get_column(ipIfStatsTabl
-          * ipIfStatsHCOutBcastPkts(45)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPIFSTATSHCOUTBCASTPKTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipIfStatsHCOutBcastPkts_get(rowreq_ctx,
--                                         (U64 *) var->val.string);
-+                                         (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-Index: net-snmp-5.7.3/agent/mibgroup/ip-mib/ipSystemStatsTable/ipSystemStatsTable.c
-===================================================================
---- net-snmp-5.7.3.orig/agent/mibgroup/ip-mib/ipSystemStatsTable/ipSystemStatsTable.c
-+++ net-snmp-5.7.3/agent/mibgroup/ip-mib/ipSystemStatsTable/ipSystemStatsTable.c
-@@ -452,7 +452,7 @@ The total number of input IP datagrams r
-  */
- int
- ipSystemStatsHCInReceives_get(ipSystemStatsTable_rowreq_ctx * rowreq_ctx,
--                              U64 * ipSystemStatsHCInReceives_val_ptr)
-+                              struct counter64 *ipSystemStatsHCInReceives_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipSystemStatsHCInReceives_val_ptr);
-@@ -579,7 +579,7 @@ The total number of octets received in i
-  */
- int
- ipSystemStatsHCInOctets_get(ipSystemStatsTable_rowreq_ctx * rowreq_ctx,
--                            U64 * ipSystemStatsHCInOctets_val_ptr)
-+                            struct counter64 *ipSystemStatsHCInOctets_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipSystemStatsHCInOctets_val_ptr);
-@@ -1058,7 +1058,7 @@ The number of input datagrams for which
- int
- ipSystemStatsHCInForwDatagrams_get(ipSystemStatsTable_rowreq_ctx *
-                                    rowreq_ctx,
--                                   U64 *
-+                                   struct counter64 *
-                                    ipSystemStatsHCInForwDatagrams_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-@@ -1474,7 +1474,7 @@ The total number of datagrams successful
-  */
- int
- ipSystemStatsHCInDelivers_get(ipSystemStatsTable_rowreq_ctx * rowreq_ctx,
--                              U64 * ipSystemStatsHCInDelivers_val_ptr)
-+                              struct counter64 *ipSystemStatsHCInDelivers_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipSystemStatsHCInDelivers_val_ptr);
-@@ -1602,7 +1602,7 @@ The total number of IP datagrams which l
-  */
- int
- ipSystemStatsHCOutRequests_get(ipSystemStatsTable_rowreq_ctx * rowreq_ctx,
--                               U64 * ipSystemStatsHCOutRequests_val_ptr)
-+                               struct counter64 *ipSystemStatsHCOutRequests_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipSystemStatsHCOutRequests_val_ptr);
-@@ -1809,7 +1809,7 @@ The number of datagrams for which this e
- int
- ipSystemStatsHCOutForwDatagrams_get(ipSystemStatsTable_rowreq_ctx *
-                                     rowreq_ctx,
--                                    U64 *
-+                                    struct counter64 *
-                                     ipSystemStatsHCOutForwDatagrams_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-@@ -2288,7 +2288,7 @@ The total number of IP datagrams that th
-  */
- int
- ipSystemStatsHCOutTransmits_get(ipSystemStatsTable_rowreq_ctx * rowreq_ctx,
--                                U64 * ipSystemStatsHCOutTransmits_val_ptr)
-+                                struct counter64 *ipSystemStatsHCOutTransmits_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipSystemStatsHCOutTransmits_val_ptr);
-@@ -2415,7 +2415,7 @@ The total number of octets in IP datagra
-  */
- int
- ipSystemStatsHCOutOctets_get(ipSystemStatsTable_rowreq_ctx * rowreq_ctx,
--                             U64 * ipSystemStatsHCOutOctets_val_ptr)
-+                             struct counter64 *ipSystemStatsHCOutOctets_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipSystemStatsHCOutOctets_val_ptr);
-@@ -2539,7 +2539,7 @@ The number of IP multicast datagrams rec
-  */
- int
- ipSystemStatsHCInMcastPkts_get(ipSystemStatsTable_rowreq_ctx * rowreq_ctx,
--                               U64 * ipSystemStatsHCInMcastPkts_val_ptr)
-+                               struct counter64 *ipSystemStatsHCInMcastPkts_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipSystemStatsHCInMcastPkts_val_ptr);
-@@ -2665,7 +2665,7 @@ The total number of octets received in I
- int
- ipSystemStatsHCInMcastOctets_get(ipSystemStatsTable_rowreq_ctx *
-                                  rowreq_ctx,
--                                 U64 *
-+                                 struct counter64 *
-                                  ipSystemStatsHCInMcastOctets_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-@@ -2790,7 +2790,7 @@ The number of IP multicast datagrams tra
-  */
- int
- ipSystemStatsHCOutMcastPkts_get(ipSystemStatsTable_rowreq_ctx * rowreq_ctx,
--                                U64 * ipSystemStatsHCOutMcastPkts_val_ptr)
-+                                struct counter64 *ipSystemStatsHCOutMcastPkts_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipSystemStatsHCOutMcastPkts_val_ptr);
-@@ -2921,7 +2921,7 @@ The total number of octets transmitted i
- int
- ipSystemStatsHCOutMcastOctets_get(ipSystemStatsTable_rowreq_ctx *
-                                   rowreq_ctx,
--                                  U64 *
-+                                  struct counter64 *
-                                   ipSystemStatsHCOutMcastOctets_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-@@ -3046,7 +3046,7 @@ The number of IP broadcast datagrams rec
-  */
- int
- ipSystemStatsHCInBcastPkts_get(ipSystemStatsTable_rowreq_ctx * rowreq_ctx,
--                               U64 * ipSystemStatsHCInBcastPkts_val_ptr)
-+                               struct counter64 *ipSystemStatsHCInBcastPkts_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipSystemStatsHCInBcastPkts_val_ptr);
-@@ -3170,7 +3170,7 @@ The number of IP broadcast datagrams tra
-  */
- int
- ipSystemStatsHCOutBcastPkts_get(ipSystemStatsTable_rowreq_ctx * rowreq_ctx,
--                                U64 * ipSystemStatsHCOutBcastPkts_val_ptr)
-+                                struct counter64 *ipSystemStatsHCOutBcastPkts_val_ptr)
- {
-    /** we should have a non-NULL pointer */
-     netsnmp_assert(NULL != ipSystemStatsHCOutBcastPkts_val_ptr);
-Index: net-snmp-5.7.3/agent/mibgroup/ip-mib/ipSystemStatsTable/ipSystemStatsTable.h
-===================================================================
---- net-snmp-5.7.3.orig/agent/mibgroup/ip-mib/ipSystemStatsTable/ipSystemStatsTable.h
-+++ net-snmp-5.7.3/agent/mibgroup/ip-mib/ipSystemStatsTable/ipSystemStatsTable.h
-@@ -144,93 +144,22 @@ config_require(ip-mib/ipSystemStatsTable
-      *********************************************************************
-      * function prototypes
-      */
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsTable_pre_request(ipSystemStatsTable_registration *
-+    int ipSystemStatsTable_pre_request(ipSystemStatsTable_registration *
-                                        user_context);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsTable_post_request(ipSystemStatsTable_registration *
-+    int ipSystemStatsTable_post_request(ipSystemStatsTable_registration *
-                                         user_context, int rc);
- 
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsTable_rowreq_ctx_init(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsTable_rowreq_ctx_init(ipSystemStatsTable_rowreq_ctx *
-                                            rowreq_ctx,
-                                            void *user_init_ctx);
-     void
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
-         ipSystemStatsTable_rowreq_ctx_cleanup(ipSystemStatsTable_rowreq_ctx
-                                               * rowreq_ctx);
- 
-     ipSystemStatsTable_data *ipSystemStatsTable_allocate_data(void);
-     void            ipSystemStatsTable_release_data(ipSystemStatsTable_data
-                                                     * data);
--
--
--         
--         
--         
--         
--         
--         
--        ipSystemStatsTable_rowreq_ctx
-+    ipSystemStatsTable_rowreq_ctx
-         * ipSystemStatsTable_row_find_by_mib_index
-         (ipSystemStatsTable_mib_index * mib_idx);
- 
-@@ -265,226 +194,50 @@ config_require(ip-mib/ipSystemStatsTable
-      * indexes
-      */
- 
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsInReceives_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsInReceives_get(ipSystemStatsTable_rowreq_ctx *
-                                     rowreq_ctx,
-                                     u_long *
-                                     ipSystemStatsInReceives_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsHCInReceives_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsHCInReceives_get(ipSystemStatsTable_rowreq_ctx *
-                                       rowreq_ctx,
--                                      U64 *
-+                                      struct counter64 *
-                                       ipSystemStatsHCInReceives_val_ptr);
-     int             ipSystemStatsInOctets_get(ipSystemStatsTable_rowreq_ctx
-                                               * rowreq_ctx,
-                                               u_long *
-                                               ipSystemStatsInOctets_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsHCInOctets_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsHCInOctets_get(ipSystemStatsTable_rowreq_ctx *
-                                     rowreq_ctx,
--                                    U64 * ipSystemStatsHCInOctets_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsInHdrErrors_get(ipSystemStatsTable_rowreq_ctx *
-+                                    struct counter64 *ipSystemStatsHCInOctets_val_ptr);
-+    int ipSystemStatsInHdrErrors_get(ipSystemStatsTable_rowreq_ctx *
-                                      rowreq_ctx,
-                                      u_long *
-                                      ipSystemStatsInHdrErrors_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsInNoRoutes_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsInNoRoutes_get(ipSystemStatsTable_rowreq_ctx *
-                                     rowreq_ctx,
-                                     u_long *
-                                     ipSystemStatsInNoRoutes_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsInAddrErrors_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsInAddrErrors_get(ipSystemStatsTable_rowreq_ctx *
-                                       rowreq_ctx,
-                                       u_long *
-                                       ipSystemStatsInAddrErrors_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsInUnknownProtos_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsInUnknownProtos_get(ipSystemStatsTable_rowreq_ctx *
-                                          rowreq_ctx,
-                                          u_long *
-                                          ipSystemStatsInUnknownProtos_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsInTruncatedPkts_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsInTruncatedPkts_get(ipSystemStatsTable_rowreq_ctx *
-                                          rowreq_ctx,
-                                          u_long *
-                                          ipSystemStatsInTruncatedPkts_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsInForwDatagrams_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsInForwDatagrams_get(ipSystemStatsTable_rowreq_ctx *
-                                          rowreq_ctx,
-                                          u_long *
-                                          ipSystemStatsInForwDatagrams_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsHCInForwDatagrams_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsHCInForwDatagrams_get(ipSystemStatsTable_rowreq_ctx *
-                                            rowreq_ctx,
--                                           U64 *
-+                                           struct counter64 *
-                                            ipSystemStatsHCInForwDatagrams_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsReasmReqds_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsReasmReqds_get(ipSystemStatsTable_rowreq_ctx *
-                                     rowreq_ctx,
-                                     u_long *
-                                     ipSystemStatsReasmReqds_val_ptr);
-@@ -492,690 +245,142 @@ config_require(ip-mib/ipSystemStatsTable
-                                               * rowreq_ctx,
-                                               u_long *
-                                               ipSystemStatsReasmOKs_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsReasmFails_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsReasmFails_get(ipSystemStatsTable_rowreq_ctx *
-                                     rowreq_ctx,
-                                     u_long *
-                                     ipSystemStatsReasmFails_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsInDiscards_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsInDiscards_get(ipSystemStatsTable_rowreq_ctx *
-                                     rowreq_ctx,
-                                     u_long *
-                                     ipSystemStatsInDiscards_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsInDelivers_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsInDelivers_get(ipSystemStatsTable_rowreq_ctx *
-                                     rowreq_ctx,
-                                     u_long *
-                                     ipSystemStatsInDelivers_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsHCInDelivers_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsHCInDelivers_get(ipSystemStatsTable_rowreq_ctx *
-                                       rowreq_ctx,
--                                      U64 *
-+                                      struct counter64 *
-                                       ipSystemStatsHCInDelivers_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsOutRequests_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsOutRequests_get(ipSystemStatsTable_rowreq_ctx *
-                                      rowreq_ctx,
-                                      u_long *
-                                      ipSystemStatsOutRequests_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsHCOutRequests_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsHCOutRequests_get(ipSystemStatsTable_rowreq_ctx *
-                                        rowreq_ctx,
--                                       U64 *
-+                                       struct counter64 *
-                                        ipSystemStatsHCOutRequests_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsOutNoRoutes_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsOutNoRoutes_get(ipSystemStatsTable_rowreq_ctx *
-                                      rowreq_ctx,
-                                      u_long *
-                                      ipSystemStatsOutNoRoutes_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsOutForwDatagrams_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsOutForwDatagrams_get(ipSystemStatsTable_rowreq_ctx *
-                                           rowreq_ctx,
-                                           u_long *
-                                           ipSystemStatsOutForwDatagrams_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsHCOutForwDatagrams_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsHCOutForwDatagrams_get(ipSystemStatsTable_rowreq_ctx *
-                                             rowreq_ctx,
--                                            U64 *
-+                                            struct counter64 *
-                                             ipSystemStatsHCOutForwDatagrams_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsOutDiscards_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsOutDiscards_get(ipSystemStatsTable_rowreq_ctx *
-                                      rowreq_ctx,
-                                      u_long *
-                                      ipSystemStatsOutDiscards_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsOutFragReqds_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsOutFragReqds_get(ipSystemStatsTable_rowreq_ctx *
-                                       rowreq_ctx,
-                                       u_long *
-                                       ipSystemStatsOutFragReqds_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsOutFragOKs_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsOutFragOKs_get(ipSystemStatsTable_rowreq_ctx *
-                                     rowreq_ctx,
-                                     u_long *
-                                     ipSystemStatsOutFragOKs_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsOutFragFails_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsOutFragFails_get(ipSystemStatsTable_rowreq_ctx *
-                                       rowreq_ctx,
-                                       u_long *
-                                       ipSystemStatsOutFragFails_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsOutFragCreates_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsOutFragCreates_get(ipSystemStatsTable_rowreq_ctx *
-                                         rowreq_ctx,
-                                         u_long *
-                                         ipSystemStatsOutFragCreates_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsOutTransmits_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsOutTransmits_get(ipSystemStatsTable_rowreq_ctx *
-                                       rowreq_ctx,
-                                       u_long *
-                                       ipSystemStatsOutTransmits_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsHCOutTransmits_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsHCOutTransmits_get(ipSystemStatsTable_rowreq_ctx *
-                                         rowreq_ctx,
--                                        U64 *
-+                                        struct counter64 *
-                                         ipSystemStatsHCOutTransmits_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsOutOctets_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsOutOctets_get(ipSystemStatsTable_rowreq_ctx *
-                                    rowreq_ctx,
-                                    u_long *
-                                    ipSystemStatsOutOctets_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsHCOutOctets_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsHCOutOctets_get(ipSystemStatsTable_rowreq_ctx *
-                                      rowreq_ctx,
--                                     U64 *
-+                                     struct counter64 *
-                                      ipSystemStatsHCOutOctets_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsInMcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsInMcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-                                      rowreq_ctx,
-                                      u_long *
-                                      ipSystemStatsInMcastPkts_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsHCInMcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsHCInMcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-                                        rowreq_ctx,
--                                       U64 *
-+                                       struct counter64 *
-                                        ipSystemStatsHCInMcastPkts_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsInMcastOctets_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsInMcastOctets_get(ipSystemStatsTable_rowreq_ctx *
-                                        rowreq_ctx,
-                                        u_long *
-                                        ipSystemStatsInMcastOctets_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsHCInMcastOctets_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsHCInMcastOctets_get(ipSystemStatsTable_rowreq_ctx *
-                                          rowreq_ctx,
--                                         U64 *
-+                                         struct counter64 *
-                                          ipSystemStatsHCInMcastOctets_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsOutMcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsOutMcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-                                       rowreq_ctx,
-                                       u_long *
-                                       ipSystemStatsOutMcastPkts_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsHCOutMcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsHCOutMcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-                                         rowreq_ctx,
--                                        U64 *
-+                                        struct counter64 *
-                                         ipSystemStatsHCOutMcastPkts_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsOutMcastOctets_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsOutMcastOctets_get(ipSystemStatsTable_rowreq_ctx *
-                                         rowreq_ctx,
-                                         u_long *
-                                         ipSystemStatsOutMcastOctets_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsHCOutMcastOctets_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsHCOutMcastOctets_get(ipSystemStatsTable_rowreq_ctx *
-                                           rowreq_ctx,
--                                          U64 *
-+                                          struct counter64 *
-                                           ipSystemStatsHCOutMcastOctets_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsInBcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsInBcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-                                      rowreq_ctx,
-                                      u_long *
-                                      ipSystemStatsInBcastPkts_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsHCInBcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsHCInBcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-                                        rowreq_ctx,
--                                       U64 *
-+                                       struct counter64 *
-                                        ipSystemStatsHCInBcastPkts_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsOutBcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsOutBcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-                                       rowreq_ctx,
-                                       u_long *
-                                       ipSystemStatsOutBcastPkts_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsHCOutBcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsHCOutBcastPkts_get(ipSystemStatsTable_rowreq_ctx *
-                                         rowreq_ctx,
--                                        U64 *
-+                                        struct counter64 *
-                                         ipSystemStatsHCOutBcastPkts_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsDiscontinuityTime_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsDiscontinuityTime_get(ipSystemStatsTable_rowreq_ctx *
-                                            rowreq_ctx,
-                                            u_long *
-                                            ipSystemStatsDiscontinuityTime_val_ptr);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsRefreshRate_get(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsRefreshRate_get(ipSystemStatsTable_rowreq_ctx *
-                                      rowreq_ctx,
-                                      u_long *
-                                      ipSystemStatsRefreshRate_val_ptr);
--
--
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsTable_indexes_set_tbl_idx(ipSystemStatsTable_mib_index
-+    int ipSystemStatsTable_indexes_set_tbl_idx(ipSystemStatsTable_mib_index
-                                                * tbl_idx,
-                                                u_long
-                                                ipSystemStatsIPVersion_val);
--    int
--     
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        
--        ipSystemStatsTable_indexes_set(ipSystemStatsTable_rowreq_ctx *
-+    int ipSystemStatsTable_indexes_set(ipSystemStatsTable_rowreq_ctx *
-                                        rowreq_ctx,
-                                        u_long ipSystemStatsIPVersion_val);
- 
--
--
-     /*
-      *********************************************************************
-      * SET function declarations
-Index: net-snmp-5.7.3/agent/mibgroup/ip-mib/ipSystemStatsTable/ipSystemStatsTable_interface.c
-===================================================================
---- net-snmp-5.7.3.orig/agent/mibgroup/ip-mib/ipSystemStatsTable/ipSystemStatsTable_interface.c
-+++ net-snmp-5.7.3/agent/mibgroup/ip-mib/ipSystemStatsTable/ipSystemStatsTable_interface.c
-@@ -674,10 +674,10 @@ _ipSystemStatsTable_get_column(ipSystemS
-          * ipSystemStatsHCInReceives(4)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPSYSTEMSTATSHCINRECEIVES:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipSystemStatsHCInReceives_get(rowreq_ctx,
--                                           (U64 *) var->val.string);
-+                                           (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -694,10 +694,10 @@ _ipSystemStatsTable_get_column(ipSystemS
-          * ipSystemStatsHCInOctets(6)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPSYSTEMSTATSHCINOCTETS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipSystemStatsHCInOctets_get(rowreq_ctx,
--                                         (U64 *) var->val.string);
-+                                         (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -764,10 +764,10 @@ _ipSystemStatsTable_get_column(ipSystemS
-          * ipSystemStatsHCInForwDatagrams(13)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPSYSTEMSTATSHCINFORWDATAGRAMS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipSystemStatsHCInForwDatagrams_get(rowreq_ctx,
--                                                (U64 *) var->val.string);
-+                                                (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -824,10 +824,10 @@ _ipSystemStatsTable_get_column(ipSystemS
-          * ipSystemStatsHCInDelivers(19)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPSYSTEMSTATSHCINDELIVERS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipSystemStatsHCInDelivers_get(rowreq_ctx,
--                                           (U64 *) var->val.string);
-+                                           (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -844,10 +844,10 @@ _ipSystemStatsTable_get_column(ipSystemS
-          * ipSystemStatsHCOutRequests(21)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPSYSTEMSTATSHCOUTREQUESTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipSystemStatsHCOutRequests_get(rowreq_ctx,
--                                            (U64 *) var->val.string);
-+                                            (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -874,10 +874,10 @@ _ipSystemStatsTable_get_column(ipSystemS
-          * ipSystemStatsHCOutForwDatagrams(24)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPSYSTEMSTATSHCOUTFORWDATAGRAMS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipSystemStatsHCOutForwDatagrams_get(rowreq_ctx,
--                                                 (U64 *) var->val.string);
-+                                                 (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -944,10 +944,10 @@ _ipSystemStatsTable_get_column(ipSystemS
-          * ipSystemStatsHCOutTransmits(31)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPSYSTEMSTATSHCOUTTRANSMITS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipSystemStatsHCOutTransmits_get(rowreq_ctx,
--                                             (U64 *) var->val.string);
-+                                             (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -964,10 +964,10 @@ _ipSystemStatsTable_get_column(ipSystemS
-          * ipSystemStatsHCOutOctets(33)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPSYSTEMSTATSHCOUTOCTETS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipSystemStatsHCOutOctets_get(rowreq_ctx,
--                                          (U64 *) var->val.string);
-+                                          (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -984,10 +984,10 @@ _ipSystemStatsTable_get_column(ipSystemS
-          * ipSystemStatsHCInMcastPkts(35)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPSYSTEMSTATSHCINMCASTPKTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipSystemStatsHCInMcastPkts_get(rowreq_ctx,
--                                            (U64 *) var->val.string);
-+                                            (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -1004,10 +1004,10 @@ _ipSystemStatsTable_get_column(ipSystemS
-          * ipSystemStatsHCInMcastOctets(37)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPSYSTEMSTATSHCINMCASTOCTETS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipSystemStatsHCInMcastOctets_get(rowreq_ctx,
--                                              (U64 *) var->val.string);
-+                                              (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -1024,10 +1024,10 @@ _ipSystemStatsTable_get_column(ipSystemS
-          * ipSystemStatsHCOutMcastPkts(39)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPSYSTEMSTATSHCOUTMCASTPKTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipSystemStatsHCOutMcastPkts_get(rowreq_ctx,
--                                             (U64 *) var->val.string);
-+                                             (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -1044,10 +1044,10 @@ _ipSystemStatsTable_get_column(ipSystemS
-          * ipSystemStatsHCOutMcastOctets(41)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPSYSTEMSTATSHCOUTMCASTOCTETS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipSystemStatsHCOutMcastOctets_get(rowreq_ctx,
--                                               (U64 *) var->val.string);
-+                                               (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -1064,10 +1064,10 @@ _ipSystemStatsTable_get_column(ipSystemS
-          * ipSystemStatsHCInBcastPkts(43)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPSYSTEMSTATSHCINBCASTPKTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipSystemStatsHCInBcastPkts_get(rowreq_ctx,
--                                            (U64 *) var->val.string);
-+                                            (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-@@ -1084,10 +1084,10 @@ _ipSystemStatsTable_get_column(ipSystemS
-          * ipSystemStatsHCOutBcastPkts(45)/COUNTER64/ASN_COUNTER64/U64(U64)//l/A/w/e/r/d/h 
-          */
-     case COLUMN_IPSYSTEMSTATSHCOUTBCASTPKTS:
--        var->val_len = sizeof(U64);
-+        var->val_len = sizeof(struct counter64);
-         var->type = ASN_COUNTER64;
-         rc = ipSystemStatsHCOutBcastPkts_get(rowreq_ctx,
--                                             (U64 *) var->val.string);
-+                                             (struct counter64 *) var->val.string);
-         break;
- 
-         /*
-Index: net-snmp-5.7.3/include/net-snmp/data_access/ipstats.h
-===================================================================
---- net-snmp-5.7.3.orig/include/net-snmp/data_access/ipstats.h
-+++ net-snmp-5.7.3/include/net-snmp/data_access/ipstats.h
-@@ -58,45 +58,45 @@ typedef struct netsnmp_ipstats_s {
-     * other columns, when underlying OS does not provide them.
-     * Always fill at least 32 bits, the table is periodically polled -> 32 bit
-     * overflow shall be detected and 64 bit value should be computed automatically. */
--   U64             HCInReceives;
--   U64             HCInOctets;
-+   struct counter64 HCInReceives;
-+   struct counter64 HCInOctets;
-    u_long          InHdrErrors;
--   U64             HCInNoRoutes; 
-+   struct counter64 HCInNoRoutes; 
-    u_long          InAddrErrors;
-    u_long          InUnknownProtos;
-    u_long          InTruncatedPkts;
-    
-    /* optional, can be computed from HCInNoRoutes and HCOutForwDatagrams */
--   U64             HCInForwDatagrams; 
-+   struct counter64 HCInForwDatagrams; 
-    
-    u_long          ReasmReqds;
-    u_long          ReasmOKs;
-    u_long          ReasmFails;
-    u_long          InDiscards;
--   U64             HCInDelivers;
--   U64             HCOutRequests;
--   U64             HCOutNoRoutes;
--   U64             HCOutForwDatagrams;
--   U64             HCOutDiscards;
-+   struct counter64 HCInDelivers;
-+   struct counter64 HCOutRequests;
-+   struct counter64 HCOutNoRoutes;
-+   struct counter64 HCOutForwDatagrams;
-+   struct counter64 HCOutDiscards;
-    
-    /* optional, can be computed from HCOutFragOKs + HCOutFragFails*/
--   U64             HCOutFragReqds;
--   U64             HCOutFragOKs;
--   U64             HCOutFragFails;
--   U64             HCOutFragCreates;
-+   struct counter64 HCOutFragReqds;
-+   struct counter64 HCOutFragOKs;
-+   struct counter64 HCOutFragFails;
-+   struct counter64 HCOutFragCreates;
-    
-    /* optional, can be computed from 
-     * HCOutRequests +HCOutForwDatagrams + HCOutFragCreates
-     * - HCOutFragReqds - HCOutNoRoutes  - HCOutDiscards */
--   U64             HCOutTransmits;
-+   struct counter64 HCOutTransmits;
-    
--   U64             HCOutOctets;
--   U64             HCInMcastPkts;
--   U64             HCInMcastOctets;
--   U64             HCOutMcastPkts;
--   U64             HCOutMcastOctets;
--   U64             HCInBcastPkts;
--   U64             HCOutBcastPkts;
-+   struct counter64 HCOutOctets;
-+   struct counter64 HCInMcastPkts;
-+   struct counter64 HCInMcastOctets;
-+   struct counter64 HCOutMcastPkts;
-+   struct counter64 HCOutMcastOctets;
-+   struct counter64 HCInBcastPkts;
-+   struct counter64 HCOutBcastPkts;
- 
-    /* Array of available columns.*/
-    int             columnAvail[IPSYSTEMSTATSTABLE_LAST+1];
-Index: net-snmp-5.7.3/include/net-snmp/library/int64.h
-===================================================================
---- net-snmp-5.7.3.orig/include/net-snmp/library/int64.h
-+++ net-snmp-5.7.3/include/net-snmp/library/int64.h
-@@ -5,31 +5,29 @@
- extern          "C" {
- #endif
- 
--    typedef struct counter64 U64;
--
- #define I64CHARSZ 21
- 
--    void            divBy10(U64, U64 *, unsigned int *);
--    void            multBy10(U64, U64 *);
--    void            incrByU16(U64 *, unsigned int);
--    void            incrByU32(U64 *, unsigned int);
-+    void            divBy10(struct counter64, struct counter64 *, unsigned int *);
-+    void            multBy10(struct counter64, struct counter64 *);
-+    void            incrByU16(struct counter64 *, unsigned int);
-+    void            incrByU32(struct counter64 *, unsigned int);
-     NETSNMP_IMPORT
--    void            zeroU64(U64 *);
--    int             isZeroU64(const U64 *);
-+    void            zeroU64(struct counter64 *);
-+    int             isZeroU64(const struct counter64 *);
-     NETSNMP_IMPORT
--    void            printU64(char *, const U64 *);
-+    void            printU64(char *, const struct counter64 *);
-     NETSNMP_IMPORT
--    void            printI64(char *, const U64 *);
--    int             read64(U64 *, const char *);
-+    void            printI64(char *, const struct counter64 *);
-+    int             read64(struct counter64 *, const char *);
-     NETSNMP_IMPORT
--    void            u64Subtract(const U64 * pu64one, const U64 * pu64two,
--                                U64 * pu64out);
--    void            u64Incr(U64 * pu64out, const U64 * pu64one);
--    void            u64UpdateCounter(U64 * pu64out, const U64 * pu64one,
--                                     const U64 * pu64two);
--    void            u64Copy(U64 * pu64one, const U64 * pu64two);
-+    void            u64Subtract(const struct counter64 *pu64one, const struct counter64 *pu64two,
-+                                struct counter64 *pu64out);
-+    void            u64Incr(struct counter64 *pu64out, const struct counter64 *pu64one);
-+    void            u64UpdateCounter(struct counter64 *pu64out, const struct counter64 *pu64one,
-+                                     const struct counter64 *pu64two);
-+    void            u64Copy(struct counter64 *pu64one, const struct counter64 *pu64two);
- 
--    int             netsnmp_c64_check_for_32bit_wrap(U64 *old_val, U64 *new_val,
-+    int             netsnmp_c64_check_for_32bit_wrap(struct counter64 *old_val, struct counter64 *new_val,
-                                                      int adjust);
-     NETSNMP_IMPORT
-     int             netsnmp_c64_check32_and_update(struct counter64 *prev_val,
-Index: net-snmp-5.7.3/snmplib/int64.c
-===================================================================
---- net-snmp-5.7.3.orig/snmplib/int64.c
-+++ net-snmp-5.7.3/snmplib/int64.c
-@@ -33,7 +33,7 @@
-  * @param[out] puR   Remainder.
-  */
- void
--divBy10(U64 u64, U64 * pu64Q, unsigned int *puR)
-+divBy10(struct counter64 u64, struct counter64 *pu64Q, unsigned int *puR)
- {
-     unsigned long   ulT;
-     unsigned long   ulQ;
-@@ -83,7 +83,7 @@ divBy10(U64 u64, U64 * pu64Q, unsigned i
-  * @param[out] pu64P Product.
-  */
- void
--multBy10(U64 u64, U64 * pu64P)
-+multBy10(struct counter64 u64, struct counter64 *pu64P)
- {
-     unsigned long   ulT;
-     unsigned long   ulP;
-@@ -130,7 +130,7 @@ multBy10(U64 u64, U64 * pu64P)
-  *
-  */
- void
--incrByU16(U64 * pu64, unsigned int u16)
-+incrByU16(struct counter64 *pu64, unsigned int u16)
- {
-     incrByU32(pu64, u16);
- }
-@@ -143,7 +143,7 @@ incrByU16(U64 * pu64, unsigned int u16)
-  *
-  */
- void
--incrByU32(U64 * pu64, unsigned int u32)
-+incrByU32(struct counter64 *pu64, unsigned int u32)
- {
-     uint32_t tmp;
- 
-@@ -161,7 +161,7 @@ incrByU32(U64 * pu64, unsigned int u32)
-  * @param[out] pu64out pu64one - pu64two.
-  */
- void
--u64Subtract(const U64 * pu64one, const U64 * pu64two, U64 * pu64out)
-+u64Subtract(const struct counter64 *pu64one, const struct counter64 *pu64two, struct counter64 *pu64out)
- {
-     int carry;
- 
-@@ -177,7 +177,7 @@ u64Subtract(const U64 * pu64one, const U
-  * @param[in,out] pu64out pu64out += pu64one.
-  */
- void
--u64Incr(U64 * pu64out, const U64 * pu64one)
-+u64Incr(struct counter64 *pu64out, const struct counter64 *pu64one)
- {
-     pu64out->high = (uint32_t)(pu64out->high + pu64one->high);
-     incrByU32(pu64out, pu64one->low);
-@@ -191,9 +191,9 @@ u64Incr(U64 * pu64out, const U64 * pu64o
-  * @param[out] pu64out pu64out += (pu64one - pu64two)
-  */
- void
--u64UpdateCounter(U64 * pu64out, const U64 * pu64one, const U64 * pu64two)
-+u64UpdateCounter(struct counter64 *pu64out, const struct counter64 *pu64one, const struct counter64 *pu64two)
- {
--    U64 tmp;
-+    struct counter64 tmp;
- 
-     u64Subtract(pu64one, pu64two, &tmp);
-     u64Incr(pu64out, &tmp);
-@@ -208,7 +208,7 @@ netsnmp_feature_child_of(u64copy, netsnm
-  * @param[out] pu64one Where to store the copy - *pu64one = *pu64two.
-  */
- void
--u64Copy(U64 * pu64one, const U64 * pu64two)
-+u64Copy(struct counter64 *pu64one, const struct counter64 *pu64two)
- {
-     *pu64one = *pu64two;
- }
-@@ -220,7 +220,7 @@ u64Copy(U64 * pu64one, const U64 * pu64t
-  * @param[in] pu64 Number to be zeroed.
-  */
- void
--zeroU64(U64 * pu64)
-+zeroU64(struct counter64 *pu64)
- {
-     pu64->low = 0;
-     pu64->high = 0;
-@@ -232,7 +232,7 @@ zeroU64(U64 * pu64)
-  * @param[in] pu64 Number to be checked.
-  */
- int
--isZeroU64(const U64 * pu64)
-+isZeroU64(const struct counter64 *pu64)
- {
-     return pu64->low == 0 && pu64->high == 0;
- }
-@@ -390,10 +390,10 @@ netsnmp_c64_check32_and_update(struct co
- /** Convert an unsigned 64-bit number to ASCII. */
- void
- printU64(char *buf, /* char [I64CHARSZ+1]; */
--         const U64 * pu64)
-+         const struct counter64 *pu64)
- {
--    U64             u64a;
--    U64             u64b;
-+    struct counter64 u64a;
-+    struct counter64 u64b;
- 
-     char            aRes[I64CHARSZ + 1];
-     unsigned int    u;
-@@ -414,9 +414,9 @@ printU64(char *buf, /* char [I64CHARSZ+1
- /** Convert a signed 64-bit number to ASCII. */
- void
- printI64(char *buf, /* char [I64CHARSZ+1]; */
--         const U64 * pu64)
-+         const struct counter64 *pu64)
- {
--    U64             u64a;
-+    struct counter64 u64a;
- 
-     if (pu64->high & 0x80000000) {
-         u64a.high = (uint32_t) ~pu64->high;
-@@ -429,11 +429,11 @@ printI64(char *buf, /* char [I64CHARSZ+1
-     }
- }
- 
--/** Convert a signed 64-bit integer from ASCII to U64. */
-+/** Convert a signed 64-bit integer from ASCII to struct counter64. */
- int
--read64(U64 * i64, const char *str)
-+read64(struct counter64 *i64, const char *str)
- {
--    U64             i64p;
-+    struct counter64 i64p;
-     unsigned int    u;
-     int             sign = 0;
-     int             ok = 0;
-Index: net-snmp-5.7.3/snmplib/read_config.c
-===================================================================
---- net-snmp-5.7.3.orig/snmplib/read_config.c
-+++ net-snmp-5.7.3/snmplib/read_config.c
-@@ -2270,10 +2270,10 @@ read_config_read_memory(int type, char *
-         return readfrom;
- 
-     case ASN_COUNTER64:
--        if (*len < sizeof(U64))
-+        if (*len < sizeof(struct counter64))
-             return NULL;
--        *len = sizeof(U64);
--        read64((U64 *) dataptr, readfrom);
-+        *len = sizeof(struct counter64);
-+        read64((struct counter64 *) dataptr, readfrom);
-         readfrom = skip_token(readfrom);
-         return readfrom;
-     }
-Index: net-snmp-5.7.3/testing/fulltests/unit-tests/T015int64_clib.c
-===================================================================
---- net-snmp-5.7.3.orig/testing/fulltests/unit-tests/T015int64_clib.c
-+++ net-snmp-5.7.3/testing/fulltests/unit-tests/T015int64_clib.c
-@@ -1,4 +1,4 @@
--/* HEADER Testing 64-bit integer operations (U64). */
-+/* HEADER Testing 64-bit integer operations (struct counter64). */
- 
- int i, j;
- char buf[22];
-@@ -15,7 +15,7 @@ static const int64_t intval[] = {
- };
- 
- for (i = 0; i < sizeof(intval)/sizeof(intval[0]); ++i) {
--    U64 a, b;
-+    struct counter64 a, b;
-     a.low = (uint32_t)intval[i];
-     a.high = (uint32_t)(intval[i] >> 32);
-     printI64(buf, &a);
-@@ -27,7 +27,7 @@ for (i = 0; i < sizeof(intval)/sizeof(in
- 
- for (i = 0; i < sizeof(intval)/sizeof(intval[0]); ++i) {
-     for (j = i; j < sizeof(intval)/sizeof(intval[0]); ++j) {
--        U64 a, b;
-+        struct counter64 a, b;
-         uint64_t d;
-         a.low = (uint32_t)intval[i];
-         a.high = (uint32_t)(intval[i] >> 32);
-@@ -43,7 +43,7 @@ for (i = 0; i < sizeof(intval)/sizeof(in
-         
- for (i = 0; i < sizeof(intval)/sizeof(intval[0]); ++i) {
-     for (j = i; j < sizeof(intval)/sizeof(intval[0]); ++j) {
--        U64 a, b, c;
-+        struct counter64 a, b, c;
-         uint64_t d;
-         a.low = (uint32_t)intval[i];
-         a.high = (uint32_t)(intval[i] >> 32);
-@@ -58,7 +58,7 @@ for (i = 0; i < sizeof(intval)/sizeof(in
- }
-         
- {
--    U64 old_val, new_val;
-+    struct counter64 old_val, new_val;
-     old_val.low = 7;
-     old_val.high = 0;
-     new_val = old_val;
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-config_os_headers-Error-Fix.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-config_os_headers-Error-Fix.patch
index 44359be..bfc55a0 100644
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-config_os_headers-Error-Fix.patch
+++ b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-config_os_headers-Error-Fix.patch
@@ -1,4 +1,4 @@
-From 261a22096c79f8e6ef7b387514a74d208e4e5945 Mon Sep 17 00:00:00 2001
+From 7ae2ce8dbf1c54d4e2db4a5f49397a239baadc49 Mon Sep 17 00:00:00 2001
 From: Li xin <lixin.fnst@cn.fujitsu.com>
 Date: Fri, 21 Aug 2015 18:23:13 +0900
 Subject: [PATCH] config_os_headers: Error Fix
@@ -13,15 +13,16 @@
 Upstream-Status: pending
 
 Signed-off-by: Li Xin <lixin.fnst@cn.fujitsu.com>
+
 ---
  configure.d/config_os_headers | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
 
-Index: net-snmp-5.7.3/configure.d/config_os_headers
-===================================================================
---- net-snmp-5.7.3.orig/configure.d/config_os_headers
-+++ net-snmp-5.7.3/configure.d/config_os_headers
-@@ -484,8 +484,8 @@ then
+diff --git a/configure.d/config_os_headers b/configure.d/config_os_headers
+index af99746..83b2e31 100644
+--- a/configure.d/config_os_headers
++++ b/configure.d/config_os_headers
+@@ -489,8 +489,8 @@ then
      unset ac_cv_header_pkg_h
      netsnmp_save_CPPFLAGS="$CPPFLAGS"
      netsnmp_save_LDFLAGS="$LDFLAGS"
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-config_os_libs2-Error-Fix.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-config_os_libs2-Error-Fix.patch
deleted file mode 100644
index 5866a95..0000000
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-config_os_libs2-Error-Fix.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From e24fcd140f3f6dd18fd836b197c6d4bb773e50e7 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Rafa=C3=ABl=20Carr=C3=A9?= <funman@videolan.org>
-Date: Wed, 4 Nov 2015 16:49:30 +0100
-Subject: [PATCH] config_os_libs2: Error Fix
-
-ERROR: This autoconf log indicates errors, it looked at host include
-and/or library paths while determining system capabilities.
----
- configure.d/config_os_libs2 | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/configure.d/config_os_libs2 b/configure.d/config_os_libs2
-index 47491e2..e3647f9 100644
---- a/configure.d/config_os_libs2
-+++ b/configure.d/config_os_libs2
-@@ -226,10 +226,10 @@ if test "x$with_nl" != "xno"; then
-     case $target_os in
-     linux*) # Check for libnl (linux)
-         netsnmp_save_CPPFLAGS="$CPPFLAGS"
--        CPPFLAGS="-I/usr/include/libnl3 $CPPFLAGS"
-+        CPPFLAGS="$CPPFLAGS"
-         NETSNMP_SEARCH_LIBS(nl_connect, nl-3,
-             [AC_CHECK_HEADERS(netlink/netlink.h)
--            EXTERNAL_MIBGROUP_INCLUDES="$EXTERNAL_MIBGROUP_INCLUDES -I/usr/include/libnl3"],
-+            EXTERNAL_MIBGROUP_INCLUDES="$EXTERNAL_MIBGROUP_INCLUDES"],
-             [CPPFLAGS="$netsnmp_save_CPPFLAGS"], [], [], [LMIBLIBS])
-         if test "x$ac_cv_header_netlink_netlink_h" != xyes; then
-             NETSNMP_SEARCH_LIBS(nl_connect, nl, [
--- 
-2.5.0
-
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-configure-fix-check-for-enable-perl-cc-checks.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-configure-fix-check-for-enable-perl-cc-checks.patch
deleted file mode 100644
index b87e9ee..0000000
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-configure-fix-check-for-enable-perl-cc-checks.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From c6304a3e4b8441ff0a6464c0f1f6c5229092fa32 Mon Sep 17 00:00:00 2001
-From: Niels Baggesen <nba@users.sourceforge.net>
-Date: Wed, 24 May 2017 16:40:03 +0800
-Subject: [PATCH 1/4] configure: fix check for --enable-perl-cc-checks
-
-This patch comes from git://git.code.sf.net/p/net-snmp/code,
-the commit is 8f431d410b803603dc809d82e0893509615d9a11.
-
-Upstream-Status: Backport
-
-Signed-off-by: Wenlin Kang <wenlin.kang@windriver.com>
----
- configure.d/config_project_perl_python | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/configure.d/config_project_perl_python b/configure.d/config_project_perl_python
-index 23f8c7e..475c843 100644
---- a/configure.d/config_project_perl_python
-+++ b/configure.d/config_project_perl_python
-@@ -84,7 +84,7 @@ if test "x$install_perl" != "xno" ; then
- 
-     #       What compiler was used to build the perl binary?
-     #
--    if test "xenable_perl_cc_checks" != "xno" ; then
-+    if test "x$enable_perl_cc_checks" != "xno" ; then
-         AC_MSG_CHECKING([for Perl cc])
-         changequote(, )
-         PERLCC=`$myperl -V:cc | $myperl -n -e 'print if (s/^\s*cc=.([-=\w\s\/]+).;\s*/$1/);'`
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-get_pid_from_inode-Include-limit.h.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-get_pid_from_inode-Include-limit.h.patch
index 60ce809..bf133b3 100644
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-get_pid_from_inode-Include-limit.h.patch
+++ b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-get_pid_from_inode-Include-limit.h.patch
@@ -1,22 +1,23 @@
-From 7136d593ba96b64537069637c328bc65e1b66b2d Mon Sep 17 00:00:00 2001
+From 98c6edba4835b515d933542411d80879327eee16 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 22 Jul 2016 18:34:39 +0000
 Subject: [PATCH] get_pid_from_inode: Include limit.h
 
 PATH_MAX and NAME_MAX are required by this file
 
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
 Upstream-Status: Pending
 
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+---
  agent/mibgroup/util_funcs/get_pid_from_inode.c | 1 +
  1 file changed, 1 insertion(+)
 
 diff --git a/agent/mibgroup/util_funcs/get_pid_from_inode.c b/agent/mibgroup/util_funcs/get_pid_from_inode.c
-index 8e157ae..a494ec7 100644
+index aee907d..7abaec2 100644
 --- a/agent/mibgroup/util_funcs/get_pid_from_inode.c
 +++ b/agent/mibgroup/util_funcs/get_pid_from_inode.c
-@@ -5,6 +5,7 @@
+@@ -6,6 +6,7 @@
  #include <net-snmp/output_api.h>
  
  #include <ctype.h>
@@ -24,6 +25,3 @@
  #include <stdio.h>
  #if HAVE_STDLIB_H
  #include <stdlib.h>
--- 
-1.8.3.1
-
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-remove-configure-options-from-versioninfo.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-remove-configure-options-from-versioninfo.patch
new file mode 100644
index 0000000..2d54096
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-remove-configure-options-from-versioninfo.patch
@@ -0,0 +1,42 @@
+From f592398b1c659f84168f5c84f63af3b71454b8f5 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Fri, 28 Sep 2018 22:59:23 +0800
+Subject: [PATCH] remove configure options from versioninfo
+
+Configure options contains host build paths which breaks
+binary reproducibility.
+
+It is no harm to remove it from version info.
+
+Upstream-Status: Inappropriate [cross compile specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ agent/mibgroup/ucd-snmp/versioninfo.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/agent/mibgroup/ucd-snmp/versioninfo.c b/agent/mibgroup/ucd-snmp/versioninfo.c
+index a5151c1..1160382 100644
+--- a/agent/mibgroup/ucd-snmp/versioninfo.c
++++ b/agent/mibgroup/ucd-snmp/versioninfo.c
+@@ -92,7 +92,7 @@ var_extensible_version(struct variable *vp,
+     static char     errmsg[300];
+     char           *cptr;
+     time_t          curtime;
+-#ifdef NETSNMP_CONFIGURE_OPTIONS
++#if 0
+     static char     config_opts[] = NETSNMP_CONFIGURE_OPTIONS;
+ #endif
+ 
+@@ -126,7 +126,7 @@ var_extensible_version(struct variable *vp,
+         *var_len = strlen(errmsg);
+         return ((u_char *) errmsg);
+     case VERCONFIG:
+-#ifdef NETSNMP_CONFIGURE_OPTIONS
++#if 0
+         *var_len = strlen(config_opts);
+         if (*var_len > 1024)
+             *var_len = 1024;    /* mib imposed restriction */
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-snmplib-UDPIPv6-transport-Add-a-missing-return-state.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-snmplib-UDPIPv6-transport-Add-a-missing-return-state.patch
deleted file mode 100644
index 527aa39..0000000
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-snmplib-UDPIPv6-transport-Add-a-missing-return-state.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-From 1ee72102fbe722d232d74abc4660a8b134cec8d6 Mon Sep 17 00:00:00 2001
-From: Bart Van Assche <bvanassche@acm.org>
-Date: Sat, 23 May 2015 07:32:53 +0200
-Subject: [PATCH] snmplib, UDPIPv6 transport: Add a missing return statement
-
-Detected by Coverity.
-
-Upstream-Status: backport
-
-Signed-off-by: Li Zhou <li.zhou@windriver.com>
----
- snmplib/transports/snmpUDPIPv6Domain.c | 1 +
- 1 file changed, 1 insertion(+)
-
-Index: net-snmp-5.7.3/snmplib/transports/snmpUDPIPv6Domain.c
-===================================================================
---- net-snmp-5.7.3.orig/snmplib/transports/snmpUDPIPv6Domain.c
-+++ net-snmp-5.7.3/snmplib/transports/snmpUDPIPv6Domain.c
-@@ -305,6 +305,7 @@ netsnmp_udp6_transport(struct sockaddr_i
-                                  errno, strerror(errno)));
-                 netsnmp_socketbase_close(t);
-                 netsnmp_transport_free(t);
-+                return NULL;
-             }
-         }
-         /*
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-snmplib-keytools.c-Don-t-check-for-return-from-EVP_M.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-snmplib-keytools.c-Don-t-check-for-return-from-EVP_M.patch
index af242fa..778b401 100644
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-snmplib-keytools.c-Don-t-check-for-return-from-EVP_M.patch
+++ b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0001-snmplib-keytools.c-Don-t-check-for-return-from-EVP_M.patch
@@ -1,7 +1,8 @@
-From d3027a227bc0f603a5b650d01f97ee1dec515be5 Mon Sep 17 00:00:00 2001
+From 89538a973119f1bf976b3a6df157ea940cf32eb5 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 18 Sep 2015 00:28:45 -0400
 Subject: [PATCH] snmplib/keytools.c: Don't check for return from
+
  EVP_MD_CTX_init()
 
 EVP_MD_CTX_init() API returns void, it fixes errors with new compilers
@@ -9,16 +10,16 @@
 snmplib/keytools.c: In function 'generate_Ku': error: invalid use of void expression
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
 ---
-Upstream-Status: Submitted [https://sourceforge.net/p/net-snmp/patches/1317/]
  snmplib/keytools.c | 3 +--
  1 file changed, 1 insertion(+), 2 deletions(-)
 
 diff --git a/snmplib/keytools.c b/snmplib/keytools.c
-index 0ccb3a6..880fc14 100644
+index 2cf0240..50fd3ea 100644
 --- a/snmplib/keytools.c
 +++ b/snmplib/keytools.c
-@@ -153,8 +153,7 @@ generate_Ku(const oid * hashtype, u_int hashtype_len,
+@@ -186,8 +186,7 @@ generate_Ku(const oid * hashtype, u_int hashtype_len,
      ctx = EVP_MD_CTX_create();
  #else
      ctx = malloc(sizeof(*ctx));
@@ -26,8 +27,5 @@
 -        return SNMPERR_GENERR;
 +    EVP_MD_CTX_init(ctx);
  #endif
- #ifndef NETSNMP_DISABLE_MD5
-     if (ISTRANSFORM(hashtype, HMACMD5Auth)) {
--- 
-2.5.2
-
+     if (!EVP_DigestInit(ctx, hashfn))
+         return SNMPERR_GENERR;
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0002-configure-fix-a-cc-check-issue.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0002-configure-fix-a-cc-check-issue.patch
index 999976d..4782714 100644
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0002-configure-fix-a-cc-check-issue.patch
+++ b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0002-configure-fix-a-cc-check-issue.patch
@@ -1,4 +1,4 @@
-From 94e7e4969bc84c945dfea12d67a1e10f61973948 Mon Sep 17 00:00:00 2001
+From a3631df3d6743113e1cd63579925e15bcce85868 Mon Sep 17 00:00:00 2001
 From: Wenlin Kang <wenlin.kang@windriver.com>
 Date: Wed, 24 May 2017 16:45:34 +0800
 Subject: [PATCH 2/4] configure: fix a cc check issue.
@@ -8,6 +8,7 @@
 can't get corretly the cc's value.
 
 Signed-off-by: Wenlin Kang <wenlin.kang@windriver.com>
+
 ---
  configure.d/config_project_perl_python | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
@@ -25,6 +26,3 @@
          changequote([, ])
          if test "x$PERLCC" != "x" ; then
              AC_MSG_RESULT([$PERLCC])
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0003-CHANGES-BUG-2712-Fix-Perl-module-compilation.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0003-CHANGES-BUG-2712-Fix-Perl-module-compilation.patch
deleted file mode 100644
index 7951234..0000000
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0003-CHANGES-BUG-2712-Fix-Perl-module-compilation.patch
+++ /dev/null
@@ -1,186 +0,0 @@
-From e57fc809ad6ae522670f3dc157aadde20d968ca7 Mon Sep 17 00:00:00 2001
-From: Bart Van Assche <bvanassche@acm.org>
-Date: Wed, 24 May 2017 17:05:03 +0800
-Subject: [PATCH 3/4] CHANGES: BUG: 2712: Fix Perl module compilation
-
-Avoid that building the Net-SNMP Perl modules fails as follows:
-
-ERROR from evaluation of /sources/net-snmp-5.7.3/perl/ASN/Makefile.PL: Bizarre \ copy of HASH in list assignment at /usr/lib/perl5/site_perl/5.24.0/Carp.pm line\ 229.
-
-See also https://sourceforge.net/p/net-snmp/bugs/2712/.
-
-This patch comes from git://git.code.sf.net/p/net-snmp/code,
-the commit is 4e793461e96a2b4fd81142ab312d074d5c8841fa.
-
-Signed-off-by: Wenlin Kang <wenlin.kang@windriver.com>
----
- perl/ASN/Makefile.PL                 | 4 +---
- perl/Makefile.PL                     | 4 +---
- perl/OID/Makefile.PL                 | 5 +----
- perl/SNMP/Makefile.PL                | 5 +----
- perl/TrapReceiver/Makefile.PL        | 5 +----
- perl/agent/Makefile.PL               | 5 +----
- perl/agent/Support/Makefile.PL       | 5 +----
- perl/agent/default_store/Makefile.PL | 5 +----
- perl/default_store/Makefile.PL       | 5 +----
- 9 files changed, 9 insertions(+), 34 deletions(-)
-
-diff --git a/perl/ASN/Makefile.PL b/perl/ASN/Makefile.PL
-index 4576781..c33d8ba 100644
---- a/perl/ASN/Makefile.PL
-+++ b/perl/ASN/Makefile.PL
-@@ -7,9 +7,7 @@ my $lib_version;
- # See lib/ExtUtils/MakeMaker.pm for details of how to influence
- # the contents of the Makefile that is written.
- 
--%MakeParams = InitMakeParams();
--
--WriteMakefile(%MakeParams);
-+WriteMakefile(InitMakeParams());
- 
- Check_Version();
- 
-diff --git a/perl/Makefile.PL b/perl/Makefile.PL
-index 31fdc40..48aba2a 100644
---- a/perl/Makefile.PL
-+++ b/perl/Makefile.PL
-@@ -3,9 +3,7 @@ use Config;
- use Getopt::Long;
- require 5;
- 
--%MakeParams = InitMakeParams();
--
--WriteMakefile(%MakeParams);
-+WriteMakefile(InitMakeParams());
- 
- sub InitMakeParams {
-     $nsconfig="net-snmp-config"; # in path by default
-diff --git a/perl/OID/Makefile.PL b/perl/OID/Makefile.PL
-index 6bb1616..2589985 100644
---- a/perl/OID/Makefile.PL
-+++ b/perl/OID/Makefile.PL
-@@ -6,11 +6,8 @@ require 5;
- use Config;
- use Getopt::Long;
- my $lib_version;
--my %MakeParams = ();
- 
--%MakeParams = InitMakeParams();
--
--WriteMakefile(%MakeParams);
-+WriteMakefile(InitMakeParams());
- 
- Check_Version();
- 
-diff --git a/perl/SNMP/Makefile.PL b/perl/SNMP/Makefile.PL
-index e617cb7..8aab9a9 100644
---- a/perl/SNMP/Makefile.PL
-+++ b/perl/SNMP/Makefile.PL
-@@ -3,15 +3,12 @@ require 5;
- use Config;
- use Getopt::Long;
- my $lib_version;
--my %MakeParams = ();
- my $opts;
- 
- # See lib/ExtUtils/MakeMaker.pm for details of how to influence
- # the contents of the Makefile that is written.
- 
--%MakeParams = InitMakeParams();
--
--WriteMakefile(%MakeParams);
-+WriteMakefile(InitMakeParams());
- 
- Check_Version();
- 
-diff --git a/perl/TrapReceiver/Makefile.PL b/perl/TrapReceiver/Makefile.PL
-index 874ee21..7e9e58e 100644
---- a/perl/TrapReceiver/Makefile.PL
-+++ b/perl/TrapReceiver/Makefile.PL
-@@ -3,11 +3,8 @@ require 5;
- use Config;
- use Getopt::Long;
- my $lib_version;
--my %MakeParams = ();
- 
--%MakeParams = InitMakeParams();
--
--WriteMakefile(%MakeParams);
-+WriteMakefile(InitMakeParams());
- 
- Check_Version();
- 
-diff --git a/perl/agent/Makefile.PL b/perl/agent/Makefile.PL
-index 4f7bee3..003c0d1 100644
---- a/perl/agent/Makefile.PL
-+++ b/perl/agent/Makefile.PL
-@@ -3,11 +3,8 @@ require 5;
- use Config;
- use Getopt::Long;
- my $lib_version;
--my %MakeParams = ();
- 
--%MakeParams = InitMakeParams();
--
--WriteMakefile(%MakeParams);
-+WriteMakefile(InitMakeParams());
- 
- Check_Version();
- 
-diff --git a/perl/agent/Support/Makefile.PL b/perl/agent/Support/Makefile.PL
-index 48815b6..2325e10 100644
---- a/perl/agent/Support/Makefile.PL
-+++ b/perl/agent/Support/Makefile.PL
-@@ -3,14 +3,11 @@ require 5;
- use Config;
- use Getopt::Long;
- my $lib_version;
--my %MakeParams = ();
- 
- # See lib/ExtUtils/MakeMaker.pm for details of how to influence
- # the contents of the Makefile that is written.
- 
--%MakeParams = InitMakeParams();
--
--WriteMakefile(%MakeParams);
-+WriteMakefile(InitMakeParams());
- 
- Check_Version();
- 
-diff --git a/perl/agent/default_store/Makefile.PL b/perl/agent/default_store/Makefile.PL
-index ed6483a..31cfbee 100644
---- a/perl/agent/default_store/Makefile.PL
-+++ b/perl/agent/default_store/Makefile.PL
-@@ -3,11 +3,8 @@ require 5;
- use Config;
- use Getopt::Long;
- my $lib_version;
--my %MakeParams = ();
- 
--%MakeParams = InitMakeParams();
--
--WriteMakefile(%MakeParams);
-+WriteMakefile(InitMakeParams());
- 
- Check_Version();
- 
-diff --git a/perl/default_store/Makefile.PL b/perl/default_store/Makefile.PL
-index 7c671b8..01c8dd0 100644
---- a/perl/default_store/Makefile.PL
-+++ b/perl/default_store/Makefile.PL
-@@ -3,11 +3,8 @@ require 5;
- use Config;
- use Getopt::Long;
- my $lib_version;
--my %MakeParams = ();
- 
--%MakeParams = InitMakeParams();
--
--WriteMakefile(%MakeParams);
-+WriteMakefile(InitMakeParams());
- 
- 
- sub InitMakeParams {
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0004-configure-fix-incorrect-variable.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0004-configure-fix-incorrect-variable.patch
index 2b03f9e..a3d84b2 100644
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0004-configure-fix-incorrect-variable.patch
+++ b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/0004-configure-fix-incorrect-variable.patch
@@ -1,4 +1,4 @@
-From 4ad98ef125eb4e7d7a1a93146042002f78254d36 Mon Sep 17 00:00:00 2001
+From f3c5cd4df7ce8e5639c99b7b918e41fb89e969e3 Mon Sep 17 00:00:00 2001
 From: Wenlin Kang <wenlin.kang@windriver.com>
 Date: Wed, 24 May 2017 17:10:20 +0800
 Subject: [PATCH 4/4] configure: fix incorrect variable
@@ -8,15 +8,16 @@
 Upstream-Status: Inappropriate [cross compile specific]
 
 Signed-off-by: Wenlin Kang <wenlin.kang@windriver.com>
+
 ---
  Makefile.in | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/Makefile.in b/Makefile.in
-index cfcdf73..164df05 100644
+index 9dbdde1..5fdc760 100644
 --- a/Makefile.in
 +++ b/Makefile.in
-@@ -171,7 +171,7 @@ OTHERCLEANTODOS=perlclean @PYTHONCLEANTARGS@ cleanfeatures perlcleanfeatures pyt
+@@ -173,7 +173,7 @@ OTHERCLEANTODOS=perlclean @PYTHONCLEANTARGS@ cleanfeatures perlcleanfeatures pyt
  #
  # override LD_RUN_PATH to avoid dependencies on the build directory
  perlmodules: perlmakefiles subdirs
@@ -25,6 +26,3 @@
          if test $$? != 0 ; then \
             exit 1 ; \
          fi
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/dont-return-incompletely-parsed-varbinds.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/dont-return-incompletely-parsed-varbinds.patch
deleted file mode 100644
index 6bd0f93..0000000
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/dont-return-incompletely-parsed-varbinds.patch
+++ /dev/null
@@ -1,131 +0,0 @@
-From 6b93e686bdb6a908d00595608646a05527a5326b Mon Sep 17 00:00:00 2001
-From: Li xin <lixin.fnst@cn.fujitsu.com>
-Date: Fri, 21 Aug 2015 12:39:12 +0900
-Subject: [PATCH] the snmp_pdu_parse() function could leave incompletely parsed
- varBind variables in the list of variables in case the parsing of the SNMP
- PDU failed. If later processing tries to operate on the stale and
- incompletely processed varBind (e.g. when printing the variables), this can
- lead to e.g. crashes or, possibly, execution of arbitrary code
-
-Upstream-Status: Backport [net-snmp]
-
-Written-by: Robert Story
----
- snmplib/snmp_api.c | 53 ++++++++++++++++++++++++++++-------------------------
- 1 file changed, 28 insertions(+), 25 deletions(-)
-
-diff --git a/snmplib/snmp_api.c b/snmplib/snmp_api.c
-index 191debf..15a2d39 100644
---- a/snmplib/snmp_api.c
-+++ b/snmplib/snmp_api.c
-@@ -4350,10 +4350,9 @@ snmp_pdu_parse(netsnmp_pdu *pdu, u_char * data, size_t * length)
-     u_char          type;
-     u_char          msg_type;
-     u_char         *var_val;
--    int             badtype = 0;
-     size_t          len;
-     size_t          four;
--    netsnmp_variable_list *vp = NULL;
-+    netsnmp_variable_list *vp = NULL, *vplast = NULL;
-     oid             objid[MAX_OID_LEN];
-     u_char         *p;
- 
-@@ -4493,31 +4492,17 @@ snmp_pdu_parse(netsnmp_pdu *pdu, u_char * data, size_t * length)
-                               (ASN_SEQUENCE | ASN_CONSTRUCTOR),
-                               "varbinds");
-     if (data == NULL)
--        return -1;
-+        goto fail;
- 
-     /*
-      * get each varBind sequence 
-      */
-     while ((int) *length > 0) {
--        netsnmp_variable_list *vptemp;
--        vptemp = (netsnmp_variable_list *) malloc(sizeof(*vptemp));
--        if (NULL == vptemp) {
--            return -1;
--        }
--        if (NULL == vp) {
--            pdu->variables = vptemp;
--        } else {
--            vp->next_variable = vptemp;
--        }
--        vp = vptemp;
-+        vp = SNMP_MALLOC_TYPEDEF(netsnmp_variable_list);
-+        if (NULL == vp)
-+            goto fail;
- 
--        vp->next_variable = NULL;
--        vp->val.string = NULL;
-         vp->name_length = MAX_OID_LEN;
--        vp->name = NULL;
--        vp->index = 0;
--        vp->data = NULL;
--        vp->dataFreeHook = NULL;
-         DEBUGDUMPSECTION("recv", "VarBind");
-         data = snmp_parse_var_op(data, objid, &vp->name_length, &vp->type,
-                                  &vp->val_len, &var_val, length);
-@@ -4604,7 +4589,7 @@ snmp_pdu_parse(netsnmp_pdu *pdu, u_char * data, size_t * length)
-                 vp->val.string = (u_char *) malloc(vp->val_len);
-             }
-             if (vp->val.string == NULL) {
--                return -1;
-+                goto fail;
-             }
-             p = asn_parse_string(var_val, &len, &vp->type, vp->val.string,
-                              &vp->val_len);
-@@ -4619,7 +4604,7 @@ snmp_pdu_parse(netsnmp_pdu *pdu, u_char * data, size_t * length)
-             vp->val_len *= sizeof(oid);
-             vp->val.objid = (oid *) malloc(vp->val_len);
-             if (vp->val.objid == NULL) {
--                return -1;
-+                goto fail;
-             }
-             memmove(vp->val.objid, objid, vp->val_len);
-             break;
-@@ -4631,7 +4616,7 @@ snmp_pdu_parse(netsnmp_pdu *pdu, u_char * data, size_t * length)
-         case ASN_BIT_STR:
-             vp->val.bitstring = (u_char *) malloc(vp->val_len);
-             if (vp->val.bitstring == NULL) {
--                return -1;
-+                goto fail;
-             }
-             p = asn_parse_bitstring(var_val, &len, &vp->type,
-                                 vp->val.bitstring, &vp->val_len);
-@@ -4640,12 +4625,30 @@ snmp_pdu_parse(netsnmp_pdu *pdu, u_char * data, size_t * length)
-             break;
-         default:
-             snmp_log(LOG_ERR, "bad type returned (%x)\n", vp->type);
--            badtype = -1;
-+            goto fail;
-             break;
-         }
-         DEBUGINDENTADD(-4);
-+
-+        if (NULL == vplast) {
-+            pdu->variables = vp;
-+        } else {
-+            vplast->next_variable = vp;
-+        }
-+        vplast = vp;
-+        vp = NULL;
-+
-     }
--    return badtype;
-+    return 0;
-+
-+  fail:
-+    DEBUGMSGTL(("recv", "error while parsing VarBindList\n"));
-+    /** if we were parsing a var, remove it from the pdu and free it */
-+    if (vp)
-+        snmp_free_var(vp);
-+
-+    return -1;
-+
- }
- 
- /*
--- 
-1.8.4.2
-
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/fix-libtool-finish.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/fix-libtool-finish.patch
index d29be33..fc3ac2a 100644
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/fix-libtool-finish.patch
+++ b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/fix-libtool-finish.patch
@@ -1,3 +1,8 @@
+From 0becb4843a40910d5ec9aa11969d4905a22037cf Mon Sep 17 00:00:00 2001
+From: "Roy.Li" <rongqing.li@windriver.com>
+Date: Fri, 16 Jan 2015 14:14:01 +0800
+Subject: [PATCH] net-snmp: fix "libtool --finish"
+
 LIB_LDCONFIG_CMD failed since it is using a host dir $(libdir)
 which is /usr/lib64 does not exist on host when compile 64bit
 image.
@@ -9,12 +14,16 @@
 Upstream-Status: Inappropriate [cross compile specific]
 
 Signed-off-by: Roy.Li <rongqing.li@windriver.com>
+
 ---
-Index: net-snmp-5.7.3/Makefile.top
-===================================================================
---- net-snmp-5.7.3.orig/Makefile.top
-+++ net-snmp-5.7.3/Makefile.top
-@@ -87,7 +87,7 @@ LIBREVISION = 3
+ Makefile.top | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/Makefile.top b/Makefile.top
+index 5d4f9bc..d0ed31c 100644
+--- a/Makefile.top
++++ b/Makefile.top
+@@ -89,7 +89,7 @@ LIBREVISION = 0
  LIB_LD_CMD      = $(LIBTOOL) --mode=link $(LINKCC) $(CFLAGS) -rpath $(libdir) -version-info $(LIBCURRENT):$(LIBREVISION):$(LIBAGE) -o
  LIB_EXTENSION   = la
  LIB_VERSION     =
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/net-snmp-5.7.2-fix-engineBoots-value-on-SIGHUP.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/net-snmp-5.7.2-fix-engineBoots-value-on-SIGHUP.patch
index fbd274b..5cbb60d 100644
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/net-snmp-5.7.2-fix-engineBoots-value-on-SIGHUP.patch
+++ b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/net-snmp-5.7.2-fix-engineBoots-value-on-SIGHUP.patch
@@ -1,4 +1,4 @@
-From e47c60dc7f649959f63e56bc62355de4bdfd73f4 Mon Sep 17 00:00:00 2001
+From d619cd9fc01f336ff0ff55b18f9112789eb4d84c Mon Sep 17 00:00:00 2001
 From: Marian Florea <marian.florea@windriver.com>
 Date: Thu, 20 Jul 2017 16:55:24 +0800
 Subject: [PATCH] net snmp: fix engineBoots value on SIGHUP
@@ -7,16 +7,17 @@
 
 Signed-off-by: Marian Florea <marian.florea@windriver.com>
 Signed-off-by: Li Zhou <li.zhou@windriver.com>
+
 ---
  agent/snmpd.c    | 1 +
  snmplib/snmpv3.c | 4 ++--
  2 files changed, 3 insertions(+), 2 deletions(-)
 
-Index: net-snmp-5.7.3/agent/snmpd.c
-===================================================================
---- net-snmp-5.7.3.orig/agent/snmpd.c
-+++ net-snmp-5.7.3/agent/snmpd.c
-@@ -1253,6 +1253,7 @@ receive(void)
+diff --git a/agent/snmpd.c b/agent/snmpd.c
+index 6566354..eb0d4b4 100644
+--- a/agent/snmpd.c
++++ b/agent/snmpd.c
+@@ -1239,6 +1239,7 @@ receive(void)
  	    snmp_log(LOG_INFO, "NET-SNMP version %s restarted\n",
  		     netsnmp_get_version());
              update_config();
@@ -24,11 +25,11 @@
              send_easy_trap(SNMP_TRAP_ENTERPRISESPECIFIC, 3);
  #if HAVE_SIGHOLD
              sigrelse(SIGHUP);
-Index: net-snmp-5.7.3/snmplib/snmpv3.c
-===================================================================
---- net-snmp-5.7.3.orig/snmplib/snmpv3.c
-+++ net-snmp-5.7.3/snmplib/snmpv3.c
-@@ -984,9 +984,9 @@ init_snmpv3_post_config(int majorid, int
+diff --git a/snmplib/snmpv3.c b/snmplib/snmpv3.c
+index 771ba3b..5de05e7 100644
+--- a/snmplib/snmpv3.c
++++ b/snmplib/snmpv3.c
+@@ -1060,9 +1060,9 @@ init_snmpv3_post_config(int majorid, int minorid, void *serverarg,
      /*
       * if our engineID has changed at all, the boots record must be set to 1 
       */
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/net-snmp-agentx-crash.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/net-snmp-agentx-crash.patch
deleted file mode 100644
index 5eed893..0000000
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/net-snmp-agentx-crash.patch
+++ /dev/null
@@ -1,75 +0,0 @@
-Description: fix snmpd crash via AgentX connection
-
- taken from Fedora, net-snmp-5.7-agentx-crash.patch
-
-bz729738 - net-snmp dumps core in netsnmp_oid_find_prefix
-bz1038011 - net-snmp: snmpd crashes/hangs when AgentX subagent times-out
-
-commit f9304c83f76202db0e684269ca1af32e43cd9db4
-Author: Jan Safranek <jsafranek@users.sourceforge.net>
-Date:   Tue Feb 7 14:53:44 2012 +0100
-
-    CHANGES: PATCH 1633670: fixed snmpd crashing when an AgentX subagent
-    disconnect in the middle of processing of a request.
-
-    I fixed also the memory leak reported in the tracker comments.
-
-Upstream-Status: Backport
-
-Signed-off-by: Zhu Yanjun <yanjun.zhu@windriver.com>
-Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
-
----
- agent/mibgroup/agentx/master.c       | 5 +++++
- agent/mibgroup/agentx/master_admin.c | 9 +++++++--
- 2 files changed, 12 insertions(+), 2 deletions(-)
-
-diff --git a/agent/mibgroup/agentx/master.c b/agent/mibgroup/agentx/master.c
-index c42a42a..baeebaf 100644
---- a/agent/mibgroup/agentx/master.c
-+++ b/agent/mibgroup/agentx/master.c
-@@ -219,6 +219,9 @@ agentx_got_response(int operation,
-     if (!cache) {
-         DEBUGMSGTL(("agentx/master", "response too late on session %8p\n",
-                     session));
-+        /* response is too late, free the cache */
-+        if (magic)
-+            netsnmp_free_delegated_cache((netsnmp_delegated_cache*) magic);
-         return 0;
-     }
-     requests = cache->requests;
-@@ -606,6 +609,8 @@ agentx_master_handler(netsnmp_mib_handler *handler,
-     result = snmp_async_send(ax_session, pdu, agentx_got_response, cb_data);
-     if (result == 0) {
-         snmp_free_pdu(pdu);
-+        if (cb_data)
-+            netsnmp_free_delegated_cache((netsnmp_delegated_cache*) cb_data);
-     }
- 
-     return SNMP_ERR_NOERROR;
-diff --git a/agent/mibgroup/agentx/master_admin.c b/agent/mibgroup/agentx/master_admin.c
-index f16f392..b84b85e 100644
---- a/agent/mibgroup/agentx/master_admin.c
-+++ b/agent/mibgroup/agentx/master_admin.c
-@@ -133,11 +133,16 @@ close_agentx_session(netsnmp_session * session, int sessid)
-          * requests, so that the delegated request will be completed and
-          * further requests can be processed
-          */
--        netsnmp_remove_delegated_requests_for_session(session);
-+	while (netsnmp_remove_delegated_requests_for_session(session)) {
-+		DEBUGMSGTL(("agentx/master", "Continue removing delegated reqests\n"));
-+	}
-+
-         if (session->subsession != NULL) {
-             netsnmp_session *subsession = session->subsession;
-             for(; subsession; subsession = subsession->next) {
--                netsnmp_remove_delegated_requests_for_session(subsession);
-+                while (netsnmp_remove_delegated_requests_for_session(subsession)) {
-+			DEBUGMSGTL(("agentx/master", "Continue removing delegated subsession reqests\n"));
-+		}
-             }
-         }
-                 
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/net-snmp-fix-for-disable-des.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/net-snmp-fix-for-disable-des.patch
index 25eb9c9..4cd8fd1 100644
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/net-snmp-fix-for-disable-des.patch
+++ b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/net-snmp-fix-for-disable-des.patch
@@ -1,4 +1,4 @@
-From 270e952f58a7e5ddeabe5a15e3ddaaadf40017d0 Mon Sep 17 00:00:00 2001
+From 068952c0e0cdda5a91250b91c5fcc9b85b43daab Mon Sep 17 00:00:00 2001
 From: Jackie Huang <jackie.huang@windriver.com>
 Date: Thu, 22 Jun 2017 10:25:08 +0800
 Subject: [PATCH] net-snmp: fix for --disable-des
@@ -9,15 +9,16 @@
 Upstream-Status: Submitted [net-snmp-coders@lists.sourceforge.net]
 
 Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
+
 ---
  snmplib/scapi.c | 2 ++
  1 file changed, 2 insertions(+)
 
 diff --git a/snmplib/scapi.c b/snmplib/scapi.c
-index 16ac829..271684b 100644
+index 8ad1d70..43caddf 100644
 --- a/snmplib/scapi.c
 +++ b/snmplib/scapi.c
-@@ -79,7 +79,9 @@ netsnmp_feature_child_of(usm_scapi, usm_support)
+@@ -84,7 +84,9 @@ netsnmp_feature_child_of(usm_scapi, usm_support)
  #include <openssl/hmac.h>
  #include <openssl/evp.h>
  #include <openssl/rand.h>
@@ -27,6 +28,3 @@
  #ifdef HAVE_AES
  #include <openssl/aes.h>
  #endif
--- 
-2.11.0
-
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/net-snmp-testing-add-the-output-format-for-ptest.patch b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/net-snmp-testing-add-the-output-format-for-ptest.patch
index 8f8336a..7cbaf0b 100644
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/net-snmp-testing-add-the-output-format-for-ptest.patch
+++ b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp/net-snmp-testing-add-the-output-format-for-ptest.patch
@@ -1,4 +1,4 @@
-From 4bb4024b395f19d36ab3569e2773ea80d8cc5261 Mon Sep 17 00:00:00 2001
+From 827fe3b0253aab33472828f40ad05934cc0261b8 Mon Sep 17 00:00:00 2001
 From: Jackie Huang <jackie.huang@windriver.com>
 Date: Wed, 14 Jan 2015 15:10:06 +0800
 Subject: [PATCH] testing: add the output format for ptest
@@ -6,15 +6,16 @@
 Upstream-Status: Inappropriate [OE specific]
 
 Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
----
- testing/RUNTESTS |    4 ++++
- 1 files changed, 4 insertions(+), 0 deletions(-)
 
-Index: net-snmp-5.7.3/testing/RUNTESTS
-===================================================================
---- net-snmp-5.7.3.orig/testing/RUNTESTS
-+++ net-snmp-5.7.3/testing/RUNTESTS
-@@ -29,13 +29,17 @@ failed_count=0
+---
+ testing/RUNTESTS | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/testing/RUNTESTS b/testing/RUNTESTS
+index 6715831..a2b6fb8 100755
+--- a/testing/RUNTESTS
++++ b/testing/RUNTESTS
+@@ -17,13 +17,17 @@ failed_count=0
  rm -f failed_tests
  for i in "${srcdir}"/testing/fulltests/default/T*$1*; do
      echo "RUNNING $i"
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp_5.7.3.bb b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp_5.7.3.bb
deleted file mode 100644
index 4ea0a59..0000000
--- a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp_5.7.3.bb
+++ /dev/null
@@ -1,259 +0,0 @@
-SUMMARY = "Various tools relating to the Simple Network Management Protocol"
-HOMEPAGE = "http://www.net-snmp.org/"
-SECTION = "net"
-LICENSE = "BSD"
-
-LIC_FILES_CHKSUM = "file://README;beginline=3;endline=8;md5=7f7f00ba639ac8e8deb5a622ea24634e"
-
-DEPENDS = "openssl libnl pciutils"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/net-snmp/net-snmp-${PV}.zip \
-           file://init \
-           file://snmpd.conf \
-           file://snmptrapd.conf \
-           file://systemd-support.patch \
-           file://snmpd.service \
-           file://snmptrapd.service \
-           file://net-snmp-add-knob-whether-nlist.h-are-checked.patch \
-           file://fix-libtool-finish.patch \
-           file://net-snmp-testing-add-the-output-format-for-ptest.patch \
-           file://run-ptest \
-           file://dont-return-incompletely-parsed-varbinds.patch \
-           file://0001-config_os_headers-Error-Fix.patch \
-           file://0001-config_os_libs2-Error-Fix.patch \
-           file://0001-snmplib-keytools.c-Don-t-check-for-return-from-EVP_M.patch \
-           file://net-snmp-agentx-crash.patch \
-           file://0001-get_pid_from_inode-Include-limit.h.patch \
-           file://0001-BUG-a2584-Fix-snmptrap-to-use-clientaddr-from-snmp.c.patch \
-           file://0001-snmplib-UDPIPv6-transport-Add-a-missing-return-state.patch \
-           file://0001-configure-fix-check-for-enable-perl-cc-checks.patch \
-           file://0002-configure-fix-a-cc-check-issue.patch \
-           file://0003-CHANGES-BUG-2712-Fix-Perl-module-compilation.patch \
-           file://0004-configure-fix-incorrect-variable.patch \
-           file://net-snmp-5.7.2-fix-engineBoots-value-on-SIGHUP.patch \
-           file://net-snmp-fix-for-disable-des.patch \
-           file://0001-Remove-U64-typedef.patch \
-           "
-SRC_URI[md5sum] = "9f682bd70c717efdd9f15b686d07baee"
-SRC_URI[sha256sum] = "e8dfc79b6539b71a6ff335746ce63d2da2239062ad41872fff4354cafed07a3e"
-
-inherit autotools-brokensep update-rc.d siteinfo systemd pkgconfig perlnative
-
-EXTRA_OEMAKE = "INSTALL_PREFIX=${D} OTHERLDFLAGS='${LDFLAGS}' HOST_CPPFLAGS='${BUILD_CPPFLAGS}'"
-
-PARALLEL_MAKE = ""
-CCACHE = ""
-
-TARGET_CC_ARCH += "${LDFLAGS}"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[elfutils] = "--with-elf, --without-elf, elfutils"
-PACKAGECONFIG[libnl] = "--with-nl, --without-nl, libnl"
-
-PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}"
-PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,,"
-
-PACKAGECONFIG[perl] = "--enable-embedded-perl --with-perl-modules=yes, --disable-embedded-perl --with-perl-modules=no,\
-                       perl, perl perl-lib"
-
-EXTRA_OECONF = "--enable-shared \
-                --disable-manuals \
-                --with-defaults \
-                --with-install-prefix=${D} \
-                --with-persistent-directory=${localstatedir}/lib/net-snmp \
-                ${@oe.utils.conditional('SITEINFO_ENDIANNESS', 'le', '--with-endianness=little', '--with-endianness=big', d)} \
-"
-
-# net-snmp needs to have mib-modules=smux enabled to enable quagga to support snmp
-EXTRA_OECONF += "--with-mib-modules=smux"
-
-CACHED_CONFIGUREVARS = " \
-    ac_cv_header_valgrind_valgrind_h=no \
-    ac_cv_header_valgrind_memcheck_h=no \
-    ac_cv_ETC_MNTTAB=/etc/mtab \
-    lt_cv_shlibpath_overrides_runpath=yes \
-"
-export PERLPROG="${bindir}/env perl"
-PERLPROG_append = "${@bb.utils.contains('PACKAGECONFIG', 'perl', ' -I${WORKDIR}', '', d)}"
-
-HAS_PERL = "${@bb.utils.contains('PACKAGECONFIG', 'perl', '1', '0', d)}"
-
-do_configure_prepend() {
-    sed -i -e "s|I/usr/include|I${STAGING_INCDIR}|g" \
-        "${S}"/configure \
-        "${S}"/configure.d/config_os_libs2
-
-    if [ "${HAS_PERL}" = "1" ]; then
-        # this may need to be changed when package perl has any change.
-        cp -f ${STAGING_DIR_TARGET}/usr/lib*/perl/*/Config.pm ${WORKDIR}/
-        cp -f ${STAGING_DIR_TARGET}/usr/lib*/perl/*/Config_heavy.pl ${WORKDIR}/
-        sed -e "s@libpth => '/usr/lib.*@libpth => '${STAGING_DIR_TARGET}/${libdir} ${STAGING_DIR_TARGET}/${base_libdir}',@g" \
-            -e "s@privlibexp => '/usr@privlibexp => '${STAGING_DIR_TARGET}/usr@g" \
-            -e "s@scriptdir => '/usr@scriptdir => '${STAGING_DIR_TARGET}/usr@g" \
-            -e "s@sitearchexp => '/usr@sitearchexp => '${STAGING_DIR_TARGET}/usr@g" \
-            -e "s@sitelibexp => '/usr@sitearchexp => '${STAGING_DIR_TARGET}/usr@g" \
-            -e "s@vendorarchexp => '/usr@vendorarchexp => '${STAGING_DIR_TARGET}/usr@g" \
-            -e "s@vendorlibexp => '/usr@vendorlibexp => '${STAGING_DIR_TARGET}/usr@g" \
-            -i ${WORKDIR}/Config.pm
-    fi
-
-}
-
-do_configure_append() {
-    if [ "${HAS_PERL}" = "1" ]; then
-        sed -e "s@^NSC_INCLUDEDIR=.*@NSC_INCLUDEDIR=${STAGING_DIR_TARGET}\$\{includedir\}@g" \
-            -e "s@^NSC_LIBDIR=-L.*@NSC_LIBDIR=-L${STAGING_DIR_TARGET}\$\{libdir\}@g" \
-            -i ${B}/net-snmp-config
-    fi
-}
-
-do_install_append() {
-    install -d ${D}${sysconfdir}/snmp
-    install -d ${D}${sysconfdir}/init.d
-    install -m 755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/snmpd
-    install -m 644 ${WORKDIR}/snmpd.conf ${D}${sysconfdir}/snmp/
-    install -m 644 ${WORKDIR}/snmptrapd.conf ${D}${sysconfdir}/snmp/
-    install -d ${D}${systemd_unitdir}/system
-    install -m 0644 ${WORKDIR}/snmpd.service ${D}${systemd_unitdir}/system
-    install -m 0644 ${WORKDIR}/snmptrapd.service ${D}${systemd_unitdir}/system
-    sed    -e "s@^NSC_SRCDIR=.*@NSC_SRCDIR=.@g" \
-        -i ${D}${bindir}/net-snmp-create-v3-user
-    sed    -e "s@^NSC_SRCDIR=.*@NSC_SRCDIR=.@g" \
-           -e "s@\([^ ]*-fdebug-prefix-map=[^ ]*\)\1*@@g" \
-           -e "s@\([^ ]*--sysroot=[^ ]*\)\1*@@g" \
-           -e "s@\([^ ]*--with-libtool-sysroot=[^ ]*\)\1*@@g" \
-           -e "s@\([^ ]*--with-install-prefix=[^ ]*\)\1*@@g" \
-        -i ${D}${bindir}/net-snmp-config
-
-    if [ "${HAS_PERL}" = "1" ]; then
-        sed -e "s@^NSC_INCLUDEDIR=.*@NSC_INCLUDEDIR=\$\{includedir\}@g" \
-            -e "s@^NSC_LIBDIR=-L.*@NSC_LIBDIR=-L\$\{libdir\}@g" \
-            -i ${D}${bindir}/net-snmp-config
-    fi
-}
-
-do_install_ptest() {
-    install -d ${D}${PTEST_PATH}
-    for i in ${S}/dist ${S}/include ${B}/include ${S}/mibs ${S}/configure \
-        ${B}/net-snmp-config ${S}/testing; do
-        if [ -e "$i" ]; then
-            cp -R --no-dereference --preserve=mode,links -v "$i" ${D}${PTEST_PATH}
-        fi
-    done
-    echo `autoconf -V|awk '/autoconf/{print $NF}'` > ${D}${PTEST_PATH}/dist/autoconf-version
-
-    rmdlist="${D}${PTEST_PATH}/dist/net-snmp-solaris-build"
-    for i in $rmdlist; do
-        if [ -d "$i" ]; then
-            rm -rf "$i"
-        fi
-    done
-}
-
-SYSROOT_PREPROCESS_FUNCS += "net_snmp_sysroot_preprocess"
-SNMP_DBGDIR = "/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR}"
-
-net_snmp_sysroot_preprocess () {
-    if [ -e ${D}${bindir}/net-snmp-config ]; then
-        install -d ${SYSROOT_DESTDIR}${bindir_crossscripts}/
-        install -m 755 ${D}${bindir}/net-snmp-config ${SYSROOT_DESTDIR}${bindir_crossscripts}/
-        sed -e "s@-I/usr/include@-I${STAGING_INCDIR}@g" \
-            -e "s@^prefix=.*@prefix=${STAGING_DIR_HOST}${prefix}@g" \
-            -e "s@^exec_prefix=.*@exec_prefix=${STAGING_EXECPREFIXDIR}@g" \
-            -e "s@^includedir=.*@includedir=${STAGING_INCDIR}@g" \
-            -e "s@^libdir=.*@libdir=${STAGING_LIBDIR}@g" \
-            -e "s@^NSC_SRCDIR=.*@NSC_SRCDIR=${S}@g" \
-            -e "s@-fdebug-prefix-map=${SNMP_DBGDIR}@-fdebug-prefix-map=${WORKDIR}=${SNMP_DBGDIR}@g" \
-            -e "s@-fdebug-prefix-map= -fdebug-prefix-map=@-fdebug-prefix-map=${STAGING_DIR_NATIVE}= \
-                  -fdebug-prefix-map=${STAGING_DIR_HOST}=@g" \
-            -e "s@--sysroot=@--sysroot=${STAGING_DIR_HOST}@g" \
-            -e "s@--with-libtool-sysroot=@--with-libtool-sysroot=${STAGING_DIR_HOST}@g" \
-            -e "s@--with-install-prefix=@--with-install-prefix=${D}@g" \
-          -i  ${SYSROOT_DESTDIR}${bindir_crossscripts}/net-snmp-config
-    fi
-}
-
-PACKAGES += "${PN}-libs ${PN}-mibs ${PN}-server ${PN}-client \
-             ${PN}-server-snmpd ${PN}-server-snmptrapd \
-             ${PN}-lib-netsnmp ${PN}-lib-agent ${PN}-lib-helpers \
-             ${PN}-lib-mibs ${PN}-lib-trapd"
-
-# perl module
-PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'perl', '${PN}-perl-modules', '', d)}"
-
-ALLOW_EMPTY_${PN} = "1"
-ALLOW_EMPTY_${PN}-server = "1"
-ALLOW_EMPTY_${PN}-libs = "1"
-
-FILES_${PN}-perl-modules = "${libdir}/perl/*"
-
-FILES_${PN}-libs = ""
-FILES_${PN}-mibs = "${datadir}/snmp/mibs"
-FILES_${PN}-server-snmpd = "${sbindir}/snmpd \
-                            ${sysconfdir}/snmp/snmpd.conf \
-                            ${sysconfdir}/init.d \
-                            ${systemd_unitdir}/system/snmpd.service \
-"
-
-FILES_${PN}-server-snmptrapd = "${sbindir}/snmptrapd \
-                                ${sysconfdir}/snmp/snmptrapd.conf \
-                                ${systemd_unitdir}/system/snmptrapd.service \
-"
-
-FILES_${PN}-lib-netsnmp = "${libdir}/libnetsnmp${SOLIBS}"
-FILES_${PN}-lib-agent = "${libdir}/libnetsnmpagent${SOLIBS}"
-FILES_${PN}-lib-helpers = "${libdir}/libnetsnmphelpers${SOLIBS}"
-FILES_${PN}-lib-mibs = "${libdir}/libnetsnmpmibs${SOLIBS}"
-FILES_${PN}-lib-trapd = "${libdir}/libnetsnmptrapd${SOLIBS}"
-
-FILES_${PN} = ""
-FILES_${PN}-client = "${bindir}/* ${datadir}/snmp/"
-FILES_${PN}-dbg += "${libdir}/.debug/ ${sbindir}/.debug/ ${bindir}/.debug/"
-FILES_${PN}-dev += "${bindir}/mib2c ${bindir}/mib2c-update"
-
-CONFFILES_${PN}-server-snmpd = "${sysconfdir}/snmp/snmpd.conf"
-CONFFILES_${PN}-server-snmptrapd = "${sysconfdir}/snmp/snmptrapd.conf"
-
-INITSCRIPT_PACKAGES = "${PN}-server-snmpd"
-INITSCRIPT_NAME_${PN}-server-snmpd = "snmpd"
-INITSCRIPT_PARAMS_${PN}-server-snmpd = "start 90 2 3 4 5 . stop 60 0 1 6 ."
-
-EXTRA_OECONF += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '--with-systemd', '--without-systemd', d)}"
-
-SYSTEMD_PACKAGES = "${PN}-server-snmpd \
-                    ${PN}-server-snmptrapd"
-
-SYSTEMD_SERVICE_${PN}-server-snmpd = "snmpd.service"
-SYSTEMD_SERVICE_${PN}-server-snmptrapd =  "snmptrapd.service"
-
-RDEPENDS_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'perl', 'net-snmp-perl-modules', '', d)}"
-RDEPENDS_${PN} += "net-snmp-client"
-RDEPENDS_${PN}-server-snmpd += "net-snmp-mibs"
-RDEPENDS_${PN}-server-snmptrapd += "net-snmp-server-snmpd ${PN}-lib-trapd"
-RDEPENDS_${PN}-server += "net-snmp-server-snmpd net-snmp-server-snmptrapd"
-RDEPENDS_${PN}-client += "net-snmp-mibs net-snmp-libs"
-RDEPENDS_${PN}-libs += "libpci \
-                        ${PN}-lib-netsnmp \
-                        ${PN}-lib-agent \
-                        ${PN}-lib-helpers \
-                        ${PN}-lib-mibs \
-"
-RDEPENDS_${PN}-ptest += "perl \
-                         perl-module-test \
-                         perl-module-file-basename \
-                         perl-module-getopt-long \
-                         perl-module-file-temp \
-                         perl-module-data-dumper \
-"
-RDEPENDS_${PN}-dev = "net-snmp-client (= ${EXTENDPKGV}) net-snmp-server (= ${EXTENDPKGV})"
-RRECOMMENDS_${PN}-dbg = "net-snmp-client (= ${EXTENDPKGV}) net-snmp-server (= ${EXTENDPKGV})"
-
-RPROVIDES_${PN}-server-snmpd += "${PN}-server-snmpd-systemd"
-RREPLACES_${PN}-server-snmpd += "${PN}-server-snmpd-systemd"
-RCONFLICTS_${PN}-server-snmpd += "${PN}-server-snmpd-systemd"
-
-RPROVIDES_${PN}-server-snmptrapd += "${PN}-server-snmptrapd-systemd"
-RREPLACES_${PN}-server-snmptrapd += "${PN}-server-snmptrapd-systemd"
-RCONFLICTS_${PN}-server-snmptrapd += "${PN}-server-snmptrapd-systemd"
-
-LEAD_SONAME = "libnetsnmp.so"
diff --git a/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp_5.8.bb b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp_5.8.bb
new file mode 100644
index 0000000..d47f9e4
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-protocols/net-snmp/net-snmp_5.8.bb
@@ -0,0 +1,261 @@
+SUMMARY = "Various tools relating to the Simple Network Management Protocol"
+HOMEPAGE = "http://www.net-snmp.org/"
+SECTION = "net"
+LICENSE = "BSD"
+
+LIC_FILES_CHKSUM = "file://README;beginline=3;endline=8;md5=7f7f00ba639ac8e8deb5a622ea24634e"
+
+DEPENDS = "openssl libnl pciutils"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/net-snmp/net-snmp-${PV}.zip \
+           file://init \
+           file://snmpd.conf \
+           file://snmptrapd.conf \
+           file://snmpd.service \
+           file://snmptrapd.service \
+           file://net-snmp-add-knob-whether-nlist.h-are-checked.patch \
+           file://fix-libtool-finish.patch \
+           file://net-snmp-testing-add-the-output-format-for-ptest.patch \
+           file://run-ptest \
+           file://0001-config_os_headers-Error-Fix.patch \
+           file://0001-snmplib-keytools.c-Don-t-check-for-return-from-EVP_M.patch \
+           file://0001-get_pid_from_inode-Include-limit.h.patch \
+           file://0002-configure-fix-a-cc-check-issue.patch \
+           file://0004-configure-fix-incorrect-variable.patch \
+           file://net-snmp-5.7.2-fix-engineBoots-value-on-SIGHUP.patch \
+           file://net-snmp-fix-for-disable-des.patch \
+           file://0001-remove-configure-options-from-versioninfo.patch \
+           "
+SRC_URI[md5sum] = "6aae5948df7efde626613d6a4b3cd9d4"
+SRC_URI[sha256sum] = "c6291385b8ed84f05890fe4197005daf7e7ee7b082c2e390fa114a9477a56042"
+
+UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/net-snmp/files/net-snmp/"
+UPSTREAM_CHECK_REGEX = "/net-snmp/(?P<pver>\d+(\.\d+)+)/"
+
+inherit autotools-brokensep update-rc.d siteinfo systemd pkgconfig perlnative
+
+EXTRA_OEMAKE = "INSTALL_PREFIX=${D} OTHERLDFLAGS='${LDFLAGS}' HOST_CPPFLAGS='${BUILD_CPPFLAGS}'"
+
+PARALLEL_MAKE = ""
+CCACHE = ""
+
+TARGET_CC_ARCH += "${LDFLAGS}"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[elfutils] = "--with-elf, --without-elf, elfutils"
+PACKAGECONFIG[libnl] = "--with-nl, --without-nl, libnl"
+
+PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}"
+PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,,"
+
+PACKAGECONFIG[perl] = "--enable-embedded-perl --with-perl-modules=yes, --disable-embedded-perl --with-perl-modules=no,\
+                       perl, perl perl-lib"
+
+EXTRA_OECONF = "--enable-shared \
+                --disable-manuals \
+                --with-defaults \
+                --with-install-prefix=${D} \
+                --with-persistent-directory=${localstatedir}/lib/net-snmp \
+                ${@oe.utils.conditional('SITEINFO_ENDIANNESS', 'le', '--with-endianness=little', '--with-endianness=big', d)} \
+                --with-openssl=${STAGING_EXECPREFIXDIR} \
+"
+
+# net-snmp needs to have mib-modules=smux enabled to enable quagga to support snmp
+EXTRA_OECONF += "--with-mib-modules=smux"
+
+CACHED_CONFIGUREVARS = " \
+    ac_cv_header_valgrind_valgrind_h=no \
+    ac_cv_header_valgrind_memcheck_h=no \
+    ac_cv_ETC_MNTTAB=/etc/mtab \
+    lt_cv_shlibpath_overrides_runpath=yes \
+"
+export PERLPROG="${bindir}/env perl"
+PERLPROG_append = "${@bb.utils.contains('PACKAGECONFIG', 'perl', ' -I${WORKDIR}', '', d)}"
+
+HAS_PERL = "${@bb.utils.contains('PACKAGECONFIG', 'perl', '1', '0', d)}"
+
+do_configure_prepend() {
+    sed -i -e "s|I/usr/include|I${STAGING_INCDIR}|g" \
+        "${S}"/configure \
+        "${S}"/configure.d/config_os_libs2
+
+    if [ "${HAS_PERL}" = "1" ]; then
+        # this may need to be changed when package perl has any change.
+        cp -f ${STAGING_DIR_TARGET}/usr/lib*/perl/*/Config.pm ${WORKDIR}/
+        cp -f ${STAGING_DIR_TARGET}/usr/lib*/perl/*/Config_heavy.pl ${WORKDIR}/
+        sed -e "s@libpth => '/usr/lib.*@libpth => '${STAGING_DIR_TARGET}/${libdir} ${STAGING_DIR_TARGET}/${base_libdir}',@g" \
+            -e "s@privlibexp => '/usr@privlibexp => '${STAGING_DIR_TARGET}/usr@g" \
+            -e "s@scriptdir => '/usr@scriptdir => '${STAGING_DIR_TARGET}/usr@g" \
+            -e "s@sitearchexp => '/usr@sitearchexp => '${STAGING_DIR_TARGET}/usr@g" \
+            -e "s@sitelibexp => '/usr@sitearchexp => '${STAGING_DIR_TARGET}/usr@g" \
+            -e "s@vendorarchexp => '/usr@vendorarchexp => '${STAGING_DIR_TARGET}/usr@g" \
+            -e "s@vendorlibexp => '/usr@vendorlibexp => '${STAGING_DIR_TARGET}/usr@g" \
+            -i ${WORKDIR}/Config.pm
+    fi
+
+}
+
+do_configure_append() {
+    if [ "${HAS_PERL}" = "1" ]; then
+        sed -e "s@^NSC_INCLUDEDIR=.*@NSC_INCLUDEDIR=${STAGING_DIR_TARGET}\$\{includedir\}@g" \
+            -e "s@^NSC_LIBDIR=-L.*@NSC_LIBDIR=-L${STAGING_DIR_TARGET}\$\{libdir\}@g" \
+            -i ${B}/net-snmp-config
+    fi
+}
+
+do_install_append() {
+    install -d ${D}${sysconfdir}/snmp
+    install -d ${D}${sysconfdir}/init.d
+    install -m 755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/snmpd
+    install -m 644 ${WORKDIR}/snmpd.conf ${D}${sysconfdir}/snmp/
+    install -m 644 ${WORKDIR}/snmptrapd.conf ${D}${sysconfdir}/snmp/
+    install -d ${D}${systemd_unitdir}/system
+    install -m 0644 ${WORKDIR}/snmpd.service ${D}${systemd_unitdir}/system
+    install -m 0644 ${WORKDIR}/snmptrapd.service ${D}${systemd_unitdir}/system
+    sed    -e "s@^NSC_SRCDIR=.*@NSC_SRCDIR=.@g" \
+        -i ${D}${bindir}/net-snmp-create-v3-user
+    sed    -e "s@^NSC_SRCDIR=.*@NSC_SRCDIR=.@g" \
+           -e "s@\([^ ]*-fdebug-prefix-map=[^ ]*\)\1*@@g" \
+           -e "s@\([^ ]*--sysroot=[^ ]*\)\1*@@g" \
+           -e "s@\([^ ]*--with-libtool-sysroot=[^ ]*\)\1*@@g" \
+           -e "s@\([^ ]*--with-install-prefix=[^ ]*\)\1*@@g" \
+        -i ${D}${bindir}/net-snmp-config
+
+    if [ "${HAS_PERL}" = "1" ]; then
+        sed -e "s@^NSC_INCLUDEDIR=.*@NSC_INCLUDEDIR=\$\{includedir\}@g" \
+            -e "s@^NSC_LIBDIR=-L.*@NSC_LIBDIR=-L\$\{libdir\}@g" \
+            -i ${D}${bindir}/net-snmp-config
+    fi
+}
+
+do_install_ptest() {
+    install -d ${D}${PTEST_PATH}
+    for i in ${S}/dist ${S}/include ${B}/include ${S}/mibs ${S}/configure \
+        ${B}/net-snmp-config ${S}/testing; do
+        if [ -e "$i" ]; then
+            cp -R --no-dereference --preserve=mode,links -v "$i" ${D}${PTEST_PATH}
+        fi
+    done
+    echo `autoconf -V|awk '/autoconf/{print $NF}'` > ${D}${PTEST_PATH}/dist/autoconf-version
+
+    rmdlist="${D}${PTEST_PATH}/dist/net-snmp-solaris-build"
+    for i in $rmdlist; do
+        if [ -d "$i" ]; then
+            rm -rf "$i"
+        fi
+    done
+}
+
+SYSROOT_PREPROCESS_FUNCS += "net_snmp_sysroot_preprocess"
+SNMP_DBGDIR = "/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR}"
+
+net_snmp_sysroot_preprocess () {
+    if [ -e ${D}${bindir}/net-snmp-config ]; then
+        install -d ${SYSROOT_DESTDIR}${bindir_crossscripts}/
+        install -m 755 ${D}${bindir}/net-snmp-config ${SYSROOT_DESTDIR}${bindir_crossscripts}/
+        sed -e "s@-I/usr/include@-I${STAGING_INCDIR}@g" \
+            -e "s@^prefix=.*@prefix=${STAGING_DIR_HOST}${prefix}@g" \
+            -e "s@^exec_prefix=.*@exec_prefix=${STAGING_EXECPREFIXDIR}@g" \
+            -e "s@^includedir=.*@includedir=${STAGING_INCDIR}@g" \
+            -e "s@^libdir=.*@libdir=${STAGING_LIBDIR}@g" \
+            -e "s@^NSC_SRCDIR=.*@NSC_SRCDIR=${S}@g" \
+            -e "s@-fdebug-prefix-map=${SNMP_DBGDIR}@-fdebug-prefix-map=${WORKDIR}=${SNMP_DBGDIR}@g" \
+            -e "s@-fdebug-prefix-map= -fdebug-prefix-map=@-fdebug-prefix-map=${STAGING_DIR_NATIVE}= \
+                  -fdebug-prefix-map=${STAGING_DIR_HOST}=@g" \
+            -e "s@--sysroot=@--sysroot=${STAGING_DIR_HOST}@g" \
+            -e "s@--with-libtool-sysroot=@--with-libtool-sysroot=${STAGING_DIR_HOST}@g" \
+            -e "s@--with-install-prefix=@--with-install-prefix=${D}@g" \
+          -i  ${SYSROOT_DESTDIR}${bindir_crossscripts}/net-snmp-config
+    fi
+}
+
+PACKAGE_PREPROCESS_FUNCS += "net_snmp_package_preprocess"
+net_snmp_package_preprocess () {
+    sed -e 's@${RECIPE_SYSROOT}@@g' \
+       -i ${PKGD}${bindir}/net-snmp-config
+}
+
+PACKAGES += "${PN}-libs ${PN}-mibs ${PN}-server ${PN}-client \
+             ${PN}-server-snmpd ${PN}-server-snmptrapd \
+             ${PN}-lib-netsnmp ${PN}-lib-agent ${PN}-lib-helpers \
+             ${PN}-lib-mibs ${PN}-lib-trapd"
+
+# perl module
+PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'perl', '${PN}-perl-modules', '', d)}"
+
+ALLOW_EMPTY_${PN} = "1"
+ALLOW_EMPTY_${PN}-server = "1"
+ALLOW_EMPTY_${PN}-libs = "1"
+
+FILES_${PN}-perl-modules = "${libdir}/perl/*"
+
+FILES_${PN}-libs = ""
+FILES_${PN}-mibs = "${datadir}/snmp/mibs"
+FILES_${PN}-server-snmpd = "${sbindir}/snmpd \
+                            ${sysconfdir}/snmp/snmpd.conf \
+                            ${sysconfdir}/init.d \
+                            ${systemd_unitdir}/system/snmpd.service \
+"
+
+FILES_${PN}-server-snmptrapd = "${sbindir}/snmptrapd \
+                                ${sysconfdir}/snmp/snmptrapd.conf \
+                                ${systemd_unitdir}/system/snmptrapd.service \
+"
+
+FILES_${PN}-lib-netsnmp = "${libdir}/libnetsnmp${SOLIBS}"
+FILES_${PN}-lib-agent = "${libdir}/libnetsnmpagent${SOLIBS}"
+FILES_${PN}-lib-helpers = "${libdir}/libnetsnmphelpers${SOLIBS}"
+FILES_${PN}-lib-mibs = "${libdir}/libnetsnmpmibs${SOLIBS}"
+FILES_${PN}-lib-trapd = "${libdir}/libnetsnmptrapd${SOLIBS}"
+
+FILES_${PN} = ""
+FILES_${PN}-client = "${bindir}/* ${datadir}/snmp/"
+FILES_${PN}-dbg += "${libdir}/.debug/ ${sbindir}/.debug/ ${bindir}/.debug/"
+FILES_${PN}-dev += "${bindir}/mib2c ${bindir}/mib2c-update"
+
+CONFFILES_${PN}-server-snmpd = "${sysconfdir}/snmp/snmpd.conf"
+CONFFILES_${PN}-server-snmptrapd = "${sysconfdir}/snmp/snmptrapd.conf"
+
+INITSCRIPT_PACKAGES = "${PN}-server-snmpd"
+INITSCRIPT_NAME_${PN}-server-snmpd = "snmpd"
+INITSCRIPT_PARAMS_${PN}-server-snmpd = "start 90 2 3 4 5 . stop 60 0 1 6 ."
+
+EXTRA_OECONF += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '--with-systemd', '--without-systemd', d)}"
+
+SYSTEMD_PACKAGES = "${PN}-server-snmpd \
+                    ${PN}-server-snmptrapd"
+
+SYSTEMD_SERVICE_${PN}-server-snmpd = "snmpd.service"
+SYSTEMD_SERVICE_${PN}-server-snmptrapd =  "snmptrapd.service"
+
+RDEPENDS_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'perl', 'net-snmp-perl-modules', '', d)}"
+RDEPENDS_${PN} += "net-snmp-client"
+RDEPENDS_${PN}-server-snmpd += "net-snmp-mibs"
+RDEPENDS_${PN}-server-snmptrapd += "net-snmp-server-snmpd ${PN}-lib-trapd"
+RDEPENDS_${PN}-server += "net-snmp-server-snmpd net-snmp-server-snmptrapd"
+RDEPENDS_${PN}-client += "net-snmp-mibs net-snmp-libs"
+RDEPENDS_${PN}-libs += "libpci \
+                        ${PN}-lib-netsnmp \
+                        ${PN}-lib-agent \
+                        ${PN}-lib-helpers \
+                        ${PN}-lib-mibs \
+"
+RDEPENDS_${PN}-ptest += "perl \
+                         perl-module-test \
+                         perl-module-file-basename \
+                         perl-module-getopt-long \
+                         perl-module-file-temp \
+                         perl-module-data-dumper \
+"
+RDEPENDS_${PN}-dev = "net-snmp-client (= ${EXTENDPKGV}) net-snmp-server (= ${EXTENDPKGV})"
+RRECOMMENDS_${PN}-dbg = "net-snmp-client (= ${EXTENDPKGV}) net-snmp-server (= ${EXTENDPKGV})"
+
+RPROVIDES_${PN}-server-snmpd += "${PN}-server-snmpd-systemd"
+RREPLACES_${PN}-server-snmpd += "${PN}-server-snmpd-systemd"
+RCONFLICTS_${PN}-server-snmpd += "${PN}-server-snmpd-systemd"
+
+RPROVIDES_${PN}-server-snmptrapd += "${PN}-server-snmptrapd-systemd"
+RREPLACES_${PN}-server-snmptrapd += "${PN}-server-snmptrapd-systemd"
+RCONFLICTS_${PN}-server-snmptrapd += "${PN}-server-snmptrapd-systemd"
+
+LEAD_SONAME = "libnetsnmp.so"
diff --git a/meta-openembedded/meta-networking/recipes-protocols/nopoll/nopoll_0.4.2.b297.bb b/meta-openembedded/meta-networking/recipes-protocols/nopoll/nopoll_0.4.2.b297.bb
deleted file mode 100644
index 1d77891..0000000
--- a/meta-openembedded/meta-networking/recipes-protocols/nopoll/nopoll_0.4.2.b297.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-SUMMARY = "OpenSource WebSocket Toolkit"
-DESCRIPTION = "noPoll is a OpenSource WebSocket implementation (RFC 6455), \
-written in ansi C, that allows building pure WebSocket solutions or to \
-provide WebSocket support to existing TCP oriented applications.\
-\
-noPoll provides support for WebSocket (ws://) and TLS (secure) WebSocket (wss://),\
-allowing message based (handler notified) programming or stream oriented access."
-
-HOMEPAGE = "http://www.aspl.es/nopoll/"
-LICENSE = "LGPL-2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=f0504124678c1b3158146e0630229298 \
-                   "
-DEPENDS = "openssl"
-SRC_URI = "http://www.aspl.es/nopoll/downloads/nopoll-${PV}.tar.gz \
-          "
-SRC_URI[md5sum] = "8c411cd0f3c0479aed28c4cf7b114fbb"
-SRC_URI[sha256sum] = "f5fbf8aaa16a77b0f265d8c847eb06cb3e68f2b1a50737466dae81181618654c"
-
-inherit autotools pkgconfig
-
-EXTRA_OECONF += "--disable-nopoll-doc"
-
-LDFLAGS += "-lpthread"
diff --git a/meta-openembedded/meta-networking/recipes-protocols/nopoll/nopoll_0.4.6.b400.bb b/meta-openembedded/meta-networking/recipes-protocols/nopoll/nopoll_0.4.6.b400.bb
new file mode 100644
index 0000000..8c57d29
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-protocols/nopoll/nopoll_0.4.6.b400.bb
@@ -0,0 +1,23 @@
+SUMMARY = "OpenSource WebSocket Toolkit"
+DESCRIPTION = "noPoll is a OpenSource WebSocket implementation (RFC 6455), \
+written in ansi C, that allows building pure WebSocket solutions or to \
+provide WebSocket support to existing TCP oriented applications.\
+\
+noPoll provides support for WebSocket (ws://) and TLS (secure) WebSocket (wss://),\
+allowing message based (handler notified) programming or stream oriented access."
+
+HOMEPAGE = "http://www.aspl.es/nopoll/"
+LICENSE = "LGPL-2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=f0504124678c1b3158146e0630229298 \
+                   "
+DEPENDS = "openssl"
+SRC_URI = "http://www.aspl.es/nopoll/downloads/nopoll-${PV}.tar.gz \
+          "
+SRC_URI[md5sum] = "8d333f158b5d5a8975a6149e6ef8db63"
+SRC_URI[sha256sum] = "7f1b20f1d0525f30cdd2a4fc386d328b4cf98c6d11cef51fe62cd9491ba19ad9"
+
+inherit autotools pkgconfig
+
+EXTRA_OECONF += "--disable-nopoll-doc"
+
+LDFLAGS += "-lpthread"
diff --git a/meta-openembedded/meta-networking/recipes-protocols/openflow/openflow/0001-generate-not-static-get_dh-functions.patch b/meta-openembedded/meta-networking/recipes-protocols/openflow/openflow/0001-generate-not-static-get_dh-functions.patch
new file mode 100644
index 0000000..4acae80
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-protocols/openflow/openflow/0001-generate-not-static-get_dh-functions.patch
@@ -0,0 +1,33 @@
+From 0fe6770b617af7e400abc6f8652c1417d4c3575e Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 8 Sep 2018 22:49:15 -0700
+Subject: [PATCH] generate not static get_dh* functions
+
+Fixes build with OpenSSL 1.1.x
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ lib/automake.mk | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/lib/automake.mk b/lib/automake.mk
+index bfbeb94..b53909a 100644
+--- a/lib/automake.mk
++++ b/lib/automake.mk
+@@ -113,8 +113,9 @@ lib/dhparams.c: lib/dh1024.pem lib/dh2048.pem lib/dh4096.pem
+ 	(echo '#include "lib/dhparams.h"' &&				\
+ 	 openssl dhparam -C -in $(srcdir)/lib/dh1024.pem -noout &&	\
+ 	 openssl dhparam -C -in $(srcdir)/lib/dh2048.pem -noout &&	\
+-	 openssl dhparam -C -in $(srcdir)/lib/dh4096.pem -noout)	\
+-	| sed 's/\(get_dh[0-9]*\)()/\1(void)/' > lib/dhparams.c.tmp
++	 openssl dhparam -C -in $(srcdir)/lib/dh4096.pem -noout) | 	\
++	 sed -e 's/\(get_dh[0-9]*\)()/\1(void)/' 			\
++	     -e 's/static DH \*get_dh/DH \*get_dh/' > lib/dhparams.c.tmp
+ 	mv lib/dhparams.c.tmp lib/dhparams.c
+ endif
+ 
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-networking/recipes-protocols/openflow/openflow_git.bb b/meta-openembedded/meta-networking/recipes-protocols/openflow/openflow_git.bb
index eceb45e..b6cef07 100644
--- a/meta-openembedded/meta-networking/recipes-protocols/openflow/openflow_git.bb
+++ b/meta-openembedded/meta-networking/recipes-protocols/openflow/openflow_git.bb
@@ -6,4 +6,5 @@
 SRC_URI += "\
            file://0001-Check-and-use-strlcpy-from-libc-before-defining-own.patch \
            file://0002-lib-netdev-Adjust-header-include-sequence.patch \
+           file://0001-generate-not-static-get_dh-functions.patch \
            "
diff --git a/meta-openembedded/meta-networking/recipes-protocols/openl2tp/openl2tp/0001-l2tp_api.c-include-rpc-clnt.h-for-resultproc_t.patch b/meta-openembedded/meta-networking/recipes-protocols/openl2tp/openl2tp/0001-l2tp_api.c-include-rpc-clnt.h-for-resultproc_t.patch
deleted file mode 100644
index a11a97e..0000000
--- a/meta-openembedded/meta-networking/recipes-protocols/openl2tp/openl2tp/0001-l2tp_api.c-include-rpc-clnt.h-for-resultproc_t.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 8f299df4dd1ca857e34859c377a29b183c630961 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 21 Sep 2017 13:05:03 -0700
-Subject: [PATCH] l2tp_api.c: include rpc/clnt.h for 'resultproc_t'
-
-Fixes
-
-| /mnt/a/oe/build/tmp/work/mips32r2-bec-linux-musl/openl2tp/1.8-r0/recipe-sysroot/usr/include/tirpc/rpc/pmap_clnt.h:81:12: error: unknown type name 'resultproc_t'; did you mean 'rpcproc_t'?                                                 |             resultproc_t);                                                                                                                                                                                                                  |             ^~~~~~~~~~~~
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Pending
-
- l2tp_api.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/l2tp_api.c b/l2tp_api.c
-index f0946fd..f77881c 100644
---- a/l2tp_api.c
-+++ b/l2tp_api.c
-@@ -26,6 +26,7 @@
- #include <sys/types.h>
- #include <rpc/types.h>
- #include <rpc/xdr.h>
-+#include <rpc/clnt.h>
- #include <rpc/pmap_clnt.h>
- //#include <netinet/in.h>
- 
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-networking/recipes-protocols/openl2tp/openl2tp/0002-user-ipv6-structures.patch b/meta-openembedded/meta-networking/recipes-protocols/openl2tp/openl2tp/0002-user-ipv6-structures.patch
index 3f8bcaa..bd9bcb8 100644
--- a/meta-openembedded/meta-networking/recipes-protocols/openl2tp/openl2tp/0002-user-ipv6-structures.patch
+++ b/meta-openembedded/meta-networking/recipes-protocols/openl2tp/openl2tp/0002-user-ipv6-structures.patch
@@ -4,6 +4,9 @@
 Subject: [PATCH 2/2] user ipv6 structures
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Update for ipv6 address compare
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
 ---
  l2tp_api.c | 8 +++++---
  1 file changed, 5 insertions(+), 3 deletions(-)
@@ -18,8 +21,8 @@
  	if ((!l2tp_opt_remote_rpc) &&
 -	    ((xprt->xp_raddr.sin_addr.s_addr != htonl(INADDR_LOOPBACK)) &&
 -	     (xprt->xp_raddr.sin_addr.s_addr != htonl(INADDR_ANY)))) {
-+	    ((xprt->xp_raddr.sin6_addr.s6_addr != htonl(INADDR_LOOPBACK)) &&
-+	     (xprt->xp_raddr.sin6_addr.s6_addr != htonl(INADDR_ANY)))) {
++	    ((memcmp(&xprt->xp_raddr.sin6_addr, &in6addr_loopback, sizeof(struct in6_addr)) != 0) &&
++	     (memcmp(&xprt->xp_raddr.sin6_addr, &in6addr_any, sizeof(struct in6_addr)) != 0))) {
 +		char straddr[INET6_ADDRSTRLEN];
 +		inet_ntop(AF_INET6, &xprt->xp_raddr.sin6_addr, straddr, sizeof(straddr));
  		if (l2tp_opt_trace_flags & L2TP_DEBUG_API) {
diff --git a/meta-openembedded/meta-networking/recipes-protocols/openl2tp/openl2tp/0004-Adjust-for-linux-kernel-headers-assumptions-on-glibc.patch b/meta-openembedded/meta-networking/recipes-protocols/openl2tp/openl2tp/0004-Adjust-for-linux-kernel-headers-assumptions-on-glibc.patch
deleted file mode 100644
index 0fcba65..0000000
--- a/meta-openembedded/meta-networking/recipes-protocols/openl2tp/openl2tp/0004-Adjust-for-linux-kernel-headers-assumptions-on-glibc.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From ede4ae8e25f9fb746a6f4e076d0ef029938d2880 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 28 Mar 2017 11:46:56 -0700
-Subject: [PATCH 4/4] Adjust for linux-kernel headers assumptions on glibc
-
-Fixes build issues e.g.
-
-In file included from /mnt/a/build/tmp-musl/work/cortexa7hf-neon-vfpv4-oe-linux-musleabi/openl2tp/1.8-r0/recipe-sysroot/usr/include/linux/if_pppox.h:24:
-/mnt/a/build/tmp-musl/work/cortexa7hf-neon-vfpv4-oe-linux-musleabi/openl2tp/1.8-r0/recipe-sysroot/usr/include/linux/if.h:97:2: error: expected identifier
-        IFF_LOWER_UP                    = 1<<16, /* __volatile__ */
-        ^
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- plugins/ppp_unix.c | 5 +++++
- 1 file changed, 5 insertions(+)
-
-diff --git a/plugins/ppp_unix.c b/plugins/ppp_unix.c
-index 869066f..5c1e44f 100644
---- a/plugins/ppp_unix.c
-+++ b/plugins/ppp_unix.c
-@@ -21,6 +21,11 @@
-  * Plugin to use the standard UNIX pppd
-  */
- 
-+/* hack to make sure kernel headers understand that libc (musl)
-+ * does define IFF_LOWER_UP et al.
-+ */
-+#define __UAPI_DEF_IF_NET_DEVICE_FLAGS_LOWER_UP_DORMANT_ECHO 0
-+
- #include <unistd.h>
- #include <fcntl.h>
- #include <sys/types.h>
--- 
-2.12.1
-
diff --git a/meta-openembedded/meta-networking/recipes-protocols/openl2tp/openl2tp_1.8.bb b/meta-openembedded/meta-networking/recipes-protocols/openl2tp/openl2tp_1.8.bb
index 1f6b4de..90e8b11 100644
--- a/meta-openembedded/meta-networking/recipes-protocols/openl2tp/openl2tp_1.8.bb
+++ b/meta-openembedded/meta-networking/recipes-protocols/openl2tp/openl2tp_1.8.bb
@@ -16,7 +16,7 @@
                     file://usl/LICENSE;md5=9c1387a3c5213aa40671438af3e00793 \
                     "
 
-DEPENDS = "popt flex readline"
+DEPENDS = "popt flex readline rpcsvc-proto-native bison-native"
 
 SRC_URI = "ftp://ftp.openl2tp.org/releases/${BP}/${BP}.tar.gz \
            file://Makefile-modify-CFLAGS-to-aviod-build-error.patch \
@@ -34,12 +34,7 @@
            file://openl2tpd-enable-tests.patch \
            file://run-ptest \
            file://fix_linux_4.15_compile.patch \
-           "
-
-SRC_URI_append_libc-musl = "\
-           file://0004-Adjust-for-linux-kernel-headers-assumptions-on-glibc.patch \
            file://0002-user-ipv6-structures.patch \
-           file://0001-l2tp_api.c-include-rpc-clnt.h-for-resultproc_t.patch \
            "
 SRC_URI[md5sum] = "e3d08dedfb9e6a9a1e24f6766f6dadd0"
 SRC_URI[sha256sum] = "1c97704d4b963a87fbc0e741668d4530933991515ae9ab0dffd11b5444f4860f"
@@ -49,10 +44,10 @@
 SYSTEMD_SERVICE_${PN} = "openl2tpd.service"
 SYSTEMD_AUTO_ENABLE = "disable"
 
-DEPENDS_append_libc-musl = " libtirpc"
-CPPFLAGS_append_libc-musl = " -I${STAGING_INCDIR}/tirpc"
-CFLAGS_append_libc-musl = " -I${STAGING_INCDIR}/tirpc"
-LDFLAGS_append_libc-musl = " -ltirpc"
+DEPENDS += "libtirpc"
+CPPFLAGS += "-I${STAGING_INCDIR}/tirpc"
+CFLAGS += "-I${STAGING_INCDIR}/tirpc"
+LDFLAGS += "-ltirpc"
 
 PARALLEL_MAKE = ""
 EXTRA_OEMAKE = 'CFLAGS="${CFLAGS} -Wno-unused-but-set-variable" CPPFLAGS="${CPPFLAGS}" OPT_CFLAGS="${CFLAGS}"'
diff --git a/meta-openembedded/meta-networking/recipes-protocols/radiusclient-ng/radiusclient-ng_0.5.6.bb b/meta-openembedded/meta-networking/recipes-protocols/radiusclient-ng/radiusclient-ng_0.5.6.bb
index 95faa65..780423f 100644
--- a/meta-openembedded/meta-networking/recipes-protocols/radiusclient-ng/radiusclient-ng_0.5.6.bb
+++ b/meta-openembedded/meta-networking/recipes-protocols/radiusclient-ng/radiusclient-ng_0.5.6.bb
@@ -17,6 +17,8 @@
 
 inherit autotools-brokensep
 
+DEPENDS += "virtual/crypt"
+
 EXTRA_OECONF += "--disable-static"
 
 do_configure_prepend () {
diff --git a/meta-openembedded/meta-networking/recipes-protocols/tsocks/tsocks_1.8beta5.bb b/meta-openembedded/meta-networking/recipes-protocols/tsocks/tsocks_1.8beta5.bb
index b2757f6..725ba18 100644
--- a/meta-openembedded/meta-networking/recipes-protocols/tsocks/tsocks_1.8beta5.bb
+++ b/meta-openembedded/meta-networking/recipes-protocols/tsocks/tsocks_1.8beta5.bb
@@ -18,11 +18,14 @@
 
 inherit autotools-brokensep
 
+LIBS_append_libc-musl = " -lssp_nonshared"
+LIBS_append_libc-glibc = " -lc_nonshared"
+
 S = "${WORKDIR}/tsocks-1.8"
 
 FILES_${PN} = "${libdir}/* ${bindir}/tsocks"
 FILES_${PN}-dev = ""
 INSANE_SKIP_${PN} = "dev-so"
 
-EXTRA_OEMAKE = "SHCC='${CC} -fPIC ${LDFLAGS}'"
+EXTRA_OEMAKE = "SHCC='${CC} -fPIC ${LDFLAGS}' LIBS='${LIBS}'"
 
diff --git a/meta-openembedded/meta-networking/recipes-support/c-ares/c-ares/cmake-install-libcares.pc.patch b/meta-openembedded/meta-networking/recipes-support/c-ares/c-ares/cmake-install-libcares.pc.patch
index 5dd4c7d..8cadb2b 100644
--- a/meta-openembedded/meta-networking/recipes-support/c-ares/c-ares/cmake-install-libcares.pc.patch
+++ b/meta-openembedded/meta-networking/recipes-support/c-ares/c-ares/cmake-install-libcares.pc.patch
@@ -1,23 +1,27 @@
-From 7e1ae687916fd5878ee755afbdea6b10494e0b92 Mon Sep 17 00:00:00 2001
-From: Alexey Firago <alexey_firago@mentor.com>
-Date: Wed, 26 Jul 2017 23:21:25 +0300
+From 12414304245cce6ef0e8b9547949be5109845353 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Tue, 24 Jul 2018 13:33:33 +0800
 Subject: [PATCH] cmake: Install libcares.pc
 
 Prepare and install libcares.pc file during cmake build, so libraries
 using pkg-config to find libcares will not fail.
 
 Signed-off-by: Alexey Firago <alexey_firago@mentor.com>
+
+update to 1.14.0, fix patch warning
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
 ---
- CMakeLists.txt      | 21 +++++++++++++++++++++
+ CMakeLists.txt      | 23 +++++++++++++++++++++++
  libcares.pc.cmakein | 20 ++++++++++++++++++++
- 2 files changed, 41 insertions(+)
+ 2 files changed, 43 insertions(+)
  create mode 100644 libcares.pc.cmakein
 
 diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 364b6c7..0016b67 100644
+index 60a880c..71eaa53 100644
 --- a/CMakeLists.txt
 +++ b/CMakeLists.txt
-@@ -173,21 +173,29 @@ ADD_DEFINITIONS(${SYSFLAGS})
+@@ -193,22 +193,30 @@ ADD_DEFINITIONS(${SYSFLAGS})
  
  
  # Tell C-Ares about libraries to depend on
@@ -43,32 +47,35 @@
  	LIST (APPEND CARES_DEPENDENT_LIBS ws2_32)
 +	LIST (APPEND CARES_PRIVATE_LIBS_LIST "-lws2_32")
  ENDIF ()
+ 
 +string (REPLACE ";" " " CARES_PRIVATE_LIBS "${CARES_PRIVATE_LIBS_LIST}")
  
- 
  # When checking for symbols, we need to make sure we set the proper
-@@ -489,6 +497,13 @@ CONFIGURE_FILE (ares_build.h.cmake ${PROJECT_BINARY_DIR}/ares_build.h)
+ # headers, libraries, and definitions for the detection to work properly
+@@ -514,6 +522,15 @@ CONFIGURE_FILE (ares_build.h.cmake ${PROJECT_BINARY_DIR}/ares_build.h)
  # Write ares_config.h configuration file.  This is used only for the build.
  CONFIGURE_FILE (ares_config.h.cmake ${PROJECT_BINARY_DIR}/ares_config.h)
  
 +# Pass required CFLAGS to pkg-config in case of static library
 +IF (CARES_STATIC)
-+	SET (CPPFLAG_CARES_STATICLIB "-DCARES_STATICLIB")
++       SET (CPPFLAG_CARES_STATICLIB "-DCARES_STATICLIB")
 +ENDIF()
 +
 +# Write ares_config.h configuration file.  This is used only for the build.
 +CONFIGURE_FILE (libcares.pc.cmakein ${PROJECT_BINARY_DIR}/libcares.pc @ONLY)
++
++
  
  # TRANSFORM_MAKEFILE_INC
  #
-@@ -625,6 +640,12 @@ IF (CARES_INSTALL)
- 	INSTALL (FILES "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}-config.cmake" DESTINATION ${CMAKECONFIG_INSTALL_DIR})
+@@ -664,6 +681,12 @@ IF (CARES_INSTALL)
+ 	INSTALL (FILES "${CMAKE_CURRENT_BINARY_DIR}/libcares.pc" DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig")
  ENDIF ()
  
 +# pkg-config file
 +IF (CARES_INSTALL)
-+	SET (PKGCONFIG_INSTALL_DIR "${CMAKE_INSTALL_LIBDIR}/pkgconfig")
-+	INSTALL (FILES "${CMAKE_CURRENT_BINARY_DIR}/libcares.pc" DESTINATION ${PKGCONFIG_INSTALL_DIR})
++       SET (PKGCONFIG_INSTALL_DIR "${CMAKE_INSTALL_LIBDIR}/pkgconfig")
++       INSTALL (FILES "${CMAKE_CURRENT_BINARY_DIR}/libcares.pc" DESTINATION ${PKGCONFIG_INSTALL_DIR})
 +ENDIF ()
 +
  # Legacy chain-building variables (provided for compatibility with old code).
@@ -76,7 +83,7 @@
  SET (CARES_FOUND 1 CACHE INTERNAL "CARES LIBRARY FOUND")
 diff --git a/libcares.pc.cmakein b/libcares.pc.cmakein
 new file mode 100644
-index 0000000..f29fede
+index 0000000..3579256
 --- /dev/null
 +++ b/libcares.pc.cmakein
 @@ -0,0 +1,20 @@
diff --git a/meta-openembedded/meta-networking/recipes-support/c-ares/c-ares_1.13.0.bb b/meta-openembedded/meta-networking/recipes-support/c-ares/c-ares_1.13.0.bb
deleted file mode 100644
index 70e497f..0000000
--- a/meta-openembedded/meta-networking/recipes-support/c-ares/c-ares_1.13.0.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-# Copyright (c) 2012-2014 LG Electronics, Inc.
-SUMMARY = "c-ares is a C library that resolves names asynchronously."
-HOMEPAGE = "http://daniel.haxx.se/projects/c-ares/"
-SECTION = "libs"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://LICENSE.md;md5=f4b026880834eb01c035c5e5cb47ccac"
-SRCREV = "3be1924221e1326df520f8498d704a5c4c8d0cce"
-PV = "1.13.0+gitr${SRCPV}"
-
-SRC_URI = "\
-    git://github.com/c-ares/c-ares.git \
-    file://cmake-install-libcares.pc.patch \
-"
-
-S = "${WORKDIR}/git"
-
-inherit cmake pkgconfig
-
-PACKAGES =+ "${PN}-utils"
-
-FILES_${PN}-dev += "${libdir}/cmake"
-FILES_${PN}-utils = "${bindir}"
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-networking/recipes-support/c-ares/c-ares_1.14.0.bb b/meta-openembedded/meta-networking/recipes-support/c-ares/c-ares_1.14.0.bb
new file mode 100644
index 0000000..b31543d
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/c-ares/c-ares_1.14.0.bb
@@ -0,0 +1,26 @@
+# Copyright (c) 2012-2014 LG Electronics, Inc.
+SUMMARY = "c-ares is a C library that resolves names asynchronously."
+HOMEPAGE = "http://daniel.haxx.se/projects/c-ares/"
+SECTION = "libs"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE.md;md5=fb997454c8d62aa6a47f07a8cd48b006"
+
+PV = "1.14.0+gitr${SRCPV}"
+
+SRC_URI = "\
+    git://github.com/c-ares/c-ares.git \
+    file://cmake-install-libcares.pc.patch \
+"
+SRCREV = "17dc1b3102e0dfc3e7e31369989013154ee17893"
+
+UPSTREAM_CHECK_GITTAGREGEX = "cares-(?P<pver>\d+_(\d_?)+)"
+
+S = "${WORKDIR}/git"
+
+inherit cmake pkgconfig
+
+PACKAGES =+ "${PN}-utils"
+
+FILES_${PN}-utils = "${bindir}"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-networking/recipes-support/celt051/celt051/0001-configure.ac-make-tools-support-optional.patch b/meta-openembedded/meta-networking/recipes-support/celt051/celt051/0001-configure.ac-make-tools-support-optional.patch
new file mode 100644
index 0000000..b0809ee
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/celt051/celt051/0001-configure.ac-make-tools-support-optional.patch
@@ -0,0 +1,39 @@
+From 86df4200c9c33d999df0e8cc3c9771f17a297ec4 Mon Sep 17 00:00:00 2001
+From: Martin Jansa <Martin.Jansa@gmail.com>
+Date: Wed, 13 Sep 2017 15:01:54 +0200
+Subject: [PATCH] configure.ac: make tools support optional
+
+* add --enable-tools option
+* XIPH_PATH_OGG macro is provided by libogg so we cannot call
+  it without the libogg dependency
+
+Upstream-Status: Pending
+
+Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
+---
+ configure.ac | 8 +++++++-
+ 1 file changed, 7 insertions(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index d4b1a3f..7d6b2dc 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -68,8 +68,14 @@ AC_MSG_RESULT($has_alloca)
+ 
+ AC_CHECK_HEADERS(sys/soundcard.h sys/audioio.h)
+ 
+-XIPH_PATH_OGG([tools="tools"], [tools=""])
++AC_ARG_ENABLE(tools, [  --enable-tools          Compile ogg tools],
++[if test "$enableval" = yes; then
++  [tools="tools"]
++else
++  [tools=""]
++fi],
+ AC_SUBST(tools)
++)
+ 
+ AC_CHECK_LIB(m, sin)
+ 
+-- 
+2.14.1
+
diff --git a/meta-openembedded/meta-networking/recipes-support/celt051/celt051/0001-tests-Include-entcode.c-into-test-sources-to-provide.patch b/meta-openembedded/meta-networking/recipes-support/celt051/celt051/0001-tests-Include-entcode.c-into-test-sources-to-provide.patch
new file mode 100644
index 0000000..cc893f0
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/celt051/celt051/0001-tests-Include-entcode.c-into-test-sources-to-provide.patch
@@ -0,0 +1,55 @@
+From 61fbdddb660c5944ac23b820754a7c4cf4eee097 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 8 Jun 2018 19:29:03 -0700
+Subject: [PATCH] tests: Include entcode.c into test sources to provide
+ definitions of functions e.g. ec_ilog()
+
+Fixes link errors in tests
+| /usr/src/debug/celt051/0.5.1.3+gitAUTOINC+5555aae843-r0/git/tests/../libcelt/rangedec.c:202: undefined reference to `ec_ilog'
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ tests/cwrs32-test.c  | 1 +
+ tests/ectest.c       | 2 +-
+ tests/laplace-test.c | 1 +
+ 3 files changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/tests/cwrs32-test.c b/tests/cwrs32-test.c
+index 3a95df2..a159ab3 100644
+--- a/tests/cwrs32-test.c
++++ b/tests/cwrs32-test.c
+@@ -8,6 +8,7 @@
+ #include "rangeenc.c"
+ #include "rangedec.c"
+ #include "cwrs.c"
++#include "entcode.c"
+ #include <string.h>
+ #define NMAX (10)
+ #define MMAX (9)
+diff --git a/tests/ectest.c b/tests/ectest.c
+index aa35453..94eb9a3 100644
+--- a/tests/ectest.c
++++ b/tests/ectest.c
+@@ -5,7 +5,7 @@
+ #include <stdlib.h>
+ #include <stdio.h>
+ #include <math.h>
+-#include "entcode.h"
++#include "entcode.c"
+ #include "entenc.c"
+ #include "entdec.c"
+ #include "rangeenc.c"
+diff --git a/tests/laplace-test.c b/tests/laplace-test.c
+index 3f98ab3..8e1fb4e 100644
+--- a/tests/laplace-test.c
++++ b/tests/laplace-test.c
+@@ -6,6 +6,7 @@
+ #include <stdlib.h>
+ #include "laplace.c"
+ #include "stack_alloc.h"
++#include "entcode.c"
+ #include "entenc.c"
+ #include "entdec.c"
+ #include "rangeenc.c"
diff --git a/meta-openembedded/meta-networking/recipes-support/celt051/celt051_git.bb b/meta-openembedded/meta-networking/recipes-support/celt051/celt051_git.bb
new file mode 100644
index 0000000..1168005
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/celt051/celt051_git.bb
@@ -0,0 +1,33 @@
+#
+# Copyright (C) 2013 Wind River Systems, Inc.
+#
+
+SUMMARY = "The CELT codec is a compression algorithm for audio"
+DESCRIPTION = "The CELT codec is a compression algorithm for \
+audio. Like MP3, Vorbis, and AAC it is suitable for transmitting music \
+with high quality. Unlike these formats CELT imposes very little delay \
+on the signal, even less than is typical for speech centric formats \
+like Speex, GSM, or G.729."
+
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=375f60ab360d17f0172737036ff155b2"
+
+PV = "0.5.1.3+git${SRCPV}"
+
+SRCREV = "5555aae843f57241d005e330b9cb65602d56db0f"
+
+SRC_URI = "git://git.xiph.org/celt.git;branch=compat-v0.5.1;protocol=https \
+           file://0001-configure.ac-make-tools-support-optional.patch \
+           file://0001-tests-Include-entcode.c-into-test-sources-to-provide.patch \
+           "
+
+S = "${WORKDIR}/git"
+
+inherit pkgconfig autotools-brokensep
+
+PACKAGECONFIG_class-native = ""
+PACKAGECONFIG ??= ""
+
+PACKAGECONFIG[ogg] = "--enable-tools,--disable-tools,libogg,"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-networking/recipes-support/chrony/chrony/arm_eabi.patch b/meta-openembedded/meta-networking/recipes-support/chrony/chrony/arm_eabi.patch
index 92a2dbd..9f943cd 100644
--- a/meta-openembedded/meta-networking/recipes-support/chrony/chrony/arm_eabi.patch
+++ b/meta-openembedded/meta-networking/recipes-support/chrony/chrony/arm_eabi.patch
@@ -1,4 +1,7 @@
-    chrony: fix build failure for arma9
+From 9ca48a6fef1da1bb0dd67ab94256c7e240da1834 Mon Sep 17 00:00:00 2001
+From: Joe Slater <jslater@windriver.com>
+Date: Thu, 9 Mar 2017 10:58:06 -0800
+Subject: [PATCH]     chrony: fix build failure for arma9
 
     Eliminate references to syscalls not available
     for ARM_EABI.  Also add a dependency on libseccomp
@@ -16,9 +19,15 @@
 
     Signed-off-by: Robert Joslyn <robert.joslyn@redrectangle.org>
 
+---
+ sys_linux.c | 19 +++++++++++++------
+ 1 file changed, 13 insertions(+), 6 deletions(-)
+
+diff --git a/sys_linux.c b/sys_linux.c
+index f4b532d..d05fa24 100644
 --- a/sys_linux.c
 +++ b/sys_linux.c
-@@ -465,14 +465,14 @@ SYS_Linux_EnableSystemCallFilter(int lev
+@@ -482,14 +482,14 @@ SYS_Linux_EnableSystemCallFilter(int level)
    const int syscalls[] = {
      /* Clock */
      SCMP_SYS(adjtimex), SCMP_SYS(clock_gettime), SCMP_SYS(gettimeofday),
@@ -36,8 +45,8 @@
      SCMP_SYS(mprotect), SCMP_SYS(mremap), SCMP_SYS(munmap), SCMP_SYS(shmdt),
      /* Filesystem */
      SCMP_SYS(access), SCMP_SYS(chmod), SCMP_SYS(chown), SCMP_SYS(chown32),
-@@ -483,14 +483,21 @@
-     SCMP_SYS(bind), SCMP_SYS(connect), SCMP_SYS(getsockname),
+@@ -500,14 +500,21 @@ SYS_Linux_EnableSystemCallFilter(int level)
+     SCMP_SYS(bind), SCMP_SYS(connect), SCMP_SYS(getsockname), SCMP_SYS(getsockopt),
      SCMP_SYS(recvfrom), SCMP_SYS(recvmmsg), SCMP_SYS(recvmsg),
      SCMP_SYS(sendmmsg), SCMP_SYS(sendmsg), SCMP_SYS(sendto),
 -    /* TODO: check socketcall arguments */
diff --git a/meta-openembedded/meta-networking/recipes-support/chrony/chrony_3.2.bb b/meta-openembedded/meta-networking/recipes-support/chrony/chrony_3.2.bb
deleted file mode 100644
index 8b90a35..0000000
--- a/meta-openembedded/meta-networking/recipes-support/chrony/chrony_3.2.bb
+++ /dev/null
@@ -1,134 +0,0 @@
-SUMMARY = "Versatile implementation of the Network Time Protocol"
-DESCRIPTION = "Chrony can synchronize the system clock with NTP \
-servers, reference clocks (e.g. GPS receiver), and manual input using \
-wristwatch and keyboard. It can also operate as an NTPv4 (RFC 5905) \
-server and peer to provide a time service to other computers in the \
-network. \
-\
-It is designed to perform well in a wide range of conditions, \
-including intermittent network connections, heavily congested \
-networks, changing temperatures (ordinary computer clocks are \
-sensitive to temperature), and systems that do not run continuously, or \
-run on a virtual machine. \
-\
-Typical accuracy between two machines on a LAN is in tens, or a few \
-hundreds, of microseconds; over the Internet, accuracy is typically \
-within a few milliseconds. With a good hardware reference clock \
-sub-microsecond accuracy is possible. \
-\
-Two programs are included in chrony: chronyd is a daemon that can be \
-started at boot time and chronyc is a command-line interface program \
-which can be used to monitor chronyd's performance and to change \
-various operating parameters whilst it is running. \
-\
-This recipe produces two binary packages: 'chrony' which contains chronyd, \
-the configuration file and the init script, and 'chronyc' which contains \
-the client program only."
-
-HOMEPAGE = "https://chrony.tuxfamily.org/"
-SECTION = "net"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
-
-SRC_URI = "https://download.tuxfamily.org/chrony/chrony-${PV}.tar.gz \
-    file://chrony.conf \
-    file://chronyd \
-    file://arm_eabi.patch \
-"
-SRC_URI[md5sum] = "f4c4eb0dc92f35ee4bb7d3dcd8029ecb"
-SRC_URI[sha256sum] = "329f6718dd8c3ece3eee78be1f4821cbbeb62608e7d23f25da293cfa433c4116"
-
-DEPENDS = "pps-tools"
-
-# Note: Despite being built via './configure; make; make install',
-#       chrony does not use GNU Autotools.
-inherit update-rc.d systemd
-
-# Configuration options:
-# - For command line editing support in chronyc, you may specify either
-#   'editline' or 'readline' but not both.  editline is smaller, but
-#   many systems already have readline for other purposes so you might want
-#   to choose that instead.  However, beware license incompatibility
-#   since chrony is GPLv2 and readline versions after 6.0 are GPLv3+.
-#   You can of course choose neither, but if you're that tight on space
-#   consider dropping chronyc entirely (you can use it remotely with
-#   appropriate chrony.conf options).
-# - Security-related:
-#   - 'sechash' is omitted by default because it pulls in nss which is huge.
-#   - 'privdrop' allows chronyd to run as non-root; would need changes to
-#     chrony.conf and init script.
-#   - 'scfilter' enables support for system call filtering, but requires the
-#     kernel to have CONFIG_SECCOMP enabled.
-PACKAGECONFIG ??= "editline \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} \
-"
-PACKAGECONFIG[readline] = "--without-editline,--without-readline,readline"
-PACKAGECONFIG[editline] = ",--without-editline,libedit"
-PACKAGECONFIG[sechash] = "--without-tomcrypt,--disable-sechash,nss"
-PACKAGECONFIG[privdrop] = ",--disable-privdrop,libcap"
-PACKAGECONFIG[scfilter] = "--enable-scfilter,--without-seccomp,libseccomp"
-PACKAGECONFIG[ipv6] = ",--disable-ipv6,"
-PACKAGECONFIG[nss] = "--with-nss,--without-nss,nss"
-PACKAGECONFIG[libcap] = "--with-libcap,--without-libcap,libcap"
-
-# --disable-static isn't supported by chrony's configure script.
-DISABLE_STATIC = ""
-
-do_configure() {
-    ./configure --sysconfdir=${sysconfdir} --bindir=${bindir} --sbindir=${sbindir} \
-                --localstatedir=${localstatedir} --datarootdir=${datadir} \
-                ${PACKAGECONFIG_CONFARGS}
-}
-
-do_install() {
-    # Binaries
-    install -d ${D}${bindir}
-    install -m 0755 ${S}/chronyc ${D}${bindir}
-    install -d ${D}${sbindir}
-    install -m 0755 ${S}/chronyd ${D}${sbindir}
-
-    # Config file
-    install -d ${D}${sysconfdir}
-    install -m 644 ${WORKDIR}/chrony.conf ${D}${sysconfdir}
-
-    # System V init script
-    install -d ${D}${sysconfdir}/init.d
-    install -m 755 ${WORKDIR}/chronyd ${D}${sysconfdir}/init.d
-
-    # systemd unit configuration file
-    install -d ${D}${systemd_unitdir}/system
-    install -m 0644 ${S}/examples/chronyd.service ${D}${systemd_unitdir}/system/
-
-    # Variable data (for drift and/or rtc file)
-    install -d ${D}${localstatedir}/lib/chrony
-
-    # Log files
-    install -d ${D}${localstatedir}/log/chrony
-
-    # Fix hard-coded paths in config files and init scripts
-    sed -i -e 's!/var/!${localstatedir}/!g' -e 's!/etc/!${sysconfdir}/!g' \
-           -e 's!/usr/sbin/!${sbindir}/!g' -e 's!/usr/bin/!${bindir}/!g' \
-           ${D}${sysconfdir}/chrony.conf \
-           ${D}${sysconfdir}/init.d/chronyd \
-           ${D}${systemd_unitdir}/system/chronyd.service
-    sed -i 's!^PATH=.*!PATH=${base_sbindir}:${base_bindir}:${sbindir}:${bindir}!' ${D}${sysconfdir}/init.d/chronyd
-    sed -i 's!^EnvironmentFile=.*!EnvironmentFile=-${sysconfdir}/default/chronyd!' ${D}${systemd_unitdir}/system/chronyd.service
-}
-
-FILES_${PN} = "${sbindir}/chronyd ${sysconfdir} ${localstatedir}"
-CONFFILES_${PN} = "${sysconfdir}/chrony.conf"
-INITSCRIPT_NAME = "chronyd"
-INITSCRIPT_PARAMS = "defaults"
-SYSTEMD_PACKAGES = "${PN}"
-SYSTEMD_SERVICE_${PN} = "chronyd.service"
-
-# It's probably a bad idea to run chrony and another time daemon on
-# the same system.  systemd includes the SNTP client 'timesyncd', which
-# will be disabled by chronyd.service, however it will remain on the rootfs
-# wasting 150 kB unless you put 'PACKAGECONFIG_remove_pn-systemd = "timesyncd"'
-# in a conf file or bbappend somewhere.
-RCONFLICTS_${PN} = "ntp ntimed"
-
-# Separate the client program into its own package
-PACKAGES =+ "chronyc"
-FILES_chronyc = "${bindir}/chronyc"
diff --git a/meta-openembedded/meta-networking/recipes-support/chrony/chrony_3.3.bb b/meta-openembedded/meta-networking/recipes-support/chrony/chrony_3.3.bb
new file mode 100644
index 0000000..2586370
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/chrony/chrony_3.3.bb
@@ -0,0 +1,134 @@
+SUMMARY = "Versatile implementation of the Network Time Protocol"
+DESCRIPTION = "Chrony can synchronize the system clock with NTP \
+servers, reference clocks (e.g. GPS receiver), and manual input using \
+wristwatch and keyboard. It can also operate as an NTPv4 (RFC 5905) \
+server and peer to provide a time service to other computers in the \
+network. \
+\
+It is designed to perform well in a wide range of conditions, \
+including intermittent network connections, heavily congested \
+networks, changing temperatures (ordinary computer clocks are \
+sensitive to temperature), and systems that do not run continuously, or \
+run on a virtual machine. \
+\
+Typical accuracy between two machines on a LAN is in tens, or a few \
+hundreds, of microseconds; over the Internet, accuracy is typically \
+within a few milliseconds. With a good hardware reference clock \
+sub-microsecond accuracy is possible. \
+\
+Two programs are included in chrony: chronyd is a daemon that can be \
+started at boot time and chronyc is a command-line interface program \
+which can be used to monitor chronyd's performance and to change \
+various operating parameters whilst it is running. \
+\
+This recipe produces two binary packages: 'chrony' which contains chronyd, \
+the configuration file and the init script, and 'chronyc' which contains \
+the client program only."
+
+HOMEPAGE = "https://chrony.tuxfamily.org/"
+SECTION = "net"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
+
+SRC_URI = "https://download.tuxfamily.org/chrony/chrony-${PV}.tar.gz \
+    file://chrony.conf \
+    file://chronyd \
+    file://arm_eabi.patch \
+"
+SRC_URI[md5sum] = "81ab62cf5d60b4b3fa8cd2c1b267ffd9"
+SRC_URI[sha256sum] = "0d1fb2d5875032f2d5a86f3770374c87ee4c941916f64171e81f7684f2a73128"
+
+DEPENDS = "pps-tools"
+
+# Note: Despite being built via './configure; make; make install',
+#       chrony does not use GNU Autotools.
+inherit update-rc.d systemd
+
+# Configuration options:
+# - For command line editing support in chronyc, you may specify either
+#   'editline' or 'readline' but not both.  editline is smaller, but
+#   many systems already have readline for other purposes so you might want
+#   to choose that instead.  However, beware license incompatibility
+#   since chrony is GPLv2 and readline versions after 6.0 are GPLv3+.
+#   You can of course choose neither, but if you're that tight on space
+#   consider dropping chronyc entirely (you can use it remotely with
+#   appropriate chrony.conf options).
+# - Security-related:
+#   - 'sechash' is omitted by default because it pulls in nss which is huge.
+#   - 'privdrop' allows chronyd to run as non-root; would need changes to
+#     chrony.conf and init script.
+#   - 'scfilter' enables support for system call filtering, but requires the
+#     kernel to have CONFIG_SECCOMP enabled.
+PACKAGECONFIG ??= "editline \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} \
+"
+PACKAGECONFIG[readline] = "--without-editline,--without-readline,readline"
+PACKAGECONFIG[editline] = ",--without-editline,libedit"
+PACKAGECONFIG[sechash] = "--without-tomcrypt,--disable-sechash,nss"
+PACKAGECONFIG[privdrop] = ",--disable-privdrop,libcap"
+PACKAGECONFIG[scfilter] = "--enable-scfilter,--without-seccomp,libseccomp"
+PACKAGECONFIG[ipv6] = ",--disable-ipv6,"
+PACKAGECONFIG[nss] = "--with-nss,--without-nss,nss"
+PACKAGECONFIG[libcap] = "--with-libcap,--without-libcap,libcap"
+
+# --disable-static isn't supported by chrony's configure script.
+DISABLE_STATIC = ""
+
+do_configure() {
+    ./configure --sysconfdir=${sysconfdir} --bindir=${bindir} --sbindir=${sbindir} \
+                --localstatedir=${localstatedir} --datarootdir=${datadir} \
+                ${PACKAGECONFIG_CONFARGS}
+}
+
+do_install() {
+    # Binaries
+    install -d ${D}${bindir}
+    install -m 0755 ${S}/chronyc ${D}${bindir}
+    install -d ${D}${sbindir}
+    install -m 0755 ${S}/chronyd ${D}${sbindir}
+
+    # Config file
+    install -d ${D}${sysconfdir}
+    install -m 644 ${WORKDIR}/chrony.conf ${D}${sysconfdir}
+
+    # System V init script
+    install -d ${D}${sysconfdir}/init.d
+    install -m 755 ${WORKDIR}/chronyd ${D}${sysconfdir}/init.d
+
+    # systemd unit configuration file
+    install -d ${D}${systemd_unitdir}/system
+    install -m 0644 ${S}/examples/chronyd.service ${D}${systemd_unitdir}/system/
+
+    # Variable data (for drift and/or rtc file)
+    install -d ${D}${localstatedir}/lib/chrony
+
+    # Log files
+    install -d ${D}${localstatedir}/log/chrony
+
+    # Fix hard-coded paths in config files and init scripts
+    sed -i -e 's!/var/!${localstatedir}/!g' -e 's!/etc/!${sysconfdir}/!g' \
+           -e 's!/usr/sbin/!${sbindir}/!g' -e 's!/usr/bin/!${bindir}/!g' \
+           ${D}${sysconfdir}/chrony.conf \
+           ${D}${sysconfdir}/init.d/chronyd \
+           ${D}${systemd_unitdir}/system/chronyd.service
+    sed -i 's!^PATH=.*!PATH=${base_sbindir}:${base_bindir}:${sbindir}:${bindir}!' ${D}${sysconfdir}/init.d/chronyd
+    sed -i 's!^EnvironmentFile=.*!EnvironmentFile=-${sysconfdir}/default/chronyd!' ${D}${systemd_unitdir}/system/chronyd.service
+}
+
+FILES_${PN} = "${sbindir}/chronyd ${sysconfdir} ${localstatedir}"
+CONFFILES_${PN} = "${sysconfdir}/chrony.conf"
+INITSCRIPT_NAME = "chronyd"
+INITSCRIPT_PARAMS = "defaults"
+SYSTEMD_PACKAGES = "${PN}"
+SYSTEMD_SERVICE_${PN} = "chronyd.service"
+
+# It's probably a bad idea to run chrony and another time daemon on
+# the same system.  systemd includes the SNTP client 'timesyncd', which
+# will be disabled by chronyd.service, however it will remain on the rootfs
+# wasting 150 kB unless you put 'PACKAGECONFIG_remove_pn-systemd = "timesyncd"'
+# in a conf file or bbappend somewhere.
+RCONFLICTS_${PN} = "ntp ntimed"
+
+# Separate the client program into its own package
+PACKAGES =+ "chronyc"
+FILES_chronyc = "${bindir}/chronyc"
diff --git a/meta-openembedded/meta-networking/recipes-support/ctdb/ctdb/01-support-cross-compile-for-linux-os.patch b/meta-openembedded/meta-networking/recipes-support/ctdb/ctdb/01-support-cross-compile-for-linux-os.patch
deleted file mode 100644
index c9195b4..0000000
--- a/meta-openembedded/meta-networking/recipes-support/ctdb/ctdb/01-support-cross-compile-for-linux-os.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-support cross-compile for linux-os.
-
-Signed-off-by: Bian Naimeng <biannm@cn.fujitsu.com>
-
-diff -Nurp ctdb-2.5.1.orig/configure ctdb-2.5.1/configure
---- ctdb-2.5.1.orig/configure	2015-05-07 16:24:28.545000238 +0900
-+++ ctdb-2.5.1/configure	2015-05-07 16:28:20.894000244 +0900
-@@ -10692,10 +10692,16 @@ if test x"$libreplace_cv_HAVE_GETADDRINF
- 	# see bug 5910, use our replacements if we detect
- 	# a broken system.
- 	if test "$cross_compiling" = yes; then :
-+		case "$target_os" in
-+		*linux*)
-+			;;
-+		*)
-   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
- $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
- as_fn_error $? "cannot run test program while cross compiling
- See \`config.log' for more details" "$LINENO" 5; }
-+			;;
-+		esac
- else
-   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h.  */
diff --git a/meta-openembedded/meta-networking/recipes-support/ctdb/ctdb/02-link-rep_snprintf-for-ltdbtool.patch b/meta-openembedded/meta-networking/recipes-support/ctdb/ctdb/02-link-rep_snprintf-for-ltdbtool.patch
deleted file mode 100644
index 1294fe4..0000000
--- a/meta-openembedded/meta-networking/recipes-support/ctdb/ctdb/02-link-rep_snprintf-for-ltdbtool.patch
+++ /dev/null
@@ -1,17 +0,0 @@
-link rep_snprintf from lib/replace/snprintf.o for ltdbtool
-
-Signed-off-by: Bian Naimeng <biannm@cn.fujitsu.com>
-
-Index: ctdb-2.5.6/Makefile.in
-===================================================================
---- ctdb-2.5.6.orig/Makefile.in
-+++ ctdb-2.5.6/Makefile.in
-@@ -176,7 +176,7 @@ bin/ctdb: $(CTDB_CLIENT_OBJ) tools/ctdb.
- 	@echo Linking $@
- 	$(WRAPPER) $(CC) $(CFLAGS) -o $@ tools/ctdb.o tools/ctdb_vacuum.o $(CTDB_CLIENT_OBJ) $(LIB_FLAGS)
- 
--bin/ltdbtool: tools/ltdbtool.o $(TDB_OBJ)
-+bin/ltdbtool: tools/ltdbtool.o $(TDB_OBJ) lib/replace/snprintf.o
- 	@echo Linking $@
- 	$(WRAPPER) $(CC) $(CFLAGS) -o $@ $+ $(LIB_FLAGS)
- 
diff --git a/meta-openembedded/meta-networking/recipes-support/ctdb/ctdb/service-ensure-the-PID-directory-is-created.patch b/meta-openembedded/meta-networking/recipes-support/ctdb/ctdb/service-ensure-the-PID-directory-is-created.patch
deleted file mode 100644
index a7e987b..0000000
--- a/meta-openembedded/meta-networking/recipes-support/ctdb/ctdb/service-ensure-the-PID-directory-is-created.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From f02ff7383f1cc0c118732352ccbae476c7b3b3ba Mon Sep 17 00:00:00 2001
-From: Mark Asselstine <mark.asselstine@windriver.com>
-Date: Tue, 17 Nov 2015 16:17:00 -0500
-Subject: [PATCH] service: ensure the PID directory is created
-
-Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com>
----
- config/ctdb.service | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/config/ctdb.service b/config/ctdb.service
-index ea37c30..8537105 100644
---- a/config/ctdb.service
-+++ b/config/ctdb.service
-@@ -5,6 +5,7 @@ After=network.target
- [Service]
- Type=forking
- LimitCORE=infinity
-+RuntimeDirectory=/run/ctdb
- PIDFile=/run/ctdb/ctdbd.pid
- ExecStart=/usr/sbin/ctdbd_wrapper /run/ctdb/ctdbd.pid start
- ExecStop=/usr/sbin/ctdbd_wrapper /run/ctdb/ctdbd.pid stop
--- 
-2.1.4
-
diff --git a/meta-openembedded/meta-networking/recipes-support/ctdb/ctdb_2.5.6.bb b/meta-openembedded/meta-networking/recipes-support/ctdb/ctdb_2.5.6.bb
deleted file mode 100644
index b5a6064..0000000
--- a/meta-openembedded/meta-networking/recipes-support/ctdb/ctdb_2.5.6.bb
+++ /dev/null
@@ -1,57 +0,0 @@
-DESCRIPTION = "CTDB is a cluster implementation of the TDB database \
-used by Samba and other projects to store temporary data. If an \
-application is already using TDB for temporary data it is very easy \
-to convert that application to be cluster aware and use CTDB instead."
-HOMEPAGE = "https://ctdb.samba.org/"
-LICENSE = "GPL-2.0+ & LGPL-3.0+ & GPL-3.0+"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
-                    file://${COREBASE}/meta/files/common-licenses/LGPL-3.0;md5=bfccfe952269fff2b407dd11f2f3083b \
-                    file://${COREBASE}/meta/files/common-licenses/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6 \
-                    "
-
-SRC_URI = "https://ftp.samba.org/pub/${BPN}/${BP}.tar.gz \
-           file://01-support-cross-compile-for-linux-os.patch \
-           file://02-link-rep_snprintf-for-ltdbtool.patch \
-           file://service-ensure-the-PID-directory-is-created.patch \
-          "
-
-SRC_URI[md5sum] = "efc50109f90a4c790124c35e4ba234ad"
-SRC_URI[sha256sum] = "fc1cdd7efcc91afc629f21408281bba5da107b9c17e74bdee2f28a532d14f874"
-
-inherit autotools-brokensep pkgconfig systemd
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[libtdb] = "--without-included-tdb,--with-included-tdb,libtdb"
-
-PARALLEL_MAKE = ""
-
-DEPENDS += "popt libtevent libtalloc libldb"
-DEPENDS_append_libc-musl = " libtirpc"
-CFLAGS_append_libc-musl = " -I${STAGING_INCDIR}/tirpc"
-LDFLAGS_append_libc-musl = " -ltirpc"
-
-# ctdbd_wrapper requires pgrep, hence procps
-RDEPENDS_${PN} += "procps"
-
-do_configure() {
-    oe_runconf
-}
-
-do_install_append() {
-    install -d ${D}${systemd_unitdir}/system
-    install -m 0644 ${S}/config/ctdb.service ${D}${systemd_unitdir}/system
-    sed -i -e 's,/usr/sbin/,${sbindir}/,' ${D}${systemd_unitdir}/system/ctdb.service
-    sed -i -e 's,\([=\ ]\)/run/,\1${localstatedir}/run/,' ${D}${systemd_unitdir}/system/ctdb.service
-
-    rm -r ${D}/${localstatedir}/run
-}
-
-# The systemd service is disabled by default, as the service will fail to
-# start without /etc/ctdb/nodes. If the user supplies this, they can re-enable
-# the service.
-SYSTEMD_AUTO_ENABLE = "disable"
-SYSTEMD_SERVICE_${PN} = "ctdb.service"
-
-# onnode is a shell script with bashisms and bash #!
-RDEPENDS_${PN} += "bash"
diff --git a/meta-openembedded/meta-networking/recipes-support/curlpp/curlpp_0.8.1.bb b/meta-openembedded/meta-networking/recipes-support/curlpp/curlpp_0.8.1.bb
index 340f57d..799cf86 100644
--- a/meta-openembedded/meta-networking/recipes-support/curlpp/curlpp_0.8.1.bb
+++ b/meta-openembedded/meta-networking/recipes-support/curlpp/curlpp_0.8.1.bb
@@ -2,7 +2,7 @@
 HOMEPAGE = "http://www.curlpp.org/"
 SECTION = "libdevel"
 LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
+LIC_FILES_CHKSUM = "file://doc/LICENSE;md5=fd0c9adf285a69aa3b4faf34384e1029"
 
 DEPENDS = "curl"
 DEPENDS_class-native = "curl-native"
@@ -15,19 +15,4 @@
 
 inherit cmake pkgconfig binconfig
 
-do_install_append () {
-    sed -i 's,${STAGING_DIR_TARGET},,g' ${D}${libdir}/pkgconfig/curlpp.pc
-}
-
-PACKAGES =+ "libcurlpp libcurlpp-dev libcurlpp-staticdev"
-
-FILES_lib${BPN} = "${libdir}/lib*.so.*"
-
-FILES_lib${BPN}-dev = "${includedir} \
-    ${libdir}/pkgconfig \
-    ${bindir}/*-config \
-"
-
-FILES_lib${BPN}-staticdev = "${libdir}/lib*.a"
-
 BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-networking/recipes-support/dnsmasq/dnsmasq/lua.patch b/meta-openembedded/meta-networking/recipes-support/dnsmasq/dnsmasq/lua.patch
index 0991dd8..1bf0f75 100644
--- a/meta-openembedded/meta-networking/recipes-support/dnsmasq/dnsmasq/lua.patch
+++ b/meta-openembedded/meta-networking/recipes-support/dnsmasq/dnsmasq/lua.patch
@@ -1,7 +1,7 @@
 From be1b3d2d0f1608cba5efee73d6aac5ad0709041b Mon Sep 17 00:00:00 2001
 From: Joe MacDonald <joe_macdonald@mentor.com>
 Date: Tue, 9 Sep 2014 10:24:58 -0400
-Subject: [PATCH] Upstream-status: Inappropriate [OE specific]
+Subject: [PATCH] Upstream-Status: Inappropriate [OE specific]
 
 Signed-off-by: Christopher Larson <chris_larson@mentor.com>
 Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
diff --git a/meta-openembedded/meta-networking/recipes-support/dnsmasq/dnsmasq_2.78.bb b/meta-openembedded/meta-networking/recipes-support/dnsmasq/dnsmasq_2.78.bb
deleted file mode 100644
index d2465f8..0000000
--- a/meta-openembedded/meta-networking/recipes-support/dnsmasq/dnsmasq_2.78.bb
+++ /dev/null
@@ -1,9 +0,0 @@
-require dnsmasq.inc
-
-SRC_URI += "\
-    file://lua.patch \
-    file://CVE-2017-15107.patch \
-"
-
-SRC_URI[dnsmasq-2.78.md5sum] = "3bb97f264c73853f802bf70610150788"
-SRC_URI[dnsmasq-2.78.sha256sum] = "c92e5d78aa6353354d02aabf74590d08980bb1385d8a00b80ef9bc80430aa1dc"
diff --git a/meta-openembedded/meta-networking/recipes-support/dnsmasq/dnsmasq_2.79.bb b/meta-openembedded/meta-networking/recipes-support/dnsmasq/dnsmasq_2.79.bb
new file mode 100644
index 0000000..a66b9a9
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/dnsmasq/dnsmasq_2.79.bb
@@ -0,0 +1,8 @@
+require dnsmasq.inc
+
+SRC_URI[dnsmasq-2.79.md5sum] = "5d7120a46d0c16a334f46757d7e2ba55"
+SRC_URI[dnsmasq-2.79.sha256sum] = "77512dd6f31ffd96718e8dcbbf54f02c083f051d4cca709bd32540aea269f789"
+SRC_URI += "\
+    file://lua.patch \
+"
+
diff --git a/meta-openembedded/meta-networking/recipes-support/dnsmasq/files/CVE-2017-15107.patch b/meta-openembedded/meta-networking/recipes-support/dnsmasq/files/CVE-2017-15107.patch
deleted file mode 100644
index 701101b..0000000
--- a/meta-openembedded/meta-networking/recipes-support/dnsmasq/files/CVE-2017-15107.patch
+++ /dev/null
@@ -1,263 +0,0 @@
-From 5a56e1b78a753d3295564daddc9ce389cc69fd68 Mon Sep 17 00:00:00 2001
-From: Simon Kelley <simon@thekelleys.org.uk>
-Date: Fri, 19 Jan 2018 12:26:08 +0000
-Subject: [PATCH] DNSSEC fix for wildcard NSEC records. CVE-2017-15107 applies.
-
-It's OK for NSEC records to be expanded from wildcards,
-but in that case, the proof of non-existence is only valid
-starting at the wildcard name, *.<domain> NOT the name expanded
-from the wildcard. Without this check it's possible for an
-attacker to craft an NSEC which wrongly proves non-existence
-in a domain which includes a wildcard for NSEC.
-
-Upstream-Status: Backport [http://thekelleys.org.uk/gitweb/?p=dnsmasq.git;a=commit;h=4fe6744a220eddd3f1749b40cac3dfc510787de6]
-CVE: CVE-2017-15107
-Signed-off-by: Sinan Kaya <okaya@kernel.org>
----
- CHANGELOG    |  44 +++++++++++++++++++
- src/dnssec.c | 117 +++++++++++++++++++++++++++++++++++++++++++++------
- 2 files changed, 147 insertions(+), 14 deletions(-)
-
-diff --git a/CHANGELOG b/CHANGELOG
-index 075fe1a6..5226dce8 100644
---- a/CHANGELOG
-+++ b/CHANGELOG
-@@ -1,3 +1,47 @@
-+version 2.79
-+	Fix parsing of CNAME arguments, which are confused by extra spaces.
-+	Thanks to Diego Aguirre for spotting the bug.
-+
-+	Where available, use IP_UNICAST_IF or IPV6_UNICAST_IF to bind
-+	upstream servers to an interface, rather than SO_BINDTODEVICE.
-+	Thanks to Beniamino Galvani for the patch.
-+
-+	Always return a SERVFAIL answer to DNS queries without the
-+	recursion desired bit set, UNLESS acting as an authoritative
-+	DNS server. This avoids a potential route to cache snooping.
-+
-+	Add support for Ed25519 signatures in DNSSEC validation.
-+
-+	No longer support RSA/MD5 signatures in DNSSEC validation,
-+	since these are not secure. This behaviour is mandated in
-+	RFC-6944.
-+
-+	Fix incorrect error exit code from dhcp_release6 utility.
-+	Thanks Gaudenz Steinlin for the bug report.
-+
-+	Use SIGINT (instead of overloading SIGHUP) to turn on DNSSEC
-+	time validation when --dnssec-no-timecheck is in use.
-+	Note that this is an incompatible change from earlier releases.
-+
-+	Allow more than one --bridge-interface option to refer to an
-+	interface, so that we can use
-+	--bridge-interface=int1,alias1
-+	--bridge-interface=int1,alias2
-+	as an alternative to
-+	--bridge-interface=int1,alias1,alias2
-+	Thanks to Neil Jerram for work on this.
-+
-+	Fix for DNSSEC with wildcard-derived NSEC records.
-+	It's OK for NSEC records to be expanded from wildcards,
-+	but in that case, the proof of non-existence is only valid
-+	starting at the wildcard name, *.<domain> NOT the name expanded
-+	from the wildcard. Without this check it's possible for an
-+	attacker to craft an NSEC which wrongly proves non-existence.
-+	Thanks to Ralph Dolmans for finding this, and co-ordinating 
-+	the vulnerability tracking and fix release.
-+	CVE-2017-15107 applies.
-+
-+
- version 2.78
-         Fix logic of appending ".<layer>" to PXE basename. Thanks to Chris
- 	Novakovic for the patch.
-diff --git a/src/dnssec.c b/src/dnssec.c
-index a74d01ab..1417be56 100644
---- a/src/dnssec.c
-+++ b/src/dnssec.c
-@@ -424,15 +424,17 @@ static void from_wire(char *name)
- static int count_labels(char *name)
- {
-   int i;
--
-+  char *p;
-+  
-   if (*name == 0)
-     return 0;
- 
--  for (i = 0; *name; name++)
--    if (*name == '.')
-+  for (p = name, i = 0; *p; p++)
-+    if (*p == '.')
-       i++;
- 
--  return i+1;
-+  /* Don't count empty first label. */
-+  return *name == '.' ? i : i+1;
- }
- 
- /* Implement RFC1982 wrapped compare for 32-bit numbers */
-@@ -1405,8 +1407,8 @@ static int hostname_cmp(const char *a, const char *b)
-     }
- }
- 
--static int prove_non_existence_nsec(struct dns_header *header, size_t plen, unsigned char **nsecs, int nsec_count,
--				    char *workspace1, char *workspace2, char *name, int type, int *nons)
-+static int prove_non_existence_nsec(struct dns_header *header, size_t plen, unsigned char **nsecs, unsigned char **labels, int nsec_count,
-+				    char *workspace1_in, char *workspace2, char *name, int type, int *nons)
- {
-   int i, rc, rdlen;
-   unsigned char *p, *psave;
-@@ -1419,6 +1421,9 @@ static int prove_non_existence_nsec(struct dns_header *header, size_t plen, unsi
-   /* Find NSEC record that proves name doesn't exist */
-   for (i = 0; i < nsec_count; i++)
-     {
-+      char *workspace1 = workspace1_in;
-+      int sig_labels, name_labels;
-+
-       p = nsecs[i];
-       if (!extract_name(header, plen, &p, workspace1, 1, 10))
- 	return 0;
-@@ -1427,7 +1432,27 @@ static int prove_non_existence_nsec(struct dns_header *header, size_t plen, unsi
-       psave = p;
-       if (!extract_name(header, plen, &p, workspace2, 1, 10))
- 	return 0;
--      
-+
-+      /* If NSEC comes from wildcard expansion, use original wildcard
-+	 as name for computation. */
-+      sig_labels = *labels[i];
-+      name_labels = count_labels(workspace1);
-+
-+      if (sig_labels < name_labels)
-+	{
-+	  int k;
-+	  for (k = name_labels - sig_labels; k != 0; k--)
-+	    {
-+	      while (*workspace1 != '.' && *workspace1 != 0)
-+		workspace1++;
-+	      if (k != 1 && *workspace1 == '.')
-+		workspace1++;
-+	    }
-+	  
-+	  workspace1--;
-+	  *workspace1 = '*';
-+	}
-+	  
-       rc = hostname_cmp(workspace1, name);
-       
-       if (rc == 0)
-@@ -1825,24 +1850,26 @@ static int prove_non_existence_nsec3(struct dns_header *header, size_t plen, uns
- 
- static int prove_non_existence(struct dns_header *header, size_t plen, char *keyname, char *name, int qtype, int qclass, char *wildname, int *nons)
- {
--  static unsigned char **nsecset = NULL;
--  static int nsecset_sz = 0;
-+  static unsigned char **nsecset = NULL, **rrsig_labels = NULL;
-+  static int nsecset_sz = 0, rrsig_labels_sz = 0;
-   
-   int type_found = 0;
--  unsigned char *p = skip_questions(header, plen);
-+  unsigned char *auth_start, *p = skip_questions(header, plen);
-   int type, class, rdlen, i, nsecs_found;
-   
-   /* Move to NS section */
-   if (!p || !(p = skip_section(p, ntohs(header->ancount), header, plen)))
-     return 0;
-+
-+  auth_start = p;
-   
-   for (nsecs_found = 0, i = ntohs(header->nscount); i != 0; i--)
-     {
-       unsigned char *pstart = p;
-       
--      if (!(p = skip_name(p, header, plen, 10)))
-+      if (!extract_name(header, plen, &p, daemon->workspacename, 1, 10))
- 	return 0;
--      
-+	  
-       GETSHORT(type, p); 
-       GETSHORT(class, p);
-       p += 4; /* TTL */
-@@ -1859,7 +1886,69 @@ static int prove_non_existence(struct dns_header *header, size_t plen, char *key
- 	  if (!expand_workspace(&nsecset, &nsecset_sz, nsecs_found))
- 	    return 0; 
- 	  
--	  nsecset[nsecs_found++] = pstart;
-+	  if (type == T_NSEC)
-+	    {
-+	      /* If we're looking for NSECs, find the corresponding SIGs, to 
-+		 extract the labels value, which we need in case the NSECs
-+		 are the result of wildcard expansion.
-+		 Note that the NSEC may not have been validated yet
-+		 so if there are multiple SIGs, make sure the label value
-+		 is the same in all, to avoid be duped by a rogue one.
-+		 If there are no SIGs, that's an error */
-+	      unsigned char *p1 = auth_start;
-+	      int res, j, rdlen1, type1, class1;
-+	      
-+	      if (!expand_workspace(&rrsig_labels, &rrsig_labels_sz, nsecs_found))
-+		return 0;
-+	      
-+	      rrsig_labels[nsecs_found] = NULL;
-+	      
-+	      for (j = ntohs(header->nscount); j != 0; j--)
-+		{
-+		  if (!(res = extract_name(header, plen, &p1, daemon->workspacename, 0, 10)))
-+		    return 0;
-+
-+		   GETSHORT(type1, p1); 
-+		   GETSHORT(class1, p1);
-+		   p1 += 4; /* TTL */
-+		   GETSHORT(rdlen1, p1);
-+
-+		   if (!CHECK_LEN(header, p1, plen, rdlen1))
-+		     return 0;
-+		   
-+		   if (res == 1 && class1 == qclass && type1 == T_RRSIG)
-+		     {
-+		       int type_covered;
-+		       unsigned char *psav = p1;
-+		       
-+		       if (rdlen < 18)
-+			 return 0; /* bad packet */
-+
-+		       GETSHORT(type_covered, p1);
-+
-+		       if (type_covered == T_NSEC)
-+			 {
-+			   p1++; /* algo */
-+			   
-+			   /* labels field must be the same in every SIG we find. */
-+			   if (!rrsig_labels[nsecs_found])
-+			     rrsig_labels[nsecs_found] = p1;
-+			   else if (*rrsig_labels[nsecs_found] != *p1) /* algo */
-+			     return 0;
-+			   }
-+		       p1 = psav;
-+		     }
-+		   
-+		   if (!ADD_RDLEN(header, p1, plen, rdlen1))
-+		     return 0;
-+		}
-+
-+	      /* Must have found at least one sig. */
-+	      if (!rrsig_labels[nsecs_found])
-+		return 0;
-+	    }
-+
-+	  nsecset[nsecs_found++] = pstart;   
- 	}
-       
-       if (!ADD_RDLEN(header, p, plen, rdlen))
-@@ -1867,7 +1956,7 @@ static int prove_non_existence(struct dns_header *header, size_t plen, char *key
-     }
-   
-   if (type_found == T_NSEC)
--    return prove_non_existence_nsec(header, plen, nsecset, nsecs_found, daemon->workspacename, keyname, name, qtype, nons);
-+    return prove_non_existence_nsec(header, plen, nsecset, rrsig_labels, nsecs_found, daemon->workspacename, keyname, name, qtype, nons);
-   else if (type_found == T_NSEC3)
-     return prove_non_existence_nsec3(header, plen, nsecset, nsecs_found, daemon->workspacename, keyname, name, qtype, wildname, nons);
-   else
--- 
-2.19.0
-
diff --git a/meta-openembedded/meta-networking/recipes-support/dovecot/dovecot_2.2.33.bb b/meta-openembedded/meta-networking/recipes-support/dovecot/dovecot_2.2.33.bb
index 5ebda19..882d5d5 100644
--- a/meta-openembedded/meta-networking/recipes-support/dovecot/dovecot_2.2.33.bb
+++ b/meta-openembedded/meta-networking/recipes-support/dovecot/dovecot_2.2.33.bb
@@ -15,11 +15,9 @@
 SRC_URI[md5sum] = "d61d1e923a22f9062cc9f47696882666"
 SRC_URI[sha256sum] = "e9483d68a7698d701bc06124fcf6e1b1f16380c2986c7ec0cf4e1475b9d0c218"
 
-DEPENDS = "openssl xz zlib bzip2 libcap icu"
-
-DEPENDS_append_libc-musl = " libtirpc"
-CFLAGS_append_libc-musl = " -I${STAGING_INCDIR}/tirpc"
-LDFLAGS_append_libc-musl = " -ltirpc"
+DEPENDS = "openssl xz zlib bzip2 libcap icu libtirpc"
+CFLAGS += "-I${STAGING_INCDIR}/tirpc"
+LDFLAGS += "-ltirpc"
 
 inherit autotools pkgconfig systemd useradd
 
diff --git a/meta-openembedded/meta-networking/recipes-support/drbd/drbd-utils/0001-Makefile.in-fix-permission-bits-for-drbd.service.patch b/meta-openembedded/meta-networking/recipes-support/drbd/drbd-utils/0001-Makefile.in-fix-permission-bits-for-drbd.service.patch
deleted file mode 100644
index 90dd1f8..0000000
--- a/meta-openembedded/meta-networking/recipes-support/drbd/drbd-utils/0001-Makefile.in-fix-permission-bits-for-drbd.service.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-Upstream-Status: Pending
-
-Subject:  Makefile.in: fix permission bits for drbd.service
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- scripts/Makefile.in | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/scripts/Makefile.in b/scripts/Makefile.in
-index 402b93b..4a45407 100644
---- a/scripts/Makefile.in
-+++ b/scripts/Makefile.in
-@@ -65,7 +65,7 @@ endif
- # yes, debian apparently allows installing both types from the same package
- ifneq ($(initscripttype),sysv)		# "systemd" or "both"
- 	install -d $(DESTDIR)$(systemdunitdir)
--	install -m 755 drbd.service $(DESTDIR)$(systemdunitdir)/
-+	install -m 644 drbd.service $(DESTDIR)$(systemdunitdir)/
- 	install -d $(DESTDIR)/lib/drbd/
- 	install -m 755 drbd $(DESTDIR)/lib/drbd/
- 	install -d $(DESTDIR)$(tmpfilesdir)/
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-networking/recipes-support/drbd/drbd-utils/0001-drbd-drbd-tools-only-rmmod-if-DRBD-is-a-module.patch b/meta-openembedded/meta-networking/recipes-support/drbd/drbd-utils/0001-drbd-drbd-tools-only-rmmod-if-DRBD-is-a-module.patch
new file mode 100644
index 0000000..c0f3adf
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/drbd/drbd-utils/0001-drbd-drbd-tools-only-rmmod-if-DRBD-is-a-module.patch
@@ -0,0 +1,43 @@
+Subject: drbd-tools: only rmmod if DRBD is a module
+
+Account for the case if the DRBD drive is built into
+the kernel. Otherwise, errors, like the following,
+will occur:
+
+root@localhost:~# /etc/init.d/drbd stop
+    Stopping all DRBD resources: ERROR: Module drbd 
+    does not exist in /proc/modules
+
+Upstream-Status: Submitted [https://github.com/LINBIT/drbd-utils/pull/2]
+
+Signed-off-by: Aws Ismail <aws.ismail@windriver.com>
+Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
+
+[ refresh to 8.4.4: squash Aws' and Jason's patches ]
+Signed-off-by: Michel Thebeau <michel.thebeau@windriver.com>
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+
+---
+ scripts/drbd | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/scripts/drbd b/scripts/drbd
+index 20bf628..de589dc 100755
+--- a/scripts/drbd
++++ b/scripts/drbd
+@@ -241,7 +241,9 @@ case "$1" in
+ 		if [ -d /sys/module/drbd/holders ]; then
+ 			(cd /sys/module/drbd/holders; for tr in *; do [ -d ${tr} ] && ${RMMOD} ${tr}; done)
+ 		fi
+-		$RMMOD drbd && break
++		if [ ! -z "$(cat /proc/modules | grep -w drbd)" ]; then
++			$RMMOD drbd && break
++		fi
+ 	    fi
+ 	done
+ 	run_hook stop
+-- 
+1.9.1
+
diff --git a/meta-openembedded/meta-networking/recipes-support/drbd/drbd-utils_8.9.6.bb b/meta-openembedded/meta-networking/recipes-support/drbd/drbd-utils_8.9.6.bb
deleted file mode 100644
index 81f1cfe..0000000
--- a/meta-openembedded/meta-networking/recipes-support/drbd/drbd-utils_8.9.6.bb
+++ /dev/null
@@ -1,46 +0,0 @@
-SUMMARY = "Distributed block device driver for Linux"
-DESCRIPTION = "DRBD mirrors a block device over the network to another machine.\
-DRBD mirrors a block device over the network to another machine.\
-Think of it as networked raid 1. It is a building block for\
-setting up high availability (HA) clusters."
-HOMEPAGE = "http://www.drbd.org/"
-SECTION = "admin"
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=5574c6965ae5f583e55880e397fbb018"
-
-SRC_URI = "http://www.linbit.com/downloads/drbd/utils/archive/${BP}.tar.gz \
-           file://0001-Makefile.in-fix-permission-bits-for-drbd.service.patch \
-          "
-SRC_URI[md5sum] = "76ed6d3190cd77b00890f3365353124b"
-SRC_URI[sha256sum] = "297b77c9b3f88de2e7dae459234f2753ea4fc2805282b2d276e35cf51e292913"
-
-SYSTEMD_SERVICE_${PN} = "drbd.service"
-SYSTEMD_AUTO_ENABLE = "disable"
-
-inherit autotools-brokensep systemd
-
-EXTRA_OECONF = " \
-                --with-initdir=/etc/init.d    \
-                --without-pacemaker           \
-                --without-rgmanager           \
-                --without-bashcompletion      \
-                --with-distro debian          \
-                --with-initscripttype=both    \
-                --with-systemdunitdir=${systemd_unitdir}/system \
-                --without-manual\
-               "
-
-do_install_append() {
-    # don't install empty /var/lock to avoid conflict with base-files
-    rm -rf ${D}${localstatedir}/lock
-}
-
-RDEPENDS_${PN} += "bash perl-module-getopt-long perl-module-exporter perl-module-constant perl-module-overloading perl-module-exporter-heavy"
-
-# The drbd items are explicitly put under /lib when installed.
-#
-FILES_${PN} += "/run"
-FILES_${PN} += "${nonarch_base_libdir}/drbd \
-                ${nonarch_libdir}/drbd \
-                ${nonarch_libdir}/tmpfiles.d"
-FILES_${PN}-dbg += "${nonarch_base_libdir}/drbd/.debug"
diff --git a/meta-openembedded/meta-networking/recipes-support/drbd/drbd-utils_9.5.0.bb b/meta-openembedded/meta-networking/recipes-support/drbd/drbd-utils_9.5.0.bb
new file mode 100644
index 0000000..bd1e857
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/drbd/drbd-utils_9.5.0.bb
@@ -0,0 +1,63 @@
+SUMMARY = "Distributed block device driver for Linux"
+DESCRIPTION = "DRBD mirrors a block device over the network to another machine.\
+DRBD mirrors a block device over the network to another machine.\
+Think of it as networked raid 1. It is a building block for\
+setting up high availability (HA) clusters."
+HOMEPAGE = "http://www.drbd.org/"
+SECTION = "admin"
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=5574c6965ae5f583e55880e397fbb018"
+
+SRC_URI = "git://github.com/LINBIT/drbd-utils;name=drbd-utils \
+           git://github.com/LINBIT/drbd-headers;name=drbd-headers;destsuffix=git/drbd-headers \
+           file://0001-drbd-drbd-tools-only-rmmod-if-DRBD-is-a-module.patch \
+          "
+# v9.5.0
+SRCREV_drbd-utils = "ee126652638328b55dc6bff47d07d6161ab768db"
+SRCREV_drbd-headers = "b47cc11bcabe1a65c40ad23f71dcaf2da6419630"
+
+S = "${WORKDIR}/git"
+
+UPSTREAM_CHECK_URI = "https://github.com/LINBIT/drbd-utils/releases"
+
+SYSTEMD_SERVICE_${PN} = "drbd.service"
+SYSTEMD_AUTO_ENABLE = "disable"
+
+inherit autotools-brokensep systemd
+
+EXTRA_OECONF = " \
+                --with-initdir=/etc/init.d    \
+                --without-pacemaker           \
+                --without-rgmanager           \
+                --without-bashcompletion      \
+                --with-distro debian          \
+                --with-initscripttype=both    \
+                --with-systemdunitdir=${systemd_unitdir}/system \
+                --without-manual \
+               "
+
+do_configure_prepend() {
+    # move the the file under folder /lib/drbd/ to /usr/lib/drbd when usrmerge enabled
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'usrmerge', 'true', 'false', d)}; then
+        for m_file in `find ${S} -name 'Makefile.in'`; do
+            sed -i -e "s;\$(DESTDIR)\/lib\/drbd;\$(DESTDIR)\${nonarch_libdir}\/drbd;g" $m_file
+        done
+        # move the the file under folder /lib/udev/ to /usr/lib/udev when usrmerge enabled
+        sed -i -e "s;default_udevdir=/lib/udev;default_udevdir=\${prefix}/lib/udev;g" ${S}/configure.ac
+    fi
+
+}
+do_install_append() {
+    # don't install empty /var/lock to avoid conflict with base-files
+    rm -rf ${D}${localstatedir}/lock
+}
+
+RDEPENDS_${PN} += "bash perl-module-getopt-long perl-module-exporter perl-module-constant perl-module-overloading perl-module-exporter-heavy"
+
+# The drbd items are explicitly put under /lib when installed.
+#
+FILES_${PN} += "/run"
+FILES_${PN} += "${nonarch_base_libdir}/drbd \
+                ${nonarch_libdir}/drbd \
+                ${nonarch_libdir}/tmpfiles.d"
+FILES_${PN}-dbg += "${nonarch_base_libdir}/drbd/.debug"
diff --git a/meta-openembedded/meta-networking/recipes-support/esmtp/esmtp_1.2.bb b/meta-openembedded/meta-networking/recipes-support/esmtp/esmtp_1.2.bb
index 2da73e7..663161a 100644
--- a/meta-openembedded/meta-networking/recipes-support/esmtp/esmtp_1.2.bb
+++ b/meta-openembedded/meta-networking/recipes-support/esmtp/esmtp_1.2.bb
@@ -18,10 +18,12 @@
 
 inherit autotools update-alternatives
 
-ALTERNATIVE_${PN} = "sendmail"
-
+ALTERNATIVE_${PN} += "sendmail mailq newaliases"
+ALTERNATIVE_TARGET[mailq] = "${bindir}/mailq"
+ALTERNATIVE_TARGET[newaliases] = "${bindir}/newaliases"
 ALTERNATIVE_LINK_NAME[sendmail] = "${sbindir}/sendmail"
 ALTERNATIVE_TARGET[sendmail] = "${bindir}/esmtp"
+
 ALTERNATIVE_PRIORITY = "10"
 
 ALTERNATIVE_${PN}-doc += "mailq.1 newaliases.1 sendmail.1"
diff --git a/meta-openembedded/meta-networking/recipes-support/fetchmail/fetchmail/02_remove_SSLv3.patch b/meta-openembedded/meta-networking/recipes-support/fetchmail/fetchmail/02_remove_SSLv3.patch
new file mode 100644
index 0000000..95cfa2f
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/fetchmail/fetchmail/02_remove_SSLv3.patch
@@ -0,0 +1,1576 @@
+Description: <short summary of the patch>
+ TODO: Put a short summary on the line above and replace this paragraph
+ with a longer explanation of this change. Complete the meta-information
+ with other relevant fields (see below for details). To make it easier, the
+ information below has been extracted from the changelog. Adjust it or drop
+ it.
+ .
+ fetchmail (6.3.26-2) unstable; urgency=low
+ .
+   * New maintainer (closes: #800750).
+   * Backport upstream fix for SSLv3 removal (closes: #804604) and do not
+     recommend SSLv3 (closes: #801178).
+   * Remove quilt and its usage.
+   * Add dh-python to build depends.
+   * Update upstream URLs.
+   * Update watch file.
+   * Update Standards-Version to 3.9.6 .
+Author: Laszlo Boszormenyi (GCS) <gcs@debian.org>
+Bug-Debian: https://bugs.debian.org/800750
+Bug-Debian: https://bugs.debian.org/801178
+Bug-Debian: https://bugs.debian.org/804604
+
+---
+The information above should follow the Patch Tagging Guidelines, please
+checkout http://dep.debian.net/deps/dep3/ to learn about the format. Here
+are templates for supplementary fields that you might want to add:
+
+Origin: <vendor|upstream|other>, <url of original patch>
+Bug: <url in upstream bugtracker>
+Bug-Debian: https://bugs.debian.org/<bugnumber>
+Bug-Ubuntu: https://launchpad.net/bugs/<bugnumber>
+Forwarded: <no|not-needed|url proving that it has been forwarded>
+Reviewed-By: <name and email of someone who approved the patch>
+Last-Update: <YYYY-MM-DD>
+
+--- fetchmail-6.3.26.orig/Makefile.am
++++ fetchmail-6.3.26/Makefile.am
+@@ -31,7 +31,7 @@ libfm_a_SOURCES=	xmalloc.c base64.c rfc8
+ 			servport.c ntlm.h smbbyteorder.h smbdes.h smbmd4.h \
+ 			smbencrypt.h smbdes.c smbencrypt.c smbmd4.c smbutil.c \
+ 			libesmtp/gethostbyname.h libesmtp/gethostbyname.c \
+-			smbtypes.h fm_getaddrinfo.c tls.c rfc822valid.c \
++			smbtypes.h fm_getaddrinfo.c starttls.c rfc822valid.c \
+ 			xmalloc.h sdump.h sdump.c x509_name_match.c \
+ 			fm_strl.h md5c.c
+ if NTLM_ENABLE
+--- fetchmail-6.3.26.orig/Makefile.in
++++ fetchmail-6.3.26/Makefile.in
+@@ -97,14 +97,14 @@ am__libfm_a_SOURCES_DIST = xmalloc.c bas
+ 	rfc2047e.c servport.c ntlm.h smbbyteorder.h smbdes.h smbmd4.h \
+ 	smbencrypt.h smbdes.c smbencrypt.c smbmd4.c smbutil.c \
+ 	libesmtp/gethostbyname.h libesmtp/gethostbyname.c smbtypes.h \
+-	fm_getaddrinfo.c tls.c rfc822valid.c xmalloc.h sdump.h sdump.c \
++	fm_getaddrinfo.c starttls.c rfc822valid.c xmalloc.h sdump.h sdump.c \
+ 	x509_name_match.c fm_strl.h md5c.c ntlmsubr.c
+ @NTLM_ENABLE_TRUE@am__objects_1 = ntlmsubr.$(OBJEXT)
+ am_libfm_a_OBJECTS = xmalloc.$(OBJEXT) base64.$(OBJEXT) \
+ 	rfc822.$(OBJEXT) report.$(OBJEXT) rfc2047e.$(OBJEXT) \
+ 	servport.$(OBJEXT) smbdes.$(OBJEXT) smbencrypt.$(OBJEXT) \
+ 	smbmd4.$(OBJEXT) smbutil.$(OBJEXT) gethostbyname.$(OBJEXT) \
+-	fm_getaddrinfo.$(OBJEXT) tls.$(OBJEXT) rfc822valid.$(OBJEXT) \
++	fm_getaddrinfo.$(OBJEXT) starttls.$(OBJEXT) rfc822valid.$(OBJEXT) \
+ 	sdump.$(OBJEXT) x509_name_match.$(OBJEXT) md5c.$(OBJEXT) \
+ 	$(am__objects_1)
+ libfm_a_OBJECTS = $(am_libfm_a_OBJECTS)
+@@ -483,7 +483,7 @@ libfm_a_SOURCES = xmalloc.c base64.c rfc
+ 	servport.c ntlm.h smbbyteorder.h smbdes.h smbmd4.h \
+ 	smbencrypt.h smbdes.c smbencrypt.c smbmd4.c smbutil.c \
+ 	libesmtp/gethostbyname.h libesmtp/gethostbyname.c smbtypes.h \
+-	fm_getaddrinfo.c tls.c rfc822valid.c xmalloc.h sdump.h sdump.c \
++	fm_getaddrinfo.c starttls.c rfc822valid.c xmalloc.h sdump.h sdump.c \
+ 	x509_name_match.c fm_strl.h md5c.c $(am__append_1)
+ libfm_a_LIBADD = $(EXTRAOBJ)
+ libfm_a_DEPENDENCIES = $(EXTRAOBJ)
+--- fetchmail-6.3.26.orig/NEWS
++++ fetchmail-6.3.26/NEWS
+@@ -51,8 +51,6 @@ removed from a 6.4.0 or newer release.)
+ * The --bsmtp - mode of operation may be removed in a future release.
+ * Given that OpenSSL is severely underdocumented, and needs license exceptions,
+   fetchmail may switch to a different SSL library.
+-* SSLv2 support will be removed from a future fetchmail release. It has been
+-  obsolete for more than a decade.
+ 
+ --------------------------------------------------------------------------------
+ 
+--- fetchmail-6.3.26.orig/README.SSL
++++ fetchmail-6.3.26/README.SSL
+@@ -11,36 +11,45 @@ specific to fetchmail.
+ In case of troubles, mail the README.SSL-SERVER file to your ISP and 
+ have them check their server configuration against it.
+ 
+-Unfortunately, fetchmail confuses SSL/TLS protocol levels with whether 
+-a service needs to use in-band negotiation (STLS/STARTTLS for POP3/IMAP4) or is 
+-totally SSL-wrapped on a separate port.  For compatibility reasons, this cannot 
+-be fixed in a bugfix release.
++Unfortunately, fetchmail confuses SSL/TLS protocol levels with whether a
++service needs to use in-band negotiation (STLS/STARTTLS for POP3/IMAP4)
++or is totally SSL-wrapped on a separate port.  For compatibility
++reasons, this cannot be fixed in a bugfix or minor release.
++
++Also, fetchmail 6.4.0 and newer releases changed some of the semantics
++as the result of a bug-fix, and will auto-negotiate TLSv1 or newer only.
++If your server does not support this, you may have to specify --sslproto
++ssl3.  This is in order to prefer the newer TLS protocols, because SSLv2
++and v3 are broken.
+ 
+-	-- Matthias Andree, 2009-05-09
++       -- Matthias Andree, 2015-01-16
+ 
+ 
+ Quickstart
+ ----------
+ 
++Use an up-to-date release of OpenSSL 1.0.1 or newer, so as to get
++TLSv1.2 support.
++
+ For use of SSL or TLS with in-band negotiation on the regular service's port, 
+ i. e. with STLS or STARTTLS, use these command line options
+ 
+-    --sslproto tls1 --sslcertck
++    --sslproto auto --sslcertck
+ 
+ or these options in the rcfile (after the respective "user"... options)
+ 
+-      sslproto tls1   sslcertck
++      sslproto auto   sslcertck
+ 
+ 
+ For use of SSL or TLS on a separate port, if the whole TCP connection is 
+-SSL-encrypted from the very beginning, use these command line options (in the 
+-rcfile, omit all leading "--"):
++SSL-encrypted from the very beginning (SSL- or TLS-wrapped), use these
++command line options (in the rcfile, omit all leading "--"):
+ 
+-    --ssl --sslproto ssl3 --sslcertck
++    --ssl --sslproto auto --sslcertck
+ 
+ or these options in the rcfile (after the respective "user"... options)
+ 
+-      ssl   sslproto ssl3   sslcertck
++      ssl   sslproto auto   sslcertck
+ 
+ 
+ Background and use (long version :-))
+--- fetchmail-6.3.26.orig/config.h.in
++++ fetchmail-6.3.26/config.h.in
+@@ -49,9 +49,9 @@
+    don't. */
+ #undef HAVE_DECL_H_ERRNO
+ 
+-/* Define to 1 if you have the declaration of `SSLv2_client_method', and to 0
++/* Define to 1 if you have the declaration of `SSLv3_client_method', and to 0
+    if you don't. */
+-#undef HAVE_DECL_SSLV2_CLIENT_METHOD
++#undef HAVE_DECL_SSLV3_CLIENT_METHOD
+ 
+ /* Define to 1 if you have the declaration of `strerror', and to 0 if you
+    don't. */
+--- fetchmail-6.3.26.orig/configure
++++ fetchmail-6.3.26/configure
+@@ -1,13 +1,11 @@
+ #! /bin/sh
+ # Guess values for system-dependent variables and create Makefiles.
+-# Generated by GNU Autoconf 2.68 for fetchmail 6.3.26.
++# Generated by GNU Autoconf 2.69 for fetchmail 6.3.26.
+ #
+ # Report bugs to <fetchmail-users@lists.berlios.de>.
+ #
+ #
+-# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
+-# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software
+-# Foundation, Inc.
++# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
+ #
+ #
+ # This configure script is free software; the Free Software Foundation
+@@ -136,6 +134,31 @@ export LANGUAGE
+ # CDPATH.
+ (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
+ 
++# Use a proper internal environment variable to ensure we don't fall
++  # into an infinite loop, continuously re-executing ourselves.
++  if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
++    _as_can_reexec=no; export _as_can_reexec;
++    # We cannot yet assume a decent shell, so we have to provide a
++# neutralization value for shells without unset; and this also
++# works around shells that cannot unset nonexistent variables.
++# Preserve -v and -x to the replacement shell.
++BASH_ENV=/dev/null
++ENV=/dev/null
++(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
++case $- in # ((((
++  *v*x* | *x*v* ) as_opts=-vx ;;
++  *v* ) as_opts=-v ;;
++  *x* ) as_opts=-x ;;
++  * ) as_opts= ;;
++esac
++exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
++# Admittedly, this is quite paranoid, since all the known shells bail
++# out after a failed `exec'.
++$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
++as_fn_exit 255
++  fi
++  # We don't want this to propagate to other subprocesses.
++          { _as_can_reexec=; unset _as_can_reexec;}
+ if test "x$CONFIG_SHELL" = x; then
+   as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
+   emulate sh
+@@ -169,7 +192,8 @@ if ( set x; as_fn_ret_success y && test
+ else
+   exitcode=1; echo positional parameters were not saved.
+ fi
+-test x\$exitcode = x0 || exit 1"
++test x\$exitcode = x0 || exit 1
++test -x / || exit 1"
+   as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
+   as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
+   eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
+@@ -214,21 +238,25 @@ IFS=$as_save_IFS
+ 
+ 
+       if test "x$CONFIG_SHELL" != x; then :
+-  # We cannot yet assume a decent shell, so we have to provide a
+-	# neutralization value for shells without unset; and this also
+-	# works around shells that cannot unset nonexistent variables.
+-	# Preserve -v and -x to the replacement shell.
+-	BASH_ENV=/dev/null
+-	ENV=/dev/null
+-	(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
+-	export CONFIG_SHELL
+-	case $- in # ((((
+-	  *v*x* | *x*v* ) as_opts=-vx ;;
+-	  *v* ) as_opts=-v ;;
+-	  *x* ) as_opts=-x ;;
+-	  * ) as_opts= ;;
+-	esac
+-	exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"}
++  export CONFIG_SHELL
++             # We cannot yet assume a decent shell, so we have to provide a
++# neutralization value for shells without unset; and this also
++# works around shells that cannot unset nonexistent variables.
++# Preserve -v and -x to the replacement shell.
++BASH_ENV=/dev/null
++ENV=/dev/null
++(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
++case $- in # ((((
++  *v*x* | *x*v* ) as_opts=-vx ;;
++  *v* ) as_opts=-v ;;
++  *x* ) as_opts=-x ;;
++  * ) as_opts= ;;
++esac
++exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
++# Admittedly, this is quite paranoid, since all the known shells bail
++# out after a failed `exec'.
++$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
++exit 255
+ fi
+ 
+     if test x$as_have_required = xno; then :
+@@ -331,6 +359,14 @@ $as_echo X"$as_dir" |
+ 
+ 
+ } # as_fn_mkdir_p
++
++# as_fn_executable_p FILE
++# -----------------------
++# Test if FILE is an executable regular file.
++as_fn_executable_p ()
++{
++  test -f "$1" && test -x "$1"
++} # as_fn_executable_p
+ # as_fn_append VAR VALUE
+ # ----------------------
+ # Append the text in VALUE to the end of the definition contained in VAR. Take
+@@ -452,6 +488,10 @@ as_cr_alnum=$as_cr_Letters$as_cr_digits
+   chmod +x "$as_me.lineno" ||
+     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
+ 
++  # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
++  # already done that, so ensure we don't try to do so again and fall
++  # in an infinite loop.  This has already happened in practice.
++  _as_can_reexec=no; export _as_can_reexec
+   # Don't try to exec as it changes $[0], causing all sort of problems
+   # (the dirname of $[0] is not the place where we might find the
+   # original and so on.  Autoconf is especially sensitive to this).
+@@ -486,16 +526,16 @@ if (echo >conf$$.file) 2>/dev/null; then
+     # ... but there are two gotchas:
+     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
+     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
+-    # In both cases, we have to default to `cp -p'.
++    # In both cases, we have to default to `cp -pR'.
+     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
+-      as_ln_s='cp -p'
++      as_ln_s='cp -pR'
+   elif ln conf$$.file conf$$ 2>/dev/null; then
+     as_ln_s=ln
+   else
+-    as_ln_s='cp -p'
++    as_ln_s='cp -pR'
+   fi
+ else
+-  as_ln_s='cp -p'
++  as_ln_s='cp -pR'
+ fi
+ rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
+ rmdir conf$$.dir 2>/dev/null
+@@ -507,28 +547,8 @@ else
+   as_mkdir_p=false
+ fi
+ 
+-if test -x / >/dev/null 2>&1; then
+-  as_test_x='test -x'
+-else
+-  if ls -dL / >/dev/null 2>&1; then
+-    as_ls_L_option=L
+-  else
+-    as_ls_L_option=
+-  fi
+-  as_test_x='
+-    eval sh -c '\''
+-      if test -d "$1"; then
+-	test -d "$1/.";
+-      else
+-	case $1 in #(
+-	-*)set "./$1";;
+-	esac;
+-	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
+-	???[sx]*):;;*)false;;esac;fi
+-    '\'' sh
+-  '
+-fi
+-as_executable_p=$as_test_x
++as_test_x='test -x'
++as_executable_p=as_fn_executable_p
+ 
+ # Sed expression to map a string onto a valid CPP name.
+ as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
+@@ -742,6 +762,7 @@ infodir
+ docdir
+ oldincludedir
+ includedir
++runstatedir
+ localstatedir
+ sharedstatedir
+ sysconfdir
+@@ -841,6 +862,7 @@ datadir='${datarootdir}'
+ sysconfdir='${prefix}/etc'
+ sharedstatedir='${prefix}/com'
+ localstatedir='${prefix}/var'
++runstatedir='${localstatedir}/run'
+ includedir='${prefix}/include'
+ oldincludedir='/usr/include'
+ docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
+@@ -1093,6 +1115,15 @@ do
+   | -silent | --silent | --silen | --sile | --sil)
+     silent=yes ;;
+ 
++  -runstatedir | --runstatedir | --runstatedi | --runstated \
++  | --runstate | --runstat | --runsta | --runst | --runs \
++  | --run | --ru | --r)
++    ac_prev=runstatedir ;;
++  -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
++  | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
++  | --run=* | --ru=* | --r=*)
++    runstatedir=$ac_optarg ;;
++
+   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
+     ac_prev=sbindir ;;
+   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
+@@ -1230,7 +1261,7 @@ fi
+ for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
+ 		datadir sysconfdir sharedstatedir localstatedir includedir \
+ 		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
+-		libdir localedir mandir
++		libdir localedir mandir runstatedir
+ do
+   eval ac_val=\$$ac_var
+   # Remove trailing slashes.
+@@ -1258,8 +1289,6 @@ target=$target_alias
+ if test "x$host_alias" != x; then
+   if test "x$build_alias" = x; then
+     cross_compiling=maybe
+-    $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host.
+-    If a cross compiler is detected then cross compile mode will be used" >&2
+   elif test "x$build_alias" != "x$host_alias"; then
+     cross_compiling=yes
+   fi
+@@ -1385,6 +1414,7 @@ Fine tuning of the installation director
+   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
+   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
+   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
++  --runstatedir=DIR       modifiable per-process data [LOCALSTATEDIR/run]
+   --libdir=DIR            object code libraries [EPREFIX/lib]
+   --includedir=DIR        C header files [PREFIX/include]
+   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
+@@ -1548,9 +1578,9 @@ test -n "$ac_init_help" && exit $ac_stat
+ if $ac_init_version; then
+   cat <<\_ACEOF
+ fetchmail configure 6.3.26
+-generated by GNU Autoconf 2.68
++generated by GNU Autoconf 2.69
+ 
+-Copyright (C) 2010 Free Software Foundation, Inc.
++Copyright (C) 2012 Free Software Foundation, Inc.
+ This configure script is free software; the Free Software Foundation
+ gives unlimited permission to copy, distribute and modify it.
+ _ACEOF
+@@ -1827,7 +1857,7 @@ $as_echo "$ac_try_echo"; } >&5
+ 	 test ! -s conftest.err
+        } && test -s conftest$ac_exeext && {
+ 	 test "$cross_compiling" = yes ||
+-	 $as_test_x conftest$ac_exeext
++	 test -x conftest$ac_exeext
+        }; then :
+   ac_retval=0
+ else
+@@ -2030,7 +2060,8 @@ int
+ main ()
+ {
+ static int test_array [1 - 2 * !(($2) >= 0)];
+-test_array [0] = 0
++test_array [0] = 0;
++return test_array [0];
+ 
+   ;
+   return 0;
+@@ -2046,7 +2077,8 @@ int
+ main ()
+ {
+ static int test_array [1 - 2 * !(($2) <= $ac_mid)];
+-test_array [0] = 0
++test_array [0] = 0;
++return test_array [0];
+ 
+   ;
+   return 0;
+@@ -2072,7 +2104,8 @@ int
+ main ()
+ {
+ static int test_array [1 - 2 * !(($2) < 0)];
+-test_array [0] = 0
++test_array [0] = 0;
++return test_array [0];
+ 
+   ;
+   return 0;
+@@ -2088,7 +2121,8 @@ int
+ main ()
+ {
+ static int test_array [1 - 2 * !(($2) >= $ac_mid)];
+-test_array [0] = 0
++test_array [0] = 0;
++return test_array [0];
+ 
+   ;
+   return 0;
+@@ -2122,7 +2156,8 @@ int
+ main ()
+ {
+ static int test_array [1 - 2 * !(($2) <= $ac_mid)];
+-test_array [0] = 0
++test_array [0] = 0;
++return test_array [0];
+ 
+   ;
+   return 0;
+@@ -2195,7 +2230,7 @@ This file contains any messages produced
+ running configure, to aid debugging if configure makes a mistake.
+ 
+ It was created by fetchmail $as_me 6.3.26, which was
+-generated by GNU Autoconf 2.68.  Invocation command line was
++generated by GNU Autoconf 2.69.  Invocation command line was
+ 
+   $ $0 $@
+ 
+@@ -2689,7 +2724,7 @@ case $as_dir/ in #((
+     # by default.
+     for ac_prog in ginstall scoinst install; do
+       for ac_exec_ext in '' $ac_executable_extensions; do
+-	if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
++	if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
+ 	  if test $ac_prog = install &&
+ 	    grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
+ 	    # AIX install.  It has an incompatible calling convention.
+@@ -2858,7 +2893,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -2898,7 +2933,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_prog_ac_ct_STRIP="strip"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -2949,7 +2984,7 @@ do
+   test -z "$as_dir" && as_dir=.
+     for ac_prog in mkdir gmkdir; do
+ 	 for ac_exec_ext in '' $ac_executable_extensions; do
+-	   { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
++	   as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
+ 	   case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
+ 	     'mkdir (GNU coreutils) '* | \
+ 	     'mkdir (coreutils) '* | \
+@@ -3002,7 +3037,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_prog_AWK="$ac_prog"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -3295,7 +3330,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -3466,7 +3501,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_prog_AWK="$ac_prog"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -3512,7 +3547,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_prog_CC="${ac_tool_prefix}gcc"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -3552,7 +3587,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_prog_ac_ct_CC="gcc"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -3605,7 +3640,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_prog_CC="${ac_tool_prefix}cc"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -3646,7 +3681,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
+        ac_prog_rejected=yes
+        continue
+@@ -3704,7 +3739,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -3748,7 +3783,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_prog_ac_ct_CC="$ac_prog"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -4194,8 +4229,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_
+ /* end confdefs.h.  */
+ #include <stdarg.h>
+ #include <stdio.h>
+-#include <sys/types.h>
+-#include <sys/stat.h>
++struct stat;
+ /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
+ struct buf { int x; };
+ FILE * (*rcsopen) (struct buf *, struct stat *, int);
+@@ -4751,7 +4785,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -4791,7 +4825,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_prog_ac_ct_RANLIB="ranlib"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -4859,7 +4893,7 @@ do
+     for ac_prog in grep ggrep; do
+     for ac_exec_ext in '' $ac_executable_extensions; do
+       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
+-      { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
++      as_fn_executable_p "$ac_path_GREP" || continue
+ # Check for GNU ac_path_GREP and select it if it is found.
+   # Check for GNU $ac_path_GREP
+ case `"$ac_path_GREP" --version 2>&1` in
+@@ -4925,7 +4959,7 @@ do
+     for ac_prog in egrep; do
+     for ac_exec_ext in '' $ac_executable_extensions; do
+       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
+-      { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
++      as_fn_executable_p "$ac_path_EGREP" || continue
+ # Check for GNU ac_path_EGREP and select it if it is found.
+   # Check for GNU $ac_path_EGREP
+ case `"$ac_path_EGREP" --version 2>&1` in
+@@ -5132,8 +5166,8 @@ else
+   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h.  */
+ 
+-#	  define __EXTENSIONS__ 1
+-	  $ac_includes_default
++#         define __EXTENSIONS__ 1
++          $ac_includes_default
+ int
+ main ()
+ {
+@@ -5513,11 +5547,11 @@ else
+ int
+ main ()
+ {
+-/* FIXME: Include the comments suggested by Paul. */
++
+ #ifndef __cplusplus
+-  /* Ultrix mips cc rejects this.  */
++  /* Ultrix mips cc rejects this sort of thing.  */
+   typedef int charset[2];
+-  const charset cs;
++  const charset cs = { 0, 0 };
+   /* SunOS 4.1.1 cc rejects this.  */
+   char const *const *pcpcc;
+   char **ppc;
+@@ -5534,8 +5568,9 @@ main ()
+   ++pcpcc;
+   ppc = (char**) pcpcc;
+   pcpcc = (char const *const *) ppc;
+-  { /* SCO 3.2v4 cc rejects this.  */
+-    char *t;
++  { /* SCO 3.2v4 cc rejects this sort of thing.  */
++    char tx;
++    char *t = &tx;
+     char const *s = 0 ? (char *) 0 : (char const *) 0;
+ 
+     *t++ = 0;
+@@ -5551,10 +5586,10 @@ main ()
+     iptr p = 0;
+     ++p;
+   }
+-  { /* AIX XL C 1.02.0.0 rejects this saying
++  { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
+        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
+-    struct s { int j; const int *ap[3]; };
+-    struct s *b; b->j = 5;
++    struct s { int j; const int *ap[3]; } bx;
++    struct s *b = &bx; b->j = 5;
+   }
+   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
+     const int foo = 10;
+@@ -5600,7 +5635,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_prog_LEX="$ac_prog"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -5632,7 +5667,8 @@ a { ECHO; }
+ b { REJECT; }
+ c { yymore (); }
+ d { yyless (1); }
+-e { yyless (input () != 0); }
++e { /* IRIX 6.5 flex 2.5.4 underquotes its yyless argument.  */
++    yyless ((input () != 0)); }
+ f { unput (yytext[0]); }
+ . { BEGIN INITIAL; }
+ %%
+@@ -5792,7 +5828,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_prog_YACC="$ac_prog"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -6044,7 +6080,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -8548,7 +8584,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_path_procmail="$as_dir/$ac_word$ac_exec_ext"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -8590,7 +8626,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_path_sendmail="$as_dir/$ac_word$ac_exec_ext"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -8632,7 +8668,7 @@ do
+   IFS=$as_save_IFS
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+     ac_cv_path_maildrop="$as_dir/$ac_word$ac_exec_ext"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+@@ -10121,16 +10157,16 @@ $as_echo "$as_me: WARNING: Consider re-r
+ fi
+ 
+ case "$LIBS" in *-lssl*)
+-	ac_fn_c_check_decl "$LINENO" "SSLv2_client_method" "ac_cv_have_decl_SSLv2_client_method" "#include <openssl/ssl.h>
++	ac_fn_c_check_decl "$LINENO" "SSLv3_client_method" "ac_cv_have_decl_SSLv3_client_method" "#include <openssl/ssl.h>
+ "
+-if test "x$ac_cv_have_decl_SSLv2_client_method" = xyes; then :
++if test "x$ac_cv_have_decl_SSLv3_client_method" = xyes; then :
+   ac_have_decl=1
+ else
+   ac_have_decl=0
+ fi
+ 
+ cat >>confdefs.h <<_ACEOF
+-#define HAVE_DECL_SSLV2_CLIENT_METHOD $ac_have_decl
++#define HAVE_DECL_SSLV3_CLIENT_METHOD $ac_have_decl
+ _ACEOF
+ 
+ 	;;
+@@ -11334,16 +11370,16 @@ if (echo >conf$$.file) 2>/dev/null; then
+     # ... but there are two gotchas:
+     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
+     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
+-    # In both cases, we have to default to `cp -p'.
++    # In both cases, we have to default to `cp -pR'.
+     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
+-      as_ln_s='cp -p'
++      as_ln_s='cp -pR'
+   elif ln conf$$.file conf$$ 2>/dev/null; then
+     as_ln_s=ln
+   else
+-    as_ln_s='cp -p'
++    as_ln_s='cp -pR'
+   fi
+ else
+-  as_ln_s='cp -p'
++  as_ln_s='cp -pR'
+ fi
+ rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
+ rmdir conf$$.dir 2>/dev/null
+@@ -11403,28 +11439,16 @@ else
+   as_mkdir_p=false
+ fi
+ 
+-if test -x / >/dev/null 2>&1; then
+-  as_test_x='test -x'
+-else
+-  if ls -dL / >/dev/null 2>&1; then
+-    as_ls_L_option=L
+-  else
+-    as_ls_L_option=
+-  fi
+-  as_test_x='
+-    eval sh -c '\''
+-      if test -d "$1"; then
+-	test -d "$1/.";
+-      else
+-	case $1 in #(
+-	-*)set "./$1";;
+-	esac;
+-	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
+-	???[sx]*):;;*)false;;esac;fi
+-    '\'' sh
+-  '
+-fi
+-as_executable_p=$as_test_x
++
++# as_fn_executable_p FILE
++# -----------------------
++# Test if FILE is an executable regular file.
++as_fn_executable_p ()
++{
++  test -f "$1" && test -x "$1"
++} # as_fn_executable_p
++as_test_x='test -x'
++as_executable_p=as_fn_executable_p
+ 
+ # Sed expression to map a string onto a valid CPP name.
+ as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
+@@ -11446,7 +11470,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_wri
+ # values after options handling.
+ ac_log="
+ This file was extended by fetchmail $as_me 6.3.26, which was
+-generated by GNU Autoconf 2.68.  Invocation command line was
++generated by GNU Autoconf 2.69.  Invocation command line was
+ 
+   CONFIG_FILES    = $CONFIG_FILES
+   CONFIG_HEADERS  = $CONFIG_HEADERS
+@@ -11512,10 +11536,10 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_writ
+ ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
+ ac_cs_version="\\
+ fetchmail config.status 6.3.26
+-configured by $0, generated by GNU Autoconf 2.68,
++configured by $0, generated by GNU Autoconf 2.69,
+   with options \\"\$ac_cs_config\\"
+ 
+-Copyright (C) 2010 Free Software Foundation, Inc.
++Copyright (C) 2012 Free Software Foundation, Inc.
+ This config.status script is free software; the Free Software Foundation
+ gives unlimited permission to copy, distribute and modify it."
+ 
+@@ -11606,7 +11630,7 @@ fi
+ _ACEOF
+ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
+ if \$ac_cs_recheck; then
+-  set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
++  set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
+   shift
+   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
+   CONFIG_SHELL='$SHELL'
+--- fetchmail-6.3.26.orig/configure.ac
++++ fetchmail-6.3.26/configure.ac
+@@ -802,7 +802,7 @@ else
+ fi
+ 
+ case "$LIBS" in *-lssl*)
+-	AC_CHECK_DECLS([SSLv2_client_method],,,[#include <openssl/ssl.h>])
++	AC_CHECK_DECLS([SSLv3_client_method],,,[#include <openssl/ssl.h>])
+ 	;;
+ esac
+ 
+--- fetchmail-6.3.26.orig/fetchmail-FAQ.html
++++ fetchmail-6.3.26/fetchmail-FAQ.html
+@@ -667,8 +667,8 @@ because there is not currently a standar
+ also uses this method, so the two will interoperate happily. They
+ better, because this is how Craig gets his mail ;-)</p>
+ 
+-<p>Finally, you can use <a href="#K5">SSL</a> for complete
+-end-to-end encryption if you have an SSL-enabled mailserver.</p>
++<p>Finally, you can use <a href="#K5">SSL or TLS</a> for complete
++end-to-end encryption if you have a TLS-enabled mailserver.</p>
+ 
+ <h2><a id="G11" name="G11">G11. Is any special configuration needed
+ to use a dynamic IP address?</a></h2>
+@@ -2120,7 +2120,7 @@ SSL?</a></h2>
+ 
+ <p>You'll need to have the <a
+ href="http://www.openssl.org/">OpenSSL</a> libraries installed, and they
+-should at least be version 0.9.7.
++should at least be version 0.9.8, with 1.0.1 preferred.
+ Configure with --with-ssl. If you have the OpenSSL libraries
+ installed in commonly-used default locations, this will
+ suffice. If you have them installed in a non-default location,
+@@ -2130,7 +2130,7 @@ to --with-ssl after an equal sign.</p>
+ <p>Fetchmail binaries built this way support <code>ssl</code>,
+ <code>sslkey</code>, and <code>sslcert</code> options that control
+ SSL encryption, and will automatically use <code>tls</code> if the
+-server offers it. You will need to have an SSL-enabled mailserver to
++server offers it. You will need to have an SSL/TLS-enabled mailserver to
+ use these options. See the manual page for details and some words
+ of care on the limited security provided.</p>
+ 
+@@ -2155,13 +2155,14 @@ poll MYSERVER port 993 plugin "openssl s
+         protocol imap username MYUSERNAME password MYPASSWORD
+ </pre>
+ 
+-<p>You should note that SSL is only secure against a "man-in-the-middle"
+-attack if the client is able to verify that the peer's public key is the
+-correct one, and has not been substituted by an attacker. fetchmail can do
+-this in one of two ways: by verifying the SSL certificate, or by checking
+-the fingerprint of the peer's public key.</p>
++<p>You should note that SSL or TLS are only secure against a
++"man-in-the-middle" attack if the client is able to verify that the
++peer's public key is the correct one, and has not been substituted by an
++attacker. fetchmail can do this in one of two ways: by verifying the SSL
++certificate, or by checking the fingerprint of the peer's public
++key.</p>
+ 
+-<p>There are three parts to SSL certificate verification: checking that the
++<p>There are three parts to TLS certificate verification: checking that the
+ domain name in the certificate matches the hostname you asked to connect to;
+ checking that the certificate expiry date has not passed; and checking that
+ the certificate has been signed by a known Certificate Authority (CA). This
+@@ -2227,8 +2228,12 @@ will automatically attempt TLS negotiati
+ time.  This can however cause problems if the upstream didn't configure
+ his certificates properly.</p>
+ 
+-<p>In order to prevent fetchmail from trying TLS (STLS, STARTTLS)
+-negotiation, add this option:</p>
++<p>In order to prevent fetchmail 6.4.0 and newer versions from trying
++STLS or STARTTLS negotiation, add this option:</p>
++<pre>sslproto ''</pre>
++
++<p>In order to prevent older fetchmail versions from trying TLS (STLS, STARTTLS)
++negotiation where the above does not work, try this option:</p>
+ 
+ <pre>sslproto ssl23</pre>
+ 
+@@ -2876,15 +2881,22 @@ need to say something like '<code>envelo
+ 
+ <pre>
+ Received: from send103.yahoomail.com (send103.yahoomail.com [205.180.60.92])
+-    by iserv.ttns.net (8.8.5/8.8.5) with SMTP id RAA10088
+-    for &lt;ksturgeon@fbceg.org&gt;; Wed, 9 Sep 1998 17:01:59 -0700
++    by iserv.example.net (8.8.5/8.8.5) with SMTP id RAA10088
++    for &lt;ksturgeon@fbceg.example.org&gt;; Wed, 9 Sep 1998 17:01:59 -0700
+ </pre>
+ 
+-<p>it checks to see if 'iserv.ttns.net' is a DNS alias of your
+-mailserver before accepting 'ksturgeon@fbceg.org' as an envelope
++<p>it checks to see if 'iserv.example.net' is a DNS alias of your
++mailserver before accepting 'ksturgeon@fbceg.example.org' as an envelope
+ address. This check might fail if your DNS were misconfigured, or
+-if you were using 'no dns' and had failed to declare iserv.ttns.net
+-as an alias of your server.</p>
++if you were using 'no dns' and had failed to declare iserv.example.net
++as an alias of your server. The typical hint is logging similar to:
++<code>line rejected, iserv.example.net is not an alias of the mailserver</code>,
++if you use fetchmail in verbose mode.</p>
++
++<p><strong>Workaround:</strong> You can specify the alias explicitly, with <code>aka
++    <em>iserv.example.net</em></code> statements in the rcfile. Replace
++<em>iserv.example.net</em> by the name you find in <strong>your</strong>
++'by' part of the 'Received:' line.</p>
+ 
+ <h2><a id="M8" name="M8">M8. Users are getting multiple copies of
+ messages.</a></h2>
+@@ -3237,6 +3249,8 @@ Hayes mode escape "+++".</p>
+ <h2><a id="X8" name="X8">X8. A spurious ) is being appended to my
+ messages.</a></h2>
+ 
++<p><em>Fetchmail 6.3.5 and newer releases are supposed to fix this.</em></p>
++
+ <p>Due to the problem described in <a href="#S2">S2</a>, the
+ IMAP support in fetchmail cannot follow the IMAP protocol 100&nbsp;%.
+ Most of the time it doesn't matter, but if you combine it with an
+@@ -3279,8 +3293,6 @@ it at the end of the message it forwards
+ on, you'll get a message about actual != expected.</li>
+ </ol>
+ 
+-<p>There is no fix for this.</p>
+-
+ <h2><a id="X9" name="X9">X9. Missing "Content-Transfer-Encoding" header
+ 	with Domino IMAP</a></h2>
+ 
+--- fetchmail-6.3.26.orig/fetchmail.c
++++ fetchmail-6.3.26/fetchmail.c
+@@ -54,6 +54,10 @@
+ #define ENETUNREACH   128       /* Interactive doesn't know this */
+ #endif /* ENETUNREACH */
+ 
++#ifdef SSL_ENABLE
++#include <openssl/ssl.h>	/* for OPENSSL_NO_SSL2 and ..._SSL3 checks */
++#endif
++
+ /* prototypes for internal functions */
+ static int load_params(int, char **, int);
+ static void dump_params (struct runctl *runp, struct query *, flag implicit);
+@@ -138,7 +142,7 @@ static void printcopyright(FILE *fp) {
+ 		   "Copyright (C) 2004 Matthias Andree, Eric S. Raymond,\n"
+ 		   "                   Robert M. Funk, Graham Wilson\n"
+ 		   "Copyright (C) 2005 - 2012 Sunil Shetye\n"
+-		   "Copyright (C) 2005 - 2013 Matthias Andree\n"
++		   "Copyright (C) 2005 - 2015 Matthias Andree\n"
+ 		   ));
+ 	fprintf(fp, GT_("Fetchmail comes with ABSOLUTELY NO WARRANTY. This is free software, and you\n"
+ 		   "are welcome to redistribute it under certain conditions. For details,\n"
+@@ -262,6 +266,9 @@ int main(int argc, char **argv)
+ #endif /* ODMR_ENABLE */
+ #ifdef SSL_ENABLE
+ 	"+SSL"
++#if (HAVE_DECL_SSLV3_CLIENT_METHOD + 0 == 0) || defined(OPENSSL_NO_SSL3)
++	"-SSLv3"
++#endif
+ #endif
+ #ifdef OPIE_ENABLE
+ 	"+OPIE"
+--- fetchmail-6.3.26.orig/fetchmail.h
++++ fetchmail-6.3.26/fetchmail.h
+@@ -771,9 +771,9 @@ int servport(const char *service);
+ int fm_getaddrinfo(const char *node, const char *serv, const struct addrinfo *hints, struct addrinfo **res);
+ void fm_freeaddrinfo(struct addrinfo *ai);
+ 
+-/* prototypes from tls.c */
+-int maybe_tls(struct query *ctl);
+-int must_tls(struct query *ctl);
++/* prototypes from starttls.c */
++int maybe_starttls(struct query *ctl);
++int must_starttls(struct query *ctl);
+ 
+ /* prototype from rfc822valid.c */
+ int rfc822_valid_msgid(const unsigned char *);
+--- fetchmail-6.3.26.orig/fetchmail.man
++++ fetchmail-6.3.26/fetchmail.man
+@@ -412,23 +412,22 @@ from. The folder information is written
+ .B \-\-ssl
+ (Keyword: ssl)
+ .br
+-Causes the connection to the mail server to be encrypted
+-via SSL.  Connect to the server using the specified base protocol over a
+-connection secured by SSL. This option defeats opportunistic starttls
+-negotiation. It is highly recommended to use \-\-sslproto 'SSL3'
+-\-\-sslcertck to validate the certificates presented by the server and
+-defeat the obsolete SSLv2 negotiation. More information is available in
+-the \fIREADME.SSL\fP file that ships with fetchmail.
+-.IP
+-Note that fetchmail may still try to negotiate SSL through starttls even
+-if this option is omitted. You can use the \-\-sslproto option to defeat
+-this behavior or tell fetchmail to negotiate a particular SSL protocol.
++Causes the connection to the mail server to be encrypted via SSL, by
++negotiating SSL directly after connecting (SSL-wrapped mode).  It is
++highly recommended to use \-\-sslcertck to validate the certificates
++presented by the server.  Please see the description of \-\-sslproto
++below!  More information is available in the \fIREADME.SSL\fP file that
++ships with fetchmail.
++.IP
++Note that even if this option is omitted, fetchmail may still negotiate
++SSL in-band for POP3 or IMAP, through the STLS or STARTTLS feature.  You
++can use the \-\-sslproto option to modify that behavior.
+ .IP
+ If no port is specified, the connection is attempted to the well known
+ port of the SSL version of the base protocol.  This is generally a
+ different port than the port used by the base protocol.  For IMAP, this
+ is port 143 for the clear protocol and port 993 for the SSL secured
+-protocol, for POP3, it is port 110 for the clear text and port 995 for
++protocol; for POP3, it is port 110 for the clear text and port 995 for
+ the encrypted variant.
+ .IP
+ If your system lacks the corresponding entries from /etc/services, see
+@@ -470,39 +469,73 @@ cause some complications in daemon mode.
+ .IP
+ Also see \-\-sslcert above.
+ .TP
+-.B \-\-sslproto <name>
+-(Keyword: sslproto)
++.B \-\-sslproto <value>
++(Keyword: sslproto, NOTE: semantic changes since v6.4.0)
+ .br
+-Forces an SSL/TLS protocol. Possible values are \fB''\fP,
+-\&'\fBSSL2\fP' (not supported on all systems),
+-\&'\fBSSL23\fP', (use of these two values is discouraged
+-and should only be used as a last resort) \&'\fBSSL3\fP', and
+-\&'\fBTLS1\fP'.  The default behaviour if this option is unset is: for
+-connections without \-\-ssl, use \&'\fBTLS1\fP' so that fetchmail will
+-opportunistically try STARTTLS negotiation with TLS1. You can configure
+-this option explicitly if the default handshake (TLS1 if \-\-ssl is not
+-used) does not work for your server.
+-.IP
+-Use this option with '\fBTLS1\fP' value to enforce a STARTTLS
+-connection. In this mode, it is highly recommended to also use
+-\-\-sslcertck (see below).  Note that this will then cause fetchmail
+-v6.3.19 to force STARTTLS negotiation even if it is not advertised by
+-the server.
+-.IP
+-To defeat opportunistic TLSv1 negotiation when the server advertises
+-STARTTLS or STLS, and use a cleartext connection use \fB''\fP.  This
+-option, even if the argument is the empty string, will also suppress the
+-diagnostic 'SERVER: opportunistic upgrade to TLS.' message in verbose
+-mode. The default is to try appropriate protocols depending on context.
++This option has a dual use, out of historic fetchmail behaviour. It
++controls both the SSL/TLS protocol version and, if \-\-ssl is not
++specified, the STARTTLS behaviour (upgrading the protocol to an SSL or
++TLS connection in-band). Some other options may however make TLS
++mandatory.
++.PP
++Only if this option and \-\-ssl are both missing for a poll, there will
++be opportunistic TLS for POP3 and IMAP, where fetchmail will attempt to
++upgrade to TLSv1 or newer.
++.PP
++Recognized values for \-\-sslproto are given below. You should normally
++chose one of the auto-negotiating options, i. e. '\fBauto\fP' or one of
++the options ending in a plus (\fB+\fP) character. Note that depending
++on OpenSSL library version and configuration, some options cause
++run-time errors because the requested SSL or TLS versions are not
++supported by the particular installed OpenSSL library.
++.RS
++.IP "\fB''\fP, the empty string"
++Disable STARTTLS. If \-\-ssl is given for the same server, log an error
++and pretend that '\fBauto\fP' had been used instead.
++.IP '\fBauto\fP'
++(default). Since v6.4.0. Require TLS. Auto-negotiate TLSv1 or newer, disable SSLv3 downgrade.
++(fetchmail 6.3.26 and older have auto-negotiated all protocols that
++their OpenSSL library supported, including the broken SSLv3).
++.IP "\&'\fBSSL23\fP'
++see '\fBauto\fP'.
++.IP \&'\fBSSL3\fP'
++Require SSLv3 exactly. SSLv3 is broken, not supported on all systems, avoid it
++if possible.  This will make fetchmail negotiate SSLv3 only, and is the
++only way besides '\fBSSL3+\fP' to have fetchmail 6.4.0 or newer permit SSLv3.
++.IP \&'\fBSSL3+\fP'
++same as '\fBauto\fP', but permit SSLv3 as well. This is the only way
++besides '\fBSSL3\fP' to have fetchmail 6.4.0 or newer permit SSLv3.
++.IP \&'\fBTLS1\fP'
++Require TLSv1. This does not negotiate TLSv1.1 or newer, and is
++discouraged. Replace by TLS1+ unless the latter chokes your server.
++.IP \&'\fBTLS1+\fP'
++Since v6.4.0. See 'fBauto\fP'.
++.IP \&'\fBTLS1.1\fP'
++Since v6.4.0. Require TLS v1.1 exactly.
++.IP \&'\fBTLS1.1+\fP'
++Since v6.4.0. Require TLS. Auto-negotiate TLSv1.1 or newer.
++.IP \&'\fBTLS1.2\fP'
++Since v6.4.0. Require TLS v1.2 exactly.
++.IP '\fBTLS1.2+\fP'
++Since v6.4.0. Require TLS. Auto-negotiate TLSv1.2 or newer.
++.IP "Unrecognized parameters"
++are treated the same as '\fBauto\fP'.
++.RE
++.IP
++NOTE: you should hardly ever need to use anything other than '' (to
++force an unencrypted connection) or 'auto' (to enforce TLS).
+ .TP
+ .B \-\-sslcertck
+ (Keyword: sslcertck)
+ .br
+-Causes fetchmail to strictly check the server certificate against a set of
+-local trusted certificates (see the \fBsslcertfile\fP and \fBsslcertpath\fP
+-options). If the server certificate cannot be obtained or is not signed by one
+-of the trusted ones (directly or indirectly), the SSL connection will fail,
+-regardless of the \fBsslfingerprint\fP option.
++Causes fetchmail to require that SSL/TLS be used and disconnect if it
++can not successfully negotiate SSL or TLS, or if it cannot successfully
++verify and validate the certificate and follow it to a trust anchor (or
++trusted root certificate). The trust anchors are given as a set of local
++trusted certificates (see the \fBsslcertfile\fP and \fBsslcertpath\fP
++options). If the server certificate cannot be obtained or is not signed
++by one of the trusted ones (directly or indirectly), fetchmail will
++disconnect, regardless of the \fBsslfingerprint\fP option.
+ .IP
+ Note that CRL (certificate revocation lists) are only supported in
+ OpenSSL 0.9.7 and newer! Your system clock should also be reasonably
+@@ -1202,31 +1235,33 @@ capability response. Specify a user opti
+ username and the part to the right as the NTLM domain.
+ 
+ .SS Secure Socket Layers (SSL) and Transport Layer Security (TLS)
++.PP All retrieval protocols can use SSL or TLS wrapping for the
++transport. Additionally, POP3 and IMAP retrival can also negotiate
++SSL/TLS by means of STARTTLS (or STLS).
+ .PP
+ Note that fetchmail currently uses the OpenSSL library, which is
+ severely underdocumented, so failures may occur just because the
+ programmers are not aware of OpenSSL's requirement of the day.
+ For instance, since v6.3.16, fetchmail calls
+ OpenSSL_add_all_algorithms(), which is necessary to support certificates
+-using SHA256 on OpenSSL 0.9.8 -- this information is deeply hidden in the
+-documentation and not at all obvious.  Please do not hesitate to report
+-subtle SSL failures.
+-.PP
+-You can access SSL encrypted services by specifying the \-\-ssl option.
+-You can also do this using the "ssl" user option in the .fetchmailrc
+-file. With SSL encryption enabled, queries are initiated over a
+-connection after negotiating an SSL session, and the connection fails if
+-SSL cannot be negotiated.  Some services, such as POP3 and IMAP, have
++using SHA256 on OpenSSL 0.9.8 -- this information is deeply hidden in
++the documentation and not at all obvious.  Please do not hesitate to
++report subtle SSL failures.
++.PP
++You can access SSL encrypted services by specifying the options starting
++with \-\-ssl, such as \-\-ssl, \-\-sslproto, \-\-sslcertck, and others.
++You can also do this using the corresponding user options in the .fetchmailrc
++file.  Some services, such as POP3 and IMAP, have
+ different well known ports defined for the SSL encrypted services.  The
+ encrypted ports will be selected automatically when SSL is enabled and
+-no explicit port is specified. The \-\-sslproto 'SSL3' option should be
+-used to select the SSLv3 protocol (default if unset: v2 or v3).  Also,
+-the \-\-sslcertck command line or sslcertck run control file option
+-should be used to force strict certificate checking - see below.
++no explicit port is specified.   Also, the \-\-sslcertck command line or
++sslcertck run control file option should be used to force strict
++certificate checking - see below.
+ .PP
+ If SSL is not configured, fetchmail will usually opportunistically try to use
+-STARTTLS. STARTTLS can be enforced by using \-\-sslproto "TLS1". TLS
+-connections use the same port as the unencrypted version of the
++STARTTLS. STARTTLS can be enforced by using \-\-sslproto\~auto and
++defeated by using \-\-sslproto\~''.
++TLS connections use the same port as the unencrypted version of the
+ protocol and negotiate TLS via special command. The \-\-sslcertck
+ command line or sslcertck run control file option should be used to
+ force strict certificate checking - see below.
+--- fetchmail-6.3.26.orig/imap.c
++++ fetchmail-6.3.26/imap.c
+@@ -405,6 +405,8 @@ static int imap_getauth(int sock, struct
+ /* apply for connection authorization */
+ {
+     int ok = 0;
++    char *commonname;
++
+     (void)greeting;
+ 
+     /*
+@@ -429,25 +431,21 @@ static int imap_getauth(int sock, struct
+         return(PS_SUCCESS);
+     }
+ 
+-#ifdef SSL_ENABLE
+-    if (maybe_tls(ctl)) {
+-	char *commonname;
+-
+-	commonname = ctl->server.pollname;
+-	if (ctl->server.via)
+-	    commonname = ctl->server.via;
+-	if (ctl->sslcommonname)
+-	    commonname = ctl->sslcommonname;
++    commonname = ctl->server.pollname;
++    if (ctl->server.via)
++	commonname = ctl->server.via;
++    if (ctl->sslcommonname)
++	commonname = ctl->sslcommonname;
+ 
+-	if (strstr(capabilities, "STARTTLS")
+-		|| must_tls(ctl)) /* if TLS is mandatory, ignore capabilities */
++#ifdef SSL_ENABLE
++    if (maybe_starttls(ctl)) {
++	if ((strstr(capabilities, "STARTTLS") && maybe_starttls(ctl))
++		|| must_starttls(ctl)) /* if TLS is mandatory, ignore capabilities */
+ 	{
+-	    /* Use "tls1" rather than ctl->sslproto because tls1 is the only
+-	     * protocol that will work with STARTTLS.  Don't need to worry
+-	     * whether TLS is mandatory or opportunistic unless SSLOpen() fails
+-	     * (see below). */
++	    /* Don't need to worry whether TLS is mandatory or
++	     * opportunistic unless SSLOpen() fails (see below). */
+ 	    if (gen_transact(sock, "STARTTLS") == PS_SUCCESS
+-		    && (set_timeout(mytimeout), SSLOpen(sock, ctl->sslcert, ctl->sslkey, "tls1", ctl->sslcertck,
++		    && (set_timeout(mytimeout), SSLOpen(sock, ctl->sslcert, ctl->sslkey, ctl->sslproto, ctl->sslcertck,
+ 			ctl->sslcertfile, ctl->sslcertpath, ctl->sslfingerprint, commonname,
+ 			ctl->server.pollname, &ctl->remotename)) != -1)
+ 	    {
+@@ -470,7 +468,7 @@ static int imap_getauth(int sock, struct
+ 		{
+ 		    report(stdout, GT_("%s: upgrade to TLS succeeded.\n"), commonname);
+ 		}
+-	    } else if (must_tls(ctl)) {
++	    } else if (must_starttls(ctl)) {
+ 		/* Config required TLS but we couldn't guarantee it, so we must
+ 		 * stop. */
+ 		set_timeout(0);
+@@ -492,6 +490,10 @@ static int imap_getauth(int sock, struct
+ 		/* Usable.  Proceed with authenticating insecurely. */
+ 	    }
+ 	}
++    } else {
++	if (strstr(capabilities, "STARTTLS") && outlevel >= O_VERBOSE) {
++	    report(stdout, GT_("%s: WARNING: server offered STARTTLS but sslproto '' given.\n"), commonname);
++	}
+     }
+ #endif /* SSL_ENABLE */
+ 
+--- fetchmail-6.3.26.orig/po/Makevars
++++ fetchmail-6.3.26/po/Makevars
+@@ -46,3 +46,15 @@ MSGID_BUGS_ADDRESS = fetchmail-devel@lis
+ # This is the list of locale categories, beyond LC_MESSAGES, for which the
+ # message catalogs shall be used.  It is usually empty.
+ EXTRA_LOCALE_CATEGORIES =
++
++# This tells whether the $(DOMAIN).pot file contains messages with an 'msgctxt'
++# context.  Possible values are "yes" and "no".  Set this to yes if the
++# package uses functions taking also a message context, like pgettext(), or
++# if in $(XGETTEXT_OPTIONS) you define keywords with a context argument.
++USE_MSGCTXT = no
++
++# These options get passed to msgmerge.
++# Useful options are in particular:
++#   --previous            to keep previous msgids of translated messages,
++#   --quiet               to reduce the verbosity.
++MSGMERGE_OPTIONS =
+--- fetchmail-6.3.26.orig/pop3.c
++++ fetchmail-6.3.26/pop3.c
+@@ -281,6 +281,7 @@ static int pop3_getauth(int sock, struct
+ #endif /* OPIE_ENABLE */
+ #ifdef SSL_ENABLE
+     flag connection_may_have_tls_errors = FALSE;
++    char *commonname;
+ #endif /* SSL_ENABLE */
+ 
+     done_capa = FALSE;
+@@ -393,7 +394,7 @@ static int pop3_getauth(int sock, struct
+ 		(ctl->server.authenticate == A_KERBEROS_V5) ||
+ 		(ctl->server.authenticate == A_OTP) ||
+ 		(ctl->server.authenticate == A_CRAM_MD5) ||
+-		maybe_tls(ctl))
++		maybe_starttls(ctl))
+ 	{
+ 	    if ((ok = capa_probe(sock)) != PS_SUCCESS)
+ 		/* we are in STAGE_GETAUTH => failure is PS_AUTHFAIL! */
+@@ -406,12 +407,12 @@ static int pop3_getauth(int sock, struct
+ 		    (ok == PS_SOCKET && !ctl->wehaveauthed))
+ 		{
+ #ifdef SSL_ENABLE
+-		    if (must_tls(ctl)) {
++		    if (must_starttls(ctl)) {
+ 			/* fail with mandatory STLS without repoll */
+ 			report(stderr, GT_("TLS is mandatory for this session, but server refused CAPA command.\n"));
+ 			report(stderr, GT_("The CAPA command is however necessary for TLS.\n"));
+ 			return ok;
+-		    } else if (maybe_tls(ctl)) {
++		    } else if (maybe_starttls(ctl)) {
+ 			/* defeat opportunistic STLS */
+ 			xfree(ctl->sslproto);
+ 			ctl->sslproto = xstrdup("");
+@@ -431,24 +432,19 @@ static int pop3_getauth(int sock, struct
+ 	}
+ 
+ #ifdef SSL_ENABLE
+-	if (maybe_tls(ctl)) {
+-	    char *commonname;
++	commonname = ctl->server.pollname;
++	if (ctl->server.via)
++	    commonname = ctl->server.via;
++	if (ctl->sslcommonname)
++	    commonname = ctl->sslcommonname;
+ 
+-	    commonname = ctl->server.pollname;
+-	    if (ctl->server.via)
+-		commonname = ctl->server.via;
+-	    if (ctl->sslcommonname)
+-		commonname = ctl->sslcommonname;
+-
+-	   if (has_stls
+-		   || must_tls(ctl)) /* if TLS is mandatory, ignore capabilities */
++	if (maybe_starttls(ctl)) {
++	   if (has_stls || must_starttls(ctl)) /* if TLS is mandatory, ignore capabilities */
+ 	   {
+-	       /* Use "tls1" rather than ctl->sslproto because tls1 is the only
+-		* protocol that will work with STARTTLS.  Don't need to worry
+-		* whether TLS is mandatory or opportunistic unless SSLOpen() fails
+-		* (see below). */
++	       /* Don't need to worry whether TLS is mandatory or
++		* opportunistic unless SSLOpen() fails (see below). */
+ 	       if (gen_transact(sock, "STLS") == PS_SUCCESS
+-		       && (set_timeout(mytimeout), SSLOpen(sock, ctl->sslcert, ctl->sslkey, "tls1", ctl->sslcertck,
++		       && (set_timeout(mytimeout), SSLOpen(sock, ctl->sslcert, ctl->sslkey, ctl->sslproto, ctl->sslcertck,
+ 			   ctl->sslcertfile, ctl->sslcertpath, ctl->sslfingerprint, commonname,
+ 			   ctl->server.pollname, &ctl->remotename)) != -1)
+ 	       {
+@@ -475,7 +471,7 @@ static int pop3_getauth(int sock, struct
+ 		   {
+ 		       report(stdout, GT_("%s: upgrade to TLS succeeded.\n"), commonname);
+ 		   }
+-	       } else if (must_tls(ctl)) {
++	       } else if (must_starttls(ctl)) {
+ 		   /* Config required TLS but we couldn't guarantee it, so we must
+ 		    * stop. */
+ 		   set_timeout(0);
+@@ -495,7 +491,11 @@ static int pop3_getauth(int sock, struct
+ 		   }
+ 	       }
+ 	   }
+-	} /* maybe_tls() */
++	} else { /* maybe_starttls() */
++	    if (has_stls && outlevel >= O_VERBOSE) {
++		report(stdout, GT_("%s: WARNING: server offered STLS, but sslproto '' given.\n"), commonname);
++	    }
++	} /* maybe_starttls() */
+ #endif /* SSL_ENABLE */
+ 
+ 	/*
+--- fetchmail-6.3.26.orig/socket.c
++++ fetchmail-6.3.26/socket.c
+@@ -876,7 +876,9 @@ int SSLOpen(int sock, char *mycert, char
+ {
+         struct stat randstat;
+         int i;
++	int avoid_ssl_versions = SSL_OP_NO_SSLv2 | SSL_OP_NO_SSLv3;
+ 	long sslopts = SSL_OP_ALL;
++	int ssle_connect = 0;
+ 
+ 	SSL_load_error_strings();
+ 	SSL_library_init();
+@@ -906,25 +908,57 @@ int SSLOpen(int sock, char *mycert, char
+ 	/* Make sure a connection referring to an older context is not left */
+ 	_ssl_context[sock] = NULL;
+ 	if(myproto) {
+-		if(!strcasecmp("ssl2",myproto)) {
+-#if HAVE_DECL_SSLV2_CLIENT_METHOD + 0 > 0
+-			_ctx[sock] = SSL_CTX_new(SSLv2_client_method());
++		if(!strcasecmp("ssl3",myproto)) {
++#if (HAVE_DECL_SSLV3_CLIENT_METHOD > 0) && (0 == OPENSSL_NO_SSL3 + 0)
++			_ctx[sock] = SSL_CTX_new(SSLv3_client_method());
++			avoid_ssl_versions &= ~SSL_OP_NO_SSLv3;
+ #else
+-			report(stderr, GT_("Your operating system does not support SSLv2.\n"));
++			report(stderr, GT_("Your OpenSSL version does not support SSLv3.\n"));
+ 			return -1;
+ #endif
+-		} else if(!strcasecmp("ssl3",myproto)) {
+-			_ctx[sock] = SSL_CTX_new(SSLv3_client_method());
++		} else if(!strcasecmp("ssl3+",myproto)) {
++			avoid_ssl_versions &= ~SSL_OP_NO_SSLv3;
++			myproto = NULL;
+ 		} else if(!strcasecmp("tls1",myproto)) {
+ 			_ctx[sock] = SSL_CTX_new(TLSv1_client_method());
+-		} else if (!strcasecmp("ssl23",myproto)) {
++		} else if(!strcasecmp("tls1+",myproto)) {
++			myproto = NULL;
++#if defined(TLS1_1_VERSION) && TLS_MAX_VERSION >= TLS1_1_VERSION
++		} else if(!strcasecmp("tls1.1",myproto)) {
++			_ctx[sock] = SSL_CTX_new(TLSv1_1_client_method());
++		} else if(!strcasecmp("tls1.1+",myproto)) {
++			myproto = NULL;
++			avoid_ssl_versions |= SSL_OP_NO_TLSv1;
++#else
++		} else if(!strcasecmp("tls1.1",myproto) || !strcasecmp("tls1.1+", myproto)) {
++			report(stderr, GT_("Your OpenSSL version does not support TLS v1.1.\n"));
++			return -1;
++#endif
++#if defined(TLS1_2_VERSION) && TLS_MAX_VERSION >= TLS1_2_VERSION
++		} else if(!strcasecmp("tls1.2",myproto)) {
++			_ctx[sock] = SSL_CTX_new(TLSv1_2_client_method());
++		} else if(!strcasecmp("tls1.2+",myproto)) {
++			myproto = NULL;
++			avoid_ssl_versions |= SSL_OP_NO_TLSv1;
++			avoid_ssl_versions |= SSL_OP_NO_TLSv1_1;
++#else
++		} else if(!strcasecmp("tls1.2",myproto) || !strcasecmp("tls1.2+", myproto)) {
++			report(stderr, GT_("Your OpenSSL version does not support TLS v1.2.\n"));
++			return -1;
++#endif
++		} else if (!strcasecmp("ssl23",myproto) || 0 == strcasecmp("auto",myproto)) {
+ 			myproto = NULL;
+ 		} else {
+-			report(stderr,GT_("Invalid SSL protocol '%s' specified, using default (SSLv23).\n"), myproto);
++			report(stderr,GT_("Invalid SSL protocol '%s' specified, using default autoselect (SSL23).\n"), myproto);
+ 			myproto = NULL;
+ 		}
+ 	}
+-	if(!myproto) {
++	// do not combine into an else { } as myproto may be nulled
++	// above!
++	if (!myproto) {
++		// SSLv23 is a misnomer and will in fact use the best
++		// available protocol, subject to SSL_OP_NO*
++		// constraints.
+ 		_ctx[sock] = SSL_CTX_new(SSLv23_client_method());
+ 	}
+ 	if(_ctx[sock] == NULL) {
+@@ -938,7 +972,7 @@ int SSLOpen(int sock, char *mycert, char
+ 		sslopts &= ~ SSL_OP_DONT_INSERT_EMPTY_FRAGMENTS;
+ 	}
+ 
+-	SSL_CTX_set_options(_ctx[sock], sslopts);
++	SSL_CTX_set_options(_ctx[sock], sslopts | avoid_ssl_versions);
+ 
+ 	if (certck) {
+ 		SSL_CTX_set_verify(_ctx[sock], SSL_VERIFY_PEER, SSL_ck_verify_callback);
+@@ -1008,8 +1042,18 @@ int SSLOpen(int sock, char *mycert, char
+ 	}
+ 
+ 	if (SSL_set_fd(_ssl_context[sock], sock) == 0 
+-	    || SSL_connect(_ssl_context[sock]) < 1) {
++	    || (ssle_connect = SSL_connect(_ssl_context[sock])) < 1) {
++		int e = errno;
++		unsigned long ssle_err_from_queue = ERR_peek_error();
++		unsigned long ssle_err_from_get_error = SSL_get_error(_ssl_context[sock], ssle_connect);
+ 		ERR_print_errors_fp(stderr);
++		if (SSL_ERROR_SYSCALL == ssle_err_from_get_error && 0 == ssle_err_from_queue) {
++		    if (0 == ssle_connect) {
++			report(stderr, GT_("Server shut down connection prematurely during SSL_connect().\n"));
++		    } else if (ssle_connect < 0) {
++			report(stderr, GT_("System error during SSL_connect(): %s\n"), strerror(e));
++		    }
++		}
+ 		SSL_free( _ssl_context[sock] );
+ 		_ssl_context[sock] = NULL;
+ 		SSL_CTX_free(_ctx[sock]);
+@@ -1017,6 +1061,24 @@ int SSLOpen(int sock, char *mycert, char
+ 		return(-1);
+ 	}
+ 
++	if (outlevel >= O_VERBOSE) {
++	    SSL_CIPHER const *sc;
++	    int bitsmax, bitsused;
++
++	    const char *ver;
++
++	    ver = SSL_get_version(_ssl_context[sock]);
++
++	    sc = SSL_get_current_cipher(_ssl_context[sock]);
++	    if (!sc) {
++		report (stderr, GT_("Cannot obtain current SSL/TLS cipher - no session established?\n"));
++	    } else {
++		bitsused = SSL_CIPHER_get_bits(sc, &bitsmax);
++		report(stdout, GT_("SSL/TLS: using protocol %s, cipher %s, %d/%d secret/processed bits\n"),
++			ver, SSL_CIPHER_get_name(sc), bitsused, bitsmax);
++	    }
++	}
++
+ 	/* Paranoia: was the callback not called as we expected? */
+ 	if (!_depth0ck) {
+ 		report(stderr, GT_("Certificate/fingerprint verification was somehow skipped!\n"));
+--- /dev/null
++++ fetchmail-6.3.26/starttls.c
+@@ -0,0 +1,37 @@
++/** \file tls.c - collect common TLS functionality 
++ * \author Matthias Andree
++ * \date 2006
++ */
++
++#include "fetchmail.h"
++
++#include <string.h>
++
++#ifdef HAVE_STRINGS_H
++#include <strings.h>
++#endif
++
++/** return true if user allowed opportunistic STARTTLS/STLS */
++int maybe_starttls(struct query *ctl) {
++#ifdef SSL_ENABLE
++         /* opportunistic  or forced TLS */
++    return (!ctl->sslproto || strlen(ctl->sslproto))
++	&& !ctl->use_ssl;
++#else
++    (void)ctl;
++    return 0;
++#endif
++}
++
++/** return true if user requires STARTTLS/STLS, note though that this
++ * code must always use a logical AND with maybe_tls(). */
++int must_starttls(struct query *ctl) {
++#ifdef SSL_ENABLE
++    return maybe_starttls(ctl)
++	&& (ctl->sslfingerprint || ctl->sslcertck
++		|| (ctl->sslproto && !strcasecmp(ctl->sslproto, "tls1")));
++#else
++    (void)ctl;
++    return 0;
++#endif
++}
diff --git a/meta-openembedded/meta-networking/recipes-support/fetchmail/fetchmail_6.3.26.bb b/meta-openembedded/meta-networking/recipes-support/fetchmail/fetchmail_6.3.26.bb
index 1d78288..5af5d0d 100644
--- a/meta-openembedded/meta-networking/recipes-support/fetchmail/fetchmail_6.3.26.bb
+++ b/meta-openembedded/meta-networking/recipes-support/fetchmail/fetchmail_6.3.26.bb
@@ -7,7 +7,9 @@
 
 DEPENDS = "openssl"
 
-SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BPN}-${PV}.tar.xz"
+SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BPN}-${PV}.tar.xz \
+           file://02_remove_SSLv3.patch \
+           "
 SRC_URI[md5sum] = "61b66faad044afa26e142bb1791aa2b3"
 SRC_URI[sha256sum] = "79b4c54cdbaf02c1a9a691d9948fcb1a77a1591a813e904283a8b614b757e850"
 
diff --git a/meta-openembedded/meta-networking/recipes-support/geoip/geoip-perl_1.50.bb b/meta-openembedded/meta-networking/recipes-support/geoip/geoip-perl_1.50.bb
deleted file mode 100644
index 95147bd..0000000
--- a/meta-openembedded/meta-networking/recipes-support/geoip/geoip-perl_1.50.bb
+++ /dev/null
@@ -1,35 +0,0 @@
-#
-# Copyright (C) 2014, 2015 Wind River Systems, Inc.
-# Released under the MIT license (see COPYING.MIT for the terms)
-#
-SUMMARY = "GeoIP perl API library to access location database"
-DESCRIPTION = "perl library for country/city/organization to IP address or hostname mapping"
-HOMEPAGE = "http://www.maxmind.com/app/ip-location"
-SECTION = "libdevel"
-LICENSE = "Artistic-1.0 | GPL-1.0+"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=b7a36f55e8ba62aadd74e4f0886a405e"
-
-S = "${WORKDIR}/git"
-SRCREV = "47f7d49bd15cfc2e5f8c0f5c4068dc8bb0e10e96"
-SRC_URI = "git://github.com/maxmind/geoip-api-perl.git;protocol=https; \
-    file://run-ptest \
-"
-
-DEPENDS += "geoip"
-
-inherit cpan ptest
-
-EXTRA_CPANFLAGS = "LIBS='-L${STAGING_LIBDIR}' INC='-I${STAGING_INCDIR}'"
-
-
-# perl scripts and some special small data files
-#
-do_install_ptest () {
-    install -d -m 0755 ${D}${PTEST_PATH}/t/data
-
-    install ${S}/t/*.t* ${D}${PTEST_PATH}/t
-    install ${S}/t/data/* ${D}${PTEST_PATH}/t/data
-}
-
-FILES_${PN}-dbg += "${libdir}/perl/vendor_perl/*/auto/Geo/IP/.debug"
-
diff --git a/meta-openembedded/meta-networking/recipes-support/geoip/geoip-perl_1.51.bb b/meta-openembedded/meta-networking/recipes-support/geoip/geoip-perl_1.51.bb
new file mode 100644
index 0000000..ed5c3a9
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/geoip/geoip-perl_1.51.bb
@@ -0,0 +1,35 @@
+#
+# Copyright (C) 2014, 2015 Wind River Systems, Inc.
+# Released under the MIT license (see COPYING.MIT for the terms)
+#
+SUMMARY = "GeoIP perl API library to access location database"
+DESCRIPTION = "perl library for country/city/organization to IP address or hostname mapping"
+HOMEPAGE = "http://www.maxmind.com/app/ip-location"
+SECTION = "libdevel"
+LICENSE = "Artistic-1.0 | GPL-1.0+"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=e4f3ea6e9b28af88dc0321190a1f8250"
+
+S = "${WORKDIR}/git"
+SRCREV = "4cdfdc38eca237c19c22a8b90490446ce6d970fa"
+SRC_URI = "git://github.com/maxmind/geoip-api-perl.git;protocol=https; \
+    file://run-ptest \
+"
+
+DEPENDS += "geoip"
+
+inherit cpan ptest
+
+EXTRA_CPANFLAGS = "LIBS='-L${STAGING_LIBDIR}' INC='-I${STAGING_INCDIR}'"
+
+
+# perl scripts and some special small data files
+#
+do_install_ptest () {
+    install -d -m 0755 ${D}${PTEST_PATH}/t/data
+
+    install ${S}/t/*.t* ${D}${PTEST_PATH}/t
+    install ${S}/t/data/* ${D}${PTEST_PATH}/t/data
+}
+
+FILES_${PN}-dbg += "${libdir}/perl/vendor_perl/*/auto/Geo/IP/.debug"
+
diff --git a/meta-openembedded/meta-networking/recipes-support/geoip/geoip_1.6.11.bb b/meta-openembedded/meta-networking/recipes-support/geoip/geoip_1.6.11.bb
deleted file mode 100644
index 3527d0c..0000000
--- a/meta-openembedded/meta-networking/recipes-support/geoip/geoip_1.6.11.bb
+++ /dev/null
@@ -1,90 +0,0 @@
-SUMMARY = "C library for country/city/organization to IP address or hostname mapping"
-DESCRIPTION = "GeoIP is a C library that enables the user to find the country that any IP \
-address or hostname originates from. It uses a file based database that is \
-accurate as of March 2003. This database simply contains IP blocks as keys, and \
-countries as values. This database should be more complete and accurate than \
-using reverse DNS lookups."
-
-HOMEPAGE = "http://dev.maxmind.com/geoip/"
-SECTION = "libdevel"
-
-SRC_URI = "git://github.com/maxmind/geoip-api-c.git \
-           http://geolite.maxmind.com/download/geoip/database/GeoLiteCountry/GeoIP.dat.gz;apply=no;name=GeoIP-dat \
-           http://geolite.maxmind.com/download/geoip/database/GeoIPv6.dat.gz;apply=no;name=GeoIPv6-dat \
-           http://geolite.maxmind.com/download/geoip/database/GeoLiteCity.dat.gz;apply=no;name=GeoLiteCity-dat \
-           http://geolite.maxmind.com/download/geoip/database/GeoLiteCityv6-beta/GeoLiteCityv6.dat.gz;apply=no;name=GeoLiteCityv6-dat \
-           file://run-ptest \
-"
-SRCREV = "3169a8a88808c8df862e0b0355f99c738cce9f7e"
-
-SRC_URI[GeoIP-dat.md5sum] = "37c84ead332dda0362a5ac7b049b72d4"
-SRC_URI[GeoIP-dat.sha256sum] = "79ff1099e96c2dc1c2539c9a18aaa13a9afd085cae477df60d95f1644d42bc07"
-
-SRC_URI[GeoIPv6-dat.md5sum] = "e75b84a4044e81d6d4484e33816bc762"
-SRC_URI[GeoIPv6-dat.sha256sum] = "a009b0f21968d2868e6dd19d14f3c3b8cd60ae84a4bfc2970df34d771a04811e"
-
-SRC_URI[GeoLiteCity-dat.md5sum] = "4b6588d0bfe1af22e267ac90aa97f769"
-SRC_URI[GeoLiteCity-dat.sha256sum] = "8a6467033a528f68b1a97de24d9d0ce86c8e8e83683820e16e433ddbd3f712f7"
-
-SRC_URI[GeoLiteCityv6-dat.md5sum] = "ad0cb42518af7f752499425dca0952bb"
-SRC_URI[GeoLiteCityv6-dat.sha256sum] = "eda67f4204ba9fa5204a53cdb629167cca9394c712f5378bc723a8c29c0b440f"
-
-LICENSE = "LGPL-2.1"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=243b725d71bb5df4a1e5920b344b86ad \
-                    file://LICENSE;md5=0388276749a542b0d611601fa7c1dcc8 "
-
-S = "${WORKDIR}/git"
-
-inherit autotools
-
-EXTRA_OECONF = "--disable-static               \
-                --disable-dependency-tracking  "
-
-do_install() {
-    make DESTDIR=${D} install
-    install -d ${D}/${datadir}/GeoIP
-    install ${WORKDIR}/GeoIP.dat ${D}/${datadir}/GeoIP/
-    install ${WORKDIR}/GeoIPv6.dat ${D}/${datadir}/GeoIP/
-    install ${WORKDIR}/GeoLiteCity.dat ${D}/${datadir}/GeoIP/
-    install ${WORKDIR}/GeoLiteCityv6.dat ${D}/${datadir}/GeoIP/
-    ln -s GeoLiteCity.dat ${D}${datadir}/GeoIP/GeoIPCity.dat
-}
-
-PACKAGES =+ "${PN}-database"
-FILES_${PN}-database = ""
-FILES_${PN}-database += "${datadir}/GeoIP/*"
-
-# We cannot do much looking up without databases.
-#
-RDEPENDS_${PN} += "${PN}-database"
-
-inherit ptest
-
-do_configure_ptest() {
-    sed -i -e "s/noinst_PROGRAMS = /test_PROGRAMS = /g" \
-        -e 's:SRCDIR=\\"$(top_srcdir)\\":SRCDIR=\\"$(testdir)\\":' \
-        ${S}/test/Makefile.am
-
-    if ! grep "^testdir = " ${S}/test/Makefile.am ; then
-        sed -e '/EXTRA_PROGRAMS = /itestdir = ${PTEST_PATH}/tests' \
-            -i ${S}/test/Makefile.am
-    fi
-
-    sed -i -e "s:/usr/local/share:/usr/share:g" \
-        ${S}/test/benchmark.c
-
-    sed -i -e 's:"../data/:"/usr/share/GeoIP/:g' \
-        ${S}/test/test-geoip-city.c \
-        ${S}/test/test-geoip-isp.c \
-        ${S}/test/test-geoip-asnum.c \
-        ${S}/test/test-geoip-netspeed.c \
-        ${S}/test/test-geoip-org.c \
-        ${S}/test/test-geoip-region.c
-}
-
-
-do_install_ptest() {
-    oe_runmake -C test DESTDIR=${D}  install-testPROGRAMS
-    install ${S}/test/*.txt ${D}${PTEST_PATH}/tests
-}
diff --git a/meta-openembedded/meta-networking/recipes-support/geoip/geoip_1.6.12.bb b/meta-openembedded/meta-networking/recipes-support/geoip/geoip_1.6.12.bb
new file mode 100644
index 0000000..4271c2e
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/geoip/geoip_1.6.12.bb
@@ -0,0 +1,92 @@
+SUMMARY = "C library for country/city/organization to IP address or hostname mapping"
+DESCRIPTION = "GeoIP is a C library that enables the user to find the country that any IP \
+address or hostname originates from. It uses a file based database that is \
+accurate as of March 2003. This database simply contains IP blocks as keys, and \
+countries as values. This database should be more complete and accurate than \
+using reverse DNS lookups."
+
+HOMEPAGE = "http://dev.maxmind.com/geoip/"
+SECTION = "libdevel"
+
+GEOIP_DATABASE_VERSION = "20181205"
+
+SRC_URI = "git://github.com/maxmind/geoip-api-c.git \
+           http://sources.openembedded.org/GeoIP.dat.${GEOIP_DATABASE_VERSION}.gz;apply=no;name=GeoIP-dat; \
+           http://sources.openembedded.org/GeoIPv6.dat.${GEOIP_DATABASE_VERSION}.gz;apply=no;name=GeoIPv6-dat; \
+           http://sources.openembedded.org/GeoLiteCity.dat.${GEOIP_DATABASE_VERSION}.gz;apply=no;name=GeoLiteCity-dat; \
+           http://sources.openembedded.org/GeoLiteCityv6.dat.${GEOIP_DATABASE_VERSION}.gz;apply=no;name=GeoLiteCityv6-dat; \
+           file://run-ptest \
+"
+SRCREV = "4b526e7331ca1d692b74a0509ddcc725622ed31a"
+
+SRC_URI[GeoIP-dat.md5sum] = "d538e57ad9268fdc7955c6cf9a37c4a9"
+SRC_URI[GeoIP-dat.sha256sum] = "b9c05eb8bfcf90a6ddfdc6815caf40a8db2710f0ce3dd48fbd6c24d485ae0449"
+
+SRC_URI[GeoIPv6-dat.md5sum] = "52d6aa0aac1adbfa5eb7fa4742197c11"
+SRC_URI[GeoIPv6.sha256sum] = "416ac92fcc35a21d5efbb32e5c88e609c37aec1aa1af6247d088b8da1af6e9bf"
+
+SRC_URI[GeoLiteCity-dat.md5sum] = "d700c137232f8e077ac8db8577f699d9"
+SRC_URI[GeoLiteCity-dat.sha256sum] = "90db2e52195e3d1bcdb2c2789209006d09de5c742812dbd9a1b36c12675ec4cd"
+
+SRC_URI[GeoLiteCityv6-dat.md5sum] = "6734ccdc644fc0ba76eb276dce73d005"
+SRC_URI[GeoLiteCityv6-dat.sha256sum] = "c95a9d2643b7f53d7abeed2114388870e13fbbad4653f450a49efa7e4b86aca4"
+
+LICENSE = "LGPL-2.1"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=243b725d71bb5df4a1e5920b344b86ad \
+                    file://LICENSE;md5=0388276749a542b0d611601fa7c1dcc8 "
+
+S = "${WORKDIR}/git"
+
+inherit autotools
+
+EXTRA_OECONF = "--disable-static               \
+                --disable-dependency-tracking  "
+
+do_install() {
+    make DESTDIR=${D} install
+    install -d ${D}/${datadir}/GeoIP
+    install ${WORKDIR}/GeoIP.dat.${GEOIP_DATABASE_VERSION} ${D}/${datadir}/GeoIP/GeoIP.dat
+    install ${WORKDIR}/GeoIPv6.dat.${GEOIP_DATABASE_VERSION} ${D}/${datadir}/GeoIP/GeoIPv6.dat
+    install ${WORKDIR}/GeoLiteCity.dat.${GEOIP_DATABASE_VERSION} ${D}/${datadir}/GeoIP/GeoLiteCity.dat
+    install ${WORKDIR}/GeoLiteCityv6.dat.${GEOIP_DATABASE_VERSION} ${D}/${datadir}/GeoIP/GeoLiteCityv6.dat
+    ln -s GeoLiteCity.dat ${D}${datadir}/GeoIP/GeoIPCity.dat
+}
+
+PACKAGES =+ "${PN}-database"
+FILES_${PN}-database = ""
+FILES_${PN}-database += "${datadir}/GeoIP/*"
+
+# We cannot do much looking up without databases.
+#
+RDEPENDS_${PN} += "${PN}-database"
+
+inherit ptest
+
+do_configure_ptest() {
+    sed -i -e "s/noinst_PROGRAMS = /test_PROGRAMS = /g" \
+        -e 's:SRCDIR=\\"$(top_srcdir)\\":SRCDIR=\\"$(testdir)\\":' \
+        ${S}/test/Makefile.am
+
+    if ! grep "^testdir = " ${S}/test/Makefile.am ; then
+        sed -e '/EXTRA_PROGRAMS = /itestdir = ${PTEST_PATH}/tests' \
+            -i ${S}/test/Makefile.am
+    fi
+
+    sed -i -e "s:/usr/local/share:/usr/share:g" \
+        ${S}/test/benchmark.c
+
+    sed -i -e 's:"../data/:"/usr/share/GeoIP/:g' \
+        ${S}/test/test-geoip-city.c \
+        ${S}/test/test-geoip-isp.c \
+        ${S}/test/test-geoip-asnum.c \
+        ${S}/test/test-geoip-netspeed.c \
+        ${S}/test/test-geoip-org.c \
+        ${S}/test/test-geoip-region.c
+}
+
+
+do_install_ptest() {
+    oe_runmake -C test DESTDIR=${D}  install-testPROGRAMS
+    install ${S}/test/*.txt ${D}${PTEST_PATH}/tests
+}
diff --git a/meta-openembedded/meta-networking/recipes-support/htpdate/htpdate/0001-Make-environment-variables-assignments-to-be-weak.patch b/meta-openembedded/meta-networking/recipes-support/htpdate/htpdate/0001-Make-environment-variables-assignments-to-be-weak.patch
new file mode 100644
index 0000000..0ee44c1
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/htpdate/htpdate/0001-Make-environment-variables-assignments-to-be-weak.patch
@@ -0,0 +1,31 @@
+From 04603f52d793f964653e6a985944400fe4fa87ee Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 13 Jun 2018 17:50:20 -0700
+Subject: [PATCH] Make environment variables assignments to be weak
+
+So that OE can override them for cross builds
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ Makefile | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index 1c80c09..884126c 100644
+--- a/Makefile
++++ b/Makefile
+@@ -2,11 +2,11 @@ prefix = $(DESTDIR)/usr
+ bindir = ${prefix}/bin
+ mandir = ${prefix}/share/man
+ 
+-CC = gcc
++CC ?= gcc
+ CFLAGS += -Wall -std=c99 -pedantic -O2
+ 
+-INSTALL = /usr/bin/install -c
+-STRIP = /usr/bin/strip -s
++INSTALL ?= /usr/bin/install -c
++STRIP ?= /usr/bin/strip -s
+ 
+ all: htpdate
+ 
diff --git a/meta-openembedded/meta-networking/recipes-support/htpdate/htpdate/0001-Replace-ntp_adjtime-with-adjtimex.patch b/meta-openembedded/meta-networking/recipes-support/htpdate/htpdate/0001-Replace-ntp_adjtime-with-adjtimex.patch
new file mode 100644
index 0000000..cca8c6c
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/htpdate/htpdate/0001-Replace-ntp_adjtime-with-adjtimex.patch
@@ -0,0 +1,40 @@
+From 75646a2d2df14fdbc4a01e222a779afac94861d1 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 14 Jun 2018 20:11:08 -0700
+Subject: [PATCH] Replace ntp_adjtime with adjtimex.
+
+ntp_adjtime in glibc is an alias to adjtimex and
+musl does not provide ntp_adjtime at all
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ htpdate.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/htpdate.c b/htpdate.c
+index 4171efe..ff0bf8d 100644
+--- a/htpdate.c
++++ b/htpdate.c
+@@ -391,7 +391,7 @@ static int htpdate_adjtimex( double drift ) {
+ 
+ 	/* Read current kernel frequency */
+ 	tmx.modes = 0;
+-	ntp_adjtime(&tmx);
++	adjtimex(&tmx);
+ 
+ 	/* Calculate new frequency */
+ 	freq = (long)(65536e6 * drift);
+@@ -406,7 +406,7 @@ static int htpdate_adjtimex( double drift ) {
+ 
+ 	/* Become root */
+ 	swuid(0);
+-	return( ntp_adjtime(&tmx) );
++	return( adjtimex(&tmx) );
+ 
+ }
+ 
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-networking/recipes-support/htpdate/htpdate_1.2.0.bb b/meta-openembedded/meta-networking/recipes-support/htpdate/htpdate_1.2.0.bb
new file mode 100644
index 0000000..eb67878
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/htpdate/htpdate_1.2.0.bb
@@ -0,0 +1,39 @@
+# Copyright (C) 2018 Khem Raj <raj.khem@gmail.com>
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+SUMMARY = "HTTP based time synchronization tool"
+
+DESCRIPTION = "The  HTTP Time Protocol (HTP) is used to synchronize a computer's time with\
+ web servers as reference time source. This program can be used instead\
+ ntpdate or similar, in networks that has a firewall blocking the NTP port.\
+ Htpdate will synchronize the computer time to Greenwich Mean Time (GMT),\
+ using the timestamps from HTTP headers found in web servers response (the\
+ HEAD method will be used to get the information).\
+ Htpdate works through proxy servers. Accuracy of htpdate will be usually\
+ within 0.5 seconds (better with multiple servers).\
+"
+
+HOMEPAGE = "http://www.vervest.org/htp/"
+
+LICENSE = "GPL-2.0+"
+LIC_FILES_CHKSUM = "file://htpdate.c;beginline=26;endline=30;md5=d7018a4d2c5a6eab392709a05e5e168a"
+
+SRC_URI = "http://www.vervest.org/htp/archive/c/htpdate-${PV}.tar.xz \
+           file://0001-Make-environment-variables-assignments-to-be-weak.patch \
+           file://0001-Replace-ntp_adjtime-with-adjtimex.patch \
+           "
+SRC_URI[md5sum] = "9d5ca69be06edf5d535b52b5f790da4e"
+SRC_URI[sha256sum] = "22b2cf3ec45b0eedecddd3ad2a3d754ac57942ae7dcbac410d254935f0bdbc03"
+
+do_configure () {
+	:
+}
+
+do_compile () {
+	oe_runmake
+}
+
+do_install () {
+	oe_runmake install 'INSTALL=install' 'STRIP=echo' 'DESTDIR=${D}'
+}
+
diff --git a/meta-openembedded/meta-networking/recipes-support/ifenslave/ifenslave_2.9.bb b/meta-openembedded/meta-networking/recipes-support/ifenslave/ifenslave_2.9.bb
index ea28b34..125b59e 100644
--- a/meta-openembedded/meta-networking/recipes-support/ifenslave/ifenslave_2.9.bb
+++ b/meta-openembedded/meta-networking/recipes-support/ifenslave/ifenslave_2.9.bb
@@ -5,9 +5,11 @@
 LICENSE = "GPLv3"
 LIC_FILES_CHKSUM = "file://debian/copyright;md5=acc89812938cf9ad6b1debc37cea0253"
 
+inherit manpages
+MAN_PKG = "${PN}"
 
 SRCREV = "42bfbb9beb924672ca86b86e9679ac3d6b87d992"
-SRC_URI = "git://anonscm.debian.org/collab-maint/ifenslave.git"
+SRC_URI = "git://salsa.debian.org/debian/ifenslave.git;protocol=https"
 
 S = "${WORKDIR}/git"
 
@@ -23,5 +25,3 @@
 
 FILES_${PN}-doc_remove = "${mandir}"
 FILES_${PN} += "${mandir}/man8/ifenslave.8"
-
-RDEPENDS_${PN} = "man"
diff --git a/meta-openembedded/meta-networking/recipes-support/ipsec-tools/ipsec-tools/0001-Disable-gcc8-specific-warnings.patch b/meta-openembedded/meta-networking/recipes-support/ipsec-tools/ipsec-tools/0001-Disable-gcc8-specific-warnings.patch
new file mode 100644
index 0000000..11a9103
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/ipsec-tools/ipsec-tools/0001-Disable-gcc8-specific-warnings.patch
@@ -0,0 +1,86 @@
+From 282d492e4cab7b4d9c7321f4c0c55b615948e280 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 11 May 2018 14:09:17 -0700
+Subject: [PATCH] Disable gcc8 specific warnings
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/libipsec/ipsec_dump_policy.c |  5 +++++
+ src/libipsec/pfkey_dump.c        |  5 +++++
+ src/racoon/isakmp.c              | 11 ++++++++++-
+ 3 files changed, 20 insertions(+), 1 deletion(-)
+
+diff --git a/src/libipsec/ipsec_dump_policy.c b/src/libipsec/ipsec_dump_policy.c
+index 4d0eb77..c3fc842 100644
+--- a/src/libipsec/ipsec_dump_policy.c
++++ b/src/libipsec/ipsec_dump_policy.c
+@@ -275,6 +275,10 @@ ipsec_dump_policy1(policy, delimiter, withports)
+ 	return buf;
+ }
+ 
++#pragma GCC diagnostic push
++#if defined(__GNUC__) && (__GNUC__ >= 8)
++#pragma GCC diagnostic ignored "-Wformat-truncation"
++#endif
+ static char *
+ ipsec_dump_ipsecrequest(buf, len, xisr, bound, withports)
+ 	char *buf;
+@@ -419,3 +423,4 @@ set_address(buf, len, sa, withports)
+ 
+ 	return buf;
+ }
++#pragma GCC diagnostic pop
+diff --git a/src/libipsec/pfkey_dump.c b/src/libipsec/pfkey_dump.c
+index 4627ebc..451e535 100644
+--- a/src/libipsec/pfkey_dump.c
++++ b/src/libipsec/pfkey_dump.c
+@@ -691,6 +691,10 @@ str_ipport(sa)
+ /*
+  * set "/prefix[port number]" to buffer.
+  */
++#pragma GCC diagnostic push
++#if defined(__GNUC__) && (__GNUC__ >= 8)
++#pragma GCC diagnostic ignored "-Wformat-truncation"
++#endif
+ static char *
+ str_prefport(family, pref, port, ulp)
+ 	u_int family, pref, port, ulp;
+@@ -735,6 +739,7 @@ str_prefport(family, pref, port, ulp)
+ 
+ 	return buf;
+ }
++#pragma GCC diagnostic pop
+ 
+ static void
+ str_upperspec(ulp, p1, p2)
+diff --git a/src/racoon/isakmp.c b/src/racoon/isakmp.c
+index 7ff53a3..4addf24 100644
+--- a/src/racoon/isakmp.c
++++ b/src/racoon/isakmp.c
+@@ -3124,7 +3124,12 @@ script_hook(iph1, script)
+ #endif
+ 
+ 	/* local address */
++#pragma GCC diagnostic push
++#if defined(__GNUC__) && (__GNUC__ >= 8)
++#pragma GCC diagnostic ignored "-Wstringop-truncation"
++#endif
+ 	GETNAMEINFO(iph1->local, addrstr, portstr);
++#pragma GCC diagnostic pop
+ 
+ 	if (script_env_append(&envp, &envc, "LOCAL_ADDR", addrstr) != 0) {
+ 		plog(LLV_ERROR, LOCATION, NULL, "Cannot set LOCAL_ADDR\n");
+@@ -3138,8 +3143,12 @@ script_hook(iph1, script)
+ 
+ 	/* Peer address */
+ 	if (iph1->remote != NULL) {
++#pragma GCC diagnostic push
++#if defined(__GNUC__) && (__GNUC__ >= 8)
++#pragma GCC diagnostic ignored "-Wstringop-truncation"
++#endif
+ 		GETNAMEINFO(iph1->remote, addrstr, portstr);
+-
++#pragma GCC diagnostic pop
+ 		if (script_env_append(&envp, &envc, 
+ 		    "REMOTE_ADDR", addrstr) != 0) {
+ 			plog(LLV_ERROR, LOCATION, NULL, 
diff --git a/meta-openembedded/meta-networking/recipes-support/ipsec-tools/ipsec-tools/0001-ipsec-tools-add-openssl-1.1-support.patch b/meta-openembedded/meta-networking/recipes-support/ipsec-tools/ipsec-tools/0001-ipsec-tools-add-openssl-1.1-support.patch
new file mode 100644
index 0000000..2282744
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/ipsec-tools/ipsec-tools/0001-ipsec-tools-add-openssl-1.1-support.patch
@@ -0,0 +1,1086 @@
+From b572350a922187d43dd4629c3b43e19979fae3ef Mon Sep 17 00:00:00 2001
+From: Eneas U de Queiroz <cote2004-github@yahoo.com>
+Date: Tue, 25 Sep 2018 15:30:04 +0800
+Subject: [PATCH] ipsec-tools: add openssl 1.1 support
+
+To: equeiroz@troianet.com.br
+
+This patch updates the calls to openssl 1.1 API, and adds a
+compatibility layer so it compiles with (at least) openssl 1.0.2, I
+haven't tested it with lower versions, but all that's needed is to edit
+the openssl_compat.* files and add the missing functions there--they're
+usually trivial.
+
+Signed-off-by: Eneas U de Queiroz <cote2004-github@yahoo.com>
+
+Upstream-Status: Submitted [https://sourceforge.net/p/ipsec-tools/mailman/message/36327963/]
+https://github.com/openwrt/packages/blob/master/net/ipsec-tools/patches/015-openssl-1.1.patch
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ src/racoon/Makefile.am      |  10 +--
+ src/racoon/algorithm.c      |   6 +-
+ src/racoon/crypto_openssl.c | 197 +++++++++++++++++++++-------------------
+ src/racoon/crypto_openssl.h |   2 +-
+ src/racoon/eaytest.c        |   7 +-
+ src/racoon/ipsec_doi.c      |   2 +-
+ src/racoon/openssl_compat.c | 213 ++++++++++++++++++++++++++++++++++++++++++++
+ src/racoon/openssl_compat.h |  45 ++++++++++
+ src/racoon/plainrsa-gen.c   |  41 +++++----
+ src/racoon/prsa_par.y       |  28 ++++--
+ src/racoon/rsalist.c        |   5 +-
+ 11 files changed, 430 insertions(+), 126 deletions(-)
+ create mode 100644 src/racoon/openssl_compat.c
+ create mode 100644 src/racoon/openssl_compat.h
+
+diff --git a/src/racoon/Makefile.am b/src/racoon/Makefile.am
+index 0662957..272b009 100644
+--- a/src/racoon/Makefile.am
++++ b/src/racoon/Makefile.am
+@@ -4,7 +4,7 @@ sbin_PROGRAMS = racoon racoonctl plainrsa-gen
+ noinst_PROGRAMS = eaytest
+ include_racoon_HEADERS = racoonctl.h var.h vmbuf.h misc.h gcmalloc.h admin.h \
+ 	schedule.h sockmisc.h isakmp_var.h isakmp.h isakmp_xauth.h \
+-	isakmp_cfg.h isakmp_unity.h ipsec_doi.h evt.h
++	isakmp_cfg.h isakmp_unity.h ipsec_doi.h evt.h openssl_compat.h
+ lib_LTLIBRARIES = libracoon.la
+ 
+ adminsockdir=${localstatedir}/racoon
+@@ -32,7 +32,7 @@ racoon_SOURCES = \
+ 	gssapi.c dnssec.c getcertsbyname.c privsep.c \
+ 	pfkey.c admin.c evt.c ipsec_doi.c oakley.c grabmyaddr.c vendorid.c \
+ 	policy.c localconf.c remoteconf.c crypto_openssl.c algorithm.c \
+-	proposal.c sainfo.c strnames.c \
++	openssl_compat.c proposal.c sainfo.c strnames.c \
+ 	plog.c logger.c schedule.c str2val.c \
+ 	safefile.c backupsa.c genlist.c rsalist.c \
+ 	cftoken.l cfparse.y prsa_tok.l prsa_par.y 
+@@ -51,12 +51,12 @@ libracoon_la_SOURCES = kmpstat.c vmbuf.c sockmisc.c misc.c
+ libracoon_la_CFLAGS = -DNOUSE_PRIVSEP $(AM_CFLAGS)
+ 
+ plainrsa_gen_SOURCES = plainrsa-gen.c plog.c \
+-	crypto_openssl.c logger.c 
++	crypto_openssl.c logger.c openssl_compat.c
+ EXTRA_plainrsa_gen_SOURCES = $(MISSING_ALGOS)
+ plainrsa_gen_LDADD = $(CRYPTOBJS) vmbuf.o misc.o
+ plainrsa_gen_DEPENDENCIES = $(CRYPTOBJS) vmbuf.o misc.o
+ 
+-eaytest_SOURCES = eaytest.c plog.c logger.c
++eaytest_SOURCES = eaytest.c plog.c logger.c openssl_compat.c
+ EXTRA_eaytest_SOURCES = missing/crypto/sha2/sha2.c
+ eaytest_LDADD =	crypto_openssl_test.o vmbuf.o str2val.o misc_noplog.o \
+ 	$(CRYPTOBJS)
+@@ -75,7 +75,7 @@ noinst_HEADERS = \
+ 	debugrm.h         isakmp.h      misc.h          sainfo.h \
+ 	dhgroup.h         isakmp_agg.h  netdb_dnssec.h  schedule.h \
+ 	isakmp_cfg.h      isakmp_xauth.h isakmp_unity.h isakmp_frag.h \
+-	throttle.h	  privsep.h \
++	throttle.h	  privsep.h     openssl_compat.h \
+ 	cfparse_proto.h	  cftoken_proto.h genlist.h     rsalist.h \
+ 	missing/crypto/sha2/sha2.h missing/crypto/rijndael/rijndael_local.h \
+ 	missing/crypto/rijndael/rijndael-api-fst.h \
+diff --git a/src/racoon/algorithm.c b/src/racoon/algorithm.c
+index 3fd50f6..66c874b 100644
+--- a/src/racoon/algorithm.c
++++ b/src/racoon/algorithm.c
+@@ -128,7 +128,7 @@ static struct enc_algorithm oakley_encdef[] = {
+ { "aes",	algtype_aes,	OAKLEY_ATTR_ENC_ALG_AES,	16,
+ 		eay_aes_encrypt,	eay_aes_decrypt,
+ 		eay_aes_weakkey,	eay_aes_keylen, },
+-#ifdef HAVE_OPENSSL_CAMELLIA_H
++#if defined(HAVE_OPENSSL_CAMELLIA_H) && ! defined(OPENSSL_NO_CAMELLIA)
+ { "camellia",	algtype_camellia,	OAKLEY_ATTR_ENC_ALG_CAMELLIA,	16,
+ 		eay_camellia_encrypt,	eay_camellia_decrypt,
+ 		eay_camellia_weakkey,	eay_camellia_keylen, },
+@@ -168,7 +168,7 @@ static struct enc_algorithm ipsec_encdef[] = {
+ { "twofish",	algtype_twofish,	IPSECDOI_ESP_TWOFISH,		16,
+ 		NULL,			NULL,
+ 		NULL,			eay_twofish_keylen, },
+-#ifdef HAVE_OPENSSL_IDEA_H
++#if defined(HAVE_OPENSSL_IDEA_H) && ! defined(OPENSSL_NO_IDEA)
+ { "3idea",	algtype_3idea,		IPSECDOI_ESP_3IDEA,		8,
+ 		NULL,			NULL,
+ 		NULL,			NULL, },
+@@ -179,7 +179,7 @@ static struct enc_algorithm ipsec_encdef[] = {
+ { "rc4",	algtype_rc4,		IPSECDOI_ESP_RC4,		8,
+ 		NULL,			NULL,
+ 		NULL,			NULL, },
+-#ifdef HAVE_OPENSSL_CAMELLIA_H
++#if defined(HAVE_OPENSSL_CAMELLIA_H) && ! defined(OPENSSL_NO_CAMELLIA)
+ { "camellia",	algtype_camellia,	IPSECDOI_ESP_CAMELLIA,		16,
+ 		NULL,			NULL,
+ 		NULL,			eay_camellia_keylen, },
+diff --git a/src/racoon/crypto_openssl.c b/src/racoon/crypto_openssl.c
+index 55b076a..8fb358f 100644
+--- a/src/racoon/crypto_openssl.c
++++ b/src/racoon/crypto_openssl.c
+@@ -90,6 +90,7 @@
+ #endif
+ #endif
+ #include "plog.h"
++#include "openssl_compat.h"
+ 
+ #define USE_NEW_DES_API
+ 
+@@ -316,9 +317,12 @@ eay_cmp_asn1dn(n1, n2)
+ 			i = idx+1;
+ 			goto end;
+ 		}
+-		if ((ea->value->length == 1 && ea->value->data[0] == '*') ||
+-		    (eb->value->length == 1 && eb->value->data[0] == '*')) {
+-	    		if (OBJ_cmp(ea->object,eb->object)) {
++		ASN1_STRING *sa = X509_NAME_ENTRY_get_data(ea);
++		ASN1_STRING *sb = X509_NAME_ENTRY_get_data(eb);
++		if ((ASN1_STRING_length(sa) == 1 && ASN1_STRING_get0_data(sa)[0] == '*') ||
++		    (ASN1_STRING_length(sb) == 1 && ASN1_STRING_get0_data(sb)[0] == '*')) {
++	    		if (OBJ_cmp(X509_NAME_ENTRY_get_object(ea),
++				    X509_NAME_ENTRY_get_object(eb))) {
+ 				i = idx+1;
+ 				goto end;
+ 	    		}
+@@ -430,7 +434,7 @@ cb_check_cert_local(ok, ctx)
+ 
+ 	if (!ok) {
+ 		X509_NAME_oneline(
+-				X509_get_subject_name(ctx->current_cert),
++				X509_get_subject_name(X509_STORE_CTX_get_current_cert(ctx)),
+ 				buf,
+ 				256);
+ 		/*
+@@ -438,7 +442,8 @@ cb_check_cert_local(ok, ctx)
+ 		 * ok if they are self signed. But we should still warn
+ 		 * the user.
+  		 */
+-		switch (ctx->error) {
++		int ctx_error = X509_STORE_CTX_get_error(ctx);
++		switch (ctx_error) {
+ 		case X509_V_ERR_CERT_HAS_EXPIRED:
+ 		case X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT:
+ 		case X509_V_ERR_INVALID_CA:
+@@ -453,9 +458,9 @@ cb_check_cert_local(ok, ctx)
+ 		}
+ 		plog(log_tag, LOCATION, NULL,
+ 			"%s(%d) at depth:%d SubjectName:%s\n",
+-			X509_verify_cert_error_string(ctx->error),
+-			ctx->error,
+-			ctx->error_depth,
++			X509_verify_cert_error_string(ctx_error),
++			ctx_error,
++			X509_STORE_CTX_get_error_depth(ctx),
+ 			buf);
+ 	}
+ 	ERR_clear_error();
+@@ -477,10 +482,11 @@ cb_check_cert_remote(ok, ctx)
+ 
+ 	if (!ok) {
+ 		X509_NAME_oneline(
+-				X509_get_subject_name(ctx->current_cert),
++				X509_get_subject_name(X509_STORE_CTX_get_current_cert(ctx)),
+ 				buf,
+ 				256);
+-		switch (ctx->error) {
++		int ctx_error=X509_STORE_CTX_get_error(ctx);
++		switch (ctx_error) {
+ 		case X509_V_ERR_UNABLE_TO_GET_CRL:
+ 			ok = 1;
+ 			log_tag = LLV_WARNING;
+@@ -490,9 +496,9 @@ cb_check_cert_remote(ok, ctx)
+ 		}
+ 		plog(log_tag, LOCATION, NULL,
+ 			"%s(%d) at depth:%d SubjectName:%s\n",
+-			X509_verify_cert_error_string(ctx->error),
+-			ctx->error,
+-			ctx->error_depth,
++			X509_verify_cert_error_string(ctx_error),
++			ctx_error,
++			X509_STORE_CTX_get_error_depth(ctx),
+ 			buf);
+ 	}
+ 	ERR_clear_error();
+@@ -516,14 +522,15 @@ eay_get_x509asn1subjectname(cert)
+ 	if (x509 == NULL)
+ 		goto error;
+ 
++	X509_NAME *subject_name = X509_get_subject_name(x509);
+ 	/* get the length of the name */
+-	len = i2d_X509_NAME(x509->cert_info->subject, NULL);
++	len = i2d_X509_NAME(subject_name, NULL);
+ 	name = vmalloc(len);
+ 	if (!name)
+ 		goto error;
+ 	/* get the name */
+ 	bp = (unsigned char *) name->v;
+-	len = i2d_X509_NAME(x509->cert_info->subject, &bp);
++	len = i2d_X509_NAME(subject_name, &bp);
+ 
+ 	X509_free(x509);
+ 
+@@ -661,15 +668,16 @@ eay_get_x509asn1issuername(cert)
+ 	if (x509 == NULL)
+ 		goto error;
+ 
++	X509_NAME *issuer_name = X509_get_issuer_name(x509);
+ 	/* get the length of the name */
+-	len = i2d_X509_NAME(x509->cert_info->issuer, NULL);
++	len = i2d_X509_NAME(issuer_name, NULL);
+ 	name = vmalloc(len);
+ 	if (name == NULL)
+ 		goto error;
+ 
+ 	/* get the name */
+ 	bp = (unsigned char *) name->v;
+-	len = i2d_X509_NAME(x509->cert_info->issuer, &bp);
++	len = i2d_X509_NAME(issuer_name, &bp);
+ 
+ 	X509_free(x509);
+ 
+@@ -850,7 +858,7 @@ eay_check_x509sign(source, sig, cert)
+ 		return -1;
+ 	}
+ 
+-	res = eay_rsa_verify(source, sig, evp->pkey.rsa);
++	res = eay_rsa_verify(source, sig, EVP_PKEY_get0_RSA(evp));
+ 
+ 	EVP_PKEY_free(evp);
+ 	X509_free(x509);
+@@ -992,7 +1000,7 @@ eay_get_x509sign(src, privkey)
+ 	if (evp == NULL)
+ 		return NULL;
+ 
+-	sig = eay_rsa_sign(src, evp->pkey.rsa);
++	sig = eay_rsa_sign(src, EVP_PKEY_get0_RSA(evp));
+ 
+ 	EVP_PKEY_free(evp);
+ 
+@@ -1079,7 +1087,11 @@ eay_strerror()
+ 	int line, flags;
+ 	unsigned long es;
+ 
++#if OPENSSL_VERSION_NUMBER >= 0x10100000L
++	es = 0; /* even when allowed by OPENSSL_API_COMPAT, it is defined as 0 */
++#else
+ 	es = CRYPTO_thread_id();
++#endif
+ 
+ 	while ((l = ERR_get_error_line_data(&file, &line, &data, &flags)) != 0){
+ 		n = snprintf(ebuf + len, sizeof(ebuf) - len,
+@@ -1100,7 +1112,7 @@ vchar_t *
+ evp_crypt(vchar_t *data, vchar_t *key, vchar_t *iv, const EVP_CIPHER *e, int enc)
+ {
+ 	vchar_t *res;
+-	EVP_CIPHER_CTX ctx;
++	EVP_CIPHER_CTX *ctx;
+ 
+ 	if (!e)
+ 		return NULL;
+@@ -1111,7 +1123,7 @@ evp_crypt(vchar_t *data, vchar_t *key, vchar_t *iv, const EVP_CIPHER *e, int enc
+ 	if ((res = vmalloc(data->l)) == NULL)
+ 		return NULL;
+ 
+-	EVP_CIPHER_CTX_init(&ctx);
++	ctx = EVP_CIPHER_CTX_new();
+ 
+ 	switch(EVP_CIPHER_nid(e)){
+ 	case NID_bf_cbc:
+@@ -1125,54 +1137,41 @@ evp_crypt(vchar_t *data, vchar_t *key, vchar_t *iv, const EVP_CIPHER *e, int enc
+ 		/* XXX: can we do that also for algos with a fixed key size ?
+ 		 */
+ 		/* init context without key/iv
+-         */
+-        if (!EVP_CipherInit(&ctx, e, NULL, NULL, enc))
+-        {
+-            OpenSSL_BUG();
+-            vfree(res);
+-            return NULL;
+-        }
++                 */
++		if (!EVP_CipherInit(ctx, e, NULL, NULL, enc))
++			goto out;
+ 		
+-        /* update key size
+-         */
+-        if (!EVP_CIPHER_CTX_set_key_length(&ctx, key->l))
+-        {
+-            OpenSSL_BUG();
+-            vfree(res);
+-            return NULL;
+-        }
+-
+-        /* finalize context init with desired key size
+-         */
+-        if (!EVP_CipherInit(&ctx, NULL, (u_char *) key->v,
++		/* update key size
++		 */
++		if (!EVP_CIPHER_CTX_set_key_length(ctx, key->l))
++			goto out;
++
++		/* finalize context init with desired key size
++		 */
++		if (!EVP_CipherInit(ctx, NULL, (u_char *) key->v,
+ 							(u_char *) iv->v, enc))
+-        {
+-            OpenSSL_BUG();
+-            vfree(res);
+-            return NULL;
+-		}
++			goto out;
+ 		break;
+ 	default:
+-		if (!EVP_CipherInit(&ctx, e, (u_char *) key->v, 
+-							(u_char *) iv->v, enc)) {
+-			OpenSSL_BUG();
+-			vfree(res);
+-			return NULL;
+-		}
++		if (!EVP_CipherInit(ctx, e, (u_char *) key->v,
++							(u_char *) iv->v, enc))
++            		goto out;
+ 	}
+ 
+ 	/* disable openssl padding */
+-	EVP_CIPHER_CTX_set_padding(&ctx, 0); 
++	EVP_CIPHER_CTX_set_padding(ctx, 0);
+ 	
+-	if (!EVP_Cipher(&ctx, (u_char *) res->v, (u_char *) data->v, data->l)) {
+-		OpenSSL_BUG();
+-		vfree(res);
+-		return NULL;
+-	}
++	if (!EVP_Cipher(ctx, (u_char *) res->v, (u_char *) data->v, data->l))
++		goto out;
+ 
+-	EVP_CIPHER_CTX_cleanup(&ctx);
++	EVP_CIPHER_CTX_free(ctx);
+ 
+ 	return res;
++out:
++	EVP_CIPHER_CTX_free(ctx);
++	OpenSSL_BUG();
++	vfree(res);
++	return NULL;
+ }
+ 
+ int
+@@ -1230,7 +1229,7 @@ eay_des_keylen(len)
+ 	return evp_keylen(len, EVP_des_cbc());
+ }
+ 
+-#ifdef HAVE_OPENSSL_IDEA_H
++#if defined(HAVE_OPENSSL_IDEA_H) && ! defined(OPENSSL_NO_IDEA)
+ /*
+  * IDEA-CBC
+  */
+@@ -1587,7 +1586,7 @@ eay_aes_keylen(len)
+ 	return len;
+ }
+ 
+-#if defined(HAVE_OPENSSL_CAMELLIA_H)
++#if defined(HAVE_OPENSSL_CAMELLIA_H) && ! defined(OPENSSL_NO_CAMELLIA)
+ /*
+  * CAMELLIA-CBC
+  */
+@@ -1680,9 +1679,9 @@ eay_hmac_init(key, md)
+ 	vchar_t *key;
+ 	const EVP_MD *md;
+ {
+-	HMAC_CTX *c = racoon_malloc(sizeof(*c));
++	HMAC_CTX *c = HMAC_CTX_new();
+ 
+-	HMAC_Init(c, key->v, key->l, md);
++	HMAC_Init_ex(c, key->v, key->l, md, NULL);
+ 
+ 	return (caddr_t)c;
+ }
+@@ -1761,8 +1760,7 @@ eay_hmacsha2_512_final(c)
+ 
+ 	HMAC_Final((HMAC_CTX *)c, (unsigned char *) res->v, &l);
+ 	res->l = l;
+-	HMAC_cleanup((HMAC_CTX *)c);
+-	(void)racoon_free(c);
++	HMAC_CTX_free((HMAC_CTX *)c);
+ 
+ 	if (SHA512_DIGEST_LENGTH != res->l) {
+ 		plog(LLV_ERROR, LOCATION, NULL,
+@@ -1811,8 +1809,7 @@ eay_hmacsha2_384_final(c)
+ 
+ 	HMAC_Final((HMAC_CTX *)c, (unsigned char *) res->v, &l);
+ 	res->l = l;
+-	HMAC_cleanup((HMAC_CTX *)c);
+-	(void)racoon_free(c);
++	HMAC_CTX_free((HMAC_CTX *)c);
+ 
+ 	if (SHA384_DIGEST_LENGTH != res->l) {
+ 		plog(LLV_ERROR, LOCATION, NULL,
+@@ -1861,8 +1858,7 @@ eay_hmacsha2_256_final(c)
+ 
+ 	HMAC_Final((HMAC_CTX *)c, (unsigned char *) res->v, &l);
+ 	res->l = l;
+-	HMAC_cleanup((HMAC_CTX *)c);
+-	(void)racoon_free(c);
++	HMAC_CTX_free((HMAC_CTX *)c);
+ 
+ 	if (SHA256_DIGEST_LENGTH != res->l) {
+ 		plog(LLV_ERROR, LOCATION, NULL,
+@@ -1912,8 +1908,7 @@ eay_hmacsha1_final(c)
+ 
+ 	HMAC_Final((HMAC_CTX *)c, (unsigned char *) res->v, &l);
+ 	res->l = l;
+-	HMAC_cleanup((HMAC_CTX *)c);
+-	(void)racoon_free(c);
++	HMAC_CTX_free((HMAC_CTX *)c);
+ 
+ 	if (SHA_DIGEST_LENGTH != res->l) {
+ 		plog(LLV_ERROR, LOCATION, NULL,
+@@ -1962,8 +1957,7 @@ eay_hmacmd5_final(c)
+ 
+ 	HMAC_Final((HMAC_CTX *)c, (unsigned char *) res->v, &l);
+ 	res->l = l;
+-	HMAC_cleanup((HMAC_CTX *)c);
+-	(void)racoon_free(c);
++	HMAC_CTX_free((HMAC_CTX *)c);
+ 
+ 	if (MD5_DIGEST_LENGTH != res->l) {
+ 		plog(LLV_ERROR, LOCATION, NULL,
+@@ -2266,6 +2260,7 @@ eay_dh_generate(prime, g, publen, pub, priv)
+ 	u_int32_t g;
+ {
+ 	BIGNUM *p = NULL;
++	BIGNUM *BNg = NULL;
+ 	DH *dh = NULL;
+ 	int error = -1;
+ 
+@@ -2276,25 +2271,28 @@ eay_dh_generate(prime, g, publen, pub, priv)
+ 
+ 	if ((dh = DH_new()) == NULL)
+ 		goto end;
+-	dh->p = p;
+-	p = NULL;	/* p is now part of dh structure */
+-	dh->g = NULL;
+-	if ((dh->g = BN_new()) == NULL)
++	if ((BNg = BN_new()) == NULL)
+ 		goto end;
+-	if (!BN_set_word(dh->g, g))
++	if (!BN_set_word(BNg, g))
+ 		goto end;
++	if (! DH_set0_pqg(dh, p, NULL, BNg))
++		goto end;
++	BNg = NULL;
++	p = NULL;	/* p is now part of dh structure */
+ 
+ 	if (publen != 0)
+-		dh->length = publen;
++		DH_set_length(dh, publen);
+ 
+ 	/* generate public and private number */
+ 	if (!DH_generate_key(dh))
+ 		goto end;
+ 
+ 	/* copy results to buffers */
+-	if (eay_bn2v(pub, dh->pub_key) < 0)
++	BIGNUM *pub_key, *priv_key;
++	DH_get0_key(dh, (const BIGNUM**) &pub_key, (const BIGNUM**) &priv_key);
++	if (eay_bn2v(pub, pub_key) < 0)
+ 		goto end;
+-	if (eay_bn2v(priv, dh->priv_key) < 0) {
++	if (eay_bn2v(priv, priv_key) < 0) {
+ 		vfree(*pub);
+ 		goto end;
+ 	}
+@@ -2306,6 +2304,8 @@ end:
+ 		DH_free(dh);
+ 	if (p != 0)
+ 		BN_free(p);
++	if (BNg != 0)
++		BN_free(BNg);
+ 	return(error);
+ }
+ 
+@@ -2319,6 +2319,10 @@ eay_dh_compute(prime, g, pub, priv, pub2, key)
+ 	int l;
+ 	unsigned char *v = NULL;
+ 	int error = -1;
++	BIGNUM *p = BN_new();
++	BIGNUM *BNg = BN_new();
++	BIGNUM *pub_key = BN_new();
++	BIGNUM *priv_key = BN_new();
+ 
+ 	/* make public number to compute */
+ 	if (eay_v2bn(&dh_pub, pub2) < 0)
+@@ -2327,19 +2331,21 @@ eay_dh_compute(prime, g, pub, priv, pub2, key)
+ 	/* make DH structure */
+ 	if ((dh = DH_new()) == NULL)
+ 		goto end;
+-	if (eay_v2bn(&dh->p, prime) < 0)
++	if (p == NULL || BNg == NULL || pub_key == NULL || priv_key == NULL)
+ 		goto end;
+-	if (eay_v2bn(&dh->pub_key, pub) < 0)
++
++	if (eay_v2bn(&p, prime) < 0)
+ 		goto end;
+-	if (eay_v2bn(&dh->priv_key, priv) < 0)
++	if (eay_v2bn(&pub_key, pub) < 0)
+ 		goto end;
+-	dh->length = pub2->l * 8;
+-
+-	dh->g = NULL;
+-	if ((dh->g = BN_new()) == NULL)
++	if (eay_v2bn(&priv_key, priv) < 0)
+ 		goto end;
+-	if (!BN_set_word(dh->g, g))
++	if (!BN_set_word(BNg, g))
+ 		goto end;
++	DH_set0_key(dh, pub_key, priv_key);
++	DH_set_length(dh, pub2->l * 8);
++	DH_set0_pqg(dh, p, NULL, BNg);
++	pub_key = priv_key = p = BNg = NULL;
+ 
+ 	if ((v = racoon_calloc(prime->l, sizeof(u_char))) == NULL)
+ 		goto end;
+@@ -2350,6 +2356,14 @@ eay_dh_compute(prime, g, pub, priv, pub2, key)
+ 	error = 0;
+ 
+ end:
++	if (p != NULL)
++		BN_free(p);
++	if (BNg != NULL)
++		BN_free(BNg);
++	if (pub_key != NULL)
++		BN_free(pub_key);
++	if (priv_key != NULL)
++		BN_free(priv_key);
+ 	if (dh_pub != NULL)
+ 		BN_free(dh_pub);
+ 	if (dh != NULL)
+@@ -2400,12 +2414,14 @@ eay_bn2v(var, bn)
+ void
+ eay_init()
+ {
++#if OPENSSL_VERSION_NUMBER < 0x10100000L
+ 	OpenSSL_add_all_algorithms();
+ 	ERR_load_crypto_strings();
+ #ifdef HAVE_OPENSSL_ENGINE_H
+ 	ENGINE_load_builtin_engines();
+ 	ENGINE_register_all_complete();
+ #endif
++#endif
+ }
+ 
+ vchar_t *
+@@ -2504,8 +2520,7 @@ binbuf_pubkey2rsa(vchar_t *binbuf)
+ 		goto out;
+ 	}
+ 	
+-	rsa_pub->n = mod;
+-	rsa_pub->e = exp;
++	RSA_set0_key(rsa_pub, mod, exp, NULL);
+ 
+ out:
+ 	return rsa_pub;
+@@ -2582,5 +2597,5 @@ eay_random()
+ const char *
+ eay_version()
+ {
+-	return SSLeay_version(SSLEAY_VERSION);
++	return OpenSSL_version(OPENSSL_VERSION);
+ }
+diff --git a/src/racoon/crypto_openssl.h b/src/racoon/crypto_openssl.h
+index 66fac73..ee5b765 100644
+--- a/src/racoon/crypto_openssl.h
++++ b/src/racoon/crypto_openssl.h
+@@ -124,7 +124,7 @@ extern vchar_t *eay_aes_decrypt __P((vchar_t *, vchar_t *, vchar_t *));
+ extern int eay_aes_weakkey __P((vchar_t *));
+ extern int eay_aes_keylen __P((int));
+ 
+-#if defined(HAVE_OPENSSL_CAMELLIA_H)
++#if defined(HAVE_OPENSSL_CAMELLIA_H) && ! defined(OPENSSL_NO_CAMELLIA)
+ /* Camellia */
+ extern vchar_t *eay_camellia_encrypt __P((vchar_t *, vchar_t *, vchar_t *));
+ extern vchar_t *eay_camellia_decrypt __P((vchar_t *, vchar_t *, vchar_t *));
+diff --git a/src/racoon/eaytest.c b/src/racoon/eaytest.c
+index d609e4f..d2d20da 100644
+--- a/src/racoon/eaytest.c
++++ b/src/racoon/eaytest.c
+@@ -62,6 +62,7 @@
+ #include "dhgroup.h"
+ #include "crypto_openssl.h"
+ #include "gnuc.h"
++#include "openssl_compat.h"
+ 
+ #include "package_version.h"
+ 
+@@ -103,7 +104,7 @@ rsa_verify_with_pubkey(src, sig, pubkey_txt)
+ 		printf ("PEM_read_PUBKEY(): %s\n", eay_strerror());
+ 		return -1;
+ 	}
+-	error = eay_check_rsasign(src, sig, evp->pkey.rsa);
++	error = eay_check_rsasign(src, sig, EVP_PKEY_get0_RSA(evp));
+ 
+ 	return error;
+ }
+@@ -698,7 +699,7 @@ ciphertest(ac, av)
+ 			  eay_cast_encrypt, eay_cast_decrypt) < 0)
+ 	  return -1;
+ 	
+-#ifdef HAVE_OPENSSL_IDEA_H
++#if defined(HAVE_OPENSSL_IDEA_H) && ! defined(OPENSSL_NO_IDEA)
+ 	if (ciphertest_1 ("IDEA",
+ 			  &data, 8,
+ 			  &key, key.l,
+@@ -715,7 +716,7 @@ ciphertest(ac, av)
+ 			  eay_rc5_encrypt, eay_rc5_decrypt) < 0)
+ 	  return -1;
+ #endif
+-#if defined(HAVE_OPENSSL_CAMELLIA_H)
++#if defined(HAVE_OPENSSL_CAMELLIA_H) && ! defined(OPENSSL_NO_CAMELLIA)
+ 	if (ciphertest_1 ("CAMELLIA",
+ 			  &data, 16,
+ 			  &key, key.l,
+diff --git a/src/racoon/ipsec_doi.c b/src/racoon/ipsec_doi.c
+index 08e4325..7b1604d 100644
+--- a/src/racoon/ipsec_doi.c
++++ b/src/racoon/ipsec_doi.c
+@@ -715,7 +715,7 @@ out:
+ 	/* key length must not be specified on some algorithms */
+ 	if (keylen) {
+ 		if (sa->enctype == OAKLEY_ATTR_ENC_ALG_DES
+-#ifdef HAVE_OPENSSL_IDEA_H
++#if defined(HAVE_OPENSSL_IDEA_H) && ! defined(OPENSSL_NO_IDEA)
+ 		 || sa->enctype == OAKLEY_ATTR_ENC_ALG_IDEA
+ #endif
+ 		 || sa->enctype == OAKLEY_ATTR_ENC_ALG_3DES) {
+diff --git a/src/racoon/openssl_compat.c b/src/racoon/openssl_compat.c
+new file mode 100644
+index 0000000..864b5fb
+--- /dev/null
++++ b/src/racoon/openssl_compat.c
+@@ -0,0 +1,213 @@
++/*
++ * Copyright 2016 The OpenSSL Project Authors. All Rights Reserved.
++ *
++ * Licensed under the OpenSSL license (the "License").  You may not use
++ * this file except in compliance with the License.  You can obtain a copy
++ * in the file LICENSE in the source distribution or at
++ * https://www.openssl.org/source/license.html
++ */
++
++#include "openssl_compat.h"
++
++#if OPENSSL_VERSION_NUMBER < 0x10100000L
++
++#include <string.h>
++
++static void *OPENSSL_zalloc(size_t num)
++{
++    void *ret = OPENSSL_malloc(num);
++
++    if (ret != NULL)
++        memset(ret, 0, num);
++    return ret;
++}
++
++int RSA_set0_key(RSA *r, BIGNUM *n, BIGNUM *e, BIGNUM *d)
++{
++    /* If the fields n and e in r are NULL, the corresponding input
++     * parameters MUST be non-NULL for n and e.  d may be
++     * left NULL (in case only the public key is used).
++     */
++    if ((r->n == NULL && n == NULL)
++        || (r->e == NULL && e == NULL))
++        return 0;
++
++    if (n != NULL) {
++        BN_free(r->n);
++        r->n = n;
++    }
++    if (e != NULL) {
++        BN_free(r->e);
++        r->e = e;
++    }
++    if (d != NULL) {
++        BN_free(r->d);
++        r->d = d;
++    }
++
++    return 1;
++}
++
++int RSA_set0_factors(RSA *r, BIGNUM *p, BIGNUM *q)
++{
++    /* If the fields p and q in r are NULL, the corresponding input
++     * parameters MUST be non-NULL.
++     */
++    if ((r->p == NULL && p == NULL)
++        || (r->q == NULL && q == NULL))
++        return 0;
++
++    if (p != NULL) {
++        BN_free(r->p);
++        r->p = p;
++    }
++    if (q != NULL) {
++        BN_free(r->q);
++        r->q = q;
++    }
++
++    return 1;
++}
++
++int RSA_set0_crt_params(RSA *r, BIGNUM *dmp1, BIGNUM *dmq1, BIGNUM *iqmp)
++{
++    /* If the fields dmp1, dmq1 and iqmp in r are NULL, the corresponding input
++     * parameters MUST be non-NULL.
++     */
++    if ((r->dmp1 == NULL && dmp1 == NULL)
++        || (r->dmq1 == NULL && dmq1 == NULL)
++        || (r->iqmp == NULL && iqmp == NULL))
++        return 0;
++
++    if (dmp1 != NULL) {
++        BN_free(r->dmp1);
++        r->dmp1 = dmp1;
++    }
++    if (dmq1 != NULL) {
++        BN_free(r->dmq1);
++        r->dmq1 = dmq1;
++    }
++    if (iqmp != NULL) {
++        BN_free(r->iqmp);
++        r->iqmp = iqmp;
++    }
++
++    return 1;
++}
++
++void RSA_get0_key(const RSA *r,
++                  const BIGNUM **n, const BIGNUM **e, const BIGNUM **d)
++{
++    if (n != NULL)
++        *n = r->n;
++    if (e != NULL)
++        *e = r->e;
++    if (d != NULL)
++        *d = r->d;
++}
++
++void RSA_get0_factors(const RSA *r, const BIGNUM **p, const BIGNUM **q)
++{
++    if (p != NULL)
++        *p = r->p;
++    if (q != NULL)
++        *q = r->q;
++}
++
++void RSA_get0_crt_params(const RSA *r,
++                         const BIGNUM **dmp1, const BIGNUM **dmq1,
++                         const BIGNUM **iqmp)
++{
++    if (dmp1 != NULL)
++        *dmp1 = r->dmp1;
++    if (dmq1 != NULL)
++        *dmq1 = r->dmq1;
++    if (iqmp != NULL)
++        *iqmp = r->iqmp;
++}
++
++int DH_set0_pqg(DH *dh, BIGNUM *p, BIGNUM *q, BIGNUM *g)
++{
++    /* If the fields p and g in d are NULL, the corresponding input
++     * parameters MUST be non-NULL.  q may remain NULL.
++     */
++    if ((dh->p == NULL && p == NULL)
++        || (dh->g == NULL && g == NULL))
++        return 0;
++
++    if (p != NULL) {
++        BN_free(dh->p);
++        dh->p = p;
++    }
++    if (q != NULL) {
++        BN_free(dh->q);
++        dh->q = q;
++    }
++    if (g != NULL) {
++        BN_free(dh->g);
++        dh->g = g;
++    }
++
++    if (q != NULL) {
++        dh->length = BN_num_bits(q);
++    }
++
++    return 1;
++}
++
++void DH_get0_key(const DH *dh, const BIGNUM **pub_key, const BIGNUM **priv_key)
++{
++    if (pub_key != NULL)
++        *pub_key = dh->pub_key;
++    if (priv_key != NULL)
++        *priv_key = dh->priv_key;
++}
++
++int DH_set0_key(DH *dh, BIGNUM *pub_key, BIGNUM *priv_key)
++{
++    /* If the field pub_key in dh is NULL, the corresponding input
++     * parameters MUST be non-NULL.  The priv_key field may
++     * be left NULL.
++     */
++    if (dh->pub_key == NULL && pub_key == NULL)
++        return 0;
++
++    if (pub_key != NULL) {
++        BN_free(dh->pub_key);
++        dh->pub_key = pub_key;
++    }
++    if (priv_key != NULL) {
++        BN_free(dh->priv_key);
++        dh->priv_key = priv_key;
++    }
++
++    return 1;
++}
++
++int DH_set_length(DH *dh, long length)
++{
++    dh->length = length;
++    return 1;
++}
++
++HMAC_CTX *HMAC_CTX_new(void)
++{
++    return OPENSSL_zalloc(sizeof(HMAC_CTX));
++}
++
++void HMAC_CTX_free(HMAC_CTX *ctx)
++{
++    HMAC_CTX_cleanup(ctx);
++    OPENSSL_free(ctx);
++}
++
++RSA *EVP_PKEY_get0_RSA(EVP_PKEY *pkey)
++{
++    if (pkey->type != EVP_PKEY_RSA) {
++        return NULL;
++    }
++    return pkey->pkey.rsa;
++}
++
++
++#endif /* OPENSSL_VERSION_NUMBER */
+diff --git a/src/racoon/openssl_compat.h b/src/racoon/openssl_compat.h
+new file mode 100644
+index 0000000..9e152c2
+--- /dev/null
++++ b/src/racoon/openssl_compat.h
+@@ -0,0 +1,45 @@
++#ifndef OPENSSL_COMPAT_H
++#define OPENSSL_COMPAT_H
++
++#include <openssl/opensslv.h>
++#if OPENSSL_VERSION_NUMBER < 0x10100000L
++
++#include <openssl/rsa.h>
++#include <openssl/dh.h>
++#include <openssl/evp.h>
++#include <openssl/hmac.h>
++
++int RSA_set0_key(RSA *r, BIGNUM *n, BIGNUM *e, BIGNUM *d);
++int RSA_set0_factors(RSA *r, BIGNUM *p, BIGNUM *q);
++int RSA_set0_crt_params(RSA *r, BIGNUM *dmp1, BIGNUM *dmq1, BIGNUM *iqmp);
++void RSA_get0_key(const RSA *r, const BIGNUM **n, const BIGNUM **e, const BIGNUM **d);
++void RSA_get0_factors(const RSA *r, const BIGNUM **p, const BIGNUM **q);
++void RSA_get0_crt_params(const RSA *r, const BIGNUM **dmp1, const BIGNUM **dmq1, const BIGNUM **iqmp);
++
++int DH_set0_pqg(DH *dh, BIGNUM *p, BIGNUM *q, BIGNUM *g);
++void DH_get0_key(const DH *dh, const BIGNUM **pub_key, const BIGNUM **priv_key);
++int DH_set0_key(DH *dh, BIGNUM *pub_key, BIGNUM *priv_key);
++int DH_set_length(DH *dh, long length);
++
++HMAC_CTX *HMAC_CTX_new(void);
++void HMAC_CTX_free(HMAC_CTX* ctx);
++
++RSA *EVP_PKEY_get0_RSA(EVP_PKEY *pkey);
++
++#define ASN1_STRING_length(s) s->length
++#define ASN1_STRING_get0_data(s) s->data
++
++#define X509_get_subject_name(x) x->cert_info->subject
++#define X509_get_issuer_name(x) x->cert_info->issuer
++#define X509_NAME_ENTRY_get_data(n) n->value
++#define X509_NAME_ENTRY_get_object(n) n->object
++#define X509_STORE_CTX_get_current_cert(ctx) ctx->current_cert
++#define X509_STORE_CTX_get_error(ctx) ctx->error
++#define X509_STORE_CTX_get_error_depth(ctx) ctx->error_depth
++
++#define OPENSSL_VERSION SSLEAY_VERSION
++#define OpenSSL_version SSLeay_version
++
++#endif /* OPENSSL_VERSION_NUMBER */
++
++#endif /* OPENSSL_COMPAT_H */
+diff --git a/src/racoon/plainrsa-gen.c b/src/racoon/plainrsa-gen.c
+index cad1861..b949b08 100644
+--- a/src/racoon/plainrsa-gen.c
++++ b/src/racoon/plainrsa-gen.c
+@@ -60,6 +60,7 @@
+ #include "vmbuf.h"
+ #include "plog.h"
+ #include "crypto_openssl.h"
++#include "openssl_compat.h"
+ 
+ #include "package_version.h"
+ 
+@@ -90,12 +91,14 @@ mix_b64_pubkey(const RSA *key)
+ 	char *binbuf;
+ 	long binlen, ret;
+ 	vchar_t *res;
+-	
+-	binlen = 1 + BN_num_bytes(key->e) + BN_num_bytes(key->n);
++	const BIGNUM *e, *n;
++
++	RSA_get0_key(key, &n, &e, NULL);
++	binlen = 1 + BN_num_bytes(e) + BN_num_bytes(n);
+ 	binbuf = malloc(binlen);
+ 	memset(binbuf, 0, binlen);
+-	binbuf[0] = BN_bn2bin(key->e, (unsigned char *) &binbuf[1]);
+-	ret = BN_bn2bin(key->n, (unsigned char *) (&binbuf[binbuf[0] + 1]));
++	binbuf[0] = BN_bn2bin(e, (unsigned char *) &binbuf[1]);
++	ret = BN_bn2bin(n, (unsigned char *) (&binbuf[binbuf[0] + 1]));
+ 	if (1 + binbuf[0] + ret != binlen) {
+ 		plog(LLV_ERROR, LOCATION, NULL,
+ 		     "Pubkey generation failed. This is really strange...\n");
+@@ -131,16 +134,20 @@ print_rsa_key(FILE *fp, const RSA *key)
+ 	
+ 	fprintf(fp, "# : PUB 0s%s\n", pubkey64->v);
+ 	fprintf(fp, ": RSA\t{\n");
+-	fprintf(fp, "\t# RSA %d bits\n", BN_num_bits(key->n));
++	const BIGNUM *n, *e, *d, *p, *q, *dmp1, *dmq1, *iqmp;
++	RSA_get0_key(key, &n, &e, &d);
++	RSA_get0_factors(key, &p, &q);
++	RSA_get0_crt_params(key, &dmp1, &dmq1, &iqmp);
++	fprintf(fp, "\t# RSA %d bits\n", BN_num_bits(n));
+ 	fprintf(fp, "\t# pubkey=0s%s\n", pubkey64->v);
+-	fprintf(fp, "\tModulus: 0x%s\n", lowercase(BN_bn2hex(key->n)));
+-	fprintf(fp, "\tPublicExponent: 0x%s\n", lowercase(BN_bn2hex(key->e)));
+-	fprintf(fp, "\tPrivateExponent: 0x%s\n", lowercase(BN_bn2hex(key->d)));
+-	fprintf(fp, "\tPrime1: 0x%s\n", lowercase(BN_bn2hex(key->p)));
+-	fprintf(fp, "\tPrime2: 0x%s\n", lowercase(BN_bn2hex(key->q)));
+-	fprintf(fp, "\tExponent1: 0x%s\n", lowercase(BN_bn2hex(key->dmp1)));
+-	fprintf(fp, "\tExponent2: 0x%s\n", lowercase(BN_bn2hex(key->dmq1)));
+-	fprintf(fp, "\tCoefficient: 0x%s\n", lowercase(BN_bn2hex(key->iqmp)));
++	fprintf(fp, "\tModulus: 0x%s\n", lowercase(BN_bn2hex(n)));
++	fprintf(fp, "\tPublicExponent: 0x%s\n", lowercase(BN_bn2hex(e)));
++	fprintf(fp, "\tPrivateExponent: 0x%s\n", lowercase(BN_bn2hex(d)));
++	fprintf(fp, "\tPrime1: 0x%s\n", lowercase(BN_bn2hex(p)));
++	fprintf(fp, "\tPrime2: 0x%s\n", lowercase(BN_bn2hex(q)));
++	fprintf(fp, "\tExponent1: 0x%s\n", lowercase(BN_bn2hex(dmp1)));
++	fprintf(fp, "\tExponent2: 0x%s\n", lowercase(BN_bn2hex(dmq1)));
++	fprintf(fp, "\tCoefficient: 0x%s\n", lowercase(BN_bn2hex(iqmp)));
+ 	fprintf(fp, "  }\n");
+ 
+ 	vfree(pubkey64);
+@@ -203,11 +210,13 @@ int
+ gen_rsa_key(FILE *fp, size_t bits, unsigned long exp)
+ {
+ 	int ret;
+-	RSA *key;
++	RSA *key = RSA_new();
++	BIGNUM *e = BN_new();
+ 
+-	key = RSA_generate_key(bits, exp, NULL, NULL);
+-	if (!key) {
++	BN_set_word(e, exp);
++	if (! RSA_generate_key_ex(key, bits, e, NULL)) {
+ 		fprintf(stderr, "RSA_generate_key(): %s\n", eay_strerror());
++		RSA_free(key);
+ 		return -1;
+ 	}
+ 	
+diff --git a/src/racoon/prsa_par.y b/src/racoon/prsa_par.y
+index 1987e4d..27ce4c6 100644
+--- a/src/racoon/prsa_par.y
++++ b/src/racoon/prsa_par.y
+@@ -68,6 +68,7 @@
+ #include "isakmp_var.h"
+ #include "handler.h"
+ #include "crypto_openssl.h"
++#include "openssl_compat.h"
+ #include "sockmisc.h"
+ #include "rsalist.h"
+ 
+@@ -85,7 +86,18 @@ char *prsa_cur_fname = NULL;
+ struct genlist *prsa_cur_list = NULL;
+ enum rsa_key_type prsa_cur_type = RSA_TYPE_ANY;
+ 
+-static RSA *rsa_cur;
++struct my_rsa_st {
++	BIGNUM *n;
++	BIGNUM *e;
++	BIGNUM *d;
++	BIGNUM *p;
++	BIGNUM *q;
++	BIGNUM *dmp1;
++	BIGNUM *dmq1;
++	BIGNUM *iqmp;
++};
++
++static struct my_rsa_st *rsa_cur;
+ 
+ void
+ prsaerror(const char *s, ...)
+@@ -201,8 +213,12 @@ rsa_statement:
+ 				rsa_cur->iqmp = NULL;
+ 			}
+ 		}
+-		$$ = rsa_cur;
+-		rsa_cur = RSA_new();
++		RSA * rsa_tmp = RSA_new();
++		RSA_set0_key(rsa_tmp, rsa_cur->n, rsa_cur->e, rsa_cur->d);
++		RSA_set0_factors(rsa_tmp, rsa_cur->p, rsa_cur->q);
++		RSA_set0_crt_params(rsa_tmp, rsa_cur->dmp1, rsa_cur->dmq1, rsa_cur->iqmp);
++		$$ = rsa_tmp;
++		memset(rsa_cur, 0, sizeof(struct my_rsa_st));
+ 	}
+ 	| TAG_PUB BASE64
+ 	{
+@@ -351,10 +367,12 @@ prsa_parse_file(struct genlist *list, char *fname, enum rsa_key_type type)
+ 	prsa_cur_fname = fname;
+ 	prsa_cur_list = list;
+ 	prsa_cur_type = type;
+-	rsa_cur = RSA_new();
++	rsa_cur = malloc(sizeof(struct my_rsa_st));
++	memset(rsa_cur, 0, sizeof(struct my_rsa_st));
+ 	ret = prsaparse();
+ 	if (rsa_cur) {
+-		RSA_free(rsa_cur);
++		memset(rsa_cur, 0, sizeof(struct my_rsa_st));
++		free(rsa_cur);
+ 		rsa_cur = NULL;
+ 	}
+ 	fclose (fp);
+diff --git a/src/racoon/rsalist.c b/src/racoon/rsalist.c
+index f152c82..96e8363 100644
+--- a/src/racoon/rsalist.c
++++ b/src/racoon/rsalist.c
+@@ -52,6 +52,7 @@
+ #include "genlist.h"
+ #include "remoteconf.h"
+ #include "crypto_openssl.h"
++#include "openssl_compat.h"
+ 
+ #ifndef LIST_FIRST
+ #define LIST_FIRST(head)        ((head)->lh_first)
+@@ -98,7 +99,9 @@ rsa_key_dup(struct rsa_key *key)
+ 		return NULL;
+ 
+ 	if (key->rsa) {
+-		new->rsa = key->rsa->d != NULL ? RSAPrivateKey_dup(key->rsa) : RSAPublicKey_dup(key->rsa);
++		const BIGNUM *d;
++		RSA_get0_key(key->rsa, NULL, NULL, &d);
++		new->rsa = (d != NULL ? RSAPrivateKey_dup(key->rsa) : RSAPublicKey_dup(key->rsa));
+ 		if (new->rsa == NULL)
+ 			goto dup_error;
+ 	}
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/ipsec-tools/ipsec-tools_0.8.2.bb b/meta-openembedded/meta-networking/recipes-support/ipsec-tools/ipsec-tools_0.8.2.bb
index 5cbeb15..a6d473b 100644
--- a/meta-openembedded/meta-networking/recipes-support/ipsec-tools/ipsec-tools_0.8.2.bb
+++ b/meta-openembedded/meta-networking/recipes-support/ipsec-tools/ipsec-tools_0.8.2.bb
@@ -25,6 +25,8 @@
            file://0001-Fix-header-issues-found-with-musl-libc.patch \
            file://0002-cfparse-clear-memory-equal-to-size-of-array.patch \
            file://fix-CVE-2016-10396.patch \
+           file://0001-Disable-gcc8-specific-warnings.patch \
+           file://0001-ipsec-tools-add-openssl-1.1-support.patch \
            "
 SRC_URI[md5sum] = "d53ec14a0a3ece64e09e5e34b3350b41"
 SRC_URI[sha256sum] = "8eb6b38716e2f3a8a72f1f549c9444c2bc28d52c9536792690564c74fe722f2d"
diff --git a/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm/0001-Modify-the-Makefile-for-cross-compile.patch b/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm/0001-Modify-the-Makefile-for-cross-compile.patch
index 7c3dfe4..d7b0267 100644
--- a/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm/0001-Modify-the-Makefile-for-cross-compile.patch
+++ b/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm/0001-Modify-the-Makefile-for-cross-compile.patch
@@ -1,18 +1,22 @@
-From 58292175115bae7a4c3600d3022e59ea57213025 Mon Sep 17 00:00:00 2001
-From: Jianchuan Wang <jianchuan.wang@windriver.com>
-Date: Mon, 12 Jan 2015 15:53:23 +0800
+From 801224257015788d3aff026bf2ae1cd8531d4fcc Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Wed, 25 Jul 2018 13:12:04 +0800
 Subject: [PATCH] Modify the Makefile for cross compile.
 
 Upstream-Status: Inappropriate [embedded specific]
 
 Signed-off-by: Jianchuan Wang <jianchuan.wang@windriver.com>
+
+update to version 1.29
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
 ---
- Makefile         | 23 ++++++-----------------
+ Makefile         | 9 ++++-----
  libipvs/Makefile |  3 +--
- 2 files changed, 7 insertions(+), 19 deletions(-)
+ 2 files changed, 5 insertions(+), 7 deletions(-)
 
 diff --git a/Makefile b/Makefile
-index e4e03cc..461c021 100644
+index 91a2991..906086d 100644
 --- a/Makefile
 +++ b/Makefile
 @@ -35,10 +35,9 @@ ARCH		= $(shell uname -m)
@@ -23,57 +27,29 @@
  INCLUDE		=
  SBIN		= $(BUILD_ROOT)/sbin
 -MANDIR		= usr/man
-+MANDIR		= usr/share/man
++MANDIR          = usr/share/man
  MAN		= $(BUILD_ROOT)/$(MANDIR)/man8
  INIT		= $(BUILD_ROOT)/etc/rc.d/init.d
  MKDIR		= mkdir
-@@ -62,17 +61,7 @@ RPMBUILD = $(shell				\
- 		echo "/bin/rpm";		\
- 	fi )
- 
--ifeq (,$(FORCE_GETOPT))
--LIB_SEARCH = /lib64 /usr/lib64 /usr/local/lib64 /lib /usr/lib /usr/local/lib
--POPT_LIB = $(shell for i in $(LIB_SEARCH); do \
--  if [ -f $$i/libpopt.a ]; then \
--    if nm $$i/libpopt.a | fgrep -q poptGetContext; then \
--	echo "-lpopt"; \
--	break; \
--    fi; \
--  fi; \
--done)
--endif
-+POPT_LIB = -lpopt
- 
- ifneq (,$(POPT_LIB))
- POPT_DEFINE = -DHAVE_POPT
-@@ -81,7 +70,7 @@ endif
- OBJS		= ipvsadm.o config_stream.o dynamic_array.o
- LIBS		= $(POPT_LIB)
- ifneq (0,$(HAVE_NL))
--LIBS		+= -lnl
-+LIBS		+= -lnl-3 -lnl-genl-3
- endif
- DEFINES		= -DVERSION=\"$(VERSION)\" -DSCHEDULERS=\"$(SCHEDULERS)\" \
- 		  -DPE_LIST=\"$(PE_LIST)\" $(POPT_DEFINE)
-@@ -91,13 +80,13 @@ DEFINES		+= $(shell if [ ! -f ../ip_vs.h ]; then	\
+@@ -81,13 +80,13 @@ DEFINES		+= $(shell if [ ! -f ../ip_vs.h ]; then	\
  
  .PHONY	= all clean install dist distclean rpm rpms
  
 -all:            libs ipvsadm
-+all: ipvsadm
++all:            ipvsadm
  
  libs:
  		make -C libipvs
  
 -ipvsadm:	$(OBJS) $(STATIC_LIBS)
 -		$(CC) $(CFLAGS) -o $@ $^ $(LIBS)
-+ipvsadm:	$(OBJS) libs
++ipvsadm:       $(OBJS) libs
 +		$(CC) $(CFLAGS) -o $@ $(OBJS) $(STATIC_LIBS) $(LIBS)
  
  install:        all
  		if [ ! -d $(SBIN) ]; then $(MKDIR) -p $(SBIN); fi
 diff --git a/libipvs/Makefile b/libipvs/Makefile
-index a527a7f..b7300ec 100644
+index f845c8b..dafab30 100644
 --- a/libipvs/Makefile
 +++ b/libipvs/Makefile
 @@ -1,6 +1,5 @@
@@ -83,7 +59,7 @@
  CFLAGS		= -Wall -Wunused -Wstrict-prototypes -g -fPIC
  ifneq (0,$(HAVE_NL))
  CFLAGS		+= -DLIBIPVS_USE_NL
-@@ -18,7 +17,7 @@ SHARED_LIB	= libipvs.so
+@@ -30,7 +29,7 @@ SHARED_LIB	= libipvs.so
  all:		$(STATIC_LIB) $(SHARED_LIB)
  
  $(STATIC_LIB):	libipvs.o ip_vs_nl_policy.o
@@ -93,5 +69,5 @@
  $(SHARED_LIB):	libipvs.o ip_vs_nl_policy.o
  		$(CC) -shared -Wl,-soname,$@ -o $@ $^
 -- 
-1.9.1
+2.7.4
 
diff --git a/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm/0002-Replace-nl_handle-to-nl_sock.patch b/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm/0002-Replace-nl_handle-to-nl_sock.patch
deleted file mode 100644
index 7896d6d..0000000
--- a/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm/0002-Replace-nl_handle-to-nl_sock.patch
+++ /dev/null
@@ -1,63 +0,0 @@
-From 2686213259b15df9cf1d969c5a14d62f14cfbaae Mon Sep 17 00:00:00 2001
-From: Jianchuan Wang <jianchuan.wang@windriver.com>
-Date: Thu, 8 Jan 2015 17:37:11 +0800
-Subject: [PATCH 2/2] Replace nl_handle to nl_sock.
-
-The nl_handle was replace with nl_sock in the libnl-3.
-
-Upstream-Status: Inappropriate [embedded specific]
-
-Signed-off-by: Jianchuan Wang <jianchuan.wang@windriver.com>
----
- libipvs/libipvs.c | 10 +++++-----
- 1 file changed, 5 insertions(+), 5 deletions(-)
-
-diff --git a/libipvs/libipvs.c b/libipvs/libipvs.c
-index a157e18..21a9bfa 100644
---- a/libipvs/libipvs.c
-+++ b/libipvs/libipvs.c
-@@ -32,7 +32,7 @@ static void* ipvs_func = NULL;
- struct ip_vs_getinfo ipvs_info;
- 
- #ifdef LIBIPVS_USE_NL
--static struct nl_handle *sock = NULL;
-+static struct nl_sock *sock = NULL;
- static int family, try_nl = 1;
- #endif
- 
-@@ -73,7 +73,7 @@ int ipvs_nl_send_message(struct nl_msg *msg, nl_recvmsg_msg_cb_t func, void *arg
- {
- 	int err = EINVAL;
- 
--	sock = nl_handle_alloc();
-+	sock = nl_socket_alloc();
- 	if (!sock) {
- 		nlmsg_free(msg);
- 		return -1;
-@@ -88,7 +88,7 @@ int ipvs_nl_send_message(struct nl_msg *msg, nl_recvmsg_msg_cb_t func, void *arg
- 
- 	/* To test connections and set the family */
- 	if (msg == NULL) {
--		nl_handle_destroy(sock);
-+		nl_socket_free(sock);
- 		sock = NULL;
- 		return 0;
- 	}
-@@ -104,12 +104,12 @@ int ipvs_nl_send_message(struct nl_msg *msg, nl_recvmsg_msg_cb_t func, void *arg
- 
- 	nlmsg_free(msg);
- 
--	nl_handle_destroy(sock);
-+	nl_socket_free(sock);
- 
- 	return 0;
- 
- fail_genl:
--	nl_handle_destroy(sock);
-+	nl_socket_free(sock);
- 	sock = NULL;
- 	nlmsg_free(msg);
- 	errno = err;
--- 
-1.8.3.1
-
diff --git a/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm/makefile-add-ldflags.patch b/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm/makefile-add-ldflags.patch
index 1bf1eed..a2c5235 100644
--- a/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm/makefile-add-ldflags.patch
+++ b/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm/makefile-add-ldflags.patch
@@ -1,19 +1,33 @@
-Add LDFLAGS variable to Makefile, make sure the extra linker flags can be passed.
+From 8aff1e965ec17262f3a5b376f7eb3e053d81905c Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Tue, 24 Jul 2018 18:18:05 +0800
+Subject: [PATCH] Add LDFLAGS variable to Makefile, make sure the extra linker
+ flags can be passed.
 
 Upstream-Status: Pending
 
 Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
 
+Update to version 1.29
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
 diff --git a/Makefile b/Makefile
-index 461c021..8bc9cde 100644
+index f29bbae..81beb5a 100644
 --- a/Makefile
 +++ b/Makefile
 @@ -86,7 +86,7 @@ libs:
  		make -C libipvs
  
- ipvsadm:	$(OBJS) libs
+ ipvsadm:       $(OBJS) libs
 -		$(CC) $(CFLAGS) -o $@ $(OBJS) $(STATIC_LIBS) $(LIBS)
 +		$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(OBJS) $(STATIC_LIBS) $(LIBS)
  
  install:        all
  		if [ ! -d $(SBIN) ]; then $(MKDIR) -p $(SBIN); fi
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm_1.26.bb b/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm_1.26.bb
deleted file mode 100644
index b35a9f4..0000000
--- a/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm_1.26.bb
+++ /dev/null
@@ -1,37 +0,0 @@
-SUMMARY = "Linux Virtual Server administration Utility"
-HOMEPAGE = "http://www.linux-vs.org/software/index.html"
-DESCRIPTION = "Ipvsadm  is  used  to set up, maintain or inspect the virtual server \
-table in the Linux kernel. The Linux Virtual  Server  can  be  used  to \
-build  scalable  network  services  based  on  a cluster of two or more nodes. \
-The active node of the cluster redirects service requests  to  a \
-collection  of  server  hosts  that will actually perform the services. \
-Supported features include two protocols (TCP and UDP),  three  packet-forwarding \
-methods (NAT, tunneling, and direct routing), and eight load balancing algorithms \
-(round robin, weighted round robin,  least-connec-tion, weighted least-connection, \
-locality-based  least-connection, locality-based least-connection with replication, \
-destination-hashing, and source-hashing)."
-SECTION = "net"
-LICENSE = "GPL-2.0"
-LIC_FILES_CHKSUM = "file://README;beginline=40;endline=56;md5=a54cba37b64924aa5008881607942892"
-
-DEPENDS += "libnl popt"
-
-SRC_URI = "http://www.linuxvirtualserver.org/software/kernel-2.6/${BP}.tar.gz \
-        file://0001-Modify-the-Makefile-for-cross-compile.patch \
-        file://0002-Replace-nl_handle-to-nl_sock.patch \
-        file://0003-ipvsadm-remove-dependency-on-bash.patch \
-        file://makefile-add-ldflags.patch \
-"
-
-SRC_URI[md5sum] = "eac3ba3f62cd4dea2da353aeddd353a8"
-SRC_URI[sha256sum] = "6d6c46fecb1c532a892616b4445c73b71730e8790d5630f60269fd9cbee0eb2d"
-
-do_compile() {
-    oe_runmake \
-    CC="${CC} -I${STAGING_INCDIR} -I${STAGING_INCDIR}/libnl3 -L${STAGING_LIBDIR}" \
-    all
-}
-
-do_install() {
-    oe_runmake 'BUILD_ROOT=${D}' install
-}
diff --git a/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm_1.29.bb b/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm_1.29.bb
new file mode 100644
index 0000000..4f3c16d
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/ipvsadm/ipvsadm_1.29.bb
@@ -0,0 +1,41 @@
+SUMMARY = "Linux Virtual Server administration Utility"
+HOMEPAGE = "http://www.linux-vs.org/software/index.html"
+DESCRIPTION = "Ipvsadm  is  used  to set up, maintain or inspect the virtual server \
+table in the Linux kernel. The Linux Virtual  Server  can  be  used  to \
+build  scalable  network  services  based  on  a cluster of two or more nodes. \
+The active node of the cluster redirects service requests  to  a \
+collection  of  server  hosts  that will actually perform the services. \
+Supported features include two protocols (TCP and UDP),  three  packet-forwarding \
+methods (NAT, tunneling, and direct routing), and eight load balancing algorithms \
+(round robin, weighted round robin,  least-connec-tion, weighted least-connection, \
+locality-based  least-connection, locality-based least-connection with replication, \
+destination-hashing, and source-hashing)."
+SECTION = "net"
+LICENSE = "GPL-2.0"
+LIC_FILES_CHKSUM = "file://README;beginline=40;endline=56;md5=b4e40069f15598d0e3fe2aa177e5ec77"
+
+DEPENDS += "libnl popt"
+
+SRC_URI = "https://mirrors.edge.kernel.org/pub/linux/utils/kernel/ipvsadm/${BP}.tar.gz \
+        file://0001-Modify-the-Makefile-for-cross-compile.patch \
+        file://0003-ipvsadm-remove-dependency-on-bash.patch \
+        file://makefile-add-ldflags.patch \
+"
+
+SRC_URI[md5sum] = "88b35030b4766b3e44ad15aacdef65c4"
+SRC_URI[sha256sum] = "297f5cd459c3eef81ed0ca32e53bf320ed6b132fe7ed6ea5e44aa6b1fbd2a7de"
+
+UPSTREAM_CHECK_URI = "${KERNELORG_MIRROR}/linux/utils/kernel/ipvsadm"
+
+do_compile() {
+    oe_runmake \
+    CC="${CC} -I${STAGING_INCDIR} -I${STAGING_INCDIR}/libnl3 -L${STAGING_LIBDIR}" \
+    all
+}
+
+do_install() {
+    sed -i -e "s;SBIN\t\t= \$(BUILD_ROOT)/sbin;SBIN\t\t= \$(BUILD_ROOT)/$base_sbindir;" ${S}/Makefile
+    oe_runmake 'BUILD_ROOT=${D}' install
+}
+
+inherit pkgconfig
diff --git a/meta-openembedded/meta-networking/recipes-support/libldb/libldb/0001-libldb-fix-config-error.patch b/meta-openembedded/meta-networking/recipes-support/libldb/libldb/0001-libldb-fix-config-error.patch
new file mode 100644
index 0000000..5818d57
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/libldb/libldb/0001-libldb-fix-config-error.patch
@@ -0,0 +1,87 @@
+From bc4ff7e37ce120c257e52a81fe3475499dfd2573 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Tue, 24 Jul 2018 10:10:24 +0800
+Subject: [PATCH] libldb: fix config error
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ wscript | 58 +++++++++++++++++++++++++++++-----------------------------
+ 1 file changed, 29 insertions(+), 29 deletions(-)
+
+diff --git a/wscript b/wscript
+index b0af7b6..8ad9f96 100644
+--- a/wscript
++++ b/wscript
+@@ -115,40 +115,40 @@ def configure(conf):
+                                              onlyif='talloc tdb tevent pyldb-util',
+                                              implied_deps='replace talloc tdb tevent'):
+                 conf.define('USING_SYSTEM_LDB', 1)
++    if not Options.options.without_ldb_lmdb:
++        if not conf.CHECK_CODE('return !(sizeof(size_t) >= 8)',
++                               "HAVE_64_BIT_SIZE_T_FOR_LMDB",
++                               execute=True,
++                               msg='Checking for a 64-bit host to '
++                               'support lmdb'):
++            Logs.warn("--without-ldb-lmdb implied as this "
++                      "host is not 64-bit")
++
++            if not conf.env.standalone_ldb and \
++               not Options.options.without_ad_dc and \
++               conf.CONFIG_GET('ENABLE_SELFTEST'):
++                Logs.warn("NOTE: Some AD DC parts of selftest will fail")
+ 
+-    if not conf.CHECK_CODE('return !(sizeof(size_t) >= 8)',
+-                           "HAVE_64_BIT_SIZE_T_FOR_LMDB",
+-                           execute=True,
+-                           msg='Checking for a 64-bit host to '
+-                           'support lmdb'):
+-        Logs.warn("--without-ldb-lmdb implied as this "
+-                  "host is not 64-bit")
+-
+-        if not conf.env.standalone_ldb and \
+-           not Options.options.without_ad_dc and \
+-           conf.CONFIG_GET('ENABLE_SELFTEST'):
+-            Logs.warn("NOTE: Some AD DC parts of selftest will fail")
+-
+-        conf.env.REQUIRE_LMDB = False
+-    else:
+-        if conf.env.standalone_ldb:
+-            if Options.options.without_ldb_lmdb:
+-                conf.env.REQUIRE_LMDB = False
+-            else:
+-                conf.env.REQUIRE_LMDB = True
+-        elif Options.options.without_ad_dc:
+             conf.env.REQUIRE_LMDB = False
+         else:
+-            if Options.options.without_ldb_lmdb:
+-                if not Options.options.without_ad_dc and \
+-                   conf.CONFIG_GET('ENABLE_SELFTEST'):
+-                    raise Utils.WafError('--without-ldb-lmdb conflicts '
+-                                         'with --enable-selftest while '
+-                                         'building the AD DC')
+-
++            if conf.env.standalone_ldb:
++                if Options.options.without_ldb_lmdb:
++                    conf.env.REQUIRE_LMDB = False
++                else:
++                    conf.env.REQUIRE_LMDB = True
++            elif Options.options.without_ad_dc:
+                 conf.env.REQUIRE_LMDB = False
+             else:
+-                conf.env.REQUIRE_LMDB = True
++                if Options.options.without_ldb_lmdb:
++                    if not Options.options.without_ad_dc and \
++                       conf.CONFIG_GET('ENABLE_SELFTEST'):
++                        raise Utils.WafError('--without-ldb-lmdb conflicts '
++                                             'with --enable-selftest while '
++                                             'building the AD DC')
++
++                    conf.env.REQUIRE_LMDB = False
++                else:
++                    conf.env.REQUIRE_LMDB = True
+ 
+ 
+     if conf.CONFIG_SET('USING_SYSTEM_LDB'):
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/libldb/libldb/avoid-openldap-unless-wanted.patch b/meta-openembedded/meta-networking/recipes-support/libldb/libldb/avoid-openldap-unless-wanted.patch
index 8ab094f..b30afee 100644
--- a/meta-openembedded/meta-networking/recipes-support/libldb/libldb/avoid-openldap-unless-wanted.patch
+++ b/meta-openembedded/meta-networking/recipes-support/libldb/libldb/avoid-openldap-unless-wanted.patch
@@ -1,6 +1,16 @@
---- a/wscript	2015-11-18 12:43:33.000000000 +0100
-+++ b/wscript	2015-11-18 12:46:25.000000000 +0100
-@@ -58,9 +58,7 @@
+From 63570b98ef63c91d8508478fcbe6b89c90c8398f Mon Sep 17 00:00:00 2001
+From: Jens Rehsack <rehsack@gmail.com>
+Date: Thu, 19 Nov 2015 20:45:56 +0100
+
+---
+ wscript | 4 +---
+ 1 file changed, 1 insertion(+), 3 deletions(-)
+
+diff --git a/wscript b/wscript
+index e7c05d2..1633593 100644
+--- a/wscript
++++ b/wscript
+@@ -161,9 +161,7 @@ def configure(conf):
      if conf.env.standalone_ldb:
          conf.CHECK_XSLTPROC_MANPAGES()
  
diff --git a/meta-openembedded/meta-networking/recipes-support/libldb/libldb/do-not-import-target-module-while-cross-compile.patch b/meta-openembedded/meta-networking/recipes-support/libldb/libldb/do-not-import-target-module-while-cross-compile.patch
old mode 100755
new mode 100644
index fdd312c..ee4936a
--- a/meta-openembedded/meta-networking/recipes-support/libldb/libldb/do-not-import-target-module-while-cross-compile.patch
+++ b/meta-openembedded/meta-networking/recipes-support/libldb/libldb/do-not-import-target-module-while-cross-compile.patch
@@ -1,12 +1,21 @@
+From f4cda3a71311e4496b725bc5f46af93413ec7a1c Mon Sep 17 00:00:00 2001
+From: Bian Naimeng <biannm@cn.fujitsu.com>
+Date: Fri, 17 Jul 2015 11:58:49 +0800
+Subject: [PATCH] libldb: add new recipe
+
 Some modules such as dynamic library maybe cann't be imported while cross compile,
 we just check whether does the module exist.
 
 Signed-off-by: Bian Naimeng <biannm@cn.fujitsu.com>
 
-Index: ldb-1.1.26/buildtools/wafsamba/samba_bundled.py
-===================================================================
---- ldb-1.1.26.orig/buildtools/wafsamba/samba_bundled.py
-+++ ldb-1.1.26/buildtools/wafsamba/samba_bundled.py
+---
+ buildtools/wafsamba/samba_bundled.py | 32 ++++++++++++++++++++++++--------
+ 1 file changed, 24 insertions(+), 8 deletions(-)
+
+diff --git a/buildtools/wafsamba/samba_bundled.py b/buildtools/wafsamba/samba_bundled.py
+index 253d604..398cc6a 100644
+--- a/buildtools/wafsamba/samba_bundled.py
++++ b/buildtools/wafsamba/samba_bundled.py
 @@ -2,6 +2,7 @@
  
  import sys
@@ -15,7 +24,7 @@
  from Configure import conf
  from samba_utils import TO_LIST
  
-@@ -230,17 +231,32 @@ def CHECK_BUNDLED_SYSTEM_PYTHON(conf, li
+@@ -249,17 +250,32 @@ def CHECK_BUNDLED_SYSTEM_PYTHON(conf, libname, modulename, minversion='0.0.0'):
      # versions
      minversion = minimum_library_version(conf, libname, minversion)
  
diff --git a/meta-openembedded/meta-networking/recipes-support/libldb/libldb/libldb-fix-musl-libc-conflict-type-error.patch b/meta-openembedded/meta-networking/recipes-support/libldb/libldb/libldb-fix-musl-libc-conflict-type-error.patch
new file mode 100644
index 0000000..444fa3f
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/libldb/libldb/libldb-fix-musl-libc-conflict-type-error.patch
@@ -0,0 +1,45 @@
+From 5bd7b5d04435bd593349825973ce32290f5f604d Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Wed, 25 Jul 2018 09:55:25 +0800
+Subject: [PATCH] libldb: fix musl libc conflicting types error
+
+/third_party/cmocka/cmocka.h:126:28: error: conflicting types for 'uintptr_t'
+            typedef unsigned int uintptr_t;
+                                 ^~~~~~~~~
+use __DEFINED_uintptr_t in alltypes.h to check if uintptr already defined
+
+Upstream-Status: Pending
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ third_party/cmocka/cmocka.h | 7 +++----
+ 1 file changed, 3 insertions(+), 4 deletions(-)
+
+diff --git a/third_party/cmocka/cmocka.h b/third_party/cmocka/cmocka.h
+index 4fd82a9..5443a08 100644
+--- a/third_party/cmocka/cmocka.h
++++ b/third_party/cmocka/cmocka.h
+@@ -110,7 +110,7 @@ typedef uintmax_t LargestIntegralType;
+     ((LargestIntegralType)(value))
+ 
+ /* Smallest integral type capable of holding a pointer. */
+-#if !defined(_UINTPTR_T) && !defined(_UINTPTR_T_DEFINED)
++#if !defined(__DEFINED_uintptr_t) 
+ # if defined(_WIN32)
+     /* WIN32 is an ILP32 platform */
+     typedef unsigned int uintptr_t;
+@@ -134,9 +134,8 @@ typedef uintmax_t LargestIntegralType;
+ #  endif /* __WORDSIZE */
+ # endif /* _WIN32 */
+ 
+-# define _UINTPTR_T
+-# define _UINTPTR_T_DEFINED
+-#endif /* !defined(_UINTPTR_T) || !defined(_UINTPTR_T_DEFINED) */
++# define __DEFINED_uintptr_t
++#endif /* !defined(__DEFINED_uintptr_t) 
+ 
+ /* Perform an unsigned cast to uintptr_t. */
+ #define cast_to_pointer_integral_type(value) \
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/libldb/libldb/libldb-fix-musl-libc-unkown-type-error.patch b/meta-openembedded/meta-networking/recipes-support/libldb/libldb/libldb-fix-musl-libc-unkown-type-error.patch
new file mode 100644
index 0000000..c0e7e89
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/libldb/libldb/libldb-fix-musl-libc-unkown-type-error.patch
@@ -0,0 +1,31 @@
+From d90534469c5c43bf2a97e5698a5ddb4b7471f92a Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Tue, 24 Jul 2018 10:53:16 +0800
+Subject: [PATCH] libldb: fix musl libc unkoown type error
+
+tevent.h:1440:8: error: unknown type name 'pid_t'; did you mean 'div_t'?
+        pid_t *pid,
+         ^~~~~
+         div_t
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ lib/tevent/tevent.h | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/lib/tevent/tevent.h b/lib/tevent/tevent.h
+index aa6fe0d..2572696 100644
+--- a/lib/tevent/tevent.h
++++ b/lib/tevent/tevent.h
+@@ -32,6 +32,8 @@
+ #include <talloc.h>
+ #include <sys/time.h>
+ #include <stdbool.h>
++#include <sys/stat.h>
++#include <sys/types.h>
+ 
+ struct tevent_context;
+ struct tevent_ops;
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/libldb/libldb/options-1.3.1.patch b/meta-openembedded/meta-networking/recipes-support/libldb/libldb/options-1.3.1.patch
deleted file mode 100644
index ffe253b..0000000
--- a/meta-openembedded/meta-networking/recipes-support/libldb/libldb/options-1.3.1.patch
+++ /dev/null
@@ -1,193 +0,0 @@
-From a4da3ab4d76013aaa731d43d52ccca1ebd37c395 Mon Sep 17 00:00:00 2001
-From: Jackie Huang <jackie.huang@windriver.com>
-Date: Wed, 21 Sep 2016 10:06:39 +0800
-Subject: [PATCH 1/1] ldb: Add configure options for packages
-
-Add configure options for the following packages:
- - acl
- - attr
- - libaio
- - libbsd
- - libcap
- - valgrind
-
-Upstream-Status: Inappropriate [oe deterministic build specific]
-
-Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
----
- lib/replace/system/wscript_configure |  6 ++-
- lib/replace/wscript                  | 94 +++++++++++++++++++++++++++---------
- wscript                              |  7 +++
- 3 files changed, 83 insertions(+), 24 deletions(-)
-
-diff --git a/lib/replace/system/wscript_configure b/lib/replace/system/wscript_configure
-index 2035474..10f9ae7 100644
---- a/lib/replace/system/wscript_configure
-+++ b/lib/replace/system/wscript_configure
-@@ -1,6 +1,10 @@
- #!/usr/bin/env python
- 
--conf.CHECK_HEADERS('sys/capability.h')
-+import Options
-+
-+if Options.options.enable_libcap:
-+    conf.CHECK_HEADERS('sys/capability.h')
-+
- conf.CHECK_FUNCS('getpwnam_r getpwuid_r getpwent_r')
- 
- # solaris varients of getXXent_r
-diff --git a/lib/replace/wscript b/lib/replace/wscript
-index 2f94d49..68b2d3a 100644
---- a/lib/replace/wscript
-+++ b/lib/replace/wscript
-@@ -23,6 +23,41 @@ def set_options(opt):
-     opt.PRIVATE_EXTENSION_DEFAULT('')
-     opt.RECURSE('buildtools/wafsamba')
- 
-+    opt.add_option('--with-acl',
-+                   help=("Enable use of acl"),
-+                   action="store_true", dest='enable_acl')
-+    opt.add_option('--without-acl',
-+                   help=("Disable use of acl"),
-+                   action="store_false", dest='enable_acl', default=False)
-+
-+    opt.add_option('--with-attr',
-+                   help=("Enable use of attr"),
-+                   action="store_true", dest='enable_attr')
-+    opt.add_option('--without-attr',
-+                   help=("Disable use of attr"),
-+                   action="store_false", dest='enable_attr', default=False)
-+
-+    opt.add_option('--with-libaio',
-+                   help=("Enable use of libaio"),
-+                   action="store_true", dest='enable_libaio')
-+    opt.add_option('--without-libaio',
-+                   help=("Disable use of libaio"),
-+                   action="store_false", dest='enable_libaio', default=False)
-+
-+    opt.add_option('--with-libbsd',
-+                   help=("Enable use of libbsd"),
-+                   action="store_true", dest='enable_libbsd')
-+    opt.add_option('--without-libbsd',
-+                   help=("Disable use of libbsd"),
-+                   action="store_false", dest='enable_libbsd', default=False)
-+
-+    opt.add_option('--with-libcap',
-+                   help=("Enable use of libcap"),
-+                   action="store_true", dest='enable_libcap')
-+    opt.add_option('--without-libcap',
-+                   help=("Disable use of libcap"),
-+                   action="store_false", dest='enable_libcap', default=False)
-+
- @Utils.run_once
- def configure(conf):
-     conf.RECURSE('buildtools/wafsamba')
-@@ -32,12 +67,25 @@ def configure(conf):
-     conf.DEFINE('HAVE_LIBREPLACE', 1)
-     conf.DEFINE('LIBREPLACE_NETWORK_CHECKS', 1)
- 
--    conf.CHECK_HEADERS('linux/types.h crypt.h locale.h acl/libacl.h compat.h')
--    conf.CHECK_HEADERS('acl/libacl.h attr/xattr.h compat.h ctype.h dustat.h')
-+    conf.CHECK_HEADERS('linux/types.h crypt.h locale.h compat.h')
-+    conf.CHECK_HEADERS('compat.h ctype.h dustat.h')
-     conf.CHECK_HEADERS('fcntl.h fnmatch.h glob.h history.h krb5.h langinfo.h')
--    conf.CHECK_HEADERS('libaio.h locale.h ndir.h pwd.h')
--    conf.CHECK_HEADERS('shadow.h sys/acl.h')
--    conf.CHECK_HEADERS('sys/attributes.h attr/attributes.h sys/capability.h sys/dir.h sys/epoll.h')
-+    conf.CHECK_HEADERS('locale.h ndir.h pwd.h')
-+    conf.CHECK_HEADERS('shadow.h')
-+    conf.CHECK_HEADERS('sys/attributes.h sys/dir.h sys/epoll.h')
-+
-+    if Options.options.enable_acl:
-+        conf.CHECK_HEADERS('acl/libacl.h sys/acl.h')
-+
-+    if Options.options.enable_attr:
-+        conf.CHECK_HEADERS('attr/attributes.h attr/xattr.h')
-+
-+    if Options.options.enable_libaio:
-+        conf.CHECK_HEADERS('libaio.h')
-+
-+    if Options.options.enable_libcap:
-+        conf.CHECK_HEADERS('sys/capability.h')
-+
-     conf.CHECK_HEADERS('port.h')
-     conf.CHECK_HEADERS('sys/fcntl.h sys/filio.h sys/filsys.h sys/fs/s5param.h sys/fs/vx/quota.h')
-     conf.CHECK_HEADERS('sys/id.h sys/ioctl.h sys/ipc.h sys/mman.h sys/mode.h sys/ndir.h sys/priv.h')
-@@ -73,7 +121,9 @@ def configure(conf):
- 
-     conf.CHECK_CODE('', headers='rpc/rpc.h rpcsvc/yp_prot.h', define='HAVE_RPCSVC_YP_PROT_H')
- 
--    conf.CHECK_HEADERS('valgrind.h valgrind/valgrind.h valgrind/memcheck.h')
-+    if Options.options.enable_valgrind:
-+        conf.CHECK_HEADERS('valgrind.h valgrind/valgrind.h valgrind/memcheck.h')
-+
-     conf.CHECK_HEADERS('nss_common.h nsswitch.h ns_api.h')
-     conf.CHECK_HEADERS('sys/extattr.h sys/ea.h sys/proplist.h sys/cdefs.h')
-     conf.CHECK_HEADERS('utmp.h utmpx.h lastlog.h')
-@@ -266,22 +316,20 @@ def configure(conf):
- 
-     conf.CHECK_FUNCS('prctl dirname basename')
- 
--    strlcpy_in_bsd = False
--
--    # libbsd on some platforms provides strlcpy and strlcat
--    if not conf.CHECK_FUNCS('strlcpy strlcat'):
--        if conf.CHECK_FUNCS_IN('strlcpy strlcat', 'bsd', headers='bsd/string.h',
--                               checklibc=True):
--            strlcpy_in_bsd = True
--    if not conf.CHECK_FUNCS('getpeereid'):
--        conf.CHECK_FUNCS_IN('getpeereid', 'bsd', headers='sys/types.h bsd/unistd.h')
--    if not conf.CHECK_FUNCS_IN('setproctitle', 'setproctitle', headers='setproctitle.h'):
--        conf.CHECK_FUNCS_IN('setproctitle', 'bsd', headers='sys/types.h bsd/unistd.h')
--    if not conf.CHECK_FUNCS('setproctitle_init'):
--        conf.CHECK_FUNCS_IN('setproctitle_init', 'bsd', headers='sys/types.h bsd/unistd.h')
--
--    if not conf.CHECK_FUNCS('closefrom'):
--        conf.CHECK_FUNCS_IN('closefrom', 'bsd', headers='bsd/unistd.h')
-+    if Options.options.enable_libbsd:
-+        # libbsd on some platforms provides strlcpy and strlcat
-+        if not conf.CHECK_FUNCS('strlcpy strlcat'):
-+            conf.CHECK_FUNCS_IN('strlcpy strlcat', 'bsd', headers='bsd/string.h',
-+                    checklibc=True)
-+        if not conf.CHECK_FUNCS('getpeereid'):
-+            conf.CHECK_FUNCS_IN('getpeereid', 'bsd', headers='sys/types.h bsd/unistd.h')
-+        if not conf.CHECK_FUNCS_IN('setproctitle', 'setproctitle', headers='setproctitle.h'):
-+            conf.CHECK_FUNCS_IN('setproctitle', 'bsd', headers='sys/types.h bsd/unistd.h')
-+        if not conf.CHECK_FUNCS('setproctitle_init'):
-+            conf.CHECK_FUNCS_IN('setproctitle_init', 'bsd', headers='sys/types.h bsd/unistd.h')
-+
-+        if not conf.CHECK_FUNCS('closefrom'):
-+            conf.CHECK_FUNCS_IN('closefrom', 'bsd', headers='bsd/unistd.h')
- 
-     conf.CHECK_CODE('''
-                 struct ucred cred;
-@@ -632,7 +680,7 @@ removeea setea
-     # look for a method of finding the list of network interfaces
-     for method in ['HAVE_IFACE_GETIFADDRS', 'HAVE_IFACE_AIX', 'HAVE_IFACE_IFCONF', 'HAVE_IFACE_IFREQ']:
-         bsd_for_strlcpy = ''
--        if strlcpy_in_bsd:
-+        if Options.options.enable_libbsd:
-             bsd_for_strlcpy = ' bsd'
-         if conf.CHECK_CODE('''
-                            #define %s 1
-diff --git a/wscript b/wscript
-index 8ae5be3..a178cc4 100644
---- a/wscript
-+++ b/wscript
-@@ -31,6 +31,13 @@ def set_options(opt):
-     opt.RECURSE('lib/replace')
-     opt.tool_options('python') # options for disabling pyc or pyo compilation
- 
-+    opt.add_option('--with-valgrind',
-+                   help=("enable use of valgrind"),
-+                   action="store_true", dest='enable_valgrind')
-+    opt.add_option('--without-valgrind',
-+                   help=("disable use of valgrind"),
-+                   action="store_false", dest='enable_valgrind', default=False)
-+
- def configure(conf):
-     conf.RECURSE('lib/tdb')
-     conf.RECURSE('lib/tevent')
--- 
-2.16.2
-
diff --git a/meta-openembedded/meta-networking/recipes-support/libldb/libldb/options-1.4.1.patch b/meta-openembedded/meta-networking/recipes-support/libldb/libldb/options-1.4.1.patch
new file mode 100644
index 0000000..357afbe
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/libldb/libldb/options-1.4.1.patch
@@ -0,0 +1,184 @@
+From ffffd29bc6303d60b3d77048fbbf6776f6fbbe01 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Thu, 19 Jul 2018 16:40:31 +0800
+Subject: [PATCH] ldb: Add configure options for packages
+
+Add configure options for the following packages:
+ - acl
+ - attr
+ - libaio
+ - libbsd
+ - libcap
+ - valgrind
+
+Upstream-Status: Inappropriate [oe deterministic build specific]
+
+Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
+
+Update to version 1.4.1, and fix one configure error
+
+Cross answers file cross-answers-i586.txt is incomplete with 
+"Checking for a 64-bit host to support lmdb: UNKNOWN"
+
+we don't support lmdb, so only check when lmdb is support
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ lib/replace/wscript | 94 ++++++++++++++++++++++++++++++++++++++++-------------
+ wscript             |  6 ++++
+ 2 files changed, 77 insertions(+), 23 deletions(-)
+
+diff --git a/lib/replace/wscript b/lib/replace/wscript
+index fd00a42..434192e 100644
+--- a/lib/replace/wscript
++++ b/lib/replace/wscript
+@@ -23,6 +23,41 @@ def set_options(opt):
+     opt.PRIVATE_EXTENSION_DEFAULT('')
+     opt.RECURSE('buildtools/wafsamba')
+ 
++    opt.add_option('--with-acl',
++                   help=("Enable use of acl"),
++                   action="store_true", dest='enable_acl')
++    opt.add_option('--without-acl',
++                   help=("Disable use of acl"),
++                   action="store_false", dest='enable_acl', default=False)
++
++    opt.add_option('--with-attr',
++                   help=("Enable use of attr"),
++                   action="store_true", dest='enable_attr')
++    opt.add_option('--without-attr',
++                   help=("Disable use of attr"),
++                   action="store_false", dest='enable_attr', default=False)
++
++    opt.add_option('--with-libaio',
++                   help=("Enable use of libaio"),
++                   action="store_true", dest='enable_libaio')
++    opt.add_option('--without-libaio',
++                   help=("Disable use of libaio"),
++                   action="store_false", dest='enable_libaio', default=False)
++
++    opt.add_option('--with-libbsd',
++                   help=("Enable use of libbsd"),
++                   action="store_true", dest='enable_libbsd')
++    opt.add_option('--without-libbsd',
++                   help=("Disable use of libbsd"),
++                   action="store_false", dest='enable_libbsd', default=False)
++
++    opt.add_option('--with-libcap',
++                   help=("Enable use of libcap"),
++                   action="store_true", dest='enable_libcap')
++    opt.add_option('--without-libcap',
++                   help=("Disable use of libcap"),
++                   action="store_false", dest='enable_libcap', default=False)
++
+ @Utils.run_once
+ def configure(conf):
+     conf.RECURSE('buildtools/wafsamba')
+@@ -32,12 +67,25 @@ def configure(conf):
+     conf.DEFINE('HAVE_LIBREPLACE', 1)
+     conf.DEFINE('LIBREPLACE_NETWORK_CHECKS', 1)
+ 
+-    conf.CHECK_HEADERS('linux/types.h crypt.h locale.h acl/libacl.h compat.h')
+-    conf.CHECK_HEADERS('acl/libacl.h attr/xattr.h compat.h ctype.h dustat.h')
++    conf.CHECK_HEADERS('linux/types.h crypt.h locale.h compat.h')
++    conf.CHECK_HEADERS('compat.h ctype.h dustat.h')
+     conf.CHECK_HEADERS('fcntl.h fnmatch.h glob.h history.h krb5.h langinfo.h')
+-    conf.CHECK_HEADERS('libaio.h locale.h ndir.h pwd.h')
+-    conf.CHECK_HEADERS('shadow.h sys/acl.h')
+-    conf.CHECK_HEADERS('sys/attributes.h attr/attributes.h sys/capability.h sys/dir.h sys/epoll.h')
++    conf.CHECK_HEADERS('locale.h ndir.h pwd.h')
++    conf.CHECK_HEADERS('shadow.h')
++    conf.CHECK_HEADERS('sys/attributes.h sys/dir.h sys/epoll.h')
++
++    if Options.options.enable_acl:
++        conf.CHECK_HEADERS('acl/libacl.h sys/acl.h')
++
++    if Options.options.enable_attr:
++        conf.CHECK_HEADERS('attr/attributes.h attr/xattr.h')
++
++    if Options.options.enable_libaio:
++        conf.CHECK_HEADERS('libaio.h')
++
++    if Options.options.enable_libcap:
++        conf.CHECK_HEADERS('sys/capability.h')
++
+     conf.CHECK_HEADERS('port.h')
+     conf.CHECK_HEADERS('sys/fcntl.h sys/filio.h sys/filsys.h sys/fs/s5param.h sys/fs/vx/quota.h')
+     conf.CHECK_HEADERS('sys/id.h sys/ioctl.h sys/ipc.h sys/mman.h sys/mode.h sys/ndir.h sys/priv.h')
+@@ -108,7 +156,9 @@ def configure(conf):
+     conf.CHECK_HEADERS('sys/fileio.h sys/filesys.h sys/dustat.h sys/sysmacros.h')
+     conf.CHECK_HEADERS('xfs/libxfs.h netgroup.h')
+ 
+-    conf.CHECK_HEADERS('valgrind.h valgrind/valgrind.h valgrind/memcheck.h')
++    if Options.options.enable_valgrind:
++        conf.CHECK_HEADERS('valgrind.h valgrind/valgrind.h valgrind/memcheck.h')
++
+     conf.CHECK_HEADERS('nss_common.h nsswitch.h ns_api.h')
+     conf.CHECK_HEADERS('sys/extattr.h sys/ea.h sys/proplist.h sys/cdefs.h')
+     conf.CHECK_HEADERS('utmp.h utmpx.h lastlog.h')
+@@ -340,22 +390,20 @@ def configure(conf):
+ 
+     conf.CHECK_FUNCS('prctl dirname basename')
+ 
+-    strlcpy_in_bsd = False
+-
+-    # libbsd on some platforms provides strlcpy and strlcat
+-    if not conf.CHECK_FUNCS('strlcpy strlcat'):
+-        if conf.CHECK_FUNCS_IN('strlcpy strlcat', 'bsd', headers='bsd/string.h',
+-                               checklibc=True):
+-            strlcpy_in_bsd = True
+-    if not conf.CHECK_FUNCS('getpeereid'):
+-        conf.CHECK_FUNCS_IN('getpeereid', 'bsd', headers='sys/types.h bsd/unistd.h')
+-    if not conf.CHECK_FUNCS_IN('setproctitle', 'setproctitle', headers='setproctitle.h'):
+-        conf.CHECK_FUNCS_IN('setproctitle', 'bsd', headers='sys/types.h bsd/unistd.h')
+-    if not conf.CHECK_FUNCS('setproctitle_init'):
+-        conf.CHECK_FUNCS_IN('setproctitle_init', 'bsd', headers='sys/types.h bsd/unistd.h')
+-
+-    if not conf.CHECK_FUNCS('closefrom'):
+-        conf.CHECK_FUNCS_IN('closefrom', 'bsd', headers='bsd/unistd.h')
++    if Options.options.enable_libbsd:
++        # libbsd on some platforms provides strlcpy and strlcat
++        if not conf.CHECK_FUNCS('strlcpy strlcat'):
++            conf.CHECK_FUNCS_IN('strlcpy strlcat', 'bsd', headers='bsd/string.h',
++                    checklibc=True)
++        if not conf.CHECK_FUNCS('getpeereid'):
++            conf.CHECK_FUNCS_IN('getpeereid', 'bsd', headers='sys/types.h bsd/unistd.h')
++        if not conf.CHECK_FUNCS_IN('setproctitle', 'setproctitle', headers='setproctitle.h'):
++            conf.CHECK_FUNCS_IN('setproctitle', 'bsd', headers='sys/types.h bsd/unistd.h')
++        if not conf.CHECK_FUNCS('setproctitle_init'):
++            conf.CHECK_FUNCS_IN('setproctitle_init', 'bsd', headers='sys/types.h bsd/unistd.h')
++
++        if not conf.CHECK_FUNCS('closefrom'):
++            conf.CHECK_FUNCS_IN('closefrom', 'bsd', headers='bsd/unistd.h')
+ 
+     conf.CHECK_CODE('''
+                 struct ucred cred;
+@@ -699,7 +747,7 @@ def configure(conf):
+     # look for a method of finding the list of network interfaces
+     for method in ['HAVE_IFACE_GETIFADDRS', 'HAVE_IFACE_AIX', 'HAVE_IFACE_IFCONF', 'HAVE_IFACE_IFREQ']:
+         bsd_for_strlcpy = ''
+-        if strlcpy_in_bsd:
++        if Options.options.enable_libbsd:
+             bsd_for_strlcpy = ' bsd'
+         if conf.CHECK_CODE('''
+                            #define %s 1
+diff --git a/wscript b/wscript
+index ad91bc6..2d20fee 100644
+--- a/wscript
++++ b/wscript
+@@ -36,6 +36,12 @@ def set_options(opt):
+                    help='disable new LMDB backend for LDB',
+                    action='store_true', dest='without_ldb_lmdb', default=False)
+ 
++    opt.add_option('--with-valgrind',
++                   help=("enable use of valgrind"),
++                   action="store_true", dest='enable_valgrind')
++    opt.add_option('--without-valgrind',
++                   help=("disable use of valgrind"),
++                   action="store_false", dest='enable_valgrind', default=False)
+ 
+ def configure(conf):
+     conf.RECURSE('lib/tdb')
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/libldb/libldb_1.3.1.bb b/meta-openembedded/meta-networking/recipes-support/libldb/libldb_1.3.1.bb
deleted file mode 100644
index 7e14cde..0000000
--- a/meta-openembedded/meta-networking/recipes-support/libldb/libldb_1.3.1.bb
+++ /dev/null
@@ -1,63 +0,0 @@
-SUMMARY = "Hierarchical, reference counted memory pool system with destructors"
-HOMEPAGE = "http://ldb.samba.org"
-SECTION = "libs"
-LICENSE = "LGPL-3.0+ & LGPL-2.1+ & GPL-3.0+"
-
-DEPENDS += "libtdb libtalloc libtevent popt"
-RDEPENDS_pyldb += "python"
-
-SRC_URI = "http://samba.org/ftp/ldb/ldb-${PV}.tar.gz \
-           file://do-not-import-target-module-while-cross-compile.patch \
-           file://options-1.3.1.patch \
-          "
-
-PACKAGECONFIG ??= "\
-    ${@bb.utils.filter('DISTRO_FEATURES', 'acl', d)} \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'xattr', 'attr', '', d)} \
-"
-PACKAGECONFIG[acl] = "--with-acl,--without-acl,acl"
-PACKAGECONFIG[attr] = "--with-attr,--without-attr,attr"
-PACKAGECONFIG[ldap] = ",,openldap"
-PACKAGECONFIG[libaio] = "--with-libaio,--without-libaio,libaio"
-PACKAGECONFIG[libbsd] = "--with-libbsd,--without-libbsd,libbsd"
-PACKAGECONFIG[libcap] = "--with-libcap,--without-libcap,libcap"
-PACKAGECONFIG[valgrind] = "--with-valgrind,--without-valgrind,valgrind"
-
-SRC_URI += "${@bb.utils.contains('PACKAGECONFIG', 'ldap', '', 'file://avoid-openldap-unless-wanted.patch', d)}"
-
-LIC_FILES_CHKSUM = "file://pyldb.h;endline=24;md5=dfbd238cecad76957f7f860fbe9adade \
-                    file://man/ldb.3.xml;beginline=261;endline=262;md5=137f9fd61040c1505d1aa1019663fd08 \
-                    file://tools/ldbdump.c;endline=19;md5=a7d4fc5d1f75676b49df491575a86a42"
-
-SRC_URI[md5sum] = "e5233f202bca27f6ce8474fb8ae65983"
-SRC_URI[sha256sum] = "b19f2c9f55ae0f46aa5ebaea0bf1a47ec1ac135e1d78af0f6318cf50bf62cbd2"
-
-inherit waf-samba
-
-S = "${WORKDIR}/ldb-${PV}"
-
-EXTRA_OECONF += "--disable-rpath \
-                 --disable-rpath-install \
-                 --bundled-libraries=cmocka \
-                 --builtin-libraries=replace \
-                 --with-modulesdir=${libdir}/ldb/modules \
-                 --with-privatelibdir=${libdir}/ldb \
-                 --with-libiconv=${STAGING_DIR_HOST}${prefix}\
-                "
-
-PACKAGES =+ "pyldb pyldb-dbg pyldb-dev"
-
-NOAUTOPACKAGEDEBUG = "1"
-
-FILES_${PN} += "${libdir}/ldb/*"
-FILES_${PN}-dbg += "${bindir}/.debug/* \
-                    ${libdir}/.debug/* \
-                    ${libdir}/ldb/.debug/* \
-                    ${libdir}/ldb/modules/ldb/.debug/*"
-
-FILES_pyldb = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/* \
-               ${libdir}/libpyldb-util.so.* \
-              "
-FILES_pyldb-dbg = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/.debug \
-                   ${libdir}/.debug/libpyldb-util.so.*"
-FILES_pyldb-dev = "${libdir}/libpyldb-util.so"
diff --git a/meta-openembedded/meta-networking/recipes-support/libldb/libldb_1.4.1.bb b/meta-openembedded/meta-networking/recipes-support/libldb/libldb_1.4.1.bb
new file mode 100644
index 0000000..3c7e545
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/libldb/libldb_1.4.1.bb
@@ -0,0 +1,68 @@
+SUMMARY = "Hierarchical, reference counted memory pool system with destructors"
+HOMEPAGE = "http://ldb.samba.org"
+SECTION = "libs"
+LICENSE = "LGPL-3.0+ & LGPL-2.1+ & GPL-3.0+"
+
+DEPENDS += "libtdb libtalloc libtevent popt"
+RDEPENDS_pyldb += "python samba"
+
+SRC_URI = "http://samba.org/ftp/ldb/ldb-${PV}.tar.gz \
+           file://do-not-import-target-module-while-cross-compile.patch \
+           file://options-1.4.1.patch \
+           file://0001-libldb-fix-config-error.patch \
+           file://libldb-fix-musl-libc-unkown-type-error.patch \
+           file://libldb-fix-musl-libc-conflict-type-error.patch \
+          "
+
+PACKAGECONFIG ??= "\
+    ${@bb.utils.filter('DISTRO_FEATURES', 'acl', d)} \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'xattr', 'attr', '', d)} \
+"
+PACKAGECONFIG[acl] = "--with-acl,--without-acl,acl"
+PACKAGECONFIG[attr] = "--with-attr,--without-attr,attr"
+PACKAGECONFIG[ldap] = ",,openldap"
+PACKAGECONFIG[libaio] = "--with-libaio,--without-libaio,libaio"
+PACKAGECONFIG[libbsd] = "--with-libbsd,--without-libbsd,libbsd"
+PACKAGECONFIG[libcap] = "--with-libcap,--without-libcap,libcap"
+PACKAGECONFIG[valgrind] = "--with-valgrind,--without-valgrind,valgrind"
+
+SRC_URI += "${@bb.utils.contains('PACKAGECONFIG', 'ldap', '', 'file://avoid-openldap-unless-wanted.patch', d)}"
+
+LIC_FILES_CHKSUM = "file://pyldb.h;endline=24;md5=dfbd238cecad76957f7f860fbe9adade \
+                    file://man/ldb.3.xml;beginline=261;endline=262;md5=137f9fd61040c1505d1aa1019663fd08 \
+                    file://tools/ldbdump.c;endline=19;md5=a7d4fc5d1f75676b49df491575a86a42"
+
+SRC_URI[md5sum] = "159a1b1a56dcccf410d1bba911be6076"
+SRC_URI[sha256sum] = "2df13aa25b376b314ce24182c37691959019523de3cc5356c40c1a333b0890a2"
+
+inherit waf-samba distro_features_check
+REQUIRED_DISTRO_FEATURES = "pam"
+
+S = "${WORKDIR}/ldb-${PV}"
+
+EXTRA_OECONF += "--disable-rpath \
+                 --disable-rpath-install \
+                 --bundled-libraries=cmocka \
+                 --builtin-libraries=replace \
+                 --with-modulesdir=${libdir}/ldb/modules \
+                 --with-privatelibdir=${libdir}/ldb \
+                 --with-libiconv=${STAGING_DIR_HOST}${prefix}\
+                 --without-ldb-lmdb \
+                "
+
+PACKAGES =+ "pyldb pyldb-dbg pyldb-dev"
+
+NOAUTOPACKAGEDEBUG = "1"
+
+FILES_${PN} += "${libdir}/ldb/*"
+FILES_${PN}-dbg += "${bindir}/.debug/* \
+                    ${libdir}/.debug/* \
+                    ${libdir}/ldb/.debug/* \
+                    ${libdir}/ldb/modules/ldb/.debug/*"
+
+FILES_pyldb = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/* \
+               ${libdir}/libpyldb-util.so.* \
+              "
+FILES_pyldb-dbg = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/.debug \
+                   ${libdir}/.debug/libpyldb-util.so.*"
+FILES_pyldb-dev = "${libdir}/libpyldb-util.so"
diff --git a/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc/avoid-attr-unless-wanted.patch b/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc/avoid-attr-unless-wanted.patch
index a3ee9cc..db3ddce 100644
--- a/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc/avoid-attr-unless-wanted.patch
+++ b/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc/avoid-attr-unless-wanted.patch
@@ -1,20 +1,20 @@
 --- a/lib/replace/wscript	2015-11-13 16:04:04.000000000 +0100
 +++ b/lib/replace/wscript	2015-11-13 16:23:20.000000000 +0100
-@@ -636,8 +636,6 @@
+@@ -837,8 +837,6 @@ def build(bld):
      if not bld.CONFIG_SET('HAVE_INET_ATON'):     REPLACE_SOURCE += ' inet_aton.c'
      if not bld.CONFIG_SET('HAVE_INET_NTOP'):     REPLACE_SOURCE += ' inet_ntop.c'
      if not bld.CONFIG_SET('HAVE_INET_PTON'):     REPLACE_SOURCE += ' inet_pton.c'
 -    if not bld.CONFIG_SET('HAVE_GETXATTR') or bld.CONFIG_SET('XATTR_ADDITIONAL_OPTIONS'):
 -                                                 REPLACE_SOURCE += ' xattr.c'
  
-     bld.SAMBA_LIBRARY('replace',
-                       source=REPLACE_SOURCE,
-@@ -648,7 +646,7 @@
+     if not bld.CONFIG_SET('HAVE_CLOSEFROM'):
+         REPLACE_SOURCE += ' closefrom.c'
+@@ -852,7 +850,7 @@ def build(bld):
                        # at the moment:
                        # hide_symbols=bld.BUILTIN_LIBRARY('replace'),
                        private_library=True,
 -                      deps='crypt dl nsl socket rt attr' + extra_libs)
 +                      deps='crypt dl nsl socket rt ' + extra_libs)
  
-     bld.SAMBA_SUBSYSTEM('replace-test',
-                       source='''test/testsuite.c test/strptime.c
+     replace_test_cflags="-Wno-format-zero-length"
+     if bld.CONFIG_SET('HAVE_WNO_FORMAT_TRUNCATION'):
diff --git a/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc/options-2.1.10.patch b/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc/options-2.1.10.patch
deleted file mode 100644
index 63f21e7..0000000
--- a/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc/options-2.1.10.patch
+++ /dev/null
@@ -1,184 +0,0 @@
-From efc1b02144f23fdf84dbc5ff15307815e0f2a425 Mon Sep 17 00:00:00 2001
-From: Jackie Huang <jackie.huang@windriver.com>
-Date: Wed, 14 Sep 2016 11:11:35 +0800
-Subject: [PATCH] talloc: Add configure options for packages
-
-Add configure options for the following packages:
- - acl
- - attr
- - libaio
- - libbsd
- - libcap
- - valgrind
-
-Upstream-Status: Inappropriate [oe deterministic build specific]
-
-Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
-
-Modified to apply to version 2.1.10.
-
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
-
----
- lib/replace/system/wscript_configure |  6 ++-
- lib/replace/wscript                  | 85 ++++++++++++++++++++++++++++--------
- wscript                              |  7 ++-
- 3 files changed, 79 insertions(+), 19 deletions(-)
-
-Index: talloc-2.1.11/lib/replace/system/wscript_configure
-===================================================================
---- talloc-2.1.11.orig/lib/replace/system/wscript_configure
-+++ talloc-2.1.11/lib/replace/system/wscript_configure
-@@ -1,6 +1,10 @@
- #!/usr/bin/env python
- 
--conf.CHECK_HEADERS('sys/capability.h')
-+import Options
-+
-+if Options.options.enable_libcap:
-+    conf.CHECK_HEADERS('sys/capability.h')
-+
- conf.CHECK_FUNCS('getpwnam_r getpwuid_r getpwent_r')
- 
- # solaris varients of getXXent_r
-Index: talloc-2.1.11/lib/replace/wscript
-===================================================================
---- talloc-2.1.11.orig/lib/replace/wscript
-+++ talloc-2.1.11/lib/replace/wscript
-@@ -23,6 +23,41 @@ def set_options(opt):
-     opt.PRIVATE_EXTENSION_DEFAULT('')
-     opt.RECURSE('buildtools/wafsamba')
- 
-+    opt.add_option('--with-acl',
-+                   help=("Enable use of acl"),
-+                   action="store_true", dest='enable_acl')
-+    opt.add_option('--without-acl',
-+                   help=("Disable use of acl"),
-+                   action="store_false", dest='enable_acl', default=False)
-+
-+    opt.add_option('--with-attr',
-+                   help=("Enable use of attr"),
-+                   action="store_true", dest='enable_attr')
-+    opt.add_option('--without-attr',
-+                   help=("Disable use of attr"),
-+                   action="store_false", dest='enable_attr', default=False)
-+
-+    opt.add_option('--with-libaio',
-+                   help=("Enable use of libaio"),
-+                   action="store_true", dest='enable_libaio')
-+    opt.add_option('--without-libaio',
-+                   help=("Disable use of libaio"),
-+                   action="store_false", dest='enable_libaio', default=False)
-+
-+    opt.add_option('--with-libbsd',
-+                   help=("Enable use of libbsd"),
-+                   action="store_true", dest='enable_libbsd')
-+    opt.add_option('--without-libbsd',
-+                   help=("Disable use of libbsd"),
-+                   action="store_false", dest='enable_libbsd', default=False)
-+
-+    opt.add_option('--with-libcap',
-+                   help=("Enable use of libcap"),
-+                   action="store_true", dest='enable_libcap')
-+    opt.add_option('--without-libcap',
-+                   help=("Disable use of libcap"),
-+                   action="store_false", dest='enable_libcap', default=False)
-+
- @Utils.run_once
- def configure(conf):
-     conf.RECURSE('buildtools/wafsamba')
-@@ -32,12 +67,25 @@ def configure(conf):
-     conf.DEFINE('HAVE_LIBREPLACE', 1)
-     conf.DEFINE('LIBREPLACE_NETWORK_CHECKS', 1)
- 
--    conf.CHECK_HEADERS('linux/types.h crypt.h locale.h acl/libacl.h compat.h')
--    conf.CHECK_HEADERS('acl/libacl.h attr/xattr.h compat.h ctype.h dustat.h')
-+    conf.CHECK_HEADERS('linux/types.h crypt.h locale.h compat.h')
-+    conf.CHECK_HEADERS('compat.h ctype.h dustat.h')
-     conf.CHECK_HEADERS('fcntl.h fnmatch.h glob.h history.h krb5.h langinfo.h')
--    conf.CHECK_HEADERS('libaio.h locale.h ndir.h pwd.h')
--    conf.CHECK_HEADERS('shadow.h sys/acl.h')
--    conf.CHECK_HEADERS('sys/attributes.h attr/attributes.h sys/capability.h sys/dir.h sys/epoll.h')
-+    conf.CHECK_HEADERS('locale.h ndir.h pwd.h')
-+    conf.CHECK_HEADERS('shadow.h')
-+    conf.CHECK_HEADERS('sys/attributes.h sys/dir.h sys/epoll.h')
-+
-+    if Options.options.enable_acl:
-+        conf.CHECK_HEADERS('acl/libacl.h sys/acl.h')
-+
-+    if Options.options.enable_attr:
-+        conf.CHECK_HEADERS('attr/attributes.h attr/xattr.h')
-+
-+    if Options.options.enable_libaio:
-+        conf.CHECK_HEADERS('libaio.h')
-+
-+    if Options.options.enable_libcap:
-+        conf.CHECK_HEADERS('sys/capability.h')
-+
-     conf.CHECK_HEADERS('port.h')
-     conf.CHECK_HEADERS('sys/fcntl.h sys/filio.h sys/filsys.h sys/fs/s5param.h sys/fs/vx/quota.h')
-     conf.CHECK_HEADERS('sys/id.h sys/ioctl.h sys/ipc.h sys/mman.h sys/mode.h sys/ndir.h sys/priv.h')
-@@ -73,7 +121,9 @@ def configure(conf):
- 
-     conf.CHECK_CODE('', headers='rpc/rpc.h rpcsvc/yp_prot.h', define='HAVE_RPCSVC_YP_PROT_H')
- 
--    conf.CHECK_HEADERS('valgrind.h valgrind/valgrind.h valgrind/memcheck.h')
-+    if Options.options.enable_valgrind:
-+        conf.CHECK_HEADERS('valgrind.h valgrind/valgrind.h valgrind/memcheck.h')
-+
-     conf.CHECK_HEADERS('nss_common.h nsswitch.h ns_api.h')
-     conf.CHECK_HEADERS('sys/extattr.h sys/ea.h sys/proplist.h sys/cdefs.h')
-     conf.CHECK_HEADERS('utmp.h utmpx.h lastlog.h')
-@@ -267,21 +317,21 @@ def configure(conf):
-     conf.CHECK_FUNCS('prctl dirname basename')
- 
-     strlcpy_in_bsd = False
--
--    # libbsd on some platforms provides strlcpy and strlcat
--    if not conf.CHECK_FUNCS('strlcpy strlcat'):
--        if conf.CHECK_FUNCS_IN('strlcpy strlcat', 'bsd', headers='bsd/string.h',
-+    if Options.options.enable_libbsd:
-+        # libbsd on some platforms provides strlcpy and strlcat
-+        if not conf.CHECK_FUNCS('strlcpy strlcat'):
-+            if conf.CHECK_FUNCS_IN('strlcpy strlcat', 'bsd', headers='bsd/string.h',
-                                checklibc=True):
--            strlcpy_in_bsd = True
--    if not conf.CHECK_FUNCS('getpeereid'):
--        conf.CHECK_FUNCS_IN('getpeereid', 'bsd', headers='sys/types.h bsd/unistd.h')
--    if not conf.CHECK_FUNCS_IN('setproctitle', 'setproctitle', headers='setproctitle.h'):
--        conf.CHECK_FUNCS_IN('setproctitle', 'bsd', headers='sys/types.h bsd/unistd.h')
--    if not conf.CHECK_FUNCS('setproctitle_init'):
--        conf.CHECK_FUNCS_IN('setproctitle_init', 'bsd', headers='sys/types.h bsd/unistd.h')
-+                strlcpy_in_bsd = True
-+        if not conf.CHECK_FUNCS('getpeereid'):
-+            conf.CHECK_FUNCS_IN('getpeereid', 'bsd', headers='sys/types.h bsd/unistd.h')
-+        if not conf.CHECK_FUNCS_IN('setproctitle', 'setproctitle', headers='setproctitle.h'):
-+            conf.CHECK_FUNCS_IN('setproctitle', 'bsd', headers='sys/types.h bsd/unistd.h')
-+        if not conf.CHECK_FUNCS('setproctitle_init'):
-+            conf.CHECK_FUNCS_IN('setproctitle_init', 'bsd', headers='sys/types.h bsd/unistd.h')
- 
--    if not conf.CHECK_FUNCS('closefrom'):
--        conf.CHECK_FUNCS_IN('closefrom', 'bsd', headers='bsd/unistd.h')
-+        if not conf.CHECK_FUNCS('closefrom'):
-+            conf.CHECK_FUNCS_IN('closefrom', 'bsd', headers='bsd/unistd.h')
- 
-     conf.CHECK_CODE('''
-                 struct ucred cred;
-Index: talloc-2.1.11/wscript
-===================================================================
---- talloc-2.1.11.orig/wscript
-+++ talloc-2.1.11/wscript
-@@ -32,7 +32,12 @@ def set_options(opt):
-         opt.add_option('--enable-talloc-compat1',
-                        help=("Build talloc 1.x.x compat library [False]"),
-                        action="store_true", dest='TALLOC_COMPAT1', default=False)
--
-+        opt.add_option('--with-valgrind',
-+                       help=("enable use of valgrind"),
-+                       action="store_true", dest='enable_valgrind')
-+        opt.add_option('--without-valgrind',
-+                       help=("disable use of valgrind"),
-+                       action="store_false", dest='enable_valgrind', default=False)
- 
- def configure(conf):
-     conf.RECURSE('lib/replace')
diff --git a/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc/options-2.1.14.patch b/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc/options-2.1.14.patch
new file mode 100644
index 0000000..df45d36
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc/options-2.1.14.patch
@@ -0,0 +1,172 @@
+From 319a2a1bb46ae35fa9d66878cb08285035f0bd5f Mon Sep 17 00:00:00 2001
+From: Jackie Huang <jackie.huang@windriver.com>
+Date: Thu, 19 Jul 2018 15:41:31 +0800
+Subject: [PATCH] talloc: Add configure options for packages
+
+Add configure options for the following packages:
+ - acl
+ - attr
+ - libaio
+ - libbsd
+ - libcap
+ - valgrind
+
+Upstream-Status: Inappropriate [oe deterministic build specific]
+
+Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
+
+Modified to apply to version 2.1.10.
+
+Signed-off-by: Joe Slater <joe.slater@windriver.com>
+
+Modified tp apply to version 2.1.14
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ lib/replace/wscript | 90 +++++++++++++++++++++++++++++++++++++++++------------
+ wscript             |  7 +++++
+ 2 files changed, 77 insertions(+), 20 deletions(-)
+
+diff --git a/lib/replace/wscript b/lib/replace/wscript
+index fd00a42..a77c058 100644
+--- a/lib/replace/wscript
++++ b/lib/replace/wscript
+@@ -22,6 +22,41 @@ def set_options(opt):
+     opt.BUILTIN_DEFAULT('NONE')
+     opt.PRIVATE_EXTENSION_DEFAULT('')
+     opt.RECURSE('buildtools/wafsamba')
++   
++    opt.add_option('--with-acl',
++                   help=("Enable use of acl"),
++                   action="store_true", dest='enable_acl')
++    opt.add_option('--without-acl',
++                   help=("Disable use of acl"),
++                   action="store_false", dest='enable_acl', default=False)
++
++    opt.add_option('--with-attr',
++                   help=("Enable use of attr"),
++                   action="store_true", dest='enable_attr')
++    opt.add_option('--without-attr',
++                   help=("Disable use of attr"),
++                   action="store_false", dest='enable_attr', default=False)
++
++    opt.add_option('--with-libaio',
++                   help=("Enable use of libaio"),
++                   action="store_true", dest='enable_libaio')
++    opt.add_option('--without-libaio',
++                   help=("Disable use of libaio"),
++                   action="store_false", dest='enable_libaio', default=False)
++
++    opt.add_option('--with-libbsd',
++                   help=("Enable use of libbsd"),
++                   action="store_true", dest='enable_libbsd')
++    opt.add_option('--without-libbsd',
++                   help=("Disable use of libbsd"),
++                   action="store_false", dest='enable_libbsd', default=False)
++
++    opt.add_option('--with-libcap',
++                   help=("Enable use of libcap"),
++                   action="store_true", dest='enable_libcap')
++    opt.add_option('--without-libcap',
++                   help=("Disable use of libcap"),
++                   action="store_false", dest='enable_libcap', default=False)
+ 
+ @Utils.run_once
+ def configure(conf):
+@@ -32,12 +67,25 @@ def configure(conf):
+     conf.DEFINE('HAVE_LIBREPLACE', 1)
+     conf.DEFINE('LIBREPLACE_NETWORK_CHECKS', 1)
+ 
+-    conf.CHECK_HEADERS('linux/types.h crypt.h locale.h acl/libacl.h compat.h')
+-    conf.CHECK_HEADERS('acl/libacl.h attr/xattr.h compat.h ctype.h dustat.h')
++    conf.CHECK_HEADERS('linux/types.h crypt.h locale.h compat.h')
++    conf.CHECK_HEADERS('attr/xattr.h compat.h ctype.h dustat.h')
+     conf.CHECK_HEADERS('fcntl.h fnmatch.h glob.h history.h krb5.h langinfo.h')
+-    conf.CHECK_HEADERS('libaio.h locale.h ndir.h pwd.h')
+-    conf.CHECK_HEADERS('shadow.h sys/acl.h')
+-    conf.CHECK_HEADERS('sys/attributes.h attr/attributes.h sys/capability.h sys/dir.h sys/epoll.h')
++    conf.CHECK_HEADERS('locale.h ndir.h pwd.h')
++    conf.CHECK_HEADERS('shadow.h')
++    conf.CHECK_HEADERS('sys/attributes.h sys/dir.h sys/epoll.h')
++
++    if Options.options.enable_acl:
++        conf.CHECK_HEADERS('acl/libacl.h sys/acl.h')
++
++    if Options.options.enable_attr:
++        conf.CHECK_HEADERS('attr/attributes.h attr/xattr.h')
++
++    if Options.options.enable_libaio:
++        conf.CHECK_HEADERS('libaio.h')
++
++    if Options.options.enable_libcap:
++        conf.CHECK_HEADERS('sys/capability.h')
++
+     conf.CHECK_HEADERS('port.h')
+     conf.CHECK_HEADERS('sys/fcntl.h sys/filio.h sys/filsys.h sys/fs/s5param.h sys/fs/vx/quota.h')
+     conf.CHECK_HEADERS('sys/id.h sys/ioctl.h sys/ipc.h sys/mman.h sys/mode.h sys/ndir.h sys/priv.h')
+@@ -108,7 +156,9 @@ def configure(conf):
+     conf.CHECK_HEADERS('sys/fileio.h sys/filesys.h sys/dustat.h sys/sysmacros.h')
+     conf.CHECK_HEADERS('xfs/libxfs.h netgroup.h')
+ 
+-    conf.CHECK_HEADERS('valgrind.h valgrind/valgrind.h valgrind/memcheck.h')
++    if Options.options.enable_valgrind:
++        conf.CHECK_HEADERS('valgrind.h valgrind/valgrind.h valgrind/memcheck.h')
++
+     conf.CHECK_HEADERS('nss_common.h nsswitch.h ns_api.h')
+     conf.CHECK_HEADERS('sys/extattr.h sys/ea.h sys/proplist.h sys/cdefs.h')
+     conf.CHECK_HEADERS('utmp.h utmpx.h lastlog.h')
+@@ -342,20 +392,20 @@ def configure(conf):
+ 
+     strlcpy_in_bsd = False
+ 
+-    # libbsd on some platforms provides strlcpy and strlcat
+-    if not conf.CHECK_FUNCS('strlcpy strlcat'):
+-        if conf.CHECK_FUNCS_IN('strlcpy strlcat', 'bsd', headers='bsd/string.h',
+-                               checklibc=True):
+-            strlcpy_in_bsd = True
+-    if not conf.CHECK_FUNCS('getpeereid'):
+-        conf.CHECK_FUNCS_IN('getpeereid', 'bsd', headers='sys/types.h bsd/unistd.h')
+-    if not conf.CHECK_FUNCS_IN('setproctitle', 'setproctitle', headers='setproctitle.h'):
+-        conf.CHECK_FUNCS_IN('setproctitle', 'bsd', headers='sys/types.h bsd/unistd.h')
+-    if not conf.CHECK_FUNCS('setproctitle_init'):
+-        conf.CHECK_FUNCS_IN('setproctitle_init', 'bsd', headers='sys/types.h bsd/unistd.h')
+-
+-    if not conf.CHECK_FUNCS('closefrom'):
+-        conf.CHECK_FUNCS_IN('closefrom', 'bsd', headers='bsd/unistd.h')
++    if Options.options.enable_libbsd:
++        # libbsd on some platforms provides strlcpy and strlcat
++        if not conf.CHECK_FUNCS('strlcpy strlcat'):
++            if conf.CHECK_FUNCS_IN('strlcpy strlcat', 'bsd', headers='bsd/string.h',
++                checklibc=True):
++                strlcpy_in_bsd = True
++        if not conf.CHECK_FUNCS('getpeereid'):
++            conf.CHECK_FUNCS_IN('getpeereid', 'bsd', headers='sys/types.h bsd/unistd.h')
++        if not conf.CHECK_FUNCS_IN('setproctitle', 'setproctitle', headers='setproctitle.h'):
++            conf.CHECK_FUNCS_IN('setproctitle', 'bsd', headers='sys/types.h bsd/unistd.h')
++        if not conf.CHECK_FUNCS('setproctitle_init'):
++            conf.CHECK_FUNCS_IN('setproctitle_init', 'bsd', headers='sys/types.h bsd/unistd.h')
++        if not conf.CHECK_FUNCS('closefrom'):
++            conf.CHECK_FUNCS_IN('closefrom', 'bsd', headers='bsd/unistd.h')
+ 
+     conf.CHECK_CODE('''
+                 struct ucred cred;
+diff --git a/wscript b/wscript
+index 18f726e..fed8ab9 100644
+--- a/wscript
++++ b/wscript
+@@ -32,6 +32,13 @@ def set_options(opt):
+         opt.add_option('--enable-talloc-compat1',
+                        help=("Build talloc 1.x.x compat library [False]"),
+                        action="store_true", dest='TALLOC_COMPAT1', default=False)
++        opt.add_option('--with-valgrind',
++                       help=("enable use of valgrind"),
++                       action="store_true", dest='enable_valgrind')
++        opt.add_option('--without-valgrind',
++                       help=("disable use of valgrind"),
++                       action="store_false", dest='enable_valgrind', default=False)
++
+ 
+ 
+ def configure(conf):
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc_2.1.11.bb b/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc_2.1.11.bb
deleted file mode 100644
index 848cf4d..0000000
--- a/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc_2.1.11.bb
+++ /dev/null
@@ -1,49 +0,0 @@
-SUMMARY = "Hierarchical, reference counted memory pool system with destructors"
-HOMEPAGE = "http://talloc.samba.org"
-SECTION = "libs"
-LICENSE = "LGPL-3.0+ & GPL-3.0+"
-LIC_FILES_CHKSUM = "file://talloc.h;beginline=3;endline=27;md5=a301712782cad6dd6d5228bfa7825249 \
-                    file://pytalloc.h;beginline=1;endline=18;md5=2c498cc6f2263672483237b20f46b43d"
-
-
-SRC_URI = "https://samba.org/ftp/talloc/talloc-${PV}.tar.gz \
-           file://options-2.1.10.patch \
-"
-SRC_URI[md5sum] = "452596f904ca2b10322bdaabf147a721"
-SRC_URI[sha256sum] = "639eb35556a0af999123c4d883e79be05ff9f00ab4f9e4ac2e5775f9c5eeeed3"
-
-inherit waf-samba
-
-PACKAGECONFIG ??= "\
-    ${@bb.utils.filter('DISTRO_FEATURES', 'acl', d)} \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'xattr', 'attr', '', d)} \
-"
-PACKAGECONFIG[acl] = "--with-acl,--without-acl,acl"
-PACKAGECONFIG[attr] = "--with-attr,--without-attr,attr"
-PACKAGECONFIG[libaio] = "--with-libaio,--without-libaio,libaio"
-PACKAGECONFIG[libbsd] = "--with-libbsd,--without-libbsd,libbsd"
-PACKAGECONFIG[libcap] = "--with-libcap,--without-libcap,libcap"
-PACKAGECONFIG[valgrind] = "--with-valgrind,--without-valgrind,valgrind"
-
-SRC_URI += "${@bb.utils.contains('PACKAGECONFIG', 'attr', '', 'file://avoid-attr-unless-wanted.patch', d)}"
-
-S = "${WORKDIR}/talloc-${PV}"
-
-EXTRA_OECONF += "--disable-rpath \
-                 --disable-rpath-install \
-                 --bundled-libraries=NONE \
-                 --builtin-libraries=replace \
-                 --disable-silent-rules \
-                 --with-libiconv=${STAGING_DIR_HOST}${prefix}\
-                "
-
-PACKAGES += "pytalloc pytalloc-dbg pytalloc-dev"
-
-FILES_pytalloc = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/* \
-                  ${libdir}/libpytalloc-util.so.2 \
-                  ${libdir}/libpytalloc-util.so.2.1.1 \
-                 "
-FILES_pytalloc-dbg = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/.debug \
-                      ${libdir}/.debug/libpytalloc-util.so.2.1.1"
-FILES_pytalloc-dev = "${libdir}/libpytalloc-util.so"
-RDEPENDS_pytalloc = "python"
diff --git a/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc_2.1.14.bb b/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc_2.1.14.bb
new file mode 100644
index 0000000..9a463a6
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/libtalloc/libtalloc_2.1.14.bb
@@ -0,0 +1,49 @@
+SUMMARY = "Hierarchical, reference counted memory pool system with destructors"
+HOMEPAGE = "http://talloc.samba.org"
+SECTION = "libs"
+LICENSE = "LGPL-3.0+ & GPL-3.0+"
+LIC_FILES_CHKSUM = "file://talloc.h;beginline=3;endline=27;md5=a301712782cad6dd6d5228bfa7825249 \
+                    file://pytalloc.h;beginline=1;endline=18;md5=2c498cc6f2263672483237b20f46b43d"
+
+
+SRC_URI = "https://samba.org/ftp/talloc/talloc-${PV}.tar.gz \
+           file://options-2.1.14.patch \
+"
+SRC_URI[md5sum] = "7478da02e309316231a497a9f17a980d"
+SRC_URI[sha256sum] = "b185602756a628bac507fa8af8b9df92ace69d27c0add5dab93190ad7c3367ce"
+
+inherit waf-samba
+
+PACKAGECONFIG ??= "\
+    ${@bb.utils.filter('DISTRO_FEATURES', 'acl', d)} \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'xattr', 'attr', '', d)} \
+"
+PACKAGECONFIG[acl] = "--with-acl,--without-acl,acl"
+PACKAGECONFIG[attr] = "--with-attr,--without-attr,attr"
+PACKAGECONFIG[libaio] = "--with-libaio,--without-libaio,libaio"
+PACKAGECONFIG[libbsd] = "--with-libbsd,--without-libbsd,libbsd"
+PACKAGECONFIG[libcap] = "--with-libcap,--without-libcap,libcap"
+PACKAGECONFIG[valgrind] = "--with-valgrind,--without-valgrind,valgrind"
+
+SRC_URI += "${@bb.utils.contains('PACKAGECONFIG', 'attr', '', 'file://avoid-attr-unless-wanted.patch', d)}"
+
+S = "${WORKDIR}/talloc-${PV}"
+
+EXTRA_OECONF += "--disable-rpath \
+                 --disable-rpath-install \
+                 --bundled-libraries=NONE \
+                 --builtin-libraries=replace \
+                 --disable-silent-rules \
+                 --with-libiconv=${STAGING_DIR_HOST}${prefix}\
+                "
+
+PACKAGES += "pytalloc pytalloc-dev"
+
+RPROVIDES_${PN}-dbg += "pytalloc-dbg"
+
+FILES_pytalloc = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/* \
+                  ${libdir}/libpytalloc-util.so.2 \
+                  ${libdir}/libpytalloc-util.so.2.1.1 \
+                 "
+FILES_pytalloc-dev = "${libdir}/libpytalloc-util.so"
+RDEPENDS_pytalloc = "python"
diff --git a/meta-openembedded/meta-networking/recipes-support/libtdb/libtdb/tdb-Add-configure-options-for-packages.patch b/meta-openembedded/meta-networking/recipes-support/libtdb/libtdb/tdb-Add-configure-options-for-packages.patch
index 272921e..365b92d 100644
--- a/meta-openembedded/meta-networking/recipes-support/libtdb/libtdb/tdb-Add-configure-options-for-packages.patch
+++ b/meta-openembedded/meta-networking/recipes-support/libtdb/libtdb/tdb-Add-configure-options-for-packages.patch
@@ -1,10 +1,7 @@
-From 24911f36bcb00412e5dc4cd11fda139e09d58798 Mon Sep 17 00:00:00 2001
-From: Huang Qiyu <huangqy.fnst@cn.fujitsu.com>
-Date: Tue, 1 Aug 2017 03:12:09 +0900
-Subject: [PATCH] From 10ac5e5fdda44adcc2a159b6f9a2d51a51361057 Mon Sep 17
- 00:00:00 2001 From: Jackie Huang <jackie.huang@windriver.com> Date: Wed, 21
- Sep 2016 10:46:19 +0800 Subject: [PATCH] tdb: Add configure options for
- packages
+From 6de1affddde4003a956523c330ecf24e22e094ac Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Thu, 19 Jul 2018 16:20:32 +0800
+Subject: [PATCH] tdb: Add configure options for packages
 
 Add configure options for the following packages:
  - acl
@@ -21,30 +18,16 @@
 Update for libtdb_1.3.14.
 
 Signed-off-by: Huang Qiyu <huangqy.fnst@cn.fujitsu.com>
----
- lib/replace/system/wscript_configure |  6 ++-
- lib/replace/wscript                  | 85 ++++++++++++++++++++++++++++--------
- wscript                              |  7 ++-
- 3 files changed, 79 insertions(+), 19 deletions(-)
 
-diff --git a/lib/replace/system/wscript_configure b/lib/replace/system/wscript_configure
-index 2035474..10f9ae7 100644
---- a/lib/replace/system/wscript_configure
-+++ b/lib/replace/system/wscript_configure
-@@ -1,6 +1,10 @@
- #!/usr/bin/env python
- 
--conf.CHECK_HEADERS('sys/capability.h')
-+import Options
-+
-+if Options.options.enable_libcap:
-+    conf.CHECK_HEADERS('sys/capability.h')
-+
- conf.CHECK_FUNCS('getpwnam_r getpwuid_r getpwent_r')
- 
- # solaris varients of getXXent_r
+Update for libtdb_1.3.16
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ lib/replace/wscript | 89 +++++++++++++++++++++++++++++++++++++++++------------
+ wscript             |  6 ++++
+ 2 files changed, 75 insertions(+), 20 deletions(-)
+
 diff --git a/lib/replace/wscript b/lib/replace/wscript
-index 7c50e1d..15df5c3 100644
+index fd00a42..2df83cd 100644
 --- a/lib/replace/wscript
 +++ b/lib/replace/wscript
 @@ -23,6 +23,41 @@ def set_options(opt):
@@ -96,7 +79,7 @@
 -    conf.CHECK_HEADERS('linux/types.h crypt.h locale.h acl/libacl.h compat.h')
 -    conf.CHECK_HEADERS('acl/libacl.h attr/xattr.h compat.h ctype.h dustat.h')
 +    conf.CHECK_HEADERS('linux/types.h crypt.h locale.h compat.h')
-+    conf.CHECK_HEADERS('compat.h ctype.h dustat.h')
++    conf.CHECK_HEADERS('attr/xattr.h compat.h ctype.h dustat.h')
      conf.CHECK_HEADERS('fcntl.h fnmatch.h glob.h history.h krb5.h langinfo.h')
 -    conf.CHECK_HEADERS('libaio.h locale.h ndir.h pwd.h')
 -    conf.CHECK_HEADERS('shadow.h sys/acl.h')
@@ -120,9 +103,9 @@
      conf.CHECK_HEADERS('port.h')
      conf.CHECK_HEADERS('sys/fcntl.h sys/filio.h sys/filsys.h sys/fs/s5param.h sys/fs/vx/quota.h')
      conf.CHECK_HEADERS('sys/id.h sys/ioctl.h sys/ipc.h sys/mman.h sys/mode.h sys/ndir.h sys/priv.h')
-@@ -73,7 +121,9 @@ def configure(conf):
- 
-     conf.CHECK_CODE('', headers='rpc/rpc.h rpcsvc/yp_prot.h', define='HAVE_RPCSVC_YP_PROT_H')
+@@ -108,7 +156,9 @@ def configure(conf):
+     conf.CHECK_HEADERS('sys/fileio.h sys/filesys.h sys/dustat.h sys/sysmacros.h')
+     conf.CHECK_HEADERS('xfs/libxfs.h netgroup.h')
  
 -    conf.CHECK_HEADERS('valgrind.h valgrind/valgrind.h valgrind/memcheck.h')
 +    if Options.options.enable_valgrind:
@@ -131,18 +114,21 @@
      conf.CHECK_HEADERS('nss_common.h nsswitch.h ns_api.h')
      conf.CHECK_HEADERS('sys/extattr.h sys/ea.h sys/proplist.h sys/cdefs.h')
      conf.CHECK_HEADERS('utmp.h utmpx.h lastlog.h')
-@@ -251,17 +301,18 @@ def configure(conf):
+@@ -342,20 +392,19 @@ def configure(conf):
  
-     conf.CHECK_FUNCS('prctl dirname basename')
+     strlcpy_in_bsd = False
  
 -    # libbsd on some platforms provides strlcpy and strlcat
 -    if not conf.CHECK_FUNCS('strlcpy strlcat'):
--        conf.CHECK_FUNCS_IN('strlcpy strlcat', 'bsd', headers='bsd/string.h',
--                checklibc=True)
+-        if conf.CHECK_FUNCS_IN('strlcpy strlcat', 'bsd', headers='bsd/string.h',
+-                               checklibc=True):
+-            strlcpy_in_bsd = True
 -    if not conf.CHECK_FUNCS('getpeereid'):
 -        conf.CHECK_FUNCS_IN('getpeereid', 'bsd', headers='sys/types.h bsd/unistd.h')
 -    if not conf.CHECK_FUNCS_IN('setproctitle', 'setproctitle', headers='setproctitle.h'):
 -        conf.CHECK_FUNCS_IN('setproctitle', 'bsd', headers='sys/types.h bsd/unistd.h')
+-    if not conf.CHECK_FUNCS('setproctitle_init'):
+-        conf.CHECK_FUNCS_IN('setproctitle_init', 'bsd', headers='sys/types.h bsd/unistd.h')
 -
 -    if not conf.CHECK_FUNCS('closefrom'):
 -        conf.CHECK_FUNCS_IN('closefrom', 'bsd', headers='bsd/unistd.h')
@@ -158,18 +144,18 @@
 +
 +        if not conf.CHECK_FUNCS('closefrom'):
 +            conf.CHECK_FUNCS_IN('closefrom', 'bsd', headers='bsd/unistd.h')
++    
  
      conf.CHECK_CODE('''
                  struct ucred cred;
 diff --git a/wscript b/wscript
-index 1c9655a..8c20d3b 100644
+index 6505648..6608481 100644
 --- a/wscript
 +++ b/wscript
-@@ -62,7 +62,12 @@ def set_options(opt):
-                    help=("Disable the use of pthread robust mutexes"),
+@@ -63,6 +63,12 @@ def set_options(opt):
                     action="store_true", dest='disable_tdb_mutex_locking',
                     default=False)
--
+ 
 +    opt.add_option('--with-valgrind',
 +                   help=("enable use of valgrind"),
 +                   action="store_true", dest='enable_valgrind')
diff --git a/meta-openembedded/meta-networking/recipes-support/libtdb/libtdb_1.3.15.bb b/meta-openembedded/meta-networking/recipes-support/libtdb/libtdb_1.3.15.bb
deleted file mode 100644
index 302a306..0000000
--- a/meta-openembedded/meta-networking/recipes-support/libtdb/libtdb_1.3.15.bb
+++ /dev/null
@@ -1,44 +0,0 @@
-SUMMARY = "The tdb library"
-HOMEPAGE = "http://tdb.samba.org/"
-SECTION = "libs"
-LICENSE = "LGPL-3.0+ & GPL-3.0+"
-
-LIC_FILES_CHKSUM = "file://tools/tdbdump.c;endline=18;md5=b59cd45aa8624578126a8c98f48018c4 \
-                    file://include/tdb.h;endline=27;md5=f5bb544641d3081821bcc1dd58310be6"
-
-SRC_URI = "https://samba.org/ftp/tdb/tdb-${PV}.tar.gz \
-           file://do-not-check-xsltproc-manpages.patch \
-           file://tdb-Add-configure-options-for-packages.patch \
-"
-
-SRC_URI[md5sum] = "60ece3996acc8d85b6f713199da971a6"
-SRC_URI[sha256sum] = "b4a1bf3833601bd9f10aff363cb750860aef9ce5b4617989239923192f946728"
-
-PACKAGECONFIG ??= "\
-    ${@bb.utils.filter('DISTRO_FEATURES', 'acl', d)} \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'xattr', 'attr', '', d)} \
-"
-PACKAGECONFIG[acl] = "--with-acl,--without-acl,acl"
-PACKAGECONFIG[attr] = "--with-attr,--without-attr,attr"
-PACKAGECONFIG[libaio] = "--with-libaio,--without-libaio,libaio"
-PACKAGECONFIG[libbsd] = "--with-libbsd,--without-libbsd,libbsd"
-PACKAGECONFIG[libcap] = "--with-libcap,--without-libcap,libcap"
-PACKAGECONFIG[valgrind] = "--with-valgrind,--without-valgrind,valgrind"
-
-S = "${WORKDIR}/tdb-${PV}"
-
-inherit waf-samba
-
-EXTRA_OECONF += "--disable-rpath \
-                 --bundled-libraries=NONE \
-                 --builtin-libraries=replace \
-                 --with-libiconv=${STAGING_DIR_HOST}${prefix}\
-                "
-
-PACKAGES += "tdb-tools python-tdb python-tdb-dbg"
-
-FILES_${PN} = "${libdir}/*.so.*"
-FILES_tdb-tools = "${bindir}/*"
-FILES_python-tdb = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/*"
-FILES_python-tdb-dbg = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/.debug/*"
-RDEPENDS_python-tdb = "python"
diff --git a/meta-openembedded/meta-networking/recipes-support/libtdb/libtdb_1.3.16.bb b/meta-openembedded/meta-networking/recipes-support/libtdb/libtdb_1.3.16.bb
new file mode 100644
index 0000000..0579ed6
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/libtdb/libtdb_1.3.16.bb
@@ -0,0 +1,45 @@
+SUMMARY = "The tdb library"
+HOMEPAGE = "http://tdb.samba.org/"
+SECTION = "libs"
+LICENSE = "LGPL-3.0+ & GPL-3.0+"
+
+LIC_FILES_CHKSUM = "file://tools/tdbdump.c;endline=18;md5=b59cd45aa8624578126a8c98f48018c4 \
+                    file://include/tdb.h;endline=27;md5=f5bb544641d3081821bcc1dd58310be6"
+
+SRC_URI = "https://samba.org/ftp/tdb/tdb-${PV}.tar.gz \
+           file://do-not-check-xsltproc-manpages.patch \
+           file://tdb-Add-configure-options-for-packages.patch \
+"
+
+SRC_URI[md5sum] = "7d06d8709188e07df853d9e91db88927"
+SRC_URI[sha256sum] = "6a3fc2616567f23993984ada3cea97d953a27669ffd1bfbbe961f26e0cf96cc5"
+
+PACKAGECONFIG ??= "\
+    ${@bb.utils.filter('DISTRO_FEATURES', 'acl', d)} \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'xattr', 'attr', '', d)} \
+"
+PACKAGECONFIG[acl] = "--with-acl,--without-acl,acl"
+PACKAGECONFIG[attr] = "--with-attr,--without-attr,attr"
+PACKAGECONFIG[libaio] = "--with-libaio,--without-libaio,libaio"
+PACKAGECONFIG[libbsd] = "--with-libbsd,--without-libbsd,libbsd"
+PACKAGECONFIG[libcap] = "--with-libcap,--without-libcap,libcap"
+PACKAGECONFIG[valgrind] = "--with-valgrind,--without-valgrind,valgrind"
+
+S = "${WORKDIR}/tdb-${PV}"
+
+inherit waf-samba
+
+EXTRA_OECONF += "--disable-rpath \
+                 --bundled-libraries=NONE \
+                 --builtin-libraries=replace \
+                 --with-libiconv=${STAGING_DIR_HOST}${prefix}\
+                "
+
+PACKAGES += "tdb-tools python-tdb"
+
+RPROVIDES_${PN}-dbg += "python-tdb-dbg"
+
+FILES_${PN} = "${libdir}/*.so.*"
+FILES_tdb-tools = "${bindir}/*"
+FILES_python-tdb = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/*"
+RDEPENDS_python-tdb = "python"
diff --git a/meta-openembedded/meta-networking/recipes-support/libtevent/libtevent/0001-libtevent-fix-musl-libc-compile-error.patch b/meta-openembedded/meta-networking/recipes-support/libtevent/libtevent/0001-libtevent-fix-musl-libc-compile-error.patch
new file mode 100644
index 0000000..e3aeda9
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/libtevent/libtevent/0001-libtevent-fix-musl-libc-compile-error.patch
@@ -0,0 +1,32 @@
+From 7ba1de909c587b6773a39ba9f6f9890987f35b24 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Tue, 24 Jul 2018 11:30:53 +0800
+Subject: [PATCH] libtevent: fix musl libc compile error
+
+libldb depend on libtevent,  build libldb with musl libc,
+will report error:
+tevent.h:1440:8: error: unknown type name 'pid_t'; did you mean 'div_t'?
+
+add missing headers to fix it.
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ tevent.h | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/tevent.h b/tevent.h
+index aa6fe0d..2572696 100644
+--- a/tevent.h
++++ b/tevent.h
+@@ -32,6 +32,8 @@
+ #include <talloc.h>
+ #include <sys/time.h>
+ #include <stdbool.h>
++#include <sys/stat.h>
++#include <sys/types.h>
+ 
+ struct tevent_context;
+ struct tevent_ops;
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/libtevent/libtevent_0.9.36.bb b/meta-openembedded/meta-networking/recipes-support/libtevent/libtevent_0.9.36.bb
deleted file mode 100644
index c91b221..0000000
--- a/meta-openembedded/meta-networking/recipes-support/libtevent/libtevent_0.9.36.bb
+++ /dev/null
@@ -1,44 +0,0 @@
-SUMMARY = "Hierarchical, reference counted memory pool system with destructors"
-HOMEPAGE = "http://tevent.samba.org"
-SECTION = "libs"
-LICENSE = "LGPLv3+"
-
-DEPENDS += "libtalloc libtirpc"
-RDEPENDS_python-tevent = "python"
-
-SRC_URI = "https://samba.org/ftp/tevent/tevent-${PV}.tar.gz \
-           file://options-0.9.36.patch \
-"
-LIC_FILES_CHKSUM = "file://tevent.h;endline=26;md5=4e458d658cb25e21efc16f720e78b85a"
-
-SRC_URI[md5sum] = "87d67bca75b231814435c47bec0aff8a"
-SRC_URI[sha256sum] = "bd2b6be3fd1601ed7f176e99111e322c57d58e425cc149ee80c7dd4fed263b4c"
-
-inherit waf-samba
-
-PACKAGECONFIG ??= "\
-    ${@bb.utils.filter('DISTRO_FEATURES', 'acl', d)} \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'xattr', 'attr', '', d)} \
-"
-PACKAGECONFIG[acl] = "--with-acl,--without-acl,acl"
-PACKAGECONFIG[attr] = "--with-attr,--without-attr,attr"
-PACKAGECONFIG[libaio] = "--with-libaio,--without-libaio,libaio"
-PACKAGECONFIG[libbsd] = "--with-libbsd,--without-libbsd,libbsd"
-PACKAGECONFIG[libcap] = "--with-libcap,--without-libcap,libcap"
-PACKAGECONFIG[valgrind] = "--with-valgrind,--without-valgrind,valgrind"
-
-SRC_URI += "${@bb.utils.contains('PACKAGECONFIG', 'attr', '', 'file://avoid-attr-unless-wanted.patch', d)}"
-
-S = "${WORKDIR}/tevent-${PV}"
-
-EXTRA_OECONF += "--disable-rpath \
-                 --bundled-libraries=NONE \
-                 --builtin-libraries=replace \
-                 --with-libiconv=${STAGING_DIR_HOST}${prefix}\
-                 --without-gettext \
-                "
-
-PACKAGES += "python-tevent python-tevent-dbg"
-
-FILES_python-tevent = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/*"
-FILES_python-tevent-dbg = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/.debug"
diff --git a/meta-openembedded/meta-networking/recipes-support/libtevent/libtevent_0.9.37.bb b/meta-openembedded/meta-networking/recipes-support/libtevent/libtevent_0.9.37.bb
new file mode 100644
index 0000000..4df251c
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/libtevent/libtevent_0.9.37.bb
@@ -0,0 +1,46 @@
+SUMMARY = "Hierarchical, reference counted memory pool system with destructors"
+HOMEPAGE = "http://tevent.samba.org"
+SECTION = "libs"
+LICENSE = "LGPLv3+"
+
+DEPENDS += "libtalloc libtirpc"
+RDEPENDS_python-tevent = "python"
+
+SRC_URI = "https://samba.org/ftp/tevent/tevent-${PV}.tar.gz \
+           file://options-0.9.36.patch \
+           file://0001-libtevent-fix-musl-libc-compile-error.patch \
+"
+LIC_FILES_CHKSUM = "file://tevent.h;endline=26;md5=4e458d658cb25e21efc16f720e78b85a"
+
+SRC_URI[md5sum] = "6859cd4081fdb2a76b1cb4bf1c803a59"
+SRC_URI[sha256sum] = "168345ed65eac03785cf77b95238e7dc66cbb473a42811693a6b0916e5dae7e0"
+
+inherit waf-samba
+
+PACKAGECONFIG ??= "\
+    ${@bb.utils.filter('DISTRO_FEATURES', 'acl', d)} \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'xattr', 'attr', '', d)} \
+"
+PACKAGECONFIG[acl] = "--with-acl,--without-acl,acl"
+PACKAGECONFIG[attr] = "--with-attr,--without-attr,attr"
+PACKAGECONFIG[libaio] = "--with-libaio,--without-libaio,libaio"
+PACKAGECONFIG[libbsd] = "--with-libbsd,--without-libbsd,libbsd"
+PACKAGECONFIG[libcap] = "--with-libcap,--without-libcap,libcap"
+PACKAGECONFIG[valgrind] = "--with-valgrind,--without-valgrind,valgrind"
+
+SRC_URI += "${@bb.utils.contains('PACKAGECONFIG', 'attr', '', 'file://avoid-attr-unless-wanted.patch', d)}"
+
+S = "${WORKDIR}/tevent-${PV}"
+
+EXTRA_OECONF += "--disable-rpath \
+                 --bundled-libraries=NONE \
+                 --builtin-libraries=replace \
+                 --with-libiconv=${STAGING_DIR_HOST}${prefix}\
+                 --without-gettext \
+                "
+
+PACKAGES += "python-tevent"
+
+RPROVIDES_${PN}-dbg += "python-tevent-dbg"
+
+FILES_python-tevent = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/*"
diff --git a/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-build-0b0dce7a36fb-actually-belongs-to-v4.19.patch b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-build-0b0dce7a36fb-actually-belongs-to-v4.19.patch
new file mode 100644
index 0000000..7599b1b
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-build-0b0dce7a36fb-actually-belongs-to-v4.19.patch
@@ -0,0 +1,31 @@
+From e5952a0cdfa8b1b56a5823574835f1f771f14ae0 Mon Sep 17 00:00:00 2001
+From: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
+Date: Fri, 24 Aug 2018 09:53:00 -0300
+Subject: [PATCH] build: 0b0dce7a36fb actually belongs to v4.19
+
+Typo or not, this commit actually belongs to v4.19 and made me wonder why
+on v4.18 it didn't find this feature.
+
+Fixes: 817f0bfa248f ("build: add two defines for Peer Address Parameters extensions on sctp_paddrparams")
+Signed-off-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
+Reviewed-by: Xin Long <lucien.xin@gmail.com>
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index f55775a..5de5c76 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -101,7 +101,7 @@ LKSCTP_CHECK_TYPE([struct sctp_prinfo], [HAVE_SCTP_SENDV])
+ # added on v4.16, 30f6ebf65bc4
+ LKSCTP_CHECK_DECL([SCTP_AUTH_NO_AUTH], [HAVE_SCTP_AUTH_NO_AUTH])
+ 
+-# New members to sctp_paddrparams, added on v4.18, 0b0dce7a36fb
++# New members to sctp_paddrparams, added on v4.19, 0b0dce7a36fb
+ LKSCTP_CHECK_MEMBER([struct sctp_paddrparams.spp_ipv6_flowlabel],
+ 		    [HAVE_SCTP_SPP_IPV6_FLOWLABEL])
+ LKSCTP_CHECK_MEMBER([struct sctp_paddrparams.spp_dscp],
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-build-fix-netinet-sctp.h-not-to-be-installed.patch b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-build-fix-netinet-sctp.h-not-to-be-installed.patch
new file mode 100644
index 0000000..03c6c4f
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-build-fix-netinet-sctp.h-not-to-be-installed.patch
@@ -0,0 +1,35 @@
+From 378560050a8f93786c590cc99a55461666205b61 Mon Sep 17 00:00:00 2001
+From: Xin Long <lucien.xin@gmail.com>
+Date: Fri, 24 Aug 2018 01:13:32 +0800
+Subject: [PATCH] build: fix netinet/sctp.h not to be installed
+
+After libcnetinet_HEADERS was set to sctp.h.in, netinet/sctp.h can
+no longer be installed into ${includedir}.
+
+Since "AC_CONFIG_HEADERS([src/include/netinet/sctp.h])" is already
+added into configure.ac, there's no need to generate sctp.h by
+automake.
+
+So we simply set libcnetinet_HEADERS back to sctp.h.
+
+Fixes: 9607dd85e70a ("netinet/sctp.h: dynamically build based on system setup")
+Signed-off-by: Xin Long <lucien.xin@gmail.com>
+Signed-off-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
+---
+ src/include/netinet/Makefile.am | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+diff --git a/src/include/netinet/Makefile.am b/src/include/netinet/Makefile.am
+index ca0aac2..965db8c 100644
+--- a/src/include/netinet/Makefile.am
++++ b/src/include/netinet/Makefile.am
+@@ -11,5 +11,4 @@ libcnetinetdir = $(includedir)/netinet
+ # API.
+ include_HEADERS =
+ 
+-libcnetinet_HEADERS = sctp.h.in
+-BUILT_SOURCES = sctp.h
++libcnetinet_HEADERS = sctp.h
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-build-fix-probing-for-HAVE_SCTP_SENDV.patch b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-build-fix-probing-for-HAVE_SCTP_SENDV.patch
new file mode 100644
index 0000000..89c8983
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-build-fix-probing-for-HAVE_SCTP_SENDV.patch
@@ -0,0 +1,35 @@
+From 596efd6631b83069d41782fb0ee2d6cf76a50dfa Mon Sep 17 00:00:00 2001
+From: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
+Date: Fri, 24 Aug 2018 09:52:59 -0300
+Subject: [PATCH] build: fix probing for HAVE_SCTP_SENDV
+
+Somehow it was using a type that is non-existent. The right one is
+sctp_prinfo, introduced on ed63afb8a318 ("sctp: add support for PR-SCTP
+Information for sendmsg"), present on v4.17.
+
+Fixes: 1b798f1ca3b5 ("build: add define HAVE_SCTP_AUTH_NO_AUTH")
+Signed-off-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
+Reviewed-by: Xin Long <lucien.xin@gmail.com>
+---
+ configure.ac | 5 ++---
+ 1 file changed, 2 insertions(+), 3 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index dad658c..f55775a 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -94,9 +94,8 @@ LKSCTP_CHECK_MEMBER([struct sctp_pdapi_event.pdapi_stream],
+ LKSCTP_CHECK_MEMBER([struct sctp_pdapi_event.pdapi_seq],
+ 		    [HAVE_SCTP_PDAPI_EVENT_PDAPI_SEQ])
+ 
+-# PR-SCTP field used to probe for sendv/recvv support, added on v4.17
+-LKSCTP_CHECK_MEMBER([struct sendv_prinfo.sctp_prinfo],
+-		    [HAVE_SCTP_SENDV])
++# PR-SCTP struct used to probe for sendv/recvv support, added on v4.17
++LKSCTP_CHECK_TYPE([struct sctp_prinfo], [HAVE_SCTP_SENDV])
+ 
+ # This event indicates that the peer does not support SCTP authentication,
+ # added on v4.16, 30f6ebf65bc4
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-build-remove-v4.12-secondary-defines-in-favor-of-HAV.patch b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-build-remove-v4.12-secondary-defines-in-favor-of-HAV.patch
new file mode 100644
index 0000000..d22cda6
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-build-remove-v4.12-secondary-defines-in-favor-of-HAV.patch
@@ -0,0 +1,52 @@
+From db6d15bf12a0123e4320e5fd7cb688331dea1bdc Mon Sep 17 00:00:00 2001
+From: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
+Date: Fri, 24 Aug 2018 09:52:58 -0300
+Subject: [PATCH] build: remove v4.12 secondary defines in favor of
+ HAVE_SCTP_STREAM_RECONFIG
+
+These were backups, commented out since beginning.
+HAVE_SCTP_STREAM_RECONFIG is enough to identify that these are there, so
+lets use only one.
+
+Signed-off-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
+Reviewed-by: Xin Long <lucien.xin@gmail.com>
+---
+ configure.ac                  | 8 --------
+ src/include/netinet/sctp.h.in | 2 --
+ 2 files changed, 10 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 2ae36ec..dad658c 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -82,14 +82,6 @@ AC_CHECK_FUNCS([bzero gethostbyname gettimeofday memmove memset select socket \
+ LKSCTP_CHECK_MEMBER([struct sctp_event_subscribe.sctp_stream_reset_event],
+ 		    [HAVE_SCTP_STREAM_RESET_EVENT])
+ 
+-# Support for assoc reset event, added on v4.12, c95129d127c6
+-#LKSCTP_CHECK_MEMBER([struct sctp_event_subscribe.sctp_assoc_reset_event], \
+-#		    [HAVE_SCTP_ASSOC_RESET_EVENT])
+-
+-# Support for stream change event, added on v4.12, b444153fb5a6
+-#LKSCTP_CHECK_MEMBER([struct sctp_event_subscribe.sctp_stream_change_event], \
+-#		    [HAVE_SCTP_STREAM_CHANGE_EVENT])
+-
+ # RFC 6525 (Stream Reconf), finished on v4.12, c0d8bab6ae51
+ LKSCTP_CHECK_DECL([SCTP_RECONFIG_SUPPORTED], [HAVE_SCTP_STREAM_RECONFIG])
+ 
+diff --git a/src/include/netinet/sctp.h.in b/src/include/netinet/sctp.h.in
+index c049077..2009f1c 100644
+--- a/src/include/netinet/sctp.h.in
++++ b/src/include/netinet/sctp.h.in
+@@ -61,8 +61,6 @@ extern "C" {
+ #define HAVE_SCTP_CANSET_PRIMARY
+ 
+ #undef HAVE_SCTP_STREAM_RESET_EVENT
+-#undef HAVE_SCTP_ASSOC_RESET_EVENT
+-#undef HAVE_SCTP_STREAM_CHANGE_EVENT
+ #undef HAVE_SCTP_STREAM_RECONFIG
+ #undef HAVE_SCTP_PEELOFF_FLAGS
+ #undef HAVE_SCTP_PDAPI_EVENT_PDAPI_STREAM
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-configure.ac-add-CURRENT-REVISION-and-AGE-for-libsct.patch b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-configure.ac-add-CURRENT-REVISION-and-AGE-for-libsct.patch
new file mode 100644
index 0000000..bec9bf0
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-configure.ac-add-CURRENT-REVISION-and-AGE-for-libsct.patch
@@ -0,0 +1,71 @@
+From 7de2bd7e769f10521e3d0c2cb42c6f6b9b505dd0 Mon Sep 17 00:00:00 2001
+From: Xin Long <lucien.xin@gmail.com>
+Date: Thu, 16 Aug 2018 14:12:30 +0800
+Subject: [PATCH] configure.ac: add CURRENT REVISION and AGE for libsctp and
+ libwithsctp
+
+Add CURRENT REVISION and AGE for libsctp and libwithsctp in
+configure.ac to update these 2 library version information.
+
+Compatible with before, they will start from 1:18:0. But each
+will get updated according to their definitions in the future.
+
+Signed-off-by: Xin Long <lucien.xin@gmail.com>
+Acked-by: Neil Horman <nhorman@tuxdriver.com>
+Signed-off-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
+---
+ configure.ac             | 7 +++++++
+ src/lib/Makefile.am      | 7 +++++--
+ src/withsctp/Makefile.am | 3 ++-
+ 3 files changed, 14 insertions(+), 3 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 275ef4e..2ae36ec 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -14,6 +14,13 @@ dnl reduce clutter in the root; if we put it below AM_INIT_AUTOMAKE,
+ dnl configure will fail ...)
+ 
+ AC_INIT([lksctp-tools], [1.0.18], [], [], [http://www.lksctp.org/])
++AC_SUBST(LIBSCTP_CURRENT, 1)
++AC_SUBST(LIBSCTP_REVISION, 18)
++AC_SUBST(LIBSCTP_AGE, 0)
++AC_SUBST(LIBWITHSCTP_CURRENT, 1)
++AC_SUBST(LIBWITHSCTP_REVISION, 18)
++AC_SUBST(LIBWITHSCTP_AGE, 0)
++
+ AC_CONFIG_AUX_DIR(bin)
+ AC_CONFIG_SRCDIR([src/apps/sctp_darn.c])
+ AC_CONFIG_HEADERS([config.h])
+diff --git a/src/lib/Makefile.am b/src/lib/Makefile.am
+index 6100c56..1d62175 100644
+--- a/src/lib/Makefile.am
++++ b/src/lib/Makefile.am
+@@ -8,5 +8,8 @@ AM_CPPFLAGS = -I$(top_srcdir)/src/include
+ 
+ lib_LTLIBRARIES = libsctp.la
+ 
+-libsctp_la_SOURCES = bindx.c connectx.c peeloff.c opt_info.c addrs.c sendmsg.c recvmsg.c Versions.map
+-libsctp_la_LDFLAGS = -version-info 1:17:0 -Wl,--version-script=$(srcdir)/Versions.map
++libsctp_la_SOURCES = bindx.c connectx.c peeloff.c opt_info.c \
++		addrs.c sendmsg.c recvmsg.c Versions.map
++libsctp_la_LDFLAGS = -version-info \
++		@LIBSCTP_CURRENT@:@LIBSCTP_REVISION@:@LIBSCTP_AGE@ \
++		-Wl,--version-script=$(srcdir)/Versions.map
+diff --git a/src/withsctp/Makefile.am b/src/withsctp/Makefile.am
+index 70b1cca..1f6ca37 100644
+--- a/src/withsctp/Makefile.am
++++ b/src/withsctp/Makefile.am
+@@ -14,7 +14,8 @@ AM_CPPFLAGS=-I$(top_srcdir)/src/include
+ pkglib_LTLIBRARIES = libwithsctp.la
+ libwithsctp_la_SOURCES = sctp_load_libs.c sctp_socket.c sctp_bind.c \
+ 	sctp_sockopt.c sctp_socket.h
+-libwithsctp_la_LDFLAGS = -version-info 1:17:0 -ldl
++libwithsctp_la_LDFLAGS = -version-info \
++	@LIBWITHSCTP_CURRENT@:@LIBWITHSCTP_REVISION@:@LIBWITHSCTP_AGE@ -ldl
+ 
+ pkgdoc_DATA = sctp_load_libs.c sctp_socket.c sctp_bind.c \
+ 	sctp_sockopt.c sctp_socket.h checksctp.c
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-test_1_to_1_events.c-initialize-event-properly.patch b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-test_1_to_1_events.c-initialize-event-properly.patch
new file mode 100644
index 0000000..621e6f4
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-test_1_to_1_events.c-initialize-event-properly.patch
@@ -0,0 +1,44 @@
+From e1e670defb84d51efdd124e5f3fa166a1a4b7c1d Mon Sep 17 00:00:00 2001
+From: Mingli Yu <Mingli.Yu@windriver.com>
+Date: Tue, 25 Sep 2018 11:39:43 +0800
+Subject: [PATCH] test_1_to_1_events.c: initialize event properly
+
+Initialize event properly to avoid below
+Segmentation fault when run below test
+related to AUTH_NO_AUTH.
+
+ # ./test_1_to_1_events
+test_1_to_1_events.c 1 PASS : COMM_UP notification on client socket - SUCCESS
+test_1_to_1_events.c 2 PASS : COMM_UP notification on server socket - SUCCESS
+test_1_to_1_events.c 3 BROK : Got a datamsg, expecting notification
+DUMP_CORE sctputil.c: 187
+[ 1468.733938] test_1_to_1_eve[2376]: segfault at 0 ip 0000561a4a3d5079 sp 00007ffd49101580 error 6 in test_1_to_1_events[561a4a3d4000+2000]
+[ 1468.734479] Code: ff bf 0a 00 00 00 e8 e6 ef ff ff b9 c9 00 00 00 48 8d 15 61 13 00 00 bf 01 00 00 00 31 c0 48 8d 35 c7 0f 00 00 e8 97 f0
+Segmentation fault
+
+Upstream-Status: Pending
+
+Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
+---
+ src/func_tests/test_1_to_1_events.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/src/func_tests/test_1_to_1_events.c b/src/func_tests/test_1_to_1_events.c
+index 46439bf..a086832 100644
+--- a/src/func_tests/test_1_to_1_events.c
++++ b/src/func_tests/test_1_to_1_events.c
+@@ -92,9 +92,11 @@ main(int argc, char *argv[])
+ 	/* Create the client socket.  */
+ 	clt_sk = test_socket(AF_INET, SOCK_STREAM, IPPROTO_SCTP);
+ 
++	memset(&event, 0, sizeof(event));
+ 	event.sctp_data_io_event = 1;
+ 	event.sctp_association_event = 1;
+ 	event.sctp_shutdown_event = 1;
++	event.sctp_authentication_event = 1;
+ 	len = sizeof(struct sctp_event_subscribe);
+ 	test_setsockopt(svr_sk, SCTP_EVENTS, &event, len);
+ 	test_setsockopt(clt_sk, SCTP_EVENTS, &event, len);
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-withsctp-use-PACKAGE_VERSION-in-withsctp.h.patch b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-withsctp-use-PACKAGE_VERSION-in-withsctp.h.patch
new file mode 100644
index 0000000..2537bb9
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools/0001-withsctp-use-PACKAGE_VERSION-in-withsctp.h.patch
@@ -0,0 +1,43 @@
+From 7c0ef4d441b3833e721df58f56e2cb8c81b34df4 Mon Sep 17 00:00:00 2001
+From: Xin Long <lucien.xin@gmail.com>
+Date: Thu, 16 Aug 2018 14:12:01 +0800
+Subject: [PATCH] withsctp: use @PACKAGE_VERSION@ in withsctp.h
+
+use @PACKAGE_VERSION@ to replace the hardcode version.
+
+Signed-off-by: Xin Long <lucien.xin@gmail.com>
+Acked-by: Neil Horman <nhorman@tuxdriver.com>
+Signed-off-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
+---
+ Makefile.rules           | 3 ++-
+ src/withsctp/withsctp.in | 3 ++-
+ 2 files changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/Makefile.rules b/Makefile.rules
+index 83f5f0c..d3693fa 100644
+--- a/Makefile.rules
++++ b/Makefile.rules
+@@ -15,4 +15,5 @@
+ edit = @sed \
+ 	-e "s|\@bindir\@|$(bindir)|" \
+ 	-e "s|\@libdir\@|$(libdir)|" \
+-	-e "s|\@PACKAGE\@|$(PACKAGE)|"
++	-e "s|\@PACKAGE\@|$(PACKAGE)|" \
++	-e "s|\@PACKAGE_VERSION\@|$(PACKAGE_VERSION)|"
+diff --git a/src/withsctp/withsctp.in b/src/withsctp/withsctp.in
+index 7f182ba..fda5ebc 100644
+--- a/src/withsctp/withsctp.in
++++ b/src/withsctp/withsctp.in
+@@ -2,7 +2,8 @@
+ # -*- sh -*-
+ LIBDIR=@libdir@/@PACKAGE@
+ BINDIR=@bindir@
+-export LD_PRELOAD=${LIBDIR}/libwithsctp.so.1.0.17
++LIBVER=@PACKAGE_VERSION@
++export LD_PRELOAD=${LIBDIR}/libwithsctp.so.${LIBVER}
+ if ! ${BINDIR}/checksctp 2> /dev/null
+ then
+     ${BINDIR}/checksctp;
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools_1.0.17.bb b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools_1.0.17.bb
deleted file mode 100644
index 121cc99..0000000
--- a/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools_1.0.17.bb
+++ /dev/null
@@ -1,62 +0,0 @@
-SUMMARY = "The Linux Kernel Stream Control Transmission Protocol (lksctp) project"
-HOMEPAGE = "http://lksctp.org"
-SECTION = "net"
-LICENSE = "LGPLv2.1 & GPLv2"
-
-LIC_FILES_CHKSUM = " \
-    file://COPYING.lib;md5=0a1b79af951c42a9c8573533fbba9a92 \
-    file://COPYING;md5=0c56db0143f4f80c369ee3af7425af6e \
-"
-
-SRCREV = "736b91d340e3f2519714f2930ed63b164d363511"
-
-PV .= "+git${SRCPV}"
-LK_REL = "1.0.17"
-
-SRC_URI = " \
-    git://github.com/sctp/lksctp-tools.git \
-    file://run-ptest \
-    file://v4test.sh \
-    file://v6test.sh \
-"
-
-S = "${WORKDIR}/git"
-
-BBCLASSEXTEND = "native"
-
-inherit autotools pkgconfig binconfig ptest
-
-do_install_ptest () {
-    install -m 0755 ${WORKDIR}/v4test.sh ${D}${PTEST_PATH}
-    install -m 0755 ${WORKDIR}/v6test.sh ${D}${PTEST_PATH}
-    for testcase in `find ${B}/src/apps/.libs ${B}/src/func_tests/.libs -maxdepth 1 -type f -executable`; do
-        install $testcase ${D}${PTEST_PATH}
-    done
-}
-
-SOLIBVERSION="${LK_REL}"
-SOLIBMAJORVERSION="1"
-
-PACKAGES =+ "${PN}-withsctp ${PN}-utils"
-
-FILES_${PN} = " \
-    ${libdir}/libsctp.so.${SOLIBVERSION} \
-    ${libdir}/libsctp.so.${SOLIBMAJORVERSION} \
-"
-
-FILES_${PN}-withsctp = " \
-    ${libdir}/lksctp-tools/libwithsctp.so.${SOLIBVERSION} \
-    ${libdir}/lksctp-tools/libwithsctp.so.${SOLIBMAJORVERSION} \
-"
-
-FILES_${PN}-dev += " \
-    ${libdir}/libsctp.so \
-    ${libdir}/lksctp-tools/libwithsctp.so \
-    ${datadir}/lksctp-tools/*.c \
-    ${datadir}/lksctp-tools/*.h \
-"
-
-FILES_${PN}-utils = "${bindir}/*"
-
-RRECOMMENDS_${PN}-utils += "kernel-module-sctp"
-RRECOMMENDS_${PN}-ptest += "kernel-module-sctp"
diff --git a/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools_1.0.18.bb b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools_1.0.18.bb
new file mode 100644
index 0000000..70cea6c
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/lksctp-tools/lksctp-tools_1.0.18.bb
@@ -0,0 +1,69 @@
+SUMMARY = "The Linux Kernel Stream Control Transmission Protocol (lksctp) project"
+HOMEPAGE = "http://lksctp.org"
+SECTION = "net"
+LICENSE = "LGPLv2.1 & GPLv2"
+
+LIC_FILES_CHKSUM = " \
+    file://COPYING.lib;md5=0a1b79af951c42a9c8573533fbba9a92 \
+    file://COPYING;md5=0c56db0143f4f80c369ee3af7425af6e \
+"
+
+SRCREV = "1b077af62d83d53c34b1bde8bad6648149d5edf9"
+
+PV .= "+git${SRCPV}"
+LK_REL = "1.0.18"
+
+SRC_URI = " \
+    git://github.com/sctp/lksctp-tools.git \
+    file://0001-withsctp-use-PACKAGE_VERSION-in-withsctp.h.patch \
+    file://0001-configure.ac-add-CURRENT-REVISION-and-AGE-for-libsct.patch \
+    file://0001-build-fix-netinet-sctp.h-not-to-be-installed.patch \
+    file://0001-build-remove-v4.12-secondary-defines-in-favor-of-HAV.patch \
+    file://0001-build-fix-probing-for-HAVE_SCTP_SENDV.patch \
+    file://0001-build-0b0dce7a36fb-actually-belongs-to-v4.19.patch \
+    file://0001-test_1_to_1_events.c-initialize-event-properly.patch \
+    file://run-ptest \
+    file://v4test.sh \
+    file://v6test.sh \
+"
+
+S = "${WORKDIR}/git"
+
+BBCLASSEXTEND = "native"
+
+inherit autotools-brokensep pkgconfig binconfig ptest
+
+do_install_ptest () {
+    install -m 0755 ${WORKDIR}/v4test.sh ${D}${PTEST_PATH}
+    install -m 0755 ${WORKDIR}/v6test.sh ${D}${PTEST_PATH}
+    for testcase in `find ${B}/src/apps/.libs ${B}/src/func_tests/.libs -maxdepth 1 -type f -executable`; do
+        install $testcase ${D}${PTEST_PATH}
+    done
+}
+
+SOLIBVERSION="${LK_REL}"
+SOLIBMAJORVERSION="1"
+
+PACKAGES =+ "${PN}-withsctp ${PN}-utils"
+
+FILES_${PN} = " \
+    ${libdir}/libsctp.so.${SOLIBVERSION} \
+    ${libdir}/libsctp.so.${SOLIBMAJORVERSION} \
+"
+
+FILES_${PN}-withsctp = " \
+    ${libdir}/lksctp-tools/libwithsctp.so.${SOLIBVERSION} \
+    ${libdir}/lksctp-tools/libwithsctp.so.${SOLIBMAJORVERSION} \
+"
+
+FILES_${PN}-dev += " \
+    ${libdir}/libsctp.so \
+    ${libdir}/lksctp-tools/libwithsctp.so \
+    ${datadir}/lksctp-tools/*.c \
+    ${datadir}/lksctp-tools/*.h \
+"
+
+FILES_${PN}-utils = "${bindir}/*"
+
+RRECOMMENDS_${PN}-utils += "kernel-module-sctp"
+RRECOMMENDS_${PN}-ptest += "kernel-module-sctp"
diff --git a/meta-openembedded/meta-networking/recipes-support/lowpan-tools/lowpan-tools/0001-Fix-potential-string-truncation-in-strncpy.patch b/meta-openembedded/meta-networking/recipes-support/lowpan-tools/lowpan-tools/0001-Fix-potential-string-truncation-in-strncpy.patch
new file mode 100644
index 0000000..e621d8f
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/lowpan-tools/lowpan-tools/0001-Fix-potential-string-truncation-in-strncpy.patch
@@ -0,0 +1,139 @@
+From 58b6d9a2efe101e5b80fd708e6f84c7ca779ce93 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 31 May 2018 20:27:43 -0700
+Subject: [PATCH] Fix potential string truncation in strncpy()
+
+GCC 8 complains about the string truncation during copy
+
+error: 'strncpy' specified bound 16 equals destination size
+
+Upstream-Status: Inappropriate [depricated component]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ tests/listen-packet.c | 3 ++-
+ tests/listen.c        | 3 ++-
+ tests/test2.c         | 4 ++--
+ tests/test3.c         | 3 ++-
+ tests/test4.c         | 3 ++-
+ tests/test5.c         | 3 ++-
+ tests/test6.c         | 3 ++-
+ tests/test7.c         | 3 ++-
+ 8 files changed, 16 insertions(+), 9 deletions(-)
+
+diff --git a/tests/listen-packet.c b/tests/listen-packet.c
+index e40af81..eae0c71 100644
+--- a/tests/listen-packet.c
++++ b/tests/listen-packet.c
+@@ -50,7 +50,8 @@ int main(int argc, char **argv) {
+ 		return 1;
+ 	}
+ 
+-	strncpy(req.ifr_name, iface, IF_NAMESIZE);
++	strncpy(req.ifr_name, iface, IF_NAMESIZE - 1);
++	req.ifr_name[IF_NAMESIZE - 1] = '\0';
+ 	ret = ioctl(sd, SIOCGIFINDEX, &req);
+ 	if (ret < 0)
+ 		perror("ioctl: SIOCGIFINDEX");
+diff --git a/tests/listen.c b/tests/listen.c
+index 75c320b..5ce1ed9 100644
+--- a/tests/listen.c
++++ b/tests/listen.c
+@@ -47,7 +47,8 @@ int main(int argc, char **argv) {
+ 		return 1;
+ 	}
+ 
+-	strncpy(req.ifr_name, iface, IFNAMSIZ);
++	strncpy(req.ifr_name, iface, IFNAMSIZ - 1);
++	req.ifr_name[IF_NAMESIZE - 1] = '\0';
+ 	ret = ioctl(sd, SIOCGIFHWADDR, &req);
+ 	if (ret < 0)
+ 		perror("ioctl: SIOCGIFHWADDR");
+diff --git a/tests/test2.c b/tests/test2.c
+index 58eb74b..5d02838 100644
+--- a/tests/test2.c
++++ b/tests/test2.c
+@@ -45,8 +45,8 @@ int main(int argc, char **argv) {
+ 		perror("socket");
+ 		return 1;
+ 	}
+-
+-	strncpy(req.ifr_name, argv[1] ?: "wpan0", IF_NAMESIZE);
++	strncpy(req.ifr_name, argv[1] ?: "wpan0", IF_NAMESIZE - 1);
++	req.ifr_name[IF_NAMESIZE - 1] = '\0';
+ 	ret = ioctl(sd, SIOCGIFHWADDR, &req);
+ 	if (ret < 0)
+ 		perror("ioctl: SIOCGIFHWADDR");
+diff --git a/tests/test3.c b/tests/test3.c
+index fb36627..2f50a5a 100644
+--- a/tests/test3.c
++++ b/tests/test3.c
+@@ -46,7 +46,8 @@ int main(int argc, char **argv) {
+ 		return 1;
+ 	}
+ 
+-	strncpy(req.ifr_name, argv[1] ?: "wpan0", IF_NAMESIZE);
++	strncpy(req.ifr_name, argv[1] ?: "wpan0", IF_NAMESIZE - 1);
++	req.ifr_name[IF_NAMESIZE - 1] = '\0';
+ 	ret = ioctl(sd, SIOCGIFHWADDR, &req);
+ 	if (ret < 0)
+ 		perror("ioctl: SIOCGIFHWADDR");
+diff --git a/tests/test4.c b/tests/test4.c
+index 33c274c..8737149 100644
+--- a/tests/test4.c
++++ b/tests/test4.c
+@@ -46,7 +46,8 @@ int main(int argc, char **argv) {
+ 		return 1;
+ 	}
+ 
+-	strncpy(req.ifr_name, argv[1] ?: "wpan0", IF_NAMESIZE);
++	strncpy(req.ifr_name, argv[1] ?: "wpan0", IF_NAMESIZE - 1);
++	req.ifr_name[IF_NAMESIZE - 1] = '\0';
+ 	ret = ioctl(sd, SIOCGIFHWADDR, &req);
+ 	if (ret < 0)
+ 		perror("ioctl: SIOCGIFHWADDR");
+diff --git a/tests/test5.c b/tests/test5.c
+index 4439dfa..28db562 100644
+--- a/tests/test5.c
++++ b/tests/test5.c
+@@ -45,7 +45,8 @@ int main(int argc, char **argv) {
+ 		return 1;
+ 	}
+ 
+-	strncpy(req.ifr_name, argv[1] ?: "wpan0", IF_NAMESIZE);
++	strncpy(req.ifr_name, argv[1] ?: "wpan0", IF_NAMESIZE - 1);
++	req.ifr_name[IF_NAMESIZE - 1] = '\0';
+ 	ret = ioctl(sd, SIOCGIFADDR, &req);
+ 	if (ret < 0) {
+ 		perror("ioctl: SIOCGIFADDR");
+diff --git a/tests/test6.c b/tests/test6.c
+index e375bfb..ce7de59 100644
+--- a/tests/test6.c
++++ b/tests/test6.c
+@@ -45,7 +45,8 @@ int main(int argc, char **argv) {
+ 		return 1;
+ 	}
+ 
+-	strncpy(req.ifr_name, argv[1] ?: "wpan0", IF_NAMESIZE);
++	strncpy(req.ifr_name, argv[1] ?: "wpan0", IF_NAMESIZE - 1);
++	req.ifr_name[IF_NAMESIZE - 1] = '\0';
+ 	ret = ioctl(sd, SIOCGIFADDR, &req);
+ 	if (ret < 0) {
+ 		perror("ioctl: SIOCGIFADDR");
+diff --git a/tests/test7.c b/tests/test7.c
+index e9a5a55..37da22d 100644
+--- a/tests/test7.c
++++ b/tests/test7.c
+@@ -58,7 +58,8 @@ int main(int argc, char **argv) {
+ 	if (ret)
+ 		perror("setsockopt");
+ 
+-	strncpy(req.ifr_name, argv[1] ?: "wpan0", IF_NAMESIZE);
++	strncpy(req.ifr_name, argv[1] ?: "wpan0", IF_NAMESIZE - 1);
++	req.ifr_name[IF_NAMESIZE - 1] = '\0';
+ 	ret = ioctl(sd, SIOCGIFHWADDR, &req);
+ 	if (ret < 0)
+ 		perror("ioctl: SIOCGIFHWADDR");
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-networking/recipes-support/lowpan-tools/lowpan-tools_git.bb b/meta-openembedded/meta-networking/recipes-support/lowpan-tools/lowpan-tools_git.bb
index d0fe59c..b70c43f 100644
--- a/meta-openembedded/meta-networking/recipes-support/lowpan-tools/lowpan-tools_git.bb
+++ b/meta-openembedded/meta-networking/recipes-support/lowpan-tools/lowpan-tools_git.bb
@@ -15,6 +15,7 @@
            file://0001-src-iz.c-Undef-dprintf-before-redefining.patch \
            file://0001-Remove-newline-from-format-line.patch \
            file://0001-coordinator-Fix-strncpy-range-warning.patch \
+           file://0001-Fix-potential-string-truncation-in-strncpy.patch \
            "
 SRCREV = "1c2d8674cc6f4b1166a066e8822e295c105ae7a2"
 
diff --git a/meta-openembedded/meta-networking/recipes-support/memcached/memcached_1.5.0.bb b/meta-openembedded/meta-networking/recipes-support/memcached/memcached_1.5.0.bb
deleted file mode 100644
index fd3d171..0000000
--- a/meta-openembedded/meta-networking/recipes-support/memcached/memcached_1.5.0.bb
+++ /dev/null
@@ -1,52 +0,0 @@
-SUMMARY = "A high-performance memory object caching system"
-DESCRIPTION = "\
- memcached optimizes specific high-load serving applications that are designed \
- to take advantage of its versatile no-locking memory access system. Clients \
- are available in several different programming languages, to suit the needs \
- of the specific application. Traditionally this has been used in mod_perl \
- apps to avoid storing large chunks of data in Apache memory, and to share \
- this burden across several machines."
-SECTION = "web"
-HOMEPAGE = "http://memcached.org/"
-LICENSE = "BSD-3-Clause"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=7e5ded7363d335e1bb18013ca08046ff"
-
-inherit autotools
-
-DEPENDS += "libevent"
-RDEPENDS_${PN} += "perl perl-module-posix perl-module-autoloader \
-    perl-module-tie-hash bash \
-    "
-
-SRC_URI = "http://www.memcached.org/files/${BP}.tar.gz \
-           file://memcached-add-hugetlbfs-check.patch \
-           "
-SRC_URI[md5sum] = "81326513f60d7ba482f8131975cd55ae"
-SRC_URI[sha256sum] = "c001f812024bb461b5e4d7d0506daab63dff9614eea26f46536c3b7e1e601c32"
-
-# set the same COMPATIBLE_HOST as libhugetlbfs
-COMPATIBLE_HOST = '(i.86|x86_64|powerpc|powerpc64|arm).*-linux'
-
-python __anonymous () {
-    endianness = d.getVar('SITEINFO_ENDIANNESS')
-    if endianness == 'le':
-        d.appendVar('EXTRA_OECONF', " ac_cv_c_endian=little")
-    else:
-        d.appendVar('EXTRA_OECONF', " ac_cv_c_endian=big")
-}
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[hugetlbfs] = "--enable-hugetlbfs, --disable-hugetlbfs, libhugetlbfs"
-
-inherit update-rc.d
-
-INITSCRIPT_NAME = "memcached"
-INITSCRIPT_PARAMS = "defaults"
-
-do_install_append() {
-    install -D -m 755 ${S}/scripts/memcached-init ${D}${sysconfdir}/init.d/memcached
-    mkdir -p ${D}/usr/share/memcached/scripts
-    install -m 755 ${S}/scripts/memcached-tool ${D}/usr/share/memcached/scripts
-    install -m 755 ${S}/scripts/start-memcached ${D}/usr/share/memcached/scripts
-}
diff --git a/meta-openembedded/meta-networking/recipes-support/memcached/memcached_1.5.10.bb b/meta-openembedded/meta-networking/recipes-support/memcached/memcached_1.5.10.bb
new file mode 100644
index 0000000..d2cafc9
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/memcached/memcached_1.5.10.bb
@@ -0,0 +1,52 @@
+SUMMARY = "A high-performance memory object caching system"
+DESCRIPTION = "\
+ memcached optimizes specific high-load serving applications that are designed \
+ to take advantage of its versatile no-locking memory access system. Clients \
+ are available in several different programming languages, to suit the needs \
+ of the specific application. Traditionally this has been used in mod_perl \
+ apps to avoid storing large chunks of data in Apache memory, and to share \
+ this burden across several machines."
+SECTION = "web"
+HOMEPAGE = "http://memcached.org/"
+LICENSE = "BSD-3-Clause"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=7e5ded7363d335e1bb18013ca08046ff"
+
+inherit autotools
+
+DEPENDS += "libevent"
+RDEPENDS_${PN} += "perl perl-module-posix perl-module-autoloader \
+    perl-module-tie-hash bash \
+    "
+
+SRC_URI = "http://www.memcached.org/files/${BP}.tar.gz \
+           file://memcached-add-hugetlbfs-check.patch \
+           "
+SRC_URI[md5sum] = "8462616b554183a75845b03c56837cca"
+SRC_URI[sha256sum] = "494c060dbd96d546c74ab85a3cc3984d009b4423767ac33e05dd2340c01f1c4b"
+
+# set the same COMPATIBLE_HOST as libhugetlbfs
+COMPATIBLE_HOST = '(i.86|x86_64|powerpc|powerpc64|arm).*-linux'
+
+python __anonymous () {
+    endianness = d.getVar('SITEINFO_ENDIANNESS')
+    if endianness == 'le':
+        d.appendVar('EXTRA_OECONF', " ac_cv_c_endian=little")
+    else:
+        d.appendVar('EXTRA_OECONF', " ac_cv_c_endian=big")
+}
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[hugetlbfs] = "--enable-hugetlbfs, --disable-hugetlbfs, libhugetlbfs"
+
+inherit update-rc.d
+
+INITSCRIPT_NAME = "memcached"
+INITSCRIPT_PARAMS = "defaults"
+
+do_install_append() {
+    install -D -m 755 ${S}/scripts/memcached-init ${D}${sysconfdir}/init.d/memcached
+    mkdir -p ${D}/usr/share/memcached/scripts
+    install -m 755 ${S}/scripts/memcached-tool ${D}/usr/share/memcached/scripts
+    install -m 755 ${S}/scripts/start-memcached ${D}/usr/share/memcached/scripts
+}
diff --git a/meta-openembedded/meta-networking/recipes-support/nbd/nbd_3.11.bb b/meta-openembedded/meta-networking/recipes-support/nbd/nbd_3.11.bb
deleted file mode 100644
index 2ad75bd..0000000
--- a/meta-openembedded/meta-networking/recipes-support/nbd/nbd_3.11.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-DESCRIPTION = "Network Block Device"
-HOMEPAGE = "http://nbd.sourceforge.net"
-SECTION = "net"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-
-DEPENDS = "glib-2.0"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BPN}-${PV}.tar.xz"
-SRC_URI[md5sum] = "73d11644a28b9f335292cdb3bdc4b74b"
-SRC_URI[sha256sum] = "14420f74cb16dc609a9302ed1efd653064bed7a8357e9d73daabc33608e3f2a0"
-
-inherit autotools pkgconfig
-
-PACKAGES = "${PN}-client ${PN}-server ${PN}-dbg ${PN}-trdump ${PN}-doc"
-
-FILES_${PN}-client = "${sbindir}/${BPN}-client"
-FILES_${PN}-server = "${bindir}/${BPN}-server"
-FILES_${PN}-trdump = "${bindir}/${BPN}-trdump"
diff --git a/meta-openembedded/meta-networking/recipes-support/nbd/nbd_3.17.bb b/meta-openembedded/meta-networking/recipes-support/nbd/nbd_3.17.bb
new file mode 100644
index 0000000..3560236
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/nbd/nbd_3.17.bb
@@ -0,0 +1,19 @@
+DESCRIPTION = "Network Block Device"
+HOMEPAGE = "http://nbd.sourceforge.net"
+SECTION = "net"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+DEPENDS = "glib-2.0"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BPN}-${PV}.tar.xz"
+SRC_URI[md5sum] = "98b74c655ed94a66686c5ba19480d98e"
+SRC_URI[sha256sum] = "d95c6bb1a3ab33b953af99b73fb4833e123bd25433513b32d57dbeb1a0a0d189"
+
+inherit autotools pkgconfig
+
+PACKAGES = "${PN}-client ${PN}-server ${PN}-dbg ${PN}-trdump ${PN}-doc"
+
+FILES_${PN}-client = "${sbindir}/${BPN}-client"
+FILES_${PN}-server = "${bindir}/${BPN}-server"
+FILES_${PN}-trdump = "${bindir}/${BPN}-trdump"
diff --git a/meta-openembedded/meta-networking/recipes-support/ndisc6/ndisc6_git.bb b/meta-openembedded/meta-networking/recipes-support/ndisc6/ndisc6_git.bb
index cebc1d9..ec48797 100644
--- a/meta-openembedded/meta-networking/recipes-support/ndisc6/ndisc6_git.bb
+++ b/meta-openembedded/meta-networking/recipes-support/ndisc6/ndisc6_git.bb
@@ -19,13 +19,10 @@
 
 EXTRA_OECONF += "PERL=${USRBINPATH}/perl"
 
-LDFLAGS += "-fuse-ld=gold"
-LDFLAGS_remove_riscv64 = "-fuse-ld=gold"
-
-TOOLCHAIN = "gcc"
-
 USE_NLS = "yes"
 
+EXTRA_OECONF += "--disable-rpath"
+
 do_configure_prepend() {
     cp ${STAGING_DATADIR_NATIVE}/gettext/gettext.h ${S}/include
     ${S}/autogen.sh
diff --git a/meta-openembedded/meta-networking/recipes-support/netcat/netcat-openbsd/0001-bundle-own-base64-encode-decode-functions.patch b/meta-openembedded/meta-networking/recipes-support/netcat/netcat-openbsd/0001-bundle-own-base64-encode-decode-functions.patch
index 0966b65..929f63f 100644
--- a/meta-openembedded/meta-networking/recipes-support/netcat/netcat-openbsd/0001-bundle-own-base64-encode-decode-functions.patch
+++ b/meta-openembedded/meta-networking/recipes-support/netcat/netcat-openbsd/0001-bundle-own-base64-encode-decode-functions.patch
@@ -1,40 +1,47 @@
-From ccd166b73eaae4dd1e1785c63ceb9b303568ed46 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 21 Mar 2017 11:30:49 -0700
+From 3da48ec13a44b71ca51adbc803b42c1b29a43f57 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Tue, 24 Jul 2018 14:03:51 +0800
 Subject: [PATCH] bundle own base64 encode/decode functions
 
 Not all libc implementations provide it.
 as an aside libresolv is no longer needed
 
+Upstream-Status: Pending
+
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Update to version 1.190-2
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
 ---
  Makefile |   4 +-
  base64.c | 313 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- netcat.c |   2 +
+ netcat.c |   3 +
  socks.c  |   3 +
- 4 files changed, 320 insertions(+), 2 deletions(-)
+ 4 files changed, 321 insertions(+), 2 deletions(-)
  create mode 100644 base64.c
 
-Index: netcat-openbsd-1.105/Makefile
-===================================================================
---- netcat-openbsd-1.105.orig/Makefile
-+++ netcat-openbsd-1.105/Makefile
-@@ -1,9 +1,9 @@
- #       $OpenBSD: Makefile,v 1.6 2001/09/02 18:45:41 jakob Exp $
+diff --git a/Makefile b/Makefile
+index 8247cfd..b8d8547 100644
+--- a/Makefile
++++ b/Makefile
+@@ -1,10 +1,10 @@
+ #	$OpenBSD: Makefile,v 1.7 2015/09/11 21:07:01 beck Exp $
  
  PROG=	nc
 -SRCS=	netcat.c atomicio.c socks.c
 +SRCS=	netcat.c atomicio.c socks.c base64.c
  
--LIBS=  `pkg-config --libs libbsd` -lresolv
-+LIBS=  `pkg-config --libs libbsd`
+ PKG_CONFIG ?= pkg-config
+-LIBS=  `$(PKG_CONFIG) --libs libbsd` -lresolv
++LIBS=  `$(PKG_CONFIG) --libs libbsd`
  OBJS=  $(SRCS:.c=.o)
  CFLAGS=  -g -O2
  LDFLAGS=  -Wl,--no-add-needed
-Index: netcat-openbsd-1.105/base64.c
-===================================================================
+diff --git a/base64.c b/base64.c
+new file mode 100644
+index 0000000..b0ee6c2
 --- /dev/null
-+++ netcat-openbsd-1.105/base64.c
++++ b/base64.c
 @@ -0,0 +1,313 @@
 +/*
 + * Copyright (c) 1996-1999 by Internet Software Consortium.
@@ -349,31 +356,34 @@
 +
 +	return (tarindex);
 +}
-Index: netcat-openbsd-1.105/netcat.c
-===================================================================
---- netcat-openbsd-1.105.orig/netcat.c
-+++ netcat-openbsd-1.105/netcat.c
-@@ -169,6 +169,9 @@ static int connect_with_timeout(int fd,
-         socklen_t salen, int ctimeout);
+diff --git a/netcat.c b/netcat.c
+index a0fb51b..9c4ed23 100644
+--- a/netcat.c
++++ b/netcat.c
+@@ -240,6 +240,9 @@ static int connect_with_timeout(int fd, const struct sockaddr *sa,
+ 
  static void quit();
  
-+int	b64_ntop(u_char const *src, size_t srclength, char *target, size_t targsize);
-+int	b64_pton(char const *src, u_char *target, size_t targsize);
++int    b64_ntop(u_char const *src, size_t srclength, char *target, size_t targsize);
++int    b64_pton(char const *src, u_char *target, size_t targsize);
 +
  int
  main(int argc, char *argv[])
  {
-Index: netcat-openbsd-1.105/socks.c
-===================================================================
---- netcat-openbsd-1.105.orig/socks.c
-+++ netcat-openbsd-1.105/socks.c
+diff --git a/socks.c b/socks.c
+index 9068f39..c576f6b 100644
+--- a/socks.c
++++ b/socks.c
 @@ -53,6 +53,9 @@
  #define SOCKS_DOMAIN	3
  #define SOCKS_IPV6	4
  
-+int	b64_ntop(u_char const *src, size_t srclength, char *target, size_t targsize);
-+int	b64_pton(char const *src, u_char *target, size_t targsize);
++int    b64_ntop(u_char const *src, size_t srclength, char *target, size_t targsize);
++int    b64_pton(char const *src, u_char *target, size_t targsize);
 +
  int	remote_connect(const char *, const char *, struct addrinfo);
  int	socks_connect(const char *, const char *, struct addrinfo,
  	    const char *, const char *, struct addrinfo, int,
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/netcat/netcat-openbsd_1.105.bb b/meta-openembedded/meta-networking/recipes-support/netcat/netcat-openbsd_1.105.bb
deleted file mode 100644
index 9d7420f..0000000
--- a/meta-openembedded/meta-networking/recipes-support/netcat/netcat-openbsd_1.105.bb
+++ /dev/null
@@ -1,56 +0,0 @@
-require netcat.inc
-SUMMARY = "OpenBSD Netcat"
-HOMEPAGE = "http://ftp.debian.org"
-LICENSE = "BSD-3-Clause"
-LIC_FILES_CHKSUM = "file://debian/copyright;md5=ee6bbaacb5db5f2973818f0902c3ae6f"
-
-DEPENDS += "glib-2.0 libbsd"
-do_patch[depends] = "quilt-native:do_populate_sysroot"
-
-SRC_URI = "${DEBIAN_MIRROR}/main/n/netcat-openbsd/netcat-openbsd_${PV}.orig.tar.gz;name=netcat \
-           ${DEBIAN_MIRROR}/main/n/netcat-openbsd/netcat-openbsd_${PV}-7.debian.tar.gz;name=netcat-patch;subdir=${BP} \
-           file://0001-bundle-own-base64-encode-decode-functions.patch \
-           "
-
-SRC_URI[netcat.md5sum] = "7e67b22f1ad41a1b7effbb59ff28fca1"
-SRC_URI[netcat.sha256sum] = "40653fe66c1516876b61b07e093d826e2a5463c5d994f1b7e6ce328f3edb211e"
-SRC_URI[netcat-patch.md5sum] = "e914f8eb7eda5c75c679dd77787ac76b"
-SRC_URI[netcat-patch.sha256sum] = "eee759327ffea293e81d0dde67921b7fcfcad279ffd7a2c9d037bbc8f882b363"
-
-inherit pkgconfig
-
-EXTRA_OEMAKE += "'LDFLAGS=${LDFLAGS}'"
-
-do_configure[noexec] = "1"
-
-netcat_do_patch() {
-    cd ${S}
-    quilt pop -a || true
-    if [ -d ${S}/.pc-netcat ]; then
-            rm -rf ${S}/.pc
-            mv ${S}/.pc-netcat ${S}/.pc
-            QUILT_PATCHES=${S}/debian/patches quilt pop -a
-            rm -rf ${S}/.pc ${S}/debian
-    fi
-    QUILT_PATCHES=${S}/debian/patches quilt push -a
-    mv ${S}/.pc ${S}/.pc-netcat
-}
-
-do_unpack[cleandirs] += "${S}"
-
-python do_patch() {
-    bb.build.exec_func('netcat_do_patch', d)
-    bb.build.exec_func('patch_do_patch', d)
-}
-
-do_compile() {
-    cd ${S}
-    pkgrel=4
-    oe_runmake CFLAGS="$CFLAGS -DDEBIAN_VERSION=\"\\\"${pkgrel}\\\"\""
-}
-
-do_install() {
-    install -d ${D}${bindir}
-    install -m 755 ${S}/nc ${D}${bindir}/nc.${BPN}
-}
-ALTERNATIVE_PRIORITY = "60"
diff --git a/meta-openembedded/meta-networking/recipes-support/netcat/netcat-openbsd_1.190.bb b/meta-openembedded/meta-networking/recipes-support/netcat/netcat-openbsd_1.190.bb
new file mode 100644
index 0000000..defc05c
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/netcat/netcat-openbsd_1.190.bb
@@ -0,0 +1,56 @@
+require netcat.inc
+SUMMARY = "OpenBSD Netcat"
+HOMEPAGE = "http://ftp.debian.org"
+LICENSE = "BSD-2-Clause"
+LIC_FILES_CHKSUM = "file://debian/copyright;md5=f39e60ae4ea9fdb559c833be2e59de99"
+
+DEPENDS += "glib-2.0 libbsd"
+do_patch[depends] = "quilt-native:do_populate_sysroot"
+
+SRC_URI = "https://launchpad.net/ubuntu/+archive/primary/+sourcefiles/netcat-openbsd/1.190-2/netcat-openbsd_${PV}.orig.tar.gz;name=netcat \
+           https://launchpad.net/ubuntu/+archive/primary/+sourcefiles/netcat-openbsd/1.190-2/netcat-openbsd_${PV}-2.debian.tar.xz;name=netcat-patch;subdir=${BP} \
+           file://0001-bundle-own-base64-encode-decode-functions.patch \
+           "
+
+SRC_URI[netcat.md5sum] = "dd32fd1d7903b541ad8709794539b959"
+SRC_URI[netcat.sha256sum] = "68ccc448392c05ec51baed0167a72b8c650454f990b895d6e6877d416a38e536"
+SRC_URI[netcat-patch.md5sum] = "78058b7af0170654b877b02c37716cdf"
+SRC_URI[netcat-patch.sha256sum] = "88088af3f520c7825e59bc133d65e70fc4a30139d451c6faabbd9f240bc78374"
+
+inherit pkgconfig
+
+EXTRA_OEMAKE += "'LDFLAGS=${LDFLAGS}'"
+
+do_configure[noexec] = "1"
+
+netcat_do_patch() {
+    cd ${S}
+    quilt pop -a || true
+    if [ -d ${S}/.pc-netcat ]; then
+            rm -rf ${S}/.pc
+            mv ${S}/.pc-netcat ${S}/.pc
+            QUILT_PATCHES=${S}/debian/patches quilt pop -a
+            rm -rf ${S}/.pc
+    fi
+    QUILT_PATCHES=${S}/debian/patches quilt push -a
+    mv ${S}/.pc ${S}/.pc-netcat
+}
+
+do_unpack[cleandirs] += "${S}"
+
+python do_patch() {
+    bb.build.exec_func('netcat_do_patch', d)
+    bb.build.exec_func('patch_do_patch', d)
+}
+
+do_compile() {
+    cd ${S}
+    pkgrel=4
+    oe_runmake CFLAGS="$CFLAGS -DDEBIAN_VERSION=\"\\\"${pkgrel}\\\"\""
+}
+
+do_install() {
+    install -d ${D}${bindir}
+    install -m 755 ${S}/nc ${D}${bindir}/nc.${BPN}
+}
+ALTERNATIVE_PRIORITY = "60"
diff --git a/meta-openembedded/meta-networking/recipes-support/netcf/netcf_0.2.8.bb b/meta-openembedded/meta-networking/recipes-support/netcf/netcf_0.2.8.bb
index 9a6f60e..a4a9c91 100644
--- a/meta-openembedded/meta-networking/recipes-support/netcf/netcf_0.2.8.bb
+++ b/meta-openembedded/meta-networking/recipes-support/netcf/netcf_0.2.8.bb
@@ -12,6 +12,8 @@
 SRC_URI = "git://pagure.io/netcf.git;protocol=https \
 "
 
+UPSTREAM_CHECK_GITTAGREGEX = "release-(?P<pver>(\d+(\.\d+)+))"
+
 DEPENDS += "augeas libnl libxslt libxml2 gnulib"
 
 S = "${WORKDIR}/git"
diff --git a/meta-openembedded/meta-networking/recipes-support/netperf/files/0001-netlib.c-Move-including-sched.h-out-og-function.patch b/meta-openembedded/meta-networking/recipes-support/netperf/files/0001-netlib.c-Move-including-sched.h-out-og-function.patch
new file mode 100644
index 0000000..515737c
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/netperf/files/0001-netlib.c-Move-including-sched.h-out-og-function.patch
@@ -0,0 +1,50 @@
+From 51a092ebb36dcc6180ceb93a9777258e826d9990 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 26 Sep 2018 18:11:10 -0700
+Subject: [PATCH] netlib.c: Move including sched.h out og function
+
+The shutdown_control() has this code where system headers are being
+included inside function body and this results in compile errors on musl
+especially when sched.h is included because sched.h defines a macro
+which defines a static function. This means it ends up being a static
+function inside another function and compiler calls it out
+
+In function 'bind_to_specific_processor':
+|
+/mnt/a/yoe/build/tmp/work/i586-yoe-linux-musl/netperf/2.7.0+git999-r0/recipe-sysroot/usr/include/sched.h:102:1:
+error: invalid storage class for function '__CPU_AND_S'
+|  __CPU_op_func_S(AND, &)
+|  ^~~~~~~~~~~~~~~
+
+Moving the definition out of function definition fixes the problem
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/netlib.c | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git a/src/netlib.c b/src/netlib.c
+index 9258424..60b032d 100644
+--- a/src/netlib.c
++++ b/src/netlib.c
+@@ -2262,6 +2262,10 @@ shutdown_control()
+ 
+ }
+ 
++#if HAVE_SCHED_SETAFFINITY
++#include <sched.h>
++#endif
++
+ /*
+   bind_to_specific_processor will bind the calling process to the
+   processor in "processor"  It has lots of ugly ifdefs to deal with
+@@ -2308,7 +2312,6 @@ bind_to_specific_processor(int processor_affinity, int use_cpu_map)
+      value will not tell you if you are bound vs unbound. */
+   bindprocessor(BINDPROCESS,getpid(),(cpu_t)mapped_affinity);
+ #elif HAVE_SCHED_SETAFFINITY
+-#include <sched.h>
+   /* in theory this should cover systems with more CPUs than bits in a
+      long, without having to specify __USE_GNU.  we "cheat" by taking
+      defines from /usr/include/bits/sched.h, which we ass-u-me is
diff --git a/meta-openembedded/meta-networking/recipes-support/netperf/netperf_git.bb b/meta-openembedded/meta-networking/recipes-support/netperf/netperf_git.bb
index f0e0f9c..8921ea7 100644
--- a/meta-openembedded/meta-networking/recipes-support/netperf/netperf_git.bb
+++ b/meta-openembedded/meta-networking/recipes-support/netperf/netperf_git.bb
@@ -8,10 +8,12 @@
 
 PV = "2.7.0+git${SRCPV}"
 
-SRC_URI="git://github.com/HewlettPackard/netperf.git \
-         file://cpu_set.patch \
-         file://vfork.patch \
-         file://init"
+SRC_URI = "git://github.com/HewlettPackard/netperf.git \
+           file://cpu_set.patch \
+           file://vfork.patch \
+           file://init \
+           file://0001-netlib.c-Move-including-sched.h-out-og-function.patch \
+           "
 
 SRCREV = "f482bab49fcedee46fc5b755da127f608325cd13"
 
diff --git a/meta-openembedded/meta-networking/recipes-support/nis/yp-tools_4.2.3.bb b/meta-openembedded/meta-networking/recipes-support/nis/yp-tools_4.2.3.bb
index 4e27e32..bb40166 100644
--- a/meta-openembedded/meta-networking/recipes-support/nis/yp-tools_4.2.3.bb
+++ b/meta-openembedded/meta-networking/recipes-support/nis/yp-tools_4.2.3.bb
@@ -20,7 +20,7 @@
 
 S = "${WORKDIR}/git"
 
-DEPENDS = "libtirpc libnsl2"
+DEPENDS = "libtirpc libnsl2 virtual/crypt"
 
 inherit autotools systemd
 SYSTEMD_SERVICE_${PN} = "domainname.service"
diff --git a/meta-openembedded/meta-networking/recipes-support/ntop/ntop/0001-plugins-Makefile.am-fix-for-automake-1.16.1.patch b/meta-openembedded/meta-networking/recipes-support/ntop/ntop/0001-plugins-Makefile.am-fix-for-automake-1.16.1.patch
new file mode 100644
index 0000000..d6f7eb5
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/ntop/ntop/0001-plugins-Makefile.am-fix-for-automake-1.16.1.patch
@@ -0,0 +1,74 @@
+From d22ddc73f00ed056032a635ee8379305ec83bf81 Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Wed, 11 Jul 2018 12:02:50 +0800
+Subject: [PATCH] plugins/Makefile.am: fix for automake 1.16.1
+
+Fixed:
+| i586-poky-linux-gcc: error: netflowPlugin.o: No such file or directory
+| i586-poky-linux-gcc: error: unrecognized command line option '-flat_namespace'; did you mean '-Wnamespaces'?
+| i586-poky-linux-gcc: fatal error: no input files
+
+The previous code make things complicated, but we don't have to, let libtool do
+most of the things can fix the problem.
+
+Upstream-Status: Pending [ntop is not longer maintained any more, we need consider moving to ntopng]
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ plugins/Makefile.am | 34 ++++++----------------------------
+ 1 file changed, 6 insertions(+), 28 deletions(-)
+
+diff --git a/plugins/Makefile.am b/plugins/Makefile.am
+index 64492e0..bcd0c10 100644
+--- a/plugins/Makefile.am
++++ b/plugins/Makefile.am
+@@ -69,40 +69,18 @@ libsflowPlugin_la_CFLAGS = $(AM_CFLAGS)
+ # by default ntop looks for plugins in the plugins/ subdirectory
+ #
+ 
+-
+-.libs/libnetflowPlugin.so@SO_VERSION_PATCH@:
+-	@if test -f libnetflowPlugin_la-netflowPlugin.o; then \
+-	$(CC) @MAKE_SHARED_LIBRARY_PARM@ -o .libs/libnetflowPlugin.so@SO_VERSION_PATCH@ libnetflowPlugin_la-netflowPlugin.o; \
+-	else \
+-	$(CC) @MAKE_SHARED_LIBRARY_PARM@ -o .libs/libnetflowPlugin.so@SO_VERSION_PATCH@ netflowPlugin.o; \
+-	fi
+-
+-netflowPlugin.so$(EXEEXT): .libs/libnetflowPlugin.so@SO_VERSION_PATCH@
+-	@$(LN_S) .libs/libnetflowPlugin.so netflowPlugin.so
++netflowPlugin.so$(EXEEXT): libnetflowPlugin.la
++	@$(LN_S) -f .libs/libnetflowPlugin.so netflowPlugin.so
+ 
+ ###############
+ 
+-.libs/librrdPlugin.so@SO_VERSION_PATCH@:
+-	@if test -f librrdPlugin_la-rrdPlugin.o; then \
+-	$(CC) @MAKE_SHARED_LIBRARY_PARM@ -o .libs/librrdPlugin.so@SO_VERSION_PATCH@ librrdPlugin_la-rrdPlugin.o; \
+-	else \
+-	$(CC) @MAKE_SHARED_LIBRARY_PARM@ -o .libs/librrdPlugin.so@SO_VERSION_PATCH@ rrdPlugin.o; \
+-	fi
+-
+-rrdPlugin.so$(EXEEXT): .libs/librrdPlugin.so@SO_VERSION_PATCH@
+-	@$(LN_S) .libs/librrdPlugin.so rrdPlugin.so
++rrdPlugin.so$(EXEEXT): librrdPlugin.la
++	@$(LN_S) -f .libs/librrdPlugin.so rrdPlugin.so
+ 
+ ###############
+ 
+-.libs/libsflowPlugin.so@SO_VERSION_PATCH@:
+-	@if test -f libsflowPlugin_la-sflowPlugin.o; then \
+-	$(CC) @MAKE_SHARED_LIBRARY_PARM@ -o .libs/libsflowPlugin.so@SO_VERSION_PATCH@ libsflowPlugin_la-sflowPlugin.o; \
+-	else \
+-	$(CC) @MAKE_SHARED_LIBRARY_PARM@ -o .libs/libsflowPlugin.so@SO_VERSION_PATCH@ sflowPlugin.o; \
+-	fi
+-
+-sflowPlugin.so$(EXEEXT): .libs/libsflowPlugin.so@SO_VERSION_PATCH@
+-	@$(LN_S) .libs/libsflowPlugin.so sflowPlugin.so
++sflowPlugin.so$(EXEEXT): libsflowPlugin.la
++	@$(LN_S) -f .libs/libsflowPlugin.so sflowPlugin.so
+ 
+ ###############
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/ntop/ntop_5.0.1.bb b/meta-openembedded/meta-networking/recipes-support/ntop/ntop_5.0.1.bb
index 298fbec..2a7a7f2 100644
--- a/meta-openembedded/meta-networking/recipes-support/ntop/ntop_5.0.1.bb
+++ b/meta-openembedded/meta-networking/recipes-support/ntop/ntop_5.0.1.bb
@@ -17,10 +17,13 @@
            file://ntop.service \
            file://use-static-inline.patch \
            file://0001-nDPI-Include-sys-types.h.patch \
+           file://0001-plugins-Makefile.am-fix-for-automake-1.16.1.patch \
           "
 SRC_URI[md5sum] = "01710b6925a8a5ffe1a41b8b512ebd69"
 SRC_URI[sha256sum] = "7e8e84cb14d2173beaca4d4cb991a14d84a4bef84ec37b2276bc363f45c52ef8"
 
+UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/ntop/files/ntop/Stable"
+
 inherit autotools-brokensep useradd pythonnative pkgconfig systemd
 
 DEPENDS = "geoip rrdtool python zlib libpcap gdbm"
diff --git a/meta-openembedded/meta-networking/recipes-support/ntp/ntp/reproducibility-fixed-path-to-posix-shell.patch b/meta-openembedded/meta-networking/recipes-support/ntp/ntp/reproducibility-fixed-path-to-posix-shell.patch
new file mode 100644
index 0000000..571db75
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/ntp/ntp/reproducibility-fixed-path-to-posix-shell.patch
@@ -0,0 +1,15 @@
+--- ntp-4.2.8p12.original/sntp/libopts/m4/libopts.m4	2018-11-12 17:54:57.747220846 +1300
++++ ntp-4.2.8p12/sntp/libopts/m4/libopts.m4	2018-11-12 18:00:50.626211641 +1300
+@@ -114,12 +114,6 @@
+   AC_PROG_SED
+   [while :
+   do
+-      POSIX_SHELL=`which bash`
+-      test -x "$POSIX_SHELL" && break
+-      POSIX_SHELL=`which dash`
+-      test -x "$POSIX_SHELL" && break
+-      POSIX_SHELL=/usr/xpg4/bin/sh
+-      test -x "$POSIX_SHELL" && break
+       POSIX_SHELL=`/bin/sh -c '
+           exec 2>/dev/null
+           if ! true ; then exit 1 ; fi
diff --git a/meta-openembedded/meta-networking/recipes-support/ntp/ntp/reproducibility-respect-source-date-epoch.patch b/meta-openembedded/meta-networking/recipes-support/ntp/ntp/reproducibility-respect-source-date-epoch.patch
new file mode 100644
index 0000000..58e71c3
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/ntp/ntp/reproducibility-respect-source-date-epoch.patch
@@ -0,0 +1,16 @@
+--- ntp-4.2.8p12.original/scripts/build/mkver.in	2018-11-12 14:06:49.333020430 +1300
++++ ntp-4.2.8p12/scripts/build/mkver.in	2018-11-12 14:15:04.947480167 +1300
+@@ -15,7 +15,12 @@
+  *) ConfStr="${ConfStr}-@VER_SUFFIX@" ;;
+ esac
+ 
+-ConfStr="$ConfStr `LC_TIME=C TZ=UTC date`"
++if [ -n "$SOURCE_DATE_EPOCH" ]; then
++   ConfStr="$ConfStr `LC_TIME=C TZ=UTC date -d@$SOURCE_DATE_EPOCH 2>/dev/null`" ||
++   ConfStr="$ConfStr `LC_TIME=C TZ=UTC date -r $SOURCE_DATE_EPOCH`"
++else
++   ConfStr="$ConfStr `LC_TIME=C TZ=UTC date`"
++fi
+ 
+ if [ ! -f .version ]; then
+   echo 0 > .version
diff --git a/meta-openembedded/meta-networking/recipes-support/ntp/ntp_4.2.8p11.bb b/meta-openembedded/meta-networking/recipes-support/ntp/ntp_4.2.8p11.bb
deleted file mode 100644
index c698fa0..0000000
--- a/meta-openembedded/meta-networking/recipes-support/ntp/ntp_4.2.8p11.bb
+++ /dev/null
@@ -1,172 +0,0 @@
-SUMMARY = "Network Time Protocol daemon and utilities"
-DESCRIPTION = "The Network Time Protocol (NTP) is used to \
-synchronize the time of a computer client or server to \
-another server or reference time source, such as a radio \
-or satellite receiver or modem."
-HOMEPAGE = "http://support.ntp.org"
-SECTION = "net"
-LICENSE = "NTP"
-LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=e877a1d567a6a58996d2b66e3e387003"
-
-DEPENDS = "libevent"
-
-SRC_URI = "http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-4.2/ntp-${PV}.tar.gz \
-           file://ntp-4.2.4_p6-nano.patch \
-           file://ntpd \
-           file://ntp.conf \
-           file://ntpdate \
-           file://ntpdate.default \
-           file://ntpdate.service \
-           file://ntpd.service \
-           file://sntp.service \
-           file://sntp \
-           file://ntpd.list \
-"
-
-SRC_URI[md5sum] = "00950ca2855579541896513e78295361"
-SRC_URI[sha256sum] = "f14a39f753688252d683ff907035ffff106ba8d3db21309b742e09b5c3cd278e"
-
-inherit autotools update-rc.d useradd systemd pkgconfig
-
-# The ac_cv_header_readline_history is to stop ntpdc depending on either
-# readline or curses
-EXTRA_OECONF += "--with-net-snmp-config=no \
-                 --without-ntpsnmpd \
-                 ac_cv_header_readline_history_h=no \
-                 --with-yielding_select=yes \
-                 --with-locfile=redhat \
-                 --without-rpath \
-                 "
-CFLAGS_append = " -DPTYS_ARE_GETPT -DPTYS_ARE_SEARCHED"
-
-USERADD_PACKAGES = "${PN}"
-NTP_USER_HOME ?= "/var/lib/ntp"
-USERADD_PARAM_${PN} = "--system --home-dir ${NTP_USER_HOME} \
-                       --no-create-home \
-                       --shell /bin/false --user-group ntp"
-
-# NB: debug is default-enabled by NTP; keep it default-enabled here.
-PACKAGECONFIG ??= "cap debug refclocks openssl \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} \
-"
-PACKAGECONFIG[openssl] = "--with-openssl-libdir=${STAGING_LIBDIR} \
-                          --with-openssl-incdir=${STAGING_INCDIR} \
-                          --with-crypto, \
-                          --without-openssl --without-crypto, \
-                          openssl"
-PACKAGECONFIG[cap] = "--enable-linuxcaps,--disable-linuxcaps,libcap"
-PACKAGECONFIG[readline] = "--with-lineeditlibs,--without-lineeditlibs,readline"
-PACKAGECONFIG[refclocks] = "--enable-all-clocks,--disable-all-clocks,pps-tools"
-PACKAGECONFIG[debug] = "--enable-debugging,--disable-debugging"
-PACKAGECONFIG[mdns] = "ac_cv_header_dns_sd_h=yes,ac_cv_header_dns_sd_h=no,mdns"
-PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
-
-do_install_append() {
-    install -d ${D}${sysconfdir}/init.d
-    install -m 644 ${WORKDIR}/ntp.conf ${D}${sysconfdir}
-    install -m 755 ${WORKDIR}/ntpd ${D}${sysconfdir}/init.d
-    install -d ${D}${bindir}
-    install -m 755 ${WORKDIR}/ntpdate ${D}${bindir}/ntpdate-sync
-
-    install -m 755 -d ${D}${NTP_USER_HOME}
-    chown ntp:ntp ${D}${NTP_USER_HOME}
-
-    # Fix hardcoded paths in scripts
-    sed -i 's!/usr/sbin/!${sbindir}/!g' ${D}${sysconfdir}/init.d/ntpd ${D}${bindir}/ntpdate-sync
-    sed -i 's!/usr/bin/!${bindir}/!g' ${D}${sysconfdir}/init.d/ntpd ${D}${bindir}/ntpdate-sync
-    sed -i 's!/etc/!${sysconfdir}/!g' ${D}${sysconfdir}/init.d/ntpd ${D}${bindir}/ntpdate-sync
-    sed -i 's!/var/!${localstatedir}/!g' ${D}${sysconfdir}/init.d/ntpd ${D}${bindir}/ntpdate-sync
-    sed -i 's!^PATH=.*!PATH=${base_sbindir}:${base_bindir}:${sbindir}:${bindir}!' ${D}${bindir}/ntpdate-sync
-    sed -i '1s,#!.*perl -w,#! ${bindir}/env perl,' ${D}${sbindir}/ntptrace
-    sed -i '/use/i use warnings;' ${D}${sbindir}/ntptrace
-    sed -i '1s,#!.*perl,#! ${bindir}/env perl,' ${D}${sbindir}/ntp-wait
-    sed -i '/use/i use warnings;' ${D}${sbindir}/ntp-wait
-    sed -i '1s,#!.*perl -w,#! ${bindir}/env perl,' ${D}${sbindir}/calc_tickadj
-    sed -i '/use/i use warnings;' ${D}${sbindir}/calc_tickadj
-
-    install -d ${D}/${sysconfdir}/default
-    install -m 644 ${WORKDIR}/ntpdate.default ${D}${sysconfdir}/default/ntpdate
-    install -m 0644 ${WORKDIR}/sntp ${D}${sysconfdir}/default/
-
-    install -d ${D}/${sysconfdir}/network/if-up.d
-    ln -s ${bindir}/ntpdate-sync ${D}/${sysconfdir}/network/if-up.d
-
-    install -d ${D}${systemd_unitdir}/system
-    install -m 0644 ${WORKDIR}/ntpdate.service ${D}${systemd_unitdir}/system/
-    install -m 0644 ${WORKDIR}/ntpd.service ${D}${systemd_unitdir}/system/
-    install -m 0644 ${WORKDIR}/sntp.service ${D}${systemd_unitdir}/system/
-
-    install -d ${D}${systemd_unitdir}/ntp-units.d
-    install -m 0644 ${WORKDIR}/ntpd.list ${D}${systemd_unitdir}/ntp-units.d/60-ntpd.list
-
-    # Remove an empty libexecdir.
-    rmdir --ignore-fail-on-non-empty ${D}${libexecdir}
-}
-
-PACKAGES += "ntpdate sntp ${PN}-tickadj ${PN}-utils"
-# NOTE: you don't need ntpdate, use "ntpd -q -g -x"
-
-# ntp originally includes tickadj. It's split off for inclusion in small firmware images on platforms
-# with wonky clocks (e.g. OpenSlug)
-RDEPENDS_${PN} = "${PN}-tickadj"
-# ntpd require libgcc for execution
-RDEPENDS_${PN} += "libgcc"
-# Handle move from bin to utils package
-RPROVIDES_${PN}-utils = "${PN}-bin"
-RREPLACES_${PN}-utils = "${PN}-bin"
-RCONFLICTS_${PN}-utils = "${PN}-bin"
-
-SYSTEMD_PACKAGES = "${PN} ntpdate sntp"
-SYSTEMD_SERVICE_${PN} = "ntpd.service"
-SYSTEMD_SERVICE_ntpdate = "ntpdate.service"
-SYSTEMD_SERVICE_sntp = "sntp.service"
-
-RPROVIDES_${PN} += "${PN}-systemd"
-RREPLACES_${PN} += "${PN}-systemd"
-RCONFLICTS_${PN} += "${PN}-systemd"
-
-RPROVIDES_ntpdate += "ntpdate-systemd"
-RREPLACES_ntpdate += "ntpdate-systemd"
-RCONFLICTS_ntpdate += "ntpdate-systemd"
-
-RSUGGESTS_${PN} = "iana-etc"
-
-FILES_${PN} = "${sbindir}/ntpd.ntp ${sysconfdir}/ntp.conf ${sysconfdir}/init.d/ntpd ${libdir} \
-    ${NTP_USER_HOME} \
-    ${systemd_unitdir}/ntp-units.d/60-ntpd.list ${libexecdir}\
-"
-FILES_${PN}-tickadj = "${sbindir}/tickadj"
-FILES_${PN}-utils = "${sbindir} ${datadir}/ntp/lib"
-RDEPENDS_${PN}-utils += "perl"
-FILES_ntpdate = "${sbindir}/ntpdate \
-    ${sysconfdir}/network/if-up.d/ntpdate-sync \
-    ${bindir}/ntpdate-sync \
-    ${sysconfdir}/default/ntpdate \
-    ${systemd_unitdir}/system/ntpdate.service \
-"
-FILES_sntp = "${sbindir}/sntp \
-              ${sysconfdir}/default/sntp \
-              ${systemd_unitdir}/system/sntp.service \
-             "
-
-CONFFILES_${PN} = "${sysconfdir}/ntp.conf"
-CONFFILES_ntpdate = "${sysconfdir}/default/ntpdate"
-
-INITSCRIPT_NAME = "ntpd"
-# No dependencies, so just go in at the standard level (20)
-INITSCRIPT_PARAMS = "defaults"
-
-pkg_postinst_ntpdate() {
-    if ! grep -q -s ntpdate $D/var/spool/cron/root; then
-        echo "adding crontab"
-        test -d $D/var/spool/cron || mkdir -p $D/var/spool/cron
-        echo "30 * * * *    ${bindir}/ntpdate-sync silent" >> $D/var/spool/cron/root
-    fi
-}
-
-inherit update-alternatives
-
-ALTERNATIVE_PRIORITY = "100"
-
-ALTERNATIVE_${PN} = "ntpd"
-ALTERNATIVE_LINK_NAME[ntpd] = "${sbindir}/ntpd"
diff --git a/meta-openembedded/meta-networking/recipes-support/ntp/ntp_4.2.8p12.bb b/meta-openembedded/meta-networking/recipes-support/ntp/ntp_4.2.8p12.bb
new file mode 100644
index 0000000..53e4129
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/ntp/ntp_4.2.8p12.bb
@@ -0,0 +1,175 @@
+SUMMARY = "Network Time Protocol daemon and utilities"
+DESCRIPTION = "The Network Time Protocol (NTP) is used to \
+synchronize the time of a computer client or server to \
+another server or reference time source, such as a radio \
+or satellite receiver or modem."
+HOMEPAGE = "http://support.ntp.org"
+SECTION = "net"
+LICENSE = "NTP"
+LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=e877a1d567a6a58996d2b66e3e387003"
+
+DEPENDS = "libevent"
+
+SRC_URI = "http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-4.2/ntp-${PV}.tar.gz \
+           file://ntp-4.2.4_p6-nano.patch \
+           file://reproducibility-fixed-path-to-posix-shell.patch \
+           file://reproducibility-respect-source-date-epoch.patch \
+           file://ntpd \
+           file://ntp.conf \
+           file://ntpdate \
+           file://ntpdate.default \
+           file://ntpdate.service \
+           file://ntpd.service \
+           file://sntp.service \
+           file://sntp \
+           file://ntpd.list \
+"
+
+SRC_URI[md5sum] = "1522d66574bae14abb2622746dad2bdc"
+SRC_URI[sha256sum] = "709b222b5013d77d26bfff532b5ea470a8039497ef29d09363931c036cb30454"
+
+inherit autotools update-rc.d useradd systemd pkgconfig
+
+# The ac_cv_header_readline_history is to stop ntpdc depending on either
+# readline or curses
+EXTRA_OECONF += "--with-net-snmp-config=no \
+                 --without-ntpsnmpd \
+                 ac_cv_header_readline_history_h=no \
+                 --with-yielding_select=yes \
+                 --with-locfile=redhat \
+                 --without-rpath \
+                 "
+CFLAGS_append = " -DPTYS_ARE_GETPT -DPTYS_ARE_SEARCHED"
+
+USERADD_PACKAGES = "${PN}"
+NTP_USER_HOME ?= "/var/lib/ntp"
+USERADD_PARAM_${PN} = "--system --home-dir ${NTP_USER_HOME} \
+                       --no-create-home \
+                       --shell /bin/false --user-group ntp"
+
+# NB: debug is default-enabled by NTP; keep it default-enabled here.
+PACKAGECONFIG ??= "cap debug refclocks openssl \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} \
+"
+PACKAGECONFIG[openssl] = "--with-openssl-libdir=${STAGING_LIBDIR} \
+                          --with-openssl-incdir=${STAGING_INCDIR} \
+                          --with-crypto, \
+                          --without-openssl --without-crypto, \
+                          openssl"
+PACKAGECONFIG[cap] = "--enable-linuxcaps,--disable-linuxcaps,libcap"
+PACKAGECONFIG[readline] = "--with-lineeditlibs,--without-lineeditlibs,readline"
+PACKAGECONFIG[refclocks] = "--enable-all-clocks,--disable-all-clocks,pps-tools"
+PACKAGECONFIG[debug] = "--enable-debugging,--disable-debugging"
+PACKAGECONFIG[mdns] = "ac_cv_header_dns_sd_h=yes,ac_cv_header_dns_sd_h=no,mdns"
+PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
+
+do_install_append() {
+    install -d ${D}${sysconfdir}/init.d
+    install -m 644 ${WORKDIR}/ntp.conf ${D}${sysconfdir}
+    install -m 755 ${WORKDIR}/ntpd ${D}${sysconfdir}/init.d
+    install -d ${D}${bindir}
+    install -m 755 ${WORKDIR}/ntpdate ${D}${bindir}/ntpdate-sync
+
+    install -m 755 -d ${D}${NTP_USER_HOME}
+    chown ntp:ntp ${D}${NTP_USER_HOME}
+
+    # Fix hardcoded paths in scripts
+    sed -i 's!/usr/sbin/!${sbindir}/!g' ${D}${sysconfdir}/init.d/ntpd ${D}${bindir}/ntpdate-sync
+    sed -i 's!/usr/bin/!${bindir}/!g' ${D}${sysconfdir}/init.d/ntpd ${D}${bindir}/ntpdate-sync
+    sed -i 's!/etc/!${sysconfdir}/!g' ${D}${sysconfdir}/init.d/ntpd ${D}${bindir}/ntpdate-sync
+    sed -i 's!/var/!${localstatedir}/!g' ${D}${sysconfdir}/init.d/ntpd ${D}${bindir}/ntpdate-sync
+    sed -i 's!^PATH=.*!PATH=${base_sbindir}:${base_bindir}:${sbindir}:${bindir}!' ${D}${bindir}/ntpdate-sync
+    sed -i '1s,#!.*perl -w,#! ${bindir}/env perl,' ${D}${sbindir}/ntptrace
+    sed -i '/use/i use warnings;' ${D}${sbindir}/ntptrace
+    sed -i '1s,#!.*perl,#! ${bindir}/env perl,' ${D}${sbindir}/ntp-wait
+    sed -i '/use/i use warnings;' ${D}${sbindir}/ntp-wait
+    sed -i '1s,#!.*perl -w,#! ${bindir}/env perl,' ${D}${sbindir}/calc_tickadj
+    sed -i '/use/i use warnings;' ${D}${sbindir}/calc_tickadj
+
+    install -d ${D}/${sysconfdir}/default
+    install -m 644 ${WORKDIR}/ntpdate.default ${D}${sysconfdir}/default/ntpdate
+    install -m 0644 ${WORKDIR}/sntp ${D}${sysconfdir}/default/
+
+    install -d ${D}/${sysconfdir}/network/if-up.d
+    ln -s ${bindir}/ntpdate-sync ${D}/${sysconfdir}/network/if-up.d
+
+    install -d ${D}${systemd_unitdir}/system
+    install -m 0644 ${WORKDIR}/ntpdate.service ${D}${systemd_unitdir}/system/
+    install -m 0644 ${WORKDIR}/ntpd.service ${D}${systemd_unitdir}/system/
+    install -m 0644 ${WORKDIR}/sntp.service ${D}${systemd_unitdir}/system/
+
+    install -d ${D}${systemd_unitdir}/ntp-units.d
+    install -m 0644 ${WORKDIR}/ntpd.list ${D}${systemd_unitdir}/ntp-units.d/60-ntpd.list
+
+    # Remove an empty libexecdir.
+    rmdir --ignore-fail-on-non-empty ${D}${libexecdir}
+}
+
+PACKAGES += "ntpdate sntp ${PN}-tickadj ${PN}-utils"
+# NOTE: you don't need ntpdate, use "ntpd -q -g -x"
+
+# ntp originally includes tickadj. It's split off for inclusion in small firmware images on platforms
+# with wonky clocks (e.g. OpenSlug)
+RDEPENDS_${PN} = "${PN}-tickadj"
+# ntpd require libgcc for execution
+RDEPENDS_${PN} += "libgcc"
+# Handle move from bin to utils package
+RPROVIDES_${PN}-utils = "${PN}-bin"
+RREPLACES_${PN}-utils = "${PN}-bin"
+RCONFLICTS_${PN}-utils = "${PN}-bin"
+
+SYSTEMD_PACKAGES = "${PN} ntpdate sntp"
+SYSTEMD_SERVICE_${PN} = "ntpd.service"
+SYSTEMD_SERVICE_ntpdate = "ntpdate.service"
+SYSTEMD_SERVICE_sntp = "sntp.service"
+SYSTEMD_AUTO_ENABLE_sntp = "disable"
+
+RPROVIDES_${PN} += "${PN}-systemd"
+RREPLACES_${PN} += "${PN}-systemd"
+RCONFLICTS_${PN} += "${PN}-systemd"
+
+RPROVIDES_ntpdate += "ntpdate-systemd"
+RREPLACES_ntpdate += "ntpdate-systemd"
+RCONFLICTS_ntpdate += "ntpdate-systemd"
+
+RSUGGESTS_${PN} = "iana-etc"
+
+FILES_${PN} = "${sbindir}/ntpd.ntp ${sysconfdir}/ntp.conf ${sysconfdir}/init.d/ntpd ${libdir} \
+    ${NTP_USER_HOME} \
+    ${systemd_unitdir}/ntp-units.d/60-ntpd.list ${libexecdir}\
+"
+FILES_${PN}-tickadj = "${sbindir}/tickadj"
+FILES_${PN}-utils = "${sbindir} ${datadir}/ntp/lib"
+RDEPENDS_${PN}-utils += "perl"
+FILES_ntpdate = "${sbindir}/ntpdate \
+    ${sysconfdir}/network/if-up.d/ntpdate-sync \
+    ${bindir}/ntpdate-sync \
+    ${sysconfdir}/default/ntpdate \
+    ${systemd_unitdir}/system/ntpdate.service \
+"
+FILES_sntp = "${sbindir}/sntp \
+              ${sysconfdir}/default/sntp \
+              ${systemd_unitdir}/system/sntp.service \
+             "
+
+CONFFILES_${PN} = "${sysconfdir}/ntp.conf"
+CONFFILES_ntpdate = "${sysconfdir}/default/ntpdate"
+
+INITSCRIPT_NAME = "ntpd"
+# No dependencies, so just go in at the standard level (20)
+INITSCRIPT_PARAMS = "defaults"
+
+pkg_postinst_ntpdate() {
+    if ! grep -q -s ntpdate $D/var/spool/cron/root; then
+        echo "adding crontab"
+        test -d $D/var/spool/cron || mkdir -p $D/var/spool/cron
+        echo "30 * * * *    ${bindir}/ntpdate-sync silent" >> $D/var/spool/cron/root
+    fi
+}
+
+inherit update-alternatives
+
+ALTERNATIVE_PRIORITY = "100"
+
+ALTERNATIVE_${PN} = "ntpd"
+ALTERNATIVE_LINK_NAME[ntpd] = "${sbindir}/ntpd"
diff --git a/meta-openembedded/meta-networking/recipes-support/open-isns/open-isns/0001-util.h-endian.h-is-available-on-musl-on-linux.patch b/meta-openembedded/meta-networking/recipes-support/open-isns/open-isns/0001-util.h-endian.h-is-available-on-musl-on-linux.patch
index 825e2bf..fbdc4e9 100644
--- a/meta-openembedded/meta-networking/recipes-support/open-isns/open-isns/0001-util.h-endian.h-is-available-on-musl-on-linux.patch
+++ b/meta-openembedded/meta-networking/recipes-support/open-isns/open-isns/0001-util.h-endian.h-is-available-on-musl-on-linux.patch
@@ -13,10 +13,10 @@
  #  include <sys/endian.h>
             ^~~~~~~~~~~~~~
 
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
 Upstream-Status: Submitted
 
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
  include/libisns/util.h | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
diff --git a/meta-openembedded/meta-networking/recipes-support/open-isns/open-isns_0.97.bb b/meta-openembedded/meta-networking/recipes-support/open-isns/open-isns_0.97.bb
deleted file mode 100644
index abfa7510..0000000
--- a/meta-openembedded/meta-networking/recipes-support/open-isns/open-isns_0.97.bb
+++ /dev/null
@@ -1,40 +0,0 @@
-# Copyright (C) 2016 Joe MacDonald <joe_macdonald@mentor.com>
-# Released under the MIT license (see COPYING.MIT for the terms)
-
-SUMMARY = "iSNS daemon and utility programs"
-DESCRIPTION = "This is a partial implementation of RFC4171, the Internet \
-Storage Name Service (iSNS).  The distribution includes the iSNS server, \
-supporting persisten storage of registrations, isnsadm, a command line \
-utility for managing nodes, and isnsdd, a corresponding discovery daemon."
-HOMEPAGE = "http://github.com/gonzoleeman/open-isns/"
-LICENSE = "GPLv2+ & LGPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=321bf41f280cf805086dd5a720b37785"
-SECTION = "net"
-
-DEPENDS = "openssl"
-
-SRC_URI = "git://github.com/open-iscsi/open-isns \
-           file://0001-util.h-endian.h-is-available-on-musl-on-linux.patch \
-           "
-
-SRCREV ?= "09954404e948e41eb0fce8e28836018b4ce3d20d"
-
-S = "${WORKDIR}/git"
-
-inherit systemd autotools-brokensep update-rc.d
-
-EXTRA_OECONF = " --prefix=${prefix} --enable-shared"
-EXTRA_OEMAKE += "SYSTEMDDIR=${D}${systemd_unitdir}/system"
-
-do_install_append () {
-    oe_runmake INCDIR=${D}${includedir}/libisns/ install_hdrs
-    oe_runmake LIBDIR=${D}${libdir} install_lib
-
-    install -D -m 755 ${S}/etc/openisns.init ${D}${sysconfdir}/init.d/openisns
-    sed -i 's|daemon isnsd|start-stop-daemon --start --quiet --oknodo --exec ${sbindir}/isnsd --|' \
-        ${D}${sysconfdir}/init.d/openisns
-}
-
-FILES_${PN} += "${libdir} ${systemd_unitdir}"
-
-INITSCRIPT_NAME = "openisns"
diff --git a/meta-openembedded/meta-networking/recipes-support/open-isns/open-isns_0.98.bb b/meta-openembedded/meta-networking/recipes-support/open-isns/open-isns_0.98.bb
new file mode 100644
index 0000000..5e64f89
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/open-isns/open-isns_0.98.bb
@@ -0,0 +1,40 @@
+# Copyright (C) 2016 Joe MacDonald <joe_macdonald@mentor.com>
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+SUMMARY = "iSNS daemon and utility programs"
+DESCRIPTION = "This is a partial implementation of RFC4171, the Internet \
+Storage Name Service (iSNS).  The distribution includes the iSNS server, \
+supporting persisten storage of registrations, isnsadm, a command line \
+utility for managing nodes, and isnsdd, a corresponding discovery daemon."
+HOMEPAGE = "http://github.com/gonzoleeman/open-isns/"
+LICENSE = "GPLv2+ & LGPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=321bf41f280cf805086dd5a720b37785"
+SECTION = "net"
+
+DEPENDS = "openssl"
+
+SRC_URI = "git://github.com/open-iscsi/open-isns \
+           file://0001-util.h-endian.h-is-available-on-musl-on-linux.patch \
+           "
+
+SRCREV = "e84374ce7d1f5fc58a4c0fc751e075b2cc752c34"
+
+S = "${WORKDIR}/git"
+
+inherit systemd autotools-brokensep update-rc.d
+
+EXTRA_OECONF = " --prefix=${prefix} --enable-shared"
+EXTRA_OEMAKE += "SYSTEMDDIR=${D}${systemd_unitdir}/system"
+
+do_install_append () {
+    oe_runmake INCDIR=${D}${includedir}/libisns/ install_hdrs
+    oe_runmake LIBDIR=${D}${libdir} install_lib
+
+    install -D -m 755 ${S}/etc/openisns.init ${D}${sysconfdir}/init.d/openisns
+    sed -i 's|daemon isnsd|start-stop-daemon --start --quiet --oknodo --exec ${sbindir}/isnsd --|' \
+        ${D}${sysconfdir}/init.d/openisns
+}
+
+FILES_${PN} += "${libdir} ${systemd_unitdir}"
+
+INITSCRIPT_NAME = "openisns"
diff --git a/meta-openembedded/meta-networking/recipes-support/openipmi/files/0001-lanserv-Rename-struct-parameter-printf-for-namespace.patch b/meta-openembedded/meta-networking/recipes-support/openipmi/files/0001-lanserv-Rename-struct-parameter-printf-for-namespace.patch
deleted file mode 100644
index 25057fb..0000000
--- a/meta-openembedded/meta-networking/recipes-support/openipmi/files/0001-lanserv-Rename-struct-parameter-printf-for-namespace.patch
+++ /dev/null
@@ -1,618 +0,0 @@
-From 8b51a6bf5a4829d8add535a098c0c06a049a9958 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 26 Aug 2017 22:50:57 -0700
-Subject: [PATCH] lanserv: Rename struct parameter printf for namespace
- collision
-
-This comes to fore when we use hardening flags where printf
-is treated as macro and gets replaced with printf_chk
-
-Fixes errors like
-
-error: no member named '__printf_chk' in 'struct emu_out_s'
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- lanserv/OpenIPMI/serv.h |   2 +-
- lanserv/emu_cmd.c       | 132 ++++++++++++++++++++++++------------------------
- lanserv/ipmi_sim.c      |  10 ++--
- 3 files changed, 72 insertions(+), 72 deletions(-)
-
-diff --git a/lanserv/OpenIPMI/serv.h b/lanserv/OpenIPMI/serv.h
-index d12d63a..8555c85 100644
---- a/lanserv/OpenIPMI/serv.h
-+++ b/lanserv/OpenIPMI/serv.h
-@@ -522,7 +522,7 @@ uint8_t ipmb_checksum(uint8_t *data, int size, uint8_t start);
- typedef struct emu_data_s emu_data_t;
- typedef struct emu_out_s
- {
--    void (*printf)(struct emu_out_s *out, char *format, ...);
-+    void (*eprintf)(struct emu_out_s *out, char *format, ...);
-     void *data;
- } emu_out_t;
- 
-diff --git a/lanserv/emu_cmd.c b/lanserv/emu_cmd.c
-index ca44032..54b6f7b 100644
---- a/lanserv/emu_cmd.c
-+++ b/lanserv/emu_cmd.c
-@@ -76,7 +76,7 @@ emu_get_uchar(emu_out_t *out, char **toks, unsigned char *val, char *errstr,
- 	if (empty_ok)
- 	    return ENOSPC;
- 	if (errstr)
--	    out->printf(out, "**No %s given\n", errstr);
-+	    out->eprintf(out, "**No %s given\n", errstr);
- 	return EINVAL;
-     }
-     if (str[0] == '\'') {
-@@ -86,7 +86,7 @@ emu_get_uchar(emu_out_t *out, char **toks, unsigned char *val, char *errstr,
-     *val = strtoul(str, &tmpstr, 0);
-     if (*tmpstr != '\0') {
- 	if (errstr)
--	    out->printf(out, "**Invalid %s given\n", errstr);
-+	    out->eprintf(out, "**Invalid %s given\n", errstr);
- 	return EINVAL;
-     }
- 
-@@ -108,7 +108,7 @@ emu_get_uchar_with_vals(emu_out_t *out, char **toks,
- 	if (empty_ok)
- 	    return ENOSPC;
- 	if (errstr)
--	    out->printf(out, "**No %s given\n", errstr);
-+	    out->eprintf(out, "**No %s given\n", errstr);
- 	return EINVAL;
-     }
-     if (str[0] == '\'') {
-@@ -131,7 +131,7 @@ emu_get_uchar_with_vals(emu_out_t *out, char **toks,
-     *val = strtoul(str, &tmpstr, 0);
-     if (*tmpstr != '\0') {
- 	if (errstr)
--	    out->printf(out, "**Invalid %s given\n", errstr);
-+	    out->eprintf(out, "**Invalid %s given\n", errstr);
- 	return EINVAL;
-     }
-  out:
-@@ -150,12 +150,12 @@ emu_get_bitmask(emu_out_t *out, char **toks, uint16_t *val, char *errstr,
- 	if (empty_ok)
- 	    return ENOSPC;
- 	if (errstr)
--	    out->printf(out, "**No %s given\n", errstr);
-+	    out->eprintf(out, "**No %s given\n", errstr);
- 	return EINVAL;
-     }
-     if (strlen(str) != size) {
- 	if (errstr)
--	    out->printf(out, "**invalid number of bits in %s\n", errstr);
-+	    out->eprintf(out, "**invalid number of bits in %s\n", errstr);
- 	return EINVAL;
-     }
-     *val = 0;
-@@ -166,7 +166,7 @@ emu_get_bitmask(emu_out_t *out, char **toks, uint16_t *val, char *errstr,
- 	    *val |= 1 << i;
- 	} else {
- 	    if (errstr)
--		out->printf(out, "**Invalid bit value '%c' in %s\n", str[j],
-+		out->eprintf(out, "**Invalid bit value '%c' in %s\n", str[j],
- 			    errstr);
- 	    return EINVAL;
- 	}
-@@ -184,13 +184,13 @@ emu_get_uint(emu_out_t *out, char **toks, unsigned int *val, char *errstr)
-     str = mystrtok(NULL, " \t\n", toks);
-     if (!str) {
- 	if (errstr)
--	    out->printf(out, "**No %s given\n", errstr);
-+	    out->eprintf(out, "**No %s given\n", errstr);
- 	return EINVAL;
-     }
-     *val = strtoul(str, &tmpstr, 0);
-     if (*tmpstr != '\0') {
- 	if (errstr)
--	    out->printf(out, "**Invalid %s given\n", errstr);
-+	    out->eprintf(out, "**Invalid %s given\n", errstr);
- 	return EINVAL;
-     }
- 
-@@ -206,7 +206,7 @@ emu_get_bytes(emu_out_t *out, char **tokptr, unsigned char *data, char *errstr,
- 
-     if (!tok) {
- 	if (errstr)
--	    out->printf(out, "**No %s given\n", errstr);
-+	    out->eprintf(out, "**No %s given\n", errstr);
- 	return EINVAL;
-     }
-     if (*tok == '"') {
-@@ -215,7 +215,7 @@ emu_get_bytes(emu_out_t *out, char **tokptr, unsigned char *data, char *errstr,
- 	tok++;
- 	end = strlen(tok) - 1;
- 	if (tok[end] != '"') {
--	  out->printf(out, "**ASCII %s doesn't end in '\"'", errstr);
-+	  out->eprintf(out, "**ASCII %s doesn't end in '\"'", errstr);
- 	    return EINVAL;
- 	}
- 	if (end > (len - 1))
-@@ -228,7 +228,7 @@ emu_get_bytes(emu_out_t *out, char **tokptr, unsigned char *data, char *errstr,
- 	char         c[3];
- 	/* HEX pw */
- 	if (strlen(tok) != 32) {
--	    out->printf(out, "**HEX %s not 32 HEX characters long", errstr);
-+	    out->eprintf(out, "**HEX %s not 32 HEX characters long", errstr);
- 	    return EINVAL;
- 	}
- 	c[2] = '\0';
-@@ -239,7 +239,7 @@ emu_get_bytes(emu_out_t *out, char **tokptr, unsigned char *data, char *errstr,
- 	    tok++;
- 	    data[i] = strtoul(c, &end, 16);
- 	    if (*end != '\0') {
--		out->printf(out, "**Invalid HEX character in %s", errstr);
-+		out->eprintf(out, "**Invalid HEX character in %s", errstr);
- 		return -1;
- 	    }
- 	}
-@@ -263,12 +263,12 @@ read_command_file(emu_out_t *out, emu_data_t *emu, const char *command_file)
- 
- 	buffer = malloc(INPUT_BUFFER_SIZE);
- 	if (!buffer) {
--	    out->printf(out, "Could not allocate buffer memory\n");
-+	    out->eprintf(out, "Could not allocate buffer memory\n");
- 	    rv = ENOMEM;
- 	    goto out;
- 	}
- 	while (fgets(buffer+pos, INPUT_BUFFER_SIZE-pos, f)) {
--	    out->printf(out, "%s", buffer+pos);
-+	    out->eprintf(out, "%s", buffer+pos);
- 	    if (buffer[pos] == '#')
- 		continue;
- 	    pos = strlen(buffer);
-@@ -318,7 +318,7 @@ sel_enable(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 
-     rv = ipmi_mc_enable_sel(mc, max_records, flags);
-     if (rv)
--	out->printf(out, "**Unable to enable sel, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to enable sel, error 0x%x\n", rv);
-     return rv;
- }
- 
-@@ -343,9 +343,9 @@ sel_add(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 
-     rv = ipmi_mc_add_to_sel(mc, record_type, data, &r);
-     if (rv)
--	out->printf(out, "**Unable to add to sel, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to add to sel, error 0x%x\n", rv);
-     else
--	out->printf(out, "Added record %d\n", r);
-+	out->eprintf(out, "Added record %d\n", r);
-     return rv;
- }
- 
-@@ -361,14 +361,14 @@ main_sdr_add(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 	if (rv == ENOSPC)
- 	    break;
- 	if (rv) {
--	    out->printf(out, "**Error 0x%x in data byte %d\n", rv, i);
-+	    out->eprintf(out, "**Error 0x%x in data byte %d\n", rv, i);
- 	    return rv;
- 	}
-     }
- 
-     rv = ipmi_mc_add_main_sdr(mc, data, i);
-     if (rv)
--	out->printf(out, "**Unable to add to sdr, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to add to sdr, error 0x%x\n", rv);
-     return rv;
- }
- 
-@@ -389,14 +389,14 @@ device_sdr_add(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 	if (rv == ENOSPC)
- 	    break;
- 	if (rv) {
--	    out->printf(out, "**Error 0x%x in data byte %d\n", rv, i);
-+	    out->eprintf(out, "**Error 0x%x in data byte %d\n", rv, i);
- 	    return rv;
- 	}
-     }
- 
-     rv = ipmi_mc_add_device_sdr(mc, lun, data, i);
-     if (rv)
--	out->printf(out, "**Unable to add to sdr, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to add to sdr, error 0x%x\n", rv);
-     return rv;
- }
- 
-@@ -439,7 +439,7 @@ sensor_add(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
-     while (tok) {
- 	if (strcmp(tok, "poll") == 0) {
- 	    if (handler) {
--		out->printf(out, "**poll given twice in sensor\n", tok);
-+		out->eprintf(out, "**poll given twice in sensor\n", tok);
- 		return -1;
- 	    }
- 
-@@ -449,27 +449,27 @@ sensor_add(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 
- 	    tok = mystrtok(NULL, " \t\n", toks);
- 	    if (!tok) {
--		out->printf(out, "**No polled sensor handler given\n", tok);
-+		out->eprintf(out, "**No polled sensor handler given\n", tok);
- 		return -1;
- 	    }
- 
- 	    handler = ipmi_sensor_find_handler(tok);
- 	    if (!handler) {
--		out->printf(out, "**Invalid sensor handler: %s\n", tok);
-+		out->eprintf(out, "**Invalid sensor handler: %s\n", tok);
- 		return -1;
- 	    }
- 
- 	    rv = handler->init(mc, lun, num, toks, handler->cb_data, &rcb_data,
- 			       &errstr);
- 	    if (rv) {
--		out->printf(out, "**Error initializing sensor handler: %s\n", 
-+		out->eprintf(out, "**Error initializing sensor handler: %s\n", 
- 			    errstr);
- 		return rv;
- 	    }
- 	} else if (strcmp(tok, "event-only") == 0) {
- 	    event_only = 1;
- 	} else {
--	    out->printf(out, "**Unknown sensor option: %s\n", tok);
-+	    out->eprintf(out, "**Unknown sensor option: %s\n", tok);
- 	    return -1;
- 	}
- 
-@@ -477,7 +477,7 @@ sensor_add(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
-     }
- 
-     if (handler && event_only) {
--	out->printf(out, "**An event-only sensor cannot be polled\n");
-+	out->eprintf(out, "**An event-only sensor cannot be polled\n");
- 	return -1;
-     }
- 
-@@ -488,7 +488,7 @@ sensor_add(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 	if (!rv && handler->postinit) {
- 	    rv = handler->postinit(rcb_data, &errstr);
- 	    if (rv) {
--		out->printf(out, "**Error in sensor handler postinit: %s\n", 
-+		out->eprintf(out, "**Error in sensor handler postinit: %s\n", 
- 			    errstr);
- 	    }
- 	}
-@@ -496,7 +496,7 @@ sensor_add(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 	rv = ipmi_mc_add_sensor(mc, lun, num, type, code, event_only);
-     }
-     if (rv)
--	out->printf(out, "**Unable to add to sensor, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to add to sensor, error 0x%x\n", rv);
-     return rv;
- }
- 
-@@ -532,7 +532,7 @@ sensor_set_bit(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 
-     rv = ipmi_mc_sensor_set_bit(mc, lun, num, bit, value, gen_event);
-     if (rv)
--	out->printf(out, "**Unable to set sensor bit, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to set sensor bit, error 0x%x\n", rv);
-     return rv;
- }
- 
-@@ -563,7 +563,7 @@ sensor_set_bit_clr_rest(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **
- 
-     rv = ipmi_mc_sensor_set_bit_clr_rest(mc, lun, num, bit, gen_event);
-     if (rv)
--	out->printf(out, "**Unable to set sensor bit, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to set sensor bit, error 0x%x\n", rv);
-     return rv;
- }
- 
-@@ -594,7 +594,7 @@ sensor_set_value(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 
-     rv = ipmi_mc_sensor_set_value(mc, lun, num, value, gen_event);
-     if (rv)
--	out->printf(out, "**Unable to set sensor value, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to set sensor value, error 0x%x\n", rv);
-     return rv;
- }
- 
-@@ -637,7 +637,7 @@ sensor_set_hysteresis(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **to
-     rv = ipmi_mc_sensor_set_hysteresis(mc, lun, num, support, positive,
- 				       negative);
-     if (rv)
--	out->printf(out, "**Unable to set sensor hysteresis, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to set sensor hysteresis, error 0x%x\n", rv);
-     return rv;
- }
- 
-@@ -682,7 +682,7 @@ sensor_set_threshold(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **tok
-     rv = ipmi_mc_sensor_set_threshold(mc, lun, num, support,
- 				      enabled, 1, thresholds);
-     if (rv)
--	out->printf(out, "**Unable to set sensor thresholds, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to set sensor thresholds, error 0x%x\n", rv);
-     return rv;
- }
- 
-@@ -759,7 +759,7 @@ sensor_set_event_support(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char *
- 					  assert_support, deassert_support,
- 					  assert_enabled, deassert_enabled);
-     if (rv)
--	out->printf(out, "**Unable to set sensor thresholds, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to set sensor thresholds, error 0x%x\n", rv);
-     return rv;
- }
- 
-@@ -819,7 +819,7 @@ mc_add(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 	else if (strcmp("persist_sdr", tok) == 0)
- 	    flags |= IPMI_MC_PERSIST_SDR;
- 	else {
--	    out->printf(out, "**Invalid MC flag: %s\n", tok);
-+	    out->eprintf(out, "**Invalid MC flag: %s\n", tok);
- 	    return -1;
- 	}
-     }
-@@ -833,7 +833,7 @@ mc_add(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 			 device_revision, major_fw_rev, minor_fw_rev,
- 			 device_support, mfg_id, product_id, flags);
-     if (rv)
--	out->printf(out, "**Unable to add the MC, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to add the MC, error 0x%x\n", rv);
-     return rv;
- }
- 
-@@ -890,7 +890,7 @@ mc_set_power(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 
-     rv = ipmi_mc_set_power(mc, power, gen_int);
-     if (rv)
--	out->printf(out, "**Unable to set power, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to set power, error 0x%x\n", rv);
-     return rv;
- }
- 
-@@ -916,7 +916,7 @@ mc_add_fru_data(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 
-     tok = mystrtok(NULL, " \t\n", toks);
-     if (!tok) {
--	out->printf(out, "**No FRU data type given");
-+	out->eprintf(out, "**No FRU data type given");
- 	return -1;
-     }
-     if (strcmp(tok, "file") == 0) {
-@@ -929,13 +929,13 @@ mc_add_fru_data(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 
- 	rv = get_delim_str(toks, &frufn, &errstr);
- 	if (rv) {
--	    out->printf(out, "**Error with FRU filename: %d", strerror(rv));
-+	    out->eprintf(out, "**Error with FRU filename: %d", strerror(rv));
- 	    return rv;
- 	}
- 	rv = ipmi_mc_add_fru_file(mc, devid, length, file_offset,
- 				  (void *) frufn);
- 	if (rv)
--	    out->printf(out, "**Unable to add FRU file, error 0x%x\n", rv);
-+	    out->eprintf(out, "**Unable to add FRU file, error 0x%x\n", rv);
- 	
-     } else if (strcmp(tok, "data") == 0) {
- 	for (i=0; i<length; i++) {
-@@ -943,14 +943,14 @@ mc_add_fru_data(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 	    if (rv == ENOSPC)
- 		break;
- 	    if (rv) {
--		out->printf(out, "**Error 0x%x in data byte %d\n", rv, i);
-+		out->eprintf(out, "**Error 0x%x in data byte %d\n", rv, i);
- 		return rv;
- 	    }
- 	}
- 
- 	rv = emu_get_uchar(out, toks, &data[i], "data byte", 1);
- 	if (rv != ENOSPC) {
--	    out->printf(out, "**Error: input data too long for FRU\n", rv, i);
-+	    out->eprintf(out, "**Error: input data too long for FRU\n", rv, i);
- 	    return EINVAL;
- 	}
- 
-@@ -958,9 +958,9 @@ mc_add_fru_data(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 
- 	rv = ipmi_mc_add_fru_data(mc, devid, length, NULL, data);
- 	if (rv)
--	    out->printf(out, "**Unable to add FRU data, error 0x%x\n", rv);
-+	    out->eprintf(out, "**Unable to add FRU data, error 0x%x\n", rv);
-     } else {
--	out->printf(out, "**FRU type not given, need file or data\n");
-+	out->eprintf(out, "**FRU type not given, need file or data\n");
- 	rv = EINVAL;
-     }
-     return rv;
-@@ -981,28 +981,28 @@ mc_dump_fru_data(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 
-     rv = ipmi_mc_get_fru_data_len(mc, devid, &length);
-     if (rv) {
--	out->printf(out, "**Unable to dump FRU data, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to dump FRU data, error 0x%x\n", rv);
- 	goto out;
-     }
- 
-     data = malloc(length);
-     if (!data) {
--	out->printf(out, "**Unable to dump FRU data, out of memory\n", rv);
-+	out->eprintf(out, "**Unable to dump FRU data, out of memory\n", rv);
- 	goto out;
-     }
- 
-     rv = ipmi_mc_get_fru_data(mc, devid, length, data);
-     if (rv) {
--	out->printf(out, "**Unable to dump FRU data, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to dump FRU data, error 0x%x\n", rv);
- 	goto out;
-     }
- 
-     for (i=0; i<length; i++) {
- 	if ((i > 0) && ((i % 8) == 0))
--	    out->printf(out, "\n");
--	out->printf(out, " 0x%2.2x", data[i]);
-+	    out->eprintf(out, "\n");
-+	out->eprintf(out, " 0x%2.2x", data[i]);
-     }
--    out->printf(out, "\n");
-+    out->eprintf(out, "\n");
- 
-  out:
-     if (data)
-@@ -1021,7 +1021,7 @@ mc_setbmc(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 	return rv;
-     rv = ipmi_emu_set_bmc_mc(emu, ipmb);
-     if (rv)
--	out->printf(out, "**Invalid IPMB address\n");
-+	out->eprintf(out, "**Invalid IPMB address\n");
-     return rv;
- }
- 
-@@ -1032,7 +1032,7 @@ atca_enable(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 
-     rv = ipmi_emu_atca_enable(emu);
-     if (rv)
--	out->printf(out, "**Unable to enable ATCA mode, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to enable ATCA mode, error 0x%x\n", rv);
-     return rv;
- }
- 
-@@ -1056,7 +1056,7 @@ atca_set_site(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 
-     rv = ipmi_emu_atca_set_site(emu, hw_address, site_type, site_number);
-     if (rv)
--	out->printf(out, "**Unable to set site type, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to set site type, error 0x%x\n", rv);
-     return rv;
- }
- 
-@@ -1072,7 +1072,7 @@ mc_set_num_leds(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 
-     rv = ipmi_mc_set_num_leds(mc, count);
-     if (rv)
--	out->printf(out, "**Unable to set number of LEDs, error 0x%x\n", rv);
-+	out->eprintf(out, "**Unable to set number of LEDs, error 0x%x\n", rv);
-     return rv;
- }
- 
-@@ -1085,7 +1085,7 @@ read_cmds(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 
-     err = get_delim_str(toks, &filename, &errstr);
-     if (err) {
--	out->printf(out, "Could not get include filename: %s\n", errstr);
-+	out->eprintf(out, "Could not get include filename: %s\n", errstr);
- 	return err;
-     }
- 
-@@ -1097,7 +1097,7 @@ read_cmds(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
-     {
- 	char *nf = malloc(strlen(BASE_CONF_STR) + strlen(filename) + 2);
- 	if (!nf) {
--	    out->printf(out, "Out of memory in include\n", errstr);
-+	    out->eprintf(out, "Out of memory in include\n", errstr);
- 	    goto out_err;
- 	}
- 	strcpy(nf, BASE_CONF_STR);
-@@ -1107,7 +1107,7 @@ read_cmds(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 	filename = nf;
- 	err = read_command_file(out, emu, filename);
- 	if (err) {
--	    out->printf(out, "Could not read include file %s\n", filename);
-+	    out->eprintf(out, "Could not read include file %s\n", filename);
- 	}
-     }
- 
-@@ -1147,7 +1147,7 @@ debug_cmd(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 	} else if (strcmp(tok, "sol") == 0) {
- 	    level |= DEBUG_SOL;
- 	} else {
--	    out->printf(out, "Invalid debug level '%s', options are 'raw' and 'msg'\n",
-+	    out->eprintf(out, "Invalid debug level '%s', options are 'raw' and 'msg'\n",
- 		   tok);
- 	    return EINVAL;
- 	}
-@@ -1168,7 +1168,7 @@ persist_cmd(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 	} else if (strcmp(tok, "off") == 0) {
- 	    persist_enable = 0;
- 	} else {
--	    out->printf(out, "Invalid persist vale '%s', options are 'on' and 'off'\n",
-+	    out->eprintf(out, "Invalid persist vale '%s', options are 'on' and 'off'\n",
- 		   tok);
- 	    return EINVAL;
- 	}
-@@ -1194,18 +1194,18 @@ do_define(emu_out_t *out, emu_data_t *emu, lmc_data_t *mc, char **toks)
- 
-     name = mystrtok(NULL, " \t\n", toks);
-     if (!name) {
--	out->printf(out, "No variable name given for define\n");
-+	out->eprintf(out, "No variable name given for define\n");
- 	return EINVAL;
-     }
-     err = get_delim_str(toks, &value, &errstr);
-     if (err) {
--	out->printf(out, "Could not get variable %s value: %s\n", name, errstr);
-+	out->eprintf(out, "Could not get variable %s value: %s\n", name, errstr);
- 	return err;
-     }
-     err = add_variable(name, value);
-     if (err) {
- 	free(value);
--	out->printf(out, "Out of memory setting variable %s\n", name);
-+	out->eprintf(out, "Out of memory setting variable %s\n", name);
- 	return err;
-     }
-     return 0;
-@@ -1301,7 +1301,7 @@ ipmi_emu_cmd(emu_out_t *out, emu_data_t *emu, char *cmd_str)
- 		    return rv;
- 		rv = ipmi_emu_get_mc_by_addr(emu, ipmb, &mc);
- 		if (rv) {
--		    out->printf(out, "**Invalid MC address\n");
-+		    out->eprintf(out, "**Invalid MC address\n");
- 		    return rv;
- 		}
- 	    }
-@@ -1312,7 +1312,7 @@ ipmi_emu_cmd(emu_out_t *out, emu_data_t *emu, char *cmd_str)
- 	}
-     }
- 
--    out->printf(out, "**Unknown command: %s\n", cmd);
-+    out->eprintf(out, "**Unknown command: %s\n", cmd);
- 
-  out:
-     return rv;
-diff --git a/lanserv/ipmi_sim.c b/lanserv/ipmi_sim.c
-index 9472cce..30c4f27 100644
---- a/lanserv/ipmi_sim.c
-+++ b/lanserv/ipmi_sim.c
-@@ -607,8 +607,8 @@ isim_log(sys_data_t *sys, int logtype, msg_t *msg, const char *format,
- 
-     con = data->consoles;
-     while (con) {
--	con->out.printf(&con->out, "%s", str);
--	con->out.printf(&con->out, "\n");
-+	con->out.eprintf(&con->out, "%s", str);
-+	con->out.eprintf(&con->out, "\n");
- 	con = con->next;
-     }
- #if HAVE_SYSLOG
-@@ -956,7 +956,7 @@ console_bind_ready(int fd, void *cb_data, os_hnd_fd_id_t *id)
-     newcon->shutdown_on_close = 0;
-     newcon->telnet = 1;
-     newcon->tn_pos = 0;
--    newcon->out.printf = emu_printf;
-+    newcon->out.eprintf = emu_printf;
-     newcon->out.data = newcon;
- 
-     setsockopt(rv, IPPROTO_TCP, TCP_NODELAY, (char *)&val, sizeof(val));
-@@ -1463,10 +1463,10 @@ main(int argc, const char *argv[])
-     stdio_console.telnet = 0;
-     stdio_console.tn_pos = 0;
-     if (nostdio) {
--	stdio_console.out.printf = dummy_printf;
-+	stdio_console.out.eprintf = dummy_printf;
- 	stdio_console.out.data = &stdio_console;
-     } else {
--	stdio_console.out.printf = emu_printf;
-+	stdio_console.out.eprintf = emu_printf;
- 	stdio_console.out.data = &stdio_console;
-     }
-     stdio_console.next = NULL;
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-networking/recipes-support/openipmi/files/openipmigui-not-compile-pyc-pyo.patch b/meta-openembedded/meta-networking/recipes-support/openipmi/files/openipmigui-not-compile-pyc-pyo.patch
new file mode 100644
index 0000000..3894075
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/openipmi/files/openipmigui-not-compile-pyc-pyo.patch
@@ -0,0 +1,26 @@
+openipmi load swig/python/.libs/_OpenIPMI.so to create .pyc and .pyo files.
+It fails when multilib is enable:
+
+| ImportError: .../lib32-openipmi/2.0.25-r0/OpenIPMI-2.0.25/swig/python/.libs/_OpenIPMI.so: wrong ELF class: ELFCLASS32
+
+Don't compile and install .pyc and .pyo files to fix the failure.
+
+Upstream-Status: Inappropriate [OE specific]
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+diff --git a/swig/python/openipmigui/Makefile.am b/swig/python/openipmigui/Makefile.am
+index 570e7b9..88258bf 100644
+--- a/swig/python/openipmigui/Makefile.am
++++ b/swig/python/openipmigui/Makefile.am
+@@ -34,9 +34,9 @@ localcopy:
+ 		fi \
+ 	done
+ 
+-all-local: localcopy $(PYC_FILES) $(PYO_FILES)
++all-local: localcopy
+ 
+-install-exec-local: $(EXTRA_DIST) $(PYC_FILES) $(PYO_FILES)
++install-exec-local: $(EXTRA_DIST)
+ 	$(INSTALL) -d $(DESTDIR)$(PYTHON_INSTALL_DIR)/openipmigui
+ 	$(INSTALL_DATA) $^ $(DESTDIR)$(PYTHON_INSTALL_DIR)/openipmigui
+ 
diff --git a/meta-openembedded/meta-networking/recipes-support/openipmi/openipmi_2.0.24.bb b/meta-openembedded/meta-networking/recipes-support/openipmi/openipmi_2.0.24.bb
deleted file mode 100644
index a4f63c5..0000000
--- a/meta-openembedded/meta-networking/recipes-support/openipmi/openipmi_2.0.24.bb
+++ /dev/null
@@ -1,110 +0,0 @@
-SUMMARY = "IPMI (Intelligent Platform Management Interface) library and tools"
-DESCRIPTION = "OpenIPMI is an effort to create a full-function IPMI system, \
-to allow full access to all IPMI information on a server \
-and to abstract it to a level that will make it easy to use"
-
-HOMEPAGE = "http://openipmi.sourceforge.net"
-
-DEPENDS = " \
-    glib-2.0 \
-    ncurses \
-    net-snmp \
-    openssl \
-    popt \
-    python \
-    swig-native \
-    "
-
-LICENSE = "GPLv2 & LGPLv2.1 & BSD"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
-                    file://COPYING.LIB;md5=d8045f3b8f929c1cb29a1e3fd737b499 \
-                    file://COPYING.BSD;md5=4b318d4160eb69c8ee53452feb1b4cdf \
-                    "
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/openipmi/OpenIPMI-${PV}.tar.gz \
-           file://fix-symlink-install-error-in-cmdlang.patch \
-           file://openipmi-no-openipmigui-man.patch \
-           file://openipmi-remove-host-path-from-la_LDFLAGS.patch \
-           file://ipmi-init-fix-the-arguments.patch \
-           file://do-not-install-pyc-and-pyo.patch \
-           file://include_sys_types.patch \
-           file://openipmi-helper \
-           file://ipmi.service \
-           file://0001-lanserv-Rename-struct-parameter-printf-for-namespace.patch \
-           "
-
-S = "${WORKDIR}/OpenIPMI-${PV}"
-SRC_URI[md5sum] = "58f9542cbfcb5fe250b77cf88345e1ec"
-SRC_URI[sha256sum] = "bca39a27071278a8b74610181ede8df51e155e5e9031bc8eaa3699d1720292b4"
-
-inherit autotools-brokensep pkgconfig pythonnative perlnative update-rc.d systemd
-
-EXTRA_OECONF = "--disable-static \
-                --with-perl='${STAGING_BINDIR_NATIVE}/perl-native/perl' \
-                --with-python='${STAGING_BINDIR_NATIVE}/python-native/python' \
-                --with-pythoninstall='${PYTHON_SITEPACKAGES_DIR}' \
-                --with-glibver=2.0"
-
-PACKAGECONFIG ??= "gdbm"
-PACKAGECONFIG[gdbm] = "ac_cv_header_gdbm_h=yes,ac_cv_header_gdbm_h=no,gdbm,"
-
-PACKAGES += "${PN}-perl ${PN}-python"
-
-FILES_${PN}-perl = " \
-    ${libdir}/perl/vendor_perl/*/OpenIPMI.pm \
-    ${libdir}/perl/vendor_perl/*/auto/OpenIPMI/OpenIPMI.so \
-    "
-
-FILES_${PN}-python = "${PYTHON_SITEPACKAGES_DIR}"
-
-FILES_${PN}-dbg += " \
-    ${libdir}/perl/vendor_perl/*/auto/OpenIPMI/.debug \
-    ${PYTHON_SITEPACKAGES_DIR}/.debug \
-    "
-
-do_configure () {
-
-    # Let's perform regular configuration first then handle perl issues.
-    autotools_do_configure
-
-    perl_ver=`perl -V:version | cut -d\' -f 2`
-    
-    # Force openipmi perl bindings to be compiled using perl-native instead of
-    # the host's perl. Set the proper install directory for the resulting
-    # openipmi.pm and openipmi.so
-    for i in ${S}/swig/Makefile ${S}/swig/perl/Makefile; do
-        echo "SAL: i = $i"
-        echo "SAL: STAGING_INCDIR_NATIVE = $STAGING_INCDIR_NATIVE"
-        echo "SAL: libdir = $libdir"
-        sed -i -e "/^PERL_CFLAGS/s:-I/usr/local/include:-I${STAGING_INCDIR_NATIVE}:g" $i
-        sed -i -e "/^PERL_INSTALL_DIR/s:^PERL_INSTALL_DIR = .*:PERL_INSTALL_DIR = ${libdir}/perl/vendor_perl/$perl_ver:g" $i
-    done
-}
-
-do_install_append () {
-    echo "SAL: D = $D"
-    echo "SAL: libdir = $libdir"
-    install -m 0755 -d ${D}${sysconfdir}/sysconfig ${D}${sysconfdir}/init.d
-    install -m 0755 ${S}/ipmi.init ${D}${sysconfdir}/init.d/ipmi
-    install -m 0644 ${S}/ipmi.sysconf ${D}${sysconfdir}/sysconfig/ipmi
-    # SAL: mv: cannot stat `/localdisk/loadbuild/slittle1/workspace/cgts_test_build/bitbake_build/tmp/work/x86_64-wrs-linux/openipmi-2.0.19-r4/image/usr/lib64/perl5': No such file or directory
-    # SAL: real path to perl is /localdisk/loadbuild/slittle1/workspace/cgts_test_build/bitbake_build/tmp/work/x86_64-wrs-linux/perl-5.14.2-r8.3/package/usr/lib64/perl5 and it is a symlink to perl so no need to mv.
-    if [ -d ${D}${libdir}/perl5 ]
-    then
-        mv ${D}${libdir}/perl5 ${D}${libdir}/perl
-    fi
- 
-    # for systemd
-    install -d ${D}${systemd_unitdir}/system
-    install -m 0664 ${WORKDIR}/ipmi.service ${D}${systemd_unitdir}/system
-    sed -i -e "s,@LIBEXECDIR@,${libexecdir},g" ${D}${systemd_unitdir}/system/ipmi.service
-    install -d ${D}${libexecdir}
-    install -m 0755 ${WORKDIR}/openipmi-helper ${D}${libexecdir}
-}
-
-INITSCRIPT_NAME = "ipmi"
-INITSCRIPT_PARAMS = "start 30 . stop 70 0 1 2 3 4 5 6 ."
-
-SYSTEMD_SERVICE_${PN} = "ipmi.service"
-SYSTEMD_AUTO_ENABLE = "disable"
diff --git a/meta-openembedded/meta-networking/recipes-support/openipmi/openipmi_2.0.25.bb b/meta-openembedded/meta-networking/recipes-support/openipmi/openipmi_2.0.25.bb
new file mode 100644
index 0000000..d28ebd4
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/openipmi/openipmi_2.0.25.bb
@@ -0,0 +1,110 @@
+SUMMARY = "IPMI (Intelligent Platform Management Interface) library and tools"
+DESCRIPTION = "OpenIPMI is an effort to create a full-function IPMI system, \
+to allow full access to all IPMI information on a server \
+and to abstract it to a level that will make it easy to use"
+
+HOMEPAGE = "http://openipmi.sourceforge.net"
+
+DEPENDS = " \
+    glib-2.0 \
+    ncurses \
+    net-snmp \
+    openssl \
+    popt \
+    python \
+    swig-native \
+    "
+
+LICENSE = "GPLv2 & LGPLv2.1 & BSD"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
+                    file://COPYING.LIB;md5=d8045f3b8f929c1cb29a1e3fd737b499 \
+                    file://COPYING.BSD;md5=4b318d4160eb69c8ee53452feb1b4cdf \
+                    "
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/openipmi/OpenIPMI-${PV}.tar.gz \
+           file://fix-symlink-install-error-in-cmdlang.patch \
+           file://openipmi-no-openipmigui-man.patch \
+           file://openipmi-remove-host-path-from-la_LDFLAGS.patch \
+           file://ipmi-init-fix-the-arguments.patch \
+           file://do-not-install-pyc-and-pyo.patch \
+           file://include_sys_types.patch \
+           file://openipmigui-not-compile-pyc-pyo.patch \
+           file://openipmi-helper \
+           file://ipmi.service \
+           "
+
+S = "${WORKDIR}/OpenIPMI-${PV}"
+SRC_URI[md5sum] = "1461ac4d78fc516646fd0a6e605a8b05"
+SRC_URI[sha256sum] = "f0f1a0ec732409930b7a31a6daa6cf39b585f52059b62a5f092b7ece21aa75a5"
+
+inherit autotools-brokensep pkgconfig pythonnative perlnative update-rc.d systemd
+
+EXTRA_OECONF = "--disable-static \
+                --with-perl='${STAGING_BINDIR_NATIVE}/perl-native/perl' \
+                --with-python='${STAGING_BINDIR_NATIVE}/python-native/python' \
+                --with-pythoninstall='${PYTHON_SITEPACKAGES_DIR}' \
+                --with-glibver=2.0"
+
+PACKAGECONFIG ??= "gdbm"
+PACKAGECONFIG[gdbm] = "ac_cv_header_gdbm_h=yes,ac_cv_header_gdbm_h=no,gdbm,"
+
+PACKAGES += "${PN}-perl ${PN}-python"
+
+FILES_${PN}-perl = " \
+    ${libdir}/perl/vendor_perl/*/OpenIPMI.pm \
+    ${libdir}/perl/vendor_perl/*/auto/OpenIPMI/OpenIPMI.so \
+    "
+
+FILES_${PN}-python = "${PYTHON_SITEPACKAGES_DIR}"
+
+FILES_${PN}-dbg += " \
+    ${libdir}/perl/vendor_perl/*/auto/OpenIPMI/.debug \
+    ${PYTHON_SITEPACKAGES_DIR}/.debug \
+    "
+
+do_configure () {
+
+    # Let's perform regular configuration first then handle perl issues.
+    autotools_do_configure
+
+    perl_ver=`perl -V:version | cut -d\' -f 2`
+    
+    # Force openipmi perl bindings to be compiled using perl-native instead of
+    # the host's perl. Set the proper install directory for the resulting
+    # openipmi.pm and openipmi.so
+    for i in ${S}/swig/Makefile ${S}/swig/perl/Makefile; do
+        echo "SAL: i = $i"
+        echo "SAL: STAGING_INCDIR_NATIVE = $STAGING_INCDIR_NATIVE"
+        echo "SAL: libdir = $libdir"
+        sed -i -e "/^PERL_CFLAGS/s:-I/usr/local/include:-I${STAGING_INCDIR_NATIVE}:g" $i
+        sed -i -e "/^PERL_INSTALL_DIR/s:^PERL_INSTALL_DIR = .*:PERL_INSTALL_DIR = ${libdir}/perl/vendor_perl/$perl_ver:g" $i
+    done
+}
+
+do_install_append () {
+    echo "SAL: D = $D"
+    echo "SAL: libdir = $libdir"
+    install -m 0755 -d ${D}${sysconfdir}/sysconfig ${D}${sysconfdir}/init.d
+    install -m 0755 ${S}/ipmi.init ${D}${sysconfdir}/init.d/ipmi
+    install -m 0644 ${S}/ipmi.sysconf ${D}${sysconfdir}/sysconfig/ipmi
+    # SAL: mv: cannot stat `/localdisk/loadbuild/slittle1/workspace/cgts_test_build/bitbake_build/tmp/work/x86_64-wrs-linux/openipmi-2.0.19-r4/image/usr/lib64/perl5': No such file or directory
+    # SAL: real path to perl is /localdisk/loadbuild/slittle1/workspace/cgts_test_build/bitbake_build/tmp/work/x86_64-wrs-linux/perl-5.14.2-r8.3/package/usr/lib64/perl5 and it is a symlink to perl so no need to mv.
+    if [ -d ${D}${libdir}/perl5 ]
+    then
+        mv ${D}${libdir}/perl5 ${D}${libdir}/perl
+    fi
+ 
+    # for systemd
+    install -d ${D}${systemd_unitdir}/system
+    install -m 0664 ${WORKDIR}/ipmi.service ${D}${systemd_unitdir}/system
+    sed -i -e "s,@LIBEXECDIR@,${libexecdir},g" ${D}${systemd_unitdir}/system/ipmi.service
+    install -d ${D}${libexecdir}
+    install -m 0755 ${WORKDIR}/openipmi-helper ${D}${libexecdir}
+}
+
+INITSCRIPT_NAME = "ipmi"
+INITSCRIPT_PARAMS = "start 30 . stop 70 0 1 2 3 4 5 6 ."
+
+SYSTEMD_SERVICE_${PN} = "ipmi.service"
+SYSTEMD_AUTO_ENABLE = "disable"
diff --git a/meta-openembedded/meta-networking/recipes-support/openvpn/openvpn_2.4.4.bb b/meta-openembedded/meta-networking/recipes-support/openvpn/openvpn_2.4.4.bb
deleted file mode 100644
index 4cad998..0000000
--- a/meta-openembedded/meta-networking/recipes-support/openvpn/openvpn_2.4.4.bb
+++ /dev/null
@@ -1,67 +0,0 @@
-SUMMARY = "A full-featured SSL VPN solution via tun device."
-HOMEPAGE = "http://openvpn.sourceforge.net"
-SECTION = "net"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=e9b64491ec98eb6c6493ac5e4118f107"
-DEPENDS = "lzo openssl iproute2 ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)}"
-
-inherit autotools systemd
-
-SRC_URI = "http://swupdate.openvpn.org/community/releases/${BP}.tar.gz \
-           file://openvpn \
-           file://openvpn@.service \
-           file://openvpn-volatile.conf"
-
-SRC_URI[md5sum] = "705a79d005558d94fa1e2b74e4413e97"
-SRC_URI[sha256sum] = "1ae883d9522c9fa6d189e5e4aaa058a93edd3d0b897e3c2664107c4785099fc3"
-
-SYSTEMD_SERVICE_${PN} += "openvpn@loopback-server.service openvpn@loopback-client.service"
-SYSTEMD_AUTO_ENABLE = "disable"
-
-CFLAGS += "-fno-inline"
-
-# I want openvpn to be able to read password from file (hrw)
-EXTRA_OECONF += "--enable-iproute2"
-EXTRA_OECONF += "${@bb.utils.contains('DISTRO_FEATURES', 'pam', '', '--disable-plugin-auth-pam', d)}"
-
-# Explicitly specify IPROUTE to bypass the configure-time check for /sbin/ip on the host.
-EXTRA_OECONF += "IPROUTE=${base_sbindir}/ip"
-
-do_install_append() {
-    install -d ${D}/${sysconfdir}/init.d
-    install -m 755 ${WORKDIR}/openvpn ${D}/${sysconfdir}/init.d
-
-    install -d ${D}/${sysconfdir}/openvpn
-    install -d ${D}/${sysconfdir}/openvpn/sample
-    install -m 755 ${S}/sample/sample-config-files/loopback-server  ${D}${sysconfdir}/openvpn/sample/loopback-server.conf
-    install -m 755 ${S}/sample/sample-config-files/loopback-client  ${D}${sysconfdir}/openvpn/sample/loopback-client.conf
-    install -dm 755 ${D}${sysconfdir}/openvpn/sample/sample-keys
-    install -m 644 ${S}/sample/sample-keys/* ${D}${sysconfdir}/openvpn/sample/sample-keys
-
-    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
-        install -d ${D}/${systemd_unitdir}/system
-        install -m 644 ${WORKDIR}/openvpn@.service ${D}/${systemd_unitdir}/system
-        install -m 644 ${WORKDIR}/openvpn@.service ${D}/${systemd_unitdir}/system/openvpn@loopback-server.service
-        install -m 644 ${WORKDIR}/openvpn@.service ${D}/${systemd_unitdir}/system/openvpn@loopback-client.service
-
-        install -d ${D}/${localstatedir}
-        install -d ${D}/${localstatedir}/lib
-        install -d -m 710 ${D}/${localstatedir}/lib/openvpn
-
-        install -d ${D}${sysconfdir}/tmpfiles.d
-        install -m 0644 ${WORKDIR}/openvpn-volatile.conf ${D}${sysconfdir}/tmpfiles.d/openvpn.conf
-        sed -i -e 's#@LOCALSTATEDIR@#${localstatedir}#g' ${D}${sysconfdir}/tmpfiles.d/openvpn.conf
-    fi
-}
-
-PACKAGES =+ " ${PN}-sample "
-
-RRECOMMENDS_${PN} = "kernel-module-tun"
-
-FILES_${PN}-dbg += "${libdir}/openvpn/plugins/.debug"
-FILES_${PN} += "${systemd_unitdir}/system/openvpn@.service \
-                ${sysconfdir}/tmpfiles.d \
-               "
-FILES_${PN}-sample += "${systemd_unitdir}/system/openvpn@loopback-server.service \
-                       ${systemd_unitdir}/system/openvpn@loopback-client.service \
-                       ${sysconfdir}/openvpn/sample/"
diff --git a/meta-openembedded/meta-networking/recipes-support/openvpn/openvpn_2.4.6.bb b/meta-openembedded/meta-networking/recipes-support/openvpn/openvpn_2.4.6.bb
new file mode 100644
index 0000000..84fd467
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/openvpn/openvpn_2.4.6.bb
@@ -0,0 +1,71 @@
+SUMMARY = "A full-featured SSL VPN solution via tun device."
+HOMEPAGE = "http://openvpn.sourceforge.net"
+SECTION = "net"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=7aee596ed2deefe3e8a861e24292abba"
+DEPENDS = "lzo openssl iproute2 ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)}"
+
+inherit autotools systemd update-rc.d
+
+SRC_URI = "http://swupdate.openvpn.org/community/releases/${BP}.tar.gz \
+           file://openvpn \
+           file://openvpn@.service \
+           file://openvpn-volatile.conf"
+
+SRC_URI[md5sum] = "971d57e29b78b4b902eb2f4aae2f05a7"
+SRC_URI[sha256sum] = "738dbd37fcf8eb9382c53628db22258c41ba9550165519d9200e8bebaef4cbe2"
+
+SYSTEMD_SERVICE_${PN} += "openvpn@loopback-server.service openvpn@loopback-client.service"
+SYSTEMD_AUTO_ENABLE = "disable"
+
+INITSCRIPT_PACKAGES = "${PN}"
+INITSCRIPT_NAME_${PN} = "openvpn"
+INITSCRIPT_PARAMS_${PN} = "start 10 2 3 4 5 . stop 70 0 1 6 ."
+
+CFLAGS += "-fno-inline"
+
+# I want openvpn to be able to read password from file (hrw)
+EXTRA_OECONF += "--enable-iproute2"
+EXTRA_OECONF += "${@bb.utils.contains('DISTRO_FEATURES', 'pam', '', '--disable-plugin-auth-pam', d)}"
+
+# Explicitly specify IPROUTE to bypass the configure-time check for /sbin/ip on the host.
+EXTRA_OECONF += "IPROUTE=${base_sbindir}/ip"
+
+do_install_append() {
+    install -d ${D}/${sysconfdir}/init.d
+    install -m 755 ${WORKDIR}/openvpn ${D}/${sysconfdir}/init.d
+
+    install -d ${D}/${sysconfdir}/openvpn
+    install -d ${D}/${sysconfdir}/openvpn/sample
+    install -m 755 ${S}/sample/sample-config-files/loopback-server  ${D}${sysconfdir}/openvpn/sample/loopback-server.conf
+    install -m 755 ${S}/sample/sample-config-files/loopback-client  ${D}${sysconfdir}/openvpn/sample/loopback-client.conf
+    install -dm 755 ${D}${sysconfdir}/openvpn/sample/sample-keys
+    install -m 644 ${S}/sample/sample-keys/* ${D}${sysconfdir}/openvpn/sample/sample-keys
+
+    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
+        install -d ${D}/${systemd_unitdir}/system
+        install -m 644 ${WORKDIR}/openvpn@.service ${D}/${systemd_unitdir}/system
+        install -m 644 ${WORKDIR}/openvpn@.service ${D}/${systemd_unitdir}/system/openvpn@loopback-server.service
+        install -m 644 ${WORKDIR}/openvpn@.service ${D}/${systemd_unitdir}/system/openvpn@loopback-client.service
+
+        install -d ${D}/${localstatedir}
+        install -d ${D}/${localstatedir}/lib
+        install -d -m 710 ${D}/${localstatedir}/lib/openvpn
+
+        install -d ${D}${sysconfdir}/tmpfiles.d
+        install -m 0644 ${WORKDIR}/openvpn-volatile.conf ${D}${sysconfdir}/tmpfiles.d/openvpn.conf
+        sed -i -e 's#@LOCALSTATEDIR@#${localstatedir}#g' ${D}${sysconfdir}/tmpfiles.d/openvpn.conf
+    fi
+}
+
+PACKAGES =+ " ${PN}-sample "
+
+RRECOMMENDS_${PN} = "kernel-module-tun"
+
+FILES_${PN}-dbg += "${libdir}/openvpn/plugins/.debug"
+FILES_${PN} += "${systemd_unitdir}/system/openvpn@.service \
+                ${sysconfdir}/tmpfiles.d \
+               "
+FILES_${PN}-sample += "${systemd_unitdir}/system/openvpn@loopback-server.service \
+                       ${systemd_unitdir}/system/openvpn@loopback-client.service \
+                       ${sysconfdir}/openvpn/sample/"
diff --git a/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core/0001-Remove-man-files-which-cant-be-built.patch b/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core/0001-Remove-man-files-which-cant-be-built.patch
new file mode 100644
index 0000000..4b59561
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core/0001-Remove-man-files-which-cant-be-built.patch
@@ -0,0 +1,103 @@
+From 5a8a2f81ef8650f06d1d9d268add612ab46025f1 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 12 Jun 2018 22:57:04 -0700
+Subject: [PATCH] Remove man files which cant be built
+
+Remove need for pandoc-prebuilt during cross build
+
+Fixes errors
+
+| CMake Error at libibumad/man/cmake_install.cmake:105 (file):
+|   file INSTALL cannot find
+|   "/mnt/a/oe/build/tmp/work/core2-64-bec-linux-musl/rdma-core/18.1-r0/git/buildlib/pandoc-prebuilt/41bbb0bed7a781be59e8c0dcd8b7278af2ce6882".
+| Call Stack (most recent call first):
+|   cmake_install.cmake:48 (include)
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ libibumad/man/CMakeLists.txt      |  1 -
+ libibverbs/man/CMakeLists.txt     | 15 ---------------
+ providers/mlx5/man/CMakeLists.txt |  1 -
+ 3 files changed, 17 deletions(-)
+
+diff --git a/libibumad/man/CMakeLists.txt b/libibumad/man/CMakeLists.txt
+index 185584a0..ac45a4e9 100644
+--- a/libibumad/man/CMakeLists.txt
++++ b/libibumad/man/CMakeLists.txt
+@@ -15,7 +15,6 @@ rdma_man_pages(
+   umad_get_mad_addr.3
+   umad_get_pkey.3
+   umad_get_port.3
+-  umad_init.3.md
+   umad_open_port.3
+   umad_poll.3
+   umad_recv.3
+diff --git a/libibverbs/man/CMakeLists.txt b/libibverbs/man/CMakeLists.txt
+index 86dd49de..b54675be 100644
+--- a/libibverbs/man/CMakeLists.txt
++++ b/libibverbs/man/CMakeLists.txt
+@@ -5,7 +5,6 @@ rdma_man_pages(
+   ibv_alloc_pd.3
+   ibv_alloc_td.3
+   ibv_asyncwatch.1
+-  ibv_attach_mcast.3.md
+   ibv_bind_mw.3
+   ibv_create_ah.3
+   ibv_create_ah_from_wc.3
+@@ -14,7 +13,6 @@ rdma_man_pages(
+   ibv_create_cq_ex.3
+   ibv_modify_cq.3
+   ibv_create_flow.3
+-  ibv_create_flow_action.3.md
+   ibv_create_qp.3
+   ibv_create_qp_ex.3
+   ibv_create_rwq_ind_table.3
+@@ -23,15 +21,9 @@ rdma_man_pages(
+   ibv_create_wq.3
+   ibv_devices.1
+   ibv_devinfo.1
+-  ibv_event_type_str.3.md
+-  ibv_fork_init.3.md
+   ibv_get_async_event.3
+   ibv_get_cq_event.3
+-  ibv_get_device_guid.3.md
+   ibv_get_device_list.3
+-  ibv_get_device_name.3.md
+-  ibv_get_srq_num.3.md
+-  ibv_inc_rkey.3.md
+   ibv_modify_qp.3
+   ibv_modify_qp_rate_limit.3
+   ibv_modify_srq.3
+@@ -46,19 +38,12 @@ rdma_man_pages(
+   ibv_post_srq_recv.3
+   ibv_query_device.3
+   ibv_query_device_ex.3
+-  ibv_query_gid.3.md
+-  ibv_query_pkey.3.md
+   ibv_query_port.3
+   ibv_query_qp.3
+   ibv_query_rt_values_ex.3
+   ibv_query_srq.3
+-  ibv_rate_to_mbps.3.md
+-  ibv_rate_to_mult.3.md
+   ibv_rc_pingpong.1
+   ibv_reg_mr.3
+-  ibv_req_notify_cq.3.md
+-  ibv_rereg_mr.3.md
+-  ibv_resize_cq.3.md
+   ibv_srq_pingpong.1
+   ibv_uc_pingpong.1
+   ibv_ud_pingpong.1
+diff --git a/providers/mlx5/man/CMakeLists.txt b/providers/mlx5/man/CMakeLists.txt
+index cdc7115e..876b6fcf 100644
+--- a/providers/mlx5/man/CMakeLists.txt
++++ b/providers/mlx5/man/CMakeLists.txt
+@@ -1,5 +1,4 @@
+ rdma_man_pages(
+-  mlx5dv_flow_action_esp.3.md
+   mlx5dv_get_clock_info.3
+   mlx5dv_init_obj.3
+   mlx5dv_query_device.3
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core/0001-S_IFSOCK-is-defined-in-both-glibc-musl.patch b/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core/0001-S_IFSOCK-is-defined-in-both-glibc-musl.patch
new file mode 100644
index 0000000..b04c9b7
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core/0001-S_IFSOCK-is-defined-in-both-glibc-musl.patch
@@ -0,0 +1,29 @@
+From f2df1db11f3a9580774300e703b6f53dbcdb28ef Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 8 Jun 2018 20:17:57 -0700
+Subject: [PATCH] S_IFSOCK is defined in both glibc/musl
+
+Fixes
+
+preload.c:1183:46: error: '__S_IFSOCK' undeclared (first use in this function); did you mean 'S_IFSOCK'?
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ librdmacm/preload.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/librdmacm/preload.c b/librdmacm/preload.c
+index 0f2aa250..d46beb1b 100644
+--- a/librdmacm/preload.c
++++ b/librdmacm/preload.c
+@@ -1180,7 +1180,7 @@ int __fxstat(int ver, int socket, struct stat *buf)
+ 	if (fd_get(socket, &fd) == fd_rsocket) {
+ 		ret = real.fxstat(ver, socket, buf);
+ 		if (!ret)
+-			buf->st_mode = (buf->st_mode & ~S_IFMT) | __S_IFSOCK;
++			buf->st_mode = (buf->st_mode & ~S_IFMT) | S_IFSOCK;
+ 	} else {
+ 		ret = real.fxstat(ver, fd, buf);
+ 	}
diff --git a/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core/0001-include-endian.h-for-htole32-and-friends.patch b/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core/0001-include-endian.h-for-htole32-and-friends.patch
new file mode 100644
index 0000000..aa33524
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core/0001-include-endian.h-for-htole32-and-friends.patch
@@ -0,0 +1,25 @@
+From 65b9a47c07be4611b4fbbcafff1993186bcb0537 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 12 Jun 2018 19:15:52 -0700
+Subject: [PATCH 1/2] include endian.h for htole32 and friends
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ providers/hns/hns_roce_u.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/providers/hns/hns_roce_u.h b/providers/hns/hns_roce_u.h
+index bd66c6e7..b07424db 100644
+--- a/providers/hns/hns_roce_u.h
++++ b/providers/hns/hns_roce_u.h
+@@ -34,6 +34,7 @@
+ #define _HNS_ROCE_U_H
+ 
+ #include <stddef.h>
++#include <endian.h>
+ #include <util/compiler.h>
+ 
+ #include <infiniband/driver.h>
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core/0002-Remove-unused-include-for-execinfo.h.patch b/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core/0002-Remove-unused-include-for-execinfo.h.patch
new file mode 100644
index 0000000..347f964
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core/0002-Remove-unused-include-for-execinfo.h.patch
@@ -0,0 +1,27 @@
+From 3d9cae15c69c0b3260a024ad5d6802a8d85515a2 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 12 Jun 2018 19:18:24 -0700
+Subject: [PATCH 2/2] Remove unused include for execinfo.h
+
+Fixes build on musl
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ providers/qedr/qelr_verbs.c | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/providers/qedr/qelr_verbs.c b/providers/qedr/qelr_verbs.c
+index e3b01f28..2ee1c832 100644
+--- a/providers/qedr/qelr_verbs.c
++++ b/providers/qedr/qelr_verbs.c
+@@ -54,7 +54,6 @@
+ 
+ #include <stdio.h>
+ #include <stdlib.h>
+-#include <execinfo.h>
+ 
+ #define QELR_SQE_ELEMENT_SIZE	(sizeof(struct rdma_sq_sge))
+ #define QELR_RQE_ELEMENT_SIZE	(sizeof(struct rdma_rq_sge))
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core/0002-neigh.c-Do-not-include-net-if_packet.h.patch b/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core/0002-neigh.c-Do-not-include-net-if_packet.h.patch
new file mode 100644
index 0000000..e887f22
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core/0002-neigh.c-Do-not-include-net-if_packet.h.patch
@@ -0,0 +1,26 @@
+From 82486f7e1ee2aa07a5c12cb357834993aa8c1d20 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 8 Jun 2018 20:19:13 -0700
+Subject: [PATCH] neigh.c: Do not include net/if_packet.h
+
+This header is glibc specific
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ libibverbs/neigh.c | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/libibverbs/neigh.c b/libibverbs/neigh.c
+index 21177db0..cfc593a0 100644
+--- a/libibverbs/neigh.c
++++ b/libibverbs/neigh.c
+@@ -2,7 +2,6 @@
+  */
+ 
+ #include "config.h"
+-#include <net/if_packet.h>
+ #include <linux/netlink.h>
+ #include <linux/rtnetlink.h>
+ #include <endian.h>
diff --git a/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core_18.1.bb b/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core_18.1.bb
new file mode 100644
index 0000000..6ad864d
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/rdma-core/rdma-core_18.1.bb
@@ -0,0 +1,30 @@
+SUMMARY = "Userspace support for InfiniBand/RDMA verbs"
+DESCRIPTION = "This is the userspace components for the Linux Kernel's drivers Infiniband/RDMA subsystem."
+SECTION = "libs"
+
+DEPENDS = "libnl"
+RDEPENDS_${PN} = "bash perl"
+
+SRC_URI = "git://github.com/linux-rdma/rdma-core.git;branch=stable-v18 \
+           file://0001-S_IFSOCK-is-defined-in-both-glibc-musl.patch \
+           file://0002-neigh.c-Do-not-include-net-if_packet.h.patch \
+           file://0001-include-endian.h-for-htole32-and-friends.patch \
+           file://0002-Remove-unused-include-for-execinfo.h.patch \
+           file://0001-Remove-man-files-which-cant-be-built.patch \
+           "
+SRCREV = "7844b3fbe5120623d63b29ecb43eb83a61129658"
+S = "${WORKDIR}/git"
+
+#Default Dual License https://github.com/linux-rdma/rdma-core/blob/master/COPYING.md
+LICENSE = "BSD-2-Clause | GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING.BSD_FB;md5=0ec18bae1a9df92c8d6ae01f94a289ae \
+		   file://COPYING.GPL2;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+
+FILES_SOLIBSDEV = ""
+FILES_${PN} += "${libdir}/*"
+INSANE_SKIP_${PN} += "dev-so"
+
+inherit cmake
+
+OECMAKE_FIND_ROOT_PATH_MODE_PROGRAM = "BOTH"
diff --git a/meta-openembedded/meta-networking/recipes-support/spice/spice-protocol_git.bb b/meta-openembedded/meta-networking/recipes-support/spice/spice-protocol_git.bb
new file mode 100644
index 0000000..30d0a76
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/spice/spice-protocol_git.bb
@@ -0,0 +1,28 @@
+#
+# Copyright (C) 2013 Wind River Systems, Inc.
+#
+
+SUMMARY = "Simple Protocol for Independent Computing Environments"
+DESCRIPTION = "SPICE (the Simple Protocol for Independent Computing \
+Environments) is a remote-display system built for virtual \
+environments which allows users to view a computing 'desktop' \ 
+environment - not only on its computer-server machine, but also from \
+anywhere on the Internet and using a wide variety of machine \
+architectures."
+
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b37311cb5604f3e5cc2fb0fd23527e95"
+
+PV = "0.12.13+git${SRCPV}"
+
+SRCREV = "87441524f4e7b79658e42bd8f1f6c3e3c8649aa5"
+
+SRC_URI = " \
+    git://anongit.freedesktop.org/spice/spice-protocol \
+"
+
+S = "${WORKDIR}/git"
+
+inherit autotools gettext pkgconfig
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-networking/recipes-support/spice/spice/0001-Convert-pthread_t-to-be-numeric.patch b/meta-openembedded/meta-networking/recipes-support/spice/spice/0001-Convert-pthread_t-to-be-numeric.patch
new file mode 100644
index 0000000..505b7c8
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/spice/spice/0001-Convert-pthread_t-to-be-numeric.patch
@@ -0,0 +1,66 @@
+From 0726ce6d6f52e135e28f15ca8392568c84909b1d Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 16 Jun 2018 16:21:39 -0700
+Subject: [PATCH] Convert pthread_t to be numeric
+
+typecast pthread_t to unsigned long
+pthread_t is implemented as a struct point in musl and its as per standard
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ server/red-channel.c | 5 +++--
+ server/red-client.c  | 6 +++---
+ 2 files changed, 6 insertions(+), 5 deletions(-)
+
+diff --git a/server/red-channel.c b/server/red-channel.c
+index 1b38f04d..11dc667b 100644
+--- a/server/red-channel.c
++++ b/server/red-channel.c
+@@ -192,7 +192,7 @@ red_channel_constructed(GObject *object)
+ {
+     RedChannel *self = RED_CHANNEL(object);
+ 
+-    red_channel_debug(self, "thread_id 0x%lx", self->priv->thread_id);
++    red_channel_debug(self, "thread_id 0x%lx", (unsigned long)self->priv->thread_id);
+ 
+     RedChannelClass *klass = RED_CHANNEL_GET_CLASS(self);
+ 
+@@ -475,7 +475,8 @@ void red_channel_remove_client(RedChannel *channel, RedChannelClient *rcc)
+         red_channel_warning(channel, "channel->thread_id (0x%lx) != pthread_self (0x%lx)."
+                             "If one of the threads is != io-thread && != vcpu-thread, "
+                             "this might be a BUG",
+-                            channel->priv->thread_id, pthread_self());
++                            (unsigned long)channel->priv->thread_id,
++                            (unsigned long)pthread_self());
+     }
+     spice_return_if_fail(channel);
+     link = g_list_find(channel->priv->clients, rcc);
+diff --git a/server/red-client.c b/server/red-client.c
+index ddfc5400..76986640 100644
+--- a/server/red-client.c
++++ b/server/red-client.c
+@@ -180,7 +180,7 @@ void red_client_migrate(RedClient *client)
+         spice_warning("client->thread_id (0x%lx) != pthread_self (0x%lx)."
+                       "If one of the threads is != io-thread && != vcpu-thread,"
+                       " this might be a BUG",
+-                      client->thread_id, pthread_self());
++                      (unsigned long)client->thread_id, (unsigned long)pthread_self());
+     }
+     FOREACH_CHANNEL_CLIENT(client, rcc) {
+         if (red_channel_client_is_connected(rcc)) {
+@@ -199,8 +199,8 @@ void red_client_destroy(RedClient *client)
+         spice_warning("client->thread_id (0x%lx) != pthread_self (0x%lx)."
+                       "If one of the threads is != io-thread && != vcpu-thread,"
+                       " this might be a BUG",
+-                      client->thread_id,
+-                      pthread_self());
++                      (unsigned long)client->thread_id,
++                      (unsigned long)pthread_self());
+     }
+     red_client_set_disconnecting(client);
+     FOREACH_CHANNEL_CLIENT(client, rcc) {
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-networking/recipes-support/spice/spice/0001-spice-fix-compile-fail-problem.patch b/meta-openembedded/meta-networking/recipes-support/spice/spice/0001-spice-fix-compile-fail-problem.patch
new file mode 100644
index 0000000..1f9d5fd
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/spice/spice/0001-spice-fix-compile-fail-problem.patch
@@ -0,0 +1,36 @@
+From 7023732c65b4dc509c46a54fb7715da275b5597f Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Thu, 13 Sep 2018 12:39:44 +0800
+Subject: [PATCH] spice: fix compile fail problem
+
+compile error:
+format '%d' expects argument of type 'int', but argument 6 has 
+type 'long unsigned int' [-Werror=format=]
+
+spice compile failed on 32bit system, since upstream commit
+9541cd2fe(in V0.14.1) change %ld to %PRIdPTR, %PRIdPTR is %d, but argument
+strm.total_out is uLong.
+
+Upstream-Status: Submitted[https://github.com/freedesktop/spice/pull/1]
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ server/red-replay-qxl.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/server/red-replay-qxl.c b/server/red-replay-qxl.c
+index 1fce76c..bd33b58 100644
+--- a/server/red-replay-qxl.c
++++ b/server/red-replay-qxl.c
+@@ -266,7 +266,7 @@ static replay_t read_binary(SpiceReplay *replay, const char *prefix, size_t *siz
+             exit(1);
+         }
+         if ((ret = inflate(&strm, Z_NO_FLUSH)) != Z_STREAM_END) {
+-            spice_error("inflate error %d (disc: %" PRIdPTR ")", ret, *size - strm.total_out);
++            spice_error("inflate error %d (disc: %ld)", ret, *size - strm.total_out);
+             if (ret == Z_DATA_ERROR) {
+                 /* last operation may be wrong. since we do the recording
+                  * in red_worker, when there is a shutdown from the vcpu/io thread
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-networking/recipes-support/spice/spice_git.bb b/meta-openembedded/meta-networking/recipes-support/spice/spice_git.bb
new file mode 100644
index 0000000..1ad46c2
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/spice/spice_git.bb
@@ -0,0 +1,57 @@
+#
+# Copyright (C) 2013 Wind River Systems, Inc.
+#
+
+SUMMARY = "Simple Protocol for Independent Computing Environments"
+DESCRIPTION = "SPICE (the Simple Protocol for Independent Computing \
+Environments) is a remote-display system built for virtual \
+environments which allows users to view a computing 'desktop' \ 
+environment - not only on its computer-server machine, but also from \
+anywhere on the Internet and using a wide variety of machine \
+architectures."
+
+LICENSE = "BSD & LGPLv2.1+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
+
+PV = "0.14.1+git${SRCPV}"
+
+SRCREV_spice = "eaa07ef15cfc3bf57a69da2576af66f028787774"
+SRCREV_spice-common = "6b93b3fce8909b836ef1d1434d191900d8aa00be"
+
+SRCREV_FORMAT = "spice_spice-common"
+
+SRC_URI = " \
+    git://anongit.freedesktop.org/spice/spice;name=spice \
+    git://anongit.freedesktop.org/spice/spice-common;destsuffix=git/subprojects/spice-common;name=spice-common \
+    file://0001-Convert-pthread_t-to-be-numeric.patch \
+    file://0001-spice-fix-compile-fail-problem.patch \
+"
+
+S = "${WORKDIR}/git"
+
+inherit autotools gettext pythonnative python-dir pkgconfig
+
+DEPENDS += "spice-protocol jpeg pixman alsa-lib glib-2.0 python-pyparsing-native python-six-native glib-2.0-native"
+DEPENDS_append_class-nativesdk = "nativesdk-openssl"
+
+export PYTHON="${STAGING_BINDIR_NATIVE}/python-native/python"
+export PYTHONPATH="${PKG_CONFIG_SYSROOT_DIR}${libdir}/python2.7/site-packages"
+
+PACKAGECONFIG_class-native = ""
+PACKAGECONFIG_class-nativesdk = ""
+PACKAGECONFIG ?= "sasl"
+
+PACKAGECONFIG[celt051] = "--enable-celt051,--disable-celt051,celt051"
+PACKAGECONFIG[smartcard] = "--enable-smartcard,--disable-smartcard,libcacard,"
+PACKAGECONFIG[sasl] = "--with-sasl,--without-sasl,cyrus-sasl,"
+PACKAGECONFIG[client] = "--enable-client,--disable-client,,"
+PACKAGECONFIG[gui] = "--enable-gui,--disable-gui,,"
+PACKAGECONFIG[opus] = "--enable-opus,--disable-opus,libopus,"
+PACKAGECONFIG[opengl] = "--enable-opengl,--disable-opengl,,"
+PACKAGECONFIG[xinerama] = "--enable-xinerama,--disable-xinerama,libxinerama,"
+
+COMPATIBLE_HOST = '(x86_64|i.86).*-linux'
+
+BBCLASSEXTEND = "native nativesdk"
+
+EXTRA_OECONF_toolchain-clang += "--disable-werror"
diff --git a/meta-openembedded/meta-networking/recipes-support/spice/usbredir_git.bb b/meta-openembedded/meta-networking/recipes-support/spice/usbredir_git.bb
new file mode 100644
index 0000000..3fea752
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/spice/usbredir_git.bb
@@ -0,0 +1,21 @@
+SUMMARY = "usbredir libraries and utilities"
+
+LICENSE = "GPLv2+ & LGPLv2.1+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+    file://COPYING.LIB;md5=4b54a1fd55a448865a0b32d41598759d \
+"
+
+DEPENDS = "libusb1"
+
+SRCREV = "39aa3c69f61bba28856a3eef3fe4ab37a3968e88"
+PV = "0.7.1+git${SRCPV}"
+
+SRC_URI = " \
+    git://anongit.freedesktop.org/spice/usbredir \
+"
+
+S = "${WORKDIR}/git"
+
+inherit autotools pkgconfig
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-networking/recipes-support/strongswan/files/fix-funtion-parameter.patch b/meta-openembedded/meta-networking/recipes-support/strongswan/files/fix-funtion-parameter.patch
index be660d1..5945507 100644
--- a/meta-openembedded/meta-networking/recipes-support/strongswan/files/fix-funtion-parameter.patch
+++ b/meta-openembedded/meta-networking/recipes-support/strongswan/files/fix-funtion-parameter.patch
@@ -3,7 +3,7 @@
 Date: Tue, 4 Mar 2014 14:38:42 +0800
 Subject: [PATCH] fix the function parameter
 
-Upstream-Status: pending
+Upstream-Status: Pending
 
 Original openssl_diffie_hellman_create has three parameters, but
 it is reassigned a function pointer which has one parameter, and
diff --git a/meta-openembedded/meta-networking/recipes-support/strongswan/strongswan_5.6.2.bb b/meta-openembedded/meta-networking/recipes-support/strongswan/strongswan_5.6.2.bb
deleted file mode 100644
index f2fe1f1..0000000
--- a/meta-openembedded/meta-networking/recipes-support/strongswan/strongswan_5.6.2.bb
+++ /dev/null
@@ -1,132 +0,0 @@
-DESCRIPTION = "strongSwan is an OpenSource IPsec implementation for the \
-Linux operating system."
-SUMMARY = "strongSwan is an OpenSource IPsec implementation"
-HOMEPAGE = "http://www.strongswan.org"
-SECTION = "net"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-DEPENDS = "gmp openssl flex-native flex bison-native"
-
-SRC_URI = "http://download.strongswan.org/strongswan-${PV}.tar.bz2 \
-           file://fix-funtion-parameter.patch \
-           file://0001-memory.h-Include-stdint.h-for-uintptr_t.patch \
-           "
-
-SRC_URI[md5sum] = "46aa3aa18fbc4bd528f9a0345ce79913"
-SRC_URI[sha256sum] = "e0a60a30ebf3c534c223559e1686497a21ded709a5d605c5123c2f52bcc22e92"
-
-EXTRA_OECONF = " \
-        --without-lib-prefix \
-"
-
-EXTRA_OECONF += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '--with-systemdsystemunitdir=${systemd_unitdir}/system/', '--without-systemdsystemunitdir', d)}"
-
-
-PACKAGECONFIG ??= "charon curl gmp openssl stroke sqlite3 \
-        ${@bb.utils.filter('DISTRO_FEATURES', 'ldap', d)} \
-"
-PACKAGECONFIG[aesni] = "--enable-aesni,--disable-aesni,,${PN}-plugin-aesni"
-PACKAGECONFIG[charon] = "--enable-charon,--disable-charon,"
-PACKAGECONFIG[curl] = "--enable-curl,--disable-curl,curl,${PN}-plugin-curl"
-PACKAGECONFIG[gmp] = "--enable-gmp,--disable-gmp,gmp,${PN}-plugin-gmp"
-PACKAGECONFIG[ldap] = "--enable-ldap,--disable-ldap,openldap,${PN}-plugin-ldap"
-PACKAGECONFIG[mysql] = "--enable-mysql,--disable-mysql,mysql5,${PN}-plugin-mysql"
-PACKAGECONFIG[openssl] = "--enable-openssl,--disable-openssl,openssl,${PN}-plugin-openssl"
-PACKAGECONFIG[scep] = "--enable-scepclient,--disable-scepclient,"
-PACKAGECONFIG[soup] = "--enable-soup,--disable-soup,libsoup-2.4,${PN}-plugin-soup"
-PACKAGECONFIG[sqlite3] = "--enable-sqlite,--disable-sqlite,sqlite3,${PN}-plugin-sqlite"
-PACKAGECONFIG[stroke] = "--enable-stroke,--disable-stroke,,${PN}-plugin-stroke"
-PACKAGECONFIG[swanctl] = "--enable-swanctl,--disable-swanctl,,libgcc"
-
-# requires swanctl
-PACKAGECONFIG[systemd-charon] = "--enable-systemd,--disable-systemd,systemd,"
-
-inherit autotools systemd pkgconfig
-
-RRECOMMENDS_${PN} = "kernel-module-ipsec"
-
-FILES_${PN} += "${libdir}/ipsec/lib*${SOLIBS}"
-FILES_${PN}-dbg += "${bindir}/.debug ${libdir}/ipsec/.debug ${libexecdir}/ipsec/.debug"
-FILES_${PN}-dev += "${libdir}/ipsec/lib*${SOLIBSDEV} ${libdir}/ipsec/*.la"
-FILES_${PN}-staticdev += "${libdir}/ipsec/*.a"
-
-CONFFILES_${PN} = "${sysconfdir}/*.conf ${sysconfdir}/ipsec.d/*.conf ${sysconfdir}/strongswan.d/*.conf"
-
-PACKAGES += "${PN}-plugins"
-ALLOW_EMPTY_${PN}-plugins = "1"
-
-PACKAGES_DYNAMIC += "^${PN}-plugin-.*$"
-NOAUTOPACKAGEDEBUG = "1"
-
-python split_strongswan_plugins () {
-    sysconfdir = d.expand('${sysconfdir}/strongswan.d/charon')
-    libdir = d.expand('${libdir}/ipsec/plugins')
-    dbglibdir = os.path.join(libdir, '.debug')
-
-    def add_plugin_conf(f, pkg, file_regex, output_pattern, modulename):
-        dvar = d.getVar('PKGD', True)
-        oldfiles = d.getVar('CONFFILES_' + pkg, True)
-        newfile = '/' + os.path.relpath(f, dvar)
-
-        if not oldfiles:
-            d.setVar('CONFFILES_' + pkg, newfile)
-        else:
-            d.setVar('CONFFILES_' + pkg, oldfiles + " " + newfile)
-
-    split_packages = do_split_packages(d, libdir, 'libstrongswan-(.*)\.so', '${PN}-plugin-%s', 'strongSwan %s plugin', prepend=True)
-    do_split_packages(d, sysconfdir, '(.*)\.conf', '${PN}-plugin-%s', 'strongSwan %s plugin', prepend=True, hook=add_plugin_conf)
-
-    split_dbg_packages = do_split_packages(d, dbglibdir, 'libstrongswan-(.*)\.so', '${PN}-plugin-%s-dbg', 'strongSwan %s plugin - Debugging files', prepend=True, extra_depends='${PN}-dbg')
-    split_dev_packages = do_split_packages(d, libdir, 'libstrongswan-(.*)\.la', '${PN}-plugin-%s-dev', 'strongSwan %s plugin - Development files', prepend=True, extra_depends='${PN}-dev')
-    split_staticdev_packages = do_split_packages(d, libdir, 'libstrongswan-(.*)\.a', '${PN}-plugin-%s-staticdev', 'strongSwan %s plugin - Development files (Static Libraries)', prepend=True, extra_depends='${PN}-staticdev')
-
-    if split_packages:
-        pn = d.getVar('PN', True)
-        d.setVar('RRECOMMENDS_' + pn + '-plugins', ' '.join(split_packages))
-        d.appendVar('RRECOMMENDS_' + pn + '-dbg', ' ' + ' '.join(split_dbg_packages))
-        d.appendVar('RRECOMMENDS_' + pn + '-dev', ' ' + ' '.join(split_dev_packages))
-        d.appendVar('RRECOMMENDS_' + pn + '-staticdev', ' ' + ' '.join(split_staticdev_packages))
-}
-
-PACKAGESPLITFUNCS_prepend = "split_strongswan_plugins "
-
-# Install some default plugins based on default strongSwan ./configure options
-# See https://wiki.strongswan.org/projects/strongswan/wiki/Pluginlist
-RDEPENDS_${PN} += "\
-    ${PN}-plugin-aes \
-    ${PN}-plugin-attr \
-    ${PN}-plugin-cmac \
-    ${PN}-plugin-constraints \
-    ${PN}-plugin-des \
-    ${PN}-plugin-dnskey \
-    ${PN}-plugin-hmac \
-    ${PN}-plugin-kernel-netlink \
-    ${PN}-plugin-md5 \
-    ${PN}-plugin-nonce \
-    ${PN}-plugin-pem \
-    ${PN}-plugin-pgp \
-    ${PN}-plugin-pkcs1 \
-    ${PN}-plugin-pkcs7 \
-    ${PN}-plugin-pkcs8 \
-    ${PN}-plugin-pkcs12 \
-    ${PN}-plugin-pubkey \
-    ${PN}-plugin-random \
-    ${PN}-plugin-rc2 \
-    ${PN}-plugin-resolve \
-    ${PN}-plugin-revocation \
-    ${PN}-plugin-sha1 \
-    ${PN}-plugin-sha2 \
-    ${PN}-plugin-socket-default \
-    ${PN}-plugin-sshkey \
-    ${PN}-plugin-updown \
-    ${PN}-plugin-vici \
-    ${PN}-plugin-x509 \
-    ${PN}-plugin-xauth-generic \
-    ${PN}-plugin-xcbc \
-    ${PN}-plugin-curve25519 \
-    "
-
-RPROVIDES_${PN} += "${PN}-systemd"
-RREPLACES_${PN} += "${PN}-systemd"
-RCONFLICTS_${PN} += "${PN}-systemd"
-SYSTEMD_SERVICE_${PN} = "${@bb.utils.contains('PACKAGECONFIG', 'swanctl', '${BPN}-swanctl.service', '${BPN}.service', d)}"
diff --git a/meta-openembedded/meta-networking/recipes-support/strongswan/strongswan_5.7.1.bb b/meta-openembedded/meta-networking/recipes-support/strongswan/strongswan_5.7.1.bb
new file mode 100644
index 0000000..c8bb17c
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/strongswan/strongswan_5.7.1.bb
@@ -0,0 +1,134 @@
+DESCRIPTION = "strongSwan is an OpenSource IPsec implementation for the \
+Linux operating system."
+SUMMARY = "strongSwan is an OpenSource IPsec implementation"
+HOMEPAGE = "http://www.strongswan.org"
+SECTION = "net"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+DEPENDS = "gmp openssl flex-native flex bison-native"
+
+SRC_URI = "http://download.strongswan.org/strongswan-${PV}.tar.bz2 \
+           file://fix-funtion-parameter.patch \
+           file://0001-memory.h-Include-stdint.h-for-uintptr_t.patch \
+           "
+
+SRC_URI[md5sum] = "86b7e9321cde075cf382268fd282e0b0"
+SRC_URI[sha256sum] = "006f9c9126e2a2f4e7a874b5e1bd2abec1bbbb193c8b3b3a4c6ccd8c2d454bec"
+
+UPSTREAM_CHECK_REGEX = "strongswan-(?P<pver>\d+(\.\d+)+)\.tar"
+
+EXTRA_OECONF = " \
+        --without-lib-prefix \
+"
+
+EXTRA_OECONF += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '--with-systemdsystemunitdir=${systemd_unitdir}/system/', '--without-systemdsystemunitdir', d)}"
+
+
+PACKAGECONFIG ??= "charon curl gmp openssl stroke sqlite3 \
+        ${@bb.utils.filter('DISTRO_FEATURES', 'ldap', d)} \
+"
+PACKAGECONFIG[aesni] = "--enable-aesni,--disable-aesni,,${PN}-plugin-aesni"
+PACKAGECONFIG[charon] = "--enable-charon,--disable-charon,"
+PACKAGECONFIG[curl] = "--enable-curl,--disable-curl,curl,${PN}-plugin-curl"
+PACKAGECONFIG[gmp] = "--enable-gmp,--disable-gmp,gmp,${PN}-plugin-gmp"
+PACKAGECONFIG[ldap] = "--enable-ldap,--disable-ldap,openldap,${PN}-plugin-ldap"
+PACKAGECONFIG[mysql] = "--enable-mysql,--disable-mysql,mysql5,${PN}-plugin-mysql"
+PACKAGECONFIG[openssl] = "--enable-openssl,--disable-openssl,openssl,${PN}-plugin-openssl"
+PACKAGECONFIG[scep] = "--enable-scepclient,--disable-scepclient,"
+PACKAGECONFIG[soup] = "--enable-soup,--disable-soup,libsoup-2.4,${PN}-plugin-soup"
+PACKAGECONFIG[sqlite3] = "--enable-sqlite,--disable-sqlite,sqlite3,${PN}-plugin-sqlite"
+PACKAGECONFIG[stroke] = "--enable-stroke,--disable-stroke,,${PN}-plugin-stroke"
+PACKAGECONFIG[swanctl] = "--enable-swanctl,--disable-swanctl,,libgcc"
+
+# requires swanctl
+PACKAGECONFIG[systemd-charon] = "--enable-systemd,--disable-systemd,systemd,"
+
+inherit autotools systemd pkgconfig
+
+RRECOMMENDS_${PN} = "kernel-module-ipsec"
+
+FILES_${PN} += "${libdir}/ipsec/lib*${SOLIBS}"
+FILES_${PN}-dbg += "${bindir}/.debug ${libdir}/ipsec/.debug ${libexecdir}/ipsec/.debug"
+FILES_${PN}-dev += "${libdir}/ipsec/lib*${SOLIBSDEV} ${libdir}/ipsec/*.la"
+FILES_${PN}-staticdev += "${libdir}/ipsec/*.a"
+
+CONFFILES_${PN} = "${sysconfdir}/*.conf ${sysconfdir}/ipsec.d/*.conf ${sysconfdir}/strongswan.d/*.conf"
+
+PACKAGES += "${PN}-plugins"
+ALLOW_EMPTY_${PN}-plugins = "1"
+
+PACKAGES_DYNAMIC += "^${PN}-plugin-.*$"
+NOAUTOPACKAGEDEBUG = "1"
+
+python split_strongswan_plugins () {
+    sysconfdir = d.expand('${sysconfdir}/strongswan.d/charon')
+    libdir = d.expand('${libdir}/ipsec/plugins')
+    dbglibdir = os.path.join(libdir, '.debug')
+
+    def add_plugin_conf(f, pkg, file_regex, output_pattern, modulename):
+        dvar = d.getVar('PKGD', True)
+        oldfiles = d.getVar('CONFFILES_' + pkg, True)
+        newfile = '/' + os.path.relpath(f, dvar)
+
+        if not oldfiles:
+            d.setVar('CONFFILES_' + pkg, newfile)
+        else:
+            d.setVar('CONFFILES_' + pkg, oldfiles + " " + newfile)
+
+    split_packages = do_split_packages(d, libdir, 'libstrongswan-(.*)\.so', '${PN}-plugin-%s', 'strongSwan %s plugin', prepend=True)
+    do_split_packages(d, sysconfdir, '(.*)\.conf', '${PN}-plugin-%s', 'strongSwan %s plugin', prepend=True, hook=add_plugin_conf)
+
+    split_dbg_packages = do_split_packages(d, dbglibdir, 'libstrongswan-(.*)\.so', '${PN}-plugin-%s-dbg', 'strongSwan %s plugin - Debugging files', prepend=True, extra_depends='${PN}-dbg')
+    split_dev_packages = do_split_packages(d, libdir, 'libstrongswan-(.*)\.la', '${PN}-plugin-%s-dev', 'strongSwan %s plugin - Development files', prepend=True, extra_depends='${PN}-dev')
+    split_staticdev_packages = do_split_packages(d, libdir, 'libstrongswan-(.*)\.a', '${PN}-plugin-%s-staticdev', 'strongSwan %s plugin - Development files (Static Libraries)', prepend=True, extra_depends='${PN}-staticdev')
+
+    if split_packages:
+        pn = d.getVar('PN', True)
+        d.setVar('RRECOMMENDS_' + pn + '-plugins', ' '.join(split_packages))
+        d.appendVar('RRECOMMENDS_' + pn + '-dbg', ' ' + ' '.join(split_dbg_packages))
+        d.appendVar('RRECOMMENDS_' + pn + '-dev', ' ' + ' '.join(split_dev_packages))
+        d.appendVar('RRECOMMENDS_' + pn + '-staticdev', ' ' + ' '.join(split_staticdev_packages))
+}
+
+PACKAGESPLITFUNCS_prepend = "split_strongswan_plugins "
+
+# Install some default plugins based on default strongSwan ./configure options
+# See https://wiki.strongswan.org/projects/strongswan/wiki/Pluginlist
+RDEPENDS_${PN} += "\
+    ${PN}-plugin-aes \
+    ${PN}-plugin-attr \
+    ${PN}-plugin-cmac \
+    ${PN}-plugin-constraints \
+    ${PN}-plugin-des \
+    ${PN}-plugin-dnskey \
+    ${PN}-plugin-hmac \
+    ${PN}-plugin-kernel-netlink \
+    ${PN}-plugin-md5 \
+    ${PN}-plugin-nonce \
+    ${PN}-plugin-pem \
+    ${PN}-plugin-pgp \
+    ${PN}-plugin-pkcs1 \
+    ${PN}-plugin-pkcs7 \
+    ${PN}-plugin-pkcs8 \
+    ${PN}-plugin-pkcs12 \
+    ${PN}-plugin-pubkey \
+    ${PN}-plugin-random \
+    ${PN}-plugin-rc2 \
+    ${PN}-plugin-resolve \
+    ${PN}-plugin-revocation \
+    ${PN}-plugin-sha1 \
+    ${PN}-plugin-sha2 \
+    ${PN}-plugin-socket-default \
+    ${PN}-plugin-sshkey \
+    ${PN}-plugin-updown \
+    ${PN}-plugin-vici \
+    ${PN}-plugin-x509 \
+    ${PN}-plugin-xauth-generic \
+    ${PN}-plugin-xcbc \
+    ${PN}-plugin-curve25519 \
+    "
+
+RPROVIDES_${PN} += "${PN}-systemd"
+RREPLACES_${PN} += "${PN}-systemd"
+RCONFLICTS_${PN} += "${PN}-systemd"
+SYSTEMD_SERVICE_${PN} = "${@bb.utils.contains('PACKAGECONFIG', 'swanctl', '${BPN}-swanctl.service', '${BPN}.service', d)}"
diff --git a/meta-openembedded/meta-networking/recipes-support/stunnel/stunnel_5.35.bb b/meta-openembedded/meta-networking/recipes-support/stunnel/stunnel_5.35.bb
deleted file mode 100644
index ec8478d..0000000
--- a/meta-openembedded/meta-networking/recipes-support/stunnel/stunnel_5.35.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-SUMMARY = "Program for providing universal TLS/SSL tunneling service"
-HOMEPAGE = "http://www.stunnel.org/"
-DESCRIPTION = "SSL encryption wrapper between remote client and local (inetd-startable) or remote server."
-SECTION = "net"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=866cdc7459d91e092b174388fab8d283"
-DEPENDS = "openssl zlib tcp-wrappers"
-
-RDEPENDS_${PN} += "perl"
-
-SRC_URI = "ftp://ftp.stunnel.org/stunnel/archive/5.x/${BP}.tar.gz \
-           file://fix-openssl-no-des.patch \
-"
-
-SRC_URI[md5sum] = "9079f5fafbccaf88b7d92b227d78249a"
-SRC_URI[sha256sum] = "ffa386ae4c825f35f35157c285e7402a6d58779ad8c3822f74a9d355b54aba1d"
-
-inherit autotools
-
-EXTRA_OECONF += "--with-ssl='${STAGING_EXECPREFIXDIR}' --disable-fips"
-
-PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6 systemd', d)}"
-PACKAGECONFIG[systemd] = "--enable-systemd,--disable-systemd,systemd"
-PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
diff --git a/meta-openembedded/meta-networking/recipes-support/stunnel/stunnel_5.49.bb b/meta-openembedded/meta-networking/recipes-support/stunnel/stunnel_5.49.bb
new file mode 100644
index 0000000..eca77cf
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/stunnel/stunnel_5.49.bb
@@ -0,0 +1,37 @@
+SUMMARY = "Program for providing universal TLS/SSL tunneling service"
+DESCRIPTION = "SSL encryption wrapper between remote client and local (inetd-startable) or remote server."
+HOMEPAGE = "https://www.stunnel.org/"
+SECTION = "net"
+# Note: Linking stunnel statically or dynamically with other modules is making
+# a combined work based on stunnel. Thus, the terms and conditions of the GNU
+# General Public License cover the whole combination.
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=f6b7fe7379c9c2d7db6c80f7bd41e06d"
+
+DEPENDS = "autoconf-archive libnsl2 openssl"
+
+SRC_URI = "ftp://ftp.stunnel.org/stunnel/archive/5.x/${BP}.tar.gz \
+           file://fix-openssl-no-des.patch \
+"
+
+SRC_URI[md5sum] = "0b41240e5585ec7d55ca343feed5530f"
+SRC_URI[sha256sum] = "3d6641213a82175c19f23fde1c3d1c841738385289eb7ca1554f4a58b96d955e"
+
+inherit autotools
+
+PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6 systemd', d)} libwrap"
+
+PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
+PACKAGECONFIG[libwrap] = "--enable-libwrap,--disable-libwrap,tcp-wrappers"
+PACKAGECONFIG[systemd] = "--enable-systemd,--disable-systemd,systemd"
+
+EXTRA_OECONF += "--with-ssl='${STAGING_EXECPREFIXDIR}' --disable-fips"
+
+# When cross compiling, configure defaults to nobody, but provides no option to change it.
+EXTRA_OEMAKE += "DEFAULT_GROUP='nogroup'"
+
+# stunnel3 is a Perl wrapper to allow use of the legacy stunnel 3.x commandline
+# syntax with stunnel >= 4.05
+PACKAGES =+ "stunnel3"
+FILES_stunnel3 = "${bindir}/stunnel3"
+RDEPENDS_stunnel3 += "${PN} perl"
diff --git a/meta-openembedded/meta-networking/recipes-support/tinyproxy/tinyproxy/disable-documentation.patch b/meta-openembedded/meta-networking/recipes-support/tinyproxy/tinyproxy/disable-documentation.patch
index 01d0236..91508d7 100644
--- a/meta-openembedded/meta-networking/recipes-support/tinyproxy/tinyproxy/disable-documentation.patch
+++ b/meta-openembedded/meta-networking/recipes-support/tinyproxy/tinyproxy/disable-documentation.patch
@@ -1,19 +1,40 @@
---- a/configure.ac	2016-01-01 17:42:27.000000000 +0100
-+++ b/configure.ac	2017-04-20 14:03:37.238254471 +0200
-@@ -284,24 +284,12 @@
- AC_SUBST(LIBS)
- AC_SUBST(ADDITIONAL_OBJECTS)
+From b71eb384522b5ce4629dee6e8be257fb4880fef3 Mon Sep 17 00:00:00 2001
+From: Benjamin Gaignard <benjamin.gaignard@linaro.org>
+Date: Thu, 20 Apr 2017 14:25:18 +0200
+
+---
+ Makefile.am  | 1 -
+ configure.ac | 9 ---------
+ 2 files changed, 10 deletions(-)
+
+diff --git a/Makefile.am b/Makefile.am
+index e9113c2..2fe3d54 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -2,7 +2,6 @@ SUBDIRS = \
+ 	src \
+ 	data \
+ 	etc \
+-	docs \
+ 	m4macros \
+ 	tests
+ 
+diff --git a/configure.ac b/configure.ac
+index 48ee0b2..a1a5fa1 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -194,10 +194,6 @@ AC_SUBST(ADDITIONAL_OBJECTS)
+ AC_PATH_PROG(XSLTPROC, xsltproc, no)
+ AM_CONDITIONAL(HAVE_XSLTPROC, test "x$XSLTPROC" != "xno")
  
 -# Check for asciidoc
 -AC_PATH_PROG(A2X, a2x, no)
 -AM_CONDITIONAL(HAVE_A2X, test "x$A2X" != "xno")
--if test x"$A2X" = x"no"; then
--  AC_MSG_ERROR([Test for asciidoc failed. See the file 'INSTALL' for help.])
--fi
 -
- AC_CONFIG_FILES([
- Makefile
- src/Makefile
+ # checking xmllint
+ AC_PATH_PROG(XMLLINT, xmllint, no)
+ if test "x$XMLLINT" != "xno"; then
+@@ -219,11 +215,6 @@ src/Makefile
  data/Makefile
  data/templates/Makefile
  etc/Makefile
@@ -25,13 +46,3 @@
  m4macros/Makefile
  tests/Makefile
  tests/scripts/Makefile
---- a/Makefile.am	2016-01-01 17:42:27.000000000 +0100
-+++ b/Makefile.am	2017-04-20 14:03:53.842822997 +0200
-@@ -2,7 +2,6 @@
- 	src \
- 	data \
- 	etc \
--	docs \
- 	m4macros \
- 	tests
- 
diff --git a/meta-openembedded/meta-networking/recipes-support/tinyproxy/tinyproxy/tinyproxy.service b/meta-openembedded/meta-networking/recipes-support/tinyproxy/tinyproxy/tinyproxy.service
index ea079f9..df42745 100644
--- a/meta-openembedded/meta-networking/recipes-support/tinyproxy/tinyproxy/tinyproxy.service
+++ b/meta-openembedded/meta-networking/recipes-support/tinyproxy/tinyproxy/tinyproxy.service
@@ -8,7 +8,7 @@
 ExecStartPre=/bin/chown -R nobody.tinyproxy /var/log/tinyproxy
 ExecStartPre=/bin/mkdir -p /var/run/tinyproxy
 ExecStartPre=/bin/chown -R nobody.tinyproxy /var/run/tinyproxy
-ExecStart=/usr/sbin/tinyproxy -d
+ExecStart=/usr/bin/tinyproxy -d
 
 [Install]
 WantedBy=multi-user.target
diff --git a/meta-openembedded/meta-networking/recipes-support/tinyproxy/tinyproxy_1.10.0.bb b/meta-openembedded/meta-networking/recipes-support/tinyproxy/tinyproxy_1.10.0.bb
new file mode 100644
index 0000000..144dcf3
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/tinyproxy/tinyproxy_1.10.0.bb
@@ -0,0 +1,37 @@
+SUMMARY = "Lightweight http(s) proxy daemon"
+HOMEPAGE = "https://tinyproxy.github.io/"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
+
+SRC_URI = "https://github.com/${BPN}/${BPN}/releases/download/${PV}/${BP}.tar.gz \
+		   file://disable-documentation.patch \
+		   file://tinyproxy.service"
+
+SRC_URI[md5sum] = "423047c8dc53a15e19f78e238198549c"
+SRC_URI[sha256sum] = "6020955e6a0ef0ef898ad5bb17a448c47f9e4c003c464b4ae7c4dba063272055"
+
+EXTRA_OECONF += " \
+	--enable-filter \
+	--enable-transparent \
+	--enable-reverse \
+	--enable-upstream \
+	--enable-xtinyproxy \
+	"
+
+inherit autotools systemd useradd
+
+#User specific
+USERADD_PACKAGES = "${PN}"
+USERADD_PARAM_${PN} = "--system --home /dev/null \
+                       --no-user-group --gid nogroup tinypoxy"
+
+SYSTEMD_PACKAGES += "${BPN}"
+SYSTEMD_SERVICE_${PN} = "tinyproxy.service"
+SYSTEMD_AUTO_ENABLE_${PN} = "enable"
+
+do_install_append() {
+	if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+		install -d ${D}${systemd_system_unitdir}
+		install -m 0644 ${WORKDIR}/tinyproxy.service ${D}${systemd_system_unitdir}
+	fi
+}
diff --git a/meta-openembedded/meta-networking/recipes-support/tinyproxy/tinyproxy_1.8.4.bb b/meta-openembedded/meta-networking/recipes-support/tinyproxy/tinyproxy_1.8.4.bb
deleted file mode 100644
index 98192dc..0000000
--- a/meta-openembedded/meta-networking/recipes-support/tinyproxy/tinyproxy_1.8.4.bb
+++ /dev/null
@@ -1,38 +0,0 @@
-SUMMARY = "Lightweight http(s) proxy daemon"
-HOMEPAGE = "https://tinyproxy.github.io/"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
-
-SRC_URI = "https://github.com/${BPN}/${BPN}/releases/download/${PV}/${BP}.tar.gz \
-		   file://disable-documentation.patch \
-		   file://tinyproxy.service"
-
-SRC_URI[md5sum] = "3b60f7d08e0821ed1a3e2cf1e5778cac"
-SRC_URI[sha256sum] = "8234c879a129feee61efa98bac14a1a3e46e5cf08f01696a216940872aa70faf"
-
-EXTRA_OECONF += " \
-	--enable-filter \
-	--enable-transparent \
-	--disable-regexcheck \
-	--enable-reverse \
-	--enable-upstream \
-	--enable-xtinyproxy \
-	"
-
-inherit autotools systemd useradd
-
-#User specific
-USERADD_PACKAGES = "${PN}"
-USERADD_PARAM_${PN} = "--system --home /dev/null \
-                       --no-user-group --gid nogroup tinypoxy"
-
-SYSTEMD_PACKAGES += "${BPN}"
-SYSTEMD_SERVICE_${PN} = "tinyproxy.service"
-SYSTEMD_AUTO_ENABLE_${PN} = "enable"
-
-do_install_append() {
-	if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-		install -d ${D}${systemd_system_unitdir}
-		install -m 0644 ${WORKDIR}/tinyproxy.service ${D}${systemd_system_unitdir}
-	fi
-}
diff --git a/meta-openembedded/meta-networking/recipes-support/uftp/uftp_4.9.3.bb b/meta-openembedded/meta-networking/recipes-support/uftp/uftp_4.9.3.bb
deleted file mode 100644
index 1166f9a..0000000
--- a/meta-openembedded/meta-networking/recipes-support/uftp/uftp_4.9.3.bb
+++ /dev/null
@@ -1,16 +0,0 @@
-DESCRIPTION = "Encrypted UDP based FTP with multicast"
-HOMEPAGE = "https://sourceforge.net/projects/uftp-multicast"
-SECTION = "libs/network"
-
-LICENSE = "GPLv3"
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=d32239bcb673463ab874e80d47fae504"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/uftp-multicast/source-tar/uftp-${PV}.tar.gz"
-SRC_URI[md5sum] = "231d6ba7820d89a712fe7d727ab0f8e6"
-SRC_URI[sha256sum] = "9e9215af0315257c6cc4f40fbc6161057e861be1fff10a38a5564f699e99c78f"
-
-DEPENDS = "openssl"
-
-do_install () {
-	oe_runmake install DESTDIR=${D}
-}
diff --git a/meta-openembedded/meta-networking/recipes-support/uftp/uftp_4.9.8.bb b/meta-openembedded/meta-networking/recipes-support/uftp/uftp_4.9.8.bb
new file mode 100644
index 0000000..0bbdd6b
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/uftp/uftp_4.9.8.bb
@@ -0,0 +1,16 @@
+DESCRIPTION = "Encrypted UDP based FTP with multicast"
+HOMEPAGE = "https://sourceforge.net/projects/uftp-multicast"
+SECTION = "libs/network"
+
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=d32239bcb673463ab874e80d47fae504"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/uftp-multicast/source-tar/uftp-${PV}.tar.gz"
+SRC_URI[md5sum] = "f7a5affd3000b5aafbb13df49719b6c0"
+SRC_URI[sha256sum] = "e98c6318e497124d777ca71eae752d213207c35de9f782c8bcaaf82ece20e599"
+
+DEPENDS = "openssl"
+
+do_install () {
+	oe_runmake install DESTDIR=${D}
+}
diff --git a/meta-openembedded/meta-networking/recipes-support/wireshark/files/libgcrypt.patch b/meta-openembedded/meta-networking/recipes-support/wireshark/files/libgcrypt.patch
deleted file mode 100644
index 2aa58f7..0000000
--- a/meta-openembedded/meta-networking/recipes-support/wireshark/files/libgcrypt.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-use OR PKG_CONFIG scheme for libgcrypt
-
-Upstream-Status: Inappropriate OE specific
-
-Signed-off-by: Armin Kuster <akuster808@gmail.com>
-
-Index: wireshark-2.4.4/m4/libgcrypt.m4
-===================================================================
---- wireshark-2.4.4.orig/m4/libgcrypt.m4
-+++ wireshark-2.4.4/m4/libgcrypt.m4
-@@ -27,11 +27,11 @@ AC_DEFUN([AM_PATH_LIBGCRYPT],
-      libgcrypt_config_prefix="$withval", libgcrypt_config_prefix="")
-   if test x$libgcrypt_config_prefix != x ; then
-      if test x${LIBGCRYPT_CONFIG+set} != xset ; then
--        LIBGCRYPT_CONFIG=$libgcrypt_config_prefix/bin/libgcrypt-config
-+        LIBGCRYPT_CONFIG=$libgcrypt_config_prefix/libgcrypt.pc
-      fi
-   fi
- 
--  AC_PATH_PROG(LIBGCRYPT_CONFIG, libgcrypt-config, no)
-+  AC_PATH_PROG(LIBGCRYPT_CONFIG, libgcrypt.pc, no)
-   tmp=ifelse([$1], ,1:1.2.0,$1)
-   if echo "$tmp" | grep ':' >/dev/null 2>/dev/null ; then
-      req_libgcrypt_api=`echo "$tmp"     | sed 's/\(.*\):\(.*\)/\1/'`
-@@ -50,7 +50,7 @@ AC_DEFUN([AM_PATH_LIBGCRYPT],
-                sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\2/'`
-     req_micro=`echo $min_libgcrypt_version | \
-                sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\3/'`
--    libgcrypt_config_version=`$LIBGCRYPT_CONFIG --version`
-+    libgcrypt_config_version=`$PKG_CONFIG --modversion libgcrypt`
-     major=`echo $libgcrypt_config_version | \
-                sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\1/'`
-     minor=`echo $libgcrypt_config_version | \
-@@ -82,7 +82,7 @@ AC_DEFUN([AM_PATH_LIBGCRYPT],
-      # If we have a recent libgcrypt, we should also check that the
-      # API is compatible
-      if test "$req_libgcrypt_api" -gt 0 ; then
--        tmp=`$LIBGCRYPT_CONFIG --api-version 2>/dev/null || echo 0`
-+        tmp=`$PKG_CONFIG --api-version libgcrypt 2>/dev/null || echo 0`
-         if test "$tmp" -gt 0 ; then
-            AC_MSG_CHECKING([LIBGCRYPT API version])
-            if test "$req_libgcrypt_api" -eq "$tmp" ; then
-@@ -95,8 +95,8 @@ AC_DEFUN([AM_PATH_LIBGCRYPT],
-      fi
-   fi
-   if test $ok = yes; then
--    LIBGCRYPT_CFLAGS=`$LIBGCRYPT_CONFIG --cflags`
--    LIBGCRYPT_LIBS=`$LIBGCRYPT_CONFIG --libs`
-+    LIBGCRYPT_CFLAGS=`$PKG_CONFIG --cflags libgcrypt`
-+    LIBGCRYPT_LIBS=`$PKG_CONFIG --libs libgcrypt`
-     ifelse([$2], , :, [$2])
-   else
-     LIBGCRYPT_CFLAGS=""
diff --git a/meta-openembedded/meta-networking/recipes-support/wireshark/wireshark/0001-Add-libm-to-link-for-fmod-API.patch b/meta-openembedded/meta-networking/recipes-support/wireshark/wireshark/0001-Add-libm-to-link-for-fmod-API.patch
new file mode 100644
index 0000000..e65ef9b
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/wireshark/wireshark/0001-Add-libm-to-link-for-fmod-API.patch
@@ -0,0 +1,29 @@
+From 1a6a5d2bcb1adec9ba138c2ebee7bbc994620aff Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 12 Jun 2018 23:23:44 -0700
+Subject: [PATCH] Add libm to link for fmod() API
+
+fixes
+ld: CMakeFiles/tshark.dir/ui/cli/tap-comparestat.c.o: undefined reference to symbol 'fmod@@GLIBC_2.2.5'
+| /mnt/a/oe/build/tmp/work/core2-64-bec-linux/wireshark/1_2.6.1-r0/recipe-sysroot/lib/libm.so.6: error adding symbols: DSO missing from command line
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ CMakeLists.txt | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 7950e85..acee140 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -2494,6 +2494,7 @@ if(BUILD_tshark)
+ 		${LIBEPAN_LIBS}
+ 		${APPLE_CORE_FOUNDATION_LIBRARY}
+ 		${APPLE_SYSTEM_CONFIGURATION_LIBRARY}
++		m
+ 	)
+ 	set(tshark_FILES
+ 		capture_opts.c
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-networking/recipes-support/wireshark/wireshark_2.4.8.bb b/meta-openembedded/meta-networking/recipes-support/wireshark/wireshark_2.4.8.bb
deleted file mode 100644
index 51a7aa8..0000000
--- a/meta-openembedded/meta-networking/recipes-support/wireshark/wireshark_2.4.8.bb
+++ /dev/null
@@ -1,73 +0,0 @@
-DESCRIPTION = "wireshark - a popular network protocol analyzer"
-HOMEPAGE = "http://www.wireshark.org"
-SECTION = "net"
-LICENSE = "GPL-2.0"
-LIC_FILES_CHKSUM = "file://COPYING;md5=6e271234ba1a13c6e512e76b94ac2f77"
-
-DEPENDS = "pcre expat glib-2.0 glib-2.0-native libgcrypt libgpg-error"
-
-SRC_URI = "https://1.as.dl.wireshark.org/src/all-versions/${BP}.tar.xz"
-SRC_URI += "file://libgcrypt.patch"
-
-UPSTREAM_CHECK_URI = "https://1.as.dl.wireshark.org/src"
-
-SRC_URI[md5sum] = "25f93aa6a2b3fdd9d1f01a49f84d224f"
-SRC_URI[sha256sum] = "db8ed7828c157e4ffb91fb8c41fa5a2f37fd44259175951a5c37848bf641f5e8"
-
-PE = "1"
-
-inherit autotools pkgconfig perlnative upstream-version-is-even
-
-ARM_INSTRUCTION_SET = "arm"
-
-PACKAGECONFIG ?= "libpcap gnutls libnl libcap sbc"
-PACKAGECONFIG += " ${@bb.utils.contains("DISTRO_FEATURES", "x11", "gtk2 graphics", "", d)}"
-
-PACKAGECONFIG[libcap] = "--with-libcap=${STAGING_DIR_HOST}/usr, --with-libcap=no --enable-pcap-ng-default , libcap"
-PACKAGECONFIG[libpcap] = "--with-pcap=${STAGING_DIR_HOST}/usr --with-pcap-remote, --with-pcap=no --enable-pcap-ng-default  , libpcap"
-PACKAGECONFIG[libsmi] = "--with-libsmi=yes, --with-libsmi=no, libsmi"
-PACKAGECONFIG[libnl] = "--with-libnl=yes, --with-libnl=no, libnl"
-PACKAGECONFIG[portaudio] = "--with-portaudio=yes, --with-portaudio=no, portaudio-v19"
-PACKAGECONFIG[gtk2] = "--with-gtk=2, , gtk+"
-PACKAGECONFIG[gtk3] = "--with-gtk=3, , gtk+3"
-PACKAGECONFIG[graphics] = "--enable-wireshark, --with-gtk=no --disable-wireshark,"
-PACKAGECONFIG[gnutls] = "--with-gnutls=yes, --with-gnutls=no, gnutls"
-PACKAGECONFIG[ssl] = "--with-ssl=yes, --with-ssl=no, openssl"
-PACKAGECONFIG[krb5] = "--with-krb5=yes, --with-krb5=no, krb5"
-PACKAGECONFIG[lua] = "--with-lua=yes, --with-lua=no, lua"
-PACKAGECONFIG[zlib] = "--with-zlib=yes, --with-zlib=no, zlib"
-PACKAGECONFIG[geoip] = "--with-geoip=yes, --with-geoip=no, geoip"
-PACKAGECONFIG[plugins] = "--with-plugins=yes, --with-plugins=no"
-PACKAGECONFIG[sbc] = "--with-sbc=yes, --with-sbc=no, sbc"
-PACKAGECONFIG[libssh] = "--with-libssh=${STAGING_DIR_HOST}/usr, --with-libssh=no, libssh2"
-PACKAGECONFIG[lz4] = "--with-lz4=${STAGING_DIR_HOST}/usr, --with-lz4=no, lz4"
-
-# these next two options require addional layers
-PACKAGECONFIG[c-ares] = "--with-c-ares=yes, --with-c-ares=no, c-ares"
-
-EXTRA_OECONF += "--with-libgcrypt-prefix=${PKG_CONFIG_DIR} --with-qt=no --enable-tshark --enable-rawshark"
-
-LDFLAGS_append = " -lgpg-error"
-
-# Currently wireshark does not install header files
-do_install_append () {
-
-	install -d ${D}/${includedir}/${BPN}
-	install -d ${D}/${includedir}/${BPN}/epan
-	install -d ${D}/${includedir}/${BPN}/epan/crypt
-	install -d ${D}/${includedir}/${BPN}/epan/dfilter
-	install -d ${D}/${includedir}/${BPN}/epan/dissectors
-	install -d ${D}/${includedir}/${BPN}/epan/ftypes
-	install -d ${D}/${includedir}/${BPN}/epan/wmem
-
-	install config.h ${D}/${includedir}/${BPN}
-	install ${S}/register.h ${D}/${includedir}/${BPN}
-	install -D ${S}/epan/*.h ${D}/${includedir}/${BPN}/epan
-	install -D ${S}/epan/crypt/*.h ${D}/${includedir}/${BPN}/epan/crypt
-	install -D ${S}/epan/dfilter/*.h ${D}/${includedir}/${BPN}/epan/dfilter
-	install -D ${S}/epan/dissectors/*.h ${D}/${includedir}/${BPN}/epan/dissectors
-	install -D ${S}/epan/ftypes/*.h ${D}/${includedir}/${BPN}/epan/ftypes
-	install -D ${S}/epan/wmem/*.h ${D}/${includedir}/${BPN}/epan/wmem
-}
-
-FILES_${PN} += "${datadir}*"
diff --git a/meta-openembedded/meta-networking/recipes-support/wireshark/wireshark_2.6.4.bb b/meta-openembedded/meta-networking/recipes-support/wireshark/wireshark_2.6.4.bb
new file mode 100644
index 0000000..595502e
--- /dev/null
+++ b/meta-openembedded/meta-networking/recipes-support/wireshark/wireshark_2.6.4.bb
@@ -0,0 +1,94 @@
+DESCRIPTION = "wireshark - a popular network protocol analyzer"
+HOMEPAGE = "http://www.wireshark.org"
+SECTION = "net"
+LICENSE = "GPL-2.0"
+LIC_FILES_CHKSUM = "file://COPYING;md5=6e271234ba1a13c6e512e76b94ac2f77"
+
+DEPENDS = "pcre expat glib-2.0 glib-2.0-native libgcrypt libgpg-error libxml2 bison-native"
+
+DEPENDS_append_class-target = " wireshark-native chrpath-replacement-native "
+
+SRC_URI = "https://1.as.dl.wireshark.org/src/all-versions/${BP}.tar.xz \
+           file://0001-Add-libm-to-link-for-fmod-API.patch \
+          "
+
+UPSTREAM_CHECK_URI = "https://1.as.dl.wireshark.org/src"
+
+SRC_URI[md5sum] = "8aa7b8c8ce0b6ce4256a081493819d6f"
+SRC_URI[sha256sum] = "a06b007e6343f148b8b93443b2fcfc9bb3204311cd268565d54d1b71660bc861"
+
+PE = "1"
+
+inherit cmake pkgconfig pythonnative perlnative upstream-version-is-even
+
+ARM_INSTRUCTION_SET = "arm"
+
+# Options: gtk+, gtk+3 and qt5
+GTK = "gtk+3"
+
+PACKAGECONFIG ?= "libpcap gnutls libnl libcap sbc"
+PACKAGECONFIG_append_class-target = " ${@bb.utils.contains("DISTRO_FEATURES", "x11", " ${GTK}", "", d)}"
+
+PACKAGECONFIG_class-native = "libpcap gnutls ssl libssh"
+
+PACKAGECONFIG[libcap] = "-DENABLE_CAP=ON,-DENABLE_CAP=OFF -DENABLE_PCAP_NG_DEFAULT=ON, libcap"
+PACKAGECONFIG[libpcap] = "-DENABLE_PCAP=ON,-DENABLE_PCAP=OFF -DENABLE_PCAP_NG_DEFAULT=ON , libpcap"
+PACKAGECONFIG[libsmi] = "-DENABLE_SMI=ON,-DENABLE_SMI=OFF,libsmi"
+PACKAGECONFIG[libnl] = ",,libnl"
+PACKAGECONFIG[portaudio] = "-DENABLE_PORTAUDIO=ON,-DENABLE_PORTAUDIO=OFF, portaudio-v19"
+PACKAGECONFIG[gtk+] = "-DENABLE_GTK=ON -DBUILD_wireshark_gtk=ON, -DENABLE_GTK=OFF, gtk+"
+PACKAGECONFIG[gtk+3] = "-DENABLE_GTK3=ON -DBUILD_wireshark_gtk=ON, -DENABLE_GTK3=OFF, gtk+3"
+PACKAGECONFIG[gnutls] = "-DENABLE_GNUTLS=ON,-DENABLE_GNUTLS=OFF, gnutls"
+PACKAGECONFIG[ssl] = ",,openssl"
+PACKAGECONFIG[krb5] = "-DENABLE_KRB5=ON,-DENABLE_KRB5=OFF, krb5"
+PACKAGECONFIG[lua] = "-DENABLE_LUA=ON,-DENABLE_LUA=OFF, lua"
+PACKAGECONFIG[zlib] = "-DENABLE_ZLIB=ON,-DENABLE_ZLIB=OFF, zlib"
+PACKAGECONFIG[geoip] = ",, geoip"
+PACKAGECONFIG[plugins] = "-DENABLE_PLUGINS=ON,-DENABLE_PLUGINS=OFF"
+PACKAGECONFIG[sbc] = "-DENABLE_SBC=ON,-DENABLE_SBC=OFF, sbc"
+PACKAGECONFIG[libssh] = ",,libssh2"
+PACKAGECONFIG[lz4] = "-DENABLE_LZ4=ON,-DENABLE_LZ4=OFF, lz4"
+
+# these next two options require addional layers
+PACKAGECONFIG[c-ares] = "-DENABLE_CARES=ON,-DENABLE_CARES=OFF, c-ares"
+PACKAGECONFIG[qt5] = "-DENABLE_QT5=ON -DBUILD_wireshark=ON, -DENABLE_QT5=OFF -DBUILD_wireshark=OFF, qtbase"
+
+EXTRA_OECMAKE += "-DENABLE_NETLINK=ON \
+                  -DBUILD_mmdbresolve=OFF \
+                  -DBUILD_randpktdump=OFF \
+                  -DBUILD_androiddump=OFF \
+                  -DBUILD_dcerpcidl2wrs=OFF \
+                  -DM_INCLUDE_DIR=${includedir} \
+                  -DM_LIBRARY=${libdir} \
+                 "
+CFLAGS_append = " -lm"
+
+do_install_append_class-native() {
+	install -d ${D}${bindir}
+	for f in lemon
+	do
+		install -m 0755 ${B}/run/$f ${D}${bindir}
+	done
+}
+
+do_install_append_class-target() {
+	for f in `find ${D}${libdir} ${D}${bindir} -type f -executable`
+	do
+		chrpath --delete $f
+	done
+}
+
+PACKAGE_BEFORE_PN += "tshark"
+PACKAGE_BEFORE_PN += "${PN}-gtk"
+
+FILES_tshark = "${bindir}/tshark ${mandir}/man1/tshark.*"
+FILES_${PN}-gtk = "${bindir}/wireshark-gtk ${datadir}/icons ${datadir}/appdata \
+                   ${datadir}/applications ${datadir}/wireshark ${datadir}/mime \
+                   ${mandir}/man1/wireshark.* "
+
+FILES_${PN} += "${datadir}*"
+
+RDEPENDS_tshark = "wireshark"
+RDEPENDS_${PN}-gtk = "${@bb.utils.contains("DISTRO_FEATURES", "x11", "${GTK}", "", d)} wireshark"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/README b/meta-openembedded/meta-oe/README
index 7cde0a2..de351f2 100644
--- a/meta-openembedded/meta-oe/README
+++ b/meta-openembedded/meta-oe/README
@@ -1,14 +1,22 @@
+meta-oe
+=======
+
 This layer depends on:
 
-URI: git://github.com/openembedded/oe-core.git
-branch: master
+URI: git://github.com/openembedded/openembedded-core.git
+branch: thud 
 revision: HEAD
 
-Send pull requests to openembedded-devel@lists.openembedded.org with '[meta-oe]' in the subject'
+Send pull requests to openembedded-devel@lists.openembedded.org with '[meta-oe][thud]' in the subject'
 
 When sending single patches, please use something like:
-'git send-email -M -1 --to openembedded-devel@lists.openembedded.org --subject-prefix=meta-oe][PATCH'
+'git send-email -M -1 --to openembedded-devel@lists.openembedded.org --subject-prefix=meta-oe[thud][PATCH'
 
-You are encouraged to fork the mirror on github https://github.com/openembedded/meta-oe/ to share your patches, this is preferred for patch sets consisting of more than one patch. Other services like gitorious, repo.or.cz or self hosted setups are of course accepted as well, 'git fetch <remote>' works the same on all of them. We recommend github because it is free, easy to use, has been proven to be reliable and has a really good web GUI.
+You are encouraged to fork the mirror on GitHub https://github.com/openembedded/openembedded-core
+to share your patches, this is preferred for patch sets consisting of more than one patch.
 
-Main layer maintainer: Armin Kuster <akuster808@gmail.com>
+Other services like gitorious, repo.or.cz or self-hosted setups are of course accepted as well,
+'git fetch <remote>' works the same on all of them. We recommend GitHub because it is free, easy
+to use, has been proven to be reliable and has a really good web GUI.
+
+Thud maintainer: Armin Kuster <akuster808@gmail.com>
diff --git a/meta-openembedded/meta-oe/classes/dos2unix.bbclass b/meta-openembedded/meta-oe/classes/dos2unix.bbclass
deleted file mode 100644
index 1bad998..0000000
--- a/meta-openembedded/meta-oe/classes/dos2unix.bbclass
+++ /dev/null
@@ -1,14 +0,0 @@
-# Class for use to convert all CRLF line terminators to LF
-# provided that some projects are being developed/maintained
-# on Windows so they have different line terminators(CRLF) vs
-# on Linux(LF), which can cause annoying patching errors during
-# git push/checkout processes.
-
-do_convert_crlf_to_lf[depends] += "dos2unix-native:do_populate_sysroot"
-
-# Convert CRLF line terminators to LF
-do_convert_crlf_to_lf () {
-    find ${S} -type f -exec dos2unix {} \;
-}
-
-addtask convert_crlf_to_lf after do_unpack before do_patch
diff --git a/meta-openembedded/meta-oe/classes/scancode.bbclass b/meta-openembedded/meta-oe/classes/scancode.bbclass
new file mode 100644
index 0000000..701660f
--- /dev/null
+++ b/meta-openembedded/meta-oe/classes/scancode.bbclass
@@ -0,0 +1,35 @@
+# We use scancode utlity for extacting licence information.
+# scancode itself is an OSS Utlitity.
+# For more informaiton https://github.com/nexB/scancode-toolkit
+
+SCANCODE_FORMAT ?= "html-app"
+EXT = "${@'html' if d.getVar('SCANCODE_FORMAT', True) == 'html-app' else 'json'}"
+SCANCODE_TOOLKIT = "${@get_scancode_toolkit(d)}"
+SCANCODE_TAG = "v2.2.1"
+SCANCODE_GIT_LOCATION ?= "https://github.com/nexB/scancode-toolkit.git"
+SCANCODE_SRC_LOCATION ?= "${DL_DIR}/scancode"
+
+def get_scancode_toolkit(d):
+    lf = bb.utils.lockfile(d.getVar('SCANCODE_SRC_LOCATION', True) + ".lock")
+    if (not os.path.exists(d.getVar('SCANCODE_SRC_LOCATION', True))):
+        os.system("git clone %s %s -b %s" % (d.getVar('SCANCODE_GIT_LOCATION', True), d.getVar('SCANCODE_SRC_LOCATION', True), d.getVar('SCANCODE_TAG', True)))
+    bb.utils.unlockfile(lf)
+    return (d.getVar('SCANCODE_SRC_LOCATION', True))
+
+do_scancode() {
+	mkdir -p ${DEPLOY_DIR_IMAGE}/scancode
+	cd ${SCANCODE_TOOLKIT}
+	if [ -d "${S}" ]; then
+		./scancode ${S} --format  ${SCANCODE_FORMAT} ${DEPLOY_DIR_IMAGE}/scancode/${PN}.${EXT}
+	fi
+}
+
+addtask scancode after do_patch
+
+do_scancode_oss() {
+    echo "We are done running scancode"
+}
+
+do_scancode_oss[recrdeptask] = "do_scancode_oss do_scancode"
+do_scancode_oss[nostamp] = "1"
+addtask do_scancode_oss after do_scancode
diff --git a/meta-openembedded/meta-oe/conf/layer.conf b/meta-openembedded/meta-oe/conf/layer.conf
index 1a43575..23c10ce 100644
--- a/meta-openembedded/meta-oe/conf/layer.conf
+++ b/meta-openembedded/meta-oe/conf/layer.conf
@@ -29,7 +29,7 @@
 
 LAYERDEPENDS_openembedded-layer = "core"
 
-LAYERSERIES_COMPAT_openembedded-layer = "sumo"
+LAYERSERIES_COMPAT_openembedded-layer = "thud"
 
 LICENSE_PATH += "${LAYERDIR}/licenses"
 
@@ -77,3 +77,5 @@
   source-han-sans-kr-fonts->fontconfig \
   source-han-sans-tw-fonts->fontconfig \
 "
+
+DEFAULT_TEST_SUITES_pn-meta-oe-ptest-image = " ${PTESTTESTSUITE}"
diff --git a/meta-openembedded/meta-oe/lib/oeqa/selftest/cases/meta_oe_sources.py b/meta-openembedded/meta-oe/lib/oeqa/selftest/cases/meta_oe_sources.py
new file mode 100644
index 0000000..b17c795
--- /dev/null
+++ b/meta-openembedded/meta-oe/lib/oeqa/selftest/cases/meta_oe_sources.py
@@ -0,0 +1,30 @@
+import os
+import re
+import glob as g
+import shutil
+import tempfile
+from oeqa.selftest.case import OESelftestTestCase
+from oeqa.utils.commands import runCmd, bitbake, get_bb_var, get_bb_vars
+
+class MetaOESourceMirroring(OESelftestTestCase):
+    # Can we download everything from the OpenEmbedded Sources Mirror over http only
+    def test_oe_source_mirror(self):
+        self.write_config("""
+BB_ALLOWED_NETWORKS = " sources.openembedded.org"
+MIRRORS = ""
+DL_DIR = "${TMPDIR}/test_oe_downloads"
+PREMIRRORS = "\\
+    bzr://.*/.*   http://sources.openembedded.org/ \\n \\
+    cvs://.*/.*   http://sources.openembedded.org/ \\n \\
+    git://.*/.*   http://sources.openembedded.org/ \\n \\
+    gitsm://.*/.* http://sources.openembedded.org/ \\n \\
+    hg://.*/.*    http://sources.openembedded.org/ \\n \\
+    osc://.*/.*   http://sources.openembedded.org/ \\n \\
+    p4://.*/.*    http://sources.openembedded.org/ \\n \\
+    svn://.*/.*   http://sources.openembedded.org/ \\n \\
+    ftp://.*/.*      http://sources.openembedded.org/ \\n \\
+    http://.*/.*     http://sources.openembedded.org/ \\n \\
+    https://.*/.*    http://sources.openembedded.org/ \\n"
+    """)
+
+        bitbake("world --runall fetch")
diff --git a/meta-openembedded/meta-oe/licenses/Khronos b/meta-openembedded/meta-oe/licenses/Khronos
new file mode 100644
index 0000000..7afedf6
--- /dev/null
+++ b/meta-openembedded/meta-oe/licenses/Khronos
@@ -0,0 +1,35 @@
+Copyright (c) 2016 The Khronos Group Inc.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software source and associated documentation files (the "Materials"),
+to deal in the Materials without restriction, including without limitation
+the rights to use, copy, modify, compile, merge, publish, distribute,
+sublicense, and/or sell copies of the Materials, and to permit persons to
+whom the Materials are furnished to do so, subject the following terms and
+conditions:
+
+All modifications to the Materials used to create a binary that is
+distributed to third parties shall be provided to Khronos with an
+unrestricted license to use for the purposes of implementing bug fixes and
+enhancements to the Materials;
+
+If the binary is used as part of an OpenCL(TM) implementation, whether binary
+is distributed together with or separately to that implementation, then
+recipient must become an OpenCL Adopter and follow the published OpenCL
+conformance process for that implementation, details at:
+http://www.khronos.org/conformance/;
+
+The above copyright notice, the OpenCL trademark license, and this permission
+notice shall be included in all copies or substantial portions of the
+Materials.
+
+THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE MATERIALS OR THE USE OR OTHER DEALINGS IN
+THE MATERIALS.
+
+OpenCL is a trademark of Apple Inc. used under license by Khronos.
+
diff --git a/meta-openembedded/meta-oe/licenses/Mini-XML-License b/meta-openembedded/meta-oe/licenses/Mini-XML-License
new file mode 100644
index 0000000..4d0aa78
--- /dev/null
+++ b/meta-openembedded/meta-oe/licenses/Mini-XML-License
@@ -0,0 +1,507 @@
+			   Mini-XML License
+			  September 18, 2010
+
+
+The Mini-XML library and included programs are provided under the
+terms of the GNU Library General Public License version 2 (LGPL2)
+with the following exceptions:
+
+  1. Static linking of applications to the Mini-XML library
+does not constitute a derivative work and does not require
+the author to provide source code for the application, use
+the shared Mini-XML libraries, or link their applications
+against a user-supplied version of Mini-XML.
+
+If you link the application to a modified version of
+Mini-XML, then the changes to Mini-XML must be provided
+under the terms of the LGPL2 in sections 1, 2, and 4.
+
+  2. You do not have to provide a copy of the Mini-XML license
+with programs that are linked to the Mini-XML library, nor
+do you have to identify the Mini-XML license in your
+program or documentation as required by section 6 of the
+LGPL2.
+
+
+		  GNU LIBRARY GENERAL PUBLIC LICENSE
+			 Version 2, June 1991
+
+	  Copyright (C) 1991 Free Software Foundation, Inc.
+       59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+
+     Everyone is permitted to copy and distribute verbatim copies
+      of this license document, but changing it is not allowed.
+
+    [This is the first released version of the library GPL.  It is
+   numbered 2 because it goes with version 2 of the ordinary GPL.]
+
+			       Preamble
+
+  The licenses for most software are designed to take away your
+freedom to share and change it.  By contrast, the GNU General Public
+Licenses are intended to guarantee your freedom to share and change
+free software--to make sure the software is free for all its users.
+
+  This license, the Library General Public License, applies to some
+specially designated Free Software Foundation software, and to any
+other libraries whose authors decide to use it.  You can use it for
+your libraries, too.
+
+  When we speak of free software, we are referring to freedom, not
+price.  Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+  To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if
+you distribute copies of the library, or if you modify it.
+
+  For example, if you distribute copies of the library, whether gratis
+or for a fee, you must give the recipients all the rights that we gave
+you.  You must make sure that they, too, receive or can get the source
+code.  If you link a program with the library, you must provide
+complete object files to the recipients so that they can relink them
+with the library, after making changes to the library and recompiling
+it.  And you must show them these terms so they know their rights.
+
+  Our method of protecting your rights has two steps: (1) copyright
+the library, and (2) offer you this license which gives you legal
+permission to copy, distribute and/or modify the library.
+
+  Also, for each distributor's protection, we want to make certain
+that everyone understands that there is no warranty for this free
+library.  If the library is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original
+version, so that any problems introduced by others will not reflect on
+the original authors' reputations.
+
+  Finally, any free program is threatened constantly by software
+patents.  We wish to avoid the danger that companies distributing free
+software will individually obtain patent licenses, thus in effect
+transforming the program into proprietary software.  To prevent this,
+we have made it clear that any patent must be licensed for everyone's
+free use or not licensed at all.
+
+  Most GNU software, including some libraries, is covered by the ordinary
+GNU General Public License, which was designed for utility programs.  This
+license, the GNU Library General Public License, applies to certain
+designated libraries.  This license is quite different from the ordinary
+one; be sure to read it in full, and don't assume that anything in it is
+the same as in the ordinary license.
+
+  The reason we have a separate public license for some libraries is that
+they blur the distinction we usually make between modifying or adding to a
+program and simply using it.  Linking a program with a library, without
+changing the library, is in some sense simply using the library, and is
+analogous to running a utility program or application program.  However, in
+a textual and legal sense, the linked executable is a combined work, a
+derivative of the original library, and the ordinary General Public License
+treats it as such.
+
+  Because of this blurred distinction, using the ordinary General
+Public License for libraries did not effectively promote software
+sharing, because most developers did not use the libraries.  We
+concluded that weaker conditions might promote sharing better.
+
+  However, unrestricted linking of non-free programs would deprive the
+users of those programs of all benefit from the free status of the
+libraries themselves.  This Library General Public License is intended to
+permit developers of non-free programs to use free libraries, while
+preserving your freedom as a user of such programs to change the free
+libraries that are incorporated in them.  (We have not seen how to achieve
+this as regards changes in header files, but we have achieved it as regards
+changes in the actual functions of the Library.)  The hope is that this
+will lead to faster development of free libraries.
+
+  The precise terms and conditions for copying, distribution and
+modification follow.  Pay close attention to the difference between a
+"work based on the library" and a "work that uses the library".  The
+former contains code derived from the library, while the latter only
+works together with the library.
+
+  Note that it is possible for a library to be covered by the ordinary
+General Public License rather than by this special one.
+
+		  GNU LIBRARY GENERAL PUBLIC LICENSE
+   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+  0. This License Agreement applies to any software library which
+contains a notice placed by the copyright holder or other authorized
+party saying it may be distributed under the terms of this Library
+General Public License (also called "this License").  Each licensee is
+addressed as "you".
+
+  A "library" means a collection of software functions and/or data
+prepared so as to be conveniently linked with application programs
+(which use some of those functions and data) to form executables.
+
+  The "Library", below, refers to any such software library or work
+which has been distributed under these terms.  A "work based on the
+Library" means either the Library or any derivative work under
+copyright law: that is to say, a work containing the Library or a
+portion of it, either verbatim or with modifications and/or translated
+straightforwardly into another language.  (Hereinafter, translation is
+included without limitation in the term "modification".)
+
+  "Source code" for a work means the preferred form of the work for
+making modifications to it.  For a library, complete source code means
+all the source code for all modules it contains, plus any associated
+interface definition files, plus the scripts used to control compilation
+and installation of the library.
+
+  Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope.  The act of
+running a program using the Library is not restricted, and output from
+such a program is covered only if its contents constitute a work based
+on the Library (independent of the use of the Library in a tool for
+writing it).  Whether that is true depends on what the Library does
+and what the program that uses the Library does.
+
+  1. You may copy and distribute verbatim copies of the Library's
+complete source code as you receive it, in any medium, provided that
+you conspicuously and appropriately publish on each copy an
+appropriate copyright notice and disclaimer of warranty; keep intact
+all the notices that refer to this License and to the absence of any
+warranty; and distribute a copy of this License along with the
+Library.
+
+  You may charge a fee for the physical act of transferring a copy,
+and you may at your option offer warranty protection in exchange for a
+fee.
+
+  2. You may modify your copy or copies of the Library or any portion
+of it, thus forming a work based on the Library, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+    a) The modified work must itself be a software library.
+
+    b) You must cause the files modified to carry prominent notices
+    stating that you changed the files and the date of any change.
+
+    c) You must cause the whole of the work to be licensed at no
+    charge to all third parties under the terms of this License.
+
+    d) If a facility in the modified Library refers to a function or a
+    table of data to be supplied by an application program that uses
+    the facility, other than as an argument passed when the facility
+    is invoked, then you must make a good faith effort to ensure that,
+    in the event an application does not supply such function or
+    table, the facility still operates, and performs whatever part of
+    its purpose remains meaningful.
+
+    (For example, a function in a library to compute square roots has
+    a purpose that is entirely well-defined independent of the
+    application.  Therefore, Subsection 2d requires that any
+    application-supplied function or table used by this function must
+    be optional: if the application does not supply it, the square
+    root function must still compute square roots.)
+
+These requirements apply to the modified work as a whole.  If
+identifiable sections of that work are not derived from the Library,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works.  But when you
+distribute the same sections as part of a whole which is a work based
+on the Library, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote
+it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Library.
+
+In addition, mere aggregation of another work not based on the Library
+with the Library (or with a work based on the Library) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+  3. You may opt to apply the terms of the ordinary GNU General Public
+License instead of this License to a given copy of the Library.  To do
+this, you must alter all the notices that refer to this License, so
+that they refer to the ordinary GNU General Public License, version 2,
+instead of to this License.  (If a newer version than version 2 of the
+ordinary GNU General Public License has appeared, then you can specify
+that version instead if you wish.)  Do not make any other change in
+these notices.
+
+  Once this change is made in a given copy, it is irreversible for
+that copy, so the ordinary GNU General Public License applies to all
+subsequent copies and derivative works made from that copy.
+
+  This option is useful when you wish to copy part of the code of
+the Library into a program that is not a library.
+
+  4. You may copy and distribute the Library (or a portion or
+derivative of it, under Section 2) in object code or executable form
+under the terms of Sections 1 and 2 above provided that you accompany
+it with the complete corresponding machine-readable source code, which
+must be distributed under the terms of Sections 1 and 2 above on a
+medium customarily used for software interchange.
+
+  If distribution of object code is made by offering access to copy
+from a designated place, then offering equivalent access to copy the
+source code from the same place satisfies the requirement to
+distribute the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+  5. A program that contains no derivative of any portion of the
+Library, but is designed to work with the Library by being compiled or
+linked with it, is called a "work that uses the Library".  Such a
+work, in isolation, is not a derivative work of the Library, and
+therefore falls outside the scope of this License.
+
+  However, linking a "work that uses the Library" with the Library
+creates an executable that is a derivative of the Library (because it
+contains portions of the Library), rather than a "work that uses the
+library".  The executable is therefore covered by this License.
+Section 6 states terms for distribution of such executables.
+
+  When a "work that uses the Library" uses material from a header file
+that is part of the Library, the object code for the work may be a
+derivative work of the Library even though the source code is not.
+Whether this is true is especially significant if the work can be
+linked without the Library, or if the work is itself a library.  The
+threshold for this to be true is not precisely defined by law.
+
+  If such an object file uses only numerical parameters, data
+structure layouts and accessors, and small macros and small inline
+functions (ten lines or less in length), then the use of the object
+file is unrestricted, regardless of whether it is legally a derivative
+work.  (Executables containing this object code plus portions of the
+Library will still fall under Section 6.)
+
+  Otherwise, if the work is a derivative of the Library, you may
+distribute the object code for the work under the terms of Section 6.
+Any executables containing that work also fall under Section 6,
+whether or not they are linked directly with the Library itself.
+
+  6. As an exception to the Sections above, you may also compile or
+link a "work that uses the Library" with the Library to produce a
+work containing portions of the Library, and distribute that work
+under terms of your choice, provided that the terms permit
+modification of the work for the customer's own use and reverse
+engineering for debugging such modifications.
+
+  You must give prominent notice with each copy of the work that the
+Library is used in it and that the Library and its use are covered by
+this License.  You must supply a copy of this License.  If the work
+during execution displays copyright notices, you must include the
+copyright notice for the Library among them, as well as a reference
+directing the user to the copy of this License.  Also, you must do one
+of these things:
+
+    a) Accompany the work with the complete corresponding
+    machine-readable source code for the Library including whatever
+    changes were used in the work (which must be distributed under
+    Sections 1 and 2 above); and, if the work is an executable linked
+    with the Library, with the complete machine-readable "work that
+    uses the Library", as object code and/or source code, so that the
+    user can modify the Library and then relink to produce a modified
+    executable containing the modified Library.  (It is understood
+    that the user who changes the contents of definitions files in the
+    Library will not necessarily be able to recompile the application
+    to use the modified definitions.)
+
+    b) Accompany the work with a written offer, valid for at
+    least three years, to give the same user the materials
+    specified in Subsection 6a, above, for a charge no more
+    than the cost of performing this distribution.
+
+    c) If distribution of the work is made by offering access to copy
+    from a designated place, offer equivalent access to copy the above
+    specified materials from the same place.
+
+    d) Verify that the user has already received a copy of these
+    materials or that you have already sent this user a copy.
+
+  For an executable, the required form of the "work that uses the
+Library" must include any data and utility programs needed for
+reproducing the executable from it.  However, as a special exception,
+the source code distributed need not include anything that is normally
+distributed (in either source or binary form) with the major
+components (compiler, kernel, and so on) of the operating system on
+which the executable runs, unless that component itself accompanies
+the executable.
+
+  It may happen that this requirement contradicts the license
+restrictions of other proprietary libraries that do not normally
+accompany the operating system.  Such a contradiction means you cannot
+use both them and the Library together in an executable that you
+distribute.
+
+  7. You may place library facilities that are a work based on the
+Library side-by-side in a single library together with other library
+facilities not covered by this License, and distribute such a combined
+library, provided that the separate distribution of the work based on
+the Library and of the other library facilities is otherwise
+permitted, and provided that you do these two things:
+
+    a) Accompany the combined library with a copy of the same work
+    based on the Library, uncombined with any other library
+    facilities.  This must be distributed under the terms of the
+    Sections above.
+
+    b) Give prominent notice with the combined library of the fact
+    that part of it is a work based on the Library, and explaining
+    where to find the accompanying uncombined form of the same work.
+
+  8. You may not copy, modify, sublicense, link with, or distribute
+the Library except as expressly provided under this License.  Any
+attempt otherwise to copy, modify, sublicense, link with, or
+distribute the Library is void, and will automatically terminate your
+rights under this License.  However, parties who have received copies,
+or rights, from you under this License will not have their licenses
+terminated so long as such parties remain in full compliance.
+
+  9. You are not required to accept this License, since you have not
+signed it.  However, nothing else grants you permission to modify or
+distribute the Library or its derivative works.  These actions are
+prohibited by law if you do not accept this License.  Therefore, by
+modifying or distributing the Library (or any work based on the
+Library), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Library or works based on it.
+
+  10. Each time you redistribute the Library (or any work based on the
+Library), the recipient automatically receives a license from the
+original licensor to copy, distribute, link with or modify the Library
+subject to these terms and conditions.  You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+  11. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License.  If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Library at all.  For example, if a patent
+license would not permit royalty-free redistribution of the Library by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Library.
+
+If any portion of this section is held invalid or unenforceable under any
+particular circumstance, the balance of the section is intended to apply,
+and the section as a whole is intended to apply in other circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system which is
+implemented by public license practices.  Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+  12. If the distribution and/or use of the Library is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Library under this License may add
+an explicit geographical distribution limitation excluding those countries,
+so that distribution is permitted only in or among countries not thus
+excluded.  In such case, this License incorporates the limitation as if
+written in the body of this License.
+
+  13. The Free Software Foundation may publish revised and/or new
+versions of the Library General Public License from time to time.
+Such new versions will be similar in spirit to the present version,
+but may differ in detail to address new problems or concerns.
+
+Each version is given a distinguishing version number.  If the Library
+specifies a version number of this License which applies to it and
+"any later version", you have the option of following the terms and
+conditions either of that version or of any later version published by
+the Free Software Foundation.  If the Library does not specify a
+license version number, you may choose any version ever published by
+the Free Software Foundation.
+
+  14. If you wish to incorporate parts of the Library into other free
+programs whose distribution conditions are incompatible with these,
+write to the author to ask for permission.  For software which is
+copyrighted by the Free Software Foundation, write to the Free
+Software Foundation; we sometimes make exceptions for this.  Our
+decision will be guided by the two goals of preserving the free status
+of all derivatives of our free software and of promoting the sharing
+and reuse of software generally.
+
+			    NO WARRANTY
+
+  15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
+WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
+EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
+OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
+KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE.  THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
+LIBRARY IS WITH YOU.  SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
+THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
+
+  16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
+WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
+AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
+FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
+CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
+LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
+RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
+FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
+SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
+DAMAGES.
+
+		     END OF TERMS AND CONDITIONS
+
+     Appendix: How to Apply These Terms to Your New Libraries
+
+  If you develop a new library, and you want it to be of the greatest
+possible use to the public, we recommend making it free software that
+everyone can redistribute and change.  You can do so by permitting
+redistribution under these terms (or, alternatively, under the terms of the
+ordinary General Public License).
+
+  To apply these terms, attach the following notices to the library.  It is
+safest to attach them to the start of each source file to most effectively
+convey the exclusion of warranty; and each file should have at least the
+"copyright" line and a pointer to where the full notice is found.
+
+    <one line to give the library's name and a brief idea of what it does.>
+    Copyright (C) <year>  <name of author>
+
+    This library is free software; you can redistribute it and/or
+    modify it under the terms of the GNU Library General Public
+    License as published by the Free Software Foundation; either
+    version 2 of the License, or (at your option) any later version.
+
+    This library is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+    Library General Public License for more details.
+
+    You should have received a copy of the GNU Library General Public
+    License along with this library; if not, write to the Free
+    Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+
+Also add information on how to contact you by electronic and paper mail.
+
+You should also get your employer (if you work as a programmer) or your
+school, if any, to sign a "copyright disclaimer" for the library, if
+necessary.  Here is a sample; alter the names:
+
+  Yoyodyne, Inc., hereby disclaims all copyright interest in the
+  library `Frob' (a library for tweaking knobs) written by James Random Hacker.
+
+  <signature of Ty Coon>, 1 April 1990
+  Ty Coon, President of Vice
+
+That's all there is to it!
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/bonnie/bonnie++_1.03e.bb b/meta-openembedded/meta-oe/recipes-benchmark/bonnie/bonnie++_1.03e.bb
deleted file mode 100644
index 2c1217e..0000000
--- a/meta-openembedded/meta-oe/recipes-benchmark/bonnie/bonnie++_1.03e.bb
+++ /dev/null
@@ -1,32 +0,0 @@
-SUMMARY = "Tests large file IO and creation/deletion of small files"
-HOMEPAGE = "http://www.coker.com.au/bonnie++/"
-SECTION = "benchmark/tests"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://copyright.txt;md5=cd4dde95a6b9d122f0a9150ae9cc3ee0"
-
-SRC_URI = "http://www.coker.com.au/bonnie++/${BPN}-${PV}.tgz \
-           file://gcc-4.3-fixes.patch \
-"
-SRC_URI[md5sum] = "750aa5b5051263a99c6c195888c74968"
-SRC_URI[sha256sum] = "cb3866116634bf65760b6806be4afa7e24a1cad6f145c876df8721f01ba2e2cb"
-
-inherit autotools-brokensep
-
-SCRIPTS = "bon_csv2html bon_csv2txt"
-EXES = "bonnie++ zcav"
-
-TARGET_CC_ARCH += "${LDFLAGS}"
-
-do_install () {
-    install -d ${D}/${bindir}
-    install -d ${D}/${sbindir}
-    install -m 0755 ${EXES} ${D}/${sbindir}
-    install -m 0755 ${SCRIPTS} ${D}/${bindir}
-}
-
-PACKAGES =+ "bonnie-scripts"
-
-FILES_${PN} = "${sbindir}"
-FILES_bonnie-scripts = "${bindir}"
-
-RDEPENDS_bonnie-scripts += "perl"
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/bonnie/bonnie++_1.04.bb b/meta-openembedded/meta-oe/recipes-benchmark/bonnie/bonnie++_1.04.bb
new file mode 100644
index 0000000..d7583f0
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-benchmark/bonnie/bonnie++_1.04.bb
@@ -0,0 +1,31 @@
+SUMMARY = "Tests large file IO and creation/deletion of small files"
+HOMEPAGE = "http://www.coker.com.au/bonnie++/"
+SECTION = "benchmark/tests"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://copyright.txt;md5=cd4dde95a6b9d122f0a9150ae9cc3ee0"
+
+SRC_URI = "http://www.coker.com.au/bonnie++/${BPN}_${PV}.tgz \
+"
+SRC_URI[md5sum] = "1414aab86e2db1b4691bd4be82031012"
+SRC_URI[sha256sum] = "507bd2ce5360c7c98b91b0fdc2bed5c9320b5c9699f7d4a3d1c86b256896c15e"
+
+inherit autotools-brokensep
+
+SCRIPTS = "bon_csv2html bon_csv2txt"
+EXES = "bonnie++ zcav"
+
+TARGET_CC_ARCH += "${LDFLAGS}"
+
+do_install () {
+    install -d ${D}/${bindir}
+    install -d ${D}/${sbindir}
+    install -m 0755 ${EXES} ${D}/${sbindir}
+    install -m 0755 ${SCRIPTS} ${D}/${bindir}
+}
+
+PACKAGES =+ "bonnie-scripts"
+
+FILES_${PN} = "${sbindir}"
+FILES_bonnie-scripts = "${bindir}"
+
+RDEPENDS_bonnie-scripts += "perl"
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/bonnie/files/gcc-4.3-fixes.patch b/meta-openembedded/meta-oe/recipes-benchmark/bonnie/files/gcc-4.3-fixes.patch
deleted file mode 100644
index 67f1b74..0000000
--- a/meta-openembedded/meta-oe/recipes-benchmark/bonnie/files/gcc-4.3-fixes.patch
+++ /dev/null
@@ -1,19 +0,0 @@
-Includes string.h to one of the source file.
-
-Upstream-Status: Inappropriate [not author.]
----
- zcav.cpp |    1 +
- 1 file changed, 1 insertion(+)
-
-Index: bonnie++-1.03a/zcav.cpp
-===================================================================
---- bonnie++-1.03a.orig/zcav.cpp
-+++ bonnie++-1.03a/zcav.cpp
-@@ -15,6 +15,7 @@ using namespace std;
- #else
- #include <vector.h>
- #endif
-+#include <string.h>
- 
- // Read the specified number of megabytes of data from the fd and return the
- // amount of time elapsed in seconds.
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/dbench/dbench_4.0.bb b/meta-openembedded/meta-oe/recipes-benchmark/dbench/dbench_4.0.bb
index 1915e4c..fb6a96e 100644
--- a/meta-openembedded/meta-oe/recipes-benchmark/dbench/dbench_4.0.bb
+++ b/meta-openembedded/meta-oe/recipes-benchmark/dbench/dbench_4.0.bb
@@ -14,12 +14,13 @@
 
 inherit autotools
 
-PACKAGES =+ "tbench tbench-dbg"
+PACKAGES =+ "tbench"
+
+RPROVIDES_${PN}-dbg += "tbench-dbg"
 
 TARGET_CC_ARCH += "${LDFLAGS}"
 
 FILES_tbench = "${bindir}/tbench* ${prefix}/share/client.txt"
-FILES_tbench-dbg += "${bindir}/.debug/tbench*"
 
 SRC_URI[md5sum] = "1fe56ff71b9a416f8889d7150ac54da4"
 SRC_URI[sha256sum] = "6001893f34e68a3cfeb5d424e1f2bfef005df96a22d86f35dc770c5bccf3aa8a"
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/fio/files/0001-update-the-interpreter-paths.patch b/meta-openembedded/meta-oe/recipes-benchmark/fio/files/0001-update-the-interpreter-paths.patch
new file mode 100644
index 0000000..327b9f5
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-benchmark/fio/files/0001-update-the-interpreter-paths.patch
@@ -0,0 +1,94 @@
+From 55078e494bdf7da7dd9cb76077fa7ac2a66b6dd6 Mon Sep 17 00:00:00 2001
+From: Mingli Yu <mingli.yu@windriver.com>
+Date: Fri, 20 Jul 2018 02:33:25 -0700
+Subject: [PATCH] update the interpreter paths
+
+Update the interpreter path to make it more
+compatible
+
+Upstream-Status: Pending
+
+Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
+---
+ tools/fio_jsonplus_clat2csv     | 2 +-
+ tools/fiologparser.py           | 2 +-
+ tools/genfio                    | 2 +-
+ tools/hist/fiologparser_hist.py | 2 +-
+ tools/hist/half-bins.py         | 2 +-
+ tools/plot/fio2gnuplot          | 2 +-
+ t/steadystate_tests.py | 2 +-
+ 7 files changed, 7 insertions(+), 7 deletions(-)
+
+diff --git a/tools/fio_jsonplus_clat2csv b/tools/fio_jsonplus_clat2csv
+index 78a007e5..0524b6e6 100755
+--- a/tools/fio_jsonplus_clat2csv
++++ b/tools/fio_jsonplus_clat2csv
+@@ -1,4 +1,4 @@
+-#!/usr/bin/python2.7
++#!/usr/bin/env python
+ # Note: this script is python2 and python3 compatible.
+ #
+ # fio_jsonplus_clat2csv
+diff --git a/tools/fiologparser.py b/tools/fiologparser.py
+index cc29f1c7..ea60e783 100755
+--- a/tools/fiologparser.py
++++ b/tools/fiologparser.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/python2.7
++#!/usr/bin/env python
+ # Note: this script is python2 and python 3 compatible.
+ #
+ # fiologparser.py
+diff --git a/tools/genfio b/tools/genfio
+index 286d814d..8518bbcc 100755
+--- a/tools/genfio
++++ b/tools/genfio
+@@ -1,4 +1,4 @@
+-#!/usr/bin/bash
++#!/bin/bash
+ #
+ #  Copyright (C) 2013 eNovance SAS <licensing@enovance.com>
+ #  Author: Erwan Velu  <erwan@enovance.com>
+diff --git a/tools/hist/fiologparser_hist.py b/tools/hist/fiologparser_hist.py
+index 8910d5fa..b77c2933 100755
+--- a/tools/hist/fiologparser_hist.py
++++ b/tools/hist/fiologparser_hist.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/python2.7
++#!/usr/bin/env python
+ """ 
+     Utility for converting *_clat_hist* files generated by fio into latency statistics.
+     
+diff --git a/tools/hist/half-bins.py b/tools/hist/half-bins.py
+index 1bba8ff7..58d53e36 100755
+--- a/tools/hist/half-bins.py
++++ b/tools/hist/half-bins.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/python2.7
++#!/usr/bin/env python
+ """ Cut the number bins in half in fio histogram output. Example usage:
+ 
+         $ half-bins.py -c 2 output_clat_hist.1.log > smaller_clat_hist.1.log
+diff --git a/tools/plot/fio2gnuplot b/tools/plot/fio2gnuplot
+index 4d1815cf..509141af 100755
+--- a/tools/plot/fio2gnuplot
++++ b/tools/plot/fio2gnuplot
+@@ -1,4 +1,4 @@
+-#!/usr/bin/python2.7
++#!/usr/bin/env python
+ # Note: this script is python2 and python3 compatible.
+ #
+ #  Copyright (C) 2013 eNovance SAS <licensing@enovance.com>
+diff --git a/t/steadystate_tests.py b/t/steadystate_tests.py
+index 50254dcc..95e7dfde 100755
+--- a/t/steadystate_tests.py
++++ b/t/steadystate_tests.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/python2.7
++#!/usr/bin/env python
+ # Note: this script is python2 and python 3 compatible.
+ #
+ # steadystate_tests.py
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/fio/fio_2.9.bb b/meta-openembedded/meta-oe/recipes-benchmark/fio/fio_2.9.bb
deleted file mode 100644
index 67b513f..0000000
--- a/meta-openembedded/meta-oe/recipes-benchmark/fio/fio_2.9.bb
+++ /dev/null
@@ -1,41 +0,0 @@
-SUMMARY = "Filesystem and hardware benchmark and stress tool"
-DESCRIPTION = "fio is an I/O tool meant to be used both for benchmark and \
-stress/hardware verification. It has support for a number of I/O engines, \
-I/O priorities (for newer Linux kernels), rate I/O, forked or threaded jobs, \
-and much more. It can work on block devices as well as files. fio accepts \
-job descriptions in a simple-to-understand text format. Several example job \
-files are included. fio displays all sorts of I/O performance information."
-HOMEPAGE = "http://freecode.com/projects/fio"
-SECTION = "console/tests"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
-
-DEPENDS = "libaio zlib"
-
-PACKAGECONFIG_NUMA = "numa"
-# ARM does not currently support NUMA
-PACKAGECONFIG_NUMA_arm = ""
-
-PACKAGECONFIG ??= "${PACKAGECONFIG_NUMA}"
-PACKAGECONFIG[numa] = ",--disable-numa,numactl"
-
-# rev for v2.9
-SRCREV = "fe8d0f4c54f0c308c9a02a4e3c2f5084e8bf5461"
-SRC_URI = "git://git.kernel.dk/fio.git"
-
-S = "${WORKDIR}/git"
-
-# avoids build breaks when using no-static-libs.inc
-DISABLE_STATIC = ""
-
-EXTRA_OEMAKE = "CC='${CC}' LDFLAGS='${LDFLAGS}'"
-
-do_configure() {
-    ./configure ${EXTRA_OECONF}
-}
-
-do_install() {
-    oe_runmake install DESTDIR=${D} prefix=${prefix} mandir=${mandir}
-    install -d ${D}/${docdir}/${PN}
-    cp -R --no-dereference --preserve=mode,links -v ${S}/examples ${D}/${docdir}/${PN}/
-}
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/fio/fio_3.12.bb b/meta-openembedded/meta-oe/recipes-benchmark/fio/fio_3.12.bb
new file mode 100644
index 0000000..2deb42d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-benchmark/fio/fio_3.12.bb
@@ -0,0 +1,45 @@
+SUMMARY = "Filesystem and hardware benchmark and stress tool"
+DESCRIPTION = "fio is an I/O tool meant to be used both for benchmark and \
+stress/hardware verification. It has support for a number of I/O engines, \
+I/O priorities (for newer Linux kernels), rate I/O, forked or threaded jobs, \
+and much more. It can work on block devices as well as files. fio accepts \
+job descriptions in a simple-to-understand text format. Several example job \
+files are included. fio displays all sorts of I/O performance information."
+HOMEPAGE = "http://freecode.com/projects/fio"
+SECTION = "console/tests"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+DEPENDS = "libaio zlib"
+RDEPENDS_${PN} = "python bash"
+
+PACKAGECONFIG_NUMA = "numa"
+# ARM does not currently support NUMA
+PACKAGECONFIG_NUMA_arm = ""
+
+PACKAGECONFIG ??= "${PACKAGECONFIG_NUMA}"
+PACKAGECONFIG[numa] = ",--disable-numa,numactl"
+
+# rev for v3.8
+SRCREV = "16500b5a0b03ee0142d592bb74a46943a223b06e"
+SRC_URI = "git://git.kernel.dk/fio.git \
+          file://0001-update-the-interpreter-paths.patch \
+"
+
+S = "${WORKDIR}/git"
+
+# avoids build breaks when using no-static-libs.inc
+DISABLE_STATIC = ""
+
+EXTRA_OEMAKE = "CC='${CC}' LDFLAGS='${LDFLAGS}'"
+EXTRA_OECONF = "--disable-optimizations"
+
+do_configure() {
+    ./configure ${EXTRA_OECONF}
+}
+
+do_install() {
+    oe_runmake install DESTDIR=${D} prefix=${prefix} mandir=${mandir}
+    install -d ${D}/${docdir}/${PN}
+    cp -R --no-dereference --preserve=mode,links -v ${S}/examples ${D}/${docdir}/${PN}/
+}
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/glmark2/glmark2_git.bb b/meta-openembedded/meta-oe/recipes-benchmark/glmark2/glmark2_git.bb
index b72ced0..99050e7 100644
--- a/meta-openembedded/meta-oe/recipes-benchmark/glmark2/glmark2_git.bb
+++ b/meta-openembedded/meta-oe/recipes-benchmark/glmark2/glmark2_git.bb
@@ -36,8 +36,8 @@
 
 PACKAGECONFIG[x11-gl] = ",,virtual/libgl virtual/libx11"
 PACKAGECONFIG[x11-gles2] = ",,virtual/libgles2 virtual/libx11"
-PACKAGECONFIG[drm-gl] = ",,virtual/libgl libdrm"
-PACKAGECONFIG[drm-gles2] = ",,virtual/libgles2 libdrm"
+PACKAGECONFIG[drm-gl] = ",,virtual/libgl libdrm virtual/libgbm"
+PACKAGECONFIG[drm-gles2] = ",,virtual/libgles2 libdrm virtual/libgbm"
 PACKAGECONFIG[wayland-gl] = ",,virtual/libgl wayland"
 PACKAGECONFIG[wayland-gles2] = ",,virtual/libgles2 wayland"
 
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/iozone3/iozone3_465.bb b/meta-openembedded/meta-oe/recipes-benchmark/iozone3/iozone3_465.bb
deleted file mode 100644
index 2864a4d..0000000
--- a/meta-openembedded/meta-oe/recipes-benchmark/iozone3/iozone3_465.bb
+++ /dev/null
@@ -1,117 +0,0 @@
-SUMMARY = "Filesystem and Disk Benchmarking Tool"
-HOMEPAGE = "http://www.iozone.org/"
-AUTHOR = "Don Capps <don.capps2@verizon.net>, William D. Norcott <wnorcott@us.oracle.com>"
-SECTION = "console/tests"
-LICENSE = "iozone3"
-LIC_FILES_CHKSUM = "file://iozone.c;beginline=37;endline=48;md5=7331260091868dcad0f9edea735b5f4b \
-    file://iozone.c;beginline=260;endline=266;md5=77f9ee51e45b57a7e7519c4fa0b4f00b \
-"
-SRC_URI = "http://www.iozone.org/src/current/${BPN}_${PV}.tar \
-    file://parallelism.patch \
-    file://copyright.txt \
-"
-SRC_URI[md5sum] = "c924e5e46fb1cf8145f420e8e57eb954"
-SRC_URI[sha256sum] = "2e3d72916e7d7340a7c505fc0c3d28553fcc5ff2daf41d811368e55bd4e6a293"
-
-S = "${WORKDIR}/${BPN}_${PV}/src/current/"
-
-#
-# All other arches can use the default OEMAKE except those
-# explicitly listed below. Another, the iozone3 Makefile
-# needs to be told about the cross-compiler explicitly here.
-#
-EXTRA_OEMAKE_powerpc = "linux-powerpc CC='${CC}' GCC='${CC}'"
-EXTRA_OEMAKE_powerpc64 = "linux-powerpc64 CC='${CC}' GCC='${CC}'"
-EXTRA_OEMAKE_x86-64 = "linux-AMD64 CC='${CC}' GCC='${CC}'"
-EXTRA_OEMAKE_arm = "linux-arm CC='${CC}' GCC='${CC}'"
-EXTRA_OEMAKE = "linux CC='${CC}' GCC='${CC}'"
-
-TARGET_CC_ARCH += "${LDFLAGS}"
-
-do_install() {
-    install -d ${D}${bindir} \
-               ${D}${mandir}/man1 \
-               ${D}${datadir}/doc/${BPN}/examples
-
-    install -m 0755 ${S}/iozone ${D}${bindir}
-    install -m 0755 ${S}/fileop ${D}${bindir}
-    install -m 0644 ${WORKDIR}/${BPN}_${PV}/docs/iozone.1 ${D}${mandir}/man1/
-    install -m 0644 ${WORKDIR}/copyright.txt ${D}${datadir}/doc/${BPN}/
-
-    install -m 0644 ${S}/*.dem ${D}${datadir}/doc/${BPN}/examples
-    install -m 0644 ${S}/client_list ${D}${datadir}/doc/${BPN}/examples
-    install -m 0644 ${S}/Gnuplot.txt ${D}${datadir}/doc/${BPN}/examples
-
-    install -m 0755 ${S}/Generate_Graphs ${D}${datadir}/doc/${BPN}/examples
-    install -m 0755 ${S}/gengnuplot.sh ${D}${datadir}/doc/${BPN}/examples
-    install -m 0755 ${S}/report.pl ${D}${datadir}/doc/${BPN}/examples
-
-    install -m 0644 ${WORKDIR}/${BPN}_${PV}/docs/Iozone_ps.gz ${D}${datadir}/doc/${BPN}/
-    install -m 0644 ${WORKDIR}/${BPN}_${PV}/docs/IOzone_msword_98.pdf ${D}${datadir}/doc/${BPN}/
-    install -m 0644 ${WORKDIR}/${BPN}_${PV}/docs/Run_rules.doc ${D}${datadir}/doc/${BPN}/
-}
-
-FILES_${PN} += "${datadir}/doc/${PN}/copyright.txt"
-
-# LICENSE:
-#
-#  Copyright 1991, 1992, 1994, 1998, 1999, 2002   William D. Norcott
-#
-#  License to freely use and distribute this software is hereby granted
-#  by the author, subject to the condition that this copyright notice
-#  remains intact.  The author retains the exclusive right to publish
-#  derivative works based on this work, including, but not limited to
-#  revised versions of this work.
-#
-
-#
-# Below is author reply to question about distributing iozone3 in
-# OpenEmbedded:
-#
-# ========================================================================
-#
-# Marcin,
-#
-#     Re-distribution is permitted as long as the copyright is
-#     maintained and the source code is not changed. I do not
-#     see a problem with your mods to enable fileop for Linux-arm,
-#     as these mods have been returned to the Iozone folks,
-#     and they have been accepted for inclusion in the next
-#     release :-)
-#
-# Thank you for your contribution,
-# Don Capps
-#
-# ----- Original Message -----
-# From: "Marcin Juszkiewicz" <firma@hrw.one.pl>
-# To: "Don Capps" <don.capps2@verizon.net>; "William D. Norcott"
-# <wnorcott@us.oracle.com>
-# Sent: Sunday, October 29, 2006 4:55 PM
-# Subject: iozone3 263 patch for arm and License question
-#
-#
-# > Morning
-# >
-# > I want to include iozone3 in OpenEmbedded [1] metadata to give it for
-# > other developers. Currently OE is used to build few distributions for
-# > misc platforms: ARM, SH3, SH4, x86, PowerPC and different types of
-# > machines (PDA, settopbox, devboards, desktops, thin clients, routers).
-# >
-# > According to your distribution of derivations is forbidden. Packaging
-# > iozone3 in OpenEmbedded will not involve any source code changes. But
-# > when I was building it for ARM I discovered that fileop binary was not
-# > built - so I created patch for it (attached). Not yet tested it on target
-# > device.
-# >
-# > Thus, I seek your written permission via e-mail to distribute a package of
-# > the unmodified source code and also a package of the pre-compiled binary.
-# > Your copyright statement will be included in the package.
-# >
-# >
-# > 1. http://www.openembedded.org/
-# >
-# > Regards
-# > --
-# > JID: hrw-jabber.org
-# > OpenEmbedded developer/consultant
-
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/iozone3/iozone3_484.bb b/meta-openembedded/meta-oe/recipes-benchmark/iozone3/iozone3_484.bb
new file mode 100644
index 0000000..f218b87
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-benchmark/iozone3/iozone3_484.bb
@@ -0,0 +1,119 @@
+SUMMARY = "Filesystem and Disk Benchmarking Tool"
+HOMEPAGE = "http://www.iozone.org/"
+AUTHOR = "Don Capps <don.capps2@verizon.net>, William D. Norcott <wnorcott@us.oracle.com>"
+SECTION = "console/tests"
+LICENSE = "iozone3"
+LIC_FILES_CHKSUM = "file://iozone.c;beginline=37;endline=48;md5=7331260091868dcad0f9edea735b5f4b \
+    file://iozone.c;beginline=269;endline=275;md5=77f9ee51e45b57a7e7519c4fa0b4f00b \
+"
+SRC_URI = "http://www.iozone.org/src/current/${BPN}_${PV}.tar \
+    file://parallelism.patch \
+    file://copyright.txt \
+"
+SRC_URI[md5sum] = "aa6b88ab83793cb6809ca06949a6ab01"
+SRC_URI[sha256sum] = "e816e6ae2f02003f2a6d19d47fcd9a50fdd8078da4f35fe3d4b9caf91c3d7216"
+
+UPSTREAM_CHECK_REGEX = "iozone3_(?P<pver>\d+).tar"
+
+S = "${WORKDIR}/${BPN}_${PV}/src/current/"
+
+#
+# All other arches can use the default OEMAKE except those
+# explicitly listed below. Another, the iozone3 Makefile
+# needs to be told about the cross-compiler explicitly here.
+#
+EXTRA_OEMAKE_powerpc = "linux-powerpc CC='${CC}' GCC='${CC}'"
+EXTRA_OEMAKE_powerpc64 = "linux-powerpc64 CC='${CC}' GCC='${CC}'"
+EXTRA_OEMAKE_x86-64 = "linux-AMD64 CC='${CC}' GCC='${CC}'"
+EXTRA_OEMAKE_arm = "linux-arm CC='${CC}' GCC='${CC}'"
+EXTRA_OEMAKE = "linux CC='${CC}' GCC='${CC}'"
+
+TARGET_CC_ARCH += "${LDFLAGS}"
+
+do_install() {
+    install -d ${D}${bindir} \
+               ${D}${mandir}/man1 \
+               ${D}${datadir}/doc/${BPN}/examples
+
+    install -m 0755 ${S}/iozone ${D}${bindir}
+    install -m 0755 ${S}/fileop ${D}${bindir}
+    install -m 0644 ${WORKDIR}/${BPN}_${PV}/docs/iozone.1 ${D}${mandir}/man1/
+    install -m 0644 ${WORKDIR}/copyright.txt ${D}${datadir}/doc/${BPN}/
+
+    install -m 0644 ${S}/*.dem ${D}${datadir}/doc/${BPN}/examples
+    install -m 0644 ${S}/client_list ${D}${datadir}/doc/${BPN}/examples
+    install -m 0644 ${S}/Gnuplot.txt ${D}${datadir}/doc/${BPN}/examples
+
+    install -m 0755 ${S}/Generate_Graphs ${D}${datadir}/doc/${BPN}/examples
+    install -m 0755 ${S}/gengnuplot.sh ${D}${datadir}/doc/${BPN}/examples
+    install -m 0755 ${S}/report.pl ${D}${datadir}/doc/${BPN}/examples
+
+    install -m 0644 ${WORKDIR}/${BPN}_${PV}/docs/Iozone_ps.gz ${D}${datadir}/doc/${BPN}/
+    install -m 0644 ${WORKDIR}/${BPN}_${PV}/docs/IOzone_msword_98.pdf ${D}${datadir}/doc/${BPN}/
+    install -m 0644 ${WORKDIR}/${BPN}_${PV}/docs/Run_rules.doc ${D}${datadir}/doc/${BPN}/
+}
+
+FILES_${PN} += "${datadir}/doc/${PN}/copyright.txt"
+
+# LICENSE:
+#
+#  Copyright 1991, 1992, 1994, 1998, 1999, 2002   William D. Norcott
+#
+#  License to freely use and distribute this software is hereby granted
+#  by the author, subject to the condition that this copyright notice
+#  remains intact.  The author retains the exclusive right to publish
+#  derivative works based on this work, including, but not limited to
+#  revised versions of this work.
+#
+
+#
+# Below is author reply to question about distributing iozone3 in
+# OpenEmbedded:
+#
+# ========================================================================
+#
+# Marcin,
+#
+#     Re-distribution is permitted as long as the copyright is
+#     maintained and the source code is not changed. I do not
+#     see a problem with your mods to enable fileop for Linux-arm,
+#     as these mods have been returned to the Iozone folks,
+#     and they have been accepted for inclusion in the next
+#     release :-)
+#
+# Thank you for your contribution,
+# Don Capps
+#
+# ----- Original Message -----
+# From: "Marcin Juszkiewicz" <firma@hrw.one.pl>
+# To: "Don Capps" <don.capps2@verizon.net>; "William D. Norcott"
+# <wnorcott@us.oracle.com>
+# Sent: Sunday, October 29, 2006 4:55 PM
+# Subject: iozone3 263 patch for arm and License question
+#
+#
+# > Morning
+# >
+# > I want to include iozone3 in OpenEmbedded [1] metadata to give it for
+# > other developers. Currently OE is used to build few distributions for
+# > misc platforms: ARM, SH3, SH4, x86, PowerPC and different types of
+# > machines (PDA, settopbox, devboards, desktops, thin clients, routers).
+# >
+# > According to your distribution of derivations is forbidden. Packaging
+# > iozone3 in OpenEmbedded will not involve any source code changes. But
+# > when I was building it for ARM I discovered that fileop binary was not
+# > built - so I created patch for it (attached). Not yet tested it on target
+# > device.
+# >
+# > Thus, I seek your written permission via e-mail to distribute a package of
+# > the unmodified source code and also a package of the pre-compiled binary.
+# > Your copyright statement will be included in the package.
+# >
+# >
+# > 1. http://www.openembedded.org/
+# >
+# > Regards
+# > --
+# > JID: hrw-jabber.org
+# > OpenEmbedded developer/consultant
+
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/iperf3/iperf3_3.2.bb b/meta-openembedded/meta-oe/recipes-benchmark/iperf3/iperf3_3.2.bb
deleted file mode 100644
index 2ed0811..0000000
--- a/meta-openembedded/meta-oe/recipes-benchmark/iperf3/iperf3_3.2.bb
+++ /dev/null
@@ -1,33 +0,0 @@
-SUMMARY = "Network benchmark tool"
-DESCRIPTION = "\
-iperf is a tool for active measurements of the maximum achievable bandwidth \
-on IP networks. It supports tuning of various parameters related to timing, \
-protocols, and buffers. For each test it reports the bandwidth, loss, and \
-other parameters."
-HOMEPAGE = "http://software.es.net/iperf/"
-SECTION = "console/network"
-BUGTRACKER = "https://github.com/esnet/iperf/issues"
-AUTHOR = "ESNET <info@es.net>, Lawrence Berkeley National Laboratory <websupport@lbl.gov>"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=d098223e44bdd19585315ee75cd9d2d7"
-
-DEPENDS = "openssl"
-
-SRC_URI = "git://github.com/esnet/iperf.git \
-           file://automake-foreign.patch \
-           file://0002-Remove-pg-from-profile_CFLAGS.patch \
-           "
-
-SRCREV = "88d907f7fb58bfab5d086c5da60c922e1c582c92"
-
-S = "${WORKDIR}/git"
-
-inherit autotools
-
-PACKAGECONFIG[lksctp] = "ac_cv_header_netinet_sctp_h=yes,ac_cv_header_netinet_sctp_h=no,lksctp-tools"
-
-CFLAGS += "-D_GNU_SOURCE"
-
-EXTRA_OECONF = "--with-openssl=${RECIPE_SYSROOT}"
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/iperf3/iperf3_3.6.bb b/meta-openembedded/meta-oe/recipes-benchmark/iperf3/iperf3_3.6.bb
new file mode 100644
index 0000000..4e11d82
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-benchmark/iperf3/iperf3_3.6.bb
@@ -0,0 +1,33 @@
+SUMMARY = "Network benchmark tool"
+DESCRIPTION = "\
+iperf is a tool for active measurements of the maximum achievable bandwidth \
+on IP networks. It supports tuning of various parameters related to timing, \
+protocols, and buffers. For each test it reports the bandwidth, loss, and \
+other parameters."
+HOMEPAGE = "http://software.es.net/iperf/"
+SECTION = "console/network"
+BUGTRACKER = "https://github.com/esnet/iperf/issues"
+AUTHOR = "ESNET <info@es.net>, Lawrence Berkeley National Laboratory <websupport@lbl.gov>"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=a9a036136b748453e839c0eb8906ef2e"
+
+DEPENDS = "openssl"
+
+SRC_URI = "git://github.com/esnet/iperf.git \
+           file://automake-foreign.patch \
+           file://0002-Remove-pg-from-profile_CFLAGS.patch \
+           "
+
+SRCREV = "88f3ad87f38762081a6d7127890ff5c3a052b06a"
+
+S = "${WORKDIR}/git"
+
+inherit autotools
+
+PACKAGECONFIG[lksctp] = "ac_cv_header_netinet_sctp_h=yes,ac_cv_header_netinet_sctp_h=no,lksctp-tools"
+
+CFLAGS += "-D_GNU_SOURCE"
+
+EXTRA_OECONF = "--with-openssl=${RECIPE_SYSROOT}${prefix}"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0001-include-stddef.h-for-ptrdiff_t.patch b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0001-include-stddef.h-for-ptrdiff_t.patch
new file mode 100644
index 0000000..a84414c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0001-include-stddef.h-for-ptrdiff_t.patch
@@ -0,0 +1,23 @@
+From 351d1de09dd80049b7a2cb02c5750635d0389873 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 21 Jun 2018 19:25:57 -0700
+Subject: [PATCH] include stddef.h for ptrdiff_t
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+---
+ morecore.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/morecore.c b/morecore.c
+index 6563bbd..0eef782 100644
+--- a/morecore.c
++++ b/morecore.c
+@@ -19,6 +19,7 @@
+ 
+ #define _GNU_SOURCE
+ 
++#include <stddef.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <malloc.h>
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0001-run_test.py-not-use-hard-coded-path-.-obj-hugeadm.patch b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0001-run_test.py-not-use-hard-coded-path-.-obj-hugeadm.patch
index 3082d7e..53f35ab 100644
--- a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0001-run_test.py-not-use-hard-coded-path-.-obj-hugeadm.patch
+++ b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0001-run_test.py-not-use-hard-coded-path-.-obj-hugeadm.patch
@@ -1,4 +1,4 @@
-From a85fc43243f8bfad12d306a4a0e230fb8b3e828a Mon Sep 17 00:00:00 2001
+From 0077532b07e268347cb8557be6d70148d5f0e840 Mon Sep 17 00:00:00 2001
 From: Ting Liu <b28495@freescale.com>
 Date: Wed, 21 Aug 2013 15:44:57 +0800
 Subject: [PATCH] run_test.py: not use hard coded path ../obj/hugeadm
@@ -9,15 +9,16 @@
 Upstream-Status: Submitted
 
 Signed-off-by: Ting Liu <b28495@freescale.com>
+
 ---
- tests/run_tests.py |   12 +++++++++++-
- 1 files changed, 11 insertions(+), 1 deletions(-)
+ tests/run_tests.py | 12 +++++++++++-
+ 1 file changed, 11 insertions(+), 1 deletion(-)
 
 diff --git a/tests/run_tests.py b/tests/run_tests.py
-index d9a6b35..a9bab8f 100755
+index 3c95a03..560df6b 100755
 --- a/tests/run_tests.py
 +++ b/tests/run_tests.py
-@@ -232,9 +232,19 @@ def get_pagesizes():
+@@ -234,9 +234,19 @@ def get_pagesizes():
      Use libhugetlbfs' hugeadm utility to get a list of page sizes that have
      active mount points and at least one huge page allocated to the pool.
      """
@@ -38,6 +39,3 @@
      if rc != 0 or out == "": return sizes
  
      for size in out.split("\n"): sizes.add(int(size))
--- 
-1.7.3.4
-
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0002-Mark-glibc-specific-code-so.patch b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0002-Mark-glibc-specific-code-so.patch
new file mode 100644
index 0000000..8cb184a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0002-Mark-glibc-specific-code-so.patch
@@ -0,0 +1,37 @@
+From 0f548286848c70aa325c6748d80e8651389b4938 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 21 Jun 2018 19:32:59 -0700
+Subject: [PATCH] Mark glibc specific code so
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+---
+ morecore.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/morecore.c b/morecore.c
+index 0eef782..d48509c 100644
+--- a/morecore.c
++++ b/morecore.c
+@@ -364,6 +364,7 @@ void hugetlbfs_setup_morecore(void)
+ 
+ 	INFO("setup_morecore(): heapaddr = 0x%lx\n", heapaddr);
+ 
++#ifdef __GLIBC__
+ 	heaptop = heapbase = (void *)heapaddr;
+ 	if (__hugetlb_opts.thp_morecore)
+ 		__morecore = &thp_morecore;
+@@ -371,7 +372,6 @@ void hugetlbfs_setup_morecore(void)
+ 		__morecore = &hugetlbfs_morecore;
+ 
+ 	/* Set some allocator options more appropriate for hugepages */
+-
+ 	if (__hugetlb_opts.shrink_ok)
+ 		mallopt(M_TRIM_THRESHOLD, hpage_size + hpage_size / 2);
+ 	else
+@@ -381,4 +381,5 @@ void hugetlbfs_setup_morecore(void)
+ 	 * This doesn't appear to prohibit malloc() from falling back
+ 	 * to mmap() if we run out of hugepages. */
+ 	mallopt(M_MMAP_MAX, 0);
++#endif
+ }
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0003-alloc.c-Avoid-sysconf-_SC_LEVEL2_CACHE_LINESIZE-on-l.patch b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0003-alloc.c-Avoid-sysconf-_SC_LEVEL2_CACHE_LINESIZE-on-l.patch
new file mode 100644
index 0000000..aca7e80
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0003-alloc.c-Avoid-sysconf-_SC_LEVEL2_CACHE_LINESIZE-on-l.patch
@@ -0,0 +1,46 @@
+From 9ff04d7acc700387e3837f8ab11a41efea5ee8b0 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 21 Jun 2018 19:44:26 -0700
+Subject: [PATCH] alloc.c: Avoid sysconf(_SC_LEVEL2_CACHE_LINESIZE) on linux
+
+musl does not have it
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+---
+ alloc.c | 15 ++++++++++++++-
+ 1 file changed, 14 insertions(+), 1 deletion(-)
+
+diff --git a/alloc.c b/alloc.c
+index bce9464..cf7eb40 100644
+--- a/alloc.c
++++ b/alloc.c
+@@ -245,6 +245,19 @@ void free_huge_pages(void *ptr)
+ 	__free_huge_pages(ptr, 1);
+ }
+ 
++static size_t get_cacheline_size() {
++#if defined(__linux__)
++	FILE * fp = fopen("/sys/devices/system/cpu/cpu0/cache/index0/coherency_line_size", "r");
++	unsigned int line_size = 0;
++	if (fp) {
++		fscanf(fp, "%d", &line_size);
++		fclose(fp);
++	}
++	return line_size;
++#else
++	return sysconf(_SC_LEVEL2_CACHE_LINESIZE);
++#endif
++}
+ /*
+  * Offset the buffer using bytes wasted due to alignment to avoid using the
+  * same cache lines for the start of every buffer returned by
+@@ -261,7 +274,7 @@ void *cachecolor(void *buf, size_t len, size_t color_bytes)
+ 
+ 	/* Lookup our cacheline size once */
+ 	if (cacheline_size == 0) {
+-		cacheline_size = sysconf(_SC_LEVEL2_CACHE_LINESIZE);
++		cacheline_size = get_cacheline_size();
+ 		linemod = time(NULL);
+ 	}
+ 
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0004-shm.c-Mark-glibc-specific-changes-so.patch b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0004-shm.c-Mark-glibc-specific-changes-so.patch
new file mode 100644
index 0000000..58776e8
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0004-shm.c-Mark-glibc-specific-changes-so.patch
@@ -0,0 +1,28 @@
+From 9ce323432a7f4d99f617970c7e35b607b9bbf843 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 21 Jun 2018 19:48:04 -0700
+Subject: [PATCH] shm.c: Mark glibc specific changes so
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+---
+ shm.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/shm.c b/shm.c
+index 1f82cab..9447b63 100644
+--- a/shm.c
++++ b/shm.c
+@@ -48,10 +48,11 @@
+  * system shmget() may be performed without worry as there is no dynamic
+  * call chain.
+  */
++#ifdef __GLIBC__
+ extern void *dlsym (void *__restrict __handle, __const char *__restrict __name)
+ 		__attribute__((weak)) __THROW __nonnull ((2));
+ extern char *dlerror (void) __attribute__((weak)) __THROW;
+-
++#endif
+ 
+ /* call syscall shmget through the generic syscall mechanism */
+ static int syscall_shmget(key_t key, size_t size, int shmflg)
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0005-Include-dirent.h-for-ino_t.patch b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0005-Include-dirent.h-for-ino_t.patch
new file mode 100644
index 0000000..0817420
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0005-Include-dirent.h-for-ino_t.patch
@@ -0,0 +1,26 @@
+From bb8c370aaaf25b1fe1fbf984e73177018026cb91 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 21 Jun 2018 19:51:02 -0700
+Subject: [PATCH] Include dirent.h for ino_t
+
+Fixes
+error: unknown type name 'ino_t'; did you mean 'int'?
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+---
+ tests/hugetests.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/tests/hugetests.h b/tests/hugetests.h
+index 8b1d8d9..056042c 100644
+--- a/tests/hugetests.h
++++ b/tests/hugetests.h
+@@ -22,6 +22,7 @@
+ 
+ #include <errno.h>
+ #include <string.h>
++#include <dirent.h>
+ 
+ #include "libhugetlbfs_privutils.h"
+ #include "libhugetlbfs_testprobes.h"
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0006-include-limits.h-for-PATH_MAX.patch b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0006-include-limits.h-for-PATH_MAX.patch
new file mode 100644
index 0000000..2ead21f
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/0006-include-limits.h-for-PATH_MAX.patch
@@ -0,0 +1,40 @@
+From 5f64aa8c47c2d3a155a97e262f89cc47394a69eb Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 21 Jun 2018 19:58:53 -0700
+Subject: [PATCH] include limits.h for PATH_MAX
+
+Fixes
+
+error: 'PATH_MAX' undeclared
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+---
+ hugeadm.c                | 1 +
+ tests/gethugepagesizes.c | 1 +
+ 2 files changed, 2 insertions(+)
+
+diff --git a/hugeadm.c b/hugeadm.c
+index fe4211d..8db274c 100644
+--- a/hugeadm.c
++++ b/hugeadm.c
+@@ -33,6 +33,7 @@
+ #include <grp.h>
+ #include <pwd.h>
+ #include <fcntl.h>
++#include <limits.h>
+ 
+ #include <sys/stat.h>
+ #include <sys/types.h>
+diff --git a/tests/gethugepagesizes.c b/tests/gethugepagesizes.c
+index 9551b38..2645e3f 100644
+--- a/tests/gethugepagesizes.c
++++ b/tests/gethugepagesizes.c
+@@ -29,6 +29,7 @@
+ #include <fcntl.h>
+ #include <stdarg.h>
+ #include <hugetlbfs.h>
++#include <limits.h>
+ 
+ #include "hugetests.h"
+ 
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/Force-text-segment-alignment-to-0x08000000-for-i386-.patch b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/Force-text-segment-alignment-to-0x08000000-for-i386-.patch
deleted file mode 100644
index ce6974d..0000000
--- a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/Force-text-segment-alignment-to-0x08000000-for-i386-.patch
+++ /dev/null
@@ -1,92 +0,0 @@
-From 3c6f8d0e3c0694f79244ec6ad5ad9ba3ca26bc0a Mon Sep 17 00:00:00 2001
-From: Yang Shi <yang.shi@linaro.org>
-Date: Mon, 7 Dec 2015 14:12:13 -0800
-Subject: [PATCH] Force text segment alignment to 0x08000000 for i386 with gold
- linker
-
-Upstream-Status: Backport
-
-When build libhugetlbfs tests with gold linker for i386, the below error occurs:
-
-i586-oe-linux-gcc  -m32 -march=i586 -Wl,-O1 -Wl,--hash-style=gnu
--Wl,--as-needed
---sysroot=/home/jenkins/oe/world/shr-core/tmp-glibc/sysroots/qemux86 -I..
--O2
--Wall -g -o obj32/linkhuge_rw.o -c linkhuge_rw.c
-| i586-oe-linux-gcc  -m32 -march=i586 -Wl,-O1 -Wl,--hash-style=gnu
--Wl,--as-needed
---sysroot=/home/jenkins/oe/world/shr-core/tmp-glibc/sysroots/qemux86
--B./obj32
--Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -Wl,-z,noexecstack -ldl
--L../obj32
--o obj32/linkhuge_rw -Wl,--no-as-needed -lpthread -ldl -lhugetlbfs_privutils
--Wl,--hugetlbfs-align obj32/linkhuge_rw.o obj32/testutils.o
-| i586-oe-linux-ld: internal error in do_write, at
-/home/jenkins/oe/world/shr-core/tmp-glibc/work/x86_64-oe-linux/binutils-cross-i586/2.25-r0/git/gold/output.cc:464
-| collect2: error: ld returned 1 exit status
-
-But, it works well with GNU linker. --hugetlbfs-align flag passes
-"-zcommon-page-size=$SLICE_SIZE -zmax-page-size=$SLICE_SIZE", that are supported by gold linker too.
-But, it looks gold linker deal with them in a different way from gnu linker for i586.
-
-The readelf shows the below result with GNU linker:
-
-Elf file type is EXEC (Executable file)
-Entry point 0x8048fbd
-There are 8 program headers, starting at offset 52
-
-Program Headers:
-  Type           Offset   VirtAddr   PhysAddr   FileSiz MemSiz  Flg Align
-  PHDR           0x000034 0x08000034 0x08000034 0x00100 0x00100 R E 0x4
-  INTERP         0x048134 0x08048134 0x08048134 0x00013 0x00013 R   0x1
-      [Requesting program interpreter: /lib/ld-linux.so.2]
-  LOAD           0x000000 0x08000000 0x08000000 0x5a5bc 0x5a5bc R E 0x400000
-  LOAD           0x05a5bc 0x0845a5bc 0x0845a5bc 0x1028c 0x202cc RW 0x400000
-  DYNAMIC        0x05a5d0 0x0845a5d0 0x0845a5d0 0x000e8 0x000e8 RW  0x4
-  NOTE           0x048148 0x08048148 0x08048148 0x00044 0x00044 R   0x4
-  GNU_EH_FRAME   0x059e5c 0x08059e5c 0x08059e5c 0x0009c 0x0009c R   0x4
-  GNU_STACK      0x000000 0x00000000 0x00000000 0x00000 0x00000 RW  0x10
-
-"--relax" linker option doesn't solve this problem.
-Forced textsegment alignment to 0x08000000 with gold linker, the build will pass and
-readelf shows the same result with GNU linker:
-
-Elf file type is EXEC (Executable file)
-Entry point 0x8048fbd
-There are 8 program headers, starting at offset 52
-
-Program Headers:
-  Type           Offset   VirtAddr   PhysAddr   FileSiz MemSiz  Flg Align
-  PHDR           0x000034 0x08000034 0x08000034 0x00100 0x00100 R E 0x4
-  INTERP         0x048134 0x08048134 0x08048134 0x00013 0x00013 R   0x1
-      [Requesting program interpreter: /lib/ld-linux.so.2]
-  LOAD           0x000000 0x08000000 0x08000000 0x5a5bc 0x5a5bc R E 0x400000
-  LOAD           0x05a5bc 0x0845a5bc 0x0845a5bc 0x1028c 0x202cc RW 0x400000
-  DYNAMIC        0x05a5d0 0x0845a5d0 0x0845a5d0 0x000e8 0x000e8 RW  0x4
-  NOTE           0x048148 0x08048148 0x08048148 0x00044 0x00044 R   0x4
-  GNU_EH_FRAME   0x059e5c 0x08059e5c 0x08059e5c 0x0009c 0x0009c R   0x4
-  GNU_STACK      0x000000 0x00000000 0x00000000 0x00000 0x00000 RW  0x10
-
-The fix just have impact on hugelink_rw test case, which needs --hugetlbfs-align flag.
-
-Signed-off-by: Yang Shi <yang.shi@linaro.org>
-Signed-off-by: Eric B Munson <emunson@mgebm.net>
----
- ld.hugetlbfs | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/ld.hugetlbfs b/ld.hugetlbfs
-index 4417442..32bc6fb 100755
---- a/ld.hugetlbfs
-+++ b/ld.hugetlbfs
-@@ -98,6 +98,7 @@ if [ "$HTLB_ALIGN" == "slice" ]; then
- 	# otherwise it will be NULL.
- 	case "$EMU" in
- 	armelf*_linux_eabi)	HTLBOPTS="$HTLBOPTS -Ttext-segment=$SLICE_SIZE" ;;
-+	elf_i386)		HTLBOPTS="$HTLBOPTS -Ttext-segment=0x08000000" ;;
- 	esac
- fi
- 
--- 
-2.0.2
-
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/libhugetlbfs-avoid-search-host-library-path-for-cros.patch b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/libhugetlbfs-avoid-search-host-library-path-for-cros.patch
index b3fd843..f95e9e8 100644
--- a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/libhugetlbfs-avoid-search-host-library-path-for-cros.patch
+++ b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/libhugetlbfs-avoid-search-host-library-path-for-cros.patch
@@ -1,19 +1,20 @@
-From 0a2877400a086e9d6ddd32a80462b7a931921dc2 Mon Sep 17 00:00:00 2001
+From 82a4f60ab24dff121f5f9d3bbcd9a8a28bb7caef Mon Sep 17 00:00:00 2001
 From: Chunrong Guo <B40290@freescale.com>
 Date: Sun, 8 Sep 2013 23:21:49 -0500
-Subject: [PATCH] libhugetlbfs: avoid search host library path for cross 
+Subject: [PATCH] libhugetlbfs: avoid search host library path for cross
  compilation
 
 Upstream-Status: Inappropriate [oe-core specific]
 
 Signed-off-by: Chunrong Guo <B40290@freescale.com>
+
 ---
- ldscripts/elf32ppclinux.xB   |    2 +-
- ldscripts/elf32ppclinux.xBDT |    2 +-
- ldscripts/elf64ppc.xB        |    2 +-
- ldscripts/elf64ppc.xBDT      |    2 +-
- ldscripts/elf_x86_64.xB      |    2 +-
- ldscripts/elf_x86_64.xBDT    |    2 +-
+ ldscripts/elf32ppclinux.xB   | 2 +-
+ ldscripts/elf32ppclinux.xBDT | 2 +-
+ ldscripts/elf64ppc.xB        | 2 +-
+ ldscripts/elf64ppc.xBDT      | 2 +-
+ ldscripts/elf_x86_64.xB      | 2 +-
+ ldscripts/elf_x86_64.xBDT    | 2 +-
  6 files changed, 6 insertions(+), 6 deletions(-)
 
 diff --git a/ldscripts/elf32ppclinux.xB b/ldscripts/elf32ppclinux.xB
@@ -94,6 +95,3 @@
  INPUT(-lhugetlbfs);
  /* Do we need any of these for elf?
     __DYNAMIC = 0;    */
--- 
-1.7.9.7
-
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/libhugetlbfs-elf_i386-avoid-search-host-library-path.patch b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/libhugetlbfs-elf_i386-avoid-search-host-library-path.patch
index 1566488..7cc180a 100644
--- a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/libhugetlbfs-elf_i386-avoid-search-host-library-path.patch
+++ b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/libhugetlbfs-elf_i386-avoid-search-host-library-path.patch
@@ -1,14 +1,16 @@
-From 889e52753d30179ba4ac940023cb4ed561436ab8 Mon Sep 17 00:00:00 2001
+From b5887693d90c430291b644c2f5713b5fdd1777ce Mon Sep 17 00:00:00 2001
 From: Jackie Huang <jackie.huang@windriver.com>
 Date: Tue, 4 Nov 2014 00:49:11 -0800
-Subject: [PATCH] libhugetlbfs/elf_i386: avoid search host library path for cross compilation
+Subject: [PATCH] libhugetlbfs/elf_i386: avoid search host library path for
+ cross compilation
 
 Upstream-Status: Inappropriate [cross compile specific]
 
 Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
+
 ---
- ldscripts/elf_i386.xB   |    1 -
- ldscripts/elf_i386.xBDT |    1 -
+ ldscripts/elf_i386.xB   | 1 -
+ ldscripts/elf_i386.xBDT | 1 -
  2 files changed, 2 deletions(-)
 
 diff --git a/ldscripts/elf_i386.xB b/ldscripts/elf_i386.xB
@@ -35,6 +37,3 @@
  INPUT(-lhugetlbfs);
  /* Do we need any of these for elf?
     __DYNAMIC = 0;    */
---
-1.7.9.5
-
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/skip-checking-LIB32-and-LIB64-if-they-point-to-the-s.patch b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/skip-checking-LIB32-and-LIB64-if-they-point-to-the-s.patch
index 07a9971..a13c538 100644
--- a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/skip-checking-LIB32-and-LIB64-if-they-point-to-the-s.patch
+++ b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/skip-checking-LIB32-and-LIB64-if-they-point-to-the-s.patch
@@ -1,17 +1,20 @@
-From 355c014573de7f95202cc7c819f81f0f230e4a1a Mon Sep 17 00:00:00 2001
+From 183a4dafe141197de5840f2e48c266ef209307aa Mon Sep 17 00:00:00 2001
 From: Ting Liu <b28495@freescale.com>
 Date: Mon, 18 Jun 2012 16:37:05 +0800
 Subject: [PATCH] skip checking LIB32 and LIB64 if they point to the same place
 
 Upstream-Status: Inappropriate [oe-core specific]
 Signed-off-by: Ting Liu <b28495@freescale.com>
+
 ---
+ Makefile | 1 -
+ 1 file changed, 1 deletion(-)
 
 diff --git a/Makefile b/Makefile
-index 91502e1..bfb3414 100644
+index 51e41f0..373df3c 100644
 --- a/Makefile
 +++ b/Makefile
-@@ -167,7 +167,6 @@ REALLIB32 = $(realpath $(PREFIX)/$(LIB32))
+@@ -177,7 +177,6 @@ REALLIB32 = $(realpath $(PREFIX)/$(LIB32))
  REALLIB64 = $(realpath $(PREFIX)/$(LIB64))
  ifneq ($(realpath $(PREFIX)),)
  ifeq ($(REALLIB32),$(REALLIB64))
@@ -19,5 +22,3 @@
  endif
  endif
  
--- 
-1.9.2
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/tests-Makefile-install-static-4G-edge-testcases.patch b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/tests-Makefile-install-static-4G-edge-testcases.patch
index 249f6e1..b8b2f8e 100644
--- a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/tests-Makefile-install-static-4G-edge-testcases.patch
+++ b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/files/tests-Makefile-install-static-4G-edge-testcases.patch
@@ -1,12 +1,23 @@
+From f1ad8ff887f16daee8d06eca3df0f2541bfdaac0 Mon Sep 17 00:00:00 2001
+From: Ting Liu <b28495@freescale.com>
+Date: Mon, 23 Sep 2013 08:00:55 +0000
+Subject: [PATCH] libhugetlbfs: add recipe
+
 Upstream-Status: Submitted
 
 TESTS_64 is empty, install will fail due to missing file operand
 
 Signed-off-by: Ting Liu <b28495@freescale.com>
 
---- a/tests/Makefileold	2013-10-12 02:32:55.262391998 -0500
-+++ b/tests/Makefile	2013-10-12 02:33:45.929394722 -0500
-@@ -292,7 +292,7 @@
+---
+ tests/Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/tests/Makefile b/tests/Makefile
+index 073df96..0ca3716 100644
+--- a/tests/Makefile
++++ b/tests/Makefile
+@@ -295,7 +295,7 @@ obj64/install:
  	$(INSTALL) -m 755 wrapper-utils.sh $(DESTDIR)$(INST_TESTSDIR64)/obj64
  	$(INSTALL) -m 755 $(HELPERS:%=obj64/%) $(DESTDIR)$(INST_TESTSDIR64)/obj64
  	$(INSTALL) -m 755 $(HELPER_LIBS:%=obj64/%) $(DESTDIR)$(INST_TESTSDIR64)/obj64
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/libhugetlbfs_git.bb b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/libhugetlbfs_git.bb
index a63494a..66fd8e2 100644
--- a/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/libhugetlbfs_git.bb
+++ b/meta-openembedded/meta-oe/recipes-benchmark/libhugetlbfs/libhugetlbfs_git.bb
@@ -3,14 +3,14 @@
 LICENSE = "LGPLv2.1"
 LIC_FILES_CHKSUM = "file://LGPL-2.1;md5=2d5025d4aa3495befef8f17206a5b0a1"
 
-DEPENDS = "sysfsutils perl"
-RDEPENDS_${PN} += "bash perl python python-io python-lang python-subprocess python-resource ${PN}-perl"
+DEPENDS = "sysfsutils"
+RDEPENDS_${PN} += "bash python python-io python-lang python-subprocess python-resource"
 RDEPENDS_${PN}-tests += "bash"
 
-PV = "2.20"
+PV = "2.21"
 PE = "1"
 
-SRCREV = "e44180072b796c0e28e53c4d01ef6279caaa2a99"
+SRCREV = "73d06e69108f231696e9c5c44f4b42690fc5d752"
 SRC_URI = " \
     git://github.com/libhugetlbfs/libhugetlbfs.git;protocol=https \
     file://skip-checking-LIB32-and-LIB64-if-they-point-to-the-s.patch \
@@ -18,9 +18,16 @@
     file://tests-Makefile-install-static-4G-edge-testcases.patch \
     file://0001-run_test.py-not-use-hard-coded-path-.-obj-hugeadm.patch \
     file://libhugetlbfs-elf_i386-avoid-search-host-library-path.patch \
-    file://Force-text-segment-alignment-to-0x08000000-for-i386-.patch \
+    file://0001-include-stddef.h-for-ptrdiff_t.patch \
+    file://0002-Mark-glibc-specific-code-so.patch \
+    file://0003-alloc.c-Avoid-sysconf-_SC_LEVEL2_CACHE_LINESIZE-on-l.patch \
+    file://0004-shm.c-Mark-glibc-specific-changes-so.patch \
+    file://0005-Include-dirent.h-for-ino_t.patch \
+    file://0006-include-limits.h-for-PATH_MAX.patch \
 "
 
+UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+(\.\d+)+)"
+
 S = "${WORKDIR}/git"
 
 COMPATIBLE_HOST = "(i.86|x86_64|powerpc|powerpc64|aarch64|arm).*-linux*"
@@ -43,14 +50,6 @@
     if [ "${@bb.utils.filter('DISTRO_FEATURES', 'ld-is-gold', d)}" ]; then
       sed -i 's/CUSTOM_LDSCRIPTS = yes/CUSTOM_LDSCRIPTS = no/'  Makefile
     fi
-
-    # fixup perl module directory hardcoded to perl5
-    sed -i 's/perl5/perl/g'  Makefile
-
-    # fixup to install perl module under $(LIBDIR)/perl/${@get_perl_version(d)}/TLBC
-    # to avoid below error
-    # Can't locate TLBC/OpCollect.pm in @INC
-    sed -i '/^PMDIR/ s:perl:perl/${@get_perl_version(d)}:g' Makefile
 }
 
 do_install() {
@@ -61,11 +60,10 @@
 }
 
 
-PACKAGES =+ "${PN}-perl ${PN}-tests "
+PACKAGES =+ "${PN}-tests "
 FILES_${PN} += "${libdir}/*.so"
 FILES_${PN}-dev = "${includedir}"
 FILES_${PN}-dbg += "${libdir}/libhugetlbfs/tests/obj32/.debug ${libdir}/libhugetlbfs/tests/obj64/.debug"
-FILES_${PN}-perl = "${libdir}/perl"
 FILES_${PN}-tests += "${libdir}/libhugetlbfs/tests"
 
 INSANE_SKIP_${PN} = "dev-so"
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/0001-src-Makefile-use-libdir-instead-of-hardcoded-lib.patch b/meta-openembedded/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/0001-src-Makefile-use-libdir-instead-of-hardcoded-lib.patch
new file mode 100644
index 0000000..04cef96
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/0001-src-Makefile-use-libdir-instead-of-hardcoded-lib.patch
@@ -0,0 +1,34 @@
+From ea683a0dbaa30a0bf101adb09a1a2531c7112c62 Mon Sep 17 00:00:00 2001
+From: Mingli Yu <Mingli.Yu@windriver.com>
+Date: Mon, 27 Aug 2018 11:02:45 +0800
+Subject: [PATCH] src/Makefile: use libdir instead of hardcoded /lib
+
+use libdir instead of hardcoded /lib
+
+Upstream-Status: Inappropriate [configuration]
+
+Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
+---
+ src/Makefile | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/Makefile b/src/Makefile
+index 4678d54..b73ddb6 100644
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -141,10 +141,10 @@ install-target:
+ 	if [ ! -d $(BASE) ]; then mkdir $(BASE); fi
+ 	if [ ! -d $(BASE)/bin ]; then mkdir $(BASE)/bin; fi
+ 	if [ ! -d $(BASE)/include ]; then mkdir $(BASE)/include; fi
+-	if [ ! -d $(BASE)/lib ]; then mkdir $(BASE)/lib; fi
++	if [ ! -d $(DESTDIR)$(libdir) ]; then mkdir $(DESTDIR)$(libdir); fi
+ 	cp $(EXES) $(BASE)/bin
+ 	cp $(INCS) $(BASE)/include
+-	cp $O/lmbench.a $(BASE)/lib/libmbench.a
++	cp $O/lmbench.a $(DESTDIR)$(libdir)/libmbench.a
+ 	cd ../doc; env MAKEFLAGS="$(MAKEFLAGS)" make CC="${CC}" OS="${OS}" BASE="$(BASE)" install
+ 
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/use-base_libdir-instead-of-hardcoded-lib.patch b/meta-openembedded/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/use-base_libdir-instead-of-hardcoded-lib.patch
deleted file mode 100644
index c6e9465..0000000
--- a/meta-openembedded/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/use-base_libdir-instead-of-hardcoded-lib.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 73fdc58ca4eb9e2f24d854b3af3a4e5daac5a33e Mon Sep 17 00:00:00 2001
-From: Ting Liu <b28495@freescale.com>
-Date: Fri, 22 Nov 2013 15:20:08 +0800
-Subject: [PATCH] use base_libdir instead of hardcoded /lib
-
-Upstream Status: Inappropriate [configuration]
-
-Signed-off-by: Ting Liu <b28495@freescale.com>
-
----
- src/Makefile | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/Makefile b/src/Makefile
-index c7a8c79..c7e4e3c 100644
---- a/src/Makefile
-+++ b/src/Makefile
-@@ -143,10 +143,10 @@ install-target:
- 	if [ ! -d $(BASE) ]; then mkdir $(BASE); fi
- 	if [ ! -d $(BASE)/bin ]; then mkdir $(BASE)/bin; fi
- 	if [ ! -d $(BASE)/include ]; then mkdir $(BASE)/include; fi
--	if [ ! -d $(BASE)/lib ]; then mkdir $(BASE)/lib; fi
-+	if [ ! -d $(BASE)$(base_libdir) ]; then mkdir $(BASE)$(base_libdir); fi
- 	cp $(EXES) $(BASE)/bin
- 	cp $(INCS) $(BASE)/include
--	cp $O/lmbench.a $(BASE)/lib/libmbench.a
-+	cp $O/lmbench.a $(BASE)$(base_libdir)
- 	cd ../doc; env MAKEFLAGS="$(MAKEFLAGS)" make CC="${CC}" OS="${OS}" BASE="$(BASE)" install
- 
- 
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/lmbench/lmbench_3.0-a9.bb b/meta-openembedded/meta-oe/recipes-benchmark/lmbench/lmbench_3.0-a9.bb
index 03b3721..8e6e803 100644
--- a/meta-openembedded/meta-oe/recipes-benchmark/lmbench/lmbench_3.0-a9.bb
+++ b/meta-openembedded/meta-oe/recipes-benchmark/lmbench/lmbench_3.0-a9.bb
@@ -7,9 +7,9 @@
 
 inherit autotools-brokensep
 
-DEPENDS_append_libc-musl = " libtirpc"
-CFLAGS_append_libc-musl = " -I${STAGING_INCDIR}/tirpc"
-LDLIBS_append_libc-musl = " -ltirpc "
+DEPENDS += "libtirpc"
+CFLAGS += "-I${STAGING_INCDIR}/tirpc"
+LDLIBS += " -ltirpc "
 
 PR = "r2"
 
@@ -19,17 +19,20 @@
            file://update-results-script.patch \
            file://obey-ranlib.patch \
            file://update-config-script.patch \
-           file://use-base_libdir-instead-of-hardcoded-lib.patch \
            file://lmbench_result_html_report.patch \
            file://fix-lmbench-memory-check-failure.patch \
            file://0001-avoid-gcc-optimize-away-the-loops.patch \
            file://0001-lat_http.c-Add-printf-format.patch \
            file://0001-Check-for-musl-define-guard-before-redefining-sockle.patch \
            file://0002-build-Adjust-CFLAGS-LDFLAGS-to-append-values-passed-.patch \
+           file://0001-src-Makefile-use-libdir-instead-of-hardcoded-lib.patch \
            "
 SRC_URI[md5sum] = "b3351a3294db66a72e2864a199d37cbf"
 SRC_URI[sha256sum] = "cbd5777d15f44eab7666dcac418054c3c09df99826961a397d9acf43d8a2a551"
 
+UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/lmbench/files/development/"
+UPSTREAM_CHECK_REGEX = "lmbench-(?P<pver>\d+(\.\d+)+-[a-z]+\d+)"
+
 EXTRA_OEMAKE = 'CC="${CC}" AR="${AR}" RANLIB="${RANLIB}" CFLAGS="${CFLAGS}" \
                 LDFLAGS="${LDFLAGS}" LDLIBS="${LDLIBS}" LD="${LD}" OS="${TARGET_SYS}" \
                 TARGET="${TARGET_OS}" BASE="${prefix}" MANDIR="${mandir}"'
@@ -63,6 +66,7 @@
     fi
 
     oe_runmake BASE="${D}${prefix}" MANDIR="${D}${mandir}" \
+            DESTDIR="${D}" \
             -C src install
     mv ${D}${bindir}/line ${D}${bindir}/lm_line
     install -m 0755 ${WORKDIR}/lmbench-run ${D}${bindir}/
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/nbench-byte/nbench-byte_2.2.3.bb b/meta-openembedded/meta-oe/recipes-benchmark/nbench-byte/nbench-byte_2.2.3.bb
index da2cb4b..22bb041 100644
--- a/meta-openembedded/meta-oe/recipes-benchmark/nbench-byte/nbench-byte_2.2.3.bb
+++ b/meta-openembedded/meta-oe/recipes-benchmark/nbench-byte/nbench-byte_2.2.3.bb
@@ -16,7 +16,7 @@
 
 EXTRA_OEMAKE = "-e MAKEFLAGS="
 
-TARGET_CC_ARCH += "${CFLAGS} ${LDFLAGS}"
+TARGET_CC_ARCH += "${LDFLAGS}"
 do_compile() {
     oe_runmake
 }
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/phoronix-test-suite/phoronix-test-suite_7.8.0.bb b/meta-openembedded/meta-oe/recipes-benchmark/phoronix-test-suite/phoronix-test-suite_7.8.0.bb
deleted file mode 100644
index 1f90a71..0000000
--- a/meta-openembedded/meta-oe/recipes-benchmark/phoronix-test-suite/phoronix-test-suite_7.8.0.bb
+++ /dev/null
@@ -1,41 +0,0 @@
-SUMMARY = "Phoronix Test Suite"
-DESCRIPTION = "The Phoronix Test Suite is designed to carry out both qualitative \
-and quantitative benchmarks in a clean, reproducible, and easy-to-use manner."
-LICENSE = "GPLv3"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
-SECTION = "console/tests"
-
-SRC_URI = "http://www.phoronix-test-suite.com/releases/${BP}.tar.gz"
-SRC_URI[md5sum] = "850843bd9252823e7e24bc0849773000"
-SRC_URI[sha256sum] = "cd6c869841f28e4ac1e8a5e4cda05fafce9a523a6b4f0f3a47805efd30494d88"
-
-S = "${WORKDIR}/phoronix-test-suite"
-
-inherit systemd allarch
-
-do_install() {
-    DESTDIR=${D} ./install-sh ${exec_prefix}
-
-    if [ "${systemd_unitdir}" != "/usr/lib/systemd" ]; then
-        install -d ${D}/${systemd_unitdir}/system/
-        mv ${D}/usr/lib/systemd/system/* ${D}/${systemd_unitdir}/system/
-        rm -rf ${D}/usr/lib/
-    fi
-}
-
-# It is not advisable to enable these services by default since they can cause
-# continual target reboots if they encounter network problems.
-#
-SYSTEMD_AUTO_ENABLE = "disable"
-SYSTEMD_SERVICE_${PN} = "phoromatic-client.service phoromatic-server.service"
-
-RDEPENDS_${PN} += "bash python php-cli"
-
-FILES_${PN} += " \
-    ${datadir}/phoronix-test-suite \
-    ${datadir}/appdata/phoronix-test-suite.appdata.xml \
-    ${datadir}/icons/hicolor/48x48/apps/phoronix-test-suite.png \
-    ${datadir}/icons/hicolor/64x64/mimetypes/application-x-openbenchmarking.png \
-    ${datadir}/mime/packages/openbenchmarking-mime.xml \
-    ${systemd_unitdir}/* \
-"
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/phoronix-test-suite/phoronix-test-suite_8.0.1.bb b/meta-openembedded/meta-oe/recipes-benchmark/phoronix-test-suite/phoronix-test-suite_8.0.1.bb
new file mode 100644
index 0000000..b1fa51b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-benchmark/phoronix-test-suite/phoronix-test-suite_8.0.1.bb
@@ -0,0 +1,41 @@
+SUMMARY = "Phoronix Test Suite"
+DESCRIPTION = "The Phoronix Test Suite is designed to carry out both qualitative \
+and quantitative benchmarks in a clean, reproducible, and easy-to-use manner."
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
+SECTION = "console/tests"
+
+SRC_URI = "http://www.phoronix-test-suite.com/releases/${BP}.tar.gz"
+SRC_URI[md5sum] = "3dc3a0e490e909f188379a9e05fd4780"
+SRC_URI[sha256sum] = "6306549109c7254baf31edb385265b19557b5692217d2dfcf96f6fb17de8e842"
+
+S = "${WORKDIR}/phoronix-test-suite"
+
+inherit systemd allarch
+
+do_install() {
+    DESTDIR=${D} ./install-sh ${exec_prefix}
+
+    if [ "${systemd_unitdir}" != "/usr/lib/systemd" ]; then
+        install -d ${D}/${systemd_unitdir}/system/
+        mv ${D}/usr/lib/systemd/system/* ${D}/${systemd_unitdir}/system/
+        rm -rf ${D}/usr/lib/
+    fi
+}
+
+# It is not advisable to enable these services by default since they can cause
+# continual target reboots if they encounter network problems.
+#
+SYSTEMD_AUTO_ENABLE = "disable"
+SYSTEMD_SERVICE_${PN} = "phoromatic-client.service phoromatic-server.service"
+
+RDEPENDS_${PN} += "bash python php-cli util-linux-lscpu os-release lsb"
+
+FILES_${PN} += " \
+    ${datadir}/phoronix-test-suite \
+    ${datadir}/appdata/phoronix-test-suite.appdata.xml \
+    ${datadir}/icons/hicolor/48x48/apps/phoronix-test-suite.png \
+    ${datadir}/icons/hicolor/64x64/mimetypes/application-x-openbenchmarking.png \
+    ${datadir}/mime/packages/openbenchmarking-mime.xml \
+    ${systemd_unitdir}/* \
+"
diff --git a/meta-openembedded/meta-oe/recipes-benchmark/s-suite/s-suite_git.bb b/meta-openembedded/meta-oe/recipes-benchmark/s-suite/s-suite_git.bb
new file mode 100644
index 0000000..77d1728
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-benchmark/s-suite/s-suite_git.bb
@@ -0,0 +1,30 @@
+SUMMARY = "Small collection of benchmarks for storage I/O"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b529aaa6a0c50f15d29f89609b5c22f3"
+
+SRCREV = "79698f645bfb28d0d966484ddad3a1efb562246d"
+PV = "0.0+git${SRCPV}"
+SRC_URI = "git://github.com/Algodev-github/S.git;protocol=https;branch=master"
+
+S = "${WORKDIR}/git"
+
+# installing in /opt/S-suite since the package has
+# dependencies to the directory structure.
+do_install() {
+    install -d ${D}/opt/S-suite
+    for i in $(find ${S}/* -type d); do
+        install -d ${D}/opt/S-suite/$(basename $i)
+        install -m0755 -p ${S}/$(basename $i)/* ${D}/opt/S-suite/$(basename $i)
+    done
+
+    install -m0755 ${S}/config_params.sh ${D}/opt/S-suite
+    install -m0755 ${S}/def_config_params.sh ${D}/opt/S-suite
+}
+
+RDEPENDS_${PN} = "bash bc coreutils gawk g++ gcc fio libaio libaio-dev sysstat"
+
+FILES_${PN} = "/opt/S-suite/"
+
+# added to INSANE_SKIP since s-suite have an runtime
+# dependency (RDEPENDS) on libaio-dev.
+INSANE_SKIP_${PN} += "dev-deps"
diff --git a/meta-openembedded/meta-oe/recipes-bsp/efibootmgr/efibootmgr_0.15.bb b/meta-openembedded/meta-oe/recipes-bsp/efibootmgr/efibootmgr_0.15.bb
deleted file mode 100644
index 9cc62a9..0000000
--- a/meta-openembedded/meta-oe/recipes-bsp/efibootmgr/efibootmgr_0.15.bb
+++ /dev/null
@@ -1,27 +0,0 @@
-DESCRIPTION = "Linux user-space application to modify the EFI Boot Manager."
-SUMMARY = "EFI Boot Manager"
-HOMEPAGE = "https://github.com/rhinstaller/efibootmgr"
-SECTION = "base"
-
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3"
-
-DEPENDS = "pciutils zlib efivar"
-
-COMPATIBLE_HOST = "(i.86|x86_64|arm|aarch64).*-linux"
-
-SRCREV = "5c14da22802576a99ebb854f7aa174f796f7b031"
-SRC_URI = "git://github.com/rhinstaller/efibootmgr.git;protocol=https \
-          "
-S = "${WORKDIR}/git"
-
-inherit pkgconfig
-
-EXTRA_OEMAKE = "'EFIDIR=/' 'CC=${CC}' 'CFLAGS=${CFLAGS} -I${S}/src/include `pkg-config --cflags efivar`'"
-
-CFLAGS_append_toolchain-clang = " -Wno-error"
-do_install () {
-    install -D -p -m0755 ${B}/src/efibootmgr ${D}/${sbindir}/efibootmgr
-}
-
-CLEANBROKEN = "1"
diff --git a/meta-openembedded/meta-oe/recipes-bsp/efibootmgr/efibootmgr_0.16.bb b/meta-openembedded/meta-oe/recipes-bsp/efibootmgr/efibootmgr_0.16.bb
new file mode 100644
index 0000000..6497e09
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-bsp/efibootmgr/efibootmgr_0.16.bb
@@ -0,0 +1,27 @@
+DESCRIPTION = "Linux user-space application to modify the EFI Boot Manager."
+SUMMARY = "EFI Boot Manager"
+HOMEPAGE = "https://github.com/rhinstaller/efibootmgr"
+SECTION = "base"
+
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3"
+
+DEPENDS = "pciutils zlib efivar"
+
+COMPATIBLE_HOST = "(i.86|x86_64|arm|aarch64).*-linux"
+
+SRCREV = "a5103251a11663adddc85c86e0b8d3d3b73cbb4a"
+SRC_URI = "git://github.com/rhinstaller/efibootmgr.git;protocol=https \
+          "
+S = "${WORKDIR}/git"
+
+inherit pkgconfig
+
+EXTRA_OEMAKE = "'EFIDIR=/' 'CC=${CC}' 'CFLAGS=${CFLAGS} -I${S}/src/include `pkg-config --cflags efivar`'"
+
+CFLAGS_append_toolchain-clang = " -Wno-error"
+do_install () {
+    install -D -p -m0755 ${B}/src/efibootmgr ${D}/${sbindir}/efibootmgr
+}
+
+CLEANBROKEN = "1"
diff --git a/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/0001-efivar-dp.h-Add-Wunknown-attributes-when-using-clang.patch b/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/0001-efivar-dp.h-Add-Wunknown-attributes-when-using-clang.patch
deleted file mode 100644
index b4ce132..0000000
--- a/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/0001-efivar-dp.h-Add-Wunknown-attributes-when-using-clang.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From d65c325dd8681edf2ee3332eeb0a547229c7ffb5 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 24 Aug 2017 15:54:47 -0700
-Subject: [PATCH] efivar-dp.h: Add -Wunknown-attributes when using clang
-
-change !dp check to a comparision against NULL to silent clang warning
-nonnull parameter 'dp' will evaluate to 'true' on first encounter
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
----
- src/include/efivar/efivar-dp.h | 5 +++++
- 1 file changed, 5 insertions(+)
-
-diff --git a/src/include/efivar/efivar-dp.h b/src/include/efivar/efivar-dp.h
-index 3a509b7..c140e8d 100644
---- a/src/include/efivar/efivar-dp.h
-+++ b/src/include/efivar/efivar-dp.h
-@@ -783,9 +783,14 @@ extern int efidp_append_instance(const_efidp dp, const_efidp dpi, efidp *out);
-  * though older or other compilers might just ignore that attribute if they
-  * don't support it.  Ugh.
-  */
-+#pragma GCC diagnostic push
- #if defined(__GNUC__) && __GNUC__ >= 6
- #pragma GCC diagnostic ignored "-Wnonnull-compare"
- #endif
-+#if defined(__clang__)
-+#pragma GCC diagnostic ignored "-Wunknown-attributes"
-+#pragma GCC diagnostic ignored "-Wpointer-bool-conversion"
-+#endif
- 
- static inline int16_t
- __attribute__((__artificial__))
diff --git a/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/0001-makeguids-Do-not-use-__bswap_constant_-16-32-macros.patch b/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/0001-makeguids-Do-not-use-__bswap_constant_-16-32-macros.patch
deleted file mode 100644
index 2a6eb06..0000000
--- a/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/0001-makeguids-Do-not-use-__bswap_constant_-16-32-macros.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From dd4291265b7b3d7d7ffa1d8adf32781ae25dbfeb Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 15 Jul 2017 00:29:42 -0700
-Subject: [PATCH] makeguids: Do not use __bswap_constant_{16|32} macros
-
-not available on musl
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
----
- src/makeguids.c | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/src/makeguids.c b/src/makeguids.c
-index da2f5f7..daf821a 100644
---- a/src/makeguids.c
-+++ b/src/makeguids.c
-@@ -155,13 +155,13 @@ main(int argc, char *argv[])
- #if BYTE_ORDER == BIG_ENDIAN\n\
- #define cpu_to_be32(n) (n)\n\
- #define cpu_to_be16(n) (n)\n\
--#define cpu_to_le32(n) (__bswap_constant_32(n))\n\
--#define cpu_to_le16(n) (__bswap_constant_16(n))\n\
-+#define cpu_to_le32(n) ((uint32_t) ((n)>>24 | (n)>>8&0xff00 | (n)<<8&0xff0000 | (n)<<24))\n\
-+#define cpu_to_le16(n) ((uint16_t) ((n)<<8 | (n)>>8))\n\
- #else\n\
- #define cpu_to_le32(n) (n)\n\
- #define cpu_to_le16(n) (n)\n\
--#define cpu_to_be32(n) (__bswap_constant_32(n))\n\
--#define cpu_to_be16(n) (__bswap_constant_16(n))\n\
-+#define cpu_to_be32(n) ((uint32_t) ((n)>>24 | (n)>>8&0xff00 | (n)<<8&0xff0000 | (n)<<24))\n\
-+#define cpu_to_be16(n) ((uint16_t) ((n)<<8 | (n)>>8))\n\
- #endif\n\
- """);
- 
diff --git a/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/0003-efivar-fix-for-cross-compile.patch b/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/0003-efivar-fix-for-cross-compile.patch
deleted file mode 100644
index 83105fe..0000000
--- a/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/0003-efivar-fix-for-cross-compile.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From dea4a55714249b2734a36701120fd22c91c64ec2 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Sat, 7 May 2016 02:06:47 -0400
-Subject: [PATCH] Makefile: fix efivar.pc not found
-
-It fixes efivar.pc not found:
-...
-| install -d -m 755 efivar/0.23-r0/image/usr/lib/pkgconfig/
-| install -m 644 efivar.pc efivar/0.23-r0/image/usr/lib/pkgconfig/
-;  install -m 644 efiboot.pc efivar/0.23-r0/image/usr/lib/pkgconfig/
-;
-| install: cannot stat 'efivar.pc': No such file or directory
-| install: cannot stat 'efiboot.pc': No such file or directory
-| make[1]: *** [install] Error 1
-| make[1]: Leaving directory `efivar/0.23-r0/git/src'
-| make: *** [install] Error 2
-| ERROR: oe_runmake failed
-...
-
-Upstream-Status: Pending
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
-
----
- src/Makefile | 4 +++-
- 1 file changed, 3 insertions(+), 1 deletion(-)
-
-diff --git a/src/Makefile b/src/Makefile
-index dcc7fc8..691aa8a 100644
---- a/src/Makefile
-+++ b/src/Makefile
-@@ -94,7 +94,9 @@ install : all
- 		ln -fs $(x).1.$(VERSION) $(DESTDIR)$(libdir)/$(x) ;\
- 		)
- 	$(INSTALL) -d -m 755 $(DESTDIR)$(PCDIR)
--	$(foreach x, $(PCTARGETS), $(INSTALL) -m 644 $(x) $(DESTDIR)$(PCDIR) ;)
-+	$(foreach x, $(PCTARGETS), $(INSTALL) -m 644 $(TOPDIR)/src/$(x).in $(DESTDIR)$(PCDIR)/$(x) ;\
-+		sed -i -e "s:@@LIBDIR@@:$(libdir):g" -e "s:@@VERSION@@:$(VERSION):g" \
-+			$(DESTDIR)$(PCDIR)/$(x); )
- 	$(INSTALL) -d -m 755 $(DESTDIR)$(includedir)/efivar
- 	$(foreach x, $(wildcard $(TOPDIR)/src/include/efivar/*.h), $(INSTALL) -m 644 $(x) $(DESTDIR)$(includedir)/efivar/$(notdir $(x));)
- 	$(INSTALL) -d -m 755 $(DESTDIR)$(bindir)
diff --git a/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/allow-multi-definitions-for-native.patch b/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/allow-multi-definitions-for-native.patch
index f88af1f..043b07a 100644
--- a/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/allow-multi-definitions-for-native.patch
+++ b/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/allow-multi-definitions-for-native.patch
@@ -1,6 +1,6 @@
-From c801dcb03d42eb533a9bead0b397d7ce4fc5a6fe Mon Sep 17 00:00:00 2001
-From: Kai Kang <kai.kang@windriver.com>
-Date: Wed, 10 Aug 2016 17:49:50 +0800
+From c10368b397483a2fc7b493c099d8416d902f8cd8 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Tue, 31 Jul 2018 14:18:35 +0800
 Subject: [PATCH] allow multi definitions for native
 
 Upstream-Status: Pending
@@ -14,12 +14,13 @@
 
 Signed-off-by: Kai Kang <kai.kang@windriver.com>
 
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
  Make.rules | 1 +
  1 file changed, 1 insertion(+)
 
 diff --git a/Make.rules b/Make.rules
-index 88b9aa7..799332f 100644
+index 042585b..257ba45 100644
 --- a/Make.rules
 +++ b/Make.rules
 @@ -20,6 +20,7 @@ include $(TOPDIR)/Make.version
@@ -28,5 +29,8 @@
  	  -Wl,--version-script=$(MAP) \
 +	  -Wl,-z,muldefs \
  	  -o $@ $^ $(LDLIBS)
+ 	ln -vfs $@ $@.1
  
- %.abixml : %.so
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/musl-strndupa.patch b/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/musl-strndupa.patch
deleted file mode 100644
index 5864ac6..0000000
--- a/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar/musl-strndupa.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 8000b9afc858472912aace985004b44f8eb467e0 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 18 Aug 2017 09:49:49 -0700
-Subject: [PATCH] support musl
-
-Upstream-Status: Pending
----
- src/linux.c | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/src/linux.c b/src/linux.c
-index 34ed479..1304f2b 100644
---- a/src/linux.c
-+++ b/src/linux.c
-@@ -40,6 +40,10 @@
- #include <efivar.h>
- #include <efiboot.h>
- 
-+#if !defined(__GLIBC__)
-+#define strndupa(x,s) strncpy(alloca(strlen(x)+1),x,s)
-+#endif
-+
- #include "dp.h"
- #include "linux.h"
- #include "util.h"
diff --git a/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar_0.31.bb b/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar_0.31.bb
deleted file mode 100644
index 9d4cdc9..0000000
--- a/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar_0.31.bb
+++ /dev/null
@@ -1,50 +0,0 @@
-SUMMARY = "Tools to manipulate UEFI variables"
-DESCRIPTION = "efivar provides a simple command line interface to the UEFI variable facility"
-HOMEPAGE = "https://github.com/rhinstaller/efivar"
-
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=6626bb1e20189cfa95f2c508ba286393"
-
-DEPENDS = "popt"
-DEPENDS_append_class-target = " efivar-native"
-
-inherit pkgconfig
-
-COMPATIBLE_HOST = "(i.86|x86_64|arm|aarch64).*-linux"
-
-SRCREV = "11324799c68193116e1dd5f94b416591bd324f90"
-SRC_URI = "git://github.com/rhinstaller/efivar.git \
-           file://allow-multi-definitions-for-native.patch \
-           file://0001-makeguids-Do-not-use-__bswap_constant_-16-32-macros.patch \
-           file://musl-strndupa.patch \
-           file://0001-efivar-dp.h-Add-Wunknown-attributes-when-using-clang.patch \
-           "
-SRC_URI_append_class-target = " file://0001-efivar-fix-for-cross-compile.patch \
-                                file://0003-efivar-fix-for-cross-compile.patch \
-                                ${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-gold', 'file://0004-fix-unknow-option-for-gold-linker.patch', '', d)} \
-                              "
-SRC_URI_append_class-native = " file://fix-compile-failure-with-host-gcc-4.6.patch \
-                              "
-
-S = "${WORKDIR}/git"
-
-# Setting CROSS_COMPILE breaks pkgconfig, so just set AR
-EXTRA_OEMAKE = "AR=${TARGET_PREFIX}gcc-ar"
-
-do_compile_prepend() {
-    sed -i -e s:-Werror::g ${S}/gcc.specs
-}
-
-do_compile_class-native() {
-    oe_runmake -C src makeguids
-}
-
-do_install() {
-    oe_runmake install DESTDIR=${D}
-}
-
-do_install_class-native() {
-    install -D -m 0755 ${B}/src/makeguids ${D}${bindir}/makeguids
-}
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar_0.36.bb b/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar_0.36.bb
new file mode 100644
index 0000000..20588ee
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-bsp/efivar/efivar_0.36.bb
@@ -0,0 +1,43 @@
+SUMMARY = "Tools to manipulate UEFI variables"
+DESCRIPTION = "efivar provides a simple command line interface to the UEFI variable facility"
+HOMEPAGE = "https://github.com/rhinstaller/efivar"
+
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=6626bb1e20189cfa95f2c508ba286393"
+
+DEPENDS = "popt"
+DEPENDS_append_class-target = " efivar-native"
+
+inherit pkgconfig
+
+COMPATIBLE_HOST = "(i.86|x86_64|arm|aarch64).*-linux"
+
+SRCREV = "ef3449223ecd1e7b1098c523d66b2f960fe839ea"
+SRC_URI = "git://github.com/rhinstaller/efivar.git \
+           file://allow-multi-definitions-for-native.patch \
+           "
+SRC_URI_append_class-target = " file://0001-efivar-fix-for-cross-compile.patch \
+                                ${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-gold', 'file://0004-fix-unknow-option-for-gold-linker.patch', '', d)} \
+                              "
+SRC_URI_append_class-native = " file://fix-compile-failure-with-host-gcc-4.6.patch \
+                              "
+
+S = "${WORKDIR}/git"
+
+do_compile_prepend() {
+    sed -i -e s:-Werror::g ${S}/gcc.specs
+}
+
+do_compile_class-native() {
+    oe_runmake -C src makeguids CC_FOR_BUILD="${BUILD_CC}"
+}
+
+do_install() {
+    oe_runmake install DESTDIR=${D}
+}
+
+do_install_class-native() {
+    install -D -m 0755 ${B}/src/makeguids ${D}${bindir}/makeguids
+}
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-bsp/flashrom/flashrom/0001-ch341a_spi-Avoid-deprecated-libusb-functions.patch b/meta-openembedded/meta-oe/recipes-bsp/flashrom/flashrom/0001-ch341a_spi-Avoid-deprecated-libusb-functions.patch
new file mode 100644
index 0000000..df80286
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-bsp/flashrom/flashrom/0001-ch341a_spi-Avoid-deprecated-libusb-functions.patch
@@ -0,0 +1,39 @@
+From e5f68189ab3602b1042cc8423fd6a3a23abd5455 Mon Sep 17 00:00:00 2001
+From: Alex James <theracermaster@gmail.com>
+Date: Sat, 14 Apr 2018 22:59:57 -0500
+Subject: [PATCH] ch341a_spi: Avoid deprecated libusb functions
+
+libusb 1.0.22 marked libusb_set_debug as deprecated. For such versions
+of libusb, use libusb_set_option instead.
+
+Change-Id: Ib71ebe812316eaf49136979a942a946ef9e4d487
+Signed-off-by: Alex James <theracermaster@gmail.com>
+Reviewed-on: https://review.coreboot.org/25681
+Tested-by: Nico Huber <nico.h@gmx.de>
+Reviewed-by: David Hendricks <david.hendricks@gmail.com>
+---
+Upstream-Status: Backport
+ ch341a_spi.c | 7 ++++++-
+ 1 file changed, 6 insertions(+), 1 deletion(-)
+
+diff --git a/ch341a_spi.c b/ch341a_spi.c
+index 6eb2804..d880510 100644
+--- a/ch341a_spi.c
++++ b/ch341a_spi.c
+@@ -444,7 +444,12 @@ int ch341a_spi_init(void)
+ 		return -1;
+ 	}
+ 
+-	libusb_set_debug(NULL, 3); // Enable information, warning and error messages (only).
++	/* Enable information, warning, and error messages (only). */
++#if LIBUSB_API_VERSION < 0x01000106
++	libusb_set_debug(NULL, 3);
++#else
++	libusb_set_option(NULL, LIBUSB_OPTION_LOG_LEVEL, LIBUSB_LOG_LEVEL_INFO);
++#endif
+ 
+ 	uint16_t vid = devs_ch341a_spi[0].vendor_id;
+ 	uint16_t pid = devs_ch341a_spi[0].device_id;
+-- 
+2.17.0
+
diff --git a/meta-openembedded/meta-oe/recipes-bsp/flashrom/flashrom_1.0.bb b/meta-openembedded/meta-oe/recipes-bsp/flashrom/flashrom_1.0.bb
index 9eac876..1c17246 100644
--- a/meta-openembedded/meta-oe/recipes-bsp/flashrom/flashrom_1.0.bb
+++ b/meta-openembedded/meta-oe/recipes-bsp/flashrom/flashrom_1.0.bb
@@ -8,6 +8,7 @@
 SRC_URI = "https://download.flashrom.org/releases/flashrom-${PV}.tar.bz2 \
            file://sst26.patch \
            file://0001-platform-Add-riscv-to-known-platforms.patch \
+           file://0001-ch341a_spi-Avoid-deprecated-libusb-functions.patch \
            "
 SRC_URI[md5sum] = "42d999990c735d88653627cefcc13b9a"
 SRC_URI[sha256sum] = "3702fa215ba5fb5af8e54c852d239899cfa1389194c1e51cb2a170c4dc9dee64"
diff --git a/meta-openembedded/meta-oe/recipes-bsp/lm_sensors/lmsensors_3.4.0.bb b/meta-openembedded/meta-oe/recipes-bsp/lm_sensors/lmsensors_3.4.0.bb
index 454a69f..ffab5d6 100644
--- a/meta-openembedded/meta-oe/recipes-bsp/lm_sensors/lmsensors_3.4.0.bb
+++ b/meta-openembedded/meta-oe/recipes-bsp/lm_sensors/lmsensors_3.4.0.bb
@@ -16,6 +16,14 @@
 SRC_URI[md5sum] = "1e9f117cbfa11be1955adc96df71eadb"
 SRC_URI[sha256sum] = "e334c1c2b06f7290e3e66bdae330a5d36054701ffd47a5dde7a06f9a7402cb4e"
 
+# It is using '-' but not '.' as delimiter for the version in the releases page,
+# which causes the version comparison unmatched.
+#UPSTREAM_CHECK_URI = "https://github.com/groeck/lm-sensors/releases"
+
+RECIPE_UPSTREAM_VERSION = "3.4.0"
+RECIPE_UPSTREAM_DATE = "Jun 25, 2015"
+CHECK_DATE = "May 28, 2018"
+
 inherit update-rc.d systemd
 
 RDEPENDS_${PN}-dev = ""
@@ -68,14 +76,16 @@
     fi
 }
 
+RPROVIDES_${PN}-dbg += "${PN}-libsensors-dbg ${PN}-sensors-dbg ${PN}-sensord-dbg ${PN}-isatools-dbg"
+
 # libsensors packages
-PACKAGES =+ "${PN}-libsensors ${PN}-libsensors-dbg ${PN}-libsensors-dev ${PN}-libsensors-staticdev ${PN}-libsensors-doc"
+PACKAGES =+ "${PN}-libsensors ${PN}-libsensors-dev ${PN}-libsensors-staticdev ${PN}-libsensors-doc"
 
 # sensors command packages
-PACKAGES =+ "${PN}-sensors ${PN}-sensors-dbg ${PN}-sensors-doc"
+PACKAGES =+ "${PN}-sensors ${PN}-sensors-doc"
 
 # sensord logging daemon
-PACKAGES =+ "${PN}-sensord ${PN}-sensord-dbg ${PN}-sensord-doc"
+PACKAGES =+ "${PN}-sensord ${PN}-sensord-doc"
 
 # fancontrol script
 PACKAGES =+ "${PN}-fancontrol ${PN}-fancontrol-doc"
@@ -90,11 +100,11 @@
 PACKAGES =+ "${PN}-pwmconfig ${PN}-pwmconfig-doc"
 
 # isadump and isaset helper program
-PACKAGES =+ "${PN}-isatools ${PN}-isatools-dbg ${PN}-isatools-doc"
+PACKAGES =+ "${PN}-isatools ${PN}-isatools-doc"
+
 
 # libsensors files
 FILES_${PN}-libsensors = "${libdir}/libsensors.so.* ${sysconfdir}/sensors3.conf ${sysconfdir}/sensors.d"
-FILES_${PN}-libsensors-dbg = "${libdir}/.debug ${prefix}/src/debug"
 FILES_${PN}-libsensors-dev = "${libdir}/libsensors.so ${includedir}"
 FILES_${PN}-libsensors-staticdev = "${libdir}/libsensors.a"
 FILES_${PN}-libsensors-doc = "${mandir}/man3"
@@ -102,13 +112,11 @@
 
 # sensors command files
 FILES_${PN}-sensors = "${bindir}/sensors"
-FILES_${PN}-sensors-dbg = "${bindir}/.debug/sensors"
 FILES_${PN}-sensors-doc = "${mandir}/man1 ${mandir}/man5"
 RDEPENDS_${PN}-sensors = "${PN}-libsensors"
 
 # sensord logging daemon
 FILES_${PN}-sensord = "${sbindir}/sensord ${sysconfdir}/init.d/sensord ${systemd_unitdir}/system/sensord.service"
-FILES_${PN}-sensord-dbg = "${bindir}/.debug/sensord"
 FILES_${PN}-sensord-doc = "${mandir}/man8/sensord.8"
 RDEPENDS_${PN}-sensord = "${PN}-sensors rrdtool"
 RRECOMMENDS_${PN}-sensord = "lmsensors-config-sensord"
@@ -136,5 +144,4 @@
 
 # isadump and isaset helper program files
 FILES_${PN}-isatools = "${sbindir}/isa*"
-FILES_${PN}-isatools-dbg = "${sbindir}/.debug/isa*"
 FILES_${PN}-isatools-doc = "${mandir}/man8/isa*"
diff --git a/meta-openembedded/meta-oe/recipes-bsp/lssci/lsscsi_0.28.bb b/meta-openembedded/meta-oe/recipes-bsp/lssci/lsscsi_0.28.bb
deleted file mode 100644
index 4b8cbaf..0000000
--- a/meta-openembedded/meta-oe/recipes-bsp/lssci/lsscsi_0.28.bb
+++ /dev/null
@@ -1,12 +0,0 @@
-SUMMARY = "The lsscsi command lists information about SCSI devices in Linux"
-HOMEPAGE = "http://sg.danny.cz/scsi/lsscsi.html"
-LICENSE = "GPLv2"
-SECTION = "base"
-LIC_FILES_CHKSUM="file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3"
-
-SRC_URI = "http://sg.danny.cz/scsi/${BP}.tgz"
-
-SRC_URI[md5sum] = "4a39e3b09cd422e2cae3edbaf56b3176"
-SRC_URI[sha256sum] = "025d009a1af42bc5b2fca664c44c9ecdfd754356e4a44f5c6aced2420afadd50"
-
-inherit autotools
diff --git a/meta-openembedded/meta-oe/recipes-bsp/lsscsi/lsscsi_0.30.bb b/meta-openembedded/meta-oe/recipes-bsp/lsscsi/lsscsi_0.30.bb
new file mode 100644
index 0000000..af34cdc
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-bsp/lsscsi/lsscsi_0.30.bb
@@ -0,0 +1,14 @@
+SUMMARY = "The lsscsi command lists information about SCSI devices in Linux"
+HOMEPAGE = "http://sg.danny.cz/scsi/lsscsi.html"
+LICENSE = "GPLv2"
+SECTION = "base"
+LIC_FILES_CHKSUM="file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3"
+
+SRC_URI = "http://sg.danny.cz/scsi/${BP}.tgz"
+
+SRC_URI[md5sum] = "298a700cd50bb4be1382d618f7b038f4"
+SRC_URI[sha256sum] = "619a2187405f02c5f57682f3478bffc75326803cd08839e39d434250c5518b15"
+
+inherit autotools
+
+S = "${WORKDIR}/lsscsi-030r154"
diff --git a/meta-openembedded/meta-oe/recipes-bsp/nvme-cli/files/0001-Makefile-fix-bash-completion-install-path.patch b/meta-openembedded/meta-oe/recipes-bsp/nvme-cli/files/0001-Makefile-fix-bash-completion-install-path.patch
new file mode 100644
index 0000000..154e140
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-bsp/nvme-cli/files/0001-Makefile-fix-bash-completion-install-path.patch
@@ -0,0 +1,33 @@
+From ef64032b34190079aab591c64a25f7535a977390 Mon Sep 17 00:00:00 2001
+From: Stefan Wiehler <stefan.wiehler@missinglinkelectronics.com>
+Date: Tue, 9 Oct 2018 11:26:34 +0200
+Subject: [PATCH] Makefile: fix bash completion install path
+
+Change path to bash-completion upstream recommendation used by most
+distributions.
+
+Upstream-Status: Accepted
+
+Signed-off-by: Stefan Wiehler <stefan.wiehler@missinglinkelectronics.com>
+---
+ Makefile | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index fa587dd..433bc41 100644
+--- a/Makefile
++++ b/Makefile
+@@ -69,8 +69,8 @@ install-bin: default
+ 	$(INSTALL) -m 755 nvme $(DESTDIR)$(SBINDIR)
+ 
+ install-bash-completion:
+-	$(INSTALL) -d $(DESTDIR)$(PREFIX)/share/bash_completion.d
+-	$(INSTALL) -m 644 -T ./completions/bash-nvme-completion.sh $(DESTDIR)$(PREFIX)/share/bash_completion.d/nvme
++	$(INSTALL) -d $(DESTDIR)$(PREFIX)/share/bash-completion/completions
++	$(INSTALL) -m 644 -T ./completions/bash-nvme-completion.sh $(DESTDIR)$(PREFIX)/share/bash-completion/completions/nvme
+ 
+ install: install-bin install-man install-bash-completion
+ 
+-- 
+1.9.1
+
diff --git a/meta-openembedded/meta-oe/recipes-bsp/nvme-cli/nvme-cli_1.6.bb b/meta-openembedded/meta-oe/recipes-bsp/nvme-cli/nvme-cli_1.6.bb
new file mode 100644
index 0000000..9b7e6cd
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-bsp/nvme-cli/nvme-cli_1.6.bb
@@ -0,0 +1,21 @@
+SUMMARY = "NVMe management command line interface"
+AUTHOR = "Stefan Wiehler <stefan.wiehler@missinglinkelectronics.com>"
+HOMEPAGE = "https://github.com/linux-nvme/nvme-cli"
+SECTION = "console/utils"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=8264535c0c4e9c6c335635c4026a8022"
+DEPENDS = "util-linux"
+PV .= "+git${SRCPV}"
+
+SRC_URI = "git://github.com/linux-nvme/nvme-cli.git \
+           file://0001-Makefile-fix-bash-completion-install-path.patch \
+           "
+SRCREV = "642d426faf8a67ed01e90f7c35c0d967f8cc52a3"
+
+S = "${WORKDIR}/git"
+
+inherit bash-completion
+
+do_install() {
+    oe_runmake PREFIX=${prefix} DESTDIR=${D} install
+}
diff --git a/poky/meta/recipes-bsp/pcmciautils/pcmciautils-018/lex_sys_types.patch b/meta-openembedded/meta-oe/recipes-bsp/pcmciautils/pcmciautils/lex_sys_types.patch
similarity index 100%
rename from poky/meta/recipes-bsp/pcmciautils/pcmciautils-018/lex_sys_types.patch
rename to meta-openembedded/meta-oe/recipes-bsp/pcmciautils/pcmciautils/lex_sys_types.patch
diff --git a/poky/meta/recipes-bsp/pcmciautils/pcmciautils-018/makefile_fix.patch b/meta-openembedded/meta-oe/recipes-bsp/pcmciautils/pcmciautils/makefile_fix.patch
similarity index 100%
rename from poky/meta/recipes-bsp/pcmciautils/pcmciautils-018/makefile_fix.patch
rename to meta-openembedded/meta-oe/recipes-bsp/pcmciautils/pcmciautils/makefile_fix.patch
diff --git a/poky/meta/recipes-bsp/pcmciautils/pcmciautils-018/makefile_race.patch b/meta-openembedded/meta-oe/recipes-bsp/pcmciautils/pcmciautils/makefile_race.patch
similarity index 100%
rename from poky/meta/recipes-bsp/pcmciautils/pcmciautils-018/makefile_race.patch
rename to meta-openembedded/meta-oe/recipes-bsp/pcmciautils/pcmciautils/makefile_race.patch
diff --git a/meta-openembedded/meta-oe/recipes-bsp/pcmciautils/pcmciautils_018.bb b/meta-openembedded/meta-oe/recipes-bsp/pcmciautils/pcmciautils_018.bb
new file mode 100644
index 0000000..fc06455
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-bsp/pcmciautils/pcmciautils_018.bb
@@ -0,0 +1,41 @@
+SUMMARY = "Linux kernel userland utilities for the PCMCIA subsystem"
+HOMEPAGE = "https://www.kernel.org/pub/linux/utils/kernel/pcmcia/"
+SECTION = "kernel/userland"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+
+DEPENDS = "udev sysfsutils flex-native bison-native"
+RDEPENDS_${PN} = "udev module-init-tools"
+
+PR = "r1"
+
+SRC_URI = "${KERNELORG_MIRROR}/linux/utils/kernel/pcmcia/${BP}.tar.xz \
+           file://makefile_fix.patch \
+           file://makefile_race.patch \
+           file://lex_sys_types.patch \
+"
+
+SRC_URI[md5sum] = "885431c3cefb76ffdad8cb985134e996"
+SRC_URI[sha256sum] = "57c27be8f04ef4d535bcfa988567316cc57659fe69068327486dab53791e6558"
+
+inherit pkgconfig
+
+export HOSTCC = "${BUILD_CC}"
+export etcdir = "${sysconfdir}"
+export sbindir = "${base_sbindir}"
+export pcmciaconfdir = "${sysconfdir}/pcmcia"
+export udevdir = "`pkg-config --variable=udevdir udev`"
+export udevrulesdir = "`pkg-config --variable=udevdir udev`/rules.d"
+export UDEV = "1"
+LD = "${CC}"
+CFLAGS =+ "-I${S}/src"
+CFLAGS =+ "-DPCMCIAUTILS_VERSION=\\"${PV}\\""
+
+EXTRA_OEMAKE = "-e 'STRIP=echo' 'LIB_OBJS=-lc -lsysfs' 'LEX=flex'"
+
+do_install () {
+	oe_runmake 'DESTDIR=${D}' install
+}
+
+CONFFILES_${PN} += "${sysconfdir}/pcmcia/config.opts"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/hostapd-CVE-2018-14526.patch b/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/hostapd-CVE-2018-14526.patch
new file mode 100644
index 0000000..522fc39
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/hostapd-CVE-2018-14526.patch
@@ -0,0 +1,44 @@
+hostapd-2.6: Fix CVE-2018-14526
+
+[No upstream tracking] -- https://w1.fi/security/2018-1/unauthenticated-eapol-key-decryption.txt
+
+wpa: Ignore unauthenticated encrypted EAPOL-Key data
+
+Ignore unauthenticated encrypted EAPOL-Key data in supplicant
+processing. When using WPA2, these are frames that have the Encrypted
+flag set, but not the MIC flag.
+
+When using WPA2, EAPOL-Key frames that had the Encrypted flag set but
+not the MIC flag, had their data field decrypted without first verifying
+the MIC. In case the data field was encrypted using RC4 (i.e., when
+negotiating TKIP as the pairwise cipher), this meant that
+unauthenticated but decrypted data would then be processed. An adversary
+could abuse this as a decryption oracle to recover sensitive information
+in the data field of EAPOL-Key messages (e.g., the group key).
+
+Upstream-Status: Backport [https://w1.fi/cgit/hostap/commit/src/rsn_supp/wpa.c?id=3e34cfdff6b192fe337c6fb3f487f73e96582961]
+CVE: CVE-2018-14526
+Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
+
+diff --git a/src/rsn_supp/wpa.c b/src/rsn_supp/wpa.c
+index 3c47879..6bdf923 100644
+--- a/src/rsn_supp/wpa.c
++++ b/src/rsn_supp/wpa.c
+@@ -2016,6 +2016,17 @@ int wpa_sm_rx_eapol(struct wpa_sm *sm, const u8 *src_addr,
+
+ 	if ((sm->proto == WPA_PROTO_RSN || sm->proto == WPA_PROTO_OSEN) &&
+ 	    (key_info & WPA_KEY_INFO_ENCR_KEY_DATA)) {
++		/*
++		 * Only decrypt the Key Data field if the frame's authenticity
++		 * was verified. When using AES-SIV (FILS), the MIC flag is not
++		 * set, so this check should only be performed if mic_len != 0
++		 * which is the case in this code branch.
++		 */
++		if (!(key_info & WPA_KEY_INFO_MIC)) {
++			wpa_msg(sm->ctx->msg_ctx, MSG_WARNING,
++				"WPA: Ignore EAPOL-Key with encrypted but unauthenticated data");
++			goto out;
++		}
+ 		if (wpa_supplicant_decrypt_key_data(sm, key, ver, key_data,
+ 						    &key_data_len))
+ 			goto out;
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd_2.6.bb b/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd_2.6.bb
index 250add8..42aae42 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd_2.6.bb
+++ b/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd_2.6.bb
@@ -18,6 +18,7 @@
     file://0005-Fix-PTK-rekeying-to-generate-a-new-ANonce.patch \
     file://0006-TDLS-Reject-TPK-TK-reconfiguration.patch \
     file://0007-FT-Do-not-allow-multiple-Reassociation-Response-fram.patch \
+    file://hostapd-CVE-2018-14526.patch \
 "
 
 SRC_URI[md5sum] = "eaa56dce9bd8f1d195eb62596eab34c7"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/krb5/krb5_1.16.1.bb b/meta-openembedded/meta-oe/recipes-connectivity/krb5/krb5_1.16.1.bb
new file mode 100644
index 0000000..11748cb
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/krb5/krb5_1.16.1.bb
@@ -0,0 +1,188 @@
+SUMMARY = "A network authentication protocol"
+DESCRIPTION = "Kerberos is a system for authenticating users and services on a network. \
+ Kerberos is a trusted third-party service.  That means that there is a \
+ third party (the Kerberos server) that is trusted by all the entities on \
+ the network (users and services, usually called "principals"). \
+ . \
+ This is the MIT reference implementation of Kerberos V5. \
+ . \
+ This package contains the Kerberos key server (KDC).  The KDC manages all \
+ authentication credentials for a Kerberos realm, holds the master keys \
+ for the realm, and responds to authentication requests.  This package \
+ should be installed on both master and slave KDCs."
+
+HOMEPAGE = "http://web.mit.edu/Kerberos/"
+SECTION = "console/network"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${S}/../NOTICE;md5=7f95bc3d8d0351aa481d56d5e9de20c3"
+DEPENDS = "bison-native ncurses util-linux e2fsprogs e2fsprogs-native openssl"
+
+inherit autotools-brokensep binconfig perlnative systemd update-rc.d
+
+SHRT_VER = "${@oe.utils.trim_version("${PV}", 2)}"
+SRC_URI = "http://web.mit.edu/kerberos/dist/${BPN}/${SHRT_VER}/${BP}.tar.gz \
+           file://0001-aclocal-Add-parameter-to-disable-keyutils-detection.patch \
+           file://debian-suppress-usr-lib-in-krb5-config.patch;striplevel=2 \
+           file://crosscompile_nm.patch \
+           file://etc/init.d/krb5-kdc \
+           file://etc/init.d/krb5-admin-server \
+           file://etc/default/krb5-kdc \
+           file://etc/default/krb5-admin-server \
+           file://krb5-kdc.service \
+           file://krb5-admin-server.service \
+"
+SRC_URI[md5sum] = "848e9b80d6aaaa798e3f3df24b83c407"
+SRC_URI[sha256sum] = "214ffe394e3ad0c730564074ec44f1da119159d94281bbec541dc29168d21117"
+
+CVE_PRODUCT = "kerberos"
+
+S = "${WORKDIR}/${BP}/src"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[libedit] = "--with-libedit,--without-libedit,libedit"
+PACKAGECONFIG[openssl] = "--with-crypto-impl=openssl,,openssl"
+PACKAGECONFIG[keyutils] = "--enable-keyutils,--disable-keyutils,keyutils"
+PACKAGECONFIG[ldap] = "--with-ldap,--without-ldap,openldap"
+PACKAGECONFIG[readline] = "--with-readline,--without-readline,readline"
+
+EXTRA_OECONF += " --without-tcl --with-system-et --disable-rpath"
+CACHED_CONFIGUREVARS += "krb5_cv_attr_constructor_destructor=yes ac_cv_func_regcomp=yes \
+                  ac_cv_printf_positional=yes ac_cv_file__etc_environment=yes \
+                  ac_cv_file__etc_TIMEZONE=no"
+
+CFLAGS_append = " -fPIC -DDESTRUCTOR_ATTR_WORKS=1 -I${STAGING_INCDIR}/et"
+CFLAGS_append_riscv64 = " -D_REENTRANT -pthread"
+LDFLAGS_append = " -pthread"
+
+do_configure() {
+    gnu-configize --force
+    autoreconf
+    oe_runconf
+}
+
+do_install_append() {
+    rm -rf ${D}/${localstatedir}/run
+    rm -f ${D}${bindir}/sclient
+    rm -f ${D}${bindir}/sim_client
+    rm -f ${D}${bindir}/uuclient
+    rm -f ${D}${sbindir}/krb5-send-pr
+    rm -f ${D}${sbindir}/sim_server
+    rm -f ${D}${sbindir}/sserver
+    rm -f ${D}${sbindir}/uuserver
+
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
+        mkdir -p ${D}/${sysconfdir}/init.d ${D}/${sysconfdir}/default
+        install -m 0755 ${WORKDIR}/etc/init.d/* ${D}/${sysconfdir}/init.d
+        install -m 0644 ${WORKDIR}/etc/default/* ${D}/${sysconfdir}/default
+
+        mkdir -p ${D}/${sysconfdir}/default/volatiles
+        echo "d root root 0755 ${localstatedir}/run/krb5kdc none" \
+              > ${D}${sysconfdir}/default/volatiles/87_krb5
+
+        echo "RUN_KADMIND=true" >> ${D}/${sysconfdir}/default/krb5-admin-server
+    fi
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+        install -d ${D}${sysconfdir}/tmpfiles.d
+        echo "d /run/krb5kdc - - - -" \
+              > ${D}${sysconfdir}/tmpfiles.d/krb5.conf
+
+        mkdir -p ${D}/${sysconfdir}/default
+        install -m 0644 ${WORKDIR}/etc/default/* ${D}/${sysconfdir}/default
+
+        install -d ${D}${systemd_system_unitdir}
+        install -m 0644 ${WORKDIR}/krb5-admin-server.service ${D}${systemd_system_unitdir}
+        install -m 0644 ${WORKDIR}/krb5-kdc.service ${D}${systemd_system_unitdir}
+    fi
+}
+
+PACKAGES =+ "${PN}-admin-server \
+             ${PN}-gss-samples \
+             ${PN}-k5tls \
+             ${PN}-kdc \
+             ${PN}-kdc-ldap \
+             ${PN}-kpropd \
+             ${PN}-otp \
+             ${PN}-pkinit \
+             ${PN}-user \
+             libgssapi-krb5 \
+             libgssrpc \
+             libk5crypto \
+             libkadm5clnt-mit \
+             libkadm5srv-mit \
+             libkdb5 \
+             libkrad \
+             libkrb5 \
+             libkrb5support \
+             libverto"
+
+FILES_${PN} = "${libdir}/krb5/plugins/preauth/test.so"
+FILES_${PN}-doc += "${datadir}/examples"
+FILES_${PN}-dbg += "${libdir}/krb5/plugins/*/.debug"
+
+FILES_${PN}-admin-server = "${sbindir}/kadmin.local \
+                            ${sbindir}/kadmind \
+                            ${sbindir}/kprop \
+                            ${sysconfdir}/default/krb5-admin-server \
+                            ${sysconfdir}/init.d/krb5-admin-server \
+                            ${systemd_system_unitdir}/krb5-admin-server.service"
+
+FILES_${PN}-gss-samples = "${bindir}/gss-client \
+                           ${sbindir}/gss-server"
+
+FILES_${PN}-k5tls = "${libdir}/krb5/plugins/tls/k5tls.so"
+
+FILES_${PN}-kdc = "${libdir}/krb5/plugins/kdb/db2.so \
+                   ${localstatedir}/krb5kdc \
+                   ${sbindir}/kdb5_util \
+                   ${sbindir}/kproplog \
+                   ${sbindir}/krb5kdc \
+                   ${sysconfdir}/default/krb5-kdc \
+                   ${sysconfdir}/default/volatiles/87_krb5 \
+                   ${sysconfdir}/init.d/krb5-kdc \
+                   ${sysconfdir}/tmpfiles.d/krb5.conf \
+                   ${systemd_system_unitdir}/krb5-kdc.service"
+
+FILES_${PN}-kdc-ldap = "${libdir}/krb5/libkdb_ldap${SOLIBS} \
+                        ${libdir}/krb5/plugins/kdb/kldap.so \
+                        ${sbindir}/kdb5_ldap_util"
+
+FILES_${PN}-kpropd = "${sbindir}/kpropd"
+FILES_${PN}-otp = "${libdir}/krb5/plugins/preauth/otp.so"
+FILES_${PN}-pkinit = "${libdir}/krb5/plugins/preauth/pkinit.so"
+FILES_${PN}-user = "${bindir}/k*"
+
+FILES_libgssapi-krb5 = "${libdir}/libgssapi_krb5${SOLIBS}"
+FILES_libgssrpc = "${libdir}/libgssrpc${SOLIBS}"
+FILES_libk5crypto = "${libdir}/libk5crypto${SOLIBS}"
+FILES_libkadm5clnt-mit = "${libdir}/libkadm5clnt_mit${SOLIBS}"
+FILES_libkadm5srv-mit = "${libdir}/libkadm5srv_mit${SOLIBS}"
+FILES_libkdb5 = "${libdir}/libkdb5${SOLIBS}"
+FILES_libkrad = "${libdir}/libkrad${SOLIBS}"
+FILES_libkrb5 = "${libdir}/libkrb5${SOLIBS} \
+                 ${libdir}/krb5/plugins/authdata \
+                 ${libdir}/krb5/plugins/libkrb5"
+FILES_libkrb5support = "${libdir}/libkrb5support${SOLIBS}"
+FILES_libverto = "${libdir}/libverto${SOLIBS}"
+
+RDEPENDS_${PN}-kadmin-server = "${PN}-kdc"
+RDEPENDS_${PN}-kpropd = "${PN}-kdc"
+
+INITSCRIPT_PACKAGES = "${PN}-admin-server ${PN}-kdc"
+INITSCRIPT_NAME_${PN}-admin-server = "krb5-admin-server"
+INITSCRIPT_NAME_${PN}-kdc = "krb5-kdc"
+
+SYSTEMD_PACKAGES = "${PN}-admin-server ${PN}-kdc"
+SYSTEMD_SERVICE_${PN}-admin-server = "krb5-admin-server.service"
+SYSTEMD_SERVICE_${PN}-kdc = "krb5-kdc.service"
+
+pkg_postinst_${PN}-kdc () {
+    if [ -z "$D" ]; then
+        if command -v systemd-tmpfiles >/dev/null; then
+            systemd-tmpfiles --create ${sysconfdir}/tmpfiles.d/krb5.conf
+        elif [ -e ${sysconfdir}/init.d/populate-volatile.sh ]; then
+            ${sysconfdir}/init.d/populate-volatile.sh update
+        fi
+    fi
+}
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/krb5/krb5_1.16.bb b/meta-openembedded/meta-oe/recipes-connectivity/krb5/krb5_1.16.bb
deleted file mode 100644
index f95240f..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/krb5/krb5_1.16.bb
+++ /dev/null
@@ -1,188 +0,0 @@
-SUMMARY = "A network authentication protocol"
-DESCRIPTION = "Kerberos is a system for authenticating users and services on a network. \
- Kerberos is a trusted third-party service.  That means that there is a \
- third party (the Kerberos server) that is trusted by all the entities on \
- the network (users and services, usually called "principals"). \
- . \
- This is the MIT reference implementation of Kerberos V5. \
- . \
- This package contains the Kerberos key server (KDC).  The KDC manages all \
- authentication credentials for a Kerberos realm, holds the master keys \
- for the realm, and responds to authentication requests.  This package \
- should be installed on both master and slave KDCs."
-
-HOMEPAGE = "http://web.mit.edu/Kerberos/"
-SECTION = "console/network"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://${S}/../NOTICE;md5=59b8da652f07186b44782a8454574f30"
-DEPENDS = "ncurses util-linux e2fsprogs e2fsprogs-native openssl"
-
-inherit autotools-brokensep binconfig perlnative systemd update-rc.d
-
-SHRT_VER = "${@oe.utils.trim_version("${PV}", 2)}"
-SRC_URI = "http://web.mit.edu/kerberos/dist/${BPN}/${SHRT_VER}/${BP}.tar.gz \
-           file://0001-aclocal-Add-parameter-to-disable-keyutils-detection.patch \
-           file://debian-suppress-usr-lib-in-krb5-config.patch;striplevel=2 \
-           file://crosscompile_nm.patch \
-           file://etc/init.d/krb5-kdc \
-           file://etc/init.d/krb5-admin-server \
-           file://etc/default/krb5-kdc \
-           file://etc/default/krb5-admin-server \
-           file://krb5-kdc.service \
-           file://krb5-admin-server.service \
-"
-SRC_URI[md5sum] = "23c5e9f07642db4a67f7a5b6168b1319"
-SRC_URI[sha256sum] = "faeb125f83b0fb4cdb2f99f088140631bb47d975982de0956d18c85842969e08"
-
-CVE_PRODUCT = "kerberos"
-
-S = "${WORKDIR}/${BP}/src"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[libedit] = "--with-libedit,--without-libedit,libedit"
-PACKAGECONFIG[openssl] = "--with-crypto-impl=openssl,,openssl"
-PACKAGECONFIG[keyutils] = "--enable-keyutils,--disable-keyutils,keyutils"
-PACKAGECONFIG[ldap] = "--with-ldap,--without-ldap,openldap"
-PACKAGECONFIG[readline] = "--with-readline,--without-readline,readline"
-
-EXTRA_OECONF += " --without-tcl --with-system-et --disable-rpath"
-CACHED_CONFIGUREVARS += "krb5_cv_attr_constructor_destructor=yes ac_cv_func_regcomp=yes \
-                  ac_cv_printf_positional=yes ac_cv_file__etc_environment=yes \
-                  ac_cv_file__etc_TIMEZONE=no"
-
-CFLAGS_append = " -fPIC -DDESTRUCTOR_ATTR_WORKS=1 -I${STAGING_INCDIR}/et"
-CFLAGS_append_riscv64 = " -D_REENTRANT -pthread"
-LDFLAGS_append = " -pthread"
-
-do_configure() {
-    gnu-configize --force
-    autoreconf
-    oe_runconf
-}
-
-do_install_append() {
-    rm -rf ${D}/${localstatedir}/run
-    rm -f ${D}${bindir}/sclient
-    rm -f ${D}${bindir}/sim_client
-    rm -f ${D}${bindir}/uuclient
-    rm -f ${D}${sbindir}/krb5-send-pr
-    rm -f ${D}${sbindir}/sim_server
-    rm -f ${D}${sbindir}/sserver
-    rm -f ${D}${sbindir}/uuserver
-
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
-        mkdir -p ${D}/${sysconfdir}/init.d ${D}/${sysconfdir}/default
-        install -m 0755 ${WORKDIR}/etc/init.d/* ${D}/${sysconfdir}/init.d
-        install -m 0644 ${WORKDIR}/etc/default/* ${D}/${sysconfdir}/default
-
-        mkdir -p ${D}/${sysconfdir}/default/volatiles
-        echo "d root root 0755 ${localstatedir}/run/krb5kdc none" \
-              > ${D}${sysconfdir}/default/volatiles/87_krb5
-
-        echo "RUN_KADMIND=true" >> ${D}/${sysconfdir}/default/krb5-admin-server
-    fi
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-        install -d ${D}${sysconfdir}/tmpfiles.d
-        echo "d /run/krb5kdc - - - -" \
-              > ${D}${sysconfdir}/tmpfiles.d/krb5.conf
-
-        mkdir -p ${D}/${sysconfdir}/default
-        install -m 0644 ${WORKDIR}/etc/default/* ${D}/${sysconfdir}/default
-
-        install -d ${D}${systemd_system_unitdir}
-        install -m 0644 ${WORKDIR}/krb5-admin-server.service ${D}${systemd_system_unitdir}
-        install -m 0644 ${WORKDIR}/krb5-kdc.service ${D}${systemd_system_unitdir}
-    fi
-}
-
-PACKAGES =+ "${PN}-admin-server \
-             ${PN}-gss-samples \
-             ${PN}-k5tls \
-             ${PN}-kdc \
-             ${PN}-kdc-ldap \
-             ${PN}-kpropd \
-             ${PN}-otp \
-             ${PN}-pkinit \
-             ${PN}-user \
-             libgssapi-krb5 \
-             libgssrpc \
-             libk5crypto \
-             libkadm5clnt-mit \
-             libkadm5srv-mit \
-             libkdb5 \
-             libkrad \
-             libkrb5 \
-             libkrb5support \
-             libverto"
-
-FILES_${PN} = "${libdir}/krb5/plugins/preauth/test.so"
-FILES_${PN}-doc += "${datadir}/examples"
-FILES_${PN}-dbg += "${libdir}/krb5/plugins/*/.debug"
-
-FILES_${PN}-admin-server = "${sbindir}/kadmin.local \
-                            ${sbindir}/kadmind \
-                            ${sbindir}/kprop \
-                            ${sysconfdir}/default/krb5-admin-server \
-                            ${sysconfdir}/init.d/krb5-admin-server \
-                            ${systemd_system_unitdir}/krb5-admin-server.service"
-
-FILES_${PN}-gss-samples = "${bindir}/gss-client \
-                           ${sbindir}/gss-server"
-
-FILES_${PN}-k5tls = "${libdir}/krb5/plugins/tls/k5tls.so"
-
-FILES_${PN}-kdc = "${libdir}/krb5/plugins/kdb/db2.so \
-                   ${localstatedir}/krb5kdc \
-                   ${sbindir}/kdb5_util \
-                   ${sbindir}/kproplog \
-                   ${sbindir}/krb5kdc \
-                   ${sysconfdir}/default/krb5-kdc \
-                   ${sysconfdir}/default/volatiles/87_krb5 \
-                   ${sysconfdir}/init.d/krb5-kdc \
-                   ${sysconfdir}/tmpfiles.d/krb5.conf \
-                   ${systemd_system_unitdir}/krb5-kdc.service"
-
-FILES_${PN}-kdc-ldap = "${libdir}/krb5/libkdb_ldap${SOLIBS} \
-                        ${libdir}/krb5/plugins/kdb/kldap.so \
-                        ${sbindir}/kdb5_ldap_util"
-
-FILES_${PN}-kpropd = "${sbindir}/kpropd"
-FILES_${PN}-otp = "${libdir}/krb5/plugins/preauth/otp.so"
-FILES_${PN}-pkinit = "${libdir}/krb5/plugins/preauth/pkinit.so"
-FILES_${PN}-user = "${bindir}/k*"
-
-FILES_libgssapi-krb5 = "${libdir}/libgssapi_krb5${SOLIBS}"
-FILES_libgssrpc = "${libdir}/libgssrpc${SOLIBS}"
-FILES_libk5crypto = "${libdir}/libk5crypto${SOLIBS}"
-FILES_libkadm5clnt-mit = "${libdir}/libkadm5clnt_mit${SOLIBS}"
-FILES_libkadm5srv-mit = "${libdir}/libkadm5srv_mit${SOLIBS}"
-FILES_libkdb5 = "${libdir}/libkdb5${SOLIBS}"
-FILES_libkrad = "${libdir}/libkrad${SOLIBS}"
-FILES_libkrb5 = "${libdir}/libkrb5${SOLIBS} \
-                 ${libdir}/krb5/plugins/authdata \
-                 ${libdir}/krb5/plugins/libkrb5"
-FILES_libkrb5support = "${libdir}/libkrb5support${SOLIBS}"
-FILES_libverto = "${libdir}/libverto${SOLIBS}"
-
-RDEPENDS_${PN}-kadmin-server = "${PN}-kdc"
-RDEPENDS_${PN}-kpropd = "${PN}-kdc"
-
-INITSCRIPT_PACKAGES = "${PN}-admin-server ${PN}-kdc"
-INITSCRIPT_NAME_${PN}-admin-server = "krb5-admin-server"
-INITSCRIPT_NAME_${PN}-kdc = "krb5-kdc"
-
-SYSTEMD_PACKAGES = "${PN}-admin-server ${PN}-kdc"
-SYSTEMD_SERVICE_${PN}-admin-server = "krb5-admin-server.service"
-SYSTEMD_SERVICE_${PN}-kdc = "krb5-kdc.service"
-
-pkg_postinst_${PN}-kdc () {
-    if [ -z "$D" ]; then
-        if command -v systemd-tmpfiles >/dev/null; then
-            systemd-tmpfiles --create ${sysconfdir}/tmpfiles.d/krb5.conf
-        elif [ -e ${sysconfdir}/init.d/populate-volatile.sh ]; then
-            ${sysconfdir}/init.d/populate-volatile.sh update
-        fi
-    fi
-}
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libev/libev_4.24.bb b/meta-openembedded/meta-oe/recipes-connectivity/libev/libev_4.24.bb
index 5e0f3a5..a5838d3 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/libev/libev_4.24.bb
+++ b/meta-openembedded/meta-oe/recipes-connectivity/libev/libev_4.24.bb
@@ -9,8 +9,6 @@
 SRC_URI[md5sum] = "94459a5a22db041dec6f98424d6efe54"
 SRC_URI[sha256sum] = "973593d3479abdf657674a55afe5f78624b0e440614e2b8cb3a07f16d4d7f821"
 
-S = "${WORKDIR}/${PN}-${PV}"
-
 inherit autotools
 
 EXTRA_OECONF += "--with-pic"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libimobiledevice/files/inline-without-definition.patch b/meta-openembedded/meta-oe/recipes-connectivity/libimobiledevice/files/inline-without-definition.patch
deleted file mode 100644
index 9a7895f..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/libimobiledevice/files/inline-without-definition.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-Fix link error with gcc 5 toolchains
-
- afc.c:258: error: undefined reference to 'debug_buffer'
- collect2: error: ld returned 1 exit status
-
-debug.h header was declaring things inline without providing a definition.
-Files that included this header then failed to link against the corresponding
-external symbol in debug.c, because the linker took the 'inline' keyword
-seriously rather than ignoring it.
-
---- libimobiledevice-1.1.4/src/debug.h.orig	2015-10-03 16:24:08.758740386 -0700
-+++ libimobiledevice-1.1.4/src/debug.h	2015-10-03 16:24:22.706740355 -0700
-@@ -44,14 +44,14 @@
- #define debug_plist(a)
- #endif
- 
--LIBIMOBILEDEVICE_INTERNAL inline void debug_info_real(const char *func,
-+LIBIMOBILEDEVICE_INTERNAL void debug_info_real(const char *func,
- 											const char *file,
- 											int	line,
- 											const char *format, ...);
- 
--LIBIMOBILEDEVICE_INTERNAL inline void debug_buffer(const char *data, const int length);
--LIBIMOBILEDEVICE_INTERNAL inline void debug_buffer_to_file(const char *file, const char *data, const int length);
--LIBIMOBILEDEVICE_INTERNAL inline void debug_plist_real(const char *func,
-+LIBIMOBILEDEVICE_INTERNAL void debug_buffer(const char *data, const int length);
-+LIBIMOBILEDEVICE_INTERNAL void debug_buffer_to_file(const char *file, const char *data, const int length);
-+LIBIMOBILEDEVICE_INTERNAL void debug_plist_real(const char *func,
- 											const char *file,
- 											int	line,
- 											plist_t plist);
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libimobiledevice/libimobiledevice_1.1.4.bb b/meta-openembedded/meta-oe/recipes-connectivity/libimobiledevice/libimobiledevice_1.1.4.bb
deleted file mode 100644
index 32aca96..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/libimobiledevice/libimobiledevice_1.1.4.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-SUMMARY = "A protocol library to access an iPhone or iPod Touch in Linux"
-LICENSE = "GPLv2 & LGPLv2.1"
-LIC_FILES_CHKSUM = "\
-    file://COPYING;md5=ebb5c50ab7cab4baeffba14977030c07 \
-    file://COPYING.LESSER;md5=6ab17b41640564434dda85c06b7124f7 \
-"
-
-HOMEPAGE ="http://www.libimobiledevice.org/"
-
-DEPENDS = "libplist usbmuxd libtasn1 gnutls libgcrypt"
-
-SRC_URI = " \
-    http://www.libimobiledevice.org/downloads/libimobiledevice-${PV}.tar.bz2 \
-    file://configure-fix-largefile.patch \
-    file://inline-without-definition.patch \
-"
-
-SRC_URI[md5sum] = "3f28cbc6a2e30d34685049c0abde5183"
-SRC_URI[sha256sum] = "67499cfaa6172f566ee6b0783605acffe484fb7ddc3b09881ab7ac58667ee5b8"
-
-inherit autotools pkgconfig
-
-EXTRA_OECONF = " --without-cython "
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libimobiledevice/libimobiledevice_git.bb b/meta-openembedded/meta-oe/recipes-connectivity/libimobiledevice/libimobiledevice_git.bb
new file mode 100644
index 0000000..908b98d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/libimobiledevice/libimobiledevice_git.bb
@@ -0,0 +1,22 @@
+SUMMARY = "A protocol library to access an iPhone or iPod Touch in Linux"
+LICENSE = "GPLv2 & LGPLv2.1"
+LIC_FILES_CHKSUM = "\
+    file://COPYING;md5=ebb5c50ab7cab4baeffba14977030c07 \
+    file://COPYING.LESSER;md5=6ab17b41640564434dda85c06b7124f7 \
+"
+
+HOMEPAGE ="http://www.libimobiledevice.org/"
+
+DEPENDS = "libplist usbmuxd libusbmuxd libtasn1 gnutls libgcrypt"
+
+SRCREV = "fb71aeef10488ed7b0e60a1c8a553193301428c0"
+PV = "1.2.0+git${SRCPV}"
+SRC_URI = "\
+    git://github.com/libimobiledevice/libimobiledevice;protocol=https \
+    file://configure-fix-largefile.patch \
+"
+
+S = "${WORKDIR}/git"
+inherit autotools pkgconfig
+
+EXTRA_OECONF = " --without-cython "
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libmbim/libmbim_1.14.0.bb b/meta-openembedded/meta-oe/recipes-connectivity/libmbim/libmbim_1.14.0.bb
deleted file mode 100644
index f89ef9d..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/libmbim/libmbim_1.14.0.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-SUMMARY = "libmbim is library for talking to WWAN devices by MBIM protocol"
-DESCRIPTION = "libmbim is a glib-based library for talking to WWAN modems and devices which speak the Mobile Interface Broadband Model (MBIM) protocol"
-HOMEPAGE = "http://www.freedesktop.org/wiki/Software/libmbim/"
-LICENSE = "GPLv2 & LGPLv2.1"
-LIC_FILES_CHKSUM = " \
-    file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-    file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c \
-"
-
-DEPENDS = "glib-2.0 glib-2.0-native libgudev"
-
-inherit autotools pkgconfig bash-completion
-
-SRC_URI = "http://www.freedesktop.org/software/${BPN}/${BPN}-${PV}.tar.xz \
-           file://clang.patch \
-"
-SRC_URI[md5sum] = "2ed809e65c85353d3ab59e372890e549"
-SRC_URI[sha256sum] = "ca8d52a95a18cbabae8f15f83f1572316e888b6504f946e6645d24405127ab5b"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libmbim/libmbim_1.16.0.bb b/meta-openembedded/meta-oe/recipes-connectivity/libmbim/libmbim_1.16.0.bb
new file mode 100644
index 0000000..5260c0f
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/libmbim/libmbim_1.16.0.bb
@@ -0,0 +1,18 @@
+SUMMARY = "libmbim is library for talking to WWAN devices by MBIM protocol"
+DESCRIPTION = "libmbim is a glib-based library for talking to WWAN modems and devices which speak the Mobile Interface Broadband Model (MBIM) protocol"
+HOMEPAGE = "http://www.freedesktop.org/wiki/Software/libmbim/"
+LICENSE = "GPLv2 & LGPLv2.1"
+LIC_FILES_CHKSUM = " \
+    file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+    file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c \
+"
+
+DEPENDS = "glib-2.0 glib-2.0-native libgudev"
+
+inherit autotools pkgconfig bash-completion
+
+SRC_URI = "http://www.freedesktop.org/software/${BPN}/${BPN}-${PV}.tar.xz \
+           file://clang.patch \
+"
+SRC_URI[md5sum] = "76ea4d8381989919b1d9b91c818fed80"
+SRC_URI[sha256sum] = "c8ca50beeddd4b43309df5b698917268303bf176cea58fe4fe53d5bf0e93fac2"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libndp/libndp/0001-include-sys-select.h-for-fd_-definitions.patch b/meta-openembedded/meta-oe/recipes-connectivity/libndp/libndp/0001-include-sys-select.h-for-fd_-definitions.patch
deleted file mode 100644
index 15aa94e..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/libndp/libndp/0001-include-sys-select.h-for-fd_-definitions.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 94e9a082d76414f82794b0c9817d0c24e3868275 Mon Sep 17 00:00:00 2001
-From: Kylie McClain <somasis@exherbo.org>
-Date: Sat, 21 May 2016 21:24:36 -0400
-Subject: [PATCH] ndptool: Fix compilation on musl libc
-
-FD_ZERO, fd_set, etc are defined within sys/select.h on musl.
-
-Signed-off-by: Kylie McClain <somasis@exherbo.org>
-Signed-off-by: Jiri Pirko <jiri@mellanox.com>
----
- utils/ndptool.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/utils/ndptool.c b/utils/ndptool.c
-index 1d96f4c..96479fa 100644
---- a/utils/ndptool.c
-+++ b/utils/ndptool.c
-@@ -28,6 +28,7 @@
- #include <arpa/inet.h>
- #include <errno.h>
- #include <ndp.h>
-+#include <sys/select.h>
- 
- enum verbosity_level {
- 	VERB1,
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libndp/libndp_1.6.bb b/meta-openembedded/meta-oe/recipes-connectivity/libndp/libndp_1.6.bb
deleted file mode 100644
index 5148798..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/libndp/libndp_1.6.bb
+++ /dev/null
@@ -1,13 +0,0 @@
-SUMMARY = "Library for IPv6 Neighbor Discovery Protocol"
-HOMEPAGE = "http://libndp.org/"
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
-
-SRC_URI = "git://github.com/jpirko/libndp \
-           file://0001-include-sys-select.h-for-fd_-definitions.patch \
-           "
-# tag for v1.6
-SRCREV = "2f721c4ff519f38f46695a60d9f9d88f35bf3c1d"
-S = "${WORKDIR}/git"
-
-inherit autotools
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libndp/libndp_1.7.bb b/meta-openembedded/meta-oe/recipes-connectivity/libndp/libndp_1.7.bb
new file mode 100644
index 0000000..07a7a1d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/libndp/libndp_1.7.bb
@@ -0,0 +1,12 @@
+SUMMARY = "Library for IPv6 Neighbor Discovery Protocol"
+HOMEPAGE = "http://libndp.org/"
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
+
+SRC_URI = "git://github.com/jpirko/libndp \
+           "
+# tag for v1.6
+SRCREV = "96674e7d4f4d569c2c961e865cc16152dfab5f09"
+S = "${WORKDIR}/git"
+
+inherit autotools
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libnet/libnet_1.2-rc3.bb b/meta-openembedded/meta-oe/recipes-connectivity/libnet/libnet_1.2-rc3.bb
index dfc2049..c991344 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/libnet/libnet_1.2-rc3.bb
+++ b/meta-openembedded/meta-oe/recipes-connectivity/libnet/libnet_1.2-rc3.bb
@@ -15,6 +15,9 @@
 SRC_URI[md5sum] = "f051e6e5bdecddb90f77c701c2ca1804"
 SRC_URI[sha256sum] = "72c380785ad44183005e654b47cc12485ee0228d7fa6b0a87109ff7614be4a63"
 
+UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/libnet-dev/files/"
+UPSTREAM_CHECK_REGEX = "libnet-(?P<pver>\d+(\.\d+)+-*[a-z]*\d*)\.tar"
+
 S = "${WORKDIR}/${BPN}-${PV}"
 
 inherit autotools binconfig
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi/0001-qmi-network-Don-t-create-invalid-wds-start-network-w.patch b/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi/0001-qmi-network-Don-t-create-invalid-wds-start-network-w.patch
new file mode 100644
index 0000000..d230d68
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi/0001-qmi-network-Don-t-create-invalid-wds-start-network-w.patch
@@ -0,0 +1,41 @@
+From 8269f4d86927fbe19e78776a12736680fe9169b6 Mon Sep 17 00:00:00 2001
+From: Adrian Bunk <bunk@stusta.de>
+Date: Mon, 1 Oct 2018 16:53:31 +0300
+Subject: [PATCH] qmi-network: Don't create invalid --wds-start-network when
+ APN is not set
+
+In 1.20.2 the warning for this was turned into an error.
+
+(cherry picked from commit 289d8ad6419895e2e1fba3d78a54a0db65da521d)
+---
+Upstream-Status: Backport
+
+ utils/qmi-network.in | 12 +++++++-----
+ 1 file changed, 7 insertions(+), 5 deletions(-)
+
+diff --git a/utils/qmi-network.in b/utils/qmi-network.in
+index bf7bed9..a9e5299 100755
+--- a/utils/qmi-network.in
++++ b/utils/qmi-network.in
+@@ -334,11 +334,13 @@ start_network ()
+ 
+     setup_data_format
+ 
+-    START_NETWORK_ARGS="apn='$APN'"
+-    if [ -n "$APN_USER" ]; then
+-        START_NETWORK_ARGS="${START_NETWORK_ARGS},username='$APN_USER'"
+-        if [ -n "$APN_PASS" ]; then
+-            START_NETWORK_ARGS="${START_NETWORK_ARGS},password='$APN_PASS'"
++    if [ -n "$APN" ]; then
++        START_NETWORK_ARGS="apn='$APN'"
++        if [ -n "$APN_USER" ]; then
++            START_NETWORK_ARGS="${START_NETWORK_ARGS},username='$APN_USER'"
++            if [ -n "$APN_PASS" ]; then
++                START_NETWORK_ARGS="${START_NETWORK_ARGS},password='$APN_PASS'"
++            fi
+         fi
+     fi
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi_1.20.0.bb b/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi_1.20.0.bb
deleted file mode 100644
index 9301cbd..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi_1.20.0.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-SUMMARY = "libqmi is a library for talking to WWAN devices by QMI protocol"
-DESCRIPTION = "libqmi is a glib-based library for talking to WWAN modems and devices which speak the Qualcomm MSM Interface (QMI) protocol"
-HOMEPAGE = "http://www.freedesktop.org/wiki/Software/libqmi"
-LICENSE = "GPLv2 & LGPLv2.1"
-LIC_FILES_CHKSUM = " \
-    file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-    file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c \
-"
-
-DEPENDS = "glib-2.0 libgudev libmbim glib-2.0-native"
-
-inherit autotools pkgconfig bash-completion
-
-SRC_URI = "http://www.freedesktop.org/software/${BPN}/${BPN}-${PV}.tar.xz \
-           file://0001-Detect-clang.patch \
-           "
-SRC_URI[md5sum] = "797e365521df76b77b067e6317618b41"
-SRC_URI[sha256sum] = "21428cd3749c56246565123f707fee51238651a22c60bdc85ebce97388626eb4"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi_1.20.2.bb b/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi_1.20.2.bb
new file mode 100644
index 0000000..f0bc81c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi_1.20.2.bb
@@ -0,0 +1,23 @@
+SUMMARY = "libqmi is a library for talking to WWAN devices by QMI protocol"
+DESCRIPTION = "libqmi is a glib-based library for talking to WWAN modems and devices which speak the Qualcomm MSM Interface (QMI) protocol"
+HOMEPAGE = "http://www.freedesktop.org/wiki/Software/libqmi"
+LICENSE = "GPLv2 & LGPLv2.1"
+LIC_FILES_CHKSUM = " \
+    file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+    file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c \
+"
+
+DEPENDS = "glib-2.0 glib-2.0-native"
+
+inherit autotools pkgconfig bash-completion
+
+SRC_URI = "http://www.freedesktop.org/software/${BPN}/${BPN}-${PV}.tar.xz \
+           file://0001-qmi-network-Don-t-create-invalid-wds-start-network-w.patch \
+           file://0001-Detect-clang.patch \
+           "
+SRC_URI[md5sum] = "584214476ab75c394160cb85fbccaa1d"
+SRC_URI[sha256sum] = "c73459ca8bfe1213f8047858d4946fc1f58e164d4f488a7a6904edee25e2ca44"
+
+PACKAGECONFIG ??= "udev mbim"
+PACKAGECONFIG[udev] = ",--without-udev,libgudev"
+PACKAGECONFIG[mbim] = "--enable-mbim-qmux,--disable-mbim-qmux,libmbim"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent/don-t-run-code-while-configuring-package.patch b/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent/don-t-run-code-while-configuring-package.patch
index 79d4f29..8d8867a 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent/don-t-run-code-while-configuring-package.patch
+++ b/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent/don-t-run-code-while-configuring-package.patch
@@ -4,91 +4,25 @@
 Upstream-Status: Pending
 Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
 
-Index: libtorrent-0.13.3/scripts/checks.m4
+Index: git/scripts/common.m4
 ===================================================================
---- libtorrent-0.13.3.orig/scripts/checks.m4	2012-05-14 14:17:04.000000000 +0300
-+++ libtorrent-0.13.3/scripts/checks.m4	2013-02-10 15:28:37.414445524 +0200
-@@ -95,40 +95,6 @@
-
- AC_DEFUN([TORRENT_CHECK_KQUEUE_SOCKET_ONLY], [
-   AC_MSG_CHECKING(whether kqueue supports pipes and ptys)
--
--  AC_RUN_IFELSE([AC_LANG_SOURCE([
--      #include <fcntl.h>
--      #include <stdlib.h>
--      #include <unistd.h>
--      #include <sys/event.h>
--      #include <sys/time.h>
--      int main() {
--        struct kevent ev@<:@2@:>@, ev_out@<:@2@:>@;
--        struct timespec ts = { 0, 0 };
--        int pfd@<:@2@:>@, pty@<:@2@:>@, kfd, n;
--        char buffer@<:@9001@:>@;
--        if (pipe(pfd) == -1) return 1;
--        if (fcntl(pfd@<:@1@:>@, F_SETFL, O_NONBLOCK) == -1) return 2;
--        while ((n = write(pfd@<:@1@:>@, buffer, sizeof(buffer))) == sizeof(buffer));
--        if ((pty@<:@0@:>@=posix_openpt(O_RDWR | O_NOCTTY)) == -1) return 3;
--        if ((pty@<:@1@:>@=grantpt(pty@<:@0@:>@)) == -1) return 4;
--        EV_SET(ev+0, pfd@<:@1@:>@, EVFILT_WRITE, EV_ADD | EV_ENABLE, 0, 0, NULL);
--        EV_SET(ev+1, pty@<:@1@:>@, EVFILT_READ, EV_ADD | EV_ENABLE, 0, 0, NULL);
--        if ((kfd = kqueue()) == -1) return 5;
--        if ((n = kevent(kfd, ev, 2, NULL, 0, NULL)) == -1) return 6;
--        if (ev_out@<:@0@:>@.flags & EV_ERROR) return 7;
--        if (ev_out@<:@1@:>@.flags & EV_ERROR) return 8;
--        read(pfd@<:@0@:>@, buffer, sizeof(buffer));
--        if ((n = kevent(kfd, NULL, 0, ev_out, 2, &ts)) < 1) return 9;
--        return 0;
--      }
--      ])],
--    [
--      AC_MSG_RESULT(yes)
--    ], [
--      AC_DEFINE(KQUEUE_SOCKET_ONLY, 1, kqueue only supports sockets.)
--      AC_MSG_RESULT(no)
--    ])
- ])
-
- AC_DEFUN([TORRENT_WITH_KQUEUE], [
-Index: libtorrent-0.13.3/scripts/common.m4
-===================================================================
---- libtorrent-0.13.3.orig/scripts/common.m4	2012-05-14 14:17:04.000000000 +0300
-+++ libtorrent-0.13.3/scripts/common.m4	2013-02-10 15:27:55.874446741 +0200
-@@ -222,38 +222,10 @@
-
+--- git.orig/scripts/common.m4
++++ git/scripts/common.m4
+@@ -153,7 +153,7 @@ dnl   Need to fix this so that it uses t
  AC_DEFUN([TORRENT_CHECK_EXECINFO], [
    AC_MSG_CHECKING(for execinfo.h)
--
--  AC_RUN_IFELSE([AC_LANG_SOURCE([
--      #include <execinfo.h>
--      int main() { backtrace((void**)0, 0); backtrace_symbols((char**)0, 0); return 0;}
--      ])],
--    [
--      AC_MSG_RESULT(yes)
--      AC_DEFINE(USE_EXECINFO, 1, Use execinfo.h)
--    ], [
--      AC_MSG_RESULT(no)
--  ])
- ])
-
+ 
+-  AC_COMPILE_IFELSE([AC_LANG_SOURCE([
++  AC_LINK_IFELSE([AC_LANG_SOURCE([
+       #include <execinfo.h>
+       int main() { backtrace((void**)0, 0); backtrace_symbols((char**)0, 0); return 0;}
+       ])],
+@@ -168,7 +168,7 @@ AC_DEFUN([TORRENT_CHECK_EXECINFO], [
  AC_DEFUN([TORRENT_CHECK_ALIGNED], [
    AC_MSG_CHECKING(the byte alignment)
--
+ 
 -  AC_RUN_IFELSE([AC_LANG_SOURCE([
--      #include <inttypes.h>
--      int main() {
--        char buf@<:@8@:>@ = { 0, 0, 0, 0, 1, 0, 0, 0 };
--	int i;
--        for (i = 1; i < 4; ++i)
--	  if (*(uint32_t*)(buf + i) == 0) return -1;
--	return 0;
--	}
--      ])],
--    [
--      AC_MSG_RESULT(none needed)
--    ], [
--      AC_DEFINE(USE_ALIGNED, 1, Require byte alignment)
--      AC_MSG_RESULT(required)
--  ])
- ])
-
-
++  AC_LINK_IFELSE([AC_LANG_SOURCE([
+       #include <inttypes.h>
+       int main() {
+         char buf@<:@8@:>@ = { 0, 0, 0, 0, 1, 0, 0, 0 };
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent_git.bb b/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent_git.bb
index 92e6528..b2dffcd 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent_git.bb
+++ b/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent_git.bb
@@ -11,9 +11,9 @@
            file://0001-implement-64bit-atomic-for-mips.patch \
            file://0001-Define-64bit-atomic-helpers-for-ppc-32-bit.patch \
            "
-SRCREV = "c167c5a9e0bcf0df23ae5efd91396aae0e37eb87"
+SRCREV = "074f6ec51a2e4bc5c6140b4dad13c9bb56f3f0dc"
 
-PV = "0.13.6+git${SRCPV}"
+PV = "0.13.7+git${SRCPV}"
 
 S = "${WORKDIR}/git"
 
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libuv/libuv_1.11.0.bb b/meta-openembedded/meta-oe/recipes-connectivity/libuv/libuv_1.11.0.bb
deleted file mode 100644
index ca4685a..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/libuv/libuv_1.11.0.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-SUMMARY = "A multi-platform support library with a focus on asynchronous I/O"
-HOMEPAGE = "https://github.com/libuv/libuv"
-BUGTRACKER = "https://github.com/libuv/libuv/issues"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=bb5ea0d651f4c3519327171906045775"
-
-S = "${WORKDIR}/git"
-SRCREV = "7452ef4e06a4f99ee26b694c65476401534f2725"
-BRANCH = "v1.x"
-SRC_URI = "git://github.com/libuv/libuv.git;protocol=https;branch=${BRANCH};"
-
-inherit autotools
-
-do_configure() {
-    ${S}/autogen.sh || bbnote "${PN} failed to autogen.sh"
-    oe_runconf
-}
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libuv/libuv_1.20.3.bb b/meta-openembedded/meta-oe/recipes-connectivity/libuv/libuv_1.20.3.bb
new file mode 100644
index 0000000..a11ff9d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/libuv/libuv_1.20.3.bb
@@ -0,0 +1,19 @@
+SUMMARY = "A multi-platform support library with a focus on asynchronous I/O"
+HOMEPAGE = "https://github.com/libuv/libuv"
+BUGTRACKER = "https://github.com/libuv/libuv/issues"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=a68902a430e32200263d182d44924d47"
+
+S = "${WORKDIR}/git"
+SRCREV = "8cfd67e59195251dff793ee47c185c9d6a8f3818"
+BRANCH = "v1.x"
+SRC_URI = "git://github.com/libuv/libuv.git;protocol=https;branch=${BRANCH};"
+
+inherit autotools
+
+do_configure() {
+    ${S}/autogen.sh || bbnote "${PN} failed to autogen.sh"
+    oe_runconf
+}
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libwebsockets/libwebsockets_2.1.0.bb b/meta-openembedded/meta-oe/recipes-connectivity/libwebsockets/libwebsockets_2.1.0.bb
deleted file mode 100644
index 100f3a3..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/libwebsockets/libwebsockets_2.1.0.bb
+++ /dev/null
@@ -1,27 +0,0 @@
-SUMMARY = "Canonical libwebsockets.org websocket library"
-HOMEPAGE = "https://libwebsockets.org/"
-LICENSE = "LGPL-2.1"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=e3393a657830d4a118c5a6ed35ba53d0"
-
-DEPENDS = "zlib"
-
-S = "${WORKDIR}/git"
-SRCREV = "73557509bd15f95a1ad081a6f4fab48ff7743215"
-SRC_URI = "git://github.com/warmcat/libwebsockets.git;protocol=https;"
-
-inherit cmake pkgconfig
-
-PACKAGECONFIG ?= "libuv client server http2 ssl"
-PACKAGECONFIG[client] = "-DLWS_WITHOUT_CLIENT=OFF,-DLWS_WITHOUT_CLIENT=ON,"
-PACKAGECONFIG[http2] = "-DLWS_WITH_HTTP2=ON,-DLWS_WITH_HTTP2=OFF,"
-PACKAGECONFIG[ipv6] = "-DLWS_IPV6=ON,-DLWS_IPV6=OFF,"
-PACKAGECONFIG[libev] = "-DLWS_WITH_LIBEV=ON,-DLWS_WITH_LIBEV=OFF,libev"
-PACKAGECONFIG[libuv] = "-DLWS_WITH_LIBUV=ON,-DLWS_WITH_LIBUV=OFF,libuv"
-PACKAGECONFIG[server] = "-DLWS_WITHOUT_SERVER=OFF,-DLWS_WITHOUT_SERVER=ON,"
-PACKAGECONFIG[ssl] = "-DLWS_WITH_SSL=ON,-DLWS_WITH_SSL=OFF,openssl"
-PACKAGECONFIG[testapps] = "-DLWS_WITHOUT_TESTAPPS=OFF,-DLWS_WITHOUT_TESTAPPS=ON,"
-
-PACKAGES =+ "${PN}-testapps"
-
-FILES_${PN}-dev += "${libdir}/cmake"
-FILES_${PN}-testapps += "${datadir}/libwebsockets-test-server/*"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/libwebsockets/libwebsockets_3.0.0.bb b/meta-openembedded/meta-oe/recipes-connectivity/libwebsockets/libwebsockets_3.0.0.bb
new file mode 100644
index 0000000..f384148
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/libwebsockets/libwebsockets_3.0.0.bb
@@ -0,0 +1,26 @@
+SUMMARY = "Canonical libwebsockets.org websocket library"
+HOMEPAGE = "https://libwebsockets.org/"
+LICENSE = "LGPL-2.1"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=4ce87f3facb6f911c142c8bef9bfb380"
+
+DEPENDS = "zlib"
+
+S = "${WORKDIR}/git"
+SRCREV = "eaa935a80adb38b5cc4d09ce06ec987b87dcddfa"
+SRC_URI = "git://github.com/warmcat/libwebsockets.git;protocol=https;"
+
+inherit cmake pkgconfig
+
+PACKAGECONFIG ?= "libuv client server http2 ssl"
+PACKAGECONFIG[client] = "-DLWS_WITHOUT_CLIENT=OFF,-DLWS_WITHOUT_CLIENT=ON,"
+PACKAGECONFIG[http2] = "-DLWS_WITH_HTTP2=ON,-DLWS_WITH_HTTP2=OFF,"
+PACKAGECONFIG[ipv6] = "-DLWS_IPV6=ON,-DLWS_IPV6=OFF,"
+PACKAGECONFIG[libev] = "-DLWS_WITH_LIBEV=ON,-DLWS_WITH_LIBEV=OFF,libev"
+PACKAGECONFIG[libuv] = "-DLWS_WITH_LIBUV=ON,-DLWS_WITH_LIBUV=OFF,libuv"
+PACKAGECONFIG[server] = "-DLWS_WITHOUT_SERVER=OFF,-DLWS_WITHOUT_SERVER=ON,"
+PACKAGECONFIG[ssl] = "-DLWS_WITH_SSL=ON,-DLWS_WITH_SSL=OFF,openssl"
+PACKAGECONFIG[testapps] = "-DLWS_WITHOUT_TESTAPPS=OFF,-DLWS_WITHOUT_TESTAPPS=ON,"
+
+PACKAGES =+ "${PN}-testapps"
+
+FILES_${PN}-testapps += "${datadir}/libwebsockets-test-server/*"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager/enum-conversion.patch b/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager/enum-conversion.patch
deleted file mode 100644
index a3fb0f3..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager/enum-conversion.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-Fixes errors found bt Clang
-
-| ../../ModemManager-1.6.4/src/mm-bearer-qmi.c:774:50: error: implicit conversion from enumeration type 'MMBearerStatus' to different enumeration type 'MMBearerConnectionStatus' [-Werror,-Wenum-conversion]
-|         MMBearerConnectionStatus bearer_status = mm_base_bearer_get_status (MM_BASE_BEARER (self));
-|                                  ~~~~~~~~~~~~~   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-| 1 error generated.
-
-
-Index: ModemManager-1.6.4/src/mm-bearer-qmi.c
-===================================================================
---- ModemManager-1.6.4.orig/src/mm-bearer-qmi.c
-+++ ModemManager-1.6.4/src/mm-bearer-qmi.c
-@@ -771,7 +771,7 @@ packet_service_status_indication_cb (Qmi
-             &connection_status,
-             NULL,
-             NULL)) {
--        MMBearerConnectionStatus bearer_status = mm_base_bearer_get_status (MM_BASE_BEARER (self));
-+        MMBearerConnectionStatus bearer_status = (MMBearerConnectionStatus)mm_base_bearer_get_status (MM_BASE_BEARER (self));
- 
-         if (connection_status == QMI_WDS_CONNECTION_STATUS_DISCONNECTED &&
-             bearer_status != MM_BEARER_CONNECTION_STATUS_DISCONNECTED &&
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager_1.6.4.bb b/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager_1.6.4.bb
deleted file mode 100644
index e60cd4b..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager_1.6.4.bb
+++ /dev/null
@@ -1,51 +0,0 @@
-SUMMARY = "ModemManager is a daemon controlling broadband devices/connections"
-DESCRIPTION = "ModemManager is a DBus-activated daemon which controls mobile broadband (2G/3G/4G) devices and connections"
-HOMEPAGE = "http://www.freedesktop.org/wiki/Software/ModemManager/"
-LICENSE = "GPL-2.0 & LGPL-2.1"
-LIC_FILES_CHKSUM = " \
-    file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-    file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c \
-"
-
-inherit gnomebase gettext systemd vala gobject-introspection bash-completion
-
-DEPENDS = "glib-2.0 libgudev dbus-glib intltool-native"
-
-SRC_URI = "http://www.freedesktop.org/software/ModemManager/ModemManager-${PV}.tar.xz \
-           file://enum-conversion.patch \
-"
-SRC_URI[md5sum] = "06488186c7dd53f8104183b86f7a1568"
-SRC_URI[sha256sum] = "cdd5b4cb1e4d7643643a28ccbfc4bb354bfa9cb89a77ea160ebdf7926171c668"
-
-S = "${WORKDIR}/ModemManager-${PV}"
-
-PACKAGECONFIG ??= "mbim qmi polkit \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} \
-"
-
-PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/,,"
-PACKAGECONFIG[polkit] = "--with-polkit=yes,--with-polkit=no,polkit"
-# Support WWAN modems and devices which speak the Mobile Interface Broadband Model (MBIM) protocol.
-PACKAGECONFIG[mbim] = "--with-mbim,--enable-mbim=no,libmbim"
-# Support WWAN modems and devices which speak the Qualcomm MSM Interface (QMI) protocol.
-PACKAGECONFIG[qmi] = "--with-qmi,--without-qmi,libqmi"
-
-FILES_${PN} += " \
-    ${datadir}/icons \
-    ${datadir}/polkit-1 \
-    ${datadir}/dbus-1 \
-    ${libdir}/ModemManager \
-    ${systemd_unitdir}/system \
-"
-
-FILES_${PN}-dev += " \
-    ${libdir}/ModemManager/*.la \
-"
-
-FILES_${PN}-staticdev += " \
-    ${libdir}/ModemManager/*.a \
-"
-
-FILES_${PN}-dbg += "${libdir}/ModemManager/.debug"
-
-SYSTEMD_SERVICE_${PN} = "ModemManager.service"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager_1.8.2.bb b/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager_1.8.2.bb
new file mode 100644
index 0000000..dec4b67
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager_1.8.2.bb
@@ -0,0 +1,55 @@
+SUMMARY = "ModemManager is a daemon controlling broadband devices/connections"
+DESCRIPTION = "ModemManager is a DBus-activated daemon which controls mobile broadband (2G/3G/4G) devices and connections"
+HOMEPAGE = "http://www.freedesktop.org/wiki/Software/ModemManager/"
+LICENSE = "GPL-2.0 & LGPL-2.1"
+LIC_FILES_CHKSUM = " \
+    file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+    file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c \
+"
+
+inherit gnomebase gettext systemd vala gobject-introspection bash-completion
+
+DEPENDS = "glib-2.0 libgudev dbus-glib intltool-native"
+
+SRC_URI = "http://www.freedesktop.org/software/ModemManager/ModemManager-${PV}.tar.xz \
+           "
+
+SRC_URI[md5sum] = "a49c9f73e46c7b89e5efedda250d22c0"
+SRC_URI[sha256sum] = "96f2a5f0ed15532b4c4c185b756fdc0326e7c2027cea26a1264f91e098260f80"
+
+S = "${WORKDIR}/ModemManager-${PV}"
+
+PACKAGECONFIG ??= "mbim qmi polkit \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} \
+"
+
+PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/,,"
+PACKAGECONFIG[polkit] = "--with-polkit=yes,--with-polkit=no,polkit"
+# Support WWAN modems and devices which speak the Mobile Interface Broadband Model (MBIM) protocol.
+PACKAGECONFIG[mbim] = "--with-mbim,--with-mbim=no,libmbim"
+# Support WWAN modems and devices which speak the Qualcomm MSM Interface (QMI) protocol.
+PACKAGECONFIG[qmi] = "--with-qmi,--without-qmi,libqmi"
+
+EXTRA_OECONF = " \
+    --with-udev-base-dir=${nonarch_base_libdir}/udev \
+"
+
+FILES_${PN} += " \
+    ${datadir}/icons \
+    ${datadir}/polkit-1 \
+    ${datadir}/dbus-1 \
+    ${libdir}/ModemManager \
+    ${systemd_unitdir}/system \
+"
+
+FILES_${PN}-dev += " \
+    ${libdir}/ModemManager/*.la \
+"
+
+FILES_${PN}-staticdev += " \
+    ${libdir}/ModemManager/*.a \
+"
+
+FILES_${PN}-dbg += "${libdir}/ModemManager/.debug"
+
+SYSTEMD_SERVICE_${PN} = "ModemManager.service"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/mosquitto/files/0001-config.mk-allow-prefix-mandir-localedir-from-environ.patch b/meta-openembedded/meta-oe/recipes-connectivity/mosquitto/files/0001-config.mk-allow-prefix-mandir-localedir-from-environ.patch
deleted file mode 100644
index a5aa277..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/mosquitto/files/0001-config.mk-allow-prefix-mandir-localedir-from-environ.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From 0be38301249d797ec1f59071cc868ceda6d4720a Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Andr=C3=A9=20Draszik?= <andre.draszik@jci.com>
-Date: Tue, 12 Apr 2016 12:50:32 +0100
-Subject: [PATCH 1/2] config.mk: allow prefix / mandir / localedir from
- environment
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-We want to control them using OE environment variables.
-
-Upstream-Status: Inappropriate [embedded-specific]
-Signed-off-by: André Draszik <andre.draszik@jci.com>
----
- config.mk | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/config.mk b/config.mk
-index 71f17e5..81d9702 100644
---- a/config.mk
-+++ b/config.mk
-@@ -249,7 +249,7 @@ ifeq ($(WITH_DOCS),yes)
- endif
- 
- INSTALL?=install
--prefix=/usr/local
--mandir=${prefix}/share/man
--localedir=${prefix}/share/locale
-+prefix?=/usr/local
-+mandir?=${prefix}/share/man
-+localedir?=${prefix}/share/locale
- STRIP?=strip
--- 
-2.15.1
-
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/mosquitto/files/mosquitto.init b/meta-openembedded/meta-oe/recipes-connectivity/mosquitto/files/mosquitto.init
deleted file mode 100644
index d2a27b2..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/mosquitto/files/mosquitto.init
+++ /dev/null
@@ -1,89 +0,0 @@
-#! /bin/sh
-
-# Based on the Debian initscript for mosquitto
-
-### BEGIN INIT INFO
-# Provides:         mosquitto
-# Required-Start:   $remote_fs $syslog
-# Required-Stop:    $remote_fs $syslog
-# Default-Start:    2 3 4 5
-# Default-Stop:     0 1 6
-# Short-Description:    mosquitto MQTT v3.1 message broker
-# Description: 
-#  This is a message broker that supports version 3.1 of the MQ Telemetry
-#  Transport (MQTT) protocol.
-#  
-#  MQTT provides a method of carrying out messaging using a publish/subscribe
-#  model. It is lightweight, both in terms of bandwidth usage and ease of
-#  implementation. This makes it particularly useful at the edge of the network
-#  where a sensor or other simple device may be implemented using an arduino for
-#  example.
-### END INIT INFO
-
-set -e
-
-PIDFILE=@LOCALSTATEDIR@/run/mosquitto.pid
-DAEMON=@SBINDIR@/mosquitto
-
-# start and stop the mosquitto MQTT message broker
-
-test -x ${DAEMON} || exit 0
-
-umask 022
-
-. @SYSCONFDIR@/init.d/functions
-
-export PATH="${PATH:+$PATH:}@SBINDIR@:@BASE_SBINDIR@"
-
-case "$1" in
-    start)
-        echo "Starting Mosquitto message broker" "mosquitto"
-        if start-stop-daemon --start --quiet --oknodo --background  --make-pidfile --pidfile ${PIDFILE} --exec ${DAEMON} ; then
-            exit 0
-        else
-            exit 1
-        fi
-        ;;
-    stop)
-        echo "Stopping Mosquitto message broker" "mosquitto"
-        if start-stop-daemon --stop --quiet --oknodo --pidfile ${PIDFILE}; then
-            rm -f ${PIDFILE}
-            exit 0
-        else
-            exit 1
-        fi
-        ;;
-
-
-    reload|force-reload)
-        if [ -f ${PIDFILE} ] ; then
-            echo "Reloading configuration for mosquitto"
-            pid=`cat ${PIDFILE}`
-            kill -HUP $pid
-        else
-            echo "mosquitto does not seem to be running"
-        fi
-        ;;
-
-    restart)
-        echo "Restarting Mosquitto message broker" "mosquitto"
-        if start-stop-daemon --stop --quiet --oknodo --retry 30 --pidfile ${PIDFILE}; then
-            rm -f ${PIDFILE}
-        fi
-        if start-stop-daemon --start --quiet --oknodo --background --make-pidfile --pidfile ${PIDFILE} --exec ${DAEMON} -- -c @SYSCONFDIR@/mosquitto/mosquitto.conf ; then
-            exit 0
-        else
-            exit 1
-        fi
-        ;;
-
-    status)
-        status ${DAEMON} && exit 0 || exit $?
-        ;;
-
-    *)
-        echo "Usage: $0 {start|stop|reload|force-reload|restart|status}"
-        exit 1
-esac
-
-exit 0
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/mosquitto/files/mosquitto.service b/meta-openembedded/meta-oe/recipes-connectivity/mosquitto/files/mosquitto.service
deleted file mode 100644
index 25f68fa..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/mosquitto/files/mosquitto.service
+++ /dev/null
@@ -1,15 +0,0 @@
-[Unit]
-Description=Mosquitto - lightweight server implementation of the MQTT and MQTT-SN protocols
-ConditionPathExists=/etc/mosquitto/mosquitto.conf
-After=network.target
-
-[Service]
-Type=simple
-ExecStartPre=/bin/rm -f /var/run/mosquitto.pid
-ExecStart=/usr/sbin/mosquitto -c /etc/mosquitto/mosquitto.conf
-ExecReload=/bin/kill -HUP $MAINPID
-PIDFile=/var/run/mosquitto.pid
-Restart=on-failure
-
-[Install]
-WantedBy=multi-user.target
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/mosquitto/mosquitto_1.4.14.bb b/meta-openembedded/meta-oe/recipes-connectivity/mosquitto/mosquitto_1.4.14.bb
deleted file mode 100644
index 13ce381..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/mosquitto/mosquitto_1.4.14.bb
+++ /dev/null
@@ -1,83 +0,0 @@
-SUMMARY = "Open source MQTT v3.1/3.1.1 implemention"
-DESCRIPTION = "Mosquitto is an open source (Eclipse licensed) message broker that implements the MQ Telemetry Transport protocol version 3.1 and 3.1.1. MQTT provides a lightweight method of carrying out messaging using a publish/subscribe model. "
-HOMEPAGE = "http://mosquitto.org/"
-SECTION = "console/network"
-LICENSE = "EPL-1.0 | EDL-1.0"
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=62ddc846179e908dc0c8efec4a42ef20 \
-                    file://edl-v10;md5=c09f121939f063aeb5235972be8c722c \
-                    file://epl-v10;md5=8d383c379e91d20ba18a52c3e7d3a979 \
-                    file://notice.html;md5=a00d6f9ab542be7babc2d8b80d5d2a4c \
-"
-DEPENDS = "uthash"
-
-SRC_URI = "http://mosquitto.org/files/source/mosquitto-${PV}.tar.gz \
-           file://0001-config.mk-allow-prefix-mandir-localedir-from-environ.patch \
-           file://0002-uthash-remove-in-tree-version.patch \
-           file://mosquitto.service \
-           file://mosquitto.init \
-"
-
-SRC_URI[md5sum] = "6b0966e93f118bc71ad7b61600a6c2d3"
-SRC_URI[sha256sum] = "156b1fa731d12baad4b8b22f7b6a8af50ba881fc711b81e9919ec103cf2942d1"
-
-inherit systemd update-rc.d useradd
-
-PACKAGECONFIG ??= "ssl uuid"
-
-PACKAGECONFIG[dns-srv] = ",,c-ares"
-PACKAGECONFIG[ssl] = ",,openssl"
-PACKAGECONFIG[uuid] = ",,util-linux"
-EXTRA_OEMAKE = "${@bb.utils.contains('PACKAGECONFIG', 'dns-srv', 'WITH_SRV=yes', 'WITH_SRV=no', d)} \
-                STRIP=/bin/true \
-                WITH_DOCS=no \
-                ${@bb.utils.contains('PACKAGECONFIG', 'ssl', 'WITH_TLS=yes WITH_TLS_PSK=yes', 'WITH_TLS=no WITH_TLS_PSK=no', d)} \
-                ${@bb.utils.contains('PACKAGECONFIG', 'uuid', 'WITH_UUID=yes', 'WITH_UUID=no', d)}"
-
-export LIB_SUFFIX="${@d.getVar('baselib', True).replace('lib', '')}"
-
-do_compile() {
-    oe_runmake PREFIX=${prefix}
-}
-
-do_install() {
-    oe_runmake install DESTDIR=${D}
-    install -d ${D}${libdir}
-    install -m 0644 lib/libmosquitto.a ${D}${libdir}/
-
-    install -d ${D}${systemd_unitdir}/system/
-    install -m 0644 ${WORKDIR}/mosquitto.service ${D}${systemd_unitdir}/system/
-
-    install -d ${D}${sysconfdir}/init.d/
-    install -m 0755 ${WORKDIR}/mosquitto.init ${D}${sysconfdir}/init.d/mosquitto
-    sed -i -e 's,@SBINDIR@,${sbindir},g' \
-        -e 's,@BASE_SBINDIR@,${base_sbindir},g' \
-        -e 's,@LOCALSTATEDIR@,${localstatedir},g' \
-        -e 's,@SYSCONFDIR@,${sysconfdir},g' \
-        ${D}${sysconfdir}/init.d/mosquitto
-}
-
-PACKAGES += "libmosquitto1 libmosquittopp1 ${PN}-clients"
-
-FILES_${PN} = "${sbindir}/mosquitto \
-               ${bindir}/mosquitto_passwd \
-               ${sysconfdir}/mosquitto \
-               ${sysconfdir}/init.d \
-               ${systemd_unitdir}/system/mosquitto.service \
-"
-
-FILES_libmosquitto1 = "${libdir}/libmosquitto.so.1"
-
-FILES_libmosquittopp1 = "${libdir}/libmosquittopp.so.1"
-
-FILES_${PN}-clients = "${bindir}/mosquitto_pub \
-                       ${bindir}/mosquitto_sub \
-"
-
-SYSTEMD_SERVICE_${PN} = "mosquitto.service"
-
-INITSCRIPT_NAME = "mosquitto"
-INITSCRIPT_PARAMS = "defaults 30"
-
-USERADD_PACKAGES = "${PN}"
-USERADD_PARAM_${PN} = "--system --no-create-home --shell /bin/false \
-                       --user-group mosquitto"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/obex/openobex_1.7.2.bb b/meta-openembedded/meta-oe/recipes-connectivity/obex/openobex_1.7.2.bb
index 1b56685..3fb8cb1 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/obex/openobex_1.7.2.bb
+++ b/meta-openembedded/meta-oe/recipes-connectivity/obex/openobex_1.7.2.bb
@@ -2,29 +2,26 @@
 Object Exchange (OBEX) protocol."
 HOMEPAGE = "http://openobex.triq.net"
 SECTION = "libs"
-DEPENDS = "virtual/libusb0"
-DEPENDS_append_class-target = " ${@bb.utils.contains('DISTRO_FEATURES','bluez5','bluez5','bluez4',d)}"
-
 LICENSE = "GPLv2 & LGPLv2.1"
 LIC_FILES_CHKSUM = "file://COPYING;md5=eb723b61539feef013de476e68b5c50a \
                     file://COPYING.LIB;md5=a6f89e2100d9b6cdffcea4f398e37343 \
 "
 
+DEPENDS = "virtual/libusb0"
+DEPENDS_append_class-target = " ${@bb.utils.contains('DISTRO_FEATURES','bluez5','bluez5','bluez4',d)}"
+
 SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BPN}/${PV}/${BP}-Source.tar.gz \
 "
-
 SRC_URI[md5sum] = "f6e0b6cb7dcfd731460a7e9a91429a3a"
 SRC_URI[sha256sum] = "158860aaea52f0fce0c8e4b64550daaae06df2689e05834697b7e8c7d73dd4fc"
 
-inherit cmake pkgconfig
-
 S = "${WORKDIR}/${BP}-Source"
 
+inherit cmake pkgconfig
+
 EXTRA_OECONF = " -DCMAKE_SKIP_RPATH=ON "
 EXTRA_OECMAKE += "-DBUILD_DOCUMENTATION=OFF"
 
-#--enable-apps --enable-syslog
-
 ASNEEDED = ""
 
 do_install_append () {
@@ -34,7 +31,7 @@
 PACKAGES =+ "openobex-apps"
 FILES_${PN}-apps = "${bindir}/*"
 FILES_${PN} += "${libdir}/lib*.so.*"
-FILES_${PN}-dev += "${bindir}/openobex-config ${libdir}/cmake"
+FILES_${PN}-dev += "${bindir}/openobex-config"
 DEBIAN_NOAUTONAME_${PN}-apps = "1"
 
 BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/paho-mqtt-c/paho-mqtt-c_1.2.0.bb b/meta-openembedded/meta-oe/recipes-connectivity/paho-mqtt-c/paho-mqtt-c_1.2.0.bb
deleted file mode 100644
index fec380c..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/paho-mqtt-c/paho-mqtt-c_1.2.0.bb
+++ /dev/null
@@ -1,35 +0,0 @@
-SUMMARY = "Paho MQTT - C libraries for the MQTT and MQTT-SN protocols"
-DESCRIPTION = "Client implementation of open and standard messaging protocols for Machine-to-Machine (M2M) and Internet of Things (IoT)."
-HOMEPAGE = "http://www.eclipse.org/paho/"
-SECTION = "console/network"
-LICENSE = "EPL-1.0 | EDL-1.0"
-
-LIC_FILES_CHKSUM = " \
-        file://edl-v10;md5=3adfcc70f5aeb7a44f3f9b495aa1fbf3 \
-        file://epl-v10;md5=659c8e92a40b6df1d9e3dccf5ae45a08 \
-        file://notice.html;md5=a00d6f9ab542be7babc2d8b80d5d2a4c \
-        file://about.html;md5=dcde438d73cf42393da9d40fabc0c9bc \
-"
-
-SRC_URI = "git://github.com/eclipse/paho.mqtt.c;protocol=http"
-
-SRCREV = "e8d34da24ad807f5e698b327d67591fd4b4bfa7e"
-
-DEPENDS = "openssl"
-
-S = "${WORKDIR}/git"
-
-TARGET_CC_ARCH += "${LDFLAGS}"
-
-do_install() {
-    install -d ${D}${libdir}
-    oe_libinstall -C build/output -so libpaho-mqtt3a ${D}${libdir}
-    oe_libinstall -C build/output -so libpaho-mqtt3as ${D}${libdir}
-    oe_libinstall -C build/output -so libpaho-mqtt3c  ${D}${libdir}
-    oe_libinstall -C build/output -so libpaho-mqtt3cs ${D}${libdir}
-    install -d ${D}${includedir}
-    install -m 644 src/MQTTAsync.h ${D}${includedir}
-    install -m 644 src/MQTTClient.h ${D}${includedir}
-    install -m 644 src/MQTTClientPersistence.h ${D}${includedir}
-}
-
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/paho-mqtt-c/paho-mqtt-c_1.2.1.bb b/meta-openembedded/meta-oe/recipes-connectivity/paho-mqtt-c/paho-mqtt-c_1.2.1.bb
new file mode 100644
index 0000000..a7a9b5a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/paho-mqtt-c/paho-mqtt-c_1.2.1.bb
@@ -0,0 +1,35 @@
+SUMMARY = "Paho MQTT - C libraries for the MQTT and MQTT-SN protocols"
+DESCRIPTION = "Client implementation of open and standard messaging protocols for Machine-to-Machine (M2M) and Internet of Things (IoT)."
+HOMEPAGE = "http://www.eclipse.org/paho/"
+SECTION = "console/network"
+LICENSE = "EPL-1.0 | EDL-1.0"
+
+LIC_FILES_CHKSUM = " \
+        file://edl-v10;md5=3adfcc70f5aeb7a44f3f9b495aa1fbf3 \
+        file://epl-v10;md5=659c8e92a40b6df1d9e3dccf5ae45a08 \
+        file://notice.html;md5=a00d6f9ab542be7babc2d8b80d5d2a4c \
+        file://about.html;md5=dcde438d73cf42393da9d40fabc0c9bc \
+"
+
+SRC_URI = "git://github.com/eclipse/paho.mqtt.c;protocol=http"
+
+SRCREV = "09fe0744e02f317b907e96dd5afcc02224ddbb85"
+
+DEPENDS = "openssl"
+
+S = "${WORKDIR}/git"
+
+TARGET_CC_ARCH += "${LDFLAGS}"
+
+do_install() {
+    install -d ${D}${libdir}
+    oe_libinstall -C build/output -so libpaho-mqtt3a ${D}${libdir}
+    oe_libinstall -C build/output -so libpaho-mqtt3as ${D}${libdir}
+    oe_libinstall -C build/output -so libpaho-mqtt3c  ${D}${libdir}
+    oe_libinstall -C build/output -so libpaho-mqtt3cs ${D}${libdir}
+    install -d ${D}${includedir}
+    install -m 644 src/MQTTAsync.h ${D}${includedir}
+    install -m 644 src/MQTTClient.h ${D}${includedir}
+    install -m 644 src/MQTTClientPersistence.h ${D}${includedir}
+}
+
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/rtorrent/rtorrent_git.bb b/meta-openembedded/meta-oe/recipes-connectivity/rtorrent/rtorrent_git.bb
index c731cf7..9bb81c4 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/rtorrent/rtorrent_git.bb
+++ b/meta-openembedded/meta-oe/recipes-connectivity/rtorrent/rtorrent_git.bb
@@ -8,9 +8,10 @@
 SRC_URI = "git://github.com/rakshasa/rtorrent \
     file://don-t-run-code-while-configuring-package.patch \
 "
-SRCREV = "226e670decf92e7adaa845a6982aca4f164ea740"
+# v0.9.7
+SRCREV = "327164f9d86aafcd2500a317d485374df32ea622"
 
-PV = "0.9.6+git${SRCPV}"
+PV = "0.9.7+git${SRCPV}"
 
 S = "${WORKDIR}/git"
 
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/ser2net/ser2net_3.4.bb b/meta-openembedded/meta-oe/recipes-connectivity/ser2net/ser2net_3.4.bb
deleted file mode 100644
index 708650f..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/ser2net/ser2net_3.4.bb
+++ /dev/null
@@ -1,15 +0,0 @@
-SUMMARY = "A serial to network proxy"
-SECTION = "console/network"
-HOMEPAGE = "http://sourceforge.net/projects/ser2net/"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=bae3019b4c6dc4138c217864bd04331f"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/project/ser2net/ser2net/ser2net-${PV}.tar.gz"
-
-SRC_URI[md5sum] = "562274d783534276a9feac913b7d8c4e"
-SRC_URI[sha256sum] = "d846066e27c3072565990745d030357aa0c278f96b7d1d4f59023347c1db8824"
-
-inherit autotools pkgconfig
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/ser2net/ser2net_3.5.bb b/meta-openembedded/meta-oe/recipes-connectivity/ser2net/ser2net_3.5.bb
new file mode 100644
index 0000000..f64776c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/ser2net/ser2net_3.5.bb
@@ -0,0 +1,15 @@
+SUMMARY = "A serial to network proxy"
+SECTION = "console/network"
+HOMEPAGE = "http://sourceforge.net/projects/ser2net/"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=bae3019b4c6dc4138c217864bd04331f"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/project/ser2net/ser2net/ser2net-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "e10e7c8c97e5bade5e85ce6e89bdf1f4"
+SRC_URI[sha256sum] = "ba9e1d60a89fd7ed075553b4a2074352902203f7fbd9b65b15048c05f0e3f3be"
+
+inherit autotools pkgconfig
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0001-Forcibly-disable-check-for-Qt5.patch b/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0001-Forcibly-disable-check-for-Qt5.patch
index fcc2f08..a77cd28 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0001-Forcibly-disable-check-for-Qt5.patch
+++ b/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0001-Forcibly-disable-check-for-Qt5.patch
@@ -1,9 +1,10 @@
-From b3da0d8677b7e8467367a303c18551c56ed20e15 Mon Sep 17 00:00:00 2001
+From a5544d8e543436e413379422b702f6f56ac7eb8e Mon Sep 17 00:00:00 2001
 From: Philip Balister <philip@balister.org>
 Date: Tue, 12 Apr 2016 17:30:15 -0400
 Subject: [PATCH] Forcibly disable check for Qt5.
 
 Signed-off-by: Philip Balister <philip@balister.org>
+
 ---
  build/cmake/DefineOptions.cmake | 3 ---
  1 file changed, 3 deletions(-)
@@ -22,6 +23,3 @@
  if(${WITH_QT4} AND ${WITH_QT5} AND ${CMAKE_MAJOR_VERSION} LESS 3)
    # cmake < 3.0.0 causes conflict when building both Qt4 and Qt5
    set(WITH_QT4 OFF)
--- 
-2.5.5
-
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0001-THRIFT-3828-In-cmake-avoid-use-of-both-quoted-paths-.patch b/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0001-THRIFT-3828-In-cmake-avoid-use-of-both-quoted-paths-.patch
index 7cc8d17..182eacc 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0001-THRIFT-3828-In-cmake-avoid-use-of-both-quoted-paths-.patch
+++ b/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0001-THRIFT-3828-In-cmake-avoid-use-of-both-quoted-paths-.patch
@@ -1,7 +1,7 @@
-From bc577820ad25795543b31f123e309cdaebc7d6c6 Mon Sep 17 00:00:00 2001
+From b8e254a2f4ba49412e541598c72159869a7770f8 Mon Sep 17 00:00:00 2001
 From: Cody P Schafer <dev@codyps.com>
 Date: Mon, 16 May 2016 15:21:10 -0400
-Subject: [PATCH 1/2] THRIFT-3828 In cmake avoid use of both quoted paths and
+Subject: [PATCH] THRIFT-3828 In cmake avoid use of both quoted paths and
  SYSTEM with include_directories()
 
 This allows us to avoid issues where there are no paths to be added to
@@ -11,6 +11,7 @@
 Specifically, gcc-6 requires that libraries stop passing paths like
 '/usr/include' (or they will get libstdc++ build errors), so these paths
 will be empty more often in the future.
+
 ---
  lib/cpp/CMakeLists.txt      | 8 ++++----
  lib/cpp/test/CMakeLists.txt | 2 +-
@@ -105,6 +106,3 @@
  
  #Make sure gen-cpp files can be included
  include_directories("${CMAKE_CURRENT_BINARY_DIR}")
--- 
-2.9.3
-
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0002-THRIFT-3831-in-test-cpp-explicitly-use-signed-char.patch b/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0002-THRIFT-3831-in-test-cpp-explicitly-use-signed-char.patch
index f13adbb..37715c2 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0002-THRIFT-3831-in-test-cpp-explicitly-use-signed-char.patch
+++ b/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0002-THRIFT-3831-in-test-cpp-explicitly-use-signed-char.patch
@@ -1,7 +1,7 @@
-From f6cad0580e5391c37af7f60adddb71bf1a403dc4 Mon Sep 17 00:00:00 2001
+From 7b05a74432f08ef34d0f8743dd6438ad012e3b5e Mon Sep 17 00:00:00 2001
 From: Cody P Schafer <dev@codyps.com>
 Date: Fri, 9 Sep 2016 15:50:26 -0400
-Subject: [PATCH 2/2] THRIFT-3831 in test/cpp explicitly use `signed char`
+Subject: [PATCH] THRIFT-3831 in test/cpp explicitly use `signed char`
 
 `char`'s signed-ness is implimentation dependent, and in the case where
 `char` was not signed, we previously recieved errors like
@@ -9,15 +9,16 @@
     thrift/0.9.3-r0/git/test/cpp/src/TestClient.cpp:404:15: error: narrowing conversion of '-127' from 'int' to 'char' inside { } [-Wnarrowing]
 
 (This example from gcc-6 on arm)
+
 ---
  test/cpp/src/TestClient.cpp | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/test/cpp/src/TestClient.cpp b/test/cpp/src/TestClient.cpp
-index e709899..4a961f8 100644
+index 7c425a9..7145ebb 100644
 --- a/test/cpp/src/TestClient.cpp
 +++ b/test/cpp/src/TestClient.cpp
-@@ -383,7 +383,7 @@ int main(int argc, char** argv) {
+@@ -381,7 +381,7 @@ int main(int argc, char** argv) {
       * BINARY TEST
       */
      printf("testBinary([-128..127]) = {");
@@ -26,7 +27,7 @@
          = {-128, -127, -126, -125, -124, -123, -122, -121, -120, -119, -118, -117, -116, -115, -114,
             -113, -112, -111, -110, -109, -108, -107, -106, -105, -104, -103, -102, -101, -100, -99,
             -98,  -97,  -96,  -95,  -94,  -93,  -92,  -91,  -90,  -89,  -88,  -87,  -86,  -85,  -84,
-@@ -404,7 +404,7 @@ int main(int argc, char** argv) {
+@@ -402,7 +402,7 @@ int main(int argc, char** argv) {
             127};
      try {
        string bin_result;
@@ -35,6 +36,3 @@
        if (bin_result.size() != 256) {
          printf("}\n*** FAILED ***\n");
          printf("invalid length: %lu\n", bin_result.size());
--- 
-2.9.3
-
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0004-THRIFT-3207-enable-build-with-OpenSSL-1.1.0-series.patch b/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0004-THRIFT-3207-enable-build-with-OpenSSL-1.1.0-series.patch
new file mode 100644
index 0000000..500cfab
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0004-THRIFT-3207-enable-build-with-OpenSSL-1.1.0-series.patch
@@ -0,0 +1,41 @@
+From 5f2c7e50b99d72177250c44236c41b99bfc161b5 Mon Sep 17 00:00:00 2001
+From: Andrej Valek <andrej.valek@siemens.com>
+Date: Thu, 7 Jun 2018 15:21:06 +0200
+Subject: [PATCH 4/6] %% original patch:
+ 0004-THRIFT-3207-enable-build-with-OpenSSL-1.1.0-series.patch
+
+---
+ lib/cpp/src/thrift/transport/TSSLSocket.cpp | 6 ++++++
+ 1 file changed, 6 insertions(+)
+
+diff --git a/lib/cpp/src/thrift/transport/TSSLSocket.cpp b/lib/cpp/src/thrift/transport/TSSLSocket.cpp
+index 98c5326..3da9e45 100644
+--- a/lib/cpp/src/thrift/transport/TSSLSocket.cpp
++++ b/lib/cpp/src/thrift/transport/TSSLSocket.cpp
+@@ -39,6 +39,7 @@
+ #include <thrift/transport/PlatformSocket.h>
+ 
+ #define OPENSSL_VERSION_NO_THREAD_ID 0x10000000L
++#define OPENSSL_VERSION_WITH_TLSv1_1_AND_TLSv1_2 0x10100000L
+ 
+ using namespace std;
+ using namespace apache::thrift::concurrency;
+@@ -143,10 +144,15 @@ SSLContext::SSLContext(const SSLProtocol& protocol) {
+     ctx_ = SSL_CTX_new(SSLv3_method());
+   } else if (protocol == TLSv1_0) {
+     ctx_ = SSL_CTX_new(TLSv1_method());
++#if (OPENSSL_VERSION_NUMBER >= OPENSSL_VERSION_WITH_TLSv1_1_AND_TLSv1_2)
+   } else if (protocol == TLSv1_1) {
+     ctx_ = SSL_CTX_new(TLSv1_1_method());
+   } else if (protocol == TLSv1_2) {
+     ctx_ = SSL_CTX_new(TLSv1_2_method());
++#else
++  //Support for this versions will end on 2016-12-31
++  //https://www.openssl.org/about/releasestrat.html
++#endif
+   } else {
+     /// UNKNOWN PROTOCOL!
+     throw TSSLException("SSL_CTX_new: Unknown protocol");
+-- 
+2.19.0
+
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0005-THRIFT-3878-Compile-error-in-TSSLSocket.cpp-with-new.patch b/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0005-THRIFT-3878-Compile-error-in-TSSLSocket.cpp-with-new.patch
new file mode 100644
index 0000000..f4482b1
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0005-THRIFT-3878-Compile-error-in-TSSLSocket.cpp-with-new.patch
@@ -0,0 +1,26 @@
+From 81f36e7174097a1f1f3e7f94a97574b2ec68577f Mon Sep 17 00:00:00 2001
+From: "James E. King, III" <jim.king@simplivity.com>
+Date: Thu, 29 Sep 2016 15:04:09 -0400
+Subject: [PATCH] THRIFT-3878: fix interop with newer OpenSSL libraries
+
+---
+ lib/cpp/src/thrift/transport/TSSLSocket.cpp | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/lib/cpp/src/thrift/transport/TSSLSocket.cpp b/lib/cpp/src/thrift/transport/TSSLSocket.cpp
+index 3da9e45..0a3a124 100644
+--- a/lib/cpp/src/thrift/transport/TSSLSocket.cpp
++++ b/lib/cpp/src/thrift/transport/TSSLSocket.cpp
+@@ -97,7 +97,12 @@ void initializeOpenSSL() {
+   SSL_library_init();
+   SSL_load_error_strings();
+   // static locking
++  // newer versions of OpenSSL changed CRYPTO_num_locks - see THRIFT-3878
++#ifdef CRYPTO_num_locks
++  mutexes = boost::shared_array<Mutex>(new Mutex[CRYPTO_num_locks()]);
++#else
+   mutexes = boost::shared_array<Mutex>(new Mutex[ ::CRYPTO_num_locks()]);
++#endif
+   if (mutexes == NULL) {
+     throw TTransportException(TTransportException::INTERNAL_ERROR,
+                               "initializeOpenSSL() failed, "
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0006-THRIFT-3736-C++-library-build-fails-if-OpenSSL-does-.patch b/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0006-THRIFT-3736-C++-library-build-fails-if-OpenSSL-does-.patch
new file mode 100644
index 0000000..dfaa2fb
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0006-THRIFT-3736-C++-library-build-fails-if-OpenSSL-does-.patch
@@ -0,0 +1,46 @@
+From 4cd49f470ca983369451d1141acc80fe1115cab4 Mon Sep 17 00:00:00 2001
+From: Nobuaki Sukegawa <nsuke@apache.org>
+Date: Sun, 13 Mar 2016 08:55:38 +0900
+Subject: [PATCH] THRIFT-3736 C++ library build fails if OpenSSL does not
+
+ surrpot SSLv3
+
+---
+ lib/cpp/src/thrift/transport/TSSLSocket.cpp | 2 ++
+ lib/cpp/test/SecurityTest.cpp               | 8 ++++++++
+ 2 files changed, 10 insertions(+)
+
+diff --git a/lib/cpp/src/thrift/transport/TSSLSocket.cpp b/lib/cpp/src/thrift/transport/TSSLSocket.cpp
+index 0a3a124..3e79354 100644
+--- a/lib/cpp/src/thrift/transport/TSSLSocket.cpp
++++ b/lib/cpp/src/thrift/transport/TSSLSocket.cpp
+@@ -145,8 +145,10 @@ static char uppercase(char c);
+ SSLContext::SSLContext(const SSLProtocol& protocol) {
+   if (protocol == SSLTLS) {
+     ctx_ = SSL_CTX_new(SSLv23_method());
++#ifndef OPENSSL_NO_SSL3
+   } else if (protocol == SSLv3) {
+     ctx_ = SSL_CTX_new(SSLv3_method());
++#endif
+   } else if (protocol == TLSv1_0) {
+     ctx_ = SSL_CTX_new(TLSv1_method());
+ #if (OPENSSL_VERSION_NUMBER >= OPENSSL_VERSION_WITH_TLSv1_1_AND_TLSv1_2)
+diff --git a/lib/cpp/test/SecurityTest.cpp b/lib/cpp/test/SecurityTest.cpp
+index 213efd4..08110e7 100644
+--- a/lib/cpp/test/SecurityTest.cpp
++++ b/lib/cpp/test/SecurityTest.cpp
+@@ -239,6 +239,14 @@ BOOST_AUTO_TEST_CASE(ssl_security_matrix)
+                     continue;
+                 }
+ 
++#ifdef OPENSSL_NO_SSL3
++                if (si == 2 || ci == 2)
++                {
++                    // Skip all SSLv3 cases - protocol not supported
++                    continue;
++                }
++#endif
++
+                 boost::mutex::scoped_lock lock(mMutex);
+ 
+                 BOOST_TEST_MESSAGE(boost::format("TEST: Server = %1%, Client = %2%")
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift_0.9.3.bb b/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift_0.9.3.bb
index aa93283..7ab7402 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift_0.9.3.bb
+++ b/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift_0.9.3.bb
@@ -12,6 +12,9 @@
            file://0001-Forcibly-disable-check-for-Qt5.patch \
            file://0001-THRIFT-3828-In-cmake-avoid-use-of-both-quoted-paths-.patch \
            file://0002-THRIFT-3831-in-test-cpp-explicitly-use-signed-char.patch \
+           file://0004-THRIFT-3207-enable-build-with-OpenSSL-1.1.0-series.patch \
+           file://0005-THRIFT-3878-Compile-error-in-TSSLSocket.cpp-with-new.patch \
+           file://0006-THRIFT-3736-C++-library-build-fails-if-OpenSSL-does-.patch \
 "
 
 SRC_URI[md5sum] = "88d667a8ae870d5adeca8cb7d6795442"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/umip/files/0001-replace-SIGCLD-with-SIGCHLD-and-include-sys-types.h.patch b/meta-openembedded/meta-oe/recipes-connectivity/umip/files/0001-replace-SIGCLD-with-SIGCHLD-and-include-sys-types.h.patch
deleted file mode 100644
index 8192056..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/umip/files/0001-replace-SIGCLD-with-SIGCHLD-and-include-sys-types.h.patch
+++ /dev/null
@@ -1,49 +0,0 @@
-From f567740cf64978ac9db014c786b6d0267b244f33 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 4 Mar 2018 22:30:30 -0800
-Subject: [PATCH 1/2] replace SIGCLD with SIGCHLD and include sys/types.h
-
-Fixes
-main.c:129:10: error: 'SIGCLD' undeclared (first use in this function); did you mean 'SIGCHLD'?
-   signal(SIGCLD, sig_child);
-          ^~~~~~
-          SIGCHLD
-
-main.c:125:2: warning: implicit declaration of function 'umask' [-Wimplicit-function-declaration]
-  umask(0);
-  ^~~~~
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Pending
-
- src/main.c | 5 +++--
- 1 file changed, 3 insertions(+), 2 deletions(-)
-
-diff --git a/src/main.c b/src/main.c
-index 3cf4072..cd34196 100644
---- a/src/main.c
-+++ b/src/main.c
-@@ -31,6 +31,7 @@
- #include <sys/ioctl.h>
- #include <sys/wait.h>
- #include <sys/param.h>
-+#include <sys/types.h>
- #include <pthread.h>
- #include <fcntl.h>
- #include <unistd.h>
-@@ -126,9 +127,9 @@ static void daemon_start(int ignsigcld)
- 
- 	if (ignsigcld) {
- #ifdef SIGTSTP
--		signal(SIGCLD, sig_child);
-+		signal(SIGCHLD, sig_child);
- #else
--		signal(SIGCLD, SIG_IGN);
-+		signal(SIGCHLD, SIG_IGN);
- #endif
- 	}
- }
--- 
-2.16.2
-
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/umip/umip_1.0.bb b/meta-openembedded/meta-oe/recipes-connectivity/umip/umip_1.0.bb
deleted file mode 100644
index 0c120bf..0000000
--- a/meta-openembedded/meta-oe/recipes-connectivity/umip/umip_1.0.bb
+++ /dev/null
@@ -1,42 +0,0 @@
-SUMMARY = "Mobile IPv6 and NEMO for Linux"
-DESCRIPTION = "UMIP is an open source implementation of Mobile IPv6 and NEMO \
-Basic Support for Linux. It is released under the GPLv2 license. It supports \
-the following IETF RFC: RFC6275 (Mobile IPv6), RFC3963 (NEMO), RFC3776 and \
-RFC4877 (IPsec and IKEv2)."
-HOMEPAGE = "http://umip.org/"
-SECTION = "System Environment/Base"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=073dc31ccb2ebed70db54f1e8aeb4c33"
-DEPENDS = "rpm indent-native"
-
-SRC_URI = "git://github.com/jlanza/umip \
-           file://add-dependency-to-support-parallel-compilation.patch \
-           file://mip6d \
-           file://mip6d.service \
-           file://0001-Add-format-string-to-fprintf-call.patch \
-           file://0001-replace-SIGCLD-with-SIGCHLD-and-include-sys-types.h.patch \
-           file://0002-replace-PTHREAD_MUTEX_FAST_NP-with-PTHREAD_MUTEX_NOR.patch \
-           "
-SRCREV = "7d67209cd1bba2dd0e183a0fa07eeef07964dd14"
-
-S = "${WORKDIR}/git"
-
-EXTRA_OECONF = "--enable-vt"
-
-inherit autotools-brokensep systemd update-rc.d
-
-INITSCRIPT_NAME = "mip6d"
-INITSCRIPT_PARAMS = "start 64 . stop 36 0 1 2 3 4 5 6 ."
-
-SYSTEMD_SERVICE_${PN} = "mip6d.service"
-SYSTEMD_AUTO_ENABLE = "disable"
-
-do_install_append() {
-	install -D -m 0755 ${WORKDIR}/mip6d ${D}${sysconfdir}/init.d/mip6d
-	install -D -m 0644 ${WORKDIR}/mip6d.service ${D}${systemd_system_unitdir}/mip6d.service
-	sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' \
-	    -e 's,@SBINDIR@,${sbindir},g' \
-	    ${D}${systemd_system_unitdir}/mip6d.service
-}
-
-RRECOMMENDS_${PN} = "kernel-module-mip6 kernel-module-ipv6"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/usbmuxd/usbmuxd_git.bb b/meta-openembedded/meta-oe/recipes-connectivity/usbmuxd/usbmuxd_git.bb
index 4365aa4..7284234 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/usbmuxd/usbmuxd_git.bb
+++ b/meta-openembedded/meta-oe/recipes-connectivity/usbmuxd/usbmuxd_git.bb
@@ -1,24 +1,21 @@
 DESCRIPTION = "This daemon is in charge of multiplexing connections over USB to an iPhone or iPod touch."
 LICENSE = "GPLv3 & GPLv2 & LGPLv2.1"
 LIC_FILES_CHKSUM = "file://COPYING.GPLv2;md5=ebb5c50ab7cab4baeffba14977030c07 \
-                    file://COPYING.GPLv3;md5=d32239bcb673463ab874e80d47fae504 \
-                    file://COPYING.LGPLv2.1;md5=6ab17b41640564434dda85c06b7124f7"
+                    file://COPYING.GPLv3;md5=d32239bcb673463ab874e80d47fae504"
 
-DEPENDS = "udev libusb1"
+DEPENDS = "udev libusb1 libplist"
 
-inherit cmake pkgconfig gitpkgv
+inherit autotools pkgconfig gitpkgv systemd
 
 PKGV = "${GITPKGVTAG}"
 
-SRCREV = "919587580c5e77f3936f3432115d2e10c7bac7c5"
-SRC_URI = "git://git.sukimashita.com/usbmuxd.git;protocol=http"
+SRCREV = "ee85938c21043ef5f7cd4dfbc7677f385814d4d8"
+SRC_URI = "git://github.com/libimobiledevice/usbmuxd;protocol=https"
 
 S = "${WORKDIR}/git"
 
+EXTRA_OECONF += "--without-preflight"
+
 FILES_${PN} += "${base_libdir}/udev/rules.d/"
 
-# fix usbmuxd installing files to /usr/lib64 on 64bit hosts:
-EXTRA_OECMAKE = "-DLIB_SUFFIX=${@d.getVar('baselib').replace('lib', '')}"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[plist] = "-DWANT_PLIST=1,-DWANT_PLIST=0,libplist"
+SYSTEMD_SERVICE_${PN} = "usbmuxd.service"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvdial_1.61.bb b/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvdial_1.61.bb
index 3a71fb9..5154208 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvdial_1.61.bb
+++ b/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvdial_1.61.bb
@@ -30,3 +30,5 @@
 do_install() {
     oe_runmake prefix=${D}/usr PPPDIR=${D}/etc/ppp/peers install
 }
+# http://errors.yoctoproject.org/Errors/Details/186959/
+EXCLUDE_FROM_WORLD_libc-musl = "1"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/0001-Forward-port-to-OpenSSL-1.1.x.patch b/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/0001-Forward-port-to-OpenSSL-1.1.x.patch
new file mode 100644
index 0000000..19a2e26
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/0001-Forward-port-to-OpenSSL-1.1.x.patch
@@ -0,0 +1,557 @@
+From 0c35749891bf834c1f3c1c4c330266bd2f4733cc Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 9 Sep 2018 10:40:09 -0700
+Subject: [PATCH] Forward port to OpenSSL 1.1.x
+
+* import patch from debian
+https://sources.debian.org/src/wvstreams/4.6.1-14/debian/patches/wvstreams_openssl1.1.patch
+Author: Reiner Herrmann <reiner@reiner-h.de>
+
+Upstream-Status: Submitted [https://github.com/apenwarr/wvstreams/pull/2]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ crypto/wvcrl.cc           | 38 +++++++++++++-------------------------
+ crypto/wvdiffiehellman.cc | 30 +++++++++++++++++++-----------
+ crypto/wvdigest.cc        | 16 ++++++++--------
+ crypto/wvocsp.cc          | 35 +++++++++--------------------------
+ crypto/wvx509.cc          | 31 ++++++++++++++++---------------
+ crypto/wvx509mgr.cc       | 27 ++++++++++++++++-----------
+ include/wvdiffiehellman.h |  2 +-
+ include/wvdigest.h        | 14 ++++++--------
+ include/wvtripledes.h     | 10 +++++-----
+ 9 files changed, 93 insertions(+), 110 deletions(-)
+
+diff --git a/crypto/wvcrl.cc b/crypto/wvcrl.cc
+index fa00c76..880ad85 100644
+--- a/crypto/wvcrl.cc
++++ b/crypto/wvcrl.cc
+@@ -357,31 +357,19 @@ bool WvCRL::isrevoked(WvStringParm serial_number) const
+ 	ASN1_INTEGER *serial = serial_to_int(serial_number);
+ 	if (serial)
+ 	{
+-	    X509_REVOKED mayberevoked;
+-	    mayberevoked.serialNumber = serial;
+-	    if (crl->crl->revoked)
+-	    {
+-		int idx = sk_X509_REVOKED_find(crl->crl->revoked, 
+-					       &mayberevoked);
+-		ASN1_INTEGER_free(serial);
+-		if (idx >= 0)
+-                {
+-                    debug("Certificate is revoked.\n");
+-		    return true;
+-                }
+-                else
+-                {
+-                    debug("Certificate is not revoked.\n");
+-		    return false;
+-                }
+-	    }
+-	    else
+-	    {
+-		ASN1_INTEGER_free(serial);
+-		debug("CRL does not have revoked list.\n");
+-                return false;
+-	    }
+-	    
++	    X509_REVOKED *revoked_entry = NULL;
++	    int idx = X509_CRL_get0_by_serial(crl, &revoked_entry, serial);
++	    ASN1_INTEGER_free(serial);
++	    if (idx >= 1 || revoked_entry)
++            {
++                debug("Certificate is revoked.\n");
++	        return true;
++            }
++            else
++            {
++                debug("Certificate is not revoked.\n");
++	        return false;
++            }
+ 	}
+ 	else
+ 	    debug(WvLog::Warning, "Can't convert serial number to ASN1 format. "
+diff --git a/crypto/wvdiffiehellman.cc b/crypto/wvdiffiehellman.cc
+index 7c0bf32..15cd104 100644
+--- a/crypto/wvdiffiehellman.cc
++++ b/crypto/wvdiffiehellman.cc
+@@ -39,24 +39,25 @@ WvDiffieHellman::WvDiffieHellman(const unsigned char *_key, int _keylen,
+ {
+     int problems;
+     int check;
+-    {
++
+ 	info = DH_new();
+-	info->p = BN_bin2bn(_key, _keylen, NULL);
++	BIGNUM *p = BN_bin2bn(_key, _keylen, NULL);
+ // 	info->p->top = 0;
+ // 	info->p->dmax = _keylen * 8 / BN_BITS2;
+ // 	info->p->neg = 0;
+ // 	info->p->flags = 0;
+ 
+-	info->g = BN_new();
+-	BN_set_word(info->g, generator);
++	BIGNUM *g = BN_new();
++	BN_set_word(g, generator);
+ // 	info->g->d = &generator;
+ //  	info->g->top = 0;
+ //  	info->g->dmax = 1;
+ //  	info->g->neg = 0;
+ //  	info->g->flags = 0;
+-    }
+ 
+-    check = BN_mod_word(info->p, 24);
++	DH_set0_pqg(info, p, NULL, g);
++
++    check = BN_mod_word(p, 24);
+     DH_check(info, &problems);
+     if (problems & DH_CHECK_P_NOT_PRIME)
+  	log(WvLog::Error, "Using a composite number for authentication.\n");
+@@ -64,7 +65,7 @@ WvDiffieHellman::WvDiffieHellman(const unsigned char *_key, int _keylen,
+ 	log(WvLog::Error,"Using an unsafe prime number for authentication.\n");
+     if (problems & DH_NOT_SUITABLE_GENERATOR)
+ 	log(WvLog::Error, "Can you just use 2 instead of %s (%s)!!\n",
+-	    BN_bn2hex(info->g), check);
++	    BN_bn2hex(g), check);
+     if (problems & DH_UNABLE_TO_CHECK_GENERATOR)
+ 	log(WvLog::Notice, "Using a strange argument for diffie-hellman.\n");
+     DH_generate_key(info);
+@@ -72,18 +73,23 @@ WvDiffieHellman::WvDiffieHellman(const unsigned char *_key, int _keylen,
+ 
+ int WvDiffieHellman::pub_key_len()
+ {
+-    return BN_num_bytes(info->pub_key);
++    const BIGNUM *pub_key = NULL;
++	DH_get0_key(info, &pub_key, NULL);
++    return BN_num_bytes(pub_key);
+ }
+ 
+ int WvDiffieHellman::get_public_value(WvBuf &outbuf, int len)
+ {
+-    int key_len = BN_num_bytes(info->pub_key);
++	const BIGNUM *pub_key = NULL;
++	DH_get0_key(info, &pub_key, NULL);
++
++    int key_len = BN_num_bytes(pub_key);
+     if (key_len < len)
+ 	len = key_len;
+ 
+     // alloca is stack allocated, don't free it.
+     unsigned char *foo = (unsigned char*)alloca(key_len);
+-    BN_bn2bin(info->pub_key, foo);
++    BN_bn2bin(pub_key, foo);
+     outbuf.put(foo, len);
+ 
+     return len;
+@@ -91,8 +97,10 @@ int WvDiffieHellman::get_public_value(WvBuf &outbuf, int len)
+ 
+ bool WvDiffieHellman::create_secret(WvBuf &inbuf, size_t in_len, WvBuf& outbuf)
+ {
++   const BIGNUM *pub_key = NULL;
++   DH_get0_key(info, &pub_key, NULL);
+     unsigned char *foo = (unsigned char *)alloca(DH_size(info));
+-   log("My public value\n%s\nYour public value\n%s\n",BN_bn2hex(info->pub_key),
++   log("My public value\n%s\nYour public value\n%s\n",BN_bn2hex(pub_key),
+        hexdump_buffer(inbuf.peek(0, in_len), in_len, false));
+     int len = DH_compute_key (foo, BN_bin2bn(inbuf.get(in_len), in_len, NULL), 
+ 			      info);
+diff --git a/crypto/wvdigest.cc b/crypto/wvdigest.cc
+index 150edee..73ebb5d 100644
+--- a/crypto/wvdigest.cc
++++ b/crypto/wvdigest.cc
+@@ -13,10 +13,10 @@
+ 
+ /***** WvEVPMDDigest *****/
+ 
+-WvEVPMDDigest::WvEVPMDDigest(const env_md_st *_evpmd) :
++WvEVPMDDigest::WvEVPMDDigest(const EVP_MD*_evpmd) :
+     evpmd(_evpmd), active(false)
+ {
+-    evpctx = new EVP_MD_CTX;
++    evpctx = EVP_MD_CTX_new();
+     _reset();
+ }
+ 
+@@ -24,7 +24,7 @@ WvEVPMDDigest::WvEVPMDDigest(const env_md_st *_evpmd) :
+ WvEVPMDDigest::~WvEVPMDDigest()
+ {
+     cleanup();
+-    delete evpctx;
++    EVP_MD_CTX_free(evpctx);
+ }
+ 
+ 
+@@ -60,7 +60,7 @@ bool WvEVPMDDigest::_reset()
+     // the typecast is necessary for API compatibility with different
+     // versions of openssl.  None of them *actually* change the contents of
+     // the pointer.
+-    EVP_DigestInit(evpctx, (env_md_st *)evpmd);
++    EVP_DigestInit(evpctx, evpmd);
+     active = true;
+     return true;
+ }
+@@ -79,7 +79,7 @@ void WvEVPMDDigest::cleanup()
+ 
+ size_t WvEVPMDDigest::digestsize() const
+ {
+-    return EVP_MD_size((env_md_st *)evpmd);
++    return EVP_MD_size(evpmd);
+ }
+ 
+ 
+@@ -104,14 +104,14 @@ WvHMACDigest::WvHMACDigest(WvEVPMDDigest *_digest,
+ {
+     key = new unsigned char[keysize];
+     memcpy(key, _key, keysize);
+-    hmacctx = new HMAC_CTX;
++    hmacctx = HMAC_CTX_new();
+     _reset();
+ }
+ 
+ WvHMACDigest::~WvHMACDigest()
+ {
+     cleanup();
+-    delete hmacctx;
++    HMAC_CTX_free(hmacctx);
+     deletev key;
+     delete digest;
+ }
+@@ -145,7 +145,7 @@ bool WvHMACDigest::_finish(WvBuf &outbuf)
+ bool WvHMACDigest::_reset()
+ {
+     cleanup();
+-    HMAC_Init(hmacctx, key, keysize, (env_md_st *)digest->getevpmd());
++    HMAC_Init(hmacctx, key, keysize, digest->getevpmd());
+     active = true;
+     return true;
+ }
+diff --git a/crypto/wvocsp.cc b/crypto/wvocsp.cc
+index ddb2de4..7d5da07 100644
+--- a/crypto/wvocsp.cc
++++ b/crypto/wvocsp.cc
+@@ -118,9 +118,10 @@ bool WvOCSPResp::check_nonce(const WvOCSPReq &req) const
+ 
+ bool WvOCSPResp::signedbycert(const WvX509 &cert) const
+ {
+-    EVP_PKEY *skey = X509_get_pubkey(cert.cert);
+-    int i = OCSP_BASICRESP_verify(bs, skey, 0);
+-    EVP_PKEY_free(skey);
++    STACK_OF(X509) *sk = sk_X509_new_null();
++    sk_X509_push(sk, cert.cert);
++    int i = OCSP_basic_verify(bs, sk, NULL, OCSP_NOVERIFY);
++    sk_X509_free(sk);
+ 
+     if(i > 0)
+         return true;
+@@ -131,33 +132,15 @@ bool WvOCSPResp::signedbycert(const WvX509 &cert) const
+ 
+ WvX509 WvOCSPResp::get_signing_cert() const
+ {
+-    if (!bs || !sk_X509_num(bs->certs))
++    const STACK_OF(X509) *certs = OCSP_resp_get0_certs(bs);
++    if (!bs || !sk_X509_num(certs))
+         return WvX509();
+ 
+-    // note: the following bit of code is taken almost verbatim from
+-    // ocsp_vfy.c in OpenSSL 0.9.8. Copyright and attribution should 
+-    // properly belong to them
+-
+-    OCSP_RESPID *id = bs->tbsResponseData->responderId;
+-
+-    if (id->type == V_OCSP_RESPID_NAME)
+-    {
+-        X509 *x = X509_find_by_subject(bs->certs, id->value.byName);
+-        if (x)
+-            return WvX509(X509_dup(x));
++    X509 *signer = NULL;
++    if (OCSP_resp_get0_signer(bs, &signer, NULL) == 1) {
++        return WvX509(X509_dup(signer));
+     }
+ 
+-    if (id->value.byKey->length != SHA_DIGEST_LENGTH) return NULL;
+-    unsigned char tmphash[SHA_DIGEST_LENGTH];
+-    unsigned char *keyhash = id->value.byKey->data;
+-    for (int i = 0; i < sk_X509_num(bs->certs); i++)
+-    {
+-        X509 *x = sk_X509_value(bs->certs, i);
+-        X509_pubkey_digest(x, EVP_sha1(), tmphash, NULL);
+-        if(!memcmp(keyhash, tmphash, SHA_DIGEST_LENGTH))
+-            return WvX509(X509_dup(x));
+-    }
+-    
+     return WvX509();
+ }
+ 
+diff --git a/crypto/wvx509.cc b/crypto/wvx509.cc
+index e4925ce..984156c 100644
+--- a/crypto/wvx509.cc
++++ b/crypto/wvx509.cc
+@@ -974,7 +974,7 @@ static void add_aia(WvStringParm type, WvString identifier,
+     sk_ACCESS_DESCRIPTION_push(ainfo, acc);
+     acc->method = OBJ_txt2obj(type.cstr(), 0);
+     acc->location->type = GEN_URI;
+-    acc->location->d.ia5 = M_ASN1_IA5STRING_new();
++    acc->location->d.ia5 = ASN1_IA5STRING_new();
+     unsigned char *cident 
+ 	= reinterpret_cast<unsigned char *>(identifier.edit());
+     ASN1_STRING_set(acc->location->d.ia5, cident, identifier.len());
+@@ -1059,7 +1059,7 @@ void WvX509::set_crl_urls(WvStringList &urls)
+         GENERAL_NAMES *uris = GENERAL_NAMES_new();
+         GENERAL_NAME *uri = GENERAL_NAME_new();
+         uri->type = GEN_URI;
+-        uri->d.ia5 = M_ASN1_IA5STRING_new();
++        uri->d.ia5 = ASN1_IA5STRING_new();
+         unsigned char *cident
+ 	    = reinterpret_cast<unsigned char *>(i().edit());    
+         ASN1_STRING_set(uri->d.ia5, cident, i().len());
+@@ -1162,10 +1162,11 @@ WvString WvX509::get_extension(int nid) const
+ #else
+             X509V3_EXT_METHOD *method = X509V3_EXT_get(ext);
+ #endif
++            ASN1_OCTET_STRING *ext_data_str = X509_EXTENSION_get_data(ext);
+             if (!method)
+             {
+                 WvDynBuf buf;
+-                buf.put(ext->value->data, ext->value->length);
++                buf.put(ext_data_str->data, ext_data_str->length);
+                 retval = buf.getstr();
+             }
+             else
+@@ -1176,21 +1177,21 @@ WvString WvX509::get_extension(int nid) const
+                 // even though it's const (at least as of version 0.9.8e). 
+                 // gah.
+ #if OPENSSL_VERSION_NUMBER >= 0x0090800fL
+-                const unsigned char * ext_value_data = ext->value->data;
++                const unsigned char * ext_value_data = ext_data_str->data;
+ #else
+                 unsigned char *ext_value_data = ext->value->data;
+ #endif
+                 if (method->it)
+                 {
+                     ext_data = ASN1_item_d2i(NULL, &ext_value_data,
+-                                             ext->value->length, 
++                                             ext_data_str->length, 
+                                              ASN1_ITEM_ptr(method->it));
+                     TRACE("Applied generic conversion!\n");
+                 }
+                 else
+                 {
+                     ext_data = method->d2i(NULL, &ext_value_data,
+-                                           ext->value->length);
++                                           ext_data_str->length);
+                     TRACE("Applied method specific conversion!\n");
+                 }
+                 
+@@ -1325,13 +1326,13 @@ bool WvX509::verify(WvBuf &original, WvStringParm signature) const
+         return false;
+     
+     /* Verify the signature */
+-    EVP_MD_CTX sig_ctx;
+-    EVP_VerifyInit(&sig_ctx, EVP_sha1());
+-    EVP_VerifyUpdate(&sig_ctx, original.peek(0, original.used()),
++    EVP_MD_CTX *sig_ctx = EVP_MD_CTX_new();
++    EVP_VerifyInit(sig_ctx, EVP_sha1());
++    EVP_VerifyUpdate(sig_ctx, original.peek(0, original.used()),
+ 		     original.used());
+-    int sig_err = EVP_VerifyFinal(&sig_ctx, sig_buf, sig_size, pk);
++    int sig_err = EVP_VerifyFinal(sig_ctx, sig_buf, sig_size, pk);
+     EVP_PKEY_free(pk);
+-    EVP_MD_CTX_cleanup(&sig_ctx); // Again, not my fault... 
++    EVP_MD_CTX_free(sig_ctx); // Again, not my fault... 
+     if (sig_err != 1) 
+     {
+         debug("Verify failed!\n");
+@@ -1450,19 +1451,19 @@ void WvX509::set_ski()
+ {
+     CHECK_CERT_EXISTS_SET("ski");
+ 
+-    ASN1_OCTET_STRING *oct = M_ASN1_OCTET_STRING_new();
+-    ASN1_BIT_STRING *pk = cert->cert_info->key->public_key;
++    ASN1_OCTET_STRING *oct = ASN1_OCTET_STRING_new();
++    ASN1_BIT_STRING *pk = X509_get0_pubkey_bitstr(cert);
+     unsigned char pkey_dig[EVP_MAX_MD_SIZE];
+     unsigned int diglen;
+ 
+     EVP_Digest(pk->data, pk->length, pkey_dig, &diglen, EVP_sha1(), NULL);
+ 
+-    M_ASN1_OCTET_STRING_set(oct, pkey_dig, diglen);
++    ASN1_OCTET_STRING_set(oct, pkey_dig, diglen);
+     X509_EXTENSION *ext = X509V3_EXT_i2d(NID_subject_key_identifier, 0, 
+ 					oct);
+     X509_add_ext(cert, ext, -1);
+     X509_EXTENSION_free(ext);
+-    M_ASN1_OCTET_STRING_free(oct);
++    ASN1_OCTET_STRING_free(oct);
+ }
+ 
+ 
+diff --git a/crypto/wvx509mgr.cc b/crypto/wvx509mgr.cc
+index f249eec..156d3a4 100644
+--- a/crypto/wvx509mgr.cc
++++ b/crypto/wvx509mgr.cc
+@@ -350,6 +350,8 @@ bool WvX509Mgr::signcert(WvX509 &unsignedcert) const
+         return false;
+     }
+ 
++    uint32_t ex_flags = X509_get_extension_flags(cert);
++    uint32_t ex_kusage = X509_get_key_usage(cert);
+     if (cert == unsignedcert.cert)
+     {
+ 	debug("Self Signing!\n");
+@@ -362,8 +364,8 @@ bool WvX509Mgr::signcert(WvX509 &unsignedcert) const
+         return false;
+     }
+ #endif
+-    else if (!((cert->ex_flags & EXFLAG_KUSAGE) && 
+-               (cert->ex_kusage & KU_KEY_CERT_SIGN)))
++    else if (!((ex_flags & EXFLAG_KUSAGE) && 
++               (ex_kusage & KU_KEY_CERT_SIGN)))
+     {
+ 	debug("This Certificate is not allowed to sign certificates!\n");
+ 	return false;
+@@ -390,6 +392,8 @@ bool WvX509Mgr::signcert(WvX509 &unsignedcert) const
+ 
+ bool WvX509Mgr::signcrl(WvCRL &crl) const
+ {
++    uint32_t ex_flags = X509_get_extension_flags(cert);
++    uint32_t ex_kusage = X509_get_key_usage(cert);
+     if (!isok() || !crl.isok())
+     {
+         debug(WvLog::Warning, "Asked to sign CRL, but certificate or CRL (or "
+@@ -403,12 +407,12 @@ bool WvX509Mgr::signcrl(WvCRL &crl) const
+               "CRLs!\n");
+         return false;
+     }
+-    else if (!((cert->ex_flags & EXFLAG_KUSAGE) && 
+-	  (cert->ex_kusage & KU_CRL_SIGN)))
++    else if (!((ex_flags & EXFLAG_KUSAGE) && 
++	  (ex_kusage & KU_CRL_SIGN)))
+     {
+ 	debug("Certificate not allowed to sign CRLs! (%s %s)\n", 
+-              (cert->ex_flags & EXFLAG_KUSAGE),
+-	      (cert->ex_kusage & KU_CRL_SIGN));
++              (ex_flags & EXFLAG_KUSAGE),
++	      (ex_kusage & KU_CRL_SIGN));
+ 	return false;
+     }
+ #endif
+@@ -454,7 +458,6 @@ WvString WvX509Mgr::sign(WvBuf &data) const
+ {
+     assert(rsa);
+ 
+-    EVP_MD_CTX sig_ctx;
+     unsigned char sig_buf[4096];
+     
+     EVP_PKEY *pk = EVP_PKEY_new();
+@@ -467,20 +470,22 @@ WvString WvX509Mgr::sign(WvBuf &data) const
+ 	return WvString::null;
+     }
+     
+-    EVP_SignInit(&sig_ctx, EVP_sha1());
+-    EVP_SignUpdate(&sig_ctx, data.peek(0, data.used()), data.used());
++    EVP_MD_CTX *sig_ctx = EVP_MD_CTX_new();
++    EVP_SignInit(sig_ctx, EVP_sha1());
++    EVP_SignUpdate(sig_ctx, data.peek(0, data.used()), data.used());
+     unsigned int sig_len = sizeof(sig_buf);
+-    int sig_err = EVP_SignFinal(&sig_ctx, sig_buf, 
++    int sig_err = EVP_SignFinal(sig_ctx, sig_buf, 
+ 				&sig_len, pk);
+     if (sig_err != 1)
+     {
+ 	debug("Error while signing.\n");
+ 	EVP_PKEY_free(pk);
++	EVP_MD_CTX_free(sig_ctx);
+ 	return WvString::null;
+     }
+ 
+     EVP_PKEY_free(pk);
+-    EVP_MD_CTX_cleanup(&sig_ctx); // this isn't my fault ://
++    EVP_MD_CTX_free(sig_ctx); // this isn't my fault ://
+     WvDynBuf buf;
+     buf.put(sig_buf, sig_len);
+     debug("Signature size: %s\n", buf.used());
+diff --git a/include/wvdiffiehellman.h b/include/wvdiffiehellman.h
+index af75ffa..a2d001f 100644
+--- a/include/wvdiffiehellman.h
++++ b/include/wvdiffiehellman.h
+@@ -27,7 +27,7 @@ public:
+     bool create_secret(WvBuf &inbuf, size_t in_len, WvBuf& outbuf);
+ 
+ protected:
+-    struct dh_st *info;
++    DH *info;
+     BN_ULONG generator;
+ 
+ private:
+diff --git a/include/wvdigest.h b/include/wvdigest.h
+index fdc39bd..f2eed40 100644
+--- a/include/wvdigest.h
++++ b/include/wvdigest.h
+@@ -9,10 +9,8 @@
+ 
+ #include "wvencoder.h"
+ #include <stdint.h>
++#include <openssl/evp.h>
+ 
+-struct env_md_st;
+-struct env_md_ctx_st;
+-struct hmac_ctx_st;
+ 
+ /**
+  * Superclass for all message digests.
+@@ -45,8 +43,8 @@ public:
+ class WvEVPMDDigest : public WvDigest
+ {
+     friend class WvHMACDigest;
+-    const env_md_st *evpmd;
+-    env_md_ctx_st *evpctx;
++    const EVP_MD *evpmd;
++    EVP_MD_CTX *evpctx;
+     bool active;
+ 
+ public:
+@@ -54,13 +52,13 @@ public:
+     virtual size_t digestsize() const;
+ 
+ protected:
+-    WvEVPMDDigest(const env_md_st *_evpmd);
++    WvEVPMDDigest(const EVP_MD *_evpmd);
+     virtual bool _encode(WvBuf &inbuf, WvBuf &outbuf,
+         bool flush); // consumes input
+     virtual bool _finish(WvBuf &outbuf); // outputs digest
+     virtual bool _reset(); // supported: resets digest value
+     
+-    const env_md_st *getevpmd()
++    const EVP_MD *getevpmd()
+         { return evpmd; }
+ 
+ private:
+@@ -104,7 +102,7 @@ class WvHMACDigest : public WvDigest
+     WvEVPMDDigest *digest;
+     unsigned char *key;
+     size_t keysize;
+-    hmac_ctx_st *hmacctx;
++    HMAC_CTX *hmacctx;
+     bool active;
+ 
+ public:
+diff --git a/include/wvtripledes.h b/include/wvtripledes.h
+index 185fe8a..a442e7a 100644
+--- a/include/wvtripledes.h
++++ b/include/wvtripledes.h
+@@ -70,11 +70,11 @@ protected:
+ 
+ private:
+     Mode mode;
+-    des_cblock key;
+-    des_key_schedule deskey1;
+-    des_key_schedule deskey2;
+-    des_key_schedule deskey3;
+-    des_cblock ivec; // initialization vector
++    DES_cblock key;
++    DES_key_schedule deskey1;
++    DES_key_schedule deskey2;
++    DES_key_schedule deskey3;
++    DES_cblock ivec; // initialization vector
+     int ivecoff; // current offset into initvec
+ };
+ 
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/05_gcc.diff b/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/05_gcc.diff
index 8e4fd03..616843d 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/05_gcc.diff
+++ b/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/05_gcc.diff
@@ -1,16 +1,3 @@
-Index: wvstreams-4.6.1/crypto/wvx509.cc
-===================================================================
---- wvstreams-4.6.1.orig/crypto/wvx509.cc	2011-05-20 00:02:38.119136584 +0200
-+++ wvstreams-4.6.1/crypto/wvx509.cc	2011-05-20 00:02:26.035136589 +0200
-@@ -1157,7 +1157,7 @@
-         
-         if (ext)
-         {
--            X509V3_EXT_METHOD *method = X509V3_EXT_get(ext);
-+            X509V3_EXT_METHOD *method = (X509V3_EXT_METHOD *)X509V3_EXT_get(ext);
-             if (!method)
-             {
-                 WvDynBuf buf;
 Index: wvstreams-4.6.1/ipstreams/wvunixdgsocket.cc
 ===================================================================
 --- wvstreams-4.6.1.orig/ipstreams/wvunixdgsocket.cc	2011-05-20 00:02:38.391136584 +0200
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/openssl-buildfix.patch b/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/openssl-buildfix.patch
new file mode 100644
index 0000000..1c7005c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/openssl-buildfix.patch
@@ -0,0 +1,16 @@
+Index: wvstreams-4.6.1/crypto/wvx509.cc
+===================================================================
+--- wvstreams-4.6.1.orig/crypto/wvx509.cc
++++ wvstreams-4.6.1/crypto/wvx509.cc
+@@ -1157,7 +1157,11 @@ WvString WvX509::get_extension(int nid)
+         
+         if (ext)
+         {
++#if OPENSSL_VERSION_NUMBER >= 0x10000000L
++            const X509V3_EXT_METHOD *method = X509V3_EXT_get(ext);
++#else
+             X509V3_EXT_METHOD *method = X509V3_EXT_get(ext);
++#endif
+             if (!method)
+             {
+                 WvDynBuf buf;
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams_4.6.1.bb b/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams_4.6.1.bb
index e3d5e7d..b9f62da 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams_4.6.1.bb
+++ b/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams_4.6.1.bb
@@ -21,6 +21,8 @@
            file://0005-check-for-libexecinfo-during-configure.patch \
            file://0001-build-fix-parallel-make.patch \
            file://0002-wvrules.mk-Use-_DEFAULT_SOURCE.patch \
+           file://openssl-buildfix.patch \
+           file://0001-Forward-port-to-OpenSSL-1.1.x.patch \
            "
 
 SRC_URI[md5sum] = "2760dac31a43d452a19a3147bfde571c"
@@ -34,23 +36,21 @@
 
 EXTRA_OECONF = " --without-tcl --without-qt --without-pam --without-valgrind"
 
-PACKAGES_prepend = "libuniconf libuniconf-dbg "
-PACKAGES_prepend = "uniconfd uniconfd-dbg "
-PACKAGES_prepend = "libwvstreams-base libwvstreams-base-dbg "
-PACKAGES_prepend = "libwvstreams-extras libwvstreams-extras-dbg "
+PACKAGES_prepend = "libuniconf "
+PACKAGES_prepend = "uniconfd "
+PACKAGES_prepend = "libwvstreams-base "
+PACKAGES_prepend = "libwvstreams-extras "
 PACKAGES_prepend = "${PN}-valgrind "
 
+RPROVIDES_${PN}-dbg += "libuniconf-dbg uniconfd-dbg libwvstreams-base-dbg libwvstreams-extras-dbg"
+
 FILES_libuniconf     = "${libdir}/libuniconf.so.*"
-FILES_libuniconf-dbg = "${libdir}/.debug/libuniconf.so.*"
 
 FILES_uniconfd     = "${sbindir}/uniconfd ${sysconfdir}/uniconf.conf ${localstatedir}/uniconf"
-FILES_uniconfd-dbg = "${sbindir}/.debug/uniconfd"
 
 FILES_libwvstreams-base     = "${libdir}/libwvutils.so.*"
-FILES_libwvstreams-base-dbg = "${libdir}/.debug/libwvutils.so.*"
 
 FILES_libwvstreams-extras     = "${libdir}/libwvbase.so.* ${libdir}/libwvstreams.so.*"
-FILES_libwvstreams-extras-dbg = "${libdir}/.debug/libwvbase.so.* ${libdir}/.debug/libwvstreams.so.*"
 
 FILES_${PN}-valgrind = "${libdir}/valgrind/wvstreams.supp"
 RDEPENDS_${PN} += "perl"
diff --git a/meta-openembedded/meta-oe/recipes-connectivity/zeromq/cppzmq_git.bb b/meta-openembedded/meta-oe/recipes-connectivity/zeromq/cppzmq_git.bb
index 4920bce..9aff59c 100644
--- a/meta-openembedded/meta-oe/recipes-connectivity/zeromq/cppzmq_git.bb
+++ b/meta-openembedded/meta-oe/recipes-connectivity/zeromq/cppzmq_git.bb
@@ -11,10 +11,7 @@
 
 S = "${WORKDIR}/git"
 
-do_install () {
-        install -d ${D}/usr/include
-        install -m 0755 ${S}/zmq.hpp ${D}/usr/include/
-}
+inherit cmake
 
 PACKAGES = "${PN}-dev"
 
diff --git a/meta-openembedded/meta-oe/recipes-core/ell/ell/0001-dhcp-include-if_arp.h-from-libc-instead-of-linux-hea.patch b/meta-openembedded/meta-oe/recipes-core/ell/ell/0001-dhcp-include-if_arp.h-from-libc-instead-of-linux-hea.patch
new file mode 100644
index 0000000..ada6540
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-core/ell/ell/0001-dhcp-include-if_arp.h-from-libc-instead-of-linux-hea.patch
@@ -0,0 +1,39 @@
+From d8236d1d789f496a193dae5d2a15d706b81f6482 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Martin=20Hundeb=C3=B8ll?= <martin@geanix.com>
+Date: Thu, 12 Jul 2018 10:19:50 +0200
+Subject: [PATCH] dhcp: include if_arp.h from libc instead of linux headers
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+To: ell@lists.01.org
+
+Compilation with musl libc fails due to redefinition of 'struct
+arp{req,req_old,hdr}' in linux/if_arp.h, since it is already defined and
+included in net/if_arp.h (through net/ethernet.h -> net/if_ether.h).
+
+The only symbols used from if_arp.h is ARPHRD_ETHER, so it should be
+safe to avoid the compile error by including the if_arp.h header from
+the c-library instead.
+
+Upstream-Status: Backport [https://lists.01.org/pipermail/ell/2018-July/001244.html]
+Signed-off-by: Martin Hundebøll <martin@geanix.com>
+---
+ ell/dhcp.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/ell/dhcp.c b/ell/dhcp.c
+index 6c90370..0d99f74 100644
+--- a/ell/dhcp.c
++++ b/ell/dhcp.c
+@@ -27,7 +27,7 @@
+ #include <netinet/ip.h>
+ #include <net/ethernet.h>
+ #include <linux/types.h>
+-#include <linux/if_arp.h>
++#include <net/if_arp.h>
+ #include <errno.h>
+ #include <time.h>
+ 
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-oe/recipes-core/ell/ell/0001-ell-fix-build-with-musl-libc.patch b/meta-openembedded/meta-oe/recipes-core/ell/ell/0001-ell-fix-build-with-musl-libc.patch
deleted file mode 100644
index a172a93..0000000
--- a/meta-openembedded/meta-oe/recipes-core/ell/ell/0001-ell-fix-build-with-musl-libc.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From 4f8c68757b05d12392cd1a8aed174cb8e56f80e3 Mon Sep 17 00:00:00 2001
-From: "Maxin B. John" <maxin.john@intel.com>
-Date: Thu, 5 Apr 2018 17:19:44 +0300
-Subject: [PATCH] ell: fix build with musl libc
-
-musl libc doesn't implement TEMP_FAILURE_RETRY. Use the
-TEMP_FAILURE_RETRY from glibc to fix build.
-
-Upstream-Status: Submitted [https://lists.01.org/pipermail/ell/2018-April/001209.html]
-
-Signed-off-by: Maxin B. John <maxin.john@intel.com>
----
- ell/dbus.h | 10 ++++++++++
- 1 file changed, 10 insertions(+)
-
-diff --git a/ell/dbus.h b/ell/dbus.h
-index a7c08d2..3ff5e0f 100644
---- a/ell/dbus.h
-+++ b/ell/dbus.h
-@@ -28,6 +28,16 @@
- #include <stddef.h>
- #include <stdarg.h>
- 
-+/* taken from glibc unistd.h for musl support */
-+#ifndef TEMP_FAILURE_RETRY
-+#define TEMP_FAILURE_RETRY(expression)             \
-+  (__extension__                                   \
-+    ({ long int __result;                          \
-+       do __result = (long int) (expression);      \
-+       while (__result == -1L && errno == EINTR);  \
-+       __result; }))
-+#endif
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
--- 
-2.4.0
-
diff --git a/meta-openembedded/meta-oe/recipes-core/ell/ell_0.4.bb b/meta-openembedded/meta-oe/recipes-core/ell/ell_0.4.bb
deleted file mode 100644
index 1524bd6..0000000
--- a/meta-openembedded/meta-oe/recipes-core/ell/ell_0.4.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-SUMMARY  = "Embedded Linux Library"
-DESCRIPTION = "ELL is a DBUS library which provides DBUS bindings."
-LICENSE  = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=fb504b67c50331fc78734fed90fb0e09"
-SECTION = "libs"
-
-inherit autotools pkgconfig
-
-S = "${WORKDIR}/git"
-SRCREV = "b4aea06fabb2af1af01f861f8f394c75950b6d47"
-SRC_URI = "git://git.kernel.org/pub/scm/libs/ell/ell.git \
-           file://0001-ell-fix-build-with-musl-libc.patch \
-          "
-
-do_configure_prepend () {
-    mkdir ${S}/build-aux
-}
-
-DEPENDS = "dbus"
diff --git a/meta-openembedded/meta-oe/recipes-core/ell/ell_0.8.bb b/meta-openembedded/meta-oe/recipes-core/ell/ell_0.8.bb
new file mode 100644
index 0000000..0428cab
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-core/ell/ell_0.8.bb
@@ -0,0 +1,17 @@
+SUMMARY  = "Embedded Linux Library"
+DESCRIPTION = "ELL is a DBUS library which provides DBUS bindings."
+LICENSE  = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=fb504b67c50331fc78734fed90fb0e09"
+SECTION = "libs"
+
+inherit autotools pkgconfig
+
+S = "${WORKDIR}/git"
+SRCREV = "d572281caedef357c392a7c9aa65a3b21a18cfdb"
+SRC_URI = "git://git.kernel.org/pub/scm/libs/ell/ell.git"
+
+do_configure_prepend () {
+    mkdir -p ${S}/build-aux
+}
+
+DEPENDS = "dbus"
diff --git a/meta-openembedded/meta-oe/recipes-core/glib-2.0/glibmm/0001-Glib-Threads-Private-Fix-gobj.patch b/meta-openembedded/meta-oe/recipes-core/glib-2.0/glibmm/0001-Glib-Threads-Private-Fix-gobj.patch
deleted file mode 100644
index 7899022..0000000
--- a/meta-openembedded/meta-oe/recipes-core/glib-2.0/glibmm/0001-Glib-Threads-Private-Fix-gobj.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From 838fe84c2ddcc9af51c34f751defbf3dd0ba8a06 Mon Sep 17 00:00:00 2001
-From: Kjell Ahlstedt <kjellahlstedt@gmail.com>
-Date: Wed, 20 Dec 2017 20:00:32 +0100
-Subject: [PATCH] Glib::Threads::Private: Fix gobj()
-
-Bug 791711
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Backport [https://github.com/GNOME/glibmm/commit/37d57ae9572b7d74aa385a30313eceae7f2d3fce]
- glib/glibmm/threads.h | 2 +-
- glib/src/threads.hg   | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/glib/glibmm/threads.h b/glib/glibmm/threads.h
-index f7e2b82a..2c0cbe8c 100644
---- a/glib/glibmm/threads.h
-+++ b/glib/glibmm/threads.h
-@@ -657,7 +657,7 @@ public:
-    */
-   inline void replace(T* data);
- 
--  GPrivate* gobj() { return gobject_; }
-+  GPrivate* gobj() { return &gobject_; }
- 
- private:
-   GPrivate gobject_;
-diff --git a/glib/src/threads.hg b/glib/src/threads.hg
-index 86d7a17b..c82a6130 100644
---- a/glib/src/threads.hg
-+++ b/glib/src/threads.hg
-@@ -628,7 +628,7 @@ public:
-    */
-   inline void replace(T* data);
- 
--  GPrivate* gobj() { return gobject_; }
-+  GPrivate* gobj() { return &gobject_; }
- 
- private:
-   GPrivate gobject_;
diff --git a/meta-openembedded/meta-oe/recipes-core/glib-2.0/glibmm_2.54.1.bb b/meta-openembedded/meta-oe/recipes-core/glib-2.0/glibmm_2.54.1.bb
deleted file mode 100644
index 4706432..0000000
--- a/meta-openembedded/meta-oe/recipes-core/glib-2.0/glibmm_2.54.1.bb
+++ /dev/null
@@ -1,37 +0,0 @@
-SUMMARY = "C++ bindings for the glib library"
-HOMEPAGE = "http://www.gtkmm.org/"
-SECTION = "libs"
-LICENSE = "LGPLv2.1 & GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=42dfffebc56fec7527aac53b7a89d1d8 \
-                    file://COPYING.tools;md5=751419260aa954499f7abaabaa882bbe"
-
-DEPENDS = "mm-common glib-2.0 libsigc++-2.0 glib-2.0-native"
-inherit autotools pkgconfig
-
-SHRT_VER = "${@d.getVar('PV').split('.')[0]}.${@d.getVar('PV').split('.')[1]}"
-
-SRC_URI = " \
-    ftp://ftp.gnome.org/pub/GNOME/sources/glibmm/${SHRT_VER}/glibmm-${PV}.tar.xz \
-    file://remove-examples.patch \
-    file://0001-Glib-Threads-Private-Fix-gobj.patch \
-"
-SRC_URI[md5sum] = "dee5ebe309f5976c3dacfcf5c43a062b"
-SRC_URI[sha256sum] = "7cc28c732b04d70ed34f0c923543129083cfb90580ea4a2b4be5b38802bf6a4a"
-
-do_install_append() {
-    install -d ${D}${datadir}/glibmm-2.4
-    install -d ${D}${datadir}/aclocal
-
-    install -m 0644 glib/glibmmconfig.h ${D}${datadir}/glibmm-2.4/
-    install -m 0644 scripts/glibmm_check_perl.m4 ${D}${datadir}/aclocal/ || true
-
-    for i in generate_wrap_init.pl gmmproc; do
-        sed -i -e '1s,.*,#!${bindir}/env perl,' ${D}${libdir}/glibmm-2.4/proc/$i
-    done
-}
-
-FILES_${PN} = "${libdir}/lib*.so.*"
-FILES_${PN}-dev += "${datadir}/glibmm-* ${libdir}/glibmm-2.4/include/ ${libdir}/glibmm-2.4/proc/ ${libdir}/giomm-2.4/include/"
-
-RDEPENDS_${PN}-dev = "perl"
-SECURITY_CFLAGS = "${SECURITY_NO_PIE_CFLAGS}"
diff --git a/meta-openembedded/meta-oe/recipes-core/glib-2.0/glibmm_2.56.0.bb b/meta-openembedded/meta-oe/recipes-core/glib-2.0/glibmm_2.56.0.bb
new file mode 100644
index 0000000..2f048d2
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-core/glib-2.0/glibmm_2.56.0.bb
@@ -0,0 +1,36 @@
+SUMMARY = "C++ bindings for the glib library"
+HOMEPAGE = "http://www.gtkmm.org/"
+SECTION = "libs"
+LICENSE = "LGPLv2.1 & GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=42dfffebc56fec7527aac53b7a89d1d8 \
+                    file://COPYING.tools;md5=751419260aa954499f7abaabaa882bbe"
+
+DEPENDS = "mm-common glib-2.0 libsigc++-2.0 glib-2.0-native"
+inherit autotools pkgconfig
+
+SHRT_VER = "${@d.getVar('PV').split('.')[0]}.${@d.getVar('PV').split('.')[1]}"
+
+SRC_URI = " \
+    ftp://ftp.gnome.org/pub/GNOME/sources/glibmm/${SHRT_VER}/glibmm-${PV}.tar.xz \
+    file://remove-examples.patch \
+"
+SRC_URI[md5sum] = "5aa7a60084fe3e01d746c96f4a115302"
+SRC_URI[sha256sum] = "6e74fcba0d245451c58fc8a196e9d103789bc510e1eee1a9b1e816c5209e79a9"
+
+do_install_append() {
+    install -d ${D}${datadir}/glibmm-2.4
+    install -d ${D}${datadir}/aclocal
+
+    install -m 0644 glib/glibmmconfig.h ${D}${datadir}/glibmm-2.4/
+    install -m 0644 scripts/glibmm_check_perl.m4 ${D}${datadir}/aclocal/ || true
+
+    for i in generate_wrap_init.pl gmmproc; do
+        sed -i -e '1s,.*,#!${bindir}/env perl,' ${D}${libdir}/glibmm-2.4/proc/$i
+    done
+}
+
+FILES_${PN} = "${libdir}/lib*.so.*"
+FILES_${PN}-dev += "${datadir}/glibmm-* ${libdir}/glibmm-2.4/include/ ${libdir}/glibmm-2.4/proc/ ${libdir}/giomm-2.4/include/"
+
+RDEPENDS_${PN}-dev = "perl"
+SECURITY_CFLAGS = "${SECURITY_NO_PIE_CFLAGS}"
diff --git a/meta-openembedded/meta-oe/recipes-core/images/meta-oe-image-base.bb b/meta-openembedded/meta-oe/recipes-core/images/meta-oe-image-base.bb
new file mode 100644
index 0000000..df92f16
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-core/images/meta-oe-image-base.bb
@@ -0,0 +1,7 @@
+SUMMARY = "meta-oe build test image"
+
+IMAGE_INSTALL = "packagegroup-core-boot"
+
+LICENSE = "MIT"
+
+inherit core-image
diff --git a/meta-openembedded/meta-oe/recipes-core/images/meta-oe-image.bb b/meta-openembedded/meta-oe/recipes-core/images/meta-oe-image.bb
new file mode 100644
index 0000000..1565549
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-core/images/meta-oe-image.bb
@@ -0,0 +1,5 @@
+require  meta-oe-image-base.bb
+
+SUMMARY = "meta-oe build test image"
+
+IMAGE_INSTALL += "packagegroup-meta-oe"
diff --git a/meta-openembedded/meta-oe/recipes-core/images/meta-oe-ptest-image.bb b/meta-openembedded/meta-oe/recipes-core/images/meta-oe-ptest-image.bb
new file mode 100644
index 0000000..0166b9c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-core/images/meta-oe-ptest-image.bb
@@ -0,0 +1,5 @@
+require  meta-oe-image-base.bb
+
+SUMMARY = "meta-oe ptest test image"
+
+IMAGE_INSTALL += "packagegroup-meta-oe"
diff --git a/meta-openembedded/meta-oe/recipes-core/mm-common/mm-common_0.9.11.bb b/meta-openembedded/meta-oe/recipes-core/mm-common/mm-common_0.9.11.bb
deleted file mode 100644
index 591caa7..0000000
--- a/meta-openembedded/meta-oe/recipes-core/mm-common/mm-common_0.9.11.bb
+++ /dev/null
@@ -1,9 +0,0 @@
-inherit gnomebase
-
-SRC_URI[archive.md5sum] = "d6f2a43589480d2315672da0b5839b56"
-SRC_URI[archive.sha256sum] = "20d1e7466ca4c83c92e29f9e8dfcc8e5721fdf1337f53157bed97be3b73b32a8"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-core/mm-common/mm-common_0.9.12.bb b/meta-openembedded/meta-oe/recipes-core/mm-common/mm-common_0.9.12.bb
new file mode 100644
index 0000000..4f91f31
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-core/mm-common/mm-common_0.9.12.bb
@@ -0,0 +1,9 @@
+inherit gnomebase
+
+SRC_URI[archive.md5sum] = "be1c61587db989c7677375a729b94672"
+SRC_URI[archive.sha256sum] = "ceffdcce1e5b52742884c233ec604bf6fded12eea9da077ce7a62c02c87e7c0b"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-core/ndctl/ndctl_git.bb b/meta-openembedded/meta-oe/recipes-core/ndctl/ndctl_git.bb
new file mode 100644
index 0000000..048f166
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-core/ndctl/ndctl_git.bb
@@ -0,0 +1,33 @@
+SUMMARY = "libnvdimm utility library"
+DESCRIPTION = "Utility library for managing the libnvdimm \
+(non-volatile memory device) sub-system in the Linux kernel. \
+The LIBNVDIMM subsystem provides support for three types of \
+NVDIMMs, namely,PMEM, BLK, and NVDIMM devices that can \
+simultaneously support both PMEM and BLK mode access."
+HOMEPAGE = "https://git.kernel.org/cgit/linux/kernel/git/nvdimm/nvdimm.git/tree/Documentation/nvdimm/nvdimm.txt?h=libnvdimm-for-next"
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=e66651809cac5da60c8b80e9e4e79e08"
+
+inherit autotools-brokensep pkgconfig module-base bash-completion systemd
+
+# v62
+SRCREV = "11f560f4048c1d38b7011a49566871a1e8a07c94"
+SRC_URI = "git://github.com/pmem/ndctl.git"
+
+DEPENDS = "virtual/kernel kmod udev json-c"
+
+PV = "v62+git${SRCPV}"
+S = "${WORKDIR}/git"
+
+EXTRA_OECONF += "--enable-test --enable-destructive --disable-docs"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[systemd] = "--with-systemd-unit-dir=${systemd_system_unitdir}, --without-systemd-unit-dir,"
+
+do_configure_prepend() {
+    ${S}/autogen.sh
+}
+
+SYSTEMD_SERVICE_${PN} = "ndctl-monitor.service"
+
+COMPATIBLE_HOST='(x86_64).*'
diff --git a/meta-openembedded/meta-oe/recipes-core/opencl-headers/opencl-headers_git.bb b/meta-openembedded/meta-oe/recipes-core/opencl-headers/opencl-headers_git.bb
new file mode 100644
index 0000000..dec1bea
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-core/opencl-headers/opencl-headers_git.bb
@@ -0,0 +1,17 @@
+SUMMARY  = "OpenCL API Headers"
+DESCRIPTION = "OpenCL compute API headers from Khronos Group"
+LICENSE  = "Khronos"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=dcefc90f4c3c689ec0c2489064e7273b"
+SECTION = "base"
+
+S = "${WORKDIR}/git"
+SRCREV = "40c5d226c7c0706f0176884e9b94b3886679c983"
+SRC_URI = "git://github.com/KhronosGroup/OpenCL-Headers.git"
+
+do_configure[noexec] = "1"
+do_compile[noexec] = "1"
+
+do_install () {
+	install -d ${D}${includedir}/CL/
+	install -m 0644 ${S}/CL/*.h ${D}${includedir}/CL
+}
diff --git a/meta-openembedded/meta-oe/recipes-core/opencl-icd-loader/opencl-icd-loader_git.bb b/meta-openembedded/meta-oe/recipes-core/opencl-icd-loader/opencl-icd-loader_git.bb
new file mode 100644
index 0000000..7c49c8d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-core/opencl-icd-loader/opencl-icd-loader_git.bb
@@ -0,0 +1,45 @@
+SUMMARY  = "OpenCL ICD Loader"
+DESCRIPTION = "OpenCL compute ICD Loader from Khronos Group"
+LICENSE  = "Khronos"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=ec724732ce73269486574c718ef0c79b"
+SECTION = "base"
+
+inherit pkgconfig cmake
+
+S = "${WORKDIR}/git"
+SRCREV = "b342ff7b7f70a4b3f2cfc53215af8fa20adc3d86"
+SRC_URI = "git://github.com/KhronosGroup/OpenCL-ICD-Loader.git"
+
+do_install () {
+	install -d ${D}${bindir}
+	install -m 0755 ${B}/bin/icd_loader_test ${D}${bindir}/
+	chrpath -d ${D}${bindir}/icd_loader_test
+	install -d ${D}${libdir}
+	install -m 0644 ${B}/lib/libIcdLog.so ${D}${libdir}/
+	install -m 0644 ${B}/lib/libOpenCLDriverStub.so ${D}${libdir}/
+	chrpath -d ${D}${libdir}/libOpenCLDriverStub.so
+	install -m 0644 ${B}/lib/libOpenCL.so.1.2 ${D}${libdir}/
+	cd ${D}${libdir}
+	ln -s libOpenCL.so.1.2 libOpenCL.so.1
+	ln -s libOpenCL.so.1 libOpenCL.so
+}
+
+PACKAGES = "opencl-icd-loader opencl-icd-loader-dev"
+PACKAGES += "libicdlog libicdlog-dbg"
+PACKAGE_DEBUG_SPLIT_STYLE = "debug-without-src"
+
+FILES_${PN} = " \
+	${bindir}/icd_loader_test \
+	${libdir}/libOpenCLDriverStub.so \
+	${libdir}/libOpenCL.so.1.2 \
+"
+FILES_${PN}-dev = " \
+	${libdir}/libOpenCL.so \
+	${libdir}/libOpenCL.so.1 \
+"
+
+FILES_libicdlog = "${libdir}/libIcdLog.so"
+FILES_libicdlog-dbg = "${libdir}/.debug/libIcdLog.so"
+
+DEPENDS = "opencl-headers"
+RDEPENDS_${PN} = "libicdlog"
diff --git a/meta-openembedded/meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb b/meta-openembedded/meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb
new file mode 100644
index 0000000..08b4bbf
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb
@@ -0,0 +1,253 @@
+SUMMARY = "Meta-oe ptest packagegroups"
+
+inherit packagegroup
+
+PROVIDES = "${PACKAGES}"
+PACKAGES = ' \
+    packagegroup-meta-oe \
+    packagegroup-meta-oe-benchmarks \
+    packagegroup-meta-oe-connectivity \
+    packagegroup-meta-oe-core \
+    packagegroup-meta-oe-crypto \
+    packagegroup-meta-oe-bsp \
+    packagegroup-meta-oe-dbs \
+    packagegroup-meta-oe-devtools \
+    packagegroup-meta-oe-extended \
+    packagegroup-meta-oe-kernel \
+    packagegroup-meta-oe-multimedia \
+    packagegroup-meta-oe-navigation \
+    packagegroup-meta-oe-security \
+    packagegroup-meta-oe-support \
+    packagegroup-meta-oe-test \
+    ${@bb.utils.contains("DISTRO_FEATURES", "x11", "packagegroup-meta-oe-gnome", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "x11", "packagegroup-meta-oe-graphics", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "ptest", "packagegroup-meta-oe-ptest", "", d)} \
+'
+
+RDEPENDS_packagegroup-meta-oe = "\
+    packagegroup-meta-oe-benchmarks \
+    packagegroup-meta-oe-connectivity \
+    packagegroup-meta-oe-core \
+    packagegroup-meta-oe-crypto \
+    packagegroup-meta-oe-bsp \
+    packagegroup-meta-oe-dbs \
+    packagegroup-meta-oe-devtools \
+    packagegroup-meta-oe-extended \
+    packagegroup-meta-oe-kernel \
+    packagegroup-meta-oe-multimedia \
+    packagegroup-meta-oe-navigation \
+    packagegroup-meta-oe-security \
+    packagegroup-meta-oe-support \
+    packagegroup-meta-oe-test \
+    ${@bb.utils.contains("DISTRO_FEATURES", "x11", "packagegroup-meta-oe-gnome", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "x11", "packagegroup-meta-oe-graphics", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "ptest", "packagegroup-meta-oe-ptest", "", d)} \
+"
+
+RDEPENDS_packagegroup-meta-oe-benchmarks = "\
+    analyze-suspend dhrystone iperf2 linpack phoronix-test-suite \
+    tiobench bonnie++ fio iperf2 iperf3 lmbench s-suite whetstone \
+    libc-bench memtester sysbench dbench iozone3 libhugetlbfs \
+    nbench-byte tinymembench \
+    ${@bb.utils.contains("DISTRO_FEATURES", "x11 wayland opengl", "glmark2", "", d)} \
+"
+
+RDEPENDS_packagegroup-meta-oe-connectivity ="\
+    gammu hostapd irssi krb5 libev libimobiledevice \
+    libmbim libmtp libndp libqmi libtorrent \
+    libuv libwebsockets linuxptp lirc loudmouth \
+    modemmanager mosh  \
+    paho-mqtt-c phonet-utils rabbitmq-c rfkill rtorrent \
+    ser2net smstools3 telepathy-glib telepathy-idle thrift \
+    usbmuxd wvstreams zabbix zeromq \
+    ${@bb.utils.contains("DISTRO_FEATURES", "x11", "obex-data-server", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "pulseadio bluez4", "libmikmod", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "bluez4", "obexftp openobex libnet wvdial", "", d)} \
+    "
+
+# dracut needs dracut
+RDEPENDS_packagegroup-meta-oe-core ="\
+    dbus-daemon-proxy libdbus-c++ eggdbus \
+    ell glibmm libsigc++-2.0 libxml++ distro-feed-configs \
+    mm-common opencl-headers opencl-icd-loader \
+    proxy-libintl usleep \
+    ${@bb.utils.contains("DISTRO_FEATURES", "systemd", "dbus-broker ndctl", "", d)} \
+    "
+
+RDEPENDS_packagegroup-meta-oe-crypto ="\
+    botan cryptsetup libkcapi libmcrypt \
+    libsodium pkcs11-helper \
+    "
+RDEPENDS_packagegroup-meta-oe-bsp ="\
+    acpitool cpufrequtils edac-utils efibootmgr \
+    efivar flashrom lmsensors lmsensors-config \
+    lsscsi nvme-cli pcmciautils pointercal \
+    "
+RDEPENDS_packagegroup-meta-oe-dbs ="\
+    leveldb libdbi mariadb mariadb-native \
+    mysql-python postgresql psqlodbc rocksdb soci \
+    sqlite \
+    ${@bb.utils.contains("DISTRO_FEATURES", "bluez4", "mongodb", "", d)} \
+    "
+
+RDEPENDS_packagegroup-meta-oe-devtools ="\
+    android-tools android-tools-conf bootchart breakpad \
+    capnproto cgdb cscope ctags \
+    debootstrap dejagnu dmalloc flatbuffers \
+    giflib icon-slicer iptraf-ng jq jsoncpp jsonrpc json-spirit \
+    kconfig-frontends lemon libedit libgee libsombok3 \
+    libubox log4cplus lshw ltrace lua mcpp memstat mercurial \
+    mpich msgpack-c nlohmann-json nodejs openocd pax-utils \
+    ipc-run libdbd-mysql-perl libdbi-perl libio-pty-perl php \
+    protobuf protobuf-c python3-distutils-extra \
+    python-cpuset python-distutils-extra python-futures python-pygobject \
+    rapidjson serialcheck sip3 sip tclap uftrace uw-imap valijson \
+    xmlrpc-c yajl yasm \
+    ${@bb.utils.contains("DISTRO_FEATURES", "x11", "geany geany-plugins glade tk", "", d)} \
+    "
+
+RDEPENDS_packagegroup-meta-oe-extended ="\
+    byacc cfengine cfengine-masterfiles cmpi-bindings \
+    ddrescue dialog dumb-init enscript fluentbit \
+    haveged hexedit hiredis hplip hwloc indent iotop isomd5sum \
+    jansson konkretcmpi lcdproc libblockdev libcec libconfig \
+    libdivecomputer libplist libusbmuxd \
+    liblockfile liblogging liblognorm libmodbus libmodbus \
+    libpwquality libqb libuio \
+    lockfile-progs logwatch lprng mailx md5deep \
+    mozjs mraa nana nicstat \
+    p7zip p8platform libfile-fnmatch-perl polkit \
+    polkit-group-rule-datetime polkit-group-rule-network \
+    rarpd redis rrdtool libfastjson librelp rsyslog sanlock \
+    sblim-cmpi-devel sblim-sfc-common sblim-sfcc \
+    scsirastools sgpio smartmontools snappy can-isotp \
+    can-utils libsocketcan tipcutils tiptop \
+    tmux uml-utilities upm vlock volume-key wipe zlog zram \
+    ${@bb.utils.contains("DISTRO_FEATURES", "x11 wayland opengl", "boinc-client", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "x11", " libgxim t1lib gnuplot libwmf gtkmathview", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "bluez", "collectd", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "pam", "pam-plugin-ccreds pam-plugin-ldapdb", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "pam", "pam-ssh-agent-auth openwsman sblim-sfcb ", "", d)} \
+    ${@bb.utils.contains("BBPATH", "meta-python", "openlmi-tools", "", d)} \
+    "
+
+RDEPENDS_packagegroup-meta-oe-gnome ="\
+    atkmm gnome-common gnome-doc-utils-stub gtkmm \
+    gtkmm3 pyxdg vte9 \
+    "
+
+RDEPENDS_packagegroup-meta-oe-graphics ="\
+    babl cairomm dietsplash directfb directfb-examples dnfdragora \
+    fbgrab fbida fontforge fvwm gegl gimp glm gphoto2 libgphoto2 \
+    gtkperf jasper leptonica libmng libsdl2-image libsdl2-mixer libsdl2-net \
+    libsdl-gfx libsdl-image libsdl-mixer libsdl-net libsdl-ttf \
+    libvncserver libyui libyui-ncurses lxdm numlockx openbox openjpeg \
+    packagegroup-fonts-truetype pangomm qrencode takao-fonts terminus-font \
+    tesseract tesseract-lang tigervnc tslib source-han-sans-cn-fonts \
+    source-han-sans-jp-fonts source-han-sans-kr-fonts source-han-sans-tw-fonts ttf-abyssinica \
+    libvdpau x11vnc xcursorgen xdotool \
+    bdftopcf iceauth sessreg setxkbmap twm xclock xfontsel xgamma xkbevd xkbprint xkbutils \
+    xlsatoms xlsclients xlsfonts xmag xmessage xrdb xrefresh xsetmode xsetroot xstdcmap \
+    xterm xwd xwud xbitmaps xorg-sgml-doctools \
+    font-adobe-100dpi font-adobe-utopia-100dpi \
+    font-bh-100dpi font-bh-lucidatypewriter-100dpi font-bitstream-100dpi font-cursor-misc \
+    font-misc-misc xorg-fonts-100dpi liblbxutil libxaw libxkbui libxpresent xserver-common \
+    ${@bb.utils.contains("DISTRO_FEATURES", "opengl", "freeglut libsdl2-ttf", "", d)} \
+    "
+
+RDEPENDS_packagegroup-meta-oe-kernel ="\
+    agent-proxy bpftool broadcom-bt-firmware cpupower \
+    crash ipmitool minicoredumper oprofile \
+    "
+
+RDEPENDS_packagegroup-meta-oe-multimedia ="\
+    alsa-oss audiofile cdrkit esound id3lib \
+    a2jmidid jack libass libburn libcdio libcdio-paranoia \
+    libdvdread libmms libmodplug libopus live555 \
+    mplayer-common opus-tools \
+    sound-theme-freedesktop v4l-utils yavta wavpack libvpx \
+    ${@bb.utils.contains("DISTRO_FEATURES", "x11", "xpext pavucontrol xsp", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "pulseadio bluez4", "libmikmod", "", d)} \
+    ${@bb.utils.contains("LICENSE_FLAGS_WHITELIST", "commercial", "libmad faad2 mpv", "", d)} \
+    "
+
+RDEPENDS_packagegroup-meta-oe-navigation ="\
+    geoclue geos libspatialite proj \
+    ${@bb.utils.contains("DISTRO_FEATURES", "x11", "orrery", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "bluz4", "gpsd gpsd-machine-conf", "", d)} \
+    "
+
+RDEPENDS_packagegroup-meta-oe-security ="\
+    tomoyo-tools \
+    ${@bb.utils.contains("DISTRO_FEATURES", "pam", "passwdqc", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "bluz5", "nmap", "", d)} \
+    "
+
+RDEPENDS_packagegroup-meta-oe-shells ="\
+    dash tcsh zsh \
+    "
+
+NE10 = ""
+NE10_aarch64 = "ne10"
+NE10_arm7 = "ne10"
+
+RDEPENDS_packagegroup-meta-oe-support ="\
+    anthy asio atop augeas avro-c bdwgc frame grail \
+    ccid ceres-solver ckermit cpprest ctapi-common daemonize \
+    daemontools debsums devmem2 dfu-util dfu-util-native digitemp \
+    dstat eject enca epeg espeak espeak-data fbset fbset-modes \
+    fftw fltk-native gd gflags glog gnulib gperftools \
+    gpm gradm gsl gsoap hddtemp hidapi htop hunspell hwdata iksemel \
+    libinih inotify-tools joe lcms lcov libatasmart libbytesize \
+    libcereal libcyusbserial libee libeigen libestr libftdi libgit2 \
+    libgpiod libiio libjs-jquery libjs-sizzle liblinebreak libmicrohttpd \
+    libmxml libnih liboauth libol liboop libp11 libraw1394 libsmi libsoc libssh2 \
+    libssh libtar libteam libtinyxml2 libtinyxml libusbg libusb-compat libutempter \
+    links lio-utils lockdev log4c log4cpp logwarn libdevmapper lvm2 \
+    mailcap mbuffer mg minini \
+    multipath-tools nano neon nmon numactl onig openct openldap \
+    opensc wbxml2 p910nd pcsc-lite picocom libotr pidgin \
+    pngcheck poco poppler poppler-data portaudio-v19 pps-tools \
+    pv pxaregs raptor2 rdfind read-edid rsnapshot s3c24xx-gpio s3c64xx-gpio \
+    sjf2410-linux-native satyr sdparm pty-forward-native serial-forward \
+    sg3-utils sharutils smem spitools srecord ssiapi start-stop-daemon stm32flash \
+    syslog-ng system-config-keyboard tbb thin-provisioning-tools tokyocabinet \
+    tree udisks udisks2 uhubctl unixodbc upower uriparser usb-modeswitch \
+    usb-modeswitch-data usbpath uthash utouch-evemu utouch-frame \
+    vim vim-tiny websocketpp wmiconfig xdelta3 xdg-user-dirs xmlstarlet \
+    zbar zile \
+    ${@bb.utils.contains("DISTRO_FEATURES", "x11", "geis toscoterm uim synergy utouch-mtview links-x11 fltk pidgin-otr", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "pulseadio bluez4", "libcanberra", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "x11 pam", "xorgxrdp xrdp", "", d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "bluez4", "procmail", "", d)} \
+    ${NE10} \
+    "
+
+RDEPENDS_packagegroup-meta-oe-support-egl ="\
+    freerdp libnice opencv \
+    "
+
+RDEPENDS_packagegroup-meta-oe-test ="\
+    catch2 cppunit cunit cxxtest evtest fb-test \
+    fwts gtest pm-qa stress-ng testfloat \
+    "
+
+RDEPENDS_packagegroup-meta-oe-ptest = "\
+    zeromq-ptest \
+    libxml-ptest \
+    soci-ptest \
+    leveldb-ptest \
+    psqlodbc-ptest \
+    lua-ptest \
+    protobuf-ptest \
+    libdbi-ptest \
+    rsyslog-ptest \
+    oprofile-ptest \
+    libteam-ptest \
+    uthash-ptest \
+    mcelog-ptest \
+    openldap-ptest \
+    libee-ptest \
+    numactl-ptest \
+    poco-ptest \
+    "
diff --git a/meta-openembedded/meta-oe/recipes-core/plymouth/files/0002-Fix-build-with-glibc-2.28.patch b/meta-openembedded/meta-oe/recipes-core/plymouth/files/0002-Fix-build-with-glibc-2.28.patch
new file mode 100644
index 0000000..8638f75
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-core/plymouth/files/0002-Fix-build-with-glibc-2.28.patch
@@ -0,0 +1,34 @@
+From 0c0345303b7971d6cec478fd8b81d64bc1fbe0f6 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
+Date: Tue, 21 Aug 2018 23:26:45 +0200
+Subject: [PATCH] Fix build with >= glibc 2.28
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Stolen from [1]
+
+[1] https://bugs.freedesktop.org/show_bug.cgi?id=102191
+
+Upstream-Status: Pending
+
+Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
+---
+ src/libply-splash-core/ply-terminal.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/libply-splash-core/ply-terminal.c b/src/libply-splash-core/ply-terminal.c
+index a0954f2..f3b32fe 100644
+--- a/src/libply-splash-core/ply-terminal.c
++++ b/src/libply-splash-core/ply-terminal.c
+@@ -32,6 +32,7 @@
+ #include <sys/socket.h>
+ #include <sys/stat.h>
+ #include <sys/types.h>
++#include <sys/sysmacros.h>
+ #include <termios.h>
+ #include <unistd.h>
+ #include <wchar.h>
+-- 
+2.14.4
+
diff --git a/meta-openembedded/meta-oe/recipes-core/plymouth/plymouth_0.9.2.bb b/meta-openembedded/meta-oe/recipes-core/plymouth/plymouth_0.9.2.bb
index 7e8d6e3..a5b16c9 100644
--- a/meta-openembedded/meta-oe/recipes-core/plymouth/plymouth_0.9.2.bb
+++ b/meta-openembedded/meta-oe/recipes-core/plymouth/plymouth_0.9.2.bb
@@ -19,6 +19,7 @@
 SRC_URI = " \
     http://www.freedesktop.org/software/plymouth/releases/${BPN}-${PV}.tar.bz2 \
     file://0001-Make-full-path-to-systemd-tty-ask-password-agent-con.patch \
+    file://0002-Fix-build-with-glibc-2.28.patch \
 "
 SRC_URI[md5sum] = "ff420994deb7ea203df678df92e7ab7d"
 SRC_URI[sha256sum] = "2f0ce82042cf9c7eadd2517a1f74c8a85fa8699781d9f294a06eade29fbed57f"
diff --git a/meta-openembedded/meta-oe/recipes-core/toybox/toybox/OE-path-changes.patch b/meta-openembedded/meta-oe/recipes-core/toybox/toybox/OE-path-changes.patch
new file mode 100644
index 0000000..e42c22e
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-core/toybox/toybox/OE-path-changes.patch
@@ -0,0 +1,195 @@
+diff --git a/toys/net/microcom.c b/toys/net/microcom.c
+index d34e1fe..a369e6c 100644
+--- a/toys/net/microcom.c
++++ b/toys/net/microcom.c
+@@ -2,7 +2,7 @@
+  *
+  * Copyright 2017 The Android Open Source Project.
+ 
+-USE_MICROCOM(NEWTOY(microcom, "<1>1s:X", TOYFLAG_BIN))
++USE_MICROCOM(NEWTOY(microcom, "<1>1s:X", TOYFLAG_USR|TOYFLAG_BIN))
+ 
+ config MICROCOM
+   bool "microcom"
+diff --git a/toys/other/blockdev.c b/toys/other/blockdev.c
+index 38e0993..c5d9fcd 100644
+--- a/toys/other/blockdev.c
++++ b/toys/other/blockdev.c
+@@ -4,7 +4,7 @@
+  *
+  * No Standard.
+ 
+-USE_BLOCKDEV(NEWTOY(blockdev, "<1>1(setro)(setrw)(getro)(getss)(getbsz)(setbsz)#<0(getsz)(getsize)(getsize64)(flushbufs)(rereadpt)",TOYFLAG_USR|TOYFLAG_BIN))
++USE_BLOCKDEV(NEWTOY(blockdev, "<1>1(setro)(setrw)(getro)(getss)(getbsz)(setbsz)#<0(getsz)(getsize)(getsize64)(flushbufs)(rereadpt)",TOYFLAG_SBIN))
+ 
+ config BLOCKDEV
+   bool "blockdev"
+diff --git a/toys/other/chrt.c b/toys/other/chrt.c
+index a1c37a0..d6db3a5 100644
+--- a/toys/other/chrt.c
++++ b/toys/other/chrt.c
+@@ -4,7 +4,7 @@
+  *
+  * Note: -ibrfo flags sorted to match SCHED positions for highest_bit()
+ 
+-USE_CHRT(NEWTOY(chrt, "^mp#<0iRbrfo[!ibrfo]", TOYFLAG_USR|TOYFLAG_SBIN))
++USE_CHRT(NEWTOY(chrt, "^mp#<0iRbrfo[!ibrfo]", TOYFLAG_USR|TOYFLAG_BIN))
+ 
+ config CHRT
+   bool "chrt"
+diff --git a/toys/other/hwclock.c b/toys/other/hwclock.c
+index 1d313e3..412582d 100644
+--- a/toys/other/hwclock.c
++++ b/toys/other/hwclock.c
+@@ -4,7 +4,7 @@
+  *
+  * No standard, but see Documentation/rtc.txt in the linux kernel source..
+  *
+-USE_HWCLOCK(NEWTOY(hwclock, ">0(fast)f(rtc):u(utc)l(localtime)t(systz)s(hctosys)r(show)w(systohc)[-ul][!rtsw]", TOYFLAG_USR|TOYFLAG_BIN))
++USE_HWCLOCK(NEWTOY(hwclock, ">0(fast)f(rtc):u(utc)l(localtime)t(systz)s(hctosys)r(show)w(systohc)[-ul][!rtsw]", TOYFLAG_SBIN))
+ 
+ config HWCLOCK
+   bool "hwclock"
+diff --git a/toys/other/modinfo.c b/toys/other/modinfo.c
+index 1178d67..966a9de 100644
+--- a/toys/other/modinfo.c
++++ b/toys/other/modinfo.c
+@@ -4,7 +4,7 @@
+  *
+  * TODO: cleanup
+ 
+-USE_MODINFO(NEWTOY(modinfo, "<1b:k:F:0", TOYFLAG_BIN))
++USE_MODINFO(NEWTOY(modinfo, "<1b:k:F:0", TOYFLAG_SBIN))
+ 
+ config MODINFO
+   bool "modinfo"
+diff --git a/toys/other/pmap.c b/toys/other/pmap.c
+index abb0a33..2acef02 100644
+--- a/toys/other/pmap.c
++++ b/toys/other/pmap.c
+@@ -5,7 +5,7 @@
+  *
+  * No Standard.
+ 
+-USE_PMAP(NEWTOY(pmap, "<1xq", TOYFLAG_BIN))
++USE_PMAP(NEWTOY(pmap, "<1xq", TOYFLAG_USR|TOYFLAG_BIN))
+ 
+ config PMAP
+   bool "pmap"
+diff --git a/toys/other/printenv.c b/toys/other/printenv.c
+index e8bcf29..65f62ed 100644
+--- a/toys/other/printenv.c
++++ b/toys/other/printenv.c
+@@ -2,7 +2,7 @@
+  *
+  * Copyright 2012 Georgi Chorbadzhiyski <georgi@unixsol.org>
+ 
+-USE_PRINTENV(NEWTOY(printenv, "0(null)", TOYFLAG_USR|TOYFLAG_BIN))
++USE_PRINTENV(NEWTOY(printenv, "0(null)", TOYFLAG_BIN))
+ 
+ config PRINTENV
+   bool "printenv"
+diff --git a/toys/other/taskset.c b/toys/other/taskset.c
+index 8ffdab7..89fd528 100644
+--- a/toys/other/taskset.c
++++ b/toys/other/taskset.c
+@@ -2,7 +2,7 @@
+  *
+  * Copyright 2012 Elie De Brauwer <eliedebrauwer@gmail.com>
+ 
+-USE_TASKSET(NEWTOY(taskset, "<1^pa", TOYFLAG_BIN|TOYFLAG_STAYROOT))
++USE_TASKSET(NEWTOY(taskset, "<1^pa", TOYFLAG_USR|TOYFLAG_BIN|TOYFLAG_STAYROOT))
+ USE_NPROC(NEWTOY(nproc, "(all)", TOYFLAG_USR|TOYFLAG_BIN))
+ 
+ config NPROC
+diff --git a/toys/other/timeout.c b/toys/other/timeout.c
+index 9b93466..e1d0f4d 100644
+--- a/toys/other/timeout.c
++++ b/toys/other/timeout.c
+@@ -4,7 +4,7 @@
+  *
+  * No standard
+ 
+-USE_TIMEOUT(NEWTOY(timeout, "<2^vk:s: ", TOYFLAG_BIN))
++USE_TIMEOUT(NEWTOY(timeout, "<2^vk:s: ", TOYFLAG_USR|TOYFLAG_BIN))
+ 
+ config TIMEOUT
+   bool "timeout"
+diff --git a/toys/other/truncate.c b/toys/other/truncate.c
+index 142d3c7..40eb1e5 100644
+--- a/toys/other/truncate.c
++++ b/toys/other/truncate.c
+@@ -2,7 +2,7 @@
+  *
+  * Copyright 2011 Rob Landley <rob@landley.net>
+ 
+-USE_TRUNCATE(NEWTOY(truncate, "<1s:|c", TOYFLAG_BIN))
++USE_TRUNCATE(NEWTOY(truncate, "<1s:|c", TOYFLAG_USR|TOYFLAG_BIN))
+ 
+ config TRUNCATE
+   bool "truncate"
+diff --git a/toys/posix/nice.c b/toys/posix/nice.c
+index 4b587ee..9f7b119 100644
+--- a/toys/posix/nice.c
++++ b/toys/posix/nice.c
+@@ -4,7 +4,7 @@
+  *
+  * See http://opengroup.org/onlinepubs/9699919799/utilities/nice.html
+ 
+-USE_NICE(NEWTOY(nice, "^<1n#", TOYFLAG_USR|TOYFLAG_BIN))
++USE_NICE(NEWTOY(nice, "^<1n#", TOYFLAG_BIN))
+ 
+ config NICE
+   bool "nice"
+diff --git a/toys/posix/nl.c b/toys/posix/nl.c
+index 9b02bfa..41e1b89 100644
+--- a/toys/posix/nl.c
++++ b/toys/posix/nl.c
+@@ -7,7 +7,7 @@
+  * This implements a subset: only one logical page (-ip), no sections (-dfh).
+  * todo: -lv
+ 
+-USE_NL(NEWTOY(nl, "v#<1=1l#b:n:s:w#<0=6E", TOYFLAG_BIN))
++USE_NL(NEWTOY(nl, "v#<1=1l#b:n:s:w#<0=6E", TOYFLAG_USR|TOYFLAG_BIN))
+ 
+ config NL
+   bool "nl"
+diff --git a/toys/posix/paste.c b/toys/posix/paste.c
+index ea04f02..8972f71 100644
+--- a/toys/posix/paste.c
++++ b/toys/posix/paste.c
+@@ -6,7 +6,7 @@
+  *
+  * Deviations from posix: the FILE argument isn't mandatory, none == '-'
+ 
+-USE_PASTE(NEWTOY(paste, "d:s", TOYFLAG_BIN|TOYFLAG_LOCALE))
++USE_PASTE(NEWTOY(paste, "d:s", TOYFLAG_USR|TOYFLAG_BIN|TOYFLAG_LOCALE))
+ 
+ config PASTE
+   bool "paste"
+diff --git a/toys/posix/ps.c b/toys/posix/ps.c
+index aef2a7f..b559e09 100644
+--- a/toys/posix/ps.c
++++ b/toys/posix/ps.c
+@@ -44,7 +44,7 @@
+  * TODO: top: thread support and SMP
+  * TODO: pgrep -f only searches the amount of cmdline that fits in toybuf.
+ 
+-USE_PS(NEWTOY(ps, "k(sort)*P(ppid)*aAdeflMno*O*p(pid)*s*t*Tu*U*g*G*wZ[!ol][+Ae][!oO]", TOYFLAG_USR|TOYFLAG_BIN|TOYFLAG_LOCALE))
++USE_PS(NEWTOY(ps, "k(sort)*P(ppid)*aAdeflMno*O*p(pid)*s*t*Tu*U*g*G*wZ[!ol][+Ae][!oO]", TOYFLAG_BIN|TOYFLAG_LOCALE))
+ // stayroot because iotop needs root to read other process' proc/$$/io
+ USE_TOP(NEWTOY(top, ">0m" "O*Hk*o*p*u*s#<1d#=3<1n#<1bq[!oO]", TOYFLAG_USR|TOYFLAG_BIN|TOYFLAG_LOCALE))
+ USE_IOTOP(NEWTOY(iotop, ">0AaKO" "k*o*p*u*s#<1=7d#=3<1n#<1bq", TOYFLAG_USR|TOYFLAG_BIN|TOYFLAG_STAYROOT|TOYFLAG_LOCALE))
+diff --git a/toys/posix/sed.c b/toys/posix/sed.c
+index cf7d15e..130ac08 100644
+--- a/toys/posix/sed.c
++++ b/toys/posix/sed.c
+@@ -10,7 +10,7 @@
+  * TODO: handle error return from emit(), error_msg/exit consistently
+  *       What's the right thing to do for -i when write fails? Skip to next?
+ 
+-USE_SED(NEWTOY(sed, "(help)(version)e*f*inEr[+Er]", TOYFLAG_USR|TOYFLAG_BIN|TOYFLAG_LOCALE|TOYFLAG_NOHELP))
++USE_SED(NEWTOY(sed, "(help)(version)e*f*inEr[+Er]", TOYFLAG_BIN|TOYFLAG_LOCALE|TOYFLAG_NOHELP))
+ 
+ config SED
+   bool "sed"
diff --git a/meta-openembedded/meta-oe/recipes-core/toybox/toybox_0.7.5.bb b/meta-openembedded/meta-oe/recipes-core/toybox/toybox_0.7.5.bb
index 347c285..7e8e7b2 100644
--- a/meta-openembedded/meta-oe/recipes-core/toybox/toybox_0.7.5.bb
+++ b/meta-openembedded/meta-oe/recipes-core/toybox/toybox_0.7.5.bb
@@ -1,11 +1,13 @@
 SUMMARY = "Toybox combines common utilities together into a single executable."
 HOMEPAGE = "http://www.landley.net/toybox/"
-DEPENDS = "attr"
+DEPENDS = "attr virtual/crypt"
 
 LICENSE = "BSD-0-Clause"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=f0b8b3dd6431bcaa245da0a08bd0d511"
 
-SRC_URI = "http://www.landley.net/toybox/downloads/${BPN}-${PV}.tar.gz"
+SRC_URI = "http://www.landley.net/toybox/downloads/${BPN}-${PV}.tar.gz \
+           file://OE-path-changes.patch \
+           "
 SRC_URI[md5sum] = "a8bb502a1be941f06dd2644fff25f547"
 SRC_URI[sha256sum] = "3ada450ac1eab1dfc352fee915ea6129b9a4349c1885f1394b61bd2d89a46c04"
 
diff --git a/meta-openembedded/meta-oe/recipes-core/usleep/usleep_1.0.bb b/meta-openembedded/meta-oe/recipes-core/usleep/usleep_1.0.bb
index 9e9c7ed..370dd4a 100644
--- a/meta-openembedded/meta-oe/recipes-core/usleep/usleep_1.0.bb
+++ b/meta-openembedded/meta-oe/recipes-core/usleep/usleep_1.0.bb
@@ -22,3 +22,12 @@
     install -m 0755 ${WORKDIR}/usleep   ${D}${base_bindir}
     install -m 0644 ${WORKDIR}/usleep.1 ${D}${mandir}/man1
 }
+
+inherit update-alternatives
+
+ALTERNATIVE_${PN} = "usleep"
+ALTERNATIVE_PRIORITY = "80"
+ALTERNATIVE_LINK_NAME[usleep] = "${base_bindir}/usleep"
+
+ALTERNATIVE_${PN}-doc = "usleep.1"
+ALTERNATIVE_LINK_NAME[usleep.1] = "${mandir}/man1/usleep.1"
diff --git a/meta-openembedded/meta-oe/recipes-crypto/botan/botan_2.7.0.bb b/meta-openembedded/meta-oe/recipes-crypto/botan/botan_2.7.0.bb
new file mode 100644
index 0000000..92853d0
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-crypto/botan/botan_2.7.0.bb
@@ -0,0 +1,55 @@
+# Copyright (C) 2018 Khem Raj <raj.khem@gmail.com>
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+DESCRIPTION = "Crypto and TLS for C++11"
+HOMEPAGE = "https://botan.randombit.net"
+LICENSE = "BSD-2-Clause"
+LIC_FILES_CHKSUM = "file://license.txt;md5=bf361fc63df3fa25652ee82c43b7601a"
+SECTION = "libs"
+
+
+#v2.7.0
+SRCREV = "5874000d42c338ec95a7ff24cdc0c64e70f967b5"
+SRC_URI = "git://github.com/randombit/botan.git"
+
+S = "${WORKDIR}/git"
+
+inherit python3native siteinfo lib_package
+
+CPU ?= "${TARGET_ARCH}"
+CPU_x86 = "x86_32"
+CPU_armv7a = "armv7"
+CPU_armv7ve = "armv7"
+
+do_configure() {
+	python3 ${S}/configure.py \
+	--prefix="${D}${prefix}" \
+	--cpu="${CPU}" \
+	--cc-bin="${CXX}" \
+	--cxxflags="${CXXFLAGS}" \
+	--ldflags="${LDFLAGS}" \
+	--with-endian=${@oe.utils.conditional('SITEINFO_ENDIANNESS', 'le', 'little', 'big', d)} \
+	${@bb.utils.contains("TUNE_FEATURES","neon","","--disable-neon",d)} \
+	--with-sysroot-dir=${STAGING_DIR_TARGET} \
+	--with-build-dir="${B}" \
+	--optimize-for-size \
+	--with-stack-protector \
+	--enable-shared-library \
+	--with-python-versions=3 \
+	${EXTRA_OECONF}
+}
+
+do_compile() {
+	oe_runmake
+}
+do_install() {
+	oe_runmake install
+	sed -i -e "s|${D}||g" ${D}${libdir}/pkgconfig/botan-2.pc
+}
+
+PACKAGES += "${PN}-python3"
+
+FILES_${PN}-python3 = "${libdir}/python3"
+
+RDEPENDS_${PN}-python3 += "python3"
+
diff --git a/meta-openembedded/meta-oe/recipes-crypto/cryptsetup/cryptsetup_1.7.4.bb b/meta-openembedded/meta-oe/recipes-crypto/cryptsetup/cryptsetup_1.7.4.bb
deleted file mode 100644
index c13b764..0000000
--- a/meta-openembedded/meta-oe/recipes-crypto/cryptsetup/cryptsetup_1.7.4.bb
+++ /dev/null
@@ -1,36 +0,0 @@
-SUMMARY = "Manage plain dm-crypt and LUKS encrypted volumes"
-DESCRIPTION = "Cryptsetup is used to conveniently setup dm-crypt managed \
-device-mapper mappings. These include plain dm-crypt volumes and \
-LUKS volumes. The difference is that LUKS uses a metadata header \
-and can hence offer more features than plain dm-crypt. On the other \
-hand, the header is visible and vulnerable to damage."
-HOMEPAGE = "http://code.google.com/p/cryptsetup/"
-SECTION = "console"
-LICENSE = "GPL-2.0-with-OpenSSL-exception"
-LIC_FILES_CHKSUM = "file://COPYING;md5=32107dd283b1dfeb66c9b3e6be312326"
-
-DEPENDS = "util-linux libdevmapper popt libgcrypt"
-
-SRC_URI = "${KERNELORG_MIRROR}/linux/utils/${BPN}/v1.7/${BP}.tar.xz"
-SRC_URI[md5sum] = "058ed35c5b776032c2a036838f9e22a7"
-SRC_URI[sha256sum] = "7ccf893ef79a38fb92d61f03c17b964982119f5319cdaa85a1335b8558cca016"
-
-inherit autotools gettext pkgconfig
-
-# Use openssl because libgcrypt drops root privileges
-# if libgcrypt is linked with libcap support
-PACKAGECONFIG ??= "openssl"
-PACKAGECONFIG[openssl] = "--with-crypto_backend=openssl,,openssl"
-PACKAGECONFIG[gcrypt] = "--with-crypto_backend=gcrypt,,libgcrypt"
-
-RRECOMMENDS_${PN} = "kernel-module-aes-generic \
-                     kernel-module-dm-crypt \
-                     kernel-module-md5 \
-                     kernel-module-cbc \
-                     kernel-module-sha256-generic \
-                     kernel-module-xts \
-"
-
-EXTRA_OECONF = "--enable-static"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-crypto/cryptsetup/cryptsetup_2.0.4.bb b/meta-openembedded/meta-oe/recipes-crypto/cryptsetup/cryptsetup_2.0.4.bb
new file mode 100644
index 0000000..cc7bc6e
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-crypto/cryptsetup/cryptsetup_2.0.4.bb
@@ -0,0 +1,38 @@
+SUMMARY = "Manage plain dm-crypt and LUKS encrypted volumes"
+DESCRIPTION = "Cryptsetup is used to conveniently setup dm-crypt managed \
+device-mapper mappings. These include plain dm-crypt volumes and \
+LUKS volumes. The difference is that LUKS uses a metadata header \
+and can hence offer more features than plain dm-crypt. On the other \
+hand, the header is visible and vulnerable to damage."
+HOMEPAGE = "https://gitlab.com/cryptsetup/cryptsetup"
+SECTION = "console"
+LICENSE = "GPL-2.0-with-OpenSSL-exception"
+LIC_FILES_CHKSUM = "file://COPYING;md5=32107dd283b1dfeb66c9b3e6be312326"
+
+DEPENDS = "util-linux libdevmapper popt libgcrypt json-c"
+
+SRC_URI = "${KERNELORG_MIRROR}/linux/utils/${BPN}/v2.0/${BP}.tar.xz"
+SRC_URI[md5sum] = "ed42b31f67d05b05e392d1943d467b8d"
+SRC_URI[sha256sum] = "9d3a3c7033293e0c97f0ad0501fd5b4d4913ae497cbf70cca06633ccc54b5734"
+
+inherit autotools gettext pkgconfig
+
+# Use openssl because libgcrypt drops root privileges
+# if libgcrypt is linked with libcap support
+PACKAGECONFIG ??= "openssl"
+PACKAGECONFIG[openssl] = "--with-crypto_backend=openssl,,openssl"
+PACKAGECONFIG[gcrypt] = "--with-crypto_backend=gcrypt,,libgcrypt"
+
+RRECOMMENDS_${PN} = "kernel-module-aes-generic \
+                     kernel-module-dm-crypt \
+                     kernel-module-md5 \
+                     kernel-module-cbc \
+                     kernel-module-sha256-generic \
+                     kernel-module-xts \
+"
+
+EXTRA_OECONF = "--enable-static"
+
+FILES_${PN} += "${@bb.utils.contains('DISTRO_FEATURES','systemd','${exec_prefix}/lib/tmpfiles.d/cryptsetup.conf', '', d)}"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-crypto/engine-pkcs11/engine-pkcs11_0.2.2.bb b/meta-openembedded/meta-oe/recipes-crypto/engine-pkcs11/engine-pkcs11_0.2.2.bb
deleted file mode 100644
index bc79f35..0000000
--- a/meta-openembedded/meta-oe/recipes-crypto/engine-pkcs11/engine-pkcs11_0.2.2.bb
+++ /dev/null
@@ -1,31 +0,0 @@
-SUMMARY = "A PKCS"
-DESCRIPTION = "\
-Engine_pkcs11 is an implementation of an engine for OpenSSL. It can be \
-loaded using code, config file or command line and will pass any function \
-call by openssl to a PKCS cards and software for using smart cards in PKCS"
-HOMEPAGE = "https://github.com/OpenSC/engine_pkcs11"
-SECTION = "Development/Libraries"
-LICENSE = "LGPLv2.1+"
-LIC_FILES_CHKSUM = "file://src/engine_pkcs11.h;beginline=1;endline=26;md5=973a19f8a6105de047f2adfbbfc04c33"
-DEPENDS = "openssl libp11"
-
-SRC_URI = "git://github.com/OpenSC/engine_pkcs11.git"
-SRCREV = "132fcf2c8b319f9f4b2ebdc8dcb54ff496dc0519"
-
-S = "${WORKDIR}/git"
-
-inherit autotools pkgconfig
-
-EXTRA_OECONF = "\
-    --disable-static \
-    --libdir ${libdir}/engines \
-"
-
-do_install_append () {
-    rm -f ${D}${libdir}/engines/libpkcs11.la
-}
-
-FILES_${PN} += "${libdir}/engines/libpkcs11${SOLIBSDEV}"
-FILES_${PN}-dbg += "${libdir}/engines/.debug/"
-
-RDEPENDS_${PN} += "openssl libp11 opensc"
diff --git a/meta-openembedded/meta-oe/recipes-crypto/libkcapi/libkcapi_git.bb b/meta-openembedded/meta-oe/recipes-crypto/libkcapi/libkcapi_git.bb
new file mode 100644
index 0000000..a93ddc8
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-crypto/libkcapi/libkcapi_git.bb
@@ -0,0 +1,28 @@
+SUMMARY = "Linux Kernel Crypto API User Space Interface Library"
+HOMEPAGE = "http://www.chronox.de/libkcapi.html"
+LICENSE = "BSD | GPL-2.0"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d0421cf231423bda10cea691b613e866"
+
+DEPENDS = "libtool"
+
+S = "${WORKDIR}/git"
+# Use v1.1.3 with changes on top for building in OE
+SRCREV = "1c736c43eb71fbb5640d00efaf34a1edf1972c49"
+PV = "1.1.3+git${SRCPV}"
+SRC_URI = " \
+    git://github.com/smuellerDD/libkcapi.git \
+"
+
+inherit autotools
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[testapp] = "--enable-kcapi-test,,,"
+PACKAGECONFIG[apps] = "--enable-kcapi-speed --enable-kcapi-hasher --enable-kcapi-rngapp --enable-kcapi-encapp --enable-kcapi-dgstapp,,,"
+
+do_install_append() {
+    # bindir contains testapp and apps.  However it is always created, even
+    # when no binaries are installed (empty bin_PROGRAMS in Makefile.am),
+    rmdir --ignore-fail-on-non-empty ${D}${bindir}
+}
+
+CPPFLAGS_append_libc-musl_toolchain-clang = " -Wno-error=sign-compare"
diff --git a/meta-openembedded/meta-oe/recipes-crypto/libmcrypt/libmcrypt_2.5.8.bb b/meta-openembedded/meta-oe/recipes-crypto/libmcrypt/libmcrypt_2.5.8.bb
index 2a133c6..be413a1 100644
--- a/meta-openembedded/meta-oe/recipes-crypto/libmcrypt/libmcrypt_2.5.8.bb
+++ b/meta-openembedded/meta-oe/recipes-crypto/libmcrypt/libmcrypt_2.5.8.bb
@@ -9,4 +9,7 @@
 SRC_URI[md5sum] = "0821830d930a86a5c69110837c55b7da"
 SRC_URI[sha256sum] = "e4eb6c074bbab168ac47b947c195ff8cef9d51a211cdd18ca9c9ef34d27a373e"
 
+UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/mcrypt/files/Libmcrypt/"
+UPSTREAM_CHECK_REGEX = "Libmcrypt/(?P<pver>\d+(\.\d+)+)/"
+
 inherit autotools-brokensep gettext binconfig
diff --git a/meta-openembedded/meta-oe/recipes-crypto/pkcs11-helper/pkcs11-helper_1.11.bb b/meta-openembedded/meta-oe/recipes-crypto/pkcs11-helper/pkcs11-helper_1.11.bb
deleted file mode 100644
index db71bd0..0000000
--- a/meta-openembedded/meta-oe/recipes-crypto/pkcs11-helper/pkcs11-helper_1.11.bb
+++ /dev/null
@@ -1,29 +0,0 @@
-SUMMARY = "A library for using PKCS"
-DESCRIPTION = "pkcs11-helper is a library that simplifies the interaction with PKCS \
-providers for end-user applications using a simple API and optional OpenSSL \
-engine. The library allows using multiple PKCS enumerating available token \
-certificates, or selecting a certificate directly by serialized id, handling \
-card removal and card insert events, handling card ie-insert to a different \
-slot, supporting session expiration and much more all using a simple API."
-
-HOMEPAGE = "http://www.opensc-project.org/pkcs11-helper/"
-SECTION = "Development/Libraries"
-
-LICENSE = "GPLv2 & BSD"
-LIC_FILES_CHKSUM = " \
-    file://COPYING;md5=4948810631bcac142af53d32df5b6ee1 \
-    file://COPYING.GPL;md5=8a71d0475d08eee76d8b6d0c6dbec543 \
-    file://COPYING.BSD;md5=f79f90ea7a106796af80b5d05f1f8da1 \
-"
-SRC_URI = "git://github.com/OpenSC/${BPN}.git"
-SRC_URI[md5sum] = "9f62af9f475901b89355266141306673"
-SRC_URI[sha256sum] = "494ec59c93e7c56c528f335d9353849e2e7c94a6b1b41c89604694e738113386"
-
-S = "${WORKDIR}/git"
-SRCREV = "e7adf8f35be232a4f04c53b4ac409be52792093e"
-
-DEPENDS = "zlib nettle gnutls gmp openssl nss nspr"
-
-inherit autotools pkgconfig
-
-EXTRA_OECONF = "--disable-static"
diff --git a/meta-openembedded/meta-oe/recipes-crypto/pkcs11-helper/pkcs11-helper_1.25.1.bb b/meta-openembedded/meta-oe/recipes-crypto/pkcs11-helper/pkcs11-helper_1.25.1.bb
new file mode 100644
index 0000000..271f2ea
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-crypto/pkcs11-helper/pkcs11-helper_1.25.1.bb
@@ -0,0 +1,28 @@
+SUMMARY = "A library for using PKCS"
+DESCRIPTION = "pkcs11-helper is a library that simplifies the interaction with PKCS \
+providers for end-user applications using a simple API and optional OpenSSL \
+engine. The library allows using multiple PKCS enumerating available token \
+certificates, or selecting a certificate directly by serialized id, handling \
+card removal and card insert events, handling card ie-insert to a different \
+slot, supporting session expiration and much more all using a simple API."
+
+HOMEPAGE = "http://www.opensc-project.org/pkcs11-helper/"
+SECTION = "Development/Libraries"
+
+LICENSE = "GPLv2 & BSD"
+LIC_FILES_CHKSUM = " \
+    file://COPYING;md5=30f10d22cfb1ba98ccd714a41ad3311a \
+    file://COPYING.GPL;md5=8a71d0475d08eee76d8b6d0c6dbec543 \
+    file://COPYING.BSD;md5=66b7a37c3c10483c1fd86007726104d7 \
+"
+SRC_URI = "git://github.com/OpenSC/${BPN}.git"
+
+S = "${WORKDIR}/git"
+# v1.25.1
+SRCREV = "2713cb09dcd90104cb7bceb5f14cd6f90834f7b1"
+
+DEPENDS = "zlib nettle gnutls gmp openssl nss nspr"
+
+inherit autotools pkgconfig
+
+EXTRA_OECONF = "--disable-static"
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-IntelRDFPMathLib20U1-Check-for-__DEFINED_wchar_t.patch b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-IntelRDFPMathLib20U1-Check-for-__DEFINED_wchar_t.patch
index 5da3448..4d7ac3a 100644
--- a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-IntelRDFPMathLib20U1-Check-for-__DEFINED_wchar_t.patch
+++ b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-IntelRDFPMathLib20U1-Check-for-__DEFINED_wchar_t.patch
@@ -18,19 +18,16 @@
  src/third_party/IntelRDFPMathLib20U1/LIBRARY/src/bid_functions.h | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-diff --git a/src/third_party/IntelRDFPMathLib20U1/LIBRARY/src/bid_functions.h b/src/third_party/IntelRDFPMathLib20U1/LIBRARY/src/bid_functions.h
-index 2b3f76db86..cc80305775 100755
---- a/src/third_party/IntelRDFPMathLib20U1/LIBRARY/src/bid_functions.h
-+++ b/src/third_party/IntelRDFPMathLib20U1/LIBRARY/src/bid_functions.h
-@@ -42,7 +42,7 @@
- #include <ctype.h>
+Index: git/src/third_party/IntelRDFPMathLib20U1/LIBRARY/src/bid_functions.h
+===================================================================
+--- git.orig/src/third_party/IntelRDFPMathLib20U1/LIBRARY/src/bid_functions.h
++++ git/src/third_party/IntelRDFPMathLib20U1/LIBRARY/src/bid_functions.h
+@@ -43,7 +43,7 @@
  
+ #if 0 // MongoDB Modification -- just `#include <stddef.h>`
  // Fix system header issue on Sun solaris and define required type by ourselves
 -#if !defined(_WCHAR_T) && !defined(_WCHAR_T_DEFINED) && !defined(__QNX__)
 +#if !defined(_WCHAR_T) && !defined(_WCHAR_T_DEFINED) && !defined(__QNX__) && !defined(__DEFINED_wchar_t)
  typedef int   wchar_t;
  #endif
- 
--- 
-2.14.1
-
+ #else
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Support-deprecated-resolver-functions.patch b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Support-deprecated-resolver-functions.patch
new file mode 100644
index 0000000..070411a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Support-deprecated-resolver-functions.patch
@@ -0,0 +1,33 @@
+From 5994023a03634dfc0318976c293e7391fe6aa060 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 24 Aug 2018 12:56:22 -0700
+Subject: [PATCH 1/2] Support deprecated resolver functions
+
+Needed for  musl libc
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/mongo/util/dns_query_posix-impl.h | 6 ++++++
+ 1 file changed, 6 insertions(+)
+
+diff --git a/src/mongo/util/dns_query_posix-impl.h b/src/mongo/util/dns_query_posix-impl.h
+index d19958010c..bbca3309ed 100644
+--- a/src/mongo/util/dns_query_posix-impl.h
++++ b/src/mongo/util/dns_query_posix-impl.h
+@@ -53,6 +53,12 @@
+ 
+ #include <boost/noncopyable.hpp>
+ 
++#ifndef res_ninit
++#define res_nclose(arg)
++#define res_ninit(arg)    res_init()
++#define res_nsearch(sta, nam, clas, typ, ans, alen)  res_search(nam, clas, typ, ans, alen)
++#endif
++
+ namespace mongo {
+ namespace dns {
+ // The anonymous namespace is safe, in this header, as it is not really a header.  It is only used
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Tell-scons-to-use-build-settings-from-environment-va.patch b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Tell-scons-to-use-build-settings-from-environment-va.patch
index aa01e95..a6d721a 100644
--- a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Tell-scons-to-use-build-settings-from-environment-va.patch
+++ b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Tell-scons-to-use-build-settings-from-environment-va.patch
@@ -13,7 +13,7 @@
 ===================================================================
 --- git.orig/SConstruct
 +++ git/SConstruct
-@@ -548,6 +548,7 @@ def variable_arch_converter(val):
+@@ -564,6 +564,7 @@ def variable_arch_converter(val):
          'amd64':  'x86_64',
          'emt64':   'x86_64',
          'x86':    'i386',
@@ -21,7 +21,7 @@
      }
      val = val.lower()
  
-@@ -627,7 +628,8 @@ env_vars.Add(
+@@ -652,7 +653,8 @@ env_vars.Add(
  )
  
  env_vars.Add('CC',
@@ -31,7 +31,7 @@
  
  env_vars.Add('CCFLAGS',
      help='Sets flags for the C and C++ compiler',
-@@ -647,7 +649,8 @@ env_vars.Add('CPPPATH',
+@@ -672,7 +674,8 @@ env_vars.Add('CPPPATH',
      converter=variable_shlex_converter)
  
  env_vars.Add('CXX',
@@ -41,19 +41,19 @@
  
  env_vars.Add('CXXFLAGS',
      help='Sets flags for the C++ compiler',
-@@ -895,6 +898,7 @@ envDict = dict(BUILD_ROOT=buildDir,
+@@ -961,6 +964,7 @@ envDict = dict(BUILD_ROOT=buildDir,
                 )
  
  env = Environment(variables=env_vars, **envDict)
 +env.PrependENVPath('PATH', os.getenv('PATH'))
  del envDict
  
- env.AddMethod(env_os_is_wrapper, 'TargetOSIs')
+ env.AddMethod(mongo_platform.env_os_is_wrapper, 'TargetOSIs')
 Index: git/src/mongo/util/SConscript
 ===================================================================
 --- git.orig/src/mongo/util/SConscript
 +++ git/src/mongo/util/SConscript
-@@ -274,6 +274,8 @@ if env['MONGO_ALLOCATOR'] == 'tcmalloc':
+@@ -329,6 +329,8 @@ if env['MONGO_ALLOCATOR'] == 'tcmalloc':
                  'MONGO_HAVE_GPERFTOOLS_SIZE_CLASS_STATS'
              ]
          )
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Use-__GLIBC__-to-control-use-of-gnu_get_libc_version.patch b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Use-__GLIBC__-to-control-use-of-gnu_get_libc_version.patch
index f8c419d..c17ebf1 100644
--- a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Use-__GLIBC__-to-control-use-of-gnu_get_libc_version.patch
+++ b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Use-__GLIBC__-to-control-use-of-gnu_get_libc_version.patch
@@ -9,34 +9,25 @@
  src/mongo/util/processinfo_linux.cpp | 6 ++++--
  1 file changed, 4 insertions(+), 2 deletions(-)
 
-diff --git a/src/mongo/util/processinfo_linux.cpp b/src/mongo/util/processinfo_linux.cpp
-index 910015215e..bf8c1ffd15 100644
---- a/src/mongo/util/processinfo_linux.cpp
-+++ b/src/mongo/util/processinfo_linux.cpp
-@@ -40,7 +40,7 @@
- #include <sys/mman.h>
- #include <sys/utsname.h>
+Index: git/src/mongo/util/processinfo_linux.cpp
+===================================================================
+--- git.orig/src/mongo/util/processinfo_linux.cpp
++++ git/src/mongo/util/processinfo_linux.cpp
+@@ -44,10 +44,10 @@
  #include <unistd.h>
--#ifdef __UCLIBC__
-+#ifndef __GLIBC__
- #include <features.h>
- #else
+ #ifdef __BIONIC__
+ #include <android/api-level.h>
+-#elif __UCLIBC__
+-#include <features.h>
+-#else
++#elif defined(__GLIBC__) && !defined(__UCLIBC__)
  #include <gnu/libc-version.h>
-@@ -451,11 +451,13 @@ double ProcessInfo::getSystemMemoryPressurePercentage() {
- }
++#else
++#include <features.h>
+ #endif
  
- void ProcessInfo::getExtraInfo(BSONObjBuilder& info) {
-+#if defined(__GLIBC__)
-     LinuxProc p(_pid);
-     if (p._maj_flt <= std::numeric_limits<long long>::max())
-         info.appendNumber("page_faults", static_cast<long long>(p._maj_flt));
-     else
-         info.appendNumber("page_faults", static_cast<double>(p._maj_flt));
-+#endif
- }
- 
- /**
-@@ -491,7 +493,7 @@ void ProcessInfo::SystemInfo::collectSystemInfo() {
+ #include <boost/filesystem.hpp>
+@@ -503,7 +503,7 @@ void ProcessInfo::SystemInfo::collectSys
      stringstream ss;
      ss << "uClibc-" << __UCLIBC_MAJOR__ << "." << __UCLIBC_MINOR__ << "." << __UCLIBC_SUBLEVEL__;
      bExtra.append("libcVersion", ss.str());
@@ -45,6 +36,3 @@
      bExtra.append("libcVersion", gnu_get_libc_version());
  #endif
      if (!verSig.empty())
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Use-long-long-instead-of-int64_t.patch b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Use-long-long-instead-of-int64_t.patch
index 389b302..99edad3 100644
--- a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Use-long-long-instead-of-int64_t.patch
+++ b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Use-long-long-instead-of-int64_t.patch
@@ -44,7 +44,7 @@
  
              if (!parseNumberFromString(stringValue, &value).isOK()) {
                  value = 0;
-@@ -426,7 +426,7 @@ Status parseProcDiskStats(const std::vec
+@@ -522,7 +522,7 @@ Status parseProcDiskStats(const std::vec
                            StringData data,
                            BSONObjBuilder* builder) {
      bool foundKeys = false;
@@ -53,7 +53,7 @@
      stats.reserve(kDiskFieldCount);
  
      using string_split_iterator = boost::split_iterator<StringData::const_iterator>;
-@@ -501,7 +501,7 @@ Status parseProcDiskStats(const std::vec
+@@ -597,7 +597,7 @@ Status parseProcDiskStats(const std::vec
  
                  StringData stringValue((*partIt).begin(), (*partIt).end());
  
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Use-strerror_r-only-on-glibc-systems.patch b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Use-strerror_r-only-on-glibc-systems.patch
deleted file mode 100644
index 0334d99..0000000
--- a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0001-Use-strerror_r-only-on-glibc-systems.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-From a4dfc92ff342e59596ab64267a8d4f22f173c23b Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 2 Sep 2017 12:40:41 -0700
-Subject: [PATCH 1/4] Use strerror_r only on glibc systems
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/mongo/util/log.cpp | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/mongo/util/log.cpp b/src/mongo/util/log.cpp
-index 1957eb4791..ddf3908818 100644
---- a/src/mongo/util/log.cpp
-+++ b/src/mongo/util/log.cpp
-@@ -101,7 +101,7 @@ string errnoWithDescription(int errNumber) {
-     char buf[kBuflen];
-     char* msg{nullptr};
- 
--#if defined(__GNUC__) && defined(_GNU_SOURCE)
-+#if defined(__GNUC__) && defined(_GNU_SOURCE) && defined(__GLIBC__)
-     msg = strerror_r(errNumber, buf, kBuflen);
- #elif defined(_WIN32)
- 
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0002-Fix-default-stack-size-to-256K.patch b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0002-Fix-default-stack-size-to-256K.patch
new file mode 100644
index 0000000..085fa50
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0002-Fix-default-stack-size-to-256K.patch
@@ -0,0 +1,39 @@
+From 98543889f7ba38c02eb7cd9822f45e27d619edd6 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 24 Aug 2018 13:07:01 -0700
+Subject: [PATCH 2/2] Fix default stack size to 256K
+
+On musl default stack size is ~80K which is too low
+for mongodb
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ .../platform/stack_locator_pthread_getattr_np.cpp      | 10 ++++++++++
+ 1 file changed, 10 insertions(+)
+
+diff --git a/src/mongo/platform/stack_locator_pthread_getattr_np.cpp b/src/mongo/platform/stack_locator_pthread_getattr_np.cpp
+index 648d26a41c..6e398f00c9 100644
+--- a/src/mongo/platform/stack_locator_pthread_getattr_np.cpp
++++ b/src/mongo/platform/stack_locator_pthread_getattr_np.cpp
+@@ -35,6 +35,16 @@
+ #include "mongo/util/assert_util.h"
+ #include "mongo/util/scopeguard.h"
+ 
++__attribute__((constructor))
++static void set_default_stack_size(void)
++{
++    pthread_attr_t attr;
++    invariant(pthread_attr_init(&attr) == 0);
++    invariant(pthread_attr_setstacksize(&attr, 256*1024) == 0);
++    pthread_setattr_default_np(&attr);
++    invariant(pthread_attr_destroy(&attr) == 0);
++}
++
+ namespace mongo {
+ 
+ StackLocator::StackLocator() {
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0002-d_state.cpp-Add-missing-dependenncy-on-local_shardin.patch b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0002-d_state.cpp-Add-missing-dependenncy-on-local_shardin.patch
deleted file mode 100644
index dc488ad..0000000
--- a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0002-d_state.cpp-Add-missing-dependenncy-on-local_shardin.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 5759878e5d278f11a1063e8fccd1e6b7b54caadf Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 2 Aug 2017 16:25:37 -0700
-Subject: [PATCH 2/2] d_state.cpp: Add missing dependenncy on
- local_sharding_info
-
-Fixes
-| src/mongo/s/d_state.cpp:81: error: undefined reference to 'mongo::enableLocalShardingInfo(mongo::ServiceContext*, std::function<bool (mongo::OperationContext*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)>)'
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/mongo/s/SConscript | 1 +
- 1 file changed, 1 insertion(+)
-
-Index: git/src/mongo/s/SConscript
-===================================================================
---- git.orig/src/mongo/s/SConscript
-+++ git/src/mongo/s/SConscript
-@@ -317,5 +317,6 @@ env.Library(
-         "$BUILD_DIR/mongo/db/s/sharding",
-         "$BUILD_DIR/mongo/executor/network_interface_factory",
-         "$BUILD_DIR/mongo/s/client/shard_local",
-+        "$BUILD_DIR/mongo/s/local_sharding_info",
-     ],
- )
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0003-Conditionalize-glibc-specific-strerror_r.patch b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0003-Conditionalize-glibc-specific-strerror_r.patch
deleted file mode 100644
index 1591f94..0000000
--- a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0003-Conditionalize-glibc-specific-strerror_r.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From 458f80f482a201b427a1c92235804d0c3f98fd51 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 2 Sep 2017 13:01:11 -0700
-Subject: [PATCH 3/4] Conditionalize glibc specific strerror_r
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- .../asio-asio-1-11-0/asio/include/asio/impl/error_code.ipp    | 11 ++++-------
- 1 file changed, 4 insertions(+), 7 deletions(-)
-
-diff --git a/src/third_party/asio-asio-1-11-0/asio/include/asio/impl/error_code.ipp b/src/third_party/asio-asio-1-11-0/asio/include/asio/impl/error_code.ipp
-index 4e7badb14a..0eeae884e2 100644
---- a/src/third_party/asio-asio-1-11-0/asio/include/asio/impl/error_code.ipp
-+++ b/src/third_party/asio-asio-1-11-0/asio/include/asio/impl/error_code.ipp
-@@ -97,17 +97,14 @@ public:
- #if defined(__sun) || defined(__QNX__) || defined(__SYMBIAN32__)
-     using namespace std;
-     return strerror(value);
--#elif defined(__MACH__) && defined(__APPLE__) \
--  || defined(__NetBSD__) || defined(__FreeBSD__) || defined(__OpenBSD__) \
--  || defined(_AIX) || defined(__hpux) || defined(__osf__) \
--  || defined(__ANDROID__)
-+#elif defined(__GLIBC__) && defined(_GNU_SOURCE)
-+    char buf[256] = "";
-+    return strerror_r(value, buf, sizeof(buf));
-+#else
-     char buf[256] = "";
-     using namespace std;
-     strerror_r(value, buf, sizeof(buf));
-     return buf;
--#else
--    char buf[256] = "";
--    return strerror_r(value, buf, sizeof(buf));
- #endif
- #endif // defined(ASIO_WINDOWS)
-   }
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0004-wiredtiger-Disable-strtouq-on-musl.patch b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0004-wiredtiger-Disable-strtouq-on-musl.patch
index e871f2b..a2e1f79 100644
--- a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0004-wiredtiger-Disable-strtouq-on-musl.patch
+++ b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/0004-wiredtiger-Disable-strtouq-on-musl.patch
@@ -8,11 +8,11 @@
  src/third_party/wiredtiger/build_linux/wiredtiger_config.h | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-diff --git a/src/third_party/wiredtiger/build_linux/wiredtiger_config.h b/src/third_party/wiredtiger/build_linux/wiredtiger_config.h
-index 1122e1e319..fdfd48687b 100644
---- a/src/third_party/wiredtiger/build_linux/wiredtiger_config.h
-+++ b/src/third_party/wiredtiger/build_linux/wiredtiger_config.h
-@@ -101,7 +101,7 @@
+Index: git/src/third_party/wiredtiger/build_linux/wiredtiger_config.h
+===================================================================
+--- git.orig/src/third_party/wiredtiger/build_linux/wiredtiger_config.h
++++ git/src/third_party/wiredtiger/build_linux/wiredtiger_config.h
+@@ -104,7 +104,7 @@
  #define HAVE_STRING_H 1
  
  /* Define to 1 if you have the `strtouq' function. */
@@ -21,6 +21,3 @@
  
  /* Define to 1 if you have the `sync_file_range' function. */
  /* #undef HAVE_SYNC_FILE_RANGE */
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/arm64-support.patch b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/arm64-support.patch
index 9046bb2..c068987 100644
--- a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/arm64-support.patch
+++ b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/arm64-support.patch
@@ -7,7 +7,7 @@
 ===================================================================
 --- git.orig/SConstruct
 +++ git/SConstruct
-@@ -990,6 +990,7 @@ elif endian == "big":
+@@ -1055,6 +1055,7 @@ elif endian == "big":
  processor_macros = {
      'arm'     : { 'endian': 'little', 'defines': ('__arm__',) },
      'aarch64' : { 'endian': 'little', 'defines': ('__arm64__', '__aarch64__')},
@@ -19,7 +19,7 @@
 ===================================================================
 --- git.orig/src/third_party/IntelRDFPMathLib20U1/SConscript
 +++ git/src/third_party/IntelRDFPMathLib20U1/SConscript
-@@ -301,7 +301,7 @@ if processor == 'i386':
+@@ -308,7 +308,7 @@ if processor == 'i386':
  elif processor == 'arm':
      cpp_defines['IA32'] = '1'
      cpp_defines['ia32'] = '1'
@@ -32,7 +32,7 @@
 ===================================================================
 --- git.orig/src/third_party/wiredtiger/SConscript
 +++ git/src/third_party/wiredtiger/SConscript
-@@ -139,7 +139,7 @@ condition_map = {
+@@ -151,7 +151,7 @@ condition_map = {
      'POSIX_HOST'   : not env.TargetOSIs('windows'),
      'WINDOWS_HOST' : env.TargetOSIs('windows'),
  
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/disable-hw-crc32-on-arm64-s390x.patch b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/disable-hw-crc32-on-arm64-s390x.patch
index 5c5c20c..23d4923 100644
--- a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/disable-hw-crc32-on-arm64-s390x.patch
+++ b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb/disable-hw-crc32-on-arm64-s390x.patch
@@ -5,7 +5,7 @@
 ===================================================================
 --- git.orig/src/third_party/wiredtiger/SConscript
 +++ git/src/third_party/wiredtiger/SConscript
-@@ -169,7 +169,9 @@ if useSnappy:
+@@ -181,7 +181,9 @@ if useSnappy:
  # If not available at runtime, we fall back to software in some cases.
  #
  # On zSeries we may disable because SLES 11 kernel doe not support the instructions.
@@ -32,7 +32,7 @@
 ===================================================================
 --- git.orig/src/third_party/wiredtiger/src/checksum/zseries/crc32-s390x.c
 +++ git/src/third_party/wiredtiger/src/checksum/zseries/crc32-s390x.c
-@@ -78,6 +78,7 @@ unsigned int __wt_crc32c_le(unsigned int
+@@ -77,6 +77,7 @@ unsigned int __wt_crc32c_le(unsigned int
  		return crc;                                                 \
  	}
  
@@ -40,7 +40,7 @@
  /* Main CRC-32 functions */
  DEFINE_CRC32_VX(__wt_crc32c_le_vx, __wt_crc32c_le_vgfm_16, __wt_crc32c_le)
  
-@@ -90,6 +91,7 @@ __wt_checksum_hw(const void *chunk, size
+@@ -89,6 +90,7 @@ __wt_checksum_hw(const void *chunk, size
  {
  	return (~__wt_crc32c_le_vx(0xffffffff, chunk, len));
  }
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb_git.bb b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb_git.bb
index bb3ff3b..d39ab0a 100644
--- a/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb_git.bb
+++ b/meta-openembedded/meta-oe/recipes-dbs/mongodb/mongodb_git.bb
@@ -3,48 +3,44 @@
 LIC_FILES_CHKSUM = "file://GNU-AGPL-3.0.txt;md5=73f1eb20517c55bf9493b7dd6e480788 \
                     file://APACHE-2.0.txt;md5=3b83ef96387f14655fc854ddc3c6bd57"
 
-DEPENDS = "openssl libpcre libpcap zlib python boost"
+DEPENDS = "openssl libpcre libpcap zlib boost curl python \
+           python-setuptools-native python-typing-native \
+           python-pyyaml-native python-cheetah-native \
+           "
 
-inherit scons dos2unix siteinfo
+inherit scons dos2unix siteinfo pythonnative
 
-PV = "3.4.13+git${SRCPV}"
-SRCREV = "fbdef2ccc53e0fcc9afb570063633d992b2aae42"
-SRC_URI = "git://github.com/mongodb/mongo.git;branch=v3.4 \
+PV = "4.0.1+git${SRCPV}"
+#v4.0.1
+SRCREV = "54f1582fc6eb01de4d4c42f26fc133e623f065fb"
+SRC_URI = "git://github.com/mongodb/mongo.git;branch=v4.0 \
            file://0001-Tell-scons-to-use-build-settings-from-environment-va.patch \
-           file://0002-d_state.cpp-Add-missing-dependenncy-on-local_shardin.patch \
            file://0001-Use-long-long-instead-of-int64_t.patch \
            file://0001-Use-__GLIBC__-to-control-use-of-gnu_get_libc_version.patch \
-           file://0001-Use-strerror_r-only-on-glibc-systems.patch \
            file://0002-Add-a-definition-for-the-macro-__ELF_NATIVE_CLASS.patch \
-           file://0003-Conditionalize-glibc-specific-strerror_r.patch \
            file://arm64-support.patch \
            file://0001-IntelRDFPMathLib20U1-Check-for-__DEFINED_wchar_t.patch \
            file://disable-hw-crc32-on-arm64-s390x.patch \
+           file://0001-Support-deprecated-resolver-functions.patch \
            "
 SRC_URI_append_libc-musl ="\
+           file://0002-Fix-default-stack-size-to-256K.patch \
            file://0004-wiredtiger-Disable-strtouq-on-musl.patch \
            "
 S = "${WORKDIR}/git"
 
-# Wiredtiger supports only 64-bit platforms
-PACKAGECONFIG_x86-64 ??= "tcmalloc wiredtiger"
-PACKAGECONFIG_aarch64 ??= "tcmalloc wiredtiger"
+COMPATIBLE_HOST ?= '(x86_64|i.86|powerpc64|arm|aarch64).*-linux'
+
+COMPATIBLE_HOST_arm = "null"
+COMPATIBLE_HOST_libc-musl_x86 = "null"
+
 PACKAGECONFIG ??= "tcmalloc"
 # gperftools compilation fails for arm below v7 because of missing support of
 # dmb operation. So we use system-allocator instead of tcmalloc
 PACKAGECONFIG_remove_armv6 = "tcmalloc"
 PACKAGECONFIG_remove_libc-musl = "tcmalloc"
 
-#std::current_exception is undefined for arm < v6
-COMPATIBLE_MACHINE_armv4 = "(!.*armv4).*"
-COMPATIBLE_MACHINE_armv5 = "(!.*armv5).*"
-COMPATIBLE_MACHINE_armv7a = "(!.*armv7a).*"
-COMPATIBLE_MACHINE_armv7ve = "(!.*armv7ve).*"
-COMPATIBLE_MACHINE_mips64 = "(!.*mips64).*"
-COMPATIBLE_MACHINE_powerpc = "(!.*ppc).*"
-
 PACKAGECONFIG[tcmalloc] = "--use-system-tcmalloc,--allocator=system,gperftools,"
-PACKAGECONFIG[wiredtiger] = "--wiredtiger=on,--wiredtiger=off,,"
 
 EXTRA_OESCONS = "--prefix=${D}${prefix} \
                  LIBPATH=${STAGING_LIBDIR} \
@@ -58,6 +54,7 @@
                  --js-engine=none \
                  --nostrip \
                  --endian=${@oe.utils.conditional('SITEINFO_ENDIANNESS', 'le', 'little', 'big', d)} \
+                 --wiredtiger=${@['off','on'][d.getVar('SITEINFO_BITS') != '32']} \
                  ${PACKAGECONFIG_CONFARGS} \
                  mongod mongos"
 
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mysql/mariadb-native_5.5.59.bb b/meta-openembedded/meta-oe/recipes-dbs/mysql/mariadb-native_5.5.62.bb
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-dbs/mysql/mariadb-native_5.5.59.bb
rename to meta-openembedded/meta-oe/recipes-dbs/mysql/mariadb-native_5.5.62.bb
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mysql/mariadb.inc b/meta-openembedded/meta-oe/recipes-dbs/mysql/mariadb.inc
index 99e7050..8ca5b2b 100644
--- a/meta-openembedded/meta-oe/recipes-dbs/mysql/mariadb.inc
+++ b/meta-openembedded/meta-oe/recipes-dbs/mysql/mariadb.inc
@@ -18,9 +18,10 @@
            file://change-cc-to-cc-version.patch \
            file://0001-disable-ucontext-on-musl.patch \
           "
+SRC_URI[md5sum] = "6375d577e9539b839f44d857e70f82b9"
+SRC_URI[sha256sum] = "56a365af71b8a9ec8bfee0801e2dec95011da8ee7507986ca329be11296411db"
 
-SRC_URI[md5sum] = "3cec4afc06b468687ef576c90148d10d"
-SRC_URI[sha256sum] = "c3269ce20b45b177239fd1e3d6d9428a94131711f12758ebf5f65222278bb110"
+UPSTREAM_CHECK_URI = "https://github.com/MariaDB/server/releases"
 
 S = "${WORKDIR}/mariadb-${PV}"
 
@@ -161,13 +162,15 @@
 }
 
 PACKAGES = "${PN}-dbg ${PN} \
-    libmysqlclient-r libmysqlclient-r-dev libmysqlclient-r-staticdev libmysqlclient-r-dbg \
-    libmysqlclient libmysqlclient-dev libmysqlclient-staticdev libmysqlclient-dbg \
+    libmysqlclient-r libmysqlclient-r-dev libmysqlclient-r-staticdev \
+    libmysqlclient libmysqlclient-dev libmysqlclient-staticdev \
     libmysqld libmysqld-dev ${PN}-client ${PN}-server ${PN}-setupdb ${PN}-leftovers"
 CONFFILES_${PN}-server += "${sysconfdir}/my.cnf ${sysconfdir}/my.cnf.d/server.cnf"
 CONFFILES_${PN}-client += "${sysconfdir}/my.cnf.d/mysql-clients.cnf"
 CONFFILES_libmysqlclient += "${sysconfdir}/my.cnf.d/client.cnf"
 
+RPROVIDES_${PN}-dbg += "libmysqlclient-r-dbg libmysqlclient-dbg"
+
 FILES_${PN} = " "
 RDEPENDS_${PN} = "${PN}-client ${PN}-server"
 ALLOW_EMPTY_${PN} = "1"
@@ -200,8 +203,6 @@
     ${bindir}/mysql_config"
 FILES_libmysqlclient-staticdev = "\
     ${libdir}/*.a"
-FILES_libmysqlclient-dbg = "${libdir}/plugin/.debug/ \
-    ${datadir}/mysql-test/lib/My/SafeProcess/.debug/my_safe_process"
 
 # Avoid warnings about ha_xtradb.so.0.0.0 and ha_innodb_plugin.so.0.0.0
 # which are intentionally non-PIC on 32-bit x86 (see e.g.
@@ -212,7 +213,6 @@
 FILES_libmysqlclient-r-dev = "\
     ${libdir}/libmysqlclient_r.so"
 FILES_libmysqlclient-r-staticdev = "${libdir}/libmysqlclient_r.a"
-FILES_libmysqlclient-r-dbg = "${libdir}/plugin/.debuglibmysqlclient_r.so.*"
 
 FILES_libmysqld = "\
     ${libdir}/libmysqld.so.*"
diff --git a/meta-openembedded/meta-oe/recipes-dbs/mysql/mariadb_5.5.59.bb b/meta-openembedded/meta-oe/recipes-dbs/mysql/mariadb_5.5.62.bb
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-dbs/mysql/mariadb_5.5.59.bb
rename to meta-openembedded/meta-oe/recipes-dbs/mysql/mariadb_5.5.62.bb
diff --git a/meta-openembedded/meta-oe/recipes-dbs/postgresql/files/0001-Sync-our-copy-of-the-timezone-library-with-IANA-rele.patch b/meta-openembedded/meta-oe/recipes-dbs/postgresql/files/0001-Sync-our-copy-of-the-timezone-library-with-IANA-rele.patch
new file mode 100644
index 0000000..6d8c46e
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-dbs/postgresql/files/0001-Sync-our-copy-of-the-timezone-library-with-IANA-rele.patch
@@ -0,0 +1,1164 @@
+From 12bfb778ce688fc662a6cb35f6298734fcf4856f Mon Sep 17 00:00:00 2001
+From: Tom Lane <tgl@sss.pgh.pa.us>
+Date: Fri, 19 Oct 2018 19:36:34 -0400
+Subject: [PATCH] Sync our copy of the timezone library with IANA release
+ tzcode2018f.
+
+About half of this is purely cosmetic changes to reduce the diff between
+our code and theirs, like inserting "const" markers where they have them.
+
+The other half is tracking actual code changes in zic.c and localtime.c.
+I don't think any of these represent near-term compatibility hazards, but
+it seems best to stay up to date.
+
+I also fixed longstanding bugs in our code for producing the
+known_abbrevs.txt list, which by chance hadn't been exposed before,
+but which resulted in some garbage output after applying the upstream
+changes in zic.c.  Notably, because upstream removed their old phony
+transitions at the Big Bang, it's now necessary to cope with TZif files
+containing no DST transition times at all.
+
+Upstream-Status: Backport
+Signed-off-by: Armin Kuster <akuster@mvista.com>
+
+---
+ src/timezone/README      |   2 +-
+ src/timezone/localtime.c | 126 ++++++++++++------
+ src/timezone/pgtz.h      |  10 +-
+ src/timezone/private.h   |   3 +
+ src/timezone/strftime.c  |  10 +-
+ src/timezone/tzfile.h    |   7 +-
+ src/timezone/zic.c       | 330 ++++++++++++++++++++++++++---------------------
+ 7 files changed, 291 insertions(+), 197 deletions(-)
+
+Index: postgresql-10.5/src/timezone/README
+===================================================================
+--- postgresql-10.5.orig/src/timezone/README
++++ postgresql-10.5/src/timezone/README
+@@ -55,7 +55,7 @@ match properly on the old version.
+ Time Zone code
+ ==============
+ 
+-The code in this directory is currently synced with tzcode release 2018e.
++The code in this directory is currently synced with tzcode release 2018f.
+ There are many cosmetic (and not so cosmetic) differences from the
+ original tzcode library, but diffs in the upstream version should usually
+ be propagated to our version.  Here are some notes about that.
+Index: postgresql-10.5/src/timezone/localtime.c
+===================================================================
+--- postgresql-10.5.orig/src/timezone/localtime.c
++++ postgresql-10.5/src/timezone/localtime.c
+@@ -1,3 +1,5 @@
++/* Convert timestamp from pg_time_t to struct pg_tm.  */
++
+ /*
+  * This file is in the public domain, so clarified as of
+  * 1996-06-05 by Arthur David Olson.
+@@ -117,7 +119,7 @@ init_ttinfo(struct ttinfo *s, int32 gmto
+ }
+ 
+ static int32
+-detzcode(const char *codep)
++detzcode(const char *const codep)
+ {
+ 	int32		result;
+ 	int			i;
+@@ -143,7 +145,7 @@ detzcode(const char *codep)
+ }
+ 
+ static int64
+-detzcode64(const char *codep)
++detzcode64(const char *const codep)
+ {
+ 	uint64		result;
+ 	int			i;
+@@ -258,8 +260,13 @@ tzloadbody(char const *name, char *canon
+ 		int32		charcnt = detzcode(up->tzhead.tzh_charcnt);
+ 		char const *p = up->buf + tzheadsize;
+ 
++		/*
++		 * Although tzfile(5) currently requires typecnt to be nonzero,
++		 * support future formats that may allow zero typecnt in files that
++		 * have a TZ string and no transitions.
++		 */
+ 		if (!(0 <= leapcnt && leapcnt < TZ_MAX_LEAPS
+-			  && 0 < typecnt && typecnt < TZ_MAX_TYPES
++			  && 0 <= typecnt && typecnt < TZ_MAX_TYPES
+ 			  && 0 <= timecnt && timecnt < TZ_MAX_TIMES
+ 			  && 0 <= charcnt && charcnt < TZ_MAX_CHARS
+ 			  && (ttisstdcnt == typecnt || ttisstdcnt == 0)
+@@ -416,8 +423,7 @@ tzloadbody(char const *name, char *canon
+ 		struct state *ts = &lsp->u.st;
+ 
+ 		up->buf[nread - 1] = '\0';
+-		if (tzparse(&up->buf[1], ts, false)
+-			&& ts->typecnt == 2)
++		if (tzparse(&up->buf[1], ts, false))
+ 		{
+ 			/*
+ 			 * Attempt to reuse existing abbreviations. Without this,
+@@ -430,7 +436,7 @@ tzloadbody(char const *name, char *canon
+ 			int			gotabbr = 0;
+ 			int			charcnt = sp->charcnt;
+ 
+-			for (i = 0; i < 2; i++)
++			for (i = 0; i < ts->typecnt; i++)
+ 			{
+ 				char	   *tsabbr = ts->chars + ts->ttis[i].tt_abbrind;
+ 				int			j;
+@@ -455,7 +461,7 @@ tzloadbody(char const *name, char *canon
+ 					}
+ 				}
+ 			}
+-			if (gotabbr == 2)
++			if (gotabbr == ts->typecnt)
+ 			{
+ 				sp->charcnt = charcnt;
+ 
+@@ -470,7 +476,8 @@ tzloadbody(char const *name, char *canon
+ 					sp->timecnt--;
+ 
+ 				for (i = 0; i < ts->timecnt; i++)
+-					if (sp->ats[sp->timecnt - 1] < ts->ats[i])
++					if (sp->timecnt == 0
++						|| sp->ats[sp->timecnt - 1] < ts->ats[i])
+ 						break;
+ 				while (i < ts->timecnt
+ 					   && sp->timecnt < TZ_MAX_TIMES)
+@@ -481,11 +488,13 @@ tzloadbody(char const *name, char *canon
+ 					sp->timecnt++;
+ 					i++;
+ 				}
+-				sp->ttis[sp->typecnt++] = ts->ttis[0];
+-				sp->ttis[sp->typecnt++] = ts->ttis[1];
++				for (i = 0; i < ts->typecnt; i++)
++					sp->ttis[sp->typecnt++] = ts->ttis[i];
+ 			}
+ 		}
+ 	}
++	if (sp->typecnt == 0)
++		return EINVAL;
+ 	if (sp->timecnt > 1)
+ 	{
+ 		for (i = 1; i < sp->timecnt; ++i)
+@@ -507,6 +516,18 @@ tzloadbody(char const *name, char *canon
+ 	}
+ 
+ 	/*
++	 * Infer sp->defaulttype from the data.  Although this default type is
++	 * always zero for data from recent tzdb releases, things are trickier for
++	 * data from tzdb 2018e or earlier.
++	 *
++	 * The first set of heuristics work around bugs in 32-bit data generated
++	 * by tzdb 2013c or earlier.  The workaround is for zones like
++	 * Australia/Macquarie where timestamps before the first transition have a
++	 * time type that is not the earliest standard-time type.  See:
++	 * https://mm.icann.org/pipermail/tz/2013-May/019368.html
++	 */
++
++	/*
+ 	 * If type 0 is unused in transitions, it's the type to use for early
+ 	 * times.
+ 	 */
+@@ -529,6 +550,11 @@ tzloadbody(char const *name, char *canon
+ 	}
+ 
+ 	/*
++	 * The next heuristics are for data generated by tzdb 2018e or earlier,
++	 * for zones like EST5EDT where the first transition is to DST.
++	 */
++
++	/*
+ 	 * If no result yet, find the first standard type. If there is none, punt
+ 	 * to type zero.
+ 	 */
+@@ -542,7 +568,14 @@ tzloadbody(char const *name, char *canon
+ 				break;
+ 			}
+ 	}
++
++	/*
++	 * A simple 'sp->defaulttype = 0;' would suffice here if we didn't have to
++	 * worry about 2018e-or-earlier data.  Even simpler would be to remove the
++	 * defaulttype member and just use 0 in its place.
++	 */
+ 	sp->defaulttype = i;
++
+ 	return 0;
+ }
+ 
+@@ -601,10 +634,11 @@ static const int year_lengths[2] = {
+ };
+ 
+ /*
+- * Given a pointer into a time zone string, scan until a character that is not
+- * a valid character in a zone name is found. Return a pointer to that
+- * character.
++ * Given a pointer into a timezone string, scan until a character that is not
++ * a valid character in a time zone abbreviation is found.
++ * Return a pointer to that character.
+  */
++
+ static const char *
+ getzname(const char *strp)
+ {
+@@ -617,15 +651,17 @@ getzname(const char *strp)
+ }
+ 
+ /*
+- * Given a pointer into an extended time zone string, scan until the ending
+- * delimiter of the zone name is located. Return a pointer to the delimiter.
++ * Given a pointer into an extended timezone string, scan until the ending
++ * delimiter of the time zone abbreviation is located.
++ * Return a pointer to the delimiter.
+  *
+  * As with getzname above, the legal character set is actually quite
+  * restricted, with other characters producing undefined results.
+  * We don't do any checking here; checking is done later in common-case code.
+  */
++
+ static const char *
+-getqzname(const char *strp, int delim)
++getqzname(const char *strp, const int delim)
+ {
+ 	int			c;
+ 
+@@ -635,13 +671,14 @@ getqzname(const char *strp, int delim)
+ }
+ 
+ /*
+- * Given a pointer into a time zone string, extract a number from that string.
++ * Given a pointer into a timezone string, extract a number from that string.
+  * Check that the number is within a specified range; if it is not, return
+  * NULL.
+  * Otherwise, return a pointer to the first character not part of the number.
+  */
++
+ static const char *
+-getnum(const char *strp, int *nump, int min, int max)
++getnum(const char *strp, int *const nump, const int min, const int max)
+ {
+ 	char		c;
+ 	int			num;
+@@ -663,14 +700,15 @@ getnum(const char *strp, int *nump, int
+ }
+ 
+ /*
+- * Given a pointer into a time zone string, extract a number of seconds,
++ * Given a pointer into a timezone string, extract a number of seconds,
+  * in hh[:mm[:ss]] form, from the string.
+  * If any error occurs, return NULL.
+  * Otherwise, return a pointer to the first character not part of the number
+  * of seconds.
+  */
++
+ static const char *
+-getsecs(const char *strp, int32 *secsp)
++getsecs(const char *strp, int32 *const secsp)
+ {
+ 	int			num;
+ 
+@@ -704,13 +742,14 @@ getsecs(const char *strp, int32 *secsp)
+ }
+ 
+ /*
+- * Given a pointer into a time zone string, extract an offset, in
++ * Given a pointer into a timezone string, extract an offset, in
+  * [+-]hh[:mm[:ss]] form, from the string.
+  * If any error occurs, return NULL.
+  * Otherwise, return a pointer to the first character not part of the time.
+  */
++
+ static const char *
+-getoffset(const char *strp, int32 *offsetp)
++getoffset(const char *strp, int32 *const offsetp)
+ {
+ 	bool		neg = false;
+ 
+@@ -730,13 +769,14 @@ getoffset(const char *strp, int32 *offse
+ }
+ 
+ /*
+- * Given a pointer into a time zone string, extract a rule in the form
++ * Given a pointer into a timezone string, extract a rule in the form
+  * date[/time]. See POSIX section 8 for the format of "date" and "time".
+  * If a valid rule is not found, return NULL.
+  * Otherwise, return a pointer to the first character not part of the rule.
+  */
++
+ static const char *
+-getrule(const char *strp, struct rule *rulep)
++getrule(const char *strp, struct rule *const rulep)
+ {
+ 	if (*strp == 'J')
+ 	{
+@@ -795,9 +835,10 @@ getrule(const char *strp, struct rule *r
+  * Given a year, a rule, and the offset from UT at the time that rule takes
+  * effect, calculate the year-relative time that rule takes effect.
+  */
++
+ static int32
+-transtime(int year, const struct rule *rulep,
+-		  int32 offset)
++transtime(const int year, const struct rule *const rulep,
++		  const int32 offset)
+ {
+ 	bool		leapyear;
+ 	int32		value;
+@@ -981,7 +1022,7 @@ tzparse(const char *name, struct state *
+ 		{
+ 			dstname = name;
+ 			name = getzname(name);
+-			dstlen = name - dstname;	/* length of DST zone name */
++			dstlen = name - dstname;	/* length of DST abbr. */
+ 		}
+ 		if (!dstlen)
+ 			return false;
+@@ -1023,8 +1064,8 @@ tzparse(const char *name, struct state *
+ 			/*
+ 			 * Two transitions per year, from EPOCH_YEAR forward.
+ 			 */
+-			init_ttinfo(&sp->ttis[0], -dstoffset, true, stdlen + 1);
+-			init_ttinfo(&sp->ttis[1], -stdoffset, false, 0);
++			init_ttinfo(&sp->ttis[0], -stdoffset, false, 0);
++			init_ttinfo(&sp->ttis[1], -dstoffset, true, stdlen + 1);
+ 			sp->defaulttype = 0;
+ 			timecnt = 0;
+ 			janfirst = 0;
+@@ -1073,19 +1114,15 @@ tzparse(const char *name, struct state *
+ 					if (!increment_overflow_time
+ 						(&sp->ats[timecnt],
+ 						 janoffset + starttime))
+-						sp->types[timecnt++] = reversed;
+-					else if (janoffset)
+-						sp->defaulttype = reversed;
++						sp->types[timecnt++] = !reversed;
+ 					sp->ats[timecnt] = janfirst;
+ 					if (!increment_overflow_time
+ 						(&sp->ats[timecnt],
+ 						 janoffset + endtime))
+ 					{
+-						sp->types[timecnt++] = !reversed;
++						sp->types[timecnt++] = reversed;
+ 						yearlim = year + YEARSPERREPEAT + 1;
+ 					}
+-					else if (janoffset)
+-						sp->defaulttype = !reversed;
+ 				}
+ 				if (increment_overflow_time
+ 					(&janfirst, janoffset + yearsecs))
+@@ -1094,7 +1131,10 @@ tzparse(const char *name, struct state *
+ 			}
+ 			sp->timecnt = timecnt;
+ 			if (!timecnt)
++			{
++				sp->ttis[0] = sp->ttis[1];
+ 				sp->typecnt = 1;	/* Perpetual DST.  */
++			}
+ 			else if (YEARSPERREPEAT < year - yearbeg)
+ 				sp->goback = sp->goahead = true;
+ 		}
+@@ -1163,7 +1203,6 @@ tzparse(const char *name, struct state *
+ 					 * otherwise, add the standard time offset to the
+ 					 * transition time.
+ 					 */
+-
+ 					/*
+ 					 * Transitions from DST to DDST will effectively disappear
+ 					 * since POSIX provides for only one DST offset.
+@@ -1217,7 +1256,7 @@ tzparse(const char *name, struct state *
+ }
+ 
+ static void
+-gmtload(struct state *sp)
++gmtload(struct state *const sp)
+ {
+ 	if (tzload(gmt, NULL, sp, true) != 0)
+ 		tzparse(gmt, sp, true);
+@@ -1232,7 +1271,7 @@ gmtload(struct state *sp)
+  */
+ static struct pg_tm *
+ localsub(struct state const *sp, pg_time_t const *timep,
+-		 struct pg_tm *tmp)
++		 struct pg_tm *const tmp)
+ {
+ 	const struct ttinfo *ttisp;
+ 	int			i;
+@@ -1300,6 +1339,11 @@ localsub(struct state const *sp, pg_time
+ 	}
+ 	ttisp = &sp->ttis[i];
+ 
++	/*
++	 * To get (wrong) behavior that's compatible with System V Release 2.0
++	 * you'd replace the statement below with t += ttisp->tt_gmtoff;
++	 * timesub(&t, 0L, sp, tmp);
++	 */
+ 	result = timesub(&t, ttisp->tt_gmtoff, sp, tmp);
+ 	if (result)
+ 	{
+@@ -1322,8 +1366,10 @@ pg_localtime(const pg_time_t *timep, con
+  *
+  * Except we have a private "struct state" for GMT, so no sp is passed in.
+  */
++
+ static struct pg_tm *
+-gmtsub(pg_time_t const *timep, int32 offset, struct pg_tm *tmp)
++gmtsub(pg_time_t const *timep, int32 offset,
++	   struct pg_tm *tmp)
+ {
+ 	struct pg_tm *result;
+ 
+@@ -1337,6 +1383,7 @@ gmtsub(pg_time_t const *timep, int32 off
+ 		gmt_is_set = true;
+ 		gmtload(gmtptr);
+ 	}
++
+ 	result = timesub(timep, offset, gmtptr, tmp);
+ 
+ 	/*
+@@ -1361,6 +1408,7 @@ pg_gmtime(const pg_time_t *timep)
+  * Return the number of leap years through the end of the given year
+  * where, to make the math easy, the answer for year zero is defined as zero.
+  */
++
+ static int
+ leaps_thru_end_of_nonneg(int y)
+ {
+Index: postgresql-10.5/src/timezone/pgtz.h
+===================================================================
+--- postgresql-10.5.orig/src/timezone/pgtz.h
++++ postgresql-10.5/src/timezone/pgtz.h
+@@ -49,10 +49,16 @@ struct state
+ 	pg_time_t	ats[TZ_MAX_TIMES];
+ 	unsigned char types[TZ_MAX_TIMES];
+ 	struct ttinfo ttis[TZ_MAX_TYPES];
+-	char		chars[BIGGEST(BIGGEST(TZ_MAX_CHARS + 1, 3 /* sizeof gmt */ ),
++	char		chars[BIGGEST(BIGGEST(TZ_MAX_CHARS + 1, 4 /* sizeof gmt */ ),
+ 							  (2 * (TZ_STRLEN_MAX + 1)))];
+ 	struct lsinfo lsis[TZ_MAX_LEAPS];
+-	int			defaulttype;	/* for early times or if no transitions */
++
++	/*
++	 * The time type to use for early times or if no transitions. It is always
++	 * zero for recent tzdb releases. It might be nonzero for data from tzdb
++	 * 2018e or earlier.
++	 */
++	int			defaulttype;
+ };
+ 
+ 
+Index: postgresql-10.5/src/timezone/private.h
+===================================================================
+--- postgresql-10.5.orig/src/timezone/private.h
++++ postgresql-10.5/src/timezone/private.h
+@@ -1,4 +1,7 @@
++/* Private header for tzdb code.  */
++
+ #ifndef PRIVATE_H
++
+ #define PRIVATE_H
+ 
+ /*
+Index: postgresql-10.5/src/timezone/strftime.c
+===================================================================
+--- postgresql-10.5.orig/src/timezone/strftime.c
++++ postgresql-10.5/src/timezone/strftime.c
+@@ -1,4 +1,4 @@
+-/* Convert a broken-down timestamp to a string. */
++/* Convert a broken-down timestamp to a string.  */
+ 
+ /*
+  * Copyright 1989 The Regents of the University of California.
+@@ -115,7 +115,7 @@ static char *_add(const char *, char *,
+ static char *_conv(int, const char *, char *, const char *);
+ static char *_fmt(const char *, const struct pg_tm *, char *, const char *,
+ 	 enum warn *);
+-static char *_yconv(int, int, bool, bool, char *, const char *);
++static char *_yconv(int, int, bool, bool, char *, char const *);
+ 
+ 
+ size_t
+@@ -441,7 +441,8 @@ _fmt(const char *format, const struct pg
+ 
+ 					/*
+ 					 * C99 and later say that %Z must be replaced by the empty
+-					 * string if the time zone is not determinable.
++					 * string if the time zone abbreviation is not
++					 * determinable.
+ 					 */
+ 					continue;
+ 				case 'z':
+@@ -519,6 +520,7 @@ _add(const char *str, char *pt, const ch
+  * same output as %Y, and that %Y contains at least 4 bytes,
+  * with more only if necessary.
+  */
++
+ static char *
+ _yconv(int a, int b, bool convert_top, bool convert_yy,
+ 	   char *pt, const char *ptlim)
+@@ -526,7 +528,7 @@ _yconv(int a, int b, bool convert_top, b
+ 	int			lead;
+ 	int			trail;
+ 
+-#define DIVISOR 100
++#define DIVISOR	100
+ 	trail = a % DIVISOR + b % DIVISOR;
+ 	lead = a / DIVISOR + b / DIVISOR + trail / DIVISOR;
+ 	trail %= DIVISOR;
+Index: postgresql-10.5/src/timezone/tzfile.h
+===================================================================
+--- postgresql-10.5.orig/src/timezone/tzfile.h
++++ postgresql-10.5/src/timezone/tzfile.h
+@@ -1,4 +1,7 @@
++/* Layout and location of TZif files.  */
++
+ #ifndef TZFILE_H
++
+ #define TZFILE_H
+ 
+ /*
+@@ -21,14 +24,14 @@
+  * Information about time zone files.
+  */
+ 
+-#define TZDEFAULT	"localtime"
++#define TZDEFAULT	"/etc/localtime"
+ #define TZDEFRULES	"posixrules"
+ 
+ /*
+  * Each file begins with. . .
+  */
+ 
+-#define TZ_MAGIC	"TZif"
++#define	TZ_MAGIC	"TZif"
+ 
+ struct tzhead
+ {
+Index: postgresql-10.5/src/timezone/zic.c
+===================================================================
+--- postgresql-10.5.orig/src/timezone/zic.c
++++ postgresql-10.5/src/timezone/zic.c
+@@ -1,3 +1,5 @@
++/* Compile .zi time zone data into TZif binary files.  */
++
+ /*
+  * This file is in the public domain, so clarified as of
+  * 2006-07-17 by Arthur David Olson.
+@@ -130,8 +132,7 @@ static void adjleap(void);
+ static void associate(void);
+ static void dolink(const char *, const char *, bool);
+ static char **getfields(char *buf);
+-static zic_t gethms(const char *string, const char *errstring,
+-	   bool);
++static zic_t gethms(const char *string, const char *errstring);
+ static zic_t getstdoff(char *, bool *);
+ static void infile(const char *filename);
+ static void inleap(char **fields, int nfields);
+@@ -162,7 +163,7 @@ enum
+ PERCENT_Z_LEN_BOUND = sizeof "+995959" - 1};
+ 
+ /* If true, work around a bug in Qt 5.6.1 and earlier, which mishandles
+-   tz binary files whose POSIX-TZ-style strings contain '<'; see
++   TZif files whose POSIX-TZ-style strings contain '<'; see
+    QTBUG-53071 <https://bugreports.qt.io/browse/QTBUG-53071>.  This
+    workaround will no longer be needed when Qt 5.6.1 and earlier are
+    obsolete, say in the year 2021.  */
+@@ -211,7 +212,7 @@ static int	typecnt;
+ #define ZF_RULE		3
+ #define ZF_FORMAT	4
+ #define ZF_TILYEAR	5
+-#define ZF_TILMONTH 6
++#define ZF_TILMONTH	6
+ #define ZF_TILDAY	7
+ #define ZF_TILTIME	8
+ #define ZONE_MINFIELDS	5
+@@ -224,12 +225,12 @@ static int	typecnt;
+ #define ZFC_GMTOFF	0
+ #define ZFC_RULE	1
+ #define ZFC_FORMAT	2
+-#define ZFC_TILYEAR 3
++#define ZFC_TILYEAR	3
+ #define ZFC_TILMONTH	4
+ #define ZFC_TILDAY	5
+-#define ZFC_TILTIME 6
+-#define ZONEC_MINFIELDS 3
+-#define ZONEC_MAXFIELDS 7
++#define ZFC_TILTIME	6
++#define ZONEC_MINFIELDS	3
++#define ZONEC_MAXFIELDS	7
+ 
+ /*
+  * Which files are which on a Rule line.
+@@ -244,7 +245,7 @@ static int	typecnt;
+ #define RF_TOD		7
+ #define RF_STDOFF	8
+ #define RF_ABBRVAR	9
+-#define RULE_FIELDS 10
++#define RULE_FIELDS	10
+ 
+ /*
+  * Which fields are which on a Link line.
+@@ -252,7 +253,7 @@ static int	typecnt;
+ 
+ #define LF_FROM		1
+ #define LF_TO		2
+-#define LINK_FIELDS 3
++#define LINK_FIELDS	3
+ 
+ /*
+  * Which fields are which on a Leap line.
+@@ -264,7 +265,7 @@ static int	typecnt;
+ #define LP_TIME		4
+ #define LP_CORR		5
+ #define LP_ROLL		6
+-#define LEAP_FIELDS 7
++#define LEAP_FIELDS	7
+ 
+ /*
+  * Year synonyms.
+@@ -998,48 +999,6 @@ dolink(char const *fromfield, char const
+ static zic_t const min_time = MINVAL(zic_t, TIME_T_BITS_IN_FILE);
+ static zic_t const max_time = MAXVAL(zic_t, TIME_T_BITS_IN_FILE);
+ 
+-/*
+- * Estimated time of the Big Bang, in seconds since the POSIX epoch.
+- * rounded downward to the negation of a power of two that is
+- * comfortably outside the error bounds.
+- *
+- * For the time of the Big Bang, see:
+- *
+- * Ade PAR, Aghanim N, Armitage-Caplan C et al.  Planck 2013 results.
+- * I. Overview of products and scientific results.
+- * arXiv:1303.5062 2013-03-20 20:10:01 UTC
+- * <https://arxiv.org/pdf/1303.5062v1> [PDF]
+- *
+- * Page 36, Table 9, row Age/Gyr, column Planck+WP+highL+BAO 68% limits
+- * gives the value 13.798 plus-or-minus 0.037 billion years.
+- * Multiplying this by 1000000000 and then by 31557600 (the number of
+- * seconds in an astronomical year) gives a value that is comfortably
+- * less than 2**59, so BIG_BANG is - 2**59.
+- *
+- * BIG_BANG is approximate, and may change in future versions.
+- * Please do not rely on its exact value.
+- */
+-
+-#ifndef BIG_BANG
+-#define BIG_BANG (- (((zic_t) 1) << 59))
+-#endif
+-
+-/* If true, work around GNOME bug 730332
+-   <https://bugzilla.gnome.org/show_bug.cgi?id=730332>
+-   by refusing to output time stamps before BIG_BANG.
+-   Such time stamps are physically suspect anyway.
+-
+-   The GNOME bug is scheduled to be fixed in GNOME 3.22, and if so
+-   this workaround will no longer be needed when GNOME 3.21 and
+-   earlier are obsolete, say in the year 2021.  */
+-enum
+-{
+-WORK_AROUND_GNOME_BUG_730332 = true};
+-
+-static const zic_t early_time = (WORK_AROUND_GNOME_BUG_730332
+-								 ? BIG_BANG
+-								 : MINVAL(zic_t, TIME_T_BITS_IN_FILE));
+-
+ /* Return true if NAME is a directory.  */
+ static bool
+ itsdir(char const *name)
+@@ -1281,8 +1240,9 @@ infile(const char *name)
+  * A null string maps to zero.
+  * Call error with errstring and return zero on errors.
+  */
++
+ static zic_t
+-gethms(char const *string, char const *errstring, bool signable)
++gethms(char const *string, char const *errstring)
+ {
+ 	/* PG: make hh be int not zic_t to avoid sscanf portability issues */
+ 	int			hh;
+@@ -1299,9 +1259,7 @@ gethms(char const *string, char const *e
+ 
+ 	if (string == NULL || *string == '\0')
+ 		return 0;
+-	if (!signable)
+-		sign = 1;
+-	else if (*string == '-')
++	if (*string == '-')
+ 	{
+ 		sign = -1;
+ 		++string;
+@@ -1384,7 +1342,7 @@ getstdoff(char *field, bool *isdst)
+ 				break;
+ 		}
+ 	}
+-	stdoff = gethms(field, _("invalid saved time"), true);
++	stdoff = gethms(field, _("invalid saved time"));
+ 	*isdst = dst < 0 ? stdoff != 0 : dst;
+ 	return stdoff;
+ }
+@@ -1399,10 +1357,29 @@ inrule(char **fields, int nfields)
+ 		error(_("wrong number of fields on Rule line"));
+ 		return;
+ 	}
+-	if (*fields[RF_NAME] == '\0')
++	switch (*fields[RF_NAME])
+ 	{
+-		error(_("nameless rule"));
+-		return;
++		case '\0':
++		case ' ':
++		case '\f':
++		case '\n':
++		case '\r':
++		case '\t':
++		case '\v':
++		case '+':
++		case '-':
++		case '0':
++		case '1':
++		case '2':
++		case '3':
++		case '4':
++		case '5':
++		case '6':
++		case '7':
++		case '8':
++		case '9':
++			error(_("Invalid rule name \"%s\""), fields[RF_NAME]);
++			return;
+ 	}
+ 	r.r_filename = filename;
+ 	r.r_linenum = linenum;
+@@ -1507,7 +1484,7 @@ inzsub(char **fields, int nfields, bool
+ 	}
+ 	z.z_filename = filename;
+ 	z.z_linenum = linenum;
+-	z.z_gmtoff = gethms(fields[i_gmtoff], _("invalid UT offset"), true);
++	z.z_gmtoff = gethms(fields[i_gmtoff], _("invalid UT offset"));
+ 	if ((cp = strchr(fields[i_format], '%')) != NULL)
+ 	{
+ 		if ((*++cp != 's' && *cp != 'z') || strchr(cp, '%')
+@@ -1649,7 +1626,7 @@ inleap(char **fields, int nfields)
+ 		return;
+ 	}
+ 	t = dayoff * SECSPERDAY;
+-	tod = gethms(fields[LP_TIME], _("invalid time of day"), false);
++	tod = gethms(fields[LP_TIME], _("invalid time of day"));
+ 	cp = fields[LP_CORR];
+ 	{
+ 		bool		positive;
+@@ -1757,7 +1734,7 @@ rulesub(struct rule *rp, const char *loy
+ 				break;
+ 		}
+ 	}
+-	rp->r_tod = gethms(dp, _("invalid time of day"), false);
++	rp->r_tod = gethms(dp, _("invalid time of day"));
+ 	free(dp);
+ 
+ 	/*
+@@ -1942,7 +1919,43 @@ is32(const zic_t x)
+ }
+ 
+ static void
+-writezone(const char *const name, const char *const string, char version)
++swaptypes(int i, int j)
++{
++	{
++		zic_t		t = gmtoffs[i];
++
++		gmtoffs[i] = gmtoffs[j];
++		gmtoffs[j] = t;
++	}
++	{
++		char		t = isdsts[i];
++
++		isdsts[i] = isdsts[j];
++		isdsts[j] = t;
++	}
++	{
++		unsigned char t = abbrinds[i];
++
++		abbrinds[i] = abbrinds[j];
++		abbrinds[j] = t;
++	}
++	{
++		bool		t = ttisstds[i];
++
++		ttisstds[i] = ttisstds[j];
++		ttisstds[j] = t;
++	}
++	{
++		bool		t = ttisgmts[i];
++
++		ttisgmts[i] = ttisgmts[j];
++		ttisgmts[j] = t;
++	}
++}
++
++static void
++writezone(const char *const name, const char *const string, char version,
++		  int defaulttype)
+ {
+ 	FILE	   *fp;
+ 	ptrdiff_t	i,
+@@ -1977,14 +1990,12 @@ writezone(const char *const name, const
+ 
+ 		toi = 0;
+ 		fromi = 0;
+-		while (fromi < timecnt && attypes[fromi].at < early_time)
+-			++fromi;
+ 		for (; fromi < timecnt; ++fromi)
+ 		{
+-			if (toi > 1 && ((attypes[fromi].at +
+-							 gmtoffs[attypes[toi - 1].type]) <=
+-							(attypes[toi - 1].at +
+-							 gmtoffs[attypes[toi - 2].type])))
++			if (toi != 0 && ((attypes[fromi].at +
++							  gmtoffs[attypes[toi - 1].type]) <=
++							 (attypes[toi - 1].at + gmtoffs[toi == 1 ? 0
++															: attypes[toi - 2].type])))
+ 			{
+ 				attypes[toi - 1].type =
+ 					attypes[fromi].type;
+@@ -2019,8 +2030,8 @@ writezone(const char *const name, const
+ 	}
+ 
+ 	/*
+-	 * Work around QTBUG-53071 for time stamps less than y2038_boundary - 1,
+-	 * by inserting a no-op transition at time y2038_boundary - 1. This works
++	 * Work around QTBUG-53071 for timestamps less than y2038_boundary - 1, by
++	 * inserting a no-op transition at time y2038_boundary - 1. This works
+ 	 * only for timestamps before the boundary, which should be good enough in
+ 	 * practice as QTBUG-53071 should be long-dead by 2038.
+ 	 */
+@@ -2116,7 +2127,8 @@ writezone(const char *const name, const
+ 		int			thisleapi,
+ 					thisleapcnt,
+ 					thisleaplim;
+-		int			writetype[TZ_MAX_TYPES];
++		int			old0;
++		char		omittype[TZ_MAX_TYPES];
+ 		int			typemap[TZ_MAX_TYPES];
+ 		int			thistypecnt;
+ 		char		thischars[TZ_MAX_CHARS];
+@@ -2144,28 +2156,19 @@ writezone(const char *const name, const
+ 			error(_("too many transition times"));
+ 		thistimelim = thistimei + thistimecnt;
+ 		thisleaplim = thisleapi + thisleapcnt;
+-		for (i = 0; i < typecnt; ++i)
+-			writetype[i] = thistimecnt == timecnt;
+-		if (thistimecnt == 0)
+-		{
+-			/*
+-			 * No transition times fall in the current (32- or 64-bit) window.
+-			 */
+-			if (typecnt != 0)
+-				writetype[typecnt - 1] = true;
+-		}
+-		else
+-		{
+-			for (i = thistimei - 1; i < thistimelim; ++i)
+-				if (i >= 0)
+-					writetype[types[i]] = true;
++		memset(omittype, true, typecnt);
++		omittype[defaulttype] = false;
++		for (i = thistimei; i < thistimelim; i++)
++			omittype[types[i]] = false;
++
++		/*
++		 * Reorder types to make DEFAULTTYPE type 0. Use TYPEMAP to swap OLD0
++		 * and DEFAULTTYPE so that DEFAULTTYPE appears as type 0 in the output
++		 * instead of OLD0.  TYPEMAP also omits unused types.
++		 */
++		old0 = strlen(omittype);
++		swaptypes(old0, defaulttype);
+ 
+-			/*
+-			 * For America/Godthab and Antarctica/Palmer
+-			 */
+-			if (thistimei == 0)
+-				writetype[0] = true;
+-		}
+ #ifndef LEAVE_SOME_PRE_2011_SYSTEMS_IN_THE_LURCH
+ 
+ 		/*
+@@ -2187,8 +2190,8 @@ writezone(const char *const name, const
+ 					mrudst = types[i];
+ 				else
+ 					mrustd = types[i];
+-			for (i = 0; i < typecnt; ++i)
+-				if (writetype[i])
++			for (i = old0; i < typecnt; i++)
++				if (!omittype[i])
+ 				{
+ 					if (isdsts[i])
+ 						hidst = i;
+@@ -2205,7 +2208,7 @@ writezone(const char *const name, const
+ 							   ttisstds[mrudst],
+ 							   ttisgmts[mrudst]);
+ 				isdsts[mrudst] = 1;
+-				writetype[type] = true;
++				omittype[type] = false;
+ 			}
+ 			if (histd >= 0 && mrustd >= 0 && histd != mrustd &&
+ 				gmtoffs[histd] != gmtoffs[mrustd])
+@@ -2217,22 +2220,26 @@ writezone(const char *const name, const
+ 							   ttisstds[mrustd],
+ 							   ttisgmts[mrustd]);
+ 				isdsts[mrustd] = 0;
+-				writetype[type] = true;
++				omittype[type] = false;
+ 			}
+ 		}
+ #endif							/* !defined
+ 								 * LEAVE_SOME_PRE_2011_SYSTEMS_IN_THE_LURCH */
+ 		thistypecnt = 0;
+-		for (i = 0; i < typecnt; ++i)
+-			typemap[i] = writetype[i] ? thistypecnt++ : -1;
++		for (i = old0; i < typecnt; i++)
++			if (!omittype[i])
++				typemap[i == old0 ? defaulttype
++						: i == defaulttype ? old0 : i]
++					= thistypecnt++;
++
+ 		for (i = 0; i < sizeof indmap / sizeof indmap[0]; ++i)
+ 			indmap[i] = -1;
+ 		thischarcnt = 0;
+-		for (i = 0; i < typecnt; ++i)
++		for (i = old0; i < typecnt; i++)
+ 		{
+ 			char	   *thisabbr;
+ 
+-			if (!writetype[i])
++			if (omittype[i])
+ 				continue;
+ 			if (indmap[abbrinds[i]] >= 0)
+ 				continue;
+@@ -2267,23 +2274,16 @@ writezone(const char *const name, const
+ 		DO(tzh_typecnt);
+ 		DO(tzh_charcnt);
+ #undef DO
+-		for (i = thistimei; i < thistimelim; ++i)
+-			if (pass == 1)
+ 
+-				/*
+-				 * Output an INT32_MIN "transition" if appropriate; see above.
+-				 */
+-				puttzcode(((ats[i] < PG_INT32_MIN) ?
+-						   PG_INT32_MIN : ats[i]), fp);
+-			else
++		/* PG: print current timezone abbreviations if requested */
++		if (print_abbrevs && pass == 2)
++		{
++			/* Print "type" data for periods ending after print_cutoff */
++			for (i = thistimei; i < thistimelim; ++i)
+ 			{
+-				puttzcode64(ats[i], fp);
+-
+-				/* Print current timezone abbreviations if requested */
+-				if (print_abbrevs &&
+-					(i == thistimelim - 1 || ats[i + 1] > print_cutoff))
++				if (i == thistimelim - 1 || ats[i + 1] > print_cutoff)
+ 				{
+-					unsigned char tm = typemap[types[i]];
++					unsigned char tm = types[i];
+ 					char	   *thisabbrev = &thischars[indmap[abbrinds[tm]]];
+ 
+ 					/* filter out assorted junk entries */
+@@ -2295,6 +2295,32 @@ writezone(const char *const name, const
+ 								isdsts[tm] ? "\tD" : "");
+ 				}
+ 			}
++			/* Print the default type if we have no transitions at all */
++			if (thistimei >= thistimelim)
++			{
++				unsigned char tm = defaulttype;
++				char	   *thisabbrev = &thischars[indmap[abbrinds[tm]]];
++
++				/* filter out assorted junk entries */
++				if (strcmp(thisabbrev, GRANDPARENTED) != 0 &&
++					strcmp(thisabbrev, "zzz") != 0)
++					fprintf(stdout, "%s\t" INT64_FORMAT "%s\n",
++							thisabbrev,
++							gmtoffs[tm],
++							isdsts[tm] ? "\tD" : "");
++			}
++		}
++
++		for (i = thistimei; i < thistimelim; ++i)
++			if (pass == 1)
++
++				/*
++				 * Output an INT32_MIN "transition" if appropriate; see above.
++				 */
++				puttzcode(((ats[i] < PG_INT32_MIN) ?
++						   PG_INT32_MIN : ats[i]), fp);
++			else
++				puttzcode64(ats[i], fp);
+ 		for (i = thistimei; i < thistimelim; ++i)
+ 		{
+ 			unsigned char uc;
+@@ -2302,8 +2328,8 @@ writezone(const char *const name, const
+ 			uc = typemap[types[i]];
+ 			fwrite(&uc, sizeof uc, 1, fp);
+ 		}
+-		for (i = 0; i < typecnt; ++i)
+-			if (writetype[i])
++		for (i = old0; i < typecnt; i++)
++			if (!omittype[i])
+ 			{
+ 				puttzcode(gmtoffs[i], fp);
+ 				putc(isdsts[i], fp);
+@@ -2346,12 +2372,13 @@ writezone(const char *const name, const
+ 				puttzcode64(todo, fp);
+ 			puttzcode(corr[i], fp);
+ 		}
+-		for (i = 0; i < typecnt; ++i)
+-			if (writetype[i])
++		for (i = old0; i < typecnt; i++)
++			if (!omittype[i])
+ 				putc(ttisstds[i], fp);
+-		for (i = 0; i < typecnt; ++i)
+-			if (writetype[i])
++		for (i = old0; i < typecnt; i++)
++			if (!omittype[i])
+ 				putc(ttisgmts[i], fp);
++		swaptypes(old0, defaulttype);
+ 	}
+ 	fprintf(fp, "\n%s\n", string);
+ 	close_file(fp, directory, name);
+@@ -2757,6 +2784,7 @@ outzone(const struct zone *zpfirst, ptrd
+ 	zic_t		one = 1;
+ 	zic_t		y2038_boundary = one << 31;
+ 	zic_t		max_year0;
++	int			defaulttype = -1;
+ 
+ 	max_abbr_len = 2 + max_format_len + max_abbrvar_len;
+ 	max_envvar_len = 2 * max_abbr_len + 5 * 9;
+@@ -2880,9 +2908,9 @@ outzone(const struct zone *zpfirst, ptrd
+ 		 */
+ 		stdoff = 0;
+ 		zp = &zpfirst[i];
+-		usestart = i > 0 && (zp - 1)->z_untiltime > early_time;
++		usestart = i > 0 && (zp - 1)->z_untiltime > min_time;
+ 		useuntil = i < (zonecount - 1);
+-		if (useuntil && zp->z_untiltime <= early_time)
++		if (useuntil && zp->z_untiltime <= min_time)
+ 			continue;
+ 		gmtoff = zp->z_gmtoff;
+ 		eat(zp->z_filename, zp->z_linenum);
+@@ -2901,7 +2929,7 @@ outzone(const struct zone *zpfirst, ptrd
+ 				usestart = false;
+ 			}
+ 			else
+-				addtt(early_time, type);
++				defaulttype = type;
+ 		}
+ 		else
+ 			for (year = min_year; year <= max_year; ++year)
+@@ -3032,6 +3060,8 @@ outzone(const struct zone *zpfirst, ptrd
+ 					offset = oadd(zp->z_gmtoff, rp->r_stdoff);
+ 					type = addtype(offset, ab, rp->r_isdst,
+ 								   rp->r_todisstd, rp->r_todisgmt);
++					if (defaulttype < 0 && !rp->r_isdst)
++						defaulttype = type;
+ 					if (rp->r_hiyear == ZIC_MAX
+ 						&& !(0 <= lastatmax
+ 							 && ktime < attypes[lastatmax].at))
+@@ -3050,11 +3080,15 @@ outzone(const struct zone *zpfirst, ptrd
+ 			if (*startbuf == '\0')
+ 				error(_("cannot determine time zone abbreviation to use just after until time"));
+ 			else
+-				addtt(starttime,
+-					  addtype(startoff, startbuf,
+-							  startoff != zp->z_gmtoff,
+-							  startttisstd,
+-							  startttisgmt));
++			{
++				bool		isdst = startoff != zp->z_gmtoff;
++
++				type = addtype(startoff, startbuf, isdst,
++							   startttisstd, startttisgmt);
++				if (defaulttype < 0 && !isdst)
++					defaulttype = type;
++				addtt(starttime, type);
++			}
+ 		}
+ 
+ 		/*
+@@ -3071,6 +3105,8 @@ outzone(const struct zone *zpfirst, ptrd
+ 				starttime = tadd(starttime, -gmtoff);
+ 		}
+ 	}
++	if (defaulttype < 0)
++		defaulttype = 0;
+ 	if (0 <= lastatmax)
+ 		attypes[lastatmax].dontmerge = true;
+ 	if (do_extend)
+@@ -3100,7 +3136,7 @@ outzone(const struct zone *zpfirst, ptrd
+ 			attypes[timecnt - 1].dontmerge = true;
+ 		}
+ 	}
+-	writezone(zpfirst->z_name, envvar, version);
++	writezone(zpfirst->z_name, envvar, version, defaulttype);
+ 	free(startbuf);
+ 	free(ab);
+ 	free(envvar);
+@@ -3109,21 +3145,6 @@ outzone(const struct zone *zpfirst, ptrd
+ static void
+ addtt(zic_t starttime, int type)
+ {
+-	if (starttime <= early_time
+-		|| (timecnt == 1 && attypes[0].at < early_time))
+-	{
+-		gmtoffs[0] = gmtoffs[type];
+-		isdsts[0] = isdsts[type];
+-		ttisstds[0] = ttisstds[type];
+-		ttisgmts[0] = ttisgmts[type];
+-		if (abbrinds[type] != 0)
+-			strcpy(chars, &chars[abbrinds[type]]);
+-		abbrinds[0] = 0;
+-		charcnt = strlen(chars) + 1;
+-		typecnt = 1;
+-		timecnt = 0;
+-		type = 0;
+-	}
+ 	attypes = growalloc(attypes, sizeof *attypes, timecnt, &timecnt_alloc);
+ 	attypes[timecnt].at = starttime;
+ 	attypes[timecnt].dontmerge = false;
+@@ -3361,7 +3382,7 @@ is_alpha(char a)
+ }
+ 
+ /* If A is an uppercase character in the C locale, return its lowercase
+- * counterpart.  Otherwise, return A.  */
++   counterpart.  Otherwise, return A.  */
+ static char
+ lowerit(char a)
+ {
+@@ -3628,6 +3649,18 @@ rpytime(const struct rule *rp, zic_t wan
+ 	dayoff = 0;
+ 	m = TM_JANUARY;
+ 	y = EPOCH_YEAR;
++	if (y < wantedy)
++	{
++		wantedy -= y;
++		dayoff = (wantedy / YEARSPERREPEAT) * (SECSPERREPEAT / SECSPERDAY);
++		wantedy %= YEARSPERREPEAT;
++		wantedy += y;
++	}
++	else if (wantedy < 0)
++	{
++		dayoff = (wantedy / YEARSPERREPEAT) * (SECSPERREPEAT / SECSPERDAY);
++		wantedy %= YEARSPERREPEAT;
++	}
+ 	while (wantedy != y)
+ 	{
+ 		if (wantedy > y)
+@@ -3706,7 +3739,6 @@ will not work with pre-2004 versions of
+ 	if (dayoff > max_time / SECSPERDAY)
+ 		return max_time;
+ 	t = (zic_t) dayoff * SECSPERDAY;
+-
+ 	return tadd(t, rp->r_tod);
+ }
+ 
diff --git a/meta-openembedded/meta-oe/recipes-dbs/postgresql/files/0001-Update-time-zone-data-files-to-tzdata-release-2018f.patch b/meta-openembedded/meta-oe/recipes-dbs/postgresql/files/0001-Update-time-zone-data-files-to-tzdata-release-2018f.patch
new file mode 100644
index 0000000..41e763c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-dbs/postgresql/files/0001-Update-time-zone-data-files-to-tzdata-release-2018f.patch
@@ -0,0 +1,6452 @@
+From 13877d30f2ec93f6043937f76af207dcc614a4e7 Mon Sep 17 00:00:00 2001
+From: Tom Lane <tgl@sss.pgh.pa.us>
+Date: Fri, 19 Oct 2018 17:01:34 -0400
+Subject: [PATCH] Update time zone data files to tzdata release 2018f.
+
+DST law changes in Chile, Fiji, and Russia (Volgograd).
+Historical corrections for China, Japan, Macau, and North Korea.
+
+Note: like the previous tzdata update, this involves a depressingly
+large amount of semantically-meaningless churn in tzdata.zi.  That
+is a consequence of upstream's data compression method assigning
+unstable abbreviations to DST rulesets.  I complained about that
+to them last time, and this version now uses an assignment method
+that pays some heed to not changing abbreviations unnecessarily.
+So hopefully, that'll be better going forward.
+
+Upstream-Status: Backport
+Signed-off-by: Armin Kuster <akuster@mvista.com>
+
+---
+ src/timezone/data/tzdata.zi      | 5273 +++++++++++++++++++-------------------
+ src/timezone/known_abbrevs.txt   |    1 +
+ src/timezone/tznames/America.txt |    3 +
+ src/timezone/tznames/Asia.txt    |    4 +
+ src/timezone/tznames/Default     |    3 +
+ src/timezone/tznames/Pacific.txt |    3 +
+ 6 files changed, 2660 insertions(+), 2627 deletions(-)
+
+diff --git a/src/timezone/data/tzdata.zi b/src/timezone/data/tzdata.zi
+index c470112..6d98902 100644
+--- a/src/timezone/data/tzdata.zi
++++ b/src/timezone/data/tzdata.zi
+@@ -1,36 +1,36 @@
+-# version 2018e
++# version 2018f
+ # This zic input file is in the public domain.
+-R A 1916 o - Jun 14 23s 1 S
+-R A 1916 1919 - O Sun>=1 23s 0 -
+-R A 1917 o - Mar 24 23s 1 S
+-R A 1918 o - Mar 9 23s 1 S
+-R A 1919 o - Mar 1 23s 1 S
+-R A 1920 o - F 14 23s 1 S
+-R A 1920 o - O 23 23s 0 -
+-R A 1921 o - Mar 14 23s 1 S
+-R A 1921 o - Jun 21 23s 0 -
+-R A 1939 o - S 11 23s 1 S
+-R A 1939 o - N 19 1 0 -
+-R A 1944 1945 - Ap M>=1 2 1 S
+-R A 1944 o - O 8 2 0 -
+-R A 1945 o - S 16 1 0 -
+-R A 1971 o - Ap 25 23s 1 S
+-R A 1971 o - S 26 23s 0 -
+-R A 1977 o - May 6 0 1 S
+-R A 1977 o - O 21 0 0 -
+-R A 1978 o - Mar 24 1 1 S
+-R A 1978 o - S 22 3 0 -
+-R A 1980 o - Ap 25 0 1 S
+-R A 1980 o - O 31 2 0 -
++R d 1916 o - Jun 14 23s 1 S
++R d 1916 1919 - O Sun>=1 23s 0 -
++R d 1917 o - Mar 24 23s 1 S
++R d 1918 o - Mar 9 23s 1 S
++R d 1919 o - Mar 1 23s 1 S
++R d 1920 o - F 14 23s 1 S
++R d 1920 o - O 23 23s 0 -
++R d 1921 o - Mar 14 23s 1 S
++R d 1921 o - Jun 21 23s 0 -
++R d 1939 o - S 11 23s 1 S
++R d 1939 o - N 19 1 0 -
++R d 1944 1945 - Ap M>=1 2 1 S
++R d 1944 o - O 8 2 0 -
++R d 1945 o - S 16 1 0 -
++R d 1971 o - Ap 25 23s 1 S
++R d 1971 o - S 26 23s 0 -
++R d 1977 o - May 6 0 1 S
++R d 1977 o - O 21 0 0 -
++R d 1978 o - Mar 24 1 1 S
++R d 1978 o - S 22 3 0 -
++R d 1980 o - Ap 25 0 1 S
++R d 1980 o - O 31 2 0 -
+ Z Africa/Algiers 0:12:12 - LMT 1891 Mar 15 0:1
+ 0:9:21 - PMT 1911 Mar 11
+-0 A WE%sT 1940 F 25 2
+-1 A CE%sT 1946 O 7
++0 d WE%sT 1940 F 25 2
++1 d CE%sT 1946 O 7
+ 0 - WET 1956 Ja 29
+ 1 - CET 1963 Ap 14
+-0 A WE%sT 1977 O 21
+-1 A CE%sT 1979 O 26
+-0 A WE%sT 1981 May
++0 d WE%sT 1977 O 21
++1 d CE%sT 1979 O 26
++0 d WE%sT 1981 May
+ 1 - CET
+ Z Atlantic/Cape_Verde -1:34:4 - LMT 1912 Ja 1 2u
+ -2 - -02 1942 S
+@@ -52,44 +52,44 @@ Li Africa/Abidjan Africa/Lome
+ Li Africa/Abidjan Africa/Nouakchott
+ Li Africa/Abidjan Africa/Ouagadougou
+ Li Africa/Abidjan Atlantic/St_Helena
+-R B 1940 o - Jul 15 0 1 S
+-R B 1940 o - O 1 0 0 -
+-R B 1941 o - Ap 15 0 1 S
+-R B 1941 o - S 16 0 0 -
+-R B 1942 1944 - Ap 1 0 1 S
+-R B 1942 o - O 27 0 0 -
+-R B 1943 1945 - N 1 0 0 -
+-R B 1945 o - Ap 16 0 1 S
+-R B 1957 o - May 10 0 1 S
+-R B 1957 1958 - O 1 0 0 -
+-R B 1958 o - May 1 0 1 S
+-R B 1959 1981 - May 1 1 1 S
+-R B 1959 1965 - S 30 3 0 -
+-R B 1966 1994 - O 1 3 0 -
+-R B 1982 o - Jul 25 1 1 S
+-R B 1983 o - Jul 12 1 1 S
+-R B 1984 1988 - May 1 1 1 S
+-R B 1989 o - May 6 1 1 S
+-R B 1990 1994 - May 1 1 1 S
+-R B 1995 2010 - Ap lastF 0s 1 S
+-R B 1995 2005 - S lastTh 24 0 -
+-R B 2006 o - S 21 24 0 -
+-R B 2007 o - S Th>=1 24 0 -
+-R B 2008 o - Au lastTh 24 0 -
+-R B 2009 o - Au 20 24 0 -
+-R B 2010 o - Au 10 24 0 -
+-R B 2010 o - S 9 24 1 S
+-R B 2010 o - S lastTh 24 0 -
+-R B 2014 o - May 15 24 1 S
+-R B 2014 o - Jun 26 24 0 -
+-R B 2014 o - Jul 31 24 1 S
+-R B 2014 o - S lastTh 24 0 -
++R K 1940 o - Jul 15 0 1 S
++R K 1940 o - O 1 0 0 -
++R K 1941 o - Ap 15 0 1 S
++R K 1941 o - S 16 0 0 -
++R K 1942 1944 - Ap 1 0 1 S
++R K 1942 o - O 27 0 0 -
++R K 1943 1945 - N 1 0 0 -
++R K 1945 o - Ap 16 0 1 S
++R K 1957 o - May 10 0 1 S
++R K 1957 1958 - O 1 0 0 -
++R K 1958 o - May 1 0 1 S
++R K 1959 1981 - May 1 1 1 S
++R K 1959 1965 - S 30 3 0 -
++R K 1966 1994 - O 1 3 0 -
++R K 1982 o - Jul 25 1 1 S
++R K 1983 o - Jul 12 1 1 S
++R K 1984 1988 - May 1 1 1 S
++R K 1989 o - May 6 1 1 S
++R K 1990 1994 - May 1 1 1 S
++R K 1995 2010 - Ap lastF 0s 1 S
++R K 1995 2005 - S lastTh 24 0 -
++R K 2006 o - S 21 24 0 -
++R K 2007 o - S Th>=1 24 0 -
++R K 2008 o - Au lastTh 24 0 -
++R K 2009 o - Au 20 24 0 -
++R K 2010 o - Au 10 24 0 -
++R K 2010 o - S 9 24 1 S
++R K 2010 o - S lastTh 24 0 -
++R K 2014 o - May 15 24 1 S
++R K 2014 o - Jun 26 24 0 -
++R K 2014 o - Jul 31 24 1 S
++R K 2014 o - S lastTh 24 0 -
+ Z Africa/Cairo 2:5:9 - LMT 1900 O
+-2 B EE%sT
+-R C 1920 1942 - S 1 0 0:20 -
+-R C 1920 1942 - D 31 0 0 -
++2 K EE%sT
++R GH 1920 1942 - S 1 0 0:20 -
++R GH 1920 1942 - D 31 0 0 -
+ Z Africa/Accra -0:0:52 - LMT 1918
+-0 C GMT/+0020
++0 GH GMT/+0020
+ Z Africa/Bissau -1:2:20 - LMT 1912 Ja 1 1u
+ -1 - -01 1975
+ 0 - GMT
+@@ -111,99 +111,99 @@ Z Africa/Monrovia -0:43:8 - LMT 1882
+ -0:43:8 - MMT 1919 Mar
+ -0:44:30 - MMT 1972 Ja 7
+ 0 - GMT
+-R D 1951 o - O 14 2 1 S
+-R D 1952 o - Ja 1 0 0 -
+-R D 1953 o - O 9 2 1 S
+-R D 1954 o - Ja 1 0 0 -
+-R D 1955 o - S 30 0 1 S
+-R D 1956 o - Ja 1 0 0 -
+-R D 1982 1984 - Ap 1 0 1 S
+-R D 1982 1985 - O 1 0 0 -
+-R D 1985 o - Ap 6 0 1 S
+-R D 1986 o - Ap 4 0 1 S
+-R D 1986 o - O 3 0 0 -
+-R D 1987 1989 - Ap 1 0 1 S
+-R D 1987 1989 - O 1 0 0 -
+-R D 1997 o - Ap 4 0 1 S
+-R D 1997 o - O 4 0 0 -
+-R D 2013 o - Mar lastF 1 1 S
+-R D 2013 o - O lastF 2 0 -
++R L 1951 o - O 14 2 1 S
++R L 1952 o - Ja 1 0 0 -
++R L 1953 o - O 9 2 1 S
++R L 1954 o - Ja 1 0 0 -
++R L 1955 o - S 30 0 1 S
++R L 1956 o - Ja 1 0 0 -
++R L 1982 1984 - Ap 1 0 1 S
++R L 1982 1985 - O 1 0 0 -
++R L 1985 o - Ap 6 0 1 S
++R L 1986 o - Ap 4 0 1 S
++R L 1986 o - O 3 0 0 -
++R L 1987 1989 - Ap 1 0 1 S
++R L 1987 1989 - O 1 0 0 -
++R L 1997 o - Ap 4 0 1 S
++R L 1997 o - O 4 0 0 -
++R L 2013 o - Mar lastF 1 1 S
++R L 2013 o - O lastF 2 0 -
+ Z Africa/Tripoli 0:52:44 - LMT 1920
+-1 D CE%sT 1959
++1 L CE%sT 1959
+ 2 - EET 1982
+-1 D CE%sT 1990 May 4
++1 L CE%sT 1990 May 4
+ 2 - EET 1996 S 30
+-1 D CE%sT 1997 O 4
++1 L CE%sT 1997 O 4
+ 2 - EET 2012 N 10 2
+-1 D CE%sT 2013 O 25 2
++1 L CE%sT 2013 O 25 2
+ 2 - EET
+-R E 1982 o - O 10 0 1 -
+-R E 1983 o - Mar 21 0 0 -
+-R E 2008 o - O lastSun 2 1 -
+-R E 2009 o - Mar lastSun 2 0 -
++R MU 1982 o - O 10 0 1 -
++R MU 1983 o - Mar 21 0 0 -
++R MU 2008 o - O lastSun 2 1 -
++R MU 2009 o - Mar lastSun 2 0 -
+ Z Indian/Mauritius 3:50 - LMT 1907
+-4 E +04/+05
+-R F 1939 o - S 12 0 1 S
+-R F 1939 o - N 19 0 0 -
+-R F 1940 o - F 25 0 1 S
+-R F 1945 o - N 18 0 0 -
+-R F 1950 o - Jun 11 0 1 S
+-R F 1950 o - O 29 0 0 -
+-R F 1967 o - Jun 3 12 1 S
+-R F 1967 o - O 1 0 0 -
+-R F 1974 o - Jun 24 0 1 S
+-R F 1974 o - S 1 0 0 -
+-R F 1976 1977 - May 1 0 1 S
+-R F 1976 o - Au 1 0 0 -
+-R F 1977 o - S 28 0 0 -
+-R F 1978 o - Jun 1 0 1 S
+-R F 1978 o - Au 4 0 0 -
+-R F 2008 o - Jun 1 0 1 S
+-R F 2008 o - S 1 0 0 -
+-R F 2009 o - Jun 1 0 1 S
+-R F 2009 o - Au 21 0 0 -
+-R F 2010 o - May 2 0 1 S
+-R F 2010 o - Au 8 0 0 -
+-R F 2011 o - Ap 3 0 1 S
+-R F 2011 o - Jul 31 0 0 -
+-R F 2012 2013 - Ap lastSun 2 1 S
+-R F 2012 o - Jul 20 3 0 -
+-R F 2012 o - Au 20 2 1 S
+-R F 2012 o - S 30 3 0 -
+-R F 2013 o - Jul 7 3 0 -
+-R F 2013 o - Au 10 2 1 S
+-R F 2013 ma - O lastSun 3 0 -
+-R F 2014 2021 - Mar lastSun 2 1 S
+-R F 2014 o - Jun 28 3 0 -
+-R F 2014 o - Au 2 2 1 S
+-R F 2015 o - Jun 14 3 0 -
+-R F 2015 o - Jul 19 2 1 S
+-R F 2016 o - Jun 5 3 0 -
+-R F 2016 o - Jul 10 2 1 S
+-R F 2017 o - May 21 3 0 -
+-R F 2017 o - Jul 2 2 1 S
+-R F 2018 o - May 13 3 0 -
+-R F 2018 o - Jun 17 2 1 S
+-R F 2019 o - May 5 3 0 -
+-R F 2019 o - Jun 9 2 1 S
+-R F 2020 o - Ap 19 3 0 -
+-R F 2020 o - May 24 2 1 S
+-R F 2021 o - Ap 11 3 0 -
+-R F 2021 o - May 16 2 1 S
+-R F 2022 o - May 8 2 1 S
+-R F 2023 o - Ap 23 2 1 S
+-R F 2024 o - Ap 14 2 1 S
+-R F 2025 o - Ap 6 2 1 S
+-R F 2026 ma - Mar lastSun 2 1 S
+-R F 2036 o - O 19 3 0 -
+-R F 2037 o - O 4 3 0 -
++4 MU +04/+05
++R M 1939 o - S 12 0 1 S
++R M 1939 o - N 19 0 0 -
++R M 1940 o - F 25 0 1 S
++R M 1945 o - N 18 0 0 -
++R M 1950 o - Jun 11 0 1 S
++R M 1950 o - O 29 0 0 -
++R M 1967 o - Jun 3 12 1 S
++R M 1967 o - O 1 0 0 -
++R M 1974 o - Jun 24 0 1 S
++R M 1974 o - S 1 0 0 -
++R M 1976 1977 - May 1 0 1 S
++R M 1976 o - Au 1 0 0 -
++R M 1977 o - S 28 0 0 -
++R M 1978 o - Jun 1 0 1 S
++R M 1978 o - Au 4 0 0 -
++R M 2008 o - Jun 1 0 1 S
++R M 2008 o - S 1 0 0 -
++R M 2009 o - Jun 1 0 1 S
++R M 2009 o - Au 21 0 0 -
++R M 2010 o - May 2 0 1 S
++R M 2010 o - Au 8 0 0 -
++R M 2011 o - Ap 3 0 1 S
++R M 2011 o - Jul 31 0 0 -
++R M 2012 2013 - Ap lastSun 2 1 S
++R M 2012 o - Jul 20 3 0 -
++R M 2012 o - Au 20 2 1 S
++R M 2012 o - S 30 3 0 -
++R M 2013 o - Jul 7 3 0 -
++R M 2013 o - Au 10 2 1 S
++R M 2013 ma - O lastSun 3 0 -
++R M 2014 2021 - Mar lastSun 2 1 S
++R M 2014 o - Jun 28 3 0 -
++R M 2014 o - Au 2 2 1 S
++R M 2015 o - Jun 14 3 0 -
++R M 2015 o - Jul 19 2 1 S
++R M 2016 o - Jun 5 3 0 -
++R M 2016 o - Jul 10 2 1 S
++R M 2017 o - May 21 3 0 -
++R M 2017 o - Jul 2 2 1 S
++R M 2018 o - May 13 3 0 -
++R M 2018 o - Jun 17 2 1 S
++R M 2019 o - May 5 3 0 -
++R M 2019 o - Jun 9 2 1 S
++R M 2020 o - Ap 19 3 0 -
++R M 2020 o - May 24 2 1 S
++R M 2021 o - Ap 11 3 0 -
++R M 2021 o - May 16 2 1 S
++R M 2022 o - May 8 2 1 S
++R M 2023 o - Ap 23 2 1 S
++R M 2024 o - Ap 14 2 1 S
++R M 2025 o - Ap 6 2 1 S
++R M 2026 ma - Mar lastSun 2 1 S
++R M 2036 o - O 19 3 0 -
++R M 2037 o - O 4 3 0 -
+ Z Africa/Casablanca -0:30:20 - LMT 1913 O 26
+-0 F WE%sT 1984 Mar 16
++0 M WE%sT 1984 Mar 16
+ 1 - CET 1986
+-0 F WE%sT
++0 M WE%sT
+ Z Africa/El_Aaiun -0:52:48 - LMT 1934
+ -1 - -01 1976 Ap 14
+-0 F WE%sT
++0 M WE%sT
+ Z Africa/Maputo 2:10:20 - LMT 1903 Mar
+ 2 - CAT
+ Li Africa/Maputo Africa/Blantyre
+@@ -213,15 +213,15 @@ Li Africa/Maputo Africa/Harare
+ Li Africa/Maputo Africa/Kigali
+ Li Africa/Maputo Africa/Lubumbashi
+ Li Africa/Maputo Africa/Lusaka
+-R G 1994 o - Mar 21 0 -1 WAT
+-R G 1994 2017 - S Sun>=1 2 0 CAT
+-R G 1995 2017 - Ap Sun>=1 2 -1 WAT
++R NA 1994 o - Mar 21 0 -1 WAT
++R NA 1994 2017 - S Sun>=1 2 0 CAT
++R NA 1995 2017 - Ap Sun>=1 2 -1 WAT
+ Z Africa/Windhoek 1:8:24 - LMT 1892 F 8
+ 1:30 - +0130 1903 Mar
+ 2 - SAST 1942 S 20 2
+ 2 1 SAST 1943 Mar 21 2
+ 2 - SAST 1990 Mar 21
+-2 G %s
++2 NA %s
+ Z Africa/Lagos 0:13:36 - LMT 1919 S
+ 1 - WAT
+ Li Africa/Lagos Africa/Bangui
+@@ -241,52 +241,52 @@ Z Africa/Sao_Tome 0:26:56 - LMT 1884
+ 1 - WAT
+ Z Indian/Mahe 3:41:48 - LMT 1906 Jun
+ 4 - +04
+-R H 1942 1943 - S Sun>=15 2 1 -
+-R H 1943 1944 - Mar Sun>=15 2 0 -
++R SA 1942 1943 - S Sun>=15 2 1 -
++R SA 1943 1944 - Mar Sun>=15 2 0 -
+ Z Africa/Johannesburg 1:52 - LMT 1892 F 8
+ 1:30 - SAST 1903 Mar
+-2 H SAST
++2 SA SAST
+ Li Africa/Johannesburg Africa/Maseru
+ Li Africa/Johannesburg Africa/Mbabane
+-R I 1970 o - May 1 0 1 S
+-R I 1970 1985 - O 15 0 0 -
+-R I 1971 o - Ap 30 0 1 S
+-R I 1972 1985 - Ap lastSun 0 1 S
++R SD 1970 o - May 1 0 1 S
++R SD 1970 1985 - O 15 0 0 -
++R SD 1971 o - Ap 30 0 1 S
++R SD 1972 1985 - Ap lastSun 0 1 S
+ Z Africa/Khartoum 2:10:8 - LMT 1931
+-2 I CA%sT 2000 Ja 15 12
++2 SD CA%sT 2000 Ja 15 12
+ 3 - EAT 2017 N
+ 2 - CAT
+ Z Africa/Juba 2:6:28 - LMT 1931
+-2 I CA%sT 2000 Ja 15 12
++2 SD CA%sT 2000 Ja 15 12
+ 3 - EAT
+-R J 1939 o - Ap 15 23s 1 S
+-R J 1939 o - N 18 23s 0 -
+-R J 1940 o - F 25 23s 1 S
+-R J 1941 o - O 6 0 0 -
+-R J 1942 o - Mar 9 0 1 S
+-R J 1942 o - N 2 3 0 -
+-R J 1943 o - Mar 29 2 1 S
+-R J 1943 o - Ap 17 2 0 -
+-R J 1943 o - Ap 25 2 1 S
+-R J 1943 o - O 4 2 0 -
+-R J 1944 1945 - Ap M>=1 2 1 S
+-R J 1944 o - O 8 0 0 -
+-R J 1945 o - S 16 0 0 -
+-R J 1977 o - Ap 30 0s 1 S
+-R J 1977 o - S 24 0s 0 -
+-R J 1978 o - May 1 0s 1 S
+-R J 1978 o - O 1 0s 0 -
+-R J 1988 o - Jun 1 0s 1 S
+-R J 1988 1990 - S lastSun 0s 0 -
+-R J 1989 o - Mar 26 0s 1 S
+-R J 1990 o - May 1 0s 1 S
+-R J 2005 o - May 1 0s 1 S
+-R J 2005 o - S 30 1s 0 -
+-R J 2006 2008 - Mar lastSun 2s 1 S
+-R J 2006 2008 - O lastSun 2s 0 -
++R n 1939 o - Ap 15 23s 1 S
++R n 1939 o - N 18 23s 0 -
++R n 1940 o - F 25 23s 1 S
++R n 1941 o - O 6 0 0 -
++R n 1942 o - Mar 9 0 1 S
++R n 1942 o - N 2 3 0 -
++R n 1943 o - Mar 29 2 1 S
++R n 1943 o - Ap 17 2 0 -
++R n 1943 o - Ap 25 2 1 S
++R n 1943 o - O 4 2 0 -
++R n 1944 1945 - Ap M>=1 2 1 S
++R n 1944 o - O 8 0 0 -
++R n 1945 o - S 16 0 0 -
++R n 1977 o - Ap 30 0s 1 S
++R n 1977 o - S 24 0s 0 -
++R n 1978 o - May 1 0s 1 S
++R n 1978 o - O 1 0s 0 -
++R n 1988 o - Jun 1 0s 1 S
++R n 1988 1990 - S lastSun 0s 0 -
++R n 1989 o - Mar 26 0s 1 S
++R n 1990 o - May 1 0s 1 S
++R n 2005 o - May 1 0s 1 S
++R n 2005 o - S 30 1s 0 -
++R n 2006 2008 - Mar lastSun 2s 1 S
++R n 2006 2008 - O lastSun 2s 0 -
+ Z Africa/Tunis 0:40:44 - LMT 1881 May 12
+ 0:9:21 - PMT 1911 Mar 11
+-1 J CE%sT
++1 n CE%sT
+ Z Antarctica/Casey 0 - -00 1969
+ 8 - +08 2009 O 18 2
+ 11 - +11 2010 Mar 5 2
+@@ -314,10 +314,10 @@ Z Antarctica/DumontDUrville 0 - -00 1947
+ 10 - +10
+ Z Antarctica/Syowa 0 - -00 1957 Ja 29
+ 3 - +03
+-R K 2005 ma - Mar lastSun 1u 2 +02
+-R K 2004 ma - O lastSun 1u 0 +00
++R Tr 2005 ma - Mar lastSun 1u 2 +02
++R Tr 2004 ma - O lastSun 1u 0 +00
+ Z Antarctica/Troll 0 - -00 2005 F 12
+-0 K %s
++0 Tr %s
+ Z Antarctica/Vostok 0 - -00 1957 D 16
+ 6 - +06
+ Z Antarctica/Rothera 0 - -00 1976 D
+@@ -325,33 +325,33 @@ Z Antarctica/Rothera 0 - -00 1976 D
+ Z Asia/Kabul 4:36:48 - LMT 1890
+ 4 - +04 1945
+ 4:30 - +0430
+-R L 2011 o - Mar lastSun 2s 1 -
+-R L 2011 o - O lastSun 2s 0 -
++R AM 2011 o - Mar lastSun 2s 1 -
++R AM 2011 o - O lastSun 2s 0 -
+ Z Asia/Yerevan 2:58 - LMT 1924 May 2
+ 3 - +03 1957 Mar
+-4 M +04/+05 1991 Mar 31 2s
+-3 M +03/+04 1995 S 24 2s
++4 R +04/+05 1991 Mar 31 2s
++3 R +03/+04 1995 S 24 2s
+ 4 - +04 1997
+-4 M +04/+05 2011
+-4 L +04/+05
+-R N 1997 2015 - Mar lastSun 4 1 -
+-R N 1997 2015 - O lastSun 5 0 -
++4 R +04/+05 2011
++4 AM +04/+05
++R AZ 1997 2015 - Mar lastSun 4 1 -
++R AZ 1997 2015 - O lastSun 5 0 -
+ Z Asia/Baku 3:19:24 - LMT 1924 May 2
+ 3 - +03 1957 Mar
+-4 M +04/+05 1991 Mar 31 2s
+-3 M +03/+04 1992 S lastSun 2s
++4 R +04/+05 1991 Mar 31 2s
++3 R +03/+04 1992 S lastSun 2s
+ 4 - +04 1996
+-4 O +04/+05 1997
+-4 N +04/+05
+-R P 2009 o - Jun 19 23 1 -
+-R P 2009 o - D 31 24 0 -
++4 E +04/+05 1997
++4 AZ +04/+05
++R BD 2009 o - Jun 19 23 1 -
++R BD 2009 o - D 31 24 0 -
+ Z Asia/Dhaka 6:1:40 - LMT 1890
+ 5:53:20 - HMT 1941 O
+ 6:30 - +0630 1942 May 15
+ 5:30 - +0530 1942 S
+ 6:30 - +0630 1951 S 30
+ 6 - +06 2009
+-6 P +06/+07
++6 BD +06/+07
+ Z Asia/Thimphu 5:58:36 - LMT 1947 Au 15
+ 5:30 - +0530 1987 O
+ 6 - +06
+@@ -366,103 +366,127 @@ Z Asia/Yangon 6:24:47 - LMT 1880
+ 6:30 - +0630 1942 May
+ 9 - +09 1945 May 3
+ 6:30 - +0630
+-R Q 1940 o - Jun 3 0 1 D
+-R Q 1940 1941 - O 1 0 0 S
+-R Q 1941 o - Mar 16 0 1 D
+-R R 1986 o - May 4 0 1 D
+-R R 1986 1991 - S Sun>=11 0 0 S
+-R R 1987 1991 - Ap Sun>=10 0 1 D
++R Sh 1940 o - Jun 1 0 1 D
++R Sh 1940 o - O 12 24 0 S
++R Sh 1941 o - Mar 15 0 1 D
++R Sh 1941 o - N 1 24 0 S
++R Sh 1942 o - Ja 31 0 1 D
++R Sh 1945 o - S 1 24 0 S
++R Sh 1946 o - May 15 0 1 D
++R Sh 1946 o - S 30 24 0 S
++R Sh 1947 o - Ap 15 0 1 D
++R Sh 1947 o - O 31 24 0 S
++R Sh 1948 1949 - May 1 0 1 D
++R Sh 1948 1949 - S 30 24 0 S
++R CN 1986 o - May 4 2 1 D
++R CN 1986 1991 - S Sun>=11 2 0 S
++R CN 1987 1991 - Ap Sun>=11 2 1 D
+ Z Asia/Shanghai 8:5:43 - LMT 1901
+-8 Q C%sT 1949
+-8 R C%sT
++8 Sh C%sT 1949 May 28
++8 CN C%sT
+ Z Asia/Urumqi 5:50:20 - LMT 1928
+ 6 - +06
+-R S 1941 o - Ap 1 3:30 1 S
+-R S 1941 o - S 30 3:30 0 -
+-R S 1946 o - Ap 20 3:30 1 S
+-R S 1946 o - D 1 3:30 0 -
+-R S 1947 o - Ap 13 3:30 1 S
+-R S 1947 o - D 30 3:30 0 -
+-R S 1948 o - May 2 3:30 1 S
+-R S 1948 1951 - O lastSun 3:30 0 -
+-R S 1952 o - O 25 3:30 0 -
+-R S 1949 1953 - Ap Sun>=1 3:30 1 S
+-R S 1953 o - N 1 3:30 0 -
+-R S 1954 1964 - Mar Sun>=18 3:30 1 S
+-R S 1954 o - O 31 3:30 0 -
+-R S 1955 1964 - N Sun>=1 3:30 0 -
+-R S 1965 1976 - Ap Sun>=16 3:30 1 S
+-R S 1965 1976 - O Sun>=16 3:30 0 -
+-R S 1973 o - D 30 3:30 1 S
+-R S 1979 o - May Sun>=8 3:30 1 S
+-R S 1979 o - O Sun>=16 3:30 0 -
++R HK 1941 o - Ap 1 3:30 1 S
++R HK 1941 o - S 30 3:30 0 -
++R HK 1946 o - Ap 20 3:30 1 S
++R HK 1946 o - D 1 3:30 0 -
++R HK 1947 o - Ap 13 3:30 1 S
++R HK 1947 o - D 30 3:30 0 -
++R HK 1948 o - May 2 3:30 1 S
++R HK 1948 1951 - O lastSun 3:30 0 -
++R HK 1952 o - O 25 3:30 0 -
++R HK 1949 1953 - Ap Sun>=1 3:30 1 S
++R HK 1953 o - N 1 3:30 0 -
++R HK 1954 1964 - Mar Sun>=18 3:30 1 S
++R HK 1954 o - O 31 3:30 0 -
++R HK 1955 1964 - N Sun>=1 3:30 0 -
++R HK 1965 1976 - Ap Sun>=16 3:30 1 S
++R HK 1965 1976 - O Sun>=16 3:30 0 -
++R HK 1973 o - D 30 3:30 1 S
++R HK 1979 o - May Sun>=8 3:30 1 S
++R HK 1979 o - O Sun>=16 3:30 0 -
+ Z Asia/Hong_Kong 7:36:42 - LMT 1904 O 30
+-8 S HK%sT 1941 D 25
++8 HK HK%sT 1941 D 25
+ 9 - JST 1945 S 15
+-8 S HK%sT
+-R T 1946 o - May 15 0 1 D
+-R T 1946 o - O 1 0 0 S
+-R T 1947 o - Ap 15 0 1 D
+-R T 1947 o - N 1 0 0 S
+-R T 1948 1951 - May 1 0 1 D
+-R T 1948 1951 - O 1 0 0 S
+-R T 1952 o - Mar 1 0 1 D
+-R T 1952 1954 - N 1 0 0 S
+-R T 1953 1959 - Ap 1 0 1 D
+-R T 1955 1961 - O 1 0 0 S
+-R T 1960 1961 - Jun 1 0 1 D
+-R T 1974 1975 - Ap 1 0 1 D
+-R T 1974 1975 - O 1 0 0 S
+-R T 1979 o - Jul 1 0 1 D
+-R T 1979 o - O 1 0 0 S
++8 HK HK%sT
++R f 1946 o - May 15 0 1 D
++R f 1946 o - O 1 0 0 S
++R f 1947 o - Ap 15 0 1 D
++R f 1947 o - N 1 0 0 S
++R f 1948 1951 - May 1 0 1 D
++R f 1948 1951 - O 1 0 0 S
++R f 1952 o - Mar 1 0 1 D
++R f 1952 1954 - N 1 0 0 S
++R f 1953 1959 - Ap 1 0 1 D
++R f 1955 1961 - O 1 0 0 S
++R f 1960 1961 - Jun 1 0 1 D
++R f 1974 1975 - Ap 1 0 1 D
++R f 1974 1975 - O 1 0 0 S
++R f 1979 o - Jul 1 0 1 D
++R f 1979 o - O 1 0 0 S
+ Z Asia/Taipei 8:6 - LMT 1896
+ 8 - CST 1937 O
+ 9 - JST 1945 S 21 1
+-8 T C%sT
+-R U 1961 1962 - Mar Sun>=16 3:30 1 D
+-R U 1961 1964 - N Sun>=1 3:30 0 S
+-R U 1963 o - Mar Sun>=16 0 1 D
+-R U 1964 o - Mar Sun>=16 3:30 1 D
+-R U 1965 o - Mar Sun>=16 0 1 D
+-R U 1965 o - O 31 0 0 S
+-R U 1966 1971 - Ap Sun>=16 3:30 1 D
+-R U 1966 1971 - O Sun>=16 3:30 0 S
+-R U 1972 1974 - Ap Sun>=15 0 1 D
+-R U 1972 1973 - O Sun>=15 0 0 S
+-R U 1974 1977 - O Sun>=15 3:30 0 S
+-R U 1975 1977 - Ap Sun>=15 3:30 1 D
+-R U 1978 1980 - Ap Sun>=15 0 1 D
+-R U 1978 1980 - O Sun>=15 0 0 S
+-Z Asia/Macau 7:34:20 - LMT 1911 D 31 16u
+-8 U C%sT
+-R V 1975 o - Ap 13 0 1 S
+-R V 1975 o - O 12 0 0 -
+-R V 1976 o - May 15 0 1 S
+-R V 1976 o - O 11 0 0 -
+-R V 1977 1980 - Ap Sun>=1 0 1 S
+-R V 1977 o - S 25 0 0 -
+-R V 1978 o - O 2 0 0 -
+-R V 1979 1997 - S lastSun 0 0 -
+-R V 1981 1998 - Mar lastSun 0 1 S
++8 f C%sT
++R _ 1942 1943 - Ap 30 23 1 -
++R _ 1942 o - N 17 23 0 -
++R _ 1943 o - S 30 23 0 S
++R _ 1946 o - Ap 30 23s 1 D
++R _ 1946 o - S 30 23s 0 S
++R _ 1947 o - Ap 19 23s 1 D
++R _ 1947 o - N 30 23s 0 S
++R _ 1948 o - May 2 23s 1 D
++R _ 1948 o - O 31 23s 0 S
++R _ 1949 1950 - Ap Sat>=1 23s 1 D
++R _ 1949 1950 - O lastSat 23s 0 S
++R _ 1951 o - Mar 31 23s 1 D
++R _ 1951 o - O 28 23s 0 S
++R _ 1952 1953 - Ap Sat>=1 23s 1 D
++R _ 1952 o - N 1 23s 0 S
++R _ 1953 1954 - O lastSat 23s 0 S
++R _ 1954 1956 - Mar Sat>=17 23s 1 D
++R _ 1955 o - N 5 23s 0 S
++R _ 1956 1964 - N Sun>=1 3:30 0 S
++R _ 1957 1964 - Mar Sun>=18 3:30 1 D
++R _ 1965 1973 - Ap Sun>=16 3:30 1 D
++R _ 1965 1966 - O Sun>=16 2:30 0 S
++R _ 1967 1976 - O Sun>=16 3:30 0 S
++R _ 1973 o - D 30 3:30 1 D
++R _ 1975 1976 - Ap Sun>=16 3:30 1 D
++R _ 1979 o - May 13 3:30 1 D
++R _ 1979 o - O Sun>=16 3:30 0 S
++Z Asia/Macau 7:34:10 - LMT 1904 O 30
++8 - CST 1941 D 21 23
++9 _ +09/+10 1945 S 30 24
++8 _ C%sT
++R CY 1975 o - Ap 13 0 1 S
++R CY 1975 o - O 12 0 0 -
++R CY 1976 o - May 15 0 1 S
++R CY 1976 o - O 11 0 0 -
++R CY 1977 1980 - Ap Sun>=1 0 1 S
++R CY 1977 o - S 25 0 0 -
++R CY 1978 o - O 2 0 0 -
++R CY 1979 1997 - S lastSun 0 0 -
++R CY 1981 1998 - Mar lastSun 0 1 S
+ Z Asia/Nicosia 2:13:28 - LMT 1921 N 14
+-2 V EE%sT 1998 S
+-2 O EE%sT
++2 CY EE%sT 1998 S
++2 E EE%sT
+ Z Asia/Famagusta 2:15:48 - LMT 1921 N 14
+-2 V EE%sT 1998 S
+-2 O EE%sT 2016 S 8
++2 CY EE%sT 1998 S
++2 E EE%sT 2016 S 8
+ 3 - +03 2017 O 29 1u
+-2 O EE%sT
++2 E EE%sT
+ Li Asia/Nicosia Europe/Nicosia
+ Z Asia/Tbilisi 2:59:11 - LMT 1880
+ 2:59:11 - TBMT 1924 May 2
+ 3 - +03 1957 Mar
+-4 M +04/+05 1991 Mar 31 2s
+-3 M +03/+04 1992
+-3 W +03/+04 1994 S lastSun
+-4 W +04/+05 1996 O lastSun
++4 R +04/+05 1991 Mar 31 2s
++3 R +03/+04 1992
++3 e +03/+04 1994 S lastSun
++4 e +04/+05 1996 O lastSun
+ 4 1 +05 1997 Mar lastSun
+-4 W +04/+05 2004 Jun 27
+-3 M +03/+04 2005 Mar lastSun 2
++4 e +04/+05 2004 Jun 27
++3 R +03/+04 2005 Mar lastSun 2
+ 4 - +04
+ Z Asia/Dili 8:22:20 - LMT 1912
+ 8 - +08 1942 F 21 23
+@@ -504,72 +528,72 @@ Z Asia/Jayapura 9:22:48 - LMT 1932 N
+ 9 - +09 1944 S
+ 9:30 - +0930 1964
+ 9 - WIT
+-R X 1978 1980 - Mar 21 0 1 -
+-R X 1978 o - O 21 0 0 -
+-R X 1979 o - S 19 0 0 -
+-R X 1980 o - S 23 0 0 -
+-R X 1991 o - May 3 0 1 -
+-R X 1992 1995 - Mar 22 0 1 -
+-R X 1991 1995 - S 22 0 0 -
+-R X 1996 o - Mar 21 0 1 -
+-R X 1996 o - S 21 0 0 -
+-R X 1997 1999 - Mar 22 0 1 -
+-R X 1997 1999 - S 22 0 0 -
+-R X 2000 o - Mar 21 0 1 -
+-R X 2000 o - S 21 0 0 -
+-R X 2001 2003 - Mar 22 0 1 -
+-R X 2001 2003 - S 22 0 0 -
+-R X 2004 o - Mar 21 0 1 -
+-R X 2004 o - S 21 0 0 -
+-R X 2005 o - Mar 22 0 1 -
+-R X 2005 o - S 22 0 0 -
+-R X 2008 o - Mar 21 0 1 -
+-R X 2008 o - S 21 0 0 -
+-R X 2009 2011 - Mar 22 0 1 -
+-R X 2009 2011 - S 22 0 0 -
+-R X 2012 o - Mar 21 0 1 -
+-R X 2012 o - S 21 0 0 -
+-R X 2013 2015 - Mar 22 0 1 -
+-R X 2013 2015 - S 22 0 0 -
+-R X 2016 o - Mar 21 0 1 -
+-R X 2016 o - S 21 0 0 -
+-R X 2017 2019 - Mar 22 0 1 -
+-R X 2017 2019 - S 22 0 0 -
+-R X 2020 o - Mar 21 0 1 -
+-R X 2020 o - S 21 0 0 -
+-R X 2021 2023 - Mar 22 0 1 -
+-R X 2021 2023 - S 22 0 0 -
+-R X 2024 o - Mar 21 0 1 -
+-R X 2024 o - S 21 0 0 -
+-R X 2025 2027 - Mar 22 0 1 -
+-R X 2025 2027 - S 22 0 0 -
+-R X 2028 2029 - Mar 21 0 1 -
+-R X 2028 2029 - S 21 0 0 -
+-R X 2030 2031 - Mar 22 0 1 -
+-R X 2030 2031 - S 22 0 0 -
+-R X 2032 2033 - Mar 21 0 1 -
+-R X 2032 2033 - S 21 0 0 -
+-R X 2034 2035 - Mar 22 0 1 -
+-R X 2034 2035 - S 22 0 0 -
+-R X 2036 ma - Mar 21 0 1 -
+-R X 2036 ma - S 21 0 0 -
++R i 1978 1980 - Mar 21 0 1 -
++R i 1978 o - O 21 0 0 -
++R i 1979 o - S 19 0 0 -
++R i 1980 o - S 23 0 0 -
++R i 1991 o - May 3 0 1 -
++R i 1992 1995 - Mar 22 0 1 -
++R i 1991 1995 - S 22 0 0 -
++R i 1996 o - Mar 21 0 1 -
++R i 1996 o - S 21 0 0 -
++R i 1997 1999 - Mar 22 0 1 -
++R i 1997 1999 - S 22 0 0 -
++R i 2000 o - Mar 21 0 1 -
++R i 2000 o - S 21 0 0 -
++R i 2001 2003 - Mar 22 0 1 -
++R i 2001 2003 - S 22 0 0 -
++R i 2004 o - Mar 21 0 1 -
++R i 2004 o - S 21 0 0 -
++R i 2005 o - Mar 22 0 1 -
++R i 2005 o - S 22 0 0 -
++R i 2008 o - Mar 21 0 1 -
++R i 2008 o - S 21 0 0 -
++R i 2009 2011 - Mar 22 0 1 -
++R i 2009 2011 - S 22 0 0 -
++R i 2012 o - Mar 21 0 1 -
++R i 2012 o - S 21 0 0 -
++R i 2013 2015 - Mar 22 0 1 -
++R i 2013 2015 - S 22 0 0 -
++R i 2016 o - Mar 21 0 1 -
++R i 2016 o - S 21 0 0 -
++R i 2017 2019 - Mar 22 0 1 -
++R i 2017 2019 - S 22 0 0 -
++R i 2020 o - Mar 21 0 1 -
++R i 2020 o - S 21 0 0 -
++R i 2021 2023 - Mar 22 0 1 -
++R i 2021 2023 - S 22 0 0 -
++R i 2024 o - Mar 21 0 1 -
++R i 2024 o - S 21 0 0 -
++R i 2025 2027 - Mar 22 0 1 -
++R i 2025 2027 - S 22 0 0 -
++R i 2028 2029 - Mar 21 0 1 -
++R i 2028 2029 - S 21 0 0 -
++R i 2030 2031 - Mar 22 0 1 -
++R i 2030 2031 - S 22 0 0 -
++R i 2032 2033 - Mar 21 0 1 -
++R i 2032 2033 - S 21 0 0 -
++R i 2034 2035 - Mar 22 0 1 -
++R i 2034 2035 - S 22 0 0 -
++R i 2036 ma - Mar 21 0 1 -
++R i 2036 ma - S 21 0 0 -
+ Z Asia/Tehran 3:25:44 - LMT 1916
+ 3:25:44 - TMT 1946
+ 3:30 - +0330 1977 N
+-4 X +04/+05 1979
+-3:30 X +0330/+0430
+-R Y 1982 o - May 1 0 1 -
+-R Y 1982 1984 - O 1 0 0 -
+-R Y 1983 o - Mar 31 0 1 -
+-R Y 1984 1985 - Ap 1 0 1 -
+-R Y 1985 1990 - S lastSun 1s 0 -
+-R Y 1986 1990 - Mar lastSun 1s 1 -
+-R Y 1991 2007 - Ap 1 3s 1 -
+-R Y 1991 2007 - O 1 3s 0 -
++4 i +04/+05 1979
++3:30 i +0330/+0430
++R IQ 1982 o - May 1 0 1 -
++R IQ 1982 1984 - O 1 0 0 -
++R IQ 1983 o - Mar 31 0 1 -
++R IQ 1984 1985 - Ap 1 0 1 -
++R IQ 1985 1990 - S lastSun 1s 0 -
++R IQ 1986 1990 - Mar lastSun 1s 1 -
++R IQ 1991 2007 - Ap 1 3s 1 -
++R IQ 1991 2007 - O 1 3s 0 -
+ Z Asia/Baghdad 2:57:40 - LMT 1890
+ 2:57:36 - BMT 1918
+ 3 - +03 1982 May
+-3 Y +03/+04
++3 IQ +03/+04
+ R Z 1940 o - Jun 1 0 1 D
+ R Z 1942 1944 - N 1 0 0 S
+ R Z 1943 o - Ap 1 2 1 D
+@@ -659,163 +683,163 @@ R Z 2013 ma - O lastSun 2 0 S
+ Z Asia/Jerusalem 2:20:54 - LMT 1880
+ 2:20:40 - JMT 1918
+ 2 Z I%sT
+-R a 1948 o - May Sat>=1 24 1 D
+-R a 1948 1951 - S Sun>=9 0 0 S
+-R a 1949 o - Ap Sat>=1 24 1 D
+-R a 1950 1951 - May Sat>=1 24 1 D
++R JP 1948 o - May Sat>=1 24 1 D
++R JP 1948 1951 - S Sat>=8 25 0 S
++R JP 1949 o - Ap Sat>=1 24 1 D
++R JP 1950 1951 - May Sat>=1 24 1 D
+ Z Asia/Tokyo 9:18:59 - LMT 1887 D 31 15u
+-9 a J%sT
+-R b 1973 o - Jun 6 0 1 S
+-R b 1973 1975 - O 1 0 0 -
+-R b 1974 1977 - May 1 0 1 S
+-R b 1976 o - N 1 0 0 -
+-R b 1977 o - O 1 0 0 -
+-R b 1978 o - Ap 30 0 1 S
+-R b 1978 o - S 30 0 0 -
+-R b 1985 o - Ap 1 0 1 S
+-R b 1985 o - O 1 0 0 -
+-R b 1986 1988 - Ap F>=1 0 1 S
+-R b 1986 1990 - O F>=1 0 0 -
+-R b 1989 o - May 8 0 1 S
+-R b 1990 o - Ap 27 0 1 S
+-R b 1991 o - Ap 17 0 1 S
+-R b 1991 o - S 27 0 0 -
+-R b 1992 o - Ap 10 0 1 S
+-R b 1992 1993 - O F>=1 0 0 -
+-R b 1993 1998 - Ap F>=1 0 1 S
+-R b 1994 o - S F>=15 0 0 -
+-R b 1995 1998 - S F>=15 0s 0 -
+-R b 1999 o - Jul 1 0s 1 S
+-R b 1999 2002 - S lastF 0s 0 -
+-R b 2000 2001 - Mar lastTh 0s 1 S
+-R b 2002 2012 - Mar lastTh 24 1 S
+-R b 2003 o - O 24 0s 0 -
+-R b 2004 o - O 15 0s 0 -
+-R b 2005 o - S lastF 0s 0 -
+-R b 2006 2011 - O lastF 0s 0 -
+-R b 2013 o - D 20 0 0 -
+-R b 2014 ma - Mar lastTh 24 1 S
+-R b 2014 ma - O lastF 0s 0 -
++9 JP J%sT
++R J 1973 o - Jun 6 0 1 S
++R J 1973 1975 - O 1 0 0 -
++R J 1974 1977 - May 1 0 1 S
++R J 1976 o - N 1 0 0 -
++R J 1977 o - O 1 0 0 -
++R J 1978 o - Ap 30 0 1 S
++R J 1978 o - S 30 0 0 -
++R J 1985 o - Ap 1 0 1 S
++R J 1985 o - O 1 0 0 -
++R J 1986 1988 - Ap F>=1 0 1 S
++R J 1986 1990 - O F>=1 0 0 -
++R J 1989 o - May 8 0 1 S
++R J 1990 o - Ap 27 0 1 S
++R J 1991 o - Ap 17 0 1 S
++R J 1991 o - S 27 0 0 -
++R J 1992 o - Ap 10 0 1 S
++R J 1992 1993 - O F>=1 0 0 -
++R J 1993 1998 - Ap F>=1 0 1 S
++R J 1994 o - S F>=15 0 0 -
++R J 1995 1998 - S F>=15 0s 0 -
++R J 1999 o - Jul 1 0s 1 S
++R J 1999 2002 - S lastF 0s 0 -
++R J 2000 2001 - Mar lastTh 0s 1 S
++R J 2002 2012 - Mar lastTh 24 1 S
++R J 2003 o - O 24 0s 0 -
++R J 2004 o - O 15 0s 0 -
++R J 2005 o - S lastF 0s 0 -
++R J 2006 2011 - O lastF 0s 0 -
++R J 2013 o - D 20 0 0 -
++R J 2014 ma - Mar lastTh 24 1 S
++R J 2014 ma - O lastF 0s 0 -
+ Z Asia/Amman 2:23:44 - LMT 1931
+-2 b EE%sT
++2 J EE%sT
+ Z Asia/Almaty 5:7:48 - LMT 1924 May 2
+ 5 - +05 1930 Jun 21
+-6 M +06/+07 1991 Mar 31 2s
+-5 M +05/+06 1992 Ja 19 2s
+-6 M +06/+07 2004 O 31 2s
++6 R +06/+07 1991 Mar 31 2s
++5 R +05/+06 1992 Ja 19 2s
++6 R +06/+07 2004 O 31 2s
+ 6 - +06
+ Z Asia/Qyzylorda 4:21:52 - LMT 1924 May 2
+ 4 - +04 1930 Jun 21
+ 5 - +05 1981 Ap
+ 5 1 +06 1981 O
+ 6 - +06 1982 Ap
+-5 M +05/+06 1991 Mar 31 2s
+-4 M +04/+05 1991 S 29 2s
+-5 M +05/+06 1992 Ja 19 2s
+-6 M +06/+07 1992 Mar 29 2s
+-5 M +05/+06 2004 O 31 2s
++5 R +05/+06 1991 Mar 31 2s
++4 R +04/+05 1991 S 29 2s
++5 R +05/+06 1992 Ja 19 2s
++6 R +06/+07 1992 Mar 29 2s
++5 R +05/+06 2004 O 31 2s
+ 6 - +06
+ Z Asia/Aqtobe 3:48:40 - LMT 1924 May 2
+ 4 - +04 1930 Jun 21
+ 5 - +05 1981 Ap
+ 5 1 +06 1981 O
+ 6 - +06 1982 Ap
+-5 M +05/+06 1991 Mar 31 2s
+-4 M +04/+05 1992 Ja 19 2s
+-5 M +05/+06 2004 O 31 2s
++5 R +05/+06 1991 Mar 31 2s
++4 R +04/+05 1992 Ja 19 2s
++5 R +05/+06 2004 O 31 2s
+ 5 - +05
+ Z Asia/Aqtau 3:21:4 - LMT 1924 May 2
+ 4 - +04 1930 Jun 21
+ 5 - +05 1981 O
+ 6 - +06 1982 Ap
+-5 M +05/+06 1991 Mar 31 2s
+-4 M +04/+05 1992 Ja 19 2s
+-5 M +05/+06 1994 S 25 2s
+-4 M +04/+05 2004 O 31 2s
++5 R +05/+06 1991 Mar 31 2s
++4 R +04/+05 1992 Ja 19 2s
++5 R +05/+06 1994 S 25 2s
++4 R +04/+05 2004 O 31 2s
+ 5 - +05
+ Z Asia/Atyrau 3:27:44 - LMT 1924 May 2
+ 3 - +03 1930 Jun 21
+ 5 - +05 1981 O
+ 6 - +06 1982 Ap
+-5 M +05/+06 1991 Mar 31 2s
+-4 M +04/+05 1992 Ja 19 2s
+-5 M +05/+06 1999 Mar 28 2s
+-4 M +04/+05 2004 O 31 2s
++5 R +05/+06 1991 Mar 31 2s
++4 R +04/+05 1992 Ja 19 2s
++5 R +05/+06 1999 Mar 28 2s
++4 R +04/+05 2004 O 31 2s
+ 5 - +05
+ Z Asia/Oral 3:25:24 - LMT 1924 May 2
+ 3 - +03 1930 Jun 21
+ 5 - +05 1981 Ap
+ 5 1 +06 1981 O
+ 6 - +06 1982 Ap
+-5 M +05/+06 1989 Mar 26 2s
+-4 M +04/+05 1992 Ja 19 2s
+-5 M +05/+06 1992 Mar 29 2s
+-4 M +04/+05 2004 O 31 2s
++5 R +05/+06 1989 Mar 26 2s
++4 R +04/+05 1992 Ja 19 2s
++5 R +05/+06 1992 Mar 29 2s
++4 R +04/+05 2004 O 31 2s
+ 5 - +05
+-R c 1992 1996 - Ap Sun>=7 0s 1 -
+-R c 1992 1996 - S lastSun 0 0 -
+-R c 1997 2005 - Mar lastSun 2:30 1 -
+-R c 1997 2004 - O lastSun 2:30 0 -
++R KG 1992 1996 - Ap Sun>=7 0s 1 -
++R KG 1992 1996 - S lastSun 0 0 -
++R KG 1997 2005 - Mar lastSun 2:30 1 -
++R KG 1997 2004 - O lastSun 2:30 0 -
+ Z Asia/Bishkek 4:58:24 - LMT 1924 May 2
+ 5 - +05 1930 Jun 21
+-6 M +06/+07 1991 Mar 31 2s
+-5 M +05/+06 1991 Au 31 2
+-5 c +05/+06 2005 Au 12
++6 R +06/+07 1991 Mar 31 2s
++5 R +05/+06 1991 Au 31 2
++5 KG +05/+06 2005 Au 12
+ 6 - +06
+-R d 1948 o - Jun 1 0 1 D
+-R d 1948 o - S 13 0 0 S
+-R d 1949 o - Ap 3 0 1 D
+-R d 1949 1951 - S Sun>=8 0 0 S
+-R d 1950 o - Ap 1 0 1 D
+-R d 1951 o - May 6 0 1 D
+-R d 1955 o - May 5 0 1 D
+-R d 1955 o - S 9 0 0 S
+-R d 1956 o - May 20 0 1 D
+-R d 1956 o - S 30 0 0 S
+-R d 1957 1960 - May Sun>=1 0 1 D
+-R d 1957 1960 - S Sun>=18 0 0 S
+-R d 1987 1988 - May Sun>=8 2 1 D
+-R d 1987 1988 - O Sun>=8 3 0 S
++R KR 1948 o - Jun 1 0 1 D
++R KR 1948 o - S 13 0 0 S
++R KR 1949 o - Ap 3 0 1 D
++R KR 1949 1951 - S Sun>=8 0 0 S
++R KR 1950 o - Ap 1 0 1 D
++R KR 1951 o - May 6 0 1 D
++R KR 1955 o - May 5 0 1 D
++R KR 1955 o - S 9 0 0 S
++R KR 1956 o - May 20 0 1 D
++R KR 1956 o - S 30 0 0 S
++R KR 1957 1960 - May Sun>=1 0 1 D
++R KR 1957 1960 - S Sun>=18 0 0 S
++R KR 1987 1988 - May Sun>=8 2 1 D
++R KR 1987 1988 - O Sun>=8 3 0 S
+ Z Asia/Seoul 8:27:52 - LMT 1908 Ap
+ 8:30 - KST 1912
+ 9 - JST 1945 S 8
+ 9 - KST 1954 Mar 21
+-8:30 d K%sT 1961 Au 10
+-9 d K%sT
++8:30 KR K%sT 1961 Au 10
++9 KR K%sT
+ Z Asia/Pyongyang 8:23 - LMT 1908 Ap
+ 8:30 - KST 1912
+ 9 - JST 1945 Au 24
+ 9 - KST 2015 Au 15
+-8:30 - KST 2018 May 5
++8:30 - KST 2018 May 4 23:30
+ 9 - KST
+-R e 1920 o - Mar 28 0 1 S
+-R e 1920 o - O 25 0 0 -
+-R e 1921 o - Ap 3 0 1 S
+-R e 1921 o - O 3 0 0 -
+-R e 1922 o - Mar 26 0 1 S
+-R e 1922 o - O 8 0 0 -
+-R e 1923 o - Ap 22 0 1 S
+-R e 1923 o - S 16 0 0 -
+-R e 1957 1961 - May 1 0 1 S
+-R e 1957 1961 - O 1 0 0 -
+-R e 1972 o - Jun 22 0 1 S
+-R e 1972 1977 - O 1 0 0 -
+-R e 1973 1977 - May 1 0 1 S
+-R e 1978 o - Ap 30 0 1 S
+-R e 1978 o - S 30 0 0 -
+-R e 1984 1987 - May 1 0 1 S
+-R e 1984 1991 - O 16 0 0 -
+-R e 1988 o - Jun 1 0 1 S
+-R e 1989 o - May 10 0 1 S
+-R e 1990 1992 - May 1 0 1 S
+-R e 1992 o - O 4 0 0 -
+-R e 1993 ma - Mar lastSun 0 1 S
+-R e 1993 1998 - S lastSun 0 0 -
+-R e 1999 ma - O lastSun 0 0 -
++R l 1920 o - Mar 28 0 1 S
++R l 1920 o - O 25 0 0 -
++R l 1921 o - Ap 3 0 1 S
++R l 1921 o - O 3 0 0 -
++R l 1922 o - Mar 26 0 1 S
++R l 1922 o - O 8 0 0 -
++R l 1923 o - Ap 22 0 1 S
++R l 1923 o - S 16 0 0 -
++R l 1957 1961 - May 1 0 1 S
++R l 1957 1961 - O 1 0 0 -
++R l 1972 o - Jun 22 0 1 S
++R l 1972 1977 - O 1 0 0 -
++R l 1973 1977 - May 1 0 1 S
++R l 1978 o - Ap 30 0 1 S
++R l 1978 o - S 30 0 0 -
++R l 1984 1987 - May 1 0 1 S
++R l 1984 1991 - O 16 0 0 -
++R l 1988 o - Jun 1 0 1 S
++R l 1989 o - May 10 0 1 S
++R l 1990 1992 - May 1 0 1 S
++R l 1992 o - O 4 0 0 -
++R l 1993 ma - Mar lastSun 0 1 S
++R l 1993 1998 - S lastSun 0 0 -
++R l 1999 ma - O lastSun 0 0 -
+ Z Asia/Beirut 2:22 - LMT 1880
+-2 e EE%sT
+-R f 1935 1941 - S 14 0 0:20 -
+-R f 1935 1941 - D 14 0 0 -
++2 l EE%sT
++R NB 1935 1941 - S 14 0 0:20 -
++R NB 1935 1941 - D 14 0 0 -
+ Z Asia/Kuala_Lumpur 6:46:46 - LMT 1901
+ 6:55:25 - SMT 1905 Jun
+ 7 - +07 1933
+@@ -827,98 +851,98 @@ Z Asia/Kuala_Lumpur 6:46:46 - LMT 1901
+ 8 - +08
+ Z Asia/Kuching 7:21:20 - LMT 1926 Mar
+ 7:30 - +0730 1933
+-8 f +08/+0820 1942 F 16
++8 NB +08/+0820 1942 F 16
+ 9 - +09 1945 S 12
+ 8 - +08
+ Z Indian/Maldives 4:54 - LMT 1880
+ 4:54 - MMT 1960
+ 5 - +05
+-R g 1983 1984 - Ap 1 0 1 -
+-R g 1983 o - O 1 0 0 -
+-R g 1985 1998 - Mar lastSun 0 1 -
+-R g 1984 1998 - S lastSun 0 0 -
+-R g 2001 o - Ap lastSat 2 1 -
+-R g 2001 2006 - S lastSat 2 0 -
+-R g 2002 2006 - Mar lastSat 2 1 -
+-R g 2015 2016 - Mar lastSat 2 1 -
+-R g 2015 2016 - S lastSat 0 0 -
++R X 1983 1984 - Ap 1 0 1 -
++R X 1983 o - O 1 0 0 -
++R X 1985 1998 - Mar lastSun 0 1 -
++R X 1984 1998 - S lastSun 0 0 -
++R X 2001 o - Ap lastSat 2 1 -
++R X 2001 2006 - S lastSat 2 0 -
++R X 2002 2006 - Mar lastSat 2 1 -
++R X 2015 2016 - Mar lastSat 2 1 -
++R X 2015 2016 - S lastSat 0 0 -
+ Z Asia/Hovd 6:6:36 - LMT 1905 Au
+ 6 - +06 1978
+-7 g +07/+08
++7 X +07/+08
+ Z Asia/Ulaanbaatar 7:7:32 - LMT 1905 Au
+ 7 - +07 1978
+-8 g +08/+09
++8 X +08/+09
+ Z Asia/Choibalsan 7:38 - LMT 1905 Au
+ 7 - +07 1978
+ 8 - +08 1983 Ap
+-9 g +09/+10 2008 Mar 31
+-8 g +08/+09
++9 X +09/+10 2008 Mar 31
++8 X +08/+09
+ Z Asia/Kathmandu 5:41:16 - LMT 1920
+ 5:30 - +0530 1986
+ 5:45 - +0545
+-R h 2002 o - Ap Sun>=2 0 1 S
+-R h 2002 o - O Sun>=2 0 0 -
+-R h 2008 o - Jun 1 0 1 S
+-R h 2008 2009 - N 1 0 0 -
+-R h 2009 o - Ap 15 0 1 S
++R PK 2002 o - Ap Sun>=2 0 1 S
++R PK 2002 o - O Sun>=2 0 0 -
++R PK 2008 o - Jun 1 0 1 S
++R PK 2008 2009 - N 1 0 0 -
++R PK 2009 o - Ap 15 0 1 S
+ Z Asia/Karachi 4:28:12 - LMT 1907
+ 5:30 - +0530 1942 S
+ 5:30 1 +0630 1945 O 15
+ 5:30 - +0530 1951 S 30
+ 5 - +05 1971 Mar 26
+-5 h PK%sT
+-R i 1999 2005 - Ap F>=15 0 1 S
+-R i 1999 2003 - O F>=15 0 0 -
+-R i 2004 o - O 1 1 0 -
+-R i 2005 o - O 4 2 0 -
+-R i 2006 2007 - Ap 1 0 1 S
+-R i 2006 o - S 22 0 0 -
+-R i 2007 o - S Th>=8 2 0 -
+-R i 2008 2009 - Mar lastF 0 1 S
+-R i 2008 o - S 1 0 0 -
+-R i 2009 o - S F>=1 1 0 -
+-R i 2010 o - Mar 26 0 1 S
+-R i 2010 o - Au 11 0 0 -
+-R i 2011 o - Ap 1 0:1 1 S
+-R i 2011 o - Au 1 0 0 -
+-R i 2011 o - Au 30 0 1 S
+-R i 2011 o - S 30 0 0 -
+-R i 2012 2014 - Mar lastTh 24 1 S
+-R i 2012 o - S 21 1 0 -
+-R i 2013 o - S F>=21 0 0 -
+-R i 2014 2015 - O F>=21 0 0 -
+-R i 2015 o - Mar lastF 24 1 S
+-R i 2016 ma - Mar Sat>=22 1 1 S
+-R i 2016 ma - O lastSat 1 0 -
++5 PK PK%sT
++R P 1999 2005 - Ap F>=15 0 1 S
++R P 1999 2003 - O F>=15 0 0 -
++R P 2004 o - O 1 1 0 -
++R P 2005 o - O 4 2 0 -
++R P 2006 2007 - Ap 1 0 1 S
++R P 2006 o - S 22 0 0 -
++R P 2007 o - S Th>=8 2 0 -
++R P 2008 2009 - Mar lastF 0 1 S
++R P 2008 o - S 1 0 0 -
++R P 2009 o - S F>=1 1 0 -
++R P 2010 o - Mar 26 0 1 S
++R P 2010 o - Au 11 0 0 -
++R P 2011 o - Ap 1 0:1 1 S
++R P 2011 o - Au 1 0 0 -
++R P 2011 o - Au 30 0 1 S
++R P 2011 o - S 30 0 0 -
++R P 2012 2014 - Mar lastTh 24 1 S
++R P 2012 o - S 21 1 0 -
++R P 2013 o - S F>=21 0 0 -
++R P 2014 2015 - O F>=21 0 0 -
++R P 2015 o - Mar lastF 24 1 S
++R P 2016 ma - Mar Sat>=22 1 1 S
++R P 2016 ma - O lastSat 1 0 -
+ Z Asia/Gaza 2:17:52 - LMT 1900 O
+ 2 Z EET/EEST 1948 May 15
+-2 B EE%sT 1967 Jun 5
++2 K EE%sT 1967 Jun 5
+ 2 Z I%sT 1996
+-2 b EE%sT 1999
+-2 i EE%sT 2008 Au 29
++2 J EE%sT 1999
++2 P EE%sT 2008 Au 29
+ 2 - EET 2008 S
+-2 i EE%sT 2010
++2 P EE%sT 2010
+ 2 - EET 2010 Mar 27 0:1
+-2 i EE%sT 2011 Au
++2 P EE%sT 2011 Au
+ 2 - EET 2012
+-2 i EE%sT
++2 P EE%sT
+ Z Asia/Hebron 2:20:23 - LMT 1900 O
+ 2 Z EET/EEST 1948 May 15
+-2 B EE%sT 1967 Jun 5
++2 K EE%sT 1967 Jun 5
+ 2 Z I%sT 1996
+-2 b EE%sT 1999
+-2 i EE%sT
+-R j 1936 o - N 1 0 1 -
+-R j 1937 o - F 1 0 0 -
+-R j 1954 o - Ap 12 0 1 -
+-R j 1954 o - Jul 1 0 0 -
+-R j 1978 o - Mar 22 0 1 -
+-R j 1978 o - S 21 0 0 -
++2 J EE%sT 1999
++2 P EE%sT
++R PH 1936 o - N 1 0 1 D
++R PH 1937 o - F 1 0 0 S
++R PH 1954 o - Ap 12 0 1 D
++R PH 1954 o - Jul 1 0 0 S
++R PH 1978 o - Mar 22 0 1 D
++R PH 1978 o - S 21 0 0 S
+ Z Asia/Manila -15:56 - LMT 1844 D 31
+ 8:4 - LMT 1899 May 11
+-8 j +08/+09 1942 May
+-9 - +09 1944 N
+-8 j +08/+09
++8 PH P%sT 1942 May
++9 - JST 1944 N
++8 PH P%sT
+ Z Asia/Qatar 3:26:8 - LMT 1920
+ 4 - +04 1972 Jun
+ 3 - +03
+@@ -945,52 +969,52 @@ Z Asia/Colombo 5:19:24 - LMT 1880
+ 6:30 - +0630 1996 O 26 0:30
+ 6 - +06 2006 Ap 15 0:30
+ 5:30 - +0530
+-R k 1920 1923 - Ap Sun>=15 2 1 S
+-R k 1920 1923 - O Sun>=1 2 0 -
+-R k 1962 o - Ap 29 2 1 S
+-R k 1962 o - O 1 2 0 -
+-R k 1963 1965 - May 1 2 1 S
+-R k 1963 o - S 30 2 0 -
+-R k 1964 o - O 1 2 0 -
+-R k 1965 o - S 30 2 0 -
+-R k 1966 o - Ap 24 2 1 S
+-R k 1966 1976 - O 1 2 0 -
+-R k 1967 1978 - May 1 2 1 S
+-R k 1977 1978 - S 1 2 0 -
+-R k 1983 1984 - Ap 9 2 1 S
+-R k 1983 1984 - O 1 2 0 -
+-R k 1986 o - F 16 2 1 S
+-R k 1986 o - O 9 2 0 -
+-R k 1987 o - Mar 1 2 1 S
+-R k 1987 1988 - O 31 2 0 -
+-R k 1988 o - Mar 15 2 1 S
+-R k 1989 o - Mar 31 2 1 S
+-R k 1989 o - O 1 2 0 -
+-R k 1990 o - Ap 1 2 1 S
+-R k 1990 o - S 30 2 0 -
+-R k 1991 o - Ap 1 0 1 S
+-R k 1991 1992 - O 1 0 0 -
+-R k 1992 o - Ap 8 0 1 S
+-R k 1993 o - Mar 26 0 1 S
+-R k 1993 o - S 25 0 0 -
+-R k 1994 1996 - Ap 1 0 1 S
+-R k 1994 2005 - O 1 0 0 -
+-R k 1997 1998 - Mar lastM 0 1 S
+-R k 1999 2006 - Ap 1 0 1 S
+-R k 2006 o - S 22 0 0 -
+-R k 2007 o - Mar lastF 0 1 S
+-R k 2007 o - N F>=1 0 0 -
+-R k 2008 o - Ap F>=1 0 1 S
+-R k 2008 o - N 1 0 0 -
+-R k 2009 o - Mar lastF 0 1 S
+-R k 2010 2011 - Ap F>=1 0 1 S
+-R k 2012 ma - Mar lastF 0 1 S
+-R k 2009 ma - O lastF 0 0 -
++R S 1920 1923 - Ap Sun>=15 2 1 S
++R S 1920 1923 - O Sun>=1 2 0 -
++R S 1962 o - Ap 29 2 1 S
++R S 1962 o - O 1 2 0 -
++R S 1963 1965 - May 1 2 1 S
++R S 1963 o - S 30 2 0 -
++R S 1964 o - O 1 2 0 -
++R S 1965 o - S 30 2 0 -
++R S 1966 o - Ap 24 2 1 S
++R S 1966 1976 - O 1 2 0 -
++R S 1967 1978 - May 1 2 1 S
++R S 1977 1978 - S 1 2 0 -
++R S 1983 1984 - Ap 9 2 1 S
++R S 1983 1984 - O 1 2 0 -
++R S 1986 o - F 16 2 1 S
++R S 1986 o - O 9 2 0 -
++R S 1987 o - Mar 1 2 1 S
++R S 1987 1988 - O 31 2 0 -
++R S 1988 o - Mar 15 2 1 S
++R S 1989 o - Mar 31 2 1 S
++R S 1989 o - O 1 2 0 -
++R S 1990 o - Ap 1 2 1 S
++R S 1990 o - S 30 2 0 -
++R S 1991 o - Ap 1 0 1 S
++R S 1991 1992 - O 1 0 0 -
++R S 1992 o - Ap 8 0 1 S
++R S 1993 o - Mar 26 0 1 S
++R S 1993 o - S 25 0 0 -
++R S 1994 1996 - Ap 1 0 1 S
++R S 1994 2005 - O 1 0 0 -
++R S 1997 1998 - Mar lastM 0 1 S
++R S 1999 2006 - Ap 1 0 1 S
++R S 2006 o - S 22 0 0 -
++R S 2007 o - Mar lastF 0 1 S
++R S 2007 o - N F>=1 0 0 -
++R S 2008 o - Ap F>=1 0 1 S
++R S 2008 o - N 1 0 0 -
++R S 2009 o - Mar lastF 0 1 S
++R S 2010 2011 - Ap F>=1 0 1 S
++R S 2012 ma - Mar lastF 0 1 S
++R S 2009 ma - O lastF 0 0 -
+ Z Asia/Damascus 2:25:12 - LMT 1920
+-2 k EE%sT
++2 S EE%sT
+ Z Asia/Dushanbe 4:35:12 - LMT 1924 May 2
+ 5 - +05 1930 Jun 21
+-6 M +06/+07 1991 Mar 31 2s
++6 R +06/+07 1991 Mar 31 2s
+ 5 1 +05/+06 1991 S 9 2s
+ 5 - +05
+ Z Asia/Bangkok 6:42:4 - LMT 1880
+@@ -1000,8 +1024,8 @@ Li Asia/Bangkok Asia/Phnom_Penh
+ Li Asia/Bangkok Asia/Vientiane
+ Z Asia/Ashgabat 3:53:32 - LMT 1924 May 2
+ 4 - +04 1930 Jun 21
+-5 M +05/+06 1991 Mar 31 2
+-4 M +04/+05 1992 Ja 19 2
++5 R +05/+06 1991 Mar 31 2
++4 R +04/+05 1992 Ja 19 2
+ 5 - +05
+ Z Asia/Dubai 3:41:12 - LMT 1920
+ 4 - +04
+@@ -1011,12 +1035,12 @@ Z Asia/Samarkand 4:27:53 - LMT 1924 May 2
+ 5 - +05 1981 Ap
+ 5 1 +06 1981 O
+ 6 - +06 1982 Ap
+-5 M +05/+06 1992
++5 R +05/+06 1992
+ 5 - +05
+ Z Asia/Tashkent 4:37:11 - LMT 1924 May 2
+ 5 - +05 1930 Jun 21
+-6 M +06/+07 1991 Mar 31 2
+-5 M +05/+06 1992
++6 R +06/+07 1991 Mar 31 2
++5 R +05/+06 1992
+ 5 - +05
+ Z Asia/Ho_Chi_Minh 7:6:40 - LMT 1906 Jul
+ 7:6:30 - PLMT 1911 May
+@@ -1028,176 +1052,176 @@ Z Asia/Ho_Chi_Minh 7:6:40 - LMT 1906 Jul
+ 7 - +07 1959 D 31 23
+ 8 - +08 1975 Jun 13
+ 7 - +07
+-R l 1917 o - Ja 1 0:1 1 D
+-R l 1917 o - Mar 25 2 0 S
+-R l 1942 o - Ja 1 2 1 D
+-R l 1942 o - Mar 29 2 0 S
+-R l 1942 o - S 27 2 1 D
+-R l 1943 1944 - Mar lastSun 2 0 S
+-R l 1943 o - O 3 2 1 D
++R AU 1917 o - Ja 1 0:1 1 D
++R AU 1917 o - Mar 25 2 0 S
++R AU 1942 o - Ja 1 2 1 D
++R AU 1942 o - Mar 29 2 0 S
++R AU 1942 o - S 27 2 1 D
++R AU 1943 1944 - Mar lastSun 2 0 S
++R AU 1943 o - O 3 2 1 D
+ Z Australia/Darwin 8:43:20 - LMT 1895 F
+ 9 - ACST 1899 May
+-9:30 l AC%sT
+-R m 1974 o - O lastSun 2s 1 D
+-R m 1975 o - Mar Sun>=1 2s 0 S
+-R m 1983 o - O lastSun 2s 1 D
+-R m 1984 o - Mar Sun>=1 2s 0 S
+-R m 1991 o - N 17 2s 1 D
+-R m 1992 o - Mar Sun>=1 2s 0 S
+-R m 2006 o - D 3 2s 1 D
+-R m 2007 2009 - Mar lastSun 2s 0 S
+-R m 2007 2008 - O lastSun 2s 1 D
++9:30 AU AC%sT
++R AW 1974 o - O lastSun 2s 1 D
++R AW 1975 o - Mar Sun>=1 2s 0 S
++R AW 1983 o - O lastSun 2s 1 D
++R AW 1984 o - Mar Sun>=1 2s 0 S
++R AW 1991 o - N 17 2s 1 D
++R AW 1992 o - Mar Sun>=1 2s 0 S
++R AW 2006 o - D 3 2s 1 D
++R AW 2007 2009 - Mar lastSun 2s 0 S
++R AW 2007 2008 - O lastSun 2s 1 D
+ Z Australia/Perth 7:43:24 - LMT 1895 D
+-8 l AW%sT 1943 Jul
+-8 m AW%sT
++8 AU AW%sT 1943 Jul
++8 AW AW%sT
+ Z Australia/Eucla 8:35:28 - LMT 1895 D
+-8:45 l +0845/+0945 1943 Jul
+-8:45 m +0845/+0945
+-R n 1971 o - O lastSun 2s 1 D
+-R n 1972 o - F lastSun 2s 0 S
+-R n 1989 1991 - O lastSun 2s 1 D
+-R n 1990 1992 - Mar Sun>=1 2s 0 S
+-R o 1992 1993 - O lastSun 2s 1 D
+-R o 1993 1994 - Mar Sun>=1 2s 0 S
++8:45 AU +0845/+0945 1943 Jul
++8:45 AW +0845/+0945
++R AQ 1971 o - O lastSun 2s 1 D
++R AQ 1972 o - F lastSun 2s 0 S
++R AQ 1989 1991 - O lastSun 2s 1 D
++R AQ 1990 1992 - Mar Sun>=1 2s 0 S
++R Ho 1992 1993 - O lastSun 2s 1 D
++R Ho 1993 1994 - Mar Sun>=1 2s 0 S
+ Z Australia/Brisbane 10:12:8 - LMT 1895
+-10 l AE%sT 1971
+-10 n AE%sT
++10 AU AE%sT 1971
++10 AQ AE%sT
+ Z Australia/Lindeman 9:55:56 - LMT 1895
+-10 l AE%sT 1971
+-10 n AE%sT 1992 Jul
+-10 o AE%sT
+-R p 1971 1985 - O lastSun 2s 1 D
+-R p 1986 o - O 19 2s 1 D
+-R p 1987 2007 - O lastSun 2s 1 D
+-R p 1972 o - F 27 2s 0 S
+-R p 1973 1985 - Mar Sun>=1 2s 0 S
+-R p 1986 1990 - Mar Sun>=15 2s 0 S
+-R p 1991 o - Mar 3 2s 0 S
+-R p 1992 o - Mar 22 2s 0 S
+-R p 1993 o - Mar 7 2s 0 S
+-R p 1994 o - Mar 20 2s 0 S
+-R p 1995 2005 - Mar lastSun 2s 0 S
+-R p 2006 o - Ap 2 2s 0 S
+-R p 2007 o - Mar lastSun 2s 0 S
+-R p 2008 ma - Ap Sun>=1 2s 0 S
+-R p 2008 ma - O Sun>=1 2s 1 D
++10 AU AE%sT 1971
++10 AQ AE%sT 1992 Jul
++10 Ho AE%sT
++R AS 1971 1985 - O lastSun 2s 1 D
++R AS 1986 o - O 19 2s 1 D
++R AS 1987 2007 - O lastSun 2s 1 D
++R AS 1972 o - F 27 2s 0 S
++R AS 1973 1985 - Mar Sun>=1 2s 0 S
++R AS 1986 1990 - Mar Sun>=15 2s 0 S
++R AS 1991 o - Mar 3 2s 0 S
++R AS 1992 o - Mar 22 2s 0 S
++R AS 1993 o - Mar 7 2s 0 S
++R AS 1994 o - Mar 20 2s 0 S
++R AS 1995 2005 - Mar lastSun 2s 0 S
++R AS 2006 o - Ap 2 2s 0 S
++R AS 2007 o - Mar lastSun 2s 0 S
++R AS 2008 ma - Ap Sun>=1 2s 0 S
++R AS 2008 ma - O Sun>=1 2s 1 D
+ Z Australia/Adelaide 9:14:20 - LMT 1895 F
+ 9 - ACST 1899 May
+-9:30 l AC%sT 1971
+-9:30 p AC%sT
+-R q 1967 o - O Sun>=1 2s 1 D
+-R q 1968 o - Mar lastSun 2s 0 S
+-R q 1968 1985 - O lastSun 2s 1 D
+-R q 1969 1971 - Mar Sun>=8 2s 0 S
+-R q 1972 o - F lastSun 2s 0 S
+-R q 1973 1981 - Mar Sun>=1 2s 0 S
+-R q 1982 1983 - Mar lastSun 2s 0 S
+-R q 1984 1986 - Mar Sun>=1 2s 0 S
+-R q 1986 o - O Sun>=15 2s 1 D
+-R q 1987 1990 - Mar Sun>=15 2s 0 S
+-R q 1987 o - O Sun>=22 2s 1 D
+-R q 1988 1990 - O lastSun 2s 1 D
+-R q 1991 1999 - O Sun>=1 2s 1 D
+-R q 1991 2005 - Mar lastSun 2s 0 S
+-R q 2000 o - Au lastSun 2s 1 D
+-R q 2001 ma - O Sun>=1 2s 1 D
+-R q 2006 o - Ap Sun>=1 2s 0 S
+-R q 2007 o - Mar lastSun 2s 0 S
+-R q 2008 ma - Ap Sun>=1 2s 0 S
++9:30 AU AC%sT 1971
++9:30 AS AC%sT
++R AT 1967 o - O Sun>=1 2s 1 D
++R AT 1968 o - Mar lastSun 2s 0 S
++R AT 1968 1985 - O lastSun 2s 1 D
++R AT 1969 1971 - Mar Sun>=8 2s 0 S
++R AT 1972 o - F lastSun 2s 0 S
++R AT 1973 1981 - Mar Sun>=1 2s 0 S
++R AT 1982 1983 - Mar lastSun 2s 0 S
++R AT 1984 1986 - Mar Sun>=1 2s 0 S
++R AT 1986 o - O Sun>=15 2s 1 D
++R AT 1987 1990 - Mar Sun>=15 2s 0 S
++R AT 1987 o - O Sun>=22 2s 1 D
++R AT 1988 1990 - O lastSun 2s 1 D
++R AT 1991 1999 - O Sun>=1 2s 1 D
++R AT 1991 2005 - Mar lastSun 2s 0 S
++R AT 2000 o - Au lastSun 2s 1 D
++R AT 2001 ma - O Sun>=1 2s 1 D
++R AT 2006 o - Ap Sun>=1 2s 0 S
++R AT 2007 o - Mar lastSun 2s 0 S
++R AT 2008 ma - Ap Sun>=1 2s 0 S
+ Z Australia/Hobart 9:49:16 - LMT 1895 S
+ 10 - AEST 1916 O 1 2
+ 10 1 AEDT 1917 F
+-10 l AE%sT 1967
+-10 q AE%sT
++10 AU AE%sT 1967
++10 AT AE%sT
+ Z Australia/Currie 9:35:28 - LMT 1895 S
+ 10 - AEST 1916 O 1 2
+ 10 1 AEDT 1917 F
+-10 l AE%sT 1971 Jul
+-10 q AE%sT
+-R r 1971 1985 - O lastSun 2s 1 D
+-R r 1972 o - F lastSun 2s 0 S
+-R r 1973 1985 - Mar Sun>=1 2s 0 S
+-R r 1986 1990 - Mar Sun>=15 2s 0 S
+-R r 1986 1987 - O Sun>=15 2s 1 D
+-R r 1988 1999 - O lastSun 2s 1 D
+-R r 1991 1994 - Mar Sun>=1 2s 0 S
+-R r 1995 2005 - Mar lastSun 2s 0 S
+-R r 2000 o - Au lastSun 2s 1 D
+-R r 2001 2007 - O lastSun 2s 1 D
+-R r 2006 o - Ap Sun>=1 2s 0 S
+-R r 2007 o - Mar lastSun 2s 0 S
+-R r 2008 ma - Ap Sun>=1 2s 0 S
+-R r 2008 ma - O Sun>=1 2s 1 D
++10 AU AE%sT 1971 Jul
++10 AT AE%sT
++R AV 1971 1985 - O lastSun 2s 1 D
++R AV 1972 o - F lastSun 2s 0 S
++R AV 1973 1985 - Mar Sun>=1 2s 0 S
++R AV 1986 1990 - Mar Sun>=15 2s 0 S
++R AV 1986 1987 - O Sun>=15 2s 1 D
++R AV 1988 1999 - O lastSun 2s 1 D
++R AV 1991 1994 - Mar Sun>=1 2s 0 S
++R AV 1995 2005 - Mar lastSun 2s 0 S
++R AV 2000 o - Au lastSun 2s 1 D
++R AV 2001 2007 - O lastSun 2s 1 D
++R AV 2006 o - Ap Sun>=1 2s 0 S
++R AV 2007 o - Mar lastSun 2s 0 S
++R AV 2008 ma - Ap Sun>=1 2s 0 S
++R AV 2008 ma - O Sun>=1 2s 1 D
+ Z Australia/Melbourne 9:39:52 - LMT 1895 F
+-10 l AE%sT 1971
+-10 r AE%sT
+-R s 1971 1985 - O lastSun 2s 1 D
+-R s 1972 o - F 27 2s 0 S
+-R s 1973 1981 - Mar Sun>=1 2s 0 S
+-R s 1982 o - Ap Sun>=1 2s 0 S
+-R s 1983 1985 - Mar Sun>=1 2s 0 S
+-R s 1986 1989 - Mar Sun>=15 2s 0 S
+-R s 1986 o - O 19 2s 1 D
+-R s 1987 1999 - O lastSun 2s 1 D
+-R s 1990 1995 - Mar Sun>=1 2s 0 S
+-R s 1996 2005 - Mar lastSun 2s 0 S
+-R s 2000 o - Au lastSun 2s 1 D
+-R s 2001 2007 - O lastSun 2s 1 D
+-R s 2006 o - Ap Sun>=1 2s 0 S
+-R s 2007 o - Mar lastSun 2s 0 S
+-R s 2008 ma - Ap Sun>=1 2s 0 S
+-R s 2008 ma - O Sun>=1 2s 1 D
++10 AU AE%sT 1971
++10 AV AE%sT
++R AN 1971 1985 - O lastSun 2s 1 D
++R AN 1972 o - F 27 2s 0 S
++R AN 1973 1981 - Mar Sun>=1 2s 0 S
++R AN 1982 o - Ap Sun>=1 2s 0 S
++R AN 1983 1985 - Mar Sun>=1 2s 0 S
++R AN 1986 1989 - Mar Sun>=15 2s 0 S
++R AN 1986 o - O 19 2s 1 D
++R AN 1987 1999 - O lastSun 2s 1 D
++R AN 1990 1995 - Mar Sun>=1 2s 0 S
++R AN 1996 2005 - Mar lastSun 2s 0 S
++R AN 2000 o - Au lastSun 2s 1 D
++R AN 2001 2007 - O lastSun 2s 1 D
++R AN 2006 o - Ap Sun>=1 2s 0 S
++R AN 2007 o - Mar lastSun 2s 0 S
++R AN 2008 ma - Ap Sun>=1 2s 0 S
++R AN 2008 ma - O Sun>=1 2s 1 D
+ Z Australia/Sydney 10:4:52 - LMT 1895 F
+-10 l AE%sT 1971
+-10 s AE%sT
++10 AU AE%sT 1971
++10 AN AE%sT
+ Z Australia/Broken_Hill 9:25:48 - LMT 1895 F
+ 10 - AEST 1896 Au 23
+ 9 - ACST 1899 May
+-9:30 l AC%sT 1971
+-9:30 s AC%sT 2000
+-9:30 p AC%sT
+-R t 1981 1984 - O lastSun 2 1 -
+-R t 1982 1985 - Mar Sun>=1 2 0 -
+-R t 1985 o - O lastSun 2 0:30 -
+-R t 1986 1989 - Mar Sun>=15 2 0 -
+-R t 1986 o - O 19 2 0:30 -
+-R t 1987 1999 - O lastSun 2 0:30 -
+-R t 1990 1995 - Mar Sun>=1 2 0 -
+-R t 1996 2005 - Mar lastSun 2 0 -
+-R t 2000 o - Au lastSun 2 0:30 -
+-R t 2001 2007 - O lastSun 2 0:30 -
+-R t 2006 o - Ap Sun>=1 2 0 -
+-R t 2007 o - Mar lastSun 2 0 -
+-R t 2008 ma - Ap Sun>=1 2 0 -
+-R t 2008 ma - O Sun>=1 2 0:30 -
++9:30 AU AC%sT 1971
++9:30 AN AC%sT 2000
++9:30 AS AC%sT
++R LH 1981 1984 - O lastSun 2 1 -
++R LH 1982 1985 - Mar Sun>=1 2 0 -
++R LH 1985 o - O lastSun 2 0:30 -
++R LH 1986 1989 - Mar Sun>=15 2 0 -
++R LH 1986 o - O 19 2 0:30 -
++R LH 1987 1999 - O lastSun 2 0:30 -
++R LH 1990 1995 - Mar Sun>=1 2 0 -
++R LH 1996 2005 - Mar lastSun 2 0 -
++R LH 2000 o - Au lastSun 2 0:30 -
++R LH 2001 2007 - O lastSun 2 0:30 -
++R LH 2006 o - Ap Sun>=1 2 0 -
++R LH 2007 o - Mar lastSun 2 0 -
++R LH 2008 ma - Ap Sun>=1 2 0 -
++R LH 2008 ma - O Sun>=1 2 0:30 -
+ Z Australia/Lord_Howe 10:36:20 - LMT 1895 F
+ 10 - AEST 1981 Mar
+-10:30 t +1030/+1130 1985 Jul
+-10:30 t +1030/+11
++10:30 LH +1030/+1130 1985 Jul
++10:30 LH +1030/+11
+ Z Antarctica/Macquarie 0 - -00 1899 N
+ 10 - AEST 1916 O 1 2
+ 10 1 AEDT 1917 F
+-10 l AE%sT 1919 Ap 1 0s
++10 AU AE%sT 1919 Ap 1 0s
+ 0 - -00 1948 Mar 25
+-10 l AE%sT 1967
+-10 q AE%sT 2010 Ap 4 3
++10 AU AE%sT 1967
++10 AT AE%sT 2010 Ap 4 3
+ 11 - +11
+ Z Indian/Christmas 7:2:52 - LMT 1895 F
+ 7 - +07
+ Z Indian/Cocos 6:27:40 - LMT 1900
+ 6:30 - +0630
+-R u 1998 1999 - N Sun>=1 2 1 -
+-R u 1999 2000 - F lastSun 3 0 -
+-R u 2009 o - N 29 2 1 -
+-R u 2010 o - Mar lastSun 3 0 -
+-R u 2010 2013 - O Sun>=21 2 1 -
+-R u 2011 o - Mar Sun>=1 3 0 -
+-R u 2012 2013 - Ja Sun>=18 3 0 -
+-R u 2014 o - Ja Sun>=18 2 0 -
+-R u 2014 ma - N Sun>=1 2 1 -
+-R u 2015 ma - Ja Sun>=14 3 0 -
++R FJ 1998 1999 - N Sun>=1 2 1 -
++R FJ 1999 2000 - F lastSun 3 0 -
++R FJ 2009 o - N 29 2 1 -
++R FJ 2010 o - Mar lastSun 3 0 -
++R FJ 2010 2013 - O Sun>=21 2 1 -
++R FJ 2011 o - Mar Sun>=1 3 0 -
++R FJ 2012 2013 - Ja Sun>=18 3 0 -
++R FJ 2014 o - Ja Sun>=18 2 0 -
++R FJ 2014 ma - N Sun>=1 2 1 -
++R FJ 2015 ma - Ja Sun>=13 3 0 -
+ Z Pacific/Fiji 11:55:44 - LMT 1915 O 26
+-12 u +12/+13
++12 FJ +12/+13
+ Z Pacific/Gambier -8:59:48 - LMT 1912 O
+ -9 - -09
+ Z Pacific/Marquesas -9:18 - LMT 1912 O
+@@ -1239,50 +1263,50 @@ Z Pacific/Nauru 11:7:40 - LMT 1921 Ja 15
+ 9 - +09 1944 Au 15
+ 11:30 - +1130 1979 May
+ 12 - +12
+-R v 1977 1978 - D Sun>=1 0 1 -
+-R v 1978 1979 - F 27 0 0 -
+-R v 1996 o - D 1 2s 1 -
+-R v 1997 o - Mar 2 2s 0 -
++R NC 1977 1978 - D Sun>=1 0 1 -
++R NC 1978 1979 - F 27 0 0 -
++R NC 1996 o - D 1 2s 1 -
++R NC 1997 o - Mar 2 2s 0 -
+ Z Pacific/Noumea 11:5:48 - LMT 1912 Ja 13
+-11 v +11/+12
+-R w 1927 o - N 6 2 1 S
+-R w 1928 o - Mar 4 2 0 M
+-R w 1928 1933 - O Sun>=8 2 0:30 S
+-R w 1929 1933 - Mar Sun>=15 2 0 M
+-R w 1934 1940 - Ap lastSun 2 0 M
+-R w 1934 1940 - S lastSun 2 0:30 S
+-R w 1946 o - Ja 1 0 0 S
+-R w 1974 o - N Sun>=1 2s 1 D
+-R x 1974 o - N Sun>=1 2:45s 1 -
+-R w 1975 o - F lastSun 2s 0 S
+-R x 1975 o - F lastSun 2:45s 0 -
+-R w 1975 1988 - O lastSun 2s 1 D
+-R x 1975 1988 - O lastSun 2:45s 1 -
+-R w 1976 1989 - Mar Sun>=1 2s 0 S
+-R x 1976 1989 - Mar Sun>=1 2:45s 0 -
+-R w 1989 o - O Sun>=8 2s 1 D
+-R x 1989 o - O Sun>=8 2:45s 1 -
+-R w 1990 2006 - O Sun>=1 2s 1 D
+-R x 1990 2006 - O Sun>=1 2:45s 1 -
+-R w 1990 2007 - Mar Sun>=15 2s 0 S
+-R x 1990 2007 - Mar Sun>=15 2:45s 0 -
+-R w 2007 ma - S lastSun 2s 1 D
+-R x 2007 ma - S lastSun 2:45s 1 -
+-R w 2008 ma - Ap Sun>=1 2s 0 S
+-R x 2008 ma - Ap Sun>=1 2:45s 0 -
++11 NC +11/+12
++R NZ 1927 o - N 6 2 1 S
++R NZ 1928 o - Mar 4 2 0 M
++R NZ 1928 1933 - O Sun>=8 2 0:30 S
++R NZ 1929 1933 - Mar Sun>=15 2 0 M
++R NZ 1934 1940 - Ap lastSun 2 0 M
++R NZ 1934 1940 - S lastSun 2 0:30 S
++R NZ 1946 o - Ja 1 0 0 S
++R NZ 1974 o - N Sun>=1 2s 1 D
++R k 1974 o - N Sun>=1 2:45s 1 -
++R NZ 1975 o - F lastSun 2s 0 S
++R k 1975 o - F lastSun 2:45s 0 -
++R NZ 1975 1988 - O lastSun 2s 1 D
++R k 1975 1988 - O lastSun 2:45s 1 -
++R NZ 1976 1989 - Mar Sun>=1 2s 0 S
++R k 1976 1989 - Mar Sun>=1 2:45s 0 -
++R NZ 1989 o - O Sun>=8 2s 1 D
++R k 1989 o - O Sun>=8 2:45s 1 -
++R NZ 1990 2006 - O Sun>=1 2s 1 D
++R k 1990 2006 - O Sun>=1 2:45s 1 -
++R NZ 1990 2007 - Mar Sun>=15 2s 0 S
++R k 1990 2007 - Mar Sun>=15 2:45s 0 -
++R NZ 2007 ma - S lastSun 2s 1 D
++R k 2007 ma - S lastSun 2:45s 1 -
++R NZ 2008 ma - Ap Sun>=1 2s 0 S
++R k 2008 ma - Ap Sun>=1 2:45s 0 -
+ Z Pacific/Auckland 11:39:4 - LMT 1868 N 2
+-11:30 w NZ%sT 1946
+-12 w NZ%sT
++11:30 NZ NZ%sT 1946
++12 NZ NZ%sT
+ Z Pacific/Chatham 12:13:48 - LMT 1868 N 2
+ 12:15 - +1215 1946
+-12:45 x +1245/+1345
++12:45 k +1245/+1345
+ Li Pacific/Auckland Antarctica/McMurdo
+-R y 1978 o - N 12 0 0:30 -
+-R y 1979 1991 - Mar Sun>=1 0 0 -
+-R y 1979 1990 - O lastSun 0 0:30 -
++R CK 1978 o - N 12 0 0:30 -
++R CK 1979 1991 - Mar Sun>=1 0 0 -
++R CK 1979 1990 - O lastSun 0 0:30 -
+ Z Pacific/Rarotonga -10:39:4 - LMT 1901
+ -10:30 - -1030 1978 N 12
+--10 y -10/-0930
++-10 CK -10/-0930
+ Z Pacific/Niue -11:19:40 - LMT 1901
+ -11:20 - -1120 1951
+ -11:30 - -1130 1978 O
+@@ -1311,570 +1335,570 @@ Z Pacific/Pago_Pago 12:37:12 - LMT 1892 Jul 5
+ -11:22:48 - LMT 1911
+ -11 - SST
+ Li Pacific/Pago_Pago Pacific/Midway
+-R z 2010 o - S lastSun 0 1 -
+-R z 2011 o - Ap Sat>=1 4 0 -
+-R z 2011 o - S lastSat 3 1 -
+-R z 2012 ma - Ap Sun>=1 4 0 -
+-R z 2012 ma - S lastSun 3 1 -
++R WS 2010 o - S lastSun 0 1 -
++R WS 2011 o - Ap Sat>=1 4 0 -
++R WS 2011 o - S lastSat 3 1 -
++R WS 2012 ma - Ap Sun>=1 4 0 -
++R WS 2012 ma - S lastSun 3 1 -
+ Z Pacific/Apia 12:33:4 - LMT 1892 Jul 5
+ -11:26:56 - LMT 1911
+ -11:30 - -1130 1950
+--11 z -11/-10 2011 D 29 24
+-13 z +13/+14
++-11 WS -11/-10 2011 D 29 24
++13 WS +13/+14
+ Z Pacific/Guadalcanal 10:39:48 - LMT 1912 O
+ 11 - +11
+ Z Pacific/Fakaofo -11:24:56 - LMT 1901
+ -11 - -11 2011 D 30
+ 13 - +13
+-R ! 1999 o - O 7 2s 1 -
+-R ! 2000 o - Mar 19 2s 0 -
+-R ! 2000 2001 - N Sun>=1 2 1 -
+-R ! 2001 2002 - Ja lastSun 2 0 -
+-R ! 2016 o - N Sun>=1 2 1 -
+-R ! 2017 o - Ja Sun>=15 3 0 -
++R TO 1999 o - O 7 2s 1 -
++R TO 2000 o - Mar 19 2s 0 -
++R TO 2000 2001 - N Sun>=1 2 1 -
++R TO 2001 2002 - Ja lastSun 2 0 -
++R TO 2016 o - N Sun>=1 2 1 -
++R TO 2017 o - Ja Sun>=15 3 0 -
+ Z Pacific/Tongatapu 12:19:20 - LMT 1901
+ 12:20 - +1220 1941
+ 13 - +13 1999
+-13 ! +13/+14
++13 TO +13/+14
+ Z Pacific/Funafuti 11:56:52 - LMT 1901
+ 12 - +12
+ Z Pacific/Wake 11:6:28 - LMT 1901
+ 12 - +12
+-R $ 1983 o - S 25 0 1 -
+-R $ 1984 1991 - Mar Sun>=23 0 0 -
+-R $ 1984 o - O 23 0 1 -
+-R $ 1985 1991 - S Sun>=23 0 1 -
+-R $ 1992 1993 - Ja Sun>=23 0 0 -
+-R $ 1992 o - O Sun>=23 0 1 -
++R VU 1983 o - S 25 0 1 -
++R VU 1984 1991 - Mar Sun>=23 0 0 -
++R VU 1984 o - O 23 0 1 -
++R VU 1985 1991 - S Sun>=23 0 1 -
++R VU 1992 1993 - Ja Sun>=23 0 0 -
++R VU 1992 o - O Sun>=23 0 1 -
+ Z Pacific/Efate 11:13:16 - LMT 1912 Ja 13
+-11 $ +11/+12
++11 VU +11/+12
+ Z Pacific/Wallis 12:15:20 - LMT 1901
+ 12 - +12
+-R % 1916 o - May 21 2s 1 BST
+-R % 1916 o - O 1 2s 0 GMT
+-R % 1917 o - Ap 8 2s 1 BST
+-R % 1917 o - S 17 2s 0 GMT
+-R % 1918 o - Mar 24 2s 1 BST
+-R % 1918 o - S 30 2s 0 GMT
+-R % 1919 o - Mar 30 2s 1 BST
+-R % 1919 o - S 29 2s 0 GMT
+-R % 1920 o - Mar 28 2s 1 BST
+-R % 1920 o - O 25 2s 0 GMT
+-R % 1921 o - Ap 3 2s 1 BST
+-R % 1921 o - O 3 2s 0 GMT
+-R % 1922 o - Mar 26 2s 1 BST
+-R % 1922 o - O 8 2s 0 GMT
+-R % 1923 o - Ap Sun>=16 2s 1 BST
+-R % 1923 1924 - S Sun>=16 2s 0 GMT
+-R % 1924 o - Ap Sun>=9 2s 1 BST
+-R % 1925 1926 - Ap Sun>=16 2s 1 BST
+-R % 1925 1938 - O Sun>=2 2s 0 GMT
+-R % 1927 o - Ap Sun>=9 2s 1 BST
+-R % 1928 1929 - Ap Sun>=16 2s 1 BST
+-R % 1930 o - Ap Sun>=9 2s 1 BST
+-R % 1931 1932 - Ap Sun>=16 2s 1 BST
+-R % 1933 o - Ap Sun>=9 2s 1 BST
+-R % 1934 o - Ap Sun>=16 2s 1 BST
+-R % 1935 o - Ap Sun>=9 2s 1 BST
+-R % 1936 1937 - Ap Sun>=16 2s 1 BST
+-R % 1938 o - Ap Sun>=9 2s 1 BST
+-R % 1939 o - Ap Sun>=16 2s 1 BST
+-R % 1939 o - N Sun>=16 2s 0 GMT
+-R % 1940 o - F Sun>=23 2s 1 BST
+-R % 1941 o - May Sun>=2 1s 2 BDST
+-R % 1941 1943 - Au Sun>=9 1s 1 BST
+-R % 1942 1944 - Ap Sun>=2 1s 2 BDST
+-R % 1944 o - S Sun>=16 1s 1 BST
+-R % 1945 o - Ap M>=2 1s 2 BDST
+-R % 1945 o - Jul Sun>=9 1s 1 BST
+-R % 1945 1946 - O Sun>=2 2s 0 GMT
+-R % 1946 o - Ap Sun>=9 2s 1 BST
+-R % 1947 o - Mar 16 2s 1 BST
+-R % 1947 o - Ap 13 1s 2 BDST
+-R % 1947 o - Au 10 1s 1 BST
+-R % 1947 o - N 2 2s 0 GMT
+-R % 1948 o - Mar 14 2s 1 BST
+-R % 1948 o - O 31 2s 0 GMT
+-R % 1949 o - Ap 3 2s 1 BST
+-R % 1949 o - O 30 2s 0 GMT
+-R % 1950 1952 - Ap Sun>=14 2s 1 BST
+-R % 1950 1952 - O Sun>=21 2s 0 GMT
+-R % 1953 o - Ap Sun>=16 2s 1 BST
+-R % 1953 1960 - O Sun>=2 2s 0 GMT
+-R % 1954 o - Ap Sun>=9 2s 1 BST
+-R % 1955 1956 - Ap Sun>=16 2s 1 BST
+-R % 1957 o - Ap Sun>=9 2s 1 BST
+-R % 1958 1959 - Ap Sun>=16 2s 1 BST
+-R % 1960 o - Ap Sun>=9 2s 1 BST
+-R % 1961 1963 - Mar lastSun 2s 1 BST
+-R % 1961 1968 - O Sun>=23 2s 0 GMT
+-R % 1964 1967 - Mar Sun>=19 2s 1 BST
+-R % 1968 o - F 18 2s 1 BST
+-R % 1972 1980 - Mar Sun>=16 2s 1 BST
+-R % 1972 1980 - O Sun>=23 2s 0 GMT
+-R % 1981 1995 - Mar lastSun 1u 1 BST
+-R % 1981 1989 - O Sun>=23 1u 0 GMT
+-R % 1990 1995 - O Sun>=22 1u 0 GMT
++R G 1916 o - May 21 2s 1 BST
++R G 1916 o - O 1 2s 0 GMT
++R G 1917 o - Ap 8 2s 1 BST
++R G 1917 o - S 17 2s 0 GMT
++R G 1918 o - Mar 24 2s 1 BST
++R G 1918 o - S 30 2s 0 GMT
++R G 1919 o - Mar 30 2s 1 BST
++R G 1919 o - S 29 2s 0 GMT
++R G 1920 o - Mar 28 2s 1 BST
++R G 1920 o - O 25 2s 0 GMT
++R G 1921 o - Ap 3 2s 1 BST
++R G 1921 o - O 3 2s 0 GMT
++R G 1922 o - Mar 26 2s 1 BST
++R G 1922 o - O 8 2s 0 GMT
++R G 1923 o - Ap Sun>=16 2s 1 BST
++R G 1923 1924 - S Sun>=16 2s 0 GMT
++R G 1924 o - Ap Sun>=9 2s 1 BST
++R G 1925 1926 - Ap Sun>=16 2s 1 BST
++R G 1925 1938 - O Sun>=2 2s 0 GMT
++R G 1927 o - Ap Sun>=9 2s 1 BST
++R G 1928 1929 - Ap Sun>=16 2s 1 BST
++R G 1930 o - Ap Sun>=9 2s 1 BST
++R G 1931 1932 - Ap Sun>=16 2s 1 BST
++R G 1933 o - Ap Sun>=9 2s 1 BST
++R G 1934 o - Ap Sun>=16 2s 1 BST
++R G 1935 o - Ap Sun>=9 2s 1 BST
++R G 1936 1937 - Ap Sun>=16 2s 1 BST
++R G 1938 o - Ap Sun>=9 2s 1 BST
++R G 1939 o - Ap Sun>=16 2s 1 BST
++R G 1939 o - N Sun>=16 2s 0 GMT
++R G 1940 o - F Sun>=23 2s 1 BST
++R G 1941 o - May Sun>=2 1s 2 BDST
++R G 1941 1943 - Au Sun>=9 1s 1 BST
++R G 1942 1944 - Ap Sun>=2 1s 2 BDST
++R G 1944 o - S Sun>=16 1s 1 BST
++R G 1945 o - Ap M>=2 1s 2 BDST
++R G 1945 o - Jul Sun>=9 1s 1 BST
++R G 1945 1946 - O Sun>=2 2s 0 GMT
++R G 1946 o - Ap Sun>=9 2s 1 BST
++R G 1947 o - Mar 16 2s 1 BST
++R G 1947 o - Ap 13 1s 2 BDST
++R G 1947 o - Au 10 1s 1 BST
++R G 1947 o - N 2 2s 0 GMT
++R G 1948 o - Mar 14 2s 1 BST
++R G 1948 o - O 31 2s 0 GMT
++R G 1949 o - Ap 3 2s 1 BST
++R G 1949 o - O 30 2s 0 GMT
++R G 1950 1952 - Ap Sun>=14 2s 1 BST
++R G 1950 1952 - O Sun>=21 2s 0 GMT
++R G 1953 o - Ap Sun>=16 2s 1 BST
++R G 1953 1960 - O Sun>=2 2s 0 GMT
++R G 1954 o - Ap Sun>=9 2s 1 BST
++R G 1955 1956 - Ap Sun>=16 2s 1 BST
++R G 1957 o - Ap Sun>=9 2s 1 BST
++R G 1958 1959 - Ap Sun>=16 2s 1 BST
++R G 1960 o - Ap Sun>=9 2s 1 BST
++R G 1961 1963 - Mar lastSun 2s 1 BST
++R G 1961 1968 - O Sun>=23 2s 0 GMT
++R G 1964 1967 - Mar Sun>=19 2s 1 BST
++R G 1968 o - F 18 2s 1 BST
++R G 1972 1980 - Mar Sun>=16 2s 1 BST
++R G 1972 1980 - O Sun>=23 2s 0 GMT
++R G 1981 1995 - Mar lastSun 1u 1 BST
++R G 1981 1989 - O Sun>=23 1u 0 GMT
++R G 1990 1995 - O Sun>=22 1u 0 GMT
+ Z Europe/London -0:1:15 - LMT 1847 D 1 0s
+-0 % %s 1968 O 27
++0 G %s 1968 O 27
+ 1 - BST 1971 O 31 2u
+-0 % %s 1996
+-0 O GMT/BST
++0 G %s 1996
++0 E GMT/BST
+ Li Europe/London Europe/Jersey
+ Li Europe/London Europe/Guernsey
+ Li Europe/London Europe/Isle_of_Man
+-R & 1971 o - O 31 2u -1 -
+-R & 1972 1980 - Mar Sun>=16 2u 0 -
+-R & 1972 1980 - O Sun>=23 2u -1 -
+-R & 1981 ma - Mar lastSun 1u 0 -
+-R & 1981 1989 - O Sun>=23 1u -1 -
+-R & 1990 1995 - O Sun>=22 1u -1 -
+-R & 1996 ma - O lastSun 1u -1 -
++R IE 1971 o - O 31 2u -1 -
++R IE 1972 1980 - Mar Sun>=16 2u 0 -
++R IE 1972 1980 - O Sun>=23 2u -1 -
++R IE 1981 ma - Mar lastSun 1u 0 -
++R IE 1981 1989 - O Sun>=23 1u -1 -
++R IE 1990 1995 - O Sun>=22 1u -1 -
++R IE 1996 ma - O lastSun 1u -1 -
+ Z Europe/Dublin -0:25 - LMT 1880 Au 2
+ -0:25:21 - DMT 1916 May 21 2s
+ -0:25:21 1 IST 1916 O 1 2s
+-0 % %s 1921 D 6
+-0 % GMT/IST 1940 F 25 2s
++0 G %s 1921 D 6
++0 G GMT/IST 1940 F 25 2s
+ 0 1 IST 1946 O 6 2s
+ 0 - GMT 1947 Mar 16 2s
+ 0 1 IST 1947 N 2 2s
+ 0 - GMT 1948 Ap 18 2s
+-0 % GMT/IST 1968 O 27
+-1 & IST/GMT
+-R O 1977 1980 - Ap Sun>=1 1u 1 S
+-R O 1977 o - S lastSun 1u 0 -
+-R O 1978 o - O 1 1u 0 -
+-R O 1979 1995 - S lastSun 1u 0 -
+-R O 1981 ma - Mar lastSun 1u 1 S
+-R O 1996 ma - O lastSun 1u 0 -
+-R ' 1977 1980 - Ap Sun>=1 1s 1 S
+-R ' 1977 o - S lastSun 1s 0 -
+-R ' 1978 o - O 1 1s 0 -
+-R ' 1979 1995 - S lastSun 1s 0 -
+-R ' 1981 ma - Mar lastSun 1s 1 S
+-R ' 1996 ma - O lastSun 1s 0 -
+-R ( 1916 o - Ap 30 23 1 S
+-R ( 1916 o - O 1 1 0 -
+-R ( 1917 1918 - Ap M>=15 2s 1 S
+-R ( 1917 1918 - S M>=15 2s 0 -
+-R ( 1940 o - Ap 1 2s 1 S
+-R ( 1942 o - N 2 2s 0 -
+-R ( 1943 o - Mar 29 2s 1 S
+-R ( 1943 o - O 4 2s 0 -
+-R ( 1944 1945 - Ap M>=1 2s 1 S
+-R ( 1944 o - O 2 2s 0 -
+-R ( 1945 o - S 16 2s 0 -
+-R ( 1977 1980 - Ap Sun>=1 2s 1 S
+-R ( 1977 o - S lastSun 2s 0 -
+-R ( 1978 o - O 1 2s 0 -
+-R ( 1979 1995 - S lastSun 2s 0 -
+-R ( 1981 ma - Mar lastSun 2s 1 S
+-R ( 1996 ma - O lastSun 2s 0 -
+-R W 1977 1980 - Ap Sun>=1 0 1 S
+-R W 1977 o - S lastSun 0 0 -
+-R W 1978 o - O 1 0 0 -
+-R W 1979 1995 - S lastSun 0 0 -
+-R W 1981 ma - Mar lastSun 0 1 S
+-R W 1996 ma - O lastSun 0 0 -
+-R M 1917 o - Jul 1 23 1 MST
+-R M 1917 o - D 28 0 0 MMT
+-R M 1918 o - May 31 22 2 MDST
+-R M 1918 o - S 16 1 1 MST
+-R M 1919 o - May 31 23 2 MDST
+-R M 1919 o - Jul 1 0u 1 MSD
+-R M 1919 o - Au 16 0 0 MSK
+-R M 1921 o - F 14 23 1 MSD
+-R M 1921 o - Mar 20 23 2 +05
+-R M 1921 o - S 1 0 1 MSD
+-R M 1921 o - O 1 0 0 -
+-R M 1981 1984 - Ap 1 0 1 S
+-R M 1981 1983 - O 1 0 0 -
+-R M 1984 1995 - S lastSun 2s 0 -
+-R M 1985 2010 - Mar lastSun 2s 1 S
+-R M 1996 2010 - O lastSun 2s 0 -
+-Z WET 0 O WE%sT
+-Z CET 1 ( CE%sT
+-Z MET 1 ( ME%sT
+-Z EET 2 O EE%sT
+-R ) 1940 o - Jun 16 0 1 S
+-R ) 1942 o - N 2 3 0 -
+-R ) 1943 o - Mar 29 2 1 S
+-R ) 1943 o - Ap 10 3 0 -
+-R ) 1974 o - May 4 0 1 S
+-R ) 1974 o - O 2 0 0 -
+-R ) 1975 o - May 1 0 1 S
+-R ) 1975 o - O 2 0 0 -
+-R ) 1976 o - May 2 0 1 S
+-R ) 1976 o - O 3 0 0 -
+-R ) 1977 o - May 8 0 1 S
+-R ) 1977 o - O 2 0 0 -
+-R ) 1978 o - May 6 0 1 S
+-R ) 1978 o - O 1 0 0 -
+-R ) 1979 o - May 5 0 1 S
+-R ) 1979 o - S 30 0 0 -
+-R ) 1980 o - May 3 0 1 S
+-R ) 1980 o - O 4 0 0 -
+-R ) 1981 o - Ap 26 0 1 S
+-R ) 1981 o - S 27 0 0 -
+-R ) 1982 o - May 2 0 1 S
+-R ) 1982 o - O 3 0 0 -
+-R ) 1983 o - Ap 18 0 1 S
+-R ) 1983 o - O 1 0 0 -
+-R ) 1984 o - Ap 1 0 1 S
++0 G GMT/IST 1968 O 27
++1 IE IST/GMT
++R E 1977 1980 - Ap Sun>=1 1u 1 S
++R E 1977 o - S lastSun 1u 0 -
++R E 1978 o - O 1 1u 0 -
++R E 1979 1995 - S lastSun 1u 0 -
++R E 1981 ma - Mar lastSun 1u 1 S
++R E 1996 ma - O lastSun 1u 0 -
++R W- 1977 1980 - Ap Sun>=1 1s 1 S
++R W- 1977 o - S lastSun 1s 0 -
++R W- 1978 o - O 1 1s 0 -
++R W- 1979 1995 - S lastSun 1s 0 -
++R W- 1981 ma - Mar lastSun 1s 1 S
++R W- 1996 ma - O lastSun 1s 0 -
++R c 1916 o - Ap 30 23 1 S
++R c 1916 o - O 1 1 0 -
++R c 1917 1918 - Ap M>=15 2s 1 S
++R c 1917 1918 - S M>=15 2s 0 -
++R c 1940 o - Ap 1 2s 1 S
++R c 1942 o - N 2 2s 0 -
++R c 1943 o - Mar 29 2s 1 S
++R c 1943 o - O 4 2s 0 -
++R c 1944 1945 - Ap M>=1 2s 1 S
++R c 1944 o - O 2 2s 0 -
++R c 1945 o - S 16 2s 0 -
++R c 1977 1980 - Ap Sun>=1 2s 1 S
++R c 1977 o - S lastSun 2s 0 -
++R c 1978 o - O 1 2s 0 -
++R c 1979 1995 - S lastSun 2s 0 -
++R c 1981 ma - Mar lastSun 2s 1 S
++R c 1996 ma - O lastSun 2s 0 -
++R e 1977 1980 - Ap Sun>=1 0 1 S
++R e 1977 o - S lastSun 0 0 -
++R e 1978 o - O 1 0 0 -
++R e 1979 1995 - S lastSun 0 0 -
++R e 1981 ma - Mar lastSun 0 1 S
++R e 1996 ma - O lastSun 0 0 -
++R R 1917 o - Jul 1 23 1 MST
++R R 1917 o - D 28 0 0 MMT
++R R 1918 o - May 31 22 2 MDST
++R R 1918 o - S 16 1 1 MST
++R R 1919 o - May 31 23 2 MDST
++R R 1919 o - Jul 1 0u 1 MSD
++R R 1919 o - Au 16 0 0 MSK
++R R 1921 o - F 14 23 1 MSD
++R R 1921 o - Mar 20 23 2 +05
++R R 1921 o - S 1 0 1 MSD
++R R 1921 o - O 1 0 0 -
++R R 1981 1984 - Ap 1 0 1 S
++R R 1981 1983 - O 1 0 0 -
++R R 1984 1995 - S lastSun 2s 0 -
++R R 1985 2010 - Mar lastSun 2s 1 S
++R R 1996 2010 - O lastSun 2s 0 -
++Z WET 0 E WE%sT
++Z CET 1 c CE%sT
++Z MET 1 c ME%sT
++Z EET 2 E EE%sT
++R q 1940 o - Jun 16 0 1 S
++R q 1942 o - N 2 3 0 -
++R q 1943 o - Mar 29 2 1 S
++R q 1943 o - Ap 10 3 0 -
++R q 1974 o - May 4 0 1 S
++R q 1974 o - O 2 0 0 -
++R q 1975 o - May 1 0 1 S
++R q 1975 o - O 2 0 0 -
++R q 1976 o - May 2 0 1 S
++R q 1976 o - O 3 0 0 -
++R q 1977 o - May 8 0 1 S
++R q 1977 o - O 2 0 0 -
++R q 1978 o - May 6 0 1 S
++R q 1978 o - O 1 0 0 -
++R q 1979 o - May 5 0 1 S
++R q 1979 o - S 30 0 0 -
++R q 1980 o - May 3 0 1 S
++R q 1980 o - O 4 0 0 -
++R q 1981 o - Ap 26 0 1 S
++R q 1981 o - S 27 0 0 -
++R q 1982 o - May 2 0 1 S
++R q 1982 o - O 3 0 0 -
++R q 1983 o - Ap 18 0 1 S
++R q 1983 o - O 1 0 0 -
++R q 1984 o - Ap 1 0 1 S
+ Z Europe/Tirane 1:19:20 - LMT 1914
+ 1 - CET 1940 Jun 16
+-1 ) CE%sT 1984 Jul
+-1 O CE%sT
++1 q CE%sT 1984 Jul
++1 E CE%sT
+ Z Europe/Andorra 0:6:4 - LMT 1901
+ 0 - WET 1946 S 30
+ 1 - CET 1985 Mar 31 2
+-1 O CE%sT
+-R * 1920 o - Ap 5 2s 1 S
+-R * 1920 o - S 13 2s 0 -
+-R * 1946 o - Ap 14 2s 1 S
+-R * 1946 1948 - O Sun>=1 2s 0 -
+-R * 1947 o - Ap 6 2s 1 S
+-R * 1948 o - Ap 18 2s 1 S
+-R * 1980 o - Ap 6 0 1 S
+-R * 1980 o - S 28 0 0 -
++1 E CE%sT
++R a 1920 o - Ap 5 2s 1 S
++R a 1920 o - S 13 2s 0 -
++R a 1946 o - Ap 14 2s 1 S
++R a 1946 1948 - O Sun>=1 2s 0 -
++R a 1947 o - Ap 6 2s 1 S
++R a 1948 o - Ap 18 2s 1 S
++R a 1980 o - Ap 6 0 1 S
++R a 1980 o - S 28 0 0 -
+ Z Europe/Vienna 1:5:21 - LMT 1893 Ap
+-1 ( CE%sT 1920
+-1 * CE%sT 1940 Ap 1 2s
+-1 ( CE%sT 1945 Ap 2 2s
++1 c CE%sT 1920
++1 a CE%sT 1940 Ap 1 2s
++1 c CE%sT 1945 Ap 2 2s
+ 1 1 CEST 1945 Ap 12 2s
+ 1 - CET 1946
+-1 * CE%sT 1981
+-1 O CE%sT
++1 a CE%sT 1981
++1 E CE%sT
+ Z Europe/Minsk 1:50:16 - LMT 1880
+ 1:50 - MMT 1924 May 2
+ 2 - EET 1930 Jun 21
+ 3 - MSK 1941 Jun 28
+-1 ( CE%sT 1944 Jul 3
+-3 M MSK/MSD 1990
++1 c CE%sT 1944 Jul 3
++3 R MSK/MSD 1990
+ 3 - MSK 1991 Mar 31 2s
+-2 M EE%sT 2011 Mar 27 2s
++2 R EE%sT 2011 Mar 27 2s
+ 3 - +03
+-R + 1918 o - Mar 9 0s 1 S
+-R + 1918 1919 - O Sat>=1 23s 0 -
+-R + 1919 o - Mar 1 23s 1 S
+-R + 1920 o - F 14 23s 1 S
+-R + 1920 o - O 23 23s 0 -
+-R + 1921 o - Mar 14 23s 1 S
+-R + 1921 o - O 25 23s 0 -
+-R + 1922 o - Mar 25 23s 1 S
+-R + 1922 1927 - O Sat>=1 23s 0 -
+-R + 1923 o - Ap 21 23s 1 S
+-R + 1924 o - Mar 29 23s 1 S
+-R + 1925 o - Ap 4 23s 1 S
+-R + 1926 o - Ap 17 23s 1 S
+-R + 1927 o - Ap 9 23s 1 S
+-R + 1928 o - Ap 14 23s 1 S
+-R + 1928 1938 - O Sun>=2 2s 0 -
+-R + 1929 o - Ap 21 2s 1 S
+-R + 1930 o - Ap 13 2s 1 S
+-R + 1931 o - Ap 19 2s 1 S
+-R + 1932 o - Ap 3 2s 1 S
+-R + 1933 o - Mar 26 2s 1 S
+-R + 1934 o - Ap 8 2s 1 S
+-R + 1935 o - Mar 31 2s 1 S
+-R + 1936 o - Ap 19 2s 1 S
+-R + 1937 o - Ap 4 2s 1 S
+-R + 1938 o - Mar 27 2s 1 S
+-R + 1939 o - Ap 16 2s 1 S
+-R + 1939 o - N 19 2s 0 -
+-R + 1940 o - F 25 2s 1 S
+-R + 1944 o - S 17 2s 0 -
+-R + 1945 o - Ap 2 2s 1 S
+-R + 1945 o - S 16 2s 0 -
+-R + 1946 o - May 19 2s 1 S
+-R + 1946 o - O 7 2s 0 -
++R b 1918 o - Mar 9 0s 1 S
++R b 1918 1919 - O Sat>=1 23s 0 -
++R b 1919 o - Mar 1 23s 1 S
++R b 1920 o - F 14 23s 1 S
++R b 1920 o - O 23 23s 0 -
++R b 1921 o - Mar 14 23s 1 S
++R b 1921 o - O 25 23s 0 -
++R b 1922 o - Mar 25 23s 1 S
++R b 1922 1927 - O Sat>=1 23s 0 -
++R b 1923 o - Ap 21 23s 1 S
++R b 1924 o - Mar 29 23s 1 S
++R b 1925 o - Ap 4 23s 1 S
++R b 1926 o - Ap 17 23s 1 S
++R b 1927 o - Ap 9 23s 1 S
++R b 1928 o - Ap 14 23s 1 S
++R b 1928 1938 - O Sun>=2 2s 0 -
++R b 1929 o - Ap 21 2s 1 S
++R b 1930 o - Ap 13 2s 1 S
++R b 1931 o - Ap 19 2s 1 S
++R b 1932 o - Ap 3 2s 1 S
++R b 1933 o - Mar 26 2s 1 S
++R b 1934 o - Ap 8 2s 1 S
++R b 1935 o - Mar 31 2s 1 S
++R b 1936 o - Ap 19 2s 1 S
++R b 1937 o - Ap 4 2s 1 S
++R b 1938 o - Mar 27 2s 1 S
++R b 1939 o - Ap 16 2s 1 S
++R b 1939 o - N 19 2s 0 -
++R b 1940 o - F 25 2s 1 S
++R b 1944 o - S 17 2s 0 -
++R b 1945 o - Ap 2 2s 1 S
++R b 1945 o - S 16 2s 0 -
++R b 1946 o - May 19 2s 1 S
++R b 1946 o - O 7 2s 0 -
+ Z Europe/Brussels 0:17:30 - LMT 1880
+ 0:17:30 - BMT 1892 May 1 12
+ 0 - WET 1914 N 8
+ 1 - CET 1916 May
+-1 ( CE%sT 1918 N 11 11u
+-0 + WE%sT 1940 May 20 2s
+-1 ( CE%sT 1944 S 3
+-1 + CE%sT 1977
+-1 O CE%sT
+-R , 1979 o - Mar 31 23 1 S
+-R , 1979 o - O 1 1 0 -
+-R , 1980 1982 - Ap Sat>=1 23 1 S
+-R , 1980 o - S 29 1 0 -
+-R , 1981 o - S 27 2 0 -
++1 c CE%sT 1918 N 11 11u
++0 b WE%sT 1940 May 20 2s
++1 c CE%sT 1944 S 3
++1 b CE%sT 1977
++1 E CE%sT
++R BG 1979 o - Mar 31 23 1 S
++R BG 1979 o - O 1 1 0 -
++R BG 1980 1982 - Ap Sat>=1 23 1 S
++R BG 1980 o - S 29 1 0 -
++R BG 1981 o - S 27 2 0 -
+ Z Europe/Sofia 1:33:16 - LMT 1880
+ 1:56:56 - IMT 1894 N 30
+ 2 - EET 1942 N 2 3
+-1 ( CE%sT 1945
++1 c CE%sT 1945
+ 1 - CET 1945 Ap 2 3
+ 2 - EET 1979 Mar 31 23
+-2 , EE%sT 1982 S 26 3
+-2 ( EE%sT 1991
+-2 W EE%sT 1997
+-2 O EE%sT
+-R . 1945 o - Ap M>=1 2s 1 S
+-R . 1945 o - O 1 2s 0 -
+-R . 1946 o - May 6 2s 1 S
+-R . 1946 1949 - O Sun>=1 2s 0 -
+-R . 1947 1948 - Ap Sun>=15 2s 1 S
+-R . 1949 o - Ap 9 2s 1 S
++2 BG EE%sT 1982 S 26 3
++2 c EE%sT 1991
++2 e EE%sT 1997
++2 E EE%sT
++R CZ 1945 o - Ap M>=1 2s 1 S
++R CZ 1945 o - O 1 2s 0 -
++R CZ 1946 o - May 6 2s 1 S
++R CZ 1946 1949 - O Sun>=1 2s 0 -
++R CZ 1947 1948 - Ap Sun>=15 2s 1 S
++R CZ 1949 o - Ap 9 2s 1 S
+ Z Europe/Prague 0:57:44 - LMT 1850
+ 0:57:44 - PMT 1891 O
+-1 ( CE%sT 1945 May 9
+-1 . CE%sT 1946 D 1 3
++1 c CE%sT 1945 May 9
++1 CZ CE%sT 1946 D 1 3
+ 1 -1 GMT 1947 F 23 2
+-1 . CE%sT 1979
+-1 O CE%sT
+-R / 1916 o - May 14 23 1 S
+-R / 1916 o - S 30 23 0 -
+-R / 1940 o - May 15 0 1 S
+-R / 1945 o - Ap 2 2s 1 S
+-R / 1945 o - Au 15 2s 0 -
+-R / 1946 o - May 1 2s 1 S
+-R / 1946 o - S 1 2s 0 -
+-R / 1947 o - May 4 2s 1 S
+-R / 1947 o - Au 10 2s 0 -
+-R / 1948 o - May 9 2s 1 S
+-R / 1948 o - Au 8 2s 0 -
++1 CZ CE%sT 1979
++1 E CE%sT
++R D 1916 o - May 14 23 1 S
++R D 1916 o - S 30 23 0 -
++R D 1940 o - May 15 0 1 S
++R D 1945 o - Ap 2 2s 1 S
++R D 1945 o - Au 15 2s 0 -
++R D 1946 o - May 1 2s 1 S
++R D 1946 o - S 1 2s 0 -
++R D 1947 o - May 4 2s 1 S
++R D 1947 o - Au 10 2s 0 -
++R D 1948 o - May 9 2s 1 S
++R D 1948 o - Au 8 2s 0 -
+ Z Europe/Copenhagen 0:50:20 - LMT 1890
+ 0:50:20 - CMT 1894
+-1 / CE%sT 1942 N 2 2s
+-1 ( CE%sT 1945 Ap 2 2
+-1 / CE%sT 1980
+-1 O CE%sT
++1 D CE%sT 1942 N 2 2s
++1 c CE%sT 1945 Ap 2 2
++1 D CE%sT 1980
++1 E CE%sT
+ Z Atlantic/Faroe -0:27:4 - LMT 1908 Ja 11
+ 0 - WET 1981
+-0 O WE%sT
+-R : 1991 1992 - Mar lastSun 2 1 D
+-R : 1991 1992 - S lastSun 2 0 S
+-R : 1993 2006 - Ap Sun>=1 2 1 D
+-R : 1993 2006 - O lastSun 2 0 S
+-R : 2007 ma - Mar Sun>=8 2 1 D
+-R : 2007 ma - N Sun>=1 2 0 S
++0 E WE%sT
++R Th 1991 1992 - Mar lastSun 2 1 D
++R Th 1991 1992 - S lastSun 2 0 S
++R Th 1993 2006 - Ap Sun>=1 2 1 D
++R Th 1993 2006 - O lastSun 2 0 S
++R Th 2007 ma - Mar Sun>=8 2 1 D
++R Th 2007 ma - N Sun>=1 2 0 S
+ Z America/Danmarkshavn -1:14:40 - LMT 1916 Jul 28
+ -3 - -03 1980 Ap 6 2
+--3 O -03/-02 1996
++-3 E -03/-02 1996
+ 0 - GMT
+ Z America/Scoresbysund -1:27:52 - LMT 1916 Jul 28
+ -2 - -02 1980 Ap 6 2
+--2 ( -02/-01 1981 Mar 29
+--1 O -01/+00
++-2 c -02/-01 1981 Mar 29
++-1 E -01/+00
+ Z America/Godthab -3:26:56 - LMT 1916 Jul 28
+ -3 - -03 1980 Ap 6 2
+--3 O -03/-02
++-3 E -03/-02
+ Z America/Thule -4:35:8 - LMT 1916 Jul 28
+--4 : A%sT
++-4 Th A%sT
+ Z Europe/Tallinn 1:39 - LMT 1880
+ 1:39 - TMT 1918 F
+-1 ( CE%sT 1919 Jul
++1 c CE%sT 1919 Jul
+ 1:39 - TMT 1921 May
+ 2 - EET 1940 Au 6
+ 3 - MSK 1941 S 15
+-1 ( CE%sT 1944 S 22
+-3 M MSK/MSD 1989 Mar 26 2s
++1 c CE%sT 1944 S 22
++3 R MSK/MSD 1989 Mar 26 2s
+ 2 1 EEST 1989 S 24 2s
+-2 ( EE%sT 1998 S 22
+-2 O EE%sT 1999 O 31 4
++2 c EE%sT 1998 S 22
++2 E EE%sT 1999 O 31 4
+ 2 - EET 2002 F 21
+-2 O EE%sT
+-R ; 1942 o - Ap 2 24 1 S
+-R ; 1942 o - O 4 1 0 -
+-R ; 1981 1982 - Mar lastSun 2 1 S
+-R ; 1981 1982 - S lastSun 3 0 -
++2 E EE%sT
++R FI 1942 o - Ap 2 24 1 S
++R FI 1942 o - O 4 1 0 -
++R FI 1981 1982 - Mar lastSun 2 1 S
++R FI 1981 1982 - S lastSun 3 0 -
+ Z Europe/Helsinki 1:39:49 - LMT 1878 May 31
+ 1:39:49 - HMT 1921 May
+-2 ; EE%sT 1983
+-2 O EE%sT
++2 FI EE%sT 1983
++2 E EE%sT
+ Li Europe/Helsinki Europe/Mariehamn
+-R < 1916 o - Jun 14 23s 1 S
+-R < 1916 1919 - O Sun>=1 23s 0 -
+-R < 1917 o - Mar 24 23s 1 S
+-R < 1918 o - Mar 9 23s 1 S
+-R < 1919 o - Mar 1 23s 1 S
+-R < 1920 o - F 14 23s 1 S
+-R < 1920 o - O 23 23s 0 -
+-R < 1921 o - Mar 14 23s 1 S
+-R < 1921 o - O 25 23s 0 -
+-R < 1922 o - Mar 25 23s 1 S
+-R < 1922 1938 - O Sat>=1 23s 0 -
+-R < 1923 o - May 26 23s 1 S
+-R < 1924 o - Mar 29 23s 1 S
+-R < 1925 o - Ap 4 23s 1 S
+-R < 1926 o - Ap 17 23s 1 S
+-R < 1927 o - Ap 9 23s 1 S
+-R < 1928 o - Ap 14 23s 1 S
+-R < 1929 o - Ap 20 23s 1 S
+-R < 1930 o - Ap 12 23s 1 S
+-R < 1931 o - Ap 18 23s 1 S
+-R < 1932 o - Ap 2 23s 1 S
+-R < 1933 o - Mar 25 23s 1 S
+-R < 1934 o - Ap 7 23s 1 S
+-R < 1935 o - Mar 30 23s 1 S
+-R < 1936 o - Ap 18 23s 1 S
+-R < 1937 o - Ap 3 23s 1 S
+-R < 1938 o - Mar 26 23s 1 S
+-R < 1939 o - Ap 15 23s 1 S
+-R < 1939 o - N 18 23s 0 -
+-R < 1940 o - F 25 2 1 S
+-R < 1941 o - May 5 0 2 M
+-R < 1941 o - O 6 0 1 S
+-R < 1942 o - Mar 9 0 2 M
+-R < 1942 o - N 2 3 1 S
+-R < 1943 o - Mar 29 2 2 M
+-R < 1943 o - O 4 3 1 S
+-R < 1944 o - Ap 3 2 2 M
+-R < 1944 o - O 8 1 1 S
+-R < 1945 o - Ap 2 2 2 M
+-R < 1945 o - S 16 3 0 -
+-R < 1976 o - Mar 28 1 1 S
+-R < 1976 o - S 26 1 0 -
++R F 1916 o - Jun 14 23s 1 S
++R F 1916 1919 - O Sun>=1 23s 0 -
++R F 1917 o - Mar 24 23s 1 S
++R F 1918 o - Mar 9 23s 1 S
++R F 1919 o - Mar 1 23s 1 S
++R F 1920 o - F 14 23s 1 S
++R F 1920 o - O 23 23s 0 -
++R F 1921 o - Mar 14 23s 1 S
++R F 1921 o - O 25 23s 0 -
++R F 1922 o - Mar 25 23s 1 S
++R F 1922 1938 - O Sat>=1 23s 0 -
++R F 1923 o - May 26 23s 1 S
++R F 1924 o - Mar 29 23s 1 S
++R F 1925 o - Ap 4 23s 1 S
++R F 1926 o - Ap 17 23s 1 S
++R F 1927 o - Ap 9 23s 1 S
++R F 1928 o - Ap 14 23s 1 S
++R F 1929 o - Ap 20 23s 1 S
++R F 1930 o - Ap 12 23s 1 S
++R F 1931 o - Ap 18 23s 1 S
++R F 1932 o - Ap 2 23s 1 S
++R F 1933 o - Mar 25 23s 1 S
++R F 1934 o - Ap 7 23s 1 S
++R F 1935 o - Mar 30 23s 1 S
++R F 1936 o - Ap 18 23s 1 S
++R F 1937 o - Ap 3 23s 1 S
++R F 1938 o - Mar 26 23s 1 S
++R F 1939 o - Ap 15 23s 1 S
++R F 1939 o - N 18 23s 0 -
++R F 1940 o - F 25 2 1 S
++R F 1941 o - May 5 0 2 M
++R F 1941 o - O 6 0 1 S
++R F 1942 o - Mar 9 0 2 M
++R F 1942 o - N 2 3 1 S
++R F 1943 o - Mar 29 2 2 M
++R F 1943 o - O 4 3 1 S
++R F 1944 o - Ap 3 2 2 M
++R F 1944 o - O 8 1 1 S
++R F 1945 o - Ap 2 2 2 M
++R F 1945 o - S 16 3 0 -
++R F 1976 o - Mar 28 1 1 S
++R F 1976 o - S 26 1 0 -
+ Z Europe/Paris 0:9:21 - LMT 1891 Mar 15 0:1
+ 0:9:21 - PMT 1911 Mar 11 0:1
+-0 < WE%sT 1940 Jun 14 23
+-1 ( CE%sT 1944 Au 25
+-0 < WE%sT 1945 S 16 3
+-1 < CE%sT 1977
+-1 O CE%sT
+-R = 1946 o - Ap 14 2s 1 S
+-R = 1946 o - O 7 2s 0 -
+-R = 1947 1949 - O Sun>=1 2s 0 -
+-R = 1947 o - Ap 6 3s 1 S
+-R = 1947 o - May 11 2s 2 M
+-R = 1947 o - Jun 29 3 1 S
+-R = 1948 o - Ap 18 2s 1 S
+-R = 1949 o - Ap 10 2s 1 S
+-R > 1945 o - May 24 2 2 M
+-R > 1945 o - S 24 3 1 S
+-R > 1945 o - N 18 2s 0 -
++0 F WE%sT 1940 Jun 14 23
++1 c CE%sT 1944 Au 25
++0 F WE%sT 1945 S 16 3
++1 F CE%sT 1977
++1 E CE%sT
++R DE 1946 o - Ap 14 2s 1 S
++R DE 1946 o - O 7 2s 0 -
++R DE 1947 1949 - O Sun>=1 2s 0 -
++R DE 1947 o - Ap 6 3s 1 S
++R DE 1947 o - May 11 2s 2 M
++R DE 1947 o - Jun 29 3 1 S
++R DE 1948 o - Ap 18 2s 1 S
++R DE 1949 o - Ap 10 2s 1 S
++R So 1945 o - May 24 2 2 M
++R So 1945 o - S 24 3 1 S
++R So 1945 o - N 18 2s 0 -
+ Z Europe/Berlin 0:53:28 - LMT 1893 Ap
+-1 ( CE%sT 1945 May 24 2
+-1 > CE%sT 1946
+-1 = CE%sT 1980
+-1 O CE%sT
++1 c CE%sT 1945 May 24 2
++1 So CE%sT 1946
++1 DE CE%sT 1980
++1 E CE%sT
+ Li Europe/Zurich Europe/Busingen
+ Z Europe/Gibraltar -0:21:24 - LMT 1880 Au 2 0s
+-0 % %s 1957 Ap 14 2
++0 G %s 1957 Ap 14 2
+ 1 - CET 1982
+-1 O CE%sT
+-R ? 1932 o - Jul 7 0 1 S
+-R ? 1932 o - S 1 0 0 -
+-R ? 1941 o - Ap 7 0 1 S
+-R ? 1942 o - N 2 3 0 -
+-R ? 1943 o - Mar 30 0 1 S
+-R ? 1943 o - O 4 0 0 -
+-R ? 1952 o - Jul 1 0 1 S
+-R ? 1952 o - N 2 0 0 -
+-R ? 1975 o - Ap 12 0s 1 S
+-R ? 1975 o - N 26 0s 0 -
+-R ? 1976 o - Ap 11 2s 1 S
+-R ? 1976 o - O 10 2s 0 -
+-R ? 1977 1978 - Ap Sun>=1 2s 1 S
+-R ? 1977 o - S 26 2s 0 -
+-R ? 1978 o - S 24 4 0 -
+-R ? 1979 o - Ap 1 9 1 S
+-R ? 1979 o - S 29 2 0 -
+-R ? 1980 o - Ap 1 0 1 S
+-R ? 1980 o - S 28 0 0 -
++1 E CE%sT
++R g 1932 o - Jul 7 0 1 S
++R g 1932 o - S 1 0 0 -
++R g 1941 o - Ap 7 0 1 S
++R g 1942 o - N 2 3 0 -
++R g 1943 o - Mar 30 0 1 S
++R g 1943 o - O 4 0 0 -
++R g 1952 o - Jul 1 0 1 S
++R g 1952 o - N 2 0 0 -
++R g 1975 o - Ap 12 0s 1 S
++R g 1975 o - N 26 0s 0 -
++R g 1976 o - Ap 11 2s 1 S
++R g 1976 o - O 10 2s 0 -
++R g 1977 1978 - Ap Sun>=1 2s 1 S
++R g 1977 o - S 26 2s 0 -
++R g 1978 o - S 24 4 0 -
++R g 1979 o - Ap 1 9 1 S
++R g 1979 o - S 29 2 0 -
++R g 1980 o - Ap 1 0 1 S
++R g 1980 o - S 28 0 0 -
+ Z Europe/Athens 1:34:52 - LMT 1895 S 14
+ 1:34:52 - AMT 1916 Jul 28 0:1
+-2 ? EE%sT 1941 Ap 30
+-1 ? CE%sT 1944 Ap 4
+-2 ? EE%sT 1981
+-2 O EE%sT
+-R @ 1918 o - Ap 1 3 1 S
+-R @ 1918 o - S 16 3 0 -
+-R @ 1919 o - Ap 15 3 1 S
+-R @ 1919 o - N 24 3 0 -
+-R @ 1945 o - May 1 23 1 S
+-R @ 1945 o - N 1 0 0 -
+-R @ 1946 o - Mar 31 2s 1 S
+-R @ 1946 1949 - O Sun>=1 2s 0 -
+-R @ 1947 1949 - Ap Sun>=4 2s 1 S
+-R @ 1950 o - Ap 17 2s 1 S
+-R @ 1950 o - O 23 2s 0 -
+-R @ 1954 1955 - May 23 0 1 S
+-R @ 1954 1955 - O 3 0 0 -
+-R @ 1956 o - Jun Sun>=1 0 1 S
+-R @ 1956 o - S lastSun 0 0 -
+-R @ 1957 o - Jun Sun>=1 1 1 S
+-R @ 1957 o - S lastSun 3 0 -
+-R @ 1980 o - Ap 6 1 1 S
++2 g EE%sT 1941 Ap 30
++1 g CE%sT 1944 Ap 4
++2 g EE%sT 1981
++2 E EE%sT
++R h 1918 o - Ap 1 3 1 S
++R h 1918 o - S 16 3 0 -
++R h 1919 o - Ap 15 3 1 S
++R h 1919 o - N 24 3 0 -
++R h 1945 o - May 1 23 1 S
++R h 1945 o - N 1 0 0 -
++R h 1946 o - Mar 31 2s 1 S
++R h 1946 1949 - O Sun>=1 2s 0 -
++R h 1947 1949 - Ap Sun>=4 2s 1 S
++R h 1950 o - Ap 17 2s 1 S
++R h 1950 o - O 23 2s 0 -
++R h 1954 1955 - May 23 0 1 S
++R h 1954 1955 - O 3 0 0 -
++R h 1956 o - Jun Sun>=1 0 1 S
++R h 1956 o - S lastSun 0 0 -
++R h 1957 o - Jun Sun>=1 1 1 S
++R h 1957 o - S lastSun 3 0 -
++R h 1980 o - Ap 6 1 1 S
+ Z Europe/Budapest 1:16:20 - LMT 1890 O
+-1 ( CE%sT 1918
+-1 @ CE%sT 1941 Ap 8
+-1 ( CE%sT 1945
+-1 @ CE%sT 1980 S 28 2s
+-1 O CE%sT
+-R [ 1917 1919 - F 19 23 1 -
+-R [ 1917 o - O 21 1 0 -
+-R [ 1918 1919 - N 16 1 0 -
+-R [ 1921 o - Mar 19 23 1 -
+-R [ 1921 o - Jun 23 1 0 -
+-R [ 1939 o - Ap 29 23 1 -
+-R [ 1939 o - O 29 2 0 -
+-R [ 1940 o - F 25 2 1 -
+-R [ 1940 1941 - N Sun>=2 1s 0 -
+-R [ 1941 1942 - Mar Sun>=2 1s 1 -
+-R [ 1943 1946 - Mar Sun>=1 1s 1 -
+-R [ 1942 1948 - O Sun>=22 1s 0 -
+-R [ 1947 1967 - Ap Sun>=1 1s 1 -
+-R [ 1949 o - O 30 1s 0 -
+-R [ 1950 1966 - O Sun>=22 1s 0 -
+-R [ 1967 o - O 29 1s 0 -
++1 c CE%sT 1918
++1 h CE%sT 1941 Ap 8
++1 c CE%sT 1945
++1 h CE%sT 1980 S 28 2s
++1 E CE%sT
++R w 1917 1919 - F 19 23 1 -
++R w 1917 o - O 21 1 0 -
++R w 1918 1919 - N 16 1 0 -
++R w 1921 o - Mar 19 23 1 -
++R w 1921 o - Jun 23 1 0 -
++R w 1939 o - Ap 29 23 1 -
++R w 1939 o - O 29 2 0 -
++R w 1940 o - F 25 2 1 -
++R w 1940 1941 - N Sun>=2 1s 0 -
++R w 1941 1942 - Mar Sun>=2 1s 1 -
++R w 1943 1946 - Mar Sun>=1 1s 1 -
++R w 1942 1948 - O Sun>=22 1s 0 -
++R w 1947 1967 - Ap Sun>=1 1s 1 -
++R w 1949 o - O 30 1s 0 -
++R w 1950 1966 - O Sun>=22 1s 0 -
++R w 1967 o - O 29 1s 0 -
+ Z Atlantic/Reykjavik -1:28 - LMT 1908
+--1 [ -01/+00 1968 Ap 7 1s
++-1 w -01/+00 1968 Ap 7 1s
+ 0 - GMT
+-R \ 1916 o - Jun 3 24 1 S
+-R \ 1916 1917 - S 30 24 0 -
+-R \ 1917 o - Mar 31 24 1 S
+-R \ 1918 o - Mar 9 24 1 S
+-R \ 1918 o - O 6 24 0 -
+-R \ 1919 o - Mar 1 24 1 S
+-R \ 1919 o - O 4 24 0 -
+-R \ 1920 o - Mar 20 24 1 S
+-R \ 1920 o - S 18 24 0 -
+-R \ 1940 o - Jun 14 24 1 S
+-R \ 1942 o - N 2 2s 0 -
+-R \ 1943 o - Mar 29 2s 1 S
+-R \ 1943 o - O 4 2s 0 -
+-R \ 1944 o - Ap 2 2s 1 S
+-R \ 1944 o - S 17 2s 0 -
+-R \ 1945 o - Ap 2 2 1 S
+-R \ 1945 o - S 15 1 0 -
+-R \ 1946 o - Mar 17 2s 1 S
+-R \ 1946 o - O 6 2s 0 -
+-R \ 1947 o - Mar 16 0s 1 S
+-R \ 1947 o - O 5 0s 0 -
+-R \ 1948 o - F 29 2s 1 S
+-R \ 1948 o - O 3 2s 0 -
+-R \ 1966 1968 - May Sun>=22 0s 1 S
+-R \ 1966 o - S 24 24 0 -
+-R \ 1967 1969 - S Sun>=22 0s 0 -
+-R \ 1969 o - Jun 1 0s 1 S
+-R \ 1970 o - May 31 0s 1 S
+-R \ 1970 o - S lastSun 0s 0 -
+-R \ 1971 1972 - May Sun>=22 0s 1 S
+-R \ 1971 o - S lastSun 0s 0 -
+-R \ 1972 o - O 1 0s 0 -
+-R \ 1973 o - Jun 3 0s 1 S
+-R \ 1973 1974 - S lastSun 0s 0 -
+-R \ 1974 o - May 26 0s 1 S
+-R \ 1975 o - Jun 1 0s 1 S
+-R \ 1975 1977 - S lastSun 0s 0 -
+-R \ 1976 o - May 30 0s 1 S
+-R \ 1977 1979 - May Sun>=22 0s 1 S
+-R \ 1978 o - O 1 0s 0 -
+-R \ 1979 o - S 30 0s 0 -
++R I 1916 o - Jun 3 24 1 S
++R I 1916 1917 - S 30 24 0 -
++R I 1917 o - Mar 31 24 1 S
++R I 1918 o - Mar 9 24 1 S
++R I 1918 o - O 6 24 0 -
++R I 1919 o - Mar 1 24 1 S
++R I 1919 o - O 4 24 0 -
++R I 1920 o - Mar 20 24 1 S
++R I 1920 o - S 18 24 0 -
++R I 1940 o - Jun 14 24 1 S
++R I 1942 o - N 2 2s 0 -
++R I 1943 o - Mar 29 2s 1 S
++R I 1943 o - O 4 2s 0 -
++R I 1944 o - Ap 2 2s 1 S
++R I 1944 o - S 17 2s 0 -
++R I 1945 o - Ap 2 2 1 S
++R I 1945 o - S 15 1 0 -
++R I 1946 o - Mar 17 2s 1 S
++R I 1946 o - O 6 2s 0 -
++R I 1947 o - Mar 16 0s 1 S
++R I 1947 o - O 5 0s 0 -
++R I 1948 o - F 29 2s 1 S
++R I 1948 o - O 3 2s 0 -
++R I 1966 1968 - May Sun>=22 0s 1 S
++R I 1966 o - S 24 24 0 -
++R I 1967 1969 - S Sun>=22 0s 0 -
++R I 1969 o - Jun 1 0s 1 S
++R I 1970 o - May 31 0s 1 S
++R I 1970 o - S lastSun 0s 0 -
++R I 1971 1972 - May Sun>=22 0s 1 S
++R I 1971 o - S lastSun 0s 0 -
++R I 1972 o - O 1 0s 0 -
++R I 1973 o - Jun 3 0s 1 S
++R I 1973 1974 - S lastSun 0s 0 -
++R I 1974 o - May 26 0s 1 S
++R I 1975 o - Jun 1 0s 1 S
++R I 1975 1977 - S lastSun 0s 0 -
++R I 1976 o - May 30 0s 1 S
++R I 1977 1979 - May Sun>=22 0s 1 S
++R I 1978 o - O 1 0s 0 -
++R I 1979 o - S 30 0s 0 -
+ Z Europe/Rome 0:49:56 - LMT 1866 S 22
+ 0:49:56 - RMT 1893 O 31 23:49:56
+-1 \ CE%sT 1943 S 10
+-1 ( CE%sT 1944 Jun 4
+-1 \ CE%sT 1980
+-1 O CE%sT
++1 I CE%sT 1943 S 10
++1 c CE%sT 1944 Jun 4
++1 I CE%sT 1980
++1 E CE%sT
+ Li Europe/Rome Europe/Vatican
+ Li Europe/Rome Europe/San_Marino
+-R ] 1989 1996 - Mar lastSun 2s 1 S
+-R ] 1989 1996 - S lastSun 2s 0 -
++R LV 1989 1996 - Mar lastSun 2s 1 S
++R LV 1989 1996 - S lastSun 2s 0 -
+ Z Europe/Riga 1:36:34 - LMT 1880
+ 1:36:34 - RMT 1918 Ap 15 2
+ 1:36:34 1 LST 1918 S 16 3
+@@ -1883,13 +1907,13 @@ Z Europe/Riga 1:36:34 - LMT 1880
+ 1:36:34 - RMT 1926 May 11
+ 2 - EET 1940 Au 5
+ 3 - MSK 1941 Jul
+-1 ( CE%sT 1944 O 13
+-3 M MSK/MSD 1989 Mar lastSun 2s
++1 c CE%sT 1944 O 13
++3 R MSK/MSD 1989 Mar lastSun 2s
+ 2 1 EEST 1989 S lastSun 2s
+-2 ] EE%sT 1997 Ja 21
+-2 O EE%sT 2000 F 29
++2 LV EE%sT 1997 Ja 21
++2 E EE%sT 2000 F 29
+ 2 - EET 2001 Ja 2
+-2 O EE%sT
++2 E EE%sT
+ Li Europe/Zurich Europe/Vaduz
+ Z Europe/Vilnius 1:41:16 - LMT 1880
+ 1:24 - WMT 1917
+@@ -1898,783 +1922,776 @@ Z Europe/Vilnius 1:41:16 - LMT 1880
+ 2 - EET 1920 O 9
+ 1 - CET 1940 Au 3
+ 3 - MSK 1941 Jun 24
+-1 ( CE%sT 1944 Au
+-3 M MSK/MSD 1989 Mar 26 2s
+-2 M EE%sT 1991 S 29 2s
+-2 ( EE%sT 1998
++1 c CE%sT 1944 Au
++3 R MSK/MSD 1989 Mar 26 2s
++2 R EE%sT 1991 S 29 2s
++2 c EE%sT 1998
+ 2 - EET 1998 Mar 29 1u
+-1 O CE%sT 1999 O 31 1u
++1 E CE%sT 1999 O 31 1u
+ 2 - EET 2003
+-2 O EE%sT
+-R ^ 1916 o - May 14 23 1 S
+-R ^ 1916 o - O 1 1 0 -
+-R ^ 1917 o - Ap 28 23 1 S
+-R ^ 1917 o - S 17 1 0 -
+-R ^ 1918 o - Ap M>=15 2s 1 S
+-R ^ 1918 o - S M>=15 2s 0 -
+-R ^ 1919 o - Mar 1 23 1 S
+-R ^ 1919 o - O 5 3 0 -
+-R ^ 1920 o - F 14 23 1 S
+-R ^ 1920 o - O 24 2 0 -
+-R ^ 1921 o - Mar 14 23 1 S
+-R ^ 1921 o - O 26 2 0 -
+-R ^ 1922 o - Mar 25 23 1 S
+-R ^ 1922 o - O Sun>=2 1 0 -
+-R ^ 1923 o - Ap 21 23 1 S
+-R ^ 1923 o - O Sun>=2 2 0 -
+-R ^ 1924 o - Mar 29 23 1 S
+-R ^ 1924 1928 - O Sun>=2 1 0 -
+-R ^ 1925 o - Ap 5 23 1 S
+-R ^ 1926 o - Ap 17 23 1 S
+-R ^ 1927 o - Ap 9 23 1 S
+-R ^ 1928 o - Ap 14 23 1 S
+-R ^ 1929 o - Ap 20 23 1 S
++2 E EE%sT
++R LX 1916 o - May 14 23 1 S
++R LX 1916 o - O 1 1 0 -
++R LX 1917 o - Ap 28 23 1 S
++R LX 1917 o - S 17 1 0 -
++R LX 1918 o - Ap M>=15 2s 1 S
++R LX 1918 o - S M>=15 2s 0 -
++R LX 1919 o - Mar 1 23 1 S
++R LX 1919 o - O 5 3 0 -
++R LX 1920 o - F 14 23 1 S
++R LX 1920 o - O 24 2 0 -
++R LX 1921 o - Mar 14 23 1 S
++R LX 1921 o - O 26 2 0 -
++R LX 1922 o - Mar 25 23 1 S
++R LX 1922 o - O Sun>=2 1 0 -
++R LX 1923 o - Ap 21 23 1 S
++R LX 1923 o - O Sun>=2 2 0 -
++R LX 1924 o - Mar 29 23 1 S
++R LX 1924 1928 - O Sun>=2 1 0 -
++R LX 1925 o - Ap 5 23 1 S
++R LX 1926 o - Ap 17 23 1 S
++R LX 1927 o - Ap 9 23 1 S
++R LX 1928 o - Ap 14 23 1 S
++R LX 1929 o - Ap 20 23 1 S
+ Z Europe/Luxembourg 0:24:36 - LMT 1904 Jun
+-1 ^ CE%sT 1918 N 25
+-0 ^ WE%sT 1929 O 6 2s
+-0 + WE%sT 1940 May 14 3
+-1 ( WE%sT 1944 S 18 3
+-1 + CE%sT 1977
+-1 O CE%sT
+-R _ 1973 o - Mar 31 0s 1 S
+-R _ 1973 o - S 29 0s 0 -
+-R _ 1974 o - Ap 21 0s 1 S
+-R _ 1974 o - S 16 0s 0 -
+-R _ 1975 1979 - Ap Sun>=15 2 1 S
+-R _ 1975 1980 - S Sun>=15 2 0 -
+-R _ 1980 o - Mar 31 2 1 S
++1 LX CE%sT 1918 N 25
++0 LX WE%sT 1929 O 6 2s
++0 b WE%sT 1940 May 14 3
++1 c WE%sT 1944 S 18 3
++1 b CE%sT 1977
++1 E CE%sT
++R MT 1973 o - Mar 31 0s 1 S
++R MT 1973 o - S 29 0s 0 -
++R MT 1974 o - Ap 21 0s 1 S
++R MT 1974 o - S 16 0s 0 -
++R MT 1975 1979 - Ap Sun>=15 2 1 S
++R MT 1975 1980 - S Sun>=15 2 0 -
++R MT 1980 o - Mar 31 2 1 S
+ Z Europe/Malta 0:58:4 - LMT 1893 N 2 0s
+-1 \ CE%sT 1973 Mar 31
+-1 _ CE%sT 1981
+-1 O CE%sT
+-R ` 1997 ma - Mar lastSun 2 1 S
+-R ` 1997 ma - O lastSun 3 0 -
++1 I CE%sT 1973 Mar 31
++1 MT CE%sT 1981
++1 E CE%sT
++R MD 1997 ma - Mar lastSun 2 1 S
++R MD 1997 ma - O lastSun 3 0 -
+ Z Europe/Chisinau 1:55:20 - LMT 1880
+ 1:55 - CMT 1918 F 15
+ 1:44:24 - BMT 1931 Jul 24
+-2 { EE%sT 1940 Au 15
++2 z EE%sT 1940 Au 15
+ 2 1 EEST 1941 Jul 17
+-1 ( CE%sT 1944 Au 24
+-3 M MSK/MSD 1990 May 6 2
+-2 M EE%sT 1992
+-2 W EE%sT 1997
+-2 ` EE%sT
++1 c CE%sT 1944 Au 24
++3 R MSK/MSD 1990 May 6 2
++2 R EE%sT 1992
++2 e EE%sT 1997
++2 MD EE%sT
+ Z Europe/Monaco 0:29:32 - LMT 1891 Mar 15
+ 0:9:21 - PMT 1911 Mar 11
+-0 < WE%sT 1945 S 16 3
+-1 < CE%sT 1977
+-1 O CE%sT
+-R | 1916 o - May 1 0 1 NST
+-R | 1916 o - O 1 0 0 AMT
+-R | 1917 o - Ap 16 2s 1 NST
+-R | 1917 o - S 17 2s 0 AMT
+-R | 1918 1921 - Ap M>=1 2s 1 NST
+-R | 1918 1921 - S lastM 2s 0 AMT
+-R | 1922 o - Mar lastSun 2s 1 NST
+-R | 1922 1936 - O Sun>=2 2s 0 AMT
+-R | 1923 o - Jun F>=1 2s 1 NST
+-R | 1924 o - Mar lastSun 2s 1 NST
+-R | 1925 o - Jun F>=1 2s 1 NST
+-R | 1926 1931 - May 15 2s 1 NST
+-R | 1932 o - May 22 2s 1 NST
+-R | 1933 1936 - May 15 2s 1 NST
+-R | 1937 o - May 22 2s 1 NST
+-R | 1937 o - Jul 1 0 1 S
+-R | 1937 1939 - O Sun>=2 2s 0 -
+-R | 1938 1939 - May 15 2s 1 S
+-R | 1945 o - Ap 2 2s 1 S
+-R | 1945 o - S 16 2s 0 -
++0 F WE%sT 1945 S 16 3
++1 F CE%sT 1977
++1 E CE%sT
++R N 1916 o - May 1 0 1 NST
++R N 1916 o - O 1 0 0 AMT
++R N 1917 o - Ap 16 2s 1 NST
++R N 1917 o - S 17 2s 0 AMT
++R N 1918 1921 - Ap M>=1 2s 1 NST
++R N 1918 1921 - S lastM 2s 0 AMT
++R N 1922 o - Mar lastSun 2s 1 NST
++R N 1922 1936 - O Sun>=2 2s 0 AMT
++R N 1923 o - Jun F>=1 2s 1 NST
++R N 1924 o - Mar lastSun 2s 1 NST
++R N 1925 o - Jun F>=1 2s 1 NST
++R N 1926 1931 - May 15 2s 1 NST
++R N 1932 o - May 22 2s 1 NST
++R N 1933 1936 - May 15 2s 1 NST
++R N 1937 o - May 22 2s 1 NST
++R N 1937 o - Jul 1 0 1 S
++R N 1937 1939 - O Sun>=2 2s 0 -
++R N 1938 1939 - May 15 2s 1 S
++R N 1945 o - Ap 2 2s 1 S
++R N 1945 o - S 16 2s 0 -
+ Z Europe/Amsterdam 0:19:32 - LMT 1835
+-0:19:32 | %s 1937 Jul
+-0:20 | +0020/+0120 1940 May 16
+-1 ( CE%sT 1945 Ap 2 2
+-1 | CE%sT 1977
+-1 O CE%sT
+-R } 1916 o - May 22 1 1 S
+-R } 1916 o - S 30 0 0 -
+-R } 1945 o - Ap 2 2s 1 S
+-R } 1945 o - O 1 2s 0 -
+-R } 1959 1964 - Mar Sun>=15 2s 1 S
+-R } 1959 1965 - S Sun>=15 2s 0 -
+-R } 1965 o - Ap 25 2s 1 S
++0:19:32 N %s 1937 Jul
++0:20 N +0020/+0120 1940 May 16
++1 c CE%sT 1945 Ap 2 2
++1 N CE%sT 1977
++1 E CE%sT
++R NO 1916 o - May 22 1 1 S
++R NO 1916 o - S 30 0 0 -
++R NO 1945 o - Ap 2 2s 1 S
++R NO 1945 o - O 1 2s 0 -
++R NO 1959 1964 - Mar Sun>=15 2s 1 S
++R NO 1959 1965 - S Sun>=15 2s 0 -
++R NO 1965 o - Ap 25 2s 1 S
+ Z Europe/Oslo 0:43 - LMT 1895
+-1 } CE%sT 1940 Au 10 23
+-1 ( CE%sT 1945 Ap 2 2
+-1 } CE%sT 1980
+-1 O CE%sT
++1 NO CE%sT 1940 Au 10 23
++1 c CE%sT 1945 Ap 2 2
++1 NO CE%sT 1980
++1 E CE%sT
+ Li Europe/Oslo Arctic/Longyearbyen
+-R ~ 1918 1919 - S 16 2s 0 -
+-R ~ 1919 o - Ap 15 2s 1 S
+-R ~ 1944 o - Ap 3 2s 1 S
+-R ~ 1944 o - O 4 2 0 -
+-R ~ 1945 o - Ap 29 0 1 S
+-R ~ 1945 o - N 1 0 0 -
+-R ~ 1946 o - Ap 14 0s 1 S
+-R ~ 1946 o - O 7 2s 0 -
+-R ~ 1947 o - May 4 2s 1 S
+-R ~ 1947 1949 - O Sun>=1 2s 0 -
+-R ~ 1948 o - Ap 18 2s 1 S
+-R ~ 1949 o - Ap 10 2s 1 S
+-R ~ 1957 o - Jun 2 1s 1 S
+-R ~ 1957 1958 - S lastSun 1s 0 -
+-R ~ 1958 o - Mar 30 1s 1 S
+-R ~ 1959 o - May 31 1s 1 S
+-R ~ 1959 1961 - O Sun>=1 1s 0 -
+-R ~ 1960 o - Ap 3 1s 1 S
+-R ~ 1961 1964 - May lastSun 1s 1 S
+-R ~ 1962 1964 - S lastSun 1s 0 -
++R O 1918 1919 - S 16 2s 0 -
++R O 1919 o - Ap 15 2s 1 S
++R O 1944 o - Ap 3 2s 1 S
++R O 1944 o - O 4 2 0 -
++R O 1945 o - Ap 29 0 1 S
++R O 1945 o - N 1 0 0 -
++R O 1946 o - Ap 14 0s 1 S
++R O 1946 o - O 7 2s 0 -
++R O 1947 o - May 4 2s 1 S
++R O 1947 1949 - O Sun>=1 2s 0 -
++R O 1948 o - Ap 18 2s 1 S
++R O 1949 o - Ap 10 2s 1 S
++R O 1957 o - Jun 2 1s 1 S
++R O 1957 1958 - S lastSun 1s 0 -
++R O 1958 o - Mar 30 1s 1 S
++R O 1959 o - May 31 1s 1 S
++R O 1959 1961 - O Sun>=1 1s 0 -
++R O 1960 o - Ap 3 1s 1 S
++R O 1961 1964 - May lastSun 1s 1 S
++R O 1962 1964 - S lastSun 1s 0 -
+ Z Europe/Warsaw 1:24 - LMT 1880
+ 1:24 - WMT 1915 Au 5
+-1 ( CE%sT 1918 S 16 3
+-2 ~ EE%sT 1922 Jun
+-1 ~ CE%sT 1940 Jun 23 2
+-1 ( CE%sT 1944 O
+-1 ~ CE%sT 1977
+-1 ' CE%sT 1988
+-1 O CE%sT
+-R AA 1916 o - Jun 17 23 1 S
+-R AA 1916 o - N 1 1 0 -
+-R AA 1917 o - F 28 23s 1 S
+-R AA 1917 1921 - O 14 23s 0 -
+-R AA 1918 o - Mar 1 23s 1 S
+-R AA 1919 o - F 28 23s 1 S
+-R AA 1920 o - F 29 23s 1 S
+-R AA 1921 o - F 28 23s 1 S
+-R AA 1924 o - Ap 16 23s 1 S
+-R AA 1924 o - O 14 23s 0 -
+-R AA 1926 o - Ap 17 23s 1 S
+-R AA 1926 1929 - O Sat>=1 23s 0 -
+-R AA 1927 o - Ap 9 23s 1 S
+-R AA 1928 o - Ap 14 23s 1 S
+-R AA 1929 o - Ap 20 23s 1 S
+-R AA 1931 o - Ap 18 23s 1 S
+-R AA 1931 1932 - O Sat>=1 23s 0 -
+-R AA 1932 o - Ap 2 23s 1 S
+-R AA 1934 o - Ap 7 23s 1 S
+-R AA 1934 1938 - O Sat>=1 23s 0 -
+-R AA 1935 o - Mar 30 23s 1 S
+-R AA 1936 o - Ap 18 23s 1 S
+-R AA 1937 o - Ap 3 23s 1 S
+-R AA 1938 o - Mar 26 23s 1 S
+-R AA 1939 o - Ap 15 23s 1 S
+-R AA 1939 o - N 18 23s 0 -
+-R AA 1940 o - F 24 23s 1 S
+-R AA 1940 1941 - O 5 23s 0 -
+-R AA 1941 o - Ap 5 23s 1 S
+-R AA 1942 1945 - Mar Sat>=8 23s 1 S
+-R AA 1942 o - Ap 25 22s 2 M
+-R AA 1942 o - Au 15 22s 1 S
+-R AA 1942 1945 - O Sat>=24 23s 0 -
+-R AA 1943 o - Ap 17 22s 2 M
+-R AA 1943 1945 - Au Sat>=25 22s 1 S
+-R AA 1944 1945 - Ap Sat>=21 22s 2 M
+-R AA 1946 o - Ap Sat>=1 23s 1 S
+-R AA 1946 o - O Sat>=1 23s 0 -
+-R AA 1947 1949 - Ap Sun>=1 2s 1 S
+-R AA 1947 1949 - O Sun>=1 2s 0 -
+-R AA 1951 1965 - Ap Sun>=1 2s 1 S
+-R AA 1951 1965 - O Sun>=1 2s 0 -
+-R AA 1977 o - Mar 27 0s 1 S
+-R AA 1977 o - S 25 0s 0 -
+-R AA 1978 1979 - Ap Sun>=1 0s 1 S
+-R AA 1978 o - O 1 0s 0 -
+-R AA 1979 1982 - S lastSun 1s 0 -
+-R AA 1980 o - Mar lastSun 0s 1 S
+-R AA 1981 1982 - Mar lastSun 1s 1 S
+-R AA 1983 o - Mar lastSun 2s 1 S
++1 c CE%sT 1918 S 16 3
++2 O EE%sT 1922 Jun
++1 O CE%sT 1940 Jun 23 2
++1 c CE%sT 1944 O
++1 O CE%sT 1977
++1 W- CE%sT 1988
++1 E CE%sT
++R p 1916 o - Jun 17 23 1 S
++R p 1916 o - N 1 1 0 -
++R p 1917 o - F 28 23s 1 S
++R p 1917 1921 - O 14 23s 0 -
++R p 1918 o - Mar 1 23s 1 S
++R p 1919 o - F 28 23s 1 S
++R p 1920 o - F 29 23s 1 S
++R p 1921 o - F 28 23s 1 S
++R p 1924 o - Ap 16 23s 1 S
++R p 1924 o - O 14 23s 0 -
++R p 1926 o - Ap 17 23s 1 S
++R p 1926 1929 - O Sat>=1 23s 0 -
++R p 1927 o - Ap 9 23s 1 S
++R p 1928 o - Ap 14 23s 1 S
++R p 1929 o - Ap 20 23s 1 S
++R p 1931 o - Ap 18 23s 1 S
++R p 1931 1932 - O Sat>=1 23s 0 -
++R p 1932 o - Ap 2 23s 1 S
++R p 1934 o - Ap 7 23s 1 S
++R p 1934 1938 - O Sat>=1 23s 0 -
++R p 1935 o - Mar 30 23s 1 S
++R p 1936 o - Ap 18 23s 1 S
++R p 1937 o - Ap 3 23s 1 S
++R p 1938 o - Mar 26 23s 1 S
++R p 1939 o - Ap 15 23s 1 S
++R p 1939 o - N 18 23s 0 -
++R p 1940 o - F 24 23s 1 S
++R p 1940 1941 - O 5 23s 0 -
++R p 1941 o - Ap 5 23s 1 S
++R p 1942 1945 - Mar Sat>=8 23s 1 S
++R p 1942 o - Ap 25 22s 2 M
++R p 1942 o - Au 15 22s 1 S
++R p 1942 1945 - O Sat>=24 23s 0 -
++R p 1943 o - Ap 17 22s 2 M
++R p 1943 1945 - Au Sat>=25 22s 1 S
++R p 1944 1945 - Ap Sat>=21 22s 2 M
++R p 1946 o - Ap Sat>=1 23s 1 S
++R p 1946 o - O Sat>=1 23s 0 -
++R p 1947 1949 - Ap Sun>=1 2s 1 S
++R p 1947 1949 - O Sun>=1 2s 0 -
++R p 1951 1965 - Ap Sun>=1 2s 1 S
++R p 1951 1965 - O Sun>=1 2s 0 -
++R p 1977 o - Mar 27 0s 1 S
++R p 1977 o - S 25 0s 0 -
++R p 1978 1979 - Ap Sun>=1 0s 1 S
++R p 1978 o - O 1 0s 0 -
++R p 1979 1982 - S lastSun 1s 0 -
++R p 1980 o - Mar lastSun 0s 1 S
++R p 1981 1982 - Mar lastSun 1s 1 S
++R p 1983 o - Mar lastSun 2s 1 S
+ Z Europe/Lisbon -0:36:45 - LMT 1884
+ -0:36:45 - LMT 1912 Ja 1 0u
+-0 AA WE%sT 1966 Ap 3 2
++0 p WE%sT 1966 Ap 3 2
+ 1 - CET 1976 S 26 1
+-0 AA WE%sT 1983 S 25 1s
+-0 ' WE%sT 1992 S 27 1s
+-1 O CE%sT 1996 Mar 31 1u
+-0 O WE%sT
++0 p WE%sT 1983 S 25 1s
++0 W- WE%sT 1992 S 27 1s
++1 E CE%sT 1996 Mar 31 1u
++0 E WE%sT
+ Z Atlantic/Azores -1:42:40 - LMT 1884
+ -1:54:32 - HMT 1912 Ja 1 2u
+--2 AA -02/-01 1942 Ap 25 22s
+--2 AA +00 1942 Au 15 22s
+--2 AA -02/-01 1943 Ap 17 22s
+--2 AA +00 1943 Au 28 22s
+--2 AA -02/-01 1944 Ap 22 22s
+--2 AA +00 1944 Au 26 22s
+--2 AA -02/-01 1945 Ap 21 22s
+--2 AA +00 1945 Au 25 22s
+--2 AA -02/-01 1966 Ap 3 2
+--1 AA -01/+00 1983 S 25 1s
+--1 ' -01/+00 1992 S 27 1s
+-0 O WE%sT 1993 Mar 28 1u
+--1 O -01/+00
++-2 p -02/-01 1942 Ap 25 22s
++-2 p +00 1942 Au 15 22s
++-2 p -02/-01 1943 Ap 17 22s
++-2 p +00 1943 Au 28 22s
++-2 p -02/-01 1944 Ap 22 22s
++-2 p +00 1944 Au 26 22s
++-2 p -02/-01 1945 Ap 21 22s
++-2 p +00 1945 Au 25 22s
++-2 p -02/-01 1966 Ap 3 2
++-1 p -01/+00 1983 S 25 1s
++-1 W- -01/+00 1992 S 27 1s
++0 E WE%sT 1993 Mar 28 1u
++-1 E -01/+00
+ Z Atlantic/Madeira -1:7:36 - LMT 1884
+ -1:7:36 - FMT 1912 Ja 1 1u
+--1 AA -01/+00 1942 Ap 25 22s
+--1 AA +01 1942 Au 15 22s
+--1 AA -01/+00 1943 Ap 17 22s
+--1 AA +01 1943 Au 28 22s
+--1 AA -01/+00 1944 Ap 22 22s
+--1 AA +01 1944 Au 26 22s
+--1 AA -01/+00 1945 Ap 21 22s
+--1 AA +01 1945 Au 25 22s
+--1 AA -01/+00 1966 Ap 3 2
+-0 AA WE%sT 1983 S 25 1s
+-0 O WE%sT
+-R { 1932 o - May 21 0s 1 S
+-R { 1932 1939 - O Sun>=1 0s 0 -
+-R { 1933 1939 - Ap Sun>=2 0s 1 S
+-R { 1979 o - May 27 0 1 S
+-R { 1979 o - S lastSun 0 0 -
+-R { 1980 o - Ap 5 23 1 S
+-R { 1980 o - S lastSun 1 0 -
+-R { 1991 1993 - Mar lastSun 0s 1 S
+-R { 1991 1993 - S lastSun 0s 0 -
++-1 p -01/+00 1942 Ap 25 22s
++-1 p +01 1942 Au 15 22s
++-1 p -01/+00 1943 Ap 17 22s
++-1 p +01 1943 Au 28 22s
++-1 p -01/+00 1944 Ap 22 22s
++-1 p +01 1944 Au 26 22s
++-1 p -01/+00 1945 Ap 21 22s
++-1 p +01 1945 Au 25 22s
++-1 p -01/+00 1966 Ap 3 2
++0 p WE%sT 1983 S 25 1s
++0 E WE%sT
++R z 1932 o - May 21 0s 1 S
++R z 1932 1939 - O Sun>=1 0s 0 -
++R z 1933 1939 - Ap Sun>=2 0s 1 S
++R z 1979 o - May 27 0 1 S
++R z 1979 o - S lastSun 0 0 -
++R z 1980 o - Ap 5 23 1 S
++R z 1980 o - S lastSun 1 0 -
++R z 1991 1993 - Mar lastSun 0s 1 S
++R z 1991 1993 - S lastSun 0s 0 -
+ Z Europe/Bucharest 1:44:24 - LMT 1891 O
+ 1:44:24 - BMT 1931 Jul 24
+-2 { EE%sT 1981 Mar 29 2s
+-2 ( EE%sT 1991
+-2 { EE%sT 1994
+-2 W EE%sT 1997
+-2 O EE%sT
++2 z EE%sT 1981 Mar 29 2s
++2 c EE%sT 1991
++2 z EE%sT 1994
++2 e EE%sT 1997
++2 E EE%sT
+ Z Europe/Kaliningrad 1:22 - LMT 1893 Ap
+-1 ( CE%sT 1945
+-2 ~ CE%sT 1946
+-3 M MSK/MSD 1989 Mar 26 2s
+-2 M EE%sT 2011 Mar 27 2s
++1 c CE%sT 1945
++2 O CE%sT 1946
++3 R MSK/MSD 1989 Mar 26 2s
++2 R EE%sT 2011 Mar 27 2s
+ 3 - +03 2014 O 26 2s
+ 2 - EET
+ Z Europe/Moscow 2:30:17 - LMT 1880
+ 2:30:17 - MMT 1916 Jul 3
+-2:31:19 M %s 1919 Jul 1 0u
+-3 M %s 1921 O
+-3 M MSK/MSD 1922 O
++2:31:19 R %s 1919 Jul 1 0u
++3 R %s 1921 O
++3 R MSK/MSD 1922 O
+ 2 - EET 1930 Jun 21
+-3 M MSK/MSD 1991 Mar 31 2s
+-2 M EE%sT 1992 Ja 19 2s
+-3 M MSK/MSD 2011 Mar 27 2s
++3 R MSK/MSD 1991 Mar 31 2s
++2 R EE%sT 1992 Ja 19 2s
++3 R MSK/MSD 2011 Mar 27 2s
+ 4 - MSK 2014 O 26 2s
+ 3 - MSK
+ Z Europe/Simferopol 2:16:24 - LMT 1880
+ 2:16 - SMT 1924 May 2
+ 2 - EET 1930 Jun 21
+ 3 - MSK 1941 N
+-1 ( CE%sT 1944 Ap 13
+-3 M MSK/MSD 1990
++1 c CE%sT 1944 Ap 13
++3 R MSK/MSD 1990
+ 3 - MSK 1990 Jul 1 2
+ 2 - EET 1992
+-2 W EE%sT 1994 May
+-3 W MSK/MSD 1996 Mar 31 0s
++2 e EE%sT 1994 May
++3 e MSK/MSD 1996 Mar 31 0s
+ 3 1 MSD 1996 O 27 3s
+-3 M MSK/MSD 1997
++3 R MSK/MSD 1997
+ 3 - MSK 1997 Mar lastSun 1u
+-2 O EE%sT 2014 Mar 30 2
++2 E EE%sT 2014 Mar 30 2
+ 4 - MSK 2014 O 26 2s
+ 3 - MSK
+ Z Europe/Astrakhan 3:12:12 - LMT 1924 May
+ 3 - +03 1930 Jun 21
+-4 M +04/+05 1989 Mar 26 2s
+-3 M +03/+04 1991 Mar 31 2s
++4 R +04/+05 1989 Mar 26 2s
++3 R +03/+04 1991 Mar 31 2s
+ 4 - +04 1992 Mar 29 2s
+-3 M +03/+04 2011 Mar 27 2s
++3 R +03/+04 2011 Mar 27 2s
+ 4 - +04 2014 O 26 2s
+ 3 - +03 2016 Mar 27 2s
+ 4 - +04
+ Z Europe/Volgograd 2:57:40 - LMT 1920 Ja 3
+ 3 - +03 1930 Jun 21
+ 4 - +04 1961 N 11
+-4 M +04/+05 1988 Mar 27 2s
+-3 M +03/+04 1991 Mar 31 2s
++4 R +04/+05 1988 Mar 27 2s
++3 R +03/+04 1991 Mar 31 2s
+ 4 - +04 1992 Mar 29 2s
+-3 M +03/+04 2011 Mar 27 2s
++3 R +03/+04 2011 Mar 27 2s
+ 4 - +04 2014 O 26 2s
+-3 - +03
++3 - +03 2018 O 28 2s
++4 - +04
+ Z Europe/Saratov 3:4:18 - LMT 1919 Jul 1 0u
+ 3 - +03 1930 Jun 21
+-4 M +04/+05 1988 Mar 27 2s
+-3 M +03/+04 1991 Mar 31 2s
++4 R +04/+05 1988 Mar 27 2s
++3 R +03/+04 1991 Mar 31 2s
+ 4 - +04 1992 Mar 29 2s
+-3 M +03/+04 2011 Mar 27 2s
++3 R +03/+04 2011 Mar 27 2s
+ 4 - +04 2014 O 26 2s
+ 3 - +03 2016 D 4 2s
+ 4 - +04
+ Z Europe/Kirov 3:18:48 - LMT 1919 Jul 1 0u
+ 3 - +03 1930 Jun 21
+-4 M +04/+05 1989 Mar 26 2s
+-3 M +03/+04 1991 Mar 31 2s
++4 R +04/+05 1989 Mar 26 2s
++3 R +03/+04 1991 Mar 31 2s
+ 4 - +04 1992 Mar 29 2s
+-3 M +03/+04 2011 Mar 27 2s
++3 R +03/+04 2011 Mar 27 2s
+ 4 - +04 2014 O 26 2s
+ 3 - +03
+ Z Europe/Samara 3:20:20 - LMT 1919 Jul 1 0u
+ 3 - +03 1930 Jun 21
+ 4 - +04 1935 Ja 27
+-4 M +04/+05 1989 Mar 26 2s
+-3 M +03/+04 1991 Mar 31 2s
+-2 M +02/+03 1991 S 29 2s
++4 R +04/+05 1989 Mar 26 2s
++3 R +03/+04 1991 Mar 31 2s
++2 R +02/+03 1991 S 29 2s
+ 3 - +03 1991 O 20 3
+-4 M +04/+05 2010 Mar 28 2s
+-3 M +03/+04 2011 Mar 27 2s
++4 R +04/+05 2010 Mar 28 2s
++3 R +03/+04 2011 Mar 27 2s
+ 4 - +04
+ Z Europe/Ulyanovsk 3:13:36 - LMT 1919 Jul 1 0u
+ 3 - +03 1930 Jun 21
+-4 M +04/+05 1989 Mar 26 2s
+-3 M +03/+04 1991 Mar 31 2s
+-2 M +02/+03 1992 Ja 19 2s
+-3 M +03/+04 2011 Mar 27 2s
++4 R +04/+05 1989 Mar 26 2s
++3 R +03/+04 1991 Mar 31 2s
++2 R +02/+03 1992 Ja 19 2s
++3 R +03/+04 2011 Mar 27 2s
+ 4 - +04 2014 O 26 2s
+ 3 - +03 2016 Mar 27 2s
+ 4 - +04
+ Z Asia/Yekaterinburg 4:2:33 - LMT 1916 Jul 3
+ 3:45:5 - PMT 1919 Jul 15 4
+ 4 - +04 1930 Jun 21
+-5 M +05/+06 1991 Mar 31 2s
+-4 M +04/+05 1992 Ja 19 2s
+-5 M +05/+06 2011 Mar 27 2s
++5 R +05/+06 1991 Mar 31 2s
++4 R +04/+05 1992 Ja 19 2s
++5 R +05/+06 2011 Mar 27 2s
+ 6 - +06 2014 O 26 2s
+ 5 - +05
+ Z Asia/Omsk 4:53:30 - LMT 1919 N 14
+ 5 - +05 1930 Jun 21
+-6 M +06/+07 1991 Mar 31 2s
+-5 M +05/+06 1992 Ja 19 2s
+-6 M +06/+07 2011 Mar 27 2s
++6 R +06/+07 1991 Mar 31 2s
++5 R +05/+06 1992 Ja 19 2s
++6 R +06/+07 2011 Mar 27 2s
+ 7 - +07 2014 O 26 2s
+ 6 - +06
+ Z Asia/Barnaul 5:35 - LMT 1919 D 10
+ 6 - +06 1930 Jun 21
+-7 M +07/+08 1991 Mar 31 2s
+-6 M +06/+07 1992 Ja 19 2s
+-7 M +07/+08 1995 May 28
+-6 M +06/+07 2011 Mar 27 2s
++7 R +07/+08 1991 Mar 31 2s
++6 R +06/+07 1992 Ja 19 2s
++7 R +07/+08 1995 May 28
++6 R +06/+07 2011 Mar 27 2s
+ 7 - +07 2014 O 26 2s
+ 6 - +06 2016 Mar 27 2s
+ 7 - +07
+ Z Asia/Novosibirsk 5:31:40 - LMT 1919 D 14 6
+ 6 - +06 1930 Jun 21
+-7 M +07/+08 1991 Mar 31 2s
+-6 M +06/+07 1992 Ja 19 2s
+-7 M +07/+08 1993 May 23
+-6 M +06/+07 2011 Mar 27 2s
++7 R +07/+08 1991 Mar 31 2s
++6 R +06/+07 1992 Ja 19 2s
++7 R +07/+08 1993 May 23
++6 R +06/+07 2011 Mar 27 2s
+ 7 - +07 2014 O 26 2s
+ 6 - +06 2016 Jul 24 2s
+ 7 - +07
+ Z Asia/Tomsk 5:39:51 - LMT 1919 D 22
+ 6 - +06 1930 Jun 21
+-7 M +07/+08 1991 Mar 31 2s
+-6 M +06/+07 1992 Ja 19 2s
+-7 M +07/+08 2002 May 1 3
+-6 M +06/+07 2011 Mar 27 2s
++7 R +07/+08 1991 Mar 31 2s
++6 R +06/+07 1992 Ja 19 2s
++7 R +07/+08 2002 May 1 3
++6 R +06/+07 2011 Mar 27 2s
+ 7 - +07 2014 O 26 2s
+ 6 - +06 2016 May 29 2s
+ 7 - +07
+ Z Asia/Novokuznetsk 5:48:48 - LMT 1924 May
+ 6 - +06 1930 Jun 21
+-7 M +07/+08 1991 Mar 31 2s
+-6 M +06/+07 1992 Ja 19 2s
+-7 M +07/+08 2010 Mar 28 2s
+-6 M +06/+07 2011 Mar 27 2s
++7 R +07/+08 1991 Mar 31 2s
++6 R +06/+07 1992 Ja 19 2s
++7 R +07/+08 2010 Mar 28 2s
++6 R +06/+07 2011 Mar 27 2s
+ 7 - +07
+ Z Asia/Krasnoyarsk 6:11:26 - LMT 1920 Ja 6
+ 6 - +06 1930 Jun 21
+-7 M +07/+08 1991 Mar 31 2s
+-6 M +06/+07 1992 Ja 19 2s
+-7 M +07/+08 2011 Mar 27 2s
++7 R +07/+08 1991 Mar 31 2s
++6 R +06/+07 1992 Ja 19 2s
++7 R +07/+08 2011 Mar 27 2s
+ 8 - +08 2014 O 26 2s
+ 7 - +07
+ Z Asia/Irkutsk 6:57:5 - LMT 1880
+ 6:57:5 - IMT 1920 Ja 25
+ 7 - +07 1930 Jun 21
+-8 M +08/+09 1991 Mar 31 2s
+-7 M +07/+08 1992 Ja 19 2s
+-8 M +08/+09 2011 Mar 27 2s
++8 R +08/+09 1991 Mar 31 2s
++7 R +07/+08 1992 Ja 19 2s
++8 R +08/+09 2011 Mar 27 2s
+ 9 - +09 2014 O 26 2s
+ 8 - +08
+ Z Asia/Chita 7:33:52 - LMT 1919 D 15
+ 8 - +08 1930 Jun 21
+-9 M +09/+10 1991 Mar 31 2s
+-8 M +08/+09 1992 Ja 19 2s
+-9 M +09/+10 2011 Mar 27 2s
++9 R +09/+10 1991 Mar 31 2s
++8 R +08/+09 1992 Ja 19 2s
++9 R +09/+10 2011 Mar 27 2s
+ 10 - +10 2014 O 26 2s
+ 8 - +08 2016 Mar 27 2
+ 9 - +09
+ Z Asia/Yakutsk 8:38:58 - LMT 1919 D 15
+ 8 - +08 1930 Jun 21
+-9 M +09/+10 1991 Mar 31 2s
+-8 M +08/+09 1992 Ja 19 2s
+-9 M +09/+10 2011 Mar 27 2s
++9 R +09/+10 1991 Mar 31 2s
++8 R +08/+09 1992 Ja 19 2s
++9 R +09/+10 2011 Mar 27 2s
+ 10 - +10 2014 O 26 2s
+ 9 - +09
+ Z Asia/Vladivostok 8:47:31 - LMT 1922 N 15
+ 9 - +09 1930 Jun 21
+-10 M +10/+11 1991 Mar 31 2s
+-9 M +09/+10 1992 Ja 19 2s
+-10 M +10/+11 2011 Mar 27 2s
++10 R +10/+11 1991 Mar 31 2s
++9 R +09/+10 1992 Ja 19 2s
++10 R +10/+11 2011 Mar 27 2s
+ 11 - +11 2014 O 26 2s
+ 10 - +10
+ Z Asia/Khandyga 9:2:13 - LMT 1919 D 15
+ 8 - +08 1930 Jun 21
+-9 M +09/+10 1991 Mar 31 2s
+-8 M +08/+09 1992 Ja 19 2s
+-9 M +09/+10 2004
+-10 M +10/+11 2011 Mar 27 2s
++9 R +09/+10 1991 Mar 31 2s
++8 R +08/+09 1992 Ja 19 2s
++9 R +09/+10 2004
++10 R +10/+11 2011 Mar 27 2s
+ 11 - +11 2011 S 13 0s
+ 10 - +10 2014 O 26 2s
+ 9 - +09
+ Z Asia/Sakhalin 9:30:48 - LMT 1905 Au 23
+ 9 - +09 1945 Au 25
+-11 M +11/+12 1991 Mar 31 2s
+-10 M +10/+11 1992 Ja 19 2s
+-11 M +11/+12 1997 Mar lastSun 2s
+-10 M +10/+11 2011 Mar 27 2s
++11 R +11/+12 1991 Mar 31 2s
++10 R +10/+11 1992 Ja 19 2s
++11 R +11/+12 1997 Mar lastSun 2s
++10 R +10/+11 2011 Mar 27 2s
+ 11 - +11 2014 O 26 2s
+ 10 - +10 2016 Mar 27 2s
+ 11 - +11
+ Z Asia/Magadan 10:3:12 - LMT 1924 May 2
+ 10 - +10 1930 Jun 21
+-11 M +11/+12 1991 Mar 31 2s
+-10 M +10/+11 1992 Ja 19 2s
+-11 M +11/+12 2011 Mar 27 2s
++11 R +11/+12 1991 Mar 31 2s
++10 R +10/+11 1992 Ja 19 2s
++11 R +11/+12 2011 Mar 27 2s
+ 12 - +12 2014 O 26 2s
+ 10 - +10 2016 Ap 24 2s
+ 11 - +11
+ Z Asia/Srednekolymsk 10:14:52 - LMT 1924 May 2
+ 10 - +10 1930 Jun 21
+-11 M +11/+12 1991 Mar 31 2s
+-10 M +10/+11 1992 Ja 19 2s
+-11 M +11/+12 2011 Mar 27 2s
++11 R +11/+12 1991 Mar 31 2s
++10 R +10/+11 1992 Ja 19 2s
++11 R +11/+12 2011 Mar 27 2s
+ 12 - +12 2014 O 26 2s
+ 11 - +11
+ Z Asia/Ust-Nera 9:32:54 - LMT 1919 D 15
+ 8 - +08 1930 Jun 21
+-9 M +09/+10 1981 Ap
+-11 M +11/+12 1991 Mar 31 2s
+-10 M +10/+11 1992 Ja 19 2s
+-11 M +11/+12 2011 Mar 27 2s
++9 R +09/+10 1981 Ap
++11 R +11/+12 1991 Mar 31 2s
++10 R +10/+11 1992 Ja 19 2s
++11 R +11/+12 2011 Mar 27 2s
+ 12 - +12 2011 S 13 0s
+ 11 - +11 2014 O 26 2s
+ 10 - +10
+ Z Asia/Kamchatka 10:34:36 - LMT 1922 N 10
+ 11 - +11 1930 Jun 21
+-12 M +12/+13 1991 Mar 31 2s
+-11 M +11/+12 1992 Ja 19 2s
+-12 M +12/+13 2010 Mar 28 2s
+-11 M +11/+12 2011 Mar 27 2s
++12 R +12/+13 1991 Mar 31 2s
++11 R +11/+12 1992 Ja 19 2s
++12 R +12/+13 2010 Mar 28 2s
++11 R +11/+12 2011 Mar 27 2s
+ 12 - +12
+ Z Asia/Anadyr 11:49:56 - LMT 1924 May 2
+ 12 - +12 1930 Jun 21
+-13 M +13/+14 1982 Ap 1 0s
+-12 M +12/+13 1991 Mar 31 2s
+-11 M +11/+12 1992 Ja 19 2s
+-12 M +12/+13 2010 Mar 28 2s
+-11 M +11/+12 2011 Mar 27 2s
++13 R +13/+14 1982 Ap 1 0s
++12 R +12/+13 1991 Mar 31 2s
++11 R +11/+12 1992 Ja 19 2s
++12 R +12/+13 2010 Mar 28 2s
++11 R +11/+12 2011 Mar 27 2s
+ 12 - +12
+ Z Europe/Belgrade 1:22 - LMT 1884
+ 1 - CET 1941 Ap 18 23
+-1 ( CE%sT 1945
++1 c CE%sT 1945
+ 1 - CET 1945 May 8 2s
+ 1 1 CEST 1945 S 16 2s
+ 1 - CET 1982 N 27
+-1 O CE%sT
++1 E CE%sT
+ Li Europe/Belgrade Europe/Ljubljana
+ Li Europe/Belgrade Europe/Podgorica
+ Li Europe/Belgrade Europe/Sarajevo
+ Li Europe/Belgrade Europe/Skopje
+ Li Europe/Belgrade Europe/Zagreb
+ Li Europe/Prague Europe/Bratislava
+-R AB 1918 o - Ap 15 23 1 S
+-R AB 1918 1919 - O 6 24s 0 -
+-R AB 1919 o - Ap 6 23 1 S
+-R AB 1924 o - Ap 16 23 1 S
+-R AB 1924 o - O 4 24s 0 -
+-R AB 1926 o - Ap 17 23 1 S
+-R AB 1926 1929 - O Sat>=1 24s 0 -
+-R AB 1927 o - Ap 9 23 1 S
+-R AB 1928 o - Ap 15 0 1 S
+-R AB 1929 o - Ap 20 23 1 S
+-R AB 1937 o - Jun 16 23 1 S
+-R AB 1937 o - O 2 24s 0 -
+-R AB 1938 o - Ap 2 23 1 S
+-R AB 1938 o - Ap 30 23 2 M
+-R AB 1938 o - O 2 24 1 S
+-R AB 1939 o - O 7 24s 0 -
+-R AB 1942 o - May 2 23 1 S
+-R AB 1942 o - S 1 1 0 -
+-R AB 1943 1946 - Ap Sat>=13 23 1 S
+-R AB 1943 1944 - O Sun>=1 1 0 -
+-R AB 1945 1946 - S lastSun 1 0 -
+-R AB 1949 o - Ap 30 23 1 S
+-R AB 1949 o - O 2 1 0 -
+-R AB 1974 1975 - Ap Sat>=12 23 1 S
+-R AB 1974 1975 - O Sun>=1 1 0 -
+-R AB 1976 o - Mar 27 23 1 S
+-R AB 1976 1977 - S lastSun 1 0 -
+-R AB 1977 o - Ap 2 23 1 S
+-R AB 1978 o - Ap 2 2s 1 S
+-R AB 1978 o - O 1 2s 0 -
+-R AC 1967 o - Jun 3 12 1 S
+-R AC 1967 o - O 1 0 0 -
+-R AC 1974 o - Jun 24 0 1 S
+-R AC 1974 o - S 1 0 0 -
+-R AC 1976 1977 - May 1 0 1 S
+-R AC 1976 o - Au 1 0 0 -
+-R AC 1977 o - S 28 0 0 -
+-R AC 1978 o - Jun 1 0 1 S
+-R AC 1978 o - Au 4 0 0 -
++R s 1918 o - Ap 15 23 1 S
++R s 1918 1919 - O 6 24s 0 -
++R s 1919 o - Ap 6 23 1 S
++R s 1924 o - Ap 16 23 1 S
++R s 1924 o - O 4 24s 0 -
++R s 1926 o - Ap 17 23 1 S
++R s 1926 1929 - O Sat>=1 24s 0 -
++R s 1927 o - Ap 9 23 1 S
++R s 1928 o - Ap 15 0 1 S
++R s 1929 o - Ap 20 23 1 S
++R s 1937 o - Jun 16 23 1 S
++R s 1937 o - O 2 24s 0 -
++R s 1938 o - Ap 2 23 1 S
++R s 1938 o - Ap 30 23 2 M
++R s 1938 o - O 2 24 1 S
++R s 1939 o - O 7 24s 0 -
++R s 1942 o - May 2 23 1 S
++R s 1942 o - S 1 1 0 -
++R s 1943 1946 - Ap Sat>=13 23 1 S
++R s 1943 1944 - O Sun>=1 1 0 -
++R s 1945 1946 - S lastSun 1 0 -
++R s 1949 o - Ap 30 23 1 S
++R s 1949 o - O 2 1 0 -
++R s 1974 1975 - Ap Sat>=12 23 1 S
++R s 1974 1975 - O Sun>=1 1 0 -
++R s 1976 o - Mar 27 23 1 S
++R s 1976 1977 - S lastSun 1 0 -
++R s 1977 o - Ap 2 23 1 S
++R s 1978 o - Ap 2 2s 1 S
++R s 1978 o - O 1 2s 0 -
+ Z Europe/Madrid -0:14:44 - LMT 1900 D 31 23:45:16
+-0 AB WE%sT 1940 Mar 16 23
+-1 AB CE%sT 1979
+-1 O CE%sT
++0 s WE%sT 1940 Mar 16 23
++1 s CE%sT 1979
++1 E CE%sT
+ Z Africa/Ceuta -0:21:16 - LMT 1900 D 31 23:38:44
+ 0 - WET 1918 May 6 23
+ 0 1 WEST 1918 O 7 23
+ 0 - WET 1924
+-0 AB WE%sT 1929
+-0 AC WE%sT 1984 Mar 16
++0 s WE%sT 1929
++0 - WET 1967
++0 M WE%sT 1984 Mar 16
+ 1 - CET 1986
+-1 O CE%sT
++1 E CE%sT
+ Z Atlantic/Canary -1:1:36 - LMT 1922 Mar
+ -1 - -01 1946 S 30 1
+ 0 - WET 1980 Ap 6 0s
+ 0 1 WEST 1980 S 28 1u
+-0 O WE%sT
++0 E WE%sT
+ Z Europe/Stockholm 1:12:12 - LMT 1879
+ 1:0:14 - SET 1900
+ 1 - CET 1916 May 14 23
+ 1 1 CEST 1916 O 1 1
+ 1 - CET 1980
+-1 O CE%sT
+-R AD 1941 1942 - May M>=1 1 1 S
+-R AD 1941 1942 - O M>=1 2 0 -
++1 E CE%sT
++R CH 1941 1942 - May M>=1 1 1 S
++R CH 1941 1942 - O M>=1 2 0 -
+ Z Europe/Zurich 0:34:8 - LMT 1853 Jul 16
+ 0:29:46 - BMT 1894 Jun
+-1 AD CE%sT 1981
+-1 O CE%sT
+-R AE 1916 o - May 1 0 1 S
+-R AE 1916 o - O 1 0 0 -
+-R AE 1920 o - Mar 28 0 1 S
+-R AE 1920 o - O 25 0 0 -
+-R AE 1921 o - Ap 3 0 1 S
+-R AE 1921 o - O 3 0 0 -
+-R AE 1922 o - Mar 26 0 1 S
+-R AE 1922 o - O 8 0 0 -
+-R AE 1924 o - May 13 0 1 S
+-R AE 1924 1925 - O 1 0 0 -
+-R AE 1925 o - May 1 0 1 S
+-R AE 1940 o - Jun 30 0 1 S
+-R AE 1940 o - O 5 0 0 -
+-R AE 1940 o - D 1 0 1 S
+-R AE 1941 o - S 21 0 0 -
+-R AE 1942 o - Ap 1 0 1 S
+-R AE 1942 o - N 1 0 0 -
+-R AE 1945 o - Ap 2 0 1 S
+-R AE 1945 o - O 8 0 0 -
+-R AE 1946 o - Jun 1 0 1 S
+-R AE 1946 o - O 1 0 0 -
+-R AE 1947 1948 - Ap Sun>=16 0 1 S
+-R AE 1947 1950 - O Sun>=2 0 0 -
+-R AE 1949 o - Ap 10 0 1 S
+-R AE 1950 o - Ap 19 0 1 S
+-R AE 1951 o - Ap 22 0 1 S
+-R AE 1951 o - O 8 0 0 -
+-R AE 1962 o - Jul 15 0 1 S
+-R AE 1962 o - O 8 0 0 -
+-R AE 1964 o - May 15 0 1 S
+-R AE 1964 o - O 1 0 0 -
+-R AE 1970 1972 - May Sun>=2 0 1 S
+-R AE 1970 1972 - O Sun>=2 0 0 -
+-R AE 1973 o - Jun 3 1 1 S
+-R AE 1973 o - N 4 3 0 -
+-R AE 1974 o - Mar 31 2 1 S
+-R AE 1974 o - N 3 5 0 -
+-R AE 1975 o - Mar 30 0 1 S
+-R AE 1975 1976 - O lastSun 0 0 -
+-R AE 1976 o - Jun 1 0 1 S
+-R AE 1977 1978 - Ap Sun>=1 0 1 S
+-R AE 1977 o - O 16 0 0 -
+-R AE 1979 1980 - Ap Sun>=1 3 1 S
+-R AE 1979 1982 - O M>=11 0 0 -
+-R AE 1981 1982 - Mar lastSun 3 1 S
+-R AE 1983 o - Jul 31 0 1 S
+-R AE 1983 o - O 2 0 0 -
+-R AE 1985 o - Ap 20 0 1 S
+-R AE 1985 o - S 28 0 0 -
+-R AE 1986 1993 - Mar lastSun 1s 1 S
+-R AE 1986 1995 - S lastSun 1s 0 -
+-R AE 1994 o - Mar 20 1s 1 S
+-R AE 1995 2006 - Mar lastSun 1s 1 S
+-R AE 1996 2006 - O lastSun 1s 0 -
++1 CH CE%sT 1981
++1 E CE%sT
++R T 1916 o - May 1 0 1 S
++R T 1916 o - O 1 0 0 -
++R T 1920 o - Mar 28 0 1 S
++R T 1920 o - O 25 0 0 -
++R T 1921 o - Ap 3 0 1 S
++R T 1921 o - O 3 0 0 -
++R T 1922 o - Mar 26 0 1 S
++R T 1922 o - O 8 0 0 -
++R T 1924 o - May 13 0 1 S
++R T 1924 1925 - O 1 0 0 -
++R T 1925 o - May 1 0 1 S
++R T 1940 o - Jun 30 0 1 S
++R T 1940 o - O 5 0 0 -
++R T 1940 o - D 1 0 1 S
++R T 1941 o - S 21 0 0 -
++R T 1942 o - Ap 1 0 1 S
++R T 1942 o - N 1 0 0 -
++R T 1945 o - Ap 2 0 1 S
++R T 1945 o - O 8 0 0 -
++R T 1946 o - Jun 1 0 1 S
++R T 1946 o - O 1 0 0 -
++R T 1947 1948 - Ap Sun>=16 0 1 S
++R T 1947 1950 - O Sun>=2 0 0 -
++R T 1949 o - Ap 10 0 1 S
++R T 1950 o - Ap 19 0 1 S
++R T 1951 o - Ap 22 0 1 S
++R T 1951 o - O 8 0 0 -
++R T 1962 o - Jul 15 0 1 S
++R T 1962 o - O 8 0 0 -
++R T 1964 o - May 15 0 1 S
++R T 1964 o - O 1 0 0 -
++R T 1970 1972 - May Sun>=2 0 1 S
++R T 1970 1972 - O Sun>=2 0 0 -
++R T 1973 o - Jun 3 1 1 S
++R T 1973 o - N 4 3 0 -
++R T 1974 o - Mar 31 2 1 S
++R T 1974 o - N 3 5 0 -
++R T 1975 o - Mar 30 0 1 S
++R T 1975 1976 - O lastSun 0 0 -
++R T 1976 o - Jun 1 0 1 S
++R T 1977 1978 - Ap Sun>=1 0 1 S
++R T 1977 o - O 16 0 0 -
++R T 1979 1980 - Ap Sun>=1 3 1 S
++R T 1979 1982 - O M>=11 0 0 -
++R T 1981 1982 - Mar lastSun 3 1 S
++R T 1983 o - Jul 31 0 1 S
++R T 1983 o - O 2 0 0 -
++R T 1985 o - Ap 20 0 1 S
++R T 1985 o - S 28 0 0 -
++R T 1986 1993 - Mar lastSun 1s 1 S
++R T 1986 1995 - S lastSun 1s 0 -
++R T 1994 o - Mar 20 1s 1 S
++R T 1995 2006 - Mar lastSun 1s 1 S
++R T 1996 2006 - O lastSun 1s 0 -
+ Z Europe/Istanbul 1:55:52 - LMT 1880
+ 1:56:56 - IMT 1910 O
+-2 AE EE%sT 1978 O 15
+-3 AE +03/+04 1985 Ap 20
+-2 AE EE%sT 2007
+-2 O EE%sT 2011 Mar 27 1u
++2 T EE%sT 1978 O 15
++3 T +03/+04 1985 Ap 20
++2 T EE%sT 2007
++2 E EE%sT 2011 Mar 27 1u
+ 2 - EET 2011 Mar 28 1u
+-2 O EE%sT 2014 Mar 30 1u
++2 E EE%sT 2014 Mar 30 1u
+ 2 - EET 2014 Mar 31 1u
+-2 O EE%sT 2015 O 25 1u
++2 E EE%sT 2015 O 25 1u
+ 2 1 EEST 2015 N 8 1u
+-2 O EE%sT 2016 S 7
++2 E EE%sT 2016 S 7
+ 3 - +03
+ Li Europe/Istanbul Asia/Istanbul
+ Z Europe/Kiev 2:2:4 - LMT 1880
+ 2:2:4 - KMT 1924 May 2
+ 2 - EET 1930 Jun 21
+ 3 - MSK 1941 S 20
+-1 ( CE%sT 1943 N 6
+-3 M MSK/MSD 1990 Jul 1 2
++1 c CE%sT 1943 N 6
++3 R MSK/MSD 1990 Jul 1 2
+ 2 1 EEST 1991 S 29 3
+-2 W EE%sT 1995
+-2 O EE%sT
++2 e EE%sT 1995
++2 E EE%sT
+ Z Europe/Uzhgorod 1:29:12 - LMT 1890 O
+ 1 - CET 1940
+-1 ( CE%sT 1944 O
++1 c CE%sT 1944 O
+ 1 1 CEST 1944 O 26
+ 1 - CET 1945 Jun 29
+-3 M MSK/MSD 1990
++3 R MSK/MSD 1990
+ 3 - MSK 1990 Jul 1 2
+ 1 - CET 1991 Mar 31 3
+ 2 - EET 1992
+-2 W EE%sT 1995
+-2 O EE%sT
++2 e EE%sT 1995
++2 E EE%sT
+ Z Europe/Zaporozhye 2:20:40 - LMT 1880
+ 2:20 - +0220 1924 May 2
+ 2 - EET 1930 Jun 21
+ 3 - MSK 1941 Au 25
+-1 ( CE%sT 1943 O 25
+-3 M MSK/MSD 1991 Mar 31 2
+-2 W EE%sT 1995
+-2 O EE%sT
+-R AF 1918 1919 - Mar lastSun 2 1 D
+-R AF 1918 1919 - O lastSun 2 0 S
+-R AF 1942 o - F 9 2 1 W
+-R AF 1945 o - Au 14 23u 1 P
+-R AF 1945 o - S lastSun 2 0 S
+-R AF 1967 2006 - O lastSun 2 0 S
+-R AF 1967 1973 - Ap lastSun 2 1 D
+-R AF 1974 o - Ja 6 2 1 D
+-R AF 1975 o - F 23 2 1 D
+-R AF 1976 1986 - Ap lastSun 2 1 D
+-R AF 1987 2006 - Ap Sun>=1 2 1 D
+-R AF 2007 ma - Mar Sun>=8 2 1 D
+-R AF 2007 ma - N Sun>=1 2 0 S
++1 c CE%sT 1943 O 25
++3 R MSK/MSD 1991 Mar 31 2
++2 e EE%sT 1995
++2 E EE%sT
++R u 1918 1919 - Mar lastSun 2 1 D
++R u 1918 1919 - O lastSun 2 0 S
++R u 1942 o - F 9 2 1 W
++R u 1945 o - Au 14 23u 1 P
++R u 1945 o - S lastSun 2 0 S
++R u 1967 2006 - O lastSun 2 0 S
++R u 1967 1973 - Ap lastSun 2 1 D
++R u 1974 o - Ja 6 2 1 D
++R u 1975 o - F 23 2 1 D
++R u 1976 1986 - Ap lastSun 2 1 D
++R u 1987 2006 - Ap Sun>=1 2 1 D
++R u 2007 ma - Mar Sun>=8 2 1 D
++R u 2007 ma - N Sun>=1 2 0 S
+ Z EST -5 - EST
+ Z MST -7 - MST
+ Z HST -10 - HST
+-Z EST5EDT -5 AF E%sT
+-Z CST6CDT -6 AF C%sT
+-Z MST7MDT -7 AF M%sT
+-Z PST8PDT -8 AF P%sT
+-R AG 1920 o - Mar lastSun 2 1 D
+-R AG 1920 o - O lastSun 2 0 S
+-R AG 1921 1966 - Ap lastSun 2 1 D
+-R AG 1921 1954 - S lastSun 2 0 S
+-R AG 1955 1966 - O lastSun 2 0 S
++Z EST5EDT -5 u E%sT
++Z CST6CDT -6 u C%sT
++Z MST7MDT -7 u M%sT
++Z PST8PDT -8 u P%sT
++R NY 1920 o - Mar lastSun 2 1 D
++R NY 1920 o - O lastSun 2 0 S
++R NY 1921 1966 - Ap lastSun 2 1 D
++R NY 1921 1954 - S lastSun 2 0 S
++R NY 1955 1966 - O lastSun 2 0 S
+ Z America/New_York -4:56:2 - LMT 1883 N 18 12:3:58
+--5 AF E%sT 1920
+--5 AG E%sT 1942
+--5 AF E%sT 1946
+--5 AG E%sT 1967
+--5 AF E%sT
+-R AH 1920 o - Jun 13 2 1 D
+-R AH 1920 1921 - O lastSun 2 0 S
+-R AH 1921 o - Mar lastSun 2 1 D
+-R AH 1922 1966 - Ap lastSun 2 1 D
+-R AH 1922 1954 - S lastSun 2 0 S
+-R AH 1955 1966 - O lastSun 2 0 S
++-5 u E%sT 1920
++-5 NY E%sT 1942
++-5 u E%sT 1946
++-5 NY E%sT 1967
++-5 u E%sT
++R Ch 1920 o - Jun 13 2 1 D
++R Ch 1920 1921 - O lastSun 2 0 S
++R Ch 1921 o - Mar lastSun 2 1 D
++R Ch 1922 1966 - Ap lastSun 2 1 D
++R Ch 1922 1954 - S lastSun 2 0 S
++R Ch 1955 1966 - O lastSun 2 0 S
+ Z America/Chicago -5:50:36 - LMT 1883 N 18 12:9:24
+--6 AF C%sT 1920
+--6 AH C%sT 1936 Mar 1 2
++-6 u C%sT 1920
++-6 Ch C%sT 1936 Mar 1 2
+ -5 - EST 1936 N 15 2
+--6 AH C%sT 1942
+--6 AF C%sT 1946
+--6 AH C%sT 1967
+--6 AF C%sT
++-6 Ch C%sT 1942
++-6 u C%sT 1946
++-6 Ch C%sT 1967
++-6 u C%sT
+ Z America/North_Dakota/Center -6:45:12 - LMT 1883 N 18 12:14:48
+--7 AF M%sT 1992 O 25 2
+--6 AF C%sT
++-7 u M%sT 1992 O 25 2
++-6 u C%sT
+ Z America/North_Dakota/New_Salem -6:45:39 - LMT 1883 N 18 12:14:21
+--7 AF M%sT 2003 O 26 2
+--6 AF C%sT
++-7 u M%sT 2003 O 26 2
++-6 u C%sT
+ Z America/North_Dakota/Beulah -6:47:7 - LMT 1883 N 18 12:12:53
+--7 AF M%sT 2010 N 7 2
+--6 AF C%sT
+-R AI 1920 1921 - Mar lastSun 2 1 D
+-R AI 1920 o - O lastSun 2 0 S
+-R AI 1921 o - May 22 2 0 S
+-R AI 1965 1966 - Ap lastSun 2 1 D
+-R AI 1965 1966 - O lastSun 2 0 S
++-7 u M%sT 2010 N 7 2
++-6 u C%sT
++R De 1920 1921 - Mar lastSun 2 1 D
++R De 1920 o - O lastSun 2 0 S
++R De 1921 o - May 22 2 0 S
++R De 1965 1966 - Ap lastSun 2 1 D
++R De 1965 1966 - O lastSun 2 0 S
+ Z America/Denver -6:59:56 - LMT 1883 N 18 12:0:4
+--7 AF M%sT 1920
+--7 AI M%sT 1942
+--7 AF M%sT 1946
+--7 AI M%sT 1967
+--7 AF M%sT
+-R AJ 1948 o - Mar 14 2:1 1 D
+-R AJ 1949 o - Ja 1 2 0 S
+-R AJ 1950 1966 - Ap lastSun 1 1 D
+-R AJ 1950 1961 - S lastSun 2 0 S
+-R AJ 1962 1966 - O lastSun 2 0 S
++-7 u M%sT 1920
++-7 De M%sT 1942
++-7 u M%sT 1946
++-7 De M%sT 1967
++-7 u M%sT
++R CA 1948 o - Mar 14 2:1 1 D
++R CA 1949 o - Ja 1 2 0 S
++R CA 1950 1966 - Ap lastSun 1 1 D
++R CA 1950 1961 - S lastSun 2 0 S
++R CA 1962 1966 - O lastSun 2 0 S
+ Z America/Los_Angeles -7:52:58 - LMT 1883 N 18 12:7:2
+--8 AF P%sT 1946
+--8 AJ P%sT 1967
+--8 AF P%sT
++-8 u P%sT 1946
++-8 CA P%sT 1967
++-8 u P%sT
+ Z America/Juneau 15:2:19 - LMT 1867 O 19 15:33:32
+ -8:57:41 - LMT 1900 Au 20 12
+ -8 - PST 1942
+--8 AF P%sT 1946
++-8 u P%sT 1946
+ -8 - PST 1969
+--8 AF P%sT 1980 Ap 27 2
+--9 AF Y%sT 1980 O 26 2
+--8 AF P%sT 1983 O 30 2
+--9 AF Y%sT 1983 N 30
+--9 AF AK%sT
++-8 u P%sT 1980 Ap 27 2
++-9 u Y%sT 1980 O 26 2
++-8 u P%sT 1983 O 30 2
++-9 u Y%sT 1983 N 30
++-9 u AK%sT
+ Z America/Sitka 14:58:47 - LMT 1867 O 19 15:30
+ -9:1:13 - LMT 1900 Au 20 12
+ -8 - PST 1942
+--8 AF P%sT 1946
++-8 u P%sT 1946
+ -8 - PST 1969
+--8 AF P%sT 1983 O 30 2
+--9 AF Y%sT 1983 N 30
+--9 AF AK%sT
++-8 u P%sT 1983 O 30 2
++-9 u Y%sT 1983 N 30
++-9 u AK%sT
+ Z America/Metlakatla 15:13:42 - LMT 1867 O 19 15:44:55
+ -8:46:18 - LMT 1900 Au 20 12
+ -8 - PST 1942
+--8 AF P%sT 1946
++-8 u P%sT 1946
+ -8 - PST 1969
+--8 AF P%sT 1983 O 30 2
++-8 u P%sT 1983 O 30 2
+ -8 - PST 2015 N 1 2
+--9 AF AK%sT
++-9 u AK%sT
+ Z America/Yakutat 14:41:5 - LMT 1867 O 19 15:12:18
+ -9:18:55 - LMT 1900 Au 20 12
+ -9 - YST 1942
+--9 AF Y%sT 1946
++-9 u Y%sT 1946
+ -9 - YST 1969
+--9 AF Y%sT 1983 N 30
+--9 AF AK%sT
++-9 u Y%sT 1983 N 30
++-9 u AK%sT
+ Z America/Anchorage 14:0:24 - LMT 1867 O 19 14:31:37
+ -9:59:36 - LMT 1900 Au 20 12
+ -10 - AST 1942
+--10 AF A%sT 1967 Ap
++-10 u A%sT 1967 Ap
+ -10 - AHST 1969
+--10 AF AH%sT 1983 O 30 2
+--9 AF Y%sT 1983 N 30
+--9 AF AK%sT
++-10 u AH%sT 1983 O 30 2
++-9 u Y%sT 1983 N 30
++-9 u AK%sT
+ Z America/Nome 12:58:22 - LMT 1867 O 19 13:29:35
+ -11:1:38 - LMT 1900 Au 20 12
+ -11 - NST 1942
+--11 AF N%sT 1946
++-11 u N%sT 1946
+ -11 - NST 1967 Ap
+ -11 - BST 1969
+--11 AF B%sT 1983 O 30 2
+--9 AF Y%sT 1983 N 30
+--9 AF AK%sT
++-11 u B%sT 1983 O 30 2
++-9 u Y%sT 1983 N 30
++-9 u AK%sT
+ Z America/Adak 12:13:22 - LMT 1867 O 19 12:44:35
+ -11:46:38 - LMT 1900 Au 20 12
+ -11 - NST 1942
+--11 AF N%sT 1946
++-11 u N%sT 1946
+ -11 - NST 1967 Ap
+ -11 - BST 1969
+--11 AF B%sT 1983 O 30 2
+--10 AF AH%sT 1983 N 30
+--10 AF H%sT
++-11 u B%sT 1983 O 30 2
++-10 u AH%sT 1983 N 30
++-10 u H%sT
+ Z Pacific/Honolulu -10:31:26 - LMT 1896 Ja 13 12
+ -10:30 - HST 1933 Ap 30 2
+ -10:30 1 HDT 1933 May 21 12
+@@ -2683,531 +2700,531 @@ Z Pacific/Honolulu -10:31:26 - LMT 1896 Ja 13 12
+ -10:30 - HST 1947 Jun 8 2
+ -10 - HST
+ Z America/Phoenix -7:28:18 - LMT 1883 N 18 11:31:42
+--7 AF M%sT 1944 Ja 1 0:1
++-7 u M%sT 1944 Ja 1 0:1
+ -7 - MST 1944 Ap 1 0:1
+--7 AF M%sT 1944 O 1 0:1
++-7 u M%sT 1944 O 1 0:1
+ -7 - MST 1967
+--7 AF M%sT 1968 Mar 21
++-7 u M%sT 1968 Mar 21
+ -7 - MST
+ Z America/Boise -7:44:49 - LMT 1883 N 18 12:15:11
+--8 AF P%sT 1923 May 13 2
+--7 AF M%sT 1974
++-8 u P%sT 1923 May 13 2
++-7 u M%sT 1974
+ -7 - MST 1974 F 3 2
+--7 AF M%sT
+-R AK 1941 o - Jun 22 2 1 D
+-R AK 1941 1954 - S lastSun 2 0 S
+-R AK 1946 1954 - Ap lastSun 2 1 D
++-7 u M%sT
++R In 1941 o - Jun 22 2 1 D
++R In 1941 1954 - S lastSun 2 0 S
++R In 1946 1954 - Ap lastSun 2 1 D
+ Z America/Indiana/Indianapolis -5:44:38 - LMT 1883 N 18 12:15:22
+--6 AF C%sT 1920
+--6 AK C%sT 1942
+--6 AF C%sT 1946
+--6 AK C%sT 1955 Ap 24 2
++-6 u C%sT 1920
++-6 In C%sT 1942
++-6 u C%sT 1946
++-6 In C%sT 1955 Ap 24 2
+ -5 - EST 1957 S 29 2
+ -6 - CST 1958 Ap 27 2
+ -5 - EST 1969
+--5 AF E%sT 1971
++-5 u E%sT 1971
+ -5 - EST 2006
+--5 AF E%sT
+-R AL 1951 o - Ap lastSun 2 1 D
+-R AL 1951 o - S lastSun 2 0 S
+-R AL 1954 1960 - Ap lastSun 2 1 D
+-R AL 1954 1960 - S lastSun 2 0 S
++-5 u E%sT
++R Ma 1951 o - Ap lastSun 2 1 D
++R Ma 1951 o - S lastSun 2 0 S
++R Ma 1954 1960 - Ap lastSun 2 1 D
++R Ma 1954 1960 - S lastSun 2 0 S
+ Z America/Indiana/Marengo -5:45:23 - LMT 1883 N 18 12:14:37
+--6 AF C%sT 1951
+--6 AL C%sT 1961 Ap 30 2
++-6 u C%sT 1951
++-6 Ma C%sT 1961 Ap 30 2
+ -5 - EST 1969
+--5 AF E%sT 1974 Ja 6 2
++-5 u E%sT 1974 Ja 6 2
+ -6 1 CDT 1974 O 27 2
+--5 AF E%sT 1976
++-5 u E%sT 1976
+ -5 - EST 2006
+--5 AF E%sT
+-R AM 1946 o - Ap lastSun 2 1 D
+-R AM 1946 o - S lastSun 2 0 S
+-R AM 1953 1954 - Ap lastSun 2 1 D
+-R AM 1953 1959 - S lastSun 2 0 S
+-R AM 1955 o - May 1 0 1 D
+-R AM 1956 1963 - Ap lastSun 2 1 D
+-R AM 1960 o - O lastSun 2 0 S
+-R AM 1961 o - S lastSun 2 0 S
+-R AM 1962 1963 - O lastSun 2 0 S
++-5 u E%sT
++R V 1946 o - Ap lastSun 2 1 D
++R V 1946 o - S lastSun 2 0 S
++R V 1953 1954 - Ap lastSun 2 1 D
++R V 1953 1959 - S lastSun 2 0 S
++R V 1955 o - May 1 0 1 D
++R V 1956 1963 - Ap lastSun 2 1 D
++R V 1960 o - O lastSun 2 0 S
++R V 1961 o - S lastSun 2 0 S
++R V 1962 1963 - O lastSun 2 0 S
+ Z America/Indiana/Vincennes -5:50:7 - LMT 1883 N 18 12:9:53
+--6 AF C%sT 1946
+--6 AM C%sT 1964 Ap 26 2
++-6 u C%sT 1946
++-6 V C%sT 1964 Ap 26 2
+ -5 - EST 1969
+--5 AF E%sT 1971
++-5 u E%sT 1971
+ -5 - EST 2006 Ap 2 2
+--6 AF C%sT 2007 N 4 2
+--5 AF E%sT
+-R AN 1946 o - Ap lastSun 2 1 D
+-R AN 1946 o - S lastSun 2 0 S
+-R AN 1953 1954 - Ap lastSun 2 1 D
+-R AN 1953 1959 - S lastSun 2 0 S
+-R AN 1955 o - May 1 0 1 D
+-R AN 1956 1963 - Ap lastSun 2 1 D
+-R AN 1960 o - O lastSun 2 0 S
+-R AN 1961 o - S lastSun 2 0 S
+-R AN 1962 1963 - O lastSun 2 0 S
++-6 u C%sT 2007 N 4 2
++-5 u E%sT
++R Pe 1946 o - Ap lastSun 2 1 D
++R Pe 1946 o - S lastSun 2 0 S
++R Pe 1953 1954 - Ap lastSun 2 1 D
++R Pe 1953 1959 - S lastSun 2 0 S
++R Pe 1955 o - May 1 0 1 D
++R Pe 1956 1963 - Ap lastSun 2 1 D
++R Pe 1960 o - O lastSun 2 0 S
++R Pe 1961 o - S lastSun 2 0 S
++R Pe 1962 1963 - O lastSun 2 0 S
+ Z America/Indiana/Tell_City -5:47:3 - LMT 1883 N 18 12:12:57
+--6 AF C%sT 1946
+--6 AN C%sT 1964 Ap 26 2
++-6 u C%sT 1946
++-6 Pe C%sT 1964 Ap 26 2
+ -5 - EST 1969
+--5 AF E%sT 1971
++-5 u E%sT 1971
+ -5 - EST 2006 Ap 2 2
+--6 AF C%sT
+-R AO 1955 o - May 1 0 1 D
+-R AO 1955 1960 - S lastSun 2 0 S
+-R AO 1956 1964 - Ap lastSun 2 1 D
+-R AO 1961 1964 - O lastSun 2 0 S
++-6 u C%sT
++R Pi 1955 o - May 1 0 1 D
++R Pi 1955 1960 - S lastSun 2 0 S
++R Pi 1956 1964 - Ap lastSun 2 1 D
++R Pi 1961 1964 - O lastSun 2 0 S
+ Z America/Indiana/Petersburg -5:49:7 - LMT 1883 N 18 12:10:53
+--6 AF C%sT 1955
+--6 AO C%sT 1965 Ap 25 2
++-6 u C%sT 1955
++-6 Pi C%sT 1965 Ap 25 2
+ -5 - EST 1966 O 30 2
+--6 AF C%sT 1977 O 30 2
++-6 u C%sT 1977 O 30 2
+ -5 - EST 2006 Ap 2 2
+--6 AF C%sT 2007 N 4 2
+--5 AF E%sT
+-R AP 1947 1961 - Ap lastSun 2 1 D
+-R AP 1947 1954 - S lastSun 2 0 S
+-R AP 1955 1956 - O lastSun 2 0 S
+-R AP 1957 1958 - S lastSun 2 0 S
+-R AP 1959 1961 - O lastSun 2 0 S
++-6 u C%sT 2007 N 4 2
++-5 u E%sT
++R St 1947 1961 - Ap lastSun 2 1 D
++R St 1947 1954 - S lastSun 2 0 S
++R St 1955 1956 - O lastSun 2 0 S
++R St 1957 1958 - S lastSun 2 0 S
++R St 1959 1961 - O lastSun 2 0 S
+ Z America/Indiana/Knox -5:46:30 - LMT 1883 N 18 12:13:30
+--6 AF C%sT 1947
+--6 AP C%sT 1962 Ap 29 2
++-6 u C%sT 1947
++-6 St C%sT 1962 Ap 29 2
+ -5 - EST 1963 O 27 2
+--6 AF C%sT 1991 O 27 2
++-6 u C%sT 1991 O 27 2
+ -5 - EST 2006 Ap 2 2
+--6 AF C%sT
+-R AQ 1946 1960 - Ap lastSun 2 1 D
+-R AQ 1946 1954 - S lastSun 2 0 S
+-R AQ 1955 1956 - O lastSun 2 0 S
+-R AQ 1957 1960 - S lastSun 2 0 S
++-6 u C%sT
++R Pu 1946 1960 - Ap lastSun 2 1 D
++R Pu 1946 1954 - S lastSun 2 0 S
++R Pu 1955 1956 - O lastSun 2 0 S
++R Pu 1957 1960 - S lastSun 2 0 S
+ Z America/Indiana/Winamac -5:46:25 - LMT 1883 N 18 12:13:35
+--6 AF C%sT 1946
+--6 AQ C%sT 1961 Ap 30 2
++-6 u C%sT 1946
++-6 Pu C%sT 1961 Ap 30 2
+ -5 - EST 1969
+--5 AF E%sT 1971
++-5 u E%sT 1971
+ -5 - EST 2006 Ap 2 2
+--6 AF C%sT 2007 Mar 11 2
+--5 AF E%sT
++-6 u C%sT 2007 Mar 11 2
++-5 u E%sT
+ Z America/Indiana/Vevay -5:40:16 - LMT 1883 N 18 12:19:44
+--6 AF C%sT 1954 Ap 25 2
++-6 u C%sT 1954 Ap 25 2
+ -5 - EST 1969
+--5 AF E%sT 1973
++-5 u E%sT 1973
+ -5 - EST 2006
+--5 AF E%sT
+-R AR 1921 o - May 1 2 1 D
+-R AR 1921 o - S 1 2 0 S
+-R AR 1941 1961 - Ap lastSun 2 1 D
+-R AR 1941 o - S lastSun 2 0 S
+-R AR 1946 o - Jun 2 2 0 S
+-R AR 1950 1955 - S lastSun 2 0 S
+-R AR 1956 1960 - O lastSun 2 0 S
++-5 u E%sT
++R v 1921 o - May 1 2 1 D
++R v 1921 o - S 1 2 0 S
++R v 1941 1961 - Ap lastSun 2 1 D
++R v 1941 o - S lastSun 2 0 S
++R v 1946 o - Jun 2 2 0 S
++R v 1950 1955 - S lastSun 2 0 S
++R v 1956 1960 - O lastSun 2 0 S
+ Z America/Kentucky/Louisville -5:43:2 - LMT 1883 N 18 12:16:58
+--6 AF C%sT 1921
+--6 AR C%sT 1942
+--6 AF C%sT 1946
+--6 AR C%sT 1961 Jul 23 2
++-6 u C%sT 1921
++-6 v C%sT 1942
++-6 u C%sT 1946
++-6 v C%sT 1961 Jul 23 2
+ -5 - EST 1968
+--5 AF E%sT 1974 Ja 6 2
++-5 u E%sT 1974 Ja 6 2
+ -6 1 CDT 1974 O 27 2
+--5 AF E%sT
++-5 u E%sT
+ Z America/Kentucky/Monticello -5:39:24 - LMT 1883 N 18 12:20:36
+--6 AF C%sT 1946
++-6 u C%sT 1946
+ -6 - CST 1968
+--6 AF C%sT 2000 O 29 2
+--5 AF E%sT
+-R AS 1948 o - Ap lastSun 2 1 D
+-R AS 1948 o - S lastSun 2 0 S
++-6 u C%sT 2000 O 29 2
++-5 u E%sT
++R Dt 1948 o - Ap lastSun 2 1 D
++R Dt 1948 o - S lastSun 2 0 S
+ Z America/Detroit -5:32:11 - LMT 1905
+ -6 - CST 1915 May 15 2
+ -5 - EST 1942
+--5 AF E%sT 1946
+--5 AS E%sT 1973
+--5 AF E%sT 1975
++-5 u E%sT 1946
++-5 Dt E%sT 1973
++-5 u E%sT 1975
+ -5 - EST 1975 Ap 27 2
+--5 AF E%sT
+-R AT 1946 o - Ap lastSun 2 1 D
+-R AT 1946 o - S lastSun 2 0 S
+-R AT 1966 o - Ap lastSun 2 1 D
+-R AT 1966 o - O lastSun 2 0 S
++-5 u E%sT
++R Me 1946 o - Ap lastSun 2 1 D
++R Me 1946 o - S lastSun 2 0 S
++R Me 1966 o - Ap lastSun 2 1 D
++R Me 1966 o - O lastSun 2 0 S
+ Z America/Menominee -5:50:27 - LMT 1885 S 18 12
+--6 AF C%sT 1946
+--6 AT C%sT 1969 Ap 27 2
++-6 u C%sT 1946
++-6 Me C%sT 1969 Ap 27 2
+ -5 - EST 1973 Ap 29 2
+--6 AF C%sT
+-R AU 1918 o - Ap 14 2 1 D
+-R AU 1918 o - O 27 2 0 S
+-R AU 1942 o - F 9 2 1 W
+-R AU 1945 o - Au 14 23u 1 P
+-R AU 1945 o - S 30 2 0 S
+-R AU 1974 1986 - Ap lastSun 2 1 D
+-R AU 1974 2006 - O lastSun 2 0 S
+-R AU 1987 2006 - Ap Sun>=1 2 1 D
+-R AU 2007 ma - Mar Sun>=8 2 1 D
+-R AU 2007 ma - N Sun>=1 2 0 S
+-R AV 1917 o - Ap 8 2 1 D
+-R AV 1917 o - S 17 2 0 S
+-R AV 1919 o - May 5 23 1 D
+-R AV 1919 o - Au 12 23 0 S
+-R AV 1920 1935 - May Sun>=1 23 1 D
+-R AV 1920 1935 - O lastSun 23 0 S
+-R AV 1936 1941 - May M>=9 0 1 D
+-R AV 1936 1941 - O M>=2 0 0 S
+-R AV 1946 1950 - May Sun>=8 2 1 D
+-R AV 1946 1950 - O Sun>=2 2 0 S
+-R AV 1951 1986 - Ap lastSun 2 1 D
+-R AV 1951 1959 - S lastSun 2 0 S
+-R AV 1960 1986 - O lastSun 2 0 S
+-R AV 1987 o - Ap Sun>=1 0:1 1 D
+-R AV 1987 2006 - O lastSun 0:1 0 S
+-R AV 1988 o - Ap Sun>=1 0:1 2 DD
+-R AV 1989 2006 - Ap Sun>=1 0:1 1 D
+-R AV 2007 2011 - Mar Sun>=8 0:1 1 D
+-R AV 2007 2010 - N Sun>=1 0:1 0 S
++-6 u C%sT
++R C 1918 o - Ap 14 2 1 D
++R C 1918 o - O 27 2 0 S
++R C 1942 o - F 9 2 1 W
++R C 1945 o - Au 14 23u 1 P
++R C 1945 o - S 30 2 0 S
++R C 1974 1986 - Ap lastSun 2 1 D
++R C 1974 2006 - O lastSun 2 0 S
++R C 1987 2006 - Ap Sun>=1 2 1 D
++R C 2007 ma - Mar Sun>=8 2 1 D
++R C 2007 ma - N Sun>=1 2 0 S
++R j 1917 o - Ap 8 2 1 D
++R j 1917 o - S 17 2 0 S
++R j 1919 o - May 5 23 1 D
++R j 1919 o - Au 12 23 0 S
++R j 1920 1935 - May Sun>=1 23 1 D
++R j 1920 1935 - O lastSun 23 0 S
++R j 1936 1941 - May M>=9 0 1 D
++R j 1936 1941 - O M>=2 0 0 S
++R j 1946 1950 - May Sun>=8 2 1 D
++R j 1946 1950 - O Sun>=2 2 0 S
++R j 1951 1986 - Ap lastSun 2 1 D
++R j 1951 1959 - S lastSun 2 0 S
++R j 1960 1986 - O lastSun 2 0 S
++R j 1987 o - Ap Sun>=1 0:1 1 D
++R j 1987 2006 - O lastSun 0:1 0 S
++R j 1988 o - Ap Sun>=1 0:1 2 DD
++R j 1989 2006 - Ap Sun>=1 0:1 1 D
++R j 2007 2011 - Mar Sun>=8 0:1 1 D
++R j 2007 2010 - N Sun>=1 0:1 0 S
+ Z America/St_Johns -3:30:52 - LMT 1884
+--3:30:52 AV N%sT 1918
+--3:30:52 AU N%sT 1919
+--3:30:52 AV N%sT 1935 Mar 30
+--3:30 AV N%sT 1942 May 11
+--3:30 AU N%sT 1946
+--3:30 AV N%sT 2011 N
+--3:30 AU N%sT
++-3:30:52 j N%sT 1918
++-3:30:52 C N%sT 1919
++-3:30:52 j N%sT 1935 Mar 30
++-3:30 j N%sT 1942 May 11
++-3:30 C N%sT 1946
++-3:30 j N%sT 2011 N
++-3:30 C N%sT
+ Z America/Goose_Bay -4:1:40 - LMT 1884
+ -3:30:52 - NST 1918
+--3:30:52 AU N%sT 1919
++-3:30:52 C N%sT 1919
+ -3:30:52 - NST 1935 Mar 30
+ -3:30 - NST 1936
+--3:30 AV N%sT 1942 May 11
+--3:30 AU N%sT 1946
+--3:30 AV N%sT 1966 Mar 15 2
+--4 AV A%sT 2011 N
+--4 AU A%sT
+-R AW 1916 o - Ap 1 0 1 D
+-R AW 1916 o - O 1 0 0 S
+-R AW 1920 o - May 9 0 1 D
+-R AW 1920 o - Au 29 0 0 S
+-R AW 1921 o - May 6 0 1 D
+-R AW 1921 1922 - S 5 0 0 S
+-R AW 1922 o - Ap 30 0 1 D
+-R AW 1923 1925 - May Sun>=1 0 1 D
+-R AW 1923 o - S 4 0 0 S
+-R AW 1924 o - S 15 0 0 S
+-R AW 1925 o - S 28 0 0 S
+-R AW 1926 o - May 16 0 1 D
+-R AW 1926 o - S 13 0 0 S
+-R AW 1927 o - May 1 0 1 D
+-R AW 1927 o - S 26 0 0 S
+-R AW 1928 1931 - May Sun>=8 0 1 D
+-R AW 1928 o - S 9 0 0 S
+-R AW 1929 o - S 3 0 0 S
+-R AW 1930 o - S 15 0 0 S
+-R AW 1931 1932 - S M>=24 0 0 S
+-R AW 1932 o - May 1 0 1 D
+-R AW 1933 o - Ap 30 0 1 D
+-R AW 1933 o - O 2 0 0 S
+-R AW 1934 o - May 20 0 1 D
+-R AW 1934 o - S 16 0 0 S
+-R AW 1935 o - Jun 2 0 1 D
+-R AW 1935 o - S 30 0 0 S
+-R AW 1936 o - Jun 1 0 1 D
+-R AW 1936 o - S 14 0 0 S
+-R AW 1937 1938 - May Sun>=1 0 1 D
+-R AW 1937 1941 - S M>=24 0 0 S
+-R AW 1939 o - May 28 0 1 D
+-R AW 1940 1941 - May Sun>=1 0 1 D
+-R AW 1946 1949 - Ap lastSun 2 1 D
+-R AW 1946 1949 - S lastSun 2 0 S
+-R AW 1951 1954 - Ap lastSun 2 1 D
+-R AW 1951 1954 - S lastSun 2 0 S
+-R AW 1956 1959 - Ap lastSun 2 1 D
+-R AW 1956 1959 - S lastSun 2 0 S
+-R AW 1962 1973 - Ap lastSun 2 1 D
+-R AW 1962 1973 - O lastSun 2 0 S
++-3:30 j N%sT 1942 May 11
++-3:30 C N%sT 1946
++-3:30 j N%sT 1966 Mar 15 2
++-4 j A%sT 2011 N
++-4 C A%sT
++R H 1916 o - Ap 1 0 1 D
++R H 1916 o - O 1 0 0 S
++R H 1920 o - May 9 0 1 D
++R H 1920 o - Au 29 0 0 S
++R H 1921 o - May 6 0 1 D
++R H 1921 1922 - S 5 0 0 S
++R H 1922 o - Ap 30 0 1 D
++R H 1923 1925 - May Sun>=1 0 1 D
++R H 1923 o - S 4 0 0 S
++R H 1924 o - S 15 0 0 S
++R H 1925 o - S 28 0 0 S
++R H 1926 o - May 16 0 1 D
++R H 1926 o - S 13 0 0 S
++R H 1927 o - May 1 0 1 D
++R H 1927 o - S 26 0 0 S
++R H 1928 1931 - May Sun>=8 0 1 D
++R H 1928 o - S 9 0 0 S
++R H 1929 o - S 3 0 0 S
++R H 1930 o - S 15 0 0 S
++R H 1931 1932 - S M>=24 0 0 S
++R H 1932 o - May 1 0 1 D
++R H 1933 o - Ap 30 0 1 D
++R H 1933 o - O 2 0 0 S
++R H 1934 o - May 20 0 1 D
++R H 1934 o - S 16 0 0 S
++R H 1935 o - Jun 2 0 1 D
++R H 1935 o - S 30 0 0 S
++R H 1936 o - Jun 1 0 1 D
++R H 1936 o - S 14 0 0 S
++R H 1937 1938 - May Sun>=1 0 1 D
++R H 1937 1941 - S M>=24 0 0 S
++R H 1939 o - May 28 0 1 D
++R H 1940 1941 - May Sun>=1 0 1 D
++R H 1946 1949 - Ap lastSun 2 1 D
++R H 1946 1949 - S lastSun 2 0 S
++R H 1951 1954 - Ap lastSun 2 1 D
++R H 1951 1954 - S lastSun 2 0 S
++R H 1956 1959 - Ap lastSun 2 1 D
++R H 1956 1959 - S lastSun 2 0 S
++R H 1962 1973 - Ap lastSun 2 1 D
++R H 1962 1973 - O lastSun 2 0 S
+ Z America/Halifax -4:14:24 - LMT 1902 Jun 15
+--4 AW A%sT 1918
+--4 AU A%sT 1919
+--4 AW A%sT 1942 F 9 2s
+--4 AU A%sT 1946
+--4 AW A%sT 1974
+--4 AU A%sT
++-4 H A%sT 1918
++-4 C A%sT 1919
++-4 H A%sT 1942 F 9 2s
++-4 C A%sT 1946
++-4 H A%sT 1974
++-4 C A%sT
+ Z America/Glace_Bay -3:59:48 - LMT 1902 Jun 15
+--4 AU A%sT 1953
+--4 AW A%sT 1954
++-4 C A%sT 1953
++-4 H A%sT 1954
+ -4 - AST 1972
+--4 AW A%sT 1974
+--4 AU A%sT
+-R AX 1933 1935 - Jun Sun>=8 1 1 D
+-R AX 1933 1935 - S Sun>=8 1 0 S
+-R AX 1936 1938 - Jun Sun>=1 1 1 D
+-R AX 1936 1938 - S Sun>=1 1 0 S
+-R AX 1939 o - May 27 1 1 D
+-R AX 1939 1941 - S Sat>=21 1 0 S
+-R AX 1940 o - May 19 1 1 D
+-R AX 1941 o - May 4 1 1 D
+-R AX 1946 1972 - Ap lastSun 2 1 D
+-R AX 1946 1956 - S lastSun 2 0 S
+-R AX 1957 1972 - O lastSun 2 0 S
+-R AX 1993 2006 - Ap Sun>=1 0:1 1 D
+-R AX 1993 2006 - O lastSun 0:1 0 S
++-4 H A%sT 1974
++-4 C A%sT
++R o 1933 1935 - Jun Sun>=8 1 1 D
++R o 1933 1935 - S Sun>=8 1 0 S
++R o 1936 1938 - Jun Sun>=1 1 1 D
++R o 1936 1938 - S Sun>=1 1 0 S
++R o 1939 o - May 27 1 1 D
++R o 1939 1941 - S Sat>=21 1 0 S
++R o 1940 o - May 19 1 1 D
++R o 1941 o - May 4 1 1 D
++R o 1946 1972 - Ap lastSun 2 1 D
++R o 1946 1956 - S lastSun 2 0 S
++R o 1957 1972 - O lastSun 2 0 S
++R o 1993 2006 - Ap Sun>=1 0:1 1 D
++R o 1993 2006 - O lastSun 0:1 0 S
+ Z America/Moncton -4:19:8 - LMT 1883 D 9
+ -5 - EST 1902 Jun 15
+--4 AU A%sT 1933
+--4 AX A%sT 1942
+--4 AU A%sT 1946
+--4 AX A%sT 1973
+--4 AU A%sT 1993
+--4 AX A%sT 2007
+--4 AU A%sT
++-4 C A%sT 1933
++-4 o A%sT 1942
++-4 C A%sT 1946
++-4 o A%sT 1973
++-4 C A%sT 1993
++-4 o A%sT 2007
++-4 C A%sT
+ Z America/Blanc-Sablon -3:48:28 - LMT 1884
+--4 AU A%sT 1970
++-4 C A%sT 1970
+ -4 - AST
+-R AY 1919 o - Mar 30 23:30 1 D
+-R AY 1919 o - O 26 0 0 S
+-R AY 1920 o - May 2 2 1 D
+-R AY 1920 o - S 26 0 0 S
+-R AY 1921 o - May 15 2 1 D
+-R AY 1921 o - S 15 2 0 S
+-R AY 1922 1923 - May Sun>=8 2 1 D
+-R AY 1922 1926 - S Sun>=15 2 0 S
+-R AY 1924 1927 - May Sun>=1 2 1 D
+-R AY 1927 1932 - S lastSun 2 0 S
+-R AY 1928 1931 - Ap lastSun 2 1 D
+-R AY 1932 o - May 1 2 1 D
+-R AY 1933 1940 - Ap lastSun 2 1 D
+-R AY 1933 o - O 1 2 0 S
+-R AY 1934 1939 - S lastSun 2 0 S
+-R AY 1945 1946 - S lastSun 2 0 S
+-R AY 1946 o - Ap lastSun 2 1 D
+-R AY 1947 1949 - Ap lastSun 0 1 D
+-R AY 1947 1948 - S lastSun 0 0 S
+-R AY 1949 o - N lastSun 0 0 S
+-R AY 1950 1973 - Ap lastSun 2 1 D
+-R AY 1950 o - N lastSun 2 0 S
+-R AY 1951 1956 - S lastSun 2 0 S
+-R AY 1957 1973 - O lastSun 2 0 S
++R t 1919 o - Mar 30 23:30 1 D
++R t 1919 o - O 26 0 0 S
++R t 1920 o - May 2 2 1 D
++R t 1920 o - S 26 0 0 S
++R t 1921 o - May 15 2 1 D
++R t 1921 o - S 15 2 0 S
++R t 1922 1923 - May Sun>=8 2 1 D
++R t 1922 1926 - S Sun>=15 2 0 S
++R t 1924 1927 - May Sun>=1 2 1 D
++R t 1927 1932 - S lastSun 2 0 S
++R t 1928 1931 - Ap lastSun 2 1 D
++R t 1932 o - May 1 2 1 D
++R t 1933 1940 - Ap lastSun 2 1 D
++R t 1933 o - O 1 2 0 S
++R t 1934 1939 - S lastSun 2 0 S
++R t 1945 1946 - S lastSun 2 0 S
++R t 1946 o - Ap lastSun 2 1 D
++R t 1947 1949 - Ap lastSun 0 1 D
++R t 1947 1948 - S lastSun 0 0 S
++R t 1949 o - N lastSun 0 0 S
++R t 1950 1973 - Ap lastSun 2 1 D
++R t 1950 o - N lastSun 2 0 S
++R t 1951 1956 - S lastSun 2 0 S
++R t 1957 1973 - O lastSun 2 0 S
+ Z America/Toronto -5:17:32 - LMT 1895
+--5 AU E%sT 1919
+--5 AY E%sT 1942 F 9 2s
+--5 AU E%sT 1946
+--5 AY E%sT 1974
+--5 AU E%sT
++-5 C E%sT 1919
++-5 t E%sT 1942 F 9 2s
++-5 C E%sT 1946
++-5 t E%sT 1974
++-5 C E%sT
+ Z America/Thunder_Bay -5:57 - LMT 1895
+ -6 - CST 1910
+ -5 - EST 1942
+--5 AU E%sT 1970
+--5 AY E%sT 1973
++-5 C E%sT 1970
++-5 t E%sT 1973
+ -5 - EST 1974
+--5 AU E%sT
++-5 C E%sT
+ Z America/Nipigon -5:53:4 - LMT 1895
+--5 AU E%sT 1940 S 29
++-5 C E%sT 1940 S 29
+ -5 1 EDT 1942 F 9 2s
+--5 AU E%sT
++-5 C E%sT
+ Z America/Rainy_River -6:18:16 - LMT 1895
+--6 AU C%sT 1940 S 29
++-6 C C%sT 1940 S 29
+ -6 1 CDT 1942 F 9 2s
+--6 AU C%sT
++-6 C C%sT
+ Z America/Atikokan -6:6:28 - LMT 1895
+--6 AU C%sT 1940 S 29
++-6 C C%sT 1940 S 29
+ -6 1 CDT 1942 F 9 2s
+--6 AU C%sT 1945 S 30 2
++-6 C C%sT 1945 S 30 2
+ -5 - EST
+-R AZ 1916 o - Ap 23 0 1 D
+-R AZ 1916 o - S 17 0 0 S
+-R AZ 1918 o - Ap 14 2 1 D
+-R AZ 1918 o - O 27 2 0 S
+-R AZ 1937 o - May 16 2 1 D
+-R AZ 1937 o - S 26 2 0 S
+-R AZ 1942 o - F 9 2 1 W
+-R AZ 1945 o - Au 14 23u 1 P
+-R AZ 1945 o - S lastSun 2 0 S
+-R AZ 1946 o - May 12 2 1 D
+-R AZ 1946 o - O 13 2 0 S
+-R AZ 1947 1949 - Ap lastSun 2 1 D
+-R AZ 1947 1949 - S lastSun 2 0 S
+-R AZ 1950 o - May 1 2 1 D
+-R AZ 1950 o - S 30 2 0 S
+-R AZ 1951 1960 - Ap lastSun 2 1 D
+-R AZ 1951 1958 - S lastSun 2 0 S
+-R AZ 1959 o - O lastSun 2 0 S
+-R AZ 1960 o - S lastSun 2 0 S
+-R AZ 1963 o - Ap lastSun 2 1 D
+-R AZ 1963 o - S 22 2 0 S
+-R AZ 1966 1986 - Ap lastSun 2s 1 D
+-R AZ 1966 2005 - O lastSun 2s 0 S
+-R AZ 1987 2005 - Ap Sun>=1 2s 1 D
++R W 1916 o - Ap 23 0 1 D
++R W 1916 o - S 17 0 0 S
++R W 1918 o - Ap 14 2 1 D
++R W 1918 o - O 27 2 0 S
++R W 1937 o - May 16 2 1 D
++R W 1937 o - S 26 2 0 S
++R W 1942 o - F 9 2 1 W
++R W 1945 o - Au 14 23u 1 P
++R W 1945 o - S lastSun 2 0 S
++R W 1946 o - May 12 2 1 D
++R W 1946 o - O 13 2 0 S
++R W 1947 1949 - Ap lastSun 2 1 D
++R W 1947 1949 - S lastSun 2 0 S
++R W 1950 o - May 1 2 1 D
++R W 1950 o - S 30 2 0 S
++R W 1951 1960 - Ap lastSun 2 1 D
++R W 1951 1958 - S lastSun 2 0 S
++R W 1959 o - O lastSun 2 0 S
++R W 1960 o - S lastSun 2 0 S
++R W 1963 o - Ap lastSun 2 1 D
++R W 1963 o - S 22 2 0 S
++R W 1966 1986 - Ap lastSun 2s 1 D
++R W 1966 2005 - O lastSun 2s 0 S
++R W 1987 2005 - Ap Sun>=1 2s 1 D
+ Z America/Winnipeg -6:28:36 - LMT 1887 Jul 16
+--6 AZ C%sT 2006
+--6 AU C%sT
+-R Aa 1918 o - Ap 14 2 1 D
+-R Aa 1918 o - O 27 2 0 S
+-R Aa 1930 1934 - May Sun>=1 0 1 D
+-R Aa 1930 1934 - O Sun>=1 0 0 S
+-R Aa 1937 1941 - Ap Sun>=8 0 1 D
+-R Aa 1937 o - O Sun>=8 0 0 S
+-R Aa 1938 o - O Sun>=1 0 0 S
+-R Aa 1939 1941 - O Sun>=8 0 0 S
+-R Aa 1942 o - F 9 2 1 W
+-R Aa 1945 o - Au 14 23u 1 P
+-R Aa 1945 o - S lastSun 2 0 S
+-R Aa 1946 o - Ap Sun>=8 2 1 D
+-R Aa 1946 o - O Sun>=8 2 0 S
+-R Aa 1947 1957 - Ap lastSun 2 1 D
+-R Aa 1947 1957 - S lastSun 2 0 S
+-R Aa 1959 o - Ap lastSun 2 1 D
+-R Aa 1959 o - O lastSun 2 0 S
+-R Ab 1957 o - Ap lastSun 2 1 D
+-R Ab 1957 o - O lastSun 2 0 S
+-R Ab 1959 1961 - Ap lastSun 2 1 D
+-R Ab 1959 o - O lastSun 2 0 S
+-R Ab 1960 1961 - S lastSun 2 0 S
++-6 W C%sT 2006
++-6 C C%sT
++R r 1918 o - Ap 14 2 1 D
++R r 1918 o - O 27 2 0 S
++R r 1930 1934 - May Sun>=1 0 1 D
++R r 1930 1934 - O Sun>=1 0 0 S
++R r 1937 1941 - Ap Sun>=8 0 1 D
++R r 1937 o - O Sun>=8 0 0 S
++R r 1938 o - O Sun>=1 0 0 S
++R r 1939 1941 - O Sun>=8 0 0 S
++R r 1942 o - F 9 2 1 W
++R r 1945 o - Au 14 23u 1 P
++R r 1945 o - S lastSun 2 0 S
++R r 1946 o - Ap Sun>=8 2 1 D
++R r 1946 o - O Sun>=8 2 0 S
++R r 1947 1957 - Ap lastSun 2 1 D
++R r 1947 1957 - S lastSun 2 0 S
++R r 1959 o - Ap lastSun 2 1 D
++R r 1959 o - O lastSun 2 0 S
++R Sw 1957 o - Ap lastSun 2 1 D
++R Sw 1957 o - O lastSun 2 0 S
++R Sw 1959 1961 - Ap lastSun 2 1 D
++R Sw 1959 o - O lastSun 2 0 S
++R Sw 1960 1961 - S lastSun 2 0 S
+ Z America/Regina -6:58:36 - LMT 1905 S
+--7 Aa M%sT 1960 Ap lastSun 2
++-7 r M%sT 1960 Ap lastSun 2
+ -6 - CST
+ Z America/Swift_Current -7:11:20 - LMT 1905 S
+--7 AU M%sT 1946 Ap lastSun 2
+--7 Aa M%sT 1950
+--7 Ab M%sT 1972 Ap lastSun 2
++-7 C M%sT 1946 Ap lastSun 2
++-7 r M%sT 1950
++-7 Sw M%sT 1972 Ap lastSun 2
+ -6 - CST
+-R Ac 1918 1919 - Ap Sun>=8 2 1 D
+-R Ac 1918 o - O 27 2 0 S
+-R Ac 1919 o - May 27 2 0 S
+-R Ac 1920 1923 - Ap lastSun 2 1 D
+-R Ac 1920 o - O lastSun 2 0 S
+-R Ac 1921 1923 - S lastSun 2 0 S
+-R Ac 1942 o - F 9 2 1 W
+-R Ac 1945 o - Au 14 23u 1 P
+-R Ac 1945 o - S lastSun 2 0 S
+-R Ac 1947 o - Ap lastSun 2 1 D
+-R Ac 1947 o - S lastSun 2 0 S
+-R Ac 1967 o - Ap lastSun 2 1 D
+-R Ac 1967 o - O lastSun 2 0 S
+-R Ac 1969 o - Ap lastSun 2 1 D
+-R Ac 1969 o - O lastSun 2 0 S
+-R Ac 1972 1986 - Ap lastSun 2 1 D
+-R Ac 1972 2006 - O lastSun 2 0 S
++R Ed 1918 1919 - Ap Sun>=8 2 1 D
++R Ed 1918 o - O 27 2 0 S
++R Ed 1919 o - May 27 2 0 S
++R Ed 1920 1923 - Ap lastSun 2 1 D
++R Ed 1920 o - O lastSun 2 0 S
++R Ed 1921 1923 - S lastSun 2 0 S
++R Ed 1942 o - F 9 2 1 W
++R Ed 1945 o - Au 14 23u 1 P
++R Ed 1945 o - S lastSun 2 0 S
++R Ed 1947 o - Ap lastSun 2 1 D
++R Ed 1947 o - S lastSun 2 0 S
++R Ed 1967 o - Ap lastSun 2 1 D
++R Ed 1967 o - O lastSun 2 0 S
++R Ed 1969 o - Ap lastSun 2 1 D
++R Ed 1969 o - O lastSun 2 0 S
++R Ed 1972 1986 - Ap lastSun 2 1 D
++R Ed 1972 2006 - O lastSun 2 0 S
+ Z America/Edmonton -7:33:52 - LMT 1906 S
+--7 Ac M%sT 1987
+--7 AU M%sT
+-R Ad 1918 o - Ap 14 2 1 D
+-R Ad 1918 o - O 27 2 0 S
+-R Ad 1942 o - F 9 2 1 W
+-R Ad 1945 o - Au 14 23u 1 P
+-R Ad 1945 o - S 30 2 0 S
+-R Ad 1946 1986 - Ap lastSun 2 1 D
+-R Ad 1946 o - O 13 2 0 S
+-R Ad 1947 1961 - S lastSun 2 0 S
+-R Ad 1962 2006 - O lastSun 2 0 S
++-7 Ed M%sT 1987
++-7 C M%sT
++R Va 1918 o - Ap 14 2 1 D
++R Va 1918 o - O 27 2 0 S
++R Va 1942 o - F 9 2 1 W
++R Va 1945 o - Au 14 23u 1 P
++R Va 1945 o - S 30 2 0 S
++R Va 1946 1986 - Ap lastSun 2 1 D
++R Va 1946 o - O 13 2 0 S
++R Va 1947 1961 - S lastSun 2 0 S
++R Va 1962 2006 - O lastSun 2 0 S
+ Z America/Vancouver -8:12:28 - LMT 1884
+--8 Ad P%sT 1987
+--8 AU P%sT
++-8 Va P%sT 1987
++-8 C P%sT
+ Z America/Dawson_Creek -8:0:56 - LMT 1884
+--8 AU P%sT 1947
+--8 Ad P%sT 1972 Au 30 2
++-8 C P%sT 1947
++-8 Va P%sT 1972 Au 30 2
+ -7 - MST
+ Z America/Fort_Nelson -8:10:47 - LMT 1884
+--8 Ad P%sT 1946
++-8 Va P%sT 1946
+ -8 - PST 1947
+--8 Ad P%sT 1987
+--8 AU P%sT 2015 Mar 8 2
++-8 Va P%sT 1987
++-8 C P%sT 2015 Mar 8 2
+ -7 - MST
+ Z America/Creston -7:46:4 - LMT 1884
+ -7 - MST 1916 O
+ -8 - PST 1918 Jun 2
+ -7 - MST
+-R Ae 1918 o - Ap 14 2 1 D
+-R Ae 1918 o - O 27 2 0 S
+-R Ae 1919 o - May 25 2 1 D
+-R Ae 1919 o - N 1 0 0 S
+-R Ae 1942 o - F 9 2 1 W
+-R Ae 1945 o - Au 14 23u 1 P
+-R Ae 1945 o - S 30 2 0 S
+-R Ae 1965 o - Ap lastSun 0 2 DD
+-R Ae 1965 o - O lastSun 2 0 S
+-R Ae 1980 1986 - Ap lastSun 2 1 D
+-R Ae 1980 2006 - O lastSun 2 0 S
+-R Ae 1987 2006 - Ap Sun>=1 2 1 D
++R Y 1918 o - Ap 14 2 1 D
++R Y 1918 o - O 27 2 0 S
++R Y 1919 o - May 25 2 1 D
++R Y 1919 o - N 1 0 0 S
++R Y 1942 o - F 9 2 1 W
++R Y 1945 o - Au 14 23u 1 P
++R Y 1945 o - S 30 2 0 S
++R Y 1965 o - Ap lastSun 0 2 DD
++R Y 1965 o - O lastSun 2 0 S
++R Y 1980 1986 - Ap lastSun 2 1 D
++R Y 1980 2006 - O lastSun 2 0 S
++R Y 1987 2006 - Ap Sun>=1 2 1 D
+ Z America/Pangnirtung 0 - -00 1921
+--4 Ae A%sT 1995 Ap Sun>=1 2
+--5 AU E%sT 1999 O 31 2
+--6 AU C%sT 2000 O 29 2
+--5 AU E%sT
++-4 Y A%sT 1995 Ap Sun>=1 2
++-5 C E%sT 1999 O 31 2
++-6 C C%sT 2000 O 29 2
++-5 C E%sT
+ Z America/Iqaluit 0 - -00 1942 Au
+--5 Ae E%sT 1999 O 31 2
+--6 AU C%sT 2000 O 29 2
+--5 AU E%sT
++-5 Y E%sT 1999 O 31 2
++-6 C C%sT 2000 O 29 2
++-5 C E%sT
+ Z America/Resolute 0 - -00 1947 Au 31
+--6 Ae C%sT 2000 O 29 2
++-6 Y C%sT 2000 O 29 2
+ -5 - EST 2001 Ap 1 3
+--6 AU C%sT 2006 O 29 2
++-6 C C%sT 2006 O 29 2
+ -5 - EST 2007 Mar 11 3
+--6 AU C%sT
++-6 C C%sT
+ Z America/Rankin_Inlet 0 - -00 1957
+--6 Ae C%sT 2000 O 29 2
++-6 Y C%sT 2000 O 29 2
+ -5 - EST 2001 Ap 1 3
+--6 AU C%sT
++-6 C C%sT
+ Z America/Cambridge_Bay 0 - -00 1920
+--7 Ae M%sT 1999 O 31 2
+--6 AU C%sT 2000 O 29 2
++-7 Y M%sT 1999 O 31 2
++-6 C C%sT 2000 O 29 2
+ -5 - EST 2000 N 5
+ -6 - CST 2001 Ap 1 3
+--7 AU M%sT
++-7 C M%sT
+ Z America/Yellowknife 0 - -00 1935
+--7 Ae M%sT 1980
+--7 AU M%sT
++-7 Y M%sT 1980
++-7 C M%sT
+ Z America/Inuvik 0 - -00 1953
+--8 Ae P%sT 1979 Ap lastSun 2
+--7 Ae M%sT 1980
+--7 AU M%sT
++-8 Y P%sT 1979 Ap lastSun 2
++-7 Y M%sT 1980
++-7 C M%sT
+ Z America/Whitehorse -9:0:12 - LMT 1900 Au 20
+--9 Ae Y%sT 1967 May 28
+--8 Ae P%sT 1980
+--8 AU P%sT
++-9 Y Y%sT 1967 May 28
++-8 Y P%sT 1980
++-8 C P%sT
+ Z America/Dawson -9:17:40 - LMT 1900 Au 20
+--9 Ae Y%sT 1973 O 28
+--8 Ae P%sT 1980
+--8 AU P%sT
+-R Af 1939 o - F 5 0 1 D
+-R Af 1939 o - Jun 25 0 0 S
+-R Af 1940 o - D 9 0 1 D
+-R Af 1941 o - Ap 1 0 0 S
+-R Af 1943 o - D 16 0 1 W
+-R Af 1944 o - May 1 0 0 S
+-R Af 1950 o - F 12 0 1 D
+-R Af 1950 o - Jul 30 0 0 S
+-R Af 1996 2000 - Ap Sun>=1 2 1 D
+-R Af 1996 2000 - O lastSun 2 0 S
+-R Af 2001 o - May Sun>=1 2 1 D
+-R Af 2001 o - S lastSun 2 0 S
+-R Af 2002 ma - Ap Sun>=1 2 1 D
+-R Af 2002 ma - O lastSun 2 0 S
++-9 Y Y%sT 1973 O 28
++-8 Y P%sT 1980
++-8 C P%sT
++R m 1939 o - F 5 0 1 D
++R m 1939 o - Jun 25 0 0 S
++R m 1940 o - D 9 0 1 D
++R m 1941 o - Ap 1 0 0 S
++R m 1943 o - D 16 0 1 W
++R m 1944 o - May 1 0 0 S
++R m 1950 o - F 12 0 1 D
++R m 1950 o - Jul 30 0 0 S
++R m 1996 2000 - Ap Sun>=1 2 1 D
++R m 1996 2000 - O lastSun 2 0 S
++R m 2001 o - May Sun>=1 2 1 D
++R m 2001 o - S lastSun 2 0 S
++R m 2002 ma - Ap Sun>=1 2 1 D
++R m 2002 ma - O lastSun 2 0 S
+ Z America/Cancun -5:47:4 - LMT 1922 Ja 1 0:12:56
+ -6 - CST 1981 D 23
+--5 Af E%sT 1998 Au 2 2
+--6 Af C%sT 2015 F 1 2
++-5 m E%sT 1998 Au 2 2
++-6 m C%sT 2015 F 1 2
+ -5 - EST
+ Z America/Merida -5:58:28 - LMT 1922 Ja 1 0:1:32
+ -6 - CST 1981 D 23
+ -5 - EST 1982 D 2
+--6 Af C%sT
++-6 m C%sT
+ Z America/Matamoros -6:40 - LMT 1921 D 31 23:20
+ -6 - CST 1988
+--6 AF C%sT 1989
+--6 Af C%sT 2010
+--6 AF C%sT
++-6 u C%sT 1989
++-6 m C%sT 2010
++-6 u C%sT
+ Z America/Monterrey -6:41:16 - LMT 1921 D 31 23:18:44
+ -6 - CST 1988
+--6 AF C%sT 1989
+--6 Af C%sT
++-6 u C%sT 1989
++-6 m C%sT
+ Z America/Mexico_City -6:36:36 - LMT 1922 Ja 1 0:23:24
+ -7 - MST 1927 Jun 10 23
+ -6 - CST 1930 N 15
+ -7 - MST 1931 May 1 23
+ -6 - CST 1931 O
+ -7 - MST 1932 Ap
+--6 Af C%sT 2001 S 30 2
++-6 m C%sT 2001 S 30 2
+ -6 - CST 2002 F 20
+--6 Af C%sT
++-6 m C%sT
+ Z America/Ojinaga -6:57:40 - LMT 1922 Ja 1 0:2:20
+ -7 - MST 1927 Jun 10 23
+ -6 - CST 1930 N 15
+@@ -3215,10 +3232,10 @@ Z America/Ojinaga -6:57:40 - LMT 1922 Ja 1 0:2:20
+ -6 - CST 1931 O
+ -7 - MST 1932 Ap
+ -6 - CST 1996
+--6 Af C%sT 1998
++-6 m C%sT 1998
+ -6 - CST 1998 Ap Sun>=1 3
+--7 Af M%sT 2010
+--7 AF M%sT
++-7 m M%sT 2010
++-7 u M%sT
+ Z America/Chihuahua -7:4:20 - LMT 1921 D 31 23:55:40
+ -7 - MST 1927 Jun 10 23
+ -6 - CST 1930 N 15
+@@ -3226,9 +3243,9 @@ Z America/Chihuahua -7:4:20 - LMT 1921 D 31 23:55:40
+ -6 - CST 1931 O
+ -7 - MST 1932 Ap
+ -6 - CST 1996
+--6 Af C%sT 1998
++-6 m C%sT 1998
+ -6 - CST 1998 Ap Sun>=1 3
+--7 Af M%sT
++-7 m M%sT
+ Z America/Hermosillo -7:23:52 - LMT 1921 D 31 23:36:8
+ -7 - MST 1927 Jun 10 23
+ -6 - CST 1930 N 15
+@@ -3238,7 +3255,7 @@ Z America/Hermosillo -7:23:52 - LMT 1921 D 31 23:36:8
+ -6 - CST 1942 Ap 24
+ -7 - MST 1949 Ja 14
+ -8 - PST 1970
+--7 Af M%sT 1999
++-7 m M%sT 1999
+ -7 - MST
+ Z America/Mazatlan -7:5:40 - LMT 1921 D 31 23:54:20
+ -7 - MST 1927 Jun 10 23
+@@ -3249,7 +3266,7 @@ Z America/Mazatlan -7:5:40 - LMT 1921 D 31 23:54:20
+ -6 - CST 1942 Ap 24
+ -7 - MST 1949 Ja 14
+ -8 - PST 1970
+--7 Af M%sT
++-7 m M%sT
+ Z America/Bahia_Banderas -7:1 - LMT 1921 D 31 23:59
+ -7 - MST 1927 Jun 10 23
+ -6 - CST 1930 N 15
+@@ -3259,8 +3276,8 @@ Z America/Bahia_Banderas -7:1 - LMT 1921 D 31 23:59
+ -6 - CST 1942 Ap 24
+ -7 - MST 1949 Ja 14
+ -8 - PST 1970
+--7 Af M%sT 2010 Ap 4 2
+--6 Af C%sT
++-7 m M%sT 2010 Ap 4 2
++-6 m C%sT
+ Z America/Tijuana -7:48:4 - LMT 1922 Ja 1 0:11:56
+ -7 - MST 1924
+ -8 - PST 1927 Jun 10 23
+@@ -3273,315 +3290,315 @@ Z America/Tijuana -7:48:4 - LMT 1922 Ja 1 0:11:56
+ -8 - PST 1948 Ap 5
+ -8 1 PDT 1949 Ja 14
+ -8 - PST 1954
+--8 AJ P%sT 1961
++-8 CA P%sT 1961
+ -8 - PST 1976
+--8 AF P%sT 1996
+--8 Af P%sT 2001
+--8 AF P%sT 2002 F 20
+--8 Af P%sT 2010
+--8 AF P%sT
+-R Ag 1964 1975 - O lastSun 2 0 S
+-R Ag 1964 1975 - Ap lastSun 2 1 D
++-8 u P%sT 1996
++-8 m P%sT 2001
++-8 u P%sT 2002 F 20
++-8 m P%sT 2010
++-8 u P%sT
++R BS 1964 1975 - O lastSun 2 0 S
++R BS 1964 1975 - Ap lastSun 2 1 D
+ Z America/Nassau -5:9:30 - LMT 1912 Mar 2
+--5 Ag E%sT 1976
+--5 AF E%sT
+-R Ah 1977 o - Jun 12 2 1 D
+-R Ah 1977 1978 - O Sun>=1 2 0 S
+-R Ah 1978 1980 - Ap Sun>=15 2 1 D
+-R Ah 1979 o - S 30 2 0 S
+-R Ah 1980 o - S 25 2 0 S
++-5 BS E%sT 1976
++-5 u E%sT
++R BB 1977 o - Jun 12 2 1 D
++R BB 1977 1978 - O Sun>=1 2 0 S
++R BB 1978 1980 - Ap Sun>=15 2 1 D
++R BB 1979 o - S 30 2 0 S
++R BB 1980 o - S 25 2 0 S
+ Z America/Barbados -3:58:29 - LMT 1924
+ -3:58:29 - BMT 1932
+--4 Ah A%sT
+-R Ai 1918 1942 - O Sun>=2 0 0:30 -0530
+-R Ai 1919 1943 - F Sun>=9 0 0 CST
+-R Ai 1973 o - D 5 0 1 CDT
+-R Ai 1974 o - F 9 0 0 CST
+-R Ai 1982 o - D 18 0 1 CDT
+-R Ai 1983 o - F 12 0 0 CST
++-4 BB A%sT
++R BZ 1918 1942 - O Sun>=2 0 0:30 -0530
++R BZ 1919 1943 - F Sun>=9 0 0 CST
++R BZ 1973 o - D 5 0 1 CDT
++R BZ 1974 o - F 9 0 0 CST
++R BZ 1982 o - D 18 0 1 CDT
++R BZ 1983 o - F 12 0 0 CST
+ Z America/Belize -5:52:48 - LMT 1912 Ap
+--6 Ai %s
++-6 BZ %s
+ Z Atlantic/Bermuda -4:19:18 - LMT 1930 Ja 1 2
+ -4 - AST 1974 Ap 28 2
+--4 AU A%sT 1976
+--4 AF A%sT
+-R Aj 1979 1980 - F lastSun 0 1 D
+-R Aj 1979 1980 - Jun Sun>=1 0 0 S
+-R Aj 1991 1992 - Ja Sat>=15 0 1 D
+-R Aj 1991 o - Jul 1 0 0 S
+-R Aj 1992 o - Mar 15 0 0 S
++-4 C A%sT 1976
++-4 u A%sT
++R CR 1979 1980 - F lastSun 0 1 D
++R CR 1979 1980 - Jun Sun>=1 0 0 S
++R CR 1991 1992 - Ja Sat>=15 0 1 D
++R CR 1991 o - Jul 1 0 0 S
++R CR 1992 o - Mar 15 0 0 S
+ Z America/Costa_Rica -5:36:13 - LMT 1890
+ -5:36:13 - SJMT 1921 Ja 15
+--6 Aj C%sT
+-R Ak 1928 o - Jun 10 0 1 D
+-R Ak 1928 o - O 10 0 0 S
+-R Ak 1940 1942 - Jun Sun>=1 0 1 D
+-R Ak 1940 1942 - S Sun>=1 0 0 S
+-R Ak 1945 1946 - Jun Sun>=1 0 1 D
+-R Ak 1945 1946 - S Sun>=1 0 0 S
+-R Ak 1965 o - Jun 1 0 1 D
+-R Ak 1965 o - S 30 0 0 S
+-R Ak 1966 o - May 29 0 1 D
+-R Ak 1966 o - O 2 0 0 S
+-R Ak 1967 o - Ap 8 0 1 D
+-R Ak 1967 1968 - S Sun>=8 0 0 S
+-R Ak 1968 o - Ap 14 0 1 D
+-R Ak 1969 1977 - Ap lastSun 0 1 D
+-R Ak 1969 1971 - O lastSun 0 0 S
+-R Ak 1972 1974 - O 8 0 0 S
+-R Ak 1975 1977 - O lastSun 0 0 S
+-R Ak 1978 o - May 7 0 1 D
+-R Ak 1978 1990 - O Sun>=8 0 0 S
+-R Ak 1979 1980 - Mar Sun>=15 0 1 D
+-R Ak 1981 1985 - May Sun>=5 0 1 D
+-R Ak 1986 1989 - Mar Sun>=14 0 1 D
+-R Ak 1990 1997 - Ap Sun>=1 0 1 D
+-R Ak 1991 1995 - O Sun>=8 0s 0 S
+-R Ak 1996 o - O 6 0s 0 S
+-R Ak 1997 o - O 12 0s 0 S
+-R Ak 1998 1999 - Mar lastSun 0s 1 D
+-R Ak 1998 2003 - O lastSun 0s 0 S
+-R Ak 2000 2003 - Ap Sun>=1 0s 1 D
+-R Ak 2004 o - Mar lastSun 0s 1 D
+-R Ak 2006 2010 - O lastSun 0s 0 S
+-R Ak 2007 o - Mar Sun>=8 0s 1 D
+-R Ak 2008 o - Mar Sun>=15 0s 1 D
+-R Ak 2009 2010 - Mar Sun>=8 0s 1 D
+-R Ak 2011 o - Mar Sun>=15 0s 1 D
+-R Ak 2011 o - N 13 0s 0 S
+-R Ak 2012 o - Ap 1 0s 1 D
+-R Ak 2012 ma - N Sun>=1 0s 0 S
+-R Ak 2013 ma - Mar Sun>=8 0s 1 D
++-6 CR C%sT
++R Q 1928 o - Jun 10 0 1 D
++R Q 1928 o - O 10 0 0 S
++R Q 1940 1942 - Jun Sun>=1 0 1 D
++R Q 1940 1942 - S Sun>=1 0 0 S
++R Q 1945 1946 - Jun Sun>=1 0 1 D
++R Q 1945 1946 - S Sun>=1 0 0 S
++R Q 1965 o - Jun 1 0 1 D
++R Q 1965 o - S 30 0 0 S
++R Q 1966 o - May 29 0 1 D
++R Q 1966 o - O 2 0 0 S
++R Q 1967 o - Ap 8 0 1 D
++R Q 1967 1968 - S Sun>=8 0 0 S
++R Q 1968 o - Ap 14 0 1 D
++R Q 1969 1977 - Ap lastSun 0 1 D
++R Q 1969 1971 - O lastSun 0 0 S
++R Q 1972 1974 - O 8 0 0 S
++R Q 1975 1977 - O lastSun 0 0 S
++R Q 1978 o - May 7 0 1 D
++R Q 1978 1990 - O Sun>=8 0 0 S
++R Q 1979 1980 - Mar Sun>=15 0 1 D
++R Q 1981 1985 - May Sun>=5 0 1 D
++R Q 1986 1989 - Mar Sun>=14 0 1 D
++R Q 1990 1997 - Ap Sun>=1 0 1 D
++R Q 1991 1995 - O Sun>=8 0s 0 S
++R Q 1996 o - O 6 0s 0 S
++R Q 1997 o - O 12 0s 0 S
++R Q 1998 1999 - Mar lastSun 0s 1 D
++R Q 1998 2003 - O lastSun 0s 0 S
++R Q 2000 2003 - Ap Sun>=1 0s 1 D
++R Q 2004 o - Mar lastSun 0s 1 D
++R Q 2006 2010 - O lastSun 0s 0 S
++R Q 2007 o - Mar Sun>=8 0s 1 D
++R Q 2008 o - Mar Sun>=15 0s 1 D
++R Q 2009 2010 - Mar Sun>=8 0s 1 D
++R Q 2011 o - Mar Sun>=15 0s 1 D
++R Q 2011 o - N 13 0s 0 S
++R Q 2012 o - Ap 1 0s 1 D
++R Q 2012 ma - N Sun>=1 0s 0 S
++R Q 2013 ma - Mar Sun>=8 0s 1 D
+ Z America/Havana -5:29:28 - LMT 1890
+ -5:29:36 - HMT 1925 Jul 19 12
+--5 Ak C%sT
+-R Al 1966 o - O 30 0 1 EDT
+-R Al 1967 o - F 28 0 0 EST
+-R Al 1969 1973 - O lastSun 0 0:30 -0430
+-R Al 1970 o - F 21 0 0 EST
+-R Al 1971 o - Ja 20 0 0 EST
+-R Al 1972 1974 - Ja 21 0 0 EST
++-5 Q C%sT
++R DO 1966 o - O 30 0 1 EDT
++R DO 1967 o - F 28 0 0 EST
++R DO 1969 1973 - O lastSun 0 0:30 -0430
++R DO 1970 o - F 21 0 0 EST
++R DO 1971 o - Ja 20 0 0 EST
++R DO 1972 1974 - Ja 21 0 0 EST
+ Z America/Santo_Domingo -4:39:36 - LMT 1890
+ -4:40 - SDMT 1933 Ap 1 12
+--5 Al %s 1974 O 27
++-5 DO %s 1974 O 27
+ -4 - AST 2000 O 29 2
+--5 AF E%sT 2000 D 3 1
++-5 u E%sT 2000 D 3 1
+ -4 - AST
+-R Am 1987 1988 - May Sun>=1 0 1 D
+-R Am 1987 1988 - S lastSun 0 0 S
++R SV 1987 1988 - May Sun>=1 0 1 D
++R SV 1987 1988 - S lastSun 0 0 S
+ Z America/El_Salvador -5:56:48 - LMT 1921
+--6 Am C%sT
+-R An 1973 o - N 25 0 1 D
+-R An 1974 o - F 24 0 0 S
+-R An 1983 o - May 21 0 1 D
+-R An 1983 o - S 22 0 0 S
+-R An 1991 o - Mar 23 0 1 D
+-R An 1991 o - S 7 0 0 S
+-R An 2006 o - Ap 30 0 1 D
+-R An 2006 o - O 1 0 0 S
++-6 SV C%sT
++R GT 1973 o - N 25 0 1 D
++R GT 1974 o - F 24 0 0 S
++R GT 1983 o - May 21 0 1 D
++R GT 1983 o - S 22 0 0 S
++R GT 1991 o - Mar 23 0 1 D
++R GT 1991 o - S 7 0 0 S
++R GT 2006 o - Ap 30 0 1 D
++R GT 2006 o - O 1 0 0 S
+ Z America/Guatemala -6:2:4 - LMT 1918 O 5
+--6 An C%sT
+-R Ao 1983 o - May 8 0 1 D
+-R Ao 1984 1987 - Ap lastSun 0 1 D
+-R Ao 1983 1987 - O lastSun 0 0 S
+-R Ao 1988 1997 - Ap Sun>=1 1s 1 D
+-R Ao 1988 1997 - O lastSun 1s 0 S
+-R Ao 2005 2006 - Ap Sun>=1 0 1 D
+-R Ao 2005 2006 - O lastSun 0 0 S
+-R Ao 2012 2015 - Mar Sun>=8 2 1 D
+-R Ao 2012 2015 - N Sun>=1 2 0 S
+-R Ao 2017 ma - Mar Sun>=8 2 1 D
+-R Ao 2017 ma - N Sun>=1 2 0 S
++-6 GT C%sT
++R HT 1983 o - May 8 0 1 D
++R HT 1984 1987 - Ap lastSun 0 1 D
++R HT 1983 1987 - O lastSun 0 0 S
++R HT 1988 1997 - Ap Sun>=1 1s 1 D
++R HT 1988 1997 - O lastSun 1s 0 S
++R HT 2005 2006 - Ap Sun>=1 0 1 D
++R HT 2005 2006 - O lastSun 0 0 S
++R HT 2012 2015 - Mar Sun>=8 2 1 D
++R HT 2012 2015 - N Sun>=1 2 0 S
++R HT 2017 ma - Mar Sun>=8 2 1 D
++R HT 2017 ma - N Sun>=1 2 0 S
+ Z America/Port-au-Prince -4:49:20 - LMT 1890
+ -4:49 - PPMT 1917 Ja 24 12
+--5 Ao E%sT
+-R Ap 1987 1988 - May Sun>=1 0 1 D
+-R Ap 1987 1988 - S lastSun 0 0 S
+-R Ap 2006 o - May Sun>=1 0 1 D
+-R Ap 2006 o - Au M>=1 0 0 S
++-5 HT E%sT
++R HN 1987 1988 - May Sun>=1 0 1 D
++R HN 1987 1988 - S lastSun 0 0 S
++R HN 2006 o - May Sun>=1 0 1 D
++R HN 2006 o - Au M>=1 0 0 S
+ Z America/Tegucigalpa -5:48:52 - LMT 1921 Ap
+--6 Ap C%sT
++-6 HN C%sT
+ Z America/Jamaica -5:7:10 - LMT 1890
+ -5:7:10 - KMT 1912 F
+ -5 - EST 1974
+--5 AF E%sT 1984
++-5 u E%sT 1984
+ -5 - EST
+ Z America/Martinique -4:4:20 - LMT 1890
+ -4:4:20 - FFMT 1911 May
+ -4 - AST 1980 Ap 6
+ -4 1 ADT 1980 S 28
+ -4 - AST
+-R Aq 1979 1980 - Mar Sun>=16 0 1 D
+-R Aq 1979 1980 - Jun M>=23 0 0 S
+-R Aq 2005 o - Ap 10 0 1 D
+-R Aq 2005 o - O Sun>=1 0 0 S
+-R Aq 2006 o - Ap 30 2 1 D
+-R Aq 2006 o - O Sun>=1 1 0 S
++R NI 1979 1980 - Mar Sun>=16 0 1 D
++R NI 1979 1980 - Jun M>=23 0 0 S
++R NI 2005 o - Ap 10 0 1 D
++R NI 2005 o - O Sun>=1 0 0 S
++R NI 2006 o - Ap 30 2 1 D
++R NI 2006 o - O Sun>=1 1 0 S
+ Z America/Managua -5:45:8 - LMT 1890
+ -5:45:12 - MMT 1934 Jun 23
+ -6 - CST 1973 May
+ -5 - EST 1975 F 16
+--6 Aq C%sT 1992 Ja 1 4
++-6 NI C%sT 1992 Ja 1 4
+ -5 - EST 1992 S 24
+ -6 - CST 1993
+ -5 - EST 1997
+--6 Aq C%sT
++-6 NI C%sT
+ Z America/Panama -5:18:8 - LMT 1890
+ -5:19:36 - CMT 1908 Ap 22
+ -5 - EST
+ Li America/Panama America/Cayman
+ Z America/Puerto_Rico -4:24:25 - LMT 1899 Mar 28 12
+ -4 - AST 1942 May 3
+--4 AF A%sT 1946
++-4 u A%sT 1946
+ -4 - AST
+ Z America/Miquelon -3:44:40 - LMT 1911 May 15
+ -4 - AST 1980 May
+ -3 - -03 1987
+--3 AU -03/-02
++-3 C -03/-02
+ Z America/Grand_Turk -4:44:32 - LMT 1890
+ -5:7:10 - KMT 1912 F
+ -5 - EST 1979
+--5 AF E%sT 2015 N Sun>=1 2
++-5 u E%sT 2015 N Sun>=1 2
+ -4 - AST 2018 Mar 11 3
+--5 AF E%sT
+-R Ar 1930 o - D 1 0 1 -
+-R Ar 1931 o - Ap 1 0 0 -
+-R Ar 1931 o - O 15 0 1 -
+-R Ar 1932 1940 - Mar 1 0 0 -
+-R Ar 1932 1939 - N 1 0 1 -
+-R Ar 1940 o - Jul 1 0 1 -
+-R Ar 1941 o - Jun 15 0 0 -
+-R Ar 1941 o - O 15 0 1 -
+-R Ar 1943 o - Au 1 0 0 -
+-R Ar 1943 o - O 15 0 1 -
+-R Ar 1946 o - Mar 1 0 0 -
+-R Ar 1946 o - O 1 0 1 -
+-R Ar 1963 o - O 1 0 0 -
+-R Ar 1963 o - D 15 0 1 -
+-R Ar 1964 1966 - Mar 1 0 0 -
+-R Ar 1964 1966 - O 15 0 1 -
+-R Ar 1967 o - Ap 2 0 0 -
+-R Ar 1967 1968 - O Sun>=1 0 1 -
+-R Ar 1968 1969 - Ap Sun>=1 0 0 -
+-R Ar 1974 o - Ja 23 0 1 -
+-R Ar 1974 o - May 1 0 0 -
+-R Ar 1988 o - D 1 0 1 -
+-R Ar 1989 1993 - Mar Sun>=1 0 0 -
+-R Ar 1989 1992 - O Sun>=15 0 1 -
+-R Ar 1999 o - O Sun>=1 0 1 -
+-R Ar 2000 o - Mar 3 0 0 -
+-R Ar 2007 o - D 30 0 1 -
+-R Ar 2008 2009 - Mar Sun>=15 0 0 -
+-R Ar 2008 o - O Sun>=15 0 1 -
++-5 u E%sT
++R A 1930 o - D 1 0 1 -
++R A 1931 o - Ap 1 0 0 -
++R A 1931 o - O 15 0 1 -
++R A 1932 1940 - Mar 1 0 0 -
++R A 1932 1939 - N 1 0 1 -
++R A 1940 o - Jul 1 0 1 -
++R A 1941 o - Jun 15 0 0 -
++R A 1941 o - O 15 0 1 -
++R A 1943 o - Au 1 0 0 -
++R A 1943 o - O 15 0 1 -
++R A 1946 o - Mar 1 0 0 -
++R A 1946 o - O 1 0 1 -
++R A 1963 o - O 1 0 0 -
++R A 1963 o - D 15 0 1 -
++R A 1964 1966 - Mar 1 0 0 -
++R A 1964 1966 - O 15 0 1 -
++R A 1967 o - Ap 2 0 0 -
++R A 1967 1968 - O Sun>=1 0 1 -
++R A 1968 1969 - Ap Sun>=1 0 0 -
++R A 1974 o - Ja 23 0 1 -
++R A 1974 o - May 1 0 0 -
++R A 1988 o - D 1 0 1 -
++R A 1989 1993 - Mar Sun>=1 0 0 -
++R A 1989 1992 - O Sun>=15 0 1 -
++R A 1999 o - O Sun>=1 0 1 -
++R A 2000 o - Mar 3 0 0 -
++R A 2007 o - D 30 0 1 -
++R A 2008 2009 - Mar Sun>=15 0 0 -
++R A 2008 o - O Sun>=15 0 1 -
+ Z America/Argentina/Buenos_Aires -3:53:48 - LMT 1894 O 31
+ -4:16:48 - CMT 1920 May
+ -4 - -04 1930 D
+--4 Ar -04/-03 1969 O 5
+--3 Ar -03/-02 1999 O 3
+--4 Ar -04/-03 2000 Mar 3
+--3 Ar -03/-02
++-4 A -04/-03 1969 O 5
++-3 A -03/-02 1999 O 3
++-4 A -04/-03 2000 Mar 3
++-3 A -03/-02
+ Z America/Argentina/Cordoba -4:16:48 - LMT 1894 O 31
+ -4:16:48 - CMT 1920 May
+ -4 - -04 1930 D
+--4 Ar -04/-03 1969 O 5
+--3 Ar -03/-02 1991 Mar 3
++-4 A -04/-03 1969 O 5
++-3 A -03/-02 1991 Mar 3
+ -4 - -04 1991 O 20
+--3 Ar -03/-02 1999 O 3
+--4 Ar -04/-03 2000 Mar 3
+--3 Ar -03/-02
++-3 A -03/-02 1999 O 3
++-4 A -04/-03 2000 Mar 3
++-3 A -03/-02
+ Z America/Argentina/Salta -4:21:40 - LMT 1894 O 31
+ -4:16:48 - CMT 1920 May
+ -4 - -04 1930 D
+--4 Ar -04/-03 1969 O 5
+--3 Ar -03/-02 1991 Mar 3
++-4 A -04/-03 1969 O 5
++-3 A -03/-02 1991 Mar 3
+ -4 - -04 1991 O 20
+--3 Ar -03/-02 1999 O 3
+--4 Ar -04/-03 2000 Mar 3
+--3 Ar -03/-02 2008 O 18
++-3 A -03/-02 1999 O 3
++-4 A -04/-03 2000 Mar 3
++-3 A -03/-02 2008 O 18
+ -3 - -03
+ Z America/Argentina/Tucuman -4:20:52 - LMT 1894 O 31
+ -4:16:48 - CMT 1920 May
+ -4 - -04 1930 D
+--4 Ar -04/-03 1969 O 5
+--3 Ar -03/-02 1991 Mar 3
++-4 A -04/-03 1969 O 5
++-3 A -03/-02 1991 Mar 3
+ -4 - -04 1991 O 20
+--3 Ar -03/-02 1999 O 3
+--4 Ar -04/-03 2000 Mar 3
++-3 A -03/-02 1999 O 3
++-4 A -04/-03 2000 Mar 3
+ -3 - -03 2004 Jun
+ -4 - -04 2004 Jun 13
+--3 Ar -03/-02
++-3 A -03/-02
+ Z America/Argentina/La_Rioja -4:27:24 - LMT 1894 O 31
+ -4:16:48 - CMT 1920 May
+ -4 - -04 1930 D
+--4 Ar -04/-03 1969 O 5
+--3 Ar -03/-02 1991 Mar
++-4 A -04/-03 1969 O 5
++-3 A -03/-02 1991 Mar
+ -4 - -04 1991 May 7
+--3 Ar -03/-02 1999 O 3
+--4 Ar -04/-03 2000 Mar 3
++-3 A -03/-02 1999 O 3
++-4 A -04/-03 2000 Mar 3
+ -3 - -03 2004 Jun
+ -4 - -04 2004 Jun 20
+--3 Ar -03/-02 2008 O 18
++-3 A -03/-02 2008 O 18
+ -3 - -03
+ Z America/Argentina/San_Juan -4:34:4 - LMT 1894 O 31
+ -4:16:48 - CMT 1920 May
+ -4 - -04 1930 D
+--4 Ar -04/-03 1969 O 5
+--3 Ar -03/-02 1991 Mar
++-4 A -04/-03 1969 O 5
++-3 A -03/-02 1991 Mar
+ -4 - -04 1991 May 7
+--3 Ar -03/-02 1999 O 3
+--4 Ar -04/-03 2000 Mar 3
++-3 A -03/-02 1999 O 3
++-4 A -04/-03 2000 Mar 3
+ -3 - -03 2004 May 31
+ -4 - -04 2004 Jul 25
+--3 Ar -03/-02 2008 O 18
++-3 A -03/-02 2008 O 18
+ -3 - -03
+ Z America/Argentina/Jujuy -4:21:12 - LMT 1894 O 31
+ -4:16:48 - CMT 1920 May
+ -4 - -04 1930 D
+--4 Ar -04/-03 1969 O 5
+--3 Ar -03/-02 1990 Mar 4
++-4 A -04/-03 1969 O 5
++-3 A -03/-02 1990 Mar 4
+ -4 - -04 1990 O 28
+ -4 1 -03 1991 Mar 17
+ -4 - -04 1991 O 6
+ -3 1 -02 1992
+--3 Ar -03/-02 1999 O 3
+--4 Ar -04/-03 2000 Mar 3
+--3 Ar -03/-02 2008 O 18
++-3 A -03/-02 1999 O 3
++-4 A -04/-03 2000 Mar 3
++-3 A -03/-02 2008 O 18
+ -3 - -03
+ Z America/Argentina/Catamarca -4:23:8 - LMT 1894 O 31
+ -4:16:48 - CMT 1920 May
+ -4 - -04 1930 D
+--4 Ar -04/-03 1969 O 5
+--3 Ar -03/-02 1991 Mar 3
++-4 A -04/-03 1969 O 5
++-3 A -03/-02 1991 Mar 3
+ -4 - -04 1991 O 20
+--3 Ar -03/-02 1999 O 3
+--4 Ar -04/-03 2000 Mar 3
++-3 A -03/-02 1999 O 3
++-4 A -04/-03 2000 Mar 3
+ -3 - -03 2004 Jun
+ -4 - -04 2004 Jun 20
+--3 Ar -03/-02 2008 O 18
++-3 A -03/-02 2008 O 18
+ -3 - -03
+ Z America/Argentina/Mendoza -4:35:16 - LMT 1894 O 31
+ -4:16:48 - CMT 1920 May
+ -4 - -04 1930 D
+--4 Ar -04/-03 1969 O 5
+--3 Ar -03/-02 1990 Mar 4
++-4 A -04/-03 1969 O 5
++-3 A -03/-02 1990 Mar 4
+ -4 - -04 1990 O 15
+ -4 1 -03 1991 Mar
+ -4 - -04 1991 O 15
+ -4 1 -03 1992 Mar
+ -4 - -04 1992 O 18
+--3 Ar -03/-02 1999 O 3
+--4 Ar -04/-03 2000 Mar 3
++-3 A -03/-02 1999 O 3
++-4 A -04/-03 2000 Mar 3
+ -3 - -03 2004 May 23
+ -4 - -04 2004 S 26
+--3 Ar -03/-02 2008 O 18
++-3 A -03/-02 2008 O 18
+ -3 - -03
+-R As 2008 2009 - Mar Sun>=8 0 0 -
+-R As 2007 2008 - O Sun>=8 0 1 -
++R Sa 2008 2009 - Mar Sun>=8 0 0 -
++R Sa 2007 2008 - O Sun>=8 0 1 -
+ Z America/Argentina/San_Luis -4:25:24 - LMT 1894 O 31
+ -4:16:48 - CMT 1920 May
+ -4 - -04 1930 D
+--4 Ar -04/-03 1969 O 5
+--3 Ar -03/-02 1990
++-4 A -04/-03 1969 O 5
++-3 A -03/-02 1990
+ -3 1 -02 1990 Mar 14
+ -4 - -04 1990 O 15
+ -4 1 -03 1991 Mar
+@@ -3590,286 +3607,288 @@ Z America/Argentina/San_Luis -4:25:24 - LMT 1894 O 31
+ -4 1 -03 2000 Mar 3
+ -3 - -03 2004 May 31
+ -4 - -04 2004 Jul 25
+--3 Ar -03/-02 2008 Ja 21
+--4 As -04/-03 2009 O 11
++-3 A -03/-02 2008 Ja 21
++-4 Sa -04/-03 2009 O 11
+ -3 - -03
+ Z America/Argentina/Rio_Gallegos -4:36:52 - LMT 1894 O 31
+ -4:16:48 - CMT 1920 May
+ -4 - -04 1930 D
+--4 Ar -04/-03 1969 O 5
+--3 Ar -03/-02 1999 O 3
+--4 Ar -04/-03 2000 Mar 3
++-4 A -04/-03 1969 O 5
++-3 A -03/-02 1999 O 3
++-4 A -04/-03 2000 Mar 3
+ -3 - -03 2004 Jun
+ -4 - -04 2004 Jun 20
+--3 Ar -03/-02 2008 O 18
++-3 A -03/-02 2008 O 18
+ -3 - -03
+ Z America/Argentina/Ushuaia -4:33:12 - LMT 1894 O 31
+ -4:16:48 - CMT 1920 May
+ -4 - -04 1930 D
+--4 Ar -04/-03 1969 O 5
+--3 Ar -03/-02 1999 O 3
+--4 Ar -04/-03 2000 Mar 3
++-4 A -04/-03 1969 O 5
++-3 A -03/-02 1999 O 3
++-4 A -04/-03 2000 Mar 3
+ -3 - -03 2004 May 30
+ -4 - -04 2004 Jun 20
+--3 Ar -03/-02 2008 O 18
++-3 A -03/-02 2008 O 18
+ -3 - -03
+ Li America/Curacao America/Aruba
+ Z America/La_Paz -4:32:36 - LMT 1890
+ -4:32:36 - CMT 1931 O 15
+ -4:32:36 1 BST 1932 Mar 21
+ -4 - -04
+-R At 1931 o - O 3 11 1 -
+-R At 1932 1933 - Ap 1 0 0 -
+-R At 1932 o - O 3 0 1 -
+-R At 1949 1952 - D 1 0 1 -
+-R At 1950 o - Ap 16 1 0 -
+-R At 1951 1952 - Ap 1 0 0 -
+-R At 1953 o - Mar 1 0 0 -
+-R At 1963 o - D 9 0 1 -
+-R At 1964 o - Mar 1 0 0 -
+-R At 1965 o - Ja 31 0 1 -
+-R At 1965 o - Mar 31 0 0 -
+-R At 1965 o - D 1 0 1 -
+-R At 1966 1968 - Mar 1 0 0 -
+-R At 1966 1967 - N 1 0 1 -
+-R At 1985 o - N 2 0 1 -
+-R At 1986 o - Mar 15 0 0 -
+-R At 1986 o - O 25 0 1 -
+-R At 1987 o - F 14 0 0 -
+-R At 1987 o - O 25 0 1 -
+-R At 1988 o - F 7 0 0 -
+-R At 1988 o - O 16 0 1 -
+-R At 1989 o - Ja 29 0 0 -
+-R At 1989 o - O 15 0 1 -
+-R At 1990 o - F 11 0 0 -
+-R At 1990 o - O 21 0 1 -
+-R At 1991 o - F 17 0 0 -
+-R At 1991 o - O 20 0 1 -
+-R At 1992 o - F 9 0 0 -
+-R At 1992 o - O 25 0 1 -
+-R At 1993 o - Ja 31 0 0 -
+-R At 1993 1995 - O Sun>=11 0 1 -
+-R At 1994 1995 - F Sun>=15 0 0 -
+-R At 1996 o - F 11 0 0 -
+-R At 1996 o - O 6 0 1 -
+-R At 1997 o - F 16 0 0 -
+-R At 1997 o - O 6 0 1 -
+-R At 1998 o - Mar 1 0 0 -
+-R At 1998 o - O 11 0 1 -
+-R At 1999 o - F 21 0 0 -
+-R At 1999 o - O 3 0 1 -
+-R At 2000 o - F 27 0 0 -
+-R At 2000 2001 - O Sun>=8 0 1 -
+-R At 2001 2006 - F Sun>=15 0 0 -
+-R At 2002 o - N 3 0 1 -
+-R At 2003 o - O 19 0 1 -
+-R At 2004 o - N 2 0 1 -
+-R At 2005 o - O 16 0 1 -
+-R At 2006 o - N 5 0 1 -
+-R At 2007 o - F 25 0 0 -
+-R At 2007 o - O Sun>=8 0 1 -
+-R At 2008 2017 - O Sun>=15 0 1 -
+-R At 2008 2011 - F Sun>=15 0 0 -
+-R At 2012 o - F Sun>=22 0 0 -
+-R At 2013 2014 - F Sun>=15 0 0 -
+-R At 2015 o - F Sun>=22 0 0 -
+-R At 2016 2022 - F Sun>=15 0 0 -
+-R At 2018 ma - N Sun>=1 0 1 -
+-R At 2023 o - F Sun>=22 0 0 -
+-R At 2024 2025 - F Sun>=15 0 0 -
+-R At 2026 o - F Sun>=22 0 0 -
+-R At 2027 2033 - F Sun>=15 0 0 -
+-R At 2034 o - F Sun>=22 0 0 -
+-R At 2035 2036 - F Sun>=15 0 0 -
+-R At 2037 o - F Sun>=22 0 0 -
+-R At 2038 ma - F Sun>=15 0 0 -
++R B 1931 o - O 3 11 1 -
++R B 1932 1933 - Ap 1 0 0 -
++R B 1932 o - O 3 0 1 -
++R B 1949 1952 - D 1 0 1 -
++R B 1950 o - Ap 16 1 0 -
++R B 1951 1952 - Ap 1 0 0 -
++R B 1953 o - Mar 1 0 0 -
++R B 1963 o - D 9 0 1 -
++R B 1964 o - Mar 1 0 0 -
++R B 1965 o - Ja 31 0 1 -
++R B 1965 o - Mar 31 0 0 -
++R B 1965 o - D 1 0 1 -
++R B 1966 1968 - Mar 1 0 0 -
++R B 1966 1967 - N 1 0 1 -
++R B 1985 o - N 2 0 1 -
++R B 1986 o - Mar 15 0 0 -
++R B 1986 o - O 25 0 1 -
++R B 1987 o - F 14 0 0 -
++R B 1987 o - O 25 0 1 -
++R B 1988 o - F 7 0 0 -
++R B 1988 o - O 16 0 1 -
++R B 1989 o - Ja 29 0 0 -
++R B 1989 o - O 15 0 1 -
++R B 1990 o - F 11 0 0 -
++R B 1990 o - O 21 0 1 -
++R B 1991 o - F 17 0 0 -
++R B 1991 o - O 20 0 1 -
++R B 1992 o - F 9 0 0 -
++R B 1992 o - O 25 0 1 -
++R B 1993 o - Ja 31 0 0 -
++R B 1993 1995 - O Sun>=11 0 1 -
++R B 1994 1995 - F Sun>=15 0 0 -
++R B 1996 o - F 11 0 0 -
++R B 1996 o - O 6 0 1 -
++R B 1997 o - F 16 0 0 -
++R B 1997 o - O 6 0 1 -
++R B 1998 o - Mar 1 0 0 -
++R B 1998 o - O 11 0 1 -
++R B 1999 o - F 21 0 0 -
++R B 1999 o - O 3 0 1 -
++R B 2000 o - F 27 0 0 -
++R B 2000 2001 - O Sun>=8 0 1 -
++R B 2001 2006 - F Sun>=15 0 0 -
++R B 2002 o - N 3 0 1 -
++R B 2003 o - O 19 0 1 -
++R B 2004 o - N 2 0 1 -
++R B 2005 o - O 16 0 1 -
++R B 2006 o - N 5 0 1 -
++R B 2007 o - F 25 0 0 -
++R B 2007 o - O Sun>=8 0 1 -
++R B 2008 2017 - O Sun>=15 0 1 -
++R B 2008 2011 - F Sun>=15 0 0 -
++R B 2012 o - F Sun>=22 0 0 -
++R B 2013 2014 - F Sun>=15 0 0 -
++R B 2015 o - F Sun>=22 0 0 -
++R B 2016 2022 - F Sun>=15 0 0 -
++R B 2018 ma - N Sun>=1 0 1 -
++R B 2023 o - F Sun>=22 0 0 -
++R B 2024 2025 - F Sun>=15 0 0 -
++R B 2026 o - F Sun>=22 0 0 -
++R B 2027 2033 - F Sun>=15 0 0 -
++R B 2034 o - F Sun>=22 0 0 -
++R B 2035 2036 - F Sun>=15 0 0 -
++R B 2037 o - F Sun>=22 0 0 -
++R B 2038 ma - F Sun>=15 0 0 -
+ Z America/Noronha -2:9:40 - LMT 1914
+--2 At -02/-01 1990 S 17
++-2 B -02/-01 1990 S 17
+ -2 - -02 1999 S 30
+--2 At -02/-01 2000 O 15
++-2 B -02/-01 2000 O 15
+ -2 - -02 2001 S 13
+--2 At -02/-01 2002 O
++-2 B -02/-01 2002 O
+ -2 - -02
+ Z America/Belem -3:13:56 - LMT 1914
+--3 At -03/-02 1988 S 12
++-3 B -03/-02 1988 S 12
+ -3 - -03
+ Z America/Santarem -3:38:48 - LMT 1914
+--4 At -04/-03 1988 S 12
++-4 B -04/-03 1988 S 12
+ -4 - -04 2008 Jun 24
+ -3 - -03
+ Z America/Fortaleza -2:34 - LMT 1914
+--3 At -03/-02 1990 S 17
++-3 B -03/-02 1990 S 17
+ -3 - -03 1999 S 30
+--3 At -03/-02 2000 O 22
++-3 B -03/-02 2000 O 22
+ -3 - -03 2001 S 13
+--3 At -03/-02 2002 O
++-3 B -03/-02 2002 O
+ -3 - -03
+ Z America/Recife -2:19:36 - LMT 1914
+--3 At -03/-02 1990 S 17
++-3 B -03/-02 1990 S 17
+ -3 - -03 1999 S 30
+--3 At -03/-02 2000 O 15
++-3 B -03/-02 2000 O 15
+ -3 - -03 2001 S 13
+--3 At -03/-02 2002 O
++-3 B -03/-02 2002 O
+ -3 - -03
+ Z America/Araguaina -3:12:48 - LMT 1914
+--3 At -03/-02 1990 S 17
++-3 B -03/-02 1990 S 17
+ -3 - -03 1995 S 14
+--3 At -03/-02 2003 S 24
++-3 B -03/-02 2003 S 24
+ -3 - -03 2012 O 21
+--3 At -03/-02 2013 S
++-3 B -03/-02 2013 S
+ -3 - -03
+ Z America/Maceio -2:22:52 - LMT 1914
+--3 At -03/-02 1990 S 17
++-3 B -03/-02 1990 S 17
+ -3 - -03 1995 O 13
+--3 At -03/-02 1996 S 4
++-3 B -03/-02 1996 S 4
+ -3 - -03 1999 S 30
+--3 At -03/-02 2000 O 22
++-3 B -03/-02 2000 O 22
+ -3 - -03 2001 S 13
+--3 At -03/-02 2002 O
++-3 B -03/-02 2002 O
+ -3 - -03
+ Z America/Bahia -2:34:4 - LMT 1914
+--3 At -03/-02 2003 S 24
++-3 B -03/-02 2003 S 24
+ -3 - -03 2011 O 16
+--3 At -03/-02 2012 O 21
++-3 B -03/-02 2012 O 21
+ -3 - -03
+ Z America/Sao_Paulo -3:6:28 - LMT 1914
+--3 At -03/-02 1963 O 23
++-3 B -03/-02 1963 O 23
+ -3 1 -02 1964
+--3 At -03/-02
++-3 B -03/-02
+ Z America/Campo_Grande -3:38:28 - LMT 1914
+--4 At -04/-03
++-4 B -04/-03
+ Z America/Cuiaba -3:44:20 - LMT 1914
+--4 At -04/-03 2003 S 24
++-4 B -04/-03 2003 S 24
+ -4 - -04 2004 O
+--4 At -04/-03
++-4 B -04/-03
+ Z America/Porto_Velho -4:15:36 - LMT 1914
+--4 At -04/-03 1988 S 12
++-4 B -04/-03 1988 S 12
+ -4 - -04
+ Z America/Boa_Vista -4:2:40 - LMT 1914
+--4 At -04/-03 1988 S 12
++-4 B -04/-03 1988 S 12
+ -4 - -04 1999 S 30
+--4 At -04/-03 2000 O 15
++-4 B -04/-03 2000 O 15
+ -4 - -04
+ Z America/Manaus -4:0:4 - LMT 1914
+--4 At -04/-03 1988 S 12
++-4 B -04/-03 1988 S 12
+ -4 - -04 1993 S 28
+--4 At -04/-03 1994 S 22
++-4 B -04/-03 1994 S 22
+ -4 - -04
+ Z America/Eirunepe -4:39:28 - LMT 1914
+--5 At -05/-04 1988 S 12
++-5 B -05/-04 1988 S 12
+ -5 - -05 1993 S 28
+--5 At -05/-04 1994 S 22
++-5 B -05/-04 1994 S 22
+ -5 - -05 2008 Jun 24
+ -4 - -04 2013 N 10
+ -5 - -05
+ Z America/Rio_Branco -4:31:12 - LMT 1914
+--5 At -05/-04 1988 S 12
++-5 B -05/-04 1988 S 12
+ -5 - -05 2008 Jun 24
+ -4 - -04 2013 N 10
+ -5 - -05
+-R Au 1927 1931 - S 1 0 1 -
+-R Au 1928 1932 - Ap 1 0 0 -
+-R Au 1968 o - N 3 4u 1 -
+-R Au 1969 o - Mar 30 3u 0 -
+-R Au 1969 o - N 23 4u 1 -
+-R Au 1970 o - Mar 29 3u 0 -
+-R Au 1971 o - Mar 14 3u 0 -
+-R Au 1970 1972 - O Sun>=9 4u 1 -
+-R Au 1972 1986 - Mar Sun>=9 3u 0 -
+-R Au 1973 o - S 30 4u 1 -
+-R Au 1974 1987 - O Sun>=9 4u 1 -
+-R Au 1987 o - Ap 12 3u 0 -
+-R Au 1988 1990 - Mar Sun>=9 3u 0 -
+-R Au 1988 1989 - O Sun>=9 4u 1 -
+-R Au 1990 o - S 16 4u 1 -
+-R Au 1991 1996 - Mar Sun>=9 3u 0 -
+-R Au 1991 1997 - O Sun>=9 4u 1 -
+-R Au 1997 o - Mar 30 3u 0 -
+-R Au 1998 o - Mar Sun>=9 3u 0 -
+-R Au 1998 o - S 27 4u 1 -
+-R Au 1999 o - Ap 4 3u 0 -
+-R Au 1999 2010 - O Sun>=9 4u 1 -
+-R Au 2000 2007 - Mar Sun>=9 3u 0 -
+-R Au 2008 o - Mar 30 3u 0 -
+-R Au 2009 o - Mar Sun>=9 3u 0 -
+-R Au 2010 o - Ap Sun>=1 3u 0 -
+-R Au 2011 o - May Sun>=2 3u 0 -
+-R Au 2011 o - Au Sun>=16 4u 1 -
+-R Au 2012 2014 - Ap Sun>=23 3u 0 -
+-R Au 2012 2014 - S Sun>=2 4u 1 -
+-R Au 2016 ma - May Sun>=9 3u 0 -
+-R Au 2016 ma - Au Sun>=9 4u 1 -
++R x 1927 1931 - S 1 0 1 -
++R x 1928 1932 - Ap 1 0 0 -
++R x 1968 o - N 3 4u 1 -
++R x 1969 o - Mar 30 3u 0 -
++R x 1969 o - N 23 4u 1 -
++R x 1970 o - Mar 29 3u 0 -
++R x 1971 o - Mar 14 3u 0 -
++R x 1970 1972 - O Sun>=9 4u 1 -
++R x 1972 1986 - Mar Sun>=9 3u 0 -
++R x 1973 o - S 30 4u 1 -
++R x 1974 1987 - O Sun>=9 4u 1 -
++R x 1987 o - Ap 12 3u 0 -
++R x 1988 1990 - Mar Sun>=9 3u 0 -
++R x 1988 1989 - O Sun>=9 4u 1 -
++R x 1990 o - S 16 4u 1 -
++R x 1991 1996 - Mar Sun>=9 3u 0 -
++R x 1991 1997 - O Sun>=9 4u 1 -
++R x 1997 o - Mar 30 3u 0 -
++R x 1998 o - Mar Sun>=9 3u 0 -
++R x 1998 o - S 27 4u 1 -
++R x 1999 o - Ap 4 3u 0 -
++R x 1999 2010 - O Sun>=9 4u 1 -
++R x 2000 2007 - Mar Sun>=9 3u 0 -
++R x 2008 o - Mar 30 3u 0 -
++R x 2009 o - Mar Sun>=9 3u 0 -
++R x 2010 o - Ap Sun>=1 3u 0 -
++R x 2011 o - May Sun>=2 3u 0 -
++R x 2011 o - Au Sun>=16 4u 1 -
++R x 2012 2014 - Ap Sun>=23 3u 0 -
++R x 2012 2014 - S Sun>=2 4u 1 -
++R x 2016 2018 - May Sun>=9 3u 0 -
++R x 2016 2018 - Au Sun>=9 4u 1 -
++R x 2019 ma - Ap Sun>=2 3u 0 -
++R x 2019 ma - S Sun>=2 4u 1 -
+ Z America/Santiago -4:42:46 - LMT 1890
+ -4:42:46 - SMT 1910 Ja 10
+ -5 - -05 1916 Jul
+ -4:42:46 - SMT 1918 S 10
+ -4 - -04 1919 Jul
+ -4:42:46 - SMT 1927 S
+--5 Au -05/-04 1932 S
++-5 x -05/-04 1932 S
+ -4 - -04 1942 Jun
+ -5 - -05 1942 Au
+ -4 - -04 1946 Jul 15
+ -4 1 -03 1946 S
+ -4 - -04 1947 Ap
+ -5 - -05 1947 May 21 23
+--4 Au -04/-03
++-4 x -04/-03
+ Z America/Punta_Arenas -4:43:40 - LMT 1890
+ -4:42:46 - SMT 1910 Ja 10
+ -5 - -05 1916 Jul
+ -4:42:46 - SMT 1918 S 10
+ -4 - -04 1919 Jul
+ -4:42:46 - SMT 1927 S
+--5 Au -05/-04 1932 S
++-5 x -05/-04 1932 S
+ -4 - -04 1942 Jun
+ -5 - -05 1942 Au
+ -4 - -04 1947 Ap
+ -5 - -05 1947 May 21 23
+--4 Au -04/-03 2016 D 4
++-4 x -04/-03 2016 D 4
+ -3 - -03
+ Z Pacific/Easter -7:17:28 - LMT 1890
+ -7:17:28 - EMT 1932 S
+--7 Au -07/-06 1982 Mar 14 3u
+--6 Au -06/-05
++-7 x -07/-06 1982 Mar 14 3u
++-6 x -06/-05
+ Z Antarctica/Palmer 0 - -00 1965
+--4 Ar -04/-03 1969 O 5
+--3 Ar -03/-02 1982 May
+--4 Au -04/-03 2016 D 4
++-4 A -04/-03 1969 O 5
++-3 A -03/-02 1982 May
++-4 x -04/-03 2016 D 4
+ -3 - -03
+-R Av 1992 o - May 3 0 1 -
+-R Av 1993 o - Ap 4 0 0 -
++R CO 1992 o - May 3 0 1 -
++R CO 1993 o - Ap 4 0 0 -
+ Z America/Bogota -4:56:16 - LMT 1884 Mar 13
+ -4:56:16 - BMT 1914 N 23
+--5 Av -05/-04
++-5 CO -05/-04
+ Z America/Curacao -4:35:47 - LMT 1912 F 12
+ -4:30 - -0430 1965
+ -4 - AST
+ Li America/Curacao America/Lower_Princes
+ Li America/Curacao America/Kralendijk
+-R Aw 1992 o - N 28 0 1 -
+-R Aw 1993 o - F 5 0 0 -
++R EC 1992 o - N 28 0 1 -
++R EC 1993 o - F 5 0 0 -
+ Z America/Guayaquil -5:19:20 - LMT 1890
+ -5:14 - QMT 1931
+--5 Aw -05/-04
++-5 EC -05/-04
+ Z Pacific/Galapagos -5:58:24 - LMT 1931
+ -5 - -05 1986
+--6 Aw -06/-05
+-R Ax 1937 1938 - S lastSun 0 1 -
+-R Ax 1938 1942 - Mar Sun>=19 0 0 -
+-R Ax 1939 o - O 1 0 1 -
+-R Ax 1940 1942 - S lastSun 0 1 -
+-R Ax 1943 o - Ja 1 0 0 -
+-R Ax 1983 o - S lastSun 0 1 -
+-R Ax 1984 1985 - Ap lastSun 0 0 -
+-R Ax 1984 o - S 16 0 1 -
+-R Ax 1985 2000 - S Sun>=9 0 1 -
+-R Ax 1986 2000 - Ap Sun>=16 0 0 -
+-R Ax 2001 2010 - Ap Sun>=15 2 0 -
+-R Ax 2001 2010 - S Sun>=1 2 1 -
++-6 EC -06/-05
++R FK 1937 1938 - S lastSun 0 1 -
++R FK 1938 1942 - Mar Sun>=19 0 0 -
++R FK 1939 o - O 1 0 1 -
++R FK 1940 1942 - S lastSun 0 1 -
++R FK 1943 o - Ja 1 0 0 -
++R FK 1983 o - S lastSun 0 1 -
++R FK 1984 1985 - Ap lastSun 0 0 -
++R FK 1984 o - S 16 0 1 -
++R FK 1985 2000 - S Sun>=9 0 1 -
++R FK 1986 2000 - Ap Sun>=16 0 0 -
++R FK 2001 2010 - Ap Sun>=15 2 0 -
++R FK 2001 2010 - S Sun>=1 2 1 -
+ Z Atlantic/Stanley -3:51:24 - LMT 1890
+ -3:51:24 - SMT 1912 Mar 12
+--4 Ax -04/-03 1983 May
+--3 Ax -03/-02 1985 S 15
+--4 Ax -04/-03 2010 S 5 2
++-4 FK -04/-03 1983 May
++-3 FK -03/-02 1985 S 15
++-4 FK -04/-03 2010 S 5 2
+ -3 - -03
+ Z America/Cayenne -3:29:20 - LMT 1911 Jul
+ -4 - -04 1967 O
+@@ -3878,46 +3897,46 @@ Z America/Guyana -3:52:40 - LMT 1915 Mar
+ -3:45 - -0345 1975 Jul 31
+ -3 - -03 1991
+ -4 - -04
+-R Ay 1975 1988 - O 1 0 1 -
+-R Ay 1975 1978 - Mar 1 0 0 -
+-R Ay 1979 1991 - Ap 1 0 0 -
+-R Ay 1989 o - O 22 0 1 -
+-R Ay 1990 o - O 1 0 1 -
+-R Ay 1991 o - O 6 0 1 -
+-R Ay 1992 o - Mar 1 0 0 -
+-R Ay 1992 o - O 5 0 1 -
+-R Ay 1993 o - Mar 31 0 0 -
+-R Ay 1993 1995 - O 1 0 1 -
+-R Ay 1994 1995 - F lastSun 0 0 -
+-R Ay 1996 o - Mar 1 0 0 -
+-R Ay 1996 2001 - O Sun>=1 0 1 -
+-R Ay 1997 o - F lastSun 0 0 -
+-R Ay 1998 2001 - Mar Sun>=1 0 0 -
+-R Ay 2002 2004 - Ap Sun>=1 0 0 -
+-R Ay 2002 2003 - S Sun>=1 0 1 -
+-R Ay 2004 2009 - O Sun>=15 0 1 -
+-R Ay 2005 2009 - Mar Sun>=8 0 0 -
+-R Ay 2010 ma - O Sun>=1 0 1 -
+-R Ay 2010 2012 - Ap Sun>=8 0 0 -
+-R Ay 2013 ma - Mar Sun>=22 0 0 -
++R y 1975 1988 - O 1 0 1 -
++R y 1975 1978 - Mar 1 0 0 -
++R y 1979 1991 - Ap 1 0 0 -
++R y 1989 o - O 22 0 1 -
++R y 1990 o - O 1 0 1 -
++R y 1991 o - O 6 0 1 -
++R y 1992 o - Mar 1 0 0 -
++R y 1992 o - O 5 0 1 -
++R y 1993 o - Mar 31 0 0 -
++R y 1993 1995 - O 1 0 1 -
++R y 1994 1995 - F lastSun 0 0 -
++R y 1996 o - Mar 1 0 0 -
++R y 1996 2001 - O Sun>=1 0 1 -
++R y 1997 o - F lastSun 0 0 -
++R y 1998 2001 - Mar Sun>=1 0 0 -
++R y 2002 2004 - Ap Sun>=1 0 0 -
++R y 2002 2003 - S Sun>=1 0 1 -
++R y 2004 2009 - O Sun>=15 0 1 -
++R y 2005 2009 - Mar Sun>=8 0 0 -
++R y 2010 ma - O Sun>=1 0 1 -
++R y 2010 2012 - Ap Sun>=8 0 0 -
++R y 2013 ma - Mar Sun>=22 0 0 -
+ Z America/Asuncion -3:50:40 - LMT 1890
+ -3:50:40 - AMT 1931 O 10
+ -4 - -04 1972 O
+ -3 - -03 1974 Ap
+--4 Ay -04/-03
+-R Az 1938 o - Ja 1 0 1 -
+-R Az 1938 o - Ap 1 0 0 -
+-R Az 1938 1939 - S lastSun 0 1 -
+-R Az 1939 1940 - Mar Sun>=24 0 0 -
+-R Az 1986 1987 - Ja 1 0 1 -
+-R Az 1986 1987 - Ap 1 0 0 -
+-R Az 1990 o - Ja 1 0 1 -
+-R Az 1990 o - Ap 1 0 0 -
+-R Az 1994 o - Ja 1 0 1 -
+-R Az 1994 o - Ap 1 0 0 -
++-4 y -04/-03
++R PE 1938 o - Ja 1 0 1 -
++R PE 1938 o - Ap 1 0 0 -
++R PE 1938 1939 - S lastSun 0 1 -
++R PE 1939 1940 - Mar Sun>=24 0 0 -
++R PE 1986 1987 - Ja 1 0 1 -
++R PE 1986 1987 - Ap 1 0 0 -
++R PE 1990 o - Ja 1 0 1 -
++R PE 1990 o - Ap 1 0 0 -
++R PE 1994 o - Ja 1 0 1 -
++R PE 1994 o - Ap 1 0 0 -
+ Z America/Lima -5:8:12 - LMT 1890
+ -5:8:36 - LMT 1908 Jul 28
+--5 Az -05/-04
++-5 PE -05/-04
+ Z Atlantic/South_Georgia -2:26:8 - LMT 1890
+ -2 - -02
+ Z America/Paramaribo -3:40:40 - LMT 1911
+@@ -3940,65 +3959,65 @@ Li America/Port_of_Spain America/St_Lucia
+ Li America/Port_of_Spain America/St_Thomas
+ Li America/Port_of_Spain America/St_Vincent
+ Li America/Port_of_Spain America/Tortola
+-R A! 1923 1925 - O 1 0 0:30 -
+-R A! 1924 1926 - Ap 1 0 0 -
+-R A! 1933 1938 - O lastSun 0 0:30 -
+-R A! 1934 1941 - Mar lastSat 24 0 -
+-R A! 1939 o - O 1 0 0:30 -
+-R A! 1940 o - O 27 0 0:30 -
+-R A! 1941 o - Au 1 0 0:30 -
+-R A! 1942 o - D 14 0 0:30 -
+-R A! 1943 o - Mar 14 0 0 -
+-R A! 1959 o - May 24 0 0:30 -
+-R A! 1959 o - N 15 0 0 -
+-R A! 1960 o - Ja 17 0 1 -
+-R A! 1960 o - Mar 6 0 0 -
+-R A! 1965 o - Ap 4 0 1 -
+-R A! 1965 o - S 26 0 0 -
+-R A! 1968 o - May 27 0 0:30 -
+-R A! 1968 o - D 1 0 0 -
+-R A! 1970 o - Ap 25 0 1 -
+-R A! 1970 o - Jun 14 0 0 -
+-R A! 1972 o - Ap 23 0 1 -
+-R A! 1972 o - Jul 16 0 0 -
+-R A! 1974 o - Ja 13 0 1:30 -
+-R A! 1974 o - Mar 10 0 0:30 -
+-R A! 1974 o - S 1 0 0 -
+-R A! 1974 o - D 22 0 1 -
+-R A! 1975 o - Mar 30 0 0 -
+-R A! 1976 o - D 19 0 1 -
+-R A! 1977 o - Mar 6 0 0 -
+-R A! 1977 o - D 4 0 1 -
+-R A! 1978 1979 - Mar Sun>=1 0 0 -
+-R A! 1978 o - D 17 0 1 -
+-R A! 1979 o - Ap 29 0 1 -
+-R A! 1980 o - Mar 16 0 0 -
+-R A! 1987 o - D 14 0 1 -
+-R A! 1988 o - F 28 0 0 -
+-R A! 1988 o - D 11 0 1 -
+-R A! 1989 o - Mar 5 0 0 -
+-R A! 1989 o - O 29 0 1 -
+-R A! 1990 o - F 25 0 0 -
+-R A! 1990 1991 - O Sun>=21 0 1 -
+-R A! 1991 1992 - Mar Sun>=1 0 0 -
+-R A! 1992 o - O 18 0 1 -
+-R A! 1993 o - F 28 0 0 -
+-R A! 2004 o - S 19 0 1 -
+-R A! 2005 o - Mar 27 2 0 -
+-R A! 2005 o - O 9 2 1 -
+-R A! 2006 2015 - Mar Sun>=8 2 0 -
+-R A! 2006 2014 - O Sun>=1 2 1 -
++R U 1923 1925 - O 1 0 0:30 -
++R U 1924 1926 - Ap 1 0 0 -
++R U 1933 1938 - O lastSun 0 0:30 -
++R U 1934 1941 - Mar lastSat 24 0 -
++R U 1939 o - O 1 0 0:30 -
++R U 1940 o - O 27 0 0:30 -
++R U 1941 o - Au 1 0 0:30 -
++R U 1942 o - D 14 0 0:30 -
++R U 1943 o - Mar 14 0 0 -
++R U 1959 o - May 24 0 0:30 -
++R U 1959 o - N 15 0 0 -
++R U 1960 o - Ja 17 0 1 -
++R U 1960 o - Mar 6 0 0 -
++R U 1965 o - Ap 4 0 1 -
++R U 1965 o - S 26 0 0 -
++R U 1968 o - May 27 0 0:30 -
++R U 1968 o - D 1 0 0 -
++R U 1970 o - Ap 25 0 1 -
++R U 1970 o - Jun 14 0 0 -
++R U 1972 o - Ap 23 0 1 -
++R U 1972 o - Jul 16 0 0 -
++R U 1974 o - Ja 13 0 1:30 -
++R U 1974 o - Mar 10 0 0:30 -
++R U 1974 o - S 1 0 0 -
++R U 1974 o - D 22 0 1 -
++R U 1975 o - Mar 30 0 0 -
++R U 1976 o - D 19 0 1 -
++R U 1977 o - Mar 6 0 0 -
++R U 1977 o - D 4 0 1 -
++R U 1978 1979 - Mar Sun>=1 0 0 -
++R U 1978 o - D 17 0 1 -
++R U 1979 o - Ap 29 0 1 -
++R U 1980 o - Mar 16 0 0 -
++R U 1987 o - D 14 0 1 -
++R U 1988 o - F 28 0 0 -
++R U 1988 o - D 11 0 1 -
++R U 1989 o - Mar 5 0 0 -
++R U 1989 o - O 29 0 1 -
++R U 1990 o - F 25 0 0 -
++R U 1990 1991 - O Sun>=21 0 1 -
++R U 1991 1992 - Mar Sun>=1 0 0 -
++R U 1992 o - O 18 0 1 -
++R U 1993 o - F 28 0 0 -
++R U 2004 o - S 19 0 1 -
++R U 2005 o - Mar 27 2 0 -
++R U 2005 o - O 9 2 1 -
++R U 2006 2015 - Mar Sun>=8 2 0 -
++R U 2006 2014 - O Sun>=1 2 1 -
+ Z America/Montevideo -3:44:51 - LMT 1908 Jun 10
+ -3:44:51 - MMT 1920 May
+ -4 - -04 1923 O
+--3:30 A! -0330/-03 1942 D 14
+--3 A! -03/-0230 1960
+--3 A! -03/-02 1968
+--3 A! -03/-0230 1970
+--3 A! -03/-02 1974
+--3 A! -03/-0130 1974 Mar 10
+--3 A! -03/-0230 1974 D 22
+--3 A! -03/-02
++-3:30 U -0330/-03 1942 D 14
++-3 U -03/-0230 1960
++-3 U -03/-02 1968
++-3 U -03/-0230 1970
++-3 U -03/-02 1974
++-3 U -03/-0130 1974 Mar 10
++-3 U -03/-0230 1974 D 22
++-3 U -03/-02
+ Z America/Caracas -4:27:44 - LMT 1890
+ -4:27:40 - CMT 1912 F 12
+ -4:30 - -0430 1965
+diff --git a/src/timezone/known_abbrevs.txt b/src/timezone/known_abbrevs.txt
+index 67d2f0b..2ae443a 100644
+--- a/src/timezone/known_abbrevs.txt
++++ b/src/timezone/known_abbrevs.txt
+@@ -92,6 +92,7 @@ NZST	43200
+ PDT	-25200	D
+ PKT	18000
+ PST	-28800
++PST	28800
+ SAST	7200
+ SST	-39600
+ UCT	0
+diff --git a/src/timezone/tznames/America.txt b/src/timezone/tznames/America.txt
+index 1c5eb1f..2594c37 100644
+--- a/src/timezone/tznames/America.txt
++++ b/src/timezone/tznames/America.txt
+@@ -237,6 +237,9 @@ PDT    -25200 D  # Pacific Daylight Time
+ PET    -18000    # Peru Time (obsolete)
+ PMDT    -7200 D  # Pierre & Miquelon Daylight Time (obsolete)
+ PMST   -10800    # Pierre & Miquelon Standard Time (obsolete)
++# CONFLICT! PST is not unique
++# Other timezones:
++#  - PST: Philippine Standard Time
+ PST    -28800    # Pacific Standard Time
+                  #     (America/Dawson)
+                  #     (America/Los_Angeles)
+diff --git a/src/timezone/tznames/Asia.txt b/src/timezone/tznames/Asia.txt
+index e1fa931..1133339 100644
+--- a/src/timezone/tznames/Asia.txt
++++ b/src/timezone/tznames/Asia.txt
+@@ -158,6 +158,10 @@ PKT     18000    # Pakistan Time
+                  #     (Asia/Karachi)
+ PKST    21600 D  # Pakistan Summer Time
+                  #     (Asia/Karachi)
++# CONFLICT! PST is not unique
++# Other timezones:
++#  - PST: Pacific Standard Time (America)
++PST     28800    # Philippine Standard Time
+ QYZT    21600    # Kizilorda Time (obsolete)
+ SAKST   Asia/Sakhalin  # Sakhalin Summer Time (obsolete)
+ SAKT    Asia/Sakhalin  # Sakhalin Time (obsolete)
+diff --git a/src/timezone/tznames/Default b/src/timezone/tznames/Default
+index 3826096..1532413 100644
+--- a/src/timezone/tznames/Default
++++ b/src/timezone/tznames/Default
+@@ -181,6 +181,9 @@ PDT    -25200 D  # Pacific Daylight Time
+                  #     (America/Whitehorse)
+ PMDT    -7200 D  # Pierre & Miquelon Daylight Time (obsolete)
+ PMST   -10800    # Pierre & Miquelon Standard Time (obsolete)
++# CONFLICT! PST is not unique
++# Other timezones:
++#  - PST: Philippine Standard Time
+ PST    -28800    # Pacific Standard Time
+                  #     (America/Dawson)
+                  #     (America/Los_Angeles)
+diff --git a/src/timezone/tznames/Pacific.txt b/src/timezone/tznames/Pacific.txt
+index c86248b..c30008c 100644
+--- a/src/timezone/tznames/Pacific.txt
++++ b/src/timezone/tznames/Pacific.txt
+@@ -52,6 +52,9 @@ NZST    43200    # New Zealand Standard Time
+ PGT     36000    # Papua New Guinea Time (obsolete)
+ PHOT    Pacific/Enderbury  # Phoenix Islands Time (Kiribati) (obsolete)
+ PONT    39600    # Ponape Time (Micronesia) (obsolete)
++# CONFLICT! PST is not unique
++# Other timezones:
++#  - PST: Philippine Standard Time
+ PST    -28800    # Pacific Standard Time
+                  #     (America/Dawson)
+                  #     (America/Los_Angeles)
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-dbs/postgresql/files/0001-Use-pkg-config-for-libxml2-detection.patch b/meta-openembedded/meta-oe/recipes-dbs/postgresql/files/0001-Use-pkg-config-for-libxml2-detection.patch
index fafbc25..f14da06 100644
--- a/meta-openembedded/meta-oe/recipes-dbs/postgresql/files/0001-Use-pkg-config-for-libxml2-detection.patch
+++ b/meta-openembedded/meta-oe/recipes-dbs/postgresql/files/0001-Use-pkg-config-for-libxml2-detection.patch
@@ -1,26 +1,29 @@
-From d52e330be895bb8c5f0fb3e2884766acbd942a85 Mon Sep 17 00:00:00 2001
-From: Philip Balister <philip@balister.org>
-Date: Tue, 1 Jul 2014 09:40:44 -0400
-Subject: [PATCH] Use pkg-config for libxml2 detection.
+From d3ee8c8df5808b63e86f40831f2ba62cbb33d291 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Wed, 8 Aug 2018 09:18:27 +0800
+Subject: [PATCH] postgresql: Use pkg-config for libxml2 detection.
 
 Upstream-Status: Inappropriate [configuration]
 
 xml2-config does not work. Use pkgconfig to set CPPFLAGS and LIBS.
 
 Signed-off-by: Philip Balister <philip@balister.org>
+
+upate to version 10.4
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
 ---
  configure.in | 15 ++-------------
  1 file changed, 2 insertions(+), 13 deletions(-)
 
-Index: postgresql-9.4.20/configure.in
-===================================================================
---- postgresql-9.4.20.orig/configure.in
-+++ postgresql-9.4.20/configure.in
-@@ -789,19 +789,8 @@ PGAC_ARG_BOOL(with, libxml, no, [build w
+diff --git a/configure.in b/configure.in
+index d9fe56e..3e2cd3a 100644
+--- a/configure.in
++++ b/configure.in
+@@ -816,19 +816,8 @@ PGAC_ARG_BOOL(with, libxml, no, [build with XML support],
                [AC_DEFINE([USE_LIBXML], 1, [Define to 1 to build with XML support. (--with-libxml)])])
  
  if test "$with_libxml" = yes ; then
--  AC_CHECK_PROGS(XML2_CONFIG, xml2-config)
+-  PGAC_PATH_PROGS(XML2_CONFIG, xml2-config)
 -  if test -n "$XML2_CONFIG"; then
 -    for pgac_option in `$XML2_CONFIG --cflags`; do
 -      case $pgac_option in
@@ -33,8 +36,11 @@
 -      esac
 -    done
 -  fi
-+  CPPFLAGS="$CPPFLAGS `pkg-config --short-errors --print-errors --cflags "libxml-2.0" 2>&1`"
-+  LIBS="`pkg-config --short-errors --print-errors --libs "libxml-2.0" 2>&1` $LIBS"
++    CPPFLAGS="$CPPFLAGS `pkg-config --short-errors --print-errors --cflags "libxml-2.0" 2>&1`"
++    LIBS="`pkg-config --short-errors --print-errors --libs "libxml-2.0" 2>&1` $LIBS"
  fi
  
  AC_SUBST(with_libxml)
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-dbs/postgresql/files/not-check-libperl.patch b/meta-openembedded/meta-oe/recipes-dbs/postgresql/files/not-check-libperl.patch
index c57b421..9715109 100644
--- a/meta-openembedded/meta-oe/recipes-dbs/postgresql/files/not-check-libperl.patch
+++ b/meta-openembedded/meta-oe/recipes-dbs/postgresql/files/not-check-libperl.patch
@@ -13,16 +13,16 @@
  configure.in | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-Index: postgresql-9.4.20/configure.in
+Index: postgresql-9.4.15/configure.in
 ===================================================================
---- postgresql-9.4.20.orig/configure.in
-+++ postgresql-9.4.20/configure.in
-@@ -1931,7 +1931,7 @@ if test "$with_tcl" = yes; then
+--- postgresql-9.4.15.orig/configure.in
++++ postgresql-9.4.15/configure.in
+@@ -1879,7 +1879,7 @@ if test "$with_tcl" = yes; then
  fi
  
  # check for <perl.h>
 -if test "$with_perl" = yes; then
 +if test "$with_perl" = yes && test "$cross_compiling" = no; then
    ac_save_CPPFLAGS=$CPPFLAGS
-   CPPFLAGS="$CPPFLAGS $perl_includespec"
+   CPPFLAGS="$CPPFLAGS -I$perl_archlibexp/CORE"
    AC_CHECK_HEADER(perl.h, [], [AC_MSG_ERROR([header file <perl.h> is required for Perl])],
diff --git a/meta-openembedded/meta-oe/recipes-dbs/postgresql/postgresql.inc b/meta-openembedded/meta-oe/recipes-dbs/postgresql/postgresql.inc
index 812c2ae..3bf71f0 100644
--- a/meta-openembedded/meta-oe/recipes-dbs/postgresql/postgresql.inc
+++ b/meta-openembedded/meta-oe/recipes-dbs/postgresql/postgresql.inc
@@ -19,7 +19,7 @@
 "
 HOMEPAGE = "http://www.postgresql.com"
 LICENSE = "BSD"
-DEPENDS = "zlib readline tzcode-native"
+DEPENDS = "libnsl2 zlib readline tzcode-native"
 
 ARM_INSTRUCTION_SET = "arm"
 
@@ -59,7 +59,7 @@
 PACKAGECONFIG[pam] = "--with-pam,--without-pam,libpam,"
 PACKAGECONFIG[openssl] = "--with-openssl,--without-openssl,openssl,"
 PACKAGECONFIG[python] = "--with-python,--without-python,python,python"
-PACKAGECONFIG[uuid] = "--with-ossp-uuid,--without-ossp-uuid,ossp-uuid,"
+PACKAGECONFIG[uuid] = "--with-uuid=e2fs,--without-uuid,util-linux,"
 PACKAGECONFIG[tcl] = "--with-tcl --with-tclconfig=${STAGING_BINDIR_CROSS},--without-tcl,tcl tcl-native,"
 PACKAGECONFIG[nls] = "--enable-nls,--disable-nls,,"
 PACKAGECONFIG[libxml] = "--with-libxml,--without-libxml,libxml2,libxml2"
@@ -72,21 +72,19 @@
 EXTRA_OECONF_sh4 += "--disable-spinlocks"
 EXTRA_OECONF_aarch64 += "--disable-spinlocks"
 
-PACKAGES_DYNAMIC += "^${PN}-plperl ^${PN}-plperl-dbg \
-    ^${PN}-pltcl ^${PN}-pltcl-dbg \
-    ^${PN}-plpython ^${PN}-plpython-dbg \
+PACKAGES_DYNAMIC += "^${PN}-plperl \
+    ^${PN}-pltcl \
+    ^${PN}-plpython \
 "
 
 python populate_packages_prepend() {
 
-    def fill_more(name, dbg=True):
+    def fill_more(name):
         if name is None or name.strip() == "":
             return
 
         fpack=d.getVar('PACKAGES', False) or ""
         fpack="${PN}-" + name + " " + fpack
-        if dbg:
-            fpack="${PN}-" + name + "-dbg" + " " + fpack
         d.setVar('PACKAGES', fpack)
 
     conf=(d.getVar('PACKAGECONFIG') or "").split()
@@ -202,15 +200,26 @@
 }
 
 SSTATE_SCAN_FILES += "Makefile.global"
+SSTATE_SCAN_FILES_remove = "*_config"
 
 PACKAGES =+ "${PN}-client ${PN}-server-dev ${PN}-timezone \
-    libecpg-compat-dbg libecpg-compat libecpg-compat-dev \
-    libecpg-dbg libecpg libecpg-dev libecpg-staticdev libecpg-doc \
-    libpq-dbg libpq libpq-dev libpq-staticdev \
-    libpgtypes-dbg libpgtypes libpgtypes-staticdev libpgtypes-dev \
-    ${PN}-contrib ${PN}-contrib-dbg \
+    libecpg-compat libecpg-compat-dev \
+    libecpg libecpg-dev libecpg-staticdev libecpg-doc \
+    libpq libpq-dev libpq-staticdev \
+    libpgtypes libpgtypes-staticdev libpgtypes-dev \
+    ${PN}-contrib \
 "
 
+RPROVIDES_${PN}-dbg += "libecpg-compat-dbg \
+                        libecpg-dbg \
+                        libpq-dbg \
+                        libpgtypes-dbg \
+                        ${PN}-contrib-dbg \
+                        ${PN}-pltcl-dbg \
+                        ${PN}-plpython-dbg \
+                        ${PN}-plperl-dbg \
+                       "
+
 FILES_${PN} += "${sysconfdir}/init.d/${BPN}-server \
     ${localstatedir}/lib/${BPN}/data ${localstatedir}/lib/${BPN}/backups \
     ${localstatedir}/lib/${BPN}/.bash_profile ${sysconfdir}/default/${BPN} \
@@ -223,13 +232,6 @@
        else ''} \
 "
 
-FILES_${PN}-dbg += " ${libdir}/${BPN}/.debug/dict_snowball.so \
-    ${libdir}/${BPN}/.debug/plpgsql.so \
-    ${libdir}/${BPN}/.debug/euc2004_sjis2004.so \
-    ${libdir}/${BPN}/.debug/libpqwalreceiver.so \
-    ${libdir}/${BPN}/.debug/*_and_*.so \
-"
-
 FILES_${PN}-client = "${bindir}/clusterdb \
     ${bindir}/createdb \
     ${bindir}/createlang \
@@ -267,7 +269,6 @@
 FILES_${PN}-server-dev = "${includedir}/${BPN}/server"
 
 FILES_libecpg = "${libdir}/libecpg*${SOLIBS}"
-FILES_libecpg-dbg = "${libdir}/.debug/libecpg*"
 FILES_libecpg-dev = "${libdir}/libecpg*${SOLIBSDEV} \
     ${libdir}/libpgtypes*${SOLIBSDEV} \
     ${includedir}/ecpg*.h ${includedir}/${BPN}/ecpg*.h \
@@ -280,7 +281,6 @@
 RDEPENDS_libecpg-staticdev = "libecpg-dev (= ${EXTENDPKGV})"
 
 FILES_libpq = "${libdir}/libpq*${SOLIBS}"
-FILES_libpq-dbg = "${libdir}/.debug/libpq* ${libdir}/${BPN}/pgxs/src/test/regress/.debug/*"
 FILES_libpq-dev = "${libdir}/libpq*${SOLIBSDEV} \
     ${includedir} \
 "
@@ -289,10 +289,8 @@
 RDEPENDS_libpq-staticdev = "libpq-dev (= ${EXTENDPKGV})"
 
 FILES_libecpg-compat = "${libdir}/libecpg_compat*${SOLIBS}"
-FILES_libecpg-compat-dbg = "${libdir}/.debug/libecpg_compat*"
 FILES_libecpg-compat-dev = "${libdir}/libecpg_compat*${SOLIBS}"
 FILES_libpgtypes = "${libdir}/libpgtypes*${SOLIBS}"
-FILES_libpgtypes-dbg = "${libdir}/.debug/libpgtypes*"
 FILES_libpgtypes-staticdev = "${libdir}/libpgtypes*.a"
 FILES_libpgtypes-dev = "${libdir}/libpgtypes*${SOLIBS} ${includedir}/pgtypes*.h"
 
@@ -324,50 +322,18 @@
     ${libdir}/${BPN}/pg_upgrade_support.so ${libdir}/${BPN}/.so \
     ${libdir}/${BPN}/unaccent.so \
 "
-FILES_${PN}-contrib-dbg = " \
-    ${libdir}/${BPN}/.debug/_int.so ${libdir}/${BPN}/.debug/adminpack.so \
-    ${libdir}/${BPN}/.debug/autoinc.so ${libdir}/${BPN}/.debug/auto_explain.so \
-    ${libdir}/${BPN}/.debug/auth_delay.so ${libdir}/${BPN}/.debug/btree_gin.so \
-    ${libdir}/${BPN}/.debug/btree_gist.so ${libdir}/${BPN}/.debug/.so \
-    ${libdir}/${BPN}/.debug/chkpass.so ${libdir}/${BPN}/.debug/citext.so \
-    ${libdir}/${BPN}/.debug/cube.so ${libdir}/${BPN}/.debug/dblink.so \
-    ${libdir}/${BPN}/.debug/dict_int.so ${libdir}/${BPN}/.debug/dict_xsyn.so \
-    ${libdir}/${BPN}/.debug/dummy_seclabel.so \
-    ${libdir}/${BPN}/.debug/earthdistance.so \
-    ${libdir}/${BPN}/.debug/file_fdw.so ${libdir}/${BPN}/.debug/fuzzystrmatch.so \
-    ${libdir}/${BPN}/.debug/hstore.so ${libdir}/${BPN}/.debug/insert_username.so \
-    ${libdir}/${BPN}/.debug/isn.so ${libdir}/${BPN}/.debug/lo.so \
-    ${libdir}/${BPN}/.debug/ltree.so ${libdir}/${BPN}/.debug/moddatetime.so \
-    ${libdir}/${BPN}/.debug/pageinspect.so \
-    ${libdir}/${BPN}/.debug/pg_buffercache.so \
-    ${libdir}/${BPN}/.debug/pg_freespacemap.so \
-    ${libdir}/${BPN}/.debug/pg_trgm.so \
-    ${libdir}/${BPN}/.debug/pgcrypto.so ${libdir}/${BPN}/.debug/pgrowlocks.so \
-    ${libdir}/${BPN}/.debug/pgstattuple.so \
-    ${libdir}/${BPN}/.debug/pg_stat_statements.so \
-    ${libdir}/${BPN}/.debug/refint.so ${libdir}/${BPN}/.debug/seg.so \
-    ${libdir}/${BPN}/.debug/sslinfo.so \
-    ${libdir}/${BPN}/.debug/tablefunc.so \
-    ${libdir}/${BPN}/.debug/test_parser.so ${libdir}/${BPN}/.debug/timetravel.so \
-    ${libdir}/${BPN}/.debug/tsearch2.so ${libdir}/${BPN}/.debug/uuid-ossp.so \
-    ${libdir}/${BPN}/.debug/pgxml.so ${libdir}/${BPN}/.debug/passwordcheck.so \
-    ${libdir}/${BPN}/.debug/pg_upgrade_support.so \
-    ${libdir}/${BPN}/.debug/unaccent.so \
-"
 DESCRIPTION_${PN}-contrib = "The postgresql-contrib package contains \
     contributed packages that are included in the PostgreSQL distribution."
 
 FILES_${PN}-pltcl = "${libdir}/${BPN}/pltcl.so ${bindir}/pltcl_delmod \
     ${binddir}/pltcl_listmod ${bindir}/pltcl_loadmod  \
     ${datadir}/${BPN}/unknown.pltcl"
-FILES_${PN}-pltcl-dbg = "${libdir}/${BPN}/.debug/pltcl.so"
 SUMMARY_${PN}-pltcl = "The Tcl procedural language for PostgreSQL"
 DESCRIPTION_${PN}-pltcl = "PostgreSQL is an advanced Object-Relational \
     database management system.  The postgresql-pltcl package contains the PL/Tcl \
     procedural language for the backend."
 
 FILES_${PN}-plperl = "${libdir}/${BPN}/plperl.so"
-FILES_${PN}-plperl-dbg = "${libdir}/${BPN}/.debug/plperl.so"
 SUMMARY_${PN}-plperl = "The Perl procedural language for PostgreSQL"
 DESCRIPTION_${PN}-plperl = "PostgreSQL is an advanced Object-Relational \
     database management system.  The postgresql-plperl package contains the \
@@ -376,7 +342,6 @@
 # In version 8, it will be plpython.so
 # In version 9, it might be plpython{2,3}.so depending on python2 or 3
 FILES_${PN}-plpython = "${libdir}/${BPN}/plpython*.so"
-FILES_${PN}-plpython-dbg = "${libdir}/${BPN}/.debug/plpython*.so"
 SUMMARY_${PN}-plpython = "The Python procedural language for PostgreSQL"
 DESCRIPTION_${PN}-plpython = "PostgreSQL is an advanced Object-Relational \
     database management system.  The postgresql-plpython package contains \
diff --git a/meta-openembedded/meta-oe/recipes-dbs/postgresql/postgresql_10.5.bb b/meta-openembedded/meta-oe/recipes-dbs/postgresql/postgresql_10.5.bb
new file mode 100644
index 0000000..1a02f15
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-dbs/postgresql/postgresql_10.5.bb
@@ -0,0 +1,12 @@
+require postgresql.inc
+
+LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=6dc95e63aa4d72502ff8193dfe2ddd38"
+
+SRC_URI += "\
+    file://not-check-libperl.patch \
+    file://0001-Update-time-zone-data-files-to-tzdata-release-2018f.patch \
+    file://0001-Sync-our-copy-of-the-timezone-library-with-IANA-rele.patch \
+"
+
+SRC_URI[md5sum] = "a5fe5fdff2d6c28f65601398be0950df"
+SRC_URI[sha256sum] = "6c8e616c91a45142b85c0aeb1f29ebba4a361309e86469e0fb4617b6a73c4011"
diff --git a/meta-openembedded/meta-oe/recipes-dbs/postgresql/postgresql_9.4.20.bb b/meta-openembedded/meta-oe/recipes-dbs/postgresql/postgresql_9.4.20.bb
deleted file mode 100644
index 61f623e..0000000
--- a/meta-openembedded/meta-oe/recipes-dbs/postgresql/postgresql_9.4.20.bb
+++ /dev/null
@@ -1,14 +0,0 @@
-require postgresql.inc
-
-LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=6dc95e63aa4d72502ff8193dfe2ddd38"
-
-SRC_URI += "\
-    file://not-check-libperl.patch \
-"
-
-do_compile_prepend_libc-musl() {
-    sed -i -e 's/\-lnsl//g' ${B}/src/Makefile.global
-}
-
-SRC_URI[md5sum] = "5821867741c821736266f27b6b8a859a"
-SRC_URI[sha256sum] = "eeb1d8ddb2854c9e4d8b5cbd65665260c0ae8cbcb911003f24c2d82ccb97f87f"
diff --git a/meta-openembedded/meta-oe/recipes-dbs/rocksdb/rocksdb/0001-Fix-GitHub-issue-3716-gcc-8-warnings.patch b/meta-openembedded/meta-oe/recipes-dbs/rocksdb/rocksdb/0001-Fix-GitHub-issue-3716-gcc-8-warnings.patch
new file mode 100644
index 0000000..be49897
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-dbs/rocksdb/rocksdb/0001-Fix-GitHub-issue-3716-gcc-8-warnings.patch
@@ -0,0 +1,194 @@
+From 8d65d70b54d1d306a0a0b00e036bc8ddd39d8ec1 Mon Sep 17 00:00:00 2001
+From: "przemyslaw.skibinski@percona.com" <przemyslaw.skibinski@percona.com>
+Date: Fri, 20 Apr 2018 13:28:05 -0700
+Subject: [PATCH] Fix GitHub issue #3716: gcc-8 warnings
+
+Summary:
+Fix the following gcc-8 warnings:
+- conflicting C language linkage declaration [-Werror]
+- writing to an object with no trivial copy-assignment [-Werror=class-memaccess]
+- array subscript -1 is below array bounds [-Werror=array-bounds]
+
+Solves https://github.com/facebook/rocksdb/issues/3716
+Closes https://github.com/facebook/rocksdb/pull/3736
+
+Differential Revision: D7684161
+
+Pulled By: yiwu-arbug
+
+fbshipit-source-id: 47c0423d26b74add251f1d3595211eee1e41e54a
+---
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Backport [https://github.com/facebook/rocksdb/commit/dee95a1afc6c63515e7d94dec33acdb79638b6d7.patch]
+
+ db/c.cc                   | 77 ++++++++++++++-------------------------
+ memtable/inlineskiplist.h | 12 +++---
+ 2 files changed, 33 insertions(+), 56 deletions(-)
+
+diff --git a/db/c.cc b/db/c.cc
+index 064103ed4..0d485d096 100644
+--- a/db/c.cc
++++ b/db/c.cc
+@@ -1388,23 +1388,24 @@ void rocksdb_writebatch_put_log_data(
+   b->rep.PutLogData(Slice(blob, len));
+ }
+ 
++class H : public WriteBatch::Handler {
++ public:
++  void* state_;
++  void (*put_)(void*, const char* k, size_t klen, const char* v, size_t vlen);
++  void (*deleted_)(void*, const char* k, size_t klen);
++  virtual void Put(const Slice& key, const Slice& value) override {
++    (*put_)(state_, key.data(), key.size(), value.data(), value.size());
++  }
++  virtual void Delete(const Slice& key) override {
++    (*deleted_)(state_, key.data(), key.size());
++  }
++};
++
+ void rocksdb_writebatch_iterate(
+     rocksdb_writebatch_t* b,
+     void* state,
+     void (*put)(void*, const char* k, size_t klen, const char* v, size_t vlen),
+     void (*deleted)(void*, const char* k, size_t klen)) {
+-  class H : public WriteBatch::Handler {
+-   public:
+-    void* state_;
+-    void (*put_)(void*, const char* k, size_t klen, const char* v, size_t vlen);
+-    void (*deleted_)(void*, const char* k, size_t klen);
+-    virtual void Put(const Slice& key, const Slice& value) override {
+-      (*put_)(state_, key.data(), key.size(), value.data(), value.size());
+-    }
+-    virtual void Delete(const Slice& key) override {
+-      (*deleted_)(state_, key.data(), key.size());
+-    }
+-  };
+   H handler;
+   handler.state_ = state;
+   handler.put_ = put;
+@@ -1649,18 +1650,6 @@ void rocksdb_writebatch_wi_iterate(
+     void* state,
+     void (*put)(void*, const char* k, size_t klen, const char* v, size_t vlen),
+     void (*deleted)(void*, const char* k, size_t klen)) {
+-  class H : public WriteBatch::Handler {
+-   public:
+-    void* state_;
+-    void (*put_)(void*, const char* k, size_t klen, const char* v, size_t vlen);
+-    void (*deleted_)(void*, const char* k, size_t klen);
+-    virtual void Put(const Slice& key, const Slice& value) override {
+-      (*put_)(state_, key.data(), key.size(), value.data(), value.size());
+-    }
+-    virtual void Delete(const Slice& key) override {
+-      (*deleted_)(state_, key.data(), key.size());
+-    }
+-  };
+   H handler;
+   handler.state_ = state;
+   handler.put_ = put;
+@@ -3109,20 +3098,21 @@ void rocksdb_slicetransform_destroy(rocksdb_slicetransform_t* st) {
+   delete st;
+ }
+ 
++struct Wrapper : public rocksdb_slicetransform_t {
++  const SliceTransform* rep_;
++  ~Wrapper() { delete rep_; }
++  const char* Name() const override { return rep_->Name(); }
++  Slice Transform(const Slice& src) const override {
++    return rep_->Transform(src);
++  }
++  bool InDomain(const Slice& src) const override {
++    return rep_->InDomain(src);
++  }
++  bool InRange(const Slice& src) const override { return rep_->InRange(src); }
++  static void DoNothing(void*) { }
++};
++
+ rocksdb_slicetransform_t* rocksdb_slicetransform_create_fixed_prefix(size_t prefixLen) {
+-  struct Wrapper : public rocksdb_slicetransform_t {
+-    const SliceTransform* rep_;
+-    ~Wrapper() { delete rep_; }
+-    const char* Name() const override { return rep_->Name(); }
+-    Slice Transform(const Slice& src) const override {
+-      return rep_->Transform(src);
+-    }
+-    bool InDomain(const Slice& src) const override {
+-      return rep_->InDomain(src);
+-    }
+-    bool InRange(const Slice& src) const override { return rep_->InRange(src); }
+-    static void DoNothing(void*) { }
+-  };
+   Wrapper* wrapper = new Wrapper;
+   wrapper->rep_ = rocksdb::NewFixedPrefixTransform(prefixLen);
+   wrapper->state_ = nullptr;
+@@ -3131,19 +3121,6 @@ rocksdb_slicetransform_t* rocksdb_slicetransform_create_fixed_prefix(size_t pref
+ }
+ 
+ rocksdb_slicetransform_t* rocksdb_slicetransform_create_noop() {
+-  struct Wrapper : public rocksdb_slicetransform_t {
+-    const SliceTransform* rep_;
+-    ~Wrapper() { delete rep_; }
+-    const char* Name() const override { return rep_->Name(); }
+-    Slice Transform(const Slice& src) const override {
+-      return rep_->Transform(src);
+-    }
+-    bool InDomain(const Slice& src) const override {
+-      return rep_->InDomain(src);
+-    }
+-    bool InRange(const Slice& src) const override { return rep_->InRange(src); }
+-    static void DoNothing(void*) { }
+-  };
+   Wrapper* wrapper = new Wrapper;
+   wrapper->rep_ = rocksdb::NewNoopTransform();
+   wrapper->state_ = nullptr;
+diff --git a/memtable/inlineskiplist.h b/memtable/inlineskiplist.h
+index 702a7336d..eadda1dc1 100644
+--- a/memtable/inlineskiplist.h
++++ b/memtable/inlineskiplist.h
+@@ -280,7 +280,7 @@ struct InlineSkipList<Comparator>::Node {
+   // next_[0].  This is used for passing data from AllocateKey to Insert.
+   void StashHeight(const int height) {
+     assert(sizeof(int) <= sizeof(next_[0]));
+-    memcpy(&next_[0], &height, sizeof(int));
++    memcpy(static_cast<void*>(&next_[0]), &height, sizeof(int));
+   }
+ 
+   // Retrieves the value passed to StashHeight.  Undefined after a call
+@@ -300,30 +300,30 @@ struct InlineSkipList<Comparator>::Node {
+     assert(n >= 0);
+     // Use an 'acquire load' so that we observe a fully initialized
+     // version of the returned Node.
+-    return (next_[-n].load(std::memory_order_acquire));
++    return ((&next_[0] - n)->load(std::memory_order_acquire));
+   }
+ 
+   void SetNext(int n, Node* x) {
+     assert(n >= 0);
+     // Use a 'release store' so that anybody who reads through this
+     // pointer observes a fully initialized version of the inserted node.
+-    next_[-n].store(x, std::memory_order_release);
++    (&next_[0] - n)->store(x, std::memory_order_release);
+   }
+ 
+   bool CASNext(int n, Node* expected, Node* x) {
+     assert(n >= 0);
+-    return next_[-n].compare_exchange_strong(expected, x);
++    return (&next_[0] - n)->compare_exchange_strong(expected, x);
+   }
+ 
+   // No-barrier variants that can be safely used in a few locations.
+   Node* NoBarrier_Next(int n) {
+     assert(n >= 0);
+-    return next_[-n].load(std::memory_order_relaxed);
++    return (&next_[0] - n)->load(std::memory_order_relaxed);
+   }
+ 
+   void NoBarrier_SetNext(int n, Node* x) {
+     assert(n >= 0);
+-    next_[-n].store(x, std::memory_order_relaxed);
++    (&next_[0] - n)->store(x, std::memory_order_relaxed);
+   }
+ 
+   // Insert node after prev on specific level.
+-- 
+2.17.0
+
diff --git a/meta-openembedded/meta-oe/recipes-dbs/rocksdb/rocksdb_git.bb b/meta-openembedded/meta-oe/recipes-dbs/rocksdb/rocksdb_git.bb
index 1e6cbae..594d1a9 100644
--- a/meta-openembedded/meta-oe/recipes-dbs/rocksdb/rocksdb_git.bb
+++ b/meta-openembedded/meta-oe/recipes-dbs/rocksdb/rocksdb_git.bb
@@ -6,11 +6,13 @@
                     file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
                     file://LICENSE.leveldb;md5=fb04ff57a14f308f2eed4a9b87d45837"
 
-SRCREV = "8969445642039566214d650cc6614849e7dd5e17"
-SRCBRANCH = "5.12.fb"
-PV = "5.12.2"
+SRCREV = "c60df9d9e7629fe208a9b848293a5599f83d5e77"
+SRCBRANCH = "5.13.fb"
+PV = "5.13.1"
 
-SRC_URI = "git://github.com/facebook/${BPN}.git;branch=${SRCBRANCH}"
+SRC_URI = "git://github.com/facebook/${BPN}.git;branch=${SRCBRANCH} \
+           file://0001-Fix-GitHub-issue-3716-gcc-8-warnings.patch \
+          "
 
 S = "${WORKDIR}/git"
 
@@ -28,5 +30,3 @@
     -DWITH_TESTS=OFF \
     -DWITH_TOOLS=OFF \
 "
-
-FILES_${PN}-dev += "${libdir}/cmake"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/0001-add-base64-implementation.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/0001-add-base64-implementation.patch
deleted file mode 100644
index 680d21f..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/0001-add-base64-implementation.patch
+++ /dev/null
@@ -1,351 +0,0 @@
-From bbeb72f11c64f190b23abbed5f44311bd021bdc9 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 15 Sep 2017 15:46:38 -0700
-Subject: [PATCH 1/2] add base64 implementation
-
-musl needs it
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- system/core/adb/adb_auth_client.c |   2 +-
- system/core/adb/base64.c          | 315 ++++++++++++++++++++++++++++++++++++++
- 2 files changed, 316 insertions(+), 1 deletion(-)
- create mode 100644 system/core/adb/base64.c
-
-diff --git a/system/core/adb/adb_auth_client.c b/system/core/adb/adb_auth_client.c
-index 55e9dca..104b413 100644
---- a/system/core/adb/adb_auth_client.c
-+++ b/system/core/adb/adb_auth_client.c
-@@ -75,7 +75,7 @@ static void read_keys(const char *file, struct listnode *list)
-         if (sep)
-             *sep = '\0';
- 
--        ret = __b64_pton(buf, (u_char *)&key->key, sizeof(key->key) + 4);
-+        ret = b64_pton(buf, (u_char *)&key->key, sizeof(key->key) + 4);
-         if (ret != sizeof(key->key)) {
-             D("%s: Invalid base64 data ret=%d\n", file, ret);
-             free(key);
-diff --git a/system/core/adb/base64.c b/system/core/adb/base64.c
-new file mode 100644
-index 0000000..95da284
---- /dev/null
-+++ b/system/core/adb/base64.c
-@@ -0,0 +1,315 @@
-+/*
-+ * Copyright (c) 1996-1999 by Internet Software Consortium.
-+ *
-+ * Permission to use, copy, modify, and distribute this software for any
-+ * purpose with or without fee is hereby granted, provided that the above
-+ * copyright notice and this permission notice appear in all copies.
-+ *
-+ * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM DISCLAIMS
-+ * ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES
-+ * OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL INTERNET SOFTWARE
-+ * CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
-+ * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
-+ * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
-+ * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
-+ * SOFTWARE.
-+ */
-+
-+/*
-+ * Portions Copyright (c) 1995 by International Business Machines, Inc.
-+ *
-+ * International Business Machines, Inc. (hereinafter called IBM) grants
-+ * permission under its copyrights to use, copy, modify, and distribute this
-+ * Software with or without fee, provided that the above copyright notice and
-+ * all paragraphs of this notice appear in all copies, and that the name of IBM
-+ * not be used in connection with the marketing of any product incorporating
-+ * the Software or modifications thereof, without specific, written prior
-+ * permission.
-+ *
-+ * To the extent it has a right to do so, IBM grants an immunity from suit
-+ * under its patents, if any, for the use, sale or manufacture of products to
-+ * the extent that such products are used for performing Domain Name System
-+ * dynamic updates in TCP/IP networks by means of the Software.  No immunity is
-+ * granted for any product per se or for any other function of any product.
-+ *
-+ * THE SOFTWARE IS PROVIDED "AS IS", AND IBM DISCLAIMS ALL WARRANTIES,
-+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
-+ * PARTICULAR PURPOSE.  IN NO EVENT SHALL IBM BE LIABLE FOR ANY SPECIAL,
-+ * DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER ARISING
-+ * OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE, EVEN
-+ * IF IBM IS APPRISED OF THE POSSIBILITY OF SUCH DAMAGES.
-+ */
-+
-+#if !defined(LINT) && !defined(CODECENTER)
-+static const char rcsid[] = "$BINDId: base64.c,v 8.7 1999/10/13 16:39:33 vixie Exp $";
-+#endif /* not lint */
-+
-+#include <sys/types.h>
-+#include <sys/param.h>
-+#include <sys/socket.h>
-+
-+#include <netinet/in.h>
-+#include <arpa/inet.h>
-+#include <arpa/nameser.h>
-+
-+#include <ctype.h>
-+#include <resolv.h>
-+#include <stdio.h>
-+#include <stdlib.h>
-+#include <stdint.h>
-+#include <string.h>
-+
-+#define Assert(Cond) if (!(Cond)) abort()
-+
-+static const char Base64[] =
-+	"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
-+static const char Pad64 = '=';
-+
-+/* (From RFC1521 and draft-ietf-dnssec-secext-03.txt)
-+   The following encoding technique is taken from RFC 1521 by Borenstein
-+   and Freed.  It is reproduced here in a slightly edited form for
-+   convenience.
-+
-+   A 65-character subset of US-ASCII is used, enabling 6 bits to be
-+   represented per printable character. (The extra 65th character, "=",
-+   is used to signify a special processing function.)
-+
-+   The encoding process represents 24-bit groups of input bits as output
-+   strings of 4 encoded characters. Proceeding from left to right, a
-+   24-bit input group is formed by concatenating 3 8-bit input groups.
-+   These 24 bits are then treated as 4 concatenated 6-bit groups, each
-+   of which is translated into a single digit in the base64 alphabet.
-+
-+   Each 6-bit group is used as an index into an array of 64 printable
-+   characters. The character referenced by the index is placed in the
-+   output string.
-+
-+                         Table 1: The Base64 Alphabet
-+
-+      Value Encoding  Value Encoding  Value Encoding  Value Encoding
-+          0 A            17 R            34 i            51 z
-+          1 B            18 S            35 j            52 0
-+          2 C            19 T            36 k            53 1
-+          3 D            20 U            37 l            54 2
-+          4 E            21 V            38 m            55 3
-+          5 F            22 W            39 n            56 4
-+          6 G            23 X            40 o            57 5
-+          7 H            24 Y            41 p            58 6
-+          8 I            25 Z            42 q            59 7
-+          9 J            26 a            43 r            60 8
-+         10 K            27 b            44 s            61 9
-+         11 L            28 c            45 t            62 +
-+         12 M            29 d            46 u            63 /
-+         13 N            30 e            47 v
-+         14 O            31 f            48 w         (pad) =
-+         15 P            32 g            49 x
-+         16 Q            33 h            50 y
-+
-+   Special processing is performed if fewer than 24 bits are available
-+   at the end of the data being encoded.  A full encoding quantum is
-+   always completed at the end of a quantity.  When fewer than 24 input
-+   bits are available in an input group, zero bits are added (on the
-+   right) to form an integral number of 6-bit groups.  Padding at the
-+   end of the data is performed using the '=' character.
-+
-+   Since all base64 input is an integral number of octets, only the
-+         -------------------------------------------------
-+   following cases can arise:
-+
-+       (1) the final quantum of encoding input is an integral
-+           multiple of 24 bits; here, the final unit of encoded
-+	   output will be an integral multiple of 4 characters
-+	   with no "=" padding,
-+       (2) the final quantum of encoding input is exactly 8 bits;
-+           here, the final unit of encoded output will be two
-+	   characters followed by two "=" padding characters, or
-+       (3) the final quantum of encoding input is exactly 16 bits;
-+           here, the final unit of encoded output will be three
-+	   characters followed by one "=" padding character.
-+   */
-+
-+int
-+b64_ntop(const uint8_t* src, size_t srclength, char* target, size_t targsize)
-+{
-+	size_t datalength = 0;
-+	uint8_t input[3];
-+	uint8_t output[4];
-+	size_t i;
-+
-+	while (2 < srclength) {
-+		input[0] = *src++;
-+		input[1] = *src++;
-+		input[2] = *src++;
-+		srclength -= 3;
-+
-+		output[0] = input[0] >> 2;
-+		output[1] = ((input[0] & 0x03) << 4) + (input[1] >> 4);
-+		output[2] = ((input[1] & 0x0f) << 2) + (input[2] >> 6);
-+		output[3] = input[2] & 0x3f;
-+		Assert(output[0] < 64);
-+		Assert(output[1] < 64);
-+		Assert(output[2] < 64);
-+		Assert(output[3] < 64);
-+
-+		if (datalength + 4 > targsize)
-+			return (-1);
-+		target[datalength++] = Base64[output[0]];
-+		target[datalength++] = Base64[output[1]];
-+		target[datalength++] = Base64[output[2]];
-+		target[datalength++] = Base64[output[3]];
-+	}
-+
-+	/* Now we worry about padding. */
-+	if (0 != srclength) {
-+		/* Get what's left. */
-+		input[0] = input[1] = input[2] = '\0';
-+		for (i = 0; i < srclength; i++)
-+			input[i] = *src++;
-+
-+		output[0] = input[0] >> 2;
-+		output[1] = ((input[0] & 0x03) << 4) + (input[1] >> 4);
-+		output[2] = ((input[1] & 0x0f) << 2) + (input[2] >> 6);
-+		Assert(output[0] < 64);
-+		Assert(output[1] < 64);
-+		Assert(output[2] < 64);
-+
-+		if (datalength + 4 > targsize)
-+			return (-1);
-+		target[datalength++] = Base64[output[0]];
-+		target[datalength++] = Base64[output[1]];
-+		if (srclength == 1)
-+			target[datalength++] = Pad64;
-+		else
-+			target[datalength++] = Base64[output[2]];
-+		target[datalength++] = Pad64;
-+	}
-+	if (datalength >= targsize)
-+		return (-1);
-+	target[datalength] = '\0';	/* Returned value doesn't count \0. */
-+	return (datalength);
-+}
-+
-+/* skips all whitespace anywhere.
-+   converts characters, four at a time, starting at (or after)
-+   src from base - 64 numbers into three 8 bit bytes in the target area.
-+   it returns the number of data bytes stored at the target, or -1 on error.
-+ */
-+
-+int b64_pton(const char* src, uint8_t* target, size_t targsize)
-+{
-+	int tarindex, state, ch;
-+	char *pos;
-+
-+	state = 0;
-+	tarindex = 0;
-+
-+	while ((ch = *src++) != '\0') {
-+		if (isspace(ch))	/* Skip whitespace anywhere. */
-+			continue;
-+
-+		if (ch == Pad64)
-+			break;
-+
-+		pos = strchr(Base64, ch);
-+		if (pos == 0) 		/* A non-base64 character. */
-+			return (-1);
-+
-+		switch (state) {
-+		case 0:
-+			if (target) {
-+				if ((size_t)tarindex >= targsize)
-+					return (-1);
-+				target[tarindex] = (pos - Base64) << 2;
-+			}
-+			state = 1;
-+			break;
-+		case 1:
-+			if (target) {
-+				if ((size_t)tarindex + 1 >= targsize)
-+					return (-1);
-+				target[tarindex]   |=  (pos - Base64) >> 4;
-+				target[tarindex+1]  = ((pos - Base64) & 0x0f)
-+							<< 4 ;
-+			}
-+			tarindex++;
-+			state = 2;
-+			break;
-+		case 2:
-+			if (target) {
-+				if ((size_t)tarindex + 1 >= targsize)
-+					return (-1);
-+				target[tarindex]   |=  (pos - Base64) >> 2;
-+				target[tarindex+1]  = ((pos - Base64) & 0x03)
-+							<< 6;
-+			}
-+			tarindex++;
-+			state = 3;
-+			break;
-+		case 3:
-+			if (target) {
-+				if ((size_t)tarindex >= targsize)
-+					return (-1);
-+				target[tarindex] |= (pos - Base64);
-+			}
-+			tarindex++;
-+			state = 0;
-+			break;
-+		default:
-+			abort();
-+		}
-+	}
-+
-+	/*
-+	 * We are done decoding Base-64 chars.  Let's see if we ended
-+	 * on a byte boundary, and/or with erroneous trailing characters.
-+	 */
-+
-+	if (ch == Pad64) {		/* We got a pad char. */
-+		ch = *src++;		/* Skip it, get next. */
-+		switch (state) {
-+		case 0:		/* Invalid = in first position */
-+		case 1:		/* Invalid = in second position */
-+			return (-1);
-+
-+		case 2:		/* Valid, means one byte of info */
-+			/* Skip any number of spaces. */
-+			for ((void)NULL; ch != '\0'; ch = *src++)
-+				if (!isspace(ch))
-+					break;
-+			/* Make sure there is another trailing = sign. */
-+			if (ch != Pad64)
-+				return (-1);
-+			ch = *src++;		/* Skip the = */
-+			/* Fall through to "single trailing =" case. */
-+			/* FALLTHROUGH */
-+
-+		case 3:		/* Valid, means two bytes of info */
-+			/*
-+			 * We know this char is an =.  Is there anything but
-+			 * whitespace after it?
-+			 */
-+			for ((void)NULL; ch != '\0'; ch = *src++)
-+				if (!isspace(ch))
-+					return (-1);
-+
-+			/*
-+			 * Now make sure for cases 2 and 3 that the "extra"
-+			 * bits that slopped past the last full byte were
-+			 * zeros.  If we don't check them, they become a
-+			 * subliminal channel.
-+			 */
-+			if (target && target[tarindex] != 0)
-+				return (-1);
-+		}
-+	} else {
-+		/*
-+		 * We ended by seeing the end of the string.  Make sure we
-+		 * have no partial bytes lying around.
-+		 */
-+		if (state != 0)
-+			return (-1);
-+	}
-+
-+	return (tarindex);
-+}
-+
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/0002-adb-Musl-fixes.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/0002-adb-Musl-fixes.patch
deleted file mode 100644
index c7aebb6..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/0002-adb-Musl-fixes.patch
+++ /dev/null
@@ -1,134 +0,0 @@
-From f8653ed0ede4aa781ab758fcd44fdc05ffbe0b0a Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 15 Sep 2017 15:50:57 -0700
-Subject: [PATCH 2/2] adb: Musl fixes
-
-__nonnull is gcc specific
-include sys/types.h for size_t
-Do not redefine close() and lseek()
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- system/core/adb/adb.h                    |  2 ++
- system/core/adb/disable_verity_service.c | 13 ++++++++-----
- system/core/adb/framebuffer_service.c    |  7 ++++---
- system/core/adb/sysdeps.h                | 12 ++++++------
- 4 files changed, 20 insertions(+), 14 deletions(-)
-
-diff --git a/system/core/adb/adb.h b/system/core/adb/adb.h
-index 44e5981..bcdc49f 100644
---- a/system/core/adb/adb.h
-+++ b/system/core/adb/adb.h
-@@ -18,7 +18,9 @@
- #define __ADB_H
- 
- #include <limits.h>
-+#include <sys/types.h>
- 
-+#include "fdevent.h"
- #include "adb_trace.h"
- #include "transport.h"  /* readx(), writex() */
- 
-diff --git a/system/core/adb/disable_verity_service.c b/system/core/adb/disable_verity_service.c
-index ed3da52..29fa3d6 100644
---- a/system/core/adb/disable_verity_service.c
-+++ b/system/core/adb/disable_verity_service.c
-@@ -14,25 +14,28 @@
-  * limitations under the License.
-  */
- 
--#include "sysdeps.h"
- 
- #define  TRACE_TAG  TRACE_ADB
- #include "adb.h"
-+#include "sysdeps.h"
-+#include "cutils/properties.h"
-+#include "ext4_sb.h"
-+#include <fs_mgr.h>
- 
- #include <stdio.h>
- #include <stdarg.h>
- #include <sys/stat.h>
- #include <fcntl.h>
- #include <inttypes.h>
-+#include <unistd.h>
-+#include <errno.h>
-+#include <stdbool.h>
- 
--#include "cutils/properties.h"
--#include "ext4_sb.h"
--#include <fs_mgr.h>
- 
- #define FSTAB_PREFIX "/fstab."
- struct fstab *fstab;
- 
--__attribute__((__format__(printf, 2, 3))) __nonnull((2))
-+__attribute__((__format__(printf, 2, 3))) __attribute__((nonnull((2))))
- static void write_console(int fd, const char* format, ...)
- {
-     char buffer[256];
-diff --git a/system/core/adb/framebuffer_service.c b/system/core/adb/framebuffer_service.c
-index 8cbe840..8f0ccfb 100644
---- a/system/core/adb/framebuffer_service.c
-+++ b/system/core/adb/framebuffer_service.c
-@@ -14,6 +14,10 @@
-  * limitations under the License.
-  */
- 
-+#include "fdevent.h"
-+#include "adb.h"
-+#include "sysdeps.h"
-+
- #include <stdlib.h>
- #include <stdio.h>
- #include <unistd.h>
-@@ -23,9 +27,6 @@
- #include <sys/types.h>
- #include <sys/wait.h>
- 
--#include "fdevent.h"
--#include "adb.h"
--
- #include <linux/fb.h>
- #include <sys/ioctl.h>
- #include <sys/mman.h>
-diff --git a/system/core/adb/sysdeps.h b/system/core/adb/sysdeps.h
-index cc1f839..ea39ac3 100644
---- a/system/core/adb/sysdeps.h
-+++ b/system/core/adb/sysdeps.h
-@@ -123,8 +123,8 @@ static __inline__ int  unix_close(int fd)
- {
-     return close(fd);
- }
--#undef   close
--#define  close   ____xxx_close
-+//#undef   close
-+//#define  close   ____xxx_close
- 
- static __inline__  int  unix_read(int  fd, void*  buf, size_t  len)
- {
-@@ -369,8 +369,8 @@ static __inline__ int  adb_close(int fd)
- {
-     return close(fd);
- }
--#undef   close
--#define  close   ____xxx_close
-+//#undef   close
-+//#define  close   ____xxx_close
- 
- 
- static __inline__  int  adb_read(int  fd, void*  buf, size_t  len)
-@@ -392,8 +392,8 @@ static __inline__ int   adb_lseek(int  fd, int  pos, int  where)
- {
-     return lseek(fd, pos, where);
- }
--#undef   lseek
--#define  lseek   ___xxx_lseek
-+//#undef   lseek
-+//#define  lseek   ___xxx_lseek
- 
- static __inline__  int    adb_unlink(const char*  path)
- {
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/android-tools-adbd.service b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/android-tools-adbd.service
index 88ed687..ddf8d7f 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/android-tools-adbd.service
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/android-tools-adbd.service
@@ -1,12 +1,13 @@
 [Unit]
 Description=Android Debug Bridge
+ConditionPathExists=/var/usb-debugging-enabled
+Before=android-system.service
 
 [Service]
 Type=simple
 Restart=on-failure
-ExecStartPre=/usr/bin/android-gadget-setup adb
+ExecStartPre=-/usr/bin/android-gadget-setup adb
 ExecStart=/usr/bin/adbd
-StandardOutput=null
 
 [Install]
 WantedBy=basic.target
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0001-adb-remove-selinux-extensions.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0001-adb-remove-selinux-extensions.patch
new file mode 100644
index 0000000..7d20c50
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0001-adb-remove-selinux-extensions.patch
@@ -0,0 +1,44 @@
+From 7b7200727413ca4a9bb132221c543ec033dffafa Mon Sep 17 00:00:00 2001
+From: Sergio Schvezov <sergio.schvezov@canonical.com>
+Date: Wed, 7 Sep 2016 12:58:47 +0300
+Subject: [PATCH] adb: remove selinux extensions
+
+* drop useless includes of Android SELINUX extensions
+* avoids having to clone another module
+* this should be sent upstream
+
+Upstream-Status: Inappropriate
+
+Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
+---
+ adb/file_sync_service.c | 3 ---
+ 1 file changed, 3 deletions(-)
+
+diff --git a/adb/file_sync_service.c b/adb/file_sync_service.c
+index 7933858516..3cbd0cd863 100644
+--- a/adb/file_sync_service.c
++++ b/adb/file_sync_service.c
+@@ -26,7 +26,6 @@
+ 
+ #include <errno.h>
+ #include <private/android_filesystem_config.h>
+-#include <selinux/android.h>
+ #include "sysdeps.h"
+ 
+ #define TRACE_TAG  TRACE_SYNC
+@@ -73,7 +72,6 @@ static int mkdirs(char *name)
+                 *x = '/';
+                 return ret;
+             }
+-            selinux_android_restorecon(name, 0);
+         }
+         *x++ = '/';
+     }
+@@ -251,7 +249,6 @@ static int handle_send_file(int s, char *path, uid_t uid,
+     if(fd >= 0) {
+         struct utimbuf u;
+         adb_close(fd);
+-        selinux_android_restorecon(path, 0);
+         u.actime = timestamp;
+         u.modtime = timestamp;
+         utime(path, &u);
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0002-adb-Use-local-sockets-where-appropriate.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0002-adb-Use-local-sockets-where-appropriate.patch
new file mode 100644
index 0000000..3627110
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0002-adb-Use-local-sockets-where-appropriate.patch
@@ -0,0 +1,70 @@
+From d855f042ca09a358cebe2d3c1d29d512afd7ebb8 Mon Sep 17 00:00:00 2001
+From: Hilko Bengen <bengen@debian.org>
+Date: Wed, 7 Sep 2016 12:58:47 +0300
+Subject: [PATCH] adb: Use local sockets where appropriate
+
+Upstream-Status: Inappropriate
+---
+ adb/adb.c             | 6 +++++-
+ adb/adb_client.c      | 5 +++--
+ adb/transport_local.c | 3 ++-
+ 3 files changed, 10 insertions(+), 4 deletions(-)
+
+diff --git a/adb/adb.c b/adb/adb.c
+index 10a1e0da26..027edd9359 100644
+--- a/adb/adb.c
++++ b/adb/adb.c
+@@ -1230,7 +1230,11 @@ int launch_server(int server_port)
+  */
+ void build_local_name(char* target_str, size_t target_size, int server_port)
+ {
+-  snprintf(target_str, target_size, "tcp:%d", server_port);
++  if (gListenAll > 0) {
++    snprintf(target_str, target_size, "tcp:%d", server_port);
++  } else {
++    snprintf(target_str, target_size, "local:%d", server_port);
++  }
+ }
+ 
+ #if !ADB_HOST
+diff --git a/adb/adb_client.c b/adb/adb_client.c
+index eb1720d22c..a383faefe3 100644
+--- a/adb/adb_client.c
++++ b/adb/adb_client.c
+@@ -185,12 +185,12 @@ int _adb_connect(const char *service)
+         strcpy(__adb_error, "service name too long");
+         return -1;
+     }
+-    snprintf(tmp, sizeof tmp, "%04x", len);
++    snprintf(tmp, sizeof tmp, "%d", __adb_server_port);
+ 
+     if (__adb_server_name)
+         fd = socket_network_client(__adb_server_name, __adb_server_port, SOCK_STREAM);
+     else
+-        fd = socket_loopback_client(__adb_server_port, SOCK_STREAM);
++        fd = socket_local_client(tmp, ANDROID_SOCKET_NAMESPACE_ABSTRACT, SOCK_STREAM);
+ 
+     if(fd < 0) {
+         strcpy(__adb_error, "cannot connect to daemon");
+@@ -201,6 +201,7 @@ int _adb_connect(const char *service)
+         return -1;
+     }
+ 
++    snprintf(tmp, sizeof tmp, "%04x", len);
+     if(writex(fd, tmp, 4) || writex(fd, service, len)) {
+         strcpy(__adb_error, "write failure during connection");
+         adb_close(fd);
+diff --git a/adb/transport_local.c b/adb/transport_local.c
+index 948cc15812..71582a8c88 100644
+--- a/adb/transport_local.c
++++ b/adb/transport_local.c
+@@ -121,7 +121,8 @@ int local_connect_arbitrary_ports(int console_port, int adb_port)
+     }
+ #endif
+     if (fd < 0) {
+-        fd = socket_loopback_client(adb_port, SOCK_STREAM);
++        snprintf(buf, sizeof buf, "%d", adb_port);
++        fd = socket_local_client(buf, ANDROID_SOCKET_NAMESPACE_ABSTRACT, SOCK_STREAM);
+     }
+ 
+     if (fd >= 0) {
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0003-adb-define-shell-command.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0003-adb-define-shell-command.patch
new file mode 100644
index 0000000..cf1d9cb
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0003-adb-define-shell-command.patch
@@ -0,0 +1,29 @@
+From 4421c2e19946dcd651fd8ac022b96627fc526149 Mon Sep 17 00:00:00 2001
+From: Fathi Boudra <fabo@debian.org>
+Date: Wed, 7 Sep 2016 12:58:47 +0300
+Subject: [PATCH] adb: define shell command
+
+we intend to run on Linux system so the shell is always /bin/sh,
+for the host or the target.
+
+Upstream-Status: Inappropriate
+---
+ adb/services.c | 4 ----
+ 1 file changed, 4 deletions(-)
+
+diff --git a/adb/services.c b/adb/services.c
+index 21b08dc201..d44b0c5068 100644
+--- a/adb/services.c
++++ b/adb/services.c
+@@ -299,11 +299,7 @@ static int create_subproc_raw(const char *cmd, const char *arg0, const char *arg
+ }
+ #endif  /* !ABD_HOST */
+ 
+-#if ADB_HOST
+ #define SHELL_COMMAND "/bin/sh"
+-#else
+-#define SHELL_COMMAND "/system/bin/sh"
+-#endif
+ 
+ #if !ADB_HOST
+ static void subproc_waiter_service(int fd, void *cookie)
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0004-adb-Fix-build-on-big-endian-systems.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0004-adb-Fix-build-on-big-endian-systems.patch
new file mode 100644
index 0000000..79e9d4d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0004-adb-Fix-build-on-big-endian-systems.patch
@@ -0,0 +1,45 @@
+From 548b8ca62c64a16305929e2eaf3d546d48de9c25 Mon Sep 17 00:00:00 2001
+From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
+Date: Tue, 21 Feb 2017 19:46:24 +0100
+Subject: [PATCH] adb: Fix build on big endian systems
+
+The usb_linux_client.c file defines cpu_to_le16/32 by using the C
+library htole16/32 function calls. However, cpu_to_le16/32 are used
+when initializing structures, i.e in a context where a function call
+is not allowed.
+
+It works fine on little endian systems because htole16/32 are defined
+by the C library as no-ops. But on big-endian systems, they are
+actually doing something, which might involve calling a function,
+causing build failures.
+
+To solve this, we simply open-code cpu_to_le16/32 in a way that allows
+them to be used when initializing structures.
+
+Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
+---
+ adb/usb_linux_client.c | 11 +++++++++--
+ 1 file changed, 9 insertions(+), 2 deletions(-)
+
+diff --git a/adb/usb_linux_client.c b/adb/usb_linux_client.c
+index 8426e0ea14..6e8b5bbbd2 100644
+--- a/adb/usb_linux_client.c
++++ b/adb/usb_linux_client.c
+@@ -34,8 +34,15 @@
+ #define MAX_PACKET_SIZE_FS	64
+ #define MAX_PACKET_SIZE_HS	512
+ 
+-#define cpu_to_le16(x)  htole16(x)
+-#define cpu_to_le32(x)  htole32(x)
++#if __BYTE_ORDER == __LITTLE_ENDIAN
++# define cpu_to_le16(x) (x)
++# define cpu_to_le32(x) (x)
++#else
++# define cpu_to_le16(x) ((((x) >> 8) & 0xffu) | (((x) & 0xffu) << 8))
++# define cpu_to_le32(x) \
++	((((x) & 0xff000000u) >> 24) | (((x) & 0x00ff0000u) >>  8) | \
++	 (((x) & 0x0000ff00u) <<  8) | (((x) & 0x000000ffu) << 24))
++#endif
+ 
+ struct usb_handle
+ {
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0005-adb-add-base64-implementation.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0005-adb-add-base64-implementation.patch
new file mode 100644
index 0000000..fcd4ae2
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0005-adb-add-base64-implementation.patch
@@ -0,0 +1,348 @@
+From 753bcb5971401b82fb2e6197d31c9e386f6d0392 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 15 Sep 2017 15:46:38 -0700
+Subject: [PATCH] adb: add base64 implementation
+
+musl needs it
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ adb/adb_auth_client.c |   2 +-
+ adb/base64.c          | 315 ++++++++++++++++++++++++++++++++++++++++++
+ 2 files changed, 316 insertions(+), 1 deletion(-)
+ create mode 100644 adb/base64.c
+
+diff --git a/adb/adb_auth_client.c b/adb/adb_auth_client.c
+index 55e9dcad19..104b413b8b 100644
+--- a/adb/adb_auth_client.c
++++ b/adb/adb_auth_client.c
+@@ -75,7 +75,7 @@ static void read_keys(const char *file, struct listnode *list)
+         if (sep)
+             *sep = '\0';
+ 
+-        ret = __b64_pton(buf, (u_char *)&key->key, sizeof(key->key) + 4);
++        ret = b64_pton(buf, (u_char *)&key->key, sizeof(key->key) + 4);
+         if (ret != sizeof(key->key)) {
+             D("%s: Invalid base64 data ret=%d\n", file, ret);
+             free(key);
+diff --git a/adb/base64.c b/adb/base64.c
+new file mode 100644
+index 0000000000..95da284d0d
+--- /dev/null
++++ b/adb/base64.c
+@@ -0,0 +1,315 @@
++/*
++ * Copyright (c) 1996-1999 by Internet Software Consortium.
++ *
++ * Permission to use, copy, modify, and distribute this software for any
++ * purpose with or without fee is hereby granted, provided that the above
++ * copyright notice and this permission notice appear in all copies.
++ *
++ * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM DISCLAIMS
++ * ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES
++ * OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL INTERNET SOFTWARE
++ * CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
++ * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
++ * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
++ * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
++ * SOFTWARE.
++ */
++
++/*
++ * Portions Copyright (c) 1995 by International Business Machines, Inc.
++ *
++ * International Business Machines, Inc. (hereinafter called IBM) grants
++ * permission under its copyrights to use, copy, modify, and distribute this
++ * Software with or without fee, provided that the above copyright notice and
++ * all paragraphs of this notice appear in all copies, and that the name of IBM
++ * not be used in connection with the marketing of any product incorporating
++ * the Software or modifications thereof, without specific, written prior
++ * permission.
++ *
++ * To the extent it has a right to do so, IBM grants an immunity from suit
++ * under its patents, if any, for the use, sale or manufacture of products to
++ * the extent that such products are used for performing Domain Name System
++ * dynamic updates in TCP/IP networks by means of the Software.  No immunity is
++ * granted for any product per se or for any other function of any product.
++ *
++ * THE SOFTWARE IS PROVIDED "AS IS", AND IBM DISCLAIMS ALL WARRANTIES,
++ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
++ * PARTICULAR PURPOSE.  IN NO EVENT SHALL IBM BE LIABLE FOR ANY SPECIAL,
++ * DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER ARISING
++ * OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE, EVEN
++ * IF IBM IS APPRISED OF THE POSSIBILITY OF SUCH DAMAGES.
++ */
++
++#if !defined(LINT) && !defined(CODECENTER)
++static const char rcsid[] = "$BINDId: base64.c,v 8.7 1999/10/13 16:39:33 vixie Exp $";
++#endif /* not lint */
++
++#include <sys/types.h>
++#include <sys/param.h>
++#include <sys/socket.h>
++
++#include <netinet/in.h>
++#include <arpa/inet.h>
++#include <arpa/nameser.h>
++
++#include <ctype.h>
++#include <resolv.h>
++#include <stdio.h>
++#include <stdlib.h>
++#include <stdint.h>
++#include <string.h>
++
++#define Assert(Cond) if (!(Cond)) abort()
++
++static const char Base64[] =
++	"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
++static const char Pad64 = '=';
++
++/* (From RFC1521 and draft-ietf-dnssec-secext-03.txt)
++   The following encoding technique is taken from RFC 1521 by Borenstein
++   and Freed.  It is reproduced here in a slightly edited form for
++   convenience.
++
++   A 65-character subset of US-ASCII is used, enabling 6 bits to be
++   represented per printable character. (The extra 65th character, "=",
++   is used to signify a special processing function.)
++
++   The encoding process represents 24-bit groups of input bits as output
++   strings of 4 encoded characters. Proceeding from left to right, a
++   24-bit input group is formed by concatenating 3 8-bit input groups.
++   These 24 bits are then treated as 4 concatenated 6-bit groups, each
++   of which is translated into a single digit in the base64 alphabet.
++
++   Each 6-bit group is used as an index into an array of 64 printable
++   characters. The character referenced by the index is placed in the
++   output string.
++
++                         Table 1: The Base64 Alphabet
++
++      Value Encoding  Value Encoding  Value Encoding  Value Encoding
++          0 A            17 R            34 i            51 z
++          1 B            18 S            35 j            52 0
++          2 C            19 T            36 k            53 1
++          3 D            20 U            37 l            54 2
++          4 E            21 V            38 m            55 3
++          5 F            22 W            39 n            56 4
++          6 G            23 X            40 o            57 5
++          7 H            24 Y            41 p            58 6
++          8 I            25 Z            42 q            59 7
++          9 J            26 a            43 r            60 8
++         10 K            27 b            44 s            61 9
++         11 L            28 c            45 t            62 +
++         12 M            29 d            46 u            63 /
++         13 N            30 e            47 v
++         14 O            31 f            48 w         (pad) =
++         15 P            32 g            49 x
++         16 Q            33 h            50 y
++
++   Special processing is performed if fewer than 24 bits are available
++   at the end of the data being encoded.  A full encoding quantum is
++   always completed at the end of a quantity.  When fewer than 24 input
++   bits are available in an input group, zero bits are added (on the
++   right) to form an integral number of 6-bit groups.  Padding at the
++   end of the data is performed using the '=' character.
++
++   Since all base64 input is an integral number of octets, only the
++         -------------------------------------------------
++   following cases can arise:
++
++       (1) the final quantum of encoding input is an integral
++           multiple of 24 bits; here, the final unit of encoded
++	   output will be an integral multiple of 4 characters
++	   with no "=" padding,
++       (2) the final quantum of encoding input is exactly 8 bits;
++           here, the final unit of encoded output will be two
++	   characters followed by two "=" padding characters, or
++       (3) the final quantum of encoding input is exactly 16 bits;
++           here, the final unit of encoded output will be three
++	   characters followed by one "=" padding character.
++   */
++
++int
++b64_ntop(const uint8_t* src, size_t srclength, char* target, size_t targsize)
++{
++	size_t datalength = 0;
++	uint8_t input[3];
++	uint8_t output[4];
++	size_t i;
++
++	while (2 < srclength) {
++		input[0] = *src++;
++		input[1] = *src++;
++		input[2] = *src++;
++		srclength -= 3;
++
++		output[0] = input[0] >> 2;
++		output[1] = ((input[0] & 0x03) << 4) + (input[1] >> 4);
++		output[2] = ((input[1] & 0x0f) << 2) + (input[2] >> 6);
++		output[3] = input[2] & 0x3f;
++		Assert(output[0] < 64);
++		Assert(output[1] < 64);
++		Assert(output[2] < 64);
++		Assert(output[3] < 64);
++
++		if (datalength + 4 > targsize)
++			return (-1);
++		target[datalength++] = Base64[output[0]];
++		target[datalength++] = Base64[output[1]];
++		target[datalength++] = Base64[output[2]];
++		target[datalength++] = Base64[output[3]];
++	}
++
++	/* Now we worry about padding. */
++	if (0 != srclength) {
++		/* Get what's left. */
++		input[0] = input[1] = input[2] = '\0';
++		for (i = 0; i < srclength; i++)
++			input[i] = *src++;
++
++		output[0] = input[0] >> 2;
++		output[1] = ((input[0] & 0x03) << 4) + (input[1] >> 4);
++		output[2] = ((input[1] & 0x0f) << 2) + (input[2] >> 6);
++		Assert(output[0] < 64);
++		Assert(output[1] < 64);
++		Assert(output[2] < 64);
++
++		if (datalength + 4 > targsize)
++			return (-1);
++		target[datalength++] = Base64[output[0]];
++		target[datalength++] = Base64[output[1]];
++		if (srclength == 1)
++			target[datalength++] = Pad64;
++		else
++			target[datalength++] = Base64[output[2]];
++		target[datalength++] = Pad64;
++	}
++	if (datalength >= targsize)
++		return (-1);
++	target[datalength] = '\0';	/* Returned value doesn't count \0. */
++	return (datalength);
++}
++
++/* skips all whitespace anywhere.
++   converts characters, four at a time, starting at (or after)
++   src from base - 64 numbers into three 8 bit bytes in the target area.
++   it returns the number of data bytes stored at the target, or -1 on error.
++ */
++
++int b64_pton(const char* src, uint8_t* target, size_t targsize)
++{
++	int tarindex, state, ch;
++	char *pos;
++
++	state = 0;
++	tarindex = 0;
++
++	while ((ch = *src++) != '\0') {
++		if (isspace(ch))	/* Skip whitespace anywhere. */
++			continue;
++
++		if (ch == Pad64)
++			break;
++
++		pos = strchr(Base64, ch);
++		if (pos == 0) 		/* A non-base64 character. */
++			return (-1);
++
++		switch (state) {
++		case 0:
++			if (target) {
++				if ((size_t)tarindex >= targsize)
++					return (-1);
++				target[tarindex] = (pos - Base64) << 2;
++			}
++			state = 1;
++			break;
++		case 1:
++			if (target) {
++				if ((size_t)tarindex + 1 >= targsize)
++					return (-1);
++				target[tarindex]   |=  (pos - Base64) >> 4;
++				target[tarindex+1]  = ((pos - Base64) & 0x0f)
++							<< 4 ;
++			}
++			tarindex++;
++			state = 2;
++			break;
++		case 2:
++			if (target) {
++				if ((size_t)tarindex + 1 >= targsize)
++					return (-1);
++				target[tarindex]   |=  (pos - Base64) >> 2;
++				target[tarindex+1]  = ((pos - Base64) & 0x03)
++							<< 6;
++			}
++			tarindex++;
++			state = 3;
++			break;
++		case 3:
++			if (target) {
++				if ((size_t)tarindex >= targsize)
++					return (-1);
++				target[tarindex] |= (pos - Base64);
++			}
++			tarindex++;
++			state = 0;
++			break;
++		default:
++			abort();
++		}
++	}
++
++	/*
++	 * We are done decoding Base-64 chars.  Let's see if we ended
++	 * on a byte boundary, and/or with erroneous trailing characters.
++	 */
++
++	if (ch == Pad64) {		/* We got a pad char. */
++		ch = *src++;		/* Skip it, get next. */
++		switch (state) {
++		case 0:		/* Invalid = in first position */
++		case 1:		/* Invalid = in second position */
++			return (-1);
++
++		case 2:		/* Valid, means one byte of info */
++			/* Skip any number of spaces. */
++			for ((void)NULL; ch != '\0'; ch = *src++)
++				if (!isspace(ch))
++					break;
++			/* Make sure there is another trailing = sign. */
++			if (ch != Pad64)
++				return (-1);
++			ch = *src++;		/* Skip the = */
++			/* Fall through to "single trailing =" case. */
++			/* FALLTHROUGH */
++
++		case 3:		/* Valid, means two bytes of info */
++			/*
++			 * We know this char is an =.  Is there anything but
++			 * whitespace after it?
++			 */
++			for ((void)NULL; ch != '\0'; ch = *src++)
++				if (!isspace(ch))
++					return (-1);
++
++			/*
++			 * Now make sure for cases 2 and 3 that the "extra"
++			 * bits that slopped past the last full byte were
++			 * zeros.  If we don't check them, they become a
++			 * subliminal channel.
++			 */
++			if (target && target[tarindex] != 0)
++				return (-1);
++		}
++	} else {
++		/*
++		 * We ended by seeing the end of the string.  Make sure we
++		 * have no partial bytes lying around.
++		 */
++		if (state != 0)
++			return (-1);
++	}
++
++	return (tarindex);
++}
++
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0006-adb-Musl-fixes.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0006-adb-Musl-fixes.patch
new file mode 100644
index 0000000..b5d383f
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0006-adb-Musl-fixes.patch
@@ -0,0 +1,131 @@
+From 62d957a1271c88ec08d67984fbe31601f0bd41a9 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 15 Sep 2017 15:50:57 -0700
+Subject: [PATCH] adb: Musl fixes
+
+__nonnull is gcc specific
+include sys/types.h for size_t
+Do not redefine close() and lseek()
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ adb/adb.h                    |  2 ++
+ adb/disable_verity_service.c | 13 ++++++++-----
+ adb/framebuffer_service.c    |  7 ++++---
+ adb/sysdeps.h                | 12 ++++++------
+ 4 files changed, 20 insertions(+), 14 deletions(-)
+
+diff --git a/adb/adb.h b/adb/adb.h
+index 44e5981bdc..bcdc49f63c 100644
+--- a/adb/adb.h
++++ b/adb/adb.h
+@@ -18,7 +18,9 @@
+ #define __ADB_H
+ 
+ #include <limits.h>
++#include <sys/types.h>
+ 
++#include "fdevent.h"
+ #include "adb_trace.h"
+ #include "transport.h"  /* readx(), writex() */
+ 
+diff --git a/adb/disable_verity_service.c b/adb/disable_verity_service.c
+index ed3da52108..29fa3d65a9 100644
+--- a/adb/disable_verity_service.c
++++ b/adb/disable_verity_service.c
+@@ -14,25 +14,28 @@
+  * limitations under the License.
+  */
+ 
+-#include "sysdeps.h"
+ 
+ #define  TRACE_TAG  TRACE_ADB
+ #include "adb.h"
++#include "sysdeps.h"
++#include "cutils/properties.h"
++#include "ext4_sb.h"
++#include <fs_mgr.h>
+ 
+ #include <stdio.h>
+ #include <stdarg.h>
+ #include <sys/stat.h>
+ #include <fcntl.h>
+ #include <inttypes.h>
++#include <unistd.h>
++#include <errno.h>
++#include <stdbool.h>
+ 
+-#include "cutils/properties.h"
+-#include "ext4_sb.h"
+-#include <fs_mgr.h>
+ 
+ #define FSTAB_PREFIX "/fstab."
+ struct fstab *fstab;
+ 
+-__attribute__((__format__(printf, 2, 3))) __nonnull((2))
++__attribute__((__format__(printf, 2, 3))) __attribute__((nonnull((2))))
+ static void write_console(int fd, const char* format, ...)
+ {
+     char buffer[256];
+diff --git a/adb/framebuffer_service.c b/adb/framebuffer_service.c
+index 8cbe8403cc..8f0ccfb7aa 100644
+--- a/adb/framebuffer_service.c
++++ b/adb/framebuffer_service.c
+@@ -14,6 +14,10 @@
+  * limitations under the License.
+  */
+ 
++#include "fdevent.h"
++#include "adb.h"
++#include "sysdeps.h"
++
+ #include <stdlib.h>
+ #include <stdio.h>
+ #include <unistd.h>
+@@ -23,9 +27,6 @@
+ #include <sys/types.h>
+ #include <sys/wait.h>
+ 
+-#include "fdevent.h"
+-#include "adb.h"
+-
+ #include <linux/fb.h>
+ #include <sys/ioctl.h>
+ #include <sys/mman.h>
+diff --git a/adb/sysdeps.h b/adb/sysdeps.h
+index cc1f839e9f..ea39ac39cc 100644
+--- a/adb/sysdeps.h
++++ b/adb/sysdeps.h
+@@ -123,8 +123,8 @@ static __inline__ int  unix_close(int fd)
+ {
+     return close(fd);
+ }
+-#undef   close
+-#define  close   ____xxx_close
++//#undef   close
++//#define  close   ____xxx_close
+ 
+ static __inline__  int  unix_read(int  fd, void*  buf, size_t  len)
+ {
+@@ -369,8 +369,8 @@ static __inline__ int  adb_close(int fd)
+ {
+     return close(fd);
+ }
+-#undef   close
+-#define  close   ____xxx_close
++//#undef   close
++//#define  close   ____xxx_close
+ 
+ 
+ static __inline__  int  adb_read(int  fd, void*  buf, size_t  len)
+@@ -392,8 +392,8 @@ static __inline__ int   adb_lseek(int  fd, int  pos, int  where)
+ {
+     return lseek(fd, pos, where);
+ }
+-#undef   lseek
+-#define  lseek   ___xxx_lseek
++//#undef   lseek
++//#define  lseek   ___xxx_lseek
+ 
+ static __inline__  int    adb_unlink(const char*  path)
+ {
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0007-adb-usb_linux.c-fix-build-with-glibc-2.28.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0007-adb-usb_linux.c-fix-build-with-glibc-2.28.patch
new file mode 100644
index 0000000..e02a956
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0007-adb-usb_linux.c-fix-build-with-glibc-2.28.patch
@@ -0,0 +1,24 @@
+From de393bba41c8feff932c77d6c30233945f380d42 Mon Sep 17 00:00:00 2001
+From: Martin Jansa <Martin.Jansa@gmail.com>
+Date: Sat, 11 Aug 2018 13:23:37 +0000
+Subject: [PATCH] adb: usb_linux.c: fix build with glibc-2.28
+
+* include sysmacros for major, minor
+
+Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
+---
+ adb/usb_linux.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/adb/usb_linux.c b/adb/usb_linux.c
+index f16bdd0361..c8a7732441 100644
+--- a/adb/usb_linux.c
++++ b/adb/usb_linux.c
+@@ -22,6 +22,7 @@
+ #include <sys/ioctl.h>
+ #include <sys/types.h>
+ #include <sys/time.h>
++#include <sys/sysmacros.h>
+ #include <dirent.h>
+ #include <fcntl.h>
+ #include <errno.h>
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0008-adb-Allow-adbd-to-be-ran-as-root.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0008-adb-Allow-adbd-to-be-ran-as-root.patch
new file mode 100644
index 0000000..7d223e0
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0008-adb-Allow-adbd-to-be-ran-as-root.patch
@@ -0,0 +1,21 @@
+From 3a788e9168c9b9eac66c4fa479413f4a95c61be4 Mon Sep 17 00:00:00 2001
+From: Florent Revest <revestflo@gmail.com>
+Date: Mon, 30 Oct 2017 21:05:46 +0100
+Subject: [PATCH] adb: Allow adbd to be ran as root
+
+---
+ adb/adb.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/adb/adb.c b/adb/adb.c
+index 027edd9359..e0f7ecde45 100644
+--- a/adb/adb.c
++++ b/adb/adb.c
+@@ -1271,6 +1271,7 @@ static int should_drop_privileges() {
+     int secure = 0;
+     char value[PROPERTY_VALUE_MAX];
+ 
++    return 0;
+    /* run adbd in secure mode if ro.secure is set and
+     ** we are not in the emulator
+     */
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0009-mkbootimg-Add-dt-parameter-to-specify-DT-image.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0009-mkbootimg-Add-dt-parameter-to-specify-DT-image.patch
new file mode 100644
index 0000000..a4dc6e1
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0009-mkbootimg-Add-dt-parameter-to-specify-DT-image.patch
@@ -0,0 +1,110 @@
+From dd195778a9930b7967b21a3b8eb390b70253dbad Mon Sep 17 00:00:00 2001
+From: David Ng <dave@codeaurora.org>
+Date: Fri, 27 Jul 2012 17:15:03 -0700
+Subject: [PATCH] mkbootimg: Add --dt parameter to specify DT image
+
+New optional --dt parameter to specify a kernel device
+tree image.
+
+Upstream-Status: Inappropriate
+---
+ mkbootimg/bootimg.h   |  7 +++++--
+ mkbootimg/mkbootimg.c | 21 +++++++++++++++++++++
+ 2 files changed, 26 insertions(+), 2 deletions(-)
+
+diff --git a/mkbootimg/bootimg.h b/mkbootimg/bootimg.h
+index 9171d85a7b..308c537d6b 100644
+--- a/mkbootimg/bootimg.h
++++ b/mkbootimg/bootimg.h
+@@ -41,8 +41,8 @@ struct boot_img_hdr
+ 
+     unsigned tags_addr;    /* physical addr for kernel tags */
+     unsigned page_size;    /* flash page size we assume */
+-    unsigned unused[2];    /* future expansion: should be 0 */
+-
++    unsigned dt_size;      /* device tree in bytes */
++    unsigned unused;       /* future expansion: should be 0 */
+     unsigned char name[BOOT_NAME_SIZE]; /* asciiz product name */
+ 
+     unsigned char cmdline[BOOT_ARGS_SIZE];
+@@ -64,10 +64,13 @@ struct boot_img_hdr
+ ** +-----------------+
+ ** | second stage    | o pages
+ ** +-----------------+
++** | device tree     | p pages
++** +-----------------+
+ **
+ ** n = (kernel_size + page_size - 1) / page_size
+ ** m = (ramdisk_size + page_size - 1) / page_size
+ ** o = (second_size + page_size - 1) / page_size
++** p = (dt_size + page_size - 1) / page_size
+ **
+ ** 0. all entities are page_size aligned in flash
+ ** 1. kernel and ramdisk are required (size != 0)
+diff --git a/mkbootimg/mkbootimg.c b/mkbootimg/mkbootimg.c
+index fc92b4dc30..658052cdf2 100644
+--- a/mkbootimg/mkbootimg.c
++++ b/mkbootimg/mkbootimg.c
+@@ -65,6 +65,7 @@ int usage(void)
+             "       [ --board <boardname> ]\n"
+             "       [ --base <address> ]\n"
+             "       [ --pagesize <pagesize> ]\n"
++            "       [ --dt <filename> ]\n"
+             "       -o|--output <filename>\n"
+             );
+     return 1;
+@@ -105,6 +106,8 @@ int main(int argc, char **argv)
+     char *cmdline = "";
+     char *bootimg = 0;
+     char *board = "";
++    char *dt_fn = 0;
++    void *dt_data = 0;
+     unsigned pagesize = 2048;
+     int fd;
+     SHA_CTX ctx;
+@@ -158,6 +161,8 @@ int main(int argc, char **argv)
+                 fprintf(stderr,"error: unsupported page size %d\n", pagesize);
+                 return -1;
+             }
++        } else if(!strcmp(arg, "--dt")) {
++            dt_fn = val;
+         } else {
+             return usage();
+         }
+@@ -232,6 +237,14 @@ int main(int argc, char **argv)
+         }
+     }
+ 
++    if(dt_fn) {
++        dt_data = load_file(dt_fn, &hdr.dt_size);
++        if (dt_data == 0) {
++            fprintf(stderr,"error: could not load device tree image '%s'\n", dt_fn);
++            return 1;
++        }
++    }
++
+     /* put a hash of the contents in the header so boot images can be
+      * differentiated based on their first 2k.
+      */
+@@ -242,6 +255,10 @@ int main(int argc, char **argv)
+     SHA_update(&ctx, &hdr.ramdisk_size, sizeof(hdr.ramdisk_size));
+     SHA_update(&ctx, second_data, hdr.second_size);
+     SHA_update(&ctx, &hdr.second_size, sizeof(hdr.second_size));
++    if(dt_data) {
++        SHA_update(&ctx, dt_data, hdr.dt_size);
++        SHA_update(&ctx, &hdr.dt_size, sizeof(hdr.dt_size));
++    }
+     sha = SHA_final(&ctx);
+     memcpy(hdr.id, sha,
+            SHA_DIGEST_SIZE > sizeof(hdr.id) ? sizeof(hdr.id) : SHA_DIGEST_SIZE);
+@@ -266,6 +283,10 @@ int main(int argc, char **argv)
+         if(write_padding(fd, pagesize, hdr.second_size)) goto fail;
+     }
+ 
++    if(dt_data) {
++        if(write(fd, dt_data, hdr.dt_size) != (ssize_t) hdr.dt_size) goto fail;
++        if(write_padding(fd, pagesize, hdr.dt_size)) goto fail;
++    }
+     return 0;
+ 
+ fail:
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0010-Use-linux-capability.h-on-linux-systems-too.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0010-Use-linux-capability.h-on-linux-systems-too.patch
new file mode 100644
index 0000000..2c607ff
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0010-Use-linux-capability.h-on-linux-systems-too.patch
@@ -0,0 +1,23 @@
+From ef743c9c3c7452ae904a5c343ee2b759ab3a87cb Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Lo=C3=AFc=20Minier?= <loic.minier@ubuntu.com>
+Date: Wed, 7 Sep 2016 12:58:47 +0300
+Subject: [PATCH] Use linux/capability.h on linux systems too
+
+Upstream-Status: Inappropriate
+---
+ include/private/android_filesystem_config.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/include/private/android_filesystem_config.h b/include/private/android_filesystem_config.h
+index 2f528b95c8..3e0b00928e 100644
+--- a/include/private/android_filesystem_config.h
++++ b/include/private/android_filesystem_config.h
+@@ -27,7 +27,7 @@
+ #include <sys/types.h>
+ #include <stdint.h>
+ 
+-#ifdef HAVE_ANDROID_OS
++#if defined(HAVE_ANDROID_OS) || defined(__linux__)
+ #include <linux/capability.h>
+ #else
+ #include "android_filesystem_capability.h"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0011-Remove-bionic-specific-calls.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0011-Remove-bionic-specific-calls.patch
new file mode 100644
index 0000000..5b18f46
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0011-Remove-bionic-specific-calls.patch
@@ -0,0 +1,64 @@
+From 9eff8799831961c0edf6e37e5d4cbf43baa7c748 Mon Sep 17 00:00:00 2001
+From: Fathi Boudra <fabo@debian.org>
+Date: Wed, 7 Sep 2016 12:58:47 +0300
+Subject: [PATCH] Remove bionic specific calls
+
+Upstream-Status: Inappropriate
+---
+ include/cutils/properties.h | 1 -
+ libcutils/properties.c      | 2 +-
+ liblog/logd_write.c         | 5 +++++
+ 3 files changed, 6 insertions(+), 2 deletions(-)
+
+diff --git a/include/cutils/properties.h b/include/cutils/properties.h
+index 798db8b36f..7d01f28d6e 100644
+--- a/include/cutils/properties.h
++++ b/include/cutils/properties.h
+@@ -19,7 +19,6 @@
+ 
+ #include <sys/cdefs.h>
+ #include <stddef.h>
+-#include <sys/system_properties.h>
+ #include <stdint.h>
+ 
+ #ifdef __cplusplus
+diff --git a/libcutils/properties.c b/libcutils/properties.c
+index b283658aa4..4151e7882c 100644
+--- a/libcutils/properties.c
++++ b/libcutils/properties.c
+@@ -104,10 +104,10 @@ int32_t property_get_int32(const char *key, int32_t default_value) {
+     return (int32_t)property_get_imax(key, INT32_MIN, INT32_MAX, default_value);
+ }
+ 
++#undef HAVE_LIBC_SYSTEM_PROPERTIES
+ #ifdef HAVE_LIBC_SYSTEM_PROPERTIES
+ 
+ #define _REALLY_INCLUDE_SYS__SYSTEM_PROPERTIES_H_
+-#include <sys/_system_properties.h>
+ 
+ int property_set(const char *key, const char *value)
+ {
+diff --git a/liblog/logd_write.c b/liblog/logd_write.c
+index b2668cedb7..f5a44fe901 100644
+--- a/liblog/logd_write.c
++++ b/liblog/logd_write.c
+@@ -23,6 +23,7 @@
+ #include <stdlib.h>
+ #include <string.h>
+ #include <sys/stat.h>
++#include <sys/syscall.h>
+ #include <sys/types.h>
+ #if (FAKE_LOG_DEVICE == 0)
+ #include <sys/socket.h>
+@@ -205,7 +206,11 @@ static int __write_to_log_kernel(log_id_t log_id, struct iovec *vec, size_t nr)
+     realtime_ts.tv_nsec = ts.tv_nsec;
+ 
+     log_id_buf = log_id;
++#ifdef __BIONIC__
+     tid = gettid();
++#else
++    tid = (pid_t) syscall(__NR_gettid);
++#endif
+ 
+     newVec[0].iov_base   = (unsigned char *) &log_id_buf;
+     newVec[0].iov_len    = sizeof_log_id_t;
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0012-Fix-implicit-declaration-of-stlcat-strlcopy-function.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0012-Fix-implicit-declaration-of-stlcat-strlcopy-function.patch
new file mode 100644
index 0000000..b0feb65
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/core/0012-Fix-implicit-declaration-of-stlcat-strlcopy-function.patch
@@ -0,0 +1,50 @@
+From cd4525d760c6f88c9bf85f7bf488da79cd0d3264 Mon Sep 17 00:00:00 2001
+From: Fathi Boudra <fabo@debian.org>
+Date: Wed, 7 Sep 2016 12:58:47 +0300
+Subject: [PATCH] Fix implicit declaration of stlcat/strlcopy functions
+
+Upstream-Status: Inappropriate
+---
+ adb/adb.c                | 1 +
+ fs_mgr/fs_mgr_fstab.c    | 2 +-
+ include/cutils/sockets.h | 2 +-
+ 3 files changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/adb/adb.c b/adb/adb.c
+index e0f7ecde45..aaefd9b401 100644
+--- a/adb/adb.c
++++ b/adb/adb.c
+@@ -41,6 +41,7 @@
+ #include <sys/prctl.h>
+ #include <getopt.h>
+ #include <selinux/selinux.h>
++#include <grp.h>
+ #else
+ #include "usb_vendors.h"
+ #endif
+diff --git a/fs_mgr/fs_mgr_fstab.c b/fs_mgr/fs_mgr_fstab.c
+index edd9591164..9ddb4643b5 100644
+--- a/fs_mgr/fs_mgr_fstab.c
++++ b/fs_mgr/fs_mgr_fstab.c
+@@ -17,7 +17,7 @@
+ #include <ctype.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+-#include <string.h>
++#include <bsd/string.h>
+ #include <sys/mount.h>
+ 
+ #include "fs_mgr_priv.h"
+diff --git a/include/cutils/sockets.h b/include/cutils/sockets.h
+index daf43ec944..d3270c69e7 100644
+--- a/include/cutils/sockets.h
++++ b/include/cutils/sockets.h
+@@ -19,7 +19,7 @@
+ 
+ #include <errno.h>
+ #include <stdlib.h>
+-#include <string.h>
++#include <bsd/string.h>
+ #include <stdbool.h>
+ 
+ #ifdef HAVE_WINSOCK
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/define-shell-command.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/define-shell-command.patch
deleted file mode 100644
index 8381967..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/define-shell-command.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-Description: we intend to run on Linux system so the shell is always /bin/sh,
-             for the host or the target.
-Author: Fathi Boudra <fabo@debian.org>
-
-Upstream-Status: Inappropriate
----
- system/core/adb/services.c |    4 ----
- 1 file changed, 4 deletions(-)
-
---- a/system/core/adb/services.c
-+++ b/system/core/adb/services.c
-@@ -299,11 +299,7 @@ static int create_subproc_raw(const char
- }
- #endif  /* !ABD_HOST */
- 
--#if ADB_HOST
- #define SHELL_COMMAND "/bin/sh"
--#else
--#define SHELL_COMMAND "/system/bin/sh"
--#endif
- 
- #if !ADB_HOST
- static void subproc_waiter_service(int fd, void *cookie)
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/extras/0001-ext4_utils-remove-selinux-extensions.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/extras/0001-ext4_utils-remove-selinux-extensions.patch
new file mode 100644
index 0000000..4a19a5d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/extras/0001-ext4_utils-remove-selinux-extensions.patch
@@ -0,0 +1,39 @@
+From 354604da9d152f1931e91991d3f34197fc8fc759 Mon Sep 17 00:00:00 2001
+From: Sergio Schvezov <sergio.schvezov@canonical.com>
+Date: Tue, 2 Oct 2018 16:36:54 +0000
+Subject: [PATCH] ext4_utils: remove selinux extensions
+
+* drop useless includes of Android SELINUX extensions
+* avoids having to clone another module
+* this should be sent upstream
+
+Upstream-Status: Inappropriate
+---
+ ext4_utils/make_ext4fs.c      | 1 -
+ ext4_utils/make_ext4fs_main.c | 1 -
+ 2 files changed, 2 deletions(-)
+
+diff --git a/ext4_utils/make_ext4fs.c b/ext4_utils/make_ext4fs.c
+index 2f89ae8a0..732afbed7 100644
+--- a/ext4_utils/make_ext4fs.c
++++ b/ext4_utils/make_ext4fs.c
+@@ -62,7 +62,6 @@
+ 
+ #include <selinux/selinux.h>
+ #include <selinux/label.h>
+-#include <selinux/android.h>
+ 
+ #define O_BINARY 0
+ 
+diff --git a/ext4_utils/make_ext4fs_main.c b/ext4_utils/make_ext4fs_main.c
+index a6c5f6160..f8e7b9da9 100644
+--- a/ext4_utils/make_ext4fs_main.c
++++ b/ext4_utils/make_ext4fs_main.c
+@@ -32,7 +32,6 @@
+ #ifndef USE_MINGW
+ #include <selinux/selinux.h>
+ #include <selinux/label.h>
+-#include <selinux/android.h>
+ #else
+ struct selabel_handle;
+ #endif
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/extras/0002-ext4_utils-add-o-argument-to-preserve-ownership.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/extras/0002-ext4_utils-add-o-argument-to-preserve-ownership.patch
new file mode 100644
index 0000000..3b50ffb
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/extras/0002-ext4_utils-add-o-argument-to-preserve-ownership.patch
@@ -0,0 +1,78 @@
+From b9254539811ce912bfd16dd1d185eba7a10cceff Mon Sep 17 00:00:00 2001
+From: Markus Mayer <mmayer@mmayer.net>
+Date: Wed, 7 Sep 2016 12:58:47 +0300
+Subject: [PATCH] ext4_utils: add -o argument to preserve ownership
+
+See also https://android-review.googlesource.com/#/c/100312/
+
+Upstream-Status: Inappropriate
+---
+ ext4_utils/make_ext4fs.c      |  6 ++++++
+ ext4_utils/make_ext4fs_main.c | 10 ++++++++--
+ 2 files changed, 14 insertions(+), 2 deletions(-)
+
+diff --git a/ext4_utils/make_ext4fs.c b/ext4_utils/make_ext4fs.c
+index 732afbed7..2cbf04399 100644
+--- a/ext4_utils/make_ext4fs.c
++++ b/ext4_utils/make_ext4fs.c
+@@ -67,6 +67,8 @@
+ 
+ #endif
+ 
++int preserve_owner = 0;
++
+ /* TODO: Not implemented:
+    Allocating blocks in the same block group as the file inode
+    Hash or binary tree directories
+@@ -185,6 +187,10 @@ static u32 build_directory_structure(const char *full_path, const char *dir_path
+ 		} else {
+ 			dentries[i].mtime = fixed_time;
+ 		}
++		if (preserve_owner) {
++			dentries[i].uid = stat.st_uid;
++			dentries[i].gid = stat.st_gid;
++		}
+ 		uint64_t capabilities;
+ 		if (fs_config_func != NULL) {
+ #ifdef ANDROID
+diff --git a/ext4_utils/make_ext4fs_main.c b/ext4_utils/make_ext4fs_main.c
+index f8e7b9da9..e82d43277 100644
+--- a/ext4_utils/make_ext4fs_main.c
++++ b/ext4_utils/make_ext4fs_main.c
+@@ -47,13 +47,15 @@ struct selabel_handle;
+ extern struct fs_info info;
+ 
+ 
++extern int preserve_owner;
++
+ static void usage(char *path)
+ {
+ 	fprintf(stderr, "%s [ -l <len> ] [ -j <journal size> ] [ -b <block_size> ]\n", basename(path));
+ 	fprintf(stderr, "    [ -g <blocks per group> ] [ -i <inodes> ] [ -I <inode size> ]\n");
+ 	fprintf(stderr, "    [ -L <label> ] [ -f ] [ -a <android mountpoint> ]\n");
+ 	fprintf(stderr, "    [ -S file_contexts ] [ -C fs_config ] [ -T timestamp ]\n");
+-	fprintf(stderr, "    [ -z | -s ] [ -w ] [ -c ] [ -J ] [ -v ] [ -B <block_list_file> ]\n");
++	fprintf(stderr, "    [ -z | -s ] [ -w ] [ -c ] [ -J ] [ -o ] [ -v ] [ -B <block_list_file> ]\n");
+ 	fprintf(stderr, "    <filename> [<directory>]\n");
+ }
+ 
+@@ -79,7 +81,7 @@ int main(int argc, char **argv)
+ 	struct selinux_opt seopts[] = { { SELABEL_OPT_PATH, "" } };
+ #endif
+ 
+-	while ((opt = getopt(argc, argv, "l:j:b:g:i:I:L:a:S:T:C:B:fwzJsctv")) != -1) {
++	while ((opt = getopt(argc, argv, "l:j:b:g:i:I:L:a:S:T:C:B:fwzJsctov")) != -1) {
+ 		switch (opt) {
+ 		case 'l':
+ 			info.len = parse_num(optarg);
+@@ -142,6 +144,10 @@ int main(int argc, char **argv)
+ 			}
+ #endif
+ 			break;
++		case 'o':
++			preserve_owner = 1;
++			printf("Warning: Enabling 'preserve ownership', this is an unofficial feature!\n");
++			break;
+ 		case 'v':
+ 			verbose = 1;
+ 			break;
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/fix-big-endian-build.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/fix-big-endian-build.patch
deleted file mode 100644
index 8deaf3a..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/fix-big-endian-build.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-Fix build on big endian systems
-
-The usb_linux_client.c file defines cpu_to_le16/32 by using the C
-library htole16/32 function calls. However, cpu_to_le16/32 are used
-when initializing structures, i.e in a context where a function call
-is not allowed.
-
-It works fine on little endian systems because htole16/32 are defined
-by the C library as no-ops. But on big-endian systems, they are
-actually doing something, which might involve calling a function,
-causing build failures.
-
-To solve this, we simply open-code cpu_to_le16/32 in a way that allows
-them to be used when initializing structures.
-
-Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
-
-Index: b/system/core/adb/usb_linux_client.c
-===================================================================
---- a/system/core/adb/usb_linux_client.c
-+++ b/system/core/adb/usb_linux_client.c
-@@ -34,8 +34,15 @@
- #define MAX_PACKET_SIZE_FS	64
- #define MAX_PACKET_SIZE_HS	512
- 
--#define cpu_to_le16(x)  htole16(x)
--#define cpu_to_le32(x)  htole32(x)
-+#if __BYTE_ORDER == __LITTLE_ENDIAN
-+# define cpu_to_le16(x) (x)
-+# define cpu_to_le32(x) (x)
-+#else
-+# define cpu_to_le16(x) ((((x) >> 8) & 0xffu) | (((x) & 0xffu) << 8))
-+# define cpu_to_le32(x) \
-+	((((x) & 0xff000000u) >> 24) | (((x) & 0x00ff0000u) >>  8) | \
-+	 (((x) & 0x0000ff00u) <<  8) | (((x) & 0x000000ffu) << 24))
-+#endif
- 
- struct usb_handle
- {
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/.gitignore b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/gitignore
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/.gitignore
rename to meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/gitignore
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/implicit-declaration-function-strlcat-strlcopy.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/implicit-declaration-function-strlcat-strlcopy.patch
deleted file mode 100644
index 64db616..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/implicit-declaration-function-strlcat-strlcopy.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-Description: fix implicit declaration of stlcat/strlcopy functions.
-Author: Fathi Boudra <fabo@debian.org>
-
-Upstream-Status: Inappropriate
----
- system/core/adb/adb.c                |    1 +
- system/core/fs_mgr/fs_mgr_fstab.c    |    2 +-
- system/core/include/cutils/sockets.h |    2 +-
- 3 files changed, 3 insertions(+), 2 deletions(-)
-
---- a/system/core/fs_mgr/fs_mgr_fstab.c
-+++ b/system/core/fs_mgr/fs_mgr_fstab.c
-@@ -17,7 +17,7 @@
- #include <ctype.h>
- #include <stdio.h>
- #include <stdlib.h>
--#include <string.h>
-+#include <bsd/string.h>
- #include <sys/mount.h>
- 
- #include "fs_mgr_priv.h"
---- a/system/core/include/cutils/sockets.h
-+++ b/system/core/include/cutils/sockets.h
-@@ -19,7 +19,7 @@
- 
- #include <errno.h>
- #include <stdlib.h>
--#include <string.h>
-+#include <bsd/string.h>
- #include <stdbool.h>
- 
- #ifdef HAVE_WINSOCK
---- a/system/core/adb/adb.c
-+++ b/system/core/adb/adb.c
-@@ -41,6 +41,7 @@
- #include <sys/prctl.h>
- #include <getopt.h>
- #include <selinux/selinux.h>
-+#include <grp.h>
- #else
- #include "usb_vendors.h"
- #endif
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/libselinux/0001-Remove-bionic-specific-calls.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/libselinux/0001-Remove-bionic-specific-calls.patch
new file mode 100644
index 0000000..9de2593
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/libselinux/0001-Remove-bionic-specific-calls.patch
@@ -0,0 +1,25 @@
+From 36654a4484117e5f4d63a810c0d94bc9c7ee3a83 Mon Sep 17 00:00:00 2001
+From: Fathi Boudra <fabo@debian.org>
+Date: Tue, 2 Oct 2018 16:36:54 +0000
+Subject: [PATCH] Remove bionic specific calls
+
+Upstream-Status: Inappropriate
+
+Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
+---
+ src/procattr.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/procattr.c b/src/procattr.c
+index f350808..761cf8e 100644
+--- a/src/procattr.c
++++ b/src/procattr.c
+@@ -8,7 +8,7 @@
+ #include "selinux_internal.h"
+ #include "policy.h"
+ 
+-#ifdef HOST
++#ifndef __BIONIC__
+ static pid_t gettid(void)
+ {
+ 	return syscall(__NR_gettid);
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/mkbootimg-Add-dt-parameter-to-specify-DT-image.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/mkbootimg-Add-dt-parameter-to-specify-DT-image.patch
deleted file mode 100644
index 35bb766..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/mkbootimg-Add-dt-parameter-to-specify-DT-image.patch
+++ /dev/null
@@ -1,108 +0,0 @@
-From cc5e7b02a3be57709a1aed6e34be100b82a71620 Mon Sep 17 00:00:00 2001
-From: David Ng <dave@codeaurora.org>
-Date: Fri, 27 Jul 2012 17:15:03 -0700
-Subject: [PATCH 1/2] mkbootimg: Add --dt parameter to specify DT image
-
-New optional --dt parameter to specify a kernel device
-tree image.
-
-Change-Id: Ie29a11cbf4138426bfd19ae486d69a5fcbd8f442
-
-Upstream-Status: Inappropriate
----
- system/core/mkbootimg/bootimg.h   |    7 +++++--
- system/core/mkbootimg/mkbootimg.c |   21 +++++++++++++++++++++
- 2 files changed, 26 insertions(+), 2 deletions(-)
-
---- a/system/core/mkbootimg/bootimg.h
-+++ b/system/core/mkbootimg/bootimg.h
-@@ -41,8 +41,8 @@ struct boot_img_hdr
- 
-     unsigned tags_addr;    /* physical addr for kernel tags */
-     unsigned page_size;    /* flash page size we assume */
--    unsigned unused[2];    /* future expansion: should be 0 */
--
-+    unsigned dt_size;      /* device tree in bytes */
-+    unsigned unused;       /* future expansion: should be 0 */
-     unsigned char name[BOOT_NAME_SIZE]; /* asciiz product name */
- 
-     unsigned char cmdline[BOOT_ARGS_SIZE];
-@@ -64,10 +64,13 @@ struct boot_img_hdr
- ** +-----------------+
- ** | second stage    | o pages
- ** +-----------------+
-+** | device tree     | p pages
-+** +-----------------+
- **
- ** n = (kernel_size + page_size - 1) / page_size
- ** m = (ramdisk_size + page_size - 1) / page_size
- ** o = (second_size + page_size - 1) / page_size
-+** p = (dt_size + page_size - 1) / page_size
- **
- ** 0. all entities are page_size aligned in flash
- ** 1. kernel and ramdisk are required (size != 0)
---- a/system/core/mkbootimg/mkbootimg.c
-+++ b/system/core/mkbootimg/mkbootimg.c
-@@ -65,6 +65,7 @@ int usage(void)
-             "       [ --board <boardname> ]\n"
-             "       [ --base <address> ]\n"
-             "       [ --pagesize <pagesize> ]\n"
-+            "       [ --dt <filename> ]\n"
-             "       -o|--output <filename>\n"
-             );
-     return 1;
-@@ -105,6 +106,8 @@ int main(int argc, char **argv)
-     char *cmdline = "";
-     char *bootimg = 0;
-     char *board = "";
-+    char *dt_fn = 0;
-+    void *dt_data = 0;
-     unsigned pagesize = 2048;
-     int fd;
-     SHA_CTX ctx;
-@@ -158,6 +161,8 @@ int main(int argc, char **argv)
-                 fprintf(stderr,"error: unsupported page size %d\n", pagesize);
-                 return -1;
-             }
-+        } else if(!strcmp(arg, "--dt")) {
-+            dt_fn = val;
-         } else {
-             return usage();
-         }
-@@ -232,6 +237,14 @@ int main(int argc, char **argv)
-         }
-     }
- 
-+    if(dt_fn) {
-+        dt_data = load_file(dt_fn, &hdr.dt_size);
-+        if (dt_data == 0) {
-+            fprintf(stderr,"error: could not load device tree image '%s'\n", dt_fn);
-+            return 1;
-+        }
-+    }
-+
-     /* put a hash of the contents in the header so boot images can be
-      * differentiated based on their first 2k.
-      */
-@@ -242,6 +255,10 @@ int main(int argc, char **argv)
-     SHA_update(&ctx, &hdr.ramdisk_size, sizeof(hdr.ramdisk_size));
-     SHA_update(&ctx, second_data, hdr.second_size);
-     SHA_update(&ctx, &hdr.second_size, sizeof(hdr.second_size));
-+    if(dt_data) {
-+        SHA_update(&ctx, dt_data, hdr.dt_size);
-+        SHA_update(&ctx, &hdr.dt_size, sizeof(hdr.dt_size));
-+    }
-     sha = SHA_final(&ctx);
-     memcpy(hdr.id, sha,
-            SHA_DIGEST_SIZE > sizeof(hdr.id) ? sizeof(hdr.id) : SHA_DIGEST_SIZE);
-@@ -266,6 +283,10 @@ int main(int argc, char **argv)
-         if(write_padding(fd, pagesize, hdr.second_size)) goto fail;
-     }
- 
-+    if(dt_data) {
-+        if(write(fd, dt_data, hdr.dt_size) != (ssize_t) hdr.dt_size) goto fail;
-+        if(write_padding(fd, pagesize, hdr.dt_size)) goto fail;
-+    }
-     return 0;
- 
- fail:
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/preserve-ownership.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/preserve-ownership.patch
deleted file mode 100644
index 5c90397..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/preserve-ownership.patch
+++ /dev/null
@@ -1,81 +0,0 @@
-From aa669312a380611d280d126cb509fa282080707e Mon Sep 17 00:00:00 2001
-From: Markus Mayer <mmayer@mmayer.net>
-Date: Wed, 7 Sep 2016 12:58:47 +0300
-Subject: [PATCH] android-tools: add recipe from AOSP tag android-5.1.1_r37
-
-Description: add -o argument to preserve ownership
-
-See also https://android-review.googlesource.com/#/c/100312/
-
-Upstream-Status: Inappropriate
-
----
- ext4_utils/make_ext4fs.c      |  6 ++++++
- ext4_utils/make_ext4fs_main.c | 10 ++++++++--
- 2 files changed, 14 insertions(+), 2 deletions(-)
-
-diff --git a/ext4_utils/make_ext4fs.c b/ext4_utils/make_ext4fs.c
-index 2f89ae8a..cc41d623 100644
---- a/ext4_utils/make_ext4fs.c
-+++ b/ext4_utils/make_ext4fs.c
-@@ -68,6 +68,8 @@
- 
- #endif
- 
-+int preserve_owner = 0;
-+
- /* TODO: Not implemented:
-    Allocating blocks in the same block group as the file inode
-    Hash or binary tree directories
-@@ -186,6 +188,10 @@ static u32 build_directory_structure(const char *full_path, const char *dir_path
- 		} else {
- 			dentries[i].mtime = fixed_time;
- 		}
-+		if (preserve_owner) {
-+			dentries[i].uid = stat.st_uid;
-+			dentries[i].gid = stat.st_gid;
-+		}
- 		uint64_t capabilities;
- 		if (fs_config_func != NULL) {
- #ifdef ANDROID
-diff --git a/ext4_utils/make_ext4fs_main.c b/ext4_utils/make_ext4fs_main.c
-index a6c5f616..7af0dddf 100644
---- a/ext4_utils/make_ext4fs_main.c
-+++ b/ext4_utils/make_ext4fs_main.c
-@@ -48,13 +48,15 @@ struct selabel_handle;
- extern struct fs_info info;
- 
- 
-+extern int preserve_owner;
-+
- static void usage(char *path)
- {
- 	fprintf(stderr, "%s [ -l <len> ] [ -j <journal size> ] [ -b <block_size> ]\n", basename(path));
- 	fprintf(stderr, "    [ -g <blocks per group> ] [ -i <inodes> ] [ -I <inode size> ]\n");
- 	fprintf(stderr, "    [ -L <label> ] [ -f ] [ -a <android mountpoint> ]\n");
- 	fprintf(stderr, "    [ -S file_contexts ] [ -C fs_config ] [ -T timestamp ]\n");
--	fprintf(stderr, "    [ -z | -s ] [ -w ] [ -c ] [ -J ] [ -v ] [ -B <block_list_file> ]\n");
-+	fprintf(stderr, "    [ -z | -s ] [ -w ] [ -c ] [ -J ] [ -o ] [ -v ] [ -B <block_list_file> ]\n");
- 	fprintf(stderr, "    <filename> [<directory>]\n");
- }
- 
-@@ -80,7 +82,7 @@ int main(int argc, char **argv)
- 	struct selinux_opt seopts[] = { { SELABEL_OPT_PATH, "" } };
- #endif
- 
--	while ((opt = getopt(argc, argv, "l:j:b:g:i:I:L:a:S:T:C:B:fwzJsctv")) != -1) {
-+	while ((opt = getopt(argc, argv, "l:j:b:g:i:I:L:a:S:T:C:B:fwzJsctov")) != -1) {
- 		switch (opt) {
- 		case 'l':
- 			info.len = parse_num(optarg);
-@@ -143,6 +145,10 @@ int main(int argc, char **argv)
- 			}
- #endif
- 			break;
-+		case 'o':
-+			preserve_owner = 1;
-+			printf("Warning: Enabling 'preserve ownership', this is an unofficial feature!\n");
-+			break;
- 		case 'v':
- 			verbose = 1;
- 			break;
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/remove-bionic-android.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/remove-bionic-android.patch
deleted file mode 100644
index e933724..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/remove-bionic-android.patch
+++ /dev/null
@@ -1,67 +0,0 @@
-Description: remove bionic specific calls
-Author: Fathi Boudra <fabo@debian.org>
-
-Upstream-Status: Inappropriate
----
- system/core/include/cutils/properties.h |    1 -
- system/core/libcutils/properties.c      |    2 +-
- system/core/liblog/logd_write.c         |    5 +++++
- 3 files changed, 6 insertions(+), 2 deletions(-)
-
---- a/system/core/include/cutils/properties.h
-+++ b/system/core/include/cutils/properties.h
-@@ -19,7 +19,6 @@
- 
- #include <sys/cdefs.h>
- #include <stddef.h>
--#include <sys/system_properties.h>
- #include <stdint.h>
- 
- #ifdef __cplusplus
---- a/system/core/liblog/logd_write.c
-+++ b/system/core/liblog/logd_write.c
-@@ -23,6 +23,7 @@
- #include <stdlib.h>
- #include <string.h>
- #include <sys/stat.h>
-+#include <sys/syscall.h>
- #include <sys/types.h>
- #if (FAKE_LOG_DEVICE == 0)
- #include <sys/socket.h>
-@@ -205,7 +206,11 @@ static int __write_to_log_kernel(log_id_
-     realtime_ts.tv_nsec = ts.tv_nsec;
- 
-     log_id_buf = log_id;
-+#ifdef __BIONIC__
-     tid = gettid();
-+#else
-+    tid = (pid_t) syscall(__NR_gettid);
-+#endif
- 
-     newVec[0].iov_base   = (unsigned char *) &log_id_buf;
-     newVec[0].iov_len    = sizeof_log_id_t;
---- a/system/core/libcutils/properties.c
-+++ b/system/core/libcutils/properties.c
-@@ -104,10 +104,10 @@ int32_t property_get_int32(const char *k
-     return (int32_t)property_get_imax(key, INT32_MIN, INT32_MAX, default_value);
- }
- 
-+#undef HAVE_LIBC_SYSTEM_PROPERTIES
- #ifdef HAVE_LIBC_SYSTEM_PROPERTIES
- 
- #define _REALLY_INCLUDE_SYS__SYSTEM_PROPERTIES_H_
--#include <sys/_system_properties.h>
- 
- int property_set(const char *key, const char *value)
- {
---- a/external/libselinux/src/procattr.c
-+++ b/external/libselinux/src/procattr.c
-@@ -8,7 +8,7 @@
- #include "selinux_internal.h"
- #include "policy.h"
- 
--#ifdef HOST
-+#ifndef __BIONIC__
- static pid_t gettid(void)
- {
- 	return syscall(__NR_gettid);
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/remove-selinux-android.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/remove-selinux-android.patch
deleted file mode 100644
index d4a37f8..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/remove-selinux-android.patch
+++ /dev/null
@@ -1,56 +0,0 @@
-Subject: drop useless includes of Android SELINUX extensions; avoids having to clone another module; this should be sent upstream
-Author: Sergio Schvezov <sergio.schvezov@canonical.com>
-
-Upstream-Status: Inappropriate
----
- system/core/adb/file_sync_service.c         |    3 ---
- system/extras/ext4_utils/make_ext4fs.c      |    1 -
- system/extras/ext4_utils/make_ext4fs_main.c |    1 -
- 3 files changed, 5 deletions(-)
-
---- a/system/extras/ext4_utils/make_ext4fs.c
-+++ b/system/extras/ext4_utils/make_ext4fs.c
-@@ -62,7 +62,6 @@
- 
- #include <selinux/selinux.h>
- #include <selinux/label.h>
--#include <selinux/android.h>
- 
- #define O_BINARY 0
- 
---- a/system/extras/ext4_utils/make_ext4fs_main.c
-+++ b/system/extras/ext4_utils/make_ext4fs_main.c
-@@ -32,7 +32,6 @@
- #ifndef USE_MINGW
- #include <selinux/selinux.h>
- #include <selinux/label.h>
--#include <selinux/android.h>
- #else
- struct selabel_handle;
- #endif
---- a/system/core/adb/file_sync_service.c
-+++ b/system/core/adb/file_sync_service.c
-@@ -26,7 +26,6 @@
- 
- #include <errno.h>
- #include <private/android_filesystem_config.h>
--#include <selinux/android.h>
- #include "sysdeps.h"
- 
- #define TRACE_TAG  TRACE_SYNC
-@@ -73,7 +72,6 @@ static int mkdirs(char *name)
-                 *x = '/';
-                 return ret;
-             }
--            selinux_android_restorecon(name, 0);
-         }
-         *x++ = '/';
-     }
-@@ -251,7 +249,6 @@ static int handle_send_file(int s, char
-     if(fd >= 0) {
-         struct utimbuf u;
-         adb_close(fd);
--        selinux_android_restorecon(path, 0);
-         u.actime = timestamp;
-         u.modtime = timestamp;
-         utime(path, &u);
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/use-capability.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/use-capability.patch
deleted file mode 100644
index b8ebe09..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/use-capability.patch
+++ /dev/null
@@ -1,19 +0,0 @@
-Subject: use linux/capability.h on linux systems too
-Author: Loïc Minier <loic.minier@ubuntu.com>
-
-Upstream-Status: Inappropriate
----
- system/core/include/private/android_filesystem_config.h |    2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
---- a/system/core/include/private/android_filesystem_config.h
-+++ b/system/core/include/private/android_filesystem_config.h
-@@ -27,7 +27,7 @@
- #include <sys/types.h>
- #include <stdint.h>
- 
--#ifdef HAVE_ANDROID_OS
-+#if defined(HAVE_ANDROID_OS) || defined(__linux__)
- #include <linux/capability.h>
- #else
- #include "android_filesystem_capability.h"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/use-local-socket.patch b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/use-local-socket.patch
deleted file mode 100644
index 7facd61..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools/use-local-socket.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-Subject: adb: Use local sockets where appropriate
-Author: Hilko Bengen <bengen@debian.org>
-
-Upstream-Status: Inappropriate
----
- system/core/adb/adb.c             |    6 +++++-
- system/core/adb/adb_client.c      |    5 +++--
- system/core/adb/transport_local.c |    3 ++-
- 3 files changed, 10 insertions(+), 4 deletions(-)
-
---- a/system/core/adb/adb.c
-+++ b/system/core/adb/adb.c
-@@ -1230,7 +1230,11 @@ int launch_server(int server_port)
-  */
- void build_local_name(char* target_str, size_t target_size, int server_port)
- {
--  snprintf(target_str, target_size, "tcp:%d", server_port);
-+  if (gListenAll > 0) {
-+    snprintf(target_str, target_size, "tcp:%d", server_port);
-+  } else {
-+    snprintf(target_str, target_size, "local:%d", server_port);
-+  }
- }
- 
- #if !ADB_HOST
---- a/system/core/adb/adb_client.c
-+++ b/system/core/adb/adb_client.c
-@@ -185,12 +185,12 @@ int _adb_connect(const char *service)
-         strcpy(__adb_error, "service name too long");
-         return -1;
-     }
--    snprintf(tmp, sizeof tmp, "%04x", len);
-+    snprintf(tmp, sizeof tmp, "%d", __adb_server_port);
- 
-     if (__adb_server_name)
-         fd = socket_network_client(__adb_server_name, __adb_server_port, SOCK_STREAM);
-     else
--        fd = socket_loopback_client(__adb_server_port, SOCK_STREAM);
-+        fd = socket_local_client(tmp, ANDROID_SOCKET_NAMESPACE_ABSTRACT, SOCK_STREAM);
- 
-     if(fd < 0) {
-         strcpy(__adb_error, "cannot connect to daemon");
-@@ -201,6 +201,7 @@ int _adb_connect(const char *service)
-         return -1;
-     }
- 
-+    snprintf(tmp, sizeof tmp, "%04x", len);
-     if(writex(fd, tmp, 4) || writex(fd, service, len)) {
-         strcpy(__adb_error, "write failure during connection");
-         adb_close(fd);
---- a/system/core/adb/transport_local.c
-+++ b/system/core/adb/transport_local.c
-@@ -121,7 +121,8 @@ int local_connect_arbitrary_ports(int co
-     }
- #endif
-     if (fd < 0) {
--        fd = socket_loopback_client(adb_port, SOCK_STREAM);
-+        snprintf(buf, sizeof buf, "%d", adb_port);
-+        fd = socket_local_client(buf, ANDROID_SOCKET_NAMESPACE_ABSTRACT, SOCK_STREAM);
-     }
- 
-     if (fd >= 0) {
diff --git a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools_5.1.1.r37.bb b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools_5.1.1.r37.bb
index 780ecaa..2604f65 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools_5.1.1.r37.bb
+++ b/meta-openembedded/meta-oe/recipes-devtools/android-tools/android-tools_5.1.1.r37.bb
@@ -7,14 +7,10 @@
     file://${COMMON_LICENSE_DIR}/BSD-2-Clause;md5=8bef8e6712b1be5aa76af1ebde9d6378 \
     file://${COMMON_LICENSE_DIR}/BSD-3-Clause;md5=550794465ba0ec5312d6919e203a55f9 \
 "
-DEPENDS = "libbsd libpcre openssl zlib libcap"
+DEPENDS = "libbsd libpcre zlib libcap"
+DEPENDS_append_class-target = " openssl10"
 
 ANDROID_MIRROR = "android.googlesource.com"
-CORE_REPO = "${ANDROID_MIRROR}/platform/system/core"
-EXTRAS_REPO = "${ANDROID_MIRROR}/platform/system/extras"
-LIBHARDWARE_REPO = "${ANDROID_MIRROR}/platform/hardware/libhardware"
-LIBSELINUX_REPO = "${ANDROID_MIRROR}/platform/external/libselinux"
-BUILD_REPO = "${ANDROID_MIRROR}/platform/build"
 
 # matches with android-5.1.1_r37
 SRCREV_core = "2314b110bdebdbfd2d94c502282f9e57c849897e"
@@ -24,24 +20,28 @@
 SRCREV_build = "16e987def3d7d8f7d30805eb95cef69e52a87dbc"
 
 SRC_URI = " \
-    git://${CORE_REPO};name=core;protocol=https;nobranch=1;destsuffix=git/system/core \
-    git://${EXTRAS_REPO};name=extras;protocol=https;nobranch=1;destsuffix=git/system/extras \
-    git://${LIBHARDWARE_REPO};name=libhardware;protocol=https;nobranch=1;destsuffix=git/hardware/libhardware \
-    git://${LIBSELINUX_REPO};name=libselinux;protocol=https;nobranch=1;destsuffix=git/external/libselinux \
-    git://${BUILD_REPO};name=build;protocol=https;nobranch=1;destsuffix=git/build \
-    file://remove-selinux-android.patch \
-    file://use-capability.patch \
-    file://use-local-socket.patch \
-    file://preserve-ownership.patch;patchdir=system/extras \
-    file://mkbootimg-Add-dt-parameter-to-specify-DT-image.patch \
-    file://remove-bionic-android.patch \
-    file://define-shell-command.patch \
-    file://implicit-declaration-function-strlcat-strlcopy.patch \
-    file://fix-big-endian-build.patch \
-    file://0001-add-base64-implementation.patch \
-    file://0002-adb-Musl-fixes.patch \
+    git://${ANDROID_MIRROR}/platform/system/core;name=core;protocol=https;nobranch=1;destsuffix=git/system/core \
+    git://${ANDROID_MIRROR}/platform/system/extras;name=extras;protocol=https;nobranch=1;destsuffix=git/system/extras \
+    git://${ANDROID_MIRROR}/platform/hardware/libhardware;name=libhardware;protocol=https;nobranch=1;destsuffix=git/hardware/libhardware \
+    git://${ANDROID_MIRROR}/platform/external/libselinux;name=libselinux;protocol=https;nobranch=1;destsuffix=git/external/libselinux \
+    git://${ANDROID_MIRROR}/platform/build;name=build;protocol=https;nobranch=1;destsuffix=git/build \
+    file://core/0001-adb-remove-selinux-extensions.patch;patchdir=system/core \
+    file://core/0002-adb-Use-local-sockets-where-appropriate.patch;patchdir=system/core \
+    file://core/0003-adb-define-shell-command.patch;patchdir=system/core \
+    file://core/0004-adb-Fix-build-on-big-endian-systems.patch;patchdir=system/core \
+    file://core/0005-adb-add-base64-implementation.patch;patchdir=system/core \
+    file://core/0006-adb-Musl-fixes.patch;patchdir=system/core \
+    file://core/0007-adb-usb_linux.c-fix-build-with-glibc-2.28.patch;patchdir=system/core \
+    file://core/0008-adb-Allow-adbd-to-be-ran-as-root.patch;patchdir=system/core \
+    file://core/0009-mkbootimg-Add-dt-parameter-to-specify-DT-image.patch;patchdir=system/core \
+    file://core/0010-Use-linux-capability.h-on-linux-systems-too.patch;patchdir=system/core \
+    file://core/0011-Remove-bionic-specific-calls.patch;patchdir=system/core \
+    file://core/0012-Fix-implicit-declaration-of-stlcat-strlcopy-function.patch;patchdir=system/core \
+    file://extras/0001-ext4_utils-remove-selinux-extensions.patch;patchdir=system/extras \
+    file://extras/0002-ext4_utils-add-o-argument-to-preserve-ownership.patch;patchdir=system/extras \
+    file://libselinux/0001-Remove-bionic-specific-calls.patch;patchdir=external/libselinux \
     file://android-tools-adbd.service \
-    file://.gitignore;subdir=git \
+    file://gitignore \
     file://adb.mk;subdir=${BPN} \
     file://adbd.mk;subdir=${BPN} \
     file://ext4_utils.mk;subdir=${BPN} \
@@ -49,6 +49,7 @@
     file://mkbootimg.mk;subdir=${BPN} \
 "
 
+
 S = "${WORKDIR}/git"
 B = "${WORKDIR}/${BPN}"
 
@@ -71,6 +72,8 @@
 TOOLS_class-nativesdk = "fastboot ext4_utils mkbootimg"
 
 do_compile() {
+    cp ${WORKDIR}/gitignore ${S}/.gitignore
+
     # Setting both variables below causing our makefiles to not work with
     # implicit make rules
     unset CFLAGS
diff --git a/meta-openembedded/meta-oe/recipes-devtools/breakpad/breakpad/0001-disable-calls-to-getcontext-with-musl.patch b/meta-openembedded/meta-oe/recipes-devtools/breakpad/breakpad/0001-disable-calls-to-getcontext-with-musl.patch
index c762754..bc79727 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/breakpad/breakpad/0001-disable-calls-to-getcontext-with-musl.patch
+++ b/meta-openembedded/meta-oe/recipes-devtools/breakpad/breakpad/0001-disable-calls-to-getcontext-with-musl.patch
@@ -8,11 +8,11 @@
  src/client/linux/handler/exception_handler.cc | 17 +++++++++++++++++
  1 file changed, 17 insertions(+)
 
-diff --git a/src/client/linux/handler/exception_handler.cc b/src/client/linux/handler/exception_handler.cc
-index cca023f..f3e460c 100644
---- a/src/client/linux/handler/exception_handler.cc
-+++ b/src/client/linux/handler/exception_handler.cc
-@@ -495,7 +495,19 @@ bool ExceptionHandler::SimulateSignalDelivery(int sig) {
+Index: git/src/client/linux/handler/exception_handler.cc
+===================================================================
+--- git.orig/src/client/linux/handler/exception_handler.cc
++++ git/src/client/linux/handler/exception_handler.cc
+@@ -495,7 +495,19 @@ bool ExceptionHandler::SimulateSignalDel
    siginfo.si_code = SI_USER;
    siginfo.si_pid = getpid();
    ucontext_t context;
@@ -42,11 +42,8 @@
      return false;
 +#else
 +  // Extreme hack - see comments above.
-+  memset (&context.context, 0, sizeof(&context.context));
++  memset (&context.context, 0, sizeof(context.context));
 +#endif
  
  #if defined(__i386__)
    // In CPUFillFromUContext in minidumpwriter.cc the stack pointer is retrieved
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-oe/recipes-devtools/capnproto/capnproto_0.6.1.bb b/meta-openembedded/meta-oe/recipes-devtools/capnproto/capnproto_0.6.1.bb
index ffbe73f..6ca3613 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/capnproto/capnproto_0.6.1.bb
+++ b/meta-openembedded/meta-oe/recipes-devtools/capnproto/capnproto_0.6.1.bb
@@ -2,25 +2,23 @@
 DESCRIPTION = "Cap’n Proto is an insanely fast data interchange format and capability-based RPC system. "
 HOMEPAGE = "https://github.com/sandstorm-io/capnproto"
 SECTION = "console/tools"
-
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://../LICENSE;md5=0a5b5b742baf10cc1c158579eba7fb1d"
 
-SRCREV = "c949a18da5f041a36cc218c5c4b79c7705999b4f"
 SRC_URI = "git://github.com/sandstorm-io/capnproto.git;branch=release-${PV}"
+SRCREV = "c949a18da5f041a36cc218c5c4b79c7705999b4f"
+
+S = "${WORKDIR}/git/c++"
+
+inherit cmake
 
 EXTRA_OECMAKE += "\
     -DBUILD_TESTING=OFF \
 "
 
-inherit cmake
-
-S = "${WORKDIR}/git/c++"
+FILES_${PN}-compiler = "${bindir}"
 
 PACKAGE_BEFORE_PN = "${PN}-compiler"
 RDEPENDS_${PN}-dev += "${PN}-compiler"
 
-FILES_${PN}-dev += "${libdir}/cmake"
-FILES_${PN}-compiler = "${bindir}"
-
 BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/cpuid/cpuid_20170122.bb b/meta-openembedded/meta-oe/recipes-devtools/cpuid/cpuid_20170122.bb
deleted file mode 100644
index 7a70f75..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/cpuid/cpuid_20170122.bb
+++ /dev/null
@@ -1,22 +0,0 @@
-SUMMARY = "Linux tool to dump x86 CPUID information about the CPU(s)"
-DESCRIPTION = "cpuid dumps detailed information about the CPU(s) gathered \
-from the CPUID instruction, and also determines the exact model of CPU(s). \
-It supports Intel, AMD, and VIA CPUs, as well as older Transmeta, Cyrix, \
-UMC, NexGen, Rise, and SiS CPUs"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-
-SRC_URI = "http://www.etallen.com/${BPN}/${BP}.src.tar.gz"
-SRC_URI[md5sum] = "1c46a6662626c5a6eaca626f23a5a7d7"
-SRC_URI[sha256sum] = "667612aae6704341dd10844e97c84c5c5c8700817a5937a3c293b55013bc4865"
-
-COMPATIBLE_HOST = "(i.86|x86_64).*-linux"
-
-# The install rule from the Makefile has hardcoded paths, so we duplicate
-# the actions to accommodate different paths.
-do_install () {
-    install -d -m755 ${D}/${bindir}
-    install -m755 ${B}/cpuid ${D}/${bindir}/cpuid
-    install -d -m755 ${D}/${mandir}
-    install -m444 ${B}/cpuid.man.gz ${D}/${mandir}
-}
diff --git a/meta-openembedded/meta-oe/recipes-devtools/cpuid/cpuid_20180519.bb b/meta-openembedded/meta-oe/recipes-devtools/cpuid/cpuid_20180519.bb
new file mode 100644
index 0000000..533a000
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/cpuid/cpuid_20180519.bb
@@ -0,0 +1,21 @@
+SUMMARY = "Linux tool to dump x86 CPUID information about the CPU(s)"
+DESCRIPTION = "cpuid dumps detailed information about the CPU(s) gathered \
+from the CPUID instruction, and also determines the exact model of CPU(s). \
+It supports Intel, AMD, and VIA CPUs, as well as older Transmeta, Cyrix, \
+UMC, NexGen, Rise, and SiS CPUs"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+SRC_URI = "http://www.etallen.com/${BPN}/${BP}.src.tar.gz \
+           "
+SRC_URI[md5sum] = "b3b4e44ef49575043a91def0207dcc76"
+SRC_URI[sha256sum] = "967823be36f23cbc972eb0aa882d069c1d155a5978990ac3bcf425e6a2e7ff9a"
+
+COMPATIBLE_HOST = "(i.86|x86_64).*-linux"
+
+# The install rule from the Makefile has hardcoded paths, so we duplicate
+# the actions to accommodate different paths.
+do_install () {
+    install -D -m 0755 ${B}/cpuid ${D}/${bindir}/cpuid
+    install -D -m 0444 ${B}/cpuid.man.gz ${D}/${mandir}
+}
diff --git a/meta-openembedded/meta-oe/recipes-devtools/glade/glade_3.20.2.bb b/meta-openembedded/meta-oe/recipes-devtools/glade/glade_3.20.2.bb
deleted file mode 100644
index 95e1737..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/glade/glade_3.20.2.bb
+++ /dev/null
@@ -1,27 +0,0 @@
-SUMMARY = "Glade - A User Interface Designer"
-HOMEPAGE = "http://www.gnu.org/software/gnash"
-LICENSE = "GPLv2 & LGPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=aabe87591cb8ae0f3c68be6977bb5522 \
-                    file://COPYING.GPL;md5=9ac2e7cff1ddaf48b6eab6028f23ef88 \
-                    file://COPYING.LGPL;md5=252890d9eee26aab7b432e8b8a616475"
-DEPENDS = "gtk+ gtk+3 glib-2.0 libxml2 intltool-native \
-           gnome-common-native \
-"
-
-
-inherit distro_features_check autotools pkgconfig gnomebase gobject-introspection
-
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI = "http://ftp.gnome.org/pub/GNOME/sources/glade/3.20/glade-${PV}.tar.xz \
-           file://remove-yelp-help-rules-var.patch \
-          "
-SRC_URI[md5sum] = "d3dd9ba33c7d7c854ab207e1ba844dda"
-SRC_URI[sha256sum] = "07d1545570951aeded20e9fdc6d3d8a56aeefe2538734568c5335be336c6abed"
-
-EXTRA_OECONF += "--disable-man-pages"
-
-FILES_${PN} += "${datadir}/* ${libdir}/glade/modules/libgladegtk.so"
-FILES_${PN}-dev += "${libdir}/glade/modules/libgladegtk.la"
-FILES_${PN}-dbg += "${libdir}/glade/modules/.debug/libgladegtk.so"
-
diff --git a/meta-openembedded/meta-oe/recipes-devtools/glade/glade_3.22.1.bb b/meta-openembedded/meta-oe/recipes-devtools/glade/glade_3.22.1.bb
new file mode 100644
index 0000000..bd4b586
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/glade/glade_3.22.1.bb
@@ -0,0 +1,27 @@
+SUMMARY = "Glade - A User Interface Designer"
+HOMEPAGE = "http://www.gnu.org/software/gnash"
+LICENSE = "GPLv2 & LGPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=aabe87591cb8ae0f3c68be6977bb5522 \
+                    file://COPYING.GPL;md5=9ac2e7cff1ddaf48b6eab6028f23ef88 \
+                    file://COPYING.LGPL;md5=252890d9eee26aab7b432e8b8a616475"
+DEPENDS = "gtk+ gtk+3 glib-2.0 libxml2 intltool-native \
+           gnome-common-native \
+"
+
+
+inherit distro_features_check autotools pkgconfig gnomebase gobject-introspection
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI = "http://ftp.gnome.org/pub/GNOME/sources/glade/3.22/glade-${PV}.tar.xz \
+           file://remove-yelp-help-rules-var.patch \
+          "
+SRC_URI[md5sum] = "226802cf3b06861240524805aa6fe6ff"
+SRC_URI[sha256sum] = "dff89a2ef2eaf000ff2a46979978d03cb9202cb04668e01d0ea5c5bb5547e39a"
+
+EXTRA_OECONF += "--disable-man-pages"
+
+FILES_${PN} += "${datadir}/* ${libdir}/glade/modules/libgladegtk.so"
+FILES_${PN}-dev += "${libdir}/glade/modules/libgladegtk.la"
+FILES_${PN}-dbg += "${libdir}/glade/modules/.debug/libgladegtk.so"
+
diff --git a/meta-openembedded/meta-oe/recipes-devtools/json-spirit/json-spirit_4.08.bb b/meta-openembedded/meta-oe/recipes-devtools/json-spirit/json-spirit_4.08.bb
index c7c1ad1..d6e42c8 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/json-spirit/json-spirit_4.08.bb
+++ b/meta-openembedded/meta-oe/recipes-devtools/json-spirit/json-spirit_4.08.bb
@@ -9,6 +9,8 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=278ef6183dec4aae1524fccc4b0113c9"
 
+DEPENDS = "boost"
+
 SRC_URI = "file://json_spirit_v${PV}.zip \
            file://0001-Adjust-the-cmake-files.patch \
            file://0001-Link-to-libatomic.patch \
@@ -16,10 +18,6 @@
 
 S = "${WORKDIR}/json_spirit_v${PV}"
 
-DEPENDS = "boost"
-
 inherit cmake
 
-FILES_${PN}-dev += "${datadir}/cmake/Modules/FindLibJsonSpirit.cmake"
-
 BBCLASSEXTEND = "nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/kconfig-frontends/kconfig-frontends_4.11.0.1.bb b/meta-openembedded/meta-oe/recipes-devtools/kconfig-frontends/kconfig-frontends_4.11.0.1.bb
index df08b8b..de9a6eb 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/kconfig-frontends/kconfig-frontends_4.11.0.1.bb
+++ b/meta-openembedded/meta-oe/recipes-devtools/kconfig-frontends/kconfig-frontends_4.11.0.1.bb
@@ -11,7 +11,7 @@
 LICENSE = "GPL-2.0"
 LIC_FILES_CHKSUM = "file://COPYING;md5=9b8cf60ff39767ff04b671fca8302408"
 SECTION = "devel"
-DEPENDS += "ncurses flex bison gperf-native"
+DEPENDS += "ncurses flex bison gperf-native bison-native"
 RDEPENDS_${PN} += "python3 bash"
 SRC_URI = "git://ymorin.is-a-geek.org/kconfig-frontends;branch=4.11.x \
 	   file://0001-Makefile-ensure-frontends-exits-before-writing-into-.patch \
diff --git a/meta-openembedded/meta-oe/recipes-devtools/lapack/lapack_3.8.0.bb b/meta-openembedded/meta-oe/recipes-devtools/lapack/lapack_3.8.0.bb
new file mode 100644
index 0000000..7544744
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/lapack/lapack_3.8.0.bb
@@ -0,0 +1,24 @@
+SUMMARY = "Linear Algebra PACKage"
+URL = "http://www.netlib.org/lapack"
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=930f8aa500a47c7dab0f8efb5a1c9a40"
+
+# Recipe needs FORTRAN support (copied from conf/local.conf.sample.extended)
+# Enabling FORTRAN
+# Note this is not officially supported and is just illustrated here to
+# show an example of how it can be done
+# You'll also need your fortran recipe to depend on libgfortran
+#FORTRAN_forcevariable = ",fortran"
+#RUNTIMETARGET_append_pn-gcc-runtime = " libquadmath"
+
+DEPENDS = "libgfortran"
+
+SRC_URI = "http://www.netlib.org/lapack/lapack-${PV}.tar.gz"
+SRC_URI[md5sum] = "96591affdbf58c450d45c1daa540dbd2"
+SRC_URI[sha256sum] = "deb22cc4a6120bff72621155a9917f485f96ef8319ac074a7afbc68aab88bcf6"
+
+EXTRA_OECMAKE = " -DBUILD_SHARED_LIBS=ON "
+OECMAKE_GENERATOR = "Unix Makefiles"
+
+inherit cmake pkgconfig
+EXCLUDE_FROM_WORLD = "1"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/libedit/libedit_20170329-3.1.bb b/meta-openembedded/meta-oe/recipes-devtools/libedit/libedit_20170329-3.1.bb
deleted file mode 100644
index fc24671..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/libedit/libedit_20170329-3.1.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-SUMMARY = "BSD replacement for libreadline"
-DESCRIPTION = "Command line editor library providing generic line editing, \
-history, and tokenization functions"
-HOMEPAGE = "http://www.thrysoee.dk/editline/"
-SECTION = "libs"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=1e4228d0c5a9093b01aeaaeae6641533"
-
-DEPENDS = "ncurses"
-
-inherit autotools
-
-# upstream site does not allow wget's User-Agent
-FETCHCMD_wget += "-U bitbake"
-SRC_URI = "http://www.thrysoee.dk/editline/${BPN}-${PV}.tar.gz \
-           file://stdc-predef.patch \
-          "
-SRC_URI[md5sum] = "c57a0690e62ef523c083598730272cfd"
-SRC_URI[sha256sum] = "91f2d90fbd2a048ff6dad7131d9a39e690fd8a8fd982a353f1333dd4017dd4be"
-
-S = "${WORKDIR}/${BPN}-${PV}"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/libedit/libedit_20180525-3.1.bb b/meta-openembedded/meta-oe/recipes-devtools/libedit/libedit_20180525-3.1.bb
new file mode 100644
index 0000000..8cc0e95
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/libedit/libedit_20180525-3.1.bb
@@ -0,0 +1,21 @@
+SUMMARY = "BSD replacement for libreadline"
+DESCRIPTION = "Command line editor library providing generic line editing, \
+history, and tokenization functions"
+HOMEPAGE = "http://www.thrysoee.dk/editline/"
+SECTION = "libs"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=1e4228d0c5a9093b01aeaaeae6641533"
+
+DEPENDS = "ncurses"
+
+inherit autotools
+
+# upstream site does not allow wget's User-Agent
+FETCHCMD_wget += "-U bitbake"
+SRC_URI = "http://www.thrysoee.dk/editline/${BPN}-${PV}.tar.gz \
+           file://stdc-predef.patch \
+          "
+SRC_URI[md5sum] = "97679319742f45d6cdcd6075511b14ac"
+SRC_URI[sha256sum] = "c41bea8fd140fb57ba67a98ec1d8ae0b8ffa82f4aba9c35a87e5a9499e653116"
+
+S = "${WORKDIR}/${BPN}-${PV}"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/libfribidi/fribidi_0.19.7.bb b/meta-openembedded/meta-oe/recipes-devtools/libfribidi/fribidi_0.19.7.bb
deleted file mode 100644
index 423a914..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/libfribidi/fribidi_0.19.7.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-SUMMARY = "Fribidi library for bidirectional text"
-SECTION = "libs"
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=a916467b91076e631dd8edb7424769c7"
-BBCLASSEXTEND = "native"
-
-PROVIDES = "libfribidi"
-DEPENDS = "glib-2.0 libpcre"
-
-inherit autotools lib_package pkgconfig
-
-CFLAGS_append = "  -DPAGE_SIZE=4096 "
-SECURITY_CFLAGS_remove_toolchain-clang = "-D_FORTIFY_SOURCE=2"
-
-SRC_URI = "http://fribidi.org/download/fribidi-${PV}.tar.bz2"
-
-SRC_URI[md5sum] = "6c7e7cfdd39c908f7ac619351c1c5c23"
-SRC_URI[sha256sum] = "08222a6212bbc2276a2d55c3bf370109ae4a35b689acbc66571ad2a670595a8e"
-
-CVE_PRODUCT = "gnu_fribidi"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/librcf/librcf_2.2.0.0.bb b/meta-openembedded/meta-oe/recipes-devtools/librcf/librcf_2.2.0.0.bb
index 267c0e7..dcd47a4 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/librcf/librcf_2.2.0.0.bb
+++ b/meta-openembedded/meta-oe/recipes-devtools/librcf/librcf_2.2.0.0.bb
@@ -47,7 +47,6 @@
 PACKAGES =+ "${@bb.utils.contains('PACKAGECONFIG', 'demos', '${PN}-demos', '', d)}"
 
 FILES_${PN}-demos = "${bindir}/*"
-FILES_${PN}-dev += "${datadir}/cmake/Modules/FindLibRcf.cmake"
 
 BBCLASSEXTEND = "nativesdk"
 
diff --git a/meta-openembedded/meta-oe/recipes-devtools/log4cplus/log4cplus_1.2.0.bb b/meta-openembedded/meta-oe/recipes-devtools/log4cplus/log4cplus_1.2.0.bb
deleted file mode 100644
index 31ab9a6..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/log4cplus/log4cplus_1.2.0.bb
+++ /dev/null
@@ -1,15 +0,0 @@
-SUMMARY = "log4cplus provides a simple C++ logging API for log management"
-SECTION = "libs"
-HOMEPAGE = "http://sourceforge.net/projects/log4cplus/"
-BUGTRACKER = "http://sourceforge.net/p/log4cplus/bugs/"
-
-LICENSE = "Apache-2.0 & BSD-2-Clause"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=cedaa287ececcb94f9f2880d9c4ef085"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/project/${BPN}/${BPN}-stable/${PV}/${BP}.tar.gz"
-SRC_URI[md5sum] = "e250f0f431c0723f8b625323e7b6465d"
-SRC_URI[sha256sum] = "ad5ec3b62f2f0bdc7f06fa398bde61091fd2493e91059e17315b5197420dcf04"
-
-inherit autotools pkgconfig
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/log4cplus/log4cplus_2.0.2.bb b/meta-openembedded/meta-oe/recipes-devtools/log4cplus/log4cplus_2.0.2.bb
new file mode 100644
index 0000000..d17d15c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/log4cplus/log4cplus_2.0.2.bb
@@ -0,0 +1,18 @@
+SUMMARY = "log4cplus provides a simple C++ logging API for log management"
+SECTION = "libs"
+HOMEPAGE = "http://sourceforge.net/projects/log4cplus/"
+BUGTRACKER = "http://sourceforge.net/p/log4cplus/bugs/"
+
+LICENSE = "Apache-2.0 & BSD-2-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=41e8e060c26822886b592ab4765c756b"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/project/${BPN}/${BPN}-stable/${PV}/${BP}.tar.gz"
+SRC_URI[md5sum] = "b3bbeb2dc3e170768430cf87583016f8"
+SRC_URI[sha256sum] = "10539f2315271d370c7bc6a2b4808cbe369279837f4539ce5c789e456489fc62"
+
+UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/log4cplus/files/log4cplus-stable/"
+UPSTREAM_CHECK_REGEX = "log4cplus-stable/(?P<pver>\d+(\.\d+)+)/"
+
+inherit autotools pkgconfig
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/lshw/files/0001-Makefile-Fix-cross-compilation.patch b/meta-openembedded/meta-oe/recipes-devtools/lshw/files/0001-Makefile-Fix-cross-compilation.patch
new file mode 100644
index 0000000..6db6ab9
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/lshw/files/0001-Makefile-Fix-cross-compilation.patch
@@ -0,0 +1,57 @@
+From 62f9ed95b5d0feab426bff452be793c62a6b795a Mon Sep 17 00:00:00 2001
+From: Krzysztof Kozlowski <krzk@kernel.org>
+Date: Wed, 6 Jun 2018 12:49:21 +0200
+Subject: [PATCH 1/2] Makefile: Fix cross compilation
+
+Allow building on ARMv7 and ARMv8.
+
+Upstream-Status: Submitted
+Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
+---
+ src/Makefile      | 2 +-
+ src/core/Makefile | 2 +-
+ src/gui/Makefile  | 4 ++--
+ 3 files changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/src/Makefile b/src/Makefile
+index b50586bc9234..654b786dd899 100644
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -18,7 +18,7 @@ export MANDIR
+ export DATADIR
+ export SQLITE
+ 
+-CXX?=c++
++CXX?=$(CROSS_COMPILE)c++
+ INCLUDES=-I./core/
+ DEFINES=-DPREFIX=\"$(PREFIX)\" -DSBINDIR=\"$(SBINDIR)\" -DMANDIR=\"$(MANDIR)\" -DDATADIR=\"$(DATADIR)\"
+ CXXFLAGS=-g -Wall -g $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
+diff --git a/src/core/Makefile b/src/core/Makefile
+index 5bf5a69cc6a6..2bd1b94c4175 100644
+--- a/src/core/Makefile
++++ b/src/core/Makefile
+@@ -1,6 +1,6 @@
+ PACKAGENAME?=lshw
+ 
+-CXX=c++
++CXX?=$(CROSS_COMPILE)c++
+ INCLUDES=
+ DEFINES=-DPREFIX=\"$(PREFIX)\" -DSBINDIR=\"$(SBINDIR)\" -DMANDIR=\"$(MANDIR)\" -DDATADIR=\"$(DATADIR)\"
+ CXXFLAGS?=-g -Wall $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
+diff --git a/src/gui/Makefile b/src/gui/Makefile
+index 332ce5704819..b0f925490356 100644
+--- a/src/gui/Makefile
++++ b/src/gui/Makefile
+@@ -1,7 +1,7 @@
+ PACKAGENAME?=lshw
+ 
+-CXX?=c++
+-CC?=cc
++CXX?=$(CROSS_COMPILE)c++
++CC?=$(CROSS_COMPILE)cc
+ STRIP?=strip
+ OBJCOPY?=objcopy
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-devtools/lshw/files/0002-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch b/meta-openembedded/meta-oe/recipes-devtools/lshw/files/0002-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch
new file mode 100644
index 0000000..d3da01b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/lshw/files/0002-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch
@@ -0,0 +1,34 @@
+From 75667f8a0ae4f1689ff03eb1768b1ee8cdfbf00d Mon Sep 17 00:00:00 2001
+From: Krzysztof Kozlowski <krzk@kernel.org>
+Date: Wed, 6 Jun 2018 12:49:30 +0200
+Subject: [PATCH 2/2] Makefile: Use supplied LDFLAGS to silence OE GNU_HASH QA
+ warning
+
+Fix OpenEmbedded/Yocto QA warning:
+
+    ERROR: lshw-02.16-r1 do_package_qa: QA Issue: No GNU_HASH in the elf binary: 'build/tmp/work/cortexa5hf-neon-poky-linux-gnueabi/lshw/02.16-r1/packages-split/lshw/usr/sbin/lshw' [ldflags]
+    ERROR: lshw-02.16-r1 do_package_qa: QA run found fatal errors. Please consider fixing them.
+    ERROR: lshw-02.16-r1 do_package_qa: Function failed: do_package_qa
+
+Upstream-Status: Submitted
+Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
+---
+ src/Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/Makefile b/src/Makefile
+index 654b786dd899..a441ba2bb666 100644
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -25,7 +25,7 @@ CXXFLAGS=-g -Wall -g $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
+ ifeq ($(SQLITE), 1)
+ 	CXXFLAGS+= -DSQLITE $(shell pkg-config --cflags sqlite3)
+ endif
+-LDFLAGS=-L./core/ -g
++LDFLAGS+=-L./core/ -g
+ ifneq ($(shell $(LD) --help 2| grep -- --as-needed), )
+ 	LDFLAGS+= -Wl,--as-needed
+ endif
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-devtools/lshw/files/0003-sysfs-Fix-basename-build-with-musl.patch b/meta-openembedded/meta-oe/recipes-devtools/lshw/files/0003-sysfs-Fix-basename-build-with-musl.patch
new file mode 100644
index 0000000..3492493
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/lshw/files/0003-sysfs-Fix-basename-build-with-musl.patch
@@ -0,0 +1,92 @@
+From a89f2ba8496994c8b5e28a89202df15d64c648f9 Mon Sep 17 00:00:00 2001
+From: Krzysztof Kozlowski <krzk@kernel.org>
+Date: Wed, 6 Jun 2018 12:47:02 +0200
+Subject: [PATCH] sysfs: Fix basename() build with musl
+
+musl provides only standard basename() which accepts non-const string.
+This fixes build error with musl C library:
+
+    | sysfs.cc: In function 'std::__cxx11::string sysfs_getbustype(const string&)':
+    | sysfs.cc:102:21: error: 'basename' was not declared in this scope
+    |        "/devices/" + basename(path.c_str());
+    |                      ^~~~~~~~
+
+Upstream-Status: Submitted
+Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
+---
+ src/core/dasd.cc  | 3 ++-
+ src/core/sysfs.cc | 9 +++++----
+ 2 files changed, 7 insertions(+), 5 deletions(-)
+
+diff --git a/src/core/dasd.cc b/src/core/dasd.cc
+index 626b8a872b0f..b27844215cc4 100644
+--- a/src/core/dasd.cc
++++ b/src/core/dasd.cc
+@@ -2,6 +2,7 @@
+ #include "osutils.h"
+ #include "dasd.h"
+ #include <glob.h>
++#include <libgen.h>
+ #include <string.h>
+ #include <fcntl.h>
+ #include <unistd.h>
+@@ -42,7 +43,7 @@ bool scan_dasd(hwNode & n)
+   {
+     for(dev_num=0;dev_num<devices.gl_pathc;dev_num++)
+     {
+-      dev_name = basename(devices.gl_pathv[dev_num]);
++      dev_name = basename(const_cast<char *>(devices.gl_pathv[dev_num]));
+       for (std::vector<std::string>::iterator it = sysfs_attribs.begin(); it != sysfs_attribs.end(); ++it)
+       {
+         std::string attrib_fname = std::string(SYSFS_PREFIX) + dev_name + "/device/" + *it;
+diff --git a/src/core/sysfs.cc b/src/core/sysfs.cc
+index acc9d0056d5e..c56bab7b3b9f 100644
+--- a/src/core/sysfs.cc
++++ b/src/core/sysfs.cc
+@@ -7,6 +7,7 @@
+ #include "version.h"
+ #include "sysfs.h"
+ #include "osutils.h"
++#include <libgen.h>
+ #include <limits.h>
+ #include <unistd.h>
+ #include <stdlib.h>
+@@ -99,7 +100,7 @@ static string sysfs_getbustype(const string & path)
+   {
+     devname =
+       string(fs.path + "/bus/") + string(namelist[i]->d_name) +
+-      "/devices/" + basename(path.c_str());
++      "/devices/" + basename(const_cast<char *>(path.c_str()));
+ 
+     if (samefile(devname, path))
+       return string(namelist[i]->d_name);
+@@ -139,7 +140,7 @@ static string sysfstobusinfo(const string & path)
+ 
+   if (bustype == "virtio")
+   {
+-    string name = basename(path.c_str());
++    string name = basename(const_cast<char *>(path.c_str()));
+     if (name.compare(0, 6, "virtio") == 0)
+       return "virtio@" + name.substr(6);
+     else
+@@ -207,7 +208,7 @@ string entry::driver() const
+   string driverlink = This->devpath + "/driver";
+   if (!exists(driverlink))
+     return "";
+-  return basename(readlink(driverlink).c_str());
++  return basename(const_cast<char *>(readlink(driverlink).c_str()));
+ }
+ 
+ 
+@@ -288,7 +289,7 @@ string entry::name_in_class(const string & classname) const
+ 
+ string entry::name() const
+ {
+-  return basename(This->devpath.c_str());
++  return basename(const_cast<char *>(This->devpath.c_str()));
+ }
+ 
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-devtools/lshw/lshw_02.18.bb b/meta-openembedded/meta-oe/recipes-devtools/lshw/lshw_02.18.bb
new file mode 100644
index 0000000..b344fbf
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/lshw/lshw_02.18.bb
@@ -0,0 +1,32 @@
+DESCRIPTION = "A small tool to provide detailed information on the hardware \
+configuration of the machine. It can report exact memory configuration, \
+firmware version, mainboard configuration, CPU version and speed, cache \
+configuration, bus speed, etc. on DMI-capable or EFI systems."
+SUMMARY = "Hardware lister"
+HOMEPAGE = "http://ezix.org/project/wiki/HardwareLiSter"
+SECTION = "console/tools"
+
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+COMPATIBLE_HOST = "(i.86|x86_64|arm|aarch64).*-linux"
+
+SRC_URI = " \
+    http://ezix.org/software/files/lshw-B.${PV}.tar.gz \
+    file://0001-Makefile-Fix-cross-compilation.patch \
+    file://0002-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch \
+    file://0003-sysfs-Fix-basename-build-with-musl.patch \
+"
+SRC_URI[md5sum] = "8671c6d94d6324a744b7f21f1bfecfd2"
+SRC_URI[sha256sum] = "ae22ef11c934364be4fd2a0a1a7aadf4495a0251ec6979da280d342a89ca3c2f"
+
+S = "${WORKDIR}/lshw-B.${PV}"
+
+do_compile() {
+    # build core only - don't ship gui
+    oe_runmake -C src core
+}
+
+do_install() {
+    oe_runmake install DESTDIR=${D}
+}
diff --git a/meta-openembedded/meta-oe/recipes-devtools/ltrace/ltrace_git.bb b/meta-openembedded/meta-oe/recipes-devtools/ltrace/ltrace_git.bb
index abe015d..f4033f7 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/ltrace/ltrace_git.bb
+++ b/meta-openembedded/meta-oe/recipes-devtools/ltrace/ltrace_git.bb
@@ -15,7 +15,7 @@
 
 DEPENDS = "elfutils"
 RDEPENDS_${PN} = "elfutils"
-SRC_URI = "git://anonscm.debian.org/collab-maint/ltrace.git;branch=master \
+SRC_URI = "git://github.com/sparkleholic/ltrace.git;branch=master;protocol=http \
            file://configure-allow-to-disable-selinux-support.patch \
            file://0001-replace-readdir_r-with-readdir.patch \
            file://0001-Use-correct-enum-type.patch \
diff --git a/meta-openembedded/meta-oe/recipes-devtools/luajit/luajit_2.0.5.bb b/meta-openembedded/meta-oe/recipes-devtools/luajit/luajit_2.0.5.bb
index 1d69b3c..3052eb0 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/luajit/luajit_2.0.5.bb
+++ b/meta-openembedded/meta-oe/recipes-devtools/luajit/luajit_2.0.5.bb
@@ -3,14 +3,14 @@
 LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=10a96c93403affcc34765f4c2612bc22"
 HOMEPAGE = "http://luajit.org"
 
-SRC_URI = "http://luajit.org/download/LuaJIT-${PV}.tar.gz \
+PV .= "+git${SRCPV}"
+SRCREV = "02b521981a1ab919ff2cd4d9bcaee80baf77dce2"
+SRC_URI = "git://luajit.org/git/luajit-2.0.git;protocol=http \
            file://0001-Do-not-strip-automatically-this-leaves-the-stripping.patch \
            file://clang.patch \
 "
-SRC_URI[md5sum] = "48353202cbcacab84ee41a5a70ea0a2c"
-SRC_URI[sha256sum] = "874b1f8297c697821f561f9b73b57ffd419ed8f4278c82e05b48806d30c1e979"
 
-S = "${WORKDIR}/LuaJIT-${PV}"
+S = "${WORKDIR}/git"
 
 inherit pkgconfig binconfig siteinfo
 
@@ -49,7 +49,6 @@
     'TARGET_SHLDFLAGS=${LDFLAGS}' \
     'HOST_CC=${BUILD_CC}' \
     'HOST_CFLAGS=${BUILD_CFLAGS}' \
-    'HOST_LDFLAGS=${BUILD_LDFLAGS}' \
     \
     'PREFIX=${prefix}' \
     'MULTILIB=${baselib}' \
diff --git a/meta-openembedded/meta-oe/recipes-devtools/mercurial/mercurial_4.4.bb b/meta-openembedded/meta-oe/recipes-devtools/mercurial/mercurial_4.4.bb
deleted file mode 100644
index 9052497..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/mercurial/mercurial_4.4.bb
+++ /dev/null
@@ -1,31 +0,0 @@
-SUMMARY = "The Mercurial distributed SCM"
-HOMEPAGE = "http://mercurial.selenic.com/"
-SECTION = "console/utils"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-DEPENDS = "python python-native"
-DEPENDS_class-native = "python-native"
-RDEPENDS_${PN} = "python python-modules"
-
-inherit python-dir
-
-SRC_URI = "https://www.mercurial-scm.org/release/${BP}.tar.gz"
-SRC_URI[md5sum] = "c1d9fad1b7ed7077b0d4ae82e71154db"
-SRC_URI[sha256sum] = "234af4a67565c85923b0a1910c704ab44bcf12f69b85532687208776563d87de"
-
-S = "${WORKDIR}/mercurial-${PV}"
-
-BBCLASSEXTEND = "native"
-
-EXTRA_OEMAKE = "STAGING_LIBDIR=${STAGING_LIBDIR} STAGING_INCDIR=${STAGING_INCDIR} \
-    PREFIX=${prefix}"
-
-do_configure_append () {
-    sed -i -e 's:PYTHON=python:PYTHON=${STAGING_BINDIR_NATIVE}/python-native/python:g' ${S}/Makefile
-}
-
-do_install () {
-    oe_runmake -e install-bin DESTDIR=${D} PREFIX=${prefix}
-}
-
-FILES_${PN} += "${PYTHON_SITEPACKAGES_DIR}"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/mercurial/mercurial_4.6.1.bb b/meta-openembedded/meta-oe/recipes-devtools/mercurial/mercurial_4.6.1.bb
new file mode 100644
index 0000000..13710aa
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/mercurial/mercurial_4.6.1.bb
@@ -0,0 +1,31 @@
+SUMMARY = "The Mercurial distributed SCM"
+HOMEPAGE = "http://mercurial.selenic.com/"
+SECTION = "console/utils"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+DEPENDS = "python python-native"
+DEPENDS_class-native = "python-native"
+RDEPENDS_${PN} = "python python-modules"
+
+inherit python-dir
+
+SRC_URI = "https://www.mercurial-scm.org/release/${BP}.tar.gz"
+SRC_URI[md5sum] = "f9b2e4a3b5901ef744fa3abe4196e97e"
+SRC_URI[sha256sum] = "89fa8ecbc8aa6e48e98f9803a1683ba91367124295dba2407b28c34ca621108d"
+
+S = "${WORKDIR}/mercurial-${PV}"
+
+BBCLASSEXTEND = "native"
+
+EXTRA_OEMAKE = "STAGING_LIBDIR=${STAGING_LIBDIR} STAGING_INCDIR=${STAGING_INCDIR} \
+    PREFIX=${prefix}"
+
+do_configure_append () {
+    sed -i -e 's:PYTHON=python:PYTHON=${STAGING_BINDIR_NATIVE}/python-native/python:g' ${S}/Makefile
+}
+
+do_install () {
+    oe_runmake -e install-bin DESTDIR=${D} PREFIX=${prefix}
+}
+
+FILES_${PN} += "${PYTHON_SITEPACKAGES_DIR}"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/msgpack/msgpack-c_2.1.5.bb b/meta-openembedded/meta-oe/recipes-devtools/msgpack/msgpack-c_2.1.5.bb
index 02c0cd2..690a7f4 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/msgpack/msgpack-c_2.1.5.bb
+++ b/meta-openembedded/meta-oe/recipes-devtools/msgpack/msgpack-c_2.1.5.bb
@@ -9,14 +9,11 @@
 
 PV .= "+git${SRCPV}"
 
-SRCREV = "208595b2620cf6260ce3d6d4cf8543f13b206449"
-
 SRC_URI = "git://github.com/msgpack/msgpack-c \
            file://0001-Fix-Werror-class-memaccess.patch \
            "
-
-inherit cmake pkgconfig
+SRCREV = "208595b2620cf6260ce3d6d4cf8543f13b206449"
 
 S = "${WORKDIR}/git"
 
-FILES_${PN}-dev += "${libdir}/cmake/msgpack/*.cmake"
+inherit cmake pkgconfig
diff --git a/meta-openembedded/meta-oe/recipes-devtools/nodejs/nodejs_8.12.0.bb b/meta-openembedded/meta-oe/recipes-devtools/nodejs/nodejs_8.12.0.bb
new file mode 100644
index 0000000..8c33978
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/nodejs/nodejs_8.12.0.bb
@@ -0,0 +1,92 @@
+DESCRIPTION = "nodeJS Evented I/O for V8 JavaScript"
+HOMEPAGE = "http://nodejs.org"
+LICENSE = "MIT & BSD & Artistic-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=fde91d5c5bbd1e0389623e1ac018d9e8"
+
+DEPENDS = "openssl zlib icu"
+
+inherit pkgconfig
+
+COMPATIBLE_MACHINE_armv4 = "(!.*armv4).*"
+COMPATIBLE_MACHINE_armv5 = "(!.*armv5).*"
+COMPATIBLE_MACHINE_mips64 = "(!.*mips64).*"
+
+SRC_URI = "http://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz \
+           file://0001-Disable-running-gyp-files-for-bundled-deps.patch \
+"
+SRC_URI[md5sum] = "8b3abd033dae96b6fadcb6a872a44d3c"
+SRC_URI[sha256sum] = "5a9dff58016c18fb4bf902d963b124ff058a550ebcd9840c677757387bce419a"
+
+S = "${WORKDIR}/node-v${PV}"
+
+# v8 errors out if you have set CCACHE
+CCACHE = ""
+
+def map_nodejs_arch(a, d):
+    import re
+
+    if   re.match('i.86$', a): return 'ia32'
+    elif re.match('x86_64$', a): return 'x64'
+    elif re.match('aarch64$', a): return 'arm64'
+    elif re.match('(powerpc64|ppc64le)$', a): return 'ppc64'
+    elif re.match('powerpc$', a): return 'ppc'
+    return a
+
+ARCHFLAGS_arm = "${@bb.utils.contains('TUNE_FEATURES', 'callconvention-hard', '--with-arm-float-abi=hard', '--with-arm-float-abi=softfp', d)} \
+                 ${@bb.utils.contains('TUNE_FEATURES', 'neon', '--with-arm-fpu=neon', \
+                    bb.utils.contains('TUNE_FEATURES', 'vfpv3d16', '--with-arm-fpu=vfpv3-d16', \
+                    bb.utils.contains('TUNE_FEATURES', 'vfpv3', '--with-arm-fpu=vfpv3', \
+                    '--with-arm-fpu=vfp', d), d), d)}"
+GYP_DEFINES_append_mipsel = " mips_arch_variant='r1' "
+ARCHFLAGS ?= ""
+
+# Node is way too cool to use proper autotools, so we install two wrappers to forcefully inject proper arch cflags to workaround gypi
+do_configure () {
+    rm -rf ${S}/deps/openssl
+    export LD="${CXX}"
+    GYP_DEFINES="${GYP_DEFINES}" export GYP_DEFINES
+    # $TARGET_ARCH settings don't match --dest-cpu settings
+   ./configure --prefix=${prefix} --with-intl=system-icu --without-snapshot --shared-openssl --shared-zlib \
+               --dest-cpu="${@map_nodejs_arch(d.getVar('TARGET_ARCH'), d)}" \
+               --dest-os=linux \
+               ${ARCHFLAGS}
+}
+
+do_compile () {
+    export LD="${CXX}"
+    oe_runmake BUILDTYPE=Release
+}
+
+do_install () {
+    oe_runmake install DESTDIR=${D}
+}
+
+do_install_append_class-native() {
+    # use node from PATH instead of absolute path to sysroot
+    # node-v0.10.25/tools/install.py is using:
+    # shebang = os.path.join(node_prefix, 'bin/node')
+    # update_shebang(link_path, shebang)
+    # and node_prefix can be very long path to bindir in native sysroot and
+    # when it exceeds 128 character shebang limit it's stripped to incorrect path
+    # and npm fails to execute like in this case with 133 characters show in log.do_install:
+    # updating shebang of /home/jenkins/workspace/build-webos-nightly/device/qemux86/label/open-webos-builder/BUILD-qemux86/work/x86_64-linux/nodejs-native/0.10.15-r0/image/home/jenkins/workspace/build-webos-nightly/device/qemux86/label/open-webos-builder/BUILD-qemux86/sysroots/x86_64-linux/usr/bin/npm to /home/jenkins/workspace/build-webos-nightly/device/qemux86/label/open-webos-builder/BUILD-qemux86/sysroots/x86_64-linux/usr/bin/node
+    # /usr/bin/npm is symlink to /usr/lib/node_modules/npm/bin/npm-cli.js
+    # use sed on npm-cli.js because otherwise symlink is replaced with normal file and
+    # npm-cli.js continues to use old shebang
+    sed "1s^.*^#\!/usr/bin/env node^g" -i ${D}${exec_prefix}/lib/node_modules/npm/bin/npm-cli.js
+}
+
+do_install_append_class-target() {
+    sed "1s^.*^#\!${bindir}/env node^g" -i ${D}${exec_prefix}/lib/node_modules/npm/bin/npm-cli.js
+}
+
+PACKAGES =+ "${PN}-npm"
+FILES_${PN}-npm = "${exec_prefix}/lib/node_modules ${bindir}/npm ${bindir}/npx"
+RDEPENDS_${PN}-npm = "bash python-shell python-datetime python-subprocess python-textutils \
+    python-compiler python-misc python-multiprocessing"
+
+PACKAGES =+ "${PN}-systemtap"
+FILES_${PN}-systemtap = "${datadir}/systemtap"
+
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/nodejs/nodejs_8.9.4.bb b/meta-openembedded/meta-oe/recipes-devtools/nodejs/nodejs_8.9.4.bb
deleted file mode 100644
index 8930cd9..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/nodejs/nodejs_8.9.4.bb
+++ /dev/null
@@ -1,90 +0,0 @@
-DESCRIPTION = "nodeJS Evented I/O for V8 JavaScript"
-HOMEPAGE = "http://nodejs.org"
-LICENSE = "MIT & BSD & Artistic-2.0"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=270f7477a1705f7cd3e29d3d4512915d"
-
-DEPENDS = "openssl10 zlib"
-
-COMPATIBLE_MACHINE_armv4 = "(!.*armv4).*"
-COMPATIBLE_MACHINE_armv5 = "(!.*armv5).*"
-COMPATIBLE_MACHINE_mips64 = "(!.*mips64).*"
-
-SRC_URI = "http://nodejs.org/dist/v${PV}/node-v${PV}.tar.xz \
-           file://0001-Disable-running-gyp-files-for-bundled-deps.patch \
-"
-SRC_URI[md5sum] = "631ed102fe58c13cf63bc92a68cf4759"
-SRC_URI[sha256sum] = "6cdcde9c9c1ca9f450a0b24eafa229ca759e576daa0fae892ce74d541ecdc86f"
-
-S = "${WORKDIR}/node-v${PV}"
-
-# v8 errors out if you have set CCACHE
-CCACHE = ""
-
-def map_nodejs_arch(a, d):
-    import re
-
-    if   re.match('i.86$', a): return 'ia32'
-    elif re.match('x86_64$', a): return 'x64'
-    elif re.match('aarch64$', a): return 'arm64'
-    elif re.match('(powerpc64|ppc64le)$', a): return 'ppc64'
-    elif re.match('powerpc$', a): return 'ppc'
-    return a
-
-ARCHFLAGS_arm = "${@bb.utils.contains('TUNE_FEATURES', 'callconvention-hard', '--with-arm-float-abi=hard', '--with-arm-float-abi=softfp', d)} \
-                 ${@bb.utils.contains('TUNE_FEATURES', 'neon', '--with-arm-fpu=neon', \
-                    bb.utils.contains('TUNE_FEATURES', 'vfpv3d16', '--with-arm-fpu=vfpv3-d16', \
-                    bb.utils.contains('TUNE_FEATURES', 'vfpv3', '--with-arm-fpu=vfpv3', \
-                    '--with-arm-fpu=vfp', d), d), d)}"
-GYP_DEFINES_append_mipsel = " mips_arch_variant='r1' "
-ARCHFLAGS ?= ""
-
-# Node is way too cool to use proper autotools, so we install two wrappers to forcefully inject proper arch cflags to workaround gypi
-do_configure () {
-    rm -rf ${S}/deps/openssl
-    export LD="${CXX}"
-    GYP_DEFINES="${GYP_DEFINES}" export GYP_DEFINES
-    # $TARGET_ARCH settings don't match --dest-cpu settings
-   ./configure --prefix=${prefix} --without-intl --without-snapshot --shared-openssl --shared-zlib \
-               --dest-cpu="${@map_nodejs_arch(d.getVar('TARGET_ARCH'), d)}" \
-               --dest-os=linux \
-               ${ARCHFLAGS}
-}
-
-do_compile () {
-    export LD="${CXX}"
-    oe_runmake BUILDTYPE=Release
-}
-
-do_install () {
-    oe_runmake install DESTDIR=${D}
-}
-
-do_install_append_class-native() {
-    # use node from PATH instead of absolute path to sysroot
-    # node-v0.10.25/tools/install.py is using:
-    # shebang = os.path.join(node_prefix, 'bin/node')
-    # update_shebang(link_path, shebang)
-    # and node_prefix can be very long path to bindir in native sysroot and
-    # when it exceeds 128 character shebang limit it's stripped to incorrect path
-    # and npm fails to execute like in this case with 133 characters show in log.do_install:
-    # updating shebang of /home/jenkins/workspace/build-webos-nightly/device/qemux86/label/open-webos-builder/BUILD-qemux86/work/x86_64-linux/nodejs-native/0.10.15-r0/image/home/jenkins/workspace/build-webos-nightly/device/qemux86/label/open-webos-builder/BUILD-qemux86/sysroots/x86_64-linux/usr/bin/npm to /home/jenkins/workspace/build-webos-nightly/device/qemux86/label/open-webos-builder/BUILD-qemux86/sysroots/x86_64-linux/usr/bin/node
-    # /usr/bin/npm is symlink to /usr/lib/node_modules/npm/bin/npm-cli.js
-    # use sed on npm-cli.js because otherwise symlink is replaced with normal file and
-    # npm-cli.js continues to use old shebang
-    sed "1s^.*^#\!/usr/bin/env node^g" -i ${D}${exec_prefix}/lib/node_modules/npm/bin/npm-cli.js
-}
-
-do_install_append_class-target() {
-    sed "1s^.*^#\!${bindir}/env node^g" -i ${D}${exec_prefix}/lib/node_modules/npm/bin/npm-cli.js
-}
-
-PACKAGES =+ "${PN}-npm"
-FILES_${PN}-npm = "${exec_prefix}/lib/node_modules ${bindir}/npm ${bindir}/npx"
-RDEPENDS_${PN}-npm = "bash python-shell python-datetime python-subprocess python-textutils \
-    python-compiler python-misc python-multiprocessing"
-
-PACKAGES =+ "${PN}-systemtap"
-FILES_${PN}-systemtap = "${datadir}/systemtap"
-
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0001-Add-fallthrough-comments.patch b/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0001-Add-fallthrough-comments.patch
deleted file mode 100644
index 644146c..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0001-Add-fallthrough-comments.patch
+++ /dev/null
@@ -1,155 +0,0 @@
-From 8f85163b030e7b957648f90cd8fa599fb04d5d65 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 16 Jun 2017 23:32:49 -0700
-Subject: [PATCH 1/5] Add fallthrough comments
-
-Fixes
-
-src/svf/svf.c:663:7: error: this statement may fall through [-Werror=implicit-fallthrough=]
-     i = -1;
-     ~~^~~~
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/flash/mflash.c            | 3 ++-
- src/flash/nand/mx3.c          | 1 +
- src/jtag/drivers/ftdi.c       | 1 +
- src/svf/svf.c                 | 2 ++
- src/target/arm_adi_v5.c       | 9 +++++++++
- src/target/arm_disassembler.c | 1 +
- src/target/target.c           | 1 +
- 7 files changed, 17 insertions(+), 1 deletion(-)
-
-diff --git a/src/flash/mflash.c b/src/flash/mflash.c
-index b69995542..3254a3d56 100644
---- a/src/flash/mflash.c
-+++ b/src/flash/mflash.c
-@@ -259,10 +259,11 @@ static int mg_dsk_wait(mg_io_type_wait wait_local, uint32_t time_var)
- 				case mg_io_wait_rdy:
- 					if (status & mg_io_rbit_status_ready)
- 						return ERROR_OK;
--
-+					/* fallthru */
- 				case mg_io_wait_drq:
- 					if (status & mg_io_rbit_status_data_req)
- 						return ERROR_OK;
-+					/* fallthru */
- 
- 				default:
- 					break;
-diff --git a/src/flash/nand/mx3.c b/src/flash/nand/mx3.c
-index b61e47535..0a55929ed 100644
---- a/src/flash/nand/mx3.c
-+++ b/src/flash/nand/mx3.c
-@@ -281,6 +281,7 @@ static int imx31_command(struct nand_device *nand, uint8_t command)
- 			 * offset == one half of page size
- 			 */
- 			in_sram_address = MX3_NF_MAIN_BUFFER0 + (nand->page_size >> 1);
-+			/* fallthru */
- 		default:
- 			in_sram_address = MX3_NF_MAIN_BUFFER0;
- 	}
-diff --git a/src/jtag/drivers/ftdi.c b/src/jtag/drivers/ftdi.c
-index 00fe37faf..20f17d810 100644
---- a/src/jtag/drivers/ftdi.c
-+++ b/src/jtag/drivers/ftdi.c
-@@ -855,6 +855,7 @@ COMMAND_HANDLER(ftdi_handle_set_signal_command)
- 			ftdi_set_signal(sig, *CMD_ARGV[1]);
- 			break;
- 		}
-+		/* fallthru */
- 	default:
- 		LOG_ERROR("unknown signal level '%s', use 0, 1 or z", CMD_ARGV[1]);
- 		return ERROR_COMMAND_SYNTAX_ERROR;
-diff --git a/src/svf/svf.c b/src/svf/svf.c
-index e7e815c10..7b261cc72 100644
---- a/src/svf/svf.c
-+++ b/src/svf/svf.c
-@@ -661,11 +661,13 @@ static int svf_read_command_from_file(FILE *fd)
- 				if (svf_getline(&svf_read_line, &svf_read_line_size, svf_fd) <= 0)
- 					return ERROR_FAIL;
- 				i = -1;
-+				/* fallthru */
- 			case '\r':
- 				slash = 0;
- 				/* Don't save '\r' and '\n' if no data is parsed */
- 				if (!cmd_pos)
- 					break;
-+				/* fallthru */
- 			default:
- 				/* The parsing code currently expects a space
- 				 * before parentheses -- "TDI (123)".  Also a
-diff --git a/src/target/arm_adi_v5.c b/src/target/arm_adi_v5.c
-index eafc2ddc0..d444db2b1 100644
---- a/src/target/arm_adi_v5.c
-+++ b/src/target/arm_adi_v5.c
-@@ -346,10 +346,13 @@ static int mem_ap_write(struct adiv5_ap *ap, const uint8_t *buffer, uint32_t siz
- 			case 4:
- 				outvalue |= (uint32_t)*buffer++ << 8 * (address++ & 3);
- 				outvalue |= (uint32_t)*buffer++ << 8 * (address++ & 3);
-+				/* fallthru */
- 			case 2:
- 				outvalue |= (uint32_t)*buffer++ << 8 * (address++ & 3);
-+				/* fallthru */
- 			case 1:
- 				outvalue |= (uint32_t)*buffer++ << 8 * (address++ & 3);
-+				/* fallthru */
- 			}
- 		}
- 
-@@ -509,20 +512,26 @@ static int mem_ap_read(struct adiv5_ap *ap, uint8_t *buffer, uint32_t size, uint
- 			case 4:
- 				*buffer++ = *read_ptr >> 8 * (3 - (address++ & 3));
- 				*buffer++ = *read_ptr >> 8 * (3 - (address++ & 3));
-+				/* fallthru */
- 			case 2:
- 				*buffer++ = *read_ptr >> 8 * (3 - (address++ & 3));
-+				/* fallthru */
- 			case 1:
- 				*buffer++ = *read_ptr >> 8 * (3 - (address++ & 3));
-+				/* fallthru */
- 			}
- 		} else {
- 			switch (this_size) {
- 			case 4:
- 				*buffer++ = *read_ptr >> 8 * (address++ & 3);
- 				*buffer++ = *read_ptr >> 8 * (address++ & 3);
-+				/* fallthru */
- 			case 2:
- 				*buffer++ = *read_ptr >> 8 * (address++ & 3);
-+				/* fallthru */
- 			case 1:
- 				*buffer++ = *read_ptr >> 8 * (address++ & 3);
-+				/* fallthru */
- 			}
- 		}
- 
-diff --git a/src/target/arm_disassembler.c b/src/target/arm_disassembler.c
-index 5277b94d8..2eb21ea33 100644
---- a/src/target/arm_disassembler.c
-+++ b/src/target/arm_disassembler.c
-@@ -3299,6 +3299,7 @@ static int t2ev_data_immed(uint32_t opcode, uint32_t address,
- 		case 0x10:
- 		case 0x12:
- 			is_signed = true;
-+			/* fallthru */
- 		case 0x18:
- 		case 0x1a:
- 			/* signed/unsigned saturated add */
-diff --git a/src/target/target.c b/src/target/target.c
-index e04ecc470..597b4b13d 100644
---- a/src/target/target.c
-+++ b/src/target/target.c
-@@ -3684,6 +3684,7 @@ COMMAND_HANDLER(handle_bp_command)
- 				addr = 0;
- 				return handle_bp_command_set(CMD_CTX, addr, asid, length, hw);
- 			}
-+			/* fallthru */
- 
- 		case 4:
- 			hw = BKPT_HARD;
--- 
-2.13.1
-
diff --git a/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0001-Fix-libusb-1.0.22-deprecated-libusb_set_debug-with-l.patch b/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0001-Fix-libusb-1.0.22-deprecated-libusb_set_debug-with-l.patch
new file mode 100644
index 0000000..c5b9083
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0001-Fix-libusb-1.0.22-deprecated-libusb_set_debug-with-l.patch
@@ -0,0 +1,39 @@
+From b95a996bfb281104b68ec66f32ebb79db519a4a8 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 31 May 2018 21:06:46 -0700
+Subject: [PATCH] Fix libusb-1.0.22 deprecated libusb_set_debug with
+ libusb_set_option
+
+libusb_set_debug is deprecated in libusb >= 1.0.22 therefore replace
+with equivalent libusb_set_option()  API
+
+see libusb commit for more details
+
+https://github.com/libusb/libusb/commit/539f22e2fd916558d11ab9a66f10f461c5593168
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Submitted [http://openocd.zylin.com/#/c/4540/]
+ src/jtag/drivers/xds110.c | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git a/src/jtag/drivers/xds110.c b/src/jtag/drivers/xds110.c
+index 90b699027..9bfe02ea8 100644
+--- a/src/jtag/drivers/xds110.c
++++ b/src/jtag/drivers/xds110.c
+@@ -367,8 +367,11 @@ static bool usb_connect(void)
+ 
+ 		/* Set libusb to auto detach kernel and disable debug messages */
+ 		(void)libusb_set_auto_detach_kernel_driver(dev, 1);
++#if LIBUSB_API_VERSION >= 0x01000106
++		libusb_set_option(ctx, LIBUSB_OPTION_LOG_LEVEL, LIBUSB_LOG_LEVEL_NONE);
++#else
+ 		libusb_set_debug(ctx, LIBUSB_LOG_LEVEL_NONE);
+-
++#endif
+ 		/* Claim the debug interface on the XDS110 */
+ 		result = libusb_claim_interface(dev, INTERFACE_DEBUG);
+ 	} else {
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0002-Workaround-new-warnings-generated-by-GCC-7.patch b/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0002-Workaround-new-warnings-generated-by-GCC-7.patch
deleted file mode 100644
index aa99735..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0002-Workaround-new-warnings-generated-by-GCC-7.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-From 8daaa8c27794653d02854c5982669a7638473224 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 16 Jun 2017 23:52:46 -0700
-Subject: [PATCH 2/5] Workaround new warnings generated by GCC 7
-
-src/flash/nor/xmc4xxx.c: In function 'xmc4xxx_get_info_command':
-src/flash/nor/xmc4xxx.c:939:43: error: '%d' directive output may be truncated writing between 1 and 10 bytes into a region of size 6 [-Werror=format-truncation=]
-     snprintf(otp_str, sizeof(otp_str), "- %d\n", i);
-                                           ^~
-src/flash/nor/xmc4xxx.c:939:40: note: directive argument in the range [0, 2147483647]
-     snprintf(otp_str, sizeof(otp_str), "- %d\n", i);
-                                        ^~~~~~~~
-src/flash/nor/xmc4xxx.c:939:5: note: 'snprintf' output between 5 and 14 bytes into a destination of size 8
-     snprintf(otp_str, sizeof(otp_str), "- %d\n", i);
-     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/flash/nor/xmc4xxx.c | 2 +-
- src/target/arm_adi_v5.c | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/flash/nor/xmc4xxx.c b/src/flash/nor/xmc4xxx.c
-index 02df46a3f..e6c398ff9 100644
---- a/src/flash/nor/xmc4xxx.c
-+++ b/src/flash/nor/xmc4xxx.c
-@@ -931,7 +931,7 @@ static int xmc4xxx_get_info_command(struct flash_bank *bank, char *buf, int buf_
- 
- 	/* If OTP Write protection is enabled (User 2), list each
- 	 * sector that has it enabled */
--	char otp_str[8];
-+	char otp_str[14];
- 	if (otp_enabled) {
- 		strcat(prot_str, "\nOTP Protection is enabled for sectors:\n");
- 		for (int i = 0; i < bank->num_sectors; i++) {
-diff --git a/src/target/arm_adi_v5.c b/src/target/arm_adi_v5.c
-index d444db2b1..d0d95121f 100644
---- a/src/target/arm_adi_v5.c
-+++ b/src/target/arm_adi_v5.c
-@@ -1062,7 +1062,7 @@ static int dap_rom_display(struct command_context *cmd_ctx,
- 	int retval;
- 	uint64_t pid;
- 	uint32_t cid;
--	char tabs[7] = "";
-+	char tabs[16] = "";
- 
- 	if (depth > 16) {
- 		command_print(cmd_ctx, "\tTables too deep");
--- 
-2.13.1
-
diff --git a/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0003-armv7a-Add-missing-break-to-fix-fallthrough-warning.patch b/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0003-armv7a-Add-missing-break-to-fix-fallthrough-warning.patch
deleted file mode 100644
index bcfbfc9..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0003-armv7a-Add-missing-break-to-fix-fallthrough-warning.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 8e5051e83fedb078170565a24d1f5de6c2ce4428 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 17 Jun 2017 00:01:51 -0700
-Subject: [PATCH 3/5] armv7a: Add missing break to fix fallthrough warning
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/target/armv7a.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/src/target/armv7a.c b/src/target/armv7a.c
-index 6021def4e..bad806b3d 100644
---- a/src/target/armv7a.c
-+++ b/src/target/armv7a.c
-@@ -355,6 +355,7 @@ int armv7a_mmu_translate_va_pa(struct target *target, uint32_t va,
- 				break;
- 			case 7:
- 				LOG_INFO("inner: Write-Back, no Write-Allocate");
-+				break;
- 
- 			default:
- 				LOG_INFO("inner: %" PRIx32 " ???", INNER);
--- 
-2.13.1
-
diff --git a/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0004-Fix-overflow-warning.patch b/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0004-Fix-overflow-warning.patch
deleted file mode 100644
index bfc5627..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0004-Fix-overflow-warning.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From d3ca56370a2be7e737d48bd14d474d790a0ab8ac Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 17 Jun 2017 00:04:00 -0700
-Subject: [PATCH 4/5] Fix overflow warning
-
-Remove an empty space which makes it fit into 11 byte string
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/target/nds32_cmd.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/target/nds32_cmd.c b/src/target/nds32_cmd.c
-index edb4872e4..73355073c 100644
---- a/src/target/nds32_cmd.c
-+++ b/src/target/nds32_cmd.c
-@@ -821,7 +821,7 @@ static int jim_nds32_bulk_read(Jim_Interp *interp, int argc, Jim_Obj * const *ar
- 	jim_wide i;
- 	Jim_SetResult(interp, Jim_NewEmptyStringObj(interp));
- 	for (i = 0; i < count; i++) {
--		sprintf(data_str, "0x%08" PRIx32 " ", data[i]);
-+		sprintf(data_str, "0x%08" PRIx32 "", data[i]);
- 		Jim_AppendStrings(interp, Jim_GetResult(interp), data_str, NULL);
- 	}
- 
--- 
-2.13.1
-
diff --git a/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0005-command-Move-the-fall-through-comment-to-right-scope.patch b/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0005-command-Move-the-fall-through-comment-to-right-scope.patch
deleted file mode 100644
index 60f75da..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd/0005-command-Move-the-fall-through-comment-to-right-scope.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 29dbf92ffdbdda29662b4190a2f8eb09caad8b51 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 17 Jun 2017 00:06:32 -0700
-Subject: [PATCH 5/5] command: Move the fall through comment to right scope
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/helper/command.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/helper/command.c b/src/helper/command.c
-index 5deaee859..287c14857 100644
---- a/src/helper/command.c
-+++ b/src/helper/command.c
-@@ -1456,8 +1456,8 @@ COMMAND_HELPER(handle_command_parse_bool, bool *out, const char *label)
- 				LOG_ERROR("%s: argument '%s' is not valid", CMD_NAME, in);
- 				return ERROR_COMMAND_SYNTAX_ERROR;
- 			}
--			/* fall through */
- 		}
-+		/* fall through */
- 		case 0:
- 			LOG_INFO("%s is %s", label, *out ? "enabled" : "disabled");
- 			break;
--- 
-2.13.1
-
diff --git a/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd_git.bb b/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd_git.bb
index 1a15e53..21a86de 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd_git.bb
+++ b/meta-openembedded/meta-oe/recipes-devtools/openocd/openocd_git.bb
@@ -9,17 +9,14 @@
     git://repo.or.cz/r/git2cl.git;protocol=http;destsuffix=tools/git2cl;name=git2cl \
     git://repo.or.cz/r/jimtcl.git;protocol=http;destsuffix=git/jimtcl;name=jimtcl \
     git://repo.or.cz/r/libjaylink.git;protocol=http;destsuffix=git/src/jtag/drivers/libjaylink;name=libjaylink \
-    file://0001-Add-fallthrough-comments.patch \
-    file://0002-Workaround-new-warnings-generated-by-GCC-7.patch \
-    file://0003-armv7a-Add-missing-break-to-fix-fallthrough-warning.patch \
-    file://0004-Fix-overflow-warning.patch \
-    file://0005-command-Move-the-fall-through-comment-to-right-scope.patch \
+    file://0001-Fix-libusb-1.0.22-deprecated-libusb_set_debug-with-l.patch \
 "
+
 SRCREV_FORMAT = "openocd"
-SRCREV_openocd = "1025be363e2bf42f1613083223a2322cc3a9bd4c"
+SRCREV_openocd = "cdf1e826eb23c29de1019ce64125f644f01b0afe"
 SRCREV_git2cl = "8373c9f74993e218a08819cbcdbab3f3564bbeba"
 SRCREV_jimtcl = "a9bf5975fd0f89974d689a2d9ebd0873c8d64787"
-SRCREV_libjaylink = "699b7001d34a79c8e7064503dde1bede786fd7f0"
+SRCREV_libjaylink = "8645845c1abebd004e991ba9a7f808f4fd0c608b"
 
 PV = "0.10+gitr${SRCPV}"
 S = "${WORKDIR}/git"
diff --git a/poky/meta/recipes-devtools/pax-utils/pax-utils_1.2.2.bb b/meta-openembedded/meta-oe/recipes-devtools/pax-utils/pax-utils_1.2.2.bb
similarity index 100%
rename from poky/meta/recipes-devtools/pax-utils/pax-utils_1.2.2.bb
rename to meta-openembedded/meta-oe/recipes-devtools/pax-utils/pax-utils_1.2.2.bb
diff --git a/meta-openembedded/meta-oe/recipes-devtools/perl/ipc-run_0.96.bb b/meta-openembedded/meta-oe/recipes-devtools/perl/ipc-run_0.96.bb
deleted file mode 100644
index 08c966d..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/perl/ipc-run_0.96.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-DESCRIPTION = "\
-IPC::Run allows you run and interact with child processes \
-using files, pipes, and pseudo-ttys. Both system()-style and scripted \
-usages are supported and may be mixed. Likewise, functional and OO API \
-styles are both supported and may be mixed."
-HOMEPAGE = "https://metacpan.org/release/IPC-Run"
-SECTION = "libs"
-LICENSE = "Artistic-1.0 | GPL-1.0+"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=0ebd37caf53781e8b7223e6b99b63f4e"
-DEPENDS = "perl"
-
-SRC_URI = "git://github.com/toddr/IPC-Run.git"
-SRCREV = "96066366ac8c401dff9c979d04f25dc8219ffcc1"
-
-S = "${WORKDIR}/git"
-
-inherit cpan
-
-EXTRA_CPANFLAGS = "EXPATLIBPATH=${STAGING_LIBDIR} EXPATINCPATH=${STAGING_INCDIR}"
-
-do_compile() {
-    export LIBC="$(find ${STAGING_DIR_TARGET}/${base_libdir}/ -name 'libc-*.so')"
-    cpan_do_compile
-}
diff --git a/meta-openembedded/meta-oe/recipes-devtools/perl/ipc-run_20180523.0.bb b/meta-openembedded/meta-oe/recipes-devtools/perl/ipc-run_20180523.0.bb
new file mode 100644
index 0000000..c812ae1
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/perl/ipc-run_20180523.0.bb
@@ -0,0 +1,24 @@
+DESCRIPTION = "\
+IPC::Run allows you run and interact with child processes \
+using files, pipes, and pseudo-ttys. Both system()-style and scripted \
+usages are supported and may be mixed. Likewise, functional and OO API \
+styles are both supported and may be mixed."
+HOMEPAGE = "https://metacpan.org/release/IPC-Run"
+SECTION = "libs"
+LICENSE = "Artistic-1.0 | GPL-1.0+"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=0ebd37caf53781e8b7223e6b99b63f4e"
+DEPENDS = "perl"
+
+SRC_URI = "git://github.com/toddr/IPC-Run.git"
+SRCREV = "0b409702490729eeb97ae65f5b94d949ec083134"
+
+S = "${WORKDIR}/git"
+
+inherit cpan
+
+EXTRA_CPANFLAGS = "EXPATLIBPATH=${STAGING_LIBDIR} EXPATINCPATH=${STAGING_INCDIR}"
+
+do_compile() {
+    export LIBC="$(find ${STAGING_DIR_TARGET}/${base_libdir}/ -name 'libc-*.so')"
+    cpan_do_compile
+}
diff --git a/meta-openembedded/meta-oe/recipes-devtools/php/php.inc b/meta-openembedded/meta-oe/recipes-devtools/php/php.inc
index 066b97c..bfd0ddf 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/php/php.inc
+++ b/meta-openembedded/meta-oe/recipes-devtools/php/php.inc
@@ -5,8 +5,7 @@
 LICENSE = "PHP-3.0"
 
 BBCLASSEXTEND = "native"
-DEPENDS = "zlib bzip2 libxml2 virtual/libiconv php-native lemon-native \
-           openssl"
+DEPENDS = "zlib bzip2 libxml2 virtual/libiconv php-native lemon-native"
 DEPENDS_class-native = "zlib-native libxml2-native"
 
 PHP_MAJOR_VERSION = "${@d.getVar('PV', True).split('.')[0]}"
@@ -59,7 +58,7 @@
                 ${COMMON_EXTRA_OECONF} \
 "
 
-CACHED_CONFIGUREVARS += "ac_cv_func_dlopen=yes ac_cv_lib_dl_dlopen=yes"
+CACHED_CONFIGUREVARS += "ac_cv_func_dlopen=no ac_cv_lib_dl_dlopen=yes"
 
 EXTRA_OECONF_class-native = " \
                 --with-zlib=${STAGING_LIBDIR_NATIVE}/.. \
@@ -67,7 +66,7 @@
                 ${COMMON_EXTRA_OECONF} \
 "
 
-PACKAGECONFIG ??= "mysql sqlite3 imap opcache \
+PACKAGECONFIG ??= "mysql sqlite3 imap opcache openssl \
                    ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6 pam', d)} \
 "
 PACKAGECONFIG_class-native = ""
@@ -80,7 +79,7 @@
 
 PACKAGECONFIG[sqlite3] = "--with-sqlite3=${STAGING_LIBDIR}/.. \
                           --with-pdo-sqlite=${STAGING_LIBDIR}/.. \
-                          , \
+                          ,--without-sqlite3 --without-pdo-sqlite \
                           ,sqlite3"
 PACKAGECONFIG[pgsql] = "--with-pgsql=${STAGING_DIR_TARGET}${exec_prefix},--without-pgsql,postgresql"
 PACKAGECONFIG[soap] = "--enable-libxml --enable-soap, --disable-soap, libxml2"
@@ -91,7 +90,8 @@
                        ,--without-imap --without-imap-ssl \
                        ,uw-imap"
 PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
-PACKAGECONFIG[opcache] = ",--disable-opcache"
+PACKAGECONFIG[opcache] = "--enable-opcache,--disable-opcache"
+PACKAGECONFIG[openssl] = "--with-openssl,--without-openssl,openssl"
 
 export PHP_NATIVE_DIR = "${STAGING_BINDIR_NATIVE}"
 export PHP_PEAR_PHP_BIN = "${STAGING_BINDIR_NATIVE}/php"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/php/php/0001-PHP-5.6-LibSSL-1.1-compatibility.patch b/meta-openembedded/meta-oe/recipes-devtools/php/php/0001-PHP-5.6-LibSSL-1.1-compatibility.patch
new file mode 100644
index 0000000..ac8365b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/php/php/0001-PHP-5.6-LibSSL-1.1-compatibility.patch
@@ -0,0 +1,1285 @@
+Subject: [PATCH] PHP 5.6 - LibSSL 1.1 compatibility
+
+This patch does not try to backport the 7.1 openssl module, it is the
+improved version of the 5.6 original openssl module.
+
+https://github.com/oerdnj/deb.sury.org/issues/566
+http://zettasystem.com/PHP-5.6.31-OpenSSL-1.1.0-compatibility-20170801.patch
+
+Upstream-Status: Deny [https://github.com/php/php-src/pull/2667]
+Reason: As PHP 5.6 is no longer actively supported only security fixes
+may land on this branch. As this change does not fall in this category,
+I'm closing this PR. (All higher versions of PHP already have OpenSSL
+1.1 support.)
+
+Author: zsalab@github https://github.com/zsalab
+
+Only port source modification, do not include the test case
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ ext/openssl/openssl.c | 683 +++++++++++++++++++++++++++++++++++++-------------
+ ext/openssl/xp_ssl.c  |  18 +-
+ ext/phar/util.c       |  13 +-
+ 3 files changed, 527 insertions(+), 187 deletions(-)
+
+diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c
+index a78a8fb..b53114c 100644
+--- a/ext/openssl/openssl.c
++++ b/ext/openssl/openssl.c
+@@ -42,6 +42,12 @@
+ 
+ /* OpenSSL includes */
+ #include <openssl/evp.h>
++#if OPENSSL_VERSION_NUMBER >= 0x10002000L
++#include <openssl/bn.h>
++#include <openssl/rsa.h>
++#include <openssl/dsa.h>
++#include <openssl/dh.h>
++#endif
+ #include <openssl/x509.h>
+ #include <openssl/x509v3.h>
+ #include <openssl/crypto.h>
+@@ -531,6 +537,133 @@ zend_module_entry openssl_module_entry = {
+ ZEND_GET_MODULE(openssl)
+ #endif
+ 
++/* {{{ OpenSSL compatibility functions and macros */
++#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined (LIBRESSL_VERSION_NUMBER)
++#define EVP_PKEY_get0_RSA(_pkey) _pkey->pkey.rsa
++#define EVP_PKEY_get0_DH(_pkey) _pkey->pkey.dh
++#define EVP_PKEY_get0_DSA(_pkey) _pkey->pkey.dsa
++#define EVP_PKEY_get0_EC_KEY(_pkey) _pkey->pkey.ec
++
++static int RSA_set0_key(RSA *r, BIGNUM *n, BIGNUM *e, BIGNUM *d)
++{
++	r->n = n;
++	r->e = e;
++	r->d = d;
++
++	return 1;
++}
++
++static int RSA_set0_factors(RSA *r, BIGNUM *p, BIGNUM *q)
++{
++	r->p = p;
++	r->q = q;
++
++	return 1;
++}
++
++static int RSA_set0_crt_params(RSA *r, BIGNUM *dmp1, BIGNUM *dmq1, BIGNUM *iqmp)
++{
++	r->dmp1 = dmp1;
++	r->dmq1 = dmq1;
++	r->iqmp = iqmp;
++
++	return 1;
++}
++
++static void RSA_get0_key(const RSA *r, const BIGNUM **n, const BIGNUM **e, const BIGNUM **d)
++{
++	*n = r->n;
++	*e = r->e;
++	*d = r->d;
++}
++
++static void RSA_get0_factors(const RSA *r, const BIGNUM **p, const BIGNUM **q)
++{
++	*p = r->p;
++	*q = r->q;
++}
++
++static void RSA_get0_crt_params(const RSA *r, const BIGNUM **dmp1, const BIGNUM **dmq1, const BIGNUM **iqmp)
++{
++	*dmp1 = r->dmp1;
++	*dmq1 = r->dmq1;
++	*iqmp = r->iqmp;
++}
++
++static void DH_get0_pqg(const DH *dh, const BIGNUM **p, const BIGNUM **q, const BIGNUM **g)
++{
++	*p = dh->p;
++	*q = dh->q;
++	*g = dh->g;
++}
++
++static int DH_set0_pqg(DH *dh, BIGNUM *p, BIGNUM *q, BIGNUM *g)
++{
++	dh->p = p;
++	dh->q = q;
++	dh->g = g;
++
++	return 1;
++}
++
++static void DH_get0_key(const DH *dh, const BIGNUM **pub_key, const BIGNUM **priv_key)
++{
++	*pub_key = dh->pub_key;
++	*priv_key = dh->priv_key;
++}
++
++static int DH_set0_key(DH *dh, BIGNUM *pub_key, BIGNUM *priv_key)
++{
++	dh->pub_key = pub_key;
++	dh->priv_key = priv_key;
++
++	return 1;
++}
++
++static void DSA_get0_pqg(const DSA *d, const BIGNUM **p, const BIGNUM **q, const BIGNUM **g)
++{
++	*p = d->p;
++	*q = d->q;
++	*g = d->g;
++}
++
++int DSA_set0_pqg(DSA *d, BIGNUM *p, BIGNUM *q, BIGNUM *g)
++{
++	d->p = p;
++	d->q = q;
++	d->g = g;
++
++	return 1;
++}
++
++static void DSA_get0_key(const DSA *d, const BIGNUM **pub_key, const BIGNUM **priv_key)
++{
++	*pub_key = d->pub_key;
++	*priv_key = d->priv_key;
++}
++
++int DSA_set0_key(DSA *d, BIGNUM *pub_key, BIGNUM *priv_key)
++{
++	d->pub_key = pub_key;
++	d->priv_key = priv_key;
++
++	return 1;
++}
++
++#if OPENSSL_VERSION_NUMBER < 0x10002000L || defined (LIBRESSL_VERSION_NUMBER)
++#define EVP_PKEY_id(_pkey) _pkey->type
++#define EVP_PKEY_base_id(_key) EVP_PKEY_type(_key->type)
++
++static int X509_get_signature_nid(const X509 *x)
++{
++	return OBJ_obj2nid(x->sig_alg->algorithm);
++}
++
++#endif
++
++#endif
++/* }}} */
++
+ static int le_key;
+ static int le_x509;
+ static int le_csr;
+@@ -825,7 +958,7 @@ static int add_oid_section(struct php_x509_request * req TSRMLS_DC) /* {{{ */
+ 	}
+ 	for (i = 0; i < sk_CONF_VALUE_num(sktmp); i++) {
+ 		cnf = sk_CONF_VALUE_value(sktmp, i);
+-		if (OBJ_create(cnf->value, cnf->name, cnf->name) == NID_undef) {
++		if (OBJ_sn2nid(cnf->name) == NID_undef && OBJ_ln2nid(cnf->name) == NID_undef && OBJ_create(cnf->value, cnf->name, cnf->name) == NID_undef) {
+ 			php_error_docref(NULL TSRMLS_CC, E_WARNING, "problem creating object %s=%s", cnf->name, cnf->value);
+ 			return FAILURE;
+ 		}
+@@ -967,7 +1100,7 @@ static void php_openssl_dispose_config(struct php_x509_request * req TSRMLS_DC)
+ }
+ /* }}} */
+ 
+-#ifdef PHP_WIN32
++#if defined(PHP_WIN32) || (OPENSSL_VERSION_NUMBER >= 0x10100000L && !defined(LIBRESSL_VERSION_NUMBER))
+ #define PHP_OPENSSL_RAND_ADD_TIME() ((void) 0)
+ #else
+ #define PHP_OPENSSL_RAND_ADD_TIME() php_openssl_rand_add_timeval()
+@@ -1053,9 +1186,11 @@ static EVP_MD * php_openssl_get_evp_md_from_algo(long algo) { /* {{{ */
+ 			mdtype = (EVP_MD *) EVP_md2();
+ 			break;
+ #endif
++#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined (LIBRESSL_VERSION_NUMBER)
+ 		case OPENSSL_ALGO_DSS1:
+ 			mdtype = (EVP_MD *) EVP_dss1();
+ 			break;
++#endif
+ #if OPENSSL_VERSION_NUMBER >= 0x0090708fL
+ 		case OPENSSL_ALGO_SHA224:
+ 			mdtype = (EVP_MD *) EVP_sha224();
+@@ -1146,6 +1281,12 @@ PHP_MINIT_FUNCTION(openssl)
+ 	OpenSSL_add_all_digests();
+ 	OpenSSL_add_all_algorithms();
+ 
++#if !defined(OPENSSL_NO_AES) && defined(EVP_CIPH_CCM_MODE) && OPENSSL_VERSION_NUMBER < 0x100020000
++	EVP_add_cipher(EVP_aes_128_ccm());
++	EVP_add_cipher(EVP_aes_192_ccm());
++	EVP_add_cipher(EVP_aes_256_ccm());
++#endif
++
+ 	SSL_load_error_strings();
+ 
+ 	/* register a resource id number with OpenSSL so that we can map SSL -> stream structures in
+@@ -1173,7 +1314,9 @@ PHP_MINIT_FUNCTION(openssl)
+ #ifdef HAVE_OPENSSL_MD2_H
+ 	REGISTER_LONG_CONSTANT("OPENSSL_ALGO_MD2", OPENSSL_ALGO_MD2, CONST_CS|CONST_PERSISTENT);
+ #endif
++#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined (LIBRESSL_VERSION_NUMBER)
+ 	REGISTER_LONG_CONSTANT("OPENSSL_ALGO_DSS1", OPENSSL_ALGO_DSS1, CONST_CS|CONST_PERSISTENT);
++#endif
+ #if OPENSSL_VERSION_NUMBER >= 0x0090708fL
+ 	REGISTER_LONG_CONSTANT("OPENSSL_ALGO_SHA224", OPENSSL_ALGO_SHA224, CONST_CS|CONST_PERSISTENT);
+ 	REGISTER_LONG_CONSTANT("OPENSSL_ALGO_SHA256", OPENSSL_ALGO_SHA256, CONST_CS|CONST_PERSISTENT);
+@@ -1251,7 +1394,9 @@ PHP_MINIT_FUNCTION(openssl)
+ 	}
+ 
+ 	php_stream_xport_register("ssl", php_openssl_ssl_socket_factory TSRMLS_CC);
++#ifndef OPENSSL_NO_SSL3
+ 	php_stream_xport_register("sslv3", php_openssl_ssl_socket_factory TSRMLS_CC);
++#endif
+ #ifndef OPENSSL_NO_SSL2
+ 	php_stream_xport_register("sslv2", php_openssl_ssl_socket_factory TSRMLS_CC);
+ #endif
+@@ -1308,7 +1453,9 @@ PHP_MSHUTDOWN_FUNCTION(openssl)
+ #ifndef OPENSSL_NO_SSL2
+ 	php_stream_xport_unregister("sslv2" TSRMLS_CC);
+ #endif
++#ifndef OPENSSL_NO_SSL3
+ 	php_stream_xport_unregister("sslv3" TSRMLS_CC);
++#endif
+ 	php_stream_xport_unregister("tls" TSRMLS_CC);
+ 	php_stream_xport_unregister("tlsv1.0" TSRMLS_CC);
+ #if OPENSSL_VERSION_NUMBER >= 0x10001001L
+@@ -1893,6 +2040,7 @@ static int openssl_x509v3_subjectAltName(BIO *bio, X509_EXTENSION *extension)
+ {
+ 	GENERAL_NAMES *names;
+ 	const X509V3_EXT_METHOD *method = NULL;
++	ASN1_OCTET_STRING *extension_data;
+ 	long i, length, num;
+ 	const unsigned char *p;
+ 
+@@ -1901,8 +2049,9 @@ static int openssl_x509v3_subjectAltName(BIO *bio, X509_EXTENSION *extension)
+ 		return -1;
+ 	}
+ 
+-	p = extension->value->data;
+-	length = extension->value->length;
++	extension_data = X509_EXTENSION_get_data(extension);
++	p = extension_data->data;
++	length = extension_data->length;
+ 	if (method->it) {
+ 		names = (GENERAL_NAMES*)(ASN1_item_d2i(NULL, &p, length,
+ 						       ASN1_ITEM_ptr(method->it)));
+@@ -1965,6 +2114,8 @@ PHP_FUNCTION(openssl_x509_parse)
+ 	char * tmpstr;
+ 	zval * subitem;
+ 	X509_EXTENSION *extension;
++	X509_NAME *subject_name;
++	char *cert_name;
+ 	char *extname;
+ 	BIO  *bio_out;
+ 	BUF_MEM *bio_buf;
+@@ -1979,10 +2130,10 @@ PHP_FUNCTION(openssl_x509_parse)
+ 	}
+ 	array_init(return_value);
+ 
+-	if (cert->name) {
+-		add_assoc_string(return_value, "name", cert->name, 1);
+-	}
+-/*	add_assoc_bool(return_value, "valid", cert->valid); */
++	subject_name = X509_get_subject_name(cert);
++	cert_name = X509_NAME_oneline(subject_name, NULL, 0);
++	add_assoc_string(return_value, "name", cert_name, 1);
++	OPENSSL_free(cert_name);
+ 
+ 	add_assoc_name_entry(return_value, "subject", 		X509_get_subject_name(cert), useshortnames TSRMLS_CC);
+ 	/* hash as used in CA directories to lookup cert by subject name */
+@@ -2008,7 +2159,7 @@ PHP_FUNCTION(openssl_x509_parse)
+ 		add_assoc_string(return_value, "alias", tmpstr, 1);
+ 	}
+ 
+-	sig_nid = OBJ_obj2nid((cert)->sig_alg->algorithm);
++	sig_nid = X509_get_signature_nid(cert);
+ 	add_assoc_string(return_value, "signatureTypeSN", (char*)OBJ_nid2sn(sig_nid), 1);
+ 	add_assoc_string(return_value, "signatureTypeLN", (char*)OBJ_nid2ln(sig_nid), 1);
+ 	add_assoc_long(return_value, "signatureTypeNID", sig_nid);
+@@ -3217,7 +3368,21 @@ PHP_FUNCTION(openssl_csr_get_public_key)
+ 		RETURN_FALSE;
+ 	}
+ 
+-	tpubkey=X509_REQ_get_pubkey(csr);
++#if OPENSSL_VERSION_NUMBER >= 0x10100000L && !defined(LIBRESSL_VERSION_NUMBER)
++	/* Due to changes in OpenSSL 1.1 related to locking when decoding CSR,
++	 * the pub key is not changed after assigning. It means if we pass
++	 * a private key, it will be returned including the private part.
++	 * If we duplicate it, then we get just the public part which is
++	 * the same behavior as for OpenSSL 1.0 */
++	csr = X509_REQ_dup(csr);
++#endif
++	/* Retrieve the public key from the CSR */
++	tpubkey = X509_REQ_get_pubkey(csr);
++
++#if OPENSSL_VERSION_NUMBER >= 0x10100000L && !defined(LIBRESSL_VERSION_NUMBER)
++	/* We need to free the CSR as it was duplicated */
++	X509_REQ_free(csr);
++#endif
+ 	RETVAL_RESOURCE(zend_list_insert(tpubkey, le_key TSRMLS_CC));
+ 	return;
+ }
+@@ -3482,13 +3647,20 @@ static int php_openssl_is_private_key(EVP_PKEY* pkey TSRMLS_DC)
+ {
+ 	assert(pkey != NULL);
+ 
+-	switch (pkey->type) {
++	switch (EVP_PKEY_id(pkey)) {
+ #ifndef NO_RSA
+ 		case EVP_PKEY_RSA:
+ 		case EVP_PKEY_RSA2:
+-			assert(pkey->pkey.rsa != NULL);
+-			if (pkey->pkey.rsa != NULL && (NULL == pkey->pkey.rsa->p || NULL == pkey->pkey.rsa->q)) {
+-				return 0;
++			{
++				RSA *rsa = EVP_PKEY_get0_RSA(pkey);
++				if (rsa != NULL) {
++					const BIGNUM *p, *q;
++
++					RSA_get0_factors(rsa, &p, &q);
++					 if (p == NULL || q == NULL) {
++						return 0;
++					 }
++				}
+ 			}
+ 			break;
+ #endif
+@@ -3498,28 +3670,51 @@ static int php_openssl_is_private_key(EVP_PKEY* pkey TSRMLS_DC)
+ 		case EVP_PKEY_DSA2:
+ 		case EVP_PKEY_DSA3:
+ 		case EVP_PKEY_DSA4:
+-			assert(pkey->pkey.dsa != NULL);
+-
+-			if (NULL == pkey->pkey.dsa->p || NULL == pkey->pkey.dsa->q || NULL == pkey->pkey.dsa->priv_key){ 
+-				return 0;
++			{
++				DSA *dsa = EVP_PKEY_get0_DSA(pkey);
++				if (dsa != NULL) {
++					const BIGNUM *p, *q, *g, *pub_key, *priv_key;
++
++					DSA_get0_pqg(dsa, &p, &q, &g);
++					if (p == NULL || q == NULL) {
++						return 0;
++					}
++ 
++					DSA_get0_key(dsa, &pub_key, &priv_key);
++					if (priv_key == NULL) {
++						return 0;
++					}
++				}
+ 			}
+ 			break;
+ #endif
+ #ifndef NO_DH
+ 		case EVP_PKEY_DH:
+-			assert(pkey->pkey.dh != NULL);
+-
+-			if (NULL == pkey->pkey.dh->p || NULL == pkey->pkey.dh->priv_key) {
+-				return 0;
++			{
++				DH *dh = EVP_PKEY_get0_DH(pkey);
++				if (dh != NULL) {
++					const BIGNUM *p, *q, *g, *pub_key, *priv_key;
++
++					DH_get0_pqg(dh, &p, &q, &g);
++					if (p == NULL) {
++						return 0;
++					}
++ 
++					DH_get0_key(dh, &pub_key, &priv_key);
++					if (priv_key == NULL) {
++						return 0;
++					}
++				}
+ 			}
+ 			break;
+ #endif
+ #ifdef HAVE_EVP_PKEY_EC
+ 		case EVP_PKEY_EC:
+-			assert(pkey->pkey.ec != NULL);
+-
+-			if ( NULL == EC_KEY_get0_private_key(pkey->pkey.ec)) {
+-				return 0;
++			{
++				EC_KEY *ec = EVP_PKEY_get0_EC_KEY(pkey);
++				if (ec != NULL && NULL == EC_KEY_get0_private_key(ec)) {
++					return 0;
++				}
+ 			}
+ 			break;
+ #endif
+@@ -3531,34 +3726,80 @@ static int php_openssl_is_private_key(EVP_PKEY* pkey TSRMLS_DC)
+ }
+ /* }}} */
+ 
+-#define OPENSSL_PKEY_GET_BN(_type, _name) do {							\
+-		if (pkey->pkey._type->_name != NULL) {							\
+-			int len = BN_num_bytes(pkey->pkey._type->_name);			\
+-			char *str = emalloc(len + 1);								\
+-			BN_bn2bin(pkey->pkey._type->_name, (unsigned char*)str);	\
+-			str[len] = 0;                                           	\
+-			add_assoc_stringl(_type, #_name, str, len, 0);				\
+-		}																\
+-	} while (0)
+-
+-#define OPENSSL_PKEY_SET_BN(_ht, _type, _name) do {						\
+-		zval **bn;														\
+-		if (zend_hash_find(_ht, #_name, sizeof(#_name),	(void**)&bn) == SUCCESS && \
+-				Z_TYPE_PP(bn) == IS_STRING) {							\
+-			_type->_name = BN_bin2bn(									\
+-				(unsigned char*)Z_STRVAL_PP(bn),						\
+-	 			Z_STRLEN_PP(bn), NULL);									\
+-	    }                                                               \
++#define OPENSSL_GET_BN(_array, _bn, _name) do { \
++		if (_bn != NULL) { \
++			int len = BN_num_bytes(_bn); \
++			char *str = emalloc(len + 1); \
++			BN_bn2bin(_bn, (unsigned char*)str); \
++			str[len] = 0; \
++			add_assoc_stringl(_array, #_name, str, len, 0); \
++		} \
+ 	} while (0);
+ 
++#define OPENSSL_PKEY_GET_BN(_type, _name) OPENSSL_GET_BN(_type, _name, _name)
++
++#define OPENSSL_PKEY_SET_BN(_data, _name) do { \
++		zval **bn; \
++		if (zend_hash_find(Z_ARRVAL_P(_data), #_name, sizeof(#_name),(void**)&bn) == SUCCESS && \
++				Z_TYPE_PP(bn) == IS_STRING) { \
++			_name = BN_bin2bn( \
++				(unsigned char*)Z_STRVAL_PP(bn), \
++				Z_STRLEN_PP(bn), NULL); \
++		} else { \
++			_name = NULL; \
++		} \
++ 	} while (0);
++
++/* {{{ php_openssl_pkey_init_rsa */
++zend_bool php_openssl_pkey_init_and_assign_rsa(EVP_PKEY *pkey, RSA *rsa, zval *data)
++{
++	BIGNUM *n, *e, *d, *p, *q, *dmp1, *dmq1, *iqmp;
++
++	OPENSSL_PKEY_SET_BN(data, n);
++	OPENSSL_PKEY_SET_BN(data, e);
++	OPENSSL_PKEY_SET_BN(data, d);
++	if (!n || !d || !RSA_set0_key(rsa, n, e, d)) {
++		return 0;
++	}
++
++	OPENSSL_PKEY_SET_BN(data, p);
++	OPENSSL_PKEY_SET_BN(data, q);
++	if ((p || q) && !RSA_set0_factors(rsa, p, q)) {
++		return 0;
++	}
++
++	OPENSSL_PKEY_SET_BN(data, dmp1);
++	OPENSSL_PKEY_SET_BN(data, dmq1);
++	OPENSSL_PKEY_SET_BN(data, iqmp);
++	if ((dmp1 || dmq1 || iqmp) && !RSA_set0_crt_params(rsa, dmp1, dmq1, iqmp)) {
++		return 0;
++	}
++
++	if (!EVP_PKEY_assign_RSA(pkey, rsa)) {
++		return 0;
++	}
++
++	return 1;
++}
++/* }}} */
++
+ /* {{{ php_openssl_pkey_init_dsa */
+-zend_bool php_openssl_pkey_init_dsa(DSA *dsa)
++zend_bool php_openssl_pkey_init_dsa(DSA *dsa, zval *data)
+ {
+-	if (!dsa->p || !dsa->q || !dsa->g) {
++	BIGNUM *p, *q, *g, *priv_key, *pub_key;
++	const BIGNUM *priv_key_const, *pub_key_const;
++
++	OPENSSL_PKEY_SET_BN(data, p);
++	OPENSSL_PKEY_SET_BN(data, q);
++	OPENSSL_PKEY_SET_BN(data, g);
++	if (!p || !q || !g || !DSA_set0_pqg(dsa, p, q, g)) {
+ 		return 0;
+ 	}
+-	if (dsa->priv_key || dsa->pub_key) {
+-		return 1;
++
++	OPENSSL_PKEY_SET_BN(data, pub_key);
++	OPENSSL_PKEY_SET_BN(data, priv_key);
++	if (pub_key) {
++		return DSA_set0_key(dsa, pub_key, priv_key);
+ 	}
+ 	PHP_OPENSSL_RAND_ADD_TIME();
+ 	if (!DSA_generate_key(dsa)) {
+@@ -3566,7 +3807,8 @@ zend_bool php_openssl_pkey_init_dsa(DSA *dsa)
+ 	}
+ 	/* if BN_mod_exp return -1, then DSA_generate_key succeed for failed key
+ 	 * so we need to double check that public key is created */
+-	if (!dsa->pub_key || BN_is_zero(dsa->pub_key)) {
++	DSA_get0_key(dsa, &pub_key_const, &priv_key_const);
++	if (!pub_key_const || BN_is_zero(pub_key_const)) {
+ 		return 0;
+ 	}
+ 	/* all good */
+@@ -3574,14 +3816,66 @@ zend_bool php_openssl_pkey_init_dsa(DSA *dsa)
+ }
+ /* }}} */
+ 
++/* {{{ php_openssl_dh_pub_from_priv */
++static BIGNUM *php_openssl_dh_pub_from_priv(BIGNUM *priv_key, BIGNUM *g, BIGNUM *p)
++{
++	BIGNUM *pub_key, *priv_key_const_time;
++	BN_CTX *ctx;
++
++	pub_key = BN_new();
++	if (pub_key == NULL) {
++		return NULL;
++	}
++
++	priv_key_const_time = BN_new();
++	if (priv_key_const_time == NULL) {
++		BN_free(pub_key);
++		return NULL;
++	}
++	ctx = BN_CTX_new();
++	if (ctx == NULL) {
++		BN_free(pub_key);
++		BN_free(priv_key_const_time);
++		return NULL;
++	}
++
++	BN_with_flags(priv_key_const_time, priv_key, BN_FLG_CONSTTIME);
++
++	if (!BN_mod_exp_mont(pub_key, g, priv_key_const_time, p, ctx, NULL)) {
++		BN_free(pub_key);
++		pub_key = NULL;
++	}
++
++	BN_free(priv_key_const_time);
++	BN_CTX_free(ctx);
++
++	return pub_key;
++}
++/* }}} */
++
+ /* {{{ php_openssl_pkey_init_dh */
+-zend_bool php_openssl_pkey_init_dh(DH *dh)
++zend_bool php_openssl_pkey_init_dh(DH *dh, zval *data)
+ {
+-	if (!dh->p || !dh->g) {
++	BIGNUM *p, *q, *g, *priv_key, *pub_key;
++
++	OPENSSL_PKEY_SET_BN(data, p);
++	OPENSSL_PKEY_SET_BN(data, q);
++	OPENSSL_PKEY_SET_BN(data, g);
++	if (!p || !g || !DH_set0_pqg(dh, p, q, g)) {
+ 		return 0;
+ 	}
+-	if (dh->pub_key) {
+-		return 1;
++
++	OPENSSL_PKEY_SET_BN(data, priv_key);
++	OPENSSL_PKEY_SET_BN(data, pub_key);
++	if (pub_key) {
++		return DH_set0_key(dh, pub_key, priv_key);
++	}
++	if (priv_key) {
++		pub_key = php_openssl_dh_pub_from_priv(priv_key, g, p);
++		if (pub_key == NULL) {
++			return 0;
++		}
++		return DH_set0_key(dh, pub_key, priv_key);
+ 	}
+ 	PHP_OPENSSL_RAND_ADD_TIME();
+ 	if (!DH_generate_key(dh)) {
+@@ -3614,18 +3908,8 @@ PHP_FUNCTION(openssl_pkey_new)
+ 		    if (pkey) {
+ 				RSA *rsa = RSA_new();
+ 				if (rsa) {
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), rsa, n);
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), rsa, e);
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), rsa, d);
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), rsa, p);
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), rsa, q);
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), rsa, dmp1);
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), rsa, dmq1);
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), rsa, iqmp);
+-					if (rsa->n && rsa->d) {
+-						if (EVP_PKEY_assign_RSA(pkey, rsa)) {
+-							RETURN_RESOURCE(zend_list_insert(pkey, le_key TSRMLS_CC));
+-						}
++					if (php_openssl_pkey_init_and_assign_rsa(pkey, rsa, *data)) {
++						RETURN_RESOURCE(zend_list_insert(pkey, le_key TSRMLS_CC));
+ 					}
+ 					RSA_free(rsa);
+ 				}
+@@ -3638,12 +3922,7 @@ PHP_FUNCTION(openssl_pkey_new)
+ 		    if (pkey) {
+ 				DSA *dsa = DSA_new();
+ 				if (dsa) {
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), dsa, p);
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), dsa, q);
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), dsa, g);
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), dsa, priv_key);
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), dsa, pub_key);
+-					if (php_openssl_pkey_init_dsa(dsa)) {
++					if (php_openssl_pkey_init_dsa(dsa, *data)) {
+ 						if (EVP_PKEY_assign_DSA(pkey, dsa)) {
+ 							RETURN_RESOURCE(zend_list_insert(pkey, le_key TSRMLS_CC));
+ 						}
+@@ -3659,11 +3938,7 @@ PHP_FUNCTION(openssl_pkey_new)
+ 		    if (pkey) {
+ 				DH *dh = DH_new();
+ 				if (dh) {
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), dh, p);
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), dh, g);
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), dh, priv_key);
+-					OPENSSL_PKEY_SET_BN(Z_ARRVAL_PP(data), dh, pub_key);
+-					if (php_openssl_pkey_init_dh(dh)) {
++					if (php_openssl_pkey_init_dh(dh, *data)) {
+ 						if (EVP_PKEY_assign_DH(pkey, dh)) {
+ 							RETURN_RESOURCE(zend_list_insert(pkey, le_key TSRMLS_CC));
+ 						}
+@@ -3738,10 +4013,10 @@ PHP_FUNCTION(openssl_pkey_export_to_file)
+ 			cipher = NULL;
+ 		}
+ 
+-		switch (EVP_PKEY_type(key->type)) {
++		switch (EVP_PKEY_base_id(key)) {
+ #ifdef HAVE_EVP_PKEY_EC
+ 			case EVP_PKEY_EC:
+-				pem_write = PEM_write_bio_ECPrivateKey(bio_out, EVP_PKEY_get1_EC_KEY(key), cipher, (unsigned char *)passphrase, passphrase_len, NULL, NULL);
++				pem_write = PEM_write_bio_ECPrivateKey(bio_out, EVP_PKEY_get0_EC_KEY(key), cipher, (unsigned char *)passphrase, passphrase_len, NULL, NULL);
+ 				break;
+ #endif
+ 			default:
+@@ -3807,7 +4082,7 @@ PHP_FUNCTION(openssl_pkey_export)
+ 			cipher = NULL;
+ 		}
+ 
+-		switch (EVP_PKEY_type(key->type)) {
++		switch (EVP_PKEY_base_id(key)) {
+ #ifdef HAVE_EVP_PKEY_EC
+ 			case EVP_PKEY_EC:
+ 				pem_write = PEM_write_bio_ECPrivateKey(bio_out, EVP_PKEY_get1_EC_KEY(key), cipher, (unsigned char *)passphrase, passphrase_len, NULL, NULL);
+@@ -3928,25 +4203,33 @@ PHP_FUNCTION(openssl_pkey_get_details)
+ 	/*TODO: Use the real values once the openssl constants are used 
+ 	 * See the enum at the top of this file
+ 	 */
+-	switch (EVP_PKEY_type(pkey->type)) {
++	switch (EVP_PKEY_base_id(pkey)) {
+ 		case EVP_PKEY_RSA:
+ 		case EVP_PKEY_RSA2:
+-			ktype = OPENSSL_KEYTYPE_RSA;
+-
+-			if (pkey->pkey.rsa != NULL) {
+-				zval *rsa;
+-
+-				ALLOC_INIT_ZVAL(rsa);
+-				array_init(rsa);
+-				OPENSSL_PKEY_GET_BN(rsa, n);
+-				OPENSSL_PKEY_GET_BN(rsa, e);
+-				OPENSSL_PKEY_GET_BN(rsa, d);
+-				OPENSSL_PKEY_GET_BN(rsa, p);
+-				OPENSSL_PKEY_GET_BN(rsa, q);
+-				OPENSSL_PKEY_GET_BN(rsa, dmp1);
+-				OPENSSL_PKEY_GET_BN(rsa, dmq1);
+-				OPENSSL_PKEY_GET_BN(rsa, iqmp);
+-				add_assoc_zval(return_value, "rsa", rsa);
++			{
++				RSA *rsa = EVP_PKEY_get0_RSA(pkey);
++				ktype = OPENSSL_KEYTYPE_RSA;
++
++				if (rsa != NULL) {
++					zval *z_rsa;
++					const BIGNUM *n, *e, *d, *p, *q, *dmp1, *dmq1, *iqmp;
++
++					RSA_get0_key(rsa, &n, &e, &d);
++					RSA_get0_factors(rsa, &p, &q);
++					RSA_get0_crt_params(rsa, &dmp1, &dmq1, &iqmp);
++
++					ALLOC_INIT_ZVAL(z_rsa);
++					array_init(z_rsa);
++					OPENSSL_PKEY_GET_BN(z_rsa, n);
++					OPENSSL_PKEY_GET_BN(z_rsa, e);
++					OPENSSL_PKEY_GET_BN(z_rsa, d);
++					OPENSSL_PKEY_GET_BN(z_rsa, p);
++					OPENSSL_PKEY_GET_BN(z_rsa, q);
++					OPENSSL_PKEY_GET_BN(z_rsa, dmp1);
++					OPENSSL_PKEY_GET_BN(z_rsa, dmq1);
++					OPENSSL_PKEY_GET_BN(z_rsa, iqmp);
++					add_assoc_zval(return_value, "rsa", z_rsa);
++				}
+ 			}
+ 
+ 			break;	
+@@ -3954,42 +4237,55 @@ PHP_FUNCTION(openssl_pkey_get_details)
+ 		case EVP_PKEY_DSA2:
+ 		case EVP_PKEY_DSA3:
+ 		case EVP_PKEY_DSA4:
+-			ktype = OPENSSL_KEYTYPE_DSA;
+-
+-			if (pkey->pkey.dsa != NULL) {
+-				zval *dsa;
+-
+-				ALLOC_INIT_ZVAL(dsa);
+-				array_init(dsa);
+-				OPENSSL_PKEY_GET_BN(dsa, p);
+-				OPENSSL_PKEY_GET_BN(dsa, q);
+-				OPENSSL_PKEY_GET_BN(dsa, g);
+-				OPENSSL_PKEY_GET_BN(dsa, priv_key);
+-				OPENSSL_PKEY_GET_BN(dsa, pub_key);
+-				add_assoc_zval(return_value, "dsa", dsa);
++			{
++				DSA *dsa = EVP_PKEY_get0_DSA(pkey);
++				ktype = OPENSSL_KEYTYPE_DSA;
++
++				if (dsa != NULL) {
++					zval *z_dsa;
++					const BIGNUM *p, *q, *g, *priv_key, *pub_key;
++
++					DSA_get0_pqg(dsa, &p, &q, &g);
++					DSA_get0_key(dsa, &pub_key, &priv_key);
++
++					ALLOC_INIT_ZVAL(z_dsa);
++					array_init(z_dsa);
++					OPENSSL_PKEY_GET_BN(z_dsa, p);
++					OPENSSL_PKEY_GET_BN(z_dsa, q);
++					OPENSSL_PKEY_GET_BN(z_dsa, g);
++					OPENSSL_PKEY_GET_BN(z_dsa, priv_key);
++					OPENSSL_PKEY_GET_BN(z_dsa, pub_key);
++					add_assoc_zval(return_value, "dsa", z_dsa);
++				}
+ 			}
+ 			break;
+ 		case EVP_PKEY_DH:
+-			
+-			ktype = OPENSSL_KEYTYPE_DH;
+-
+-			if (pkey->pkey.dh != NULL) {
+-				zval *dh;
+-
+-				ALLOC_INIT_ZVAL(dh);
+-				array_init(dh);
+-				OPENSSL_PKEY_GET_BN(dh, p);
+-				OPENSSL_PKEY_GET_BN(dh, g);
+-				OPENSSL_PKEY_GET_BN(dh, priv_key);
+-				OPENSSL_PKEY_GET_BN(dh, pub_key);
+-				add_assoc_zval(return_value, "dh", dh);
++			{
++				DH *dh = EVP_PKEY_get0_DH(pkey);
++				ktype = OPENSSL_KEYTYPE_DH;
++
++				if (dh != NULL) {
++					zval *z_dh;
++					const BIGNUM *p, *q, *g, *priv_key, *pub_key;
++
++					DH_get0_pqg(dh, &p, &q, &g);
++					DH_get0_key(dh, &pub_key, &priv_key);
++
++					ALLOC_INIT_ZVAL(z_dh);
++					array_init(z_dh);
++					OPENSSL_PKEY_GET_BN(z_dh, p);
++					OPENSSL_PKEY_GET_BN(z_dh, g);
++					OPENSSL_PKEY_GET_BN(z_dh, priv_key);
++					OPENSSL_PKEY_GET_BN(z_dh, pub_key);
++					add_assoc_zval(return_value, "dh", z_dh);
++				}
+ 			}
+ 
+ 			break;
+ #ifdef HAVE_EVP_PKEY_EC
+ 		case EVP_PKEY_EC:
+ 			ktype = OPENSSL_KEYTYPE_EC;
+-			if (pkey->pkey.ec != NULL) {
++			if (EVP_PKEY_get0_EC_KEY(pkey) != NULL) {
+ 				zval *ec;
+ 				const EC_GROUP *ec_group;
+ 				int nid;
+@@ -4546,13 +4842,13 @@ PHP_FUNCTION(openssl_private_encrypt)
+ 	cryptedlen = EVP_PKEY_size(pkey);
+ 	cryptedbuf = emalloc(cryptedlen + 1);
+ 
+-	switch (pkey->type) {
++	switch (EVP_PKEY_id(pkey)) {
+ 		case EVP_PKEY_RSA:
+ 		case EVP_PKEY_RSA2:
+ 			successful =  (RSA_private_encrypt(data_len, 
+ 						(unsigned char *)data, 
+ 						cryptedbuf, 
+-						pkey->pkey.rsa, 
++						EVP_PKEY_get0_RSA(pkey), 
+ 						padding) == cryptedlen);
+ 			break;
+ 		default:
+@@ -4604,13 +4900,13 @@ PHP_FUNCTION(openssl_private_decrypt)
+ 	cryptedlen = EVP_PKEY_size(pkey);
+ 	crypttemp = emalloc(cryptedlen + 1);
+ 
+-	switch (pkey->type) {
++	switch (EVP_PKEY_id(pkey)) {
+ 		case EVP_PKEY_RSA:
+ 		case EVP_PKEY_RSA2:
+ 			cryptedlen = RSA_private_decrypt(data_len, 
+ 					(unsigned char *)data, 
+ 					crypttemp, 
+-					pkey->pkey.rsa, 
++					EVP_PKEY_get0_RSA(pkey), 
+ 					padding);
+ 			if (cryptedlen != -1) {
+ 				cryptedbuf = emalloc(cryptedlen + 1);
+@@ -4669,13 +4965,13 @@ PHP_FUNCTION(openssl_public_encrypt)
+ 	cryptedlen = EVP_PKEY_size(pkey);
+ 	cryptedbuf = emalloc(cryptedlen + 1);
+ 
+-	switch (pkey->type) {
++	switch (EVP_PKEY_id(pkey)) {
+ 		case EVP_PKEY_RSA:
+ 		case EVP_PKEY_RSA2:
+ 			successful = (RSA_public_encrypt(data_len, 
+ 						(unsigned char *)data, 
+ 						cryptedbuf, 
+-						pkey->pkey.rsa, 
++						EVP_PKEY_get0_RSA(pkey), 
+ 						padding) == cryptedlen);
+ 			break;
+ 		default:
+@@ -4728,13 +5024,13 @@ PHP_FUNCTION(openssl_public_decrypt)
+ 	cryptedlen = EVP_PKEY_size(pkey);
+ 	crypttemp = emalloc(cryptedlen + 1);
+ 
+-	switch (pkey->type) {
++	switch (EVP_PKEY_id(pkey)) {
+ 		case EVP_PKEY_RSA:
+ 		case EVP_PKEY_RSA2:
+ 			cryptedlen = RSA_public_decrypt(data_len, 
+ 					(unsigned char *)data, 
+ 					crypttemp, 
+-					pkey->pkey.rsa, 
++					EVP_PKEY_get0_RSA(pkey), 
+ 					padding);
+ 			if (cryptedlen != -1) {
+ 				cryptedbuf = emalloc(cryptedlen + 1);
+@@ -4798,7 +5094,7 @@ PHP_FUNCTION(openssl_sign)
+ 	long keyresource = -1;
+ 	char * data;
+ 	int data_len;
+-	EVP_MD_CTX md_ctx;
++	EVP_MD_CTX *md_ctx;
+ 	zval *method = NULL;
+ 	long signature_algo = OPENSSL_ALGO_SHA1;
+ 	const EVP_MD *mdtype;
+@@ -4831,9 +5127,10 @@ PHP_FUNCTION(openssl_sign)
+ 	siglen = EVP_PKEY_size(pkey);
+ 	sigbuf = emalloc(siglen + 1);
+ 
+-	EVP_SignInit(&md_ctx, mdtype);
+-	EVP_SignUpdate(&md_ctx, data, data_len);
+-	if (EVP_SignFinal (&md_ctx, sigbuf,(unsigned int *)&siglen, pkey)) {
++	md_ctx = EVP_MD_CTX_create();
++	EVP_SignInit(md_ctx, mdtype);
++	EVP_SignUpdate(md_ctx, data, data_len);
++	if (EVP_SignFinal (md_ctx, sigbuf,(unsigned int *)&siglen, pkey)) {
+ 		zval_dtor(signature);
+ 		sigbuf[siglen] = '\0';
+ 		ZVAL_STRINGL(signature, (char *)sigbuf, siglen, 0);
+@@ -4842,7 +5139,7 @@ PHP_FUNCTION(openssl_sign)
+ 		efree(sigbuf);
+ 		RETVAL_FALSE;
+ 	}
+-	EVP_MD_CTX_cleanup(&md_ctx);
++	EVP_MD_CTX_destroy(md_ctx);
+ 	if (keyresource == -1) {
+ 		EVP_PKEY_free(pkey);
+ 	}
+@@ -4856,7 +5153,7 @@ PHP_FUNCTION(openssl_verify)
+ 	zval **key;
+ 	EVP_PKEY *pkey;
+ 	int err;
+-	EVP_MD_CTX     md_ctx;
++	EVP_MD_CTX     *md_ctx;
+ 	const EVP_MD *mdtype;
+ 	long keyresource = -1;
+ 	char * data;	int data_len;
+@@ -4890,10 +5187,11 @@ PHP_FUNCTION(openssl_verify)
+ 		RETURN_FALSE;
+ 	}
+ 
+-	EVP_VerifyInit   (&md_ctx, mdtype);
+-	EVP_VerifyUpdate (&md_ctx, data, data_len);
+-	err = EVP_VerifyFinal (&md_ctx, (unsigned char *)signature, signature_len, pkey);
+-	EVP_MD_CTX_cleanup(&md_ctx);
++	md_ctx = EVP_MD_CTX_create();
++	EVP_VerifyInit   (md_ctx, mdtype);
++	EVP_VerifyUpdate (md_ctx, data, data_len);
++	err = EVP_VerifyFinal (md_ctx, (unsigned char *)signature, signature_len, pkey);
++	EVP_MD_CTX_destroy(md_ctx);
+ 
+ 	if (keyresource == -1) {
+ 		EVP_PKEY_free(pkey);
+@@ -4917,7 +5215,7 @@ PHP_FUNCTION(openssl_seal)
+ 	char *method =NULL;
+ 	int method_len = 0;
+ 	const EVP_CIPHER *cipher;
+-	EVP_CIPHER_CTX ctx;
++	EVP_CIPHER_CTX *ctx;
+ 
+ 	if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "szza/|s", &data, &data_len, &sealdata, &ekeys, &pubkeys, &method, &method_len) == FAILURE) {
+ 		return;
+@@ -4950,6 +5248,7 @@ PHP_FUNCTION(openssl_seal)
+ 	memset(eks, 0, sizeof(*eks) * nkeys);
+ 	key_resources = safe_emalloc(nkeys, sizeof(long), 0);
+ 	memset(key_resources, 0, sizeof(*key_resources) * nkeys);
++	memset(pkeys, 0, sizeof(*pkeys) * nkeys);
+ 
+ 	/* get the public keys we are using to seal this data */
+ 	zend_hash_internal_pointer_reset_ex(pubkeysht, &pos);
+@@ -4967,27 +5266,28 @@ PHP_FUNCTION(openssl_seal)
+ 		i++;
+ 	}
+ 
+-	if (!EVP_EncryptInit(&ctx,cipher,NULL,NULL)) {
++	ctx = EVP_CIPHER_CTX_new();
++	if (ctx == NULL || !EVP_EncryptInit(ctx,cipher,NULL,NULL)) {
+ 		RETVAL_FALSE;
+-		EVP_CIPHER_CTX_cleanup(&ctx);
++		EVP_CIPHER_CTX_free(ctx);
+ 		goto clean_exit;
+ 	}
+ 
+ #if 0
+ 	/* Need this if allow ciphers that require initialization vector */
+-	ivlen = EVP_CIPHER_CTX_iv_length(&ctx);
++	ivlen = EVP_CIPHER_CTX_iv_length(ctx);
+ 	iv = ivlen ? emalloc(ivlen + 1) : NULL;
+ #endif
+ 	/* allocate one byte extra to make room for \0 */
+-	buf = emalloc(data_len + EVP_CIPHER_CTX_block_size(&ctx));
+-	EVP_CIPHER_CTX_cleanup(&ctx);
++	buf = emalloc(data_len + EVP_CIPHER_CTX_block_size(ctx));
++	EVP_CIPHER_CTX_cleanup(ctx);
+ 
+-	if (EVP_SealInit(&ctx, cipher, eks, eksl, NULL, pkeys, nkeys) <= 0 ||
+-			!EVP_SealUpdate(&ctx, buf, &len1, (unsigned char *)data, data_len) ||
+-			!EVP_SealFinal(&ctx, buf + len1, &len2)) {
++	if (EVP_SealInit(ctx, cipher, eks, eksl, NULL, pkeys, nkeys) <= 0 ||
++			!EVP_SealUpdate(ctx, buf, &len1, (unsigned char *)data, data_len) ||
++			!EVP_SealFinal(ctx, buf + len1, &len2)) {
+ 		RETVAL_FALSE;
+ 		efree(buf);
+-		EVP_CIPHER_CTX_cleanup(&ctx);
++		EVP_CIPHER_CTX_free(ctx);
+ 		goto clean_exit;
+ 	}
+ 
+@@ -5018,7 +5318,7 @@ PHP_FUNCTION(openssl_seal)
+ 		efree(buf);
+ 	}
+ 	RETVAL_LONG(len1 + len2);
+-	EVP_CIPHER_CTX_cleanup(&ctx);
++	EVP_CIPHER_CTX_free(ctx);
+ 
+ clean_exit:
+ 	for (i=0; i<nkeys; i++) {
+@@ -5045,7 +5345,7 @@ PHP_FUNCTION(openssl_open)
+ 	int len1, len2;
+ 	unsigned char *buf;
+ 	long keyresource = -1;
+-	EVP_CIPHER_CTX ctx;
++	EVP_CIPHER_CTX *ctx;
+ 	char * data;	int data_len;
+ 	char * ekey;	int ekey_len;
+ 	char *method =NULL;
+@@ -5074,8 +5374,9 @@ PHP_FUNCTION(openssl_open)
+ 	
+ 	buf = emalloc(data_len + 1);
+ 
+-	if (EVP_OpenInit(&ctx, cipher, (unsigned char *)ekey, ekey_len, NULL, pkey) && EVP_OpenUpdate(&ctx, buf, &len1, (unsigned char *)data, data_len)) {
+-		if (!EVP_OpenFinal(&ctx, buf + len1, &len2) || (len1 + len2 == 0)) {
++	ctx = EVP_CIPHER_CTX_new();
++	if (EVP_OpenInit(ctx, cipher, (unsigned char *)ekey, ekey_len, NULL, pkey) && EVP_OpenUpdate(ctx, buf, &len1, (unsigned char *)data, data_len)) {
++		if (!EVP_OpenFinal(ctx, buf + len1, &len2) || (len1 + len2 == 0)) {
+ 			efree(buf);
+ 			RETVAL_FALSE;
+ 		} else {
+@@ -5091,7 +5392,7 @@ PHP_FUNCTION(openssl_open)
+ 	if (keyresource == -1) {
+ 		EVP_PKEY_free(pkey);
+ 	}
+-	EVP_CIPHER_CTX_cleanup(&ctx);
++	EVP_CIPHER_CTX_free(ctx);
+ }
+ /* }}} */
+ 
+@@ -5151,7 +5452,7 @@ PHP_FUNCTION(openssl_digest)
+ 	char *data, *method;
+ 	int data_len, method_len;
+ 	const EVP_MD *mdtype;
+-	EVP_MD_CTX md_ctx;
++	EVP_MD_CTX *md_ctx;
+ 	int siglen;
+ 	unsigned char *sigbuf;
+ 
+@@ -5167,9 +5468,10 @@ PHP_FUNCTION(openssl_digest)
+ 	siglen = EVP_MD_size(mdtype);
+ 	sigbuf = emalloc(siglen + 1);
+ 
+-	EVP_DigestInit(&md_ctx, mdtype);
+-	EVP_DigestUpdate(&md_ctx, (unsigned char *)data, data_len);
+-	if (EVP_DigestFinal (&md_ctx, (unsigned char *)sigbuf, (unsigned int *)&siglen)) {
++	md_ctx = EVP_MD_CTX_create();
++	EVP_DigestInit(md_ctx, mdtype);
++	EVP_DigestUpdate(md_ctx, (unsigned char *)data, data_len);
++	if (EVP_DigestFinal (md_ctx, (unsigned char *)sigbuf, (unsigned int *)&siglen)) {
+ 		if (raw_output) {
+ 			sigbuf[siglen] = '\0';
+ 			RETVAL_STRINGL((char *)sigbuf, siglen, 0);
+@@ -5185,6 +5487,8 @@ PHP_FUNCTION(openssl_digest)
+ 		efree(sigbuf);
+ 		RETVAL_FALSE;
+ 	}
++
++	EVP_MD_CTX_destroy(md_ctx);
+ }
+ /* }}} */
+ 
+@@ -5230,7 +5534,7 @@ PHP_FUNCTION(openssl_encrypt)
+ 	char *data, *method, *password, *iv = "";
+ 	int data_len, method_len, password_len, iv_len = 0, max_iv_len;
+ 	const EVP_CIPHER *cipher_type;
+-	EVP_CIPHER_CTX cipher_ctx;
++	EVP_CIPHER_CTX *cipher_ctx;
+ 	int i=0, outlen, keylen;
+ 	unsigned char *outbuf, *key;
+ 	zend_bool free_iv;
+@@ -5262,19 +5566,24 @@ PHP_FUNCTION(openssl_encrypt)
+ 	outlen = data_len + EVP_CIPHER_block_size(cipher_type);
+ 	outbuf = safe_emalloc(outlen, 1, 1);
+ 
+-	EVP_EncryptInit(&cipher_ctx, cipher_type, NULL, NULL);
++	cipher_ctx = EVP_CIPHER_CTX_new();
++	if (!cipher_ctx) {
++		php_error_docref(NULL TSRMLS_CC, E_WARNING, "Failed to create cipher context");
++		RETURN_FALSE;
++	}
++	EVP_EncryptInit(cipher_ctx, cipher_type, NULL, NULL);
+ 	if (password_len > keylen) {
+-		EVP_CIPHER_CTX_set_key_length(&cipher_ctx, password_len);
++		EVP_CIPHER_CTX_set_key_length(cipher_ctx, password_len);
+ 	}
+-	EVP_EncryptInit_ex(&cipher_ctx, NULL, NULL, key, (unsigned char *)iv);
++	EVP_EncryptInit_ex(cipher_ctx, NULL, NULL, key, (unsigned char *)iv);
+ 	if (options & OPENSSL_ZERO_PADDING) {
+-		EVP_CIPHER_CTX_set_padding(&cipher_ctx, 0);
++		EVP_CIPHER_CTX_set_padding(cipher_ctx, 0);
+ 	}
+ 	if (data_len > 0) {
+-		EVP_EncryptUpdate(&cipher_ctx, outbuf, &i, (unsigned char *)data, data_len);
++		EVP_EncryptUpdate(cipher_ctx, outbuf, &i, (unsigned char *)data, data_len);
+ 	}
+ 	outlen = i;
+-	if (EVP_EncryptFinal(&cipher_ctx, (unsigned char *)outbuf + i, &i)) {
++	if (EVP_EncryptFinal(cipher_ctx, (unsigned char *)outbuf + i, &i)) {
+ 		outlen += i;
+ 		if (options & OPENSSL_RAW_DATA) {
+ 			outbuf[outlen] = '\0';
+@@ -5301,7 +5610,8 @@ PHP_FUNCTION(openssl_encrypt)
+ 	if (free_iv) {
+ 		efree(iv);
+ 	}
+-	EVP_CIPHER_CTX_cleanup(&cipher_ctx);
++	EVP_CIPHER_CTX_cleanup(cipher_ctx);
++	EVP_CIPHER_CTX_free(cipher_ctx);
+ }
+ /* }}} */
+ 
+@@ -5313,7 +5623,7 @@ PHP_FUNCTION(openssl_decrypt)
+ 	char *data, *method, *password, *iv = "";
+ 	int data_len, method_len, password_len, iv_len = 0;
+ 	const EVP_CIPHER *cipher_type;
+-	EVP_CIPHER_CTX cipher_ctx;
++	EVP_CIPHER_CTX *cipher_ctx;
+ 	int i, outlen, keylen;
+ 	unsigned char *outbuf, *key;
+ 	int base64_str_len;
+@@ -5359,17 +5669,23 @@ PHP_FUNCTION(openssl_decrypt)
+ 	outlen = data_len + EVP_CIPHER_block_size(cipher_type);
+ 	outbuf = emalloc(outlen + 1);
+ 
+-	EVP_DecryptInit(&cipher_ctx, cipher_type, NULL, NULL);
++	cipher_ctx = EVP_CIPHER_CTX_new();
++	if (!cipher_ctx) {
++		php_error_docref(NULL TSRMLS_CC, E_WARNING, "Failed to create cipher context");
++		RETURN_FALSE;
++	}
++
++	EVP_DecryptInit(cipher_ctx, cipher_type, NULL, NULL);
+ 	if (password_len > keylen) {
+-		EVP_CIPHER_CTX_set_key_length(&cipher_ctx, password_len);
++		EVP_CIPHER_CTX_set_key_length(cipher_ctx, password_len);
+ 	}
+-	EVP_DecryptInit_ex(&cipher_ctx, NULL, NULL, key, (unsigned char *)iv);
++	EVP_DecryptInit_ex(cipher_ctx, NULL, NULL, key, (unsigned char *)iv);
+ 	if (options & OPENSSL_ZERO_PADDING) {
+-		EVP_CIPHER_CTX_set_padding(&cipher_ctx, 0);
++		EVP_CIPHER_CTX_set_padding(cipher_ctx, 0);
+ 	}
+-	EVP_DecryptUpdate(&cipher_ctx, outbuf, &i, (unsigned char *)data, data_len);
++	EVP_DecryptUpdate(cipher_ctx, outbuf, &i, (unsigned char *)data, data_len);
+ 	outlen = i;
+-	if (EVP_DecryptFinal(&cipher_ctx, (unsigned char *)outbuf + i, &i)) {
++	if (EVP_DecryptFinal(cipher_ctx, (unsigned char *)outbuf + i, &i)) {
+ 		outlen += i;
+ 		outbuf[outlen] = '\0';
+ 		RETVAL_STRINGL((char *)outbuf, outlen, 0);
+@@ -5386,7 +5702,8 @@ PHP_FUNCTION(openssl_decrypt)
+ 	if (base64_str) {
+ 		efree(base64_str);
+ 	}
+- 	EVP_CIPHER_CTX_cleanup(&cipher_ctx);
++ 	EVP_CIPHER_CTX_cleanup(cipher_ctx);
++ 	EVP_CIPHER_CTX_free(cipher_ctx);
+ }
+ /* }}} */
+ 
+@@ -5424,6 +5741,7 @@ PHP_FUNCTION(openssl_dh_compute_key)
+ 	zval *key;
+ 	char *pub_str;
+ 	int pub_len;
++	DH *dh;
+ 	EVP_PKEY *pkey;
+ 	BIGNUM *pub;
+ 	char *data;
+@@ -5433,14 +5751,21 @@ PHP_FUNCTION(openssl_dh_compute_key)
+ 		return;
+ 	}
+ 	ZEND_FETCH_RESOURCE(pkey, EVP_PKEY *, &key, -1, "OpenSSL key", le_key);
+-	if (!pkey || EVP_PKEY_type(pkey->type) != EVP_PKEY_DH || !pkey->pkey.dh) {
++	if (pkey == NULL) {
++		RETURN_FALSE;
++	}
++	if (EVP_PKEY_base_id(pkey) != EVP_PKEY_DH) {
++		RETURN_FALSE;
++	}
++	dh = EVP_PKEY_get0_DH(pkey);
++	if (dh == NULL) {
+ 		RETURN_FALSE;
+ 	}
+ 
+ 	pub = BN_bin2bn((unsigned char*)pub_str, pub_len, NULL);
+ 
+-	data = emalloc(DH_size(pkey->pkey.dh) + 1);
+-	len = DH_compute_key((unsigned char*)data, pub, pkey->pkey.dh);
++	data = emalloc(DH_size(dh) + 1);
++	len = DH_compute_key((unsigned char*)data, pub, dh);
+ 
+ 	if (len >= 0) {
+ 		data[len] = 0;
+diff --git a/ext/openssl/xp_ssl.c b/ext/openssl/xp_ssl.c
+index d549033..c2d477c 100644
+--- a/ext/openssl/xp_ssl.c
++++ b/ext/openssl/xp_ssl.c
+@@ -935,7 +935,7 @@ static int set_local_cert(SSL_CTX *ctx, php_stream *stream TSRMLS_DC) /* {{{ */
+ static const SSL_METHOD *php_select_crypto_method(long method_value, int is_client TSRMLS_DC) /* {{{ */
+ {
+ 	if (method_value == STREAM_CRYPTO_METHOD_SSLv2) {
+-#ifndef OPENSSL_NO_SSL2
++#if !defined(OPENSSL_NO_SSL2) && OPENSSL_VERSION_NUMBER < 0x10100000L
+ 		return is_client ? SSLv2_client_method() : SSLv2_server_method();
+ #else
+ 		php_error_docref(NULL TSRMLS_CC, E_WARNING,
+@@ -1588,12 +1588,26 @@ int php_openssl_setup_crypto(php_stream *stream,
+ }
+ /* }}} */
+ 
++#define PHP_SSL_MAX_VERSION_LEN 32
++
++static char *php_ssl_cipher_get_version(const SSL_CIPHER *c, char *buffer, size_t max_len) /* {{{ */
++{
++	const char *version = SSL_CIPHER_get_version(c);
++	strncpy(buffer, version, max_len);
++	if (max_len <= strlen(version)) {
++		buffer[max_len - 1] = 0;
++	}
++	return buffer;
++}
++/* }}} */
++
+ static zval *capture_session_meta(SSL *ssl_handle) /* {{{ */
+ {
+ 	zval *meta_arr;
+ 	char *proto_str;
+ 	long proto = SSL_version(ssl_handle);
+ 	const SSL_CIPHER *cipher = SSL_get_current_cipher(ssl_handle);
++	char version_str[PHP_SSL_MAX_VERSION_LEN];
+ 
+ 	switch (proto) {
+ #if OPENSSL_VERSION_NUMBER >= 0x10001001L
+@@ -1611,7 +1625,7 @@ static zval *capture_session_meta(SSL *ssl_handle) /* {{{ */
+ 	add_assoc_string(meta_arr, "protocol", proto_str, 1);
+ 	add_assoc_string(meta_arr, "cipher_name", (char *) SSL_CIPHER_get_name(cipher), 1);
+ 	add_assoc_long(meta_arr, "cipher_bits", SSL_CIPHER_get_bits(cipher, NULL));
+-	add_assoc_string(meta_arr, "cipher_version", SSL_CIPHER_get_version(cipher), 1);
++	add_assoc_string(meta_arr, "cipher_version", php_ssl_cipher_get_version(cipher, version_str, PHP_SSL_MAX_VERSION_LEN), 1);
+ 
+ 	return meta_arr;
+ }
+diff --git a/ext/phar/util.c b/ext/phar/util.c
+index 828be8f..06e4e55 100644
+--- a/ext/phar/util.c
++++ b/ext/phar/util.c
+@@ -1531,7 +1531,7 @@ int phar_verify_signature(php_stream *fp, size_t end_of_phar, php_uint32 sig_typ
+ 			BIO *in;
+ 			EVP_PKEY *key;
+ 			EVP_MD *mdtype = (EVP_MD *) EVP_sha1();
+-			EVP_MD_CTX md_ctx;
++			EVP_MD_CTX *md_ctx;
+ #else
+ 			int tempsig;
+ #endif
+@@ -1608,7 +1608,8 @@ int phar_verify_signature(php_stream *fp, size_t end_of_phar, php_uint32 sig_typ
+ 				return FAILURE;
+ 			}
+ 
+-			EVP_VerifyInit(&md_ctx, mdtype);
++			md_ctx = EVP_MD_CTX_create();
++			EVP_VerifyInit(md_ctx, mdtype);
+ 			read_len = end_of_phar;
+ 
+ 			if (read_len > sizeof(buf)) {
+@@ -1620,7 +1621,7 @@ int phar_verify_signature(php_stream *fp, size_t end_of_phar, php_uint32 sig_typ
+ 			php_stream_seek(fp, 0, SEEK_SET);
+ 
+ 			while (read_size && (len = php_stream_read(fp, (char*)buf, read_size)) > 0) {
+-				EVP_VerifyUpdate (&md_ctx, buf, len);
++				EVP_VerifyUpdate (md_ctx, buf, len);
+ 				read_len -= (off_t)len;
+ 
+ 				if (read_len < read_size) {
+@@ -1628,9 +1629,9 @@ int phar_verify_signature(php_stream *fp, size_t end_of_phar, php_uint32 sig_typ
+ 				}
+ 			}
+ 
+-			if (EVP_VerifyFinal(&md_ctx, (unsigned char *)sig, sig_len, key) != 1) {
++			if (EVP_VerifyFinal(md_ctx, (unsigned char *)sig, sig_len, key) != 1) {
+ 				/* 1: signature verified, 0: signature does not match, -1: failed signature operation */
+-				EVP_MD_CTX_cleanup(&md_ctx);
++				EVP_MD_CTX_destroy(md_ctx);
+ 
+ 				if (error) {
+ 					spprintf(error, 0, "broken openssl signature");
+@@ -1639,7 +1640,7 @@ int phar_verify_signature(php_stream *fp, size_t end_of_phar, php_uint32 sig_typ
+ 				return FAILURE;
+ 			}
+ 
+-			EVP_MD_CTX_cleanup(&md_ctx);
++			EVP_MD_CTX_destroy(md_ctx);
+ #endif
+ 
+ 			*signature_len = phar_hex_str((const char*)sig, sig_len, signature TSRMLS_CC);
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-devtools/php/php/CVE-2017-9120.patch b/meta-openembedded/meta-oe/recipes-devtools/php/php/CVE-2017-9120.patch
new file mode 100644
index 0000000..728f25b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/php/php/CVE-2017-9120.patch
@@ -0,0 +1,21 @@
+php: patch for CVE-2017-9120
+
+Upstream-Status: Backport [https://bugs.php.net/bug.php?id=74544]
+
+CVE: CVE-2017-9120
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+
+diff --git a/ext/mysqli/mysqli_api.c b/ext/mysqli/mysqli_api.c
+index 03a39d7..7b88731 100644
+--- a/ext/mysqli/mysqli_api.c
++++ b/ext/mysqli/mysqli_api.c
+@@ -1965,7 +1965,7 @@ PHP_FUNCTION(mysqli_real_escape_string) {
+ 	}
+ 	MYSQLI_FETCH_RESOURCE_CONN(mysql, mysql_link, MYSQLI_STATUS_VALID);
+ 
+-	newstr = zend_string_alloc(2 * escapestr_len, 0);
++	newstr = zend_string_safe_alloc(2, escapestr_len, 0, 0);
+ 	ZSTR_LEN(newstr) = mysql_real_escape_string(mysql->mysql, ZSTR_VAL(newstr), escapestr, escapestr_len);
+ 	newstr = zend_string_truncate(newstr, ZSTR_LEN(newstr), 0);
+ 
diff --git a/meta-openembedded/meta-oe/recipes-devtools/php/php_5.6.35.bb b/meta-openembedded/meta-oe/recipes-devtools/php/php_5.6.35.bb
deleted file mode 100644
index c17c0d6..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/php/php_5.6.35.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-require php.inc
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=b602636d46a61c0ac0432bbf5c078fe4"
-
-SRC_URI += "file://php5-change-AC_TRY_RUN-to-AC_TRY_LINK.patch \
-            file://pthread-check-threads-m4.patch \
-            file://0001-Add-lpthread-to-link.patch \
-            file://acinclude-xml2-config.patch \
-            file://0001-acinclude-use-pkgconfig-for-libxml2-config.patch \
-            "
-
-SRC_URI_append_class-target = " \
-                                file://php5-pear-makefile.patch \
-                                file://php5-phar-makefile.patch \
-                                file://php5-0001-opcache-config.m4-enable-opcache.patch \
-                                "
-
-SRC_URI[md5sum] = "905ae5f586351f3ca29d044c9484d475"
-SRC_URI[sha256sum] = "ee78a7e9ca21d8ea394d037c55effff477a49dbae31c7753c547036f5bd73b92"
-
-DEPENDS += "libmcrypt"
-EXTRA_OECONF += "--with-mcrypt=${STAGING_DIR_TARGET}${exec_prefix} \
-                 " 
diff --git a/meta-openembedded/meta-oe/recipes-devtools/php/php_5.6.38.bb b/meta-openembedded/meta-oe/recipes-devtools/php/php_5.6.38.bb
new file mode 100644
index 0000000..d6f5145
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/php/php_5.6.38.bb
@@ -0,0 +1,24 @@
+require php.inc
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=b602636d46a61c0ac0432bbf5c078fe4"
+
+SRC_URI += "file://php5-change-AC_TRY_RUN-to-AC_TRY_LINK.patch \
+            file://pthread-check-threads-m4.patch \
+            file://0001-Add-lpthread-to-link.patch \
+            file://acinclude-xml2-config.patch \
+            file://0001-acinclude-use-pkgconfig-for-libxml2-config.patch \
+            file://0001-PHP-5.6-LibSSL-1.1-compatibility.patch \
+            "
+
+SRC_URI_append_class-target = " \
+                                file://php5-pear-makefile.patch \
+                                file://php5-phar-makefile.patch \
+                                file://php5-0001-opcache-config.m4-enable-opcache.patch \
+                                "
+
+SRC_URI[md5sum] = "5b98aa066567eca8e5738b8ef4a3545c"
+SRC_URI[sha256sum] = "d65b231bbdd63be4439ef5ced965cfd63e62983429dbd4dfcfb49981593ebc03"
+
+DEPENDS += "libmcrypt"
+EXTRA_OECONF += "--with-mcrypt=${STAGING_DIR_TARGET}${exec_prefix} \
+                 " 
diff --git a/meta-openembedded/meta-oe/recipes-devtools/php/php_7.2.10.bb b/meta-openembedded/meta-oe/recipes-devtools/php/php_7.2.10.bb
new file mode 100644
index 0000000..8dc64bb
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/php/php_7.2.10.bb
@@ -0,0 +1,25 @@
+require php.inc
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=67e369bc8d1f2e641236b8002039a6a2"
+
+SRC_URI += "file://change-AC_TRY_RUN-to-AC_TRY_LINK.patch \
+            file://0001-acinclude.m4-skip-binconfig-check-for-libxml.patch \
+            file://0001-fix-error-caused-by-a-new-variable-is-declared-after.patch \
+            file://CVE-2017-9120.patch \
+           "
+SRC_URI_append_class-target = " \
+                                file://pear-makefile.patch \
+                                file://phar-makefile.patch \
+                                file://0001-opcache-config.m4-enable-opcache.patch \
+                                "
+
+SRC_URI[md5sum] = "0ce8ff615bfb9de7a89bab8d742c11c0"
+SRC_URI[sha256sum] = "01b6129a0921a1636b07da9bc598a876669e45a462cef4b5844fc26862dbda9d"
+
+PACKAGECONFIG[mysql] = "--with-mysqli=${STAGING_BINDIR_CROSS}/mysql_config \
+                        --with-pdo-mysql=${STAGING_BINDIR_CROSS}/mysql_config \
+                        ,--without-mysqli --without-pdo-mysql \
+                        ,mysql5"
+PACKAGECONFIG[valgrind] = "--with-valgrind=${STAGING_DIR_TARGET}/usr,--with-valgrind=no,valgrind"
+
+FILES_${PN}-fpm += "${sysconfdir}/php-fpm.d/www.conf.default"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/php/php_7.2.7.bb b/meta-openembedded/meta-oe/recipes-devtools/php/php_7.2.7.bb
deleted file mode 100644
index a256cd7..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/php/php_7.2.7.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-require php.inc
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=67e369bc8d1f2e641236b8002039a6a2"
-
-SRC_URI += "file://change-AC_TRY_RUN-to-AC_TRY_LINK.patch \
-            file://0001-acinclude.m4-skip-binconfig-check-for-libxml.patch \
-            file://0001-fix-error-caused-by-a-new-variable-is-declared-after.patch \
-           "
-SRC_URI_append_class-target = " \
-                                file://pear-makefile.patch \
-                                file://phar-makefile.patch \
-                                file://0001-opcache-config.m4-enable-opcache.patch \
-                                "
-
-SRC_URI[md5sum] = "4b5698c8c6c2b9cbff3a5706da67bb0f"
-SRC_URI[sha256sum] = "cc81675a96af4dd18d8ffc02f26a36c622abadf86af7ecfea7bcde8d3c96d5a3"
-
-PACKAGECONFIG[mysql] = "--with-mysqli=${STAGING_BINDIR_CROSS}/mysql_config \
-                        --with-pdo-mysql=${STAGING_BINDIR_CROSS}/mysql_config \
-                        ,--without-mysqli --without-pdo-mysql \
-                        ,mysql5"
-
-FILES_${PN}-fpm += "${sysconfdir}/php-fpm.d/www.conf.default"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/protobuf/protobuf-c_1.3.0.bb b/meta-openembedded/meta-oe/recipes-devtools/protobuf/protobuf-c_1.3.0.bb
deleted file mode 100644
index fe1e6e5..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/protobuf/protobuf-c_1.3.0.bb
+++ /dev/null
@@ -1,31 +0,0 @@
-SUMMARY = "Protocol Buffers - structured data serialisation mechanism"
-DESCRIPTION = "This is protobuf-c, a C implementation of the Google Protocol Buffers data \
-serialization format. It includes libprotobuf-c, a pure C library that \
-implements protobuf encoding and decoding, and protoc-c, a code generator that \
-converts Protocol Buffer .proto files to C descriptor code, based on the \
-original protoc. protobuf-c formerly included an RPC implementation; that code \
-has been split out into the protobuf-c-rpc project."
-HOMEPAGE = "https://github.com/protobuf-c/protobuf-c"
-SECTION = "console/tools"
-LICENSE = "BSD-2-Clause"
-
-DEPENDS = "protobuf-native protobuf"
-
-PACKAGE_BEFORE_PN = "${PN}-compiler"
-RDEPENDS_${PN}-compiler = "protobuf-compiler"
-RDEPENDS_${PN}-dev += "${PN}-compiler"
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=cb901168715f4782a2b06c3ddaefa558"
-
-PV .= "+git${SRCPV}"
-SRCREV = "dac1a65feac4ad72f612aab99f487056fbcf5c1a"
-
-SRC_URI = "git://github.com/protobuf-c/protobuf-c.git"
-
-S = "${WORKDIR}/git"
-
-inherit autotools pkgconfig
-
-FILES_${PN}-compiler = "${bindir}"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/protobuf/protobuf-c_1.3.1.bb b/meta-openembedded/meta-oe/recipes-devtools/protobuf/protobuf-c_1.3.1.bb
new file mode 100644
index 0000000..7ef0300
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/protobuf/protobuf-c_1.3.1.bb
@@ -0,0 +1,35 @@
+SUMMARY = "Protocol Buffers - structured data serialisation mechanism"
+DESCRIPTION = "This is protobuf-c, a C implementation of the Google Protocol Buffers data \
+serialization format. It includes libprotobuf-c, a pure C library that \
+implements protobuf encoding and decoding, and protoc-c, a code generator that \
+converts Protocol Buffer .proto files to C descriptor code, based on the \
+original protoc. protobuf-c formerly included an RPC implementation; that code \
+has been split out into the protobuf-c-rpc project."
+HOMEPAGE = "https://github.com/protobuf-c/protobuf-c"
+SECTION = "console/tools"
+LICENSE = "BSD-2-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=cb901168715f4782a2b06c3ddaefa558"
+
+DEPENDS = "protobuf-native protobuf"
+
+PV .= "+git${SRCPV}"
+SRCREV = "269771b4b45d3aba04e59569f53600003db8d9ff"
+
+SRC_URI = "git://github.com/protobuf-c/protobuf-c.git"
+
+S = "${WORKDIR}/git"
+
+#make sure c++11 is used
+CXXFLAGS += "-std=c++11"
+BUILD_CXXFLAGS += "-std=c++11"
+
+inherit autotools pkgconfig
+
+PACKAGE_BEFORE_PN = "${PN}-compiler"
+
+FILES_${PN}-compiler = "${bindir}"
+
+RDEPENDS_${PN}-compiler = "protobuf-compiler"
+RDEPENDS_${PN}-dev += "${PN}-compiler"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/protobuf/protobuf/0001-protobuf-fix-configure-error.patch b/meta-openembedded/meta-oe/recipes-devtools/protobuf/protobuf/0001-protobuf-fix-configure-error.patch
new file mode 100644
index 0000000..a2f7a4b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/protobuf/protobuf/0001-protobuf-fix-configure-error.patch
@@ -0,0 +1,33 @@
+From 52959e8e01e39139d18f752e97283e45b4b7a426 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Wed, 18 Jul 2018 17:52:34 +0800
+Subject: [PATCH] protobuf: fix configure error
+
+fix below error:
+gnu-configize: 'configure.ac' or 'configure.in' is required
+
+third_party/googletest is git submodule of protobuf. Above error
+caused by missing submodule googletest.
+
+Upstream-Status: Inappropriate [oe-specific]
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ configure.ac | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index aec10cf..7fbe57d 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -214,7 +214,6 @@ AX_CXX_COMPILE_STDCXX([11], [noext], [mandatory])
+ #   too.
+ export CFLAGS
+ export CXXFLAGS
+-AC_CONFIG_SUBDIRS([third_party/googletest])
+ 
+ AC_CONFIG_FILES([Makefile src/Makefile benchmarks/Makefile conformance/Makefile protobuf.pc protobuf-lite.pc])
+ AC_OUTPUT
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-devtools/protobuf/protobuf_3.5.1.bb b/meta-openembedded/meta-oe/recipes-devtools/protobuf/protobuf_3.5.1.bb
deleted file mode 100644
index 073dfae..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/protobuf/protobuf_3.5.1.bb
+++ /dev/null
@@ -1,87 +0,0 @@
-SUMMARY = "Protocol Buffers - structured data serialisation mechanism"
-DESCRIPTION = "Protocol Buffers are a way of encoding structured data in an \
-efficient yet extensible format. Google uses Protocol Buffers for almost \
-all of its internal RPC protocols and file formats."
-HOMEPAGE = "https://github.com/google/protobuf"
-SECTION = "console/tools"
-LICENSE = "BSD-3-Clause"
-
-PACKAGE_BEFORE_PN = "${PN}-compiler ${PN}-lite"
-
-DEPENDS = "zlib"
-DEPENDS_append_class-target  = " protobuf-native"
-RDEPENDS_${PN}-compiler = "${PN}"
-RDEPENDS_${PN}-dev += "${PN}-compiler"
-RDEPENDS_${PN}-ptest = "bash ${@bb.utils.contains('PACKAGECONFIG', 'python', 'python-protobuf', '', d)}"
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=35953c752efc9299b184f91bef540095"
-
-SRCREV = "106ffc04be1abf3ff3399f54ccf149815b287dd9"
-
-PV = "3.5.1+git${SRCPV}"
-
-SRC_URI = "git://github.com/google/protobuf.git;branch=3.5.x \
-	   file://run-ptest \
-          "
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[python] = ",,"
-
-EXTRA_OECONF += " --with-protoc=echo"
-
-inherit autotools-brokensep pkgconfig ptest
-
-S = "${WORKDIR}/git"
-TEST_SRC_DIR="examples"
-LANG_SUPPORT = "cpp ${@bb.utils.contains('PACKAGECONFIG', 'python', 'python', '', d)}"
-
-do_compile_ptest() {
-	# Modify makefile to use the cross-compiler
-	sed -e "s|c++|${CXX} \$(LDFLAGS)|g" -i "${S}/${TEST_SRC_DIR}/Makefile"
-
-	mkdir -p "${B}/${TEST_SRC_DIR}"
-
-	# Add the location of the cross-compiled header and library files
-	# which haven't been installed yet.
-	cp "${B}/protobuf.pc" "${B}/${TEST_SRC_DIR}/protobuf.pc"
-	sed -e 's|libdir=|libdir=${PKG_CONFIG_SYSROOT_DIR}|' -i "${B}/${TEST_SRC_DIR}/protobuf.pc"
-	sed -e 's|Cflags:|Cflags: -I${S}/src|' -i "${B}/${TEST_SRC_DIR}/protobuf.pc"
-	sed -e 's|Libs:|Libs: -L${B}/src/.libs|' -i "${B}/${TEST_SRC_DIR}/protobuf.pc"
-	export PKG_CONFIG_PATH="${B}/${TEST_SRC_DIR}"
-
-	# Save the pkgcfg sysroot variable, and update it to nothing so
-	# that it doesn't append the sysroot to the beginning of paths.
-	# The header and library files aren't installed to the target
-	# system yet.  So the absolute paths were specified above.
-	save_pkg_config_sysroot_dir=$PKG_CONFIG_SYSROOT_DIR
-	export PKG_CONFIG_SYSROOT_DIR=
-
-	# Compile the tests
-	for lang in ${LANG_SUPPORT}; do
-		oe_runmake -C "${S}/${TEST_SRC_DIR}" ${lang}
-	done
-
-	# Restore the pkgconfig sysroot variable
-	export PKG_CONFIG_SYSROOT_DIR=$save_pkg_config_sysroot_dir
-}
-
-do_install_ptest() {
-	local olddir=`pwd`
-
-	cd "${S}/${TEST_SRC_DIR}"
-	install -d "${D}/${PTEST_PATH}"
-	for i in add_person* list_people*; do
-		if [ -x "$i" ]; then
-			install "$i" "${D}/${PTEST_PATH}"
-		fi
-	done
-	cp "${S}/${TEST_SRC_DIR}/addressbook_pb2.py" "${D}/${PTEST_PATH}"
-	cd "$olddir"
-}
-
-FILES_${PN}-compiler = "${bindir} ${libdir}/libprotoc${SOLIBS}"
-FILES_${PN}-lite = "${bindir} ${libdir}/libprotobuf-lite${SOLIBS}"
-
-MIPS_INSTRUCTION_SET = "mips"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/protobuf/protobuf_3.6.1.bb b/meta-openembedded/meta-oe/recipes-devtools/protobuf/protobuf_3.6.1.bb
new file mode 100644
index 0000000..cf72d9c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/protobuf/protobuf_3.6.1.bb
@@ -0,0 +1,93 @@
+SUMMARY = "Protocol Buffers - structured data serialisation mechanism"
+DESCRIPTION = "Protocol Buffers are a way of encoding structured data in an \
+efficient yet extensible format. Google uses Protocol Buffers for almost \
+all of its internal RPC protocols and file formats."
+HOMEPAGE = "https://github.com/google/protobuf"
+SECTION = "console/tools"
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=37b5762e07f0af8c74ce80a8bda4266b"
+
+DEPENDS = "zlib"
+DEPENDS_append_class-target = " protobuf-native"
+
+PV .= "+git${SRCPV}"
+
+SRCREV = "48cb18e5c419ddd23d9badcfe4e9df7bde1979b2"
+
+SRC_URI = "git://github.com/google/protobuf.git;branch=3.6.x \
+           file://run-ptest \
+           file://0001-protobuf-fix-configure-error.patch \
+"
+S = "${WORKDIR}/git"
+
+inherit autotools-brokensep pkgconfig ptest
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[python] = ",,"
+
+EXTRA_OECONF += "--with-protoc=echo"
+
+TEST_SRC_DIR = "examples"
+LANG_SUPPORT = "cpp ${@bb.utils.contains('PACKAGECONFIG', 'python', 'python', '', d)}"
+
+do_compile_ptest() {
+	# Modify makefile to use the cross-compiler
+	sed -e "s|c++|${CXX} \$(LDFLAGS)|g" -i "${S}/${TEST_SRC_DIR}/Makefile"
+
+	mkdir -p "${B}/${TEST_SRC_DIR}"
+
+	# Add the location of the cross-compiled header and library files
+	# which haven't been installed yet.
+	cp "${B}/protobuf.pc" "${B}/${TEST_SRC_DIR}/protobuf.pc"
+	sed -e 's|libdir=|libdir=${PKG_CONFIG_SYSROOT_DIR}|' -i "${B}/${TEST_SRC_DIR}/protobuf.pc"
+	sed -e 's|Cflags:|Cflags: -I${S}/src|' -i "${B}/${TEST_SRC_DIR}/protobuf.pc"
+	sed -e 's|Libs:|Libs: -L${B}/src/.libs|' -i "${B}/${TEST_SRC_DIR}/protobuf.pc"
+	export PKG_CONFIG_PATH="${B}/${TEST_SRC_DIR}"
+
+	# Save the pkgcfg sysroot variable, and update it to nothing so
+	# that it doesn't append the sysroot to the beginning of paths.
+	# The header and library files aren't installed to the target
+	# system yet.  So the absolute paths were specified above.
+	save_pkg_config_sysroot_dir=$PKG_CONFIG_SYSROOT_DIR
+	export PKG_CONFIG_SYSROOT_DIR=
+
+	# Compile the tests
+	for lang in ${LANG_SUPPORT}; do
+		oe_runmake -C "${S}/${TEST_SRC_DIR}" ${lang}
+	done
+
+	# Restore the pkgconfig sysroot variable
+	export PKG_CONFIG_SYSROOT_DIR=$save_pkg_config_sysroot_dir
+}
+
+do_install_ptest() {
+	local olddir=`pwd`
+
+	cd "${S}/${TEST_SRC_DIR}"
+	install -d "${D}/${PTEST_PATH}"
+	for i in add_person* list_people*; do
+		if [ -x "$i" ]; then
+			install "$i" "${D}/${PTEST_PATH}"
+		fi
+	done
+	cp "${S}/${TEST_SRC_DIR}/addressbook_pb2.py" "${D}/${PTEST_PATH}"
+	cd "$olddir"
+}
+
+PACKAGE_BEFORE_PN = "${PN}-compiler ${PN}-lite"
+
+FILES_${PN}-compiler = "${bindir} ${libdir}/libprotoc${SOLIBS}"
+FILES_${PN}-lite = "${libdir}/libprotobuf-lite${SOLIBS}"
+
+RDEPENDS_${PN}-compiler = "${PN}"
+RDEPENDS_${PN}-dev += "${PN}-compiler"
+RDEPENDS_${PN}-ptest = "bash ${@bb.utils.contains('PACKAGECONFIG', 'python', 'python-protobuf', '', d)}"
+
+MIPS_INSTRUCTION_SET = "mips"
+
+BBCLASSEXTEND = "native nativesdk"
+
+LDFLAGS_append_arm = " -latomic"
+LDFLAGS_append_mips = " -latomic"
+LDFLAGS_append_powerpc = " -latomic"
+LDFLAGS_append_mipsel = " -latomic"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/python/python-distutils-extra.bb b/meta-openembedded/meta-oe/recipes-devtools/python/python-distutils-extra.bb
index 56dd33d..eb84f74 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/python/python-distutils-extra.bb
+++ b/meta-openembedded/meta-oe/recipes-devtools/python/python-distutils-extra.bb
@@ -2,8 +2,6 @@
 
 inherit setuptools
 
-DISTUTILS_INSTALL_ARGS += "--install-lib=${libdir}/${PYTHON_DIR}/site-packages"
-
 RDEPENDS_${PN} = "\
     python-distutils \
 "
diff --git a/meta-openembedded/meta-oe/recipes-devtools/python/python-pygobject_3.28.0.bb b/meta-openembedded/meta-oe/recipes-devtools/python/python-pygobject_3.28.0.bb
deleted file mode 100644
index ab65ba1..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/python/python-pygobject_3.28.0.bb
+++ /dev/null
@@ -1,35 +0,0 @@
-SUMMARY = "Python GObject bindings"
-HOMEPAGE = "http://www.pygtk.org/"
-SECTION = "devel/python"
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=a916467b91076e631dd8edb7424769c7"
-
-inherit autotools pkgconfig gnomebase distutils-base gobject-introspection
-
-PYTHON_BASEVERSION = "2.7"
-PYTHON_PN = "python"
-
-DEPENDS += "gnome-common-native python glib-2.0"
-
-SRCNAME="pygobject"
-SRC_URI = " \
-    http://ftp.gnome.org/pub/GNOME/sources/${SRCNAME}/${@gnome_verdir("${PV}")}/${SRCNAME}-${PV}.tar.xz \
-    file://0001-configure.ac-add-sysroot-path-to-GI_DATADIR-don-t-se.patch \
-"
-
-SRC_URI[md5sum] = "b29d69edb63ae1f555afeb19f90b9996"
-SRC_URI[sha256sum] = "42b47b261b45aedfc77e02e3c90a01cd74d6f86c3273c1860a054d531d606e5a"
-
-S = "${WORKDIR}/${SRCNAME}-${PV}"
-
-BBCLASSEXTEND = "native"
-
-EXTRA_OECONF = "--disable-cairo --with-python=${PYTHON}"
-
-RDEPENDS_${PN} += "python-setuptools"
-RDEPENDS_${PN}_class-native = ""
-
-do_install_append() {
-    # Remove files that clash with python3-pygobject; their content is same
-    rm -rf ${D}${includedir}/pygobject-3.0//pygobject.h ${D}${libdir}/pkgconfig
-}
diff --git a/meta-openembedded/meta-oe/recipes-devtools/python/python-pygobject_3.28.3.bb b/meta-openembedded/meta-oe/recipes-devtools/python/python-pygobject_3.28.3.bb
new file mode 100644
index 0000000..c444fbf
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/python/python-pygobject_3.28.3.bb
@@ -0,0 +1,35 @@
+SUMMARY = "Python GObject bindings"
+HOMEPAGE = "http://www.pygtk.org/"
+SECTION = "devel/python"
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=a916467b91076e631dd8edb7424769c7"
+
+inherit autotools pkgconfig gnomebase distutils-base gobject-introspection
+
+PYTHON_BASEVERSION = "2.7"
+PYTHON_PN = "python"
+
+DEPENDS += "gnome-common-native python glib-2.0"
+
+SRCNAME="pygobject"
+SRC_URI = " \
+    http://ftp.gnome.org/pub/GNOME/sources/${SRCNAME}/${@gnome_verdir("${PV}")}/${SRCNAME}-${PV}.tar.xz \
+    file://0001-configure.ac-add-sysroot-path-to-GI_DATADIR-don-t-se.patch \
+"
+
+SRC_URI[md5sum] = "3bac63c86bb963aa401f97859464aa90"
+SRC_URI[sha256sum] = "3dd3e21015d06e00482ea665fc1733b77e754a6ab656a5db5d7f7bfaf31ad0b0"
+
+S = "${WORKDIR}/${SRCNAME}-${PV}"
+
+BBCLASSEXTEND = "native"
+
+EXTRA_OECONF = "--disable-cairo --with-python=${PYTHON}"
+
+RDEPENDS_${PN} += "python-setuptools"
+RDEPENDS_${PN}_class-native = ""
+
+do_install_append() {
+    # Remove files that clash with python3-pygobject; their content is same
+    rm -rf ${D}${includedir}/pygobject-3.0//pygobject.h ${D}${libdir}/pkgconfig
+}
diff --git a/meta-openembedded/meta-oe/recipes-devtools/python/python3-distutils-extra.bb b/meta-openembedded/meta-oe/recipes-devtools/python/python3-distutils-extra.bb
index af242b8..5836b09 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/python/python3-distutils-extra.bb
+++ b/meta-openembedded/meta-oe/recipes-devtools/python/python3-distutils-extra.bb
@@ -4,8 +4,6 @@
 
 S = "${WORKDIR}/python-distutils-extra-${PV}"
 
-DISTUTILS_INSTALL_ARGS += "--install-lib=${libdir}/${PYTHON_DIR}/site-packages"
-
 RDEPENDS_${PN} = "\
     python3-setuptools \
 "
diff --git a/meta-openembedded/meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb b/meta-openembedded/meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb
index 8ab35d2..c90eab0 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb
+++ b/meta-openembedded/meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb
@@ -4,11 +4,9 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://license.txt;md5=ba04aa8f65de1396a7e59d1d746c2125"
 
-SRC_URI = "git://github.com/miloyip/rapidjson.git;nobranch=1 \
-           file://remove-march-native-from-CMAKE_CXX_FLAGS.patch \
-"
+SRC_URI = "git://github.com/miloyip/rapidjson.git;nobranch=1"
 
-SRCREV = "e5635fb27feab7f6e8d7b916aa20ad799045a641"
+SRCREV = "6a905f9311f82d306da77bd963ec5aa5da07da9c"
 
 PV = "1.1.0+git${SRCPV}"
 
@@ -20,7 +18,6 @@
 
 # RapidJSON is a header-only C++ library, so the main package will be empty.
 
-FILES_${PN}-dev += "${libdir}/cmake"
-RDEPENDS_${PN}-dev = ""
+ALLOW_EMPTY_${PN} = "1"
 
 BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/sip/sip.inc b/meta-openembedded/meta-oe/recipes-devtools/sip/sip.inc
new file mode 100644
index 0000000..d079545
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/sip/sip.inc
@@ -0,0 +1,36 @@
+SUMMARY = "SIP is a C++/Python Wrapper Generator"
+HOMEPAGE = "http://www.riverbankcomputing.co.uk/sip"
+SECTION = "devel"
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://LICENSE-GPL2;md5=e91355d8a6f8bd8f7c699d62863c7303"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/project/pyqt/sip/sip-${PV}/sip-${PV}.tar.gz \
+          "
+SRC_URI[md5sum] = "9124cb8978742685747a5415179a9890"                           
+SRC_URI[sha256sum] = "e353a7056599bf5fbd5d3ff9842a6ab2ea3cf4e0304a0f925ec5862907c0d15e"
+
+S = "${WORKDIR}/sip-${PV}"
+
+BBCLASSEXTEND = "native"
+
+do_configure_prepend_class-target() {
+    echo "py_platform = linux" > sip.cfg
+    echo "py_inc_dir = %(sysroot)/${includedir}/python${PYTHON_BASEVERSION}${PYTHON_ABI}" >> sip.cfg
+    echo "sip_bin_dir = ${D}/${bindir}" >> sip.cfg
+    echo "sip_inc_dir = ${D}/${includedir}" >> sip.cfg
+    echo "sip_module_dir = ${D}/${libdir}/python${PYTHON_BASEVERSION}${PYTHON_ABI}/site-packages" >> sip.cfg
+    echo "sip_sip_dir = ${D}/${datadir}/sip" >> sip.cfg
+    ${PYTHON} configure.py --configuration sip.cfg --sip-module PyQt5.sip --sysroot ${STAGING_DIR_HOST} CC="${CC}" CXX="${CXX}" LINK="${CXX}" STRIP="" LINK_SHLIB="${CXX}" CFLAGS="${CFLAGS}" CXXFLAGS="${CXXFLAGS}" LFLAGS="${LDFLAGS}"
+}
+do_configure_prepend_class-native() {
+    echo "py_platform = linux" > sip.cfg
+    echo "py_inc_dir = ${includedir}/python${PYTHON_BASEVERSION}${PYTHON_ABI}" >> sip.cfg
+    echo "sip_bin_dir = ${D}/${bindir}" >> sip.cfg
+    echo "sip_inc_dir = ${D}/${includedir}" >> sip.cfg
+    echo "sip_module_dir = ${D}/${libdir}/python${PYTHON_BASEVERSION}${PYTHON_ABI}/site-packages" >> sip.cfg
+    echo "sip_sip_dir = ${D}/${datadir}/sip" >> sip.cfg
+    ${PYTHON} configure.py --configuration sip.cfg --sip-module PyQt5.sip --sysroot=${STAGING_DIR_NATIVE}
+}
+do_install() {
+    oe_runmake install
+}
diff --git a/meta-openembedded/meta-oe/recipes-devtools/sip/sip3_4.19.13.bb b/meta-openembedded/meta-oe/recipes-devtools/sip/sip3_4.19.13.bb
new file mode 100644
index 0000000..dc15bc2
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/sip/sip3_4.19.13.bb
@@ -0,0 +1,11 @@
+require sip.inc
+
+DEPENDS = "python3"
+
+inherit python3-dir python3native
+
+PACKAGES += "python3-sip3"
+
+FILES_python3-sip3 = "${libdir}/${PYTHON_DIR}${PYTHON_ABI}/site-packages/"
+FILES_${PN}-dbg += "${libdir}/${PYTHON_DIR}${PYTHON_ABI}/site-packages/.debug"
+
diff --git a/meta-openembedded/meta-oe/recipes-devtools/sip/sip_4.19.13.bb b/meta-openembedded/meta-oe/recipes-devtools/sip/sip_4.19.13.bb
new file mode 100644
index 0000000..3da15b8
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/sip/sip_4.19.13.bb
@@ -0,0 +1,11 @@
+require sip.inc
+
+DEPENDS = "python"
+
+inherit python-dir pythonnative
+
+PACKAGES += "python-sip"
+
+FILES_python-sip = "${libdir}/${PYTHON_DIR}/site-packages/"
+FILES_${PN}-dbg += "${libdir}/${PYTHON_DIR}/site-packages/.debug"
+
diff --git a/meta-openembedded/meta-oe/recipes-devtools/sip/sip_4.19.8.bb b/meta-openembedded/meta-oe/recipes-devtools/sip/sip_4.19.8.bb
deleted file mode 100644
index ea944b3..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/sip/sip_4.19.8.bb
+++ /dev/null
@@ -1,42 +0,0 @@
-SUMMARY = "SIP is a C++/Python Wrapper Generator"
-HOMEPAGE = "http://www.riverbankcomputing.co.uk/sip"
-SECTION = "devel"
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://LICENSE-GPL2;md5=e91355d8a6f8bd8f7c699d62863c7303"
-
-inherit python-dir
-
-DEPENDS = "python"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/project/pyqt/sip/sip-${PV}/sip-${PV}.tar.gz"
-SRC_URI[md5sum] = "0625fb20347d4ff1b5da551539be0727"
-SRC_URI[sha256sum] = "7eaf7a2ea7d4d38a56dd6d2506574464bddf7cf284c960801679942377c297bc"
-
-BBCLASSEXTEND = "native"
-
-PACKAGES += "python-sip"
-
-do_configure_prepend_class-target() {
-    echo "py_platform = linux" > sip.cfg
-    echo "py_inc_dir = %(sysroot)/${includedir}/python%(py_major).%(py_minor)" >> sip.cfg
-    echo "sip_bin_dir = ${D}/${bindir}" >> sip.cfg
-    echo "sip_inc_dir = ${D}/${includedir}" >> sip.cfg
-    echo "sip_module_dir = ${D}/${libdir}/python%(py_major).%(py_minor)/site-packages" >> sip.cfg
-    echo "sip_sip_dir = ${D}/${datadir}/sip" >> sip.cfg
-    python configure.py --configuration sip.cfg --sysroot ${STAGING_DIR_HOST} CC="${CC}" CXX="${CXX}" LINK="${CXX}" STRIP="" LINK_SHLIB="${CXX}" CFLAGS="${CFLAGS}" CXXFLAGS="${CXXFLAGS}" LFLAGS="${LDFLAGS}"
-}
-do_configure_prepend_class-native() {
-    echo "py_platform = linux" > sip.cfg
-    echo "py_inc_dir = ${includedir}/python%(py_major).%(py_minor)" >> sip.cfg
-    echo "sip_bin_dir = ${D}/${bindir}" >> sip.cfg
-    echo "sip_inc_dir = ${D}/${includedir}" >> sip.cfg
-    echo "sip_module_dir = ${D}/${libdir}/python%(py_major).%(py_minor)/site-packages" >> sip.cfg
-    echo "sip_sip_dir = ${D}/${datadir}/sip" >> sip.cfg
-    python configure.py --configuration sip.cfg --sysroot ${STAGING_DIR_NATIVE}
-}
-do_install() {
-    oe_runmake install
-}
-
-FILES_python-sip = "${libdir}/${PYTHON_DIR}/site-packages/"
-FILES_${PN}-dbg += "${libdir}/${PYTHON_DIR}/site-packages/.debug"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/tclap/tclap_1.2.1.bb b/meta-openembedded/meta-oe/recipes-devtools/tclap/tclap_1.2.1.bb
deleted file mode 100644
index 3eadbe4..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/tclap/tclap_1.2.1.bb
+++ /dev/null
@@ -1,16 +0,0 @@
-SUMMARY = "Templatized C++ Command Line Parser"
-HOMEPAGE = "http://tclap.sourceforge.net/"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=c8ab0ff134bcc584d0e6b5b9f8732453"
-
-SRCREV = "3627d9402e529770df9b0edf2aa8c0e0d6c6bb41"
-SRC_URI = "git://git.code.sf.net/p/tclap/code \
-    file://Makefile.am-disable-docs.patch \
-"
-
-S = "${WORKDIR}/git"
-inherit autotools
-
-ALLOW_EMPTY_${PN} = "1"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/tclap/tclap_1.2.2.bb b/meta-openembedded/meta-oe/recipes-devtools/tclap/tclap_1.2.2.bb
new file mode 100644
index 0000000..46a9408
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/tclap/tclap_1.2.2.bb
@@ -0,0 +1,16 @@
+SUMMARY = "Templatized C++ Command Line Parser"
+HOMEPAGE = "http://tclap.sourceforge.net/"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=0ca8b9c5c5445cfa7af7e78fd27e60ed"
+
+SRCREV = "75f440bcac1276c847f5351e14216f6e91def44d"
+SRC_URI = "git://git.code.sf.net/p/tclap/code \
+    file://Makefile.am-disable-docs.patch \
+"
+
+S = "${WORKDIR}/git"
+inherit autotools
+
+ALLOW_EMPTY_${PN} = "1"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/tcltk/tk_8.6.8.bb b/meta-openembedded/meta-oe/recipes-devtools/tcltk/tk_8.6.8.bb
index 13dc4d7..4e38525 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/tcltk/tk_8.6.8.bb
+++ b/meta-openembedded/meta-oe/recipes-devtools/tcltk/tk_8.6.8.bb
@@ -42,22 +42,14 @@
 EXTRA_OECONF = "\
     --enable-threads \
     --with-x \
-    --with-tcl=${STAGING_BINDIR_CROSS} \
+    --with-tcl=${STAGING_BINDIR}/crossscripts \
     --libdir=${libdir} \
 "
-
+export TK_LIBRARY='${libdir}/tk${VER}'
 do_install_append() {
     ln -sf libtk${VER}.so ${D}${libdir}/libtk${VER}.so.0
     oe_libinstall -so libtk${VER} ${D}${libdir}
     ln -sf wish${VER} ${D}${bindir}/wish
-
-    # Even after passing libdir=${libdir} at config, some incorrect dirs are still generated for the multilib build
-    if [ "$libdir" != "/usr/lib" ]; then
-        # Move files to correct library directory
-        mv ${D}/usr/lib/tk${VER}/* ${D}/${libdir}/tk${VER}/
-        # Remove unneeded/incorrect dir ('usr/lib/')
-        rm -rf ${D}/usr/lib
-    fi
 }
 
 PACKAGECONFIG ??= "xft"
@@ -73,7 +65,7 @@
 RDEPENDS_${PN} += "tk-lib"
 RDEPENDS_${PN}_class-native = ""
 
-BBCLASSEXTEND = "native"
+BBCLASSEXTEND = "native nativesdk"
 
 # Fix the path in sstate
 SSTATE_SCAN_FILES += "*Config.sh"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/uftrace/uftrace/0001-include-dlfcn.h-for-RTLD_DEFAULT.patch b/meta-openembedded/meta-oe/recipes-devtools/uftrace/uftrace/0001-include-dlfcn.h-for-RTLD_DEFAULT.patch
new file mode 100644
index 0000000..fe7aac9
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/uftrace/uftrace/0001-include-dlfcn.h-for-RTLD_DEFAULT.patch
@@ -0,0 +1,39 @@
+From cdf7f2e394fcfb93a61f509ae3388f29540a6b35 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 8 Sep 2018 11:56:13 -0700
+Subject: [PATCH] include dlfcn.h for RTLD_DEFAULT
+
+Fixes
+plthook.c:128:41: error: use of undeclared identifier 'RTLD_DEFAULT'
+
+Upstream-Status: Submitted [https://github.com/namhyung/uftrace/pull/487]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ libmcount/plthook.c | 1 +
+ utils/debug.c       | 1 +
+ 2 files changed, 2 insertions(+)
+
+diff --git a/libmcount/plthook.c b/libmcount/plthook.c
+index d9d84f0..d54f5e8 100644
+--- a/libmcount/plthook.c
++++ b/libmcount/plthook.c
+@@ -6,6 +6,7 @@
+ #include <sys/mman.h>
+ #include <pthread.h>
+ #include <assert.h>
++#include <dlfcn.h>
+ 
+ /* This should be defined before #include "utils.h" */
+ #define PR_FMT     "mcount"
+diff --git a/utils/debug.c b/utils/debug.c
+index 2134b09..5460def 100644
+--- a/utils/debug.c
++++ b/utils/debug.c
+@@ -13,6 +13,7 @@
+ #include <assert.h>
+ #include <limits.h>
+ #include <inttypes.h>
++#include <dlfcn.h>
+ 
+ #include "utils/utils.h"
+ 
diff --git a/meta-openembedded/meta-oe/recipes-devtools/uftrace/uftrace_0.8.3.bb b/meta-openembedded/meta-oe/recipes-devtools/uftrace/uftrace_0.8.3.bb
new file mode 100644
index 0000000..ca38e6a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/uftrace/uftrace_0.8.3.bb
@@ -0,0 +1,44 @@
+SUMMARY = "Trace and analyze execution of a program written in C/C++"
+HOMEPAGE = "https://github.com/namhyung/uftrace"
+BUGTRACKER = "https://github.com/namhyung/uftrace/issues"
+SECTION = "devel"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+DEPENDS = "elfutils"
+DEPENDS_append_libc-musl = " argp-standalone"
+
+inherit autotools
+
+# v0.8.3
+SRCREV = "8b723a6fae2ef30495cd6279774fba9c95cd9c88"
+SRC_URI = "git://github.com/namhyung/${BPN} \
+           file://0001-include-dlfcn.h-for-RTLD_DEFAULT.patch \
+           "
+S = "${WORKDIR}/git"
+
+LDFLAGS_append_libc-musl = " -largp"
+
+def set_target_arch(d):
+    import re
+    arch = d.getVar('TARGET_ARCH', True)
+    if re.match(r'i.86', arch, re.I):
+        return 'i386'
+    else:
+        return arch
+
+EXTRA_UFTRACE_OECONF = "ARCH=${@set_target_arch(d)} \
+                        with_elfutils=/use/libelf/from/sysroot"
+
+do_configure() {
+    ${S}/configure ${EXTRA_UFTRACE_OECONF}
+}
+
+FILES_SOLIBSDEV = ""
+FILES_${PN} += "${libdir}/*.so"
+
+COMPATIBLE_HOST = "(i.86|x86_64|aarch64|arm)"
+
+# uftrace supports armv6 and above
+COMPATIBLE_HOST_armv4 = 'null'
+COMPATIBLE_HOST_armv5 = 'null'
diff --git a/meta-openembedded/meta-oe/recipes-devtools/uftrace/uftrace_0.8.bb b/meta-openembedded/meta-oe/recipes-devtools/uftrace/uftrace_0.8.bb
deleted file mode 100644
index 82b1795..0000000
--- a/meta-openembedded/meta-oe/recipes-devtools/uftrace/uftrace_0.8.bb
+++ /dev/null
@@ -1,31 +0,0 @@
-SUMMARY = "Trace and analyze execution of a program written in C/C++"
-HOMEPAGE = "https://github.com/namhyung/uftrace"
-BUGTRACKER = "https://github.com/namhyung/uftrace/issues"
-SECTION = "devel"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-
-DEPENDS = "elfutils"
-DEPENDS_append_libc-musl = " argp-standalone"
-
-inherit autotools
-
-SRCREV = "5af9ff9fa89c340617e52c8ed05798b352a7145c"
-SRC_URI = "git://github.com/namhyung/${BPN}"
-S = "${WORKDIR}/git"
-
-LDFLAGS_append_libc-musl = " -largp"
-EXTRA_OECONF = "ARCH=${TARGET_ARCH}"
-
-do_configure() {
-    ${S}/configure ${EXTRA_OECONF}
-}
-
-FILES_SOLIBSDEV = ""
-FILES_${PN} += "${libdir}/*.so"
-
-COMPATIBLE_HOST = "(x86_64|aarch64|arm)"
-
-# uftrace supports armv6 and above
-COMPATIBLE_HOST_armv4 = 'null'
-COMPATIBLE_HOST_armv5 = 'null'
diff --git a/meta-openembedded/meta-oe/recipes-devtools/uw-imap/uw-imap/0001-Support-OpenSSL-1.1.patch b/meta-openembedded/meta-oe/recipes-devtools/uw-imap/uw-imap/0001-Support-OpenSSL-1.1.patch
new file mode 100644
index 0000000..d5610bb
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/uw-imap/uw-imap/0001-Support-OpenSSL-1.1.patch
@@ -0,0 +1,71 @@
+From 4c684542816a08b95444b8e2515f24d084e6e3c3 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 4 Sep 2018 22:05:17 -0700
+Subject: [PATCH] Support OpenSSL 1.1
+
+When building with OpenSSL 1.1 and newer, use the new built-in
+ hostname verification instead of code that doesn't compile due to
+ structs having been made opaque.
+Bug-Debian: https://bugs.debian.org/828589
+
+Upstream-Status: Unknown
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/osdep/unix/ssl_unix.c | 14 +++++++++++++-
+ 1 file changed, 13 insertions(+), 1 deletion(-)
+
+diff --git a/src/osdep/unix/ssl_unix.c b/src/osdep/unix/ssl_unix.c
+index 3bfdff3..dec9467 100644
+--- a/src/osdep/unix/ssl_unix.c
++++ b/src/osdep/unix/ssl_unix.c
+@@ -227,8 +227,16 @@ static char *ssl_start_work (SSLSTREAM *stream,char *host,unsigned long flags)
+ 				/* disable certificate validation? */
+   if (flags & NET_NOVALIDATECERT)
+     SSL_CTX_set_verify (stream->context,SSL_VERIFY_NONE,NIL);
+-  else SSL_CTX_set_verify (stream->context,SSL_VERIFY_PEER,ssl_open_verify);
++  else {
++#if OPENSSL_VERSION_NUMBER >= 0x10100000      
++      X509_VERIFY_PARAM *param = SSL_CTX_get0_param(stream->context);
++      X509_VERIFY_PARAM_set_hostflags(param, X509_CHECK_FLAG_NO_PARTIAL_WILDCARDS);
++      X509_VERIFY_PARAM_set1_host(param, host, 0);
++#endif
++
++      SSL_CTX_set_verify (stream->context,SSL_VERIFY_PEER,ssl_open_verify);
+ 				/* set default paths to CAs... */
++  }
+   SSL_CTX_set_default_verify_paths (stream->context);
+ 				/* ...unless a non-standard path desired */
+   if (s = (char *) mail_parameters (NIL,GET_SSLCAPATH,NIL))
+@@ -266,6 +274,7 @@ static char *ssl_start_work (SSLSTREAM *stream,char *host,unsigned long flags)
+   if (SSL_write (stream->con,"",0) < 0)
+     return ssl_last_error ? ssl_last_error : "SSL negotiation failed";
+ 				/* need to validate host names? */
++#if OPENSSL_VERSION_NUMBER < 0x10100000
+   if (!(flags & NET_NOVALIDATECERT) &&
+       (err = ssl_validate_cert (cert = SSL_get_peer_certificate (stream->con),
+ 				host))) {
+@@ -275,6 +284,7 @@ static char *ssl_start_work (SSLSTREAM *stream,char *host,unsigned long flags)
+     sprintf (tmp,"*%.128s: %.255s",err,cert ? cert->name : "???");
+     return ssl_last_error = cpystr (tmp);
+   }
++#endif
+   return NIL;
+ }
+ 
+@@ -313,6 +323,7 @@ static int ssl_open_verify (int ok,X509_STORE_CTX *ctx)
+  * Returns: NIL if validated, else string of error message
+  */
+ 
++#if OPENSSL_VERSION_NUMBER < 0x10100000
+ static char *ssl_validate_cert (X509 *cert,char *host)
+ {
+   int i,n;
+@@ -342,6 +353,7 @@ static char *ssl_validate_cert (X509 *cert,char *host)
+   else ret = "Unable to locate common name in certificate";
+   return ret;
+ }
++#endif
+ 
+ /* Case-independent wildcard pattern match
+  * Accepts: base string
diff --git a/meta-openembedded/meta-oe/recipes-devtools/uw-imap/uw-imap_2007f.bb b/meta-openembedded/meta-oe/recipes-devtools/uw-imap/uw-imap_2007f.bb
index 91003f6..0000f05 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/uw-imap/uw-imap_2007f.bb
+++ b/meta-openembedded/meta-oe/recipes-devtools/uw-imap/uw-imap_2007f.bb
@@ -4,12 +4,13 @@
 LICENSE = "Apache-2.0"
 LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=a6a4ddbb7cd2999f6827ee143f6fcd97"
 
-DEPENDS = "openssl"
+DEPENDS = "openssl virtual/crypt"
 
 SRC_URI = "https://fossies.org/linux/misc/old/imap-${PV}.tar.gz \
            file://quote_cctype.patch \
            file://imap-2007e-shared.patch \
            file://imap-2007f-format-security.patch \
+           file://0001-Support-OpenSSL-1.1.patch \
            "
 
 SRC_URI[md5sum] = "2126fd125ea26b73b20f01fcd5940369"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/xerces-c/xerces-c_3.1.4.bb b/meta-openembedded/meta-oe/recipes-devtools/xerces-c/xerces-c_3.1.4.bb
index 64ac747..0951307 100644
--- a/meta-openembedded/meta-oe/recipes-devtools/xerces-c/xerces-c_3.1.4.bb
+++ b/meta-openembedded/meta-oe/recipes-devtools/xerces-c/xerces-c_3.1.4.bb
@@ -9,7 +9,7 @@
 LICENSE = "Apache-2.0"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
 
-SRC_URI = "http://apache.lauf-forum.at/xerces/c/3/sources/${BP}.tar.bz2"
+SRC_URI = "http://archive.apache.org/dist/xerces/c/3/sources/${BP}.tar.bz2"
 SRC_URI[md5sum] = "d04ae9d8b2dee2157c6db95fa908abfd"
 SRC_URI[sha256sum] = "9408f12c1628ecf80730bedbe8b2caad810edd01bb4c66f77b60c873e8cc6891"
 
@@ -24,24 +24,21 @@
 }
 
 PACKAGES = "libxerces-c \
-    libxerces-c-dbg \
     libxerces-c-dev \
     xerces-c-samples \
-    xerces-c-samples-dbg \
     libxerces-c-staticdev \
+    ${PN}-dbg \
 "
 
+RPROVIDES_${PN}-dbg += "libxerces-c-dbg xerces-c-samples-dbg"
+
 FILES_libxerces-c = "${libdir}/libxerces-c-3.1.so"
-FILES_libxerces-c-dbg = "${libdir}/.debug \
-    ${prefix}/src/debug \
-"
 FILES_libxerces-c-dev = "${libdir}/lib*.la \
     ${libdir}/libxerces-c.so \
     ${libdir}/pkgconfig/xerces-c.pc \
     ${includedir}/xercesc \
 "
 FILES_xerces-c-samples = "${bindir}/*"
-FILES_xerces-c-samples-dbg = "${bindir}/.debug/"
 FILES_libxerces-c-staticdev = "${libdir}/lib*.a"
 
 BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-devtools/yasm/yasm_git.bb b/meta-openembedded/meta-oe/recipes-devtools/yasm/yasm_git.bb
new file mode 100644
index 0000000..b20d4c0
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-devtools/yasm/yasm_git.bb
@@ -0,0 +1,22 @@
+SUMMARY = "x86 (SSE) assembler supporting NASM and GAS-syntaxes"
+LICENSE = "BSD"
+HOMEPAGE = "http://www.tortall.net/projects/yasm/"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=a12d8903508fb6bfd49d8d82c6170dd9"
+
+DEPENDS += "flex-native bison-native xmlto-native"
+
+PV = "1.3.0+git${SRCPV}"
+# v1.3.0
+SRCREV = "ba463d3c26c0ece2e797b8d6381b161633b5971a"
+SRC_URI = "git://github.com/yasm/yasm.git"
+
+S = "${WORKDIR}/git"
+
+inherit autotools gettext pythonnative
+
+CACHED_CONFIGUREVARS = "CCLD_FOR_BUILD='${CC_FOR_BUILD}'"
+
+BBCLASSEXTEND = "native"
+
+PARALLEL_MAKE = ""
diff --git a/meta-openembedded/meta-oe/recipes-extended/boinc/boinc-client/cross-compile.patch b/meta-openembedded/meta-oe/recipes-extended/boinc/boinc-client/cross-compile.patch
deleted file mode 100644
index 287391a..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/boinc/boinc-client/cross-compile.patch
+++ /dev/null
@@ -1,98 +0,0 @@
-Remove rpath, its bad for cross compiling to encode
-build time rpaths
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Upstream-Status: Pending
-
-Index: boinc-client_release-7.6-7.6.33/api/Makefile.am
-===================================================================
---- boinc-client_release-7.6-7.6.33.orig/api/Makefile.am
-+++ boinc-client_release-7.6-7.6.33/api/Makefile.am
-@@ -43,18 +43,18 @@ endif
- 
- lib_LTLIBRARIES = libboinc_api.la
- libboinc_api_la_SOURCES = $(api_files)
--libboinc_api_la_LDFLAGS = -L$(libdir) -rpath $(libdir) -version-number $(LIBBOINC_VERSION)
-+libboinc_api_la_LDFLAGS = -version-number $(LIBBOINC_VERSION)
- 
- if BUILD_GRAPHICS_API
- lib_LTLIBRARIES += libboinc_graphics2.la
- libboinc_graphics2_la_SOURCES = $(graphics2_files)
- libboinc_graphics2_la_CPPFLAGS = -I$(top_srcdir) -I$(top_srcdir)/lib -I$(top_srcdir)/samples/image_libs
--libboinc_graphics2_la_LDFLAGS = -L$(libdir) -rpath $(libdir) -version-number $(LIBBOINC_VERSION) -ljpeg
-+libboinc_graphics2_la_LDFLAGS = -version-number $(LIBBOINC_VERSION) -ljpeg
- endif #BUILD_GRAPHICS_API
- 
- lib_LTLIBRARIES += libboinc_opencl.la
- libboinc_opencl_la_SOURCES = $(opencl_files)
--libboinc_opencl_la_LDFLAGS = -L$(libdir) -rpath $(libdir) -version-number $(LIBBOINC_VERSION)
-+libboinc_opencl_la_LDFLAGS = -version-number $(LIBBOINC_VERSION)
- 
- if INSTALL_HEADERS
- ## install only headers that are meant for exporting the API !!
-Index: boinc-client_release-7.6-7.6.33/lib/Makefile.am
-===================================================================
---- boinc-client_release-7.6-7.6.33.orig/lib/Makefile.am
-+++ boinc-client_release-7.6-7.6.33/lib/Makefile.am
-@@ -173,7 +173,7 @@ lib_LTLIBRARIES = libboinc.la
- libboinc_la_SOURCES = $(generic_sources) $(mac_sources) $(win_sources)
- libboinc_la_CFLAGS = $(AM_CFLAGS) $(PICFLAGS) $(PTHREAD_CFLAGS)
- libboinc_la_CXXFLAGS = $(AM_CXXFLAGS) $(PICFLAGS) $(PTHREAD_CFLAGS)
--libboinc_la_LDFLAGS = -L$(libdir) -rpath $(libdir) -static -version-number $(LIBBOINC_VERSION)
-+libboinc_la_LDFLAGS = -static -version-number $(LIBBOINC_VERSION)
- libboinc_la_LIBADD =
- 
- if ENABLE_BOINCCRYPT
-@@ -181,7 +181,7 @@ lib_LTLIBRARIES += libboinc_crypt.la
- libboinc_crypt_la_SOURCES = crypt.cpp
- libboinc_crypt_la_CFLAGS = $(AM_CFLAGS) $(PICFLAGS) $(PTHREAD_CFLAGS) $(SSL_CFLAGS)
- libboinc_crypt_la_CXXFLAGS = $(AM_CXXFLAGS) $(PICFLAGS) $(PTHREAD_CFLAGS) $(SSL_CXXFLAGS)
--libboinc_crypt_la_LDFLAGS = -L$(libdir) -rpath $(libdir) -static -version-number $(LIBBOINC_VERSION)
-+libboinc_crypt_la_LDFLAGS = -static -version-number $(LIBBOINC_VERSION)
- libboinc_crypt_la_LIBADD =
- endif
- 
-@@ -190,7 +190,7 @@ lib_LTLIBRARIES += libboinc_fcgi.la
- libboinc_fcgi_la_SOURCES = $(libfcgi_sources) $(mac_sources) $(win_sources)
- libboinc_fcgi_la_CFLAGS = -D_USING_FCGI_ $(AM_CFLAGS) $(PICFLAGS) $(PTHREAD_CFLAGS)
- libboinc_fcgi_la_CXXFLAGS = -D_USING_FCGI_ $(AM_CXXFLAGS) $(PICFLAGS) $(PTHREAD_CFLAGS)
--libboinc_fcgi_la_LDFLAGS = -L$(libdir) -rpath $(libdir) -version-number $(LIBBOINC_VERSION)
-+libboinc_fcgi_la_LDFLAGS = -version-number $(LIBBOINC_VERSION)
- libboinc_fcgi_la_LIBADD =
- endif 
- # end of "if ENABLE_FCGI"
-Index: boinc-client_release-7.6-7.6.33/sched/Makefile.am
-===================================================================
---- boinc-client_release-7.6-7.6.33.orig/sched/Makefile.am
-+++ boinc-client_release-7.6-7.6.33/sched/Makefile.am
-@@ -26,7 +26,7 @@ lib_LTLIBRARIES = libsched.la
- libsched_la_SOURCES = $(libsched_sources)
- libsched_la_CFLAGS = $(AM_CPPFLAGS)
- libsched_la_CXXFLAGS = $(AM_CPPFLAGS)
--libsched_la_LDFLAGS= -L$(libdir) -rpath $(libdir) -version-number $(LIBBOINC_VERSION)
-+libsched_la_LDFLAGS= -version-number $(LIBBOINC_VERSION)
- libsched_la_LIBADD= $(SSL_LIBS)
- 
- ## install only headers that are meant for exporting the API !!
-@@ -48,7 +48,7 @@ lib_LTLIBRARIES += libsched_fcgi.la
- libsched_fcgi_la_SOURCES = $(libsched_sources)
- libsched_fcgi_la_CFLAGS = -D_USING_FCGI_ $(AM_CPPFLAGS)
- libsched_fcgi_la_CXXFLAGS = -D_USING_FCGI_ $(AM_CPPFLAGS)
--libsched_fcgi_la_LDFLAGS= -L$(libdir) -rpath $(libdir) -version-number $(LIBBOINC_VERSION)
-+libsched_fcgi_la_LDFLAGS= -version-number $(LIBBOINC_VERSION)
- libsched_fcgi_la_LIBADD=
- 
- endif
-Index: boinc-client_release-7.6-7.6.33/zip/Makefile.am
-===================================================================
---- boinc-client_release-7.6-7.6.33.orig/zip/Makefile.am
-+++ boinc-client_release-7.6-7.6.33/zip/Makefile.am
-@@ -61,7 +61,7 @@ endif
- 
- lib_LTLIBRARIES = libboinc_zip.la
- libboinc_zip_la_SOURCES = $(libboinc_zip_sources)
--libboinc_zip_la_LDFLAGS = -L$(libdir) -rpath $(libdir) -version-number $(LIBBOINC_VERSION)
-+libboinc_zip_la_LDFLAGS = -version-number $(LIBBOINC_VERSION)
- libboinc_zip_la_LIBADD =
- 
- # Some OSs may not prefix libraries with lib.
diff --git a/meta-openembedded/meta-oe/recipes-extended/boinc/boinc-client_7.12.bb b/meta-openembedded/meta-oe/recipes-extended/boinc/boinc-client_7.12.bb
new file mode 100644
index 0000000..e505bb4
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/boinc/boinc-client_7.12.bb
@@ -0,0 +1,87 @@
+# Copyright (C) 2016 Khem Raj <raj.khem@gmail.com>
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+SUMMARY = "Open-source software for volunteer computing"
+DESCRIPTION = "The Berkeley Open Infrastructure for Network Computing (BOINC) is an open- \
+source software platform which supports distributed computing, primarily in \
+the form of volunteer computing and desktop Grid computing.  It is well \
+suited for problems which are often described as trivially parallel.  BOINC \
+is the underlying software used by projects such as SETI@home, Einstein@Home, \
+ClimatePrediciton.net, the World Community Grid, and many other distributed \
+computing projects. \
+This package installs the BOINC client software, which will allow your \
+computer to participate in one or more BOINC projects, using your spare \
+computer time to search for cures for diseases, model protein folding, study \
+global warming, discover sources of gravitational waves, and many other types \
+of scientific and mathematical research."
+
+HOMEPAGE = "http://boinc.berkeley.edu/"
+LICENSE = "LGPLv2+ & GPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
+                    file://COPYING.LESSER;md5=6a6a8e020838b23406c81b19c1d46df6"
+SECTION = "applications"
+DEPENDS = "curl \
+           jpeg \
+           openssl \
+           sqlite3 \
+           virtual/libgl \
+           ${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'libnotify', '', d)} \
+           ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'gtk+ libnotify xcb-util libxscrnsaver', '', d)} \
+           nettle \
+"
+SRCREV = "bd12338dbd29083daa5a4b022592ca31ff68cd98"
+BRANCH = "client_release/7/${PV}"
+SRC_URI = "git://github.com/BOINC/boinc;protocol=https;branch=${BRANCH} \
+           file://boinc-AM_CONDITIONAL.patch \
+           file://opengl_m4_check.patch \
+           file://gtk-configure.patch \
+"
+
+inherit gettext autotools pkgconfig distro_features_check systemd
+
+REQUIRED_DISTRO_FEATURES += "opengl"
+
+S = "${WORKDIR}/git"
+
+EXTRA_OECONF += "\
+    --enable-libraries \
+    --enable-unicode \
+    --enable-shared \
+    --enable-dynamic-client-linkage \
+    --enable-client \
+    --disable-server \
+    --disable-static \
+    --disable-manager \
+    --with-ssl=${STAGING_EXECPREFIXDIR} \
+    --without-wxdir \
+    --without-x \
+    --with-boinc-platform=${TARGET_SYS} \
+"
+export PKG_CONFIG = "${STAGING_BINDIR_NATIVE}/pkg-config"
+
+do_configure_prepend () {
+	if "${@bb.utils.contains('DEPENDS', 'gtk+', '1', '0', d)}" = "0"
+	then
+		export GTK2_CFLAGS=""
+		export GTK2_LIBS=""
+	fi
+}
+
+do_compile_prepend () {
+	# Disable rpaths
+	sed -i -e 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' ${B}/${TARGET_SYS}-libtool
+	sed -i -e 's|^sys_lib_dlsearch_path_spec=.*|sys_lib_dlsearch_path_spec=""|g' ${B}/${TARGET_SYS}-libtool
+	sed -i -e 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' ${B}/${TARGET_SYS}-libtool
+}
+do_install_append() {
+	if [ -e ${D}${libdir}/systemd/system/boinc-client.service ]; then
+		install -D -m 0644 \
+		${D}${libdir}/systemd/system/boinc-client.service \
+		${D}${systemd_system_unitdir}/boinc-client.service
+		rm -rf ${D}${libdir}/systemd
+	fi
+}
+
+SYSTEMD_SERVICE_${PN} = "boinc-client.service"
+
+FILES_${PN} += "${libdir}/systemd"
diff --git a/meta-openembedded/meta-oe/recipes-extended/boinc/boinc-client_7.6.33.bb b/meta-openembedded/meta-oe/recipes-extended/boinc/boinc-client_7.6.33.bb
deleted file mode 100644
index 99b43fa..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/boinc/boinc-client_7.6.33.bb
+++ /dev/null
@@ -1,79 +0,0 @@
-# Copyright (C) 2016 Khem Raj <raj.khem@gmail.com>
-# Released under the MIT license (see COPYING.MIT for the terms)
-
-SUMMARY = "Open-source software for volunteer computing"
-DESCRIPTION = "The Berkeley Open Infrastructure for Network Computing (BOINC) is an open- \
-source software platform which supports distributed computing, primarily in \
-the form of volunteer computing and desktop Grid computing.  It is well \
-suited for problems which are often described as trivially parallel.  BOINC \
-is the underlying software used by projects such as SETI@home, Einstein@Home, \
-ClimatePrediciton.net, the World Community Grid, and many other distributed \
-computing projects. \
-This package installs the BOINC client software, which will allow your \
-computer to participate in one or more BOINC projects, using your spare \
-computer time to search for cures for diseases, model protein folding, study \
-global warming, discover sources of gravitational waves, and many other types \
-of scientific and mathematical research."
-
-HOMEPAGE = "http://boinc.berkeley.edu/"
-LICENSE = "LGPLv2+ & GPLv3"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
-                    file://COPYING.LESSER;md5=6a6a8e020838b23406c81b19c1d46df6"
-SECTION = "applications"
-DEPENDS = "curl \
-           jpeg \
-           openssl \
-           sqlite3 \
-           virtual/libgl \
-           ${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'libnotify', '', d)} \
-           ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'gtk+ libnotify xcb-util libxscrnsaver', '', d)} \
-           nettle \
-"
-
-SRC_URI = "https://github.com/BOINC/boinc/archive/client_release/7.6/${PV}.tar.gz \
-           file://boinc-AM_CONDITIONAL.patch \
-           file://opengl_m4_check.patch \
-           file://cross-compile.patch \
-           file://gtk-configure.patch \
-"
-SRC_URI[md5sum] = "437b4b98e384b4bda4ef7056e68166ac"
-SRC_URI[sha256sum] = "c4b1c29b9655013e0ac61dddf47ad7f30f38c46159f02a9d9dc8ab854e99aa6d"
-
-inherit gettext autotools-brokensep pkgconfig distro_features_check
-
-REQUIRED_DISTRO_FEATURES += "opengl"
-
-S = "${WORKDIR}/${BPN}_release-7.6-${PV}"
-
-EXTRA_OECONF += "\
-    --enable-libraries \
-    --enable-unicode \
-    --enable-shared \
-    --enable-dynamic-client-linkage \
-    --enable-client \
-    --disable-server \
-    --disable-static \
-    --disable-manager \
-    --with-ssl=${STAGING_EXECPREFIXDIR} \
-    --without-wxdir \
-    --without-x \
-    --with-boinc-platform=${TARGET_SYS} \
-"
-export PKG_CONFIG = "${STAGING_BINDIR_NATIVE}/pkg-config"
-
-do_configure_prepend () {
-	if "${@bb.utils.contains('DEPENDS', 'gtk+', '1', '0', d)}" = "0"
-	then
-		export GTK2_CFLAGS=""
-		export GTK2_LIBS=""
-	fi
-}
-
-do_compile_prepend () {
-	# Disable rpaths
-	sed -i -e 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' ${B}/${TARGET_SYS}-libtool
-	sed -i -e 's|^sys_lib_dlsearch_path_spec=.*|sys_lib_dlsearch_path_spec=""|g' ${B}/${TARGET_SYS}-libtool
-	sed -i -e 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' ${B}/${TARGET_SYS}-libtool
-}
-
-SECURITY_CFLAGS = "${SECURITY_NO_PIE_CFLAGS}"
diff --git a/meta-openembedded/meta-oe/recipes-extended/brotli/brotli_1.0.7.bb b/meta-openembedded/meta-oe/recipes-extended/brotli/brotli_1.0.7.bb
new file mode 100644
index 0000000..b4d4773
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/brotli/brotli_1.0.7.bb
@@ -0,0 +1,14 @@
+SUMMARY = "Lossless compression library and tool"
+DESCRIPTIOM = "Brotli is a generic-purpose lossless compression algorithm \
+that it is similar in speed to deflate but offers more dense compression."
+HOMEPAGE = "https://github.com/google/brotli"
+BUGTRACKER = "https://github.com/google/brotli/issues"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${S}/LICENSE;md5=941ee9cd1609382f946352712a319b4b"
+
+SRC_URI = "git://github.com/google/brotli.git"
+# tag 1.0.7
+SRCREV= "d6d98957ca8ccb1ef45922e978bb10efca0ea541"
+S = "${WORKDIR}/git"
+
+inherit cmake lib_package
diff --git a/meta-openembedded/meta-oe/recipes-extended/byacc/byacc.inc b/meta-openembedded/meta-oe/recipes-extended/byacc/byacc.inc
index 9bdafd2..5214715 100644
--- a/meta-openembedded/meta-oe/recipes-extended/byacc/byacc.inc
+++ b/meta-openembedded/meta-oe/recipes-extended/byacc/byacc.inc
@@ -6,7 +6,7 @@
 SECTION = "devel"
 LICENSE = "PD"
 
-SRC_URI = "ftp://invisible-island.net/byacc/byacc-${PV}.tgz \
+SRC_URI = "ftp://ftp.invisible-island.net/byacc/byacc-${PV}.tgz \
            file://byacc-open.patch \
            file://0001-byacc-do-not-reorder-CC-and-CFLAGS.patch"
 
diff --git a/meta-openembedded/meta-oe/recipes-extended/byacc/byacc/0001-byacc-do-not-reorder-CC-and-CFLAGS.patch b/meta-openembedded/meta-oe/recipes-extended/byacc/byacc/0001-byacc-do-not-reorder-CC-and-CFLAGS.patch
index 7cd2510..3bc0db9 100644
--- a/meta-openembedded/meta-oe/recipes-extended/byacc/byacc/0001-byacc-do-not-reorder-CC-and-CFLAGS.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/byacc/byacc/0001-byacc-do-not-reorder-CC-and-CFLAGS.patch
@@ -9,28 +9,29 @@
 Upstream-Status: Inappropriate [OE Specific]
 
 Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+
 ---
  aclocal.m4 |   1 -
- configure  | 119 -------------------------------------------------------------
- 2 files changed, 120 deletions(-)
+ configure  | 140 -------------------------------------------------------------
+ 2 files changed, 141 deletions(-)
 
 diff --git a/aclocal.m4 b/aclocal.m4
-index 917a848..62ef241 100644
+index 0d14f26..0cefa08 100644
 --- a/aclocal.m4
 +++ b/aclocal.m4
-@@ -1021,7 +1021,6 @@ CF_GCC_VERSION
+@@ -1038,7 +1038,6 @@ CF_GCC_VERSION
  CF_ACVERSION_CHECK(2.52,
  	[AC_PROG_CC_STDC],
  	[CF_ANSI_CC_REQD])
 -CF_CC_ENV_FLAGS
  ])dnl
  dnl ---------------------------------------------------------------------------
- dnl CF_PROG_GROFF version: 2 updated: 2015/07/04 11:16:27
+ dnl CF_PROG_GROFF version: 3 updated: 2018/01/07 13:16:19
 diff --git a/configure b/configure
-index 9707e50..4f0497c 100755
+index d27ae31..077c648 100755
 --- a/configure
 +++ b/configure
-@@ -1946,125 +1946,6 @@ esac
+@@ -1946,146 +1946,6 @@ esac
  # This should have been defined by AC_PROG_CC
  : ${CC:=cc}
  
@@ -43,8 +44,9 @@
 -	{ echo "$as_me:1955: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
 -echo "$as_me: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
 -	# humor him...
--	cf_flags=`echo "$CC" | sed -e 's/^.*[ 	]\(-[^ 	]\)/\1/'`
--	CC=`echo "$CC " | sed -e 's/[ 	]-[^ 	].*$//' -e 's/[ 	]*$//'`
+-	cf_prog=`echo "$CC" | sed -e 's/	/ /g' -e 's/[ ]* / /g' -e 's/[ ]*[ ]-[^ ].*//'`
+-	cf_flags=`echo "$CC" | ${AWK:-awk} -v prog="$cf_prog" '{ printf("%s", substr($0,1+length(prog))); }'`
+-	CC="$cf_prog"
 -	for cf_arg in $cf_flags
 -	do
 -		case "x$cf_arg" in
@@ -55,7 +57,7 @@
 -cf_new_cppflags=
 -cf_new_extra_cppflags=
 -
--for cf_add_cflags in $cf_flags
+-for cf_add_cflags in $cf_arg
 -do
 -case $cf_fix_cppflags in
 -(no)
@@ -70,10 +72,16 @@
 -				&& cf_fix_cppflags=yes
 -
 -			if test $cf_fix_cppflags = yes ; then
--				cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
+-
+-	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
+-	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
+-
 -				continue
 -			elif test "${cf_tst_cflags}" = "\"'" ; then
--				cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
+-
+-	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
+-	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
+-
 -				continue
 -			fi
 -			;;
@@ -92,17 +100,25 @@
 -
 -				;;
 -			esac
--			cf_new_cppflags="$cf_new_cppflags $cf_add_cflags"
+-
+-	test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
+-	cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
+-
 -			;;
 -		esac
 -		;;
 -	(*)
--		cf_new_cflags="$cf_new_cflags $cf_add_cflags"
+-
+-	test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
+-	cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
+-
 -		;;
 -	esac
 -	;;
 -(yes)
--	cf_new_extra_cppflags="$cf_new_extra_cppflags $cf_add_cflags"
+-
+-	test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
+-	cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
 -
 -	cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
 -
@@ -115,17 +131,23 @@
 -
 -if test -n "$cf_new_cflags" ; then
 -
--	CFLAGS="$CFLAGS $cf_new_cflags"
+-	test -n "$CFLAGS" && CFLAGS="$CFLAGS "
+-	CFLAGS="${CFLAGS}$cf_new_cflags"
+-
 -fi
 -
 -if test -n "$cf_new_cppflags" ; then
 -
--	CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
+-	test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
+-	CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
+-
 -fi
 -
 -if test -n "$cf_new_extra_cppflags" ; then
 -
--	EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
+-	test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
+-	EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
+-
 -fi
 -
 -			;;
@@ -136,26 +158,26 @@
 -	done
 -	test -n "$verbose" && echo "	resulting CC: '$CC'" 1>&6
 -
--echo "${as_me:-configure}:2051: testing resulting CC: '$CC' ..." 1>&5
+-echo "${as_me:-configure}:2072: testing resulting CC: '$CC' ..." 1>&5
 -
 -	test -n "$verbose" && echo "	resulting CFLAGS: '$CFLAGS'" 1>&6
 -
--echo "${as_me:-configure}:2055: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
+-echo "${as_me:-configure}:2076: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
 -
 -	test -n "$verbose" && echo "	resulting CPPFLAGS: '$CPPFLAGS'" 1>&6
 -
--echo "${as_me:-configure}:2059: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
+-echo "${as_me:-configure}:2080: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
 -
 -	;;
 -(*)
--	echo "$as_me:2063: result: ok" >&5
+-	echo "$as_me:2084: result: ok" >&5
 -echo "${ECHO_T}ok" >&6
 -	;;
 -esac
 -
- echo "$as_me:2068: checking whether ${MAKE-make} sets \${MAKE}" >&5
+ echo "$as_me:2089: checking whether ${MAKE-make} sets \${MAKE}" >&5
  echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
  set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
 -- 
-2.8.3
+2.7.4
 
diff --git a/meta-openembedded/meta-oe/recipes-extended/byacc/byacc_20170201.bb b/meta-openembedded/meta-oe/recipes-extended/byacc/byacc_20170201.bb
deleted file mode 100644
index 702c4c9..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/byacc/byacc_20170201.bb
+++ /dev/null
@@ -1,12 +0,0 @@
-# Sigh. This is one of those places where everyone licenses it differently. Someone
-# even apply UCB to it (Free/Net/OpenBSD). The maintainer states that:
-# "I've found no reliable source which states that byacc must bear a UCB copyright."
-# Setting to PD as this is what the upstream has it as.
-
-LICENSE = "PD"
-LIC_FILES_CHKSUM = "file://package/debian/copyright;md5=9176bfb16dab43ebcb8e50d9ee9550b6"
-require byacc.inc
-
-SRC_URI[md5sum] = "4bb274bbd7b648d4251c2b9ca36ed0c9"
-SRC_URI[sha256sum] = "90b768d177f91204e6e7cef226ae1dc7cac831b625774cebd3e233a917754f91"
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/byacc/byacc_20180510.bb b/meta-openembedded/meta-oe/recipes-extended/byacc/byacc_20180510.bb
new file mode 100644
index 0000000..f30c426
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/byacc/byacc_20180510.bb
@@ -0,0 +1,12 @@
+# Sigh. This is one of those places where everyone licenses it differently. Someone
+# even apply UCB to it (Free/Net/OpenBSD). The maintainer states that:
+# "I've found no reliable source which states that byacc must bear a UCB copyright."
+# Setting to PD as this is what the upstream has it as.
+
+LICENSE = "PD"
+LIC_FILES_CHKSUM = "file://package/debian/copyright;md5=8b2933503c0443e041d3168dc0c65640"
+require byacc.inc
+
+SRC_URI[md5sum] = "97fdc0745e0ff0cef5c09d57d0c6752d"
+SRC_URI[sha256sum] = "d0940dbffbc7e9c9dd4985c25349c390beede84ae1d9fe86b71c0aa659a6d693"
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine-masterfiles_3.10.2.bb b/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine-masterfiles_3.10.2.bb
deleted file mode 100644
index b52e7cc..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine-masterfiles_3.10.2.bb
+++ /dev/null
@@ -1,36 +0,0 @@
-#
-# Copyright (C) 2014 - 2017 Wind River Systems, Inc.
-#
-SUMMARY = "Base policy for CFEngine"
-
-DESCRIPTION = "CFEngine is an IT infrastructure automation framework \
-that helps engineers, system administrators and other stakeholders \
-in an IT system to manage and understand IT infrastructure throughout \
-its lifecycle. CFEngine takes systems from Build to Deploy, Manage and Audit. \
- \
-This package is intended to provide a stable base policy for \
-installations and upgrades, and is used by CFEngine 3.6 and newer. \
- \
-The contents of this packge are intended to live in `/var/cfengine/masterfiles` \
-or wherever `$(sys.masterdir)` points. \
-"
-
-HOMEPAGE = "http://cfengine.com"
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=9f76426f9ef8c6f6739fadd21d817a4f"
-
-SRC_URI = "https://cfengine-package-repos.s3.amazonaws.com/tarballs/${BP}.tar.gz"
-
-SRC_URI[md5sum] = "1247ef4e8f3cee5efa98da50c326e5a4"
-SRC_URI[sha256sum] = "5d18a8d71f451d0b5dd1f5e579452b29b99b664f2bb0827dbba9a615f2764df6"
-
-inherit autotools
-
-export EXPLICIT_VERSION="${PV}"
-
-EXTRA_OECONF = "--prefix=${datadir}/cfengine"
-
-FILES_${PN} = "${datadir}/cfengine"
-
-RDEPENDS_${PN} += "python-core"
diff --git a/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine-masterfiles_3.12.0.bb b/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine-masterfiles_3.12.0.bb
new file mode 100644
index 0000000..dda6af9
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine-masterfiles_3.12.0.bb
@@ -0,0 +1,36 @@
+#
+# Copyright (C) 2014 - 2017 Wind River Systems, Inc.
+#
+SUMMARY = "Base policy for CFEngine"
+
+DESCRIPTION = "CFEngine is an IT infrastructure automation framework \
+that helps engineers, system administrators and other stakeholders \
+in an IT system to manage and understand IT infrastructure throughout \
+its lifecycle. CFEngine takes systems from Build to Deploy, Manage and Audit. \
+ \
+This package is intended to provide a stable base policy for \
+installations and upgrades, and is used by CFEngine 3.6 and newer. \
+ \
+The contents of this packge are intended to live in `/var/cfengine/masterfiles` \
+or wherever `$(sys.masterdir)` points. \
+"
+
+HOMEPAGE = "http://cfengine.com"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=9f76426f9ef8c6f6739fadd21d817a4f"
+
+SRC_URI = "https://cfengine-package-repos.s3.amazonaws.com/tarballs/${BP}.tar.gz"
+
+SRC_URI[md5sum] = "d59bd8c95620da816c382f749d425860"
+SRC_URI[sha256sum] = "1c50e3d8c702097e13a21258626d936d6ff2e6492e893dfe286ff0d6204d7a65"
+
+inherit autotools
+
+export EXPLICIT_VERSION="${PV}"
+
+EXTRA_OECONF = "--prefix=${datadir}/cfengine"
+
+FILES_${PN} = "${datadir}/cfengine"
+
+RDEPENDS_${PN} += "python-core"
diff --git a/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine/change-hard-coded-lib-path.patch b/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine/change-hard-coded-lib-path.patch
deleted file mode 100644
index 2295e41..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine/change-hard-coded-lib-path.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-Upstream-Status: Inappropriate [configuration]
-
-projlibdir use a hard coded lib path, this will cause error when build a 64bit
-target. So change it to suitable path.
-
-Signed-off-by: Song.Li <Song.Li@windriver.com>
-Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
----
- configure.ac | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/configure.ac b/configure.ac
-index 38e2b9c..bc6b996 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -188,7 +188,7 @@ AS_IF([test x"$enable_fhs" = xyes], [
-   fi
- 
-   sbindir='${exec_prefix}/bin' # /var/cfengine/bin despite being sbin_?
--  projlibdir='${exec_prefix}/lib'
-+  projlibdir='${libdir}'
-   mandir='${exec_prefix}/share/man'
- ])
- 
--- 
-1.7.1
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine/set-path-of-default-config-file.patch b/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine/set-path-of-default-config-file.patch
index b9526f2..db69f95 100644
--- a/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine/set-path-of-default-config-file.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine/set-path-of-default-config-file.patch
@@ -1,23 +1,38 @@
+From dc270040cb3beb5ca42f864813145c8a68594bad Mon Sep 17 00:00:00 2001
+From: Kai Kang <kai.kang@windriver.com>
+Date: Mon, 18 Jul 2016 09:06:06 +0800
+Subject: [PATCH] cfengine: add recipe and base policy
+
 Upstream-Status: Inappropriate [configuration]
 
 Set the path of default configure file.
 
 Signed-off-by: Kai Kang <kai.kang@windriver.com>
+
 ---
+ misc/init.d/cfengine3.in | 12 ++++--------
+ 1 file changed, 4 insertions(+), 8 deletions(-)
+
 diff --git a/misc/init.d/cfengine3.in b/misc/init.d/cfengine3.in
-index d6ae26f..1dee283 100644
+index c584817..12f5803 100644
 --- a/misc/init.d/cfengine3.in
 +++ b/misc/init.d/cfengine3.in
-@@ -101,11 +101,7 @@ if [ -z "$LOCKDIR" ]; then
+@@ -101,14 +101,10 @@ if [ -z "$LOCKDIR" ]; then
  fi
  
  # default control file
 -if [ "$DEBIAN" = "1" ]; then
 -    DEFAULT=/etc/default/cfengine3
+-    INIT_FUNCTIONS=/lib/lsb/init-functions
+-    if [ -e "$INIT_FUNCTIONS" ]; then
+-        . "$INIT_FUNCTIONS"
+-    fi
 -else
 -    DEFAULT=/etc/sysconfig/cfengine3
--fi
 +DEFAULT=/etc/default/cfengine3
++INIT_FUNCTIONS=/lib/lsb/init-functions
++if [ -e "$INIT_FUNCTIONS" ]; then
++    . "$INIT_FUNCTIONS"
+ fi
  
  if [ -f $DEFAULT ]; then
-     . $DEFAULT
diff --git a/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine_3.10.2.bb b/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine_3.10.2.bb
deleted file mode 100644
index b86b0a1..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine_3.10.2.bb
+++ /dev/null
@@ -1,73 +0,0 @@
-#
-# Copyright (C) 2014 - 2017 Wind River Systems, Inc.
-#
-SUMMARY = "CFEngine is an IT infrastructure automation framework"
-
-DESCRIPTION = "CFEngine is an IT infrastructure automation framework \
-that helps engineers, system administrators and other stakeholders \
-in an IT system to manage and understand IT infrastructure throughout \
-its lifecycle. CFEngine takes systems from Build to Deploy, Manage and Audit."
-
-HOMEPAGE = "http://cfengine.com"
-
-LICENSE = "GPLv3"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=f8b34828ab373d6b1bb4b0fc60a78494"
-
-DEPENDS = "attr tokyocabinet"
-
-SRC_URI = "https://cfengine-package-repos.s3.amazonaws.com/tarballs/${BP}.tar.gz \
-           file://change-hard-coded-lib-path.patch \
-           file://set-path-of-default-config-file.patch \
-"
-
-SRC_URI[md5sum] = "c16baf08189a1af6fcf2e2ff61102992"
-SRC_URI[sha256sum] = "d4fa9ac7276dba7b85d6757aab2f0929ab8d3b115cb0e7b0cf984760347429d7"
-
-inherit autotools systemd
-
-export EXPLICIT_VERSION="${PV}"
-
-SYSTEMD_SERVICE_${PN} = "cfengine3.service cf-apache.service cf-hub.service cf-postgres.service \
-                         cf-runalerts.service cf-consumer.service cf-execd.service \
-                         cf-monitord.service  cf-redis-server.service  cf-serverd.service \
-"
-SYSTEMD_AUTO_ENABLE_${PN} = "disable"
-
-PACKAGECONFIG ??= "libpcre openssl \
-                   ${@bb.utils.filter('DISTRO_FEATURES', 'pam systemd', d)} \
-"
-PACKAGECONFIG[libxml2] = "--with-libxml2=yes,--with-libxml2=no,libxml2,"
-PACKAGECONFIG[mysql] = "--with-mysql=yes,--with-mysql=no,mysql,"
-PACKAGECONFIG[postgresql] = "--with-postgresql=yes,--with-postgresql=no,postgresql,"
-PACKAGECONFIG[acl] = "--with-libacl=yes,--with-libacl=no,acl,"
-PACKAGECONFIG[libvirt] = "--with-libvirt=yes,--with-libvirt=no,libvirt,"
-PACKAGECONFIG[libpcre] = "--with-pcre=yes,--with-pcre=no,libpcre,"
-PACKAGECONFIG[openssl] = "--with-openssl=yes,--with-openssl=no,openssl,"
-PACKAGECONFIG[pam] = "--with-pam=yes,--with-pam=no,libpam,"
-PACKAGECONFIG[libyaml] = "--with-libyaml,--without-libyaml,libyaml,"
-PACKAGECONFIG[systemd] = "--with-systemd-service=${systemd_system_unitdir},--without-systemd-service"
-PACKAGECONFIG[libcurl] = "--with-libcurl,--without-libcurl,curl,"
-
-EXTRA_OECONF = "hw_cv_func_va_copy=yes --with-init-script=${sysconfdir}/init.d --with-tokyocabinet"
-
-do_install_append() {
-    install -d ${D}${localstatedir}/${BPN}/bin
-    for f in `ls ${D}${bindir}`; do
-        ln -s ${bindir}/`basename $f` ${D}${localstatedir}/${BPN}/bin/
-    done
-
-    install -d ${D}${sysconfdir}/default
-    cat << EOF > ${D}${sysconfdir}/default/cfengine3
-RUN_CF_SERVERD=1
-RUN_CF_EXECD=1
-RUN_CF_MONITORD=1
-RUN_CF_HUB=0
-EOF
-
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-        install -m 0755 -D ${D}${sysconfdir}/init.d/cfengine3 ${D}${datadir}/${BPN}/cfengine3
-        sed -i -e 's#/etc/init.d#${datadir}/${BPN}#' ${D}${systemd_system_unitdir}/*.service
-    fi
-}
-
-RDEPENDS_${PN} += "${BPN}-masterfiles"
diff --git a/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine_3.12.0.bb b/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine_3.12.0.bb
new file mode 100644
index 0000000..9d0123d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/cfengine/cfengine_3.12.0.bb
@@ -0,0 +1,72 @@
+#
+# Copyright (C) 2014 - 2017 Wind River Systems, Inc.
+#
+SUMMARY = "CFEngine is an IT infrastructure automation framework"
+
+DESCRIPTION = "CFEngine is an IT infrastructure automation framework \
+that helps engineers, system administrators and other stakeholders \
+in an IT system to manage and understand IT infrastructure throughout \
+its lifecycle. CFEngine takes systems from Build to Deploy, Manage and Audit."
+
+HOMEPAGE = "http://cfengine.com"
+
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=f8b34828ab373d6b1bb4b0fc60a78494"
+
+DEPENDS = "attr tokyocabinet"
+
+SRC_URI = "https://cfengine-package-repos.s3.amazonaws.com/tarballs/${BP}.tar.gz \
+           file://set-path-of-default-config-file.patch \
+           "
+
+SRC_URI[md5sum] = "33ef12260db4b430352229f37f7cb0e5"
+SRC_URI[sha256sum] = "d71ba98a272390c6fa8bc20e8ea27f0050a0a72a3e6b206a4762b4646be332ec"
+
+inherit autotools systemd
+
+export EXPLICIT_VERSION="${PV}"
+
+SYSTEMD_SERVICE_${PN} = "cfengine3.service cf-apache.service cf-hub.service cf-postgres.service \
+                         cf-runalerts.service cf-execd.service \
+                         cf-monitord.service  cf-serverd.service \
+"
+SYSTEMD_AUTO_ENABLE_${PN} = "disable"
+
+PACKAGECONFIG ??= "libpcre openssl \
+                   ${@bb.utils.filter('DISTRO_FEATURES', 'pam systemd', d)} \
+"
+PACKAGECONFIG[libxml2] = "--with-libxml2=yes,--with-libxml2=no,libxml2,"
+PACKAGECONFIG[mysql] = "--with-mysql=yes,--with-mysql=no,mysql,"
+PACKAGECONFIG[postgresql] = "--with-postgresql=yes,--with-postgresql=no,postgresql,"
+PACKAGECONFIG[acl] = "--with-libacl=yes,--with-libacl=no,acl,"
+PACKAGECONFIG[libvirt] = "--with-libvirt=yes,--with-libvirt=no,libvirt,"
+PACKAGECONFIG[libpcre] = "--with-pcre=yes,--with-pcre=no,libpcre,"
+PACKAGECONFIG[openssl] = "--with-openssl=yes,--with-openssl=no,openssl,"
+PACKAGECONFIG[pam] = "--with-pam=yes,--with-pam=no,libpam,"
+PACKAGECONFIG[libyaml] = "--with-libyaml,--without-libyaml,libyaml,"
+PACKAGECONFIG[systemd] = "--with-systemd-service=${systemd_system_unitdir},--without-systemd-service"
+PACKAGECONFIG[libcurl] = "--with-libcurl,--without-libcurl,curl,"
+
+EXTRA_OECONF = "hw_cv_func_va_copy=yes --with-init-script=${sysconfdir}/init.d --with-tokyocabinet"
+
+do_install_append() {
+    install -d ${D}${localstatedir}/${BPN}/bin
+    for f in `ls ${D}${bindir}`; do
+        ln -s ${bindir}/`basename $f` ${D}${localstatedir}/${BPN}/bin/
+    done
+
+    install -d ${D}${sysconfdir}/default
+    cat << EOF > ${D}${sysconfdir}/default/cfengine3
+RUN_CF_SERVERD=1
+RUN_CF_EXECD=1
+RUN_CF_MONITORD=1
+RUN_CF_HUB=0
+EOF
+
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+        install -m 0755 -D ${D}${sysconfdir}/init.d/cfengine3 ${D}${datadir}/${BPN}/cfengine3
+        sed -i -e 's#/etc/init.d#${datadir}/${BPN}#' ${D}${systemd_system_unitdir}/*.service
+    fi
+}
+
+RDEPENDS_${PN} += "${BPN}-masterfiles"
diff --git a/meta-openembedded/meta-oe/recipes-extended/cmpi-bindings/cmpi-bindings_git.bb b/meta-openembedded/meta-oe/recipes-extended/cmpi-bindings/cmpi-bindings_1.0.1.bb
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-extended/cmpi-bindings/cmpi-bindings_git.bb
rename to meta-openembedded/meta-oe/recipes-extended/cmpi-bindings/cmpi-bindings_1.0.1.bb
diff --git a/meta-openembedded/meta-oe/recipes-extended/collectd/collectd/0001-conditionally-check-libvirt.patch b/meta-openembedded/meta-oe/recipes-extended/collectd/collectd/0001-conditionally-check-libvirt.patch
index 1ceacd8..5ee75cb 100644
--- a/meta-openembedded/meta-oe/recipes-extended/collectd/collectd/0001-conditionally-check-libvirt.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/collectd/collectd/0001-conditionally-check-libvirt.patch
@@ -1,28 +1,31 @@
-[PATCH] conditionally check libvirt
+From 385bf1c2ec57942e17ee529e57eef0dcd99904e6 Mon Sep 17 00:00:00 2001
+From: Roy Li <rongqing.li@windriver.com>
+Date: Tue, 1 Sep 2015 17:00:33 +0800
+Subject: [PATCH] [PATCH] conditionally check libvirt
 
 Upstream-Statue: Pending
 
 check if libvirt is available only when a user wants to use libvirt
 
 Signed-off-by: Roy Li <rongqing.li@windriver.com>
----
- configure.ac | 14 ++++++++------
- 1 file changed, 8 insertions(+), 6 deletions(-)
 
-Index: collectd-5.7.1/configure.ac
-===================================================================
---- collectd-5.7.1.orig/configure.ac
-+++ collectd-5.7.1/configure.ac
-@@ -5556,12 +5556,14 @@ else
- 	with_libxml2="no (pkg-config doesn't know libxml-2.0)"
+---
+ configure.ac | 13 ++++++++-----
+ 1 file changed, 8 insertions(+), 5 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 101d6f9f..a7eca97d 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -5758,11 +5758,14 @@ else
+   with_libxml2="no (pkg-config doesn't know libxml-2.0)"
  fi
  
 -$PKG_CONFIG --exists libvirt 2>/dev/null
--if test "$?" = "0"
--then
--	with_libvirt="yes"
+-if test $? = 0; then
+-  with_libvirt="yes"
 -else
--	with_libvirt="no (pkg-config doesn't know libvirt)"
+-  with_libvirt="no (pkg-config doesn't know libvirt)"
 +if test "x$enable_libvirt" = "xyes"; then
 +	$PKG_CONFIG --exists libvirt 2>/dev/null
 +	if test "$?" = "0"
@@ -32,5 +35,5 @@
 +		with_libvirt="no (pkg-config doesn't know libvirt)"
 +	fi
  fi
- if test "x$with_libxml2" = "xyes"
- then
+ 
+ if test "x$with_libxml2" = "xyes"; then
diff --git a/meta-openembedded/meta-oe/recipes-extended/collectd/collectd/0001-configure-Check-for-Wno-error-format-truncation-comp.patch b/meta-openembedded/meta-oe/recipes-extended/collectd/collectd/0001-configure-Check-for-Wno-error-format-truncation-comp.patch
index 5069a63..d2c7268 100644
--- a/meta-openembedded/meta-oe/recipes-extended/collectd/collectd/0001-configure-Check-for-Wno-error-format-truncation-comp.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/collectd/collectd/0001-configure-Check-for-Wno-error-format-truncation-comp.patch
@@ -1,4 +1,4 @@
-From b459c55e4968321e5a82272cb39aa69d4054990f Mon Sep 17 00:00:00 2001
+From b0a64db90a24469e36978c748417ebe456b34d59 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sat, 22 Apr 2017 11:54:57 -0700
 Subject: [PATCH] configure: Check for -Wno-error=format-truncation compiler
@@ -14,35 +14,26 @@
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
 ---
- configure.ac                |  3 +-
- m4/ax_check_compile_flag.m4 | 74 +++++++++++++++++++++++++++++++++++++++++++++
- 2 files changed, 76 insertions(+), 1 deletion(-)
+ configure.ac                |  1 +
+ m4/ax_check_compile_flag.m4 | 74 +++++++++++++++++++++++++++++++++++++
+ 2 files changed, 75 insertions(+)
  create mode 100644 m4/ax_check_compile_flag.m4
 
 diff --git a/configure.ac b/configure.ac
-index 8854542..edb8cfb 100644
+index a7eca97d..560eb988 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -4,7 +4,6 @@ AC_INIT([collectd],[m4_esyscmd(./version-gen.sh)])
- AC_CONFIG_SRCDIR(src/target_set.c)
- AC_CONFIG_HEADERS(src/config.h)
- AC_CONFIG_AUX_DIR([libltdl/config])
--
- dnl older automake's default of ARFLAGS=cru is noisy on newer binutils;
- dnl we don't really need the 'u' even in older toolchains.  Then there is
- dnl older libtool, which spelled it AR_FLAGS
-@@ -6688,6 +6687,8 @@ then
-         AM_CFLAGS="$AM_CFLAGS -Werror"
-         AM_CXXFLAGS="$AM_CXXFLAGS -Werror"
+@@ -6794,6 +6794,7 @@ if test "x$enable_werror" != "xno"; then
+   AM_CFLAGS="$AM_CFLAGS -Werror"
+   AM_CXXFLAGS="$AM_CXXFLAGS -Werror"
  fi
 +AX_CHECK_COMPILE_FLAG([-Werror -Werror=format-truncation],[AM_CFLAGS="$AM_CFLAGS -Wno-error=format-truncation" AM_CXXFLAGS="$AM_CXXFLAGS -Wno-error=format-truncation"])
-+
+ 
  AC_SUBST([AM_CFLAGS])
  AC_SUBST([AM_CXXFLAGS])
- 
 diff --git a/m4/ax_check_compile_flag.m4 b/m4/ax_check_compile_flag.m4
 new file mode 100644
-index 0000000..dcabb92
+index 00000000..dcabb92a
 --- /dev/null
 +++ b/m4/ax_check_compile_flag.m4
 @@ -0,0 +1,74 @@
@@ -120,6 +111,3 @@
 +  [m4_default([$3], :)])
 +AS_VAR_POPDEF([CACHEVAR])dnl
 +])dnl AX_CHECK_COMPILE_FLAGS
--- 
-2.13.4
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/collectd/collectd/0005-Disable-new-gcc8-warnings.patch b/meta-openembedded/meta-oe/recipes-extended/collectd/collectd/0005-Disable-new-gcc8-warnings.patch
new file mode 100644
index 0000000..b12690b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/collectd/collectd/0005-Disable-new-gcc8-warnings.patch
@@ -0,0 +1,65 @@
+From d65e48b68076d5b304e6d865967003ae1fea0e6c Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 9 May 2018 21:45:38 -0700
+Subject: [PATCH] Disable new gcc8 warnings
+
+GCC seems to be not able to detect the checks for size are
+already in place
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Submitted [https://github.com/collectd/collectd/pull/2768]
+ src/libcollectdclient/network_parse.c | 7 +++++++
+ src/write_sensu.c                     | 7 +++++++
+ 2 files changed, 14 insertions(+)
+
+diff --git a/src/libcollectdclient/network_parse.c b/src/libcollectdclient/network_parse.c
+index 2365ab0a..79e6ed96 100644
+--- a/src/libcollectdclient/network_parse.c
++++ b/src/libcollectdclient/network_parse.c
+@@ -163,6 +163,11 @@ static int parse_int(void *payload, size_t payload_size, uint64_t *out) {
+   return 0;
+ }
+ 
++#pragma GCC diagnostic push
++#if __GNUC__ == 8
++#pragma GCC diagnostic ignored "-Wstringop-truncation"
++#endif
++
+ static int parse_string(void *payload, size_t payload_size, char *out,
+                         size_t out_size) {
+   char *in = payload;
+@@ -175,6 +180,8 @@ static int parse_string(void *payload, size_t payload_size, char *out,
+   return 0;
+ }
+ 
++#pragma GCC diagnostic pop
++
+ static int parse_identifier(uint16_t type, void *payload, size_t payload_size,
+                             lcc_value_list_t *state) {
+   char buf[LCC_NAME_LEN];
+diff --git a/src/write_sensu.c b/src/write_sensu.c
+index ce23e654..63e1f599 100644
+--- a/src/write_sensu.c
++++ b/src/write_sensu.c
+@@ -569,6 +569,11 @@ static char *sensu_value_to_json(struct sensu_host const *host, /* {{{ */
+   return ret_str;
+ } /* }}} char *sensu_value_to_json */
+ 
++#pragma GCC diagnostic push
++#if __GNUC__ == 8
++#pragma GCC diagnostic ignored "-Wstringop-overflow"
++#pragma GCC diagnostic ignored "-Wstringop-truncation"
++#endif
+ /*
+  * Uses replace_str2() implementation from
+  * http://creativeandcritical.net/str-replace-c/
+@@ -631,6 +636,8 @@ static char *replace_str(const char *str, const char *old, /* {{{ */
+   return ret;
+ } /* }}} char *replace_str */
+ 
++#pragma GCC diagnostic pop
++
+ static char *replace_json_reserved(const char *message) /* {{{ */
+ {
+   char *msg = replace_str(message, "\\", "\\\\");
diff --git a/meta-openembedded/meta-oe/recipes-extended/collectd/collectd/no-gcrypt-badpath.patch b/meta-openembedded/meta-oe/recipes-extended/collectd/collectd/no-gcrypt-badpath.patch
index 1fde6a0..f12b16c 100644
--- a/meta-openembedded/meta-oe/recipes-extended/collectd/collectd/no-gcrypt-badpath.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/collectd/collectd/no-gcrypt-badpath.patch
@@ -1,43 +1,37 @@
-Index: collectd-5.7.1/configure.ac
-===================================================================
---- collectd-5.7.1.orig/configure.ac
-+++ collectd-5.7.1/configure.ac
-@@ -2305,7 +2305,7 @@ AC_ARG_WITH(libgcrypt, [AS_HELP_STRING([
- 	 with_libgcrypt="yes"
-  else if test -f "$withval/bin/gcrypt-config" && test -x "$withval/bin/gcrypt-config"
-  then
--	 with_libgcrypt_config="$withval/bin/gcrypt-config"
-+	 with_libgcrypt_config="$withval/bin/pkg-config"
- 	 with_libgcrypt="yes"
-  else if test -d "$withval"
-  then
-@@ -2313,12 +2313,12 @@ AC_ARG_WITH(libgcrypt, [AS_HELP_STRING([
- 	 GCRYPT_LDFLAGS="$GCRYPT_LDFLAGS -L$withval/lib"
- 	 with_libgcrypt="yes"
-  else
--	 with_libgcrypt_config="gcrypt-config"
-+	 with_libgcrypt_config="pkg-config"
- 	 with_libgcrypt="$withval"
-  fi; fi; fi
- ],
- [
-- with_libgcrypt_config="libgcrypt-config"
-+ with_libgcrypt_config="pkg-config"
-  with_libgcrypt="yes"
- ])
- 
-@@ -2326,12 +2326,12 @@ if test "x$with_libgcrypt" = "xyes" && t
- then
- 	if test "x$GCRYPT_CPPFLAGS" = "x"
- 	then
--		GCRYPT_CPPFLAGS=`"$with_libgcrypt_config" --cflags 2>/dev/null`
-+		GCRYPT_CPPFLAGS=`"$with_libgcrypt_config" --cflags libgcrypt 2>/dev/null`
- 	fi
- 
- 	if test "x$GCRYPT_LIBS" = "x"
- 	then
--		GCRYPT_LIBS=`"$with_libgcrypt_config" --libs 2>/dev/null`
-+		GCRYPT_LIBS=`"$with_libgcrypt_config" --lib libgcrypt 2>/dev/null`
- 	fi
- fi
- 
+From d9b954bd9d0b084d9a1f5159a9f0c45802a51809 Mon Sep 17 00:00:00 2001
+From: Paul Eggleton <paul.eggleton@linux.intel.com>
+Date: Mon, 22 Apr 2013 16:28:16 +0000
+
+---
+ configure.ac | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index e869a6a0..101d6f9f 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -2514,20 +2514,20 @@ AC_ARG_WITH([libgcrypt],
+     if test -f "$withval" && test -x "$withval"; then
+       with_libgcrypt_config="$withval"
+       with_libgcrypt="yes"
+-    else if test -f "$withval/bin/gcrypt-config" && test -x "$withval/bin/gcrypt-config"; then
+-      with_libgcrypt_config="$withval/bin/gcrypt-config"
++    else if test -f "$withval/bin/pkg-config" && test -x "$withval/bin/pkg-config"; then
++      with_libgcrypt_config="$withval/bin/pkg-config"
+       with_libgcrypt="yes"
+     else if test -d "$withval"; then
+       GCRYPT_CPPFLAGS="$GCRYPT_CPPFLAGS -I$withval/include"
+       GCRYPT_LDFLAGS="$GCRYPT_LDFLAGS -L$withval/lib"
+       with_libgcrypt="yes"
+     else
+-      with_libgcrypt_config="gcrypt-config"
++      with_libgcrypt_config="pkg-config"
+       with_libgcrypt="$withval"
+     fi; fi; fi
+   ],
+   [
+-    with_libgcrypt_config="libgcrypt-config"
++    with_libgcrypt_config="libpkg-config"
+     with_libgcrypt="yes"
+   ]
+ )
diff --git a/meta-openembedded/meta-oe/recipes-extended/collectd/collectd_5.7.2.bb b/meta-openembedded/meta-oe/recipes-extended/collectd/collectd_5.7.2.bb
deleted file mode 100644
index c156ea1..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/collectd/collectd_5.7.2.bb
+++ /dev/null
@@ -1,86 +0,0 @@
-SUMMARY = "Collects and summarises system performance statistics"
-DESCRIPTION = "collectd is a daemon which collects system performance statistics periodically and provides mechanisms to store the values in a variety of ways, for example in RRD files."
-LICENSE = "GPLv2 & MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=1bd21f19f7f0c61a7be8ecacb0e28854"
-
-DEPENDS = "rrdtool curl libpcap libxml2 yajl libgcrypt libtool lvm2"
-
-SRC_URI = "http://collectd.org/files/collectd-${PV}.tar.bz2 \
-           file://collectd.init \
-           file://collectd.service \
-           file://no-gcrypt-badpath.patch \
-           file://0001-conditionally-check-libvirt.patch \
-           file://0001-fix-to-build-with-glibc-2.25.patch \
-           file://0001-configure-Check-for-Wno-error-format-truncation-comp.patch \
-"
-SRC_URI[md5sum] = "5da2b69c286a064db35c6cc1e758b039"
-SRC_URI[sha256sum] = "9d20a0221569a8d6b80bbc52b86e5e84965f5bafdbf5dfc3790e0fed0763e592"
-
-inherit autotools pythonnative update-rc.d pkgconfig systemd
-
-SYSTEMD_SERVICE_${PN} = "collectd.service"
-
-# Floatingpoint layout, architecture dependent
-# 'nothing', 'endianflip' or 'intswap'
-FPLAYOUT ?= "--with-fp-layout=nothing"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[openjdk] = "--with-java=${STAGING_DIR_TARGET}${libdir}/jvm,--without-java,openjdk-7"
-PACKAGECONFIG[snmp] = "--enable-snmp,--disable-snmp --with-libnetsnmp=no,net-snmp"
-PACKAGECONFIG[libmemcached] = "--with-libmemcached,--without-libmemcached,libmemcached"
-PACKAGECONFIG[iptables] = "--enable-iptables,--disable-iptables,iptables"
-PACKAGECONFIG[postgresql] = "--enable-postgresql --with-libpq=yes, \
-        --disable-postgresql --with-libpq=no,postgresql"
-PACKAGECONFIG[mysql] = "--enable-mysql --with-libmysql=yes, \
-        --disable-mysql --with-libmysql=no,mysql5"
-PACKAGECONFIG[dbi] = "--enable-dbi,--disable-dbi,libdbi"
-PACKAGECONFIG[modbus] = "--enable-modbus,--disable-modbus,libmodbus"
-PACKAGECONFIG[libowcapi] = "--with-libowcapi,--without-libowcapi,owfs"
-PACKAGECONFIG[sensors] = "--enable-sensors --with-libsensors=yes, \
-        --disable-sensors --with-libsensors=no,lmsensors"
-PACKAGECONFIG[amqp] = "--enable-amqp --with-librabbitmq=yes, \
-        --disable-amqp --with-librabbitmq=no,rabbitmq-c"
-# protobuf-c, libvirt that are currently only available in meta-virtualization layer
-PACKAGECONFIG[pinba] = "--enable-pinba,--disable-pinba,protobuf-c-native protobuf-c"
-PACKAGECONFIG[libvirt] = "--enable-libvirt,--disable-libvirt,libvirt"
-PACKAGECONFIG[libesmtp] = "--with-libesmtp,--without-libesmtp,libesmtp"
-PACKAGECONFIG[libmnl] = "--with-libmnl,--without-libmnl,libmnl"
-PACKAGECONFIG[libatasmart] = "--with-libatasmart,--without-libatasmart,libatasmart"
-PACKAGECONFIG[ldap] = "--enable-openldap --with-libldap,--disable-openldap --without-libldap, openldap"
-
-EXTRA_OECONF = " \
-                ${FPLAYOUT} \
-                --disable-perl --with-libperl=no --with-perl-bindings=no \
-                --with-libgcrypt=${STAGING_BINDIR_CROSS}/libgcrypt-config \
-                --disable-notify_desktop \
-"
-
-do_install_append() {
-    install -d ${D}${sysconfdir}/init.d
-    install -m 0755 ${WORKDIR}/collectd.init ${D}${sysconfdir}/init.d/collectd
-    sed -i 's!/usr/sbin/!${sbindir}/!g' ${D}${sysconfdir}/init.d/collectd
-    sed -i 's!/etc/!${sysconfdir}/!g' ${D}${sysconfdir}/init.d/collectd
-    sed -i 's!/var/!${localstatedir}/!g' ${D}${sysconfdir}/init.d/collectd
-    sed -i 's!^PATH=.*!PATH=${base_sbindir}:${base_bindir}:${sbindir}:${bindir}!' ${D}${sysconfdir}/init.d/collectd
-
-    # Fix configuration file to allow collectd to start up
-    sed -i 's!^#FQDNLookup[ \t]*true!FQDNLookup   false!g' ${D}${sysconfdir}/collectd.conf
-
-    rmdir "${D}${localstatedir}/run"
-    rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
-
-    # Install systemd unit files
-    install -d ${D}${systemd_unitdir}/system
-    install -m 0644 ${WORKDIR}/collectd.service ${D}${systemd_unitdir}/system
-    sed -i -e 's,@SBINDIR@,${sbindir},g' \
-        ${D}${systemd_unitdir}/system/collectd.service
-}
-
-CONFFILES_${PN} = "${sysconfdir}/collectd.conf"
-
-INITSCRIPT_NAME = "collectd"
-INITSCRIPT_PARAMS = "defaults"
-
-# threshold.so load.so are also provided by gegl
-# disk.so is also provided by libgphoto2-camlibs
-PRIVATE_LIBS = "threshold.so load.so disk.so"
diff --git a/meta-openembedded/meta-oe/recipes-extended/collectd/collectd_5.8.0.bb b/meta-openembedded/meta-oe/recipes-extended/collectd/collectd_5.8.0.bb
new file mode 100644
index 0000000..df9fa23
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/collectd/collectd_5.8.0.bb
@@ -0,0 +1,87 @@
+SUMMARY = "Collects and summarises system performance statistics"
+DESCRIPTION = "collectd is a daemon which collects system performance statistics periodically and provides mechanisms to store the values in a variety of ways, for example in RRD files."
+LICENSE = "GPLv2 & MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=1bd21f19f7f0c61a7be8ecacb0e28854"
+
+DEPENDS = "rrdtool curl libpcap libxml2 yajl libgcrypt libtool lvm2"
+
+SRC_URI = "http://collectd.org/files/collectd-${PV}.tar.bz2 \
+           file://collectd.init \
+           file://collectd.service \
+           file://no-gcrypt-badpath.patch \
+           file://0001-conditionally-check-libvirt.patch \
+           file://0001-fix-to-build-with-glibc-2.25.patch \
+           file://0001-configure-Check-for-Wno-error-format-truncation-comp.patch \
+           file://0005-Disable-new-gcc8-warnings.patch \
+           "
+SRC_URI[md5sum] = "a841159323624f18bf03198e9f5aa364"
+SRC_URI[sha256sum] = "b06ff476bbf05533cb97ae6749262cc3c76c9969f032bd8496690084ddeb15c9"
+
+inherit autotools pythonnative update-rc.d pkgconfig systemd
+
+SYSTEMD_SERVICE_${PN} = "collectd.service"
+
+# Floatingpoint layout, architecture dependent
+# 'nothing', 'endianflip' or 'intswap'
+FPLAYOUT ?= "--with-fp-layout=nothing"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[openjdk] = "--with-java=${STAGING_DIR_TARGET}${libdir}/jvm,--without-java,openjdk-7"
+PACKAGECONFIG[snmp] = "--enable-snmp,--disable-snmp --with-libnetsnmp=no,net-snmp"
+PACKAGECONFIG[libmemcached] = "--with-libmemcached,--without-libmemcached,libmemcached"
+PACKAGECONFIG[iptables] = "--enable-iptables,--disable-iptables,iptables"
+PACKAGECONFIG[postgresql] = "--enable-postgresql --with-libpq=yes, \
+        --disable-postgresql --with-libpq=no,postgresql"
+PACKAGECONFIG[mysql] = "--enable-mysql --with-libmysql=yes, \
+        --disable-mysql --with-libmysql=no,mysql5"
+PACKAGECONFIG[dbi] = "--enable-dbi,--disable-dbi,libdbi"
+PACKAGECONFIG[modbus] = "--enable-modbus,--disable-modbus,libmodbus"
+PACKAGECONFIG[libowcapi] = "--with-libowcapi,--without-libowcapi,owfs"
+PACKAGECONFIG[sensors] = "--enable-sensors --with-libsensors=yes, \
+        --disable-sensors --with-libsensors=no,lmsensors"
+PACKAGECONFIG[amqp] = "--enable-amqp --with-librabbitmq=yes, \
+        --disable-amqp --with-librabbitmq=no,rabbitmq-c"
+# protobuf-c, libvirt that are currently only available in meta-virtualization layer
+PACKAGECONFIG[pinba] = "--enable-pinba,--disable-pinba,protobuf-c-native protobuf-c"
+PACKAGECONFIG[libvirt] = "--enable-virt,--disable-virt,libvirt"
+PACKAGECONFIG[libesmtp] = "--with-libesmtp,--without-libesmtp,libesmtp"
+PACKAGECONFIG[libmnl] = "--with-libmnl,--without-libmnl,libmnl"
+PACKAGECONFIG[libatasmart] = "--with-libatasmart,--without-libatasmart,libatasmart"
+PACKAGECONFIG[ldap] = "--enable-openldap --with-libldap,--disable-openldap --without-libldap, openldap"
+
+EXTRA_OECONF = " \
+                ${FPLAYOUT} \
+                --disable-perl --with-libperl=no --with-perl-bindings=no \
+                --with-libgcrypt=${STAGING_BINDIR_CROSS}/libgcrypt-config \
+                --disable-notify_desktop \
+"
+
+do_install_append() {
+    install -d ${D}${sysconfdir}/init.d
+    install -m 0755 ${WORKDIR}/collectd.init ${D}${sysconfdir}/init.d/collectd
+    sed -i 's!/usr/sbin/!${sbindir}/!g' ${D}${sysconfdir}/init.d/collectd
+    sed -i 's!/etc/!${sysconfdir}/!g' ${D}${sysconfdir}/init.d/collectd
+    sed -i 's!/var/!${localstatedir}/!g' ${D}${sysconfdir}/init.d/collectd
+    sed -i 's!^PATH=.*!PATH=${base_sbindir}:${base_bindir}:${sbindir}:${bindir}!' ${D}${sysconfdir}/init.d/collectd
+    install -Dm 0640 ${B}/src/collectd.conf ${D}${sysconfdir}/collectd.conf
+    # Fix configuration file to allow collectd to start up
+    sed -i 's!^#FQDNLookup[ \t]*true!FQDNLookup   false!g' ${D}${sysconfdir}/collectd.conf
+
+    rmdir "${D}${localstatedir}/run"
+    rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
+
+    # Install systemd unit files
+    install -d ${D}${systemd_unitdir}/system
+    install -m 0644 ${WORKDIR}/collectd.service ${D}${systemd_unitdir}/system
+    sed -i -e 's,@SBINDIR@,${sbindir},g' \
+        ${D}${systemd_unitdir}/system/collectd.service
+}
+
+CONFFILES_${PN} = "${sysconfdir}/collectd.conf"
+
+INITSCRIPT_NAME = "collectd"
+INITSCRIPT_PARAMS = "defaults"
+
+# threshold.so load.so are also provided by gegl
+# disk.so is also provided by libgphoto2-camlibs
+PRIVATE_LIBS = "threshold.so load.so disk.so"
diff --git a/meta-openembedded/meta-oe/recipes-extended/dialog/dialog_1.3-20171209.bb b/meta-openembedded/meta-oe/recipes-extended/dialog/dialog_1.3-20171209.bb
deleted file mode 100644
index 63c65c4..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/dialog/dialog_1.3-20171209.bb
+++ /dev/null
@@ -1,29 +0,0 @@
-SUMMARY = "display dialog boxes from shell scripts"
-DESCRIPTION = "Dialog lets you to present a variety of questions \
-or display messages using dialog boxes from a shell \
-script (or any scripting language)."
-HOMEPAGE = "http://invisible-island.net/dialog/"
-SECTION = "console/utils"
-DEPENDS = "ncurses"
-LICENSE = "LGPL-2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=a6f89e2100d9b6cdffcea4f398e37343"
-
-SRC_URI = "ftp://ftp.invisible-island.net/${BPN}/${BP}.tgz \
-          "
-SRC_URI[md5sum] = "f66f28beca900b54f5fc90fdcce93508"
-SRC_URI[sha256sum] = "20139442119e2eff5c35236e8e5e313c901539008d9cccf8c8ab3851b41267e6"
-
-# hardcoded here for use in dialog-static recipe
-S = "${WORKDIR}/dialog-${PV}"
-
-inherit autotools-brokensep pkgconfig
-
-EXTRA_OECONF = "--with-ncurses \
-                --disable-rpath-hack"
-
-do_configure() {
-    gnu-configize --force
-    sed -i 's,${cf_ncuconfig_root}6-config,${cf_ncuconfig_root}-config,g' -i configure
-    sed -i 's,cf_have_ncuconfig=unknown,cf_have_ncuconfig=yes,g' -i configure
-    oe_runconf
-}
diff --git a/meta-openembedded/meta-oe/recipes-extended/dialog/dialog_1.3-20180621.bb b/meta-openembedded/meta-oe/recipes-extended/dialog/dialog_1.3-20180621.bb
new file mode 100644
index 0000000..e987959
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/dialog/dialog_1.3-20180621.bb
@@ -0,0 +1,29 @@
+SUMMARY = "display dialog boxes from shell scripts"
+DESCRIPTION = "Dialog lets you to present a variety of questions \
+or display messages using dialog boxes from a shell \
+script (or any scripting language)."
+HOMEPAGE = "http://invisible-island.net/dialog/"
+SECTION = "console/utils"
+DEPENDS = "ncurses"
+LICENSE = "LGPL-2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=a6f89e2100d9b6cdffcea4f398e37343"
+
+SRC_URI = "ftp://ftp.invisible-island.net/${BPN}/${BP}.tgz \
+          "
+SRC_URI[md5sum] = "1dba09cf45ac4ba40b3cb4a3f1d694b2"
+SRC_URI[sha256sum] = "4a4859e2b22d24e46c1a529b5a5605b95503aa04da4432f7bbd713e3e867587a"
+
+# hardcoded here for use in dialog-static recipe
+S = "${WORKDIR}/dialog-${PV}"
+
+inherit autotools-brokensep pkgconfig
+
+EXTRA_OECONF = "--with-ncurses \
+                --disable-rpath-hack"
+
+do_configure() {
+    gnu-configize --force
+    sed -i 's,${cf_ncuconfig_root}6-config,${cf_ncuconfig_root}-config,g' -i configure
+    sed -i 's,cf_have_ncuconfig=unknown,cf_have_ncuconfig=yes,g' -i configure
+    oe_runconf
+}
diff --git a/meta-openembedded/meta-oe/recipes-extended/gnuplot/gnuplot_5.2.2.bb b/meta-openembedded/meta-oe/recipes-extended/gnuplot/gnuplot_5.2.2.bb
index 4cc289d..f9fd8ae 100644
--- a/meta-openembedded/meta-oe/recipes-extended/gnuplot/gnuplot_5.2.2.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/gnuplot/gnuplot_5.2.2.bb
@@ -60,10 +60,12 @@
     install -m 0644 ${WORKDIR}/gnuplot.png ${D}${datadir}/pixmaps/
 }
 
-PACKAGES =+ "${PN}-x11-dbg ${PN}-x11"
+PACKAGES =+ "${PN}-x11"
+
+RPROVIDES_${PN}-dbg += "${PN}-x11-dbg"
+
 DESCRIPTION_${PN}-x11 = "X11 display terminal for Gnuplot."
 SECTION_${PN}-x11 = "x11/scientific"
 FILES_${PN}-x11 = "${libexecdir} ${datadir}/applications ${datadir}/pixmaps ${libdir}/X11 "
 
 FILES_${PN} += "${datadir}/texmf"
-FILES_${PN}-x11-dbg += "${libexecdir}/gnuplot/*/.debug"
diff --git a/meta-openembedded/meta-oe/recipes-extended/haveged/haveged_1.9.2.bb b/meta-openembedded/meta-oe/recipes-extended/haveged/haveged_1.9.2.bb
index 05ee842..bf13673 100644
--- a/meta-openembedded/meta-oe/recipes-extended/haveged/haveged_1.9.2.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/haveged/haveged_1.9.2.bb
@@ -12,6 +12,8 @@
 SRC_URI[md5sum] = "fb1d8b3dcbb9d06b30eccd8aa500fd31"
 SRC_URI[sha256sum] = "f77d9adbdf421b61601fa29faa9ce3b479d910f73c66b9e364ba8642ccbfbe70"
 
+UPSTREAM_CHECK_URI = "http://www.issihosts.com/haveged/downloads.html"
+
 inherit autotools update-rc.d systemd
 
 EXTRA_OECONF = "\
diff --git a/meta-openembedded/meta-oe/recipes-extended/hwloc/hwloc_1.11.10.bb b/meta-openembedded/meta-oe/recipes-extended/hwloc/hwloc_1.11.10.bb
new file mode 100644
index 0000000..5f4155e
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/hwloc/hwloc_1.11.10.bb
@@ -0,0 +1,31 @@
+SUMMARY = "Portable Hardware Locality (hwloc) software package"
+DESCRIPTION = "The Portable Hardware Locality (hwloc) software package \
+ provides a portable abstraction of the hierarchical topology of modern \
+ architectures."
+HOMEPAGE = "https://www.open-mpi.org/software/hwloc/"
+SECTION = "base"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=3282e20dc3cec311deda3c6d4b1f990b"
+
+SRC_URI = "https://www.open-mpi.org/software/${BPN}/v1.11/downloads/${BP}.tar.bz2"
+SRC_URI[md5sum] = "0981a01935982aa7e850a96e0c3057b0"
+SRC_URI[sha256sum] = "2be808383d8337846fe77ce49c7ad3336fb6857505494d85c0ac03f22c5bd1e7"
+
+UPSTREAM_CHECK_URI = "https://www.open-mpi.org/software/hwloc/v1.11/"
+
+inherit autotools pkgconfig
+
+DEPENDS += "ncurses udev zlib"
+DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'selinux', 'libselinux', '', d)}"
+
+PACKAGECONFIG ?= "pci libxml2 ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', '', d)}"
+
+PACKAGECONFIG[numactl] = "--enable-libnuma,--disable-libnuma,numactl,numactl"
+PACKAGECONFIG[libxml2] = "--enable-libxml2,--disable-libxml2,libxml2,libxml2"
+PACKAGECONFIG[x11] = "--with-x,--without-x,virtual/libx11 cairo,cairo"
+PACKAGECONFIG[pci] = "--enable-pci,--disable-pci,libpciaccess,libpciaccess"
+
+# Split hwloc library into separate subpackage
+PACKAGES_prepend = " libhwloc "
+FILES_libhwloc += "${libdir}/libhwloc.so.*"
+RDEPENDS_${PN} += "libhwloc (= ${EXTENDPKGV})"
diff --git a/meta-openembedded/meta-oe/recipes-extended/hwloc/hwloc_1.11.5.bb b/meta-openembedded/meta-oe/recipes-extended/hwloc/hwloc_1.11.5.bb
deleted file mode 100644
index 5a335b9..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/hwloc/hwloc_1.11.5.bb
+++ /dev/null
@@ -1,29 +0,0 @@
-SUMMARY = "Portable Hardware Locality (hwloc) software package"
-DESCRIPTION = "The Portable Hardware Locality (hwloc) software package \
- provides a portable abstraction of the hierarchical topology of modern \
- architectures."
-HOMEPAGE = "https://www.open-mpi.org/software/hwloc/"
-SECTION = "base"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=3282e20dc3cec311deda3c6d4b1f990b"
-
-SRC_URI = "https://www.open-mpi.org/software/${PN}/v1.11/downloads/${BP}.tar.bz2"
-SRC_URI[md5sum] = "96c34136ff416d2b13a7821c27477bed"
-SRC_URI[sha256sum] = "95d80286dfe658a3f79e2ac90698782bb36e5504f4bac1bba2394ba14dbbad24"
-
-inherit autotools pkgconfig
-
-DEPENDS += "ncurses udev zlib"
-DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'selinux', 'libselinux', '', d)}"
-
-PACKAGECONFIG ?= "pci libxml2 ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', '', d)}"
-
-PACKAGECONFIG[numactl] = "--enable-libnuma,--disable-libnuma,numactl,numactl"
-PACKAGECONFIG[libxml2] = "--enable-libxml2,--disable-libxml2,libxml2,libxml2"
-PACKAGECONFIG[x11] = "--with-x,--without-x,virtual/libx11 cairo,cairo"
-PACKAGECONFIG[pci] = "--enable-pci,--disable-pci,libpciaccess,libpciaccess"
-
-# Split hwloc library into separate subpackage
-PACKAGES_prepend = " libhwloc "
-FILES_libhwloc += "${libdir}/libhwloc.so.*"
-RDEPENDS_${PN} += "libhwloc (= ${EXTENDPKGV})"
diff --git a/meta-openembedded/meta-oe/recipes-extended/iotop/iotop_0.6.bb b/meta-openembedded/meta-oe/recipes-extended/iotop/iotop_0.6.bb
index 5dcae98..94643cd 100644
--- a/meta-openembedded/meta-oe/recipes-extended/iotop/iotop_0.6.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/iotop/iotop_0.6.bb
@@ -12,6 +12,9 @@
 SRC_URI[md5sum] = "5ef9456b26d7694abf3101a72e1e0d1d"
 SRC_URI[sha256sum] = "3adea2a24eda49bbbaeb4e6ed2042355b441dbd7161e883067a02bfc8dcef75b"
 
+UPSTREAM_CHECK_URI = "http://repo.or.cz/iotop.git/tags"
+UPSTREAM_CHECK_REGEX = "iotop-(?P<pver>\d+(\.\d+)+)"
+
 inherit distutils
 
 do_install_append() {
@@ -21,4 +24,4 @@
 
 RDEPENDS_${PN} = "python-curses python-textutils \
                   python-codecs python-ctypes python-pprint \
-                  python-shell"
+                  python-shell python-subprocess"
diff --git a/meta-openembedded/meta-oe/recipes-extended/isomd5sum/files/0001-tweak-install-prefix.patch b/meta-openembedded/meta-oe/recipes-extended/isomd5sum/files/0001-tweak-install-prefix.patch
index bcfc117..61310cc 100644
--- a/meta-openembedded/meta-oe/recipes-extended/isomd5sum/files/0001-tweak-install-prefix.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/isomd5sum/files/0001-tweak-install-prefix.patch
@@ -1,7 +1,7 @@
-From cffe4767f89ea0b54b57e8bf9065a08a9c38d46e Mon Sep 17 00:00:00 2001
+From a70513ff59da3c593c76330afb445c21761c3268 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Tue, 18 Jul 2017 21:53:00 -0400
-Subject: [PATCH] tweak install prefix
+Date: Tue, 31 Jul 2018 17:14:24 +0800
+Subject: [PATCH 1/2] tweak install prefix
 
 Upstream-Status: Inappropriate [oe specific]
 
@@ -11,7 +11,7 @@
  1 file changed, 14 insertions(+), 14 deletions(-)
 
 diff --git a/Makefile b/Makefile
-index df16a3b..fbdfcb4 100644
+index c98cf35..7c5907f 100644
 --- a/Makefile
 +++ b/Makefile
 @@ -39,26 +39,26 @@ pyisomd5sum.so: $(PYOBJS)
@@ -43,7 +43,7 @@
 -	install -m 0644 libcheckisomd5.h $(DESTDIR)/usr/include/
 -	install -m 0644 libimplantisomd5.a $(DESTDIR)/usr/$(LIBDIR)
 -	install -m 0644 libcheckisomd5.a $(DESTDIR)/usr/$(LIBDIR)
--	sed "s#@VERSION@#${VERSION}#g; s#@includedir@#${DESTDIR}/usr/include#g; s#@libdir@#${DESTDIR}/usr/${LIBDIR}#g" isomd5sum.pc.in > ${DESTDIR}/usr/share/pkgconfig/isomd5sum.pc
+-	sed "s#@VERSION@#${VERSION}#g; s#@includedir@#/usr/include#g; s#@libdir@#/usr/${LIBDIR}#g" isomd5sum.pc.in > ${DESTDIR}/usr/share/pkgconfig/isomd5sum.pc
 +	install -d -m 0755 $(DESTDIR)$(includedir)
 +	install -d -m 0755 $(DESTDIR)$(libdir)
 +	install -d -m 0755 $(DESTDIR)${datadir}/pkgconfig
@@ -51,10 +51,10 @@
 +	install -m 0644 libcheckisomd5.h $(DESTDIR)$(includedir)
 +	install -m 0644 libimplantisomd5.a $(DESTDIR)$(libdir)
 +	install -m 0644 libcheckisomd5.a $(DESTDIR)$(libdir)
-+	sed "s#@VERSION@#${VERSION}#g; s#@includedir@#${DESTDIR}/usr/include#g; s#@libdir@#${DESTDIR}/usr/${LIBDIR}#g" isomd5sum.pc.in > ${DESTDIR}${datadir}/pkgconfig/isomd5sum.pc
++	sed "s#@VERSION@#${VERSION}#g; s#@includedir@#$(includedir)#g; s#@libdir@#$(libdir)#g" isomd5sum.pc.in > ${DESTDIR}${datadir}/pkgconfig/isomd5sum.pc
  
  clean:
  	rm -f *.o *.so *.pyc *.a .depend *~
 -- 
-2.8.1
+2.7.4
 
diff --git a/meta-openembedded/meta-oe/recipes-extended/isomd5sum/isomd5sum_1.2.1.bb b/meta-openembedded/meta-oe/recipes-extended/isomd5sum/isomd5sum_1.2.1.bb
deleted file mode 100644
index 815113e..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/isomd5sum/isomd5sum_1.2.1.bb
+++ /dev/null
@@ -1,35 +0,0 @@
-SUMMARY = "Tools for taking the MD5 sum of ISO images"
-DESCRIPTION = "Tools for taking the MD5 sum of ISO images"
-
-DEPENDS = "popt python3 openssl curl popt-native"
-RDEPENDS_${PN} = "openssl curl"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=8ca43cbc842c2336e835926c2166c28b"
-
-SRC_URI = "git://github.com/rhinstaller/isomd5sum.git;branch=master \
-           file://0001-tweak-install-prefix.patch \
-           file://0002-fix-parallel-error.patch \
-"
-
-S = "${WORKDIR}/git"
-inherit python3native
-
-EXTRA_OEMAKE += " \
-    DESTDIR='${D}' \
-    PYTHONINCLUDE='-I${STAGING_INCDIR}/${PYTHON_DIR}${PYTHON_ABI}' \
-    PYTHONSITEPACKAGES='${PYTHON_SITEPACKAGES_DIR}' \
-"
-
-do_install () {
-    oe_runmake install
-}
-
-PACKAGES += "${PYTHON_PN}-${PN} ${PYTHON_PN}-${PN}-dbg"
-
-FILES_${PYTHON_PN}-${PN} = "${PYTHON_SITEPACKAGES_DIR}/pyisomd5sum.so"
-FILES_${PYTHON_PN}-${PN}-dbg = "${PYTHON_SITEPACKAGES_DIR}/.debug/pyisomd5sum.so"
-
-SRCREV = "69dc036d20761715b734ca9cc59ecc6dc8145026"
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-extended/isomd5sum/isomd5sum_1.2.3.bb b/meta-openembedded/meta-oe/recipes-extended/isomd5sum/isomd5sum_1.2.3.bb
new file mode 100644
index 0000000..83e8385
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/isomd5sum/isomd5sum_1.2.3.bb
@@ -0,0 +1,36 @@
+SUMMARY = "Tools for taking the MD5 sum of ISO images"
+DESCRIPTION = "Tools for taking the MD5 sum of ISO images"
+
+DEPENDS = "popt python3 openssl curl popt-native"
+RDEPENDS_${PN} = "openssl curl"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=8ca43cbc842c2336e835926c2166c28b"
+
+SRC_URI = "git://github.com/rhinstaller/isomd5sum.git;branch=master \
+           file://0001-tweak-install-prefix.patch \
+           file://0002-fix-parallel-error.patch \
+"
+
+S = "${WORKDIR}/git"
+inherit python3native
+
+EXTRA_OEMAKE += " \
+    DESTDIR='${D}' \
+    PYTHONINCLUDE='-I${STAGING_INCDIR}/${PYTHON_DIR}${PYTHON_ABI}' \
+    PYTHONSITEPACKAGES='${PYTHON_SITEPACKAGES_DIR}' \
+"
+
+do_install () {
+    oe_runmake install
+}
+
+PACKAGES += "${PYTHON_PN}-${PN}"
+
+RPROVIDES_${PN}-dbg += "${PYTHON_PN}-${PN}-dbg"
+
+FILES_${PYTHON_PN}-${PN} = "${PYTHON_SITEPACKAGES_DIR}/pyisomd5sum.so"
+
+SRCREV = "7860901f726f5d92689cb67243cc7f981f21f74b"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-extended/jansson/jansson_2.11.bb b/meta-openembedded/meta-oe/recipes-extended/jansson/jansson_2.11.bb
new file mode 100644
index 0000000..370fa22
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/jansson/jansson_2.11.bb
@@ -0,0 +1,12 @@
+SUMMARY = "Jansson is a C library for encoding, decoding and manipulating JSON data"
+HOMEPAGE = "http://www.digip.org/jansson/"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=8b70213ec164c7bd876ec2120ba52f61"
+
+SRC_URI = "http://www.digip.org/jansson/releases/${BPN}-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "7af071db9970441e1eaaf25662310e33"
+SRC_URI[sha256sum] = "6e85f42dabe49a7831dbdd6d30dca8a966956b51a9a50ed534b82afc3fa5b2f4"
+
+inherit autotools pkgconfig
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/jansson/jansson_2.9.bb b/meta-openembedded/meta-oe/recipes-extended/jansson/jansson_2.9.bb
deleted file mode 100644
index 455b374..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/jansson/jansson_2.9.bb
+++ /dev/null
@@ -1,12 +0,0 @@
-SUMMARY = "Jansson is a C library for encoding, decoding and manipulating JSON data"
-HOMEPAGE = "http://www.digip.org/jansson/"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=8b70213ec164c7bd876ec2120ba52f61"
-
-SRC_URI = "http://www.digip.org/jansson/releases/${BPN}-${PV}.tar.gz"
-
-SRC_URI[md5sum] = "84abaefee9502b2f2ff394d758f160c7"
-SRC_URI[sha256sum] = "0ad0d074ca049a36637e7abef755d40849ad73e926b93914ce294927b97bd2a5"
-
-inherit autotools pkgconfig
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/konkretcmpi/konkretcmpi_0.9.2.bb b/meta-openembedded/meta-oe/recipes-extended/konkretcmpi/konkretcmpi_0.9.2.bb
index 0f798d2..f62cf6b 100644
--- a/meta-openembedded/meta-oe/recipes-extended/konkretcmpi/konkretcmpi_0.9.2.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/konkretcmpi/konkretcmpi_0.9.2.bb
@@ -30,9 +30,10 @@
     rm -rf ${D}${datadir}
 }
 
-PACKAGES =+ "${PN}-python ${PN}-python-dbg"
+PACKAGES =+ "${PN}-python"
+
+RPROVIDES_${PN}-dbg += "${PN}-python-dbg"
 
 FILES_${PN}-python = "${libdir}/python2.7/site-packages/konkretmof.py* ${libdir}/python2.7/site-packages/_konkretmof.so"
-FILES_${PN}-python-dbg = "${libdir}/python2.7/site-packages/.debug/*"
 
 BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-extended/lcdproc/lcdproc/0001-include-asm-ioctl.h-explicitly.patch b/meta-openembedded/meta-oe/recipes-extended/lcdproc/lcdproc/0001-include-asm-ioctl.h-explicitly.patch
deleted file mode 100644
index abdedad..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/lcdproc/lcdproc/0001-include-asm-ioctl.h-explicitly.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From b5ca64c7398d516e9845d849e8306df7ac024bc4 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 11 Apr 2017 13:59:34 -0700
-Subject: [PATCH] include asm/ioctl.h explicitly
-
-Needed for _IOC* defines
-
-helps compiling with musl where this file is
-not included indirectly
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- server/drivers/hd44780-pifacecad.c | 1 +
- server/drivers/hd44780-spi.c       | 1 +
- 2 files changed, 2 insertions(+)
-
-diff --git a/server/drivers/hd44780-pifacecad.c b/server/drivers/hd44780-pifacecad.c
-index 43db19c..e2798ad 100644
---- a/server/drivers/hd44780-pifacecad.c
-+++ b/server/drivers/hd44780-pifacecad.c
-@@ -54,6 +54,7 @@
- #include <unistd.h>
- #include <fcntl.h>
- #include <sys/ioctl.h>
-+#include <asm/ioctl.h>
- #include <stdint.h>
- #include <linux/spi/spidev.h>
- 
-diff --git a/server/drivers/hd44780-spi.c b/server/drivers/hd44780-spi.c
-index 5f94333..8a4015b 100644
---- a/server/drivers/hd44780-spi.c
-+++ b/server/drivers/hd44780-spi.c
-@@ -29,6 +29,7 @@
- #include <unistd.h>
- #include <fcntl.h>
- #include <sys/ioctl.h>
-+#include <asm/ioctl.h>
- #include <stdint.h>
- #include <linux/spi/spidev.h>
- 
--- 
-2.12.2
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/lcdproc/lcdproc_git.bb b/meta-openembedded/meta-oe/recipes-extended/lcdproc/lcdproc_git.bb
index 96bc826..93a09f2 100644
--- a/meta-openembedded/meta-oe/recipes-extended/lcdproc/lcdproc_git.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/lcdproc/lcdproc_git.bb
@@ -9,17 +9,18 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=18810669f13b87348459e611d31ab760 \
                     file://README.md;beginline=107;md5=5c927ce1742d6d5cddc45b7ad6230f75"
 
-BASEPV = "0.5.8"
+BASEPV = "0.5.9"
 PV = "${BASEPV}+git${SRCPV}"
-SRCREV = "f5156e2e41bb418f14761afea22eee8efb49fb85"
-SRC_URI = "git://github.com/lcdproc/lcdproc;branch=lcdproc-${BASEPV} \
-           file://0001-include-asm-ioctl.h-explicitly.patch \
+SRCREV = "a4b5a7e058fdd0d914a61138748b589c0128b45b"
+SRC_URI = "git://github.com/lcdproc/lcdproc \
            "
 
 S = "${WORKDIR}/git"
 
 inherit autotools pkgconfig update-rc.d
 
+COMPATIBLE_HOST_arm_libc-musl = "null"
+
 LCD_DRIVERS ?= "all,!irman,!svga"
 LCD_DEFAULT_DRIVER ?= "curses"
 
diff --git a/meta-openembedded/meta-oe/recipes-extended/libblockdev/files/0001-fix-configure-and-compile-failures.patch b/meta-openembedded/meta-oe/recipes-extended/libblockdev/files/0001-fix-configure-and-compile-failures.patch
deleted file mode 100644
index 745883e..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/libblockdev/files/0001-fix-configure-and-compile-failures.patch
+++ /dev/null
@@ -1,79 +0,0 @@
-From 86686ccbf43c5d9e8c8dc97c66ba09e522050e5e Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Thu, 27 Jul 2017 10:06:24 +0800
-Subject: [PATCH 1/3] fix configure and compile failures
-
-1. Fix do_configure failure
----------------------------
-|Checking header volume_key/libvolume_key.h existence and usability.
-../tmp/6tvtK.c:1:38: fatal error: volume_key/libvolume_key.h:
-No such file or directory
-| #include <volume_key/libvolume_key.h>
-|Checking header dmraid/dmraid.h existence and usability.../tmp/
-ktVJ6.c:1:27: fatal error: dmraid/dmraid.h: No such file or directory
-| #include <dmraid/dmraid.h>
----------------------------
-We explictly add volume_key and dmraid to DEPENDS, do not need
-configure to test.
-
-2. Fix config.h not found
-Add it to configure.ac
-
-3. Correct AC_DEFINE
-...
-autoheader: warning: missing template: LIBMOUNT_NEW_ERR_API
-autoheader: Use AC_DEFINE([LIBMOUNT_NEW_ERR_API], [], [Description])
-...
-
-Upstream-Status: Inappropriate [oe specific]
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- configure.ac | 10 ++++------
- 1 file changed, 4 insertions(+), 6 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index d41a307..b036e04 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -9,6 +9,8 @@ AC_DISABLE_STATIC
- AM_INIT_AUTOMAKE([foreign -Wall -Werror -Wno-syntax -Wno-portability])
- AC_CONFIG_MACRO_DIR([m4])
- 
-+AC_CONFIG_HEADERS([config.h])
-+
- AM_PATH_PYTHON
- 
- AM_PROG_AR
-@@ -154,7 +156,6 @@ LIBBLOCKDEV_PKG_CHECK_MODULES([KMOD], [libkmod >= 19])
- AS_IF([test "x$with_crypto" != "xno"],
-       [LIBBLOCKDEV_PKG_CHECK_MODULES([CRYPTSETUP], [libcryptsetup >= 1.6.7])
-        LIBBLOCKDEV_PKG_CHECK_MODULES([NSS], [nss >= 3.18.0])
--       LIBBLOCKDEV_CHECK_HEADER([volume_key/libvolume_key.h], [$GLIB_CFLAGS $NSS_CFLAGS], [libvolume_key.h not available])
-       ],
-       [])
- 
-@@ -162,10 +163,6 @@ AS_IF([test "x$with_dm" != "xno" -o "x$with_lvm" != "xno" -o "x$with_lvm_dbus" !
-       [LIBBLOCKDEV_PKG_CHECK_MODULES([DEVMAPPER], [devmapper >= 1.02.93])],
-       [])
- 
--AS_IF([test "x$with_dm" != "xno"],
--      [LIBBLOCKDEV_CHECK_HEADER([dmraid/dmraid.h], [], [dmraid.h not available])],
--      [])
--
- AS_IF([test "x$with_part" != "xno" -o "x$with_fs" != "xno"],
-       [LIBBLOCKDEV_PKG_CHECK_MODULES([PARTED], [libparted >= 3.1])]
-       [])
-@@ -174,7 +171,8 @@ AS_IF([test "x$with_fs" != "xno"],
-       [LIBBLOCKDEV_PKG_CHECK_MODULES([MOUNT], [mount >= 2.23.0])
-        # new versions of libmount has some new functions we can use
-        AS_IF([$PKG_CONFIG --atleast-version=2.30.0 mount],
--             [AC_DEFINE([LIBMOUNT_NEW_ERR_API])], [])
-+             [AC_DEFINE([LIBMOUNT_NEW_ERR_API], [1], [new versions of libmount has some new functions we can use])],
-+             [])
- 
-        LIBBLOCKDEV_PKG_CHECK_MODULES([BLKID], [blkid >= 2.23.0])
-        # older versions of libblkid don't support BLKID_SUBLKS_BADCSUM so let's just
--- 
-2.14.3
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/libblockdev/files/0002-remove-python2-support.patch b/meta-openembedded/meta-oe/recipes-extended/libblockdev/files/0002-remove-python2-support.patch
deleted file mode 100644
index 0719759..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/libblockdev/files/0002-remove-python2-support.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 40dae7ea6450cb30f066da8443eabf063b5b0ad7 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Mon, 8 May 2017 02:05:40 -0400
-Subject: [PATCH 2/3] remove python2 support
-
-Only python3 is required.
-
-Upstream-Status: Inappropriate [wr-installer specific]
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- src/python/gi/overrides/Makefile.am | 5 -----
- 1 file changed, 5 deletions(-)
-
-diff --git a/src/python/gi/overrides/Makefile.am b/src/python/gi/overrides/Makefile.am
-index a2927ac..6385502 100644
---- a/src/python/gi/overrides/Makefile.am
-+++ b/src/python/gi/overrides/Makefile.am
-@@ -1,8 +1,3 @@
--pylibdir = $(shell python -c "import distutils.sysconfig; print(distutils.sysconfig.get_python_lib(1,0,prefix='${exec_prefix}'))")
--
--overridesdir = $(pylibdir)/gi/overrides
--dist_overrides_DATA = BlockDev.py
--
- if WITH_PYTHON3
- py3libdir = $(shell python3 -c "import distutils.sysconfig; print(distutils.sysconfig.get_python_lib(1,0,prefix='${exec_prefix}'))")
- py3overridesdir = $(py3libdir)/gi/overrides
--- 
-1.8.3.1
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/libblockdev/files/0003-remove-dmraid-while-compiling-with-with-dm.patch b/meta-openembedded/meta-oe/recipes-extended/libblockdev/files/0003-remove-dmraid-while-compiling-with-with-dm.patch
deleted file mode 100644
index ac5b5e2..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/libblockdev/files/0003-remove-dmraid-while-compiling-with-with-dm.patch
+++ /dev/null
@@ -1,492 +0,0 @@
-From bda7c937ba544182a5cae2a9cf0c173e0ba268c9 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Thu, 27 Jul 2017 09:47:23 +0800
-Subject: [PATCH 3/3] remove dmraid while compiling with --with-dm
-
-Fix the following failure:
-
-...
-Perhaps you should add the directory containing `dmraid.pc'
-to the PKG_CONFIG_PATH environment variable
-No package 'dmraid' found
-...
-
-...
-../../../git/src/plugins/dm.c:24:10: fatal error: dmraid/dmraid.h: No
-such file or directory
- #include <dmraid/dmraid.h>
-          ^~~~~~~~~~~~~~~~~
-...
-
-Upstream-Status: Inappropriate [oe specific]
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- src/lib/plugin_apis/dm.api          |  50 ------
- src/plugins/Makefile.am             |   2 +-
- src/plugins/dm.c                    | 330 ------------------------------------
- src/plugins/dm.h                    |   5 -
- src/python/gi/overrides/BlockDev.py |   6 -
- 5 files changed, 1 insertion(+), 392 deletions(-)
-
-diff --git a/src/lib/plugin_apis/dm.api b/src/lib/plugin_apis/dm.api
-index 04fd8d8..5d30b6a 100644
---- a/src/lib/plugin_apis/dm.api
-+++ b/src/lib/plugin_apis/dm.api
-@@ -111,53 +111,3 @@ gchar* bd_dm_get_subsystem_from_name (const gchar *device_name, GError **error);
-  * Tech category: %BD_DM_TECH_MAP-%BD_DM_TECH_MODE_QUERY
-  */
- gboolean bd_dm_map_exists (const gchar *map_name, gboolean live_only, gboolean active_only, GError **error);
--
--/**
-- * bd_dm_get_member_raid_sets:
-- * @name: (allow-none): name of the member
-- * @uuid: (allow-none): uuid of the member
-- * @major: major number of the device or -1 if not specified
-- * @minor: minor number of the device or -1 if not specified
-- * @error: (out): variable to store error (if any)
-- *
-- * Returns: (transfer full) (array zero-terminated=1): list of names of the RAID sets related to
-- * the member or %NULL in case of error
-- *
-- * One of @name, @uuid or @major:@minor has to be given.
-- *
-- * Tech category: %BD_DM_TECH_RAID-%BD_DM_TECH_MODE_QUERY
-- */
--gchar** bd_dm_get_member_raid_sets (const gchar *name, const gchar *uuid, gint major, gint minor, GError **error);
--
--/**
-- * bd_dm_activate_raid_set:
-- * @name: name of the DM RAID set to activate
-- * @error: (out): variable to store error (if any)
-- *
-- * Returns: whether the RAID set @name was successfully activate or not
-- *
-- * Tech category: %BD_DM_TECH_RAID-%BD_DM_TECH_CREATE_ACTIVATE
-- */
--gboolean bd_dm_activate_raid_set (const gchar *name, GError **error);
--
--/**
-- * bd_dm_deactivate_raid_set:
-- * @name: name of the DM RAID set to deactivate
-- * @error: (out): variable to store error (if any)
-- *
-- * Returns: whether the RAID set @name was successfully deactivate or not
-- *
-- * Tech category: %BD_DM_TECH_RAID-%BD_DM_TECH_REMOVE_DEACTIVATE
-- */
--gboolean bd_dm_deactivate_raid_set (const gchar *name, GError **error);
--
--/**
-- * bd_dm_get_raid_set_type:
-- * @name: name of the DM RAID set to get the type of
-- * @error: (out): variable to store error (if any)
-- *
-- * Returns: string representation of the @name RAID set's type
-- *
-- * Tech category: %BD_DM_TECH_RAID-%BD_DM_TECH_QUERY
-- */
--gchar* bd_dm_get_raid_set_type (const gchar *name, GError **error);
-diff --git a/src/plugins/Makefile.am b/src/plugins/Makefile.am
-index b69c8f7..7575f4a 100644
---- a/src/plugins/Makefile.am
-+++ b/src/plugins/Makefile.am
-@@ -75,7 +75,7 @@ endif
- 
- if WITH_DM
- libbd_dm_la_CFLAGS = $(GLIB_CFLAGS) $(DEVMAPPER_CFLAGS) $(UDEV_CFLAGS) -Wall -Wextra -Werror
--libbd_dm_la_LIBADD = $(GLIB_LIBS) $(DEVMAPPER_LIBS) $(UDEV_LIBS) -ldmraid ${builddir}/../utils/libbd_utils.la
-+libbd_dm_la_LIBADD = $(GLIB_LIBS) $(DEVMAPPER_LIBS) $(UDEV_LIBS) ${builddir}/../utils/libbd_utils.la
- libbd_dm_la_LDFLAGS = -L${srcdir}/../utils/ -version-info 2:0:0 -Wl,--no-undefined
- # Dear author of libdmdraid, VERSION really is not a good name for an enum member!
- libbd_dm_la_CPPFLAGS = -I${builddir}/../../include/ -UVERSION
-diff --git a/src/plugins/dm.c b/src/plugins/dm.c
-index 0e5466c..31ebe96 100644
---- a/src/plugins/dm.c
-+++ b/src/plugins/dm.c
-@@ -21,17 +21,11 @@
- #include <unistd.h>
- #include <blockdev/utils.h>
- #include <libdevmapper.h>
--#include <dmraid/dmraid.h>
- #include <libudev.h>
- 
- #include "dm.h"
- #include "check_deps.h"
- 
--/* macros taken from the pyblock/dmraid.h file plus one more*/
--#define for_each_raidset(_c, _n) list_for_each_entry(_n, LC_RS(_c), list)
--#define for_each_subset(_rs, _n) list_for_each_entry(_n, &(_rs)->sets, list)
--#define for_each_device(_rs, _d) list_for_each_entry(_d, &(_rs)->devs, devs)
--
- /**
-  * SECTION: dm
-  * @short_description: plugin for basic operations with device mapper
-@@ -380,327 +374,3 @@ gboolean bd_dm_map_exists (const gchar *map_name, gboolean live_only, gboolean a
- 
-     return ret;
- }
--
--/**
-- * init_dmraid_stack: (skip)
-- *
-- * Initializes the dmraid stack by creating the library context, discovering
-- * devices, raid sets, etc.
-- */
--static struct lib_context* init_dmraid_stack (GError **error) {
--    gint rc = 0;
--    gchar *argv[] = {"blockdev.dmraid", NULL};
--    struct lib_context *lc;
--
--    /* the code for this function was cherry-picked from the pyblock code */
--    /* XXX: do this all just once, store global lc and provide a reinit
--     *      function? */
--
--    /* initialize dmraid library context */
--    lc = libdmraid_init (1, (gchar **)argv);
--
--    rc = discover_devices (lc, NULL);
--    if (!rc) {
--        g_set_error (error, BD_DM_ERROR, BD_DM_ERROR_RAID_FAIL,
--                     "Failed to discover devices");
--        libdmraid_exit (lc);
--        return NULL;
--    }
--    discover_raid_devices (lc, NULL);
--
--    if (!count_devices (lc, RAID)) {
--        g_set_error (error, BD_DM_ERROR, BD_DM_ERROR_RAID_NO_DEVS,
--                     "No RAIDs discovered");
--        libdmraid_exit (lc);
--        return NULL;
--    }
--
--    argv[0] = NULL;
--    if (!group_set (lc, argv)) {
--        g_set_error (error, BD_DM_ERROR, BD_DM_ERROR_RAID_FAIL,
--                     "Failed to group_set");
--        libdmraid_exit (lc);
--        return NULL;
--    }
--
--    return lc;
--}
--
--/**
-- * raid_dev_matches_spec: (skip)
-- *
-- * Returns: whether the device specified by @sysname matches the spec given by @name,
-- *          @uuid, @major and @minor
-- */
--static gboolean raid_dev_matches_spec (struct raid_dev *raid_dev, const gchar *name, const gchar *uuid, gint major, gint minor) {
--    gchar const *dev_name = NULL;
--    gchar const *dev_uuid;
--    gchar const *major_str;
--    gchar const *minor_str;
--    struct udev *context;
--    struct udev_device *device;
--    gboolean ret = TRUE;
--
--    /* find the second '/' to get name (the rest of the string) */
--    dev_name = strchr (raid_dev->di->path, '/');
--    if (dev_name && strlen (dev_name) > 1) {
--        dev_name++;
--        dev_name = strchr (dev_name, '/');
--    }
--    if (dev_name && strlen (dev_name) > 1) {
--        dev_name++;
--    }
--    else
--        dev_name = NULL;
--
--    /* if we don't have the name, we cannot check any match */
--    g_return_val_if_fail (dev_name, FALSE);
--
--    /* g_return_val_if_fail above checks value of dev_name and returns FALSE if
--     * it is NULL so we don't need to check it here */
--    /* coverity[var_deref_model] */
--    if (name && strcmp (dev_name, name) != 0) {
--        return FALSE;
--    }
--
--    context = udev_new ();
--    device = udev_device_new_from_subsystem_sysname (context, "block", dev_name);
--    dev_uuid = udev_device_get_property_value (device, "UUID");
--    major_str = udev_device_get_property_value (device, "MAJOR");
--    minor_str = udev_device_get_property_value (device, "MINOR");
--
--    if (uuid && (g_strcmp0 (uuid, "") != 0) && (g_strcmp0 (uuid, dev_uuid) != 0))
--        ret = FALSE;
--
--    if (major >= 0 && (atoi (major_str) != major))
--        ret = FALSE;
--
--    if (minor >= 0 && (atoi (minor_str) != minor))
--        ret = FALSE;
--
--    udev_device_unref (device);
--    udev_unref (context);
--
--    return ret;
--}
--
--/**
-- * find_raid_sets_for_dev: (skip)
-- */
--static void find_raid_sets_for_dev (const gchar *name, const gchar *uuid, gint major, gint minor, struct lib_context *lc, struct raid_set *rs, GPtrArray *ret_sets) {
--    struct raid_set *subset = NULL;
--    struct raid_dev *dev = NULL;
--
--    if (T_GROUP(rs) || !list_empty(&(rs->sets))) {
--        for_each_subset (rs, subset)
--            find_raid_sets_for_dev (name, uuid, major, minor, lc, subset, ret_sets);
--    } else {
--        for_each_device (rs, dev) {
--            if (raid_dev_matches_spec (dev, name, uuid, major, minor))
--                g_ptr_array_add (ret_sets, g_strdup (rs->name));
--        }
--    }
--}
--
--/**
-- * bd_dm_get_member_raid_sets:
-- * @name: (allow-none): name of the member
-- * @uuid: (allow-none): uuid of the member
-- * @major: major number of the device or -1 if not specified
-- * @minor: minor number of the device or -1 if not specified
-- * @error: (out): variable to store error (if any)
-- *
-- * Returns: (transfer full) (array zero-terminated=1): list of names of the RAID sets related to
-- * the member or %NULL in case of error
-- *
-- * One of @name, @uuid or @major:@minor has to be given.
-- *
-- * Tech category: %BD_DM_TECH_RAID-%BD_DM_TECH_MODE_QUERY
-- */
--gchar** bd_dm_get_member_raid_sets (const gchar *name, const gchar *uuid, gint major, gint minor, GError **error) {
--    guint64 i = 0;
--    struct lib_context *lc = NULL;
--    struct raid_set *rs = NULL;
--    GPtrArray *ret_sets = g_ptr_array_new ();
--    gchar **ret = NULL;
--
--    lc = init_dmraid_stack (error);
--    if (!lc)
--        /* error is already populated */
--        return NULL;
--
--    for_each_raidset (lc, rs) {
--        find_raid_sets_for_dev (name, uuid, major, minor, lc, rs, ret_sets);
--    }
--
--    /* now create the return value -- NULL-terminated array of strings */
--    ret = g_new0 (gchar*, ret_sets->len + 1);
--    for (i=0; i < ret_sets->len; i++)
--        ret[i] = (gchar*) g_ptr_array_index (ret_sets, i);
--    ret[i] = NULL;
--
--    g_ptr_array_free (ret_sets, FALSE);
--
--    libdmraid_exit (lc);
--    return ret;
--}
--
--/**
-- * find_in_raid_sets: (skip)
-- *
-- * Runs @eval_fn with @data on each set (traversing recursively) and returns the
-- * first RAID set that @eval_fn returns. Thus the @eval_fn should return %NULL
-- * on all RAID sets that don't fulfill the search criteria.
-- */
--static struct raid_set* find_in_raid_sets (struct raid_set *rs, RSEvalFunc eval_fn, gpointer data) {
--    struct raid_set *subset = NULL;
--    struct raid_set *ret = NULL;
--
--    ret = eval_fn (rs, data);
--    if (ret)
--        return ret;
--
--    if (T_GROUP(rs) || !list_empty(&(rs->sets))) {
--        for_each_subset (rs, subset) {
--            ret = find_in_raid_sets (subset, eval_fn, data);
--            if (ret)
--                return ret;
--        }
--    }
--
--    return ret;
--}
--
--static struct raid_set* rs_matches_name (struct raid_set *rs, gpointer *name_data) {
--    gchar *name = (gchar*) name_data;
--
--    if (g_strcmp0 (rs->name, name) == 0)
--        return rs;
--    else
--        return NULL;
--}
--
--static gboolean change_set_by_name (const gchar *name, enum activate_type action, GError **error) {
--    gint rc = 0;
--    struct lib_context *lc = NULL;
--    struct raid_set *iter_rs = NULL;
--    struct raid_set *match_rs = NULL;
--
--    lc = init_dmraid_stack (error);
--    if (!lc)
--        /* error is already populated */
--        return FALSE;
--
--    for_each_raidset (lc, iter_rs) {
--        match_rs = find_in_raid_sets (iter_rs, (RSEvalFunc)rs_matches_name, (gchar *)name);
--        if (match_rs)
--            break;
--    }
--
--    if (!match_rs) {
--        g_set_error (error, BD_DM_ERROR, BD_DM_ERROR_RAID_NO_EXIST,
--                     "RAID set %s doesn't exist", name);
--        libdmraid_exit (lc);
--        return FALSE;
--    }
--
--    rc = change_set (lc, action, match_rs);
--    if (!rc) {
--        g_set_error (error, BD_DM_ERROR, BD_DM_ERROR_RAID_FAIL,
--                     "Failed to activate the RAID set '%s'", name);
--        libdmraid_exit (lc);
--        return FALSE;
--    }
--
--    libdmraid_exit (lc);
--    return TRUE;
--}
--
--/**
-- * bd_dm_activate_raid_set:
-- * @name: name of the DM RAID set to activate
-- * @error: (out): variable to store error (if any)
-- *
-- * Returns: whether the RAID set @name was successfully activate or not
-- *
-- * Tech category: %BD_DM_TECH_RAID-%BD_DM_TECH_CREATE_ACTIVATE
-- */
--gboolean bd_dm_activate_raid_set (const gchar *name, GError **error) {
--    guint64 progress_id = 0;
--    gchar *msg = NULL;
--    gboolean ret = FALSE;
--
--    msg = g_strdup_printf ("Activating DM RAID set '%s'", name);
--    progress_id = bd_utils_report_started (msg);
--    g_free (msg);
--    ret = change_set_by_name (name, A_ACTIVATE, error);
--    bd_utils_report_finished (progress_id, "Completed");
--    return ret;
--}
--
--/**
-- * bd_dm_deactivate_raid_set:
-- * @name: name of the DM RAID set to deactivate
-- * @error: (out): variable to store error (if any)
-- *
-- * Returns: whether the RAID set @name was successfully deactivate or not
-- *
-- * Tech category: %BD_DM_TECH_RAID-%BD_DM_TECH_REMOVE_DEACTIVATE
-- */
--gboolean bd_dm_deactivate_raid_set (const gchar *name, GError **error) {
--    guint64 progress_id = 0;
--    gchar *msg = NULL;
--    gboolean ret = FALSE;
--
--    msg = g_strdup_printf ("Deactivating DM RAID set '%s'", name);
--    progress_id = bd_utils_report_started (msg);
--    g_free (msg);
--    ret = change_set_by_name (name, A_DEACTIVATE, error);
--    bd_utils_report_finished (progress_id, "Completed");
--    return ret;
--}
--
--/**
-- * bd_dm_get_raid_set_type:
-- * @name: name of the DM RAID set to get the type of
-- * @error: (out): variable to store error (if any)
-- *
-- * Returns: string representation of the @name RAID set's type
-- *
-- * Tech category: %BD_DM_TECH_RAID-%BD_DM_TECH_QUERY
-- */
--gchar* bd_dm_get_raid_set_type (const gchar *name, GError **error) {
--    struct lib_context *lc = NULL;
--    struct raid_set *iter_rs = NULL;
--    struct raid_set *match_rs = NULL;
--    const gchar *type = NULL;
--
--    lc = init_dmraid_stack (error);
--    if (!lc)
--        /* error is already populated */
--        return NULL;
--
--    for_each_raidset (lc, iter_rs) {
--        match_rs = find_in_raid_sets (iter_rs, (RSEvalFunc)rs_matches_name, (gchar *)name);
--        if (match_rs)
--            break;
--    }
--
--    if (!match_rs) {
--        g_set_error (error, BD_DM_ERROR, BD_DM_ERROR_RAID_NO_EXIST,
--                     "RAID set %s doesn't exist", name);
--        libdmraid_exit (lc);
--        return NULL;
--    }
--
--    type = get_set_type (lc, match_rs);
--    if (!type) {
--        g_set_error (error, BD_DM_ERROR, BD_DM_ERROR_RAID_FAIL,
--                     "Failed to get RAID set's type");
--        libdmraid_exit (lc);
--        return NULL;
--    }
--
--    libdmraid_exit (lc);
--    return g_strdup (type);
--}
-diff --git a/src/plugins/dm.h b/src/plugins/dm.h
-index 0dce6ac..1ee3788 100644
---- a/src/plugins/dm.h
-+++ b/src/plugins/dm.h
-@@ -1,5 +1,4 @@
- #include <glib.h>
--#include <dmraid/dmraid.h>
- 
- #ifndef BD_DM
- #define BD_DM
-@@ -48,9 +47,5 @@ gboolean bd_dm_map_exists (const gchar *map_name, gboolean live_only, gboolean a
- gchar* bd_dm_name_from_node (const gchar *dm_node, GError **error);
- gchar* bd_dm_node_from_name (const gchar *map_name, GError **error);
- gchar* bd_dm_get_subsystem_from_name (const gchar *device_name, GError **error);
--gchar** bd_dm_get_member_raid_sets (const gchar *name, const gchar *uuid, gint major, gint minor, GError **error);
--gboolean bd_dm_activate_raid_set (const gchar *name, GError **error);
--gboolean bd_dm_deactivate_raid_set (const gchar *name, GError **error);
--gchar* bd_dm_get_raid_set_type (const gchar *name, GError **error);
- 
- #endif  /* BD_DM */
-diff --git a/src/python/gi/overrides/BlockDev.py b/src/python/gi/overrides/BlockDev.py
-index fb3ffb4..eed0a38 100644
---- a/src/python/gi/overrides/BlockDev.py
-+++ b/src/python/gi/overrides/BlockDev.py
-@@ -233,12 +233,6 @@ def dm_create_linear(map_name, device, length, uuid=None):
-     return _dm_create_linear(map_name, device, length, uuid)
- __all__.append("dm_create_linear")
- 
--_dm_get_member_raid_sets = BlockDev.dm_get_member_raid_sets
--@override(BlockDev.dm_get_member_raid_sets)
--def dm_get_member_raid_sets(name=None, uuid=None, major=-1, minor=-1):
--    return _dm_get_member_raid_sets(name, uuid, major, minor)
--__all__.append("dm_get_member_raid_sets")
--
- 
- _loop_setup = BlockDev.loop_setup
- @override(BlockDev.loop_setup)
--- 
-2.14.3
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/libblockdev/files/0004-fix-compile-failure-against-musl-C-library.patch b/meta-openembedded/meta-oe/recipes-extended/libblockdev/files/0004-fix-compile-failure-against-musl-C-library.patch
deleted file mode 100644
index 0b5b809..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/libblockdev/files/0004-fix-compile-failure-against-musl-C-library.patch
+++ /dev/null
@@ -1,50 +0,0 @@
-From 59fbd57acd1df25b1972a131dc6a77a4fe147729 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Thu, 27 Jul 2017 10:45:02 +0800
-Subject: [PATCH] fix compile failure against musl C library
-
-Upstream-Status: Pending
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- src/plugins/crypto.c | 2 +-
- src/plugins/part.c   | 3 ++-
- 2 files changed, 3 insertions(+), 2 deletions(-)
-
-diff --git a/src/plugins/crypto.c b/src/plugins/crypto.c
-index b961471..2d3d251 100644
---- a/src/plugins/crypto.c
-+++ b/src/plugins/crypto.c
-@@ -22,7 +22,7 @@
- #include <libcryptsetup.h>
- #include <nss.h>
- #include <volume_key/libvolume_key.h>
--#include <sys/fcntl.h>
-+#include <fcntl.h>
- #include <sys/ioctl.h>
- #include <linux/random.h>
- #include <locale.h>
-diff --git a/src/plugins/part.c b/src/plugins/part.c
-index 6b2a690..ab490d9 100644
---- a/src/plugins/part.c
-+++ b/src/plugins/part.c
-@@ -25,6 +25,7 @@
- #include <inttypes.h>
- #include <unistd.h>
- #include <sys/file.h>
-+#include <fcntl.h>
- #include <sys/ioctl.h>
- #include <linux/fs.h>
- #include <blockdev/utils.h>
-@@ -1354,7 +1355,7 @@ static gboolean set_gpt_flags (const gchar *device, int part_num, guint64 flags,
-         real_flags |= 0x4000000000000000; /* 1 << 62 */
-     if (flags & BD_PART_FLAG_GPT_NO_AUTOMOUNT)
-         real_flags |= 0x8000000000000000; /* 1 << 63 */
--    mask_str = g_strdup_printf ("%.16"__PRI64_PREFIX"x", real_flags);
-+    mask_str = g_strdup_printf ("%.16"__PRI64"x", real_flags);
- 
-     args[2] = g_strdup_printf ("%d:=:%s", part_num, mask_str);
-     g_free (mask_str);
--- 
-2.14.3
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/libblockdev/files/0005-fix-a-clang-compiling-issue.patch b/meta-openembedded/meta-oe/recipes-extended/libblockdev/files/0005-fix-a-clang-compiling-issue.patch
deleted file mode 100644
index b214f0b..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/libblockdev/files/0005-fix-a-clang-compiling-issue.patch
+++ /dev/null
@@ -1,111 +0,0 @@
-From 9b4a7a4d0653b627d747e00d6b3ada2990caa1d3 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Wed, 9 Aug 2017 13:57:57 +0800
-Subject: [PATCH] fix a clang compiling issue
-
-[snip]
-../../../git/src/plugins/fs.c:2617:26: error: missing field 'start'
-initializer [-Werror,-Wmissing-field-initializers]
-    PedGeometry geom = {0};
-                         ^
-../../../git/src/plugins/fs.c:2618:30: error: missing field 'start'
-initializer [-Werror,-Wmissing-field-initializers]
-    PedGeometry new_geom = {0};
-[snip]
-
-Fix typo s/enum libvk_packet_format format/enum libvk_secret secret_type/
-
-Upstream-Status: Submitted [https://github.com/storaged-project/libblockdev/pull/266]
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- src/plugins/crypto.c  | 6 +++---
- src/plugins/fs/vfat.c | 4 ++--
- src/plugins/part.c    | 4 ++--
- src/utils/exec.c      | 2 +-
- 4 files changed, 8 insertions(+), 8 deletions(-)
-
-diff --git a/src/plugins/crypto.c b/src/plugins/crypto.c
-index 563093e..b961471 100644
---- a/src/plugins/crypto.c
-+++ b/src/plugins/crypto.c
-@@ -970,7 +970,7 @@ gboolean bd_crypto_tc_open (const gchar *device, const gchar *name, const guint8
-     gint ret = 0;
-     guint64 progress_id = 0;
-     gchar *msg = NULL;
--    struct crypt_params_tcrypt params = {0};
-+    struct crypt_params_tcrypt params = {NULL,0,NULL,0,NULL,NULL,NULL,0,0};
- 
-     msg = g_strdup_printf ("Started opening '%s' TrueCrypt/VeraCrypt device", device);
-     progress_id = bd_utils_report_started (msg);
-@@ -1090,7 +1090,7 @@ static gchar *replace_char (gchar *str, gchar orig, gchar new) {
-     return str;
- }
- 
--static gboolean write_escrow_data_file (struct libvk_volume *volume, struct libvk_ui *ui, enum libvk_packet_format format, const gchar *out_path,
-+static gboolean write_escrow_data_file (struct libvk_volume *volume, struct libvk_ui *ui, enum libvk_secret secret_type, const gchar *out_path,
-                                         CERTCertificate *cert, GError **error) {
-     gpointer packet_data = NULL;
-     gsize packet_data_size = 0;
-@@ -1099,7 +1099,7 @@ static gboolean write_escrow_data_file (struct libvk_volume *volume, struct libv
-     gsize bytes_written = 0;
-     GError *tmp_error = NULL;
- 
--    packet_data = libvk_volume_create_packet_asymmetric_with_format (volume, &packet_data_size, format, cert,
-+    packet_data = libvk_volume_create_packet_asymmetric_with_format (volume, &packet_data_size, secret_type, cert,
-                                                                      ui, LIBVK_PACKET_FORMAT_ASYMMETRIC_WRAP_SECRET_ONLY, error);
- 
-     if (!packet_data) {
-diff --git a/src/plugins/fs/vfat.c b/src/plugins/fs/vfat.c
-index 3ed7d4a..5ff7795 100644
---- a/src/plugins/fs/vfat.c
-+++ b/src/plugins/fs/vfat.c
-@@ -376,8 +376,8 @@ BDFSVfatInfo* bd_fs_vfat_get_info (const gchar *device, GError **error) {
-  */
- gboolean bd_fs_vfat_resize (const gchar *device, guint64 new_size, GError **error) {
-     PedDevice *ped_dev = NULL;
--    PedGeometry geom = {0};
--    PedGeometry new_geom = {0};
-+    PedGeometry geom = {NULL, 0, 0, 0};
-+    PedGeometry new_geom = {NULL, 0, 0, 0};
-     PedFileSystem *fs = NULL;
-     PedSector start = 0;
-     PedSector length = 0;
-diff --git a/src/plugins/part.c b/src/plugins/part.c
-index fed8300..6b2a690 100644
---- a/src/plugins/part.c
-+++ b/src/plugins/part.c
-@@ -926,7 +926,7 @@ static PedPartition* add_part_to_disk (PedDevice *dev, PedDisk *disk, BDPartType
-         return NULL;
-     }
- 
--    part = ped_partition_new (disk, type, NULL, geom->start, geom->end);
-+    part = ped_partition_new (disk, (PedPartitionType)type, NULL, geom->start, geom->end);
-     if (!part) {
-         set_parted_error (error, BD_PART_ERROR_FAIL);
-         g_prefix_error (error, "Failed to create new partition on device '%s'", dev->path);
-@@ -1564,7 +1564,7 @@ gboolean bd_part_set_part_flags (const gchar *disk, const gchar *part, guint64 f
-     PedPartition *ped_part = NULL;
-     const gchar *part_num_str = NULL;
-     gint part_num = 0;
--    guint64 i = 0;
-+    int i = 0;
-     gint status = 0;
-     gboolean ret = FALSE;
-     guint64 progress_id = 0;
-diff --git a/src/utils/exec.c b/src/utils/exec.c
-index 11c1489..dcf87e5 100644
---- a/src/utils/exec.c
-+++ b/src/utils/exec.c
-@@ -354,7 +354,7 @@ gboolean bd_utils_exec_and_report_progress (const gchar **argv, const BDExtraArg
-     GIOStatus io_status = G_IO_STATUS_NORMAL;
-     guint i = 0;
-     guint8 completion = 0;
--    GPollFD fds[2] = {{0}, {0}};
-+    GPollFD fds[2] = {{0,0,0}, {0,0,0}};
-     gboolean out_done = FALSE;
-     gboolean err_done = FALSE;
-     GString *stdout_data = g_string_new (NULL);
--- 
-2.14.3
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/libblockdev/libblockdev_2.16.bb b/meta-openembedded/meta-oe/recipes-extended/libblockdev/libblockdev_2.16.bb
deleted file mode 100644
index 0c954aa..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/libblockdev/libblockdev_2.16.bb
+++ /dev/null
@@ -1,51 +0,0 @@
-DESCRIPTION = "libblockdev is a C library supporting GObject introspection for manipulation of \
-block devices. It has a plugin-based architecture where each technology (like \
-LVM, Btrfs, MD RAID, Swap,...) is implemented in a separate plugin, possibly \
-with multiple implementations (e.g. using LVM CLI or the new LVM DBus API)."
-HOMEPAGE = "http://rhinstaller.github.io/libblockdev/"
-LICENSE = "LGPLv2+"
-SECTION = "devel/lib"
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=c07cb499d259452f324bb90c3067d85c"
-
-inherit autotools python3native gobject-introspection
-
-DEPENDS += " \
-    cryptsetup \
-    nss \
-    volume-key \
-    libbytesize \
-    btrfs-tools \
-"
-
-SRCREV = "e2e0899efe8dd3f111ff955fb6c1dc10b0bd2075"
-SRC_URI = " \
-    git://github.com/rhinstaller/libblockdev;branch=master \
-    file://0001-fix-configure-and-compile-failures.patch \
-    file://0002-remove-python2-support.patch \
-    file://0003-remove-dmraid-while-compiling-with-with-dm.patch \
-    file://0005-fix-a-clang-compiling-issue.patch \
-"
-SRC_URI_append_libc-musl = " \
-    file://0004-fix-compile-failure-against-musl-C-library.patch \
-"
-
-S = "${WORKDIR}/git"
-
-RDEPENDS_${PN} += " \
-    lvm2 \
-"
-
-FILES_${PN} += "${PYTHON_SITEPACKAGES_DIR}"
-
-PACKAGECONFIG ??= "python3 lvm dm kmod parted fs"
-PACKAGECONFIG[python3] = "--with-python3, --without-python3,,python3"
-PACKAGECONFIG[lvm] = "--with-lvm, --without-lvm, multipath-tools"
-PACKAGECONFIG[dm] = "--with-dm, --without-dm"
-PACKAGECONFIG[kmod] = "--with-kbd, --without-kbd, kmod"
-PACKAGECONFIG[parted] = "--with-part, --without-part, parted"
-PACKAGECONFIG[fs] = "--with-fs, --without-fs, util-linux"
-PACKAGECONFIG[doc] = "--with-gtk-doc, --without-gtk-doc, gtk-doc-native"
-
-export GIR_EXTRA_LIBS_PATH="${B}/src/utils/.libs"
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/libblockdev/libblockdev_2.18.bb b/meta-openembedded/meta-oe/recipes-extended/libblockdev/libblockdev_2.18.bb
new file mode 100644
index 0000000..35f0cc0
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/libblockdev/libblockdev_2.18.bb
@@ -0,0 +1,43 @@
+DESCRIPTION = "libblockdev is a C library supporting GObject introspection for manipulation of \
+block devices. It has a plugin-based architecture where each technology (like \
+LVM, Btrfs, MD RAID, Swap,...) is implemented in a separate plugin, possibly \
+with multiple implementations (e.g. using LVM CLI or the new LVM DBus API)."
+HOMEPAGE = "http://rhinstaller.github.io/libblockdev/"
+LICENSE = "LGPLv2+"
+SECTION = "devel/lib"
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=c07cb499d259452f324bb90c3067d85c"
+
+inherit autotools python3native gobject-introspection
+
+SRCREV = "0debeb45562ac3d8f6f43f6f942b238abab55be9"
+SRC_URI = " \
+    git://github.com/rhinstaller/libblockdev;branch=master \
+"
+
+S = "${WORKDIR}/git"
+
+FILES_${PN} += "${PYTHON_SITEPACKAGES_DIR}"
+
+PACKAGECONFIG ??= "python3 lvm dm kmod parted fs escrow btrfs crypto mdraid kbd mpath"
+PACKAGECONFIG[python3] = "--with-python3, --without-python3,,python3"
+PACKAGECONFIG[python2] = "--with-python2, --without-python2,,python2"
+PACKAGECONFIG[lvm] = "--with-lvm, --without-lvm, multipath-tools, lvm2"
+PACKAGECONFIG[lvm-dbus] = "--with-lvm_dbus, --without-lvm_dbus, multipath-tools, lvm2"
+PACKAGECONFIG[dm] = "--with-dm, --without-dm, multipath-tools, lvm2"
+PACKAGECONFIG[dmraid] = "--with-dmraid, --without-dmraid"
+PACKAGECONFIG[kmod] = "--with-kbd, --without-kbd, kmod"
+PACKAGECONFIG[parted] = "--with-part, --without-part, parted"
+PACKAGECONFIG[fs] = "--with-fs, --without-fs, util-linux"
+PACKAGECONFIG[doc] = "--with-gtk-doc, --without-gtk-doc, gtk-doc-native"
+PACKAGECONFIG[nvdimm] = "--with-nvdimm, --without-nvdimm"
+PACKAGECONFIG[vdo] = "--with-vdo, --without-vdo"
+PACKAGECONFIG[escrow] = "--with-escrow, --without-escrow, nss volume-key"
+PACKAGECONFIG[btrfs] = "--with-btrfs,--without-btrfs,libbytesize btrfs-tools"
+PACKAGECONFIG[crypto] = "--with-crypto,--without-crypto,cryptsetup nss volume-key"
+PACKAGECONFIG[mdraid] = "--with-mdraid,--without-mdraid,libbytesize"
+PACKAGECONFIG[kbd] = "--with-kbd,--without-kbd,libbytesize"
+PACKAGECONFIG[mpath] = "--with-mpath,--without-mpath, multipath-tools, lvm2"
+
+export GIR_EXTRA_LIBS_PATH="${B}/src/utils/.libs"
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/libcec/files/0001-Explicitly-use-python3-in-pyCecClient.patch b/meta-openembedded/meta-oe/recipes-extended/libcec/files/0001-Explicitly-use-python3-in-pyCecClient.patch
new file mode 100644
index 0000000..ec1f5d0
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/libcec/files/0001-Explicitly-use-python3-in-pyCecClient.patch
@@ -0,0 +1,24 @@
+From 16e8c072709572ccefa6c7f835136db01f031323 Mon Sep 17 00:00:00 2001
+From: Pascal Bach <pascal.bach@siemens.com>
+Date: Fri, 28 Sep 2018 16:56:14 +0200
+Subject: [PATCH] Explicitly use python3 in pyCecClient
+
+Upstream-Status: Submitted [https://github.com/Pulse-Eight/libcec/pull/433]
+
+---
+ src/pyCecClient/pyCecClient.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/pyCecClient/pyCecClient.py b/src/pyCecClient/pyCecClient.py
+index 6d47857..d0504ac 100755
+--- a/src/pyCecClient/pyCecClient.py
++++ b/src/pyCecClient/pyCecClient.py
+@@ -1,4 +1,4 @@
+-#! /usr/bin/python
++#! /usr/bin/python3
+ ## demo of the python-libcec API
+ 
+ # This file is part of the libCEC(R) library.
+-- 
+2.11.0
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/libcec/files/python-install-location.patch b/meta-openembedded/meta-oe/recipes-extended/libcec/files/python-install-location.patch
deleted file mode 100644
index b6be78d..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/libcec/files/python-install-location.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From 330fa6777d51d41eefacff8e98e4250d210fde35 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Javi=20Mart=C3=ADnez?= <javi@flamingalah.net>
-Date: Tue, 13 Dec 2016 22:31:13 +0100
-Subject: [PATCH] Improve/fix installation of Python bindings
-
-Upstream-Status: Backport
-
-dist-packages is a Debian-specific directory for distribution packages (and used in derivatives such as Ubuntu). Therefore changed to site-packages.
----
- src/libcec/cmake/CheckPlatformSupport.cmake | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/libcec/cmake/CheckPlatformSupport.cmake b/src/libcec/cmake/CheckPlatformSupport.cmake
-index fcd0ef7..7661107 100644
---- a/src/libcec/cmake/CheckPlatformSupport.cmake
-+++ b/src/libcec/cmake/CheckPlatformSupport.cmake
-@@ -195,9 +195,9 @@ else()
-               RENAME      __init__.py)
-     else()
-       install(TARGETS     ${SWIG_MODULE_cec_REAL_NAME}
--              DESTINATION lib/python${PYTHON_VERSION}/dist-packages/cec)
-+              DESTINATION lib/python${PYTHON_VERSION}/site-packages/cec)
-       install(FILES       ${CMAKE_BINARY_DIR}/src/libcec/cec.py
--              DESTINATION lib/python${PYTHON_VERSION}/dist-packages/cec
-+              DESTINATION lib/python${PYTHON_VERSION}/site-packages/cec
-               RENAME      __init__.py)
-     endif()
-   endif()
diff --git a/meta-openembedded/meta-oe/recipes-extended/libcec/libcec_git.bb b/meta-openembedded/meta-oe/recipes-extended/libcec/libcec_git.bb
index cb65caa..4ad4997 100644
--- a/meta-openembedded/meta-oe/recipes-extended/libcec/libcec_git.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/libcec/libcec_git.bb
@@ -4,24 +4,30 @@
 LICENSE = "GPLv2+"
 LIC_FILES_CHKSUM = "file://COPYING;md5=e61fd86f9c947b430126181da2c6c715"
 
-DEPENDS = "p8platform udev lockdev ncurses swig-native python3"
+DEPENDS = "p8platform udev ncurses swig-native python3"
 
 DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'libx11 libxrandr', '', d)}"
 DEPENDS_append_rpi = "${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', '', ' userland', d)}"
 
-PV = "4.0.1+gitr${SRCPV}"
+PV = "4.0.2+gitr${SRCPV}"
 
-SRCREV = "2fc92b5f02dca702da92ccc5ed7b805b240ef5df"
+SRCREV = "0a97062dd4b196ceeb003ec41841c7a7edc36dd1"
 SRC_URI = "git://github.com/Pulse-Eight/libcec.git \
-           file://python-install-location.patch"
+           file://0001-Explicitly-use-python3-in-pyCecClient.patch"
 
 S = "${WORKDIR}/git"
 
 inherit cmake pkgconfig
 
+# Put client tools into a separate package
+PACKAGE_BEFORE_PN += "${PN}-tools"
+FILES_${PN}-tools = "${bindir}"
+RDEPENDS_${PN}-tools = "python3-${BPN}"
+
 # Create the wrapper for python3
 PACKAGES += "python3-${BPN}"
-FILES_python3-${BPN} = "${libdir}/python3*"
+FILES_python3-${BPN} = "${libdir}/python3* ${bindir}/py*"
+RDEPENDS_${PN} = "python3-core"
 
 # cec-client and xbmc need the .so present to work :(
 FILES_${PN} += "${libdir}/*.so"
diff --git a/meta-openembedded/meta-oe/recipes-extended/libconfig/libconfig_1.5.bb b/meta-openembedded/meta-oe/recipes-extended/libconfig/libconfig_1.5.bb
deleted file mode 100644
index fb6e50e..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/libconfig/libconfig_1.5.bb
+++ /dev/null
@@ -1,14 +0,0 @@
-SUMMARY = "C/C++ Configuration File Library"
-DESCRIPTION = "Library for manipulating structured configuration files"
-HOMEPAGE = "http://www.hyperrealm.com/libconfig/"
-SECTION = "libs"
-
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=fad9b3332be894bab9bc501572864b29"
-
-SRC_URI = "http://www.hyperrealm.com/${BPN}/${BP}.tar.gz"
-
-inherit autotools-brokensep pkgconfig
-
-SRC_URI[md5sum] = "a939c4990d74e6fc1ee62be05716f633"
-SRC_URI[sha256sum] = "e31daa390d8e4461c8830512fe2e13ba1a3d6a02a2305a02429eec61e68703f6"
diff --git a/meta-openembedded/meta-oe/recipes-extended/libconfig/libconfig_1.7.2.bb b/meta-openembedded/meta-oe/recipes-extended/libconfig/libconfig_1.7.2.bb
new file mode 100644
index 0000000..eb0a2c3
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/libconfig/libconfig_1.7.2.bb
@@ -0,0 +1,19 @@
+SUMMARY = "C/C++ Configuration File Library"
+DESCRIPTION = "Library for manipulating structured configuration files"
+HOMEPAGE = "https://hyperrealm.github.io/libconfig/"
+BUGTRACKER = "https://github.com/hyperrealm/libconfig/issues"
+SECTION = "libs"
+
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=fad9b3332be894bab9bc501572864b29"
+
+SRC_URI = "https://hyperrealm.github.io/libconfig/dist/libconfig-${PV}.tar.gz"
+
+inherit autotools-brokensep pkgconfig
+
+SRC_URI[md5sum] = "6bd98ee3a6e6b9126c82c916d7a9e690"
+SRC_URI[sha256sum] = "7c3c7a9c73ff3302084386e96f903eb62ce06953bb1666235fac74363a16fad9"
+
+FILES_${PN}_append = " \
+    ${libdir}/cmake \
+"
diff --git a/meta-openembedded/meta-oe/recipes-extended/libimobiledevice/files/0001-Fix-warnings-found-with-clang.patch b/meta-openembedded/meta-oe/recipes-extended/libimobiledevice/files/0001-Fix-warnings-found-with-clang.patch
deleted file mode 100644
index f8114a0..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/libimobiledevice/files/0001-Fix-warnings-found-with-clang.patch
+++ /dev/null
@@ -1,51 +0,0 @@
-From ad1be542b87b3186f8ef7bee2c594daefe5bb4c8 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 18 Oct 2016 21:31:40 +0000
-Subject: [PATCH] Fix warnings found with clang
-
-| /mnt/oe/openembedded-core/build/workspace/sources/libplist/src/base64.c:107:12: error: non-void function 'base64decode' should return a value [-Wreturn-type]
-|         if (!buf) return;
-|                   ^
-| /mnt/oe/openembedded-core/build/workspace/sources/libplist/src/base64.c:109:16: error: non-void function 'base64decode' should return a value [-Wreturn-type]
-|         if (len <= 0) return;
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- libcnary/node.c | 2 +-
- src/base64.c    | 4 ++--
- 2 files changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/libcnary/node.c b/libcnary/node.c
-index 1f9f669..d6f3f63 100644
---- a/libcnary/node.c
-+++ b/libcnary/node.c
-@@ -104,7 +104,7 @@ int node_detach(node_t* parent, node_t* child) {
- 
- int node_insert(node_t* parent, unsigned int index, node_t* child)
- {
--	if (!parent || !child) return;
-+	if (!parent || !child) return -1;
- 	child->isLeaf = TRUE;
- 	child->isRoot = FALSE;
- 	child->parent = parent;
-diff --git a/src/base64.c b/src/base64.c
-index 65c6061..531a06a 100644
---- a/src/base64.c
-+++ b/src/base64.c
-@@ -104,9 +104,9 @@ static int base64decode_block(unsigned char *target, const char *data, size_t da
- 
- unsigned char *base64decode(const char *buf, size_t *size)
- {
--	if (!buf) return;
-+	if (!buf) return 0;
- 	size_t len = strlen(buf);
--	if (len <= 0) return;
-+	if (len <= 0) return 0;
- 	unsigned char *outbuf = (unsigned char*)malloc((len/4)*3+3);
- 
- 	unsigned char *line;
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/libimobiledevice/files/fix-parallel-make.patch b/meta-openembedded/meta-oe/recipes-extended/libimobiledevice/files/fix-parallel-make.patch
deleted file mode 100644
index f6ef6f4..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/libimobiledevice/files/fix-parallel-make.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-From 335b25febd4c864ad0ac08479f5cd43fc21b7d73 Mon Sep 17 00:00:00 2001
-From: Nikias Bassen
-Date: Mon, 09 Jul 2012 21:17:15 +0000
-Subject: Fix building with parallel build makeopts
-
----
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 0bad840..155994e 100644
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -57,6 +57,8 @@ ADD_SUBDIRECTORY( plutil )
- ADD_SUBDIRECTORY( include )
- ADD_SUBDIRECTORY( test )
- 
-+ADD_DEPENDENCIES( plist libcnary )
-+
- IF ( SWIG_FOUND AND PYTHONLIBS_FOUND AND PYTHONINTERP_FOUND )
- 	ADD_SUBDIRECTORY( swig )
- ENDIF ( SWIG_FOUND AND PYTHONLIBS_FOUND AND PYTHONINTERP_FOUND )
---
-cgit v0.9.0.2
diff --git a/meta-openembedded/meta-oe/recipes-extended/libimobiledevice/libplist_1.8.bb b/meta-openembedded/meta-oe/recipes-extended/libimobiledevice/libplist_1.8.bb
deleted file mode 100644
index f789796..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/libimobiledevice/libplist_1.8.bb
+++ /dev/null
@@ -1,31 +0,0 @@
-SUMMARY = "A library to handle Apple Property List format whereas it's binary or XML"
-
-LICENSE = "GPLv2 & LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=ebb5c50ab7cab4baeffba14977030c07 \
-                    file://COPYING.LESSER;md5=6ab17b41640564434dda85c06b7124f7"
-
-DEPENDS = "libxml2 glib-2.0 swig python"
-
-inherit cmake pkgconfig
-
-SRC_URI = "http://www.libimobiledevice.org/downloads/libplist-${PV}.tar.bz2 \
-           file://fix-parallel-make.patch \
-           file://0001-Fix-warnings-found-with-clang.patch \
-           "
-
-SRC_URI[md5sum] = "2a9e0258847d50f9760dc3ece25f4dc6"
-SRC_URI[sha256sum] = "a418da3880308199b74766deef2a760a9b169b81a868a6a9032f7614e20500ec"
-
-do_install_append () {
-    if [ -e ${D}${libdir}/python*/site-packages/plist/_plist.so ]; then
-        chrpath -d ${D}${libdir}/python*/site-packages/plist/_plist.so
-    fi
-}
-
-PACKAGES =+ "${PN}-utils ${PN}++ ${PN}-python"
-FILES_${PN} = "${libdir}/libplist${SOLIBS}"
-FILES_${PN}++ = "${libdir}/libplist++${SOLIBS}"
-FILES_${PN}-utils = "${bindir}/*"
-FILES_${PN}-python = "${libdir}/python*/site-packages/*"
-
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/libimobiledevice/libplist_2.0.0.bb b/meta-openembedded/meta-oe/recipes-extended/libimobiledevice/libplist_2.0.0.bb
new file mode 100644
index 0000000..43c1fd5
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/libimobiledevice/libplist_2.0.0.bb
@@ -0,0 +1,29 @@
+SUMMARY = "A library to handle Apple Property List format whereas it's binary or XML"
+
+LICENSE = "GPLv2 & LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=ebb5c50ab7cab4baeffba14977030c07 \
+                    file://COPYING.LESSER;md5=6ab17b41640564434dda85c06b7124f7"
+
+DEPENDS = "libxml2 glib-2.0 swig python"
+
+inherit autotools pkgconfig pythonnative
+
+SRCREV = "62ec804736435fa34e37e66e228e17e2aacee1d7"
+SRC_URI = "git://github.com/libimobiledevice/libplist;protocol=https \
+           "
+
+S = "${WORKDIR}/git"
+
+do_install_append () {
+    if [ -e ${D}${libdir}/python*/site-packages/plist/_plist.so ]; then
+        chrpath -d ${D}${libdir}/python*/site-packages/plist/_plist.so
+    fi
+}
+
+PACKAGES =+ "${PN}-utils ${PN}++ ${PN}-python"
+FILES_${PN} = "${libdir}/libplist${SOLIBS}"
+FILES_${PN}++ = "${libdir}/libplist++${SOLIBS}"
+FILES_${PN}-utils = "${bindir}/*"
+FILES_${PN}-python = "${libdir}/python*/site-packages/*"
+
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/libimobiledevice/libusbmuxd_git.bb b/meta-openembedded/meta-oe/recipes-extended/libimobiledevice/libusbmuxd_git.bb
new file mode 100644
index 0000000..36fc5c8
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/libimobiledevice/libusbmuxd_git.bb
@@ -0,0 +1,16 @@
+DESCRIPTION = "This daemon is in charge of multiplexing connections over USB to an iPhone or iPod touch."
+LICENSE = "LGPL-2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=6ab17b41640564434dda85c06b7124f7"
+
+DEPENDS = "udev libusb1 libplist"
+
+inherit autotools pkgconfig gitpkgv
+
+PKGV = "${GITPKGVTAG}"
+
+SRCREV = "78df9be5fc8222ed53846cb553de9b5d24c85c6c"
+SRC_URI = "git://github.com/libimobiledevice/libusbmuxd;protocol=https"
+
+S = "${WORKDIR}/git"
+
+FILES_${PN} += "${base_libdir}/udev/rules.d/"
diff --git a/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile-1.09/install.patch b/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile-1.09/install.patch
deleted file mode 100644
index a9319ff..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile-1.09/install.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-
-#
-# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher
-#
-
---- liblockfile-1.05/Makefile.in~install
-+++ liblockfile-1.05/Makefile.in
-@@ -20,6 +20,7 @@
- includedir	= @includedir@
- 
- MAILGROUP	= @MAILGROUP@
-+INSTGRP		= $(if $(MAILGROUP),-g $(MAILGROUP))
- 
- all:		@TARGETS@
- install:	@INSTALL_TARGETS@
-@@ -50,25 +51,27 @@
- 		$(CC) $(CFLAGS) -c lockfile.c -o xlockfile.o
- 
- install_static:	static install_common
-+		install -d $(ROOT)$(libdir)
- 		install -m 644 liblockfile.a $(ROOT)$(libdir)
- 
- install_shared:	shared install_common
-+		install -d $(ROOT)$(libdir)
- 		install -m 755 liblockfile.so \
- 			$(ROOT)$(libdir)/liblockfile.so.$(VER)
- 		ln -s liblockfile.so.$(VER) $(ROOT)$(libdir)/liblockfile.so
- 		if test "$(ROOT)" = ""; then @LDCONFIG@; fi
- 
- install_common:
-+		install -d $(ROOT)$(includedir)
- 		install -m 644 lockfile.h maillock.h $(ROOT)$(includedir)
--		if [ "$(MAILGROUP)" != "" ]; then\
--		  install -g $(MAILGROUP) -m 2755 dotlockfile $(ROOT)$(bindir);\
--		else \
--		  install -g root -m 755 dotlockfile $(ROOT)$(bindir); \
--		fi
-+		install -d $(ROOT)$(bindir)
-+		install -m 755 $(INSTGRP) dotlockfile $(ROOT)$(bindir)
-+		install -d $(ROOT)$(mandir)/man1 $(ROOT)$(mandir)/man3
- 		install -m 644 *.1 $(ROOT)$(mandir)/man1
- 		install -m 644 *.3 $(ROOT)$(mandir)/man3
- 
- install_nfslib:	nfslib
-+		install -d $(ROOT)$(nfslockdir)
- 		install -m 755 nfslock.so.$(VER) $(ROOT)$(nfslockdir)
- 		if test "$(ROOT)" = ""; then @LDCONFIG@; fi
- 
diff --git a/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile-1.09/ldflags.patch b/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile-1.09/ldflags.patch
deleted file mode 100644
index eb1d147..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile-1.09/ldflags.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-
-#
-# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher
-#
-
---- liblockfile-1.05/Makefile.in~ldflags
-+++ liblockfile-1.05/Makefile.in
-@@ -34,11 +34,11 @@
- 
- liblockfile.so: liblockfile.a
- 		$(CC) -fPIC -shared -Wl,-soname,liblockfile.so.1 \
--			-o liblockfile.so lockfile.o -lc
-+			-o liblockfile.so lockfile.o $(LDFLAGS) -lc
- 
- nfslock.so.$(VER):	nfslock.o
- 		$(CC) -fPIC -shared -Wl,-soname,nfslock.so.0 \
--			-o nfslock.so.$(NVER) nfslock.o
-+			-o nfslock.so.$(NVER) nfslock.o $(LDFLAGS)
- 
- dotlockfile:	dotlockfile.o xlockfile.o
- 		$(CC) $(LDFLAGS) -o dotlockfile dotlockfile.o xlockfile.o
diff --git a/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile-1.09/liblockfile-fix-install-so-to-man-dir.patch b/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile-1.09/liblockfile-fix-install-so-to-man-dir.patch
deleted file mode 100644
index 27f760c..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile-1.09/liblockfile-fix-install-so-to-man-dir.patch
+++ /dev/null
@@ -1,20 +0,0 @@
-Upstream-Status: Inappropriate [no upstream]
-
-The extend so file is rename from nfslock.so.$(VER) to nfslock.so.$(NVER). That
-causes file nfslock.so.0.1 is installed into manual directory. Fix it.
-
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
-
-diff --git a/Makefile.in b/Makefile.in
-index a589fb8..46a57e8 100644
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -68,7 +68,7 @@ install_common:
- 		install -d $(ROOT)$(bindir)
- 		install -m 755 $(INSTGRP) dotlockfile $(ROOT)$(bindir)
- 		install -d $(ROOT)$(mandir)/man1 $(ROOT)$(mandir)/man3
--		install -m 644 *.1 $(ROOT)$(mandir)/man1
-+		install -m 644 dotlockfile.1 $(ROOT)$(mandir)/man1
- 		install -m 644 *.3 $(ROOT)$(mandir)/man3
- 
- install_nfslib:	nfslib
diff --git a/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile-1.09/liblockfile-fix-nfslib-and-soname.patch b/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile-1.09/liblockfile-fix-nfslib-and-soname.patch
deleted file mode 100644
index ffd7a40..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile-1.09/liblockfile-fix-nfslib-and-soname.patch
+++ /dev/null
@@ -1,54 +0,0 @@
-Upstream-Status: Inappropriate [no upstream]
-
-* nfslib should use NVER instead of VER
-* install the missing soname library
-
-Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
----
- Makefile.in         |    9 ++++++---
- 1 files changed, 5 insertions(+), 3 deletions(-)
-
-diff --git a/Makefile.in b/Makefile.in
-index 836ca9b..a589fb8 100644
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -27,7 +27,7 @@ install:	@INSTALL_TARGETS@
- 
- static:		liblockfile.a dotlockfile
- shared:		liblockfile.so dotlockfile
--nfslib:		nfslock.so.$(VER)
-+nfslib:		nfslock.so.$(NVER)
- 
- liblockfile.a:	lockfile.o
- 		$(AR) rv liblockfile.a lockfile.o
-@@ -36,7 +36,7 @@ liblockfile.so: liblockfile.a
- 		$(CC) -fPIC -shared -Wl,-soname,liblockfile.so.1 \
- 			-o liblockfile.so lockfile.o $(LDFLAGS) -lc
- 
--nfslock.so.$(VER):	nfslock.o
-+nfslock.so.$(NVER):	nfslock.o
- 		$(CC) -fPIC -shared -Wl,-soname,nfslock.so.0 \
- 			-o nfslock.so.$(NVER) nfslock.o $(LDFLAGS)
- 
-@@ -59,6 +59,7 @@ install_shared:	shared install_common
- 		install -m 755 liblockfile.so \
- 			$(ROOT)$(libdir)/liblockfile.so.$(VER)
- 		ln -s liblockfile.so.$(VER) $(ROOT)$(libdir)/liblockfile.so
-+		ln -s liblockfile.so.$(VER) $(ROOT)$(libdir)/liblockfile.so.1
- 		if test "$(ROOT)" = ""; then @LDCONFIG@; fi
- 
- install_common:
-@@ -72,7 +73,9 @@ install_common:
- 
- install_nfslib:	nfslib
- 		install -d $(ROOT)$(nfslockdir)
--		install -m 755 nfslock.so.$(VER) $(ROOT)$(nfslockdir)
-+		install -m 755 nfslock.so.$(NVER) $(ROOT)$(nfslockdir)
-+		ln -sf nfslock.so.$(NVER) $(ROOT)$(libdir)/nfslock.so
-+		ln -sf nfslock.so.$(NVER) $(ROOT)$(libdir)/nfslock.so.0
- 		if test "$(ROOT)" = ""; then @LDCONFIG@; fi
- 
- clean:
--- 
-1.7.9.5
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile/0001-Makefile.in-add-DESTDIR.patch b/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile/0001-Makefile.in-add-DESTDIR.patch
new file mode 100644
index 0000000..ea415dd
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile/0001-Makefile.in-add-DESTDIR.patch
@@ -0,0 +1,54 @@
+From 67843dabe1177840697839b916fd899218893ec7 Mon Sep 17 00:00:00 2001
+From: Mingli Yu <mingli.yu@windriver.com>
+Date: Thu, 19 Jul 2018 00:25:23 -0700
+Subject: [PATCH] Makefile.in: add DESTDIR
+
+Add DESTDIR to fix below error during do_install
+
+| install -d -m 755 -g root -p /usr/include
+| install -d -m 755 -g root -p /usr/lib
+| install -d -m 755 -g root -p /usr/bin
+| install -m 755 nfslock.so.0.1 /usr/lib
+| install -d -m 755 -g root -p /usr/share/man/man1
+| install: cannot create regular file '/usr/lib/nfslock.so.0.1': Permission denied
+| Makefile:78: recipe for target 'install_nfslib' failed
+| make: *** [install_nfslib] Error 1
+| make: *** Waiting for unfinished jobs....
+| install -d -m 755 -g root -p /usr/share/man/man3
+| install -m 644 lockfile.h maillock.h /usr/include
+| install: cannot create regular file '/usr/include/lockfile.h': Permission denied
+| install: cannot create regular file '/usr/include/maillock.h': Permission denied
+| Makefile:64: recipe for target 'install_common' failed
+| make: *** [install_common] Error 1
+
+Upstream-Status: Inappropriate [oe specific]
+
+Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
+---
+ Makefile.in | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index 36a6d23..1e4130e 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -12,11 +12,11 @@ CC		= @CC@
+ 
+ prefix		= $(DESTDIR)@prefix@
+ exec_prefix	= @exec_prefix@
+-bindir		= @bindir@
+-libdir		= @libdir@
+-mandir		= @mandir@
+-nfslockdir	= @nfslockdir@
+-includedir	= @includedir@
++bindir		= $(DESTDIR)@bindir@
++libdir		= $(DESTDIR)@libdir@
++mandir		= $(DESTDIR)@mandir@
++nfslockdir	= $(DESTDIR)@nfslockdir@
++includedir	= $(DESTDIR)@includedir@
+ datarootdir	= @datarootdir@
+ MAILGROUP	= @MAILGROUP@
+ 
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile/0001-Makefile.in-install-nfslock.so-and-nfslock.so.0.patch b/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile/0001-Makefile.in-install-nfslock.so-and-nfslock.so.0.patch
new file mode 100644
index 0000000..a6b297b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile/0001-Makefile.in-install-nfslock.so-and-nfslock.so.0.patch
@@ -0,0 +1,31 @@
+From 631d46efff2a6d8970e202ba5422ebedd17a8d2f Mon Sep 17 00:00:00 2001
+From: Mingli Yu <mingli.yu@windriver.com>
+Date: Thu, 19 Jul 2018 01:00:10 -0700
+Subject: [PATCH] Makefile.in: install nfslock.so and nfslock.so.0
+
+* install the missing soname library
+
+Upstream-Status: Pending
+
+Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
+Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
+---
+ Makefile.in | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/Makefile.in b/Makefile.in
+index 1e4130e..0f1b506 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -77,6 +77,8 @@ install_common:
+ install_nfslib:	nfslib
+ 		install -d -m 755 -g root -p $(nfslockdir)
+ 		install -m 755 nfslock.so.$(NFSVER) $(nfslockdir)
++		ln -sf nfslock.so.$(NFSVER) $(libdir)/nfslock.so
++		ln -sf nfslock.so.$(NFSVER) $(libdir)/nfslock.so.0
+ 		if test "$(DESTDIR)" = ""; then @LDCONFIG@; fi
+ 
+ clean:
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile-1.09/configure.patch b/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile/configure.patch
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile-1.09/configure.patch
rename to meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile/configure.patch
diff --git a/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile/liblockfile-fix-install-so-to-man-dir.patch b/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile/liblockfile-fix-install-so-to-man-dir.patch
new file mode 100644
index 0000000..da25033
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile/liblockfile-fix-install-so-to-man-dir.patch
@@ -0,0 +1,33 @@
+From 363eb1aaeca914c7d36a2cdaf1417e4f87af4c22 Mon Sep 17 00:00:00 2001
+From: Mingli Yu <mingli.yu@windriver.com>
+Date: Thu, 19 Jul 2018 01:12:47 -0700
+Subject: [PATCH] Makefile.in: define dotlockfile.1 installed to man
+
+Explicitly define dotlockfile.1 installed to man
+dir to avoid nfslock.so.0.1 is installed into man
+directory
+
+Upstream-Status: Pending
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
+---
+ Makefile.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index 0f1b506..6e53179 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -71,7 +71,7 @@ install_common:
+ 		else \
+ 		  install -g root -m 755 dotlockfile $(bindir); \
+ 		fi
+-		install -m 644 *.1 $(mandir)/man1
++		install -m 644 dotlockfile.1 $(mandir)/man1
+ 		install -m 644 *.3 $(mandir)/man3
+ 
+ install_nfslib:	nfslib
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile_1.09.bb b/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile_1.09.bb
deleted file mode 100644
index 0c41afa..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile_1.09.bb
+++ /dev/null
@@ -1,35 +0,0 @@
-SUMMARY = "File locking library"
-HOMEPAGE = "http://packages.qa.debian.org/libl/liblockfile.html"
-SECTION = "libs"
-LICENSE = "LGPLv2+ & GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=ac284a60d48eaa4bc811cddc377fa341"
-
-SRC_URI = "${DEBIAN_MIRROR}/main/libl/liblockfile/liblockfile_1.09.orig.tar.gz \
-    ${DEBIAN_MIRROR}/main/libl/liblockfile/liblockfile_1.09-6.debian.tar.bz2;name=1.09-6 \
-    file://install.patch \
-    file://configure.patch \
-    file://ldflags.patch \
-    file://liblockfile-fix-nfslib-and-soname.patch \
-    file://liblockfile-fix-install-so-to-man-dir.patch \
-"
-
-SRC_URI[md5sum] = "2aa269e4405ee8235ff17d1b357c6ae8"
-SRC_URI[sha256sum] = "16979eba05396365e1d6af7100431ae9d32f9bc063930d1de66298a0695f1b7f"
-
-SRC_URI[1.09-6.md5sum] = "a2811807e63a526c07b0f60626e329a2"
-SRC_URI[1.09-6.sha256sum] = "d45eacb7c637c16d03c777c55989d98da494ae9584a0783fe6dbf0db60fa290f"
-
-inherit autotools-brokensep
-
-# set default mailgroup to mail
-# --with-libnfslock specify where to install nfslock.so.NVER
-EXTRA_OECONF = "--enable-shared \
-                --with-mailgroup=mail \
-                --with-libnfslock=${libdir} \
-"
-
-# Makefile using ROOT not DESTDIR
-EXTRA_OEMAKE += "ROOT=${D}"
-
-FILES_${PN} += "${libdir}/nfslock.so.*"
-FILES_${PN}-dev += "${libdir}/nfslock.so"
diff --git a/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile_1.14.bb b/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile_1.14.bb
new file mode 100644
index 0000000..de2c1e3
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/liblockfile/liblockfile_1.14.bb
@@ -0,0 +1,37 @@
+SUMMARY = "File locking library"
+HOMEPAGE = "http://packages.qa.debian.org/libl/liblockfile.html"
+SECTION = "libs"
+LICENSE = "LGPLv2+ & GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=f4ba6ad04fcb05cc30a4cfa5062c55a3"
+
+SRC_URI = "${DEBIAN_MIRROR}/main/libl/liblockfile/liblockfile_1.14.orig.tar.gz \
+    ${DEBIAN_MIRROR}/main/libl/liblockfile/liblockfile_1.14-1.debian.tar.bz2;name=1.14-1 \
+    file://configure.patch \
+    file://0001-Makefile.in-add-DESTDIR.patch \
+    file://0001-Makefile.in-install-nfslock.so-and-nfslock.so.0.patch \
+    file://liblockfile-fix-install-so-to-man-dir.patch \
+"
+
+SRC_URI[md5sum] = "420c056ba0cc4d1477e402f70ba2f5eb"
+SRC_URI[sha256sum] = "ab40d4a3e8cbc204f7e87fea637a4e4ddf9a1149aaa0a723a4267febd0b1d060"
+
+SRC_URI[1.14-1.md5sum] = "f9a44928c3477d218c56252712ebc479"
+SRC_URI[1.14-1.sha256sum] = "73f9be769e602149391588c28f0f4f5cda131e30fb94c0777dbb23d811ac21ff"
+
+S = "${WORKDIR}/${BPN}"
+
+inherit autotools-brokensep
+
+# set default mailgroup to mail
+# --with-libnfslock specify where to install nfslock.so.NVER
+EXTRA_OECONF = "--enable-shared \
+                --with-mailgroup=mail \
+                --with-libnfslock=${libdir} \
+"
+
+# Makefile using DESTDIR as the change in e35f9eabcbba224ecc70b145d5d2a2d81064c195
+# at https://github.com/miquels/liblockfile.git
+EXTRA_OEMAKE += "DESTDIR=${D}"
+
+FILES_${PN} += "${libdir}/nfslock.so.*"
+FILES_${PN}-dev += "${libdir}/nfslock.so"
diff --git a/meta-openembedded/meta-oe/recipes-extended/liblogging/liblogging_1.0.5.bb b/meta-openembedded/meta-oe/recipes-extended/liblogging/liblogging_1.0.5.bb
deleted file mode 100644
index 64a258b..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/liblogging/liblogging_1.0.5.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-SUMMARY = "An easy to use logging library"
-DESCRIPTION = " \
-liblogging (the upstream project) is a collection of several components. \
-Namely: stdlog, journalemu, rfc3195. \
-The stdlog component of liblogging can be viewed as an enhanced version of \
-the syslog(3) API. It retains the easy semantics, but makes the API more \
-sophisticated "behind the scenes" with better support for multiple threads \
-and flexibility for different log destinations (e.g. syslog and systemd \
-journal)."
-SECTION = "libs"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=63fe03535d83726f5655072502bef1bc"
-SRC_URI = "http://download.rsyslog.com/${BPN}/${BPN}-${PV}.tar.gz"
-
-SRC_URI[md5sum] = "44b8ce2daa1bfb84c9feaf42f9925fd7"
-SRC_URI[sha256sum] = "310dc1691279b7a669d383581fe4b0babdc7bf75c9b54a24e51e60428624890b"
-
-inherit autotools pkgconfig
-
-EXTRA_OECONF = "--disable-man-pages"
-
-PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
-PACKAGECONFIG[systemd] = "--enable-journal, --disable-journal, systemd"
diff --git a/meta-openembedded/meta-oe/recipes-extended/liblogging/liblogging_1.0.6.bb b/meta-openembedded/meta-oe/recipes-extended/liblogging/liblogging_1.0.6.bb
new file mode 100644
index 0000000..bb59845
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/liblogging/liblogging_1.0.6.bb
@@ -0,0 +1,23 @@
+SUMMARY = "An easy to use logging library"
+DESCRIPTION = " \
+liblogging (the upstream project) is a collection of several components. \
+Namely: stdlog, journalemu, rfc3195. \
+The stdlog component of liblogging can be viewed as an enhanced version of \
+the syslog(3) API. It retains the easy semantics, but makes the API more \
+sophisticated "behind the scenes" with better support for multiple threads \
+and flexibility for different log destinations (e.g. syslog and systemd \
+journal)."
+SECTION = "libs"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=63fe03535d83726f5655072502bef1bc"
+SRC_URI = "http://download.rsyslog.com/${BPN}/${BPN}-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "f215c7e7ac6cfd1f5dabdba08c522b29"
+SRC_URI[sha256sum] = "338c6174e5c8652eaa34f956be3451f7491a4416ab489aef63151f802b00bf93"
+
+inherit autotools pkgconfig
+
+EXTRA_OECONF = "--disable-man-pages"
+
+PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
+PACKAGECONFIG[systemd] = "--enable-journal, --disable-journal, systemd"
diff --git a/meta-openembedded/meta-oe/recipes-extended/libpwquality/libpwquality_1.4.0.bb b/meta-openembedded/meta-oe/recipes-extended/libpwquality/libpwquality_1.4.0.bb
index 2c96063..9fb25cd 100644
--- a/meta-openembedded/meta-oe/recipes-extended/libpwquality/libpwquality_1.4.0.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/libpwquality/libpwquality_1.4.0.bb
@@ -12,20 +12,19 @@
 SRC_URI[md5sum] = "b8defcc7280a90e9400d6689c93a279c"
 SRC_URI[sha256sum] = "1de6ff046cf2172d265a2cb6f8da439d894f3e4e8157b056c515515232fade6b"
 
+UPSTREAM_CHECK_URI = "https://github.com/libpwquality/libpwquality/releases"
+
 S = "${WORKDIR}/${SRCNAME}-${PV}"
 
-DEPENDS = "cracklib virtual/gettext python3"
-RDEPENDS_python3-libpwquality = "${PN}"
+DEPENDS = "cracklib virtual/gettext"
 
-inherit autotools python3native gettext
+inherit autotools distutils3-base gettext
 
 B = "${S}"
 
 export PYTHON_DIR
 export BUILD_SYS
 export HOST_SYS
-export STAGING_LIBDIR
-export STAGING_INCDIR
 
 EXTRA_OECONF += "--with-python-rev=${PYTHON_BASEVERSION} \
                  --with-python-binary=${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} \
@@ -36,10 +35,7 @@
 PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'pam', '', d)}"
 PACKAGECONFIG[pam] = "--enable-pam, --disable-pam, libpam"
 
-PACKAGES += "python3-libpwquality python3-libpwquality-dbg"
 FILES_${PN} += "${libdir}/security/pam_pwquality.so"
 FILES_${PN}-dbg += "${libdir}/security/.debug"
 FILES_${PN}-staticdev += "${libdir}/security/pam_pwquality.a"
 FILES_${PN}-dev += "${libdir}/security/pam_pwquality.la"
-FILES_python3-${PN} = "${PYTHON_SITEPACKAGES_DIR}/*"
-FILES_python3-${PN}-dbg = "${PYTHON_SITEPACKAGES_DIR}/.debug"
diff --git a/meta-openembedded/meta-oe/recipes-extended/libreport/files/0001-Makefile.am-remove-doc-and-apidoc.patch b/meta-openembedded/meta-oe/recipes-extended/libreport/files/0001-Makefile.am-remove-doc-and-apidoc.patch
index 9b328a1..97fb097 100644
--- a/meta-openembedded/meta-oe/recipes-extended/libreport/files/0001-Makefile.am-remove-doc-and-apidoc.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/libreport/files/0001-Makefile.am-remove-doc-and-apidoc.patch
@@ -1,7 +1,7 @@
-From db32ba60ca75d288d3ac08b54256cb74d9e1581a Mon Sep 17 00:00:00 2001
+From 1f7d106c7d982fe055addc8d883b161202233175 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Wed, 26 Apr 2017 03:47:58 -0400
-Subject: [PATCH 1/3] Makefile.am: remove doc and apidoc
+Subject: [PATCH 1/4] Makefile.am: remove doc and apidoc
 
 There was a failure at do_install time, so remove doc to workaround.
 
@@ -13,7 +13,7 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/Makefile.am b/Makefile.am
-index c6ab640..fb09fc1 100644
+index 9ad827c..34364a8 100644
 --- a/Makefile.am
 +++ b/Makefile.am
 @@ -1,5 +1,5 @@
@@ -24,5 +24,5 @@
  EXTRA_DIST = \
      libreport.pc.in \
 -- 
-2.8.1
+2.7.4
 
diff --git a/meta-openembedded/meta-oe/recipes-extended/libreport/files/0002-configure.ac-remove-prog-test-of-xmlto-and-asciidoc.patch b/meta-openembedded/meta-oe/recipes-extended/libreport/files/0002-configure.ac-remove-prog-test-of-xmlto-and-asciidoc.patch
index 146510e..7f5895e 100644
--- a/meta-openembedded/meta-oe/recipes-extended/libreport/files/0002-configure.ac-remove-prog-test-of-xmlto-and-asciidoc.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/libreport/files/0002-configure.ac-remove-prog-test-of-xmlto-and-asciidoc.patch
@@ -1,7 +1,7 @@
-From d8c49e6a15ab28f4ca94e03b2a53ed8df63346cd Mon Sep 17 00:00:00 2001
+From 9beadcdfca9198548f06bf18f3f26e1d11542e53 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Wed, 26 Apr 2017 03:49:45 -0400
-Subject: [PATCH 2/3] configure.ac: remove prog test of xmlto and asciidoc
+Date: Tue, 31 Jul 2018 16:53:04 +0800
+Subject: [PATCH 2/4] configure.ac: remove prog test of xmlto and asciidoc
 
 The prog of xmlto and asciidoc were used to generate documents,
 and since the doc module has already been disabled, so we should
@@ -15,12 +15,12 @@
  1 file changed, 18 deletions(-)
 
 diff --git a/configure.ac b/configure.ac
-index ccefe50..ed48c88 100644
+index feafc28..aceccf4 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -68,24 +68,6 @@ if test -z "$PYTHON3"; then
-     exit 1
- fi
+@@ -56,24 +56,6 @@ IT_PROG_INTLTOOL([0.35.0])
+ 
+ dnl ****** END ****************************************
  
 -AC_PATH_PROG([ASCIIDOC], [asciidoc], [no])
 -[if test "$ASCIIDOC" = "no"]
@@ -44,5 +44,5 @@
  AS_HELP_STRING([--with-bugzilla],[use Bugzilla plugin (default is YES)]),
  LIBREPORT_PARSE_WITH([bugzilla]))
 -- 
-2.8.1
+2.7.4
 
diff --git a/meta-openembedded/meta-oe/recipes-extended/libreport/files/0003-without-build-plugins.patch b/meta-openembedded/meta-oe/recipes-extended/libreport/files/0003-without-build-plugins.patch
index 3ad7774..2ff1731 100644
--- a/meta-openembedded/meta-oe/recipes-extended/libreport/files/0003-without-build-plugins.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/libreport/files/0003-without-build-plugins.patch
@@ -1,7 +1,7 @@
-From 0e96d9f23b2b166e7444e7c8e0a6d4b83c2eccd7 Mon Sep 17 00:00:00 2001
+From 41bce1de2fd2a0f79c266f245ae3e3720ccaf46a Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Wed, 26 Apr 2017 03:51:03 -0400
-Subject: [PATCH 3/3] without build plugins
+Subject: [PATCH 3/4] without build plugins
 
 Upstream-Status:  Inappropriate workaround
 
@@ -22,5 +22,5 @@
 -SUBDIRS = include lib plugins report-python cli client-python workflows $(sub_dirs)
 +SUBDIRS = include lib report-python cli client-python workflows $(sub_dirs)
 -- 
-2.8.1
+2.7.4
 
diff --git a/meta-openembedded/meta-oe/recipes-extended/libreport/files/0004-configure.ac-remove-prog-test-of-augparse.patch b/meta-openembedded/meta-oe/recipes-extended/libreport/files/0004-configure.ac-remove-prog-test-of-augparse.patch
index 9839e5a..4ba69c7 100644
--- a/meta-openembedded/meta-oe/recipes-extended/libreport/files/0004-configure.ac-remove-prog-test-of-augparse.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/libreport/files/0004-configure.ac-remove-prog-test-of-augparse.patch
@@ -1,7 +1,7 @@
-From cf3b646facc19078ed29f828e36dd2e552283518 Mon Sep 17 00:00:00 2001
+From c1c301502a8f69b9889197744b301a136082f09d Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Thu, 27 Apr 2017 02:15:02 -0400
-Subject: [PATCH] configure.ac: remove prog test of augparse
+Subject: [PATCH 4/4] configure.ac: remove prog test of augparse
 
 The build time does not require it.
 
@@ -13,10 +13,10 @@
  1 file changed, 8 deletions(-)
 
 diff --git a/configure.ac b/configure.ac
-index c06af2d..b90f49e 100644
+index aceccf4..83c101b 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -288,14 +288,6 @@ AC_ARG_WITH(augeaslenslibdir,
+@@ -350,14 +350,6 @@ AC_ARG_WITH(augeaslenslibdir,
                             [Directory for librepor lens (default: /usr/share/augeas/lenses)])],
              [], [with_augeaslenslibdir="/usr/share/augeas/lenses"])
  AC_SUBST([AUGEAS_LENS_LIB_DIR], [$with_augeaslenslibdir])
@@ -32,5 +32,5 @@
  AC_ARG_WITH([defaultdumpdirmode],
              AS_HELP_STRING([--with-defaultdumpdirmode=OCTAL-MODE],
 -- 
-2.8.1
+2.7.4
 
diff --git a/meta-openembedded/meta-oe/recipes-extended/libreport/files/0005-remove-python2-support.patch b/meta-openembedded/meta-oe/recipes-extended/libreport/files/0005-remove-python2-support.patch
deleted file mode 100644
index 9770f07..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/libreport/files/0005-remove-python2-support.patch
+++ /dev/null
@@ -1,142 +0,0 @@
-From 06710ab89fc7d7a82a378289aa3fcd92d33074f2 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Thu, 27 Apr 2017 03:31:00 -0400
-Subject: [PATCH] remove python2 support
-
-We do not require python2, so remove it.
-
-Upstream-Status:  Inappropriate workaround
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- configure.ac                               | 15 ---------------
- src/client-python/reportclient/Makefile.am |  9 ---------
- src/report-python/Makefile.am              | 19 -------------------
- 3 files changed, 43 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index eb50382..826d0fe 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -166,15 +166,6 @@ do
- done
- fi dnl end NO_MANTISBT
- 
--AC_PATH_PROG([PYTHON_CONFIG], [python-config], [no])
--[if test "$PYTHON_CONFIG" = "no"]
--[then]
--    [echo "The python-config program was not found in the search path. Please ensure"]
--    [echo "that it is installed and its directory is included in the search path."]
--    [echo "Then run configure again before attempting to build libreport."]
--    [exit 1]
--[fi]
--
- AC_PATH_PROG([PYTHON3_CONFIG], [python3-config], [no])
- [if test "$PYTHON3_CONFIG" = "no"]
- [then]
-@@ -184,9 +175,6 @@ AC_PATH_PROG([PYTHON3_CONFIG], [python3-config], [no])
-     [exit 1]
- [fi]
- 
--PYTHON_CFLAGS=`python-config --cflags 2> /dev/null`
--PYTHON_LIBS=`python-config --libs 2> /dev/null`
--
- PYTHON3_CFLAGS=`python3-config --cflags 2> /dev/null`
- PYTHON3_LIBS=`python3-config --libs 2> /dev/null`
- 
-@@ -198,9 +186,6 @@ PYTHON3_DIR=`$PYTHON3 -c "import distutils.sysconfig; \
- PYTHON3_EXECDIR=`$PYTHON3 -c "import distutils.sysconfig; \
-     print(distutils.sysconfig.get_python_lib(1,0,prefix='$PYTHON3_EXEC_PREFIX'))"`
- 
--AC_SUBST(PYTHON_CFLAGS)
--AC_SUBST(PYTHON_LIBS)
--
- AC_SUBST(PYTHON3_CFLAGS)
- AC_SUBST(PYTHON3_LIBS)
- AC_SUBST(python3dir, $PYTHON3_DIR)
-diff --git a/src/client-python/reportclient/Makefile.am b/src/client-python/reportclient/Makefile.am
-index 46ac42f..fb5216a 100644
---- a/src/client-python/reportclient/Makefile.am
-+++ b/src/client-python/reportclient/Makefile.am
-@@ -4,13 +4,10 @@ PYFILES = \
-     dnfdebuginfo.py \
-     yumdebuginfo.py
- 
--py2clientdir = $(pyexecdir)/reportclient
- py3clientdir = $(py3execdir)/reportclient
- 
--py2client_PYTHON = $(PYFILES)
- py3client_PYTHON = $(PYFILES)
- 
--py2client_LTLIBRARIES = _reportclient.la
- py3client_LTLIBRARIES = _reportclient3.la
- 
- PYEXTFILES = \
-@@ -33,12 +30,6 @@ PYEXTLDFLAGS = \
-     -avoid-version \
-     -Wl,-z,relro -Wl,-z,now
- 
--_reportclient_la_SOURCES = $(PYEXTFILES)
--_reportclient_la_CPPFLAGS = $(PYEXTCPPFLAGS) $(PYTHON_CFLAGS)
--_reportclient_la_LDFLAGS = $(PYEXTLDFLAGS) \
--    -export-symbols-regex init_reportclient
--_reportclient_la_LIBADD = ../../lib/libreport.la
--
- _reportclient3_la_SOURCES = $(PYEXTFILES)
- _reportclient3_la_CPPFLAGS = $(PYEXTCPPFLAGS) $(PYTHON3_CFLAGS)
- _reportclient3_la_LDFLAGS = $(PYEXTLDFLAGS) \
-diff --git a/src/report-python/Makefile.am b/src/report-python/Makefile.am
-index 793cebd..241dcb7 100644
---- a/src/report-python/Makefile.am
-+++ b/src/report-python/Makefile.am
-@@ -1,12 +1,9 @@
- PYFILES = __init__.py accountmanager.py
- 
--pyreportexecdir = $(pyexecdir)/report
- py3reportexecdir = $(py3execdir)/report
- 
--pyreportexec_PYTHON = $(PYFILES)
- py3reportexec_PYTHON = $(PYFILES)
- 
--pyreportexec_LTLIBRARIES = _pyreport.la
- py3reportexec_LTLIBRARIES = _py3report.la
- 
- PYEXTFILES = \
-@@ -34,20 +31,6 @@ PYEXTLDFLAGS = \
-     -avoid-version \
-     -Wl,-z,relro -Wl,-z,now
- 
--_pyreport_la_SOURCES = $(PYEXTFILES)
--
--_pyreport_la_CPPFLAGS = \
--    $(PYEXTCPPFLAGS) \
--    $(PYTHON_CFLAGS)
--
--_pyreport_la_LDFLAGS = \
--   $(PYEXTLDFLAGS) \
--   -export-symbols-regex init_pyreport
--
--_pyreport_la_LIBADD = \
--    ../lib/libreport.la \
--    $(PYTHON2_LIBS)
--
- _py3report_la_SOURCES = $(PYEXTFILES)
- 
- _py3report_la_CPPFLAGS = \
-@@ -64,7 +47,6 @@ _py3report_la_LIBADD = \
- 
- # report compat:
- 
--pyreportioexecdir = $(pyexecdir)/report/io
- py3reportioexecdir = $(py3execdir)/report/io
- 
- PYIOFILES = \
-@@ -73,5 +55,4 @@ PYIOFILES = \
-     io/NewtIO.py \
-     io/TextIO.py
- 
--pyreportioexec_PYTHON = $(PYIOFILES)
- py3reportioexec_PYTHON = $(PYIOFILES)
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/libreport/libreport_2.9.2.bb b/meta-openembedded/meta-oe/recipes-extended/libreport/libreport_2.9.2.bb
deleted file mode 100644
index f2c661c..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/libreport/libreport_2.9.2.bb
+++ /dev/null
@@ -1,45 +0,0 @@
-DESCRIPTION = "Libraries providing API for reporting different problems in applications \
-to different bug targets like Bugzilla, ftp, trac, etc..."
-SUMMARY = "Generic library for reporting various problems"
-HOMEPAGE = "https://abrt.readthedocs.org/"
-LICENSE = "GPLv2+"
-DEPENDS = "xmlrpc-c xmlrpc-c-native intltool-native \
-        json-c libtar libnewt libproxy rpm \
-        augeas satyr systemd \
-"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
-
-
-SRC_URI = "git://github.com/abrt/libreport.git;protocol=https"
-SRC_URI += "file://0001-Makefile.am-remove-doc-and-apidoc.patch \
-            file://0002-configure.ac-remove-prog-test-of-xmlto-and-asciidoc.patch \
-            file://0003-without-build-plugins.patch \
-            file://0004-configure.ac-remove-prog-test-of-augparse.patch \
-            file://0005-remove-python2-support.patch \
-"
-SRCREV = "cfff49f06d9d17e269d463ee71b3d94c8bfb0c58"
-S = "${WORKDIR}/git"
-
-inherit distro_features_check
-REQUIRED_DISTRO_FEATURES = "systemd"
-
-inherit gettext autotools python3native pkgconfig
-
-PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES','x11','gtk','',d)}"
-PACKAGECONFIG[gtk] = "--with-gtk, --without-gtk, gtk+3,"
-
-RDEPENDS_python3-libreport += "${PN}"
-
-do_patch[prefuncs] += "do_gen_version"
-do_gen_version() {
-    cd ${S}
-    ./gen-version
-}
-
-PACKAGES += "python3-libreport"
-
-FILES_${PN} += "${datadir}/*"
-FILES_${PN}-dbg += "${PYTHON_SITEPACKAGES_DIR}/*/.debug"
-FILES_python3-libreport = "${PYTHON_SITEPACKAGES_DIR}/*"
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/libreport/libreport_2.9.5.bb b/meta-openembedded/meta-oe/recipes-extended/libreport/libreport_2.9.5.bb
new file mode 100644
index 0000000..542956c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/libreport/libreport_2.9.5.bb
@@ -0,0 +1,49 @@
+DESCRIPTION = "Libraries providing API for reporting different problems in applications \
+to different bug targets like Bugzilla, ftp, trac, etc..."
+SUMMARY = "Generic library for reporting various problems"
+HOMEPAGE = "https://abrt.readthedocs.org/"
+LICENSE = "GPLv2+"
+DEPENDS = "xmlrpc-c xmlrpc-c-native intltool-native \
+        json-c libtar libnewt libproxy rpm \
+        augeas satyr systemd \
+"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
+
+
+SRC_URI = "git://github.com/abrt/libreport.git;protocol=https"
+SRC_URI += "file://0001-Makefile.am-remove-doc-and-apidoc.patch \
+            file://0002-configure.ac-remove-prog-test-of-xmlto-and-asciidoc.patch \
+            file://0003-without-build-plugins.patch \
+            file://0004-configure.ac-remove-prog-test-of-augparse.patch \
+"
+SRCREV = "15f92bcaf73e5eb8958fbde655a57dcd111757a7"
+
+UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+(\.\d+)+)"
+
+S = "${WORKDIR}/git"
+
+inherit distro_features_check
+REQUIRED_DISTRO_FEATURES = "systemd"
+
+inherit gettext autotools python3native pkgconfig
+
+PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES','x11','gtk','',d)}"
+PACKAGECONFIG[gtk] = "--with-gtk, --without-gtk, gtk+3,"
+
+EXTRA_OECONF += "--without-python2 --with-python3"
+
+RDEPENDS_python3-libreport += "${PN}"
+
+do_patch[prefuncs] += "do_gen_version"
+do_gen_version() {
+    cd ${S}
+    ./gen-version
+}
+
+PACKAGES += "python3-libreport"
+
+FILES_${PN} += "${datadir}/*"
+FILES_${PN}-dbg += "${PYTHON_SITEPACKAGES_DIR}/*/.debug"
+FILES_python3-libreport = "${PYTHON_SITEPACKAGES_DIR}/*"
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/mailx/files/0001-support-openssl-1.1.x.patch b/meta-openembedded/meta-oe/recipes-extended/mailx/files/0001-support-openssl-1.1.x.patch
new file mode 100644
index 0000000..6a8911d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/mailx/files/0001-support-openssl-1.1.x.patch
@@ -0,0 +1,72 @@
+From 7db6d8a657d13bb562a27c6181accaf3e53c0efd Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Tue, 25 Sep 2018 14:03:10 +0800
+Subject: [PATCH] support openssl 1.1.x
+
+Long time no maintain from upstream since 2013-06-04
+(https://sourceforge.net/projects/nail/), backport a
+fix from openSUSE
+
+Upstream-Status: Backport [openSUSE]
+https://build.opensuse.org/package/view_file/openSUSE:Leap:15.0/mailx/mailx-12.5-openssl-1.1.0f.patch?expand=1
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ openssl.c | 25 ++++++++++++++++++++++++-
+ 1 file changed, 24 insertions(+), 1 deletion(-)
+
+diff --git a/openssl.c b/openssl.c
+index 44fe4e5..0ccc517 100644
+--- a/openssl.c
++++ b/openssl.c
+@@ -137,7 +137,12 @@ ssl_rand_init(void)
+ 
+ 	if ((cp = value("ssl-rand-egd")) != NULL) {
+ 		cp = expand(cp);
+-		if (RAND_egd(cp) == -1) {
++#ifndef OPENSSL_NO_EGD
++		if (RAND_egd(cp) == -1)
++#else
++		if (1)
++#endif
++		{
+ 			fprintf(stderr, catgets(catd, CATSET, 245,
+ 				"entropy daemon at \"%s\" not available\n"),
+ 					cp);
+@@ -216,6 +221,7 @@ ssl_select_method(const char *uhp)
+ 
+ 	cp = ssl_method_string(uhp);
+ 	if (cp != NULL) {
++#if defined(OPENSSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER < 0x1010006fL
+ 		if (equal(cp, "ssl3"))
+ 			method = SSLv3_client_method();
+ 		else if (equal(cp, "tls1"))
+@@ -225,8 +231,25 @@ ssl_select_method(const char *uhp)
+ 					"Invalid SSL method \"%s\"\n"), cp);
+ 			method = SSLv23_client_method();
+ 		}
++#else
++		method = NULL;
++		if (equal(cp, "tls"))
++			method = TLS_client_method();
++		else if (equal(cp, "dtls"))
++			method = DTLS_client_method();
++
++		if (!method) {
++			fprintf(stderr, catgets(catd, CATSET, 244,
++					"Invalid SSL method \"%s\"\n"), cp);
++			method = TLS_client_method();
++		}
++#endif
+ 	} else
++#if defined(OPENSSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER < 0x1010006fL
+ 		method = SSLv23_client_method();
++#else
++		method = TLS_client_method();
++#endif
+ 	return method;
+ }
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/mailx/mailx_12.5-5.bb b/meta-openembedded/meta-oe/recipes-extended/mailx/mailx_12.5-5.bb
index 0a191a0..4161ea6 100644
--- a/meta-openembedded/meta-oe/recipes-extended/mailx/mailx_12.5-5.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/mailx/mailx_12.5-5.bb
@@ -9,7 +9,7 @@
 LICENSE = "BSD & MPL-1"
 LIC_FILES_CHKSUM = "file://COPYING;md5=4202a0a62910cf94f7af8a3436a2a2dd"
 
-DEPENDS = "openssl10"
+DEPENDS = "openssl"
 
 SRC_URI = "http://snapshot.debian.org/archive/debian/20160728T043443Z/pool/main/h/heirloom-mailx/heirloom-mailx_12.5.orig.tar.gz;name=archive \
            file://0001-Don-t-reuse-weak-symbol-optopt-to-fix-FTBFS-on-mips.patch \
@@ -21,6 +21,7 @@
            file://0014-globname-Invoke-wordexp-with-WRDE_NOCMD.patch \
            file://0015-usr-sbin-sendmail.patch \
            file://explicitly.disable.krb5.support.patch \
+           file://0001-support-openssl-1.1.x.patch \
           "
 
 SRC_URI[archive.md5sum] = "29a6033ef1412824d02eb9d9213cb1f2"
diff --git a/meta-openembedded/meta-oe/recipes-extended/md5deep/files/0001-Fix-errors-found-by-clang.patch b/meta-openembedded/meta-oe/recipes-extended/md5deep/files/0001-Fix-errors-found-by-clang.patch
deleted file mode 100644
index cc7cdc3..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/md5deep/files/0001-Fix-errors-found-by-clang.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From 6ef69a26126ee4e69a25392fd456b8a66c51dffd Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 15 Nov 2016 02:46:55 +0000
-Subject: [PATCH] Fix errors found by clang
-
-Fixes errors like
-
-../../git/src/hash.cpp:282:19: error: ordered comparison between pointer and zero ('const unsigned char *' and 'int')
-            if(fdht->base>0){
-               ~~~~~~~~~~^~
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/hash.cpp | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/hash.cpp b/src/hash.cpp
-index 4216157..52f419b 100644
---- a/src/hash.cpp
-+++ b/src/hash.cpp
-@@ -279,7 +279,7 @@ void file_data_hasher_t::hash()
- 		MAP_FILE|
- #endif
- 		MAP_SHARED,fd,0);
--	    if(fdht->base>0){		
-+	    if(fdht->base != (void *) -1){
- 		/* mmap is successful, so set the bounds.
- 		 * if it is not successful, we default to reading the fd
- 		 */
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/md5deep/files/0001-Fix-literal-and-identifier-spacing-as-dictated-by-C-.patch b/meta-openembedded/meta-oe/recipes-extended/md5deep/files/0001-Fix-literal-and-identifier-spacing-as-dictated-by-C-.patch
new file mode 100644
index 0000000..69460b3
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/md5deep/files/0001-Fix-literal-and-identifier-spacing-as-dictated-by-C-.patch
@@ -0,0 +1,128 @@
+From 7d7b60e38ca701819d4d00b38161faddce01e2ae Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 6 Sep 2018 23:21:22 -0700
+Subject: [PATCH] Fix literal and identifier spacing as dictated by C++11
+
+Fixes clang error like below
+
+error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Wreserved-user-defined-literal]
+|         status("  Known files not found: %"PRIu64, this->match.unused);
+
+Upstream-Status: Submitted [https://github.com/jessek/hashdeep/pull/385/commits/18a6b5d57f7a648d2b7dcc6e50ff00a1e4b05fcc]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/display.cpp  | 16 ++++++++--------
+ src/files.cpp    |  4 ++--
+ src/hash.cpp     |  2 +-
+ src/hashlist.cpp |  4 ++--
+ src/xml.h        |  2 +-
+ 5 files changed, 14 insertions(+), 14 deletions(-)
+
+diff --git a/src/display.cpp b/src/display.cpp
+index b23335d..2eddc23 100644
+--- a/src/display.cpp
++++ b/src/display.cpp
+@@ -311,7 +311,7 @@ void display::display_realtime_stats(const file_data_hasher_t *fdht, const hash_
+ 
+ 	ss << mb_read << "MB of " << fdht->stat_megs() << "MB done, ";
+ 	char msg[64];
+-	snprintf(msg,sizeof(msg),"%02"PRIu64":%02"PRIu64":%02"PRIu64" left", hour, min, seconds);
++	snprintf(msg,sizeof(msg),"%02" PRIu64 ":%02" PRIu64 ":%02" PRIu64 " left", hour, min, seconds);
+ 	ss << msg;
+     }
+     ss << "\r";
+@@ -424,14 +424,14 @@ void display::display_audit_results()
+   
+     if (opt_verbose)    {
+ 	if(opt_verbose >= MORE_VERBOSE){
+-	    status("   Input files examined: %"PRIu64, this->match.total);
+-	    status("  Known files expecting: %"PRIu64, this->match.expect);
++	    status("   Input files examined: %" PRIu64, this->match.total);
++	    status("  Known files expecting: %" PRIu64, this->match.expect);
+ 	}
+-	status("          Files matched: %"PRIu64, this->match.exact);
+-	status("Files partially matched: %"PRIu64, this->match.partial);
+-	status("            Files moved: %"PRIu64, this->match.moved);
+-	status("        New files found: %"PRIu64, this->match.unknown);
+-	status("  Known files not found: %"PRIu64, this->match.unused);
++	status("          Files matched: %" PRIu64, this->match.exact);
++	status("Files partially matched: %" PRIu64, this->match.partial);
++	status("            Files moved: %" PRIu64, this->match.moved);
++	status("        New files found: %" PRIu64, this->match.unknown);
++	status("  Known files not found: %" PRIu64, this->match.unused);
+     }
+ }
+ 
+diff --git a/src/files.cpp b/src/files.cpp
+index 89c6984..3dfd363 100644
+--- a/src/files.cpp
++++ b/src/files.cpp
+@@ -509,7 +509,7 @@ int state::parse_encase_file(const char *fn, FILE *handle,uint32_t expected_hash
+         
+ 	    // Users expect the line numbers to start at one, not zero.
+ 	    if ((!ocb.opt_silent) || (mode_warn_only)) {
+-		ocb.error("%s: No hash found in line %"PRIu32, fn, count + 1);
++		ocb.error("%s: No hash found in line %" PRIu32, fn, count + 1);
+ 		ocb.error("%s: %s", fn, strerror(errno));
+ 		return status_t::STATUS_USER_ERROR;
+ 	    }
+@@ -542,7 +542,7 @@ int state::parse_encase_file(const char *fn, FILE *handle,uint32_t expected_hash
+     }
+ 
+     if (expected_hashes != count){
+-	ocb.error("%s: Expecting %"PRIu32" hashes, found %"PRIu32"\n", 
++	ocb.error("%s: Expecting %" PRIu32 " hashes, found %" PRIu32 "\n", 
+ 			fn, expected_hashes, count);
+     }
+     return status_t::status_ok;
+diff --git a/src/hash.cpp b/src/hash.cpp
+index 52f419b..a4b3128 100644
+--- a/src/hash.cpp
++++ b/src/hash.cpp
+@@ -124,7 +124,7 @@ bool file_data_hasher_t::compute_hash(uint64_t request_start,uint64_t request_le
+     
+ 	// If an error occured, display a message and see if we need to quit.
+ 	if ((current_read_bytes<0) || (this->handle && ferror(this->handle))){
+-	    ocb->error_filename(this->file_name,"error at offset %"PRIu64": %s",
++	    ocb->error_filename(this->file_name,"error at offset %" PRIu64 ": %s",
+ 				request_start, strerror(errno));
+ 	   
+ 	    if (file_fatal_error()){
+diff --git a/src/hashlist.cpp b/src/hashlist.cpp
+index b5b275f..eb0d45a 100644
+--- a/src/hashlist.cpp
++++ b/src/hashlist.cpp
+@@ -342,7 +342,7 @@ hashlist::load_hash_file(display *ocb,const std::string &fn)
+     file_data_t *t = new (std::nothrow) file_data_t();
+     if (NULL == t)
+     {
+-      ocb->fatal_error("%s: Out of memory in line %"PRIu64,
++      ocb->fatal_error("%s: Out of memory in line %" PRIu64,
+ 		       fn.c_str(), line_number);
+     }
+ 
+@@ -390,7 +390,7 @@ hashlist::load_hash_file(display *ocb,const std::string &fn)
+       if ( !algorithm_t::valid_hash(hash_column[column_number],word))
+       {
+ 	if (ocb)
+-	  ocb->error("%s: Invalid %s hash in line %"PRIu64,
++	  ocb->error("%s: Invalid %s hash in line %" PRIu64,
+ 		     fn.c_str(),
+ 		     hashes[hash_column[column_number]].name.c_str(),
+ 		     line_number);
+diff --git a/src/xml.h b/src/xml.h
+index bfe0c94..017dba7 100644
+--- a/src/xml.h
++++ b/src/xml.h
+@@ -100,7 +100,7 @@ public:
+     void xmlout(const std::string &tag,const std::string &value){ xmlout(tag,value,"",true); }
+     void xmlout(const std::string &tag,const int value){ xmlprintf(tag,"","%d",value); }
+     void xmloutl(const std::string &tag,const long value){ xmlprintf(tag,"","%ld",value); }
+-    void xmlout(const std::string &tag,const int64_t value){ xmlprintf(tag,"","%"PRId64,value); }
++    void xmlout(const std::string &tag,const int64_t value){ xmlprintf(tag,"","%" PRId64,value); }
+     void xmlout(const std::string &tag,const double value){ xmlprintf(tag,"","%f",value); }
+     void xmlout(const std::string &tag,const struct timeval &ts){
+ 	xmlprintf(tag,"","%d.%06d",(int)ts.tv_sec, (int)ts.tv_usec);
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/md5deep/files/wrong-variable-expansion.patch b/meta-openembedded/meta-oe/recipes-extended/md5deep/files/wrong-variable-expansion.patch
index 3a4c4f4..73c6cb1 100644
--- a/meta-openembedded/meta-oe/recipes-extended/md5deep/files/wrong-variable-expansion.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/md5deep/files/wrong-variable-expansion.patch
@@ -1,6 +1,8 @@
---- a/configure.ac	2014-08-22 12:22:54.290884351 +0200
-+++ b/configure.ac	2014-08-22 12:23:15.822306295 +0200
-@@ -42,18 +42,6 @@
+Index: git/configure.ac
+===================================================================
+--- git.orig/configure.ac
++++ git/configure.ac
+@@ -42,18 +42,6 @@ case $host in
       ;;		 		     
  esac
  
@@ -19,21 +21,3 @@
  #
  #
  ################################################################
-@@ -71,7 +59,7 @@
- 
- if test $mingw = "no" ; then
-   # add the warnings we don't want to do on mingw
--  $WARNINGS_TO_TEST="$WARNINGS_TO_TEST -Wall -Wstrict-prototypes  -Weffc++"
-+  WARNINGS_TO_TEST="$WARNINGS_TO_TEST -Wall -Wstrict-prototypes  -Weffc++"
- fi
- 
- for option in $WARNINGS_TO_TEST
-@@ -105,7 +93,7 @@
- 
- if test $mingw = "no" ; then
-   # add the warnings we don't want to do on mingw
--  $WARNINGS_TO_TEST="$WARNINGS_TO_TEST  -Weffc++"
-+  WARNINGS_TO_TEST="$WARNINGS_TO_TEST  -Weffc++"
- fi
- 
- for option in $WARNINGS_TO_TEST
diff --git a/meta-openembedded/meta-oe/recipes-extended/md5deep/md5deep_4.4.bb b/meta-openembedded/meta-oe/recipes-extended/md5deep/md5deep_4.4.bb
deleted file mode 100644
index bb30abe..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/md5deep/md5deep_4.4.bb
+++ /dev/null
@@ -1,17 +0,0 @@
-SUMMARY = "md5deep and hashdeep to compute and audit hashsets of amounts of files."
-DESCRIPTION = "md5deep is a set of programs to compute MD5, SHA-1, SHA-256, Tiger, or Whirlpool message digests on an arbitrary number of files. This package also includes hashdeep which is also able to audit hashsets."
-AUTHOR = "Jesse Kornblum, Simson L. Garfinkel"
-HOMEPAGE = "http://md5deep.sourceforge.net"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=9190f660105b9a56cdb272309bfd5491"
-# Release 4.4
-SRCREV = "cd2ed7416685a5e83eb10bb659d6e9bec01244ae"
-
-SRC_URI = "git://github.com/jessek/hashdeep.git \
-        file://wrong-variable-expansion.patch \
-        file://0001-Fix-errors-found-by-clang.patch \
-        "
-
-S = "${WORKDIR}/git"
-
-inherit autotools
diff --git a/meta-openembedded/meta-oe/recipes-extended/md5deep/md5deep_git.bb b/meta-openembedded/meta-oe/recipes-extended/md5deep/md5deep_git.bb
new file mode 100644
index 0000000..e8c6864
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/md5deep/md5deep_git.bb
@@ -0,0 +1,19 @@
+SUMMARY = "md5deep and hashdeep to compute and audit hashsets of amounts of files."
+DESCRIPTION = "md5deep is a set of programs to compute MD5, SHA-1, SHA-256, Tiger, or Whirlpool message digests on an arbitrary number of files. This package also includes hashdeep which is also able to audit hashsets."
+AUTHOR = "Jesse Kornblum, Simson L. Garfinkel"
+HOMEPAGE = "http://md5deep.sourceforge.net"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=9190f660105b9a56cdb272309bfd5491"
+
+PV = "4.4+git${SRCPV}"
+
+SRCREV = "877613493ff44807888ce1928129574be393cbb0"
+
+SRC_URI = "git://github.com/jessek/hashdeep.git \
+           file://wrong-variable-expansion.patch \
+           file://0001-Fix-literal-and-identifier-spacing-as-dictated-by-C-.patch \
+           "
+
+S = "${WORKDIR}/git"
+
+inherit autotools
diff --git a/meta-openembedded/meta-oe/recipes-extended/mml-widget/gtkmathview/0001-Fix-formatting-for-modern-c-11-compilers.patch b/meta-openembedded/meta-oe/recipes-extended/mml-widget/gtkmathview/0001-Fix-formatting-for-modern-c-11-compilers.patch
new file mode 100644
index 0000000..8b00966
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/mml-widget/gtkmathview/0001-Fix-formatting-for-modern-c-11-compilers.patch
@@ -0,0 +1,31 @@
+From 90411a7f5e0e9582e79f0a8ccc1e2f158615e451 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 19 May 2018 23:18:11 -0700
+Subject: [PATCH] Fix formatting for modern c++11 compilers
+
+Fixes
+error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Wreserved-user-defined-literal]
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/backend/svg/SVG_RenderingContext.cc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/backend/svg/SVG_RenderingContext.cc b/src/backend/svg/SVG_RenderingContext.cc
+index 55d6097..0d50702 100644
+--- a/src/backend/svg/SVG_RenderingContext.cc
++++ b/src/backend/svg/SVG_RenderingContext.cc
+@@ -68,7 +68,7 @@ void
+ SVG_RenderingContext::documentStart(const BoundingBox& bbox)
+ {
+   beginDocument(bbox);
+-  metadata("Created by "PACKAGE" version "VERSION);
++  metadata("Created by " PACKAGE " version " VERSION);
+ }
+ 
+ void
+-- 
+2.17.0
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/mml-widget/gtkmathview_0.8.0.bb b/meta-openembedded/meta-oe/recipes-extended/mml-widget/gtkmathview_0.8.0.bb
index df82bef..9ee9e30 100644
--- a/meta-openembedded/meta-oe/recipes-extended/mml-widget/gtkmathview_0.8.0.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/mml-widget/gtkmathview_0.8.0.bb
@@ -13,6 +13,7 @@
     file://0001-include-cstdio-to-get-printf-definitions.patch \
     file://0002-configure.ac-header-detection-of-hash_map-is-broken-.patch \
     file://0003-gcc-6.0-build-fixes.patch \
+    file://0001-Fix-formatting-for-modern-c-11-compilers.patch \
 "
 
 S = "${WORKDIR}/git"
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-compare-the-first-character-of-string-to-be-null-or-.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-compare-the-first-character-of-string-to-be-null-or-.patch
deleted file mode 100644
index 40d646c..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-compare-the-first-character-of-string-to-be-null-or-.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From f36c9476d2816e0d3e61c9e13c22ed73883cb54a Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 24 Apr 2017 12:13:43 -0700
-Subject: [PATCH] compare the first character of string to be null or not
-
-Fixes
-
-error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
-|          if (value[0] == '\0')
-|                          ^~~~
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- js/src/shell/jsoptparse.cpp | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/js/src/shell/jsoptparse.cpp b/js/src/shell/jsoptparse.cpp
-index b49d0a5..612aa00 100644
---- a/js/src/shell/jsoptparse.cpp
-+++ b/js/src/shell/jsoptparse.cpp
-@@ -243,7 +243,7 @@ OptionParser::extractValue(size_t argc, char **argv, size_t *i, char **value)
-     char *eq = strchr(argv[*i], '=');
-     if (eq) {
-         *value = eq + 1;
--        if (value[0] == '\0')
-+        if (value[0][0] == '\0')
-             return error("A value is required for option %.*s", eq - argv[*i], argv[*i]);
-         return Okay;
-     }
--- 
-2.12.2
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-do-not-create-python-environment.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-do-not-create-python-environment.patch
new file mode 100644
index 0000000..ba317bc
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-do-not-create-python-environment.patch
@@ -0,0 +1,91 @@
+From 5028d1cd669c179ed49061316d04c8e8862a5bd8 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 12 Jul 2018 15:04:47 +0800
+Subject: [PATCH 1/5] do not create python environment
+
+Use oe's python environment rather than create one of host
+
+Upstream-Status: Inappropriate [oe specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ build/moz.configure/init.configure | 18 ------------------
+ configure.py                       | 10 +++++++++-
+ js/src/old-configure               |  4 ++--
+ 3 files changed, 11 insertions(+), 21 deletions(-)
+
+diff --git a/build/moz.configure/init.configure b/build/moz.configure/init.configure
+index 2123beb..6fe6591 100644
+--- a/build/moz.configure/init.configure
++++ b/build/moz.configure/init.configure
+@@ -179,24 +179,6 @@ def virtualenv_python(env_python, build_env, mozconfig, help):
+     else:
+         python = sys.executable
+ 
+-    if not manager.up_to_date(python):
+-        log.info('Creating Python environment')
+-        manager.build(python)
+-
+-    python = normsep(manager.python_path)
+-
+-    if python != normsep(sys.executable):
+-        log.info('Reexecuting in the virtualenv')
+-        if env_python:
+-            del os.environ['PYTHON']
+-        # One would prefer to use os.execl, but that's completely borked on
+-        # Windows.
+-        sys.exit(subprocess.call([python] + sys.argv))
+-
+-    # We are now in the virtualenv
+-    if not distutils.sysconfig.get_python_lib():
+-        die('Could not determine python site packages directory')
+-
+     return python
+ 
+ set_config('PYTHON', virtualenv_python)
+diff --git a/configure.py b/configure.py
+index f7392d0..45323a5 100644
+--- a/configure.py
++++ b/configure.py
+@@ -12,7 +12,15 @@ import textwrap
+ 
+ 
+ base_dir = os.path.abspath(os.path.dirname(__file__))
+-sys.path.insert(0, os.path.join(base_dir, 'python', 'mozbuild'))
++sys.path.insert(0, os.path.join(base_dir, 'config'))
++def get_immediate_subdirectories(a_dir):
++    return [name for name in os.listdir(a_dir)
++            if os.path.isdir(os.path.join(a_dir, name))]
++for s in ["python", "testing/mozbase"]:
++    sub_dir = os.path.join(base_dir, s)
++    for module_dir in get_immediate_subdirectories(sub_dir):
++        sys.path.insert(0, os.path.join(sub_dir, module_dir))
++
+ from mozbuild.configure import ConfigureSandbox
+ from mozbuild.util import (
+     indented_repr,
+diff --git a/js/src/old-configure b/js/src/old-configure
+index ee4527b..75b00e1 100644
+--- a/js/src/old-configure
++++ b/js/src/old-configure
+@@ -10512,7 +10512,7 @@ if test "$MOZ_BUILD_APP" != js -o -n "$JS_STANDALONE"; then
+     ;;
+   esac
+ 
+-  eval $dumpenv $PYTHON $_topsrcdir/build/subconfigure.py --prepare "$srcdir" "$moz_config_dir" "$_CONFIG_SHELL" $ac_configure_args 
++  eval $dumpenv PYTHONPATH=$_topsrcdir/python/mozbuild/ $PYTHON $_topsrcdir/build/subconfigure.py --prepare "$srcdir" "$moz_config_dir" "$_CONFIG_SHELL" $ac_configure_args
+ 
+   done
+ 
+@@ -10931,7 +10931,7 @@ if test "$JS_STANDALONE"; then
+   
+ if test "$no_recursion" != yes; then
+   trap '' EXIT
+-  if ! $PYTHON $_topsrcdir/build/subconfigure.py --list subconfigures --skip skip_subconfigures; then
++  if ! PYTHONPATH=$_topsrcdir/python/mozbuild/ $PYTHON $_topsrcdir/build/subconfigure.py --list subconfigures --skip skip_subconfigures; then
+       exit 1
+   fi
+ fi
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-fix-compiling-failure-on-mips64-n32-bsp.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-fix-compiling-failure-on-mips64-n32-bsp.patch
new file mode 100644
index 0000000..bc1af3c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-fix-compiling-failure-on-mips64-n32-bsp.patch
@@ -0,0 +1,79 @@
+From 5ad700c92224193bfc789f7d53af38fc6f8b8904 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 19 Jul 2018 17:31:35 +0800
+Subject: [PATCH] fix compiling failure on mips64-n32 bsp
+
+- Tweak mips64-n32 with mips32
+
+- The toolchain of mips64-n32 supports both of macro
+  `__mips64' and `__mips__', but 32bit is required here.
+
+- N32 uses 64-bit registers but restricts addresses to 32 bits.
+  https://www.linux-mips.org/pub/linux/mips/doc/ABI/MIPS-N32-ABI-Handbook.pdf
+  Table 2-1 specifies the use of registers in n32 and native 64-bit mode.
+  From the table, N32 and N64 have the same registers
+
+Upstream-Status: Inappropriate [oe specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ build/moz.configure/init.configure                | 5 ++++-
+ js/src/jit/mips-shared/Architecture-mips-shared.h | 4 +++-
+ python/mozbuild/mozbuild/configure/constants.py   | 2 +-
+ 3 files changed, 8 insertions(+), 3 deletions(-)
+
+diff --git a/build/moz.configure/init.configure b/build/moz.configure/init.configure
+index 6fe6591..a77b46c 100644
+--- a/build/moz.configure/init.configure
++++ b/build/moz.configure/init.configure
+@@ -357,7 +357,10 @@ def split_triplet(triplet):
+         canonical_cpu = 'mips32'
+         endianness = 'little' if 'el' in cpu else 'big'
+     elif cpu in ('mips64', 'mips64el'):
+-        canonical_cpu = 'mips64'
++        if 'n32' in triplet:
++            canonical_cpu = 'mips32'
++        else:
++            canonical_cpu = 'mips64'
+         endianness = 'little' if 'el' in cpu else 'big'
+     elif cpu.startswith('aarch64'):
+         canonical_cpu = 'aarch64'
+diff --git a/js/src/jit/mips-shared/Architecture-mips-shared.h b/js/src/jit/mips-shared/Architecture-mips-shared.h
+index 7afe305..c6e29dc 100644
+--- a/js/src/jit/mips-shared/Architecture-mips-shared.h
++++ b/js/src/jit/mips-shared/Architecture-mips-shared.h
+@@ -24,6 +24,8 @@
+ #define USES_O32_ABI
+ #elif (defined(_MIPS_SIM) && (_MIPS_SIM == _ABI64)) || defined(JS_SIMULATOR_MIPS64)
+ #define USES_N64_ABI
++#elif (defined(_MIPS_SIM) && (_MIPS_SIM == _ABIN32))
++#define USES_N32_ABI
+ #else
+ #error "Unsupported ABI"
+ #endif
+@@ -91,7 +93,7 @@ class Registers
+         ta1 = t5,
+         ta2 = t6,
+         ta3 = t7,
+-#elif defined(USES_N64_ABI)
++#elif defined(USES_N64_ABI) || defined(USES_N32_ABI)
+         a4 = r8,
+         a5 = r9,
+         a6 = r10,
+diff --git a/python/mozbuild/mozbuild/configure/constants.py b/python/mozbuild/mozbuild/configure/constants.py
+index dfc7cf8..27f83ab 100644
+--- a/python/mozbuild/mozbuild/configure/constants.py
++++ b/python/mozbuild/mozbuild/configure/constants.py
+@@ -83,8 +83,8 @@ CPU_preprocessor_checks = OrderedDict((
+     ('hppa', '__hppa__'),
+     ('sparc64', '__sparc__ && __arch64__'),
+     ('sparc', '__sparc__'),
+-    ('mips64', '__mips64'),
+     ('mips32', '__mips__'),
++    ('mips64', '__mips64'),
+ ))
+ 
+ assert sorted(CPU_preprocessor_checks.keys()) == sorted(CPU.POSSIBLE_VALUES)
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-js.pc.in-do-not-include-RequiredDefines.h-for-depend.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-js.pc.in-do-not-include-RequiredDefines.h-for-depend.patch
index bc141d9..c111ea5 100644
--- a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-js.pc.in-do-not-include-RequiredDefines.h-for-depend.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-js.pc.in-do-not-include-RequiredDefines.h-for-depend.patch
@@ -3,33 +3,31 @@
 Date: Thu, 6 Jun 2013 18:36:01 +0200
 Subject: [PATCH] js.pc.in: do not include RequiredDefines.h for depending
  packages
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
 
 in our cross environment the would fail with:
 
 | cc1: fatal error: /usr/include/js-17.0/js/RequiredDefines.h: No such file or directory
 
 and currently it only defines __STDC_LIMIT_MACROS
-
 Upstream-Status: Inappropriate [embedded specific]
-
 Signed-off-by: Andreas Müller <schnitzeltony@googlemail.com>
----
- js.pc.in |    2 +-
- 1 files changed, 1 insertions(+), 1 deletions(-)
 
-diff --git a/js.pc.in b/js.pc.in
-index 13d761d..a95a7bd 100644
---- a/js.pc.in
-+++ b/js.pc.in
+Rebase to 52.8.1
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ js/src/js.pc.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/js/src/js.pc.in b/js/src/js.pc.in
+index 2eae393..c2dea62 100644
+--- a/js/src/js.pc.in
++++ b/js/src/js.pc.in
 @@ -8,4 +8,4 @@ Description: The Mozilla library for JavaScript
  Version: @MOZILLA_VERSION@
- Requires.private: @NSPR_PKGCONF_CHECK@
- Libs: -L${libdir} -l@LIBRARY_NAME@
--Cflags: -include ${includedir}/@MODULE@/js/RequiredDefines.h -I${includedir}/@MODULE@
-+Cflags: -I${includedir}/@MODULE@
+ @PKGCONF_REQUIRES_PRIVATE@
+ Libs: -L${libdir} -l@JS_LIBRARY_NAME@
+-Cflags: -include ${includedir}/@JS_LIBRARY_NAME@/js/RequiredDefines.h -I${includedir}/@JS_LIBRARY_NAME@
++Cflags: -I${includedir}/@JS_LIBRARY_NAME@
 -- 
-1.7.6.5
+2.7.4
 
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-mozjs-fix-coredump-caused-by-getenv.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-mozjs-fix-coredump-caused-by-getenv.patch
new file mode 100644
index 0000000..477f73a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-mozjs-fix-coredump-caused-by-getenv.patch
@@ -0,0 +1,27 @@
+From 20b639b7364f9953fdacb058f9ba800bcbf029b4 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Thu, 2 Aug 2018 09:40:48 +0800
+Subject: [PATCH] mozjs: fix coredump caused by getenv
+
+Upstream-Status: Submitted [https://bugzilla.mozilla.org/show_bug.cgi?id=1480315]
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ mozglue/misc/TimeStamp.cpp | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/mozglue/misc/TimeStamp.cpp b/mozglue/misc/TimeStamp.cpp
+index 932b75c..7a4d71b 100644
+--- a/mozglue/misc/TimeStamp.cpp
++++ b/mozglue/misc/TimeStamp.cpp
+@@ -11,6 +11,7 @@
+ #include "mozilla/TimeStamp.h"
+ #include <stdio.h>
+ #include <string.h>
++#include <stdlib.h>
+ 
+ namespace mozilla {
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-mozjs17.0.0-fix-the-compile-bug-of-powerpc.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-mozjs17.0.0-fix-the-compile-bug-of-powerpc.patch
deleted file mode 100644
index de72d4f..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-mozjs17.0.0-fix-the-compile-bug-of-powerpc.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From da3929a96d9c74e11bf37d128890e18fcb745365 Mon Sep 17 00:00:00 2001
-From: Lei Maohui <leimaohui@cn.fujitsu.com>
-Date: Mon, 26 Jan 2015 08:53:19 +0900
-Subject: [PATCH] mozjs17.0.0: fix the compile bug of powerpc
-
-To fix the bug as following
-
-error: cannot convert '__va_list_tag**' to '__va_list_tag (*)[1]' for
-argument '5' to 'JSBool TryArgumentFormatter(JSContext*, const char**,
-JSBool, jsval**, __va_list_tag (*)[1])'
-
-Signed-off-by: Lei Maohui <leimaohui@cn.fujitsu.com>
----
- jscpucfg.h | 6 ++++++
- 1 file changed, 6 insertions(+)
-
-diff --git a/jscpucfg.h b/jscpucfg.h
-index dfb1c14..8683491 100644
---- a/jscpucfg.h
-+++ b/jscpucfg.h
-@@ -47,6 +47,12 @@
- #elif defined(JS_HAVE_ENDIAN_H)
- # include <endian.h>
- 
-+#if defined(_POWER) || defined(__powerpc__) || \
-+    defined(__ppc__)
-+# define HAVE_VA_LIST_AS_ARRAY 1
-+# endif
-+
-+
- # if defined(__BYTE_ORDER)
- #  if __BYTE_ORDER == __LITTLE_ENDIAN
- #   define IS_LITTLE_ENDIAN 1
--- 
-1.8.4.2
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-regenerate-configure.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-regenerate-configure.patch
deleted file mode 100644
index fa413ea..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0001-regenerate-configure.patch
+++ /dev/null
@@ -1,3238 +0,0 @@
-From 6440b4901c6f4bcc69686ff10806e311cc5a927b Mon Sep 17 00:00:00 2001
-From: Koen Kooi <koen.kooi@linaro.org>
-Date: Tue, 3 Mar 2015 19:12:17 +0800
-Subject: [PATCH] regenerate configure with autoconf-2.13
-
-Signed-off-by: Koen Kooi <koen.kooi@linaro.org>
-Upstream-status: Inappropriate [generated file]
-
----
- js/src/configure | 838 ++++++++++++++++++++++++++-----------------------------
- 1 file changed, 389 insertions(+), 449 deletions(-)
-
-diff --git a/js/src/configure b/js/src/configure
-index cb6b41b..b05298f 100755
---- a/js/src/configure
-+++ b/js/src/configure
-@@ -5757,6 +5757,10 @@ arm*)
-     CPU_ARCH=arm
-     ;;
- 
-+aarch64*)
-+    CPU_ARCH=aarch64
-+    ;;
-+
- mips|mipsel)
-     CPU_ARCH="mips"
-     ;;
-@@ -5893,14 +5897,14 @@ no)
-     _SAVE_CFLAGS="$CFLAGS"
-     CFLAGS="$arch_flag"
-     cat > conftest.$ac_ext <<EOF
--#line 5897 "configure"
-+#line 5901 "configure"
- #include "confdefs.h"
- 
- int main() {
- return sizeof(__thumb2__);
- ; return 0; }
- EOF
--if { (eval echo configure:5904: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:5908: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   MOZ_THUMB2=1
- else
-@@ -5972,16 +5976,16 @@ if test -n "$all_flags"; then
-     _SAVE_CFLAGS="$CFLAGS"
-     CFLAGS="$all_flags"
-     echo $ac_n "checking whether the chosen combination of compiler flags ($all_flags) works""... $ac_c" 1>&6
--echo "configure:5976: checking whether the chosen combination of compiler flags ($all_flags) works" >&5
-+echo "configure:5980: checking whether the chosen combination of compiler flags ($all_flags) works" >&5
-     cat > conftest.$ac_ext <<EOF
--#line 5978 "configure"
-+#line 5982 "configure"
- #include "confdefs.h"
- 
- int main() {
- return 0;
- ; return 0; }
- EOF
--if { (eval echo configure:5985: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:5989: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   echo "$ac_t""yes" 1>&6
- else
-@@ -6004,18 +6008,18 @@ fi
- 
- if test "$CPU_ARCH" = "arm"; then
-   echo $ac_n "checking for ARM SIMD support in compiler""... $ac_c" 1>&6
--echo "configure:6008: checking for ARM SIMD support in compiler" >&5
-+echo "configure:6012: checking for ARM SIMD support in compiler" >&5
-   # We try to link so that this also fails when
-   # building with LTO.
-   cat > conftest.$ac_ext <<EOF
--#line 6012 "configure"
-+#line 6016 "configure"
- #include "confdefs.h"
- 
- int main() {
- asm("uqadd8 r1, r1, r2");
- ; return 0; }
- EOF
--if { (eval echo configure:6019: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:6023: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   result="yes"
- else
-@@ -6038,18 +6042,18 @@ EOF
-   fi
- 
-   echo $ac_n "checking for ARM NEON support in compiler""... $ac_c" 1>&6
--echo "configure:6042: checking for ARM NEON support in compiler" >&5
-+echo "configure:6046: checking for ARM NEON support in compiler" >&5
-   # We try to link so that this also fails when
-   # building with LTO.
-   cat > conftest.$ac_ext <<EOF
--#line 6046 "configure"
-+#line 6050 "configure"
- #include "confdefs.h"
- 
- int main() {
- asm(".fpu neon\n vadd.i8 d0, d0, d0");
- ; return 0; }
- EOF
--if { (eval echo configure:6053: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:6057: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   result="yes"
- else
-@@ -6094,7 +6098,7 @@ configure_static_assert_macros='
- '
- 
- echo $ac_n "checking that static assertion macros used in autoconf tests work""... $ac_c" 1>&6
--echo "configure:6098: checking that static assertion macros used in autoconf tests work" >&5
-+echo "configure:6102: checking that static assertion macros used in autoconf tests work" >&5
- if eval "test \"`echo '$''{'ac_cv_static_assertion_macros_work'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -6108,14 +6112,14 @@ cross_compiling=$ac_cv_prog_cc_cross
- 
-   ac_cv_static_assertion_macros_work="yes"
-   cat > conftest.$ac_ext <<EOF
--#line 6112 "configure"
-+#line 6116 "configure"
- #include "confdefs.h"
- $configure_static_assert_macros
- int main() {
- CONFIGURE_STATIC_ASSERT(1)
- ; return 0; }
- EOF
--if { (eval echo configure:6119: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:6123: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   :
- else
-   echo "configure: failed program was:" >&5
-@@ -6125,14 +6129,14 @@ else
- fi
- rm -f conftest*
-   cat > conftest.$ac_ext <<EOF
--#line 6129 "configure"
-+#line 6133 "configure"
- #include "confdefs.h"
- $configure_static_assert_macros
- int main() {
- CONFIGURE_STATIC_ASSERT(0)
- ; return 0; }
- EOF
--if { (eval echo configure:6136: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:6140: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_static_assertion_macros_work="no"
- else
-@@ -6148,14 +6152,14 @@ ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftes
- cross_compiling=$ac_cv_prog_cxx_cross
- 
-   cat > conftest.$ac_ext <<EOF
--#line 6152 "configure"
-+#line 6156 "configure"
- #include "confdefs.h"
- $configure_static_assert_macros
- int main() {
- CONFIGURE_STATIC_ASSERT(1)
- ; return 0; }
- EOF
--if { (eval echo configure:6159: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:6163: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   :
- else
-   echo "configure: failed program was:" >&5
-@@ -6165,14 +6169,14 @@ else
- fi
- rm -f conftest*
-   cat > conftest.$ac_ext <<EOF
--#line 6169 "configure"
-+#line 6173 "configure"
- #include "confdefs.h"
- $configure_static_assert_macros
- int main() {
- CONFIGURE_STATIC_ASSERT(0)
- ; return 0; }
- EOF
--if { (eval echo configure:6176: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:6180: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_static_assertion_macros_work="no"
- else
-@@ -6317,7 +6321,7 @@ if test "$GNU_CC"; then
-     _WARNINGS_CFLAGS="${_WARNINGS_CFLAGS} -Wall -Wpointer-arith -Wdeclaration-after-statement"
-     
-     echo $ac_n "checking whether the C compiler supports -Werror=return-type""... $ac_c" 1>&6
--echo "configure:6321: checking whether the C compiler supports -Werror=return-type" >&5
-+echo "configure:6325: checking whether the C compiler supports -Werror=return-type" >&5
- if eval "test \"`echo '$''{'ac_c_has_werror_return_type'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -6333,14 +6337,14 @@ cross_compiling=$ac_cv_prog_cc_cross
-             _SAVE_CFLAGS="$CFLAGS"
-             CFLAGS="$CFLAGS -Werror -Werror=return-type"
-             cat > conftest.$ac_ext <<EOF
--#line 6337 "configure"
-+#line 6341 "configure"
- #include "confdefs.h"
- 
- int main() {
- return(0);
- ; return 0; }
- EOF
--if { (eval echo configure:6344: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:6348: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_c_has_werror_return_type="yes"
- else
-@@ -6368,7 +6372,7 @@ echo "$ac_t""$ac_c_has_werror_return_type" 1>&6
- 
-     
-     echo $ac_n "checking whether the C compiler supports -Wtype-limits""... $ac_c" 1>&6
--echo "configure:6372: checking whether the C compiler supports -Wtype-limits" >&5
-+echo "configure:6376: checking whether the C compiler supports -Wtype-limits" >&5
- if eval "test \"`echo '$''{'ac_c_has_wtype_limits'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -6384,14 +6388,14 @@ cross_compiling=$ac_cv_prog_cc_cross
-             _SAVE_CFLAGS="$CFLAGS"
-             CFLAGS="$CFLAGS -Werror -Wtype-limits"
-             cat > conftest.$ac_ext <<EOF
--#line 6388 "configure"
-+#line 6392 "configure"
- #include "confdefs.h"
- 
- int main() {
- return(0);
- ; return 0; }
- EOF
--if { (eval echo configure:6395: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:6399: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_c_has_wtype_limits="yes"
- else
-@@ -6419,7 +6423,7 @@ echo "$ac_t""$ac_c_has_wtype_limits" 1>&6
- 
-     
-     echo $ac_n "checking whether the C compiler supports -Wempty-body""... $ac_c" 1>&6
--echo "configure:6423: checking whether the C compiler supports -Wempty-body" >&5
-+echo "configure:6427: checking whether the C compiler supports -Wempty-body" >&5
- if eval "test \"`echo '$''{'ac_c_has_wempty_body'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -6435,14 +6439,14 @@ cross_compiling=$ac_cv_prog_cc_cross
-             _SAVE_CFLAGS="$CFLAGS"
-             CFLAGS="$CFLAGS -Werror -Wempty-body"
-             cat > conftest.$ac_ext <<EOF
--#line 6439 "configure"
-+#line 6443 "configure"
- #include "confdefs.h"
- 
- int main() {
- return(0);
- ; return 0; }
- EOF
--if { (eval echo configure:6446: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:6450: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_c_has_wempty_body="yes"
- else
-@@ -6476,7 +6480,7 @@ echo "$ac_t""$ac_c_has_wempty_body" 1>&6
-     _WARNINGS_CFLAGS="${_WARNINGS_CFLAGS} -Wno-unused"
-     
-     echo $ac_n "checking whether the C compiler supports -Wno-overlength-strings""... $ac_c" 1>&6
--echo "configure:6480: checking whether the C compiler supports -Wno-overlength-strings" >&5
-+echo "configure:6484: checking whether the C compiler supports -Wno-overlength-strings" >&5
- if eval "test \"`echo '$''{'ac_c_has_wno_overlength_strings'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -6492,14 +6496,14 @@ cross_compiling=$ac_cv_prog_cc_cross
-             _SAVE_CFLAGS="$CFLAGS"
-             CFLAGS="$CFLAGS -Werror -Woverlength-strings"
-             cat > conftest.$ac_ext <<EOF
--#line 6496 "configure"
-+#line 6500 "configure"
- #include "confdefs.h"
- 
- int main() {
- return(0);
- ; return 0; }
- EOF
--if { (eval echo configure:6503: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:6507: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_c_has_wno_overlength_strings="yes"
- else
-@@ -6580,7 +6584,7 @@ if test "$GNU_CXX"; then
-     _WARNINGS_CXXFLAGS="${_WARNINGS_CXXFLAGS} -Wall -Wpointer-arith -Woverloaded-virtual"
-     
-     echo $ac_n "checking whether the C++ compiler supports -Werror=return-type""... $ac_c" 1>&6
--echo "configure:6584: checking whether the C++ compiler supports -Werror=return-type" >&5
-+echo "configure:6588: checking whether the C++ compiler supports -Werror=return-type" >&5
- if eval "test \"`echo '$''{'ac_cxx_has_werror_return_type'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -6596,14 +6600,14 @@ cross_compiling=$ac_cv_prog_cxx_cross
-             _SAVE_CXXFLAGS="$CXXFLAGS"
-             CXXFLAGS="$CXXFLAGS -Werror -Werror=return-type"
-             cat > conftest.$ac_ext <<EOF
--#line 6600 "configure"
-+#line 6604 "configure"
- #include "confdefs.h"
- 
- int main() {
- return(0);
- ; return 0; }
- EOF
--if { (eval echo configure:6607: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:6611: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cxx_has_werror_return_type="yes"
- else
-@@ -6631,7 +6635,7 @@ echo "$ac_t""$ac_cxx_has_werror_return_type" 1>&6
- 
-     
-     echo $ac_n "checking whether the C++ compiler supports -Wtype-limits""... $ac_c" 1>&6
--echo "configure:6635: checking whether the C++ compiler supports -Wtype-limits" >&5
-+echo "configure:6639: checking whether the C++ compiler supports -Wtype-limits" >&5
- if eval "test \"`echo '$''{'ac_cxx_has_wtype_limits'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -6647,14 +6651,14 @@ cross_compiling=$ac_cv_prog_cxx_cross
-             _SAVE_CXXFLAGS="$CXXFLAGS"
-             CXXFLAGS="$CXXFLAGS -Werror -Wtype-limits"
-             cat > conftest.$ac_ext <<EOF
--#line 6651 "configure"
-+#line 6655 "configure"
- #include "confdefs.h"
- 
- int main() {
- return(0);
- ; return 0; }
- EOF
--if { (eval echo configure:6658: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:6662: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cxx_has_wtype_limits="yes"
- else
-@@ -6682,7 +6686,7 @@ echo "$ac_t""$ac_cxx_has_wtype_limits" 1>&6
- 
-     
-     echo $ac_n "checking whether the C++ compiler supports -Wempty-body""... $ac_c" 1>&6
--echo "configure:6686: checking whether the C++ compiler supports -Wempty-body" >&5
-+echo "configure:6690: checking whether the C++ compiler supports -Wempty-body" >&5
- if eval "test \"`echo '$''{'ac_cxx_has_wempty_body'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -6698,14 +6702,14 @@ cross_compiling=$ac_cv_prog_cxx_cross
-             _SAVE_CXXFLAGS="$CXXFLAGS"
-             CXXFLAGS="$CXXFLAGS -Werror -Wempty-body"
-             cat > conftest.$ac_ext <<EOF
--#line 6702 "configure"
-+#line 6706 "configure"
- #include "confdefs.h"
- 
- int main() {
- return(0);
- ; return 0; }
- EOF
--if { (eval echo configure:6709: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:6713: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cxx_has_wempty_body="yes"
- else
-@@ -6741,7 +6745,7 @@ echo "$ac_t""$ac_cxx_has_wempty_body" 1>&6
-     _WARNINGS_CXXFLAGS="${_WARNINGS_CXXFLAGS} -Wno-ctor-dtor-privacy"
-     
-     echo $ac_n "checking whether the C++ compiler supports -Wno-overlength-strings""... $ac_c" 1>&6
--echo "configure:6745: checking whether the C++ compiler supports -Wno-overlength-strings" >&5
-+echo "configure:6749: checking whether the C++ compiler supports -Wno-overlength-strings" >&5
- if eval "test \"`echo '$''{'ac_cxx_has_wno_overlength_strings'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -6757,14 +6761,14 @@ cross_compiling=$ac_cv_prog_cxx_cross
-             _SAVE_CXXFLAGS="$CXXFLAGS"
-             CXXFLAGS="$CXXFLAGS -Werror -Woverlength-strings"
-             cat > conftest.$ac_ext <<EOF
--#line 6761 "configure"
-+#line 6765 "configure"
- #include "confdefs.h"
- 
- int main() {
- return(0);
- ; return 0; }
- EOF
--if { (eval echo configure:6768: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:6772: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cxx_has_wno_overlength_strings="yes"
- else
-@@ -6792,7 +6796,7 @@ echo "$ac_t""$ac_cxx_has_wno_overlength_strings" 1>&6
- 
-     
-     echo $ac_n "checking whether the C++ compiler supports -Wno-invalid-offsetof""... $ac_c" 1>&6
--echo "configure:6796: checking whether the C++ compiler supports -Wno-invalid-offsetof" >&5
-+echo "configure:6800: checking whether the C++ compiler supports -Wno-invalid-offsetof" >&5
- if eval "test \"`echo '$''{'ac_cxx_has_wno_invalid_offsetof'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -6808,14 +6812,14 @@ cross_compiling=$ac_cv_prog_cxx_cross
-             _SAVE_CXXFLAGS="$CXXFLAGS"
-             CXXFLAGS="$CXXFLAGS -Werror -Winvalid-offsetof"
-             cat > conftest.$ac_ext <<EOF
--#line 6812 "configure"
-+#line 6816 "configure"
- #include "confdefs.h"
- 
- int main() {
- return(0);
- ; return 0; }
- EOF
--if { (eval echo configure:6819: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:6823: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cxx_has_wno_invalid_offsetof="yes"
- else
-@@ -6843,7 +6847,7 @@ echo "$ac_t""$ac_cxx_has_wno_invalid_offsetof" 1>&6
- 
-     
-     echo $ac_n "checking whether the C++ compiler supports -Wno-variadic-macros""... $ac_c" 1>&6
--echo "configure:6847: checking whether the C++ compiler supports -Wno-variadic-macros" >&5
-+echo "configure:6851: checking whether the C++ compiler supports -Wno-variadic-macros" >&5
- if eval "test \"`echo '$''{'ac_cxx_has_wno_variadic_macros'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -6859,14 +6863,14 @@ cross_compiling=$ac_cv_prog_cxx_cross
-             _SAVE_CXXFLAGS="$CXXFLAGS"
-             CXXFLAGS="$CXXFLAGS -Werror -Wvariadic-macros"
-             cat > conftest.$ac_ext <<EOF
--#line 6863 "configure"
-+#line 6867 "configure"
- #include "confdefs.h"
- 
- int main() {
- return(0);
- ; return 0; }
- EOF
--if { (eval echo configure:6870: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:6874: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cxx_has_wno_variadic_macros="yes"
- else
-@@ -6918,7 +6922,7 @@ echo "$ac_t""$ac_cxx_has_wno_variadic_macros" 1>&6
-         _WARNINGS_CXXFLAGS="${_WARNINGS_CXXFLAGS} -Wno-c++0x-extensions"
-         
-     echo $ac_n "checking whether the C++ compiler supports -Wno-extended-offsetof""... $ac_c" 1>&6
--echo "configure:6922: checking whether the C++ compiler supports -Wno-extended-offsetof" >&5
-+echo "configure:6926: checking whether the C++ compiler supports -Wno-extended-offsetof" >&5
- if eval "test \"`echo '$''{'ac_cxx_has_wno_extended_offsetof'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -6934,14 +6938,14 @@ cross_compiling=$ac_cv_prog_cxx_cross
-             _SAVE_CXXFLAGS="$CXXFLAGS"
-             CXXFLAGS="$CXXFLAGS -Werror -Wextended-offsetof"
-             cat > conftest.$ac_ext <<EOF
--#line 6938 "configure"
-+#line 6942 "configure"
- #include "confdefs.h"
- 
- int main() {
- return(0);
- ; return 0; }
- EOF
--if { (eval echo configure:6945: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:6949: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cxx_has_wno_extended_offsetof="yes"
- else
-@@ -6979,7 +6983,7 @@ MKSHLIB_UNFORCE_ALL=
- if test "$COMPILE_ENVIRONMENT"; then
- if test "$GNU_CC"; then
-   echo $ac_n "checking whether ld has archive extraction flags""... $ac_c" 1>&6
--echo "configure:6983: checking whether ld has archive extraction flags" >&5
-+echo "configure:6987: checking whether ld has archive extraction flags" >&5
-   if eval "test \"`echo '$''{'ac_cv_mkshlib_force_and_unforce'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -6996,14 +7000,14 @@ LOOP_INPUT
-       LDFLAGS=$force
-       LIBS=$unforce
-       cat > conftest.$ac_ext <<EOF
--#line 7000 "configure"
-+#line 7004 "configure"
- #include "confdefs.h"
- 
- int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:7007: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:7011: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   ac_cv_mkshlib_force_and_unforce=$line; break
- else
-@@ -7038,16 +7042,16 @@ ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$a
- cross_compiling=$ac_cv_prog_cc_cross
- 
- echo $ac_n "checking for 64-bit OS""... $ac_c" 1>&6
--echo "configure:7042: checking for 64-bit OS" >&5
-+echo "configure:7046: checking for 64-bit OS" >&5
- cat > conftest.$ac_ext <<EOF
--#line 7044 "configure"
-+#line 7048 "configure"
- #include "confdefs.h"
- $configure_static_assert_macros
- int main() {
- CONFIGURE_STATIC_ASSERT(sizeof(void*) == 8)
- ; return 0; }
- EOF
--if { (eval echo configure:7051: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:7055: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   result="yes"
- else
-@@ -7170,7 +7174,7 @@ case "$host" in
- esac
- 
- echo $ac_n "checking for Python version >= $PYTHON_VERSION but not 3.x""... $ac_c" 1>&6
--echo "configure:7174: checking for Python version >= $PYTHON_VERSION but not 3.x" >&5
-+echo "configure:7178: checking for Python version >= $PYTHON_VERSION but not 3.x" >&5
- 
- $PYTHON -c "import sys; sys.exit(sys.version[:3] < sys.argv[1] or sys.version[:2] != '2.')" $PYTHON_VERSION
- _python_res=$?
-@@ -7181,7 +7185,7 @@ fi
- echo "$ac_t""yes" 1>&6
- 
- echo $ac_n "checking for custom <stdint.h> implementation""... $ac_c" 1>&6
--echo "configure:7185: checking for custom <stdint.h> implementation" >&5
-+echo "configure:7189: checking for custom <stdint.h> implementation" >&5
- if test "$MOZ_CUSTOM_STDINT_H"; then
-   cat >> confdefs.pytmp <<EOF
-         (''' MOZ_CUSTOM_STDINT_H ''', r''' "$MOZ_CUSTOM_STDINT_H" ''')
-@@ -7249,9 +7253,9 @@ ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftes
- cross_compiling=$ac_cv_prog_cxx_cross
- 
-             echo $ac_n "checking for IBM XLC/C++ compiler version >= 9.0.0.7""... $ac_c" 1>&6
--echo "configure:7253: checking for IBM XLC/C++ compiler version >= 9.0.0.7" >&5
-+echo "configure:7257: checking for IBM XLC/C++ compiler version >= 9.0.0.7" >&5
-             cat > conftest.$ac_ext <<EOF
--#line 7255 "configure"
-+#line 7259 "configure"
- #include "confdefs.h"
- 
- int main() {
-@@ -7260,7 +7264,7 @@ int main() {
-                  #endif
- ; return 0; }
- EOF
--if { (eval echo configure:7264: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:7268: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   _BAD_COMPILER=
- else
-@@ -7298,12 +7302,12 @@ cross_compiling=$ac_cv_prog_cc_cross
-   do
-        ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
--echo "configure:7302: checking for $ac_hdr" >&5
-+echo "configure:7306: checking for $ac_hdr" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 7307 "configure"
-+#line 7311 "configure"
- #include "confdefs.h"
- 
- #include <$ac_hdr>
-@@ -7311,7 +7315,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:7315: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:7319: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -7394,17 +7398,17 @@ EOF
-     # builds.
-     _SAVE_LDFLAGS=$LDFLAGS
-      echo $ac_n "checking for -framework ExceptionHandling""... $ac_c" 1>&6
--echo "configure:7398: checking for -framework ExceptionHandling" >&5
-+echo "configure:7402: checking for -framework ExceptionHandling" >&5
-     LDFLAGS="$LDFLAGS -framework ExceptionHandling"
-     cat > conftest.$ac_ext <<EOF
--#line 7401 "configure"
-+#line 7405 "configure"
- #include "confdefs.h"
- 
- int main() {
- return 0;
- ; return 0; }
- EOF
--if { (eval echo configure:7408: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:7412: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   ac_cv_have_framework_exceptionhandling="yes"
- else
-@@ -7426,18 +7430,18 @@ rm -f conftest*
-         echo "Skipping -dead_strip because DTrace is enabled. See bug 403132."
-     else
-                 echo $ac_n "checking for -dead_strip option to ld""... $ac_c" 1>&6
--echo "configure:7430: checking for -dead_strip option to ld" >&5
-+echo "configure:7434: checking for -dead_strip option to ld" >&5
-         _SAVE_LDFLAGS=$LDFLAGS
-         LDFLAGS="$LDFLAGS -Wl,-dead_strip"
-         cat > conftest.$ac_ext <<EOF
--#line 7434 "configure"
-+#line 7438 "configure"
- #include "confdefs.h"
- 
- int main() {
- return 0;
- ; return 0; }
- EOF
--if { (eval echo configure:7441: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:7445: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   _HAVE_DEAD_STRIP=1
- else
-@@ -7783,12 +7787,12 @@ EOF
-   do
-        ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
--echo "configure:7787: checking for $ac_hdr" >&5
-+echo "configure:7791: checking for $ac_hdr" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 7792 "configure"
-+#line 7796 "configure"
- #include "confdefs.h"
- 
- #include <$ac_hdr>
-@@ -7796,7 +7800,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:7800: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:7804: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -7989,19 +7993,19 @@ EOF
-     _DEFINES_CXXFLAGS="$_DEFINES_CXXFLAGS -Uunix -U__unix -U__unix__"
- 
-     echo $ac_n "checking for __declspec(dllexport)""... $ac_c" 1>&6
--echo "configure:7993: checking for __declspec(dllexport)" >&5
-+echo "configure:7997: checking for __declspec(dllexport)" >&5
- if eval "test \"`echo '$''{'ac_os2_declspec'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 7998 "configure"
-+#line 8002 "configure"
- #include "confdefs.h"
- __declspec(dllexport) void ac_os2_declspec(void) {}
- int main() {
- return 0;
- ; return 0; }
- EOF
--if { (eval echo configure:8005: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:8009: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_os2_declspec="yes"
- else
-@@ -8054,14 +8058,14 @@ EOF
-            _SAVE_LDFLAGS=$LDFLAGS
-            LDFLAGS="-M /usr/lib/ld/map.noexstk $LDFLAGS"
-            cat > conftest.$ac_ext <<EOF
--#line 8058 "configure"
-+#line 8062 "configure"
- #include "confdefs.h"
- #include <stdio.h>
- int main() {
- printf("Hello World\n");
- ; return 0; }
- EOF
--if { (eval echo configure:8065: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:8069: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   :
- else
-   echo "configure: failed program was:" >&5
-@@ -8089,7 +8093,7 @@ rm -f conftest*
-        CC_VERSION=`$CC -V 2>&1 | grep '^cc:' 2>/dev/null | $AWK -F\: '{ print $2 }'`
-        CXX_VERSION=`$CXX -V 2>&1 | grep '^CC:' 2>/dev/null | $AWK -F\: '{ print $2 }'`
-        echo $ac_n "checking for Sun C++ compiler version >= 5.9""... $ac_c" 1>&6
--echo "configure:8093: checking for Sun C++ compiler version >= 5.9" >&5
-+echo "configure:8097: checking for Sun C++ compiler version >= 5.9" >&5
-        
-        ac_ext=C
- # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-@@ -8099,7 +8103,7 @@ ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftes
- cross_compiling=$ac_cv_prog_cxx_cross
- 
-        cat > conftest.$ac_ext <<EOF
--#line 8103 "configure"
-+#line 8107 "configure"
- #include "confdefs.h"
- 
- int main() {
-@@ -8108,7 +8112,7 @@ int main() {
-            #endif
- ; return 0; }
- EOF
--if { (eval echo configure:8112: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:8116: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   _BAD_COMPILER=
- else
-@@ -8125,7 +8129,7 @@ rm -f conftest*
-            _res="yes"
-        fi
-        cat > conftest.$ac_ext <<EOF
--#line 8129 "configure"
-+#line 8133 "configure"
- #include "confdefs.h"
- 
- int main() {
-@@ -8134,7 +8138,7 @@ int main() {
-            #endif
- ; return 0; }
- EOF
--if { (eval echo configure:8138: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:8142: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   _ABOVE_SS12U1=
- else
-@@ -8535,7 +8539,7 @@ fi
- 
- if test "$GNU_CC" -a "$GCC_USE_GNU_LD" -a -z "$MOZ_DISABLE_ICF"; then
-     echo $ac_n "checking whether the linker supports Identical Code Folding""... $ac_c" 1>&6
--echo "configure:8539: checking whether the linker supports Identical Code Folding" >&5
-+echo "configure:8543: checking whether the linker supports Identical Code Folding" >&5
- if eval "test \"`echo '$''{'LD_SUPPORTS_ICF'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -8544,7 +8548,7 @@ else
-               'int main() {return foo() - bar();}' > conftest.${ac_ext}
-         # If the linker supports ICF, foo and bar symbols will have
-         # the same address
--        if { ac_try='${CC-cc} -o conftest${ac_exeext} $LDFLAGS -Wl,--icf=safe -ffunction-sections conftest.${ac_ext} $LIBS 1>&2'; { (eval echo configure:8548: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } &&
-+        if { ac_try='${CC-cc} -o conftest${ac_exeext} $LDFLAGS -Wl,--icf=safe -ffunction-sections conftest.${ac_ext} $LIBS 1>&2'; { (eval echo configure:8552: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } &&
-            test -s conftest${ac_exeext} &&
-            objdump -t conftest${ac_exeext} | awk '{a[$6] = $1} END {if (a["foo"] && (a["foo"] != a["bar"])) { exit 1 }}'; then
-             LD_SUPPORTS_ICF=yes
-@@ -8559,14 +8563,14 @@ echo "$ac_t""$LD_SUPPORTS_ICF" 1>&6
-         _SAVE_LDFLAGS="$LDFLAGS -Wl,--icf=safe"
-         LDFLAGS="$LDFLAGS -Wl,--icf=safe -Wl,--print-icf-sections"
-         cat > conftest.$ac_ext <<EOF
--#line 8563 "configure"
-+#line 8567 "configure"
- #include "confdefs.h"
- 
- int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:8570: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:8574: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   LD_PRINT_ICF_SECTIONS=-Wl,--print-icf-sections
- else
-@@ -8584,15 +8588,15 @@ fi
- 
- if test "$GNU_CC" -a "$GCC_USE_GNU_LD" -a -n "$MOZ_DEBUG_FLAGS"; then
-       echo $ac_n "checking whether removing dead symbols breaks debugging""... $ac_c" 1>&6
--echo "configure:8588: checking whether removing dead symbols breaks debugging" >&5
-+echo "configure:8592: checking whether removing dead symbols breaks debugging" >&5
- if eval "test \"`echo '$''{'GC_SECTIONS_BREAKS_DEBUG_RANGES'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   echo 'int foo() {return 42;}' \
-              'int bar() {return 1;}' \
-              'int main() {return foo();}' > conftest.${ac_ext}
--        if { ac_try='${CC-cc} -o conftest.${ac_objext} $CFLAGS $MOZ_DEBUG_FLAGS -c conftest.${ac_ext} 1>&2'; { (eval echo configure:8595: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } &&
--           { ac_try='${CC-cc} -o conftest${ac_exeext} $LDFLAGS $MOZ_DEBUG_FLAGS -Wl,--gc-sections conftest.${ac_objext} $LIBS 1>&2'; { (eval echo configure:8596: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } &&
-+        if { ac_try='${CC-cc} -o conftest.${ac_objext} $CFLAGS $MOZ_DEBUG_FLAGS -c conftest.${ac_ext} 1>&2'; { (eval echo configure:8599: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } &&
-+           { ac_try='${CC-cc} -o conftest${ac_exeext} $LDFLAGS $MOZ_DEBUG_FLAGS -Wl,--gc-sections conftest.${ac_objext} $LIBS 1>&2'; { (eval echo configure:8600: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } &&
-            test -s conftest${ac_exeext} -a -s conftest.${ac_objext}; then
-             if test "`$PYTHON "$_topsrcdir"/build/autoconf/check_debug_ranges.py conftest.${ac_objext} conftest.${ac_ext}`" = \
-                     "`$PYTHON "$_topsrcdir"/build/autoconf/check_debug_ranges.py conftest${ac_exeext} conftest.${ac_ext}`"; then
-@@ -8615,12 +8619,12 @@ fi
- 
- if test -z "$SKIP_COMPILER_CHECKS"; then
- echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
--echo "configure:8619: checking for ANSI C header files" >&5
-+echo "configure:8623: checking for ANSI C header files" >&5
- if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 8624 "configure"
-+#line 8628 "configure"
- #include "confdefs.h"
- #include <stdlib.h>
- #include <stdarg.h>
-@@ -8628,7 +8632,7 @@ else
- #include <float.h>
- EOF
- ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
--{ (eval echo configure:8632: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-+{ (eval echo configure:8636: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
- ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
- if test -z "$ac_err"; then
-   rm -rf conftest*
-@@ -8645,7 +8649,7 @@ rm -f conftest*
- if test $ac_cv_header_stdc = yes; then
-   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
- cat > conftest.$ac_ext <<EOF
--#line 8649 "configure"
-+#line 8653 "configure"
- #include "confdefs.h"
- #include <string.h>
- EOF
-@@ -8663,7 +8667,7 @@ fi
- if test $ac_cv_header_stdc = yes; then
-   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
- cat > conftest.$ac_ext <<EOF
--#line 8667 "configure"
-+#line 8671 "configure"
- #include "confdefs.h"
- #include <stdlib.h>
- EOF
-@@ -8684,7 +8688,7 @@ if test "$cross_compiling" = yes; then
-   :
- else
-   cat > conftest.$ac_ext <<EOF
--#line 8688 "configure"
-+#line 8692 "configure"
- #include "confdefs.h"
- #include <ctype.h>
- #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-@@ -8695,7 +8699,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
- exit (0); }
- 
- EOF
--if { (eval echo configure:8699: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-+if { (eval echo configure:8703: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
- then
-   :
- else
-@@ -8722,12 +8726,12 @@ EOF
- fi
- 
- echo $ac_n "checking for working const""... $ac_c" 1>&6
--echo "configure:8726: checking for working const" >&5
-+echo "configure:8730: checking for working const" >&5
- if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 8731 "configure"
-+#line 8735 "configure"
- #include "confdefs.h"
- 
- int main() {
-@@ -8776,7 +8780,7 @@ ccp = (char const *const *) p;
- 
- ; return 0; }
- EOF
--if { (eval echo configure:8780: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:8784: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_c_const=yes
- else
-@@ -8800,12 +8804,12 @@ EOF
- fi
- 
- echo $ac_n "checking for mode_t""... $ac_c" 1>&6
--echo "configure:8804: checking for mode_t" >&5
-+echo "configure:8808: checking for mode_t" >&5
- if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 8809 "configure"
-+#line 8813 "configure"
- #include "confdefs.h"
- #include <sys/types.h>
- #if STDC_HEADERS
-@@ -8836,12 +8840,12 @@ EOF
- fi
- 
- echo $ac_n "checking for off_t""... $ac_c" 1>&6
--echo "configure:8840: checking for off_t" >&5
-+echo "configure:8844: checking for off_t" >&5
- if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 8845 "configure"
-+#line 8849 "configure"
- #include "confdefs.h"
- #include <sys/types.h>
- #if STDC_HEADERS
-@@ -8872,12 +8876,12 @@ EOF
- fi
- 
- echo $ac_n "checking for pid_t""... $ac_c" 1>&6
--echo "configure:8876: checking for pid_t" >&5
-+echo "configure:8880: checking for pid_t" >&5
- if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 8881 "configure"
-+#line 8885 "configure"
- #include "confdefs.h"
- #include <sys/types.h>
- #if STDC_HEADERS
-@@ -8908,12 +8912,12 @@ EOF
- fi
- 
- echo $ac_n "checking for size_t""... $ac_c" 1>&6
--echo "configure:8912: checking for size_t" >&5
-+echo "configure:8916: checking for size_t" >&5
- if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 8917 "configure"
-+#line 8921 "configure"
- #include "confdefs.h"
- #include <sys/types.h>
- #if STDC_HEADERS
-@@ -8951,12 +8955,12 @@ ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftes
- cross_compiling=$ac_cv_prog_cxx_cross
- 
- echo $ac_n "checking for __stdcall""... $ac_c" 1>&6
--echo "configure:8955: checking for __stdcall" >&5
-+echo "configure:8959: checking for __stdcall" >&5
- if eval "test \"`echo '$''{'ac_cv___stdcall'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 8960 "configure"
-+#line 8964 "configure"
- #include "confdefs.h"
- template <typename Method> struct foo;
-                   template <> struct foo<void (*)()> {};
-@@ -8965,7 +8969,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:8969: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:8973: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv___stdcall=true
- else
-@@ -8997,12 +9001,12 @@ ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$a
- cross_compiling=$ac_cv_prog_cc_cross
- 
- echo $ac_n "checking for ssize_t""... $ac_c" 1>&6
--echo "configure:9001: checking for ssize_t" >&5
-+echo "configure:9005: checking for ssize_t" >&5
- if eval "test \"`echo '$''{'ac_cv_type_ssize_t'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 9006 "configure"
-+#line 9010 "configure"
- #include "confdefs.h"
- #include <stdio.h>
-                   #include <sys/types.h>
-@@ -9010,7 +9014,7 @@ int main() {
- ssize_t foo = 0;
- ; return 0; }
- EOF
--if { (eval echo configure:9014: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:9018: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_type_ssize_t=true
- else
-@@ -9035,12 +9039,12 @@ else
-   echo "$ac_t""no" 1>&6
- fi
- echo $ac_n "checking for st_blksize in struct stat""... $ac_c" 1>&6
--echo "configure:9039: checking for st_blksize in struct stat" >&5
-+echo "configure:9043: checking for st_blksize in struct stat" >&5
- if eval "test \"`echo '$''{'ac_cv_struct_st_blksize'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 9044 "configure"
-+#line 9048 "configure"
- #include "confdefs.h"
- #include <sys/types.h>
- #include <sys/stat.h>
-@@ -9048,7 +9052,7 @@ int main() {
- struct stat s; s.st_blksize;
- ; return 0; }
- EOF
--if { (eval echo configure:9052: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:9056: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_struct_st_blksize=yes
- else
-@@ -9072,12 +9076,12 @@ EOF
- fi
- 
- echo $ac_n "checking for siginfo_t""... $ac_c" 1>&6
--echo "configure:9076: checking for siginfo_t" >&5
-+echo "configure:9080: checking for siginfo_t" >&5
- if eval "test \"`echo '$''{'ac_cv_siginfo_t'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 9081 "configure"
-+#line 9085 "configure"
- #include "confdefs.h"
- #define _POSIX_C_SOURCE 199506L
-                   #include <signal.h>
-@@ -9085,7 +9089,7 @@ int main() {
- siginfo_t* info;
- ; return 0; }
- EOF
--if { (eval echo configure:9089: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:9093: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_siginfo_t=true
- else
-@@ -9111,72 +9115,8 @@ else
- fi
- 
- 
--echo $ac_n "checking for the size of void*""... $ac_c" 1>&6
--echo "configure:9116: checking for the size of void*" >&5
--if eval "test \"`echo '$''{'moz_cv_size_of_JS_BYTES_PER_WORD'+set}'`\" = set"; then
--  echo $ac_n "(cached) $ac_c" 1>&6
--else
--  
--  moz_cv_size_of_JS_BYTES_PER_WORD=
--  for size in 4 8; do
--    cat > conftest.$ac_ext <<EOF
--#line 9124 "configure"
--#include "confdefs.h"
--
--int main() {
--
--                     int a[sizeof (void*) == $size ? 1 : -1];
--                     return 0;
--                   
--; return 0; }
--EOF
--if { (eval echo configure:9134: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
--  rm -rf conftest*
--  moz_cv_size_of_JS_BYTES_PER_WORD=$size; break
--else
--  echo "configure: failed program was:" >&5
--  cat conftest.$ac_ext >&5
--fi
--rm -f conftest*
--  done
--  if test ! "$moz_cv_size_of_JS_BYTES_PER_WORD"; then
--    { echo "configure: error: No size found for void*" 1>&2; exit 1; }
--  fi
--
--fi
--
--echo "$ac_t""$moz_cv_size_of_JS_BYTES_PER_WORD" 1>&6
--cat >> confdefs.pytmp <<EOF
--        (''' JS_BYTES_PER_WORD ''', r''' $moz_cv_size_of_JS_BYTES_PER_WORD ''')
--EOF
--cat >> confdefs.h <<EOF
--#define JS_BYTES_PER_WORD $moz_cv_size_of_JS_BYTES_PER_WORD
--EOF
--
--
--if test "$moz_cv_size_of_JS_BYTES_PER_WORD" -eq "4"; then
--  cat >> confdefs.pytmp <<\EOF
--        (''' JS_BITS_PER_WORD_LOG2 ''', r''' 5 ''')
--EOF
--cat >> confdefs.h <<\EOF
--#define JS_BITS_PER_WORD_LOG2 5
--EOF
--
--elif test "$moz_cv_size_of_JS_BYTES_PER_WORD" -eq "8"; then
--  cat >> confdefs.pytmp <<\EOF
--        (''' JS_BITS_PER_WORD_LOG2 ''', r''' 6 ''')
--EOF
--cat >> confdefs.h <<\EOF
--#define JS_BITS_PER_WORD_LOG2 6
--EOF
--
--else
--  { echo "configure: error: Unexpected JS_BYTES_PER_WORD" 1>&2; exit 1; }
--fi
--
--
- echo $ac_n "checking for the alignment of void*""... $ac_c" 1>&6
--echo "configure:9180: checking for the alignment of void*" >&5
-+echo "configure:9120: checking for the alignment of void*" >&5
- if eval "test \"`echo '$''{'moz_cv_align_of_JS_ALIGN_OF_POINTER'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -9184,7 +9124,7 @@ else
-   moz_cv_align_of_JS_ALIGN_OF_POINTER=
-   for align in 2 4 8 16; do
-     cat > conftest.$ac_ext <<EOF
--#line 9188 "configure"
-+#line 9128 "configure"
- #include "confdefs.h"
- 
-                      #include <stddef.h>
-@@ -9197,7 +9137,7 @@ int main() {
-                    
- ; return 0; }
- EOF
--if { (eval echo configure:9201: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:9141: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   moz_cv_align_of_JS_ALIGN_OF_POINTER=$align; break
- else
-@@ -9223,7 +9163,7 @@ EOF
- 
- 
- echo $ac_n "checking for the size of double""... $ac_c" 1>&6
--echo "configure:9227: checking for the size of double" >&5
-+echo "configure:9167: checking for the size of double" >&5
- if eval "test \"`echo '$''{'moz_cv_size_of_JS_BYTES_PER_DOUBLE'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -9231,7 +9171,7 @@ else
-   moz_cv_size_of_JS_BYTES_PER_DOUBLE=
-   for size in 6 8 10 12 14; do
-     cat > conftest.$ac_ext <<EOF
--#line 9235 "configure"
-+#line 9175 "configure"
- #include "confdefs.h"
- 
- int main() {
-@@ -9241,7 +9181,7 @@ int main() {
-                    
- ; return 0; }
- EOF
--if { (eval echo configure:9245: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:9185: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   moz_cv_size_of_JS_BYTES_PER_DOUBLE=$size; break
- else
-@@ -9270,12 +9210,12 @@ EOF
-   do
-        ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
--echo "configure:9274: checking for $ac_hdr" >&5
-+echo "configure:9214: checking for $ac_hdr" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 9279 "configure"
-+#line 9219 "configure"
- #include "confdefs.h"
- 
- #include <$ac_hdr>
-@@ -9283,7 +9223,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:9287: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:9227: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -9326,12 +9266,12 @@ fi
-   do
-        ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
--echo "configure:9330: checking for $ac_hdr" >&5
-+echo "configure:9270: checking for $ac_hdr" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 9335 "configure"
-+#line 9275 "configure"
- #include "confdefs.h"
- #include <sys/types.h>
- #include <$ac_hdr>
-@@ -9339,7 +9279,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:9343: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:9283: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -9382,12 +9322,12 @@ fi
-   do
-        ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
--echo "configure:9386: checking for $ac_hdr" >&5
-+echo "configure:9326: checking for $ac_hdr" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 9391 "configure"
-+#line 9331 "configure"
- #include "confdefs.h"
- 
- #include <$ac_hdr>
-@@ -9395,7 +9335,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:9399: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:9339: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -9435,12 +9375,12 @@ EOF
- fi
- 
- echo $ac_n "checking for uint""... $ac_c" 1>&6
--echo "configure:9439: checking for uint" >&5
-+echo "configure:9379: checking for uint" >&5
- if eval "test \"`echo '$''{'ac_cv_uint'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 9444 "configure"
-+#line 9384 "configure"
- #include "confdefs.h"
- #include <stdio.h>
-                   #include <sys/types.h>
-@@ -9448,7 +9388,7 @@ int main() {
- uint foo = 0;
- ; return 0; }
- EOF
--if { (eval echo configure:9452: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:9392: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_uint=true
- else
-@@ -9473,12 +9413,12 @@ else
-   echo "$ac_t""no" 1>&6
- fi
- echo $ac_n "checking for uint_t""... $ac_c" 1>&6
--echo "configure:9477: checking for uint_t" >&5
-+echo "configure:9417: checking for uint_t" >&5
- if eval "test \"`echo '$''{'ac_cv_uint_t'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 9482 "configure"
-+#line 9422 "configure"
- #include "confdefs.h"
- #include <stdio.h>
-                   #include <sys/types.h>
-@@ -9486,7 +9426,7 @@ int main() {
- uint_t foo = 0;
- ; return 0; }
- EOF
--if { (eval echo configure:9490: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:9430: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_uint_t=true
- else
-@@ -9520,12 +9460,12 @@ cross_compiling=$ac_cv_prog_cxx_cross
- 
- 
- echo $ac_n "checking for uname.domainname""... $ac_c" 1>&6
--echo "configure:9524: checking for uname.domainname" >&5
-+echo "configure:9464: checking for uname.domainname" >&5
- if eval "test \"`echo '$''{'ac_cv_have_uname_domainname_field'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 9529 "configure"
-+#line 9469 "configure"
- #include "confdefs.h"
- #include <sys/utsname.h>
- int main() {
-@@ -9533,7 +9473,7 @@ int main() {
-             (void)uname(res);  if (res != 0) { domain = res->domainname; } 
- ; return 0; }
- EOF
--if { (eval echo configure:9537: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:9477: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_have_uname_domainname_field=true
- else
-@@ -9560,12 +9500,12 @@ else
- fi
- 
- echo $ac_n "checking for uname.__domainname""... $ac_c" 1>&6
--echo "configure:9564: checking for uname.__domainname" >&5
-+echo "configure:9504: checking for uname.__domainname" >&5
- if eval "test \"`echo '$''{'ac_cv_have_uname_us_domainname_field'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 9569 "configure"
-+#line 9509 "configure"
- #include "confdefs.h"
- #include <sys/utsname.h>
- int main() {
-@@ -9573,7 +9513,7 @@ int main() {
-             (void)uname(res);  if (res != 0) { domain = res->__domainname; } 
- ; return 0; }
- EOF
--if { (eval echo configure:9577: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:9517: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_have_uname_us_domainname_field=true
- else
-@@ -9609,7 +9549,7 @@ cross_compiling=$ac_cv_prog_cc_cross
- 
- if test "$GNU_CC"; then
-   echo $ac_n "checking for visibility(hidden) attribute""... $ac_c" 1>&6
--echo "configure:9613: checking for visibility(hidden) attribute" >&5
-+echo "configure:9553: checking for visibility(hidden) attribute" >&5
- if eval "test \"`echo '$''{'ac_cv_visibility_hidden'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -9637,7 +9577,7 @@ EOF
- 
- 
-     echo $ac_n "checking for visibility(default) attribute""... $ac_c" 1>&6
--echo "configure:9641: checking for visibility(default) attribute" >&5
-+echo "configure:9581: checking for visibility(default) attribute" >&5
- if eval "test \"`echo '$''{'ac_cv_visibility_default'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -9665,7 +9605,7 @@ EOF
- 
- 
-       echo $ac_n "checking for visibility pragma support""... $ac_c" 1>&6
--echo "configure:9669: checking for visibility pragma support" >&5
-+echo "configure:9609: checking for visibility pragma support" >&5
- if eval "test \"`echo '$''{'ac_cv_visibility_pragma'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -9690,7 +9630,7 @@ fi
- echo "$ac_t""$ac_cv_visibility_pragma" 1>&6
-       if test "$ac_cv_visibility_pragma" = "yes"; then
-         echo $ac_n "checking For gcc visibility bug with class-level attributes (GCC bug 26905)""... $ac_c" 1>&6
--echo "configure:9694: checking For gcc visibility bug with class-level attributes (GCC bug 26905)" >&5
-+echo "configure:9634: checking For gcc visibility bug with class-level attributes (GCC bug 26905)" >&5
- if eval "test \"`echo '$''{'ac_cv_have_visibility_class_bug'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -9718,7 +9658,7 @@ fi
- echo "$ac_t""$ac_cv_have_visibility_class_bug" 1>&6
- 
-         echo $ac_n "checking For x86_64 gcc visibility bug with builtins (GCC bug 20297)""... $ac_c" 1>&6
--echo "configure:9722: checking For x86_64 gcc visibility bug with builtins (GCC bug 20297)" >&5
-+echo "configure:9662: checking For x86_64 gcc visibility bug with builtins (GCC bug 20297)" >&5
- if eval "test \"`echo '$''{'ac_cv_have_visibility_builtin_bug'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -9770,7 +9710,7 @@ fi         # Sun Studio on Solaris
- if test "$GNU_CC"; then
- 
- echo $ac_n "checking for gcc PR49911""... $ac_c" 1>&6
--echo "configure:9774: checking for gcc PR49911" >&5
-+echo "configure:9714: checking for gcc PR49911" >&5
- ac_have_gcc_pr49911="no"
- 
- ac_ext=C
-@@ -9787,7 +9727,7 @@ if test "$cross_compiling" = yes; then
-   true
- else
-   cat > conftest.$ac_ext <<EOF
--#line 9791 "configure"
-+#line 9731 "configure"
- #include "confdefs.h"
- 
- extern "C" void abort(void);
-@@ -9828,7 +9768,7 @@ int main(void) {
- }
- 
- EOF
--if { (eval echo configure:9832: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-+if { (eval echo configure:9772: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
- then
-   true
- else
-@@ -9865,12 +9805,12 @@ for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
- do
- ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
- echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
--echo "configure:9869: checking for $ac_hdr that defines DIR" >&5
-+echo "configure:9809: checking for $ac_hdr that defines DIR" >&5
- if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 9874 "configure"
-+#line 9814 "configure"
- #include "confdefs.h"
- #include <sys/types.h>
- #include <$ac_hdr>
-@@ -9878,7 +9818,7 @@ int main() {
- DIR *dirp = 0;
- ; return 0; }
- EOF
--if { (eval echo configure:9882: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:9822: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_dirent_$ac_safe=yes"
- else
-@@ -9906,7 +9846,7 @@ done
- # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
- if test $ac_header_dirent = dirent.h; then
- echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
--echo "configure:9910: checking for opendir in -ldir" >&5
-+echo "configure:9850: checking for opendir in -ldir" >&5
- ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
- if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
-@@ -9914,7 +9854,7 @@ else
-   ac_save_LIBS="$LIBS"
- LIBS="-ldir  $LIBS"
- cat > conftest.$ac_ext <<EOF
--#line 9918 "configure"
-+#line 9858 "configure"
- #include "confdefs.h"
- /* Override any gcc2 internal prototype to avoid an error.  */
- /* We use char because int might match the return type of a gcc2
-@@ -9925,7 +9865,7 @@ int main() {
- opendir()
- ; return 0; }
- EOF
--if { (eval echo configure:9929: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:9869: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_lib_$ac_lib_var=yes"
- else
-@@ -9947,7 +9887,7 @@ fi
- 
- else
- echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
--echo "configure:9951: checking for opendir in -lx" >&5
-+echo "configure:9891: checking for opendir in -lx" >&5
- ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
- if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
-@@ -9955,7 +9895,7 @@ else
-   ac_save_LIBS="$LIBS"
- LIBS="-lx  $LIBS"
- cat > conftest.$ac_ext <<EOF
--#line 9959 "configure"
-+#line 9899 "configure"
- #include "confdefs.h"
- /* Override any gcc2 internal prototype to avoid an error.  */
- /* We use char because int might match the return type of a gcc2
-@@ -9966,7 +9906,7 @@ int main() {
- opendir()
- ; return 0; }
- EOF
--if { (eval echo configure:9970: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:9910: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_lib_$ac_lib_var=yes"
- else
-@@ -10000,12 +9940,12 @@ esac
-   do
-        ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
--echo "configure:10004: checking for $ac_hdr" >&5
-+echo "configure:9944: checking for $ac_hdr" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 10009 "configure"
-+#line 9949 "configure"
- #include "confdefs.h"
- 
- #include <$ac_hdr>
-@@ -10013,7 +9953,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:10017: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:9957: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -10048,12 +9988,12 @@ EOF
-   do
-        ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
--echo "configure:10052: checking for $ac_hdr" >&5
-+echo "configure:9992: checking for $ac_hdr" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 10057 "configure"
-+#line 9997 "configure"
- #include "confdefs.h"
- 
- #include <$ac_hdr>
-@@ -10061,7 +10001,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:10065: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:10005: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -10095,12 +10035,12 @@ EOF
-   do
-        ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
--echo "configure:10099: checking for $ac_hdr" >&5
-+echo "configure:10039: checking for $ac_hdr" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 10104 "configure"
-+#line 10044 "configure"
- #include "confdefs.h"
- 
- #include <$ac_hdr>
-@@ -10108,7 +10048,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:10112: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:10052: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -10141,12 +10081,12 @@ EOF
-   do
-        ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
--echo "configure:10145: checking for $ac_hdr" >&5
-+echo "configure:10085: checking for $ac_hdr" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 10150 "configure"
-+#line 10090 "configure"
- #include "confdefs.h"
- 
- #include <$ac_hdr>
-@@ -10154,7 +10094,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:10158: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:10098: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -10188,12 +10128,12 @@ EOF
-   do
-        ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
--echo "configure:10192: checking for $ac_hdr" >&5
-+echo "configure:10132: checking for $ac_hdr" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 10197 "configure"
-+#line 10137 "configure"
- #include "confdefs.h"
- 
- #include <$ac_hdr>
-@@ -10201,7 +10141,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:10205: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:10145: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -10241,12 +10181,12 @@ cross_compiling=$ac_cv_prog_cxx_cross
- NEW_H=new.h
-    ac_safe=`echo "new" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for new""... $ac_c" 1>&6
--echo "configure:10245: checking for new" >&5
-+echo "configure:10185: checking for new" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 10250 "configure"
-+#line 10190 "configure"
- #include "confdefs.h"
- 
- #include <new>
-@@ -10254,7 +10194,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:10258: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:10198: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -10298,12 +10238,12 @@ fi
- if test "x$enable_dtrace" = "xyes"; then
-      ac_safe=`echo "sys/sdt.h" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for sys/sdt.h""... $ac_c" 1>&6
--echo "configure:10302: checking for sys/sdt.h" >&5
-+echo "configure:10242: checking for sys/sdt.h" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 10307 "configure"
-+#line 10247 "configure"
- #include "confdefs.h"
- 
- #include <sys/sdt.h>
-@@ -10311,7 +10251,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:10315: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:10255: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -10353,12 +10293,12 @@ case $target in
-   do
-        ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
--echo "configure:10357: checking for $ac_hdr" >&5
-+echo "configure:10297: checking for $ac_hdr" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 10362 "configure"
-+#line 10302 "configure"
- #include "confdefs.h"
- 
- #include <$ac_hdr>
-@@ -10366,7 +10306,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:10370: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:10310: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -10418,12 +10358,12 @@ CFLAGS="$CFLAGS $LINUX_HEADERS_INCLUDES"
- 
-    ac_safe=`echo "linux/perf_event.h" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for linux/perf_event.h""... $ac_c" 1>&6
--echo "configure:10422: checking for linux/perf_event.h" >&5
-+echo "configure:10362: checking for linux/perf_event.h" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 10427 "configure"
-+#line 10367 "configure"
- #include "confdefs.h"
- 
- #include <linux/perf_event.h>
-@@ -10431,7 +10371,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:10435: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:10375: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -10446,19 +10386,19 @@ fi
-   if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
-     echo "$ac_t""yes" 1>&6
-     echo $ac_n "checking for perf_event_open system call""... $ac_c" 1>&6
--echo "configure:10450: checking for perf_event_open system call" >&5
-+echo "configure:10390: checking for perf_event_open system call" >&5
- if eval "test \"`echo '$''{'ac_cv_perf_event_open'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 10455 "configure"
-+#line 10395 "configure"
- #include "confdefs.h"
- #include <asm/unistd.h>
- int main() {
- return sizeof(__NR_perf_event_open);
- ; return 0; }
- EOF
--if { (eval echo configure:10462: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:10402: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_perf_event_open=yes
- else
-@@ -10494,7 +10434,7 @@ case $target in
- 	;;
- *)
- 	echo $ac_n "checking for gethostbyname_r in -lc_r""... $ac_c" 1>&6
--echo "configure:10498: checking for gethostbyname_r in -lc_r" >&5
-+echo "configure:10438: checking for gethostbyname_r in -lc_r" >&5
- ac_lib_var=`echo c_r'_'gethostbyname_r | sed 'y%./+-%__p_%'`
- if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
-@@ -10502,7 +10442,7 @@ else
-   ac_save_LIBS="$LIBS"
- LIBS="-lc_r  $LIBS"
- cat > conftest.$ac_ext <<EOF
--#line 10506 "configure"
-+#line 10446 "configure"
- #include "confdefs.h"
- /* Override any gcc2 internal prototype to avoid an error.  */
- /* We use char because int might match the return type of a gcc2
-@@ -10513,7 +10453,7 @@ int main() {
- gethostbyname_r()
- ; return 0; }
- EOF
--if { (eval echo configure:10517: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:10457: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_lib_$ac_lib_var=yes"
- else
-@@ -10554,14 +10494,14 @@ case $target in
- *)
-     
- echo $ac_n "checking for library containing dlopen""... $ac_c" 1>&6
--echo "configure:10558: checking for library containing dlopen" >&5
-+echo "configure:10498: checking for library containing dlopen" >&5
- if eval "test \"`echo '$''{'ac_cv_search_dlopen'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   ac_func_search_save_LIBS="$LIBS"
- ac_cv_search_dlopen="no"
- cat > conftest.$ac_ext <<EOF
--#line 10565 "configure"
-+#line 10505 "configure"
- #include "confdefs.h"
- /* Override any gcc2 internal prototype to avoid an error.  */
- /* We use char because int might match the return type of a gcc2
-@@ -10572,7 +10512,7 @@ int main() {
- dlopen()
- ; return 0; }
- EOF
--if { (eval echo configure:10576: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:10516: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   ac_cv_search_dlopen="none required"
- else
-@@ -10583,7 +10523,7 @@ rm -f conftest*
- test "$ac_cv_search_dlopen" = "no" && for i in dl; do
- LIBS="-l$i  $ac_func_search_save_LIBS"
- cat > conftest.$ac_ext <<EOF
--#line 10587 "configure"
-+#line 10527 "configure"
- #include "confdefs.h"
- /* Override any gcc2 internal prototype to avoid an error.  */
- /* We use char because int might match the return type of a gcc2
-@@ -10594,7 +10534,7 @@ int main() {
- dlopen()
- ; return 0; }
- EOF
--if { (eval echo configure:10598: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:10538: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   ac_cv_search_dlopen="-l$i"
- break
-@@ -10612,12 +10552,12 @@ if test "$ac_cv_search_dlopen" != "no"; then
-   test "$ac_cv_search_dlopen" = "none required" || LIBS="$ac_cv_search_dlopen $LIBS"
-      ac_safe=`echo "dlfcn.h" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for dlfcn.h""... $ac_c" 1>&6
--echo "configure:10616: checking for dlfcn.h" >&5
-+echo "configure:10556: checking for dlfcn.h" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 10621 "configure"
-+#line 10561 "configure"
- #include "confdefs.h"
- 
- #include <dlfcn.h>
-@@ -10625,7 +10565,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:10629: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:10569: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -10662,12 +10602,12 @@ CFLAGS="$CFLAGS -D_GNU_SOURCE"
- for ac_func in dladdr
- do
- echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
--echo "configure:10666: checking for $ac_func" >&5
-+echo "configure:10606: checking for $ac_func" >&5
- if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 10671 "configure"
-+#line 10611 "configure"
- #include "confdefs.h"
- /* System header to define __stub macros and hopefully few prototypes,
-     which can conflict with char $ac_func(); below.  */
-@@ -10690,7 +10630,7 @@ $ac_func();
- 
- ; return 0; }
- EOF
--if { (eval echo configure:10694: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:10634: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_func_$ac_func=yes"
- else
-@@ -10724,7 +10664,7 @@ if test ! "$GNU_CXX"; then
-     case $target in
-     *-aix*)
- 	echo $ac_n "checking for demangle in -lC_r""... $ac_c" 1>&6
--echo "configure:10728: checking for demangle in -lC_r" >&5
-+echo "configure:10668: checking for demangle in -lC_r" >&5
- ac_lib_var=`echo C_r'_'demangle | sed 'y%./+-%__p_%'`
- if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
-@@ -10732,7 +10672,7 @@ else
-   ac_save_LIBS="$LIBS"
- LIBS="-lC_r  $LIBS"
- cat > conftest.$ac_ext <<EOF
--#line 10736 "configure"
-+#line 10676 "configure"
- #include "confdefs.h"
- /* Override any gcc2 internal prototype to avoid an error.  */
- /* We use char because int might match the return type of a gcc2
-@@ -10743,7 +10683,7 @@ int main() {
- demangle()
- ; return 0; }
- EOF
--if { (eval echo configure:10747: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:10687: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_lib_$ac_lib_var=yes"
- else
-@@ -10776,7 +10716,7 @@ fi
- 	;;
-      *)
- 	echo $ac_n "checking for demangle in -lC""... $ac_c" 1>&6
--echo "configure:10780: checking for demangle in -lC" >&5
-+echo "configure:10720: checking for demangle in -lC" >&5
- ac_lib_var=`echo C'_'demangle | sed 'y%./+-%__p_%'`
- if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
-@@ -10784,7 +10724,7 @@ else
-   ac_save_LIBS="$LIBS"
- LIBS="-lC  $LIBS"
- cat > conftest.$ac_ext <<EOF
--#line 10788 "configure"
-+#line 10728 "configure"
- #include "confdefs.h"
- /* Override any gcc2 internal prototype to avoid an error.  */
- /* We use char because int might match the return type of a gcc2
-@@ -10795,7 +10735,7 @@ int main() {
- demangle()
- ; return 0; }
- EOF
--if { (eval echo configure:10799: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:10739: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_lib_$ac_lib_var=yes"
- else
-@@ -10834,7 +10774,7 @@ case $target in
-     ;;
- *)
-     echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6
--echo "configure:10838: checking for socket in -lsocket" >&5
-+echo "configure:10778: checking for socket in -lsocket" >&5
- ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'`
- if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
-@@ -10842,7 +10782,7 @@ else
-   ac_save_LIBS="$LIBS"
- LIBS="-lsocket  $LIBS"
- cat > conftest.$ac_ext <<EOF
--#line 10846 "configure"
-+#line 10786 "configure"
- #include "confdefs.h"
- /* Override any gcc2 internal prototype to avoid an error.  */
- /* We use char because int might match the return type of a gcc2
-@@ -10853,7 +10793,7 @@ int main() {
- socket()
- ; return 0; }
- EOF
--if { (eval echo configure:10857: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:10797: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_lib_$ac_lib_var=yes"
- else
-@@ -10892,7 +10832,7 @@ darwin*)
- *)
-     
- echo $ac_n "checking for pthread_create in -lpthreads""... $ac_c" 1>&6
--echo "configure:10896: checking for pthread_create in -lpthreads" >&5
-+echo "configure:10836: checking for pthread_create in -lpthreads" >&5
- echo "
-     #include <pthread.h>
-     #include <stdlib.h>
-@@ -10915,7 +10855,7 @@ echo "
-         echo "$ac_t""no" 1>&6
-         
- echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6
--echo "configure:10919: checking for pthread_create in -lpthread" >&5
-+echo "configure:10859: checking for pthread_create in -lpthread" >&5
- echo "
-     #include <pthread.h>
-     #include <stdlib.h>
-@@ -10938,7 +10878,7 @@ echo "
-         echo "$ac_t""no" 1>&6
-         
- echo $ac_n "checking for pthread_create in -lc_r""... $ac_c" 1>&6
--echo "configure:10942: checking for pthread_create in -lc_r" >&5
-+echo "configure:10882: checking for pthread_create in -lc_r" >&5
- echo "
-     #include <pthread.h>
-     #include <stdlib.h>
-@@ -10961,7 +10901,7 @@ echo "
-         echo "$ac_t""no" 1>&6
-         
- echo $ac_n "checking for pthread_create in -lc""... $ac_c" 1>&6
--echo "configure:10965: checking for pthread_create in -lc" >&5
-+echo "configure:10905: checking for pthread_create in -lc" >&5
- echo "
-     #include <pthread.h>
-     #include <stdlib.h>
-@@ -11020,7 +10960,7 @@ then
- 				rm -f conftest*
- 	ac_cv_have_dash_pthread=no
- 	echo $ac_n "checking whether ${CC-cc} accepts -pthread""... $ac_c" 1>&6
--echo "configure:11024: checking whether ${CC-cc} accepts -pthread" >&5
-+echo "configure:10964: checking whether ${CC-cc} accepts -pthread" >&5
- 	echo 'int main() { return 0; }' | cat > conftest.c
- 	${CC-cc} -pthread -o conftest conftest.c > conftest.out 2>&1
- 	if test $? -eq 0; then
-@@ -11043,7 +10983,7 @@ echo "configure:11024: checking whether ${CC-cc} accepts -pthread" >&5
- 			    ac_cv_have_dash_pthreads=no
-     if test "$ac_cv_have_dash_pthread" = "no"; then
- 	    echo $ac_n "checking whether ${CC-cc} accepts -pthreads""... $ac_c" 1>&6
--echo "configure:11047: checking whether ${CC-cc} accepts -pthreads" >&5
-+echo "configure:10987: checking whether ${CC-cc} accepts -pthreads" >&5
-     	echo 'int main() { return 0; }' | cat > conftest.c
- 	    ${CC-cc} -pthreads -o conftest conftest.c > conftest.out 2>&1
-     	if test $? -eq 0; then
-@@ -11148,13 +11088,13 @@ fi
- 
- if test $ac_cv_prog_gcc = yes; then
-     echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&6
--echo "configure:11152: checking whether ${CC-cc} needs -traditional" >&5
-+echo "configure:11092: checking whether ${CC-cc} needs -traditional" >&5
- if eval "test \"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-     ac_pattern="Autoconf.*'x'"
-   cat > conftest.$ac_ext <<EOF
--#line 11158 "configure"
-+#line 11098 "configure"
- #include "confdefs.h"
- #include <sgtty.h>
- Autoconf TIOCGETP
-@@ -11172,7 +11112,7 @@ rm -f conftest*
- 
-   if test $ac_cv_prog_gcc_traditional = no; then
-     cat > conftest.$ac_ext <<EOF
--#line 11176 "configure"
-+#line 11116 "configure"
- #include "confdefs.h"
- #include <termio.h>
- Autoconf TCGETA
-@@ -11194,7 +11134,7 @@ echo "$ac_t""$ac_cv_prog_gcc_traditional" 1>&6
- fi
- 
- echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6
--echo "configure:11198: checking for 8-bit clean memcmp" >&5
-+echo "configure:11138: checking for 8-bit clean memcmp" >&5
- if eval "test \"`echo '$''{'ac_cv_func_memcmp_clean'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -11202,7 +11142,7 @@ else
-   ac_cv_func_memcmp_clean=no
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11206 "configure"
-+#line 11146 "configure"
- #include "confdefs.h"
- 
- main()
-@@ -11212,7 +11152,7 @@ main()
- }
- 
- EOF
--if { (eval echo configure:11216: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-+if { (eval echo configure:11156: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
- then
-   ac_cv_func_memcmp_clean=yes
- else
-@@ -11234,12 +11174,12 @@ for ac_func in fchmod flockfile getc_unlocked _getc_nolock getpagesize \
-                 stat64 statvfs statvfs64 strerror strtok_r truncate64
- do
- echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
--echo "configure:11238: checking for $ac_func" >&5
-+echo "configure:11178: checking for $ac_func" >&5
- if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11243 "configure"
-+#line 11183 "configure"
- #include "confdefs.h"
- /* System header to define __stub macros and hopefully few prototypes,
-     which can conflict with char $ac_func(); below.  */
-@@ -11262,7 +11202,7 @@ $ac_func();
- 
- ; return 0; }
- EOF
--if { (eval echo configure:11266: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:11206: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_func_$ac_func=yes"
- else
-@@ -11291,14 +11231,14 @@ done
- 
- 
- cat > conftest.$ac_ext <<EOF
--#line 11295 "configure"
-+#line 11235 "configure"
- #include "confdefs.h"
- #include <windows.h>
- int main() {
- SYSTEMTIME st;FILETIME ft;SystemTimeToFileTime(&st,&ft);
- ; return 0; }
- EOF
--if { (eval echo configure:11302: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:11242: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   ac_cv_have_systemtimetofiletime="yes"
- else
-@@ -11318,14 +11258,14 @@ EOF
- 
- fi
- cat > conftest.$ac_ext <<EOF
--#line 11322 "configure"
-+#line 11262 "configure"
- #include "confdefs.h"
- #include <windows.h>
- int main() {
- FILETIME ft;GetSystemTimeAsFileTime(&ft);
- ; return 0; }
- EOF
--if { (eval echo configure:11329: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:11269: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   ac_cv_have_getsystemtimeasfiletime="yes"
- else
-@@ -11355,19 +11295,19 @@ ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftes
- cross_compiling=$ac_cv_prog_cxx_cross
- 
- echo $ac_n "checking for wcrtomb""... $ac_c" 1>&6
--echo "configure:11359: checking for wcrtomb" >&5
-+echo "configure:11299: checking for wcrtomb" >&5
- if eval "test \"`echo '$''{'ac_cv_have_wcrtomb'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11364 "configure"
-+#line 11304 "configure"
- #include "confdefs.h"
- #include <wchar.h>
- int main() {
- mbstate_t ps={0};wcrtomb(0,'f',&ps);
- ; return 0; }
- EOF
--if { (eval echo configure:11371: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:11311: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   ac_cv_have_wcrtomb="yes"
- else
-@@ -11390,19 +11330,19 @@ EOF
- 
- fi
- echo $ac_n "checking for mbrtowc""... $ac_c" 1>&6
--echo "configure:11394: checking for mbrtowc" >&5
-+echo "configure:11334: checking for mbrtowc" >&5
- if eval "test \"`echo '$''{'ac_cv_have_mbrtowc'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11399 "configure"
-+#line 11339 "configure"
- #include "confdefs.h"
- #include <wchar.h>
- int main() {
- mbstate_t ps={0};mbrtowc(0,0,0,&ps);
- ; return 0; }
- EOF
--if { (eval echo configure:11406: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:11346: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   ac_cv_have_mbrtowc="yes"
- else
-@@ -11434,12 +11374,12 @@ cross_compiling=$ac_cv_prog_cc_cross
- fi
- 
- echo $ac_n "checking for res_ninit()""... $ac_c" 1>&6
--echo "configure:11438: checking for res_ninit()" >&5
-+echo "configure:11378: checking for res_ninit()" >&5
- if eval "test \"`echo '$''{'ac_cv_func_res_ninit'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11443 "configure"
-+#line 11383 "configure"
- #include "confdefs.h"
- 
-         #ifdef linux
-@@ -11451,7 +11391,7 @@ int main() {
- int foo = res_ninit(&_res);
- ; return 0; }
- EOF
--if { (eval echo configure:11455: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:11395: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   ac_cv_func_res_ninit=yes
- else
-@@ -11484,12 +11424,12 @@ ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftes
- cross_compiling=$ac_cv_prog_cxx_cross
- 
- echo $ac_n "checking for gnu_get_libc_version()""... $ac_c" 1>&6
--echo "configure:11488: checking for gnu_get_libc_version()" >&5
-+echo "configure:11428: checking for gnu_get_libc_version()" >&5
- if eval "test \"`echo '$''{'ac_cv_func_gnu_get_libc_version'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11493 "configure"
-+#line 11433 "configure"
- #include "confdefs.h"
- 
-         #ifdef HAVE_GNU_LIBC_VERSION_H
-@@ -11500,7 +11440,7 @@ int main() {
- const char *glibc_version = gnu_get_libc_version();
- ; return 0; }
- EOF
--if { (eval echo configure:11504: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:11444: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   ac_cv_func_gnu_get_libc_version=yes
- else
-@@ -11534,7 +11474,7 @@ cross_compiling=$ac_cv_prog_cc_cross
- 
- 
- echo $ac_n "checking for an implementation of va_copy()""... $ac_c" 1>&6
--echo "configure:11538: checking for an implementation of va_copy()" >&5
-+echo "configure:11478: checking for an implementation of va_copy()" >&5
- if eval "test \"`echo '$''{'ac_cv_va_copy'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -11544,7 +11484,7 @@ else
-     
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11548 "configure"
-+#line 11488 "configure"
- #include "confdefs.h"
- 
-         #include <stdarg.h>
-@@ -11558,7 +11498,7 @@ else
-         }
-         int main() { f (0, 42); return 0; }
- EOF
--if { (eval echo configure:11562: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-+if { (eval echo configure:11502: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
- then
-   ac_cv_va_copy=yes
- else
-@@ -11575,7 +11515,7 @@ fi
- 
- echo "$ac_t""$ac_cv_va_copy" 1>&6
- echo $ac_n "checking for an implementation of __va_copy()""... $ac_c" 1>&6
--echo "configure:11579: checking for an implementation of __va_copy()" >&5
-+echo "configure:11519: checking for an implementation of __va_copy()" >&5
- if eval "test \"`echo '$''{'ac_cv___va_copy'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -11585,7 +11525,7 @@ else
-     
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11589 "configure"
-+#line 11529 "configure"
- #include "confdefs.h"
- 
-         #include <stdarg.h>
-@@ -11599,7 +11539,7 @@ else
-         }
-         int main() { f (0, 42); return 0; }
- EOF
--if { (eval echo configure:11603: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-+if { (eval echo configure:11543: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
- then
-   ac_cv___va_copy=yes
- else
-@@ -11616,7 +11556,7 @@ fi
- 
- echo "$ac_t""$ac_cv___va_copy" 1>&6
- echo $ac_n "checking whether va_lists can be copied by value""... $ac_c" 1>&6
--echo "configure:11620: checking whether va_lists can be copied by value" >&5
-+echo "configure:11560: checking whether va_lists can be copied by value" >&5
- if eval "test \"`echo '$''{'ac_cv_va_val_copy'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -11626,7 +11566,7 @@ else
-     
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11630 "configure"
-+#line 11570 "configure"
- #include "confdefs.h"
- 
-         #include <stdarg.h>
-@@ -11640,7 +11580,7 @@ else
-         }
-         int main() { f (0, 42); return 0; }
- EOF
--if { (eval echo configure:11644: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-+if { (eval echo configure:11584: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
- then
-   ac_cv_va_val_copy=yes
- else
-@@ -11710,12 +11650,12 @@ ARM_ABI_PREFIX=
- if test "$GNU_CC"; then
-   if test "$CPU_ARCH" = "arm" ; then
-     echo $ac_n "checking for ARM EABI""... $ac_c" 1>&6
--echo "configure:11714: checking for ARM EABI" >&5
-+echo "configure:11654: checking for ARM EABI" >&5
- if eval "test \"`echo '$''{'ac_cv_gcc_arm_eabi'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11719 "configure"
-+#line 11659 "configure"
- #include "confdefs.h"
- 
- int main() {
-@@ -11728,7 +11668,7 @@ int main() {
-                         
- ; return 0; }
- EOF
--if { (eval echo configure:11732: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:11672: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_gcc_arm_eabi="yes"
- else
-@@ -11753,12 +11693,12 @@ echo "$ac_t""$ac_cv_gcc_arm_eabi" 1>&6
- fi
- 
- echo $ac_n "checking for modern C++ template specialization syntax support""... $ac_c" 1>&6
--echo "configure:11757: checking for modern C++ template specialization syntax support" >&5
-+echo "configure:11697: checking for modern C++ template specialization syntax support" >&5
- if eval "test \"`echo '$''{'ac_cv_cpp_modern_specialize_template_syntax'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11762 "configure"
-+#line 11702 "configure"
- #include "confdefs.h"
- template <class T> struct X { int a; };
-                                class Y {};
-@@ -11768,7 +11708,7 @@ X<int> int_x;
-                                X<Y> y_x;
- ; return 0; }
- EOF
--if { (eval echo configure:11772: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:11712: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_cpp_modern_specialize_template_syntax=yes
- else
-@@ -11786,12 +11726,12 @@ if test "$ac_cv_cpp_modern_specialize_template_syntax" = no ; then
- fi
- 
- echo $ac_n "checking whether partial template specialization works""... $ac_c" 1>&6
--echo "configure:11790: checking whether partial template specialization works" >&5
-+echo "configure:11730: checking whether partial template specialization works" >&5
- if eval "test \"`echo '$''{'ac_cv_cpp_partial_specialization'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11795 "configure"
-+#line 11735 "configure"
- #include "confdefs.h"
- template <class T> class Foo {};
-                                template <class T> class Foo<T*> {};
-@@ -11799,7 +11739,7 @@ int main() {
- return 0;
- ; return 0; }
- EOF
--if { (eval echo configure:11803: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:11743: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_cpp_partial_specialization=yes
- else
-@@ -11823,12 +11763,12 @@ EOF
- fi
- 
- echo $ac_n "checking whether the C++ \"using\" keyword resolves ambiguity""... $ac_c" 1>&6
--echo "configure:11827: checking whether the C++ \"using\" keyword resolves ambiguity" >&5
-+echo "configure:11767: checking whether the C++ \"using\" keyword resolves ambiguity" >&5
- if eval "test \"`echo '$''{'ac_cv_cpp_ambiguity_resolving_using'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11832 "configure"
-+#line 11772 "configure"
- #include "confdefs.h"
- class X {
-                                  public: int go(const X&) {return 3;}
-@@ -11844,7 +11784,7 @@ int main() {
- X x; Y y; y.jo(x);
- ; return 0; }
- EOF
--if { (eval echo configure:11848: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:11788: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_cpp_ambiguity_resolving_using=yes
- else
-@@ -11868,7 +11808,7 @@ EOF
- fi
- 
- echo $ac_n "checking for C++ dynamic_cast to void*""... $ac_c" 1>&6
--echo "configure:11872: checking for C++ dynamic_cast to void*" >&5
-+echo "configure:11812: checking for C++ dynamic_cast to void*" >&5
- if eval "test \"`echo '$''{'ac_cv_cpp_dynamic_cast_void_ptr'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -11876,7 +11816,7 @@ else
-   ac_cv_cpp_dynamic_cast_void_ptr=no
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11880 "configure"
-+#line 11820 "configure"
- #include "confdefs.h"
- class X { int i; public: virtual ~X() { } };
-                             class Y { int j; public: virtual ~Y() { } };
-@@ -11892,7 +11832,7 @@ class X { int i; public: virtual ~X() { } };
-                                            ((void*)&mdo == dynamic_cast<void*>(suby))));
-                             }
- EOF
--if { (eval echo configure:11896: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-+if { (eval echo configure:11836: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
- then
-   ac_cv_cpp_dynamic_cast_void_ptr=yes
- else
-@@ -11919,19 +11859,19 @@ fi
- 
- 
- echo $ac_n "checking whether C++ requires implementation of unused virtual methods""... $ac_c" 1>&6
--echo "configure:11923: checking whether C++ requires implementation of unused virtual methods" >&5
-+echo "configure:11863: checking whether C++ requires implementation of unused virtual methods" >&5
- if eval "test \"`echo '$''{'ac_cv_cpp_unused_required'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11928 "configure"
-+#line 11868 "configure"
- #include "confdefs.h"
- class X {private: virtual void never_called();};
- int main() {
- X x;
- ; return 0; }
- EOF
--if { (eval echo configure:11935: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:11875: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   ac_cv_cpp_unused_required=no
- else
-@@ -11957,12 +11897,12 @@ fi
- 
- 
- echo $ac_n "checking for trouble comparing to zero near std::operator!=()""... $ac_c" 1>&6
--echo "configure:11961: checking for trouble comparing to zero near std::operator!=()" >&5
-+echo "configure:11901: checking for trouble comparing to zero near std::operator!=()" >&5
- if eval "test \"`echo '$''{'ac_cv_trouble_comparing_to_zero'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 11966 "configure"
-+#line 11906 "configure"
- #include "confdefs.h"
- #include <algorithm>
-                                 template <class T> class Foo {};
-@@ -11973,7 +11913,7 @@ int main() {
- Foo<int> f; return (0 != f);
- ; return 0; }
- EOF
--if { (eval echo configure:11977: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:11917: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_trouble_comparing_to_zero=no
- else
-@@ -12003,19 +11943,19 @@ fi
- _SAVE_LDFLAGS=$LDFLAGS
- LDFLAGS="$LDFLAGS $DSO_PIC_CFLAGS $DSO_LDOPTS $MOZ_OPTIMIZE_LDFLAGS"
- echo $ac_n "checking for __thread keyword for TLS variables""... $ac_c" 1>&6
--echo "configure:12007: checking for __thread keyword for TLS variables" >&5
-+echo "configure:11947: checking for __thread keyword for TLS variables" >&5
- if eval "test \"`echo '$''{'ac_cv_thread_keyword'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 12012 "configure"
-+#line 11952 "configure"
- #include "confdefs.h"
- __thread bool tlsIsMainThread = false;
- int main() {
- return tlsIsMainThread;
- ; return 0; }
- EOF
--if { (eval echo configure:12019: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:11959: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   ac_cv_thread_keyword=yes
- else
-@@ -12055,12 +11995,12 @@ fi
- MALLOC_H=
-    ac_safe=`echo "malloc.h" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for malloc.h""... $ac_c" 1>&6
--echo "configure:12059: checking for malloc.h" >&5
-+echo "configure:11999: checking for malloc.h" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 12064 "configure"
-+#line 12004 "configure"
- #include "confdefs.h"
- 
- #include <malloc.h>
-@@ -12068,7 +12008,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:12072: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:12012: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -12091,12 +12031,12 @@ fi
- if test "$MALLOC_H" = ""; then
-      ac_safe=`echo "malloc/malloc.h" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for malloc/malloc.h""... $ac_c" 1>&6
--echo "configure:12095: checking for malloc/malloc.h" >&5
-+echo "configure:12035: checking for malloc/malloc.h" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 12100 "configure"
-+#line 12040 "configure"
- #include "confdefs.h"
- 
- #include <malloc/malloc.h>
-@@ -12104,7 +12044,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:12108: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:12048: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -12127,12 +12067,12 @@ fi
-   if test "$MALLOC_H" = ""; then
-        ac_safe=`echo "sys/malloc.h" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for sys/malloc.h""... $ac_c" 1>&6
--echo "configure:12131: checking for sys/malloc.h" >&5
-+echo "configure:12071: checking for sys/malloc.h" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 12136 "configure"
-+#line 12076 "configure"
- #include "confdefs.h"
- 
- #include <sys/malloc.h>
-@@ -12140,7 +12080,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:12144: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:12084: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -12176,12 +12116,12 @@ MOZ_ALLOCATING_FUNCS="strndup posix_memalign memalign valloc"
- for ac_func in strndup posix_memalign memalign valloc
- do
- echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
--echo "configure:12180: checking for $ac_func" >&5
-+echo "configure:12120: checking for $ac_func" >&5
- if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 12185 "configure"
-+#line 12125 "configure"
- #include "confdefs.h"
- /* System header to define __stub macros and hopefully few prototypes,
-     which can conflict with char $ac_func(); below.  */
-@@ -12207,7 +12147,7 @@ $ac_func();
- 
- ; return 0; }
- EOF
--if { (eval echo configure:12211: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:12151: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_func_$ac_func=yes"
- else
-@@ -12237,19 +12177,19 @@ done
- 
- 
- echo $ac_n "checking for __attribute__((always_inline))""... $ac_c" 1>&6
--echo "configure:12241: checking for __attribute__((always_inline))" >&5
-+echo "configure:12181: checking for __attribute__((always_inline))" >&5
- if eval "test \"`echo '$''{'ac_cv_attribute_always_inline'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 12246 "configure"
-+#line 12186 "configure"
- #include "confdefs.h"
- inline void f(void) __attribute__((always_inline));
- int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:12253: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:12193: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_attribute_always_inline=yes
- else
-@@ -12264,19 +12204,19 @@ fi
- echo "$ac_t""$ac_cv_attribute_always_inline" 1>&6
- 
- echo $ac_n "checking for __attribute__((malloc))""... $ac_c" 1>&6
--echo "configure:12268: checking for __attribute__((malloc))" >&5
-+echo "configure:12208: checking for __attribute__((malloc))" >&5
- if eval "test \"`echo '$''{'ac_cv_attribute_malloc'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 12273 "configure"
-+#line 12213 "configure"
- #include "confdefs.h"
- void* f(int) __attribute__((malloc));
- int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:12280: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:12220: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_attribute_malloc=yes
- else
-@@ -12291,19 +12231,19 @@ fi
- echo "$ac_t""$ac_cv_attribute_malloc" 1>&6
- 
- echo $ac_n "checking for __attribute__((warn_unused_result))""... $ac_c" 1>&6
--echo "configure:12295: checking for __attribute__((warn_unused_result))" >&5
-+echo "configure:12235: checking for __attribute__((warn_unused_result))" >&5
- if eval "test \"`echo '$''{'ac_cv_attribute_warn_unused'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 12300 "configure"
-+#line 12240 "configure"
- #include "confdefs.h"
- int f(void) __attribute__((warn_unused_result));
- int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:12307: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:12247: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_attribute_warn_unused=yes
- else
-@@ -12327,19 +12267,19 @@ cross_compiling=$ac_cv_prog_cc_cross
- 
- 
- echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
--echo "configure:12331: checking for LC_MESSAGES" >&5
-+echo "configure:12271: checking for LC_MESSAGES" >&5
- if eval "test \"`echo '$''{'ac_cv_i18n_lc_messages'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 12336 "configure"
-+#line 12276 "configure"
- #include "confdefs.h"
- #include <locale.h>
- int main() {
- int category = LC_MESSAGES;
- ; return 0; }
- EOF
--if { (eval echo configure:12343: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:12283: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_i18n_lc_messages=yes
- else
-@@ -12365,12 +12305,12 @@ fi
- for ac_func in localeconv
- do
- echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
--echo "configure:12369: checking for $ac_func" >&5
-+echo "configure:12309: checking for $ac_func" >&5
- if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 12374 "configure"
-+#line 12314 "configure"
- #include "confdefs.h"
- /* System header to define __stub macros and hopefully few prototypes,
-     which can conflict with char $ac_func(); below.  */
-@@ -12393,7 +12333,7 @@ $ac_func();
- 
- ; return 0; }
- EOF
--if { (eval echo configure:12397: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:12337: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_func_$ac_func=yes"
- else
-@@ -12580,7 +12520,7 @@ fi
- 	# Extract the first word of "nspr-config", so it can be a program name with args.
- set dummy nspr-config; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
--echo "configure:12584: checking for $ac_word" >&5
-+echo "configure:12524: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_NSPR_CONFIG'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -12615,7 +12555,7 @@ fi
- 
- 	min_nspr_version=$NSPR_MINVER
- 	echo $ac_n "checking for NSPR - version >= $min_nspr_version""... $ac_c" 1>&6
--echo "configure:12619: checking for NSPR - version >= $min_nspr_version" >&5
-+echo "configure:12559: checking for NSPR - version >= $min_nspr_version" >&5
- 
- 	no_nspr=""
- 	if test "$NSPR_CONFIG" != "no"; then
-@@ -12678,7 +12618,7 @@ if test -n "$MOZ_NATIVE_NSPR"; then
-     _SAVE_CFLAGS=$CFLAGS
-     CFLAGS="$CFLAGS $NSPR_CFLAGS"
-     cat > conftest.$ac_ext <<EOF
--#line 12682 "configure"
-+#line 12622 "configure"
- #include "confdefs.h"
- #include "prlog.h"
- int main() {
-@@ -12687,7 +12627,7 @@ int main() {
-                  #endif
- ; return 0; }
- EOF
--if { (eval echo configure:12691: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:12631: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   MOZ_NATIVE_NSPR=1
- else
-@@ -12729,7 +12669,7 @@ if test -z "$MOZ_ZLIB_LIBS$MOZ_ZLIB_CFLAGS$SKIP_LIBRARY_CHECKS"; then
-         MOZ_NATIVE_ZLIB=
-     else
-         echo $ac_n "checking for gzread in -lz""... $ac_c" 1>&6
--echo "configure:12733: checking for gzread in -lz" >&5
-+echo "configure:12673: checking for gzread in -lz" >&5
- ac_lib_var=`echo z'_'gzread | sed 'y%./+-%__p_%'`
- if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
-@@ -12737,7 +12677,7 @@ else
-   ac_save_LIBS="$LIBS"
- LIBS="-lz  $LIBS"
- cat > conftest.$ac_ext <<EOF
--#line 12741 "configure"
-+#line 12681 "configure"
- #include "confdefs.h"
- /* Override any gcc2 internal prototype to avoid an error.  */
- /* We use char because int might match the return type of a gcc2
-@@ -12748,7 +12688,7 @@ int main() {
- gzread()
- ; return 0; }
- EOF
--if { (eval echo configure:12752: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:12692: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_lib_$ac_lib_var=yes"
- else
-@@ -12772,7 +12712,7 @@ fi
-         if test "$MOZ_NATIVE_ZLIB" = 1; then
-             MOZZLIBNUM=`echo $MOZZLIB | awk -F. '{printf "0x%x\n", ((($1 * 16 + $2) * 16) + $3) * 16 + $4}'`
-             cat > conftest.$ac_ext <<EOF
--#line 12776 "configure"
-+#line 12716 "configure"
- #include "confdefs.h"
-  #include <stdio.h>
-                              #include <string.h>
-@@ -12783,7 +12723,7 @@ int main() {
-                              #endif 
- ; return 0; }
- EOF
--if { (eval echo configure:12787: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:12727: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   MOZ_NATIVE_ZLIB=1
- else
-@@ -12829,7 +12769,7 @@ if test -n "$MOZ_NATIVE_FFI"; then
-     # Extract the first word of "pkg-config", so it can be a program name with args.
- set dummy pkg-config; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
--echo "configure:12833: checking for $ac_word" >&5
-+echo "configure:12773: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_PKG_CONFIG'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -12873,19 +12813,19 @@ fi
-      PKG_CONFIG_MIN_VERSION=0.9.0
-      if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
-         echo $ac_n "checking for libffi > 3.0.9""... $ac_c" 1>&6
--echo "configure:12877: checking for libffi > 3.0.9" >&5
-+echo "configure:12817: checking for libffi > 3.0.9" >&5
- 
-         if $PKG_CONFIG --exists "libffi > 3.0.9" ; then
-             echo "$ac_t""yes" 1>&6
-             succeeded=yes
- 
-             echo $ac_n "checking MOZ_FFI_CFLAGS""... $ac_c" 1>&6
--echo "configure:12884: checking MOZ_FFI_CFLAGS" >&5
-+echo "configure:12824: checking MOZ_FFI_CFLAGS" >&5
-             MOZ_FFI_CFLAGS=`$PKG_CONFIG --cflags "libffi > 3.0.9"`
-             echo "$ac_t""$MOZ_FFI_CFLAGS" 1>&6
- 
-             echo $ac_n "checking MOZ_FFI_LIBS""... $ac_c" 1>&6
--echo "configure:12889: checking MOZ_FFI_LIBS" >&5
-+echo "configure:12829: checking MOZ_FFI_LIBS" >&5
-             ## Remove evil flags like -Wl,--export-dynamic
-             MOZ_FFI_LIBS="`$PKG_CONFIG --libs \"libffi > 3.0.9\" |sed s/-Wl,--export-dynamic//g`"
-             echo "$ac_t""$MOZ_FFI_LIBS" 1>&6
-@@ -12921,7 +12861,7 @@ echo "configure:12889: checking MOZ_FFI_LIBS" >&5
-     # Extract the first word of "pkg-config", so it can be a program name with args.
- set dummy pkg-config; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
--echo "configure:12925: checking for $ac_word" >&5
-+echo "configure:12865: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_PKG_CONFIG'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -12965,19 +12905,19 @@ fi
-      PKG_CONFIG_MIN_VERSION=0.9.0
-      if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
-         echo $ac_n "checking for libffi >= 3.0.9""... $ac_c" 1>&6
--echo "configure:12969: checking for libffi >= 3.0.9" >&5
-+echo "configure:12909: checking for libffi >= 3.0.9" >&5
- 
-         if $PKG_CONFIG --exists "libffi >= 3.0.9" ; then
-             echo "$ac_t""yes" 1>&6
-             succeeded=yes
- 
-             echo $ac_n "checking MOZ_FFI_CFLAGS""... $ac_c" 1>&6
--echo "configure:12976: checking MOZ_FFI_CFLAGS" >&5
-+echo "configure:12916: checking MOZ_FFI_CFLAGS" >&5
-             MOZ_FFI_CFLAGS=`$PKG_CONFIG --cflags "libffi >= 3.0.9"`
-             echo "$ac_t""$MOZ_FFI_CFLAGS" 1>&6
- 
-             echo $ac_n "checking MOZ_FFI_LIBS""... $ac_c" 1>&6
--echo "configure:12981: checking MOZ_FFI_LIBS" >&5
-+echo "configure:12921: checking MOZ_FFI_LIBS" >&5
-             ## Remove evil flags like -Wl,--export-dynamic
-             MOZ_FFI_LIBS="`$PKG_CONFIG --libs \"libffi >= 3.0.9\" |sed s/-Wl,--export-dynamic//g`"
-             echo "$ac_t""$MOZ_FFI_LIBS" 1>&6
-@@ -13112,18 +13052,18 @@ MOZ_DEBUG_DISABLE_DEFS="-DNDEBUG -DTRIMMED"
- 
- if test -n "$MOZ_DEBUG"; then
-     echo $ac_n "checking for valid debug flags""... $ac_c" 1>&6
--echo "configure:13116: checking for valid debug flags" >&5
-+echo "configure:13056: checking for valid debug flags" >&5
-     _SAVE_CFLAGS=$CFLAGS
-     CFLAGS="$CFLAGS $MOZ_DEBUG_FLAGS"
-     cat > conftest.$ac_ext <<EOF
--#line 13120 "configure"
-+#line 13060 "configure"
- #include "confdefs.h"
- #include <stdio.h>
- int main() {
- printf("Hello World\n");
- ; return 0; }
- EOF
--if { (eval echo configure:13127: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:13067: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   _results=yes
- else
-@@ -13201,18 +13141,18 @@ fi
- if test "$COMPILE_ENVIRONMENT"; then
- if test -n "$MOZ_OPTIMIZE"; then
-     echo $ac_n "checking for valid optimization flags""... $ac_c" 1>&6
--echo "configure:13205: checking for valid optimization flags" >&5
-+echo "configure:13145: checking for valid optimization flags" >&5
-     _SAVE_CFLAGS=$CFLAGS
-     CFLAGS="$CFLAGS $MOZ_OPTIMIZE_FLAGS"
-     cat > conftest.$ac_ext <<EOF
--#line 13209 "configure"
-+#line 13149 "configure"
- #include "confdefs.h"
- #include <stdio.h>
- int main() {
- printf("Hello World\n");
- ; return 0; }
- EOF
--if { (eval echo configure:13216: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:13156: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   _results=yes
- else
-@@ -13364,7 +13304,7 @@ EOF
-     fi
-   else
-     echo $ac_n "checking size of int *""... $ac_c" 1>&6
--echo "configure:13368: checking size of int *" >&5
-+echo "configure:13308: checking size of int *" >&5
- if eval "test \"`echo '$''{'ac_cv_sizeof_int_p'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -13372,7 +13312,7 @@ else
-   ac_cv_sizeof_int_p=4
- else
-   cat > conftest.$ac_ext <<EOF
--#line 13376 "configure"
-+#line 13316 "configure"
- #include "confdefs.h"
- #include <stdio.h>
- int main()
-@@ -13383,7 +13323,7 @@ int main()
-   return(0);
- }
- EOF
--if { (eval echo configure:13387: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-+if { (eval echo configure:13327: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
- then
-   ac_cv_sizeof_int_p=`cat conftestval`
- else
-@@ -13687,12 +13627,12 @@ fi
- if test -n "$MOZ_VALGRIND"; then
-        ac_safe=`echo "valgrind/valgrind.h" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for valgrind/valgrind.h""... $ac_c" 1>&6
--echo "configure:13691: checking for valgrind/valgrind.h" >&5
-+echo "configure:13631: checking for valgrind/valgrind.h" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 13696 "configure"
-+#line 13636 "configure"
- #include "confdefs.h"
- 
- #include <valgrind/valgrind.h>
-@@ -13700,7 +13640,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:13704: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:13644: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -13973,7 +13913,7 @@ do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
- set dummy $ac_prog; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
--echo "configure:13977: checking for $ac_word" >&5
-+echo "configure:13917: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_CCACHE'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -14099,12 +14039,12 @@ cross_compiling=$ac_cv_prog_cxx_cross
-     for ac_func in __cxa_demangle
- do
- echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
--echo "configure:14103: checking for $ac_func" >&5
-+echo "configure:14043: checking for $ac_func" >&5
- if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 14108 "configure"
-+#line 14048 "configure"
- #include "confdefs.h"
- /* System header to define __stub macros and hopefully few prototypes,
-     which can conflict with char $ac_func(); below.  */
-@@ -14130,7 +14070,7 @@ $ac_func();
- 
- ; return 0; }
- EOF
--if { (eval echo configure:14134: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:14074: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_func_$ac_func=yes"
- else
-@@ -14184,12 +14124,12 @@ fi
- if test -z "$SKIP_LIBRARY_CHECKS"; then
-        ac_safe=`echo "unwind.h" | sed 'y%./+-%__p_%'`
-   echo $ac_n "checking for unwind.h""... $ac_c" 1>&6
--echo "configure:14188: checking for unwind.h" >&5
-+echo "configure:14128: checking for unwind.h" >&5
-   if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-    cat > conftest.$ac_ext <<EOF
--#line 14193 "configure"
-+#line 14133 "configure"
- #include "confdefs.h"
- 
- #include <unwind.h>
-@@ -14197,7 +14137,7 @@ int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:14201: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:14141: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   eval "ac_cv_header_$ac_safe=yes"
- else
-@@ -14214,12 +14154,12 @@ fi
-     for ac_func in _Unwind_Backtrace
- do
- echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
--echo "configure:14218: checking for $ac_func" >&5
-+echo "configure:14158: checking for $ac_func" >&5
- if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 14223 "configure"
-+#line 14163 "configure"
- #include "confdefs.h"
- /* System header to define __stub macros and hopefully few prototypes,
-     which can conflict with char $ac_func(); below.  */
-@@ -14242,7 +14182,7 @@ $ac_func();
- 
- ; return 0; }
- EOF
--if { (eval echo configure:14246: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:14186: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_func_$ac_func=yes"
- else
-@@ -14334,7 +14274,7 @@ if test -z "$SKIP_COMPILER_CHECKS"; then
- # Compiler Options
- 
- echo $ac_n "checking for -pipe support""... $ac_c" 1>&6
--echo "configure:14338: checking for -pipe support" >&5
-+echo "configure:14278: checking for -pipe support" >&5
- if test -n "$GNU_CC" -a -n "$GNU_CXX"; then
-         CFLAGS="$CFLAGS -pipe"
-     CXXFLAGS="$CXXFLAGS -pipe"
-@@ -14348,16 +14288,16 @@ _SAVE_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS -fprofile-generate -fprofile-correction"
- 
- echo $ac_n "checking whether C compiler supports -fprofile-generate""... $ac_c" 1>&6
--echo "configure:14352: checking whether C compiler supports -fprofile-generate" >&5
-+echo "configure:14292: checking whether C compiler supports -fprofile-generate" >&5
- cat > conftest.$ac_ext <<EOF
--#line 14354 "configure"
-+#line 14294 "configure"
- #include "confdefs.h"
- 
- int main() {
- return 0;
- ; return 0; }
- EOF
--if { (eval echo configure:14361: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:14301: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-    PROFILE_GEN_CFLAGS="-fprofile-generate"
-                  result="yes" 
-@@ -14421,16 +14361,16 @@ if test "$_PEDANTIC"; then
-     _SAVE_CXXFLAGS=$CXXFLAGS
-     CXXFLAGS="$CXXFLAGS -pedantic ${_WARNINGS_CXXFLAGS} -Wno-long-long"
-     echo $ac_n "checking whether C++ compiler has -pedantic long long bug""... $ac_c" 1>&6
--echo "configure:14425: checking whether C++ compiler has -pedantic long long bug" >&5
-+echo "configure:14365: checking whether C++ compiler has -pedantic long long bug" >&5
-     cat > conftest.$ac_ext <<EOF
--#line 14427 "configure"
-+#line 14367 "configure"
- #include "confdefs.h"
- $configure_static_assert_macros
- int main() {
- CONFIGURE_STATIC_ASSERT(sizeof(long long) == 8)
- ; return 0; }
- EOF
--if { (eval echo configure:14434: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:14374: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   result="no"
- else
-@@ -14457,12 +14397,12 @@ fi
- _SAVE_CXXFLAGS=$CXXFLAGS
- CXXFLAGS="$CXXFLAGS ${_WARNINGS_CXXFLAGS}"
- echo $ac_n "checking for correct overload resolution with const and templates""... $ac_c" 1>&6
--echo "configure:14461: checking for correct overload resolution with const and templates" >&5
-+echo "configure:14401: checking for correct overload resolution with const and templates" >&5
- if eval "test \"`echo '$''{'ac_nscap_nonconst_opeq_bug'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 14466 "configure"
-+#line 14406 "configure"
- #include "confdefs.h"
- 
-                       template <class T>
-@@ -14492,7 +14432,7 @@ int main() {
-                     
- ; return 0; }
- EOF
--if { (eval echo configure:14496: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:14436: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_nscap_nonconst_opeq_bug="no"
- else
-@@ -14518,19 +14458,19 @@ EOF
- fi
- 
- echo $ac_n "checking for tm_zone tm_gmtoff in struct tm""... $ac_c" 1>&6
--echo "configure:14522: checking for tm_zone tm_gmtoff in struct tm" >&5
-+echo "configure:14462: checking for tm_zone tm_gmtoff in struct tm" >&5
- if eval "test \"`echo '$''{'ac_cv_struct_tm_zone_tm_gmtoff'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 14527 "configure"
-+#line 14467 "configure"
- #include "confdefs.h"
- #include <time.h>
- int main() {
- struct tm tm; tm.tm_zone = 0; tm.tm_gmtoff = 1;
- ; return 0; }
- EOF
--if { (eval echo configure:14534: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:14474: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   rm -rf conftest*
-   ac_cv_struct_tm_zone_tm_gmtoff="yes"
- else
-@@ -14572,18 +14512,18 @@ cross_compiling=$ac_cv_prog_cc_cross
- 
- 
- echo $ac_n "checking what kind of list files are supported by the linker""... $ac_c" 1>&6
--echo "configure:14576: checking what kind of list files are supported by the linker" >&5
-+echo "configure:14516: checking what kind of list files are supported by the linker" >&5
- if eval "test \"`echo '$''{'EXPAND_LIBS_LIST_STYLE'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   echo "int main() {return 0;}" > conftest.${ac_ext}
--     if { ac_try='${CC-cc} -o conftest.${OBJ_SUFFIX} -c $CFLAGS $CPPFLAGS conftest.${ac_ext} 1>&5'; { (eval echo configure:14581: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.${OBJ_SUFFIX}; then
-+     if { ac_try='${CC-cc} -o conftest.${OBJ_SUFFIX} -c $CFLAGS $CPPFLAGS conftest.${ac_ext} 1>&5'; { (eval echo configure:14521: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.${OBJ_SUFFIX}; then
-          echo "INPUT(conftest.${OBJ_SUFFIX})" > conftest.list
--         if { ac_try='${CC-cc} -o conftest${ac_exeext} $LDFLAGS conftest.list $LIBS 1>&5'; { (eval echo configure:14583: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest${ac_exeext}; then
-+         if { ac_try='${CC-cc} -o conftest${ac_exeext} $LDFLAGS conftest.list $LIBS 1>&5'; { (eval echo configure:14523: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest${ac_exeext}; then
-              EXPAND_LIBS_LIST_STYLE=linkerscript
-          else
-              echo "conftest.${OBJ_SUFFIX}" > conftest.list
--             if { ac_try='${CC-cc} -o conftest${ac_exeext} $LDFLAGS @conftest.list $LIBS 1>&5'; { (eval echo configure:14587: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest${ac_exeext}; then
-+             if { ac_try='${CC-cc} -o conftest${ac_exeext} $LDFLAGS @conftest.list $LIBS 1>&5'; { (eval echo configure:14527: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest${ac_exeext}; then
-                  EXPAND_LIBS_LIST_STYLE=list
-              else
-                  EXPAND_LIBS_LIST_STYLE=none
-@@ -14603,7 +14543,7 @@ LIBS_DESC_SUFFIX=desc
- 
- if test "$GCC_USE_GNU_LD"; then
-     echo $ac_n "checking what kind of ordering can be done with the linker""... $ac_c" 1>&6
--echo "configure:14607: checking what kind of ordering can be done with the linker" >&5
-+echo "configure:14547: checking what kind of ordering can be done with the linker" >&5
- if eval "test \"`echo '$''{'EXPAND_LIBS_ORDER_STYLE'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -14611,14 +14551,14 @@ else
-          _SAVE_LDFLAGS="$LDFLAGS"
-          LDFLAGS="${LDFLAGS} -Wl,--section-ordering-file,conftest.order"
-          cat > conftest.$ac_ext <<EOF
--#line 14615 "configure"
-+#line 14555 "configure"
- #include "confdefs.h"
- 
- int main() {
- 
- ; return 0; }
- EOF
--if { (eval echo configure:14622: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:14562: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   EXPAND_LIBS_ORDER_STYLE=section-ordering-file
- else
-@@ -14630,7 +14570,7 @@ fi
- rm -f conftest*
-          LDFLAGS="$_SAVE_LDFLAGS"
-          if test -z "$EXPAND_LIBS_ORDER_STYLE"; then
--             if { ac_try='${CC-cc} ${DSO_LDOPTS} ${LDFLAGS} -o ${DLL_PREFIX}conftest${DLL_SUFFIX} -Wl'; { (eval echo configure:14634: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
-+             if { ac_try='${CC-cc} ${DSO_LDOPTS} ${LDFLAGS} -o ${DLL_PREFIX}conftest${DLL_SUFFIX} -Wl'; { (eval echo configure:14574: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
-                  EXPAND_LIBS_ORDER_STYLE=linkerscript
-              else
-                  EXPAND_LIBS_ORDER_STYLE=none
-@@ -14741,7 +14681,7 @@ esac
- if test -z "$SKIP_LIBRARY_CHECKS" -a -z "$NO_EDITLINE"; then
-   if test -n "$JS_WANT_READLINE"; then
-     echo $ac_n "checking for readline in -lreadline""... $ac_c" 1>&6
--echo "configure:14745: checking for readline in -lreadline" >&5
-+echo "configure:14685: checking for readline in -lreadline" >&5
- ac_lib_var=`echo readline'_'readline | sed 'y%./+-%__p_%'`
- if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
-@@ -14749,7 +14689,7 @@ else
-   ac_save_LIBS="$LIBS"
- LIBS="-lreadline  $LIBS"
- cat > conftest.$ac_ext <<EOF
--#line 14753 "configure"
-+#line 14693 "configure"
- #include "confdefs.h"
- /* Override any gcc2 internal prototype to avoid an error.  */
- /* We use char because int might match the return type of a gcc2
-@@ -14760,7 +14700,7 @@ int main() {
- readline()
- ; return 0; }
- EOF
--if { (eval echo configure:14764: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:14704: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_lib_$ac_lib_var=yes"
- else
-@@ -14990,9 +14930,9 @@ EOF
- 
- 
- echo $ac_n "checking for posix_fallocate""... $ac_c" 1>&6
--echo "configure:14994: checking for posix_fallocate" >&5
-+echo "configure:14934: checking for posix_fallocate" >&5
- cat > conftest.$ac_ext <<EOF
--#line 14996 "configure"
-+#line 14936 "configure"
- #include "confdefs.h"
- #define _XOPEN_SOURCE 600
-   #include <fcntl.h>
-@@ -15000,7 +14940,7 @@ int main() {
- posix_fallocate(0, 0, 0);
- ; return 0; }
- EOF
--if { (eval echo configure:15004: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:14944: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   ac_cv___posix_fallocate=true
- else
-@@ -15029,7 +14969,7 @@ if test "$MOZ_X11"; then
-                 _SAVE_CFLAGS=$CFLAGS
-     CFLAGS="$CFLAGS $XCFLAGS"
-     cat > conftest.$ac_ext <<EOF
--#line 15033 "configure"
-+#line 14973 "configure"
- #include "confdefs.h"
- 
-         #include <stdio.h>
-@@ -15047,7 +14987,7 @@ int main() {
-     
- ; return 0; }
- EOF
--if { (eval echo configure:15051: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:14991: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-   :
- else
-   echo "configure: failed program was:" >&5
-@@ -15162,12 +15102,12 @@ fi
- for ac_func in setlocale
- do
- echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
--echo "configure:15166: checking for $ac_func" >&5
-+echo "configure:15106: checking for $ac_func" >&5
- if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 15171 "configure"
-+#line 15111 "configure"
- #include "confdefs.h"
- /* System header to define __stub macros and hopefully few prototypes,
-     which can conflict with char $ac_func(); below.  */
-@@ -15190,7 +15130,7 @@ $ac_func();
- 
- ; return 0; }
- EOF
--if { (eval echo configure:15194: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:15134: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_func_$ac_func=yes"
- else
-@@ -15220,12 +15160,12 @@ done
- for ac_func in localeconv
- do
- echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
--echo "configure:15224: checking for $ac_func" >&5
-+echo "configure:15164: checking for $ac_func" >&5
- if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.$ac_ext <<EOF
--#line 15229 "configure"
-+#line 15169 "configure"
- #include "confdefs.h"
- /* System header to define __stub macros and hopefully few prototypes,
-     which can conflict with char $ac_func(); below.  */
-@@ -15248,7 +15188,7 @@ $ac_func();
- 
- ; return 0; }
- EOF
--if { (eval echo configure:15252: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:15192: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   rm -rf conftest*
-   eval "ac_cv_func_$ac_func=yes"
- else
--- 
-1.9.3
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0002-Move-JS_BYTES_PER_WORD-out-of-config.h.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0002-Move-JS_BYTES_PER_WORD-out-of-config.h.patch
deleted file mode 100644
index 6aeb2f6..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0002-Move-JS_BYTES_PER_WORD-out-of-config.h.patch
+++ /dev/null
@@ -1,75 +0,0 @@
-From d4a15ad82292ff6d772dcc631df98754d20be31b Mon Sep 17 00:00:00 2001
-From: Colin Walters <walters@verbum.org>
-Date: Tue, 18 Mar 2014 11:46:05 -0400
-Subject: [PATCH 2/5] Move JS_BYTES_PER_WORD out of config.h
-
-Instead define it in terms of the already extant GNU C extension
-__SIZEOF_POINTER__.  This avoids multiarch conflicts when 32 and 64
-bit packages of js are co-installed.
----
-
-Upstream-status: Pending
-
- js/src/configure.in   |  9 ---------
- js/src/js-config.h.in |  1 -
- js/src/jstypes.h      | 12 ++++++++++++
- 3 files changed, 12 insertions(+), 10 deletions(-)
-
-diff --git a/js/src/configure.in b/js/src/configure.in
-index 15605b2..64c7606 100644
---- a/js/src/configure.in
-+++ b/js/src/configure.in
-@@ -2345,15 +2345,6 @@ else
-   AC_MSG_RESULT(no)
- fi
- 
--MOZ_SIZE_OF_TYPE(JS_BYTES_PER_WORD, void*, 4 8)
--if test "$moz_cv_size_of_JS_BYTES_PER_WORD" -eq "4"; then
--  AC_DEFINE(JS_BITS_PER_WORD_LOG2, 5)
--elif test "$moz_cv_size_of_JS_BYTES_PER_WORD" -eq "8"; then
--  AC_DEFINE(JS_BITS_PER_WORD_LOG2, 6)
--else
--  AC_MSG_ERROR([Unexpected JS_BYTES_PER_WORD])
--fi
--
- MOZ_ALIGN_OF_TYPE(JS_ALIGN_OF_POINTER, void*, 2 4 8 16)
- MOZ_SIZE_OF_TYPE(JS_BYTES_PER_DOUBLE, double, 6 8 10 12 14)
- 
-diff --git a/js/src/js-config.h.in b/js/src/js-config.h.in
-index 6889e00..4775420 100644
---- a/js/src/js-config.h.in
-+++ b/js/src/js-config.h.in
-@@ -56,7 +56,6 @@
- #undef JS_INT32_TYPE
- #undef JS_INT64_TYPE
- #undef JS_INTPTR_TYPE
--#undef JS_BYTES_PER_WORD
- 
- /* Some mozilla code uses JS-friend APIs that depend on JS_METHODJIT being
-    correct. */
-diff --git a/js/src/jstypes.h b/js/src/jstypes.h
-index d0cf183..3e7928f 100644
---- a/js/src/jstypes.h
-+++ b/js/src/jstypes.h
-@@ -24,6 +24,18 @@
- #include "mozilla/Util.h"
- 
- #include "js-config.h"
-+#ifndef JS_BYTES_PER_WORD
-+#define JS_BYTES_PER_WORD __SIZEOF_POINTER__
-+#endif
-+#ifndef JS_BITS_PER_WORD_LOG2
-+#if JS_BYTES_PER_WORD == 8
-+#define JS_BITS_PER_WORD_LOG2 6
-+#elif JS_BYTES_PER_WORD == 4
-+#define JS_BITS_PER_WORD_LOG2 5
-+#else
-+#error Unhandled JS_BYTES_PER_WORD
-+#endif 
-+#endif
- 
- /***********************************************************************
- ** MACROS:      JS_EXTERN_API
--- 
-1.9.3
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0002-fix-cannot-find-link.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0002-fix-cannot-find-link.patch
new file mode 100644
index 0000000..4f7ebc6
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0002-fix-cannot-find-link.patch
@@ -0,0 +1,34 @@
+From e6dcee5f8a0f80ce99946b81fa1233611a149fe6 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 12 Jul 2018 18:00:52 +0800
+Subject: [PATCH 2/5] fix cannot find link
+
+..
+|DEBUG: link: Trying 'mips64-wrs-linux-ld --sysroot=tmp-glibc/work/
+mips64-wrs-linux/mozjs/52.8.1-r0/recipe-sysroot '
+|ERROR: Cannot find link
+...
+
+Upstream-Status: Inappropriate [oe specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ build/moz.configure/checks.configure | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/build/moz.configure/checks.configure b/build/moz.configure/checks.configure
+index 8c2dbc0..83bffc3 100644
+--- a/build/moz.configure/checks.configure
++++ b/build/moz.configure/checks.configure
+@@ -128,7 +128,7 @@ def check_prog(var, progs, what=None, input=None, allow_missing=False,
+ 
+         for prog in value or progs:
+             log.debug('%s: Trying %s', var.lower(), quote(prog))
+-            result = find_program(prog, paths)
++            result = find_program(prog.split()[0], paths)
+             if result:
+                 return result
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0003-Add-AArch64-support.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0003-Add-AArch64-support.patch
deleted file mode 100644
index 6e72429..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0003-Add-AArch64-support.patch
+++ /dev/null
@@ -1,76 +0,0 @@
-From 15e710e331d36eb279852b5cd1ba37a9a6005217 Mon Sep 17 00:00:00 2001
-From: Koen Kooi <koen.kooi@linaro.org>
-Date: Mon, 2 Mar 2015 19:08:22 +0800
-Subject: [PATCH 3/5] Add AArch64 support
-
----
-Upstream-status: Pending
-
- js/src/assembler/jit/ExecutableAllocator.h | 6 ++++++
- js/src/assembler/wtf/Platform.h            | 4 ++++
- js/src/configure.in                        | 4 ++++
- mfbt/double-conversion/utils.h             | 1 +
- 4 files changed, 15 insertions(+)
-
-diff --git a/js/src/assembler/jit/ExecutableAllocator.h b/js/src/assembler/jit/ExecutableAllocator.h
-index c071c33..90764c3 100644
---- a/js/src/assembler/jit/ExecutableAllocator.h
-+++ b/js/src/assembler/jit/ExecutableAllocator.h
-@@ -382,6 +382,12 @@ public:
-     {
-         reprotectRegion(start, size, Executable);
-     }
-+#elif WTF_CPU_AARCH64 && WTF_PLATFORM_LINUX
-+    static void cacheFlush(void* code, size_t size)
-+    {
-+        intptr_t end = reinterpret_cast<intptr_t>(code) + size;
-+        __builtin___clear_cache(reinterpret_cast<char*>(code), reinterpret_cast<char*>(end));
-+    }
- #else
-     static void makeWritable(void*, size_t) {}
-     static void makeExecutable(void*, size_t) {}
-diff --git a/js/src/assembler/wtf/Platform.h b/js/src/assembler/wtf/Platform.h
-index 0c84896..e8763a7 100644
---- a/js/src/assembler/wtf/Platform.h
-+++ b/js/src/assembler/wtf/Platform.h
-@@ -325,6 +325,10 @@
- #define WTF_THUMB_ARCH_VERSION 0
- #endif
- 
-+/* CPU(AArch64) - 64-bit ARM */
-+#if defined(__aarch64__)
-+#define WTF_CPU_AARCH64 1
-+#endif
- 
- /* WTF_CPU_ARMV5_OR_LOWER - ARM instruction set v5 or earlier */
- /* On ARMv5 and below the natural alignment is required. 
-diff --git a/js/src/configure.in b/js/src/configure.in
-index 64c7606..0673aca 100644
---- a/js/src/configure.in
-+++ b/js/src/configure.in
-@@ -1121,6 +1121,10 @@ arm*)
-     CPU_ARCH=arm
-     ;;
- 
-+aarch64)
-+    CPU_ARCH=aarch64
-+    ;;
-+
- mips|mipsel)
-     CPU_ARCH="mips"
-     ;;
-diff --git a/mfbt/double-conversion/utils.h b/mfbt/double-conversion/utils.h
-index 0eec2d9..fe26dab 100644
---- a/mfbt/double-conversion/utils.h
-+++ b/mfbt/double-conversion/utils.h
-@@ -58,6 +58,7 @@
-     defined(__mips__) || defined(__powerpc__) || \
-     defined(__sparc__) || defined(__sparc) || defined(__s390__) || \
-     defined(__SH4__) || defined(__alpha__) || \
-+    defined(__aarch64__) || \
-     defined(_MIPS_ARCH_MIPS32R2)
- #define DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS 1
- #elif defined(_M_IX86) || defined(__i386__) || defined(__i386)
--- 
-1.9.3
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0003-workaround-autoconf-2.13-detection-failed.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0003-workaround-autoconf-2.13-detection-failed.patch
new file mode 100644
index 0000000..a754ff1
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0003-workaround-autoconf-2.13-detection-failed.patch
@@ -0,0 +1,28 @@
+From 646a78262b18e19721cd41ee515215221dd241b6 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 12 Jul 2018 18:12:42 +0800
+Subject: [PATCH 3/5] workaround  autoconf 2.13 detection failed
+
+Upstream-Status: Inappropriate [oe specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ build/moz.configure/old.configure | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/build/moz.configure/old.configure b/build/moz.configure/old.configure
+index b32c3f7..ece47f4 100644
+--- a/build/moz.configure/old.configure
++++ b/build/moz.configure/old.configure
+@@ -31,7 +31,7 @@ def autoconf(mozconfig, autoconf):
+     autoconf = autoconf[0] if autoconf else None
+ 
+     for ac in (mozconfig_autoconf, autoconf, 'autoconf-2.13', 'autoconf2.13',
+-               'autoconf213'):
++               'autoconf213', 'autoconf'):
+         if ac:
+             autoconf = find_program(ac)
+             if autoconf:
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0004-do-not-use-autoconf-2.13-to-refresh-old.configure.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0004-do-not-use-autoconf-2.13-to-refresh-old.configure.patch
new file mode 100644
index 0000000..4cba79c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0004-do-not-use-autoconf-2.13-to-refresh-old.configure.patch
@@ -0,0 +1,42 @@
+From a46adb74b5ba5e17d676d31d70faca76c1381d15 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 12 Jul 2018 21:25:46 +0800
+Subject: [PATCH 4/5] do not use autoconf 2.13 to refresh old.configure
+
+Upstream-Status: Inappropriate [oe specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ build/moz.configure/old.configure | 2 +-
+ js/src/old-configure              | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/build/moz.configure/old.configure b/build/moz.configure/old.configure
+index ece47f4..a73900f 100644
+--- a/build/moz.configure/old.configure
++++ b/build/moz.configure/old.configure
+@@ -83,7 +83,7 @@ def prepare_configure(old_configure, mozconfig, autoconf, build_env, shell,
+             old_configure = os.path.join(old_configure_dir, 'js', 'src',
+                                          os.path.basename(old_configure))
+ 
+-    refresh = True
++    refresh = False
+     if exists(old_configure):
+         mtime = getmtime(old_configure)
+         aclocal = os.path.join(build_env.topsrcdir, 'build', 'autoconf',
+diff --git a/js/src/old-configure b/js/src/old-configure
+index 75b00e1..8a8ef52 100644
+--- a/js/src/old-configure
++++ b/js/src/old-configure
+@@ -619,7 +619,7 @@ if test -z "$srcdir"; then
+   ac_prog=$0
+   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
+   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
+-  srcdir=$ac_confdir
++  srcdir="$ac_confdir/../../"
+   if test ! -r $srcdir/$ac_unique_file; then
+     srcdir=..
+   fi
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0004-mozbug746112-no-decommit-on-large-pages.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0004-mozbug746112-no-decommit-on-large-pages.patch
deleted file mode 100644
index 8bd35d4..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0004-mozbug746112-no-decommit-on-large-pages.patch
+++ /dev/null
@@ -1,103 +0,0 @@
-From 0128c5a9eeee0d3fc0deb9129dd20eb79338c8f4 Mon Sep 17 00:00:00 2001
-From: Koen Kooi <koen.kooi@linaro.org>
-Date: Mon, 2 Mar 2015 19:08:59 +0800
-Subject: [PATCH 4/5] mozbug746112-no-decommit-on-large-pages
-
----
-Upstream-status: Pending
-
- js/src/gc/Heap.h | 15 ++++++++++-----
- js/src/jsgc.cpp  | 15 ++++++++++++---
- 2 files changed, 22 insertions(+), 8 deletions(-)
-
-diff --git a/js/src/gc/Heap.h b/js/src/gc/Heap.h
-index b8f8c78..1cfd269 100644
---- a/js/src/gc/Heap.h
-+++ b/js/src/gc/Heap.h
-@@ -103,26 +103,31 @@ struct Cell
- };
- 
- /*
-- * Page size is 4096 by default, except for SPARC, where it is 8192.
-+ * Page size must be static to support our arena pointer optimizations, so we
-+ * are forced to support each platform with non-4096 pages as a special case.
-+ * Note: The freelist supports a maximum arena shift of 15.
-  * Note: Do not use JS_CPU_SPARC here, this header is used outside JS.
-  * Bug 692267: Move page size definition to gc/Memory.h and include it
-  *             directly once jsgc.h is no longer an installed header.
-  */
- #if defined(SOLARIS) && (defined(__sparc) || defined(__sparcv9))
- const size_t PageShift = 13;
-+const size_t ArenaShift = PageShift;
-+#elif defined(__powerpc__)
-+const size_t PageShift = 16;
-+const size_t ArenaShift = 12;
- #else
- const size_t PageShift = 12;
-+const size_t ArenaShift = PageShift;
- #endif
- const size_t PageSize = size_t(1) << PageShift;
-+const size_t ArenaSize = size_t(1) << ArenaShift;
-+const size_t ArenaMask = ArenaSize - 1;
- 
- const size_t ChunkShift = 20;
- const size_t ChunkSize = size_t(1) << ChunkShift;
- const size_t ChunkMask = ChunkSize - 1;
- 
--const size_t ArenaShift = PageShift;
--const size_t ArenaSize = PageSize;
--const size_t ArenaMask = ArenaSize - 1;
--
- /*
-  * This is the maximum number of arenas we allow in the FreeCommitted state
-  * before we trigger a GC_SHRINK to release free arenas to the OS.
-diff --git a/js/src/jsgc.cpp b/js/src/jsgc.cpp
-index b3caf05..a258d2d 100644
---- a/js/src/jsgc.cpp
-+++ b/js/src/jsgc.cpp
-@@ -251,6 +251,13 @@ static const int BackgroundPhaseLength[] = {
-     sizeof(BackgroundPhaseStrings) / sizeof(AllocKind)
- };
- 
-+/* Unused memory decommiting requires the arena size match the page size. */
-+static bool
-+DecommitEnabled()
-+{
-+    return PageSize == ArenaSize;
-+}
-+
- #ifdef DEBUG
- void
- ArenaHeader::checkSynchronizedWithFreeList() const
-@@ -742,7 +749,8 @@ Chunk::fetchNextDecommittedArena()
-     decommittedArenas.unset(offset);
- 
-     Arena *arena = &arenas[offset];
--    MarkPagesInUse(arena, ArenaSize);
-+    if (DecommitEnabled())
-+        MarkPagesInUse(arena, ArenaSize);
-     arena->aheader.setAsNotAllocated();
- 
-     return &arena->aheader;
-@@ -2731,7 +2739,7 @@ DecommitArenasFromAvailableList(JSRuntime *rt, Chunk **availableListHeadp)
-                 chunk->removeFromAvailableList();
- 
-             size_t arenaIndex = Chunk::arenaIndex(aheader->arenaAddress());
--            bool ok;
-+            bool ok = true;
-             {
-                 /*
-                  * If the main thread waits for the decommit to finish, skip
-@@ -2741,7 +2749,8 @@ DecommitArenasFromAvailableList(JSRuntime *rt, Chunk **availableListHeadp)
-                 Maybe<AutoUnlockGC> maybeUnlock;
-                 if (!rt->isHeapBusy())
-                     maybeUnlock.construct(rt);
--                ok = MarkPagesUnused(aheader->getArena(), ArenaSize);
-+                if (DecommitEnabled())
-+                    ok = MarkPagesUnused(aheader->getArena(), ArenaSize);
-             }
- 
-             if (ok) {
--- 
-1.9.3
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0005-aarch64-64k-page.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0005-aarch64-64k-page.patch
deleted file mode 100644
index bc99ecc..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0005-aarch64-64k-page.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From 9c42920c2b635a399bd1f93833efdeb1696f17ee Mon Sep 17 00:00:00 2001
-From: Koen Kooi <koen.kooi@linaro.org>
-Date: Mon, 2 Mar 2015 19:09:57 +0800
-Subject: [PATCH 5/5] aarch64-64k-page
-
----
-Upstream-status: Pending
-
- js/src/gc/Heap.h     | 2 +-
- js/src/gc/Memory.cpp | 3 +++
- 2 files changed, 4 insertions(+), 1 deletion(-)
-
-diff --git a/js/src/gc/Heap.h b/js/src/gc/Heap.h
-index 1cfd269..f4dbcda 100644
---- a/js/src/gc/Heap.h
-+++ b/js/src/gc/Heap.h
-@@ -113,7 +113,7 @@ struct Cell
- #if defined(SOLARIS) && (defined(__sparc) || defined(__sparcv9))
- const size_t PageShift = 13;
- const size_t ArenaShift = PageShift;
--#elif defined(__powerpc__)
-+#elif defined(__powerpc__) || defined(__aarch64__)
- const size_t PageShift = 16;
- const size_t ArenaShift = 12;
- #else
-diff --git a/js/src/gc/Memory.cpp b/js/src/gc/Memory.cpp
-index 5b386a2..e5ad018 100644
---- a/js/src/gc/Memory.cpp
-+++ b/js/src/gc/Memory.cpp
-@@ -302,8 +302,11 @@ GetPageFaultCount()
- void
- InitMemorySubsystem()
- {
-+    /* aarch64 may have 64KB or 4KB pages */
-+#ifndef __aarch64__
-     if (size_t(sysconf(_SC_PAGESIZE)) != PageSize)
-         MOZ_CRASH();
-+#endif
- }
- 
- void *
--- 
-1.9.3
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0005-fix-do_compile-failed-on-mips.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0005-fix-do_compile-failed-on-mips.patch
new file mode 100644
index 0000000..38e4698
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0005-fix-do_compile-failed-on-mips.patch
@@ -0,0 +1,38 @@
+From 55d833dc3c194f1eb7841f308ad3b9ec3800d3b3 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Fri, 13 Jul 2018 15:48:32 +0800
+Subject: [PATCH 5/5] fix do_compile failed on mips
+
+Link with var-OS_LDFLAGS to fix the issue.
+Such as on mips:
+...
+|mips-wrsmllib32-linux-g++ -meb -mabi=32 -mhard-float ... -o libmozjs-52.so
+|/usr/include/c++/8.1.0/bits/atomic_base.h:514: error: undefined
+reference to '__atomic_fetch_add_8'
+...
+
+In recipe, set OS_LDFLAGS="-Wl,-latomic" could fix the issue.
+
+Upstream-Status: Inappropriate [oe specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ config/config.mk | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/config/config.mk b/config/config.mk
+index 4e3fd1a..d847ffa 100644
+--- a/config/config.mk
++++ b/config/config.mk
+@@ -523,7 +523,7 @@ EXPAND_MKSHLIB_ARGS = --uselist
+ ifdef SYMBOL_ORDER
+ EXPAND_MKSHLIB_ARGS += --symbol-order $(SYMBOL_ORDER)
+ endif
+-EXPAND_MKSHLIB = $(EXPAND_LIBS_EXEC) $(EXPAND_MKSHLIB_ARGS) -- $(MKSHLIB)
++EXPAND_MKSHLIB = $(EXPAND_LIBS_EXEC) $(EXPAND_MKSHLIB_ARGS) -- $(MKSHLIB) $(OS_LDFLAGS)
+ 
+ # $(call CHECK_SYMBOLS,lib,PREFIX,dep_name,test)
+ # Checks that the given `lib` doesn't contain dependency on symbols with a
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0006-support-musl.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0006-support-musl.patch
new file mode 100644
index 0000000..32a977c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0006-support-musl.patch
@@ -0,0 +1,158 @@
+From 04e8a611e958f0da1ccac61acae3a6f1a5168b20 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Fri, 13 Jul 2018 18:08:14 +0800
+Subject: [PATCH] support musl
+
+Upstream-Status: Pending
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ memory/jemalloc/src/src/pages.c              | 1 -
+ memory/mozjemalloc/jemalloc.c                | 7 +++----
+ mozglue/misc/TimeStamp_darwin.cpp            | 1 -
+ mozglue/misc/TimeStamp_posix.cpp             | 1 -
+ nsprpub/pr/src/misc/prsystem.c               | 1 -
+ python/psutil/psutil/_psutil_bsd.c           | 1 -
+ python/psutil/psutil/_psutil_osx.c           | 1 -
+ python/psutil/psutil/arch/bsd/process_info.c | 1 -
+ python/psutil/psutil/arch/osx/process_info.c | 1 -
+ 9 files changed, 3 insertions(+), 12 deletions(-)
+
+diff --git a/memory/jemalloc/src/src/pages.c b/memory/jemalloc/src/src/pages.c
+index 647952a..7b964c8 100644
+--- a/memory/jemalloc/src/src/pages.c
++++ b/memory/jemalloc/src/src/pages.c
+@@ -2,7 +2,6 @@
+ #include "jemalloc/internal/jemalloc_internal.h"
+ 
+ #ifdef JEMALLOC_SYSCTL_VM_OVERCOMMIT
+-#include <sys/sysctl.h>
+ #endif
+ 
+ /******************************************************************************/
+diff --git a/memory/mozjemalloc/jemalloc.c b/memory/mozjemalloc/jemalloc.c
+index 5d4d83a..c618de9 100644
+--- a/memory/mozjemalloc/jemalloc.c
++++ b/memory/mozjemalloc/jemalloc.c
+@@ -332,7 +332,6 @@ __FBSDID("$FreeBSD: head/lib/libc/stdlib/malloc.c 180599 2008-07-18 19:35:44Z ja
+ #include <sys/time.h>
+ #include <sys/types.h>
+ #if !defined(MOZ_MEMORY_SOLARIS) && !defined(MOZ_MEMORY_ANDROID)
+-#include <sys/sysctl.h>
+ #endif
+ #include <sys/uio.h>
+ #ifndef MOZ_MEMORY
+@@ -674,7 +673,7 @@ static bool malloc_initialized = false;
+ #elif defined(MOZ_MEMORY_DARWIN)
+ static malloc_mutex_t init_lock = {OS_SPINLOCK_INIT};
+ #elif defined(MOZ_MEMORY_LINUX) && !defined(MOZ_MEMORY_ANDROID)
+-static malloc_mutex_t init_lock = PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP;
++static malloc_mutex_t init_lock = PTHREAD_MUTEX_INITIALIZER;
+ #elif defined(MOZ_MEMORY)
+ static malloc_mutex_t init_lock = PTHREAD_MUTEX_INITIALIZER;
+ #else
+@@ -1644,7 +1643,7 @@ malloc_mutex_init(malloc_mutex_t *mutex)
+ 	pthread_mutexattr_t attr;
+ 	if (pthread_mutexattr_init(&attr) != 0)
+ 		return (true);
+-	pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_ADAPTIVE_NP);
++	pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_STALLED);
+ 	if (pthread_mutex_init(mutex, &attr) != 0) {
+ 		pthread_mutexattr_destroy(&attr);
+ 		return (true);
+@@ -1709,7 +1708,7 @@ malloc_spin_init(malloc_spinlock_t *lock)
+ 	pthread_mutexattr_t attr;
+ 	if (pthread_mutexattr_init(&attr) != 0)
+ 		return (true);
+-	pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_ADAPTIVE_NP);
++	pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_STALLED);
+ 	if (pthread_mutex_init(lock, &attr) != 0) {
+ 		pthread_mutexattr_destroy(&attr);
+ 		return (true);
+diff --git a/mozglue/misc/TimeStamp_darwin.cpp b/mozglue/misc/TimeStamp_darwin.cpp
+index f30bc98..3998c9c 100644
+--- a/mozglue/misc/TimeStamp_darwin.cpp
++++ b/mozglue/misc/TimeStamp_darwin.cpp
+@@ -18,7 +18,6 @@
+ 
+ #include <mach/mach_time.h>
+ #include <sys/time.h>
+-#include <sys/sysctl.h>
+ #include <time.h>
+ #include <unistd.h>
+ 
+diff --git a/mozglue/misc/TimeStamp_posix.cpp b/mozglue/misc/TimeStamp_posix.cpp
+index 05dedde..d9e30f2 100644
+--- a/mozglue/misc/TimeStamp_posix.cpp
++++ b/mozglue/misc/TimeStamp_posix.cpp
+@@ -21,7 +21,6 @@
+ #if defined(__DragonFly__) || defined(__FreeBSD__) \
+     || defined(__NetBSD__) || defined(__OpenBSD__)
+ #include <sys/param.h>
+-#include <sys/sysctl.h>
+ #endif
+ 
+ #if defined(__DragonFly__) || defined(__FreeBSD__)
+diff --git a/nsprpub/pr/src/misc/prsystem.c b/nsprpub/pr/src/misc/prsystem.c
+index eba85fb..54b57bb 100644
+--- a/nsprpub/pr/src/misc/prsystem.c
++++ b/nsprpub/pr/src/misc/prsystem.c
+@@ -27,7 +27,6 @@
+     || defined(OPENBSD) || defined(DRAGONFLY) || defined(DARWIN)
+ #define _PR_HAVE_SYSCTL
+ #include <sys/param.h>
+-#include <sys/sysctl.h>
+ #endif
+ 
+ #if defined(DARWIN)
+diff --git a/python/psutil/psutil/_psutil_bsd.c b/python/psutil/psutil/_psutil_bsd.c
+index 7b6e561..0a91262 100644
+--- a/python/psutil/psutil/_psutil_bsd.c
++++ b/python/psutil/psutil/_psutil_bsd.c
+@@ -16,7 +16,6 @@
+ #include <fcntl.h>
+ #include <paths.h>
+ #include <sys/types.h>
+-#include <sys/sysctl.h>
+ #include <sys/param.h>
+ #include <sys/user.h>
+ #include <sys/proc.h>
+diff --git a/python/psutil/psutil/_psutil_osx.c b/python/psutil/psutil/_psutil_osx.c
+index 3ebf8ff..b3910ba 100644
+--- a/python/psutil/psutil/_psutil_osx.c
++++ b/python/psutil/psutil/_psutil_osx.c
+@@ -13,7 +13,6 @@
+ #include <stdlib.h>
+ #include <stdio.h>
+ #include <utmpx.h>
+-#include <sys/sysctl.h>
+ #include <sys/vmmeter.h>
+ #include <libproc.h>
+ #include <sys/proc_info.h>
+diff --git a/python/psutil/psutil/arch/bsd/process_info.c b/python/psutil/psutil/arch/bsd/process_info.c
+index 4d73924..46f288d 100644
+--- a/python/psutil/psutil/arch/bsd/process_info.c
++++ b/python/psutil/psutil/arch/bsd/process_info.c
+@@ -15,7 +15,6 @@
+ #include <stdio.h>
+ #include <string.h>
+ #include <sys/types.h>
+-#include <sys/sysctl.h>
+ #include <sys/param.h>
+ #include <sys/user.h>
+ #include <sys/proc.h>
+diff --git a/python/psutil/psutil/arch/osx/process_info.c b/python/psutil/psutil/arch/osx/process_info.c
+index b6dd5bb..62a838f 100644
+--- a/python/psutil/psutil/arch/osx/process_info.c
++++ b/python/psutil/psutil/arch/osx/process_info.c
+@@ -16,7 +16,6 @@
+ #include <stdlib.h>
+ #include <stdio.h>
+ #include <signal.h>
+-#include <sys/sysctl.h>
+ #include <libproc.h>
+ 
+ #include "process_info.h"
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0010-fix-cross-compilation-on-i586-targets.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0010-fix-cross-compilation-on-i586-targets.patch
index 6432e1f..9194e34 100644
--- a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0010-fix-cross-compilation-on-i586-targets.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/0010-fix-cross-compilation-on-i586-targets.patch
@@ -1,4 +1,4 @@
-From a452138a1dd274bfad381a701729783360dc86fb Mon Sep 17 00:00:00 2001
+From a452138a1dd274bfad381a701729783360dc86fb Mon Sep 17  00:00:00 2001
 From: Maciej Borzecki <maciej.borzecki@open-rnd.pl>
 Date: Tue, 5 Jan 2016 22:04:17 +0100
 Subject: [PATCH] fix cross compilation on i586 targets
@@ -10,37 +10,26 @@
 Upstream-Status: Inappropriate [embedded specific]
 
 Signed-off-by: Maciej Borzecki <maciej.borzecki@open-rnd.pl>
----
- js/src/configure    | 2 +-
- js/src/configure.in | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
 
-diff --git a/js/src/configure b/js/src/configure
-index d019b0fdba44233596541de94307010d85a8e32e..5aa40f757a3dbb7d6887175046f44212c15c2eac 100755
---- a/js/src/configure
-+++ b/js/src/configure
-@@ -5555,7 +5555,7 @@ TARGET_MD_ARCH=unix
+Rebase to 52.8.1
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ js/src/old-configure | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/js/src/old-configure b/js/src/old-configure
+index 8a8ef52..d7afcff 100644
+--- a/js/src/old-configure
++++ b/js/src/old-configure
+@@ -3964,7 +3964,7 @@ IMPORT_LIB_SUFFIX=
  DIRENT_INO=d_ino
  MOZ_USER_DIR=".mozilla"
  
--MOZ_FIX_LINK_PATHS='-Wl,-rpath-link,$(LIBXUL_DIST)/bin -Wl,-rpath-link,$(prefix)/lib'
-+MOZ_FIX_LINK_PATHS='-Wl,-rpath-link,$(LIBXUL_DIST)/bin'
+-MOZ_FIX_LINK_PATHS="-Wl,-rpath-link,${DIST}/bin -Wl,-rpath-link,${prefix}/lib"
++MOZ_FIX_LINK_PATHS="-Wl,-rpath-link,${DIST}/bin"
  
- MOZ_COMPONENT_NSPR_LIBS='-L$(LIBXUL_DIST)/bin $(NSPR_LIBS)'
  
-diff --git a/js/src/configure.in b/js/src/configure.in
-index 0673aca12f6d83035549ade2a4a83906bf91f0f0..39b22724f9535ac1a6dba04658c91e4ef667fc47 100644
---- a/js/src/configure.in
-+++ b/js/src/configure.in
-@@ -919,7 +919,7 @@ TARGET_MD_ARCH=unix
- DIRENT_INO=d_ino
- MOZ_USER_DIR=".mozilla"
- 
--MOZ_FIX_LINK_PATHS='-Wl,-rpath-link,$(LIBXUL_DIST)/bin -Wl,-rpath-link,$(prefix)/lib'
-+MOZ_FIX_LINK_PATHS='-Wl,-rpath-link,$(LIBXUL_DIST)/bin'
- 
- MOZ_COMPONENT_NSPR_LIBS='-L$(LIBXUL_DIST)/bin $(NSPR_LIBS)'
  
 -- 
-2.5.0
+2.7.4
 
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/Manually_mmap_heap_memory_esr17.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/Manually_mmap_heap_memory_esr17.patch
deleted file mode 100644
index 83f4543..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/Manually_mmap_heap_memory_esr17.patch
+++ /dev/null
@@ -1,112 +0,0 @@
-From 1d1fa95c8ff7697e46343385a79a8f7e5c514a87 Mon Sep 17 00:00:00 2001
-From: Zheng Xu <zheng.xu@linaro.org>
-Date: Fri, 2 Sep 2016 17:40:05 +0800
-Subject: [PATCH] Bug 1143022 - Manually mmap on arm64 to ensure high 17 bits
- are clear. r=ehoogeveen
-
-There might be 48-bit VA on arm64 depending on kernel configuration.
-Manually mmap heap memory to align with the assumption made by JS engine.
-
-Change-Id: Ic5d2b2fe4b758b3c87cc0688348af7e71a991146
-
-Upstream-status: Backport
-
----
- js/src/gc/Memory.cpp | 73 ++++++++++++++++++++++++++++++++++++++++++++++++++--
- 1 file changed, 71 insertions(+), 2 deletions(-)
-
-diff --git a/js/src/gc/Memory.cpp b/js/src/gc/Memory.cpp
-index e5ad018..4149adf 100644
---- a/js/src/gc/Memory.cpp
-+++ b/js/src/gc/Memory.cpp
-@@ -309,6 +309,75 @@ InitMemorySubsystem()
- #endif
- }
- 
-+static inline void *
-+MapMemory(size_t length, int prot, int flags, int fd, off_t offset)
-+{
-+#if defined(__ia64__)
-+    /*
-+     * The JS engine assumes that all allocated pointers have their high 17 bits clear,
-+     * which ia64's mmap doesn't support directly. However, we can emulate it by passing
-+     * mmap an "addr" parameter with those bits clear. The mmap will return that address,
-+     * or the nearest available memory above that address, providing a near-guarantee
-+     * that those bits are clear. If they are not, we return NULL below to indicate
-+     * out-of-memory.
-+     *
-+     * The addr is chosen as 0x0000070000000000, which still allows about 120TB of virtual
-+     * address space.
-+     *
-+     * See Bug 589735 for more information.
-+     */
-+    void *region = mmap((void*)0x0000070000000000, length, prot, flags, fd, offset);
-+    if (region == MAP_FAILED)
-+        return MAP_FAILED;
-+    /*
-+     * If the allocated memory doesn't have its upper 17 bits clear, consider it
-+     * as out of memory.
-+     */
-+    if ((uintptr_t(region) + (length - 1)) & 0xffff800000000000) {
-+        JS_ALWAYS_TRUE(0 == munmap(region, length));
-+        return MAP_FAILED;
-+    }
-+    return region;
-+#elif defined(__aarch64__)
-+   /*
-+    * There might be similar virtual address issue on arm64 which depends on
-+    * hardware and kernel configurations. But the work around is slightly
-+    * different due to the different mmap behavior.
-+    *
-+    * TODO: Merge with the above code block if this implementation works for
-+    * ia64 and sparc64.
-+    */
-+    const uintptr_t start = UINT64_C(0x0000070000000000);
-+    const uintptr_t end   = UINT64_C(0x0000800000000000);
-+    const uintptr_t step  = ChunkSize;
-+   /*
-+    * Optimization options if there are too many retries in practice:
-+    * 1. Examine /proc/self/maps to find an available address. This file is
-+    *    not always available, however. In addition, even if we examine
-+    *    /proc/self/maps, we may still need to retry several times due to
-+    *    racing with other threads.
-+    * 2. Use a global/static variable with lock to track the addresses we have
-+    *    allocated or tried.
-+    */
-+    uintptr_t hint;
-+    void* region = MAP_FAILED;
-+    for (hint = start; region == MAP_FAILED && hint + length <= end; hint += step) {
-+        region = mmap((void*)hint, length, prot, flags, fd, offset);
-+        if (region != MAP_FAILED) {
-+            if ((uintptr_t(region) + (length - 1)) & 0xffff800000000000) {
-+                if (munmap(region, length)) {
-+                    MOZ_ASSERT(errno == ENOMEM);
-+                }
-+                region = MAP_FAILED;
-+            }
-+        }
-+    }
-+    return region == MAP_FAILED ? NULL : region;
-+#else
-+    return mmap(NULL, length, prot, flags, fd, offset);
-+#endif
-+}
-+
- void *
- MapAlignedPages(size_t size, size_t alignment)
- {
-@@ -322,12 +391,12 @@ MapAlignedPages(size_t size, size_t alignment)
- 
-     /* Special case: If we want page alignment, no further work is needed. */
-     if (alignment == PageSize) {
--        return mmap(NULL, size, prot, flags, -1, 0);
-+        return MapMemory(size, prot, flags, -1, 0);
-     }
- 
-     /* Overallocate and unmap the region's edges. */
-     size_t reqSize = Min(size + 2 * alignment, 2 * size);
--    void *region = mmap(NULL, reqSize, prot, flags, -1, 0);
-+    void *region = MapMemory(reqSize, prot, flags, -1, 0);
-     if (region == MAP_FAILED)
-         return NULL;
- 
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/add-riscv-support.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/add-riscv-support.patch
new file mode 100644
index 0000000..4354a9d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/add-riscv-support.patch
@@ -0,0 +1,70 @@
+Add RISC-V support
+
+Upstream-Status: Submitted [https://bugzilla.mozilla.org/show_bug.cgi?id=1318905]
+
+Signed-off-by: Ricardo Salveti <ricardo@foundries.io>
+
+diff --git a/build/autoconf/config.guess b/build/autoconf/config.guess
+index d5d667d..1277a86 100755
+--- a/build/autoconf/config.guess
++++ b/build/autoconf/config.guess
+@@ -1029,6 +1029,9 @@ EOF
+     ppcle:Linux:*:*)
+ 	echo powerpcle-unknown-linux-${LIBC}
+ 	exit ;;
++    riscv32:Linux:*:* | riscv64:Linux:*:*)
++	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
++	exit ;;
+     s390:Linux:*:* | s390x:Linux:*:*)
+ 	echo ${UNAME_MACHINE}-ibm-linux-${LIBC}
+ 	exit ;;
+diff --git a/build/moz.configure/init.configure b/build/moz.configure/init.configure
+index 6fe6591..56e6730 100644
+--- a/build/moz.configure/init.configure
++++ b/build/moz.configure/init.configure
+@@ -362,6 +362,9 @@ def split_triplet(triplet):
+     elif cpu.startswith('aarch64'):
+         canonical_cpu = 'aarch64'
+         endianness = 'little'
++    elif cpu in ('riscv32', 'riscv64'):
++        canonical_cpu = cpu
++        endianness = 'little'
+     else:
+         die('Unknown CPU type: %s' % cpu)
+ 
+diff --git a/mfbt/double-conversion/utils.h b/mfbt/double-conversion/utils.h
+index 15dd4bf..4f37218 100644
+--- a/mfbt/double-conversion/utils.h
++++ b/mfbt/double-conversion/utils.h
+@@ -60,7 +60,8 @@
+     defined(__sparc__) || defined(__sparc) || defined(__s390__) || \
+     defined(__SH4__) || defined(__alpha__) || \
+     defined(_MIPS_ARCH_MIPS32R2) || \
+-    defined(__AARCH64EL__) || defined(__aarch64__)
++    defined(__AARCH64EL__) || defined(__aarch64__) || \
++    defined(__riscv)
+ #define DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS 1
+ #elif defined(_M_IX86) || defined(__i386__) || defined(__i386)
+ #if defined(_WIN32)
+diff --git a/python/mozbuild/mozbuild/configure/constants.py b/python/mozbuild/mozbuild/configure/constants.py
+index dfc7cf8..4f8d666 100644
+--- a/python/mozbuild/mozbuild/configure/constants.py
++++ b/python/mozbuild/mozbuild/configure/constants.py
+@@ -48,6 +48,8 @@ CPU_bitness = {
+     'mips64': 64,
+     'ppc': 32,
+     'ppc64': 64,
++    'riscv32': 32,
++    'riscv64': 64,
+     's390': 32,
+     's390x': 64,
+     'sparc': 32,
+@@ -79,6 +81,8 @@ CPU_preprocessor_checks = OrderedDict((
+     ('s390', '__s390__'),
+     ('ppc64', '__powerpc64__'),
+     ('ppc', '__powerpc__'),
++    ('riscv32', '__riscv && __SIZEOF_POINTER__ == 4'),
++    ('riscv64', '__riscv && __SIZEOF_POINTER__ == 8'),
+     ('Alpha', '__alpha__'),
+     ('hppa', '__hppa__'),
+     ('sparc64', '__sparc__ && __arch64__'),
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/disable-mozglue-in-stand-alone-builds.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/disable-mozglue-in-stand-alone-builds.patch
new file mode 100644
index 0000000..5487cdb
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/disable-mozglue-in-stand-alone-builds.patch
@@ -0,0 +1,74 @@
+From 2fb531ac753500314336ccd508cb2d53f5e768e5 Mon Sep 17 00:00:00 2001
+From: Till Schneidereit <till@tillschneidereit.net>
+Date: Thu, 1 Oct 2015 12:59:09 +0200
+Subject: Disable MOZ_GLUE_IN_PROGRAM in stand-alone builds on all platforms
+
+Otherwise, build fails not being able to find HashBytes.
+
+Patch ported forward to mozjs52 by Philip Chimento
+<philip.chimento@gmail.com>.
+
+https://bugzilla.mozilla.org/show_bug.cgi?id=1176787
+
+Upstream-Status: Backport
+
+Signed-off-by: Ricardo Salveti <ricardo@foundries.io>
+---
+ js/src/old-configure    | 20 ++++++++++++--------
+ mozglue/build/moz.build |  2 +-
+ 2 files changed, 13 insertions(+), 9 deletions(-)
+
+diff --git a/js/src/old-configure b/js/src/old-configure
+index d7afcff..8a6f142 100644
+--- a/js/src/old-configure
++++ b/js/src/old-configure
+@@ -8546,21 +8546,25 @@ if test -z "$MOZ_ENABLE_WARNINGS_AS_ERRORS"; then
+ fi
+ 
+ 
+-case "${OS_TARGET}" in
+-Android|WINNT|Darwin)
++if test "$JS_STANDALONE"; then
+   MOZ_GLUE_IN_PROGRAM=
+-  ;;
+-*)
+-    MOZ_GLUE_IN_PROGRAM=1
+-  cat >> confdefs.pytmp <<\EOF
++else
++  case "${OS_TARGET}" in
++  Android|WINNT|Darwin)
++    MOZ_GLUE_IN_PROGRAM=
++    ;;
++  *)
++        MOZ_GLUE_IN_PROGRAM=1
++    cat >> confdefs.pytmp <<\EOF
+     (''' MOZ_GLUE_IN_PROGRAM ''', ' 1 ')
+ EOF
+ cat >> confdefs.h <<\EOF
+ #define MOZ_GLUE_IN_PROGRAM 1
+ EOF
+ 
+-  ;;
+-esac
++    ;;
++  esac
++fi
+ 
+ if test "$MOZ_MEMORY"; then
+   if test "x$MOZ_DEBUG" = "x1"; then
+diff --git a/mozglue/build/moz.build b/mozglue/build/moz.build
+index d289747..e3be5a2 100644
+--- a/mozglue/build/moz.build
++++ b/mozglue/build/moz.build
+@@ -6,7 +6,7 @@
+ 
+ # Build mozglue as a shared lib on Windows, OSX and Android.
+ # If this is ever changed, update MOZ_SHARED_MOZGLUE in browser/installer/Makefile.in
+-if CONFIG['OS_TARGET'] in ('WINNT', 'Darwin', 'Android'):
++if CONFIG['OS_TARGET'] in ('WINNT', 'Darwin', 'Android') and not CONFIG['JS_STANDALONE']:
+     SharedLibrary('mozglue')
+ else:
+     Library('mozglue')
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/fix-the-compile-error-of-powerpc64.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/fix-the-compile-error-of-powerpc64.patch
deleted file mode 100644
index 43c4590..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/fix-the-compile-error-of-powerpc64.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-fix the compile error of powerpc64
- 
-Upstream-status: Accepted
-
- fix the following error
- |error: 'jsuword' does not name a type
-
-
---- a/js/src/jsval.hold	2015-04-24 01:15:06.692970731 -0500
-+++ b/js/src/jsval.h	2015-04-24 01:15:41.792969478 -0500
-@@ -304,7 +304,6 @@
-             int32_t        i32;
-             uint32_t       u32;
-             JSWhyMagic     why;
--            jsuword        word;
-         } payload;
-     } s;
-     double asDouble;
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/fix_milestone_compile_issue.patch b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/fix_milestone_compile_issue.patch
deleted file mode 100644
index abde01b..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs/fix_milestone_compile_issue.patch
+++ /dev/null
@@ -1,20 +0,0 @@
-fix the compile error do to perl update
-
-Upstream-status: Inappropriate
-
-
-Signed-of-by: Armin Kuster <akuster808@gmail.com>
-
-Index: src/config/milestone.pl
-===================================================================
---- src.orig/config/milestone.pl
-+++ src/config/milestone.pl
-@@ -55,7 +55,7 @@ $MILESTONE_FILE  = "$TOPSRCDIR/config/mi
- #
- my $milestone = Moz::Milestone::getOfficialMilestone($MILESTONE_FILE);
- 
--if (defined(@TEMPLATE_FILE)) {
-+if (@TEMPLATE_FILE) {
-   my $TFILE;
- 
-   foreach $TFILE (@TEMPLATE_FILE) {
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs_17.0.0.bb b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs_17.0.0.bb
deleted file mode 100644
index 49b7f15..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs_17.0.0.bb
+++ /dev/null
@@ -1,82 +0,0 @@
-SUMMARY = "SpiderMonkey is Mozilla's JavaScript engine written in C/C++"
-HOMEPAGE = "http://www.mozilla.org/js/"
-LICENSE = "MPL-2.0"
-LIC_FILES_CHKSUM = "file://../../LICENSE;md5=815ca599c9df247a0c7f619bab123dad"
-
-SRC_URI = "http://ftp.mozilla.org/pub/mozilla.org/js/${BPN}${PV}.tar.gz \
-           file://0001-mozjs17.0.0-fix-the-compile-bug-of-powerpc.patch \
-           file://0001-js.pc.in-do-not-include-RequiredDefines.h-for-depend.patch \
-           file://0002-Move-JS_BYTES_PER_WORD-out-of-config.h.patch;patchdir=../../ \
-           file://0003-Add-AArch64-support.patch;patchdir=../../ \
-           file://0004-mozbug746112-no-decommit-on-large-pages.patch;patchdir=../../ \
-           file://0005-aarch64-64k-page.patch;patchdir=../../ \
-           file://0001-regenerate-configure.patch;patchdir=../../ \
-           file://fix-the-compile-error-of-powerpc64.patch;patchdir=../../ \
-           file://fix_milestone_compile_issue.patch \
-           file://0010-fix-cross-compilation-on-i586-targets.patch;patchdir=../../ \
-           file://Manually_mmap_heap_memory_esr17.patch;patchdir=../../ \
-           file://0001-compare-the-first-character-of-string-to-be-null-or-.patch;patchdir=../../ \
-           "
-
-SRC_URI[md5sum] = "20b6f8f1140ef6e47daa3b16965c9202"
-SRC_URI[sha256sum] = "321e964fe9386785d3bf80870640f2fa1c683e32fe988eeb201b04471c172fba"
-
-S = "${WORKDIR}/${BPN}${PV}/js/src"
-
-inherit autotools pkgconfig perlnative pythonnative
-
-DEPENDS += "nspr zlib"
-
-# Host specific flags need to be defined, otherwise target flags will be passed to the host
-export HOST_CFLAGS = "${BUILD_CFLAGS}"
-export HOST_CXXFLAGS = "${BUILD_CXXFLAGS}"
-export HOST_LDFLAGS = "${BUILD_LDFLAGS}"
-
-# nspr's package-config is ignored so set libs manually
-EXTRA_OECONF = " \
-    --target=${TARGET_SYS} \
-    --host=${BUILD_SYS} \
-    --build=${BUILD_SYS} \
-    --prefix=${prefix} \
-    --libdir=${libdir} \
-    --with-nspr-libs='-lplds4 -lplc4 -lnspr4' \
-    --enable-threadsafe \
-    --disable-static \
-"
-EXTRA_OECONF_append_armv4 = " \
-    --disable-methodjit \
-"
-
-PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}"
-PACKAGECONFIG[x11] = "--with-x --x-includes=${STAGING_INCDIR} --x-libraries=${STAGING_LIBDIR},--without-x,virtual/libx11"
-
-# mozjs requires autoreconf 2.13
-do_configure() {
-    export HOST_CFLAGS="${BUILD_CFLAGS}"
-    export HOST_CXXFLAGS="${BUILD_CPPFLAGS}"
-    export HOST_LDFLAGS="${BUILD_LDFLAGS}"
-    ( cd ${S}
-      gnu-configize --force
-      mv config.guess config.sub build/autoconf )
-    ${S}/configure ${EXTRA_OECONF}
-}
-
-# patch.bbclass will try to apply the patches already present and fail, so clean them out
-do_unpack() {
-    tar -xvf ${DL_DIR}/mozjs17.0.0.tar.gz -C ${WORKDIR}/
-    rm -rf ${WORKDIR}/${BPN}${PV}/patches
-}
-
-
-PACKAGES =+ "lib${BPN}"
-FILES_lib${BPN} += "${libdir}/lib*.so"
-FILES_${PN}-dev += "${bindir}/js17-config"
-
-# Fails to build with thumb-1 (qemuarm)
-#| {standard input}: Assembler messages:
-#| {standard input}:2172: Error: shifts in CMP/MOV instructions are only supported in unified syntax -- `mov r2,r1,LSR#20'
-#| {standard input}:2173: Error: unshifted register required -- `bic r2,r2,#(1<<11)'
-#| {standard input}:2174: Error: unshifted register required -- `orr r1,r1,#(1<<20)'
-#| {standard input}:2176: Error: instruction not supported in Thumb16 mode -- `subs r2,r2,#0x300'
-#| {standard input}:2178: Error: instruction not supported in Thumb16 mode -- `subs r5,r2,#52'
-ARM_INSTRUCTION_SET = "arm"
diff --git a/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs_52.9.1.bb b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs_52.9.1.bb
new file mode 100644
index 0000000..0dfe2f8
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/mozjs/mozjs_52.9.1.bb
@@ -0,0 +1,111 @@
+SUMMARY = "SpiderMonkey is Mozilla's JavaScript engine written in C/C++"
+HOMEPAGE = "https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey"
+LICENSE = "MPL-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=815ca599c9df247a0c7f619bab123dad"
+
+SRC_URI = "http://archive.ubuntu.com/ubuntu/pool/main/m/mozjs52/mozjs52_52.9.1.orig.tar.xz \
+           file://0001-js.pc.in-do-not-include-RequiredDefines.h-for-depend.patch \
+           file://0010-fix-cross-compilation-on-i586-targets.patch \
+           file://0001-do-not-create-python-environment.patch \
+           file://0002-fix-cannot-find-link.patch \
+           file://0003-workaround-autoconf-2.13-detection-failed.patch \
+           file://0004-do-not-use-autoconf-2.13-to-refresh-old.configure.patch \
+           file://0005-fix-do_compile-failed-on-mips.patch \
+           file://disable-mozglue-in-stand-alone-builds.patch \
+           file://add-riscv-support.patch \
+           file://0001-mozjs-fix-coredump-caused-by-getenv.patch \
+           "
+SRC_URI_append_libc-musl = " \
+           file://0006-support-musl.patch \
+           "
+SRC_URI_append_mipsarchn32 = " \
+           file://0001-fix-compiling-failure-on-mips64-n32-bsp.patch \
+           "
+
+SRC_URI[md5sum] = "c9473c625ee0a9edaaac8b742ff24c5f"
+SRC_URI[sha256sum] = "f9324a6724233ab15f10381fe13e635e89d725ef1e78025a0a7d36c58a84a0f9"
+
+inherit autotools pkgconfig perlnative pythonnative
+
+inherit distro_features_check
+CONFLICT_DISTRO_FEATURES_mipsarchn32 = "ld-is-gold"
+
+DEPENDS += "nspr zlib"
+
+# Disable null pointer optimization in gcc >= 6
+# https://bugzilla.redhat.com/show_bug.cgi?id=1328045
+CFLAGS += "-fno-tree-vrp -fno-strict-aliasing -fno-delete-null-pointer-checks"
+CXXFLAGS += "-fno-tree-vrp -fno-strict-aliasing -fno-delete-null-pointer-checks"
+
+# nspr's package-config is ignored so set libs manually
+EXTRA_OECONF = " \
+    --target=${TARGET_SYS} \
+    --host=${BUILD_SYS} \
+    --prefix=${prefix} \
+    --libdir=${libdir} \
+    --disable-tests \
+    --with-nspr-libs='-lplds4 -lplc4 -lnspr4' \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-gold', "--enable-gold", '--disable-gold', d)} \
+"
+
+PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}"
+PACKAGECONFIG[x11] = "--x-includes=${STAGING_INCDIR} --x-libraries=${STAGING_LIBDIR},,virtual/libx11"
+
+EXTRA_OEMAKE_task-compile += "OS_LDFLAGS='-Wl,-latomic ${LDFLAGS}'"
+EXTRA_OEMAKE_task-install += "STATIC_LIBRARY_NAME=js_static"
+
+do_configure() {
+    export SHELL="/bin/sh"
+    export TMP="${B}"
+    ${S}/js/src/configure ${EXTRA_OECONF}
+}
+
+do_compile_prepend() {
+    export SHELL="/bin/sh"
+    export S
+    export PYTHONPATH
+    cd ${S}
+    for sub_dir in python testing/mozbase; do
+        for module_dir in `ls $sub_dir -1`;do
+            [ $module_dir = "virtualenv" ] && continue
+            if [ -d "${S}/$sub_dir/$module_dir" ];then
+                PYTHONPATH="$PYTHONPATH:${S}/$sub_dir/$module_dir"
+            fi
+        done
+    done
+    PYTHONPATH="$PYTHONPATH:${S}/config:${S}/build"
+    cd -
+}
+
+do_install_prepend() {
+    export SHELL="/bin/sh"
+    export S
+    export PYTHONPATH
+    cd ${S}
+    for sub_dir in python testing/mozbase; do
+        for module_dir in `ls $sub_dir -1`;do
+            [ $module_dir = "virtualenv" ] && continue
+            if [ -d "${S}/$sub_dir/$module_dir" ];then
+                PYTHONPATH="$PYTHONPATH:${S}/$sub_dir/$module_dir"
+            fi
+        done
+    done
+    PYTHONPATH="$PYTHONPATH:${S}/config:${S}/build"
+    cd -
+}
+
+PACKAGES =+ "lib${BPN}"
+FILES_lib${BPN} += "${libdir}/lib*.so"
+FILES_${PN}-dev += "${bindir}/js52-config"
+
+# Fails to build with thumb-1 (qemuarm)
+#| {standard input}: Assembler messages:
+#| {standard input}:2172: Error: shifts in CMP/MOV instructions are only supported in unified syntax -- `mov r2,r1,LSR#20'
+#| {standard input}:2173: Error: unshifted register required -- `bic r2,r2,#(1<<11)'
+#| {standard input}:2174: Error: unshifted register required -- `orr r1,r1,#(1<<20)'
+#| {standard input}:2176: Error: instruction not supported in Thumb16 mode -- `subs r2,r2,#0x300'
+#| {standard input}:2178: Error: instruction not supported in Thumb16 mode -- `subs r5,r2,#52'
+ARM_INSTRUCTION_SET_armv5 = "arm"
+ARM_INSTRUCTION_SET_armv4 = "arm"
+
+DISABLE_STATIC = ""
diff --git a/meta-openembedded/meta-oe/recipes-extended/openlmi/openlmi-tools_0.10.5.bb b/meta-openembedded/meta-oe/recipes-extended/openlmi/openlmi-tools_0.10.5.bb
index 13e67cb..419b3ee 100644
--- a/meta-openembedded/meta-oe/recipes-extended/openlmi/openlmi-tools_0.10.5.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/openlmi/openlmi-tools_0.10.5.bb
@@ -2,25 +2,23 @@
 DESCRIPTION = "openlmi-tools is a set of command line tools for Openlmi providers."
 HOMEPAGE = "http://www.openlmi.org/"
 LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=75859989545e37968a99b631ef42722e"
+LIC_FILES_CHKSUM = "file://../COPYING;md5=75859989545e37968a99b631ef42722e"
 SECTION = "System/Management"
 
 inherit setuptools
 
-DEPENDS = "python-native pywbem-native python-m2crypto pywbem"
+DEPENDS = "python-native python-pywbem-native python-m2crypto python-pywbem"
 
 SRC_URI = "http://fedorahosted.org/released/${BPN}/${BP}.tar.gz \
           "
 SRC_URI[md5sum] = "e156246cb7b49753db82f4ddf7f03e50"
 SRC_URI[sha256sum] = "292b8f5f2250655a4add8183c529b73358bc980bd4f23cfa484a940953fce9e4"
 
-do_compile_prepend() {
-    cd cli
+S = "${WORKDIR}/${BP}/cli"
+
+do_configure_prepend() {
     sed 's/@@VERSION@@/$(VERSION)/g' setup.py.skel >setup.py
 }
-do_install_prepend() {
-    cd cli
-}
 
 python() {
     if 'meta-python' not in d.getVar('BBFILE_COLLECTIONS').split():
diff --git a/meta-openembedded/meta-oe/recipes-extended/openwsman/openwsman/0001-Port-to-OpenSSL-1.1.0.patch b/meta-openembedded/meta-oe/recipes-extended/openwsman/openwsman/0001-Port-to-OpenSSL-1.1.0.patch
new file mode 100644
index 0000000..49afa56
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/openwsman/openwsman/0001-Port-to-OpenSSL-1.1.0.patch
@@ -0,0 +1,162 @@
+From f78643d2388dd0697f83f17880403253a0596d83 Mon Sep 17 00:00:00 2001
+From: Vitezslav Crhonek <vcrhonek@redhat.com>
+Date: Wed, 5 Sep 2018 11:23:46 -0700
+Subject: [PATCH 1/2] Port to OpenSSL 1.1.0
+
+Upstream-Status: Submitted [https://github.com/Openwsman/openwsman/pull/99]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/lib/wsman-curl-client-transport.c |  6 +++-
+ src/server/shttpd/io_ssl.c            | 17 ----------
+ src/server/shttpd/shttpd.c            | 20 ++++--------
+ src/server/shttpd/ssl.h               | 46 ---------------------------
+ 4 files changed, 12 insertions(+), 77 deletions(-)
+
+diff --git a/src/lib/wsman-curl-client-transport.c b/src/lib/wsman-curl-client-transport.c
+index cd7f517a..e64ad097 100644
+--- a/src/lib/wsman-curl-client-transport.c
++++ b/src/lib/wsman-curl-client-transport.c
+@@ -241,12 +241,16 @@ write_handler( void *ptr, size_t size, size_t nmemb, void *data)
+ static int ssl_certificate_thumbprint_verify_callback(X509_STORE_CTX *ctx, void *arg)
+ {
+ 	unsigned char *thumbprint = (unsigned char *)arg;
+-	X509 *cert = ctx->cert;
+ 	EVP_MD                                  *tempDigest;
+ 
+ 	unsigned char   tempFingerprint[EVP_MAX_MD_SIZE];
+ 	unsigned int      tempFingerprintLen;
+ 	tempDigest = (EVP_MD*)EVP_sha1( );
++
++	X509 *cert = X509_STORE_CTX_get_current_cert(ctx);
++	if(!cert)
++		return 0;
++
+ 	if ( X509_digest(cert, tempDigest, tempFingerprint, &tempFingerprintLen ) <= 0)
+ 		return 0;
+ 	if(!memcmp(tempFingerprint, thumbprint, tempFingerprintLen))
+diff --git a/src/server/shttpd/io_ssl.c b/src/server/shttpd/io_ssl.c
+index 6de0db2a..7ac669e4 100644
+--- a/src/server/shttpd/io_ssl.c
++++ b/src/server/shttpd/io_ssl.c
+@@ -11,23 +11,6 @@
+ #include "defs.h"
+ 
+ #if !defined(NO_SSL)
+-struct ssl_func	ssl_sw[] = {
+-	{"SSL_free",			{0}},
+-	{"SSL_accept",			{0}},
+-	{"SSL_connect",			{0}},
+-	{"SSL_read",			{0}},
+-	{"SSL_write",			{0}},
+-	{"SSL_get_error",		{0}},
+-	{"SSL_set_fd",			{0}},
+-	{"SSL_new",			{0}},
+-	{"SSL_CTX_new",			{0}},
+-	{"SSLv23_server_method",	{0}},
+-	{"SSL_library_init",		{0}},
+-	{"SSL_CTX_use_PrivateKey_file",	{0}},
+-	{"SSL_CTX_use_certificate_file",{0}},
+-	{NULL,				{0}}
+-};
+-
+ void
+ _shttpd_ssl_handshake(struct stream *stream)
+ {
+diff --git a/src/server/shttpd/shttpd.c b/src/server/shttpd/shttpd.c
+index 5876392e..4c1dbf32 100644
+--- a/src/server/shttpd/shttpd.c
++++ b/src/server/shttpd/shttpd.c
+@@ -1476,20 +1476,14 @@ set_ssl(struct shttpd_ctx *ctx, const char *pem)
+ 	int		retval = FALSE;
+ 	EC_KEY*		key;
+ 
+-	/* Load SSL library dynamically */
+-	if ((lib = dlopen(SSL_LIB, RTLD_LAZY)) == NULL) {
+-		_shttpd_elog(E_LOG, NULL, "set_ssl: cannot load %s", SSL_LIB);
+-		return (FALSE);
+-	}
+-
+-	for (fp = ssl_sw; fp->name != NULL; fp++)
+-		if ((fp->ptr.v_void = dlsym(lib, fp->name)) == NULL) {
+-			_shttpd_elog(E_LOG, NULL,"set_ssl: cannot find %s", fp->name);
+-			return (FALSE);
+-		}
+-
+ 	/* Initialize SSL crap */
++	debug("Initialize SSL");
++	SSL_load_error_strings();
++	#if OPENSSL_VERSION_NUMBER < 0x10100000L
+ 	SSL_library_init();
++	#else
++	OPENSSL_init_ssl(0, NULL);
++	#endif
+ 
+ 	if ((CTX = SSL_CTX_new(SSLv23_server_method())) == NULL)
+ 		_shttpd_elog(E_LOG, NULL, "SSL_CTX_new error");
+@@ -1532,7 +1526,7 @@ set_ssl(struct shttpd_ctx *ctx, const char *pem)
+ 			if (strncasecmp(protocols[idx].name, ssl_disabled_protocols, blank_ptr-ssl_disabled_protocols) == 0) {
+ 				//_shttpd_elog(E_LOG, NULL, "SSL: disable %s protocol", protocols[idx].name);
+ 				debug("SSL: disable %s protocol", protocols[idx].name);
+-				SSL_CTX_ctrl(CTX, SSL_CTRL_OPTIONS, protocols[idx].opt, NULL);
++				SSL_CTX_set_options(CTX, protocols[idx].opt);
+ 				break;
+ 			}
+ 		}
+diff --git a/src/server/shttpd/ssl.h b/src/server/shttpd/ssl.h
+index a863f2c7..8dad0109 100644
+--- a/src/server/shttpd/ssl.h
++++ b/src/server/shttpd/ssl.h
+@@ -12,50 +12,4 @@
+ 
+ #include <openssl/ssl.h>
+ 
+-#else
+-
+-/*
+- * Snatched from OpenSSL includes. I put the prototypes here to be independent
+- * from the OpenSSL source installation. Having this, shttpd + SSL can be
+- * built on any system with binary SSL libraries installed.
+- */
+-
+-typedef struct ssl_st SSL;
+-typedef struct ssl_method_st SSL_METHOD;
+-typedef struct ssl_ctx_st SSL_CTX;
+-
+-#define	SSL_ERROR_WANT_READ	2
+-#define	SSL_ERROR_WANT_WRITE	3
+-#define	SSL_ERROR_SYSCALL	5
+-#define	SSL_FILETYPE_PEM	1
+-
+ #endif
+-
+-/*
+- * Dynamically loaded SSL functionality
+- */
+-struct ssl_func {
+-	const char	*name;		/* SSL function name	*/
+-	union variant	ptr;		/* Function pointer	*/
+-};
+-
+-extern struct ssl_func	ssl_sw[];
+-
+-#define	FUNC(x)	ssl_sw[x].ptr.v_func
+-
+-#define	SSL_free(x)	(* (void (*)(SSL *)) FUNC(0))(x)
+-#define	SSL_accept(x)	(* (int (*)(SSL *)) FUNC(1))(x)
+-#define	SSL_connect(x)	(* (int (*)(SSL *)) FUNC(2))(x)
+-#define	SSL_read(x,y,z)	(* (int (*)(SSL *, void *, int)) FUNC(3))((x),(y),(z))
+-#define	SSL_write(x,y,z) \
+-	(* (int (*)(SSL *, const void *,int)) FUNC(4))((x), (y), (z))
+-#define	SSL_get_error(x,y)(* (int (*)(SSL *, int)) FUNC(5))((x), (y))
+-#define	SSL_set_fd(x,y)	(* (int (*)(SSL *, int)) FUNC(6))((x), (y))
+-#define	SSL_new(x)	(* (SSL * (*)(SSL_CTX *)) FUNC(7))(x)
+-#define	SSL_CTX_new(x)	(* (SSL_CTX * (*)(SSL_METHOD *)) FUNC(8))(x)
+-#define	SSLv23_server_method()	(* (SSL_METHOD * (*)(void)) FUNC(9))()
+-#define	SSL_library_init() (* (int (*)(void)) FUNC(10))()
+-#define	SSL_CTX_use_PrivateKey_file(x,y,z)	(* (int (*)(SSL_CTX *, \
+-		const char *, int)) FUNC(11))((x), (y), (z))
+-#define	SSL_CTX_use_certificate_file(x,y,z)	(* (int (*)(SSL_CTX *, \
+-		const char *, int)) FUNC(12))((x), (y), (z))
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/openwsman/openwsman/0002-Check-OpenSSL-version-number-to-allow-builds-with-ol.patch b/meta-openembedded/meta-oe/recipes-extended/openwsman/openwsman/0002-Check-OpenSSL-version-number-to-allow-builds-with-ol.patch
new file mode 100644
index 0000000..5ae2e00
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/openwsman/openwsman/0002-Check-OpenSSL-version-number-to-allow-builds-with-ol.patch
@@ -0,0 +1,48 @@
+From 75669b077bd54bedbc086c60cbe137e7f4c685b5 Mon Sep 17 00:00:00 2001
+From: Vitezslav Crhonek <vcrhonek@redhat.com>
+Date: Mon, 24 Apr 2017 11:28:39 +0200
+Subject: [PATCH 2/2] Check OpenSSL version number to allow builds with older
+ version
+
+Upstream-Status: Submitted [https://github.com/Openwsman/openwsman/pull/99]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/lib/wsman-curl-client-transport.c | 4 ++++
+ src/server/shttpd/shttpd.c            | 4 ++++
+ 2 files changed, 8 insertions(+)
+
+diff --git a/src/lib/wsman-curl-client-transport.c b/src/lib/wsman-curl-client-transport.c
+index e64ad097..4fc047e8 100644
+--- a/src/lib/wsman-curl-client-transport.c
++++ b/src/lib/wsman-curl-client-transport.c
+@@ -247,7 +247,11 @@ static int ssl_certificate_thumbprint_verify_callback(X509_STORE_CTX *ctx, void
+ 	unsigned int      tempFingerprintLen;
+ 	tempDigest = (EVP_MD*)EVP_sha1( );
+ 
++	#if OPENSSL_VERSION_NUMBER < 0x10100000L
++	X509 *cert = ctx->cert;
++	#else
+ 	X509 *cert = X509_STORE_CTX_get_current_cert(ctx);
++	#endif
+ 	if(!cert)
+ 		return 0;
+ 
+diff --git a/src/server/shttpd/shttpd.c b/src/server/shttpd/shttpd.c
+index 4c1dbf32..161720c8 100644
+--- a/src/server/shttpd/shttpd.c
++++ b/src/server/shttpd/shttpd.c
+@@ -1526,7 +1526,11 @@ set_ssl(struct shttpd_ctx *ctx, const char *pem)
+ 			if (strncasecmp(protocols[idx].name, ssl_disabled_protocols, blank_ptr-ssl_disabled_protocols) == 0) {
+ 				//_shttpd_elog(E_LOG, NULL, "SSL: disable %s protocol", protocols[idx].name);
+ 				debug("SSL: disable %s protocol", protocols[idx].name);
++				#if OPENSSL_VERSION_NUMBER < 0x10100000L
++				SSL_CTX_ctrl(CTX, SSL_CTRL_OPTIONS, protocols[idx].opt, NULL);
++				#else
+ 				SSL_CTX_set_options(CTX, protocols[idx].opt);
++				#endif
+ 				break;
+ 			}
+ 		}
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/openwsman/openwsman_2.6.3.bb b/meta-openembedded/meta-oe/recipes-extended/openwsman/openwsman_2.6.3.bb
deleted file mode 100644
index f618f02..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/openwsman/openwsman_2.6.3.bb
+++ /dev/null
@@ -1,70 +0,0 @@
-SUMMARY = "Opensource Implementation of WS-Management"
-DESCRIPTION = "Openwsman is a project intended to provide an open-source \
-implementation of the Web Services Management specipication \
-(WS-Management) and to expose system management information on the \
-Linux operating system using the WS-Management protocol. WS-Management \
-is based on a suite of web services specifications and usage \
-requirements that exposes a set of operations focused on and covers \
-all system management aspects. \
-Openwsman Server and service libraries"
-HOMEPAGE = "http://www.openwsman.org/"
-SECTION = "Applications/System"
-
-DEPENDS = "curl libxml2 openssl libpam"
-
-inherit distro_features_check
-REQUIRED_DISTRO_FEATURES = "pam"
-
-SRCREV = "feb7ec9b004fcaea0dbe65ce8a1a79cc29dd994c"
-PV = "2.6.3"
-
-SRC_URI = "git://github.com/Openwsman/openwsman.git \
-           file://libssl-is-required-if-eventint-supported.patch \
-           file://openwsmand.service \
-           file://0001-lock.c-Define-PTHREAD_MUTEX_RECURSIVE_NP-if-undefine.patch \
-           "
-
-S = "${WORKDIR}/git"
-
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d4f53d4c6cf73b9d43186ce3be6dd0ba"
-
-inherit systemd cmake pkgconfig pythonnative perlnative
-
-SYSTEMD_SERVICE_${PN} = "openwsmand.service"
-SYSTEMD_AUTO_ENABLE = "disable"
-
-LDFLAGS_append = "${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-gold', " -fuse-ld=bfd ", '', d)}"
-
-EXTRA_OECMAKE = "-DBUILD_BINDINGS=NO \
-                 -DBUILD_LIBCIM=NO \
-                 -DBUILD_PERL=YES \
-                 -DCMAKE_INSTALL_PREFIX=${prefix} \
-                 -DLIB=${baselib} \
-                "
-
-do_configure_prepend() {
-    export STAGING_INCDIR=${STAGING_INCDIR}
-    export STAGING_LIBDIR=${STAGING_LIBDIR}
-}
-
-do_install_append() {
-    install -d ${D}/${sysconfdir}/init.d
-    install -m 755 ${B}/etc/init/openwsmand.sh ${D}/${sysconfdir}/init.d/openwsmand
-    ln -sf ${sysconfdir}/init.d/openwsmand ${D}/${sbindir}/rcopenwsmand
-    chmod 755 ${D}/${sysconfdir}/openwsman/owsmangencert.sh
-    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
-        install -d ${D}/${systemd_unitdir}/system
-        install -m 644 ${WORKDIR}/openwsmand.service ${D}/${systemd_unitdir}/system
-
-        sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/openwsmand.service
-        sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' ${D}${systemd_unitdir}/system/openwsmand.service
-        sed -i -e 's,@LOCALSTATEDIR@,${localstatedir},g' ${D}${systemd_unitdir}/system/openwsmand.service
-    fi
-}
-
-FILES_${PN}-dbg += "${libdir}/openwsman/plugins/.debug/ \
-                    ${libdir}/openwsman/authenticators/.debug/ \
-                   "
-
-INSANE_SKIP_${PN} = "dev-so"
diff --git a/meta-openembedded/meta-oe/recipes-extended/openwsman/openwsman_2.6.5.bb b/meta-openembedded/meta-oe/recipes-extended/openwsman/openwsman_2.6.5.bb
new file mode 100644
index 0000000..5fba385
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/openwsman/openwsman_2.6.5.bb
@@ -0,0 +1,73 @@
+SUMMARY = "Opensource Implementation of WS-Management"
+DESCRIPTION = "Openwsman is a project intended to provide an open-source \
+implementation of the Web Services Management specipication \
+(WS-Management) and to expose system management information on the \
+Linux operating system using the WS-Management protocol. WS-Management \
+is based on a suite of web services specifications and usage \
+requirements that exposes a set of operations focused on and covers \
+all system management aspects. \
+Openwsman Server and service libraries"
+HOMEPAGE = "http://www.openwsman.org/"
+SECTION = "Applications/System"
+
+DEPENDS = "curl libxml2 openssl libpam"
+
+inherit distro_features_check
+REQUIRED_DISTRO_FEATURES = "pam"
+
+SRCREV = "e90e5c96e3006c372bf45e0185e33c9250e67df6"
+PV = "2.6.5"
+
+SRC_URI = "git://github.com/Openwsman/openwsman.git \
+           file://libssl-is-required-if-eventint-supported.patch \
+           file://openwsmand.service \
+           file://0001-lock.c-Define-PTHREAD_MUTEX_RECURSIVE_NP-if-undefine.patch \
+           file://0001-Port-to-OpenSSL-1.1.0.patch \
+           file://0002-Check-OpenSSL-version-number-to-allow-builds-with-ol.patch \
+           "
+
+S = "${WORKDIR}/git"
+
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d4f53d4c6cf73b9d43186ce3be6dd0ba"
+
+inherit systemd cmake pkgconfig pythonnative perlnative
+
+SYSTEMD_SERVICE_${PN} = "openwsmand.service"
+SYSTEMD_AUTO_ENABLE = "disable"
+
+LDFLAGS_append = "${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-gold', " -fuse-ld=bfd ", '', d)}"
+
+EXTRA_OECMAKE = "-DBUILD_BINDINGS=NO \
+                 -DBUILD_LIBCIM=NO \
+                 -DBUILD_PERL=YES \
+                 -DCMAKE_INSTALL_PREFIX=${prefix} \
+                 -DLIB=${baselib} \
+                "
+
+do_configure_prepend() {
+    export STAGING_INCDIR=${STAGING_INCDIR}
+    export STAGING_LIBDIR=${STAGING_LIBDIR}
+}
+
+do_install_append() {
+    install -d ${D}/${sysconfdir}/init.d
+    install -m 755 ${B}/etc/init/openwsmand.sh ${D}/${sysconfdir}/init.d/openwsmand
+    ln -sf ${sysconfdir}/init.d/openwsmand ${D}/${sbindir}/rcopenwsmand
+    chmod 755 ${D}/${sysconfdir}/openwsman/owsmangencert.sh
+    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
+        install -d ${D}/${systemd_unitdir}/system
+        install -m 644 ${WORKDIR}/openwsmand.service ${D}/${systemd_unitdir}/system
+
+        sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/openwsmand.service
+        sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' ${D}${systemd_unitdir}/system/openwsmand.service
+        sed -i -e 's,@LOCALSTATEDIR@,${localstatedir},g' ${D}${systemd_unitdir}/system/openwsmand.service
+    fi
+}
+
+FILES_${PN}-dbg += "${libdir}/openwsman/plugins/.debug/ \
+                    ${libdir}/openwsman/authenticators/.debug/ \
+                   "
+
+INSANE_SKIP_${PN} = "dev-so"
+RDEPENDS_${PN} = "ruby"
diff --git a/meta-openembedded/meta-oe/recipes-extended/p7zip/p7zip_16.02.bb b/meta-openembedded/meta-oe/recipes-extended/p7zip/p7zip_16.02.bb
index d986da9..13479a9 100644
--- a/meta-openembedded/meta-oe/recipes-extended/p7zip/p7zip_16.02.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/p7zip/p7zip_16.02.bb
@@ -17,26 +17,9 @@
 S = "${WORKDIR}/${BPN}_${PV}"
 
 do_install() {
-    install -d ${D}${bindir}
-    install -m 0755 ${S}/bin/* ${D}${bindir}
-}
-
-# all3: to build bin/7za, bin/7z (with its plugins), bin/7zr and bin/7zCon.sfx
-EXTRA_OEMAKE_class-native = "all3"
-
-do_install_class-native() {
-    install -d ${D}${bindir}
-    install -d ${D}${bindir}/Codecs
-    install -m 0755 ${S}/bin/7* ${D}${bindir}
-    install -m 0755 ${S}/bin/Codecs/* ${D}${bindir}/Codecs
-
-    # Create a shell script wrapper to execute next to 7z.so
-    mv ${D}${bindir}/7z ${D}${bindir}/7z.bin
-    cat > ${D}${bindir}/7z << 'EOF'
-#!/bin/sh
-exec "$(dirname "$0")"/7z.bin "$@"
-EOF
-    chmod 0755 ${D}${bindir}/7z
+	install -d ${D}${bindir}
+	install -m 0755 ${S}/bin/* ${D}${bindir}
+	ln -s 7za ${D}${bindir}/7z
 }
 
 BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-extended/p8platform/files/0001-Make-resulting-cmake-config-relocatable.patch b/meta-openembedded/meta-oe/recipes-extended/p8platform/files/0001-Make-resulting-cmake-config-relocatable.patch
new file mode 100644
index 0000000..9ff85b1
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/p8platform/files/0001-Make-resulting-cmake-config-relocatable.patch
@@ -0,0 +1,64 @@
+From 2650bb3bd3644784359be373252b0436873ca8cb Mon Sep 17 00:00:00 2001
+From: Pascal Bach <pascal.bach@siemens.com>
+Date: Fri, 28 Sep 2018 16:44:37 +0200
+Subject: [PATCH] Make resulting cmake config relocatable
+
+This change avoids hardcoded install prefix in the p8-platform-config.cmake.
+Especially important when doing cross compilation with Yocto for example.
+
+Upstream-Status: Submitted [https://github.com/Pulse-Eight/platform/pull/38]
+
+---
+ CMakeLists.txt              |  4 ----
+ p8-platform-config.cmake.in | 13 +++++++++----
+ 2 files changed, 9 insertions(+), 8 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 7144b0b..f2db66e 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -22,10 +22,6 @@ if(WIN32)
+                    src/windows/os-threads.cpp)
+ endif()
+ 
+-set(p8-platform_INCLUDE_DIRS "${CMAKE_INSTALL_PREFIX}/include/p8-platform")
+-IF(WIN32)
+-  LIST(APPEND p8-platform_INCLUDE_DIRS "${CMAKE_INSTALL_PREFIX}/include/p8-platform/windows")
+-ENDIF(WIN32)
+ set(p8-platform_LIBRARIES ${CMAKE_THREAD_LIBS_INIT})
+ 
+ if(NOT ${CORE_SYSTEM_NAME} STREQUAL "")
+diff --git a/p8-platform-config.cmake.in b/p8-platform-config.cmake.in
+index 47f30f1..b08e96c 100644
+--- a/p8-platform-config.cmake.in
++++ b/p8-platform-config.cmake.in
+@@ -9,17 +9,22 @@
+ #  p8-platform_LIBRARY_DIRS - directories in which the libraries are situated
+ #
+ # propagate these properties from one build system to the other
++get_filename_component(_p8-platform_rootdir ${CMAKE_CURRENT_LIST_DIR}/../ ABSOLUTE)
++
+ set (p8-platform_VERSION "@p8-platform_VERSION_MAJOR@.@p8-platform_VERSION_MINOR@")
+-set (p8-platform_INCLUDE_DIRS @p8-platform_INCLUDE_DIRS@ @CMAKE_INSTALL_PREFIX@/include)
+-set (p8-platform_LIBRARY_DIRS "@CMAKE_LIBRARY_OUTPUT_DIRECTORY@")
++set (p8-platform_INCLUDE_DIRS "${_p8-platform_rootdir}/include" "${_p8-platform_rootdir}/include/p8-platform")
++if(WIN32)
++  list(APPEND p8-platform_INCLUDE_DIRS "${_p8-platform_rootdir}/include/p8-platform/windows")
++endif(WIN32)
++set (p8-platform_LIBRARY_DIRS "${_p8-platform_rootdir}")
+ set (p8-platform_LINKER_FLAGS "@p8-platform_LINKER_FLAGS@")
+ set (p8-platform_CONFIG_VARS "@p8-platform_CONFIG_VARS@")
+ 
+ # libraries come from the build tree where this file was generated
+ if(WIN32)
+-  set (p8-platform_LIBRARY "@CMAKE_INSTALL_PREFIX@/@CMAKE_INSTALL_LIBDIR@/p8-platform.lib")
++  set (p8-platform_LIBRARY "${_p8-platform_rootdir}/p8-platform.lib")
+ else(WIN32)
+-  set (p8-platform_LIBRARY "-L@CMAKE_INSTALL_PREFIX@/@CMAKE_INSTALL_LIBDIR@ -lp8-platform")
++  set (p8-platform_LIBRARY "-L${_p8-platform_rootdir} -lp8-platform")
+ endif(WIN32)
+ set (p8-platform_LIBRARIES ${p8-platform_LIBRARY} "@p8-platform_LIBRARIES@")
+ mark_as_advanced (p8-platform_LIBRARY)
+-- 
+2.11.0
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/p8platform/p8platform_git.bb b/meta-openembedded/meta-oe/recipes-extended/p8platform/p8platform_git.bb
index f6347c2..0690d4b 100644
--- a/meta-openembedded/meta-oe/recipes-extended/p8platform/p8platform_git.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/p8platform/p8platform_git.bb
@@ -4,10 +4,11 @@
 LICENSE = "GPLv2+"
 LIC_FILES_CHKSUM = "file://src/os.h;md5=752555fa94e82005d45fd201fee5bd33"
 
-PV = "2.1.0"
+PV = "2.1.0.1"
 
-SRC_URI = "git://github.com/Pulse-Eight/platform.git"
-SRCREV = "d7bceb64541cb046421cbcd4c98d91e9bf24822f"
+SRC_URI = "git://github.com/Pulse-Eight/platform.git \
+           file://0001-Make-resulting-cmake-config-relocatable.patch"
+SRCREV = "2d90f98620e25f47702c9e848380c0d93f29462b"
 
 S = "${WORKDIR}/git"
 
diff --git a/meta-openembedded/meta-oe/recipes-extended/pam/pam-plugin-ccreds_11.bb b/meta-openembedded/meta-oe/recipes-extended/pam/pam-plugin-ccreds_11.bb
new file mode 100644
index 0000000..95d879d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/pam/pam-plugin-ccreds_11.bb
@@ -0,0 +1,22 @@
+SUMMARY = "PAM cached credentials module"
+HOMEPAGE = "https://www.padl.com/OSS/pam_ccreds.html"
+SECTION = "libs"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+
+DEPENDS = "libpam openssl db"
+
+inherit distro_features_check
+REQUIRED_DISTRO_FEATURES = "pam"
+
+SRCREV = "e2145df09469bf84878e4729b4ecd814efb797d1"
+
+SRC_URI = "git://github.com/PADL/pam_ccreds"
+
+S = "${WORKDIR}/git"
+
+inherit autotools
+
+EXTRA_OECONF += "--libdir=${base_libdir} "
+
+FILES_${PN} += "${base_libdir}/security/pam*"
diff --git a/meta-openembedded/meta-oe/recipes-extended/pam/pam-plugin-ldapdb_1.3.bb b/meta-openembedded/meta-oe/recipes-extended/pam/pam-plugin-ldapdb_1.3.bb
new file mode 100644
index 0000000..c59a259
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/pam/pam-plugin-ldapdb_1.3.bb
@@ -0,0 +1,23 @@
+SUMMARY = "PAM searchless LDAP authentication module"
+HOMEPAGE = "https://github.com/rmbreak/pam_ldapdb"
+BUGTRACKER = "https://github.com/rmbreak/pam_ldapdb/issues"
+SECTION = "libs"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=41ab94182d94be9bb35e2a8b933f1e7d"
+
+DEPENDS = "libpam openldap"
+
+inherit distro_features_check
+REQUIRED_DISTRO_FEATURES = "pam"
+
+SRC_URI = "https://github.com/rmbreak/pam_ldapdb/archive/v${PV}.tar.gz;downloadfilename=${BP}.tar.gz"
+SRC_URI[md5sum] = "2dd4f1370fcfe995ee0ad09611109b87"
+SRC_URI[sha256sum] = "8ed92b36523556bb5d9bf3eb33a1035e46041d4be767c8d62136930c0ca0e45b"
+
+S = "${WORKDIR}/pam_ldapdb-${PV}"
+
+do_install () {
+    oe_runmake install DESTDIR=${D} PAMDIR=${base_libdir}/security
+}
+
+FILES_${PN} += "${base_libdir}/security/pam_ldapdb.so"
diff --git a/meta-openembedded/meta-oe/recipes-extended/pam/pam-ssh-agent-auth_0.10.3.bb b/meta-openembedded/meta-oe/recipes-extended/pam/pam-ssh-agent-auth_0.10.3.bb
index 1638c41..2a461fc 100644
--- a/meta-openembedded/meta-oe/recipes-extended/pam/pam-ssh-agent-auth_0.10.3.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/pam/pam-ssh-agent-auth_0.10.3.bb
@@ -11,7 +11,7 @@
 SRC_URI[md5sum] = "8dbe90ab3625e545036333e6f51ccf1d"
 SRC_URI[sha256sum] = "3c53d358d6eaed1b211239df017c27c6f9970995d14102ae67bae16d4f47a763"
 
-DEPENDS += "libpam openssl"
+DEPENDS += "libpam openssl10"
 
 inherit distro_features_check
 REQUIRED_DISTRO_FEATURES = "pam"
diff --git a/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0001-jemalloc-jemalloc.cfg-Specify-the-host-when-building.patch b/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0001-jemalloc-jemalloc.cfg-Specify-the-host-when-building.patch
new file mode 100644
index 0000000..747538b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0001-jemalloc-jemalloc.cfg-Specify-the-host-when-building.patch
@@ -0,0 +1,29 @@
+From 2a22dc96c3bbb5c9bbcc008f58d4f5c64e3d19e6 Mon Sep 17 00:00:00 2001
+From: Alistair Francis <alistair.francis@wdc.com>
+Date: Mon, 23 Jul 2018 11:23:39 -0700
+Subject: [PATCH] jemalloc/jemalloc.cfg: Specify the host when building
+ jemalloc
+
+To avoid this error:
+    configure: error: cannot run C compiled programs.
+    If you meant to cross compile, use `--host'.
+when cross compiling specify the host when configuring jemalloc.
+
+Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
+Upstream-Status: Inappropriate [configuration]
+---
+ src/jemalloc/jemalloc.cfg | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/jemalloc/jemalloc.cfg b/src/jemalloc/jemalloc.cfg
+index 196129de6..79ebbab1c 100644
+--- a/src/jemalloc/jemalloc.cfg
++++ b/src/jemalloc/jemalloc.cfg
+@@ -3,3 +3,4 @@
+ --with-private-namespace=je_vmem_
+ --disable-xmalloc
+ --disable-munmap
++--host=${HOST_SYS}
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0002-Makefile-Don-t-install-the-docs.patch b/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0002-Makefile-Don-t-install-the-docs.patch
new file mode 100644
index 0000000..bd1b97c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0002-Makefile-Don-t-install-the-docs.patch
@@ -0,0 +1,26 @@
+From 460a96e390cb80278784cfe36629e280fe7ffef7 Mon Sep 17 00:00:00 2001
+From: Alistair Francis <alistair.francis@wdc.com>
+Date: Mon, 23 Jul 2018 11:31:17 -0700
+Subject: [PATCH 2/2] Makefile: Don't install the docs
+
+Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
+Upstream-Status: Inappropriate [disable feature]
+---
+ Makefile | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/Makefile b/Makefile
+index 224a315f6..ce7f84afb 100644
+--- a/Makefile
++++ b/Makefile
+@@ -144,7 +144,6 @@ rpm dpkg: pkg-clean source
+ 
+ install uninstall:
+ 	$(MAKE) -C src $@
+-	$(MAKE) -C doc $@
+ 
+ .PHONY: all clean clobber test check cstyle check-license install uninstall\
+ 	source rpm dpkg pkg-clean pcheck check-remote format doc $(SUBDIRS)
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0003-Makefile-Don-t-build-the-examples.patch b/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0003-Makefile-Don-t-build-the-examples.patch
new file mode 100644
index 0000000..f75d941
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0003-Makefile-Don-t-build-the-examples.patch
@@ -0,0 +1,34 @@
+From a7f07dca2468ea226d2f07fc0105166e75cadaf8 Mon Sep 17 00:00:00 2001
+From: Alistair Francis <alistair.francis@wdc.com>
+Date: Thu, 6 Sep 2018 16:18:50 -0700
+Subject: [PATCH] Makefile: Don't build the examples
+
+Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
+Upstream-Status: Inappropriate [disable feature]
+---
+ src/Makefile | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/Makefile b/src/Makefile
+index 4b50dd8b5..e00501e31 100644
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -38,13 +38,13 @@ include $(TOP)/src/version.inc
+ 
+ TARGETS = libpmem libvmem libpmemblk libpmemlog libpmemobj libpmempool\
+ 		  libpmemcto libvmmalloc tools
+-ALL_TARGETS = $(TARGETS) common librpmem examples benchmarks
++ALL_TARGETS = $(TARGETS) common librpmem benchmarks
+ 
+ SCOPE_DIRS = $(TARGETS) common librpmem rpmem_common
+ 
+ DEBUG_RELEASE_TARGETS = common libpmem libvmem libpmemblk libpmemlog libpmemobj\
+ 	libpmempool libvmmalloc librpmem libpmemcto
+-RELEASE_TARGETS = tools examples benchmarks
++RELEASE_TARGETS = tools benchmarks
+ 
+ CLEAN_NO_JE_TARGETS = $(ALL_TARGETS) rpmem_common test
+ CLEAN_TARGETS = $(CLEAN_NO_JE_TARGETS) jemalloc
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0004-os_posix-Manually-implement-secure_getenv-if-require.patch b/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0004-os_posix-Manually-implement-secure_getenv-if-require.patch
new file mode 100644
index 0000000..624f17b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0004-os_posix-Manually-implement-secure_getenv-if-require.patch
@@ -0,0 +1,30 @@
+From 33affa9ee97691efb73f439fcdba4adb8625a26a Mon Sep 17 00:00:00 2001
+From: Alistair Francis <alistair.francis@wdc.com>
+Date: Mon, 10 Sep 2018 12:59:48 -0700
+Subject: [PATCH] os_posix: Manually implement secure_getenv() if required
+
+Manually implement the secure_getenv() if we need to, this is required
+if using musl.
+
+Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
+Upstream-Status: Pending
+---
+ src/common/os_posix.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/common/os_posix.c b/src/common/os_posix.c
+index 2d70a0a29..fb09b6ce0 100644
+--- a/src/common/os_posix.c
++++ b/src/common/os_posix.c
+@@ -261,7 +261,7 @@ os_setenv(const char *name, const char *value, int overwrite)
+ /*
+  * secure_getenv -- provide GNU secure_getenv for FreeBSD
+  */
+-#ifdef __FreeBSD__
++#if defined(__FreeBSD__) || !HAVE___SECURE_GETENV
+ static char *
+ secure_getenv(const char *name)
+ {
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0005-pmempool-Remove-unused-__USE_UNIX98-define.patch b/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0005-pmempool-Remove-unused-__USE_UNIX98-define.patch
new file mode 100644
index 0000000..75c35f8
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0005-pmempool-Remove-unused-__USE_UNIX98-define.patch
@@ -0,0 +1,30 @@
+From 92e63699ea83074298971b0251f002562be4dbd3 Mon Sep 17 00:00:00 2001
+From: Alistair Francis <alistair.francis@wdc.com>
+Date: Mon, 10 Sep 2018 13:23:37 -0700
+Subject: [PATCH 2/3] pmempool: Remove unused __USE_UNIX98 define
+
+Remove the unused __USE_UNIX98 to fix musl build failures.
+
+Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
+Upstream-Status: Pending
+---
+ src/tools/pmempool/info.c | 3 ---
+ 1 file changed, 3 deletions(-)
+
+diff --git a/src/tools/pmempool/info.c b/src/tools/pmempool/info.c
+index b4010bf35..7b890a123 100644
+--- a/src/tools/pmempool/info.c
++++ b/src/tools/pmempool/info.c
+@@ -45,9 +45,6 @@
+ #include <inttypes.h>
+ #include <assert.h>
+ #include <sys/param.h>
+-#ifndef __FreeBSD__
+-#define __USE_UNIX98
+-#endif
+ #include <unistd.h>
+ #include <sys/mman.h>
+ 
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0006-Makefile.inc-Allow-extra-libs-to-be-specified.patch b/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0006-Makefile.inc-Allow-extra-libs-to-be-specified.patch
new file mode 100644
index 0000000..2042fdb
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/pmdk/files/0006-Makefile.inc-Allow-extra-libs-to-be-specified.patch
@@ -0,0 +1,29 @@
+From a88e806f9ce8cc071e81abad688643d53f393176 Mon Sep 17 00:00:00 2001
+From: Alistair Francis <alistair.francis@wdc.com>
+Date: Mon, 10 Sep 2018 14:18:38 -0700
+Subject: [PATCH 3/3] Makefile.inc: Allow extra libs to be specified
+
+Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
+Upstream-Status: Pending
+---
+ src/Makefile.inc       | 2 ++
+ src/common.inc         | 2 ++
+ src/tools/Makefile.inc | 1 +
+ 3 files changed, 5 insertions(+)
+
+diff --git a/src/common.inc b/src/common.inc
+index 032cb83ea..2d5c4bedf 100644
+--- a/src/common.inc
++++ b/src/common.inc
+@@ -74,6 +74,8 @@ GCOV_CFLAGS=-fprofile-arcs -ftest-coverage --coverage
+ GCOV_LDFLAGS=-fprofile-arcs -ftest-coverage
+ GCOV_LIBS=-lgcov
+ 
++LIBS += $(EXTRA_LIBS)
++
+ osdep = $(1)_$(shell uname -s | tr "[:upper:]" "[:lower:]")$(2)
+ get_arch = $(shell $(CC) -dumpmachine | awk -F'[/-]' '{print $$1}')
+ 
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/pmdk/pmdk_1.4.2.bb b/meta-openembedded/meta-oe/recipes-extended/pmdk/pmdk_1.4.2.bb
new file mode 100644
index 0000000..3da22a9
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/pmdk/pmdk_1.4.2.bb
@@ -0,0 +1,64 @@
+SUMMARY = "Persistent Memory Development Kit"
+DESCRIPTION = "Persistent Memory Development Kit"
+HOMEPAGE = "http://pmem.io"
+SECTION = "libs"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=7db1106255a1baa80391fd2e21eebab7"
+DEPENDS = "ndctl"
+
+# Required to have the fts.h header for musl
+DEPENDS_append_libc-musl = " fts"
+
+SRC_URI = "https://github.com/pmem/${BPN}/archive/${PV}.tar.gz \
+           file://0001-jemalloc-jemalloc.cfg-Specify-the-host-when-building.patch \
+           file://0002-Makefile-Don-t-install-the-docs.patch \
+           file://0003-Makefile-Don-t-build-the-examples.patch \
+           file://0005-pmempool-Remove-unused-__USE_UNIX98-define.patch \
+           file://0006-Makefile.inc-Allow-extra-libs-to-be-specified.patch \
+          "
+
+SRC_URI_append_libc-musl = " file://0004-os_posix-Manually-implement-secure_getenv-if-require.patch"
+
+SRC_URI[md5sum] = "bde73bca9ef5b90911deb0fdcfb15ccf"
+SRC_URI[sha256sum] = "df7e658e75d28cd80f6d2ff7b9fc9ae2885d52f8923fdbacecfd46215115fb4c"
+
+inherit autotools-brokensep pkgconfig
+
+# Fix jemalloc error:
+# | configure: error: cannot run C compiled programs.
+# | If you meant to cross compile, use `--host'.
+#
+# Also fix #warning _FORTIFY_SOURCE requires compiling with optimization (-O) [-Werror=cpp]
+EXTRA_OEMAKE = "HOST_SYS='${HOST_SYS}' EXTRA_CFLAGS='${SELECTED_OPTIMIZATION}'"
+
+# Fix the missing fts libs when using musl
+EXTRA_OEMAKE_append_libc-musl = " EXTRA_LIBS='-lfts'"
+
+do_install() {
+	oe_runmake PREFIX=${prefix} DESTDIR=${D} install
+
+	# Copy these into the standard directories
+	install -d ${D}${bindir}/
+	mv ${D}/usr/local/bin/pmempool ${D}${bindir}/
+	mv ${D}/usr/local/bin/daxio ${D}${bindir}/
+
+	install -d ${D}${libdir}
+	mv ${D}/usr/local/lib/*so* ${D}${libdir}/
+
+	install -d ${D}${libdir}/pkgconfig
+	mv ${D}/usr/local/lib/pkgconfig/*.pc ${D}${libdir}/pkgconfig/
+
+	install -d ${D}${includedir}
+	mv ${D}/usr/local/include/* ${D}${includedir}/
+
+	# Remove uneeded files
+	rm -rf ${D}/usr/local/
+}
+
+# Include these by default otherwise the SDK is not very useful
+FILES_${PN} += "${bindir}/pmempool ${bindir}/daxio"
+FILES_${PN} += "${libdir}/*so*"
+FILES_${PN} += "${libdir}/pkgconfig/*.pc"
+FILES_${PN} += "${includedir}/libpmemobj++/* ${includedir}/libpmemobj/*"
+
+COMPATIBLE_HOST='(x86_64).*'
diff --git a/meta-openembedded/meta-oe/recipes-extended/polkit/polkit/0001-make-netgroup-support-configurable.patch b/meta-openembedded/meta-oe/recipes-extended/polkit/polkit/0001-make-netgroup-support-configurable.patch
index 4e3af87..3b0ef5e 100644
--- a/meta-openembedded/meta-oe/recipes-extended/polkit/polkit/0001-make-netgroup-support-configurable.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/polkit/polkit/0001-make-netgroup-support-configurable.patch
@@ -12,16 +12,19 @@
 ---
 Upstream-Status: Pending
 
+Rebase to 0.115
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
  configure.ac                                          | 2 +-
  src/polkitbackend/polkitbackendinteractiveauthority.c | 6 +++++-
- src/polkitbackend/polkitbackendjsauthority.c          | 5 ++---
- 3 files changed, 8 insertions(+), 5 deletions(-)
+ src/polkitbackend/polkitbackendjsauthority.cpp        | 2 ++
+ 3 files changed, 8 insertions(+), 2 deletions(-)
 
 diff --git a/configure.ac b/configure.ac
-index 07982d1..21590b2 100644
+index 8b3e1b1..1c392df 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -158,7 +158,7 @@ AC_CHECK_LIB(expat,XML_ParserCreate,[EXPAT_LIBS="-lexpat"],
+@@ -99,7 +99,7 @@ AC_CHECK_LIB(expat,XML_ParserCreate,[EXPAT_LIBS="-lexpat"],
  	     [AC_MSG_ERROR([Can't find expat library. Please install expat.])])
  AC_SUBST(EXPAT_LIBS)
  
@@ -31,10 +34,10 @@
  if test "x$GCC" = "xyes"; then
    LDFLAGS="-Wl,--as-needed $LDFLAGS"
 diff --git a/src/polkitbackend/polkitbackendinteractiveauthority.c b/src/polkitbackend/polkitbackendinteractiveauthority.c
-index 7019356..cf39d77 100644
+index cb6fdab..de3f752 100644
 --- a/src/polkitbackend/polkitbackendinteractiveauthority.c
 +++ b/src/polkitbackend/polkitbackendinteractiveauthority.c
-@@ -2213,7 +2213,7 @@ get_users_in_group (PolkitIdentity                    *group,
+@@ -2224,7 +2224,7 @@ get_users_in_group (PolkitIdentity                    *group,
   out:
    return ret;
  }
@@ -43,7 +46,7 @@
  static GList *
  get_users_in_net_group (PolkitIdentity                    *group,
                          gboolean                           include_root)
-@@ -2270,6 +2270,8 @@ get_users_in_net_group (PolkitIdentity                    *group,
+@@ -2285,6 +2285,8 @@ get_users_in_net_group (PolkitIdentity                    *group,
    return ret;
  }
  
@@ -52,7 +55,7 @@
  /* ---------------------------------------------------------------------------------------------------- */
  
  static void
-@@ -2355,10 +2357,12 @@ authentication_agent_initiate_challenge (AuthenticationAgent         *agent,
+@@ -2369,10 +2371,12 @@ authentication_agent_initiate_challenge (AuthenticationAgent         *agent,
          {
            user_identities = g_list_concat (user_identities, get_users_in_group (identity, FALSE));
          }
@@ -65,43 +68,26 @@
        else
          {
            g_warning ("Unsupported identity");
-diff --git a/src/polkitbackend/polkitbackendjsauthority.c b/src/polkitbackend/polkitbackendjsauthority.c
-index 097dcc5..e59b3f7 100644
---- a/src/polkitbackend/polkitbackendjsauthority.c
-+++ b/src/polkitbackend/polkitbackendjsauthority.c
-@@ -1498,7 +1498,6 @@ js_polkit_spawn (JSContext  *cx,
- 
- /* ---------------------------------------------------------------------------------------------------- */
- 
--
- static JSBool
- js_polkit_user_is_in_netgroup (JSContext  *cx,
-                                unsigned    argc,
-@@ -1518,6 +1517,7 @@ js_polkit_user_is_in_netgroup (JSContext  *cx,
-   user = JS_EncodeString (cx, user_str);
-   netgroup = JS_EncodeString (cx, netgroup_str);
+diff --git a/src/polkitbackend/polkitbackendjsauthority.cpp b/src/polkitbackend/polkitbackendjsauthority.cpp
+index 517f3c6..6042dd2 100644
+--- a/src/polkitbackend/polkitbackendjsauthority.cpp
++++ b/src/polkitbackend/polkitbackendjsauthority.cpp
+@@ -1502,6 +1502,7 @@ js_polkit_user_is_in_netgroup (JSContext  *cx,
+   user = JS_EncodeString (cx, args[0].toString());
+   netgroup = JS_EncodeString (cx, args[1].toString());
  
 +#if defined HAVE_INNETGR
    if (innetgr (netgroup,
                 NULL,  /* host */
                 user,
-@@ -1525,6 +1525,7 @@ js_polkit_user_is_in_netgroup (JSContext  *cx,
+@@ -1509,6 +1510,7 @@ js_polkit_user_is_in_netgroup (JSContext  *cx,
      {
-       is_in_netgroup =  JS_TRUE;
+       is_in_netgroup =  true;
      }
 +#endif
  
    JS_free (cx, netgroup);
    JS_free (cx, user);
-@@ -1536,8 +1537,6 @@ js_polkit_user_is_in_netgroup (JSContext  *cx,
-   return ret;
- }
- 
--
--
- /* ---------------------------------------------------------------------------------------------------- */
- 
- typedef struct
 -- 
-2.7.0
+2.7.4
 
diff --git a/meta-openembedded/meta-oe/recipes-extended/polkit/polkit/polkit-1_pam.patch b/meta-openembedded/meta-oe/recipes-extended/polkit/polkit/polkit-1_pam.patch
index 74647ef..c491abf 100644
--- a/meta-openembedded/meta-oe/recipes-extended/polkit/polkit/polkit-1_pam.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/polkit/polkit/polkit-1_pam.patch
@@ -4,9 +4,18 @@
 
 Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
 
---- a/configure.ac	2011-03-04 02:26:20.000000000 +0800
-+++ b/configure.ac.new	2011-07-18 10:14:12.516818852 +0800
-@@ -350,10 +350,10 @@
+Upstream-Status: Inappropriate [oe specific]
+Rebase to 0.115
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ configure.ac | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 36df239..8b3e1b1 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -471,10 +471,10 @@ elif test x$with_os_type = xfreebsd -o x$with_os_type = xnetbsd; then
      PAM_FILE_INCLUDE_PASSWORD=system
      PAM_FILE_INCLUDE_SESSION=system
  else
@@ -21,3 +30,6 @@
  fi
  
  AC_SUBST(PAM_FILE_INCLUDE_AUTH)
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/polkit/polkit_0.113.bb b/meta-openembedded/meta-oe/recipes-extended/polkit/polkit_0.113.bb
deleted file mode 100644
index f34928f..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/polkit/polkit_0.113.bb
+++ /dev/null
@@ -1,51 +0,0 @@
-SUMMARY = "PolicyKit Authorization Framework"
-DESCRIPTION = "The polkit package is an application-level toolkit for defining and handling the policy that allows unprivileged processes to speak to privileged processes."
-HOMEPAGE = "http://www.freedesktop.org/wiki/Software/polkit"
-LICENSE = "LGPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=155db86cdbafa7532b41f390409283eb \
-                    file://src/polkit/polkit.h;beginline=1;endline=20;md5=0a8630b0133176d0504c87a0ded39db4"
-
-DEPENDS = "expat glib-2.0 intltool-native mozjs"
-
-inherit autotools gtk-doc pkgconfig useradd systemd gobject-introspection
-
-PACKAGECONFIG = "${@bb.utils.filter('DISTRO_FEATURES', 'pam', d)} \
-                 ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', \
-                    bb.utils.contains('DISTRO_FEATURES', 'x11', 'consolekit', '', d), d)} \
-                "
-
-PACKAGECONFIG[pam] = "--with-authfw=pam,--with-authfw=shadow,libpam,libpam"
-PACKAGECONFIG[systemd] = "--enable-libsystemd-login=yes --with-systemdsystemunitdir=${systemd_unitdir}/system/,--enable-libsystemd-login=no --with-systemdsystemunitdir=,systemd"
-# there is no --enable/--disable option for consolekit and it's not picked by shlibs, so add it to RDEPENDS
-PACKAGECONFIG[consolekit] = ",,,consolekit"
-
-PAM_SRC_URI = "file://polkit-1_pam.patch"
-SRC_URI = "http://www.freedesktop.org/software/polkit/releases/polkit-${PV}.tar.gz \
-    file://0001-make-netgroup-support-configurable.patch \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${PAM_SRC_URI}', '', d)} \
-"
-SRC_URI[md5sum] = "4b77776c9e4f897dcfe03b2c34198edf"
-SRC_URI[sha256sum] = "e1c095093c654951f78f8618d427faf91cf62abdefed98de40ff65eca6413c81"
-
-EXTRA_OECONF = "--with-os-type=moblin --disable-man-pages"
-
-do_compile_prepend () {
-    export GIR_EXTRA_LIBS_PATH="${B}/src/polkit/.libs"
-}
-
-PACKAGES =+ "${PN}-examples"
-
-FILES_${PN}_append = " \
-    ${libdir}/${BPN}-1 \
-    ${nonarch_libdir}/${BPN}-1 \
-    ${datadir}/dbus-1 \
-    ${datadir}/${BPN}-1 \
-"
-
-FILES_${PN}-examples = "${bindir}/*example*"
-
-USERADD_PACKAGES = "${PN}"
-USERADD_PARAM_${PN} = "--system --no-create-home --user-group --home-dir ${sysconfdir}/${BPN}-1 polkitd"
-
-SYSTEMD_SERVICE_${PN} = "${BPN}.service"
-SYSTEMD_AUTO_ENABLE = "disable"
diff --git a/meta-openembedded/meta-oe/recipes-extended/polkit/polkit_0.115.bb b/meta-openembedded/meta-oe/recipes-extended/polkit/polkit_0.115.bb
new file mode 100644
index 0000000..ad0f66a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/polkit/polkit_0.115.bb
@@ -0,0 +1,55 @@
+SUMMARY = "PolicyKit Authorization Framework"
+DESCRIPTION = "The polkit package is an application-level toolkit for defining and handling the policy that allows unprivileged processes to speak to privileged processes."
+HOMEPAGE = "http://www.freedesktop.org/wiki/Software/polkit"
+LICENSE = "LGPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=155db86cdbafa7532b41f390409283eb \
+                    file://src/polkit/polkit.h;beginline=1;endline=20;md5=0a8630b0133176d0504c87a0ded39db4"
+
+DEPENDS = "expat glib-2.0 intltool-native mozjs"
+
+inherit autotools gtk-doc pkgconfig useradd systemd gobject-introspection
+
+PACKAGECONFIG = "${@bb.utils.filter('DISTRO_FEATURES', 'pam', d)} \
+                 ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', \
+                    bb.utils.contains('DISTRO_FEATURES', 'x11', 'consolekit', '', d), d)} \
+                "
+
+PACKAGECONFIG[pam] = "--with-authfw=pam,--with-authfw=shadow,libpam,libpam"
+PACKAGECONFIG[systemd] = "--enable-libsystemd-login=yes --with-systemdsystemunitdir=${systemd_unitdir}/system/,--enable-libsystemd-login=no --with-systemdsystemunitdir=,systemd"
+# there is no --enable/--disable option for consolekit and it's not picked by shlibs, so add it to RDEPENDS
+PACKAGECONFIG[consolekit] = ",,,consolekit"
+
+PAM_SRC_URI = "file://polkit-1_pam.patch"
+SRC_URI = "http://www.freedesktop.org/software/polkit/releases/polkit-${PV}.tar.gz \
+    file://0001-make-netgroup-support-configurable.patch \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${PAM_SRC_URI}', '', d)} \
+"
+SRC_URI[md5sum] = "f03b055d6ae5fc8eac76838c7d83d082"
+SRC_URI[sha256sum] = "2f87ecdabfbd415c6306673ceadc59846f059b18ef2fce42bac63fe283f12131"
+
+EXTRA_OECONF = "--with-os-type=moblin \
+                --disable-man-pages \
+                --disable-libelogind \
+               "
+
+do_compile_prepend () {
+    export GIR_EXTRA_LIBS_PATH="${B}/src/polkit/.libs"
+}
+
+PACKAGES =+ "${PN}-examples"
+
+FILES_${PN}_append = " \
+    ${libdir}/${BPN}-1 \
+    ${nonarch_libdir}/${BPN}-1 \
+    ${datadir}/dbus-1 \
+    ${datadir}/${BPN}-1 \
+    ${datadir}/gettext \
+"
+
+FILES_${PN}-examples = "${bindir}/*example*"
+
+USERADD_PACKAGES = "${PN}"
+USERADD_PARAM_${PN} = "--system --no-create-home --user-group --home-dir ${sysconfdir}/${BPN}-1 polkitd"
+
+SYSTEMD_SERVICE_${PN} = "${BPN}.service"
+SYSTEMD_AUTO_ENABLE = "disable"
diff --git a/meta-openembedded/meta-oe/recipes-extended/redis/redis/hiredis-update-Makefile-to-add-symbols-to-staticlib.patch b/meta-openembedded/meta-oe/recipes-extended/redis/redis/hiredis-update-Makefile-to-add-symbols-to-staticlib.patch
deleted file mode 100644
index 2b3b587..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/redis/redis/hiredis-update-Makefile-to-add-symbols-to-staticlib.patch
+++ /dev/null
@@ -1,19 +0,0 @@
---- redis-3.0.2/deps/hiredis/Makefile.orig	2016-05-06 19:36:26.179003036 -0700
-+++ redis-3.0.2/deps/hiredis/Makefile	2016-05-06 19:40:15.341340736 -0700
-@@ -25,7 +25,7 @@
- 
- # Fallback to gcc when $CC is not in $PATH.
- CC?=$(shell sh -c 'type $(CC) >/dev/null 2>/dev/null && echo $(CC) || echo gcc')
--OPTIMIZATION?=-O3
-+OPTIMIZATION?=-O2
- WARNINGS=-Wall -W -Wstrict-prototypes -Wwrite-strings
- DEBUG?= -g -ggdb
- REAL_CFLAGS=$(OPTIMIZATION) -fPIC $(CFLAGS) $(WARNINGS) $(DEBUG) $(ARCH)
-@@ -68,6 +68,7 @@
- 
- $(STLIBNAME): $(OBJ)
- 	$(STLIB_MAKE_CMD) $(OBJ)
-+	$(RANLIB) $@
- 
- dynamic: $(DYLIBNAME)
- static: $(STLIBNAME)
diff --git a/meta-openembedded/meta-oe/recipes-extended/redis/redis/hiredis-use-default-CC-if-it-is-set.patch b/meta-openembedded/meta-oe/recipes-extended/redis/redis/hiredis-use-default-CC-if-it-is-set.patch
index f9f1c0d..421f306 100644
--- a/meta-openembedded/meta-oe/recipes-extended/redis/redis/hiredis-use-default-CC-if-it-is-set.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/redis/redis/hiredis-use-default-CC-if-it-is-set.patch
@@ -8,23 +8,23 @@
 
 Signed-off-by: Venture Research <tech@ventureresearch.com>
 
-Update to work with 3.0.x
-Signed-off-by: Armin Kuster <akuster808@gmail.com>
+Update to work with 4.0.8
+Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
 
 ---
  deps/hiredis/Makefile | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-Index: deps/hiredis/Makefile
-===================================================================
+diff --git a/deps/hiredis/Makefile b/deps/hiredis/Makefile
+index 9a4de836..271c06ba 100644
 --- a/deps/hiredis/Makefile
 +++ b/deps/hiredis/Makefile
-@@ -24,7 +24,7 @@ endef
+@@ -36,7 +36,7 @@ endef
  export REDIS_TEST_CONFIG
  
  # Fallback to gcc when $CC is not in $PATH.
 -CC:=$(shell sh -c 'type $(CC) >/dev/null 2>/dev/null && echo $(CC) || echo gcc')
 +CC?=$(shell sh -c 'type $(CC) >/dev/null 2>/dev/null && echo $(CC) || echo gcc')
+ CXX:=$(shell sh -c 'type $(CXX) >/dev/null 2>/dev/null && echo $(CXX) || echo g++')
  OPTIMIZATION?=-O3
  WARNINGS=-Wall -W -Wstrict-prototypes -Wwrite-strings
- DEBUG?= -g -ggdb
diff --git a/meta-openembedded/meta-oe/recipes-extended/redis/redis/oe-use-libc-malloc.patch b/meta-openembedded/meta-oe/recipes-extended/redis/redis/oe-use-libc-malloc.patch
index b768a77..6745f3d 100644
--- a/meta-openembedded/meta-oe/recipes-extended/redis/redis/oe-use-libc-malloc.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/redis/redis/oe-use-libc-malloc.patch
@@ -11,15 +11,15 @@
 
 Signed-off-by: Venture Research <tech@ventureresearch.com>
 
-Update to work with 3.0.x
-Signed-off-by: Armin Kuster <akuster808@gmail.com>
+Update to work with 4.0.8
+Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
 
 ---
  src/Makefile | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-Index: src/Makefile
-===================================================================
+diff --git a/src/Makefile b/src/Makefile
+index 86e0b3fe..a810180b 100644
 --- a/src/Makefile
 +++ b/src/Makefile
 @@ -13,7 +13,8 @@
@@ -29,6 +29,6 @@
 -uname_S := $(shell sh -c 'uname -s 2>/dev/null || echo not')
 +# use fake uname option to force use of generic libc
 +uname_S := "USE_LIBC_MALLOC"
+ uname_M := $(shell sh -c 'uname -m 2>/dev/null || echo not')
  OPTIMIZATION?=-O2
  DEPENDENCY_TARGETS=hiredis linenoise lua
- 
diff --git a/meta-openembedded/meta-oe/recipes-extended/redis/redis/redis.conf b/meta-openembedded/meta-oe/recipes-extended/redis/redis/redis.conf
index ab024ad..75037d6 100644
--- a/meta-openembedded/meta-oe/recipes-extended/redis/redis/redis.conf
+++ b/meta-openembedded/meta-oe/recipes-extended/redis/redis/redis.conf
@@ -1,4 +1,9 @@
-# Redis configuration file example
+# Redis configuration file example.
+#
+# Note that in order to read the configuration file, Redis must be
+# started with the file path as first argument:
+#
+# ./redis-server /path/to/redis.conf
 
 # Note on units: when memory size is needed, it is possible to specify
 # it in the usual form of 1k 5GB 4M and so forth:
@@ -12,48 +17,160 @@
 #
 # units are case insensitive so 1GB 1Gb 1gB are all the same.
 
-# By default Redis does not run as a daemon. Use 'yes' if you need it.
-# Note that Redis will write a pid file in /var/run/redis.pid when daemonized.
+################################## INCLUDES ###################################
+
+# Include one or more other config files here.  This is useful if you
+# have a standard template that goes to all Redis servers but also need
+# to customize a few per-server settings.  Include files can include
+# other files, so use this wisely.
 #
+# Notice option "include" won't be rewritten by command "CONFIG REWRITE"
+# from admin or Redis Sentinel. Since Redis always uses the last processed
+# line as value of a configuration directive, you'd better put includes
+# at the beginning of this file to avoid overwriting config change at runtime.
+#
+# If instead you are interested in using includes to override configuration
+# options, it is better to use include as the last line.
+#
+# include /path/to/local.conf
+# include /path/to/other.conf
+
+################################## MODULES #####################################
+
+# Load modules at startup. If the server is not able to load modules
+# it will abort. It is possible to use multiple loadmodule directives.
+#
+# loadmodule /path/to/my_module.so
+# loadmodule /path/to/other_module.so
+
+################################## NETWORK #####################################
+
+# By default, if no "bind" configuration directive is specified, Redis listens
+# for connections from all the network interfaces available on the server.
+# It is possible to listen to just one or multiple selected interfaces using
+# the "bind" configuration directive, followed by one or more IP addresses.
+#
+# Examples:
+#
+# bind 192.168.1.100 10.0.0.1
+# bind 127.0.0.1 ::1
+#
+# ~~~ WARNING ~~~ If the computer running Redis is directly exposed to the
+# internet, binding to all the interfaces is dangerous and will expose the
+# instance to everybody on the internet. So by default we uncomment the
+# following bind directive, that will force Redis to listen only into
+# the IPv4 lookback interface address (this means Redis will be able to
+# accept connections only from clients running into the same computer it
+# is running).
+#
+# IF YOU ARE SURE YOU WANT YOUR INSTANCE TO LISTEN TO ALL THE INTERFACES
+# JUST COMMENT THE FOLLOWING LINE.
+# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+bind 127.0.0.1
+
+# Protected mode is a layer of security protection, in order to avoid that
+# Redis instances left open on the internet are accessed and exploited.
+#
+# When protected mode is on and if:
+#
+# 1) The server is not binding explicitly to a set of addresses using the
+#    "bind" directive.
+# 2) No password is configured.
+#
+# The server only accepts connections from clients connecting from the
+# IPv4 and IPv6 loopback addresses 127.0.0.1 and ::1, and from Unix domain
+# sockets.
+#
+# By default protected mode is enabled. You should disable it only if
+# you are sure you want clients from other hosts to connect to Redis
+# even if no authentication is configured, nor a specific set of interfaces
+# are explicitly listed using the "bind" directive.
+protected-mode yes
+
+# Accept connections on the specified port, default is 6379 (IANA #815344).
+# If port 0 is specified Redis will not listen on a TCP socket.
+port 6379
+
+# TCP listen() backlog.
+#
+# In high requests-per-second environments you need an high backlog in order
+# to avoid slow clients connections issues. Note that the Linux kernel
+# will silently truncate it to the value of /proc/sys/net/core/somaxconn so
+# make sure to raise both the value of somaxconn and tcp_max_syn_backlog
+# in order to get the desired effect.
+tcp-backlog 511
+
+# Unix socket.
+#
+# Specify the path for the Unix socket that will be used to listen for
+# incoming connections. There is no default, so Redis will not listen
+# on a unix socket when not specified.
+#
+# unixsocket /tmp/redis.sock
+# unixsocketperm 700
+
+# Close the connection after a client is idle for N seconds (0 to disable)
+timeout 0
+
+# TCP keepalive.
+#
+# If non-zero, use SO_KEEPALIVE to send TCP ACKs to clients in absence
+# of communication. This is useful for two reasons:
+#
+# 1) Detect dead peers.
+# 2) Take the connection alive from the point of view of network
+#    equipment in the middle.
+#
+# On Linux, the specified value (in seconds) is the period used to send ACKs.
+# Note that to close the connection the double of the time is needed.
+# On other kernels the period depends on the kernel configuration.
+#
+# A reasonable value for this option is 300 seconds, which is the new
+# Redis default starting with Redis 3.2.1.
+tcp-keepalive 300
+
+################################# GENERAL #####################################
+
 # OE: run as a daemon.
-#
 daemonize yes
 
+# If you run Redis from upstart or systemd, Redis can interact with your
+# supervision tree. Options:
+#   supervised no      - no supervision interaction
+#   supervised upstart - signal upstart by putting Redis into SIGSTOP mode
+#   supervised systemd - signal systemd by writing READY=1 to $NOTIFY_SOCKET
+#   supervised auto    - detect upstart or systemd method based on
+#                        UPSTART_JOB or NOTIFY_SOCKET environment variables
+# Note: these supervision methods only signal "process is ready."
+#       They do not enable continuous liveness pings back to your supervisor.
+supervised no
+
+# If a pid file is specified, Redis writes it where specified at startup
+# and removes it at exit.
+#
+# When the server runs non daemonized, no pid file is created if none is
+# specified in the configuration. When the server is daemonized, the pid file
+# is used even if not specified, defaulting to "/var/run/redis.pid".
+#
+# Creating a pid file is best effort: if Redis is not able to create it
+# nothing bad happens, the server will start and run normally.
+
 # When running daemonized, Redis writes a pid file in /var/run/redis.pid by
 # default. You can specify a custom pid file location here.
 pidfile /var/run/redis.pid
 
-# Accept connections on the specified port, default is 6379.
-# If port 0 is specified Redis will not listen on a TCP socket.
-port 6379
-
-# If you want you can bind a single interface, if the bind option is not
-# specified all the interfaces will listen for incoming connections.
-#
-bind 127.0.0.1
-
-# Specify the path for the unix socket that will be used to listen for
-# incoming connections. There is no default, so Redis will not listen
-# on a unix socket when not specified.
-#
-# unixsocket /tmp/redis.sock
-# unixsocketperm 755
-
-# Close the connection after a client is idle for N seconds (0 to disable)
-timeout 0
-
-# Set server verbosity to 'debug'
-# it can be one of:
+# Specify the server verbosity level.
+# This can be one of:
 # debug (a lot of information, useful for development/testing)
 # verbose (many rarely useful info, but not a mess like the debug level)
 # notice (moderately verbose, what you want in production probably)
 # warning (only very important / critical messages are logged)
 loglevel notice
 
-# Specify the log file name. Also 'stdout' can be used to force
+# Specify the log file name. Also the empty string can be used to force
 # Redis to log on the standard output. Note that if you use standard
 # output for logging but daemonize, logs will be sent to /dev/null
-# logfile /var/log/redis.log
+logfile ""
 
 # To enable logging to the system logger, just set 'syslog-enabled' to yes,
 # and optionally update the other syslog parameters to suit your needs.
@@ -62,7 +179,7 @@
 # Specify the syslog identity.
 syslog-ident redis
 
-# Specify the syslog facility.  Must be USER or between LOCAL0-LOCAL7.
+# Specify the syslog facility. Must be USER or between LOCAL0-LOCAL7.
 # syslog-facility local0
 
 # Set the number of databases. The default database is DB 0, you can select
@@ -70,7 +187,15 @@
 # dbid is a number between 0 and 'databases'-1
 databases 16
 
-################################ SNAPSHOTTING  #################################
+# By default Redis shows an ASCII art logo only when started to log to the
+# standard output and if the standard output is a TTY. Basically this means
+# that normally a logo is displayed only in interactive sessions.
+#
+# However it is possible to force the pre-4.0 behavior and always show a
+# ASCII art logo in startup logs by setting the following option to yes.
+always-show-logo yes
+
+################################ SNAPSHOTTING  ################################
 #
 # Save the DB on disk:
 #
@@ -84,7 +209,7 @@
 #   after 300 sec (5 min) if at least 10 keys changed
 #   after 60 sec if at least 10000 keys changed
 #
-#   Note: you can disable saving at all commenting all the "save" lines.
+#   Note: you can disable saving completely by commenting out all "save" lines.
 #
 #   It is also possible to remove all the previously configured save
 #   points by adding a save directive with a single empty string argument
@@ -103,16 +228,16 @@
 
 # By default Redis will stop accepting writes if RDB snapshots are enabled
 # (at least one save point) and the latest background save failed.
-# This will make the user aware (in an hard way) that data is not persisting
+# This will make the user aware (in a hard way) that data is not persisting
 # on disk properly, otherwise chances are that no one will notice and some
-# distater will happen.
+# disaster will happen.
 #
 # If the background saving process will start working again Redis will
 # automatically allow writes again.
 #
 # However if you have setup your proper monitoring of the Redis server
 # and persistence, you may want to disable this feature so that Redis will
-# continue to work as usually even if there are problems with disk,
+# continue to work as usual even if there are problems with disk,
 # permissions, and so forth.
 stop-writes-on-bgsave-error yes
 
@@ -122,7 +247,7 @@
 # the dataset will likely be bigger if you have compressible values or keys.
 rdbcompression yes
 
-# Since verison 5 of RDB a CRC64 checksum is placed at the end of the file.
+# Since version 5 of RDB a CRC64 checksum is placed at the end of the file.
 # This makes the format more resistant to corruption but there is a performance
 # hit to pay (around 10%) when saving and loading RDB files, so you can disable it
 # for maximum performances.
@@ -138,18 +263,27 @@
 #
 # The DB will be written inside this directory, with the filename specified
 # above using the 'dbfilename' configuration directive.
-# 
-# Also the Append Only File will be created inside this directory.
-# 
+#
+# The Append Only File will also be created inside this directory.
+#
 # Note that you must specify a directory here, not a file name.
 dir /var/lib/redis/
 
 ################################# REPLICATION #################################
 
 # Master-Slave replication. Use slaveof to make a Redis instance a copy of
-# another Redis server. Note that the configuration is local to the slave
-# so for example it is possible to configure the slave to save the DB with a
-# different interval, or to listen to another port, and so on.
+# another Redis server. A few things to understand ASAP about Redis replication.
+#
+# 1) Redis replication is asynchronous, but you can configure a master to
+#    stop accepting writes if it appears to be not connected with at least
+#    a given number of slaves.
+# 2) Redis slaves are able to perform a partial resynchronization with the
+#    master if the replication link is lost for a relatively small amount of
+#    time. You may want to configure the replication backlog size (see the next
+#    sections of this file) with a sensible value depending on your needs.
+# 3) Replication is automatic and does not need user intervention. After a
+#    network partition slaves automatically try to reconnect to masters
+#    and resynchronize with them.
 #
 # slaveof <masterip> <masterport>
 
@@ -160,14 +294,14 @@
 #
 # masterauth <master-password>
 
-# When a slave lost the connection with the master, or when the replication
+# When a slave loses its connection with the master, or when the replication
 # is still in progress, the slave can act in two different ways:
 #
 # 1) if slave-serve-stale-data is set to 'yes' (the default) the slave will
 #    still reply to client requests, possibly with out of date data, or the
 #    data set may just be empty if this is the first synchronization.
 #
-# 2) if slave-serve-stale data is set to 'no' the slave will reply with
+# 2) if slave-serve-stale-data is set to 'no' the slave will reply with
 #    an error "SYNC with master in progress" to all the kind of commands
 #    but to INFO and SLAVEOF.
 #
@@ -184,19 +318,65 @@
 # Note: read only slaves are not designed to be exposed to untrusted clients
 # on the internet. It's just a protection layer against misuse of the instance.
 # Still a read only slave exports by default all the administrative commands
-# such as CONFIG, DEBUG, and so forth. To a limited extend you can improve
+# such as CONFIG, DEBUG, and so forth. To a limited extent you can improve
 # security of read only slaves using 'rename-command' to shadow all the
 # administrative / dangerous commands.
 slave-read-only yes
 
+# Replication SYNC strategy: disk or socket.
+#
+# -------------------------------------------------------
+# WARNING: DISKLESS REPLICATION IS EXPERIMENTAL CURRENTLY
+# -------------------------------------------------------
+#
+# New slaves and reconnecting slaves that are not able to continue the replication
+# process just receiving differences, need to do what is called a "full
+# synchronization". An RDB file is transmitted from the master to the slaves.
+# The transmission can happen in two different ways:
+#
+# 1) Disk-backed: The Redis master creates a new process that writes the RDB
+#                 file on disk. Later the file is transferred by the parent
+#                 process to the slaves incrementally.
+# 2) Diskless: The Redis master creates a new process that directly writes the
+#              RDB file to slave sockets, without touching the disk at all.
+#
+# With disk-backed replication, while the RDB file is generated, more slaves
+# can be queued and served with the RDB file as soon as the current child producing
+# the RDB file finishes its work. With diskless replication instead once
+# the transfer starts, new slaves arriving will be queued and a new transfer
+# will start when the current one terminates.
+#
+# When diskless replication is used, the master waits a configurable amount of
+# time (in seconds) before starting the transfer in the hope that multiple slaves
+# will arrive and the transfer can be parallelized.
+#
+# With slow disks and fast (large bandwidth) networks, diskless replication
+# works better.
+repl-diskless-sync no
+
+# When diskless replication is enabled, it is possible to configure the delay
+# the server waits in order to spawn the child that transfers the RDB via socket
+# to the slaves.
+#
+# This is important since once the transfer starts, it is not possible to serve
+# new slaves arriving, that will be queued for the next RDB transfer, so the server
+# waits a delay in order to let more slaves arrive.
+#
+# The delay is specified in seconds, and by default is 5 seconds. To disable
+# it entirely just set it to 0 seconds and the transfer will start ASAP.
+repl-diskless-sync-delay 5
+
 # Slaves send PINGs to server in a predefined interval. It's possible to change
 # this interval with the repl_ping_slave_period option. The default value is 10
 # seconds.
 #
 # repl-ping-slave-period 10
 
-# The following option sets a timeout for both Bulk transfer I/O timeout and
-# master data or ping response timeout. The default value is 60 seconds.
+# The following option sets the replication timeout for:
+#
+# 1) Bulk transfer I/O during SYNC, from the point of view of slave.
+# 2) Master timeout from the point of view of slaves (data, pings).
+# 3) Slave timeout from the point of view of masters (REPLCONF ACK pings).
 #
 # It is important to make sure that this value is greater than the value
 # specified for repl-ping-slave-period otherwise a timeout will be detected
@@ -204,13 +384,54 @@
 #
 # repl-timeout 60
 
+# Disable TCP_NODELAY on the slave socket after SYNC?
+#
+# If you select "yes" Redis will use a smaller number of TCP packets and
+# less bandwidth to send data to slaves. But this can add a delay for
+# the data to appear on the slave side, up to 40 milliseconds with
+# Linux kernels using a default configuration.
+#
+# If you select "no" the delay for data to appear on the slave side will
+# be reduced but more bandwidth will be used for replication.
+#
+# By default we optimize for low latency, but in very high traffic conditions
+# or when the master and slaves are many hops away, turning this to "yes" may
+# be a good idea.
+repl-disable-tcp-nodelay no
+
+# Set the replication backlog size. The backlog is a buffer that accumulates
+# slave data when slaves are disconnected for some time, so that when a slave
+# wants to reconnect again, often a full resync is not needed, but a partial
+# resync is enough, just passing the portion of data the slave missed while
+# disconnected.
+#
+# The bigger the replication backlog, the longer the time the slave can be
+# disconnected and later be able to perform a partial resynchronization.
+#
+# The backlog is only allocated once there is at least a slave connected.
+#
+# repl-backlog-size 1mb
+
+# After a master has no longer connected slaves for some time, the backlog
+# will be freed. The following option configures the amount of seconds that
+# need to elapse, starting from the time the last slave disconnected, for
+# the backlog buffer to be freed.
+#
+# Note that slaves never free the backlog for timeout, since they may be
+# promoted to masters later, and should be able to correctly "partially
+# resynchronize" with the slaves: hence they should always accumulate backlog.
+#
+# A value of 0 means to never release the backlog.
+#
+# repl-backlog-ttl 3600
+
 # The slave priority is an integer number published by Redis in the INFO output.
 # It is used by Redis Sentinel in order to select a slave to promote into a
 # master if the master is no longer working correctly.
 #
 # A slave with a low priority number is considered better for promotion, so
 # for instance if there are three slaves with priority 10, 100, 25 Sentinel will
-# pick the one wtih priority 10, that is the lowest.
+# pick the one with priority 10, that is the lowest.
 #
 # However a special priority of 0 marks the slave as not able to perform the
 # role of master, so a slave with priority of 0 will never be selected by
@@ -219,6 +440,57 @@
 # By default the priority is 100.
 slave-priority 100
 
+# It is possible for a master to stop accepting writes if there are less than
+# N slaves connected, having a lag less or equal than M seconds.
+#
+# The N slaves need to be in "online" state.
+#
+# The lag in seconds, that must be <= the specified value, is calculated from
+# the last ping received from the slave, that is usually sent every second.
+#
+# This option does not GUARANTEE that N replicas will accept the write, but
+# will limit the window of exposure for lost writes in case not enough slaves
+# are available, to the specified number of seconds.
+#
+# For example to require at least 3 slaves with a lag <= 10 seconds use:
+#
+# min-slaves-to-write 3
+# min-slaves-max-lag 10
+#
+# Setting one or the other to 0 disables the feature.
+#
+# By default min-slaves-to-write is set to 0 (feature disabled) and
+# min-slaves-max-lag is set to 10.
+
+# A Redis master is able to list the address and port of the attached
+# slaves in different ways. For example the "INFO replication" section
+# offers this information, which is used, among other tools, by
+# Redis Sentinel in order to discover slave instances.
+# Another place where this info is available is in the output of the
+# "ROLE" command of a master.
+#
+# The listed IP and address normally reported by a slave is obtained
+# in the following way:
+#
+#   IP: The address is auto detected by checking the peer address
+#   of the socket used by the slave to connect with the master.
+#
+#   Port: The port is communicated by the slave during the replication
+#   handshake, and is normally the port that the slave is using to
+#   list for connections.
+#
+# However when port forwarding or Network Address Translation (NAT) is
+# used, the slave may be actually reachable via different IP and port
+# pairs. The following two options can be used by a slave in order to
+# report to its master a specific set of IP and port, so that both INFO
+# and ROLE will report those values.
+#
+# There is no need to use both the options if you need to override just
+# the port or the IP address.
+#
+# slave-announce-ip 5.5.5.5
+# slave-announce-port 1234
+
 ################################## SECURITY ###################################
 
 # Require clients to issue AUTH <PASSWORD> before processing any other
@@ -227,7 +499,7 @@
 #
 # This should stay commented out for backward compatibility and because most
 # people do not need auth (e.g. they run their own servers).
-# 
+#
 # Warning: since Redis is pretty fast an outside user can try up to
 # 150k passwords per second against a good box. This means that you should
 # use a very strong password otherwise it will be very easy to break.
@@ -238,23 +510,26 @@
 #
 # It is possible to change the name of dangerous commands in a shared
 # environment. For instance the CONFIG command may be renamed into something
-# of hard to guess so that it will be still available for internal-use
-# tools but not available for general clients.
+# hard to guess so that it will still be available for internal-use tools
+# but not available for general clients.
 #
 # Example:
 #
 # rename-command CONFIG b840fc02d524045429941cc15f59e41cb7be6c52
 #
-# It is also possible to completely kill a command renaming it into
+# It is also possible to completely kill a command by renaming it into
 # an empty string:
 #
 # rename-command CONFIG ""
+#
+# Please note that changing the name of commands that are logged into the
+# AOF file or transmitted to slaves may cause problems.
 
-################################### LIMITS ####################################
+################################### CLIENTS ####################################
 
 # Set the max number of connected clients at the same time. By default
 # this limit is set to 10000 clients, however if the Redis server is not
-# able ot configure the process file limit to allow for the specified limit
+# able to configure the process file limit to allow for the specified limit
 # the max number of allowed clients is set to the current file limit
 # minus 32 (as Redis reserves a few file descriptors for internal uses).
 #
@@ -263,17 +538,19 @@
 #
 # maxclients 10000
 
-# Don't use more memory than the specified amount of bytes.
+############################## MEMORY MANAGEMENT ################################
+
+# Set a memory usage limit to the specified amount of bytes.
 # When the memory limit is reached Redis will try to remove keys
-# accordingly to the eviction policy selected (see maxmemmory-policy).
+# according to the eviction policy selected (see maxmemory-policy).
 #
 # If Redis can't remove keys according to the policy, or if the policy is
 # set to 'noeviction', Redis will start to reply with errors to commands
 # that would use more memory, like SET, LPUSH, and so on, and will continue
 # to reply to read-only commands like GET.
 #
-# This option is usually useful when using Redis as an LRU cache, or to set
-# an hard memory limit for an instance (using the 'noeviction' policy).
+# This option is usually useful when using Redis as an LRU or LFU cache, or to
+# set a hard memory limit for an instance (using the 'noeviction' policy).
 #
 # WARNING: If you have slaves attached to an instance with maxmemory on,
 # the size of the output buffers needed to feed the slaves are subtracted
@@ -289,19 +566,27 @@
 # maxmemory <bytes>
 
 # MAXMEMORY POLICY: how Redis will select what to remove when maxmemory
-# is reached? You can select among five behavior:
-# 
-# volatile-lru -> remove the key with an expire set using an LRU algorithm
-# allkeys-lru -> remove any key accordingly to the LRU algorithm
-# volatile-random -> remove a random key with an expire set
-# allkeys-random -> remove a random key, any key
-# volatile-ttl -> remove the key with the nearest expire time (minor TTL)
-# noeviction -> don't expire at all, just return an error on write operations
-# 
-# Note: with all the kind of policies, Redis will return an error on write
-#       operations, when there are not suitable keys for eviction.
+# is reached. You can select among five behaviors:
 #
-#       At the date of writing this commands are: set setnx setex append
+# volatile-lru -> Evict using approximated LRU among the keys with an expire set.
+# allkeys-lru -> Evict any key using approximated LRU.
+# volatile-lfu -> Evict using approximated LFU among the keys with an expire set.
+# allkeys-lfu -> Evict any key using approximated LFU.
+# volatile-random -> Remove a random key among the ones with an expire set.
+# allkeys-random -> Remove a random key, any key.
+# volatile-ttl -> Remove the key with the nearest expire time (minor TTL)
+# noeviction -> Don't evict anything, just return an error on write operations.
+#
+# LRU means Least Recently Used
+# LFU means Least Frequently Used
+#
+# Both LRU, LFU and volatile-ttl are implemented using approximated
+# randomized algorithms.
+#
+# Note: with any of the above policies, Redis will return an error on write
+#       operations, when there are no suitable keys for eviction.
+#
+#       At the date of writing these commands are: set setnx setex append
 #       incr decr rpush lpush rpushx lpushx linsert lset rpoplpush sadd
 #       sinter sinterstore sunion sunionstore sdiff sdiffstore zadd zincrby
 #       zunionstore zinterstore hset hsetnx hmset hincrby incrby decrby
@@ -309,15 +594,67 @@
 #
 # The default is:
 #
-# maxmemory-policy volatile-lru
+# maxmemory-policy noeviction
 
-# LRU and minimal TTL algorithms are not precise algorithms but approximated
-# algorithms (in order to save memory), so you can select as well the sample
-# size to check. For instance for default Redis will check three keys and
-# pick the one that was used less recently, you can change the sample size
-# using the following configuration directive.
+# LRU, LFU and minimal TTL algorithms are not precise algorithms but approximated
+# algorithms (in order to save memory), so you can tune it for speed or
+# accuracy. For default Redis will check five keys and pick the one that was
+# used less recently, you can change the sample size using the following
+# configuration directive.
 #
-# maxmemory-samples 3
+# The default of 5 produces good enough results. 10 Approximates very closely
+# true LRU but costs more CPU. 3 is faster but not very accurate.
+#
+# maxmemory-samples 5
+
+############################# LAZY FREEING ####################################
+
+# Redis has two primitives to delete keys. One is called DEL and is a blocking
+# deletion of the object. It means that the server stops processing new commands
+# in order to reclaim all the memory associated with an object in a synchronous
+# way. If the key deleted is associated with a small object, the time needed
+# in order to execute the DEL command is very small and comparable to most other
+# O(1) or O(log_N) commands in Redis. However if the key is associated with an
+# aggregated value containing millions of elements, the server can block for
+# a long time (even seconds) in order to complete the operation.
+#
+# For the above reasons Redis also offers non blocking deletion primitives
+# such as UNLINK (non blocking DEL) and the ASYNC option of FLUSHALL and
+# FLUSHDB commands, in order to reclaim memory in background. Those commands
+# are executed in constant time. Another thread will incrementally free the
+# object in the background as fast as possible.
+#
+# DEL, UNLINK and ASYNC option of FLUSHALL and FLUSHDB are user-controlled.
+# It's up to the design of the application to understand when it is a good
+# idea to use one or the other. However the Redis server sometimes has to
+# delete keys or flush the whole database as a side effect of other operations.
+# Specifically Redis deletes objects independently of a user call in the
+# following scenarios:
+#
+# 1) On eviction, because of the maxmemory and maxmemory policy configurations,
+#    in order to make room for new data, without going over the specified
+#    memory limit.
+# 2) Because of expire: when a key with an associated time to live (see the
+#    EXPIRE command) must be deleted from memory.
+# 3) Because of a side effect of a command that stores data on a key that may
+#    already exist. For example the RENAME command may delete the old key
+#    content when it is replaced with another one. Similarly SUNIONSTORE
+#    or SORT with STORE option may delete existing keys. The SET command
+#    itself removes any old content of the specified key in order to replace
+#    it with the specified string.
+# 4) During replication, when a slave performs a full resynchronization with
+#    its master, the content of the whole database is removed in order to
+#    load the RDB file just transfered.
+#
+# In all the above cases the default is to delete objects in a blocking way,
+# like if DEL was called. However you can configure each case specifically
+# in order to instead release memory in a non-blocking way like if UNLINK
+# was called, using the following configuration directives:
+
+lazyfree-lazy-eviction no
+lazyfree-lazy-expire no
+lazyfree-lazy-server-del no
+slave-lazy-flush no
 
 ############################## APPEND ONLY MODE ###############################
 
@@ -339,24 +676,24 @@
 #
 # Please check http://redis.io/topics/persistence for more information.
 
-#
 # OE: changed default to enable this
 appendonly yes
 
 # The name of the append only file (default: "appendonly.aof")
-# appendfilename appendonly.aof
+
+appendfilename "appendonly.aof"
 
 # The fsync() call tells the Operating System to actually write data on disk
-# instead to wait for more data in the output buffer. Some OS will really flush 
+# instead of waiting for more data in the output buffer. Some OS will really flush
 # data on disk, some other OS will just try to do it ASAP.
 #
 # Redis supports three different modes:
 #
 # no: don't fsync, just let the OS flush the data when it wants. Faster.
-# always: fsync after every write to the append only log . Slow, Safest.
+# always: fsync after every write to the append only log. Slow, Safest.
 # everysec: fsync only one time every second. Compromise.
 #
-# The default is "everysec" that's usually the right compromise between
+# The default is "everysec", as that's usually the right compromise between
 # speed and data safety. It's up to you to understand if you can relax this to
 # "no" that will let the operating system flush the output buffer when
 # it wants, for better performances (but if you can live with the idea of
@@ -384,21 +721,22 @@
 # that will prevent fsync() from being called in the main process while a
 # BGSAVE or BGREWRITEAOF is in progress.
 #
-# This means that while another child is saving the durability of Redis is
-# the same as "appendfsync none", that in practical terms means that it is
-# possible to lost up to 30 seconds of log in the worst scenario (with the
+# This means that while another child is saving, the durability of Redis is
+# the same as "appendfsync none". In practical terms, this means that it is
+# possible to lose up to 30 seconds of log in the worst scenario (with the
 # default Linux settings).
-# 
+#
 # If you have latency problems turn this to "yes". Otherwise leave it as
 # "no" that is the safest pick from the point of view of durability.
+
 no-appendfsync-on-rewrite no
 
 # Automatic rewrite of the append only file.
 # Redis is able to automatically rewrite the log file implicitly calling
-# BGREWRITEAOF when the AOF log size will growth by the specified percentage.
-# 
+# BGREWRITEAOF when the AOF log size grows by the specified percentage.
+#
 # This is how it works: Redis remembers the size of the AOF file after the
-# latest rewrite (or if no rewrite happened since the restart, the size of
+# latest rewrite (if no rewrite has happened since the restart, the size of
 # the AOF at startup is used).
 #
 # This base size is compared to the current size. If the current size is
@@ -413,6 +751,44 @@
 auto-aof-rewrite-percentage 100
 auto-aof-rewrite-min-size 64mb
 
+# An AOF file may be found to be truncated at the end during the Redis
+# startup process, when the AOF data gets loaded back into memory.
+# This may happen when the system where Redis is running
+# crashes, especially when an ext4 filesystem is mounted without the
+# data=ordered option (however this can't happen when Redis itself
+# crashes or aborts but the operating system still works correctly).
+#
+# Redis can either exit with an error when this happens, or load as much
+# data as possible (the default now) and start if the AOF file is found
+# to be truncated at the end. The following option controls this behavior.
+#
+# If aof-load-truncated is set to yes, a truncated AOF file is loaded and
+# the Redis server starts emitting a log to inform the user of the event.
+# Otherwise if the option is set to no, the server aborts with an error
+# and refuses to start. When the option is set to no, the user requires
+# to fix the AOF file using the "redis-check-aof" utility before to restart
+# the server.
+#
+# Note that if the AOF file will be found to be corrupted in the middle
+# the server will still exit with an error. This option only applies when
+# Redis will try to read more data from the AOF file but not enough bytes
+# will be found.
+aof-load-truncated yes
+
+# When rewriting the AOF file, Redis is able to use an RDB preamble in the
+# AOF file for faster rewrites and recoveries. When this option is turned
+# on the rewritten AOF file is composed of two different stanzas:
+#
+#   [RDB file][AOF tail]
+#
+# When loading Redis recognizes that the AOF file starts with the "REDIS"
+# string and loads the prefixed RDB file, and continues loading the AOF
+# tail.
+#
+# This is currently turned off by default in order to avoid the surprise
+# of a format change, but will at some point be used as the default.
+aof-use-rdb-preamble no
+
 ################################ LUA SCRIPTING  ###############################
 
 # Max execution time of a Lua script in milliseconds.
@@ -421,16 +797,157 @@
 # still in execution after the maximum allowed time and will start to
 # reply to queries with an error.
 #
-# When a long running script exceed the maximum execution time only the
+# When a long running script exceeds the maximum execution time only the
 # SCRIPT KILL and SHUTDOWN NOSAVE commands are available. The first can be
 # used to stop a script that did not yet called write commands. The second
-# is the only way to shut down the server in the case a write commands was
-# already issue by the script but the user don't want to wait for the natural
+# is the only way to shut down the server in the case a write command was
+# already issued by the script but the user doesn't want to wait for the natural
 # termination of the script.
 #
 # Set it to 0 or a negative value for unlimited execution without warnings.
 lua-time-limit 5000
 
+################################ REDIS CLUSTER  ###############################
+#
+# ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+# WARNING EXPERIMENTAL: Redis Cluster is considered to be stable code, however
+# in order to mark it as "mature" we need to wait for a non trivial percentage
+# of users to deploy it in production.
+# ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+#
+# Normal Redis instances can't be part of a Redis Cluster; only nodes that are
+# started as cluster nodes can. In order to start a Redis instance as a
+# cluster node enable the cluster support uncommenting the following:
+#
+# cluster-enabled yes
+
+# Every cluster node has a cluster configuration file. This file is not
+# intended to be edited by hand. It is created and updated by Redis nodes.
+# Every Redis Cluster node requires a different cluster configuration file.
+# Make sure that instances running in the same system do not have
+# overlapping cluster configuration file names.
+#
+# cluster-config-file nodes-6379.conf
+
+# Cluster node timeout is the amount of milliseconds a node must be unreachable
+# for it to be considered in failure state.
+# Most other internal time limits are multiple of the node timeout.
+#
+# cluster-node-timeout 15000
+
+# A slave of a failing master will avoid to start a failover if its data
+# looks too old.
+#
+# There is no simple way for a slave to actually have an exact measure of
+# its "data age", so the following two checks are performed:
+#
+# 1) If there are multiple slaves able to failover, they exchange messages
+#    in order to try to give an advantage to the slave with the best
+#    replication offset (more data from the master processed).
+#    Slaves will try to get their rank by offset, and apply to the start
+#    of the failover a delay proportional to their rank.
+#
+# 2) Every single slave computes the time of the last interaction with
+#    its master. This can be the last ping or command received (if the master
+#    is still in the "connected" state), or the time that elapsed since the
+#    disconnection with the master (if the replication link is currently down).
+#    If the last interaction is too old, the slave will not try to failover
+#    at all.
+#
+# The point "2" can be tuned by user. Specifically a slave will not perform
+# the failover if, since the last interaction with the master, the time
+# elapsed is greater than:
+#
+#   (node-timeout * slave-validity-factor) + repl-ping-slave-period
+#
+# So for example if node-timeout is 30 seconds, and the slave-validity-factor
+# is 10, and assuming a default repl-ping-slave-period of 10 seconds, the
+# slave will not try to failover if it was not able to talk with the master
+# for longer than 310 seconds.
+#
+# A large slave-validity-factor may allow slaves with too old data to failover
+# a master, while a too small value may prevent the cluster from being able to
+# elect a slave at all.
+#
+# For maximum availability, it is possible to set the slave-validity-factor
+# to a value of 0, which means, that slaves will always try to failover the
+# master regardless of the last time they interacted with the master.
+# (However they'll always try to apply a delay proportional to their
+# offset rank).
+#
+# Zero is the only value able to guarantee that when all the partitions heal
+# the cluster will always be able to continue.
+#
+# cluster-slave-validity-factor 10
+
+# Cluster slaves are able to migrate to orphaned masters, that are masters
+# that are left without working slaves. This improves the cluster ability
+# to resist to failures as otherwise an orphaned master can't be failed over
+# in case of failure if it has no working slaves.
+#
+# Slaves migrate to orphaned masters only if there are still at least a
+# given number of other working slaves for their old master. This number
+# is the "migration barrier". A migration barrier of 1 means that a slave
+# will migrate only if there is at least 1 other working slave for its master
+# and so forth. It usually reflects the number of slaves you want for every
+# master in your cluster.
+#
+# Default is 1 (slaves migrate only if their masters remain with at least
+# one slave). To disable migration just set it to a very large value.
+# A value of 0 can be set but is useful only for debugging and dangerous
+# in production.
+#
+# cluster-migration-barrier 1
+
+# By default Redis Cluster nodes stop accepting queries if they detect there
+# is at least an hash slot uncovered (no available node is serving it).
+# This way if the cluster is partially down (for example a range of hash slots
+# are no longer covered) all the cluster becomes, eventually, unavailable.
+# It automatically returns available as soon as all the slots are covered again.
+#
+# However sometimes you want the subset of the cluster which is working,
+# to continue to accept queries for the part of the key space that is still
+# covered. In order to do so, just set the cluster-require-full-coverage
+# option to no.
+#
+# cluster-require-full-coverage yes
+
+# In order to setup your cluster make sure to read the documentation
+# available at http://redis.io web site.
+
+########################## CLUSTER DOCKER/NAT support  ########################
+
+# In certain deployments, Redis Cluster nodes address discovery fails, because
+# addresses are NAT-ted or because ports are forwarded (the typical case is
+# Docker and other containers).
+#
+# In order to make Redis Cluster working in such environments, a static
+# configuration where each node knows its public address is needed. The
+# following two options are used for this scope, and are:
+#
+# * cluster-announce-ip
+# * cluster-announce-port
+# * cluster-announce-bus-port
+#
+# Each instruct the node about its address, client port, and cluster message
+# bus port. The information is then published in the header of the bus packets
+# so that other nodes will be able to correctly map the address of the node
+# publishing the information.
+#
+# If the above options are not used, the normal Redis Cluster auto-detection
+# will be used instead.
+#
+# Note that when remapped, the bus port may not be at the fixed offset of
+# clients port + 10000, so you can specify any port and bus-port depending
+# on how they get remapped. If the bus-port is not set, a fixed offset of
+# 10000 will be used as usually.
+#
+# Example:
+#
+# cluster-announce-ip 10.1.1.5
+# cluster-announce-port 6379
+# cluster-announce-bus-port 6380
+
 ################################## SLOW LOG ###################################
 
 # The Redis Slow Log is a system to log queries that exceeded a specified
@@ -439,7 +956,7 @@
 # but just the time needed to actually execute the command (this is the only
 # stage of command execution where the thread is blocked and can not serve
 # other requests in the meantime).
-# 
+#
 # You can configure the slow log with two parameters: one tells Redis
 # what is the execution time, in microseconds, to exceed in order for the
 # command to get logged, and the other parameter is the length of the
@@ -455,6 +972,73 @@
 # You can reclaim memory used by the slow log with SLOWLOG RESET.
 slowlog-max-len 128
 
+################################ LATENCY MONITOR ##############################
+
+# The Redis latency monitoring subsystem samples different operations
+# at runtime in order to collect data related to possible sources of
+# latency of a Redis instance.
+#
+# Via the LATENCY command this information is available to the user that can
+# print graphs and obtain reports.
+#
+# The system only logs operations that were performed in a time equal or
+# greater than the amount of milliseconds specified via the
+# latency-monitor-threshold configuration directive. When its value is set
+# to zero, the latency monitor is turned off.
+#
+# By default latency monitoring is disabled since it is mostly not needed
+# if you don't have latency issues, and collecting data has a performance
+# impact, that while very small, can be measured under big load. Latency
+# monitoring can easily be enabled at runtime using the command
+# "CONFIG SET latency-monitor-threshold <milliseconds>" if needed.
+latency-monitor-threshold 0
+
+############################# EVENT NOTIFICATION ##############################
+
+# Redis can notify Pub/Sub clients about events happening in the key space.
+# This feature is documented at http://redis.io/topics/notifications
+#
+# For instance if keyspace events notification is enabled, and a client
+# performs a DEL operation on key "foo" stored in the Database 0, two
+# messages will be published via Pub/Sub:
+#
+# PUBLISH __keyspace@0__:foo del
+# PUBLISH __keyevent@0__:del foo
+#
+# It is possible to select the events that Redis will notify among a set
+# of classes. Every class is identified by a single character:
+#
+#  K     Keyspace events, published with __keyspace@<db>__ prefix.
+#  E     Keyevent events, published with __keyevent@<db>__ prefix.
+#  g     Generic commands (non-type specific) like DEL, EXPIRE, RENAME, ...
+#  $     String commands
+#  l     List commands
+#  s     Set commands
+#  h     Hash commands
+#  z     Sorted set commands
+#  x     Expired events (events generated every time a key expires)
+#  e     Evicted events (events generated when a key is evicted for maxmemory)
+#  A     Alias for g$lshzxe, so that the "AKE" string means all the events.
+#
+#  The "notify-keyspace-events" takes as argument a string that is composed
+#  of zero or multiple characters. The empty string means that notifications
+#  are disabled.
+#
+#  Example: to enable list and generic events, from the point of view of the
+#           event name, use:
+#
+#  notify-keyspace-events Elg
+#
+#  Example 2: to get the stream of the expired keys subscribing to channel
+#             name __keyevent@0__:expired use:
+#
+#  notify-keyspace-events Ex
+#
+#  By default all notifications are disabled because most users don't need
+#  this feature and the feature has some overhead. Note that if you don't
+#  specify at least one of K or E, no events will be delivered.
+notify-keyspace-events ""
+
 ############################### ADVANCED CONFIG ###############################
 
 # Hashes are encoded using a memory efficient data structure when they have a
@@ -463,14 +1047,39 @@
 hash-max-ziplist-entries 512
 hash-max-ziplist-value 64
 
-# Similarly to hashes, small lists are also encoded in a special way in order
-# to save a lot of space. The special representation is only used when
-# you are under the following limits:
-list-max-ziplist-entries 512
-list-max-ziplist-value 64
+# Lists are also encoded in a special way to save a lot of space.
+# The number of entries allowed per internal list node can be specified
+# as a fixed maximum size or a maximum number of elements.
+# For a fixed maximum size, use -5 through -1, meaning:
+# -5: max size: 64 Kb  <-- not recommended for normal workloads
+# -4: max size: 32 Kb  <-- not recommended
+# -3: max size: 16 Kb  <-- probably not recommended
+# -2: max size: 8 Kb   <-- good
+# -1: max size: 4 Kb   <-- good
+# Positive numbers mean store up to _exactly_ that number of elements
+# per list node.
+# The highest performing option is usually -2 (8 Kb size) or -1 (4 Kb size),
+# but if your use case is unique, adjust the settings as necessary.
+list-max-ziplist-size -2
+
+# Lists may also be compressed.
+# Compress depth is the number of quicklist ziplist nodes from *each* side of
+# the list to *exclude* from compression.  The head and tail of the list
+# are always uncompressed for fast push/pop operations.  Settings are:
+# 0: disable all list compression
+# 1: depth 1 means "don't start compressing until after 1 node into the list,
+#    going from either the head or tail"
+#    So: [head]->node->node->...->node->[tail]
+#    [head], [tail] will always be uncompressed; inner nodes will compress.
+# 2: [head]->[next]->node->node->...->node->[prev]->[tail]
+#    2 here means: don't compress head or head->next or tail->prev or tail,
+#    but compress all nodes between them.
+# 3: [head]->[next]->[next]->node->node->...->node->[prev]->[prev]->[tail]
+# etc.
+list-compress-depth 0
 
 # Sets have a special encoding in just one case: when a set is composed
-# of just strings that happens to be integers in radix 10 in the range
+# of just strings that happen to be integers in radix 10 in the range
 # of 64 bit signed integers.
 # The following configuration setting sets the limit in the size of the
 # set in order to use this special memory saving encoding.
@@ -482,20 +1091,34 @@
 zset-max-ziplist-entries 128
 zset-max-ziplist-value 64
 
+# HyperLogLog sparse representation bytes limit. The limit includes the
+# 16 bytes header. When an HyperLogLog using the sparse representation crosses
+# this limit, it is converted into the dense representation.
+#
+# A value greater than 16000 is totally useless, since at that point the
+# dense representation is more memory efficient.
+#
+# The suggested value is ~ 3000 in order to have the benefits of
+# the space efficient encoding without slowing down too much PFADD,
+# which is O(N) with the sparse encoding. The value can be raised to
+# ~ 10000 when CPU is not a concern, but space is, and the data set is
+# composed of many HyperLogLogs with cardinality in the 0 - 15000 range.
+hll-sparse-max-bytes 3000
+
 # Active rehashing uses 1 millisecond every 100 milliseconds of CPU time in
 # order to help rehashing the main Redis hash table (the one mapping top-level
 # keys to values). The hash table implementation Redis uses (see dict.c)
-# performs a lazy rehashing: the more operation you run into an hash table
+# performs a lazy rehashing: the more operation you run into a hash table
 # that is rehashing, the more rehashing "steps" are performed, so if the
 # server is idle the rehashing is never complete and some more memory is used
 # by the hash table.
-# 
+#
 # The default is to use this millisecond 10 times every second in order to
-# active rehashing the main dictionaries, freeing memory when possible.
+# actively rehash the main dictionaries, freeing memory when possible.
 #
 # If unsure:
 # use "activerehashing no" if you have hard latency requirements and it is
-# not a good thing in your environment that Redis can reply form time to time
+# not a good thing in your environment that Redis can reply from time to time
 # to queries with 2 milliseconds delay.
 #
 # use "activerehashing yes" if you don't have such hard requirements but
@@ -509,9 +1132,9 @@
 #
 # The limit can be set differently for the three different classes of clients:
 #
-# normal -> normal clients
-# slave  -> slave clients and MONITOR clients
-# pubsub -> clients subcribed to at least one pubsub channel or pattern
+# normal -> normal clients including MONITOR clients
+# slave  -> slave clients
+# pubsub -> clients subscribed to at least one pubsub channel or pattern
 #
 # The syntax of every client-output-buffer-limit directive is the following:
 #
@@ -534,17 +1157,158 @@
 # Instead there is a default limit for pubsub and slave clients, since
 # subscribers and slaves receive data in a push fashion.
 #
-# Both the hard or the soft limit can be disabled just setting it to zero.
+# Both the hard or the soft limit can be disabled by setting them to zero.
 client-output-buffer-limit normal 0 0 0
 client-output-buffer-limit slave 256mb 64mb 60
 client-output-buffer-limit pubsub 32mb 8mb 60
 
-################################## INCLUDES ###################################
-
-# Include one or more other config files here.  This is useful if you
-# have a standard template that goes to all Redis server but also need
-# to customize a few per-server settings.  Include files can include
-# other files, so use this wisely.
+# Client query buffers accumulate new commands. They are limited to a fixed
+# amount by default in order to avoid that a protocol desynchronization (for
+# instance due to a bug in the client) will lead to unbound memory usage in
+# the query buffer. However you can configure it here if you have very special
+# needs, such us huge multi/exec requests or alike.
 #
-# include /path/to/local.conf
-# include /path/to/other.conf
+# client-query-buffer-limit 1gb
+
+# In the Redis protocol, bulk requests, that are, elements representing single
+# strings, are normally limited ot 512 mb. However you can change this limit
+# here.
+#
+# proto-max-bulk-len 512mb
+
+# Redis calls an internal function to perform many background tasks, like
+# closing connections of clients in timeout, purging expired keys that are
+# never requested, and so forth.
+#
+# Not all tasks are performed with the same frequency, but Redis checks for
+# tasks to perform according to the specified "hz" value.
+#
+# By default "hz" is set to 10. Raising the value will use more CPU when
+# Redis is idle, but at the same time will make Redis more responsive when
+# there are many keys expiring at the same time, and timeouts may be
+# handled with more precision.
+#
+# The range is between 1 and 500, however a value over 100 is usually not
+# a good idea. Most users should use the default of 10 and raise this up to
+# 100 only in environments where very low latency is required.
+hz 10
+
+# When a child rewrites the AOF file, if the following option is enabled
+# the file will be fsync-ed every 32 MB of data generated. This is useful
+# in order to commit the file to the disk more incrementally and avoid
+# big latency spikes.
+aof-rewrite-incremental-fsync yes
+
+# Redis LFU eviction (see maxmemory setting) can be tuned. However it is a good
+# idea to start with the default settings and only change them after investigating
+# how to improve the performances and how the keys LFU change over time, which
+# is possible to inspect via the OBJECT FREQ command.
+#
+# There are two tunable parameters in the Redis LFU implementation: the
+# counter logarithm factor and the counter decay time. It is important to
+# understand what the two parameters mean before changing them.
+#
+# The LFU counter is just 8 bits per key, it's maximum value is 255, so Redis
+# uses a probabilistic increment with logarithmic behavior. Given the value
+# of the old counter, when a key is accessed, the counter is incremented in
+# this way:
+#
+# 1. A random number R between 0 and 1 is extracted.
+# 2. A probability P is calculated as 1/(old_value*lfu_log_factor+1).
+# 3. The counter is incremented only if R < P.
+#
+# The default lfu-log-factor is 10. This is a table of how the frequency
+# counter changes with a different number of accesses with different
+# logarithmic factors:
+#
+# +--------+------------+------------+------------+------------+------------+
+# | factor | 100 hits   | 1000 hits  | 100K hits  | 1M hits    | 10M hits   |
+# +--------+------------+------------+------------+------------+------------+
+# | 0      | 104        | 255        | 255        | 255        | 255        |
+# +--------+------------+------------+------------+------------+------------+
+# | 1      | 18         | 49         | 255        | 255        | 255        |
+# +--------+------------+------------+------------+------------+------------+
+# | 10     | 10         | 18         | 142        | 255        | 255        |
+# +--------+------------+------------+------------+------------+------------+
+# | 100    | 8          | 11         | 49         | 143        | 255        |
+# +--------+------------+------------+------------+------------+------------+
+#
+# NOTE: The above table was obtained by running the following commands:
+#
+#   redis-benchmark -n 1000000 incr foo
+#   redis-cli object freq foo
+#
+# NOTE 2: The counter initial value is 5 in order to give new objects a chance
+# to accumulate hits.
+#
+# The counter decay time is the time, in minutes, that must elapse in order
+# for the key counter to be divided by two (or decremented if it has a value
+# less <= 10).
+#
+# The default value for the lfu-decay-time is 1. A Special value of 0 means to
+# decay the counter every time it happens to be scanned.
+#
+# lfu-log-factor 10
+# lfu-decay-time 1
+
+########################### ACTIVE DEFRAGMENTATION #######################
+#
+# WARNING THIS FEATURE IS EXPERIMENTAL. However it was stress tested
+# even in production and manually tested by multiple engineers for some
+# time.
+#
+# What is active defragmentation?
+# -------------------------------
+#
+# Active (online) defragmentation allows a Redis server to compact the
+# spaces left between small allocations and deallocations of data in memory,
+# thus allowing to reclaim back memory.
+#
+# Fragmentation is a natural process that happens with every allocator (but
+# less so with Jemalloc, fortunately) and certain workloads. Normally a server
+# restart is needed in order to lower the fragmentation, or at least to flush
+# away all the data and create it again. However thanks to this feature
+# implemented by Oran Agra for Redis 4.0 this process can happen at runtime
+# in an "hot" way, while the server is running.
+#
+# Basically when the fragmentation is over a certain level (see the
+# configuration options below) Redis will start to create new copies of the
+# values in contiguous memory regions by exploiting certain specific Jemalloc
+# features (in order to understand if an allocation is causing fragmentation
+# and to allocate it in a better place), and at the same time, will release the
+# old copies of the data. This process, repeated incrementally for all the keys
+# will cause the fragmentation to drop back to normal values.
+#
+# Important things to understand:
+#
+# 1. This feature is disabled by default, and only works if you compiled Redis
+#    to use the copy of Jemalloc we ship with the source code of Redis.
+#    This is the default with Linux builds.
+#
+# 2. You never need to enable this feature if you don't have fragmentation
+#    issues.
+#
+# 3. Once you experience fragmentation, you can enable this feature when
+#    needed with the command "CONFIG SET activedefrag yes".
+#
+# The configuration parameters are able to fine tune the behavior of the
+# defragmentation process. If you are not sure about what they mean it is
+# a good idea to leave the defaults untouched.
+
+# Enabled active defragmentation
+# activedefrag yes
+
+# Minimum amount of fragmentation waste to start active defrag
+# active-defrag-ignore-bytes 100mb
+
+# Minimum percentage of fragmentation to start active defrag
+# active-defrag-threshold-lower 10
+
+# Maximum percentage of fragmentation at which we use maximum effort
+# active-defrag-threshold-upper 100
+
+# Minimal effort for defrag in CPU percentage
+# active-defrag-cycle-min 25
+
+# Maximal effort for defrag in CPU percentage
+# active-defrag-cycle-max 75
diff --git a/meta-openembedded/meta-oe/recipes-extended/redis/redis/remove-atomics.patch b/meta-openembedded/meta-oe/recipes-extended/redis/redis/remove-atomics.patch
new file mode 100644
index 0000000..23b2f2a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/redis/redis/remove-atomics.patch
@@ -0,0 +1,72 @@
+From c486455e0691f9915018b9d8b133200a6c61a3c5 Mon Sep 17 00:00:00 2001
+From: Alistair Francis <alistair.francis@wdc.com>
+Date: Thu, 24 May 2018 09:58:42 -0700
+Subject: [PATCH] Remove atomics
+
+Based on this patch:
+https://github.com/patrikx3/lede-redis/blob/master/redis/patches/010-redis.patch
+
+Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
+---
+ deps/jemalloc/src/pages.c | 22 +---------------------
+ src/atomicvar.h           |  4 ++--
+ 2 files changed, 3 insertions(+), 23 deletions(-)
+
+diff --git a/deps/jemalloc/src/pages.c b/deps/jemalloc/src/pages.c
+index 83a167f6..8e82c78d 100644
+--- a/deps/jemalloc/src/pages.c
++++ b/deps/jemalloc/src/pages.c
+@@ -147,27 +147,7 @@ pages_purge(void *addr, size_t size)
+ {
+ 	bool unzeroed;
+ 
+-#ifdef _WIN32
+-	VirtualAlloc(addr, size, MEM_RESET, PAGE_READWRITE);
+-	unzeroed = true;
+-#elif defined(JEMALLOC_HAVE_MADVISE)
+-#  ifdef JEMALLOC_PURGE_MADVISE_DONTNEED
+-#    define JEMALLOC_MADV_PURGE MADV_DONTNEED
+-#    define JEMALLOC_MADV_ZEROS true
+-#  elif defined(JEMALLOC_PURGE_MADVISE_FREE)
+-#    define JEMALLOC_MADV_PURGE MADV_FREE
+-#    define JEMALLOC_MADV_ZEROS false
+-#  else
+-#    error "No madvise(2) flag defined for purging unused dirty pages."
+-#  endif
+-	int err = madvise(addr, size, JEMALLOC_MADV_PURGE);
+-	unzeroed = (!JEMALLOC_MADV_ZEROS || err != 0);
+-#  undef JEMALLOC_MADV_PURGE
+-#  undef JEMALLOC_MADV_ZEROS
+-#else
+-	/* Last resort no-op. */
+-	unzeroed = true;
+-#endif
++	unzeroed = false;
+ 	return (unzeroed);
+ }
+ 
+diff --git a/src/atomicvar.h b/src/atomicvar.h
+index 84a5bbc5..f9b563c2 100644
+--- a/src/atomicvar.h
++++ b/src/atomicvar.h
+@@ -68,7 +68,7 @@
+  * is reported. */
+ // #define __ATOMIC_VAR_FORCE_SYNC_MACROS
+ 
+-#if !defined(__ATOMIC_VAR_FORCE_SYNC_MACROS) && defined(__ATOMIC_RELAXED) && !defined(__sun) && (!defined(__clang__) || !defined(__APPLE__) || __apple_build_version__ > 4210057)
++#if defined(CONFIG_EDAC_ATOMIC_SCRUB) &&  !defined(__ATOMIC_VAR_FORCE_SYNC_MACROS) && defined(__ATOMIC_RELAXED) && !defined(__sun) && (!defined(__clang__) || !defined(__APPLE__) || __apple_build_version__ > 4210057)
+ /* Implementation using __atomic macros. */
+ 
+ #define atomicIncr(var,count) __atomic_add_fetch(&var,(count),__ATOMIC_RELAXED)
+@@ -82,7 +82,7 @@
+ #define atomicSet(var,value) __atomic_store_n(&var,value,__ATOMIC_RELAXED)
+ #define REDIS_ATOMIC_API "atomic-builtin"
+ 
+-#elif defined(HAVE_ATOMIC)
++#elif defined(CONFIG_EDAC_ATOMIC_SCRUB) && defined(HAVE_ATOMIC)
+ /* Implementation using __sync macros. */
+ 
+ #define atomicIncr(var,count) __sync_add_and_fetch(&var,(count))
+-- 
+2.17.0
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/redis/redis_3.0.2.bb b/meta-openembedded/meta-oe/recipes-extended/redis/redis_3.0.2.bb
deleted file mode 100644
index 9395b33..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/redis/redis_3.0.2.bb
+++ /dev/null
@@ -1,55 +0,0 @@
-SUMMARY = "Redis key-value store"
-DESCRIPTION = "Redis is an open source, advanced key-value store."
-HOMEPAGE = "http://redis.io"
-SECTION = "libs"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=3c01b49fed4df1a79843688fa3f7b9d6"
-DEPENDS = ""
-
-SRC_URI = "http://download.redis.io/releases/${BP}.tar.gz \
-           file://hiredis-use-default-CC-if-it-is-set.patch \
-           file://lua-update-Makefile-to-use-environment-build-setting.patch \
-           file://oe-use-libc-malloc.patch \
-           file://redis.conf \
-           file://init-redis-server \
-           file://redis.service \
-           file://hiredis-update-Makefile-to-add-symbols-to-staticlib.patch \
-"
-
-SRC_URI[md5sum] = "87be8867447f62524b584813e5a7bd14"
-SRC_URI[sha256sum] = "93e422c0d584623601f89b956045be158889ebe594478a2c24e1bf218495633f"
-
-inherit autotools-brokensep update-rc.d systemd useradd
-
-USERADD_PACKAGES = "${PN}"
-USERADD_PARAM_${PN}  = "--system --home-dir /var/lib/redis -g redis --shell /bin/false redis"
-GROUPADD_PARAM_${PN} = "--system redis"
-
-
-REDIS_ON_SYSTEMD = "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}"
-
-do_install() {
-    export PREFIX=${D}/${prefix}
-    oe_runmake install
-    install -d ${D}/${sysconfdir}/redis
-    install -m 0644 ${WORKDIR}/redis.conf ${D}/${sysconfdir}/redis/redis.conf
-    install -d ${D}/${sysconfdir}/init.d
-    install -m 0755 ${WORKDIR}/init-redis-server ${D}/${sysconfdir}/init.d/redis-server
-    install -d ${D}/var/lib/redis/
-    chown redis.redis ${D}/var/lib/redis/
-
-    install -d ${D}${systemd_system_unitdir}
-    install -m 0644 ${WORKDIR}/redis.service ${D}${systemd_system_unitdir}
-    sed -i 's!/usr/sbin/!${sbindir}/!g' ${D}${systemd_system_unitdir}/redis.service
-
-    if [ "${REDIS_ON_SYSTEMD}" = true ]; then
-        sed -i 's!daemonize yes!# daemonize yes!' ${D}/${sysconfdir}/redis/redis.conf
-    fi
-}
-
-CONFFILES_${PN} = "${sysconfdir}/redis/redis.conf"
-
-INITSCRIPT_NAME = "redis-server"
-INITSCRIPT_PARAMS = "defaults 87"
-
-SYSTEMD_SERVICE_${PN} = "redis.service"
diff --git a/meta-openembedded/meta-oe/recipes-extended/redis/redis_4.0.8.bb b/meta-openembedded/meta-oe/recipes-extended/redis/redis_4.0.8.bb
new file mode 100644
index 0000000..80d36d2
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/redis/redis_4.0.8.bb
@@ -0,0 +1,57 @@
+SUMMARY = "Redis key-value store"
+DESCRIPTION = "Redis is an open source, advanced key-value store."
+HOMEPAGE = "http://redis.io"
+SECTION = "libs"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=3c01b49fed4df1a79843688fa3f7b9d6"
+DEPENDS = ""
+
+SRC_URI = "http://download.redis.io/releases/${BP}.tar.gz \
+           file://hiredis-use-default-CC-if-it-is-set.patch \
+           file://lua-update-Makefile-to-use-environment-build-setting.patch \
+           file://oe-use-libc-malloc.patch \
+           file://redis.conf \
+           file://init-redis-server \
+           file://redis.service \
+"
+
+SRC_URI_append_mips = " file://remove-atomics.patch"
+SRC_URI_append_arm = " file://remove-atomics.patch"
+
+SRC_URI[md5sum] = "c75b11e4177e153e4dc1d8dd3a6174e4"
+SRC_URI[sha256sum] = "ff0c38b8c156319249fec61e5018cf5b5fe63a65b61690bec798f4c998c232ad"
+
+inherit autotools-brokensep update-rc.d systemd useradd
+
+USERADD_PACKAGES = "${PN}"
+USERADD_PARAM_${PN}  = "--system --home-dir /var/lib/redis -g redis --shell /bin/false redis"
+GROUPADD_PARAM_${PN} = "--system redis"
+
+
+REDIS_ON_SYSTEMD = "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}"
+
+do_install() {
+    export PREFIX=${D}/${prefix}
+    oe_runmake install
+    install -d ${D}/${sysconfdir}/redis
+    install -m 0644 ${WORKDIR}/redis.conf ${D}/${sysconfdir}/redis/redis.conf
+    install -d ${D}/${sysconfdir}/init.d
+    install -m 0755 ${WORKDIR}/init-redis-server ${D}/${sysconfdir}/init.d/redis-server
+    install -d ${D}/var/lib/redis/
+    chown redis.redis ${D}/var/lib/redis/
+
+    install -d ${D}${systemd_system_unitdir}
+    install -m 0644 ${WORKDIR}/redis.service ${D}${systemd_system_unitdir}
+    sed -i 's!/usr/sbin/!${sbindir}/!g' ${D}${systemd_system_unitdir}/redis.service
+
+    if [ "${REDIS_ON_SYSTEMD}" = true ]; then
+        sed -i 's!daemonize yes!# daemonize yes!' ${D}/${sysconfdir}/redis/redis.conf
+    fi
+}
+
+CONFFILES_${PN} = "${sysconfdir}/redis/redis.conf"
+
+INITSCRIPT_NAME = "redis-server"
+INITSCRIPT_PARAMS = "defaults 87"
+
+SYSTEMD_SERVICE_${PN} = "redis.service"
diff --git a/meta-openembedded/meta-oe/recipes-extended/rrdtool/rrdtool_1.6.0.bb b/meta-openembedded/meta-oe/recipes-extended/rrdtool/rrdtool_1.6.0.bb
deleted file mode 100644
index 797bcaa..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/rrdtool/rrdtool_1.6.0.bb
+++ /dev/null
@@ -1,128 +0,0 @@
-SUMMARY = "High performance data logging and graphing system for time series data"
-HOMEPAGE = "http://oss.oetiker.ch/rrdtool/"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=3349111ed0533471494beec99715bc9d"
-
-DEPENDS = "libpng zlib cairo pango glib-2.0 libxml2 groff-native"
-
-SRCREV = "61f116744262c4c18922dcf806e496715f199669"
-PV = "1.6.0"
-
-SRC_URI = "\
-    git://github.com/oetiker/rrdtool-1.x.git;branch=1.6;protocol=http; \
-"
-
-S = "${WORKDIR}/git"
-
-inherit cpan autotools-brokensep gettext pythonnative python-dir systemd
-
-BBCLASSEXTEND = "native"
-
-SYSTEMD_PACKAGES = "rrdcached"
-SYSTEMD_SERVICE_rrdcached = "rrdcached.socket rrdcached.service"
-
-EXTRA_AUTORECONF = "-I m4 --exclude=autopoint"
-
-PACKAGECONFIG ??= "python perl ${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
-
-PACKAGECONFIG[python] = "--enable-python=yes \
-am_cv_python_pythondir=${STAGING_LIBDIR}/python${PYTHON_BASEVERSION}/site-packages \
-am_cv_python_pyexecdir=${STAGING_LIBDIR}/python${PYTHON_BASEVERSION}/site-packages,\
---disable-python,python,"
-
-PACKAGECONFIG[perl] = \
-"--enable-perl=yes --with-perl-options='INSTALLDIRS="vendor"' \
-ac_cv_path_PERL_CC='${CC}',  \
---disable-perl,perl,"
-
-PACKAGECONFIG[dbi] = "--enable-libdbi,--disable-libdbi,libdbi"
-
-PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/,--without-systemdsystemunitdir,systemd,"
-
-EXTRA_OECONF = " \
-    --enable-shared \
-    --disable-libwrap \
-    --program-prefix='' \
-    rd_cv_ieee_works=yes \
-    --disable-ruby \
-    --disable-lua \
-    --disable-tcl \
-    --disable-rpath \
-    --enable-nls=${USE_NLS} \
-"
-
-export STAGING_LIBDIR
-export STAGING_INCDIR
-
-# emulate cpan_do_configure
-EXTRA_OEMAKE = ' PERL5LIB="${PERL_ARCHLIB}" '
-# Avoid do_configure error on some hosts
-
-do_configure() {
-    unset PERLHOSTLIB
-    #fix the pkglib problem with newer automake
-    #perl
-    sed -i -e "s|-Wl,--rpath -Wl,\$rp||g" \
-        ${S}/bindings/perl-shared/Makefile.PL
-
-    #python
-    sed -i -e '/PYTHON_INCLUDES="-I${/c \
-    PYTHON_INCLUDES="-I=/usr/include/python${PYTHON_BASEVERSION}"' \
-        ${S}/m4/acinclude.m4
-    #remove the useless RPATH from the rrdtool.so
-    sed -i -e 's|LD_RUN_PATH=$(libdir)||g' ${S}/bindings/Makefile.am
-
-    autotools_do_configure
-
-    #modify python sitepkg
-    #remove the dependency of perl-shared:Makefile
-    #or perl-shared/Makefile will be regenerated
-    #if any code touch bindings/Makefile after below perl bindings code
-    sed -i -e "s:python/setup.py install:python/setup.py install \
-        --install-lib=${PYTHON_SITEPACKAGES_DIR}:" \
-        -e "s:perl-shared/Makefile.PL Makefile:perl-shared/Makefile.PL:" \
-        ${B}/bindings/Makefile
-
-    #redo the perl bindings
-    (
-    cd ${S}/bindings/perl-shared;
-    perl Makefile.PL INSTALLDIRS="vendor" INSTALLPRIVLIB="abc";
-
-    cd ../../bindings/perl-piped;
-    perl Makefile.PL INSTALLDIRS="vendor";
-    )
-
-    #change the interpreter in file
-    sed -i -e "s|^PERL = ${STAGING_BINDIR_NATIVE}/.*|PERL = /usr/bin/perl|g" \
-        ${B}/examples/Makefile
-    sed -i -e "s|${STAGING_BINDIR_NATIVE}/perl-native/perl|/usr/bin/perl|g" \
-        ${B}/examples/*.pl
-}
-
-PACKAGES =+ "${PN}-perl ${PN}-python"
-PACKAGES =+ "rrdcached"
-
-DESCRIPTION_rrdcached = \
-"The rrdcached package contains the data caching daemon for RRDtool."
-
-FILES_rrdcached = "${bindir}/rrdcached \
-    ${systemd_unitdir}/system/rrdcached.service \
-    ${systemd_unitdir}/system/rrdcached.socket"
-
-FILES_${PN}-doc += "${datadir}/rrdtool/examples"
-
-DESCRIPTION_${PN}-perl = \
-"The ${PN}-perl package includes RRDtool bindings for perl."
-FILES_${PN}-perl = "${libdir}/perl/vendor_perl/*/*.pm \
-    ${libdir}/perl/vendor_perl/*/auto/RRDs/RRDs.*"
-RDEPENDS_${PN}-perl = "perl perl-module-lib perl-module-getopt-long perl-module-time-hires \
-    perl-module-io-file perl-module-ipc-open2 perl-module-io-socket"
-
-DESCRIPTION_${PN}-python = \
-"The ${PN}-python package includes RRDtool bindings for python."
-FILES_${PN}-python = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/*"
-RDEPENDS_${PN}-python = "python"
-
-FILES_${PN}-dbg += "${libdir}/perl/vendor_perl/*/auto/RRDs/.debug \
-    ${libdir}/python${PYTHON_BASEVERSION}/site-packages/.debug"
diff --git a/meta-openembedded/meta-oe/recipes-extended/rrdtool/rrdtool_1.7.0.bb b/meta-openembedded/meta-oe/recipes-extended/rrdtool/rrdtool_1.7.0.bb
new file mode 100644
index 0000000..ff99574
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/rrdtool/rrdtool_1.7.0.bb
@@ -0,0 +1,128 @@
+SUMMARY = "High performance data logging and graphing system for time series data"
+HOMEPAGE = "http://oss.oetiker.ch/rrdtool/"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=3349111ed0533471494beec99715bc9d"
+
+DEPENDS = "libpng zlib cairo pango glib-2.0 libxml2 groff-native python-setuptools-native"
+
+SRCREV = "bfc82d5242855628b826018479df00e0ec4e8360"
+PV = "1.7.0"
+
+SRC_URI = "\
+    git://github.com/oetiker/rrdtool-1.x.git;branch=master;protocol=http; \
+"
+
+S = "${WORKDIR}/git"
+
+inherit cpan autotools-brokensep gettext pythonnative python-dir systemd
+
+BBCLASSEXTEND = "native"
+
+SYSTEMD_PACKAGES = "rrdcached"
+SYSTEMD_SERVICE_rrdcached = "rrdcached.socket rrdcached.service"
+
+EXTRA_AUTORECONF = "-I m4 --exclude=autopoint"
+
+PACKAGECONFIG ??= "python perl ${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
+
+PACKAGECONFIG[python] = "--enable-python=yes \
+am_cv_python_pythondir=${STAGING_LIBDIR}/python${PYTHON_BASEVERSION}/site-packages \
+am_cv_python_pyexecdir=${STAGING_LIBDIR}/python${PYTHON_BASEVERSION}/site-packages,\
+--disable-python,python,"
+
+PACKAGECONFIG[perl] = \
+"--enable-perl=yes --with-perl-options='INSTALLDIRS="vendor"' \
+ac_cv_path_PERL_CC='${CC}',  \
+--disable-perl,perl,"
+
+PACKAGECONFIG[dbi] = "--enable-libdbi,--disable-libdbi,libdbi"
+
+PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/,--without-systemdsystemunitdir,systemd,"
+
+EXTRA_OECONF = " \
+    --enable-shared \
+    --disable-libwrap \
+    --program-prefix='' \
+    rd_cv_ieee_works=yes \
+    --disable-ruby \
+    --disable-lua \
+    --disable-tcl \
+    --disable-rpath \
+    --enable-nls=${USE_NLS} \
+"
+
+export STAGING_LIBDIR
+export STAGING_INCDIR
+
+# emulate cpan_do_configure
+EXTRA_OEMAKE = ' PERL5LIB="${PERL_ARCHLIB}" '
+# Avoid do_configure error on some hosts
+
+do_configure() {
+    unset PERLHOSTLIB
+    #fix the pkglib problem with newer automake
+    #perl
+    sed -i -e "s|-Wl,--rpath -Wl,\$rp||g" \
+        ${S}/bindings/perl-shared/Makefile.PL
+
+    #python
+    sed -i -e '/PYTHON_INCLUDES="-I${/c \
+    PYTHON_INCLUDES="-I=/usr/include/python${PYTHON_BASEVERSION}"' \
+        ${S}/m4/acinclude.m4
+    #remove the useless RPATH from the rrdtool.so
+    sed -i -e 's|LD_RUN_PATH=$(libdir)||g' ${S}/bindings/Makefile.am
+
+    autotools_do_configure
+
+    #modify python sitepkg
+    #remove the dependency of perl-shared:Makefile
+    #or perl-shared/Makefile will be regenerated
+    #if any code touch bindings/Makefile after below perl bindings code
+    sed -i -e "s:python/setup.py install:python/setup.py install \
+        --install-lib=${PYTHON_SITEPACKAGES_DIR}:" \
+        -e "s:perl-shared/Makefile.PL Makefile:perl-shared/Makefile.PL:" \
+        ${B}/bindings/Makefile
+
+    #redo the perl bindings
+    (
+    cd ${S}/bindings/perl-shared;
+    perl Makefile.PL INSTALLDIRS="vendor" INSTALLPRIVLIB="abc";
+
+    cd ../../bindings/perl-piped;
+    perl Makefile.PL INSTALLDIRS="vendor";
+    )
+
+    #change the interpreter in file
+    sed -i -e "s|^PERL = ${STAGING_BINDIR_NATIVE}/.*|PERL = /usr/bin/perl|g" \
+        ${B}/examples/Makefile
+    sed -i -e "s|${STAGING_BINDIR_NATIVE}/perl-native/perl|/usr/bin/perl|g" \
+        ${B}/examples/*.pl
+}
+
+PACKAGES =+ "${PN}-perl ${PN}-python"
+PACKAGES =+ "rrdcached"
+
+DESCRIPTION_rrdcached = \
+"The rrdcached package contains the data caching daemon for RRDtool."
+
+FILES_rrdcached = "${bindir}/rrdcached \
+    ${systemd_unitdir}/system/rrdcached.service \
+    ${systemd_unitdir}/system/rrdcached.socket"
+
+FILES_${PN}-doc += "${datadir}/rrdtool/examples"
+
+DESCRIPTION_${PN}-perl = \
+"The ${PN}-perl package includes RRDtool bindings for perl."
+FILES_${PN}-perl = "${libdir}/perl/vendor_perl/*/*.pm \
+    ${libdir}/perl/vendor_perl/*/auto/RRDs/RRDs.*"
+RDEPENDS_${PN}-perl = "perl perl-module-lib perl-module-getopt-long perl-module-time-hires \
+    perl-module-io-file perl-module-ipc-open2 perl-module-io-socket"
+
+DESCRIPTION_${PN}-python = \
+"The ${PN}-python package includes RRDtool bindings for python."
+FILES_${PN}-python = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/*"
+RDEPENDS_${PN}-python = "python"
+
+FILES_${PN}-dbg += "${libdir}/perl/vendor_perl/*/auto/RRDs/.debug \
+    ${libdir}/python${PYTHON_BASEVERSION}/site-packages/.debug"
diff --git a/meta-openembedded/meta-oe/recipes-extended/rsyslog/librelp/0001-src-tcp.c-fix-jump-misses-init-error.patch b/meta-openembedded/meta-oe/recipes-extended/rsyslog/librelp/0001-src-tcp.c-fix-jump-misses-init-error.patch
new file mode 100644
index 0000000..68b6863
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/rsyslog/librelp/0001-src-tcp.c-fix-jump-misses-init-error.patch
@@ -0,0 +1,71 @@
+From 3e5a0cb440c788e2383e40ab23ac1cf01d96961b Mon Sep 17 00:00:00 2001
+From: Mingli Yu <mingli.yu@windriver.com>
+Date: Tue, 24 Jul 2018 01:30:25 -0700
+Subject: [PATCH] src/tcp.c: fix jump-misses-init error
+
+Fix below jump-misses-init error
+
+| In file included from ../../git/src/tcp.c:51:
+| ../../git/src/tcp.c: In function 'relpTcpConnect':
+| ../../git/src/relp.h:220:3: error: jump skips variable initialization [-Werror=jump-misses-init]
+|    goto finalize_it;  \
+|    ^~~~
+| ../../git/src/tcp.c:1951:3: note: in expansion of macro 'ABORT_FINALIZE'
+|    ABORT_FINALIZE(RELP_RET_IO_ERR);
+|    ^~~~~~~~~~~~~~
+| ../../git/src/tcp.c:2005:1: note: label 'finalize_it' defined here
+|  finalize_it:
+|  ^~~~~~~~~~~
+| ../../git/src/tcp.c:1991:6: note: 'r' declared here
+|   int r = getsockopt(pThis->sock, SOL_SOCKET, SO_ERROR, &so_error, &len);
+|       ^
+| In file included from ../../git/src/tcp.c:51:
+| ../../git/src/relp.h:220:3: error: jump skips variable initialization [-Werror=jump-misses-init]
+|    goto finalize_it;  \
+|    ^~~~
+| ../../git/src/tcp.c:1951:3: note: in expansion of macro 'ABORT_FINALIZE'
+|    ABORT_FINALIZE(RELP_RET_IO_ERR);
+|    ^~~~~~~~~~~~~~
+| ../../git/src/tcp.c:2005:1: note: label 'finalize_it' defined here
+|  finalize_it:
+|  ^~~~~~~~~~~
+| ../../git/src/tcp.c:1989:12: note: 'len' declared here
+|   socklen_t len = sizeof so_error;
+|             ^~~
+
+Upstream-Status: Submitted[https://github.com/rsyslog/librelp/pull/117]
+
+Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
+---
+ src/tcp.c | 7 ++++---
+ 1 file changed, 4 insertions(+), 3 deletions(-)
+
+diff --git a/src/tcp.c b/src/tcp.c
+index f35eb84..fb34dc7 100644
+--- a/src/tcp.c
++++ b/src/tcp.c
+@@ -1936,6 +1936,9 @@ relpTcpConnect(relpTcp_t *const pThis,
+ 	struct addrinfo hints;
+ 	struct addrinfo *reslocal = NULL;
+ 	struct pollfd pfd;
++	int so_error;
++	socklen_t len = sizeof so_error;
++	int r;
+ 
+ 	ENTER_RELPFUNC;
+ 	RELPOBJ_assert(pThis, Tcp);
+@@ -1985,10 +1988,8 @@ relpTcpConnect(relpTcp_t *const pThis,
+ 		ABORT_FINALIZE(RELP_RET_TIMED_OUT);
+ 	}
+ 
+-	int so_error;
+-	socklen_t len = sizeof so_error;
+ 
+-	int r = getsockopt(pThis->sock, SOL_SOCKET, SO_ERROR, &so_error, &len);
++	r = getsockopt(pThis->sock, SOL_SOCKET, SO_ERROR, &so_error, &len);
+ 	if (r == -1 || so_error != 0) {
+ 		pThis->pEngine->dbgprint("socket has an error %d\n", so_error);
+ 		ABORT_FINALIZE(RELP_RET_IO_ERR);
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/rsyslog/librelp/0001-src-tcp.c-increase-the-size-of-szHname.patch b/meta-openembedded/meta-oe/recipes-extended/rsyslog/librelp/0001-src-tcp.c-increase-the-size-of-szHname.patch
new file mode 100644
index 0000000..5a62e15
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/rsyslog/librelp/0001-src-tcp.c-increase-the-size-of-szHname.patch
@@ -0,0 +1,53 @@
+From d8950ad273d79ec516468289adbd427e681dbc66 Mon Sep 17 00:00:00 2001
+From: Mingli Yu <mingli.yu@windriver.com>
+Date: Mon, 30 Jul 2018 01:22:56 -0700
+Subject: [PATCH] src/tcp.c: increase the size of szHname
+
+Increase the size of szHname to fix below
+error:
+| ../../git/src/tcp.c: In function 'relpTcpSetRemHost':
+| ../../git/src/tcp.c:352:57: error: '%s' directive output may be truncated writing up to 1024 bytes into a region of size 1011 [-Werror=format-truncation=]
+|      snprintf((char*)szHname, NI_MAXHOST, "[MALICIOUS:IP=%s]", szIP);
+|                                                          ^~    ~~~~
+| In file included from /poky-build/tmp/work/i586-poky-linux/librelp/1.2.16-r0/recipe-sysroot/usr/include/stdio.h:862,
+|                  from ../../git/src/tcp.c:38:
+| /poky-build/tmp/work/i586-poky-linux/librelp/1.2.16-r0/recipe-sysroot/usr/include/bits/stdio2.h:64:10: note: '__builtin___snprintf_chk' output between 16 and 1040 bytes into a destination of size 1025
+|    return __builtin___snprintf_chk (__s, __n, __USE_FORTIFY_LEVEL - 1,
+|           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+|         __bos (__s), __fmt, __va_arg_pack ());
+|         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+| cc1: all warnings being treated as errors
+| Makefile:536: recipe for target 'librelp_la-tcp.lo' failed
+
+Upstream-Status: Submitted[https://github.com/rsyslog/librelp/pull/118]
+
+Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
+---
+ src/tcp.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/tcp.c b/src/tcp.c
+index fb34dc7..2c38b0b 100644
+--- a/src/tcp.c
++++ b/src/tcp.c
+@@ -319,7 +319,7 @@ relpTcpSetRemHost(relpTcp_t *const pThis, struct sockaddr *pAddr)
+ 	relpEngine_t *pEngine;
+ 	int error;
+ 	unsigned char szIP[NI_MAXHOST] = "";
+-	unsigned char szHname[NI_MAXHOST] = "";
++	unsigned char szHname[1045] = "";
+ 	struct addrinfo hints, *res;
+ 	size_t len;
+ 	
+@@ -349,7 +349,7 @@ relpTcpSetRemHost(relpTcp_t *const pThis, struct sockaddr *pAddr)
+ 			if(getaddrinfo((char*)szHname, NULL, &hints, &res) == 0) {
+ 				freeaddrinfo (res);
+ 				/* OK, we know we have evil, so let's indicate this to our caller */
+-				snprintf((char*)szHname, NI_MAXHOST, "[MALICIOUS:IP=%s]", szIP);
++				snprintf((char*)szHname, sizeof(szHname), "[MALICIOUS:IP=%s]", szIP);
+ 				pEngine->dbgprint("Malicious PTR record, IP = \"%s\" HOST = \"%s\"", szIP, szHname);
+ 				iRet = RELP_RET_MALICIOUS_HNAME;
+ 			}
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/rsyslog/librelp_1.2.14.bb b/meta-openembedded/meta-oe/recipes-extended/rsyslog/librelp_1.2.14.bb
deleted file mode 100644
index 28047eb..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/rsyslog/librelp_1.2.14.bb
+++ /dev/null
@@ -1,15 +0,0 @@
-SUMMARY = "A reliable logging library"
-HOMEPAGE = "https://github.com/rsyslog/libfastjson"
-
-LICENSE = "GPLv3"
-LIC_FILES_CHKSUM = "file://COPYING;md5=1fb9c10ed9fd6826757615455ca893a9"
-
-DEPENDS = "gmp nettle libidn zlib gnutls"
-
-SRC_URI = "git://github.com/rsyslog/librelp.git;protocol=https"
-
-SRCREV = "fc512e337bfc7c92770246dbff5f482b879498b9"
-
-S = "${WORKDIR}/git"
-
-inherit autotools pkgconfig
diff --git a/meta-openembedded/meta-oe/recipes-extended/rsyslog/librelp_1.2.16.bb b/meta-openembedded/meta-oe/recipes-extended/rsyslog/librelp_1.2.16.bb
new file mode 100644
index 0000000..17478ef
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/rsyslog/librelp_1.2.16.bb
@@ -0,0 +1,18 @@
+SUMMARY = "A reliable logging library"
+HOMEPAGE = "https://github.com/rsyslog/libfastjson"
+
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=1fb9c10ed9fd6826757615455ca893a9"
+
+DEPENDS = "gmp nettle libidn zlib gnutls"
+
+SRC_URI = "git://github.com/rsyslog/librelp.git;protocol=https \
+           file://0001-src-tcp.c-fix-jump-misses-init-error.patch \
+           file://0001-src-tcp.c-increase-the-size-of-szHname.patch \
+"
+
+SRCREV = "5e849ff060be0c7dce972e194c54fdacfee0adc2"
+
+S = "${WORKDIR}/git"
+
+inherit autotools pkgconfig
diff --git a/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/0001-Include-sys-time-h.patch b/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/0001-Include-sys-time-h.patch
index ca88dd3..6ce8b7a 100644
--- a/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/0001-Include-sys-time-h.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/0001-Include-sys-time-h.patch
@@ -1,6 +1,6 @@
-From 9739095de6ae5f844354756ae968f5f8864eb3e3 Mon Sep 17 00:00:00 2001
+From 7baf35b88d742032a2dc456c396843e17e866f8e Mon Sep 17 00:00:00 2001
 From: Ming Liu <peter.x.liu@external.atlascopco.com>
-Date: Sun, 26 Feb 2017 14:10:21 +0100
+Date: Wed, 27 Jun 2018 14:04:57 +0800
 Subject: [PATCH] Include sys/time.h
 
 struct timeval is defined in sys/time.h with a musl libc.
@@ -8,13 +8,13 @@
 Upstream-Status: Inappropriate [musl libc specific]
 
 Signed-off-by: Ming Liu <peter.x.liu@external.atlascopco.com>
-
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
 ---
  tests/msleep.c | 4 ----
  1 file changed, 4 deletions(-)
 
 diff --git a/tests/msleep.c b/tests/msleep.c
-index 26a8206..ca818be 100644
+index 98dbece..96f6950 100644
 --- a/tests/msleep.c
 +++ b/tests/msleep.c
 @@ -26,11 +26,7 @@
@@ -26,6 +26,7 @@
 -#else
 -#include <time.h>
 -#endif
- 
- int main(int argc, char *argv[])
- {
+ #if defined(HAVE_SYS_SELECT_H)
+ #include <sys/select.h>
+ #endif
+2.7.4
diff --git a/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/rsyslog.conf b/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/rsyslog.conf
index 324ae6d..dbfefb7 100644
--- a/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/rsyslog.conf
+++ b/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/rsyslog.conf
@@ -84,3 +84,8 @@
 # UDP Syslog Server:
 #$ModLoad imudp.so  # provides UDP syslog reception
 #$UDPServerRun 514 # start a UDP syslog server at standard port 514
+
+#
+# Include all config files in /etc/rsyslog.d/
+#
+$IncludeConfig /etc/rsyslog.d/*.conf
diff --git a/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/rsyslog.logrotate b/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/rsyslog.logrotate
index 94ec517..5f8568f 100644
--- a/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/rsyslog.logrotate
+++ b/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/rsyslog.logrotate
@@ -9,7 +9,7 @@
         delaycompress
         compress
         postrotate
-		/bin/kill -HUP `cat /var/run/rsyslogd.pid 2> /dev/null` 2> /dev/null || true
+		@BINDIR@/pkill -HUP rsyslogd 2> /dev/null || true
         endscript
 }
 
@@ -34,6 +34,6 @@
         delaycompress
         sharedscripts
         postrotate
-		/bin/kill -HUP `cat /var/run/rsyslogd.pid 2> /dev/null` 2> /dev/null || true
+		@BINDIR@/pkill -HUP rsyslogd 2> /dev/null || true
         endscript
 }
diff --git a/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/use-pkgconfig-to-check-libgcrypt.patch b/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/use-pkgconfig-to-check-libgcrypt.patch
index 162d239..0352587 100644
--- a/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/use-pkgconfig-to-check-libgcrypt.patch
+++ b/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog/use-pkgconfig-to-check-libgcrypt.patch
@@ -3,7 +3,7 @@
 Date: Wed, 18 Jun 2014 13:46:52 +0800
 Subject: [PATCH] use pkgconfig to check libgcrypt
 
-Upstream-status: Inappropriate [configuration]
+Upstream-Status: Inappropriate [configuration]
 
 libgcrypt does no longer provide libgcrypt-config, and provide
 *.pc, so we should use pkgconfig to check
diff --git a/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog_8.29.0.bb b/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog_8.29.0.bb
deleted file mode 100644
index 476540d..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog_8.29.0.bb
+++ /dev/null
@@ -1,150 +0,0 @@
-SUMMARY = "Rsyslog is an enhanced multi-threaded syslogd"
-DESCRIPTION = "\
-Rsyslog is an enhanced syslogd supporting, among others, MySQL,\
- PostgreSQL, failover log destinations, syslog/tcp, fine grain\
- output format control, high precision timestamps, queued operations\
- and the ability to filter on any message part. It is quite\
- compatible to stock sysklogd and can be used as a drop-in replacement.\
- Its advanced features make it suitable for enterprise-class,\
- encryption protected syslog relay chains while at the same time being\
- very easy to setup for the novice user."
-
-DEPENDS = "zlib libestr libfastjson bison-native flex-native liblogging"
-HOMEPAGE = "http://www.rsyslog.com/"
-LICENSE = "GPLv3 & LGPLv3 & Apache-2.0"
-LIC_FILES_CHKSUM = "file://COPYING;md5=51d9635e646fb75e1b74c074f788e973 \
-                    file://COPYING.LESSER;md5=cb7903f1e5c39ae838209e130dca270a \
-                    file://COPYING.ASL20;md5=052f8a09206615ab07326ff8ce2d9d32\
-"
-
-SRC_URI = "http://www.rsyslog.com/download/files/download/rsyslog/${BPN}-${PV}.tar.gz \
-           file://initscript \
-           file://rsyslog.conf \
-           file://rsyslog.logrotate \
-           file://use-pkgconfig-to-check-libgcrypt.patch \
-           file://run-ptest \
-           file://rsyslog-fix-ptest-not-finish.patch \
-"
-
-SRC_URI_append_libc-musl = " \
-    file://0001-Include-sys-time-h.patch \
-"
-
-SRC_URI[md5sum] = "3805617f65a4b4bea34606487a5255a0"
-SRC_URI[sha256sum] = "220ba30b5afb0f3ddb328613fea7aa3966b01e4d0c52d6de9ab27b0858f19738"
-
-inherit autotools pkgconfig systemd update-rc.d ptest
-
-EXTRA_OECONF += "--disable-generate-man-pages ap_cv_atomic_builtins=yes"
-
-# first line is default yes in configure
-PACKAGECONFIG ??= " \
-    rsyslogd rsyslogrt klog inet regexp uuid libgcrypt \
-    imdiag gnutls imfile \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'snmp systemd', d)} \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'ptest', 'testbench relp ${VALGRIND}', '', d)} \
-"
-
-# default yes in configure
-PACKAGECONFIG[relp] = "--enable-relp,--disable-relp,librelp,"
-PACKAGECONFIG[rsyslogd] = "--enable-rsyslogd,--disable-rsyslogd,,"
-PACKAGECONFIG[rsyslogrt] = "--enable-rsyslogrt,--disable-rsyslogrt,,"
-PACKAGECONFIG[inet] = "--enable-inet,--disable-inet,,"
-PACKAGECONFIG[klog] = "--enable-klog,--disable-klog,,"
-PACKAGECONFIG[regexp] = "--enable-regexp,--disable-regexp,,"
-PACKAGECONFIG[uuid] = "--enable-uuid,--disable-uuid,util-linux,"
-PACKAGECONFIG[libgcrypt] = "--enable-libgcrypt,--disable-libgcrypt,libgcrypt,"
-PACKAGECONFIG[testbench] = "--enable-testbench --enable-omstdout,--disable-testbench --disable-omstdout,,"
-
-# default no in configure
-PACKAGECONFIG[debug] = "--enable-debug,--disable-debug,,"
-PACKAGECONFIG[imdiag] = "--enable-imdiag,--disable-imdiag,,"
-PACKAGECONFIG[imfile] = "--enable-imfile,--disable-imfile,,"
-PACKAGECONFIG[snmp] = "--enable-snmp,--disable-snmp,net-snmp,"
-PACKAGECONFIG[gnutls] = "--enable-gnutls,--disable-gnutls,gnutls,"
-PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/,--without-systemdsystemunitdir,systemd,"
-PACKAGECONFIG[mysql] = "--enable-mysql,--disable-mysql,mysql5,"
-PACKAGECONFIG[postgresql] = "--enable-pgsql,--disable-pgsql,postgresql,"
-PACKAGECONFIG[libdbi] = "--enable-libdbi,--disable-libdbi,libdbi,"
-PACKAGECONFIG[mail] = "--enable-mail,--disable-mail,,"
-PACKAGECONFIG[valgrind] = "--enable-valgrind,--disable-valgrind,valgrind,"
-
-TESTDIR = "tests"
-do_compile_ptest() {
-    echo 'buildtest-TESTS: $(check_PROGRAMS)' >> ${TESTDIR}/Makefile
-    oe_runmake -C ${TESTDIR} buildtest-TESTS
-}
-
-do_install_ptest() {
-    # install the tests
-    cp -rf ${S}/${TESTDIR} ${D}${PTEST_PATH}
-    cp -rf ${B}/${TESTDIR} ${D}${PTEST_PATH}
-
-    # do NOT need to rebuild Makefile itself
-    sed -i 's/^Makefile:.*$/Makefile:/' ${D}${PTEST_PATH}/${TESTDIR}/Makefile
-
-    # fix the srcdir, top_srcdir
-    sed -i 's,^\(srcdir = \).*,\1${PTEST_PATH}/tests,' ${D}${PTEST_PATH}/${TESTDIR}/Makefile
-    sed -i 's,^\(top_srcdir = \).*,\1${PTEST_PATH}/tests,' ${D}${PTEST_PATH}/${TESTDIR}/Makefile
-
-    # valgrind is not compatible with arm and mips,
-    # so remove related test cases if there is no valgrind.
-    if [ x${VALGRIND} = x ]; then
-        sed -i '/udp-msgreduc-/d' ${D}${PTEST_PATH}/${TESTDIR}/Makefile
-    fi
-
-    # install test-driver
-    install -m 644 ${S}/test-driver ${D}${PTEST_PATH}
-
-    # install necessary links
-    install -d ${D}${PTEST_PATH}/tools
-    ln -sf ${sbindir}/rsyslogd ${D}${PTEST_PATH}/tools/rsyslogd
-
-    install -d ${D}${PTEST_PATH}/runtime
-    install -d ${D}${PTEST_PATH}/runtime/.libs
-    (
-        cd ${D}/${libdir}/rsyslog
-        allso="*.so"
-        for i in $allso; do
-            ln -sf ${libdir}/rsyslog/$i ${D}${PTEST_PATH}/runtime/.libs/$i
-        done
-    )
-
-    # fix the module load path with runtime/.libs
-    find ${D}${PTEST_PATH}/${TESTDIR} -name "*.conf" -o -name "*.sh" -o -name "*.c" | xargs \
-        sed -i -e 's:../plugins/.*/.libs/:../runtime/.libs/:g'
-}
-
-do_install_append() {
-    install -d "${D}${sysconfdir}/init.d"
-    install -d "${D}${sysconfdir}/logrotate.d"
-    install -m 755 ${WORKDIR}/initscript ${D}${sysconfdir}/init.d/syslog
-    install -m 644 ${WORKDIR}/rsyslog.conf ${D}${sysconfdir}/rsyslog.conf
-    install -m 644 ${WORKDIR}/rsyslog.logrotate ${D}${sysconfdir}/logrotate.d/logrotate.rsyslog
-}
-
-FILES_${PN} += "${bindir}"
-
-INITSCRIPT_NAME = "syslog"
-INITSCRIPT_PARAMS = "defaults"
-
-CONFFILES_${PN} = "${sysconfdir}/rsyslog.conf"
-
-RCONFLICTS_${PN} = "busybox-syslog sysklogd syslog-ng"
-
-RPROVIDES_${PN} += "${PN}-systemd"
-RREPLACES_${PN} += "${PN}-systemd"
-RCONFLICTS_${PN} += "${PN}-systemd"
-SYSTEMD_SERVICE_${PN} = "${BPN}.service"
-
-RDEPENDS_${PN} += "logrotate"
-
-# for rsyslog-ptest
-VALGRIND = "valgrind"
-VALGRIND_mips = ""
-VALGRIND_mips64 = ""
-VALGRIND_mips64n32 = ""
-VALGRIND_arm = ""
-VALGRIND_aarch64 = ""
-RDEPENDS_${PN}-ptest += "make diffutils gzip bash gawk coreutils procps"
-RRECOMMENDS_${PN}-ptest += "${TCLIBC}-dbg ${VALGRIND}"
diff --git a/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog_8.37.0.bb b/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog_8.37.0.bb
new file mode 100644
index 0000000..1fb4390
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/rsyslog/rsyslog_8.37.0.bb
@@ -0,0 +1,166 @@
+SUMMARY = "Rsyslog is an enhanced multi-threaded syslogd"
+DESCRIPTION = "\
+Rsyslog is an enhanced syslogd supporting, among others, MySQL,\
+ PostgreSQL, failover log destinations, syslog/tcp, fine grain\
+ output format control, high precision timestamps, queued operations\
+ and the ability to filter on any message part. It is quite\
+ compatible to stock sysklogd and can be used as a drop-in replacement.\
+ Its advanced features make it suitable for enterprise-class,\
+ encryption protected syslog relay chains while at the same time being\
+ very easy to setup for the novice user."
+
+DEPENDS = "zlib libestr libfastjson bison-native flex-native liblogging"
+HOMEPAGE = "http://www.rsyslog.com/"
+LICENSE = "GPLv3 & LGPLv3 & Apache-2.0"
+LIC_FILES_CHKSUM = "file://COPYING;md5=51d9635e646fb75e1b74c074f788e973 \
+                    file://COPYING.LESSER;md5=cb7903f1e5c39ae838209e130dca270a \
+                    file://COPYING.ASL20;md5=052f8a09206615ab07326ff8ce2d9d32\
+"
+
+SRC_URI = "http://www.rsyslog.com/download/files/download/rsyslog/${BPN}-${PV}.tar.gz \
+           file://initscript \
+           file://rsyslog.conf \
+           file://rsyslog.logrotate \
+           file://use-pkgconfig-to-check-libgcrypt.patch \
+           file://run-ptest \
+           file://rsyslog-fix-ptest-not-finish.patch \
+"
+
+SRC_URI_append_libc-musl = " \
+    file://0001-Include-sys-time-h.patch \
+"
+
+SRC_URI[md5sum] = "e0942b4b88a13602a6b6352bf9f05091"
+SRC_URI[sha256sum] = "295c289b4c8abd8f8f3fe35a83249b739cedabe82721702b910255f9faf147e7"
+
+UPSTREAM_CHECK_URI = "https://github.com/rsyslog/rsyslog/releases"
+UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)"
+
+inherit autotools pkgconfig systemd update-rc.d ptest
+
+EXTRA_OECONF += "--disable-generate-man-pages ap_cv_atomic_builtins=yes"
+
+# first line is default yes in configure
+PACKAGECONFIG ??= " \
+    rsyslogd rsyslogrt klog inet regexp uuid libgcrypt \
+    fmhttp imdiag gnutls imfile \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'snmp systemd', d)} \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'ptest', 'testbench relp ${VALGRIND}', '', d)} \
+"
+
+# default yes in configure
+PACKAGECONFIG[relp] = "--enable-relp,--disable-relp,librelp,"
+PACKAGECONFIG[rsyslogd] = "--enable-rsyslogd,--disable-rsyslogd,,"
+PACKAGECONFIG[rsyslogrt] = "--enable-rsyslogrt,--disable-rsyslogrt,,"
+PACKAGECONFIG[fmhttp] = "--enable-fmhttp,--disable-fmhttp,curl,"
+PACKAGECONFIG[inet] = "--enable-inet,--disable-inet,,"
+PACKAGECONFIG[klog] = "--enable-klog,--disable-klog,,"
+PACKAGECONFIG[regexp] = "--enable-regexp,--disable-regexp,,"
+PACKAGECONFIG[uuid] = "--enable-uuid,--disable-uuid,util-linux,"
+PACKAGECONFIG[libgcrypt] = "--enable-libgcrypt,--disable-libgcrypt,libgcrypt,"
+PACKAGECONFIG[testbench] = "--enable-testbench --enable-omstdout,--disable-testbench --disable-omstdout,,"
+
+# default no in configure
+PACKAGECONFIG[debug] = "--enable-debug,--disable-debug,,"
+PACKAGECONFIG[imdiag] = "--enable-imdiag,--disable-imdiag,,"
+PACKAGECONFIG[imfile] = "--enable-imfile,--disable-imfile,,"
+PACKAGECONFIG[snmp] = "--enable-snmp,--disable-snmp,net-snmp,"
+PACKAGECONFIG[gnutls] = "--enable-gnutls,--disable-gnutls,gnutls,"
+PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/,--without-systemdsystemunitdir,systemd,"
+PACKAGECONFIG[imjournal] = "--enable-imjournal,--disable-imjournal,"
+PACKAGECONFIG[mysql] = "--enable-mysql,--disable-mysql,mysql5,"
+PACKAGECONFIG[postgresql] = "--enable-pgsql,--disable-pgsql,postgresql,"
+PACKAGECONFIG[libdbi] = "--enable-libdbi,--disable-libdbi,libdbi,"
+PACKAGECONFIG[mail] = "--enable-mail,--disable-mail,,"
+PACKAGECONFIG[valgrind] = "--enable-valgrind,--disable-valgrind,valgrind,"
+
+TESTDIR = "tests"
+do_compile_ptest() {
+    echo 'buildtest-TESTS: $(check_PROGRAMS)' >> ${TESTDIR}/Makefile
+    oe_runmake -C ${TESTDIR} buildtest-TESTS
+}
+
+do_install_ptest() {
+    # install the tests
+    cp -rf ${S}/${TESTDIR} ${D}${PTEST_PATH}
+    cp -rf ${B}/${TESTDIR} ${D}${PTEST_PATH}
+
+    # do NOT need to rebuild Makefile itself
+    sed -i 's/^Makefile:.*$/Makefile:/' ${D}${PTEST_PATH}/${TESTDIR}/Makefile
+    # do NOT need to rebuild $(check_PROGRAMS)
+    sed -i 's/^check-TESTS:.*$/check-TESTS:/' ${D}${PTEST_PATH}/${TESTDIR}/Makefile
+
+    # fix the srcdir, top_srcdir
+    sed -i 's,^\(srcdir = \).*,\1${PTEST_PATH}/tests,' ${D}${PTEST_PATH}/${TESTDIR}/Makefile
+    sed -i 's,^\(top_srcdir = \).*,\1${PTEST_PATH}/tests,' ${D}${PTEST_PATH}/${TESTDIR}/Makefile
+    # fix the abs_top_builddir
+    sed -i 's,^\(abs_top_builddir = \).*,\1${PTEST_PATH}/,' ${D}${PTEST_PATH}/${TESTDIR}/Makefile
+
+    # valgrind is not compatible with arm and mips,
+    # so remove related test cases if there is no valgrind.
+    if [ x${VALGRIND} = x ]; then
+        sed -i '/udp-msgreduc-/d' ${D}${PTEST_PATH}/${TESTDIR}/Makefile
+    fi
+
+    # install test-driver
+    install -m 644 ${S}/test-driver ${D}${PTEST_PATH}
+
+    # install necessary links
+    install -d ${D}${PTEST_PATH}/tools
+    ln -sf ${sbindir}/rsyslogd ${D}${PTEST_PATH}/tools/rsyslogd
+
+    install -d ${D}${PTEST_PATH}/runtime
+    install -d ${D}${PTEST_PATH}/runtime/.libs
+    (
+        cd ${D}/${libdir}/rsyslog
+        allso="*.so"
+        for i in $allso; do
+            ln -sf ${libdir}/rsyslog/$i ${D}${PTEST_PATH}/runtime/.libs/$i
+        done
+    )
+
+    # fix the module load path with runtime/.libs
+    find ${D}${PTEST_PATH}/${TESTDIR} -name "*.conf" -o -name "*.sh" -o -name "*.c" | xargs \
+        sed -i -e 's:../plugins/.*/.libs/:../runtime/.libs/:g'
+}
+
+do_install_append() {
+    install -d "${D}${sysconfdir}/init.d"
+    install -d "${D}${sysconfdir}/logrotate.d"
+    install -m 755 ${WORKDIR}/initscript ${D}${sysconfdir}/init.d/syslog
+    install -m 644 ${WORKDIR}/rsyslog.conf ${D}${sysconfdir}/rsyslog.conf
+    install -m 644 ${WORKDIR}/rsyslog.logrotate ${D}${sysconfdir}/logrotate.d/logrotate.rsyslog
+    sed -i -e "s#@BINDIR@#${bindir}#g" ${D}${sysconfdir}/logrotate.d/logrotate.rsyslog
+
+    if ${@bb.utils.contains('PACKAGECONFIG', 'imjournal', 'true', 'false', d)}; then
+        install -d 0755 ${D}${sysconfdir}/rsyslog.d
+        echo '$ModLoad imjournal' >> ${D}${sysconfdir}/rsyslog.d/imjournal.conf
+    fi
+}
+
+FILES_${PN} += "${bindir}"
+
+INITSCRIPT_NAME = "syslog"
+INITSCRIPT_PARAMS = "defaults"
+
+CONFFILES_${PN} = "${sysconfdir}/rsyslog.conf"
+
+RCONFLICTS_${PN} = "busybox-syslog sysklogd syslog-ng"
+
+RPROVIDES_${PN} += "${PN}-systemd"
+RREPLACES_${PN} += "${PN}-systemd"
+RCONFLICTS_${PN} += "${PN}-systemd"
+SYSTEMD_SERVICE_${PN} = "${BPN}.service"
+
+RDEPENDS_${PN} += "logrotate"
+
+# for rsyslog-ptest
+VALGRIND = "valgrind"
+VALGRIND_mips = ""
+VALGRIND_mips64 = ""
+VALGRIND_mips64n32 = ""
+VALGRIND_arm = ""
+VALGRIND_aarch64 = ""
+VALGRIND_riscv64 = ""
+RDEPENDS_${PN}-ptest += "make diffutils gzip bash gawk coreutils procps"
+RRECOMMENDS_${PN}-ptest += "${TCLIBC}-dbg ${VALGRIND}"
diff --git a/meta-openembedded/meta-oe/recipes-extended/sanlock/sanlock/0001-fix-compile-failure-with-libc-musl.patch b/meta-openembedded/meta-oe/recipes-extended/sanlock/sanlock/0001-fix-compile-failure-with-libc-musl.patch
new file mode 100644
index 0000000..e4bde80
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/sanlock/sanlock/0001-fix-compile-failure-with-libc-musl.patch
@@ -0,0 +1,80 @@
+From c51c2c543f3c78b2a68acc61f786f903f2e0fec8 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Sun, 9 Sep 2018 07:28:09 -0400
+Subject: [PATCH] fix compile failure with libc musl
+
+The lack of random_r in musl:
+[snip]
+|main.c:1393:7: warning: implicit declaration of function 'random_r';
+did you mean 'random'? [-Wimplicit-function-declaration]
+|  rv = random_r(&rand_data, &val);
+|       ^~~~~~~~
+|       random
+|main.c:1408:30: error: invalid application of 'sizeof' to incomplete
+type 'struct random_data'
+|  memset(&rand_data, 0, sizeof(rand_data));
+[snip]
+
+s/random_r/random/, s/initstate_r/initstate/ and remove `static struct
+random_data rand_data'
+
+Here is the man of `random_r()':
+[snip]
+The random_r() function is like random(3), except that instead of using
+state information maintained in a global variable
+[snip]
+
+So use random without state information is OK.
+
+Upstream-Status: Submitted [sanlock-devel@lists.fedorahosted.org]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ src/main.c | 12 ++++--------
+ 1 file changed, 4 insertions(+), 8 deletions(-)
+
+diff --git a/src/main.c b/src/main.c
+index f60b4d3..602c400 100644
+--- a/src/main.c
++++ b/src/main.c
+@@ -84,7 +84,6 @@ static char command[COMMAND_MAX];
+ static int cmd_argc;
+ static char **cmd_argv;
+ static struct thread_pool pool;
+-static struct random_data rand_data;
+ static char rand_state[32];
+ static pthread_mutex_t rand_mutex = PTHREAD_MUTEX_INITIALIZER;
+ static const char *run_dir = NULL;
+@@ -1386,16 +1385,15 @@ int get_rand(int a, int b);
+ 
+ int get_rand(int a, int b)
+ {
+-	int32_t val;
+-	int rv;
++	long int rv;
+ 
+ 	pthread_mutex_lock(&rand_mutex);
+-	rv = random_r(&rand_data, &val);
++	rv = random();
+ 	pthread_mutex_unlock(&rand_mutex);
+ 	if (rv < 0)
+ 		return rv;
+ 
+-	return a + (int) (((float)(b - a + 1)) * val / (RAND_MAX+1.0));
++	return a + (int) (((float)(b - a + 1)) * rv / (RAND_MAX+1.0));
+ }
+ 
+ static void setup_host_name(void)
+@@ -1405,9 +1403,7 @@ static void setup_host_name(void)
+ 	uuid_t uu;
+ 
+ 	memset(rand_state, 0, sizeof(rand_state));
+-	memset(&rand_data, 0, sizeof(rand_data));
+-
+-	initstate_r(time(NULL), rand_state, sizeof(rand_state), &rand_data);
++	initstate(time(NULL), rand_state, sizeof(rand_state));
+ 
+ 	/* use host name from command line */
+ 
+-- 
+2.8.1
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/sanlock/sanlock_3.6.0.bb b/meta-openembedded/meta-oe/recipes-extended/sanlock/sanlock_3.6.0.bb
new file mode 100644
index 0000000..c51bccc
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/sanlock/sanlock_3.6.0.bb
@@ -0,0 +1,36 @@
+SUMMARY = "A shared storage lock manager"
+DESCRIPTION = "sanlock  is  a lock manager built on shared storage.  Hosts with access \
+to the storage can perform locking.   An  application  running  on  the \
+hosts  is  given  a small amount of space on the shared block device or \
+file, and uses sanlock for its  own  application-specific  synchronization. \
+Internally,  the  sanlock  daemon manages locks using two disk-based \
+lease algorithms: delta leases and paxos leases."
+HOMEPAGE = "https://pagure.io/sanlock"
+SECTION = "utils"
+
+LICENSE = "LGPLv2+ & GPLv2 & GPLv2+"
+LIC_FILES_CHKSUM = "file://README.license;md5=60487bf0bf429d6b5aa72b6d37a0eb22"
+
+SRC_URI = "git://pagure.io/sanlock.git;protocol=http \
+           file://0001-fix-compile-failure-with-libc-musl.patch \
+          "
+SRCREV = "90b2ffa77edd46bea007b7bb39bfd4d2db2ff7af"
+S = "${WORKDIR}/git"
+
+DEPENDS = "libaio util-linux"
+
+inherit distutils
+
+do_configure[noexec] = "1"
+
+do_compile_prepend () {
+    oe_runmake -C wdmd CMD_LDFLAGS="${LDFLAGS}" LIB_LDFLAGS="${LDFLAGS}"
+    oe_runmake -C src CMD_LDFLAGS="${LDFLAGS}" LIB_ENTIRE_LDFLAGS="${LDFLAGS}" LIB_CLIENT_LDFLAGS="${LDFLAGS}"
+    cd ${S}/python
+}
+
+do_install_prepend () {
+    oe_runmake -C wdmd DESTDIR=${D} LIBDIR=${libdir} install
+    oe_runmake -C src DESTDIR=${D} LIBDIR=${libdir} install
+    cd ${S}/python
+}
diff --git a/meta-openembedded/meta-oe/recipes-extended/sblim-sfcb/sblim-sfcb-1.4.9/sblim-sfcb-1.4.9-fix-sfcbinst2mof.patch b/meta-openembedded/meta-oe/recipes-extended/sblim-sfcb/sblim-sfcb-1.4.9/sblim-sfcb-1.4.9-fix-sfcbinst2mof.patch
new file mode 100644
index 0000000..7279d84
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/sblim-sfcb/sblim-sfcb-1.4.9/sblim-sfcb-1.4.9-fix-sfcbinst2mof.patch
@@ -0,0 +1,31 @@
+From ad6ca4f392bf549239b1ed3b2b372070eb127e7f Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Wed, 11 Jul 2018 11:06:04 +0800
+Subject: [PATCH] Makefile.am: fix sfcbinst2mof_DEPENDENCIES
+
+Fixed build with automake 1.16.1:
+/path/to/i586-poky-linux/8.1.0/ld: cannot find -lsfcBrokerCore
+collect2: error: ld returned 1 exit status
+
+Upstream-Status: Pending
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ Makefile.am | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/Makefile.am b/Makefile.am
+index 34ac319..47deed7 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -360,6 +360,7 @@ sfcbproc_SOURCES=sfcbproc.c
+ 
+ sfcbinst2mof_SOURCES=sfcbinst2mof.c
+ sfcbinst2mof_LDADD = -lsfcFileRepository -lsfcBrokerCore
++sfcbinst2mof_DEPENDENCIES = libsfcBrokerCore.la libsfcFileRepository.la
+ 
+ sfcbtrace_SOURCES=sfcbtrace.c
+ sfcbtrace_LDADD = -lsfcBrokerCore
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/sblim-sfcb/sblim-sfcb_1.4.9.bb b/meta-openembedded/meta-oe/recipes-extended/sblim-sfcb/sblim-sfcb_1.4.9.bb
index 10ffaaa..91c5002 100644
--- a/meta-openembedded/meta-oe/recipes-extended/sblim-sfcb/sblim-sfcb_1.4.9.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/sblim-sfcb/sblim-sfcb_1.4.9.bb
@@ -25,6 +25,7 @@
            file://sblim-sfcb-1.4.9-fix-ftbfs.patch \
            file://0001-include-stdint.h-system-header-for-UINT16_MAX.patch \
            file://0001-Replace-need-for-error.h-when-it-does-not-exist.patch \
+           file://sblim-sfcb-1.4.9-fix-sfcbinst2mof.patch \
 "
 
 SRC_URI[md5sum] = "28021cdabc73690a94f4f9d57254ce30"
@@ -67,14 +68,8 @@
 }
 
 pkg_postinst_${PN} () {
-    OPTS=""
-
     if [ x"$D" != "x" ]; then
-        OPTS="--root=$D"
-        if type systemctl >/dev/null 2>/dev/null; then
-                systemctl $OPTS ${SYSTEMD_AUTO_ENABLE} ${SYSTEMD_SERVICE}
-        fi
-        exit 1
+        $INTERCEPT_DIR/postinst_intercept delay_to_first_boot ${PKG} mlprefix=${MLPREFIX}
     fi
 
     ${datadir}/sfcb/genSslCert.sh ${sysconfdir}/sfcb
diff --git a/meta-openembedded/meta-oe/recipes-extended/scsirastools/scsirastools_1.6.6.bb b/meta-openembedded/meta-oe/recipes-extended/scsirastools/scsirastools_1.6.6.bb
index e202d16..77d3cfe 100644
--- a/meta-openembedded/meta-oe/recipes-extended/scsirastools/scsirastools_1.6.6.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/scsirastools/scsirastools_1.6.6.bb
@@ -33,16 +33,14 @@
 INITSCRIPT_NAME_${PN}-raidmon = "sgraid"
 INITSCRIPT_PARAMS_${PN}-raidmon = "defaults 80 20"
 
-PACKAGES =+ "${PN}-diskmon ${PN}-diskmon-dbg"
-PACKAGES =+ "${PN}-raidmon ${PN}-raidmon-dbg"
+PACKAGES =+ "${PN}-diskmon"
+PACKAGES =+ "${PN}-raidmon"
 
-FILES_${PN}-dbg += "/usr/share/scsirastools/.debug"
+RPROVIDES_${PN}-dbg += "${PN}-diskmon-dbg ${PN}-raidmon-dbg"
 
 FILES_${PN}-diskmon = "${sbindir}/sgdiskmon ${sysconfdir}/init.d/sgdisk"
-FILES_${PN}-diskmon-dbg = "${sbindir}/.debug/sgdiskmon"
 
 FILES_${PN}-raidmon = "${sbindir}/sgraidmon ${sysconfdir}/init.d/sgraid"
-FILES_${PN}-raidmon-dbg = "${sbindir}/.debug/sgraidmon"
 
 RDEPENDS_${PN} += "bash"
 RDEPENDS_${PN}-diskmon += "${PN}"
diff --git a/meta-openembedded/meta-oe/recipes-extended/sedutil/sedutil_git.bb b/meta-openembedded/meta-oe/recipes-extended/sedutil/sedutil_git.bb
new file mode 100644
index 0000000..cec569f
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/sedutil/sedutil_git.bb
@@ -0,0 +1,17 @@
+DESCRIPTION = "A utility to manage self encrypting drives that conform \
+to the Trusted Computing Group OPAL 2.0 SSC specification."
+SUMMARY = "The Drive Trust Alliance Self Encrypting Drive Utility"
+HOMEPAGE = "https://github.com/Drive-Trust-Alliance/sedutil"
+SECTION = "console/utils"
+LICENSE = "GPLv3"
+
+LIC_FILES_CHKSUM = "file://Common/LICENSE.txt;md5=d32239bcb673463ab874e80d47fae504"
+
+BASEPV = "1.15.1"
+PV = "${BASEPV}+git${SRCPV}"
+SRCREV = "358cc758948be788284d5faba46ccf4cc1813796"
+SRC_URI = "git://github.com/Drive-Trust-Alliance/sedutil.git"
+
+S = "${WORKDIR}/git"
+
+inherit autotools-brokensep
diff --git a/meta-openembedded/meta-oe/recipes-extended/smartmontools/files/0001-os_linux.cpp-Use-realpath-BSD-POSIX-instead-of-canon.patch b/meta-openembedded/meta-oe/recipes-extended/smartmontools/files/0001-os_linux.cpp-Use-realpath-BSD-POSIX-instead-of-canon.patch
new file mode 100644
index 0000000..91e64d2
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/smartmontools/files/0001-os_linux.cpp-Use-realpath-BSD-POSIX-instead-of-canon.patch
@@ -0,0 +1,28 @@
+From f28aa188e5b0ea85369febe657b8807b8025038b Mon Sep 17 00:00:00 2001
+From: chrfranke <authors@smartmontools.org>
+Date: Wed, 8 Nov 2017 06:15:50 +0000
+Subject: [PATCH] os_linux.cpp: Use 'realpath()' (BSD, POSIX) instead of
+ 'canonicalize_file_name()' (GNU extension). This fixes build on systems with
+ musl libc (#921).
+
+git-svn-id: http://svn.code.sf.net/p/smartmontools/code/trunk@4603 4ea69e1a-61f1-4043-bf83-b5c94c648137
+
+Upstream-Status: Backport [https://www.smartmontools.org/ticket/921]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ os_linux.cpp | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/os_linux.cpp b/os_linux.cpp
+index 134d5bc..935f9c7 100644
+--- a/os_linux.cpp
++++ b/os_linux.cpp
+@@ -3176,7 +3176,7 @@ static bool is_hpsa(const char * name)
+ {
+   char path[128];
+   snprintf(path, sizeof(path), "/sys/block/%s/device", name);
+-  char * syshostpath = canonicalize_file_name(path);
++  char * syshostpath = realpath(name, (char *)0);
+   if (!syshostpath)
+     return false;
+ 
diff --git a/meta-openembedded/meta-oe/recipes-extended/smartmontools/smartmontools_6.6.bb b/meta-openembedded/meta-oe/recipes-extended/smartmontools/smartmontools_6.6.bb
index 1a1767e..c77c105 100644
--- a/meta-openembedded/meta-oe/recipes-extended/smartmontools/smartmontools_6.6.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/smartmontools/smartmontools_6.6.bb
@@ -1,6 +1,6 @@
 SUMMARY = "Control and monitor storage systems using S.M.A.R.T"
-DESCRIPTION = \
-"The smartmontools package contains two utility programs (smartctl \
+DESCRIPTION = "\
+The smartmontools package contains two utility programs (smartctl \
 and smartd) to control and monitor storage systems using the Self-\
 Monitoring, Analysis and Reporting Technology System (SMART) built \
 into most modern ATA and SCSI hard disks. In many cases, these \
@@ -13,10 +13,11 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
 
 SRC_URI = "${SOURCEFORGE_MIRROR}/smartmontools/smartmontools-${PV}.tar.gz \
-    file://initd.smartd \
-    file://smartmontools.default \
-    file://smartd.service \
-"
+           file://initd.smartd \
+           file://smartmontools.default \
+           file://smartd.service \
+           file://0001-os_linux.cpp-Use-realpath-BSD-POSIX-instead-of-canon.patch \
+           "
 
 PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'libcap-ng selinux', d)}"
 PACKAGECONFIG[libcap-ng] = "--with-libcap-ng=yes,--with-libcap-ng=no,libcap-ng"
diff --git a/meta-openembedded/meta-oe/recipes-extended/snappy/snappy_1.1.7.bb b/meta-openembedded/meta-oe/recipes-extended/snappy/snappy_1.1.7.bb
new file mode 100644
index 0000000..9f37c5f
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/snappy/snappy_1.1.7.bb
@@ -0,0 +1,25 @@
+#
+# Copyright (C) 2014 Wind River Systems, Inc.
+# Released under the BSD-3-Clause license (see COPYING.BSD-3 for the terms)
+#
+SUMMARY = "A compression/decompression library"
+DESCRIPTION = "Snappy is a fast data compression and decompression library \
+It was designed to be very fast and stable, but not to achieve a high \
+compression ratio."
+
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://COPYING;md5=f62f3080324a97b3159a7a7e61812d0c"
+
+SRC_URI = "https://src.fedoraproject.org/repo/pkgs/snappy/snappy-1.1.7.tar.gz/sha512/32046f532606ba545a4e4825c0c66a19be449f2ca2ff760a6fa170a3603731479a7deadb683546e5f8b5033414c50f4a9a29f6d23b7a41f047e566e69eca7caf/snappy-1.1.7.tar.gz"
+
+SRC_URI[md5sum] = "ee9086291c9ae8deb4dac5e0b85bf54a"
+SRC_URI[sha256sum] = "3dfa02e873ff51a11ee02b9ca391807f0c8ea0529a4924afa645fbf97163f9d4"
+
+inherit cmake pkgconfig
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[lzo] = "-DHAVE_LIBLZO2=1,-DHAVE_LIBLZO2=0,lzo,"
+TARGET_CFLAGS += "-fPIC"
+
+EXTRA_OECMAKE += '-DBUILD_SHARED_LIBS="ON" \
+                  '
diff --git a/meta-openembedded/meta-oe/recipes-extended/socketcan/can-isotp_git.bb b/meta-openembedded/meta-oe/recipes-extended/socketcan/can-isotp_git.bb
index 3c019eb..6ce3cab 100644
--- a/meta-openembedded/meta-oe/recipes-extended/socketcan/can-isotp_git.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/socketcan/can-isotp_git.bb
@@ -1,6 +1,6 @@
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING;md5=72d977d697c3c05830fdff00a7448931"
-SRCREV = "d1248b0f22ea8dc3b9d84a61bd35a83309bdb4b4"
+SRCREV = "6003f9997587e6a563cebf1f246bcd0eb6deff3d"
 PV = "1.0+git${SRCPV}"
 
 SRC_URI = "git://github.com/hartkopp/can-isotp.git;protocol=https"
diff --git a/meta-openembedded/meta-oe/recipes-extended/tiptop/tiptop/0001-Fix-build-when-S-B.patch b/meta-openembedded/meta-oe/recipes-extended/tiptop/tiptop/0001-Fix-build-when-S-B.patch
new file mode 100644
index 0000000..51756b8
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/tiptop/tiptop/0001-Fix-build-when-S-B.patch
@@ -0,0 +1,28 @@
+From ad907b1aff217fe3b431ae052025ba8ba6cacc01 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 20 Jun 2018 23:14:58 -0700
+Subject: [PATCH] Fix build when S != B
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/Makefile.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/Makefile.in b/src/Makefile.in
+index 4392c06..2c5cae4 100644
+--- a/src/Makefile.in
++++ b/src/Makefile.in
+@@ -69,7 +69,7 @@ install:
+ 	$(INSTALL) -d $(DESTDIR)$(bindir)
+ 	$(INSTALL) -m 0755 tiptop $(DESTDIR)$(bindir)
+ 	$(INSTALL) -d $(DESTDIR)$(man1dir)
+-	$(INSTALL) -m 0644 tiptop.1 $(DESTDIR)$(man1dir)
++	$(INSTALL) -m 0644 $(srcdir)/tiptop.1 $(DESTDIR)$(man1dir)
+ 	ln $(DESTDIR)$(bindir)/tiptop $(DESTDIR)$(bindir)/ptiptop
+ 	ln $(DESTDIR)$(man1dir)/tiptop.1 $(DESTDIR)$(man1dir)/ptiptop.1
+ 
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/tiptop/tiptop/0001-Fix-parallel-build-problems-by-Adrian-Bunk.patch b/meta-openembedded/meta-oe/recipes-extended/tiptop/tiptop/0001-Fix-parallel-build-problems-by-Adrian-Bunk.patch
new file mode 100644
index 0000000..ae676ae
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/tiptop/tiptop/0001-Fix-parallel-build-problems-by-Adrian-Bunk.patch
@@ -0,0 +1,28 @@
+From 848983a30dc99248ec45632bfc31718716a86e9d Mon Sep 17 00:00:00 2001
+From: Tomasz Buchert <tomasz@debian.org>
+Date: Fri, 7 Jul 2017 21:15:58 +0200
+Subject: [PATCH] Fix parallel build problems (by Adrian Bunk)
+
+Taken from debian
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/Makefile.in | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/src/Makefile.in b/src/Makefile.in
+index 32ab563..1993c9b 100644
+--- a/src/Makefile.in
++++ b/src/Makefile.in
+@@ -59,8 +59,9 @@ lex.yy.c: calc.lex
+ lex.yy.o: lex.yy.c
+ 	$(CC) $(CFLAGS) -I$(srcdir) -c lex.yy.c
+ 
++y.tab.c: y.tab.h
+ 
+-y.tab.c y.tab.h: calc.y
++y.tab.h: calc.y
+ 	$(YACC) -d $(srcdir)/calc.y
+ 
+ y.tab.o: y.tab.c
diff --git a/meta-openembedded/meta-oe/recipes-extended/tiptop/tiptop/0002-fix-reproducibility-of-build-process.patch b/meta-openembedded/meta-oe/recipes-extended/tiptop/tiptop/0002-fix-reproducibility-of-build-process.patch
new file mode 100644
index 0000000..cecb70b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/tiptop/tiptop/0002-fix-reproducibility-of-build-process.patch
@@ -0,0 +1,32 @@
+From 89dd9d8705408dccd5c5e47d22eba6fd6ec22b50 Mon Sep 17 00:00:00 2001
+From: Tomasz Buchert <tomasz@debian.org>
+Date: Thu, 9 Jul 2015 16:07:23 +0200
+Subject: [PATCH] fix reproducibility of build process
+
+The upstream Makefile sets macros that depend on
+a particular platform where the package is built.
+We don't set them which fixes the problem.
+
+Taken from debian
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/Makefile.in | 4 +---
+ 1 file changed, 1 insertion(+), 3 deletions(-)
+
+diff --git a/src/Makefile.in b/src/Makefile.in
+index 1993c9b..4392c06 100644
+--- a/src/Makefile.in
++++ b/src/Makefile.in
+@@ -48,9 +48,7 @@ Makefile: Makefile.in ../config.status
+ 
+ 
+ version.o: version.c
+-	$(CC) $(CFLAGS) -DCOMPILE_HOST="\""`hostname`"\"" \
+-                        -DCOMPILE_DATE="\"`date`\"" \
+-                        -c $(srcdir)/version.c
++	$(CC) $(CFLAGS) -c $(srcdir)/version.c
+ 
+ 
+ lex.yy.c: calc.lex
diff --git a/meta-openembedded/meta-oe/recipes-extended/tiptop/tiptop_2.3.1.bb b/meta-openembedded/meta-oe/recipes-extended/tiptop/tiptop_2.3.1.bb
index 0a00a36..cf67a08 100644
--- a/meta-openembedded/meta-oe/recipes-extended/tiptop/tiptop_2.3.1.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/tiptop/tiptop_2.3.1.bb
@@ -2,15 +2,20 @@
 HOMEPAGE = "http://tiptop.gforge.inria.fr/"
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-DEPENDS = "ncurses libxml2"
+DEPENDS = "ncurses libxml2 bison-native flex-native"
 
-SRC_URI = "http://tiptop.gforge.inria.fr/releases/${BP}.tar.gz"
+SRC_URI = "http://tiptop.gforge.inria.fr/releases/${BP}.tar.gz \
+           file://0001-Fix-parallel-build-problems-by-Adrian-Bunk.patch \
+           file://0002-fix-reproducibility-of-build-process.patch \
+           file://0001-Fix-build-when-S-B.patch \
+           "
 SRC_URI[md5sum] = "46ca0fdf0236f02dd2b96d347626d2a2"
 SRC_URI[sha256sum] = "51c4449c95bba34f16b429729c2f58431490665d8093efaa8643b2e1d1084182"
 
-inherit autotools-brokensep
+inherit autotools
+
 EXTRA_OECONF = "CFLAGS="$CFLAGS -I${STAGING_INCDIR}/libxml2""
-COMPATIBLE_HOST = "(i.86|x86_64|arm|powerpc).*-linux"
+COMPATIBLE_HOST = "(i.86|x86_64|arm|powerpc|aarch64).*-linux"
 
 do_configure_prepend () {
     # Two bugs in configure.ac when cross-compiling.
diff --git a/meta-openembedded/meta-oe/recipes-extended/upm/upm/0001-Replace-strncpy-with-memcpy.patch b/meta-openembedded/meta-oe/recipes-extended/upm/upm/0001-Replace-strncpy-with-memcpy.patch
new file mode 100644
index 0000000..4b17087
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/upm/upm/0001-Replace-strncpy-with-memcpy.patch
@@ -0,0 +1,49 @@
+From d314f26e024aaf15bf4ab22ceb98501148d0eac8 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 7 May 2018 19:53:33 -0700
+Subject: [PATCH] Replace strncpy with memcpy
+
+gcc8 detects that strncpy is overwiritng the null terminating character
+the source strings are already initialized to 0 so memcpy would do the same
+job
+
+Fixes
+rn2903.c:153:5: error: 'strncpy' output may be truncated copying 16 bytes from a string of length 511 [-Werror=stringop-truncation]
+     strncpy(dev->hardware_eui, dev->resp_data, RN2903_MAX_HEX_EUI64);
+     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/ecezo/ecezo.c   | 2 +-
+ src/rn2903/rn2903.c | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/ecezo/ecezo.c b/src/ecezo/ecezo.c
+index 6a195fc1..56c6dab3 100644
+--- a/src/ecezo/ecezo.c
++++ b/src/ecezo/ecezo.c
+@@ -488,7 +488,7 @@ int ecezo_send_command(const ecezo_context dev, char *cmd, char *buffer,
+     // our write buffer
+     char writeBuffer[ECEZO_MAX_BUFFER_LEN];
+ 
+-    strncpy(writeBuffer, cmd, ECEZO_MAX_BUFFER_LEN);
++    memcpy(writeBuffer, cmd, ECEZO_MAX_BUFFER_LEN-1);
+     writeBuffer[ECEZO_MAX_BUFFER_LEN - 1] = 0;
+ 
+     int writelen = strlen(writeBuffer);
+diff --git a/src/rn2903/rn2903.c b/src/rn2903/rn2903.c
+index f30a33ae..01a011da 100644
+--- a/src/rn2903/rn2903.c
++++ b/src/rn2903/rn2903.c
+@@ -150,7 +150,7 @@ static rn2903_context _rn2903_postinit(rn2903_context dev,
+         rn2903_close(dev);
+         return NULL;
+     }
+-    strncpy(dev->hardware_eui, dev->resp_data, RN2903_MAX_HEX_EUI64);
++    memcpy(dev->hardware_eui, dev->resp_data, RN2903_MAX_HEX_EUI64);
+ 
+     return dev;
+ }
+-- 
+2.17.0
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/upm/upm/0001-include-sys-types.h-for-uint-definition.patch b/meta-openembedded/meta-oe/recipes-extended/upm/upm/0001-include-sys-types.h-for-uint-definition.patch
new file mode 100644
index 0000000..a0a4741
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/upm/upm/0001-include-sys-types.h-for-uint-definition.patch
@@ -0,0 +1,33 @@
+From 48a580bd402cf6a3ee9e42013653219bfeb3caf6 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 21 Jun 2018 18:39:16 -0700
+Subject: [PATCH] include sys/types.h for uint definition
+
+uint is defined in sys/types.h, therefore this
+header needs to be included, it gets exposed with
+musl where this header is not getting included indirectly
+as it is happening when building on glibc
+
+Fixes build errors on musl e.g.
+upm/src/kx122/kx122.hpp:456:31: error: 'uint' has not been declared
+|        void setBufferThreshold(uint samples);
+|                                ^~~~
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Submitted [https://github.com/intel-iot-devkit/upm/pull/656]
+ src/kx122/kx122.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/kx122/kx122.h b/src/kx122/kx122.h
+index 1622ed50..56e5215e 100644
+--- a/src/kx122/kx122.h
++++ b/src/kx122/kx122.h
+@@ -31,6 +31,7 @@ extern "C"{
+ #include <assert.h>
+ #include <unistd.h>
+ #include <math.h>
++#include <sys/types.h>
+ 
+ #include <mraa/i2c.h>
+ #include <mraa/spi.h>
diff --git a/meta-openembedded/meta-oe/recipes-extended/upm/upm_git.bb b/meta-openembedded/meta-oe/recipes-extended/upm/upm_git.bb
index d742a5e..babe5f4 100644
--- a/meta-openembedded/meta-oe/recipes-extended/upm/upm_git.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/upm/upm_git.bb
@@ -7,12 +7,13 @@
 
 DEPENDS = "libjpeg-turbo mraa"
 
-SRCREV = "cc7fec9ae0228add9011bf1c2cd5e0ca2ba0d4f0"
+SRCREV = "dc45cd78595c7c24c8a8574c63bb48b5bb99c5aa"
 PV = "1.6.0-git${SRCPV}"
 
-SRC_URI = " \
-    git://github.com/intel-iot-devkit/${BPN}.git;protocol=http \
-"
+SRC_URI = "git://github.com/intel-iot-devkit/${BPN}.git;protocol=http \
+           file://0001-Replace-strncpy-with-memcpy.patch \
+           file://0001-include-sys-types.h-for-uint-definition.patch \
+           "
 
 S = "${WORKDIR}/git"
 
@@ -21,7 +22,6 @@
 
 inherit distutils3-base cmake
 
-
 # override this in local.conf to get needed bindings.
 # BINDINGS_pn-upm="python"
 # will result in only the python bindings being built/packaged.
diff --git a/meta-openembedded/meta-oe/recipes-extended/volume_key/files/0001-explicitly-support-python3-by-pkg-config.patch b/meta-openembedded/meta-oe/recipes-extended/volume_key/files/0001-explicitly-support-python3-by-pkg-config.patch
deleted file mode 100644
index 03edb13..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/volume_key/files/0001-explicitly-support-python3-by-pkg-config.patch
+++ /dev/null
@@ -1,56 +0,0 @@
-From 18415c0b4c6e50ed9b99dfdae8d210590d0ab72e Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Fri, 28 Apr 2017 04:50:30 -0400
-Subject: [PATCH] explicitly support python3 by pkg-config
-
-The PYTHON_CPPFLAGS and -lpython$(PYTHON_VERSION) is hardcoded,
-use pkg-config to replace
-
-Upstream-Status: Inappropriate [wr-installer specific]
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- Makefile.am  | 5 ++---
- configure.ac | 2 ++
- 2 files changed, 4 insertions(+), 3 deletions(-)
-
-diff --git a/Makefile.am b/Makefile.am
-index 4569bbf..7a8daf4 100644
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -20,7 +20,6 @@ ACLOCAL_AMFLAGS = -I m4
- AM_CPPFLAGS = $(blkid_CFLAGS) $(glib_CFLAGS) $(GPGME_CFLAGS) \
- 	$(libcryptsetup_CFLAGS) $(nss_CFLAGS)
- LOCALEDIR_CPPFLAGS = -DLOCALEDIR='"$(localedir)"'
--PYTHON_CPPFLAGS = -I/usr/include/python$(PYTHON_VERSION)
- 
- ## Targets
- SUBDIRS = po
-@@ -63,9 +62,9 @@ lib_libvolume_key_la_LIBADD = $(blkid_LIBS) $(glib_LIBS) $(GPGME_LIBS) \
- 	$(LTLIBINTL) $(libcryptsetup_LIBS) $(nss_LIBS)
- 
- python__volume_key_la_SOURCES = python/volume_key_wrap.c
--python__volume_key_la_CPPFLAGS = $(AM_CPPFLAGS) $(PYTHON_CPPFLAGS)
-+python__volume_key_la_CPPFLAGS = $(AM_CPPFLAGS) $(python3_CFLAGS)
- python__volume_key_la_LDFLAGS = -module -avoid-version $(glib_LIBS)
--python__volume_key_la_LIBADD = lib/libvolume_key.la -lpython$(PYTHON_VERSION) \
-+python__volume_key_la_LIBADD = lib/libvolume_key.la $(python3_LIBS) \
- 	$(glib_LIBS) $(nss_LIBS)
- 
- src_volume_key_SOURCES = src/volume_key.c
-diff --git a/configure.ac b/configure.ac
-index ff35dd0..0928a6c 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -27,6 +27,8 @@ AM_INIT_AUTOMAKE([no-dist-gzip dist-xz no-define subdir-objects -Wall])
- AC_PROG_CC
- AM_PROG_CC_C_O
- LT_INIT([disable-static])
-+
-+PKG_CHECK_MODULES(python3, [python3])
- AM_PATH_PYTHON
- 
- dnl Not gpg2, it cannot receive passphrases from gpgme
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/volume_key/volume-key_0.3.11.bb b/meta-openembedded/meta-oe/recipes-extended/volume_key/volume-key_0.3.11.bb
new file mode 100644
index 0000000..c41b20c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-extended/volume_key/volume-key_0.3.11.bb
@@ -0,0 +1,34 @@
+DESCRIPTION = "The volume_key project provides a libvolume_key, a library for manipulating \
+storage volume encryption keys and storing them separately from volumes, and an \
+associated command-line tool, named volume_key."
+LICENSE = "GPLv2"
+SECTION = "devel/lib"
+
+HOMEPAGE = "https://pagure.io/volume_key"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+SRC_URI = "https://releases.pagure.org/volume_key/volume_key-${PV}.tar.xz \
+"
+SRC_URI[md5sum] = "30df56c7743eb7c965293b3d61194232"
+SRC_URI[sha256sum] = "e6b279c25ae477b555f938db2e41818f90c8cde942b0eec92f70b6c772095f6d"
+
+SRCNAME = "volume_key"
+S = "${WORKDIR}/${SRCNAME}-${PV}"
+
+inherit autotools python3native gettext
+
+DEPENDS += " \
+    util-linux \
+    glib-2.0 \
+    cryptsetup \
+    nss \
+    gpgme \
+    swig-native \
+"
+
+RDEPENDS_python3-${PN} += "${PN}"
+
+PACKAGES += "python3-${PN}"
+FILES_python3-${PN} = "${PYTHON_SITEPACKAGES_DIR}/*"
+
diff --git a/meta-openembedded/meta-oe/recipes-extended/volume_key/volume-key_0.3.9.bb b/meta-openembedded/meta-oe/recipes-extended/volume_key/volume-key_0.3.9.bb
deleted file mode 100644
index febf3f2..0000000
--- a/meta-openembedded/meta-oe/recipes-extended/volume_key/volume-key_0.3.9.bb
+++ /dev/null
@@ -1,34 +0,0 @@
-DESCRIPTION = "The volume_key project provides a libvolume_key, a library for manipulating \
-storage volume encryption keys and storing them separately from volumes, and an \
-associated command-line tool, named volume_key."
-LICENSE = "GPLv2"
-SECTION = "devel/lib"
-
-HOMEPAGE = "https://pagure.io/volume_key"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-
-SRC_URI = "https://releases.pagure.org/volume_key/volume_key-${PV}.tar.xz \
-           file://0001-explicitly-support-python3-by-pkg-config.patch \
-"
-SRC_URI[md5sum] = "a2d14931177c660e1f3ebbcf5f47d8e2"
-SRC_URI[sha256sum] = "450a54fe9bf56acec6850c1e71371d3e4913c9ca1ef0cdc3a517b4b6910412a6"
-
-SRCNAME = "volume_key"
-S = "${WORKDIR}/${SRCNAME}-${PV}"
-
-inherit autotools python3native gettext
-
-DEPENDS += " \
-    util-linux \
-    glib-2.0 \
-    cryptsetup \
-    nss \
-    gpgme \
-"
-
-RDEPENDS_python3-${PN} += "${PN}"
-
-PACKAGES += "python3-${PN}"
-FILES_python3-${PN} = "${PYTHON_SITEPACKAGES_DIR}/*"
-
diff --git a/meta-openembedded/meta-oe/recipes-extended/zlog/zlog_git.bb b/meta-openembedded/meta-oe/recipes-extended/zlog/zlog_git.bb
index 86e6d30..de75164 100644
--- a/meta-openembedded/meta-oe/recipes-extended/zlog/zlog_git.bb
+++ b/meta-openembedded/meta-oe/recipes-extended/zlog/zlog_git.bb
@@ -14,7 +14,7 @@
 
 inherit pkgconfig
 
-EXTRA_OEMAKE = "CC='${CC}' LD='${LD}'"
+EXTRA_OEMAKE = "CC='${CC}' LD='${LD}' LIBRARY_PATH=${baselib}"
 
 do_install() {
     oe_runmake install PREFIX=${D}${exec_prefix} INSTALL=install
diff --git a/meta-openembedded/meta-oe/recipes-gnome/pyxdg/pyxdg_0.26.bb b/meta-openembedded/meta-oe/recipes-gnome/pyxdg/pyxdg_0.26.bb
new file mode 100644
index 0000000..0128a7c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-gnome/pyxdg/pyxdg_0.26.bb
@@ -0,0 +1,12 @@
+DESCRIPTION = "A Python module to deal with freedesktop.org specifications"
+HOMEPAGE = "http://freedesktop.org/wiki/Software/pyxdg"
+SECTION = "devel/python"
+LICENSE = "LGPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=f30a9716ef3762e3467a2f62bf790f0a"
+
+SRCREV = "7db14dcf4c4305c3859a2d9fcf9f5da2db328330"
+SRC_URI = "git://anongit.freedesktop.org/xdg/pyxdg"
+
+inherit distutils
+
+S = "${WORKDIR}/git"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/directfb/directfb.inc b/meta-openembedded/meta-oe/recipes-graphics/directfb/directfb.inc
index bd66a28..96aa311 100644
--- a/meta-openembedded/meta-oe/recipes-graphics/directfb/directfb.inc
+++ b/meta-openembedded/meta-oe/recipes-graphics/directfb/directfb.inc
@@ -20,6 +20,7 @@
            file://union-sigval.patch \
            file://use-PTHREAD_MUTEX_RECURSIVE.patch \
            file://fix-client-gfx_state-initialisation.patch \
+           file://fix-tslib-version-check.patch \
           "
 
 S = "${WORKDIR}/DirectFB-${PV}"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/directfb/directfb/fix-tslib-version-check.patch b/meta-openembedded/meta-oe/recipes-graphics/directfb/directfb/fix-tslib-version-check.patch
new file mode 100644
index 0000000..352bfaf
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/directfb/directfb/fix-tslib-version-check.patch
@@ -0,0 +1,38 @@
+fix tslib version check in configure.in
+
+The patch makes sure that the old as well as the new tslib pkg-config
+metadata file naming style is handled correctly.
+
+tslib 0.0 to 1.0 created only a tslib-<VERSION>.pc pkg-config metadata
+file.
+
+With tslib 1.1 the tslib-<VERSION>.pc phase out was started.
+Additionally, the pkg-config metadata file tslib.pc was added.
+
+Since tslib 1.6 the tslib-<VERSION>.pc metadata file is deprecated.
+Now, there is only a tslib.pc.
+
+Upstream-Status: Inappropriate [no upstream]
+Signed-off-by: Ben Guan <ben.guan@cn.bosch.com>
+Signed-off-by: Mark Jonas <mark.jonas@de.bosch.com>
+
+diff -Nru DirectFB-1.7.7.orig/configure.in DirectFB-1.7.7/configure.in
+--- DirectFB-1.7.7.orig/configure.in	2015-02-10 01:16:46.000000000 +0800
++++ DirectFB-1.7.7/configure.in	2018-06-06 17:19:18.472143103 +0800
+@@ -2459,10 +2459,13 @@
+ 
+ enable_tslib=no
+ if test "$checkfor_tslib" = "yes"; then
+-  PKG_CHECK_MODULES([TSLIB], [tslib-1.0 >= 1.0.0], [enable_tslib=yes], [enable_tslib=no])
++  PKG_CHECK_MODULES([TSLIB], [tslib >= 1.1], [enable_tslib=yes], [enable_tslib=no])
+   if test "$enable_tslib" = "no"; then
+-     PKG_CHECK_MODULES([TSLIB], [tslib-0.0], [enable_tslib=yes], [enable_tslib=no
+-       AC_MSG_WARN([*** no tslib -- tslib driver will not be built.])])
++    PKG_CHECK_MODULES([TSLIB], [tslib-1.0 >= 1.0], [enable_tslib=yes], [enable_tslib=no])
++    if test "$enable_tslib" = "no"; then
++      PKG_CHECK_MODULES([TSLIB], [tslib-0.0], [enable_tslib=yes], [enable_tslib=no
++        AC_MSG_WARN([*** no tslib -- tslib driver will not be built.])])
++    fi
+   fi
+ fi
+ 
diff --git a/meta-openembedded/meta-oe/recipes-graphics/fontforge/fontforge_20170731.bb b/meta-openembedded/meta-oe/recipes-graphics/fontforge/fontforge_20170731.bb
index 481fedf..947d36e 100644
--- a/meta-openembedded/meta-oe/recipes-graphics/fontforge/fontforge_20170731.bb
+++ b/meta-openembedded/meta-oe/recipes-graphics/fontforge/fontforge_20170731.bb
@@ -45,7 +45,9 @@
     cd $currdir
 }
 
-PACKAGES =+ "${PN}-python-dbg ${PN}-python"
+PACKAGES =+ "${PN}-python"
+
+RPROVIDES_${PN}-dbg += "${PN}-python-dbg"
 
 FILES_${PN} += " \
     ${datadir}/mime \
@@ -53,7 +55,6 @@
 "
 
 FILES_${PN}-python = "${PYTHON_SITEPACKAGES_DIR} ${datadir}/${PN}/python"
-FILES_${PN}-python-dbg = "${PYTHON_SITEPACKAGES_DIR}/.debug"
 RDEPENDS_${PN}-python = "python"
 
 # for e.g kde's oxygen-fonts
diff --git a/meta-openembedded/meta-oe/recipes-graphics/glm/glm_0.9.9-a2.bb b/meta-openembedded/meta-oe/recipes-graphics/glm/glm_0.9.9-a2.bb
index 4e2ee23..7f16708 100644
--- a/meta-openembedded/meta-oe/recipes-graphics/glm/glm_0.9.9-a2.bb
+++ b/meta-openembedded/meta-oe/recipes-graphics/glm/glm_0.9.9-a2.bb
@@ -4,9 +4,7 @@
 Shading Language (GLSL) specifications."
 HOMEPAGE = "https://glm.g-truc.net"
 BUGTRACKER = "https://github.com/g-truc/glm/issues"
-
 SECTION = "libs"
-
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://readme.md;beginline=21;endline=22;md5=3075b5727d36f29edccf97b93e72b790"
 
@@ -16,13 +14,13 @@
     file://0002-glm-install-headers-only.patch \
 "
 SRCREV = "fcbedf5058ef8613dd02aac62ef00d55dcfeadd7"
+
 S = "${WORKDIR}/git"
 
 inherit cmake
 
 EXTRA_OECMAKE = "-DGLM_ENABLE_EXPERIMENTAL=ON"
 
-FILES_${PN}-dev += "${libdir}/cmake"
 RDEPENDS_${PN}-dev = ""
 
 BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.16.bb b/meta-openembedded/meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.16.bb
deleted file mode 100644
index 7a691c6..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.16.bb
+++ /dev/null
@@ -1,54 +0,0 @@
-SUMMARY = "libgphoto2 allows you to access digital cameras"
-SECTION = "libs"
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=0448d3676bc0de00406af227d341a4d1"
-
-DEPENDS = "libtool jpeg virtual/libusb0 libexif zlib libxml2"
-
-# The .fdi and .rules files were generated with:
-#  libgphoto2-2.5.8/packaging/generic$ qemu-arm -s 1048576 -r 2.6.24 -L /OE/angstrom-dev/staging/armv5te-angstrom-linux-gnueabi/ .libs/print-camera-list
-# They are release specific, so please regen when adding new releases
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/gphoto/libgphoto2-${PV}.tar.bz2;name=libgphoto2 \
-           file://10-camera-libgphoto2-device.fdi \
-           file://10-camera-libgphoto2.fdi \
-           file://40-libgphoto2.rules \
-           file://0001-configure.ac-remove-AM_PO_SUBDIRS.patch \
-"
-
-SRC_URI[libgphoto2.md5sum] = "084d220d078d28c0c7a3ba13f4476128"
-SRC_URI[libgphoto2.sha256sum] = "e757416d1623e01a9d0d294b2e790162e434c0964f50d3b7ff1a3424b62a2906"
-
-inherit autotools pkgconfig gettext lib_package
-
-EXTRA_OECONF = " --with-drivers=all udevscriptdir=${nonarch_base_libdir}/udev ac_cv_lib_ltdl_lt_dlcaller_register=yes"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[gd] = ",--without-gdlib,gd"
-PACKAGECONFIG[serial] = "--enable-serial,--disable-serial,lockdev"
-
-do_configure_append() {
-    cp ${STAGING_DATADIR_NATIVE}/gettext/po/Makefile.in.in ${S}/libgphoto2_port/po/
-    cd ${S}/libgphoto2_port/
-    autoreconf -Wcross --verbose --install --force ${EXTRA_AUTORECONF} $acpaths
-    cd ${S}
-}
-
-do_install_append() {
-    install -d ${D}${datadir}/hal/fdi/information/20thirdparty
-    install -m 0644 ${WORKDIR}/*.fdi ${D}${datadir}/hal/fdi/information/20thirdparty/
-
-    install -d ${D}${sysconfdir}/udev/rules.d/
-    install -m 0755 ${WORKDIR}/*.rules ${D}${sysconfdir}/udev/rules.d/
-}
-
-PACKAGES =+ "libgphotoport libgphoto2-camlibs"
-FILES_libgphoto2-camlibs = "${libdir}/libgphoto2*/*/*.so*"
-RRECOMMENDS_${PN} = "libgphoto2-camlibs"
-
-FILES_libgphotoport = "${libdir}/libgphoto2_port.so.*"
-
-FILES_${PN} += "${nonarch_base_libdir}/udev/* ${datadir}/hal"
-FILES_${PN}-dbg += "${libdir}/*/*/.debug"
-FILES_${PN}-dev += "${libdir}/*/*/*.la"
-FILES_${PN}-doc += "${datadir}/libgphoto2_port/0.12.0/vcamera/README.txt"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.17.bb b/meta-openembedded/meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.17.bb
new file mode 100644
index 0000000..91c5ed2
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.17.bb
@@ -0,0 +1,54 @@
+SUMMARY = "libgphoto2 allows you to access digital cameras"
+SECTION = "libs"
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=0448d3676bc0de00406af227d341a4d1"
+
+DEPENDS = "libtool jpeg virtual/libusb0 libexif zlib libxml2"
+
+# The .fdi and .rules files were generated with:
+#  libgphoto2-2.5.8/packaging/generic$ qemu-arm -s 1048576 -r 2.6.24 -L /OE/angstrom-dev/staging/armv5te-angstrom-linux-gnueabi/ .libs/print-camera-list
+# They are release specific, so please regen when adding new releases
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/gphoto/libgphoto2-${PV}.tar.bz2;name=libgphoto2 \
+           file://10-camera-libgphoto2-device.fdi \
+           file://10-camera-libgphoto2.fdi \
+           file://40-libgphoto2.rules \
+           file://0001-configure.ac-remove-AM_PO_SUBDIRS.patch \
+"
+
+SRC_URI[libgphoto2.md5sum] = "ae78e7a7936a6962c3a22b256bee1869"
+SRC_URI[libgphoto2.sha256sum] = "417464f0a313fa937e8a71cdf18a371cf01e750830195cd63ae31da0d092b555"
+
+inherit autotools pkgconfig gettext lib_package
+
+EXTRA_OECONF = " --with-drivers=all udevscriptdir=${nonarch_base_libdir}/udev ac_cv_lib_ltdl_lt_dlcaller_register=yes"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[gd] = ",--without-gdlib,gd"
+PACKAGECONFIG[serial] = "--enable-serial,--disable-serial,lockdev"
+
+do_configure_append() {
+    cp ${STAGING_DATADIR_NATIVE}/gettext/po/Makefile.in.in ${S}/libgphoto2_port/po/
+    cd ${S}/libgphoto2_port/
+    autoreconf -Wcross --verbose --install --force ${EXTRA_AUTORECONF} $acpaths
+    cd ${S}
+}
+
+do_install_append() {
+    install -d ${D}${datadir}/hal/fdi/information/20thirdparty
+    install -m 0644 ${WORKDIR}/*.fdi ${D}${datadir}/hal/fdi/information/20thirdparty/
+
+    install -d ${D}${sysconfdir}/udev/rules.d/
+    install -m 0755 ${WORKDIR}/*.rules ${D}${sysconfdir}/udev/rules.d/
+}
+
+PACKAGES =+ "libgphotoport libgphoto2-camlibs"
+FILES_libgphoto2-camlibs = "${libdir}/libgphoto2*/*/*.so*"
+RRECOMMENDS_${PN} = "libgphoto2-camlibs"
+
+FILES_libgphotoport = "${libdir}/libgphoto2_port.so.*"
+
+FILES_${PN} += "${nonarch_base_libdir}/udev/* ${datadir}/hal"
+FILES_${PN}-dbg += "${libdir}/*/*/.debug"
+FILES_${PN}-dev += "${libdir}/*/*/*.la"
+FILES_${PN}-doc += "${datadir}/libgphoto2_port/0.12.0/vcamera/README.txt"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-gfx_2.0.25.bb b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-gfx_2.0.25.bb
new file mode 100644
index 0000000..b077a0b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-gfx_2.0.25.bb
@@ -0,0 +1,19 @@
+SUMMARY = "SDL graphics drawing primitives and other support functions"
+SECTION = "libs"
+LICENSE = "Zlib"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=5d1de21f0b70830e299905eac3419084"
+
+DEPENDS = "virtual/libsdl"
+
+SRC_URI = "http://www.ferzkopp.net/Software/SDL_gfx-2.0/SDL_gfx-${PV}.tar.gz"
+SRC_URI[md5sum] = "ea24ed4b82ff1304809c363494fa8e16"
+SRC_URI[sha256sum] = "556eedc06b6cf29eb495b6d27f2dcc51bf909ad82389ba2fa7bdc4dec89059c0"
+
+S = "${WORKDIR}/SDL_gfx-${PV}"
+
+inherit autotools pkgconfig
+
+EXTRA_OECONF += " \
+    --disable-mmx \
+"
+
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/libsdl-image/libsdl-image/configure.patch b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-image/configure.patch
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-multimedia/libsdl-image/libsdl-image/configure.patch
rename to meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-image/configure.patch
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/libsdl-image/libsdl-image_1.2.12.bb b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-image_1.2.12.bb
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-multimedia/libsdl-image/libsdl-image_1.2.12.bb
rename to meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-image_1.2.12.bb
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/libsdl-mixer/libsdl-mixer/configure.patch b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-mixer/configure.patch
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-multimedia/libsdl-mixer/libsdl-mixer/configure.patch
rename to meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-mixer/configure.patch
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/libsdl-mixer/libsdl-mixer_1.2.12.bb b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-mixer_1.2.12.bb
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-multimedia/libsdl-mixer/libsdl-mixer_1.2.12.bb
rename to meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-mixer_1.2.12.bb
diff --git a/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-net/am_foreign.patch b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-net/am_foreign.patch
new file mode 100644
index 0000000..fb3ff7e
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-net/am_foreign.patch
@@ -0,0 +1,11 @@
+diff -Nurd SDL_net-1.2.8/Makefile.am SDL_net-1.2.8/Makefile.am
+--- SDL_net-1.2.8/Makefile.am	2012-01-15 18:20:10.000000000 +0200
++++ SDL_net-1.2.8/Makefile.am	2014-08-01 21:18:52.720815807 +0300
+@@ -1,5 +1,7 @@
+ # Makefile.am for the SDL sample image loading library and viewer
+ 
++AUTOMAKE_OPTIONS = foreign
++
+ lib_LTLIBRARIES = libSDL_net.la
+ 
+ libSDL_netincludedir = $(includedir)/SDL
diff --git a/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-net/libtool2.patch b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-net/libtool2.patch
new file mode 100644
index 0000000..9718a3b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-net/libtool2.patch
@@ -0,0 +1,21 @@
+From f9417c864183a0f6d0e90f66f5254a63b04a041a Mon Sep 17 00:00:00 2001
+From: Denis 'GNUtoo' Carikli <GNUtoo@no-log.org>
+Date: Wed, 17 Oct 2012 20:51:51 +0200
+
+---
+ configure.in | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/configure.in b/configure.in
+index c42bd0c..71a4825 100644
+--- a/configure.in
++++ b/configure.in
+@@ -44,6 +44,8 @@ AC_CANONICAL_HOST
+ dnl Setup for automake
+ AM_INIT_AUTOMAKE(SDL_net, $VERSION)
+ 
++dnl got macros
++AC_CONFIG_MACRO_DIR([acinclude])
+ dnl Check for tools
+ AC_PROG_LIBTOOL
+ AC_PROG_CC
diff --git a/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-net_1.2.8.bb b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-net_1.2.8.bb
new file mode 100644
index 0000000..b021e56
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-net_1.2.8.bb
@@ -0,0 +1,20 @@
+DESCRIPTION = "Simple DirectMedia Layer networking library."
+SECTION = "libs/network"
+
+LICENSE = "Zlib"
+LIC_FILES_CHKSUM = "file://COPYING;md5=9cf3de2d872bf510f88eb20d06d700b5"
+
+inherit autotools pkgconfig
+
+DEPENDS = "virtual/libsdl"
+
+SRC_URI = " \
+  https://www.libsdl.org/projects/SDL_net/release/SDL_net-${PV}.tar.gz \
+  file://libtool2.patch \
+  file://am_foreign.patch \
+"
+
+S = "${WORKDIR}/SDL_net-${PV}"
+
+SRC_URI[md5sum] = "20e64e61d65662db66c379034f11f718"
+SRC_URI[sha256sum] = "5f4a7a8bb884f793c278ac3f3713be41980c5eedccecff0260411347714facb4"
diff --git a/meta-openembedded/meta-oe/recipes-support/libsdl-ttf/libsdl-ttf/use.pkg-config.for.freetype2.patch b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-ttf/use.pkg-config.for.freetype2.patch
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-support/libsdl-ttf/libsdl-ttf/use.pkg-config.for.freetype2.patch
rename to meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-ttf/use.pkg-config.for.freetype2.patch
diff --git a/meta-openembedded/meta-oe/recipes-support/libsdl-ttf/libsdl-ttf_2.0.11.bb b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-ttf_2.0.11.bb
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-support/libsdl-ttf/libsdl-ttf_2.0.11.bb
rename to meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl-ttf_2.0.11.bb
diff --git a/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl2-image_2.0.3.bb b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl2-image_2.0.3.bb
new file mode 100644
index 0000000..6deb352
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl2-image_2.0.3.bb
@@ -0,0 +1,31 @@
+SUMMARY = "Simple DirectMedia Layer image library v2"
+SECTION = "libs"
+
+LICENSE = "Zlib"
+LIC_FILES_CHKSUM = "file://COPYING.txt;md5=a855a9eb5507fc556e672080c4b428ca"
+
+DEPENDS = "tiff zlib libpng jpeg virtual/libsdl2 libwebp"
+
+SRC_URI = "http://www.libsdl.org/projects/SDL_image/release/SDL2_image-${PV}.tar.gz"
+SRC_URI[md5sum] = "c6baf6dfa80fa8a66853661a36a6034e"
+SRC_URI[sha256sum] = "3510c25da735ffcd8ce3b65073150ff4f7f9493b866e85b83738083b556d2368"
+
+S = "${WORKDIR}/SDL2_image-${PV}"
+
+inherit autotools pkgconfig
+
+# Disable the run-time loading of the libs and bring back the soname dependencies.
+EXTRA_OECONF += "--disable-jpg-shared --disable-png-shared -disable-tif-shared"
+
+do_configure_prepend() {
+    # make autoreconf happy
+    touch ${S}/NEWS ${S}/README ${S}/AUTHORS ${S}/ChangeLog
+    # Removing these files fixes a libtool version mismatch.
+    rm -f ${S}/acinclude/libtool.m4
+    rm -f ${S}/acinclude/sdl2.m4
+    rm -f ${S}/acinclude/pkg.m4
+    rm -f ${S}/acinclude/lt~obsolete.m4
+    rm -f ${S}/acinclude/ltoptions.m4
+    rm -f ${S}/acinclude/ltsugar.m4
+    rm -f ${S}/acinclude/ltversion.m4
+}
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/libsdl-mixer/libsdl2-mixer_2.0.2.bb b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl2-mixer_2.0.2.bb
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-multimedia/libsdl-mixer/libsdl2-mixer_2.0.2.bb
rename to meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl2-mixer_2.0.2.bb
diff --git a/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl2-net_2.0.1.bb b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl2-net_2.0.1.bb
new file mode 100644
index 0000000..0ea96fe
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl2-net_2.0.1.bb
@@ -0,0 +1,27 @@
+DESCRIPTION = "Simple DirectMedia Layer networking library."
+SECTION = "libs/network"
+LICENSE = "Zlib"
+LIC_FILES_CHKSUM = "file://COPYING.txt;md5=fe9d52a78585a65224776875510ed127"
+
+SRC_URI = " \
+  https://www.libsdl.org/projects/SDL_net/release/SDL2_net-${PV}.tar.gz \
+"
+S = "${WORKDIR}/SDL2_net-${PV}"
+
+inherit autotools pkgconfig
+
+DEPENDS = "virtual/libsdl2"
+
+SRC_URI[md5sum] = "5c1d9d1cfa63301b141cb5c0de2ea7c4"
+SRC_URI[sha256sum] = "15ce8a7e5a23dafe8177c8df6e6c79b6749a03fff1e8196742d3571657609d21"
+
+do_configure_prepend() {
+    # create dummy files which autotools consider as mandatory
+    touch ${S}/NEWS ${S}/README ${S}/AUTHORS ${S}/ChangeLog  
+
+    # Remove old libtool macros.
+    for macro in libtool.m4 lt~obsolete.m4 ltoptions.m4 ltsugar.m4 ltversion.m4; do
+        echo ${S}/acinclude/macro
+        rm -f ${S}/acinclude/$macro
+    done
+}
diff --git a/meta-openembedded/meta-oe/recipes-support/libsdl-ttf/libsdl2-ttf/automake_foreign.patch b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl2-ttf/automake_foreign.patch
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-support/libsdl-ttf/libsdl2-ttf/automake_foreign.patch
rename to meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl2-ttf/automake_foreign.patch
diff --git a/meta-openembedded/meta-oe/recipes-support/libsdl-ttf/libsdl2-ttf/use.pkg-config.for.freetype2.patch b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl2-ttf/use.pkg-config.for.freetype2.patch
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-support/libsdl-ttf/libsdl2-ttf/use.pkg-config.for.freetype2.patch
rename to meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl2-ttf/use.pkg-config.for.freetype2.patch
diff --git a/meta-openembedded/meta-oe/recipes-support/libsdl-ttf/libsdl2-ttf_2.0.14.bb b/meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl2-ttf_2.0.14.bb
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-support/libsdl-ttf/libsdl2-ttf_2.0.14.bb
rename to meta-openembedded/meta-oe/recipes-graphics/libsdl/libsdl2-ttf_2.0.14.bb
diff --git a/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses/0001-Use-override-consistently.patch b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses/0001-Use-override-consistently.patch
new file mode 100644
index 0000000..6d4bdc2
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses/0001-Use-override-consistently.patch
@@ -0,0 +1,147 @@
+From 0acfb67f99fd8d6af323311fee8c08116295b148 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 5 Sep 2018 18:21:19 -0700
+Subject: [PATCH 1/2] Use override consistently
+
+Make clang++ happy
+error: 'setApplicationTitle' overrides a member function but is not marked 'override' [-Werror,-Winconsistent-missing-over ride]
+
+Upstream-Status: Submitted [https://github.com/libyui/libyui-ncurses/pull/69]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/NCApplication.h | 46 ++++++++++++++++++++++-----------------------
+ 1 file changed, 23 insertions(+), 23 deletions(-)
+
+diff --git a/src/NCApplication.h b/src/NCApplication.h
+index e24c3eb..09e4708 100644
+--- a/src/NCApplication.h
++++ b/src/NCApplication.h
+@@ -60,7 +60,7 @@ public:
+      * Reimplemented from YApplication.
+      **/
+     virtual void setLanguage( const std::string & language,
+-			      const std::string & encoding = std::string() );
++			      const std::string & encoding = std::string() ) override;
+ 
+     /**
+      * Open a directory selection box and prompt the user for an existing
+@@ -77,7 +77,7 @@ public:
+      * Implemented from YApplication.
+      **/
+     virtual std::string askForExistingDirectory( const std::string & startDir,
+-					    const std::string & headline );
++					    const std::string & headline ) override;
+ 
+     /**
+      * Open a file selection box and prompt the user for an existing file.
+@@ -97,7 +97,7 @@ public:
+      **/
+     virtual std::string askForExistingFile( const std::string & startWith,
+ 				       const std::string & filter,
+-				       const std::string & headline );
++				       const std::string & headline ) override;
+ 
+     /**
+      * Open a file selection box and prompt the user for a file to save data
+@@ -119,28 +119,28 @@ public:
+      **/
+     virtual std::string askForSaveFileName( const std::string & startWith,
+ 				       const std::string & filter,
+-				       const std::string & headline );
++				       const std::string & headline ) override;
+ 
+     /**
+      * Beep.
+      *
+      * Reimplemented from YApplication.
+      **/
+-    virtual void beep();
++    virtual void beep() override;
+ 
+     /**
+      * Redraw the screen.
+      *
+      * Reimplemented from YApplication.
+      **/
+-    virtual void redrawScreen();
++    virtual void redrawScreen() override;
+ 
+     /**
+      * Initialize the (text) console keyboard.
+      *
+      * Reimplemented from YApplication.
+      **/
+-    virtual void initConsoleKeyboard();
++    virtual void initConsoleKeyboard() override;
+ 
+     /**
+      * Set the (text) console font according to the current encoding etc.
+@@ -152,7 +152,7 @@ public:
+ 				 const std::string & font,
+ 				 const std::string & screen_map,
+ 				 const std::string & unicode_map,
+-				 const std::string & language );
++				 const std::string & language ) override;
+ 
+     /**
+      * Run a shell command (typically an interactive program using NCurses)
+@@ -165,7 +165,7 @@ public:
+      *
+      * Reimplemented from YApplication.
+      **/
+-    virtual int runInTerminal( const std::string & command );
++    virtual int runInTerminal( const std::string & command ) override;
+ 
+ 
+     /// @{
+@@ -183,33 +183,33 @@ public:
+     //
+     // All implemented from YApplication.
+ 
+-    virtual int	 displayWidth();
+-    virtual int	 displayHeight();
+-    virtual int	 displayDepth();
+-    virtual long displayColors();
++    virtual int	 displayWidth() override;
++    virtual int	 displayHeight() override;
++    virtual int	 displayDepth() override;
++    virtual long displayColors() override;
+ 
+-    virtual int	 defaultWidth();
+-    virtual int	 defaultHeight();
++    virtual int	 defaultWidth() override;
++    virtual int	 defaultHeight() override;
+ 
+-    virtual bool isTextMode()			{ return true; }
++    virtual bool isTextMode() override			{ return true; }
+ 
+-    virtual bool hasImageSupport()		{ return false; }
++    virtual bool hasImageSupport() override 		{ return false; }
+ 
+-    virtual bool hasIconSupport()		{ return false; }
++    virtual bool hasIconSupport() override		{ return false; }
+ 
+-    virtual bool hasAnimationSupport()		{ return false; }
++    virtual bool hasAnimationSupport()	override	{ return false; }
+ 
+-    virtual bool hasFullUtf8Support();
+-    virtual bool richTextSupportsTable()	{ return false; }
++    virtual bool hasFullUtf8Support() override;
++    virtual bool richTextSupportsTable() override	{ return false; }
+ 
+-    virtual bool leftHandedMouse()		{ return false; }
++    virtual bool leftHandedMouse() override		{ return false; }
+     
+     /**
+      * Set the application title
+      *
+      * Reimplemented from YApplication.
+      **/
+-    virtual void setApplicationTitle(const std::string& title);
++    virtual void setApplicationTitle(const std::string& title) override;
+ };
+ 
+ 
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses/0001-use-_nl_msg_cat_cntr-only-with-glibc.patch b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses/0001-use-_nl_msg_cat_cntr-only-with-glibc.patch
deleted file mode 100644
index 8e3774c..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses/0001-use-_nl_msg_cat_cntr-only-with-glibc.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From 4b84f243a70a8c07f6a38dad3c9411fa707f25c9 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 4 Mar 2018 17:08:43 -0800
-Subject: [PATCH] use _nl_msg_cat_cntr only with glibc
-
-The musl libc provides libintl (similar to glibc)
-but does not use the same internals,
-so even though we are using the GNU gettext
-the libintl included with the libc does not define
-_nl_msg_cat_cntr and it does not need to.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Pending
-
- src/NCi18n.h | 3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
-diff --git a/src/NCi18n.h b/src/NCi18n.h
-index 165b0e7..bfc4ed7 100644
---- a/src/NCi18n.h
-+++ b/src/NCi18n.h
-@@ -59,12 +59,13 @@ inline void setTextdomain( const char * domain )
-     bindtextdomain( domain,  YSettings::localeDir().c_str() );
-     bind_textdomain_codeset( domain, "UTF-8" );
-     textdomain( domain );
--
-+#if defined(__GLIBC__)
-     // Make change known
-     {
- 	extern int _nl_msg_cat_cntr;
- 	++_nl_msg_cat_cntr;
-     }
-+#endif
- }
- 
- 
--- 
-2.16.2
-
diff --git a/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses/0002-Define-own-resize-in-NCPad-and-fix-param-type-of-Set.patch b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses/0002-Define-own-resize-in-NCPad-and-fix-param-type-of-Set.patch
new file mode 100644
index 0000000..f65cbe6
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses/0002-Define-own-resize-in-NCPad-and-fix-param-type-of-Set.patch
@@ -0,0 +1,49 @@
+From 162a0899f1dacd83007c4e82b9034f55610d8c20 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 5 Sep 2018 19:01:51 -0700
+Subject: [PATCH 2/2] Define own resize in NCPad and fix param type of
+ SetLabel()
+
+Explicitly override resize() to avoid conflicts from NCursesWindow
+definition since there is another resize definition as well
+
+Fixes
+src/NCPad.h:164:18: error: 'NCPad::resize' hides overloaded virtual function [-Werror,-Woverloaded-virtual]
+
+NCTablePad.h:132:18: error: 'NCTableTag::SetLabel' hides overloaded virtual function [-Werror,-Woverloaded-virtual]
+
+Upstream-Status: Submitted [https://github.com/libyui/libyui-ncurses/pull/69]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/NCPad.h      | 1 +
+ src/NCTablePad.h | 2 +-
+ 2 files changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/src/NCPad.h b/src/NCPad.h
+index 328c4aa..d8fb324 100644
+--- a/src/NCPad.h
++++ b/src/NCPad.h
+@@ -162,6 +162,7 @@ public:
+     virtual void Destwin( NCursesWindow * dwin );
+ 
+     virtual void resize( wsze nsze );
++    virtual int resize( int lines, int columns ) { return NCursesWindow::resize(lines, columns );}
+     virtual void wRecoded();
+     virtual void setDirty() { dirty = true; }
+ 
+diff --git a/src/NCTablePad.h b/src/NCTablePad.h
+index c450529..3756796 100644
+--- a/src/NCTablePad.h
++++ b/src/NCTablePad.h
+@@ -129,7 +129,7 @@ public:
+ 
+     virtual ~NCTableTag() {}
+ 
+-    virtual void SetLabel( const NCstring & ) { /*NOOP*/; }
++    virtual void SetLabel( const NClabel & ) { /*NOOP*/; }
+ 
+     virtual void DrawAt( NCursesWindow & w, const wrect at,
+ 			 NCTableStyle & tableStyle,
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses/0003-Simplify-ncurses-finding-module.patch b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses/0003-Simplify-ncurses-finding-module.patch
new file mode 100644
index 0000000..2520ac4
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses/0003-Simplify-ncurses-finding-module.patch
@@ -0,0 +1,35 @@
+From c2291fe28dc5682f81804941512431642975cf21 Mon Sep 17 00:00:00 2001
+From: Pascal Bach <pascal.bach@siemens.com>
+Date: Mon, 29 Oct 2018 18:17:32 +0100
+Subject: [PATCH] Simplify ncurses finding module
+
+CMake will automatically look in the right locations, there is no need to
+re-implement the logic with a for loop and NO_DEFAULT_PATH.
+
+It is already done like this to file the headers.
+
+Upstream-Status: Submitted [https://github.com/libyui/libyui-ncurses/pull/73]
+Signed-off-by: Pascal Bach <pascal.bach@siemens.com>
+---
+ cmake/Modules/FindCurses6.cmake | 8 +++-----
+ 1 file changed, 3 insertions(+), 5 deletions(-)
+
+diff --git a/cmake/Modules/FindCurses6.cmake b/cmake/Modules/FindCurses6.cmake
+index 0bf02c3..e298d5d 100644
+--- a/cmake/Modules/FindCurses6.cmake
++++ b/cmake/Modules/FindCurses6.cmake
+@@ -5,11 +5,9 @@
+ #  CURSES6_LIBRARIES - The libraries needed to use Curses6
+ #  CURSES6_DEFINITIONS - Compiler switches required for using Curses6
+ 
+-FOREACH(path ${CMAKE_LIBRARY_PATH} /usr/${LIB_DIR})
+-  FIND_LIBRARY(CURSES6_NCURSESW_LIBRARY NAMES ncursesw PATHS ${path}/ncurses6 ${path} NO_DEFAULT_PATH)
+-  FIND_LIBRARY(CURSES6_PANELW_LIBRARY NAMES panelw PATHS ${path}/ncurses6 ${path} NO_DEFAULT_PATH)
+-  FIND_LIBRARY(CURSES6_TINFO_LIBRARY NAMES tinfo PATHS ${path}/ncurses6 ${path} NO_DEFAULT_PATH)
+-ENDFOREACH()
++FIND_LIBRARY(CURSES6_NCURSESW_LIBRARY NAMES ncursesw PATH_SUFFIXES ncurses6)
++FIND_LIBRARY(CURSES6_PANELW_LIBRARY NAMES panelw PATH_SUFFIXES ncurses6)
++FIND_LIBRARY(CURSES6_TINFO_LIBRARY NAMES tinfo PATH_SUFFIXES ncurses6)
+ 
+ SET(CURSES6_LIBRARIES ${CURSES6_NCURSESW_LIBRARY} ${CURSES6_PANELW_LIBRARY})
+ # tinfo is optional (in 12.1 is not there)
diff --git a/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses_git.bb b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses_git.bb
index 578c713..18ea2e8 100644
--- a/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses_git.bb
+++ b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui-ncurses_git.bb
@@ -5,13 +5,15 @@
 "
 
 SRC_URI = "git://github.com/libyui/libyui-ncurses.git \
-           file://0001-use-_nl_msg_cat_cntr-only-with-glibc.patch \
+           file://0001-Use-override-consistently.patch \
+           file://0002-Define-own-resize-in-NCPad-and-fix-param-type-of-Set.patch \
+           file://0003-Simplify-ncurses-finding-module.patch \
           "
 
 SRC_URI_append_class-target = " file://0001-Fix-the-error-of-can-t-find-header-file.patch"
 
 PV = "2.48.3+git${SRCPV}"
-SRCREV = "79b804b45ffc6a0d92e28e793ff389a20b63b54b"
+SRCREV = "c941b32246e8b2952fce4fd5743f8e318222ab98"
 
 S = "${WORKDIR}/git"
 
@@ -29,8 +31,8 @@
     mkdir -p ${PKG_CONFIG_SYSROOT_DIR}${base_prefix}/usr/lib64/
     cp ${PKG_CONFIG_SYSROOT_DIR}${base_prefix}/usr/lib/libyui.so* ${PKG_CONFIG_SYSROOT_DIR}${base_prefix}/usr/lib64/
     cd -
-    sed -i "s#\${YPREFIX}#\${PKG_CONFIG_SYSROOT_DIR}${base_prefix}&#" ${S}/CMakeLists.txt
-    sed -i "s#/usr#${PKG_CONFIG_SYSROOT_DIR}${base_prefix}&#" ${PKG_CONFIG_SYSROOT_DIR}${libdir}/cmake/libyui/LibyuiLibraryDepends-release.cmake
+    sed -i -e "s#\${YPREFIX}#\${PKG_CONFIG_SYSROOT_DIR}${base_prefix}&#" ${S}/CMakeLists.txt
+    sed -i -e "s#/usr#${PKG_CONFIG_SYSROOT_DIR}${base_prefix}&#" ${PKG_CONFIG_SYSROOT_DIR}${libdir}/cmake/libyui/LibyuiLibraryDepends-release.cmake
 }
 
 do_install_append () {
diff --git a/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui/0001-Fix-GCC-8-warning.patch b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui/0001-Fix-GCC-8-warning.patch
deleted file mode 100644
index c1ba42e..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui/0001-Fix-GCC-8-warning.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-From 1e6d40fec16a94d1a4bd40634405267200b7e969 Mon Sep 17 00:00:00 2001
-From: marxin <mliska@suse.cz>
-Date: Tue, 10 Apr 2018 15:21:40 +0200
-Subject: [PATCH] Fix GCC 8 warning:
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-/home/marxin/Programming/libyui/src/YDialog.cc: In static member function ‘static void YDialog::showText(const string&, bool)’:
-/home/marxin/Programming/libyui/src/YDialog.cc:690:26: error: catching polymorphic type ‘class YUIException’ by value [-Werror=catch-value=]
-     catch ( YUIException exception )
-                          ^~~~~~~~~
-/home/marxin/Programming/libyui/src/YDialog.cc: In static member function ‘static bool YDialog::showRelNotesText()’:
-/home/marxin/Programming/libyui/src/YDialog.cc:814:26: error: catching polymorphic type ‘class YUIException’ by value [-Werror=catch-value=]
-     catch ( YUIException exception )
-                          ^~~~~~~~~
----
-Upstream-Status: Submitted [https://github.com/libyui/libyui/pull/122]
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
- src/YDialog.cc | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/YDialog.cc b/src/YDialog.cc
-index 92e5031..8ecff90 100644
---- a/src/YDialog.cc
-+++ b/src/YDialog.cc
-@@ -687,7 +687,7 @@ YDialog::showText( const std::string & text, bool useRichText )
- 	dialog->waitForEvent();
- 	dialog->destroy();
-     }
--    catch ( YUIException exception )
-+    catch ( YUIException &exception )
-     {
- 	// Don't let the application die just because help couldn't be displayed.
- 
-@@ -811,7 +811,7 @@ YDialog::showRelNotesText()
- 	}
-         dialog->destroy();
-     }
--    catch ( YUIException exception )
-+    catch ( YUIException &exception )
-     {
-         // Don't let the application die just because RN couldn't be displayed.
- 
--- 
-2.17.0
-
diff --git a/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui/0001-Use-curly-braces-for-MAKE-variable.patch b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui/0001-Use-curly-braces-for-MAKE-variable.patch
new file mode 100644
index 0000000..dbe2417
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui/0001-Use-curly-braces-for-MAKE-variable.patch
@@ -0,0 +1,32 @@
+From 4eed37b1a61458fc8e5251f7cb7c6d64e8e9da8d Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 5 Sep 2018 17:48:09 -0700
+Subject: [PATCH] Use curly braces for MAKE variable
+
+Fixes errors with ninja
+| ninja: error: build.ninja:142: bad $-escape (literal $ must be written as $$)
+
+Upstream-Status: Submitted [https://github.com/libyui/libyui/pull/137]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ buildtools/LibyuiCommon.cmake | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/buildtools/LibyuiCommon.cmake b/buildtools/LibyuiCommon.cmake
+index cb93307..e6fbefd 100644
+--- a/buildtools/LibyuiCommon.cmake
++++ b/buildtools/LibyuiCommon.cmake
+@@ -122,8 +122,8 @@ MACRO( SET_BUILD_FLAGS )	# setup compiler-flags depending on CMAKE_BUILD_TYPE
+     ENABLE_TESTING()
+     # add a wrapper "tests" target, the builtin "test" cannot be extended :-(
+     ADD_CUSTOM_TARGET(tests
+-      $(MAKE)
+-      COMMAND $(MAKE) test
++      ${MAKE}
++      COMMAND ${MAKE} test
+     )
+   ENDIF ( ENABLE_TESTS OR ENABLE_CODE_COVERAGE)
+ 
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui/0001-Use-relative-install-paths-for-CMake.patch b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui/0001-Use-relative-install-paths-for-CMake.patch
new file mode 100644
index 0000000..11a1678
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui/0001-Use-relative-install-paths-for-CMake.patch
@@ -0,0 +1,130 @@
+From d24c2516ae25d0ee180c1020e52114ea32230585 Mon Sep 17 00:00:00 2001
+From: Pascal Bach <pascal.bach@siemens.com>
+Date: Mon, 29 Oct 2018 18:03:43 +0100
+Subject: [PATCH] Use relative install paths for CMake
+
+Files are installed via a special _PREFIX variant of the INSTALL_???_DIR
+variable which is an absolute path.
+
+This not only is redundant if CMAKE_INTALL_PREFIX is set but it even causes
+the resulting Config.cmake to be non relocatable. This means it contains absolute
+paths to the build host. This is a problem for cross compilation in Yocto.
+
+This change gets rid of the absolute path and removes the no longer needed
+_PREFIX variants.
+
+Upstream-Status: Submitted [https://github.com/libyui/libyui/pull/140]
+Signed-off-by: Pascal Bach <pascal.bach@siemens.com>
+---
+ buildtools/LibyuiCommon.cmake | 35 ++++++++++++++---------------------
+ 1 file changed, 14 insertions(+), 21 deletions(-)
+
+diff --git a/buildtools/LibyuiCommon.cmake b/buildtools/LibyuiCommon.cmake
+index e6fbefd..5e2fc0d 100644
+--- a/buildtools/LibyuiCommon.cmake
++++ b/buildtools/LibyuiCommon.cmake
+@@ -258,13 +258,6 @@ MACRO( SET_ENVIRONMENT )	# setup the environment vars
+ 
+   SET( INSTALL_DOC_DIR "${DOC_DIR}" )
+ 
+-  FOREACH( p "DOC" LIB INCLUDE CMAKE PKGCONFIG BUILDTOOLS )
+-    SET( var "INSTALL_${p}_DIR" )
+-    IF( NOT IS_ABSOLUTE "${${var}}" )
+-      SET( ${var}_PREFIX "${YPREFIX}/${${var}}" )
+-    ENDIF( NOT IS_ABSOLUTE "${${var}}" )
+-  ENDFOREACH()
+-
+ ENDMACRO( SET_ENVIRONMENT )
+ 
+ MACRO( SET_SONAME )
+@@ -359,7 +352,7 @@ MACRO( SET_AUTODOCS )		# looks for doxygen, dot and latex and setup autodocs acc
+       IF( INSTALL_DOCS OR DOCS_ONLY )
+         INSTALL(
+           FILES "${CMAKE_BINARY_DIR}/doc/latex/refman.pdf"
+-          DESTINATION "${INSTALL_DOC_DIR_PREFIX}"
++          DESTINATION "${INSTALL_DOC_DIR}"
+         )
+       ENDIF( INSTALL_DOCS OR DOCS_ONLY )
+ 
+@@ -379,7 +372,7 @@ MACRO( SET_AUTODOCS )		# looks for doxygen, dot and latex and setup autodocs acc
+       FOREACH( p css gif html jpg js png tag )
+         INSTALL(
+           DIRECTORY "${CMAKE_BINARY_DIR}/doc/html"
+-          DESTINATION "${INSTALL_DOC_DIR_PREFIX}"
++          DESTINATION "${INSTALL_DOC_DIR}"
+           FILES_MATCHING PATTERN "*.${p}"
+         )
+       ENDFOREACH()
+@@ -638,32 +631,32 @@ MACRO( SET_INSTALL_TARGET )
+ 
+ INSTALL(
+   EXPORT ${PROJECTNAME_UC}LibraryDepends
+-  DESTINATION "${INSTALL_CMAKE_DIR_PREFIX}"
++  DESTINATION "${INSTALL_CMAKE_DIR}"
+   COMPONENT dev
+ )
+ 
+ FOREACH( p Config.cmake ConfigVersion.cmake )
+   INSTALL(
+     FILES "${CMAKE_BINARY_DIR}/${PROJECTNAME_UC}${p}"
+-    DESTINATION "${INSTALL_CMAKE_DIR_PREFIX}"
++    DESTINATION "${INSTALL_CMAKE_DIR}"
+ )
+ ENDFOREACH( p Config.cmake ConfigVersion.cmake )
+ 
+ INSTALL(
+   FILES "${CMAKE_BINARY_DIR}/${PROJECTNAME}.pc"
+-  DESTINATION "${INSTALL_PKGCONFIG_DIR_PREFIX}"
++  DESTINATION "${INSTALL_PKGCONFIG_DIR}"
+ )
+ 
+ IF( NOT PLUGINNAME AND NOT EXTENSIONNAME )
+   INSTALL(
+     DIRECTORY "${BUILDTOOLS_DIR}"
+-    DESTINATION "${INSTALL_BUILDTOOLS_DIR_PREFIX}"
++    DESTINATION "${INSTALL_BUILDTOOLS_DIR}"
+   )
+ ENDIF( NOT PLUGINNAME AND NOT EXTENSIONNAME )
+ 
+ INSTALL(
+   FILES ${BUILDTOOLS_LIST}
+-  DESTINATION "${INSTALL_BUILDTOOLS_DIR_PREFIX}"
++  DESTINATION "${INSTALL_BUILDTOOLS_DIR}"
+ )
+ 
+ ENDMACRO( SET_INSTALL_TARGET )
+@@ -724,9 +717,9 @@ MACRO( PROCESS_SOURCES )
+   INSTALL(
+     TARGETS ${TARGETLIB}
+     EXPORT ${PROJECTNAME_UC}LibraryDepends
+-    LIBRARY DESTINATION "${INSTALL_LIB_DIR_PREFIX}"
+-    ARCHIVE DESTINATION "${INSTALL_LIB_DIR_PREFIX}"
+-    PUBLIC_HEADER DESTINATION "${INSTALL_INCLUDE_DIR_PREFIX}"
++    LIBRARY DESTINATION "${INSTALL_LIB_DIR}"
++    ARCHIVE DESTINATION "${INSTALL_LIB_DIR}"
++    PUBLIC_HEADER DESTINATION "${INSTALL_INCLUDE_DIR}"
+     COMPONENT dev
+   )
+ 
+@@ -746,9 +739,9 @@ MACRO( PROCESS_SOURCES )
+     INSTALL(
+       TARGETS ${TARGETLIB}_static
+       EXPORT ${PROJECTNAME_UC}LibraryDepends
+-      LIBRARY DESTINATION "${INSTALL_LIB_DIR_PREFIX}"
+-      ARCHIVE DESTINATION "${INSTALL_LIB_DIR_PREFIX}"
+-      PUBLIC_HEADER DESTINATION "${INSTALL_INCLUDE_DIR_PREFIX}"
++      LIBRARY DESTINATION "${INSTALL_LIB_DIR}"
++      ARCHIVE DESTINATION "${INSTALL_LIB_DIR}"
++      PUBLIC_HEADER DESTINATION "${INSTALL_INCLUDE_DIR}"
+       COMPONENT dev
+      )
+ 
+@@ -776,7 +769,7 @@ MACRO( PROCESS_EXAMPLES )
+ 
+   INSTALL(
+     FILES ${EXAMPLES_LIST}
+-    DESTINATION "${INSTALL_DOC_DIR_PREFIX}/examples"
++    DESTINATION "${INSTALL_DOC_DIR}/examples"
+   )
+ 
+ ENDMACRO( PROCESS_EXAMPLES )
diff --git a/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui_git.bb b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui_git.bb
index 4294528..d313fb0 100644
--- a/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui_git.bb
+++ b/meta-openembedded/meta-oe/recipes-graphics/libyui/libyui_git.bb
@@ -6,13 +6,14 @@
                    "
 
 SRC_URI = "git://github.com/libyui/libyui.git \
-           file://0001-Fix-GCC-8-warning.patch \
            file://0001-Fix-build-with-clang.patch \
+           file://0001-Use-curly-braces-for-MAKE-variable.patch \
+           file://0001-Use-relative-install-paths-for-CMake.patch \
            "
 
 PV = "3.3.3+git"
-SRCREV = "2b634cb7821e2e79dd4b7a73caf8e67c50189376"
-
+SRCREV = "50672da835ec9d52766320a44a2677e08a24c99c"
+SRCREV_FORMAT = "default"
 S = "${WORKDIR}/git"
 
 inherit cmake gettext pkgconfig
@@ -22,9 +23,9 @@
 BBCLASSEXTEND = "native nativesdk"
 
 do_configure_prepend () {
-        cd ${S}
-        ./bootstrap.sh
-        cd -
+        (cd ${S} &&
+        ./bootstrap.sh &&
+        cd -)
 }
 
 do_install_append () {
diff --git a/meta-openembedded/meta-oe/recipes-graphics/lxdm/lxdm/0001-check-for-libexecinfo-providing-backtrace-APIs.patch b/meta-openembedded/meta-oe/recipes-graphics/lxdm/lxdm/0003-check-for-libexecinfo-providing-backtrace-APIs.patch
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-graphics/lxdm/lxdm/0001-check-for-libexecinfo-providing-backtrace-APIs.patch
rename to meta-openembedded/meta-oe/recipes-graphics/lxdm/lxdm/0003-check-for-libexecinfo-providing-backtrace-APIs.patch
diff --git a/meta-openembedded/meta-oe/recipes-graphics/lxdm/lxdm/0004-fix-css-under-gtk-3.20.patch b/meta-openembedded/meta-oe/recipes-graphics/lxdm/lxdm/0004-fix-css-under-gtk-3.20.patch
new file mode 100644
index 0000000..afe11f3
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/lxdm/lxdm/0004-fix-css-under-gtk-3.20.patch
@@ -0,0 +1,27 @@
+From 72812894cfd9454d70e4b0753531e46580416771 Mon Sep 17 00:00:00 2001
+From: dgod <dgod.osa@gmail.com>
+Date: Mon, 21 Mar 2016 19:25:25 +0800
+Subject: [PATCH] fix css under gtk 3.20
+
+Upstream-Status: Applied [1]
+
+[1] https://git.lxde.org/gitweb/?p=lxde/lxdm.git;a=patch;h=72812894cfd9454d70e4b0753531e46580416771
+---
+ data/themes/Industrial/gtk.css | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/data/themes/Industrial/gtk.css b/data/themes/Industrial/gtk.css
+index 179f0d6..f8e6432 100644
+--- a/data/themes/Industrial/gtk.css
++++ b/data/themes/Industrial/gtk.css
+@@ -17,6 +17,7 @@
+ 	color: #000000;
+ }
+ 
++#bottom_pane label,
+ #bottom_pane GtkLabel {
+ 	font: Sans 12;
+ 	color: #9E9D9B;
+-- 
+2.14.4
+
diff --git a/meta-openembedded/meta-oe/recipes-graphics/lxdm/lxdm_0.5.3.bb b/meta-openembedded/meta-oe/recipes-graphics/lxdm/lxdm_0.5.3.bb
index 8e7efcd..701266b 100644
--- a/meta-openembedded/meta-oe/recipes-graphics/lxdm/lxdm_0.5.3.bb
+++ b/meta-openembedded/meta-oe/recipes-graphics/lxdm/lxdm_0.5.3.bb
@@ -7,14 +7,15 @@
            ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'file://lxdm-pam file://lxdm-pam-debug', '', d)} \
            ${@bb.utils.contains("DISTRO_TYPE", "debug", "", "file://0001-lxdm.conf.in-blacklist-root-for-release-images.patch",d)} \
            file://0002-let-autotools-create-lxdm.conf.patch \
-           file://0001-check-for-libexecinfo-providing-backtrace-APIs.patch \
+           file://0003-check-for-libexecinfo-providing-backtrace-APIs.patch \
+           file://0004-fix-css-under-gtk-3.20.patch \
            "
 SRC_URI[md5sum] = "061caae432634e6db38bbdc84bc6ffa0"
 SRC_URI[sha256sum] = "4891efee81c72a400cc6703e40aa76f3f3853833d048b72ec805da0f93567f2f"
 
 PE = "1"
 
-DEPENDS = "virtual/libintl intltool-native cairo dbus gdk-pixbuf glib-2.0 gtk+ virtual/libx11 libxcb pango iso-codes"
+DEPENDS = "virtual/libintl intltool-native cairo dbus gdk-pixbuf glib-2.0 gtk+3 virtual/libx11 libxcb pango iso-codes"
 DEPENDS += "${@bb.utils.contains("DISTRO_FEATURES", "systemd", "", "consolekit", d)}"
 DEPENDS_append_libc-musl = " libexecinfo"
 
@@ -28,7 +29,7 @@
 CFLAGS_append = " -fno-builtin-fork -fno-builtin-memset -fno-builtin-strstr "
 LDFLAGS_append_libc-musl = " -lexecinfo"
 
-EXTRA_OECONF += "--enable-gtk3=no --enable-password=yes --with-x -with-xconn=xcb \
+EXTRA_OECONF += "--enable-gtk3=yes --enable-password=yes --with-x -with-xconn=xcb \
     ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '--with-systemdsystemunitdir=${systemd_unitdir}/system/ --disable-consolekit', '--without-systemdsystemunitdir', d)} \
     ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '--with-pam', '--without-pam', d)} \
 "
diff --git a/meta-openembedded/meta-oe/recipes-graphics/openbox/openbox_3.6.1.bb b/meta-openembedded/meta-oe/recipes-graphics/openbox/openbox_3.6.1.bb
index c35a0c7..f4d21b8 100644
--- a/meta-openembedded/meta-oe/recipes-graphics/openbox/openbox_3.6.1.bb
+++ b/meta-openembedded/meta-oe/recipes-graphics/openbox/openbox_3.6.1.bb
@@ -39,7 +39,6 @@
     do_split_packages(d, theme_dir, '(.*)', theme_name, '${PN} theme for %s', extra_depends='', allow_dirs=True)
 }
 
-RDEPENDS_${PN} += "${PN}-core ${PN}-config ${PN}-theme-clearlooks"
 FILES_${PN}-core = "${bindir}/openbox ${bindir}/openbox-session ${libdir}/*${SOLIBS}"
 
 FILES_${PN}-lxde += "${datadir}/lxde/ \
@@ -54,3 +53,5 @@
 "
 
 FILES_${PN}-config += "${sysconfdir}"
+
+RDEPENDS_${PN} += "${PN}-core ${PN}-config ${PN}-theme-clearlooks python pyxdg"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/openjpeg/files/0001-bmp_read_info_header-reject-bmp-files-with-biBitCoun.patch b/meta-openembedded/meta-oe/recipes-graphics/openjpeg/files/0001-bmp_read_info_header-reject-bmp-files-with-biBitCoun.patch
deleted file mode 100644
index 866d9aa..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/openjpeg/files/0001-bmp_read_info_header-reject-bmp-files-with-biBitCoun.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 226f07e4b49c2757b181c62e6841000c512054e3 Mon Sep 17 00:00:00 2001
-From: Even Rouault <even.rouault@spatialys.com>
-Date: Mon, 14 Aug 2017 17:26:58 +0200
-Subject: [PATCH] bmp_read_info_header(): reject bmp files with biBitCount == 0
- (#983)
-
-Upstream-Status: Backport [https://github.com/uclouvain/openjpeg/commit/baf0c1ad4572daa89caa3b12985bdd93530f0dd7]
-CVE: CVE-2017-12982
-Signed-off-by: Dengke Du <dengke.du@windriver.com>
----
- src/bin/jp2/convertbmp.c | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/src/bin/jp2/convertbmp.c b/src/bin/jp2/convertbmp.c
-index b49e7a0..2715fdf 100644
---- a/src/bin/jp2/convertbmp.c
-+++ b/src/bin/jp2/convertbmp.c
-@@ -392,6 +392,10 @@ static OPJ_BOOL bmp_read_info_header(FILE* IN, OPJ_BITMAPINFOHEADER* header)
- 
-     header->biBitCount  = (OPJ_UINT16)getc(IN);
-     header->biBitCount |= (OPJ_UINT16)((OPJ_UINT32)getc(IN) << 8);
-+    if (header->biBitCount == 0) {
-+        fprintf(stderr, "Error, invalid biBitCount %d\n", 0);
-+        return OPJ_FALSE;
-+    }
- 
-     if (header->biSize >= 40U) {
-         header->biCompression  = (OPJ_UINT32)getc(IN);
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-graphics/openjpeg/openjpeg/0001-Ensure-cmake-files-are-installed-at-common-location.patch b/meta-openembedded/meta-oe/recipes-graphics/openjpeg/openjpeg/0001-Ensure-cmake-files-are-installed-at-common-location.patch
new file mode 100644
index 0000000..5c5fe64
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/openjpeg/openjpeg/0001-Ensure-cmake-files-are-installed-at-common-location.patch
@@ -0,0 +1,48 @@
+From fe491c0919f5adc8d626cb98c5ec19d0b99dfe20 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
+Date: Thu, 27 Sep 2018 23:45:04 +0200
+Subject: [PATCH] Ensure cmake files are installed at common location
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+* Otherwise recent poppler is not able to find them
+* Include path needs adjustment with this change
+
+Upstream-Status: Inappropriate [Configuration]
+
+Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
+---
+ CMakeLists.txt                | 2 +-
+ cmake/OpenJPEGConfig.cmake.in | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index ff70a06f..23d2fac4 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -150,7 +150,7 @@ if(NOT OPENJPEG_INSTALL_PACKAGE_DIR)
+   # We could install *.cmake files in share/ however those files contains
+   # hardcoded path to libraries on a multi-arch system (fedora/debian) those
+   # path will be different (lib/i386-linux-gnu vs lib/x86_64-linux-gnu)
+-  set(OPENJPEG_INSTALL_PACKAGE_DIR "${OPENJPEG_INSTALL_LIB_DIR}/${OPENJPEG_INSTALL_SUBDIR}")
++  set(OPENJPEG_INSTALL_PACKAGE_DIR "${OPENJPEG_INSTALL_LIB_DIR}/cmake/${OPENJPEG_INSTALL_SUBDIR}")
+ endif()
+ 
+ if (APPLE)
+diff --git a/cmake/OpenJPEGConfig.cmake.in b/cmake/OpenJPEGConfig.cmake.in
+index b20294ca..6a2f4baf 100644
+--- a/cmake/OpenJPEGConfig.cmake.in
++++ b/cmake/OpenJPEGConfig.cmake.in
+@@ -26,7 +26,7 @@ get_filename_component(SELF_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
+ if(EXISTS ${SELF_DIR}/OpenJPEGTargets.cmake)
+   # This is an install tree
+   include(${SELF_DIR}/OpenJPEGTargets.cmake)
+-  get_filename_component(OPENJPEG_INCLUDE_ROOT "${SELF_DIR}/../../@OPENJPEG_INSTALL_INCLUDE_DIR@" ABSOLUTE)
++  get_filename_component(OPENJPEG_INCLUDE_ROOT "${SELF_DIR}/../../../@OPENJPEG_INSTALL_INCLUDE_DIR@" ABSOLUTE)
+   set(OPENJPEG_INCLUDE_DIRS ${OPENJPEG_INCLUDE_ROOT})
+ 
+ else()
+-- 
+2.14.4
+
diff --git a/meta-openembedded/meta-oe/recipes-graphics/openjpeg/openjpeg/0002-Do-not-ask-cmake-to-export-binaries-they-don-t-make-.patch b/meta-openembedded/meta-oe/recipes-graphics/openjpeg/openjpeg/0002-Do-not-ask-cmake-to-export-binaries-they-don-t-make-.patch
new file mode 100644
index 0000000..0ba13cf
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/openjpeg/openjpeg/0002-Do-not-ask-cmake-to-export-binaries-they-don-t-make-.patch
@@ -0,0 +1,31 @@
+From 4681de07e21f17aa28710d3a51fabe7da60463f9 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
+Date: Fri, 28 Sep 2018 00:38:50 +0200
+Subject: [PATCH] Do not ask cmake to export binaries - they don't make it
+ dependants sysroots
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Upstream-Status: Inappropriate [OE-Specific]
+
+Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
+---
+ src/bin/jp2/CMakeLists.txt | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/src/bin/jp2/CMakeLists.txt b/src/bin/jp2/CMakeLists.txt
+index 4324c36d..2c11fe02 100644
+--- a/src/bin/jp2/CMakeLists.txt
++++ b/src/bin/jp2/CMakeLists.txt
+@@ -66,7 +66,6 @@ foreach(exe opj_decompress opj_compress opj_dump)
+   endif()
+   # Install exe
+   install(TARGETS ${exe}
+-    EXPORT OpenJPEGTargets
+     DESTINATION ${OPENJPEG_INSTALL_BIN_DIR} COMPONENT Applications
+   )
+   if(OPJ_USE_DSYMUTIL)
+-- 
+2.14.4
+
diff --git a/meta-openembedded/meta-oe/recipes-graphics/openjpeg/openjpeg_2.2.0.bb b/meta-openembedded/meta-oe/recipes-graphics/openjpeg/openjpeg_2.2.0.bb
deleted file mode 100644
index 4ef1c40..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/openjpeg/openjpeg_2.2.0.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-DESCRIPTION = "OpenJPEG library is an open-source JPEG 2000 codec"
-HOMEPAGE = "http://www.openjpeg.org"
-
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=c648878b4840d7babaade1303e7f108c"
-
-SRC_URI = "https://github.com/uclouvain/${BPN}/archive/v${PV}.tar.gz;downloadfilename=${BP}.tar.gz \
-           file://0001-bmp_read_info_header-reject-bmp-files-with-biBitCoun.patch \
-          "
-SRC_URI[md5sum] = "269bb0b175476f3addcc0d03bd9a97b6"
-SRC_URI[sha256sum] = "6fddbce5a618e910e03ad00d66e7fcd09cc6ee307ce69932666d54c73b7c6e7b"
-
-inherit cmake
-
-DEPENDS = "libpng tiff lcms zlib"
-
-# standard path for *.cmake
-EXTRA_OECMAKE += "-DOPENJPEG_INSTALL_PACKAGE_DIR=${baselib}/cmake \
-                  -DOPENJPEG_INSTALL_LIB_DIR:PATH=${libdir}"
-
-FILES_${PN}-dev += "${libdir}/cmake/*.cmake"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/openjpeg/openjpeg_2.3.0.bb b/meta-openembedded/meta-oe/recipes-graphics/openjpeg/openjpeg_2.3.0.bb
new file mode 100644
index 0000000..c50d55e
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/openjpeg/openjpeg_2.3.0.bb
@@ -0,0 +1,16 @@
+DESCRIPTION = "OpenJPEG library is an open-source JPEG 2000 codec"
+HOMEPAGE = "http://www.openjpeg.org"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=c648878b4840d7babaade1303e7f108c"
+
+DEPENDS = "libpng tiff lcms zlib"
+
+SRC_URI = " \
+    git://github.com/uclouvain/openjpeg.git \
+    file://0001-Ensure-cmake-files-are-installed-at-common-location.patch \
+    file://0002-Do-not-ask-cmake-to-export-binaries-they-don-t-make-.patch \
+"
+SRCREV = "081de4b15f54cb4482035b7bf5e3fb443e4bc84b"
+S = "${WORKDIR}/git"
+
+inherit cmake
diff --git a/meta-openembedded/meta-oe/recipes-graphics/tigervnc/files/0001-tigervnc-remove-includedir.patch b/meta-openembedded/meta-oe/recipes-graphics/tigervnc/files/0001-tigervnc-remove-includedir.patch
index 12c4376..f0056d6 100644
--- a/meta-openembedded/meta-oe/recipes-graphics/tigervnc/files/0001-tigervnc-remove-includedir.patch
+++ b/meta-openembedded/meta-oe/recipes-graphics/tigervnc/files/0001-tigervnc-remove-includedir.patch
@@ -1,6 +1,6 @@
-From 4b423cd2e5e4296abca3be553bf64d8cc287180a Mon Sep 17 00:00:00 2001
+From 47f175618a0b0817714ea557c9e93f22f327421e Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Thu, 20 Jul 2017 17:09:05 +0800
+Date: Tue, 31 Jul 2018 16:39:52 +0800
 Subject: [PATCH 1/4] tigervnc: remove includedir
 
 Upstream-Status: Pending
@@ -15,28 +15,28 @@
  1 file changed, 3 insertions(+), 3 deletions(-)
 
 diff --git a/unix/xserver/hw/vnc/Makefile.am b/unix/xserver/hw/vnc/Makefile.am
-index 0d6a4ac..854f078 100644
+index 470424b..ee18bf9 100644
 --- a/unix/xserver/hw/vnc/Makefile.am
 +++ b/unix/xserver/hw/vnc/Makefile.am
-@@ -22,7 +22,7 @@ libvnccommon_la_SOURCES = $(HDRS) \
+@@ -23,7 +23,7 @@ libvnccommon_la_SOURCES = $(HDRS) \
  
- libvnccommon_la_CPPFLAGS = -DVENDOR_RELEASE="$(VENDOR_RELEASE)" \
+ libvnccommon_la_CPPFLAGS = -DVENDOR_RELEASE="$(VENDOR_RELEASE)" -I$(TIGERVNC_SRCDIR)/unix/common \
  	-DVENDOR_STRING="\"$(VENDOR_STRING)\"" -I$(TIGERVNC_SRCDIR)/common -UHAVE_CONFIG_H \
 -	-I$(TIGERVNC_SRCDIR)/unix/vncconfig $(XVNC_CPPFLAGS) ${XSERVERLIBS_CFLAGS} -I$(includedir) \
 +	-I$(TIGERVNC_SRCDIR)/unix/vncconfig $(XVNC_CPPFLAGS) ${XSERVERLIBS_CFLAGS} \
  	-I$(top_srcdir)/include
  
  bin_PROGRAMS = Xvnc
-@@ -42,7 +42,7 @@ Xvnc_CPPFLAGS = $(XVNC_CPPFLAGS) -DTIGERVNC -DNO_MODULE_EXTS \
+@@ -43,7 +43,7 @@ Xvnc_CPPFLAGS = $(XVNC_CPPFLAGS) -DTIGERVNC -DNO_MODULE_EXTS \
  	-UHAVE_CONFIG_H \
  	-DXFree86Server -DVENDOR_RELEASE="$(VENDOR_RELEASE)" \
- 	-DVENDOR_STRING="\"$(VENDOR_STRING)\"" -I$(TIGERVNC_SRCDIR)/common \
+ 	-DVENDOR_STRING="\"$(VENDOR_STRING)\"" -I$(TIGERVNC_SRCDIR)/common -I$(TIGERVNC_SRCDIR)/unix/common \
 -	-I$(top_srcdir)/include ${XSERVERLIBS_CFLAGS} -I$(includedir)
 +	-I$(top_srcdir)/include ${XSERVERLIBS_CFLAGS}
  
  Xvnc_LDADD = $(XVNC_LIBS) libvnccommon.la $(COMMON_LIBS) \
  	$(XSERVER_LIBS) $(XSERVER_SYS_LIBS) $(XVNC_SYS_LIBS) -lX11
-@@ -62,7 +62,7 @@ libvnc_la_CPPFLAGS = $(XVNC_CPPFLAGS) -I$(TIGERVNC_SRCDIR)/common -UHAVE_CONFIG_
+@@ -64,7 +64,7 @@ libvnc_la_CPPFLAGS = $(XVNC_CPPFLAGS) -I$(TIGERVNC_SRCDIR)/common -UHAVE_CONFIG_
  	-I$(top_srcdir)/hw/xfree86/os-support \
  	-I$(top_srcdir)/hw/xfree86/os-support/bus \
  	-I$(top_srcdir)/include \
diff --git a/meta-openembedded/meta-oe/recipes-graphics/tigervnc/files/0005-Remove-INITARGS-from-xserver119.patch.patch b/meta-openembedded/meta-oe/recipes-graphics/tigervnc/files/0005-Remove-INITARGS-from-xserver119.patch.patch
deleted file mode 100644
index 2f342c6..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/tigervnc/files/0005-Remove-INITARGS-from-xserver119.patch.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From e4ec992984983ac9107efae1f1cc552007e4229e Mon Sep 17 00:00:00 2001
-From: Vishal Biswas <vshlbiswas@ymail.com>
-Date: Mon, 8 May 2017 11:06:11 +0530
-Subject: [PATCH] Remove INITARGS from xserver119.patch
-
-Upstream-Status: Backport
-
----
- unix/xserver119.patch | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/unix/xserver119.patch b/unix/xserver119.patch
-index 614f104..7adf314 100644
---- a/unix/xserver119.patch
-+++ b/unix/xserver119.patch
-@@ -66,7 +66,7 @@ diff -up xserver/mi/miinitext.c.xserver116-rebased xserver/mi/miinitext.c
-  #include "globals.h"
-  
- +#ifdef TIGERVNC
--+extern void vncExtensionInit(INITARGS);
-++extern void vncExtensionInit(void);
- +#endif
- +
-  /* The following is only a small first step towards run-time
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-oe/recipes-graphics/tigervnc/tigervnc_1.8.0.bb b/meta-openembedded/meta-oe/recipes-graphics/tigervnc/tigervnc_1.8.0.bb
deleted file mode 100644
index 469745f..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/tigervnc/tigervnc_1.8.0.bb
+++ /dev/null
@@ -1,132 +0,0 @@
-DESCRIPTION = "TigerVNC remote display system"
-HOMEPAGE = "http://www.tigervnc.com/"
-LICENSE = "GPLv2+"
-SECTION = "x11/utils"
-DEPENDS = "xserver-xorg gnutls jpeg libxtst gettext-native fltk"
-RDEPENDS_${PN} = "chkconfig coreutils hicolor-icon-theme"
-
-LIC_FILES_CHKSUM = "file://LICENCE.TXT;md5=75b02c2872421380bbd47781d2bd75d3"
-
-S = "${WORKDIR}/git"
-
-inherit distro_features_check
-REQUIRED_DISTRO_FEATURES = "x11"
-
-inherit autotools cmake
-B = "${S}"
-
-SRCREV = "4d6e1b8306a8cca8ad5e15ff8201f6ea24459cfd"
-
-SRC_URI = "git://github.com/TigerVNC/tigervnc.git;branch=1.8-branch \
-           file://0001-tigervnc-remove-includedir.patch \
-           file://0002-do-not-build-tests-sub-directory.patch \
-           file://0003-add-missing-dynamic-library-to-FLTK_LIBRARIES.patch \
-           file://0004-tigervnc-add-fPIC-option-to-COMPILE_FLAGS.patch \
-           file://0005-Remove-INITARGS-from-xserver119.patch.patch \
-"
-
-# Keep sync with xorg-server in oe-core
-XORG_PN ?= "xorg-server"
-XORG_PV ?= "1.19.3"
-SRC_URI += "${XORG_MIRROR}/individual/xserver/${XORG_PN}-${XORG_PV}.tar.bz2;name=xorg"
-XORG_S = "${WORKDIR}/${XORG_PN}-${XORG_PV}"
-SRC_URI[xorg.md5sum] = "015d2fc4b9f2bfe7a626edb63a62c65e"
-SRC_URI[xorg.sha256sum] = "677a8166e03474719238dfe396ce673c4234735464d6dadf2959b600d20e5a98"
-
-# It is the directory containing the Xorg source for the
-# machine on which you are building TigerVNC.
-XSERVER_SOURCE_DIR="${S}/unix/xserver"
-
-do_patch[postfuncs] += "do_patch_xserver"
-do_patch_xserver () {
-    for subdir in Xext xkb GL hw/xquartz/bundle hw/xfree86/common; do
-        install -d ${XSERVER_SOURCE_DIR}/$subdir
-    done
-
-    for subdir in hw/dmx/doc man doc hw/dmx/doxygen; do
-        install -d ${XSERVER_SOURCE_DIR}/$subdir
-    done
-
-    sources="hw/xquartz/bundle/cpprules.in man/Xserver.man doc/smartsched \
-             hw/dmx/doxygen/doxygen.conf.in xserver.ent.in xkb/README.compiled \
-             hw/xfree86/xorgconf.cpp hw/xfree86/Xorg.sh.in"
-    for i in ${sources}; do
-        install -m 0644 ${XORG_S}/$i ${XSERVER_SOURCE_DIR}/$i;
-    done
-
-    cd ${XORG_S}
-    find . -type f | egrep '.*\.(c|h|am|ac|inc|m4|h.in|pc.in|man.pre|pl|txt)$' | \
-    xargs tar cf - | (cd ${XSERVER_SOURCE_DIR} && tar xf -)
-
-    cd ${XSERVER_SOURCE_DIR}
-    xserverpatch="${S}/unix/xserver119.patch"
-    echo "Apply $xserverpatch"
-    patch -p1 -b --suffix .vnc < $xserverpatch
-}
-
-EXTRA_OECONF = "--disable-xorg --disable-xnest --disable-xvfb --disable-dmx \
-        --disable-xwin --disable-xephyr --disable-kdrive --with-pic \
-        --disable-static --disable-xinerama \
-        --with-xkb-output=${localstatedir}/lib/xkb \
-        --disable-glx --disable-dri --disable-dri2 \
-        --disable-config-hal \
-        --disable-config-udev \
-        --without-dtrace \
-        --disable-unit-tests \
-        --disable-devel-docs \
-        --disable-selective-werror \
-        --disable-xshmfence \
-        --disable-config-udev \
-        --disable-dri3 \
-        --disable-libunwind \
-        --without-xmlto \
-        --enable-systemd-logind=no \
-        --disable-xinerama \
-        --disable-xwayland \
-"
-
-do_configure_append () {
-    olddir=`pwd`
-    cd ${XSERVER_SOURCE_DIR}
-
-    rm -rf aclocal-copy/
-    rm -f aclocal.m4
-
-    export ACLOCALDIR="${XSERVER_SOURCE_DIR}/aclocal-copy"
-    mkdir -p ${ACLOCALDIR}/
-    if [ -d ${STAGING_DATADIR_NATIVE}/aclocal ]; then
-        cp-noerror ${STAGING_DATADIR_NATIVE}/aclocal/ ${ACLOCALDIR}/
-    fi
-    if [ -d ${STAGING_DATADIR}/aclocal -a "${STAGING_DATADIR_NATIVE}/aclocal" != "${STAGING_DATADIR}/aclocal" ]; then
-        cp-noerror ${STAGING_DATADIR}/aclocal/ ${ACLOCALDIR}/
-    fi
-    ACLOCAL="aclocal --system-acdir=${ACLOCALDIR}/" autoreconf -Wcross --verbose --install --force ${EXTRA_AUTORECONF} $acpaths || bbfatal "autoreconf execution failed."
-    chmod +x ./configure
-    ${CACHED_CONFIGUREVARS} ./configure ${CONFIGUREOPTS} ${EXTRA_OECONF}
-    cd $olddir
-}
-
-do_compile_append () {
-    olddir=`pwd`
-    cd ${XSERVER_SOURCE_DIR}
-
-    oe_runmake
-
-    cd $olddir
-}
-
-do_install_append() {
-    olddir=`pwd`
-    cd ${XSERVER_SOURCE_DIR}/hw/vnc
-
-    oe_runmake 'DESTDIR=${D}' install
-
-    cd $olddir
-}
-
-FILES_${PN} += " \
-    ${libdir}/xorg/modules/extensions \
-    ${datadir}/icons \
-"
-
-FILES_${PN}-dbg += "${libdir}/xorg/modules/extensions/.debug"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/tigervnc/tigervnc_1.9.0.bb b/meta-openembedded/meta-oe/recipes-graphics/tigervnc/tigervnc_1.9.0.bb
new file mode 100644
index 0000000..f3dc899
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/tigervnc/tigervnc_1.9.0.bb
@@ -0,0 +1,131 @@
+DESCRIPTION = "TigerVNC remote display system"
+HOMEPAGE = "http://www.tigervnc.com/"
+LICENSE = "GPLv2+"
+SECTION = "x11/utils"
+DEPENDS = "xserver-xorg gnutls jpeg libxtst gettext-native fltk"
+RDEPENDS_${PN} = "chkconfig coreutils hicolor-icon-theme"
+
+LIC_FILES_CHKSUM = "file://LICENCE.TXT;md5=75b02c2872421380bbd47781d2bd75d3"
+
+S = "${WORKDIR}/git"
+
+inherit distro_features_check
+REQUIRED_DISTRO_FEATURES = "x11"
+
+inherit autotools cmake
+B = "${S}"
+
+SRCREV = "6f2301d08e64a965ad36b401ec8dc2b24bc47075"
+
+SRC_URI = "git://github.com/TigerVNC/tigervnc.git;branch=1.9-branch \
+           file://0001-tigervnc-remove-includedir.patch \
+           file://0002-do-not-build-tests-sub-directory.patch \
+           file://0003-add-missing-dynamic-library-to-FLTK_LIBRARIES.patch \
+           file://0004-tigervnc-add-fPIC-option-to-COMPILE_FLAGS.patch \
+"
+
+# Keep sync with xorg-server in oe-core
+XORG_PN ?= "xorg-server"
+XORG_PV ?= "1.19.6"
+SRC_URI += "${XORG_MIRROR}/individual/xserver/${XORG_PN}-${XORG_PV}.tar.bz2;name=xorg"
+XORG_S = "${WORKDIR}/${XORG_PN}-${XORG_PV}"
+SRC_URI[xorg.md5sum] = "3e47777ff034a331aed2322b078694a8"
+SRC_URI[xorg.sha256sum] = "a732502f1db000cf36a376cd0c010ffdbf32ecdd7f1fa08ba7f5bdf9601cc197"
+
+# It is the directory containing the Xorg source for the
+# machine on which you are building TigerVNC.
+XSERVER_SOURCE_DIR="${S}/unix/xserver"
+
+do_patch[postfuncs] += "do_patch_xserver"
+do_patch_xserver () {
+    for subdir in Xext xkb GL hw/xquartz/bundle hw/xfree86/common; do
+        install -d ${XSERVER_SOURCE_DIR}/$subdir
+    done
+
+    for subdir in hw/dmx/doc man doc hw/dmx/doxygen; do
+        install -d ${XSERVER_SOURCE_DIR}/$subdir
+    done
+
+    sources="hw/xquartz/bundle/cpprules.in man/Xserver.man doc/smartsched \
+             hw/dmx/doxygen/doxygen.conf.in xserver.ent.in xkb/README.compiled \
+             hw/xfree86/xorgconf.cpp hw/xfree86/Xorg.sh.in"
+    for i in ${sources}; do
+        install -m 0644 ${XORG_S}/$i ${XSERVER_SOURCE_DIR}/$i;
+    done
+
+    cd ${XORG_S}
+    find . -type f | egrep '.*\.(c|h|am|ac|inc|m4|h.in|pc.in|man.pre|pl|txt)$' | \
+    xargs tar cf - | (cd ${XSERVER_SOURCE_DIR} && tar xf -)
+
+    cd ${XSERVER_SOURCE_DIR}
+    xserverpatch="${S}/unix/xserver119.patch"
+    echo "Apply $xserverpatch"
+    patch -p1 -b --suffix .vnc < $xserverpatch
+}
+
+EXTRA_OECONF = "--disable-xorg --disable-xnest --disable-xvfb --disable-dmx \
+        --disable-xwin --disable-xephyr --disable-kdrive --with-pic \
+        --disable-static --disable-xinerama \
+        --with-xkb-output=${localstatedir}/lib/xkb \
+        --disable-glx --disable-dri --disable-dri2 \
+        --disable-config-hal \
+        --disable-config-udev \
+        --without-dtrace \
+        --disable-unit-tests \
+        --disable-devel-docs \
+        --disable-selective-werror \
+        --disable-xshmfence \
+        --disable-config-udev \
+        --disable-dri3 \
+        --disable-libunwind \
+        --without-xmlto \
+        --enable-systemd-logind=no \
+        --disable-xinerama \
+        --disable-xwayland \
+"
+
+do_configure_append () {
+    olddir=`pwd`
+    cd ${XSERVER_SOURCE_DIR}
+
+    rm -rf aclocal-copy/
+    rm -f aclocal.m4
+
+    export ACLOCALDIR="${XSERVER_SOURCE_DIR}/aclocal-copy"
+    mkdir -p ${ACLOCALDIR}/
+    if [ -d ${STAGING_DATADIR_NATIVE}/aclocal ]; then
+        cp-noerror ${STAGING_DATADIR_NATIVE}/aclocal/ ${ACLOCALDIR}/
+    fi
+    if [ -d ${STAGING_DATADIR}/aclocal -a "${STAGING_DATADIR_NATIVE}/aclocal" != "${STAGING_DATADIR}/aclocal" ]; then
+        cp-noerror ${STAGING_DATADIR}/aclocal/ ${ACLOCALDIR}/
+    fi
+    ACLOCAL="aclocal --system-acdir=${ACLOCALDIR}/" autoreconf -Wcross --verbose --install --force ${EXTRA_AUTORECONF} $acpaths || bbfatal "autoreconf execution failed."
+    chmod +x ./configure
+    ${CACHED_CONFIGUREVARS} ./configure ${CONFIGUREOPTS} ${EXTRA_OECONF}
+    cd $olddir
+}
+
+do_compile_append () {
+    olddir=`pwd`
+    cd ${XSERVER_SOURCE_DIR}
+
+    oe_runmake
+
+    cd $olddir
+}
+
+do_install_append() {
+    olddir=`pwd`
+    cd ${XSERVER_SOURCE_DIR}/hw/vnc
+
+    oe_runmake 'DESTDIR=${D}' install
+
+    cd $olddir
+}
+
+FILES_${PN} += " \
+    ${libdir}/xorg/modules/extensions \
+    ${datadir}/icons \
+"
+
+FILES_${PN}-dbg += "${libdir}/xorg/modules/extensions/.debug"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/tslib/tslib_1.15.bb b/meta-openembedded/meta-oe/recipes-graphics/tslib/tslib_1.15.bb
deleted file mode 100644
index 7ae941a..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/tslib/tslib_1.15.bb
+++ /dev/null
@@ -1,82 +0,0 @@
-SUMMARY = "An abstraction layer for touchscreen panel events"
-DESCRIPTION = "Tslib is an abstraction layer for touchscreen panel \
-events, as well as a filter stack for the manipulation of those events. \
-Tslib is generally used on embedded devices to provide a common user \
-space interface to touchscreen functionality."
-HOMEPAGE = "http://tslib.org/"
-
-AUTHOR = "Martin Kepplinger <martink@posteo.de>"
-SECTION = "base"
-LICENSE = "LGPLv2+ & GPLv2+"
-LIC_FILES_CHKSUM = "\
-    file://COPYING;md5=fc178bcd425090939a8b634d1d6a9594 \
-    file://tests/COPYING;md5=a23a74b3f4caf9616230789d94217acb \
-"
-
-SRC_URI = "https://github.com/kergoth/tslib/releases/download/${PV}/tslib-${PV}.tar.xz;downloadfilename=tslib-${PV}.tar.xz \
-           file://ts.conf \
-           file://tslib.sh \
-"
-SRC_URI[md5sum] = "9ff36788c9ab76a10b58422227b9629e"
-SRC_URI[sha256sum] = "7ce48807cab655076d71a1ceef3ed0ab8a25df98074981d4a8fd1477ee5f710c"
-
-UPSTREAM_CHECK_URI = "https://github.com/kergoth/tslib/releases"
-
-inherit autotools pkgconfig
-
-PACKAGECONFIG ??= "debounce dejitter iir linear median pthres skip lowpass invert variance input touchkit waveshare"
-PACKAGECONFIG[debounce] = "--enable-debounce,--disable-debounce"
-PACKAGECONFIG[dejitter] = "--enable-dejitter,--disable-dejitter"
-PACKAGECONFIG[iir] = "--enable-iir,--disable-iir"
-PACKAGECONFIG[linear] = "--enable-linear,--disable-linear"
-PACKAGECONFIG[median] = "--enable-median,--disable-median"
-PACKAGECONFIG[pthres] = "--enable-pthres,--disable-pthres"
-PACKAGECONFIG[skip] = "--enable-skip,--disable-skip"
-PACKAGECONFIG[lowpass] = "--enable-lowpass,--disable-lowpass"
-PACKAGECONFIG[invert] = "--enable-invert,--disable-invert"
-PACKAGECONFIG[variance] = "--enable-variance,--disable-variance"
-PACKAGECONFIG[input] = "--enable-input,--disable-input"
-PACKAGECONFIG[tatung] = "--enable-tatung,--disable-tatung"
-PACKAGECONFIG[touchkit] = "--enable-touchkit,--disable-touchkit"
-PACKAGECONFIG[waveshare] = "--enable-waveshare,--disable-waveshare"
-PACKAGECONFIG[ucb1x00] = "--enable-ucb1x00,--disable-ucb1x00"
-PACKAGECONFIG[mk712] = "--enable-mk712,--disable-mk712"
-PACKAGECONFIG[h3600] = "--enable-h3600,--disable-h3600"
-PACKAGECONFIG[dmc] = "--enable-dmc,--disable-dmc"
-PACKAGECONFIG[linear-h2200] = "--enable-linear-h2200,--disable-linear-h2200"
-PACKAGECONFIG[corgi] = "--enable-corgi,--disable-corgi"
-PACKAGECONFIG[collie] = "--enable-collie,--disable-collie"
-PACKAGECONFIG[arctic2] = "--enable-arctic2,--disable-arctic2"
-PACKAGECONFIG[dmc_dus3000] = "--enable-dmc_dus3000,--disable-dmc_dus3000"
-PACKAGECONFIG[cy8mrln-palmpre] = "--enable-cy8mrln-palmpre,--disable-cy8mrln-palmpre"
-PACKAGECONFIG[galax] = "--enable-galax,--disable-galax"
-PACKAGECONFIG[debug] = "--enable-debug,--disable-debug"
-
-do_install_prepend() {
-    install -m 0644 ${WORKDIR}/ts.conf ${S}/etc/ts.conf
-}
-
-do_install_append() {
-    install -d ${D}${sysconfdir}/profile.d/
-    install -m 0755 ${WORKDIR}/tslib.sh ${D}${sysconfdir}/profile.d/
-}
-
-RPROVIDES_tslib-conf = "libts-0.0-conf"
-
-PACKAGES =+ "tslib-conf tslib-tests tslib-calibrate tslib-uinput"
-DEBIAN_NOAUTONAME_tslib-conf = "1"
-DEBIAN_NOAUTONAME_tslib-tests = "1"
-DEBIAN_NOAUTONAME_tslib-calibrate = "1"
-DEBIAN_NOAUTONAME_tslib-uinput = "1"
-
-RDEPENDS_${PN} = "tslib-conf"
-RRECOMMENDS_${PN} = "pointercal"
-
-FILES_${PN}-dev += "${libdir}/ts/*.la"
-FILES_tslib-conf = "${sysconfdir}/ts.conf ${sysconfdir}/profile.d/tslib.sh ${datadir}/tslib"
-FILES_${PN} = "${libdir}/*.so.* ${libdir}/ts/*.so*"
-FILES_tslib-calibrate += "${bindir}/ts_calibrate"
-FILES_tslib-uinput += "${bindir}/ts_uinput"
-
-FILES_tslib-tests = "${bindir}/ts_harvest ${bindir}/ts_print ${bindir}/ts_print_raw ${bindir}/ts_print_mt \
-                     ${bindir}/ts_test ${bindir}/ts_test_mt ${bindir}/ts_verify ${bindir}/ts_finddev"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/tslib/tslib_1.16.bb b/meta-openembedded/meta-oe/recipes-graphics/tslib/tslib_1.16.bb
new file mode 100644
index 0000000..8d23bd5
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/tslib/tslib_1.16.bb
@@ -0,0 +1,82 @@
+SUMMARY = "An abstraction layer for touchscreen panel events"
+DESCRIPTION = "Tslib is an abstraction layer for touchscreen panel \
+events, as well as a filter stack for the manipulation of those events. \
+Tslib is generally used on embedded devices to provide a common user \
+space interface to touchscreen functionality."
+HOMEPAGE = "http://tslib.org/"
+
+AUTHOR = "Martin Kepplinger <martink@posteo.de>"
+SECTION = "base"
+LICENSE = "LGPLv2+ & GPLv2+"
+LIC_FILES_CHKSUM = "\
+    file://COPYING;md5=fc178bcd425090939a8b634d1d6a9594 \
+    file://tests/COPYING;md5=a23a74b3f4caf9616230789d94217acb \
+"
+
+SRC_URI = "https://github.com/kergoth/tslib/releases/download/${PV}/tslib-${PV}.tar.xz;downloadfilename=tslib-${PV}.tar.xz \
+           file://ts.conf \
+           file://tslib.sh \
+"
+SRC_URI[md5sum] = "254a022fc8aa89d164840fe8869c2441"
+SRC_URI[sha256sum] = "c9a54651337a701a66b074c603c313225579995a7910e519bbc7b1dcdab9a755"
+
+UPSTREAM_CHECK_URI = "https://github.com/kergoth/tslib/releases"
+
+inherit autotools pkgconfig
+
+PACKAGECONFIG ??= "debounce dejitter iir linear median pthres skip lowpass invert variance input touchkit waveshare"
+PACKAGECONFIG[debounce] = "--enable-debounce,--disable-debounce"
+PACKAGECONFIG[dejitter] = "--enable-dejitter,--disable-dejitter"
+PACKAGECONFIG[iir] = "--enable-iir,--disable-iir"
+PACKAGECONFIG[linear] = "--enable-linear,--disable-linear"
+PACKAGECONFIG[median] = "--enable-median,--disable-median"
+PACKAGECONFIG[pthres] = "--enable-pthres,--disable-pthres"
+PACKAGECONFIG[skip] = "--enable-skip,--disable-skip"
+PACKAGECONFIG[lowpass] = "--enable-lowpass,--disable-lowpass"
+PACKAGECONFIG[invert] = "--enable-invert,--disable-invert"
+PACKAGECONFIG[variance] = "--enable-variance,--disable-variance"
+PACKAGECONFIG[input] = "--enable-input,--disable-input"
+PACKAGECONFIG[tatung] = "--enable-tatung,--disable-tatung"
+PACKAGECONFIG[touchkit] = "--enable-touchkit,--disable-touchkit"
+PACKAGECONFIG[waveshare] = "--enable-waveshare,--disable-waveshare"
+PACKAGECONFIG[ucb1x00] = "--enable-ucb1x00,--disable-ucb1x00"
+PACKAGECONFIG[mk712] = "--enable-mk712,--disable-mk712"
+PACKAGECONFIG[h3600] = "--enable-h3600,--disable-h3600"
+PACKAGECONFIG[dmc] = "--enable-dmc,--disable-dmc"
+PACKAGECONFIG[linear-h2200] = "--enable-linear-h2200,--disable-linear-h2200"
+PACKAGECONFIG[corgi] = "--enable-corgi,--disable-corgi"
+PACKAGECONFIG[collie] = "--enable-collie,--disable-collie"
+PACKAGECONFIG[arctic2] = "--enable-arctic2,--disable-arctic2"
+PACKAGECONFIG[dmc_dus3000] = "--enable-dmc_dus3000,--disable-dmc_dus3000"
+PACKAGECONFIG[cy8mrln-palmpre] = "--enable-cy8mrln-palmpre,--disable-cy8mrln-palmpre"
+PACKAGECONFIG[galax] = "--enable-galax,--disable-galax"
+PACKAGECONFIG[debug] = "--enable-debug,--disable-debug"
+
+do_install_prepend() {
+    install -m 0644 ${WORKDIR}/ts.conf ${S}/etc/ts.conf
+}
+
+do_install_append() {
+    install -d ${D}${sysconfdir}/profile.d/
+    install -m 0755 ${WORKDIR}/tslib.sh ${D}${sysconfdir}/profile.d/
+}
+
+RPROVIDES_tslib-conf = "libts-0.0-conf"
+
+PACKAGES =+ "tslib-conf tslib-tests tslib-calibrate tslib-uinput"
+DEBIAN_NOAUTONAME_tslib-conf = "1"
+DEBIAN_NOAUTONAME_tslib-tests = "1"
+DEBIAN_NOAUTONAME_tslib-calibrate = "1"
+DEBIAN_NOAUTONAME_tslib-uinput = "1"
+
+RDEPENDS_${PN} = "tslib-conf"
+RRECOMMENDS_${PN} = "pointercal"
+
+FILES_${PN}-dev += "${libdir}/ts/*.la"
+FILES_tslib-conf = "${sysconfdir}/ts.conf ${sysconfdir}/profile.d/tslib.sh ${datadir}/tslib"
+FILES_${PN} = "${libdir}/*.so.* ${libdir}/ts/*.so*"
+FILES_tslib-calibrate += "${bindir}/ts_calibrate"
+FILES_tslib-uinput += "${bindir}/ts_uinput"
+
+FILES_tslib-tests = "${bindir}/ts_harvest ${bindir}/ts_print ${bindir}/ts_print_raw ${bindir}/ts_print_mt \
+                     ${bindir}/ts_test ${bindir}/ts_test_mt ${bindir}/ts_verify ${bindir}/ts_finddev"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/vdpau/libvdpau_git.bb b/meta-openembedded/meta-oe/recipes-graphics/vdpau/libvdpau_git.bb
index 31bcce0..b79a562 100644
--- a/meta-openembedded/meta-oe/recipes-graphics/vdpau/libvdpau_git.bb
+++ b/meta-openembedded/meta-oe/recipes-graphics/vdpau/libvdpau_git.bb
@@ -3,7 +3,7 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://COPYING;md5=83af8811a28727a13f04132cc33b7f58"
 
-DEPENDS = "virtual/libx11 libxext dri2proto"
+DEPENDS = "virtual/libx11 libxext xorgproto"
 
 PV = "1.1.1+git${SRCPV}"
 
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xorg-app/iceauth_1.0.7.bb b/meta-openembedded/meta-oe/recipes-graphics/xorg-app/iceauth_1.0.7.bb
deleted file mode 100644
index f40dec8..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/xorg-app/iceauth_1.0.7.bb
+++ /dev/null
@@ -1,16 +0,0 @@
-require recipes-graphics/xorg-app/xorg-app-common.inc
-
-SUMMARY = "X.Org X11 X client utilities"
-
-DESCRIPTION = "A collection of utilities used to tweak and query the runtime configuration\
-of the X server."
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=13f70acf3c27f5f834bbc954df775f8e"
-
-BBCLASSEXTEND = "native"
-
-DEPENDS += "libice"
-
-SRC_URI[md5sum] = "25dab02f8e40d5b71ce29a07dc901b8c"
-SRC_URI[sha256sum] = "1216af2dee99b318fcf8bf9a259915273bcb37a7f1e7859af4f15d0ebf6f3f0a"
-
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xorg-app/iceauth_1.0.8.bb b/meta-openembedded/meta-oe/recipes-graphics/xorg-app/iceauth_1.0.8.bb
new file mode 100644
index 0000000..62296b5
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/xorg-app/iceauth_1.0.8.bb
@@ -0,0 +1,16 @@
+require recipes-graphics/xorg-app/xorg-app-common.inc
+
+SUMMARY = "X.Org X11 X client utilities"
+
+DESCRIPTION = "A collection of utilities used to tweak and query the runtime configuration\
+of the X server."
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=13f70acf3c27f5f834bbc954df775f8e"
+
+BBCLASSEXTEND = "native"
+
+DEPENDS += "libice"
+
+SRC_URI[md5sum] = "3b9b79fa0f9928161f4bad94273de7ae"
+SRC_URI[sha256sum] = "e6ee213a217265cc76050e4293ea70b98c32dce6505c6421227efbda62ab60c6"
+
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xorg-app/xkbevd_1.1.4.bb b/meta-openembedded/meta-oe/recipes-graphics/xorg-app/xkbevd_1.1.4.bb
index a6fc9e7..b42c1b9 100644
--- a/meta-openembedded/meta-oe/recipes-graphics/xorg-app/xkbevd_1.1.4.bb
+++ b/meta-openembedded/meta-oe/recipes-graphics/xorg-app/xkbevd_1.1.4.bb
@@ -5,7 +5,7 @@
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=208668fa9004709ba22c2b748140956c"
 
-DEPENDS += "libxkbfile"
+DEPENDS += "libxkbfile bison-native"
 
 BBCLASSEXTEND = "native"
 
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xorg-app/xrdb_1.1.0.bb b/meta-openembedded/meta-oe/recipes-graphics/xorg-app/xrdb_1.1.0.bb
deleted file mode 100644
index 85957e0..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/xorg-app/xrdb_1.1.0.bb
+++ /dev/null
@@ -1,9 +0,0 @@
-require recipes-graphics/xorg-app/xorg-app-common.inc
-SUMMARY = "X server resource database utility"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d1167c4f586bd41f0c62166db4384a69"
-
-DEPENDS += "libxmu"
-
-SRC_URI[md5sum] = "b54c7e3e53b4f332d41ed435433fbda0"
-SRC_URI[sha256sum] = "73827b6bbfc9d27ca287d95a1224c306d7053cd7b8156641698d7dc541ca565b"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xorg-app/xrdb_1.1.1.bb b/meta-openembedded/meta-oe/recipes-graphics/xorg-app/xrdb_1.1.1.bb
new file mode 100644
index 0000000..e50c082
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/xorg-app/xrdb_1.1.1.bb
@@ -0,0 +1,9 @@
+require recipes-graphics/xorg-app/xorg-app-common.inc
+SUMMARY = "X server resource database utility"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d1167c4f586bd41f0c62166db4384a69"
+
+DEPENDS += "libxmu"
+
+SRC_URI[md5sum] = "96f9423eab4d0641c70848d665737d2e"
+SRC_URI[sha256sum] = "2d23ade7cdbb487996bf77cbb32cbe9bdb34d004748a53de7a4a97660d2217b7"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xorg-app/xterm_330.bb b/meta-openembedded/meta-oe/recipes-graphics/xorg-app/xterm_330.bb
index 16f9b78..c2feb81 100644
--- a/meta-openembedded/meta-oe/recipes-graphics/xorg-app/xterm_330.bb
+++ b/meta-openembedded/meta-oe/recipes-graphics/xorg-app/xterm_330.bb
@@ -1,6 +1,6 @@
 require recipes-graphics/xorg-app/xorg-app-common.inc
 SUMMARY = "xterm is the standard terminal emulator for the X Window System"
-DEPENDS = "libxaw xproto xextproto libxext libxau libxinerama libxpm ncurses"
+DEPENDS = "libxaw xorgproto libxext libxau libxinerama libxpm ncurses"
 
 LIC_FILES_CHKSUM = "file://xterm.h;beginline=3;endline=31;md5=f02ab9ebda87b770ecf711dbb3784a33"
 
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-armsoc_1.4.1.bb b/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-armsoc_1.4.1.bb
new file mode 100644
index 0000000..b436ef1
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-armsoc_1.4.1.bb
@@ -0,0 +1,14 @@
+require recipes-graphics/xorg-driver/xorg-driver-video.inc
+
+SUMMARY = "X.Org X server -- ARM SOC display driver"
+LICENSE = "MIT-X & GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=10ce5de3b111315ea652a5f74ec0c602"
+
+DEPENDS += "virtual/libx11 libdrm xorgproto"
+
+SRCREV = "8bbdb2ae3bb8ef649999a8da33ddbe11a04763b8"
+SRC_URI = "git://anongit.freedesktop.org/xorg/driver/xf86-video-armsoc"
+
+S = "${WORKDIR}/git"
+
+RDEPENDS_${PN} += "xserver-xorg-module-exa"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-ati_18.0.1.bb b/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-ati_18.0.1.bb
new file mode 100644
index 0000000..969c1a0
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-ati_18.0.1.bb
@@ -0,0 +1,25 @@
+require recipes-graphics/xorg-driver/xorg-driver-video.inc
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=aabff1606551f9461ccf567739af63dc"
+
+SUMMARY = "X.Org X server -- ATI Radeon video driver"
+
+DESCRIPTION = "Open-source X.org graphics driver for ATI Radeon graphics"
+
+DEPENDS += "virtual/libx11 libxvmc drm \
+            virtual/libgl xorgproto libpciaccess"
+
+inherit distro_features_check
+REQUIRED_DISTRO_FEATURES += "opengl"
+
+COMPATIBLE_HOST = '(i.86|x86_64).*-linux'
+
+SRC_URI[md5sum] = "40e7c0a5a69aba3d84e0958f58705ea7"
+SRC_URI[sha256sum] = "72ea3b8127d4550b64f797457f5a7851a541fa4ee2cc3f345b6c1886b81714a0"
+
+EXTRA_OECONF += "--disable-glamor"
+
+RDEPENDS_${PN} += "xserver-xorg-module-exa"
+RRECOMMENDS_${PN} += "linux-firmware-radeon"
+
+FILES_${PN} += "${datadir}/X11"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-ati_7.8.0.bb b/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-ati_7.8.0.bb
deleted file mode 100644
index d409a18..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-ati_7.8.0.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-require recipes-graphics/xorg-driver/xorg-driver-video.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=aabff1606551f9461ccf567739af63dc"
-
-SUMMARY = "X.Org X server -- ATI Radeon video driver"
-
-DESCRIPTION = "Open-source X.org graphics driver for ATI Radeon graphics"
-
-DEPENDS += "virtual/libx11 libxvmc drm xf86driproto glproto \
-            virtual/libgl xineramaproto libpciaccess"
-
-inherit distro_features_check
-REQUIRED_DISTRO_FEATURES += "opengl"
-
-COMPATIBLE_HOST = '(i.86|x86_64).*-linux'
-
-SRC_URI[md5sum] = "f34d04a755e761e03b459155fa3ddcbb"
-SRC_URI[sha256sum] = "401f5de772928f3dc4ce43a885adb0a47a2f61aa4a9e45d2ab3d184136a9d6fa"
-
-EXTRA_OECONF += "--disable-glamor"
-
-RDEPENDS_${PN} += "xserver-xorg-module-exa"
-RRECOMMENDS_${PN} += "linux-firmware-radeon"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-mga_1.6.5.bb b/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-mga_1.6.5.bb
index cd68059..182e18f 100644
--- a/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-mga_1.6.5.bb
+++ b/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-mga_1.6.5.bb
@@ -16,6 +16,6 @@
 SRC_URI[sha256sum] = "b663cd8e6364f7c4e2637b9fcab9861d0e3971518c73b00d213f6545a1289422"
 
 PACKAGECONFIG ?= "${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'dri', '', d)}"
-PACKAGECONFIG[dri] = "--enable-dri,--disable-dri,drm xf86driproto,xserver-xorg-extension-dri"
+PACKAGECONFIG[dri] = "--enable-dri,--disable-dri,drm xorgproto,xserver-xorg-extension-dri"
 
 RDEPENDS_${PN} = "xserver-xorg-module-exa"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-nouveau_1.0.15.bb b/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-nouveau_1.0.15.bb
index 2746821..2b1b87c 100644
--- a/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-nouveau_1.0.15.bb
+++ b/meta-openembedded/meta-oe/recipes-graphics/xorg-driver/xf86-video-nouveau_1.0.15.bb
@@ -6,8 +6,8 @@
 
 DESCRIPTION = "Open-source X.org graphics driver for NVIDIA graphics"
 
-DEPENDS += "virtual/libx11 libxvmc drm xf86driproto glproto \
-            virtual/libgl xineramaproto libpciaccess"
+DEPENDS += "virtual/libx11 libxvmc drm xorgproto \
+            virtual/libgl libpciaccess"
 RDEPENDS_${PN} += "xserver-xorg-module-exa"
 
 inherit distro_features_check
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xorg-lib/liblbxutil_1.1.0.bb b/meta-openembedded/meta-oe/recipes-graphics/xorg-lib/liblbxutil_1.1.0.bb
index 7d26d14..3e5c31a 100644
--- a/meta-openembedded/meta-oe/recipes-graphics/xorg-lib/liblbxutil_1.1.0.bb
+++ b/meta-openembedded/meta-oe/recipes-graphics/xorg-lib/liblbxutil_1.1.0.bb
@@ -3,7 +3,7 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=b0d5bdc98f7ebab3b6c3791d9bf40907"
 
 SUMMARY = "XFIXES Extension"
-DEPENDS += " xextproto xproto zlib"
+DEPENDS += " xorgproto zlib"
 PE = "1"
 PR = "r11"
 
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xorg-lib/libxaw_1.0.13.bb b/meta-openembedded/meta-oe/recipes-graphics/xorg-lib/libxaw_1.0.13.bb
index 8ba5ac3..cb1ffcd 100644
--- a/meta-openembedded/meta-oe/recipes-graphics/xorg-lib/libxaw_1.0.13.bb
+++ b/meta-openembedded/meta-oe/recipes-graphics/xorg-lib/libxaw_1.0.13.bb
@@ -1,6 +1,6 @@
 require recipes-graphics/xorg-lib/xorg-lib-common.inc
 SUMMARY = "X Athena Widget Set"
-DEPENDS += "xproto virtual/libx11 libxext xextproto libxt libxmu libxpm libxau xmlto-native"
+DEPENDS += "xorgproto virtual/libx11 libxext libxt libxmu libxpm libxau xmlto-native"
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=1c65719d42900bb81b83e8293c20a364"
 
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xorg-lib/libxpresent_1.0.0.bb b/meta-openembedded/meta-oe/recipes-graphics/xorg-lib/libxpresent_1.0.0.bb
new file mode 100644
index 0000000..4fe9992
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/xorg-lib/libxpresent_1.0.0.bb
@@ -0,0 +1,11 @@
+require recipes-graphics/xorg-lib/xorg-lib-common.inc
+SUMMARY = "X Athena Widget Set"
+DEPENDS += "xorgproto libxfixes libxrandr"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=3c1ce42c334a6f5cccb0277556a053e0"
+
+SRC_URI = "http://xorg.freedesktop.org/archive/individual/lib/libXpresent-${PV}.tar.bz2"
+SRC_URI[md5sum] = "edd87ac15bb666081898dd7382fcbff5"
+SRC_URI[sha256sum] = "c11ae015141a9afbe10f4f2b8ee00b11adca6373dc1b9808d7c6c138b2da7b8a"
+
+XORG_PN = "libXpresent"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xscreensaver/files/fix-buildscripts.patch b/meta-openembedded/meta-oe/recipes-graphics/xscreensaver/files/fix-buildscripts.patch
new file mode 100644
index 0000000..3a50eff
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/xscreensaver/files/fix-buildscripts.patch
@@ -0,0 +1,116 @@
+--- xscreensaver-5.39.orig/configure.in
++++ xscreensaver-5.39/configure.in
+@@ -14,6 +14,9 @@
+ #
+ ###############################################################################
+ 
++includedir=''
++libdir=''
++
+ AH_TOP([
+ /* config.h.in --- xscreensaver, Copyright (c) 1991-2014 Jamie Zawinski.
+  *
+@@ -422,12 +425,12 @@
+ 
+   OBJCC="$CC"
+ 
+-  AC_MSG_CHECKING([whether the compiler works on ANSI C])
+-  AC_TRY_RUN([ main(int ac, char **av) { return 0; } ],
+-     AC_MSG_RESULT(yes),
+-     AC_MSG_RESULT(no)
+-     AC_MSG_ERROR(Couldn't build even a trivial ANSI C program: check CC.),
+-     AC_MSG_ERROR(Couldn't build even a trivial ANSI C program: check CC.))
++#  AC_MSG_CHECKING([whether the compiler works on ANSI C])
++#  AC_TRY_RUN([ main(int ac, char **av) { return 0; } ],
++#     AC_MSG_RESULT(yes),
++#     AC_MSG_RESULT(no)
++#     AC_MSG_ERROR(Couldn't build even a trivial ANSI C program: check CC.),
++#     AC_MSG_ERROR(Couldn't build even a trivial ANSI C program: check CC.))
+ 
+   if test -n "$GCC"; then
+     AC_MSG_RESULT(Turning on gcc compiler warnings.)
+--- xscreensaver-5.39.orig/Makefile.in
++++ xscreensaver-5.39/Makefile.in
+@@ -6,7 +6,7 @@
+ VPATH		= @srcdir@
+ 
+ SHELL		= /bin/sh
+-SUBDIRS 	= utils jwxyz hacks/images hacks hacks/glx driver po
++SUBDIRS 	= utils jwxyz hacks/images hacks driver
+ SUBDIRS2	= $(SUBDIRS) OSX android
+ TARFILES	= README README.hacking README.VMS INSTALL \
+ 		  configure configure.in Makefile.in config.h.in \
+--- xscreensaver-5.39.orig/driver/Makefile.in
++++ xscreensaver-5.39/driver/Makefile.in
+@@ -10,7 +10,7 @@
+ top_srcdir	= @top_srcdir@
+ top_builddir	= ..
+ 
+-install_prefix	=
++install_prefix	= ${DESTDIR}
+ prefix		= @prefix@
+ exec_prefix	= @exec_prefix@
+ bindir		= @bindir@
+@@ -221,7 +221,7 @@
+ SCRIPTS_1	= xscreensaver-getimage-file xscreensaver-getimage-video \
+ 		  xscreensaver-text
+ SCRIPTS_OSX	= xscreensaver-getimage-desktop
+-SCRIPTS		= $(SCRIPTS_1) @SCRIPTS_OSX@
++#SCRIPTS		= $(SCRIPTS_1) @SCRIPTS_OSX@
+ 
+ HDRS		= XScreenSaver_ad.h XScreenSaver_Xm_ad.h \
+ 		  xscreensaver.h prefs.h remote.h exec.h \
+--- xscreensaver-5.39.orig/hacks/Makefile.in
++++ xscreensaver-5.39/hacks/Makefile.in
+@@ -10,7 +10,7 @@
+ top_srcdir	= @top_srcdir@
+ top_builddir	= ..
+ 
+-install_prefix	=
++install_prefix	= ${DESTDIR}
+ prefix		= @prefix@
+ exec_prefix	= @exec_prefix@
+ bindir		= @bindir@
+@@ -122,7 +122,7 @@
+ 		  asm6502.c abstractile.c lcdscrub.c hexadrop.c \
+ 		  tessellimage.c delaunay.c recanim.c binaryring.c \
+ 		  webcollage-cocoa.m webcollage-helper-cocoa.m testx11.c
+-SCRIPTS		= vidwhacker webcollage ljlatest
++#SCRIPTS		= vidwhacker webcollage ljlatest
+ 
+ # Programs that are mentioned in XScreenSaver.ad, and that have XML files,
+ # but that are not shipped with xscreensaver itself.
+@@ -163,7 +163,13 @@
+ 		  lcdscrub.o hexadrop.o tessellimage.o delaunay.o recanim.o \
+ 		  binaryring.o testx11.o
+ 
+-EXES		= attraction blitspin bouboule braid decayscreen deco \
++EXES		= fontglide
++JPEG_EXES	= webcollage-helper
++
++RETIRED_EXES	= ant bubbles critical flag forest hyperball hypercube laser \
++		  lightning lisa lissie lmorph rotor sphere spiral t3d vines \
++		  whirlygig worm xsublim juggle testx11 \
++		  attraction blitspin bouboule braid decayscreen deco \
+ 		  drift flame galaxy grav greynetic halo \
+ 		  helix hopalong ifs imsmap julia kaleidescope \
+ 		  maze moire noseguy pedal \
+@@ -179,17 +185,12 @@
+ 		  speedmine vermiculate twang apollonian euler2d \
+ 		  polyominoes thornbird  fluidballs anemone halftone \
+ 		  metaballs eruption popsquares barcode piecewise cloudlife \
+-		  fontglide apple2 xanalogtv pong  wormhole \
++		  apple2 xanalogtv pong  wormhole \
+ 		  pacman fuzzyflakes anemotaxis memscroller substrate \
+ 		  intermomentary fireworkx fiberlamp boxfit interaggregate \
+ 		  celtic cwaves m6502 abstractile lcdscrub hexadrop \
+ 		  tessellimage binaryring \
+ 		  @JPEG_EXES@
+-JPEG_EXES	= webcollage-helper
+-
+-RETIRED_EXES	= ant bubbles critical flag forest hyperball hypercube laser \
+-		  lightning lisa lissie lmorph rotor sphere spiral t3d vines \
+-		  whirlygig worm xsublim juggle testx11
+ 
+ HACK_OBJS_1	= fps.o $(UTILS_BIN)/resources.o $(UTILS_BIN)/visual.o \
+ 		  $(UTILS_BIN)/usleep.o $(UTILS_BIN)/yarandom.o \
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xscreensaver/files/tweak-app-defaults.patch b/meta-openembedded/meta-oe/recipes-graphics/xscreensaver/files/tweak-app-defaults.patch
new file mode 100644
index 0000000..099a0b2
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/xscreensaver/files/tweak-app-defaults.patch
@@ -0,0 +1,273 @@
+--- xscreensaver-5.39.orig/driver/XScreenSaver.ad.in
++++ xscreensaver-5.39/driver/XScreenSaver.ad.in
+@@ -29,7 +29,7 @@
+ ! /* (xrdb prevention kludge: whole file)
+ 
+ *mode:			random
+-*timeout:		0:10:00
++*timeout:		0:15:00
+ *cycle:			0:10:00
+ *lockTimeout:		0:00:00
+ *passwdTimeout:		0:00:30
+@@ -38,7 +38,7 @@
+ *dpmsStandby:		2:00:00
+ *dpmsSuspend:		2:00:00
+ *dpmsOff:		4:00:00
+-*grabDesktopImages:	True
++*grabDesktopImages:	False
+ *grabVideoFrames:	False
+ *chooseRandomImages:	@DEFAULT_IMAGES_P@
+ ! This can be a local directory name, or the URL of an RSS or Atom feed.
+@@ -48,11 +48,11 @@
+ *lock:			False
+ *verbose:		False
+ *timestamp:		True
+-*fade:			True
++*fade:			False
+ *unfade:		False
+ *fadeSeconds:		0:00:03
+ *fadeTicks:		20
+-*splash:		True
++*splash:		False
+ *splashDuration:	0:00:05
+ *visualID:		default
+ *captureStderr: 	True
+@@ -158,236 +158,8 @@
+ ! screen savers interactively.
+ !
+ *programs:								      \
+-				maze -root				    \n\
+-@GL_KLUDGE@ GL: 				superquadrics -root			    \n\
+-				attraction -root			    \n\
+-				blitspin -root				    \n\
+-				greynetic -root				    \n\
+-				helix -root				    \n\
+-				hopalong -root				    \n\
+-				imsmap -root				    \n\
+--				noseguy -root				    \n\
+--				pyro -root				    \n\
+-				qix -root				    \n\
+--				rocks -root				    \n\
+-				rorschach -root				    \n\
+-				decayscreen -root			    \n\
+-				flame -root				    \n\
+-				halo -root				    \n\
+-				slidescreen -root			    \n\
+-				pedal -root				    \n\
+-				bouboule -root				    \n\
+--				braid -root				    \n\
+-				coral -root				    \n\
+-				deco -root				    \n\
+-				drift -root				    \n\
+--				fadeplot -root				    \n\
+-				galaxy -root				    \n\
+-				goop -root				    \n\
+-				grav -root				    \n\
+-				ifs -root				    \n\
+-@GL_KLUDGE@ GL: 				jigsaw -root				    \n\
+-				julia -root				    \n\
+--				kaleidescope -root			    \n\
+-@GL_KLUDGE@ GL: 				moebius -root				    \n\
+-				moire -root				    \n\
+-@GL_KLUDGE@ GL: 				morph3d -root				    \n\
+-				mountain -root				    \n\
+-				munch -root				    \n\
+-				penrose -root				    \n\
+-@GL_KLUDGE@ GL: 				pipes -root				    \n\
+-				rd-bomb -root				    \n\
+-@GL_KLUDGE@ GL: 				rubik -root				    \n\
+--				sierpinski -root			    \n\
+-				slip -root				    \n\
+-@GL_KLUDGE@ GL: 				sproingies -root			    \n\
+-				starfish -root				    \n\
+-				strange -root				    \n\
+-				swirl -root				    \n\
+-				triangle -root				    \n\
+-				xjack -root				    \n\
+-				xlyap -root				    \n\
+-@GL_KLUDGE@ GL: 				atlantis -root				    \n\
+-				bsod -root				    \n\
+-@GL_KLUDGE@ GL: 				bubble3d -root				    \n\
+-@GL_KLUDGE@ GL: 				cage -root				    \n\
+--				crystal -root				    \n\
+-				cynosure -root				    \n\
+-				discrete -root				    \n\
+-				distort -root				    \n\
+-				epicycle -root				    \n\
+-				flow -root				    \n\
+-@GL_KLUDGE@ GL: 				glplanet -root				    \n\
+-				interference -root			    \n\
+-				kumppa -root				    \n\
+-@GL_KLUDGE@ GL: 				lament -root				    \n\
+-				moire2 -root				    \n\
+-@GL_KLUDGE@ GL: 				sonar -root				    \n\
+-@GL_KLUDGE@ GL: 				stairs -root				    \n\
+-				truchet -root				    \n\
+--				vidwhacker -root			    \n\
+-				blaster -root				    \n\
+-				bumps -root				    \n\
+-				ccurve -root				    \n\
+-				compass -root				    \n\
+-				deluxe -root				    \n\
+--				demon -root				    \n\
+-@GLE_KLUDGE@ GL: 				extrusion -root				    \n\
+--				loop -root				    \n\
+-				penetrate -root				    \n\
+-				petri -root				    \n\
+-				phosphor -root				    \n\
+-@GL_KLUDGE@ GL: 				pulsar -root				    \n\
+-				ripples -root				    \n\
+-				shadebobs -root				    \n\
+-@GL_KLUDGE@ GL: 				sierpinski3d -root			    \n\
+-				spotlight -root				    \n\
+-				squiral -root				    \n\
+-				wander -root				    \n\
+--				webcollage -root			    \n\
+-				xflame -root				    \n\
+-				xmatrix -root				    \n\
+-@GL_KLUDGE@ GL: 				gflux -root				    \n\
+--				nerverot -root				    \n\
+-				xrayswarm -root				    \n\
+-				xspirograph -root			    \n\
+-@GL_KLUDGE@ GL: 				circuit -root				    \n\
+-@GL_KLUDGE@ GL: 				dangerball -root			    \n\
+-- GL: 				dnalogo -root				    \n\
+-@GL_KLUDGE@ GL: 				engine -root				    \n\
+-@GL_KLUDGE@ GL: 				flipscreen3d -root			    \n\
+-@GL_KLUDGE@ GL: 				gltext -root				    \n\
+-@GL_KLUDGE@ GL: 				menger -root				    \n\
+-@GL_KLUDGE@ GL: 				molecule -root				    \n\
+-				rotzoomer -root				    \n\
+-				speedmine -root				    \n\
+-@GL_KLUDGE@ GL: 				starwars -root				    \n\
+-@GL_KLUDGE@ GL: 				stonerview -root			    \n\
+-				vermiculate -root			    \n\
+-				whirlwindwarp -root			    \n\
+-				zoom -root				    \n\
+-				anemone -root				    \n\
+-				apollonian -root			    \n\
+-@GL_KLUDGE@ GL: 				boxed -root				    \n\
+-@GL_KLUDGE@ GL: 				cubenetic -root				    \n\
+-@GL_KLUDGE@ GL: 				endgame -root				    \n\
+-				euler2d -root				    \n\
+-				fluidballs -root			    \n\
+-@GL_KLUDGE@ GL: 				flurry -root				    \n\
+-- GL: 				glblur -root				    \n\
+-@GL_KLUDGE@ GL: 				glsnake -root				    \n\
+-				halftone -root				    \n\
+-@GL_KLUDGE@ GL: 				juggler3d -root				    \n\
+-@GL_KLUDGE@ GL: 				lavalite -root				    \n\
+--				polyominoes -root			    \n\
+-@GL_KLUDGE@ GL: 				queens -root				    \n\
+-- GL: 				sballs -root				    \n\
+-@GL_KLUDGE@ GL: 				spheremonics -root			    \n\
+--				thornbird -root				    \n\
+-				twang -root				    \n\
+-- GL: 				antspotlight -root			    \n\
+-				apple2 -root				    \n\
+-@GL_KLUDGE@ GL: 				atunnel -root				    \n\
+-				barcode -root				    \n\
+-@GL_KLUDGE@ GL: 				blinkbox -root				    \n\
+-@GL_KLUDGE@ GL: 				blocktube -root				    \n\
+-@GL_KLUDGE@ GL: 				bouncingcow -root			    \n\
+-				cloudlife -root				    \n\
+-@GL_KLUDGE@ GL: 				cubestorm -root				    \n\
+-				eruption -root				    \n\
+-@GL_KLUDGE@ GL: 				flipflop -root				    \n\
+-@GL_KLUDGE@ GL: 				flyingtoasters -root			    \n\
+-				fontglide -root				    \n\
+-@GL_KLUDGE@ GL: 				gleidescope -root			    \n\
+-@GL_KLUDGE@ GL: 				glknots -root				    \n\
+-@GL_KLUDGE@ GL: 				glmatrix -root				    \n\
+-- GL: 				glslideshow -root			    \n\
+-@GL_KLUDGE@ GL: 				hypertorus -root			    \n\
+-- GL: 				jigglypuff -root			    \n\
+-				metaballs -root				    \n\
+-@GL_KLUDGE@ GL: 				mirrorblob -root			    \n\
+-				piecewise -root				    \n\
+-@GL_KLUDGE@ GL: 				polytopes -root				    \n\
+-				pong -root				    \n\
+-				popsquares -root			    \n\
+-@GL_KLUDGE@ GL: 				surfaces -root				    \n\
+-				xanalogtv -root				    \n\
+-				abstractile -root			    \n\
+-				anemotaxis -root			    \n\
+-- GL: 				antinspect -root			    \n\
+-				fireworkx -root				    \n\
+-				fuzzyflakes -root			    \n\
+-				interaggregate -root			    \n\
+-				intermomentary -root			    \n\
+-				memscroller -root			    \n\
+-@GL_KLUDGE@ GL: 				noof -root				    \n\
+-				pacman -root				    \n\
+-@GL_KLUDGE@ GL: 				pinion -root				    \n\
+-@GL_KLUDGE@ GL: 				polyhedra -root				    \n\
+-- GL: 				providence -root			    \n\
+-				substrate -root				    \n\
+-				wormhole -root				    \n\
+-- GL: 				antmaze -root				    \n\
+-@GL_KLUDGE@ GL: 				boing -root				    \n\
+-				boxfit -root				    \n\
+-@GL_KLUDGE@ GL: 				carousel -root				    \n\
+-				celtic -root				    \n\
+-@GL_KLUDGE@ GL: 				crackberg -root				    \n\
+-@GL_KLUDGE@ GL: 				cube21 -root				    \n\
+-				fiberlamp -root				    \n\
+-@GL_KLUDGE@ GL: 				fliptext -root				    \n\
+-@GL_KLUDGE@ GL: 				glhanoi -root				    \n\
+-@GL_KLUDGE@ GL: 				tangram -root				    \n\
+-@GL_KLUDGE@ GL: 				timetunnel -root			    \n\
+-@GL_KLUDGE@ GL: 				glschool -root				    \n\
+-@GL_KLUDGE@ GL: 				topblock -root				    \n\
+-@GL_KLUDGE@ GL: 				cubicgrid -root				    \n\
+-				cwaves -root				    \n\
+-@GL_KLUDGE@ GL: 				gears -root				    \n\
+-@GL_KLUDGE@ GL: 				glcells -root				    \n\
+-@GL_KLUDGE@ GL: 				lockward -root				    \n\
+-				m6502 -root				    \n\
+-@GL_KLUDGE@ GL: 				moebiusgears -root			    \n\
+-@GL_KLUDGE@ GL: 				voronoi -root				    \n\
+-@GL_KLUDGE@ GL: 				hypnowheel -root			    \n\
+-@GL_KLUDGE@ GL: 				klein -root				    \n\
+--				lcdscrub -root				    \n\
+-@GL_KLUDGE@ GL: 				photopile -root				    \n\
+-@GL_KLUDGE@ GL: 				skytentacles -root			    \n\
+-@GL_KLUDGE@ GL: 				rubikblocks -root			    \n\
+-@GL_KLUDGE@ GL: 				companioncube -root			    \n\
+-@GL_KLUDGE@ GL: 				hilbert -root				    \n\
+-@GL_KLUDGE@ GL: 				tronbit -root				    \n\
+-@GL_KLUDGE@ GL: 				geodesic -root				    \n\
+-				hexadrop -root				    \n\
+-@GL_KLUDGE@ GL: 				kaleidocycle -root			    \n\
+-@GL_KLUDGE@ GL: 				quasicrystal -root			    \n\
+-@GL_KLUDGE@ GL: 				unknownpleasures -root			    \n\
+-				binaryring -root			    \n\
+-@GL_KLUDGE@ GL: 				cityflow -root				    \n\
+-@GL_KLUDGE@ GL: 				geodesicgears -root			    \n\
+-@GL_KLUDGE@ GL: 				projectiveplane -root			    \n\
+-@GL_KLUDGE@ GL: 				romanboy -root				    \n\
+-				tessellimage -root			    \n\
+-@GL_KLUDGE@ GL: 				winduprobot -root			    \n\
+-@GL_KLUDGE@ GL: 				splitflap -root				    \n\
+-@GL_KLUDGE@ GL: 				cubestack -root				    \n\
+-@GL_KLUDGE@ GL: 				cubetwist -root				    \n\
+-@GL_KLUDGE@ GL: 				discoball -root				    \n\
+-@GL_KLUDGE@ GL: 				dymaxionmap -root			    \n\
+-@GL_KLUDGE@ GL: 				energystream -root			    \n\
+-@GL_KLUDGE@ GL: 				hexstrut -root				    \n\
+-@GL_KLUDGE@ GL: 				hydrostat -root				    \n\
+-@GL_KLUDGE@ GL: 				raverhoop -root				    \n\
+-@GL_KLUDGE@ GL: 				splodesic -root				    \n\
+-@GL_KLUDGE@ GL: 				unicrud -root				    \n\
+-@GL_KLUDGE@ GL: 				esper -root				    \n\
+-@GL_KLUDGE@ GL: 				vigilance -root				    \n\
+-@GL_KLUDGE@ GL: 				crumbler -root				    \n\
+-@GL_KLUDGE@ GL: 				maze3d -root				    \n\
+-@GL_KLUDGE@ GL: 				peepers -root				    \n\
+-@GL_KLUDGE@ GL: 				razzledazzle -root			    \n
+-
++-				fontglide -root -program "date +'%F %H:%M %z'"				    \n\
++				gifview --window $XSCREENSAVER_WINDOW /usr/share/logo/bosch-black.gif			    \n
+ 
+ 
+ !=============================================================================
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xscreensaver/files/xscreensaver.service b/meta-openembedded/meta-oe/recipes-graphics/xscreensaver/files/xscreensaver.service
new file mode 100755
index 0000000..17dfe75
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/xscreensaver/files/xscreensaver.service
@@ -0,0 +1,14 @@
+[Unit]
+Description=Xscreensaver service
+PartOf=xserver-nodm.service
+After=xserver-nodm.service
+
+[Service]
+ExecStart=/usr/bin/xscreensaver
+Environment="DISPLAY=:0"
+User=xuser
+Restart=always
+RestartSec=1
+
+[Install]
+WantedBy=multi-user.target
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xscreensaver/xscreensaver_5.39.bb b/meta-openembedded/meta-oe/recipes-graphics/xscreensaver/xscreensaver_5.39.bb
new file mode 100644
index 0000000..6ebf3c7
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-graphics/xscreensaver/xscreensaver_5.39.bb
@@ -0,0 +1,29 @@
+SUMMARY = "X screen saver and locker"
+
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://driver/xscreensaver.h;endline=10;md5=e141ab5822fb2d43694e1e47b59fc0df"
+
+SRC_URI = "https://www.jwz.org/${BPN}/${BP}.tar.gz"
+SRC_URI[md5sum] = "a5da62b91271f4e8afcc73d44697364b"
+SRC_URI[sha256sum] = "48ce1880f18b5321182be0c033aeceb5ec5628a1505b9d1ff69dbf06093c2426"
+
+SRC_URI += " \
+    file://xscreensaver.service \
+    file://fix-buildscripts.patch \
+    file://tweak-app-defaults.patch \
+"
+
+DEPENDS = "intltool-native libx11 libxext libxt libxft glib-2.0-native bc-native"
+# These are only needed as part of the stopgap screensaver implementation:
+RDEPENDS_${PN} += "xserver-nodm-init liberation-fonts"
+
+inherit systemd perlnative pkgconfig gettext autotools-brokensep distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+do_install_append() {
+    install -D ${WORKDIR}/xscreensaver.service ${D}${systemd_unitdir}/system/xscreensaver.service
+}
+
+FILES_${PN} += "${datadir}/X11/app-defaults/XScreenSaver"
+SYSTEMD_SERVICE_${PN} = "xscreensaver.service"
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xtscal/xtscal/30xTs_Calibrate.sh b/meta-openembedded/meta-oe/recipes-graphics/xtscal/xtscal/30xTs_Calibrate.sh
deleted file mode 100644
index fa43617..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/xtscal/xtscal/30xTs_Calibrate.sh
+++ /dev/null
@@ -1,13 +0,0 @@
-#!/bin/sh
-
-. /etc/formfactor/config
-
-if [ "$HAVE_TOUCHSCREEN" = "1" ]; then
-	n=1
-	while [ ! -z $TSLIB_TSDEVICE ] && [ ! -f /etc/pointercal ] && [ $n -le 5 ]
-	do
-	   /usr/bin/xtscal
-	   sleep 1
-	   n=$(($n+1))
-	done
-fi
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xtscal/xtscal/change-cross.patch b/meta-openembedded/meta-oe/recipes-graphics/xtscal/xtscal/change-cross.patch
deleted file mode 100644
index 1da7717..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/xtscal/xtscal/change-cross.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-Upstream-Status: Pending
-
---- tmp/main.c.orig	2007-01-02 15:39:54.000000000 +0000
-+++ tmp/main.c	2007-01-02 15:39:54.000000000 +0000
-@@ -131,9 +131,10 @@
- {
-   XRenderFillRectangles (dpy, PictOpSrc, pict, &rect_color, rectangles, 2);
- 
--  XFillArc (dpy, crosshair_w, crosshair_gc, (CROSSHAIR_SIZE / 2) - (WIDTH / 2) - 1, 
--	    (CROSSHAIR_SIZE / 2) - (WIDTH / 2) - 1,
--	    WIDTH + 1, WIDTH + 1, 0, 360 * 64);
-+  XFillRectangle (dpy, crosshair_w, crosshair_gc,
-+		  (CROSSHAIR_SIZE / 2) - (WIDTH / 2),
-+		  (CROSSHAIR_SIZE / 2) - (WIDTH / 2),
-+		  WIDTH, WIDTH);
- }
- 
- void
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xtscal/xtscal/cleanup.patch b/meta-openembedded/meta-oe/recipes-graphics/xtscal/xtscal/cleanup.patch
deleted file mode 100644
index f7b0854..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/xtscal/xtscal/cleanup.patch
+++ /dev/null
@@ -1,621 +0,0 @@
----
- Makefile.am  |    9 --
- configure.ac |    3 
- gpe-dist.am  |   12 ---
- h3600_ts.h   |  216 -----------------------------------------------------------
- main.c       |  210 ++-------------------------------------------------------
- xtscal.in    |   19 -----
- 6 files changed, 14 insertions(+), 455 deletions(-)
-
-Upstream-Status: Pending
-
-Index: xtscal-0.6.3/xtscal.in
-===================================================================
---- xtscal-0.6.3.orig/xtscal.in	2004-09-10 20:10:36.000000000 +0100
-+++ /dev/null	1970-01-01 00:00:00.000000000 +0000
-@@ -1,19 +0,0 @@
--#!/bin/sh
--
--module_id() {
--    # Get model name
--    echo `grep "^Hardware" /proc/cpuinfo | sed -e "s/.*: *//" | tr a-z A-Z`
--}
--
--case `module_id` in
--	"HP IPAQ H3100" | "HP IPAQ H3800" )
--		ARGS="-rotate 90" ;;
--	"HP IPAQ H3600" | "HP IPAQ H3700" | "HP IPAQ H3900" | *COLLIE | *POODLE)
--		ARGS="-rotate 270" ;;
--	# H2200: works without rotation
--esac
--
--# the things we do for autoconf
--prefix=@prefix@
--exec_prefix=@exec_prefix@
--exec @libexecdir@/xtscal.bin $ARGS $*
-Index: xtscal-0.6.3/main.c
-===================================================================
---- xtscal-0.6.3.orig/main.c	2007-07-01 01:12:52.000000000 +0100
-+++ xtscal-0.6.3/main.c	2007-07-01 01:12:55.000000000 +0100
-@@ -22,12 +22,10 @@
- #include <X11/Xlib.h>
- 
- #include <X11/extensions/Xrender.h>
--#include <X11/extensions/Xrandr.h>
- #include <X11/Xft/Xft.h>
- #include <X11/extensions/xcalibrate.h>
- #include <X11/keysym.h>
- 
--#include "h3600_ts.h"
- #include "calibrate.h"
- 
- Display *dpy;
-@@ -45,15 +43,11 @@ XftColor xftcol;
- XftDraw *xftdraw;
- XftFont *xftfont;
- int screen_x, screen_y;
--int ts_fd;
- int samples;
- Pixmap bg_pixmap;
- int flag_debug;
--int rotation = 0;
- int error_base, event_base;
- 
--int using_xcalibrate;
--
- int moving;
- 
- #define CROSSHAIR_SIZE	25
-@@ -63,7 +57,6 @@ int moving;
- #define ENOUGH 5
- #define MAX_SAMPLES 40
- 
--#define RAW_DEVICE "/dev/h3600_tsraw"
- #define FONTNAME "sans-10"
- 
- struct point 
-@@ -287,12 +280,8 @@ sort_by_y (const void* a, const void *b)
- void
- set_calibration (calibration *cal)
- {
--  TS_CAL tc;
--  int xtrans, ytrans, xscale, yscale, xyscale, yxscale;
-   calibration ocal = *cal;
- 
--  if (using_xcalibrate)
--    {
-       FILE *fp;
-       if (flag_debug)
- 	printf ("constants are: %d %d %d %d %d %d %d\n", cal->a[1], cal->a[2], cal->a[0], cal->a[4], cal->a[5], cal->a[3], cal->a[6]);
-@@ -304,29 +293,6 @@ set_calibration (calibration *cal)
- 	}
-       fprintf (fp, "%d %d %d %d %d %d %d\n", cal->a[1], cal->a[2], cal->a[0], cal->a[4], cal->a[5], cal->a[3], cal->a[6]);
-       fclose (fp); 
--      return;
--    }
--
--  xtrans = cal->a[0] / cal->a[6];
--  ytrans = cal->a[3] / cal->a[6];
--  xscale = cal->a[1] * 256 / cal->a[6];
--  yscale = cal->a[5] * 256 / cal->a[6];
--  xyscale = cal->a[2] * 256 / cal->a[6];
--  yxscale = cal->a[4] * 256 / cal->a[6];
--  
--  tc.xtrans = xtrans;
--  tc.ytrans = ytrans;
--  tc.xscale = xscale;
--  tc.yscale = yscale;
--  tc.xyswap = 0;
--
--  printf ("%d %d %d %d %d\n", tc.xscale, tc.xtrans, tc.yscale, tc.ytrans, tc.xyswap);
--
--  if (ioctl (ts_fd, TS_SET_CAL, (void *)&tc) != 0)
--    {
--      perror ("TS_SET_CAL");
--      exit (1);
--    }
- }
- 
- void
-@@ -398,80 +364,13 @@ handle_ts_event (int x, int y, int press
- }
- 
- void
--read_ts (void)
--{
--  TS_EVENT ts_ev;
--  int r;
--
--  r = read (ts_fd, &ts_ev, sizeof (ts_ev));
--  if (r == sizeof (ts_ev))
--    handle_ts_event (ts_ev.x, ts_ev.y, ts_ev.pressure);
--}
--
--void
--do_cal (char **args)
--{
--  TS_CAL tc;
--
--  tc.xscale = atoi (args[0]);
--  tc.xtrans = atoi (args[1]);
--  tc.yscale = atoi (args[2]);
--  tc.ytrans = atoi (args[3]);
--  tc.xyswap = atoi (args[4]);
--
--  if (flag_debug)
--    fprintf (stderr, "setting: %d %d %d %d %d\n", 
--	     tc.xtrans, tc.ytrans, tc.xscale, tc.yscale, tc.xyswap);
--    
--  if (ioctl (ts_fd, TS_SET_CAL, (void *)&tc) != 0)
--    {
--      perror ("TS_SET_CAL");
--      exit (1);
--    }
--  
--  exit (0);
--}
--
--void
--show_cal (void)
--{
--  TS_CAL tc;
--
--  if (ioctl (ts_fd, TS_GET_CAL, (void *)&tc) != 0)
--    {
--      perror ("TS_GET_CAL");
--      exit (1);
--    }
--
--  printf ("%d %d %d %d %d\n", tc.xscale, tc.xtrans, tc.yscale, tc.ytrans, tc.xyswap);
--}
--
--void
- usage (const char *name)
- {
--  fprintf (stderr, "usage: %s -view\n", name);
--  fprintf (stderr, "       %s [-rotate <0 | 90 | 180 | 270>]\n", name);
--  fprintf (stderr, "       %s -cal <xs> <xt> <ys> <yt> <xyswap>\n", name);
--
-+  fprintf (stderr, "usage: %s [-debug]\n", name);
-   exit (1);
- }
- 
- int
--xrr_supported (void)
--{
--  int xrr_event_base, xrr_error_base;
--  int xrr_major, xrr_minor;
--
--  if (XRRQueryExtension (dpy, &xrr_event_base, &xrr_error_base) == False
--      || XRRQueryVersion (dpy, &xrr_major, &xrr_minor) == 0
--      || xrr_major != 1
--      || xrr_minor < 1)
--    return 0;
--
--  return 1;
--}
--
--int
- main (int argc, char *argv[])
- {
-   XSetWindowAttributes attributes;
-@@ -480,31 +379,11 @@ main (int argc, char *argv[])
-   int max_fd;
-   GC bg_gc;
-   int i;
--  int have_xrandr;
- 
-   for (i = 1; i < argc; i++)
-     {
--      if (!strcmp (argv[i], "-view"))
--	{
--	  show_cal ();
--	  exit (0);
--	}
--      else if (!strcmp (argv[i], "-debug"))
-+      if (!strcmp (argv[i], "-debug"))
- 	flag_debug = 1;
--      else if (!strcmp (argv[i], "-cal"))
--	{
--	  if (argc > (i + 5))
--	    do_cal (argv + i + 1);
--	  else
--	    usage (argv[0]);
--	}
--      else if (!strcmp (argv[i], "-rotate"))
--	{
--	  if (argc > (i + 1))
--	    rotation = atoi (argv[++i]);
--	  else
--	    usage (argv[0]);
--	}
-       else
- 	usage (argv[0]);
-     }
-@@ -531,48 +410,11 @@ main (int argc, char *argv[])
- 	  fprintf (stderr, "failed to set raw mode: error %d\n", r);
- 	  exit (1);
- 	}
--
--      using_xcalibrate = 1;
--    }
--
--  have_xrandr = xrr_supported ();
--  if (have_xrandr)
--    {
--      XRRScreenConfiguration *rr_screen;
--      Rotation current_rotation;
--
--      if (flag_debug)
--	fprintf (stderr, "XRANDR is supported\n");
--
--      rr_screen = XRRGetScreenInfo (dpy, RootWindow (dpy, screen));
--
--      XRRRotations (dpy, screen, &current_rotation);
--
--      XRRFreeScreenConfigInfo (rr_screen);
--
--      if (flag_debug)
--	fprintf (stderr, "Current RANDR rotation is %d\n", current_rotation);
--
--      switch (current_rotation)
--	{
--	case RR_Rotate_270:
--	  rotation += 90;
--	case RR_Rotate_180:
--	  rotation += 90;
--	case RR_Rotate_90:
--	  rotation += 90;
--	  rotation %= 360;
--	case RR_Rotate_0:
--	  break;
--	default:
--	  fprintf (stderr, "Unknown RANDR rotation: %d\n", current_rotation);
--	  break;
--	}
-     }
-   else
-     {
--      if (flag_debug)
--	fprintf (stderr, "XRANDR not supported\n");
-+      perror ("XCALIBRATE extension missing");
-+      exit (1);
-     }
- 
-   attributes.override_redirect = flag_debug ? False : True;
-@@ -666,45 +508,17 @@ main (int argc, char *argv[])
- 
-   for (i = 0; i < NR_POINTS; i++)
-     {
--      switch (rotation)
--	{
--	case 0:
--	  cal.xfb[i] = cal.xscr[i];
--	  cal.yfb[i] = cal.yscr[i];
--	  break;
--	case 90:
--	  cal.xfb[i] = cal.yscr[i];
--	  cal.yfb[i] = screen_x - cal.xscr[i];
--	  break;
--	case 180:
--	  cal.xfb[i] = screen_x - cal.xscr[i];
--	  cal.yfb[i] = screen_y - cal.yscr[i];
--	  break;
--	case 270:
--	  cal.xfb[i] = screen_y - cal.yscr[i];
--	  cal.yfb[i] = cal.xscr[i];
--	  break;
--	}
-+      cal.xfb[i] = cal.xscr[i];
-+      cal.yfb[i] = cal.yscr[i];
-+      XCalibrateScreenToCoord (dpy, &cal.xfb[i], &cal.yfb[i]);
- 
-       if (flag_debug)
--	printf ("rotation %d: (%d,%d) -> (%d,%d)\n", rotation, 
-+	printf ("rotation conversion: (%d,%d) -> (%d,%d)\n",
- 		cal.xscr[i], cal.yscr[i], cal.xfb[i], cal.yfb[i]);
-     }
- 
-   next_event ();
- 
--  if (!using_xcalibrate)
--    {
--      ts_fd = open (RAW_DEVICE, O_RDONLY);
--      if (ts_fd < 0)
--	{
--	  perror (RAW_DEVICE);
--	  exit (1);
--	}
--    }
--
--  max_fd = (xfd > ts_fd) ? xfd : ts_fd;
--
-   for (;;)
-     {
-       fd_set fds;
-@@ -713,12 +527,8 @@ main (int argc, char *argv[])
- 
-       FD_ZERO (&fds);
-       FD_SET (xfd, &fds);
--      if (ts_fd != -1)
--	FD_SET (ts_fd, &fds);
- 
--      select (max_fd + 1, &fds, NULL, NULL, NULL);
--      
--      if (ts_fd != -1 && FD_ISSET (ts_fd, &fds))
--	read_ts ();
-+      select (xfd + 1, &fds, NULL, NULL, NULL);
-     }
- }
-+
-Index: xtscal-0.6.3/configure.ac
-===================================================================
---- xtscal-0.6.3.orig/configure.ac	2004-09-10 20:11:12.000000000 +0100
-+++ xtscal-0.6.3/configure.ac	2007-07-01 01:12:55.000000000 +0100
-@@ -9,8 +9,7 @@ AM_INIT_AUTOMAKE([foreign dist-bzip2])
- # Checks for programs.
- AC_PROG_CC
- 
--PKG_CHECK_MODULES(XTSCAL, x11 xft xext xrandr xcalibrate)
-+PKG_CHECK_MODULES(XTSCAL, x11 xft xext xcalibrate)
- 
- AC_CONFIG_FILES([Makefile])
--AC_CONFIG_FILES([xtscal])
- AC_OUTPUT
-Index: xtscal-0.6.3/gpe-dist.am
-===================================================================
---- xtscal-0.6.3.orig/gpe-dist.am	2004-06-02 23:07:13.000000000 +0100
-+++ /dev/null	1970-01-01 00:00:00.000000000 +0000
-@@ -1,12 +0,0 @@
--CVSTAG := $(shell echo $(PACKAGE)-$(VERSION) | tr [a-z.] [A-Z_])
--
--dist-upload: dist
--	scp $(PACKAGE)-$(VERSION).tar.bz2 $(USER)@handhelds.org:/home/ftp/pub/projects/gpe/source/
--
--tag:
--	cvs tag $(CVSTAG)
--
--retag:
--	cvs tag -F $(CVSTAG)
--
--source: tag dist-upload
-Index: xtscal-0.6.3/h3600_ts.h
-===================================================================
---- xtscal-0.6.3.orig/h3600_ts.h	2003-07-05 17:27:10.000000000 +0100
-+++ /dev/null	1970-01-01 00:00:00.000000000 +0000
-@@ -1,216 +0,0 @@
--/*
--*
--* Driver for the H3600 Touch Screen and other Atmel controlled devices.
--*
--* Copyright 2000 Compaq Computer Corporation.
--*
--* Use consistent with the GNU GPL is permitted,
--* provided that this copyright notice is
--* preserved in its entirety in all copies and derived works.
--*
--* COMPAQ COMPUTER CORPORATION MAKES NO WARRANTIES, EXPRESSED OR IMPLIED,
--* AS TO THE USEFULNESS OR CORRECTNESS OF THIS CODE OR ITS
--* FITNESS FOR ANY PARTICULAR PURPOSE.
--*
--* Author: Charles Flynn.
--*
--*/
--
--
--#ifndef __H3600_TS_H__
--#define __H3600_TS_H__
--
--#include <linux/ioctl.h>
--
--enum h3600_ts_minor_devices {
--	TS_MINOR    = 0,
--	TSRAW_MINOR = 1,
--	KEY_MINOR   = 2
--};
--
--typedef struct h3600_ts_calibration {
--        int xscale;
--        int xtrans;
--        int yscale;
--        int ytrans;
--        int xyswap;
--} TS_CAL;
--
--typedef struct h3600_ts_event {
--        unsigned short pressure;
--        unsigned short x;
--        unsigned short y;
--        unsigned short pad;
--} TS_EVENT;
--
--/* Deprecated - do not use */
--typedef struct h3600_ts_return {
--        unsigned short pressure;
--        unsigned short x;
--        unsigned short y;
--        unsigned short pad;
--} TS_RET;
--
--enum power_button_mode {
--   PBM_SUSPEND           = 0,
--   PBM_GENERATE_KEYPRESS = 1
--};
--
--
--/* ++++++++++++++ +++++++++++++++++++++++++++++++++++++ */
--
--typedef struct therm_dev {
--	short data;
--} THERM_DEV;
--
--#define H3600_BATT_CHEM_ALKALINE        0x01
--#define H3600_BATT_CHEM_NICD            0x02
--#define H3600_BATT_CHEM_NIMH            0x03
--#define H3600_BATT_CHEM_LION            0x04
--#define H3600_BATT_CHEM_LIPOLY          0x05
--#define H3600_BATT_CHEM_NOT_INSTALLED   0x06
--#define H3600_BATT_CHEM_UNKNOWN         0xff
--
--/* These should match the apm_bios.h definitions */
--#define H3600_AC_STATUS_AC_OFFLINE	0x00
--#define H3600_AC_STATUS_AC_ONLINE	0x01
--#define H3600_AC_STATUS_AC_BACKUP	0x02   /* What does this mean? */
--#define H3600_AC_STATUS_AC_UNKNOWN	0xff
--
--/* These bitfields are rarely "or'd" together */
--#define H3600_BATT_STATUS_HIGH		0x01
--#define H3600_BATT_STATUS_LOW		0x02
--#define H3600_BATT_STATUS_CRITICAL	0x04
--#define H3600_BATT_STATUS_CHARGING	0x08
--#define H3600_BATT_STATUS_CHARGE_MAIN   0x10
--#define H3600_BATT_STATUS_DEAD          0x20   /* Battery will not charge */
--#define H3600_BATT_NOT_INSTALLED        0x20   /* For expansion pack batteries */
--#define H3600_BATT_STATUS_FULL          0x40   /* Battery fully charged (and connected to AC) */
--#define H3600_BATT_STATUS_NOBATT	0x80
--#define H3600_BATT_STATUS_UNKNOWN	0xff
--
--struct battery_data {
--	unsigned char  chemistry;
--	unsigned char  status;
--	unsigned short voltage;    /* Voltage for battery #0; unknown for battery #1 */
--	unsigned short percentage; /* Percentage of full charge */
--	unsigned short life;       /* Life remaining in minutes */
--};
--
--struct h3600_battery {
--        unsigned char       ac_status;
--	unsigned char       battery_count;  /* How many batteries we have */
--	struct battery_data battery[2];
--};
--
--/* -------- EEPROM and SPI Interfaces ---------------*/
--
--#define EEPROM_RD_BUFSIZ 6	/* EEPROM reads are 16 bits */
--#define EEPROM_WR_BUFSIZ 5	/* Allow room for 8bit 'addr' field in buffer*/ 
--#define SPI_RD_BUFSIZ	 16	/* SPI reads are 8 bits */
--#define SPI_WR_BUFSIZ	 7
--
--/* The EEPROM is where internal programs are stored on the Amtel.
--   You probably don't want to read or write these values */
--
--typedef struct h3600_eeprom_read_request {
--	unsigned char addr;    /* 8bit Address Offset 0-255 */
--	unsigned char len;     /* Number of 16bit words to read 0-128  */
--	unsigned short buff[EEPROM_RD_BUFSIZ];
--} EEPROM_READ;
--
--typedef struct h3600_eeprom_write_request {
--	unsigned char len;	/* used only to compute the number of bytes to send */
--	unsigned char addr;    /* 0-128  */
--	unsigned short buff[EEPROM_WR_BUFSIZ];
--} EEPROM_WRITE;
--
--/* The SPI bus connects to EEPROMs located on sleeves plugged into
--   the iPAQ.  You may want to read these values  */
--
--typedef struct h3600_spi_read_request {
--	unsigned short addr;    /* 16bit Address Offset 0-128 */
--	unsigned char len;      /* Number of bytes to read */
--	unsigned char buff[SPI_RD_BUFSIZ];
--} SPI_READ;
--
--#define SPI_READ_STATUS_BYTE  0xffff   /* Use this address to read the status byte */
--
--typedef struct h3600_spi_write_request {
--	unsigned short len;	/* used only to compute the number of bytes to send */
--	unsigned short addr;	/* this 16bit address accesses a single byte */
--	unsigned char  buff[SPI_WR_BUFSIZ];
--} SPI_WRITE;
--
--
--/* -------- end of EEPROM and SPI Interfaces ---------------*/
--
--/* User space structures for IOCTL calls */
--
--typedef struct h3600_ts_version {
--	unsigned char host_version[8];	/* ascii "x.yy" */
--	unsigned char pack_version[8];	/* ascii "x.yy" */
--	unsigned char boot_type;		/* TODO ?? */
--} VER_RET;
--
--typedef struct h3600_ts_led {
--        unsigned char OffOnBlink;       /* 0=off 1=on 2=Blink */
--        unsigned char TotalTime;        /* Units of 5 seconds */
--        unsigned char OnTime;           /* units of 100m/s */
--        unsigned char OffTime;          /* units of 100m/s */
--} LED_IN;
--
--enum flite_mode {
--        FLITE_MODE1 = 1,
--	FLITE_AUTO_MODE   = 1,     /* for reference only */
--	FLITE_MANUAL_MODE = 2,     /* Use this normally? */
--	FLITE_GET_LIGHT_SENSOR = 3 /* Returns light reading in "brightness" field */
--};
--enum flite_pwr {
--        FLITE_PWR_OFF = 0,
--        FLITE_PWR_ON  = 1
--};
--
--typedef struct h3600_ts_flite {
--        unsigned char mode;
--        unsigned char pwr;
--        unsigned char brightness;
--} FLITE_IN;
--
--/*************************** Updated "universal" structures *******************/
--
--/* Sets backlight for both H3100 and H3600 models - technically "frontlight" for H3600 */
--struct h3600_ts_backlight {
--	enum flite_pwr power;          /* 0 = off, 1 = on */
--	unsigned char  brightness;     /* 0 - 255         */
--};
--
--struct h3600_ts_contrast {            /* Only useful on H3100 model */
--	unsigned char contrast;       /* 0 - 255 */
--};
--
--/* IOCTL cmds  user or kernel space */
--
--/* Use 'f' as magic number */
--#define IOC_H3600_TS_MAGIC  'f'
--
--/* TODO: Some of these IOWR values are just plain wrong */
--#define GET_VERSION		_IOR(IOC_H3600_TS_MAGIC,  1, struct h3600_ts_version )
--#define READ_EEPROM		_IOWR(IOC_H3600_TS_MAGIC, 2, struct h3600_eeprom_read_request)
--#define WRITE_EEPROM		_IOWR(IOC_H3600_TS_MAGIC, 3, struct h3600_eeprom_write_request)
--#define GET_THERMAL		_IOR(IOC_H3600_TS_MAGIC,  4, struct therm_dev)
--#define LED_ON			_IOW(IOC_H3600_TS_MAGIC,  5, struct h3600_ts_led)
--#define GET_BATTERY_STATUS	_IOR(IOC_H3600_TS_MAGIC,  6, struct h3600_battery)
--#define FLITE_ON		_IOW(IOC_H3600_TS_MAGIC,  7, struct h3600_ts_flite)
--#define READ_SPI		_IOWR(IOC_H3600_TS_MAGIC, 8, struct h3600_spi_read_request)
--#define WRITE_SPI		_IOWR(IOC_H3600_TS_MAGIC, 9, struct h3600_spi_write_request)
--#define TS_GET_CAL		_IOR(IOC_H3600_TS_MAGIC, 10, struct h3600_ts_calibration)
--#define TS_SET_CAL		_IOW(IOC_H3600_TS_MAGIC, 11, struct h3600_ts_calibration)
--
--/* New IOCTL interfaces - defined to be more user friendly */
--#define TS_GET_BACKLIGHT        _IOR(IOC_H3600_TS_MAGIC, 20, struct h3600_ts_backlight)
--#define TS_SET_BACKLIGHT        _IOW(IOC_H3600_TS_MAGIC, 20, struct h3600_ts_backlight)
--#define TS_GET_CONTRAST         _IOR(IOC_H3600_TS_MAGIC, 21, struct h3600_ts_contrast)
--#define TS_SET_CONTRAST         _IOW(IOC_H3600_TS_MAGIC, 21, struct h3600_ts_contrast)
--
--#endif
-Index: xtscal-0.6.3/Makefile.am
-===================================================================
---- xtscal-0.6.3.orig/Makefile.am	2004-06-02 23:07:13.000000000 +0100
-+++ xtscal-0.6.3/Makefile.am	2007-07-02 12:51:02.000000000 +0100
-@@ -1,11 +1,8 @@
--libexec_PROGRAMS = xtscal.bin
--bin_SCRIPTS = xtscal
-+bin_PROGRAMS = xtscal
- 
--xtscal_bin_SOURCES = main.c calibrate.c calibrate.h h3600_ts.h
-+xtscal_SOURCES = main.c calibrate.c calibrate.h
- 
--xtscal_bin_LDADD = @XTSCAL_LIBS@
-+xtscal_LDADD = @XTSCAL_LIBS@
- 
- INCLUDES = @XTSCAL_CFLAGS@ -DNR_POINTS=5
- 
--include gpe-dist.am
--
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xtscal/xtscal/dso_linking_change_build_fix.patch b/meta-openembedded/meta-oe/recipes-graphics/xtscal/xtscal/dso_linking_change_build_fix.patch
deleted file mode 100644
index 3e4533f..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/xtscal/xtscal/dso_linking_change_build_fix.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-after gcc linking has changed, all the libraries must be explicitely specified 
-This patch avoids this linking error:
-
-| ccache i586-poky-linux-gcc -march=i586 --sysroot=/disk0/pokybuild/build1/tmp/sysroots/i586-poky-linux  -fexpensive-optimizations -fomit-frame-pointer -frename-registers -O2 -ggdb -feliminate-unused-debug-types  -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -o xtscal main.o calibrate.o -lX11 -lXft -lXext -lXcalibrate^M
-| /disk0/pokybuild/build1/tmp/sysroots/x86_64-linux/usr/libexec/i586-poky-linux/gcc/i586-poky-linux/4.5.1/ld: ^?: invalid DSO for symbol `XRenderChangePicture' definition^M
-| /disk0/pokybuild/build1/tmp/sysroots/i586-poky-linux/usr/lib/libXrender.so.1: could not read symbols: Bad value^M
-| collect2: ld returned 1 exit status^M
-| make: *** [xtscal] Error 1
-
-Nitin A Kamble <nitin.a.kamble@intel.com>
-Date: 2011/01/11
-
-Upstream-Status: Pending
-
-Index: xtscal-0.6.3/configure.ac
-===================================================================
---- xtscal-0.6.3.orig/configure.ac
-+++ xtscal-0.6.3/configure.ac
-@@ -9,7 +9,7 @@ AM_INIT_AUTOMAKE([foreign dist-bzip2])
- # Checks for programs.
- AC_PROG_CC
- 
--PKG_CHECK_MODULES(XTSCAL, x11 xft xext xcalibrate)
-+PKG_CHECK_MODULES(XTSCAL, x11 xft xext xcalibrate xrender)
- 
- AC_CONFIG_FILES([Makefile])
- AC_OUTPUT
diff --git a/meta-openembedded/meta-oe/recipes-graphics/xtscal/xtscal_0.6.3.bb b/meta-openembedded/meta-oe/recipes-graphics/xtscal/xtscal_0.6.3.bb
deleted file mode 100644
index 4bfddf0..0000000
--- a/meta-openembedded/meta-oe/recipes-graphics/xtscal/xtscal_0.6.3.bb
+++ /dev/null
@@ -1,33 +0,0 @@
-SUMMARY = "Touchscreen calibration utility"
-
-DESCRIPTION = "Basic touchscreen calibration utility"
-
-HOMEPAGE = "http://gpe.linuxtogo.org"
-BUGTRACKER = "http://bugs.linuxtogo.org"
-LICENSE = "GPLv2 & GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
-                    file://main.c;endline=10;md5=8721bcb08ae9f24e5fe4c82941873c87"
-
-SECTION = "x11/base"
-
-DEPENDS = "virtual/libx11 libxft libxcalibrate"
-
-PR = "r13"
-
-SRC_URI = "${GPE_MIRROR}/xtscal-${PV}.tar.bz2 \
-           file://change-cross.patch \
-           file://cleanup.patch \
-           file://dso_linking_change_build_fix.patch \
-           file://30xTs_Calibrate.sh"
-
-SRC_URI[md5sum] = "9bcab80b474d5454477d1ca166a68c34"
-SRC_URI[sha256sum] = "27b9dc2203de9b1706ca39fa6ca80ecab8807909ec901c4a345b8e41178800a1"
-
-inherit autotools pkgconfig distro_features_check
-# depends on virtual/libx11
-REQUIRED_DISTRO_FEATURES = "x11"
-
-do_install_append() {
-    install -d ${D}${sysconfdir}/X11/Xsession.d/
-    install -m 0755 ${WORKDIR}/30xTs_Calibrate.sh ${D}${sysconfdir}/X11/Xsession.d/
-}
diff --git a/meta-openembedded/meta-oe/recipes-kernel/bpftool/bpftool.bb b/meta-openembedded/meta-oe/recipes-kernel/bpftool/bpftool.bb
new file mode 100644
index 0000000..fd0653a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-kernel/bpftool/bpftool.bb
@@ -0,0 +1,31 @@
+SUMMARY = "Inspect and manipulate eBPF programs and maps"
+DESCRIPTION = "bpftool is a kernel tool for inspection and simple manipulation \
+of eBPF programs and maps."
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6"
+DEPENDS = "binutils elfutils"
+PROVIDES = "virtual/bpftool"
+
+inherit bash-completion kernelsrc kernel-arch
+
+do_populate_lic[depends] += "virtual/kernel:do_patch"
+
+EXTRA_OEMAKE = "-C ${S}/tools/bpf/bpftool O=${B} CROSS=${TARGET_PREFIX} CC="${CC}" LD="${LD}" AR=${AR} ARCH=${ARCH}"
+
+do_configure[depends] += "virtual/kernel:do_shared_workdir"
+
+do_compile() {
+    oe_runmake
+}
+
+do_install() {
+    oe_runmake DESTDIR=${D} install
+}
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+python do_package_prepend() {
+    d.setVar('PKGV', d.getVar("KERNEL_VERSION", True).split("-")[0])
+}
+
+B = "${WORKDIR}/${BPN}-${PV}"
diff --git a/meta-openembedded/meta-oe/recipes-kernel/broadcom-bt-firmware/broadcom-bt-firmware_git.bb b/meta-openembedded/meta-oe/recipes-kernel/broadcom-bt-firmware/broadcom-bt-firmware_git.bb
new file mode 100644
index 0000000..8c474ec
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-kernel/broadcom-bt-firmware/broadcom-bt-firmware_git.bb
@@ -0,0 +1,76 @@
+# Copyright (C) 2018 Krzysztof Kozlowski <krzk@kernel.org>
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+SUMMARY = "Broadcom Bluetooth firmware files"
+DESCRIPTION = "Firmware for Broadcom Bluetooth devices. Note that in case of BT+WiFi devices, separate WiFi firmware might be needed."
+HOMEPAGE = "https://github.com/winterheart/broadcom-bt-firmware"
+
+LICENSE = "Firmware-Broadcom-WIDCOMM"
+NO_GENERIC_LICENSE[Firmware-Broadcom-WIDCOMM] = "LICENSE.broadcom_bcm20702"
+
+LIC_FILES_CHKSUM = "file://LICENSE.broadcom_bcm20702;md5=c0d5ea0502b00df74173d0f8a48b619d"
+SRC_URI = "git://github.com/winterheart/broadcom-bt-firmware.git"
+SRCREV = "c0bd928b8ae5754b6077c99afe6ef5c949a58f32"
+PE = "1"
+PV = "0.0+git${SRCPV}"
+
+S = "${WORKDIR}/git"
+
+inherit allarch
+
+CLEANBROKEN = "1"
+
+do_compile() {
+    :
+}
+
+do_install() {
+    install -d ${D}${nonarch_base_libdir}/firmware/brcm/
+    cp brcm/*.hcd ${D}${nonarch_base_libdir}/firmware/brcm/
+
+    # For license package:
+    install -m 0644 LICENSE.broadcom_bcm20702 ${D}${nonarch_base_libdir}/firmware/brcm/
+
+    # For main package:
+    install -m 0644 DEVICES.md ${D}${nonarch_base_libdir}/firmware/brcm/
+}
+
+PACKAGES =+ " \
+    ${PN}-bcm20702a1 \
+    ${PN}-bcm20702b0 \
+    ${PN}-bcm20703a1 \
+    ${PN}-bcm43142a0 \
+    ${PN}-bcm4335c0 \
+    ${PN}-bcm4350c5 \
+    ${PN}-bcm4356a2 \
+    ${PN}-bcm4371c2 \
+    ${PN}-license \
+"
+
+RDEPENDS_${PN}-bcm20702a1 = "${PN}-license"
+RDEPENDS_${PN}-bcm20702b0 = "${PN}-license"
+RDEPENDS_${PN}-bcm20703a1 = "${PN}-license"
+RDEPENDS_${PN}-bcm43142a0 = "${PN}-license"
+RDEPENDS_${PN}-bcm4335c0 = "${PN}-license"
+RDEPENDS_${PN}-bcm4350c5 = "${PN}-license"
+RDEPENDS_${PN}-bcm4356a2 = "${PN}-license"
+RDEPENDS_${PN}-bcm4371c2 = "${PN}-license"
+
+FILES_${PN}-bcm20702a1 = "${nonarch_base_libdir}/firmware/brcm/BCM20702A1*hcd"
+FILES_${PN}-bcm20702b0 = "${nonarch_base_libdir}/firmware/brcm/BCM20702B0*hcd"
+FILES_${PN}-bcm20703a1 = "${nonarch_base_libdir}/firmware/brcm/BCM20703A1*hcd"
+FILES_${PN}-bcm43142a0 = "${nonarch_base_libdir}/firmware/brcm/BCM43142A0*hcd"
+FILES_${PN}-bcm4335c0 = "${nonarch_base_libdir}/firmware/brcm/BCM4335C0*hcd"
+FILES_${PN}-bcm4350c5 = "${nonarch_base_libdir}/firmware/brcm/BCM4350C5*hcd"
+FILES_${PN}-bcm4356a2 = "${nonarch_base_libdir}/firmware/brcm/BCM4356A2*hcd"
+FILES_${PN}-bcm4371c2 = "${nonarch_base_libdir}/firmware/brcm/BCM4371C2*hcd"
+FILES_${PN}-license += "${nonarch_base_libdir}/firmware/brcm/LICENSE.broadcom_bcm20702"
+
+FILES_${PN} += "${nonarch_base_libdir}/firmware/brcm/*"
+RDEPENDS_${PN} += "${PN}-license"
+
+# Make broadcom-bt-firmware depend on all of the split-out packages.
+python populate_packages_prepend () {
+    firmware_pkgs = oe.utils.packages_filter_out_system(d)
+    d.appendVar('RDEPENDS_broadcom-bt-firmware', ' ' + ' '.join(firmware_pkgs))
+}
diff --git a/meta-openembedded/meta-oe/recipes-kernel/cpupower/cpupower.bb b/meta-openembedded/meta-oe/recipes-kernel/cpupower/cpupower.bb
index 4abd273..4544f5b 100644
--- a/meta-openembedded/meta-oe/recipes-kernel/cpupower/cpupower.bb
+++ b/meta-openembedded/meta-oe/recipes-kernel/cpupower/cpupower.bb
@@ -2,7 +2,7 @@
 DESCRIPTION = "cpupower is a collection of tools to examine and tune power \
 saving related features of your processor."
 LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
+LIC_FILES_CHKSUM = "file://COPYING;md5=bbea815ee2795b2f4230826c0c6b8814"
 DEPENDS = "pciutils gettext-native"
 PROVIDES = "virtual/cpupower"
 
diff --git a/meta-openembedded/meta-oe/recipes-kernel/crash/crash_7.2.0.bb b/meta-openembedded/meta-oe/recipes-kernel/crash/crash_7.2.0.bb
deleted file mode 100644
index 9bea48e..0000000
--- a/meta-openembedded/meta-oe/recipes-kernel/crash/crash_7.2.0.bb
+++ /dev/null
@@ -1,115 +0,0 @@
-SUMMARY = "Kernel analysis utility for live systems, netdump, diskdump, kdump, LKCD or mcore dumpfiles"
-DESCRIPTION = "The core analysis suite is a self-contained tool that can be used to\
-investigate either live systems, kernel core dumps created from the\
-netdump, diskdump and kdump packages from Red Hat Linux, the mcore kernel patch\
-offered by Mission Critical Linux, or the LKCD kernel patch."
-
-HOMEPAGE = "http://people.redhat.com/anderson"
-SECTION = "devel"
-
-LICENSE = "GPLv3"
-LIC_FILES_CHKSUM = "file://COPYING3;md5=d32239bcb673463ab874e80d47fae504"
-
-DEPENDS = "zlib readline coreutils-native"
-
-SRC_URI = "https://github.com/crash-utility/${BPN}/archive/${PV}.tar.gz;downloadfilename=${BP}.tar.gz \
-           http://ftp.gnu.org/gnu/gdb/gdb-7.6.tar.gz;name=gdb;subdir=${BP} \
-           file://7001force_define_architecture.patch \
-           file://7003cross_ranlib.patch \
-           file://0001-cross_add_configure_option.patch \
-           file://sim-ppc-drop-LIBS-from-psim-dependency.patch \
-           file://sim-common-sim-arange-fix-extern-inline-handling.patch \
-           file://donnot-extract-gdb-during-do-compile.patch \
-           file://gdb_build_jobs_and_not_write_crash_target.patch \
-           file://remove-unrecognized-gcc-option-m32-for-mips.patch \
-           file://0002-crash-fix-build-error-unknown-type-name-gdb_fpregset.patch \
-           file://0003-crash-detect-the-sysroot-s-glibc-header-file.patch \
-           "
-SRC_URI[md5sum] = "48899de3118e04cfa40a2364f5618193"
-SRC_URI[sha256sum] = "5d076e1fefb41aa178ad3e1cef6511670efc47de5cb04d4af9bdd4e8f2f18cbc"
-
-SRC_URI[gdb.md5sum] = "a9836707337e5f7bf76a009a8904f470"
-SRC_URI[gdb.sha256sum] = "8070389a5dcc104eb0be483d582729f98ed4d761ad19cedd3f17b5d2502faa36"
-
-inherit gettext
-
-BBCLASSEXTEND = "native cross"
-TARGET_CC_ARCH_append = " ${SELECTED_OPTIMIZATION}"
-
-# crash 7.1.3 and before don't support mips64
-COMPATIBLE_HOST = "^(?!mips64).*"
-
-EXTRA_OEMAKE = 'RPMPKG="${PV}" \
-                GDB_TARGET="${TARGET_SYS}" \
-                GDB_HOST="${BUILD_SYS}" \
-                GDB_MAKE_JOBS="${PARALLEL_MAKE}" \
-                LDFLAGS="${LDFLAGS}" \
-                '
-
-EXTRA_OEMAKE_class-cross = 'RPMPKG="${PV}" \
-                            GDB_TARGET="${BUILD_SYS} \
-                                        \${GDB_CONF_FLAGS} \
-                                        --target=${TARGET_SYS}" \
-                            GDB_HOST="${BUILD_SYS}" \
-                            GDB_MAKE_JOBS="${PARALLEL_MAKE}" \
-                            '
-
-EXTRA_OEMAKE_append_class-native = " LDFLAGS='${BUILD_LDFLAGS}'"
-EXTRA_OEMAKE_append_class-cross = " LDFLAGS='${BUILD_LDFLAGS}'"
-
-REMOVE_M32 = "sed -i -e 's/#define TARGET_CFLAGS_ARM_ON_X86_64.*/#define TARGET_CFLAGS_ARM_ON_X86_64\t\"TARGET_CFLAGS=-D_FILE_OFFSET_BITS=64\"/g' ${S}/configure.c"
-
-REMOVE_M32_class-cross = ""
-
-do_configure() {
-    :
-}
-
-do_compile_prepend() {
-    case ${TARGET_ARCH} in
-        aarch64*)    ARCH=ARM64 ;;
-        arm*)        ARCH=ARM ;;
-        i*86*)       ARCH=X86 ;;
-        x86_64*)     ARCH=X86_64 ;;
-        powerpc64*)  ARCH=PPC64 ;;
-        powerpc*)    ARCH=PPC ;;
-        mips*)       ARCH=MIPS ;;
-    esac
-
-    sed -i s/FORCE_DEFINE_ARCH/"${ARCH}"/g ${S}/configure.c
-    ${REMOVE_M32}
-    sed -i 's/&gt;/>/g' ${S}/Makefile
-}
-
-do_compile() {
-    oe_runmake ${EXTRA_OEMAKE} RECIPE_SYSROOT=${RECIPE_SYSROOT}
-}
-
-do_install_prepend () {
-    install -d ${D}${bindir}
-    install -d ${D}/${mandir}/man8
-    install -d ${D}${includedir}/crash
-
-    install -m 0644 ${S}/crash.8 ${D}/${mandir}/man8/
-    install -m 0644 ${S}/defs.h ${D}${includedir}/crash
-}
-
-do_install_class-target () {
-    oe_runmake DESTDIR=${D} install
-}
-
-do_install_class-native () {
-    oe_runmake DESTDIR=${D}${STAGING_DIR_NATIVE} install
-}
-
-do_install_class-cross () {
-    install -m 0755 ${S}/crash ${D}/${bindir}
-}
-
-RDEPENDS_${PN} += "liblzma"
-RDEPENDS_${PN}_class-native = ""
-RDEPENDS_${PN}_class-cross = ""
-
-# Causes gcc to get stuck and eat all available memory in qemuarm builds
-# jenkins  15161  100 12.5 10389596 10321284 ?   R    11:40  28:17 /home/jenkins/oe/world/shr-core/tmp-glibc/sysroots/x86_64-linux/usr/libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/4.9.2/cc1 -quiet -I . -I . -I ./common -I ./config -I ./../include/opcode -I ./../opcodes/.. -I ./../readline/.. -I ../bfd -I ./../bfd -I ./../include -I ../libdecnumber -I ./../libdecnumber -I ./gnulib/import -I build-gnulib/import -isysroot /home/jenkins/oe/world/shr-core/tmp-glibc/sysroots/qemuarm -MMD eval.d -MF .deps/eval.Tpo -MP -MT eval.o -D LOCALEDIR="/usr/local/share/locale" -D CRASH_MERGE -D HAVE_CONFIG_H -D TUI=1 eval.c -quiet -dumpbase eval.c -march=armv5te -mthumb -mthumb-interwork -mtls-dialect=gnu -auxbase-strip eval.o -g -O2 -Wall -Wpointer-arith -Wformat-nonliteral -Wno-pointer-sign -Wno-unused -Wunused-value -Wunused-function -Wno-switch -Wno-char-subscripts -Wmissing-prototypes -Wdeclaration-after-statement -Wempty-body -feliminate-unused-debug-types -o -
-ARM_INSTRUCTION_SET = "arm"
diff --git a/meta-openembedded/meta-oe/recipes-kernel/crash/crash_7.2.4.bb b/meta-openembedded/meta-oe/recipes-kernel/crash/crash_7.2.4.bb
new file mode 100644
index 0000000..c72b1a3
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-kernel/crash/crash_7.2.4.bb
@@ -0,0 +1,120 @@
+SUMMARY = "Kernel analysis utility for live systems, netdump, diskdump, kdump, LKCD or mcore dumpfiles"
+DESCRIPTION = "The core analysis suite is a self-contained tool that can be used to\
+investigate either live systems, kernel core dumps created from the\
+netdump, diskdump and kdump packages from Red Hat Linux, the mcore kernel patch\
+offered by Mission Critical Linux, or the LKCD kernel patch."
+
+HOMEPAGE = "http://people.redhat.com/anderson"
+SECTION = "devel"
+
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://COPYING3;md5=d32239bcb673463ab874e80d47fae504"
+
+DEPENDS = "zlib readline coreutils-native"
+
+SRC_URI = "https://github.com/crash-utility/${BPN}/archive/${PV}.tar.gz;downloadfilename=${BP}.tar.gz \
+           http://ftp.gnu.org/gnu/gdb/gdb-7.6.tar.gz;name=gdb;subdir=${BP} \
+           file://7001force_define_architecture.patch \
+           file://7003cross_ranlib.patch \
+           file://0001-cross_add_configure_option.patch \
+           file://sim-ppc-drop-LIBS-from-psim-dependency.patch \
+           file://sim-common-sim-arange-fix-extern-inline-handling.patch \
+           file://donnot-extract-gdb-during-do-compile.patch \
+           file://gdb_build_jobs_and_not_write_crash_target.patch \
+           file://remove-unrecognized-gcc-option-m32-for-mips.patch \
+           file://0002-crash-fix-build-error-unknown-type-name-gdb_fpregset.patch \
+           file://0003-crash-detect-the-sysroot-s-glibc-header-file.patch \
+           "
+SRC_URI[md5sum] = "4f66eb0e9a82ff83de06ac2b37501f5c"
+SRC_URI[sha256sum] = "85ca2e93f1ee628ef2499ab9c78623f8b04500bdf7378c09de19283f6a7a698f"
+
+SRC_URI[gdb.md5sum] = "a9836707337e5f7bf76a009a8904f470"
+SRC_URI[gdb.sha256sum] = "8070389a5dcc104eb0be483d582729f98ed4d761ad19cedd3f17b5d2502faa36"
+
+UPSTREAM_CHECK_URI = "https://github.com/crash-utility/crash/releases"
+
+inherit gettext
+
+BBCLASSEXTEND = "native cross"
+TARGET_CC_ARCH_append = " ${SELECTED_OPTIMIZATION}"
+
+# crash 7.1.3 and before don't support mips64
+COMPATIBLE_HOST = "^(?!mips64).*"
+
+EXTRA_OEMAKE = 'RPMPKG="${PV}" \
+                GDB_TARGET="${TARGET_SYS}" \
+                GDB_HOST="${BUILD_SYS}" \
+                GDB_MAKE_JOBS="${PARALLEL_MAKE}" \
+                LDFLAGS="${LDFLAGS}" \
+                '
+
+EXTRA_OEMAKE_class-cross = 'RPMPKG="${PV}" \
+                            GDB_TARGET="${BUILD_SYS} \
+                                        \${GDB_CONF_FLAGS} \
+                                        --target=${TARGET_SYS}" \
+                            GDB_HOST="${BUILD_SYS}" \
+                            GDB_MAKE_JOBS="${PARALLEL_MAKE}" \
+                            '
+
+EXTRA_OEMAKE_append_class-native = " LDFLAGS='${BUILD_LDFLAGS}'"
+EXTRA_OEMAKE_append_class-cross = " LDFLAGS='${BUILD_LDFLAGS}'"
+
+REMOVE_M32 = "sed -i -e 's/#define TARGET_CFLAGS_ARM_ON_X86_64.*/#define TARGET_CFLAGS_ARM_ON_X86_64\t\"TARGET_CFLAGS=-D_FILE_OFFSET_BITS=64\"/g' ${S}/configure.c"
+
+REMOVE_M32_class-cross = ""
+
+do_configure() {
+    :
+}
+
+do_compile_prepend() {
+    case ${TARGET_ARCH} in
+        aarch64*)    ARCH=ARM64 ;;
+        arm*)        ARCH=ARM ;;
+        i*86*)       ARCH=X86 ;;
+        x86_64*)     ARCH=X86_64 ;;
+        powerpc64*)  ARCH=PPC64 ;;
+        powerpc*)    ARCH=PPC ;;
+        mips*)       ARCH=MIPS ;;
+    esac
+
+    sed -i s/FORCE_DEFINE_ARCH/"${ARCH}"/g ${S}/configure.c
+    ${REMOVE_M32}
+    sed -i 's/&gt;/>/g' ${S}/Makefile
+}
+
+do_compile() {
+    oe_runmake ${EXTRA_OEMAKE} RECIPE_SYSROOT=${RECIPE_SYSROOT}
+}
+
+do_install_prepend () {
+    install -d ${D}${bindir}
+    install -d ${D}/${mandir}/man8
+    install -d ${D}${includedir}/crash
+
+    install -m 0644 ${S}/crash.8 ${D}/${mandir}/man8/
+    install -m 0644 ${S}/defs.h ${D}${includedir}/crash
+}
+
+do_install_class-target () {
+    oe_runmake DESTDIR=${D} install
+}
+
+do_install_class-native () {
+    oe_runmake DESTDIR=${D}${STAGING_DIR_NATIVE} install
+}
+
+do_install_class-cross () {
+    install -m 0755 ${S}/crash ${D}/${bindir}
+}
+
+RDEPENDS_${PN} += "liblzma"
+RDEPENDS_${PN}_class-native = ""
+RDEPENDS_${PN}_class-cross = ""
+
+# Causes gcc to get stuck and eat all available memory in qemuarm builds
+# jenkins  15161  100 12.5 10389596 10321284 ?   R    11:40  28:17 /home/jenkins/oe/world/shr-core/tmp-glibc/sysroots/x86_64-linux/usr/libexec/arm-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/4.9.2/cc1 -quiet -I . -I . -I ./common -I ./config -I ./../include/opcode -I ./../opcodes/.. -I ./../readline/.. -I ../bfd -I ./../bfd -I ./../include -I ../libdecnumber -I ./../libdecnumber -I ./gnulib/import -I build-gnulib/import -isysroot /home/jenkins/oe/world/shr-core/tmp-glibc/sysroots/qemuarm -MMD eval.d -MF .deps/eval.Tpo -MP -MT eval.o -D LOCALEDIR="/usr/local/share/locale" -D CRASH_MERGE -D HAVE_CONFIG_H -D TUI=1 eval.c -quiet -dumpbase eval.c -march=armv5te -mthumb -mthumb-interwork -mtls-dialect=gnu -auxbase-strip eval.o -g -O2 -Wall -Wpointer-arith -Wformat-nonliteral -Wno-pointer-sign -Wno-unused -Wunused-value -Wunused-function -Wno-switch -Wno-char-subscripts -Wmissing-prototypes -Wdeclaration-after-statement -Wempty-body -feliminate-unused-debug-types -o -
+ARM_INSTRUCTION_SET = "arm"
+
+# http://errors.yoctoproject.org/Errors/Details/186964/
+EXCLUDE_FROM_WORLD_libc-musl = "1"
diff --git a/meta-openembedded/meta-oe/recipes-kernel/ipmitool/ipmitool/0001-Migrate-to-openssl-1.1.patch b/meta-openembedded/meta-oe/recipes-kernel/ipmitool/ipmitool/0001-Migrate-to-openssl-1.1.patch
new file mode 100644
index 0000000..394aa16
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-kernel/ipmitool/ipmitool/0001-Migrate-to-openssl-1.1.patch
@@ -0,0 +1,152 @@
+From c9dcb6afef9c343d070aaff208d11a997a45a105 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 5 Sep 2018 22:19:38 -0700
+Subject: [PATCH] Migrate to openssl 1.1
+
+Upstream-Status: Backport [https://sourceforge.net/p/ipmitool/source/ci/1664902525a1c3771b4d8b3ccab7ea1ba6b2bdd1/]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/plugins/lanplus/lanplus_crypt_impl.c | 50 ++++++++++++++----------
+ 1 file changed, 29 insertions(+), 21 deletions(-)
+
+diff --git a/src/plugins/lanplus/lanplus_crypt_impl.c b/src/plugins/lanplus/lanplus_crypt_impl.c
+index d5fac37..9652a5e 100644
+--- a/src/plugins/lanplus/lanplus_crypt_impl.c
++++ b/src/plugins/lanplus/lanplus_crypt_impl.c
+@@ -164,11 +164,7 @@ lanplus_encrypt_aes_cbc_128(const uint8_t * iv,
+ 							uint8_t       * output,
+ 							uint32_t        * bytes_written)
+ {
+-	EVP_CIPHER_CTX ctx;
+-	EVP_CIPHER_CTX_init(&ctx);
+-	EVP_EncryptInit_ex(&ctx, EVP_aes_128_cbc(), NULL, key, iv);
+-	EVP_CIPHER_CTX_set_padding(&ctx, 0);
+-	
++	EVP_CIPHER_CTX *ctx = NULL;
+ 
+ 	*bytes_written = 0;
+ 
+@@ -182,6 +178,14 @@ lanplus_encrypt_aes_cbc_128(const uint8_t * iv,
+ 		printbuf(input, input_length, "encrypting this data");
+ 	}
+ 
++	ctx = EVP_CIPHER_CTX_new();
++	if (ctx == NULL) {
++		lprintf(LOG_DEBUG, "ERROR: EVP_CIPHER_CTX_new() failed");
++		return;
++	}
++	EVP_CIPHER_CTX_init(ctx);
++	EVP_EncryptInit_ex(ctx, EVP_aes_128_cbc(), NULL, key, iv);
++	EVP_CIPHER_CTX_set_padding(ctx, 0);
+ 
+ 	/*
+ 	 * The default implementation adds a whole block of padding if the input
+@@ -191,28 +195,28 @@ lanplus_encrypt_aes_cbc_128(const uint8_t * iv,
+ 	assert((input_length % IPMI_CRYPT_AES_CBC_128_BLOCK_SIZE) == 0);
+ 
+ 
+-	if(!EVP_EncryptUpdate(&ctx, output, (int *)bytes_written, input, input_length))
++	if(!EVP_EncryptUpdate(ctx, output, (int *)bytes_written, input, input_length))
+ 	{
+ 		/* Error */
+ 		*bytes_written = 0;
+-		return;
+ 	}
+ 	else
+ 	{
+ 		uint32_t tmplen;
+ 
+-		if(!EVP_EncryptFinal_ex(&ctx, output + *bytes_written, (int *)&tmplen))
++		if(!EVP_EncryptFinal_ex(ctx, output + *bytes_written, (int *)&tmplen))
+ 		{
++			/* Error */
+ 			*bytes_written = 0;
+-			return; /* Error */
+ 		}
+ 		else
+ 		{
+ 			/* Success */
+ 			*bytes_written += tmplen;
+-			EVP_CIPHER_CTX_cleanup(&ctx);
+ 		}
+ 	}
++	/* performs cleanup and free */
++	EVP_CIPHER_CTX_free(ctx);
+ }
+ 
+ 
+@@ -239,11 +243,7 @@ lanplus_decrypt_aes_cbc_128(const uint8_t * iv,
+ 							uint8_t       * output,
+ 							uint32_t        * bytes_written)
+ {
+-	EVP_CIPHER_CTX ctx;
+-	EVP_CIPHER_CTX_init(&ctx);
+-	EVP_DecryptInit_ex(&ctx, EVP_aes_128_cbc(), NULL, key, iv);
+-	EVP_CIPHER_CTX_set_padding(&ctx, 0);
+-
++	EVP_CIPHER_CTX *ctx = NULL;
+ 
+ 	if (verbose >= 5)
+ 	{
+@@ -252,12 +252,20 @@ lanplus_decrypt_aes_cbc_128(const uint8_t * iv,
+ 		printbuf(input, input_length, "decrypting this data");
+ 	}
+ 
+-
+ 	*bytes_written = 0;
+ 
+ 	if (input_length == 0)
+ 		return;
+ 
++	ctx = EVP_CIPHER_CTX_new();
++	if (ctx == NULL) {
++		lprintf(LOG_DEBUG, "ERROR: EVP_CIPHER_CTX_new() failed");
++		return;
++	}
++	EVP_CIPHER_CTX_init(ctx);
++	EVP_DecryptInit_ex(ctx, EVP_aes_128_cbc(), NULL, key, iv);
++	EVP_CIPHER_CTX_set_padding(ctx, 0);
++
+ 	/*
+ 	 * The default implementation adds a whole block of padding if the input
+ 	 * data is perfectly aligned.  We would like to keep that from happening.
+@@ -266,33 +274,33 @@ lanplus_decrypt_aes_cbc_128(const uint8_t * iv,
+ 	assert((input_length % IPMI_CRYPT_AES_CBC_128_BLOCK_SIZE) == 0);
+ 
+ 
+-	if (!EVP_DecryptUpdate(&ctx, output, (int *)bytes_written, input, input_length))
++	if (!EVP_DecryptUpdate(ctx, output, (int *)bytes_written, input, input_length))
+ 	{
+ 		/* Error */
+ 		lprintf(LOG_DEBUG, "ERROR: decrypt update failed");
+ 		*bytes_written = 0;
+-		return;
+ 	}
+ 	else
+ 	{
+ 		uint32_t tmplen;
+ 
+-		if (!EVP_DecryptFinal_ex(&ctx, output + *bytes_written, (int *)&tmplen))
++		if (!EVP_DecryptFinal_ex(ctx, output + *bytes_written, (int *)&tmplen))
+ 		{
++			/* Error */
+ 			char buffer[1000];
+ 			ERR_error_string(ERR_get_error(), buffer);
+ 			lprintf(LOG_DEBUG, "the ERR error %s", buffer);
+ 			lprintf(LOG_DEBUG, "ERROR: decrypt final failed");
+ 			*bytes_written = 0;
+-			return; /* Error */
+ 		}
+ 		else
+ 		{
+ 			/* Success */
+ 			*bytes_written += tmplen;
+-			EVP_CIPHER_CTX_cleanup(&ctx);
+ 		}
+ 	}
++	/* performs cleanup and free */
++	EVP_CIPHER_CTX_free(ctx);
+ 
+ 	if (verbose >= 5)
+ 	{
diff --git a/meta-openembedded/meta-oe/recipes-kernel/ipmitool/ipmitool_1.8.18.bb b/meta-openembedded/meta-oe/recipes-kernel/ipmitool/ipmitool_1.8.18.bb
index 9f73d27..b7f1aa9 100644
--- a/meta-openembedded/meta-oe/recipes-kernel/ipmitool/ipmitool_1.8.18.bb
+++ b/meta-openembedded/meta-oe/recipes-kernel/ipmitool/ipmitool_1.8.18.bb
@@ -22,7 +22,9 @@
 
 DEPENDS = "openssl readline ncurses"
 
-SRC_URI = "${SOURCEFORGE_MIRROR}/ipmitool/ipmitool-${PV}.tar.bz2"
+SRC_URI = "${SOURCEFORGE_MIRROR}/ipmitool/ipmitool-${PV}.tar.bz2 \
+           file://0001-Migrate-to-openssl-1.1.patch \
+           "
 SRC_URI[md5sum] = "bab7ea104c7b85529c3ef65c54427aa3"
 SRC_URI[sha256sum] = "0c1ba3b1555edefb7c32ae8cd6a3e04322056bc087918f07189eeedfc8b81e01"
 
diff --git a/meta-openembedded/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest.bb b/meta-openembedded/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest.bb
new file mode 100644
index 0000000..181e97c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest.bb
@@ -0,0 +1,123 @@
+SUMMARY = "Kernel selftest for Linux"
+DESCRIPTION = "Kernel selftest for Linux"
+LICENSE = "GPLv2"
+
+LIC_FILES_CHKSUM = "file://../COPYING;md5=bbea815ee2795b2f4230826c0c6b8814"
+
+DEPENDS = "rsync-native llvm-native"
+
+# for musl libc
+SRC_URI_append_libc-musl = "\
+                      file://userfaultfd.patch \
+                      "
+SRC_URI += "file://run-ptest \
+            file://COPYING \
+            "
+
+# now we just test bpf and vm
+# we will append other kernel selftest in the future
+# bpf was added in 4.10 with: https://github.com/torvalds/linux/commit/5aa5bd14c5f8660c64ceedf14a549781be47e53d
+# if you have older kernel than that you need to remove it from PACKAGECONFIG
+PACKAGECONFIG ??= "bpf vm"
+PACKAGECONFIG_remove_x86 = "bpf"
+PACKAGECONFIG_remove_arm = "bpf"
+
+PACKAGECONFIG[bpf] = ",,elfutils libcap libcap-ng rsync-native,"
+PACKAGECONFIG[vm] = ",,libcap,libgcc bash"
+
+do_patch[depends] += "virtual/kernel:do_shared_workdir"
+
+inherit linux-kernel-base kernel-arch ptest
+
+S = "${WORKDIR}/${BP}"
+
+TEST_LIST = "\
+    ${@bb.utils.filter('PACKAGECONFIG', 'bpf vm', d)} \
+"
+
+EXTRA_OEMAKE = '\
+    CROSS_COMPILE=${TARGET_PREFIX} \
+    ARCH=${ARCH} \
+    CC="${CC}" \
+    AR="${AR}" \
+    LD="${LD}" \
+    DESTDIR="${D}" \
+'
+
+KERNEL_SELFTEST_SRC ?= "Makefile \
+                        include \
+                        tools \
+                        scripts \
+                        arch \
+                        LICENSES \
+"
+
+python __anonymous () {
+    import re
+
+    var = d.getVar('TARGET_CC_ARCH')
+    pattern = '_FORTIFY_SOURCE=[^0]'
+
+    if re.search(pattern, var):
+        d.appendVar('TARGET_CC_ARCH', " -O")
+}
+
+do_compile() {
+    bbwarn "clang >= 6.0  with bpf support is needed with kernel 4.18+ so \
+either install it and add it to HOSTTOOLS, or add \
+clang-native from meta-clang to dependency"
+    for i in ${TEST_LIST}
+    do
+        oe_runmake -C ${S}/tools/testing/selftests/${i}
+    done
+}
+
+do_install() {
+    for i in ${TEST_LIST}
+    do
+        oe_runmake -C ${S}/tools/testing/selftests/${i} INSTALL_PATH=${D}/usr/kernel-selftest/${i} install
+    done
+    if [ -e ${D}/usr/kernel-selftest/bpf/test_offload.py ]; then
+	sed -i -e '1s,#!.*python3,#! /usr/bin/env python3,' ${D}/usr/kernel-selftest/bpf/test_offload.py
+    fi
+    chown root:root  -R ${D}/usr/kernel-selftest
+}
+
+do_configure() {
+    install -D -m 0644 ${WORKDIR}/COPYING ${S}/COPYING
+}
+
+do_patch[prefuncs] += "copy_kselftest_source_from_kernel remove_unrelated"
+python copy_kselftest_source_from_kernel() {
+    sources = (d.getVar("KERNEL_SELFTEST_SRC") or "").split()
+    src_dir = d.getVar("STAGING_KERNEL_DIR")
+    dest_dir = d.getVar("S")
+    bb.utils.mkdirhier(dest_dir)
+    for s in sources:
+        src = oe.path.join(src_dir, s)
+        dest = oe.path.join(dest_dir, s)
+        if os.path.isdir(src):
+            oe.path.copytree(src, dest)
+        else:
+            bb.utils.copyfile(src, dest)
+}
+
+remove_unrelated() {
+    if ${@bb.utils.contains('PACKAGECONFIG','bpf','true','false',d)} ; then
+        test -f ${S}/tools/testing/selftests/bpf/Makefile && \
+            sed -i -e 's/test_pkt_access.*$/\\/' \
+                   -e 's/test_pkt_md_access.*$/\\/' \
+                   -e 's/sockmap_verdict_prog.*$/\\/' \
+                   ${S}/tools/testing/selftests/bpf/Makefile || \
+            bberror "Your kernel is probably older than 4.10 and doesn't have tools/testing/selftests/bpf/Makefile file from https://github.com/torvalds/linux/commit/5aa5bd14c5f8660c64ceedf14a549781be47e53d, disable bpf PACKAGECONFIG"
+    fi
+}
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+INHIBIT_PACKAGE_DEBUG_SPLIT="1"
+FILES_${PN} += "/usr/kernel-selftest"
+
+RDEPENDS_${PN} += "python3"
+# tools/testing/selftests/vm/Makefile doesn't respect LDFLAGS and tools/testing/selftests/Makefile explicitly overrides to empty
+INSANE_SKIP_${PN} += "ldflags"
diff --git a/meta-openembedded/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest/COPYING b/meta-openembedded/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest/COPYING
new file mode 100644
index 0000000..da4cb28
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest/COPYING
@@ -0,0 +1,18 @@
+The Linux Kernel is provided under:
+
+	SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note
+
+Being under the terms of the GNU General Public License version 2 only,
+according with:
+
+	LICENSES/preferred/GPL-2.0
+
+With an explicit syscall exception, as stated at:
+
+	LICENSES/exceptions/Linux-syscall-note
+
+In addition, other licenses may also apply. Please see:
+
+	Documentation/process/license-rules.rst
+
+for more details.
diff --git a/meta-openembedded/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest/run-ptest b/meta-openembedded/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest/run-ptest
new file mode 100755
index 0000000..d40b957
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest/run-ptest
@@ -0,0 +1,11 @@
+#!/bin/sh
+export PATH=$PATH:/usr/kernel-selftest/bpf
+
+# test_align
+test_align | grep "12 pass" &> /dev/null
+if [ $? == 0 ]; then
+    echo "[PASS]: test_align"
+else
+    echo "[FAIL]: test_align"
+fi
+
diff --git a/meta-openembedded/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest/userfaultfd.patch b/meta-openembedded/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest/userfaultfd.patch
new file mode 100644
index 0000000..bed2051
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest/userfaultfd.patch
@@ -0,0 +1,322 @@
+From c7b375747cffb627d02543d946b28525455d7d46 Mon Sep 17 00:00:00 2001
+From: "Hongzhi.Song" <hongzhi.song@windriver.com>
+Date: Fri, 13 Jul 2018 06:06:19 -0700
+Subject: [PATCH] vm: add some funtions to support musl libc
+
+Signed-off-by: Hongzhi.Song <hongzhi.song@windriver.com>
+---
+ tools/testing/selftests/vm/userfaultfd.c | 298 +++++++++++++++++++++++++++++++
+ 1 file changed, 298 insertions(+)
+
+diff --git a/tools/testing/selftests/vm/userfaultfd.c b/tools/testing/selftests/vm/userfaultfd.c
+index de2f9ec..dc73021 100644
+--- a/tools/testing/selftests/vm/userfaultfd.c
++++ b/tools/testing/selftests/vm/userfaultfd.c
+@@ -71,6 +71,304 @@
+ 
+ #ifdef __NR_userfaultfd
+ 
++/* Linear congruential.  */
++#define	TYPE_0		0
++#define	BREAK_0		8
++#define	DEG_0		0
++#define	SEP_0		0
++
++/* x**7 + x**3 + 1.  */
++#define	TYPE_1		1
++#define	BREAK_1		32
++#define	DEG_1		7
++#define	SEP_1		3
++
++/* x**15 + x + 1.  */
++#define	TYPE_2		2
++#define	BREAK_2		64
++#define	DEG_2		15
++#define	SEP_2		1
++
++/* x**31 + x**3 + 1.  */
++#define	TYPE_3		3
++#define	BREAK_3		128
++#define	DEG_3		31
++#define	SEP_3		3
++
++/* x**63 + x + 1.  */
++#define	TYPE_4		4
++#define	BREAK_4		256
++#define	DEG_4		63
++#define	SEP_4		1
++
++/* Array versions of the above information to make code run faster.
++   Relies on fact that TYPE_i == i.  */
++
++#define	MAX_TYPES	5	/* Max number of types above.  */
++
++#define __set_errno(val) (errno = (val))
++
++struct random_data
++  {
++    int32_t *fptr;      /* Front pointer.  */
++    int32_t *rptr;      /* Rear pointer.  */
++    int32_t *state;     /* Array of state values.  */
++    int rand_type;      /* Type of random number generator.  */
++    int rand_deg;       /* Degree of random number generator.  */
++    int rand_sep;       /* Distance between front and rear.  */
++    int32_t *end_ptr;       /* Pointer behind state table.  */
++  };
++
++struct random_poly_info
++{
++  int seps[MAX_TYPES];
++  int degrees[MAX_TYPES];
++};
++
++static const struct random_poly_info random_poly_info =
++{
++  { SEP_0, SEP_1, SEP_2, SEP_3, SEP_4 },
++  { DEG_0, DEG_1, DEG_2, DEG_3, DEG_4 }
++};
++
++/* If we are using the trivial TYPE_0 R.N.G., just do the old linear
++   congruential bit.  Otherwise, we do our fancy trinomial stuff, which is the
++   same in all the other cases due to all the global variables that have been
++   set up.  The basic operation is to add the number at the rear pointer into
++   the one at the front pointer.  Then both pointers are advanced to the next
++   location cyclically in the table.  The value returned is the sum generated,
++   reduced to 31 bits by throwing away the "least random" low bit.
++   Note: The code takes advantage of the fact that both the front and
++   rear pointers can't wrap on the same call by not testing the rear
++   pointer if the front one has wrapped.  Returns a 31-bit random number.  */
++
++int random_r (struct random_data *buf, int32_t *result)
++{
++  int32_t *state;
++
++  if (buf == NULL || result == NULL)
++    goto fail;
++
++  state = buf->state;
++
++  if (buf->rand_type == TYPE_0)
++    {
++      int32_t val = ((state[0] * 1103515245U) + 12345U) & 0x7fffffff;
++      state[0] = val;
++      *result = val;
++    }
++  else
++    {
++      int32_t *fptr = buf->fptr;
++      int32_t *rptr = buf->rptr;
++      int32_t *end_ptr = buf->end_ptr;
++      uint32_t val;
++
++      val = *fptr += (uint32_t) *rptr;
++      /* Chucking least random bit.  */
++      *result = val >> 1;
++      ++fptr;
++      if (fptr >= end_ptr)
++	{
++	  fptr = state;
++	  ++rptr;
++	}
++      else
++	{
++	  ++rptr;
++	  if (rptr >= end_ptr)
++	    rptr = state;
++	}
++      buf->fptr = fptr;
++      buf->rptr = rptr;
++    }
++  return 0;
++
++ fail:
++  __set_errno (EINVAL);
++  return -1;
++}
++
++/* Initialize the random number generator based on the given seed.  If the
++   type is the trivial no-state-information type, just remember the seed.
++   Otherwise, initializes state[] based on the given "seed" via a linear
++   congruential generator.  Then, the pointers are set to known locations
++   that are exactly rand_sep places apart.  Lastly, it cycles the state
++   information a given number of times to get rid of any initial dependencies
++   introduced by the L.C.R.N.G.  Note that the initialization of randtbl[]
++   for default usage relies on values produced by this routine.  */
++int srandom_r (unsigned int seed, struct random_data *buf)
++{
++  int type;
++  int32_t *state;
++  long int i;
++  int32_t word;
++  int32_t *dst;
++  int kc;
++
++  if (buf == NULL)
++    goto fail;
++  type = buf->rand_type;
++  if ((unsigned int) type >= MAX_TYPES)
++    goto fail;
++
++  state = buf->state;
++  /* We must make sure the seed is not 0.  Take arbitrarily 1 in this case.  */
++  if (seed == 0)
++    seed = 1;
++  state[0] = seed;
++  if (type == TYPE_0)
++    goto done;
++
++  dst = state;
++  word = seed;
++  kc = buf->rand_deg;
++  for (i = 1; i < kc; ++i)
++    {
++      /* This does:
++	   state[i] = (16807 * state[i - 1]) % 2147483647;
++	 but avoids overflowing 31 bits.  */
++      long int hi = word / 127773;
++      long int lo = word % 127773;
++      word = 16807 * lo - 2836 * hi;
++      if (word < 0)
++	word += 2147483647;
++      *++dst = word;
++    }
++
++  buf->fptr = &state[buf->rand_sep];
++  buf->rptr = &state[0];
++  kc *= 10;
++  while (--kc >= 0)
++    {
++      int32_t discard;
++      (void) random_r (buf, &discard);
++    }
++
++ done:
++  return 0;
++
++ fail:
++  return -1;
++}
++
++/* Initialize the state information in the given array of N bytes for
++   future random number generation.  Based on the number of bytes we
++   are given, and the break values for the different R.N.G.'s, we choose
++   the best (largest) one we can and set things up for it.  srandom is
++   then called to initialize the state information.  Note that on return
++   from srandom, we set state[-1] to be the type multiplexed with the current
++   value of the rear pointer; this is so successive calls to initstate won't
++   lose this information and will be able to restart with setstate.
++   Note: The first thing we do is save the current state, if any, just like
++   setstate so that it doesn't matter when initstate is called.
++   Returns 0 on success, non-zero on failure.  */
++int initstate_r (unsigned int seed, char *arg_state, size_t n,
++	       struct random_data *buf)
++{
++  if (buf == NULL)
++    goto fail;
++
++  int32_t *old_state = buf->state;
++  if (old_state != NULL)
++    {
++      int old_type = buf->rand_type;
++      if (old_type == TYPE_0)
++	old_state[-1] = TYPE_0;
++      else
++	old_state[-1] = (MAX_TYPES * (buf->rptr - old_state)) + old_type;
++    }
++
++  int type;
++  if (n >= BREAK_3)
++    type = n < BREAK_4 ? TYPE_3 : TYPE_4;
++  else if (n < BREAK_1)
++    {
++      if (n < BREAK_0)
++	goto fail;
++
++      type = TYPE_0;
++    }
++  else
++    type = n < BREAK_2 ? TYPE_1 : TYPE_2;
++
++  int degree = random_poly_info.degrees[type];
++  int separation = random_poly_info.seps[type];
++
++  buf->rand_type = type;
++  buf->rand_sep = separation;
++  buf->rand_deg = degree;
++  int32_t *state = &((int32_t *) arg_state)[1];	/* First location.  */
++  /* Must set END_PTR before srandom.  */
++  buf->end_ptr = &state[degree];
++
++  buf->state = state;
++
++  srandom_r (seed, buf);
++
++  state[-1] = TYPE_0;
++  if (type != TYPE_0)
++    state[-1] = (buf->rptr - state) * MAX_TYPES + type;
++
++  return 0;
++
++ fail:
++  __set_errno (EINVAL);
++  return -1;
++}
++
++/* Restore the state from the given state array.
++   Note: It is important that we also remember the locations of the pointers
++   in the current state information, and restore the locations of the pointers
++   from the old state information.  This is done by multiplexing the pointer
++   location into the zeroth word of the state information. Note that due
++   to the order in which things are done, it is OK to call setstate with the
++   same state as the current state
++   Returns 0 on success, non-zero on failure.  */
++int setstate_r (char *arg_state, struct random_data *buf)
++{
++  int32_t *new_state = 1 + (int32_t *) arg_state;
++  int type;
++  int old_type;
++  int32_t *old_state;
++  int degree;
++  int separation;
++
++  if (arg_state == NULL || buf == NULL)
++    goto fail;
++
++  old_type = buf->rand_type;
++  old_state = buf->state;
++  if (old_type == TYPE_0)
++    old_state[-1] = TYPE_0;
++  else
++    old_state[-1] = (MAX_TYPES * (buf->rptr - old_state)) + old_type;
++
++  type = new_state[-1] % MAX_TYPES;
++  if (type < TYPE_0 || type > TYPE_4)
++    goto fail;
++
++  buf->rand_deg = degree = random_poly_info.degrees[type];
++  buf->rand_sep = separation = random_poly_info.seps[type];
++  buf->rand_type = type;
++
++  if (type != TYPE_0)
++    {
++      int rear = new_state[-1] / MAX_TYPES;
++      buf->rptr = &new_state[rear];
++      buf->fptr = &new_state[(rear + separation) % degree];
++    }
++  buf->state = new_state;
++  /* Set end_ptr too.  */
++  buf->end_ptr = &new_state[degree];
++
++  return 0;
++
++ fail:
++  __set_errno (EINVAL);
++  return -1;
++}
++
+ static unsigned long nr_cpus, nr_pages, nr_pages_per_cpu, page_size;
+ 
+ #define BOUNCE_RANDOM		(1<<0)
+-- 
+2.11.0
+
diff --git a/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch.inc b/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch.inc
index b1e73e9..cd819f3 100644
--- a/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch.inc
+++ b/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch.inc
@@ -30,6 +30,7 @@
 PROVIDES += "kpatch-build"
 
 COMPATIBLE_HOST = "(x86_64).*-linux"
+COMPATIBLE_HOST_libc-musl = "null"
 
 RDEPENDS_${PN} = "bash binutils"
 RDEPENDS_kpatch-build = "bash glibc-utils"
@@ -38,6 +39,7 @@
 	${sbindir}/kpatch \
 	${systemd_system_unitdir}/kpatch.service \
 	${mandir}/man1/kpatch.1.gz \
+	${sysconfdir}/init/kpatch.conf \
 	"
 FILES_kpatch-build = " \
 	${bindir}/kpatch-build \
diff --git a/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch/0001-kpatch-build-add-cross-compilation-support.patch b/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch/0001-kpatch-build-add-cross-compilation-support.patch
index 459fb21..ab3b127 100644
--- a/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch/0001-kpatch-build-add-cross-compilation-support.patch
+++ b/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch/0001-kpatch-build-add-cross-compilation-support.patch
@@ -1,4 +1,4 @@
-From a9a80a1f4df65892a0269295ce8a64b06f2ff61d Mon Sep 17 00:00:00 2001
+From 70de3fecbc551907c4fd504cfff385c73be8db75 Mon Sep 17 00:00:00 2001
 From: Ruslan Bilovol <rbilovol@cisco.com>
 Date: Tue, 19 Dec 2017 15:59:04 +0200
 Subject: [PATCH] kpatch-build: add cross-compilation support
@@ -17,16 +17,17 @@
 Upstream-Status: Pending
 
 Signed-off-by: Ruslan Bilovol <rbilovol@cisco.com>
+
 ---
  kpatch-build/kpatch-build | 13 +++++++++++--
  kpatch-build/kpatch-gcc   |  4 ++--
  2 files changed, 13 insertions(+), 4 deletions(-)
 
 diff --git a/kpatch-build/kpatch-build b/kpatch-build/kpatch-build
-index 166ecbd..af24cc4 100755
+index a76913f..4a011aa 100755
 --- a/kpatch-build/kpatch-build
 +++ b/kpatch-build/kpatch-build
-@@ -195,7 +195,7 @@ gcc_version_check() {
+@@ -197,7 +197,7 @@ gcc_version_check() {
  	# gcc --version varies between distributions therefore extract version
  	# by compiling a test file and compare it to vmlinux's version.
  	echo 'void main(void) {}' > "$c"
@@ -35,7 +36,7 @@
  	gccver="$(gcc_version_from_file "$o")"
  	kgccver="$(gcc_version_from_file "$VMLINUX")"
  	rm -f "$c" "$o"
-@@ -381,12 +381,14 @@ usage() {
+@@ -392,12 +392,14 @@ usage() {
  	echo "		-d, --debug        Enable 'xtrace' and keep scratch files" >&2
  	echo "		                   in <CACHEDIR>/tmp" >&2
  	echo "		                   (can be specified multiple times)" >&2
@@ -51,7 +52,7 @@
  
  eval set -- "$options"
  
-@@ -444,6 +446,10 @@ while [[ $# -gt 0 ]]; do
+@@ -455,6 +457,10 @@ while [[ $# -gt 0 ]]; do
  			echo "DEBUG mode enabled"
  		fi
  		;;
@@ -62,7 +63,7 @@
  	--skip-cleanup)
  		echo "Skipping cleanup"
  		SKIPCLEANUP=1
-@@ -691,6 +697,8 @@ if [[ $DEBUG -ge 4 ]]; then
+@@ -710,6 +716,8 @@ if [[ $DEBUG -ge 4 ]]; then
  	export KPATCH_GCC_DEBUG=1
  fi
  
@@ -70,8 +71,8 @@
 +
  echo "Building original kernel"
  ./scripts/setlocalversion --save-scmversion || die
- make mrproper 2>&1 | logger || die
-@@ -840,6 +848,7 @@ cd "$TEMPDIR/patch" || die
+ unset KPATCH_GCC_TEMPDIR
+@@ -874,6 +882,7 @@ cd "$TEMPDIR/patch" || die
  KPATCH_BUILD="$SRCDIR" KPATCH_NAME="$MODNAME" \
  KBUILD_EXTRA_SYMBOLS="$KBUILD_EXTRA_SYMBOLS" \
  KPATCH_LDFLAGS="$KPATCH_LDFLAGS" \
@@ -80,7 +81,7 @@
  
  if ! "$KPATCH_MODULE"; then
 diff --git a/kpatch-build/kpatch-gcc b/kpatch-build/kpatch-gcc
-index 6ba133c..3937948 100755
+index 2d56da1..59a4255 100755
 --- a/kpatch-build/kpatch-gcc
 +++ b/kpatch-build/kpatch-gcc
 @@ -8,7 +8,7 @@ TOOLCHAINCMD="$1"
@@ -92,12 +93,9 @@
  fi
  
  declare -a args=("$@")
-@@ -80,4 +80,4 @@ elif [[ "$TOOLCHAINCMD" = "ld" ]] ; then
+@@ -82,4 +82,4 @@ elif [[ "$TOOLCHAINCMD" = "ld" ]] ; then
  	done
  fi
  
 -exec "$TOOLCHAINCMD" "${args[@]}"
 +exec ${KPATCH_CROSS_COMPILE}${TOOLCHAINCMD} "${args[@]}"
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch/0002-kpatch-build-allow-overriding-of-distro-name.patch b/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch/0002-kpatch-build-allow-overriding-of-distro-name.patch
index a9d8a7f..13cdc6b 100644
--- a/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch/0002-kpatch-build-allow-overriding-of-distro-name.patch
+++ b/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch/0002-kpatch-build-allow-overriding-of-distro-name.patch
@@ -1,4 +1,4 @@
-From d418d716dae1e2a05131dfb42a19a4da2fc8a85d Mon Sep 17 00:00:00 2001
+From 15838a86d5ea94fa05976ea32fd847b18261b403 Mon Sep 17 00:00:00 2001
 From: Ruslan Bilovol <rbilovol@cisco.com>
 Date: Tue, 2 Jan 2018 14:50:03 +0200
 Subject: [PATCH] kpatch-build: allow overriding of distro name
@@ -14,15 +14,16 @@
 Upstream-Status: Pending
 
 Signed-off-by: Ruslan Bilovol <rbilovol@cisco.com>
+
 ---
  kpatch-build/kpatch-build | 9 +++++++--
  1 file changed, 7 insertions(+), 2 deletions(-)
 
 diff --git a/kpatch-build/kpatch-build b/kpatch-build/kpatch-build
-index af24cc4..4f9f78d 100755
+index 4a011aa..eb6cd64 100755
 --- a/kpatch-build/kpatch-build
 +++ b/kpatch-build/kpatch-build
-@@ -383,12 +383,13 @@ usage() {
+@@ -394,12 +394,13 @@ usage() {
  	echo "		                   (can be specified multiple times)" >&2
  	echo "		--cross-compile    Specify the prefix used for all executables" >&2
  	echo "		                   used during compilation" >&2
@@ -37,7 +38,7 @@
  
  eval set -- "$options"
  
-@@ -450,6 +451,10 @@ while [[ $# -gt 0 ]]; do
+@@ -461,6 +462,10 @@ while [[ $# -gt 0 ]]; do
  		KPATCH_CROSS_COMPILE="$2"
  		shift
  		;;
@@ -48,7 +49,7 @@
  	--skip-cleanup)
  		echo "Skipping cleanup"
  		SKIPCLEANUP=1
-@@ -526,7 +531,7 @@ fi
+@@ -539,7 +544,7 @@ fi
  # Don't check external file.
  # shellcheck disable=SC1091
  source /etc/os-release
@@ -57,6 +58,3 @@
  if [[ "$DISTRO" = fedora ]] || [[ "$DISTRO" = rhel ]] || [[ "$DISTRO" = ol ]] || [[ "$DISTRO" = centos ]]; then
  	[[ -z "$VMLINUX" ]] && VMLINUX="/usr/lib/debug/lib/modules/$ARCHVERSION/vmlinux"
  	[[ -e "$VMLINUX" ]] || die "kernel-debuginfo-$ARCHVERSION not installed"
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch_git.bb b/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch_git.bb
index e495e28..024cca6 100644
--- a/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch_git.bb
+++ b/meta-openembedded/meta-oe/recipes-kernel/kpatch/kpatch_git.bb
@@ -2,9 +2,9 @@
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
 
-SRCREV = "db6efbb8c7e90d2b761272cf563047119072768f"
+SRCREV = "7f550f01bd308cf058ae782327d29c8916cc5602"
 
-PV = "0.5.0+git${SRCPV}"
+PV = "0.6.1+git${SRCPV}"
 
 S = "${WORKDIR}/git"
 
diff --git a/meta-openembedded/meta-oe/recipes-kernel/makedumpfile/makedumpfile/0001-makedumpfile-replace-hardcode-CFLAGS.patch b/meta-openembedded/meta-oe/recipes-kernel/makedumpfile/makedumpfile/0001-makedumpfile-replace-hardcode-CFLAGS.patch
index d599a91..a478065 100644
--- a/meta-openembedded/meta-oe/recipes-kernel/makedumpfile/makedumpfile/0001-makedumpfile-replace-hardcode-CFLAGS.patch
+++ b/meta-openembedded/meta-oe/recipes-kernel/makedumpfile/makedumpfile/0001-makedumpfile-replace-hardcode-CFLAGS.patch
@@ -1,4 +1,4 @@
-From 3c2f4ff583a156a7ed2fa0cc002a413c391d063d Mon Sep 17 00:00:00 2001
+From 8eeb1b15608ce1a9a1f0d5417938fd6da4504406 Mon Sep 17 00:00:00 2001
 From: Mingli Yu <mingli.yu@windriver.com>
 Date: Thu, 21 Jul 2016 18:06:21 +0800
 Subject: [PATCH] makedumpfile: replace hardcode CFLAGS
@@ -13,12 +13,13 @@
 Upstream-Status: Inappropriate[oe specific]
 
 Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
+
 ---
  Makefile | 46 +++++++++++++++++++++++-----------------------
  1 file changed, 23 insertions(+), 23 deletions(-)
 
 diff --git a/Makefile b/Makefile
-index 7dde3e4..c5286ac 100644
+index 612b9d0..f6d6265 100644
 --- a/Makefile
 +++ b/Makefile
 @@ -8,13 +8,6 @@ ifeq ($(strip $CC),)
@@ -80,9 +81,9 @@
 +		-DRELEASE_DATE='"$(DATE)"'
 +
  SRC_BASE = makedumpfile.c makedumpfile.h diskdump_mod.h sadump_mod.h sadump_info.h
- SRC_PART = print_info.c dwarf_info.c elf_info.c erase_info.c sadump_info.c cache.c
+ SRC_PART = print_info.c dwarf_info.c elf_info.c erase_info.c sadump_info.c cache.c tools.c
  OBJ_PART=$(patsubst %.c,%.o,$(SRC_PART))
-@@ -54,17 +54,17 @@ OBJ_ARCH=$(patsubst %.c,%.o,$(SRC_ARCH))
+@@ -53,17 +53,17 @@ OBJ_ARCH=$(patsubst %.c,%.o,$(SRC_ARCH))
  
  LIBS = -ldw -lbz2 -lebl -ldl -lelf -lz
  ifneq ($(LINKTYPE), dynamic)
@@ -103,7 +104,7 @@
  endif
  
  LIBS := -lpthread $(LIBS)
-@@ -72,14 +72,14 @@ LIBS := -lpthread $(LIBS)
+@@ -71,14 +71,14 @@ LIBS := -lpthread $(LIBS)
  all: makedumpfile
  
  $(OBJ_PART): $(SRC_PART)
@@ -120,7 +121,7 @@
  	echo .TH MAKEDUMPFILE 8 \"$(DATE)\" \"makedumpfile v$(VERSION)\" \"Linux System Administrator\'s Manual\" > temp.8
  	grep -v "^.TH MAKEDUMPFILE 8" $(VPATH)makedumpfile.8 >> temp.8
  	mv temp.8 makedumpfile.8
-@@ -90,7 +90,7 @@ makedumpfile: $(SRC_BASE) $(OBJ_PART) $(OBJ_ARCH)
+@@ -89,7 +89,7 @@ makedumpfile: $(SRC_BASE) $(OBJ_PART) $(OBJ_ARCH)
  	gzip -c ./makedumpfile.conf.5 > ./makedumpfile.conf.5.gz
  
  eppic_makedumpfile.so: extension_eppic.c
@@ -129,6 +130,3 @@
  
  clean:
  	rm -f $(OBJ) $(OBJ_PART) $(OBJ_ARCH) makedumpfile makedumpfile.8.gz makedumpfile.conf.5.gz
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-kernel/makedumpfile/makedumpfile/0002-mem_section-Support-only-46-bit-for-MAX_PHYSMEM_BITS.patch b/meta-openembedded/meta-oe/recipes-kernel/makedumpfile/makedumpfile/0002-mem_section-Support-only-46-bit-for-MAX_PHYSMEM_BITS.patch
index e0c3d9a..766f4fc 100644
--- a/meta-openembedded/meta-oe/recipes-kernel/makedumpfile/makedumpfile/0002-mem_section-Support-only-46-bit-for-MAX_PHYSMEM_BITS.patch
+++ b/meta-openembedded/meta-oe/recipes-kernel/makedumpfile/makedumpfile/0002-mem_section-Support-only-46-bit-for-MAX_PHYSMEM_BITS.patch
@@ -1,4 +1,4 @@
-From 653fe8e724081d2f289c2245d1220d5f7170538d Mon Sep 17 00:00:00 2001
+From ba123fa6b2aa0ac62d1b78f327339635ae87201a Mon Sep 17 00:00:00 2001
 From: Alexandru Moise <alexandru.moise@windriver.com>
 Date: Fri, 29 Apr 2016 07:40:46 +0000
 Subject: [PATCH] mem_section: Support only 46 bit for MAX_PHYSMEM_BITS on
@@ -20,18 +20,20 @@
 
 Signed-off-by: Alexandru Moise <alexandru.moise@windriver.com>
 Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
+
 ---
  arch/ppc64.c | 28 ++--------------------------
  1 file changed, 2 insertions(+), 26 deletions(-)
 
 diff --git a/arch/ppc64.c b/arch/ppc64.c
-index 89a7f05..6c928ab 100644
+index 8b6f7d5..458f06b 100644
 --- a/arch/ppc64.c
 +++ b/arch/ppc64.c
-@@ -302,37 +302,13 @@ ppc64_vtop_level4(unsigned long vaddr)
+@@ -462,38 +462,14 @@ ppc64_vtop_level4(unsigned long vaddr)
+ 	return paddr;
  }
  
- int
+-int
 -set_ppc64_max_physmem_bits(void)
 -{
 -	long array_len = ARRAY_LENGTH(mem_section);
@@ -53,7 +55,7 @@
 -	return FALSE;
 -}
 -
--int
+ int
  get_machdep_info_ppc64(void)
  {
  	unsigned long vmlist, vmap_area_list, vmalloc_start;
@@ -68,6 +70,3 @@
  	info->page_offset = __PAGE_OFFSET;
  
  	if (SYMBOL(_stext) == NOT_FOUND_SYMBOL) {
--- 
-2.5.0
-
diff --git a/meta-openembedded/meta-oe/recipes-kernel/makedumpfile/makedumpfile_1.6.2.bb b/meta-openembedded/meta-oe/recipes-kernel/makedumpfile/makedumpfile_1.6.2.bb
deleted file mode 100644
index d6f2d80..0000000
--- a/meta-openembedded/meta-oe/recipes-kernel/makedumpfile/makedumpfile_1.6.2.bb
+++ /dev/null
@@ -1,54 +0,0 @@
-SUMMARY = "VMcore extraction tool"
-DESCRIPTION = "\
-    This program is used to extract a subset of the memory available either \
-    via /dev/mem or /proc/vmcore (for crashdumps). It is used to get memory \
-    images without extra uneeded information (zero pages, userspace programs, \
-    etc). \
-"
-HOMEPAGE = "http://makedumpfile.sourceforge.net"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
-LICENSE = "GPLv2.0"
-
-DEPENDS = "bzip2 zlib elfutils"
-RDEPENDS_${PN}-tools = "perl ${PN}"
-
-# arm would compile but has never been tested upstream.  mips would not compile.
-#
-COMPATIBLE_HOST = "(x86_64|i.86|powerpc|arm).*-linux"
-
-PACKAGES =+ "${PN}-tools"
-FILES_${PN}-tools = "${bindir}/*.pl"
-
-SRC_URI = "\
-    ${SOURCEFORGE_MIRROR}/makedumpfile/${BPN}-${PV}.tar.gz \
-    file://0001-makedumpfile-replace-hardcode-CFLAGS.patch \
-    file://0002-mem_section-Support-only-46-bit-for-MAX_PHYSMEM_BITS.patch \
-"
-SRC_URI[md5sum] = "72be5bf973eed898c5127e3abc466583"
-SRC_URI[sha256sum] = "ee3d21cb4032a60bd2c802d1d8b21b9f399710e1574f8de8ead5ab50cd821a6d"
-
-SECTION = "base"
-
-# If we do not specify TARGET, makedumpfile will build for the host but use the
-# target gcc.
-#
-EXTRA_OEMAKE = "\
-    LINKTYPE=static \
-    TARGET=${TARGET_ARCH} \
-"
-
-do_install () {
-    mkdir -p ${D}/usr/bin
-    install -m 755 ${S}/makedumpfile ${D}/usr/bin
-    install -m 755 ${S}/makedumpfile-R.pl ${D}/usr/bin
-
-    mkdir -p ${D}/usr/share/man/man8
-    install -m 644 ${S}/makedumpfile.8.gz ${D}/usr/share/man/man8
-
-    mkdir -p ${D}/usr/share/man/man5
-    install -m 644 ${S}/makedumpfile.conf.5.gz ${D}/usr/share/man/man5
-
-    mkdir -p ${D}/etc/
-    install -m 644 ${S}/makedumpfile.conf ${D}/etc/makedumpfile.conf.sample
-}
diff --git a/meta-openembedded/meta-oe/recipes-kernel/makedumpfile/makedumpfile_1.6.4.bb b/meta-openembedded/meta-oe/recipes-kernel/makedumpfile/makedumpfile_1.6.4.bb
new file mode 100644
index 0000000..629e251
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-kernel/makedumpfile/makedumpfile_1.6.4.bb
@@ -0,0 +1,57 @@
+SUMMARY = "VMcore extraction tool"
+DESCRIPTION = "\
+    This program is used to extract a subset of the memory available either \
+    via /dev/mem or /proc/vmcore (for crashdumps). It is used to get memory \
+    images without extra uneeded information (zero pages, userspace programs, \
+    etc). \
+"
+HOMEPAGE = "http://makedumpfile.sourceforge.net"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
+LICENSE = "GPLv2.0"
+
+DEPENDS = "bzip2 zlib elfutils"
+RDEPENDS_${PN}-tools = "perl ${PN}"
+
+# arm would compile but has never been tested upstream.  mips would not compile.
+#
+COMPATIBLE_HOST = "(x86_64|i.86|powerpc|arm).*-linux"
+
+PACKAGES =+ "${PN}-tools"
+FILES_${PN}-tools = "${bindir}/*.pl"
+
+SRC_URI = "\
+    ${SOURCEFORGE_MIRROR}/makedumpfile/${BPN}-${PV}.tar.gz \
+    file://0001-makedumpfile-replace-hardcode-CFLAGS.patch \
+    file://0002-mem_section-Support-only-46-bit-for-MAX_PHYSMEM_BITS.patch \
+"
+SRC_URI[md5sum] = "7dfbca19f487604c271e2892ba07f4bd"
+SRC_URI[sha256sum] = "7e06f72d5f291fcab9e92975f405a76e37d4f7fc8fa4172f199636398ae812b1"
+
+UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/makedumpfile/files/makedumpfile/"
+UPSTREAM_CHECK_REGEX = "makedumpfile/(?P<pver>\d+(\.\d+)+)/"
+
+SECTION = "base"
+
+# If we do not specify TARGET, makedumpfile will build for the host but use the
+# target gcc.
+#
+EXTRA_OEMAKE = "\
+    LINKTYPE=static \
+    TARGET=${TARGET_ARCH} \
+"
+
+do_install () {
+    mkdir -p ${D}/usr/bin
+    install -m 755 ${S}/makedumpfile ${D}/usr/bin
+    install -m 755 ${S}/makedumpfile-R.pl ${D}/usr/bin
+
+    mkdir -p ${D}/usr/share/man/man8
+    install -m 644 ${S}/makedumpfile.8.gz ${D}/usr/share/man/man8
+
+    mkdir -p ${D}/usr/share/man/man5
+    install -m 644 ${S}/makedumpfile.conf.5.gz ${D}/usr/share/man/man5
+
+    mkdir -p ${D}/etc/
+    install -m 644 ${S}/makedumpfile.conf ${D}/etc/makedumpfile.conf.sample
+}
diff --git a/meta-openembedded/meta-oe/recipes-kernel/minicoredumper/files/0001-fix-compile-error-on-arch-x32.patch b/meta-openembedded/meta-oe/recipes-kernel/minicoredumper/files/0001-fix-compile-error-on-arch-x32.patch
deleted file mode 100644
index 6ba6ad4..0000000
--- a/meta-openembedded/meta-oe/recipes-kernel/minicoredumper/files/0001-fix-compile-error-on-arch-x32.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From 883f53ee33eaef8aca1288a110857402ad362966 Mon Sep 17 00:00:00 2001
-From: John Ogness <john.ogness@linutronix.de>
-Date: Fri, 8 Sep 2017 15:03:03 -0700
-Subject: [PATCH] fix compile error on arch=x32
-
-On the x32 architecture time_t is a "long long int". By
- typecasting time_t to "long long", this should work correctly
- for all architectures.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Pending
-
- src/minicoredumper/corestripper.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/minicoredumper/corestripper.c b/src/minicoredumper/corestripper.c
-index fd39bfb..07dc318 100644
---- a/src/minicoredumper/corestripper.c
-+++ b/src/minicoredumper/corestripper.c
-@@ -1241,7 +1241,7 @@ static int dump_compressed_tar(struct dump_info *di)
- 	snprintf(hdr.mode, sizeof(hdr.mode), "%07o", 0644);
- 	snprintf(hdr.uid, sizeof(hdr.uid), "%07o", 0);
- 	snprintf(hdr.gid, sizeof(hdr.gid), "%07o", 0);
--	snprintf(hdr.mtime, sizeof(hdr.mtime), "%011lo",
-+	snprintf(hdr.mtime, sizeof(hdr.mtime), "%011llo",
- 		 (long long)time(NULL));
- 	memset(hdr.checksum, ' ', sizeof(hdr.checksum));
- 	hdr.type = 'S';
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-oe/recipes-kernel/minicoredumper/minicoredumper_2.0.0.bb b/meta-openembedded/meta-oe/recipes-kernel/minicoredumper/minicoredumper_2.0.0.bb
index 0d3c66b..bae5cf4 100644
--- a/meta-openembedded/meta-oe/recipes-kernel/minicoredumper/minicoredumper_2.0.0.bb
+++ b/meta-openembedded/meta-oe/recipes-kernel/minicoredumper/minicoredumper_2.0.0.bb
@@ -9,7 +9,7 @@
 
 inherit autotools pkgconfig systemd update-rc.d
 
-SRCREV = "cdc1faf1212a51e89b477468876e229223fceb9a"
+SRCREV = "1c0d5960b0bb4bac7566e6afe8bc9705399cc76b"
 
 PR .= "+git${SRCPV}"
 
@@ -17,7 +17,6 @@
            file://minicoredumper.service \
            file://minicoredumper.init \
            file://0001-minicoredumper-Initialize-pointer-to-config-struct-t.patch \
-           file://0001-fix-compile-error-on-arch-x32.patch \
            "
 
 S = "${WORKDIR}/git"
@@ -43,3 +42,6 @@
     sed -i -e s:/usr/bin/minicoredumper:${sbindir}/minicoredumper:g ${D}${sysconfdir}/init.d/minicoredumper
     sed -i -e s:/usr/bin/minicoredumper:${sbindir}/minicoredumper:g ${D}${systemd_system_unitdir}/minicoredumper.service
 }
+
+# http://errors.yoctoproject.org/Errors/Details/186966/
+EXCLUDE_FROM_WORLD_libc-musl = "1"
diff --git a/meta-openembedded/meta-oe/recipes-kernel/oprofile/oprofile.inc b/meta-openembedded/meta-oe/recipes-kernel/oprofile/oprofile.inc
index 4b01654..349e2bf 100644
--- a/meta-openembedded/meta-oe/recipes-kernel/oprofile/oprofile.inc
+++ b/meta-openembedded/meta-oe/recipes-kernel/oprofile/oprofile.inc
@@ -25,12 +25,12 @@
            file://run-ptest \
            file://root-home-dir.patch \
            file://0001-Add-rmb-definition-for-NIOS2-architecture.patch \
-           file://0001-Fix-FTBFS-problem-with-GCC-6.patch \
 "
 UPSTREAM_CHECK_REGEX = "oprofile-(?P<pver>\d+(\.\d+)+)/"
 UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/oprofile/files/oprofile/"
 
-SRC_URI_append_libc-musl = " file://musl.patch"
+SRC_URI_append_libc-musl = " file://musl.patch \
+"
 
 inherit autotools pkgconfig ptest
 
diff --git a/meta-openembedded/meta-oe/recipes-kernel/oprofile/oprofile/0001-Fix-FTBFS-problem-with-GCC-6.patch b/meta-openembedded/meta-oe/recipes-kernel/oprofile/oprofile/0001-Fix-FTBFS-problem-with-GCC-6.patch
deleted file mode 100644
index d372fd5..0000000
--- a/meta-openembedded/meta-oe/recipes-kernel/oprofile/oprofile/0001-Fix-FTBFS-problem-with-GCC-6.patch
+++ /dev/null
@@ -1,51 +0,0 @@
-From 39d4d46a0bd504ac708ffe72df87bf74cd12ad30 Mon Sep 17 00:00:00 2001
-From: William Cohen <wcohen@redhat.com>
-Date: Fri, 5 Feb 2016 17:30:19 -0500
-Subject: [PATCH] Fix FTBFS problem with GCC-6
-
-GCC-6 is pickier about some of the type conversions causing the Fedora
-24 mass rebuild the build of oprofile failed with:
-
-make[3]: Entering directory '/builddir/build/BUILD/oprofile-1.1.0/libutil++'
-g++ -DHAVE_CONFIG_H -I. -I..  -I ../libutil -I ../libop -I ../libpp   -W -Wall -fno-common -ftemplate-depth-50 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m32 -march=i686 -mtune=atom -fasynchronous-unwind-tables -c -o op_bfd.o op_bfd.cpp
-op_bfd.cpp: In member function 'void op_bfd::get_symbol_range(symbol_index_t, long long unsigned int&, long long unsigned int&) const':
-op_bfd.cpp:538:47: error: cannot convert 'std::ostream {aka std::basic_ostream<char>}' to 'const bool' in initialization
-  bool const verbose = cverb << (vbfd & vlevel1);
-                                               ^
-op_bfd.cpp:546:7: error: in argument to unary !
-  if (!verbose)
-       ^~~~~~~
-
-Avoid the intermediate bool type to make GCC-6 happy.
-
-Signed-off-by: William Cohen <wcohen@redhat.com>
----
-Upstream-Status: Backport
-
- libutil++/op_bfd.cpp | 4 +---
- 1 file changed, 1 insertion(+), 3 deletions(-)
-
-diff --git a/libutil++/op_bfd.cpp b/libutil++/op_bfd.cpp
-index 389c920..f2eb42b 100644
---- a/libutil++/op_bfd.cpp
-+++ b/libutil++/op_bfd.cpp
-@@ -535,15 +535,13 @@ void op_bfd::get_symbol_range(symbol_index_t sym_idx,
- {
- 	op_bfd_symbol const & sym = syms[sym_idx];
- 
--	bool const verbose = cverb << (vbfd & vlevel1);
--
- 	if (anon_obj)
- 		start = sym.vma();
- 	else
- 		start = sym.filepos();
- 	end = start + sym.size();
- 
--	if (!verbose)
-+	if (!(cverb << (vbfd & vlevel1)))
- 		return;
- 
- 	io_state state(cverb << (vbfd & vlevel1));
--- 
-1.9.1
-
diff --git a/meta-openembedded/meta-oe/recipes-kernel/oprofile/oprofile_1.1.0.bb b/meta-openembedded/meta-oe/recipes-kernel/oprofile/oprofile_1.1.0.bb
deleted file mode 100644
index 92a94ad..0000000
--- a/meta-openembedded/meta-oe/recipes-kernel/oprofile/oprofile_1.1.0.bb
+++ /dev/null
@@ -1,10 +0,0 @@
-require oprofile.inc
-
-DEPENDS += "virtual/kernel"
-DEPENDS_append_powerpc64 = " libpfm4"
-
-SRC_URI[md5sum] = "248c4c069f9476f427fa7195563f9867"
-SRC_URI[sha256sum] = "cf759a6de1a6033d5dfc93bda129a9f2e128aecc4238cc657feb0801d1b0366c"
-
-S = "${WORKDIR}/oprofile-${PV}"
-
diff --git a/meta-openembedded/meta-oe/recipes-kernel/oprofile/oprofile_1.3.0.bb b/meta-openembedded/meta-oe/recipes-kernel/oprofile/oprofile_1.3.0.bb
new file mode 100644
index 0000000..1dc535e
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-kernel/oprofile/oprofile_1.3.0.bb
@@ -0,0 +1,10 @@
+require oprofile.inc
+
+DEPENDS += "virtual/kernel"
+DEPENDS_append_powerpc64 = " libpfm4"
+
+SRC_URI[md5sum] = "bd998df5521ebedae31e71cd3fb6200b"
+SRC_URI[sha256sum] = "95ded8bde1ec39922f0af015981a67aec63e025a501e4dc04cd65d38f73647e6"
+
+S = "${WORKDIR}/oprofile-${PV}"
+
diff --git a/meta-openembedded/meta-oe/recipes-kernel/turbostat/turbostat/COPYING b/meta-openembedded/meta-oe/recipes-kernel/turbostat/turbostat/COPYING
new file mode 100644
index 0000000..da4cb28
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-kernel/turbostat/turbostat/COPYING
@@ -0,0 +1,18 @@
+The Linux Kernel is provided under:
+
+	SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note
+
+Being under the terms of the GNU General Public License version 2 only,
+according with:
+
+	LICENSES/preferred/GPL-2.0
+
+With an explicit syscall exception, as stated at:
+
+	LICENSES/exceptions/Linux-syscall-note
+
+In addition, other licenses may also apply. Please see:
+
+	Documentation/process/license-rules.rst
+
+for more details.
diff --git a/meta-openembedded/meta-oe/recipes-kernel/turbostat/turbostat_3.4.bb b/meta-openembedded/meta-oe/recipes-kernel/turbostat/turbostat_3.4.bb
new file mode 100644
index 0000000..dc3e78f
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-kernel/turbostat/turbostat_3.4.bb
@@ -0,0 +1,57 @@
+#
+# Copyright (C) 2013 Wind River Systems, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License version 2 as
+# published by the Free Software Foundation.
+#
+SUMMARY = "Frequency and Idle power monitoring tools for Linux"
+
+DESCRIPTION = "The turbostat tool allows you to determine the actual \
+processor frequency and idle power saving state residency on supported \
+processors."
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://../COPYING;md5=bbea815ee2795b2f4230826c0c6b8814"
+COMPATIBLE_HOST = '(x86_64.*|i.86.*)-linux'
+COMPATIBLE_HOST_libc-musl = "null"
+
+SRC_URI += "\
+            file://COPYING \
+            "
+
+DEPENDS = "virtual/kernel"
+
+# This looks in S, so we better make sure there's
+# something in the directory.
+#
+do_populate_lic[depends] = "${PN}:do_configure"
+
+
+EXTRA_OEMAKE = '\
+                CC="${CC}" \
+		'CFLAGS=-Wall -I${STAGING_KERNEL_DIR}/arch/x86/include/uapi ${LDFLAGS}' \
+               '
+
+# If we build under STAGING_KERNEL_DIR, source will not be put
+# into the dbg rpm.  STAGING_KERNEL_DIR will exist by the time
+# do_configure() is invoked so we can safely copy from it.
+#
+do_configure_prepend() {
+	mkdir -p ${S}
+	cp -r ${STAGING_KERNEL_DIR}/arch/x86/include/asm/msr-index.h ${S}
+	cp -r ${STAGING_KERNEL_DIR}/arch/x86/include/asm/intel-family.h ${S}
+	cp -r ${STAGING_KERNEL_DIR}/tools/power/x86/turbostat/* ${S}
+	cp -r ${WORKDIR}/COPYING ${S}
+}
+
+do_compile() {
+	sed -i 's#MSRHEADER#"msr-index.h"#' turbostat.c
+	sed -i 's#INTEL_FAMILY_HEADER#"intel-family.h"#' turbostat.c
+	sed -i 's#\$(CC) \$(CFLAGS) \$< -o \$(BUILD_OUTPUT)/\$@#\$(CC) \$(CFLAGS) \$(LDFLAGS) \$< -o \$(BUILD_OUTPUT)/\$@#' Makefile
+	oe_runmake STAGING_KERNEL_DIR=${STAGING_KERNEL_DIR}
+}
+
+do_install() {
+	oe_runmake DESTDIR="${D}" install
+}
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/alsa/alsa-oss_1.0.28.bb b/meta-openembedded/meta-oe/recipes-multimedia/alsa/alsa-oss_1.0.28.bb
deleted file mode 100644
index 0c4a9f5..0000000
--- a/meta-openembedded/meta-oe/recipes-multimedia/alsa/alsa-oss_1.0.28.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-SUMMARY = "Alsa OSS Compatibility Package"
-SECTION = "libs/multimedia"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
-DEPENDS = "alsa-lib"
-
-SRC_URI = "ftp://ftp.alsa-project.org/pub/oss-lib/alsa-oss-${PV}.tar.bz2 \
-    file://libio.patch \
-"
-SRC_URI[md5sum] = "91f57e8cee1ad4cc956caa8b62ac5d43"
-SRC_URI[sha256sum] = "3ae62caa88a0bc7b30ed836dcb794dc6ef4d3650439e2260db54cace7d5c6ad5"
-
-inherit autotools
-
-LEAD_SONAME = "libaoss.so.0"
-
-do_configure_prepend () {
-    touch NEWS README AUTHORS ChangeLog
-    sed -i "s/libaoss.so/${LEAD_SONAME}/" ${S}/alsa/aoss.in
-}
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/alsa/alsa-oss_1.1.6.bb b/meta-openembedded/meta-oe/recipes-multimedia/alsa/alsa-oss_1.1.6.bb
new file mode 100644
index 0000000..6c2176f
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-multimedia/alsa/alsa-oss_1.1.6.bb
@@ -0,0 +1,46 @@
+# FIXME: the LIC_FILES_CHKSUM values have been updated by 'devtool upgrade'.
+# The following is the difference between the old and the new license text.
+# Please update the LICENSE value if needed, and summarize the changes in
+# the commit message via 'License-Update:' tag.
+# (example: 'License-Update: copyright years updated.')
+#
+# The changes:
+#
+# --- COPYING
+# +++ COPYING
+# @@ -2,7 +2,8 @@
+#  		       Version 2, June 1991
+#  
+#   Copyright (C) 1989, 1991 Free Software Foundation, Inc.
+# -                       59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+# + 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
+# +
+#   Everyone is permitted to copy and distribute verbatim copies
+#   of this license document, but changing it is not allowed.
+#  
+# 
+#
+
+SUMMARY = "Alsa OSS Compatibility Package"
+SECTION = "libs/multimedia"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=ed055b4eff93da784176a01582e6ec1a"
+DEPENDS = "alsa-lib"
+
+SRC_URI = "ftp://ftp.alsa-project.org/pub/oss-lib/alsa-oss-${PV}.tar.bz2 \
+    file://libio.patch \
+"
+SRC_URI[md5sum] = "fc845cafc4444193510ab1865c7350b8"
+SRC_URI[sha256sum] = "c3d3f743e61f05ff95c5cba3b06bc9c91ff86c37495f1d19dab844e6b90845ea"
+
+inherit autotools
+
+LEAD_SONAME = "libaoss.so.0"
+
+do_configure_prepend () {
+    touch NEWS README AUTHORS ChangeLog
+    sed -i "s/libaoss.so/${LEAD_SONAME}/" ${S}/alsa/aoss.in
+}
+
+# http://errors.yoctoproject.org/Errors/Details/186961/
+EXCLUDE_FROM_WORLD_libc-musl = "1"
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/faad2/faad2_2.7.bb b/meta-openembedded/meta-oe/recipes-multimedia/faad2/faad2_2.7.bb
index 63e590c..9e5a381 100644
--- a/meta-openembedded/meta-oe/recipes-multimedia/faad2/faad2_2.7.bb
+++ b/meta-openembedded/meta-oe/recipes-multimedia/faad2/faad2_2.7.bb
@@ -1,9 +1,12 @@
-SUMMARY = "Library for reading some sort of media format"
+SUMMARY = "An open source MPEG-4 and MPEG-2 AAC decoding library"
+HOMEPAGE = "http://www.audiocoding.com/faad2.html"
 SECTION = "libs"
 LICENSE = "GPLv2"
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=381c8cbe277a7bc1ee2ae6083a04c958"
 
+LICENSE_FLAGS = "commercial"
+
 PR = "r1"
 
 inherit autotools
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/jack/jack/0001-Python-3.7-fixes-2126.patch b/meta-openembedded/meta-oe/recipes-multimedia/jack/jack/0001-Python-3.7-fixes-2126.patch
new file mode 100644
index 0000000..e6021cd
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-multimedia/jack/jack/0001-Python-3.7-fixes-2126.patch
@@ -0,0 +1,26 @@
+From 72564b04151b61fa8d954bbb43afc58108ee50ec Mon Sep 17 00:00:00 2001
+From: Thomas Nagy <tnagy@waf.io>
+Date: Mon, 12 Mar 2018 20:42:55 +0100
+Subject: [PATCH] Python 3.7 fixes #2126
+
+Upstream-Status: Backport
+[https://gitlab.com/ita1024/waf/commit/facdc0b173d933073832c768ec1917c553cb369c]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ waflib/Node.py | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/waflib/Node.py b/waflib/Node.py
+index fb3cd273..405a6fec 100644
+--- a/waflib/Node.py
++++ b/waflib/Node.py
+@@ -537,8 +537,6 @@ class Node(object):
+ 					if maxdepth:
+ 						for k in node.ant_iter(accept=accept, maxdepth=maxdepth - 1, pats=npats, dir=dir, src=src, remove=remove):
+ 							yield k
+-		raise StopIteration
+-
+ 	def ant_glob(self, *k, **kw):
+ 		"""
+ 		This method is used for finding files across folders. It behaves like ant patterns:
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/jack/jack_git.bb b/meta-openembedded/meta-oe/recipes-multimedia/jack/jack_git.bb
index 11da6b1..52559cb 100644
--- a/meta-openembedded/meta-oe/recipes-multimedia/jack/jack_git.bb
+++ b/meta-openembedded/meta-oe/recipes-multimedia/jack/jack_git.bb
@@ -14,7 +14,9 @@
 
 DEPENDS = "libsamplerate0 libsndfile1 readline"
 
-SRC_URI = "git://github.com/jackaudio/jack2.git"
+SRC_URI = "git://github.com/jackaudio/jack2.git \
+           file://0001-Python-3.7-fixes-2126.patch \
+           "
 SRCREV = "c1647819eed6d11f94b21981d9c869629299f357"
 PV = "1.9.12"
 S = "${WORKDIR}/git"
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/libmms/libmms_0.6.4.bb b/meta-openembedded/meta-oe/recipes-multimedia/libmms/libmms_0.6.4.bb
index 831394e..668afc8 100644
--- a/meta-openembedded/meta-oe/recipes-multimedia/libmms/libmms_0.6.4.bb
+++ b/meta-openembedded/meta-oe/recipes-multimedia/libmms/libmms_0.6.4.bb
@@ -10,3 +10,11 @@
 SRC_URI[sha256sum] = "3c05e05aebcbfcc044d9e8c2d4646cd8359be39a3f0ba8ce4e72a9094bee704f"
 
 inherit autotools pkgconfig
+
+do_install_append() {
+    # The GLib dependency was removed in libmms 0.6.3, but the
+    # "Requires" was not removed from the pkg-config file.  Since we
+    # don't have (and don't want) the RDEPENDS on GLib, we should
+    # remove the "Requires" line.
+    sed -i '/^Requires: glib-2\.0$/d' ${D}${libdir}/pkgconfig/libmms.pc
+}
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/libopus/libopus_1.1.3.bb b/meta-openembedded/meta-oe/recipes-multimedia/libopus/libopus_1.1.3.bb
index a24f5e3..dd6789d 100644
--- a/meta-openembedded/meta-oe/recipes-multimedia/libopus/libopus_1.1.3.bb
+++ b/meta-openembedded/meta-oe/recipes-multimedia/libopus/libopus_1.1.3.bb
@@ -50,3 +50,5 @@
 #| {standard input}:773: Error: selected processor does not support Thumb mode `smull fp,r3,r5,r8'
 #| make[2]: *** [celt/celt.lo] Error 1
 ARM_INSTRUCTION_SET = "arm"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/libsdl-image/libsdl2-image_2.0.1.bb b/meta-openembedded/meta-oe/recipes-multimedia/libsdl-image/libsdl2-image_2.0.1.bb
deleted file mode 100644
index 1f9c794..0000000
--- a/meta-openembedded/meta-oe/recipes-multimedia/libsdl-image/libsdl2-image_2.0.1.bb
+++ /dev/null
@@ -1,31 +0,0 @@
-SUMMARY = "Simple DirectMedia Layer image library v2"
-SECTION = "libs"
-
-LICENSE = "Zlib"
-LIC_FILES_CHKSUM = "file://COPYING.txt;md5=ec65b9778f5584a0bd8dfc17d6340ba0"
-
-DEPENDS = "tiff zlib libpng jpeg virtual/libsdl2 libwebp"
-
-SRC_URI = "http://www.libsdl.org/projects/SDL_image/release/SDL2_image-${PV}.tar.gz"
-SRC_URI[md5sum] = "d94b94555ba022fa249a53a021dc3606"
-SRC_URI[sha256sum] = "3a3eafbceea5125c04be585373bfd8b3a18f259bd7eae3efc4e6d8e60e0d7f64"
-
-S = "${WORKDIR}/SDL2_image-${PV}"
-
-inherit autotools pkgconfig
-
-# Disable the run-time loading of the libs and bring back the soname dependencies.
-EXTRA_OECONF += "--disable-jpg-shared --disable-png-shared -disable-tif-shared"
-
-do_configure_prepend() {
-    # make autoreconf happy
-    touch ${S}/NEWS ${S}/README ${S}/AUTHORS ${S}/ChangeLog
-    # Removing these files fixes a libtool version mismatch.
-    rm -f ${S}/acinclude/libtool.m4
-    rm -f ${S}/acinclude/sdl2.m4
-    rm -f ${S}/acinclude/pkg.m4
-    rm -f ${S}/acinclude/lt~obsolete.m4
-    rm -f ${S}/acinclude/ltoptions.m4
-    rm -f ${S}/acinclude/ltsugar.m4
-    rm -f ${S}/acinclude/ltversion.m4
-}
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/mplayer/mpv_0.26.0.bb b/meta-openembedded/meta-oe/recipes-multimedia/mplayer/mpv_0.26.0.bb
index de78de2..c2e8e3d 100644
--- a/meta-openembedded/meta-oe/recipes-multimedia/mplayer/mpv_0.26.0.bb
+++ b/meta-openembedded/meta-oe/recipes-multimedia/mplayer/mpv_0.26.0.bb
@@ -31,6 +31,8 @@
     libass \
     ${@bb.utils.filter('DISTRO_FEATURES', 'wayland', d)} \
 "
+
+PACKAGECONFIG_remove_aarch64 = "lua"
 PACKAGECONFIG[drm] = "--enable-drm,--disable-drm,libdrm"
 PACKAGECONFIG[gbm] = "--enable-gbm,--disable-gbm,virtual/mesa"
 PACKAGECONFIG[lua] = "--enable-lua,--disable-lua,lua luajit"
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils/0001-buildsystem-do-not-assume-building-in-source-tree.patch b/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils/0001-buildsystem-do-not-assume-building-in-source-tree.patch
deleted file mode 100644
index 12609d3..0000000
--- a/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils/0001-buildsystem-do-not-assume-building-in-source-tree.patch
+++ /dev/null
@@ -1,108 +0,0 @@
-From 75372b8088c20474497b79ec6cf1e99f2d17f56d Mon Sep 17 00:00:00 2001
-From: Ismo Puustinen <ismo.puustinen@intel.com>
-Date: Mon, 3 Apr 2017 13:23:38 +0300
-Subject: [PATCH] buildsystem: do not assume building in source tree.
-
-Use $(top_srcdir) as reference for include paths and buildtime scripts.
-Otherwise compilation outside of project root directory will fail
-because header and script paths are wrong.
-
-To reproduce: mkdir b; cd b; ../configure; make
-
-Upstream-status: Accepted [https://git.linuxtv.org//v4l-utils.git/commit/?id=bd98c9a99bffc8d44c54859345e4dfee0ada4275]
-
-Signed-off-by: Ismo Puustinen <ismo.puustinen@intel.com>
-
----
- utils/cec-compliance/Makefile.am  | 2 +-
- utils/cec-ctl/Makefile.am         | 2 +-
- utils/cec-follower/Makefile.am    | 4 ++--
- utils/qv4l2/Makefile.am           | 2 +-
- utils/v4l2-compliance/Makefile.am | 2 +-
- utils/v4l2-ctl/Makefile.am        | 2 +-
- 6 files changed, 7 insertions(+), 7 deletions(-)
-
-diff --git a/utils/cec-compliance/Makefile.am b/utils/cec-compliance/Makefile.am
-index f05fe6c..f7d1535 100644
---- a/utils/cec-compliance/Makefile.am
-+++ b/utils/cec-compliance/Makefile.am
-@@ -7,7 +7,7 @@ cec_compliance_LDFLAGS = -lrt
- cec-compliance.cpp: cec-table.h
- 
- cec-table.h: ../cec-ctl/msg2ctl.pl ../../include/linux/cec.h ../../include/linux/cec-funcs.h
--	../cec-ctl/msg2ctl.pl 2 ../../include/linux/cec.h ../../include/linux/cec-funcs.h >$@
-+	$(top_srcdir)/utils/cec-ctl/msg2ctl.pl 2 $(top_srcdir)/include/linux/cec.h $(top_srcdir)/include/linux/cec-funcs.h >$@
- 
- cec-compliance.cpp: version.h
- 
-diff --git a/utils/cec-ctl/Makefile.am b/utils/cec-ctl/Makefile.am
-index 4a6eae5..570a070 100644
---- a/utils/cec-ctl/Makefile.am
-+++ b/utils/cec-ctl/Makefile.am
-@@ -6,7 +6,7 @@ cec_ctl_SOURCES = cec-ctl.cpp
- cec-ctl.cpp: cec-ctl-gen.h
- 
- cec-ctl-gen.h: msg2ctl.pl ../../include/linux/cec.h ../../include/linux/cec-funcs.h
--	./msg2ctl.pl 0 ../../include/linux/cec.h ../../include/linux/cec-funcs.h >$@
-+	$(top_srcdir)/utils/cec-ctl/msg2ctl.pl 0 $(top_srcdir)/include/linux/cec.h $(top_srcdir)/include/linux/cec-funcs.h >$@
- 
- clean-local:
- 	-rm -vf cec-ctl-gen.h
-diff --git a/utils/cec-follower/Makefile.am b/utils/cec-follower/Makefile.am
-index d8ad292..e3553eb 100644
---- a/utils/cec-follower/Makefile.am
-+++ b/utils/cec-follower/Makefile.am
-@@ -7,12 +7,12 @@ cec_follower_LDFLAGS = -lrt
- cec-log.cpp: cec-log.h
- 
- cec-log.h: ../cec-ctl/msg2ctl.pl ../../include/linux/cec.h ../../include/linux/cec-funcs.h
--	../cec-ctl/msg2ctl.pl 1 ../../include/linux/cec.h ../../include/linux/cec-funcs.h >$@
-+	$(top_srcdir)/utils/cec-ctl/msg2ctl.pl 1 $(top_srcdir)/include/linux/cec.h $(top_srcdir)/include/linux/cec-funcs.h >$@
- 
- cec-follower.cpp: cec-table.h version.h
- 
- cec-table.h: ../cec-ctl/msg2ctl.pl ../../include/linux/cec.h ../../include/linux/cec-funcs.h
--	../cec-ctl/msg2ctl.pl 2 ../../include/linux/cec.h ../../include/linux/cec-funcs.h >$@
-+	$(top_srcdir)/utils/cec-ctl/msg2ctl.pl 2 $(top_srcdir)/include/linux/cec.h $(top_srcdir)/include/linux/cec-funcs.h >$@
- 
- version.h:
- 	@if git show-ref -s HEAD >/dev/null 2>&1; then \
-diff --git a/utils/qv4l2/Makefile.am b/utils/qv4l2/Makefile.am
-index fd58486..ccd1a2a 100644
---- a/utils/qv4l2/Makefile.am
-+++ b/utils/qv4l2/Makefile.am
-@@ -8,7 +8,7 @@ qv4l2_SOURCES = qv4l2.cpp general-tab.cpp ctrl-tab.cpp vbi-tab.cpp capture-win.c
- nodist_qv4l2_SOURCES = moc_qv4l2.cpp moc_general-tab.cpp moc_capture-win.cpp moc_vbi-tab.cpp qrc_qv4l2.cpp
- qv4l2_LDADD = ../../lib/libv4l2/libv4l2.la ../../lib/libv4lconvert/libv4lconvert.la \
-   ../libv4l2util/libv4l2util.la ../libmedia_dev/libmedia_dev.la
--qv4l2_CPPFLAGS = -I../common
-+qv4l2_CPPFLAGS = -I$(top_srcdir)/utils/common
- 
- if WITH_QTGL
- qv4l2_CPPFLAGS += $(QTGL_CFLAGS)
-diff --git a/utils/v4l2-compliance/Makefile.am b/utils/v4l2-compliance/Makefile.am
-index c2b5919..fb8d12e 100644
---- a/utils/v4l2-compliance/Makefile.am
-+++ b/utils/v4l2-compliance/Makefile.am
-@@ -5,7 +5,7 @@ DEFS :=
- v4l2_compliance_SOURCES = v4l2-compliance.cpp v4l2-test-debug.cpp v4l2-test-input-output.cpp \
- 	v4l2-test-controls.cpp v4l2-test-io-config.cpp v4l2-test-formats.cpp v4l2-test-buffers.cpp \
- 	v4l2-test-codecs.cpp v4l2-test-colors.cpp v4l2-compliance.h
--v4l2_compliance_CPPFLAGS = -I../common
-+v4l2_compliance_CPPFLAGS = -I$(top_srcdir)/utils/common
- 
- if WITH_V4L2_COMPLIANCE_LIBV4L
- v4l2_compliance_LDADD = ../../lib/libv4l2/libv4l2.la ../../lib/libv4lconvert/libv4lconvert.la -lrt -lpthread
-diff --git a/utils/v4l2-ctl/Makefile.am b/utils/v4l2-ctl/Makefile.am
-index 955647d..825e53f 100644
---- a/utils/v4l2-ctl/Makefile.am
-+++ b/utils/v4l2-ctl/Makefile.am
-@@ -7,7 +7,7 @@ v4l2_ctl_SOURCES = v4l2-ctl.cpp v4l2-ctl.h v4l2-ctl-common.cpp v4l2-ctl-tuner.cp
- 	v4l2-ctl-overlay.cpp v4l2-ctl-vbi.cpp v4l2-ctl-selection.cpp v4l2-ctl-misc.cpp \
- 	v4l2-ctl-streaming.cpp v4l2-ctl-sdr.cpp v4l2-ctl-edid.cpp v4l2-ctl-modes.cpp \
- 	v4l2-tpg-colors.c v4l2-tpg-core.c v4l-stream.c
--v4l2_ctl_CPPFLAGS = -I../common
-+v4l2_ctl_CPPFLAGS = -I$(top_srcdir)/utils/common
- 
- if WITH_V4L2_CTL_LIBV4L
- v4l2_ctl_LDADD = ../../lib/libv4l2/libv4l2.la ../../lib/libv4lconvert/libv4lconvert.la -lrt -lpthread
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils/0001-ir-ctl-Define-TEMP_FAILURE_RETRY-if-undefined.patch b/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils/0001-ir-ctl-Define-TEMP_FAILURE_RETRY-if-undefined.patch
deleted file mode 100644
index 82fc3e1..0000000
--- a/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils/0001-ir-ctl-Define-TEMP_FAILURE_RETRY-if-undefined.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-From b2efcc20617d6317f74c4acb2a6af5b765f20b34 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 14 Jul 2017 13:11:25 -0700
-Subject: [PATCH] ir-ctl: Define TEMP_FAILURE_RETRY if undefined
-
-use strndup() instead of strndupa() which is not
-universally available in C libraries
-
-Taken from AlpineLinux
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
----
- utils/ir-ctl/ir-ctl.c | 14 +++++++++++++-
- 1 file changed, 13 insertions(+), 1 deletion(-)
-
-diff --git a/utils/ir-ctl/ir-ctl.c b/utils/ir-ctl/ir-ctl.c
-index bc58cee..1a44011 100644
---- a/utils/ir-ctl/ir-ctl.c
-+++ b/utils/ir-ctl/ir-ctl.c
-@@ -42,6 +42,16 @@
- # define _(string) string
- #endif
- 
-+/* taken from glibc unistd.h */
-+#ifndef TEMP_FAILURE_RETRY
-+#define TEMP_FAILURE_RETRY(expression) \
-+  (__extension__                                                              \
-+    ({ long int __result;                                                     \
-+       do __result = (long int) (expression);                                 \
-+       while (__result == -1L && errno == EINTR);                             \
-+       __result; }))
-+#endif
-+
- # define N_(string) string
- 
- 
-@@ -344,12 +354,14 @@ static struct file *read_scancode(const char *name)
- 		return NULL;
- 	}
- 
--	pstr = strndupa(name, p - name);
-+	pstr = strndup(name, p - name);
- 
- 	if (!protocol_match(pstr, &proto)) {
- 		fprintf(stderr, _("error: protocol '%s' not found\n"), pstr);
-+		free(pstr);
- 		return NULL;
- 	}
-+	free(pstr);
- 
- 	if (!strtoscancode(p + 1, &scancode)) {
- 		fprintf(stderr, _("error: invalid scancode '%s'\n"), p + 1);
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils/0002-contrib-test-Link-mc_nextgen_test-with-libargp-if-ne.patch b/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils/0002-contrib-test-Link-mc_nextgen_test-with-libargp-if-ne.patch
index a779a30..8033fca 100644
--- a/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils/0002-contrib-test-Link-mc_nextgen_test-with-libargp-if-ne.patch
+++ b/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils/0002-contrib-test-Link-mc_nextgen_test-with-libargp-if-ne.patch
@@ -6,17 +6,16 @@
 musl depends on external argp implementation e.g.
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
 ---
  contrib/test/Makefile.am | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/contrib/test/Makefile.am b/contrib/test/Makefile.am
-index 4641e21..e47b948 100644
+index 0188fe2..dac07f3 100644
 --- a/contrib/test/Makefile.am
 +++ b/contrib/test/Makefile.am
-@@ -32,7 +32,7 @@ v4l2gl_LDFLAGS = $(X11_LIBS) $(GL_LIBS) $(GLU_LIBS) $(ARGP_LIBS)
- v4l2gl_LDADD = ../../lib/libv4l2/libv4l2.la ../../lib/libv4lconvert/libv4lconvert.la
+@@ -40,7 +40,7 @@ sdlcam_CFLAGS = -I../.. $(SDL2_CFLAGS)
+ sdlcam_LDADD = ../../lib/libv4l2/libv4l2.la  ../../lib/libv4lconvert/libv4lconvert.la
  
  mc_nextgen_test_CFLAGS = $(LIBUDEV_CFLAGS)
 -mc_nextgen_test_LDFLAGS = $(LIBUDEV_LIBS)
@@ -24,3 +23,6 @@
  
  
  ioctl_test_SOURCES = ioctl-test.c ioctl-test.h ioctl_32.h ioctl_64.h
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils_1.12.3.bb b/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils_1.12.3.bb
deleted file mode 100644
index 57cfb13..0000000
--- a/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils_1.12.3.bb
+++ /dev/null
@@ -1,55 +0,0 @@
-SUMMARY = "v4l2 and IR applications"
-LICENSE = "GPLv2 & LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=48da9957849056017dc568bbc43d8975 \
-                    file://COPYING.libv4l;md5=d749e86a105281d7a44c2328acebc4b0"
-PROVIDES = "libv4l media-ctl"
-
-DEPENDS = "jpeg \
-           ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'virtual/libx11', '', d)}"
-DEPENDS_append_libc-musl = " argp-standalone"
-DEPENDS_append_class-target = " udev"
-LDFLAGS_append = " -pthread"
-
-inherit autotools gettext pkgconfig
-
-PACKAGECONFIG ??= "media-ctl"
-PACKAGECONFIG[media-ctl] = "--enable-v4l-utils,--disable-v4l-utils,,"
-
-SRC_URI = "http://linuxtv.org/downloads/v4l-utils/v4l-utils-${PV}.tar.bz2 \
-           file://0001-Revert-media-ctl-Don-t-install-libmediactl-and-libv4.patch \
-           file://0001-buildsystem-do-not-assume-building-in-source-tree.patch \
-           file://mediactl-pkgconfig.patch \
-           file://export-mediactl-headers.patch \
-           file://0001-ir-ctl-Define-TEMP_FAILURE_RETRY-if-undefined.patch \
-           file://0002-contrib-test-Link-mc_nextgen_test-with-libargp-if-ne.patch \
-           file://0003-v4l2-ctl-Do-not-use-getsubopt.patch \
-           "
-SRC_URI[md5sum] = "89e1ed6c69c94e0489dc0a638c7841aa"
-SRC_URI[sha256sum] = "5a47dd6f0e7dfe902d94605c01d385a4a4e87583ff5856d6f181900ea81cf46e"
-
-EXTRA_OECONF = "--disable-qv4l2 --enable-shared --with-udevdir=${base_libdir}/udev"
-
-VIRTUAL-RUNTIME_ir-keytable-keymaps ?= "rc-keymaps"
-
-PACKAGES =+ "media-ctl ir-keytable rc-keymaps libv4l libv4l-dbg libv4l-dev"
-
-FILES_media-ctl = "${bindir}/media-ctl ${libdir}/libmediactl.so.*"
-
-FILES_ir-keytable = "${bindir}/ir-keytable ${base_libdir}/udev/rules.d/*-infrared.rules"
-RDEPENDS_ir-keytable += "${VIRTUAL-RUNTIME_ir-keytable-keymaps}"
-
-FILES_rc-keymaps = "${sysconfdir}/rc* ${base_libdir}/udev/rc*"
-
-FILES_${PN} = "${bindir} ${sbindir}"
-
-FILES_libv4l += "${libdir}/libv4l*${SOLIBS} ${libdir}/libv4l/*.so ${libdir}/libv4l/plugins/*.so \
-                 ${libdir}/libdvbv5*${SOLIBS} \
-                 ${libdir}/libv4l/*-decomp"
-
-FILES_libv4l-dbg += "${libdir}/libv4l/.debug ${libdir}/libv4l/plugins/.debug"
-FILES_libv4l-dev += "${includedir} ${libdir}/pkgconfig \
-                     ${libdir}/libv4l*${SOLIBSDEV} ${libdir}/*.la \
-                     ${libdir}/v4l*${SOLIBSDEV} ${libdir}/libv4l/*.la ${libdir}/libv4l/plugins/*.la"
-
-PARALLEL_MAKE_class-native = ""
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils_1.16.0.bb b/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils_1.16.0.bb
new file mode 100644
index 0000000..bcead00
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-multimedia/v4l2apps/v4l-utils_1.16.0.bb
@@ -0,0 +1,54 @@
+SUMMARY = "v4l2 and IR applications"
+LICENSE = "GPLv2 & LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=48da9957849056017dc568bbc43d8975 \
+                    file://COPYING.libv4l;md5=d749e86a105281d7a44c2328acebc4b0"
+PROVIDES = "libv4l media-ctl"
+
+DEPENDS = "jpeg \
+           ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'virtual/libx11', '', d)}"
+DEPENDS_append_libc-musl = " argp-standalone"
+DEPENDS_append_class-target = " udev"
+LDFLAGS_append = " -pthread"
+
+inherit autotools gettext pkgconfig
+
+PACKAGECONFIG ??= "media-ctl"
+PACKAGECONFIG[media-ctl] = "--enable-v4l-utils,--disable-v4l-utils,,"
+
+SRC_URI = "http://linuxtv.org/downloads/v4l-utils/v4l-utils-${PV}.tar.bz2 \
+           file://0001-Revert-media-ctl-Don-t-install-libmediactl-and-libv4.patch \
+           file://mediactl-pkgconfig.patch \
+           file://export-mediactl-headers.patch \
+           file://0002-contrib-test-Link-mc_nextgen_test-with-libargp-if-ne.patch \
+           file://0003-v4l2-ctl-Do-not-use-getsubopt.patch \
+           "
+SRC_URI[md5sum] = "21a6ec3605a1c3114c8ccb70a963c871"
+SRC_URI[sha256sum] = "f1b425584284bac378b76331c0671dc890bd7af49c03e8a6cc0c70e57eea0bad"
+
+EXTRA_OECONF = "--disable-qv4l2 --enable-shared --with-udevdir=${base_libdir}/udev"
+
+VIRTUAL-RUNTIME_ir-keytable-keymaps ?= "rc-keymaps"
+
+PACKAGES =+ "media-ctl ir-keytable rc-keymaps libv4l libv4l-dev"
+
+RPROVIDES_${PN}-dbg += "libv4l-dbg"
+
+FILES_media-ctl = "${bindir}/media-ctl ${libdir}/libmediactl.so.*"
+
+FILES_ir-keytable = "${bindir}/ir-keytable ${base_libdir}/udev/rules.d/*-infrared.rules"
+RDEPENDS_ir-keytable += "${VIRTUAL-RUNTIME_ir-keytable-keymaps}"
+
+FILES_rc-keymaps = "${sysconfdir}/rc* ${base_libdir}/udev/rc*"
+
+FILES_${PN} = "${bindir} ${sbindir}"
+
+FILES_libv4l += "${libdir}/libv4l*${SOLIBS} ${libdir}/libv4l/*.so ${libdir}/libv4l/plugins/*.so \
+                 ${libdir}/libdvbv5*${SOLIBS} \
+                 ${libdir}/libv4l/*-decomp"
+
+FILES_libv4l-dev += "${includedir} ${libdir}/pkgconfig \
+                     ${libdir}/libv4l*${SOLIBSDEV} ${libdir}/*.la \
+                     ${libdir}/v4l*${SOLIBSDEV} ${libdir}/libv4l/*.la ${libdir}/libv4l/plugins/*.la"
+
+PARALLEL_MAKE_class-native = ""
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-navigation/gpsd/gpsd_3.17.bb b/meta-openembedded/meta-oe/recipes-navigation/gpsd/gpsd_3.17.bb
index d526db2..e823e42 100644
--- a/meta-openembedded/meta-oe/recipes-navigation/gpsd/gpsd_3.17.bb
+++ b/meta-openembedded/meta-oe/recipes-navigation/gpsd/gpsd_3.17.bb
@@ -84,13 +84,13 @@
     install -m 0644 ${S}/systemd/${BPN}.socket ${D}${systemd_unitdir}/system/${BPN}.socket
 }
 
-PACKAGES =+ "libgps libgpsd python-pygps-dbg python-pygps gpsd-udev gpsd-conf gpsd-gpsctl gps-utils"
+PACKAGES =+ "libgps libgpsd python-pygps gpsd-udev gpsd-conf gpsd-gpsctl gps-utils"
+
+RPROVIDES_${PN}-dbg += "python-pygps-dbg"
 
 FILES_${PN}-dev += "${libdir}/pkgconfdir/libgpsd.pc ${libdir}/pkgconfdir/libgps.pc \
                     ${libdir}/libQgpsmm.prl"
 
-FILES_python-pygps-dbg += " ${libdir}/python*/site-packages/gps/.debug"
-
 RDEPENDS_${PN} = "gpsd-gpsctl"
 RRECOMMENDS_${PN} = "gpsd-conf gpsd-udev gpsd-machine-conf"
 
diff --git a/meta-security/recipes-security/nmap/files/nmap-redefine-the-python-library-dir.patch b/meta-openembedded/meta-oe/recipes-security/nmap/files/nmap-redefine-the-python-library-dir.patch
similarity index 100%
rename from meta-security/recipes-security/nmap/files/nmap-redefine-the-python-library-dir.patch
rename to meta-openembedded/meta-oe/recipes-security/nmap/files/nmap-redefine-the-python-library-dir.patch
diff --git a/meta-security/recipes-security/nmap/files/nmap-replace-shtool-mkdir-with-coreutils-mkdir-command.patch b/meta-openembedded/meta-oe/recipes-security/nmap/files/nmap-replace-shtool-mkdir-with-coreutils-mkdir-command.patch
similarity index 100%
rename from meta-security/recipes-security/nmap/files/nmap-replace-shtool-mkdir-with-coreutils-mkdir-command.patch
rename to meta-openembedded/meta-oe/recipes-security/nmap/files/nmap-replace-shtool-mkdir-with-coreutils-mkdir-command.patch
diff --git a/meta-openembedded/meta-oe/recipes-security/nmap/nmap_7.70.bb b/meta-openembedded/meta-oe/recipes-security/nmap/nmap_7.70.bb
new file mode 100644
index 0000000..01be151
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-security/nmap/nmap_7.70.bb
@@ -0,0 +1,48 @@
+SUMMARY = "network auditing tool"
+DESCRIPTION = "Nmap ("Network Mapper") is a free and open source (license) utility for network discovery and security auditing.\nGui support via appending to IMAGE_FEATURES x11-base in local.conf"
+SECTION = "security"
+LICENSE = "GPL-2.0"
+
+LIC_FILES_CHKSUM = "file://COPYING;beginline=7;endline=12;md5=1489288f46af415fadc4e8b6345ab9f4"
+
+SRC_URI = "http://nmap.org/dist/${BP}.tar.bz2 \
+           file://nmap-redefine-the-python-library-dir.patch \
+           file://nmap-replace-shtool-mkdir-with-coreutils-mkdir-command.patch \
+"
+
+SRC_URI[md5sum] = "84eb6fbe788e0d4918c2b1e39421bf79"
+SRC_URI[sha256sum] = "847b068955f792f4cc247593aca6dc3dc4aae12976169873247488de147a6e18"
+
+inherit autotools-brokensep pkgconfig pythonnative
+
+PACKAGECONFIG ?= "ncat nping ndiff pcap"
+
+PACKAGECONFIG[pcap] = "--with-pcap=linux, --without-pcap, libpcap, libpcap"
+PACKAGECONFIG[pcre] = "--with-libpcre=${STAGING_LIBDIR}/.., --with-libpcre=included, libpre"
+PACKAGECONFIG[ssl] = "--with-openssl=${STAGING_LIBDIR}/.., --without-openssl, openssl, openssl"
+PACKAGECONFIG[ssh2] = "--with-openssh2=${STAGING_LIBDIR}/.., --without-openssh2, libssh2, libssh2"
+PACKAGECONFIG[libz] = "--with-libz=${STAGING_LIBDIR}/.., --without-libz, zlib, zlib"
+
+#disable/enable packages
+PACKAGECONFIG[nping] = ",--without-nping,"
+PACKAGECONFIG[ncat] = ",--without-ncat,"
+PACKAGECONFIG[ndiff] = ",--without-ndiff,python"
+PACKAGECONFIG[update] = ",--without-nmap-update,"
+
+EXTRA_OECONF = "--with-libdnet=included --with-liblinear=included --without-subversion --with-liblua=included"
+
+# zenmap needs python-pygtk which has been removed
+# it also only works with python2
+# disable for now until py3 is supported
+EXTRA_OECONF += "--without-zenmap"
+
+export PYTHON_SITEPACKAGES_DIR
+
+do_configure() {
+    autoconf
+    oe_runconf
+}
+
+FILES_${PN} += "${PYTHON_SITEPACKAGES_DIR}"
+
+RDEPENDS_${PN} = "python"
diff --git a/meta-openembedded/meta-oe/recipes-shells/tcsh/tcsh_6.20.00.bb b/meta-openembedded/meta-oe/recipes-shells/tcsh/tcsh_6.20.00.bb
index b59d88f..c171963 100644
--- a/meta-openembedded/meta-oe/recipes-shells/tcsh/tcsh_6.20.00.bb
+++ b/meta-openembedded/meta-oe/recipes-shells/tcsh/tcsh_6.20.00.bb
@@ -7,7 +7,7 @@
 LICENSE = "BSD-3-Clause"
 LIC_FILES_CHKSUM = "file://Copyright;md5=575cf2715c3bf894e1f79aec1d4eaaf5"
 SECTION = "base"
-DEPENDS = "ncurses gettext-native"
+DEPENDS = "ncurses virtual/crypt gettext-native"
 SRC_URI = " \
     http://ftp.funet.fi/pub/mirrors/ftp.astron.com/pub/tcsh/${BP}.tar.gz \
     file://0001-Enable-system-malloc-on-all-linux.patch \
diff --git a/meta-openembedded/meta-oe/recipes-shells/zsh/zsh_5.4.2.bb b/meta-openembedded/meta-oe/recipes-shells/zsh/zsh_5.4.2.bb
index 100c449..3aab65b 100644
--- a/meta-openembedded/meta-oe/recipes-shells/zsh/zsh_5.4.2.bb
+++ b/meta-openembedded/meta-oe/recipes-shells/zsh/zsh_5.4.2.bb
@@ -49,6 +49,7 @@
 
 do_install_append () {
     rm -fr ${D}/usr/share
+    rmdir --ignore-fail-on-non-empty ${D}/usr
 }
 
 pkg_postinst_${PN} () {
diff --git a/meta-openembedded/meta-oe/recipes-support/asio/asio.inc b/meta-openembedded/meta-oe/recipes-support/asio/asio.inc
deleted file mode 100644
index 54f78e4..0000000
--- a/meta-openembedded/meta-oe/recipes-support/asio/asio.inc
+++ /dev/null
@@ -1,15 +0,0 @@
-DESCRIPTION = "Asio is a cross-platform C++ library for network and low-level \
-        I/O programming that provides developers with a consistent asynchronous \
-        model using a modern C++ approach."
-AUTHOR = "Christopher M. Kohlhoff (chris at kohlhoff dot com)"
-HOMEPAGE = "http://think-async.com/Asio"
-SECTION = "libs"
-LICENSE = "BSL-1.0"
-
-DEPENDS = "boost openssl"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/asio/${BP}.tar.bz2"
-
-inherit autotools
-
-ALLOW_EMPTY_${PN} = "1"
diff --git a/meta-openembedded/meta-oe/recipes-support/asio/asio/0001-Automatically-handle-glibc-variant-of-strerror_r-wit.patch b/meta-openembedded/meta-oe/recipes-support/asio/asio/0001-Automatically-handle-glibc-variant-of-strerror_r-wit.patch
deleted file mode 100644
index 4244b97..0000000
--- a/meta-openembedded/meta-oe/recipes-support/asio/asio/0001-Automatically-handle-glibc-variant-of-strerror_r-wit.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-From 45c855400842fd40f200ae9b7abf9debf4ab5436 Mon Sep 17 00:00:00 2001
-From: Christopher Kohlhoff <chris@kohlhoff.com>
-Date: Sun, 28 Aug 2016 09:21:53 +1000
-Subject: [PATCH] Automatically handle glibc variant of strerror_r without
- #ifdefs.
-
----
-Upstream-Status: Backport https://github.com/chriskohlhoff/asio/commit/443bc17d13eb5e37de780ea6e23157493cf7b3b9
- include/asio/impl/error_code.ipp | 16 +++++++---------
- 1 file changed, 7 insertions(+), 9 deletions(-)
-
-diff --git a/include/asio/impl/error_code.ipp b/include/asio/impl/error_code.ipp
-index ccb70dd..a117658 100644
---- a/include/asio/impl/error_code.ipp
-+++ b/include/asio/impl/error_code.ipp
-@@ -97,20 +97,18 @@ public:
- #if defined(__sun) || defined(__QNX__) || defined(__SYMBIAN32__)
-     using namespace std;
-     return strerror(value);
--#elif defined(__MACH__) && defined(__APPLE__) \
--  || defined(__NetBSD__) || defined(__FreeBSD__) || defined(__OpenBSD__) \
--  || defined(_AIX) || defined(__hpux) || defined(__osf__) \
--  || defined(__ANDROID__)
--    char buf[256] = "";
--    using namespace std;
--    strerror_r(value, buf, sizeof(buf));
--    return buf;
- #else
-     char buf[256] = "";
--    return strerror_r(value, buf, sizeof(buf));
-+    using namespace std;
-+    return strerror_result(strerror_r(value, buf, sizeof(buf)), buf);
- #endif
- #endif // defined(ASIO_WINDOWS)
-   }
-+
-+private:
-+  // Helper function to adapt the result from glibc's variant of strerror_r.
-+  static const char* strerror_result(int, const char* s) { return s; }
-+  static const char* strerror_result(const char* s, const char*) { return s; }
- };
- 
- } // namespace detail
--- 
-2.9.3
-
diff --git a/meta-openembedded/meta-oe/recipes-support/asio/asio/0001-use-POSIX-poll.h-instead-of-sys-poll.h.patch b/meta-openembedded/meta-oe/recipes-support/asio/asio/0001-use-POSIX-poll.h-instead-of-sys-poll.h.patch
deleted file mode 100644
index 7f95f5a..0000000
--- a/meta-openembedded/meta-oe/recipes-support/asio/asio/0001-use-POSIX-poll.h-instead-of-sys-poll.h.patch
+++ /dev/null
@@ -1,64 +0,0 @@
-From dac36a170188917e2f61b0394ba8a2f6509ddf3a Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Andr=C3=A9=20Draszik?= <adraszik@tycoint.com>
-Date: Tue, 8 Nov 2016 20:39:55 +0000
-Subject: [PATCH] use POSIX poll.h instead of sys/poll.h
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-POSIX specifies that <poll.h> is the correct header to
-include for poll()
-  http://pubs.opengroup.org/onlinepubs/009695399/functions/poll.html
-whereas <sys/poll.h> is only needed for ancient glibc (<2.3),
-so let's follow POSIX instead.
-
-As a side-effect, this silences numerous compilation warnings
-when compiling against the musl C-library:
-
-In file included from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/detail/socket_types.hpp:57:0,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/impl/error_code.ipp:29,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/error_code.hpp:185,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/detail/throw_error.hpp:19,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/detail/impl/posix_tss_ptr.ipp:23,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/detail/posix_tss_ptr.hpp:74,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/detail/tss_ptr.hpp:27,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/detail/call_stack.hpp:20,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/impl/handler_alloc_hook.ipp:19,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/handler_alloc_hook.hpp:78,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/detail/handler_alloc_helpers.hpp:21,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/detail/bind_handler.hpp:19,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/detail/wrapped_handler.hpp:18,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/io_service.hpp:24,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/basic_io_object.hpp:19,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/basic_socket.hpp:20,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio/basic_datagram_socket.hpp:20,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/../../../include/asio.hpp:19,
-                 from ../../../../asio-1.10.6/src/examples/cpp03/buffers/reference_counted.cpp:11:
-<sysroot>/usr/include/sys/poll.h:1:2: warning: #warning redirecting incorrect #include <sys/poll.h> to <poll.h> [-Wcpp]
- #warning redirecting incorrect #include <sys/poll.h> to <poll.h>
-  ^~~~~~~
-
-etc.
-
-Signed-off-by: André Draszik <adraszik@tycoint.com>
----
-Upstream-Status: Submitted https://svn.boost.org/trac/boost/ticket/12419
- include/asio/detail/socket_types.hpp | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/include/asio/detail/socket_types.hpp b/include/asio/detail/socket_types.hpp
-index f2600c2..cb61b8e 100644
---- a/include/asio/detail/socket_types.hpp
-+++ b/include/asio/detail/socket_types.hpp
-@@ -54,7 +54,7 @@
- #else
- # include <sys/ioctl.h>
- # if !defined(__SYMBIAN32__)
--#  include <sys/poll.h>
-+#  include <poll.h>
- # endif
- # include <sys/types.h>
- # include <sys/stat.h>
--- 
-2.10.2
-
diff --git a/meta-openembedded/meta-oe/recipes-support/asio/asio_1.10.6.bb b/meta-openembedded/meta-oe/recipes-support/asio/asio_1.10.6.bb
deleted file mode 100644
index 5656039..0000000
--- a/meta-openembedded/meta-oe/recipes-support/asio/asio_1.10.6.bb
+++ /dev/null
@@ -1,11 +0,0 @@
-require asio.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=fede5286a78559dd646e355ab0cc8f04"
-
-SRC_URI[md5sum] = "85d014a356a6e004cd30ccd4c9b6a5c2"
-SRC_URI[sha256sum] = "e0d71c40a7b1f6c1334008fb279e7361b32a063e020efd21e40d9d8ff037195e"
-
-SRC_URI += "\
-    file://0001-Automatically-handle-glibc-variant-of-strerror_r-wit.patch \
-    file://0001-use-POSIX-poll.h-instead-of-sys-poll.h.patch \
-"
diff --git a/meta-openembedded/meta-oe/recipes-support/asio/asio_1.12.1.bb b/meta-openembedded/meta-oe/recipes-support/asio/asio_1.12.1.bb
new file mode 100644
index 0000000..28cd9c0
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/asio/asio_1.12.1.bb
@@ -0,0 +1,22 @@
+DESCRIPTION = "Asio is a cross-platform C++ library for network and low-level \
+        I/O programming that provides developers with a consistent asynchronous \
+        model using a modern C++ approach."
+AUTHOR = "Christopher M. Kohlhoff (chris at kohlhoff dot com)"
+HOMEPAGE = "http://think-async.com/Asio"
+SECTION = "libs"
+LICENSE = "BSL-1.0"
+
+DEPENDS = "boost openssl"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/asio/${BP}.tar.bz2"
+
+inherit autotools
+
+ALLOW_EMPTY_${PN} = "1"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=3e73f311a3af69e6df275e8c3b1c09b5"
+
+SRC_URI[md5sum] = "037854d113024f57c9753d6326b339bc"
+SRC_URI[sha256sum] = "a9091b4de847539fa5b2259bf76a5355339c7eaaa5e33d7d4ae74d614c21965a"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/asio/${BP}.tar.bz2"
diff --git a/meta-openembedded/meta-oe/recipes-support/atop/atop/0001-add-sys-sysmacros.h-for-major-minor-macros.patch b/meta-openembedded/meta-oe/recipes-support/atop/atop/0001-add-sys-sysmacros.h-for-major-minor-macros.patch
new file mode 100644
index 0000000..5646061
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/atop/atop/0001-add-sys-sysmacros.h-for-major-minor-macros.patch
@@ -0,0 +1,26 @@
+From 13f3771655f859d5e0332dd65b9c43f572f6359d Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 11 Aug 2018 16:02:06 -0700
+Subject: [PATCH] add sys/sysmacros.h for major/minor macros
+
+photosyst.c:1465:19: error: called object 'major' is not a function or function pointer
+     dmp->major  = major(statbuf.st_rdev);
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ photosyst.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/photosyst.c b/photosyst.c
+index 38828ec..caed352 100644
+--- a/photosyst.c
++++ b/photosyst.c
+@@ -152,6 +152,7 @@
+ static const char rcsid[] = "$Id: photosyst.c,v 1.38 2010/11/19 07:40:40 gerlof Exp $";
+ 
+ #include <sys/types.h>
++#include <sys/sysmacros.h>
+ #include <stdio.h>
+ #include <string.h>
+ #include <unistd.h>
diff --git a/meta-openembedded/meta-oe/recipes-support/atop/atop/0001-include-missing-header-files.patch b/meta-openembedded/meta-oe/recipes-support/atop/atop/0001-include-missing-header-files.patch
deleted file mode 100644
index 3708f60..0000000
--- a/meta-openembedded/meta-oe/recipes-support/atop/atop/0001-include-missing-header-files.patch
+++ /dev/null
@@ -1,97 +0,0 @@
-From 7b651793269b6b86f12c43c30b751b86def27222 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 18 Mar 2017 17:56:40 -0700
-Subject: [PATCH] include missing header files
-
-fixes build with musl
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- deviate.c     | 1 +
- procdbase.c   | 2 +-
- showgeneric.c | 2 +-
- showlinux.c   | 2 +-
- showprocs.c   | 2 +-
- showsys.c     | 2 +-
- 6 files changed, 6 insertions(+), 5 deletions(-)
-
-diff --git a/deviate.c b/deviate.c
-index 7cf1b49..8e615af 100644
---- a/deviate.c
-+++ b/deviate.c
-@@ -178,6 +178,7 @@ static const char rcsid[] = "$Id: deviate.c,v 1.45 2010/10/23 14:02:03 gerlof Ex
- #include <stdio.h>
- #include <errno.h>
- #include <fcntl.h>
-+#include <stdlib.h>
- #include <unistd.h>
- #include <limits.h>
- #include <memory.h>
-diff --git a/procdbase.c b/procdbase.c
-index 9cab347..0487d26 100644
---- a/procdbase.c
-+++ b/procdbase.c
-@@ -67,7 +67,7 @@ static const char rcsid[] = "$Id: procdbase.c,v 1.8 2010/04/23 12:19:35 gerlof E
- #include <fcntl.h>
- #include <unistd.h>
- #include <string.h>
--#include <malloc.h>
-+#include <stdlib.h>
- 
- #include "atop.h"
- #include "photoproc.h"
-diff --git a/showgeneric.c b/showgeneric.c
-index 775afa8..3d5be0e 100644
---- a/showgeneric.c
-+++ b/showgeneric.c
-@@ -268,7 +268,7 @@ static const char rcsid[] = "$Id: showgeneric.c,v 1.71 2010/10/25 19:08:32 gerlo
- #include <errno.h>
- #include <fcntl.h>
- #include <string.h>
--#include <termio.h>
-+#include <termios.h>
- #include <unistd.h>
- #include <stdarg.h>
- #include <curses.h>
-diff --git a/showlinux.c b/showlinux.c
-index 6e60754..aba2ee6 100644
---- a/showlinux.c
-+++ b/showlinux.c
-@@ -274,7 +274,7 @@ static const char rcsid[] = "$Id: showlinux.c,v 1.70 2010/10/23 14:04:12 gerlof
- #include <string.h>
- #include <errno.h>
- #include <fcntl.h>
--#include <termio.h>
-+#include <termios.h>
- #include <unistd.h>
- #include <stdarg.h>
- #include <curses.h>
-diff --git a/showprocs.c b/showprocs.c
-index 5194524..f0169ad 100644
---- a/showprocs.c
-+++ b/showprocs.c
-@@ -94,7 +94,7 @@ static const char rcsid[] = "$Id: showprocs.c,v 1.15 2011/09/05 11:44:16 gerlof
- #include <string.h>
- #include <errno.h>
- #include <fcntl.h>
--#include <termio.h>
-+#include <termios.h>
- #include <unistd.h>
- #include <stdarg.h>
- #include <curses.h>
-diff --git a/showsys.c b/showsys.c
-index 26331be..5a05fe5 100644
---- a/showsys.c
-+++ b/showsys.c
-@@ -80,7 +80,7 @@ static const char rcsid[] = "XXXXXX";
- #include <string.h>
- #include <errno.h>
- #include <fcntl.h>
--#include <termio.h>
-+#include <termios.h>
- #include <unistd.h>
- #include <stdarg.h>
- #include <curses.h>
--- 
-2.12.0
-
diff --git a/meta-openembedded/meta-oe/recipes-support/atop/atop_2.2.3.bb b/meta-openembedded/meta-oe/recipes-support/atop/atop_2.2.3.bb
deleted file mode 100644
index 1ab9e7c..0000000
--- a/meta-openembedded/meta-oe/recipes-support/atop/atop_2.2.3.bb
+++ /dev/null
@@ -1,63 +0,0 @@
-SUMMARY = "Monitor for system resources and process activity"
-DESCRIPTION = "Atop is an ASCII full-screen performance monitor for Linux that \
-is capable of reporting the activity of all processes (even if processes have \
-finished during the interval), daily logging of system and process activity for \
-long-term analysis, highlighting overloaded system resources by using colors, \
-etc. At regular intervals, it shows system-level activity related to the CPU, \
-memory, swap, disks (including LVM) and network layers, and for every process \
-(and thread) it shows e.g. the CPU utilization, memory growth, disk \
-utilization, priority, username, state, and exit code."
-HOMEPAGE = "http://www.atoptool.nl"
-SECTION = "console/utils"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
-
-DEPENDS = "ncurses zlib"
-
-ATOP_VER = "${@'-'.join(d.getVar('PV').rsplit('.', 1))}"
-
-SRC_URI = " \
-    http://www.atoptool.nl/download/${BPN}-${ATOP_VER}.tar.gz \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'file://volatiles.atop.conf', 'file://volatiles.99_atop', d)} \
-    file://0001-include-missing-header-files.patch \
-    file://remove-bashisms.patch \
-    file://fix-permissions.patch \
-    file://sysvinit-implement-status.patch \
-"
-
-SRC_URI[md5sum] = "034dc1544f2ec4e4d2c739d320dc326d"
-SRC_URI[sha256sum] = "c785b8a2355be28b3de6b58a8ea4c4fcab8fadeaa57a99afeb03c66fac8e055d"
-
-S = "${WORKDIR}/${BPN}-${ATOP_VER}"
-
-do_compile() {
-    oe_runmake all
-}
-
-do_install() {
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-        make DESTDIR=${D} VERS=${ATOP_VER} SYSDPATH=${systemd_system_unitdir} \
-            PMPATHD=${systemd_unitdir}/system-sleep systemdinstall
-        install -d ${D}${sysconfdir}/tmpfiles.d
-        install -m 644 ${WORKDIR}/volatiles.atop.conf ${D}${sysconfdir}/tmpfiles.d/atop.conf
-        rm -f ${D}${systemd_system_unitdir}/atopacct.service
-    else
-        make DESTDIR=${D} VERS=${ATOP_VER} sysvinstall
-        install -d ${D}${sysconfdir}/default/volatiles
-        install -m 644 ${WORKDIR}/volatiles.99_atop ${D}${sysconfdir}/default/volatiles/99_atop
-        rm -f ${D}${sysconfdir}/init.d/atopacct
-    fi
-
-    # remove atopacct related files
-    rm -rf ${D}${sbindir} ${D}${mandir}/man8
-}
-
-inherit systemd
-
-SYSTEMD_SERVICE_${PN} = "atop.service"
-SYSTEMD_AUTO_ENABLE = "disable"
-
-FILES_${PN} += "${systemd_unitdir}/system-sleep"
-
-RDEPENDS_${PN} = "procps"
diff --git a/meta-openembedded/meta-oe/recipes-support/atop/atop_2.3.0.bb b/meta-openembedded/meta-oe/recipes-support/atop/atop_2.3.0.bb
new file mode 100644
index 0000000..302813c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/atop/atop_2.3.0.bb
@@ -0,0 +1,57 @@
+SUMMARY = "Monitor for system resources and process activity"
+DESCRIPTION = "Atop is an ASCII full-screen performance monitor for Linux that \
+is capable of reporting the activity of all processes (even if processes have \
+finished during the interval), daily logging of system and process activity for \
+long-term analysis, highlighting overloaded system resources by using colors, \
+etc. At regular intervals, it shows system-level activity related to the CPU, \
+memory, swap, disks (including LVM) and network layers, and for every process \
+(and thread) it shows e.g. the CPU utilization, memory growth, disk \
+utilization, priority, username, state, and exit code."
+HOMEPAGE = "http://www.atoptool.nl"
+SECTION = "console/utils"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
+
+DEPENDS = "ncurses zlib"
+
+SRC_URI = "http://www.atoptool.nl/download/${BP}.tar.gz \
+           ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'file://volatiles.atop.conf', 'file://volatiles.99_atop', d)} \
+           file://remove-bashisms.patch \
+           file://fix-permissions.patch \
+           file://sysvinit-implement-status.patch \
+           file://0001-add-sys-sysmacros.h-for-major-minor-macros.patch \
+           "
+SRC_URI[md5sum] = "48e1dbef8c7d826e68829a8d5fc920fc"
+SRC_URI[sha256sum] = "73e4725de0bafac8c63b032e8479e2305e3962afbe977ec1abd45f9e104eb264"
+
+do_compile() {
+    oe_runmake all
+}
+
+do_install() {
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+        make DESTDIR=${D} VERS=${PV} SYSDPATH=${systemd_system_unitdir} \
+            PMPATHD=${systemd_unitdir}/system-sleep systemdinstall
+        install -d ${D}${sysconfdir}/tmpfiles.d
+        install -m 644 ${WORKDIR}/volatiles.atop.conf ${D}${sysconfdir}/tmpfiles.d/atop.conf
+        rm -f ${D}${systemd_system_unitdir}/atopacct.service
+    else
+        make DESTDIR=${D} VERS=${PV} sysvinstall
+        install -d ${D}${sysconfdir}/default/volatiles
+        install -m 644 ${WORKDIR}/volatiles.99_atop ${D}${sysconfdir}/default/volatiles/99_atop
+        rm -f ${D}${sysconfdir}/init.d/atopacct
+    fi
+
+    # remove atopacct related files
+    rm -rf ${D}${sbindir} ${D}${mandir}/man8
+}
+
+inherit systemd
+
+SYSTEMD_SERVICE_${PN} = "atop.service"
+SYSTEMD_AUTO_ENABLE = "disable"
+
+FILES_${PN} += "${systemd_unitdir}/system-sleep"
+
+RDEPENDS_${PN} = "procps"
diff --git a/meta-openembedded/meta-oe/recipes-support/augeas/augeas.inc b/meta-openembedded/meta-oe/recipes-support/augeas/augeas.inc
index 185abae..c939d4b 100644
--- a/meta-openembedded/meta-oe/recipes-support/augeas/augeas.inc
+++ b/meta-openembedded/meta-oe/recipes-support/augeas/augeas.inc
@@ -31,3 +31,5 @@
 
 PACKAGECONFIG ??= ""
 PACKAGECONFIG[libselinux] = "--with-selinux,--without-selinux,libselinux"
+
+EXTRA_AUTORECONF += "-I ${S}/gnulib/m4"
diff --git a/meta-openembedded/meta-oe/recipes-support/augeas/augeas_1.10.1.bb b/meta-openembedded/meta-oe/recipes-support/augeas/augeas_1.10.1.bb
new file mode 100644
index 0000000..26e191b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/augeas/augeas_1.10.1.bb
@@ -0,0 +1,4 @@
+require augeas.inc
+
+SRC_URI[md5sum] = "6c0b2ea6eec45e8bc374b283aedf27ce"
+SRC_URI[sha256sum] = "52db256afab261d31cc147eaa1a71795a5fec59e888dfd0b65a84c7aacd6364d"
diff --git a/meta-openembedded/meta-oe/recipes-support/augeas/augeas_1.5.0.bb b/meta-openembedded/meta-oe/recipes-support/augeas/augeas_1.5.0.bb
deleted file mode 100644
index c4f62e7..0000000
--- a/meta-openembedded/meta-oe/recipes-support/augeas/augeas_1.5.0.bb
+++ /dev/null
@@ -1,4 +0,0 @@
-require augeas.inc
-
-SRC_URI[md5sum] = "01190e455c513124a2dae29a1182c113"
-SRC_URI[sha256sum] = "223bb6e6fe3e9e92277dafd5d34e623733eb969a72a382998d204feab253f73f"
diff --git a/meta-openembedded/meta-oe/recipes-support/ceres-solver/ceres-solver_1.14.bb b/meta-openembedded/meta-oe/recipes-support/ceres-solver/ceres-solver_1.14.bb
index 29917c8..a62e5ef 100644
--- a/meta-openembedded/meta-oe/recipes-support/ceres-solver/ceres-solver_1.14.bb
+++ b/meta-openembedded/meta-oe/recipes-support/ceres-solver/ceres-solver_1.14.bb
@@ -1,20 +1,19 @@
 DESCRIPTION = "Ceres Solver is an open source C++ library for modeling and solving large, complicated optimization problems."
 AUTHOR = "Sameer Agarwal and Keir Mierle and Others"
 HOMEPAGE = "http://ceres-solver.org/"
-
 LICENSE = "BSD-3-Clause"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=35e00f0c4c96a0820a03e0b31e6416be"
 
+DEPENDS = "libeigen glog"
+
 SRC_URI = "git://github.com/ceres-solver/ceres-solver.git"
 SRCREV = "facb199f3eda902360f9e1d5271372b7e54febe1"
 
 S = "${WORKDIR}/git"
 
-DEPENDS = "libeigen glog"
-
 inherit cmake
 
 # Only a static library and headers are created
-ALLOW_EMPTY_${PN} = "1"
-
-FILES_${PN}-dev += "${libdir}/cmake/*"
+RDEPENDS_${PN}-dev = ""
+RRECOMMENDS_${PN}-dev = "${PN}-staticdev"
+RRECOMMENDS_${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})"
diff --git a/meta-openembedded/meta-oe/recipes-support/ckermit/ckermit_302.bb b/meta-openembedded/meta-oe/recipes-support/ckermit/ckermit_302.bb
index 61c08ee..abeeecc 100644
--- a/meta-openembedded/meta-oe/recipes-support/ckermit/ckermit_302.bb
+++ b/meta-openembedded/meta-oe/recipes-support/ckermit/ckermit_302.bb
@@ -20,12 +20,6 @@
 
 EXTRA_OEMAKE = "-e MAKEFLAGS="
 
-# Additional flags. For uclibc we add -DNOARROWKEYS which stops ckermit
-# trying to look inside the stdio headers.
-CKERMIT_ADDITIONAL = ""
-CKERMIT_ADDITIONAL_libc-uclibc = "-DNOARROWKEYS"
-CKERMIT_ADDITIONAL_libc-musl = "-DNOARROWKEYS"
-
 TARGET_CC_ARCH += "${LDFLAGS}"
 
 do_compile () {
@@ -49,7 +43,7 @@
         -DNORESEND -DNOAUTODL -DNOSTREAMING -DNOHINTS -DNOCKXYZ -DNOLEARN \
         -DNOMKDIR -DNOPERMS -DNOCKTIMERS -DNOCKREGEX -DNOREALPATH \
         -DCK_SMALL -DNOLOGDIAL -DNORENAME -DNOWHATAMI \
-        ${CKERMIT_ADDITIONAL}"
+        -DNOARROWKEYS"
 }
 
 do_install () {
diff --git a/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest-2.10.2/fix-cmake-install.patch b/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest-2.10.2/fix-cmake-install.patch
deleted file mode 100644
index 0feafef..0000000
--- a/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest-2.10.2/fix-cmake-install.patch
+++ /dev/null
@@ -1,17 +0,0 @@
-Description: install cmake files into /usr/lib/cmake/cpprestsdk
-Author: Gianfranco Costamagna <locutusofborg@debian.org>
-Upstream-Status: https://github.com/Microsoft/cpprestsdk/pull/737
-Forwarded: https://github.com/Microsoft/cpprestsdk/pull/737
-Last-Update: 2018-04-19
-
---- cpprest-2.10.2.orig/CMakeLists.txt
-+++ cpprest-2.10.2/CMakeLists.txt
-@@ -18,7 +18,7 @@ enable_testing()
- set(WERROR ON CACHE BOOL "Treat Warnings as Errors.")
- set(CPPREST_EXCLUDE_WEBSOCKETS OFF CACHE BOOL "Exclude websockets functionality.")
- set(CPPREST_EXCLUDE_COMPRESSION OFF CACHE BOOL "Exclude compression functionality.")
--set(CPPREST_EXPORT_DIR lib/cpprestsdk CACHE STRING "Directory to install CMake config files.")
-+set(CPPREST_EXPORT_DIR lib/cmake/cpprestsdk CACHE STRING "Directory to install CMake config files.")
- set(CPPREST_INSTALL_HEADERS ON CACHE BOOL "Install header files.")
- set(CPPREST_INSTALL ON CACHE BOOL "Add install commands.")
- 
diff --git a/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest/950-fix.patch b/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest/950-fix.patch
new file mode 100644
index 0000000..3ae46a1
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest/950-fix.patch
@@ -0,0 +1,26 @@
+Origin: upstream
+Bug: https://github.com/Microsoft/cpprestsdk/issues/950
+Last-Update: 2018-11-04
+
+Index: cpprest/Release/src/utilities/asyncrt_utils.cpp
+===================================================================
+--- cpprest.orig/Release/src/utilities/asyncrt_utils.cpp
++++ cpprest/Release/src/utilities/asyncrt_utils.cpp
+@@ -356,7 +356,7 @@
+ inline size_t count_utf8_to_utf16(const std::string& s)
+ {
+     const size_t sSize = s.size();
+-    auto sData = reinterpret_cast<const UtilCharInternal_t* const>(s.data());
++    auto const sData = reinterpret_cast<const UtilCharInternal_t*>(s.data());
+     size_t result{ sSize };
+ 
+     for (size_t index = 0; index < sSize;)
+@@ -441,7 +441,7 @@
+ {
+     // Save repeated heap allocations, use the length of resulting sequence.
+     const size_t srcSize = s.size();
+-    auto srcData = reinterpret_cast<const UtilCharInternal_t* const>(s.data());
++    auto const srcData = reinterpret_cast<const UtilCharInternal_t*>(s.data());
+     utf16string dest(count_utf8_to_utf16(s), L'\0');
+     utf16string::value_type* const destData = &dest[0];
+     size_t destIndex = 0;
diff --git a/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest/disable-float-tests.patch b/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest/disable-float-tests.patch
new file mode 100644
index 0000000..75f74ec
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest/disable-float-tests.patch
@@ -0,0 +1,25 @@
+Description: new toolchain might have increased the float precision
+Author: Gianfranco Costamagna <locutusofborg@debian.org>
+Last-Update: 2017-10-28
+Forwarded: https://github.com/Microsoft/cpprestsdk/issues/576
+
+--- casablanca-2.10.0.orig/Release/tests/functional/streams/istream_tests.cpp
++++ casablanca-2.10.0/Release/tests/functional/streams/istream_tests.cpp
+@@ -1302,7 +1302,7 @@ void compare_float(float expected, float
+ {
+     compare_floating(expected, actual, FLT_EPSILON);
+ }
+-
++/*
+ TEST(extract_floating_point)
+ {
+     std::string test_string;
+@@ -1349,7 +1349,7 @@ TEST(extract_floating_point)
+             VERIFY_ARE_EQUAL(1 / expected, 1 / actual);
+     } while (!std_istream.eof());
+ }
+-
++*/
+ TEST(extract_floating_point_with_exceptions)
+ {
+     std::vector<std::pair<std::string, std::string>> tests;
diff --git a/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest/disable-outside-tests.patch b/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest/disable-outside-tests.patch
new file mode 100644
index 0000000..2dff0d9
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest/disable-outside-tests.patch
@@ -0,0 +1,142 @@
+Description: Debian forbids calls to external websites.
+
+Author: Gianfranco Costamagna <locutus@debian.org>
+Origin: Debian
+Forwarded: not-needed
+Reviewed-By: Gianfranco Costamagna <locutusofborg@debian.org>
+Last-Update: 2015-11-25
+
+Index: casablanca/Release/tests/functional/http/client/CMakeLists.txt
+===================================================================
+--- casablanca.orig/Release/tests/functional/http/client/CMakeLists.txt
++++ casablanca/Release/tests/functional/http/client/CMakeLists.txt
+@@ -12,7 +12,6 @@
+   multiple_requests.cpp
+   oauth1_tests.cpp
+   oauth2_tests.cpp
+-  outside_tests.cpp
+   pipeline_stage_tests.cpp
+   progress_handler_tests.cpp
+   proxy_tests.cpp
+Index: casablanca/Release/tests/functional/http/client/authentication_tests.cpp
+===================================================================
+--- casablanca.orig/Release/tests/functional/http/client/authentication_tests.cpp
++++ casablanca/Release/tests/functional/http/client/authentication_tests.cpp
+@@ -663,15 +663,19 @@
+     VERIFY_ARE_EQUAL(return_code, response.status_code());
+ }
+ 
++/*
+ TEST(auth_no_data)
+ {
+     auth_test_impl(false);
+ }
++*/
+ 
++/*
+ TEST(unsuccessful_auth_with_basic_cred)
+ {
+     auth_test_impl(true);
+ }
++*/
+ 
+ TEST_FIXTURE(uri_address, set_user_options_asio_http)
+ {
+@@ -692,7 +696,7 @@
+     auto response = client.request(methods::GET).get();
+     VERIFY_ARE_EQUAL(200, response.status_code());
+ }
+-
++/*
+ TEST_FIXTURE(uri_address, set_user_options_asio_https)
+ {
+     handle_timeout([]
+@@ -714,7 +718,7 @@
+         VERIFY_IS_FALSE(v.empty());
+     });
+ }
+-
++*/
+ #endif
+ 
+ } // SUITE(authentication_tests)
+Index: casablanca/Release/tests/functional/websockets/client/authentication_tests.cpp
+===================================================================
+--- casablanca.orig/Release/tests/functional/websockets/client/authentication_tests.cpp
++++ casablanca/Release/tests/functional/websockets/client/authentication_tests.cpp
+@@ -86,7 +86,7 @@
+     }
+     return false;
+ }
+-
++/*
+ TEST(ssl_test)
+ {
+     websocket_client client;
+@@ -122,7 +122,7 @@
+         throw;
+     }
+ }
+-
++*/
+ // These tests are specific to our websocketpp based implementation.
+ #if !defined(__cplusplus_winrt)
+ 
+@@ -153,14 +153,15 @@
+         throw;
+     }
+ }
+-
++/*
+ // Test specifically for server SignalR team hit interesting cases with.
+ TEST(sni_with_older_server_test)
+ {
+     websocket_client client;
+     sni_test_impl(client);
+ }
+-
++*/
++/*
+ // WinRT doesn't expose option for disabling.
+ // No stable server is available to reliably test this.
+ // The configuration below relies on a timeout in the success case.
+@@ -188,7 +189,8 @@
+         throw;
+     }
+ }
+-
++*/
++/*
+ // Winrt doesn't allow explicitly setting server host for SNI.
+ TEST(sni_explicit_hostname)
+ {
+@@ -199,7 +201,7 @@
+     websocket_client client(config);
+     sni_test_impl(client);
+ }
+-
++*/
+ void handshake_error_test_impl(const ::utility::string_t &host)
+ {
+     websocket_client client;
+Index: casablanca/Release/tests/functional/http/client/connections_and_errors.cpp
+===================================================================
+--- casablanca.orig/Release/tests/functional/http/client/connections_and_errors.cpp
++++ casablanca/Release/tests/functional/http/client/connections_and_errors.cpp
+@@ -415,6 +415,7 @@
+ }
+ #endif
+ 
++/*
+ // Try to connect to a server on a closed port and cancel the operation.
+ TEST_FIXTURE(uri_address, cancel_bad_port)
+ {
+@@ -446,7 +447,7 @@
+ 
+     VERIFY_THROWS_HTTP_ERROR_CODE(t.get(), std::errc::operation_canceled);
+ }
+-
++*/
+ } // SUITE(connections_and_errors)
+ 
+ }}}}
diff --git a/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest/disable-test-timeouts.patch b/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest/disable-test-timeouts.patch
new file mode 100644
index 0000000..93c3e8a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest/disable-test-timeouts.patch
@@ -0,0 +1,103 @@
+Description: Some tests takes too long on slow architectures and timeouts
+ We can safely disable them.
+ e.g.
+ Release/tests/functional/http/client/connections_and_errors.cpp:142: error: Failure in request_timeout_microsecond: Test case timed out and is hung. Aborting all remaining test cases. Expected under 180000ms. FAILED
+
+Index: casablanca/Release/tests/functional/http/client/connections_and_errors.cpp
+===================================================================
+--- casablanca.orig/Release/tests/functional/http/client/connections_and_errors.cpp
++++ casablanca/Release/tests/functional/http/client/connections_and_errors.cpp
+@@ -127,7 +127,7 @@
+     // Try sending another request.
+     VERIFY_THROWS(client.request(methods::GET).wait(), web::http::http_exception);
+ }
+-
++/*
+ TEST_FIXTURE(uri_address, request_timeout)
+ {
+     test_http_server::scoped_server scoped(m_uri);
+@@ -146,7 +146,8 @@
+ #endif
+     t.get();
+ }
+-
++*/
++/*
+ TEST_FIXTURE(uri_address, request_timeout_microsecond)
+ {
+     pplx::task<test_request*> t;
+@@ -168,7 +169,7 @@
+     try { t.get(); }
+     catch (...) {}
+ }
+-
++*/
+ TEST_FIXTURE(uri_address, invalid_method)
+ {
+     web::http::uri uri(U("http://www.bing.com/"));
+Index: casablanca/Release/tests/functional/http/listener/requests_tests.cpp
+===================================================================
+--- casablanca.orig/Release/tests/functional/http/listener/requests_tests.cpp
++++ casablanca/Release/tests/functional/http/listener/requests_tests.cpp
+@@ -173,7 +173,7 @@
+ 
+     listener.close().wait();
+ }
+-
++/*
+ TEST_FIXTURE(uri_address, response_order)
+ {
+     http_listener listener(m_uri);
+@@ -217,7 +217,7 @@
+ 
+     listener.close().wait();
+ }
+-
++*/
+ TEST_FIXTURE(uri_address, uri_encoding, "Ignore", "Codeplex 201")
+ {
+     http_listener listener(m_uri);
+Index: casablanca/Release/tests/functional/websockets/client/authentication_tests.cpp
+===================================================================
+--- casablanca.orig/Release/tests/functional/websockets/client/authentication_tests.cpp
++++ casablanca/Release/tests/functional/websockets/client/authentication_tests.cpp
+@@ -221,7 +221,7 @@
+         VERIFY_ARE_EQUAL("TLS handshake failed", e.error_code().message());
+     }
+ }
+-
++/*
+ TEST(self_signed_cert)
+ {
+     handshake_error_test_impl(U("wss://self-signed.badssl.com/"));
+@@ -236,7 +236,7 @@
+ {
+     handshake_error_test_impl(U("wss://expired.badssl.com/"));
+ }
+-
++*/
+ #endif
+ 
+ } // SUITE(authentication_tests)
+Index: casablanca/Release/tests/functional/websockets/client/client_construction.cpp
+===================================================================
+--- casablanca.orig/Release/tests/functional/websockets/client/client_construction.cpp
++++ casablanca/Release/tests/functional/websockets/client/client_construction.cpp
+@@ -81,7 +81,7 @@
+     VERIFY_ARE_EQUAL(config2.credentials().username(), cred.username());
+ }
+ 
+-
++/*
+ // Verify that we can get the baseuri from websocket_client connect.
+ TEST_FIXTURE(uri_address, uri_test)
+ {
+@@ -101,7 +101,7 @@
+     VERIFY_ARE_EQUAL(client2.uri(), m_uri);
+     client2.close().wait();
+ }
+-
++*/
+ TEST_FIXTURE(uri_address, move_operations)
+ {
+     std::string body("hello");
diff --git a/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest/system-brotli.patch b/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest/system-brotli.patch
new file mode 100644
index 0000000..e6f6477
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest/system-brotli.patch
@@ -0,0 +1,38 @@
+Description: Find system brotli
+Author: Gianfranco Costamagna <locutusofborg@debian.org>
+Forwarded: https://github.com/Microsoft/cpprestsdk/pull/952
+Last-Update: 2018-11-05
+
+--- cpprest-2.10.7.orig/Release/cmake/cpprest_find_brotli.cmake
++++ cpprest-2.10.7/Release/cmake/cpprest_find_brotli.cmake
+@@ -3,8 +3,17 @@ function(cpprest_find_brotli)
+     return()
+   endif()
+ 
+-  find_package(unofficial-brotli REQUIRED)
+ 
+-  add_library(cpprestsdk_brotli_internal INTERFACE)
+-  target_link_libraries(cpprestsdk_brotli_internal INTERFACE unofficial::brotli::brotlienc unofficial::brotli::brotlidec unofficial::brotli::brotlicommon)
++  find_package(PkgConfig)
++  pkg_check_modules(BROTLIENC libbrotlienc)
++  pkg_check_modules(BROTLIDEC libbrotlidec)
++  if(BROTLIDEC_FOUND AND BROTLIENC_FOUND)
++	  target_link_libraries(cpprest PRIVATE ${BROTLIDEC_LDFLAGS} ${BROTLIENC_LDFLAGS})
++  else(BROTLIDEC_FOUND AND BROTLIENC_FOUND)
++    find_package(unofficial-brotli REQUIRED)
++    add_library(cpprestsdk_brotli_internal INTERFACE)
++    target_link_libraries(cpprestsdk_brotli_internal INTERFACE unofficial::brotli::brotlienc unofficial::brotli::brotlidec unofficial::brotli::brotlicommon)
++    target_link_libraries(cpprest PRIVATE cpprestsdk_brotli_internal)
++  endif(BROTLIDEC_FOUND AND BROTLIENC_FOUND)
++
+ endfunction()
+--- cpprest-2.10.7.orig/Release/src/CMakeLists.txt
++++ cpprest-2.10.7/Release/src/CMakeLists.txt
+@@ -84,7 +84,6 @@ else()
+     target_compile_definitions(cpprest PRIVATE -DCPPREST_EXCLUDE_BROTLI=1)
+   else()
+     cpprest_find_brotli()
+-    target_link_libraries(cpprest PRIVATE cpprestsdk_brotli_internal)
+   endif()
+ endif()
+ 
diff --git a/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb b/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb
deleted file mode 100644
index 2ba6fc6..0000000
--- a/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest_2.10.2.bb
+++ /dev/null
@@ -1,17 +0,0 @@
-SUMMARY = "Microsoft project for cloud-based client-server communication in native code using a modern asynchronous C++ API design."
-SECTION = "libs/network"
-HOMEPAGE = "https://github.com/Microsoft/cpprestsdk/"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://${S}/../license.txt;md5=a2e15b954769218ff912468eecd6a02f"
-DEPENDS = "openssl websocketpp zlib boost"
-
-SRC_URI = "git://github.com/Microsoft/cpprestsdk.git;protocol=https;branch=master"
-
-SRC_URI += "file://fix-cmake-install.patch"
-
-# tag 2.10.2
-SRCREV= "fea848e2a77563cf2a6f28f8eab396fd6e787fbf"
-
-S = "${WORKDIR}/git/Release"
-
-inherit cmake
diff --git a/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest_2.10.7.bb b/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest_2.10.7.bb
new file mode 100644
index 0000000..5cc6385
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/cpprest/cpprest_2.10.7.bb
@@ -0,0 +1,23 @@
+SUMMARY = "Microsoft project for cloud-based client-server communication in native code using a modern asynchronous C++ API design."
+SECTION = "libs/network"
+HOMEPAGE = "https://github.com/Microsoft/cpprestsdk/"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${S}/license.txt;md5=a2e15b954769218ff912468eecd6a02f"
+DEPENDS = "openssl websocketpp zlib boost brotli"
+
+EXTRA_OECMAKE = "-DCPPREST_EXPORT_DIR=cmake -DCPPREST_EXCLUDE_BROTLI=OFF"
+
+SRC_URI = "git://github.com/Microsoft/cpprestsdk.git;protocol=https;branch=master \
+           file://disable-outside-tests.patch \
+           file://disable-test-timeouts.patch \
+           file://disable-float-tests.patch \
+           file://950-fix.patch \
+           file://system-brotli.patch \
+           "
+
+# tag 2.10.7
+SRCREV= "c4cef129e880a3f9c23a480e8c983793963173bb"
+
+S = "${WORKDIR}/git"
+
+inherit cmake
diff --git a/meta-openembedded/meta-oe/recipes-support/dos2unix/dos2unix_7.4.0.bb b/meta-openembedded/meta-oe/recipes-support/dos2unix/dos2unix_7.4.0.bb
deleted file mode 100644
index 8d3c578..0000000
--- a/meta-openembedded/meta-oe/recipes-support/dos2unix/dos2unix_7.4.0.bb
+++ /dev/null
@@ -1,34 +0,0 @@
-SUMMARY = "Convert text file line endings between CRLF and LF"
-DESCRIPTION = "The Dos2unix package includes utilities dos2unix and \
-unix2dos to convert plain text files in DOS or Mac format to Unix \
-format and vice versa."
-HOMEPAGE = "http://waterlan.home.xs4all.nl/dos2unix.html"
-SECTION = "support"
-
-LICENSE = "BSD-2-Clause"
-LIC_FILES_CHKSUM = "file://COPYING.txt;md5=1b78fca784db24f4a40e30b300787f3f"
-
-SRC_URI = "git://git.code.sf.net/p/dos2unix/dos2unix"
-
-# Release 7.4.0
-SRCREV = "1182533bde3c1fe65be2ead465e87671faa2c027"
-
-S = "${WORKDIR}/git/dos2unix"
-
-inherit gettext perlnative
-
-# The dos2unix NLS relies on po4a-native, while po4a recipe is
-# provided by meta-perl layer, so make it optional here, you
-# need have meta-perl in bblayers.conf before enabling nls in
-# PACKAGECONFIG.
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[nls] = "ENABLE_NLS=1,ENABLE_NLS=,po4a-native"
-
-EXTRA_OEMAKE = "${PACKAGECONFIG_CONFARGS} LDFLAGS_USER='${LDFLAGS}'"
-EXTRA_OEMAKE_class-native = "ENABLE_NLS="
-
-do_install () {
-    oe_runmake DESTDIR="${D}${base_prefix}" install
-}
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-support/eject/eject/0001-eject-Include-sys-sysmacros.h-for-major-minor.patch b/meta-openembedded/meta-oe/recipes-support/eject/eject/0001-eject-Include-sys-sysmacros.h-for-major-minor.patch
new file mode 100644
index 0000000..0551287
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/eject/eject/0001-eject-Include-sys-sysmacros.h-for-major-minor.patch
@@ -0,0 +1,27 @@
+From 433ffb21119a0f39e882dd3fea4742e64aadcc40 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 11 Aug 2018 09:56:40 -0700
+Subject: [PATCH] eject: Include sys/sysmacros.h for major/minor
+
+Fixes
+arm-bec-linux-gnueabi/gcc/arm-bec-linux-gnueabi/8.2.0/ld: eject.o: in function `GetMajorMinor':
+/usr/src/debug/eject/2.1.5-r1/eject-2.1.5/../../../../../../../workspace/sources/eject/eject.c:866: undefined reference to `major'
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ eject.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/eject.c b/eject.c
+index 47e09fe..b171218 100644
+--- a/eject.c
++++ b/eject.c
+@@ -54,6 +54,7 @@
+ #include <sys/wait.h>
+ #include <sys/mtio.h>
+ #include <sys/mount.h>
++#include <sys/sysmacros.h>
+ 
+ #if defined(__linux__)
+ #include <linux/version.h>
diff --git a/meta-openembedded/meta-oe/recipes-support/eject/eject_2.1.5.bb b/meta-openembedded/meta-oe/recipes-support/eject/eject_2.1.5.bb
index 49a3d74..dec2e7a 100644
--- a/meta-openembedded/meta-oe/recipes-support/eject/eject_2.1.5.bb
+++ b/meta-openembedded/meta-oe/recipes-support/eject/eject_2.1.5.bb
@@ -10,7 +10,8 @@
            file://eject-2.1.1-verbose.patch \
            file://eject-2.1.5-spaces.patch \
            file://eject-timeout.patch \
-"
+           file://0001-eject-Include-sys-sysmacros.h-for-major-minor.patch \
+           "
 
 SRC_URI[md5sum] = "b96a6d4263122f1711db12701d79f738"
 SRC_URI[sha256sum] = "ef9f7906484cfde4ba223b2682a37058f9a3c7d3bb1adda7a34a67402e2ffe55"
diff --git a/meta-openembedded/meta-oe/recipes-support/espeak/espeak-data_1.48.04.bb b/meta-openembedded/meta-oe/recipes-support/espeak/espeak-data_1.48.04.bb
index 79b2cc1..a4e5d14 100644
--- a/meta-openembedded/meta-oe/recipes-support/espeak/espeak-data_1.48.04.bb
+++ b/meta-openembedded/meta-oe/recipes-support/espeak/espeak-data_1.48.04.bb
@@ -14,7 +14,7 @@
     sed -i '/^ *CC *=/d' Makefile
     sed -i 's/\(.*BYTE_ORDER\)/#undef BYTE_ORDER\n#define BYTE_ORDER BIG_ENDIAN\n\1/' espeak-phoneme-data.c
     oe_runmake
-    ./espeak-phoneme-data "${S}/espeak-data"
+    ./espeak-phoneme-data "${S}/espeak-data" "." "${S}/espeak-data/phondata-manifest"
     cp -f phondata phonindex phontab "${S}/espeak-data"
 }
 
diff --git a/meta-openembedded/meta-oe/recipes-support/espeak/espeak.inc b/meta-openembedded/meta-oe/recipes-support/espeak/espeak.inc
index 60b3f73..f45455c 100644
--- a/meta-openembedded/meta-oe/recipes-support/espeak/espeak.inc
+++ b/meta-openembedded/meta-oe/recipes-support/espeak/espeak.inc
@@ -4,7 +4,8 @@
 LIC_FILES_CHKSUM = "file://License.txt;md5=cb7a20edb4c9f5f478de6523dcd7362c"
 
 SRC_URI = "http://downloads.sourceforge.net/espeak/espeak-1.48.04-source.zip \
-           file://gcc-narrowing-warning-fix.patch \
+           file://0001-Fix-build-of-shared-library-on-architectures-needing.patch \
+           file://espeak-1.48-gcc-6-fix.patch \
 "
 SRC_URI[md5sum] = "cadd7482eaafe9239546bdc09fa244c3"
 SRC_URI[sha256sum] = "bf9a17673adffcc28ff7ea18764f06136547e97bbd9edf2ec612f09b207f0659"
diff --git a/meta-openembedded/meta-oe/recipes-support/espeak/espeak_1.48.04.bb b/meta-openembedded/meta-oe/recipes-support/espeak/espeak_1.48.04.bb
index 552f404..57e30f0 100644
--- a/meta-openembedded/meta-oe/recipes-support/espeak/espeak_1.48.04.bb
+++ b/meta-openembedded/meta-oe/recipes-support/espeak/espeak_1.48.04.bb
@@ -36,6 +36,5 @@
         rm -f ${S}/espeak-data/phon*
     fi
 
-    cp -prf ${S}/espeak-data/* ${D}${datadir}/espeak-data
-    chown -R root:root ${D}${datadir}/espeak-data
+    cp -R --no-dereference --preserve=mode,links ${S}/espeak-data/* ${D}${datadir}/espeak-data
 }
diff --git a/meta-openembedded/meta-oe/recipes-support/espeak/files/0001-Fix-build-of-shared-library-on-architectures-needing.patch b/meta-openembedded/meta-oe/recipes-support/espeak/files/0001-Fix-build-of-shared-library-on-architectures-needing.patch
new file mode 100644
index 0000000..2590e15
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/espeak/files/0001-Fix-build-of-shared-library-on-architectures-needing.patch
@@ -0,0 +1,31 @@
+From 08a464e2b6bd31bb2bf4e258ebfa9b9d65805abf Mon Sep 17 00:00:00 2001
+From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
+Date: Fri, 27 Nov 2015 15:17:02 +0100
+Subject: [PATCH] Fix build of shared library on architectures needing -fPIC
+
+Certain architectures, like Sparc and Sparc64 require objects to be
+built with -fPIC (and not just -fpic) to be usable in shared
+libraries. On other architectures, -fPIC is the same as -fpic so this
+patch doesn't affect such architectures.
+
+Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
+---
+ src/Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/Makefile b/src/Makefile
+index 95fe549..c293611 100755
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -110,7 +110,7 @@ $(BIN2_NAME): $(OBJS3) $(LIB_NAME)
+ 
+ 
+ x_%.o: %.cpp
+-	$(CXX) $(CXXFLAGS) $(USE_AUDIO) -D PATH_ESPEAK_DATA=\"$(DATADIR)\" -Wall -fpic -fvisibility=hidden -pedantic \
++	$(CXX) $(CXXFLAGS) $(USE_AUDIO) -D PATH_ESPEAK_DATA=\"$(DATADIR)\" -Wall -fPIC -fvisibility=hidden -pedantic \
+ 	-I. -D LIBRARY -c -fno-exceptions  $<  -o x_$*.o
+ 
+ $(LIB_NAME): $(OBJS2)
+-- 
+2.6.3
+
diff --git a/meta-openembedded/meta-oe/recipes-support/espeak/files/espeak-1.48-gcc-6-fix.patch b/meta-openembedded/meta-oe/recipes-support/espeak/files/espeak-1.48-gcc-6-fix.patch
new file mode 100644
index 0000000..6e59c78
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/espeak/files/espeak-1.48-gcc-6-fix.patch
@@ -0,0 +1,12 @@
+diff --git a/src/tr_languages.cpp b/src/tr_languages.cpp
+--- a/src/tr_languages.cpp
++++ b/src/tr_languages.cpp
+@@ -198,7 +198,7 @@ static const unsigned short chars_ignore_zwnj_hyphen[] = {
+ 	0x200d,  1, // zero width joiner
+ 	0, 0 };
+ 
+-const char string_ordinal[] = {0xc2,0xba,0};  // masculine ordinal character, UTF-8
++const char string_ordinal[] = {'\xc2','\xba',0};  // masculine ordinal character, UTF-8
+ 
+ 
+ static Translator* NewTranslator(void)
diff --git a/meta-openembedded/meta-oe/recipes-support/espeak/files/gcc-narrowing-warning-fix.patch b/meta-openembedded/meta-oe/recipes-support/espeak/files/gcc-narrowing-warning-fix.patch
deleted file mode 100644
index 2a9b460..0000000
--- a/meta-openembedded/meta-oe/recipes-support/espeak/files/gcc-narrowing-warning-fix.patch
+++ /dev/null
@@ -1,56 +0,0 @@
-From f09c83640b9173552fd9277c3a48619b903fa436 Mon Sep 17 00:00:00 2001
-From: "Reece H. Dunn" <msclrhd@gmail.com>
-Date: Wed, 20 Jan 2016 20:48:29 +0000
-Subject: [PATCH] Fix GCC -Wnarrowing warnings.
-
----
- src/tr_languages.cpp | 7 ++++---
- src/translate.h    | 2 +-
- 2 files changed, 5 insertions(+), 4 deletions(-)
-
-Index: espeak-1.48.04-source/src/tr_languages.cpp
-===================================================================
---- espeak-1.48.04-source.orig/src/tr_languages.cpp
-+++ espeak-1.48.04-source/src/tr_languages.cpp
-@@ -198,8 +198,8 @@ static const unsigned short chars_ignore
- 	0x200d,  1, // zero width joiner
- 	0, 0 };
- 
--const char string_ordinal[] = {0xc2,0xba,0};  // masculine ordinal character, UTF-8
--
-+const unsigned char string_ordinal[] = {0xc2,0xba,0};  // masculine ordinal character, UTF-8
-+const unsigned char utf8_null[] = { 0 }; // null string, UTF-8
- 
- static Translator* NewTranslator(void)
- {//===================================
-@@ -296,7 +296,7 @@ static const char transpose_map_latin[]
- 	tr->langopts.replace_chars = NULL;
- 	tr->langopts.ascii_language[0] = 0;    // Non-Latin alphabet languages, use this language to speak Latin words, default is English
- 	tr->langopts.alt_alphabet_lang = L('e','n');
--	tr->langopts.roman_suffix = "";
-+	tr->langopts.roman_suffix = utf8_null;
- 
- 	SetLengthMods(tr,201);
- //	tr->langopts.length_mods = length_mods_en;
-@@ -758,7 +758,7 @@ Translator *SelectTranslator(const char
- 				tr->langopts.stress_flags = S_FINAL_SPANISH | S_FINAL_DIM_ONLY | S_FINAL_NO_2;
- 				tr->langopts.numbers = NUM_SINGLE_STRESS | NUM_DECIMAL_COMMA | NUM_AND_UNITS | NUM_OMIT_1_HUNDRED | NUM_OMIT_1_THOUSAND | NUM_ROMAN | NUM_ROMAN_ORDINAL;
- 				tr->langopts.numbers2 = NUM2_ORDINAL_NO_AND;
--				tr->langopts.roman_suffix = string_ordinal;
-+				tr->langopts.roman_suffix = utf8_null;
- 			}
- 			else
- 			if(name2 == L_pap)
-Index: espeak-1.48.04-source/src/translate.h
-===================================================================
---- espeak-1.48.04-source.orig/src/translate.h
-+++ espeak-1.48.04-source/src/translate.h
-@@ -545,7 +545,7 @@ typedef struct {
- 	int decimal_sep;
- 	int max_digits;    // max number of digits which can be spoken as an integer number (rather than individual digits)
- 	const char *ordinal_indicator;   // UTF-8 string
--	const char *roman_suffix;    // add this (ordinal) suffix to Roman numbers (LANG=an)
-+	const unsigned char *roman_suffix;    // add this (ordinal) suffix to Roman numbers (LANG=an)
- 
- 	// bit 0, accent name before the letter name, bit 1 "capital" after letter name
- 	int accents;
diff --git a/meta-openembedded/meta-oe/recipes-support/eventlog/eventlog_0.2.13.bb b/meta-openembedded/meta-oe/recipes-support/eventlog/eventlog_0.2.13.bb
deleted file mode 100644
index 13eb794..0000000
--- a/meta-openembedded/meta-oe/recipes-support/eventlog/eventlog_0.2.13.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-SUMMARY = "Replacement syslog API"
-HOMEPAGE = "http://www.balabit.com/network-security/syslog-ng/opensource-logging-system"
-DESCRIPTION = "The EventLog library aims to be a replacement of the \
-              simple syslog() API provided on UNIX systems. The \
-              major difference between EventLog and syslog is that \
-              EventLog tries to add structure to messages. EventLog \
-              provides an interface to build, format and output an \
-              event record. The exact format and output method can \
-              be customized by the administrator via a configuration \
-              file. his package is the runtime part of the library. \
-"
-
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b8ba8e77bcda9a53fac0fe39fe957767"
-
-SRC_URI = "https://www.balabit.com/downloads/syslog-ng/open-source-edition/3.4.2/source/${BPN}_${PV}.tar.gz"
-
-inherit autotools pkgconfig
-
-SRC_URI[md5sum] = "68ec8d1ea3b98fa35002bb756227c315"
-SRC_URI[sha256sum] = "7cb4e6f316daede4fa54547371d5c986395177c12dbdec74a66298e684ac8b85"
diff --git a/meta-openembedded/meta-oe/recipes-support/farsight/libnice_0.1.13.bb b/meta-openembedded/meta-oe/recipes-support/farsight/libnice_0.1.13.bb
deleted file mode 100644
index 48c8221..0000000
--- a/meta-openembedded/meta-oe/recipes-support/farsight/libnice_0.1.13.bb
+++ /dev/null
@@ -1,36 +0,0 @@
-SUMMARY = "Interactive Connectivity Establishment library"
-DESCRIPTION = "Libnice is an implementation of the IETF's draft Interactive Connectivity Establishment standard (ICE)."
-HOMEPAGE = "http://nice.freedesktop.org/wiki/"
-SRC_URI = "http://nice.freedesktop.org/releases/libnice-${PV}.tar.gz"
-SRC_URI[md5sum] = "3226faeaf48a9150ada00da2e2865959"
-SRC_URI[sha256sum] = "61112d9f3be933a827c8365f20551563953af6718057928f51f487bfe88419e1"
-
-LICENSE = "LGPLv2.1 & MPLv1.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=9c42325015702feda4f4d2f19a55b767 \
-                    file://COPYING.LGPL;md5=2d5025d4aa3495befef8f17206a5b0a1 \
-                    file://COPYING.MPL;md5=3c617710e51cdbe0fc00716f056dfb1a \
-"
-
-DEPENDS = "glib-2.0 gstreamer1.0 gstreamer1.0-plugins-base"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[gupnp] = "--enable-gupnp,--disable-gupnp,gupnp-igd"
-
-inherit autotools pkgconfig gtk-doc gobject-introspection
-
-FILES_${PN} += "${libdir}/gstreamer-1.0/*.so"
-FILES_${PN}-dev += "${libdir}/gstreamer-1.0/*.la"
-FILES_${PN}-staticdev += "${libdir}/gstreamer-1.0/*.a"
-FILES_${PN}-dbg += "${libdir}/gstreamer-1.0/.debug"
-
-do_configure_prepend() {
-    mkdir ${S}/m4 || true
-}
-
-do_compile_append() {
-    for i in $(find ${B} -name "*.pc") ; do
-        sed -i -e s:${STAGING_DIR_TARGET}::g \
-               -e s:/${TARGET_SYS}::g \
-                  $i
-    done
-}
diff --git a/meta-openembedded/meta-oe/recipes-support/farsight/libnice_0.1.14.bb b/meta-openembedded/meta-oe/recipes-support/farsight/libnice_0.1.14.bb
new file mode 100644
index 0000000..775257f
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/farsight/libnice_0.1.14.bb
@@ -0,0 +1,38 @@
+SUMMARY = "Interactive Connectivity Establishment library"
+DESCRIPTION = "Libnice is an implementation of the IETF's draft Interactive Connectivity Establishment standard (ICE)."
+HOMEPAGE = "http://nice.freedesktop.org/wiki/"
+SRC_URI = "http://nice.freedesktop.org/releases/libnice-${PV}.tar.gz"
+SRC_URI[md5sum] = "c9b9b74b8ae1b3890e4bd93f1b70e8ff"
+SRC_URI[sha256sum] = "be120ba95d4490436f0da077ffa8f767bf727b82decf2bf499e39becc027809c"
+
+LICENSE = "LGPLv2.1 & MPLv1.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=9c42325015702feda4f4d2f19a55b767 \
+                    file://COPYING.LGPL;md5=2d5025d4aa3495befef8f17206a5b0a1 \
+                    file://COPYING.MPL;md5=3c617710e51cdbe0fc00716f056dfb1a \
+"
+
+DEPENDS = "glib-2.0 gnutls"
+
+PACKAGECONFIG ??= "gstreamer1.0"
+PACKAGECONFIG[gupnp] = "--enable-gupnp,--disable-gupnp,gupnp-igd"
+PACKAGECONFIG[gstreamer0.10] = "--with-gstreamer-0.10,--without-gstreamer-0.10,gstreamer gst-plugins-base"
+PACKAGECONFIG[gstreamer1.0] = "--with-gstreamer,--without-gstreamer,gstreamer1.0 gstreamer1.0-plugins-base"
+
+inherit autotools pkgconfig gtk-doc gobject-introspection
+
+FILES_${PN} += "${libdir}/gstreamer-0.10/*.so ${libdir}/gstreamer-1.0/*.so"
+FILES_${PN}-dev += "${libdir}/gstreamer-0.10/*.la ${libdir}/gstreamer-1.0/*.la"
+FILES_${PN}-staticdev += "${libdir}/gstreamer-0.10/*.a ${libdir}/gstreamer-1.0/*.a"
+FILES_${PN}-dbg += "${libdir}/gstreamer-0.10/.debug ${libdir}/gstreamer-1.0/.debug"
+
+do_configure_prepend() {
+    mkdir ${S}/m4 || true
+}
+
+do_compile_append() {
+    for i in $(find ${B} -name "*.pc") ; do
+        sed -i -e s:${STAGING_DIR_TARGET}::g \
+               -e s:/${TARGET_SYS}::g \
+                  $i
+    done
+}
diff --git a/meta-openembedded/meta-oe/recipes-support/fbset/fbset-modes.bb b/meta-openembedded/meta-oe/recipes-support/fbset/fbset-modes.bb
index 5f6f990..b768553 100644
--- a/meta-openembedded/meta-oe/recipes-support/fbset/fbset-modes.bb
+++ b/meta-openembedded/meta-oe/recipes-support/fbset/fbset-modes.bb
@@ -14,8 +14,6 @@
     install -m 0644 ${WORKDIR}/fb.modes ${D}${sysconfdir}
 }
 
-inherit allarch
-
 # fb.modes file is MACHINE_ARCH, base.bbclass correctly changes it to MACHINE_ARCH, but too late for allarch.bbclass
 # to disable "all" behavior (found when comparing qemuarm and qemux86 signatures)
 PACKAGE_ARCH = "${MACHINE_ARCH}"
diff --git a/meta-openembedded/meta-oe/recipes-support/fftw/fftw_3.3.7.bb b/meta-openembedded/meta-oe/recipes-support/fftw/fftw_3.3.7.bb
deleted file mode 100644
index aae6ec9..0000000
--- a/meta-openembedded/meta-oe/recipes-support/fftw/fftw_3.3.7.bb
+++ /dev/null
@@ -1,80 +0,0 @@
-DESCRIPTION = "FFTW"
-SECTION = "libs"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552"
-
-SRC_URI = " \
-    http://www.fftw.org/fftw-${PV}.tar.gz \
-    file://0001-NEON-autodetection-segfaults-assume-neon-present.patch \
-"
-SRC_URI[md5sum] = "0d5915d7d39b3253c1cc05030d79ac47"
-SRC_URI[sha256sum] = "3b609b7feba5230e8f6dd8d245ddbefac324c5a6ae4186947670d9ac2cd25573"
-
-inherit autotools pkgconfig
-
-# we had multiple recipes in the past
-PROVIDES = "fftwl fftwf"
-
-EXTRA_OECONF = "--disable-fortran --enable-shared --enable-threads"
-
-CFLAGS += "-D_GNU_SOURCE"
-
-FFTW_NEON = "${@bb.utils.contains('TUNE_FEATURES', 'neon', '--enable-neon', '', d)}"
-FFTW_NEON_class-native = ""
-
-do_configure() {
-    # configure fftw
-    rm -rf ${WORKDIR}/build-fftw
-	mkdir -p ${B}
-    cd ${B}
-    # full (re)configure
-    autotools_do_configure
-    mv ${B} ${WORKDIR}/build-fftw
-
-    # configure fftwl
-    rm -rf ${WORKDIR}/build-fftwl
-	mkdir -p ${B}
-    cd ${B}
-    # configure only
-    oe_runconf  --enable-long-double
-    mv ${B} ${WORKDIR}/build-fftwl 
-
-    # configure fftwf
-    rm -rf ${WORKDIR}/build-fftwf
-	mkdir -p ${B}
-    cd ${B}
-    # configure only
-    oe_runconf --enable-single ${FFTW_NEON}
-    mv ${B} ${WORKDIR}/build-fftwf
-}
-
-do_compile() {
-    for lib in fftw fftwl fftwf; do
-        cd ${WORKDIR}/build-$lib
-        autotools_do_compile
-    done
-}
-
-do_install() {
-    for lib in fftw fftwl fftwf; do
-        cd ${WORKDIR}/build-$lib
-        autotools_do_install
-    done
-}
-
-
-PACKAGES =+ "libfftw libfftwl libfftwf"
-FILES_libfftw = "${libdir}/libfftw3.so.* ${libdir}/libfftw3_*.so.*"
-FILES_libfftwl = "${libdir}/libfftw3l.so.* ${libdir}/libfftw3l_*.so.*"
-FILES_libfftwf = "${libdir}/libfftw3f.so.* ${libdir}/libfftw3f_*.so.*"
-
-PACKAGES =+ "fftw-wisdom fftwl-wisdom fftwf-wisdom fftw-wisdom-to-conf"
-FILES_fftw-wisdom = "${bindir}/fftw-wisdom"
-FILES_fftwl-wisdom = "${bindir}/fftwl-wisdom"
-FILES_fftwf-wisdom = "${bindir}/fftwf-wisdom"
-FILES_fftw-wisdom-to-conf = "${bindir}/fftw-wisdom-to-conf"
-
-FILES_${PN}-dev += "${libdir}/cmake"
-RDEPENDS_${PN}-dev = "libfftw libfftwl libfftwf"
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-support/fftw/fftw_3.3.8.bb b/meta-openembedded/meta-oe/recipes-support/fftw/fftw_3.3.8.bb
new file mode 100644
index 0000000..d9e0ea3
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/fftw/fftw_3.3.8.bb
@@ -0,0 +1,83 @@
+DESCRIPTION = "FFTW"
+SECTION = "libs"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552"
+
+SRC_URI = " \
+    http://www.fftw.org/fftw-${PV}.tar.gz \
+    file://0001-NEON-autodetection-segfaults-assume-neon-present.patch \
+"
+SRC_URI[md5sum] = "8aac833c943d8e90d51b697b27d4384d"
+SRC_URI[sha256sum] = "6113262f6e92c5bd474f2875fa1b01054c4ad5040f6b0da7c03c98821d9ae303"
+
+inherit autotools pkgconfig
+
+# we had multiple recipes in the past
+PROVIDES = "fftwl fftwf"
+
+EXTRA_OECONF = "--disable-fortran --enable-shared --enable-threads"
+
+CFLAGS += "-D_GNU_SOURCE"
+
+# neon is optional for arm version < 8 -> check tune features
+FFTW_NEON = "${@bb.utils.contains('TUNE_FEATURES', 'neon', '--enable-neon', '', d)}"
+# neon is suppored for arm version = 8 -> enable
+FFTW_NEON_aarch64 = "--enable-neon"
+FFTW_NEON_class-native = ""
+
+do_configure() {
+    # configure fftw
+    rm -rf ${WORKDIR}/build-fftw
+	mkdir -p ${B}
+    cd ${B}
+    # full (re)configure
+    autotools_do_configure
+    mv ${B} ${WORKDIR}/build-fftw
+
+    # configure fftwl
+    rm -rf ${WORKDIR}/build-fftwl
+	mkdir -p ${B}
+    cd ${B}
+    # configure only
+    oe_runconf  --enable-long-double
+    mv ${B} ${WORKDIR}/build-fftwl 
+
+    # configure fftwf
+    rm -rf ${WORKDIR}/build-fftwf
+	mkdir -p ${B}
+    cd ${B}
+    # configure only
+    oe_runconf --enable-single ${FFTW_NEON}
+    mv ${B} ${WORKDIR}/build-fftwf
+}
+
+do_compile() {
+    for lib in fftw fftwl fftwf; do
+        cd ${WORKDIR}/build-$lib
+        autotools_do_compile
+    done
+}
+
+do_install() {
+    for lib in fftw fftwl fftwf; do
+        cd ${WORKDIR}/build-$lib
+        autotools_do_install
+    done
+}
+
+
+PACKAGES =+ "libfftw libfftwl libfftwf"
+FILES_libfftw = "${libdir}/libfftw3.so.* ${libdir}/libfftw3_*.so.*"
+FILES_libfftwl = "${libdir}/libfftw3l.so.* ${libdir}/libfftw3l_*.so.*"
+FILES_libfftwf = "${libdir}/libfftw3f.so.* ${libdir}/libfftw3f_*.so.*"
+
+PACKAGES =+ "fftw-wisdom fftwl-wisdom fftwf-wisdom fftw-wisdom-to-conf"
+FILES_fftw-wisdom = "${bindir}/fftw-wisdom"
+FILES_fftwl-wisdom = "${bindir}/fftwl-wisdom"
+FILES_fftwf-wisdom = "${bindir}/fftwf-wisdom"
+FILES_fftw-wisdom-to-conf = "${bindir}/fftw-wisdom-to-conf"
+
+FILES_${PN}-dev += "${libdir}/cmake"
+RDEPENDS_${PN}-dev = "libfftw libfftwl libfftwf"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-support/fltk/fltk.inc b/meta-openembedded/meta-oe/recipes-support/fltk/fltk.inc
index dbe700a..d3416c8 100644
--- a/meta-openembedded/meta-oe/recipes-support/fltk/fltk.inc
+++ b/meta-openembedded/meta-oe/recipes-support/fltk/fltk.inc
@@ -12,9 +12,9 @@
     file://0002-always-build-fluid-and-export-pointers.patch \
 "
 
-PV = "1.3.4-1"
-SRC_URI[md5sum] = "d7fcd27ab928648e1a1366dd2e273970"
-SRC_URI[sha256sum] = "7fb2c8882433ce694e6900c94fda505e8f4ed3fa9c7e597007098a33b85c53f4"
+PV = "1.3.4-2"
+SRC_URI[md5sum] = "b8e291343357e49dd81a22408744e400"
+SRC_URI[sha256sum] = "25d349c18c99508737d48f225a2eb26a43338f9247551cab72a317fa42cda910"
 
 inherit cmake pkgconfig
 
diff --git a/meta-openembedded/meta-oe/recipes-support/gd/gd/0001-annotate.c-gdft.c-Replace-strncpy-with-memccpy-to-fi.patch b/meta-openembedded/meta-oe/recipes-support/gd/gd/0001-annotate.c-gdft.c-Replace-strncpy-with-memccpy-to-fi.patch
new file mode 100644
index 0000000..c377b37
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/gd/gd/0001-annotate.c-gdft.c-Replace-strncpy-with-memccpy-to-fi.patch
@@ -0,0 +1,46 @@
+From 85c7694a5cf34597909bdd1ca6931b0f99904c2e Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Tue, 19 Jun 2018 00:40:49 -0700
+Subject: [PATCH] annotate.c/gdft.c: Replace strncpy with memccpy to fix
+ -Wstringop-truncation.
+
+Fixed for gcc8:
+git/src/gdft.c:1699:2: error: 'strncpy' output truncated before terminating nul copying as many bytes from a string as its length [-Werror=stringop-truncation]
+
+Upstream-Status: Submitted [https://github.com/libgd/libgd/pull/442]
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ src/annotate.c | 2 +-
+ src/gdft.c     | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/annotate.c b/src/annotate.c
+index 00aaf49..17df813 100644
+--- a/src/annotate.c
++++ b/src/annotate.c
+@@ -104,7 +104,7 @@ int main(int argc, char *argv[])
+ 					fprintf(stderr, "Font maximum length is 1024, %d given\n", font_len);
+ 					goto badLine;
+ 				}
+-				strncpy(font, st, font_len);
++				memcpy(font, st, font_len);
+ 			}
+ 		} else if(!strcmp(st, "align")) {
+ 			char *st = strtok(0, " \t\r\n");
+diff --git a/src/gdft.c b/src/gdft.c
+index 9fa8295..81dbe41 100644
+--- a/src/gdft.c
++++ b/src/gdft.c
+@@ -1696,7 +1696,7 @@ static char * font_path(char **fontpath, char *name_list)
+ 		gdFree(path);
+ 		return "could not alloc full list of fonts";
+ 	}
+-	strncpy(fontlist, name_list, name_list_len);
++	memcpy(fontlist, name_list, name_list_len);
+ 	fontlist[name_list_len] = 0;
+ 
+ 	/*
+-- 
+2.10.2
+
diff --git a/meta-openembedded/meta-oe/recipes-support/gd/gd/CVE-2018-1000222.patch b/meta-openembedded/meta-oe/recipes-support/gd/gd/CVE-2018-1000222.patch
new file mode 100644
index 0000000..25924d1
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/gd/gd/CVE-2018-1000222.patch
@@ -0,0 +1,82 @@
+From 4b1e18a00ce7c4b7e6919c3b3109a034393b805a Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Sat, 14 Jul 2018 13:54:08 -0400
+Subject: [PATCH] bmp: check return value in gdImageBmpPtr
+
+Closes #447.
+
+(cherry picked from commit ac16bdf2d41724b5a65255d4c28fb0ec46bc42f5)
+
+Upstream-Status: Backport [https://github.com/libgd/libgd/commit/4b1e18a00ce7c4b7e6919c3b3109a034393b805a]
+CVE: CVE-2018-1000222
+Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
+---
+ src/gd_bmp.c | 17 ++++++++++++++---
+ 1 file changed, 14 insertions(+), 3 deletions(-)
+
+diff --git a/src/gd_bmp.c b/src/gd_bmp.c
+index ccafdcd..d625da1 100644
+--- a/src/gd_bmp.c
++++ b/src/gd_bmp.c
+@@ -48,6 +48,8 @@ static int bmp_read_4bit(gdImagePtr im, gdIOCtxPtr infile, bmp_info_t *info, bmp
+ static int bmp_read_8bit(gdImagePtr im, gdIOCtxPtr infile, bmp_info_t *info, bmp_hdr_t *header);
+ static int bmp_read_rle(gdImagePtr im, gdIOCtxPtr infile, bmp_info_t *info);
+ 
++static int _gdImageBmpCtx(gdImagePtr im, gdIOCtxPtr out, int compression);
++
+ #define BMP_DEBUG(s)
+ 
+ static int gdBMPPutWord(gdIOCtx *out, int w)
+@@ -88,8 +90,10 @@ BGD_DECLARE(void *) gdImageBmpPtr(gdImagePtr im, int *size, int compression)
+ 	void *rv;
+ 	gdIOCtx *out = gdNewDynamicCtx(2048, NULL);
+ 	if (out == NULL) return NULL;
+-	gdImageBmpCtx(im, out, compression);
+-	rv = gdDPExtractData(out, size);
++	if (!_gdImageBmpCtx(im, out, compression))
++		rv = gdDPExtractData(out, size);
++	else
++		rv = NULL;
+ 	out->gd_free(out);
+ 	return rv;
+ }
+@@ -142,6 +146,11 @@ BGD_DECLARE(void) gdImageBmp(gdImagePtr im, FILE *outFile, int compression)
+ 		compression - whether to apply RLE or not.
+ */
+ BGD_DECLARE(void) gdImageBmpCtx(gdImagePtr im, gdIOCtxPtr out, int compression)
++{
++	_gdImageBmpCtx(im, out, compression);
++}
++
++static int _gdImageBmpCtx(gdImagePtr im, gdIOCtxPtr out, int compression)
+ {
+ 	int bitmap_size = 0, info_size, total_size, padding;
+ 	int i, row, xpos, pixel;
+@@ -149,6 +158,7 @@ BGD_DECLARE(void) gdImageBmpCtx(gdImagePtr im, gdIOCtxPtr out, int compression)
+ 	unsigned char *uncompressed_row = NULL, *uncompressed_row_start = NULL;
+ 	FILE *tmpfile_for_compression = NULL;
+ 	gdIOCtxPtr out_original = NULL;
++	int ret = 1;
+ 
+ 	/* No compression if its true colour or we don't support seek */
+ 	if (im->trueColor) {
+@@ -326,6 +336,7 @@ BGD_DECLARE(void) gdImageBmpCtx(gdImagePtr im, gdIOCtxPtr out, int compression)
+ 		out_original = NULL;
+ 	}
+ 
++	ret = 0;
+ cleanup:
+ 	if (tmpfile_for_compression) {
+ #ifdef _WIN32
+@@ -339,7 +350,7 @@ cleanup:
+ 	if (out_original) {
+ 		out_original->gd_free(out_original);
+ 	}
+-	return;
++	return ret;
+ }
+ 
+ static int compress_row(unsigned char *row, int length)
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-support/gd/gd_2.2.5.bb b/meta-openembedded/meta-oe/recipes-support/gd/gd_2.2.5.bb
index 63d9acf..548d2c5 100644
--- a/meta-openembedded/meta-oe/recipes-support/gd/gd_2.2.5.bb
+++ b/meta-openembedded/meta-oe/recipes-support/gd/gd_2.2.5.bb
@@ -14,6 +14,8 @@
 DEPENDS = "freetype libpng jpeg zlib tiff"
 
 SRC_URI = "git://github.com/libgd/libgd.git;branch=GD-2.2 \
+           file://0001-annotate.c-gdft.c-Replace-strncpy-with-memccpy-to-fi.patch \
+           file://CVE-2018-1000222.patch \
           "
 
 SRCREV = "8255231b68889597d04d451a72438ab92a405aba"
diff --git a/meta-openembedded/meta-oe/recipes-support/gflags/gflags_2.2.0.bb b/meta-openembedded/meta-oe/recipes-support/gflags/gflags_2.2.0.bb
index 28b652a..29a1125 100644
--- a/meta-openembedded/meta-oe/recipes-support/gflags/gflags_2.2.0.bb
+++ b/meta-openembedded/meta-oe/recipes-support/gflags/gflags_2.2.0.bb
@@ -1,7 +1,5 @@
 DESCRIPTION = "The gflags package contains a C++ library that implements commandline flags processing. It includes built-in support for standard types such as string and the ability to define flags in the source file in which they are used"
-
 HOMEPAGE = "https://github.com/gflags/gflags"
-
 LICENSE = "BSD-3-Clause"
 LIC_FILES_CHKSUM = "file://COPYING.txt;md5=c80d1a3b623f72bb85a4c75b556551df"
 
@@ -10,14 +8,13 @@
 
 S = "${WORKDIR}/git"
 
-FILES_${PN}-dev += "${libdir}/cmake"
-
 inherit cmake
 
 EXTRA_OECMAKE="-DBUILD_SHARED_LIBS=ON -DREGISTER_INSTALL_PREFIX=OFF -DLIB_INSTALL_DIR=${baselib}"
 
 PACKAGES =+ "${PN}-bash-completion"
 FILES_${PN}-bash-completion += "${bindir}/gflags_completions.sh"
+
 RDEPENDS_${PN}-bash-completion = "bash bash-completion"
 
-BBCLASSEXTEND = "native"
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-support/glog/glog/0001-Rework-CMake-glog-VERSION-management.patch b/meta-openembedded/meta-oe/recipes-support/glog/glog/0001-Rework-CMake-glog-VERSION-management.patch
new file mode 100644
index 0000000..f41a6c9
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/glog/glog/0001-Rework-CMake-glog-VERSION-management.patch
@@ -0,0 +1,71 @@
+From 4ea11e0d7c0575316a6ccc07a931164ca29c3d2f Mon Sep 17 00:00:00 2001
+From: Corentin Le Molgat <corentinl@google.com>
+Date: Mon, 29 Jan 2018 14:59:08 +0100
+Subject: [PATCH] Rework CMake glog VERSION management.
+
+- Use of Project version properties instead of custom variables
+- fix missmatch between VERSION (build version) and SOVERSION (API version)
+src: https://cmake.org/cmake/help/latest/prop_tgt/VERSION.html#prop_tgt:VERSION
+
+Upstream-Status: Backport [https://github.com/google/glog/commit/6b6e38a7d53fe01f42ce34384cf4ba4c50e8cb65]
+Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
+---
+ CMakeLists.txt | 23 ++++++++---------------
+ 1 file changed, 8 insertions(+), 15 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 7415eab..fb4e408 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -8,23 +8,16 @@ if (POLICY CMP0063)
+   cmake_policy (SET CMP0063 NEW)
+ endif (POLICY CMP0063)
+ 
+-project (google-glog)
++project(glog VERSION 0.3.5 LANGUAGES C CXX)
+ 
+ enable_testing ()
+ 
+-set (GLOG_MAJOR_VERSION 0)
+-set (GLOG_MINOR_VERSION 3)
+-set (GLOG_PATCH_VERSION 5)
+-
+-set (GLOG_VERSION
+-  ${GLOG_MAJOR_VERSION}.${GLOG_MINOR_VERSION}.${GLOG_PATCH_VERSION})
+-
+ set (CPACK_PACKAGE_NAME glog)
+ set (CPACK_PACKAGE_DESCRIPTION_SUMMARY "")
+-set (CPACK_PACKAGE_VERSION_MAJOR ${GLOG_MAJOR_VERSION})
+-set (CPACK_PACKAGE_VERSION_MINOR ${GLOG_MINOR_VERSION})
+-set (CPACK_PACKAGE_VERSION_PATCH ${GLOG_PATCH_VERSION})
+-set (CPACK_PACKAGE_VERSION ${GLOG_VERSION})
++set (CPACK_PACKAGE_VERSION_MAJOR ${PROJECT_VERSION_MAJOR})
++set (CPACK_PACKAGE_VERSION_MINOR ${PROJECT_VERSION_MINOR})
++set (CPACK_PACKAGE_VERSION_PATCH ${PROJECT_VERSION_PATCH})
++set (CPACK_PACKAGE_VERSION ${PROJECT_VERSION})
+ 
+ option (WITH_GFLAGS "Use gflags" ON)
+ option (WITH_THREADS "Enable multithreading support" ON)
+@@ -406,8 +399,8 @@ if (gflags_FOUND)
+   endif (NOT BUILD_SHARED_LIBS)
+ endif (gflags_FOUND)
+ 
+-set_target_properties (glog PROPERTIES VERSION ${GLOG_MAJOR_VERSION})
+-set_target_properties (glog PROPERTIES SOVERSION ${GLOG_VERSION})
++set_target_properties (glog PROPERTIES VERSION ${PROJECT_VERSION})
++set_target_properties (glog PROPERTIES SOVERSION ${PROJECT_VERSION_MAJOR})
+ 
+ if (WIN32)
+   target_compile_definitions (glog PUBLIC GLOG_NO_ABBREVIATED_SEVERITIES)
+@@ -570,7 +563,7 @@ configure_package_config_file (glog-config.cmake.in
+   NO_CHECK_REQUIRED_COMPONENTS_MACRO)
+ 
+ write_basic_package_version_file (glog-config-version.cmake VERSION
+-  ${GLOG_VERSION} COMPATIBILITY SameMajorVersion)
++  ${PROJECT_VERSION} COMPATIBILITY SameMajorVersion)
+ 
+ export (TARGETS glog NAMESPACE glog:: FILE glog-targets.cmake)
+ export (PACKAGE glog)
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-oe/recipes-support/glog/glog/0001-configure.ac-Allow-user-to-disable-gflags.patch b/meta-openembedded/meta-oe/recipes-support/glog/glog/0001-configure.ac-Allow-user-to-disable-gflags.patch
deleted file mode 100644
index 596281f..0000000
--- a/meta-openembedded/meta-oe/recipes-support/glog/glog/0001-configure.ac-Allow-user-to-disable-gflags.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From 0fabde0515e180c53961c27346dd7a79cffa4c1f Mon Sep 17 00:00:00 2001
-From: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
-Date: Thu, 11 Aug 2016 11:49:36 +0200
-Subject: [PATCH] configure.ac: Allow user to disable gflags
-
-Under some circumstances like cross-compilation, the user might not want
-to enable support for gflags.
-
-This patch allows support for --without-gflags
-
-Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
----
- configure.ac | 6 +++++-
- 1 file changed, 5 insertions(+), 1 deletion(-)
-
-diff --git a/configure.ac b/configure.ac
-index 7b4d21e7ae8a..eba5e5cda1ea 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -136,7 +136,11 @@ AC_ARG_WITH(gflags, AS_HELP_STRING[--with-gflags=GFLAGS_DIR],
-   CFLAGS="$CFLAGS $GFLAGS_CFLAGS"
-   LIBS="$LIBS $GFLAGS_LIBS"
- )
--AC_CHECK_LIB(gflags, main, ac_cv_have_libgflags=1, ac_cv_have_libgflags=0)
-+if test x"$with_gflags" = x"no"; then
-+  ac_cv_have_libgflags=0
-+else
-+  AC_CHECK_LIB(gflags, main, ac_cv_have_libgflags=1, ac_cv_have_libgflags=0)
-+fi
- if test x"$ac_cv_have_libgflags" = x"1"; then
-   AC_DEFINE(HAVE_LIB_GFLAGS, 1, [define if you have google gflags library])
-   if test x"$GFLAGS_LIBS" = x""; then
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/glog/glog/0002-Find-Libunwind-during-configure.patch b/meta-openembedded/meta-oe/recipes-support/glog/glog/0002-Find-Libunwind-during-configure.patch
new file mode 100644
index 0000000..15cf67f
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/glog/glog/0002-Find-Libunwind-during-configure.patch
@@ -0,0 +1,120 @@
+diff -uNr a/cmake/FindLibunwind.cmake b/cmake/FindLibunwind.cmake
+--- a/cmake/FindLibunwind.cmake	1970-01-01 01:00:00.000000000 +0100
++++ b/cmake/FindLibunwind.cmake	2018-11-20 15:53:48.799078114 +0100
+@@ -0,0 +1,54 @@
++# - Try to find libunwind
++# Once done this will define
++#
++#  Libunwind_FOUND - system has libunwind
++#  unwind - cmake target for libunwind
++
++find_library (UNWIND_LIBRARY NAMES unwind DOC "unwind library")
++include (CheckIncludeFile)
++check_include_file (libunwind.h HAVE_LIBUNWIND_H)
++check_include_file (unwind.h HAVE_UNWIND_H)
++
++if (CMAKE_SYSTEM_PROCESSOR MATCHES "^arm")
++    set(LIBUNWIND_ARCH "arm")
++elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "^aarch64")
++    set(LIBUNWIND_ARCH "aarch64")
++elseif (CMAKE_SYSTEM_PROCESSOR STREQUAL "x86_64" OR
++        CMAKE_SYSTEM_PROCESSOR STREQUAL "amd64" OR
++        CMAKE_SYSTEM_PROCESSOR STREQUAL "corei7-64")
++    set(LIBUNWIND_ARCH "x86_64")
++elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "^i.86$")
++    set(LIBUNWIND_ARCH "x86")
++elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "^ppc64")
++    set(LIBUNWIND_ARCH "ppc64")
++elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "^ppc")
++    set(LIBUNWIND_ARCH "ppc32")
++elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "^mips")
++    set(LIBUNWIND_ARCH "mips")
++elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "^hppa")
++    set(LIBUNWIND_ARCH "hppa")
++elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "^ia64")
++    set(LIBUNWIND_ARCH "ia64")
++endif()
++
++find_library (UNWIND_LIBRARY_PLATFORM NAMES "unwind-${LIBUNWIND_ARCH}" DOC "unwind library platform")
++if (UNWIND_LIBRARY_PLATFORM)
++    set(HAVE_LIB_UNWIND "1")
++endif()
++
++include(FindPackageHandleStandardArgs)
++# handle the QUIETLY and REQUIRED arguments and set Libunwind_FOUND to TRUE
++# if all listed variables are TRUE
++find_package_handle_standard_args(Libunwind DEFAULT_MSG
++    UNWIND_LIBRARY HAVE_LIBUNWIND_H HAVE_UNWIND_H HAVE_LIB_UNWIND)
++
++mark_as_advanced (UNWIND_LIBRARY UNWIND_LIBRARY_PLATFORM)
++
++if (Libunwind_FOUND)
++    add_library(unwind INTERFACE IMPORTED)
++    set_target_properties(unwind PROPERTIES
++        INTERFACE_LINK_LIBRARIES "${UNWIND_LIBRARY};${UNWIND_LIBRARY_PLATFORM}"
++    )
++else()
++    message("Can't find libunwind library")
++endif()
+diff -uNr a/CMakeLists.txt b/CMakeLists.txt
+--- a/CMakeLists.txt	2018-11-20 15:49:07.576278417 +0100
++++ b/CMakeLists.txt	2018-11-20 15:49:32.106819928 +0100
+@@ -58,7 +58,6 @@
+ check_include_file (execinfo.h HAVE_EXECINFO_H)
+ check_include_file (glob.h HAVE_GLOB_H)
+ check_include_file (inttypes.h HAVE_INTTYPES_H)
+-check_include_file (libunwind.h HAVE_LIBUNWIND_H)
+ check_include_file (memory.h HAVE_MEMORY_H)
+ check_include_file (pwd.h HAVE_PWD_H)
+ check_include_file (stdint.h HAVE_STDINT_H)
+@@ -74,7 +73,6 @@
+ check_include_file (syslog.h HAVE_SYSLOG_H)
+ check_include_file (ucontext.h HAVE_UCONTEXT_H)
+ check_include_file (unistd.h HAVE_UNISTD_H)
+-check_include_file (unwind.h HAVE_UNWIND_H)
+ 
+ check_include_file_cxx ("ext/hash_map" HAVE_EXT_HASH_MAP)
+ check_include_file_cxx ("ext/hash_set" HAVE_EXT_HASH_SET)
+@@ -109,10 +107,7 @@
+ # snprintf as an inline function
+ check_symbol_exists (snprintf stdio.h HAVE_SNPRINTF)
+ 
+-check_library_exists (unwind get_static_proc_name "" HAVE_LIB_UNWIND)
+-
+-find_library (UNWIND_LIBRARY NAMES unwind DOC "unwind library")
+-mark_as_advanced (UNWIND_LIBRARY)
++find_package(Libunwind)
+ 
+ check_c_source_compiles ("
+ #include <stdlib.h>
+@@ -376,9 +371,9 @@
+ 
+ set_target_properties (glog PROPERTIES POSITION_INDEPENDENT_CODE ON)
+ 
+-if (UNWIND_LIBRARY)
+-  target_link_libraries (glog PUBLIC ${UNWIND_LIBRARY})
+-endif (UNWIND_LIBRARY)
++if (Libunwind_FOUND)
++  target_link_libraries (glog PUBLIC unwind)
++endif (Libunwind_FOUND)
+ 
+ if (HAVE_PTHREAD)
+   target_link_libraries (glog PUBLIC ${CMAKE_THREAD_LIBS_INIT})
+@@ -571,6 +566,7 @@
+ install (FILES
+   ${CMAKE_CURRENT_BINARY_DIR}/glog-config.cmake
+   ${CMAKE_CURRENT_BINARY_DIR}/glog-config-version.cmake
++  ${CMAKE_CURRENT_SOURCE_DIR}/cmake/FindLibunwind.cmake
+   DESTINATION lib/cmake/glog)
+ 
+ install (EXPORT glog-targets NAMESPACE glog:: DESTINATION lib/cmake/glog)
+diff -uNr a/glog-config.cmake.in b/glog-config.cmake.in
+--- a/glog-config.cmake.in	2018-11-20 15:49:07.576278417 +0100
++++ b/glog-config.cmake.in	2018-11-20 15:52:32.330418489 +0100
+@@ -4,4 +4,6 @@
+ 
+ @gflags_DEPENDENCY@
+ 
++find_dependency (Libunwind)
++
+ include ("${CMAKE_CURRENT_LIST_DIR}/glog-targets.cmake")
diff --git a/meta-openembedded/meta-oe/recipes-support/glog/glog/0003-installation-path-fix.patch b/meta-openembedded/meta-oe/recipes-support/glog/glog/0003-installation-path-fix.patch
new file mode 100644
index 0000000..641f70c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/glog/glog/0003-installation-path-fix.patch
@@ -0,0 +1,65 @@
+diff -uNr a/CMakeLists.txt b/CMakeLists.txt
+--- a/CMakeLists.txt	2018-12-05 12:55:59.630792054 +0100
++++ b/CMakeLists.txt	2018-12-05 13:00:22.922269200 +0100
+@@ -403,10 +403,15 @@
+ 
+ set_target_properties (glog PROPERTIES PUBLIC_HEADER "${GLOG_PUBLIC_H}")
+ 
++set (_glog_CMake_BINDIR ${CMAKE_INSTALL_BINDIR})
++set (_glog_CMake_INCLUDE_DIR ${CMAKE_INSTALL_INCLUDEDIR})
++set (_glog_CMake_LIBDIR ${CMAKE_INSTALL_LIBDIR})
++set (_glog_CMake_INSTALLDIR ${_glog_CMake_LIBDIR}/cmake/glog)
++
+ target_include_directories (glog BEFORE PUBLIC
+   "$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>"
+   "$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src>"
+-  "$<INSTALL_INTERFACE:include>"
++  "$<INSTALL_INTERFACE:${_glog_CMake_INCLUDE_DIR}>"
+   PRIVATE ${CMAKE_CURRENT_BINARY_DIR}
+   PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/src)
+ 
+@@ -543,10 +548,10 @@
+ 
+ install (TARGETS glog
+   EXPORT glog-targets
+-  RUNTIME DESTINATION bin
+-  PUBLIC_HEADER DESTINATION include/glog
+-  LIBRARY DESTINATION lib
+-  ARCHIVE DESTINATION lib)
++  RUNTIME DESTINATION ${_glog_CMake_BINDIR}
++  PUBLIC_HEADER DESTINATION ${_glog_CMake_INCLUDE_DIR}/glog
++  LIBRARY DESTINATION ${_glog_CMake_LIBDIR}
++  ARCHIVE DESTINATION ${_glog_CMake_LIBDIR})
+ 
+ if (gflags_FOUND)
+   set (gflags_DEPENDENCY "find_dependency (gflags ${gflags_VERSION})")
+@@ -554,7 +559,7 @@
+ 
+ configure_package_config_file (glog-config.cmake.in
+   ${CMAKE_CURRENT_BINARY_DIR}/glog-config.cmake
+-  INSTALL_DESTINATION lib/cmake/glog
++  INSTALL_DESTINATION ${_glog_CMake_INSTALLDIR}
+   NO_CHECK_REQUIRED_COMPONENTS_MACRO)
+ 
+ write_basic_package_version_file (glog-config-version.cmake VERSION
+@@ -567,6 +572,7 @@
+   ${CMAKE_CURRENT_BINARY_DIR}/glog-config.cmake
+   ${CMAKE_CURRENT_BINARY_DIR}/glog-config-version.cmake
+   ${CMAKE_CURRENT_SOURCE_DIR}/cmake/FindLibunwind.cmake
+-  DESTINATION lib/cmake/glog)
++  DESTINATION ${_glog_CMake_INSTALLDIR})
+ 
+-install (EXPORT glog-targets NAMESPACE glog:: DESTINATION lib/cmake/glog)
++install (EXPORT glog-targets NAMESPACE glog:: DESTINATION
++  ${_glog_CMake_INSTALLDIR})
+diff -uNr a/glog-config.cmake.in b/glog-config.cmake.in
+--- a/glog-config.cmake.in	2018-12-05 12:55:59.630792054 +0100
++++ b/glog-config.cmake.in	2018-12-05 13:05:19.547196843 +0100
+@@ -4,6 +4,7 @@
+ 
+ @gflags_DEPENDENCY@
+ 
++list (APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}")
+ find_dependency (Libunwind)
+ 
+ include ("${CMAKE_CURRENT_LIST_DIR}/glog-targets.cmake")
diff --git a/meta-openembedded/meta-oe/recipes-support/glog/glog_0.3.4.bb b/meta-openembedded/meta-oe/recipes-support/glog/glog_0.3.4.bb
deleted file mode 100644
index d7c1974..0000000
--- a/meta-openembedded/meta-oe/recipes-support/glog/glog_0.3.4.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-DESCRIPTION = "The glog library implements application-level logging. This \
-library provides logging APIs based on C++-style streams and various helper \
-macros."
-HOMEPAGE = "https://github.com/google/glog"
-
-LICENSE = "BSD-3-Clause"
-LIC_FILES_CHKSUM = "file://COPYING;md5=dc9db360e0bbd4e46672f3fd91dd6c4b"
-
-DEPENDS = "libunwind"
-
-SRC_URI = " \
-    git://github.com/google/glog.git \
-    file://0001-configure.ac-Allow-user-to-disable-gflags.patch \
-"
-
-SRCREV = "d8cb47f77d1c31779f3ff890e1a5748483778d6a"
-
-S = "${WORKDIR}/git"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[gflags] = ",--without-gflags,gflags,"
-
-inherit autotools pkgconfig
diff --git a/meta-openembedded/meta-oe/recipes-support/glog/glog_0.3.5.bb b/meta-openembedded/meta-oe/recipes-support/glog/glog_0.3.5.bb
new file mode 100644
index 0000000..3de01ef
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/glog/glog_0.3.5.bb
@@ -0,0 +1,26 @@
+DESCRIPTION = "The glog library implements application-level logging. This \
+library provides logging APIs based on C++-style streams and various helper \
+macros."
+HOMEPAGE = "https://github.com/google/glog"
+
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://COPYING;md5=dc9db360e0bbd4e46672f3fd91dd6c4b"
+
+DEPENDS = "libunwind"
+
+SRC_URI = " \
+    git://github.com/google/glog.git;branch=v035 \
+    file://0001-Rework-CMake-glog-VERSION-management.patch \
+    file://0002-Find-Libunwind-during-configure.patch \
+    file://0003-installation-path-fix.patch \
+"
+
+SRCREV = "a6a166db069520dbbd653c97c2e5b12e08a8bb26"
+
+S = "${WORKDIR}/git"
+
+inherit cmake
+
+RDEPENDS_${PN} += "libunwind"
+
+EXTRA_OECMAKE += "-DBUILD_SHARED_LIBS=ON"
diff --git a/meta-openembedded/meta-oe/recipes-support/gnulib/gnulib/CVE-2018-17942.patch b/meta-openembedded/meta-oe/recipes-support/gnulib/gnulib/CVE-2018-17942.patch
new file mode 100644
index 0000000..77e82b1
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/gnulib/gnulib/CVE-2018-17942.patch
@@ -0,0 +1,88 @@
+From e91600a7aae3bafbefbe13abf771e61badd16286 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Tue, 16 Oct 2018 14:26:11 +0800
+Subject: [PATCH] vasnprintf: Fix heap memory overrun bug.
+
+Reported by Ben Pfaff <blp@cs.stanford.edu> in
+<https://lists.gnu.org/archive/html/bug-gnulib/2018-09/msg00107.html>.
+
+* lib/vasnprintf.c (convert_to_decimal): Allocate one more byte of
+memory.
+* tests/test-vasnprintf.c (test_function): Add another test.
+
+Upstream-Status: Backport [http://git.savannah.gnu.org/gitweb/?p=gnulib.git;
+a=commitdiff;h=278b4175c9d7dd47c1a3071554aac02add3b3c35]
+
+CVE: CVE-2018-17942
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ ChangeLog               |  8 ++++++++
+ lib/vasnprintf.c        |  4 +++-
+ tests/test-vasnprintf.c | 19 ++++++++++++++++++-
+ 3 files changed, 29 insertions(+), 2 deletions(-)
+
+diff --git a/ChangeLog b/ChangeLog
+index 9864353..5ff76a3 100644
+--- a/ChangeLog
++++ b/ChangeLog
+@@ -1,3 +1,11 @@
++2018-09-23  Bruno Haible  <bruno@clisp.org>
++ 	vasnprintf: Fix heap memory overrun bug.
++	Reported by Ben Pfaff <blp@cs.stanford.edu> in
++	<https://lists.gnu.org/archive/html/bug-gnulib/2018-09/msg00107.html>.
++	* lib/vasnprintf.c (convert_to_decimal): Allocate one more byte of
++	memory.
++	* tests/test-vasnprintf.c (test_function): Add another test.
++
+ 2017-08-21  Paul Eggert  <eggert@cs.ucla.edu>
+ 
+ 	vc-list-files: port to Solaris 10
+diff --git a/lib/vasnprintf.c b/lib/vasnprintf.c
+index 2e4eb19..45de49f 100644
+--- a/lib/vasnprintf.c
++++ b/lib/vasnprintf.c
+@@ -860,7 +860,9 @@ convert_to_decimal (mpn_t a, size_t extra_zeroes)
+   size_t a_len = a.nlimbs;
+   /* 0.03345 is slightly larger than log(2)/(9*log(10)).  */
+   size_t c_len = 9 * ((size_t)(a_len * (GMP_LIMB_BITS * 0.03345f)) + 1);
+-  char *c_ptr = (char *) malloc (xsum (c_len, extra_zeroes));
++  /* We need extra_zeroes bytes for zeroes, followed by c_len bytes for the
++     digits of a, followed by 1 byte for the terminating NUL.  */
++  char *c_ptr = (char *) malloc (xsum (xsum (extra_zeroes, c_len), 1));
+   if (c_ptr != NULL)
+     {
+       char *d_ptr = c_ptr;
+diff --git a/tests/test-vasnprintf.c b/tests/test-vasnprintf.c
+index 2dd869f..ff68d5c 100644
+--- a/tests/test-vasnprintf.c
++++ b/tests/test-vasnprintf.c
+@@ -53,7 +53,24 @@ test_function (char * (*my_asnprintf) (char *, size_t *, const char *, ...))
+       ASSERT (result != NULL);
+       ASSERT (strcmp (result, "12345") == 0);
+       ASSERT (length == 5);
+-      if (size < 6)
++      if (size < 5 + 1)
++        ASSERT (result != buf);
++      ASSERT (memcmp (buf + size, &"DEADBEEF"[size], 8 - size) == 0);
++      if (result != buf)
++        free (result);
++    }
++   /* Note: This test assumes IEEE 754 representation of 'double' floats.  */
++  for (size = 0; size <= 8; size++)
++    {
++      size_t length;
++      char *result;
++       memcpy (buf, "DEADBEEF", 8);
++      length = size;
++      result = my_asnprintf (buf, &length, "%2.0f", 1.6314159265358979e+125);
++      ASSERT (result != NULL);
++      ASSERT (strcmp (result, "163141592653589790215729350939528493057529598899734151772468186268423257777068536614838678161083520756952076273094236944990208") == 0);
++      ASSERT (length == 126);
++      if (size < 126 + 1)
+         ASSERT (result != buf);
+       ASSERT (memcmp (buf + size, &"DEADBEEF"[size], 8 - size) == 0);
+       if (result != buf)
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/gnulib/gnulib_2017-08-20.18.bb b/meta-openembedded/meta-oe/recipes-support/gnulib/gnulib_2017-08-20.18.bb
index b72ffa9..e048810 100644
--- a/meta-openembedded/meta-oe/recipes-support/gnulib/gnulib_2017-08-20.18.bb
+++ b/meta-openembedded/meta-oe/recipes-support/gnulib/gnulib_2017-08-20.18.bb
@@ -14,6 +14,7 @@
 SRCREV = "b23000de1e47c7d580e0e220966dd1ee42a5e5bc"
 
 SRC_URI = "git://git.sv.gnu.org/gnulib;protocol=git \
+           file://CVE-2018-17942.patch \
 "
 
 S = "${WORKDIR}/git"
@@ -22,6 +23,8 @@
     cd ${S}
     git checkout master
     git clone ${S} ${D}/${datadir}/gnulib
+    cd ${D}/${datadir}/gnulib
+    git am ${WORKDIR}/CVE-2018-17942.patch
 }
 
 do_patch[noexec] = "1"
@@ -32,5 +35,6 @@
 deltask package_write_ipk
 deltask package_write_deb
 deltask package_write_rpm
+deltask do_deploy_archives 
 
 BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools/0001-Use-ucontext_t-instead-of-struct-ucontext.patch b/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools/0001-Use-ucontext_t-instead-of-struct-ucontext.patch
deleted file mode 100644
index b303362..0000000
--- a/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools/0001-Use-ucontext_t-instead-of-struct-ucontext.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From 230cd84486145c5bb1d69d4c9a544e00adbcc9b5 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 1 Jul 2017 13:21:21 -0700
-Subject: [PATCH] Use ucontext_t instead of struct ucontext
-
-Newer glibc has dropped the ucontext tag from exposing
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
----
- src/stacktrace_powerpc-linux-inl.h | 3 +--
- 1 file changed, 1 insertion(+), 2 deletions(-)
-
-diff --git a/src/stacktrace_powerpc-linux-inl.h b/src/stacktrace_powerpc-linux-inl.h
-index 3b3843b..a301a46 100644
---- a/src/stacktrace_powerpc-linux-inl.h
-+++ b/src/stacktrace_powerpc-linux-inl.h
-@@ -53,7 +53,6 @@
- #elif defined(HAVE_UCONTEXT_H)
- #include <ucontext.h>  // for ucontext_t
- #endif
--typedef ucontext ucontext_t;
- 
- // PowerPC64 Little Endian follows BE wrt. backchain, condition register,
- // and LR save area, so no need to adjust the reading struct.
-@@ -202,7 +201,7 @@ static int GET_STACK_TRACE_OR_FRAMES {
-         struct rt_signal_frame_32 {
-           char dummy[64 + 16];
-           siginfo_t info;
--          struct ucontext uc;
-+          ucontext_t uc;
-           // We don't care about the rest, since IP value is at 'uc' field.A
-         } *sigframe = reinterpret_cast<rt_signal_frame_32*>(current);
-         result[n] = (void*) sigframe->uc.uc_mcontext.uc_regs->gregs[PT_NIP];
diff --git a/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools/0001-fix-build-with-musl-libc.patch b/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools/0001-fix-build-with-musl-libc.patch
index 0a72ff2..49d5c21 100644
--- a/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools/0001-fix-build-with-musl-libc.patch
+++ b/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools/0001-fix-build-with-musl-libc.patch
@@ -1,4 +1,4 @@
-From 034e7da08c3fbffcba8cf8d4e24a71a16558db5a Mon Sep 17 00:00:00 2001
+From 696674a800cb6d2070897a565b92d7e63022a8f1 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sun, 16 Jul 2017 15:51:28 -0700
 Subject: [PATCH] fix build with musl libc
@@ -13,7 +13,7 @@
  2 files changed, 7 insertions(+), 2 deletions(-)
 
 diff --git a/configure.ac b/configure.ac
-index b42fea3..70b49a3 100644
+index 497103e..f9efc3e 100644
 --- a/configure.ac
 +++ b/configure.ac
 @@ -188,6 +188,7 @@ AC_HEADER_STDC
@@ -25,7 +25,7 @@
  AC_CHECK_FUNCS(geteuid)         # for turning off services when run as root
  AC_CHECK_FUNCS(fork)            # for the pthread_atfork setup
 diff --git a/src/malloc_hook_mmap_linux.h b/src/malloc_hook_mmap_linux.h
-index 79ac4e3..d444635 100755
+index 2f6116f..0605855 100755
 --- a/src/malloc_hook_mmap_linux.h
 +++ b/src/malloc_hook_mmap_linux.h
 @@ -46,6 +46,10 @@
@@ -55,5 +55,5 @@
 -#ifndef __UCLIBC__
 +#if HAVE___SBRK
  // libc's version:
- extern "C" void* __sbrk(ptrdiff_t increment);
+ extern "C" void* __sbrk(intptr_t increment);
  
diff --git a/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools/0001-include-fcntl.h-for-loff_t-definition.patch b/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools/0001-include-fcntl.h-for-loff_t-definition.patch
deleted file mode 100644
index 4c63e73..0000000
--- a/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools/0001-include-fcntl.h-for-loff_t-definition.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-From a16a73f0819d26219ee83cd98eea82786d7c1755 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 16 Jul 2017 19:28:17 -0700
-Subject: [PATCH] include fcntl.h for loff_t definition
-
-Fixes
-linux_syscall_support.h:2641:26: error: 'loff_t' has not been declared
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
----
- src/base/linux_syscall_support.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/src/base/linux_syscall_support.h b/src/base/linux_syscall_support.h
-index 85347a2..70431ca 100644
---- a/src/base/linux_syscall_support.h
-+++ b/src/base/linux_syscall_support.h
-@@ -162,6 +162,7 @@ extern "C" {
- #include <unistd.h>
- #include <linux/unistd.h>
- #include <endian.h>
-+#include <fcntl.h>
- 
- #ifdef __mips__
- /* Include definitions of the ABI currently in use.                          */
diff --git a/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools_2.6.1.bb b/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools_2.6.1.bb
deleted file mode 100644
index ecac6c5..0000000
--- a/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools_2.6.1.bb
+++ /dev/null
@@ -1,27 +0,0 @@
-SUMMARY = "Fast, multi-threaded malloc() and nifty performance analysis tools"
-HOMEPAGE = "https://github.com/gperftools/gperftools"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=762732742c73dc6c7fbe8632f06c059a"
-DEPENDS += "libunwind"
-
-SRCREV = "bf840dec0495e17f5c8403e68e10b9d6bf05c559"
-SRC_URI = "git://github.com/gperftools/gperftools \
-           file://0001-Support-Atomic-ops-on-clang.patch \
-           file://0001-Use-ucontext_t-instead-of-struct-ucontext.patch \
-           file://0001-fix-build-with-musl-libc.patch \
-           file://0001-include-fcntl.h-for-loff_t-definition.patch \
-           file://0001-disbale-heap-checkers-and-debug-allocator-on-musl.patch \
-           file://disable_libunwind_aarch64.patch \
-           file://sgidef.patch \
-           "
-
-inherit autotools
-
-S = "${WORKDIR}/git"
-
-# Disable thumb1
-# {standard input}: Assembler messages:
-# {standard input}:434: Error: lo register required -- `ldr pc,[sp]'
-# Makefile:4538: recipe for target 'src/base/libtcmalloc_la-linuxthreads.lo' failed
-ARM_INSTRUCTION_SET_armv5 = "arm"
-
diff --git a/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools_2.7.bb b/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools_2.7.bb
new file mode 100644
index 0000000..e9fcc4c
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/gperftools/gperftools_2.7.bb
@@ -0,0 +1,29 @@
+SUMMARY = "Fast, multi-threaded malloc() and nifty performance analysis tools"
+HOMEPAGE = "https://github.com/gperftools/gperftools"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=762732742c73dc6c7fbe8632f06c059a"
+DEPENDS += "libunwind"
+
+SRCREV = "9608fa3bcf8020d35f59fbf70cd3cbe4b015b972"
+SRC_URI = "git://github.com/gperftools/gperftools \
+           file://0001-Support-Atomic-ops-on-clang.patch \
+           file://0001-fix-build-with-musl-libc.patch \
+           file://0001-disbale-heap-checkers-and-debug-allocator-on-musl.patch \
+           file://disable_libunwind_aarch64.patch \
+           file://sgidef.patch \
+           "
+
+inherit autotools
+
+S = "${WORKDIR}/git"
+
+# On mips, we have the following error.
+#   do_page_fault(): sending SIGSEGV to ls for invalid read access from 00000008
+#   Segmentation fault (core dumped)
+COMPATIBLE_HOST_mipsarch_libc-glibc = "null"
+# Disable thumb1
+# {standard input}: Assembler messages:
+# {standard input}:434: Error: lo register required -- `ldr pc,[sp]'
+# Makefile:4538: recipe for target 'src/base/libtcmalloc_la-linuxthreads.lo' failed
+ARM_INSTRUCTION_SET_armv5 = "arm"
+
diff --git a/meta-openembedded/meta-oe/recipes-support/gpm/gpm_git.bb b/meta-openembedded/meta-oe/recipes-support/gpm/gpm_git.bb
index 51c4dd6..dcc9d68 100644
--- a/meta-openembedded/meta-oe/recipes-support/gpm/gpm_git.bb
+++ b/meta-openembedded/meta-oe/recipes-support/gpm/gpm_git.bb
@@ -9,7 +9,7 @@
 PR = "r2"
 SRCREV = "1fd19417b8a4dd9945347e98dfa97e4cfd798d77"
 
-DEPENDS = "ncurses"
+DEPENDS = "ncurses bison-native"
 
 SRC_URI = "git://github.com/telmich/gpm;protocol=git \
            file://init \
diff --git a/meta-openembedded/meta-oe/recipes-support/gradm/gradm_3.1.bb b/meta-openembedded/meta-oe/recipes-support/gradm/gradm_3.1.bb
index 1a4261a..a7d0607 100644
--- a/meta-openembedded/meta-oe/recipes-support/gradm/gradm_3.1.bb
+++ b/meta-openembedded/meta-oe/recipes-support/gradm/gradm_3.1.bb
@@ -43,10 +43,6 @@
     rm -rf ${D}/dev
 }
 
-pkg_postinst_${PN}() {
-    # make sure running on the target
-    if [ x"$D" != "x" ]; then
-        exit 1
-    fi
+pkg_postinst_ontarget_${PN}() {
     /bin/mknod -m 0622 /dev/grsec c 1 13
 }
diff --git a/meta-openembedded/meta-oe/recipes-support/gsoap/gsoap_2.8.51.bb b/meta-openembedded/meta-oe/recipes-support/gsoap/gsoap_2.8.51.bb
index 8875844..36530d2 100644
--- a/meta-openembedded/meta-oe/recipes-support/gsoap/gsoap_2.8.51.bb
+++ b/meta-openembedded/meta-oe/recipes-support/gsoap/gsoap_2.8.51.bb
@@ -22,7 +22,7 @@
 
 EXTRA_OEMAKE_class-target = "SOAP=${STAGING_BINDIR_NATIVE}/soapcpp2"
 
-DEPENDS = "openssl zlib flex bison"
+DEPENDS = "openssl zlib flex bison bison-native"
 DEPENDS_append_class-target = " gsoap-native"
 
 do_install_append() {
diff --git a/meta-openembedded/meta-oe/recipes-support/htop/htop_2.1.0.bb b/meta-openembedded/meta-oe/recipes-support/htop/htop_2.1.0.bb
deleted file mode 100644
index 33508f9..0000000
--- a/meta-openembedded/meta-oe/recipes-support/htop/htop_2.1.0.bb
+++ /dev/null
@@ -1,35 +0,0 @@
-SUMMARY = "Interactive process viewer"
-HOMEPAGE = "http://hisham.hm/htop"
-SECTION = "console/utils"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=c312653532e8e669f30e5ec8bdc23be3"
-
-DEPENDS = "ncurses"
-
-SRC_URI = "http://hisham.hm/htop/releases/${PV}/${BP}.tar.gz \
-           file://0001-Use-pkg-config.patch"
-SRC_URI[md5sum] = "f262b66ad6c194782f4d3a80627e84c8"
-SRC_URI[sha256sum] = "3260be990d26e25b6b49fc9d96dbc935ad46e61083c0b7f6df413e513bf80748"
-
-inherit autotools pkgconfig
-
-PACKAGECONFIG ??= "proc \
-                   cgroup \
-                   taskstats \
-                   unicode \
-                   linux-affinity \
-                   delayacct"
-PACKAGECONFIG[proc] = "--enable-proc,--disable-proc"
-PACKAGECONFIG[openvz] = "--enable-openvz,--disable-openvz"
-PACKAGECONFIG[cgroup] = "--enable-cgroup,--disable-cgroup"
-PACKAGECONFIG[vserver] = "--enable-vserver,--disable-vserver"
-PACKAGECONFIG[taskstats] = "--enable-taskstats,--disable-taskstats"
-PACKAGECONFIG[unicode] = "--enable-unicode,--disable-unicode"
-PACKAGECONFIG[linux-affinity] = "--enable-linux-affinity,--disable-linux-affinity"
-PACKAGECONFIG[hwloc] = "--enable-hwloc,--disable-hwloc,hwloc"
-PACKAGECONFIG[setuid] = "--enable-setuid,--disable-setuid"
-PACKAGECONFIG[delayacct] = "--enable-delayacct,--disable-delayacct,libnl"
-
-do_configure_prepend () {
-    rm -rf ${S}/config.h
-}
diff --git a/meta-openembedded/meta-oe/recipes-support/htop/htop_2.2.0.bb b/meta-openembedded/meta-oe/recipes-support/htop/htop_2.2.0.bb
new file mode 100644
index 0000000..01c856d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/htop/htop_2.2.0.bb
@@ -0,0 +1,35 @@
+SUMMARY = "Interactive process viewer"
+HOMEPAGE = "http://hisham.hm/htop"
+SECTION = "console/utils"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=c312653532e8e669f30e5ec8bdc23be3"
+
+DEPENDS = "ncurses"
+
+SRC_URI = "http://hisham.hm/htop/releases/${PV}/${BP}.tar.gz \
+           file://0001-Use-pkg-config.patch"
+SRC_URI[md5sum] = "0d816b6beed31edc75babcfbf863ffa8"
+SRC_URI[sha256sum] = "d9d6826f10ce3887950d709b53ee1d8c1849a70fa38e91d5896ad8cbc6ba3c57"
+
+inherit autotools pkgconfig
+
+PACKAGECONFIG ??= "proc \
+                   cgroup \
+                   taskstats \
+                   unicode \
+                   linux-affinity \
+                   delayacct"
+PACKAGECONFIG[proc] = "--enable-proc,--disable-proc"
+PACKAGECONFIG[openvz] = "--enable-openvz,--disable-openvz"
+PACKAGECONFIG[cgroup] = "--enable-cgroup,--disable-cgroup"
+PACKAGECONFIG[vserver] = "--enable-vserver,--disable-vserver"
+PACKAGECONFIG[taskstats] = "--enable-taskstats,--disable-taskstats"
+PACKAGECONFIG[unicode] = "--enable-unicode,--disable-unicode"
+PACKAGECONFIG[linux-affinity] = "--enable-linux-affinity,--disable-linux-affinity"
+PACKAGECONFIG[hwloc] = "--enable-hwloc,--disable-hwloc,hwloc"
+PACKAGECONFIG[setuid] = "--enable-setuid,--disable-setuid"
+PACKAGECONFIG[delayacct] = "--enable-delayacct,--disable-delayacct,libnl"
+
+do_configure_prepend () {
+    rm -rf ${S}/config.h
+}
diff --git a/meta-openembedded/meta-oe/recipes-support/hwdata/hwdata_git.bb b/meta-openembedded/meta-oe/recipes-support/hwdata/hwdata_git.bb
index 679673b..8e8dbf5 100644
--- a/meta-openembedded/meta-oe/recipes-support/hwdata/hwdata_git.bb
+++ b/meta-openembedded/meta-oe/recipes-support/hwdata/hwdata_git.bb
@@ -5,8 +5,8 @@
 LICENSE = "GPL-2.0+"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=1556547711e8246992b999edd9445a57"
 
-PV = "0.298+git${SRCPV}"
-SRCREV = "9030fbd6ab1538f4d77d3cf1e0b463a7ec25b5c4"
+PV = "0.316+git${SRCPV}"
+SRCREV = "803819aef862ded2ce0737cd3cf642c633b68c35"
 SRC_URI = "git://github.com/vcrhonek/${BPN}.git"
 
 S = "${WORKDIR}/git"
diff --git a/meta-openembedded/meta-oe/recipes-support/imagemagick/imagemagick_7.0.7.bb b/meta-openembedded/meta-oe/recipes-support/imagemagick/imagemagick_7.0.7.bb
index 669534e..46cc78e 100644
--- a/meta-openembedded/meta-oe/recipes-support/imagemagick/imagemagick_7.0.7.bb
+++ b/meta-openembedded/meta-oe/recipes-support/imagemagick/imagemagick_7.0.7.bb
@@ -3,7 +3,7 @@
 LICENSE = "ImageMagick"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=dad5a98f173fd3fa6958a1a58c6131c1"
 # FIXME: There are many more checked libraries. All should be added or explicitly disabled to get consistent results.
-DEPENDS = "lcms bzip2 jpeg libpng librsvg tiff zlib fftw freetype"
+DEPENDS = "lcms bzip2 jpeg libpng tiff zlib fftw freetype"
 
 BASE_PV := "${PV}"
 PV .= "_7"
@@ -25,6 +25,7 @@
 PACKAGECONFIG[lzma] = "--with-lzma,--without-lzma,xz"
 PACKAGECONFIG[openjpeg] = "--with-openjp2,--without-openjp2,openjpeg"
 PACKAGECONFIG[pango] = "--with-pango,--without-pango,pango cairo"
+PACKAGECONFIG[rsvg] = "--with-rsvg,--without-rsvg,librsvg"
 PACKAGECONFIG[webp] = "--with-webp,--without-webp,libwebp"
 PACKAGECONFIG[wmf] = "--with-wmf,--without-wmf,libwmf"
 PACKAGECONFIG[x11] = "--with-x,--without-x,virtual/libx11 libxext libxt"
diff --git a/meta-openembedded/meta-oe/recipes-support/lcov/lcov_1.11.bb b/meta-openembedded/meta-oe/recipes-support/lcov/lcov_1.11.bb
index 2f9ac33..56a018b 100644
--- a/meta-openembedded/meta-oe/recipes-support/lcov/lcov_1.11.bb
+++ b/meta-openembedded/meta-oe/recipes-support/lcov/lcov_1.11.bb
@@ -14,6 +14,31 @@
     perl-module-filehandle \
     perl-module-getopt-std \
     perl-module-digest-sha \
+    perl-module-constant \
+    perl-module-cwd \
+    perl-module-errno \
+    perl-module-file-basename \
+    perl-module-file-find \
+    perl-module-file-path \
+    perl-module-file-spec \
+    perl-module-file-spec-functions \
+    perl-module-file-spec-unix \
+    perl-module-file-temp \
+    perl-module-getopt-long \
+    perl-module-list-util \
+    perl-module-mro \
+    perl-module-overload \
+    perl-module-overloading \
+    perl-module-overload-numbers \
+    perl-module-parent \
+    perl-module-pod-usage \
+    perl-module-posix \
+    perl-module-re \
+    perl-module-safe \
+    perl-module-scalar-util \
+    perl-module-term-cap \
+    perl-module-text-parsewords \
+    perl-module-tie-hash \
 "
 
 SRC_URI = "http://downloads.sourceforge.net/ltp/${BP}.tar.gz"
diff --git a/meta-openembedded/meta-oe/recipes-support/libbytesize/files/0001-remove-python2-support.patch b/meta-openembedded/meta-oe/recipes-support/libbytesize/files/0001-remove-python2-support.patch
deleted file mode 100644
index b57e39f..0000000
--- a/meta-openembedded/meta-oe/recipes-support/libbytesize/files/0001-remove-python2-support.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 2ddc97b30792817d162f51ec3818376aefbf184e Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Wed, 3 May 2017 02:05:33 -0400
-Subject: [PATCH] remove python2 support
-
-We use python3 rather than python2 support
-
-Upstream-Status: Inappropriate [oe specific]
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- src/python/Makefile.am | 5 -----
- 1 file changed, 5 deletions(-)
-
-diff --git a/src/python/Makefile.am b/src/python/Makefile.am
-index 567d0d7..8d9f446 100644
---- a/src/python/Makefile.am
-+++ b/src/python/Makefile.am
-@@ -1,8 +1,3 @@
--pylibdir = $(shell python -c "import distutils.sysconfig; print(distutils.sysconfig.get_python_lib(1,0,prefix='${exec_prefix}'))")
--
--pybytesizedir     = $(pylibdir)/bytesize
--dist_pybytesize_DATA = bytesize.py __init__.py
--
- if WITH_PYTHON3
- py3libdir = $(shell python3 -c "import distutils.sysconfig; print(distutils.sysconfig.get_python_lib(1,0,prefix='${exec_prefix}'))")
- py3bytesizedir    = $(py3libdir)/bytesize
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/libbytesize/libbytesize_0.10.bb b/meta-openembedded/meta-oe/recipes-support/libbytesize/libbytesize_0.10.bb
deleted file mode 100644
index 6903021..0000000
--- a/meta-openembedded/meta-oe/recipes-support/libbytesize/libbytesize_0.10.bb
+++ /dev/null
@@ -1,34 +0,0 @@
-DESCRIPTION = "The goal of this project is to provide a tiny library that would \
-facilitate the common operations with sizes in bytes."
-HOMEPAGE = "https://github.com/rhinstaller/libbytesize"
-LICENSE = "LGPLv2+"
-SECTION = "devel/lib"
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=c07cb499d259452f324bb90c3067d85c"
-
-S = "${WORKDIR}/git"
-B = "${S}"
-
-SRCREV = "369127c0edbba7d1a4e2e02486375dd9d379524f"
-PV = "0.10+git${SRCPV}"
-SRC_URI = "git://github.com/rhinstaller/libbytesize;branch=master \
-           file://0001-remove-python2-support.patch \
-"
-
-inherit gettext autotools python3native
-
-DEPENDS += " \
-    libpcre \
-    gmp \
-    mpfr \
-"
-
-FILES_${PN} += "${PYTHON_SITEPACKAGES_DIR}/bytesize"
-
-PACKAGECONFIG ??= "python3"
-PACKAGECONFIG[python3] = "--with-python3, --without-python3,,python3"
-PACKAGECONFIG[doc] = "--with-gtk-doc, --without-gtk-doc, gtk-doc-native"
-
-EXTRA_OEMAKE = "py3libdir=${PYTHON_SITEPACKAGES_DIR}"
-
-
diff --git a/meta-openembedded/meta-oe/recipes-support/libbytesize/libbytesize_1.3.bb b/meta-openembedded/meta-oe/recipes-support/libbytesize/libbytesize_1.3.bb
new file mode 100644
index 0000000..caf84de
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/libbytesize/libbytesize_1.3.bb
@@ -0,0 +1,34 @@
+DESCRIPTION = "The goal of this project is to provide a tiny library that would \
+facilitate the common operations with sizes in bytes."
+HOMEPAGE = "https://github.com/rhinstaller/libbytesize"
+LICENSE = "LGPLv2+"
+SECTION = "devel/lib"
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=c07cb499d259452f324bb90c3067d85c"
+
+S = "${WORKDIR}/git"
+B = "${S}"
+
+SRCREV = "b0dcf6f457d700127b43c0e0a198253c266b78ae"
+PV = "1.3+git${SRCPV}"
+SRC_URI = "git://github.com/rhinstaller/libbytesize;branch=master \
+"
+
+inherit gettext autotools python3native
+
+DEPENDS += " \
+    libpcre \
+    gmp \
+    mpfr \
+"
+
+FILES_${PN} += "${PYTHON_SITEPACKAGES_DIR}/bytesize"
+
+PACKAGECONFIG ??= "python3"
+PACKAGECONFIG[python3] = "--with-python3, --without-python3,,python3"
+PACKAGECONFIG[python2] = "--with-python2, --without-python2,,python2"
+PACKAGECONFIG[doc] = "--with-gtk-doc, --without-gtk-doc, gtk-doc-native"
+
+EXTRA_OEMAKE = "py3libdir=${PYTHON_SITEPACKAGES_DIR}"
+
+
diff --git a/meta-openembedded/meta-oe/recipes-support/libeigen/libeigen_3.3.4.bb b/meta-openembedded/meta-oe/recipes-support/libeigen/libeigen_3.3.4.bb
deleted file mode 100644
index bc3b32e..0000000
--- a/meta-openembedded/meta-oe/recipes-support/libeigen/libeigen_3.3.4.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-DESCRIPTION = "Eigen is a C++ template library for linear algebra: matrices, vectors, numerical solvers, and related algorithms."
-AUTHOR = "Benoît Jacob and Gaël Guennebaud and others"
-HOMEPAGE = "http://eigen.tuxfamily.org/"
-LICENSE = "MPL-2.0"
-LIC_FILES_CHKSUM = "file://COPYING.MPL2;md5=815ca599c9df247a0c7f619bab123dad"
-
-SRC_URI = "http://bitbucket.org/eigen/eigen/get/${PV}.tar.bz2;downloadfilename=${BP}.tar.bz2"
-SRC_URI[md5sum] = "a7aab9f758249b86c93221ad417fbe18"
-SRC_URI[sha256sum] = "dd254beb0bafc695d0f62ae1a222ff85b52dbaa3a16f76e781dce22d0d20a4a6"
-
-S = "${WORKDIR}/eigen-eigen-5a0156e40feb"
-
-inherit cmake
-
-FILES_${PN} = "${includedir} ${libdir}"
-FILES_${PN}-dev = "${datadir}/eigen3/cmake ${datadir}/cmake/Modules ${datadir}/pkgconfig"
-
-# ${PN} is empty so we need to tweak -dev and -dbg package dependencies
-RDEPENDS_${PN}-dev = ""
-RRECOMMENDS_${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})"
diff --git a/meta-openembedded/meta-oe/recipes-support/libeigen/libeigen_3.3.5.bb b/meta-openembedded/meta-oe/recipes-support/libeigen/libeigen_3.3.5.bb
new file mode 100644
index 0000000..7078e50
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/libeigen/libeigen_3.3.5.bb
@@ -0,0 +1,20 @@
+DESCRIPTION = "Eigen is a C++ template library for linear algebra: matrices, vectors, numerical solvers, and related algorithms."
+AUTHOR = "Benoît Jacob and Gaël Guennebaud and others"
+HOMEPAGE = "http://eigen.tuxfamily.org/"
+LICENSE = "MPL-2.0"
+LIC_FILES_CHKSUM = "file://COPYING.MPL2;md5=815ca599c9df247a0c7f619bab123dad"
+
+SRC_URI = "http://bitbucket.org/eigen/eigen/get/${PV}.tar.bz2;downloadfilename=${BP}.tar.bz2"
+SRC_URI[md5sum] = "e83549a79d1b721da0f8899ab34edf95"
+SRC_URI[sha256sum] = "7352bff3ea299e4c7d7fbe31c504f8eb9149d7e685dec5a12fbaa26379f603e2"
+
+S = "${WORKDIR}/eigen-eigen-b3f3d4950030"
+
+inherit cmake
+
+FILES_${PN} = "${libdir}"
+FILES_${PN}-dev = "${includedir} ${datadir}/eigen3/cmake ${datadir}/cmake/Modules ${datadir}/pkgconfig"
+
+# ${PN} is empty so we need to tweak -dev and -dbg package dependencies
+RDEPENDS_${PN}-dev = ""
+RRECOMMENDS_${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})"
diff --git a/meta-openembedded/meta-oe/recipes-support/libestr/libestr_0.1.10.bb b/meta-openembedded/meta-oe/recipes-support/libestr/libestr_0.1.10.bb
deleted file mode 100644
index 9bff4f3..0000000
--- a/meta-openembedded/meta-oe/recipes-support/libestr/libestr_0.1.10.bb
+++ /dev/null
@@ -1,11 +0,0 @@
-SUMMARY = "some essentials for string handling (and a bit more)"
-HOMEPAGE = "http://libestr.adiscon.com/"
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=9d6c993486c18262afba4ca5bcb894d0"
-
-SRC_URI = "http://libestr.adiscon.com/files/download/${BP}.tar.gz"
-
-SRC_URI[md5sum] = "f4c9165a23587e77f7efe65d676d5e8e"
-SRC_URI[sha256sum] = "bd655e126e750edd18544b88eb1568d200a424a0c23f665eb14bbece07ac703c"
-
-inherit autotools
diff --git a/meta-openembedded/meta-oe/recipes-support/libestr/libestr_0.1.11.bb b/meta-openembedded/meta-oe/recipes-support/libestr/libestr_0.1.11.bb
new file mode 100644
index 0000000..ff61dd8
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/libestr/libestr_0.1.11.bb
@@ -0,0 +1,13 @@
+SUMMARY = "some essentials for string handling (and a bit more)"
+HOMEPAGE = "http://libestr.adiscon.com/"
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=9d6c993486c18262afba4ca5bcb894d0"
+
+SRC_URI = "http://libestr.adiscon.com/files/download/${BP}.tar.gz"
+
+SRC_URI[md5sum] = "1f25a2332750d4bfacfb314235fedff0"
+SRC_URI[sha256sum] = "46632b2785ff4a231dcf241eeb0dcb5fc0c7d4da8ee49cf5687722cdbe8b2024"
+
+UPSTREAM_CHECK_URI = "http://libestr.adiscon.com/download/"
+
+inherit autotools
diff --git a/meta-openembedded/meta-oe/recipes-support/libftdi/libftdi_1.4.bb b/meta-openembedded/meta-oe/recipes-support/libftdi/libftdi_1.4.bb
index 6bea165..4fc6eb0 100644
--- a/meta-openembedded/meta-oe/recipes-support/libftdi/libftdi_1.4.bb
+++ b/meta-openembedded/meta-oe/recipes-support/libftdi/libftdi_1.4.bb
@@ -3,7 +3,6 @@
 including the popular bitbang mode."
 HOMEPAGE = "http://www.intra2net.com/en/developer/libftdi/"
 SECTION = "libs"
-
 LICENSE = "LGPLv2.1 & GPLv2"
 LIC_FILES_CHKSUM= "\
     file://COPYING.GPL;md5=751419260aa954499f7abaabaa882bbe \
@@ -13,19 +12,16 @@
 DEPENDS = "libusb1"
 
 SRC_URI = "http://www.intra2net.com/en/developer/${BPN}/download/${BPN}1-${PV}.tar.bz2"
-
 SRC_URI[md5sum] = "0c09fb2bb19a57c839fa6845c6c780a2"
 SRC_URI[sha256sum] = "ec36fb49080f834690c24008328a5ef42d3cf584ef4060f3a35aa4681cb31b74"
 
 S = "${WORKDIR}/${BPN}1-${PV}"
 
+inherit cmake binconfig pkgconfig
+
 PACKAGECONFIG ??= ""
 PACKAGECONFIG[cpp-wrapper] = "-DFTDI_BUILD_CPP=on -DFTDIPP=on,-DFTDI_BUILD_CPP=off -DFTDIPP=off,boost"
 
-inherit cmake binconfig pkgconfig
-
 EXTRA_OECMAKE = "-DLIB_SUFFIX=${@d.getVar('baselib').replace('lib', '')}"
 
-FILES_${PN}-dev += "${libdir}/cmake"
-
-BBCLASSEXTEND = "native"
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-support/libgit2/libgit2_0.24.3.bb b/meta-openembedded/meta-oe/recipes-support/libgit2/libgit2_0.24.3.bb
deleted file mode 100644
index 8f580f9..0000000
--- a/meta-openembedded/meta-oe/recipes-support/libgit2/libgit2_0.24.3.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-SUMMARY = "the Git linkable library"
-HOMEPAGE = "http://libgit2.github.com/"
-LICENSE = "GPL-2.0-with-GCC-exception"
-LIC_FILES_CHKSUM = "file://COPYING;md5=34197a479f637beb9e09e56893f48bc2"
-
-DEPENDS = "curl openssl zlib libssh2"
-
-SRC_URI = "git://github.com/libgit2/libgit2.git;branch=maint/v0.24"
-SRCREV = "4cf1ec7cff28da8838a2f0a9fb330e312ea3f963"
-
-S = "${WORKDIR}/git"
-
-inherit cmake
-
-EXTRA_OECMAKE = "\
-        -DTHREADSAFE=ON \
-        -DBUILD_CLAR=OFF \
-        -DSHA1_TYPE="builtin" \
-        -DCMAKE_BUILD_TYPE=RelWithDebInfo \
-        -DBUILD_EXAMPLES=OFF \
-"
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-support/libgit2/libgit2_0.27.4.bb b/meta-openembedded/meta-oe/recipes-support/libgit2/libgit2_0.27.4.bb
new file mode 100644
index 0000000..e7f7688
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/libgit2/libgit2_0.27.4.bb
@@ -0,0 +1,24 @@
+SUMMARY = "the Git linkable library"
+HOMEPAGE = "http://libgit2.github.com/"
+LICENSE = "GPL-2.0-with-GCC-exception & MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=3f2cd5d3cccd71d62066ba619614592b"
+
+DEPENDS = "curl openssl zlib libssh2 libgcrypt"
+
+SRC_URI = "git://github.com/libgit2/libgit2.git;branch=maint/v0.27"
+#v0.27.5
+SRCREV = "8e0b172981a046d19f1d9efa5acd6186bccbd3ce"
+
+S = "${WORKDIR}/git"
+
+inherit cmake
+
+EXTRA_OECMAKE = "\
+        -DTHREADSAFE=ON \
+        -DBUILD_CLAR=OFF \
+        -DSHA1_TYPE="builtin" \
+        -DCMAKE_BUILD_TYPE=RelWithDebInfo \
+        -DBUILD_EXAMPLES=OFF \
+"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-support/libgpiod/libgpiod_1.0.1.bb b/meta-openembedded/meta-oe/recipes-support/libgpiod/libgpiod_1.0.1.bb
deleted file mode 100644
index 51499fd..0000000
--- a/meta-openembedded/meta-oe/recipes-support/libgpiod/libgpiod_1.0.1.bb
+++ /dev/null
@@ -1,4 +0,0 @@
-require libgpiod.inc
-
-SRC_URI[md5sum] = "2ca0c3eb17d69e367b6f6a109ca86e41"
-SRC_URI[sha256sum] = "972924195367f5fb045c023d65340c4b7dfc8764499516be446553865208dedc"
diff --git a/meta-openembedded/meta-oe/recipes-support/libgpiod/libgpiod_1.2.bb b/meta-openembedded/meta-oe/recipes-support/libgpiod/libgpiod_1.2.bb
new file mode 100644
index 0000000..30289b9
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/libgpiod/libgpiod_1.2.bb
@@ -0,0 +1,16 @@
+require libgpiod.inc
+
+DEPENDS += "autoconf-archive-native"
+
+SRC_URI[md5sum] = "34a9972f2f4e9c32fa940301301b007d"
+SRC_URI[sha256sum] = "b6b9079c933f7c8524815437937dda6b795a16141bca202a9eec70ba5844b5ba"
+
+PACKAGECONFIG[cxx] = "--enable-bindings-cxx,--disable-bindings-cxx"
+
+PACKAGECONFIG[python3] = "--enable-bindings-python,--disable-bindings-python,python3,python3-core"
+inherit ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3native', '', d)}
+
+PACKAGES =+ "${PN}-python"
+FILES_${PN}-python = "${PYTHON_SITEPACKAGES_DIR}"
+RRECOMMENDS_PYTHON = "${@bb.utils.contains('PACKAGECONFIG', 'python3', '${PN}-python', '',d)}"
+RRECOMMENDS_${PN} += "${RRECOMMENDS_PYTHON}"
diff --git a/meta-openembedded/meta-oe/recipes-support/libiio/libiio_git.bb b/meta-openembedded/meta-oe/recipes-support/libiio/libiio_git.bb
index ba380ed..fa6f4c2 100644
--- a/meta-openembedded/meta-oe/recipes-support/libiio/libiio_git.bb
+++ b/meta-openembedded/meta-oe/recipes-support/libiio/libiio_git.bb
@@ -24,10 +24,11 @@
     ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '-DWITH_SYSTEMD=ON -DSYSTEMD_UNIT_INSTALL_DIR=${systemd_system_unitdir}', '', d)} \
 "
 
-PACKAGECONFIG ??= "USB_BACKEND NETWORK_BACKEND"
+PACKAGECONFIG ??= "USB_BACKEND NETWORK_BACKEND PYTHON_BINDINGS"
 
 PACKAGECONFIG[USB_BACKEND] = "-DWITH_USB_BACKEND=ON,-DWITH_USB_BACKEND=OFF,libusb1,libxml2"
 PACKAGECONFIG[NETWORK_BACKEND] = "-DWITH_NETWORK_BACKEND=ON,-DWITH_NETWORK_BACKEND=OFF,libxml2"
+PACKAGECONFIG[PYTHON_BINDINGS] = ",,python"
 
 PACKAGES =+ "${PN}-iiod ${PN}-tests ${PN}-python"
 
diff --git a/meta-openembedded/meta-oe/recipes-support/libmicrohttpd/libmicrohttpd_0.9.55.bb b/meta-openembedded/meta-oe/recipes-support/libmicrohttpd/libmicrohttpd_0.9.55.bb
deleted file mode 100644
index 0930a27..0000000
--- a/meta-openembedded/meta-oe/recipes-support/libmicrohttpd/libmicrohttpd_0.9.55.bb
+++ /dev/null
@@ -1,27 +0,0 @@
-DESCRIPTION = "A small C library that is supposed to make it easy to run an HTTP server as part of another application"
-HOMEPAGE = "http://www.gnu.org/software/libmicrohttpd/"
-LICENSE = "LGPL-2.1+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=9331186f4f80db7da0e724bdd6554ee5"
-SECTION = "net"
-DEPENDS = "libgcrypt gnutls file"
-
-SRC_URI = "http://ftp.gnu.org/gnu/libmicrohttpd/${BPN}-${PV}.tar.gz"
-SRC_URI[md5sum] = "1c20f84a8b9cf692dd50b558b3571a3a"
-SRC_URI[sha256sum] = "0c1cab8dc9f2588bd3076a28f77a7f8de9560cbf2d80e53f9a8696ada80ed0f8"
-
-inherit autotools lib_package pkgconfig gettext
-
-CFLAGS += "-pthread -D_REENTRANT"
-
-EXTRA_OECONF += "--disable-static --with-gnutls=${STAGING_LIBDIR}/../"
-
-PACKAGECONFIG ?= "curl"
-PACKAGECONFIG_append_class-target = "\
-        ${@bb.utils.filter('DISTRO_FEATURES', 'largefile', d)} \
-"
-PACKAGECONFIG[largefile] = "--enable-largefile,--disable-largefile,,"
-PACKAGECONFIG[curl] = "--enable-curl,--disable-curl,curl,"
-
-do_compile_append() {
-    sed -i s:-L${STAGING_LIBDIR}::g libmicrohttpd.pc
-}
diff --git a/meta-openembedded/meta-oe/recipes-support/libmicrohttpd/libmicrohttpd_0.9.59.bb b/meta-openembedded/meta-oe/recipes-support/libmicrohttpd/libmicrohttpd_0.9.59.bb
new file mode 100644
index 0000000..b44c66a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/libmicrohttpd/libmicrohttpd_0.9.59.bb
@@ -0,0 +1,28 @@
+DESCRIPTION = "A small C library that is supposed to make it easy to run an HTTP server as part of another application"
+HOMEPAGE = "http://www.gnu.org/software/libmicrohttpd/"
+LICENSE = "LGPL-2.1+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=9331186f4f80db7da0e724bdd6554ee5"
+SECTION = "net"
+DEPENDS = "file"
+
+SRC_URI = "http://ftp.gnu.org/gnu/libmicrohttpd/${BPN}-${PV}.tar.gz"
+SRC_URI[md5sum] = "8ab5123535549195aff19e91b4e49f48"
+SRC_URI[sha256sum] = "9b9ccd7d0b11b0e179f1f58dc2caa3e0c62c8609e1e1dc7dcaadf941b67d923c"
+
+inherit autotools lib_package pkgconfig gettext
+
+CFLAGS += "-pthread -D_REENTRANT"
+
+EXTRA_OECONF += "--disable-static --with-gnutls=${STAGING_LIBDIR}/../"
+
+PACKAGECONFIG ?= "curl https"
+PACKAGECONFIG_append_class-target = "\
+        ${@bb.utils.filter('DISTRO_FEATURES', 'largefile', d)} \
+"
+PACKAGECONFIG[largefile] = "--enable-largefile,--disable-largefile,,"
+PACKAGECONFIG[curl] = "--enable-curl,--disable-curl,curl,"
+PACKAGECONFIG[https] = "--enable-https,--disable-https,libgcrypt gnutls,"
+
+do_compile_append() {
+    sed -i s:-L${STAGING_LIBDIR}::g libmicrohttpd.pc
+}
diff --git a/meta-openembedded/meta-oe/recipes-support/libmxml/libmxml_git.bb b/meta-openembedded/meta-oe/recipes-support/libmxml/libmxml_git.bb
new file mode 100644
index 0000000..542fe81
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/libmxml/libmxml_git.bb
@@ -0,0 +1,41 @@
+DESCRIPTION = "Tiny XML Library"
+LICENSE = "Mini-XML-License"
+LIC_FILES_CHKSUM = "file://COPYING;md5=a6ba38606d63bb042c5d8cfee182e120"
+HOMEPAGE = "https://www.msweet.org/mxml/"
+BUGTRACKER = "https://github.com/michaelrsweet/mxml/issues"
+
+SRC_URI = "git://github.com/michaelrsweet/mxml.git"
+SRCREV = "ba3cca82e15a88a9cc6afb60f059288a99afc703"
+S = "${WORKDIR}/git"
+PV = "2.12+git${SRCPV}"
+
+CONFIGUREOPTS = " --prefix=${prefix} \
+                  --bindir=${bindir} \
+                  --sbindir=${sbindir} \
+                  --libexecdir=${libexecdir} \
+                  --datadir=${datadir} \
+                  --sysconfdir=${sysconfdir} \
+                  --sharedstatedir=${sharedstatedir} \
+                  --localstatedir=${localstatedir} \
+                  --libdir=${libdir} \
+                  --includedir=${includedir} \
+                  --oldincludedir=${oldincludedir} \
+                  --infodir=${infodir} \
+                  --mandir=${mandir} \
+                  --host=${TARGET_SYS} \
+                  --build=${BUILD_SYS} \
+                  ${PACKAGECONFIG_CONFARGS} \
+                "
+
+do_configure() {
+    ./configure ${CONFIGUREOPTS} --enable-shared
+}
+
+do_install () {
+    export DSTROOT=${D}
+    oe_runmake install
+}
+
+PACKAGES += " ${PN}-bin "
+FILES_${PN} = "${libdir}/*"
+FILES_${PN}-bin = "${bindir}/*"
diff --git a/meta-openembedded/meta-oe/recipes-support/liboauth/liboauth/0001-Support-OpenSSL-1.1.0.patch b/meta-openembedded/meta-oe/recipes-support/liboauth/liboauth/0001-Support-OpenSSL-1.1.0.patch
new file mode 100644
index 0000000..8691eae
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/liboauth/liboauth/0001-Support-OpenSSL-1.1.0.patch
@@ -0,0 +1,151 @@
+From c14d9bf71753a38df57cc6538b22ed389d2c2cb1 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 4 Sep 2018 17:18:51 -0700
+Subject: [PATCH] Support OpenSSL 1.1.0
+
+Taken from https://github.com/x42/liboauth/issues/9
+
+Upstream-Status: Submitted[https://github.com/x42/liboauth/issues/9]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/hash.c | 65 ++++++++++++++++++++++++++++++++++++------------------
+ 1 file changed, 44 insertions(+), 21 deletions(-)
+
+diff --git a/src/hash.c b/src/hash.c
+index 17ff5c8..e128826 100644
+--- a/src/hash.c
++++ b/src/hash.c
+@@ -362,6 +362,11 @@ looser:
+ #include "oauth.h" // base64 encode fn's.
+ #include <openssl/hmac.h>
+ 
++#if OPENSSL_VERSION_NUMBER < 0x10100000
++#define EVP_MD_CTX_new EVP_MD_CTX_create
++#define EVP_MD_CTX_free EVP_MD_CTX_destroy
++#endif
++
+ char *oauth_sign_hmac_sha1 (const char *m, const char *k) {
+   return(oauth_sign_hmac_sha1_raw (m, strlen(m), k, strlen(k)));
+ }
+@@ -386,7 +391,7 @@ char *oauth_sign_rsa_sha1 (const char *m, const char *k) {
+   unsigned char *sig = NULL;
+   unsigned char *passphrase = NULL;
+   unsigned int len=0;
+-  EVP_MD_CTX md_ctx;
++  EVP_MD_CTX *md_ctx;
+ 
+   EVP_PKEY *pkey;
+   BIO *in;
+@@ -399,24 +404,31 @@ char *oauth_sign_rsa_sha1 (const char *m, const char *k) {
+     return xstrdup("liboauth/OpenSSL: can not read private key");
+   }
+ 
++	md_ctx = EVP_MD_CTX_new();
++	if (md_ctx == NULL) {
++		return xstrdup("liboauth/OpenSSL: failed to allocate EVP_MD_CTX");
++	}
++
+   len = EVP_PKEY_size(pkey);
+   sig = (unsigned char*)xmalloc((len+1)*sizeof(char));
+ 
+-  EVP_SignInit(&md_ctx, EVP_sha1());
+-  EVP_SignUpdate(&md_ctx, m, strlen(m));
+-  if (EVP_SignFinal (&md_ctx, sig, &len, pkey)) {
++	EVP_SignInit(md_ctx, EVP_sha1());
++	EVP_SignUpdate(md_ctx, m, strlen(m));
++	if (EVP_SignFinal (md_ctx, sig, &len, pkey)) {
+     char *tmp;
+     sig[len] = '\0';
+     tmp = oauth_encode_base64(len,sig);
+     OPENSSL_free(sig);
+     EVP_PKEY_free(pkey);
++    EVP_MD_CTX_free(md_ctx);
+     return tmp;
+   }
++  EVP_MD_CTX_free(md_ctx);
+   return xstrdup("liboauth/OpenSSL: rsa-sha1 signing failed");
+ }
+ 
+ int oauth_verify_rsa_sha1 (const char *m, const char *c, const char *s) {
+-  EVP_MD_CTX md_ctx;
++  EVP_MD_CTX *md_ctx;
+   EVP_PKEY *pkey;
+   BIO *in;
+   X509 *cert = NULL;
+@@ -437,13 +449,18 @@ int oauth_verify_rsa_sha1 (const char *m, const char *c, const char *s) {
+     return -2;
+   }
+ 
++	md_ctx = EVP_MD_CTX_new();
++	if (md_ctx == NULL) {
++		return -2;
++	}
++
+   b64d= (unsigned char*) xmalloc(sizeof(char)*strlen(s));
+   slen = oauth_decode_base64(b64d, s);
+ 
+-  EVP_VerifyInit(&md_ctx, EVP_sha1());
+-  EVP_VerifyUpdate(&md_ctx, m, strlen(m));
+-  err = EVP_VerifyFinal(&md_ctx, b64d, slen, pkey);
+-  EVP_MD_CTX_cleanup(&md_ctx);
++	EVP_VerifyInit(md_ctx, EVP_sha1());
++	EVP_VerifyUpdate(md_ctx, m, strlen(m));
++	err = EVP_VerifyFinal(md_ctx, b64d, slen, pkey);
++	EVP_MD_CTX_free(md_ctx);
+   EVP_PKEY_free(pkey);
+   xfree(b64d);
+   return (err);
+@@ -455,35 +472,41 @@ int oauth_verify_rsa_sha1 (const char *m, const char *c, const char *s) {
+  */
+ char *oauth_body_hash_file(char *filename) {
+   unsigned char fb[BUFSIZ];
+-  EVP_MD_CTX ctx;
++  EVP_MD_CTX *ctx;
+   size_t len=0;
+   unsigned char *md;
+   FILE *F= fopen(filename, "r");
+   if (!F) return NULL;
+ 
+-  EVP_MD_CTX_init(&ctx);
+-  EVP_DigestInit(&ctx,EVP_sha1());
++	ctx = EVP_MD_CTX_new();
++	if (ctx == NULL) {
++		return xstrdup("liboauth/OpenSSL: failed to allocate EVP_MD_CTX");
++	}
++	EVP_DigestInit(ctx,EVP_sha1());
+   while (!feof(F) && (len=fread(fb,sizeof(char),BUFSIZ, F))>0) {
+-    EVP_DigestUpdate(&ctx, fb, len);
++    EVP_DigestUpdate(ctx, fb, len);
+   }
+   fclose(F);
+   len=0;
+   md=(unsigned char*) xcalloc(EVP_MD_size(EVP_sha1()),sizeof(unsigned char));
+-  EVP_DigestFinal(&ctx, md,(unsigned int*) &len);
+-  EVP_MD_CTX_cleanup(&ctx);
++	EVP_DigestFinal(ctx, md,(unsigned int*) &len);
++	EVP_MD_CTX_free(ctx);
+   return oauth_body_hash_encode(len, md);
+ }
+ 
+ char *oauth_body_hash_data(size_t length, const char *data) {
+-  EVP_MD_CTX ctx;
++  EVP_MD_CTX *ctx;
+   size_t len=0;
+   unsigned char *md;
+   md=(unsigned char*) xcalloc(EVP_MD_size(EVP_sha1()),sizeof(unsigned char));
+-  EVP_MD_CTX_init(&ctx);
+-  EVP_DigestInit(&ctx,EVP_sha1());
+-  EVP_DigestUpdate(&ctx, data, length);
+-  EVP_DigestFinal(&ctx, md,(unsigned int*) &len);
+-  EVP_MD_CTX_cleanup(&ctx);
++	ctx = EVP_MD_CTX_new();
++	if (ctx == NULL) {
++		return xstrdup("liboauth/OpenSSL: failed to allocate EVP_MD_CTX");
++	}
++	EVP_DigestInit(ctx,EVP_sha1());
++	EVP_DigestUpdate(ctx, data, length);
++	EVP_DigestFinal(ctx, md,(unsigned int*) &len);
++	EVP_MD_CTX_free(ctx);
+   return oauth_body_hash_encode(len, md);
+ }
+ 
diff --git a/meta-openembedded/meta-oe/recipes-support/liboauth/liboauth_1.0.3.bb b/meta-openembedded/meta-oe/recipes-support/liboauth/liboauth_1.0.3.bb
index 3311da5..498764a 100644
--- a/meta-openembedded/meta-oe/recipes-support/liboauth/liboauth_1.0.3.bb
+++ b/meta-openembedded/meta-oe/recipes-support/liboauth/liboauth_1.0.3.bb
@@ -9,7 +9,9 @@
 SECTION = "libs"
 DEPENDS = "curl openssl"
 
-SRC_URI = "${SOURCEFORGE_MIRROR}/project/${BPN}/${BP}.tar.gz"
+SRC_URI = "${SOURCEFORGE_MIRROR}/project/${BPN}/${BP}.tar.gz \
+           file://0001-Support-OpenSSL-1.1.0.patch \
+           "
 SRC_URI[md5sum] = "689b46c2b3ab1a39735ac33f714c4f7f"
 SRC_URI[sha256sum] = "0df60157b052f0e774ade8a8bac59d6e8d4b464058cc55f9208d72e41156811f"
 
diff --git a/meta-openembedded/meta-oe/recipes-support/libp11/libp11_0.4.7.bb b/meta-openembedded/meta-oe/recipes-support/libp11/libp11_0.4.7.bb
index 949c337..87d99c1 100644
--- a/meta-openembedded/meta-oe/recipes-support/libp11/libp11_0.4.7.bb
+++ b/meta-openembedded/meta-oe/recipes-support/libp11/libp11_0.4.7.bb
@@ -22,5 +22,5 @@
     rm -rf ${D}${docdir}/${BPN}
 }
 
-FILES_${PN} += "${libdir}/engines/pkcs11.so"
-FILES_${PN}-dev += "${libdir}/engines/libpkcs11${SOLIBSDEV}"
+FILES_${PN} += "${libdir}/engines*/pkcs11.so"
+FILES_${PN}-dev += "${libdir}/engines*/libpkcs11${SOLIBSDEV}"
diff --git a/meta-openembedded/meta-oe/recipes-support/libssh/libssh_0.7.3.bb b/meta-openembedded/meta-oe/recipes-support/libssh/libssh_0.7.3.bb
deleted file mode 100644
index 79e7dc5..0000000
--- a/meta-openembedded/meta-oe/recipes-support/libssh/libssh_0.7.3.bb
+++ /dev/null
@@ -1,34 +0,0 @@
-SUMMARY = "Multiplatform C library implementing the SSHv2 and SSHv1 protocol"
-HOMEPAGE = "http://www.libssh.org"
-SECTION = "libs"
-
-DEPENDS = "zlib openssl libgcrypt"
-
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=388a4fb1dea8ceae0be78ba9b01fc139"
-
-SRC_URI = "git://git.libssh.org/projects/libssh.git;branch=v0-7"
-SRCREV = "cdf7690e038230623cbbf6b024ece62f41efa98d"
-S = "${WORKDIR}/git"
-
-EXTRA_OECMAKE = " \
-    -DWITH_GCRYPT=1 \
-    -DWITH_PCAP=1 \
-    -DWITH_SFTP=1 \
-    -DWITH_ZLIB=1 \
-    -DLIB_SUFFIX=${@d.getVar('baselib').replace('lib', '')} \
-    "
-
-PACKAGECONFIG ??=""
-PACKAGECONFIG[gssapi] = "-DWITH_GSSAPI=1, -DWITH_GSSAPI=0, krb5, "
-
-inherit cmake
-
-do_configure_prepend () {
-    # Disable building of examples
-    sed -i -e '/add_subdirectory(examples)/s/^/#DONOTWANT/' ${S}/CMakeLists.txt \
-        || bbfatal "Failed to disable examples"
-}
-
-FILES_${PN}-dev += "${libdir}/cmake"
-TOOLCHAIN = "gcc"
diff --git a/meta-openembedded/meta-oe/recipes-support/libssh/libssh_0.8.4.bb b/meta-openembedded/meta-oe/recipes-support/libssh/libssh_0.8.4.bb
new file mode 100644
index 0000000..6040ec9
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/libssh/libssh_0.8.4.bb
@@ -0,0 +1,35 @@
+SUMMARY = "Multiplatform C library implementing the SSHv2 and SSHv1 protocol"
+HOMEPAGE = "http://www.libssh.org"
+SECTION = "libs"
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=388a4fb1dea8ceae0be78ba9b01fc139"
+
+DEPENDS = "zlib openssl libgcrypt"
+
+SRC_URI = "git://git.libssh.org/projects/libssh.git;branch=stable-0.8"
+SRCREV = "789df0b7d0c7abd6b85db9fc5247e146e3d4ddba"
+
+S = "${WORKDIR}/git"
+
+inherit cmake
+
+PACKAGECONFIG ??=""
+PACKAGECONFIG[gssapi] = "-DWITH_GSSAPI=1, -DWITH_GSSAPI=0, krb5, "
+
+ARM_INSTRUCTION_SET_armv5 = "arm"
+
+EXTRA_OECMAKE = " \
+    -DWITH_GCRYPT=1 \
+    -DWITH_PCAP=1 \
+    -DWITH_SFTP=1 \
+    -DWITH_ZLIB=1 \
+    -DLIB_SUFFIX=${@d.getVar('baselib').replace('lib', '')} \
+    "
+
+do_configure_prepend () {
+    # Disable building of examples
+    sed -i -e '/add_subdirectory(examples)/s/^/#DONOTWANT/' ${S}/CMakeLists.txt \
+        || bbfatal "Failed to disable examples"
+}
+
+TOOLCHAIN = "gcc"
diff --git a/meta-openembedded/meta-oe/recipes-support/libtinyxml2/libtinyxml2_7.0.1.bb b/meta-openembedded/meta-oe/recipes-support/libtinyxml2/libtinyxml2_7.0.1.bb
index 74780e1..e4bb3f3 100644
--- a/meta-openembedded/meta-oe/recipes-support/libtinyxml2/libtinyxml2_7.0.1.bb
+++ b/meta-openembedded/meta-oe/recipes-support/libtinyxml2/libtinyxml2_7.0.1.bb
@@ -12,6 +12,4 @@
 
 inherit cmake
 
-FILES_${PN}-dev += "${libdir}/cmake/"
-
 BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-support/libusb/libusb-compat/0001-usb.h-Include-sys-types.h.patch b/meta-openembedded/meta-oe/recipes-support/libusb/libusb-compat/0001-usb.h-Include-sys-types.h.patch
similarity index 100%
rename from poky/meta/recipes-support/libusb/libusb-compat/0001-usb.h-Include-sys-types.h.patch
rename to meta-openembedded/meta-oe/recipes-support/libusb/libusb-compat/0001-usb.h-Include-sys-types.h.patch
diff --git a/poky/meta/recipes-support/libusb/libusb-compat_0.1.5.bb b/meta-openembedded/meta-oe/recipes-support/libusb/libusb-compat_0.1.5.bb
similarity index 100%
rename from poky/meta/recipes-support/libusb/libusb-compat_0.1.5.bb
rename to meta-openembedded/meta-oe/recipes-support/libusb/libusb-compat_0.1.5.bb
diff --git a/meta-openembedded/meta-oe/recipes-support/links/files/ac-prog-cxx.patch b/meta-openembedded/meta-oe/recipes-support/links/files/ac-prog-cxx.patch
index 41c3826..2dc57a5 100644
--- a/meta-openembedded/meta-oe/recipes-support/links/files/ac-prog-cxx.patch
+++ b/meta-openembedded/meta-oe/recipes-support/links/files/ac-prog-cxx.patch
@@ -1,11 +1,21 @@
---- links-2.1pre20/configure.in.orig	2005-12-21 15:23:49.000000000 +0000
-+++ links-2.1pre20/configure.in	2005-12-21 15:23:59.000000000 +0000
-@@ -18,7 +18,7 @@
+From c00668541f68c17a5e453a4dcc2a86022b20af87 Mon Sep 17 00:00:00 2001
+From: Martin Jansa <Martin.Jansa@gmail.com>
+Date: Mon, 30 Jul 2012 23:52:49 +0200
+
+---
+ configure.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.in b/configure.in
+index 7c15b6b..9896631 100644
+--- a/configure.in
++++ b/configure.in
+@@ -23,7 +23,7 @@ AM_CONFIG_HEADER(config.h)
  dnl Checks for programs.
  AC_PROG_CC
  
--#AC_PROG_CXX
+-dnl AC_PROG_CXX
 +AC_PROG_CXX
- #AC_PROG_AWK
- #AM_PROG_LEX
- #AC_PROG_YACC
+ dnl AC_PROG_AWK
+ dnl AM_PROG_LEX
+ dnl AC_PROG_YACC
diff --git a/meta-openembedded/meta-oe/recipes-support/links/links-x11_2.16.bb b/meta-openembedded/meta-oe/recipes-support/links/links-x11_2.16.bb
new file mode 100644
index 0000000..f55a6fc
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/links/links-x11_2.16.bb
@@ -0,0 +1,53 @@
+# FIXME: the LIC_FILES_CHKSUM values have been updated by 'devtool upgrade'.
+# The following is the difference between the old and the new license text.
+# Please update the LICENSE value if needed, and summarize the changes in
+# the commit message via 'License-Update:' tag.
+# (example: 'License-Update: copyright years updated.')
+#
+# The changes:
+#
+# --- COPYING
+# +++ COPYING
+# @@ -293,7 +293,7 @@
+#      <one line to give the program's name and a brief idea of what it does.>
+#      Copyright (C) <year>  <name of author>
+#  
+# -    on, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USAThis program is free software; you can redistribute it and/or modify
+# +    This program is free software; you can redistribute it and/or modify
+#      it under the terms of the GNU General Public License as published by
+#      the Free Software Foundation; either version 2 of the License, or
+#      (at your option) any later version.
+# 
+#
+
+require links.inc
+
+DEPENDS += "virtual/libx11"
+RCONFLICTS_${PN} = "links"
+
+inherit distro_features_check
+# depends on virtual/libx11
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI += " file://links2.desktop \
+             http://www.xora.org.uk/oe/links2.png;name=icon"
+
+S = "${WORKDIR}/links-${PV}"
+
+EXTRA_OECONF = "--enable-graphics \
+                --with-ssl=${STAGING_LIBDIR}/.. --with-libjpeg \
+                --without-libtiff --without-svgalib --without-fb \
+                --without-directfb --without-pmshell --without-atheos \
+                --with-x --without-gpm"
+
+do_install_append() {
+    install -d ${D}/${datadir}/applications
+    install -m 0644 ${WORKDIR}/links2.desktop ${D}/${datadir}/applications
+    install -d ${D}/${datadir}/pixmaps
+    install -m 0644 ${WORKDIR}/links2.png ${D}/${datadir}/pixmaps
+}
+
+SRC_URI[md5sum] = "645fb0c0294e4c3268f94d307d394ffb"
+SRC_URI[sha256sum] = "82f03038d5e050a65681b9888762af41c40fd42dec7e59a8d630bfb0ee134a3f"
+SRC_URI[icon.md5sum] = "477e8787927c634614bac01b44355a33"
+SRC_URI[icon.sha256sum] = "eddcd8b8c8698aa621d1a453943892d77b72ed492e0d14e0dbac5c6a57e52f47"
diff --git a/meta-openembedded/meta-oe/recipes-support/links/links-x11_2.7.bb b/meta-openembedded/meta-oe/recipes-support/links/links-x11_2.7.bb
deleted file mode 100644
index 2ae11ac..0000000
--- a/meta-openembedded/meta-oe/recipes-support/links/links-x11_2.7.bb
+++ /dev/null
@@ -1,31 +0,0 @@
-require links.inc
-
-DEPENDS += "virtual/libx11"
-RCONFLICTS_${PN} = "links"
-
-inherit distro_features_check
-# depends on virtual/libx11
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI += " file://links2.desktop \
-             http://www.xora.org.uk/oe/links2.png;name=icon"
-
-S = "${WORKDIR}/links-${PV}"
-
-EXTRA_OECONF = "--enable-graphics \
-                --with-ssl=${STAGING_LIBDIR}/.. --with-libjpeg \
-                --without-libtiff --without-svgalib --without-fb \
-                --without-directfb --without-pmshell --without-atheos \
-                --with-x --without-gpm"
-
-do_install_append() {
-    install -d ${D}/${datadir}/applications
-    install -m 0644 ${WORKDIR}/links2.desktop ${D}/${datadir}/applications
-    install -d ${D}/${datadir}/pixmaps
-    install -m 0644 ${WORKDIR}/links2.png ${D}/${datadir}/pixmaps
-}
-
-SRC_URI[md5sum] = "d06aa6e14b2172d73188871a5357185a"
-SRC_URI[sha256sum] = "0c182b1cbcdfd5cdcd2f75a6032d1a4b660d07c1225c1e07757cec81d3302130"
-SRC_URI[icon.md5sum] = "477e8787927c634614bac01b44355a33"
-SRC_URI[icon.sha256sum] = "eddcd8b8c8698aa621d1a453943892d77b72ed492e0d14e0dbac5c6a57e52f47"
diff --git a/meta-openembedded/meta-oe/recipes-support/links/links.inc b/meta-openembedded/meta-oe/recipes-support/links/links.inc
index e072408..d6aa2d2 100644
--- a/meta-openembedded/meta-oe/recipes-support/links/links.inc
+++ b/meta-openembedded/meta-oe/recipes-support/links/links.inc
@@ -3,7 +3,7 @@
 HOMEPAGE = "http://links.twibright.com/"
 SECTION = "console/network"
 LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=65e735be2e05d5943803344148f57603"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b0c80473f97008e42e29a9f80fcc55ff"
 DEPENDS = "jpeg libpng flex openssl zlib"
 
 SRC_URI = "http://links.twibright.com/download/links-${PV}.tar.bz2 \
diff --git a/meta-openembedded/meta-oe/recipes-support/links/links_2.16.bb b/meta-openembedded/meta-oe/recipes-support/links/links_2.16.bb
new file mode 100644
index 0000000..19ea7a6
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/links/links_2.16.bb
@@ -0,0 +1,15 @@
+require links.inc
+
+DEPENDS += "gpm"
+RCONFLICTS_${PN} = "links-x11"
+
+EXTRA_OECONF = "--enable-graphics \
+                --with-ssl=${STAGING_LIBDIR}/.. --with-libjpeg \
+                --without-libtiff --without-svgalib --with-fb \
+                --without-directfb --without-pmshell --without-atheos \
+                --without-x"
+
+SRC_URI[md5sum] = "645fb0c0294e4c3268f94d307d394ffb"
+SRC_URI[sha256sum] = "82f03038d5e050a65681b9888762af41c40fd42dec7e59a8d630bfb0ee134a3f"
+SRC_URI[icon.md5sum] = "477e8787927c634614bac01b44355a33"
+SRC_URI[icon.sha256sum] = "eddcd8b8c8698aa621d1a453943892d77b72ed492e0d14e0dbac5c6a57e52f47"
diff --git a/meta-openembedded/meta-oe/recipes-support/links/links_2.7.bb b/meta-openembedded/meta-oe/recipes-support/links/links_2.7.bb
deleted file mode 100644
index e80dd7b..0000000
--- a/meta-openembedded/meta-oe/recipes-support/links/links_2.7.bb
+++ /dev/null
@@ -1,13 +0,0 @@
-require links.inc
-
-DEPENDS += "gpm"
-RCONFLICTS_${PN} = "links-x11"
-
-EXTRA_OECONF = "--enable-graphics \
-                --with-ssl=${STAGING_LIBDIR}/.. --with-libjpeg \
-                --without-libtiff --without-svgalib --with-fb \
-                --without-directfb --without-pmshell --without-atheos \
-                --without-x"
-
-SRC_URI[md5sum] = "d06aa6e14b2172d73188871a5357185a"
-SRC_URI[sha256sum] = "0c182b1cbcdfd5cdcd2f75a6032d1a4b660d07c1225c1e07757cec81d3302130"
diff --git a/meta-openembedded/meta-oe/recipes-support/lio-utils/lio-utils_4.1.bb b/meta-openembedded/meta-oe/recipes-support/lio-utils/lio-utils_4.1.bb
index 3a6319c..d9780cf 100644
--- a/meta-openembedded/meta-oe/recipes-support/lio-utils/lio-utils_4.1.bb
+++ b/meta-openembedded/meta-oe/recipes-support/lio-utils/lio-utils_4.1.bb
@@ -60,3 +60,7 @@
     bash"
 
 FILES_${PN} += "${sbindir}/* /etc/init.d/* /etc/target/*"
+
+# http://errors.yoctoproject.org/Errors/Details/184712/
+# python-native/python: can't open file 'setup.py': [Errno 2] No such file or directory
+CLEANBROKEN = "1"
diff --git a/meta-openembedded/meta-oe/recipes-support/lockdev/lockdev/0001-include-sys-sysmacros.h-for-major-minor-definitions.patch b/meta-openembedded/meta-oe/recipes-support/lockdev/lockdev/0001-include-sys-sysmacros.h-for-major-minor-definitions.patch
new file mode 100644
index 0000000..12f5be9
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/lockdev/lockdev/0001-include-sys-sysmacros.h-for-major-minor-definitions.patch
@@ -0,0 +1,30 @@
+From 2f39dc3d6f920c0826aa74367da1a0a7cc49b0fe Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 11 Aug 2018 15:18:04 -0700
+Subject: [PATCH] include sys/sysmacros.h for major/minor definitions
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+inclusion of <sys/sysmacros.h> by <sys/types.h> is deprecated.
+This means that in a future release, the macros “major”, “minor”, and
+“makedev” will only be available from <sys/sysmacros.h>.
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/lockdev.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/lockdev.c b/src/lockdev.c
+index 9a0fca5..3581938 100644
+--- a/src/lockdev.c
++++ b/src/lockdev.c
+@@ -117,6 +117,7 @@
+ #include <sys/stat.h>
+ #include <sys/file.h>
+ #include <sys/types.h>
++#include <sys/sysmacros.h>
+ #include <sys/wait.h>
+ #include "lockdev.h"
+ #include "ttylock.h"
diff --git a/meta-openembedded/meta-oe/recipes-support/lockdev/lockdev_git.bb b/meta-openembedded/meta-oe/recipes-support/lockdev/lockdev_git.bb
index 507ce3f..5ad7f0c 100644
--- a/meta-openembedded/meta-oe/recipes-support/lockdev/lockdev_git.bb
+++ b/meta-openembedded/meta-oe/recipes-support/lockdev/lockdev_git.bb
@@ -6,7 +6,9 @@
 PV = "1.0.3+git${SRCPV}"
 
 SRCREV = "16b899645d32012cc94cc9232f64d4ddaaf0b795"
-SRC_URI = "git://anonscm.debian.org/lockdev/lockdev.git"
+SRC_URI = "git://anonscm.debian.org/lockdev/lockdev.git \
+           file://0001-include-sys-sysmacros.h-for-major-minor-definitions.patch \
+           "
 
 S = "${WORKDIR}/git"
 
diff --git a/meta-openembedded/meta-oe/recipes-support/lvm2/files/0001-Avoid-bashisms-in-init-scripts.patch b/meta-openembedded/meta-oe/recipes-support/lvm2/files/0001-Avoid-bashisms-in-init-scripts.patch
index e86ab25..5b55111 100644
--- a/meta-openembedded/meta-oe/recipes-support/lvm2/files/0001-Avoid-bashisms-in-init-scripts.patch
+++ b/meta-openembedded/meta-oe/recipes-support/lvm2/files/0001-Avoid-bashisms-in-init-scripts.patch
@@ -17,17 +17,17 @@
  scripts/lvm2_monitoring_init_rhel4            | 4 ++--
  8 files changed, 17 insertions(+), 17 deletions(-)
 
-diff --git a/scripts/blk_availability_init_red_hat.in b/scripts/blk_availability_init_red_hat.in
-index a84ffe7..6b855b7 100644
---- a/scripts/blk_availability_init_red_hat.in
-+++ b/scripts/blk_availability_init_red_hat.in
+Index: LVM2.2.02.177/scripts/blk_availability_init_red_hat.in
+===================================================================
+--- LVM2.2.02.177.orig/scripts/blk_availability_init_red_hat.in
++++ LVM2.2.02.177/scripts/blk_availability_init_red_hat.in
 @@ -1,4 +1,4 @@
 -#!/bin/bash
 +#!/bin/sh
  #
- # Copyright (C) 2012 Red Hat, Inc. All rights reserved.
+ # Copyright (C) 2012-2017 Red Hat, Inc. All rights reserved.
  #
-@@ -53,6 +53,6 @@ case "$1" in
+@@ -51,6 +51,6 @@ case "$1" in
    status)
  	;;
    *)
@@ -35,10 +35,10 @@
 +	echo "Usage: $0 {start|stop|status}"
  	;;
  esac
-diff --git a/scripts/clvmd_init_red_hat.in b/scripts/clvmd_init_red_hat.in
-index d7f3392..abc8011 100644
---- a/scripts/clvmd_init_red_hat.in
-+++ b/scripts/clvmd_init_red_hat.in
+Index: LVM2.2.02.177/scripts/clvmd_init_red_hat.in
+===================================================================
+--- LVM2.2.02.177.orig/scripts/clvmd_init_red_hat.in
++++ LVM2.2.02.177/scripts/clvmd_init_red_hat.in
 @@ -1,4 +1,4 @@
 -#!/bin/bash
 +#!/bin/sh
@@ -63,17 +63,17 @@
  	rtrn=2
  	;;
  esac
-diff --git a/scripts/cmirrord_init_red_hat.in b/scripts/cmirrord_init_red_hat.in
-index d4b7e37..d442cbc 100755
---- a/scripts/cmirrord_init_red_hat.in
-+++ b/scripts/cmirrord_init_red_hat.in
+Index: LVM2.2.02.177/scripts/cmirrord_init_red_hat.in
+===================================================================
+--- LVM2.2.02.177.orig/scripts/cmirrord_init_red_hat.in
++++ LVM2.2.02.177/scripts/cmirrord_init_red_hat.in
 @@ -1,4 +1,4 @@
 -#!/bin/bash
 +#!/bin/sh
  #
  # chkconfig: - 22 78
  # description: Starts and stops cmirrord
-@@ -101,7 +101,7 @@ case "$1" in
+@@ -103,7 +103,7 @@ case "$1" in
  		;;
  
  	*)
@@ -82,15 +82,15 @@
  		;;
  esac
  
-diff --git a/scripts/lvm2_cluster_activation_red_hat.sh.in b/scripts/lvm2_cluster_activation_red_hat.sh.in
-index abea026..d8cba2e 100644
---- a/scripts/lvm2_cluster_activation_red_hat.sh.in
-+++ b/scripts/lvm2_cluster_activation_red_hat.sh.in
+Index: LVM2.2.02.177/scripts/lvm2_cluster_activation_red_hat.sh.in
+===================================================================
+--- LVM2.2.02.177.orig/scripts/lvm2_cluster_activation_red_hat.sh.in
++++ LVM2.2.02.177/scripts/lvm2_cluster_activation_red_hat.sh.in
 @@ -1,4 +1,4 @@
 -#!/bin/bash
 +#!/bin/sh
  
- sbindir=@sbindir@
+ sbindir="@SBINDIR@"
  
 @@ -54,7 +54,7 @@ case "$1" in
  	rtrn=$?
@@ -101,15 +101,34 @@
  	rtrn=3
  	;;
  esac
-diff --git a/scripts/lvm2_lvmetad_init_red_hat.in b/scripts/lvm2_lvmetad_init_red_hat.in
-index b2f5d50..96269a9 100644
---- a/scripts/lvm2_lvmetad_init_red_hat.in
-+++ b/scripts/lvm2_lvmetad_init_red_hat.in
+Index: LVM2.2.02.177/scripts/lvm2_lvmetad_init_red_hat.in
+===================================================================
+--- LVM2.2.02.177.orig/scripts/lvm2_lvmetad_init_red_hat.in
++++ LVM2.2.02.177/scripts/lvm2_lvmetad_init_red_hat.in
 @@ -1,4 +1,4 @@
 -#!/bin/bash
 +#!/bin/sh
  #
- # Copyright (C) 2012 Red Hat, Inc. All rights reserved.
+ # Copyright (C) 2012-2017 Red Hat, Inc. All rights reserved.
+ #
+@@ -103,7 +103,7 @@ case "$1" in
+ 	;;
+ 
+   *)
+-	echo $"Usage: $0 {start|stop|force-stop|restart|condrestart|try-restart|status}"
++	echo "Usage: $0 {start|stop|force-stop|restart|condrestart|try-restart|status}"
+ 	;;
+ esac
+ 
+Index: LVM2.2.02.177/scripts/lvm2_lvmpolld_init_red_hat.in
+===================================================================
+--- LVM2.2.02.177.orig/scripts/lvm2_lvmpolld_init_red_hat.in
++++ LVM2.2.02.177/scripts/lvm2_lvmpolld_init_red_hat.in
+@@ -1,4 +1,4 @@
+-#!/bin/bash
++#!/bin/sh
+ #
+ # Copyright (C) 2015 Red Hat, Inc. All rights reserved.
  #
 @@ -105,7 +105,7 @@ case "$1" in
  	;;
@@ -120,36 +139,17 @@
  	;;
  esac
  
-diff --git a/scripts/lvm2_lvmpolld_init_red_hat.in b/scripts/lvm2_lvmpolld_init_red_hat.in
-index c521955..cdbaece 100644
---- a/scripts/lvm2_lvmpolld_init_red_hat.in
-+++ b/scripts/lvm2_lvmpolld_init_red_hat.in
-@@ -1,4 +1,4 @@
--#!/bin/bash
-+#!/bin/sh
- #
- # Copyright (C) 2015 Red Hat, Inc. All rights reserved.
- #
-@@ -107,7 +107,7 @@ case "$1" in
- 	;;
- 
-   *)
--	echo $"Usage: $0 {start|stop|force-stop|restart|condrestart|try-restart|status}"
-+	echo "Usage: $0 {start|stop|force-stop|restart|condrestart|try-restart|status}"
- 	;;
- esac
- 
-diff --git a/scripts/lvm2_monitoring_init_red_hat.in b/scripts/lvm2_monitoring_init_red_hat.in
-index de7ff0d..9ff6bb7 100644
---- a/scripts/lvm2_monitoring_init_red_hat.in
-+++ b/scripts/lvm2_monitoring_init_red_hat.in
+Index: LVM2.2.02.177/scripts/lvm2_monitoring_init_red_hat.in
+===================================================================
+--- LVM2.2.02.177.orig/scripts/lvm2_monitoring_init_red_hat.in
++++ LVM2.2.02.177/scripts/lvm2_monitoring_init_red_hat.in
 @@ -1,4 +1,4 @@
 -#!/bin/bash
 +#!/bin/sh
  #
  # Copyright (C) 2007-2009 Red Hat, Inc. All rights reserved.
  #
-@@ -128,7 +128,7 @@ case "$1" in
+@@ -127,7 +127,7 @@ case "$1" in
  	;;
  
    *)
@@ -158,10 +158,10 @@
  	;;
  esac
  
-diff --git a/scripts/lvm2_monitoring_init_rhel4 b/scripts/lvm2_monitoring_init_rhel4
-index 8eb06c5..2e8d0f7 100644
---- a/scripts/lvm2_monitoring_init_rhel4
-+++ b/scripts/lvm2_monitoring_init_rhel4
+Index: LVM2.2.02.177/scripts/lvm2_monitoring_init_rhel4
+===================================================================
+--- LVM2.2.02.177.orig/scripts/lvm2_monitoring_init_rhel4
++++ LVM2.2.02.177/scripts/lvm2_monitoring_init_rhel4
 @@ -1,4 +1,4 @@
 -#!/bin/bash
 +#!/bin/sh
@@ -177,6 +177,3 @@
  	;;
  esac
  
--- 
-2.12.0
-
diff --git a/meta-openembedded/meta-oe/recipes-support/lvm2/files/0001-implement-libc-specific-reopen_stream.patch b/meta-openembedded/meta-oe/recipes-support/lvm2/files/0001-implement-libc-specific-reopen_stream.patch
index 5d72402..bb582ed 100644
--- a/meta-openembedded/meta-oe/recipes-support/lvm2/files/0001-implement-libc-specific-reopen_stream.patch
+++ b/meta-openembedded/meta-oe/recipes-support/lvm2/files/0001-implement-libc-specific-reopen_stream.patch
@@ -19,11 +19,11 @@
  tools/lvmcmdline.c | 6 +++---
  2 files changed, 9 insertions(+), 3 deletions(-)
 
-diff --git a/lib/log/log.c b/lib/log/log.c
-index c933154..3581084 100644
---- a/lib/log/log.c
-+++ b/lib/log/log.c
-@@ -161,6 +161,7 @@ static void _check_and_replace_standard_log_streams(FILE *old_stream, FILE *new_
+Index: LVM2.2.02.177/lib/log/log.c
+===================================================================
+--- LVM2.2.02.177.orig/lib/log/log.c
++++ LVM2.2.02.177/lib/log/log.c
+@@ -161,6 +161,7 @@ static void _check_and_replace_standard_
   * Close and reopen standard stream on file descriptor fd.
   */
  int reopen_standard_stream(FILE **stream, const char *mode)
@@ -31,7 +31,7 @@
  {
  	int fd, fd_copy, new_fd;
  	const char *name;
-@@ -207,6 +208,11 @@ int reopen_standard_stream(FILE **stream, const char *mode)
+@@ -207,6 +208,11 @@ int reopen_standard_stream(FILE **stream
  	*stream = new_stream;
  	return 1;
  }
@@ -43,11 +43,11 @@
  
  void init_log_fn(lvm2_log_fn_t log_fn)
  {
-diff --git a/tools/lvmcmdline.c b/tools/lvmcmdline.c
-index 9a4deb7..f1f18e6 100644
---- a/tools/lvmcmdline.c
-+++ b/tools/lvmcmdline.c
-@@ -1818,7 +1818,7 @@ static int _check_standard_fds(void)
+Index: LVM2.2.02.177/tools/lvmcmdline.c
+===================================================================
+--- LVM2.2.02.177.orig/tools/lvmcmdline.c
++++ LVM2.2.02.177/tools/lvmcmdline.c
+@@ -3095,7 +3095,7 @@ static int _check_standard_fds(void)
  	int err = is_valid_fd(STDERR_FILENO);
  
  	if (!is_valid_fd(STDIN_FILENO) &&
@@ -56,7 +56,7 @@
  		if (err)
  			perror("stdin stream open");
  		else
-@@ -1828,7 +1828,7 @@ static int _check_standard_fds(void)
+@@ -3105,7 +3105,7 @@ static int _check_standard_fds(void)
  	}
  
  	if (!is_valid_fd(STDOUT_FILENO) &&
@@ -65,7 +65,7 @@
  		if (err)
  			perror("stdout stream open");
  		/* else no stdout */
-@@ -1836,7 +1836,7 @@ static int _check_standard_fds(void)
+@@ -3113,7 +3113,7 @@ static int _check_standard_fds(void)
  	}
  
  	if (!is_valid_fd(STDERR_FILENO) &&
@@ -74,6 +74,3 @@
  		printf("stderr stream open: %s\n",
  		       strerror(errno));
  		return 0;
--- 
-2.12.0
-
diff --git a/meta-openembedded/meta-oe/recipes-support/lvm2/files/0002-Guard-use-of-mallinfo-with-__GLIBC__.patch b/meta-openembedded/meta-oe/recipes-support/lvm2/files/0002-Guard-use-of-mallinfo-with-__GLIBC__.patch
index 95dcede..ce8a97a 100644
--- a/meta-openembedded/meta-oe/recipes-support/lvm2/files/0002-Guard-use-of-mallinfo-with-__GLIBC__.patch
+++ b/meta-openembedded/meta-oe/recipes-support/lvm2/files/0002-Guard-use-of-mallinfo-with-__GLIBC__.patch
@@ -12,11 +12,11 @@
  lib/mm/memlock.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-diff --git a/lib/mm/memlock.c b/lib/mm/memlock.c
-index da90144..f34f890 100644
---- a/lib/mm/memlock.c
-+++ b/lib/mm/memlock.c
-@@ -150,7 +150,7 @@ static void _touch_memory(void *mem, size_t size)
+Index: LVM2.2.02.177/lib/mm/memlock.c
+===================================================================
+--- LVM2.2.02.177.orig/lib/mm/memlock.c
++++ LVM2.2.02.177/lib/mm/memlock.c
+@@ -151,7 +151,7 @@ static void _touch_memory(void *mem, siz
  
  static void _allocate_memory(void)
  {
@@ -25,6 +25,3 @@
  	void *stack_mem;
  	struct rlimit limit;
  	int i, area = 0, missing = _size_malloc_tmp, max_areas = 32, hblks;
--- 
-2.12.0
-
diff --git a/meta-openembedded/meta-oe/recipes-support/lvm2/files/0004-tweak-MODPROBE_CMD-for-cross-compile.patch b/meta-openembedded/meta-oe/recipes-support/lvm2/files/0004-tweak-MODPROBE_CMD-for-cross-compile.patch
index aaeaa72..517b9a5 100644
--- a/meta-openembedded/meta-oe/recipes-support/lvm2/files/0004-tweak-MODPROBE_CMD-for-cross-compile.patch
+++ b/meta-openembedded/meta-oe/recipes-support/lvm2/files/0004-tweak-MODPROBE_CMD-for-cross-compile.patch
@@ -1,6 +1,6 @@
-From 0012ea63f6070a5d41fa380970f9c30b953237d2 Mon Sep 17 00:00:00 2001
-From: Dengke Du <dengke.du@windriver.com>
-Date: Tue, 25 Oct 2016 11:59:40 +0000
+From 3bba45890985b877b823836e78a1c8ac3c878856 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Tue, 31 Jul 2018 15:04:29 +0800
 Subject: [PATCH 4/4] tweak MODPROBE_CMD for cross compile
 
 Lvm uses variable MODPROBE_CMD at runtime, so build time detection of modprobe
@@ -16,23 +16,23 @@
 Upstream-Status: Inappropriate [oe specific]
 
 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
-Signed-off-by: Dengke Du <dengke.du@windriver.com>
 ---
- configure.in | 1 -
- 1 file changed, 1 deletion(-)
+ configure.ac | 2 --
+ 1 file changed, 2 deletions(-)
 
-diff --git a/configure.in b/configure.in
-index cc77aab..a3579f2 100644
---- a/configure.in
-+++ b/configure.in
-@@ -1853,7 +1853,6 @@ if test "$UDEV_SYNC" = yes; then
+diff --git a/configure.ac b/configure.ac
+index e427708..aa374ea 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -1791,8 +1791,6 @@ if test "$BUILD_DMFILEMAPD" = yes; then
  fi
  
  ################################################################################
--AC_PATH_TOOL(MODPROBE_CMD, modprobe)
- 
+-AC_PATH_TOOL(MODPROBE_CMD, modprobe, [], [$PATH_SBIN])
+-
  if test -n "$MODPROBE_CMD"; then
  	AC_DEFINE_UNQUOTED([MODPROBE_CMD], ["$MODPROBE_CMD"], [The path to 'modprobe', if available.])
+ fi
 -- 
-2.9.3
+2.7.4
 
diff --git a/meta-openembedded/meta-oe/recipes-support/lvm2/files/0005-do-not-build-manual.patch b/meta-openembedded/meta-oe/recipes-support/lvm2/files/0005-do-not-build-manual.patch
index 15aa9f5..e3ce4c8 100644
--- a/meta-openembedded/meta-oe/recipes-support/lvm2/files/0005-do-not-build-manual.patch
+++ b/meta-openembedded/meta-oe/recipes-support/lvm2/files/0005-do-not-build-manual.patch
@@ -1,6 +1,6 @@
-From d8bb25e34d6533ba78eaae697771ee499a66706f Mon Sep 17 00:00:00 2001
+From 51d661ff33bb254d7b335a9c87acf5c6e7a94192 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Wed, 2 Aug 2017 03:41:37 -0400
+Date: Tue, 31 Jul 2018 15:08:34 +0800
 Subject: [PATCH] do not build manual
 
 On some host (ubuntu 1404), build manual failed.
@@ -15,24 +15,33 @@
 
 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
- Makefile.in  | 4 ++--
- configure.in | 1 -
- 2 files changed, 2 insertions(+), 3 deletions(-)
+ Makefile.in  | 6 +++---
+ configure.ac | 1 -
+ 2 files changed, 3 insertions(+), 4 deletions(-)
 
 diff --git a/Makefile.in b/Makefile.in
-index 31d428d..24f89a2 100644
+index e2f5a84..acf31e5 100644
 --- a/Makefile.in
 +++ b/Makefile.in
 @@ -18,7 +18,7 @@ top_builddir = @top_builddir@
  abs_top_builddir = @abs_top_builddir@
  abs_top_srcdir = @abs_top_srcdir@
  
--SUBDIRS = conf daemons include lib libdaemon libdm man scripts tools
-+SUBDIRS = conf daemons include lib libdaemon libdm scripts tools
+-SUBDIRS = conf daemons include lib libdaemon libdm man scripts device_mapper tools
++SUBDIRS = conf daemons include lib libdaemon libdm scripts device_mapper tools
  
  ifeq ("@UDEV_RULES@", "yes")
    SUBDIRS += udev
-@@ -69,7 +69,7 @@ liblvm.device-mapper: include.device-mapper
+@@ -41,7 +41,7 @@ ifeq ($(MAKECMDGOALS),clean)
+ endif
+ # FIXME Should use intermediate Makefiles here!
+ ifeq ($(MAKECMDGOALS),distclean)
+-  SUBDIRS = conf include man test scripts \
++  SUBDIRS = conf include test scripts \
+     libdaemon lib tools daemons libdm \
+     udev po liblvm python device_mapper
+ tools.distclean: test.distclean
+@@ -71,7 +71,7 @@ liblvm.device-mapper: include.device-mapper
  daemons.device-mapper: libdm.device-mapper
  tools.device-mapper: libdm.device-mapper
  scripts.device-mapper: include.device-mapper
@@ -41,11 +50,11 @@
  
  ifeq ("@INTL@", "yes")
  lib.pofile: include.pofile
-diff --git a/configure.in b/configure.in
-index 1dc8819..108ace4 100644
---- a/configure.in
-+++ b/configure.in
-@@ -2213,7 +2213,6 @@ libdm/Makefile
+diff --git a/configure.ac b/configure.ac
+index aa374ea..5a92cba 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -2124,7 +2124,6 @@ libdm/Makefile
  libdm/libdevmapper.pc
  liblvm/Makefile
  liblvm/liblvm2app.pc
@@ -54,5 +63,5 @@
  python/Makefile
  python/setup.py
 -- 
-2.8.1
+2.7.4
 
diff --git a/meta-openembedded/meta-oe/recipes-support/lvm2/libdevmapper_2.02.171.bb b/meta-openembedded/meta-oe/recipes-support/lvm2/libdevmapper_2.02.171.bb
deleted file mode 100644
index b6ae902..0000000
--- a/meta-openembedded/meta-oe/recipes-support/lvm2/libdevmapper_2.02.171.bb
+++ /dev/null
@@ -1,16 +0,0 @@
-require lvm2.inc
-
-SRC_URI[md5sum] = "153b7bb643eb26073274968e9026fa8f"
-SRC_URI[sha256sum] = "b815a711a2fabaa5c3dc1a4a284df0268bf0f325f0fc0f5c9530c9bbb54b9964"
-
-DEPENDS += "autoconf-archive-native"
-
-TARGET_CC_ARCH += "${LDFLAGS}"
-
-do_install() {
-    oe_runmake 'DESTDIR=${D}' -C libdm install
-}
-
-RRECOMMENDS_${PN}_append_class-target = " lvm2-udevrules"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-support/lvm2/libdevmapper_2.02.180.bb b/meta-openembedded/meta-oe/recipes-support/lvm2/libdevmapper_2.02.180.bb
new file mode 100644
index 0000000..26af327
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/lvm2/libdevmapper_2.02.180.bb
@@ -0,0 +1,17 @@
+require lvm2.inc
+
+SRC_URI[md5sum] = "bc26da66e96727babbd288bb0f050339"
+SRC_URI[sha256sum] = "24997e26dfc916151707c9da504d38d0473bec3481a8230b676bc079041bead6"
+
+DEPENDS += "autoconf-archive-native"
+
+TARGET_CC_ARCH += "${LDFLAGS}"
+
+do_install() {
+    oe_runmake 'DESTDIR=${D}' -C libdm install
+    oe_runmake 'DESTDIR=${D}' -C tools install_device-mapper
+}
+
+RRECOMMENDS_${PN}_append_class-target = " lvm2-udevrules"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-support/lvm2/lvm2.inc b/meta-openembedded/meta-oe/recipes-support/lvm2/lvm2.inc
index 289e07d..26a887e 100644
--- a/meta-openembedded/meta-oe/recipes-support/lvm2/lvm2.inc
+++ b/meta-openembedded/meta-oe/recipes-support/lvm2/lvm2.inc
@@ -1,11 +1,11 @@
 HOMEPAGE = "https://www.sourceware.org/lvm2/"
 SECTION = "utils"
 DESCRIPTION = "LVM2 is a set of utilities to manage logical volumes in Linux."
-LICENSE = "GPLv2 & LGPLv2"
+LICENSE = "GPLv2 & LGPLv2.1"
 LIC_FILES_CHKSUM = "file://COPYING;md5=12713b4d9386533feeb07d6e4831765a \
                     file://COPYING.LIB;md5=fbc093901857fcd118f065f900982c24"
 
-DEPENDS += "util-linux"
+DEPENDS += "util-linux libaio"
 
 SRC_URI = "ftp://sources.redhat.com/pub/lvm2/old/LVM2.${PV}.tgz \
            file://lvm.conf \
@@ -17,6 +17,10 @@
            file://0005-do-not-build-manual.patch \
            file://0006-start-lvm2-monitor.service-after-tmp.mount.patch \
            "
+
+UPSTREAM_CHECK_URI = "ftp://sources.redhat.com/pub/lvm2/"
+UPSTREAM_CHECK_REGEX = "LVM2\.(?P<pver>\d+(\.\d+)+)"
+
 S = "${WORKDIR}/LVM2.${PV}"
 
 inherit autotools-brokensep pkgconfig systemd license
diff --git a/meta-openembedded/meta-oe/recipes-support/lvm2/lvm2/0001-explicitly-do-not-install-libdm.patch b/meta-openembedded/meta-oe/recipes-support/lvm2/lvm2/0001-explicitly-do-not-install-libdm.patch
index e85818d..7f5dd93 100644
--- a/meta-openembedded/meta-oe/recipes-support/lvm2/lvm2/0001-explicitly-do-not-install-libdm.patch
+++ b/meta-openembedded/meta-oe/recipes-support/lvm2/lvm2/0001-explicitly-do-not-install-libdm.patch
@@ -1,4 +1,4 @@
-From 0a8e466fcf99622896e070c5133165e4278e8cfb Mon Sep 17 00:00:00 2001
+From 5a3e13ae94318c2bed60f875bb3852c45ce0113c Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Thu, 25 May 2017 05:27:11 -0400
 Subject: [PATCH] explicitly do not install libdm
@@ -9,12 +9,14 @@
 Upstream-Status: Inappropriate [meta-oe specific]
 
 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+Signed-off-by: Andrew Bresticker <abrestic@waymo.com>
 ---
  libdm/Makefile.in | 6 ++++--
- 1 file changed, 4 insertions(+), 2 deletions(-)
+ tools/Makefile.in | 3 ++-
+ 2 files changed, 6 insertions(+), 3 deletions(-)
 
 diff --git a/libdm/Makefile.in b/libdm/Makefile.in
-index 3c9a4ce..45c91c6 100644
+index 66ec39513..c779c9d86 100644
 --- a/libdm/Makefile.in
 +++ b/libdm/Makefile.in
 @@ -77,9 +77,11 @@ ifeq ("@PKGCONFIG@", "yes")
@@ -23,14 +25,28 @@
  
 -install: $(INSTALL_TYPE) install_include
 +install:
-+	echo "Do not install device mappler in lvm2"
++	echo "Do not install device mapper in lvm2"
  
 -install_device-mapper: install
 +install_device-mapper:
-+	echo "Do not install device mappler in lvm2"
++	echo "Do not install device mapper in lvm2"
  
  install_include: $(srcdir)/libdevmapper.h
  	$(INSTALL_DATA) -D $< $(includedir)/$(<F)
+diff --git a/tools/Makefile.in b/tools/Makefile.in
+index 103b76732..63ba7fc04 100644
+--- a/tools/Makefile.in
++++ b/tools/Makefile.in
+@@ -267,7 +267,8 @@ install_dmsetup_static: dmsetup.static
+ 	$(Q) $(INSTALL_PROGRAM) -D $< $(staticdir)/$(<F)
+ 	$(Q) $(LN_S) -f $(<F) $(staticdir)/dmstats
+ 
+-install_device-mapper: $(INSTALL_DMSETUP_TARGETS)
++install_device-mapper:
++	echo "Do not install device mapper in lvm2"
+ 
+ install_lvm2: $(INSTALL_LVM_TARGETS)
+ 
 -- 
-2.8.1
+2.19.0.397.gdd90340f6a-goog
 
diff --git a/meta-openembedded/meta-oe/recipes-support/lvm2/lvm2_2.02.171.bb b/meta-openembedded/meta-oe/recipes-support/lvm2/lvm2_2.02.171.bb
deleted file mode 100644
index 84881e7..0000000
--- a/meta-openembedded/meta-oe/recipes-support/lvm2/lvm2_2.02.171.bb
+++ /dev/null
@@ -1,54 +0,0 @@
-require lvm2.inc
-
-SRC_URI[md5sum] = "153b7bb643eb26073274968e9026fa8f"
-SRC_URI[sha256sum] = "b815a711a2fabaa5c3dc1a4a284df0268bf0f325f0fc0f5c9530c9bbb54b9964"
-
-SRC_URI += "file://0001-explicitly-do-not-install-libdm.patch"
-
-DEPENDS += "autoconf-archive-native"
-
-CACHED_CONFIGUREVARS += "MODPROBE_CMD=${base_sbindir}/modprobe"
-
-do_install_append() {
-    # Install machine specific configuration file
-    install -d ${D}${sysconfdir}/lvm
-    install -m 0644 ${WORKDIR}/lvm.conf ${D}${sysconfdir}/lvm/lvm.conf
-    sed -i -e 's:@libdir@:${libdir}:g' ${D}${sysconfdir}/lvm/lvm.conf
-    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
-        oe_runmake 'DESTDIR=${D}' install install_systemd_units
-        sed -i -e 's:/usr/bin/true:${base_bindir}/true:g' ${D}${systemd_system_unitdir}/blk-availability.service
-    else
-        oe_runmake 'DESTDIR=${D}' install install_initscripts
-        mv ${D}${sysconfdir}/rc.d/init.d ${D}${sysconfdir}/init.d
-        rm -rf ${D}${sysconfdir}/rc.d
-    fi
-}
-
-PACKAGE_BEFORE_PN = "${PN}-scripts ${PN}-udevrules"
-
-SYSTEMD_PACKAGES = "${PN}"
-SYSTEMD_SERVICE_${PN} = "${@bb.utils.contains('PACKAGECONFIG', 'dmeventd', 'lvm2-monitor.service dm-event.socket dm-event.service', '', d)} \
-                         ${@bb.utils.contains('PACKAGECONFIG', 'lvmetad', 'lvm2-lvmetad.socket lvm2-pvscan@.service', '', d)} \
-                         blk-availability.service"
-SYSTEMD_AUTO_ENABLE = "disable"
-
-TARGET_CC_ARCH += "${LDFLAGS}"
-
-FILES_${PN} += "${libdir}/device-mapper/*.so"
-FILES_${PN}-scripts = " \
-    ${sbindir}/blkdeactivate \
-    ${sbindir}/fsadm \
-    ${sbindir}/lvmconf \
-    ${sbindir}/lvmdump \
-"
-# Specified explicitly for the udev rules, just in case that it does not get picked
-# up automatically:
-FILES_${PN}-udevrules = "${nonarch_base_libdir}/udev/rules.d"
-RDEPENDS_${PN}_append_class-target = " libdevmapper"
-
-RDEPENDS_${PN}-scripts = "${PN} (= ${EXTENDPKGV}) bash"
-RRECOMMENDS_${PN}_class-target = "${PN}-scripts (= ${EXTENDPKGV})"
-
-CONFFILES_${PN} += "${sysconfdir}/lvm/lvm.conf"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-support/lvm2/lvm2_2.02.180.bb b/meta-openembedded/meta-oe/recipes-support/lvm2/lvm2_2.02.180.bb
new file mode 100644
index 0000000..7bd7b09
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/lvm2/lvm2_2.02.180.bb
@@ -0,0 +1,62 @@
+require lvm2.inc
+
+SRC_URI[md5sum] = "bc26da66e96727babbd288bb0f050339"
+SRC_URI[sha256sum] = "24997e26dfc916151707c9da504d38d0473bec3481a8230b676bc079041bead6"
+
+SRC_URI += "file://0001-explicitly-do-not-install-libdm.patch"
+
+DEPENDS += "autoconf-archive-native"
+
+inherit multilib_script
+
+MULTILIB_SCRIPTS = "${PN}:${sysconfdir}/lvm/lvm.conf"
+
+CACHED_CONFIGUREVARS += "MODPROBE_CMD=${base_sbindir}/modprobe"
+
+do_install_append() {
+    # Install machine specific configuration file
+    install -d ${D}${sysconfdir}/lvm
+    install -m 0644 ${WORKDIR}/lvm.conf ${D}${sysconfdir}/lvm/lvm.conf
+    sed -i -e 's:@libdir@:${libdir}:g' ${D}${sysconfdir}/lvm/lvm.conf
+    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
+        oe_runmake 'DESTDIR=${D}' install install_systemd_units
+        sed -i -e 's:/usr/bin/true:${base_bindir}/true:g' ${D}${systemd_system_unitdir}/blk-availability.service
+    else
+        oe_runmake 'DESTDIR=${D}' install install_initscripts
+        mv ${D}${sysconfdir}/rc.d/init.d ${D}${sysconfdir}/init.d
+        rm -rf ${D}${sysconfdir}/rc.d
+    fi
+}
+
+PACKAGE_BEFORE_PN = "${PN}-scripts ${PN}-udevrules"
+
+SYSTEMD_PACKAGES = "${PN}"
+SYSTEMD_SERVICE_${PN} = "${@bb.utils.contains('PACKAGECONFIG', 'dmeventd', 'lvm2-monitor.service dm-event.socket dm-event.service', '', d)} \
+                         ${@bb.utils.contains('PACKAGECONFIG', 'lvmetad', 'lvm2-lvmetad.socket lvm2-pvscan@.service', '', d)} \
+                         blk-availability.service"
+SYSTEMD_AUTO_ENABLE = "disable"
+
+TARGET_CC_ARCH += "${LDFLAGS}"
+
+EXTRA_OECONF_append_class-nativesdk = " --with-confdir=${sysconfdir}"
+
+FILES_${PN} += "${libdir}/device-mapper/*.so"
+FILES_${PN}-scripts = " \
+    ${sbindir}/blkdeactivate \
+    ${sbindir}/fsadm \
+    ${sbindir}/lvmconf \
+    ${sbindir}/lvmdump \
+"
+# Specified explicitly for the udev rules, just in case that it does not get picked
+# up automatically:
+FILES_${PN}-udevrules = "${nonarch_base_libdir}/udev/rules.d"
+RDEPENDS_${PN}-udevrules = "${PN}"
+RDEPENDS_${PN}_append_class-target = " libdevmapper"
+RDEPENDS_${PN}_append_class-nativesdk = " libdevmapper"
+
+RDEPENDS_${PN}-scripts = "${PN} (= ${EXTENDPKGV}) bash"
+RRECOMMENDS_${PN}_class-target = "${PN}-scripts (= ${EXTENDPKGV})"
+
+CONFFILES_${PN} += "${sysconfdir}/lvm/lvm.conf"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-oe/recipes-support/mcelog/mce-inject_git.bb b/meta-openembedded/meta-oe/recipes-support/mcelog/mce-inject_git.bb
index f876144..cc33cba 100644
--- a/meta-openembedded/meta-oe/recipes-support/mcelog/mce-inject_git.bb
+++ b/meta-openembedded/meta-oe/recipes-support/mcelog/mce-inject_git.bb
@@ -8,6 +8,10 @@
 
 SRCREV = "4cbe46321b4a81365ff3aafafe63967264dbfec5"
 
+UPSTREAM_CHECK_COMMITS = "1"
+
+DEPENDS = "bison-native"
+
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://README;beginline=30;md5=94c18755082a2da9c9cf97cba3ad47d6"
 
diff --git a/meta-openembedded/meta-oe/recipes-support/mcelog/mcelog_1.49.bb b/meta-openembedded/meta-oe/recipes-support/mcelog/mcelog_1.49.bb
deleted file mode 100644
index 84633a7..0000000
--- a/meta-openembedded/meta-oe/recipes-support/mcelog/mcelog_1.49.bb
+++ /dev/null
@@ -1,35 +0,0 @@
-SUMMARY = "mcelog daemon accounts memory and some other errors in various ways."
-DESCRIPTION = "mcelog is required by both 32bit x86 Linux kernels (since 2.6.30) \
-and 64bit Linux kernels (since early 2.6 kernel releases) to log machine checks \
-and should run on all Linux systems that need error handling."
-HOMEPAGE = "http://mcelog.org/"
-SECTION = "System Environment/Base"
-
-SRC_URI = "git://git.kernel.org/pub/scm/utils/cpu/mce/mcelog.git;protocol=http; \
-    file://run-ptest \
-"
-
-SRCREV = "2cfdf29b2ef98ccd5ed42cdde8bbe437e0d6412f"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://README.md;md5=279840fabb191e6cd9150492d31b0e20"
-
-S = "${WORKDIR}/git"
-
-inherit autotools-brokensep ptest
-
-COMPATIBLE_HOST = '(x86_64.*|i.86.*)-linux'
-
-do_install_append() {
-    install -d ${D}${sysconfdir}/cron.hourly
-    install -m 0755 ${S}/mcelog.cron ${D}${sysconfdir}/cron.hourly/
-    sed -i 's/bash/sh/' ${D}${sysconfdir}/cron.hourly/mcelog.cron
-}
-
-do_install_ptest() {
-    install -d ${D}${PTEST_PATH}
-    cp -r ${S}/tests ${S}/input ${D}${PTEST_PATH}
-    sed -i 's#../../mcelog#mcelog#' ${D}${PTEST_PATH}/tests/test
-}
-
-RDEPENDS_${PN}-ptest += "${PN} make bash mce-inject"
diff --git a/meta-openembedded/meta-oe/recipes-support/mcelog/mcelog_161.bb b/meta-openembedded/meta-oe/recipes-support/mcelog/mcelog_161.bb
new file mode 100644
index 0000000..dfca385
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/mcelog/mcelog_161.bb
@@ -0,0 +1,35 @@
+SUMMARY = "mcelog daemon accounts memory and some other errors in various ways."
+DESCRIPTION = "mcelog is required by both 32bit x86 Linux kernels (since 2.6.30) \
+and 64bit Linux kernels (since early 2.6 kernel releases) to log machine checks \
+and should run on all Linux systems that need error handling."
+HOMEPAGE = "http://mcelog.org/"
+SECTION = "System Environment/Base"
+
+SRC_URI = "git://git.kernel.org/pub/scm/utils/cpu/mce/mcelog.git;protocol=http; \
+    file://run-ptest \
+"
+
+SRCREV = "6ed93e30f83519b0ab71f8ecd156b8ff0b2912b6"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://README.md;md5=74bb47b9a68850cb398665cf78b31de6"
+
+S = "${WORKDIR}/git"
+
+inherit autotools-brokensep ptest
+
+COMPATIBLE_HOST = '(x86_64.*|i.86.*)-linux'
+
+do_install_append() {
+    install -d ${D}${sysconfdir}/cron.hourly
+    install -m 0755 ${S}/mcelog.cron ${D}${sysconfdir}/cron.hourly/
+    sed -i 's/bash/sh/' ${D}${sysconfdir}/cron.hourly/mcelog.cron
+}
+
+do_install_ptest() {
+    install -d ${D}${PTEST_PATH}
+    cp -r ${S}/tests ${S}/input ${D}${PTEST_PATH}
+    sed -i 's#../../mcelog#mcelog#' ${D}${PTEST_PATH}/tests/test
+}
+
+RDEPENDS_${PN}-ptest += "${PN} make bash mce-inject"
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0001-kpartx-include-limits.h-for-PATH_MAX.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0001-kpartx-include-limits.h-for-PATH_MAX.patch
deleted file mode 100644
index 46dd8e2..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0001-kpartx-include-limits.h-for-PATH_MAX.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From 330028a5a904a0da3788141030e614569dc5aaa7 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 14 Jul 2017 23:28:12 -0700
-Subject: [PATCH] kpartx: include limits.h for PATH_MAX
-
-lopart.c:76:12: error: 'PATH_MAX' undeclared (first use in this function); did you mean 'INT8_MAX'?
-  char path[PATH_MAX];
-            ^~~~~~~~
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- kpartx/lopart.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/kpartx/lopart.c b/kpartx/lopart.c
-index 7005445..5efe5dc 100644
---- a/kpartx/lopart.c
-+++ b/kpartx/lopart.c
-@@ -22,6 +22,7 @@
- #include <errno.h>
- #include <stdlib.h>
- #include <unistd.h>
-+#include <limits.h>
- #include <sys/ioctl.h>
- #include <sys/stat.h>
- #include <sys/mman.h>
--- 
-2.13.3
-
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0001-multipath-attempt-at-common-multipath.rules.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0001-multipath-attempt-at-common-multipath.rules.patch
deleted file mode 100644
index acb4269..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0001-multipath-attempt-at-common-multipath.rules.patch
+++ /dev/null
@@ -1,107 +0,0 @@
-From 5ab50e0cb888e553a2635bbbf81eea3cdeffee60 Mon Sep 17 00:00:00 2001
-From: Benjamin Marzinski <bmarzins@redhat.com>
-Date: Wed, 12 Apr 2017 09:07:51 -0500
-Subject: [PATCH 01/14] multipath: attempt at common multipath.rules
-
-This is a proposal to try and bring the Redhat and SuSE multipath.rules
-closer. There are a couple of changes that I'd like some input on.
-
-The big change is moving the kpartx call into the multipath rules.  Half
-of the current kpartx.rules file is about creating symlinks for multiple
-types of dm devices. The other half auto-creates kpartx devices on top
-of multipath devices. Since it is only creating kpartx devices on top of
-multipath devices, I've moved the these rules into multipath.rules, or
-rather, I've replaced them with the redhat rules in multipath.rules. The
-biggest difference is the kpartx isn't run on every reload.  It works
-with the 11-dm-mpath.rules code to not run kpartx on multipathd
-generated reloads or when there aren't any working paths. It does
-remember if it didn't get to run kpartx when it was supposed to (because
-there were no valid paths or the device was suspended) and will make
-sure to run it on the next possible uevent.
-
-The other change is the redhat multipath rules remove the partition
-device nodes for devices claimed by multipath. The udev rule will only
-do this one time (both to keep from running partx on every event, and so
-that if users manually reread the partition table, we don't keep
-removing them when clearly they are wanted). Redhat does this because we
-had multiple customer issues where they were using the scsi partitions
-instead of the kpartx devices. Obviously, with setting the partition
-devices to not ready and clearing their fs_type, this isn't essential,
-but it has helped make customers do the right thing.
-
-Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
----
- kpartx/kpartx.rules       |  8 --------
- multipath/multipath.rules | 27 ++++++++++++++++++++++++---
- 2 files changed, 24 insertions(+), 11 deletions(-)
-
-diff --git a/kpartx/kpartx.rules b/kpartx/kpartx.rules
-index a958791..906e320 100644
---- a/kpartx/kpartx.rules
-+++ b/kpartx/kpartx.rules
-@@ -34,12 +34,4 @@ ENV{ID_FS_LABEL_ENC}=="?*", IMPORT{db}="ID_FS_LABEL_ENC"
- ENV{ID_FS_USAGE}=="filesystem|other", ENV{ID_FS_LABEL_ENC}=="?*", \
- 	SYMLINK+="disk/by-label/$env{ID_FS_LABEL_ENC}"
- 
--# Create dm tables for partitions
--ENV{DM_ACTION}=="PATH_FAILED|PATH_REINSTATED", GOTO="kpartx_end"
--ENV{DM_NR_VALID_PATHS}=="0", GOTO="kpartx_end"
--ENV{ENV{DM_UDEV_PRIMARY_SOURCE_FLAG}!="1", IMPORT{db}="DM_SUBSYSTEM_UDEV_FLAG1"
--ENV{DM_SUBSYSTEM_UDEV_FLAG1}=="1", GOTO="kpartx_end"
--ENV{DM_STATE}!="SUSPENDED", ENV{DM_UUID}=="mpath-*", \
--	RUN+="/sbin/kpartx -un -p -part /dev/$name"
--
- LABEL="kpartx_end"
-diff --git a/multipath/multipath.rules b/multipath/multipath.rules
-index 86defc0..616a04c 100644
---- a/multipath/multipath.rules
-+++ b/multipath/multipath.rules
-@@ -1,13 +1,13 @@
- # Set DM_MULTIPATH_DEVICE_PATH if the device should be handled by multipath
- SUBSYSTEM!="block", GOTO="end_mpath"
- ACTION!="add|change", GOTO="end_mpath"
--KERNEL!="sd*|dasd*", GOTO="end_mpath"
--
-+KERNEL!="sd*|dasd*|rbd*|dm-*", GOTO="end_mpath"
- IMPORT{cmdline}="nompath"
- ENV{nompath}=="?*", GOTO="end_mpath"
- IMPORT{cmdline}="multipath"
- ENV{multipath}=="off", GOTO="end_mpath"
- 
-+KERNEL=="dm-*", GOTO="check_kpartx"
- ENV{DEVTYPE}!="partition", GOTO="test_dev"
- IMPORT{parent}="DM_MULTIPATH_DEVICE_PATH"
- ENV{DM_MULTIPATH_DEVICE_PATH}=="1", ENV{ID_FS_TYPE}="none", \
-@@ -21,7 +21,28 @@ TEST!="$env{MPATH_SBIN_PATH}/multipath", ENV{MPATH_SBIN_PATH}="/usr/sbin"
- 
- ENV{DM_MULTIPATH_DEVICE_PATH}!="1", \
- 	PROGRAM=="$env{MPATH_SBIN_PATH}/multipath -u %k", \
--	ENV{DM_MULTIPATH_DEVICE_PATH}="1", ENV{ID_FS_TYPE}="none", \
-+	ENV{DM_MULTIPATH_DEVICE_PATH}="1", ENV{ID_FS_TYPE}="mpath_member", \
- 	ENV{SYSTEMD_READY}="0"
- 
-+ENV{DM_MULTIPATH_DEVICE_PATH}!="1", GOTO="end_mpath"
-+
-+IMPORT{db}="DM_MULTIPATH_WIPE_PARTS"
-+ENV{DM_MULTIPATH_WIPE_PARTS}!="1", ENV{DM_MULTIPATH_WIPE_PARTS}="1", \
-+	RUN+="/sbin/partx -d --nr 1-1024 $env{DEVNAME}"
-+GOTO="end_mpath"
-+
-+LABEL="check_kpartx"
-+
-+IMPORT{db}="DM_MULTIPATH_NEED_KPARTX"
-+ENV{DM_UDEV_PRIMARY_SOURCE_FLAG}!="1", IMPORT{db}="DM_SUBSYSTEM_UDEV_FLAG1"
-+ENV{DM_SUBSYSTEM_UDEV_FLAG1}=="1", GOTO="end_mpath"
-+ACTION!="change", GOTO="end_mpath"
-+ENV{DM_UUID}!="mpath-?*", GOTO="end_mpath"
-+ENV{DM_ACTIVATION}=="1", ENV{DM_MULTIPATH_NEED_KPARTX}="1"
-+ENV{DM_SUSPENDED}=="1", GOTO="end_mpath"
-+ENV{DM_ACTION}=="PATH_FAILED", GOTO="end_mpath"
-+ENV{DM_ACTIVATION}!="1", ENV{DM_MULTIPATH_NEED_KPARTX}!="1", GOTO="end_mpath"
-+RUN+="/sbin/kpartx -un -p -part /dev/$name"
-+ENV{DM_MULTIPATH_NEED_KPARTX}=""
-+
- LABEL="end_mpath"
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0001-multipath-tools-add-RDAC-SUN-ArrayStorage-to-hwtable.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0001-multipath-tools-add-RDAC-SUN-ArrayStorage-to-hwtable.patch
new file mode 100644
index 0000000..1d983e9
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0001-multipath-tools-add-RDAC-SUN-ArrayStorage-to-hwtable.patch
@@ -0,0 +1,42 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Date: Wed, 11 Apr 2018 15:14:13 +0200
+Subject: [PATCH] multipath-tools: add RDAC SUN/ArrayStorage to hwtable
+
+Already in scsi_dh: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/scsi/scsi_dh.c#n70
+
+Cc: NetApp RDAC team <ng-eseries-upstream-maintainers@netapp.com>
+Cc: Christophe Varoqui <christophe.varoqui@opensvc.com>
+Cc: DM ML <dm-devel@redhat.com>
+Signed-off-by: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/hwtable.c | 12 ++++++++++++
+ 1 file changed, 12 insertions(+)
+
+diff --git a/libmultipath/hwtable.c b/libmultipath/hwtable.c
+index 88b4700..827e899 100644
+--- a/libmultipath/hwtable.c
++++ b/libmultipath/hwtable.c
+@@ -890,6 +890,18 @@ static struct hwentry default_hw[] = {
+ 		.no_path_retry = 30,
+ 	},
+ 	{
++		.vendor        = "SUN",
++		.product       = "ArrayStorage",
++		.bl_product    = "Universal Xport",
++		.pgpolicy      = GROUP_BY_PRIO,
++		.checker_name  = RDAC,
++		.features      = "2 pg_init_retries 50",
++		.hwhandler     = "1 rdac",
++		.prio_name     = PRIO_RDAC,
++		.pgfailback    = -FAILBACK_IMMEDIATE,
++		.no_path_retry = 30,
++	},
++	{
+ 		/* ZFS Storage Appliances */
+ 		.vendor        = "SUN",
+ 		.product       = "(Sun Storage|ZFS Storage|COMSTAR)",
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0002-RH-fixup-udev-rules-for-redhat.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0002-RH-fixup-udev-rules-for-redhat.patch
deleted file mode 100644
index e63d2eb..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0002-RH-fixup-udev-rules-for-redhat.patch
+++ /dev/null
@@ -1,110 +0,0 @@
-From 158255383c02d3fb81c82fb9ec6fd36fb234f68e Mon Sep 17 00:00:00 2001
-From: Benjamin Marzinski <bmarzins@redhat.com>
-Date: Thu, 13 Apr 2017 07:22:23 -0500
-Subject: [PATCH 02/14] RH: fixup udev rules for redhat
-
-The multipath rules need to run after scsi_id is run. This means moving
-them after 60-persistent-storage.rules for redhat. Also, we don't
-currently set up all the symlinks that SuSE does. If we want them, they
-should be done in the device-mapper package, since they are for all
-device-mapper devices. Redhat also uses a different naming scheme for
-partitions than SuSE.
-
-Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
----
- Makefile.inc              |  2 +-
- kpartx/Makefile           | 14 +++++++-------
- multipath/Makefile        |  4 ++--
- multipath/multipath.rules |  3 ++-
- 4 files changed, 12 insertions(+), 11 deletions(-)
-
-diff --git a/Makefile.inc b/Makefile.inc
-index 1815f9a..2591fa9 100644
---- a/Makefile.inc
-+++ b/Makefile.inc
-@@ -47,7 +47,7 @@ endif
- 
- prefix		=
- exec_prefix	= $(prefix)
--bindir		= $(exec_prefix)/sbin
-+bindir		= $(exec_prefix)/usr/sbin
- libudevdir	= $(prefix)/$(SYSTEMDPATH)/udev
- udevrulesdir	= $(libudevdir)/rules.d
- multipathdir	= $(TOPDIR)/libmultipath
-diff --git a/kpartx/Makefile b/kpartx/Makefile
-index 7b75032..bfa6fe8 100644
---- a/kpartx/Makefile
-+++ b/kpartx/Makefile
-@@ -26,19 +26,19 @@ $(EXEC): $(OBJS)
- install: $(EXEC) $(EXEC).8
- 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(bindir)
- 	$(INSTALL_PROGRAM) -m 755 $(EXEC) $(DESTDIR)$(bindir)
--	$(INSTALL_PROGRAM) -d $(DESTDIR)$(libudevdir)
--	$(INSTALL_PROGRAM) -m 755 kpartx_id $(DESTDIR)$(libudevdir)
--	$(INSTALL_PROGRAM) -d $(DESTDIR)$(libudevdir)/rules.d
--	$(INSTALL_PROGRAM) -m 644 kpartx.rules $(DESTDIR)$(libudevdir)/rules.d/66-kpartx.rules
-+#	$(INSTALL_PROGRAM) -d $(DESTDIR)$(libudevdir)
-+#	$(INSTALL_PROGRAM) -m 755 kpartx_id $(DESTDIR)$(libudevdir)
-+#	$(INSTALL_PROGRAM) -d $(DESTDIR)$(libudevdir)/rules.d
-+#	$(INSTALL_PROGRAM) -m 644 kpartx.rules $(DESTDIR)$(libudevdir)/rules.d/66-kpartx.rules
- 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(man8dir)
- 	$(INSTALL_PROGRAM) -m 644 $(EXEC).8.gz $(DESTDIR)$(man8dir)
- 
- uninstall:
- 	$(RM) $(DESTDIR)$(bindir)/$(EXEC)
- 	$(RM) $(DESTDIR)$(man8dir)/$(EXEC).8.gz
--	$(RM) $(DESTDIR)$(libudevdir)/kpartx_id
--	$(RM) $(DESTDIR)$(libudevdir)/rules.d/66-kpartx.rules
--	$(RM) $(DESTDIR)$(libudevdir)/rules.d/67-kpartx-compat.rules
-+#	$(RM) $(DESTDIR)$(libudevdir)/kpartx_id
-+#	$(RM) $(DESTDIR)$(libudevdir)/rules.d/66-kpartx.rules
-+#	$(RM) $(DESTDIR)$(libudevdir)/rules.d/67-kpartx-compat.rules
- 
- clean:
- 	$(RM) core *.o $(EXEC) *.gz
-diff --git a/multipath/Makefile b/multipath/Makefile
-index c85314e..1e9ee4b 100644
---- a/multipath/Makefile
-+++ b/multipath/Makefile
-@@ -24,7 +24,7 @@ install:
- 	$(INSTALL_PROGRAM) -m 755 $(EXEC) $(DESTDIR)$(bindir)/
- 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(udevrulesdir)
- 	$(INSTALL_PROGRAM) -m 644 11-dm-mpath.rules $(DESTDIR)$(udevrulesdir)
--	$(INSTALL_PROGRAM) -m 644 $(EXEC).rules $(DESTDIR)$(libudevdir)/rules.d/56-multipath.rules
-+	$(INSTALL_PROGRAM) -m 644 $(EXEC).rules $(DESTDIR)$(libudevdir)/rules.d/62-multipath.rules
- 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(man8dir)
- 	$(INSTALL_PROGRAM) -m 644 $(EXEC).8.gz $(DESTDIR)$(man8dir)
- 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(man5dir)
-@@ -33,7 +33,7 @@ install:
- uninstall:
- 	$(RM) $(DESTDIR)$(bindir)/$(EXEC)
- 	$(RM) $(DESTDIR)$(udevrulesdir)/11-dm-mpath.rules
--	$(RM) $(DESTDIR)$(libudevdir)/rules.d/56-multipath.rules
-+	$(RM) $(DESTDIR)$(libudevdir)/rules.d/62-multipath.rules
- 	$(RM) $(DESTDIR)$(man8dir)/$(EXEC).8.gz
- 	$(RM) $(DESTDIR)$(man5dir)/$(EXEC).conf.5.gz
- 
-diff --git a/multipath/multipath.rules b/multipath/multipath.rules
-index 616a04c..4d78b98 100644
---- a/multipath/multipath.rules
-+++ b/multipath/multipath.rules
-@@ -33,6 +33,7 @@ GOTO="end_mpath"
- 
- LABEL="check_kpartx"
- 
-+ENV{DM_UUID}=="mpath-?*|part[0-9]*-mpath-?*", OPTIONS+="link_priority=10"
- IMPORT{db}="DM_MULTIPATH_NEED_KPARTX"
- ENV{DM_UDEV_PRIMARY_SOURCE_FLAG}!="1", IMPORT{db}="DM_SUBSYSTEM_UDEV_FLAG1"
- ENV{DM_SUBSYSTEM_UDEV_FLAG1}=="1", GOTO="end_mpath"
-@@ -42,7 +43,7 @@ ENV{DM_ACTIVATION}=="1", ENV{DM_MULTIPATH_NEED_KPARTX}="1"
- ENV{DM_SUSPENDED}=="1", GOTO="end_mpath"
- ENV{DM_ACTION}=="PATH_FAILED", GOTO="end_mpath"
- ENV{DM_ACTIVATION}!="1", ENV{DM_MULTIPATH_NEED_KPARTX}!="1", GOTO="end_mpath"
--RUN+="/sbin/kpartx -un -p -part /dev/$name"
-+RUN+="/sbin/kpartx -un /dev/$name"
- ENV{DM_MULTIPATH_NEED_KPARTX}=""
- 
- LABEL="end_mpath"
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0002-multipath-tools-remove-c-from-__cpluscplus-misspelle.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0002-multipath-tools-remove-c-from-__cpluscplus-misspelle.patch
new file mode 100644
index 0000000..73f000a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0002-multipath-tools-remove-c-from-__cpluscplus-misspelle.patch
@@ -0,0 +1,33 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Date: Tue, 24 Apr 2018 15:03:40 +0200
+Subject: [PATCH] multipath-tools: remove "c" from __cpluscplus, misspelled
+
+found by cppcheck(http://cppcheck.sf.net/):
+[libmpathcmd/mpath_cmd.h:24]: (error) Invalid number of character '{' when these macros are defined: '__cpluscplus'.
+
+Cc: Benjamin Marzinski <bmarzins@redhat.com>
+Cc: Christophe Varoqui <christophe.varoqui@opensvc.com>
+Cc: DM ML <dm-devel@redhat.com>
+Signed-off-by: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmpathcmd/mpath_cmd.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/libmpathcmd/mpath_cmd.h b/libmpathcmd/mpath_cmd.h
+index aaa8da9..df9d938 100644
+--- a/libmpathcmd/mpath_cmd.h
++++ b/libmpathcmd/mpath_cmd.h
+@@ -20,7 +20,7 @@
+ #ifndef LIB_MPATH_CMD_H
+ #define LIB_MPATH_CMD_H
+ 
+-#ifdef __cpluscplus
++#ifdef __cplusplus
+ extern "C" {
+ #endif
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0003-RH-Remove-the-property-blacklist-exception-builtin.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0003-RH-Remove-the-property-blacklist-exception-builtin.patch
deleted file mode 100644
index 684e959..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0003-RH-Remove-the-property-blacklist-exception-builtin.patch
+++ /dev/null
@@ -1,70 +0,0 @@
-From 69a67c2ed09ae51b53de402966a9f7a4cc737715 Mon Sep 17 00:00:00 2001
-From: Benjamin Marzinski <bmarzins@redhat.com>
-Date: Wed, 2 Jul 2014 12:49:53 -0500
-Subject: [PATCH 03/14] RH: Remove the property blacklist exception builtin
-
-Multipath set the default property blacklist exceptions to
-(ID_SCSI_VPD|ID_WWN).  This has the effect of blacklisting some internal
-devices.  These devices may never have multiple paths, but it is nice
-to be able to set multipath up on them all the same.  This patch simply
-removes the default, and makes it so that if no property
-blacklist_exception is given, then devices aren't failed for not matching
-it.
-
-Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
----
- libmultipath/blacklist.c   | 15 ++++++---------
- multipath/multipath.conf.5 |  4 ----
- 2 files changed, 6 insertions(+), 13 deletions(-)
-
-diff --git a/libmultipath/blacklist.c b/libmultipath/blacklist.c
-index ee396e2..19d4697 100644
---- a/libmultipath/blacklist.c
-+++ b/libmultipath/blacklist.c
-@@ -181,12 +181,6 @@ setup_default_blist (struct config * conf)
- 	if (store_ble(conf->blist_devnode, str, ORIGIN_DEFAULT))
- 		return 1;
- 
--	str = STRDUP("(SCSI_IDENT_|ID_WWN)");
--	if (!str)
--		return 1;
--	if (store_ble(conf->elist_property, str, ORIGIN_DEFAULT))
--		return 1;
--
- 	vector_foreach_slot (conf->hwtable, hwe, i) {
- 		if (hwe->bl_product) {
- 			if (_blacklist_device(conf->blist_device, hwe->vendor,
-@@ -390,9 +384,12 @@ filter_property(struct config * conf, struct udev_device * udev)
- 	 * This is the inverse of the 'normal' matching;
- 	 * the environment variable _has_ to match.
- 	 */
--	log_filter(devname, NULL, NULL, NULL, NULL,
--		   MATCH_PROPERTY_BLIST_MISSING);
--	return MATCH_PROPERTY_BLIST_MISSING;
-+	if (VECTOR_SIZE(conf->elist_property)) {
-+		log_filter(devname, NULL, NULL, NULL, NULL,
-+			   MATCH_PROPERTY_BLIST_MISSING);
-+		return MATCH_PROPERTY_BLIST_MISSING;
-+	}
-+	return 0;
- }
- 
- void
-diff --git a/multipath/multipath.conf.5 b/multipath/multipath.conf.5
-index f04ff19..fbbbb27 100644
---- a/multipath/multipath.conf.5
-+++ b/multipath/multipath.conf.5
-@@ -1014,10 +1014,6 @@ The \fIWorld Wide Identification\fR of a device.
- .TP
- .B property
- Regular expression of the udev property to be whitelisted.
--.RS
--.TP
--The default is: \fB(SCSI_IDENT_|ID_WWN)\fR
--.RE
- .TP
- .B device
- Subsection for the device description. This subsection recognizes the
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0003-multipath-tools-remove-emacs-autoconfig-of-kpartx-gp.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0003-multipath-tools-remove-emacs-autoconfig-of-kpartx-gp.patch
new file mode 100644
index 0000000..7358e1a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0003-multipath-tools-remove-emacs-autoconfig-of-kpartx-gp.patch
@@ -0,0 +1,43 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Date: Thu, 12 Apr 2018 18:17:13 +0200
+Subject: [PATCH] multipath-tools: remove emacs autoconfig of kpartx/gpt.h
+
+Cc: Christophe Varoqui <christophe.varoqui@opensvc.com>
+Cc: DM ML <dm-devel@redhat.com>
+Signed-off-by: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ kpartx/gpt.h | 19 -------------------
+ 1 file changed, 19 deletions(-)
+
+diff --git a/kpartx/gpt.h b/kpartx/gpt.h
+index 66ce8f1..7bb54b7 100644
+--- a/kpartx/gpt.h
++++ b/kpartx/gpt.h
+@@ -109,22 +109,3 @@ int read_gpt_pt (int fd, struct slice all, struct slice *sp, int ns);
+ 
+ 
+ #endif
+-
+-/*
+- * Overrides for Emacs so that we follow Linus's tabbing style.
+- * Emacs will notice this stuff at the end of the file and automatically
+- * adjust the settings for this buffer only.  This must remain at the end
+- * of the file.
+- * ---------------------------------------------------------------------------
+- * Local variables:
+- * c-indent-level: 4
+- * c-brace-imaginary-offset: 0
+- * c-brace-offset: -4
+- * c-argdecl-indent: 4
+- * c-label-offset: -4
+- * c-continued-statement-offset: 4
+- * c-continued-brace-offset: 0
+- * indent-tabs-mode: nil
+- * tab-width: 8
+- * End:
+- */
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0004-RH-don-t-start-without-a-config-file.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0004-RH-don-t-start-without-a-config-file.patch
deleted file mode 100644
index 87a6d3f..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0004-RH-don-t-start-without-a-config-file.patch
+++ /dev/null
@@ -1,108 +0,0 @@
-From b2b504fc1959c7a3f0a843c3c204e8e193b675b7 Mon Sep 17 00:00:00 2001
-From: Benjamin Marzinski <bmarzins@redhat.com>
-Date: Wed, 15 Oct 2014 10:39:30 -0500
-Subject: [PATCH 04/14] RH: don't start without a config file
-
-If /etc/multipath.conf doesn't exist, don't start multipathd and blacklist
-all devices when running multipath.  A completely blank configuration file
-is almost never what users want.  Also, people may have the multipath
-packages installed but don't want to use them.  This patch provides a
-simple way to disable multipath.  Simply removing or renaming
-/etc/multipath.conf will keep multipath from doing anything.
-
-Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
----
- libmultipath/config.c         | 17 +++++++++++++++++
- libmultipath/config.h         |  1 +
- multipath/multipath.rules     |  1 +
- multipathd/multipathd.8       |  2 ++
- multipathd/multipathd.service |  1 +
- 5 files changed, 22 insertions(+)
-
-diff --git a/libmultipath/config.c b/libmultipath/config.c
-index bb6619b..aae69b8 100644
---- a/libmultipath/config.c
-+++ b/libmultipath/config.c
-@@ -25,6 +25,7 @@
- #include "prio.h"
- #include "devmapper.h"
- #include "mpath_cmd.h"
-+#include "version.h"
- 
- static int
- hwe_strmatch (struct hwentry *hwe1, struct hwentry *hwe2)
-@@ -667,6 +668,22 @@ load_config (char * file)
- 			factorize_hwtable(conf->hwtable, builtin_hwtable_size);
- 		}
- 
-+	} else {
-+		condlog(0, "/etc/multipath.conf does not exist, blacklisting all devices.");
-+		condlog(0, "A default multipath.conf file is located at");
-+		condlog(0, "/usr/share/doc/device-mapper-multipath-%d.%d.%d/multipath.conf", MULTIPATH_VERSION(VERSION_CODE));
-+		if (conf->blist_devnode == NULL) {
-+			conf->blist_devnode = vector_alloc();
-+			if (!conf->blist_devnode) {
-+				condlog(0, "cannot allocate blacklist\n");
-+				goto out;
-+			}
-+		}
-+		if (store_ble(conf->blist_devnode, strdup(".*"),
-+		              ORIGIN_NO_CONFIG)) {
-+			condlog(0, "cannot store default no-config blacklist\n");
-+			goto out;
-+		}
- 	}
- 
- 	conf->processed_main_config = 1;
-diff --git a/libmultipath/config.h b/libmultipath/config.h
-index ffc69b5..614331c 100644
---- a/libmultipath/config.h
-+++ b/libmultipath/config.h
-@@ -7,6 +7,7 @@
- 
- #define ORIGIN_DEFAULT 0
- #define ORIGIN_CONFIG  1
-+#define ORIGIN_NO_CONFIG 2
- 
- /*
-  * In kernel, fast_io_fail == 0 means immediate failure on rport delete.
-diff --git a/multipath/multipath.rules b/multipath/multipath.rules
-index 4d78b98..5753766 100644
---- a/multipath/multipath.rules
-+++ b/multipath/multipath.rules
-@@ -6,6 +6,7 @@ IMPORT{cmdline}="nompath"
- ENV{nompath}=="?*", GOTO="end_mpath"
- IMPORT{cmdline}="multipath"
- ENV{multipath}=="off", GOTO="end_mpath"
-+TEST!="/etc/multipath.conf", GOTO="end_mpath"
- 
- KERNEL=="dm-*", GOTO="check_kpartx"
- ENV{DEVTYPE}!="partition", GOTO="test_dev"
-diff --git a/multipathd/multipathd.8 b/multipathd/multipathd.8
-index 4c765af..c1499a5 100644
---- a/multipathd/multipathd.8
-+++ b/multipathd/multipathd.8
-@@ -39,6 +39,8 @@ map regains its maximum performance and redundancy.
- This daemon executes the external \fBmultipath\fR tool when events occur.
- In turn, the multipath tool signals the multipathd daemon when it is done with
- devmap reconfiguration, so that it can refresh its failed path list.
-+
-+In this Linux distribution, multipathd does not run unless a /etc/multipath.conffile exists
- .
- .
- .\" ----------------------------------------------------------------------------
-diff --git a/multipathd/multipathd.service b/multipathd/multipathd.service
-index fd66cf6..fafd088 100644
---- a/multipathd/multipathd.service
-+++ b/multipathd/multipathd.service
-@@ -4,6 +4,7 @@ Wants=systemd-udev-trigger.service systemd-udev-settle.service
- Before=iscsi.service iscsid.service lvm2-lvmetad.service lvm2-activation-early.service
- Before=local-fs-pre.target blk-availability.service
- After=multipathd.socket systemd-udev-trigger.service systemd-udev-settle.service
-+ConditionPathExists=/etc/multipath.conf
- DefaultDependencies=no
- Conflicts=shutdown.target
- ConditionKernelCommandLine=!nompath
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0004-multipath-tools-replace-FSF-address-with-a-www-point.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0004-multipath-tools-replace-FSF-address-with-a-www-point.patch
new file mode 100644
index 0000000..13f18b5
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0004-multipath-tools-replace-FSF-address-with-a-www-point.patch
@@ -0,0 +1,191 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Date: Fri, 11 May 2018 15:42:43 +0200
+Subject: [PATCH] multipath-tools: replace FSF address with a www pointer
+
+Less prone to future modifications, new FSF licences
+point exactly to this url: <http://www.gnu.org/licenses/>.
+And sending a smail to FSF is outdated.
+
+First clean up was done in 5619a39c433ac3d10a88079593cec1aa6472cbeb
+
+Cc: Martin Wilck <mwilck@suse.com>
+Cc: Benjamin Marzinski <bmarzins@redhat.com>
+Cc: Christophe Varoqui <christophe.varoqui@opensvc.com>
+Cc: DM ML <dm-devel@redhat.com>
+Signed-off-by: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/dm-generic.c   | 4 +---
+ libmultipath/dm-generic.h   | 4 +---
+ libmultipath/foreign.c      | 4 +---
+ libmultipath/foreign.h      | 4 +---
+ libmultipath/foreign/nvme.c | 4 +---
+ libmultipath/generic.c      | 4 +---
+ libmultipath/generic.h      | 4 +---
+ tests/dmevents.c            | 2 +-
+ tests/parser.c              | 2 +-
+ tests/uevent.c              | 2 +-
+ tests/util.c                | 2 +-
+ 11 files changed, 11 insertions(+), 25 deletions(-)
+
+diff --git a/libmultipath/dm-generic.c b/libmultipath/dm-generic.c
+index bdc9ca0..d752991 100644
+--- a/libmultipath/dm-generic.c
++++ b/libmultipath/dm-generic.c
+@@ -12,9 +12,7 @@
+   GNU General Public License for more details.
+ 
+   You should have received a copy of the GNU General Public License
+-  along with this program; if not, write to the Free Software
+-  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301,
+-  USA.
++  along with this program.  If not, see <https://www.gnu.org/licenses/>.
+  */
+ 
+ #include <stdint.h>
+diff --git a/libmultipath/dm-generic.h b/libmultipath/dm-generic.h
+index 5d59724..986429f 100644
+--- a/libmultipath/dm-generic.h
++++ b/libmultipath/dm-generic.h
+@@ -12,9 +12,7 @@
+   GNU General Public License for more details.
+ 
+   You should have received a copy of the GNU General Public License
+-  along with this program; if not, write to the Free Software
+-  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301,
+-  USA.
++  along with this program.  If not, see <https://www.gnu.org/licenses/>.
+  */
+ #ifndef _DM_GENERIC_H
+ #define _DM_GENERIC_H
+diff --git a/libmultipath/foreign.c b/libmultipath/foreign.c
+index 7217184..80b399b 100644
+--- a/libmultipath/foreign.c
++++ b/libmultipath/foreign.c
+@@ -12,9 +12,7 @@
+   GNU General Public License for more details.
+ 
+   You should have received a copy of the GNU General Public License
+-  along with this program; if not, write to the Free Software
+-  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301,
+-  USA.
++  along with this program.  If not, see <https://www.gnu.org/licenses/>.
+ */
+ 
+ #include <sys/sysmacros.h>
+diff --git a/libmultipath/foreign.h b/libmultipath/foreign.h
+index 973f368..697f12f 100644
+--- a/libmultipath/foreign.h
++++ b/libmultipath/foreign.h
+@@ -12,9 +12,7 @@
+   GNU General Public License for more details.
+ 
+   You should have received a copy of the GNU General Public License
+-  along with this program; if not, write to the Free Software
+-  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301,
+-  USA.
++  along with this program.  If not, see <https://www.gnu.org/licenses/>.
+ */
+ #ifndef _FOREIGN_H
+ #define _FOREIGN_H
+diff --git a/libmultipath/foreign/nvme.c b/libmultipath/foreign/nvme.c
+index 235f75d..280b6bd 100644
+--- a/libmultipath/foreign/nvme.c
++++ b/libmultipath/foreign/nvme.c
+@@ -12,9 +12,7 @@
+   GNU General Public License for more details.
+ 
+   You should have received a copy of the GNU General Public License
+-  along with this program; if not, write to the Free Software
+-  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301,
+-  USA.
++  along with this program.  If not, see <https://www.gnu.org/licenses/>.
+ */
+ 
+ #include <sys/sysmacros.h>
+diff --git a/libmultipath/generic.c b/libmultipath/generic.c
+index 6f7a2cd..0d1e632 100644
+--- a/libmultipath/generic.c
++++ b/libmultipath/generic.c
+@@ -12,9 +12,7 @@
+   GNU General Public License for more details.
+ 
+   You should have received a copy of the GNU General Public License
+-  along with this program; if not, write to the Free Software
+-  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301,
+-  USA.
++  along with this program.  If not, see <https://www.gnu.org/licenses/>.
+  */
+ 
+ 
+diff --git a/libmultipath/generic.h b/libmultipath/generic.h
+index 7f7fe66..6346ffe 100644
+--- a/libmultipath/generic.h
++++ b/libmultipath/generic.h
+@@ -12,9 +12,7 @@
+   GNU General Public License for more details.
+ 
+   You should have received a copy of the GNU General Public License
+-  along with this program; if not, write to the Free Software
+-  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301,
+-  USA.
++  along with this program.  If not, see <https://www.gnu.org/licenses/>.
+  */
+ #ifndef _GENERIC_H
+ #define _GENERIC_H
+diff --git a/tests/dmevents.c b/tests/dmevents.c
+index bba51dc..3399c81 100644
+--- a/tests/dmevents.c
++++ b/tests/dmevents.c
+@@ -12,7 +12,7 @@
+  * GNU General Public License for more details.
+  *
+  * You should have received a copy of the GNU General Public License
+- * along with this program; if not, write to the Free Software
++ * along with this program.  If not, see <https://www.gnu.org/licenses/>.
+  *
+  */
+ 
+diff --git a/tests/parser.c b/tests/parser.c
+index a7e7598..29859da 100644
+--- a/tests/parser.c
++++ b/tests/parser.c
+@@ -12,7 +12,7 @@
+  * GNU General Public License for more details.
+  *
+  * You should have received a copy of the GNU General Public License
+- * along with this program; if not, write to the Free Software
++ * along with this program.  If not, see <https://www.gnu.org/licenses/>.
+  *
+  */
+ 
+diff --git a/tests/uevent.c b/tests/uevent.c
+index acfcb14..b0d0bfd 100644
+--- a/tests/uevent.c
++++ b/tests/uevent.c
+@@ -12,7 +12,7 @@
+  * GNU General Public License for more details.
+  *
+  * You should have received a copy of the GNU General Public License
+- * along with this program; if not, write to the Free Software
++ * along with this program.  If not, see <https://www.gnu.org/licenses/>.
+  *
+  */
+ 
+diff --git a/tests/util.c b/tests/util.c
+index 113b134..839effd 100644
+--- a/tests/util.c
++++ b/tests/util.c
+@@ -12,7 +12,7 @@
+  * GNU General Public License for more details.
+  *
+  * You should have received a copy of the GNU General Public License
+- * along with this program; if not, write to the Free Software
++ * along with this program.  If not, see <https://www.gnu.org/licenses/>.
+  *
+  */
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0005-RH-add-mpathconf.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0005-RH-add-mpathconf.patch
deleted file mode 100644
index acef410..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0005-RH-add-mpathconf.patch
+++ /dev/null
@@ -1,648 +0,0 @@
-From de44504fe7f7802cd474efd92ac15b5a8857db1f Mon Sep 17 00:00:00 2001
-From: Benjamin Marzinski <bmarzins@redhat.com>
-Date: Thu, 16 Oct 2014 15:49:01 -0500
-Subject: [PATCH 05/14] RH: add mpathconf
-
-mpathconf is a program (largely based on lvmcomf) to help users
-configure /etc/multipath.conf and enable or disable multipathing.  It
-has a couple of built-in options that can be set directly from the
-command line.  But, mostly it is used to get a multipath.conf file
-with the OS defaults, and to enable and disable multipathing via
-a single command.
-
-Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
----
- libmultipath/config.c |   1 +
- multipath/Makefile    |   5 +
- multipath/mpathconf   | 464 ++++++++++++++++++++++++++++++++++++++++++++++++++
- multipath/mpathconf.8 | 101 +++++++++++
- 4 files changed, 571 insertions(+)
- create mode 100644 multipath/mpathconf
- create mode 100644 multipath/mpathconf.8
-
-diff --git a/libmultipath/config.c b/libmultipath/config.c
-index aae69b8..c485748 100644
---- a/libmultipath/config.c
-+++ b/libmultipath/config.c
-@@ -672,6 +672,7 @@ load_config (char * file)
- 		condlog(0, "/etc/multipath.conf does not exist, blacklisting all devices.");
- 		condlog(0, "A default multipath.conf file is located at");
- 		condlog(0, "/usr/share/doc/device-mapper-multipath-%d.%d.%d/multipath.conf", MULTIPATH_VERSION(VERSION_CODE));
-+		condlog(0, "You can run /sbin/mpathconf to create or modify /etc/multipath.conf");
- 		if (conf->blist_devnode == NULL) {
- 			conf->blist_devnode = vector_alloc();
- 			if (!conf->blist_devnode) {
-diff --git a/multipath/Makefile b/multipath/Makefile
-index 1e9ee4b..3d4d459 100644
---- a/multipath/Makefile
-+++ b/multipath/Makefile
-@@ -18,10 +18,12 @@ $(EXEC): $(OBJS)
- 	$(CC) $(CFLAGS) $(OBJS) -o $(EXEC) $(LDFLAGS) $(LIBDEPS)
- 	$(GZIP) $(EXEC).8 > $(EXEC).8.gz
- 	$(GZIP) $(EXEC).conf.5 > $(EXEC).conf.5.gz
-+	$(GZIP) mpathconf.8 > mpathconf.8.gz
- 
- install:
- 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(bindir)
- 	$(INSTALL_PROGRAM) -m 755 $(EXEC) $(DESTDIR)$(bindir)/
-+	$(INSTALL_PROGRAM) -m 755 mpathconf $(DESTDIR)$(bindir)/
- 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(udevrulesdir)
- 	$(INSTALL_PROGRAM) -m 644 11-dm-mpath.rules $(DESTDIR)$(udevrulesdir)
- 	$(INSTALL_PROGRAM) -m 644 $(EXEC).rules $(DESTDIR)$(libudevdir)/rules.d/62-multipath.rules
-@@ -29,13 +31,16 @@ install:
- 	$(INSTALL_PROGRAM) -m 644 $(EXEC).8.gz $(DESTDIR)$(man8dir)
- 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(man5dir)
- 	$(INSTALL_PROGRAM) -m 644 $(EXEC).conf.5.gz $(DESTDIR)$(man5dir)
-+	$(INSTALL_PROGRAM) -m 644 mpathconf.8.gz $(DESTDIR)$(man8dir)
- 
- uninstall:
- 	$(RM) $(DESTDIR)$(bindir)/$(EXEC)
- 	$(RM) $(DESTDIR)$(udevrulesdir)/11-dm-mpath.rules
- 	$(RM) $(DESTDIR)$(libudevdir)/rules.d/62-multipath.rules
-+	$(RM) $(DESTDIR)$(bindir)/mpathconf
- 	$(RM) $(DESTDIR)$(man8dir)/$(EXEC).8.gz
- 	$(RM) $(DESTDIR)$(man5dir)/$(EXEC).conf.5.gz
-+	$(RM) $(DESTDIR)$(man8dir)/mpathconf.8.gz
- 
- clean:
- 	$(RM) core *.o $(EXEC) *.gz
-diff --git a/multipath/mpathconf b/multipath/mpathconf
-new file mode 100644
-index 0000000..e839134
---- /dev/null
-+++ b/multipath/mpathconf
-@@ -0,0 +1,464 @@
-+#!/bin/bash
-+#
-+# Copyright (C) 2010 Red Hat, Inc. All rights reserved.
-+#
-+# This file is part of the device-mapper-multipath package.
-+#
-+# This copyrighted material is made available to anyone wishing to use,
-+# modify, copy, or redistribute it subject to the terms and conditions
-+# of the GNU General Public License v.2.
-+#
-+# You should have received a copy of the GNU General Public License
-+# along with this program; if not, write to the Free Software Foundation,
-+# Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
-+
-+#
-+# Simple editting of /etc/multipath.conf
-+# This program was largely ripped off from lvmconf
-+#
-+
-+unset ENABLE FIND FRIENDLY MODULE MULTIPATHD HAVE_DISABLE HAVE_WWID_DISABLE HAVE_FIND HAVE_BLACKLIST HAVE_EXCEPTIONS HAVE_DEFAULTS HAVE_FRIENDLY HAVE_MULTIPATHD HAVE_MODULE HAVE_OUTFILE SHOW_STATUS CHANGED_CONFIG WWID_LIST
-+
-+DEFAULT_CONFIG="# device-mapper-multipath configuration file
-+
-+# For a complete list of the default configuration values, run either:
-+# # multipath -t
-+# or
-+# # multipathd show config
-+
-+# For a list of configuration options with descriptions, see the
-+# multipath.conf man page.
-+
-+defaults {
-+	user_friendly_names yes
-+	find_multipaths yes
-+}
-+
-+blacklist_exceptions {
-+        property \"(SCSI_IDENT_|ID_WWN)\"
-+}"
-+
-+CONFIGFILE="/etc/multipath.conf"
-+OUTPUTFILE="/etc/multipath.conf"
-+MULTIPATHDIR="/etc/multipath"
-+TMPFILE="/etc/multipath/.multipath.conf.tmp"
-+WWIDS=0
-+
-+function usage
-+{
-+	echo "usage: $0 <command>"
-+	echo ""
-+	echo "Commands:"
-+	echo "Enable: --enable "
-+	echo "Disable: --disable"
-+	echo "Only allow certain wwids (instead of enable): --allow <WWID>"
-+	echo "Set user_friendly_names (Default y): --user_friendly_names <y|n>"
-+	echo "Set find_multipaths (Default y): --find_multipaths <y|n>"
-+	echo "Load the dm-multipath modules on enable (Default y): --with_module <y|n>"
-+	echo "start/stop/reload multipathd (Default n): --with_multipathd <y|n>"
-+	echo "select output file (Default /etc/multipath.conf): --outfile <FILE>"
-+	echo ""
-+}
-+
-+function add_wwid
-+{
-+	INDEX=0
-+	while [ "$INDEX" -lt "$WWIDS" ] ; do
-+		if [ "$1" = "${WWID_LIST[$INDEX]}" ] ; then
-+			return
-+		fi
-+		((INDEX++))
-+	done
-+	WWID_LIST[$WWIDS]="$1"
-+	((WWIDS++))
-+}
-+
-+function get_dm_deps
-+{
-+	shift 3
-+	while [ -n "$1" -a -n "$2" ]; do
-+		MAJOR=$(echo $1 | tr -d '(,')
-+		MINOR=$(echo $2 | tr -d ')')
-+		UUID=`dmsetup info -c --noheadings -o uuid -j $MAJOR -m $MINOR  2> /dev/null`
-+		if [ -n "$UUID" ] ; then
-+			set_dm_wwid $UUID
-+		fi
-+		shift 2
-+	done
-+}
-+
-+function set_dm_wwid
-+{
-+	if [[ "$1" =~ ^part[[:digit:]]+-mpath- ]] ; then
-+		add_wwid "${1##part*-mpath-}"
-+	elif [[ "$1" =~ ^mpath- ]] ; then
-+		add_wwid "${1##mpath-}"
-+	else
-+		get_dm_deps `dmsetup deps -u $1`
-+	fi
-+}
-+
-+function set_wwid
-+{
-+	UUID=""
-+	if [[ "$1" =~ ^[[:digit:]]+:[[:digit:]]+$ ]] ; then
-+		MAJOR=${1%%:*}
-+		MINOR=${1##*:}
-+		UUID=`dmsetup info -c --noheadings -o uuid -j $MAJOR -m $MINOR  2> /dev/null`
-+	else
-+		UUID=`dmsetup info -c --noheadings -o uuid $1 2> /dev/null`
-+	fi
-+	if [ -n "$UUID" ] ; then
-+		set_dm_wwid $UUID
-+	else
-+		add_wwid "$1"
-+	fi
-+}
-+
-+function parse_args
-+{
-+	while [ -n "$1" ]; do
-+		case $1 in
-+			--enable)
-+				ENABLE=1
-+				shift
-+				;;
-+			--disable)
-+				ENABLE=0
-+				shift
-+				;;
-+			--allow)
-+				ENABLE=2
-+				if [ -n "$2" ]; then
-+					set_wwid $2
-+					shift 2
-+				else
-+					usage
-+					exit 1
-+				fi
-+				;;
-+			--user_friendly_names)
-+				if [ -n "$2" ]; then
-+					FRIENDLY=$2
-+					shift 2
-+				else
-+					usage
-+					exit 1
-+				fi
-+				;;
-+			--find_multipaths)
-+				if [ -n "$2" ]; then
-+					FIND=$2
-+					shift 2
-+				else
-+					usage
-+					exit 1
-+				fi
-+				;;
-+			--with_module)
-+				if [ -n "$2" ]; then
-+					MODULE=$2
-+					shift 2
-+				else
-+					usage
-+					exit 1
-+				fi
-+				;;
-+			--with_multipathd)
-+				if [ -n "$2" ]; then
-+					MULTIPATHD=$2
-+					shift 2
-+				else
-+					usage
-+					exit 1
-+				fi
-+				;;
-+			--outfile)
-+				if [ -n "$2" ]; then
-+					OUTPUTFILE=$2
-+					HAVE_OUTFILE=1
-+					shift 2
-+				else
-+					usage
-+					exit 1
-+				fi
-+				;;
-+			*)
-+				usage
-+				exit
-+		esac
-+	done
-+}
-+
-+function validate_args
-+{
-+	if [ "$ENABLE" = "0" ] && [ -n "$FRIENDLY" -o -n "$FIND" -o -n "$MODULE" ]; then
-+		echo "ignoring extra parameters on disable"
-+		FRIENDLY=""
-+		FIND=""
-+		MODULE=""
-+	fi
-+	if [ -n "$FRIENDLY" ] && [ "$FRIENDLY" != "y" -a "$FRIENDLY" != "n" ]; then
-+		echo "--user_friendly_names must be either 'y' or 'n'"
-+		exit 1
-+	fi
-+	if [ -n "$FIND" ] && [ "$FIND" != "y" -a "$FIND" != "n" ]; then
-+		echo "--find_multipaths must be either 'y' or 'n'"
-+		exit 1
-+	fi
-+	if [ -z "$ENABLE" -a -z "$FIND" -a -z "$FRIENDLY" ]; then
-+		SHOW_STATUS=1
-+	fi
-+	if [ -n "$MODULE" ] && [ "$MODULE" != "y" -a "$MODULE" != "n" ]; then
-+		echo "--with_module must be either 'y' or 'n'"
-+		exit 1
-+	fi
-+	if [ -n "$MULTIPATHD" ] && [ "$MULTIPATHD" != "y" -a "$MULTIPATHD" != "n" ]; then
-+		echo "--with_multipathd must be either 'y' or 'n'"
-+		exit 1
-+	fi
-+	if [ "$ENABLE" = 2 -a -z "$HAVE_OUTFILE" ]; then
-+		echo "Because --allow makes changes that cannot be automatically reversed,"
-+		echo "you must set --outfile when you set --allow"
-+		exit 1
-+	fi
-+}
-+
-+function add_blacklist_exceptions
-+{
-+	INDEX=0
-+	while [ "$INDEX" -lt "$WWIDS" ] ; do
-+		sed -i '/^blacklist_exceptions[[:space:]]*{/ a\
-+	wwid '"\"${WWID_LIST[$INDEX]}\""'
-+' $TMPFILE
-+		((INDEX++))
-+	done
-+}
-+
-+umask 0077
-+
-+parse_args "$@"
-+
-+validate_args
-+
-+if [ ! -d "$MULTIPATHDIR" ]; then
-+	echo "/etc/multipath/ does not exist. failing"
-+	exit 1
-+fi
-+
-+rm $TMPFILE 2> /dev/null
-+echo "$DEFAULT_CONFIG" > $TMPFILE
-+if [ -f "$CONFIGFILE" ]; then
-+	cp $CONFIGFILE $TMPFILE
-+fi
-+
-+if grep -q "^blacklist[[:space:]]*{" $TMPFILE ; then
-+	HAVE_BLACKLIST=1
-+fi
-+
-+if grep -q "^blacklist_exceptions[[:space:]]*{" $TMPFILE ; then
-+	HAVE_EXCEPTIONS=1
-+fi
-+
-+if grep -q "^defaults[[:space:]]*{" $TMPFILE ; then
-+	HAVE_DEFAULTS=1
-+fi
-+
-+if [ -z "$MODULE" -o "$MODULE" = "y" ]; then
-+	if lsmod | grep -q "dm_multipath" ; then
-+		HAVE_MODULE=1
-+	else
-+		HAVE_MODULE=0
-+	fi
-+fi
-+
-+if [ "$MULTIPATHD" = "y" ]; then
-+	if /bin/systemctl status multipathd.service > /dev/null 2>&1 ; then
-+		HAVE_MULTIPATHD=1
-+	else
-+		HAVE_MULTIPATHD=0
-+	fi
-+fi
-+
-+if [ "$HAVE_BLACKLIST" = "1" ]; then
-+	if sed -n '/^blacklist[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*devnode \"\.\?\*\"" ; then
-+		HAVE_DISABLE=1
-+	elif sed -n '/^blacklist[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*#[[:space:]]*devnode \"\.\?\*\"" ; then
-+		HAVE_DISABLE=0
-+	fi
-+fi
-+
-+if [ "$HAVE_BLACKLIST" = "1" ]; then
-+	if sed -n '/^blacklist[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*wwid \"\.\?\*\"" ; then
-+		HAVE_WWID_DISABLE=1
-+	elif sed -n '/^blacklist[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*#[[:space:]]*wwid \"\.\?\*\"" ; then
-+		HAVE_WWID_DISABLE=0
-+	fi
-+fi
-+
-+if [ "$HAVE_DEFAULTS" = "1" ]; then
-+	if sed -n '/^defaults[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*find_multipaths[[:space:]]*\(yes\|1\)" ; then
-+		HAVE_FIND=1
-+	elif sed -n '/^defaults[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*find_multipaths[[:space:]]*\(no\|0\)" ; then
-+		HAVE_FIND=0
-+	fi
-+	if sed -n '/^defaults[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*user_friendly_names[[:space:]]*\(yes\|1\)" ; then
-+		HAVE_FRIENDLY=1
-+	elif sed -n '/^defaults[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*user_friendly_names[[:space:]]*\(no\|0\)" ; then
-+		HAVE_FRIENDLY=0
-+	fi
-+fi
-+
-+if [ -n "$SHOW_STATUS" ]; then
-+	if [ -z "$HAVE_DISABLE" -o "$HAVE_DISABLE" = 0 ]; then
-+		echo "multipath is enabled"
-+	else
-+		echo "multipath is disabled"
-+	fi
-+	if [ -z "$HAVE_FIND"  -o "$HAVE_FIND" = 0 ]; then
-+		echo "find_multipaths is disabled"
-+	else
-+		echo "find_multipaths is enabled"
-+	fi
-+	if [ -z "$HAVE_FRIENDLY" -o "$HAVE_FRIENDLY" = 0 ]; then
-+		echo "user_friendly_names is disabled"
-+	else
-+		echo "user_friendly_names is enabled"
-+	fi
-+	if [ -n "$HAVE_MODULE" ]; then
-+		if [ "$HAVE_MODULE" = 1 ]; then
-+			echo "dm_multipath module is loaded"
-+		else
-+			echo "dm_multipath module is not loaded"
-+		fi
-+	fi
-+	if [ -z "$HAVE_MULTIPATHD" ]; then
-+		if /bin/systemctl status multipathd.service > /dev/null 2>&1 ; then
-+			HAVE_MULTIPATHD=1
-+		else
-+			HAVE_MULTIPATHD=0
-+		fi
-+	fi
-+	if [ "$HAVE_MULTIPATHD" = 1 ]; then
-+		echo "multipathd is running"
-+	else
-+		echo "multipathd is not running"
-+	fi
-+	exit 0
-+fi
-+
-+if [ -z "$HAVE_BLACKLIST" ]; then
-+	cat >> $TMPFILE <<- _EOF_
-+
-+blacklist {
-+}
-+_EOF_
-+fi
-+
-+if [ -z "$HAVE_DEFAULTS" ]; then
-+	cat >> $TMPFILE <<- _EOF_
-+
-+defaults {
-+}
-+_EOF_
-+fi
-+
-+if [ "$ENABLE" = 2 ]; then
-+	if [ "$HAVE_DISABLE" = 1 ]; then
-+		sed -i '/^blacklist[[:space:]]*{/,/^}/ s/^[[:space:]]*devnode \"\.\?\*\"/#	devnode ".*"/' $TMPFILE
-+	fi
-+	if [ -z "$HAVE_WWID_DISABLE" ]; then
-+		sed -i '/^blacklist[[:space:]]*{/ a\
-+	wwid ".*"
-+' $TMPFILE
-+	elif [ "$HAVE_WWID_DISABLE" = 0 ]; then
-+		sed -i '/^blacklist[[:space:]]*{/,/^}/ s/^[[:space:]]*#[[:space:]]*wwid \"\.\?\*\"/	wwid ".*"/' $TMPFILE
-+	fi
-+	if [ "$HAVE_EXCEPTIONS" = 1 ]; then
-+		sed -i '/^blacklist_exceptions[[:space:]]*{/,/^}/ {/^[[:space:]]*wwid/ d}' $TMPFILE
-+	else
-+		cat >> $TMPFILE <<- _EOF_
-+
-+blacklist_exceptions {
-+}
-+_EOF_
-+	fi
-+	add_blacklist_exceptions
-+elif [ "$ENABLE" = 1 ]; then
-+	if [ "$HAVE_DISABLE" = 1 ]; then
-+		sed -i '/^blacklist[[:space:]]*{/,/^}/ s/^[[:space:]]*devnode \"\.\?\*\"/#	devnode ".*"/' $TMPFILE
-+	fi
-+elif [ "$ENABLE" = 0 ]; then
-+	if [ -z "$HAVE_DISABLE" ]; then
-+		sed -i '/^blacklist[[:space:]]*{/ a\
-+	devnode ".*"
-+' $TMPFILE
-+	elif [ "$HAVE_DISABLE" = 0 ]; then
-+		sed -i '/^blacklist[[:space:]]*{/,/^}/ s/^[[:space:]]*#[[:space:]]*devnode \"\.\?\*\"/	devnode ".*"/' $TMPFILE
-+	fi
-+fi
-+
-+if [ "$FIND" = "n" ]; then
-+	if [ "$HAVE_FIND" = 1 ]; then
-+		sed -i '/^defaults[[:space:]]*{/,/^}/ s/^[[:space:]]*find_multipaths[[:space:]]*\(yes\|1\)/	find_multipaths no/' $TMPFILE
-+		CHANGED_CONFIG=1
-+	fi
-+elif [ "$FIND" = "y" ]; then
-+	if [ -z "$HAVE_FIND" ]; then
-+		sed -i '/^defaults[[:space:]]*{/ a\
-+	find_multipaths yes
-+' $TMPFILE
-+		CHANGED_CONFIG=1
-+	elif [ "$HAVE_FIND" = 0 ]; then
-+		sed -i '/^defaults[[:space:]]*{/,/^}/ s/^[[:space:]]*find_multipaths[[:space:]]*\(no\|0\)/	find_multipaths yes/' $TMPFILE
-+		CHANGED_CONFIG=1
-+	fi
-+fi
-+
-+if [ "$FRIENDLY" = "n" ]; then
-+	if [ "$HAVE_FRIENDLY" = 1 ]; then
-+		sed -i '/^defaults[[:space:]]*{/,/^}/ s/^[[:space:]]*user_friendly_names[[:space:]]*\(yes\|1\)/	user_friendly_names no/' $TMPFILE
-+		CHANGED_CONFIG=1
-+	fi
-+elif [ "$FRIENDLY" = "y" ]; then
-+	if [ -z "$HAVE_FRIENDLY" ]; then
-+		sed -i '/^defaults[[:space:]]*{/ a\
-+	user_friendly_names yes
-+' $TMPFILE
-+		CHANGED_CONFIG=1
-+	elif [ "$HAVE_FRIENDLY" = 0 ]; then
-+		sed -i '/^defaults[[:space:]]*{/,/^}/ s/^[[:space:]]*user_friendly_names[[:space:]]*\(no\|0\)/	user_friendly_names yes/' $TMPFILE
-+		CHANGED_CONFIG=1
-+	fi
-+fi
-+
-+if [ -f "$OUTPUTFILE" ]; then
-+	cp $OUTPUTFILE $OUTPUTFILE.old
-+	if [ $? != 0 ]; then
-+		echo "failed to backup old config file, $OUTPUTFILE not updated"
-+		exit 1
-+	fi
-+fi
-+
-+cp $TMPFILE $OUTPUTFILE
-+if [ $? != 0 ]; then
-+	echo "failed to copy new config file into place, check $OUTPUTFILE is still OK"
-+	exit 1
-+fi
-+
-+rm -f $TMPFILE
-+
-+if [ "$ENABLE" = 1 ]; then
-+	if [ "$HAVE_MODULE" = 0 ]; then
-+		modprobe dm_multipath
-+	fi
-+	if [ "$HAVE_MULTIPATHD" = 0 ]; then
-+		systemctl start multipathd.service
-+	fi
-+elif [ "$ENABLE" = 0 ]; then
-+	if [ "$HAVE_MULTIPATHD" = 1 ]; then
-+		systemctl stop multipathd.service
-+	fi
-+elif [ -n "$CHANGED_CONFIG" -a "$HAVE_MULTIPATHD" = 1 ]; then
-+	systemctl reload multipathd.service
-+fi
-diff --git a/multipath/mpathconf.8 b/multipath/mpathconf.8
-new file mode 100644
-index 0000000..4cd3267
---- /dev/null
-+++ b/multipath/mpathconf.8
-@@ -0,0 +1,101 @@
-+.TH MPATHCONF 8 "June 2010" "" "Linux Administrator's Manual"
-+.SH NAME
-+mpathconf - A tool for configuring device-mapper-multipath
-+.SH SYNOPSIS
-+.B mpathconf
-+.RB [\| commands \|]
-+.RB [\| options \|]
-+.SH DESCRIPTION
-+.B mpathconf
-+is a utility that creates or modifies
-+.B /etc/multipath.conf.
-+It can enable or disable multipathing and configure some common options.
-+.B mpathconf
-+can also load the
-+.B dm_multipath
-+module, start and stop the
-+.B multipathd
-+daemon, and configure the
-+.B multipathd
-+service to start automatically or not. If
-+.B mpathconf
-+is called with no commands, it will display the current configuration.
-+
-+The default options for mpathconf are
-+.B --with_module
-+The
-+.B --with_multipathd
-+option is not set by default.  Enabling multipathing will load the
-+.B dm_multipath
-+module but it will not immediately start it. This is so
-+that users can manually edit their config file if necessary, before starting
-+.B multipathd.
-+
-+If
-+.B /etc/multipath.conf
-+already exists, mpathconf will edit it. If it does not exist, mpathconf will
-+create a default file with
-+.B user_friendly_names
-+and
-+.B find_multipaths
-+set. To disable these, use the
-+.B --user_friendly_names n
-+and
-+.B --find_multipaths n
-+options
-+.SH COMMANDS
-+.TP
-+.B --enable
-+Removes any line that blacklists all device nodes from the
-+.B /etc/multipath.conf
-+blacklist section.
-+.TP
-+.B --disable
-+Adds a line that blacklists all device nodes to the
-+.B /etc/multipath.conf
-+blacklist section. If no blacklist section exists, it will create one.
-+.TP
-+.B --user_friendly_name \fP { \fBy\fP | \fBn\fP }
-+If set to \fBy\fP, this adds the line
-+.B user_friendly_names yes
-+to the
-+.B /etc/multipath.conf
-+defaults section. If set to \fBn\fP, this removes the line, if present. This
-+command can be used along with any other command.
-+.TP
-+.B --find_multipaths\fP { \fBy\fP | \fBn\fP }
-+If set to \fBy\fP, this adds the line
-+.B find_multipaths yes
-+to the
-+.B /etc/multipath.conf
-+defaults section. If set to \fBn\fP, this removes the line, if present. This
-+command can be used aldong with any other command.
-+.SH OPTIONS
-+.TP
-+.B --with_module\fP { \fBy\fP | \fBn\fP }
-+If set to \fBy\fP, this runs
-+.B modprobe dm_multipath
-+to install the multipath modules. This option only works with the
-+.B --enable
-+command. This option is set to \fBy\fP by default.
-+.TP
-+.B --with_multipathd { \fBy\fP | \fBn\fP }
-+If set to \fBy\fP, this runs
-+.B service multipathd start
-+to start the multipathd daemon on \fB--enable\fP,
-+.B service multipathd stop
-+to stop the multipathd daemon on \fB--disable\fP, and
-+.B service multipathd reload
-+to reconfigure multipathd on \fB--user_frindly_names\fP and
-+\fB--find_multipaths\fP.
-+This option is set to \fBn\fP by default.
-+.SH FILES
-+.BR /etc/multipath.conf
-+.SH "SEE ALSO"
-+.BR multipath.conf (5),
-+.BR modprobe (8),
-+.BR multipath (8),
-+.BR multipathd (8),
-+.BR service (8),
-+.SH AUTHOR
-+Benjamin Marzinski <bmarzins@redhat.com>
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0005-multipath-tools-Remove-trailing-leading-whitespaces-.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0005-multipath-tools-Remove-trailing-leading-whitespaces-.patch
new file mode 100644
index 0000000..953e739
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0005-multipath-tools-Remove-trailing-leading-whitespaces-.patch
@@ -0,0 +1,156 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Date: Fri, 11 May 2018 15:43:11 +0200
+Subject: [PATCH] multipath-tools: Remove trailing/leading whitespaces and
+ reformat code
+
+Cc: Christophe Varoqui <christophe.varoqui@opensvc.com>
+Cc: device-mapper development <dm-devel@redhat.com>
+Signed-off-by: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ Makefile.inc           | 23 +++++++++++------------
+ kpartx/mac.h           |  2 +-
+ kpartx/test-kpartx     |  2 +-
+ libmpathcmd/Makefile   |  2 +-
+ libmultipath/hwtable.c | 14 +++++++-------
+ libmultipath/print.h   |  2 +-
+ multipathd/main.h      |  6 +++---
+ 7 files changed, 25 insertions(+), 26 deletions(-)
+
+diff --git a/Makefile.inc b/Makefile.inc
+index 57a1835..af2f5ba 100644
+--- a/Makefile.inc
++++ b/Makefile.inc
+@@ -103,21 +103,20 @@ LDFLAGS		= -Wl,-z,relro -Wl,-z,now
+ BIN_LDFLAGS	= -pie
+ 
+ # Check whether a function with name $1 has been declared in header file $2.
+-check_func =								       \
+-    $(shell								       \
++check_func = $(shell \
+ 	if grep -Eq "^[^[:blank:]]+[[:blank:]]+$1[[:blank:]]*(.*)*" "$2"; then \
+-	   found=1;							       \
+-	   status="yes";						       \
+-	else								       \
+-	   found=0;							       \
+-	   status="no";							       \
+-	fi;								       \
+-	echo 1>&2 "Checking for $1 in $2 ... $$status";			       \
+-	echo "$$found"							       \
+-    )
++		found=1; \
++		status="yes"; \
++	else \
++		found=0; \
++		status="no"; \
++	fi; \
++	echo 1>&2 "Checking for $1 in $2 ... $$status"; \
++	echo "$$found" \
++	)
+ 
+ # Checker whether a file with name $1 exists
+-check_file = $(shell	\
++check_file = $(shell \
+ 	if [ -f "$1" ]; then \
+ 		found=1; \
+ 		status="yes"; \
+diff --git a/kpartx/mac.h b/kpartx/mac.h
+index a44cf38..55c3ec9 100644
+--- a/kpartx/mac.h
++++ b/kpartx/mac.h
+@@ -24,7 +24,7 @@ struct mac_driver_desc {
+ 	uint16_t  signature;      /* expected to be MAC_DRIVER_MAGIC */
+ 	uint16_t  block_size;
+ 	uint32_t  block_count;
+-    /* ... more stuff */
++	/* ... more stuff */
+ };
+ 
+ #endif
+diff --git a/kpartx/test-kpartx b/kpartx/test-kpartx
+index 9cee20f..d2001dc 100755
+--- a/kpartx/test-kpartx
++++ b/kpartx/test-kpartx
+@@ -131,7 +131,7 @@ step "create DM devices (spans)"
+ # They also serve as DM devices to test partition removal on those.
+ 
+ TABLE="\
+-0 $((SIZE/SECTSIZ-OFFS)) linear $DEV1 $OFFS 
++0 $((SIZE/SECTSIZ-OFFS)) linear $DEV1 $OFFS
+ $((SIZE/SECTSIZ-OFFS)) $((SIZE/SECTSIZ-OFFS)) linear $DEV2 $OFFS"
+ 
+ SPAN1=kpt
+diff --git a/libmpathcmd/Makefile b/libmpathcmd/Makefile
+index 53c0899..0f6b816 100644
+--- a/libmpathcmd/Makefile
++++ b/libmpathcmd/Makefile
+@@ -27,7 +27,7 @@ uninstall:
+ 	$(RM) $(DESTDIR)$(includedir)/mpath_cmd.h
+ 
+ clean: dep_clean
+-	$(RM) core *.a *.o *.so *.so.* *.gz 
++	$(RM) core *.a *.o *.so *.so.* *.gz
+ 
+ include $(wildcard $(OBJS:.o=.d))
+ 
+diff --git a/libmultipath/hwtable.c b/libmultipath/hwtable.c
+index 827e899..2ca6888 100644
+--- a/libmultipath/hwtable.c
++++ b/libmultipath/hwtable.c
+@@ -78,13 +78,13 @@
+ #endif
+ 
+ static struct hwentry default_hw[] = {
+-       /*
+-	* Generic NVMe
+-	*
+-	* Due to the parsing logic in find_hwe(), generic entries
+-	* have to be put on top of this list, and more specific ones
+-	* below.
+-	*/
++	/*
++	 * Generic NVMe devices
++	 *
++	 * Due to the parsing logic in find_hwe(), generic entries
++	 * have to be put on top of this list, and more specific ones
++	 * below.
++	 */
+ 	{
+ 		.vendor        = "NVME",
+ 		.product       = ".*",
+diff --git a/libmultipath/print.h b/libmultipath/print.h
+index 7ba6438..9b5a23a 100644
+--- a/libmultipath/print.h
++++ b/libmultipath/print.h
+@@ -113,7 +113,7 @@ int _snprint_multipath (const struct gen_multipath *, char *, int,
+ 			const char *, int);
+ #define snprint_multipath(buf, len, fmt, mp, v)				\
+ 	_snprint_multipath(dm_multipath_to_gen(mp), buf, len, fmt,  v)
+-int _snprint_multipath_topology (const struct gen_multipath *, char *, int, 
++int _snprint_multipath_topology (const struct gen_multipath *, char *, int,
+ 				 int verbosity);
+ #define snprint_multipath_topology(buf, len, mpp, v) \
+ 	_snprint_multipath_topology (dm_multipath_to_gen(mpp), buf, len, v)
+diff --git a/multipathd/main.h b/multipathd/main.h
+index af39558..8fd426b 100644
+--- a/multipathd/main.h
++++ b/multipathd/main.h
+@@ -29,11 +29,11 @@ int ev_remove_map (char *, char *, int, struct vectors *);
+ int set_config_state(enum daemon_status);
+ void * mpath_alloc_prin_response(int prin_sa);
+ int prin_do_scsi_ioctl(char *, int rq_servact, struct prin_resp * resp,
+-       int noisy);
++		       int noisy);
+ void dumpHex(const char * , int len, int no_ascii);
+ int prout_do_scsi_ioctl(char * , int rq_servact, int rq_scope,
+-       unsigned int rq_type, struct prout_param_descriptor *param,
+-       int noisy);
++			unsigned int rq_type,
++			struct prout_param_descriptor *param, int noisy);
+ int mpath_pr_event_handle(struct path *pp);
+ void * mpath_pr_event_handler_fn (void * );
+ int update_map_pr(struct multipath *mpp);
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0006-RH-add-wwids-from-kernel-cmdline-mpath.wwids-with-A.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0006-RH-add-wwids-from-kernel-cmdline-mpath.wwids-with-A.patch
deleted file mode 100644
index dc291b8..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0006-RH-add-wwids-from-kernel-cmdline-mpath.wwids-with-A.patch
+++ /dev/null
@@ -1,166 +0,0 @@
-From 15179c830521d8f37f9254ebc6bbf150a409f956 Mon Sep 17 00:00:00 2001
-From: Benjamin Marzinski <bmarzins@redhat.com>
-Date: Fri, 17 Oct 2014 11:20:34 -0500
-Subject: [PATCH 06/14] RH: add wwids from kernel cmdline mpath.wwids with -A
-
-This patch adds another option to multipath, "-A", which reads
-/proc/cmdline for mpath.wwid=<WWID> options, and adds any wwids it finds
-to /etc/multipath/wwids.  While this isn't usually important during
-normal operation, since these wwids should already be added, it can be
-helpful during installation, to make sure that multipath can claim
-devices as its own, before LVM or something else makes use of them.  The
-patch also execs "/sbin/multipath -A" before running multipathd in
-multipathd.service
-
-Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
----
- libmultipath/wwids.c          | 44 +++++++++++++++++++++++++++++++++++++++++++
- libmultipath/wwids.h          |  1 +
- multipath/main.c              | 10 ++++++++--
- multipath/multipath.8         |  5 ++++-
- multipathd/multipathd.service |  1 +
- 5 files changed, 58 insertions(+), 3 deletions(-)
-
-diff --git a/libmultipath/wwids.c b/libmultipath/wwids.c
-index bc70a27..88bb72b 100644
---- a/libmultipath/wwids.c
-+++ b/libmultipath/wwids.c
-@@ -321,3 +321,47 @@ remember_wwid(char *wwid)
- 		condlog(4, "wwid %s already in wwids file", wwid);
- 	return 0;
- }
-+
-+int remember_cmdline_wwid(void)
-+{
-+	FILE *f = NULL;
-+	char buf[LINE_MAX], *next, *ptr;
-+	int ret = 0;
-+
-+	f = fopen("/proc/cmdline", "re");
-+	if (!f) {
-+		condlog(0, "can't open /proc/cmdline : %s", strerror(errno));
-+		return -1;
-+	}
-+
-+	if (!fgets(buf, sizeof(buf), f)) {
-+		if (ferror(f))
-+			condlog(0, "read of /proc/cmdline failed : %s",
-+				strerror(errno));
-+		else
-+			condlog(0, "couldn't read /proc/cmdline");
-+		fclose(f);
-+		return -1;
-+	}
-+	fclose(f);
-+	next = buf;
-+	while((ptr = strstr(next, "mpath.wwid="))) {
-+		ptr += 11;
-+		next = strpbrk(ptr, " \t\n");
-+		if (next) {
-+			*next = '\0';
-+			next++;
-+		}
-+		if (strlen(ptr)) {
-+			if (remember_wwid(ptr) != 0)
-+				ret = -1;
-+		}
-+		else {
-+			condlog(0, "empty mpath.wwid kernel command line option");
-+			ret = -1;
-+		}
-+		if (!next)
-+			break;
-+	}
-+	return ret;
-+}
-diff --git a/libmultipath/wwids.h b/libmultipath/wwids.h
-index 9527012..b665232 100644
---- a/libmultipath/wwids.h
-+++ b/libmultipath/wwids.h
-@@ -17,5 +17,6 @@ int remember_wwid(char *wwid);
- int check_wwids_file(char *wwid, int write_wwid);
- int remove_wwid(char *wwid);
- int replace_wwids(vector mp);
-+int remember_cmdline_wwid(void);
- 
- #endif /* _WWIDS_H */
-diff --git a/multipath/main.c b/multipath/main.c
-index 4174d43..72585b0 100644
---- a/multipath/main.c
-+++ b/multipath/main.c
-@@ -102,7 +102,7 @@ usage (char * progname)
- {
- 	fprintf (stderr, VERSION_STRING);
- 	fprintf (stderr, "Usage:\n");
--	fprintf (stderr, "  %s [-a|-c|-w|-W] [-d] [-r] [-i] [-v lvl] [-p pol] [-b fil] [-q] [dev]\n", progname);
-+	fprintf (stderr, "  %s [-a|-A|-c|-w|-W] [-d] [-r] [-i] [-v lvl] [-p pol] [-b fil] [-q] [dev]\n", progname);
- 	fprintf (stderr, "  %s -l|-ll|-f [-v lvl] [-b fil] [-R num] [dev]\n", progname);
- 	fprintf (stderr, "  %s -F [-v lvl] [-R num]\n", progname);
- 	fprintf (stderr, "  %s -t\n", progname);
-@@ -116,6 +116,8 @@ usage (char * progname)
- 		"  -f      flush a multipath device map\n"
- 		"  -F      flush all multipath device maps\n"
- 		"  -a      add a device wwid to the wwids file\n"
-+		"  -A      add devices from kernel command line mpath.wwids\n"
-+		"          parameters to wwids file\n"
- 		"  -c      check if a device should be a path in a multipath device\n"
- 		"  -q      allow queue_if_no_path when multipathd is not running\n"
- 		"  -d      dry run, do not create or update devmaps\n"
-@@ -522,7 +524,7 @@ main (int argc, char *argv[])
- 		exit(1);
- 	multipath_conf = conf;
- 	conf->retrigger_tries = 0;
--	while ((arg = getopt(argc, argv, ":adchl::FfM:v:p:b:BrR:itquwW")) != EOF ) {
-+	while ((arg = getopt(argc, argv, ":aAdchl::FfM:v:p:b:BrR:itquwW")) != EOF ) {
- 		switch(arg) {
- 		case 1: printf("optarg : %s\n",optarg);
- 			break;
-@@ -586,6 +588,10 @@ main (int argc, char *argv[])
- 		case 't':
- 			r = dump_config(conf);
- 			goto out_free_config;
-+		case 'A':
-+			if (remember_cmdline_wwid() != 0)
-+				exit(1);
-+			exit(0);
- 		case 'h':
- 			usage(argv[0]);
- 			exit(0);
-diff --git a/multipath/multipath.8 b/multipath/multipath.8
-index b9436e5..b9ad6b1 100644
---- a/multipath/multipath.8
-+++ b/multipath/multipath.8
-@@ -25,7 +25,7 @@ multipath \- Device mapper target autoconfig.
- .RB [\| \-b\ \c
- .IR bindings_file \|]
- .RB [\| \-d \|]
--.RB [\| \-h | \-l | \-ll | \-f | \-t | \-F | \-B | \-c | \-q | \|-r | \|-i | \-a | \|-u | \-w | \-W \|]
-+.RB [\| \-h | \-l | \-ll | \-f | \-t | \-F | \-B | \-c | \-q | \|-r | \|-i | \-a | \-A | \-u | \-w | \-W \|]
- .RB [\| \-p\ \c
- .IR failover | multibus | group_by_serial | group_by_prio | group_by_node_name \|]
- .RB [\| \-R\ \c
-@@ -122,6 +122,9 @@ Add the WWID for the specified device to the WWIDs file.
- Check if the device specified in the program environment should be
- a path in a multipath device.
- .
-+.B \-A
-+add wwids from any kernel command line mpath.wwid parameters to the wwids file
-+.
- .TP
- .B \-w
- Remove the WWID for the specified device from the WWIDs file.
-diff --git a/multipathd/multipathd.service b/multipathd/multipathd.service
-index fafd088..a623a3f 100644
---- a/multipathd/multipathd.service
-+++ b/multipathd/multipathd.service
-@@ -15,6 +15,7 @@ Type=notify
- NotifyAccess=main
- LimitCORE=infinity
- ExecStartPre=-/sbin/modprobe -a scsi_dh_alua scsi_dh_emc scsi_dh_rdac dm-multipath
-+ExecStartPre=-/sbin/multipath -A
- ExecStart=/sbin/multipathd -d -s
- ExecReload=/sbin/multipathd reconfigure
- 
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0006-multipath-tools-fix-compilation-with-musl-libc.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0006-multipath-tools-fix-compilation-with-musl-libc.patch
new file mode 100644
index 0000000..c6fd5b4
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0006-multipath-tools-fix-compilation-with-musl-libc.patch
@@ -0,0 +1,58 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Date: Fri, 11 May 2018 18:39:44 +0200
+Subject: [PATCH] multipath-tools: fix compilation with musl libc
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+In file included from alias.c:15:
+file.h:9:47: error: unknown type name ‘mode_t’; did you mean ‘time_t’?
+ int ensure_directories_exist(const char *str, mode_t dir_mode);
+                                               ^~~~~~
+                                               time_t
+
+sysfs.c: In function ‘sysfs_is_multipathed’:
+sysfs.c:304:15: error: ‘PATH_MAX’ undeclared (first use in this function); did you mean ‘PATH_UP’?
+  char pathbuf[PATH_MAX];
+               ^~~~~~~~
+               PATH_UP
+
+Cc: Martin Wilck <mwilck@suse.com>
+Cc: Christophe Varoqui <christophe.varoqui@opensvc.com>
+Cc: DM ML <dm-devel@redhat.com>
+Signed-off-by: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/file.h  | 2 ++
+ libmultipath/sysfs.c | 1 +
+ 2 files changed, 3 insertions(+)
+
+diff --git a/libmultipath/file.h b/libmultipath/file.h
+index 29520c7..3c75c90 100644
+--- a/libmultipath/file.h
++++ b/libmultipath/file.h
+@@ -5,6 +5,8 @@
+ #ifndef _FILE_H
+ #define _FILE_H
+ 
++#include <sys/stat.h>
++
+ #define FILE_TIMEOUT 30
+ int ensure_directories_exist(const char *str, mode_t dir_mode);
+ int open_file(const char *file, int *can_write, const char *header);
+diff --git a/libmultipath/sysfs.c b/libmultipath/sysfs.c
+index ee72e6a..16e0a73 100644
+--- a/libmultipath/sysfs.c
++++ b/libmultipath/sysfs.c
+@@ -28,6 +28,7 @@
+ #include <dirent.h>
+ #include <libudev.h>
+ #include <fnmatch.h>
++#include <limits.h>
+ 
+ #include "checkers.h"
+ #include "vector.h"
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0007-RH-trigger-change-uevent-on-new-device-creation.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0007-RH-trigger-change-uevent-on-new-device-creation.patch
deleted file mode 100644
index 025a351..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0007-RH-trigger-change-uevent-on-new-device-creation.patch
+++ /dev/null
@@ -1,138 +0,0 @@
-From 0d2c9afbd89d79fd700f9c99aa20e5f7c7382027 Mon Sep 17 00:00:00 2001
-From: Benjamin Marzinski <bmarzins@redhat.com>
-Date: Mon, 24 Apr 2017 09:39:57 -0500
-Subject: [PATCH 07/14] RH: trigger change uevent on new device creation
-
-When multipath first sees a path device with user_friendly names
-enabled, it can't know if the device should be multipathed. This means
-that it will not claim the device in udev.  If the device is eventually
-multipathed, multipath should trigger a change uevent to update the udev
-database to claim the device.
-
-This also reverts commit 64e27ec066a001012f44550f095c93443e91d845.
-
-Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
----
- libmultipath/configure.c | 26 ++++++++++++++++++++++++--
- libmultipath/configure.h |  1 +
- libmultipath/wwids.c     |  4 ++--
- multipath/main.c         |  2 +-
- multipathd/main.c        |  7 ++-----
- 5 files changed, 30 insertions(+), 10 deletions(-)
-
-diff --git a/libmultipath/configure.c b/libmultipath/configure.c
-index bd090d9..843dd09 100644
---- a/libmultipath/configure.c
-+++ b/libmultipath/configure.c
-@@ -422,6 +422,28 @@ trigger_udev_change(const struct multipath *mpp)
- 	udev_device_unref(udd);
- }
- 
-+void
-+trigger_paths_udev_change(const struct multipath *mpp)
-+{
-+	struct pathgroup * pgp;
-+	struct path * pp;
-+	int i, j;
-+
-+	if (!mpp || !mpp->pg)
-+		return;
-+
-+	vector_foreach_slot (mpp->pg, pgp, i) {
-+		if (!pgp->paths)
-+			continue;
-+		vector_foreach_slot(pgp->paths, pp, j) {
-+			if (!pp->udev)
-+				continue;
-+			sysfs_attr_set_value(pp->udev, "uevent", "change",
-+					     strlen("change"));
-+		}
-+	}
-+}
-+
- static int
- is_mpp_known_to_udev(const struct multipath *mpp)
- {
-@@ -802,8 +824,8 @@ int domap(struct multipath *mpp, char *params, int is_daemon)
- 		 * succeeded
- 		 */
- 		mpp->force_udev_reload = 0;
--		if (mpp->action == ACT_CREATE)
--			remember_wwid(mpp->wwid);
-+		if (mpp->action == ACT_CREATE && remember_wwid(mpp->wwid) == 1)
-+			trigger_paths_udev_change(mpp);
- 		if (!is_daemon) {
- 			/* multipath client mode */
- 			dm_switchgroup(mpp->alias, mpp->bestpg);
-diff --git a/libmultipath/configure.h b/libmultipath/configure.h
-index fd7f581..253e29b 100644
---- a/libmultipath/configure.h
-+++ b/libmultipath/configure.h
-@@ -36,3 +36,4 @@ int get_refwwid (enum mpath_cmds cmd, char * dev, enum devtypes dev_type,
- 		 vector pathvec, char **wwid);
- int reload_map(struct vectors *vecs, struct multipath *mpp, int refresh, int is_daemon);
- int sysfs_get_host_adapter_name(struct path *pp, char *adapter_name);
-+void trigger_paths_udev_change(const struct multipath *mpp);
-diff --git a/libmultipath/wwids.c b/libmultipath/wwids.c
-index 88bb72b..249c6c1 100644
---- a/libmultipath/wwids.c
-+++ b/libmultipath/wwids.c
-@@ -319,7 +319,7 @@ remember_wwid(char *wwid)
- 		condlog(3, "wrote wwid %s to wwids file", wwid);
- 	else
- 		condlog(4, "wwid %s already in wwids file", wwid);
--	return 0;
-+	return ret;
- }
- 
- int remember_cmdline_wwid(void)
-@@ -353,7 +353,7 @@ int remember_cmdline_wwid(void)
- 			next++;
- 		}
- 		if (strlen(ptr)) {
--			if (remember_wwid(ptr) != 0)
-+			if (remember_wwid(ptr) < 0)
- 				ret = -1;
- 		}
- 		else {
-diff --git a/multipath/main.c b/multipath/main.c
-index 72585b0..2eda6a3 100644
---- a/multipath/main.c
-+++ b/multipath/main.c
-@@ -336,7 +336,7 @@ configure (struct config *conf, enum mpath_cmds cmd,
- 		}
- 		if (cmd == CMD_ADD_WWID) {
- 			r = remember_wwid(refwwid);
--			if (r == 0)
-+			if (r >= 0)
- 				printf("wwid '%s' added\n", refwwid);
- 			else
- 				printf("failed adding '%s' to wwids file\n",
-diff --git a/multipathd/main.c b/multipathd/main.c
-index 81c76ca..874bcce 100644
---- a/multipathd/main.c
-+++ b/multipathd/main.c
-@@ -2093,7 +2093,8 @@ configure (struct vectors * vecs, int start_waiters)
- 
- 	sync_maps_state(mpvec);
- 	vector_foreach_slot(mpvec, mpp, i){
--		remember_wwid(mpp->wwid);
-+		if (remember_wwid(mpp->wwid) == 1)
-+			trigger_paths_udev_change(mpp);
- 		update_map_pr(mpp);
- 	}
- 
-@@ -2175,10 +2176,6 @@ reconfigure (struct vectors * vecs)
- 		conf->verbosity = verbosity;
- 	if (bindings_read_only)
- 		conf->bindings_read_only = bindings_read_only;
--	if (conf->find_multipaths) {
--		condlog(2, "find_multipaths is set: -n is implied");
--		ignore_new_devs = 1;
--	}
- 	if (ignore_new_devs)
- 		conf->ignore_new_devs = ignore_new_devs;
- 	uxsock_timeout = conf->uxsock_timeout;
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0007-multipath-tools-add-x-to-doc-preclean.pl-and-split-m.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0007-multipath-tools-add-x-to-doc-preclean.pl-and-split-m.patch
new file mode 100644
index 0000000..9e608e1
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0007-multipath-tools-add-x-to-doc-preclean.pl-and-split-m.patch
@@ -0,0 +1,27 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Date: Sun, 13 May 2018 00:39:41 +0200
+Subject: [PATCH] multipath-tools: add +x to doc-preclean.pl and split-man.pl
+
+It is not strictly necessary, but it helps identify bin files.
+
+Cc: Christophe Varoqui <christophe.varoqui@opensvc.com>
+Cc: DM ML <dm-devel@redhat.com>
+Signed-off-by: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libdmmp/docs/doc-preclean.pl | 0
+ libdmmp/docs/split-man.pl    | 0
+ 2 files changed, 0 insertions(+), 0 deletions(-)
+ mode change 100644 => 100755 libdmmp/docs/doc-preclean.pl
+ mode change 100644 => 100755 libdmmp/docs/split-man.pl
+
+diff --git a/libdmmp/docs/doc-preclean.pl b/libdmmp/docs/doc-preclean.pl
+old mode 100644
+new mode 100755
+diff --git a/libdmmp/docs/split-man.pl b/libdmmp/docs/split-man.pl
+old mode 100644
+new mode 100755
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0008-libmultipath-change-how-RADOS-checker-is-enabled.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0008-libmultipath-change-how-RADOS-checker-is-enabled.patch
deleted file mode 100644
index f678809..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0008-libmultipath-change-how-RADOS-checker-is-enabled.patch
+++ /dev/null
@@ -1,56 +0,0 @@
-From 0be174dbedd861d7694b0c7799fe26be31eb32b0 Mon Sep 17 00:00:00 2001
-From: Benjamin Marzinski <bmarzins@redhat.com>
-Date: Fri, 26 May 2017 17:52:57 -0500
-Subject: [PATCH 08/14] libmultipath: change how RADOS checker is enabled
-
-Instead of making the user call "make", "make install" and "make clean"
-with ENABLE_RADOS set correctly, have the makefile check if
-/usr/include/rados/librados.h exists, just like it checks if specific
-functions exist in a file.
-
-Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
----
- Makefile.inc                   | 13 +++++++++++++
- libmultipath/checkers/Makefile |  3 ++-
- 2 files changed, 15 insertions(+), 1 deletion(-)
-
-diff --git a/Makefile.inc b/Makefile.inc
-index 2591fa9..e084fd1 100644
---- a/Makefile.inc
-+++ b/Makefile.inc
-@@ -109,5 +109,18 @@ check_func =								       \
- 	echo "$$found"							       \
-     )
- 
-+# Checker whether a file with name $1 exists
-+check_file = $(shell	\
-+	if [ -f "$1" ]; then \
-+		found=1; \
-+		status="yes"; \
-+	else \
-+		found=0; \
-+		status="no"; \
-+	fi; \
-+	echo 1>&2 "Checking if $1 exists ... $$status"; \
-+	echo "$$found" \
-+	)
-+
- %.o:	%.c
- 	$(CC) $(CFLAGS) -c -o $@ $<
-diff --git a/libmultipath/checkers/Makefile b/libmultipath/checkers/Makefile
-index 732ca9d..bce6b8b 100644
---- a/libmultipath/checkers/Makefile
-+++ b/libmultipath/checkers/Makefile
-@@ -14,7 +14,8 @@ LIBS= \
- 	libcheckemc_clariion.so \
- 	libcheckhp_sw.so \
- 	libcheckrdac.so
--ifneq ($(ENABLE_RADOS),0)
-+
-+ifneq ($(call check_file,/usr/include/rados/librados.h),0)
- LIBS += libcheckrbd.so
- endif
- 
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0008-multipath-tools-refresh-kernel-doc-from-kernel-sourc.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0008-multipath-tools-refresh-kernel-doc-from-kernel-sourc.patch
new file mode 100644
index 0000000..3752158
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0008-multipath-tools-refresh-kernel-doc-from-kernel-sourc.patch
@@ -0,0 +1,784 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Date: Sun, 13 May 2018 00:39:42 +0200
+Subject: [PATCH] multipath-tools: refresh kernel-doc from kernel sources
+
+Cc: Gris Ge <fge@redhat.com>
+Cc: Christophe Varoqui <christophe.varoqui@opensvc.com>
+Cc: device-mapper development <dm-devel@redhat.com>
+Signed-off-by: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libdmmp/docs/kernel-doc | 671 ++++++++++++++++++++++++++----------------------
+ 1 file changed, 368 insertions(+), 303 deletions(-)
+
+diff --git a/libdmmp/docs/kernel-doc b/libdmmp/docs/kernel-doc
+index fee8952..0057d8e 100755
+--- a/libdmmp/docs/kernel-doc
++++ b/libdmmp/docs/kernel-doc
+@@ -1,4 +1,5 @@
+ #!/usr/bin/env perl
++# SPDX-License-Identifier: GPL-2.0
+ 
+ use warnings;
+ use strict;
+@@ -328,13 +329,15 @@ my $lineprefix="";
+ use constant {
+     STATE_NORMAL        => 0, # normal code
+     STATE_NAME          => 1, # looking for function name
+-    STATE_FIELD         => 2, # scanning field start
+-    STATE_PROTO         => 3, # scanning prototype
+-    STATE_DOCBLOCK      => 4, # documentation block
+-    STATE_INLINE        => 5, # gathering documentation outside main block
++    STATE_BODY_MAYBE    => 2, # body - or maybe more description
++    STATE_BODY          => 3, # the body of the comment
++    STATE_PROTO         => 4, # scanning prototype
++    STATE_DOCBLOCK      => 5, # documentation block
++    STATE_INLINE        => 6, # gathering documentation outside main block
+ };
+ my $state;
+ my $in_doc_sect;
++my $leading_space;
+ 
+ # Inline documentation state
+ use constant {
+@@ -363,7 +366,7 @@ my $doc_sect = $doc_com .
+ my $doc_content = $doc_com_body . '(.*)';
+ my $doc_block = $doc_com . 'DOC:\s*(.*)?';
+ my $doc_inline_start = '^\s*/\*\*\s*$';
+-my $doc_inline_sect = '\s*\*\s*(@[\w\s]+):(.*)';
++my $doc_inline_sect = '\s*\*\s*(@\s*[\w][\w\.]*\s*):(.*)';
+ my $doc_inline_end = '^\s*\*/\s*$';
+ my $doc_inline_oneline = '^\s*/\*\*\s*(@[\w\s]+):\s*(.*)\s*\*/\s*$';
+ my $export_symbol = '^\s*EXPORT_SYMBOL(_GPL)?\s*\(\s*(\w+)\s*\)\s*;';
+@@ -553,10 +556,9 @@ sub output_highlight {
+ 	}
+ 	if ($line eq ""){
+ 	    if (! $output_preformatted) {
+-		print $lineprefix, local_unescape($blankline);
++		print $lineprefix, $blankline;
+ 	    }
+ 	} else {
+-	    $line =~ s/\\\\\\/\&/g;
+ 	    if ($output_mode eq "man" && substr($line, 0, 1) eq ".") {
+ 		print "\\&$line";
+ 	    } else {
+@@ -747,17 +749,73 @@ sub output_blockhead_rst(%) {
+     }
+ }
+ 
+-sub output_highlight_rst {
+-    my $contents = join "\n",@_;
+-    my $line;
+-
+-    # undo the evil effects of xml_escape() earlier
+-    $contents = xml_unescape($contents);
+-
++#
++# Apply the RST highlights to a sub-block of text.
++#   
++sub highlight_block($) {
++    # The dohighlight kludge requires the text be called $contents
++    my $contents = shift;
+     eval $dohighlight;
+     die $@ if $@;
++    return $contents;
++}
+ 
+-    foreach $line (split "\n", $contents) {
++#
++# Regexes used only here.
++#
++my $sphinx_literal = '^[^.].*::$';
++my $sphinx_cblock = '^\.\.\ +code-block::';
++
++sub output_highlight_rst {
++    my $input = join "\n",@_;
++    my $output = "";
++    my $line;
++    my $in_literal = 0;
++    my $litprefix;
++    my $block = "";
++
++    foreach $line (split "\n",$input) {
++	#
++	# If we're in a literal block, see if we should drop out
++	# of it.  Otherwise pass the line straight through unmunged.
++	#
++	if ($in_literal) {
++	    if (! ($line =~ /^\s*$/)) {
++		#
++		# If this is the first non-blank line in a literal
++		# block we need to figure out what the proper indent is.
++		#
++		if ($litprefix eq "") {
++		    $line =~ /^(\s*)/;
++		    $litprefix = '^' . $1;
++		    $output .= $line . "\n";
++		} elsif (! ($line =~ /$litprefix/)) {
++		    $in_literal = 0;
++		} else {
++		    $output .= $line . "\n";
++		}
++	    } else {
++		$output .= $line . "\n";
++	    }
++	}
++	#
++	# Not in a literal block (or just dropped out)
++	#
++	if (! $in_literal) {
++	    $block .= $line . "\n";
++	    if (($line =~ /$sphinx_literal/) || ($line =~ /$sphinx_cblock/)) {
++		$in_literal = 1;
++		$litprefix = "";
++		$output .= highlight_block($block);
++		$block = ""
++	    }
++	}
++    }
++
++    if ($block) {
++	$output .= highlight_block($block);
++    }
++    foreach $line (split "\n", $output) {
+ 	print $lineprefix . $line . "\n";
+     }
+ }
+@@ -1062,7 +1120,7 @@ sub dump_struct($$) {
+ 					# Handle bitmaps
+ 					$arg =~ s/:\s*\d+\s*//g;
+ 					# Handle arrays
+-					$arg =~ s/\[\S+\]//g;
++					$arg =~ s/\[.*\]//g;
+ 					# The type may have multiple words,
+ 					# and multiple IDs can be defined, like:
+ 					#	const struct foo, *bar, foobar
+@@ -1422,8 +1480,6 @@ sub push_parameter($$$$) {
+ 		}
+ 	}
+ 
+-	$param = xml_escape($param);
+-
+ 	# strip spaces from $param so that it is one continuous string
+ 	# on @parameterlist;
+ 	# this fixes a problem where check_sections() cannot find
+@@ -1522,6 +1578,7 @@ sub dump_function($$) {
+     $prototype =~ s/__meminit +//;
+     $prototype =~ s/__must_check +//;
+     $prototype =~ s/__weak +//;
++    $prototype =~ s/__sched +//;
+     my $define = $prototype =~ s/^#\s*define\s+//; #ak added
+     $prototype =~ s/__attribute__\s*\(\(
+             (?:
+@@ -1748,47 +1805,6 @@ sub process_proto_type($$) {
+     }
+ }
+ 
+-# xml_escape: replace <, >, and & in the text stream;
+-#
+-# however, formatting controls that are generated internally/locally in the
+-# kernel-doc script are not escaped here; instead, they begin life like
+-# $blankline_html (4 of '\' followed by a mnemonic + ':'), then these strings
+-# are converted to their mnemonic-expected output, without the 4 * '\' & ':',
+-# just before actual output; (this is done by local_unescape())
+-sub xml_escape($) {
+-	my $text = shift;
+-	if ($output_mode eq "man") {
+-		return $text;
+-	}
+-	$text =~ s/\&/\\\\\\amp;/g;
+-	$text =~ s/\</\\\\\\lt;/g;
+-	$text =~ s/\>/\\\\\\gt;/g;
+-	return $text;
+-}
+-
+-# xml_unescape: reverse the effects of xml_escape
+-sub xml_unescape($) {
+-	my $text = shift;
+-	if ($output_mode eq "man") {
+-		return $text;
+-	}
+-	$text =~ s/\\\\\\amp;/\&/g;
+-	$text =~ s/\\\\\\lt;/</g;
+-	$text =~ s/\\\\\\gt;/>/g;
+-	return $text;
+-}
+-
+-# convert local escape strings to html
+-# local escape strings look like:  '\\\\menmonic:' (that's 4 backslashes)
+-sub local_unescape($) {
+-	my $text = shift;
+-	if ($output_mode eq "man") {
+-		return $text;
+-	}
+-	$text =~ s/\\\\\\\\lt:/</g;
+-	$text =~ s/\\\\\\\\gt:/>/g;
+-	return $text;
+-}
+ 
+ sub map_filename($) {
+     my $file;
+@@ -1826,15 +1842,291 @@ sub process_export_file($) {
+     close(IN);
+ }
+ 
+-sub process_file($) {
+-    my $file;
++#
++# Parsers for the various processing states.
++#
++# STATE_NORMAL: looking for the /** to begin everything.
++#
++sub process_normal() {
++    if (/$doc_start/o) {
++	$state = STATE_NAME;	# next line is always the function name
++	$in_doc_sect = 0;
++	$declaration_start_line = $. + 1;
++    }
++}
++
++#
++# STATE_NAME: Looking for the "name - description" line
++#
++sub process_name($$) {
++    my $file = shift;
+     my $identifier;
+-    my $func;
+     my $descr;
+-    my $in_purpose = 0;
++
++    if (/$doc_block/o) {
++	$state = STATE_DOCBLOCK;
++	$contents = "";
++	$new_start_line = $. + 1;
++
++	if ( $1 eq "" ) {
++	    $section = $section_intro;
++	} else {
++	    $section = $1;
++	}
++    }
++    elsif (/$doc_decl/o) {
++	$identifier = $1;
++	if (/\s*([\w\s]+?)(\(\))?\s*-/) {
++	    $identifier = $1;
++	}
++
++	$state = STATE_BODY;
++	# if there's no @param blocks need to set up default section
++	# here
++	$contents = "";
++	$section = $section_default;
++	$new_start_line = $. + 1;
++	if (/-(.*)/) {
++	    # strip leading/trailing/multiple spaces
++	    $descr= $1;
++	    $descr =~ s/^\s*//;
++	    $descr =~ s/\s*$//;
++	    $descr =~ s/\s+/ /g;
++	    $declaration_purpose = $descr;
++	    $state = STATE_BODY_MAYBE;
++	} else {
++	    $declaration_purpose = "";
++	}
++
++	if (($declaration_purpose eq "") && $verbose) {
++	    print STDERR "${file}:$.: warning: missing initial short description on line:\n";
++	    print STDERR $_;
++	    ++$warnings;
++	}
++
++	if ($identifier =~ m/^struct/) {
++	    $decl_type = 'struct';
++	} elsif ($identifier =~ m/^union/) {
++	    $decl_type = 'union';
++	} elsif ($identifier =~ m/^enum/) {
++	    $decl_type = 'enum';
++	} elsif ($identifier =~ m/^typedef/) {
++	    $decl_type = 'typedef';
++	} else {
++	    $decl_type = 'function';
++	}
++
++	if ($verbose) {
++	    print STDERR "${file}:$.: info: Scanning doc for $identifier\n";
++	}
++    } else {
++	print STDERR "${file}:$.: warning: Cannot understand $_ on line $.",
++	    " - I thought it was a doc line\n";
++	++$warnings;
++	$state = STATE_NORMAL;
++    }
++}
++
++
++#
++# STATE_BODY and STATE_BODY_MAYBE: the bulk of a kerneldoc comment.
++#
++sub process_body($$) {
++    my $file = shift;
++
++    if (/$doc_sect/i) { # case insensitive for supported section names
++	$newsection = $1;
++	$newcontents = $2;
++
++	# map the supported section names to the canonical names
++	if ($newsection =~ m/^description$/i) {
++	    $newsection = $section_default;
++	} elsif ($newsection =~ m/^context$/i) {
++	    $newsection = $section_context;
++	} elsif ($newsection =~ m/^returns?$/i) {
++	    $newsection = $section_return;
++	} elsif ($newsection =~ m/^\@return$/) {
++	    # special: @return is a section, not a param description
++	    $newsection = $section_return;
++	}
++
++	if (($contents ne "") && ($contents ne "\n")) {
++	    if (!$in_doc_sect && $verbose) {
++		print STDERR "${file}:$.: warning: contents before sections\n";
++		++$warnings;
++	    }
++	    dump_section($file, $section, $contents);
++	    $section = $section_default;
++	}
++
++	$in_doc_sect = 1;
++	$state = STATE_BODY;
++	$contents = $newcontents;
++	$new_start_line = $.;
++	while (substr($contents, 0, 1) eq " ") {
++	    $contents = substr($contents, 1);
++	}
++	if ($contents ne "") {
++	    $contents .= "\n";
++	}
++	$section = $newsection;
++	$leading_space = undef;
++    } elsif (/$doc_end/) {
++	if (($contents ne "") && ($contents ne "\n")) {
++	    dump_section($file, $section, $contents);
++	    $section = $section_default;
++	    $contents = "";
++	}
++	# look for doc_com + <text> + doc_end:
++	if ($_ =~ m'\s*\*\s*[a-zA-Z_0-9:\.]+\*/') {
++	    print STDERR "${file}:$.: warning: suspicious ending line: $_";
++	    ++$warnings;
++	}
++
++	$prototype = "";
++	$state = STATE_PROTO;
++	$brcount = 0;
++    } elsif (/$doc_content/) {
++	# miguel-style comment kludge, look for blank lines after
++	# @parameter line to signify start of description
++	if ($1 eq "") {
++	    if ($section =~ m/^@/ || $section eq $section_context) {
++		dump_section($file, $section, $contents);
++		$section = $section_default;
++		$contents = "";
++		$new_start_line = $.;
++	    } else {
++		$contents .= "\n";
++	    }
++	    $state = STATE_BODY;
++	} elsif ($state == STATE_BODY_MAYBE) {
++	    # Continued declaration purpose
++	    chomp($declaration_purpose);
++	    $declaration_purpose .= " " . $1;
++	    $declaration_purpose =~ s/\s+/ /g;
++	} else {
++	    my $cont = $1;
++	    if ($section =~ m/^@/ || $section eq $section_context) {
++		if (!defined $leading_space) {
++		    if ($cont =~ m/^(\s+)/) {
++			$leading_space = $1;
++		    } else {
++			$leading_space = "";
++		    }
++		}
++		$cont =~ s/^$leading_space//;
++	    }
++	    $contents .= $cont . "\n";
++	}
++    } else {
++	# i dont know - bad line?  ignore.
++	print STDERR "${file}:$.: warning: bad line: $_";
++	++$warnings;
++    }
++}
++
++
++#
++# STATE_PROTO: reading a function/whatever prototype.
++#
++sub process_proto($$) {
++    my $file = shift;
++
++    if (/$doc_inline_oneline/) {
++	$section = $1;
++	$contents = $2;
++	if ($contents ne "") {
++	    $contents .= "\n";
++	    dump_section($file, $section, $contents);
++	    $section = $section_default;
++	    $contents = "";
++	}
++    } elsif (/$doc_inline_start/) {
++	$state = STATE_INLINE;
++	$inline_doc_state = STATE_INLINE_NAME;
++    } elsif ($decl_type eq 'function') {
++	process_proto_function($_, $file);
++    } else {
++	process_proto_type($_, $file);
++    }
++}
++
++#
++# STATE_DOCBLOCK: within a DOC: block.
++#
++sub process_docblock($$) {
++    my $file = shift;
++
++    if (/$doc_end/) {
++	dump_doc_section($file, $section, $contents);
++	$section = $section_default;
++	$contents = "";
++	$function = "";
++	%parameterdescs = ();
++	%parametertypes = ();
++	@parameterlist = ();
++	%sections = ();
++	@sectionlist = ();
++	$prototype = "";
++	$state = STATE_NORMAL;
++    } elsif (/$doc_content/) {
++	if ( $1 eq "" )	{
++	    $contents .= $blankline;
++	} else {
++	    $contents .= $1 . "\n";
++	}
++    }
++}
++
++#
++# STATE_INLINE: docbook comments within a prototype.
++#
++sub process_inline($$) {
++    my $file = shift;
++
++    # First line (state 1) needs to be a @parameter
++    if ($inline_doc_state == STATE_INLINE_NAME && /$doc_inline_sect/o) {
++	$section = $1;
++	$contents = $2;
++	$new_start_line = $.;
++	if ($contents ne "") {
++	    while (substr($contents, 0, 1) eq " ") {
++		$contents = substr($contents, 1);
++	    }
++	    $contents .= "\n";
++	}
++	$inline_doc_state = STATE_INLINE_TEXT;
++	# Documentation block end */
++    } elsif (/$doc_inline_end/) {
++	if (($contents ne "") && ($contents ne "\n")) {
++	    dump_section($file, $section, $contents);
++	    $section = $section_default;
++	    $contents = "";
++	}
++	$state = STATE_PROTO;
++	$inline_doc_state = STATE_INLINE_NA;
++	# Regular text
++    } elsif (/$doc_content/) {
++	if ($inline_doc_state == STATE_INLINE_TEXT) {
++	    $contents .= $1 . "\n";
++	    # nuke leading blank lines
++	    if ($contents =~ /^\s*$/) {
++		$contents = "";
++	    }
++	} elsif ($inline_doc_state == STATE_INLINE_NAME) {
++	    $inline_doc_state = STATE_INLINE_ERROR;
++	    print STDERR "${file}:$.: warning: ";
++	    print STDERR "Incorrect use of kernel-doc format: $_";
++	    ++$warnings;
++	}
++    }
++}
++
++
++sub process_file($) {
++    my $file;
+     my $initial_section_counter = $section_counter;
+     my ($orig_file) = @_;
+-    my $leading_space;
+ 
+     $file = map_filename($orig_file);
+ 
+@@ -1853,250 +2145,23 @@ sub process_file($) {
+ 	}
+ 	# Replace tabs by spaces
+         while ($_ =~ s/\t+/' ' x (length($&) * 8 - length($`) % 8)/e) {};
++	# Hand this line to the appropriate state handler
+ 	if ($state == STATE_NORMAL) {
+-	    if (/$doc_start/o) {
+-		$state = STATE_NAME;	# next line is always the function name
+-		$in_doc_sect = 0;
+-		$declaration_start_line = $. + 1;
+-	    }
+-	} elsif ($state == STATE_NAME) {# this line is the function name (always)
+-	    if (/$doc_block/o) {
+-		$state = STATE_DOCBLOCK;
+-		$contents = "";
+-                $new_start_line = $. + 1;
+-
+-		if ( $1 eq "" ) {
+-			$section = $section_intro;
+-		} else {
+-			$section = $1;
+-		}
+-	    }
+-	    elsif (/$doc_decl/o) {
+-		$identifier = $1;
+-		if (/\s*([\w\s]+?)\s*-/) {
+-		    $identifier = $1;
+-		}
+-
+-		$state = STATE_FIELD;
+-		# if there's no @param blocks need to set up default section
+-		# here
+-		$contents = "";
+-		$section = $section_default;
+-		$new_start_line = $. + 1;
+-		if (/-(.*)/) {
+-		    # strip leading/trailing/multiple spaces
+-		    $descr= $1;
+-		    $descr =~ s/^\s*//;
+-		    $descr =~ s/\s*$//;
+-		    $descr =~ s/\s+/ /g;
+-		    $declaration_purpose = xml_escape($descr);
+-		    $in_purpose = 1;
+-		} else {
+-		    $declaration_purpose = "";
+-		}
+-
+-		if (($declaration_purpose eq "") && $verbose) {
+-			print STDERR "${file}:$.: warning: missing initial short description on line:\n";
+-			print STDERR $_;
+-			++$warnings;
+-		}
+-
+-		if ($identifier =~ m/^struct/) {
+-		    $decl_type = 'struct';
+-		} elsif ($identifier =~ m/^union/) {
+-		    $decl_type = 'union';
+-		} elsif ($identifier =~ m/^enum/) {
+-		    $decl_type = 'enum';
+-		} elsif ($identifier =~ m/^typedef/) {
+-		    $decl_type = 'typedef';
+-		} else {
+-		    $decl_type = 'function';
+-		}
+-
+-		if ($verbose) {
+-		    print STDERR "${file}:$.: info: Scanning doc for $identifier\n";
+-		}
+-	    } else {
+-		print STDERR "${file}:$.: warning: Cannot understand $_ on line $.",
+-		" - I thought it was a doc line\n";
+-		++$warnings;
+-		$state = STATE_NORMAL;
+-	    }
+-	} elsif ($state == STATE_FIELD) {	# look for head: lines, and include content
+-	    if (/$doc_sect/i) { # case insensitive for supported section names
+-		$newsection = $1;
+-		$newcontents = $2;
+-
+-		# map the supported section names to the canonical names
+-		if ($newsection =~ m/^description$/i) {
+-		    $newsection = $section_default;
+-		} elsif ($newsection =~ m/^context$/i) {
+-		    $newsection = $section_context;
+-		} elsif ($newsection =~ m/^returns?$/i) {
+-		    $newsection = $section_return;
+-		} elsif ($newsection =~ m/^\@return$/) {
+-		    # special: @return is a section, not a param description
+-		    $newsection = $section_return;
+-		}
+-
+-		if (($contents ne "") && ($contents ne "\n")) {
+-		    if (!$in_doc_sect && $verbose) {
+-			print STDERR "${file}:$.: warning: contents before sections\n";
+-			++$warnings;
+-		    }
+-		    dump_section($file, $section, xml_escape($contents));
+-		    $section = $section_default;
+-		}
+-
+-		$in_doc_sect = 1;
+-		$in_purpose = 0;
+-		$contents = $newcontents;
+-                $new_start_line = $.;
+-		while (substr($contents, 0, 1) eq " ") {
+-		    $contents = substr($contents, 1);
+-		}
+-		if ($contents ne "") {
+-		    $contents .= "\n";
+-		}
+-		$section = $newsection;
+-		$leading_space = undef;
+-	    } elsif (/$doc_end/) {
+-		if (($contents ne "") && ($contents ne "\n")) {
+-		    dump_section($file, $section, xml_escape($contents));
+-		    $section = $section_default;
+-		    $contents = "";
+-		}
+-		# look for doc_com + <text> + doc_end:
+-		if ($_ =~ m'\s*\*\s*[a-zA-Z_0-9:\.]+\*/') {
+-		    print STDERR "${file}:$.: warning: suspicious ending line: $_";
+-		    ++$warnings;
+-		}
+-
+-		$prototype = "";
+-		$state = STATE_PROTO;
+-		$brcount = 0;
+-#		print STDERR "end of doc comment, looking for prototype\n";
+-	    } elsif (/$doc_content/) {
+-		# miguel-style comment kludge, look for blank lines after
+-		# @parameter line to signify start of description
+-		if ($1 eq "") {
+-		    if ($section =~ m/^@/ || $section eq $section_context) {
+-			dump_section($file, $section, xml_escape($contents));
+-			$section = $section_default;
+-			$contents = "";
+-                        $new_start_line = $.;
+-		    } else {
+-			$contents .= "\n";
+-		    }
+-		    $in_purpose = 0;
+-		} elsif ($in_purpose == 1) {
+-		    # Continued declaration purpose
+-		    chomp($declaration_purpose);
+-		    $declaration_purpose .= " " . xml_escape($1);
+-		    $declaration_purpose =~ s/\s+/ /g;
+-		} else {
+-		    my $cont = $1;
+-		    if ($section =~ m/^@/ || $section eq $section_context) {
+-			if (!defined $leading_space) {
+-			    if ($cont =~ m/^(\s+)/) {
+-				$leading_space = $1;
+-			    } else {
+-				$leading_space = "";
+-			    }
+-			}
+-
+-			$cont =~ s/^$leading_space//;
+-		    }
+-		    $contents .= $cont . "\n";
+-		}
+-	    } else {
+-		# i dont know - bad line?  ignore.
+-		print STDERR "${file}:$.: warning: bad line: $_";
+-		++$warnings;
+-	    }
++	    process_normal();
++	} elsif ($state == STATE_NAME) {
++	    process_name($file, $_);
++	} elsif ($state == STATE_BODY || $state == STATE_BODY_MAYBE) {
++	    process_body($file, $_);
+ 	} elsif ($state == STATE_INLINE) { # scanning for inline parameters
+-	    # First line (state 1) needs to be a @parameter
+-	    if ($inline_doc_state == STATE_INLINE_NAME && /$doc_inline_sect/o) {
+-		$section = $1;
+-		$contents = $2;
+-                $new_start_line = $.;
+-		if ($contents ne "") {
+-		    while (substr($contents, 0, 1) eq " ") {
+-			$contents = substr($contents, 1);
+-		    }
+-		    $contents .= "\n";
+-		}
+-		$inline_doc_state = STATE_INLINE_TEXT;
+-	    # Documentation block end */
+-	    } elsif (/$doc_inline_end/) {
+-		if (($contents ne "") && ($contents ne "\n")) {
+-		    dump_section($file, $section, xml_escape($contents));
+-		    $section = $section_default;
+-		    $contents = "";
+-		}
+-		$state = STATE_PROTO;
+-		$inline_doc_state = STATE_INLINE_NA;
+-	    # Regular text
+-	    } elsif (/$doc_content/) {
+-		if ($inline_doc_state == STATE_INLINE_TEXT) {
+-		    $contents .= $1 . "\n";
+-		    # nuke leading blank lines
+-		    if ($contents =~ /^\s*$/) {
+-			$contents = "";
+-		    }
+-		} elsif ($inline_doc_state == STATE_INLINE_NAME) {
+-		    $inline_doc_state = STATE_INLINE_ERROR;
+-		    print STDERR "${file}:$.: warning: ";
+-		    print STDERR "Incorrect use of kernel-doc format: $_";
+-		    ++$warnings;
+-		}
+-	    }
+-	} elsif ($state == STATE_PROTO) {	# scanning for function '{' (end of prototype)
+-	    if (/$doc_inline_oneline/) {
+-		$section = $1;
+-		$contents = $2;
+-		if ($contents ne "") {
+-		    $contents .= "\n";
+-		    dump_section($file, $section, xml_escape($contents));
+-		    $section = $section_default;
+-		    $contents = "";
+-		}
+-	    } elsif (/$doc_inline_start/) {
+-		$state = STATE_INLINE;
+-		$inline_doc_state = STATE_INLINE_NAME;
+-	    } elsif ($decl_type eq 'function') {
+-		process_proto_function($_, $file);
+-	    } else {
+-		process_proto_type($_, $file);
+-	    }
++	    process_inline($file, $_);
++	} elsif ($state == STATE_PROTO) {
++	    process_proto($file, $_);
+ 	} elsif ($state == STATE_DOCBLOCK) {
+-		if (/$doc_end/)
+-		{
+-			dump_doc_section($file, $section, xml_escape($contents));
+-			$section = $section_default;
+-			$contents = "";
+-			$function = "";
+-			%parameterdescs = ();
+-			%parametertypes = ();
+-			@parameterlist = ();
+-			%sections = ();
+-			@sectionlist = ();
+-			$prototype = "";
+-			$state = STATE_NORMAL;
+-		}
+-		elsif (/$doc_content/)
+-		{
+-			if ( $1 eq "" )
+-			{
+-				$contents .= $blankline;
+-			}
+-			else
+-			{
+-				$contents .= $1 . "\n";
+-			}
+-		}
++	    process_docblock($file, $_);
+ 	}
+     }
++
++    # Make sure we got something interesting.
+     if ($initial_section_counter == $section_counter) {
+ 	if ($output_mode ne "none") {
+ 	    print STDERR "${file}:1: warning: no structured comments found\n";
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0009-multipath-set-verbosity-to-default-during-config.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0009-multipath-set-verbosity-to-default-during-config.patch
deleted file mode 100644
index 17d2d91..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0009-multipath-set-verbosity-to-default-during-config.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From 526e539628e051128abf46a60ec22e18c9b5d84f Mon Sep 17 00:00:00 2001
-From: Benjamin Marzinski <bmarzins@redhat.com>
-Date: Wed, 31 May 2017 15:03:02 -0500
-Subject: [PATCH 09/14] multipath: set verbosity to default during config
-
-condlog was setting the verbosity to 0 if there was no configuration.
-This keeps multipath from printing warning messages about config file
-problems that are found while loading the configuration. Instead, it
-should use the default config level until it loads the configuration
-to find the current value.
-
-Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
----
- libmultipath/debug.c | 3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
-diff --git a/libmultipath/debug.c b/libmultipath/debug.c
-index fbe171a..f89b264 100644
---- a/libmultipath/debug.c
-+++ b/libmultipath/debug.c
-@@ -11,6 +11,7 @@
- #include "../third-party/valgrind/drd.h"
- #include "vector.h"
- #include "config.h"
-+#include "defaults.h"
- 
- void dlog (int sink, int prio, const char * fmt, ...)
- {
-@@ -21,7 +22,7 @@ void dlog (int sink, int prio, const char * fmt, ...)
- 	va_start(ap, fmt);
- 	conf = get_multipath_config();
- 	ANNOTATE_IGNORE_READS_BEGIN();
--	thres = (conf) ? conf->verbosity : 0;
-+	thres = (conf) ? conf->verbosity : DEFAULT_VERBOSITY;
- 	ANNOTATE_IGNORE_READS_END();
- 	put_multipath_config(conf);
- 
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0009-multipath-tools-configure-hitachi-ams2000-and-hus100.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0009-multipath-tools-configure-hitachi-ams2000-and-hus100.patch
new file mode 100644
index 0000000..2cae075
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0009-multipath-tools-configure-hitachi-ams2000-and-hus100.patch
@@ -0,0 +1,56 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Date: Mon, 14 May 2018 17:30:17 +0200
+Subject: [PATCH] multipath-tools: configure hitachi ams2000 and hus100 as full
+ active arrays
+
+AMS2000 and HUS100 families are active/active arrays.
+
+Based on https://support.hitachivantara.com/download/epcra/df818913.pdf
+and internal hitachi docs.
+
+Cc: Matthias Rudolph <Matthias.Rudolph@hitachivantara.com>
+Cc: Christophe Varoqui <christophe.varoqui@opensvc.com>
+Cc: DM-DEV ML <dm-devel@redhat.com>
+Signed-off-by: Xose Vazquez Perez <xose.vazquez@gmail.com>
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/hwtable.c | 10 ++++++++--
+ 1 file changed, 8 insertions(+), 2 deletions(-)
+
+diff --git a/libmultipath/hwtable.c b/libmultipath/hwtable.c
+index 2ca6888..148f0ba 100644
+--- a/libmultipath/hwtable.c
++++ b/libmultipath/hwtable.c
+@@ -398,13 +398,13 @@ static struct hwentry default_hw[] = {
+ 	 * Mail : matthias.rudolph@hds.com
+ 	 */
+ 	{
+-		/* USP-V, HUS VM, VSP, VSP G1X00 and VSP GX00 families */
++		/* USP-V, HUS VM, VSP, VSP G1X00 and VSP GX00 families / HP XP */
+ 		.vendor        = "(HITACHI|HP)",
+ 		.product       = "^OPEN-",
+ 		.pgpolicy      = MULTIBUS,
+ 	},
+ 	{
+-		/* AMS 2000 and HUS 100 families */
++		/* AMS other than AMS 2000 */
+ 		.vendor        = "HITACHI",
+ 		.product       = "^DF",
+ 		.no_path_retry = NO_PATH_RETRY_QUEUE,
+@@ -412,6 +412,12 @@ static struct hwentry default_hw[] = {
+ 		.pgfailback    = -FAILBACK_IMMEDIATE,
+ 		.prio_name     = PRIO_HDS,
+ 	},
++	{
++		/* AMS 2000 and HUS 100 families */
++		.vendor        = "HITACHI",
++		.product       = "^DF600F",
++		.pgpolicy      = MULTIBUS,
++	},
+ 	/*
+ 	 * IBM
+ 	 *
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0010-libmultipath-don-t-reject-maps-with-undefined-prio.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0010-libmultipath-don-t-reject-maps-with-undefined-prio.patch
new file mode 100644
index 0000000..2dda2ed
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0010-libmultipath-don-t-reject-maps-with-undefined-prio.patch
@@ -0,0 +1,42 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Martin Wilck <mwilck@suse.com>
+Date: Wed, 21 Mar 2018 10:34:18 +0100
+Subject: [PATCH] libmultipath: don't reject maps with undefined prio
+
+libmultipath's prio routines can deal with pp->priority == PRIO_UNDEF
+just fine. PRIO_UNDEF is just a very low priority. So there's
+no reason to reject setting up a multipath map because paths have
+undefined priority.
+
+Signed-off-by: Martin Wilck <mwilck@suse.com>
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/configure.c | 5 -----
+ 1 file changed, 5 deletions(-)
+
+diff --git a/libmultipath/configure.c b/libmultipath/configure.c
+index 5796683..5c54f9b 100644
+--- a/libmultipath/configure.c
++++ b/libmultipath/configure.c
+@@ -1063,9 +1063,6 @@ int coalesce_paths (struct vectors * vecs, vector newmp, char * refwwid,
+ 			continue;
+ 		}
+ 
+-		if (pp1->priority == PRIO_UNDEF)
+-			mpp->action = ACT_REJECT;
+-
+ 		if (!mpp->paths) {
+ 			condlog(0, "%s: skip coalesce (no paths)", mpp->alias);
+ 			remove_map(mpp, vecs, 0);
+@@ -1091,8 +1088,6 @@ int coalesce_paths (struct vectors * vecs, vector newmp, char * refwwid,
+ 					mpp->size);
+ 				mpp->action = ACT_REJECT;
+ 			}
+-			if (pp2->priority == PRIO_UNDEF)
+-				mpp->action = ACT_REJECT;
+ 		}
+ 		verify_paths(mpp, vecs);
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0010-mpath-skip-device-configs-without-vendor-product.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0010-mpath-skip-device-configs-without-vendor-product.patch
deleted file mode 100644
index 396b6d3..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0010-mpath-skip-device-configs-without-vendor-product.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From f88d60a93e98d86ae294f2317a122c4efde276f0 Mon Sep 17 00:00:00 2001
-From: Benjamin Marzinski <bmarzins@redhat.com>
-Date: Wed, 31 May 2017 17:58:59 -0500
-Subject: [PATCH 10/14] mpath: skip device configs without vendor/product
-
-Right now if multipath.conf includes a device configuration without a
-vendor or product string, it will automatically be applied to all
-devices, skipping all other configs entirely.  This is clearly wrong.
-This patch makes sure that user added configs include vendor and
-product strings
-
-Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
----
- libmultipath/config.c | 7 +++++++
- 1 file changed, 7 insertions(+)
-
-diff --git a/libmultipath/config.c b/libmultipath/config.c
-index c485748..bdde113 100644
---- a/libmultipath/config.c
-+++ b/libmultipath/config.c
-@@ -452,6 +452,13 @@ restart:
- 			break;
- 		j = n;
- 		vector_foreach_slot_after(hw, hwe2, j) {
-+			/* drop invalid device configs */
-+			if (!hwe2->vendor || !hwe2->product) {
-+				condlog(0, "device config missing vendor or product parameter");
-+				vector_del_slot(hw, j--);
-+				free_hwe(hwe2);
-+				continue;
-+			}
- 			if (hwe_regmatch(hwe1, hwe2))
- 				continue;
- 			/* dup */
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0011-multipathd-fix-show-maps-json-crash.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0011-multipathd-fix-show-maps-json-crash.patch
deleted file mode 100644
index 12d6d38..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0011-multipathd-fix-show-maps-json-crash.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-From bc3ceda747104afdc24386df5dc45ca86f6c2936 Mon Sep 17 00:00:00 2001
-From: Benjamin Marzinski <bmarzins@redhat.com>
-Date: Thu, 1 Jun 2017 17:52:28 -0500
-Subject: [PATCH 11/14] multipathd: fix "show maps json" crash
-
-If there are no multipath devices, show_maps_json sets the maximum size
-of the reply buffer to 0. Having a size of 0 causes the calls to calloc
-and realloc to behave in ways that the code isn't designed to handle,
-leading to a double-free crash. Instead, show_maps_json should just
-use the INITIAL_REPLY_LEN if there are no multipath devices.
-
-Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
----
- multipathd/cli_handlers.c | 6 ++++--
- 1 file changed, 4 insertions(+), 2 deletions(-)
-
-diff --git a/multipathd/cli_handlers.c b/multipathd/cli_handlers.c
-index 04c7386..7b0d00c 100644
---- a/multipathd/cli_handlers.c
-+++ b/multipathd/cli_handlers.c
-@@ -162,10 +162,12 @@ show_maps_json (char ** r, int * len, struct vectors * vecs)
- 	struct multipath * mpp;
- 	char * c;
- 	char * reply;
--	unsigned int maxlen = INITIAL_REPLY_LEN *
--			PRINT_JSON_MULTIPLIER * VECTOR_SIZE(vecs->mpvec);
-+	unsigned int maxlen = INITIAL_REPLY_LEN;
- 	int again = 1;
- 
-+	if (VECTOR_SIZE(vecs->mpvec) > 0)
-+		maxlen *= PRINT_JSON_MULTIPLIER * VECTOR_SIZE(vecs->mpvec);
-+
- 	vector_foreach_slot(vecs->mpvec, mpp, i) {
- 		if (update_multipath(vecs, mpp->alias, 0)) {
- 			return 1;
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0011-multipathd-handle-errors-in-uxlsnr-as-fatal.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0011-multipathd-handle-errors-in-uxlsnr-as-fatal.patch
new file mode 100644
index 0000000..96a814f
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0011-multipathd-handle-errors-in-uxlsnr-as-fatal.patch
@@ -0,0 +1,57 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Martin Wilck <mwilck@suse.com>
+Date: Wed, 21 Mar 2018 10:34:19 +0100
+Subject: [PATCH] multipathd: handle errors in uxlsnr as fatal
+
+The ppoll() calls of the uxlsnr thread are vital for proper functioning of
+multipathd. If the uxlsnr thread can't open the socket or fails to call ppoll()
+for other reasons, quit the daemon. If we don't do that, multipathd may
+hang in a state where it can't be terminated any more, because the uxlsnr
+thread is responsible for handling all signals. This happens e.g. if
+systemd's multipathd.socket is running in and multipathd is started from
+outside systemd.
+
+24f2844 "multipathd: fix signal blocking logic" has made this problem more
+severe. Before that patch, the signals weren't actually blocked in any thread.
+That's not to say 24f2844 was wrong. I still think it's correct, we just
+need this one on top.
+
+Signed-off-by: Martin Wilck <mwilck@suse.com>
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ multipathd/uxlsnr.c | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/multipathd/uxlsnr.c b/multipathd/uxlsnr.c
+index cdafd82..6f66666 100644
+--- a/multipathd/uxlsnr.c
++++ b/multipathd/uxlsnr.c
+@@ -178,7 +178,7 @@ void * uxsock_listen(uxsock_trigger_fn uxsock_trigger, void * trigger_data)
+ 
+ 	if (ux_sock == -1) {
+ 		condlog(1, "could not create uxsock: %d", errno);
+-		return NULL;
++		exit_daemon();
+ 	}
+ 
+ 	pthread_cleanup_push(uxsock_cleanup, (void *)ux_sock);
+@@ -187,7 +187,7 @@ void * uxsock_listen(uxsock_trigger_fn uxsock_trigger, void * trigger_data)
+ 	polls = (struct pollfd *)MALLOC((MIN_POLLS + 1) * sizeof(struct pollfd));
+ 	if (!polls) {
+ 		condlog(0, "uxsock: failed to allocate poll fds");
+-		return NULL;
++		exit_daemon();
+ 	}
+ 	sigfillset(&mask);
+ 	sigdelset(&mask, SIGINT);
+@@ -249,6 +249,7 @@ void * uxsock_listen(uxsock_trigger_fn uxsock_trigger, void * trigger_data)
+ 
+ 			/* something went badly wrong! */
+ 			condlog(0, "uxsock: poll failed with %d", errno);
++			exit_daemon();
+ 			break;
+ 		}
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0012-libmultipath-fix-error-parsing-find_multipaths-stric.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0012-libmultipath-fix-error-parsing-find_multipaths-stric.patch
new file mode 100644
index 0000000..8ce2431
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0012-libmultipath-fix-error-parsing-find_multipaths-stric.patch
@@ -0,0 +1,36 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Martin Wilck <mwilck@suse.com>
+Date: Tue, 15 May 2018 14:32:44 +0200
+Subject: [PATCH] libmultipath: fix error parsing "find_multipaths strict"
+
+If "find_multipaths strict" is set in multipath.conf, the error message
+"illegal value for find_multipaths: strict" is printed. This causes no
+functional problem, as "strict" happens to be the default, fallback
+value. It should be fixed nonetheless. FIND_MULTIPATHS_STRICT, having
+the highest numeric value, must be last in the enum.
+
+Fixes: c36f2f42 "libmultipath: change find_multipaths option to multi-value"
+Signed-off-by: Martin Wilck <mwilck@suse.com>
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/structs.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/libmultipath/structs.h b/libmultipath/structs.h
+index eb6a178..e424b15 100644
+--- a/libmultipath/structs.h
++++ b/libmultipath/structs.h
+@@ -122,9 +122,9 @@ enum find_multipaths_states {
+ 	FIND_MULTIPATHS_UNDEF = YNU_UNDEF,
+ 	FIND_MULTIPATHS_OFF = YNU_NO,
+ 	FIND_MULTIPATHS_ON = _FIND_MULTIPATHS_F,
+-	FIND_MULTIPATHS_STRICT = _FIND_MULTIPATHS_F|_FIND_MULTIPATHS_N,
+ 	FIND_MULTIPATHS_GREEDY = _FIND_MULTIPATHS_I,
+ 	FIND_MULTIPATHS_SMART = _FIND_MULTIPATHS_F|_FIND_MULTIPATHS_I,
++	FIND_MULTIPATHS_STRICT = _FIND_MULTIPATHS_F|_FIND_MULTIPATHS_N,
+ 	__FIND_MULTIPATHS_LAST,
+ };
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0012-multipath-tools-modify-Makefile.inc-for-cross-compil.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0012-multipath-tools-modify-Makefile.inc-for-cross-compil.patch
deleted file mode 100644
index 5ccd4ae..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0012-multipath-tools-modify-Makefile.inc-for-cross-compil.patch
+++ /dev/null
@@ -1,58 +0,0 @@
-From 6864ba28dec61609662ce5dc8bc7ed1925abb546 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Wed, 5 Jul 2017 02:56:13 -0400
-Subject: [PATCH 12/14] multipath-tools: modify Makefile.inc for
- cross-compilation
-
-Do not look for systemd info on the host, and allow us to pass in CFLAGS
-using the OPTFLAGS variable.
-
-Upstream-Status: Inappropriate [embedded specific]
-
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
-
-Update for version 0.5.0-144-g770e6d0
-
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
-
-Update for version 0.7.1
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- Makefile.inc | 8 ++------
- 1 file changed, 2 insertions(+), 6 deletions(-)
-
-diff --git a/Makefile.inc b/Makefile.inc
-index e084fd1..c7f45fa 100644
---- a/Makefile.inc
-+++ b/Makefile.inc
-@@ -35,12 +35,6 @@ ifndef RUN
- 	endif
- endif
- 
--ifndef SYSTEMD
--	ifeq ($(shell systemctl --version > /dev/null 2>&1 && echo 1), 1)
--		SYSTEMD = $(shell systemctl --version 2> /dev/null |  sed -n 's/systemd \([0-9]*\)/\1/p')
--	endif
--endif
--
- ifndef SYSTEMDPATH
- 	SYSTEMDPATH=usr/lib
- endif
-@@ -82,11 +76,13 @@ TEST_CC_OPTION = $(shell \
- 
- STACKPROT := $(call TEST_CC_OPTION,-fstack-protector-strong,-fstack-protector)
- 
-+ifndef OPTFLAGS
- OPTFLAGS	= -O2 -g -pipe -Wall -Wextra -Wformat=2 -Werror=implicit-int \
- 		  -Werror=implicit-function-declaration -Werror=format-security \
- 		  -Wno-sign-compare -Wno-unused-parameter -Wno-clobbered \
- 		  -Wp,-D_FORTIFY_SOURCE=2 $(STACKPROT) \
- 		  --param=ssp-buffer-size=4
-+endif
- 
- CFLAGS		= $(OPTFLAGS) -DLIB_STRING=\"${LIB}\" -DRUN_DIR=\"${RUN}\"
- BIN_CFLAGS	= -fPIE -DPIE
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0013-Always-use-devmapper.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0013-Always-use-devmapper.patch
deleted file mode 100644
index 52240f6..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0013-Always-use-devmapper.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-From 1498338970a093fccbda3e33f5588a289ef2c66a Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Wed, 5 Jul 2017 02:59:46 -0400
-Subject: [PATCH 13/14] Always use devmapper
-
-Do not try to compute several _API_ make variables
-from host information when cross-compiling.
-
-Upstream-Status: Inappropriate [embedded specific]
-
-Signed-off-by: Aws Ismail <aws.ismail@windriver.com>
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
-
-Rebase to 0.7.1
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- libmultipath/Makefile | 19 ++++---------------
- 1 file changed, 4 insertions(+), 15 deletions(-)
-
-diff --git a/libmultipath/Makefile b/libmultipath/Makefile
-index b3244fc..9006b3f 100644
---- a/libmultipath/Makefile
-+++ b/libmultipath/Makefile
-@@ -20,21 +20,10 @@ ifdef SYSTEMD
- 	endif
- endif
- 
--ifneq ($(call check_func,dm_task_no_flush,/usr/include/libdevmapper.h),0)
--	CFLAGS += -DLIBDM_API_FLUSH -D_GNU_SOURCE
--endif
--
--ifneq ($(call check_func,dm_task_set_cookie,/usr/include/libdevmapper.h),0)
--	CFLAGS += -DLIBDM_API_COOKIE
--endif
--
--ifneq ($(call check_func,udev_monitor_set_receive_buffer_size,/usr/include/libudev.h),0)
--	CFLAGS += -DLIBUDEV_API_RECVBUF
--endif
--
--ifneq ($(call check_func,dm_task_deferred_remove,/usr/include/libdevmapper.h),0)
--	CFLAGS += -DLIBDM_API_DEFERRED
--endif
-+CFLAGS += -DLIBDM_API_FLUSH -D_GNU_SOURCE
-+CFLAGS += -DLIBDM_API_COOKIE
-+CFLAGS += -DLIBUDEV_API_RECVBUF
-+CFLAGS += -DLIBDM_API_DEFERRED
- 
- OBJS = memory.o parser.o vector.o devmapper.o callout.o \
- 	hwtable.o blacklist.o util.o dmparser.o config.o \
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0013-libmultipath-print-correct-default-for-delay_-_check.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0013-libmultipath-print-correct-default-for-delay_-_check.patch
new file mode 100644
index 0000000..c767804
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0013-libmultipath-print-correct-default-for-delay_-_check.patch
@@ -0,0 +1,40 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Mon, 7 May 2018 17:16:05 -0500
+Subject: [PATCH] libmultipath: print correct default for delay_*_checks
+
+These options default to "no", so they should display that when the
+config is printed.
+
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/dict.c | 6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/libmultipath/dict.c b/libmultipath/dict.c
+index 4040611..3e7c5d6 100644
+--- a/libmultipath/dict.c
++++ b/libmultipath/dict.c
+@@ -1115,7 +1115,8 @@ print_off_int_undef(char * buff, int len, long v)
+ }
+ 
+ declare_def_handler(delay_watch_checks, set_off_int_undef)
+-declare_def_snprint(delay_watch_checks, print_off_int_undef)
++declare_def_snprint_defint(delay_watch_checks, print_off_int_undef,
++			   DEFAULT_DELAY_CHECKS)
+ declare_ovr_handler(delay_watch_checks, set_off_int_undef)
+ declare_ovr_snprint(delay_watch_checks, print_off_int_undef)
+ declare_hw_handler(delay_watch_checks, set_off_int_undef)
+@@ -1123,7 +1124,8 @@ declare_hw_snprint(delay_watch_checks, print_off_int_undef)
+ declare_mp_handler(delay_watch_checks, set_off_int_undef)
+ declare_mp_snprint(delay_watch_checks, print_off_int_undef)
+ declare_def_handler(delay_wait_checks, set_off_int_undef)
+-declare_def_snprint(delay_wait_checks, print_off_int_undef)
++declare_def_snprint_defint(delay_wait_checks, print_off_int_undef,
++			   DEFAULT_DELAY_CHECKS)
+ declare_ovr_handler(delay_wait_checks, set_off_int_undef)
+ declare_ovr_snprint(delay_wait_checks, print_off_int_undef)
+ declare_hw_handler(delay_wait_checks, set_off_int_undef)
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0014-Always-use-devmapper-for-kpartx.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0014-Always-use-devmapper-for-kpartx.patch
deleted file mode 100644
index f951213..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0014-Always-use-devmapper-for-kpartx.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From 7f5869cd32a7b3f717d9544b35562d9d01ca6510 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Wed, 5 Jul 2017 03:03:16 -0400
-Subject: [PATCH 14/14] Always use devmapper for kpartx
-
-Do not try to compute the LIBDM_API_COOKIE make variable
-from host information when cross-compiling.
-
-Upstream-Status: Inappropriate [embedded specific]
-
-Signed-off-by: Aws Ismail <aws.ismail@windriver.com>
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
-
-Rebase to 0.7.1
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- kpartx/Makefile | 4 +---
- 1 file changed, 1 insertion(+), 3 deletions(-)
-
-diff --git a/kpartx/Makefile b/kpartx/Makefile
-index bfa6fe8..be87124 100644
---- a/kpartx/Makefile
-+++ b/kpartx/Makefile
-@@ -8,9 +8,7 @@ LDFLAGS += $(BIN_LDFLAGS)
- 
- LIBDEPS += -ldevmapper
- 
--ifneq ($(call check_func,dm_task_set_cookie,/usr/include/libdevmapper.h),0)
--	CFLAGS += -DLIBDM_API_COOKIE
--endif
-+CFLAGS += -DLIBDM_API_COOKIE
- 
- OBJS = bsd.o dos.o kpartx.o solaris.o unixware.o dasd.o sun.o \
- 	gpt.o mac.o ps3.o crc32.o lopart.o xstrncpy.o devmapper.o
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0014-multipath.conf.5-clarify-property-whitelist-handling.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0014-multipath.conf.5-clarify-property-whitelist-handling.patch
new file mode 100644
index 0000000..0ab4e06
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0014-multipath.conf.5-clarify-property-whitelist-handling.patch
@@ -0,0 +1,31 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Wed, 9 May 2018 14:32:59 -0500
+Subject: [PATCH] multipath.conf.5: clarify property whitelist handling
+
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ multipath/multipath.conf.5 | 7 +++----
+ 1 file changed, 3 insertions(+), 4 deletions(-)
+
+diff --git a/multipath/multipath.conf.5 b/multipath/multipath.conf.5
+index f689795..96d1b66 100644
+--- a/multipath/multipath.conf.5
++++ b/multipath/multipath.conf.5
+@@ -1181,10 +1181,9 @@ and
+ keywords. For a full description of these keywords please see the \fIdevices\fR
+ section description.
+ .LP
+-The \fIproperty\fR blacklist and whitelist handling is different from the usual
+-handling in the sense that the whitelist \fIhas\fR to be set, otherwise the
+-device will be blacklisted. In these cases the message \fIblacklisted, udev
+-property missing\fR will be displayed.
++The \fIproperty\fR whitelist handling is different from the usual
++handling in the sense that the device \fIhas\fR to have a udev property that
++matches the whitelist, otherwise the device will be blacklisted. In these cases the message \fIblacklisted, udev property missing\fR will be displayed.
+ .
+ .
+ .\" ----------------------------------------------------------------------------
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0015-mpathpersist-add-all_tg_pt-option.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0015-mpathpersist-add-all_tg_pt-option.patch
new file mode 100644
index 0000000..be2681d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0015-mpathpersist-add-all_tg_pt-option.patch
@@ -0,0 +1,317 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Thu, 31 May 2018 17:47:11 -0500
+Subject: [PATCH] mpathpersist: add all_tg_pt option
+
+Some arrays, such as the EMC VNX, don't follow the scsi persistent
+reservations spec in making key registrations per I_T NEXUS. Instead,
+the registration is shared by all target ports connected to a given
+host.  This causes mpathpersist to fail whenever it tries to register a
+key, since it will receive a registration conflict on some of the paths.
+
+To deal with this, mpathpersist needs to track the hosts that it has
+done a registration on, and only register once per host. The new
+"all_tg_pt" multipath.conf option is used to set which arrays need this
+feature.  I currently don't know if all EMC VNX arrays handle persistent
+reservations like this, or if it is configurable. A future patch will
+update the VNX built-in config, if this is indeed their default (or
+only) setting.
+
+Multipathd doesn't need to worry about this. It is often the case that
+when a path device comes back, it will still have the keys registered to
+it. Because of this, multipathd uses register-and-ignore, which means
+that it won't cause an error if the registration has already happened
+down a different target port.
+
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmpathpersist/mpath_persist.c | 28 ++++++++++++++++++++++------
+ libmultipath/config.c           |  2 ++
+ libmultipath/config.h           |  2 ++
+ libmultipath/defaults.h         |  1 +
+ libmultipath/dict.c             | 10 ++++++++++
+ libmultipath/propsel.c          | 15 +++++++++++++++
+ libmultipath/propsel.h          |  1 +
+ libmultipath/structs.h          |  7 +++++++
+ multipath/multipath.conf.5      | 11 +++++++++++
+ 9 files changed, 71 insertions(+), 6 deletions(-)
+
+diff --git a/libmpathpersist/mpath_persist.c b/libmpathpersist/mpath_persist.c
+index 907a17c..ca91c55 100644
+--- a/libmpathpersist/mpath_persist.c
++++ b/libmpathpersist/mpath_persist.c
+@@ -335,6 +335,7 @@ int mpath_persistent_reserve_out ( int fd, int rq_servact, int rq_scope,
+ 
+ 	conf = get_multipath_config();
+ 	select_reservation_key(conf, mpp);
++	select_all_tg_pt(conf, mpp);
+ 	put_multipath_config(conf);
+ 
+ 	memcpy(&prkey, paramp->sa_key, 8);
+@@ -456,7 +457,7 @@ int mpath_prout_reg(struct multipath *mpp,int rq_servact, int rq_scope,
+ 	unsigned int rq_type, struct prout_param_descriptor * paramp, int noisy)
+ {
+ 
+-	int i, j;
++	int i, j, k;
+ 	struct pathgroup *pgp = NULL;
+ 	struct path *pp = NULL;
+ 	int rollback = 0;
+@@ -481,11 +482,13 @@ int mpath_prout_reg(struct multipath *mpp,int rq_servact, int rq_scope,
+ 	}
+ 
+ 	struct threadinfo thread[active_pathcount];
++	int hosts[active_pathcount];
+ 
+ 	memset(thread, 0, sizeof(thread));
+ 
+ 	/* init thread parameter */
+ 	for (i =0; i< active_pathcount; i++){
++		hosts[i] = -1;
+ 		thread[i].param.rq_servact = rq_servact;
+ 		thread[i].param.rq_scope = rq_scope;
+ 		thread[i].param.rq_type = rq_type;
+@@ -514,6 +517,17 @@ int mpath_prout_reg(struct multipath *mpp,int rq_servact, int rq_scope,
+ 				condlog (1, "%s: %s path not up. Skip.", mpp->wwid, pp->dev);
+ 				continue;
+ 			}
++			if (mpp->all_tg_pt == ALL_TG_PT_ON &&
++			    pp->sg_id.host_no != -1) {
++				for (k = 0; k < count; k++) {
++					if (pp->sg_id.host_no == hosts[k]) {
++						condlog(3, "%s: %s host %d matches skip.", pp->wwid, pp->dev, pp->sg_id.host_no);
++						break;
++					}
++				}
++				if (k < count)
++					continue;
++			}
+ 			strncpy(thread[count].param.dev, pp->dev,
+ 				FILE_NAME_SIZE - 1);
+ 
+@@ -531,10 +545,12 @@ int mpath_prout_reg(struct multipath *mpp,int rq_servact, int rq_scope,
+ 				condlog (0, "%s: failed to create thread %d", mpp->wwid, rc);
+ 				thread[count].param.status = MPATH_PR_THREAD_ERROR;
+ 			}
++			else
++				hosts[count] = pp->sg_id.host_no;
+ 			count = count + 1;
+ 		}
+ 	}
+-	for( i=0; i < active_pathcount ; i++){
++	for( i=0; i < count ; i++){
+ 		if (thread[i].param.status != MPATH_PR_THREAD_ERROR) {
+ 			rc = pthread_join(thread[i].id, NULL);
+ 			if (rc){
+@@ -557,7 +573,7 @@ int mpath_prout_reg(struct multipath *mpp,int rq_servact, int rq_scope,
+ 	}
+ 	if (rollback && ((rq_servact == MPATH_PROUT_REG_SA) && sa_key != 0 )){
+ 		condlog (3, "%s: ERROR: initiating pr out rollback", mpp->wwid);
+-		for( i=0 ; i < active_pathcount ; i++){
++		for( i=0 ; i < count ; i++){
+ 			if(thread[i].param.status == MPATH_PR_SUCCESS) {
+ 				memcpy(&thread[i].param.paramp->key, &thread[i].param.paramp->sa_key, 8);
+ 				memset(&thread[i].param.paramp->sa_key, 0, 8);
+@@ -571,7 +587,7 @@ int mpath_prout_reg(struct multipath *mpp,int rq_servact, int rq_scope,
+ 			} else
+ 				thread[i].param.status = MPATH_PR_SKIP;
+ 		}
+-		for(i=0; i < active_pathcount ; i++){
++		for(i=0; i < count ; i++){
+ 			if (thread[i].param.status != MPATH_PR_SKIP &&
+ 			    thread[i].param.status != MPATH_PR_THREAD_ERROR) {
+ 				rc = pthread_join(thread[i].id, NULL);
+@@ -720,7 +736,7 @@ int mpath_prout_rel(struct multipath *mpp,int rq_servact, int rq_scope,
+ 		}
+ 	}
+ 	pthread_attr_destroy (&attr);
+-	for (i = 0; i < active_pathcount; i++){
++	for (i = 0; i < count; i++){
+ 		if (thread[i].param.status != MPATH_PR_THREAD_ERROR) {
+ 			rc = pthread_join (thread[i].id, NULL);
+ 			if (rc){
+@@ -729,7 +745,7 @@ int mpath_prout_rel(struct multipath *mpp,int rq_servact, int rq_scope,
+ 		}
+ 	}
+ 
+-	for (i = 0; i < active_pathcount; i++){
++	for (i = 0; i < count; i++){
+ 		/*  check thread status here and return the status */
+ 
+ 		if (thread[i].param.status == MPATH_PR_RESERV_CONFLICT)
+diff --git a/libmultipath/config.c b/libmultipath/config.c
+index 085a3e1..5872927 100644
+--- a/libmultipath/config.c
++++ b/libmultipath/config.c
+@@ -352,6 +352,7 @@ merge_hwe (struct hwentry * dst, struct hwentry * src)
+ 	merge_num(skip_kpartx);
+ 	merge_num(max_sectors_kb);
+ 	merge_num(ghost_delay);
++	merge_num(all_tg_pt);
+ 
+ 	snprintf(id, sizeof(id), "%s/%s", dst->vendor, dst->product);
+ 	reconcile_features_with_options(id, &dst->features,
+@@ -622,6 +623,7 @@ load_config (char * file)
+ 	conf->disable_changed_wwids = DEFAULT_DISABLE_CHANGED_WWIDS;
+ 	conf->remove_retries = 0;
+ 	conf->ghost_delay = DEFAULT_GHOST_DELAY;
++	conf->all_tg_pt = DEFAULT_ALL_TG_PT;
+ 
+ 	/*
+ 	 * preload default hwtable
+diff --git a/libmultipath/config.h b/libmultipath/config.h
+index 6e69a37..1bf708a 100644
+--- a/libmultipath/config.h
++++ b/libmultipath/config.h
+@@ -82,6 +82,7 @@ struct hwentry {
+ 	int skip_kpartx;
+ 	int max_sectors_kb;
+ 	int ghost_delay;
++	int all_tg_pt;
+ 	char * bl_product;
+ };
+ 
+@@ -194,6 +195,7 @@ struct config {
+ 	char * partition_delim;
+ 	char * config_dir;
+ 	int prkey_source;
++	int all_tg_pt;
+ 	struct be64 reservation_key;
+ 
+ 	vector keywords;
+diff --git a/libmultipath/defaults.h b/libmultipath/defaults.h
+index d7b87b4..f076b4b 100644
+--- a/libmultipath/defaults.h
++++ b/libmultipath/defaults.h
+@@ -43,6 +43,7 @@
+ #define DEFAULT_GHOST_DELAY GHOST_DELAY_OFF
+ #define DEFAULT_FIND_MULTIPATHS_TIMEOUT -10
+ #define DEFAULT_UNKNOWN_FIND_MULTIPATHS_TIMEOUT 1
++#define DEFAULT_ALL_TG_PT ALL_TG_PT_OFF
+ 
+ #define DEFAULT_CHECKINT	5
+ #define MAX_CHECKINT(a)		(a << 2)
+diff --git a/libmultipath/dict.c b/libmultipath/dict.c
+index 3e7c5d6..2557b8a 100644
+--- a/libmultipath/dict.c
++++ b/libmultipath/dict.c
+@@ -1178,6 +1178,13 @@ declare_hw_snprint(ghost_delay, print_off_int_undef)
+ declare_mp_handler(ghost_delay, set_off_int_undef)
+ declare_mp_snprint(ghost_delay, print_off_int_undef)
+ 
++declare_def_handler(all_tg_pt, set_yes_no_undef)
++declare_def_snprint_defint(all_tg_pt, print_yes_no_undef, DEFAULT_ALL_TG_PT)
++declare_ovr_handler(all_tg_pt, set_yes_no_undef)
++declare_ovr_snprint(all_tg_pt, print_yes_no_undef)
++declare_hw_handler(all_tg_pt, set_yes_no_undef)
++declare_hw_snprint(all_tg_pt, print_yes_no_undef)
++
+ 
+ static int
+ def_uxsock_timeout_handler(struct config *conf, vector strvec)
+@@ -1509,6 +1516,7 @@ init_keywords(vector keywords)
+ 	install_keyword("prkeys_file", &def_prkeys_file_handler, &snprint_def_prkeys_file);
+ 	install_keyword("log_checker_err", &def_log_checker_err_handler, &snprint_def_log_checker_err);
+ 	install_keyword("reservation_key", &def_reservation_key_handler, &snprint_def_reservation_key);
++	install_keyword("all_tg_pt", &def_all_tg_pt_handler, &snprint_def_all_tg_pt);
+ 	install_keyword("retain_attached_hw_handler", &def_retain_hwhandler_handler, &snprint_def_retain_hwhandler);
+ 	install_keyword("detect_prio", &def_detect_prio_handler, &snprint_def_detect_prio);
+ 	install_keyword("detect_checker", &def_detect_checker_handler, &snprint_def_detect_checker);
+@@ -1618,6 +1626,7 @@ init_keywords(vector keywords)
+ 	install_keyword("skip_kpartx", &hw_skip_kpartx_handler, &snprint_hw_skip_kpartx);
+ 	install_keyword("max_sectors_kb", &hw_max_sectors_kb_handler, &snprint_hw_max_sectors_kb);
+ 	install_keyword("ghost_delay", &hw_ghost_delay_handler, &snprint_hw_ghost_delay);
++	install_keyword("all_tg_pt", &hw_all_tg_pt_handler, &snprint_hw_all_tg_pt);
+ 	install_sublevel_end();
+ 
+ 	install_keyword_root("overrides", &overrides_handler);
+@@ -1654,6 +1663,7 @@ init_keywords(vector keywords)
+ 	install_keyword("skip_kpartx", &ovr_skip_kpartx_handler, &snprint_ovr_skip_kpartx);
+ 	install_keyword("max_sectors_kb", &ovr_max_sectors_kb_handler, &snprint_ovr_max_sectors_kb);
+ 	install_keyword("ghost_delay", &ovr_ghost_delay_handler, &snprint_ovr_ghost_delay);
++	install_keyword("all_tg_pt", &ovr_all_tg_pt_handler, &snprint_ovr_all_tg_pt);
+ 
+ 	install_keyword_root("multipaths", &multipaths_handler);
+ 	install_keyword_multi("multipath", &multipath_handler, NULL);
+diff --git a/libmultipath/propsel.c b/libmultipath/propsel.c
+index 627d366..9ca1355 100644
+--- a/libmultipath/propsel.c
++++ b/libmultipath/propsel.c
+@@ -978,3 +978,18 @@ out:
+ 		pp->dev, pp->find_multipaths_timeout, origin);
+ 	return 0;
+ }
++
++int select_all_tg_pt (struct config *conf, struct multipath * mp)
++{
++	const char *origin;
++
++	mp_set_ovr(all_tg_pt);
++	mp_set_hwe(all_tg_pt);
++	mp_set_conf(all_tg_pt);
++	mp_set_default(all_tg_pt, DEFAULT_ALL_TG_PT);
++out:
++	condlog(3, "%s: all_tg_pt = %s %s", mp->alias,
++		(mp->all_tg_pt == ALL_TG_PT_ON)? "yes" : "no",
++		origin);
++	return 0;
++}
+diff --git a/libmultipath/propsel.h b/libmultipath/propsel.h
+index a022bee..ae99b92 100644
+--- a/libmultipath/propsel.h
++++ b/libmultipath/propsel.h
+@@ -34,3 +34,4 @@ int select_ghost_delay(struct config *conf, struct multipath * mp);
+ void reconcile_features_with_options(const char *id, char **features,
+ 				     int* no_path_retry,
+ 				     int *retain_hwhandler);
++int select_all_tg_pt (struct config *conf, struct multipath * mp);
+diff --git a/libmultipath/structs.h b/libmultipath/structs.h
+index e424b15..0194b1e 100644
+--- a/libmultipath/structs.h
++++ b/libmultipath/structs.h
+@@ -217,6 +217,12 @@ enum prkey_sources {
+ 	PRKEY_SOURCE_FILE,
+ };
+ 
++enum all_tg_pt_states {
++	ALL_TG_PT_UNDEF = YNU_UNDEF,
++	ALL_TG_PT_OFF = YNU_NO,
++	ALL_TG_PT_ON = YNU_YES,
++};
++
+ struct sg_id {
+ 	int host_no;
+ 	int channel;
+@@ -362,6 +368,7 @@ struct multipath {
+ 	int prkey_source;
+ 	struct be64 reservation_key;
+ 	unsigned char prflag;
++	int all_tg_pt;
+ 	struct gen_multipath generic_mp;
+ };
+ 
+diff --git a/multipath/multipath.conf.5 b/multipath/multipath.conf.5
+index 96d1b66..0c1f174 100644
+--- a/multipath/multipath.conf.5
++++ b/multipath/multipath.conf.5
+@@ -743,6 +743,17 @@ The default is: \fB<unset>\fR
+ .
+ .
+ .TP
++.B all_tg_pt
++This must be set to \fByes\fR to successfully use mpathpersist on arrays that
++automatically set and clear registration keys on all target ports from a
++host, instead of per target port per host.
++.RS
++.TP
++The default is: \fBno\fR
++.RE
++.
++.
++.TP
+ .B retain_attached_hw_handler
+ (Obsolete for kernels >= 4.3) If set to
+ .I yes
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0016-libmultipath-remove-rbd-code.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0016-libmultipath-remove-rbd-code.patch
new file mode 100644
index 0000000..8d19547
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0016-libmultipath-remove-rbd-code.patch
@@ -0,0 +1,1093 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Fri, 1 Jun 2018 16:30:44 -0500
+Subject: [PATCH] libmultipath: remove rbd code
+
+The Ceph tean has asked to drop support for multipathed rbd, since it
+was running into data corruption issues. There was never an upstream
+Ceph release based on it, and because of the corruption, there should be
+no users of this code. This patch simply reverts all the rbd code from
+multipath.
+
+Cc: Michael Christie <mchristi@redhat.com>
+Cc: Jason Dillaman <dillaman@redhat.com>
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/checkers.c              |  22 --
+ libmultipath/checkers.h              |   6 -
+ libmultipath/checkers/Makefile       |   7 -
+ libmultipath/checkers/cciss_tur.c    |   5 -
+ libmultipath/checkers/directio.c     |   5 -
+ libmultipath/checkers/emc_clariion.c |   5 -
+ libmultipath/checkers/hp_sw.c        |   5 -
+ libmultipath/checkers/rbd.c          | 653 -----------------------------------
+ libmultipath/checkers/rdac.c         |   5 -
+ libmultipath/checkers/readsector0.c  |   5 -
+ libmultipath/checkers/tur.c          |   5 -
+ libmultipath/discovery.c             |  70 ----
+ libmultipath/hwtable.c               |  12 -
+ multipath/multipath.conf.5           |   3 -
+ multipathd/main.c                    |  11 -
+ 15 files changed, 819 deletions(-)
+ delete mode 100644 libmultipath/checkers/rbd.c
+
+diff --git a/libmultipath/checkers.c b/libmultipath/checkers.c
+index 08cdfc3..0bacc86 100644
+--- a/libmultipath/checkers.c
++++ b/libmultipath/checkers.c
+@@ -141,13 +141,6 @@ struct checker * add_checker (char *multipath_dir, char * name)
+ 	if (!c->free)
+ 		goto out;
+ 
+-	c->repair = (void (*)(struct checker *)) dlsym(c->handle,
+-						       "libcheck_repair");
+-	errstr = dlerror();
+-	if (errstr != NULL)
+-		condlog(0, "A dynamic linking error occurred: (%s)", errstr);
+-	if (!c->repair)
+-		goto out;
+ done:
+ 	c->fd = -1;
+ 	c->sync = 1;
+@@ -222,20 +215,6 @@ void checker_put (struct checker * dst)
+ 	free_checker(src);
+ }
+ 
+-void checker_repair (struct checker * c)
+-{
+-	if (!checker_selected(c))
+-		return;
+-
+-	c->message[0] = '\0';
+-	if (c->disable) {
+-		MSG(c, "checker disabled");
+-		return;
+-	}
+-	if (c->repair)
+-		c->repair(c);
+-}
+-
+ int checker_check (struct checker * c, int path_state)
+ {
+ 	int r;
+@@ -310,7 +289,6 @@ void checker_get (char *multipath_dir, struct checker * dst, char * name)
+ 	dst->sync = src->sync;
+ 	strncpy(dst->name, src->name, CHECKER_NAME_LEN);
+ 	strncpy(dst->message, src->message, CHECKER_MSG_LEN);
+-	dst->repair = src->repair;
+ 	dst->check = src->check;
+ 	dst->init = src->init;
+ 	dst->free = src->free;
+diff --git a/libmultipath/checkers.h b/libmultipath/checkers.h
+index 52154ca..7b18a1a 100644
+--- a/libmultipath/checkers.h
++++ b/libmultipath/checkers.h
+@@ -86,7 +86,6 @@ enum path_check_state {
+ #define READSECTOR0  "readsector0"
+ #define CCISS_TUR    "cciss_tur"
+ #define NONE         "none"
+-#define RBD          "rbd"
+ 
+ #define ASYNC_TIMEOUT_SEC	30
+ 
+@@ -113,9 +112,6 @@ struct checker {
+ 						multipath-wide. Use MALLOC if
+ 						you want to stuff data in. */
+ 	int (*check)(struct checker *);
+-	void (*repair)(struct checker *);    /* called if check returns
+-						PATH_DOWN to bring path into
+-						usable state */
+ 	int (*init)(struct checker *);       /* to allocate the context */
+ 	void (*free)(struct checker *);      /* to free the context */
+ };
+@@ -136,7 +132,6 @@ void checker_set_async (struct checker *);
+ void checker_set_fd (struct checker *, int);
+ void checker_enable (struct checker *);
+ void checker_disable (struct checker *);
+-void checker_repair (struct checker *);
+ int checker_check (struct checker *, int);
+ int checker_selected (struct checker *);
+ char * checker_name (struct checker *);
+@@ -148,6 +143,5 @@ void checker_get (char *, struct checker *, char *);
+ int libcheck_check(struct checker *);
+ int libcheck_init(struct checker *);
+ void libcheck_free(struct checker *);
+-void libcheck_repair(struct checker *);
+ 
+ #endif /* _CHECKERS_H */
+diff --git a/libmultipath/checkers/Makefile b/libmultipath/checkers/Makefile
+index 87c15bd..02caea6 100644
+--- a/libmultipath/checkers/Makefile
++++ b/libmultipath/checkers/Makefile
+@@ -15,15 +15,8 @@ LIBS= \
+ 	libcheckhp_sw.so \
+ 	libcheckrdac.so
+ 
+-ifneq ($(call check_file,/usr/include/rados/librados.h),0)
+-LIBS += libcheckrbd.so
+-endif
+-
+ all: $(LIBS)
+ 
+-libcheckrbd.so: rbd.o
+-	$(CC) $(LDFLAGS) $(SHARED_FLAGS) -o $@ $^ -lrados -ludev
+-
+ libcheckdirectio.so: libsg.o directio.o
+ 	$(CC) $(LDFLAGS) $(SHARED_FLAGS) -o $@ $^ -laio
+ 
+diff --git a/libmultipath/checkers/cciss_tur.c b/libmultipath/checkers/cciss_tur.c
+index 436470c..1cab201 100644
+--- a/libmultipath/checkers/cciss_tur.c
++++ b/libmultipath/checkers/cciss_tur.c
+@@ -59,11 +59,6 @@ void libcheck_free (struct checker * c)
+ 	return;
+ }
+ 
+-void libcheck_repair (struct checker * c)
+-{
+-	return;
+-}
+-
+ int libcheck_check(struct checker * c)
+ {
+ 	int rc;
+diff --git a/libmultipath/checkers/directio.c b/libmultipath/checkers/directio.c
+index ce60e4c..a80848d 100644
+--- a/libmultipath/checkers/directio.c
++++ b/libmultipath/checkers/directio.c
+@@ -118,11 +118,6 @@ void libcheck_free (struct checker * c)
+ 	free(ct);
+ }
+ 
+-void libcheck_repair (struct checker * c)
+-{
+-	return;
+-}
+-
+ static int
+ check_state(int fd, struct directio_context *ct, int sync, int timeout_secs)
+ {
+diff --git a/libmultipath/checkers/emc_clariion.c b/libmultipath/checkers/emc_clariion.c
+index 9c1ffed..9115b1b 100644
+--- a/libmultipath/checkers/emc_clariion.c
++++ b/libmultipath/checkers/emc_clariion.c
+@@ -90,11 +90,6 @@ void libcheck_free (struct checker * c)
+ 	free(c->context);
+ }
+ 
+-void libcheck_repair (struct checker * c)
+-{
+-	return;
+-}
+-
+ int libcheck_check (struct checker * c)
+ {
+ 	unsigned char sense_buffer[128] = { 0, };
+diff --git a/libmultipath/checkers/hp_sw.c b/libmultipath/checkers/hp_sw.c
+index cee9aab..0ad34a6 100644
+--- a/libmultipath/checkers/hp_sw.c
++++ b/libmultipath/checkers/hp_sw.c
+@@ -45,11 +45,6 @@ void libcheck_free (struct checker * c)
+ 	return;
+ }
+ 
+-void libcheck_repair (struct checker * c)
+-{
+-	return;
+-}
+-
+ static int
+ do_inq(int sg_fd, int cmddt, int evpd, unsigned int pg_op,
+        void *resp, int mx_resp_len, int noisy, unsigned int timeout)
+diff --git a/libmultipath/checkers/rbd.c b/libmultipath/checkers/rbd.c
+deleted file mode 100644
+index 4ff54f4..0000000
+--- a/libmultipath/checkers/rbd.c
++++ /dev/null
+@@ -1,653 +0,0 @@
+-/*
+- * Copyright (c) 2016 Red Hat
+- * Copyright (c) 2004 Christophe Varoqui
+- *
+- * Code based off of tur.c and ceph's krbd.cc
+- */
+-#define _GNU_SOURCE
+-#include <stdio.h>
+-#include <stdlib.h>
+-#include <string.h>
+-#include <unistd.h>
+-#include <fcntl.h>
+-#include <errno.h>
+-#include <pthread.h>
+-#include <libudev.h>
+-#include <ifaddrs.h>
+-#include <sys/types.h>
+-#include <sys/stat.h>
+-#include <sys/ioctl.h>
+-#include <sys/time.h>
+-#include <sys/wait.h>
+-#include <urcu.h>
+-
+-#include "rados/librados.h"
+-
+-#include "structs.h"
+-#include "checkers.h"
+-
+-#include "../libmultipath/debug.h"
+-#include "../libmultipath/util.h"
+-#include "../libmultipath/time-util.h"
+-#include "../libmultipath/util.h"
+-
+-struct rbd_checker_context;
+-typedef int (thread_fn)(struct rbd_checker_context *ct, char *msg);
+-
+-#define RBD_MSG(msg, fmt, args...) snprintf(msg, CHECKER_MSG_LEN, fmt, ##args);
+-
+-#define RBD_FEATURE_EXCLUSIVE_LOCK	(1 << 2)
+-
+-struct rbd_checker_context {
+-	int rbd_bus_id;
+-	char *client_addr;
+-	char *config_info;
+-	char *snap;
+-	char *pool;
+-	char *image;
+-	char *username;
+-	int remapped;
+-	int blacklisted;
+-	unsigned lock_on_read:1;
+-
+-	rados_t cluster;
+-
+-	int state;
+-	int running;
+-	time_t time;
+-	thread_fn *fn;
+-	pthread_t thread;
+-	pthread_mutex_t lock;
+-	pthread_cond_t active;
+-	pthread_spinlock_t hldr_lock;
+-	int holders;
+-	char message[CHECKER_MSG_LEN];
+-};
+-
+-int libcheck_init(struct checker * c)
+-{
+-	struct rbd_checker_context *ct;
+-	struct udev_device *block_dev;
+-	struct udev_device *bus_dev;
+-	struct udev *udev;
+-	struct stat sb;
+-	const char *block_name, *addr, *config_info, *features_str;
+-	const char *image, *pool, *snap, *username;
+-	uint64_t features = 0;
+-	char sysfs_path[PATH_SIZE];
+-	int ret;
+-
+-	ct = malloc(sizeof(struct rbd_checker_context));
+-	if (!ct)
+-		return 1;
+-	memset(ct, 0, sizeof(struct rbd_checker_context));
+-	ct->holders = 1;
+-	pthread_cond_init_mono(&ct->active);
+-	pthread_mutex_init(&ct->lock, NULL);
+-	pthread_spin_init(&ct->hldr_lock, PTHREAD_PROCESS_PRIVATE);
+-	c->context = ct;
+-
+-	/*
+-	 * The rbd block layer sysfs device is not linked to the rbd bus
+-	 * device that we interact with, so figure that out now.
+-	 */
+-	if (fstat(c->fd, &sb) != 0)
+-		goto free_ct;
+-
+-	udev = udev_new();
+-	if (!udev)
+-		goto free_ct;
+-
+-	block_dev = udev_device_new_from_devnum(udev, 'b', sb.st_rdev);
+-	if (!block_dev)
+-		goto free_udev;
+-
+-	block_name  = udev_device_get_sysname(block_dev);
+-	ret = sscanf(block_name, "rbd%d", &ct->rbd_bus_id);
+-
+-	udev_device_unref(block_dev);
+-	if (ret != 1)
+-		goto free_udev;
+-
+-	snprintf(sysfs_path, sizeof(sysfs_path), "/sys/bus/rbd/devices/%d",
+-		 ct->rbd_bus_id);
+-	bus_dev = udev_device_new_from_syspath(udev, sysfs_path);
+-	if (!bus_dev)
+-		goto free_udev;
+-
+-	addr = udev_device_get_sysattr_value(bus_dev, "client_addr");
+-	if (!addr) {
+-		condlog(0, "rbd%d: Could not find client_addr in rbd sysfs. "
+-			"Try updating kernel", ct->rbd_bus_id);
+-		goto free_dev;
+-	}
+-
+-	ct->client_addr = strdup(addr);
+-	if (!ct->client_addr)
+-		goto free_dev;
+-
+-	features_str = udev_device_get_sysattr_value(bus_dev, "features");
+-	if (!features_str)
+-		goto free_addr;
+-	features = strtoll(features_str, NULL, 16);
+-	if (!(features & RBD_FEATURE_EXCLUSIVE_LOCK)) {
+-		condlog(3, "rbd%d: Exclusive lock not set.", ct->rbd_bus_id);
+-		goto free_addr;
+-	}
+-
+-	config_info = udev_device_get_sysattr_value(bus_dev, "config_info");
+-	if (!config_info)
+-		goto free_addr;
+-
+-	if (!strstr(config_info, "noshare")) {
+-		condlog(3, "rbd%d: Only nonshared clients supported.",
+-			ct->rbd_bus_id);
+-		goto free_addr;
+-	}
+-
+-	if (strstr(config_info, "lock_on_read"))
+-		ct->lock_on_read = 1;
+-
+-	ct->config_info = strdup(config_info);
+-	if (!ct->config_info)
+-		goto free_addr;
+-
+-	username = strstr(config_info, "name=");
+-	if (username) {
+-		char *end;
+-		int len;
+-
+-		username += 5;
+-		end = strchr(username, ',');
+-		if (!end)
+-			goto free_info;
+-		len = end - username;
+-
+-		ct->username = malloc(len + 1);
+-		if (!ct->username)
+-			goto free_info;
+-		strncpy(ct->username, username, len);
+-		ct->username[len] = '\0';
+-	}
+-
+-	image = udev_device_get_sysattr_value(bus_dev, "name");
+-	if (!image)
+-		goto free_username;
+-
+-	ct->image = strdup(image);
+-	if (!ct->image)
+-		goto free_username;
+-
+-	pool = udev_device_get_sysattr_value(bus_dev, "pool");
+-	if (!pool)
+-		goto free_image;
+-
+-	ct->pool = strdup(pool);
+-	if (!ct->pool)
+-		goto free_image;
+-
+-	snap = udev_device_get_sysattr_value(bus_dev, "current_snap");
+-	if (!snap)
+-		goto free_pool;
+-
+-	if (strcmp("-", snap)) {
+-		ct->snap = strdup(snap);
+-		if (!ct->snap)
+-			goto free_pool;
+-	}
+-
+-	if (rados_create(&ct->cluster, NULL) < 0) {
+-		condlog(0, "rbd%d: Could not create rados cluster",
+-			ct->rbd_bus_id);
+-		goto free_snap;
+-	}
+-
+-	if (rados_conf_read_file(ct->cluster, NULL) < 0) {
+-		condlog(0, "rbd%d: Could not read rados conf", ct->rbd_bus_id);
+-		goto shutdown_rados;
+-	}
+-
+-	ret = rados_connect(ct->cluster);
+-	if (ret < 0) {
+-		condlog(0, "rbd%d: Could not connect to rados cluster",
+-			ct->rbd_bus_id);
+-		goto shutdown_rados;
+-	}
+-
+-	udev_device_unref(bus_dev);
+-	udev_unref(udev);
+-
+-	condlog(3, "rbd%d checker init %s %s/%s@%s %s", ct->rbd_bus_id,
+-		ct->client_addr, ct->pool, ct->image, ct->snap ? ct->snap : "-",
+-		ct->username ? ct->username : "none");
+-	return 0;
+-
+-shutdown_rados:
+-	rados_shutdown(ct->cluster);
+-free_snap:
+-	if (ct->snap)
+-		free(ct->snap);
+-free_pool:
+-	free(ct->pool);
+-free_image:
+-	free(ct->image);
+-free_username:
+-	if (ct->username)
+-		free(ct->username);
+-free_info:
+-	free(ct->config_info);
+-free_addr:
+-	free(ct->client_addr);
+-free_dev:
+-	udev_device_unref(bus_dev);
+-free_udev:
+-	udev_unref(udev);
+-free_ct:
+-	free(ct);
+-	return 1;
+-}
+-
+-static void cleanup_context(struct rbd_checker_context *ct)
+-{
+-	pthread_mutex_destroy(&ct->lock);
+-	pthread_cond_destroy(&ct->active);
+-	pthread_spin_destroy(&ct->hldr_lock);
+-
+-	rados_shutdown(ct->cluster);
+-
+-	if (ct->username)
+-		free(ct->username);
+-	if (ct->snap)
+-		free(ct->snap);
+-	free(ct->pool);
+-	free(ct->image);
+-	free(ct->config_info);
+-	free(ct->client_addr);
+-	free(ct);
+-}
+-
+-void libcheck_free(struct checker * c)
+-{
+-	if (c->context) {
+-		struct rbd_checker_context *ct = c->context;
+-		int holders;
+-		pthread_t thread;
+-
+-		pthread_spin_lock(&ct->hldr_lock);
+-		ct->holders--;
+-		holders = ct->holders;
+-		thread = ct->thread;
+-		pthread_spin_unlock(&ct->hldr_lock);
+-		if (holders)
+-			pthread_cancel(thread);
+-		else
+-			cleanup_context(ct);
+-		c->context = NULL;
+-	}
+-}
+-
+-static int rbd_is_blacklisted(struct rbd_checker_context *ct, char *msg)
+-{
+-	char *addr_tok, *start, *save;
+-	const char *cmd[2];
+-	char *blklist, *stat;
+-	size_t blklist_len, stat_len;
+-	int ret;
+-	char *end;
+-
+-	cmd[0] = "{\"prefix\": \"osd blacklist ls\"}";
+-	cmd[1] = NULL;
+-
+-	ret = rados_mon_command(ct->cluster, (const char **)cmd, 1, "", 0,
+-				&blklist, &blklist_len, &stat, &stat_len);
+-	if (ret < 0) {
+-		RBD_MSG(msg, "checker failed: mon command failed %d", ret);
+-		return ret;
+-	}
+-
+-	if (!blklist || !blklist_len)
+-		goto free_bufs;
+-
+-	/*
+-	 * parse list of addrs with the format
+-	 * ipv4:port/nonce date time\n
+-	 * or
+-	 * [ipv6]:port/nonce date time\n
+-	 */
+-	ret = 0;
+-	for (start = blklist; ; start = NULL) {
+-		addr_tok = strtok_r(start, "\n", &save);
+-		if (!addr_tok || !strlen(addr_tok))
+-			break;
+-
+-		end = strchr(addr_tok, ' ');
+-		if (!end) {
+-			RBD_MSG(msg, "checker failed: invalid blacklist %s",
+-				 addr_tok);
+-			break;
+-		}
+-		*end = '\0';
+-
+-		if (!strcmp(addr_tok, ct->client_addr)) {
+-			ct->blacklisted = 1;
+-			RBD_MSG(msg, "%s is blacklisted", ct->client_addr);
+-			ret = 1;
+-			break;
+-		}
+-	}
+-
+-free_bufs:
+-	rados_buffer_free(blklist);
+-	rados_buffer_free(stat);
+-	return ret;
+-}
+-
+-static int rbd_check(struct rbd_checker_context *ct, char *msg)
+-{
+-	if (ct->blacklisted || rbd_is_blacklisted(ct, msg) == 1)
+-		return PATH_DOWN;
+-
+-	RBD_MSG(msg, "checker reports path is up");
+-	/*
+-	 * Path may have issues, but the ceph cluster is at least
+-	 * accepting IO, so we can attempt to do IO.
+-	 *
+-	 * TODO: in future versions, we can run other tests to
+-	 * verify OSDs and networks.
+-	 */
+-	return PATH_UP;
+-}
+-
+-static int sysfs_write_rbd_bus(const char *which, const char *buf,
+-			       size_t buf_len)
+-{
+-	char sysfs_path[PATH_SIZE];
+-	int fd;
+-	int r;
+-
+-	/* we require newer kernels so single_major should always be there */
+-	snprintf(sysfs_path, sizeof(sysfs_path),
+-		 "/sys/bus/rbd/%s_single_major", which);
+-	fd = open(sysfs_path, O_WRONLY);
+-	if (fd < 0)
+-		return -errno;
+-
+-	r = safe_write(fd, buf, buf_len);
+-	close(fd);
+-	return r;
+-}
+-
+-static int rbd_remap(struct rbd_checker_context *ct)
+-{
+-	char *argv[11];
+-	pid_t pid;
+-	int ret = 0, i = 0;
+-	int status;
+-
+-	pid = fork();
+-	switch (pid) {
+-	case 0:
+-		argv[i++] = "rbd";
+-		argv[i++] = "map";
+-		if (ct->lock_on_read)
+-			argv[i++] = "-o noshare,lock_on_read";
+-		else
+-			argv[i++] = "-o noshare";
+-		if (ct->username) {
+-			argv[i++] = "--id";
+-			argv[i++] = ct->username;
+-		}
+-		argv[i++] = "--pool";
+-		argv[i++] = ct->pool;
+-		if (ct->snap) {
+-			argv[i++] = "--snap";
+-			argv[i++] = ct->snap;
+-		}
+-		argv[i++] = ct->image;
+-		argv[i] = NULL;
+-
+-		ret = execvp(argv[0], argv);
+-		condlog(0, "rbd%d: Error executing rbd: %s", ct->rbd_bus_id,
+-			strerror(errno));
+-		exit(-1);
+-	case -1:
+-		condlog(0, "rbd%d: fork failed: %s", ct->rbd_bus_id,
+-			strerror(errno));
+-		return -1;
+-	default:
+-		ret = -1;
+-		wait(&status);
+-		if (WIFEXITED(status)) {
+-			status = WEXITSTATUS(status);
+-			if (status == 0)
+-				ret = 0;
+-			else
+-				condlog(0, "rbd%d: failed with %d",
+-					ct->rbd_bus_id, status);
+-		}
+-	}
+-
+-	return ret;
+-}
+-
+-static int sysfs_write_rbd_remove(const char *buf, int buf_len)
+-{
+-	return sysfs_write_rbd_bus("remove", buf, buf_len);
+-}
+-
+-static int rbd_rm_blacklist(struct rbd_checker_context *ct)
+-{
+-	const char *cmd[2];
+-	char *stat, *cmd_str;
+-	size_t stat_len;
+-	int ret;
+-
+-	ret = asprintf(&cmd_str, "{\"prefix\": \"osd blacklist\", \"blacklistop\": \"rm\", \"addr\": \"%s\"}",
+-		       ct->client_addr);
+-	if (ret == -1)
+-		return -ENOMEM;
+-
+-	cmd[0] = cmd_str;
+-	cmd[1] = NULL;
+-
+-	ret = rados_mon_command(ct->cluster, (const char **)cmd, 1, "", 0,
+-				NULL, NULL, &stat, &stat_len);
+-	if (ret < 0) {
+-		condlog(1, "rbd%d: repair failed to remove blacklist for %s %d",
+-			ct->rbd_bus_id, ct->client_addr, ret);
+-		goto free_cmd;
+-	}
+-
+-	condlog(1, "rbd%d: repair rm blacklist for %s",
+-	       ct->rbd_bus_id, ct->client_addr);
+-	free(stat);
+-free_cmd:
+-	free(cmd_str);
+-	return ret;
+-}
+-
+-static int rbd_repair(struct rbd_checker_context *ct, char *msg)
+-{
+-	char del[17];
+-	int ret;
+-
+-	if (!ct->blacklisted)
+-		return PATH_UP;
+-
+-	if (!ct->remapped) {
+-		ret = rbd_remap(ct);
+-		if (ret) {
+-			RBD_MSG(msg, "repair failed to remap. Err %d", ret);
+-			return PATH_DOWN;
+-		}
+-	}
+-	ct->remapped = 1;
+-
+-	snprintf(del, sizeof(del), "%d force", ct->rbd_bus_id);
+-	ret = sysfs_write_rbd_remove(del, strlen(del) + 1);
+-	if (ret) {
+-		RBD_MSG(msg, "repair failed to clean up. Err %d", ret);
+-		return PATH_DOWN;
+-	}
+-
+-	ret = rbd_rm_blacklist(ct);
+-	if (ret) {
+-		RBD_MSG(msg, "repair could not remove blacklist entry. Err %d",
+-			ret);
+-		return PATH_DOWN;
+-	}
+-
+-	ct->remapped = 0;
+-	ct->blacklisted = 0;
+-
+-	RBD_MSG(msg, "has been repaired");
+-	return PATH_UP;
+-}
+-
+-#define rbd_thread_cleanup_push(ct) pthread_cleanup_push(cleanup_func, ct)
+-#define rbd_thread_cleanup_pop(ct) pthread_cleanup_pop(1)
+-
+-static void cleanup_func(void *data)
+-{
+-	int holders;
+-	struct rbd_checker_context *ct = data;
+-	pthread_spin_lock(&ct->hldr_lock);
+-	ct->holders--;
+-	holders = ct->holders;
+-	ct->thread = 0;
+-	pthread_spin_unlock(&ct->hldr_lock);
+-	if (!holders)
+-		cleanup_context(ct);
+-	rcu_unregister_thread();
+-}
+-
+-static void *rbd_thread(void *ctx)
+-{
+-	struct rbd_checker_context *ct = ctx;
+-	int state;
+-
+-	/* This thread can be canceled, so setup clean up */
+-	rbd_thread_cleanup_push(ct)
+-	rcu_register_thread();
+-	condlog(3, "rbd%d: thread starting up", ct->rbd_bus_id);
+-
+-	ct->message[0] = '\0';
+-
+-	/* checker start up */
+-	pthread_mutex_lock(&ct->lock);
+-	ct->state = PATH_PENDING;
+-	pthread_mutex_unlock(&ct->lock);
+-
+-	state = ct->fn(ct, ct->message);
+-
+-	/* checker done */
+-	pthread_mutex_lock(&ct->lock);
+-	ct->state = state;
+-	pthread_cond_signal(&ct->active);
+-	pthread_mutex_unlock(&ct->lock);
+-
+-	condlog(3, "rbd%d: thead finished, state %s", ct->rbd_bus_id,
+-		checker_state_name(state));
+-	rbd_thread_cleanup_pop(ct);
+-	return ((void *)0);
+-}
+-
+-static void rbd_timeout(struct timespec *tsp)
+-{
+-	clock_gettime(CLOCK_MONOTONIC, tsp);
+-	tsp->tv_nsec += 1000 * 1000; /* 1 millisecond */
+-	normalize_timespec(tsp);
+-}
+-
+-static int rbd_exec_fn(struct checker *c, thread_fn *fn)
+-{
+-	struct rbd_checker_context *ct = c->context;
+-	struct timespec tsp;
+-	pthread_attr_t attr;
+-	int rbd_status, r;
+-
+-	if (c->sync)
+-		return fn(ct, c->message);
+-	/*
+-	 * Async mode
+-	 */
+-	r = pthread_mutex_lock(&ct->lock);
+-	if (r != 0) {
+-		condlog(2, "rbd%d: mutex lock failed with %d", ct->rbd_bus_id,
+-			r);
+-		MSG(c, "rbd%d: thread failed to initialize", ct->rbd_bus_id);
+-		return PATH_WILD;
+-	}
+-
+-	if (ct->running) {
+-		/* Check if checker is still running */
+-		if (ct->thread) {
+-			condlog(3, "rbd%d: thread not finished",
+-				ct->rbd_bus_id);
+-			rbd_status = PATH_PENDING;
+-		} else {
+-			/* checker done */
+-			ct->running = 0;
+-			rbd_status = ct->state;
+-			strncpy(c->message, ct->message, CHECKER_MSG_LEN);
+-			c->message[CHECKER_MSG_LEN - 1] = '\0';
+-		}
+-		pthread_mutex_unlock(&ct->lock);
+-	} else {
+-		/* Start new checker */
+-		ct->state = PATH_UNCHECKED;
+-		ct->fn = fn;
+-		pthread_spin_lock(&ct->hldr_lock);
+-		ct->holders++;
+-		pthread_spin_unlock(&ct->hldr_lock);
+-		setup_thread_attr(&attr, 32 * 1024, 1);
+-		r = pthread_create(&ct->thread, &attr, rbd_thread, ct);
+-		if (r) {
+-			pthread_mutex_unlock(&ct->lock);
+-			ct->thread = 0;
+-			ct->holders--;
+-			condlog(3, "rbd%d failed to start rbd thread, using sync mode",
+-				ct->rbd_bus_id);
+-			return fn(ct, c->message);
+-		}
+-		pthread_attr_destroy(&attr);
+-		rbd_timeout(&tsp);
+-		r = pthread_cond_timedwait(&ct->active, &ct->lock, &tsp);
+-		rbd_status = ct->state;
+-		strncpy(c->message, ct->message,CHECKER_MSG_LEN);
+-		c->message[CHECKER_MSG_LEN -1] = '\0';
+-		pthread_mutex_unlock(&ct->lock);
+-
+-		if (ct->thread &&
+-		    (rbd_status == PATH_PENDING || rbd_status == PATH_UNCHECKED)) {
+-			condlog(3, "rbd%d: thread still running",
+-				ct->rbd_bus_id);
+-			ct->running = 1;
+-			rbd_status = PATH_PENDING;
+-		}
+-	}
+-
+-	return rbd_status;
+-}
+-
+-void libcheck_repair(struct checker * c)
+-{
+-	struct rbd_checker_context *ct = c->context;
+-
+-	if (!ct || !ct->blacklisted)
+-		return;
+-	rbd_exec_fn(c, rbd_repair);
+-}
+-
+-int libcheck_check(struct checker * c)
+-{
+-	struct rbd_checker_context *ct = c->context;
+-
+-	if (!ct)
+-		return PATH_UNCHECKED;
+-
+-	if (ct->blacklisted)
+-		return PATH_DOWN;
+-
+-	return rbd_exec_fn(c, rbd_check);
+-}
+diff --git a/libmultipath/checkers/rdac.c b/libmultipath/checkers/rdac.c
+index a643a4a..5104e4e 100644
+--- a/libmultipath/checkers/rdac.c
++++ b/libmultipath/checkers/rdac.c
+@@ -139,11 +139,6 @@ void libcheck_free (struct checker * c)
+ 	return;
+ }
+ 
+-void libcheck_repair (struct checker * c)
+-{
+-	return;
+-}
+-
+ static int
+ do_inq(int sg_fd, unsigned int pg_op, void *resp, int mx_resp_len,
+        unsigned int timeout)
+diff --git a/libmultipath/checkers/readsector0.c b/libmultipath/checkers/readsector0.c
+index 8fccb46..1c2a868 100644
+--- a/libmultipath/checkers/readsector0.c
++++ b/libmultipath/checkers/readsector0.c
+@@ -23,11 +23,6 @@ void libcheck_free (struct checker * c)
+ 	return;
+ }
+ 
+-void libcheck_repair (struct checker * c)
+-{
+-	return;
+-}
+-
+ int libcheck_check (struct checker * c)
+ {
+ 	unsigned char buf[4096];
+diff --git a/libmultipath/checkers/tur.c b/libmultipath/checkers/tur.c
+index eb3348d..bf8486d 100644
+--- a/libmultipath/checkers/tur.c
++++ b/libmultipath/checkers/tur.c
+@@ -112,11 +112,6 @@ void libcheck_free (struct checker * c)
+ 	return;
+ }
+ 
+-void libcheck_repair (struct checker * c)
+-{
+-	return;
+-}
+-
+ #define TUR_MSG(fmt, args...)					\
+ 	do {							\
+ 		char msg[CHECKER_MSG_LEN];			\
+diff --git a/libmultipath/discovery.c b/libmultipath/discovery.c
+index 1ef1dfa..18ad0e2 100644
+--- a/libmultipath/discovery.c
++++ b/libmultipath/discovery.c
+@@ -1246,21 +1246,6 @@ nvme_sysfs_pathinfo (struct path * pp, vector hwtable)
+ }
+ 
+ static int
+-rbd_sysfs_pathinfo (struct path * pp, vector hwtable)
+-{
+-	sprintf(pp->vendor_id, "Ceph");
+-	sprintf(pp->product_id, "RBD");
+-
+-	condlog(3, "%s: vendor = %s product = %s", pp->dev, pp->vendor_id,
+-		pp->product_id);
+-	/*
+-	 * set the hwe configlet pointer
+-	 */
+-	pp->hwe = find_hwe(hwtable, pp->vendor_id, pp->product_id, NULL);
+-	return 0;
+-}
+-
+-static int
+ ccw_sysfs_pathinfo (struct path * pp, vector hwtable)
+ {
+ 	struct udev_device *parent;
+@@ -1486,8 +1471,6 @@ sysfs_pathinfo(struct path * pp, vector hwtable)
+ 		pp->bus = SYSFS_BUS_CCW;
+ 	if (!strncmp(pp->dev,"sd", 2))
+ 		pp->bus = SYSFS_BUS_SCSI;
+-	if (!strncmp(pp->dev,"rbd", 3))
+-		pp->bus = SYSFS_BUS_RBD;
+ 	if (!strncmp(pp->dev,"nvme", 4))
+ 		pp->bus = SYSFS_BUS_NVME;
+ 
+@@ -1502,9 +1485,6 @@ sysfs_pathinfo(struct path * pp, vector hwtable)
+ 	} else if (pp->bus == SYSFS_BUS_CCISS) {
+ 		if (cciss_sysfs_pathinfo(pp, hwtable))
+ 			return 1;
+-	} else if (pp->bus == SYSFS_BUS_RBD) {
+-		if (rbd_sysfs_pathinfo(pp, hwtable))
+-			return 1;
+ 	} else if (pp->bus == SYSFS_BUS_NVME) {
+ 		if (nvme_sysfs_pathinfo(pp, hwtable))
+ 			return 1;
+@@ -1753,53 +1733,6 @@ get_udev_uid(struct path * pp, char *uid_attribute, struct udev_device *udev)
+ }
+ 
+ static int
+-get_rbd_uid(struct path * pp)
+-{
+-	struct udev_device *rbd_bus_dev;
+-	int ret, rbd_bus_id;
+-	const char *pool, *image, *snap;
+-	char sysfs_path[PATH_SIZE];
+-	uint64_t snap_id, max_snap_id = -3;
+-
+-	ret = sscanf(pp->dev, "rbd%d", &rbd_bus_id);
+-	if (ret != 1)
+-		return -EINVAL;
+-
+-	snprintf(sysfs_path, sizeof(sysfs_path), "/sys/bus/rbd/devices/%d",
+-		 rbd_bus_id);
+-	rbd_bus_dev = udev_device_new_from_syspath(udev, sysfs_path);
+-	if (!rbd_bus_dev)
+-		return -ENODEV;
+-
+-	ret = -EINVAL;
+-	pool = udev_device_get_sysattr_value(rbd_bus_dev, "pool_id");
+-	if (!pool)
+-		goto free_dev;
+-
+-	image = udev_device_get_sysattr_value(rbd_bus_dev, "image_id");
+-	if (!image)
+-		goto free_dev;
+-
+-	snap = udev_device_get_sysattr_value(rbd_bus_dev, "snap_id");
+-	if (!snap)
+-		goto free_dev;
+-	snap_id = strtoull(snap, NULL, 19);
+-	if (snap_id >= max_snap_id)
+-		ret = snprintf(pp->wwid, WWID_SIZE, "%s-%s", pool, image);
+-	else
+-		ret = snprintf(pp->wwid, WWID_SIZE, "%s-%s-%s", pool,
+-			       image, snap);
+-	if (ret >= WWID_SIZE) {
+-		condlog(0, "%s: wwid overflow", pp->dev);
+-		ret = -EOVERFLOW;
+-	}
+-
+-free_dev:
+-	udev_device_unref(rbd_bus_dev);
+-	return ret;
+-}
+-
+-static int
+ get_vpd_uid(struct path * pp)
+ {
+ 	struct udev_device *parent = pp->udev;
+@@ -1876,9 +1809,6 @@ get_uid (struct path * pp, int path_state, struct udev_device *udev)
+ 		} else
+ 			len = strlen(pp->wwid);
+ 		origin = "callout";
+-	} else if (pp->bus == SYSFS_BUS_RBD) {
+-		len = get_rbd_uid(pp);
+-		origin = "sysfs";
+ 	} else {
+ 
+ 		if (udev && pp->uid_attribute) {
+diff --git a/libmultipath/hwtable.c b/libmultipath/hwtable.c
+index 148f0ba..d529bae 100644
+--- a/libmultipath/hwtable.c
++++ b/libmultipath/hwtable.c
+@@ -1000,18 +1000,6 @@ static struct hwentry default_hw[] = {
+ 		.prio_name     = PRIO_ALUA,
+ 	},
+ 	/*
+-	 * Red Hat
+-	 *
+-	 * Maintainer: Mike Christie
+-	 * Mail: mchristi@redhat.com
+-	 */
+-	{
+-		.vendor        = "Ceph",
+-		.product       = "RBD",
+-		.checker_name  = RBD,
+-		.deferred_remove = DEFERRED_REMOVE_ON,
+-	},
+-	/*
+ 	 * Kove
+ 	 */
+ 	{
+diff --git a/multipath/multipath.conf.5 b/multipath/multipath.conf.5
+index 0c1f174..31f4585 100644
+--- a/multipath/multipath.conf.5
++++ b/multipath/multipath.conf.5
+@@ -482,9 +482,6 @@ Check the path state for HP/COMPAQ Smart Array(CCISS) controllers.
+ .I none
+ Do not check the device, fallback to use the values retrieved from sysfs
+ .TP
+-.I rbd
+-Check if the path is in the Ceph blacklist and remap the path if it is.
+-.TP
+ The default is: \fBtur\fR
+ .RE
+ .
+diff --git a/multipathd/main.c b/multipathd/main.c
+index 0db88ee..d40c416 100644
+--- a/multipathd/main.c
++++ b/multipathd/main.c
+@@ -1783,15 +1783,6 @@ int update_path_groups(struct multipath *mpp, struct vectors *vecs, int refresh)
+ 	return 0;
+ }
+ 
+-void repair_path(struct path * pp)
+-{
+-	if (pp->state != PATH_DOWN)
+-		return;
+-
+-	checker_repair(&pp->checker);
+-	LOG_MSG(1, checker_message(&pp->checker));
+-}
+-
+ /*
+  * Returns '1' if the path has been checked, '-1' if it was blacklisted
+  * and '0' otherwise
+@@ -1972,7 +1963,6 @@ check_path (struct vectors * vecs, struct path * pp, int ticks)
+ 			pp->mpp->failback_tick = 0;
+ 
+ 			pp->mpp->stat_path_failures++;
+-			repair_path(pp);
+ 			return 1;
+ 		}
+ 
+@@ -2071,7 +2061,6 @@ check_path (struct vectors * vecs, struct path * pp, int ticks)
+ 	}
+ 
+ 	pp->state = newstate;
+-	repair_path(pp);
+ 
+ 	if (pp->mpp->wait_for_udev)
+ 		return 1;
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0017-mpathpersist-fix-aptpl-support.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0017-mpathpersist-fix-aptpl-support.patch
new file mode 100644
index 0000000..b98d310
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0017-mpathpersist-fix-aptpl-support.patch
@@ -0,0 +1,543 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Mon, 4 Jun 2018 22:04:44 -0500
+Subject: [PATCH] mpathpersist: fix aptpl support
+
+The "Active Persist Through Power Loss" flag must be set whenever a key
+is registered. However, there is no way for multipathd to know if this
+was set by mpathpersist. The result is that if a path goes down and
+comes back up (or if it wasn't up when mpathpersist was first run)
+multipathd will clear the aptpl flag when it reregisters the key on it.
+
+To fix this, multipath.conf now accepts an optional ":aptpl" appended
+on the reservation_key value. If this is added to the reservation_key
+multipathd will set the aptpl flag when it reregisters the key. If
+reservation_key is set to "file", this will automatically be tracked
+in the /etc/multipath/prkeys file.
+
+To track this flag in the prkeys file, without changing the format
+I've made "0x<key>" stand for non-aptpl keys, and "0X<key>" stand
+for aptpl keys. Since previously, all keys used a lower-case x, this
+will default to the current behavior for existing keys. Obviously, the
+next time mpathpersist is run, this will be changed if --param-aptpl
+is used.  Since there are no more flags that are in sg_persist that
+multipathd needs to care about in mpathpersist, there shouldn't need
+to be any more flags added to the prkeys file.
+
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmpathpersist/mpath_persist.c  |  3 ++-
+ libmpathpersist/mpath_updatepr.c | 11 +++++++----
+ libmpathpersist/mpathpr.h        |  3 ++-
+ libmultipath/Makefile            |  2 +-
+ libmultipath/config.h            |  2 ++
+ libmultipath/dict.c              | 23 +++++++++++++++++++----
+ libmultipath/dict.h              |  3 ++-
+ libmultipath/prkey.c             | 27 ++++++++++++++++++++++++---
+ libmultipath/prkey.h             |  6 ++++--
+ libmultipath/propsel.c           |  6 ++++--
+ libmultipath/structs.h           |  1 +
+ libmultipath/util.c              | 16 ++++++++++++++++
+ libmultipath/util.h              |  1 +
+ multipath/multipath.conf.5       |  7 +++++--
+ multipathd/cli_handlers.c        | 15 ++++++++++-----
+ multipathd/main.c                |  1 +
+ 16 files changed, 101 insertions(+), 26 deletions(-)
+
+diff --git a/libmpathpersist/mpath_persist.c b/libmpathpersist/mpath_persist.c
+index ca91c55..6e9e67f 100644
+--- a/libmpathpersist/mpath_persist.c
++++ b/libmpathpersist/mpath_persist.c
+@@ -344,7 +344,8 @@ int mpath_persistent_reserve_out ( int fd, int rq_servact, int rq_scope,
+ 	      rq_servact == MPATH_PROUT_REG_SA) ||
+ 	     rq_servact == MPATH_PROUT_REG_IGN_SA)) {
+ 		memcpy(&mpp->reservation_key, paramp->sa_key, 8);
+-		if (update_prkey(alias, get_be64(mpp->reservation_key))) {
++		if (update_prkey_flags(alias, get_be64(mpp->reservation_key),
++				       paramp->sa_flags)) {
+ 			condlog(0, "%s: failed to set prkey for multipathd.",
+ 				alias);
+ 			ret = MPATH_PR_DMMP_ERROR;
+diff --git a/libmpathpersist/mpath_updatepr.c b/libmpathpersist/mpath_updatepr.c
+index 8063e90..0aca28e 100644
+--- a/libmpathpersist/mpath_updatepr.c
++++ b/libmpathpersist/mpath_updatepr.c
+@@ -1,7 +1,5 @@
+ #include <stdio.h>
+ #include <unistd.h>
+-#include <errno.h>
+-
+ #include <stdlib.h>
+ #include <stdarg.h>
+ #include <fcntl.h>
+@@ -11,6 +9,8 @@
+ #include <sys/un.h>
+ #include <poll.h>
+ #include <errno.h>
++#include <libudev.h>
++#include <mpath_persist.h>
+ #include "debug.h"
+ #include "mpath_cmd.h"
+ #include "uxsock.h"
+@@ -59,11 +59,14 @@ int update_prflag(char *mapname, int set) {
+ 	return do_update_pr(mapname, (set)? "setprstatus" : "unsetprstatus");
+ }
+ 
+-int update_prkey(char *mapname, uint64_t prkey) {
++int update_prkey_flags(char *mapname, uint64_t prkey, uint8_t sa_flags) {
+ 	char str[256];
++	char *flagstr = "";
+ 
++	if (sa_flags & MPATH_F_APTPL_MASK)
++		flagstr = ":aptpl";
+ 	if (prkey)
+-		sprintf(str, "setprkey key %" PRIx64, prkey);
++		sprintf(str, "setprkey key %" PRIx64 "%s", prkey, flagstr);
+ 	else
+ 		sprintf(str, "unsetprkey");
+ 	return do_update_pr(mapname, str);
+diff --git a/libmpathpersist/mpathpr.h b/libmpathpersist/mpathpr.h
+index 72feb60..5ea8cd6 100644
+--- a/libmpathpersist/mpathpr.h
++++ b/libmpathpersist/mpathpr.h
+@@ -46,7 +46,8 @@ int send_prout_activepath(char * dev, int rq_servact, int rq_scope,
+ 	unsigned int rq_type,   struct prout_param_descriptor * paramp, int noisy);
+ 
+ int update_prflag(char *mapname, int set);
+-int update_prkey(char *mapname, uint64_t prkey);
++int update_prkey_flags(char *mapname, uint64_t prkey, uint8_t sa_flags);
++#define update_prkey(mapname, prkey) update_prkey_flags(mapname, prkey, 0)
+ void * mpath_alloc_prin_response(int prin_sa);
+ int update_map_pr(struct multipath *mpp);
+ 
+diff --git a/libmultipath/Makefile b/libmultipath/Makefile
+index f51786d..33f5269 100644
+--- a/libmultipath/Makefile
++++ b/libmultipath/Makefile
+@@ -7,7 +7,7 @@ SONAME = 0
+ DEVLIB = libmultipath.so
+ LIBS = $(DEVLIB).$(SONAME)
+ 
+-CFLAGS += $(LIB_CFLAGS) -I$(mpathcmddir)
++CFLAGS += $(LIB_CFLAGS) -I$(mpathcmddir) -I$(mpathpersistdir)
+ 
+ LIBDEPS += -lpthread -ldl -ldevmapper -ludev -L$(mpathcmddir) -lmpathcmd -lurcu -laio
+ 
+diff --git a/libmultipath/config.h b/libmultipath/config.h
+index 1bf708a..fcbe3fc 100644
+--- a/libmultipath/config.h
++++ b/libmultipath/config.h
+@@ -98,6 +98,7 @@ struct mpentry {
+ 	char * prio_args;
+ 	int prkey_source;
+ 	struct be64 reservation_key;
++	uint8_t sa_flags;
+ 	int pgpolicy;
+ 	int pgfailback;
+ 	int rr_weight;
+@@ -197,6 +198,7 @@ struct config {
+ 	int prkey_source;
+ 	int all_tg_pt;
+ 	struct be64 reservation_key;
++	uint8_t sa_flags;
+ 
+ 	vector keywords;
+ 	vector mptable;
+diff --git a/libmultipath/dict.c b/libmultipath/dict.c
+index 2557b8a..7ad0f5a 100644
+--- a/libmultipath/dict.c
++++ b/libmultipath/dict.c
+@@ -22,6 +22,8 @@
+ #include "util.h"
+ #include <errno.h>
+ #include <inttypes.h>
++#include <libudev.h>
++#include <mpath_persist.h>
+ #include "mpath_cmd.h"
+ #include "dict.h"
+ 
+@@ -1012,10 +1014,12 @@ snprint_def_log_checker_err (struct config *conf, char * buff, int len,
+ }
+ 
+ static int
+-set_reservation_key(vector strvec, struct be64 *be64_ptr, int *source_ptr)
++set_reservation_key(vector strvec, struct be64 *be64_ptr, uint8_t *flags_ptr,
++		    int *source_ptr)
+ {
+ 	char *buff;
+ 	uint64_t prkey;
++	uint8_t sa_flags;
+ 
+ 	buff = set_value(strvec);
+ 	if (!buff)
+@@ -1023,35 +1027,43 @@ set_reservation_key(vector strvec, struct be64 *be64_ptr, int *source_ptr)
+ 
+ 	if (strcmp(buff, "file") == 0) {
+ 		*source_ptr = PRKEY_SOURCE_FILE;
++		*flags_ptr = 0;
+ 		put_be64(*be64_ptr, 0);
+ 		FREE(buff);
+ 		return 0;
+ 	}
+ 
+-	if (parse_prkey(buff, &prkey) != 0) {
++	if (parse_prkey_flags(buff, &prkey, &sa_flags) != 0) {
+ 		FREE(buff);
+ 		return 1;
+ 	}
+ 	*source_ptr = PRKEY_SOURCE_CONF;
++	*flags_ptr = sa_flags;
+ 	put_be64(*be64_ptr, prkey);
+ 	FREE(buff);
+ 	return 0;
+ }
+ 
+ int
+-print_reservation_key(char * buff, int len, struct be64 key, int source)
++print_reservation_key(char * buff, int len, struct be64 key, uint8_t flags,
++		      int source)
+ {
++	char *flagstr = "";
+ 	if (source == PRKEY_SOURCE_NONE)
+ 		return 0;
+ 	if (source == PRKEY_SOURCE_FILE)
+ 		return snprintf(buff, len, "file");
+-	return snprintf(buff, len, "0x%" PRIx64, get_be64(key));
++	if (flags & MPATH_F_APTPL_MASK)
++		flagstr = ":aptpl";
++	return snprintf(buff, len, "0x%" PRIx64 "%s", get_be64(key),
++			flagstr);
+ }
+ 
+ static int
+ def_reservation_key_handler(struct config *conf, vector strvec)
+ {
+ 	return set_reservation_key(strvec, &conf->reservation_key,
++				   &conf->sa_flags,
+ 				   &conf->prkey_source);
+ }
+ 
+@@ -1060,6 +1072,7 @@ snprint_def_reservation_key (struct config *conf, char * buff, int len,
+ 			     const void * data)
+ {
+ 	return print_reservation_key(buff, len, conf->reservation_key,
++				     conf->sa_flags,
+ 				     conf->prkey_source);
+ }
+ 
+@@ -1070,6 +1083,7 @@ mp_reservation_key_handler(struct config *conf, vector strvec)
+ 	if (!mpe)
+ 		return 1;
+ 	return set_reservation_key(strvec, &mpe->reservation_key,
++				   &mpe->sa_flags,
+ 				   &mpe->prkey_source);
+ }
+ 
+@@ -1079,6 +1093,7 @@ snprint_mp_reservation_key (struct config *conf, char * buff, int len,
+ {
+ 	const struct mpentry * mpe = (const struct mpentry *)data;
+ 	return print_reservation_key(buff, len, mpe->reservation_key,
++				     mpe->sa_flags,
+ 				     mpe->prkey_source);
+ }
+ 
+diff --git a/libmultipath/dict.h b/libmultipath/dict.h
+index 7564892..a40ac66 100644
+--- a/libmultipath/dict.h
++++ b/libmultipath/dict.h
+@@ -15,6 +15,7 @@ int print_pgpolicy(char *buff, int len, long v);
+ int print_no_path_retry(char *buff, int len, long v);
+ int print_fast_io_fail(char *buff, int len, long v);
+ int print_dev_loss(char *buff, int len, unsigned long v);
+-int print_reservation_key(char * buff, int len, struct be64 key, int source);
++int print_reservation_key(char * buff, int len, struct be64 key, uint8_t
++			  flags, int source);
+ int print_off_int_undef(char *buff, int len, long v);
+ #endif /* _DICT_H */
+diff --git a/libmultipath/prkey.c b/libmultipath/prkey.c
+index 89b90ed..d645f81 100644
+--- a/libmultipath/prkey.c
++++ b/libmultipath/prkey.c
+@@ -11,6 +11,8 @@
+ #include <string.h>
+ #include <inttypes.h>
+ #include <errno.h>
++#include <libudev.h>
++#include <mpath_persist.h>
+ 
+ #define PRKEY_READ 0
+ #define PRKEY_WRITE 1
+@@ -108,7 +110,8 @@ static int do_prkey(int fd, char *wwid, char *keystr, int cmd)
+ 	return 0;
+ }
+ 
+-int get_prkey(struct config *conf, struct multipath *mpp, uint64_t *prkey)
++int get_prkey(struct config *conf, struct multipath *mpp, uint64_t *prkey,
++	      uint8_t *sa_flags)
+ {
+ 	int fd;
+ 	int unused;
+@@ -124,6 +127,9 @@ int get_prkey(struct config *conf, struct multipath *mpp, uint64_t *prkey)
+ 	ret = do_prkey(fd, mpp->wwid, keystr, PRKEY_READ);
+ 	if (ret)
+ 		goto out_file;
++	*sa_flags = 0;
++	if (strchr(keystr, 'X'))
++		*sa_flags = MPATH_F_APTPL_MASK;
+ 	ret = !!parse_prkey(keystr, prkey);
+ out_file:
+ 	close(fd);
+@@ -131,7 +137,8 @@ out:
+ 	return ret;
+ }
+ 
+-int set_prkey(struct config *conf, struct multipath *mpp, uint64_t prkey)
++int set_prkey(struct config *conf, struct multipath *mpp, uint64_t prkey,
++	      uint8_t sa_flags)
+ {
+ 	int fd;
+ 	int can_write = 1;
+@@ -141,6 +148,12 @@ int set_prkey(struct config *conf, struct multipath *mpp, uint64_t prkey)
+ 	if (!strlen(mpp->wwid))
+ 		goto out;
+ 
++	if (sa_flags & ~MPATH_F_APTPL_MASK) {
++		condlog(0, "unsupported pr flags, 0x%x",
++			sa_flags & ~MPATH_F_APTPL_MASK);
++		sa_flags &= MPATH_F_APTPL_MASK;
++	}
++
+ 	fd = open_file(conf->prkeys_file, &can_write, PRKEYS_FILE_HEADER);
+ 	if (fd < 0)
+ 		goto out;
+@@ -149,7 +162,15 @@ int set_prkey(struct config *conf, struct multipath *mpp, uint64_t prkey)
+ 		goto out_file;
+ 	}
+ 	if (prkey) {
+-		snprintf(keystr, PRKEY_SIZE, "0x%016" PRIx64, prkey);
++		/* using the capitalization of the 'x' is a hack, but
++		 * it's unlikely that mpath_persist will support more options
++		 * since sg_persist doesn't, and this lets us keep the
++		 * same file format as before instead of needing to change
++		 * the format of the prkeys file */
++		if (sa_flags)
++			snprintf(keystr, PRKEY_SIZE, "0X%016" PRIx64, prkey);
++		else
++			snprintf(keystr, PRKEY_SIZE, "0x%016" PRIx64, prkey);
+ 		keystr[PRKEY_SIZE - 1] = '\0';
+ 		ret = do_prkey(fd, mpp->wwid, keystr, PRKEY_WRITE);
+ 	}
+diff --git a/libmultipath/prkey.h b/libmultipath/prkey.h
+index 4028e70..6739191 100644
+--- a/libmultipath/prkey.h
++++ b/libmultipath/prkey.h
+@@ -13,7 +13,9 @@
+ "# prkey wwid\n" \
+ "#\n"
+ 
+-int set_prkey(struct config *conf, struct multipath *mpp, uint64_t prkey);
+-int get_prkey(struct config *conf, struct multipath *mpp, uint64_t *prkey);
++int set_prkey(struct config *conf, struct multipath *mpp, uint64_t prkey,
++	      uint8_t sa_flags);
++int get_prkey(struct config *conf, struct multipath *mpp, uint64_t *prkey,
++	      uint8_t *sa_flags);
+ 
+ #endif /* _PRKEY_H */
+diff --git a/libmultipath/propsel.c b/libmultipath/propsel.c
+index 9ca1355..62a6893 100644
+--- a/libmultipath/propsel.c
++++ b/libmultipath/propsel.c
+@@ -106,6 +106,7 @@ do {									\
+ 	if (src && src->prkey_source != PRKEY_SOURCE_NONE) {		\
+ 		mp->prkey_source = src->prkey_source;			\
+ 		mp->reservation_key = src->reservation_key;		\
++		mp->sa_flags = src->sa_flags;				\
+ 		origin = msg;						\
+ 		goto out;						\
+ 	}								\
+@@ -703,18 +704,19 @@ int select_reservation_key(struct config *conf, struct multipath *mp)
+ 	do_prkey_set(mp->mpe, multipaths_origin);
+ 	do_prkey_set(conf, conf_origin);
+ 	put_be64(mp->reservation_key, 0);
++	mp->sa_flags = 0;
+ 	mp->prkey_source = PRKEY_SOURCE_NONE;
+ 	return 0;
+ out:
+ 	if (mp->prkey_source == PRKEY_SOURCE_FILE) {
+ 		from_file = " (from prkeys file)";
+-		if (get_prkey(conf, mp, &prkey) != 0)
++		if (get_prkey(conf, mp, &prkey, &mp->sa_flags) != 0)
+ 			put_be64(mp->reservation_key, 0);
+ 		else
+ 			put_be64(mp->reservation_key, prkey);
+ 	}
+ 	print_reservation_key(buff, PRKEY_SIZE, mp->reservation_key,
+-			      mp->prkey_source);
++			      mp->sa_flags, mp->prkey_source);
+ 	condlog(3, "%s: reservation_key = %s %s%s", mp->alias, buff, origin,
+ 		from_file);
+ 	return 0;
+diff --git a/libmultipath/structs.h b/libmultipath/structs.h
+index 0194b1e..987479f 100644
+--- a/libmultipath/structs.h
++++ b/libmultipath/structs.h
+@@ -367,6 +367,7 @@ struct multipath {
+ 	/* persistent management data*/
+ 	int prkey_source;
+ 	struct be64 reservation_key;
++	uint8_t sa_flags;
+ 	unsigned char prflag;
+ 	int all_tg_pt;
+ 	struct gen_multipath generic_mp;
+diff --git a/libmultipath/util.c b/libmultipath/util.c
+index 7251ad0..8d8fcc8 100644
+--- a/libmultipath/util.c
++++ b/libmultipath/util.c
+@@ -10,6 +10,8 @@
+ #include <dirent.h>
+ #include <unistd.h>
+ #include <errno.h>
++#include <libudev.h>
++#include <mpath_persist.h>
+ 
+ #include "util.h"
+ #include "debug.h"
+@@ -435,6 +437,20 @@ int parse_prkey(char *ptr, uint64_t *prkey)
+ 	return 0;
+ }
+ 
++int parse_prkey_flags(char *ptr, uint64_t *prkey, uint8_t *flags)
++{
++	char *flagstr;
++
++	flagstr = strchr(ptr, ':');
++	*flags = 0;
++	if (flagstr) {
++		*flagstr++ = '\0';
++		if (strlen(flagstr) == 5 && strcmp(flagstr, "aptpl") == 0)
++			*flags = MPATH_F_APTPL_MASK;
++	}
++	return parse_prkey(ptr, prkey);
++}
++
+ int safe_write(int fd, const void *buf, size_t count)
+ {
+ 	while (count > 0) {
+diff --git a/libmultipath/util.h b/libmultipath/util.h
+index a3ab894..56cec76 100644
+--- a/libmultipath/util.h
++++ b/libmultipath/util.h
+@@ -19,6 +19,7 @@ void setup_thread_attr(pthread_attr_t *attr, size_t stacksize, int detached);
+ int systemd_service_enabled(const char *dev);
+ int get_linux_version_code(void);
+ int parse_prkey(char *ptr, uint64_t *prkey);
++int parse_prkey_flags(char *ptr, uint64_t *prkey, uint8_t *flags);
+ int safe_write(int fd, const void *buf, size_t count);
+ 
+ #define KERNEL_VERSION(maj, min, ptc) ((((maj) * 256) + (min)) * 256 + (ptc))
+diff --git a/multipath/multipath.conf.5 b/multipath/multipath.conf.5
+index 31f4585..30d8598 100644
+--- a/multipath/multipath.conf.5
++++ b/multipath/multipath.conf.5
+@@ -726,14 +726,17 @@ This is the service action reservation key used by mpathpersist. It must be
+ set for all multipath devices using persistent reservations, and it must be
+ the same as the RESERVATION KEY field of the PERSISTENT RESERVE OUT parameter
+ list which contains an 8-byte value provided by the application client to the
+-device server to identify the I_T nexus.
++device server to identify the I_T nexus. If the \fI--param-aptpl\fR option is
++used when registering the key with mpathpersist, \fB:aptpl\fR must be appended
++to the end of the reservation key.
+ .RS
+ .PP
+ Alternatively, this can be set to \fBfile\fR, which will store the RESERVATION
+ KEY registered by mpathpersist in the \fIprkeys_file\fR. multipathd will then
+ use this key to register additional paths as they appear.  When the
+ registration is removed, the RESERVATION KEY is removed from the
+-\fIprkeys_file\fR.
++\fIprkeys_file\fR. The prkeys file will automatically keep track of whether
++the key was registered with \fI--param-aptpl\fR.
+ .TP
+ The default is: \fB<unset>\fR
+ .RE
+diff --git a/multipathd/cli_handlers.c b/multipathd/cli_handlers.c
+index ba50fb8..6452796 100644
+--- a/multipathd/cli_handlers.c
++++ b/multipathd/cli_handlers.c
+@@ -21,6 +21,7 @@
+ #include "sysfs.h"
+ #include <errno.h>
+ #include <libudev.h>
++#include <mpath_persist.h>
+ #include "util.h"
+ #include "prkey.h"
+ #include "propsel.h"
+@@ -1463,6 +1464,7 @@ cli_getprkey(void * v, char ** reply, int * len, void * data)
+ 	struct multipath * mpp;
+ 	struct vectors * vecs = (struct vectors *)data;
+ 	char *mapname = get_keyparam(v, MAP);
++	char *flagstr = "";
+ 
+ 	mapname = convert_dev(mapname, 0);
+ 	condlog(3, "%s: get persistent reservation key (operator)", mapname);
+@@ -1478,8 +1480,10 @@ cli_getprkey(void * v, char ** reply, int * len, void * data)
+ 		*len = strlen(*reply) + 1;
+ 		return 0;
+ 	}
+-	snprintf(*reply, 20, "0x%" PRIx64 "\n",
+-		 get_be64(mpp->reservation_key));
++	if (mpp->sa_flags & MPATH_F_APTPL_MASK)
++		flagstr = ":aptpl";
++	snprintf(*reply, 20, "0x%" PRIx64 "%s\n",
++		 get_be64(mpp->reservation_key), flagstr);
+ 	(*reply)[19] = '\0';
+ 	*len = strlen(*reply) + 1;
+ 	return 0;
+@@ -1503,7 +1507,7 @@ cli_unsetprkey(void * v, char ** reply, int * len, void * data)
+ 
+ 	conf = get_multipath_config();
+ 	pthread_cleanup_push(put_multipath_config, conf);
+-	ret = set_prkey(conf, mpp, 0);
++	ret = set_prkey(conf, mpp, 0, 0);
+ 	pthread_cleanup_pop(1);
+ 
+ 	return ret;
+@@ -1517,6 +1521,7 @@ cli_setprkey(void * v, char ** reply, int * len, void * data)
+ 	char *mapname = get_keyparam(v, MAP);
+ 	char *keyparam = get_keyparam(v, KEY);
+ 	uint64_t prkey;
++	uint8_t flags;
+ 	int ret;
+ 	struct config *conf;
+ 
+@@ -1527,14 +1532,14 @@ cli_setprkey(void * v, char ** reply, int * len, void * data)
+ 	if (!mpp)
+ 		return 1;
+ 
+-	if (parse_prkey(keyparam, &prkey) != 0) {
++	if (parse_prkey_flags(keyparam, &prkey, &flags) != 0) {
+ 		condlog(0, "%s: invalid prkey : '%s'", mapname, keyparam);
+ 		return 1;
+ 	}
+ 
+ 	conf = get_multipath_config();
+ 	pthread_cleanup_push(put_multipath_config, conf);
+-	ret = set_prkey(conf, mpp, prkey);
++	ret = set_prkey(conf, mpp, prkey, flags);
+ 	pthread_cleanup_pop(1);
+ 
+ 	return ret;
+diff --git a/multipathd/main.c b/multipathd/main.c
+index d40c416..6b1e782 100644
+--- a/multipathd/main.c
++++ b/multipathd/main.c
+@@ -3089,6 +3089,7 @@ void *  mpath_pr_event_handler_fn (void * pathp )
+ 
+ 	param= malloc(sizeof(struct prout_param_descriptor));
+ 	memset(param, 0 , sizeof(struct prout_param_descriptor));
++	param->sa_flags = mpp->sa_flags;
+ 	memcpy(param->sa_key, &mpp->reservation_key, 8);
+ 	param->num_transportid = 0;
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0018-multipath-don-t-check-timestamps-without-a-path.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0018-multipath-don-t-check-timestamps-without-a-path.patch
new file mode 100644
index 0000000..5a3fd83
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0018-multipath-don-t-check-timestamps-without-a-path.patch
@@ -0,0 +1,34 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Tue, 5 Jun 2018 15:31:55 -0500
+Subject: [PATCH] multipath: don't check timestamps without a path
+
+If a path was blacklisted, pathvec could exist but have no path in it.
+print_cmd_valid wasn't checking this before calling
+find_multipaths_check_timeout(). This was causing it to dereference a
+NULL pointer in these cases.
+
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ multipath/main.c | 4 +---
+ 1 file changed, 1 insertion(+), 3 deletions(-)
+
+diff --git a/multipath/main.c b/multipath/main.c
+index c69e996..3f0a6aa 100644
+--- a/multipath/main.c
++++ b/multipath/main.c
+@@ -482,10 +482,8 @@ static int print_cmd_valid(int k, const vector pathvec,
+ 			pp, pp->find_multipaths_timeout, &until);
+ 		if (wait != FIND_MULTIPATHS_WAITING)
+ 			k = 1;
+-	} else if (pathvec != NULL) {
+-		pp = VECTOR_SLOT(pathvec, 0);
++	} else if (pathvec != NULL && (pp = VECTOR_SLOT(pathvec, 0)))
+ 		wait = find_multipaths_check_timeout(pp, 0, &until);
+-	}
+ 	if (wait == FIND_MULTIPATHS_WAITING)
+ 		printf("FIND_MULTIPATHS_WAIT_UNTIL=\"%ld.%06ld\"\n",
+ 			       until.tv_sec, until.tv_nsec/1000);
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0019-libmultipath-fix-detect-alua-corner-case.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0019-libmultipath-fix-detect-alua-corner-case.patch
new file mode 100644
index 0000000..23908fa
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0019-libmultipath-fix-detect-alua-corner-case.patch
@@ -0,0 +1,35 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Fri, 8 Jun 2018 17:12:37 -0500
+Subject: [PATCH] libmultipath: fix detect alua corner case
+
+If retain_attach_hw_handler = no, then the paths tpgs state will never
+be checked, and the multipath device will always select the alua
+handler, if no other handler is selected. the paths tpgs state
+should be checked, regardless of the retain_hwhandler value.
+
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/propsel.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/libmultipath/propsel.c b/libmultipath/propsel.c
+index 62a6893..f626c74 100644
+--- a/libmultipath/propsel.c
++++ b/libmultipath/propsel.c
+@@ -403,9 +403,11 @@ int select_hwhandler(struct config *conf, struct multipath *mp)
+ 	bool all_tpgs = true;
+ 
+ 	dh_state = &handler[2];
++
++	vector_foreach_slot(mp->paths, pp, i)
++		all_tpgs = all_tpgs && (pp->tpgs > 0);
+ 	if (mp->retain_hwhandler != RETAIN_HWHANDLER_OFF) {
+ 		vector_foreach_slot(mp->paths, pp, i) {
+-			all_tpgs = all_tpgs && (pp->tpgs > 0);
+ 			if (get_dh_state(pp, dh_state, sizeof(handler) - 2) > 0
+ 			    && strcmp(dh_state, "detached")) {
+ 				memcpy(handler, "1 ", 2);
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0020-multipath-fix-setting-conf-version.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0020-multipath-fix-setting-conf-version.patch
new file mode 100644
index 0000000..624f45e
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0020-multipath-fix-setting-conf-version.patch
@@ -0,0 +1,39 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Fri, 8 Jun 2018 17:23:07 -0500
+Subject: [PATCH] multipath: fix setting conf->version
+
+Commit d3b71498 stopped multipath from setting conf->version. Instead,
+it was always being set to 0.0.0. Multipathd was still setting this
+correctly.
+
+Fixes: d3b71498 "multipath: fix rcu thread cancellation hang"
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/devmapper.c | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/libmultipath/devmapper.c b/libmultipath/devmapper.c
+index f2befad..8136d15 100644
+--- a/libmultipath/devmapper.c
++++ b/libmultipath/devmapper.c
+@@ -245,13 +245,13 @@ void libmp_dm_init(void)
+ 	int verbosity;
+ 	unsigned int version[3];
+ 
++	if (dm_prereq(version))
++		exit(1);
+ 	conf = get_multipath_config();
+ 	verbosity = conf->verbosity;
+-	memcpy(version, conf->version, sizeof(version));
++	memcpy(conf->version, version, sizeof(version));
+ 	put_multipath_config(conf);
+ 	dm_init(verbosity);
+-	if (dm_prereq(version))
+-		exit(1);
+ 	dm_udev_set_sync_support(libmp_dm_udev_sync);
+ }
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0021-RH-fixup-udev-rules-for-redhat.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0021-RH-fixup-udev-rules-for-redhat.patch
new file mode 100644
index 0000000..4ef3e70
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0021-RH-fixup-udev-rules-for-redhat.patch
@@ -0,0 +1,82 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Thu, 13 Apr 2017 07:22:23 -0500
+Subject: [PATCH] RH: fixup udev rules for redhat
+
+The multipath rules need to run after scsi_id is run. This means moving
+them after 60-persistent-storage.rules for redhat. Redhat also uses a
+different naming scheme for partitions than SuSE. Also, there are some
+false warnings that gcc throws because of the changed options. Fix these
+too.
+
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ Makefile.inc        | 2 +-
+ kpartx/kpartx.rules | 2 +-
+ multipath/Makefile  | 4 ++--
+ multipath/main.c    | 2 +-
+ 4 files changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/Makefile.inc b/Makefile.inc
+index af2f5ba..0b271ea 100644
+--- a/Makefile.inc
++++ b/Makefile.inc
+@@ -51,7 +51,7 @@ endif
+ prefix		=
+ exec_prefix	= $(prefix)
+ usr_prefix	= $(prefix)
+-bindir		= $(exec_prefix)/sbin
++bindir		= $(exec_prefix)/usr/sbin
+ libudevdir	= $(prefix)/$(SYSTEMDPATH)/udev
+ udevrulesdir	= $(libudevdir)/rules.d
+ multipathdir	= $(TOPDIR)/libmultipath
+diff --git a/kpartx/kpartx.rules b/kpartx/kpartx.rules
+index 8f99049..8a3a171 100644
+--- a/kpartx/kpartx.rules
++++ b/kpartx/kpartx.rules
+@@ -32,6 +32,6 @@ LABEL="mpath_kpartx_end"
+ GOTO="kpartx_end"
+ 
+ LABEL="run_kpartx"
+-RUN+="/sbin/kpartx -un -p -part /dev/$name"
++RUN+="/sbin/kpartx -un /dev/$name"
+ 
+ LABEL="kpartx_end"
+diff --git a/multipath/Makefile b/multipath/Makefile
+index 0828a8f..b9bbb3c 100644
+--- a/multipath/Makefile
++++ b/multipath/Makefile
+@@ -24,7 +24,7 @@ install:
+ 	$(INSTALL_PROGRAM) -m 755 $(EXEC) $(DESTDIR)$(bindir)/
+ 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(udevrulesdir)
+ 	$(INSTALL_PROGRAM) -m 644 11-dm-mpath.rules $(DESTDIR)$(udevrulesdir)
+-	$(INSTALL_PROGRAM) -m 644 $(EXEC).rules $(DESTDIR)$(libudevdir)/rules.d/56-multipath.rules
++	$(INSTALL_PROGRAM) -m 644 $(EXEC).rules $(DESTDIR)$(libudevdir)/rules.d/62-multipath.rules
+ 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(man8dir)
+ 	$(INSTALL_PROGRAM) -m 644 $(EXEC).8.gz $(DESTDIR)$(man8dir)
+ 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(man5dir)
+@@ -33,7 +33,7 @@ install:
+ uninstall:
+ 	$(RM) $(DESTDIR)$(bindir)/$(EXEC)
+ 	$(RM) $(DESTDIR)$(udevrulesdir)/11-dm-mpath.rules
+-	$(RM) $(DESTDIR)$(libudevdir)/rules.d/56-multipath.rules
++	$(RM) $(DESTDIR)$(libudevdir)/rules.d/62-multipath.rules
+ 	$(RM) $(DESTDIR)$(man8dir)/$(EXEC).8.gz
+ 	$(RM) $(DESTDIR)$(man5dir)/$(EXEC).conf.5.gz
+ 
+diff --git a/multipath/main.c b/multipath/main.c
+index 3f0a6aa..6fdde03 100644
+--- a/multipath/main.c
++++ b/multipath/main.c
+@@ -389,7 +389,7 @@ static int find_multipaths_check_timeout(const struct path *pp, long tmo,
+ 	struct timespec now, ftimes[2], tdiff;
+ 	struct stat st;
+ 	long fd;
+-	int r, err, retries = 0;
++	int r, err = 0, retries = 0;
+ 
+ 	clock_gettime(CLOCK_REALTIME, &now);
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0022-RH-Remove-the-property-blacklist-exception-builtin.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0022-RH-Remove-the-property-blacklist-exception-builtin.patch
new file mode 100644
index 0000000..451c524
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0022-RH-Remove-the-property-blacklist-exception-builtin.patch
@@ -0,0 +1,87 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Wed, 2 Jul 2014 12:49:53 -0500
+Subject: [PATCH] RH: Remove the property blacklist exception builtin
+
+Multipath set the default property blacklist exceptions to
+(ID_SCSI_VPD|ID_WWN).  This has the effect of blacklisting some internal
+devices.  These devices may never have multiple paths, but it is nice
+to be able to set multipath up on them all the same.  This patch simply
+removes the default, and makes it so that if no property
+blacklist_exception is given, then devices aren't failed for not matching
+it.
+
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/blacklist.c   | 15 ++++++---------
+ multipath/multipath.conf.5 | 14 ++++++++------
+ 2 files changed, 14 insertions(+), 15 deletions(-)
+
+diff --git a/libmultipath/blacklist.c b/libmultipath/blacklist.c
+index ee396e2..19d4697 100644
+--- a/libmultipath/blacklist.c
++++ b/libmultipath/blacklist.c
+@@ -181,12 +181,6 @@ setup_default_blist (struct config * conf)
+ 	if (store_ble(conf->blist_devnode, str, ORIGIN_DEFAULT))
+ 		return 1;
+ 
+-	str = STRDUP("(SCSI_IDENT_|ID_WWN)");
+-	if (!str)
+-		return 1;
+-	if (store_ble(conf->elist_property, str, ORIGIN_DEFAULT))
+-		return 1;
+-
+ 	vector_foreach_slot (conf->hwtable, hwe, i) {
+ 		if (hwe->bl_product) {
+ 			if (_blacklist_device(conf->blist_device, hwe->vendor,
+@@ -390,9 +384,12 @@ filter_property(struct config * conf, struct udev_device * udev)
+ 	 * This is the inverse of the 'normal' matching;
+ 	 * the environment variable _has_ to match.
+ 	 */
+-	log_filter(devname, NULL, NULL, NULL, NULL,
+-		   MATCH_PROPERTY_BLIST_MISSING);
+-	return MATCH_PROPERTY_BLIST_MISSING;
++	if (VECTOR_SIZE(conf->elist_property)) {
++		log_filter(devname, NULL, NULL, NULL, NULL,
++			   MATCH_PROPERTY_BLIST_MISSING);
++		return MATCH_PROPERTY_BLIST_MISSING;
++	}
++	return 0;
+ }
+ 
+ void
+diff --git a/multipath/multipath.conf.5 b/multipath/multipath.conf.5
+index 30d8598..c45da9f 100644
+--- a/multipath/multipath.conf.5
++++ b/multipath/multipath.conf.5
+@@ -1179,10 +1179,6 @@ The \fIWorld Wide Identification\fR of a device.
+ .TP
+ .B property
+ Regular expression of the udev property to be whitelisted.
+-.RS
+-.TP
+-The default is: \fB(SCSI_IDENT_|ID_WWN)\fR
+-.RE
+ .TP
+ .B device
+ Subsection for the device description. This subsection recognizes the
+@@ -1193,8 +1189,14 @@ keywords. For a full description of these keywords please see the \fIdevices\fR
+ section description.
+ .LP
+ The \fIproperty\fR whitelist handling is different from the usual
+-handling in the sense that the device \fIhas\fR to have a udev property that
+-matches the whitelist, otherwise the device will be blacklisted. In these cases the message \fIblacklisted, udev property missing\fR will be displayed.
++handling in the sense that if the propery whitelist is set, the device
++\fIhas\fR to have a udev property that matches the whitelist, otherwise the
++device will be blacklisted. In these cases the message \fIblacklisted, udev
++property missing\fR will be displayed. For example settting the
++property blacklist_exception to \fB(SCSI_IDENT_|ID_WWN)\fR will blacklist
++all devices that have no udev property whose name regex matches either
++\fBSCSI_IDENT_\fR or \fBID_WWN\fR. This works to exclude most
++non-multipathable devices.
+ .
+ .
+ .\" ----------------------------------------------------------------------------
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0023-RH-don-t-start-without-a-config-file.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0023-RH-don-t-start-without-a-config-file.patch
new file mode 100644
index 0000000..886f1c8
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0023-RH-don-t-start-without-a-config-file.patch
@@ -0,0 +1,106 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Wed, 15 Oct 2014 10:39:30 -0500
+Subject: [PATCH] RH: don't start without a config file
+
+If /etc/multipath.conf doesn't exist, don't start multipathd and blacklist
+all devices when running multipath.  A completely blank configuration file
+is almost never what users want.  Also, people may have the multipath
+packages installed but don't want to use them.  This patch provides a
+simple way to disable multipath.  Simply removing or renaming
+/etc/multipath.conf will keep multipath from doing anything.
+
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/config.c         | 15 +++++++++++++++
+ libmultipath/config.h         |  1 +
+ multipath/multipath.rules     |  1 +
+ multipathd/multipathd.8       |  2 ++
+ multipathd/multipathd.service |  1 +
+ 5 files changed, 20 insertions(+)
+
+diff --git a/libmultipath/config.c b/libmultipath/config.c
+index 5872927..0607403 100644
+--- a/libmultipath/config.c
++++ b/libmultipath/config.c
+@@ -26,6 +26,7 @@
+ #include "devmapper.h"
+ #include "mpath_cmd.h"
+ #include "propsel.h"
++#include "version.h"
+ 
+ static int
+ hwe_strmatch (struct hwentry *hwe1, struct hwentry *hwe2)
+@@ -658,6 +659,20 @@ load_config (char * file)
+ 			factorize_hwtable(conf->hwtable, builtin_hwtable_size);
+ 		}
+ 
++	} else {
++		condlog(0, "/etc/multipath.conf does not exist, blacklisting all devices.");
++		if (conf->blist_devnode == NULL) {
++			conf->blist_devnode = vector_alloc();
++			if (!conf->blist_devnode) {
++				condlog(0, "cannot allocate blacklist\n");
++				goto out;
++			}
++		}
++		if (store_ble(conf->blist_devnode, strdup(".*"),
++		              ORIGIN_NO_CONFIG)) {
++			condlog(0, "cannot store default no-config blacklist\n");
++			goto out;
++		}
+ 	}
+ 
+ 	conf->processed_main_config = 1;
+diff --git a/libmultipath/config.h b/libmultipath/config.h
+index fcbe3fc..3a42435 100644
+--- a/libmultipath/config.h
++++ b/libmultipath/config.h
+@@ -9,6 +9,7 @@
+ 
+ #define ORIGIN_DEFAULT 0
+ #define ORIGIN_CONFIG  1
++#define ORIGIN_NO_CONFIG 2
+ 
+ /*
+  * In kernel, fast_io_fail == 0 means immediate failure on rport delete.
+diff --git a/multipath/multipath.rules b/multipath/multipath.rules
+index d658073..b3f54d7 100644
+--- a/multipath/multipath.rules
++++ b/multipath/multipath.rules
+@@ -9,6 +9,7 @@ IMPORT{cmdline}="nompath"
+ ENV{nompath}=="?*", GOTO="end_mpath"
+ IMPORT{cmdline}="multipath"
+ ENV{multipath}=="off", GOTO="end_mpath"
++TEST!="/etc/multipath.conf", GOTO="end_mpath"
+ 
+ ENV{DEVTYPE}!="partition", GOTO="test_dev"
+ IMPORT{parent}="DM_MULTIPATH_DEVICE_PATH"
+diff --git a/multipathd/multipathd.8 b/multipathd/multipathd.8
+index e78ac9e..09cdead 100644
+--- a/multipathd/multipathd.8
++++ b/multipathd/multipathd.8
+@@ -38,6 +38,8 @@ map regains its maximum performance and redundancy.
+ This daemon executes the external \fBmultipath\fR tool when events occur.
+ In turn, the multipath tool signals the multipathd daemon when it is done with
+ devmap reconfiguration, so that it can refresh its failed path list.
++
++In this Linux distribution, multipathd does not run unless a /etc/multipath.conf file exists.
+ .
+ .
+ .\" ----------------------------------------------------------------------------
+diff --git a/multipathd/multipathd.service b/multipathd/multipathd.service
+index ba24983..17434ce 100644
+--- a/multipathd/multipathd.service
++++ b/multipathd/multipathd.service
+@@ -4,6 +4,7 @@ Wants=systemd-udev-trigger.service systemd-udev-settle.service
+ Before=iscsi.service iscsid.service lvm2-activation-early.service
+ Before=local-fs-pre.target blk-availability.service
+ After=multipathd.socket systemd-udev-trigger.service systemd-udev-settle.service
++ConditionPathExists=/etc/multipath.conf
+ DefaultDependencies=no
+ Conflicts=shutdown.target
+ ConditionKernelCommandLine=!nompath
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0024-RH-use-rpm-optflags-if-present.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0024-RH-use-rpm-optflags-if-present.patch
new file mode 100644
index 0000000..9330bf0
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0024-RH-use-rpm-optflags-if-present.patch
@@ -0,0 +1,52 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Wed, 19 Apr 2017 06:10:01 -0500
+Subject: [PATCH] RH: use rpm optflags if present
+
+Use the passed in optflags when compiling as an RPM, and keep the
+default flags as close as possible to the current fedora flags, while
+still being generic.
+
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ Makefile.inc | 24 ++++++++++++++++--------
+ 1 file changed, 16 insertions(+), 8 deletions(-)
+
+diff --git a/Makefile.inc b/Makefile.inc
+index 0b271ea..5ff69a3 100644
+--- a/Makefile.inc
++++ b/Makefile.inc
+@@ -85,14 +85,22 @@ TEST_CC_OPTION = $(shell \
+ 		echo "$(2)"; \
+ 	fi)
+ 
+-STACKPROT := $(call TEST_CC_OPTION,-fstack-protector-strong,-fstack-protector)
+-
+-OPTFLAGS	= -O2 -g -pipe -Wall -Wextra -Wformat=2 -Werror=implicit-int \
+-		  -Werror=implicit-function-declaration -Werror=format-security \
+-		  -Wno-sign-compare -Wno-unused-parameter -Wno-clobbered \
+-		  -Werror=cast-qual -Werror=discarded-qualifiers \
+-		  -Wp,-D_FORTIFY_SOURCE=2 $(STACKPROT) \
+-		  --param=ssp-buffer-size=4
++ifndef RPM_OPT_FLAGS
++	STACKPROT := $(call TEST_CC_OPTION,-fstack-protector-strong,-fstack-protector)
++	OPTFLAGS	= -O2 -g -pipe -Wall -Werror=format-security \
++			  -Wp,-D_FORTIFY_SOURCE=2 -fexceptions \
++			  $(STACKPROT) --param=ssp-buffer-size=4 \
++			  -grecord-gcc-switches
++	ifeq ($(shell test -f /usr/lib/rpm/redhat/redhat-hardened-cc1 && echo 1),1)
++		OPTFLAGS += -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1
++	endif
++else
++	OPTFLAGS = $(RPM_OPT_FLAGS)
++endif
++OPTFLAGS	+= -Wextra -Wstrict-prototypes -Wformat=2 -Werror=implicit-int \
++		   -Werror=implicit-function-declaration -Wno-sign-compare \
++		   -Wno-unused-parameter -Werror=cast-qual \
++		   -Werror=discarded-qualifiers
+ 
+ CFLAGS		:= $(OPTFLAGS) -DBIN_DIR=\"$(bindir)\" -DLIB_STRING=\"${LIB}\" -DRUN_DIR=\"${RUN}\" \
+ 		   -MMD -MP $(CFLAGS)
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0025-RH-add-mpathconf.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0025-RH-add-mpathconf.patch
new file mode 100644
index 0000000..5cad22b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0025-RH-add-mpathconf.patch
@@ -0,0 +1,648 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Thu, 16 Oct 2014 15:49:01 -0500
+Subject: [PATCH] RH: add mpathconf
+
+mpathconf is a program (largely based on lvmcomf) to help users
+configure /etc/multipath.conf and enable or disable multipathing.  It
+has a couple of built-in options that can be set directly from the
+command line.  But, mostly it is used to get a multipath.conf file
+with the OS defaults, and to enable and disable multipathing via
+a single command.
+
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/config.c |   1 +
+ multipath/Makefile    |   5 +
+ multipath/mpathconf   | 464 ++++++++++++++++++++++++++++++++++++++++++++++++++
+ multipath/mpathconf.8 | 101 +++++++++++
+ 4 files changed, 571 insertions(+)
+ create mode 100644 multipath/mpathconf
+ create mode 100644 multipath/mpathconf.8
+
+diff --git a/libmultipath/config.c b/libmultipath/config.c
+index 0607403..5c98e48 100644
+--- a/libmultipath/config.c
++++ b/libmultipath/config.c
+@@ -661,6 +661,7 @@ load_config (char * file)
+ 
+ 	} else {
+ 		condlog(0, "/etc/multipath.conf does not exist, blacklisting all devices.");
++		condlog(0, "You can run /sbin/mpathconf to create or modify /etc/multipath.conf");
+ 		if (conf->blist_devnode == NULL) {
+ 			conf->blist_devnode = vector_alloc();
+ 			if (!conf->blist_devnode) {
+diff --git a/multipath/Makefile b/multipath/Makefile
+index b9bbb3c..e720c7f 100644
+--- a/multipath/Makefile
++++ b/multipath/Makefile
+@@ -18,10 +18,12 @@ $(EXEC): $(OBJS) $(multipathdir)/libmultipath.so $(mpathcmddir)/libmpathcmd.so
+ 	$(CC) $(CFLAGS) $(OBJS) -o $(EXEC) $(LDFLAGS) $(LIBDEPS)
+ 	$(GZIP) $(EXEC).8 > $(EXEC).8.gz
+ 	$(GZIP) $(EXEC).conf.5 > $(EXEC).conf.5.gz
++	$(GZIP) mpathconf.8 > mpathconf.8.gz
+ 
+ install:
+ 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(bindir)
+ 	$(INSTALL_PROGRAM) -m 755 $(EXEC) $(DESTDIR)$(bindir)/
++	$(INSTALL_PROGRAM) -m 755 mpathconf $(DESTDIR)$(bindir)/
+ 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(udevrulesdir)
+ 	$(INSTALL_PROGRAM) -m 644 11-dm-mpath.rules $(DESTDIR)$(udevrulesdir)
+ 	$(INSTALL_PROGRAM) -m 644 $(EXEC).rules $(DESTDIR)$(libudevdir)/rules.d/62-multipath.rules
+@@ -29,13 +31,16 @@ install:
+ 	$(INSTALL_PROGRAM) -m 644 $(EXEC).8.gz $(DESTDIR)$(man8dir)
+ 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(man5dir)
+ 	$(INSTALL_PROGRAM) -m 644 $(EXEC).conf.5.gz $(DESTDIR)$(man5dir)
++	$(INSTALL_PROGRAM) -m 644 mpathconf.8.gz $(DESTDIR)$(man8dir)
+ 
+ uninstall:
+ 	$(RM) $(DESTDIR)$(bindir)/$(EXEC)
+ 	$(RM) $(DESTDIR)$(udevrulesdir)/11-dm-mpath.rules
+ 	$(RM) $(DESTDIR)$(libudevdir)/rules.d/62-multipath.rules
++	$(RM) $(DESTDIR)$(bindir)/mpathconf
+ 	$(RM) $(DESTDIR)$(man8dir)/$(EXEC).8.gz
+ 	$(RM) $(DESTDIR)$(man5dir)/$(EXEC).conf.5.gz
++	$(RM) $(DESTDIR)$(man8dir)/mpathconf.8.gz
+ 
+ clean: dep_clean
+ 	$(RM) core *.o $(EXEC) *.gz
+diff --git a/multipath/mpathconf b/multipath/mpathconf
+new file mode 100644
+index 0000000..e839134
+--- /dev/null
++++ b/multipath/mpathconf
+@@ -0,0 +1,464 @@
++#!/bin/bash
++#
++# Copyright (C) 2010 Red Hat, Inc. All rights reserved.
++#
++# This file is part of the device-mapper-multipath package.
++#
++# This copyrighted material is made available to anyone wishing to use,
++# modify, copy, or redistribute it subject to the terms and conditions
++# of the GNU General Public License v.2.
++#
++# You should have received a copy of the GNU General Public License
++# along with this program; if not, write to the Free Software Foundation,
++# Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
++
++#
++# Simple editting of /etc/multipath.conf
++# This program was largely ripped off from lvmconf
++#
++
++unset ENABLE FIND FRIENDLY MODULE MULTIPATHD HAVE_DISABLE HAVE_WWID_DISABLE HAVE_FIND HAVE_BLACKLIST HAVE_EXCEPTIONS HAVE_DEFAULTS HAVE_FRIENDLY HAVE_MULTIPATHD HAVE_MODULE HAVE_OUTFILE SHOW_STATUS CHANGED_CONFIG WWID_LIST
++
++DEFAULT_CONFIG="# device-mapper-multipath configuration file
++
++# For a complete list of the default configuration values, run either:
++# # multipath -t
++# or
++# # multipathd show config
++
++# For a list of configuration options with descriptions, see the
++# multipath.conf man page.
++
++defaults {
++	user_friendly_names yes
++	find_multipaths yes
++}
++
++blacklist_exceptions {
++        property \"(SCSI_IDENT_|ID_WWN)\"
++}"
++
++CONFIGFILE="/etc/multipath.conf"
++OUTPUTFILE="/etc/multipath.conf"
++MULTIPATHDIR="/etc/multipath"
++TMPFILE="/etc/multipath/.multipath.conf.tmp"
++WWIDS=0
++
++function usage
++{
++	echo "usage: $0 <command>"
++	echo ""
++	echo "Commands:"
++	echo "Enable: --enable "
++	echo "Disable: --disable"
++	echo "Only allow certain wwids (instead of enable): --allow <WWID>"
++	echo "Set user_friendly_names (Default y): --user_friendly_names <y|n>"
++	echo "Set find_multipaths (Default y): --find_multipaths <y|n>"
++	echo "Load the dm-multipath modules on enable (Default y): --with_module <y|n>"
++	echo "start/stop/reload multipathd (Default n): --with_multipathd <y|n>"
++	echo "select output file (Default /etc/multipath.conf): --outfile <FILE>"
++	echo ""
++}
++
++function add_wwid
++{
++	INDEX=0
++	while [ "$INDEX" -lt "$WWIDS" ] ; do
++		if [ "$1" = "${WWID_LIST[$INDEX]}" ] ; then
++			return
++		fi
++		((INDEX++))
++	done
++	WWID_LIST[$WWIDS]="$1"
++	((WWIDS++))
++}
++
++function get_dm_deps
++{
++	shift 3
++	while [ -n "$1" -a -n "$2" ]; do
++		MAJOR=$(echo $1 | tr -d '(,')
++		MINOR=$(echo $2 | tr -d ')')
++		UUID=`dmsetup info -c --noheadings -o uuid -j $MAJOR -m $MINOR  2> /dev/null`
++		if [ -n "$UUID" ] ; then
++			set_dm_wwid $UUID
++		fi
++		shift 2
++	done
++}
++
++function set_dm_wwid
++{
++	if [[ "$1" =~ ^part[[:digit:]]+-mpath- ]] ; then
++		add_wwid "${1##part*-mpath-}"
++	elif [[ "$1" =~ ^mpath- ]] ; then
++		add_wwid "${1##mpath-}"
++	else
++		get_dm_deps `dmsetup deps -u $1`
++	fi
++}
++
++function set_wwid
++{
++	UUID=""
++	if [[ "$1" =~ ^[[:digit:]]+:[[:digit:]]+$ ]] ; then
++		MAJOR=${1%%:*}
++		MINOR=${1##*:}
++		UUID=`dmsetup info -c --noheadings -o uuid -j $MAJOR -m $MINOR  2> /dev/null`
++	else
++		UUID=`dmsetup info -c --noheadings -o uuid $1 2> /dev/null`
++	fi
++	if [ -n "$UUID" ] ; then
++		set_dm_wwid $UUID
++	else
++		add_wwid "$1"
++	fi
++}
++
++function parse_args
++{
++	while [ -n "$1" ]; do
++		case $1 in
++			--enable)
++				ENABLE=1
++				shift
++				;;
++			--disable)
++				ENABLE=0
++				shift
++				;;
++			--allow)
++				ENABLE=2
++				if [ -n "$2" ]; then
++					set_wwid $2
++					shift 2
++				else
++					usage
++					exit 1
++				fi
++				;;
++			--user_friendly_names)
++				if [ -n "$2" ]; then
++					FRIENDLY=$2
++					shift 2
++				else
++					usage
++					exit 1
++				fi
++				;;
++			--find_multipaths)
++				if [ -n "$2" ]; then
++					FIND=$2
++					shift 2
++				else
++					usage
++					exit 1
++				fi
++				;;
++			--with_module)
++				if [ -n "$2" ]; then
++					MODULE=$2
++					shift 2
++				else
++					usage
++					exit 1
++				fi
++				;;
++			--with_multipathd)
++				if [ -n "$2" ]; then
++					MULTIPATHD=$2
++					shift 2
++				else
++					usage
++					exit 1
++				fi
++				;;
++			--outfile)
++				if [ -n "$2" ]; then
++					OUTPUTFILE=$2
++					HAVE_OUTFILE=1
++					shift 2
++				else
++					usage
++					exit 1
++				fi
++				;;
++			*)
++				usage
++				exit
++		esac
++	done
++}
++
++function validate_args
++{
++	if [ "$ENABLE" = "0" ] && [ -n "$FRIENDLY" -o -n "$FIND" -o -n "$MODULE" ]; then
++		echo "ignoring extra parameters on disable"
++		FRIENDLY=""
++		FIND=""
++		MODULE=""
++	fi
++	if [ -n "$FRIENDLY" ] && [ "$FRIENDLY" != "y" -a "$FRIENDLY" != "n" ]; then
++		echo "--user_friendly_names must be either 'y' or 'n'"
++		exit 1
++	fi
++	if [ -n "$FIND" ] && [ "$FIND" != "y" -a "$FIND" != "n" ]; then
++		echo "--find_multipaths must be either 'y' or 'n'"
++		exit 1
++	fi
++	if [ -z "$ENABLE" -a -z "$FIND" -a -z "$FRIENDLY" ]; then
++		SHOW_STATUS=1
++	fi
++	if [ -n "$MODULE" ] && [ "$MODULE" != "y" -a "$MODULE" != "n" ]; then
++		echo "--with_module must be either 'y' or 'n'"
++		exit 1
++	fi
++	if [ -n "$MULTIPATHD" ] && [ "$MULTIPATHD" != "y" -a "$MULTIPATHD" != "n" ]; then
++		echo "--with_multipathd must be either 'y' or 'n'"
++		exit 1
++	fi
++	if [ "$ENABLE" = 2 -a -z "$HAVE_OUTFILE" ]; then
++		echo "Because --allow makes changes that cannot be automatically reversed,"
++		echo "you must set --outfile when you set --allow"
++		exit 1
++	fi
++}
++
++function add_blacklist_exceptions
++{
++	INDEX=0
++	while [ "$INDEX" -lt "$WWIDS" ] ; do
++		sed -i '/^blacklist_exceptions[[:space:]]*{/ a\
++	wwid '"\"${WWID_LIST[$INDEX]}\""'
++' $TMPFILE
++		((INDEX++))
++	done
++}
++
++umask 0077
++
++parse_args "$@"
++
++validate_args
++
++if [ ! -d "$MULTIPATHDIR" ]; then
++	echo "/etc/multipath/ does not exist. failing"
++	exit 1
++fi
++
++rm $TMPFILE 2> /dev/null
++echo "$DEFAULT_CONFIG" > $TMPFILE
++if [ -f "$CONFIGFILE" ]; then
++	cp $CONFIGFILE $TMPFILE
++fi
++
++if grep -q "^blacklist[[:space:]]*{" $TMPFILE ; then
++	HAVE_BLACKLIST=1
++fi
++
++if grep -q "^blacklist_exceptions[[:space:]]*{" $TMPFILE ; then
++	HAVE_EXCEPTIONS=1
++fi
++
++if grep -q "^defaults[[:space:]]*{" $TMPFILE ; then
++	HAVE_DEFAULTS=1
++fi
++
++if [ -z "$MODULE" -o "$MODULE" = "y" ]; then
++	if lsmod | grep -q "dm_multipath" ; then
++		HAVE_MODULE=1
++	else
++		HAVE_MODULE=0
++	fi
++fi
++
++if [ "$MULTIPATHD" = "y" ]; then
++	if /bin/systemctl status multipathd.service > /dev/null 2>&1 ; then
++		HAVE_MULTIPATHD=1
++	else
++		HAVE_MULTIPATHD=0
++	fi
++fi
++
++if [ "$HAVE_BLACKLIST" = "1" ]; then
++	if sed -n '/^blacklist[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*devnode \"\.\?\*\"" ; then
++		HAVE_DISABLE=1
++	elif sed -n '/^blacklist[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*#[[:space:]]*devnode \"\.\?\*\"" ; then
++		HAVE_DISABLE=0
++	fi
++fi
++
++if [ "$HAVE_BLACKLIST" = "1" ]; then
++	if sed -n '/^blacklist[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*wwid \"\.\?\*\"" ; then
++		HAVE_WWID_DISABLE=1
++	elif sed -n '/^blacklist[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*#[[:space:]]*wwid \"\.\?\*\"" ; then
++		HAVE_WWID_DISABLE=0
++	fi
++fi
++
++if [ "$HAVE_DEFAULTS" = "1" ]; then
++	if sed -n '/^defaults[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*find_multipaths[[:space:]]*\(yes\|1\)" ; then
++		HAVE_FIND=1
++	elif sed -n '/^defaults[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*find_multipaths[[:space:]]*\(no\|0\)" ; then
++		HAVE_FIND=0
++	fi
++	if sed -n '/^defaults[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*user_friendly_names[[:space:]]*\(yes\|1\)" ; then
++		HAVE_FRIENDLY=1
++	elif sed -n '/^defaults[[:space:]]*{/,/^}/ p' $TMPFILE | grep -q "^[[:space:]]*user_friendly_names[[:space:]]*\(no\|0\)" ; then
++		HAVE_FRIENDLY=0
++	fi
++fi
++
++if [ -n "$SHOW_STATUS" ]; then
++	if [ -z "$HAVE_DISABLE" -o "$HAVE_DISABLE" = 0 ]; then
++		echo "multipath is enabled"
++	else
++		echo "multipath is disabled"
++	fi
++	if [ -z "$HAVE_FIND"  -o "$HAVE_FIND" = 0 ]; then
++		echo "find_multipaths is disabled"
++	else
++		echo "find_multipaths is enabled"
++	fi
++	if [ -z "$HAVE_FRIENDLY" -o "$HAVE_FRIENDLY" = 0 ]; then
++		echo "user_friendly_names is disabled"
++	else
++		echo "user_friendly_names is enabled"
++	fi
++	if [ -n "$HAVE_MODULE" ]; then
++		if [ "$HAVE_MODULE" = 1 ]; then
++			echo "dm_multipath module is loaded"
++		else
++			echo "dm_multipath module is not loaded"
++		fi
++	fi
++	if [ -z "$HAVE_MULTIPATHD" ]; then
++		if /bin/systemctl status multipathd.service > /dev/null 2>&1 ; then
++			HAVE_MULTIPATHD=1
++		else
++			HAVE_MULTIPATHD=0
++		fi
++	fi
++	if [ "$HAVE_MULTIPATHD" = 1 ]; then
++		echo "multipathd is running"
++	else
++		echo "multipathd is not running"
++	fi
++	exit 0
++fi
++
++if [ -z "$HAVE_BLACKLIST" ]; then
++	cat >> $TMPFILE <<- _EOF_
++
++blacklist {
++}
++_EOF_
++fi
++
++if [ -z "$HAVE_DEFAULTS" ]; then
++	cat >> $TMPFILE <<- _EOF_
++
++defaults {
++}
++_EOF_
++fi
++
++if [ "$ENABLE" = 2 ]; then
++	if [ "$HAVE_DISABLE" = 1 ]; then
++		sed -i '/^blacklist[[:space:]]*{/,/^}/ s/^[[:space:]]*devnode \"\.\?\*\"/#	devnode ".*"/' $TMPFILE
++	fi
++	if [ -z "$HAVE_WWID_DISABLE" ]; then
++		sed -i '/^blacklist[[:space:]]*{/ a\
++	wwid ".*"
++' $TMPFILE
++	elif [ "$HAVE_WWID_DISABLE" = 0 ]; then
++		sed -i '/^blacklist[[:space:]]*{/,/^}/ s/^[[:space:]]*#[[:space:]]*wwid \"\.\?\*\"/	wwid ".*"/' $TMPFILE
++	fi
++	if [ "$HAVE_EXCEPTIONS" = 1 ]; then
++		sed -i '/^blacklist_exceptions[[:space:]]*{/,/^}/ {/^[[:space:]]*wwid/ d}' $TMPFILE
++	else
++		cat >> $TMPFILE <<- _EOF_
++
++blacklist_exceptions {
++}
++_EOF_
++	fi
++	add_blacklist_exceptions
++elif [ "$ENABLE" = 1 ]; then
++	if [ "$HAVE_DISABLE" = 1 ]; then
++		sed -i '/^blacklist[[:space:]]*{/,/^}/ s/^[[:space:]]*devnode \"\.\?\*\"/#	devnode ".*"/' $TMPFILE
++	fi
++elif [ "$ENABLE" = 0 ]; then
++	if [ -z "$HAVE_DISABLE" ]; then
++		sed -i '/^blacklist[[:space:]]*{/ a\
++	devnode ".*"
++' $TMPFILE
++	elif [ "$HAVE_DISABLE" = 0 ]; then
++		sed -i '/^blacklist[[:space:]]*{/,/^}/ s/^[[:space:]]*#[[:space:]]*devnode \"\.\?\*\"/	devnode ".*"/' $TMPFILE
++	fi
++fi
++
++if [ "$FIND" = "n" ]; then
++	if [ "$HAVE_FIND" = 1 ]; then
++		sed -i '/^defaults[[:space:]]*{/,/^}/ s/^[[:space:]]*find_multipaths[[:space:]]*\(yes\|1\)/	find_multipaths no/' $TMPFILE
++		CHANGED_CONFIG=1
++	fi
++elif [ "$FIND" = "y" ]; then
++	if [ -z "$HAVE_FIND" ]; then
++		sed -i '/^defaults[[:space:]]*{/ a\
++	find_multipaths yes
++' $TMPFILE
++		CHANGED_CONFIG=1
++	elif [ "$HAVE_FIND" = 0 ]; then
++		sed -i '/^defaults[[:space:]]*{/,/^}/ s/^[[:space:]]*find_multipaths[[:space:]]*\(no\|0\)/	find_multipaths yes/' $TMPFILE
++		CHANGED_CONFIG=1
++	fi
++fi
++
++if [ "$FRIENDLY" = "n" ]; then
++	if [ "$HAVE_FRIENDLY" = 1 ]; then
++		sed -i '/^defaults[[:space:]]*{/,/^}/ s/^[[:space:]]*user_friendly_names[[:space:]]*\(yes\|1\)/	user_friendly_names no/' $TMPFILE
++		CHANGED_CONFIG=1
++	fi
++elif [ "$FRIENDLY" = "y" ]; then
++	if [ -z "$HAVE_FRIENDLY" ]; then
++		sed -i '/^defaults[[:space:]]*{/ a\
++	user_friendly_names yes
++' $TMPFILE
++		CHANGED_CONFIG=1
++	elif [ "$HAVE_FRIENDLY" = 0 ]; then
++		sed -i '/^defaults[[:space:]]*{/,/^}/ s/^[[:space:]]*user_friendly_names[[:space:]]*\(no\|0\)/	user_friendly_names yes/' $TMPFILE
++		CHANGED_CONFIG=1
++	fi
++fi
++
++if [ -f "$OUTPUTFILE" ]; then
++	cp $OUTPUTFILE $OUTPUTFILE.old
++	if [ $? != 0 ]; then
++		echo "failed to backup old config file, $OUTPUTFILE not updated"
++		exit 1
++	fi
++fi
++
++cp $TMPFILE $OUTPUTFILE
++if [ $? != 0 ]; then
++	echo "failed to copy new config file into place, check $OUTPUTFILE is still OK"
++	exit 1
++fi
++
++rm -f $TMPFILE
++
++if [ "$ENABLE" = 1 ]; then
++	if [ "$HAVE_MODULE" = 0 ]; then
++		modprobe dm_multipath
++	fi
++	if [ "$HAVE_MULTIPATHD" = 0 ]; then
++		systemctl start multipathd.service
++	fi
++elif [ "$ENABLE" = 0 ]; then
++	if [ "$HAVE_MULTIPATHD" = 1 ]; then
++		systemctl stop multipathd.service
++	fi
++elif [ -n "$CHANGED_CONFIG" -a "$HAVE_MULTIPATHD" = 1 ]; then
++	systemctl reload multipathd.service
++fi
+diff --git a/multipath/mpathconf.8 b/multipath/mpathconf.8
+new file mode 100644
+index 0000000..4cd3267
+--- /dev/null
++++ b/multipath/mpathconf.8
+@@ -0,0 +1,101 @@
++.TH MPATHCONF 8 "June 2010" "" "Linux Administrator's Manual"
++.SH NAME
++mpathconf - A tool for configuring device-mapper-multipath
++.SH SYNOPSIS
++.B mpathconf
++.RB [\| commands \|]
++.RB [\| options \|]
++.SH DESCRIPTION
++.B mpathconf
++is a utility that creates or modifies
++.B /etc/multipath.conf.
++It can enable or disable multipathing and configure some common options.
++.B mpathconf
++can also load the
++.B dm_multipath
++module, start and stop the
++.B multipathd
++daemon, and configure the
++.B multipathd
++service to start automatically or not. If
++.B mpathconf
++is called with no commands, it will display the current configuration.
++
++The default options for mpathconf are
++.B --with_module
++The
++.B --with_multipathd
++option is not set by default.  Enabling multipathing will load the
++.B dm_multipath
++module but it will not immediately start it. This is so
++that users can manually edit their config file if necessary, before starting
++.B multipathd.
++
++If
++.B /etc/multipath.conf
++already exists, mpathconf will edit it. If it does not exist, mpathconf will
++create a default file with
++.B user_friendly_names
++and
++.B find_multipaths
++set. To disable these, use the
++.B --user_friendly_names n
++and
++.B --find_multipaths n
++options
++.SH COMMANDS
++.TP
++.B --enable
++Removes any line that blacklists all device nodes from the
++.B /etc/multipath.conf
++blacklist section.
++.TP
++.B --disable
++Adds a line that blacklists all device nodes to the
++.B /etc/multipath.conf
++blacklist section. If no blacklist section exists, it will create one.
++.TP
++.B --user_friendly_name \fP { \fBy\fP | \fBn\fP }
++If set to \fBy\fP, this adds the line
++.B user_friendly_names yes
++to the
++.B /etc/multipath.conf
++defaults section. If set to \fBn\fP, this removes the line, if present. This
++command can be used along with any other command.
++.TP
++.B --find_multipaths\fP { \fBy\fP | \fBn\fP }
++If set to \fBy\fP, this adds the line
++.B find_multipaths yes
++to the
++.B /etc/multipath.conf
++defaults section. If set to \fBn\fP, this removes the line, if present. This
++command can be used aldong with any other command.
++.SH OPTIONS
++.TP
++.B --with_module\fP { \fBy\fP | \fBn\fP }
++If set to \fBy\fP, this runs
++.B modprobe dm_multipath
++to install the multipath modules. This option only works with the
++.B --enable
++command. This option is set to \fBy\fP by default.
++.TP
++.B --with_multipathd { \fBy\fP | \fBn\fP }
++If set to \fBy\fP, this runs
++.B service multipathd start
++to start the multipathd daemon on \fB--enable\fP,
++.B service multipathd stop
++to stop the multipathd daemon on \fB--disable\fP, and
++.B service multipathd reload
++to reconfigure multipathd on \fB--user_frindly_names\fP and
++\fB--find_multipaths\fP.
++This option is set to \fBn\fP by default.
++.SH FILES
++.BR /etc/multipath.conf
++.SH "SEE ALSO"
++.BR multipath.conf (5),
++.BR modprobe (8),
++.BR multipath (8),
++.BR multipathd (8),
++.BR service (8),
++.SH AUTHOR
++Benjamin Marzinski <bmarzins@redhat.com>
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0026-RH-add-wwids-from-kernel-cmdline-mpath.wwids-with-A.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0026-RH-add-wwids-from-kernel-cmdline-mpath.wwids-with-A.patch
new file mode 100644
index 0000000..ddf022f
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0026-RH-add-wwids-from-kernel-cmdline-mpath.wwids-with-A.patch
@@ -0,0 +1,167 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Fri, 17 Oct 2014 11:20:34 -0500
+Subject: [PATCH] RH: add wwids from kernel cmdline mpath.wwids with -A
+
+This patch adds another option to multipath, "-A", which reads
+/proc/cmdline for mpath.wwid=<WWID> options, and adds any wwids it finds
+to /etc/multipath/wwids.  While this isn't usually important during
+normal operation, since these wwids should already be added, it can be
+helpful during installation, to make sure that multipath can claim
+devices as its own, before LVM or something else makes use of them.  The
+patch also execs "/sbin/multipath -A" before running multipathd in
+multipathd.service
+
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/wwids.c          | 44 +++++++++++++++++++++++++++++++++++++++++++
+ libmultipath/wwids.h          |  1 +
+ multipath/main.c              | 10 ++++++++--
+ multipath/multipath.8         |  5 ++++-
+ multipathd/multipathd.service |  1 +
+ 5 files changed, 58 insertions(+), 3 deletions(-)
+
+diff --git a/libmultipath/wwids.c b/libmultipath/wwids.c
+index 53e7951..39e08cd 100644
+--- a/libmultipath/wwids.c
++++ b/libmultipath/wwids.c
+@@ -443,3 +443,47 @@ int op ## _wwid(const char *wwid) \
+ declare_failed_wwid_op(is_failed, false)
+ declare_failed_wwid_op(mark_failed, true)
+ declare_failed_wwid_op(unmark_failed, true)
++
++int remember_cmdline_wwid(void)
++{
++	FILE *f = NULL;
++	char buf[LINE_MAX], *next, *ptr;
++	int ret = 0;
++
++	f = fopen("/proc/cmdline", "re");
++	if (!f) {
++		condlog(0, "can't open /proc/cmdline : %s", strerror(errno));
++		return -1;
++	}
++
++	if (!fgets(buf, sizeof(buf), f)) {
++		if (ferror(f))
++			condlog(0, "read of /proc/cmdline failed : %s",
++				strerror(errno));
++		else
++			condlog(0, "couldn't read /proc/cmdline");
++		fclose(f);
++		return -1;
++	}
++	fclose(f);
++	next = buf;
++	while((ptr = strstr(next, "mpath.wwid="))) {
++		ptr += 11;
++		next = strpbrk(ptr, " \t\n");
++		if (next) {
++			*next = '\0';
++			next++;
++		}
++		if (strlen(ptr)) {
++			if (remember_wwid(ptr) != 0)
++				ret = -1;
++		}
++		else {
++			condlog(0, "empty mpath.wwid kernel command line option");
++			ret = -1;
++		}
++		if (!next)
++			break;
++	}
++	return ret;
++}
+diff --git a/libmultipath/wwids.h b/libmultipath/wwids.h
+index 0c6ee54..e32a0b0 100644
+--- a/libmultipath/wwids.h
++++ b/libmultipath/wwids.h
+@@ -17,6 +17,7 @@ int remember_wwid(char *wwid);
+ int check_wwids_file(char *wwid, int write_wwid);
+ int remove_wwid(char *wwid);
+ int replace_wwids(vector mp);
++int remember_cmdline_wwid(void);
+ 
+ enum {
+ 	WWID_IS_NOT_FAILED = 0,
+diff --git a/multipath/main.c b/multipath/main.c
+index 6fdde03..7bac232 100644
+--- a/multipath/main.c
++++ b/multipath/main.c
+@@ -109,7 +109,7 @@ usage (char * progname)
+ {
+ 	fprintf (stderr, VERSION_STRING);
+ 	fprintf (stderr, "Usage:\n");
+-	fprintf (stderr, "  %s [-a|-c|-w|-W] [-d] [-r] [-i] [-v lvl] [-p pol] [-b fil] [-q] [dev]\n", progname);
++	fprintf (stderr, "  %s [-a|-A|-c|-w|-W] [-d] [-r] [-i] [-v lvl] [-p pol] [-b fil] [-q] [dev]\n", progname);
+ 	fprintf (stderr, "  %s -l|-ll|-f [-v lvl] [-b fil] [-R num] [dev]\n", progname);
+ 	fprintf (stderr, "  %s -F [-v lvl] [-R num]\n", progname);
+ 	fprintf (stderr, "  %s -t\n", progname);
+@@ -123,6 +123,8 @@ usage (char * progname)
+ 		"  -f      flush a multipath device map\n"
+ 		"  -F      flush all multipath device maps\n"
+ 		"  -a      add a device wwid to the wwids file\n"
++		"  -A      add devices from kernel command line mpath.wwids\n"
++		"          parameters to wwids file\n"
+ 		"  -c      check if a device should be a path in a multipath device\n"
+ 		"  -C      check if a multipath device has usable paths\n"
+ 		"  -q      allow queue_if_no_path when multipathd is not running\n"
+@@ -907,7 +909,7 @@ main (int argc, char *argv[])
+ 		exit(1);
+ 	multipath_conf = conf;
+ 	conf->retrigger_tries = 0;
+-	while ((arg = getopt(argc, argv, ":adcChl::FfM:v:p:b:BrR:itquUwW")) != EOF ) {
++	while ((arg = getopt(argc, argv, ":aAdcChl::FfM:v:p:b:BrR:itquUwW")) != EOF ) {
+ 		switch(arg) {
+ 		case 1: printf("optarg : %s\n",optarg);
+ 			break;
+@@ -974,6 +976,10 @@ main (int argc, char *argv[])
+ 		case 't':
+ 			r = dump_config(conf);
+ 			goto out_free_config;
++		case 'A':
++			if (remember_cmdline_wwid() != 0)
++				exit(1);
++			exit(0);
+ 		case 'h':
+ 			usage(argv[0]);
+ 			exit(0);
+diff --git a/multipath/multipath.8 b/multipath/multipath.8
+index 914a8cb..8c6a4c1 100644
+--- a/multipath/multipath.8
++++ b/multipath/multipath.8
+@@ -25,7 +25,7 @@ multipath \- Device mapper target autoconfig.
+ .RB [\| \-b\ \c
+ .IR bindings_file \|]
+ .RB [\| \-d \|]
+-.RB [\| \-h | \-l | \-ll | \-f | \-t | \-F | \-B | \-c | \-C | \-q | \-r | \-i | \-a | \-u | \-U | \-w | \-W \|]
++.RB [\| \-h | \-l | \-ll | \-f | \-t | \-F | \-B | \-c | \-C | \-q | \-r | \-i | \-a | \-A | \-u | \-U | \-w | \-W \|]
+ .RB [\| \-p\ \c
+ .IR failover | multibus | group_by_serial | group_by_prio | group_by_node_name \|]
+ .RB [\| \-R\ \c
+@@ -135,6 +135,9 @@ Add the WWID for the specified device to the WWIDs file.
+ Check if the device specified in the program environment should be
+ a path in a multipath device.
+ .
++.B \-A
++add wwids from any kernel command line mpath.wwid parameters to the wwids file
++.
+ .TP
+ .B \-U
+ Check if the device specified in the program environment is a multipath device
+diff --git a/multipathd/multipathd.service b/multipathd/multipathd.service
+index 17434ce..0fbcc46 100644
+--- a/multipathd/multipathd.service
++++ b/multipathd/multipathd.service
+@@ -15,6 +15,7 @@ Type=notify
+ NotifyAccess=main
+ LimitCORE=infinity
+ ExecStartPre=-/sbin/modprobe -a scsi_dh_alua scsi_dh_emc scsi_dh_rdac dm-multipath
++ExecStartPre=-/sbin/multipath -A
+ ExecStart=/sbin/multipathd -d -s
+ ExecReload=/sbin/multipathd reconfigure
+ TasksMax=infinity
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0027-RH-warn-on-invalid-regex-instead-of-failing.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0027-RH-warn-on-invalid-regex-instead-of-failing.patch
new file mode 100644
index 0000000..a23e167
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0027-RH-warn-on-invalid-regex-instead-of-failing.patch
@@ -0,0 +1,121 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Mon, 6 Nov 2017 21:39:28 -0600
+Subject: [PATCH] RH: warn on invalid regex instead of failing
+
+multipath.conf used to allow "*" as a match everything regular expression,
+instead of requiring ".*". Instead of erroring when the old style
+regular expressions are used, it should print a warning and convert
+them.
+
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/dict.c   | 27 +++++++++++++++++++++------
+ libmultipath/parser.c | 13 +++++++++++++
+ libmultipath/parser.h |  1 +
+ 3 files changed, 35 insertions(+), 6 deletions(-)
+
+diff --git a/libmultipath/dict.c b/libmultipath/dict.c
+index 7ad0f5a..ab808d6 100644
+--- a/libmultipath/dict.c
++++ b/libmultipath/dict.c
+@@ -55,6 +55,21 @@ set_str(vector strvec, void *ptr)
+ }
+ 
+ static int
++set_regex(vector strvec, void *ptr)
++{
++	char **str_ptr = (char **)ptr;
++
++	if (*str_ptr)
++		FREE(*str_ptr);
++	*str_ptr = set_regex_value(strvec);
++
++	if (!*str_ptr)
++		return 1;
++
++	return 0;
++}
++
++static int
+ set_yes_no(vector strvec, void *ptr)
+ {
+ 	char * buff;
+@@ -1271,7 +1286,7 @@ ble_ ## option ## _handler (struct config *conf, vector strvec)		\
+ 	if (!conf->option)						\
+ 		return 1;						\
+ 									\
+-	buff = set_value(strvec);					\
++	buff = set_regex_value(strvec);					\
+ 	if (!buff)							\
+ 		return 1;						\
+ 									\
+@@ -1287,7 +1302,7 @@ ble_ ## option ## _ ## name ## _handler (struct config *conf, vector strvec) \
+ 	if (!conf->option)						\
+ 		return 1;						\
+ 									\
+-	buff = set_value(strvec);					\
++	buff = set_regex_value(strvec);					\
+ 	if (!buff)							\
+ 		return 1;						\
+ 									\
+@@ -1388,16 +1403,16 @@ device_handler(struct config *conf, vector strvec)
+ 	return 0;
+ }
+ 
+-declare_hw_handler(vendor, set_str)
++declare_hw_handler(vendor, set_regex)
+ declare_hw_snprint(vendor, print_str)
+ 
+-declare_hw_handler(product, set_str)
++declare_hw_handler(product, set_regex)
+ declare_hw_snprint(product, print_str)
+ 
+-declare_hw_handler(revision, set_str)
++declare_hw_handler(revision, set_regex)
+ declare_hw_snprint(revision, print_str)
+ 
+-declare_hw_handler(bl_product, set_str)
++declare_hw_handler(bl_product, set_regex)
+ declare_hw_snprint(bl_product, print_str)
+ 
+ declare_hw_handler(hwhandler, set_str)
+diff --git a/libmultipath/parser.c b/libmultipath/parser.c
+index b8b7e0d..34b4ad2 100644
+--- a/libmultipath/parser.c
++++ b/libmultipath/parser.c
+@@ -380,6 +380,19 @@ set_value(vector strvec)
+ 	return alloc;
+ }
+ 
++void *
++set_regex_value(vector strvec)
++{
++	char *buff = set_value(strvec);
++
++	if (buff && strcmp("*", buff) == 0) {
++		condlog(0, "Invalid regular expression \"*\" in multipath.conf. Using \".*\"");
++		FREE(buff);
++		return strdup(".*");
++	}
++	return buff;
++}
++
+ /* non-recursive configuration stream handler */
+ static int kw_level = 0;
+ 
+diff --git a/libmultipath/parser.h b/libmultipath/parser.h
+index 62906e9..b791705 100644
+--- a/libmultipath/parser.h
++++ b/libmultipath/parser.h
+@@ -77,6 +77,7 @@ extern void dump_keywords(vector keydump, int level);
+ extern void free_keywords(vector keywords);
+ extern vector alloc_strvec(char *string);
+ extern void *set_value(vector strvec);
++extern void *set_regex_value(vector strvec);
+ extern int process_file(struct config *conf, char *conf_file);
+ extern struct keyword * find_keyword(vector keywords, vector v, char * name);
+ int snprint_keyword(char *buff, int len, char *fmt, struct keyword *kw,
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0028-RH-reset-default-find_mutipaths-value-to-off.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0028-RH-reset-default-find_mutipaths-value-to-off.patch
new file mode 100644
index 0000000..05e6864
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0028-RH-reset-default-find_mutipaths-value-to-off.patch
@@ -0,0 +1,29 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Benjamin Marzinski <bmarzins@redhat.com>
+Date: Thu, 7 Jun 2018 17:43:52 -0500
+Subject: [PATCH] RH: reset default find_mutipaths value to off
+
+Upstream has changed to default find_multipaths to "strict". For now
+Redhat will retain the previous default of "off".
+
+Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
+---
+ libmultipath/defaults.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/libmultipath/defaults.h b/libmultipath/defaults.h
+index f076b4b..70ba98a 100644
+--- a/libmultipath/defaults.h
++++ b/libmultipath/defaults.h
+@@ -17,7 +17,7 @@
+ #define DEFAULT_NO_PATH_RETRY	NO_PATH_RETRY_UNDEF
+ #define DEFAULT_VERBOSITY	2
+ #define DEFAULT_REASSIGN_MAPS	0
+-#define DEFAULT_FIND_MULTIPATHS	FIND_MULTIPATHS_STRICT
++#define DEFAULT_FIND_MULTIPATHS	FIND_MULTIPATHS_OFF
+ #define DEFAULT_FAST_IO_FAIL	5
+ #define DEFAULT_DEV_LOSS_TMO	600
+ #define DEFAULT_RETAIN_HWHANDLER RETAIN_HWHANDLER_ON
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0029-multipath-tools-modify-Makefile.inc-for-cross-compil.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0029-multipath-tools-modify-Makefile.inc-for-cross-compil.patch
new file mode 100644
index 0000000..45cd32a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0029-multipath-tools-modify-Makefile.inc-for-cross-compil.patch
@@ -0,0 +1,49 @@
+From 8bdd4481d822b6625d8bf719431ca74ed1b5e021 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Mon, 16 Jul 2018 15:56:37 +0800
+Subject: [PATCH] multipath-tools: modify Makefile.inc for cross-compilation
+
+Do not look for systemd info on the host, and allow us to pass in CFLAGS
+using the OPTFLAGS variable.
+
+Upstream-Status: Inappropriate [embedded specific]
+
+Signed-off-by: Joe Slater <joe.slater@windriver.com>
+
+Update for version 0.5.0-144-g770e6d0
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+
+Update for version 0.7.1
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+
+update for version 0.7.7
+
+remove change about CFLAGS part, since patch 0024 already have similar function.
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ Makefile.inc | 8 ++------
+ 1 file changed, 2 insertions(+), 6 deletions(-)
+
+diff --git a/Makefile.inc b/Makefile.inc
+index 57a1835..0c403c7 100644
+--- a/Makefile.inc
++++ b/Makefile.inc
+@@ -38,12 +38,6 @@ ifndef RUN
+ 	endif
+ endif
+ 
+-ifndef SYSTEMD
+-	ifeq ($(shell systemctl --version > /dev/null 2>&1 && echo 1), 1)
+-		SYSTEMD = $(shell systemctl --version 2> /dev/null |  sed -n 's/systemd \([0-9]*\)/\1/p')
+-	endif
+-endif
+-
+ ifndef SYSTEMDPATH
+ 	SYSTEMDPATH=usr/lib
+ endif
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0030-Always-use-devmapper.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0030-Always-use-devmapper.patch
new file mode 100644
index 0000000..1281180
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0030-Always-use-devmapper.patch
@@ -0,0 +1,57 @@
+From d929a1ea5e42ecbe30c990644ed4ada2817c6439 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Mon, 16 Jul 2018 16:00:14 +0800
+Subject: [PATCH]  Always use devmapper
+
+Do not try to compute several _API_ make variables
+from host information when cross-compiling.
+
+Upstream-Status: Inappropriate [embedded specific]
+
+Signed-off-by: Aws Ismail <aws.ismail@windriver.com>
+Signed-off-by: Joe Slater <joe.slater@windriver.com>
+
+Rebase to 0.7.1
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+
+Rebase to 0.7.7
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ libmultipath/Makefile | 19 ++++---------------
+ 1 file changed, 4 insertions(+), 15 deletions(-)
+
+diff --git a/libmultipath/Makefile b/libmultipath/Makefile
+index f51786d..3ad9c48 100644
+--- a/libmultipath/Makefile
++++ b/libmultipath/Makefile
+@@ -20,21 +20,10 @@ ifdef SYSTEMD
+ 	endif
+ endif
+ 
+-ifneq ($(call check_func,dm_task_no_flush,/usr/include/libdevmapper.h),0)
+-	CFLAGS += -DLIBDM_API_FLUSH -D_GNU_SOURCE
+-endif
+-
+-ifneq ($(call check_func,dm_task_set_cookie,/usr/include/libdevmapper.h),0)
+-	CFLAGS += -DLIBDM_API_COOKIE
+-endif
+-
+-ifneq ($(call check_func,udev_monitor_set_receive_buffer_size,/usr/include/libudev.h),0)
+-	CFLAGS += -DLIBUDEV_API_RECVBUF
+-endif
+-
+-ifneq ($(call check_func,dm_task_deferred_remove,/usr/include/libdevmapper.h),0)
+-	CFLAGS += -DLIBDM_API_DEFERRED
+-endif
++CFLAGS += -DLIBDM_API_FLUSH -D_GNU_SOURCE
++CFLAGS += -DLIBDM_API_COOKIE
++CFLAGS += -DLIBUDEV_API_RECVBUF
++CFLAGS += -DLIBDM_API_DEFERRED
+ 
+ OBJS = memory.o parser.o vector.o devmapper.o callout.o \
+ 	hwtable.o blacklist.o util.o dmparser.o config.o \
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0031-Always-use-devmapper-for-kpartx.patch b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0031-Always-use-devmapper-for-kpartx.patch
new file mode 100644
index 0000000..88a758d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/files/0031-Always-use-devmapper-for-kpartx.patch
@@ -0,0 +1,40 @@
+From 145f2b829e5362cda975bebafd7fe4d00ff56d1c Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Mon, 16 Jul 2018 16:02:07 +0800
+Subject: [PATCH] Always use devmapper for kpartx
+
+Do not try to compute the LIBDM_API_COOKIE make variable
+from host information when cross-compiling.
+
+Upstream-Status: Inappropriate [embedded specific]
+
+Signed-off-by: Aws Ismail <aws.ismail@windriver.com>
+Signed-off-by: Joe Slater <joe.slater@windriver.com>
+
+Rebase to 0.7.1
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+
+Rebase to 0.7.7
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ kpartx/Makefile | 4 +---
+ 1 file changed, 1 insertion(+), 3 deletions(-)
+
+diff --git a/kpartx/Makefile b/kpartx/Makefile
+index 7eb467e..c143321 100644
+--- a/kpartx/Makefile
++++ b/kpartx/Makefile
+@@ -8,9 +8,7 @@ LDFLAGS += $(BIN_LDFLAGS)
+ 
+ LIBDEPS += -ldevmapper
+ 
+-ifneq ($(call check_func,dm_task_set_cookie,/usr/include/libdevmapper.h),0)
+-	CFLAGS += -DLIBDM_API_COOKIE
+-endif
++CFLAGS += -DLIBDM_API_COOKIE
+ 
+ OBJS = bsd.o dos.o kpartx.o solaris.o unixware.o dasd.o sun.o \
+ 	gpt.o mac.o ps3.o crc32.o lopart.o xstrncpy.o devmapper.o
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/multipath-tools_0.7.1.bb b/meta-openembedded/meta-oe/recipes-support/multipath-tools/multipath-tools_0.7.1.bb
deleted file mode 100644
index 6ec5dff..0000000
--- a/meta-openembedded/meta-oe/recipes-support/multipath-tools/multipath-tools_0.7.1.bb
+++ /dev/null
@@ -1,113 +0,0 @@
-SUMMARY = "The upstream project used to drive the Device Mapper multipathing driver"
-
-DESCRIPTION = "It provides tools to manage multipath devices \
-by instructing the device-mapper kernel module what to do. These \
-tools include: \
-1. multipath - Scan the system for multipath devices and assemble them.\
-2. multipathd - Detects when paths fail and execs multipath to update \
-things.\
-3. mpathpersist - Persistent reservation management feature allows \
-cluster management software to manage persistent reservation through \
-mpath device. It processes management requests from callers and hides \
-the management task details. It also handles persistent reservation \
-management of data path life cycle and state changes.\
-4. kpartx - This tool, derived from util-linux's partx, reads partition \
-tables on specified device and create device maps over partitions \
-segments detected. It is called from hotplug upon device maps creation \
-and deletion"
-
-HOMEPAGE = "http://christophe.varoqui.free.fr/"
-
-DEPENDS = "libdevmapper \
-           libaio \
-           liburcu \
-           readline \
-           udev \
-           json-c \
-          "
-
-LICENSE = "GPLv2"
-
-SRC_URI = "git://git.opensvc.com/multipath-tools/.git;protocol=http \
-           file://multipathd.oe \
-           file://multipath.conf.example \
-           file://0001-multipath-attempt-at-common-multipath.rules.patch \
-           file://0002-RH-fixup-udev-rules-for-redhat.patch \
-           file://0003-RH-Remove-the-property-blacklist-exception-builtin.patch \
-           file://0004-RH-don-t-start-without-a-config-file.patch \
-           file://0005-RH-add-mpathconf.patch \
-           file://0006-RH-add-wwids-from-kernel-cmdline-mpath.wwids-with-A.patch \
-           file://0007-RH-trigger-change-uevent-on-new-device-creation.patch \
-           file://0008-libmultipath-change-how-RADOS-checker-is-enabled.patch \
-           file://0009-multipath-set-verbosity-to-default-during-config.patch \
-           file://0010-mpath-skip-device-configs-without-vendor-product.patch \
-           file://0011-multipathd-fix-show-maps-json-crash.patch \
-           file://0012-multipath-tools-modify-Makefile.inc-for-cross-compil.patch \
-           file://0013-Always-use-devmapper.patch \
-           file://0014-Always-use-devmapper-for-kpartx.patch \
-           file://0001-kpartx-include-limits.h-for-PATH_MAX.patch \
-           "
-LIC_FILES_CHKSUM = "file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2"
-
-SRCREV = "f21166a812a2cfb50ecf9550d32947c83103f83a"
-
-S = "${WORKDIR}/git"
-
-inherit systemd pkgconfig
-
-SYSTEMD_SERVICE_${PN} = "multipathd.service"
-
-TARGET_CC_ARCH += "${LDFLAGS}"
-
-# multipath-tools includes a copy of the valgrind.h header
-# file and uses the macros to suppress some false positives. However,
-# that only works on ARM when thumb is disabled. Otherwise one gets:
-#   Error: shifts in CMP/MOV instructions are only supported in unified syntax -- `mov r12,r12,ror#3'
-#   ../Makefile.inc:66: recipe for target 'debug.o' failed
-ARM_INSTRUCTION_SET_armv4 = "arm"
-ARM_INSTRUCTION_SET_armv5 = "arm"
-
-# The exact version of SYSTEMD does not matter but should be greater than 209.
-#
-EXTRA_OEMAKE = 'MULTIPATH_VERSION=${PV} DESTDIR=${D} syslibdir=${base_libdir} \
-                OPTFLAGS="${CFLAGS}" \
-                bindir=${base_sbindir} \
-                LIB=${base_libdir} libdir=${base_libdir}/multipath \
-                unitdir=${systemd_system_unitdir} \
-                ${@bb.utils.contains("DISTRO_FEATURES", "systemd", "SYSTEMD=216", "", d)} \
-               '
-
-do_install() {
-    oe_runmake install
-
-    # We copy an initscript, but do not start multipathd at init time.
-    #
-    if ${@bb.utils.contains('DISTRO_FEATURES','sysvinit','true','false',d)};then
-        install -d ${D}${sysconfdir}/init.d
-        cp ${WORKDIR}/multipathd.oe ${D}${sysconfdir}/init.d/multipathd
-    fi
-
-    install -d ${D}${sysconfdir}
-    install -m 0644 ${WORKDIR}/multipath.conf.example \
-    ${D}${sysconfdir}/multipath.conf.example
-}
-
-FILES_${PN}-dbg += "${base_libdir}/multipath/.debug"
-
-PACKAGES =+ "${PN}-libs"
-FILES_${PN}-libs = "${base_libdir}/lib*.so.* \
-                    ${base_libdir}/multipath/lib*.so*"
-RDEPENDS_${PN} += "${PN}-libs bash"
-
-PROVIDES += "device-mapper-multipath"
-RPROVIDES_${PN} += "device-mapper-multipath"
-RPROVIDES_${PN}-libs += "device-mapper-multipath-libs"
-
-FILES_${PN}-dev += "${base_libdir}/pkgconfig"
-
-PACKAGES =+ "kpartx"
-FILES_kpartx = "${base_sbindir}/kpartx \
-                ${nonarch_libdir}/udev/kpartx_id \
-               "
-
-RDEPENDS_${PN} += "bash kpartx"
diff --git a/meta-openembedded/meta-oe/recipes-support/multipath-tools/multipath-tools_0.7.7.bb b/meta-openembedded/meta-oe/recipes-support/multipath-tools/multipath-tools_0.7.7.bb
new file mode 100644
index 0000000..5cc1546
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/multipath-tools/multipath-tools_0.7.7.bb
@@ -0,0 +1,131 @@
+SUMMARY = "The upstream project used to drive the Device Mapper multipathing driver"
+
+DESCRIPTION = "It provides tools to manage multipath devices \
+by instructing the device-mapper kernel module what to do. These \
+tools include: \
+1. multipath - Scan the system for multipath devices and assemble them.\
+2. multipathd - Detects when paths fail and execs multipath to update \
+things.\
+3. mpathpersist - Persistent reservation management feature allows \
+cluster management software to manage persistent reservation through \
+mpath device. It processes management requests from callers and hides \
+the management task details. It also handles persistent reservation \
+management of data path life cycle and state changes.\
+4. kpartx - This tool, derived from util-linux's partx, reads partition \
+tables on specified device and create device maps over partitions \
+segments detected. It is called from hotplug upon device maps creation \
+and deletion"
+
+HOMEPAGE = "http://christophe.varoqui.free.fr/"
+
+DEPENDS = "libdevmapper \
+           libaio \
+           liburcu \
+           readline \
+           udev \
+           json-c \
+          "
+
+LICENSE = "GPLv2"
+
+SRC_URI = "git://git.opensvc.com/multipath-tools/.git;protocol=http \
+           file://multipathd.oe \
+           file://multipath.conf.example \
+           file://0001-multipath-tools-add-RDAC-SUN-ArrayStorage-to-hwtable.patch \
+           file://0002-multipath-tools-remove-c-from-__cpluscplus-misspelle.patch \
+           file://0003-multipath-tools-remove-emacs-autoconfig-of-kpartx-gp.patch \
+           file://0004-multipath-tools-replace-FSF-address-with-a-www-point.patch \
+           file://0005-multipath-tools-Remove-trailing-leading-whitespaces-.patch \
+           file://0006-multipath-tools-fix-compilation-with-musl-libc.patch \
+           file://0007-multipath-tools-add-x-to-doc-preclean.pl-and-split-m.patch \
+           file://0008-multipath-tools-refresh-kernel-doc-from-kernel-sourc.patch \
+           file://0009-multipath-tools-configure-hitachi-ams2000-and-hus100.patch \
+           file://0010-libmultipath-don-t-reject-maps-with-undefined-prio.patch \
+           file://0011-multipathd-handle-errors-in-uxlsnr-as-fatal.patch \
+           file://0012-libmultipath-fix-error-parsing-find_multipaths-stric.patch \
+           file://0013-libmultipath-print-correct-default-for-delay_-_check.patch \
+           file://0014-multipath.conf.5-clarify-property-whitelist-handling.patch \
+           file://0015-mpathpersist-add-all_tg_pt-option.patch \
+           file://0016-libmultipath-remove-rbd-code.patch \
+           file://0017-mpathpersist-fix-aptpl-support.patch \
+           file://0018-multipath-don-t-check-timestamps-without-a-path.patch \
+           file://0019-libmultipath-fix-detect-alua-corner-case.patch \
+           file://0020-multipath-fix-setting-conf-version.patch \
+           file://0021-RH-fixup-udev-rules-for-redhat.patch \
+           file://0022-RH-Remove-the-property-blacklist-exception-builtin.patch \
+           file://0023-RH-don-t-start-without-a-config-file.patch \
+           file://0024-RH-use-rpm-optflags-if-present.patch \
+           file://0025-RH-add-mpathconf.patch \
+           file://0026-RH-add-wwids-from-kernel-cmdline-mpath.wwids-with-A.patch \
+           file://0027-RH-warn-on-invalid-regex-instead-of-failing.patch \
+           file://0028-RH-reset-default-find_mutipaths-value-to-off.patch \
+           file://0029-multipath-tools-modify-Makefile.inc-for-cross-compil.patch \
+           file://0030-Always-use-devmapper.patch \
+           file://0031-Always-use-devmapper-for-kpartx.patch \
+           "
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2"
+
+SRCREV = "386d288b5595fc2c01dffe698b6eb306c6674908"
+
+S = "${WORKDIR}/git"
+
+inherit systemd pkgconfig
+
+SYSTEMD_SERVICE_${PN} = "multipathd.service"
+SYSTEMD_AUTO_ENABLE = "disable"
+
+TARGET_CC_ARCH += "${LDFLAGS}"
+
+# multipath-tools includes a copy of the valgrind.h header
+# file and uses the macros to suppress some false positives. However,
+# that only works on ARM when thumb is disabled. Otherwise one gets:
+#   Error: shifts in CMP/MOV instructions are only supported in unified syntax -- `mov r12,r12,ror#3'
+#   ../Makefile.inc:66: recipe for target 'debug.o' failed
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
+
+# The exact version of SYSTEMD does not matter but should be greater than 209.
+#
+EXTRA_OEMAKE = 'MULTIPATH_VERSION=${PV} DESTDIR=${D} syslibdir=${base_libdir} \
+                OPTFLAGS="${CFLAGS}" \
+                bindir=${base_sbindir} \
+                LIB=${base_libdir} libdir=${base_libdir}/multipath \
+                unitdir=${systemd_system_unitdir} \
+                ${@bb.utils.contains("DISTRO_FEATURES", "systemd", "SYSTEMD=216", "", d)} \
+               '
+
+do_install() {
+    oe_runmake install
+
+    # We copy an initscript, but do not start multipathd at init time.
+    #
+    if ${@bb.utils.contains('DISTRO_FEATURES','sysvinit','true','false',d)};then
+        install -d ${D}${sysconfdir}/init.d
+        cp ${WORKDIR}/multipathd.oe ${D}${sysconfdir}/init.d/multipathd
+    fi
+
+    install -d ${D}${sysconfdir}
+    install -m 0644 ${WORKDIR}/multipath.conf.example \
+    ${D}${sysconfdir}/multipath.conf.example
+}
+
+FILES_${PN}-dbg += "${base_libdir}/multipath/.debug"
+
+PACKAGES =+ "${PN}-libs"
+FILES_${PN}-libs = "${base_libdir}/lib*.so.* \
+                    ${base_libdir}/multipath/lib*.so*"
+RDEPENDS_${PN} += "${PN}-libs bash"
+
+PROVIDES += "device-mapper-multipath"
+RPROVIDES_${PN} += "device-mapper-multipath"
+RPROVIDES_${PN}-libs += "device-mapper-multipath-libs"
+
+FILES_${PN}-dev += "${base_libdir}/pkgconfig"
+
+PACKAGES =+ "kpartx"
+FILES_kpartx = "${base_sbindir}/kpartx \
+                ${nonarch_libdir}/udev/kpartx_id \
+               "
+
+RDEPENDS_${PN} += "bash kpartx"
diff --git a/meta-openembedded/meta-oe/recipes-support/nano/nano.inc b/meta-openembedded/meta-oe/recipes-support/nano/nano.inc
deleted file mode 100644
index 22f0fb2..0000000
--- a/meta-openembedded/meta-oe/recipes-support/nano/nano.inc
+++ /dev/null
@@ -1,17 +0,0 @@
-DESCRIPTION = "GNU nano (Nano's ANOther editor, or \
-Not ANOther editor) is an enhanced clone of the \
-Pico text editor."
-HOMEPAGE = "http://www.nano-editor.org/"
-LICENSE = "GPLv3"
-LIC_FILES_CHKSUM = "file://COPYING;md5=f27defe1e96c2e1ecd4e0c9be8967949"
-SECTION = "console/utils"
-DEPENDS = "ncurses file"
-RDEPENDS_${PN} = "ncurses-terminfo"
-
-PV_MAJOR = "${@d.getVar('PV').split('.')[0]}.${@d.getVar('PV').split('.')[1]}"
-
-SRC_URI = "https://nano-editor.org/dist/v${PV_MAJOR}/nano-${PV}.tar.xz"
-
-inherit autotools gettext pkgconfig
-
-PACKAGECONFIG[tiny] = "--enable-tiny,"
diff --git a/meta-openembedded/meta-oe/recipes-support/nano/nano_2.9.3.bb b/meta-openembedded/meta-oe/recipes-support/nano/nano_2.9.3.bb
deleted file mode 100644
index afb0cf2..0000000
--- a/meta-openembedded/meta-oe/recipes-support/nano/nano_2.9.3.bb
+++ /dev/null
@@ -1,4 +0,0 @@
-include nano.inc
-
-SRC_URI[md5sum] = "6dd37f010d6a985bf0e5f8ed091ff919"
-SRC_URI[sha256sum] = "7783bcfd4b2d5dc0bf64d4bd07b1a19e7ba3c91da881a4249772a36b972d4012"
diff --git a/meta-openembedded/meta-oe/recipes-support/nano/nano_3.0.bb b/meta-openembedded/meta-oe/recipes-support/nano/nano_3.0.bb
new file mode 100644
index 0000000..2c7fbd5
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/nano/nano_3.0.bb
@@ -0,0 +1,20 @@
+DESCRIPTION = "GNU nano (Nano's ANOther editor, or \
+Not ANOther editor) is an enhanced clone of the \
+Pico text editor."
+HOMEPAGE = "http://www.nano-editor.org/"
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=f27defe1e96c2e1ecd4e0c9be8967949"
+SECTION = "console/utils"
+DEPENDS = "ncurses file"
+RDEPENDS_${PN} = "ncurses-terminfo-base"
+
+PV_MAJOR = "${@d.getVar('PV').split('.')[0]}"
+
+SRC_URI = "https://nano-editor.org/dist/v${PV_MAJOR}/nano-${PV}.tar.xz"
+
+SRC_URI[md5sum] = "74196427a09ec2f82a88facd220d2787"
+SRC_URI[sha256sum] = "e0a5bca354514e64762c987c200a8758b05e7bcced3b00b3e48ea0a2d383c8a0"
+
+inherit autotools gettext pkgconfig
+
+PACKAGECONFIG[tiny] = "--enable-tiny,"
diff --git a/meta-openembedded/meta-oe/recipes-support/ne10/ne10_1.2.1.bb b/meta-openembedded/meta-oe/recipes-support/ne10/ne10_1.2.1.bb
index 76e0741..3afdff7 100644
--- a/meta-openembedded/meta-oe/recipes-support/ne10/ne10_1.2.1.bb
+++ b/meta-openembedded/meta-oe/recipes-support/ne10/ne10_1.2.1.bb
@@ -38,7 +38,7 @@
     install -m 0644 ${S}/inc/NE10*.h ${D}${includedir}/
     install -m 0644 ${B}/modules/libNE10.a ${D}${libdir}/
     install -m 0755 ${B}/modules/libNE10.so.* ${D}${libdir}/
-    cp -a ${B}/modules/libNE10.so ${D}${libdir}/
+    cp -d ${B}/modules/libNE10.so ${D}${libdir}/
 }
 
 # ERROR: QA Issue: ELF binary 'ne10/1.2.1-r0/packages-split/ne10/usr/lib/libNE10.so.10' has relocations in .text [textrel]
diff --git a/meta-openembedded/meta-oe/recipes-support/numactl/numactl/0001-fix-NULL-pointer-problem.patch b/meta-openembedded/meta-oe/recipes-support/numactl/numactl/0001-fix-NULL-pointer-problem.patch
new file mode 100644
index 0000000..0497613
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/numactl/numactl/0001-fix-NULL-pointer-problem.patch
@@ -0,0 +1,35 @@
+From 5c16beff9909b28f55f25f48ed7ddbf98d8b1d5c Mon Sep 17 00:00:00 2001
+From: Roy Li <rongqing.li@windriver.com>
+Date: Wed, 18 Jul 2018 09:43:55 +0800
+Subject: [PATCH] fix NULL pointer problem
+
+return 0 if distance_table is NULL
+
+Upstream-Status: Pending
+
+read_distance_table() maybe return 0, but distance_table is not set,
+if distance_table is used, and will lead to SEGFAULT
+
+Signed-off-by: Roy Li <rongqing.li@windriver.com>
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ distance.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/distance.c b/distance.c
+index 8d472af..6a6e886 100644
+--- a/distance.c
++++ b/distance.c
+@@ -113,6 +113,8 @@ int numa_distance(int a, int b)
+ 		int err = read_distance_table();
+ 		if (err < 0)
+ 			return 0;
++		if(!distance_table)
++			return 0;
+ 	}
+ 	if ((unsigned)a >= distance_numnodes || (unsigned)b >= distance_numnodes)
+ 		return 0;
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/numactl/numactl/fix-null-pointer.patch b/meta-openembedded/meta-oe/recipes-support/numactl/numactl/fix-null-pointer.patch
deleted file mode 100644
index 53952ae..0000000
--- a/meta-openembedded/meta-oe/recipes-support/numactl/numactl/fix-null-pointer.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-[PATCH] return 0 if distance_table is NULL
-
-Upstream-Status: Pending
-
-read_distance_table() maybe return 0, but distance_table is not set,
-if distance_table is used, and will lead to SEGFAULT
-
-Signed-off-by: Roy Li <rongqing.li@windriver.com>
----
- distance.c |    2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/distance.c b/distance.c
-index 4a26972..c6ca021 100755
---- a/distance.c
-+++ b/distance.c
-@@ -113,6 +113,8 @@ int numa_distance(int a, int b)
- 		int err = read_distance_table();
- 		if (err < 0)
- 			return 0;
-+		if (!distance_table)
-+			return 0;
- 	}
- 	return distance_table[a * distance_numnodes + b];
- }
--- 
-1.7.10.4
-
diff --git a/meta-openembedded/meta-oe/recipes-support/numactl/numactl_git.bb b/meta-openembedded/meta-oe/recipes-support/numactl/numactl_git.bb
index b9cbcf0..279ac04 100644
--- a/meta-openembedded/meta-oe/recipes-support/numactl/numactl_git.bb
+++ b/meta-openembedded/meta-oe/recipes-support/numactl/numactl_git.bb
@@ -5,17 +5,16 @@
 allocations with NUMA policy in applications."
 LICENSE = "GPL-2.0 & LGPL-2.1"
 SECTION = "apps"
-RDEPENDS_${PN} = "perl"
 
 inherit autotools-brokensep ptest
 
-LIC_FILES_CHKSUM = "file://README;beginline=19;endline=32;md5=5644cc3851cb2499f6c48e52fe198bd9"
+LIC_FILES_CHKSUM = "file://README.md;beginline=19;endline=32;md5=f8ff2391624f28e481299f3f677b21bb"
 
-SRCREV = "ea3a70681c2f523fe58e1d44527f478ca76db74e"
-PV = "2.0.11+git${SRCPV}"
+SRCREV = "841253d1313b01a968c380cae4f498f20c46e5aa"
+PV = "2.0.12+git${SRCPV}"
 
 SRC_URI = "git://github.com/numactl/numactl \
-    file://fix-null-pointer.patch \
+    file://0001-fix-NULL-pointer-problem.patch \
     file://Fix-the-test-output-format.patch \
     file://Makefile \
     file://run-ptest \
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0001-Remove-assumptions-about-glibc-being-only-libc-imple.patch b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0001-Remove-assumptions-about-glibc-being-only-libc-imple.patch
deleted file mode 100644
index 9773b4a..0000000
--- a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0001-Remove-assumptions-about-glibc-being-only-libc-imple.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-From a0983d84185f04c4e40778fe951fde4439894882 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 16 Jul 2017 07:37:03 -0700
-Subject: [PATCH 01/11] Remove assumptions about glibc being only libc
- implementation on linux
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- open-vm-tools/lib/file/fileIOPosix.c      | 2 +-
- open-vm-tools/lib/include/vm_basic_defs.h | 2 ++
- 2 files changed, 3 insertions(+), 1 deletion(-)
-
-Index: open-vm-tools/lib/file/fileIOPosix.c
-===================================================================
---- open-vm-tools.orig/lib/file/fileIOPosix.c
-+++ open-vm-tools/lib/file/fileIOPosix.c
-@@ -205,7 +205,7 @@ static AlignedPool alignedPool;
-  * are not available in any header file.
-  */
- 
--#if defined(__linux__) && !defined(__ANDROID__)
-+#if defined(__linux__) && defined(__GLIBC__)
-    #if defined(_FILE_OFFSET_BITS) && (_FILE_OFFSET_BITS == 64)
-       /*
-        * We want preadv/pwritev. But due to FOB=64, the symbols are -64.
-Index: open-vm-tools/lib/include/vm_basic_defs.h
-===================================================================
---- open-vm-tools.orig/lib/include/vm_basic_defs.h
-+++ open-vm-tools/lib/include/vm_basic_defs.h
-@@ -571,6 +571,7 @@ typedef int pid_t;
- #if defined __linux__ && !defined __KERNEL__ && !defined MODULE && \
-                          !defined VMM && !defined FROBOS && !defined __ANDROID__
- #include <features.h>
-+#if __GLIBC__
- #if __GLIBC_PREREQ(2, 1) && !defined GLIBC_VERSION_21
- #define GLIBC_VERSION_21
- #endif
-@@ -590,6 +591,7 @@ typedef int pid_t;
- #define GLIBC_VERSION_212
- #endif
- #endif
-+#endif
- 
- /*
-  * Convenience definitions of unicode characters.
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0001-Use-off64_t-instead-of-__off64_t.patch b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0001-Use-off64_t-instead-of-__off64_t.patch
new file mode 100644
index 0000000..432496f
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0001-Use-off64_t-instead-of-__off64_t.patch
@@ -0,0 +1,31 @@
+From 43d859f9d5eecdc0fdc1a6bf539bcde4a152e6f5 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 27 Aug 2018 23:22:21 -0700
+Subject: [PATCH] Use off64_t instead of __off64_t
+
+Fixes
+unknown type name '__off64_t'
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ lib/file/fileIOPosix.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/lib/file/fileIOPosix.c b/lib/file/fileIOPosix.c
+index 23108279..bcd2ddc5 100644
+--- a/lib/file/fileIOPosix.c
++++ b/lib/file/fileIOPosix.c
+@@ -206,10 +206,10 @@ static AlignedPool alignedPool;
+        * the symbols (and anyone building XOPEN<700 gets nothing).
+        */
+       extern ssize_t preadv64(int fd, const struct iovec *iov, int iovcnt,
+-                          __off64_t offset) __attribute__ ((weak));
++                          off64_t offset) __attribute__ ((weak));
+ 
+       extern ssize_t pwritev64(int fd, const struct iovec *iov, int iovcnt,
+-                          __off64_t offset) __attribute__ ((weak));
++                          off64_t offset) __attribute__ ((weak));
+    #else
+       #error "Large file support unavailable. Aborting."
+    #endif
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0001-configure.ac-don-t-use-dnet-config.patch b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0001-configure.ac-don-t-use-dnet-config.patch
index e9cb873..b7a4058 100644
--- a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0001-configure.ac-don-t-use-dnet-config.patch
+++ b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0001-configure.ac-don-t-use-dnet-config.patch
@@ -14,11 +14,11 @@
  configure.ac | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
 
-diff --git a/configure.ac b/configure.ac
-index 3400b86..7d6119e 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -942,7 +942,7 @@ if test "$with_dnet" = "yes"; then
+Index: open-vm-tools/configure.ac
+===================================================================
+--- open-vm-tools.orig/configure.ac
++++ open-vm-tools/configure.ac
+@@ -944,7 +944,7 @@ if test "$with_dnet" = "yes"; then
        AC_VMW_CHECK_LIB([dnet],
                         [DNET],
                         [],
@@ -27,15 +27,12 @@
                         [],
                         [dnet.h],
                         [intf_open],
-@@ -952,7 +952,7 @@ if test "$with_dnet" = "yes"; then
+@@ -954,7 +954,7 @@ if test "$with_dnet" = "yes"; then
  
     if test $have_dnet = "no"; then
  		AC_MSG_ERROR(
 -		   [dnet-config was not found on your PATH. Please configure without dnet (using --without-dnet) or install dnet - http://libdnet.sourceforge.net])
 +		   [dnet was not found. Please configure without dnet (using --without-dnet) or install dnet - http://libdnet.sourceforge.net])
- 	fi
+    fi
  fi
  
--- 
-2.1.4
-
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0001-include-poll.h-instead-of-sys-poll.h.patch b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0001-include-poll.h-instead-of-sys-poll.h.patch
new file mode 100644
index 0000000..8820581
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0001-include-poll.h-instead-of-sys-poll.h.patch
@@ -0,0 +1,26 @@
+From 4981bb3013d7f1e40e44618076d99af3484eedea Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 13 Jun 2018 23:02:50 -0700
+Subject: [PATCH] include poll.h instead of sys/poll.h
+
+including sys/poll.h is deprecated
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ open-vm-tools/lib/asyncsocket/asyncsocket.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/lib/asyncsocket/asyncsocket.c b/lib/asyncsocket/asyncsocket.c
+index 13908679..e0a68e7e 100644
+--- a/lib/asyncsocket/asyncsocket.c
++++ b/lib/asyncsocket/asyncsocket.c
+@@ -69,8 +69,8 @@
+ #else
+ #include <stddef.h>
+ #include <ctype.h>
++#include <poll.h>
+ #include <sys/types.h>
+-#include <sys/poll.h>
+ #include <sys/socket.h>
+ #include <sys/un.h>
+ #include <netdb.h>
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0002-Rename-poll.h-to-vm_poll.h.patch b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0002-Rename-poll.h-to-vm_poll.h.patch
new file mode 100644
index 0000000..4d6a0fd
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0002-Rename-poll.h-to-vm_poll.h.patch
@@ -0,0 +1,115 @@
+From 92955b3a6180b4285d11ef79766df01b9ab60dbd Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 13 Jun 2018 23:11:58 -0700
+Subject: [PATCH] Rename poll.h to vm_poll.h
+
+musl libc's system headers pulls in open-vm-tools' poll.h. To avoid this
+we rename poll.h to vm_poll.h.
+
+Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ open-vm-tools/lib/asyncsocket/asyncsocket.c                     | 2 +-
+ open-vm-tools/lib/hgfsServer/hgfsServer.c                       | 2 +-
+ open-vm-tools/lib/include/asyncsocket.h                         | 2 +-
+ open-vm-tools/lib/include/pollImpl.h                            | 2 +-
+ open-vm-tools/lib/include/{poll.h => vm_poll.h}                 | 2 +-
+ open-vm-tools/lib/rpcIn/rpcin.c                                 | 2 +-
+ .../services/plugins/grabbitmqProxy/grabbitmqProxyPlugin.c      | 2 +-
+ 7 files changed, 7 insertions(+), 7 deletions(-)
+ rename open-vm-tools/lib/include/{poll.h => vm_poll.h} (99%)
+
+diff --git a/lib/asyncsocket/asyncsocket.c b/lib/asyncsocket/asyncsocket.c
+index e0a68e7e..b9675674 100644
+--- a/lib/asyncsocket/asyncsocket.c
++++ b/lib/asyncsocket/asyncsocket.c
+@@ -86,7 +86,7 @@
+ #include "random.h"
+ #include "asyncsocket.h"
+ #include "asyncSocketBase.h"
+-#include "poll.h"
++#include "vm_poll.h"
+ #include "log.h"
+ #include "err.h"
+ #include "hostinfo.h"
+diff --git a/lib/hgfsServer/hgfsServer.c b/lib/hgfsServer/hgfsServer.c
+index 991a7941..ed0c09f9 100644
+--- a/lib/hgfsServer/hgfsServer.c
++++ b/lib/hgfsServer/hgfsServer.c
+@@ -48,7 +48,7 @@
+ #include "hgfsServerOplock.h"
+ #include "hgfsDirNotify.h"
+ #include "userlock.h"
+-#include "poll.h"
++#include "vm_poll.h"
+ #include "mutexRankLib.h"
+ #include "vm_basic_asm.h"
+ #include "unicodeOperations.h"
+diff --git a/lib/include/asyncsocket.h b/lib/include/asyncsocket.h
+index 524147ea..103f944f 100644
+--- a/lib/include/asyncsocket.h
++++ b/lib/include/asyncsocket.h
+@@ -164,7 +164,7 @@ typedef struct AsyncSocket AsyncSocket;
+  * Or the client can specify its favorite poll class and locking behavior.
+  * Use of IVmdbPoll is only supported for regular sockets and for Attach.
+  */
+-#include "poll.h"
++#include "vm_poll.h"
+ struct IVmdbPoll;
+ typedef struct AsyncSocketPollParams {
+    int flags;               /* Default 0, only POLL_FLAG_NO_BULL is valid */
+diff --git a/lib/include/pollImpl.h b/lib/include/pollImpl.h
+index 46442e55..8bc66997 100644
+--- a/lib/include/pollImpl.h
++++ b/lib/include/pollImpl.h
+@@ -44,7 +44,7 @@
+ #define INCLUDE_ALLOW_USERLEVEL
+ #include "includeCheck.h"
+ 
+-#include "poll.h"
++#include "vm_poll.h"
+ #include "vm_basic_asm.h"
+ 
+ #if defined(__cplusplus)
+diff --git a/lib/include/poll.h b/lib/include/vm_poll.h
+similarity index 99%
+rename from open-vm-tools/lib/include/poll.h
+rename to open-vm-tools/lib/include/vm_poll.h
+index 988fe6d0..e9e74fb5 100644
+--- a/lib/include/poll.h
++++ b/lib/include/vm_poll.h
+@@ -60,7 +60,7 @@ extern "C" {
+ #if !defined(TARGET_OS_IPHONE) || TARGET_OS_IPHONE == 0
+ #include <sys/kernel.h>
+ #endif
+-#include <sys/poll.h>
++#include <poll.h>
+ #define HZ 100
+ #endif
+ #ifdef __ANDROID__
+diff --git a/lib/rpcIn/rpcin.c b/lib/rpcIn/rpcin.c
+index c2c51583..d6c62f10 100644
+--- a/lib/rpcIn/rpcin.c
++++ b/lib/rpcIn/rpcin.c
+@@ -57,7 +57,7 @@
+ 
+ #if defined(VMTOOLS_USE_VSOCKET)
+ #  include <glib.h>
+-#  include "poll.h"
++#  include "vm_poll.h"
+ #  include "asyncsocket.h"
+ #  include "vmci_defs.h"
+ #include "dataMap.h"
+diff --git a/services/plugins/grabbitmqProxy/grabbitmqProxyPlugin.c b/services/plugins/grabbitmqProxy/grabbitmqProxyPlugin.c
+index 03700937..f0b49ad7 100644
+--- a/services/plugins/grabbitmqProxy/grabbitmqProxyPlugin.c
++++ b/services/plugins/grabbitmqProxy/grabbitmqProxyPlugin.c
+@@ -48,7 +48,7 @@
+ #include "rpcout.h"
+ #include "rabbitmqProxyConst.h"
+ #include "vm_basic_types.h"
+-#include "poll.h"
++#include "vm_poll.h"
+ #ifdef OPEN_VM_TOOLS
+ #include "vmci_sockets.h"
+ #include "sslDirect.h"
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0002-include-poll.h-instead-of-obsolete-sys-poll.h.patch b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0002-include-poll.h-instead-of-obsolete-sys-poll.h.patch
deleted file mode 100644
index d26bf2d..0000000
--- a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0002-include-poll.h-instead-of-obsolete-sys-poll.h.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-From d44c7c9de7380ad7b284231bd5b5c99b5c19758d Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 16 Jul 2017 07:37:59 -0700
-Subject: [PATCH 02/11] include poll.h instead of obsolete sys/poll.h
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- open-vm-tools/lib/asyncsocket/asyncSocketInt.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-Index: open-vm-tools/lib/asyncsocket/asyncSocketInt.h
-===================================================================
---- open-vm-tools.orig/lib/asyncsocket/asyncSocketInt.h
-+++ open-vm-tools/lib/asyncsocket/asyncSocketInt.h
-@@ -71,8 +71,8 @@
- #else
- #include <stddef.h>
- #include <ctype.h>
-+#include <poll.h>
- #include <sys/types.h>
--#include <sys/poll.h>
- #include <sys/socket.h>
- #include <sys/un.h>
- #include <netdb.h>
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0003-Rename-poll.h-to-vm_poll.h.patch b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0003-Rename-poll.h-to-vm_poll.h.patch
deleted file mode 100644
index 8641778..0000000
--- a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0003-Rename-poll.h-to-vm_poll.h.patch
+++ /dev/null
@@ -1,756 +0,0 @@
-From 687fca20b3417ac885b6961e6fe1126d4a3fe7a4 Mon Sep 17 00:00:00 2001
-From: Natanael Copa <ncopa@alpinelinux.org>
-Date: Tue, 17 Nov 2015 10:57:31 +0000
-Subject: [PATCH 03/11] Rename poll.h to vm_poll.h
-
-musl libc's system headers pulls in open-vm-tools' poll.h. To avoid this
-we rename poll.h to vm_poll.h.
-
-Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
----
- open-vm-tools/lib/asyncsocket/asyncsocket.c                          | 2 +-
- open-vm-tools/lib/hgfsServer/hgfsServer.c                            | 2 +-
- open-vm-tools/lib/include/asyncsocket.h                              | 2 +-
- open-vm-tools/lib/include/pollImpl.h                                 | 2 +-
- open-vm-tools/lib/include/{poll.h => vm_poll.h}                      | 0
- open-vm-tools/lib/rpcIn/rpcin.c                                      | 2 +-
- open-vm-tools/services/plugins/grabbitmqProxy/grabbitmqProxyPlugin.c | 2 +-
- 7 files changed, 6 insertions(+), 6 deletions(-)
- rename open-vm-tools/lib/include/{poll.h => vm_poll.h} (100%)
-
-Index: open-vm-tools/lib/asyncsocket/asyncsocket.c
-===================================================================
---- open-vm-tools.orig/lib/asyncsocket/asyncsocket.c
-+++ open-vm-tools/lib/asyncsocket/asyncsocket.c
-@@ -52,7 +52,7 @@
- #include "vmware.h"
- #include "asyncsocket.h"
- #include "asyncSocketInt.h"
--#include "poll.h"
-+#include "vm_poll.h"
- #include "log.h"
- #include "err.h"
- #include "hostinfo.h"
-Index: open-vm-tools/lib/hgfsServer/hgfsServer.c
-===================================================================
---- open-vm-tools.orig/lib/hgfsServer/hgfsServer.c
-+++ open-vm-tools/lib/hgfsServer/hgfsServer.c
-@@ -48,7 +48,7 @@
- #include "hgfsServerOplock.h"
- #include "hgfsDirNotify.h"
- #include "userlock.h"
--#include "poll.h"
-+#include "vm_poll.h"
- #include "mutexRankLib.h"
- #include "vm_basic_asm.h"
- #include "unicodeOperations.h"
-Index: open-vm-tools/lib/include/asyncsocket.h
-===================================================================
---- open-vm-tools.orig/lib/include/asyncsocket.h
-+++ open-vm-tools/lib/include/asyncsocket.h
-@@ -129,7 +129,7 @@ typedef struct AsyncSocket AsyncSocket;
-  * Or the client can specify its favorite poll class and locking behavior.
-  * Use of IVmdbPoll is only supported for regular sockets and for Attach.
-  */
--#include "poll.h"
-+#include "vm_poll.h"
- struct IVmdbPoll;
- typedef struct AsyncSocketPollParams {
-    int flags;               /* Default 0, only POLL_FLAG_NO_BULL is valid */
-Index: open-vm-tools/lib/include/poll.h
-===================================================================
---- open-vm-tools.orig/lib/include/poll.h
-+++ /dev/null
-@@ -1,324 +0,0 @@
--/*********************************************************
-- * Copyright (C) 1998-2016 VMware, Inc. All rights reserved.
-- *
-- * This program is free software; you can redistribute it and/or modify it
-- * under the terms of the GNU Lesser General Public License as published
-- * by the Free Software Foundation version 2.1 and no later version.
-- *
-- * This program is distributed in the hope that it will be useful, but
-- * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
-- * or FITNESS FOR A PARTICULAR PURPOSE.  See the Lesser GNU General Public
-- * License for more details.
-- *
-- * You should have received a copy of the GNU Lesser General Public License
-- * along with this program; if not, write to the Free Software Foundation, Inc.,
-- * 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA.
-- *
-- *********************************************************/
--
--/*********************************************************
-- * The contents of this file are subject to the terms of the Common
-- * Development and Distribution License (the "License") version 1.0
-- * and no later version.  You may not use this file except in
-- * compliance with the License.
-- *
-- * You can obtain a copy of the License at
-- *         http://www.opensource.org/licenses/cddl1.php
-- *
-- * See the License for the specific language governing permissions
-- * and limitations under the License.
-- *
-- *********************************************************/
--
--
--#ifndef _POLL_H_
--#define _POLL_H_
--
--#define INCLUDE_ALLOW_USERLEVEL
--#define INCLUDE_ALLOW_VMCORE
--#include "includeCheck.h"
--
--#include "vm_basic_types.h"
--#include "vm_basic_defs.h"
--#include "vmware.h"
--#include "userlock.h"
--
--#ifdef _WIN32
--#define HZ 100
--#elif defined linux
--#include <asm/param.h>
--#elif __APPLE__
--#include <TargetConditionals.h>
--/*
-- * Old SDKs don't define TARGET_OS_IPHONE at all.
-- * New ones define it to 0 on Mac OS X, 1 on iOS.
-- */
--#if !defined(TARGET_OS_IPHONE) || TARGET_OS_IPHONE == 0
--#include <sys/kernel.h>
--#endif
--#include <sys/poll.h>
--#define HZ 100
--#endif
--#ifdef __ANDROID__
--/*
-- * <poll.h> of android should be included, but its name is same
-- * with this file. So its content is put here to avoid conflict.
-- */
--#include <asm/poll.h>
--#define HZ 100
--typedef unsigned int  nfds_t;
--int poll(struct pollfd *, nfds_t, long);
--#endif
--
--
--/*
-- * Poll event types: each type has a different reason for firing,
-- * or condition that must be met before firing.
-- */
--
--typedef enum {
--   /*
--    * Actual Poll queue types against which you can register callbacks.
--    */
--   POLL_VIRTUALREALTIME = -1, /* Negative because it doesn't have its own Q */
--   POLL_VTIME = 0,
--   POLL_REALTIME,
--   POLL_DEVICE,
--   POLL_MAIN_LOOP,
--   POLL_NUM_QUEUES
--} PollEventType;
--
--
--/*
-- * Classes of events
-- *
-- * These are the predefined classes.  More can be declared
-- * with Poll_AllocClass().
-- */
--
--typedef enum PollClass {
--   POLL_CLASS_MAIN,
--   POLL_CLASS_PAUSE,
--   POLL_CLASS_IPC,
--   POLL_CLASS_CPT,
--   POLL_CLASS_MKS,
--   POLL_FIXED_CLASSES,
--   POLL_MAX_CLASSES = 320 /* Size enum to maximum */
--} PollClass;
--
--
--/*
-- * Each callback is registered in a set of classes
-- */
--
--typedef struct PollClassSet {
--   /* Type is uintptr_t to give best 32/64-bit code. */
--#define _POLL_ELEMSIZE (sizeof (uintptr_t) * 8)
--   uintptr_t bits[CEILING(POLL_MAX_CLASSES, _POLL_ELEMSIZE)];
--} PollClassSet;
--
--/* An empty PollClassSet. */
--static INLINE PollClassSet
--PollClassSet_Empty(void)
--{
--   PollClassSet set = { { 0 } };
--   return set;
--}
--
--/* A PollClassSet with the single member. */
--static INLINE PollClassSet
--PollClassSet_Singleton(PollClass c)
--{
--   PollClassSet s = PollClassSet_Empty();
--
--   ASSERT_ON_COMPILE(sizeof s.bits[0] * 8 == _POLL_ELEMSIZE); /* Size correct */
--   ASSERT_ON_COMPILE((_POLL_ELEMSIZE & (_POLL_ELEMSIZE - 1)) == 0); /* power of 2 */
--   ASSERT_ON_COMPILE(POLL_MAX_CLASSES <= ARRAYSIZE(s.bits) * _POLL_ELEMSIZE);
--   ASSERT(c < POLL_MAX_CLASSES);
--
--   s.bits[c / _POLL_ELEMSIZE] = CONST3264U(1) << (c % _POLL_ELEMSIZE);
--   return s;
--}
--
--/* Combine two PollClassSets. */
--static INLINE PollClassSet
--PollClassSet_Union(PollClassSet lhs, PollClassSet rhs)
--{
--   PollClassSet u;
--   unsigned i;
--
--   for (i = 0; i < ARRAYSIZE(u.bits); i++) {
--      u.bits[i] = lhs.bits[i] | rhs.bits[i];
--   }
--   return u;
--}
--
--/* Add single class to PollClassSet. */
--static INLINE PollClassSet
--PollClassSet_Include(PollClassSet set, PollClass c)
--{
--   return PollClassSet_Union(set, PollClassSet_Singleton(c));
--}
--
--
--#define POLL_CS_MAIN    PollClassSet_Singleton(POLL_CLASS_MAIN)
--#define POLL_CS_PAUSE   PollClassSet_Union(POLL_CS_MAIN,            \
--                           PollClassSet_Singleton(POLL_CLASS_PAUSE))
--#define POLL_CS_CPT     PollClassSet_Union(POLL_CS_PAUSE,           \
--                           PollClassSet_Singleton(POLL_CLASS_CPT))
--#define POLL_CS_IPC     PollClassSet_Union(POLL_CS_CPT,             \
--                           PollClassSet_Singleton(POLL_CLASS_IPC))
--#define POLL_CS_VMDB    POLL_CS_PAUSE /* POLL_CLASS_VMDB is retired */
--#define POLL_CS_MKS	PollClassSet_Singleton(POLL_CLASS_MKS)
--/* 
-- * DANGER.  You don't need POLL_CS_ALWAYS.  Really.  So don't use it.
-- */
--#define POLL_CS_ALWAYS  PollClassSet_Union(POLL_CS_CPT, POLL_CS_IPC)
--
--/*
-- * Poll class-set taxonomy:
-- * POLL_CS_MAIN
-- *    - Unless you NEED another class, use POLL_CS_MAIN.
-- * POLL_CS_PAUSE
-- *    - For callbacks that must occur even if the guest is paused.
-- *      Most VMDB or Foundry commands are in this category.
-- * POLL_CS_CPT
-- *    - Only for callbacks which can trigger intermediate Checkpoint 
-- *      transitions.
-- *      The ONLY such callback is Migrate.
-- * POLL_CS_IPC
-- *    - Only for callbacks which can contain Msg_(Post|Hint|Question) 
-- *      responses, and for signal handlers (why)?
-- *      Vigor, VMDB, and Foundry can contain Msg_* responses.
-- * POLL_CS_MKS
-- *    - Callback runs in MKS thread.
-- * POLL_CS_ALWAYS
-- *    - Only for events that must be processed immediately.
-- *      The ONLY such callback is OvhdMemVmxSizeCheck.
-- */
--
--
--/*
-- * Poll_Callback flags
-- */
--
--#define POLL_FLAG_PERIODIC		0x01    // keep after firing
--#define POLL_FLAG_REMOVE_AT_POWEROFF	0x02  	// self-explanatory
--#define POLL_FLAG_READ			0x04	// device is ready for reading
--#define POLL_FLAG_WRITE			0x08	// device is ready for writing
--#define POLL_FLAG_SOCKET                0x10    // device is a Windows socket
--#define POLL_FLAG_NO_BULL               0x20    // callback does its own locking
--#define POLL_FLAG_WINSOCK               0x40    // Winsock style write events
--#define POLL_FLAG_FD                    0x80    // device is a Windows file descriptor.
--#define POLL_FLAG_ACCEPT_INVALID_FDS    0x100   // For broken 3rd party libs, e.g. curl
--#define POLL_FLAG_THUNK_TO_WND          0x200   // thunk callback to window message loop
--
--
--/*
-- * Advisory minimum time period.
-- * Users that want the fastest running real-time poll
-- * should use TICKS_TO_USECS(1).
-- */
--
--#define TICKS_TO_USECS(_x) ((_x) * (1000000 / HZ))
--#define USECS_TO_TICKS(_x) ((_x) / (1000000 / HZ))
--
--
--typedef void (*PollerFunction)(void *clientData);
--typedef void (*PollerFireWrapper)(PollerFunction func,
--                                  void *funcData,
--                                  void *wrapperData);
--typedef Bool (*PollerErrorFn)(const char *errorStr);
--
--/*
-- * Initialisers:
-- *
-- *      For the sake of convenience, we declare the initialisers
-- *      for custom implmentations here, even though the actual
-- *      implementations are distinct from the core poll code.
-- */
--
--typedef struct PollOptions {
--   Bool locked;           // Use internal MXUser for locking
--   Bool allowFullQueue;   // Don't assert when device event queue is full.
--   VThreadID windowsMsgThread;       // thread that processes Windows messages
--   PollerFireWrapper fireWrapperFn;  // optional; may be useful for stats
--   void *fireWrapperData; // optional
--   PollerErrorFn errorFn; // optional; called upon unrecoverable error
--} PollOptions;
--
--
--void Poll_InitDefault(void);
--void Poll_InitDefaultEx(const PollOptions *opts);
--void Poll_InitGtk(void); // On top of glib for Linux
--void Poll_InitCF(void);  // On top of CoreFoundation for OSX
--
--
--/*
-- * Functions
-- */
--int Poll_SocketPair(Bool vmci, Bool stream, int fds[2]);
--void Poll_Loop(Bool loop, Bool *exit, PollClass c);
--void Poll_LoopTimeout(Bool loop, Bool *exit, PollClass c, int timeout);
--Bool Poll_LockingEnabled(void);
--void Poll_Exit(void);
--
--
--/*
-- * Poll_Callback adds a callback regardless of whether an identical one exists.
-- *
-- * Likewise, Poll_CallbackRemove removes exactly one callback.
-- */
--
--VMwareStatus Poll_Callback(PollClassSet classSet,
--                           int flags,
--                           PollerFunction f,
--                           void *clientData,
--                           PollEventType type,
--                           PollDevHandle info, // fd/microsec delay
--                           MXUserRecLock *lck);
--Bool Poll_CallbackRemove(PollClassSet classSet,
--                         int flags,
--                         PollerFunction f,
--                         void *clientData,
--                         PollEventType type);
--Bool Poll_CallbackRemoveOneByCB(PollClassSet classSet,
--                                int flags,
--                                PollerFunction f,
--                                PollEventType type,
--                                void **clientData);
--
--void Poll_NotifyChange(PollClassSet classSet);
--
--/*
-- * Wrappers for Poll_Callback and Poll_CallbackRemove that present
-- * simpler subsets of those interfaces.
-- */
--
--VMwareStatus Poll_CB_Device(PollerFunction f,
--                            void *clientData,
--                            PollDevHandle device,
--                            Bool periodic);
--
--Bool Poll_CB_DeviceRemove(PollerFunction f,
--                          void *clientData,
--                          Bool periodic);
--
--
--VMwareStatus Poll_CB_RTime(PollerFunction f,
--                           void *clientData,
--                           int delay,	// microseconds
--                           Bool periodic,
--                           MXUserRecLock *lock);
--
--Bool Poll_CB_RTimeRemove(PollerFunction f,
--                         void *clientData,
--                         Bool periodic);
--
--
--#ifdef _WIN32
--void Poll_SetWindowMessageRecipient(HWND hWnd, UINT msg, Bool alwaysThunk);
--Bool Poll_FireWndCallback(void *lparam);
--#endif
--
--#endif // _POLL_H_
-Index: open-vm-tools/lib/include/pollImpl.h
-===================================================================
---- open-vm-tools.orig/lib/include/pollImpl.h
-+++ open-vm-tools/lib/include/pollImpl.h
-@@ -44,7 +44,7 @@
- #define INCLUDE_ALLOW_USERLEVEL
- #include "includeCheck.h"
- 
--#include "poll.h"
-+#include "vm_poll.h"
- 
- /*
-  * PollImpl:
-Index: open-vm-tools/lib/include/vm_poll.h
-===================================================================
---- /dev/null
-+++ open-vm-tools/lib/include/vm_poll.h
-@@ -0,0 +1,324 @@
-+/*********************************************************
-+ * Copyright (C) 1998-2016 VMware, Inc. All rights reserved.
-+ *
-+ * This program is free software; you can redistribute it and/or modify it
-+ * under the terms of the GNU Lesser General Public License as published
-+ * by the Free Software Foundation version 2.1 and no later version.
-+ *
-+ * This program is distributed in the hope that it will be useful, but
-+ * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
-+ * or FITNESS FOR A PARTICULAR PURPOSE.  See the Lesser GNU General Public
-+ * License for more details.
-+ *
-+ * You should have received a copy of the GNU Lesser General Public License
-+ * along with this program; if not, write to the Free Software Foundation, Inc.,
-+ * 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA.
-+ *
-+ *********************************************************/
-+
-+/*********************************************************
-+ * The contents of this file are subject to the terms of the Common
-+ * Development and Distribution License (the "License") version 1.0
-+ * and no later version.  You may not use this file except in
-+ * compliance with the License.
-+ *
-+ * You can obtain a copy of the License at
-+ *         http://www.opensource.org/licenses/cddl1.php
-+ *
-+ * See the License for the specific language governing permissions
-+ * and limitations under the License.
-+ *
-+ *********************************************************/
-+
-+
-+#ifndef _POLL_H_
-+#define _POLL_H_
-+
-+#define INCLUDE_ALLOW_USERLEVEL
-+#define INCLUDE_ALLOW_VMCORE
-+#include "includeCheck.h"
-+
-+#include "vm_basic_types.h"
-+#include "vm_basic_defs.h"
-+#include "vmware.h"
-+#include "userlock.h"
-+
-+#ifdef _WIN32
-+#define HZ 100
-+#elif defined linux
-+#include <asm/param.h>
-+#elif __APPLE__
-+#include <TargetConditionals.h>
-+/*
-+ * Old SDKs don't define TARGET_OS_IPHONE at all.
-+ * New ones define it to 0 on Mac OS X, 1 on iOS.
-+ */
-+#if !defined(TARGET_OS_IPHONE) || TARGET_OS_IPHONE == 0
-+#include <sys/kernel.h>
-+#endif
-+#include <sys/poll.h>
-+#define HZ 100
-+#endif
-+#ifdef __ANDROID__
-+/*
-+ * <poll.h> of android should be included, but its name is same
-+ * with this file. So its content is put here to avoid conflict.
-+ */
-+#include <asm/poll.h>
-+#define HZ 100
-+typedef unsigned int  nfds_t;
-+int poll(struct pollfd *, nfds_t, long);
-+#endif
-+
-+
-+/*
-+ * Poll event types: each type has a different reason for firing,
-+ * or condition that must be met before firing.
-+ */
-+
-+typedef enum {
-+   /*
-+    * Actual Poll queue types against which you can register callbacks.
-+    */
-+   POLL_VIRTUALREALTIME = -1, /* Negative because it doesn't have its own Q */
-+   POLL_VTIME = 0,
-+   POLL_REALTIME,
-+   POLL_DEVICE,
-+   POLL_MAIN_LOOP,
-+   POLL_NUM_QUEUES
-+} PollEventType;
-+
-+
-+/*
-+ * Classes of events
-+ *
-+ * These are the predefined classes.  More can be declared
-+ * with Poll_AllocClass().
-+ */
-+
-+typedef enum PollClass {
-+   POLL_CLASS_MAIN,
-+   POLL_CLASS_PAUSE,
-+   POLL_CLASS_IPC,
-+   POLL_CLASS_CPT,
-+   POLL_CLASS_MKS,
-+   POLL_FIXED_CLASSES,
-+   POLL_MAX_CLASSES = 320 /* Size enum to maximum */
-+} PollClass;
-+
-+
-+/*
-+ * Each callback is registered in a set of classes
-+ */
-+
-+typedef struct PollClassSet {
-+   /* Type is uintptr_t to give best 32/64-bit code. */
-+#define _POLL_ELEMSIZE (sizeof (uintptr_t) * 8)
-+   uintptr_t bits[CEILING(POLL_MAX_CLASSES, _POLL_ELEMSIZE)];
-+} PollClassSet;
-+
-+/* An empty PollClassSet. */
-+static INLINE PollClassSet
-+PollClassSet_Empty(void)
-+{
-+   PollClassSet set = { { 0 } };
-+   return set;
-+}
-+
-+/* A PollClassSet with the single member. */
-+static INLINE PollClassSet
-+PollClassSet_Singleton(PollClass c)
-+{
-+   PollClassSet s = PollClassSet_Empty();
-+
-+   ASSERT_ON_COMPILE(sizeof s.bits[0] * 8 == _POLL_ELEMSIZE); /* Size correct */
-+   ASSERT_ON_COMPILE((_POLL_ELEMSIZE & (_POLL_ELEMSIZE - 1)) == 0); /* power of 2 */
-+   ASSERT_ON_COMPILE(POLL_MAX_CLASSES <= ARRAYSIZE(s.bits) * _POLL_ELEMSIZE);
-+   ASSERT(c < POLL_MAX_CLASSES);
-+
-+   s.bits[c / _POLL_ELEMSIZE] = CONST3264U(1) << (c % _POLL_ELEMSIZE);
-+   return s;
-+}
-+
-+/* Combine two PollClassSets. */
-+static INLINE PollClassSet
-+PollClassSet_Union(PollClassSet lhs, PollClassSet rhs)
-+{
-+   PollClassSet u;
-+   unsigned i;
-+
-+   for (i = 0; i < ARRAYSIZE(u.bits); i++) {
-+      u.bits[i] = lhs.bits[i] | rhs.bits[i];
-+   }
-+   return u;
-+}
-+
-+/* Add single class to PollClassSet. */
-+static INLINE PollClassSet
-+PollClassSet_Include(PollClassSet set, PollClass c)
-+{
-+   return PollClassSet_Union(set, PollClassSet_Singleton(c));
-+}
-+
-+
-+#define POLL_CS_MAIN    PollClassSet_Singleton(POLL_CLASS_MAIN)
-+#define POLL_CS_PAUSE   PollClassSet_Union(POLL_CS_MAIN,            \
-+                           PollClassSet_Singleton(POLL_CLASS_PAUSE))
-+#define POLL_CS_CPT     PollClassSet_Union(POLL_CS_PAUSE,           \
-+                           PollClassSet_Singleton(POLL_CLASS_CPT))
-+#define POLL_CS_IPC     PollClassSet_Union(POLL_CS_CPT,             \
-+                           PollClassSet_Singleton(POLL_CLASS_IPC))
-+#define POLL_CS_VMDB    POLL_CS_PAUSE /* POLL_CLASS_VMDB is retired */
-+#define POLL_CS_MKS	PollClassSet_Singleton(POLL_CLASS_MKS)
-+/* 
-+ * DANGER.  You don't need POLL_CS_ALWAYS.  Really.  So don't use it.
-+ */
-+#define POLL_CS_ALWAYS  PollClassSet_Union(POLL_CS_CPT, POLL_CS_IPC)
-+
-+/*
-+ * Poll class-set taxonomy:
-+ * POLL_CS_MAIN
-+ *    - Unless you NEED another class, use POLL_CS_MAIN.
-+ * POLL_CS_PAUSE
-+ *    - For callbacks that must occur even if the guest is paused.
-+ *      Most VMDB or Foundry commands are in this category.
-+ * POLL_CS_CPT
-+ *    - Only for callbacks which can trigger intermediate Checkpoint 
-+ *      transitions.
-+ *      The ONLY such callback is Migrate.
-+ * POLL_CS_IPC
-+ *    - Only for callbacks which can contain Msg_(Post|Hint|Question) 
-+ *      responses, and for signal handlers (why)?
-+ *      Vigor, VMDB, and Foundry can contain Msg_* responses.
-+ * POLL_CS_MKS
-+ *    - Callback runs in MKS thread.
-+ * POLL_CS_ALWAYS
-+ *    - Only for events that must be processed immediately.
-+ *      The ONLY such callback is OvhdMemVmxSizeCheck.
-+ */
-+
-+
-+/*
-+ * Poll_Callback flags
-+ */
-+
-+#define POLL_FLAG_PERIODIC		0x01    // keep after firing
-+#define POLL_FLAG_REMOVE_AT_POWEROFF	0x02  	// self-explanatory
-+#define POLL_FLAG_READ			0x04	// device is ready for reading
-+#define POLL_FLAG_WRITE			0x08	// device is ready for writing
-+#define POLL_FLAG_SOCKET                0x10    // device is a Windows socket
-+#define POLL_FLAG_NO_BULL               0x20    // callback does its own locking
-+#define POLL_FLAG_WINSOCK               0x40    // Winsock style write events
-+#define POLL_FLAG_FD                    0x80    // device is a Windows file descriptor.
-+#define POLL_FLAG_ACCEPT_INVALID_FDS    0x100   // For broken 3rd party libs, e.g. curl
-+#define POLL_FLAG_THUNK_TO_WND          0x200   // thunk callback to window message loop
-+
-+
-+/*
-+ * Advisory minimum time period.
-+ * Users that want the fastest running real-time poll
-+ * should use TICKS_TO_USECS(1).
-+ */
-+
-+#define TICKS_TO_USECS(_x) ((_x) * (1000000 / HZ))
-+#define USECS_TO_TICKS(_x) ((_x) / (1000000 / HZ))
-+
-+
-+typedef void (*PollerFunction)(void *clientData);
-+typedef void (*PollerFireWrapper)(PollerFunction func,
-+                                  void *funcData,
-+                                  void *wrapperData);
-+typedef Bool (*PollerErrorFn)(const char *errorStr);
-+
-+/*
-+ * Initialisers:
-+ *
-+ *      For the sake of convenience, we declare the initialisers
-+ *      for custom implmentations here, even though the actual
-+ *      implementations are distinct from the core poll code.
-+ */
-+
-+typedef struct PollOptions {
-+   Bool locked;           // Use internal MXUser for locking
-+   Bool allowFullQueue;   // Don't assert when device event queue is full.
-+   VThreadID windowsMsgThread;       // thread that processes Windows messages
-+   PollerFireWrapper fireWrapperFn;  // optional; may be useful for stats
-+   void *fireWrapperData; // optional
-+   PollerErrorFn errorFn; // optional; called upon unrecoverable error
-+} PollOptions;
-+
-+
-+void Poll_InitDefault(void);
-+void Poll_InitDefaultEx(const PollOptions *opts);
-+void Poll_InitGtk(void); // On top of glib for Linux
-+void Poll_InitCF(void);  // On top of CoreFoundation for OSX
-+
-+
-+/*
-+ * Functions
-+ */
-+int Poll_SocketPair(Bool vmci, Bool stream, int fds[2]);
-+void Poll_Loop(Bool loop, Bool *exit, PollClass c);
-+void Poll_LoopTimeout(Bool loop, Bool *exit, PollClass c, int timeout);
-+Bool Poll_LockingEnabled(void);
-+void Poll_Exit(void);
-+
-+
-+/*
-+ * Poll_Callback adds a callback regardless of whether an identical one exists.
-+ *
-+ * Likewise, Poll_CallbackRemove removes exactly one callback.
-+ */
-+
-+VMwareStatus Poll_Callback(PollClassSet classSet,
-+                           int flags,
-+                           PollerFunction f,
-+                           void *clientData,
-+                           PollEventType type,
-+                           PollDevHandle info, // fd/microsec delay
-+                           MXUserRecLock *lck);
-+Bool Poll_CallbackRemove(PollClassSet classSet,
-+                         int flags,
-+                         PollerFunction f,
-+                         void *clientData,
-+                         PollEventType type);
-+Bool Poll_CallbackRemoveOneByCB(PollClassSet classSet,
-+                                int flags,
-+                                PollerFunction f,
-+                                PollEventType type,
-+                                void **clientData);
-+
-+void Poll_NotifyChange(PollClassSet classSet);
-+
-+/*
-+ * Wrappers for Poll_Callback and Poll_CallbackRemove that present
-+ * simpler subsets of those interfaces.
-+ */
-+
-+VMwareStatus Poll_CB_Device(PollerFunction f,
-+                            void *clientData,
-+                            PollDevHandle device,
-+                            Bool periodic);
-+
-+Bool Poll_CB_DeviceRemove(PollerFunction f,
-+                          void *clientData,
-+                          Bool periodic);
-+
-+
-+VMwareStatus Poll_CB_RTime(PollerFunction f,
-+                           void *clientData,
-+                           int delay,	// microseconds
-+                           Bool periodic,
-+                           MXUserRecLock *lock);
-+
-+Bool Poll_CB_RTimeRemove(PollerFunction f,
-+                         void *clientData,
-+                         Bool periodic);
-+
-+
-+#ifdef _WIN32
-+void Poll_SetWindowMessageRecipient(HWND hWnd, UINT msg, Bool alwaysThunk);
-+Bool Poll_FireWndCallback(void *lparam);
-+#endif
-+
-+#endif // _POLL_H_
-Index: open-vm-tools/lib/rpcIn/rpcin.c
-===================================================================
---- open-vm-tools.orig/lib/rpcIn/rpcin.c
-+++ open-vm-tools/lib/rpcIn/rpcin.c
-@@ -57,7 +57,7 @@
- 
- #if defined(VMTOOLS_USE_VSOCKET)
- #  include <glib.h>
--#  include "poll.h"
-+#  include "vm_poll.h"
- #  include "asyncsocket.h"
- #  include "vmci_defs.h"
- #include "dataMap.h"
-Index: open-vm-tools/services/plugins/grabbitmqProxy/grabbitmqProxyPlugin.c
-===================================================================
---- open-vm-tools.orig/services/plugins/grabbitmqProxy/grabbitmqProxyPlugin.c
-+++ open-vm-tools/services/plugins/grabbitmqProxy/grabbitmqProxyPlugin.c
-@@ -48,7 +48,7 @@
- #include "rpcout.h"
- #include "rabbitmqProxyConst.h"
- #include "vm_basic_types.h"
--#include "poll.h"
-+#include "vm_poll.h"
- #ifdef OPEN_VM_TOOLS
- #include "vmci_sockets.h"
- #include "sslDirect.h"
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0003-use-posix-strerror_r-unless-on-gnu-libc-system.patch b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0003-use-posix-strerror_r-unless-on-gnu-libc-system.patch
new file mode 100644
index 0000000..c7d34c5
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0003-use-posix-strerror_r-unless-on-gnu-libc-system.patch
@@ -0,0 +1,39 @@
+From a2e7d9273261c5c5cbc33796900f415097f5455e Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 13 Jun 2018 23:16:53 -0700
+Subject: [PATCH] use posix strerror_r unless on gnu libc system
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ open-vm-tools/lib/err/errPosix.c | 9 ++++++---
+ 1 file changed, 6 insertions(+), 3 deletions(-)
+
+diff --git a/lib/err/errPosix.c b/lib/err/errPosix.c
+index c81b4c13..7a403640 100644
+--- a/lib/err/errPosix.c
++++ b/lib/err/errPosix.c
+@@ -31,6 +31,7 @@
+ #include <errno.h>
+ #include <string.h>
+ #include <locale.h>
++#include <stdio.h>
+ 
+ #include "vmware.h"
+ #include "errInt.h"
+@@ -63,11 +64,13 @@ ErrErrno2String(Err_Number errorNumber, // IN
+ {
+    char *p;
+ 
+-#if defined(__linux__) && !defined(__ANDROID__)
++#if defined(__GLIBC__) && !defined(__ANDROID__)
+    p = strerror_r(errorNumber, buf, bufSize);
+ #else
+-   p = strerror(errorNumber);
+-#endif
++   if (strerror_r(errorNumber, buf, bufSize) != 0)
++      snprintf(buf, bufSize, "unknown error %i", errorNumber);
++   p = buf;
++#endif /* defined __GLIBC__ */
+    ASSERT(p != NULL);
+    return p;
+ }
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0004-Add-Wno-incompatible-pointer-types-and-Wno-error-add.patch b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0004-Add-Wno-incompatible-pointer-types-and-Wno-error-add.patch
deleted file mode 100644
index 0105167..0000000
--- a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0004-Add-Wno-incompatible-pointer-types-and-Wno-error-add.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From cdb0b3c898c6b6b6c8259d9ddb8b00163ac5e419 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 16 Jul 2017 09:43:18 -0700
-Subject: [PATCH 04/11] Add -Wno-incompatible-pointer-types and
- -Wno-error=address
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- open-vm-tools/lib/dynxdr/Makefile.am | 2 +-
- open-vm-tools/lib/file/Makefile.am   | 1 +
- 2 files changed, 2 insertions(+), 1 deletion(-)
-
-Index: open-vm-tools/lib/dynxdr/Makefile.am
-===================================================================
---- open-vm-tools.orig/lib/dynxdr/Makefile.am
-+++ open-vm-tools/lib/dynxdr/Makefile.am
-@@ -20,4 +20,4 @@ noinst_LTLIBRARIES = libDynxdr.la
- libDynxdr_la_SOURCES = 
- libDynxdr_la_SOURCES += dynxdr.c
- libDynxdr_la_SOURCES += xdrutil.c
--
-+libDynxdr_la_CPPFLAGS = -Wno-incompatible-pointer-types
-Index: open-vm-tools/lib/file/Makefile.am
-===================================================================
---- open-vm-tools.orig/lib/file/Makefile.am
-+++ open-vm-tools/lib/file/Makefile.am
-@@ -27,3 +27,4 @@ libFile_la_SOURCES += fileLockPrimitive.
- libFile_la_SOURCES += fileLockPosix.c
- libFile_la_SOURCES += fileTempPosix.c
- libFile_la_SOURCES += fileTemp.c
-+libFile_la_CPPFLAGS = -Wno-error=address
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0004-Use-uintmax_t-for-handling-rlim_t.patch b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0004-Use-uintmax_t-for-handling-rlim_t.patch
new file mode 100644
index 0000000..e802dca
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0004-Use-uintmax_t-for-handling-rlim_t.patch
@@ -0,0 +1,29 @@
+From e694a122c1ff32d8b951ae55756796f9576d23ed Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 13 Jun 2018 23:37:09 -0700
+Subject: [PATCH] Use uintmax_t for handling rlim_t
+
+rlimit types are not representable with long or long long
+formats, therefore use uintmax_t to typecast rlim_t types
+and use %j to print it
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ open-vm-tools/lib/hgfsServer/hgfsServerLinux.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/lib/hgfsServer/hgfsServerLinux.c b/lib/hgfsServer/hgfsServerLinux.c
+index 2e73707d..a2fdb850 100644
+--- a/lib/hgfsServer/hgfsServerLinux.c
++++ b/lib/hgfsServer/hgfsServerLinux.c
+@@ -5294,8 +5294,8 @@ HgfsWriteCheckIORange(off_t offset,         // IN:
+       goto exit;
+    }
+ 
+-   LOG(6, ("%s: File Size limits: 0x%"FMT64"x 0x%"FMT64"x\n",
+-           __FUNCTION__, fileSize.rlim_cur, fileSize.rlim_max));
++   LOG(6, ("%s: File Size limits: 0x%jx 0x%jx\n",
++           __FUNCTION__, (uintmax_t)fileSize.rlim_cur, (uintmax_t)fileSize.rlim_max));
+ 
+    /*
+     * Check the offset is within the file size range.
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0007-Use-configure-to-test-for-feature-instead-of-platfor.patch b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0007-Use-configure-to-test-for-feature-instead-of-platfor.patch
index 5adf9b0..ad19fb2 100644
--- a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0007-Use-configure-to-test-for-feature-instead-of-platfor.patch
+++ b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0007-Use-configure-to-test-for-feature-instead-of-platfor.patch
@@ -29,7 +29,7 @@
 ===================================================================
 --- open-vm-tools.orig/configure.ac
 +++ open-vm-tools/configure.ac
-@@ -798,6 +798,7 @@ AC_CHECK_FUNCS(
+@@ -892,6 +892,7 @@ AC_CHECK_FUNCS(
  
  AC_CHECK_FUNCS([ecvt])
  AC_CHECK_FUNCS([fcvt])
@@ -37,7 +37,7 @@
  
  AC_CHECK_FUNC([mkdtemp], [have_mkdtemp=yes])
  
-@@ -1063,10 +1064,13 @@ AC_PATH_PROG(
+@@ -1076,10 +1077,13 @@ AC_PATH_PROG(
  ###
  
  AC_CHECK_HEADERS([crypt.h])
@@ -133,12 +133,3 @@
  # include <net/if.h>
  #endif
  #ifndef NO_DNET
-@@ -348,7 +352,7 @@ GuestInfoGetNicInfo(NicInfoV3 *nicInfo)
-  *
-  ******************************************************************************
-  */
--#if defined(__FreeBSD__) || defined(__APPLE__) || defined(USERWORLD)
-+#if defined(NO_DNET) && defined(HAVE_GETIFADDRS)
- 
- char *
- GuestInfoGetPrimaryIP(void)
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0008-use-posix-strerror_r-unless-gnu.patch b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0008-use-posix-strerror_r-unless-gnu.patch
deleted file mode 100644
index 3d1291c..0000000
--- a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0008-use-posix-strerror_r-unless-gnu.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From d4d1e7146ca2698089f6bd532f2fb8b9c1134ca7 Mon Sep 17 00:00:00 2001
-From: Natanael Copa <ncopa@alpinelinux.org>
-Date: Mon, 2 Jan 2017 14:39:27 +0000
-Subject: [PATCH 08/11] use posix strerror_r unless gnu
-
----
- open-vm-tools/lib/err/errPosix.c | 8 +++++---
- 1 file changed, 5 insertions(+), 3 deletions(-)
-
-Index: open-vm-tools/lib/err/errPosix.c
-===================================================================
---- open-vm-tools.orig/lib/err/errPosix.c
-+++ open-vm-tools/lib/err/errPosix.c
-@@ -63,11 +63,13 @@ ErrErrno2String(Err_Number errorNumber,
- {
-    char *p;
- 
--#if defined(linux) && !defined(N_PLAT_NLM) && !defined(__ANDROID__)
-+#if defined(__GLIBC__)
-    p = strerror_r(errorNumber, buf, bufSize);
- #else
--   p = strerror(errorNumber);
--#endif
-+   if (strerror_r(errorNumber, buf, bufSize) != 0)
-+      snprintf(buf, bufSize, "unknown error %i", errorNumber);
-+   p = buf;
-+#endif /* defined __GLIBC__ */
-    ASSERT(p != NULL);
-    return p;
- }
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0009-Add-support-for-building-with-system-libtirpc.patch b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0009-Add-support-for-building-with-system-libtirpc.patch
deleted file mode 100644
index 2bee5ac..0000000
--- a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0009-Add-support-for-building-with-system-libtirpc.patch
+++ /dev/null
@@ -1,342 +0,0 @@
-From 5ae6c662fefa621f4600559e299a7d97c2254e69 Mon Sep 17 00:00:00 2001
-From: Natanael Copa <ncopa@alpinelinux.org>
-Date: Sun, 16 Jul 2017 10:20:10 -0700
-Subject: [PATCH 1/3] Add support for building with system libtirpc
-
-Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
----
- open-vm-tools/configure.ac                               | 14 ++++++++++++++
- open-vm-tools/lib/dynxdr/Makefile.am                     |  8 ++++++--
- open-vm-tools/lib/err/errPosix.c                         |  1 +
- open-vm-tools/lib/guestRpc/Makefile.am                   |  6 ++++++
- open-vm-tools/lib/misc/Makefile.am                       |  1 +
- open-vm-tools/lib/netUtil/Makefile.am                    |  4 ++++
- open-vm-tools/lib/nicInfo/Makefile.am                    |  2 ++
- open-vm-tools/lib/rpcChannel/Makefile.am                 |  4 ++++
- open-vm-tools/lib/slashProc/Makefile.am                  |  4 ++++
- open-vm-tools/lib/string/bsd_output_shared.c             |  2 +-
- open-vm-tools/libguestlib/Makefile.am                    |  2 ++
- open-vm-tools/rpctool/Makefile.am                        |  3 +++
- open-vm-tools/rpctool/rpctool.c                          |  2 ++
- open-vm-tools/services/plugins/dndcp/Makefile.am         |  2 ++
- open-vm-tools/services/plugins/guestInfo/Makefile.am     |  1 +
- open-vm-tools/services/plugins/resolutionSet/Makefile.am |  2 ++
- open-vm-tools/services/plugins/vix/Makefile.am           |  2 ++
- open-vm-tools/services/plugins/vmbackup/Makefile.am      |  2 ++
- open-vm-tools/toolbox/Makefile.am                        |  2 ++
- 19 files changed, 61 insertions(+), 3 deletions(-)
-
-Index: open-vm-tools/configure.ac
-===================================================================
---- open-vm-tools.orig/configure.ac
-+++ open-vm-tools/configure.ac
-@@ -405,6 +405,20 @@ AC_VMW_CHECK_LIB([fuse],
-                   AC_MSG_WARN([Fuse is missing, vmblock-fuse/vmhgfs-fuse will be disabled.])])
- 
- #
-+# Check for libtirpc
-+#
-+AC_VMW_CHECK_LIB([libtirpc],
-+                 [LIBTIRPC],
-+                 [libtirpc],
-+                 [],
-+                 [],
-+                 [rpc/xdr.h],
-+                 [xdr_void],
-+                 [have_libtirpc=yes],
-+                 [have_libtitirpc=no;
-+                  AC_MSG_WARN([libtirpc is missing.])])
-+
-+#
- # Check for PAM.
- #
- AC_ARG_WITH([pam],
-Index: open-vm-tools/lib/dynxdr/Makefile.am
-===================================================================
---- open-vm-tools.orig/lib/dynxdr/Makefile.am
-+++ open-vm-tools/lib/dynxdr/Makefile.am
-@@ -17,7 +17,11 @@
- 
- noinst_LTLIBRARIES = libDynxdr.la
- 
--libDynxdr_la_SOURCES = 
-+libDynxdr_la_SOURCES =
- libDynxdr_la_SOURCES += dynxdr.c
- libDynxdr_la_SOURCES += xdrutil.c
--libDynxdr_la_CPPFLAGS = -Wno-incompatible-pointer-types
-+libDynxdr_la_CPPFLAGS = @LIBTIRPC_CPPFLAGS@ -Wno-incompatible-pointer-types
-+
-+libDynxdr_la_LIBADD =
-+libDynxdr_la_LIBADD += @LIBTIRPC_LIBS@
-+
-Index: open-vm-tools/lib/err/errPosix.c
-===================================================================
---- open-vm-tools.orig/lib/err/errPosix.c
-+++ open-vm-tools/lib/err/errPosix.c
-@@ -31,6 +31,7 @@
- #include <errno.h>
- #include <string.h>
- #include <locale.h>
-+#include <stdio.h>
- 
- #include "vmware.h"
- #include "errInt.h"
-Index: open-vm-tools/lib/guestRpc/Makefile.am
-===================================================================
---- open-vm-tools.orig/lib/guestRpc/Makefile.am
-+++ open-vm-tools/lib/guestRpc/Makefile.am
-@@ -20,6 +20,12 @@ noinst_LTLIBRARIES = libGuestRpc.la
- libGuestRpc_la_SOURCES =
- libGuestRpc_la_SOURCES += nicinfo_xdr.c
- 
-+libGuestRpc_la_CPPFLAGS =
-+libGuestRpc_la_CPPFLAGS += @LIBTIRPC_CPPFLAGS@
-+
-+libGuestRpc_la_LIBADD =
-+libGuestRpc_la_LIBADD += @LIBTIRPC_LIBS@
-+
- # XXX: Autoreconf complains about this and recommends using AM_CFLAGS instead.
- # Problem is, $(CFLAGS) is appended to the compiler command line after AM_CFLAGS
- # and after libGuestRpc_la_CFLAGS, so "-Wall -Werror" will override this flag.
-Index: open-vm-tools/lib/misc/Makefile.am
-===================================================================
---- open-vm-tools.orig/lib/misc/Makefile.am
-+++ open-vm-tools/lib/misc/Makefile.am
-@@ -52,4 +52,5 @@ libMisc_la_SOURCES += utilMem.c
- libMisc_la_SOURCES += vmstdio.c
- libMisc_la_SOURCES += strutil.c
- libMisc_la_SOURCES += vthreadBase.c
-+libMisc_la_CPPFLAGS = -Wno-error=int-conversion
- 
-Index: open-vm-tools/lib/netUtil/Makefile.am
-===================================================================
---- open-vm-tools.orig/lib/netUtil/Makefile.am
-+++ open-vm-tools/lib/netUtil/Makefile.am
-@@ -20,3 +20,7 @@ noinst_LTLIBRARIES = libNetUtil.la
- libNetUtil_la_SOURCES =
- libNetUtil_la_SOURCES += netUtilLinux.c
- 
-+libNetUtil_la_CPPFLAGS =
-+libNetUtil_la_CPPFLAGS += @LIBTIRPC_CPPFLAGS@
-+
-+libNetUtil_la_LIBADD = @LIBTIRPC_LIBS@
-Index: open-vm-tools/lib/nicInfo/Makefile.am
-===================================================================
---- open-vm-tools.orig/lib/nicInfo/Makefile.am
-+++ open-vm-tools/lib/nicInfo/Makefile.am
-@@ -25,12 +25,14 @@ libNicInfo_la_SOURCES += nicInfoPosix.c
- 
- libNicInfo_la_CPPFLAGS =
- libNicInfo_la_CPPFLAGS += @GLIB2_CPPFLAGS@
-+libNicInfo_la_CPPFLAGS += @LIBTIRPC_CPPFLAGS@
- 
- AM_CFLAGS = $(DNET_CPPFLAGS)
- if USE_SLASH_PROC
- AM_CFLAGS += -DUSE_SLASH_PROC
- endif
- libNicInfo_la_LIBADD =
-+libNicInfo_la_LIBADD += @LIBTIRPC_LIBS@
- if HAVE_DNET
-    libNicInfo_la_LIBADD += @DNET_LIBS@
- endif
-Index: open-vm-tools/lib/rpcChannel/Makefile.am
-===================================================================
---- open-vm-tools.orig/lib/rpcChannel/Makefile.am
-+++ open-vm-tools/lib/rpcChannel/Makefile.am
-@@ -27,3 +27,7 @@ endif
- 
- libRpcChannel_la_CPPFLAGS =
- libRpcChannel_la_CPPFLAGS += @VMTOOLS_CPPFLAGS@
-+libRpcChannel_la_CPPFLAGS += @LIBTIRPC_CPPFLAGS@
-+
-+libRpcChannel_la_LIBADD =
-+libRpcChannel_la_LIBADD += @LIBTIRPC_LIBS@
-Index: open-vm-tools/lib/slashProc/Makefile.am
-===================================================================
---- open-vm-tools.orig/lib/slashProc/Makefile.am
-+++ open-vm-tools/lib/slashProc/Makefile.am
-@@ -22,6 +22,10 @@ libSlashProc_la_SOURCES += net.c
- 
- libSlashProc_la_CPPFLAGS =
- libSlashProc_la_CPPFLAGS += @GLIB2_CPPFLAGS@
-+libSlashProc_la_CPPFLAGS += @LIBTIRPC_CPPFLAGS@
-+
-+libSlashProc_la_LIBADD =
-+libSlashProc_la_LIBADD += @LIBTIRPC_LIBS@
- 
- AM_CFLAGS = $(DNET_CPPFLAGS)
- 
-Index: open-vm-tools/lib/string/bsd_output_shared.c
-===================================================================
---- open-vm-tools.orig/lib/string/bsd_output_shared.c
-+++ open-vm-tools/lib/string/bsd_output_shared.c
-@@ -38,7 +38,7 @@
- //#include <sys/cdefs.h>
- 
- #if !defined(STR_NO_WIN32_LIBS) && !defined(__FreeBSD__) && !defined(__OpenBSD__) && !defined(__NetBSD__) && !defined(__ANDROID__)
--
-+#define _GNU_SOURCE
- #include <stdio.h>
- #include <stdlib.h>
- #ifndef _WIN32
-Index: open-vm-tools/libguestlib/Makefile.am
-===================================================================
---- open-vm-tools.orig/libguestlib/Makefile.am
-+++ open-vm-tools/libguestlib/Makefile.am
-@@ -22,6 +22,7 @@ AM_CFLAGS += -I$(top_srcdir)/include
- 
- libguestlib_la_LIBADD =
- libguestlib_la_LIBADD += @VMTOOLS_LIBS@
-+libguestlib_la_LIBADD += @LIBTIRPC_LIBS@
- 
- libguestlib_la_SOURCES =
- libguestlib_la_SOURCES += guestlibV3_xdr.c
-@@ -56,6 +57,7 @@ CFLAGS += -Wno-unused
- libguestlib_la_CPPFLAGS =
- libguestlib_la_CPPFLAGS += -DVMTOOLS_USE_GLIB
- libguestlib_la_CPPFLAGS += @GLIB2_CPPFLAGS@
-+libguestlib_la_CPPFLAGS += @LIBTIRPC_CPPFLAGS@
- 
- EXTRA_DIST = vmguestlib.pc.in
- 
-Index: open-vm-tools/rpctool/Makefile.am
-===================================================================
---- open-vm-tools.orig/rpctool/Makefile.am
-+++ open-vm-tools/rpctool/Makefile.am
-@@ -17,10 +17,13 @@
- 
- bin_PROGRAMS = vmware-rpctool
- 
-+vmware_rpctool_CFLAGS= @LIBTIRPC_LIBS@
-+
- vmware_rpctool_SOURCES =
- vmware_rpctool_SOURCES += rpctool.c
- 
- vmware_rpctool_LDADD =
-+vmware_rpctool_LDADD += @LIBTIRPC_LIBS@
- vmware_rpctool_LDADD += ../lib/rpcOut/libRpcOut.la
- vmware_rpctool_LDADD += ../lib/message/libMessage.la
- vmware_rpctool_LDADD += ../lib/backdoor/libBackdoor.la
-Index: open-vm-tools/rpctool/rpctool.c
-===================================================================
---- open-vm-tools.orig/rpctool/rpctool.c
-+++ open-vm-tools/rpctool/rpctool.c
-@@ -23,6 +23,8 @@
-  */
- 
- #ifndef _WIN32
-+#define _GNU_SOURCE
-+#include <signal.h>
- #include "sigPosixRegs.h"
- #include <errno.h>
- #include <stdint.h>
-Index: open-vm-tools/services/plugins/dndcp/Makefile.am
-===================================================================
---- open-vm-tools.orig/services/plugins/dndcp/Makefile.am
-+++ open-vm-tools/services/plugins/dndcp/Makefile.am
-@@ -23,6 +23,7 @@ plugin_LTLIBRARIES = libdndcp.la
- libdndcp_la_CPPFLAGS =
- libdndcp_la_CPPFLAGS += @GTK_CPPFLAGS@
- libdndcp_la_CPPFLAGS += @PLUGIN_CPPFLAGS@
-+libdndcp_la_CPPFLAGS += @LIBTIRPC_CPPFLAGS@
- libdndcp_la_CPPFLAGS += -I$(top_srcdir)/services/plugins/dndcp/dnd
- libdndcp_la_CPPFLAGS += -I$(top_srcdir)/services/plugins/dndcp/dndGuest
- libdndcp_la_CPPFLAGS += -I$(top_srcdir)/services/plugins/dndcp/stringxx
-@@ -44,6 +45,7 @@ libdndcp_la_LIBADD += @GTK_LIBS@
- libdndcp_la_LIBADD += @GTKMM_LIBS@
- libdndcp_la_LIBADD += @VMTOOLS_LIBS@
- libdndcp_la_LIBADD += @HGFS_LIBS@
-+libdndcp_la_LIBADD += @LIBTIRPC_LIBS@
- libdndcp_la_LIBADD += $(top_builddir)/lib/hgfsUri/hgfsUriPosix.lo
- 
- libdndcp_la_SOURCES =
-Index: open-vm-tools/services/plugins/guestInfo/Makefile.am
-===================================================================
---- open-vm-tools.orig/services/plugins/guestInfo/Makefile.am
-+++ open-vm-tools/services/plugins/guestInfo/Makefile.am
-@@ -22,6 +22,7 @@ plugin_LTLIBRARIES = libguestInfo.la
- 
- libguestInfo_la_CPPFLAGS =
- libguestInfo_la_CPPFLAGS += @PLUGIN_CPPFLAGS@
-+libguestInfo_la_CPPFLAGS += @LIBTIRPC_CPPFLAGS@
- 
- libguestInfo_la_LDFLAGS =
- libguestInfo_la_LDFLAGS += @PLUGIN_LDFLAGS@
-Index: open-vm-tools/services/plugins/resolutionSet/Makefile.am
-===================================================================
---- open-vm-tools.orig/services/plugins/resolutionSet/Makefile.am
-+++ open-vm-tools/services/plugins/resolutionSet/Makefile.am
-@@ -21,6 +21,7 @@ plugin_LTLIBRARIES = libresolutionSet.la
- libresolutionSet_la_CPPFLAGS =
- libresolutionSet_la_CPPFLAGS += @GTK_CPPFLAGS@
- libresolutionSet_la_CPPFLAGS += @PLUGIN_CPPFLAGS@
-+libresolutionSet_la_CPPFLAGS += @LIBTIRPC_CPPFLAGS@
- libresolutionSet_la_CPPFLAGS += -DRESOLUTION_X11
- 
- libresolutionSet_la_LDFLAGS =
-@@ -30,6 +31,7 @@ libresolutionSet_la_LIBADD =
- libresolutionSet_la_LIBADD += @COMMON_XLIBS@
- libresolutionSet_la_LIBADD += @GTK_LIBS@
- libresolutionSet_la_LIBADD += @VMTOOLS_LIBS@
-+libresolutionSet_la_LIBADD += @LIBTIRPC_LIBS@
- 
- libresolutionSet_la_SOURCES =
- libresolutionSet_la_SOURCES += libvmwarectrl.c
-Index: open-vm-tools/services/plugins/vix/Makefile.am
-===================================================================
---- open-vm-tools.orig/services/plugins/vix/Makefile.am
-+++ open-vm-tools/services/plugins/vix/Makefile.am
-@@ -20,6 +20,7 @@ plugin_LTLIBRARIES = libvix.la
- 
- libvix_la_CPPFLAGS =
- libvix_la_CPPFLAGS += @PLUGIN_CPPFLAGS@
-+libvix_la_CPPFLAGS += @LIBTIRPC_CPPFLAGS@
- libvix_la_CPPFLAGS += -I$(top_srcdir)/vgauth/public
- 
- libvix_la_LDFLAGS =
-@@ -29,6 +30,7 @@ libvix_la_LIBADD =
- libvix_la_LIBADD += @VIX_LIBADD@
- libvix_la_LIBADD += @VMTOOLS_LIBS@
- libvix_la_LIBADD += @HGFS_LIBS@
-+libvix_la_LIBADD += @LIBTIRPC_LIBS@
- libvix_la_LIBADD += $(top_builddir)/lib/auth/libAuth.la
- libvix_la_LIBADD += $(top_builddir)/lib/foundryMsg/libFoundryMsg.la
- libvix_la_LIBADD += $(top_builddir)/lib/impersonate/libImpersonate.la
-Index: open-vm-tools/services/plugins/vmbackup/Makefile.am
-===================================================================
---- open-vm-tools.orig/services/plugins/vmbackup/Makefile.am
-+++ open-vm-tools/services/plugins/vmbackup/Makefile.am
-@@ -20,6 +20,7 @@ plugin_LTLIBRARIES = libvmbackup.la
- 
- libvmbackup_la_CPPFLAGS =
- libvmbackup_la_CPPFLAGS += @PLUGIN_CPPFLAGS@
-+libvmbackup_la_CPPFLAGS += @LIBTIRPC_CPPFLAGS@
- 
- libvmbackup_la_LDFLAGS =
- libvmbackup_la_LDFLAGS += @PLUGIN_LDFLAGS@
-@@ -27,6 +28,7 @@ libvmbackup_la_LDFLAGS += @PLUGIN_LDFLAG
- libvmbackup_la_LIBADD =
- libvmbackup_la_LIBADD += @GOBJECT_LIBS@
- libvmbackup_la_LIBADD += @VMTOOLS_LIBS@
-+libvmbackup_la_LIBADD += @LIBTIRPC_LIBS@
- 
- libvmbackup_la_SOURCES =
- libvmbackup_la_SOURCES += nullProvider.c
-Index: open-vm-tools/toolbox/Makefile.am
-===================================================================
---- open-vm-tools.orig/toolbox/Makefile.am
-+++ open-vm-tools/toolbox/Makefile.am
-@@ -20,9 +20,11 @@ bin_PROGRAMS = vmware-toolbox-cmd
- vmware_toolbox_cmd_LDADD =
- vmware_toolbox_cmd_LDADD += ../libguestlib/libguestlib.la
- vmware_toolbox_cmd_LDADD += @VMTOOLS_LIBS@
-+vmware_toolbox_cmd_LDADD += @LIBTIRPC_LIBS@
- 
- vmware_toolbox_cmd_CPPFLAGS =
- vmware_toolbox_cmd_CPPFLAGS += @VMTOOLS_CPPFLAGS@
-+vmware_toolbox_cmd_CPPFLAGS += @LIBTIRPC_CPPFLAGS@
- 
- vmware_toolbox_cmd_SOURCES =
- vmware_toolbox_cmd_SOURCES += toolbox-cmd.c
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0010-gnu-ucontext.patch b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0010-gnu-ucontext.patch
deleted file mode 100644
index c9beac1..0000000
--- a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/0010-gnu-ucontext.patch
+++ /dev/null
@@ -1,65 +0,0 @@
-From 27442e2dd287d393d7b3f8bf164a887affef84df Mon Sep 17 00:00:00 2001
-From: Natanael Copa <ncopa@alpinelinux.org>
-Date: Wed, 18 Nov 2015 10:27:51 +0000
-Subject: [PATCH 10/11] gnu-ucontext
-
----
- open-vm-tools/lib/include/sigPosixRegs.h | 24 ++++++++++++------------
- 1 file changed, 12 insertions(+), 12 deletions(-)
-
-Index: open-vm-tools/lib/include/sigPosixRegs.h
-===================================================================
---- open-vm-tools.orig/lib/include/sigPosixRegs.h
-+++ open-vm-tools/lib/include/sigPosixRegs.h
-@@ -33,7 +33,7 @@
- #include "includeCheck.h"
- 
- 
--#if __linux__         // We need the REG_foo offsets in the gregset_t;
-+#if defined(__GLIBC__) // We need the REG_foo offsets in the gregset_t;
- #  define _GNU_SOURCE // _GNU_SOURCE maps to __USE_GNU
- 
- /* And, the REG_foo definitions conflict with our own in x86.h */
-@@ -73,7 +73,7 @@
- #include <sys/ucontext.h>
- #endif
- 
--#if __linux__
-+#if defined(__GLIBC__)
- #  if defined(__x86_64__)
- #    undef REG_RAX
- #    undef REG_RBX
-@@ -199,7 +199,7 @@
- #define SC_ESP(uc) ((unsigned long) (uc)->uc_mcontext.mc_esp)
- #define SC_EIP(uc) ((unsigned long) (uc)->uc_mcontext.mc_eip)
- #endif
--#elif defined (sun)
-+#elif !defined (__GLIBC__)
- #ifdef __x86_64__
- #define SC_EAX(uc) ((unsigned long) (uc)->uc_mcontext.gregs[REG_RAX])
- #define SC_EBX(uc) ((unsigned long) (uc)->uc_mcontext.gregs[REG_RBX])
-@@ -219,15 +219,15 @@
- #define SC_R14(uc) ((unsigned long) (uc)->uc_mcontext.gregs[REG_R14])
- #define SC_R15(uc) ((unsigned long) (uc)->uc_mcontext.gregs[REG_R15])
- #else
--#define SC_EAX(uc) ((unsigned long) (uc)->uc_mcontext.gregs[EAX])
--#define SC_EBX(uc) ((unsigned long) (uc)->uc_mcontext.gregs[EBX])
--#define SC_ECX(uc) ((unsigned long) (uc)->uc_mcontext.gregs[ECX])
--#define SC_EDX(uc) ((unsigned long) (uc)->uc_mcontext.gregs[EDX])
--#define SC_EDI(uc) ((unsigned long) (uc)->uc_mcontext.gregs[EDI])
--#define SC_ESI(uc) ((unsigned long) (uc)->uc_mcontext.gregs[ESI])
--#define SC_EBP(uc) ((unsigned long) (uc)->uc_mcontext.gregs[EBP])
--#define SC_ESP(uc) ((unsigned long) (uc)->uc_mcontext.gregs[ESP])
--#define SC_EIP(uc) ((unsigned long) (uc)->uc_mcontext.gregs[EIP])
-+#define SC_EAX(uc) ((unsigned long) (uc)->uc_mcontext.gregs[REG_EAX])
-+#define SC_EBX(uc) ((unsigned long) (uc)->uc_mcontext.gregs[REG_EBX])
-+#define SC_ECX(uc) ((unsigned long) (uc)->uc_mcontext.gregs[REG_ECX])
-+#define SC_EDX(uc) ((unsigned long) (uc)->uc_mcontext.gregs[REG_EDX])
-+#define SC_EDI(uc) ((unsigned long) (uc)->uc_mcontext.gregs[REG_EDI])
-+#define SC_ESI(uc) ((unsigned long) (uc)->uc_mcontext.gregs[REG_ESI])
-+#define SC_EBP(uc) ((unsigned long) (uc)->uc_mcontext.gregs[REG_EBP])
-+#define SC_ESP(uc) ((unsigned long) (uc)->uc_mcontext.gregs[REG_ESP])
-+#define SC_EIP(uc) ((unsigned long) (uc)->uc_mcontext.gregs[REG_EIP])
- #endif
- #elif defined(ANDROID_X86)
- #define SC_EAX(uc) ((unsigned long) (uc)->uc_mcontext.eax)
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/fix-subdir-objects-configure-error.patch b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/fix-subdir-objects-configure-error.patch
new file mode 100644
index 0000000..1a6bfdb
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/fix-subdir-objects-configure-error.patch
@@ -0,0 +1,12 @@
+Index: open-vm-tools/configure.ac
+===================================================================
+--- open-vm-tools.orig/configure.ac
++++ open-vm-tools/configure.ac
+@@ -303,6 +303,7 @@ AC_ARG_ENABLE(
+    [],
+    [enable_resolutionkms="auto"])
+ 
++AM_INIT_AUTOMAKE([subdir-objects])
+ AM_INIT_AUTOMAKE
+ 
+ ###
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/files/tools.conf b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/tools.conf
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-support/open-vm-tools/files/tools.conf
rename to meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/tools.conf
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/files/vmtoolsd.init b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/vmtoolsd.init
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-support/open-vm-tools/files/vmtoolsd.init
rename to meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/vmtoolsd.init
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/files/vmtoolsd.service b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/vmtoolsd.service
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-support/open-vm-tools/files/vmtoolsd.service
rename to meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools/vmtoolsd.service
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools_10.1.5.bb b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools_10.1.5.bb
deleted file mode 100644
index c32d2c5..0000000
--- a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools_10.1.5.bb
+++ /dev/null
@@ -1,114 +0,0 @@
-# This recipe is modified from the recipe originally found in the Open-Switch
-# repository:
-#
-# https://github.com/open-switch/ops-build
-# yocto/openswitch/meta-foss-openswitch/meta-oe/recipes-support/open-vm-tools/open-vm-tools_10.0.5.bb
-# Commit 9008de2d8e100f3f868c66765742bca9fa98f3f9
-#
-# The recipe packaging has been relicensed under the MIT license for inclusion
-# in meta-openembedded by agreement of the author (Diego Dompe).
-#
-
-SUMMARY = "Tools to enhance VMWare guest integration and performance"
-HOMEPAGE = "https://github.com/vmware/open-vm-tools"
-SECTION = "vmware-tools"
-
-LICENSE = "LGPL-2.0 & GPL-2.0 & BSD & CDDL-1.0"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=b66ba4cb4fc017682c95efc300410e79"
-LICENSE_modules/freebsd/vmblock = "BSD"
-LICENSE_modules/freebsd/vmmemctl = "GPL-2.0"
-LICENSE_modules/freebsd/vmxnet = "GPL-2.0"
-LICENSE_modules/linux = "GPL-2.0"
-LICENSE_modules/solaris = "CDDL-1.0"
-
-SRC_URI = "git://github.com/vmware/open-vm-tools.git;protocol=https \
-           file://tools.conf \
-           file://vmtoolsd.service \
-           file://vmtoolsd.init \
-           file://0001-configure.ac-don-t-use-dnet-config.patch \
-           file://0002-add-include-sys-sysmacros.h.patch \
-           file://0001-Remove-assumptions-about-glibc-being-only-libc-imple.patch \
-           file://0002-include-poll.h-instead-of-obsolete-sys-poll.h.patch \
-           file://0003-Rename-poll.h-to-vm_poll.h.patch \
-           file://0004-Add-Wno-incompatible-pointer-types-and-Wno-error-add.patch \
-           file://0005-Use-configure-test-for-struct-timespec.patch \
-           file://0006-Fix-definition-of-ALLPERMS-and-ACCESSPERMS.patch \
-           file://0007-Use-configure-to-test-for-feature-instead-of-platfor.patch \
-           file://0008-use-posix-strerror_r-unless-gnu.patch \
-           file://0011-Use-configure-test-for-sys-stat.h-include.patch \
-           "
-SRC_URI_append_libc-musl = "\
-           file://0009-Add-support-for-building-with-system-libtirpc.patch \
-           file://0010-gnu-ucontext.patch \
-           "
-SRCREV = "854c0bb374612f7e633b448ca273f970f154458b"
-
-S = "${WORKDIR}/git/open-vm-tools"
-
-DEPENDS = "glib-2.0 glib-2.0-native util-linux libdnet procps"
-DEPENDS_append_libc-musl = " libtirpc"
-
-# open-vm-tools is supported only on x86.
-COMPATIBLE_HOST = '(x86_64.*|i.86.*)-linux'
-
-inherit autotools pkgconfig systemd update-rc.d
-
-SYSTEMD_SERVICE_${PN} = "vmtoolsd.service"
-
-EXTRA_OECONF = "--without-icu --disable-multimon --disable-docs \
-                --disable-tests --without-gtkmm --without-xerces --without-pam \
-                --disable-grabbitmqproxy --disable-vgauth --disable-deploypkg \
-                --without-root-privileges --without-kernel-modules"
-
-NO_X11_FLAGS = "--without-x --without-gtk2 --without-gtk3"
-X11_DEPENDS = "libxext libxi libxrender libxrandr libxtst gtk+ gdk-pixbuf"
-PACKAGECONFIG[x11] = ",${NO_X11_FLAGS},${X11_DEPENDS}"
-
-# fuse gets implicitly detected; there is no --without-fuse option.
-PACKAGECONFIG[fuse] = ",,fuse"
-
-CFLAGS_append_toolchain-clang = " -Wno-address-of-packed-member"
-FILES_${PN} += "\
-    ${libdir}/open-vm-tools/plugins/vmsvc/lib*.so \
-    ${libdir}/open-vm-tools/plugins/common/lib*.so \
-    ${sysconfdir}/vmware-tools/tools.conf \
-    "
-FILES_${PN}-locale += "${datadir}/open-vm-tools/messages"
-FILES_${PN}-dev += "${libdir}/open-vm-tools/plugins/common/lib*.la"
-FILES_${PN}-dbg += "\
-    ${libdir}/open-vm-tools/plugins/common/.debug \
-    ${libdir}/open-vm-tools/plugins/vmsvc/.debug \
-    "
-
-CONFFILES_${PN} += "${sysconfdir}/vmware-tools/tools.conf"
-
-RDEPENDS_${PN} = "util-linux libdnet fuse"
-
-do_install_append() {
-    ln -sf ${sbindir}/mount.vmhgfs ${D}/sbin/mount.vmhgfs
-    install -d ${D}${sysconfdir}/vmware-tools
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-        install -d ${D}${systemd_unitdir}/system
-        install -m 644 ${WORKDIR}/*.service ${D}${systemd_unitdir}/system
-    else
-        install -d ${D}${sysconfdir}/init.d
-        install -m 0755 ${WORKDIR}/vmtoolsd.init ${D}${sysconfdir}/init.d/vmtoolsd
-    fi
-    install -m 0644 ${WORKDIR}/tools.conf ${D}${sysconfdir}/vmware-tools/tools.conf
-}
-
-do_configure_prepend() {
-    export CUSTOM_DNET_NAME=dnet
-    export CUSTOM_DNET_LIBS=-L${STAGING_LIBDIR}/libdnet.so
-}
-
-INITSCRIPT_PACKAGES = "${PN}"
-INITSCRIPT_NAME_${PN} = "vmtoolsd"
-INITSCRIPT_PARAMS_${PN} = "start 90 2 3 4 5 . stop 60 0 1 6 ."
-
-python() {
-    if 'networking-layer' not in d.getVar('BBFILE_COLLECTIONS').split() or \
-	'filesystems-layer' not in d.getVar('BBFILE_COLLECTIONS').split():
-        raise bb.parse.SkipRecipe('Requires meta-networking and meta-filesystems to be present.')
-}
-
diff --git a/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools_10.3.0.bb b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools_10.3.0.bb
new file mode 100644
index 0000000..478d762
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/open-vm-tools/open-vm-tools_10.3.0.bb
@@ -0,0 +1,110 @@
+# This recipe is modified from the recipe originally found in the Open-Switch
+# repository:
+#
+# https://github.com/open-switch/ops-build
+# yocto/openswitch/meta-foss-openswitch/meta-oe/recipes-support/open-vm-tools/open-vm-tools_10.0.5.bb
+# Commit 9008de2d8e100f3f868c66765742bca9fa98f3f9
+#
+# The recipe packaging has been relicensed under the MIT license for inclusion
+# in meta-openembedded by agreement of the author (Diego Dompe).
+#
+
+SUMMARY = "Tools to enhance VMWare guest integration and performance"
+HOMEPAGE = "https://github.com/vmware/open-vm-tools"
+SECTION = "vmware-tools"
+
+LICENSE = "LGPL-2.0 & GPL-2.0 & BSD & CDDL-1.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=559317809c5444fb39ceaf6ac45c43ac"
+LICENSE_modules/freebsd/vmblock = "BSD"
+LICENSE_modules/freebsd/vmmemctl = "GPL-2.0"
+LICENSE_modules/freebsd/vmxnet = "GPL-2.0"
+LICENSE_modules/linux = "GPL-2.0"
+LICENSE_modules/solaris = "CDDL-1.0"
+
+SRC_URI = "git://github.com/vmware/open-vm-tools.git;protocol=https \
+           file://tools.conf \
+           file://vmtoolsd.service \
+           file://vmtoolsd.init \
+           file://0001-configure.ac-don-t-use-dnet-config.patch \
+           file://0002-add-include-sys-sysmacros.h.patch \
+           file://0005-Use-configure-test-for-struct-timespec.patch \
+           file://0006-Fix-definition-of-ALLPERMS-and-ACCESSPERMS.patch \
+           file://0007-Use-configure-to-test-for-feature-instead-of-platfor.patch \
+           file://0011-Use-configure-test-for-sys-stat.h-include.patch \
+           file://fix-subdir-objects-configure-error.patch \
+           file://0001-include-poll.h-instead-of-sys-poll.h.patch \
+           file://0002-Rename-poll.h-to-vm_poll.h.patch \
+           file://0003-use-posix-strerror_r-unless-on-gnu-libc-system.patch \
+           file://0004-Use-uintmax_t-for-handling-rlim_t.patch \
+           file://0001-Use-off64_t-instead-of-__off64_t.patch \
+           "
+SRCREV = "2147df6aabe639fc5ff423ed791a8e7f02bf8d0a"
+
+S = "${WORKDIR}/git/open-vm-tools"
+
+DEPENDS = "glib-2.0 glib-2.0-native util-linux libdnet procps libtirpc"
+
+# open-vm-tools is supported only on x86.
+COMPATIBLE_HOST = '(x86_64.*|i.86.*)-linux'
+
+inherit autotools pkgconfig systemd update-rc.d
+
+SYSTEMD_SERVICE_${PN} = "vmtoolsd.service"
+
+EXTRA_OECONF = "--without-icu --disable-multimon --disable-docs \
+                --disable-tests --without-gtkmm --without-xerces --without-pam \
+                --disable-grabbitmqproxy --disable-vgauth --disable-deploypkg \
+                --without-root-privileges --without-kernel-modules"
+
+NO_X11_FLAGS = "--without-x --without-gtk2 --without-gtk3"
+X11_DEPENDS = "libxext libxi libxrender libxrandr libxtst gtk+ gdk-pixbuf"
+PACKAGECONFIG[x11] = ",${NO_X11_FLAGS},${X11_DEPENDS}"
+
+# fuse gets implicitly detected; there is no --without-fuse option.
+PACKAGECONFIG[fuse] = ",,fuse"
+
+CFLAGS_append_toolchain-clang = " -Wno-address-of-packed-member"
+FILES_${PN} += "\
+    ${libdir}/open-vm-tools/plugins/vmsvc/lib*.so \
+    ${libdir}/open-vm-tools/plugins/common/lib*.so \
+    ${sysconfdir}/vmware-tools/tools.conf \
+    "
+FILES_${PN}-locale += "${datadir}/open-vm-tools/messages"
+FILES_${PN}-dev += "${libdir}/open-vm-tools/plugins/common/lib*.la"
+FILES_${PN}-dbg += "\
+    ${libdir}/open-vm-tools/plugins/common/.debug \
+    ${libdir}/open-vm-tools/plugins/vmsvc/.debug \
+    "
+
+CONFFILES_${PN} += "${sysconfdir}/vmware-tools/tools.conf"
+
+RDEPENDS_${PN} = "util-linux libdnet fuse"
+
+do_install_append() {
+    ln -sf ${sbindir}/mount.vmhgfs ${D}/sbin/mount.vmhgfs
+    install -d ${D}${sysconfdir}/vmware-tools
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+        install -d ${D}${systemd_unitdir}/system
+        install -m 644 ${WORKDIR}/*.service ${D}${systemd_unitdir}/system
+    else
+        install -d ${D}${sysconfdir}/init.d
+        install -m 0755 ${WORKDIR}/vmtoolsd.init ${D}${sysconfdir}/init.d/vmtoolsd
+    fi
+    install -m 0644 ${WORKDIR}/tools.conf ${D}${sysconfdir}/vmware-tools/tools.conf
+}
+
+do_configure_prepend() {
+    export CUSTOM_DNET_NAME=dnet
+    export CUSTOM_DNET_LIBS=-L${STAGING_LIBDIR}/libdnet.so
+}
+
+INITSCRIPT_PACKAGES = "${PN}"
+INITSCRIPT_NAME_${PN} = "vmtoolsd"
+INITSCRIPT_PARAMS_${PN} = "start 90 2 3 4 5 . stop 60 0 1 6 ."
+
+python() {
+    if 'networking-layer' not in d.getVar('BBFILE_COLLECTIONS').split() or \
+	'filesystems-layer' not in d.getVar('BBFILE_COLLECTIONS').split():
+        raise bb.parse.SkipRecipe('Requires meta-networking and meta-filesystems to be present.')
+}
+
diff --git a/meta-openembedded/meta-oe/recipes-support/openct/openct_0.6.20.bb b/meta-openembedded/meta-oe/recipes-support/openct/openct_0.6.20.bb
index 913290c..67b7c29 100644
--- a/meta-openembedded/meta-oe/recipes-support/openct/openct_0.6.20.bb
+++ b/meta-openembedded/meta-oe/recipes-support/openct/openct_0.6.20.bb
@@ -88,7 +88,3 @@
     touch ${D}${localstatedir}/run/openct/status
     chmod 644 ${D}${localstatedir}/run/openct/status
 }
-
-pkg_postinst_${PN} () {
-    ln -sf ctapi/libopenctapi.so ${libdir}/libopenctapi.so
-}
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-Add-missing-multi-line-separator.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-Add-missing-multi-line-separator.patch
new file mode 100644
index 0000000..513597b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-Add-missing-multi-line-separator.patch
@@ -0,0 +1,36 @@
+From 60857229aab13ccc426572a43ab891409bb76ea4 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 9 Sep 2018 22:52:55 -0700
+Subject: [PATCH] Add missing multi-line separator
+
+Otherwise this fails to build ( found on mips )
+
+Fixes
+contrib/modules/surface_matching/src/hash_murmur86.hpp:97:15: error:
+expected constructor, destructor, or type conversion before '(' token
+     && defined(__GNUC__) && (__GNUC__>4 || (__GNUC__==4 &&
+__GNUC_MINOR__>=3))
+               ^
+
+Upstream-Status: Submitted [https://github.com/opencv/opencv_contrib/pull/1764]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ modules/surface_matching/src/hash_murmur86.hpp | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/modules/surface_matching/src/hash_murmur86.hpp b/modules/surface_matching/src/hash_murmur86.hpp
+index 1edf6bf4..0477d37e 100644
+--- a/modules/surface_matching/src/hash_murmur86.hpp
++++ b/modules/surface_matching/src/hash_murmur86.hpp
+@@ -93,7 +93,7 @@ void hashMurmurx86 ( const void * key, const int len, const uint seed, void * ou
+ /* Now find best way we can to READ_UINT32 */
+ #ifndef WORDS_BIGENDIAN
+ # define READ_UINT32(ptr)   (*((uint32_t*)(ptr)))
+-#elif defined(WORDS_BIGENDIAN)
++#elif defined(WORDS_BIGENDIAN) \
+     && defined(__GNUC__) && (__GNUC__>4 || (__GNUC__==4 && __GNUC_MINOR__>=3))
+ # define READ_UINT32(ptr)   (__builtin_bswap32(*((uint32_t*)(ptr))))
+ #endif
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-Check-for-clang-before-using-isystem.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-Check-for-clang-before-using-isystem.patch
new file mode 100644
index 0000000..319071a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-Check-for-clang-before-using-isystem.patch
@@ -0,0 +1,32 @@
+From fa76d8646bb2b9b514728eeef41afed7c43a36f2 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 11 Sep 2018 18:18:33 -0700
+Subject: [PATCH] Check for clang before using -isystem
+
+When cross compiling with clang, the internal C++ headers are not found
+when adding sysroot to -isystem, that is redundant anyway because it
+will look for headers insider --sysroot path with same quality as it
+would do with -isystem otherwise
+
+Upstream-Status: Submitted [https://github.com/opencv/opencv/pull/12504]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ cmake/OpenCVUtils.cmake | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/cmake/OpenCVUtils.cmake b/cmake/OpenCVUtils.cmake
+index fae91c165f..60c20192dc 100644
+--- a/cmake/OpenCVUtils.cmake
++++ b/cmake/OpenCVUtils.cmake
+@@ -259,7 +259,7 @@ function(ocv_include_directories)
+     ocv_is_opencv_directory(__is_opencv_dir "${dir}")
+     if(__is_opencv_dir)
+       list(APPEND __add_before "${dir}")
+-    elseif(CV_GCC AND NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS "6.0" AND
++    elseif(((CV_GCC AND NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS "6.0") OR CV_CLANG) AND
+            dir MATCHES "/usr/include$")
+       # workaround for GCC 6.x bug
+     else()
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-Dont-use-isystem.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-Dont-use-isystem.patch
index 6dd48fc..bf0b80a 100644
--- a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-Dont-use-isystem.patch
+++ b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-Dont-use-isystem.patch
@@ -1,26 +1,30 @@
-From 2bc6bb9831d07f035fea74ea745cea43dd5f9ef9 Mon Sep 17 00:00:00 2001
+From 7144c44ec70dee73a628463b99ffeed74b1a8ef6 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 9 Sep 2017 23:48:31 -0700
+Date: Tue, 11 Sep 2018 00:21:18 -0700
 Subject: [PATCH] Dont use isystem
 
+clang really does not like it
+
+Upstream-Status: Pending
+
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 ---
-Upstream-Status: Pending
+ cmake/OpenCVPCHSupport.cmake | 2 ++
+ 1 file changed, 2 insertions(+)
 
- cmake/OpenCVPCHSupport.cmake | 10 ++++------
- 1 file changed, 4 insertions(+), 6 deletions(-)
-
-Index: git/cmake/OpenCVPCHSupport.cmake
-===================================================================
---- git.orig/cmake/OpenCVPCHSupport.cmake
-+++ git/cmake/OpenCVPCHSupport.cmake
-@@ -17,7 +17,8 @@ IF(CMAKE_COMPILER_IS_GNUCXX)
-     IF(NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS "4.2.0")
+diff --git a/cmake/OpenCVPCHSupport.cmake b/cmake/OpenCVPCHSupport.cmake
+index f9b1b48b65..fe27a136f5 100644
+--- a/cmake/OpenCVPCHSupport.cmake
++++ b/cmake/OpenCVPCHSupport.cmake
+@@ -18,6 +18,8 @@ IF(CV_GCC)
          SET(PCHSupport_FOUND TRUE)
      ENDIF()
--
+ 
 +    SET(CMAKE_INCLUDE_SYSTEM_FLAG_C "-I")
 +    SET(CMAKE_INCLUDE_SYSTEM_FLAG_CXX "-I")
      SET(_PCH_include_prefix "-I")
      SET(_PCH_isystem_prefix "-isystem")
      SET(_PCH_define_prefix "-D")
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-Temporarliy-work-around-deprecated-ffmpeg-RAW-functi.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-Temporarliy-work-around-deprecated-ffmpeg-RAW-functi.patch
new file mode 100644
index 0000000..63cb7f9
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-Temporarliy-work-around-deprecated-ffmpeg-RAW-functi.patch
@@ -0,0 +1,33 @@
+From 7d31f41d2a6759e244983504ce855fc32916b97a Mon Sep 17 00:00:00 2001
+From: Jason Wessel <jason.wessel@windriver.com>
+Date: Wed, 9 May 2018 13:33:59 -0700
+Subject: [PATCH] Temporarliy work around deprecated ffmpeg RAW function
+ compile failure until next uprev
+
+Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
+---
+ modules/videoio/src/cap_ffmpeg_impl.hpp | 8 ++++++++
+ 1 file changed, 8 insertions(+)
+
+diff --git a/modules/videoio/src/cap_ffmpeg_impl.hpp b/modules/videoio/src/cap_ffmpeg_impl.hpp
+index 5a9b10f075..97c6b74b07 100644
+--- a/modules/videoio/src/cap_ffmpeg_impl.hpp
++++ b/modules/videoio/src/cap_ffmpeg_impl.hpp
+@@ -667,6 +667,14 @@ struct ImplMutex::Impl
+ 
+ #endif
+ 
++/* NOTE This is deprecated in ffmpeg and the code should be removed */
++#ifndef AVFMT_RAWPICTURE
++#define AVFMT_RAWPICTURE	0x0020
++#endif /* AVFMT_RAWPICTURE */
++#ifndef CODEC_FLAG_GLOBAL_HEADER
++#define CODEC_FLAG_GLOBAL_HEADER	AV_CODEC_FLAG_GLOBAL_HEADER
++#endif
++
+ void ImplMutex::init()
+ {
+     impl = new Impl();
+-- 
+2.11.0
+
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-build-workaround-GCC-7.1.1-compilation-issue-with-sa.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-build-workaround-GCC-7.1.1-compilation-issue-with-sa.patch
deleted file mode 100644
index 0140633..0000000
--- a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-build-workaround-GCC-7.1.1-compilation-issue-with-sa.patch
+++ /dev/null
@@ -1,127 +0,0 @@
-Upstream-Status: Backport [https://github.com/opencv/opencv/pull/9376/commits/0d854db361106dfcb055231fd0112c5b85ef2287]
-
-Fix CVEs for opencv 3.3.
-
-* CVE-2017-12597
-* CVE-2017-12598
-* CVE-2017-12599
-* CVE-2017-12600
-* CVE-2017-12601
-* CVE-2017-12602
-* CVE-2017-12603
-* CVE-2017-12604
-* CVE-2017-12605
-* CVE-2017-12606
-* CVE-2017-12862
-* CVE-2017-12863
-* CVE-2017-12864
-
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
----
-From 0d854db361106dfcb055231fd0112c5b85ef2287 Mon Sep 17 00:00:00 2001
-From: Alexander Alekhin <alexander.a.alekhin@gmail.com>
-Date: Tue, 15 Aug 2017 21:45:05 +0000
-Subject: [PATCH 1/3] build: workaround GCC 7.1.1 compilation issue with
- sanitize flags
-
-Version: gcc (GCC) 7.1.1 20170622 (Red Hat 7.1.1-3)
-Flags: -fsanitize=address,undefined
----
- modules/ts/src/cuda_test.cpp | 56 ++++++++++++++++++++++++++------------------
- 1 file changed, 33 insertions(+), 23 deletions(-)
-
-diff --git a/modules/ts/src/cuda_test.cpp b/modules/ts/src/cuda_test.cpp
-index a48e0a087..eb4cee136 100644
---- a/modules/ts/src/cuda_test.cpp
-+++ b/modules/ts/src/cuda_test.cpp
-@@ -322,16 +322,20 @@ namespace cvtest
- 
-         if (m1.size() != m2.size())
-         {
--            return AssertionFailure() << "Matrices \"" << expr1 << "\" and \"" << expr2 << "\" have different sizes : \""
--                                      << expr1 << "\" [" << PrintToString(m1.size()) << "] vs \""
--                                      << expr2 << "\" [" << PrintToString(m2.size()) << "]";
-+            std::stringstream msg;
-+            msg << "Matrices \"" << expr1 << "\" and \"" << expr2 << "\" have different sizes : \""
-+                << expr1 << "\" [" << PrintToString(m1.size()) << "] vs \""
-+                << expr2 << "\" [" << PrintToString(m2.size()) << "]";
-+            return AssertionFailure() << msg.str();
-         }
- 
-         if (m1.type() != m2.type())
-         {
--            return AssertionFailure() << "Matrices \"" << expr1 << "\" and \"" << expr2 << "\" have different types : \""
--                                      << expr1 << "\" [" << PrintToString(MatType(m1.type())) << "] vs \""
--                                      << expr2 << "\" [" << PrintToString(MatType(m2.type())) << "]";
-+            std::stringstream msg;
-+            msg << "Matrices \"" << expr1 << "\" and \"" << expr2 << "\" have different types : \""
-+                << expr1 << "\" [" << PrintToString(MatType(m1.type())) << "] vs \""
-+                << expr2 << "\" [" << PrintToString(MatType(m2.type())) << "]";
-+             return AssertionFailure() << msg.str();
-         }
- 
-         Mat diff;
-@@ -343,12 +347,14 @@ namespace cvtest
- 
-         if (maxVal > eps)
-         {
--            return AssertionFailure() << "The max difference between matrices \"" << expr1 << "\" and \"" << expr2
--                                      << "\" is " << maxVal << " at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ")"
--                                      << ", which exceeds \"" << eps_expr << "\", where \""
--                                      << expr1 << "\" at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ") evaluates to " << printMatVal(m1, maxLoc) << ", \""
--                                      << expr2 << "\" at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ") evaluates to " << printMatVal(m2, maxLoc) << ", \""
--                                      << eps_expr << "\" evaluates to " << eps;
-+            std::stringstream msg;
-+            msg << "The max difference between matrices \"" << expr1 << "\" and \"" << expr2
-+                << "\" is " << maxVal << " at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ")"
-+                << ", which exceeds \"" << eps_expr << "\", where \""
-+                << expr1 << "\" at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ") evaluates to " << printMatVal(m1, maxLoc) << ", \""
-+                << expr2 << "\" at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ") evaluates to " << printMatVal(m2, maxLoc) << ", \""
-+                << eps_expr << "\" evaluates to " << eps;
-+            return AssertionFailure() << msg.str();
-         }
- 
-         return AssertionSuccess();
-@@ -469,9 +475,11 @@ namespace cvtest
-     {
-         if (gold.size() != actual.size())
-         {
--            return testing::AssertionFailure() << "KeyPoints size mistmach\n"
--                                               << "\"" << gold_expr << "\" : " << gold.size() << "\n"
--                                               << "\"" << actual_expr << "\" : " << actual.size();
-+            std::stringstream msg;
-+            msg << "KeyPoints size mistmach\n"
-+                << "\"" << gold_expr << "\" : " << gold.size() << "\n"
-+                << "\"" << actual_expr << "\" : " << actual.size();
-+            return AssertionFailure() << msg.str();
-         }
- 
-         std::sort(actual.begin(), actual.end(), KeyPointLess());
-@@ -484,14 +492,16 @@ namespace cvtest
- 
-             if (!keyPointsEquals(p1, p2))
-             {
--                return testing::AssertionFailure() << "KeyPoints differ at " << i << "\n"
--                                                   << "\"" << gold_expr << "\" vs \"" << actual_expr << "\" : \n"
--                                                   << "pt : " << testing::PrintToString(p1.pt) << " vs " << testing::PrintToString(p2.pt) << "\n"
--                                                   << "size : " << p1.size << " vs " << p2.size << "\n"
--                                                   << "angle : " << p1.angle << " vs " << p2.angle << "\n"
--                                                   << "response : " << p1.response << " vs " << p2.response << "\n"
--                                                   << "octave : " << p1.octave << " vs " << p2.octave << "\n"
--                                                   << "class_id : " << p1.class_id << " vs " << p2.class_id;
-+                std::stringstream msg;
-+                msg << "KeyPoints differ at " << i << "\n"
-+                    << "\"" << gold_expr << "\" vs \"" << actual_expr << "\" : \n"
-+                    << "pt : " << testing::PrintToString(p1.pt) << " vs " << testing::PrintToString(p2.pt) << "\n"
-+                    << "size : " << p1.size << " vs " << p2.size << "\n"
-+                    << "angle : " << p1.angle << " vs " << p2.angle << "\n"
-+                    << "response : " << p1.response << " vs " << p2.response << "\n"
-+                    << "octave : " << p1.octave << " vs " << p2.octave << "\n"
-+                    << "class_id : " << p1.class_id << " vs " << p2.class_id;
-+                return AssertionFailure() << msg.str();
-             }
-         }
- 
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-carotene-don-t-use-__asm__-with-aarch64.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-carotene-don-t-use-__asm__-with-aarch64.patch
deleted file mode 100644
index a1a56e0..0000000
--- a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0001-carotene-don-t-use-__asm__-with-aarch64.patch
+++ /dev/null
@@ -1,1250 +0,0 @@
-From 353fc92618ce0dc6bab4a3e8bff1c13c3b613110 Mon Sep 17 00:00:00 2001
-From: Alexander Alekhin <alexander.alekhin@intel.com>
-Date: Wed, 23 Aug 2017 17:41:23 +0300
-Subject: [PATCH 1/2] carotene: don't use __asm__ with aarch64
-
----
-Upstream-Status: Backport
-
- 3rdparty/carotene/src/channel_extract.cpp  |   4 +-
- 3rdparty/carotene/src/channels_combine.cpp |   2 +-
- 3rdparty/carotene/src/colorconvert.cpp     | 104 ++++++++++++++---------------
- 3rdparty/carotene/src/convert.cpp          |  54 +++++++--------
- 3rdparty/carotene/src/convert_scale.cpp    |  72 ++++++++++----------
- 3rdparty/carotene/src/gaussian_blur.cpp    |   6 +-
- 3rdparty/carotene/src/pyramid.cpp          |  20 +++---
- 3rdparty/carotene/src/scharr.cpp           |   4 +-
- 8 files changed, 133 insertions(+), 133 deletions(-)
-
-diff --git a/3rdparty/carotene/src/channel_extract.cpp b/3rdparty/carotene/src/channel_extract.cpp
-index f663bc6005..8238a3ece8 100644
---- a/3rdparty/carotene/src/channel_extract.cpp
-+++ b/3rdparty/carotene/src/channel_extract.cpp
-@@ -231,7 +231,7 @@ void extract4(const Size2D &size,
-                  srcStride == dst2Stride && \
-                  srcStride == dst3Stride &&
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- 
- #define SPLIT_ASM2(sgn, bits) __asm__ ( \
-                                           "vld2." #bits " {d0, d2}, [%[in0]]            \n\t" \
-@@ -351,7 +351,7 @@ void extract4(const Size2D &size,
-     }                                                                                                   \
- }
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- 
- #define ALPHA_QUAD(sgn, bits) { \
-                                   internal::prefetch(src + sj); \
-diff --git a/3rdparty/carotene/src/channels_combine.cpp b/3rdparty/carotene/src/channels_combine.cpp
-index 157c8b8121..fc98fb9181 100644
---- a/3rdparty/carotene/src/channels_combine.cpp
-+++ b/3rdparty/carotene/src/channels_combine.cpp
-@@ -77,7 +77,7 @@ namespace CAROTENE_NS {
-                  dstStride == src2Stride && \
-                  dstStride == src3Stride &&
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- 
- #define MERGE_ASM2(sgn, bits) __asm__ ( \
-                                           "vld1." #bits " {d0-d1}, [%[in0]]             \n\t" \
-diff --git a/3rdparty/carotene/src/colorconvert.cpp b/3rdparty/carotene/src/colorconvert.cpp
-index 3037fe672a..26ae54b15c 100644
---- a/3rdparty/carotene/src/colorconvert.cpp
-+++ b/3rdparty/carotene/src/colorconvert.cpp
-@@ -97,7 +97,7 @@ void rgb2gray(const Size2D &size, COLOR_SPACE color_space,
-     const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709;
-     const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709;
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-     register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y);
-     register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y);
-     register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y);
-@@ -116,7 +116,7 @@ void rgb2gray(const Size2D &size, COLOR_SPACE color_space,
-         u8 * dst = internal::getRowPtr(dstBase, dstStride, i);
-         size_t sj = 0u, dj = 0u;
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-         for (; dj < roiw8; sj += 24, dj += 8)
-         {
-             internal::prefetch(src + sj);
-@@ -198,7 +198,7 @@ void rgbx2gray(const Size2D &size, COLOR_SPACE color_space,
-     const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709;
-     const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709;
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-     register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y);
-     register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y);
-     register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y);
-@@ -217,7 +217,7 @@ void rgbx2gray(const Size2D &size, COLOR_SPACE color_space,
-         u8 * dst = internal::getRowPtr(dstBase, dstStride, i);
-         size_t sj = 0u, dj = 0u;
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-         for (; dj < roiw8; sj += 32, dj += 8)
-         {
-             internal::prefetch(src + sj);
-@@ -300,7 +300,7 @@ void bgr2gray(const Size2D &size, COLOR_SPACE color_space,
-     const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709;
-     const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709;
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-     register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y);
-     register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y);
-     register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y);
-@@ -319,7 +319,7 @@ void bgr2gray(const Size2D &size, COLOR_SPACE color_space,
-         u8 * dst = internal::getRowPtr(dstBase, dstStride, i);
-         size_t sj = 0u, dj = 0u;
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-         for (; dj < roiw8; sj += 24, dj += 8)
-         {
-             internal::prefetch(src + sj);
-@@ -402,7 +402,7 @@ void bgrx2gray(const Size2D &size, COLOR_SPACE color_space,
-     const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709;
-     const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709;
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-     register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y);
-     register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y);
-     register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y);
-@@ -421,7 +421,7 @@ void bgrx2gray(const Size2D &size, COLOR_SPACE color_space,
-         u8 * dst = internal::getRowPtr(dstBase, dstStride, i);
-         size_t sj = 0u, dj = 0u;
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-         for (; dj < roiw8; sj += 32, dj += 8)
-         {
-             internal::prefetch(src + sj);
-@@ -512,7 +512,7 @@ void gray2rgb(const Size2D &size,
-         for (; sj < roiw16; sj += 16, dj += 48)
-         {
-             internal::prefetch(src + sj);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             __asm__ (
-             "vld1.8 {d0-d1}, [%[in0]]            \n\t"
-             "vmov.8 q1, q0                       \n\t"
-@@ -538,7 +538,7 @@ void gray2rgb(const Size2D &size,
- 
-         if (sj < roiw8)
-         {
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             __asm__ (
-             "vld1.8 {d0}, [%[in]]                \n\t"
-             "vmov.8 d1, d0                       \n\t"
-@@ -584,7 +584,7 @@ void gray2rgbx(const Size2D &size,
-     size_t roiw16 = size.width >= 15 ? size.width - 15 : 0;
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-     register uint8x16_t vc255   asm ("q4") = vmovq_n_u8(255);
- #else
-     uint8x16x4_t vRgba;
-@@ -602,7 +602,7 @@ void gray2rgbx(const Size2D &size,
-         for (; sj < roiw16; sj += 16, dj += 64)
-         {
-             internal::prefetch(src + sj);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             __asm__ (
-             "vld1.8 {d0-d1}, [%[in0]]            \n\t"
-             "vmov.8 q1, q0                       \n\t"
-@@ -628,7 +628,7 @@ void gray2rgbx(const Size2D &size,
- 
-         if (sj < roiw8)
-         {
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             __asm__ (
-             "vld1.8 {d5}, [%[in]]                \n\t"
-             "vmov.8 d6, d5                       \n\t"
-@@ -672,7 +672,7 @@ void rgb2rgbx(const Size2D &size,
-     internal::assertSupportedConfiguration();
- #ifdef CAROTENE_NEON
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-     register uint8x8_t vc255_0  asm ("d3") = vmov_n_u8(255);
- #else
-     size_t roiw16 = size.width >= 15 ? size.width - 15 : 0;
-@@ -688,7 +688,7 @@ void rgb2rgbx(const Size2D &size,
-         u8 * dst = internal::getRowPtr(dstBase, dstStride, i);
-         size_t sj = 0u, dj = 0u, j = 0u;
- 
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-         for (; j < roiw8; sj += 24, dj += 32, j += 8)
-         {
-             internal::prefetch(src + sj);
-@@ -742,7 +742,7 @@ void rgbx2rgb(const Size2D &size,
-     internal::assertSupportedConfiguration();
- #ifdef CAROTENE_NEON
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
--#if !defined(__GNUC__) || !defined(__arm__)
-+#if !(!defined(__aarch64__) && defined(__GNUC__) && defined(__arm__))
-     size_t roiw16 = size.width >= 15 ? size.width - 15 : 0;
-     union { uint8x16x4_t v4; uint8x16x3_t v3; } v_dst0;
-     union { uint8x8x4_t v4; uint8x8x3_t v3; } v_dst;
-@@ -754,7 +754,7 @@ void rgbx2rgb(const Size2D &size,
-         u8 * dst = internal::getRowPtr(dstBase, dstStride, i);
-         size_t sj = 0u, dj = 0u, j = 0u;
- 
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-         for (; j < roiw8; sj += 32, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
-@@ -805,7 +805,7 @@ void rgb2bgr(const Size2D &size,
- {
-     internal::assertSupportedConfiguration();
- #ifdef CAROTENE_NEON
--#if !defined(__GNUC__) || !defined(__arm__)
-+#if !(!defined(__aarch64__) && defined(__GNUC__) && defined(__arm__))
-     size_t roiw16 = size.width >= 15 ? size.width - 15 : 0;
- #endif
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
-@@ -817,7 +817,7 @@ void rgb2bgr(const Size2D &size,
-         size_t sj = 0u, dj = 0u, j = 0u;
- 
- 
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-         for (; j < roiw8; sj += 24, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
-@@ -874,7 +874,7 @@ void rgbx2bgrx(const Size2D &size,
- {
-     internal::assertSupportedConfiguration();
- #ifdef CAROTENE_NEON
--#if !defined(__GNUC__) || !defined(__arm__)
-+#if !(!defined(__aarch64__) && defined(__GNUC__) && defined(__arm__))
-     size_t roiw16 = size.width >= 15 ? size.width - 15 : 0;
- #endif
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
-@@ -885,7 +885,7 @@ void rgbx2bgrx(const Size2D &size,
-         u8 * dst = internal::getRowPtr(dstBase, dstStride, i);
-         size_t sj = 0u, dj = 0u, j = 0u;
- 
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-         for (; j < roiw8; sj += 32, dj += 32, j += 8)
-         {
-             internal::prefetch(src + sj);
-@@ -943,7 +943,7 @@ void rgbx2bgr(const Size2D &size,
- {
-     internal::assertSupportedConfiguration();
- #ifdef CAROTENE_NEON
--#if !defined(__GNUC__) || !defined(__arm__)
-+#if !(!defined(__aarch64__) && defined(__GNUC__) && defined(__arm__))
-     size_t roiw16 = size.width >= 15 ? size.width - 15 : 0;
- #endif
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
-@@ -954,7 +954,7 @@ void rgbx2bgr(const Size2D &size,
-         u8 * dst = internal::getRowPtr(dstBase, dstStride, i);
-         size_t sj = 0u, dj = 0u, j = 0u;
- 
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-         for (; j < roiw8; sj += 32, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
-@@ -1010,7 +1010,7 @@ void rgb2bgrx(const Size2D &size,
- {
-     internal::assertSupportedConfiguration();
- #ifdef CAROTENE_NEON
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-     register uint8x8_t vc255  asm ("d3") = vmov_n_u8(255);
- #else
-     union { uint8x16x4_t v4; uint8x16x3_t v3; } vals0;
-@@ -1019,7 +1019,7 @@ void rgb2bgrx(const Size2D &size,
-     vals8.v4.val[3] = vmov_n_u8(255);
- #endif
- 
--#if !defined(__GNUC__) || !defined(__arm__)
-+#if !(!defined(__aarch64__) && defined(__GNUC__) && defined(__arm__))
-     size_t roiw16 = size.width >= 15 ? size.width - 15 : 0;
- #endif
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
-@@ -1030,7 +1030,7 @@ void rgb2bgrx(const Size2D &size,
-         u8 * dst = internal::getRowPtr(dstBase, dstStride, i);
-         size_t sj = 0u, dj = 0u, j = 0u;
- 
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-         for (; j < roiw8; sj += 24, dj += 32, j += 8)
-         {
-             internal::prefetch(src + sj);
-@@ -1409,7 +1409,7 @@ inline void convertToHSV(const s32 r, const s32 g, const s32 b,
-               "d24","d25","d26","d27","d28","d29","d30","d31"         \
-             );
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- 
- #define YCRCB_CONSTS                                                        \
-     register int16x4_t vcYR  asm ("d31") = vmov_n_s16(4899);                \
-@@ -1555,7 +1555,7 @@ inline uint8x8x3_t convertToYCrCb( const int16x8_t& vR, const int16x8_t& vG, con
- #define COEFF_G   (  8663)
- #define COEFF_B   (-17705)
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- #define YUV420ALPHA3_CONST
- #define YUV420ALPHA4_CONST register uint8x16_t c255  asm ("q13") = vmovq_n_u8(255);
- #define YUV420ALPHA3_CONVERT
-@@ -1852,7 +1852,7 @@ void rgb2hsv(const Size2D &size,
- #ifdef CAROTENE_NEON
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
-     const s32 hsv_shift = 12;
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-     register const f32 vsdiv_table = f32(255 << hsv_shift);
-     register f32 vhdiv_table = f32(hrange << hsv_shift);
-     register const s32 vhrange = hrange;
-@@ -1871,7 +1871,7 @@ void rgb2hsv(const Size2D &size,
-         for (; j < roiw8; sj += 24, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERT_TO_HSV_ASM(vld3.8 {d0-d2}, d0, d2)
- #else
-             uint8x8x3_t vRgb = vld3_u8(src + sj);
-@@ -1904,7 +1904,7 @@ void rgbx2hsv(const Size2D &size,
- #ifdef CAROTENE_NEON
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
-     const s32 hsv_shift = 12;
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-     register const f32 vsdiv_table = f32(255 << hsv_shift);
-     register f32 vhdiv_table = f32(hrange << hsv_shift);
-     register const s32 vhrange = hrange;
-@@ -1923,7 +1923,7 @@ void rgbx2hsv(const Size2D &size,
-         for (; j < roiw8; sj += 32, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERT_TO_HSV_ASM(vld4.8 {d0-d3}, d0, d2)
- #else
-             uint8x8x4_t vRgb = vld4_u8(src + sj);
-@@ -1956,7 +1956,7 @@ void bgr2hsv(const Size2D &size,
- #ifdef CAROTENE_NEON
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
-     const s32 hsv_shift = 12;
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-     register const f32 vsdiv_table = f32(255 << hsv_shift);
-     register f32 vhdiv_table = f32(hrange << hsv_shift);
-     register const s32 vhrange = hrange;
-@@ -1975,7 +1975,7 @@ void bgr2hsv(const Size2D &size,
-         for (; j < roiw8; sj += 24, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERT_TO_HSV_ASM(vld3.8 {d0-d2}, d2, d0)
- #else
-             uint8x8x3_t vRgb = vld3_u8(src + sj);
-@@ -2008,7 +2008,7 @@ void bgrx2hsv(const Size2D &size,
- #ifdef CAROTENE_NEON
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
-     const s32 hsv_shift = 12;
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-     register const f32 vsdiv_table = f32(255 << hsv_shift);
-     register f32 vhdiv_table = f32(hrange << hsv_shift);
-     register const s32 vhrange = hrange;
-@@ -2027,7 +2027,7 @@ void bgrx2hsv(const Size2D &size,
-         for (; j < roiw8; sj += 32, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERT_TO_HSV_ASM(vld4.8 {d0-d3}, d2, d0)
- #else
-             uint8x8x4_t vRgb = vld4_u8(src + sj);
-@@ -2068,7 +2068,7 @@ void rgbx2bgr565(const Size2D &size,
-         for (; j < roiw16; sj += 64, dj += 32, j += 16)
-         {
-             internal::prefetch(src + sj);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             __asm__ (
-                 "vld4.8 {d2, d4, d6, d8}, [%[in0]]        @  q0       q1       q2       q3       q4       \n\t"
-                 "vld4.8 {d3, d5, d7, d9}, [%[in1]]        @  xxxxxxxx rrrrRRRR ggggGGGG bbbbBBBB xxxxxxxx \n\t"
-@@ -2122,7 +2122,7 @@ void rgb2bgr565(const Size2D &size,
-         for (; j < roiw16; sj += 48, dj += 32, j += 16)
-         {
-             internal::prefetch(src + sj);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             __asm__ (
-                 "vld3.8 {d2, d4, d6}, [%[in0]]       @  q0       q1       q2       q3       q4       \n\t"
-                 "vld3.8 {d3, d5, d7}, [%[in1]]       @  xxxxxxxx rrrrRRRR ggggGGGG bbbbBBBB xxxxxxxx \n\t"
-@@ -2176,7 +2176,7 @@ void rgbx2rgb565(const Size2D &size,
-         for (; j < roiw16; sj += 64, dj += 32, j += 16)
-         {
-             internal::prefetch(src + sj);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             __asm__ (
-                 "vld4.8 {d0, d2, d4, d6}, [%[in0]]    @  q0       q1       q2       q3         \n\t"
-                 "vld4.8 {d1, d3, d5, d7}, [%[in1]]    @  rrrrRRRR ggggGGGG bbbbBBBB aaaaAAAA   \n\t"
-@@ -2230,7 +2230,7 @@ void rgb2rgb565(const Size2D &size,
-         for (; j < roiw16; sj += 48, dj += 32, j += 16)
-         {
-             internal::prefetch(src + sj);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             __asm__ (
-                 "vld3.8 {d0, d2, d4}, [%[in0]]        @  q0       q1       q2       q3         \n\t"
-                 "vld3.8 {d1, d3, d5}, [%[in1]]        @  rrrrRRRR ggggGGGG bbbbBBBB xxxxxxxx   \n\t"
-@@ -2285,7 +2285,7 @@ void rgb2ycrcb(const Size2D &size,
-         for (; j < roiw8; sj += 24, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERTTOYCRCB(vld3.8 {d0-d2}, d0, d1, d2)
- #else
-             uint8x8x3_t vRgb = vld3_u8(src + sj);
-@@ -2329,7 +2329,7 @@ void rgbx2ycrcb(const Size2D &size,
-         for (; j < roiw8; sj += 32, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERTTOYCRCB(vld4.8 {d0-d3}, d0, d1, d2)
- #else
-             uint8x8x4_t vRgba = vld4_u8(src + sj);
-@@ -2373,7 +2373,7 @@ void bgr2ycrcb(const Size2D &size,
-         for (; j < roiw8; sj += 24, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERTTOYCRCB(vld3.8 {d0-d2}, d2, d1, d0)
- #else
-             uint8x8x3_t vBgr = vld3_u8(src + sj);
-@@ -2417,7 +2417,7 @@ void bgrx2ycrcb(const Size2D &size,
-         for (; j < roiw8; sj += 32, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERTTOYCRCB(vld4.8 {d0-d3}, d2, d1, d0)
- #else
-             uint8x8x4_t vBgra = vld4_u8(src + sj);
-@@ -2499,7 +2499,7 @@ void yuv420sp2rgb(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERTYUV420TORGB(3, d1, d0, q5, q6)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-@@ -2545,7 +2545,7 @@ void yuv420sp2rgbx(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERTYUV420TORGB(4, d1, d0, q5, q6)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-@@ -2591,7 +2591,7 @@ void yuv420i2rgb(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERTYUV420TORGB(3, d0, d1, q5, q6)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-@@ -2637,7 +2637,7 @@ void yuv420i2rgbx(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERTYUV420TORGB(4, d0, d1, q5, q6)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-@@ -2683,7 +2683,7 @@ void yuv420sp2bgr(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERTYUV420TORGB(3, d1, d0, q6, q5)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-@@ -2729,7 +2729,7 @@ void yuv420sp2bgrx(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERTYUV420TORGB(4, d1, d0, q6, q5)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-@@ -2775,7 +2775,7 @@ void yuv420i2bgr(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERTYUV420TORGB(3, d0, d1, q6, q5)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-@@ -2821,7 +2821,7 @@ void yuv420i2bgrx(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             CONVERTYUV420TORGB(4, d0, d1, q6, q5)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-diff --git a/3rdparty/carotene/src/convert.cpp b/3rdparty/carotene/src/convert.cpp
-index 403f16d86a..64b6db78ab 100644
---- a/3rdparty/carotene/src/convert.cpp
-+++ b/3rdparty/carotene/src/convert.cpp
-@@ -101,7 +101,7 @@ CVT_FUNC(u8, s8, 16,
-      }
- })
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVT_FUNC(u8, u16, 16,
-      register uint8x16_t zero0 asm ("q1") = vmovq_n_u8(0);,
- {
-@@ -135,7 +135,7 @@ CVT_FUNC(u8, u16, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVT_FUNC(u8, s32, 16,
-      register uint8x16_t zero0 asm ("q1") = vmovq_n_u8(0);
-      register uint8x16_t zero1 asm ("q2") = vmovq_n_u8(0);
-@@ -173,7 +173,7 @@ CVT_FUNC(u8, s32, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(u8, f32, 16,
- ,
- {
-@@ -248,7 +248,7 @@ CVT_FUNC(s8, u8, 16,
-      }
- })
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVT_FUNC(s8, u16, 16,
-      register uint8x16_t zero0 asm ("q1") = vmovq_n_u8(0);,
- {
-@@ -284,7 +284,7 @@ CVT_FUNC(s8, u16, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(s8, s16, 16,
- ,
- {
-@@ -323,7 +323,7 @@ CVT_FUNC(s8, s16, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVT_FUNC(s8, s32, 16,
- ,
- {
-@@ -377,7 +377,7 @@ CVT_FUNC(s8, s32, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(s8, f32, 16,
- ,
- {
-@@ -440,7 +440,7 @@ CVT_FUNC(s8, f32, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(u16, u8, 16,
- ,
- {
-@@ -479,7 +479,7 @@ CVT_FUNC(u16, u8, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(u16, s8, 16,
-     register uint8x16_t v127 asm ("q4") = vmovq_n_u8(127);,
- {
-@@ -522,7 +522,7 @@ CVT_FUNC(u16, s8, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVT_FUNC(u16, s16, 8,
-      register uint16x8_t v32767 asm ("q4") = vmovq_n_u16(0x7FFF);,
- {
-@@ -555,7 +555,7 @@ CVT_FUNC(u16, s16, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVT_FUNC(u16, s32, 8,
-      register uint16x8_t zero0 asm ("q1") = vmovq_n_u16(0);,
- {
-@@ -589,7 +589,7 @@ CVT_FUNC(u16, s32, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(u16, f32, 8,
- ,
- {
-@@ -633,7 +633,7 @@ CVT_FUNC(u16, f32, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(s16, u8, 16,
- ,
- {
-@@ -672,7 +672,7 @@ CVT_FUNC(s16, u8, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(s16, s8, 16,
- ,
- {
-@@ -711,7 +711,7 @@ CVT_FUNC(s16, s8, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVT_FUNC(s16, u16, 8,
-      register int16x8_t vZero asm ("q4") = vmovq_n_s16(0);,
- {
-@@ -747,7 +747,7 @@ CVT_FUNC(s16, u16, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(s16, s32, 8,
- ,
- {
-@@ -786,7 +786,7 @@ CVT_FUNC(s16, s32, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(s16, f32, 8,
- ,
- {
-@@ -829,7 +829,7 @@ CVT_FUNC(s16, f32, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(s32, u8, 8,
- ,
- {
-@@ -870,7 +870,7 @@ CVT_FUNC(s32, u8, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(s32, s8, 8,
- ,
- {
-@@ -911,7 +911,7 @@ CVT_FUNC(s32, s8, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(s32, u16, 8,
- ,
- {
-@@ -950,7 +950,7 @@ CVT_FUNC(s32, u16, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(s32, s16, 8,
- ,
- {
-@@ -989,7 +989,7 @@ CVT_FUNC(s32, s16, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(s32, f32, 8,
- ,
- {
-@@ -1034,7 +1034,7 @@ CVT_FUNC(s32, f32, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(f32, u8, 8,
-     register float32x4_t vmult asm ("q0") = vdupq_n_f32((float)(1 << 16));
-     register uint32x4_t  vmask asm ("q1") = vdupq_n_u32(1<<16);,
-@@ -1101,7 +1101,7 @@ CVT_FUNC(f32, u8, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(f32, s8, 8,
-      register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);,
- {
-@@ -1153,7 +1153,7 @@ CVT_FUNC(f32, s8, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(f32, u16, 8,
-      register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);,
- {
-@@ -1212,7 +1212,7 @@ CVT_FUNC(f32, u16, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(f32, s16, 8,
-      register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);,
- {
-@@ -1271,7 +1271,7 @@ CVT_FUNC(f32, s16, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
- CVT_FUNC(f32, s32, 8,
-      register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);,
- {
-diff --git a/3rdparty/carotene/src/convert_scale.cpp b/3rdparty/carotene/src/convert_scale.cpp
-index 0a14a8035c..ae41a985c8 100644
---- a/3rdparty/carotene/src/convert_scale.cpp
-+++ b/3rdparty/carotene/src/convert_scale.cpp
-@@ -135,7 +135,7 @@ namespace CAROTENE_NS {
- 
- #endif
- 
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
- CVTS_FUNC1(u8, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -220,7 +220,7 @@ CVTS_FUNC1(u8, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
- CVTS_FUNC(u8, s8, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -305,7 +305,7 @@ CVTS_FUNC(u8, s8, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
- CVTS_FUNC(u8, u16, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -389,7 +389,7 @@ CVTS_FUNC(u8, u16, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
- CVTS_FUNC(u8, s16, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -473,7 +473,7 @@ CVTS_FUNC(u8, s16, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(u8, s32, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -562,7 +562,7 @@ CVTS_FUNC(u8, s32, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(u8, f32, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);,
-@@ -643,7 +643,7 @@ CVTS_FUNC(u8, f32, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
- CVTS_FUNC(s8, u8, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -728,7 +728,7 @@ CVTS_FUNC(s8, u8, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
- CVTS_FUNC1(s8, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -813,7 +813,7 @@ CVTS_FUNC1(s8, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
- CVTS_FUNC(s8, u16, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -899,7 +899,7 @@ CVTS_FUNC(s8, u16, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
- CVTS_FUNC(s8, s16, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -985,7 +985,7 @@ CVTS_FUNC(s8, s16, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(s8, s32, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1074,7 +1074,7 @@ CVTS_FUNC(s8, s32, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(s8, f32, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);,
-@@ -1155,7 +1155,7 @@ CVTS_FUNC(s8, f32, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(u16, u8, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1214,7 +1214,7 @@ CVTS_FUNC(u16, u8, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(u16, s8, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1273,7 +1273,7 @@ CVTS_FUNC(u16, s8, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC1(u16, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1330,7 +1330,7 @@ CVTS_FUNC1(u16, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(u16, s16, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1387,7 +1387,7 @@ CVTS_FUNC(u16, s16, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(u16, s32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1443,7 +1443,7 @@ CVTS_FUNC(u16, s32, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(u16, f32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);,
-@@ -1495,7 +1495,7 @@ CVTS_FUNC(u16, f32, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(s16, u8, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1554,7 +1554,7 @@ CVTS_FUNC(s16, u8, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(s16, s8, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1613,7 +1613,7 @@ CVTS_FUNC(s16, s8, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(s16, u16, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1670,7 +1670,7 @@ CVTS_FUNC(s16, u16, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC1(s16, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1727,7 +1727,7 @@ CVTS_FUNC1(s16, 16,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(s16, s32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1783,7 +1783,7 @@ CVTS_FUNC(s16, s32, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(s16, f32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);,
-@@ -1835,7 +1835,7 @@ CVTS_FUNC(s16, f32, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(s32, u8, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1893,7 +1893,7 @@ CVTS_FUNC(s32, u8, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(s32, s8, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1951,7 +1951,7 @@ CVTS_FUNC(s32, s8, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(s32, u16, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -2007,7 +2007,7 @@ CVTS_FUNC(s32, u16, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(s32, s16, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -2063,7 +2063,7 @@ CVTS_FUNC(s32, s16, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC1(s32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -2118,7 +2118,7 @@ CVTS_FUNC1(s32, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(s32, f32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);,
-@@ -2169,7 +2169,7 @@ CVTS_FUNC(s32, f32, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(f32, u8, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)((1 << 16)*alpha));
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)((1 << 16)*beta));
-@@ -2239,7 +2239,7 @@ CVTS_FUNC(f32, u8, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(f32, s8, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -2293,7 +2293,7 @@ CVTS_FUNC(f32, s8, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(f32, u16, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -2345,7 +2345,7 @@ CVTS_FUNC(f32, u16, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(f32, s16, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -2397,7 +2397,7 @@ CVTS_FUNC(f32, s16, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC(f32, s32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -2448,7 +2448,7 @@ CVTS_FUNC(f32, s32, 8,
- })
- #endif
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
- CVTS_FUNC1(f32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);,
-diff --git a/3rdparty/carotene/src/gaussian_blur.cpp b/3rdparty/carotene/src/gaussian_blur.cpp
-index 1b5399436f..f7b5f18d79 100644
---- a/3rdparty/carotene/src/gaussian_blur.cpp
-+++ b/3rdparty/carotene/src/gaussian_blur.cpp
-@@ -327,7 +327,7 @@ void gaussianBlur5x5(const Size2D &size, s32 cn,
-                 u16* lidx1 = lane + x - 1*2;
-                 u16* lidx3 = lane + x + 1*2;
-                 u16* lidx4 = lane + x + 2*2;
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-                 __asm__ __volatile__ (
-                     "vld2.16 {d0, d2}, [%[in0]]!                              \n\t"
-                     "vld2.16 {d1, d3}, [%[in0]]                               \n\t"
-@@ -398,7 +398,7 @@ void gaussianBlur5x5(const Size2D &size, s32 cn,
-                 u16* lidx1 = lane + x - 1*3;
-                 u16* lidx3 = lane + x + 1*3;
-                 u16* lidx4 = lane + x + 2*3;
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-                 __asm__ __volatile__ (
-                     "vld3.16 {d0, d2, d4}, [%[in0]]!                          \n\t"
-                     "vld3.16 {d1, d3, d5}, [%[in0]]                           \n\t"
-@@ -482,7 +482,7 @@ void gaussianBlur5x5(const Size2D &size, s32 cn,
-                 u16* lidx1 = lane + x - 1*4;
-                 u16* lidx3 = lane + x + 1*4;
-                 u16* lidx4 = lane + x + 2*4;
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-                 __asm__ __volatile__ (
-                     "vld4.16 {d0, d2, d4, d6}, [%[in0]]!                      \n\t"
-                     "vld4.16 {d1, d3, d5, d7}, [%[in0]]                       \n\t"
-diff --git a/3rdparty/carotene/src/pyramid.cpp b/3rdparty/carotene/src/pyramid.cpp
-index 8ef1268933..232ccf3efd 100644
---- a/3rdparty/carotene/src/pyramid.cpp
-+++ b/3rdparty/carotene/src/pyramid.cpp
-@@ -331,7 +331,7 @@ void gaussianPyramidDown(const Size2D &srcSize,
-             for (; x < roiw8; x += 8)
-             {
-                 internal::prefetch(lane + 2 * x);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-                 __asm__ (
-                     "vld2.16 {d0-d3}, [%[in0]]                               \n\t"
-                     "vld2.16 {d4-d7}, [%[in4]]                               \n\t"
-@@ -538,7 +538,7 @@ void gaussianPyramidDown(const Size2D &srcSize,
-             for (; x < roiw4; x += 4)
-             {
-                 internal::prefetch(lane + 2 * x);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-                 __asm__ (
-                     "vld2.32 {d0-d3}, [%[in0]]                              \n\t"
-                     "vld2.32 {d4-d7}, [%[in4]]                              \n\t"
-@@ -672,7 +672,7 @@ void gaussianPyramidDown(const Size2D &srcSize,
-     std::vector<f32> _buf(cn*(srcSize.width + 4) + 32/sizeof(f32));
-     f32* lane = internal::alignPtr(&_buf[2*cn], 32);
- 
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-     register float32x4_t vc6d4f32  asm ("q11") = vmovq_n_f32(1.5f);  // 6/4
-     register float32x4_t vc1d4f32  asm ("q12") = vmovq_n_f32(0.25f); // 1/4
- 
-@@ -739,7 +739,7 @@ void gaussianPyramidDown(const Size2D &srcSize,
-             for (; x < roiw4; x += 4)
-             {
-                 internal::prefetch(lane + 2 * x);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-                 __asm__ __volatile__ (
-                     "vld2.32 {d0-d3}, [%[in0]]                              \n\t"
-                     "vld2.32 {d8-d11}, [%[in4]]                             \n\t"
-@@ -932,7 +932,7 @@ pyrUp8uHorizontalConvolution:
-             for (; x < lim; x += 8)
-             {
-                 internal::prefetch(lane + x);
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-                 __asm__ (
-                     "vld1.16 {d0-d1}, [%[in0]]       /*q0 = v0*/            \n\t"
-                     "vld1.16 {d2-d3}, [%[in2]]       /*q1 = v2*/            \n\t"
-@@ -973,7 +973,7 @@ pyrUp8uHorizontalConvolution:
-             for (; x < lim; x += 24)
-             {
-                 internal::prefetch(lane + x);
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-                 __asm__ (
-                     "vmov.u16 q9, #6                                           \n\t"
-                     "vld3.16 {d0, d2, d4}, [%[in0]]        /*v0*/              \n\t"
-@@ -1064,7 +1064,7 @@ pyrUp8uHorizontalConvolution:
-             for (; x < lim; x += 8)
-             {
-                 internal::prefetch(lane + x);
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-                 __asm__ (
-                     "vld1.16 {d0-d1}, [%[in0]]       /*q0 = v0*/            \n\t"
-                     "vld1.16 {d2-d3}, [%[in2]]       /*q1 = v2*/            \n\t"
-@@ -1210,7 +1210,7 @@ pyrUp16sHorizontalConvolution:
-             for (; x < lim; x += 4)
-             {
-                 internal::prefetch(lane + x);
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-                 __asm__ (
-                     "vld1.32 {d0-d1}, [%[in0]]       /*q0 = v0*/            \n\t"
-                     "vld1.32 {d2-d3}, [%[in2]]       /*q1 = v2*/            \n\t"
-@@ -1251,7 +1251,7 @@ pyrUp16sHorizontalConvolution:
-             for (; x < lim; x += 12)
-             {
-                 internal::prefetch(lane + x + 3);
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-                 __asm__ (
-                     "vmov.s32 q9, #6                                           \n\t"
-                     "vld3.32 {d0, d2, d4}, [%[in0]]        /*v0*/              \n\t"
-@@ -1343,7 +1343,7 @@ pyrUp16sHorizontalConvolution:
-             for (; x < lim; x += 4)
-             {
-                 internal::prefetch(lane + x);
--#if defined(__GNUC__) && defined(__arm__)
-+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)
-                 __asm__ (
-                     "vld1.32 {d0-d1}, [%[in0]]       /*q0 = v0*/            \n\t"
-                     "vld1.32 {d2-d3}, [%[in2]]       /*q1 = v2*/            \n\t"
-diff --git a/3rdparty/carotene/src/scharr.cpp b/3rdparty/carotene/src/scharr.cpp
-index 5695804fe4..8d3b6328b1 100644
---- a/3rdparty/carotene/src/scharr.cpp
-+++ b/3rdparty/carotene/src/scharr.cpp
-@@ -109,7 +109,7 @@ void ScharrDeriv(const Size2D &size, s32 cn,
-             internal::prefetch(srow0 + x);
-             internal::prefetch(srow1 + x);
-             internal::prefetch(srow2 + x);
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-             __asm__ (
-                 "vld1.8 {d0}, [%[src0]]                                \n\t"
-                 "vld1.8 {d2}, [%[src2]]                                \n\t"
-@@ -161,7 +161,7 @@ void ScharrDeriv(const Size2D &size, s32 cn,
-         x = 0;
-         for( ; x < roiw8; x += 8 )
-         {
--#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-             __asm__ (
-                 "vld1.16 {d4-d5}, [%[s2ptr]]                           \n\t"
-                 "vld1.16 {d8-d9}, [%[s4ptr]]                           \n\t"
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0002-Do-not-enable-asm-with-clang.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0002-Do-not-enable-asm-with-clang.patch
deleted file mode 100644
index 22e868a..0000000
--- a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0002-Do-not-enable-asm-with-clang.patch
+++ /dev/null
@@ -1,993 +0,0 @@
-From 333f60165b6737588eb975a5e4393d847011a1cd Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 19 Sep 2017 18:07:35 -0700
-Subject: [PATCH 2/2] Do not enable asm with clang
-
-clang pretends to be gcc 4.2.0 which means we will
-use inline asm for no reason, instead of builtins
-on clang when possible.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Submitted
- 3rdparty/carotene/src/channel_extract.cpp  |  4 +-
- 3rdparty/carotene/src/channels_combine.cpp |  2 +-
- 3rdparty/carotene/src/colorconvert.cpp     | 78 +++++++++++++++---------------
- 3rdparty/carotene/src/convert.cpp          | 54 ++++++++++-----------
- 3rdparty/carotene/src/convert_scale.cpp    | 56 ++++++++++-----------
- 3rdparty/carotene/src/gaussian_blur.cpp    |  2 +-
- 3rdparty/carotene/src/pyramid.cpp          |  8 +--
- 3rdparty/carotene/src/scharr.cpp           |  4 +-
- 8 files changed, 104 insertions(+), 104 deletions(-)
-
-diff --git a/3rdparty/carotene/src/channel_extract.cpp b/3rdparty/carotene/src/channel_extract.cpp
-index 8238a3ece8..ff4fb3770c 100644
---- a/3rdparty/carotene/src/channel_extract.cpp
-+++ b/3rdparty/carotene/src/channel_extract.cpp
-@@ -231,7 +231,7 @@ void extract4(const Size2D &size,
-                  srcStride == dst2Stride && \
-                  srcStride == dst3Stride &&
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- 
- #define SPLIT_ASM2(sgn, bits) __asm__ ( \
-                                           "vld2." #bits " {d0, d2}, [%[in0]]            \n\t" \
-@@ -351,7 +351,7 @@ void extract4(const Size2D &size,
-     }                                                                                                   \
- }
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- 
- #define ALPHA_QUAD(sgn, bits) { \
-                                   internal::prefetch(src + sj); \
-diff --git a/3rdparty/carotene/src/channels_combine.cpp b/3rdparty/carotene/src/channels_combine.cpp
-index fc98fb9181..5d9251d51c 100644
---- a/3rdparty/carotene/src/channels_combine.cpp
-+++ b/3rdparty/carotene/src/channels_combine.cpp
-@@ -77,7 +77,7 @@ namespace CAROTENE_NS {
-                  dstStride == src2Stride && \
-                  dstStride == src3Stride &&
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- 
- #define MERGE_ASM2(sgn, bits) __asm__ ( \
-                                           "vld1." #bits " {d0-d1}, [%[in0]]             \n\t" \
-diff --git a/3rdparty/carotene/src/colorconvert.cpp b/3rdparty/carotene/src/colorconvert.cpp
-index 26ae54b15c..d3a40fe64e 100644
---- a/3rdparty/carotene/src/colorconvert.cpp
-+++ b/3rdparty/carotene/src/colorconvert.cpp
-@@ -97,7 +97,7 @@ void rgb2gray(const Size2D &size, COLOR_SPACE color_space,
-     const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709;
-     const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709;
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-     register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y);
-     register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y);
-     register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y);
-@@ -116,7 +116,7 @@ void rgb2gray(const Size2D &size, COLOR_SPACE color_space,
-         u8 * dst = internal::getRowPtr(dstBase, dstStride, i);
-         size_t sj = 0u, dj = 0u;
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-         for (; dj < roiw8; sj += 24, dj += 8)
-         {
-             internal::prefetch(src + sj);
-@@ -198,7 +198,7 @@ void rgbx2gray(const Size2D &size, COLOR_SPACE color_space,
-     const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709;
-     const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709;
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-     register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y);
-     register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y);
-     register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y);
-@@ -217,7 +217,7 @@ void rgbx2gray(const Size2D &size, COLOR_SPACE color_space,
-         u8 * dst = internal::getRowPtr(dstBase, dstStride, i);
-         size_t sj = 0u, dj = 0u;
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-         for (; dj < roiw8; sj += 32, dj += 8)
-         {
-             internal::prefetch(src + sj);
-@@ -300,7 +300,7 @@ void bgr2gray(const Size2D &size, COLOR_SPACE color_space,
-     const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709;
-     const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709;
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-     register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y);
-     register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y);
-     register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y);
-@@ -319,7 +319,7 @@ void bgr2gray(const Size2D &size, COLOR_SPACE color_space,
-         u8 * dst = internal::getRowPtr(dstBase, dstStride, i);
-         size_t sj = 0u, dj = 0u;
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-         for (; dj < roiw8; sj += 24, dj += 8)
-         {
-             internal::prefetch(src + sj);
-@@ -402,7 +402,7 @@ void bgrx2gray(const Size2D &size, COLOR_SPACE color_space,
-     const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709;
-     const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709;
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-     register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y);
-     register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y);
-     register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y);
-@@ -421,7 +421,7 @@ void bgrx2gray(const Size2D &size, COLOR_SPACE color_space,
-         u8 * dst = internal::getRowPtr(dstBase, dstStride, i);
-         size_t sj = 0u, dj = 0u;
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-         for (; dj < roiw8; sj += 32, dj += 8)
-         {
-             internal::prefetch(src + sj);
-@@ -512,7 +512,7 @@ void gray2rgb(const Size2D &size,
-         for (; sj < roiw16; sj += 16, dj += 48)
-         {
-             internal::prefetch(src + sj);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             __asm__ (
-             "vld1.8 {d0-d1}, [%[in0]]            \n\t"
-             "vmov.8 q1, q0                       \n\t"
-@@ -538,7 +538,7 @@ void gray2rgb(const Size2D &size,
- 
-         if (sj < roiw8)
-         {
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             __asm__ (
-             "vld1.8 {d0}, [%[in]]                \n\t"
-             "vmov.8 d1, d0                       \n\t"
-@@ -584,7 +584,7 @@ void gray2rgbx(const Size2D &size,
-     size_t roiw16 = size.width >= 15 ? size.width - 15 : 0;
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-     register uint8x16_t vc255   asm ("q4") = vmovq_n_u8(255);
- #else
-     uint8x16x4_t vRgba;
-@@ -602,7 +602,7 @@ void gray2rgbx(const Size2D &size,
-         for (; sj < roiw16; sj += 16, dj += 64)
-         {
-             internal::prefetch(src + sj);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             __asm__ (
-             "vld1.8 {d0-d1}, [%[in0]]            \n\t"
-             "vmov.8 q1, q0                       \n\t"
-@@ -628,7 +628,7 @@ void gray2rgbx(const Size2D &size,
- 
-         if (sj < roiw8)
-         {
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             __asm__ (
-             "vld1.8 {d5}, [%[in]]                \n\t"
-             "vmov.8 d6, d5                       \n\t"
-@@ -1409,7 +1409,7 @@ inline void convertToHSV(const s32 r, const s32 g, const s32 b,
-               "d24","d25","d26","d27","d28","d29","d30","d31"         \
-             );
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- 
- #define YCRCB_CONSTS                                                        \
-     register int16x4_t vcYR  asm ("d31") = vmov_n_s16(4899);                \
-@@ -1555,7 +1555,7 @@ inline uint8x8x3_t convertToYCrCb( const int16x8_t& vR, const int16x8_t& vG, con
- #define COEFF_G   (  8663)
- #define COEFF_B   (-17705)
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- #define YUV420ALPHA3_CONST
- #define YUV420ALPHA4_CONST register uint8x16_t c255  asm ("q13") = vmovq_n_u8(255);
- #define YUV420ALPHA3_CONVERT
-@@ -1852,7 +1852,7 @@ void rgb2hsv(const Size2D &size,
- #ifdef CAROTENE_NEON
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
-     const s32 hsv_shift = 12;
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-     register const f32 vsdiv_table = f32(255 << hsv_shift);
-     register f32 vhdiv_table = f32(hrange << hsv_shift);
-     register const s32 vhrange = hrange;
-@@ -1871,7 +1871,7 @@ void rgb2hsv(const Size2D &size,
-         for (; j < roiw8; sj += 24, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERT_TO_HSV_ASM(vld3.8 {d0-d2}, d0, d2)
- #else
-             uint8x8x3_t vRgb = vld3_u8(src + sj);
-@@ -1904,7 +1904,7 @@ void rgbx2hsv(const Size2D &size,
- #ifdef CAROTENE_NEON
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
-     const s32 hsv_shift = 12;
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-     register const f32 vsdiv_table = f32(255 << hsv_shift);
-     register f32 vhdiv_table = f32(hrange << hsv_shift);
-     register const s32 vhrange = hrange;
-@@ -1923,7 +1923,7 @@ void rgbx2hsv(const Size2D &size,
-         for (; j < roiw8; sj += 32, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERT_TO_HSV_ASM(vld4.8 {d0-d3}, d0, d2)
- #else
-             uint8x8x4_t vRgb = vld4_u8(src + sj);
-@@ -1956,7 +1956,7 @@ void bgr2hsv(const Size2D &size,
- #ifdef CAROTENE_NEON
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
-     const s32 hsv_shift = 12;
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-     register const f32 vsdiv_table = f32(255 << hsv_shift);
-     register f32 vhdiv_table = f32(hrange << hsv_shift);
-     register const s32 vhrange = hrange;
-@@ -1975,7 +1975,7 @@ void bgr2hsv(const Size2D &size,
-         for (; j < roiw8; sj += 24, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERT_TO_HSV_ASM(vld3.8 {d0-d2}, d2, d0)
- #else
-             uint8x8x3_t vRgb = vld3_u8(src + sj);
-@@ -2008,7 +2008,7 @@ void bgrx2hsv(const Size2D &size,
- #ifdef CAROTENE_NEON
-     size_t roiw8 = size.width >= 7 ? size.width - 7 : 0;
-     const s32 hsv_shift = 12;
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-     register const f32 vsdiv_table = f32(255 << hsv_shift);
-     register f32 vhdiv_table = f32(hrange << hsv_shift);
-     register const s32 vhrange = hrange;
-@@ -2027,7 +2027,7 @@ void bgrx2hsv(const Size2D &size,
-         for (; j < roiw8; sj += 32, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERT_TO_HSV_ASM(vld4.8 {d0-d3}, d2, d0)
- #else
-             uint8x8x4_t vRgb = vld4_u8(src + sj);
-@@ -2068,7 +2068,7 @@ void rgbx2bgr565(const Size2D &size,
-         for (; j < roiw16; sj += 64, dj += 32, j += 16)
-         {
-             internal::prefetch(src + sj);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             __asm__ (
-                 "vld4.8 {d2, d4, d6, d8}, [%[in0]]        @  q0       q1       q2       q3       q4       \n\t"
-                 "vld4.8 {d3, d5, d7, d9}, [%[in1]]        @  xxxxxxxx rrrrRRRR ggggGGGG bbbbBBBB xxxxxxxx \n\t"
-@@ -2122,7 +2122,7 @@ void rgb2bgr565(const Size2D &size,
-         for (; j < roiw16; sj += 48, dj += 32, j += 16)
-         {
-             internal::prefetch(src + sj);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             __asm__ (
-                 "vld3.8 {d2, d4, d6}, [%[in0]]       @  q0       q1       q2       q3       q4       \n\t"
-                 "vld3.8 {d3, d5, d7}, [%[in1]]       @  xxxxxxxx rrrrRRRR ggggGGGG bbbbBBBB xxxxxxxx \n\t"
-@@ -2176,7 +2176,7 @@ void rgbx2rgb565(const Size2D &size,
-         for (; j < roiw16; sj += 64, dj += 32, j += 16)
-         {
-             internal::prefetch(src + sj);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             __asm__ (
-                 "vld4.8 {d0, d2, d4, d6}, [%[in0]]    @  q0       q1       q2       q3         \n\t"
-                 "vld4.8 {d1, d3, d5, d7}, [%[in1]]    @  rrrrRRRR ggggGGGG bbbbBBBB aaaaAAAA   \n\t"
-@@ -2230,7 +2230,7 @@ void rgb2rgb565(const Size2D &size,
-         for (; j < roiw16; sj += 48, dj += 32, j += 16)
-         {
-             internal::prefetch(src + sj);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             __asm__ (
-                 "vld3.8 {d0, d2, d4}, [%[in0]]        @  q0       q1       q2       q3         \n\t"
-                 "vld3.8 {d1, d3, d5}, [%[in1]]        @  rrrrRRRR ggggGGGG bbbbBBBB xxxxxxxx   \n\t"
-@@ -2285,7 +2285,7 @@ void rgb2ycrcb(const Size2D &size,
-         for (; j < roiw8; sj += 24, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERTTOYCRCB(vld3.8 {d0-d2}, d0, d1, d2)
- #else
-             uint8x8x3_t vRgb = vld3_u8(src + sj);
-@@ -2329,7 +2329,7 @@ void rgbx2ycrcb(const Size2D &size,
-         for (; j < roiw8; sj += 32, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERTTOYCRCB(vld4.8 {d0-d3}, d0, d1, d2)
- #else
-             uint8x8x4_t vRgba = vld4_u8(src + sj);
-@@ -2373,7 +2373,7 @@ void bgr2ycrcb(const Size2D &size,
-         for (; j < roiw8; sj += 24, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERTTOYCRCB(vld3.8 {d0-d2}, d2, d1, d0)
- #else
-             uint8x8x3_t vBgr = vld3_u8(src + sj);
-@@ -2417,7 +2417,7 @@ void bgrx2ycrcb(const Size2D &size,
-         for (; j < roiw8; sj += 32, dj += 24, j += 8)
-         {
-             internal::prefetch(src + sj);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERTTOYCRCB(vld4.8 {d0-d3}, d2, d1, d0)
- #else
-             uint8x8x4_t vBgra = vld4_u8(src + sj);
-@@ -2499,7 +2499,7 @@ void yuv420sp2rgb(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERTYUV420TORGB(3, d1, d0, q5, q6)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-@@ -2545,7 +2545,7 @@ void yuv420sp2rgbx(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERTYUV420TORGB(4, d1, d0, q5, q6)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-@@ -2591,7 +2591,7 @@ void yuv420i2rgb(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERTYUV420TORGB(3, d0, d1, q5, q6)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-@@ -2637,7 +2637,7 @@ void yuv420i2rgbx(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERTYUV420TORGB(4, d0, d1, q5, q6)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-@@ -2683,7 +2683,7 @@ void yuv420sp2bgr(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERTYUV420TORGB(3, d1, d0, q6, q5)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-@@ -2729,7 +2729,7 @@ void yuv420sp2bgrx(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERTYUV420TORGB(4, d1, d0, q6, q5)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-@@ -2775,7 +2775,7 @@ void yuv420i2bgr(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERTYUV420TORGB(3, d0, d1, q6, q5)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-@@ -2821,7 +2821,7 @@ void yuv420i2bgrx(const Size2D &size,
-             internal::prefetch(uv + j);
-             internal::prefetch(y1 + j);
-             internal::prefetch(y2 + j);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             CONVERTYUV420TORGB(4, d0, d1, q6, q5)
- #else
-             convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj);
-diff --git a/3rdparty/carotene/src/convert.cpp b/3rdparty/carotene/src/convert.cpp
-index 64b6db78ab..f0c2d153f2 100644
---- a/3rdparty/carotene/src/convert.cpp
-+++ b/3rdparty/carotene/src/convert.cpp
-@@ -101,7 +101,7 @@ CVT_FUNC(u8, s8, 16,
-      }
- })
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVT_FUNC(u8, u16, 16,
-      register uint8x16_t zero0 asm ("q1") = vmovq_n_u8(0);,
- {
-@@ -135,7 +135,7 @@ CVT_FUNC(u8, u16, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVT_FUNC(u8, s32, 16,
-      register uint8x16_t zero0 asm ("q1") = vmovq_n_u8(0);
-      register uint8x16_t zero1 asm ("q2") = vmovq_n_u8(0);
-@@ -173,7 +173,7 @@ CVT_FUNC(u8, s32, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(u8, f32, 16,
- ,
- {
-@@ -248,7 +248,7 @@ CVT_FUNC(s8, u8, 16,
-      }
- })
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVT_FUNC(s8, u16, 16,
-      register uint8x16_t zero0 asm ("q1") = vmovq_n_u8(0);,
- {
-@@ -284,7 +284,7 @@ CVT_FUNC(s8, u16, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(s8, s16, 16,
- ,
- {
-@@ -323,7 +323,7 @@ CVT_FUNC(s8, s16, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVT_FUNC(s8, s32, 16,
- ,
- {
-@@ -377,7 +377,7 @@ CVT_FUNC(s8, s32, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(s8, f32, 16,
- ,
- {
-@@ -440,7 +440,7 @@ CVT_FUNC(s8, f32, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(u16, u8, 16,
- ,
- {
-@@ -479,7 +479,7 @@ CVT_FUNC(u16, u8, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(u16, s8, 16,
-     register uint8x16_t v127 asm ("q4") = vmovq_n_u8(127);,
- {
-@@ -522,7 +522,7 @@ CVT_FUNC(u16, s8, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVT_FUNC(u16, s16, 8,
-      register uint16x8_t v32767 asm ("q4") = vmovq_n_u16(0x7FFF);,
- {
-@@ -555,7 +555,7 @@ CVT_FUNC(u16, s16, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVT_FUNC(u16, s32, 8,
-      register uint16x8_t zero0 asm ("q1") = vmovq_n_u16(0);,
- {
-@@ -589,7 +589,7 @@ CVT_FUNC(u16, s32, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(u16, f32, 8,
- ,
- {
-@@ -633,7 +633,7 @@ CVT_FUNC(u16, f32, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(s16, u8, 16,
- ,
- {
-@@ -672,7 +672,7 @@ CVT_FUNC(s16, u8, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(s16, s8, 16,
- ,
- {
-@@ -711,7 +711,7 @@ CVT_FUNC(s16, s8, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVT_FUNC(s16, u16, 8,
-      register int16x8_t vZero asm ("q4") = vmovq_n_s16(0);,
- {
-@@ -747,7 +747,7 @@ CVT_FUNC(s16, u16, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(s16, s32, 8,
- ,
- {
-@@ -786,7 +786,7 @@ CVT_FUNC(s16, s32, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(s16, f32, 8,
- ,
- {
-@@ -829,7 +829,7 @@ CVT_FUNC(s16, f32, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(s32, u8, 8,
- ,
- {
-@@ -870,7 +870,7 @@ CVT_FUNC(s32, u8, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(s32, s8, 8,
- ,
- {
-@@ -911,7 +911,7 @@ CVT_FUNC(s32, s8, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(s32, u16, 8,
- ,
- {
-@@ -950,7 +950,7 @@ CVT_FUNC(s32, u16, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(s32, s16, 8,
- ,
- {
-@@ -989,7 +989,7 @@ CVT_FUNC(s32, s16, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(s32, f32, 8,
- ,
- {
-@@ -1034,7 +1034,7 @@ CVT_FUNC(s32, f32, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(f32, u8, 8,
-     register float32x4_t vmult asm ("q0") = vdupq_n_f32((float)(1 << 16));
-     register uint32x4_t  vmask asm ("q1") = vdupq_n_u32(1<<16);,
-@@ -1101,7 +1101,7 @@ CVT_FUNC(f32, u8, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(f32, s8, 8,
-      register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);,
- {
-@@ -1153,7 +1153,7 @@ CVT_FUNC(f32, s8, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(f32, u16, 8,
-      register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);,
- {
-@@ -1212,7 +1212,7 @@ CVT_FUNC(f32, u16, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(f32, s16, 8,
-      register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);,
- {
-@@ -1271,7 +1271,7 @@ CVT_FUNC(f32, s16, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
- CVT_FUNC(f32, s32, 8,
-      register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);,
- {
-diff --git a/3rdparty/carotene/src/convert_scale.cpp b/3rdparty/carotene/src/convert_scale.cpp
-index ae41a985c8..d599d24c1e 100644
---- a/3rdparty/carotene/src/convert_scale.cpp
-+++ b/3rdparty/carotene/src/convert_scale.cpp
-@@ -473,7 +473,7 @@ CVTS_FUNC(u8, s16, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(u8, s32, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -562,7 +562,7 @@ CVTS_FUNC(u8, s32, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(u8, f32, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);,
-@@ -985,7 +985,7 @@ CVTS_FUNC(s8, s16, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(s8, s32, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1074,7 +1074,7 @@ CVTS_FUNC(s8, s32, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(s8, f32, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);,
-@@ -1155,7 +1155,7 @@ CVTS_FUNC(s8, f32, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(u16, u8, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1214,7 +1214,7 @@ CVTS_FUNC(u16, u8, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(u16, s8, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1273,7 +1273,7 @@ CVTS_FUNC(u16, s8, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC1(u16, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1330,7 +1330,7 @@ CVTS_FUNC1(u16, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(u16, s16, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1387,7 +1387,7 @@ CVTS_FUNC(u16, s16, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(u16, s32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1443,7 +1443,7 @@ CVTS_FUNC(u16, s32, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(u16, f32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);,
-@@ -1495,7 +1495,7 @@ CVTS_FUNC(u16, f32, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(s16, u8, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1554,7 +1554,7 @@ CVTS_FUNC(s16, u8, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(s16, s8, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1613,7 +1613,7 @@ CVTS_FUNC(s16, s8, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(s16, u16, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1670,7 +1670,7 @@ CVTS_FUNC(s16, u16, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC1(s16, 16,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1727,7 +1727,7 @@ CVTS_FUNC1(s16, 16,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(s16, s32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1783,7 +1783,7 @@ CVTS_FUNC(s16, s32, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(s16, f32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);,
-@@ -1835,7 +1835,7 @@ CVTS_FUNC(s16, f32, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(s32, u8, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1893,7 +1893,7 @@ CVTS_FUNC(s32, u8, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(s32, s8, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -1951,7 +1951,7 @@ CVTS_FUNC(s32, s8, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(s32, u16, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -2007,7 +2007,7 @@ CVTS_FUNC(s32, u16, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(s32, s16, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -2063,7 +2063,7 @@ CVTS_FUNC(s32, s16, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC1(s32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -2118,7 +2118,7 @@ CVTS_FUNC1(s32, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(s32, f32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);,
-@@ -2169,7 +2169,7 @@ CVTS_FUNC(s32, f32, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(f32, u8, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)((1 << 16)*alpha));
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)((1 << 16)*beta));
-@@ -2239,7 +2239,7 @@ CVTS_FUNC(f32, u8, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(f32, s8, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -2293,7 +2293,7 @@ CVTS_FUNC(f32, s8, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(f32, u16, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -2345,7 +2345,7 @@ CVTS_FUNC(f32, u16, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(f32, s16, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -2397,7 +2397,7 @@ CVTS_FUNC(f32, s16, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC(f32, s32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);,
-@@ -2448,7 +2448,7 @@ CVTS_FUNC(f32, s32, 8,
- })
- #endif
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
- CVTS_FUNC1(f32, 8,
-     register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha);
-     register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);,
-diff --git a/3rdparty/carotene/src/gaussian_blur.cpp b/3rdparty/carotene/src/gaussian_blur.cpp
-index f7b5f18d79..e5aa8fc75b 100644
---- a/3rdparty/carotene/src/gaussian_blur.cpp
-+++ b/3rdparty/carotene/src/gaussian_blur.cpp
-@@ -327,7 +327,7 @@ void gaussianBlur5x5(const Size2D &size, s32 cn,
-                 u16* lidx1 = lane + x - 1*2;
-                 u16* lidx3 = lane + x + 1*2;
-                 u16* lidx4 = lane + x + 2*2;
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-                 __asm__ __volatile__ (
-                     "vld2.16 {d0, d2}, [%[in0]]!                              \n\t"
-                     "vld2.16 {d1, d3}, [%[in0]]                               \n\t"
-diff --git a/3rdparty/carotene/src/pyramid.cpp b/3rdparty/carotene/src/pyramid.cpp
-index 232ccf3efd..d4e32ea50f 100644
---- a/3rdparty/carotene/src/pyramid.cpp
-+++ b/3rdparty/carotene/src/pyramid.cpp
-@@ -331,7 +331,7 @@ void gaussianPyramidDown(const Size2D &srcSize,
-             for (; x < roiw8; x += 8)
-             {
-                 internal::prefetch(lane + 2 * x);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-                 __asm__ (
-                     "vld2.16 {d0-d3}, [%[in0]]                               \n\t"
-                     "vld2.16 {d4-d7}, [%[in4]]                               \n\t"
-@@ -538,7 +538,7 @@ void gaussianPyramidDown(const Size2D &srcSize,
-             for (; x < roiw4; x += 4)
-             {
-                 internal::prefetch(lane + 2 * x);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-                 __asm__ (
-                     "vld2.32 {d0-d3}, [%[in0]]                              \n\t"
-                     "vld2.32 {d4-d7}, [%[in4]]                              \n\t"
-@@ -672,7 +672,7 @@ void gaussianPyramidDown(const Size2D &srcSize,
-     std::vector<f32> _buf(cn*(srcSize.width + 4) + 32/sizeof(f32));
-     f32* lane = internal::alignPtr(&_buf[2*cn], 32);
- 
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-     register float32x4_t vc6d4f32  asm ("q11") = vmovq_n_f32(1.5f);  // 6/4
-     register float32x4_t vc1d4f32  asm ("q12") = vmovq_n_f32(0.25f); // 1/4
- 
-@@ -739,7 +739,7 @@ void gaussianPyramidDown(const Size2D &srcSize,
-             for (; x < roiw4; x += 4)
-             {
-                 internal::prefetch(lane + 2 * x);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-                 __asm__ __volatile__ (
-                     "vld2.32 {d0-d3}, [%[in0]]                              \n\t"
-                     "vld2.32 {d8-d11}, [%[in4]]                             \n\t"
-diff --git a/3rdparty/carotene/src/scharr.cpp b/3rdparty/carotene/src/scharr.cpp
-index 8d3b6328b1..36f6b2276e 100644
---- a/3rdparty/carotene/src/scharr.cpp
-+++ b/3rdparty/carotene/src/scharr.cpp
-@@ -109,7 +109,7 @@ void ScharrDeriv(const Size2D &size, s32 cn,
-             internal::prefetch(srow0 + x);
-             internal::prefetch(srow1 + x);
-             internal::prefetch(srow2 + x);
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 7 && !defined(__clang__)
-             __asm__ (
-                 "vld1.8 {d0}, [%[src0]]                                \n\t"
-                 "vld1.8 {d2}, [%[src2]]                                \n\t"
-@@ -161,7 +161,7 @@ void ScharrDeriv(const Size2D &size, s32 cn,
-         x = 0;
-         for( ; x < roiw8; x += 8 )
-         {
--#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6
-+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 &&  __GNUC_MINOR__ < 6 && !defined(__clang__)
-             __asm__ (
-                 "vld1.16 {d4-d5}, [%[s2ptr]]                           \n\t"
-                 "vld1.16 {d8-d9}, [%[s4ptr]]                           \n\t"
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0002-imgcodecs-refactoring-improve-code-quality.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0002-imgcodecs-refactoring-improve-code-quality.patch
deleted file mode 100644
index 39f33af..0000000
--- a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0002-imgcodecs-refactoring-improve-code-quality.patch
+++ /dev/null
@@ -1,656 +0,0 @@
-Upstream-Status: Backport [https://github.com/opencv/opencv/pull/9376/commits/999f41fb4f4aa94a0cb47256919ae8b5c29ca5f3]
-
-Fix CVEs for opencv 3.3:
-
-* CVE-2017-12597
-* CVE-2017-12598
-* CVE-2017-12599
-* CVE-2017-12600
-* CVE-2017-12601
-* CVE-2017-12602
-* CVE-2017-12603
-* CVE-2017-12604
-* CVE-2017-12605
-* CVE-2017-12606
-* CVE-2017-12862
-* CVE-2017-12863
-* CVE-2017-12864
-
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
----
-From 999f41fb4f4aa94a0cb47256919ae8b5c29ca5f3 Mon Sep 17 00:00:00 2001
-From: Alexander Alekhin <alexander.a.alekhin@gmail.com>
-Date: Tue, 15 Aug 2017 22:04:55 +0000
-Subject: [PATCH 2/3] imgcodecs: refactoring, improve code quality
-
----
- modules/imgcodecs/src/bitstrm.cpp   |   2 +
- modules/imgcodecs/src/bitstrm.hpp   |  19 +++--
- modules/imgcodecs/src/grfmt_bmp.cpp |  13 ++-
- modules/imgcodecs/src/grfmt_pxm.cpp | 122 ++++++++++++++++-----------
- modules/imgcodecs/src/loadsave.cpp  | 164 +++++++++++++++++++++++++++++-------
- 5 files changed, 231 insertions(+), 89 deletions(-)
-
-diff --git a/modules/imgcodecs/src/bitstrm.cpp b/modules/imgcodecs/src/bitstrm.cpp
-index a7e187fa0..0a8941aec 100644
---- a/modules/imgcodecs/src/bitstrm.cpp
-+++ b/modules/imgcodecs/src/bitstrm.cpp
-@@ -209,6 +209,8 @@ int  RLByteStream::getByte()
-         current = m_current;
-     }
- 
-+    CV_Assert(current < m_end);
-+
-     val = *((uchar*)current);
-     m_current = current + 1;
-     return val;
-diff --git a/modules/imgcodecs/src/bitstrm.hpp b/modules/imgcodecs/src/bitstrm.hpp
-index 465c0a847..26947971f 100644
---- a/modules/imgcodecs/src/bitstrm.hpp
-+++ b/modules/imgcodecs/src/bitstrm.hpp
-@@ -48,13 +48,20 @@
- namespace cv
- {
- 
--enum
--{
--    RBS_THROW_EOS=-123,  // <end of stream> exception code
--    RBS_THROW_FORB=-124,  // <forrbidden huffman code> exception code
--    RBS_HUFF_FORB=2047,  // forrbidden huffman code "value"
--    RBS_BAD_HEADER=-125 // invalid header
-+#define DECLARE_RBS_EXCEPTION(name) \
-+class RBS_ ## name ## _Exception : public cv::Exception \
-+{ \
-+public: \
-+    RBS_ ## name ## _Exception(int code_, const String& err_, const String& func_, const String& file_, int line_) : \
-+        cv::Exception(code_, err_, func_, file_, line_) \
-+    {} \
- };
-+DECLARE_RBS_EXCEPTION(THROW_EOS)
-+#define RBS_THROW_EOS RBS_THROW_EOS_Exception(cv::Error::StsError, "Unexpected end of input stream", CV_Func, __FILE__, __LINE__)
-+DECLARE_RBS_EXCEPTION(THROW_FORB)
-+#define RBS_THROW_FORB RBS_THROW_FORB_Exception(cv::Error::StsError, "Forrbidden huffman code", CV_Func, __FILE__, __LINE__)
-+DECLARE_RBS_EXCEPTION(BAD_HEADER)
-+#define RBS_BAD_HEADER RBS_BAD_HEADER_Exception(cv::Error::StsError, "Invalid header", CV_Func, __FILE__, __LINE__)
- 
- typedef unsigned long ulong;
- 
-diff --git a/modules/imgcodecs/src/grfmt_bmp.cpp b/modules/imgcodecs/src/grfmt_bmp.cpp
-index 86cacd316..257f97c2d 100644
---- a/modules/imgcodecs/src/grfmt_bmp.cpp
-+++ b/modules/imgcodecs/src/grfmt_bmp.cpp
-@@ -118,8 +118,9 @@ bool  BmpDecoder::readHeader()
- 
-                 if( m_bpp <= 8 )
-                 {
--                    memset( m_palette, 0, sizeof(m_palette));
--                    m_strm.getBytes( m_palette, (clrused == 0? 1<<m_bpp : clrused)*4 );
-+                    CV_Assert(clrused < 256);
-+                    memset(m_palette, 0, sizeof(m_palette));
-+                    m_strm.getBytes(m_palette, (clrused == 0? 1<<m_bpp : clrused)*4 );
-                     iscolor = IsColorPalette( m_palette, m_bpp );
-                 }
-                 else if( m_bpp == 16 && m_rle_code == BMP_BITFIELDS )
-@@ -290,7 +291,9 @@ bool  BmpDecoder::readData( Mat& img )
-                     else if( code > 2 ) // absolute mode
-                     {
-                         if( data + code*nch > line_end ) goto decode_rle4_bad;
--                        m_strm.getBytes( src, (((code + 1)>>1) + 1) & -2 );
-+                        int sz = (((code + 1)>>1) + 1) & (~1);
-+                        CV_Assert((size_t)sz < _src.size());
-+                        m_strm.getBytes(src, sz);
-                         if( color )
-                             data = FillColorRow4( data, src, code, m_palette );
-                         else
-@@ -379,7 +382,9 @@ decode_rle4_bad: ;
- 
-                         if( data + code3 > line_end )
-                             goto decode_rle8_bad;
--                        m_strm.getBytes( src, (code + 1) & -2 );
-+                        int sz = (code + 1) & (~1);
-+                        CV_Assert((size_t)sz < _src.size());
-+                        m_strm.getBytes(src, sz);
-                         if( color )
-                             data = FillColorRow8( data, src, code, m_palette );
-                         else
-diff --git a/modules/imgcodecs/src/grfmt_pxm.cpp b/modules/imgcodecs/src/grfmt_pxm.cpp
-index 1750cb705..68bd8fd93 100644
---- a/modules/imgcodecs/src/grfmt_pxm.cpp
-+++ b/modules/imgcodecs/src/grfmt_pxm.cpp
-@@ -43,50 +43,58 @@
- #include "precomp.hpp"
- #include "utils.hpp"
- #include "grfmt_pxm.hpp"
-+#include <iostream>
- 
- namespace cv
- {
- 
- ///////////////////////// P?M reader //////////////////////////////
- 
--static int ReadNumber( RLByteStream& strm, int maxdigits )
-+static int ReadNumber(RLByteStream& strm, int maxdigits = 0)
- {
-     int code;
--    int val = 0;
-+    int64 val = 0;
-     int digits = 0;
- 
-     code = strm.getByte();
- 
--    if( !isdigit(code))
-+    while (!isdigit(code))
-     {
--        do
-+        if (code == '#' )
-         {
--            if( code == '#' )
-+            do
-             {
--                do
--                {
--                    code = strm.getByte();
--                }
--                while( code != '\n' && code != '\r' );
-+                code = strm.getByte();
-             }
--
-+            while (code != '\n' && code != '\r');
-             code = strm.getByte();
--
--            while( isspace(code))
-+        }
-+        else if (isspace(code))
-+        {
-+            while (isspace(code))
-                 code = strm.getByte();
-         }
--        while( !isdigit( code ));
-+        else
-+        {
-+#if 1
-+            CV_ErrorNoReturn_(Error::StsError, ("PXM: Unexpected code in ReadNumber(): 0x%x (%d)", code, code));
-+#else
-+            code = strm.getByte();
-+#endif
-+        }
-     }
- 
-     do
-     {
--        val = val*10 + code - '0';
--        if( ++digits >= maxdigits ) break;
-+        val = val*10 + (code - '0');
-+        CV_Assert(val <= INT_MAX && "PXM: ReadNumber(): result is too large");
-+        digits++;
-+        if (maxdigits != 0 && digits >= maxdigits) break;
-         code = strm.getByte();
-     }
--    while( isdigit(code));
-+    while (isdigit(code));
- 
--    return val;
-+    return (int)val;
- }
- 
- 
-@@ -122,13 +130,13 @@ ImageDecoder PxMDecoder::newDecoder() const
-     return makePtr<PxMDecoder>();
- }
- 
--void  PxMDecoder::close()
-+void PxMDecoder::close()
- {
-     m_strm.close();
- }
- 
- 
--bool  PxMDecoder::readHeader()
-+bool PxMDecoder::readHeader()
- {
-     bool result = false;
- 
-@@ -158,10 +166,10 @@ bool  PxMDecoder::readHeader()
-         m_binary = code >= '4';
-         m_type = m_bpp > 8 ? CV_8UC3 : CV_8UC1;
- 
--        m_width = ReadNumber( m_strm, INT_MAX );
--        m_height = ReadNumber( m_strm, INT_MAX );
-+        m_width = ReadNumber(m_strm);
-+        m_height = ReadNumber(m_strm);
- 
--        m_maxval = m_bpp == 1 ? 1 : ReadNumber( m_strm, INT_MAX );
-+        m_maxval = m_bpp == 1 ? 1 : ReadNumber(m_strm);
-         if( m_maxval > 65535 )
-             throw RBS_BAD_HEADER;
- 
-@@ -175,8 +183,14 @@ bool  PxMDecoder::readHeader()
-             result = true;
-         }
-     }
--    catch(...)
-+    catch (const cv::Exception&)
-+    {
-+        throw;
-+    }
-+    catch (...)
-     {
-+        std::cerr << "PXM::readHeader(): unknown C++ exception" << std::endl << std::flush;
-+        throw;
-     }
- 
-     if( !result )
-@@ -189,33 +203,28 @@ bool  PxMDecoder::readHeader()
- }
- 
- 
--bool  PxMDecoder::readData( Mat& img )
-+bool PxMDecoder::readData( Mat& img )
- {
-     int color = img.channels() > 1;
-     uchar* data = img.ptr();
-     PaletteEntry palette[256];
-     bool   result = false;
--    int  bit_depth = CV_ELEM_SIZE1(m_type)*8;
--    int  src_pitch = (m_width*m_bpp*bit_depth/8 + 7)/8;
-+    const int bit_depth = CV_ELEM_SIZE1(m_type)*8;
-+    const int src_pitch = divUp(m_width*m_bpp*(bit_depth/8), 8);
-     int  nch = CV_MAT_CN(m_type);
-     int  width3 = m_width*nch;
--    int  i, x, y;
- 
-     if( m_offset < 0 || !m_strm.isOpened())
-         return false;
- 
--    AutoBuffer<uchar> _src(src_pitch + 32);
--    uchar* src = _src;
--    AutoBuffer<uchar> _gray_palette;
--    uchar* gray_palette = _gray_palette;
-+    uchar gray_palette[256] = {0};
- 
-     // create LUT for converting colors
-     if( bit_depth == 8 )
-     {
--        _gray_palette.allocate(m_maxval + 1);
--        gray_palette = _gray_palette;
-+        CV_Assert(m_maxval < 256);
- 
--        for( i = 0; i <= m_maxval; i++ )
-+        for (int i = 0; i <= m_maxval; i++)
-             gray_palette[i] = (uchar)((i*255/m_maxval)^(m_bpp == 1 ? 255 : 0));
- 
-         FillGrayPalette( palette, m_bpp==1 ? 1 : 8 , m_bpp == 1 );
-@@ -229,12 +238,16 @@ bool  PxMDecoder::readData( Mat& img )
-         {
-         ////////////////////////// 1 BPP /////////////////////////
-         case 1:
-+            CV_Assert(CV_MAT_DEPTH(m_type) == CV_8U);
-             if( !m_binary )
-             {
--                for( y = 0; y < m_height; y++, data += img.step )
-+                AutoBuffer<uchar> _src(m_width);
-+                uchar* src = _src;
-+
-+                for (int y = 0; y < m_height; y++, data += img.step)
-                 {
--                    for( x = 0; x < m_width; x++ )
--                        src[x] = ReadNumber( m_strm, 1 ) != 0;
-+                    for (int x = 0; x < m_width; x++)
-+                        src[x] = ReadNumber(m_strm, 1) != 0;
- 
-                     if( color )
-                         FillColorRow8( data, src, m_width, palette );
-@@ -244,7 +257,10 @@ bool  PxMDecoder::readData( Mat& img )
-             }
-             else
-             {
--                for( y = 0; y < m_height; y++, data += img.step )
-+                AutoBuffer<uchar> _src(src_pitch);
-+                uchar* src = _src;
-+
-+                for (int y = 0; y < m_height; y++, data += img.step)
-                 {
-                     m_strm.getBytes( src, src_pitch );
- 
-@@ -260,13 +276,17 @@ bool  PxMDecoder::readData( Mat& img )
-         ////////////////////////// 8 BPP /////////////////////////
-         case 8:
-         case 24:
--            for( y = 0; y < m_height; y++, data += img.step )
-+        {
-+            AutoBuffer<uchar> _src(std::max<size_t>(width3*2, src_pitch));
-+            uchar* src = _src;
-+
-+            for (int y = 0; y < m_height; y++, data += img.step)
-             {
-                 if( !m_binary )
-                 {
--                    for( x = 0; x < width3; x++ )
-+                    for (int x = 0; x < width3; x++)
-                     {
--                        int code = ReadNumber( m_strm, INT_MAX );
-+                        int code = ReadNumber(m_strm);
-                         if( (unsigned)code > (unsigned)m_maxval ) code = m_maxval;
-                         if( bit_depth == 8 )
-                             src[x] = gray_palette[code];
-@@ -279,7 +299,7 @@ bool  PxMDecoder::readData( Mat& img )
-                     m_strm.getBytes( src, src_pitch );
-                     if( bit_depth == 16 && !isBigEndian() )
-                     {
--                        for( x = 0; x < width3; x++ )
-+                        for (int x = 0; x < width3; x++)
-                         {
-                             uchar v = src[x * 2];
-                             src[x * 2] = src[x * 2 + 1];
-@@ -290,7 +310,7 @@ bool  PxMDecoder::readData( Mat& img )
- 
-                 if( img.depth() == CV_8U && bit_depth == 16 )
-                 {
--                    for( x = 0; x < width3; x++ )
-+                    for (int x = 0; x < width3; x++)
-                     {
-                         int v = ((ushort *)src)[x];
-                         src[x] = (uchar)(v >> 8);
-@@ -331,12 +351,19 @@ bool  PxMDecoder::readData( Mat& img )
-             }
-             result = true;
-             break;
-+        }
-         default:
--            assert(0);
-+            CV_ErrorNoReturn(Error::StsError, "m_bpp is not supported");
-         }
-     }
--    catch(...)
-+    catch (const cv::Exception&)
-+    {
-+        throw;
-+    }
-+    catch (...)
-     {
-+        std::cerr << "PXM::readData(): unknown exception" << std::endl << std::flush;
-+        throw;
-     }
- 
-     return result;
-@@ -412,8 +439,9 @@ bool  PxMEncoder::write( const Mat& img, const std::vector<int>& params )
-     char* buffer = _buffer;
- 
-     // write header;
--    sprintf( buffer, "P%c\n%d %d\n%d\n",
-+    sprintf( buffer, "P%c\n# Generated by OpenCV %s\n%d %d\n%d\n",
-              '2' + (channels > 1 ? 1 : 0) + (isBinary ? 3 : 0),
-+             CV_VERSION,
-              width, height, (1 << depth) - 1 );
- 
-     strm.putBytes( buffer, (int)strlen(buffer) );
-diff --git a/modules/imgcodecs/src/loadsave.cpp b/modules/imgcodecs/src/loadsave.cpp
-index 3b2366217..5ee4ca354 100644
---- a/modules/imgcodecs/src/loadsave.cpp
-+++ b/modules/imgcodecs/src/loadsave.cpp
-@@ -55,6 +55,27 @@
- /****************************************************************************************\
- *                                      Image Codecs                                      *
- \****************************************************************************************/
-+
-+namespace cv {
-+
-+// TODO Add runtime configuration
-+#define CV_IO_MAX_IMAGE_PARAMS (50)
-+#define CV_IO_MAX_IMAGE_WIDTH (1<<20)
-+#define CV_IO_MAX_IMAGE_HEIGHT (1<<20)
-+#define CV_IO_MAX_IMAGE_PIXELS (1<<30) // 1 Gigapixel
-+
-+static Size validateInputImageSize(const Size& size)
-+{
-+    CV_Assert(size.width > 0);
-+    CV_Assert(size.width <= CV_IO_MAX_IMAGE_WIDTH);
-+    CV_Assert(size.height > 0);
-+    CV_Assert(size.height <= CV_IO_MAX_IMAGE_HEIGHT);
-+    uint64 pixels = (uint64)size.width * (uint64)size.height;
-+    CV_Assert(pixels <= CV_IO_MAX_IMAGE_PIXELS);
-+    return size;
-+}
-+
-+
- namespace {
- 
- class ByteStreamBuffer: public std::streambuf
-@@ -94,9 +115,6 @@ protected:
- 
- }
- 
--namespace cv
--{
--
- /**
-  * @struct ImageCodecInitializer
-  *
-@@ -408,14 +426,26 @@ imread_( const String& filename, int flags, int hdrtype, Mat* mat=0 )
-     /// set the filename in the driver
-     decoder->setSource( filename );
- 
--   // read the header to make sure it succeeds
--   if( !decoder->readHeader() )
-+    try
-+    {
-+        // read the header to make sure it succeeds
-+        if( !decoder->readHeader() )
-+            return 0;
-+    }
-+    catch (const cv::Exception& e)
-+    {
-+        std::cerr << "imread_('" << filename << "'): can't read header: " << e.what() << std::endl << std::flush;
-         return 0;
-+    }
-+    catch (...)
-+    {
-+        std::cerr << "imread_('" << filename << "'): can't read header: unknown exception" << std::endl << std::flush;
-+        return 0;
-+    }
-+
- 
-     // established the required input image size
--    CvSize size;
--    size.width = decoder->width();
--    size.height = decoder->height();
-+    Size size = validateInputImageSize(Size(decoder->width(), decoder->height()));
- 
-     // grab the decoded type
-     int type = decoder->type();
-@@ -451,7 +481,21 @@ imread_( const String& filename, int flags, int hdrtype, Mat* mat=0 )
-     }
- 
-     // read the image data
--    if( !decoder->readData( *data ))
-+    bool success = false;
-+    try
-+    {
-+        if (decoder->readData(*data))
-+            success = true;
-+    }
-+    catch (const cv::Exception& e)
-+    {
-+        std::cerr << "imread_('" << filename << "'): can't read data: " << e.what() << std::endl << std::flush;
-+    }
-+    catch (...)
-+    {
-+        std::cerr << "imread_('" << filename << "'): can't read data: unknown exception" << std::endl << std::flush;
-+    }
-+    if (!success)
-     {
-         cvReleaseImage( &image );
-         cvReleaseMat( &matrix );
-@@ -504,8 +548,22 @@ imreadmulti_(const String& filename, int flags, std::vector<Mat>& mats)
-     decoder->setSource(filename);
- 
-     // read the header to make sure it succeeds
--    if (!decoder->readHeader())
-+    try
-+    {
-+        // read the header to make sure it succeeds
-+        if( !decoder->readHeader() )
-+            return 0;
-+    }
-+    catch (const cv::Exception& e)
-+    {
-+        std::cerr << "imreadmulti_('" << filename << "'): can't read header: " << e.what() << std::endl << std::flush;
-         return 0;
-+    }
-+    catch (...)
-+    {
-+        std::cerr << "imreadmulti_('" << filename << "'): can't read header: unknown exception" << std::endl << std::flush;
-+        return 0;
-+    }
- 
-     for (;;)
-     {
-@@ -523,17 +581,32 @@ imreadmulti_(const String& filename, int flags, std::vector<Mat>& mats)
-                 type = CV_MAKETYPE(CV_MAT_DEPTH(type), 1);
-         }
- 
-+        // established the required input image size
-+        Size size = validateInputImageSize(Size(decoder->width(), decoder->height()));
-+
-         // read the image data
--        Mat mat(decoder->height(), decoder->width(), type);
--        if (!decoder->readData(mat))
-+        Mat mat(size.height, size.width, type);
-+        bool success = false;
-+        try
-         {
--            // optionally rotate the data if EXIF' orientation flag says so
--            if( (flags & IMREAD_IGNORE_ORIENTATION) == 0 && flags != IMREAD_UNCHANGED )
--            {
--                ApplyExifOrientation(filename, mat);
--            }
--
-+            if (decoder->readData(mat))
-+                success = true;
-+        }
-+        catch (const cv::Exception& e)
-+        {
-+            std::cerr << "imreadmulti_('" << filename << "'): can't read data: " << e.what() << std::endl << std::flush;
-+        }
-+        catch (...)
-+        {
-+            std::cerr << "imreadmulti_('" << filename << "'): can't read data: unknown exception" << std::endl << std::flush;
-+        }
-+        if (!success)
-             break;
-+
-+        // optionally rotate the data if EXIF' orientation flag says so
-+        if( (flags & IMREAD_IGNORE_ORIENTATION) == 0 && flags != IMREAD_UNCHANGED )
-+        {
-+            ApplyExifOrientation(filename, mat);
-         }
- 
-         mats.push_back(mat);
-@@ -616,6 +689,7 @@ static bool imwrite_( const String& filename, const Mat& image,
-     }
- 
-     encoder->setDestination( filename );
-+    CV_Assert(params.size() <= CV_IO_MAX_IMAGE_PARAMS*2);
-     bool code = encoder->write( *pimage, params );
- 
-     //    CV_Assert( code );
-@@ -663,22 +737,35 @@ imdecode_( const Mat& buf, int flags, int hdrtype, Mat* mat=0 )
-         decoder->setSource(filename);
-     }
- 
--    if( !decoder->readHeader() )
-+    bool success = false;
-+    try
-+    {
-+        if (decoder->readHeader())
-+            success = true;
-+    }
-+    catch (const cv::Exception& e)
-+    {
-+        std::cerr << "imdecode_('" << filename << "'): can't read header: " << e.what() << std::endl << std::flush;
-+    }
-+    catch (...)
-+    {
-+        std::cerr << "imdecode_('" << filename << "'): can't read header: unknown exception" << std::endl << std::flush;
-+    }
-+    if (!success)
-     {
-         decoder.release();
--        if ( !filename.empty() )
-+        if (!filename.empty())
-         {
--            if ( remove(filename.c_str()) != 0 )
-+            if (0 != remove(filename.c_str()))
-             {
--                CV_Error( CV_StsError, "unable to remove temporary file" );
-+                std::cerr << "unable to remove temporary file:" << filename << std::endl << std::flush;
-             }
-         }
-         return 0;
-     }
- 
--    CvSize size;
--    size.width = decoder->width();
--    size.height = decoder->height();
-+    // established the required input image size
-+    Size size = validateInputImageSize(Size(decoder->width(), decoder->height()));
- 
-     int type = decoder->type();
-     if( (flags & IMREAD_LOAD_GDAL) != IMREAD_LOAD_GDAL && flags != IMREAD_UNCHANGED )
-@@ -712,17 +799,30 @@ imdecode_( const Mat& buf, int flags, int hdrtype, Mat* mat=0 )
-         temp = cvarrToMat(image);
-     }
- 
--    bool code = decoder->readData( *data );
-+    success = false;
-+    try
-+    {
-+        if (decoder->readData(*data))
-+            success = true;
-+    }
-+    catch (const cv::Exception& e)
-+    {
-+        std::cerr << "imdecode_('" << filename << "'): can't read data: " << e.what() << std::endl << std::flush;
-+    }
-+    catch (...)
-+    {
-+        std::cerr << "imdecode_('" << filename << "'): can't read data: unknown exception" << std::endl << std::flush;
-+    }
-     decoder.release();
--    if ( !filename.empty() )
-+    if (!filename.empty())
-     {
--        if ( remove(filename.c_str()) != 0 )
-+        if (0 != remove(filename.c_str()))
-         {
--            CV_Error( CV_StsError, "unable to remove temporary file" );
-+            std::cerr << "unable to remove temporary file:" << filename << std::endl << std::flush;
-         }
-     }
- 
--    if( !code )
-+    if (!success)
-     {
-         cvReleaseImage( &image );
-         cvReleaseMat( &matrix );
-@@ -859,7 +959,7 @@ cvSaveImage( const char* filename, const CvArr* arr, const int* _params )
-     if( _params )
-     {
-         for( ; _params[i] > 0; i += 2 )
--            ;
-+            CV_Assert(i < CV_IO_MAX_IMAGE_PARAMS*2); // Limit number of params for security reasons
-     }
-     return cv::imwrite_(filename, cv::cvarrToMat(arr),
-         i > 0 ? std::vector<int>(_params, _params+i) : std::vector<int>(),
-@@ -890,7 +990,7 @@ cvEncodeImage( const char* ext, const CvArr* arr, const int* _params )
-     if( _params )
-     {
-         for( ; _params[i] > 0; i += 2 )
--            ;
-+            CV_Assert(i < CV_IO_MAX_IMAGE_PARAMS*2); // Limit number of params for security reasons
-     }
-     cv::Mat img = cv::cvarrToMat(arr);
-     if( CV_IS_IMAGE(arr) && ((const IplImage*)arr)->origin == IPL_ORIGIN_BL )
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0003-To-fix-errors-as-following.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0003-To-fix-errors-as-following.patch
index a22b04a..5270b8c 100644
--- a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0003-To-fix-errors-as-following.patch
+++ b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0003-To-fix-errors-as-following.patch
@@ -19,29 +19,21 @@
  modules/ts/include/opencv2/ts/ts_ext.hpp   | 2 +-
  3 files changed, 5 insertions(+), 5 deletions(-)
 
-diff --git a/modules/ts/include/opencv2/ts.hpp b/modules/ts/include/opencv2/ts.hpp
-index 41a76b13e..205646140 100644
---- a/modules/ts/include/opencv2/ts.hpp
-+++ b/modules/ts/include/opencv2/ts.hpp
-@@ -555,7 +555,7 @@ protected:
+Index: git/modules/ts/include/opencv2/ts.hpp
+===================================================================
+--- git.orig/modules/ts/include/opencv2/ts.hpp
++++ git/modules/ts/include/opencv2/ts.hpp
+@@ -608,7 +608,7 @@ protected:
      }
  };
  
 -extern uint64 param_seed;
 +CV_EXPORTS extern uint64 param_seed;
  
- struct CV_EXPORTS DefaultRngAuto
+ struct DefaultRngAuto
  {
-@@ -611,14 +611,14 @@ CV_EXPORTS std::string findDataFile(const std::string& relative_path, bool requi
- 
- #ifdef HAVE_OPENCL
- namespace ocl {
--void dumpOpenCLDevice();
-+CV_EXPORTS void dumpOpenCLDevice();
- }
- #define TEST_DUMP_OCL_INFO cvtest::ocl::dumpOpenCLDevice();
- #else
- #define TEST_DUMP_OCL_INFO
+@@ -671,7 +671,7 @@ private:
+ #endif
  #endif
  
 -void parseCustomOptions(int argc, char **argv);
@@ -49,10 +41,10 @@
  
  #define CV_TEST_INIT0_NOOP (void)0
  
-diff --git a/modules/ts/include/opencv2/ts/ocl_test.hpp b/modules/ts/include/opencv2/ts/ocl_test.hpp
-index 54b33ece8..ef56bf9ef 100644
---- a/modules/ts/include/opencv2/ts/ocl_test.hpp
-+++ b/modules/ts/include/opencv2/ts/ocl_test.hpp
+Index: git/modules/ts/include/opencv2/ts/ocl_test.hpp
+===================================================================
+--- git.orig/modules/ts/include/opencv2/ts/ocl_test.hpp
++++ git/modules/ts/include/opencv2/ts/ocl_test.hpp
 @@ -82,7 +82,7 @@ inline UMat ToUMat(InputArray src)
      return dst;
  }
@@ -62,19 +54,16 @@
  
  #define MAX_VALUE 357
  
-diff --git a/modules/ts/include/opencv2/ts/ts_ext.hpp b/modules/ts/include/opencv2/ts/ts_ext.hpp
-index 0bdd346dd..2cd34dfce 100644
---- a/modules/ts/include/opencv2/ts/ts_ext.hpp
-+++ b/modules/ts/include/opencv2/ts/ts_ext.hpp
+Index: git/modules/ts/include/opencv2/ts/ts_ext.hpp
+===================================================================
+--- git.orig/modules/ts/include/opencv2/ts/ts_ext.hpp
++++ git/modules/ts/include/opencv2/ts/ts_ext.hpp
 @@ -9,7 +9,7 @@
  #define OPENCV_TS_EXT_HPP
  
  namespace cvtest {
 -void checkIppStatus();
 +CV_EXPORTS void checkIppStatus();
- }
- 
- #define CV_TEST_INIT \
--- 
-2.13.4
-
+ extern bool skipUnstableTests;
+ extern bool runBigDataTests;
+ extern int testThreads;
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0003-imgproc-test-add-checks-for-remove-call.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0003-imgproc-test-add-checks-for-remove-call.patch
deleted file mode 100644
index 5f4a60c..0000000
--- a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/0003-imgproc-test-add-checks-for-remove-call.patch
+++ /dev/null
@@ -1,186 +0,0 @@
-Upstream-Status: Backport [https://github.com/opencv/opencv/pull/9376/commits/78a310630fb0a1f6d089576202343e672f27609d]
-
-Fix CVEs for opencv 3.3.
-
-* CVE-2017-12597
-* CVE-2017-12598
-* CVE-2017-12599
-* CVE-2017-12600
-* CVE-2017-12601
-* CVE-2017-12602
-* CVE-2017-12603
-* CVE-2017-12604
-* CVE-2017-12605
-* CVE-2017-12606
-* CVE-2017-12862
-* CVE-2017-12863
-* CVE-2017-12864
-
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
----
-From 78a310630fb0a1f6d089576202343e672f27609d Mon Sep 17 00:00:00 2001
-From: Alexander Alekhin <alexander.alekhin@intel.com>
-Date: Wed, 16 Aug 2017 13:53:12 +0300
-Subject: [PATCH 3/3] imgproc(test): add checks for remove() call
-
----
- modules/imgcodecs/test/test_grfmt.cpp      |  2 +-
- modules/imgcodecs/test/test_jpeg.cpp       | 12 ++++++------
- modules/imgcodecs/test/test_png.cpp        |  2 +-
- modules/imgcodecs/test/test_read_write.cpp |  4 ++--
- modules/imgcodecs/test/test_tiff.cpp       |  8 ++++----
- modules/imgcodecs/test/test_webp.cpp       |  6 +++---
- 6 files changed, 17 insertions(+), 17 deletions(-)
-
-diff --git a/modules/imgcodecs/test/test_grfmt.cpp b/modules/imgcodecs/test/test_grfmt.cpp
-index 64a0c1e3a..74b72c3b3 100644
---- a/modules/imgcodecs/test/test_grfmt.cpp
-+++ b/modules/imgcodecs/test/test_grfmt.cpp
-@@ -175,7 +175,7 @@ TEST_P(Imgcodecs_ExtSize, write_imageseq)
-             EXPECT_LT(n, 1.);
-             EXPECT_PRED_FORMAT2(cvtest::MatComparator(0, 0), img, img_gt);
-         }
--        remove(filename.c_str());
-+        EXPECT_EQ(0, remove(filename.c_str()));
-     }
- }
- 
-diff --git a/modules/imgcodecs/test/test_jpeg.cpp b/modules/imgcodecs/test/test_jpeg.cpp
-index 5546f2d91..6ddb02840 100644
---- a/modules/imgcodecs/test/test_jpeg.cpp
-+++ b/modules/imgcodecs/test/test_jpeg.cpp
-@@ -123,8 +123,8 @@ TEST(Imgcodecs_Jpeg, encode_decode_progressive_jpeg)
- 
-     EXPECT_EQ(0, cvtest::norm(img_jpg_progressive, img_jpg_normal, NORM_INF));
- 
--    remove(output_progressive.c_str());
--    remove(output_normal.c_str());
-+    EXPECT_EQ(0, remove(output_progressive.c_str()));
-+    EXPECT_EQ(0, remove(output_normal.c_str()));
- }
- 
- TEST(Imgcodecs_Jpeg, encode_decode_optimize_jpeg)
-@@ -148,8 +148,8 @@ TEST(Imgcodecs_Jpeg, encode_decode_optimize_jpeg)
- 
-     EXPECT_EQ(0, cvtest::norm(img_jpg_optimized, img_jpg_normal, NORM_INF));
- 
--    remove(output_optimized.c_str());
--    remove(output_normal.c_str());
-+    EXPECT_EQ(0, remove(output_optimized.c_str()));
-+    EXPECT_EQ(0, remove(output_normal.c_str()));
- }
- 
- TEST(Imgcodecs_Jpeg, encode_decode_rst_jpeg)
-@@ -173,8 +173,8 @@ TEST(Imgcodecs_Jpeg, encode_decode_rst_jpeg)
- 
-     EXPECT_EQ(0, cvtest::norm(img_jpg_rst, img_jpg_normal, NORM_INF));
- 
--    remove(output_rst.c_str());
--    remove(output_normal.c_str());
-+    EXPECT_EQ(0, remove(output_rst.c_str()));
-+    EXPECT_EQ(0, remove(output_normal.c_str()));
- }
- 
- #endif // HAVE_JPEG
-diff --git a/modules/imgcodecs/test/test_png.cpp b/modules/imgcodecs/test/test_png.cpp
-index c46f90119..4e97043e1 100644
---- a/modules/imgcodecs/test/test_png.cpp
-+++ b/modules/imgcodecs/test/test_png.cpp
-@@ -17,7 +17,7 @@ TEST(Imgcodecs_Png, write_big)
-     EXPECT_EQ(13043, img.cols);
-     EXPECT_EQ(13917, img.rows);
-     ASSERT_NO_THROW(imwrite(dst_file, img));
--    remove(dst_file.c_str());
-+    EXPECT_EQ(0, remove(dst_file.c_str()));
- }
- 
- TEST(Imgcodecs_Png, encode)
-diff --git a/modules/imgcodecs/test/test_read_write.cpp b/modules/imgcodecs/test/test_read_write.cpp
-index 38f10225f..5119813bf 100644
---- a/modules/imgcodecs/test/test_read_write.cpp
-+++ b/modules/imgcodecs/test/test_read_write.cpp
-@@ -50,7 +50,7 @@ TEST(Imgcodecs_Image, read_write_bmp)
-         psnr = cvtest::PSNR(buf_loaded, image);
-         EXPECT_GT(psnr, thresDbell);
- 
--        remove(dst_name.c_str());
-+        EXPECT_EQ(0, remove(dst_name.c_str()));
-     }
- }
- 
-@@ -95,7 +95,7 @@ TEST_P(Imgcodecs_Image, read_write)
-     psnr = cvtest::PSNR(buf_loaded, image);
-     EXPECT_GT(psnr, thresDbell);
- 
--    remove(full_name.c_str());
-+    EXPECT_EQ(0, remove(full_name.c_str()));
- }
- 
- const string exts[] = {
-diff --git a/modules/imgcodecs/test/test_tiff.cpp b/modules/imgcodecs/test/test_tiff.cpp
-index 0264da4cd..6ef0c1748 100644
---- a/modules/imgcodecs/test/test_tiff.cpp
-+++ b/modules/imgcodecs/test/test_tiff.cpp
-@@ -41,8 +41,8 @@ TEST(Imgcodecs_Tiff, decode_tile16384x16384)
-         // not enough memory
-     }
- 
--    remove(file3.c_str());
--    remove(file4.c_str());
-+    EXPECT_EQ(0, remove(file3.c_str()));
-+    EXPECT_EQ(0, remove(file4.c_str()));
- }
- 
- TEST(Imgcodecs_Tiff, write_read_16bit_big_little_endian)
-@@ -88,7 +88,7 @@ TEST(Imgcodecs_Tiff, write_read_16bit_big_little_endian)
-         EXPECT_EQ(0xDEAD, img.at<ushort>(0,0));
-         EXPECT_EQ(0xBEEF, img.at<ushort>(0,1));
- 
--        remove(filename.c_str());
-+        EXPECT_EQ(0, remove(filename.c_str()));
-     }
- }
- 
-@@ -143,7 +143,7 @@ TEST(Imgcodecs_Tiff, decode_infinite_rowsperstrip)
- 
-     EXPECT_NO_THROW(cv::imread(filename, IMREAD_UNCHANGED));
- 
--    remove(filename.c_str());
-+    EXPECT_EQ(0, remove(filename.c_str()));
- }
- 
- //==================================================================================================
-diff --git a/modules/imgcodecs/test/test_webp.cpp b/modules/imgcodecs/test/test_webp.cpp
-index 6d40ce21e..d82fdd289 100644
---- a/modules/imgcodecs/test/test_webp.cpp
-+++ b/modules/imgcodecs/test/test_webp.cpp
-@@ -44,7 +44,7 @@ TEST(Imgcodecs_WebP, encode_decode_lossless_webp)
-         }
-     }
- 
--    remove(output.c_str());
-+    EXPECT_EQ(0, remove(output.c_str()));
- 
-     cv::Mat decode = cv::imdecode(buf, IMREAD_COLOR);
-     ASSERT_FALSE(decode.empty());
-@@ -71,7 +71,7 @@ TEST(Imgcodecs_WebP, encode_decode_lossy_webp)
- 
-         EXPECT_NO_THROW(cv::imwrite(output, img, params));
-         cv::Mat img_webp = cv::imread(output);
--        remove(output.c_str());
-+        EXPECT_EQ(0, remove(output.c_str()));
-         EXPECT_FALSE(img_webp.empty());
-         EXPECT_EQ(3,   img_webp.channels());
-         EXPECT_EQ(512, img_webp.cols);
-@@ -96,7 +96,7 @@ TEST(Imgcodecs_WebP, encode_decode_with_alpha_webp)
- 
-     EXPECT_NO_THROW(cv::imwrite(output, img));
-     cv::Mat img_webp = cv::imread(output);
--    remove(output.c_str());
-+    EXPECT_EQ(0, remove(output.c_str()));
-     EXPECT_FALSE(img_webp.empty());
-     EXPECT_EQ(4,   img_webp.channels());
-     EXPECT_EQ(512, img_webp.cols);
--- 
-2.14.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/CVE-2017-14136.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/CVE-2017-14136.patch
deleted file mode 100644
index 7ad50a2..0000000
--- a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/CVE-2017-14136.patch
+++ /dev/null
@@ -1,288 +0,0 @@
-Upstream-Status: Backport [https://github.com/opencv/opencv/pull/9448/commits/aacae20]
-
-Backport patch to fix CVE-2017-14136.
-
-Ref: https://github.com/opencv/opencv/issues/9443
-
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
----
-From aacae2065744adb05e858d327198c7bbe7f452b0 Mon Sep 17 00:00:00 2001
-From: Alexander Alekhin <alexander.alekhin@intel.com>
-Date: Wed, 23 Aug 2017 15:15:27 +0300
-Subject: [PATCH] imgcodesc: fix code problems with integer overflow / address
- arithmetic / UB
-
----
- modules/imgcodecs/src/grfmt_bmp.cpp      |  8 ++---
- modules/imgcodecs/src/grfmt_exr.cpp      | 10 +++----
- modules/imgcodecs/src/grfmt_jpeg.cpp     |  2 +-
- modules/imgcodecs/src/grfmt_jpeg2000.cpp |  6 ++--
- modules/imgcodecs/src/grfmt_pam.cpp      |  2 +-
- modules/imgcodecs/src/grfmt_sunras.cpp   |  6 ++--
- modules/imgcodecs/src/utils.cpp          | 51 +++++++++++++++++++-------------
- modules/imgcodecs/src/utils.hpp          |  2 ++
- 8 files changed, 50 insertions(+), 37 deletions(-)
-
-diff --git a/modules/imgcodecs/src/grfmt_bmp.cpp b/modules/imgcodecs/src/grfmt_bmp.cpp
-index 257f97c2d8b..69768e276a3 100644
---- a/modules/imgcodecs/src/grfmt_bmp.cpp
-+++ b/modules/imgcodecs/src/grfmt_bmp.cpp
-@@ -193,7 +193,7 @@ bool  BmpDecoder::readHeader()
- bool  BmpDecoder::readData( Mat& img )
- {
-     uchar* data = img.ptr();
--    int step = (int)img.step;
-+    int step = validateToInt(img.step);
-     bool color = img.channels() > 1;
-     uchar  gray_palette[256] = {0};
-     bool   result = false;
-@@ -206,7 +206,7 @@ bool  BmpDecoder::readData( Mat& img )
- 
-     if( m_origin == IPL_ORIGIN_BL )
-     {
--        data += (m_height - 1)*step;
-+        data += (m_height - 1)*(size_t)step;
-         step = -step;
-     }
- 
-@@ -530,7 +530,7 @@ bool  BmpEncoder::write( const Mat& img, const std::vector<int>& )
-     int  bitmapHeaderSize = 40;
-     int  paletteSize = channels > 1 ? 0 : 1024;
-     int  headerSize = 14 /* fileheader */ + bitmapHeaderSize + paletteSize;
--    int  fileSize = fileStep*height + headerSize;
-+    size_t fileSize = (size_t)fileStep*height + headerSize;
-     PaletteEntry palette[256];
- 
-     if( m_buf )
-@@ -540,7 +540,7 @@ bool  BmpEncoder::write( const Mat& img, const std::vector<int>& )
-     strm.putBytes( fmtSignBmp, (int)strlen(fmtSignBmp) );
- 
-     // write file header
--    strm.putDWord( fileSize ); // file size
-+    strm.putDWord( validateToInt(fileSize) ); // file size
-     strm.putDWord( 0 );
-     strm.putDWord( headerSize );
- 
-diff --git a/modules/imgcodecs/src/grfmt_exr.cpp b/modules/imgcodecs/src/grfmt_exr.cpp
-index 0d2ae9fa7d2..78ffe6c7668 100644
---- a/modules/imgcodecs/src/grfmt_exr.cpp
-+++ b/modules/imgcodecs/src/grfmt_exr.cpp
-@@ -195,7 +195,7 @@ bool  ExrDecoder::readData( Mat& img )
-     bool color = img.channels() > 1;
- 
-     uchar* data = img.ptr();
--    int step = img.step;
-+    size_t step = img.step;
-     bool justcopy = m_native_depth;
-     bool chromatorgb = false;
-     bool rgbtogray = false;
-@@ -203,8 +203,8 @@ bool  ExrDecoder::readData( Mat& img )
-     FrameBuffer frame;
-     int xsample[3] = {1, 1, 1};
-     char *buffer;
--    int xstep;
--    int ystep;
-+    size_t xstep = 0;
-+    size_t ystep = 0;
- 
-     xstep = m_native_depth ? 4 : 1;
- 
-@@ -593,7 +593,7 @@ bool  ExrEncoder::write( const Mat& img, const std::vector<int>& )
-     bool issigned = depth == CV_8S || depth == CV_16S || depth == CV_32S;
-     bool isfloat = depth == CV_32F || depth == CV_64F;
-     depth = CV_ELEM_SIZE1(depth)*8;
--    const int step = img.step;
-+    const size_t step = img.step;
- 
-     Header header( width, height );
-     Imf::PixelType type;
-@@ -623,7 +623,7 @@ bool  ExrEncoder::write( const Mat& img, const std::vector<int>& )
-     FrameBuffer frame;
- 
-     char *buffer;
--    int bufferstep;
-+    size_t bufferstep;
-     int size;
-     if( type == FLOAT && depth == 32 )
-     {
-diff --git a/modules/imgcodecs/src/grfmt_jpeg.cpp b/modules/imgcodecs/src/grfmt_jpeg.cpp
-index ce942ca1995..caf768d2569 100644
---- a/modules/imgcodecs/src/grfmt_jpeg.cpp
-+++ b/modules/imgcodecs/src/grfmt_jpeg.cpp
-@@ -396,7 +396,7 @@ int my_jpeg_load_dht (struct jpeg_decompress_struct *info, unsigned char *dht,
- bool  JpegDecoder::readData( Mat& img )
- {
-     volatile bool result = false;
--    int step = (int)img.step;
-+    size_t step = img.step;
-     bool color = img.channels() > 1;
- 
-     if( m_state && m_width && m_height )
-diff --git a/modules/imgcodecs/src/grfmt_jpeg2000.cpp b/modules/imgcodecs/src/grfmt_jpeg2000.cpp
-index 950ec21375f..24dfb38bb9d 100644
---- a/modules/imgcodecs/src/grfmt_jpeg2000.cpp
-+++ b/modules/imgcodecs/src/grfmt_jpeg2000.cpp
-@@ -156,7 +156,7 @@ bool  Jpeg2KDecoder::readData( Mat& img )
-     bool result = false;
-     int color = img.channels() > 1;
-     uchar* data = img.ptr();
--    int step = (int)img.step;
-+    size_t step = img.step;
-     jas_stream_t* stream = (jas_stream_t*)m_stream;
-     jas_image_t* image = (jas_image_t*)m_image;
- 
-@@ -252,9 +252,9 @@ bool  Jpeg2KDecoder::readData( Mat& img )
-                         if( !jas_image_readcmpt( image, cmptlut[i], 0, 0, xend / xstep, yend / ystep, buffer ))
-                         {
-                             if( img.depth() == CV_8U )
--                                result = readComponent8u( data + i, buffer, step, cmptlut[i], maxval, offset, ncmpts );
-+                                result = readComponent8u( data + i, buffer, validateToInt(step), cmptlut[i], maxval, offset, ncmpts );
-                             else
--                                result = readComponent16u( ((unsigned short *)data) + i, buffer, step / 2, cmptlut[i], maxval, offset, ncmpts );
-+                                result = readComponent16u( ((unsigned short *)data) + i, buffer, validateToInt(step / 2), cmptlut[i], maxval, offset, ncmpts );
-                             if( !result )
-                             {
-                                 i = ncmpts;
-diff --git a/modules/imgcodecs/src/grfmt_pam.cpp b/modules/imgcodecs/src/grfmt_pam.cpp
-index 11195dc342c..8eb9e012309 100644
---- a/modules/imgcodecs/src/grfmt_pam.cpp
-+++ b/modules/imgcodecs/src/grfmt_pam.cpp
-@@ -479,7 +479,7 @@ bool  PAMDecoder::readData( Mat& img )
- {
-     uchar* data = img.ptr();
-     int target_channels = img.channels();
--    int imp_stride = (int)img.step;
-+    size_t imp_stride = img.step;
-     int sample_depth = CV_ELEM_SIZE1(m_type);
-     int src_elems_per_row = m_width*m_channels;
-     int src_stride = src_elems_per_row*sample_depth;
-diff --git a/modules/imgcodecs/src/grfmt_sunras.cpp b/modules/imgcodecs/src/grfmt_sunras.cpp
-index aca9b369318..6d448f94ed3 100644
---- a/modules/imgcodecs/src/grfmt_sunras.cpp
-+++ b/modules/imgcodecs/src/grfmt_sunras.cpp
-@@ -160,7 +160,7 @@ bool  SunRasterDecoder::readData( Mat& img )
- {
-     int color = img.channels() > 1;
-     uchar* data = img.ptr();
--    int step = (int)img.step;
-+    size_t step = img.step;
-     uchar  gray_palette[256] = {0};
-     bool   result = false;
-     int  src_pitch = ((m_width*m_bpp + 7)/8 + 1) & -2;
-@@ -308,11 +308,11 @@ bool  SunRasterDecoder::readData( Mat& img )
-                         code = m_strm.getByte();
- 
-                         if( color )
--                            data = FillUniColor( data, line_end, step, width3,
-+                            data = FillUniColor( data, line_end, validateToInt(step), width3,
-                                                  y, m_height, len,
-                                                  m_palette[code] );
-                         else
--                            data = FillUniGray( data, line_end, step, width3,
-+                            data = FillUniGray( data, line_end, validateToInt(step), width3,
-                                                 y, m_height, len,
-                                                 gray_palette[code] );
-                         if( y >= m_height )
-diff --git a/modules/imgcodecs/src/utils.cpp b/modules/imgcodecs/src/utils.cpp
-index 2ee5bafc712..474dae008ca 100644
---- a/modules/imgcodecs/src/utils.cpp
-+++ b/modules/imgcodecs/src/utils.cpp
-@@ -42,6 +42,13 @@
- #include "precomp.hpp"
- #include "utils.hpp"
- 
-+int validateToInt(size_t sz)
-+{
-+    int valueInt = (int)sz;
-+    CV_Assert((size_t)valueInt == sz);
-+    return valueInt;
-+}
-+
- #define  SCALE  14
- #define  cR  (int)(0.299*(1 << SCALE) + 0.5)
- #define  cG  (int)(0.587*(1 << SCALE) + 0.5)
-@@ -537,23 +544,25 @@ uchar* FillColorRow1( uchar* data, uchar* indices, int len, PaletteEntry* palett
- {
-     uchar* end = data + len*3;
- 
-+    const PaletteEntry p0 = palette[0], p1 = palette[1];
-+
-     while( (data += 24) < end )
-     {
-         int idx = *indices++;
--        *((PaletteEntry*)(data - 24)) = palette[(idx & 128) != 0];
--        *((PaletteEntry*)(data - 21)) = palette[(idx & 64) != 0];
--        *((PaletteEntry*)(data - 18)) = palette[(idx & 32) != 0];
--        *((PaletteEntry*)(data - 15)) = palette[(idx & 16) != 0];
--        *((PaletteEntry*)(data - 12)) = palette[(idx & 8) != 0];
--        *((PaletteEntry*)(data - 9)) = palette[(idx & 4) != 0];
--        *((PaletteEntry*)(data - 6)) = palette[(idx & 2) != 0];
--        *((PaletteEntry*)(data - 3)) = palette[(idx & 1) != 0];
-+        *((PaletteEntry*)(data - 24)) = (idx & 128) ? p1 : p0;
-+        *((PaletteEntry*)(data - 21)) = (idx & 64) ? p1 : p0;
-+        *((PaletteEntry*)(data - 18)) = (idx & 32) ? p1 : p0;
-+        *((PaletteEntry*)(data - 15)) = (idx & 16) ? p1 : p0;
-+        *((PaletteEntry*)(data - 12)) = (idx & 8) ? p1 : p0;
-+        *((PaletteEntry*)(data - 9)) = (idx & 4) ? p1 : p0;
-+        *((PaletteEntry*)(data - 6)) = (idx & 2) ? p1 : p0;
-+        *((PaletteEntry*)(data - 3)) = (idx & 1) ? p1 : p0;
-     }
- 
--    int idx = indices[0] << 24;
-+    int idx = indices[0];
-     for( data -= 24; data < end; data += 3, idx += idx )
-     {
--        PaletteEntry clr = palette[idx < 0];
-+        const PaletteEntry clr = (idx & 128) ? p1 : p0;
-         WRITE_PIX( data, clr );
-     }
- 
-@@ -565,23 +574,25 @@ uchar* FillGrayRow1( uchar* data, uchar* indices, int len, uchar* palette )
- {
-     uchar* end = data + len;
- 
-+    const uchar p0 = palette[0], p1 = palette[1];
-+
-     while( (data += 8) < end )
-     {
-         int idx = *indices++;
--        *((uchar*)(data - 8)) = palette[(idx & 128) != 0];
--        *((uchar*)(data - 7)) = palette[(idx & 64) != 0];
--        *((uchar*)(data - 6)) = palette[(idx & 32) != 0];
--        *((uchar*)(data - 5)) = palette[(idx & 16) != 0];
--        *((uchar*)(data - 4)) = palette[(idx & 8) != 0];
--        *((uchar*)(data - 3)) = palette[(idx & 4) != 0];
--        *((uchar*)(data - 2)) = palette[(idx & 2) != 0];
--        *((uchar*)(data - 1)) = palette[(idx & 1) != 0];
-+        *((uchar*)(data - 8)) = (idx & 128) ? p1 : p0;
-+        *((uchar*)(data - 7)) = (idx & 64) ? p1 : p0;
-+        *((uchar*)(data - 6)) = (idx & 32) ? p1 : p0;
-+        *((uchar*)(data - 5)) = (idx & 16) ? p1 : p0;
-+        *((uchar*)(data - 4)) = (idx & 8) ? p1 : p0;
-+        *((uchar*)(data - 3)) = (idx & 4) ? p1 : p0;
-+        *((uchar*)(data - 2)) = (idx & 2) ? p1 : p0;
-+        *((uchar*)(data - 1)) = (idx & 1) ? p1 : p0;
-     }
- 
--    int idx = indices[0] << 24;
-+    int idx = indices[0];
-     for( data -= 8; data < end; data++, idx += idx )
-     {
--        data[0] = palette[idx < 0];
-+        data[0] = (idx & 128) ? p1 : p0;
-     }
- 
-     return data;
-diff --git a/modules/imgcodecs/src/utils.hpp b/modules/imgcodecs/src/utils.hpp
-index cab10609db2..7af4c6174ee 100644
---- a/modules/imgcodecs/src/utils.hpp
-+++ b/modules/imgcodecs/src/utils.hpp
-@@ -42,6 +42,8 @@
- #ifndef _UTILS_H_
- #define _UTILS_H_
- 
-+int validateToInt(size_t step);
-+
- struct PaletteEntry
- {
-     unsigned char b, g, r, a;
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/already-exists.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/already-exists.patch
deleted file mode 100644
index 6e24f2d..0000000
--- a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/already-exists.patch
+++ /dev/null
@@ -1,394 +0,0 @@
-From e4bf148cddf277834e57c9afeec8daff8378a655 Mon Sep 17 00:00:00 2001
-From: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
-Date: Wed, 22 Nov 2017 15:27:07 +0100
-Subject: [PATCH] Fix: File already exists in database: caffe.proto
-
-Fixes error when importing python cv
-
-Upstream-status: Backport https://github.com/opencv/opencv/pull/10092
-Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
----
- modules/dnn/CMakeLists.txt                                | 6 +++---
- modules/dnn/src/caffe/caffe_importer.cpp                  | 1 -
- modules/dnn/src/caffe/caffe_io.cpp                        | 1 -
- modules/dnn/src/caffe/caffe_io.hpp                        | 2 +-
- modules/dnn/src/caffe/{caffe.proto => opencv-caffe.proto} | 0
- 5 files changed, 4 insertions(+), 6 deletions(-)
- rename modules/dnn/src/caffe/{caffe.proto => opencv-caffe.proto} (100%)
-
-diff --git a/modules/dnn/CMakeLists.txt b/modules/dnn/CMakeLists.txt
-index c6329a742263..8ef00ef983ff 100644
---- a/modules/dnn/CMakeLists.txt
-+++ b/modules/dnn/CMakeLists.txt
-@@ -55,13 +55,13 @@ ocv_warnings_disable(CMAKE_CXX_FLAGS
- 
- if(PROTOBUF_UPDATE_FILES)
-   file(GLOB proto_files src/tensorflow/*.proto)
--  list(APPEND proto_files src/caffe/caffe.proto)
-+  list(APPEND proto_files src/caffe/opencv-caffe.proto)
-   PROTOBUF_GENERATE_CPP(Protobuf_HDRS Protobuf_SRCS ${proto_files})
- else()
-   file(GLOB fw_srcs ${CMAKE_CURRENT_SOURCE_DIR}/misc/tensorflow/*.cc)
-   file(GLOB fw_hdrs ${CMAKE_CURRENT_SOURCE_DIR}/misc/tensorflow/*.h)
--  list(APPEND fw_srcs ${CMAKE_CURRENT_SOURCE_DIR}/misc/caffe/caffe.pb.cc)
--  list(APPEND fw_hdrs ${CMAKE_CURRENT_SOURCE_DIR}/misc/caffe/caffe.pb.h)
-+  list(APPEND fw_srcs ${CMAKE_CURRENT_SOURCE_DIR}/misc/caffe/opencv-caffe.pb.cc)
-+  list(APPEND fw_hdrs ${CMAKE_CURRENT_SOURCE_DIR}/misc/caffe/opencv-caffe.pb.h)
-   list(APPEND Protobuf_SRCS ${fw_srcs})
-   list(APPEND Protobuf_HDRS ${fw_hdrs})
-   list(APPEND Protobuf_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/misc/caffe)
-diff --git a/modules/dnn/src/caffe/caffe_importer.cpp b/modules/dnn/src/caffe/caffe_importer.cpp
-index c075651b95b3..2c977c84b0f4 100644
---- a/modules/dnn/src/caffe/caffe_importer.cpp
-+++ b/modules/dnn/src/caffe/caffe_importer.cpp
-@@ -42,7 +42,6 @@
- #include "../precomp.hpp"
- 
- #ifdef HAVE_PROTOBUF
--#include "caffe.pb.h"
- 
- #include <iostream>
- #include <fstream>
-diff --git a/modules/dnn/src/caffe/caffe_io.cpp b/modules/dnn/src/caffe/caffe_io.cpp
-index 0f46ea77df9a..1d3c518f1328 100644
---- a/modules/dnn/src/caffe/caffe_io.cpp
-+++ b/modules/dnn/src/caffe/caffe_io.cpp
-@@ -99,7 +99,6 @@
- #include <fstream>
- #include <vector>
- 
--#include "caffe.pb.h"
- #include "caffe_io.hpp"
- #include "glog_emulator.hpp"
- 
-diff --git a/modules/dnn/src/caffe/caffe_io.hpp b/modules/dnn/src/caffe/caffe_io.hpp
-index 09bc5709a24e..f5912c3bcec1 100644
---- a/modules/dnn/src/caffe/caffe_io.hpp
-+++ b/modules/dnn/src/caffe/caffe_io.hpp
-@@ -91,7 +91,7 @@
- #define __OPENCV_DNN_CAFFE_IO_HPP__
- #ifdef HAVE_PROTOBUF
- 
--#include "caffe.pb.h"
-+#include "opencv-caffe.pb.h"
- 
- namespace cv {
- namespace dnn {
-diff --git a/modules/dnn/src/caffe/caffe.proto b/modules/dnn/src/caffe/opencv-caffe.proto
-similarity index 100%
-rename from modules/dnn/src/caffe/caffe.proto
-rename to modules/dnn/src/caffe/opencv-caffe.proto
-diff --git a/modules/dnn/src/layers/detection_output_layer.cpp b/modules/dnn/src/layers/detection_output_layer.cpp
-index 0b72326f7e7d..f413bad5b81a 100644
---- a/modules/dnn/src/layers/detection_output_layer.cpp
-+++ b/modules/dnn/src/layers/detection_output_layer.cpp
-@@ -44,7 +44,7 @@
- #include "layers_common.hpp"
- #include <float.h>
- #include <string>
--#include <caffe.pb.h>
-+#include <opencv-caffe.pb.h>
- 
- namespace cv
- {
-diff --git a/modules/dnn/src/caffe/caffe_importer.cpp b/modules/dnn/src/caffe/caffe_importer.cpp
-index 2c977c84b0f4..a1827a381117 100644
---- a/modules/dnn/src/caffe/caffe_importer.cpp
-+++ b/modules/dnn/src/caffe/caffe_importer.cpp
-@@ -78,8 +78,8 @@ static cv::String toString(const T &v)
- 
- class CaffeImporter : public Importer
- {
--    caffe::NetParameter net;
--    caffe::NetParameter netBinary;
-+    opencvcaffe::NetParameter net;
-+    opencvcaffe::NetParameter netBinary;
- 
- public:
- 
-@@ -197,7 +197,7 @@ public:
-         }
-     }
- 
--    void blobShapeFromProto(const caffe::BlobProto &pbBlob, MatShape& shape)
-+    void blobShapeFromProto(const opencvcaffe::BlobProto &pbBlob, MatShape& shape)
-     {
-         shape.clear();
-         if (pbBlob.has_num() || pbBlob.has_channels() || pbBlob.has_height() || pbBlob.has_width())
-@@ -209,7 +209,7 @@ public:
-         }
-         else if (pbBlob.has_shape())
-         {
--            const caffe::BlobShape &_shape = pbBlob.shape();
-+            const opencvcaffe::BlobShape &_shape = pbBlob.shape();
- 
-             for (int i = 0; i < _shape.dim_size(); i++)
-                 shape.push_back((int)_shape.dim(i));
-@@ -218,7 +218,7 @@ public:
-             CV_Error(Error::StsError, "Unknown shape of input blob");
-     }
- 
--    void blobFromProto(const caffe::BlobProto &pbBlob, cv::Mat &dstBlob)
-+    void blobFromProto(const opencvcaffe::BlobProto &pbBlob, cv::Mat &dstBlob)
-     {
-         MatShape shape;
-         blobShapeFromProto(pbBlob, shape);
-@@ -233,7 +233,7 @@ public:
-             dstData[i] = pbBlob.data(i);
-     }
- 
--    void extractBinaryLayerParms(const caffe::LayerParameter& layer, LayerParams& layerParams)
-+    void extractBinaryLayerParms(const opencvcaffe::LayerParameter& layer, LayerParams& layerParams)
-     {
-         const std::string &name = layer.name();
- 
-@@ -247,7 +247,7 @@ public:
-         if (li == netBinary.layer_size() || netBinary.layer(li).blobs_size() == 0)
-             return;
- 
--        const caffe::LayerParameter &binLayer = netBinary.layer(li);
-+        const opencvcaffe::LayerParameter &binLayer = netBinary.layer(li);
-         layerParams.blobs.resize(binLayer.blobs_size());
-         for (int bi = 0; bi < binLayer.blobs_size(); bi++)
-         {
-@@ -289,7 +289,7 @@ public:
- 
-         for (int li = 0; li < layersSize; li++)
-         {
--            const caffe::LayerParameter &layer = net.layer(li);
-+            const opencvcaffe::LayerParameter &layer = net.layer(li);
-             String name = layer.name();
-             String type = layer.type();
-             LayerParams layerParams;
-@@ -313,7 +313,7 @@ public:
-         addedBlobs.clear();
-     }
- 
--    void addOutput(const caffe::LayerParameter &layer, int layerId, int outNum)
-+    void addOutput(const opencvcaffe::LayerParameter &layer, int layerId, int outNum)
-     {
-         const std::string &name = layer.top(outNum);
- 
-diff --git a/modules/dnn/src/caffe/caffe_io.hpp b/modules/dnn/src/caffe/caffe_io.hpp
-index f5912c3bcec1..24cd5fa254eb 100644
---- a/modules/dnn/src/caffe/caffe_io.hpp
-+++ b/modules/dnn/src/caffe/caffe_io.hpp
-@@ -98,9 +98,9 @@ namespace dnn {
- 
- // Read parameters from a file into a NetParameter proto message.
- void ReadNetParamsFromTextFileOrDie(const char* param_file,
--                                    caffe::NetParameter* param);
-+                                    opencvcaffe::NetParameter* param);
- void ReadNetParamsFromBinaryFileOrDie(const char* param_file,
--                                      caffe::NetParameter* param);
-+                                      opencvcaffe::NetParameter* param);
- 
- }
- }
-diff --git a/modules/dnn/src/caffe/opencv-caffe.proto b/modules/dnn/src/caffe/opencv-caffe.proto
-index 3d23fb48ea6a..df4e1d3269ae 100644
---- a/modules/dnn/src/caffe/opencv-caffe.proto
-+++ b/modules/dnn/src/caffe/opencv-caffe.proto
-@@ -48,7 +48,7 @@
- 
- syntax = "proto2";
- 
--package caffe;
-+package opencvcaffe;
- 
- // Specifies the shape (dimensions) of a Blob.
- message BlobShape {
-diff --git a/modules/dnn/src/layers/detection_output_layer.cpp b/modules/dnn/src/layers/detection_output_layer.cpp
-index f413bad5b81a..832c257eebf9 100644
---- a/modules/dnn/src/layers/detection_output_layer.cpp
-+++ b/modules/dnn/src/layers/detection_output_layer.cpp
-@@ -72,7 +72,7 @@ public:
- 
-     int _backgroundLabelId;
- 
--    typedef caffe::PriorBoxParameter_CodeType CodeType;
-+    typedef opencvcaffe::PriorBoxParameter_CodeType CodeType;
-     CodeType _codeType;
- 
-     bool _varianceEncodedInTarget;
-@@ -85,7 +85,7 @@ public:
-     enum { _numAxes = 4 };
-     static const std::string _layerName;
- 
--    typedef std::map<int, std::vector<caffe::NormalizedBBox> > LabelBBox;
-+    typedef std::map<int, std::vector<opencvcaffe::NormalizedBBox> > LabelBBox;
- 
-     bool getParameterDict(const LayerParams &params,
-                           const std::string &parameterName,
-@@ -131,11 +131,11 @@ public:
-     {
-         String codeTypeString = params.get<String>("code_type").toLowerCase();
-         if (codeTypeString == "corner")
--            _codeType = caffe::PriorBoxParameter_CodeType_CORNER;
-+            _codeType = opencvcaffe::PriorBoxParameter_CodeType_CORNER;
-         else if (codeTypeString == "center_size")
--            _codeType = caffe::PriorBoxParameter_CodeType_CENTER_SIZE;
-+            _codeType = opencvcaffe::PriorBoxParameter_CodeType_CENTER_SIZE;
-         else
--            _codeType = caffe::PriorBoxParameter_CodeType_CORNER;
-+            _codeType = opencvcaffe::PriorBoxParameter_CodeType_CORNER;
-     }
- 
-     DetectionOutputLayerImpl(const LayerParams &params)
-@@ -215,7 +215,7 @@ public:
-             GetConfidenceScores(confidenceData, num, numPriors, _numClasses, allConfidenceScores);
- 
-             // Retrieve all prior bboxes
--            std::vector<caffe::NormalizedBBox> priorBBoxes;
-+            std::vector<opencvcaffe::NormalizedBBox> priorBBoxes;
-             std::vector<std::vector<float> > priorVariances;
-             GetPriorBBoxes(priorData, numPriors, priorBBoxes, priorVariances);
- 
-@@ -272,7 +272,7 @@ public:
-             for (size_t j = 0; j < indices.size(); ++j, ++count)
-             {
-                 int idx = indices[j];
--                const caffe::NormalizedBBox& decode_bbox = label_bboxes->second[idx];
-+                const opencvcaffe::NormalizedBBox& decode_bbox = label_bboxes->second[idx];
-                 outputsData[count * 7] = i;
-                 outputsData[count * 7 + 1] = label;
-                 outputsData[count * 7 + 2] = scores[idx];
-@@ -355,7 +355,7 @@ public:
- 
-     // Compute bbox size
-     template<bool normalized>
--    static float BBoxSize(const caffe::NormalizedBBox& bbox)
-+    static float BBoxSize(const opencvcaffe::NormalizedBBox& bbox)
-     {
-         if (bbox.xmax() < bbox.xmin() || bbox.ymax() < bbox.ymin())
-         {
-@@ -388,10 +388,10 @@ public:
-     // Decode a bbox according to a prior bbox
-     template<bool variance_encoded_in_target>
-     static void DecodeBBox(
--        const caffe::NormalizedBBox& prior_bbox, const std::vector<float>& prior_variance,
-+        const opencvcaffe::NormalizedBBox& prior_bbox, const std::vector<float>& prior_variance,
-         const CodeType code_type,
--        const bool clip_bbox, const caffe::NormalizedBBox& bbox,
--        caffe::NormalizedBBox& decode_bbox)
-+        const bool clip_bbox, const opencvcaffe::NormalizedBBox& bbox,
-+        opencvcaffe::NormalizedBBox& decode_bbox)
-     {
-         float bbox_xmin = variance_encoded_in_target ? bbox.xmin() : prior_variance[0] * bbox.xmin();
-         float bbox_ymin = variance_encoded_in_target ? bbox.ymin() : prior_variance[1] * bbox.ymin();
-@@ -399,13 +399,13 @@ public:
-         float bbox_ymax = variance_encoded_in_target ? bbox.ymax() : prior_variance[3] * bbox.ymax();
-         switch(code_type)
-         {
--            case caffe::PriorBoxParameter_CodeType_CORNER:
-+            case opencvcaffe::PriorBoxParameter_CodeType_CORNER:
-                 decode_bbox.set_xmin(prior_bbox.xmin() + bbox_xmin);
-                 decode_bbox.set_ymin(prior_bbox.ymin() + bbox_ymin);
-                 decode_bbox.set_xmax(prior_bbox.xmax() + bbox_xmax);
-                 decode_bbox.set_ymax(prior_bbox.ymax() + bbox_ymax);
-                 break;
--            case caffe::PriorBoxParameter_CodeType_CENTER_SIZE:
-+            case opencvcaffe::PriorBoxParameter_CodeType_CENTER_SIZE:
-             {
-                 float prior_width = prior_bbox.xmax() - prior_bbox.xmin();
-                 CV_Assert(prior_width > 0);
-@@ -431,7 +431,7 @@ public:
-         };
-         if (clip_bbox)
-         {
--            // Clip the caffe::NormalizedBBox such that the range for each corner is [0, 1]
-+            // Clip the opencvcaffe::NormalizedBBox such that the range for each corner is [0, 1]
-             decode_bbox.set_xmin(std::max(std::min(decode_bbox.xmin(), 1.f), 0.f));
-             decode_bbox.set_ymin(std::max(std::min(decode_bbox.ymin(), 1.f), 0.f));
-             decode_bbox.set_xmax(std::max(std::min(decode_bbox.xmax(), 1.f), 0.f));
-@@ -443,11 +443,11 @@ public:
- 
-     // Decode a set of bboxes according to a set of prior bboxes
-     static void DecodeBBoxes(
--        const std::vector<caffe::NormalizedBBox>& prior_bboxes,
-+        const std::vector<opencvcaffe::NormalizedBBox>& prior_bboxes,
-         const std::vector<std::vector<float> >& prior_variances,
-         const CodeType code_type, const bool variance_encoded_in_target,
--        const bool clip_bbox, const std::vector<caffe::NormalizedBBox>& bboxes,
--        std::vector<caffe::NormalizedBBox>& decode_bboxes)
-+        const bool clip_bbox, const std::vector<opencvcaffe::NormalizedBBox>& bboxes,
-+        std::vector<opencvcaffe::NormalizedBBox>& decode_bboxes)
-     {
-         CV_Assert(prior_bboxes.size() == prior_variances.size());
-         CV_Assert(prior_bboxes.size() == bboxes.size());
-@@ -470,7 +470,7 @@ public:
- 
-     // Decode all bboxes in a batch
-     static void DecodeBBoxesAll(const std::vector<LabelBBox>& all_loc_preds,
--        const std::vector<caffe::NormalizedBBox>& prior_bboxes,
-+        const std::vector<opencvcaffe::NormalizedBBox>& prior_bboxes,
-         const std::vector<std::vector<float> >& prior_variances,
-         const int num, const bool share_location,
-         const int num_loc_classes, const int background_label_id,
-@@ -503,10 +503,10 @@ public:
-     // Get prior bounding boxes from prior_data
-     //    prior_data: 1 x 2 x num_priors * 4 x 1 blob.
-     //    num_priors: number of priors.
--    //    prior_bboxes: stores all the prior bboxes in the format of caffe::NormalizedBBox.
-+    //    prior_bboxes: stores all the prior bboxes in the format of opencvcaffe::NormalizedBBox.
-     //    prior_variances: stores all the variances needed by prior bboxes.
-     static void GetPriorBBoxes(const float* priorData, const int& numPriors,
--                        std::vector<caffe::NormalizedBBox>& priorBBoxes,
-+                        std::vector<opencvcaffe::NormalizedBBox>& priorBBoxes,
-                         std::vector<std::vector<float> >& priorVariances)
-     {
-         priorBBoxes.clear(); priorBBoxes.resize(numPriors);
-@@ -514,7 +514,7 @@ public:
-         for (int i = 0; i < numPriors; ++i)
-         {
-             int startIdx = i * 4;
--            caffe::NormalizedBBox& bbox = priorBBoxes[i];
-+            opencvcaffe::NormalizedBBox& bbox = priorBBoxes[i];
-             bbox.set_xmin(priorData[startIdx]);
-             bbox.set_ymin(priorData[startIdx + 1]);
-             bbox.set_xmax(priorData[startIdx + 2]);
-@@ -565,7 +565,7 @@ public:
-                     {
-                         labelBBox[label].resize(numPredsPerClass);
-                     }
--                    caffe::NormalizedBBox& bbox = labelBBox[label][p];
-+                    opencvcaffe::NormalizedBBox& bbox = labelBBox[label][p];
-                     bbox.set_xmin(locData[startIdx + c * 4]);
-                     bbox.set_ymin(locData[startIdx + c * 4 + 1]);
-                     bbox.set_xmax(locData[startIdx + c * 4 + 2]);
-@@ -612,7 +612,7 @@ public:
-     //    nms_threshold: a threshold used in non maximum suppression.
-     //    top_k: if not -1, keep at most top_k picked indices.
-     //    indices: the kept indices of bboxes after nms.
--    static void ApplyNMSFast(const std::vector<caffe::NormalizedBBox>& bboxes,
-+    static void ApplyNMSFast(const std::vector<opencvcaffe::NormalizedBBox>& bboxes,
-           const std::vector<float>& scores, const float score_threshold,
-           const float nms_threshold, const float eta, const int top_k,
-           std::vector<int>& indices)
-@@ -674,10 +674,10 @@ public:
- 
-     // Compute the jaccard (intersection over union IoU) overlap between two bboxes.
-     template<bool normalized>
--    static float JaccardOverlap(const caffe::NormalizedBBox& bbox1,
--                         const caffe::NormalizedBBox& bbox2)
-+    static float JaccardOverlap(const opencvcaffe::NormalizedBBox& bbox1,
-+                         const opencvcaffe::NormalizedBBox& bbox2)
-     {
--        caffe::NormalizedBBox intersect_bbox;
-+        opencvcaffe::NormalizedBBox intersect_bbox;
-         if (bbox2.xmin() > bbox1.xmax() || bbox2.xmax() < bbox1.xmin() ||
-             bbox2.ymin() > bbox1.ymax() || bbox2.ymax() < bbox1.ymin())
-         {
-diff --git a/modules/dnn/src/caffe/caffe_io.cpp b/modules/dnn/src/caffe/caffe_io.cpp
-index 1d3c518f1328..3cf6e255aa60 100644
---- a/modules/dnn/src/caffe/caffe_io.cpp
-+++ b/modules/dnn/src/caffe/caffe_io.cpp
-@@ -107,7 +107,7 @@ namespace dnn {
- 
- using std::string;
- using std::map;
--using namespace caffe;
-+using namespace opencvcaffe;
- using namespace ::google::protobuf;
- using namespace ::google::protobuf::io;
- 
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/fixpkgconfig.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/fixpkgconfig.patch
index 3aeda7d..3ed3468 100644
--- a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/fixpkgconfig.patch
+++ b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/fixpkgconfig.patch
@@ -1,24 +1,25 @@
-diff --git a/cmake/OpenCVGenPkgconfig.cmake b/cmake/OpenCVGenPkgconfig.cmake
-index b8cb8777c06b..75281ee964fd 100644
---- a/cmake/OpenCVGenPkgconfig.cmake
-+++ b/cmake/OpenCVGenPkgconfig.cmake
-@@ -27,7 +27,7 @@ macro(fix_prefix lst isown)
+Index: git/cmake/OpenCVGenPkgconfig.cmake
+===================================================================
+--- git.orig/cmake/OpenCVGenPkgconfig.cmake
++++ git/cmake/OpenCVGenPkgconfig.cmake
+@@ -31,7 +31,7 @@ macro(fix_prefix lst isown)
        get_filename_component(libdir "${item}" PATH)
-       get_filename_component(libname "${item}" NAME_WE)
-       string(REGEX REPLACE "^lib(.*)" "\\1" libname "${libname}")
+       get_filename_component(_libname "${item}" NAME)
+       ocv_get_libname(libname "${_libname}")
 -      list(APPEND _lst "-L${libdir}" "-l${libname}")
 +      list(APPEND _lst "-l${libname}")
      else()
        list(APPEND _lst "-l${item}")
      endif()
-@@ -66,10 +66,14 @@ ocv_list_unique(_3rdparty)
+@@ -124,11 +124,14 @@ ocv_list_unique(_extra)
+ ocv_list_unique(_3rdparty)
  
  set(OPENCV_PC_LIBS
-   "-L\${exec_prefix}/${OPENCV_LIB_INSTALL_PATH}"
+-  "-L\${exec_prefix}/${OPENCV_LIB_INSTALL_PATH}"
 +  "-L\${exec_prefix}/${OPENCV_3P_LIB_INSTALL_PATH}"
    "${_modules}"
  )
- if (BUILD_SHARED_LIBS)
+ if(BUILD_SHARED_LIBS)
 -  set(OPENCV_PC_LIBS_PRIVATE "${_extra}")
 +  set(OPENCV_PC_LIBS_PRIVATE
 +    "-L\${exec_prefix}/${OPENCV_LIB_INSTALL_PATH}"
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/javagen.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/javagen.patch
deleted file mode 100644
index 56526ec..0000000
--- a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/javagen.patch
+++ /dev/null
@@ -1,16 +0,0 @@
-Upstream-status: Inappropriate [OE specific] https://github.com/opencv/opencv/pull/10039#issuecomment-342539288
-
-Signed-off-by: Ricardo Ribalda <ricardo.ribalda@gmail.com>
-diff --git a/modules/java/CMakeLists.txt b/modules/java/CMakeLists.txt
-index 74bc0ef04169..4622fbf9a5f1 100644
---- a/modules/java/CMakeLists.txt
-+++ b/modules/java/CMakeLists.txt
-@@ -291,7 +291,7 @@ foreach(java_file ${step3_input_files})
-   endif()
-   if(__configure)
-     configure_file("${java_file}" "${java_src_dir}/${output_name}" @ONLY)
--  elseif(NOT "${java_file}" MATCHES "${OpenCV_BINARY_DIR}/")
-+  elseif(EXISTS "${java_file}" AND NOT "${java_file}" MATCHES "${OpenCV_BINARY_DIR}/")
-     configure_file("${java_file}" "${java_src_dir}/${output_name}" COPYONLY)
-   else()
-     add_custom_command(OUTPUT "${java_src_dir}/${output_name}"
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/protobuf.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/protobuf.patch
deleted file mode 100644
index c63dc14..0000000
--- a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/protobuf.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-Upstream-status: Inappropriate [OE specific]
-
-Signed-off-by: Ricardo Ribalda <ricardo.ribalda@gmail.com>
-diff --git a/cmake/OpenCVFindLibProtobuf.cmake b/cmake/OpenCVFindLibProtobuf.cmake
-index b6ce1e7fd56b..e916ec0df2a6 100644
---- a/cmake/OpenCVFindLibProtobuf.cmake
-+++ b/cmake/OpenCVFindLibProtobuf.cmake
-@@ -7,21 +7,21 @@ OCV_OPTION(BUILD_PROTOBUF "Force to build libprotobuf from sources" ON)
- OCV_OPTION(PROTOBUF_UPDATE_FILES "Force to rebuild .proto files" OFF)
- 
- if(PROTOBUF_UPDATE_FILES)
--  if(NOT DEFINED Protobuf_PROTOC_EXECUTABLE)
-+  if(NOT DEFINED PROTOBUF_PROTOC_EXECUTABLE)
-     find_package(Protobuf QUIET)
-   endif()
--  if(DEFINED Protobuf_PROTOC_EXECUTABLE AND EXISTS ${Protobuf_PROTOC_EXECUTABLE})
--    message(STATUS "The protocol buffer compiler is found (${Protobuf_PROTOC_EXECUTABLE})")
-+  if(DEFINED PROTOBUF_PROTOC_EXECUTABLE AND EXISTS ${PROTOBUF_PROTOC_EXECUTABLE})
-+    message(STATUS "The protocol buffer compiler is found (${PROTOBUF_PROTOC_EXECUTABLE})")
-   else()
--    message(FATAL_ERROR "The protocol buffer compiler is not found (Protobuf_PROTOC_EXECUTABLE='${Protobuf_PROTOC_EXECUTABLE}')")
-+    message(FATAL_ERROR "The protocol buffer compiler is not found (PROTOBUF_PROTOC_EXECUTABLE='${PROTOBUF_PROTOC_EXECUTABLE}')")
-   endif()
- endif()
- 
--if(NOT BUILD_PROTOBUF AND NOT (DEFINED Protobuf_INCLUDE_DIRS AND DEFINED Protobuf_LIBRARIES))
-+if(NOT BUILD_PROTOBUF AND NOT (DEFINED PROTOBUF_INCLUDE_DIR AND DEFINED PROTOBUF_LIBRARIES))
-   find_package(Protobuf QUIET)
- endif()
- 
--if(Protobuf_FOUND)
-+if(PROTOBUF_FOUND OR (DEFINED PROTOBUF_INCLUDE_DIR AND DEFINED PROTOBUF_LIBRARIES))
-   # nothing
- else()
-   set(Protobuf_LIBRARIES libprotobuf)
-diff --git a/modules/dnn/CMakeLists.txt b/modules/dnn/CMakeLists.txt
-index 2a71568d1a44..c6329a742263 100644
---- a/modules/dnn/CMakeLists.txt
-+++ b/modules/dnn/CMakeLists.txt
-@@ -7,7 +7,7 @@ if(DEFINED BUILD_opencv_dnn AND NOT BUILD_opencv_dnn)
- endif()
- 
- include(${OpenCV_SOURCE_DIR}/cmake/OpenCVFindLibProtobuf.cmake)
--if(NOT Protobuf_FOUND)
-+if(NOT PROTOBUF_FOUND)
-   ocv_module_disable(opencv_dnn)
- endif()
- 
-@@ -72,7 +72,7 @@ ocv_source_group("Src\\protobuf" FILES ${Protobuf_SRCS} ${Protobuf_HDRS})
- ocv_module_include_directories(include ${Protobuf_INCLUDE_DIRS})
- 
- ocv_glob_module_sources(${Protobuf_SRCS} ${Protobuf_HDRS} ${CBLAS_H_PROXY_PATH})
--ocv_create_module(${Protobuf_LIBRARIES} ${LAPACK_LIBRARIES})
-+ocv_create_module(${PROTOBUF_LIBRARIES} ${LAPACK_LIBRARIES})
- ocv_add_samples()
- ocv_add_accuracy_tests()
- ocv_add_perf_tests()
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/tinydnn.patch b/meta-openembedded/meta-oe/recipes-support/opencv/opencv/tinydnn.patch
deleted file mode 100644
index c433fc3..0000000
--- a/meta-openembedded/meta-oe/recipes-support/opencv/opencv/tinydnn.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-Upstream-status: Inappropriate [OE specific]
-
-Signed-off-by: Ricardo Ribalda <ricardo.ribalda@gmail.com>
-diff --git a/modules/dnn_modern/CMakeLists.txt b/modules/dnn_modern/CMakeLists.txt
-index 79b64b12160b..ba06a0a163e4 100644
---- a/modules/dnn_modern/CMakeLists.txt
-+++ b/modules/dnn_modern/CMakeLists.txt
-@@ -15,24 +15,8 @@ list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake)
- # MODULE REQUIREMENTS
- # ----------------------------------------------------------------------------
- 
--set(TINY_DNN_CPP_PATH "${OpenCV_BINARY_DIR}/3rdparty/tinydnn")
--set(TINY_DNN_CPP_ROOT "${TINY_DNN_CPP_PATH}/tiny-dnn-1.0.0a3")
--ocv_download(FILENAME "v1.0.0a3.tar.gz"
--               HASH "adb1c512e09ca2c7a6faef36f9c53e59"
--               URL
--                 "${OPENCV_TINY_DNN_URL}"
--                 "$ENV{OPENCV_TINY_DNN_URL}"
--                 "https://github.com/tiny-dnn/tiny-dnn/archive/"
--               DESTINATION_DIR "${TINY_DNN_CPP_PATH}"
--               STATUS TINY_DNN_DOWNLOAD_SUCCESS
--               ID "tiny-dnn"
--               UNPACK RELATIVE_URL)
--
--if(NOT TINY_DNN_DOWNLOAD_SUCCESS)
--  message(STATUS "Failed to download tiny-dnn sources")
--endif()
--
--find_package(TinyDNN QUIET)
-+set(TINYDNN_INCLUDE_DIRS "${OpenCV_SOURCE_DIR}/3rdparty/tinydnn/tiny-dnn-1.0.0a3")
-+set(TinyDNN_FOUND TRUE)
- 
- include(CheckCXXCompilerFlag)
- CHECK_CXX_COMPILER_FLAG("-std=c++11" COMPILER_SUPPORTS_CXX11)
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv_3.3.bb b/meta-openembedded/meta-oe/recipes-support/opencv/opencv_3.3.bb
deleted file mode 100644
index ca62de7..0000000
--- a/meta-openembedded/meta-oe/recipes-support/opencv/opencv_3.3.bb
+++ /dev/null
@@ -1,203 +0,0 @@
-SUMMARY = "Opencv : The Open Computer Vision Library"
-HOMEPAGE = "http://opencv.org/"
-SECTION = "libs"
-
-LICENSE = "BSD-3-Clause"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=2b2f8752cc5edf504d283107d033f544"
-
-ARM_INSTRUCTION_SET_armv4 = "arm"
-ARM_INSTRUCTION_SET_armv5 = "arm"
-
-DEPENDS = "libtool swig-native bzip2 zlib glib-2.0 libwebp"
-
-SRCREV_opencv = "87c27a074db9f6d9d60513f351daa903606ca370"
-SRCREV_contrib = "2a9d1b22ed76eb22fad1a5edf6faf4d05f207b13"
-SRCREV_ipp = "a62e20676a60ee0ad6581e217fe7e4bada3b95db"
-SRCREV_boostdesc = "34e4206aef44d50e6bbcd0ab06354b52e7466d26"
-SRCREV_vgg = "fccf7cd6a4b12079f73bbfb21745f9babcd4eb1d"
-SRC_URI[tinydnn.md5sum] = "adb1c512e09ca2c7a6faef36f9c53e59"
-SRC_URI[tinydnn.sha256sum] = "e2c61ce8c5debaa644121179e9dbdcf83f497f39de853f8dd5175846505aa18b"
-
-def ipp_filename(d):
-    import re
-    arch = d.getVar('TARGET_ARCH', True)
-    if re.match("i.86$", arch):
-        return "ippicv_2017u2_lnx_ia32_20170418.tgz"
-    else:
-        return "ippicv_2017u2_lnx_intel64_20170418.tgz"
-
-def ipp_md5sum(d):
-    import re
-    arch = d.getVar('TARGET_ARCH', True)
-    if re.match("i.86$", arch):
-        return "f2cece00d802d4dea86df52ed095257e"
-    else:
-        return "808b791a6eac9ed78d32a7666804320e"
-
-IPP_FILENAME = "${@ipp_filename(d)}"
-IPP_MD5 = "${@ipp_md5sum(d)}"
-
-SRCREV_FORMAT = "opencv_contrib_ipp_boostdesc_vgg"
-SRC_URI = "git://github.com/opencv/opencv.git;name=opencv \
-    git://github.com/opencv/opencv_contrib.git;destsuffix=contrib;name=contrib \
-    git://github.com/opencv/opencv_3rdparty.git;branch=ippicv/master_20170418;destsuffix=ipp;name=ipp \
-    git://github.com/opencv/opencv_3rdparty.git;branch=contrib_xfeatures2d_boostdesc_20161012;destsuffix=boostdesc;name=boostdesc \
-    git://github.com/opencv/opencv_3rdparty.git;branch=contrib_xfeatures2d_vgg_20160317;destsuffix=vgg;name=vgg \
-    https://github.com/tiny-dnn/tiny-dnn/archive/v1.0.0a3.tar.gz;destsuffix=git/3rdparty/tinydnn/tiny-dnn-1.0.0a3;name=tinydnn;unpack=false \
-    file://0001-3rdparty-ippicv-Use-pre-downloaded-ipp.patch \
-    file://fixpkgconfig.patch \
-    file://uselocalxfeatures.patch;patchdir=../contrib/ \
-    file://tinydnn.patch;patchdir=../contrib/ \
-    file://0002-Make-opencv-ts-create-share-library-intead-of-static.patch \
-    file://0003-To-fix-errors-as-following.patch \
-    file://0001-build-workaround-GCC-7.1.1-compilation-issue-with-sa.patch \
-    file://0002-imgcodecs-refactoring-improve-code-quality.patch \
-    file://0003-imgproc-test-add-checks-for-remove-call.patch \
-    file://0001-Dont-use-isystem.patch \
-    file://0001-carotene-don-t-use-__asm__-with-aarch64.patch \
-    file://0002-Do-not-enable-asm-with-clang.patch \
-    file://CVE-2017-14136.patch \
-    file://javagen.patch \
-    file://protobuf.patch \
-    file://already-exists.patch \
-"
-PV = "3.3+git${SRCPV}"
-
-S = "${WORKDIR}/git"
-
-do_unpack_extra() {
-    mkdir -p ${S}/3rdparty/tinydnn/
-    tar xzf ${WORKDIR}/v1.0.0a3.tar.gz -C ${S}/3rdparty/tinydnn/
-    tar xzf ${WORKDIR}/ipp/ippicv/${IPP_FILENAME} -C ${WORKDIR}
-    cp ${WORKDIR}/vgg/*.i ${WORKDIR}/contrib/modules/xfeatures2d/src
-    cp ${WORKDIR}/boostdesc/*.i ${WORKDIR}/contrib/modules/xfeatures2d/src
-}
-addtask unpack_extra after do_unpack before do_patch
-
-EXTRA_OECMAKE = "-DOPENCV_EXTRA_MODULES_PATH=${WORKDIR}/contrib/modules \
-    -DWITH_1394=OFF \
-    -DCMAKE_SKIP_RPATH=ON \
-    -DOPENCV_ICV_HASH=${IPP_MD5} \
-    -DIPPROOT=${WORKDIR}/ippicv_lnx \
-    ${@bb.utils.contains("TARGET_CC_ARCH", "-msse3", "-DENABLE_SSE=1 -DENABLE_SSE2=1 -DENABLE_SSE3=1 -DENABLE_SSSE3=1", "", d)} \
-    ${@bb.utils.contains("TARGET_CC_ARCH", "-msse4.1", "-DENABLE_SSE=1 -DENABLE_SSE2=1 -DENABLE_SSE3=1 -DENABLE_SSSE3=1 -DENABLE_SSE41=1", "", d)} \
-    ${@bb.utils.contains("TARGET_CC_ARCH", "-msse4.2", "-DENABLE_SSE=1 -DENABLE_SSE2=1 -DENABLE_SSE3=1 -DENABLE_SSSE3=1 -DENABLE_SSE41=1 -DENABLE_SSE42=1", "", d)} \
-    ${@oe.utils.conditional("libdir", "/usr/lib64", "-DLIB_SUFFIX=64", "", d)} \
-    ${@oe.utils.conditional("libdir", "/usr/lib32", "-DLIB_SUFFIX=32", "", d)} \
-"
-EXTRA_OECMAKE_append_x86 = " -DX86=ON"
-
-PACKAGECONFIG ??= "python3 eigen jpeg png tiff v4l libv4l gstreamer samples tbb gphoto2 \
-    ${@bb.utils.contains("DISTRO_FEATURES", "x11", "gtk", "", d)} \
-    ${@bb.utils.contains("LICENSE_FLAGS_WHITELIST", "commercial", "libav", "", d)}"
-
-PACKAGECONFIG[amdblas] = "-DWITH_OPENCLAMDBLAS=ON,-DWITH_OPENCLAMDBLAS=OFF,libclamdblas,"
-PACKAGECONFIG[amdfft] = "-DWITH_OPENCLAMDFFT=ON,-DWITH_OPENCLAMDFFT=OFF,libclamdfft,"
-PACKAGECONFIG[dnn] = "-DBUILD_opencv_dnn=ON -DPROTOBUF_UPDATE_FILES=ON -DBUILD_PROTOBUF=OFF,-DBUILD_opencv_dnn=OFF,protobuf protobuf-native,"
-PACKAGECONFIG[eigen] = "-DWITH_EIGEN=ON,-DWITH_EIGEN=OFF,libeigen gflags glog,"
-PACKAGECONFIG[freetype] = "-DBUILD_opencv_freetype=ON,-DBUILD_opencv_freetype=OFF,freetype,"
-PACKAGECONFIG[gphoto2] = "-DWITH_GPHOTO2=ON,-DWITH_GPHOTO2=OFF,libgphoto2,"
-PACKAGECONFIG[gstreamer] = "-DWITH_GSTREAMER=ON,-DWITH_GSTREAMER=OFF,gstreamer1.0 gstreamer1.0-plugins-base,"
-PACKAGECONFIG[gtk] = "-DWITH_GTK=ON,-DWITH_GTK=OFF,gtk+3,"
-PACKAGECONFIG[jasper] = "-DWITH_JASPER=ON,-DWITH_JASPER=OFF,jasper,"
-PACKAGECONFIG[java] = "-DJAVA_INCLUDE_PATH=${JAVA_HOME}/include -DJAVA_INCLUDE_PATH2=${JAVA_HOME}/include/linux -DJAVA_AWT_INCLUDE_PATH=${JAVA_HOME}/include -DJAVA_AWT_LIBRARY=${JAVA_HOME}/lib/amd64/libjawt.so -DJAVA_JVM_LIBRARY=${JAVA_HOME}/lib/amd64/server/libjvm.so,,ant-native fastjar-native openjdk-8-native,"
-PACKAGECONFIG[jpeg] = "-DWITH_JPEG=ON,-DWITH_JPEG=OFF,jpeg,"
-PACKAGECONFIG[libav] = "-DWITH_FFMPEG=ON,-DWITH_FFMPEG=OFF,libav,"
-PACKAGECONFIG[libv4l] = "-DWITH_LIBV4L=ON,-DWITH_LIBV4L=OFF,v4l-utils,"
-PACKAGECONFIG[opencl] = "-DWITH_OPENCL=ON,-DWITH_OPENCL=OFF,opencl-headers virtual/opencl-icd,"
-PACKAGECONFIG[oracle-java] = "-DJAVA_INCLUDE_PATH=${ORACLE_JAVA_HOME}/include -DJAVA_INCLUDE_PATH2=${ORACLE_JAVA_HOME}/include/linux -DJAVA_AWT_INCLUDE_PATH=${ORACLE_JAVA_HOME}/include -DJAVA_AWT_LIBRARY=${ORACLE_JAVA_HOME}/lib/amd64/libjawt.so -DJAVA_JVM_LIBRARY=${ORACLE_JAVA_HOME}/lib/amd64/server/libjvm.so,,ant-native oracle-jse-jdk oracle-jse-jdk-native,"
-PACKAGECONFIG[png] = "-DWITH_PNG=ON,-DWITH_PNG=OFF,libpng,"
-PACKAGECONFIG[python2] = "-DPYTHON2_NUMPY_INCLUDE_DIRS:PATH=${STAGING_LIBDIR}/${PYTHON_DIR}/site-packages/numpy/core/include,,python-numpy,"
-PACKAGECONFIG[python3] = "-DPYTHON3_NUMPY_INCLUDE_DIRS:PATH=${STAGING_LIBDIR}/${PYTHON_DIR}/site-packages/numpy/core/include,,python3-numpy,"
-PACKAGECONFIG[samples] = "-DBUILD_EXAMPLES=ON -DINSTALL_PYTHON_EXAMPLES=ON,-DBUILD_EXAMPLES=OFF,,"
-PACKAGECONFIG[tbb] = "-DWITH_TBB=ON,-DWITH_TBB=OFF,tbb,"
-PACKAGECONFIG[text] = "-DBUILD_opencv_text=ON,-DBUILD_opencv_text=OFF,tesseract,"
-PACKAGECONFIG[tiff] = "-DWITH_TIFF=ON,-DWITH_TIFF=OFF,tiff,"
-PACKAGECONFIG[v4l] = "-DWITH_V4L=ON,-DWITH_V4L=OFF,v4l-utils,"
-
-inherit pkgconfig cmake
-
-inherit ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'distutils3-base', '', d)}
-inherit ${@bb.utils.contains('PACKAGECONFIG', 'python2', 'distutils-base', '', d)}
-
-export PYTHON_CSPEC="-I${STAGING_INCDIR}/${PYTHON_DIR}"
-export PYTHON="${STAGING_BINDIR_NATIVE}/${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3', 'python', d)}"
-export ORACLE_JAVA_HOME="${STAGING_DIR_NATIVE}/usr/bin/java"
-export JAVA_HOME="${STAGING_DIR_NATIVE}/usr/lib/jvm/openjdk-8-native"
-export ANT_DIR="${STAGING_DIR_NATIVE}/usr/share/ant/"
-
-TARGET_CC_ARCH += "-I${S}/include "
-
-PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'samples', '${PN}-samples', '', d)} \
-    ${@bb.utils.contains('PACKAGECONFIG', 'oracle-java', '${PN}-java', '', d)} \
-    ${@bb.utils.contains('PACKAGECONFIG', 'java', '${PN}-java', '', d)} \
-    ${@bb.utils.contains('PACKAGECONFIG', 'python2', 'python-${BPN}', '', d)} \
-    ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3-${BPN}', '', d)} \
-    ${PN}-apps"
-
-python populate_packages_prepend () {
-    cv_libdir = d.expand('${libdir}')
-    do_split_packages(d, cv_libdir, '^lib(.*)\.so$', 'lib%s-dev', 'OpenCV %s development package', extra_depends='${PN}-dev', allow_links=True)
-    do_split_packages(d, cv_libdir, '^lib(.*)\.la$', 'lib%s-dev', 'OpenCV %s development package', extra_depends='${PN}-dev')
-    do_split_packages(d, cv_libdir, '^lib(.*)\.a$', 'lib%s-dev', 'OpenCV %s development package', extra_depends='${PN}-dev')
-    do_split_packages(d, cv_libdir, '^lib(.*)\.so\.*', 'lib%s', 'OpenCV %s library', extra_depends='', allow_links=True)
-
-    pn = d.getVar('PN')
-    metapkg =  pn + '-dev'
-    d.setVar('ALLOW_EMPTY_' + metapkg, "1")
-    blacklist = [ metapkg ]
-    metapkg_rdepends = [ ]
-    packages = d.getVar('PACKAGES').split()
-    for pkg in packages[1:]:
-        if not pkg in blacklist and not pkg in metapkg_rdepends and pkg.endswith('-dev'):
-            metapkg_rdepends.append(pkg)
-    d.setVar('RRECOMMENDS_' + metapkg, ' '.join(metapkg_rdepends))
-
-    metapkg =  pn
-    d.setVar('ALLOW_EMPTY_' + metapkg, "1")
-    blacklist = [ metapkg, "libopencv-ts" ]
-    metapkg_rdepends = [ ]
-    for pkg in packages[1:]:
-        if not pkg in blacklist and not pkg in metapkg_rdepends and not pkg.endswith('-dev') and not pkg.endswith('-dbg') and not pkg.endswith('-doc') and not pkg.endswith('-locale') and not pkg.endswith('-staticdev'):
-            metapkg_rdepends.append(pkg)
-    d.setVar('RDEPENDS_' + metapkg, ' '.join(metapkg_rdepends))
-}
-
-PACKAGES_DYNAMIC += "^libopencv-.*"
-
-FILES_${PN} = ""
-FILES_${PN}-dbg += "${datadir}/OpenCV/java/.debug/* ${datadir}/OpenCV/samples/bin/.debug/*"
-FILES_${PN}-dev = "${includedir} ${libdir}/pkgconfig ${datadir}/OpenCV/*.cmake"
-FILES_${PN}-staticdev += "${datadir}/OpenCV/3rdparty/lib/*.a"
-FILES_${PN}-apps = "${bindir}/* ${datadir}/OpenCV"
-FILES_${PN}-java = "${datadir}/OpenCV/java"
-FILES_${PN}-samples = "${datadir}/OpenCV/samples/"
-
-INSANE_SKIP_${PN}-java = "libdir"
-INSANE_SKIP_${PN}-dbg = "libdir"
-
-ALLOW_EMPTY_${PN} = "1"
-
-SUMMARY_python-opencv = "Python bindings to opencv"
-FILES_python-opencv = "${PYTHON_SITEPACKAGES_DIR}/*"
-RDEPENDS_python-opencv = "python-core python-numpy"
-
-SUMMARY_python3-opencv = "Python bindings to opencv"
-FILES_python3-opencv = "${PYTHON_SITEPACKAGES_DIR}/*"
-RDEPENDS_python3-opencv = "python3-core python3-numpy"
-
-do_install_append() {
-    cp ${S}/include/opencv/*.h ${D}${includedir}/opencv/
-    sed -i '/blobtrack/d' ${D}${includedir}/opencv/cvaux.h
-
-    # Move Python files into correct library folder (for multilib build)
-    if [ "$libdir" != "/usr/lib" -a -d ${D}/usr/lib ]; then
-        mv ${D}/usr/lib/* ${D}/${libdir}/
-        rm -rf ${D}/usr/lib
-    fi
-
-    if ${@bb.utils.contains("PACKAGECONFIG", "samples", "true", "false", d)}; then
-        install -d ${D}${datadir}/OpenCV/samples/bin/
-        cp -f bin/*-tutorial-* bin/*-example-* ${D}${datadir}/OpenCV/samples/bin/
-    fi
-}
diff --git a/meta-openembedded/meta-oe/recipes-support/opencv/opencv_3.4.3.bb b/meta-openembedded/meta-oe/recipes-support/opencv/opencv_3.4.3.bb
new file mode 100644
index 0000000..0a99700
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/opencv/opencv_3.4.3.bb
@@ -0,0 +1,192 @@
+SUMMARY = "Opencv : The Open Computer Vision Library"
+HOMEPAGE = "http://opencv.org/"
+SECTION = "libs"
+
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=62d89c5dcb0583609ea919c56be0ee76"
+
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
+
+DEPENDS = "libtool swig-native bzip2 zlib glib-2.0 libwebp"
+
+SRCREV_opencv = "b38c50b3d0c31e82294315ec44b54b7ef559ef12"
+SRCREV_contrib = "1f6d6f06266e1ef336437ae5404bee1c65d42cda"
+SRCREV_ipp = "bdb7bb85f34a8cb0d35e40a81f58da431aa1557a"
+SRCREV_boostdesc = "34e4206aef44d50e6bbcd0ab06354b52e7466d26"
+SRCREV_vgg = "fccf7cd6a4b12079f73bbfb21745f9babcd4eb1d"
+SRC_URI[tinydnn.md5sum] = "adb1c512e09ca2c7a6faef36f9c53e59"
+SRC_URI[tinydnn.sha256sum] = "e2c61ce8c5debaa644121179e9dbdcf83f497f39de853f8dd5175846505aa18b"
+
+def ipp_filename(d):
+    import re
+    arch = d.getVar('TARGET_ARCH', True)
+    if re.match("i.86$", arch):
+        return "ippicv_2017u3_lnx_ia32_general_20180518.tgz"
+    else:
+        return "ippicv_2017u3_lnx_intel64_general_20180518.tgz"
+
+def ipp_md5sum(d):
+    import re
+    arch = d.getVar('TARGET_ARCH', True)
+    if re.match("i.86$", arch):
+        return "ea72de74dae3c604eb6348395366e78e"
+    else:
+        return "b7cc351267db2d34b9efa1cd22ff0572"
+
+IPP_FILENAME = "${@ipp_filename(d)}"
+IPP_MD5 = "${@ipp_md5sum(d)}"
+
+SRCREV_FORMAT = "opencv_contrib_ipp_boostdesc_vgg"
+SRC_URI = "git://github.com/opencv/opencv.git;name=opencv \
+    git://github.com/opencv/opencv_contrib.git;destsuffix=contrib;name=contrib \
+    git://github.com/opencv/opencv_3rdparty.git;branch=ippicv/master_20180518;destsuffix=ipp;name=ipp \
+    git://github.com/opencv/opencv_3rdparty.git;branch=contrib_xfeatures2d_boostdesc_20161012;destsuffix=boostdesc;name=boostdesc \
+    git://github.com/opencv/opencv_3rdparty.git;branch=contrib_xfeatures2d_vgg_20160317;destsuffix=vgg;name=vgg \
+    https://github.com/tiny-dnn/tiny-dnn/archive/v1.0.0a3.tar.gz;destsuffix=git/3rdparty/tinydnn/tiny-dnn-1.0.0a3;name=tinydnn;unpack=false \
+    file://0001-3rdparty-ippicv-Use-pre-downloaded-ipp.patch \
+    file://uselocalxfeatures.patch;patchdir=../contrib/ \
+    file://0001-Add-missing-multi-line-separator.patch;patchdir=../contrib/ \
+    file://0002-Make-opencv-ts-create-share-library-intead-of-static.patch \
+    file://0003-To-fix-errors-as-following.patch \
+    file://fixpkgconfig.patch \
+    file://0001-Temporarliy-work-around-deprecated-ffmpeg-RAW-functi.patch \
+    file://0001-Dont-use-isystem.patch \
+    file://0001-Check-for-clang-before-using-isystem.patch \
+"
+PV = "3.4.3+git${SRCPV}"
+
+S = "${WORKDIR}/git"
+
+do_unpack_extra() {
+    mkdir -p ${S}/3rdparty/tinydnn/
+    tar xzf ${WORKDIR}/v1.0.0a3.tar.gz -C ${S}/3rdparty/tinydnn/
+    tar xzf ${WORKDIR}/ipp/ippicv/${IPP_FILENAME} -C ${WORKDIR}
+    cp ${WORKDIR}/vgg/*.i ${WORKDIR}/contrib/modules/xfeatures2d/src
+    cp ${WORKDIR}/boostdesc/*.i ${WORKDIR}/contrib/modules/xfeatures2d/src
+}
+addtask unpack_extra after do_unpack before do_patch
+
+EXTRA_OECMAKE = "-DOPENCV_EXTRA_MODULES_PATH=${WORKDIR}/contrib/modules \
+    -DWITH_1394=OFF \
+    -DENABLE_PRECOMPILED_HEADERS=OFF \
+    -DCMAKE_SKIP_RPATH=ON \
+    -DOPENCV_ICV_HASH=${IPP_MD5} \
+    -DIPPROOT=${WORKDIR}/ippicv_lnx \
+    ${@bb.utils.contains("TARGET_CC_ARCH", "-msse3", "-DENABLE_SSE=1 -DENABLE_SSE2=1 -DENABLE_SSE3=1 -DENABLE_SSSE3=1", "", d)} \
+    ${@bb.utils.contains("TARGET_CC_ARCH", "-msse4.1", "-DENABLE_SSE=1 -DENABLE_SSE2=1 -DENABLE_SSE3=1 -DENABLE_SSSE3=1 -DENABLE_SSE41=1", "", d)} \
+    ${@bb.utils.contains("TARGET_CC_ARCH", "-msse4.2", "-DENABLE_SSE=1 -DENABLE_SSE2=1 -DENABLE_SSE3=1 -DENABLE_SSSE3=1 -DENABLE_SSE41=1 -DENABLE_SSE42=1", "", d)} \
+    ${@oe.utils.conditional("libdir", "/usr/lib64", "-DLIB_SUFFIX=64", "", d)} \
+    ${@oe.utils.conditional("libdir", "/usr/lib32", "-DLIB_SUFFIX=32", "", d)} \
+"
+EXTRA_OECMAKE_append_x86 = " -DX86=ON"
+
+PACKAGECONFIG ??= "python3 eigen jpeg png tiff v4l libv4l gstreamer samples tbb gphoto2 \
+    ${@bb.utils.contains("DISTRO_FEATURES", "x11", "gtk", "", d)} \
+    ${@bb.utils.contains("LICENSE_FLAGS_WHITELIST", "commercial", "libav", "", d)}"
+
+PACKAGECONFIG[amdblas] = "-DWITH_OPENCLAMDBLAS=ON,-DWITH_OPENCLAMDBLAS=OFF,libclamdblas,"
+PACKAGECONFIG[amdfft] = "-DWITH_OPENCLAMDFFT=ON,-DWITH_OPENCLAMDFFT=OFF,libclamdfft,"
+PACKAGECONFIG[dnn] = "-DBUILD_opencv_dnn=ON -DPROTOBUF_UPDATE_FILES=ON -DBUILD_PROTOBUF=OFF,-DBUILD_opencv_dnn=OFF,protobuf protobuf-native,"
+PACKAGECONFIG[eigen] = "-DWITH_EIGEN=ON,-DWITH_EIGEN=OFF,libeigen gflags glog,"
+PACKAGECONFIG[freetype] = "-DBUILD_opencv_freetype=ON,-DBUILD_opencv_freetype=OFF,freetype,"
+PACKAGECONFIG[gphoto2] = "-DWITH_GPHOTO2=ON,-DWITH_GPHOTO2=OFF,libgphoto2,"
+PACKAGECONFIG[gstreamer] = "-DWITH_GSTREAMER=ON,-DWITH_GSTREAMER=OFF,gstreamer1.0 gstreamer1.0-plugins-base,"
+PACKAGECONFIG[gtk] = "-DWITH_GTK=ON,-DWITH_GTK=OFF,gtk+3,"
+PACKAGECONFIG[jasper] = "-DWITH_JASPER=ON,-DWITH_JASPER=OFF,jasper,"
+PACKAGECONFIG[java] = "-DJAVA_INCLUDE_PATH=${JAVA_HOME}/include -DJAVA_INCLUDE_PATH2=${JAVA_HOME}/include/linux -DJAVA_AWT_INCLUDE_PATH=${JAVA_HOME}/include -DJAVA_AWT_LIBRARY=${JAVA_HOME}/lib/amd64/libjawt.so -DJAVA_JVM_LIBRARY=${JAVA_HOME}/lib/amd64/server/libjvm.so,,ant-native fastjar-native openjdk-8-native,"
+PACKAGECONFIG[jpeg] = "-DWITH_JPEG=ON,-DWITH_JPEG=OFF,jpeg,"
+PACKAGECONFIG[libav] = "-DWITH_FFMPEG=ON,-DWITH_FFMPEG=OFF,libav,"
+PACKAGECONFIG[libv4l] = "-DWITH_LIBV4L=ON,-DWITH_LIBV4L=OFF,v4l-utils,"
+PACKAGECONFIG[opencl] = "-DWITH_OPENCL=ON,-DWITH_OPENCL=OFF,opencl-headers virtual/opencl-icd,"
+PACKAGECONFIG[oracle-java] = "-DJAVA_INCLUDE_PATH=${ORACLE_JAVA_HOME}/include -DJAVA_INCLUDE_PATH2=${ORACLE_JAVA_HOME}/include/linux -DJAVA_AWT_INCLUDE_PATH=${ORACLE_JAVA_HOME}/include -DJAVA_AWT_LIBRARY=${ORACLE_JAVA_HOME}/lib/amd64/libjawt.so -DJAVA_JVM_LIBRARY=${ORACLE_JAVA_HOME}/lib/amd64/server/libjvm.so,,ant-native oracle-jse-jdk oracle-jse-jdk-native,"
+PACKAGECONFIG[png] = "-DWITH_PNG=ON,-DWITH_PNG=OFF,libpng,"
+PACKAGECONFIG[python2] = "-DPYTHON2_NUMPY_INCLUDE_DIRS:PATH=${STAGING_LIBDIR}/${PYTHON_DIR}/site-packages/numpy/core/include,,python-numpy,"
+PACKAGECONFIG[python3] = "-DPYTHON3_NUMPY_INCLUDE_DIRS:PATH=${STAGING_LIBDIR}/${PYTHON_DIR}/site-packages/numpy/core/include,,python3-numpy,"
+PACKAGECONFIG[samples] = "-DBUILD_EXAMPLES=ON -DINSTALL_PYTHON_EXAMPLES=ON,-DBUILD_EXAMPLES=OFF,,"
+PACKAGECONFIG[tbb] = "-DWITH_TBB=ON,-DWITH_TBB=OFF,tbb,"
+PACKAGECONFIG[text] = "-DBUILD_opencv_text=ON,-DBUILD_opencv_text=OFF,tesseract,"
+PACKAGECONFIG[tiff] = "-DWITH_TIFF=ON,-DWITH_TIFF=OFF,tiff,"
+PACKAGECONFIG[v4l] = "-DWITH_V4L=ON,-DWITH_V4L=OFF,v4l-utils,"
+
+inherit pkgconfig cmake
+
+inherit ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'distutils3-base', '', d)}
+inherit ${@bb.utils.contains('PACKAGECONFIG', 'python2', 'distutils-base', '', d)}
+
+export PYTHON_CSPEC="-I${STAGING_INCDIR}/${PYTHON_DIR}"
+export PYTHON="${STAGING_BINDIR_NATIVE}/${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3', 'python', d)}"
+export ORACLE_JAVA_HOME="${STAGING_DIR_NATIVE}/usr/bin/java"
+export JAVA_HOME="${STAGING_DIR_NATIVE}/usr/lib/jvm/openjdk-8-native"
+export ANT_DIR="${STAGING_DIR_NATIVE}/usr/share/ant/"
+
+TARGET_CC_ARCH += "-I${S}/include "
+
+PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'samples', '${PN}-samples', '', d)} \
+    ${@bb.utils.contains('PACKAGECONFIG', 'oracle-java', '${PN}-java', '', d)} \
+    ${@bb.utils.contains('PACKAGECONFIG', 'java', '${PN}-java', '', d)} \
+    ${@bb.utils.contains('PACKAGECONFIG', 'python2', 'python-${BPN}', '', d)} \
+    ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3-${BPN}', '', d)} \
+    ${PN}-apps"
+
+python populate_packages_prepend () {
+    cv_libdir = d.expand('${libdir}')
+    do_split_packages(d, cv_libdir, '^lib(.*)\.so$', 'lib%s-dev', 'OpenCV %s development package', extra_depends='${PN}-dev', allow_links=True)
+    do_split_packages(d, cv_libdir, '^lib(.*)\.la$', 'lib%s-dev', 'OpenCV %s development package', extra_depends='${PN}-dev')
+    do_split_packages(d, cv_libdir, '^lib(.*)\.a$', 'lib%s-dev', 'OpenCV %s development package', extra_depends='${PN}-dev')
+    do_split_packages(d, cv_libdir, '^lib(.*)\.so\.*', 'lib%s', 'OpenCV %s library', extra_depends='', allow_links=True)
+
+    pn = d.getVar('PN')
+    metapkg =  pn + '-dev'
+    d.setVar('ALLOW_EMPTY_' + metapkg, "1")
+    blacklist = [ metapkg ]
+    metapkg_rdepends = [ ]
+    packages = d.getVar('PACKAGES').split()
+    for pkg in packages[1:]:
+        if not pkg in blacklist and not pkg in metapkg_rdepends and pkg.endswith('-dev'):
+            metapkg_rdepends.append(pkg)
+    d.setVar('RRECOMMENDS_' + metapkg, ' '.join(metapkg_rdepends))
+
+    metapkg =  pn
+    d.setVar('ALLOW_EMPTY_' + metapkg, "1")
+    blacklist = [ metapkg, "libopencv-ts" ]
+    metapkg_rdepends = [ ]
+    for pkg in packages[1:]:
+        if not pkg in blacklist and not pkg in metapkg_rdepends and not pkg.endswith('-dev') and not pkg.endswith('-dbg') and not pkg.endswith('-doc') and not pkg.endswith('-locale') and not pkg.endswith('-staticdev'):
+            metapkg_rdepends.append(pkg)
+    d.setVar('RDEPENDS_' + metapkg, ' '.join(metapkg_rdepends))
+}
+
+PACKAGES_DYNAMIC += "^libopencv-.*"
+
+FILES_${PN} = ""
+FILES_${PN}-dbg += "${datadir}/OpenCV/java/.debug/* ${datadir}/OpenCV/samples/bin/.debug/*"
+FILES_${PN}-dev = "${includedir} ${libdir}/pkgconfig ${datadir}/OpenCV/*.cmake"
+FILES_${PN}-staticdev += "${datadir}/OpenCV/3rdparty/lib/*.a"
+FILES_${PN}-apps = "${bindir}/* ${datadir}/OpenCV"
+FILES_${PN}-java = "${datadir}/OpenCV/java"
+FILES_${PN}-samples = "${datadir}/OpenCV/samples/"
+
+INSANE_SKIP_${PN}-java = "libdir"
+INSANE_SKIP_${PN}-dbg = "libdir"
+
+ALLOW_EMPTY_${PN} = "1"
+
+SUMMARY_python-opencv = "Python bindings to opencv"
+FILES_python-opencv = "${PYTHON_SITEPACKAGES_DIR}/*"
+RDEPENDS_python-opencv = "python-core python-numpy"
+
+SUMMARY_python3-opencv = "Python bindings to opencv"
+FILES_python3-opencv = "${PYTHON_SITEPACKAGES_DIR}/*"
+RDEPENDS_python3-opencv = "python3-core python3-numpy"
+
+do_install_append() {
+    cp ${S}/include/opencv/*.h ${D}${includedir}/opencv/
+    sed -i '/blobtrack/d' ${D}${includedir}/opencv/cvaux.h
+
+    # Move Python files into correct library folder (for multilib build)
+    if [ "$libdir" != "/usr/lib" -a -d ${D}/usr/lib ]; then
+        mv ${D}/usr/lib/* ${D}/${libdir}/
+        rm -rf ${D}/usr/lib
+    fi
+}
diff --git a/meta-openembedded/meta-oe/recipes-support/openldap/openldap/install-strip.patch b/meta-openembedded/meta-oe/recipes-support/openldap/openldap/install-strip.patch
index 2992b70..7c67596 100644
--- a/meta-openembedded/meta-oe/recipes-support/openldap/openldap/install-strip.patch
+++ b/meta-openembedded/meta-oe/recipes-support/openldap/openldap/install-strip.patch
@@ -1,6 +1,9 @@
 # This patch ensures that the install operations which strip
 # programs and libraries (LTINSTALL) work in a cross build
 # environment.
+
+Upstream-Status: Pending
+
 --- openldap-2.2.24/.pc/install-strip.patch/build/top.mk	2005-01-20 09:00:55.000000000 -0800
 +++ openldap-2.2.24/build/top.mk	2005-04-16 13:48:20.536710376 -0700
 @@ -116,7 +116,7 @@
diff --git a/meta-openembedded/meta-oe/recipes-support/openldap/openldap/kill-icu.patch b/meta-openembedded/meta-oe/recipes-support/openldap/openldap/kill-icu.patch
index dcf5411..35e4646 100644
--- a/meta-openembedded/meta-oe/recipes-support/openldap/openldap/kill-icu.patch
+++ b/meta-openembedded/meta-oe/recipes-support/openldap/openldap/kill-icu.patch
@@ -2,7 +2,7 @@
 
 slapd depends on ICU if it was built first.
 
-Upstream-status: inappropiate [embedded specific]
+Upstream-Status: inappropiate [embedded specific]
 ---
  configure.in |    8 --------
  1 file changed, 8 deletions(-)
diff --git a/meta-openembedded/meta-oe/recipes-support/openldap/openldap/openldap-2.4.28-gnutls-gcrypt.patch b/meta-openembedded/meta-oe/recipes-support/openldap/openldap/openldap-2.4.28-gnutls-gcrypt.patch
index c7b1552..86d0767 100644
--- a/meta-openembedded/meta-oe/recipes-support/openldap/openldap/openldap-2.4.28-gnutls-gcrypt.patch
+++ b/meta-openembedded/meta-oe/recipes-support/openldap/openldap/openldap-2.4.28-gnutls-gcrypt.patch
@@ -1,6 +1,6 @@
 From http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/net-nds/openldap/files/
 
-Upstream-status: Unknown
+Upstream-status: Pending
 
 --
 
diff --git a/meta-openembedded/meta-oe/recipes-support/openldap/openldap/openldap-CVE-2015-3276.patch b/meta-openembedded/meta-oe/recipes-support/openldap/openldap/openldap-CVE-2015-3276.patch
index de9ca52..25e148e 100644
--- a/meta-openembedded/meta-oe/recipes-support/openldap/openldap/openldap-CVE-2015-3276.patch
+++ b/meta-openembedded/meta-oe/recipes-support/openldap/openldap/openldap-CVE-2015-3276.patch
@@ -10,6 +10,8 @@
 be used and allow remote attackers to have unspecified impact via
 unknown vectors.
 
+Upstream-Status: Pending
+
 Signed-off-by: Li Wang <li.wang@windriver.com>
 ---
  libraries/libldap/tls_m.c |   27 ++++++++++++++++-----------
diff --git a/meta-openembedded/meta-oe/recipes-support/openldap/openldap/openldap-m4-pthread.patch b/meta-openembedded/meta-oe/recipes-support/openldap/openldap/openldap-m4-pthread.patch
index b669b72..38c0a5a 100644
--- a/meta-openembedded/meta-oe/recipes-support/openldap/openldap/openldap-m4-pthread.patch
+++ b/meta-openembedded/meta-oe/recipes-support/openldap/openldap/openldap-m4-pthread.patch
@@ -1,3 +1,5 @@
+Upstream-Status: Pending
+
 --- openldap-2.3.11/build/openldap.m4.orig	2005-11-11 00:11:18.604322590 -0800
 +++ openldap-2.3.11/build/openldap.m4	2005-11-11 00:26:21.621145856 -0800
 @@ -788,7 +788,7 @@ AC_DEFUN([OL_PTHREAD_TEST_FUNCTION],[[
diff --git a/meta-openembedded/meta-oe/recipes-support/openldap/openldap/remove-user-host-pwd-from-version.patch b/meta-openembedded/meta-oe/recipes-support/openldap/openldap/remove-user-host-pwd-from-version.patch
new file mode 100644
index 0000000..4eb3897
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/openldap/openldap/remove-user-host-pwd-from-version.patch
@@ -0,0 +1,29 @@
+diff -ru openldap-2.4.46.orig/build/mkversion openldap-2.4.46/build/mkversion
+--- openldap-2.4.46.orig/build/mkversion	2018-10-25 18:46:10.383750480 +1300
++++ openldap-2.4.46/build/mkversion	2018-10-25 18:46:33.156232586 +1300
+@@ -50,7 +50,15 @@
+ fi
+ 
+ APPLICATION=$1
+-WHOWHERE="$USER@`uname -n`:`pwd`"
++if [ -n "${SOURCE_DATE_EPOCH}" ]; then
++   WHOWHERE="openldap"
++   DATE=$(date -d@$SOURCE_DATE_EPOCH +' %b %d %Y ')
++   TIME=$(date -d@$SOURCE_DATE_EPOCH +' %H:%M:%S ')
++else
++   WHOWHERE="$USER@$(uname -n):$(pwd)"
++   DATE='" __DATE__ "'
++   TIME='" __TIME__ "'
++fi
+ 
+ cat << __EOF__
+ /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
+@@ -72,7 +80,7 @@
+ "COPYING RESTRICTIONS APPLY\n";
+ 
+ $static $const char $SYMBOL[] =
+-"@(#) \$$PACKAGE: $APPLICATION $VERSION (" __DATE__ " " __TIME__ ") \$\n"
++"@(#) \$$PACKAGE: $APPLICATION $VERSION ($DATE $TIME) \$\n"
+ "\t$WHOWHERE\n";
+ 
+ __EOF__
diff --git a/meta-openembedded/meta-oe/recipes-support/openldap/openldap_2.4.45.bb b/meta-openembedded/meta-oe/recipes-support/openldap/openldap_2.4.45.bb
deleted file mode 100644
index 82d6619..0000000
--- a/meta-openembedded/meta-oe/recipes-support/openldap/openldap_2.4.45.bb
+++ /dev/null
@@ -1,256 +0,0 @@
-# OpenLDAP, a license free (see http://www.OpenLDAP.org/license.html)
-#
-SUMMARY = "OpenLDAP Directory Service"
-DESCRIPTION = "OpenLDAP Software is an open source implementation of the Lightweight Directory Access Protocol."
-HOMEPAGE = "http://www.OpenLDAP.org/license.html"
-# The OpenLDAP Public License - see the HOMEPAGE - defines
-# the license.  www.openldap.org claims this is Open Source
-# (see http://www.openldap.org), the license appears to be
-# basically BSD.  opensource.org does not record this license
-# at present (so it is apparently not OSI certified).
-LICENSE = "OpenLDAP"
-LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=25fd3721960f39128cd15a749fd21139 \
-                    file://LICENSE;md5=153d07ef052c4a37a8fac23bc6031972 \
-"
-SECTION = "libs"
-
-LDAP_VER = "${@'.'.join(d.getVar('PV').split('.')[0:2])}"
-
-SRC_URI = "ftp://ftp.openldap.org/pub/OpenLDAP/openldap-release/${BP}.tgz \
-    file://openldap-m4-pthread.patch \
-    file://kill-icu.patch \
-    file://openldap-2.4.28-gnutls-gcrypt.patch \
-    file://use-urandom.patch \
-    file://initscript \
-    file://slapd.service \
-    file://thread_stub.patch \
-    file://openldap-CVE-2015-3276.patch \
-"
-
-SRC_URI[md5sum] = "00ff8301277cdfd0af728a6927042a13"
-SRC_URI[sha256sum] = "cdd6cffdebcd95161a73305ec13fc7a78e9707b46ca9f84fb897cd5626df3824"
-
-DEPENDS = "util-linux groff-native"
-
-# The original top.mk used INSTALL, not INSTALL_STRIP_PROGRAM when
-# installing .so and executables, this fails in cross compilation
-# environments
-SRC_URI += "file://install-strip.patch"
-
-inherit autotools-brokensep update-rc.d systemd
-
-# CV SETTINGS
-# Required to work round AC_FUNC_MEMCMP which gets the wrong answer
-# when cross compiling (should be in site?)
-EXTRA_OECONF += "ac_cv_func_memcmp_working=yes"
-
-# CONFIG DEFINITIONS
-# The following is necessary because it cannot be determined for a
-# cross compile automagically.  Select should yield fine on all OE
-# systems...
-EXTRA_OECONF += "--with-yielding-select=yes"
-# Shared libraries are nice...
-EXTRA_OECONF += "--enable-dynamic"
-
-PACKAGECONFIG ??= "gnutls modules \
-                   mdb ldap meta monitor null passwd shell proxycache dnssrv \
-                   ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} \
-"
-#--with-tls              with TLS/SSL support auto|openssl|gnutls [auto]
-PACKAGECONFIG[gnutls] = "--with-tls=gnutls,,gnutls libgcrypt"
-PACKAGECONFIG[openssl] = "--with-tls=openssl,,openssl"
-
-PACKAGECONFIG[sasl] = "--with-cyrus-sasl,--without-cyrus-sasl,cyrus-sasl"
-PACKAGECONFIG[modules] = "lt_cv_dlopen_self=yes --enable-modules,--disable-modules,libtool"
-PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6"
-
-# SLAPD options
-#
-# UNIX crypt(3) passwd support:
-EXTRA_OECONF += "--enable-crypt"
-
-# SLAPD BACKEND
-#
-# The backend must be set by the configuration.  This controls the
-# required database.
-#
-# Backends="bdb dnssrv hdb ldap mdb meta monitor ndb null passwd perl relay shell sock sql"
-#
-# Note that multiple backends can be built.  The ldbm backend requires a
-# build-time choice of database API.  The bdb backend forces this to be
-# DB4.  To use the gdbm (or other) API the Berkely database module must
-# be removed from the build.
-md = "${libexecdir}/openldap"
-#
-#--enable-bdb          enable Berkeley DB backend no|yes|mod yes
-# The Berkely DB is the standard choice.  This version of OpenLDAP requires
-# the version 4 implementation or better.
-PACKAGECONFIG[bdb] = "--enable-bdb=yes,--enable-bdb=no,db"
-
-#--enable-dnssrv       enable dnssrv backend no|yes|mod no
-PACKAGECONFIG[dnssrv] = "--enable-dnssrv=mod,--enable-dnssrv=no"
-
-#--enable-hdb          enable Hierarchical DB backend no|yes|mod no
-PACKAGECONFIG[hdb] = "--enable-hdb=yes,--enable-hdb=no,db"
-
-#--enable-ldap         enable ldap backend no|yes|mod no
-PACKAGECONFIG[ldap] = "--enable-ldap=mod,--enable-ldap=no,"
-
-#--enable-mdb          enable mdb database backend no|yes|mod [yes]
-PACKAGECONFIG[mdb] = "--enable-mdb=yes,--enable-mdb=no,"
-
-#--enable-meta         enable metadirectory backend no|yes|mod no
-PACKAGECONFIG[meta] = "--enable-meta=mod,--enable-meta=no,"
-
-#--enable-monitor      enable monitor backend no|yes|mod yes
-PACKAGECONFIG[monitor] = "--enable-monitor=mod,--enable-monitor=no,"
-
-#--enable-ndb          enable MySQL NDB Cluster backend no|yes|mod [no]
-PACKAGECONFIG[ndb] = "--enable-ndb=mod,--enable-ndb=no,"
-
-#--enable-null         enable null backend no|yes|mod no
-PACKAGECONFIG[null] = "--enable-null=mod,--enable-null=no,"
-
-#--enable-passwd       enable passwd backend no|yes|mod no
-PACKAGECONFIG[passwd] = "--enable-passwd=mod,--enable-passwd=no,"
-
-#--enable-perl         enable perl backend no|yes|mod no
-#  This requires a loadable perl dynamic library, if enabled without
-#  doing something appropriate (building perl?) the build will pick
-#  up the build machine perl - not good (inherit perlnative?)
-PACKAGECONFIG[perl] = "--enable-perl=mod,--enable-perl=no,perl"
-
-#--enable-relay        enable relay backend no|yes|mod [yes]
-PACKAGECONFIG[relay] = "--enable-relay=mod,--enable-relay=no,"
-
-#--enable-shell        enable shell backend no|yes|mod no
-# configure: WARNING: Use of --without-threads is recommended with back-shell
-PACKAGECONFIG[shell] = "--enable-shell=mod --without-threads,--enable-shell=no,"
-
-#--enable-sock         enable sock backend no|yes|mod [no]
-PACKAGECONFIG[sock] = "--enable-sock=mod,--enable-sock=no,"
-
-#--enable-sql          enable sql backend no|yes|mod no
-# sql requires some sql backend which provides sql.h, sqlite* provides
-# sqlite.h (which may be compatible but hasn't been tried.)
-PACKAGECONFIG[sql] = "--enable-sql=mod,--enable-sql=no,sqlite3"
-
-#--enable-dyngroup     Dynamic Group overlay no|yes|mod no
-#  This is a demo, Proxy Cache defines init_module which conflicts with the
-#  same symbol in dyngroup
-PACKAGECONFIG[dyngroup] = "--enable-dyngroup=mod,--enable-dyngroup=no,"
-
-#--enable-proxycache   Proxy Cache overlay no|yes|mod no
-PACKAGECONFIG[proxycache] = "--enable-proxycache=mod,--enable-proxycache=no,"
-FILES_${PN}-overlay-proxycache = "${md}/pcache-*.so.*"
-PACKAGES += "${PN}-overlay-proxycache"
-
-# Append URANDOM_DEVICE='/dev/urandom' to CPPFLAGS:
-# This allows tls to obtain random bits from /dev/urandom, by default
-# it was disabled for cross-compiling.
-CPPFLAGS_append = " -D_GNU_SOURCE -DURANDOM_DEVICE=\'/dev/urandom\' -fPIC"
-
-LDFLAGS_append = " -pthread"
-
-do_configure() {
-    cp ${STAGING_DATADIR_NATIVE}/libtool/build-aux/ltmain.sh ${S}/build
-    rm -f ${S}/libtool
-    aclocal
-    libtoolize --force --copy
-    gnu-configize
-    autoconf
-    oe_runconf
-}
-
-LEAD_SONAME = "libldap-${LDAP_VER}.so.*"
-
-# The executables go in a separate package.  This allows the
-# installation of the libraries with no daemon support.
-# Each module also has its own package - see above.
-PACKAGES += "${PN}-slapd ${PN}-slurpd ${PN}-bin"
-
-# Package contents - shift most standard contents to -bin
-FILES_${PN} = "${libdir}/lib*.so.* ${sysconfdir}/openldap/ldap.* ${localstatedir}/${BPN}/data"
-FILES_${PN}-slapd = "${sysconfdir}/init.d ${libexecdir}/slapd ${sbindir} ${localstatedir}/run ${localstatedir}/volatile/run \
-    ${sysconfdir}/openldap/slapd.* ${sysconfdir}/openldap/schema \
-    ${sysconfdir}/openldap/DB_CONFIG.example ${systemd_unitdir}/system/*"
-FILES_${PN}-slurpd = "${libexecdir}/slurpd ${localstatedir}/openldap-slurp ${localstatedir}/run ${localstatedir}/volatile/run"
-FILES_${PN}-bin = "${bindir}"
-FILES_${PN}-dev = "${includedir} ${libdir}/lib*.so ${libdir}/*.la ${libdir}/*.a ${libexecdir}/openldap/*.a ${libexecdir}/openldap/*.la ${libexecdir}/openldap/*.so"
-FILES_${PN}-dbg += "${libexecdir}/openldap/.debug"
-
-do_install_append() {
-    install -d ${D}${sysconfdir}/init.d
-    cat ${WORKDIR}/initscript > ${D}${sysconfdir}/init.d/openldap
-    chmod 755 ${D}${sysconfdir}/init.d/openldap
-    # This is duplicated in /etc/openldap and is for slapd
-    rm -f ${D}${localstatedir}/openldap-data/DB_CONFIG.example
-
-    # Installing slapd under ${sbin} is more FHS and LSB compliance
-    mv ${D}${libexecdir}/slapd ${D}/${sbindir}/slapd
-    rmdir --ignore-fail-on-non-empty ${D}${libexecdir}
-    SLAPTOOLS="slapadd slapcat slapdn slapindex slappasswd slaptest slapauth slapacl slapschema"
-    cd ${D}/${sbindir}/
-    rm -f ${SLAPTOOLS}
-    for i in ${SLAPTOOLS}; do ln -sf slapd $i; done
-
-    rmdir "${D}${localstatedir}/run"
-    rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
-
-    install -d ${D}${systemd_unitdir}/system/
-    install -m 0644 ${WORKDIR}/slapd.service ${D}${systemd_unitdir}/system/
-    sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/*.service
-
-    # Uses mdm as the database
-    #  and localstatedir as data directory ...
-    sed -e 's/# modulepath/modulepath/' \
-        -e 's/# moduleload\s*back_bdb.*/moduleload    back_mdb/' \
-        -e 's/database\s*bdb/database        mdb/' \
-        -e 's%^directory\s*.*%directory   ${localstatedir}/${BPN}/data/%' \
-        -i ${D}${sysconfdir}/openldap/slapd.conf
-
-    mkdir -p ${D}${localstatedir}/${BPN}/data
-
-
-}
-
-INITSCRIPT_PACKAGES = "${PN}-slapd"
-INITSCRIPT_NAME_${PN}-slapd = "openldap"
-INITSCRIPT_PARAMS_${PN}-slapd = "defaults"
-SYSTEMD_SERVICE_${PN}-slapd = "hostapd.service"
-SYSTEMD_AUTO_ENABLE_${PN}-slapd ?= "disable"
-
-
-PACKAGES_DYNAMIC += "^${PN}-backends.* ^${PN}-backend-.*"
-
-# The modules require their .so to be dynamicaly loaded
-INSANE_SKIP_${PN}-backend-dnssrv  += "dev-so"
-INSANE_SKIP_${PN}-backend-ldap    += "dev-so"
-INSANE_SKIP_${PN}-backend-meta    += "dev-so"
-INSANE_SKIP_${PN}-backend-mdb     += "dev-so"
-INSANE_SKIP_${PN}-backend-monitor += "dev-so"
-INSANE_SKIP_${PN}-backend-null    += "dev-so"
-INSANE_SKIP_${PN}-backend-passwd  += "dev-so"
-INSANE_SKIP_${PN}-backend-shell   += "dev-so"
-
-
-python populate_packages_prepend () {
-    backend_dir    = d.expand('${libexecdir}/openldap')
-    do_split_packages(d, backend_dir, 'back_([a-z]*)\.so$', 'openldap-backend-%s', 'OpenLDAP %s backend', prepend=True, extra_depends='', allow_links=True)
-    do_split_packages(d, backend_dir, 'back_([a-z]*)\-.*\.so\..*$', 'openldap-backend-%s', 'OpenLDAP %s backend', extra_depends='', allow_links=True)
-
-    metapkg = "${PN}-backends"
-    d.setVar('ALLOW_EMPTY_' + metapkg, "1")
-    d.setVar('FILES_' + metapkg, "")
-    metapkg_rdepends = []
-    packages = d.getVar('PACKAGES').split()
-    for pkg in packages[1:]:
-        if pkg.count("openldap-backend-") and not pkg in metapkg_rdepends and not pkg.count("-dev") and not pkg.count("-dbg") and not pkg.count("static") and not pkg.count("locale"):
-            metapkg_rdepends.append(pkg)
-    d.setVar('RDEPENDS_' + metapkg, ' '.join(metapkg_rdepends))
-    d.setVar('DESCRIPTION_' + metapkg, 'OpenLDAP backends meta package')
-    packages.append(metapkg)
-    d.setVar('PACKAGES', ' '.join(packages))
-}
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-support/openldap/openldap_2.4.46.bb b/meta-openembedded/meta-oe/recipes-support/openldap/openldap_2.4.46.bb
new file mode 100644
index 0000000..7fe9fb0
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/openldap/openldap_2.4.46.bb
@@ -0,0 +1,255 @@
+SUMMARY = "OpenLDAP Directory Service"
+DESCRIPTION = "OpenLDAP Software is an open source implementation of the Lightweight Directory Access Protocol."
+HOMEPAGE = "http://www.OpenLDAP.org/license.html"
+# The OpenLDAP Public License - see the HOMEPAGE - defines
+# the license.  www.openldap.org claims this is Open Source
+# (see http://www.openldap.org), the license appears to be
+# basically BSD.  opensource.org does not record this license
+# at present (so it is apparently not OSI certified).
+LICENSE = "OpenLDAP"
+LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=25b4ead0e45182e7c2914e59ff57009f \
+                    file://LICENSE;md5=153d07ef052c4a37a8fac23bc6031972 \
+                    "
+SECTION = "libs"
+
+LDAP_VER = "${@'.'.join(d.getVar('PV').split('.')[0:2])}"
+
+SRC_URI = "ftp://ftp.openldap.org/pub/OpenLDAP/openldap-release/${BP}.tgz \
+    file://openldap-m4-pthread.patch \
+    file://kill-icu.patch \
+    file://openldap-2.4.28-gnutls-gcrypt.patch \
+    file://use-urandom.patch \
+    file://initscript \
+    file://slapd.service \
+    file://thread_stub.patch \
+    file://openldap-CVE-2015-3276.patch \
+    file://remove-user-host-pwd-from-version.patch \
+"
+
+SRC_URI[md5sum] = "829016c5a9f45c51adc50073ac6f9fd7"
+SRC_URI[sha256sum] = "9a90dcb86b99ae790ccab93b7585a31fbcbeec8c94bf0f7ab0ca0a87ea0c4b2d"
+
+DEPENDS = "util-linux groff-native"
+
+# The original top.mk used INSTALL, not INSTALL_STRIP_PROGRAM when
+# installing .so and executables, this fails in cross compilation
+# environments
+SRC_URI += "file://install-strip.patch"
+
+inherit autotools-brokensep update-rc.d systemd
+
+# CV SETTINGS
+# Required to work round AC_FUNC_MEMCMP which gets the wrong answer
+# when cross compiling (should be in site?)
+EXTRA_OECONF += "ac_cv_func_memcmp_working=yes"
+
+# CONFIG DEFINITIONS
+# The following is necessary because it cannot be determined for a
+# cross compile automagically.  Select should yield fine on all OE
+# systems...
+EXTRA_OECONF += "--with-yielding-select=yes"
+# Shared libraries are nice...
+EXTRA_OECONF += "--enable-dynamic"
+
+PACKAGECONFIG ??= "gnutls modules \
+                   mdb ldap meta monitor null passwd shell proxycache dnssrv \
+                   ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} \
+"
+#--with-tls              with TLS/SSL support auto|openssl|gnutls [auto]
+PACKAGECONFIG[gnutls] = "--with-tls=gnutls,,gnutls libgcrypt"
+PACKAGECONFIG[openssl] = "--with-tls=openssl,,openssl"
+
+PACKAGECONFIG[sasl] = "--with-cyrus-sasl,--without-cyrus-sasl,cyrus-sasl"
+PACKAGECONFIG[modules] = "lt_cv_dlopen_self=yes --enable-modules,--disable-modules,libtool"
+PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6"
+
+# SLAPD options
+#
+# UNIX crypt(3) passwd support:
+EXTRA_OECONF += "--enable-crypt"
+
+# SLAPD BACKEND
+#
+# The backend must be set by the configuration.  This controls the
+# required database.
+#
+# Backends="bdb dnssrv hdb ldap mdb meta monitor ndb null passwd perl relay shell sock sql"
+#
+# Note that multiple backends can be built.  The ldbm backend requires a
+# build-time choice of database API.  The bdb backend forces this to be
+# DB4.  To use the gdbm (or other) API the Berkely database module must
+# be removed from the build.
+md = "${libexecdir}/openldap"
+#
+#--enable-bdb          enable Berkeley DB backend no|yes|mod yes
+# The Berkely DB is the standard choice.  This version of OpenLDAP requires
+# the version 4 implementation or better.
+PACKAGECONFIG[bdb] = "--enable-bdb=yes,--enable-bdb=no,db"
+
+#--enable-dnssrv       enable dnssrv backend no|yes|mod no
+PACKAGECONFIG[dnssrv] = "--enable-dnssrv=mod,--enable-dnssrv=no"
+
+#--enable-hdb          enable Hierarchical DB backend no|yes|mod no
+PACKAGECONFIG[hdb] = "--enable-hdb=yes,--enable-hdb=no,db"
+
+#--enable-ldap         enable ldap backend no|yes|mod no
+PACKAGECONFIG[ldap] = "--enable-ldap=mod,--enable-ldap=no,"
+
+#--enable-mdb          enable mdb database backend no|yes|mod [yes]
+PACKAGECONFIG[mdb] = "--enable-mdb=yes,--enable-mdb=no,"
+
+#--enable-meta         enable metadirectory backend no|yes|mod no
+PACKAGECONFIG[meta] = "--enable-meta=mod,--enable-meta=no,"
+
+#--enable-monitor      enable monitor backend no|yes|mod yes
+PACKAGECONFIG[monitor] = "--enable-monitor=mod,--enable-monitor=no,"
+
+#--enable-ndb          enable MySQL NDB Cluster backend no|yes|mod [no]
+PACKAGECONFIG[ndb] = "--enable-ndb=mod,--enable-ndb=no,"
+
+#--enable-null         enable null backend no|yes|mod no
+PACKAGECONFIG[null] = "--enable-null=mod,--enable-null=no,"
+
+#--enable-passwd       enable passwd backend no|yes|mod no
+PACKAGECONFIG[passwd] = "--enable-passwd=mod,--enable-passwd=no,"
+
+#--enable-perl         enable perl backend no|yes|mod no
+#  This requires a loadable perl dynamic library, if enabled without
+#  doing something appropriate (building perl?) the build will pick
+#  up the build machine perl - not good (inherit perlnative?)
+PACKAGECONFIG[perl] = "--enable-perl=mod,--enable-perl=no,perl"
+
+#--enable-relay        enable relay backend no|yes|mod [yes]
+PACKAGECONFIG[relay] = "--enable-relay=mod,--enable-relay=no,"
+
+#--enable-shell        enable shell backend no|yes|mod no
+# configure: WARNING: Use of --without-threads is recommended with back-shell
+PACKAGECONFIG[shell] = "--enable-shell=mod --without-threads,--enable-shell=no,"
+
+#--enable-sock         enable sock backend no|yes|mod [no]
+PACKAGECONFIG[sock] = "--enable-sock=mod,--enable-sock=no,"
+
+#--enable-sql          enable sql backend no|yes|mod no
+# sql requires some sql backend which provides sql.h, sqlite* provides
+# sqlite.h (which may be compatible but hasn't been tried.)
+PACKAGECONFIG[sql] = "--enable-sql=mod,--enable-sql=no,sqlite3"
+
+#--enable-dyngroup     Dynamic Group overlay no|yes|mod no
+#  This is a demo, Proxy Cache defines init_module which conflicts with the
+#  same symbol in dyngroup
+PACKAGECONFIG[dyngroup] = "--enable-dyngroup=mod,--enable-dyngroup=no,"
+
+#--enable-proxycache   Proxy Cache overlay no|yes|mod no
+PACKAGECONFIG[proxycache] = "--enable-proxycache=mod,--enable-proxycache=no,"
+FILES_${PN}-overlay-proxycache = "${md}/pcache-*.so.*"
+PACKAGES += "${PN}-overlay-proxycache"
+
+# Append URANDOM_DEVICE='/dev/urandom' to CPPFLAGS:
+# This allows tls to obtain random bits from /dev/urandom, by default
+# it was disabled for cross-compiling.
+CPPFLAGS_append = " -D_GNU_SOURCE -DURANDOM_DEVICE=\'/dev/urandom\' -fPIC"
+
+LDFLAGS_append = " -pthread"
+
+do_configure() {
+    cp ${STAGING_DATADIR_NATIVE}/libtool/build-aux/ltmain.sh ${S}/build
+    rm -f ${S}/libtool
+    aclocal
+    libtoolize --force --copy
+    gnu-configize
+    autoconf
+    oe_runconf
+}
+
+LEAD_SONAME = "libldap-${LDAP_VER}.so.*"
+
+# The executables go in a separate package.  This allows the
+# installation of the libraries with no daemon support.
+# Each module also has its own package - see above.
+PACKAGES += "${PN}-slapd ${PN}-slurpd ${PN}-bin"
+
+# Package contents - shift most standard contents to -bin
+FILES_${PN} = "${libdir}/lib*.so.* ${sysconfdir}/openldap/ldap.* ${localstatedir}/${BPN}/data"
+FILES_${PN}-slapd = "${sysconfdir}/init.d ${libexecdir}/slapd ${sbindir} ${localstatedir}/run ${localstatedir}/volatile/run \
+    ${sysconfdir}/openldap/slapd.* ${sysconfdir}/openldap/schema \
+    ${sysconfdir}/openldap/DB_CONFIG.example ${systemd_unitdir}/system/*"
+FILES_${PN}-slurpd = "${libexecdir}/slurpd ${localstatedir}/openldap-slurp ${localstatedir}/run ${localstatedir}/volatile/run"
+FILES_${PN}-bin = "${bindir}"
+FILES_${PN}-dev = "${includedir} ${libdir}/lib*.so ${libdir}/*.la ${libdir}/*.a ${libexecdir}/openldap/*.a ${libexecdir}/openldap/*.la ${libexecdir}/openldap/*.so"
+FILES_${PN}-dbg += "${libexecdir}/openldap/.debug"
+
+do_install_append() {
+    install -d ${D}${sysconfdir}/init.d
+    cat ${WORKDIR}/initscript > ${D}${sysconfdir}/init.d/openldap
+    chmod 755 ${D}${sysconfdir}/init.d/openldap
+    # This is duplicated in /etc/openldap and is for slapd
+    rm -f ${D}${localstatedir}/openldap-data/DB_CONFIG.example
+
+    # Installing slapd under ${sbin} is more FHS and LSB compliance
+    mv ${D}${libexecdir}/slapd ${D}/${sbindir}/slapd
+    rmdir --ignore-fail-on-non-empty ${D}${libexecdir}
+    SLAPTOOLS="slapadd slapcat slapdn slapindex slappasswd slaptest slapauth slapacl slapschema"
+    cd ${D}/${sbindir}/
+    rm -f ${SLAPTOOLS}
+    for i in ${SLAPTOOLS}; do ln -sf slapd $i; done
+
+    rmdir "${D}${localstatedir}/run"
+    rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
+
+    install -d ${D}${systemd_unitdir}/system/
+    install -m 0644 ${WORKDIR}/slapd.service ${D}${systemd_unitdir}/system/
+    sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/*.service
+
+    # Uses mdm as the database
+    #  and localstatedir as data directory ...
+    sed -e 's/# modulepath/modulepath/' \
+        -e 's/# moduleload\s*back_bdb.*/moduleload    back_mdb/' \
+        -e 's/database\s*bdb/database        mdb/' \
+        -e 's%^directory\s*.*%directory   ${localstatedir}/${BPN}/data/%' \
+        -i ${D}${sysconfdir}/openldap/slapd.conf
+
+    mkdir -p ${D}${localstatedir}/${BPN}/data
+
+
+}
+
+INITSCRIPT_PACKAGES = "${PN}-slapd"
+INITSCRIPT_NAME_${PN}-slapd = "openldap"
+INITSCRIPT_PARAMS_${PN}-slapd = "defaults"
+SYSTEMD_SERVICE_${PN}-slapd = "hostapd.service"
+SYSTEMD_AUTO_ENABLE_${PN}-slapd ?= "disable"
+
+
+PACKAGES_DYNAMIC += "^${PN}-backends.* ^${PN}-backend-.*"
+
+# The modules require their .so to be dynamicaly loaded
+INSANE_SKIP_${PN}-backend-dnssrv  += "dev-so"
+INSANE_SKIP_${PN}-backend-ldap    += "dev-so"
+INSANE_SKIP_${PN}-backend-meta    += "dev-so"
+INSANE_SKIP_${PN}-backend-mdb     += "dev-so"
+INSANE_SKIP_${PN}-backend-monitor += "dev-so"
+INSANE_SKIP_${PN}-backend-null    += "dev-so"
+INSANE_SKIP_${PN}-backend-passwd  += "dev-so"
+INSANE_SKIP_${PN}-backend-shell   += "dev-so"
+
+
+python populate_packages_prepend () {
+    backend_dir    = d.expand('${libexecdir}/openldap')
+    do_split_packages(d, backend_dir, 'back_([a-z]*)\.so$', 'openldap-backend-%s', 'OpenLDAP %s backend', prepend=True, extra_depends='', allow_links=True)
+    do_split_packages(d, backend_dir, 'back_([a-z]*)\-.*\.so\..*$', 'openldap-backend-%s', 'OpenLDAP %s backend', extra_depends='', allow_links=True)
+
+    metapkg = "${PN}-backends"
+    d.setVar('ALLOW_EMPTY_' + metapkg, "1")
+    d.setVar('FILES_' + metapkg, "")
+    metapkg_rdepends = []
+    packages = d.getVar('PACKAGES').split()
+    for pkg in packages[1:]:
+        if pkg.count("openldap-backend-") and not pkg in metapkg_rdepends and not pkg.count("-dev") and not pkg.count("-dbg") and not pkg.count("static") and not pkg.count("locale"):
+            metapkg_rdepends.append(pkg)
+    d.setVar('RDEPENDS_' + metapkg, ' '.join(metapkg_rdepends))
+    d.setVar('DESCRIPTION_' + metapkg, 'OpenLDAP backends meta package')
+    packages.append(metapkg)
+    d.setVar('PACKAGES', ' '.join(packages))
+}
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-support/opensc/opensc/0001-Fixed-gcc-8-compilation-errors-1353.patch b/meta-openembedded/meta-oe/recipes-support/opensc/opensc/0001-Fixed-gcc-8-compilation-errors-1353.patch
new file mode 100644
index 0000000..48d8327
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/opensc/opensc/0001-Fixed-gcc-8-compilation-errors-1353.patch
@@ -0,0 +1,73 @@
+From 87857d5cae7db94fdd776904886392b1e86053bd Mon Sep 17 00:00:00 2001
+From: Florian Bezdeka <1119693+fbezdeka@users.noreply.github.com>
+Date: Fri, 18 May 2018 18:54:56 +0200
+Subject: [PATCH] Fixed gcc 8 compilation errors (#1353)
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+The following errors occured during a compilation using gcc 8:
+
+In function »gids_create_file.constprop«,
+    inserted by »gids_save_certificate.isra.8« beicard-gids.c:1548:7:
+card-gids.c:465:2: Error: »strncpy« output may be truncated copying 8 bytes from a string of length 8 [-Werror=stringop-truncation]
+  strncpy(record->filename, filename, 8);
+  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+pkcs15-oberthur.c: In function »sc_pkcs15emu_oberthur_add_prvkey«:
+pkcs15-oberthur.c:741:5: Error: »strncpy« output may be truncated copying 254 bytes from a string of length 254 [-Werror=stringop-truncation]
+     strncpy(kobj.label, objs[ii]->label, sizeof(kobj.label) - 1);
+     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Upstream-Status: Backport [https://github.com/OpenSC/OpenSC/pull/1353]
+Signed-off-by Khem Raj <raj.khem@gmail.com>
+---
+ src/libopensc/card-gids.c       | 3 ++-
+ src/libopensc/pkcs15-oberthur.c | 3 ++-
+ 2 files changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/src/libopensc/card-gids.c b/src/libopensc/card-gids.c
+index fc5d2a7..ac3e579 100644
+--- a/src/libopensc/card-gids.c
++++ b/src/libopensc/card-gids.c
+@@ -33,6 +33,7 @@ Some features are undocumented like the format used to store certificates. They
+ 
+ #include <stdlib.h>
+ #include <string.h>
++#include "../common/compat_strlcpy.h"
+ 
+ #ifdef ENABLE_OPENSSL
+ /* openssl only needed for card administration */
+@@ -462,7 +463,7 @@ static int gids_create_file(sc_card_t *card, char* directory, char* filename) {
+ 	memset(masterfilebuffer + offset, 0, sizeof(gids_mf_record_t));
+ 	record = (gids_mf_record_t*) (masterfilebuffer + offset);
+ 	strncpy(record->directory, directory, 8);
+-	strncpy(record->filename, filename, 8);
++	strlcpy(record->filename, filename, sizeof(record->filename));
+ 	record->fileIdentifier = fileIdentifier;
+ 	record->dataObjectIdentifier = dataObjectIdentifier;
+ 
+diff --git a/src/libopensc/pkcs15-oberthur.c b/src/libopensc/pkcs15-oberthur.c
+index 4f841ed..3415be7 100644
+--- a/src/libopensc/pkcs15-oberthur.c
++++ b/src/libopensc/pkcs15-oberthur.c
+@@ -29,6 +29,7 @@
+ #include <stdlib.h>
+ #include <string.h>
+ #include <stdio.h>
++#include "../common/compat_strlcpy.h"
+ 
+ #include "pkcs15.h"
+ #include "log.h"
+@@ -738,7 +739,7 @@ sc_pkcs15emu_oberthur_add_prvkey(struct sc_pkcs15_card *p15card,
+ 			unsigned int id = path.value[path.len - 2] * 0x100 + path.value[path.len - 1];
+ 
+ 			if (id == ccont.id_cert)   {
+-				strncpy(kobj.label, objs[ii]->label, sizeof(kobj.label) - 1);
++				strlcpy(kobj.label, objs[ii]->label, sizeof(kobj.label));
+ 				break;
+ 			}
+ 		}
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-oe/recipes-support/opensc/opensc_0.16.0.bb b/meta-openembedded/meta-oe/recipes-support/opensc/opensc_0.16.0.bb
deleted file mode 100644
index fd67181..0000000
--- a/meta-openembedded/meta-oe/recipes-support/opensc/opensc_0.16.0.bb
+++ /dev/null
@@ -1,44 +0,0 @@
-SUMMARY = "Smart card library and applications"
-DESCRIPTION = "OpenSC is a tool for accessing smart card devices. Basic\
-functionality (e.g. SELECT FILE, READ BINARY) should work on any ISO\
-7816-4 compatible smart card. Encryption and decryption using private\
-keys on the smart card is possible with PKCS\
-such as the FINEID (Finnish Electronic IDentity) card. Swedish Posten\
-eID cards have also been confirmed to work."
-
-HOMEPAGE = "http://www.opensc-project.org/opensc/"
-SECTION = "System Environment/Libraries"
-
-SRC_URI = "${DEBIAN_MIRROR}/main/o/${BPN}/${BPN}_${PV}.orig.tar.gz"
-
-SRC_URI[md5sum] = "724d128f23cd7a74b28d04300ce7bcbd"
-SRC_URI[sha256sum] = "3ac8c29542bb48179e7086d35a1b8907a4e86aca3de3323c2f48bd74eaaf5729"
-
-DEPENDS = "openct pcsc-lite virtual/libiconv openssl"
-
-LICENSE = "LGPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=7fbc338309ac38fefcd64b04bb903e34"
-
-inherit autotools pkgconfig
-
-EXTRA_OECONF = " \
-    --disable-static \
-    --enable-openct \
-    --disable-pcsc \
-    --disable-ctapi \
-    --disable-doc \
-"
-EXTRA_OEMAKE = "DESTDIR=${D}"
-
-RDEPENDS_${PN} = "readline"
-
-FILES_${PN} += "\
-    ${libdir}/opensc-pkcs11.so \
-    ${libdir}/onepin-opensc-pkcs11.so \
-    ${libdir}/pkcs11-spy.so \
-"
-FILES_${PN}-dev += "\
-    ${libdir}/pkcs11/opensc-pkcs11.so \
-    ${libdir}/pkcs11/onepin-opensc-pkcs11.so \
-    ${libdir}/pkcs11/pkcs11-spy.so \
-"
diff --git a/meta-openembedded/meta-oe/recipes-support/opensc/opensc_0.18.0.bb b/meta-openembedded/meta-oe/recipes-support/opensc/opensc_0.18.0.bb
new file mode 100644
index 0000000..45c931e
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/opensc/opensc_0.18.0.bb
@@ -0,0 +1,47 @@
+SUMMARY = "Smart card library and applications"
+DESCRIPTION = "OpenSC is a tool for accessing smart card devices. Basic\
+functionality (e.g. SELECT FILE, READ BINARY) should work on any ISO\
+7816-4 compatible smart card. Encryption and decryption using private\
+keys on the smart card is possible with PKCS\
+such as the FINEID (Finnish Electronic IDentity) card. Swedish Posten\
+eID cards have also been confirmed to work."
+
+HOMEPAGE = "http://www.opensc-project.org/opensc/"
+SECTION = "System Environment/Libraries"
+
+SRC_URI = "https://snapshot.debian.org/archive/debian/20180521T101428Z/pool/main/o/opensc/opensc_0.18.0.orig.tar.gz \
+           file://0001-Fixed-gcc-8-compilation-errors-1353.patch \
+          "
+
+SRC_URI[md5sum] = "bce516f752e0db5327aa06cc0136fe27"
+SRC_URI[sha256sum] = "6ef62b00e8fdbe3e386c3ee25c2cadb56c1931ea42f1a11dce8c947f51b45033"
+
+DEPENDS = "openct pcsc-lite virtual/libiconv openssl"
+
+LICENSE = "LGPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=7fbc338309ac38fefcd64b04bb903e34"
+
+inherit autotools pkgconfig
+
+S = "${WORKDIR}/OpenSC-${PV}"
+EXTRA_OECONF = " \
+    --disable-static \
+    --enable-openct \
+    --disable-pcsc \
+    --disable-ctapi \
+    --disable-doc \
+"
+EXTRA_OEMAKE = "DESTDIR=${D}"
+
+RDEPENDS_${PN} = "readline"
+
+FILES_${PN} += "\
+    ${libdir}/opensc-pkcs11.so \
+    ${libdir}/onepin-opensc-pkcs11.so \
+    ${libdir}/pkcs11-spy.so \
+"
+FILES_${PN}-dev += "\
+    ${libdir}/pkcs11/opensc-pkcs11.so \
+    ${libdir}/pkcs11/onepin-opensc-pkcs11.so \
+    ${libdir}/pkcs11/pkcs11-spy.so \
+"
diff --git a/meta-openembedded/meta-oe/recipes-support/pcsc-lite/pcsc-lite_1.8.22.bb b/meta-openembedded/meta-oe/recipes-support/pcsc-lite/pcsc-lite_1.8.22.bb
index 90d58b0..10f724e 100644
--- a/meta-openembedded/meta-oe/recipes-support/pcsc-lite/pcsc-lite_1.8.22.bb
+++ b/meta-openembedded/meta-oe/recipes-support/pcsc-lite/pcsc-lite_1.8.22.bb
@@ -11,7 +11,7 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=f38b3d1c7ef7fc2c8b6d20cd38efdc29"
 DEPENDS = "udev"
 
-SRC_URI = "https://alioth.debian.org/frs/download.php/file/4225/pcsc-lite-${PV}.tar.bz2"
+SRC_URI = "https://pcsclite.apdu.fr/files/${BP}.tar.bz2"
 SRC_URI[md5sum] = "0ec103b1ef298d0c58d6ef6b00b9cf17"
 SRC_URI[sha256sum] = "6a358f61ed3b66a7f6e1f4e794a94c7be4c81b7a58ec360c33791e8d7d9bd405"
 
diff --git a/meta-openembedded/meta-oe/recipes-support/pidgin/pidgin_2.12.0.bb b/meta-openembedded/meta-oe/recipes-support/pidgin/pidgin_2.12.0.bb
index 088f08b..148e4b6 100644
--- a/meta-openembedded/meta-oe/recipes-support/pidgin/pidgin_2.12.0.bb
+++ b/meta-openembedded/meta-oe/recipes-support/pidgin/pidgin_2.12.0.bb
@@ -58,7 +58,9 @@
 OE_LT_RPATH_ALLOW=":${libdir}/purple-2:"
 OE_LT_RPATH_ALLOW[export]="1"
 
-PACKAGES =+ "libpurple-dbg libpurple-dev libpurple libgnt-dbg libgnt libgnt-dev finch-dbg finch finch-dev ${PN}-data"
+PACKAGES =+ "libpurple-dev libpurple libgnt libgnt-dev finch finch-dev ${PN}-data"
+
+RPROVIDES_${PN}-dbg += "libpurple-dbg libgnt-dbg finch-dbg"
 
 LEAD_SONAME = "libpurple.so.0"
 FILES_libpurple     = "${libdir}/libpurple*.so.* ${libdir}/purple-2 ${bindir}/purple-* ${sysconfdir}/gconf/schemas/purple* ${datadir}/purple/ca-certs"
@@ -69,15 +71,10 @@
                        ${libdir}/purple-2/liboscar.so \
                        ${libdir}/purple-2/libymsg.so \
                        ${datadir}/aclocal"
-FILES_libpurple-dbg += "${libdir}/.debug/libpurple* \
-                        ${libdir}/purple-2/.debug"
 FILES_libgnt         = "${libdir}/libgnt.so.* ${libdir}/gnt/*.so"
 FILES_libgnt-dev     = "${libdir}/gnt/*.la"
-FILES_libgnt-dbg     = "${libdir}/gnt/.debug"
 FILES_finch          = "${bindir}/finch"
 FILES_finch-dev      = "${libdir}/finch/*.la"
-FILES_finch-dbg      = "${bindir}/.debug/finch \
-                        ${libdir}/finch/.debug"
 
 FILES_${PN} = "${bindir} ${datadir}/${PN} ${libdir}/${PN}/*.so \
            ${datadir}/applications"
diff --git a/meta-openembedded/meta-oe/recipes-support/poco/poco/0001-Don-t-try-to-install-non-existing-Encodings-testsuit.patch b/meta-openembedded/meta-oe/recipes-support/poco/poco/0001-Don-t-try-to-install-non-existing-Encodings-testsuit.patch
new file mode 100644
index 0000000..f4a358f
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/poco/poco/0001-Don-t-try-to-install-non-existing-Encodings-testsuit.patch
@@ -0,0 +1,31 @@
+From fa079dfc5e1d22ea35762bf4c5b09999bdc5e731 Mon Sep 17 00:00:00 2001
+From: Jochen Sprickerhof <git@jochen.sprickerhof.de>
+Date: Wed, 22 Aug 2018 21:42:09 +0200
+Subject: [PATCH] Don't try to install non existing Encodings/testsuite/data
+
+Upstream-Status: Backport [https://github.com/pocoproject/poco/pull/2437]
+---
+ Encodings/testsuite/CMakeLists.txt | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
+diff --git a/Encodings/testsuite/CMakeLists.txt b/Encodings/testsuite/CMakeLists.txt
+index 7508e5522..79495ae02 100644
+--- a/Encodings/testsuite/CMakeLists.txt
++++ b/Encodings/testsuite/CMakeLists.txt
+@@ -19,12 +19,9 @@ POCO_SOURCES_AUTO_PLAT( TEST_SRCS WINCE
+ add_executable( ${TESTUNIT} ${TEST_SRCS} )
+ if(ANDROID)
+ 	add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
+-			COMMAND ${CMAKE_COMMAND} -DANDROID_NDK=${ANDROID_NDK} "-DTEST_FILES=${CMAKE_CURRENT_SOURCE_DIR}/data;" -DLIBRARY_DIR=${CMAKE_BINARY_DIR}/lib -DUNITTEST=${CMAKE_BINARY_DIR}/bin/${TESTUNIT} -DTEST_PARAMETER=-all -P ${CMAKE_SOURCE_DIR}/cmake/ExecuteOnAndroid.cmake)
++			COMMAND ${CMAKE_COMMAND} -DANDROID_NDK=${ANDROID_NDK} -DLIBRARY_DIR=${CMAKE_BINARY_DIR}/lib -DUNITTEST=${CMAKE_BINARY_DIR}/bin/Encodings-testrunner -DTEST_PARAMETER=-all -P ${CMAKE_SOURCE_DIR}/cmake/ExecuteOnAndroid.cmake)
+ else()
+ 	add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
+-	# The test is run in the build directory. So the test data is copied there too
+-	add_custom_command(TARGET ${TESTUNIT} POST_BUILD
+-				   COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/data ${CMAKE_CURRENT_BINARY_DIR}/data )
+ endif()
+ #set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
+ target_link_libraries( ${TESTUNIT}  PocoEncodings PocoFoundation CppUnit )
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-oe/recipes-support/poco/poco_1.8.0.1.bb b/meta-openembedded/meta-oe/recipes-support/poco/poco_1.8.0.1.bb
deleted file mode 100644
index 160b4d3..0000000
--- a/meta-openembedded/meta-oe/recipes-support/poco/poco_1.8.0.1.bb
+++ /dev/null
@@ -1,106 +0,0 @@
-SUMMARY = "Modern, powerful open source cross-platform C++ class libraries"
-DESCRIPTION = "Modern, powerful open source C++ class libraries and frameworks for building network- and internet-based applications that run on desktop, server, mobile and embedded systems."
-SECTION = "libs"
-HOMEPAGE = "http://pocoproject.org/"
-LICENSE = "BSL-1.0"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=4267f48fc738f50380cbeeb76f95cebc"
-
-# These dependencies are required by Foundation
-DEPENDS = "libpcre zlib"
-
-inherit cmake ptest
-
-BBCLASSEXTEND = "native"
-
-SRCREV = "af527ab21fca5ab2659285408aec9920ed7c7b17"
-SRC_URI = " \
-    git://github.com/pocoproject/poco.git \
-    file://run-ptest \
-   "
-
-S = "${WORKDIR}/git"
-
-EXTRA_OECMAKE = "-DCMAKE_BUILD_TYPE=RelWithDebInfo -DPOCO_UNBUNDLED=ON \
-                  -DZLIB_LIBRARY_RELEASE:STRING=z -DPCRE_LIBRARY:STRING=pcre \
-                 ${@bb.utils.contains('PTEST_ENABLED', '1', '-DENABLE_TESTS=ON ', '', d)}"
-
-# For the native build we want to use the bundled version
-EXTRA_OECMAKE_append_class-native = " -DPOCO_UNBUNDLED=OFF"
-
-# do not use rpath
-EXTRA_OECMAKE_append = " -DCMAKE_SKIP_RPATH=ON"
-
-# By default the most commonly used poco components are built
-# Foundation is built anyway and doesn't need to be listed explicitly
-# these don't have dependencies outside oe-core
-PACKAGECONFIG ??= "XML JSON MongoDB PDF Util Net NetSSL Crypto Data DataSQLite Zip"
-
-PACKAGECONFIG[XML] = "-DENABLE_XML=ON -DEXPAT_LIBRARY:STRING=expat,-DENABLE_XML=OFF,expat"
-PACKAGECONFIG[JSON] = "-DENABLE_JSON=ON,-DENABLE_JSON=OFF"
-PACKAGECONFIG[MongoDB] = "-DENABLE_MONGODB=ON,-DENABLE_MONGODB=OFF"
-PACKAGECONFIG[PDF] = "-DENABLE_PDF=ON,-DENABLE_PDF=OFF,zlib"
-PACKAGECONFIG[Util] = "-DENABLE_UTIL=ON,-DENABLE_UTIL=OFF"
-PACKAGECONFIG[Net] = "-DENABLE_NET=ON,-DENABLE_NET=OFF"
-PACKAGECONFIG[NetSSL] = "-DENABLE_NETSSL=ON -DOPENSSL_SSL_LIBRARY:STRING=ssl -DOPENSSL_CRYPTO_LIBRARY:STRING=crypto,-DENABLE_NETSSL=OFF,openssl"
-PACKAGECONFIG[Crypto] = "-DENABLE_CRYPTO=ON -DOPENSSL_SSL_LIBRARY:STRING=ssl -DOPENSSL_CRYPTO_LIBRARY:STRING=crypto,-DENABLE_CRYPTO=OFF,openssl"
-PACKAGECONFIG[Data] = "-DENABLE_DATA=ON,-DENABLE_DATA=OFF"
-PACKAGECONFIG[DataSQLite] = "-DENABLE_DATA_SQLITE=ON -DSQLITE3_LIBRARY:STRING=sqlite3,-DENABLE_DATA_SQLITE=OFF,sqlite3"
-PACKAGECONFIG[Zip] = "-DENABLE_ZIP=ON,-DENABLE_ZIP=OFF"
-
-# Additional components not build by default,
-# they might have dependencies not included in oe-core
-# or they don't work on all architectures
-PACKAGECONFIG[mod_poco] = "-DENABLE_APACHECONNECTOR=ON,-DENABLE_APACHECONNECTOR=OFF,apr apache2"
-PACKAGECONFIG[CppParser] = "-DENABLE_CPPPARSER=ON,-DENABLE_CPPPARSER=OFF"
-PACKAGECONFIG[DataMySQL] = "-DENABLE_DATA_MYSQL=ON -DMYSQL_LIB:STRING=mysqlclient_r,-DENABLE_DATA_MYSQL=OFF,mariadb"
-PACKAGECONFIG[DataODBC] = "-DENABLE_DATA_ODBC=ON,-DENABLE_DATA_ODBC=OFF,libiodbc"
-PACKAGECONFIG[PageCompiler] = "-DENABLE_PAGECOMPILER=ON,-DENABLE_PAGECOMPILER=OFF"
-PACKAGECONFIG[PageCompilerFile2Page] = "-DENABLE_PAGECOMPILER_FILE2PAGE=ON,-DENABLE_PAGECOMPILER_FILE2PAGE=OFF"
-PACKAGECONFIG[SevenZip] = "-DENABLE_SEVENZIP=ON,-DENABLE_SEVENZIP=OFF"
-
-# Make a package for each library
-PACKAGES = "${PN}-dbg ${POCO_PACKAGES}"
-python __anonymous () {
-    packages = []
-    testrunners = []
-    components = d.getVar("PACKAGECONFIG").split()
-    components.append("Foundation")
-    for lib in components:
-        pkg = ("poco-%s" % lib.lower()).replace("_","")
-        packages.append(pkg)
-        if not d.getVar("FILES_%s" % pkg):
-            d.setVar("FILES_%s" % pkg, "${libdir}/libPoco%s.so.*" % lib)
-        testrunners.append("%s" % lib)
-
-    d.setVar("POCO_PACKAGES", " ".join(packages))
-    d.setVar("POCO_TESTRUNNERS", "\n".join(testrunners))
-}
-
-# "poco" is a metapackage which pulls in all Poco components
-PACKAGES += "${PN}"
-RRECOMMENDS_${PN} += "${POCO_PACKAGES}"
-RRECOMMENDS_${PN}_class-native = ""
-ALLOW_EMPTY_${PN} = "1"
-
-# -dev last to pick up the remaining stuff
-PACKAGES += "${PN}-dev ${PN}-staticdev"
-FILES_${PN}-dev = "${includedir} ${libdir}/libPoco*.so ${libdir}/cmake"
-FILES_${PN}-staticdev = "${libdir}/libPoco*.a"
-
-# ptest support
-FILES_${PN}-dbg += "${PTEST_PATH}/bin/.debug"
-
-# cppunit is only built if tests are enabled
-PACKAGES += "${PN}-cppunit"
-FILES_${PN}-cppunit += "${libdir}/libCppUnit.so*"
-ALLOW_EMPTY_${PN}-cppunit = "1"
-
-RDEPENDS_${PN}-ptest += "${PN}-cppunit"
-
-do_install_ptest () {
-       cp -rf ${B}/bin/ ${D}${PTEST_PATH}
-       cp -f ${B}/lib/libCppUnit.so* ${D}${libdir}
-       cp -rf ${B}/*/testsuite/data ${D}${PTEST_PATH}/bin/
-       find "${D}${PTEST_PATH}" -executable -exec chrpath -d {} \;
-       echo "${POCO_TESTRUNNERS}" > "${D}${PTEST_PATH}/testrunners"
-}
diff --git a/meta-openembedded/meta-oe/recipes-support/poco/poco_1.9.0.bb b/meta-openembedded/meta-oe/recipes-support/poco/poco_1.9.0.bb
new file mode 100644
index 0000000..258cc49
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/poco/poco_1.9.0.bb
@@ -0,0 +1,99 @@
+SUMMARY = "Modern, powerful open source cross-platform C++ class libraries"
+DESCRIPTION = "Modern, powerful open source C++ class libraries and frameworks for building network- and internet-based applications that run on desktop, server, mobile and embedded systems."
+HOMEPAGE = "http://pocoproject.org/"
+SECTION = "libs"
+LICENSE = "BSL-1.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=4267f48fc738f50380cbeeb76f95cebc"
+
+# These dependencies are required by Foundation
+DEPENDS = "libpcre zlib"
+
+SRC_URI = " \
+    git://github.com/pocoproject/poco.git;branch=poco-${PV} \
+    file://0001-Don-t-try-to-install-non-existing-Encodings-testsuit.patch \
+    file://run-ptest \
+   "
+SRCREV = "daf00da73ab917e4d4581e3aa00c0ee61e0cc58b"
+
+S = "${WORKDIR}/git"
+
+inherit cmake ptest
+
+# By default the most commonly used poco components are built
+# Foundation is built anyway and doesn't need to be listed explicitly
+# these don't have dependencies outside oe-core
+PACKAGECONFIG ??= "XML JSON MongoDB PDF Util Net NetSSL Crypto Data DataSQLite Zip Encodings Redis"
+
+PACKAGECONFIG[XML] = "-DENABLE_XML=ON -DEXPAT_LIBRARY:STRING=expat,-DENABLE_XML=OFF,expat"
+PACKAGECONFIG[JSON] = "-DENABLE_JSON=ON,-DENABLE_JSON=OFF"
+PACKAGECONFIG[MongoDB] = "-DENABLE_MONGODB=ON,-DENABLE_MONGODB=OFF"
+PACKAGECONFIG[PDF] = "-DENABLE_PDF=ON,-DENABLE_PDF=OFF,zlib"
+PACKAGECONFIG[Util] = "-DENABLE_UTIL=ON,-DENABLE_UTIL=OFF"
+PACKAGECONFIG[Net] = "-DENABLE_NET=ON,-DENABLE_NET=OFF"
+PACKAGECONFIG[NetSSL] = "-DENABLE_NETSSL=ON -DOPENSSL_SSL_LIBRARY:STRING=ssl -DOPENSSL_CRYPTO_LIBRARY:STRING=crypto,-DENABLE_NETSSL=OFF,openssl"
+PACKAGECONFIG[Crypto] = "-DENABLE_CRYPTO=ON -DOPENSSL_SSL_LIBRARY:STRING=ssl -DOPENSSL_CRYPTO_LIBRARY:STRING=crypto,-DENABLE_CRYPTO=OFF,openssl"
+PACKAGECONFIG[Data] = "-DENABLE_DATA=ON,-DENABLE_DATA=OFF"
+PACKAGECONFIG[DataSQLite] = "-DENABLE_DATA_SQLITE=ON -DSQLITE3_LIBRARY:STRING=sqlite3,-DENABLE_DATA_SQLITE=OFF,sqlite3"
+PACKAGECONFIG[Zip] = "-DENABLE_ZIP=ON,-DENABLE_ZIP=OFF"
+PACKAGECONFIG[Encodings] = "-DENABLE_ENCODINGS=ON,-DENABLE_ENCODINGS=OFF"
+PACKAGECONFIG[Redis] = "-DENABLE_REDIS=ON,-DENABLE_REDIS=OFF"
+
+# Additional components not build by default,
+# they might have dependencies not included in oe-core
+# or they don't work on all architectures
+PACKAGECONFIG[mod_poco] = "-DENABLE_APACHECONNECTOR=ON,-DENABLE_APACHECONNECTOR=OFF,apr apache2"
+PACKAGECONFIG[CppParser] = "-DENABLE_CPPPARSER=ON,-DENABLE_CPPPARSER=OFF"
+PACKAGECONFIG[DataMySQL] = "-DENABLE_DATA_MYSQL=ON -DMYSQL_LIB:STRING=mysqlclient_r,-DENABLE_DATA_MYSQL=OFF,mariadb"
+PACKAGECONFIG[DataODBC] = "-DENABLE_DATA_ODBC=ON,-DENABLE_DATA_ODBC=OFF,libiodbc"
+PACKAGECONFIG[PageCompiler] = "-DENABLE_PAGECOMPILER=ON,-DENABLE_PAGECOMPILER=OFF"
+PACKAGECONFIG[PageCompilerFile2Page] = "-DENABLE_PAGECOMPILER_FILE2PAGE=ON,-DENABLE_PAGECOMPILER_FILE2PAGE=OFF"
+PACKAGECONFIG[SevenZip] = "-DENABLE_SEVENZIP=ON,-DENABLE_SEVENZIP=OFF"
+
+EXTRA_OECMAKE = "-DCMAKE_BUILD_TYPE=RelWithDebInfo -DPOCO_UNBUNDLED=ON \
+                  -DZLIB_LIBRARY_RELEASE:STRING=z -DPCRE_LIBRARY:STRING=pcre \
+                 ${@bb.utils.contains('PTEST_ENABLED', '1', '-DENABLE_TESTS=ON ', '', d)}"
+
+# For the native build we want to use the bundled version
+EXTRA_OECMAKE_append_class-native = " -DPOCO_UNBUNDLED=OFF"
+
+# do not use rpath
+EXTRA_OECMAKE_append = " -DCMAKE_SKIP_RPATH=ON"
+
+python populate_packages_prepend () {
+    poco_libdir = d.expand('${libdir}')
+    pn = d.getVar("PN")
+    packages = []
+    testrunners = []
+
+    def hook(f, pkg, file_regex, output_pattern, modulename):
+        packages.append(pkg)
+        testrunners.append(modulename)
+
+    do_split_packages(d, poco_libdir, '^libPoco(.*)\.so\..*$',
+                    'poco-%s', 'Poco %s component', extra_depends='', prepend=True, hook=hook)
+
+    d.setVar("RRECOMMENDS_%s" % pn, " ".join(packages))
+    d.setVar("POCO_TESTRUNNERS", "\n".join(testrunners))
+}
+
+do_install_ptest () {
+       cp -rf ${B}/bin/ ${D}${PTEST_PATH}
+       cp -f ${B}/lib/libCppUnit.so* ${D}${libdir}
+       cp -rf ${B}/*/testsuite/data ${D}${PTEST_PATH}/bin/
+       find "${D}${PTEST_PATH}" -executable -exec chrpath -d {} \;
+       echo "${POCO_TESTRUNNERS}" > "${D}${PTEST_PATH}/testrunners"
+}
+
+PACKAGES_DYNAMIC = "poco-.*"
+
+# "poco" is a metapackage which pulls in all Poco components
+ALLOW_EMPTY_${PN} = "1"
+
+# cppunit is only built if tests are enabled
+PACKAGES =+ "${PN}-cppunit"
+FILES_${PN}-cppunit += "${libdir}/libCppUnit.so*"
+ALLOW_EMPTY_${PN}-cppunit = "1"
+
+RDEPENDS_${PN}-ptest += "${PN}-cppunit"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-support/poppler/poppler-data_0.4.8.bb b/meta-openembedded/meta-oe/recipes-support/poppler/poppler-data_0.4.8.bb
deleted file mode 100644
index 343b6db..0000000
--- a/meta-openembedded/meta-oe/recipes-support/poppler/poppler-data_0.4.8.bb
+++ /dev/null
@@ -1,36 +0,0 @@
-SUMMARY = "Encoding files for Poppler"
-DESCRIPTION = "Encoding files for use with poppler that enable poppler to \
-               correctly render CJK and Cyrrilic."
-LICENSE = "BSD & GPLv2 & GPLv3+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=4870b98343f0bbb25fa43b9d2ba59448 \
-                    file://COPYING.adobe;md5=63c6a8a9df204c00461fa5f163d8a663 \
-                    file://COPYING.gpl2;md5=751419260aa954499f7abaabaa882bbe \
-"
-
-inherit allarch
-
-INHIBIT_DEFAULT_DEPS = "1"
-
-CMAP_RESOURCES_BASE = "https://github.com/adobe-type-tools/cmap-resources/raw/0561ebca035813ed04c3485bca636a0aa7abdc1d/cmapresources_identity-0/CMap"
-
-SRC_URI = "http://poppler.freedesktop.org/${BP}.tar.gz \
-           ${CMAP_RESOURCES_BASE}/Identity-H;name=idh \
-           ${CMAP_RESOURCES_BASE}/Identity-V;name=idv"
-
-SRC_URI[md5sum] = "00f8989c804de84af0ba2ea629949980"
-SRC_URI[sha256sum] = "1096a18161f263cccdc6d8a2eb5548c41ff8fcf9a3609243f1b6296abdf72872"
-SRC_URI[idh.md5sum] = "009c93cf0141ab7bd6acb7eea14306cc"
-SRC_URI[idh.sha256sum] = "ae702c203a82ea124e9b96590f821db6fbf8754e2c4547a9dba0e82f94739e95"
-SRC_URI[idv.md5sum] = "2f32a45d43d001c26eeac6b878855fbf"
-SRC_URI[idv.sha256sum] = "89a85daf7031e93c883e76b9168a226dfd585bf5506e9e1956772163f15cb082"
-
-do_compile() {
-}
-
-do_install() {
-    oe_runmake install DESTDIR=${D} prefix=${prefix} datadir=${datadir}
-    install -d ${D}${datadir}/poppler/cMap
-    install -m644 ${WORKDIR}/Identity-* ${D}${datadir}/poppler/cMap/
-}
-
-FILES_${PN} += "${datadir}"
diff --git a/meta-openembedded/meta-oe/recipes-support/poppler/poppler-data_0.4.9.bb b/meta-openembedded/meta-oe/recipes-support/poppler/poppler-data_0.4.9.bb
new file mode 100644
index 0000000..b2af097
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/poppler/poppler-data_0.4.9.bb
@@ -0,0 +1,36 @@
+SUMMARY = "Encoding files for Poppler"
+DESCRIPTION = "Encoding files for use with poppler that enable poppler to \
+               correctly render CJK and Cyrrilic."
+LICENSE = "BSD & GPLv2 & GPLv3+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=4870b98343f0bbb25fa43b9d2ba59448 \
+                    file://COPYING.adobe;md5=63c6a8a9df204c00461fa5f163d8a663 \
+                    file://COPYING.gpl2;md5=751419260aa954499f7abaabaa882bbe \
+"
+
+inherit allarch
+
+INHIBIT_DEFAULT_DEPS = "1"
+
+CMAP_RESOURCES_BASE = "https://github.com/adobe-type-tools/cmap-resources/raw/0561ebca035813ed04c3485bca636a0aa7abdc1d/cmapresources_identity-0/CMap"
+
+SRC_URI = "http://poppler.freedesktop.org/${BP}.tar.gz \
+           ${CMAP_RESOURCES_BASE}/Identity-H;name=idh \
+           ${CMAP_RESOURCES_BASE}/Identity-V;name=idv"
+
+SRC_URI[md5sum] = "35cc7beba00aa174631466f06732be40"
+SRC_URI[sha256sum] = "1f9c7e7de9ecd0db6ab287349e31bf815ca108a5a175cf906a90163bdbe32012"
+SRC_URI[idh.md5sum] = "009c93cf0141ab7bd6acb7eea14306cc"
+SRC_URI[idh.sha256sum] = "ae702c203a82ea124e9b96590f821db6fbf8754e2c4547a9dba0e82f94739e95"
+SRC_URI[idv.md5sum] = "2f32a45d43d001c26eeac6b878855fbf"
+SRC_URI[idv.sha256sum] = "89a85daf7031e93c883e76b9168a226dfd585bf5506e9e1956772163f15cb082"
+
+do_compile() {
+}
+
+do_install() {
+    oe_runmake install DESTDIR=${D} prefix=${prefix} datadir=${datadir}
+    install -d ${D}${datadir}/poppler/cMap
+    install -m644 ${WORKDIR}/Identity-* ${D}${datadir}/poppler/cMap/
+}
+
+FILES_${PN} += "${datadir}"
diff --git a/meta-openembedded/meta-oe/recipes-support/poppler/poppler/basename-include.patch b/meta-openembedded/meta-oe/recipes-support/poppler/poppler/basename-include.patch
new file mode 100644
index 0000000..528528a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/poppler/poppler/basename-include.patch
@@ -0,0 +1,20 @@
+Minic GNU basename() API for non-glibc library e.g. musl
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Index: poppler-0.64.0/utils/pdfsig.cc
+===================================================================
+--- poppler-0.64.0.orig/utils/pdfsig.cc
++++ poppler-0.64.0/utils/pdfsig.cc
+@@ -35,6 +35,10 @@
+ #include "Win32Console.h"
+ #include "numberofcharacters.h"
+ 
++#if !defined(__GLIBC__)
++#define basename(src) (strrchr(src,'/') ? strrchr(src,'/')+1 : src)
++#endif
++
+ static const char * getReadableSigState(SignatureValidationStatus sig_vs)
+ {
+   switch(sig_vs) {
diff --git a/meta-openembedded/meta-oe/recipes-support/poppler/poppler_0.64.0.bb b/meta-openembedded/meta-oe/recipes-support/poppler/poppler_0.64.0.bb
deleted file mode 100644
index 1e87ae6..0000000
--- a/meta-openembedded/meta-oe/recipes-support/poppler/poppler_0.64.0.bb
+++ /dev/null
@@ -1,58 +0,0 @@
-SUMMARY = "Poppler is a PDF rendering library based on the xpdf-3.0 code base"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
-
-SRC_URI = "http://poppler.freedesktop.org/${BP}.tar.xz \
-           file://0001-Do-not-overwrite-all-our-build-flags.patch \
-           file://0002-CairoOutputDev.cc-fix-build-error-when-using-fixedpo.patch \
-           file://0001-glib-CMakeLists.txt-Add-libpoppler-to-link-along-wit.patch \
-           "
-SRC_URI[md5sum] = "f7f687ebb60004f8ad61994575018044"
-SRC_URI[sha256sum] = "b21df92ca99f78067785cf2dc8e06deb04726b62389c0ee1f5d8b103c77f64b1"
-
-DEPENDS = "fontconfig zlib cairo lcms glib-2.0"
-
-inherit cmake pkgconfig gobject-introspection
-
-PACKAGECONFIG ??= "jpeg openjpeg png tiff nss ${@bb.utils.contains('BBFILE_COLLECTIONS', 'qt5-layer', 'qt5', '', d)}"
-PACKAGECONFIG[jpeg] = "-DWITH_JPEG=ON -DENABLE_DCTDECODER=libjpeg,-DWITH_JPEG=OFF -DENABLE_DCTDECODER=none,jpeg"
-PACKAGECONFIG[png] = "-DWITH_PNG=ON,-DWITH_PNG=OFF,libpng"
-PACKAGECONFIG[tiff] = "-DWITH_TIFF=ON,-DWITH_TIFF=OFF,tiff"
-PACKAGECONFIG[curl] = "-DENABLE_LIBCURL=ON,-DENABLE_LIBCURL=OFF,curl"
-PACKAGECONFIG[openjpeg] = "-DENABLE_LIBOPENJPEG=openjpeg2,-DENABLE_LIBOPENJPEG=none,openjpeg"
-PACKAGECONFIG[qt5] = "-DENABLE_QT5=ON,-DENABLE_QT5=OFF,qtbase qttools-native"
-PACKAGECONFIG[nss] = "-DWITH_NSS3=ON,-DWITH_NSS3=OFF,nss"
-
-# surprise - did not expect this to work :)
-inherit ${@bb.utils.contains('PACKAGECONFIG', 'qt5', 'cmake_qt5', '', d)}
-
-SECURITY_CFLAGS = "${SECURITY_NO_PIE_CFLAGS}"
-
-EXTRA_OECMAKE += " \
-    -DENABLE_CMS=lcms2 \
-    -DENABLE_XPDF_HEADERS=ON \
-    -DBUILD_GTK_TESTS=OFF \
-    -DENABLE_ZLIB=ON \
-    -DCMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES:PATH='${STAGING_INCDIR}' \
-"
-
-do_configure_append() {
-    # poppler macro uses pkg-config to check for g-ir runtimes. Something
-    # makes them point to /usr/bin. Align them to sysroot - that's where the
-    # git-wrappers are:
-    sed -i 's: ${bindir}/g-ir: ${STAGING_BINDIR}/g-ir:' ${B}/build.ninja
-}
-
-# check for TARGET_FPU=soft and inform configure of the result so it can disable some floating points
-def get_poppler_fpu_setting(bb, d):
-    if d.getVar('TARGET_FPU') in [ 'soft' ]:
-        return "-DUSE_FIXEDPOINT=ON"
-    return ""
-
-EXTRA_OECMAKE += "${@get_poppler_fpu_setting(bb, d)}"
-
-PACKAGES =+ "libpoppler libpoppler-glib"
-FILES_libpoppler = "${libdir}/libpoppler.so.*"
-FILES_libpoppler-glib = "${libdir}/libpoppler-glib.so.*"
-
-RDEPENDS_libpoppler = "poppler-data"
diff --git a/meta-openembedded/meta-oe/recipes-support/poppler/poppler_0.70.1.bb b/meta-openembedded/meta-oe/recipes-support/poppler/poppler_0.70.1.bb
new file mode 100644
index 0000000..b618f28
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/poppler/poppler_0.70.1.bb
@@ -0,0 +1,59 @@
+SUMMARY = "Poppler is a PDF rendering library based on the xpdf-3.0 code base"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
+
+SRC_URI = "http://poppler.freedesktop.org/${BP}.tar.xz \
+           file://0001-Do-not-overwrite-all-our-build-flags.patch \
+           file://0002-CairoOutputDev.cc-fix-build-error-when-using-fixedpo.patch \
+           file://0001-glib-CMakeLists.txt-Add-libpoppler-to-link-along-wit.patch \
+           file://basename-include.patch \
+           "
+SRC_URI[md5sum] = "fdb0699e9aa20e81acd1a50701374c8b"
+SRC_URI[sha256sum] = "66972047d9ef8162cc8c389d7e7698291dfc9f2b3e4ea9a9f08ae604107451bd"
+
+DEPENDS = "fontconfig zlib cairo lcms glib-2.0"
+
+inherit cmake pkgconfig gobject-introspection
+
+PACKAGECONFIG ??= "jpeg openjpeg png tiff nss ${@bb.utils.contains('BBFILE_COLLECTIONS', 'qt5-layer', 'qt5', '', d)}"
+PACKAGECONFIG[jpeg] = "-DWITH_JPEG=ON -DENABLE_DCTDECODER=libjpeg,-DWITH_JPEG=OFF -DENABLE_DCTDECODER=none,jpeg"
+PACKAGECONFIG[png] = "-DWITH_PNG=ON,-DWITH_PNG=OFF,libpng"
+PACKAGECONFIG[tiff] = "-DWITH_TIFF=ON,-DWITH_TIFF=OFF,tiff"
+PACKAGECONFIG[curl] = "-DENABLE_LIBCURL=ON,-DENABLE_LIBCURL=OFF,curl"
+PACKAGECONFIG[openjpeg] = "-DENABLE_LIBOPENJPEG=openjpeg2,-DENABLE_LIBOPENJPEG=none,openjpeg"
+PACKAGECONFIG[qt5] = "-DENABLE_QT5=ON,-DENABLE_QT5=OFF,qtbase qttools-native"
+PACKAGECONFIG[nss] = "-DWITH_NSS3=ON,-DWITH_NSS3=OFF,nss"
+
+# surprise - did not expect this to work :)
+inherit ${@bb.utils.contains('PACKAGECONFIG', 'qt5', 'cmake_qt5', '', d)}
+
+SECURITY_CFLAGS = "${SECURITY_NO_PIE_CFLAGS}"
+
+EXTRA_OECMAKE += " \
+    -DENABLE_CMS=lcms2 \
+    -DENABLE_XPDF_HEADERS=ON \
+    -DBUILD_GTK_TESTS=OFF \
+    -DENABLE_ZLIB=ON \
+    -DCMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES:PATH='${STAGING_INCDIR}' \
+"
+
+do_configure_append() {
+    # poppler macro uses pkg-config to check for g-ir runtimes. Something
+    # makes them point to /usr/bin. Align them to sysroot - that's where the
+    # git-wrappers are:
+    sed -i 's: ${bindir}/g-ir: ${STAGING_BINDIR}/g-ir:' ${B}/build.ninja
+}
+
+# check for TARGET_FPU=soft and inform configure of the result so it can disable some floating points
+def get_poppler_fpu_setting(bb, d):
+    if d.getVar('TARGET_FPU') in [ 'soft' ]:
+        return "-DUSE_FIXEDPOINT=ON"
+    return ""
+
+EXTRA_OECMAKE += "${@get_poppler_fpu_setting(bb, d)}"
+
+PACKAGES =+ "libpoppler libpoppler-glib"
+FILES_libpoppler = "${libdir}/libpoppler.so.*"
+FILES_libpoppler-glib = "${libdir}/libpoppler-glib.so.*"
+
+RDEPENDS_libpoppler = "poppler-data"
diff --git a/meta-openembedded/meta-oe/recipes-support/pps-tools/pps-tools_1.0.2.bb b/meta-openembedded/meta-oe/recipes-support/pps-tools/pps-tools_1.0.2.bb
new file mode 100644
index 0000000..c8baa5d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/pps-tools/pps-tools_1.0.2.bb
@@ -0,0 +1,18 @@
+SUMMARY = "User-space tools for LinuxPPS"
+HOMEPAGE = "http://linuxpps.org"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
+
+SRCREV = "cb48b7ecf7079ceba7081c78d4e61e507b0e8d2d"
+SRC_URI = "git://github.com/ago/pps-tools.git"
+
+S = "${WORKDIR}/git"
+
+RDEPENDS_${PN} = "bash"
+
+do_install() {
+        install -d ${D}${bindir} ${D}${includedir} \
+                   ${D}${includedir}/sys
+        oe_runmake 'DESTDIR=${D}' install
+}
diff --git a/meta-openembedded/meta-oe/recipes-support/pps-tools/pps-tools_git.bb b/meta-openembedded/meta-oe/recipes-support/pps-tools/pps-tools_git.bb
deleted file mode 100644
index 8bf9036..0000000
--- a/meta-openembedded/meta-oe/recipes-support/pps-tools/pps-tools_git.bb
+++ /dev/null
@@ -1,17 +0,0 @@
-SUMMARY = "User-space tools for LinuxPPS"
-HOMEPAGE = "http://linuxpps.org"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
-
-PV = "0.0.0+git${SRCPV}"
-SRCREV = "0deb9c7e135e9380a6d09e9d2e938a146bb698c8"
-SRC_URI = "git://github.com/ago/pps-tools.git"
-
-S = "${WORKDIR}/git"
-
-do_install() {
-        install -d ${D}${bindir} ${D}${includedir} \
-                   ${D}${includedir}/sys
-        oe_runmake 'DESTDIR=${D}' install
-}
diff --git a/meta-openembedded/meta-oe/recipes-support/procmail/procmail_3.22.bb b/meta-openembedded/meta-oe/recipes-support/procmail/procmail_3.22.bb
index aa474ce..6160733 100644
--- a/meta-openembedded/meta-oe/recipes-support/procmail/procmail_3.22.bb
+++ b/meta-openembedded/meta-oe/recipes-support/procmail/procmail_3.22.bb
@@ -29,7 +29,7 @@
     export CFLAGS="${BUILD_CFLAGS}"
     export AR="${BUILD_AR}"
     export AS="${BUILD_AS}"
-    make TARGET_CFLAGS="$TARGET_CFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64" LDFLAGS0="${LDFLAGS}" autoconf.h
+    make TARGET_CFLAGS="$TARGET_CFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64" LDFLAGS0="${BUILD_LDFLAGS}" autoconf.h
 }
 
 do_compile() {
diff --git a/meta-openembedded/meta-oe/recipes-support/satyr/files/0001-do-not-support-python2.patch b/meta-openembedded/meta-oe/recipes-support/satyr/files/0001-do-not-support-python2.patch
deleted file mode 100644
index 9e95a3f..0000000
--- a/meta-openembedded/meta-oe/recipes-support/satyr/files/0001-do-not-support-python2.patch
+++ /dev/null
@@ -1,84 +0,0 @@
-From 206f334d62da17093e784094c9d9e80c853f704f Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Fri, 12 May 2017 03:03:46 -0400
-Subject: [PATCH] do not support python2
-
-Upstream-Status: Inappropriate [oe specific]
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- configure.ac       | 16 ----------------
- python/Makefile.am | 24 ------------------------
- 2 files changed, 40 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index 200a7cc..8431c51 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -22,22 +22,6 @@ AM_MISSING_PROG([AUTOM4TE], [autom4te])
- # Needed by tests/atlocal.in.
- AC_SUBST([O0CFLAGS], [`echo $CFLAGS | sed 's/-O[[0-9]] *//'`])
- 
--AM_PATH_PYTHON
--AM_CONDITIONAL([HAVE_PYTHON], test -n "$PYTHON")
--[if test -z "$PYTHON"; then]
--    [echo "The python interpreter was not found in the search path. The Python language bindings"]
--    [echo "will not be built.  If you want to build the Python language bindings, please ensure"]
--    [echo "that python is installed and its directory is included in the search path."]
--    [echo "Then run configure again before attempting to build Satyr."]
--[fi]
--
--# Just PKG_CHECK_MODULES([PYTHON], [python]) works only with python2.7+
--# Below, if python is not found, we set up for python2.6 w/o checking:
--PKG_CHECK_MODULES([PYTHON], [python2],,[
--    PYTHON_LIBS='-L/usr/lib64 -lpython2.6'
--    PYTHON_CFLAGS='-I/usr/include/python2.6'
--])
--
- AC_ARG_ENABLE([python-manpage],
-               [AS_HELP_STRING([--disable-python-manpage],
-                               [Disable python bindings manpage build])],
-diff --git a/python/Makefile.am b/python/Makefile.am
-index 36fc2e9..0b73f66 100644
---- a/python/Makefile.am
-+++ b/python/Makefile.am
-@@ -1,12 +1,5 @@
- SUBDIRS = . doc
- 
--py2satyrdir = $(pyexecdir)/satyr
--
--py2satyr_PYTHON = \
--    __init__.py
--
--py2satyr_LTLIBRARIES = _satyr.la
--
- PYEXTFILES = \
-     py_cluster.h \
-     py_cluster.c \
-@@ -75,23 +68,6 @@ PYEXTLDFLAGS = \
-     -module \
-     -avoid-version
- 
--_satyr_la_SOURCES = $(PYEXTFILES)
--_satyr_la_CPPFLAGS = \
--    $(PYEXTCPPFLAGS) \
--    $(PYTHON_CFLAGS)
--_satyr_la_LDFLAGS = \
--    $(PYEXTLDFLAGS) \
--    -export-symbols-regex init_satyr
--
--# Depending on the configure option, we either link libsatyr.so dynamically (as
--# is usual), or directly include its object files (by including the
--# convenience library).
--if ENABLE_STATIC_PYTHON_MODULE
--_satyr_la_LIBADD = ../lib/libsatyr_conv.la
--else
--_satyr_la_LIBADD = ../lib/libsatyr.la
--endif
--
- if WITH_PYTHON3
- py3satyrdir = $(py3execdir)/satyr
- 
--- 
-2.8.1
-
diff --git a/meta-openembedded/meta-oe/recipes-support/satyr/files/0002-fix-compile-failure-against-musl-C-library.patch b/meta-openembedded/meta-oe/recipes-support/satyr/files/0002-fix-compile-failure-against-musl-C-library.patch
index 5827eb4..b6c32c4 100644
--- a/meta-openembedded/meta-oe/recipes-support/satyr/files/0002-fix-compile-failure-against-musl-C-library.patch
+++ b/meta-openembedded/meta-oe/recipes-support/satyr/files/0002-fix-compile-failure-against-musl-C-library.patch
@@ -14,7 +14,7 @@
 index 920e145..58140bf 100644
 --- a/lib/rpm.c
 +++ b/lib/rpm.c
-@@ -188,7 +188,7 @@ sr_rpm_package_sort(struct sr_rpm_package *packages)
+@@ -191,7 +191,7 @@ sr_rpm_package_sort(struct sr_rpm_package *packages)
      }
  
      /* Sort the array. */
diff --git a/meta-openembedded/meta-oe/recipes-support/satyr/satyr_0.23.bb b/meta-openembedded/meta-oe/recipes-support/satyr/satyr_0.23.bb
deleted file mode 100644
index f795c37..0000000
--- a/meta-openembedded/meta-oe/recipes-support/satyr/satyr_0.23.bb
+++ /dev/null
@@ -1,33 +0,0 @@
-DESCRIPTION = "Satyr is a collection of low-level algorithms for program \
-failure processing, analysis, and reporting supporting kernel space, user \
-space, Python, and Java programs"
-
-HOMEPAGE = "https://github.com/abrt/satyr"
-LICENSE = "GPLv2"
-
-inherit autotools-brokensep python3native pkgconfig
-
-SRC_URI = "git://github.com/abrt/satyr.git \
-           file://0001-do-not-support-python2.patch \
-           file://0002-fix-compile-failure-against-musl-C-library.patch \
-"
-SRCREV = "4742fd4857c446b96f712d52e2e4cd0b6cfe7398"
-S = "${WORKDIR}/git"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
-
-DEPENDS += " \
-    gdb \
-"
-
-PACKAGES += "python3-${PN}"
-FILES_python3-${PN} = "${PYTHON_SITEPACKAGES_DIR}/${BPN}"
-
-PACKAGECONFIG ??= "python3 rpm"
-PACKAGECONFIG[python3] = "--with-python3, --without-python3,,python3"
-PACKAGECONFIG[pythonmanpage] = "--enable-python-manpage, --disable-python-manpage"
-PACKAGECONFIG[rpm] = "--with-rpm, --without-rpm, rpm"
-
-do_configure_prepend() {
-    ${S}/gen-version
-}
diff --git a/meta-openembedded/meta-oe/recipes-support/satyr/satyr_0.26.bb b/meta-openembedded/meta-oe/recipes-support/satyr/satyr_0.26.bb
new file mode 100644
index 0000000..a09bea2
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/satyr/satyr_0.26.bb
@@ -0,0 +1,32 @@
+DESCRIPTION = "Satyr is a collection of low-level algorithms for program \
+failure processing, analysis, and reporting supporting kernel space, user \
+space, Python, and Java programs"
+
+HOMEPAGE = "https://github.com/abrt/satyr"
+LICENSE = "GPLv2"
+
+inherit autotools-brokensep python3native pkgconfig
+
+SRC_URI = "git://github.com/abrt/satyr.git \
+           file://0002-fix-compile-failure-against-musl-C-library.patch \
+"
+SRCREV = "4baa0c765071054314d1e7e78547ce6b7c133fbc"
+S = "${WORKDIR}/git"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
+
+DEPENDS += " \
+    gdb \
+"
+
+PACKAGES += "python3-${PN}"
+FILES_python3-${PN} = "${PYTHON_SITEPACKAGES_DIR}/${BPN}"
+
+PACKAGECONFIG ??= "python3 rpm"
+PACKAGECONFIG[python2] = "--with-python2, --without-python2,,python2"
+PACKAGECONFIG[python3] = "--with-python3, --without-python3,,python3"
+PACKAGECONFIG[rpm] = "--with-rpm, --without-rpm, rpm"
+
+do_configure_prepend() {
+    ${S}/gen-version
+}
diff --git a/meta-openembedded/meta-oe/recipes-support/sdparm/sdparm_1.10.bb b/meta-openembedded/meta-oe/recipes-support/sdparm/sdparm_1.10.bb
index 3299a77..35e22d3 100644
--- a/meta-openembedded/meta-oe/recipes-support/sdparm/sdparm_1.10.bb
+++ b/meta-openembedded/meta-oe/recipes-support/sdparm/sdparm_1.10.bb
@@ -12,6 +12,8 @@
            "
 MIRRORS += "http://sg.danny.cz/sg/p https://fossies.org/linux/misc"
 
+UPSTREAM_CHECK_REGEX = "sdparm-(?P<pver>\d+(\.\d+)+)\.tgz"
+
 PACKAGES =+ "${PN}-scripts"
 RDEPENDS_${PN}-scripts += "bash ${PN}"
 
diff --git a/meta-openembedded/meta-oe/recipes-support/sg3-utils/sg3-utils/glibc-2.28.patch b/meta-openembedded/meta-oe/recipes-support/sg3-utils/sg3-utils/glibc-2.28.patch
new file mode 100644
index 0000000..fbad413
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/sg3-utils/sg3-utils/glibc-2.28.patch
@@ -0,0 +1,24 @@
+Fixes:
+http://errors.yoctoproject.org/Errors/Details/185896/
+
+TOPDIR/tmp-glibc/work/core2-64-oe-linux/sg3-utils/1.42-r0/recipe-sysroot-native/usr/bin/x86_64-oe-linux/../../libexec/x86_64-oe-linux/gcc/x86_64-oe-linux/8.2.0/ld: sg_map26.o: in function `nd_match_scandir_select':
+/usr/src/debug/sg3-utils/1.42-r0/sg3_utils-1.42/src/sg_map26.c:359: undefined reference to `major'
+TOPDIR/tmp-glibc/work/core2-64-oe-linux/sg3-utils/1.42-r0/recipe-sysroot-native/usr/bin/x86_64-oe-linux/../../libexec/x86_64-oe-linux/gcc/x86_64-oe-linux/8.2.0/ld: /usr/src/debug/sg3-utils/1.42-r0/sg3_utils-1.42/src/sg_map26.c:361: undefined reference to `minor'
+TOPDIR/tmp-glibc/work/core2-64-oe-linux/sg3-utils/1.42-r0/recipe-sysroot-native/usr/bin/x86_64-oe-linux/../../libexec/x86_64-oe-linux/gcc/x86_64-oe-linux/8.2.0/ld: sg_map26.o: in function `nt_typ_from_filename':
+/usr/src/debug/sg3-utils/1.42-r0/sg3_utils-1.42/src/sg_map26.c:218: undefined reference to `major'
+TOPDIR/tmp-glibc/work/core2-64-oe-linux/sg3-utils/1.42-r0/recipe-sysroot-native/usr/bin/x86_64-oe-linux/../../libexec/x86_64-oe-linux/gcc/x86_64-oe-linux/8.2.0/ld: /usr/src/debug/sg3-utils/1.42-r0/sg3_utils-1.42/src/sg_map26.c:219: undefined reference to `minor'
+collect2: error: ld returned 1 exit status
+Makefile:806: recipe for target 'sg_map26' failed
+
+Upstream-Status: Pending
+
+--- sg3_utils-1.42.orig/src/sg_map26.c	2018-08-09 11:53:26.907493996 +0000
++++ sg3_utils-1.42/src/sg_map26.c	2018-08-09 11:51:56.713490763 +0000
+@@ -33,6 +33,7 @@
+ #include <sys/ioctl.h>
+ #include <sys/types.h>
+ #include <sys/stat.h>
++#include <sys/sysmacros.h>
+ #include <linux/major.h>
+ 
+ #ifdef HAVE_CONFIG_H
diff --git a/meta-openembedded/meta-oe/recipes-support/sg3-utils/sg3-utils_1.42.bb b/meta-openembedded/meta-oe/recipes-support/sg3-utils/sg3-utils_1.42.bb
index c7de057..c37c5e9 100644
--- a/meta-openembedded/meta-oe/recipes-support/sg3-utils/sg3-utils_1.42.bb
+++ b/meta-openembedded/meta-oe/recipes-support/sg3-utils/sg3-utils_1.42.bb
@@ -8,9 +8,13 @@
 LICENSE = "GPLv2+ & BSD"
 LIC_FILES_CHKSUM = "file://COPYING;md5=f90da7fc52172599dbf082d7620f18ca"
 
-SRC_URI = "http://sg.danny.cz/sg/p/sg3_utils-${PV}.tgz"
+SRC_URI = "http://sg.danny.cz/sg/p/sg3_utils-${PV}.tgz \
+    file://glibc-2.28.patch \
+"
 MIRRORS += "http://sg.danny.cz/sg/p https://fossies.org/linux/misc"
 
+UPSTREAM_CHECK_REGEX = "sg3_utils-(?P<pver>\d+(\.\d+)+)\.tgz"
+
 SRC_URI[md5sum] = "28080de5bf2222f8b55a29093bec8aea"
 SRC_URI[sha256sum] = "1dcb7a0309bd0ba3d4a83acb526973b80106ee26cd9f7398186cd3f0633c9ef3"
 
diff --git a/meta-openembedded/meta-oe/recipes-support/sharutils/sharutils/CVE-2018-1000097.patch b/meta-openembedded/meta-oe/recipes-support/sharutils/sharutils/CVE-2018-1000097.patch
new file mode 100644
index 0000000..99dc4e3
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/sharutils/sharutils/CVE-2018-1000097.patch
@@ -0,0 +1,61 @@
+From bd68ae1271598e8fdc72f2adb457e6882604582d Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar@redhat.com>
+Date: Thu, 22 Feb 2018 16:39:43 +0100
+Subject: [PATCH] Fix a heap-buffer-overflow in find_archive()
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+rw_buffer has allocated rw_base_size bytes. But subsequend fgets() in
+find_archive() reads up-to BUFSIZ bytes.
+
+On my system, BUFSIZ is 8192. rw_base_size is usually equaled to
+a memory page size, 4096 on my system. Thus find_archive() can write
+beyonded allocated memmory for rw_buffer array:
+
+$ valgrind -- ./unshar /tmp/id\:000000\,sig\:06\,src\:000005+000030\,op\:splice\,rep\:4
+==30582== Memcheck, a memory error detector
+==30582== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
+==30582== Using Valgrind-3.13.0 and LibVEX; rerun with -h for copyright info
+==30582== Command: ./unshar /tmp/id:000000,sig:06,src:000005+000030,op:splice,rep:4
+==30582==
+==30582== Invalid write of size 1
+==30582==    at 0x4EAB480: _IO_getline_info (in /usr/lib64/libc-2.27.so)
+==30582==    by 0x4EB47C2: fgets_unlocked (in /usr/lib64/libc-2.27.so)
+==30582==    by 0x10BF60: fgets_unlocked (stdio2.h:320)
+==30582==    by 0x10BF60: find_archive (unshar.c:243)
+==30582==    by 0x10BF60: unshar_file (unshar.c:379)
+==30582==    by 0x10BCCC: validate_fname (unshar-opts.c:604)
+==30582==    by 0x10BCCC: main (unshar-opts.c:639)
+==30582==  Address 0x523a790 is 0 bytes after a block of size 4,096 alloc'd
+==30582==    at 0x4C2DBBB: malloc (vg_replace_malloc.c:299)
+==30582==    by 0x10C670: init_unshar (unshar.c:450)
+==30582==    by 0x10BC55: main (unshar-opts.c:630)
+
+This was reported in
+<http://lists.gnu.org/archive/html/bug-gnu-utils/2018-02/msg00004.html>.
+
+CVE: CVE-2018-1000097
+Upstream-Status: no upstream [http://lists.gnu.org/archive/html/bug-gnu-utils/2018-02/msg00004.html]
+Signed-off-by: Petr Písař <ppisar@redhat.com>
+Signed-off-by: Sinan Kaya <okaya@kernel.org>
+---
+ src/unshar.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/unshar.c b/src/unshar.c
+index 80bc3a9..0fc3773 100644
+--- a/src/unshar.c
++++ b/src/unshar.c
+@@ -240,7 +240,7 @@ find_archive (char const * name, FILE * file, off_t start)
+       off_t position = ftello (file);
+ 
+       /* Read next line, fail if no more and no previous process.  */
+-      if (!fgets (rw_buffer, BUFSIZ, file))
++      if (!fgets (rw_buffer, rw_base_size, file))
+ 	{
+ 	  if (!start)
+ 	    error (0, 0, _("Found no shell commands in %s"), name);
+-- 
+2.19.0
+
diff --git a/meta-openembedded/meta-oe/recipes-support/sharutils/sharutils_4.15.2.bb b/meta-openembedded/meta-oe/recipes-support/sharutils/sharutils_4.15.2.bb
index 812fee9..c12289b 100644
--- a/meta-openembedded/meta-oe/recipes-support/sharutils/sharutils_4.15.2.bb
+++ b/meta-openembedded/meta-oe/recipes-support/sharutils/sharutils_4.15.2.bb
@@ -8,6 +8,7 @@
 
 SRC_URI = "ftp://ftp.gnu.org/gnu/${BPN}/${BP}.tar.gz \
            file://0001-Fix-build-with-clang.patch \
+           file://CVE-2018-1000097.patch \
 "
 SRC_URI[md5sum] = "32a51b23e25ad5e6af4b89f228be1800"
 SRC_URI[sha256sum] = "ee336e68549664e7a19b117adf02edfdeac6307f22e5ba78baca457116914637"
diff --git a/meta-openembedded/meta-oe/recipes-support/spitools/spitools_git.bb b/meta-openembedded/meta-oe/recipes-support/spitools/spitools_git.bb
index 3f6cdc6..af1cd60 100644
--- a/meta-openembedded/meta-oe/recipes-support/spitools/spitools_git.bb
+++ b/meta-openembedded/meta-oe/recipes-support/spitools/spitools_git.bb
@@ -4,11 +4,9 @@
 LICENSE="GPLv2"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=8c16666ae6c159876a0ba63099614381"
 
-PR = "r0"
-
-BPV = "0.8.1"
+BPV = "0.8.3"
 PV = "${BPV}"
-SRCREV = "318bcae5249722873bf58b27afdd20473c7047cc"
+SRCREV = "a3f1f68a048d0d2321ee562b3744dd1162cad22f"
 
 S = "${WORKDIR}/git"
 
@@ -16,4 +14,3 @@
 
 
 inherit autotools
-
diff --git a/meta-openembedded/meta-oe/recipes-support/start-stop-daemon/start-stop-daemon/0001-Add-linux-musleabi-to-ostable.patch b/meta-openembedded/meta-oe/recipes-support/start-stop-daemon/start-stop-daemon/0001-Add-linux-musleabi-to-ostable.patch
new file mode 100644
index 0000000..269441f
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/start-stop-daemon/start-stop-daemon/0001-Add-linux-musleabi-to-ostable.patch
@@ -0,0 +1,39 @@
+From 087840efdbc86b1432ebdd81f25b4cb78c75f818 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 11 Sep 2018 12:28:10 -0700
+Subject: [PATCH] Add linux-musleabi to ostable
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ ostable      | 1 +
+ triplettable | 1 +
+ 2 files changed, 2 insertions(+)
+
+diff --git a/ostable b/ostable
+index 3bb6819..d0ffdc7 100644
+--- a/ostable
++++ b/ostable
+@@ -15,6 +15,7 @@
+ uclibceabi-linux	linux-uclibceabi	linux[^-]*-uclibceabi
+ uclibc-linux		linux-uclibc		linux[^-]*-uclibc
+ musleabihf-linux	linux-musleabihf	linux[^-]*-musleabihf
++musleabi-linux		linux-musleabi		linux[^-]*-musleabi
+ musl-linux		linux-musl		linux[^-]*-musl
+ gnueabihf-linux		linux-gnueabihf		linux[^-]*-gnueabihf
+ gnueabi-linux		linux-gnueabi		linux[^-]*-gnueabi
+diff --git a/triplettable b/triplettable
+index 7257744..45864c3 100644
+--- a/triplettable
++++ b/triplettable
+@@ -6,6 +6,7 @@
+ uclibceabi-linux-arm	uclibc-linux-armel
+ uclibc-linux-<cpu>	uclibc-linux-<cpu>
+ musleabihf-linux-arm	musl-linux-armhf
++musleabi-linux-arm	musl-linux-arm
+ musl-linux-<cpu>	musl-linux-<cpu>
+ gnueabihf-linux-arm	armhf
+ gnueabi-linux-arm	armel
+-- 
+2.18.0
+
diff --git a/meta-openembedded/meta-oe/recipes-support/start-stop-daemon/start-stop-daemon_1.17.25.bb b/meta-openembedded/meta-oe/recipes-support/start-stop-daemon/start-stop-daemon_1.17.25.bb
index cc2727b..b9b22a3 100644
--- a/meta-openembedded/meta-oe/recipes-support/start-stop-daemon/start-stop-daemon_1.17.25.bb
+++ b/meta-openembedded/meta-oe/recipes-support/start-stop-daemon/start-stop-daemon_1.17.25.bb
@@ -9,6 +9,7 @@
 SRC_URI = " \
     ${DEBIAN_MIRROR}/main/d/dpkg/dpkg_${PV}.tar.xz \
     file://0001-dpkg-start-stop-daemon-Accept-SIG-prefixed-signal-na.patch \
+    file://0001-Add-linux-musleabi-to-ostable.patch \
 "
 
 SRC_URI[md5sum] = "e48fcfdb2162e77d72c2a83432d537ca"
diff --git a/meta-openembedded/meta-oe/recipes-support/stm32flash/stm32flash_0.5.bb b/meta-openembedded/meta-oe/recipes-support/stm32flash/stm32flash_0.5.bb
new file mode 100644
index 0000000..854df06
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/stm32flash/stm32flash_0.5.bb
@@ -0,0 +1,16 @@
+SUMMARY = "Open source flash program for STM32 using the ST serial bootloader"
+HOMEPAGE = "https://sourceforge.net/projects/stm32flash/"
+BUGTRACKER = "https://sourceforge.net/p/stm32flash/tickets/"
+LICENSE = "GPL-2.0+"
+LIC_FILES_CHKSUM = "file://gpl-2.0.txt;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+S = "${WORKDIR}/${BPN}"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BP}.tar.gz"
+
+do_install() {
+	oe_runmake install DESTDIR=${D} PREFIX=${prefix}
+}
+
+SRC_URI[md5sum] = "40f673502949f3bb655d2bcc539d7b6a"
+SRC_URI[sha256sum] = "97aa9422ef02e82f7da9039329e21a437decf972cb3919ad817f70ac9a49e306"
diff --git a/meta-openembedded/meta-oe/recipes-support/synergy/synergy_git.bb b/meta-openembedded/meta-oe/recipes-support/synergy/synergy_git.bb
index 68f0387..f5518bd 100644
--- a/meta-openembedded/meta-oe/recipes-support/synergy/synergy_git.bb
+++ b/meta-openembedded/meta-oe/recipes-support/synergy/synergy_git.bb
@@ -1,35 +1,24 @@
 SUMMARY = "Synergy - control multiple computers with one keyboard and mouse"
 HOMEPAGE = "http://synergy-project.org"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=d2ba51ca68e055566aade24662f9eb41"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=54c1fc8d8bb6776ae501acfb1585e9d6"
 LICENSE = "GPL-2.0-with-OpenSSL-exception"
 SECTION = "x11/utils"
 
 DEPENDS = "virtual/libx11 libxtst libxinerama curl openssl"
-do_unpack_extra[depends] = "unzip-native:do_populate_sysroot"
 
 # depends on virtual/libx11
 REQUIRED_DISTRO_FEATURES = "x11"
 
-SRC_URI = "git://github.com/symless/synergy.git;protocol=http"
+SRC_URI = "git://github.com/symless/synergy-core;protocol=https;nobranch=1"
 
-# Version 1.8.8-stable
-SRCREV ?= "c30301e23424db1125664da17deb8c3aa6aec52d"
-PV = "1.8.8+${SRCPV}"
+# Version 1.10.1-stable
+SRCREV ?= "1b4c076127687aceac931d269e898beaac1cad9f"
+PV = "1.10.1+git${SRCPV}"
 
 S = "${WORKDIR}/git"
 
 inherit cmake distro_features_check
 
-do_unpack_extra() {
-    cd ${S}/ext
-    for file in *.zip; do
-        fname="${file##*/}"
-        unzip $file -d ${fname%.*}
-    done
-}
-addtask unpack_extra after do_unpack before do_patch
+EXTRA_OECMAKE += "-DSYNERGY_BUILD_LEGACY_GUI=OFF"
 
-do_install() {
-    install -d ${D}/usr/bin
-    install -m 0755 ${S}/bin/synergy* ${D}/usr/bin/
-}
+FILES_${PN} += "${datadir}/icons/hicolor"
diff --git a/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/0001-syslog-ng-fix-segment-fault-during-service-start.patch b/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/0001-syslog-ng-fix-segment-fault-during-service-start.patch
new file mode 100644
index 0000000..0fc40be
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/0001-syslog-ng-fix-segment-fault-during-service-start.patch
@@ -0,0 +1,75 @@
+From caeccb7bec45f65bc89efa8195b3853368328361 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Mon, 17 Sep 2018 12:49:36 +0800
+Subject: [PATCH] syslog-ng: fix segment fault during service start on arm64
+
+service start failed since segment fault on arch arm64,
+syslog-ng have a submodule ivykis, from ivykis V0.42,
+it use pthread_atfork, but for arm64, this symbol is
+not included by libpthread, so cause segment fault.
+
+refer systemd, replace pthread_atfork with __register_atfork
+to fix this problem.
+
+I have create an issue, and this proposal to upstream.
+https://github.com/buytenh/ivykis/issues/15
+
+Upstream-Status: Pending
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ lib/ivykis/src/pthr.h | 24 ++++++++++++------------
+ 1 file changed, 12 insertions(+), 12 deletions(-)
+
+diff --git a/lib/ivykis/src/pthr.h b/lib/ivykis/src/pthr.h
+index a41eaf3..72c5190 100644
+--- a/lib/ivykis/src/pthr.h
++++ b/lib/ivykis/src/pthr.h
+@@ -24,6 +24,16 @@
+ #include <pthread.h>
+ #include <signal.h>
+ 
++#ifdef __GLIBC__
++/* We use glibc __register_atfork() + __dso_handle directly here, as they are not included in the glibc
++ * headers. __register_atfork() is mostly equivalent to pthread_atfork(), but doesn't require us to link against
++ * libpthread, as it is part of glibc anyway. */
++extern int __register_atfork(void (*prepare) (void), void (*parent) (void), void (*child) (void), void * __dso_handle);
++extern void* __dso_handle __attribute__ ((__weak__));
++#else
++#define __register_atfork(prepare,parent,child,dso) pthread_atfork(prepare,parent,child)
++#endif
++
+ #ifdef HAVE_PRAGMA_WEAK
+ #pragma weak pthread_create
+ #endif
+@@ -36,16 +46,7 @@ static inline int pthreads_available(void)
+ 
+ #ifdef HAVE_PRAGMA_WEAK
+ 
+-/*
+- * On Linux, pthread_atfork() is defined in libpthread_nonshared.a,
+- * a static library, and we want to avoid "#pragma weak" for that
+- * symbol because that causes it to be undefined even if you link
+- * libpthread_nonshared.a in explicitly.
+- */
+-#ifndef HAVE_LIBPTHREAD_NONSHARED
+-#pragma weak pthread_atfork
+-#endif
+-
++#pragma weak __register_atfork
+ #pragma weak pthread_create
+ #pragma weak pthread_detach
+ #pragma weak pthread_getspecific
+@@ -73,8 +74,7 @@ static inline int
+ pthr_atfork(void (*prepare)(void), void (*parent)(void), void (*child)(void))
+ {
+ 	if (pthreads_available())
+-		return pthread_atfork(prepare, parent, child);
+-
++		return __register_atfork(prepare, parent, child, __dso_handle);
+ 	return ENOSYS;
+ }
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/Fix-the-memory-leak-problem-when-HAVE_ENVIRON-defined.patch b/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/Fix-the-memory-leak-problem-when-HAVE_ENVIRON-defined.patch
deleted file mode 100644
index 5d481f2..0000000
--- a/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/Fix-the-memory-leak-problem-when-HAVE_ENVIRON-defined.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-Fix the memory leak problem when HAVE_ENVIRON is defined
-
-Upstream-Status: Pending
-
-Signed-off-by: Xufeng Zhang <xufeng.zhang@windriver.com>
----
-Index: syslog-ng-3.8.1/lib/gprocess.c
-===================================================================
---- syslog-ng-3.8.1.orig/lib/gprocess.c
-+++ syslog-ng-3.8.1/lib/gprocess.c
-@@ -1432,6 +1432,18 @@ g_process_startup_ok(void)
- void
- g_process_finish(void)
- {
-+#ifdef HAVE_ENVIRON
-+  int i = 0;
-+
-+  while (environ[i]) {
-+    g_free(environ[i]);
-+    ++i;
-+  }
-+  if (environ)
-+    g_free(environ);
-+  if (process_opts.argv_orig)
-+    free(process_opts.argv_orig);
-+#endif
-   g_process_remove_pidfile();
- }
- 
diff --git a/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/configure.ac-add-option-enable-thread-tls-to-manage-.patch b/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/configure.ac-add-option-enable-thread-tls-to-manage-.patch
index c172e4e..4f8a3d0 100644
--- a/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/configure.ac-add-option-enable-thread-tls-to-manage-.patch
+++ b/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/configure.ac-add-option-enable-thread-tls-to-manage-.patch
@@ -10,21 +10,21 @@
  configure.ac | 17 +++++++++++------
  1 file changed, 11 insertions(+), 6 deletions(-)
 
-Index: syslog-ng-3.8.1/configure.ac
+Index: syslog-ng-3.15.1/configure.ac
 ===================================================================
---- syslog-ng-3.8.1.orig/configure.ac
-+++ syslog-ng-3.8.1/configure.ac
-@@ -147,6 +147,9 @@ AC_ARG_ENABLE(gprof,
+--- syslog-ng-3.15.1.orig/configure.ac
++++ syslog-ng-3.15.1/configure.ac
+@@ -190,6 +190,9 @@ AC_ARG_ENABLE(gprof,
  AC_ARG_ENABLE(memtrace,
                [  --enable-memtrace   Enable alternative leak debugging code.])
  
 +AC_ARG_ENABLE(thread-tls,
-+              [  --enable-thread-tls        Enable Thread Transport Layer Security support.],,enable_thread_tls="no")
++              [  --enable-thread-tls        Enable Thread Local Storage support.],,enable_thread_tls="no")
 +
  AC_ARG_ENABLE(dynamic-linking,
                [  --enable-dynamic-linking        Link everything dynamically.],,enable_dynamic_linking="auto")
  
-@@ -486,12 +489,14 @@ dnl ************************************
+@@ -591,12 +594,14 @@ dnl ***************************************************************************
  dnl Is the __thread keyword available?
  dnl ***************************************************************************
  
@@ -33,14 +33,14 @@
 -__thread int a;
 -]],
 -[a=0;])],
--[ac_cv_have_tls=yes; AC_DEFINE_UNQUOTED(HAVE_THREAD_KEYWORD, 1, "Whether Transport Layer Security is supported by the system")])
+-[ac_cv_have_tls=yes; AC_DEFINE_UNQUOTED(HAVE_THREAD_KEYWORD, 1, "Whether Thread Local Storage is supported by the system")])
 +if test "x$enable_thread_tls" != "xno"; then
 +    AC_LINK_IFELSE([AC_LANG_PROGRAM(
 +    [[#include <pthread.h>
 +    __thread int a;
 +    ]],
 +    [a=0;])],
-+    [ac_cv_have_tls=yes; AC_DEFINE_UNQUOTED(HAVE_THREAD_KEYWORD, 1, "Whether Transport Layer Security is supported by the system")])
++    [ac_cv_have_tls=yes; AC_DEFINE_UNQUOTED(HAVE_THREAD_KEYWORD, 1, "Whether Thread Local Storage is supported by the system")])
 +fi
  
  dnl ***************************************************************************
diff --git a/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/syslog-ng.conf b/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/syslog-ng.conf
deleted file mode 100644
index 0c6f543..0000000
--- a/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/syslog-ng.conf
+++ /dev/null
@@ -1,155 +0,0 @@
-@version: 3.8
-#
-# Syslog-ng configuration file, compatible with default Debian syslogd
-# installation. Originally written by anonymous (I can't find his name)
-# Revised, and rewrited by me (SZALAY Attila <sasa@debian.org>)
-
-# First, set some global options.
-options { chain_hostnames(off); flush_lines(0); use_dns(no); use_fqdn(no);
-	  owner("root"); group("adm"); perm(0640); stats_freq(0);
-	  bad_hostname("^gconfd$");
-};
-
-########################
-# Sources
-########################
-# This is the default behavior of sysklogd package
-# Logs may come from unix stream, but not from another machine.
-#
-source s_src { unix-dgram("/dev/log"); internal();
-       	     file("/proc/kmsg" program_override("kernel"));
-};
-
-# If you wish to get logs from remote machine you should uncomment
-# this and comment the above source line.
-#
-#source s_net { tcp(ip(127.0.0.1) port(1000) authentication(required) encrypt(allow)); };
-
-########################
-# Destinations
-########################
-# First some standard logfile
-#
-destination d_auth { file("/var/log/auth.log"); };
-destination d_cron { file("/var/log/cron.log"); };
-destination d_daemon { file("/var/log/daemon.log"); };
-destination d_kern { file("/var/log/kern.log"); };
-destination d_lpr { file("/var/log/lpr.log"); };
-destination d_mail { file("/var/log/mail.log"); };
-destination d_syslog { file("/var/log/syslog"); };
-destination d_user { file("/var/log/user.log"); };
-destination d_uucp { file("/var/log/uucp.log"); };
-
-# This files are the log come from the mail subsystem.
-#
-destination d_mailinfo { file("/var/log/mail/mail.info"); };
-destination d_mailwarn { file("/var/log/mail/mail.warn"); };
-destination d_mailerr { file("/var/log/mail/mail.err"); };
-
-# Logging for INN news system
-#
-destination d_newscrit { file("/var/log/news/news.crit"); };
-destination d_newserr { file("/var/log/news/news.err"); };
-destination d_newsnotice { file("/var/log/news/news.notice"); };
-
-# Some 'catch-all' logfiles.
-#
-destination d_debug { file("/var/log/debug"); };
-destination d_error { file("/var/log/error"); };
-destination d_messages { file("/var/log/messages"); };
-
-# The root's console.
-#
-destination d_console { usertty("root"); };
-
-# Virtual console.
-#
-destination d_console_all { file("/dev/tty10"); };
-
-# The named pipe /dev/xconsole is for the nsole' utility.  To use it,
-# you must invoke nsole' with the -file' option:
-#
-#    $ xconsole -file /dev/xconsole [...]
-#
-destination d_xconsole { pipe("/dev/xconsole"); };
-
-# Send the messages to an other host
-#
-#destination d_net { tcp("127.0.0.1" port(1000) authentication(on) encrypt(on) log_fifo_size(1000)); };
-
-# Debian only
-destination d_ppp { file("/var/log/ppp.log"); };
-
-########################
-# Filters
-########################
-# Here's come the filter options. With this rules, we can set which
-# message go where.
-
-filter f_dbg { level(debug); };
-filter f_info { level(info); };
-filter f_notice { level(notice); };
-filter f_warn { level(warn); };
-filter f_err { level(err); };
-filter f_crit { level(crit .. emerg); };
-
-filter f_debug { level(debug) and not facility(auth, authpriv, news, mail); };
-filter f_error { level(err .. emerg) ; };
-filter f_messages { level(info,notice,warn) and
-                    not facility(auth,authpriv,cron,daemon,mail,news); };
-
-filter f_auth { facility(auth, authpriv) and not filter(f_debug); };
-filter f_cron { facility(cron) and not filter(f_debug); };
-filter f_daemon { facility(daemon) and not filter(f_debug); };
-filter f_kern { facility(kern) and not filter(f_debug); };
-filter f_lpr { facility(lpr) and not filter(f_debug); };
-filter f_local { facility(local0, local1, local3, local4, local5,
-                        local6, local7) and not filter(f_debug); };
-filter f_mail { facility(mail) and not filter(f_debug); };
-filter f_news { facility(news) and not filter(f_debug); };
-filter f_syslog3 { not facility(auth, authpriv, mail) and not filter(f_debug); };
-filter f_user { facility(user) and not filter(f_debug); };
-filter f_uucp { facility(uucp) and not filter(f_debug); };
-
-filter f_cnews { level(notice, err, crit) and facility(news); };
-filter f_cother { level(debug, info, notice, warn) or facility(daemon, mail); };
-
-filter f_ppp { facility(local2) and not filter(f_debug); };
-filter f_console { level(warn .. emerg); };
-
-########################
-# Log paths
-########################
-log { source(s_src); filter(f_auth); destination(d_auth); };
-log { source(s_src); filter(f_cron); destination(d_cron); };
-log { source(s_src); filter(f_daemon); destination(d_daemon); };
-log { source(s_src); filter(f_kern); destination(d_kern); };
-log { source(s_src); filter(f_lpr); destination(d_lpr); };
-log { source(s_src); filter(f_syslog3); destination(d_syslog); };
-log { source(s_src); filter(f_user); destination(d_user); };
-log { source(s_src); filter(f_uucp); destination(d_uucp); };
-
-log { source(s_src); filter(f_mail); destination(d_mail); };
-#log { source(s_src); filter(f_mail); filter(f_info); destination(d_mailinfo); };
-#log { source(s_src); filter(f_mail); filter(f_warn); destination(d_mailwarn); };
-#log { source(s_src); filter(f_mail); filter(f_err); destination(d_mailerr); };
-
-log { source(s_src); filter(f_news); filter(f_crit); destination(d_newscrit); };
-log { source(s_src); filter(f_news); filter(f_err); destination(d_newserr); };
-log { source(s_src); filter(f_news); filter(f_notice); destination(d_newsnotice); };
-#log { source(s_src); filter(f_cnews); destination(d_console_all); };
-#log { source(s_src); filter(f_cother); destination(d_console_all); };
-
-#log { source(s_src); filter(f_ppp); destination(d_ppp); };
-
-log { source(s_src); filter(f_debug); destination(d_debug); };
-log { source(s_src); filter(f_error); destination(d_error); };
-log { source(s_src); filter(f_messages); destination(d_messages); };
-
-log { source(s_src); filter(f_console); destination(d_console_all);
-				    destination(d_xconsole); };
-log { source(s_src); filter(f_crit); destination(d_console); };
-
-# All messages send to a remote site
-#
-#log { source(s_src); destination(d_net); };
diff --git a/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/syslog-ng.conf.systemd b/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/syslog-ng.conf.systemd
new file mode 100644
index 0000000..9e910ca
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/syslog-ng.conf.systemd
@@ -0,0 +1,155 @@
+@version: 3.15
+#
+# Syslog-ng configuration file, compatible with default Debian syslogd
+# installation. Originally written by anonymous (I can't find his name)
+# Revised, and rewrited by me (SZALAY Attila <sasa@debian.org>)
+
+# First, set some global options.
+options { chain_hostnames(off); flush_lines(0); use_dns(no); use_fqdn(no);
+	  owner("root"); group("adm"); perm(0640); stats_freq(0);
+	  bad_hostname("^gconfd$");
+};
+
+########################
+# Sources
+########################
+# This is the default behavior of sysklogd package
+# Logs may come from unix stream, but not from another machine.
+#
+source s_src { systemd_journal(); internal();
+       	     file("/proc/kmsg" program_override("kernel"));
+};
+
+# If you wish to get logs from remote machine you should uncomment
+# this and comment the above source line.
+#
+#source s_net { tcp(ip(127.0.0.1) port(1000) authentication(required) encrypt(allow)); };
+
+########################
+# Destinations
+########################
+# First some standard logfile
+#
+destination d_auth { file("/var/log/auth.log"); };
+destination d_cron { file("/var/log/cron.log"); };
+destination d_daemon { file("/var/log/daemon.log"); };
+destination d_kern { file("/var/log/kern.log"); };
+destination d_lpr { file("/var/log/lpr.log"); };
+destination d_mail { file("/var/log/mail.log"); };
+destination d_syslog { file("/var/log/syslog"); };
+destination d_user { file("/var/log/user.log"); };
+destination d_uucp { file("/var/log/uucp.log"); };
+
+# This files are the log come from the mail subsystem.
+#
+destination d_mailinfo { file("/var/log/mail/mail.info"); };
+destination d_mailwarn { file("/var/log/mail/mail.warn"); };
+destination d_mailerr { file("/var/log/mail/mail.err"); };
+
+# Logging for INN news system
+#
+destination d_newscrit { file("/var/log/news/news.crit"); };
+destination d_newserr { file("/var/log/news/news.err"); };
+destination d_newsnotice { file("/var/log/news/news.notice"); };
+
+# Some 'catch-all' logfiles.
+#
+destination d_debug { file("/var/log/debug"); };
+destination d_error { file("/var/log/error"); };
+destination d_messages { file("/var/log/messages"); };
+
+# The root's console.
+#
+destination d_console { usertty("root"); };
+
+# Virtual console.
+#
+destination d_console_all { file("/dev/tty10"); };
+
+# The named pipe /dev/xconsole is for the nsole' utility.  To use it,
+# you must invoke nsole' with the -file' option:
+#
+#    $ xconsole -file /dev/xconsole [...]
+#
+destination d_xconsole { pipe("/dev/xconsole"); };
+
+# Send the messages to an other host
+#
+#destination d_net { tcp("127.0.0.1" port(1000) authentication(on) encrypt(on) log_fifo_size(1000)); };
+
+# Debian only
+destination d_ppp { file("/var/log/ppp.log"); };
+
+########################
+# Filters
+########################
+# Here's come the filter options. With this rules, we can set which
+# message go where.
+
+filter f_dbg { level(debug); };
+filter f_info { level(info); };
+filter f_notice { level(notice); };
+filter f_warn { level(warn); };
+filter f_err { level(err); };
+filter f_crit { level(crit .. emerg); };
+
+filter f_debug { level(debug) and not facility(auth, authpriv, news, mail); };
+filter f_error { level(err .. emerg) ; };
+filter f_messages { level(info,notice,warn) and
+                    not facility(auth,authpriv,cron,daemon,mail,news); };
+
+filter f_auth { facility(auth, authpriv) and not filter(f_debug); };
+filter f_cron { facility(cron) and not filter(f_debug); };
+filter f_daemon { facility(daemon) and not filter(f_debug); };
+filter f_kern { facility(kern) and not filter(f_debug); };
+filter f_lpr { facility(lpr) and not filter(f_debug); };
+filter f_local { facility(local0, local1, local3, local4, local5,
+                        local6, local7) and not filter(f_debug); };
+filter f_mail { facility(mail) and not filter(f_debug); };
+filter f_news { facility(news) and not filter(f_debug); };
+filter f_syslog3 { not facility(auth, authpriv, mail) and not filter(f_debug); };
+filter f_user { facility(user) and not filter(f_debug); };
+filter f_uucp { facility(uucp) and not filter(f_debug); };
+
+filter f_cnews { level(notice, err, crit) and facility(news); };
+filter f_cother { level(debug, info, notice, warn) or facility(daemon, mail); };
+
+filter f_ppp { facility(local2) and not filter(f_debug); };
+filter f_console { level(warn .. emerg); };
+
+########################
+# Log paths
+########################
+log { source(s_src); filter(f_auth); destination(d_auth); };
+log { source(s_src); filter(f_cron); destination(d_cron); };
+log { source(s_src); filter(f_daemon); destination(d_daemon); };
+log { source(s_src); filter(f_kern); destination(d_kern); };
+log { source(s_src); filter(f_lpr); destination(d_lpr); };
+log { source(s_src); filter(f_syslog3); destination(d_syslog); };
+log { source(s_src); filter(f_user); destination(d_user); };
+log { source(s_src); filter(f_uucp); destination(d_uucp); };
+
+log { source(s_src); filter(f_mail); destination(d_mail); };
+#log { source(s_src); filter(f_mail); filter(f_info); destination(d_mailinfo); };
+#log { source(s_src); filter(f_mail); filter(f_warn); destination(d_mailwarn); };
+#log { source(s_src); filter(f_mail); filter(f_err); destination(d_mailerr); };
+
+log { source(s_src); filter(f_news); filter(f_crit); destination(d_newscrit); };
+log { source(s_src); filter(f_news); filter(f_err); destination(d_newserr); };
+log { source(s_src); filter(f_news); filter(f_notice); destination(d_newsnotice); };
+#log { source(s_src); filter(f_cnews); destination(d_console_all); };
+#log { source(s_src); filter(f_cother); destination(d_console_all); };
+
+#log { source(s_src); filter(f_ppp); destination(d_ppp); };
+
+log { source(s_src); filter(f_debug); destination(d_debug); };
+log { source(s_src); filter(f_error); destination(d_error); };
+log { source(s_src); filter(f_messages); destination(d_messages); };
+
+log { source(s_src); filter(f_console); destination(d_console_all);
+				    destination(d_xconsole); };
+log { source(s_src); filter(f_crit); destination(d_console); };
+
+# All messages send to a remote site
+#
+#log { source(s_src); destination(d_net); };
diff --git a/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/syslog-ng.conf.sysvinit b/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/syslog-ng.conf.sysvinit
new file mode 100644
index 0000000..fb183ee
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/syslog-ng.conf.sysvinit
@@ -0,0 +1,155 @@
+@version: 3.15
+#
+# Syslog-ng configuration file, compatible with default Debian syslogd
+# installation. Originally written by anonymous (I can't find his name)
+# Revised, and rewrited by me (SZALAY Attila <sasa@debian.org>)
+
+# First, set some global options.
+options { chain_hostnames(off); flush_lines(0); use_dns(no); use_fqdn(no);
+	  owner("root"); group("adm"); perm(0640); stats_freq(0);
+	  bad_hostname("^gconfd$");
+};
+
+########################
+# Sources
+########################
+# This is the default behavior of sysklogd package
+# Logs may come from unix stream, but not from another machine.
+#
+source s_src { unix-dgram("/dev/log"); internal();
+       	     file("/proc/kmsg" program_override("kernel"));
+};
+
+# If you wish to get logs from remote machine you should uncomment
+# this and comment the above source line.
+#
+#source s_net { tcp(ip(127.0.0.1) port(1000) authentication(required) encrypt(allow)); };
+
+########################
+# Destinations
+########################
+# First some standard logfile
+#
+destination d_auth { file("/var/log/auth.log"); };
+destination d_cron { file("/var/log/cron.log"); };
+destination d_daemon { file("/var/log/daemon.log"); };
+destination d_kern { file("/var/log/kern.log"); };
+destination d_lpr { file("/var/log/lpr.log"); };
+destination d_mail { file("/var/log/mail.log"); };
+destination d_syslog { file("/var/log/syslog"); };
+destination d_user { file("/var/log/user.log"); };
+destination d_uucp { file("/var/log/uucp.log"); };
+
+# This files are the log come from the mail subsystem.
+#
+destination d_mailinfo { file("/var/log/mail/mail.info"); };
+destination d_mailwarn { file("/var/log/mail/mail.warn"); };
+destination d_mailerr { file("/var/log/mail/mail.err"); };
+
+# Logging for INN news system
+#
+destination d_newscrit { file("/var/log/news/news.crit"); };
+destination d_newserr { file("/var/log/news/news.err"); };
+destination d_newsnotice { file("/var/log/news/news.notice"); };
+
+# Some 'catch-all' logfiles.
+#
+destination d_debug { file("/var/log/debug"); };
+destination d_error { file("/var/log/error"); };
+destination d_messages { file("/var/log/messages"); };
+
+# The root's console.
+#
+destination d_console { usertty("root"); };
+
+# Virtual console.
+#
+destination d_console_all { file("/dev/tty10"); };
+
+# The named pipe /dev/xconsole is for the nsole' utility.  To use it,
+# you must invoke nsole' with the -file' option:
+#
+#    $ xconsole -file /dev/xconsole [...]
+#
+destination d_xconsole { pipe("/dev/xconsole"); };
+
+# Send the messages to an other host
+#
+#destination d_net { tcp("127.0.0.1" port(1000) authentication(on) encrypt(on) log_fifo_size(1000)); };
+
+# Debian only
+destination d_ppp { file("/var/log/ppp.log"); };
+
+########################
+# Filters
+########################
+# Here's come the filter options. With this rules, we can set which
+# message go where.
+
+filter f_dbg { level(debug); };
+filter f_info { level(info); };
+filter f_notice { level(notice); };
+filter f_warn { level(warn); };
+filter f_err { level(err); };
+filter f_crit { level(crit .. emerg); };
+
+filter f_debug { level(debug) and not facility(auth, authpriv, news, mail); };
+filter f_error { level(err .. emerg) ; };
+filter f_messages { level(info,notice,warn) and
+                    not facility(auth,authpriv,cron,daemon,mail,news); };
+
+filter f_auth { facility(auth, authpriv) and not filter(f_debug); };
+filter f_cron { facility(cron) and not filter(f_debug); };
+filter f_daemon { facility(daemon) and not filter(f_debug); };
+filter f_kern { facility(kern) and not filter(f_debug); };
+filter f_lpr { facility(lpr) and not filter(f_debug); };
+filter f_local { facility(local0, local1, local3, local4, local5,
+                        local6, local7) and not filter(f_debug); };
+filter f_mail { facility(mail) and not filter(f_debug); };
+filter f_news { facility(news) and not filter(f_debug); };
+filter f_syslog3 { not facility(auth, authpriv, mail) and not filter(f_debug); };
+filter f_user { facility(user) and not filter(f_debug); };
+filter f_uucp { facility(uucp) and not filter(f_debug); };
+
+filter f_cnews { level(notice, err, crit) and facility(news); };
+filter f_cother { level(debug, info, notice, warn) or facility(daemon, mail); };
+
+filter f_ppp { facility(local2) and not filter(f_debug); };
+filter f_console { level(warn .. emerg); };
+
+########################
+# Log paths
+########################
+log { source(s_src); filter(f_auth); destination(d_auth); };
+log { source(s_src); filter(f_cron); destination(d_cron); };
+log { source(s_src); filter(f_daemon); destination(d_daemon); };
+log { source(s_src); filter(f_kern); destination(d_kern); };
+log { source(s_src); filter(f_lpr); destination(d_lpr); };
+log { source(s_src); filter(f_syslog3); destination(d_syslog); };
+log { source(s_src); filter(f_user); destination(d_user); };
+log { source(s_src); filter(f_uucp); destination(d_uucp); };
+
+log { source(s_src); filter(f_mail); destination(d_mail); };
+#log { source(s_src); filter(f_mail); filter(f_info); destination(d_mailinfo); };
+#log { source(s_src); filter(f_mail); filter(f_warn); destination(d_mailwarn); };
+#log { source(s_src); filter(f_mail); filter(f_err); destination(d_mailerr); };
+
+log { source(s_src); filter(f_news); filter(f_crit); destination(d_newscrit); };
+log { source(s_src); filter(f_news); filter(f_err); destination(d_newserr); };
+log { source(s_src); filter(f_news); filter(f_notice); destination(d_newsnotice); };
+#log { source(s_src); filter(f_cnews); destination(d_console_all); };
+#log { source(s_src); filter(f_cother); destination(d_console_all); };
+
+#log { source(s_src); filter(f_ppp); destination(d_ppp); };
+
+log { source(s_src); filter(f_debug); destination(d_debug); };
+log { source(s_src); filter(f_error); destination(d_error); };
+log { source(s_src); filter(f_messages); destination(d_messages); };
+
+log { source(s_src); filter(f_console); destination(d_console_all);
+				    destination(d_xconsole); };
+log { source(s_src); filter(f_crit); destination(d_console); };
+
+# All messages send to a remote site
+#
+#log { source(s_src); destination(d_net); };
diff --git a/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/syslog-ng.service-the-syslog-ng-service.patch b/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/syslog-ng.service-the-syslog-ng-service.patch
index 6b30c20..39c3f59 100644
--- a/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/syslog-ng.service-the-syslog-ng-service.patch
+++ b/meta-openembedded/meta-oe/recipes-support/syslog-ng/files/syslog-ng.service-the-syslog-ng-service.patch
@@ -7,25 +7,40 @@
 Upstream-Status: pending
 
 Signed-off-by: Li Xin <lixin.fnst@cn.fujitsu.com>
+Updated-by: Andrej Valek <andrej.valek@siemens.com>
 ---
  contrib/systemd/syslog-ng.service | 5 ++---
  1 file changed, 2 insertion(+), 3 deletions(-)
 
-diff --git a/contrib/systemd/syslog-ng.service b/contrib/systemd/syslog-ng.service
-index fc16f8d..8e09deb 100644
---- a/contrib/systemd/syslog-ng.service
-+++ b/contrib/systemd/syslog-ng.service
-@@ -4,8 +4,8 @@ Description=System Logger Daemon
- 
- [Service]
+diff --git a/contrib/systemd/syslog-ng@.service b/contrib/systemd/syslog-ng@.service
+index a28640e..93aec94 100644
+--- a/contrib/systemd/syslog-ng@.service
++++ b/contrib/systemd/syslog-ng@.service
+@@ -7,8 +7,8 @@ Conflicts=emergency.service emergency.target
  Type=notify
--ExecStart=/usr/sbin/syslog-ng -F $SYSLOGNG_OPTS
+ EnvironmentFile=-/etc/default/syslog-ng@%i
+ EnvironmentFile=-/etc/sysconfig/syslog-ng@%i
+-ExecStart=/usr/sbin/syslog-ng -F $OTHER_OPTIONS --cfgfile $CONFIG_FILE --control $CONTROL_FILE --persist-file $PERSIST_FILE --pidfile $PID_FILE
 -ExecReload=/bin/kill -HUP $MAINPID
-+ExecStart=@SBINDIR@/syslog-ng -F $SYSLOGNG_OPTS -p @LOCALSTATEDIR@/run/syslogd.pid
++ExecStart=@SBINDIR@/syslog-ng -F $OTHER_OPTIONS --cfgfile $CONFIG_FILE --control $CONTROL_FILE --persist-file $PERSIST_FILE --pidfile $PID_FILE
 +ExecReload=@BASEBINDIR@/kill -HUP $MAINPID
- EnvironmentFile=-/etc/default/syslog-ng
- EnvironmentFile=-/etc/sysconfig/syslog-ng
  StandardOutput=journal
+ StandardError=journal
+ Restart=on-failure
+diff --git a/contrib/systemd/syslog-ng@default b/contrib/systemd/syslog-ng@default
+index 02da288..3a8215d 100644
+--- a/contrib/systemd/syslog-ng@default
++++ b/contrib/systemd/syslog-ng@default
+@@ -1,5 +1,5 @@
+-CONFIG_FILE=/etc/syslog-ng.conf
+-PERSIST_FILE=/var/lib/syslog-ng/syslog-ng.persist
+-CONTROL_FILE=/var/lib/syslog-ng/syslog-ng.ctl
+-PID_FILE=/var/run/syslog-ng.pid
++CONFIG_FILE=/etc/syslog-ng/syslog-ng.conf
++PERSIST_FILE=@LOCALSTATEDIR@/lib/syslog-ng/syslog-ng.persist
++CONTROL_FILE=@LOCALSTATEDIR@/lib/syslog-ng/syslog-ng.ctl
++PID_FILE=@LOCALSTATEDIR@/run/syslog-ng.pid
+ OTHER_OPTIONS="--enable-core"
+
 -- 
 1.8.4.2
-
diff --git a/meta-openembedded/meta-oe/recipes-support/syslog-ng/syslog-ng.inc b/meta-openembedded/meta-oe/recipes-support/syslog-ng/syslog-ng.inc
index 771cdb1..b52deff 100644
--- a/meta-openembedded/meta-oe/recipes-support/syslog-ng/syslog-ng.inc
+++ b/meta-openembedded/meta-oe/recipes-support/syslog-ng/syslog-ng.inc
@@ -13,15 +13,18 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=24c0c5cb2c83d9f2ab725481e4df5240"
 
 # util-linux added to get libuuid
-DEPENDS = "libpcre flex eventlog glib-2.0 openssl util-linux"
+DEPENDS = "libpcre flex glib-2.0 openssl util-linux"
 
 SRC_URI = "https://github.com/balabit/syslog-ng/releases/download/${BP}/${BP}.tar.gz \
-           file://syslog-ng.conf \
+           file://syslog-ng.conf.systemd \
+           file://syslog-ng.conf.sysvinit \
            file://initscript \
            file://volatiles.03_syslog-ng \
            file://configure.ac-add-option-enable-thread-tls-to-manage-.patch \
 "
 
+UPSTREAM_CHECK_URI = "https://github.com/balabit/syslog-ng/releases"
+
 inherit autotools gettext systemd pkgconfig update-rc.d
 
 EXTRA_OECONF = " \
@@ -67,15 +70,8 @@
 	cd $olddir
 }
 
-do_install_prepend() {
-    sed -i -e 's,@SBINDIR@,${sbindir},g' ${S}/contrib/systemd/*.service
-    sed -i -e 's,@LOCALSTATEDIR@,${localstatedir},g' ${S}/contrib/systemd/*.service
-    sed -i -e 's,@BASEBINDIR@,${base_bindir},g' ${S}/contrib/systemd/*.service
-}
-
 do_install_append() {
     install -d ${D}/${sysconfdir}/${BPN}
-    install ${WORKDIR}/syslog-ng.conf ${D}${sysconfdir}/${BPN}/${BPN}.conf
     install -d ${D}/${sysconfdir}/init.d
     install -m 755 ${WORKDIR}/initscript ${D}/${sysconfdir}/init.d/syslog
     install -d ${D}/${sysconfdir}/default/volatiles/
@@ -83,16 +79,43 @@
     install -d ${D}/${localstatedir}/lib/${BPN}
     # Remove /var/run as it is created on startup
     rm -rf ${D}${localstatedir}/run
+
+    # support for systemd
+    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
+        install ${WORKDIR}/syslog-ng.conf.systemd ${D}${sysconfdir}/${BPN}/${BPN}.conf
+
+        install -d ${D}${systemd_unitdir}/system/
+        install -m 0644 ${S}/contrib/systemd/${BPN}@.service ${D}${systemd_unitdir}/system/${BPN}@.service
+        install -m 0644 ${S}/contrib/systemd/${BPN}@default ${D}${sysconfdir}/default/${BPN}@default
+
+        sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/${BPN}@.service ${D}${sysconfdir}/default/${BPN}@default
+        sed -i -e 's,@LOCALSTATEDIR@,${localstatedir},g' ${D}${systemd_unitdir}/system/${BPN}@.service ${D}${sysconfdir}/default/${BPN}@default
+        sed -i -e 's,@BASEBINDIR@,${base_bindir},g' ${D}${systemd_unitdir}/system/${BPN}@.service ${D}${sysconfdir}/default/${BPN}@default
+
+        install -d ${D}${systemd_unitdir}/system/multi-user.target.wants
+        ln -sf ../${BPN}@.service ${D}${systemd_unitdir}/system/multi-user.target.wants/${BPN}@default.service
+    else
+        install ${WORKDIR}/syslog-ng.conf.sysvinit ${D}${sysconfdir}/${BPN}/${BPN}.conf
+    fi
 }
 
-FILES_${PN} += "${datadir}/include/scl/ ${datadir}/xsd ${datadir}/tools"
-RDEPENDS_${PN} += "gawk"
+FILES_${PN} += "${datadir}/include/scl/ ${datadir}/xsd ${datadir}/tools ${systemd_unitdir}/system/multi-user.target.wants/*"
+RDEPENDS_${PN} += "gawk ${@bb.utils.contains('PACKAGECONFIG','json','${PN}-jconf','',d)}"
+
+FILES_${PN}-jconf += " \
+${datadir}/${BPN}/include/scl/cim \
+${datadir}/${BPN}/include/scl/elasticsearch \
+${datadir}/${BPN}/include/scl/ewmm \
+${datadir}/${BPN}/include/scl/graylog2 \
+${datadir}/${BPN}/include/scl/loggly \
+${datadir}/${BPN}/include/scl/logmatic \
+"
 
 # This overcomes the syslog-ng rdepends on syslog-ng-dev QA Error
-PACKAGES =+ "${PN}-libs ${PN}-libs-dev ${PN}-libs-dbg"
+PACKAGES =+ "${PN}-jconf ${PN}-libs ${PN}-libs-dev"
+RPROVIDES_${PN}-dbg += "${PN}-libs-dbg"
 FILES_${PN}-libs = "${libdir}/${BPN}/*.so ${libdir}/libsyslog-ng-*.so*"
 FILES_${PN}-libs-dev = "${libdir}/${BPN}/lib*.la"
-FILES_${PN}-libs-dbg = "${libdir}/${BPN}/.debug"
 FILES_${PN}-staticdev += "${libdir}/${BPN}/libtest/*.a"
 INSANE_SKIP_${PN}-libs = "dev-so"
 RDEPENDS_${PN} += "${PN}-libs"
@@ -108,7 +131,7 @@
 RPROVIDES_${PN} += "${PN}-systemd"
 RREPLACES_${PN} += "${PN}-systemd"
 RCONFLICTS_${PN} += "${PN}-systemd"
-SYSTEMD_SERVICE_${PN} = "${BPN}.service"
+SYSTEMD_SERVICE_${PN} = "${BPN}@.service"
 
 INITSCRIPT_NAME = "syslog"
 INITSCRIPT_PARAMS = "start 20 2 3 4 5 . stop 90 0 1 6 ."
diff --git a/meta-openembedded/meta-oe/recipes-support/syslog-ng/syslog-ng_3.16.1.bb b/meta-openembedded/meta-oe/recipes-support/syslog-ng/syslog-ng_3.16.1.bb
new file mode 100644
index 0000000..b5f42cf
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/syslog-ng/syslog-ng_3.16.1.bb
@@ -0,0 +1,16 @@
+require syslog-ng.inc
+
+SRC_URI = "https://github.com/balabit/syslog-ng/releases/download/${BP}/${BP}.tar.gz \
+           file://syslog-ng.conf.systemd \
+           file://syslog-ng.conf.sysvinit \
+           file://initscript \
+           file://volatiles.03_syslog-ng \
+           file://configure.ac-add-option-enable-thread-tls-to-manage-.patch \
+           file://fix-config-libnet.patch \
+           file://fix-invalid-ownership.patch \
+           file://syslog-ng.service-the-syslog-ng-service.patch \
+           file://0001-syslog-ng-fix-segment-fault-during-service-start.patch \
+           "
+
+SRC_URI[md5sum] = "72d44ad02c2e9ba0748b3ecd3f15a7ff"
+SRC_URI[sha256sum] = "c7ee6f1d5e98d86f191964e580111bfa71081ecbb3275cea035bbba177b73a29"
diff --git a/meta-openembedded/meta-oe/recipes-support/syslog-ng/syslog-ng_3.8.1.bb b/meta-openembedded/meta-oe/recipes-support/syslog-ng/syslog-ng_3.8.1.bb
deleted file mode 100644
index 91a0e46..0000000
--- a/meta-openembedded/meta-oe/recipes-support/syslog-ng/syslog-ng_3.8.1.bb
+++ /dev/null
@@ -1,11 +0,0 @@
-require syslog-ng.inc
-
-SRC_URI += " \
-    file://fix-config-libnet.patch \
-    file://fix-invalid-ownership.patch \
-    file://Fix-the-memory-leak-problem-when-HAVE_ENVIRON-defined.patch \
-    file://syslog-ng.service-the-syslog-ng-service.patch \
-"
-
-SRC_URI[md5sum] = "acf14563cf5ce435db8db35486ce66af"
-SRC_URI[sha256sum] = "84b081f6e5f98cbc52052e342bcfdc5de5fe0ebe9f5ec32fe9eaec5759224cc5"
diff --git a/meta-openembedded/meta-oe/recipes-support/thin-provisioning-tools/files/0001-do-not-strip-pdata_tools-at-do_install.patch b/meta-openembedded/meta-oe/recipes-support/thin-provisioning-tools/files/0001-do-not-strip-pdata_tools-at-do_install.patch
index b4cdda1..547949d 100644
--- a/meta-openembedded/meta-oe/recipes-support/thin-provisioning-tools/files/0001-do-not-strip-pdata_tools-at-do_install.patch
+++ b/meta-openembedded/meta-oe/recipes-support/thin-provisioning-tools/files/0001-do-not-strip-pdata_tools-at-do_install.patch
@@ -1,6 +1,6 @@
-From e8be402e20cbdfbd8192a171ac9904d9362103bf Mon Sep 17 00:00:00 2001
+From de869ad2cb19d81257a159770ebe27593a71593c Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Wed, 31 Aug 2016 01:35:40 -0400
+Date: Tue, 31 Jul 2018 11:29:51 +0800
 Subject: [PATCH] do not strip pdata_tools at do_install
 
 It caused QA Issue:
@@ -17,11 +17,11 @@
  1 file changed, 1 deletion(-)
 
 diff --git a/Makefile.in b/Makefile.in
-index 4264191..ac22042 100644
+index 02b75dd..df590b4 100644
 --- a/Makefile.in
 +++ b/Makefile.in
-@@ -189,7 +189,6 @@ distclean: clean
- install: bin/pdata_tools
+@@ -267,7 +267,6 @@ MANPAGES:=$(patsubst %,man8/%.8,$(TOOLS))
+ install: bin/pdata_tools $(MANPAGES)
  	$(INSTALL_DIR) $(BINDIR)
  	$(INSTALL_PROGRAM) bin/pdata_tools $(BINDIR)
 -	$(STRIP) $(BINDIR)/pdata_tools
@@ -29,5 +29,5 @@
  	ln -s -f pdata_tools $(BINDIR)/cache_dump
  	ln -s -f pdata_tools $(BINDIR)/cache_metadata_size
 -- 
-2.8.1
+2.7.4
 
diff --git a/meta-openembedded/meta-oe/recipes-support/thin-provisioning-tools/files/0001-fix-compile-failed-with-libc-musl.patch b/meta-openembedded/meta-oe/recipes-support/thin-provisioning-tools/files/0001-fix-compile-failed-with-libc-musl.patch
new file mode 100644
index 0000000..28b44da
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/thin-provisioning-tools/files/0001-fix-compile-failed-with-libc-musl.patch
@@ -0,0 +1,42 @@
+From fcbcf9c494cca166106ae4cb03c1dd135ee4f25c Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Wed, 1 Aug 2018 09:34:00 +0800
+Subject: [PATCH] fix compile failed with libc musl
+
+There is a failure while compiling with libc musl:
+[snip]
+|./block-cache/io_engine.h:18:17: error: expected
+unqualified-id before numeric constant
+|  unsigned const PAGE_SIZE = 4096;
+[snip]
+
+The musl defeines macro PAGE_SIZE, undef it conditionally
+could fix the issue.
+
+http://musl.openwall.narkive.com/tO8vrHdP/why-musl-define-page-size
+
+Upstream-Status: Submitted [git://github.com/jthornber/thin-provisioning-tools]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ block-cache/io_engine.h | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/block-cache/io_engine.h b/block-cache/io_engine.h
+index 1704251..e36b932 100644
+--- a/block-cache/io_engine.h
++++ b/block-cache/io_engine.h
+@@ -12,6 +12,10 @@
+ 
+ //----------------------------------------------------------------
+ 
++// Musl defines
++#ifdef PAGE_SIZE
++#undef PAGE_SIZE
++#endif
+ namespace bcache {
+ 	using sector_t = uint64_t;
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/thin-provisioning-tools/thin-provisioning-tools_0.6.3.bb b/meta-openembedded/meta-oe/recipes-support/thin-provisioning-tools/thin-provisioning-tools_0.6.3.bb
deleted file mode 100755
index c9d6690..0000000
--- a/meta-openembedded/meta-oe/recipes-support/thin-provisioning-tools/thin-provisioning-tools_0.6.3.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-SUMMARY = "Tools of dm-thin device-mapper"
-DESCRIPTION = "A suite of tools for manipulating the metadata of the dm-thin device-mapper target."
-HOMEPAGE = "https://github.com/jthornber/thin-provisioning-tools"
-LICENSE = "GPLv3"
-SECTION = "devel"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
-S = "${WORKDIR}/git"
-
-SRC_URI = "git://github.com/jthornber/thin-provisioning-tools \
-           file://0001-do-not-strip-pdata_tools-at-do_install.patch \
-"
-
-SRCREV = "49bfc12e9c7956c1ac134b24afbe1a6a602ce7d5"
-
-DEPENDS += "expat libaio boost"
-
-inherit autotools-brokensep
diff --git a/meta-openembedded/meta-oe/recipes-support/thin-provisioning-tools/thin-provisioning-tools_0.7.6.bb b/meta-openembedded/meta-oe/recipes-support/thin-provisioning-tools/thin-provisioning-tools_0.7.6.bb
new file mode 100644
index 0000000..20cb17a
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/thin-provisioning-tools/thin-provisioning-tools_0.7.6.bb
@@ -0,0 +1,21 @@
+SUMMARY = "Tools of dm-thin device-mapper"
+DESCRIPTION = "A suite of tools for manipulating the metadata of the dm-thin device-mapper target."
+HOMEPAGE = "https://github.com/jthornber/thin-provisioning-tools"
+LICENSE = "GPLv3"
+SECTION = "devel"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
+S = "${WORKDIR}/git"
+
+SRC_URI = "git://github.com/jthornber/thin-provisioning-tools \
+           file://0001-do-not-strip-pdata_tools-at-do_install.patch \
+           file://0001-fix-compile-failed-with-libc-musl.patch \
+"
+
+SRCREV = "6f936992b8e6208a7838fcf1ec87c5bd3a694a77"
+
+UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+(\.\d+)+)"
+
+DEPENDS += "expat libaio boost"
+
+inherit autotools-brokensep
diff --git a/meta-openembedded/meta-oe/recipes-support/udisks/udisks/0001-include-sys-sysmacros.h.patch b/meta-openembedded/meta-oe/recipes-support/udisks/udisks/0001-include-sys-sysmacros.h.patch
new file mode 100644
index 0000000..f140793
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/udisks/udisks/0001-include-sys-sysmacros.h.patch
@@ -0,0 +1,77 @@
+From 64f051963d6cdeebd19f9e7f0a7e584a1f7acc60 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 11 Aug 2018 19:12:57 -0700
+Subject: [PATCH] include sys/sysmacros.h
+
+fixes build with glibc 2.28+
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/daemon.c          | 1 +
+ src/device.c          | 1 +
+ src/mount-monitor.c   | 1 +
+ tools/udisks.c        | 1 +
+ tools/umount-udisks.c | 1 +
+ 5 files changed, 5 insertions(+)
+
+diff --git a/src/daemon.c b/src/daemon.c
+index 14e952f..2c61cfb 100644
+--- a/src/daemon.c
++++ b/src/daemon.c
+@@ -39,6 +39,7 @@
+ #include <errno.h>
+ #include <string.h>
+ #include <sys/types.h>
++#include <sys/sysmacros.h>
+ #include <sys/stat.h>
+ #include <sys/time.h>
+ #include <sys/resource.h>
+diff --git a/src/device.c b/src/device.c
+index d73f9d6..5911d78 100644
+--- a/src/device.c
++++ b/src/device.c
+@@ -29,6 +29,7 @@
+ #include <errno.h>
+ #include <string.h>
+ #include <sys/types.h>
++#include <sys/sysmacros.h>
+ #include <sys/wait.h>
+ #include <sys/stat.h>
+ #include <sys/time.h>
+diff --git a/src/mount-monitor.c b/src/mount-monitor.c
+index 573a69c..ccf3365 100644
+--- a/src/mount-monitor.c
++++ b/src/mount-monitor.c
+@@ -28,6 +28,7 @@
+ #include <errno.h>
+ #include <string.h>
+ #include <sys/types.h>
++#include <sys/sysmacros.h>
+ #include <sys/stat.h>
+ #include <mntent.h>
+ 
+diff --git a/tools/udisks.c b/tools/udisks.c
+index d30159b..f24a30a 100644
+--- a/tools/udisks.c
++++ b/tools/udisks.c
+@@ -29,6 +29,7 @@
+ #include <errno.h>
+ #include <string.h>
+ #include <sys/types.h>
++#include <sys/sysmacros.h>
+ #include <sys/stat.h>
+ #include <sys/wait.h>
+ #include <fcntl.h>
+diff --git a/tools/umount-udisks.c b/tools/umount-udisks.c
+index 2813fe0..5cf6b4d 100644
+--- a/tools/umount-udisks.c
++++ b/tools/umount-udisks.c
+@@ -29,6 +29,7 @@
+ #include <errno.h>
+ #include <string.h>
+ #include <sys/types.h>
++#include <sys/sysmacros.h>
+ #include <sys/stat.h>
+ #include <fcntl.h>
+ #include <pwd.h>
diff --git a/meta-openembedded/meta-oe/recipes-support/udisks/udisks2/0001-data-fix-out-of-tree-build.patch b/meta-openembedded/meta-oe/recipes-support/udisks/udisks2/0001-data-fix-out-of-tree-build.patch
deleted file mode 100644
index 1cbd877..0000000
--- a/meta-openembedded/meta-oe/recipes-support/udisks/udisks2/0001-data-fix-out-of-tree-build.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From 7fdd4acdf6daf95c5cc74e968f4710513c8ddaea Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
-Date: Fri, 23 Mar 2018 18:33:52 +0100
-Subject: [PATCH] data: fix out of tree build
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-| sed: can't read udisks2.service.in: No such file or directory
-
-Upstream-Status: Submitted [1]
-
-[1] https://github.com/storaged-project/udisks/pull/510
-
-Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
----
- data/Makefile.am | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/data/Makefile.am b/data/Makefile.am
-index ddf9e3d6..b38928c8 100644
---- a/data/Makefile.am
-+++ b/data/Makefile.am
-@@ -22,7 +22,7 @@ systemdservicedir       = $(systemdsystemunitdir)
- systemdservice_DATA     = $(systemdservice_in_files:.service.in=.service)
- 
- $(systemdservice_DATA): udisks2.service.in Makefile
--	@sed -e "s|\@udisksdprivdir\@|$(libexecdir)/udisks2|" udisks2.service.in > udisks2.service
-+	@sed -e "s|\@udisksdprivdir\@|$(libexecdir)/udisks2|" $(srcdir)/udisks2.service.in > udisks2.service
- endif
- 
- udevrulesdir = $(udevdir)/rules.d
--- 
-2.14.3
-
diff --git a/meta-openembedded/meta-oe/recipes-support/udisks/udisks2_2.7.6.bb b/meta-openembedded/meta-oe/recipes-support/udisks/udisks2_2.7.6.bb
deleted file mode 100644
index 4d22afd..0000000
--- a/meta-openembedded/meta-oe/recipes-support/udisks/udisks2_2.7.6.bb
+++ /dev/null
@@ -1,49 +0,0 @@
-SUMMARY = "udisks provides dbus interfaces for disks and storage devices"
-LICENSE = "GPLv2+ & LGPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=dd79f6dbbffdbc8e86b086a8f0c0ef43"
-
-DEPENDS = " \
-    acl \
-    libatasmart \
-    polkit \
-    libgudev \
-    dbus-glib \
-    glib-2.0 \
-    libblockdev \
-    intltool-native \
-    gnome-common-native \
-    libxslt-native \
-"
-DEPENDS += "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
-
-RDEPENDS_${PN} = "acl"
-
-SRC_URI = " \
-    git://github.com/storaged-project/udisks.git \
-    file://0001-data-fix-out-of-tree-build.patch \
-    file://non-gnu-libc.patch \
-"
-SRCREV = "b6471f2e99f6aa1133af0de658f1fa05c748932c"
-S = "${WORKDIR}/git"
-
-CVE_PRODUCT = "udisks"
-
-inherit autotools systemd gtk-doc gobject-introspection
-
-EXTRA_OECONF = "--disable-man --disable-gtk-doc"
-
-FILES_${PN} += " \
-    ${datadir}/dbus-1/ \
-    ${datadir}/polkit-1 \
-    ${datadir}/bash-completion \
-    ${libdir}/polkit-1/extensions/*.so \
-    ${nonarch_base_libdir}/udev/* \
-    ${exec_prefix}${nonarch_base_libdir}/udisks2/* \
-    ${systemd_system_unitdir} \
-"
-
-PACKAGES =+ "${PN}-libs"
-FILES_${PN}-libs = "${libdir}/lib*${SOLIBS}"
-
-SYSTEMD_SERVICE_${PN} = "${BPN}.service"
-SYSTEMD_AUTO_ENABLE = "disable"
diff --git a/meta-openembedded/meta-oe/recipes-support/udisks/udisks2_2.7.8.bb b/meta-openembedded/meta-oe/recipes-support/udisks/udisks2_2.7.8.bb
new file mode 100644
index 0000000..64b338f
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/udisks/udisks2_2.7.8.bb
@@ -0,0 +1,48 @@
+SUMMARY = "udisks provides dbus interfaces for disks and storage devices"
+LICENSE = "GPLv2+ & LGPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=dd79f6dbbffdbc8e86b086a8f0c0ef43"
+
+DEPENDS = " \
+    acl \
+    libatasmart \
+    polkit \
+    libgudev \
+    dbus-glib \
+    glib-2.0 \
+    libblockdev \
+    intltool-native \
+    gnome-common-native \
+    libxslt-native \
+"
+DEPENDS += "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
+
+RDEPENDS_${PN} = "acl"
+
+SRC_URI = " \
+    git://github.com/storaged-project/udisks.git;branch=2.7.x-branch \
+    file://non-gnu-libc.patch \
+"
+SRCREV = "47bc0141cb84624ba1e2242d596a89a30df1f5ea"
+S = "${WORKDIR}/git"
+
+CVE_PRODUCT = "udisks"
+
+inherit autotools systemd gtk-doc gobject-introspection
+
+EXTRA_OECONF = "--disable-man --disable-gtk-doc"
+
+FILES_${PN} += " \
+    ${datadir}/dbus-1/ \
+    ${datadir}/polkit-1 \
+    ${datadir}/bash-completion \
+    ${libdir}/polkit-1/extensions/*.so \
+    ${nonarch_base_libdir}/udev/* \
+    ${exec_prefix}${nonarch_base_libdir}/udisks2/* \
+    ${systemd_system_unitdir} \
+"
+
+PACKAGES =+ "${PN}-libs"
+FILES_${PN}-libs = "${libdir}/lib*${SOLIBS}"
+
+SYSTEMD_SERVICE_${PN} = "${BPN}.service"
+SYSTEMD_AUTO_ENABLE = "disable"
diff --git a/meta-openembedded/meta-oe/recipes-support/udisks/udisks_1.0.5.bb b/meta-openembedded/meta-oe/recipes-support/udisks/udisks_1.0.5.bb
index e332660..7cd9992 100644
--- a/meta-openembedded/meta-oe/recipes-support/udisks/udisks_1.0.5.bb
+++ b/meta-openembedded/meta-oe/recipes-support/udisks/udisks_1.0.5.bb
@@ -11,13 +11,13 @@
     dbus-glib-native \
 "
 
-SRC_URI = " \
-    http://hal.freedesktop.org/releases/${BPN}-${PV}.tar.gz;name=${BPN} \
-    file://optional-depends.patch \
-    file://0001-fix-build-with-newer-glibc-versions.patch \
-    file://udisks-1.0.5-fix-service-file.patch \
-    file://0001-Make-udev-rules-directory-configurable.patch \
-"
+SRC_URI = "http://hal.freedesktop.org/releases/${BPN}-${PV}.tar.gz;name=${BPN} \
+           file://optional-depends.patch \
+           file://0001-fix-build-with-newer-glibc-versions.patch \
+           file://udisks-1.0.5-fix-service-file.patch \
+           file://0001-Make-udev-rules-directory-configurable.patch \
+           file://0001-include-sys-sysmacros.h.patch \
+           "
 
 SRC_URI[udisks.md5sum] = "70d48dcfe523a74cd7c7fbbc2847fcdd"
 SRC_URI[udisks.sha256sum] = "f2ec82eb0ea7e01dc299b5b29b3c18cdf861236ec43dcff66b3552b4b31c6f71"
diff --git a/meta-openembedded/meta-oe/recipes-support/uhubctl/uhubctl_2.0.0.bb b/meta-openembedded/meta-oe/recipes-support/uhubctl/uhubctl_2.0.0.bb
new file mode 100644
index 0000000..6306ddb
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/uhubctl/uhubctl_2.0.0.bb
@@ -0,0 +1,21 @@
+SUMMARY = "USB hub per-port power control"
+HOMEPAGE = "https://github.com/mvp/uhubctl"
+BUGTRACKER = "https://github.com/mvp/uhubctl/issues"
+DEPENDS = "libusb1"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+SRC_URI = "https://github.com/mvp/${PN}/archive/v${PV}.tar.gz"
+SRC_URI[md5sum] = "5c711911d766d76813333c3812277574"
+SRC_URI[sha256sum] = "4c31278b2c03e5be5a696c3088bc86cf2557a70e00f697799c163aba18e3c40e"
+
+# uhubctl gets its program version from "git describe". As we use the source
+# archive do reduce download size replace the call with our hardcoded version.
+do_configure_append() {
+    sed -i "s/^\(GIT_VERSION :=\).*$/\1 ${PV}/g" ${S}/Makefile
+}
+
+do_install () {
+    oe_runmake install DESTDIR=${D}
+}
diff --git a/meta-openembedded/meta-oe/recipes-support/unixodbc/unixodbc_2.3.6.bb b/meta-openembedded/meta-oe/recipes-support/unixodbc/unixodbc_2.3.6.bb
index 62d9db8..2674d35 100644
--- a/meta-openembedded/meta-oe/recipes-support/unixodbc/unixodbc_2.3.6.bb
+++ b/meta-openembedded/meta-oe/recipes-support/unixodbc/unixodbc_2.3.6.bb
@@ -14,6 +14,8 @@
 SRC_URI[md5sum] = "a8629fd2953b04b4639d0a9d8a5cf9d1"
 SRC_URI[sha256sum] = "88b637f647c052ecc3861a3baa275c3b503b193b6a49ff8c28b2568656d14d69"
 
+UPSTREAM_CHECK_REGEX = "unixODBC-(?P<pver>\d+(\.\d+)+)\.tar"
+
 inherit autotools-brokensep
 
 S = "${WORKDIR}/unixODBC-${PV}"
diff --git a/meta-openembedded/meta-oe/recipes-support/upower/upower/0001-linux-lower-severity-of-unhandled-action-messages.patch b/meta-openembedded/meta-oe/recipes-support/upower/upower/0001-linux-lower-severity-of-unhandled-action-messages.patch
new file mode 100644
index 0000000..de89dc0
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/upower/upower/0001-linux-lower-severity-of-unhandled-action-messages.patch
@@ -0,0 +1,31 @@
+From f64b6ce8054b47e5bdcc8c4c7965534b388e6151 Mon Sep 17 00:00:00 2001
+From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
+Date: Fri, 6 Apr 2018 11:26:54 -0700
+Subject: [PATCH] linux: lower severity of "unhandled action" messages
+
+Newer kernels emit bind/unbind uevents that are not of interest to
+powerd. To avoid littering logs with scary messages, let's lower their
+severity to "debug".
+
+https://bugs.freedesktop.org/show_bug.cgi?id=106019
+
+Upstream-Status: Backport
+---
+ src/linux/up-backend.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/linux/up-backend.c b/src/linux/up-backend.c
+index e668dc8..b8021e7 100644
+--- a/src/linux/up-backend.c
++++ b/src/linux/up-backend.c
+@@ -273,7 +273,7 @@ up_backend_uevent_signal_handler_cb (GUdevClient *client, const gchar *action,
+ 		g_debug ("SYSFS change %s", g_udev_device_get_sysfs_path (device));
+ 		up_backend_device_changed (backend, device);
+ 	} else {
+-		g_warning ("unhandled action '%s' on %s", action, g_udev_device_get_sysfs_path (device));
++		g_debug ("unhandled action '%s' on %s", action, g_udev_device_get_sysfs_path (device));
+ 	}
+ }
+ 
+-- 
+2.17.0.484.g0c8726318c-goog
diff --git a/meta-openembedded/meta-oe/recipes-support/upower/upower_0.99.7.bb b/meta-openembedded/meta-oe/recipes-support/upower/upower_0.99.7.bb
index 973fbe7..2cf3163 100644
--- a/meta-openembedded/meta-oe/recipes-support/upower/upower_0.99.7.bb
+++ b/meta-openembedded/meta-oe/recipes-support/upower/upower_0.99.7.bb
@@ -4,7 +4,10 @@
 
 DEPENDS = "intltool-native libusb1 libgudev glib-2.0 dbus-glib polkit"
 
-SRC_URI = "http://upower.freedesktop.org/releases/${BPN}-${PV}.tar.xz"
+SRC_URI = " \
+    http://upower.freedesktop.org/releases/${BPN}-${PV}.tar.xz \
+    file://0001-linux-lower-severity-of-unhandled-action-messages.patch \
+"
 SRC_URI[md5sum] = "236bb439d9ff1151450b3d8582399532"
 SRC_URI[sha256sum] = "24bcc2f6ab25a2533bac70b587bcb019e591293076920f5b5e04bdedc140a401"
 
diff --git a/meta-openembedded/meta-oe/recipes-support/uriparser/uriparser_0.8.4.bb b/meta-openembedded/meta-oe/recipes-support/uriparser/uriparser_0.8.4.bb
index b4be853..bfcdf83 100644
--- a/meta-openembedded/meta-oe/recipes-support/uriparser/uriparser_0.8.4.bb
+++ b/meta-openembedded/meta-oe/recipes-support/uriparser/uriparser_0.8.4.bb
@@ -12,3 +12,5 @@
 
 SRC_URI[md5sum] = "9aabdc3611546f553f4af372167de6d6"
 SRC_URI[sha256sum] = "ce7ccda4136974889231e8426a785e7578e66a6283009cfd13f1b24a5e657b23"
+
+BBCLASSEXTEND += "native"
diff --git a/meta-openembedded/meta-oe/recipes-support/vboxguestdrivers/vboxguestdrivers/kernel-4.18.patch b/meta-openembedded/meta-oe/recipes-support/vboxguestdrivers/vboxguestdrivers/kernel-4.18.patch
new file mode 100644
index 0000000..93eaa3d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/vboxguestdrivers/vboxguestdrivers/kernel-4.18.patch
@@ -0,0 +1,33 @@
+Description: Fix build failure with new kernel 4.18
+Author: Gianfranco Costamagna <locutusofborg@debian.org>
+
+Upstream-Status:Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Index: vbox_module/vboxsf/utils.c
+===================================================================
+--- vbox_module.orig/vboxsf/utils.c
++++ vbox_module/vboxsf/utils.c
+@@ -50,7 +50,11 @@ static void sf_timespec_from_ftime(RTTIM
+     RTTimeSpecSetNano(ts, t);
+ }
+ #else /* >= 2.6.0 */
++#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 18, 0)
+ static void sf_ftime_from_timespec(struct timespec *tv, RTTIMESPEC *ts)
++#else
++static void sf_ftime_from_timespec(struct timespec64 *tv, RTTIMESPEC *ts)
++#endif
+ {
+     int64_t t = RTTimeSpecGetNano(ts);
+     int64_t nsec;
+@@ -60,7 +64,11 @@ static void sf_ftime_from_timespec(struc
+     tv->tv_nsec = nsec;
+ }
+ 
++#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 18, 0)
+ static void sf_timespec_from_ftime(RTTIMESPEC *ts, struct timespec *tv)
++#else
++static void sf_timespec_from_ftime(RTTIMESPEC *ts, struct timespec64 *tv)
++#endif
+ {
+     int64_t t = (int64_t)tv->tv_nsec + (int64_t)tv->tv_sec * 1000000000;
+     RTTimeSpecSetNano(ts, t);
diff --git a/meta-openembedded/meta-oe/recipes-support/vboxguestdrivers/vboxguestdrivers_5.2.18.bb b/meta-openembedded/meta-oe/recipes-support/vboxguestdrivers/vboxguestdrivers_5.2.18.bb
new file mode 100644
index 0000000..2a4cc38
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/vboxguestdrivers/vboxguestdrivers_5.2.18.bb
@@ -0,0 +1,78 @@
+SUMMARY = "VirtualBox Linux Guest Drivers"
+SECTION = "core"
+LICENSE = "GPL-2.0"
+LIC_FILES_CHKSUM = "file://${WORKDIR}/${VBOX_NAME}/COPYING;md5=e197d5641bb35b29d46ca8c4bf7f2660"
+
+DEPENDS = "virtual/kernel"
+
+inherit module kernel-module-split
+
+COMPATIBLE_MACHINE = "(qemux86|qemux86-64)"
+
+VBOX_NAME = "VirtualBox-${PV}"
+
+SRC_URI = "http://download.virtualbox.org/virtualbox/${PV}/${VBOX_NAME}.tar.bz2 \
+    file://Makefile.utils \
+    file://kernel-4.18.patch \
+"
+SRC_URI[md5sum] = "d8e291525b84569356773eef507c49ce"
+SRC_URI[sha256sum] = "ed0a7efd56c7f39fae79c7ec3321473da412ef0d7914457b66f42679d513efcf"
+
+S = "${WORKDIR}/vbox_module"
+
+export BUILD_TARGET_ARCH="${ARCH}"
+export BUILD_TARGET_ARCH_x86-64="amd64"
+
+EXTRA_OEMAKE += "KERN_DIR='${WORKDIR}/${KERNEL_VERSION}/build'"
+
+addtask export_sources before do_patch after do_unpack
+
+do_export_sources() {
+    mkdir -p "${S}"
+    ${WORKDIR}/${VBOX_NAME}/src/VBox/Additions/linux/export_modules.sh ${T}/vbox_modules.tar.gz
+    tar -C "${S}" -xzf ${T}/vbox_modules.tar.gz
+
+    # add a mount utility to use shared folder from VBox Addition Source Code
+    mkdir -p "${S}/utils"
+    install ${WORKDIR}/${VBOX_NAME}/src/VBox/Additions/linux/sharedfolders/mount.vboxsf.c ${S}/utils
+    install ${WORKDIR}/${VBOX_NAME}/src/VBox/Additions/linux/sharedfolders/vbsfmount.c ${S}/utils
+    install ${S}/../Makefile.utils ${S}/utils/Makefile
+
+}
+
+do_configure_prepend() {
+    # vboxguestdrivers/5.2.6-r0/vbox_module/vboxguest/Makefile.include.header:99: *** The variable KERN_DIR must be a kernel build folder and end with /build without a trailing slash, or KERN_VER must be set.  Stop.
+    # vboxguestdrivers/5.2.6-r0/vbox_module/vboxguest/Makefile.include.header:108: *** The kernel build folder path must end in <version>/build, or the variable KERN_VER must be set.  Stop.
+    mkdir -p ${WORKDIR}/${KERNEL_VERSION}
+    ln -snf ${STAGING_KERNEL_DIR} ${WORKDIR}/${KERNEL_VERSION}/build
+}
+
+# compile and install mount utility
+do_compile_append() {
+    oe_runmake 'LD=${CC}' 'LDFLAGS=${LDFLAGS}' -C ${S}/utils
+    if ! [ -e vboxguest.ko -a -e vboxsf.ko -a -e vboxvideo.ko ] ; then
+        echo "ERROR: One of vbox*.ko modules wasn't built"
+        exit 1
+    fi
+}
+
+module_do_install() {
+    MODULE_DIR=${D}${nonarch_base_libdir}/modules/${KERNEL_VERSION}/kernel/misc
+    install -d $MODULE_DIR
+    install -m 644 vboxguest.ko $MODULE_DIR
+    install -m 644 vboxsf.ko $MODULE_DIR
+    install -m 644 vboxvideo.ko $MODULE_DIR
+}
+
+do_install_append() {
+    install -d ${D}${base_sbindir}
+    install -m 755 ${S}/utils/mount.vboxsf ${D}${base_sbindir}
+}
+
+PACKAGES += "kernel-module-vboxguest kernel-module-vboxsf kernel-module-vboxvideo"
+RRECOMMENDS_${PN} += "kernel-module-vboxguest kernel-module-vboxsf kernel-module-vboxvideo"
+
+FILES_${PN} = "${base_sbindir}"
+
+# autoload if installed
+KERNEL_MODULE_AUTOLOAD += "vboxguest vboxsf vboxvideo"
diff --git a/meta-openembedded/meta-oe/recipes-support/vboxguestdrivers/vboxguestdrivers_5.2.8.bb b/meta-openembedded/meta-oe/recipes-support/vboxguestdrivers/vboxguestdrivers_5.2.8.bb
deleted file mode 100644
index e00db4d..0000000
--- a/meta-openembedded/meta-oe/recipes-support/vboxguestdrivers/vboxguestdrivers_5.2.8.bb
+++ /dev/null
@@ -1,78 +0,0 @@
-SUMMARY = "VirtualBox Linux Guest Drivers"
-SECTION = "core"
-LICENSE = "GPL-2.0"
-LIC_FILES_CHKSUM = "file://${WORKDIR}/${VBOX_NAME}/COPYING;md5=e197d5641bb35b29d46ca8c4bf7f2660"
-
-DEPENDS = "virtual/kernel"
-
-inherit module kernel-module-split
-
-COMPATIBLE_MACHINE = "(qemux86|qemux86-64)"
-
-VBOX_NAME = "VirtualBox-${PV}"
-
-SRC_URI = "http://download.virtualbox.org/virtualbox/${PV}/${VBOX_NAME}.tar.bz2 \
-    file://Makefile.utils \
-"
-
-SRC_URI[md5sum] = "e731ea9c5c31096ec4c2a3bfba26665c"
-SRC_URI[sha256sum] = "ee2759d47b0b4ac81b8b671c9485c87fb2db12c097b3e7e69b94c1291a8084e8"
-
-S = "${WORKDIR}/vbox_module"
-
-export BUILD_TARGET_ARCH="${ARCH}"
-export BUILD_TARGET_ARCH_x86-64="amd64"
-
-EXTRA_OEMAKE += "KERN_DIR='${WORKDIR}/${KERNEL_VERSION}/build'"
-
-addtask export_sources before do_patch after do_unpack
-
-do_export_sources() {
-    mkdir -p "${S}"
-    ${WORKDIR}/${VBOX_NAME}/src/VBox/Additions/linux/export_modules.sh ${T}/vbox_modules.tar.gz
-    tar -C "${S}" -xzf ${T}/vbox_modules.tar.gz
-
-    # add a mount utility to use shared folder from VBox Addition Source Code
-    mkdir -p "${S}/utils"
-    install ${WORKDIR}/${VBOX_NAME}/src/VBox/Additions/linux/sharedfolders/mount.vboxsf.c ${S}/utils
-    install ${WORKDIR}/${VBOX_NAME}/src/VBox/Additions/linux/sharedfolders/vbsfmount.c ${S}/utils
-    install ${S}/../Makefile.utils ${S}/utils/Makefile
-
-}
-
-do_configure_prepend() {
-    # vboxguestdrivers/5.2.6-r0/vbox_module/vboxguest/Makefile.include.header:99: *** The variable KERN_DIR must be a kernel build folder and end with /build without a trailing slash, or KERN_VER must be set.  Stop.
-    # vboxguestdrivers/5.2.6-r0/vbox_module/vboxguest/Makefile.include.header:108: *** The kernel build folder path must end in <version>/build, or the variable KERN_VER must be set.  Stop.
-    mkdir -p ${WORKDIR}/${KERNEL_VERSION}
-    ln -snf ${STAGING_KERNEL_DIR} ${WORKDIR}/${KERNEL_VERSION}/build
-}
-
-# compile and install mount utility
-do_compile_append() {
-    oe_runmake 'LD=${CC}' 'LDFLAGS=${LDFLAGS}' -C ${S}/utils
-    if ! [ -e vboxguest.ko -a -e vboxsf.ko -a -e vboxvideo.ko ] ; then
-        echo "ERROR: One of vbox*.ko modules wasn't built"
-        exit 1
-    fi
-}
-
-module_do_install() {
-    MODULE_DIR=${D}${nonarch_base_libdir}/modules/${KERNEL_VERSION}/kernel/misc
-    install -d $MODULE_DIR
-    install -m 644 vboxguest.ko $MODULE_DIR
-    install -m 644 vboxsf.ko $MODULE_DIR
-    install -m 644 vboxvideo.ko $MODULE_DIR
-}
-
-do_install_append() {
-    install -d ${D}${base_sbindir}
-    install -m 755 ${S}/utils/mount.vboxsf ${D}${base_sbindir}
-}
-
-PACKAGES += "kernel-module-vboxguest kernel-module-vboxsf kernel-module-vboxvideo"
-RRECOMMENDS_${PN} += "kernel-module-vboxguest kernel-module-vboxsf kernel-module-vboxvideo"
-
-FILES_${PN} = "${base_sbindir}"
-
-# autoload if installed
-KERNEL_MODULE_AUTOLOAD += "vboxguest vboxsf vboxvideo"
diff --git a/meta-openembedded/meta-oe/recipes-support/vim/files/CVE-2017-17087.patch b/meta-openembedded/meta-oe/recipes-support/vim/files/CVE-2017-17087.patch
deleted file mode 100644
index 937b9ba..0000000
--- a/meta-openembedded/meta-oe/recipes-support/vim/files/CVE-2017-17087.patch
+++ /dev/null
@@ -1,70 +0,0 @@
-From 9c11f80339372b7aa2f43153d574f2b5abb79708 Mon Sep 17 00:00:00 2001
-From: Li Zhou <li.zhou@windriver.com>
-Date: Sun, 17 Dec 2017 23:09:35 -0800
-Subject: [PATCH] vim: patch 8.0.1263: others can read the swap file if a user
- is careless
-
-Problem:    Others can read the swap file if a user is careless with his
-            primary group.
-Solution:   If the group permission allows for reading but the world
-            permissions doesn't, make sure the group is right.
-
-Upstream-Status: Backport
-CVE: CVE-2017-17087
-Signed-off-by: Li Zhou <li.zhou@windriver.com>
----
- src/fileio.c  | 24 +++++++++++++++++++++++-
- src/version.c |  2 ++
- 2 files changed, 25 insertions(+), 1 deletion(-)
-
-diff --git a/src/fileio.c b/src/fileio.c
-index f54fb8465..2c7740af9 100644
---- a/src/fileio.c
-+++ b/src/fileio.c
-@@ -716,7 +716,29 @@ readfile(
- 	/* Set swap file protection bits after creating it. */
- 	if (swap_mode > 0 && curbuf->b_ml.ml_mfp != NULL
- 			  && curbuf->b_ml.ml_mfp->mf_fname != NULL)
--	    (void)mch_setperm(curbuf->b_ml.ml_mfp->mf_fname, (long)swap_mode);
-+	{
-+	    char_u *swap_fname = curbuf->b_ml.ml_mfp->mf_fname;
-+
-+	    /*
-+	     * If the group-read bit is set but not the world-read bit, then
-+	     * the group must be equal to the group of the original file.  If
-+	     * we can't make that happen then reset the group-read bit.  This
-+	     * avoids making the swap file readable to more users when the
-+	     * primary group of the user is too permissive.
-+	     */
-+	    if ((swap_mode & 044) == 040)
-+	    {
-+		stat_T	swap_st;
-+
-+		if (mch_stat((char *)swap_fname, &swap_st) >= 0
-+			&& st.st_gid != swap_st.st_gid
-+			&& fchown(curbuf->b_ml.ml_mfp->mf_fd, -1, st.st_gid)
-+									 == -1)
-+		    swap_mode &= 0600;
-+	    }
-+
-+	    (void)mch_setperm(swap_fname, (long)swap_mode);
-+	}
- #endif
-     }
- 
-diff --git a/src/version.c b/src/version.c
-index a5cb078f0..5c0df475f 100644
---- a/src/version.c
-+++ b/src/version.c
-@@ -770,6 +770,8 @@ static char *(features[]) =
- static int included_patches[] =
- {   /* Add new patch number below this line */
- /**/
-+    1263,
-+/**/
-     983,
- /**/
-     982,
--- 
-2.11.0
-
diff --git a/meta-openembedded/meta-oe/recipes-support/vim/files/disable_acl_header_check.patch b/meta-openembedded/meta-oe/recipes-support/vim/files/disable_acl_header_check.patch
index 65e5f58..4720003 100644
--- a/meta-openembedded/meta-oe/recipes-support/vim/files/disable_acl_header_check.patch
+++ b/meta-openembedded/meta-oe/recipes-support/vim/files/disable_acl_header_check.patch
@@ -1,14 +1,23 @@
-Upstream-Status: pending
+From 5ed25c076a1fb1889a3c50dddf29f21850b59a13 Mon Sep 17 00:00:00 2001
+From: Wenzong Fan <wenzong.fan@windriver.com> 
+Date: Tue, 26 Jun 2018 17:29:09 +0800
+Subject: [PATCH] disable acl header check
 
 Don't check 'sys/acl.h' if acl support disabled for vim/vim-tiny.
 
+Upstream-Status: pending
+
 Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
-================================================
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ src/configure.ac | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
 diff --git a/src/configure.ac b/src/configure.ac
-index fb965e5..d734064 100644
+index 107c170..0ee86ad 100644
 --- a/src/configure.ac
 +++ b/src/configure.ac
-@@ -2511,7 +2511,7 @@ AC_CHECK_HEADERS(stdarg.h stdint.h stdlib.h string.h \
+@@ -3220,7 +3220,7 @@ AC_CHECK_HEADERS(stdint.h stdlib.h string.h \
  	sys/systeminfo.h locale.h sys/stream.h termios.h \
  	libc.h sys/statfs.h poll.h sys/poll.h pwd.h \
  	utime.h sys/param.h libintl.h libgen.h \
@@ -17,11 +26,14 @@
  	sys/access.h sys/sysinfo.h wchar.h wctype.h)
  
  dnl sys/ptem.h depends on sys/stream.h on Solaris
-@@ -3112,6 +3112,7 @@ AC_ARG_ENABLE(acl,
+@@ -3848,6 +3848,7 @@ AC_ARG_ENABLE(acl,
  	, [enable_acl="yes"])
  if test "$enable_acl" = "yes"; then
- AC_MSG_RESULT(no)
-+AC_CHECK_HEADERS(sys/acl.h)
- AC_CHECK_LIB(posix1e, acl_get_file, [LIBS="$LIBS -lposix1e"],
+   AC_MSG_RESULT(no)
++  AC_CHECK_HEADERS(sys/acl.h)
+   AC_CHECK_LIB(posix1e, acl_get_file, [LIBS="$LIBS -lposix1e"],
  	AC_CHECK_LIB(acl, acl_get_file, [LIBS="$LIBS -lacl"
  		  AC_CHECK_LIB(attr, fgetxattr, LIBS="$LIBS -lattr",,)],,),)
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-oe/recipes-support/vim/files/vim-add-knob-whether-elf.h-are-checked.patch b/meta-openembedded/meta-oe/recipes-support/vim/files/vim-add-knob-whether-elf.h-are-checked.patch
index 6c620f9..37914d4 100644
--- a/meta-openembedded/meta-oe/recipes-support/vim/files/vim-add-knob-whether-elf.h-are-checked.patch
+++ b/meta-openembedded/meta-oe/recipes-support/vim/files/vim-add-knob-whether-elf.h-are-checked.patch
@@ -1,20 +1,24 @@
-vim: add knob whether elf.h are checked
+From 38de4bccdb8a861ffdd447f12fdab19d6d852c02 Mon Sep 17 00:00:00 2001
+From: Chong Lu <Chong.Lu@windriver.com>
+Date: Tue, 26 Jun 2018 17:34:15 +0800
+Subject: [PATCH] vim: add knob whether elf.h are checked
 
 Previously, it still was checked when there was no elf library in sysroots directory.
 Add knob to decide whether elf.h are checked or not.
 
-Upstream-status: Pending
+Upstream-Status: Pending
 
 Signed-off-by: Chong Lu <Chong.Lu@windriver.com>
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
 ---
- src/configure.ac |    7 +++++++
+ src/configure.ac | 7 +++++++
  1 file changed, 7 insertions(+)
 
 diff --git a/src/configure.ac b/src/configure.ac
-index d734064..f504fa6 100644
+index 0ee86ad..64736f0 100644
 --- a/src/configure.ac
 +++ b/src/configure.ac
-@@ -2483,11 +2483,18 @@ AC_TRY_COMPILE([#include <stdio.h>], [int x __attribute__((unused));],
+@@ -3192,11 +3192,18 @@ AC_TRY_COMPILE([#include <stdio.h>], [int x __attribute__((unused));],
  	AC_MSG_RESULT(no))
  
  dnl Checks for header files.
@@ -34,5 +38,5 @@
  AC_HEADER_DIRENT
  
 -- 
-1.7.9.5
+2.7.4
 
diff --git a/meta-openembedded/meta-oe/recipes-support/vim/vim-tiny_8.0.0983.bb b/meta-openembedded/meta-oe/recipes-support/vim/vim-tiny_8.0.0983.bb
deleted file mode 100644
index bb8f2b7..0000000
--- a/meta-openembedded/meta-oe/recipes-support/vim/vim-tiny_8.0.0983.bb
+++ /dev/null
@@ -1,13 +0,0 @@
-require vim_${PV}.bb
-
-SUMMARY += " (with tiny features)"
-
-PACKAGECONFIG += "tiny"
-
-do_install() {
-    install -d ${D}/${bindir}
-    install -m 0755 ${S}/vim ${D}/${bindir}/vim.tiny
-}
-
-ALTERNATIVE_PRIORITY = "90"
-ALTERNATIVE_TARGET = "${bindir}/vim.tiny"
diff --git a/meta-openembedded/meta-oe/recipes-support/vim/vim-tiny_8.1.0347.bb b/meta-openembedded/meta-oe/recipes-support/vim/vim-tiny_8.1.0347.bb
new file mode 100644
index 0000000..8b1fb7b
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/vim/vim-tiny_8.1.0347.bb
@@ -0,0 +1,15 @@
+require vim_${PV}.bb
+
+SUMMARY += " (with tiny features)"
+
+PROVIDES_remove = "xxd"
+ALTERNATIVE_${PN}_remove = "xxd"
+
+PACKAGECONFIG += "tiny"
+
+do_install() {
+    install -D -m 0755 ${S}/vim ${D}/${bindir}/vim.tiny
+}
+
+ALTERNATIVE_PRIORITY = "90"
+ALTERNATIVE_TARGET = "${bindir}/vim.tiny"
diff --git a/meta-openembedded/meta-oe/recipes-support/vim/vim_8.0.0983.bb b/meta-openembedded/meta-oe/recipes-support/vim/vim_8.0.0983.bb
deleted file mode 100644
index 44c868c..0000000
--- a/meta-openembedded/meta-oe/recipes-support/vim/vim_8.0.0983.bb
+++ /dev/null
@@ -1,114 +0,0 @@
-SUMMARY = "Vi IMproved - enhanced vi editor"
-SECTION = "console/utils"
-DEPENDS = "ncurses gettext-native"
-# vimdiff doesn't like busybox diff
-RSUGGESTS_${PN} = "diffutils"
-LICENSE = "vim"
-LIC_FILES_CHKSUM = "file://../runtime/doc/uganda.txt;md5=eea32ac1424bba14096736a494ae9045"
-
-SRC_URI = "git://github.com/vim/vim.git \
-           file://disable_acl_header_check.patch;patchdir=.. \
-           file://vim-add-knob-whether-elf.h-are-checked.patch;patchdir=.. \
-           file://CVE-2017-17087.patch;patchdir=.. \
-"
-SRCREV = "3f9a1ff141412e9e85f7dff47d02946cb9be9228"
-
-S = "${WORKDIR}/git/src"
-
-VIMDIR = "vim${@d.getVar('PV').split('.')[0]}${@d.getVar('PV').split('.')[1]}"
-
-inherit autotools-brokensep update-alternatives
-
-CLEANBROKEN = "1"
-
-# vim configure.in contains functions which got 'dropped' by autotools.bbclass
-do_configure () {
-    rm -f auto/*
-    touch auto/config.mk
-    aclocal
-    autoconf
-    oe_runconf
-    touch auto/configure
-    touch auto/config.mk auto/config.h
-}
-
-#Available PACKAGECONFIG options are gtkgui, acl, x11, tiny
-PACKAGECONFIG ??= ""
-PACKAGECONFIG += "${@bb.utils.filter('DISTRO_FEATURES', 'acl selinux', d)}"
-
-PACKAGECONFIG[gtkgui] = "--enable-gtk2-test --enable-gui=gtk2,--enable-gui=no,gtk+,"
-PACKAGECONFIG[acl] = "--enable-acl,--disable-acl,acl,"
-PACKAGECONFIG[x11] = "--with-x,--without-x,xt,"
-PACKAGECONFIG[tiny] = "--with-features=tiny,--with-features=big,,"
-PACKAGECONFIG[selinux] = "--enable-selinux,--disable-selinux,libselinux,"
-PACKAGECONFIG[elfutils] = "--enable-elf-check,,elfutils,"
-
-EXTRA_OECONF = " \
-    --disable-gpm \
-    --disable-gtktest \
-    --disable-xim \
-    --disable-netbeans \
-    --with-tlib=ncurses \
-    ac_cv_small_wchar_t=no \
-    vim_cv_getcwd_broken=no \
-    vim_cv_memmove_handles_overlap=yes \
-    vim_cv_stat_ignores_slash=no \
-    vim_cv_terminfo=yes \
-    vim_cv_tgent=non-zero \
-    vim_cv_toupper_broken=no \
-    vim_cv_tty_group=world \
-    STRIP=/bin/true \
-"
-
-do_install() {
-    autotools_do_install
-
-    # Work around file-rdeps picking up csh, awk, perl or python as a dep
-    chmod -x ${D}${datadir}/${BPN}/${VIMDIR}/tools/vim132
-    chmod -x ${D}${datadir}/${BPN}/${VIMDIR}/tools/mve.awk
-    chmod -x ${D}${datadir}/${BPN}/${VIMDIR}/tools/*.pl
-    chmod -x ${D}${datadir}/${BPN}/${VIMDIR}/tools/*.py
-
-    # Install example vimrc from runtime files
-    install -m 0644 ../runtime/vimrc_example.vim ${D}/${datadir}/${BPN}/vimrc
-
-    # we use --with-features=big as default
-    mv ${D}${bindir}/${BPN} ${D}${bindir}/${BPN}.${BPN}
-}
-
-PARALLEL_MAKEINST = ""
-
-PACKAGES =+ "${PN}-common ${PN}-syntax ${PN}-help ${PN}-tutor ${PN}-vimrc ${PN}-tools"
-FILES_${PN}-syntax = "${datadir}/${BPN}/${VIMDIR}/syntax"
-FILES_${PN}-help = "${datadir}/${BPN}/${VIMDIR}/doc"
-FILES_${PN}-tutor = "${datadir}/${BPN}/${VIMDIR}/tutor ${bindir}/${BPN}tutor"
-FILES_${PN}-vimrc = "${datadir}/${BPN}/vimrc"
-FILES_${PN}-data = "${datadir}/${BPN}"
-FILES_${PN}-tools = "${datadir}/${BPN}/${VIMDIR}/tools"
-FILES_${PN}-common = " \
-    ${datadir}/${BPN}/${VIMDIR}/*.vim \
-    ${datadir}/${BPN}/${VIMDIR}/autoload \
-    ${datadir}/${BPN}/${VIMDIR}/colors \
-    ${datadir}/${BPN}/${VIMDIR}/compiler \
-    ${datadir}/${BPN}/${VIMDIR}/ftplugin \
-    ${datadir}/${BPN}/${VIMDIR}/indent \
-    ${datadir}/${BPN}/${VIMDIR}/keymap \
-    ${datadir}/${BPN}/${VIMDIR}/lang \
-    ${datadir}/${BPN}/${VIMDIR}/macros \
-    ${datadir}/${BPN}/${VIMDIR}/plugin \
-    ${datadir}/${BPN}/${VIMDIR}/print \
-    ${datadir}/${BPN}/${VIMDIR}/spell \
-    ${datadir}/icons \
-"
-
-RDEPENDS_${BPN} = "ncurses-terminfo-base"
-# Recommend that runtime data is installed along with vim
-RRECOMMENDS_${BPN} = "${PN}-syntax ${PN}-help ${PN}-tutor ${PN}-vimrc ${PN}-common"
-
-ALTERNATIVE_${PN} = "vi vim"
-ALTERNATIVE_TARGET = "${bindir}/${BPN}.${BPN}"
-ALTERNATIVE_LINK_NAME[vi] = "${base_bindir}/vi"
-ALTERNATIVE_LINK_NAME[vim] = "${bindir}/vim"
-ALTERNATIVE_PRIORITY = "100"
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-support/vim/vim_8.1.0347.bb b/meta-openembedded/meta-oe/recipes-support/vim/vim_8.1.0347.bb
new file mode 100644
index 0000000..46d229e
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/vim/vim_8.1.0347.bb
@@ -0,0 +1,117 @@
+SUMMARY = "Vi IMproved - enhanced vi editor"
+SECTION = "console/utils"
+
+PROVIDES = "xxd"
+DEPENDS = "ncurses gettext-native"
+# vimdiff doesn't like busybox diff
+RSUGGESTS_${PN} = "diffutils"
+LICENSE = "vim"
+LIC_FILES_CHKSUM = "file://../runtime/doc/uganda.txt;endline=287;md5=f1f82b42360005c70b8c19b0ef493f72"
+
+SRC_URI = "git://github.com/vim/vim.git \
+           file://disable_acl_header_check.patch;patchdir=.. \
+           file://vim-add-knob-whether-elf.h-are-checked.patch;patchdir=.. \
+"
+SRCREV = "f1c118be93184e8e57e3e80b1b3383f464ed649e"
+
+S = "${WORKDIR}/git/src"
+
+VIMDIR = "vim${@d.getVar('PV').split('.')[0]}${@d.getVar('PV').split('.')[1]}"
+
+inherit autotools-brokensep update-alternatives
+
+CLEANBROKEN = "1"
+
+# vim configure.in contains functions which got 'dropped' by autotools.bbclass
+do_configure () {
+    rm -f auto/*
+    touch auto/config.mk
+    aclocal
+    autoconf
+    oe_runconf
+    touch auto/configure
+    touch auto/config.mk auto/config.h
+}
+
+#Available PACKAGECONFIG options are gtkgui, acl, x11, tiny
+PACKAGECONFIG ??= ""
+PACKAGECONFIG += "${@bb.utils.filter('DISTRO_FEATURES', 'acl selinux', d)}"
+
+PACKAGECONFIG[gtkgui] = "--enable-gtk2-test --enable-gui=gtk2,--enable-gui=no,gtk+,"
+PACKAGECONFIG[acl] = "--enable-acl,--disable-acl,acl,"
+PACKAGECONFIG[x11] = "--with-x,--without-x,xt,"
+PACKAGECONFIG[tiny] = "--with-features=tiny,--with-features=big,,"
+PACKAGECONFIG[selinux] = "--enable-selinux,--disable-selinux,libselinux,"
+PACKAGECONFIG[elfutils] = "--enable-elf-check,,elfutils,"
+
+EXTRA_OECONF = " \
+    --disable-gpm \
+    --disable-gtktest \
+    --disable-xim \
+    --disable-netbeans \
+    --with-tlib=ncurses \
+    ac_cv_small_wchar_t=no \
+    vim_cv_getcwd_broken=no \
+    vim_cv_memmove_handles_overlap=yes \
+    vim_cv_stat_ignores_slash=no \
+    vim_cv_terminfo=yes \
+    vim_cv_tgetent=non-zero \
+    vim_cv_toupper_broken=no \
+    vim_cv_tty_group=world \
+    STRIP=/bin/true \
+"
+
+do_install() {
+    autotools_do_install
+
+    # Work around file-rdeps picking up csh, awk, perl or python as a dep
+    chmod -x ${D}${datadir}/${BPN}/${VIMDIR}/tools/vim132
+    chmod -x ${D}${datadir}/${BPN}/${VIMDIR}/tools/mve.awk
+    chmod -x ${D}${datadir}/${BPN}/${VIMDIR}/tools/*.pl
+    chmod -x ${D}${datadir}/${BPN}/${VIMDIR}/tools/*.py
+
+    # Install example vimrc from runtime files
+    install -m 0644 ../runtime/vimrc_example.vim ${D}/${datadir}/${BPN}/vimrc
+
+    # we use --with-features=big as default
+    mv ${D}${bindir}/${BPN} ${D}${bindir}/${BPN}.${BPN}
+}
+
+PARALLEL_MAKEINST = ""
+
+PACKAGES =+ "${PN}-common ${PN}-syntax ${PN}-help ${PN}-tutor ${PN}-vimrc ${PN}-tools"
+FILES_${PN}-syntax = "${datadir}/${BPN}/${VIMDIR}/syntax"
+FILES_${PN}-help = "${datadir}/${BPN}/${VIMDIR}/doc"
+FILES_${PN}-tutor = "${datadir}/${BPN}/${VIMDIR}/tutor ${bindir}/${BPN}tutor"
+FILES_${PN}-vimrc = "${datadir}/${BPN}/vimrc"
+FILES_${PN}-data = "${datadir}/${BPN}"
+FILES_${PN}-tools = "${datadir}/${BPN}/${VIMDIR}/tools"
+FILES_${PN}-common = " \
+    ${datadir}/${BPN}/${VIMDIR}/*.vim \
+    ${datadir}/${BPN}/${VIMDIR}/autoload \
+    ${datadir}/${BPN}/${VIMDIR}/colors \
+    ${datadir}/${BPN}/${VIMDIR}/compiler \
+    ${datadir}/${BPN}/${VIMDIR}/ftplugin \
+    ${datadir}/${BPN}/${VIMDIR}/indent \
+    ${datadir}/${BPN}/${VIMDIR}/keymap \
+    ${datadir}/${BPN}/${VIMDIR}/lang \
+    ${datadir}/${BPN}/${VIMDIR}/macros \
+    ${datadir}/${BPN}/${VIMDIR}/plugin \
+    ${datadir}/${BPN}/${VIMDIR}/print \
+    ${datadir}/${BPN}/${VIMDIR}/spell \
+    ${datadir}/icons \
+"
+
+RDEPENDS_${BPN} = "ncurses-terminfo-base"
+# Recommend that runtime data is installed along with vim
+RRECOMMENDS_${BPN} = "${PN}-syntax ${PN}-help ${PN}-tutor ${PN}-vimrc ${PN}-common"
+
+ALTERNATIVE_${PN} = "vi vim xxd"
+ALTERNATIVE_PRIORITY = "100"
+ALTERNATIVE_TARGET = "${bindir}/${BPN}.${BPN}"
+ALTERNATIVE_LINK_NAME[vi] = "${base_bindir}/vi"
+ALTERNATIVE_LINK_NAME[vim] = "${bindir}/vim"
+ALTERNATIVE_TARGET[xxd] = "${bindir}/xxd"
+ALTERNATIVE_LINK_NAME[xxd] = "${bindir}/xxd"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.7.0/0001-Fix-issue-599.patch b/meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.8.1/0001-Fix-issue-599.patch
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.7.0/0001-Fix-issue-599.patch
rename to meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.8.1/0001-Fix-issue-599.patch
diff --git a/meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.7.0/4cab5e5c0c5f19fcee7d37b4a38b156d63a150d4.patch b/meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.8.1/4cab5e5c0c5f19fcee7d37b4a38b156d63a150d4.patch
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.7.0/4cab5e5c0c5f19fcee7d37b4a38b156d63a150d4.patch
rename to meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.8.1/4cab5e5c0c5f19fcee7d37b4a38b156d63a150d4.patch
diff --git a/meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.7.0/9ddb300d874a30db35e3ad58f188944bef0bf31b.patch b/meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.8.1/9ddb300d874a30db35e3ad58f188944bef0bf31b.patch
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.7.0/9ddb300d874a30db35e3ad58f188944bef0bf31b.patch
rename to meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.8.1/9ddb300d874a30db35e3ad58f188944bef0bf31b.patch
diff --git a/meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.7.0/disable-tests.patch b/meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.8.1/disable-tests.patch
similarity index 100%
rename from meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.7.0/disable-tests.patch
rename to meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp-0.8.1/disable-tests.patch
diff --git a/meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp_0.7.0.bb b/meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp_0.7.0.bb
deleted file mode 100644
index 65fc974..0000000
--- a/meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp_0.7.0.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-SUMMARY = "C++/Boost Asio based websocket client/server library."
-SECTION = "libs/network"
-HOMEPAGE = "https://github.com/zaphoyd/websocketpp"
-LICENSE = "BSD-3-Clause"
-LIC_FILES_CHKSUM = "file://${S}/COPYING;md5=4d168d763c111f4ffc62249870e4e0ea"
-DEPENDS = "openssl boost zlib"
-
-SRC_URI = "git://github.com/zaphoyd/websocketpp.git;protocol=https;branch=master"
-
-# tag 0.7.0
-SRCREV= "378437aecdcb1dfe62096ffd5d944bf1f640ccc3"
-
-SRC_URI += "file://0001-Fix-issue-599.patch \
-            file://9ddb300d874a30db35e3ad58f188944bef0bf31b.patch \
-            file://4cab5e5c0c5f19fcee7d37b4a38b156d63a150d4.patch \
-            file://disable-tests.patch \
- "
-
-S = "${WORKDIR}/git"
-
-inherit cmake
diff --git a/meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp_0.8.1.bb b/meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp_0.8.1.bb
new file mode 100644
index 0000000..75a5f88
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/websocketpp/websocketpp_0.8.1.bb
@@ -0,0 +1,15 @@
+SUMMARY = "C++/Boost Asio based websocket client/server library."
+SECTION = "libs/network"
+HOMEPAGE = "https://github.com/zaphoyd/websocketpp"
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://${S}/COPYING;md5=4d168d763c111f4ffc62249870e4e0ea"
+DEPENDS = "openssl boost zlib"
+
+SRC_URI = "git://github.com/zaphoyd/websocketpp.git;protocol=https;branch=master"
+
+# tag 0.8.1
+SRCREV= "c6d7e295bf5a0ab9b5f896720cc1a0e0fdc397a7"
+
+S = "${WORKDIR}/git"
+
+inherit cmake
diff --git a/meta-openembedded/meta-oe/recipes-test/catch2/catch2/0001-Fix-convert-from-char-on-ARM-build.patch b/meta-openembedded/meta-oe/recipes-test/catch2/catch2/0001-Fix-convert-from-char-on-ARM-build.patch
new file mode 100644
index 0000000..3073775
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-test/catch2/catch2/0001-Fix-convert-from-char-on-ARM-build.patch
@@ -0,0 +1,46 @@
+From 5729874fa5059c39aa97cfa08fddf107b7a65c9e Mon Sep 17 00:00:00 2001
+From: Miguel Gaio <mgaio35@gmail.com>
+Date: Wed, 3 Oct 2018 10:22:16 +0200
+Subject: [PATCH] Fix convert from char on ARM build
+
+Some platforms set the signedness of char to unsigned (eg. ARM).
+Convert from char should not assume the signedness of char.
+
+Fix build issue with -Werror,-Wtautological-unsigned-zero-compare flags.
+
+Signed-off-by: Miguel Gaio <mgaio35@gmail.com>
+
+Upstream-Status: Accepted [Commit f1faaa9c107113692301ad8bb56084460ef1a2ff]
+
+Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
+---
+ include/internal/catch_tostring.cpp | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/include/internal/catch_tostring.cpp b/include/internal/catch_tostring.cpp
+index 4e0c027d..8cbabbf2 100644
+--- a/include/internal/catch_tostring.cpp
++++ b/include/internal/catch_tostring.cpp
+@@ -205,7 +205,7 @@ std::string StringMaker<bool>::convert(bool b) {
+     return b ? "true" : "false";
+ }
+ 
+-std::string StringMaker<char>::convert(char value) {
++std::string StringMaker<signed char>::convert(signed char value) {
+     if (value == '\r') {
+         return "'\\r'";
+     } else if (value == '\f') {
+@@ -222,8 +222,8 @@ std::string StringMaker<char>::convert(char value) {
+         return chstr;
+     }
+ }
+-std::string StringMaker<signed char>::convert(signed char c) {
+-    return ::Catch::Detail::stringify(static_cast<char>(c));
++std::string StringMaker<char>::convert(char c) {
++    return ::Catch::Detail::stringify(static_cast<signed char>(c));
+ }
+ std::string StringMaker<unsigned char>::convert(unsigned char c) {
+     return ::Catch::Detail::stringify(static_cast<char>(c));
+-- 
+2.19.1
+
diff --git a/meta-openembedded/meta-oe/recipes-test/catch2/catch2_2.4.1.bb b/meta-openembedded/meta-oe/recipes-test/catch2/catch2_2.4.1.bb
new file mode 100644
index 0000000..0183c2e
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-test/catch2/catch2_2.4.1.bb
@@ -0,0 +1,24 @@
+DESCRIPTION = "A modern, C++-native, header-only, test framework for unit-tests, \
+TDD and BDD - using C++11, C++14, C++17 and later."
+AUTHOR = "Phil Nash, Martin Horenovsky and others"
+HOMEPAGE = "https://github.com/catchorg/Catch2"
+LICENSE = "BSL-1.0"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=e4224ccaecb14d942c71d31bef20d78c"
+
+SRC_URI = "git://github.com/catchorg/Catch2.git \
+           file://0001-Fix-convert-from-char-on-ARM-build.patch"
+SRCREV = "9e1bdca4667295fcb16265eae00efa8423f07007"
+
+S = "${WORKDIR}/git"
+
+inherit cmake python3native
+
+# Header-only library
+RDEPENDS_${PN}-dev = ""
+RRECOMMENDS_${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})"
+
+do_install_append() {
+    rm ${D}/${datadir}/Catch2/lldbinit
+    rm ${D}/${datadir}/Catch2/gdbinit
+    rmdir ${D}/${datadir}/Catch2/
+}
diff --git a/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Add-correct-printf-qualifier-for-off_t.patch b/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Add-correct-printf-qualifier-for-off_t.patch
index 192e05f..c2d679a 100644
--- a/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Add-correct-printf-qualifier-for-off_t.patch
+++ b/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Add-correct-printf-qualifier-for-off_t.patch
@@ -1,18 +1,19 @@
-From 232daf5fca6fb52cced5e810f2601fe1a71b96d8 Mon Sep 17 00:00:00 2001
+From 613e5cfe7751068062cc92f83870e436669fc0a8 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Thu, 8 Jun 2017 16:49:50 -0700
-Subject: [PATCH 1/3] Add correct printf qualifier for off_t
+Subject: [PATCH] Add correct printf qualifier for off_t
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/bios/ebda_region/ebda_region.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
 
-Index: git/src/bios/ebda_region/ebda_region.c
-===================================================================
---- git.orig/src/bios/ebda_region/ebda_region.c
-+++ git/src/bios/ebda_region/ebda_region.c
-@@ -83,9 +83,9 @@ static int ebda_test1(fwts_framework *fw
+---
+ src/bios/ebda_region/ebda_region.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/src/bios/ebda_region/ebda_region.c b/src/bios/ebda_region/ebda_region.c
+index 16c39357..ad6d635c 100644
+--- a/src/bios/ebda_region/ebda_region.c
++++ b/src/bios/ebda_region/ebda_region.c
+@@ -83,9 +83,9 @@ static int ebda_test1(fwts_framework *fw)
  	if ((entry != NULL) &&
  	    (entry->type == FWTS_MEMORY_MAP_RESERVED ||
  	     entry->type == FWTS_MEMORY_MAP_ACPI)) {
@@ -24,7 +25,7 @@
  			(entry->end_address - entry->start_address) / 1024,
  			memory_map_name,
  			entry->start_address,
-@@ -93,8 +93,8 @@ static int ebda_test1(fwts_framework *fw
+@@ -93,8 +93,8 @@ static int ebda_test1(fwts_framework *fw)
  	} else
  		fwts_failed(fw, LOG_LEVEL_MEDIUM,
  			"EBDAMappedNotReserved",
diff --git a/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Include-poll.h-instead-of-deprecated-sys-poll.h.patch b/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Include-poll.h-instead-of-deprecated-sys-poll.h.patch
index 8ad0789..4baefe4 100644
--- a/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Include-poll.h-instead-of-deprecated-sys-poll.h.patch
+++ b/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Include-poll.h-instead-of-deprecated-sys-poll.h.patch
@@ -1,18 +1,19 @@
-From 100a107a53d5dc9b0554252ac5dbf2c9330615e9 Mon Sep 17 00:00:00 2001
+From ed988c27efde5355c3ba9d0de8a14a4a40f798cc Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Tue, 6 Jun 2017 07:25:09 -0700
-Subject: [PATCH 1/3] Include poll.h instead of deprecated sys/poll.h
+Subject: [PATCH] Include poll.h instead of deprecated sys/poll.h
 
 Upstream-Status: Pending
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
 ---
  src/lib/src/fwts_ipmi.c   | 3 ++-
  src/lib/src/fwts_pipeio.c | 2 +-
  2 files changed, 3 insertions(+), 2 deletions(-)
 
 diff --git a/src/lib/src/fwts_ipmi.c b/src/lib/src/fwts_ipmi.c
-index cbb27611..70d11cfa 100644
+index a4c8a511..e298969e 100644
 --- a/src/lib/src/fwts_ipmi.c
 +++ b/src/lib/src/fwts_ipmi.c
 @@ -18,10 +18,11 @@
@@ -29,7 +30,7 @@
  #include <linux/ipmi.h>
  
 diff --git a/src/lib/src/fwts_pipeio.c b/src/lib/src/fwts_pipeio.c
-index fd719640..bdc5b2ea 100644
+index 3b3cfaff..289564d1 100644
 --- a/src/lib/src/fwts_pipeio.c
 +++ b/src/lib/src/fwts_pipeio.c
 @@ -30,9 +30,9 @@
@@ -43,6 +44,3 @@
  #include <sys/types.h>
  #include <sys/wait.h>
  #include <errno.h>
--- 
-2.13.0
-
diff --git a/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Remove-Werror-from-build.patch b/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Remove-Werror-from-build.patch
new file mode 100644
index 0000000..611ccc8
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-Remove-Werror-from-build.patch
@@ -0,0 +1,52 @@
+From 475979cf5c1af978f4e8409666365ec75b3320ea Mon Sep 17 00:00:00 2001
+From: Benjamin Berg <bberg@redhat.com>
+Date: Mon, 21 Aug 2017 10:34:40 +0200
+Subject: [PATCH] Remove -Werror from build
+
+Upstream-Status: Pending
+
+---
+ src/Makefile.am           | 2 +-
+ src/lib/src/Makefile.am   | 2 +-
+ src/utilities/Makefile.am | 2 +-
+ 3 files changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/src/Makefile.am b/src/Makefile.am
+index 4daa9e8f..873f23eb 100644
+--- a/src/Makefile.am
++++ b/src/Makefile.am
+@@ -14,7 +14,7 @@ AM_CPPFLAGS = \
+ 	`pkg-config --silence-errors --cflags json` \
+ 	`pkg-config --silence-errors --cflags json-c` \
+ 	-pthread `pkg-config --cflags glib-2.0 gio-2.0` \
+-	-Wall -Werror -Wextra
++	-Wall -Wextra
+ 
+ bin_PROGRAMS = fwts
+ 
+diff --git a/src/lib/src/Makefile.am b/src/lib/src/Makefile.am
+index fa232451..082403a2 100644
+--- a/src/lib/src/Makefile.am
++++ b/src/lib/src/Makefile.am
+@@ -24,7 +24,7 @@ AM_CPPFLAGS = \
+ 	`pkg-config --silence-errors --cflags json-c`	\
+ 	`pkg-config --cflags glib-2.0 gio-2.0` 		\
+ 	-DDATAROOTDIR=\"$(datarootdir)\"		\
+-	-Wall -Werror -Wextra
++	-Wall -Wextra
+ 
+ pkglib_LTLIBRARIES = libfwts.la
+ 
+diff --git a/src/utilities/Makefile.am b/src/utilities/Makefile.am
+index aa37de55..4d5297cc 100644
+--- a/src/utilities/Makefile.am
++++ b/src/utilities/Makefile.am
+@@ -16,7 +16,7 @@
+ # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ #
+ 
+-AM_CPPFLAGS = -Wall -Werror -Wextra -DDATAROOTDIR=\"$(datarootdir)\" \
++AM_CPPFLAGS = -Wall -Wextra -DDATAROOTDIR=\"$(datarootdir)\" \
+ 	`pkg-config --silence-errors --cflags json` \
+ 	`pkg-config --silence-errors --cflags json-c`
+ 
diff --git a/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-ignore-constant-logical-operand-warning-with-clang.patch b/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-ignore-constant-logical-operand-warning-with-clang.patch
index a3cc1ff..ae3665b 100644
--- a/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-ignore-constant-logical-operand-warning-with-clang.patch
+++ b/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0001-ignore-constant-logical-operand-warning-with-clang.patch
@@ -1,9 +1,10 @@
-From 953cff93c85d3cfd5cbcac56e14443dc5f6e5fbd Mon Sep 17 00:00:00 2001
+From 5bd05ad8569880985ddf6d4c06ed927d388c297f Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Wed, 19 Oct 2016 01:57:16 +0000
 Subject: [PATCH] ignore constant-logical-operand warning with clang
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
 ---
  src/dmi/dmicheck/dmicheck.c            | 3 +++
  src/lib/src/fwts_acpi_tables.c         | 5 +++++
@@ -11,10 +12,10 @@
  3 files changed, 13 insertions(+)
 
 diff --git a/src/dmi/dmicheck/dmicheck.c b/src/dmi/dmicheck/dmicheck.c
-index ecd98223..7fca4a64 100644
+index 3cca9db9..60fb758f 100644
 --- a/src/dmi/dmicheck/dmicheck.c
 +++ b/src/dmi/dmicheck/dmicheck.c
-@@ -209,6 +209,8 @@ static const char *uuid_patterns[] = {
+@@ -211,6 +211,8 @@ static const char *uuid_patterns[] = {
  	"0A0A0A0A-0A0A-0A0A-0A0A-0A0A0A0A0A0A",
  	NULL,
  };
@@ -23,19 +24,19 @@
  
  static const fwts_chassis_type_map fwts_dmi_chassis_type[] = {
  	{ "Invalid",		FWTS_SMBIOS_CHASSIS_INVALID },
-@@ -245,6 +247,7 @@ static const fwts_chassis_type_map fwts_dmi_chassis_type[] = {
- 	{ "Convertible",	FWTS_SMBIOS_CHASSIS_CONVERTIBLE },
- 	{ "Detachable",		FWTS_SMBIOS_CHASSIS_DETACHABLE },
+@@ -251,6 +253,7 @@ static const fwts_chassis_type_map fwts_dmi_chassis_type[] = {
+ 	{ "Mini PC",		FWTS_SMBIOS_CHASSIS_MINI_PC },
+ 	{ "Stick PC",		FWTS_SMBIOS_CHASSIS_STICK_PC },
  };
 +#pragma clang diagnostic pop
  
  /* Remapping table from buggy version numbers to correct values */
  static const fwts_dmi_version dmi_versions[] = {
 diff --git a/src/lib/src/fwts_acpi_tables.c b/src/lib/src/fwts_acpi_tables.c
-index 30b4060e..d5339bf7 100644
+index c7ba59be..bdd224aa 100644
 --- a/src/lib/src/fwts_acpi_tables.c
 +++ b/src/lib/src/fwts_acpi_tables.c
-@@ -394,10 +394,14 @@ static int fwts_acpi_handle_fadt(
+@@ -393,10 +393,14 @@ static int fwts_acpi_handle_fadt(
  	/* Determine FACS addr and load it.
  	 * Will ignore the missing FACS in the hardware-reduced mode.
  	 */
@@ -50,7 +51,7 @@
  	if (result != FWTS_OK) {
  		if ((result == FWTS_NULL_POINTER) &&
  				fwts_acpi_is_reduced_hardware(fadt)) {
-@@ -416,6 +420,7 @@ static int fwts_acpi_handle_fadt(
+@@ -415,6 +419,7 @@ static int fwts_acpi_handle_fadt(
  		return FWTS_ERROR;
  	}
  	return FWTS_OK;
@@ -59,7 +60,7 @@
  
  /*
 diff --git a/src/uefi/uefirtauthvar/uefirtauthvar.c b/src/uefi/uefirtauthvar/uefirtauthvar.c
-index cdfd7aa3..001e8cc8 100644
+index c2031741..7a33d19d 100644
 --- a/src/uefi/uefirtauthvar/uefirtauthvar.c
 +++ b/src/uefi/uefirtauthvar/uefirtauthvar.c
 @@ -142,6 +142,9 @@ static int uefirtauthvar_deinit(fwts_framework *fw)
diff --git a/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0002-Add-C99-defined-format-for-printing-uint64_t.patch b/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0002-Add-C99-defined-format-for-printing-uint64_t.patch
deleted file mode 100644
index 35ce883..0000000
--- a/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0002-Add-C99-defined-format-for-printing-uint64_t.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-From 25f18b9ac37960dc12a3b648a5c866bd56ef2cbe Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 8 Jun 2017 16:50:23 -0700
-Subject: [PATCH 2/3] Add C99 defined format for printing uint64_t
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/opal/reserv_mem.c | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/src/opal/reserv_mem.c b/src/opal/reserv_mem.c
-index eeec2947..f0672e05 100644
---- a/src/opal/reserv_mem.c
-+++ b/src/opal/reserv_mem.c
-@@ -185,7 +185,7 @@ static int reserv_mem_limits_test(fwts_framework *fw)
- 		regions[j].start = (uint64_t)be64toh(ranges[2 * j]);
- 		regions[j].len = (uint64_t)be64toh(ranges[2 * j + 1]);
- 		fwts_log_info(fw, "Region name %80s"
--			" start: 0x%08lx, len: 0x%08lx\n",
-+			" start: 0x%08" PRIx64 ", len: 0x%08" PRIx64 "\n",
- 			regions[j].name, regions[j].start, regions[j].len);
- 	}
- 
-@@ -248,7 +248,7 @@ static int reserv_mem_limits_test(fwts_framework *fw)
- 				fwts_failed(fw, LOG_LEVEL_MEDIUM,
- 					"ImageSizeMismatch",
- 					"Mismatch in homer-image size, "
--					"expected: 0x%lx, actual: 0x%lx",
-+					"expected: 0x%" PRIx64 ", actual: 0x%" PRIx64 "",
- 					configstruct.homer, regions[j].len);
- 				ok = false;
- 			} else
-@@ -261,7 +261,7 @@ static int reserv_mem_limits_test(fwts_framework *fw)
- 				fwts_failed(fw, LOG_LEVEL_MEDIUM,
- 					"ImageSizeMismatch",
- 					"Mismatch in slw-image size, "
--					"expected: 0x%lx, actual: 0x%lx",
-+					"expected: 0x%" PRIx64 ", actual: 0x%" PRIx64 "",
- 					configstruct.slw, regions[j].len);
- 				ok = false;
- 			} else
-@@ -274,7 +274,7 @@ static int reserv_mem_limits_test(fwts_framework *fw)
- 				fwts_failed(fw, LOG_LEVEL_MEDIUM,
- 					"ImageSizeMismatch",
- 					"Mismatch in occ-common-area size, "
--					"expected: 0x%lx, actual: 0x%lx",
-+					"expected: 0x%" PRIx64", actual: 0x%" PRIx64"",
- 					configstruct.occ_common,
- 					regions[j].len);
- 				ok = false;
--- 
-2.13.1
-
diff --git a/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0002-Define-__SWORD_TYPE-if-not-defined-by-libc.patch b/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0002-Define-__SWORD_TYPE-if-not-defined-by-libc.patch
index 3b83ca5..b45e46a 100644
--- a/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0002-Define-__SWORD_TYPE-if-not-defined-by-libc.patch
+++ b/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0002-Define-__SWORD_TYPE-if-not-defined-by-libc.patch
@@ -1,7 +1,7 @@
-From 0e89127cd02ecd5ea4506b935cb2b59eb94107d2 Mon Sep 17 00:00:00 2001
+From 1112e51d240a206bdcf253878ef1f4963b92da8a Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Tue, 6 Jun 2017 07:37:20 -0700
-Subject: [PATCH 2/3] Define __SWORD_TYPE if not defined by libc
+Subject: [PATCH] Define __SWORD_TYPE if not defined by libc
 
 __SWORD_TYPE is internal to glibc, therefore
 check and define it if needed e.g. on musl
@@ -9,12 +9,13 @@
 Upstream-Status: Pending
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
 ---
  src/lib/src/fwts_uefi.c | 4 ++++
  1 file changed, 4 insertions(+)
 
 diff --git a/src/lib/src/fwts_uefi.c b/src/lib/src/fwts_uefi.c
-index 1f9d31fa..2d925f8d 100644
+index 544145fa..460b0b77 100644
 --- a/src/lib/src/fwts_uefi.c
 +++ b/src/lib/src/fwts_uefi.c
 @@ -59,6 +59,10 @@ typedef struct {
@@ -28,6 +29,3 @@
  /* File system magic numbers */
  #define PSTOREFS_MAGIC          ((__SWORD_TYPE)0x6165676C)
  #define EFIVARFS_MAGIC          ((__SWORD_TYPE)0xde5e81e4)
--- 
-2.13.0
-
diff --git a/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-Undefine-PAGE_SIZE.patch b/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-Undefine-PAGE_SIZE.patch
index f84fbff..1d8c620 100644
--- a/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-Undefine-PAGE_SIZE.patch
+++ b/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-Undefine-PAGE_SIZE.patch
@@ -1,7 +1,7 @@
-From 0857269d5a053b5b4c31cfa01b6501526b24035f Mon Sep 17 00:00:00 2001
+From 244e9551ab9bbc1dfa91d19cd472ef254a94ae41 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Tue, 6 Jun 2017 07:39:28 -0700
-Subject: [PATCH 3/3] Undefine PAGE_SIZE
+Subject: [PATCH] Undefine PAGE_SIZE
 
 musl defines PAGE_SIZE and build complains
 of multiple definitions
@@ -9,12 +9,13 @@
 Upstream-Status: Pending
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
 ---
  src/lib/src/fwts_acpi_tables.c | 1 +
  1 file changed, 1 insertion(+)
 
 diff --git a/src/lib/src/fwts_acpi_tables.c b/src/lib/src/fwts_acpi_tables.c
-index 1d4fc705..71023ad2 100644
+index bdd224aa..58e982a6 100644
 --- a/src/lib/src/fwts_acpi_tables.c
 +++ b/src/lib/src/fwts_acpi_tables.c
 @@ -42,6 +42,7 @@
@@ -25,6 +26,3 @@
  #define PAGE_SIZE	(4096)
  
  static fwts_acpi_table_info	tables[ACPI_MAX_TABLES];
--- 
-2.13.0
-
diff --git a/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-use-intptr_t-to-fix-pointer-to-int-cast-issues.patch b/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-use-intptr_t-to-fix-pointer-to-int-cast-issues.patch
index 3cd3fbb..bebbfa4 100644
--- a/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-use-intptr_t-to-fix-pointer-to-int-cast-issues.patch
+++ b/meta-openembedded/meta-oe/recipes-test/fwts/fwts/0003-use-intptr_t-to-fix-pointer-to-int-cast-issues.patch
@@ -1,13 +1,14 @@
-From d0d76820efe51dd404d381fc4c46544008e757dd Mon Sep 17 00:00:00 2001
+From 1848b8f8b9be500046ca5d632789a068d6151815 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Thu, 8 Jun 2017 16:50:59 -0700
-Subject: [PATCH 3/3] use intptr_t to fix pointer-to-int-cast issues
+Subject: [PATCH] use intptr_t to fix pointer-to-int-cast issues
 
 uintptr_t is guaranteed to be wide enough that
 converting a void* to uintptr_t and back again
 will yield the original pointer value
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
 ---
  src/lib/src/fwts_acpi_tables.c | 4 ++--
  src/lib/src/fwts_mmap.c        | 2 +-
@@ -15,19 +16,19 @@
  3 files changed, 5 insertions(+), 5 deletions(-)
 
 diff --git a/src/lib/src/fwts_acpi_tables.c b/src/lib/src/fwts_acpi_tables.c
-index 832f8d66..d0006529 100644
+index 58e982a6..6522032f 100644
 --- a/src/lib/src/fwts_acpi_tables.c
 +++ b/src/lib/src/fwts_acpi_tables.c
-@@ -150,7 +150,7 @@ static fwts_acpi_table_rsdp *fwts_acpi_get_rsdp(fwts_framework *fw, void *addr,
- 	fwts_acpi_table_rsdp *rsdp = NULL;
- 	*rsdp_len = 0;
+@@ -156,7 +156,7 @@ static fwts_acpi_table_rsdp *fwts_acpi_get_rsdp(fwts_framework *fw, void *addr,
+ 		return NULL;
+ 	}
  
 -	if ((mem = fwts_mmap((off_t)addr, sizeof(fwts_acpi_table_rsdp))) == FWTS_MAP_FAILED)
 +	if ((mem = fwts_mmap((uintptr_t)addr, sizeof(fwts_acpi_table_rsdp))) == FWTS_MAP_FAILED)
  		return NULL;
  
- 	if (fwts_safe_memread(mem, sizeof(fwts_acpi_table_rsdp)) != FWTS_OK) {
-@@ -456,7 +456,7 @@ static int fwts_acpi_load_tables_from_firmware(fwts_framework *fw)
+ 	if (fwts_safe_memcpy(rsdp, mem, sizeof(fwts_acpi_table_rsdp)) != FWTS_OK) {
+@@ -455,7 +455,7 @@ static int fwts_acpi_load_tables_from_firmware(fwts_framework *fw)
  	if ((rsdp = fwts_acpi_get_rsdp(fw, rsdp_addr, &rsdp_len)) == NULL)
  		return FWTS_ERROR;
  
@@ -37,7 +38,7 @@
  	/* Load any tables from XSDT if it's valid */
  	if (rsdp->xsdt_address) {
 diff --git a/src/lib/src/fwts_mmap.c b/src/lib/src/fwts_mmap.c
-index a09f688e..9fe6329a 100644
+index e28abf87..2180b2cc 100644
 --- a/src/lib/src/fwts_mmap.c
 +++ b/src/lib/src/fwts_mmap.c
 @@ -81,7 +81,7 @@ int fwts_munmap(void *mem, const size_t size)
@@ -50,27 +51,24 @@
  	if (munmap((void *)((uint8_t *)mem - offset), size + offset) < 0)
  		return FWTS_ERROR;
 diff --git a/src/lib/src/fwts_smbios.c b/src/lib/src/fwts_smbios.c
-index 8d0ea39b..63b4bf25 100644
+index e5b3c774..c8134926 100644
 --- a/src/lib/src/fwts_smbios.c
 +++ b/src/lib/src/fwts_smbios.c
-@@ -54,7 +54,7 @@ static void *fwts_smbios_find_entry_uefi(fwts_framework *fw, fwts_smbios_entry *
- 	if ((addr = fwts_scan_efi_systab("SMBIOS")) != NULL) {
+@@ -55,7 +55,7 @@ static void *fwts_smbios_find_entry_uefi(fwts_framework *fw, fwts_smbios_entry *
  		fwts_smbios_entry *mapped_entry;
+ 		const size_t size = sizeof(fwts_smbios_entry);
  
--		if ((mapped_entry = fwts_mmap((off_t)addr, sizeof(fwts_smbios_entry))) != FWTS_MAP_FAILED) {
-+		if ((mapped_entry = fwts_mmap((uintptr_t)addr, sizeof(fwts_smbios_entry))) != FWTS_MAP_FAILED) {
- 			*entry = *mapped_entry;
- 			(void)fwts_munmap(mapped_entry, sizeof(fwts_smbios_entry));
- 			*type  = FWTS_SMBIOS;
-@@ -84,7 +84,7 @@ static void *fwts_smbios30_find_entry_uefi(fwts_framework *fw, fwts_smbios30_ent
- 	if ((addr = fwts_scan_efi_systab("SMBIOS3")) != NULL) {
+-		if ((mapped_entry = fwts_mmap((off_t)addr, size)) != FWTS_MAP_FAILED) {
++		if ((mapped_entry = fwts_mmap((uintptr_t)addr, size)) != FWTS_MAP_FAILED) {
+ 			if (fwts_safe_memcpy(entry, mapped_entry, size) == FWTS_OK) {
+ 				(void)fwts_munmap(mapped_entry, size);
+ 				*type  = FWTS_SMBIOS;
+@@ -91,7 +91,7 @@ static void *fwts_smbios30_find_entry_uefi(fwts_framework *fw, fwts_smbios30_ent
  		fwts_smbios30_entry *mapped_entry;
+ 		const size_t size = sizeof(fwts_smbios30_entry);
  
--		if ((mapped_entry = fwts_mmap((off_t)addr, sizeof(fwts_smbios30_entry))) != FWTS_MAP_FAILED) {
-+		if ((mapped_entry = fwts_mmap((uintptr_t)addr, sizeof(fwts_smbios30_entry))) != FWTS_MAP_FAILED) {
- 			*entry = *mapped_entry;
- 			(void)fwts_munmap(mapped_entry, sizeof(fwts_smbios30_entry));
- 			return addr;
--- 
-2.13.1
-
+-		if ((mapped_entry = fwts_mmap((off_t)addr, size)) != FWTS_MAP_FAILED) {
++		if ((mapped_entry = fwts_mmap((uintptr_t)addr, size)) != FWTS_MAP_FAILED) {
+ 			if (fwts_safe_memread(mapped_entry, size) == FWTS_OK) {
+ 				*entry = *mapped_entry;
+ 				(void)fwts_munmap(mapped_entry, size);
diff --git a/meta-openembedded/meta-oe/recipes-test/fwts/fwts_git.bb b/meta-openembedded/meta-oe/recipes-test/fwts/fwts_git.bb
index 87a23af..d3fb644 100644
--- a/meta-openembedded/meta-oe/recipes-test/fwts/fwts_git.bb
+++ b/meta-openembedded/meta-oe/recipes-test/fwts/fwts_git.bb
@@ -5,27 +5,27 @@
 LICENSE = "GPLv2+"
 LIC_FILES_CHKSUM = "file://src/main.c;beginline=1;endline=16;md5=31da590f3e9f3bd34dcdb9e4db568519"
 
-PV = "17.03.00+git${SRCPV}"
+PV = "18.05.00+git${SRCPV}"
 
-SRCREV = "0153ea51cb648b3067a1b327eee6a075b6cfa330"
+SRCREV = "b0ec7aa2ef743d113fd8c5e57c0ca3d5edd86f0e"
 SRC_URI = "git://kernel.ubuntu.com/hwe/fwts.git \
            file://0001-ignore-constant-logical-operand-warning-with-clang.patch \
            file://0001-Include-poll.h-instead-of-deprecated-sys-poll.h.patch \
            file://0002-Define-__SWORD_TYPE-if-not-defined-by-libc.patch \
            file://0003-Undefine-PAGE_SIZE.patch \
            file://0001-Add-correct-printf-qualifier-for-off_t.patch \
-           file://0002-Add-C99-defined-format-for-printing-uint64_t.patch \
            file://0003-use-intptr_t-to-fix-pointer-to-int-cast-issues.patch \
+           file://0001-Remove-Werror-from-build.patch \
            "
 
 S = "${WORKDIR}/git"
 
 COMPATIBLE_HOST = "(i.86|x86_64|aarch64|powerpc64).*-linux"
 
-DEPENDS = "libpcre json-c glib-2.0 dtc"
+DEPENDS = "libpcre json-c glib-2.0 dtc bison-native"
 DEPENDS_append_libc-musl = " libexecinfo"
 
-inherit autotools pkgconfig
+inherit autotools bash-completion pkgconfig
 
 CFLAGS += "-I${STAGING_INCDIR}/json-c -Wno-error=unknown-pragmas"
 LDFLAGS_append_libc-musl = " -lexecinfo"
diff --git a/meta-openembedded/meta-oe/recipes-test/pm-qa/pm-qa_git.bb b/meta-openembedded/meta-oe/recipes-test/pm-qa/pm-qa_git.bb
index 1ee6573..0929090 100644
--- a/meta-openembedded/meta-oe/recipes-test/pm-qa/pm-qa_git.bb
+++ b/meta-openembedded/meta-oe/recipes-test/pm-qa/pm-qa_git.bb
@@ -63,3 +63,6 @@
     done
 }
 RDEPENDS_${PN} +="bash"
+
+# http://errors.yoctoproject.org/Errors/Details/186956/
+EXCLUDE_FROM_WORLD_libc-musl = "1"
diff --git a/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0001-Revert-Makefile-force-sync-after-build-in-case-reboo.patch b/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0001-Revert-Makefile-force-sync-after-build-in-case-reboo.patch
new file mode 100644
index 0000000..469791d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0001-Revert-Makefile-force-sync-after-build-in-case-reboo.patch
@@ -0,0 +1,31 @@
+From 7c97710bfc44d895b7111bef9c55866f00a3589c Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 13 Aug 2018 11:54:27 -0700
+Subject: [PATCH] Revert "Makefile: force sync after build in case reboot loses
+ executable"
+
+This reverts commit ae6322b1baea56a589207c96e358daae8edd0a8f.
+
+Not needed for cross-builds
+
+Upstream-Status: Inappropriate [Cross compile specific]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ Makefile | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/Makefile b/Makefile
+index c0db72c0..5781dda6 100644
+--- a/Makefile
++++ b/Makefile
+@@ -348,7 +348,6 @@ endif
+ stress-ng: $(OBJS)
+ 	@echo "LD $@"
+ 	@$(CC) $(CPPFLAGS) $(CFLAGS) $(OBJS) -lm $(LDFLAGS) -o $@
+-	@sync
+ 
+ makeconfig:
+ 	@if [ ! -s config ]; then \
+-- 
+2.17.0
+
diff --git a/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0001-Several-changes-to-fix-musl-build.patch b/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0001-Several-changes-to-fix-musl-build.patch
index d604f86..c0b3449 100644
--- a/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0001-Several-changes-to-fix-musl-build.patch
+++ b/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0001-Several-changes-to-fix-musl-build.patch
@@ -1,11 +1,13 @@
-From 784dcd09d3f266e271d007f4fd257e85036872ca Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?An=C3=ADbal=20Lim=C3=B3n?= <anibal.limon@linaro.org>
-Date: Tue, 17 Oct 2017 10:13:20 -0500
+From 9bcb4e170f01dbe0a9e7bf6b899c5d9b5283d4c6 Mon Sep 17 00:00:00 2001
+From: Randy MacLeod <Randy.MacLeod@windriver.com>
+Date: Sun, 11 Nov 2018 23:00:53 -0500
 Subject: [PATCH] Several changes to fix musl build
 MIME-Version: 1.0
 Content-Type: text/plain; charset=UTF-8
 Content-Transfer-Encoding: 8bit
 
+Rebased patch for:
+
 stress-{context, stackmmap}.c: Set tests to non-implemented because uses
 swapcontext, musl provide the definition but not the implementation due
   to that functions are pre-POSIX and set to be deprecated.
@@ -19,20 +21,19 @@
 
 Signed-off-by: Aníbal Limón <anibal.limon@linaro.org>
 Signed-off-by: Tim Orling <timothy.t.orling@linux.intel.com>
+Signed-off-by: Randy MacLeod <Randy.MacLeod@windriver.com>
 
 Upstream-status: Pending
-
 ---
  cache.c            |  4 ++++
  stress-madvise.c   |  1 +
- stress-malloc.c    |  2 +-
  stress-pty.c       | 18 ------------------
  stress-resources.c |  1 -
  stress-stackmmap.c |  2 +-
- 6 files changed, 7 insertions(+), 21 deletions(-)
+ 5 files changed, 6 insertions(+), 20 deletions(-)
 
 diff --git a/cache.c b/cache.c
-index fbf7674..936c1ff 100644
+index e8a0f791..4c7bb486 100644
 --- a/cache.c
 +++ b/cache.c
 @@ -28,6 +28,10 @@ typedef struct {
@@ -47,10 +48,10 @@
  #define SYS_CPU_PREFIX               "/sys/devices/system/cpu"
  #define GLOB_PATTERN SYS_CPU_PREFIX  "/cpu[0-9]*"
 diff --git a/stress-madvise.c b/stress-madvise.c
-index 9e71e11..ddf8d2d 100644
+index b2e3497f..77e43a91 100644
 --- a/stress-madvise.c
 +++ b/stress-madvise.c
-@@ -147,6 +147,7 @@ static int stress_random_advise(const args_t *args)
+@@ -146,6 +146,7 @@ static int stress_random_advise(const args_t *args)
  #if defined(MADV_SOFT_OFFLINE)
  	if (advise == MADV_SOFT_OFFLINE) {
  		static int soft_offline_count;
@@ -58,21 +59,8 @@
  
  		/* ..and minimize number of soft offline pages */
  		if ((soft_offline_count >= NUM_SOFT_OFFLINE_MAX) ||
-diff --git a/stress-malloc.c b/stress-malloc.c
-index a46b8c6..427827a 100644
---- a/stress-malloc.c
-+++ b/stress-malloc.c
-@@ -99,7 +99,7 @@ int stress_malloc(const args_t *args)
- 			malloc_max = MIN_MALLOC_MAX;
- 	}
- 
--#if defined(__GNUC__) && defined(__linux__)
-+#if defined(__GNUC__) && defined(__linux__) && defined(M_MMAP_THRESHOLD)
- 	if (get_setting("malloc-threshold", &malloc_threshold))
- 		(void)mallopt(M_MMAP_THRESHOLD, (int)malloc_threshold);
- #endif
 diff --git a/stress-pty.c b/stress-pty.c
-index 1bd1fbd..b1fe573 100644
+index 4dd88ab9..c79a7021 100644
 --- a/stress-pty.c
 +++ b/stress-pty.c
 @@ -26,7 +26,6 @@
@@ -83,7 +71,7 @@
  #include <termios.h>
  
  typedef struct {
-@@ -108,7 +107,6 @@ int stress_pty(const args_t *args)
+@@ -111,7 +110,6 @@ static int stress_pty(const args_t *args)
  		 */
  		for (i = 0; i < n; i++) {
  			struct termios ios;
@@ -91,7 +79,7 @@
  			struct winsize ws;
  			int arg;
  
-@@ -130,22 +128,6 @@ int stress_pty(const args_t *args)
+@@ -133,22 +131,6 @@ static int stress_pty(const args_t *args)
  			if (ioctl(ptys[i].slave, TCSETSF, &ios) < 0)
  				pr_fail_err("ioctl TCSETSF on slave pty");
  #endif
@@ -115,10 +103,10 @@
  			if (ioctl(ptys[i].slave, TIOCGLCKTRMIOS, &ios) < 0)
  				pr_fail_err("ioctl TIOCGLCKTRMIOS on slave pty");
 diff --git a/stress-resources.c b/stress-resources.c
-index 958c99a..af79abd 100644
+index f3dcfb38..86f9a5ba 100644
 --- a/stress-resources.c
 +++ b/stress-resources.c
-@@ -31,7 +31,6 @@
+@@ -28,7 +28,6 @@
  #include <sys/inotify.h>
  #endif
  #if defined(__linux__)
@@ -127,7 +115,7 @@
  #endif
  #if defined(HAVE_LIB_PTHREAD) && defined(__linux__)
 diff --git a/stress-stackmmap.c b/stress-stackmmap.c
-index 9c83a69..2984f09 100644
+index c2f4c31d..54308777 100644
 --- a/stress-stackmmap.c
 +++ b/stress-stackmmap.c
 @@ -24,7 +24,7 @@
@@ -139,3 +127,6 @@
  
  #include <ucontext.h>
  
+-- 
+2.17.0
+
diff --git a/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0002-stress-fcntl-fix-build-for-musl.patch b/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0002-stress-fcntl-fix-build-for-musl.patch
deleted file mode 100644
index ed3287e..0000000
--- a/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng/0002-stress-fcntl-fix-build-for-musl.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From faadbc147394cea9278bc2494f33e3521d88e742 Mon Sep 17 00:00:00 2001
-From: Tim Orling <timothy.t.orling@linux.intel.com>
-Date: Tue, 9 Jan 2018 18:38:45 -0800
-Subject: [PATCH] stress-fcntl: fix build for musl
-
-Signed-off-by: Tim Orling <timothy.t.orling@linux.intel.com>
-
-Upstream-status: Pending
-
----
- stress-fcntl.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/stress-fcntl.c b/stress-fcntl.c
-index 2ea867b..e91b345 100644
---- a/stress-fcntl.c
-+++ b/stress-fcntl.c
-@@ -415,6 +415,7 @@ ofd_lock_abort:	{ /* Nowt */ }
- #if (defined(F_GET_FILE_RW_HINT) && defined(F_SET_FILE_RW_HINT)) | \
-     (defined(F_GET_RW_HINT) && defined(F_SET_RW_HINT))
- 	{
-+		int ret;
- 		size_t i;
- 		unsigned long hint;
- 		static const unsigned long hints[] = {
diff --git a/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng_0.09.14.bb b/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng_0.09.14.bb
deleted file mode 100644
index 7fab430..0000000
--- a/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng_0.09.14.bb
+++ /dev/null
@@ -1,25 +0,0 @@
-SUMMARY = "A tool to load and stress a computer system"
-HOMEPAGE = "http://kernel.ubuntu.com/~cking/stress-ng/"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-
-DEPENDS = "zlib libaio"
-
-SRC_URI = "http://kernel.ubuntu.com/~cking/tarballs/${BPN}/${BP}.tar.xz \
-           file://0002-stress-fcntl-fix-build-for-musl.patch \
-          "
-SRC_URI_append_libc-musl = " \
-    file://0001-Several-changes-to-fix-musl-build.patch \
-    "
-SRC_URI[md5sum] = "1f8b6c2c2830704d2a2814c16082d48e"
-SRC_URI[sha256sum] = "02cac34a5cb041197af60c1867844c6cbb089a6d10a38cdcf7b8f27bfaa6ef8f"
-
-UPSTREAM_CHECK_URI ?= "http://kernel.ubuntu.com/~cking/tarballs/${BPN}/"
-UPSTREAM_CHECK_REGEX ?= "(?P<pver>\d+(\.\d+)+)\.tar"
-
-CFLAGS += "-Wall -Wextra -DVERSION='"$(VERSION)"'"
-
-do_install_append() {
-    install -d ${D}${bindir}
-    install -m 755 ${S}/stress-ng ${D}${bindir}/stress-ng
-}
diff --git a/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng_0.09.45.bb b/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng_0.09.45.bb
new file mode 100644
index 0000000..3e8f2d4
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-test/stress-ng/stress-ng_0.09.45.bb
@@ -0,0 +1,26 @@
+SUMMARY = "A tool to load and stress a computer system"
+HOMEPAGE = "http://kernel.ubuntu.com/~cking/stress-ng/"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+DEPENDS = "zlib libaio"
+
+SRC_URI = "http://kernel.ubuntu.com/~cking/tarballs/${BPN}/${BP}.tar.xz \
+           file://0001-Revert-Makefile-force-sync-after-build-in-case-reboo.patch \
+           "
+SRC_URI_append_libc-musl = " \
+    file://0001-Several-changes-to-fix-musl-build.patch \
+    "
+
+SRC_URI[md5sum] = "b03744c2eb68bf7e9a300e78e397f348"
+SRC_URI[sha256sum] = "0741e3004bf590bb7af3db979a46fe89bee7aaad6065cd1d87d0b7fa49046cb2"
+
+UPSTREAM_CHECK_URI ?= "http://kernel.ubuntu.com/~cking/tarballs/${BPN}/"
+UPSTREAM_CHECK_REGEX ?= "(?P<pver>\d+(\.\d+)+)\.tar"
+
+CFLAGS += "-Wall -Wextra -DVERSION='"$(VERSION)"'"
+
+do_install_append() {
+    install -d ${D}${bindir}
+    install -m 755 ${S}/stress-ng ${D}${bindir}/stress-ng
+}
diff --git a/meta-openembedded/meta-perl/README b/meta-openembedded/meta-perl/README
index 67f2910..3c787f4 100644
--- a/meta-openembedded/meta-perl/README
+++ b/meta-openembedded/meta-perl/README
@@ -52,7 +52,7 @@
 This layer depends on:
 
   URI: git://git.openembedded.org/openembedded-core
-  branch: master
+  branch: thud
   revision: HEAD
   prio: default
 
@@ -75,14 +75,12 @@
 -----------
 
 Send patches / pull requests to openembedded-devel@lists.openembedded.org with
-'[meta-perl]' in the subject.
+'[meta-perl][thud]' in the subject.
 
 When sending single patches, please using something like:
-'git send-email -M -1 --to openembedded-devel@lists.openembedded.org --subject-prefix=meta-perl][PATCH'
+'git send-email -M -1 --to openembedded-devel@lists.openembedded.org --subject-prefix=meta-perl][thud][PATCH'
 
-Layer maintainers:
-    Hongxu Jia <hongxu.jia@windriver.com>
-    Tim "moto-timo" Orling <ticotimo@gmail.com>
+Thud maintainers: Armin kuster <akuster808@gmail.com>
 
 License
 -------
diff --git a/meta-openembedded/meta-perl/conf/layer.conf b/meta-openembedded/meta-perl/conf/layer.conf
index ece6dd0..b2bb379 100644
--- a/meta-openembedded/meta-perl/conf/layer.conf
+++ b/meta-openembedded/meta-perl/conf/layer.conf
@@ -15,4 +15,4 @@
 
 LAYERDEPENDS_perl-layer = "core openembedded-layer"
 
-LAYERSERIES_COMPAT_perl-layer = "sumo"
+LAYERSERIES_COMPAT_perl-layer = "thud"
diff --git a/meta-openembedded/meta-perl/recipes-extended/logcheck/logcheck_1.3.18.bb b/meta-openembedded/meta-perl/recipes-extended/logcheck/logcheck_1.3.18.bb
deleted file mode 100644
index b8766a7..0000000
--- a/meta-openembedded/meta-perl/recipes-extended/logcheck/logcheck_1.3.18.bb
+++ /dev/null
@@ -1,79 +0,0 @@
-SUMMARY = "Analyzes log files and sends noticeable events as email"
-DESCRIPTION = "\
-Logcheck is a simple utility which is designed to allow a system administrator \
-to view the log-files which are produced upon hosts under their control. \
-It does this by mailing summaries of the log-files to them, after first \
-filtering out "normal" entries. \
-Normal entries are entries which match one of the many included regular \
-expression files contain in the database."
-SECTION = "Applications/System"
-HOMEPAGE = "http://logcheck.org/"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=c93c0550bd3173f4504b2cbd8991e50b"
-
-SRC_URI = "git://git.debian.org/git/logcheck/logcheck.git \
-           file://99_logcheck \
-"
-SRCREV = "0a5865d80fa34c55387a1917a3e6f885bcff7f1d"
-
-S = "${WORKDIR}/git"
-
-inherit useradd
-
-USERADD_PACKAGES = "${PN}"
-USERADD_PARAM_${PN} = "-m -g ${BPN} -G adm -r -d ${localstatedir}/lib/${BPN} \
-                       -s /bin/false -c 'logcheck account' ${BPN}"
-GROUPADD_PARAM_${PN} = "-r ${BPN}"
-
-do_install() {
-    # Fix QA Issue
-    sed -i '/install -d $(DESTDIR)\/var\/lock\/logcheck/s/^/#/' Makefile
-
-    # "make install" do not install the manpages. Install them manually.
-    install -m 755 -d ${D}${mandir}/man1
-    install -m 755 -d ${D}${mandir}/man8
-    install -m 644 docs/logcheck-test.1 ${D}${mandir}/man1/
-    install -m 644 docs/logtail.8 ${D}${mandir}/man8/
-    install -m 644 docs/logtail2.8 ${D}${mandir}/man8/
-
-    install -m 755 -d ${D}${sysconfdir}/cron.d
-    install -m 644 debian/logcheck.cron.d ${D}${sysconfdir}/cron.d/logcheck
-    install -m 755 -d ${D}/var/lib/logcheck
-
-    oe_runmake install DESTDIR=${D}
-
-    # install header.txt for generated mails
-    install -m 0644 ${S}/debian/header.txt ${D}${sysconfdir}/${BPN}
-
-    chown -R ${BPN}:${BPN} ${D}${localstatedir}/lib/${BPN}
-    chown -R root:${BPN} ${D}${sysconfdir}/${BPN}
-
-    # Don't install /var/lock when populating rootfs. Do it through volatile
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
-        install -d ${D}${sysconfdir}/default/volatiles
-        install -m 0644 ${WORKDIR}/99_logcheck ${D}${sysconfdir}/default/volatiles
-    fi
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-        install -d ${D}${sysconfdir}/tmpfiles.d
-        echo "d /var/lock/logcheck 0755 logcheck logcheck -" \
-            > ${D}${sysconfdir}/tmpfiles.d/logcheck.conf
-    fi
-}
-
-VIRTUAL-RUNTIME_syslog ??= "rsyslog"
-
-RDEPENDS_${PN} = "\
-    bash \
-    cronie \
-    debianutils-run-parts \
-    grep \
-    lockfile-progs \
-    mime-construct \
-    perl \
-    perl-module-file-basename \
-    perl-module-getopt-std \
-    perl-module-file-glob \
-    ${VIRTUAL-RUNTIME_syslog} \
-"
-
-FILES_${PN} += "${datadir}/logtail"
diff --git a/meta-openembedded/meta-perl/recipes-extended/logcheck/logcheck_1.3.19.bb b/meta-openembedded/meta-perl/recipes-extended/logcheck/logcheck_1.3.19.bb
new file mode 100644
index 0000000..873ac2b
--- /dev/null
+++ b/meta-openembedded/meta-perl/recipes-extended/logcheck/logcheck_1.3.19.bb
@@ -0,0 +1,78 @@
+SUMMARY = "Analyzes log files and sends noticeable events as email"
+DESCRIPTION = "\
+Logcheck is a simple utility which is designed to allow a system administrator \
+to view the log-files which are produced upon hosts under their control. \
+It does this by mailing summaries of the log-files to them, after first \
+filtering out "normal" entries. \
+Normal entries are entries which match one of the many included regular \
+expression files contain in the database."
+SECTION = "Applications/System"
+HOMEPAGE = "http://logcheck.org/"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=c93c0550bd3173f4504b2cbd8991e50b"
+
+SRC_URI = "${DEBIAN_MIRROR}/main/l/${BPN}/${BPN}_${PV}.tar.xz \
+           file://99_logcheck \
+"
+SRC_URI[md5sum] = "7b50d10da6f185228627c55fdd51f624"
+SRC_URI[sha256sum] = "06294c092b2115eca3d054c57778718c91dd2e0fd1c46650b7343c2a92672ca9"
+
+inherit useradd
+
+USERADD_PACKAGES = "${PN}"
+USERADD_PARAM_${PN} = "-m -g ${BPN} -G adm -r -d ${localstatedir}/lib/${BPN} \
+                       -s /bin/false -c 'logcheck account' ${BPN}"
+GROUPADD_PARAM_${PN} = "-r ${BPN}"
+
+do_install() {
+    # Fix QA Issue
+    sed -i '/install -d $(DESTDIR)\/var\/lock\/logcheck/s/^/#/' Makefile
+
+    # "make install" do not install the manpages. Install them manually.
+    install -m 755 -d ${D}${mandir}/man1
+    install -m 755 -d ${D}${mandir}/man8
+    install -m 644 docs/logcheck-test.1 ${D}${mandir}/man1/
+    install -m 644 docs/logtail.8 ${D}${mandir}/man8/
+    install -m 644 docs/logtail2.8 ${D}${mandir}/man8/
+
+    install -m 755 -d ${D}${sysconfdir}/cron.d
+    install -m 644 debian/logcheck.cron.d ${D}${sysconfdir}/cron.d/logcheck
+    install -m 755 -d ${D}/var/lib/logcheck
+
+    oe_runmake install DESTDIR=${D}
+
+    # install header.txt for generated mails
+    install -m 0644 ${S}/debian/header.txt ${D}${sysconfdir}/${BPN}
+
+    chown -R ${BPN}:${BPN} ${D}${localstatedir}/lib/${BPN}
+    chown -R root:${BPN} ${D}${sysconfdir}/${BPN}
+
+    # Don't install /var/lock when populating rootfs. Do it through volatile
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
+        install -d ${D}${sysconfdir}/default/volatiles
+        install -m 0644 ${WORKDIR}/99_logcheck ${D}${sysconfdir}/default/volatiles
+    fi
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+        install -d ${D}${sysconfdir}/tmpfiles.d
+        echo "d /var/lock/logcheck 0755 logcheck logcheck -" \
+            > ${D}${sysconfdir}/tmpfiles.d/logcheck.conf
+    fi
+}
+
+VIRTUAL-RUNTIME_syslog ??= "rsyslog"
+
+RDEPENDS_${PN} = "\
+    bash \
+    cronie \
+    debianutils-run-parts \
+    grep \
+    lockfile-progs \
+    mime-construct \
+    perl \
+    perl-module-file-basename \
+    perl-module-getopt-std \
+    perl-module-file-glob \
+    ${VIRTUAL-RUNTIME_syslog} \
+"
+
+FILES_${PN} += "${datadir}/logtail"
diff --git a/meta-openembedded/meta-perl/recipes-perl/adduser/adduser_3.116.bb b/meta-openembedded/meta-perl/recipes-perl/adduser/adduser_3.116.bb
deleted file mode 100644
index 112a5f0..0000000
--- a/meta-openembedded/meta-perl/recipes-perl/adduser/adduser_3.116.bb
+++ /dev/null
@@ -1,54 +0,0 @@
-SUMMARY = "a utility to add users/groups to the system"
-DESCRIPTION = "adduser, addgroup - add a user or group to the system"
-HOMEPAGE = "http://alioth.debian.org/projects/adduser/"
-SECTION = "base/utils"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://debian/copyright;md5=caed49ab166f22ef31bf1127f558d0ef"
-
-SRC_URI = "http://ftp.de.debian.org/debian/pool/main/a/${BPN}/${BPN}_${PV}.tar.xz \
-           file://adduser-add-M-option-for-useradd.patch \
-"
-
-SRC_URI[md5sum] = "e042a5842b8f24312d6f5a99a1af8f2c"
-SRC_URI[sha256sum] = "72d811ad3ba17d2794b14d19acd1d6b57f9dd31d9250d51e786895dee2daeac0"
-
-inherit cpan-base update-alternatives
-
-S = "${WORKDIR}/${BPN}"
-
-do_install() {
-    install -d ${D}${sbindir}
-    install -m 0755 ${S}/adduser ${D}${sbindir}
-    install -m 0755 ${S}/deluser ${D}${sbindir}
-
-    install -D -m 0644 ${S}/AdduserCommon.pm ${D}${libdir}/perl/${@get_perl_version(d)}/Debian/AdduserCommon.pm
-    sed -i -e "s/VERSION/${PV}/" ${D}${sbindir}/*
-
-    install -d ${D}/${sysconfdir}
-    install -m 0644 ${S}/*.conf ${D}/${sysconfdir}
-
-    install -d ${D}${mandir}/man5
-    install -m 0644 ${S}/doc/*.conf.5 ${D}${mandir}/man5
-    install -d ${D}${mandir}/man8
-    install -m 0644 ${S}/doc/*.8 ${D}${mandir}/man8
-    install -d ${D}${docdir}/${BPN}
-    cp -rf ${S}/examples ${D}${docdir}/${BPN}
-}
-
-RDEPENDS_${PN} += "\
-    shadow \
-    perl-module-getopt-long \
-    perl-module-overloading \
-    perl-module-file-find \
-    perl-module-file-temp \
-"
-
-ALTERNATIVE_${PN} = "adduser deluser addgroup delgroup"
-ALTERNATIVE_PRIORITY = "60"
-ALTERNATIVE_LINK_NAME[adduser] = "${sbindir}/adduser"
-ALTERNATIVE_LINK_NAME[deluser] = "${sbindir}/deluser"
-ALTERNATIVE_LINK_NAME[addgroup] = "${sbindir}/addgroup"
-ALTERNATIVE_LINK_NAME[delgroup] = "${sbindir}/delgroup"
-ALTERNATIVE_TARGET[addgroup] = "${sbindir}/adduser.${BPN}"
-ALTERNATIVE_TARGET[delgroup] = "${sbindir}/deluser.${BPN}"
diff --git a/meta-openembedded/meta-perl/recipes-perl/adduser/adduser_3.118.bb b/meta-openembedded/meta-perl/recipes-perl/adduser/adduser_3.118.bb
new file mode 100644
index 0000000..660a7f7
--- /dev/null
+++ b/meta-openembedded/meta-perl/recipes-perl/adduser/adduser_3.118.bb
@@ -0,0 +1,54 @@
+SUMMARY = "a utility to add users/groups to the system"
+DESCRIPTION = "adduser, addgroup - add a user or group to the system"
+HOMEPAGE = "https://salsa.debian.org/debian/adduser"
+SECTION = "base/utils"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://debian/copyright;md5=caed49ab166f22ef31bf1127f558d0ef"
+
+SRC_URI = "https://launchpad.net/debian/+archive/primary/+sourcefiles/adduser/${PV}/${BPN}_${PV}.tar.xz \
+           file://adduser-add-M-option-for-useradd.patch \
+"
+
+SRC_URI[md5sum] = "44ba2475ebdaafc9613236bdda321c97"
+SRC_URI[sha256sum] = "3e9eea661c9aac6b2c791bfcc1de3a9c6a422d45c8f3d38ed417737ed3166ffc"
+
+S = "${WORKDIR}/${BPN}"
+
+inherit cpan-base update-alternatives
+
+do_install() {
+    install -d ${D}${sbindir}
+    install -m 0755 ${S}/adduser ${D}${sbindir}
+    install -m 0755 ${S}/deluser ${D}${sbindir}
+
+    install -D -m 0644 ${S}/AdduserCommon.pm ${D}${libdir}/perl/${@get_perl_version(d)}/Debian/AdduserCommon.pm
+    sed -i -e "s/VERSION/${PV}/" ${D}${sbindir}/*
+
+    install -d ${D}/${sysconfdir}
+    install -m 0644 ${S}/*.conf ${D}/${sysconfdir}
+
+    install -d ${D}${mandir}/man5
+    install -m 0644 ${S}/doc/*.conf.5 ${D}${mandir}/man5
+    install -d ${D}${mandir}/man8
+    install -m 0644 ${S}/doc/*.8 ${D}${mandir}/man8
+    install -d ${D}${docdir}/${BPN}
+    cp -rf ${S}/examples ${D}${docdir}/${BPN}
+}
+
+RDEPENDS_${PN} += "\
+    shadow \
+    perl-module-getopt-long \
+    perl-module-overloading \
+    perl-module-file-find \
+    perl-module-file-temp \
+"
+
+ALTERNATIVE_${PN} = "adduser deluser addgroup delgroup"
+ALTERNATIVE_PRIORITY = "60"
+ALTERNATIVE_LINK_NAME[adduser] = "${sbindir}/adduser"
+ALTERNATIVE_LINK_NAME[deluser] = "${sbindir}/deluser"
+ALTERNATIVE_LINK_NAME[addgroup] = "${sbindir}/addgroup"
+ALTERNATIVE_LINK_NAME[delgroup] = "${sbindir}/delgroup"
+ALTERNATIVE_TARGET[addgroup] = "${sbindir}/adduser.${BPN}"
+ALTERNATIVE_TARGET[delgroup] = "${sbindir}/deluser.${BPN}"
diff --git a/meta-openembedded/meta-perl/recipes-perl/libcrypt/libcrypt-openssl-guess_0.11.bb b/meta-openembedded/meta-perl/recipes-perl/libcrypt/libcrypt-openssl-guess_0.11.bb
new file mode 100644
index 0000000..21be047
--- /dev/null
+++ b/meta-openembedded/meta-perl/recipes-perl/libcrypt/libcrypt-openssl-guess_0.11.bb
@@ -0,0 +1,21 @@
+SUMMARY = "Guess OpenSSL include path"
+SECTION = "libs"
+LICENSE = "Artistic-1.0 | GPL-1.0+"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=ea914cc2718e8d53bd7744d96e66c03c"
+
+SRC_URI = "http://www.cpan.org/modules/by-module/Crypt/Crypt-OpenSSL-Guess-${PV}.tar.gz "
+
+SRC_URI[md5sum] = "e768fe2c07826b0ac9ea604c79f93032"
+SRC_URI[sha256sum] = "aa6b18e38cb852cbad80a58cd90c395b40819d4d01e0ab37e7703149094d7167"
+
+DEPENDS += "openssl"
+
+RDEPENDS_${PN}="perl-module-config perl-module-exporter perl-module-symbol perl-module-file-spec"
+
+EXTRA_CPANFLAGS = "INC='-I${STAGING_INCDIR}' LIBS='-L${STAGING_LIBDIR} -lssl -L${STAGING_DIR_TARGET}${base_libdir} -lcrypto'"
+
+S = "${WORKDIR}/Crypt-OpenSSL-Guess-${PV}"
+
+inherit cpan
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-perl/recipes-perl/libcrypt/libcrypt-openssl-rsa-perl_0.28.bb b/meta-openembedded/meta-perl/recipes-perl/libcrypt/libcrypt-openssl-rsa-perl_0.28.bb
deleted file mode 100644
index f0c610f..0000000
--- a/meta-openembedded/meta-perl/recipes-perl/libcrypt/libcrypt-openssl-rsa-perl_0.28.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-SUMMARY = "Crypt Openssl RSA cpan module"
-SECTION = "libs"
-LICENSE = "Artistic-1.0 | GPL-1.0+"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=385c55653886acac3821999a3ccd17b3"
-
-SRC_URI = "http://www.cpan.org/modules/by-module/Crypt/Crypt-OpenSSL-RSA-${PV}.tar.gz "
-
-SRC_URI[md5sum] = "86217a5036fc63779c30420b5fd84129"
-SRC_URI[sha256sum] = "5357f977464bb3a8184cf2d3341851a10d5515b4b2b0dfb88bf78995c0ded7be"
-
-DEPENDS += "openssl"
-
-RDEPENDS_${PN}="libcrypt-openssl-random-perl"
-
-EXTRA_CPANFLAGS = "INC='-I${STAGING_INCDIR}' LIBS='-L${STAGING_LIBDIR} -lssl -L${STAGING_DIR_TARGET}${base_libdir} -lcrypto'"
-
-S = "${WORKDIR}/Crypt-OpenSSL-RSA-${PV}"
-
-inherit cpan
-
-do_compile() {
-    export OTHERLDFLAGS='-Wl,-rpath'
-    cpan_do_compile
-}
diff --git a/meta-openembedded/meta-perl/recipes-perl/libcrypt/libcrypt-openssl-rsa-perl_0.30.bb b/meta-openembedded/meta-perl/recipes-perl/libcrypt/libcrypt-openssl-rsa-perl_0.30.bb
new file mode 100644
index 0000000..0a2ad8a
--- /dev/null
+++ b/meta-openembedded/meta-perl/recipes-perl/libcrypt/libcrypt-openssl-rsa-perl_0.30.bb
@@ -0,0 +1,24 @@
+SUMMARY = "Crypt Openssl RSA cpan module"
+SECTION = "libs"
+LICENSE = "Artistic-1.0 | GPL-1.0+"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=a67ceecc5d9a91a5a0d003ba50c26346"
+
+SRC_URI = "http://www.cpan.org/modules/by-module/Crypt/Crypt-OpenSSL-RSA-${PV}.tar.gz "
+
+SRC_URI[md5sum] = "10bca2fc6d0ba1aa329f227424ae87d5"
+SRC_URI[sha256sum] = "23e13531397af102db4fd24bcf70137add7c85c23cca697c43aa71c2959a29ac"
+
+DEPENDS += "libcrypt-openssl-guess-native openssl"
+
+RDEPENDS_${PN}="libcrypt-openssl-random-perl"
+
+EXTRA_CPANFLAGS = "INC='-I${STAGING_INCDIR}' LIBS='-L${STAGING_LIBDIR} -lssl -L${STAGING_DIR_TARGET}${base_libdir} -lcrypto'"
+
+S = "${WORKDIR}/Crypt-OpenSSL-RSA-${PV}"
+
+inherit cpan
+
+do_compile() {
+    export OTHERLDFLAGS='-Wl,-rpath'
+    cpan_do_compile
+}
diff --git a/meta-openembedded/meta-perl/recipes-perl/libio/libio-socket-ssl-perl_2.054.bb b/meta-openembedded/meta-perl/recipes-perl/libio/libio-socket-ssl-perl_2.054.bb
deleted file mode 100644
index ea78bc4..0000000
--- a/meta-openembedded/meta-perl/recipes-perl/libio/libio-socket-ssl-perl_2.054.bb
+++ /dev/null
@@ -1,47 +0,0 @@
-SUMMARY = "Perl library for transparent SSL"
-DESCRIPTION = "This module is a true drop-in replacement for IO::Socket::INET that \
-uses SSL to encrypt data before it is transferred to a remote server \
-or client. IO::Socket::SSL supports all the extra features that one \
-needs to write a full-featured SSL client or server application: \
-multiple SSL contexts, cipher selection, certificate verification, and \
-SSL version selection. As an extra bonus, it works perfectly with \
-mod_perl."
-HOMEPAGE = "http://search.cpan.org/dist/IO-Socket-SSL/"
-SECTION = "libs"
-
-LICENSE = "Artistic-1.0|GPLv1+"
-LIC_FILES_CHKSUM = "file://META.yml;beginline=11;endline=11;md5=963ce28228347875ace682de56eef8e8"
-
-RDEPENDS_${PN} += "\
-    libnet-ssleay-perl \
-    perl-module-autoloader \
-    perl-module-scalar-util \
-    perl-module-io-socket \
-"
-
-SRC_URI = "http://search.cpan.org/CPAN/authors/id/S/SU/SULLR/IO-Socket-SSL-${PV}.tar.gz \
-           file://run-ptest \
-          "
-SRC_URI[md5sum] = "e1b412e28d107c716e7ca637e2b7f8bd"
-SRC_URI[sha256sum] = "02ea04e9a336a7d3ca9aa604c0c5b5aaf3efa513cefecfc73cc79ceeb5131e4b"
-
-S = "${WORKDIR}/IO-Socket-SSL-${PV}"
-
-inherit cpan ptest
-
-do_install_append () {
-    mkdir -p ${D}${docdir}/${PN}/
-    cp ${S}/BUGS ${D}${docdir}/${PN}/
-    cp ${S}/Changes ${D}${docdir}/${PN}/
-    cp ${S}/README ${D}${docdir}/${PN}/
-    cp -pRP ${S}/docs ${D}${docdir}/${PN}/
-    cp -pRP ${S}/certs ${D}${docdir}/${PN}/
-    cp -pRP ${S}/example ${D}${docdir}/${PN}/
-}
-
-do_install_ptest () {
-    cp -r ${B}/t ${D}${PTEST_PATH}
-    cp -r ${B}/certs ${D}${PTEST_PATH}
-}
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-perl/recipes-perl/libio/libio-socket-ssl-perl_2.060.bb b/meta-openembedded/meta-perl/recipes-perl/libio/libio-socket-ssl-perl_2.060.bb
new file mode 100644
index 0000000..20f8808
--- /dev/null
+++ b/meta-openembedded/meta-perl/recipes-perl/libio/libio-socket-ssl-perl_2.060.bb
@@ -0,0 +1,47 @@
+SUMMARY = "Perl library for transparent SSL"
+DESCRIPTION = "This module is a true drop-in replacement for IO::Socket::INET that \
+uses SSL to encrypt data before it is transferred to a remote server \
+or client. IO::Socket::SSL supports all the extra features that one \
+needs to write a full-featured SSL client or server application: \
+multiple SSL contexts, cipher selection, certificate verification, and \
+SSL version selection. As an extra bonus, it works perfectly with \
+mod_perl."
+HOMEPAGE = "http://search.cpan.org/dist/IO-Socket-SSL/"
+SECTION = "libs"
+
+LICENSE = "Artistic-1.0|GPLv1+"
+LIC_FILES_CHKSUM = "file://META.yml;beginline=11;endline=11;md5=963ce28228347875ace682de56eef8e8"
+
+RDEPENDS_${PN} += "\
+    libnet-ssleay-perl \
+    perl-module-autoloader \
+    perl-module-scalar-util \
+    perl-module-io-socket \
+"
+
+SRC_URI = "http://search.cpan.org/CPAN/authors/id/S/SU/SULLR/IO-Socket-SSL-${PV}.tar.gz \
+           file://run-ptest \
+          "
+SRC_URI[md5sum] = "97fa6cd64f15db60f810cd8ab02d57fc"
+SRC_URI[sha256sum] = "fb5b2877ac5b686a5d7b8dd71cf5464ffe75d10c32047b5570674870e46b1b8c"
+
+S = "${WORKDIR}/IO-Socket-SSL-${PV}"
+
+inherit cpan ptest
+
+do_install_append () {
+    mkdir -p ${D}${docdir}/${PN}/
+    cp ${S}/BUGS ${D}${docdir}/${PN}/
+    cp ${S}/Changes ${D}${docdir}/${PN}/
+    cp ${S}/README ${D}${docdir}/${PN}/
+    cp -pRP ${S}/docs ${D}${docdir}/${PN}/
+    cp -pRP ${S}/certs ${D}${docdir}/${PN}/
+    cp -pRP ${S}/example ${D}${docdir}/${PN}/
+}
+
+do_install_ptest () {
+    cp -r ${B}/t ${D}${PTEST_PATH}
+    cp -r ${B}/certs ${D}${PTEST_PATH}
+}
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-dns-perl_1.14.bb b/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-dns-perl_1.14.bb
deleted file mode 100644
index efaa7f7..0000000
--- a/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-dns-perl_1.14.bb
+++ /dev/null
@@ -1,27 +0,0 @@
-DESCRIPTION = "This package contains the DNS.pm module with friends."
-HOMEPAGE = "http://www.net-dns.org/"
-SECTION = "libs"
-LICENSE = "Artistic-1.0 | GPL-1.0+"
-
-LIC_FILES_CHKSUM = "file://README;md5=92d93d8c5bf22de77578531e283dd219"
-
-DEPENDS += "perl"
-
-SRC_URI = "http://search.cpan.org/CPAN/authors/id/N/NL/NLNETLABS/Net-DNS-${PV}.tar.gz"
-
-SRC_URI[md5sum] = "0da1099c0a3548d36ea9e31d5bb9e122"
-SRC_URI[sha256sum] = "83c38a594eeb2c85d66e60047a0f5b403f34bd92a5d13606f02e828d450299fc"
-
-S = "${WORKDIR}/Net-DNS-${PV}"
-
-EXTRA_CPANFLAGS = "EXPATLIBPATH=${STAGING_LIBDIR} EXPATINCPATH=${STAGING_INCDIR}"
-
-inherit cpan
-
-RDEPENDS_${PN} = "perl-module-integer"
-
-do_compile() {
-    export LIBC="$(find ${STAGING_DIR_TARGET}/${base_libdir}/ -name 'libc-*.so')"
-    cpan_do_compile
-}
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-dns-perl_1.18.bb b/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-dns-perl_1.18.bb
new file mode 100644
index 0000000..4e0c9c4
--- /dev/null
+++ b/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-dns-perl_1.18.bb
@@ -0,0 +1,66 @@
+DESCRIPTION = "This package contains the DNS.pm module with friends."
+HOMEPAGE = "http://www.net-dns.org/"
+SECTION = "libs"
+LICENSE = "MIT"
+
+LIC_FILES_CHKSUM = "file://README;beginline=252;endline=269;md5=27db37b42cd1a5173a53922d67072bcb"
+
+DEPENDS += "perl"
+
+SRC_URI = "http://search.cpan.org/CPAN/authors/id/N/NL/NLNETLABS/Net-DNS-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "67af7e5c1c339f60c45c1054374bd8ee"
+SRC_URI[sha256sum] = "52ce1494fc9707fd5a60ed71db5cde727157b7f2363787d730d4d1bd9800a9d3"
+
+UPSTREAM_CHECK_REGEX = "Net\-DNS\-(?P<pver>(\d+\.\d+))(?!_\d+).tar"
+
+S = "${WORKDIR}/Net-DNS-${PV}"
+
+EXTRA_CPANFLAGS = "EXPATLIBPATH=${STAGING_LIBDIR} EXPATINCPATH=${STAGING_INCDIR}"
+
+inherit cpan ptest-perl
+
+RDEPENDS_${PN} = " \
+    libdigest-hmac-perl \
+    perl-module-base \
+    perl-module-constant \
+    perl-module-digest-md5 \
+    perl-module-digest-sha \
+    perl-module-file-spec \
+    perl-module-integer \
+    perl-module-io-file \
+    perl-module-io-select \
+    perl-module-io-socket \
+    perl-module-io-socket-ip \
+    perl-module-mime-base64 \
+    perl-module-scalar-util \
+    perl-module-test-more \
+    perl-module-time-local \
+"
+
+RRECOMMENDS_${PN} += " \
+    libnet-dns-sec-perl \
+"
+
+RDEPENDS_${PN}-ptest += " \
+    perl-module-encode \
+    perl-module-encode-byte \
+    perl-module-extutils-mm \
+    perl-module-extutils-mm-unix \
+    perl-module-overload \
+"
+
+python __anonymous () {
+    # rather than use "find" to determine libc-*.so,
+    # statically export the known paths for glibc and musl
+    import os
+    if d.getVar('TCLIBC') == "glibc":
+        os.environ["LIBC"] = "${STAGING_BASELIBDIR}/libc.so.6"
+    elif d.getVar('TCLIBC') == "musl":
+        os.environ["LIBC"] = "${STAGING_LIBDIR}/libc.so"
+    else:
+       raise bb.parse.SkipRecipe("incompatible with %s C library" %
+                                   d.getVar('TCLIBC'))
+}
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-dns-sec-perl_1.10.bb b/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-dns-sec-perl_1.10.bb
new file mode 100644
index 0000000..3fa6294
--- /dev/null
+++ b/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-dns-sec-perl_1.10.bb
@@ -0,0 +1,33 @@
+DESCRIPTION = "DNSSEC extensions to Net::DNS"
+HOMEPAGE = "http://www.net-dns.org/"
+SECTION = "libs"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://README;beginline=165;endline=192;md5=6ef523fa09e8c272675839e21de16bde"
+
+SRC_URI = "https://cpan.metacpan.org/authors/id/W/WI/WILLEM/Net-DNS-SEC-${PV}.tar.gz"
+SRC_URI[md5sum] = "ffa55a9898192c9d4c623cb1357eba9b"
+SRC_URI[sha256sum] = "37a47d4def72d7338f3cc7cd807ec19bd9e2ae638ae656fa536cf0314801989e"
+
+DEPENDS += "openssl"
+
+UPSTREAM_CHECK_REGEX = "Net\-DNS\-SEC\-(?P<pver>(\d+\.\d+))(?!_\d+).tar"
+
+S = "${WORKDIR}/Net-DNS-SEC-${PV}"
+
+EXTRA_CPANFLAGS = "INC='-I${STAGING_INCDIR}' LIBS='-L${STAGING_LIBDIR} -lssl -L${STAGING_BASELIBDIR} -lcrypto'"
+
+inherit cpan ptest-perl
+
+RDEPENDS_${PN} = " \
+    libnet-dns-perl \
+    libcrypto \
+    perl-module-dynaloader \
+    perl-module-file-find \
+    perl-module-file-spec \
+    perl-module-io-file \
+    perl-module-mime-base64 \
+    perl-module-test-more \
+"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-ssleay-perl/no-exec-on-configure.patch b/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-ssleay-perl/no-exec-on-configure.patch
new file mode 100644
index 0000000..6efa7d8
--- /dev/null
+++ b/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-ssleay-perl/no-exec-on-configure.patch
@@ -0,0 +1,33 @@
+--- a/inc/Module/Install/PRIVATE/Net/SSLeay.pm	2018-08-27 14:56:24.788544991 +0200
++++ b/inc/Module/Install/PRIVATE/Net/SSLeay.pm	2018-08-27 15:00:12.847266331 +0200
+@@ -24,20 +24,7 @@
+     $self->requires_external_cc;
+ 
+     my $prefix = $self->find_openssl_prefix;
+-    my $exec   = $self->find_openssl_exec($prefix);
+-
+-    unless (-x $exec) {
+-        print <<EOM;
+-*** Could not find OpenSSL
+-    If it's already installed, please set the OPENSSL_PREFIX environment
+-    variable accordingly. If it isn't installed yet, get the latest version
+-    from http://www.openssl.org/.
+-EOM
+-        exit 0; # according http://wiki.cpantesters.org/wiki/CPANAuthorNotes this is best-practice when "missing library"
+-    }
+-
+-    $self->check_openssl_version($prefix, $exec);
+-    my $opts = $self->ssleay_get_build_opts($prefix, $exec);
++    my $opts = $self->ssleay_get_build_opts($prefix);
+ 
+     $self->makemaker_args(
+         CCCDLFLAGS => $opts->{cccdlflags},
+@@ -58,7 +45,7 @@
+ }
+ 
+ sub ssleay_get_build_opts {
+-    my ($self, $prefix, $exec) = @_;
++    my ($self, $prefix) = @_;
+ 
+     my $opts = {
+         lib_links  => [],
diff --git a/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-ssleay-perl_1.84.bb b/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-ssleay-perl_1.84.bb
deleted file mode 100644
index cfecef9..0000000
--- a/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-ssleay-perl_1.84.bb
+++ /dev/null
@@ -1,47 +0,0 @@
-SUMMARY = "Net::SSLeay - Perl extension for using OpenSSL"
-DESCRIPTION = "This module offers some high level convenience functions for accessing \
-web pages on SSL servers (for symmetry, same API is offered for \
-accessing http servers, too), a sslcat() function for writing your own \
-clients, and finally access to the SSL api of SSLeay/OpenSSL package \
-so you can write servers or clients for more complicated applications."
-HOMEPAGE = "http://search.cpan.org/dist/Net-SSLeay/"
-SECTION = "libs"
-
-LICENSE = "Artistic-1.0 | GPL-1.0+"
-LIC_FILES_CHKSUM = "file://README;beginline=274;endline=294;md5=67d67095d83e339da538a082fad5f38e"
-
-DEPENDS = "openssl zlib openssl-native"
-RDEPENDS_${PN} += "\
-    libssl \
-    libcrypto \
-    perl-module-carp \
-    perl-module-errno \
-    perl-module-extutils-makemaker \
-    perl-module-mime-base64 \
-    perl-module-socket \
-    zlib \
-"
-
-SRC_URI = "http://search.cpan.org/CPAN/authors/id/M/MI/MIKEM/Net-SSLeay-${PV}.tar.gz \
-           file://run-ptest \
-          "
-SRC_URI[md5sum] = "cfbe968487149626978f427cc9fb8c77"
-SRC_URI[sha256sum] = "823ec3cbb428309d6a9e56f362a9300693ce3215b7fede109adb7be361fff177"
-
-S = "${WORKDIR}/Net-SSLeay-${PV}"
-
-inherit cpan ptest
-
-export OPENSSL_PREFIX="${STAGING_LIBDIR}"
-
-EXTRA_CPANFLAGS = "INC=-I${STAGING_INCDIR} LIBS='-L${STAGING_LIBDIR} -lcrypto -lssl -L${STAGING_BASELIBDIR} -lz'"
-
-do_install_ptest() {
-    cp -r ${B}/t ${D}${PTEST_PATH}
-}
-
-BBCLASSEXTEND = "native"
-
-FILES_${PN}-dbg =+ "${libdir}/perl/vendor_perl/*/auto/Net/SSLeay/.debug/"
-
-RDEPENDS_${PN}-ptest = " perl"
diff --git a/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-ssleay-perl_1.85.bb b/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-ssleay-perl_1.85.bb
new file mode 100644
index 0000000..dccef16
--- /dev/null
+++ b/meta-openembedded/meta-perl/recipes-perl/libnet/libnet-ssleay-perl_1.85.bb
@@ -0,0 +1,49 @@
+SUMMARY = "Net::SSLeay - Perl extension for using OpenSSL"
+DESCRIPTION = "This module offers some high level convenience functions for accessing \
+web pages on SSL servers (for symmetry, same API is offered for \
+accessing http servers, too), a sslcat() function for writing your own \
+clients, and finally access to the SSL api of SSLeay/OpenSSL package \
+so you can write servers or clients for more complicated applications."
+HOMEPAGE = "http://search.cpan.org/dist/Net-SSLeay/"
+SECTION = "libs"
+
+LICENSE = "Artistic-1.0 | GPL-1.0+"
+LIC_FILES_CHKSUM = "file://README;beginline=274;endline=294;md5=67d67095d83e339da538a082fad5f38e"
+
+DEPENDS = "openssl zlib openssl-native"
+RDEPENDS_${PN} += "\
+    libssl \
+    libcrypto \
+    perl-module-carp \
+    perl-module-errno \
+    perl-module-extutils-makemaker \
+    perl-module-mime-base64 \
+    perl-module-socket \
+    zlib \
+"
+
+SRC_URI = "http://search.cpan.org/CPAN/authors/id/M/MI/MIKEM/Net-SSLeay-${PV}.tar.gz \
+           file://no-exec-on-configure.patch \
+           file://run-ptest \
+          "
+SRC_URI[md5sum] = "d602bdce4e0531c6efc276e3e429ca69"
+SRC_URI[sha256sum] = "9d8188b9fb1cae3bd791979c20554925d5e94a138d00414f1a6814549927b0c8"
+
+S = "${WORKDIR}/Net-SSLeay-${PV}"
+
+inherit cpan ptest
+
+do_configure() {
+    export OPENSSL_PREFIX="${STAGING_EXECPREFIXDIR}"
+    cpan_do_configure
+}
+
+do_install_ptest() {
+    cp -r ${B}/t ${D}${PTEST_PATH}
+}
+
+BBCLASSEXTEND = "native"
+
+FILES_${PN}-dbg =+ "${libdir}/perl/vendor_perl/*/auto/Net/SSLeay/.debug/"
+
+RDEPENDS_${PN}-ptest = " perl"
diff --git a/meta-openembedded/meta-python/README b/meta-openembedded/meta-python/README
index 0566e49..9c10c78 100644
--- a/meta-openembedded/meta-python/README
+++ b/meta-openembedded/meta-python/README
@@ -5,10 +5,6 @@
 -------------------------
 
 This layer is intended to be the home of python modules for OpenEmbedded.
-Modules in this layer need to be independent of openembedded-core and
-meta-openembedded/meta-oe. Because of this, modules required by 'gateone'
-and 'anki' are not included and remain in:
-        meta-openembedded/meta-oe/recipes-devtools/python.
 
 Dependencies
 -------------------------
@@ -17,12 +13,12 @@
 
 	URI: git://git.openembedded.org/openembedded-core
 	layers: meta
-	branch: master
+	branch: thud
 	revision: HEAD
 
 	URI: git://git.openembedded.org/meta-openembedded
 	layers: meta-oe
-	branch: master
+	branch: thud
 	revision: HEAD
 
 Please follow the recommended setup procedures of your OE distribution.
@@ -39,15 +35,13 @@
 before posting.
 
 Send pull requests to openembedded-devel@lists.openembedded.org with
-'[meta-python]' in the subject.
+'[meta-python][thud]' in the subject.
 
 When sending single patches, please use something like: 
-'git send-email -M -1 --to=openembedded-devel@lists.openembedded.org --subject-prefix=meta-python][PATCH'
+'git send-email -M -1 --to=openembedded-devel@lists.openembedded.org --subject-prefix=meta-python][thud][PATCH'
 
 Maintenance
 -------------------------
 
-Layer Maintainers:
-        Tim "moto-timo" Orling <TicoTimo@gmail.com>
-        Derek Straka <derek@asterius.io>
+Thud Maintainers: Armin Kuster <akuster808@gmail.com>
 
diff --git a/meta-openembedded/meta-python/conf/layer.conf b/meta-openembedded/meta-python/conf/layer.conf
index 7089071..321d51b 100644
--- a/meta-openembedded/meta-python/conf/layer.conf
+++ b/meta-openembedded/meta-python/conf/layer.conf
@@ -14,6 +14,6 @@
 
 LAYERDEPENDS_meta-python = "core openembedded-layer"
 
-LAYERSERIES_COMPAT_meta-python = "sumo"
+LAYERSERIES_COMPAT_meta-python = "thud"
 
 LICENSE_PATH += "${LAYERDIR}/licenses"
diff --git a/meta-openembedded/meta-python/recipes-connectivity/gateone/gateone_git.bb b/meta-openembedded/meta-python/recipes-connectivity/gateone/gateone_git.bb
index 4577873..5d2ca00 100644
--- a/meta-openembedded/meta-python/recipes-connectivity/gateone/gateone_git.bb
+++ b/meta-openembedded/meta-python/recipes-connectivity/gateone/gateone_git.bb
@@ -16,9 +16,7 @@
 
 inherit setuptools python-dir systemd update-rc.d
 
-DISTUTILS_INSTALL_ARGS = "--root=${D} \
-    --prefix=${prefix} \
-    --install-lib=${PYTHON_SITEPACKAGES_DIR} \
+DISTUTILS_INSTALL_ARGS += " \
     --install-data=${PYTHON_SITEPACKAGES_DIR} \
     --install-scripts=${bindir} \
     --skip_init_scripts"
diff --git a/meta-openembedded/meta-python/recipes-connectivity/python-pyconnman/python-pyconnman.inc b/meta-openembedded/meta-python/recipes-connectivity/python-pyconnman/python-pyconnman.inc
new file mode 100644
index 0000000..beb2baf
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-connectivity/python-pyconnman/python-pyconnman.inc
@@ -0,0 +1,12 @@
+DESCRIPTION = "Python-based Network Connectivity Management"
+HOMEPAGE = "https://pypi.python.org/pypi/pyconnman/"
+LICENSE = "Apache-2.0"
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
+
+SRC_URI[md5sum] = "b7fa82034b1c0e1fb1b518ffe3bb4fc0"
+SRC_URI[sha256sum] = "46c64c0692063fd0c9fb0216d49f7884bec9fa9760d8473db4b1e2f8162fab4a"
+
+inherit pypi
+
+RDEPENDS_${PN} = "connman"
diff --git a/meta-openembedded/meta-python/recipes-connectivity/python-pyconnman/python-pyconnman_0.1.0.bb b/meta-openembedded/meta-python/recipes-connectivity/python-pyconnman/python-pyconnman_0.1.0.bb
index 77b5e4d..3c12db9 100644
--- a/meta-openembedded/meta-python/recipes-connectivity/python-pyconnman/python-pyconnman_0.1.0.bb
+++ b/meta-openembedded/meta-python/recipes-connectivity/python-pyconnman/python-pyconnman_0.1.0.bb
@@ -1,12 +1,5 @@
-DESCRIPTION = "Python-based Network Connectivity Management"
-HOMEPAGE = "https://pypi.python.org/pypi/pyconnman/"
-LICENSE = "Apache-2.0"
+require python-pyconnman.inc
 
-LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
+inherit setuptools
 
-SRC_URI[md5sum] = "b7fa82034b1c0e1fb1b518ffe3bb4fc0"
-SRC_URI[sha256sum] = "46c64c0692063fd0c9fb0216d49f7884bec9fa9760d8473db4b1e2f8162fab4a"
-
-inherit pypi setuptools
-
-RDEPENDS_${PN} = "connman python-dbus python-pprint"
+RDEPENDS_${PN} += "python-dbus python-pprint"
diff --git a/meta-openembedded/meta-python/recipes-connectivity/python-pyconnman/python3-pyconnman_0.1.0.bb b/meta-openembedded/meta-python/recipes-connectivity/python-pyconnman/python3-pyconnman_0.1.0.bb
new file mode 100644
index 0000000..e0f3fdd
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-connectivity/python-pyconnman/python3-pyconnman_0.1.0.bb
@@ -0,0 +1,5 @@
+require python-pyconnman.inc
+
+inherit setuptools3
+
+RDEPENDS_${PN} += "python3-dbus python3-pprint"
diff --git a/meta-openembedded/meta-python/recipes-connectivity/python-pyro4/python-pyro4_4.63.bb b/meta-openembedded/meta-python/recipes-connectivity/python-pyro4/python-pyro4_4.63.bb
deleted file mode 100644
index 6f683e3..0000000
--- a/meta-openembedded/meta-python/recipes-connectivity/python-pyro4/python-pyro4_4.63.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-SUMMARY = "Python Remote Objects"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=378acef375e17a3bff03bd0f78c53220"
-
-SRC_URI[md5sum] = "e1d772b67bf7c6f75fa3174bc95c8839"
-SRC_URI[sha256sum] = "67d2b34156619ba37e92100af95aade8129dd2b7327eb05821d43887451f7d7b"
-
-PYPI_PACKAGE = "Pyro4"
-
-inherit pypi setuptools
-
-RDEPENDS_${PN} += " \
-    ${PYTHON_PN}-logging \
-    ${PYTHON_PN}-selectors34 \
-    ${PYTHON_PN}-serpent \
-    ${PYTHON_PN}-threading \
-    ${PYTHON_PN}-zlib \
-    "
diff --git a/meta-openembedded/meta-python/recipes-connectivity/python-pyro4/python-pyro4_4.73.bb b/meta-openembedded/meta-python/recipes-connectivity/python-pyro4/python-pyro4_4.73.bb
new file mode 100644
index 0000000..88f5b18
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-connectivity/python-pyro4/python-pyro4_4.73.bb
@@ -0,0 +1,18 @@
+SUMMARY = "Python Remote Objects"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=cd13dafd4eeb0802bb6efea6b4a4bdbc"
+
+SRC_URI[md5sum] = "0375c061b93411feb86da01e801df888"
+SRC_URI[sha256sum] = "536b07a097d0619e7ab1effa3747fda177a24168d17a07a93ca9ac30977608f7"
+
+PYPI_PACKAGE = "Pyro4"
+
+inherit pypi setuptools
+
+RDEPENDS_${PN} += " \
+    ${PYTHON_PN}-logging \
+    ${PYTHON_PN}-selectors34 \
+    ${PYTHON_PN}-serpent \
+    ${PYTHON_PN}-threading \
+    ${PYTHON_PN}-zlib \
+    "
diff --git a/meta-openembedded/meta-python/recipes-connectivity/python-thrift/python-thrift_0.11.0.bb b/meta-openembedded/meta-python/recipes-connectivity/python-thrift/python-thrift_0.11.0.bb
index 8047ec7..10cff42 100644
--- a/meta-openembedded/meta-python/recipes-connectivity/python-thrift/python-thrift_0.11.0.bb
+++ b/meta-openembedded/meta-python/recipes-connectivity/python-thrift/python-thrift_0.11.0.bb
@@ -7,6 +7,9 @@
 
 inherit pypi setuptools
 
+# Use different filename to prevent conflicts with thrift itself
+PYPI_SRC_URI_append = ";downloadfilename=${BP}.${PYPI_PACKAGE_EXT}"
+
 RDEPENDS_${PN} += "\
     ${PYTHON_PN}-logging \
     ${PYTHON_PN}-six \
diff --git a/meta-openembedded/meta-python/recipes-connectivity/python-txws/python-txws_0.9.1.bb b/meta-openembedded/meta-python/recipes-connectivity/python-txws/python-txws_0.9.1.bb
index 0b2ac11..f3631cd 100644
--- a/meta-openembedded/meta-python/recipes-connectivity/python-txws/python-txws_0.9.1.bb
+++ b/meta-openembedded/meta-python/recipes-connectivity/python-txws/python-txws_0.9.1.bb
@@ -4,7 +4,7 @@
 LICENSE = "Apache-2.0"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=76699830db7fa9e897f6a1ad05f98ec8"
 
-DEPENDS = "python-twisted python-six python-vcversioner"
+DEPENDS = "python-twisted python-six python-vcversioner python-six-native python-vcversioner-native"
 
 SRC_URI = "git://github.com/MostAwesomeDude/txWS.git"
 SRCREV= "88cf6d9b9b685ffa1720644bd53c742afb10a414"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/pamela_0.3.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/pamela_0.3.0.bb
new file mode 100644
index 0000000..8071fcb
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/pamela_0.3.0.bb
@@ -0,0 +1,15 @@
+DESCRIPTION = "Pamela: yet another Python wrapper for PAM"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://PKG-INFO;md5=bfb663f37eb99232bc8ccfa4ea8f1202"
+
+SRC_URI[md5sum] = "de6516118d51eb5fc97017f3b6d5c68b"
+SRC_URI[sha256sum] = "1e198446a6cdd87704aa0def7621d62e7c20b0e6068e2788b9a866a8355e5d6b"
+
+PYPI_PACKAGE = "pamela"
+
+inherit pypi setuptools
+
+RDEPENDS_${PN} = "libpam"
+
+inherit distro_features_check
+REQUIRED_DISTRO_FEATURES = "pam"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-alembic.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-alembic.inc
index f1a6412..477e89c 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-alembic.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-alembic.inc
@@ -2,8 +2,8 @@
 LICENSE = "BSD"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=c5f1361296835ff94bda73db7dd312a6"
 
-SRC_URI[md5sum] = "5cfef58641c9a94d4a5d547e951a7dda"
-SRC_URI[sha256sum] = "13b8611788acf0d7b617775db5c2ae26554a6d4263c590ef628d448fd05aef56"
+SRC_URI[md5sum] = "762ab9ba56d1c0b1bfbc7c9f7f849c92"
+SRC_URI[sha256sum] = "52d73b1d750f1414fa90c25a08da47b87de1e4ad883935718a8f36396e19e78e"
 
 PYPI_PACKAGE = "alembic"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-alembic_0.9.8.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-alembic_1.0.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-alembic_0.9.8.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-alembic_1.0.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-asn1crypto.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-asn1crypto.inc
index 5c37995..f1f0a3c 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-asn1crypto.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-asn1crypto.inc
@@ -1,7 +1,7 @@
-DESCRIPTION = "Python binding to the Networking and Cryptography (NaCl) library"
-HOMEPAGE = "https://github.com/pyca/pynacl"
+DESCRIPTION = "A fast, pure Python library for parsing and serializing ASN.1 structures"
+HOMEPAGE = "https://github.com/wbond/asn1crypto"
 SECTION = "devel/python"
-LICENSE = "Apache-2.0"
+LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=52010cd3c7d7bd965b55721ef4d93ec2"
 
 PYPI_PACKAGE = "asn1crypto"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-astroid.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-astroid.inc
index ead2b6e..fae0f13 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-astroid.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-astroid.inc
@@ -4,8 +4,8 @@
 LICENSE = "LGPL-2.1"
 LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
 
-SRC_URI[md5sum] = "7d7dc000b25f0cbfcca20cb9a8dc0310"
-SRC_URI[sha256sum] = "35cfae47aac19c7b407b7095410e895e836f2285ccf1220336afba744cc4c5f2"
+SRC_URI[md5sum] = "2dd01ef0d5b5f0fc754c1ba40137b61c"
+SRC_URI[sha256sum] = "fc9b582dba0366e63540982c3944a9230cbc6f303641c51483fa547dcc22393a"
 
 inherit pypi
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-astroid_1.6.3.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-astroid_1.6.5.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-astroid_1.6.3.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-astroid_1.6.5.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-attrs.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-attrs.inc
index c29f058..fa73ea5 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-attrs.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-attrs.inc
@@ -3,8 +3,8 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=d4ab25949a73fe7d4fdee93bcbdbf8ff"
 
-SRC_URI[md5sum] = "d7a89063b2e0fd36bd82389c4d82821d"
-SRC_URI[sha256sum] = "1c7960ccfd6a005cd9f7ba884e6316b5e430a3f1a6c37c5f87d8b43f83b54ec9"
+SRC_URI[sha256sum] = "e0d0eb91441a3b53dab4d9b743eafc1ac44476296a2053b6ca3af0b139faf87b"
+SRC_URI[md5sum] = "3f3f3e0750dab74cfa1dc8b0fd7a5f86"
 
 inherit pypi
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-attrs_17.4.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-attrs_18.1.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-attrs_17.4.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-attrs_18.1.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-automat.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-automat.inc
index 43b9ce9..f6cbb35 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-automat.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-automat.inc
@@ -5,8 +5,8 @@
 
 FILESEXTRAPATHS_prepend := "${THISDIR}/python-automat:"
 
-SRC_URI[md5sum] = "ad7bba58d262d8956d732330cb5ef53d"
-SRC_URI[sha256sum] = "3c1fd04ecf08ac87b4dd3feae409542e9bf7827257097b2b6ed5692f69d6f6a8"
+SRC_URI[md5sum] = "b72d5b7a83c2b1bd6e9ec3614a69f9ea"
+SRC_URI[sha256sum] = "cbd78b83fa2d81fe2a4d23d258e1661dd7493c9a50ee2f1a5b2cac61c1793b0e"
 
 PYPI_PACKAGE = "Automat"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-automat/0001-setup.py-remove-the-dependency-on-m2r.patch b/meta-openembedded/meta-python/recipes-devtools/python/python-automat/0001-setup.py-remove-the-dependency-on-m2r.patch
index d6def98..c29b659 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-automat/0001-setup.py-remove-the-dependency-on-m2r.patch
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-automat/0001-setup.py-remove-the-dependency-on-m2r.patch
@@ -1,4 +1,4 @@
-From d5ebe479fc8fe11c5c75e7f35484849320349222 Mon Sep 17 00:00:00 2001
+From 33b70266930c9093712173c4e0c419815b55e313 Mon Sep 17 00:00:00 2001
 From: Derek Straka <derek@asterius.io>
 Date: Fri, 22 Dec 2017 09:07:00 -0500
 Subject: [PATCH] setup.py: remove the dependency on m2r
@@ -11,14 +11,15 @@
 Upstream-Status: Inappropriate (OE specific)
 
 Signed-off-by: Derek Straka <derek@asterius.io>
+
 ---
  setup.py | 10 ----------
  1 file changed, 10 deletions(-)
 
-Index: Automat-0.6.0/setup.py
-===================================================================
---- Automat-0.6.0.orig/setup.py
-+++ Automat-0.6.0/setup.py
+diff --git a/setup.py b/setup.py
+index d360c64..7b4180a 100644
+--- a/setup.py
++++ b/setup.py
 @@ -4,14 +4,6 @@ Setup file for automat
  
  from setuptools import setup, find_packages
@@ -46,4 +47,4 @@
 -        'm2r',
      ],
      install_requires=[
-         "attrs",
+         "attrs>=16.1.0",
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-automat_0.6.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-automat_0.7.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-automat_0.6.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-automat_0.7.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-aws-iot-device-sdk-python.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-aws-iot-device-sdk-python.inc
index a3299e4..7423fa7 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-aws-iot-device-sdk-python.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-aws-iot-device-sdk-python.inc
@@ -7,8 +7,8 @@
     file://AWSIoTPythonSDK/core/protocol/paho/client.py;endline=14;md5=5a3c8a1a4bb71bd934f450ecff972ad9 \
 "
 
-SRC_URI[md5sum] = "97e8cf0d40ef3765d979c19b534a716d"
-SRC_URI[sha256sum] = "d68cbff396143e837b4c23b6621d3b7ae374281afc75eed8e51a28625d9125ba"
+SRC_URI[md5sum] = "50a5c46410c2b44b5c09f1ea5eb15a3b"
+SRC_URI[sha256sum] = "b3c8af3ce24eab861447a194f3c382509dd70e90452c86a5426f1e7272460177"
 
 inherit pypi
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-aws-iot-device-sdk-python_1.3.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-aws-iot-device-sdk-python_1.4.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-aws-iot-device-sdk-python_1.3.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-aws-iot-device-sdk-python_1.4.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-babel.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-babel.inc
index 4dcb255..14b5a9f 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-babel.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-babel.inc
@@ -1,10 +1,10 @@
 DESCRIPTION = "A collection of tools for internationalizing Python applications"
 HOMEPAGE = "http://babel.edgewall.org/"
 LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=e6eeaabc92cfc2d03f53e789324d7292"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=eebdc057dc12abcc2d6c4453628bfcd4"
 
-SRC_URI[md5sum] = "152a6b17fe4110b95675aceb9af9fab2"
-SRC_URI[sha256sum] = "8ce4cb6fdd4393edd323227cba3a077bceb2a6ce5201c902c65e730046f41f14"
+SRC_URI[md5sum] = "c384ac03026e8fe6f9b90f55201f1bff"
+SRC_URI[sha256sum] = "8cba50f48c529ca3fa18cf81fa9403be176d374ac4d60738b839122dfaaa3d23"
 
 PYPI_PACKAGE = "Babel"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-babel_2.5.3.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-babel_2.6.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-babel_2.5.3.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-babel_2.6.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-backports-functools-lru-cache_1.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-backports-functools-lru-cache_1.4.bb
deleted file mode 100644
index 961436f..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-backports-functools-lru-cache_1.4.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-SUMMARY = "Backport of functools.lru_cache from Python 3.3"
-HOMEPAGE = "https://github.com/jaraco/backports.functools_lru_cache"
-SECTION = "devel/python"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://setup.py;beginline=47;endline=47;md5=98fc3658e5970d26f6b2109808c766be"
-
-PYPI_PACKAGE = "backports.functools_lru_cache"
-
-SRC_URI[md5sum] = "b954e7d5e2ca0f0f66ad2ed12ba800e5"
-SRC_URI[sha256sum] = "31f235852f88edc1558d428d890663c49eb4514ffec9f3650e7f3c9e4a12e36f"
-
-DEPENDS += "python-setuptools-scm-native"
-
-inherit setuptools pypi
-
-RDEPENDS_${PN} += "\
-    ${PYTHON_PN}-pickle \
-    ${PYTHON_PN}-threading \
-    "
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-backports-functools-lru-cache_1.5.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-backports-functools-lru-cache_1.5.bb
new file mode 100644
index 0000000..825444f
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-backports-functools-lru-cache_1.5.bb
@@ -0,0 +1,19 @@
+SUMMARY = "Backport of functools.lru_cache from Python 3.3"
+HOMEPAGE = "https://github.com/jaraco/backports.functools_lru_cache"
+SECTION = "devel/python"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://setup.py;beginline=57;endline=57;md5=98fc3658e5970d26f6b2109808c766be"
+
+PYPI_PACKAGE = "backports.functools_lru_cache"
+
+SRC_URI[md5sum] = "20f53f54cd3f04b3346ce75a54959754"
+SRC_URI[sha256sum] = "9d98697f088eb1b0fa451391f91afb5e3ebde16bbdb272819fd091151fda4f1a"
+
+DEPENDS += "python-setuptools-scm-native"
+
+inherit setuptools pypi
+
+RDEPENDS_${PN} += "\
+    ${PYTHON_PN}-pickle \
+    ${PYTHON_PN}-threading \
+    "
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-behave.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-behave.inc
new file mode 100644
index 0000000..ded7580
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-behave.inc
@@ -0,0 +1,15 @@
+SUMMARY = "A behavior-driven development framework, Python style"
+HOMEPAGE = "https://github.com/behave/behave"
+LICENSE = "BSD-2-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=d950439e8ea6ed233e4288f5e1a49c06"
+
+SRC_URI[md5sum] = "3f05c859a1c45f5ed33e925817ad887d"
+SRC_URI[sha256sum] = "b9662327aa53294c1351b0a9c369093ccec1d21026f050c3bd9b3e5cccf81a86"
+
+inherit pypi
+
+RDEPENDS_${PN} += " \
+    ${PYTHON_PN}-parse-type \
+    ${PYTHON_PN}-setuptools \
+    ${PYTHON_PN}-six \
+    "
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-behave_1.2.6.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-behave_1.2.6.bb
index 6797302..6622168 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-behave_1.2.6.bb
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-behave_1.2.6.bb
@@ -1,10 +1,8 @@
-SUMMARY = "A behavior-driven development framework, Python style"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=d950439e8ea6ed233e4288f5e1a49c06"
+inherit setuptools
+require python-behave.inc
 
-SRC_URI[md5sum] = "3f05c859a1c45f5ed33e925817ad887d"
-SRC_URI[sha256sum] = "b9662327aa53294c1351b0a9c369093ccec1d21026f050c3bd9b3e5cccf81a86"
-
-RDEPENDS_${PN} += "python-difflib python-setuptools python-pkgutil python-misc python-argparse python-xml python-enum34 python-parse python-parse-type python-six"
-
-inherit pypi setuptools
+RDEPENDS_${PN} += " \
+    ${PYTHON_PN}-argparse \
+    ${PYTHON_PN}-enum34 \
+    ${PYTHON_PN}-traceback2 \
+    "
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-bitarray.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-bitarray.inc
index 38a22f6..480f048 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-bitarray.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-bitarray.inc
@@ -1,10 +1,10 @@
 SUMMARY = "A high-level Python efficient arrays of booleans -- C extension"
 HOMEPAGE = "https://github.com/ilanschnell/bitarray"
 LICENSE = "PSF"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=3ba469353f9f2a244b2075902351e37d"
+LIC_FILES_CHKSUM = "file://PKG-INFO;md5=f4ce1ae80a385140f0ddb2bcef410b06"
 
-SRC_URI[md5sum] = "3825184f54f4d93508a28031b4c65d3b"
-SRC_URI[sha256sum] = "7da501356e48a83c61f479393681c1bc4b94e5a34ace7e08cb29e7dd9290ab18"
+SRC_URI[md5sum] = "f3131ac2a277f3b70dbb6132ca8f8889"
+SRC_URI[sha256sum] = "050cd30b810ddb3aa941e7ddfbe0d8065e793012d0a88cb5739ec23624b9895e"
 
 inherit pypi
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-bitarray_0.8.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-bitarray_0.8.3.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-bitarray_0.8.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-bitarray_0.8.3.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-can.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-can.inc
index a71c47b..46f0859 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-can.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-can.inc
@@ -3,8 +3,8 @@
 LICENSE = "LGPLv3"
 LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=38138baa100d7259934590850bc0406e"
 
-SRC_URI[md5sum] = "3310f0aa2a8492d0ff614ecf636ec8a8"
-SRC_URI[sha256sum] = "4a5c01dd67feeda35f88e6c12ea14ac8cabd426b9be0cc5f9fd083fe90a9dbfc"
+SRC_URI[md5sum] = "dcdd3f6b924e3f20acb1ccf4598236cf"
+SRC_URI[sha256sum] = "b5e93b2ee32bdd597d9d908afe5171c402a04c9678ba47b60f33506738b1375b"
 
 PYPI_PACKAGE="python-can"
 
@@ -14,4 +14,5 @@
     ${PYTHON_PN}-misc \
     ${PYTHON_PN}-netserver \
     ${PYTHON_PN}-sqlite3 \
+    ${PYTHON_PN}-wrapt \
 "
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-can_2.1.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-can_2.2.1.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-can_2.1.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-can_2.2.1.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-cassandra-driver.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-cassandra-driver.inc
index 1648d3e..1cc1f4c 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-cassandra-driver.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-cassandra-driver.inc
@@ -8,8 +8,8 @@
 LIC_FILES_CHKSUM = "file://LICENSE;md5=2ee41112a44fe7014dce33e26468ba93"
 SRCNAME = "cassandra-driver"
 
-SRC_URI[md5sum] = "5c8b4a3adfc48180e8ec38b8c4e996fd"
-SRC_URI[sha256sum] = "61b670fb2ba95d51d91fa7b589aae3666df494713f5d1ed78bb5c510778d77f0"
+SRC_URI[md5sum] = "c5bed026bf48c821424c1f6296193908"
+SRC_URI[sha256sum] = "b65218e2582277f5b77d1436e420db8616f63e3437a9e839cdcd7172d760e861"
 
 DISTUTILS_BUILD_ARGS += " \
     --no-libev \
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-certifi.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-certifi.inc
index 26df5c1..c7955c5 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-certifi.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-certifi.inc
@@ -7,7 +7,7 @@
 LICENSE = "ISC"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=f77f61d14ee6feac4228d3ebd26cc1f1"
 
-SRC_URI[md5sum] = "068fd5c3c690ae47504b3e0bf4e56c4c"
-SRC_URI[sha256sum] = "edbc3f203427eef571f79a7692bb160a2b0f7ccaa31953e99bd17e307cf63f7d"
+SRC_URI[md5sum] = "a84571995a209dcd00a1702a74302b88"
+SRC_URI[sha256sum] = "4c1d68a1408dd090d2f3a869aa94c3947cc1d967821d1ed303208c9f41f0f2f4"
 
 BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-certifi_2018.1.18.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-certifi_2018.8.13.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-certifi_2018.1.18.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-certifi_2018.8.13.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-click.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-click.inc
index 718bbab..c81545b 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-click.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-click.inc
@@ -11,6 +11,8 @@
 SRC_URI[md5sum] = "fc4cc00c4863833230d3af92af48abd4"
 SRC_URI[sha256sum] = "f15516df478d5a56180fbf80e68f206010e6d160fc39fa508b65e035fd75130b"
 
+UPSTREAM_CHECK_REGEX = "click/(?P<pver>\d+(\.\d+)+)/"
+
 CLEANBROKEN = "1"
 
 RDEPENDS_${PN} += "\
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-cmd2_0.8.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-cmd2_0.8.1.bb
deleted file mode 100644
index 145ab98..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-cmd2_0.8.1.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-SUMMARY = "Extra features for standard library's cmd module"
-HOMEPAGE = "http://packages.python.org/cmd2/"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://setup.py;beginline=51;endline=51;md5=0f13c9cfc75288223cf7edd2f3b985a2"
-
-SRC_URI[md5sum] = "701b916ffac99137bea413205106f993"
-SRC_URI[sha256sum] = "d09976f9ad2327883c2d07b5acb42e66ad52b17e352873c22041ed124bfe8aba"
-
-inherit pypi setuptools
-
-RDEPENDS_${PN} += "\
-    ${PYTHON_PN}-doctest \
-    ${PYTHON_PN}-pyparsing \
-    ${PYTHON_PN}-pyperclip \
-    ${PYTHON_PN}-shell \
-    ${PYTHON_PN}-six \
-    ${PYTHON_PN}-stringold \
-    ${PYTHON_PN}-subprocess \
-    ${PYTHON_PN}-threading \
-    ${PYTHON_PN}-textutils \
-    "
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-cmd2_0.9.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-cmd2_0.9.2.bb
new file mode 100644
index 0000000..1b75e34
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-cmd2_0.9.2.bb
@@ -0,0 +1,23 @@
+SUMMARY = "Extra features for standard library's cmd module"
+HOMEPAGE = "http://packages.python.org/cmd2/"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=60bc6842001870a418935bd84570b676"
+
+SRC_URI[md5sum] = "bfe0900a2288283a40f0ee7533486a2f"
+SRC_URI[sha256sum] = "e7b6b4b76272a051c943c3c709cd760142af16fbc9218e0ed3c22b28ea38d0a8"
+
+inherit pypi setuptools
+
+RDEPENDS_${PN} += "\
+    ${PYTHON_PN}-doctest \
+    ${PYTHON_PN}-pyparsing \
+    ${PYTHON_PN}-pyperclip \
+    ${PYTHON_PN}-shell \
+    ${PYTHON_PN}-six \
+    ${PYTHON_PN}-stringold \
+    ${PYTHON_PN}-subprocess \
+    ${PYTHON_PN}-threading \
+    ${PYTHON_PN}-textutils \
+    "
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-configparser.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-configparser.inc
index c1fb858..133dbba 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-configparser.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-configparser.inc
@@ -1,4 +1,4 @@
-SUMMARY = "This module provides the ConfigParser class which implements a basic configuration language which provides a structure similar to what’s found in Microsoft Windows INI files."
+SUMMARY = "This module provides the ConfigParser class which implements a basic configuration language which provides a structure similar to what's found in Microsoft Windows INI files."
 SECTION = "devel/python"
 HOMEPAGE = "https://docs.python.org/3/library/configparser.html"
 LICENSE = "MIT"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-crcmod.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-crcmod.inc
new file mode 100644
index 0000000..85da7cb
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-crcmod.inc
@@ -0,0 +1,14 @@
+SUMMARY = "A Python module for generating objects that compute the Cyclic Redundancy Check."
+HOMEPAGE = "https://pypi.org/project/crcmod"
+LICENSE = "MIT"
+SECTION = "devel/python"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=f9a19291627cad2d1dfbfcf3c9fb85c2"
+
+SRC_URI[md5sum] = "2d5b92117d958dcead94f9e17f54cd32"
+SRC_URI[sha256sum] = "dc7051a0db5f2bd48665a990d3ec1cc305a466a77358ca4492826f41f283601e"
+
+inherit pypi
+
+RDEPENDS_${PN} += "${PYTHON_PN}-unittest"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-crcmod_1.7.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-crcmod_1.7.bb
new file mode 100644
index 0000000..45b9a2c
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-crcmod_1.7.bb
@@ -0,0 +1,2 @@
+inherit setuptools
+require python-crcmod.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-cryptography-vectors.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-cryptography-vectors.inc
index 00bb87b..d1e254b 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-cryptography-vectors.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-cryptography-vectors.inc
@@ -8,8 +8,8 @@
     ${PYTHON_PN}-cryptography \
 "
 
-SRC_URI[md5sum] = "ef115b870cc8d8b9f0f4189b512bc170"
-SRC_URI[sha256sum] = "78c4b4f3f84853ea5d038e2f53d355229dd8119fe9cf949c3e497c85c760a5ca"
+SRC_URI[md5sum] = "294d44f32885a6b97d5f9cdd7ffc73a3"
+SRC_URI[sha256sum] = "356a2ded84ae379e556515eec9b68dd74957651a38465d10605bb9fbae280f15"
 
 PYPI_PACKAGE = "cryptography_vectors"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-cryptography-vectors_2.1.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-cryptography-vectors_2.3.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-cryptography-vectors_2.1.4.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-cryptography-vectors_2.3.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-cryptography.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-cryptography.inc
index 4be7907..dbbfe2c 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-cryptography.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-cryptography.inc
@@ -1,7 +1,7 @@
 SUMMARY = "Provides cryptographic recipes and primitives to python developers"
 HOMEPAGE = "https://cryptography.io/"
 LICENSE = "Apache-2.0 | BSD"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=d5ede125ed08d4fd14ec44d334bdb388"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=097f805837700cfac572ac274cd38124"
 
 DEPENDS += " \
     ${PYTHON_PN}-cffi \
@@ -10,8 +10,8 @@
     ${PYTHON_PN}-six \
 "
 
-SRC_URI[md5sum] = "9f39d4d8f2b05f295fa0ff52475ec4f2"
-SRC_URI[sha256sum] = "e4d967371c5b6b2e67855066471d844c5d52d210c36c28d49a8507b96e2c5291"
+SRC_URI[md5sum] = "a0f3f563ab1c5c3bc02fae8d4aa3ad16"
+SRC_URI[sha256sum] = "c132bab45d4bd0fff1d3fe294d92b0a6eb8404e93337b3127bdec9f21de117e6"
 
 RDEPENDS_${PN} += " \
     ${PYTHON_PN}-cffi \
@@ -39,6 +39,7 @@
     ${PYTHON_PN}-iso8601 \
     ${PYTHON_PN}-pretend \
     ${PYTHON_PN}-pytest \
+    ${PYTHON_PN}-pytz \
 "
 
 inherit ptest
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-cryptography_2.1.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-cryptography_2.3.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-cryptography_2.1.4.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-cryptography_2.3.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-cython.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-cython.inc
index 5d3b9d5..0939cad 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-cython.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-cython.inc
@@ -7,8 +7,8 @@
 PYPI_PACKAGE = "Cython"
 BBCLASSEXTEND = "native nativesdk"
 
-SRC_URI[md5sum] = "0e0568d6bed4b09ad01afe0a38805305"
-SRC_URI[sha256sum] = "634e2f10fc8d026c633cffacb45cd8f4582149fa68e1428124e762dbc566e68a"
+SRC_URI[md5sum] = "0cb620e1259818e4ecc1a056e8c3a8be"
+SRC_URI[sha256sum] = "b64575241f64f6ec005a4d4137339fb0ba5e156e826db2fdb5f458060d9979e0"
 
 inherit pypi
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-cython_0.28.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-cython_0.28.5.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-cython_0.28.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-cython_0.28.5.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-daemon_2.1.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-daemon_2.1.2.bb
index 4c18e2b..ffb5beb 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-daemon_2.1.2.bb
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-daemon_2.1.2.bb
@@ -2,7 +2,7 @@
 HOMEPAGE = "https://pagure.io/python-daemon/"
 SECTION = "devel/python"
 
-DEPENDS = "python-docutils"
+DEPENDS += "python-docutils-native"
 RDEPENDS_${PN} = "python-docutils \
                   python-lockfile (>= 0.10) \
                   python-resource \
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-dateutil.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-dateutil.inc
index 333b5e2..9c5a89d 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-dateutil.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-dateutil.inc
@@ -4,8 +4,8 @@
 LICENSE = "BSD-3-Clause & Apache-2.0"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=e3155c7bdc71f66e02678411d2abf996"
 
-SRC_URI[md5sum] = "03a08c8bcf0a2b29f1cd21b9de4d12fb"
-SRC_URI[sha256sum] = "9d8074be4c993fbe4947878ce593052f71dac82932a677d49194d8ce9778002e"
+SRC_URI[md5sum] = "175b7c1a3cc0cb01151eced07c61c0b8"
+SRC_URI[sha256sum] = "e27001de32f627c22380a688bcc43ce83504a7bc5da472209b4c70f02829f0b8"
 
 PYPI_PACKAGE = "python-dateutil"
 inherit pypi
@@ -13,6 +13,8 @@
 PACKAGES =+ "${PN}-zoneinfo"
 FILES_${PN}-zoneinfo = "${libdir}/${PYTHON_DIR}/site-packages/dateutil/zoneinfo"
 
+DEPENDS += "${PYTHON_PN}-setuptools-scm-native"
+
 RDEPENDS_${PN}_class-target = "\
     ${PYTHON_PN}-datetime \
     ${PYTHON_PN}-numbers \
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-dateutil_2.7.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-dateutil_2.7.3.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-dateutil_2.7.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-dateutil_2.7.3.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-dbus_1.2.6.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-dbus_1.2.6.bb
deleted file mode 100644
index 0f18ccc..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-dbus_1.2.6.bb
+++ /dev/null
@@ -1,32 +0,0 @@
-SUMMARY = "Python bindings for the DBus inter-process communication system"
-SECTION = "devel/python"
-HOMEPAGE = "http://www.freedesktop.org/Software/dbus"
-LICENSE = "MIT & AFL-2.1 | GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b03240518994df6d8c974675675e5ca4 \
-		    file://dbus-gmain/COPYING;md5=05c3eacd50f69bb1d58afec460baad57 "
-DEPENDS = "expat dbus dbus-glib virtual/libintl python-pyrex-native"
-
-SRC_URI = "http://dbus.freedesktop.org/releases/dbus-python/dbus-python-${PV}.tar.gz \
-"
-
-SRC_URI[md5sum] = "1ce1ddf2582060f8f971652ea54cc17e"
-SRC_URI[sha256sum] = "32f29c17172cdb9cb61c68b1f1a71dfe7351506fc830869029c47449bd04faeb"
-S = "${WORKDIR}/dbus-python-${PV}"
-
-inherit distutils-base autotools pkgconfig
-
-PACKAGECONFIG ?= ""
-PACKAGECONFIG[docs] = "--enable-html-docs,--disable-html-docs,python3-docutils-native"
-PACKAGECONFIG[api-docs] = "--enable-api-docs,--disable-api-docs,python3-docutils-native python3-epydoc-native"
-
-export STAGING_LIBDIR
-export STAGING_INCDIR
-
-RDEPENDS_${PN} = "python-io python-logging python-stringold python-threading python-xml"
-
-FILES_${PN}-dev += "${libdir}/pkgconfig"
-
-do_install_append() {
-    # Remove files that clash with python3-dbus; their content is same
-    rm ${D}${includedir}/dbus-1.0/dbus/dbus-python.h ${D}${libdir}/pkgconfig/dbus-python.pc
-}
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-dbus_1.2.8.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-dbus_1.2.8.bb
new file mode 100644
index 0000000..b3f7240
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-dbus_1.2.8.bb
@@ -0,0 +1,32 @@
+SUMMARY = "Python bindings for the DBus inter-process communication system"
+SECTION = "devel/python"
+HOMEPAGE = "http://www.freedesktop.org/Software/dbus"
+LICENSE = "MIT & AFL-2.1 | GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b03240518994df6d8c974675675e5ca4 \
+		    file://dbus-gmain/COPYING;md5=05c3eacd50f69bb1d58afec460baad57 "
+DEPENDS = "expat dbus dbus-glib virtual/libintl python-pyrex-native"
+
+SRC_URI = "http://dbus.freedesktop.org/releases/dbus-python/dbus-python-${PV}.tar.gz \
+"
+
+SRC_URI[md5sum] = "7379db774c10904f27e7e2743d90fb43"
+SRC_URI[sha256sum] = "abf12bbb765e300bf8e2a1b2f32f85949eab06998dbda127952c31cb63957b6f"
+S = "${WORKDIR}/dbus-python-${PV}"
+
+inherit distutils-base autotools pkgconfig
+
+# documentation needs python-sphinx, which is not in oe-core or meta-python for now
+# change to use PACKAGECONFIG when python-sphinx is added to oe-core or meta-python
+EXTRA_OECONF += "--disable-documentation"
+
+export STAGING_LIBDIR
+export STAGING_INCDIR
+
+RDEPENDS_${PN} = "python-io python-logging python-stringold python-threading python-xml"
+
+FILES_${PN}-dev += "${libdir}/pkgconfig"
+
+do_install_append() {
+    # Remove files that clash with python3-dbus; their content is same
+    rm ${D}${includedir}/dbus-1.0/dbus/dbus-python.h ${D}${libdir}/pkgconfig/dbus-python.pc
+}
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-django.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-django.inc
index 4ef2d7f..ee3aee6 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-django.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-django.inc
@@ -3,12 +3,14 @@
 LICENSE = "BSD-3-Clause"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=f09eb47206614a4954c51db8a94840fa"
 
-SRC_URI[md5sum] = "f306015e16a8d5024dbac923ac34fffb"
-SRC_URI[sha256sum] = "22383567385a9c406d8a5ce080a2694c82c6b733e157922197e8b393bb3aacd9"
+SRC_URI[md5sum] = "38e82b59a1c27bbf98ccf0564ead7426"
+SRC_URI[sha256sum] = "eb9271f0874f53106a2719c0c35ce67631f6cc27cf81a60c6f8c9817b35a3f6e"
 
 PYPI_PACKAGE = "Django"
 inherit pypi
 
+UPSTREAM_CHECK_REGEX = "(?P<pver>1(\.\d+)+)"
+
 FILES_${PN} += "${datadir}/django"
 
 BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-django_1.11.10.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-django_1.11.14.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-django_1.11.10.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-django_1.11.14.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-djangorestframework.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-djangorestframework.inc
new file mode 100644
index 0000000..8551a83
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-djangorestframework.inc
@@ -0,0 +1,16 @@
+SUMMARY =  "djangorestframework"
+DESCRIPTION = "pip3 install djangorestframework"
+HOMEPAGE = "https://pypi.python.org/pypi/djangorestframework"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE.md;md5=7879a5a716147a784f7e524c9cf103c1"
+
+SRC_URI[md5sum] = "0d481bf8dbb87bb927b46798edc1a9bd"
+SRC_URI[sha256sum] = "607865b0bb1598b153793892101d881466bd5a991de12bd6229abb18b1c86136"
+PYPI_PACKAGE = "djangorestframework"
+
+inherit pypi
+
+RDEPENDS_${PN} += "\
+    ${PYTHON_PN}-django \
+"
\ No newline at end of file
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-djangorestframework_3.9.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-djangorestframework_3.9.0.bb
new file mode 100644
index 0000000..540d12d
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-djangorestframework_3.9.0.bb
@@ -0,0 +1,2 @@
+require python-djangorestframework.inc
+inherit setuptools
\ No newline at end of file
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-flask-migrate.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-flask-migrate.inc
index 7af4fe1..dfb20e9 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-flask-migrate.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-flask-migrate.inc
@@ -2,8 +2,8 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=3b69377f79f3f48c661701236d5a6a85"
 
-SRC_URI[md5sum] = "def4106c80897b7fad2afb3bc05360e4"
-SRC_URI[sha256sum] = "b709ca8642559c3c5a81a33ab10839fa052177accd5ba821047a99db635255ed"
+SRC_URI[md5sum] = "aaeee55431d0287063657122ff41a0e6"
+SRC_URI[sha256sum] = "cd1b4e6cb829eeb41c02ad9202d83bef5f4b7a036dd9fad72ce96ad1e22efb07"
 
 PYPI_PACKAGE = "Flask-Migrate"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-flask-migrate_2.1.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-flask-migrate_2.2.1.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-flask-migrate_2.1.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-flask-migrate_2.2.1.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-flask-sijax.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-flask-sijax.inc
new file mode 100644
index 0000000..ff4e70a
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-flask-sijax.inc
@@ -0,0 +1,8 @@
+DESCRIPTION = "An extension for the Flask microframework that adds Sijax support."
+HOMEPAGE = "https://github.com/spantaleev/flask-sijax"
+LICENSE = "BSD-3-Clause"
+
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=266adc7b911b7c84b837bf77196e1ba6"
+
+PYPI_PACKAGE = "Flask-Sijax"
+RDEPENDS_${PN} = "${PYTHON_PN}-sijax"
\ No newline at end of file
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-flask-sijax_0.4.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-flask-sijax_0.4.1.bb
new file mode 100644
index 0000000..74738fc
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-flask-sijax_0.4.1.bb
@@ -0,0 +1,4 @@
+inherit pypi setuptools
+require python-flask-sijax.inc
+
+SRC_URI[sha256sum] = "fb2bf2d4f75408185102195055d75549fee8d9c9e954dca2427186925cdc429f"
\ No newline at end of file
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-flask.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-flask.inc
index ecf5619..66ad1a6 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-flask.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-flask.inc
@@ -4,10 +4,10 @@
 intentions. And before you ask: It’s BSD licensed!"
 HOMEPAGE = "https://github.com/mitsuhiko/flask/"
 LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=19866b76b054ab30c270c0eb9d7e43d7"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=c011883ac26229b8ba3084f55c7664c6"
 
-SRC_URI[md5sum] = "97278dfdafda98ba7902e890b0289177"
-SRC_URI[sha256sum] = "49f44461237b69ecd901cc7ce66feea0319b9158743dd27a2899962ab214dac1"
+SRC_URI[md5sum] = "824f0f20aae1f44c9c7dc4054adb7969"
+SRC_URI[sha256sum] = "2271c0070dbcb5275fad4a82e29f23ab92682dc45f9dfbc22c02ba9b9322ce48"
 
 CLEANBROKEN = "1"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-flask_0.12.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-flask_1.0.2.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-flask_0.12.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-flask_1.0.2.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-future.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-future.inc
new file mode 100644
index 0000000..2247561
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-future.inc
@@ -0,0 +1,13 @@
+DESCRIPTION = "Clean single-source support for Python 3 and 2"
+HOMEPAGE = "https://python-future.org"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=3f457538b297bd0ef86564b8ac216ad7"
+
+SRC_URI[md5sum] = "3e8e88a2bda48d54b1da7634d04760d7"
+SRC_URI[sha256sum] = "e39ced1ab767b5936646cedba8bcce582398233d6a627067d4c6a454c90cfedb"
+
+PYPI_PACKAGE_HASH = "99abde815842bc6e97d5a7806ad51236630da14ca2f3b1fce94c0bb94d3d"
+
+inherit pypi
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-future_0.16.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-future_0.16.0.bb
index 46f7fe5..d95e1ba 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-future_0.16.0.bb
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-future_0.16.0.bb
@@ -1,13 +1,2 @@
-DESCRIPTION = "Clean single-source support for Python 3 and 2"
-HOMEPAGE = "https://python-future.org"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=3f457538b297bd0ef86564b8ac216ad7"
-
-SRC_URI[md5sum] = "3e8e88a2bda48d54b1da7634d04760d7"
-SRC_URI[sha256sum] = "e39ced1ab767b5936646cedba8bcce582398233d6a627067d4c6a454c90cfedb"
-
-PYPI_PACKAGE_HASH = "99abde815842bc6e97d5a7806ad51236630da14ca2f3b1fce94c0bb94d3d"
-
-inherit pypi setuptools
-
-BBCLASSEXTEND = "native"
+inherit setuptools
+require python-future.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-greenlet.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-greenlet.inc
index 7a42240..fcd81f6 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-greenlet.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-greenlet.inc
@@ -3,7 +3,7 @@
 LIC_FILES_CHKSUM = "file://LICENSE;md5=03143d7a1a9f5d8a0fee825f24ca9c36 \
                     file://LICENSE.PSF;md5=c106931d9429eda0492617f037b8f69a"
 
-SRC_URI[md5sum] = "6e0b9dd5385f81d478451ec8ed1d62b3"
-SRC_URI[sha256sum] = "0fef83d43bf87a5196c91e73cb9772f945a4caaff91242766c5916d1dd1381e4"
+SRC_URI[md5sum] = "a87b6028c3b742b210bf5973939db595"
+SRC_URI[sha256sum] = "f1cc268a15ade58d9a0c04569fe6613e19b8b0345b64453064e2c3c6d79051af"
 
 inherit pypi
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-greenlet_0.4.13.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-greenlet_0.4.14.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-greenlet_0.4.13.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-greenlet_0.4.14.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio-tools.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio-tools.inc
new file mode 100644
index 0000000..91cc62f
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio-tools.inc
@@ -0,0 +1,16 @@
+DESCRIPTION = "Google gRPC tools"
+HOMEPAGE = "http://www.grpc.io/"
+SECTION = "devel/python"
+
+DEPENDS_append = "${PYTHON_PN}-grpcio"
+RDEPENDS_${PN} = "${PYTHON_PN}-grpcio"
+
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/BSD-3-Clause;md5=550794465ba0ec5312d6919e203a55f9"
+
+inherit pypi
+
+SRC_URI[md5sum] = "b2fabfb54c7824c1e49a02de2aa6628e"
+SRC_URI[sha256sum] = "4ce5aa660d7884f23aac1eafa93b97a4c3e2b512edff871e91fdb6ee86ebd5ea"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio-tools_1.14.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio-tools_1.14.1.bb
new file mode 100644
index 0000000..5b19beb
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio-tools_1.14.1.bb
@@ -0,0 +1,2 @@
+inherit setuptools
+require python-grpcio-tools.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio-tools_1.8.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio-tools_1.8.4.bb
deleted file mode 100644
index 45e0cc1..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio-tools_1.8.4.bb
+++ /dev/null
@@ -1,17 +0,0 @@
-DESCRIPTION = "Google gRPC tools"
-HOMEPAGE = "http://www.grpc.io/"
-SECTION = "devel/python"
-
-DEPENDS = "python-grpcio"
-RDEPENDS_${PN} = "python-grpcio"
-
-LICENSE = "BSD-3-Clause"
-LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/BSD-3-Clause;md5=550794465ba0ec5312d6919e203a55f9"
-
-inherit pypi setuptools
-
-SRC_URI[md5sum] = "e04e65afe60410cf178ff2698f052a7c"
-SRC_URI[sha256sum] = "edc84c09039d3a01012ccd97450abd06ee6b980710f6d9f191b50deb6774a75c"
-
-# For usage in other recipies when compiling protobuf files (e.g. by grpcio-tools)
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio.inc
new file mode 100644
index 0000000..23d25f7
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio.inc
@@ -0,0 +1,25 @@
+DESCRIPTION = "Google gRPC"
+HOMEPAGE = "http://www.grpc.io/"
+SECTION = "devel/python"
+
+DEPENDS_append = "${PYTHON_PN}-protobuf"
+
+FILESEXTRAPATHS_prepend := "${THISDIR}/python-grpcio:"
+SRC_URI_append_class-target = " file://0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch "
+
+RDEPENDS_${PN} = "${PYTHON_PN}-protobuf \
+                  ${PYTHON_PN}-setuptools \
+                  ${PYTHON_PN}-six \
+"
+
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/BSD-3-Clause;md5=550794465ba0ec5312d6919e203a55f9"
+
+inherit pypi
+
+SRC_URI[md5sum] = "0987ae2e47b5103de3cacc437874a3c5"
+SRC_URI[sha256sum] = "4bf23666e763ca7ff6010465864e9f088f4ac7ecc1e11abd6f85b250e66b2c05"
+
+CLEANBROKEN = "1"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio/0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch b/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio/0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch
index 0c1d964..996597b 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio/0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio/0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch
@@ -18,16 +18,25 @@
  setup.py | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-Index: grpcio-1.8.4/setup.py
+Index: grpcio-1.14.1/setup.py
 ===================================================================
---- grpcio-1.8.4.orig/setup.py
-+++ grpcio-1.8.4/setup.py
-@@ -115,7 +115,7 @@ if EXTRA_ENV_COMPILE_ARGS is None:
+--- grpcio-1.14.1.orig/setup.py
++++ grpcio-1.14.1/setup.py
+@@ -123,7 +123,7 @@ ENABLE_DOCUMENTATION_BUILD = os.environ.
+ EXTRA_ENV_COMPILE_ARGS = os.environ.get('GRPC_PYTHON_CFLAGS', None)
+ EXTRA_ENV_LINK_ARGS = os.environ.get('GRPC_PYTHON_LDFLAGS', None)
+ if EXTRA_ENV_COMPILE_ARGS is None:
+-  EXTRA_ENV_COMPILE_ARGS = ' -std=c++11'
++  EXTRA_ENV_COMPILE_ARGS = ""
+   if 'win32' in sys.platform and sys.version_info < (3, 5):
+     EXTRA_ENV_COMPILE_ARGS += ' -D_hypot=hypot'
+     # We use define flags here and don't directly add to DEFINE_MACROS below to
+@@ -135,7 +135,7 @@ if EXTRA_ENV_COMPILE_ARGS is None:
      else:
        EXTRA_ENV_COMPILE_ARGS += ' -D_ftime=_ftime64 -D_timeb=__timeb64'
    elif "linux" in sys.platform:
--    EXTRA_ENV_COMPILE_ARGS += ' -std=c++11 -std=gnu99 -fvisibility=hidden -fno-wrapv -fno-exceptions'
+-    EXTRA_ENV_COMPILE_ARGS += ' -std=gnu99 -fvisibility=hidden -fno-wrapv -fno-exceptions'
 +    EXTRA_ENV_COMPILE_ARGS += ' -fvisibility=hidden -fno-wrapv -fno-exceptions'
    elif "darwin" in sys.platform:
      EXTRA_ENV_COMPILE_ARGS += ' -fvisibility=hidden -fno-wrapv -fno-exceptions'
- 
+ EXTRA_ENV_COMPILE_ARGS += ' -DPB_FIELD_16BIT'
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio_1.14.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio_1.14.1.bb
new file mode 100644
index 0000000..820bea4
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio_1.14.1.bb
@@ -0,0 +1,6 @@
+inherit setuptools
+require python-grpcio.inc
+
+RDEPENDS_${PN} += " python-enum34 \
+                    python-futures \
+"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio_1.8.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio_1.8.4.bb
deleted file mode 100644
index bec9d84..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-grpcio_1.8.4.bb
+++ /dev/null
@@ -1,25 +0,0 @@
-DESCRIPTION = "Google gRPC"
-HOMEPAGE = "http://www.grpc.io/"
-SECTION = "devel/python"
-
-DEPENDS = "python-protobuf"
-
-SRC_URI_append_class-target = " file://0001-setup.py-Do-not-mix-C-and-C-compiler-options.patch "
-
-RDEPENDS_${PN} = "python-enum34 \
-                  python-futures \
-                  python-protobuf \
-                  python-setuptools \
-                  python-six \
-"
-
-LICENSE = "BSD-3-Clause"
-LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/BSD-3-Clause;md5=550794465ba0ec5312d6919e203a55f9"
-
-inherit pypi setuptools
-
-SRC_URI[md5sum] = "7860f7c61de3890323670b7b1ff63e56"
-SRC_URI[sha256sum] = "88d87aab9c7889b3ab29dd74aac1a5493ed78b9bf5afba1c069c9dd5531f951d"
-
-# For usage in other recipes when compiling protobuf files (e.g. by grpcio-tools)
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-hyperlink.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-hyperlink.inc
index 2b5b0a0..78e3ee8 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-hyperlink.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-hyperlink.inc
@@ -3,8 +3,8 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=3893d4ed05dcc823f8ed685a9ea19bcb"
 
-SRC_URI[md5sum] = "eaccb9845b559817e838846669cbc68a"
-SRC_URI[sha256sum] = "bc4ffdbde9bdad204d507bd8f554f16bba82dd356f6130cb16f41422909c33bc"
+SRC_URI[sha256sum] = "f01b4ff744f14bc5d0a22a6b9f1525ab7d6312cb0ff967f59414bbac52f0a306"
+SRC_URI[md5sum] = "f41a96779b324d824864696a94b24823"
 
 inherit pypi
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-hyperlink_17.3.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-hyperlink_18.0.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-hyperlink_17.3.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-hyperlink_18.0.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-idna.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-idna.inc
index b1d0d18..519812d 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-idna.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-idna.inc
@@ -1,13 +1,18 @@
 SUMMARY = "Internationalised Domain Names in Applications"
 HOMEPAGE = "https://github.com/kjd/idna"
 LICENSE = "BSD-3-Clause & Python-2.0 & Unicode"
-LIC_FILES_CHKSUM = "file://LICENSE.rst;md5=c9ba5acd829579492fd5eb306c7a0565"
+LIC_FILES_CHKSUM = "file://LICENSE.rst;md5=782775b32f96098512e283fb5d4546cd"
 
-SRC_URI[md5sum] = "c706e2790b016bd0ed4edd2d4ba4d147"
-SRC_URI[sha256sum] = "2c6a5de3089009e3da7c5dde64a141dbc8551d5b7f6cf4ed7c2568d0cc520a8f"
+SRC_URI[md5sum] = "0e5bb69018ddef1b9d95f681182be82c"
+SRC_URI[sha256sum] = "684a38a6f903c1d71d6d5fac066b58d7768af4de2b832e426ec79c30daa94a16"
 
 RDEPENDS_${PN}_class-target = "\
     ${PYTHON_PN}-codecs \
 "
 
+# Remove bundled egg-info
+do_compile_prepend() {
+    rm -rf ${S}/idna.egg-info
+}
+
 BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-idna_2.6.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-idna_2.7.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-idna_2.6.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-idna_2.7.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-inflection.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-inflection.inc
new file mode 100644
index 0000000..556b268
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-inflection.inc
@@ -0,0 +1,14 @@
+SUMMARY = "A port of Ruby on Rails' inflection to Python."
+HOMEPAGE = "https://pypi.org/project/inflection"
+LICENSE = "MIT"
+SECTION = "devel/python"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=de7833d9c2ce0052a4073928c76a13d7"
+
+SRC_URI[md5sum] = "7941165e9f148e0520023941c0886b40"
+SRC_URI[sha256sum] = "18ea7fb7a7d152853386523def08736aa8c32636b047ade55f7578c4edeb16ca"
+
+inherit pypi
+
+RDEPENDS_${PN} += "${PYTHON_PN}-pytest"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-inflection_0.3.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-inflection_0.3.1.bb
new file mode 100644
index 0000000..4a9d497
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-inflection_0.3.1.bb
@@ -0,0 +1,4 @@
+inherit setuptools
+require python-inflection.inc
+
+RDEPENDS_${PN} += "${PYTHON_PN}-codecs"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-intervals.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-intervals.inc
new file mode 100644
index 0000000..1ecca35
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-intervals.inc
@@ -0,0 +1,15 @@
+DESCRIPTION = "Interval arithmetic for Python"
+HOMEPAGE = "https://github.com/AlexandreDecan/python-intervals"
+SECTION = "devel/python"
+
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/BSD-3-Clause;md5=550794465ba0ec5312d6919e203a55f9"
+
+PYPI_PACKAGE := "python-intervals"
+
+inherit pypi
+
+SRC_URI[md5sum] = "a35dd44269fdb134bf19cfd80cb2c120"
+SRC_URI[sha256sum] = "a8a15b7c2fadb8465310f44aa96e384828b35a29de38ac74738cd665924cb8ac"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-intervals_1.5.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-intervals_1.5.4.bb
new file mode 100644
index 0000000..3c2a33b
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-intervals_1.5.4.bb
@@ -0,0 +1,2 @@
+inherit setuptools
+require python-intervals.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-ipaddress_1.0.19.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-ipaddress_1.0.19.bb
deleted file mode 100644
index 9c50b46..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-ipaddress_1.0.19.bb
+++ /dev/null
@@ -1,13 +0,0 @@
-SUMMARY = "Python 3.3+'s ipaddress for Python 2.6, 2.7, 3.2."
-HOMEPAGE = "https://github.com/phihag/ipaddress"
-LICENSE = "Python-2.0"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=7f538584cc3407bf76042def7168548a"
-
-DEPENDS += "python-pip"
-
-SRC_URI[md5sum] = "d0687efaf93a32476d81e90ba0609c57"
-SRC_URI[sha256sum] = "200d8686011d470b5e4de207d803445deee427455cd0cb7c982b68cf82524f81"
-
-inherit pypi setuptools
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-ipaddress_1.0.22.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-ipaddress_1.0.22.bb
new file mode 100644
index 0000000..66de8b6
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-ipaddress_1.0.22.bb
@@ -0,0 +1,13 @@
+SUMMARY = "Python 3.3+'s ipaddress for Python 2.6, 2.7, 3.2."
+HOMEPAGE = "https://github.com/phihag/ipaddress"
+LICENSE = "Python-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=7f538584cc3407bf76042def7168548a"
+
+DEPENDS += "python-pip"
+
+SRC_URI[md5sum] = "74c1ce3109f30eaa1ab3dd342e7b76d4"
+SRC_URI[sha256sum] = "b146c751ea45cad6188dd6cf2d9b757f6f4f8d6ffb96a023e6f2e26eea02a72c"
+
+inherit pypi setuptools
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-isort.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-isort.inc
index 6d13e5f..359b180 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-isort.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-isort.inc
@@ -13,3 +13,5 @@
     ${PYTHON_PN}-datetime \
     ${PYTHON_PN}-shell \
 "
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-linecache2_1.0.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-linecache2_1.0.0.bb
new file mode 100644
index 0000000..386da2d
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-linecache2_1.0.0.bb
@@ -0,0 +1,13 @@
+SUMMARY = "A backport of linecache to older supported Pythons"
+HOMEPAGE = "https://github.com/testing-cabal/linecache2"
+LICENSE = "Python-2.0"
+LIC_FILES_CHKSUM = "file://PKG-INFO;beginline=19;endline=19;md5=368ddc8588431c180ae7c33f4fb57519"
+
+DEPENDS = "${PYTHON_PN}-pbr-native"
+
+SRC_URI[md5sum] = "7b25d0289ec36bff1f9e63c4329ce65c"
+SRC_URI[sha256sum] = "4b26ff4e7110db76eeb6f5a7b64a82623839d595c2038eeda662f2a2db78e97c"
+
+inherit pypi setuptools
+
+CLEAN_BROKEN = "1"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-lxml.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-lxml.inc
index 3f3a1e2..7f355a7 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-lxml.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-lxml.inc
@@ -18,8 +18,8 @@
 
 DEPENDS += "libxml2 libxslt"
 
-SRC_URI[md5sum] = "c266d9062e23b08f66426979a2b36f51"
-SRC_URI[sha256sum] = "e2629cdbcad82b83922a3488937632a4983ecc0fed3e5cfbf430d069382eeb9b"
+SRC_URI[md5sum] = "31239400ca4e130b69993bb3c14204b3"
+SRC_URI[sha256sum] = "e2afbe403090f5893e254958d02875e0732975e73c4c0cdd33c1f009a61963ca"
 
 DISTUTILS_BUILD_ARGS += " \
                      --with-xslt-config='pkg-config libxslt' \
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-lxml_4.2.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-lxml_4.2.4.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-lxml_4.2.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-lxml_4.2.4.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto.inc
new file mode 100644
index 0000000..a36ab8a
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto.inc
@@ -0,0 +1,54 @@
+SUMMARY = "A Python crypto and SSL toolkit"
+HOMEPAGE = "https://gitlab.com/m2crypto/m2crypto"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENCE;md5=b0e1f0b7d0ce8a62c18b1287b991800e"
+
+FILESEXTRAPATHS_prepend := "${THISDIR}/python-m2crypto:"
+
+SRC_URI += "file://0001-setup.py-link-in-sysroot-not-in-host-directories.patch \
+            file://cross-compile-platform.patch \
+            file://m2crypto-0.26.4-gcc_macros.patch \
+           "
+SRC_URI[md5sum] = "7fce3cbf85eb84a669682892b935746b"
+SRC_URI[sha256sum] = "a1b2751cdadc6afac3df8a5799676b7b7c67a6ad144bb62d38563062e7cd3fc6"
+
+PYPI_PACKAGE = "M2Crypto"
+inherit pypi siteinfo
+
+DEPENDS += "openssl swig-native"
+RDEPENDS_${PN} += "python-typing"
+
+DISTUTILS_BUILD_ARGS += "build_ext --openssl=${STAGING_EXECPREFIXDIR} -I${STAGING_INCDIR}"
+DISTUTILS_INSTALL_ARGS += "build_ext --openssl=${STAGING_EXECPREFIXDIR}"
+
+SWIG_FEATURES_x86 = "-D__i386__"
+SWIG_FEATURES_x32 = "-D__ILP32__"
+SWIG_FEATURES ?= "-D__${HOST_ARCH}__"
+export SWIG_FEATURES
+
+# Get around a problem with swig, but only if the
+# multilib header file exists.
+#
+do_configure_prepend() {
+    ${CPP} -dM - < /dev/null | grep -v '__\(STDC\|REGISTER_PREFIX\|GNUC\|STDC_HOSTED\)__' \
+    | sed 's/^\(#define \([^ ]*\) .*\)$/#undef \2\n\1/' > SWIG/gcc_macros.h
+
+    if [ "${SITEINFO_BITS}" = "64" ];then
+        bit="64"
+    else
+        bit="32"
+    fi
+
+    if [ -e ${STAGING_INCDIR}/openssl/opensslconf-${bit}.h ] ;then
+        for i in SWIG/_ec.i SWIG/_evp.i; do
+            sed -i -e "s/opensslconf.*\./opensslconf-${bit}\./" "$i"
+        done
+    elif [ -e ${STAGING_INCDIR}/openssl/opensslconf-n${bit}.h ] ;then
+        for i in SWIG/_ec.i SWIG/_evp.i; do
+            sed -i -e "s/opensslconf.*\./opensslconf-n${bit}\./" "$i"
+        done
+    fi
+}
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto/0001-setup.py-link-in-sysroot-not-in-host-directories.patch b/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto/0001-setup.py-link-in-sysroot-not-in-host-directories.patch
index c71b16f..b339d93 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto/0001-setup.py-link-in-sysroot-not-in-host-directories.patch
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto/0001-setup.py-link-in-sysroot-not-in-host-directories.patch
@@ -10,30 +10,26 @@
  setup.py | 6 +++---
  1 file changed, 3 insertions(+), 3 deletions(-)
 
-diff --git a/setup.py b/setup.py
-index 3407c82..15ed7cd 100644
---- a/setup.py
-+++ b/setup.py
-@@ -127,7 +127,7 @@ class _M2CryptoBuildExt(build_ext.build_ext):
-                 self.openssl = os.path.join(self.openssl, 'OpenSSL')
-         else:
-             self.libraries = ['ssl', 'crypto']
--            self.openssl = '/usr'
-+            self.openssl = os.environ.get( "STAGING_DIR" )
+Index: M2Crypto-0.30.1/setup.py
+===================================================================
+--- M2Crypto-0.30.1.orig/setup.py
++++ M2Crypto-0.30.1/setup.py
+@@ -130,6 +130,7 @@ class _M2CryptoBuildExt(build_ext.build_
+         self.set_undefined_options('build', ('bundledlls', 'bundledlls'))
  
-     def finalize_options(self):
-         '''Overloaded build_ext implementation to append custom openssl
-@@ -143,8 +143,8 @@ class _M2CryptoBuildExt(build_ext.build_ext):
-         if _openssl and os.path.isdir(_openssl):
-             self.openssl = _openssl
+         self.libraries = ['ssl', 'crypto']
++        self.openssl = os.environ.get( "STAGING_DIR" )
+         if sys.platform == 'win32':
+             self.libraries = ['ssleay32', 'libeay32']
+             if self.openssl and openssl_version(self.openssl, 0x10100000, True):
+@@ -150,8 +151,8 @@ class _M2CryptoBuildExt(build_ext.build_
  
--        self.include_dirs.append(os.path.join(self.openssl, 'include'))
--        openssl_library_dir = os.path.join(self.openssl, 'lib')
-+        self.include_dirs.append(os.environ.get( "STAGING_INCDIR" ))
-+        openssl_library_dir = os.environ.get( "STAGING_LIBDIR" )
+         if self.openssl is not None:
+             log.debug('self.openssl = %s', self.openssl)
+-            openssl_library_dir = os.path.join(self.openssl, 'lib')
+-            openssl_include_dir = os.path.join(self.openssl, 'include')
++            openssl_library_dir = os.environ.get( "STAGING_LIBDIR" )
++            openssl_include_dir = os.environ.get( "STAGING_INCDIR" )
  
-         if platform.system() == "Linux":
-             if _multiarch:  # on Fedora/RHEL it is an empty string
--- 
-2.7.4
-
+             self.library_dirs.append(openssl_library_dir)
+             self.include_dirs.append(openssl_include_dir)
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto/cross-compile-platform.patch b/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto/cross-compile-platform.patch
index c6654e5..4b64f46 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto/cross-compile-platform.patch
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto/cross-compile-platform.patch
@@ -4,27 +4,30 @@
 Upstream-Status: Inappropriate
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
-Index: M2Crypto-0.26.0/setup.py
+Index: M2Crypto-0.30.1/setup.py
 ===================================================================
---- M2Crypto-0.26.0.orig/setup.py
-+++ M2Crypto-0.26.0/setup.py
-@@ -141,19 +141,6 @@ class _M2CryptoBuildExt(build_ext.build_
-                 self.include_dirs.append(
-                     os.path.join(self.openssl, 'include', 'openssl'))
+--- M2Crypto-0.30.1.orig/setup.py
++++ M2Crypto-0.30.1/setup.py
+@@ -160,22 +160,6 @@ class _M2CryptoBuildExt(build_ext.build_
+             log.debug('self.include_dirs = %s', self.include_dirs)
+             log.debug('self.library_dirs = %s', self.library_dirs)
  
+-        if platform.system() == "Linux":
 -            # For RedHat-based distros, the '-D__{arch}__' option for
 -            # Swig needs to be normalized, particularly on i386.
 -            mach = platform.machine().lower()
 -            if mach in ('i386', 'i486', 'i586', 'i686'):
 -                arch = '__i386__'
--            elif mach in ('ppc64', 'powerpc64'):
+-            elif mach in ('ppc64', 'powerpc64', 'ppc64le', 'ppc64el'):
 -                arch = '__powerpc64__'
 -            elif mach in ('ppc', 'powerpc'):
 -                arch = '__powerpc__'
 -            else:
 -                arch = '__%s__' % mach
 -            self.swig_opts.append('-D%s' % arch)
+-            if mach in ('ppc64le', 'ppc64el'):
+-                self.swig_opts.append('-D_CALL_ELF=2')
 -
          self.swig_opts.extend(['-I%s' % i for i in self.include_dirs])
-         self.swig_opts.append('-includeall')
-         self.swig_opts.append('-modern')
+ 
+         # Some Linux distributor has added the following line in
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto/m2crypto-0.26.4-gcc_macros.patch b/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto/m2crypto-0.26.4-gcc_macros.patch
index 2d738cc..7f6dd29 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto/m2crypto-0.26.4-gcc_macros.patch
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto/m2crypto-0.26.4-gcc_macros.patch
@@ -1,16 +1,22 @@
 Imported from Fedora
 
---- M2Crypto/SWIG/_m2crypto.i	2017-09-26 11:26:33.000000000 +0200
-+++ M2Crypto-0.26.4/SWIG/_m2crypto.i	2017-09-26 21:04:14.080330741 +0200
-@@ -7,6 +7,7 @@
-  * Copyright (c) 2009-2010 Heikki Toivonen. All rights reserved.
+Index: M2Crypto-0.30.1/SWIG/_m2crypto.i
+===================================================================
+--- M2Crypto-0.30.1.orig/SWIG/_m2crypto.i
++++ M2Crypto-0.30.1/SWIG/_m2crypto.i
+@@ -8,6 +8,11 @@
   *
   */
-+%import "gcc_macros.h"
  
++%import "gcc_macros.h"
++
++%ignore WCHAR_MAX;
++%ignore WCHAR_MIN;
++
  %module(threads=1) m2crypto
  /* We really don't need threadblock (PyGILState_Ensure() etc.) anywhere.
-@@ -15,11 +16,6 @@
+    Disable threadallow as well, only enable it for operations likely to
+@@ -15,11 +20,6 @@
  %nothreadblock;
  %nothreadallow;
  
@@ -20,5 +26,10 @@
 -#endif
 -
  %{
- #if __GNUC__ < 5
- #pragma GCC diagnostic ignored "-Wunused-label"
+ #ifdef _WIN32
+ #define _WINSOCKAPI_
+@@ -95,4 +95,3 @@ static PyObject *x509_store_verify_cb_fu
+ %constant int encrypt = 1;
+ %constant int decrypt = 0;
+ #endif
+-  
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto_0.26.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto_0.26.4.bb
deleted file mode 100644
index 272c76c..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto_0.26.4.bb
+++ /dev/null
@@ -1,50 +0,0 @@
-SUMMARY = "A Python crypto and SSL toolkit"
-HOMEPAGE = "https://gitlab.com/m2crypto/m2crypto"
-
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://LICENCE;md5=b0e1f0b7d0ce8a62c18b1287b991800e"
-
-SRC_URI += "file://0001-setup.py-link-in-sysroot-not-in-host-directories.patch \
-            file://cross-compile-platform.patch \
-            file://m2crypto-0.26.4-gcc_macros.patch \
-           "
-SRC_URI[md5sum] = "5c74c25ba8b45122318a165a3a2059ad"
-SRC_URI[sha256sum] = "5cae7acc0b34821f8c0ddf6665e482893fe1f198ad6379e61ffa9d8e65f5c199"
-
-PYPI_PACKAGE = "M2Crypto"
-inherit pypi setuptools siteinfo
-
-DEPENDS += "openssl swig-native"
-RDEPENDS_${PN} += "python-typing"
-
-DISTUTILS_BUILD_ARGS += "build_ext --openssl=${STAGING_DIR_HOST} -I${STAGING_INCDIR}"
-DISTUTILS_INSTALL_ARGS += "build_ext --openssl=${STAGING_DIR_HOST}"
-
-SWIG_FEATURES_x86 = "-D__i386__"
-SWIG_FEATURES ?= "-D__${HOST_ARCH}__"
-export SWIG_FEATURES
-
-# Get around a problem with swig, but only if the
-# multilib header file exists.
-#
-do_compile_prepend() {
-    ${CPP} -dM - < /dev/null | grep -v __STDC__ | grep -v __REGISTER_PREFIX__ | grep -v __GNUC__ \
-	| sed 's/^\(#define \([^ ]*\) .*\)$/#undef \2\n\1/' > SWIG/gcc_macros.h
-    if [ "${SITEINFO_BITS}" = "64" ];then
-        bit="64"
-    else
-        bit="32"
-    fi
-
-    if [ -e ${STAGING_INCDIR}/openssl/opensslconf-${bit}.h ] ;then
-        for i in SWIG/_ec.i SWIG/_evp.i; do
-            sed -i -e "s/opensslconf.*\./opensslconf-${bit}\./" "$i"
-        done
-    elif [ -e ${STAGING_INCDIR}/openssl/opensslconf-n${bit}.h ] ;then
-        for i in SWIG/_ec.i SWIG/_evp.i; do
-            sed -i -e "s/opensslconf.*\./opensslconf-n${bit}\./" "$i"
-        done
-    fi
-}
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto_0.30.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto_0.30.1.bb
new file mode 100644
index 0000000..c612fcd
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-m2crypto_0.30.1.bb
@@ -0,0 +1,2 @@
+inherit setuptools
+require python-m2crypto.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-mccabe_0.4.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-mccabe_0.4.0.bb
index a86d158..6b63cd7 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-mccabe_0.4.0.bb
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-mccabe_0.4.0.bb
@@ -16,3 +16,5 @@
     python-prettytable \
     python-cmd2 \
     python-pyparsing"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-mock_2.0.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-mock_2.0.0.bb
index 840c36e..210502f 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-mock_2.0.0.bb
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-mock_2.0.0.bb
@@ -1,5 +1,5 @@
 SUMMARY = "A Python Mocking and Patching Library for Testing"
-LICENSE = "Apache-2.0"
+LICENSE = "BSD-2-Clause"
 LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=de9dfbf780446b18aab11f00baaf5b7e"
 
 SRC_URI[md5sum] = "0febfafd14330c9dcaa40de2d82d40ad"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-monotonic_1.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-monotonic_1.4.bb
deleted file mode 100644
index 4c5d8ae..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-monotonic_1.4.bb
+++ /dev/null
@@ -1,10 +0,0 @@
-SUMMARY = "An implementation of time.monotonic() for Python 2.0 through 3.2"
-LICENSE = "Apache-2.0"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=d2794c0df5b907fdace235a619d80314"
-
-SRC_URI[md5sum] = "29302cd6b1013b3ab0d1ed78e20d22f2"
-SRC_URI[sha256sum] = "a02611d5b518cd4051bf22d21bd0ae55b3a03f2d2993a19b6c90d9d168691f84"
-
-inherit pypi setuptools
-
-RDEPENDS_${PN} += "${PYTHON_PN}-ctypes ${PYTHON_PN}-io ${PYTHON_PN}-re ${PYTHON_PN}-threading"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-monotonic_1.5.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-monotonic_1.5.bb
new file mode 100644
index 0000000..01e7b1c
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-monotonic_1.5.bb
@@ -0,0 +1,10 @@
+SUMMARY = "An implementation of time.monotonic() for Python 2.0 through 3.2"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=d2794c0df5b907fdace235a619d80314"
+
+SRC_URI[md5sum] = "9f81cb0e5966479754453dea2b6822f4"
+SRC_URI[sha256sum] = "23953d55076df038541e648a53676fb24980f7a1be290cdda21300b3bc21dfb0"
+
+inherit pypi setuptools
+
+RDEPENDS_${PN} += "${PYTHON_PN}-ctypes ${PYTHON_PN}-io ${PYTHON_PN}-re ${PYTHON_PN}-threading"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-ndg-httpsclient.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-ndg-httpsclient.inc
index d743023..91235b9 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-ndg-httpsclient.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-ndg-httpsclient.inc
@@ -3,8 +3,8 @@
 LICENSE = "BSD"
 LIC_FILES_CHKSUM = "file://MANIFEST.in;md5=ce22c0cd986d2de3f7073cd6b5523ae0"
 
-SRC_URI[md5sum] = "a0d349cf9530e331697a6e5ab1f40de6"
-SRC_URI[sha256sum] = "fba4d4798dcac2965874f24afb6631b4326baa4bd02505744d34f690c354856a"
+SRC_URI[md5sum] = "b0fc8ea38f87d2c1ab1ed79a95c078f9"
+SRC_URI[sha256sum] = "d72faed0376ab039736c2ba12e30695e2788c4aa569c9c3e3d72131de2592210"
 
 PYPI_PACKAGE = "ndg_httpsclient"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-ndg-httpsclient_0.4.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-ndg-httpsclient_0.4.4.bb
deleted file mode 100644
index ca0eb32..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-ndg-httpsclient_0.4.4.bb
+++ /dev/null
@@ -1,2 +0,0 @@
-require python-ndg-httpsclient.inc
-inherit pypi setuptools
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-ndg-httpsclient_0.5.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-ndg-httpsclient_0.5.1.bb
new file mode 100644
index 0000000..9cd881a
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-ndg-httpsclient_0.5.1.bb
@@ -0,0 +1,6 @@
+require python-ndg-httpsclient.inc
+inherit pypi setuptools update-alternatives
+
+ALTERNATIVE_${PN} = "ndg_httpclient"
+ALTERNATIVE_LINK_NAME[ndg_httpclient] = "${bindir}/ndg_httpclient"
+ALTERNATIVE_PRIORITY = "20"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pandas.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pandas.inc
index b9f84a6..d6ca243 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pandas.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pandas.inc
@@ -6,13 +6,13 @@
 LICENSE = "BSD-3-Clause"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=ee0470f2de336c370a71c2f8d5e81c11"
 
-SRC_URI[md5sum] = "c7a2757b607748255f3270221ac61d59"
-SRC_URI[sha256sum] = "44a94091dd71f05922eec661638ec1a35f26d573c119aa2fad964f10a2880e6c"
+SRC_URI[md5sum] = "7b597c7f989652e0c9af5f09a157e3ae"
+SRC_URI[sha256sum] = "5b24ca47acf69222e82530e89111dd9d14f9b970ab2cd3a1c2c78f0c4fbba4f4"
 
 inherit pypi
 
 DEPENDS += " \
-    ${PYTHON_PN}-numpy-native \
+    ${PYTHON_PN}-numpy-native ${PYTHON_PN}-cython-native \
 "
 
 RDEPENDS_${PN} += " \
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pandas_0.22.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pandas_0.23.4.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-pandas_0.22.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-pandas_0.23.4.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-parse-type.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-parse-type.inc
new file mode 100644
index 0000000..4549ec9
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-parse-type.inc
@@ -0,0 +1,12 @@
+SUMMARY = "Simplifies building parse types based on the parse module"
+HOMEPAGE = "https://github.com/jenisys/parse_type"
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=d07323820cca0f1d192cbbf8a0516f95"
+
+SRC_URI[md5sum] = "b5fa59e45965d1b2896023742df2e707"
+SRC_URI[sha256sum] = "f596bdc75d3dd93036fbfe3d04127da9f6df0c26c36e01e76da85adef4336b3c"
+
+PYPI_PACKAGE = "parse_type"
+inherit pypi
+
+RDEPENDS_${PN} += "${PYTHON_PN}-parse"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-parse-type_0.4.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-parse-type_0.4.2.bb
index b516c59..8e10e80 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-parse-type_0.4.2.bb
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-parse-type_0.4.2.bb
@@ -1,11 +1,2 @@
-SUMMARY = "Simplifies building parse types based on the parse module"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=d07323820cca0f1d192cbbf8a0516f95"
-PYPI_PACKAGE = "parse_type"
-
-SRC_URI[md5sum] = "b5fa59e45965d1b2896023742df2e707"
-SRC_URI[sha256sum] = "f596bdc75d3dd93036fbfe3d04127da9f6df0c26c36e01e76da85adef4336b3c"
-
-RDEPENDS_${PN} += "python-parse"
-
-inherit pypi setuptools
+inherit setuptools
+require python-parse-type.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-parse.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-parse.inc
new file mode 100644
index 0000000..fa55a93
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-parse.inc
@@ -0,0 +1,14 @@
+SUMMARY = "Parse strings using a specification based on the Python format() syntax"
+HOMEPAGE = "https://github.com/r1chardj0n3s/parse"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://parse.py;beginline=1273;endline=1291;md5=5147afdd9b3615290ad8733f0137a1a1"
+
+SRC_URI[md5sum] = "fa69ab2fe846f9b183411391f7c6897b"
+SRC_URI[sha256sum] = "c3cdf6206f22aeebfa00e5b954fcfea13d1b2dc271c75806b6025b94fb490939"
+
+inherit pypi
+
+RDEPENDS_${PN} += "\
+    ${PYTHON_PN}-datetime \
+    ${PYTHON_PN}-logging \
+    "
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-parse_1.8.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-parse_1.8.2.bb
deleted file mode 100644
index 8e16372..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-parse_1.8.2.bb
+++ /dev/null
@@ -1,13 +0,0 @@
-SUMMARY = "Parse strings using a specification based on the Python format() syntax"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://parse.py;beginline=1191;endline=1209;md5=5147afdd9b3615290ad8733f0137a1a1"
-
-SRC_URI[md5sum] = "42002338551bdfa0f01bbe4e679a17dd"
-SRC_URI[sha256sum] = "8048dde3f5ca07ad7ac7350460952d83b63eaacecdac1b37f45fd74870d849d2"
-
-inherit pypi setuptools
-
-RDEPENDS_${PN} += "\
-    ${PYTHON_PN}-datetime \
-    ${PYTHON_PN}-logging \
-    "
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-parse_1.8.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-parse_1.8.4.bb
new file mode 100644
index 0000000..d31ccc7
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-parse_1.8.4.bb
@@ -0,0 +1,2 @@
+inherit setuptools
+require python-parse.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pbr_3.1.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pbr_3.1.1.bb
deleted file mode 100644
index bdff867..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pbr_3.1.1.bb
+++ /dev/null
@@ -1,16 +0,0 @@
-DESCRIPTION = "Python Build Reasonableness: PBR is a library that injects some useful and sensible default behaviors into your setuptools run"
-HOMEPAGE = "https://pypi.python.org/pypi/pbr"
-SECTION = "devel/python"
-LICENSE = "Apache-2.0"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=1dece7821bf3fd70fe1309eaa37d52a2"
-
-SRC_URI[md5sum] = "4e82c2e07af544c56a5b71c801525b00"
-SRC_URI[sha256sum] = "05f61c71aaefc02d8e37c0a3eeb9815ff526ea28b3b76324769e6158d7f95be1"
-
-inherit pypi setuptools
-
-RDEPENDS_${PN}_class-target += " \
-        python-pip \
-        "
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pbr_4.2.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pbr_4.2.0.bb
new file mode 100644
index 0000000..a4b56cd
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pbr_4.2.0.bb
@@ -0,0 +1,3 @@
+inherit setuptools
+# The inc file is in oe-core
+require recipes-devtools/python/python-pbr.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pep8_1.7.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pep8_1.7.1.bb
index b12d72d..54ce978 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pep8_1.7.1.bb
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pep8_1.7.1.bb
@@ -12,3 +12,5 @@
     python-prettytable \
     python-cmd2 \
     python-pyparsing"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-periphery.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-periphery.inc
new file mode 100644
index 0000000..539c357
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-periphery.inc
@@ -0,0 +1,7 @@
+DESCRIPTION = "A pure Python 2/3 library for peripheral I/O (GPIO, LED, PWM, SPI, I2C, MMIO, Serial) in Linux."
+HOMEPAGE = "http://pythonhosted.org/python-periphery/"
+LICENSE = "MIT"
+
+LIC_FILES_CHKSUM = "file://PKG-INFO;md5=063846af82b555d48822cf43dc6db6af"
+
+PYPI_PACKAGE = "python-periphery"
\ No newline at end of file
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-periphery_1.1.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-periphery_1.1.1.bb
new file mode 100644
index 0000000..6ae7fed
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-periphery_1.1.1.bb
@@ -0,0 +1,4 @@
+inherit pypi setuptools
+require python-periphery.inc
+
+SRC_URI[sha256sum] = "fe8f351934edce72cd919b4eb070878ebff551db5e21aea61e0f446101f0a79f"
\ No newline at end of file
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pexpect.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pexpect.inc
index fa8ad01..efeab83 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pexpect.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pexpect.inc
@@ -4,8 +4,8 @@
 LICENSE = "ISC"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=1c7a725251880af8c6a148181665385b"
 
-SRC_URI[md5sum] = "913fc0a68a915cdf6ad4250493c94cf7"
-SRC_URI[sha256sum] = "9f8eb3277716a01faafaba553d629d3d60a1a624c7cf45daa600d2148c30020c"
+SRC_URI[md5sum] = "d4f3372965a996238d57d19b95d2e03a"
+SRC_URI[sha256sum] = "2a8e88259839571d1251d278476f3eec5db26deb73a70be5ed5dc5435e418aba"
 
 UPSTREAM_CHECK_URI = "https://pypi.python.org/pypi/pexpect"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pexpect_4.5.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pexpect_4.6.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-pexpect_4.5.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-pexpect_4.6.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pint.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pint.inc
new file mode 100644
index 0000000..53f7783
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pint.inc
@@ -0,0 +1,15 @@
+DESCRIPTION = "Interval arithmetic for Python"
+HOMEPAGE = "https://github.com/AlexandreDecan/python-intervals"
+SECTION = "devel/python"
+
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/BSD-3-Clause;md5=550794465ba0ec5312d6919e203a55f9"
+
+PYPI_PACKAGE := "Pint"
+
+inherit pypi
+
+SRC_URI[md5sum] = "e1f80f3f8fc4e61f68ad3912db26b3a8"
+SRC_URI[sha256sum] = "afcf31443a478c32bbac4b00337ee9026a13d0e2ac83d30c79151462513bb0d4"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pint_0.8.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pint_0.8.1.bb
new file mode 100644
index 0000000..480f088
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pint_0.8.1.bb
@@ -0,0 +1,2 @@
+inherit setuptools
+require python-pint.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pip_18.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pip_18.0.bb
new file mode 100644
index 0000000..6b943b0
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pip_18.0.bb
@@ -0,0 +1,14 @@
+SUMMARY = "PIP is a tool for installing and managing Python packages"
+HOMEPAGE = "https://pip.pypa.io/"
+LICENSE = "MIT & LGPL-2.1"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=593c6cd9d639307226978cbcae61ad4b"
+
+SRC_URI[md5sum] = "52f75ceb21e96c258f289859a2996b60"
+SRC_URI[sha256sum] = "a0e11645ee37c90b40c46d607070c4fd583e2cd46231b1c06e389c5e814eed76"
+
+inherit pypi setuptools
+
+# Since PIP is like CPAN for PERL we need to drag in all python modules to ensure everything works
+RDEPENDS_${PN}_class-target = "python-modules python-distribute python-misc"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pip_9.0.3.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pip_9.0.3.bb
deleted file mode 100644
index e3fc6ba..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pip_9.0.3.bb
+++ /dev/null
@@ -1,14 +0,0 @@
-SUMMARY = "PIP is a tool for installing and managing Python packages"
-HOMEPAGE = "https://pip.pypa.io/"
-LICENSE = "MIT & LGPL-2.1"
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=25fba45109565f87de20bae85bc39452"
-
-SRC_URI[md5sum] = "b15b33f9aad61f88d0f8c866d16c55d8"
-SRC_URI[sha256sum] = "7bf48f9a693be1d58f49f7af7e0ae9fe29fd671cde8a55e6edca3581c4ef5796"
-
-inherit pypi setuptools
-
-# Since PIP is like CPAN for PERL we need to drag in all python modules to ensure everything works
-RDEPENDS_${PN}_class-target = "python-modules python-distribute python-misc"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-prettytable_0.7.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-prettytable_0.7.2.bb
index 6f4390e..406555a 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-prettytable_0.7.2.bb
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-prettytable_0.7.2.bb
@@ -23,3 +23,5 @@
 
 UPSTREAM_CHECK_URI = "https://pypi.python.org/pypi/PrettyTable/"
 UPSTREAM_CHECK_REGEX = "/PrettyTable/(?P<pver>(\d+[\.\-_]*)+)"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-progress.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-progress.inc
index 297c0d3..9f00615 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-progress.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-progress.inc
@@ -3,8 +3,8 @@
 LICENSE = "ISC"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=aef5566ac4fede9815eccf124c281317"
 
-SRC_URI[md5sum] = "f65ccfcc2339d522b2dd5801aaa40dc7"
-SRC_URI[sha256sum] = "c88d89ee3bd06716a0b8b5504d9c3bcb3c1c0ab98f96dc7f1dc5f56812a4f60a"
+SRC_URI[md5sum] = "057981e2f09029288f5255b1ea3ab64d"
+SRC_URI[sha256sum] = "5e2f9da88ed8236a76fffbee3ceefd259589cf42dfbc2cec2877102189fae58a"
 
 RDEPENDS_${PN}_class-target += " \
     ${PYTHON_PN}-datetime \
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-progress_1.3.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-progress_1.4.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-progress_1.3.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-progress_1.4.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-prompt-toolkit.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-prompt-toolkit.inc
index cc409a4..1a4bd35 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-prompt-toolkit.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-prompt-toolkit.inc
@@ -2,8 +2,8 @@
 LICENSE = "BSD"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=b2cde7da89f0c1f3e49bf968d00d554f"
 
-SRC_URI[md5sum] = "8fe70295006dbc8afedd43e5eba99032"
-SRC_URI[sha256sum] = "858588f1983ca497f1cf4ffde01d978a3ea02b01c8a26a8bbc5cd2e66d816917"
+SRC_URI[md5sum] = "8db8b8e40e91bc6dce133d8d5727a717"
+SRC_URI[sha256sum] = "ff58ce8bb82c11c43416dd3eec7701dcbe8c576e2d7649f1d2b9d21a2fd93808"
 
 PYPI_PACKAGE = "prompt_toolkit"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-prompt-toolkit_1.0.15.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-prompt-toolkit_2.0.4.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-prompt-toolkit_1.0.15.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-prompt-toolkit_2.0.4.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-protobuf.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-protobuf.inc
index b84983d..b617904 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-protobuf.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-protobuf.inc
@@ -7,8 +7,14 @@
 
 inherit pypi
 
-SRC_URI[md5sum] = "393a53483224cb338df5c643646c0300"
-SRC_URI[sha256sum] = "09879a295fd7234e523b62066223b128c5a8a88f682e3aff62fb115e4a0d8be0"
+SRC_URI[md5sum] = "e2daef80e70249aa1f05363670c6b3f8"
+SRC_URI[sha256sum] = "1489b376b0f364bcc6f89519718c057eb191d7ad6f1b395ffd93d1aa45587811"
+
+# http://errors.yoctoproject.org/Errors/Details/184715/
+# Can't find required file: ../src/google/protobuf/descriptor.proto
+CLEANBROKEN = "1"
+
+UPSTREAM_CHECK_REGEX = "protobuf/(?P<pver>\d+(\.\d+)+)/"
 
 RDEPENDS_${PN} += " \
     ${PYTHON_PN}-datetime \
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-protobuf_3.5.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-protobuf_3.6.1.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-protobuf_3.5.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-protobuf_3.6.1.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-psutil.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-psutil.inc
index 5d8e61f..67ae118 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-psutil.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-psutil.inc
@@ -2,8 +2,8 @@
 LICENSE = "BSD"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=0f02e99f7f3c9a7fe8ecfc5d44c2be62"
 
-SRC_URI[md5sum] = "3b291833dbea631db9d271aa602a169a"
-SRC_URI[sha256sum] = "e2467e9312c2fa191687b89ff4bc2ad8843be4af6fb4dc95a7cc5f7d7a327b18"
+SRC_URI[md5sum] = "200e073cdd56cc7a9ba9a06088569200"
+SRC_URI[sha256sum] = "686e5a35fe4c0acc25f3466c32e716f2d498aaae7b7edc03e2305b682226bcf6"
 
 PACKAGES =+ "${PN}-tests"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-psutil_5.4.3.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-psutil_5.4.6.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-psutil_5.4.3.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-psutil_5.4.6.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-ptyprocess.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-ptyprocess.inc
index 43f2d09..49cc5a4 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-ptyprocess.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-ptyprocess.inc
@@ -6,8 +6,8 @@
 
 SRCNAME = "ptyprocess"
 
-SRC_URI[md5sum] = "d3b8febae1b8c53b054bd818d0bb8665"
-SRC_URI[sha256sum] = "e64193f0047ad603b71f202332ab5527c5e52aa7c8b609704fc28c0dc20c4365"
+SRC_URI[md5sum] = "37402d69f3b50913d4d483587bffad8f"
+SRC_URI[sha256sum] = "923f299cc5ad920c68f2bc0bc98b75b9f838b93b599941a6b63ddbc2476394c0"
 
 UPSTREAM_CHECK_URI = "https://pypi.python.org/pypi/ptyprocess"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-ptyprocess_0.5.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-ptyprocess_0.6.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-ptyprocess_0.5.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-ptyprocess_0.6.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-py.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-py.inc
index c7d6727..8144523 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-py.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-py.inc
@@ -3,7 +3,8 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=a6bb0320b04a0a503f12f69fea479de9"
 
-SRC_URI[md5sum] = "279ca69c632069e1b71e11b14641ca28"
-SRC_URI[sha256sum] = "ca18943e28235417756316bfada6cd96b23ce60dd532642690dcfdaba988a76d"
+SRC_URI[md5sum] = "5ccd0cd5373c55171cf9fd61b9f19a1b"
+SRC_URI[sha256sum] = "06a30435d058473046be836d3fc4f27167fd84c45b99704f2fb5509ef61f9af1"
 
+DEPENDS += "${PYTHON_PN}-setuptools-scm-native"
 BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-py_1.5.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-py_1.6.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-py_1.5.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-py_1.6.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1-modules.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1-modules.inc
index 9fa54cf..87dbd1d 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1-modules.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1-modules.inc
@@ -4,10 +4,10 @@
  data structures (X.509, PKCS etc.)."
 HOMEPAGE = "https://github.com/etingof/pyasn1-modules"
 LICENSE = "BSD-2-Clause"
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=280606d9c18f200e03e0c247ac61475a"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=815ac3f9ca693006349094b358ab3155"
 
-SRC_URI[md5sum] = "ff938698590f314ff9b3d5c48737d899"
-SRC_URI[sha256sum] = "af00ea8f2022b6287dc375b2c70f31ab5af83989fc6fe9eacd4976ce26cd7ccc"
+SRC_URI[md5sum] = "65ce1ea1021679bffe96065baab232de"
+SRC_URI[sha256sum] = "a0cf3e1842e7c60fde97cb22d275eb6f9524f5c5250489e292529de841417547"
 
 inherit pypi
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1-modules_0.2.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1-modules_0.2.2.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1-modules_0.2.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1-modules_0.2.2.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1.inc
index f3c32e0..ab34d25 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1.inc
@@ -1,10 +1,10 @@
 SUMMARY = "Python library implementing ASN.1 types."
 HOMEPAGE = "http://pyasn1.sourceforge.net/"
 LICENSE = "BSD-2-Clause"
-LIC_FILES_CHKSUM = "file://LICENSE.rst;md5=280606d9c18f200e03e0c247ac61475a"
+LIC_FILES_CHKSUM = "file://LICENSE.rst;md5=815ac3f9ca693006349094b358ab3155"
 
-SRC_URI[md5sum] = "cb5883ddc6a9f405600429f37cf0759c"
-SRC_URI[sha256sum] = "d258b0a71994f7770599835249cece1caef3c70def868c4915e6e5ca49b67d15"
+SRC_URI[md5sum] = "0d182b71e1f72fe147d7957bc90be7f2"
+SRC_URI[sha256sum] = "f58f2a3d12fd754aa123e9fa74fb7345333000a035f3921dbdaa08597aa53137"
 
 RDEPENDS_${PN}_class-target += " \
     ${PYTHON_PN}-codecs \
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1_0.4.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1_0.4.4.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1_0.4.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-pyasn1_0.4.4.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pybind11.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pybind11.inc
index e441dc6..1722875 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pybind11.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pybind11.inc
@@ -3,5 +3,5 @@
 LICENSE = "BSD-2-Clause"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=beb87117af69fd10fbf9fb14c22a2e62"
 
-SRC_URI[md5sum] = "2c651a75a20dabbaa18a8b023ffd54c0"
-SRC_URI[sha256sum] = "cbb036a8aad59a199ad672f98813f85c672642c6a67b4ff3868b1d6abc5fae3e"
+SRC_URI[md5sum] = "5b9611041e4ea66b2b919239e3bacd65"
+SRC_URI[sha256sum] = "87ff3ae777d9326349af5272974581270b2a0909b2392dc0cc57eb28ce23bcc3"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pybind11_2.2.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pybind11_2.2.3.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-pybind11_2.2.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-pybind11_2.2.3.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pycodestyle.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pycodestyle.inc
new file mode 100644
index 0000000..c0e46b7
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pycodestyle.inc
@@ -0,0 +1,12 @@
+SUMMARY = "Python style guide checker (formly called pep8)"
+HOMEPAGE = "https://pypi.org/project/pycodestyle"
+LICENSE = "MIT"
+SECTION = "devel/python"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=01831ddbaf398471da3cc87f5037e822"
+
+SRC_URI[md5sum] = "85bbebd2c90d2f833c1db467d4d0e9a3"
+SRC_URI[sha256sum] = "cbfca99bd594a10f674d0cd97a3d802a1fdef635d4361e1a2658de47ed261e3a"
+
+inherit pypi
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pycodestyle_2.4.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pycodestyle_2.4.0.bb
new file mode 100644
index 0000000..7c736e7
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pycodestyle_2.4.0.bb
@@ -0,0 +1,4 @@
+inherit setuptools
+require python-pycodestyle.inc
+
+RDEPENDS_${PN} += "${PYTHON_PN}-lang"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyflakes_1.6.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pyflakes_1.6.0.bb
index 2444859..a16a880 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pyflakes_1.6.0.bb
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyflakes_1.6.0.bb
@@ -12,3 +12,5 @@
     ${PYTHON_PN}-prettytable \
     ${PYTHON_PN}-cmd2 \
     ${PYTHON_PN}-pyparsing"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyflame-1.6.6/0001-ptrace-Abstract-over-user_regs_struct-name-which-dif.patch b/meta-openembedded/meta-python/recipes-devtools/python/python-pyflame-1.6.6/0001-ptrace-Abstract-over-user_regs_struct-name-which-dif.patch
new file mode 100644
index 0000000..09c4394
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyflame-1.6.6/0001-ptrace-Abstract-over-user_regs_struct-name-which-dif.patch
@@ -0,0 +1,69 @@
+From 2ef124e235a47dd4742813cf80e11a89cf4f02f8 Mon Sep 17 00:00:00 2001
+From: Andrew Jeffery <andrew@aj.id.au>
+Date: Thu, 3 May 2018 12:35:31 +0930
+Subject: [PATCH] ptrace: Abstract over user_regs_struct name, which differs on
+ ARM32
+
+Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
+---
+ src/ptrace.cc |  6 +++---
+ src/ptrace.h  | 10 ++++++++--
+ 2 files changed, 11 insertions(+), 5 deletions(-)
+
+diff --git a/src/ptrace.cc b/src/ptrace.cc
+index 485f58e4d82e..610fabb3b8e8 100644
+--- a/src/ptrace.cc
++++ b/src/ptrace.cc
+@@ -122,8 +122,8 @@ void PtraceInterrupt(pid_t pid) {
+   DoWait(pid);
+ }
+ 
+-struct user_regs_struct PtraceGetRegs(pid_t pid) {
+-  struct user_regs_struct regs;
++user_regs_struct PtraceGetRegs(pid_t pid) {
++  user_regs_struct regs;
+   if (ptrace(PTRACE_GETREGS, pid, 0, &regs)) {
+     std::ostringstream ss;
+     ss << "Failed to PTRACE_GETREGS: " << strerror(errno);
+@@ -132,7 +132,7 @@ struct user_regs_struct PtraceGetRegs(pid_t pid) {
+   return regs;
+ }
+ 
+-void PtraceSetRegs(pid_t pid, struct user_regs_struct regs) {
++void PtraceSetRegs(pid_t pid, user_regs_struct regs) {
+   if (ptrace(PTRACE_SETREGS, pid, 0, &regs)) {
+     std::ostringstream ss;
+     ss << "Failed to PTRACE_SETREGS: " << strerror(errno);
+diff --git a/src/ptrace.h b/src/ptrace.h
+index 7083be1c4dfd..d6af8bf9f83a 100644
+--- a/src/ptrace.h
++++ b/src/ptrace.h
+@@ -23,6 +23,12 @@
+ 
+ #include "./config.h"
+ 
++#if defined(__arm__)
++typedef struct user_regs user_regs_struct;
++#else
++typedef struct user_regs_struct user_regs_struct;
++#endif
++
+ namespace pyflame {
+ 
+ int DoWait(pid_t pid, int options = 0);
+@@ -39,10 +45,10 @@ void PtraceSeize(pid_t pid);
+ void PtraceInterrupt(pid_t pid);
+ 
+ // get regs from a process
+-struct user_regs_struct PtraceGetRegs(pid_t pid);
++user_regs_struct PtraceGetRegs(pid_t pid);
+ 
+ // set regs in a process
+-void PtraceSetRegs(pid_t pid, struct user_regs_struct regs);
++void PtraceSetRegs(pid_t pid, user_regs_struct regs);
+ 
+ // poke a long word into an address
+ void PtracePoke(pid_t pid, unsigned long addr, long data);
+-- 
+2.14.1
+
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyflame-1.6.6/0001-symbol-Account-for-prelinked-shared-objects.patch b/meta-openembedded/meta-python/recipes-devtools/python/python-pyflame-1.6.6/0001-symbol-Account-for-prelinked-shared-objects.patch
new file mode 100644
index 0000000..3eefc9c
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyflame-1.6.6/0001-symbol-Account-for-prelinked-shared-objects.patch
@@ -0,0 +1,134 @@
+From 007965d341349679607699d005c4af811b2c419a Mon Sep 17 00:00:00 2001
+From: Andrew Jeffery <andrew@aj.id.au>
+Date: Fri, 4 May 2018 11:23:53 +0930
+Subject: [PATCH] symbol: Account for prelinked shared objects
+
+Some projects, such as those derived from Yocto, tend to prelink their
+binaries and libraries to reduce runtime overhead. Currently this trips
+up pyflame in its symbol address calculations, and leads to ptrace
+failures due to spurious addresses:
+
+   $ pyflame -t python -c "print 'foo'"
+   Unexpected ptrace(2) exception: Failed to PTRACE_PEEKDATA (pid 1482, addr 0x9f9b1d70): Input/output error
+   Unexpected ptrace(2) exception: Failed to PTRACE_PEEKDATA (pid 1482, addr 0x9f9b1d70): Input/output error
+   Unexpected ptrace(2) exception: Failed to PTRACE_PEEKDATA (pid 1482, addr 0x9f9b1d70): Input/output error
+   Unexpected ptrace(2) exception: Failed to PTRACE_PEEKDATA (pid 1482, addr 0x9f9b1d70): Input/output error
+   Unexpected ptrace(2) exception: Failed to PTRACE_PEEKDATA (pid 1482, addr 0x9f9b1d70): Input/output error
+   ...
+
+Add support for reading a prelinked base p_vaddr out of the ELF and
+adjust the PyAddresses values accordingly.
+
+Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
+---
+ src/symbol.cc | 15 +++++++++++++++
+ src/symbol.h  | 29 ++++++++++++++++++++++++++++-
+ 2 files changed, 43 insertions(+), 1 deletion(-)
+
+diff --git a/src/symbol.cc b/src/symbol.cc
+index 125174efeeb5..39c3e8132dd1 100644
+--- a/src/symbol.cc
++++ b/src/symbol.cc
+@@ -166,6 +166,17 @@ PyABI ELF::WalkTable(int sym, int str, PyAddresses *addrs) {
+   return abi;
+ }
+ 
++addr_t ELF::GetBaseAddress() {
++  int32_t phnum = hdr()->e_phnum;
++  int32_t i;
++  for (i = 0; i < phnum && phdr(i)->p_type != PT_LOAD; i++) {
++  }
++  if (i == phnum) {
++    throw FatalException("Failed to find PT_LOAD entry in program headers");
++  }
++  return phdr(i)->p_vaddr;
++}
++
+ PyAddresses ELF::GetAddresses(PyABI *abi) {
+   PyAddresses addrs;
+   PyABI detected_abi = WalkTable(dynsym_, dynstr_, &addrs);
+@@ -176,6 +187,10 @@ PyAddresses ELF::GetAddresses(PyABI *abi) {
+   if (abi != nullptr) {
+     *abi = detected_abi;
+   }
++  // Handle prelinked shared objects
++  if (hdr()->e_type == ET_DYN) {
++    return addrs - GetBaseAddress();
++  }
+   return addrs;
+ }
+ }  // namespace pyflame
+diff --git a/src/symbol.h b/src/symbol.h
+index 124853bcc1c1..bb92b9a2604b 100644
+--- a/src/symbol.h
++++ b/src/symbol.h
+@@ -28,15 +28,19 @@
+ 
+ #if USE_ELF64
+ #define ehdr_t Elf64_Ehdr
++#define phdr_t Elf64_Phdr
+ #define shdr_t Elf64_Shdr
+ #define dyn_t Elf64_Dyn
+ #define sym_t Elf64_Sym
++#define addr_t Elf64_Addr
+ #define ARCH_ELFCLASS ELFCLASS64
+ #else
+ #define ehdr_t Elf32_Ehdr
++#define phdr_t Elf32_Phdr
+ #define shdr_t Elf32_Shdr
+ #define dyn_t Elf32_Dyn
+ #define sym_t Elf32_Sym
++#define addr_t Elf32_Addr
+ #define ARCH_ELFCLASS ELFCLASS32
+ #endif
+ 
+@@ -67,8 +71,18 @@ struct PyAddresses {
+         interp_head_hint(0),
+         pie(false) {}
+ 
++  PyAddresses operator-(const unsigned long base) const {
++    PyAddresses res(*this);
++    res.tstate_addr = this->tstate_addr == 0 ? 0 : this->tstate_addr - base;
++    res.interp_head_addr =
++        this->interp_head_addr == 0 ? 0 : this->interp_head_addr - base;
++    res.interp_head_fn_addr =
++        this->interp_head_fn_addr == 0 ? 0 : this->interp_head_fn_addr - base;
++    return res;
++  }
++
+   PyAddresses operator+(const unsigned long base) const {
+-    PyAddresses res;
++    PyAddresses res(*this);
+     res.tstate_addr = this->tstate_addr == 0 ? 0 : this->tstate_addr + base;
+     res.interp_head_addr =
+         this->interp_head_addr == 0 ? 0 : this->interp_head_addr + base;
+@@ -113,6 +127,9 @@ class ELF {
+   // ABI.
+   PyAddresses GetAddresses(PyABI *abi);
+ 
++  // Extract the base load address from the Program Header table
++  addr_t GetBaseAddress();
++
+  private:
+   void *addr_;
+   size_t length_;
+@@ -122,6 +139,16 @@ class ELF {
+     return reinterpret_cast<const ehdr_t *>(addr_);
+   }
+ 
++  inline const phdr_t *phdr(int idx) const {
++    if (idx < 0) {
++      std::ostringstream ss;
++      ss << "Illegal phdr index: " << idx;
++      throw FatalException(ss.str());
++    }
++    return reinterpret_cast<const phdr_t *>(p() + hdr()->e_phoff +
++                                            idx * hdr()->e_phentsize);
++  }
++
+   inline const shdr_t *shdr(int idx) const {
+     if (idx < 0) {
+       std::ostringstream ss;
+-- 
+2.14.1
+
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyflame.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pyflame.inc
new file mode 100644
index 0000000..340aab7
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyflame.inc
@@ -0,0 +1,15 @@
+SUMMARY = "Pyflame: A Ptracing Profiler For Python"
+HOMEPAGE = "https://github.com/uber/pyflame"
+SECTION = "devel/python"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://${S}/LICENSE;md5=2ee41112a44fe7014dce33e26468ba93"
+DEPENDS = "python"
+
+SRC_URI = "git://github.com/uber/pyflame.git;protocol=https"
+S = "${WORKDIR}/git"
+
+inherit pkgconfig autotools
+
+COMPATIBLE_HOST_libc-musl_class-target = "null"
+COMPATIBLE_HOST_mipsarch_class-target = "null"
+COMPATIBLE_HOST_aarch64_class-target = "null"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyflame_1.6.6.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pyflame_1.6.6.bb
new file mode 100644
index 0000000..8dedb89
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyflame_1.6.6.bb
@@ -0,0 +1,6 @@
+require python-pyflame.inc
+
+# v1.6.6
+SRCREV = "8a9d8c2acc3b3bb027475b738134f1e6fff14e6c"
+SRC_URI += "file://0001-ptrace-Abstract-over-user_regs_struct-name-which-dif.patch"
+SRC_URI += "file://0001-symbol-Account-for-prelinked-shared-objects.patch"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyiface.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pyiface.inc
index 620b244..2e398fc 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pyiface.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyiface.inc
@@ -5,7 +5,7 @@
 
 LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=4fe869ee987a340198fb0d54c55c47f1"
 
-SRC_URI[md5sum] = "06c3c71fe51df740dae6a88a13afb5e0"
-SRC_URI[sha256sum] = "4bb79100cbcf7344a1ccaddc578cd6455da47d8eac6eb1bf903ec32e043af924"
+SRC_URI[md5sum] = "b066aa984656742738127c9c75436ab4"
+SRC_URI[sha256sum] = "e231e5735d329c5b2d4fc8854f069fdaa5436d3ef91ed64ee49e41e3f5e8a3f5"
 
 inherit pypi
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyiface_0.0.5.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pyiface_0.0.11.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-pyiface_0.0.5.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-pyiface_0.0.11.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyjwt.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pyjwt.inc
index 9f9282e..00c38e3 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pyjwt.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyjwt.inc
@@ -6,8 +6,8 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=68626705a7b513ca8d5f44a3e200ed0c"
 
-SRC_URI[md5sum] = "f7dbe0d62f2087a7605946aeeca02541"
-SRC_URI[sha256sum] = "dacba5786fe3bf1a0ae8673874e29f9ac497860955c501289c63b15d3daae63a"
+SRC_URI[md5sum] = "2731c6b66b67b95d1944f072f5fa35a9"
+SRC_URI[sha256sum] = "4ee413b357d53fd3fb44704577afac88e72e878716116270d722723d65b42176"
 
 PYPI_PACKAGE = "PyJWT"
 inherit pypi
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyjwt_1.6.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pyjwt_1.6.4.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-pyjwt_1.6.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-pyjwt_1.6.4.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pymisp.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pymisp.inc
index 7765cc5..468a801 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pymisp.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pymisp.inc
@@ -3,8 +3,8 @@
 LICENSE = "BSD-2-Clause"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=a3639cf5780f71b125d3e9d1dc127c20"
 
-SRC_URI[md5sum] = "d4fee2abb2d7468010b7fe9ebc68b0cb"
-SRC_URI[sha256sum] = "304fbd8862dfde27d767c093de87fec42fc63c70d8393643d1a3b4f765aae78f"
+SRC_URI[md5sum] = "6d549b36cbfa8c1a3323c5d6e299789e"
+SRC_URI[sha256sum] = "f4ed2000cbe1a314f1f88fd8a8eba4ad05974b351b96f1235c6e532158a39fe0"
 
 RDEPENDS_${PN} += " \
     ${PYTHON_PN}-dateutil \
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pymisp_2.4.89.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pymisp_2.4.93.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-pymisp_2.4.89.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-pymisp_2.4.93.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pymongo.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pymongo.inc
index baf3dd5..b5277f1 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pymongo.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pymongo.inc
@@ -8,8 +8,8 @@
 LICENSE = "Apache-2.0"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=86d3f3a95c324c9479bd8986968f4327"
 
-SRC_URI[md5sum] = "0d72c87fb93cea0759529befafefce54"
-SRC_URI[sha256sum] = "f7ebcb846962ee40374db2d9014a89bea9c983ae63c1877957c3a0a756974796"
+SRC_URI[md5sum] = "7449c81a6c32c3c8cb9bebebc848fded"
+SRC_URI[sha256sum] = "f14fb6c4058772a0d74d82874d3b89d7264d89b4ed7fa0413ea0ef8112b268b9"
 
 PACKAGES =+ "${PYTHON_PN}-bson"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pymongo_3.6.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pymongo_3.7.1.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-pymongo_3.6.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-pymongo_3.7.1.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyopenssl.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pyopenssl.inc
index 7722e8e..516e795 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pyopenssl.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyopenssl.inc
@@ -5,8 +5,8 @@
 
 DEPENDS += "openssl ${PYTHON_PN}-cryptography"
 
-SRC_URI[md5sum] = "d9c5134db8bf3183573b7840954cac94"
-SRC_URI[sha256sum] = "2c10cfba46a52c0b0950118981d61e72c1e5b1aac451ca1bc77de1a679456773"
+SRC_URI[md5sum] = "c92e9c85b520b7e153fef0f7f3c5dda7"
+SRC_URI[sha256sum] = "6488f1423b00f73b7ad5167885312bb0ce410d3312eb212393795b53c8caa580"
 
 PYPI_PACKAGE = "pyOpenSSL"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyopenssl_17.5.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pyopenssl_18.0.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-pyopenssl_17.5.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-pyopenssl_18.0.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyperclip.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pyperclip.inc
index e05de67..4ee47ee 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pyperclip.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyperclip.inc
@@ -1,12 +1,14 @@
 DESCRIPTION = "A cross-platform clipboard module for Python. (only handles plain text for now)"
 LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://PKG-INFO;md5=1ed92115c8f96b19ec34ed09df586e51"
+LIC_FILES_CHKSUM = "file://PKG-INFO;md5=4a3129a2c1b8bdc0e2895a1ec0e2dae2"
 
-SRC_URI[md5sum] = "d2f6a3129cd6f2518b52bb0b8deeeda7"
-SRC_URI[sha256sum] = "ce829433a9af640e08ee89b20f7c62132714bcc5d77df114044d0fccb8c3b3b8"
+SRC_URI[md5sum] = "3680607974f99d6e4411b102358b1884"
+SRC_URI[sha256sum] = "43496f0a1f363a5ecfc4cda5eba6a2a3d5056fe6c7ffb9a99fbb1c5a3c7dea05"
 
 inherit pypi
 
 RDEPENDS_${PN} += " \
     ${PYTHON_PN}-ctypes \
 "
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyperclip_1.6.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pyperclip_1.6.2.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-pyperclip_1.6.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-pyperclip_1.6.2.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyroute2.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pyroute2.inc
index 9ec9866..ed1981e 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pyroute2.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyroute2.inc
@@ -3,8 +3,8 @@
 LIC_FILES_CHKSUM = "file://LICENSE.GPL.v2;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
                     file://LICENSE.Apache.v2;md5=34281e312165f843a2b7d1f114fe65ce"
 
-SRC_URI[md5sum] = "9c251543c4282a2f8b1a8d6aa8afc688"
-SRC_URI[sha256sum] = "7afad28ee0a0f3e7c34adaa9f953d00560ed9910203e93f107833b6e8d151171"
+SRC_URI[md5sum] = "2f6f951e94356ae9d224f417dc6ebed2"
+SRC_URI[sha256sum] = "42bf74495d95a0196a74dd171357f660175aba2bfc23f9b5f63e3830ccbef9ac"
 
 FILESEXTRAPATHS_prepend := "${THISDIR}/python-pyroute2:"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyroute2_0.4.21.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pyroute2_0.5.2.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-pyroute2_0.4.21.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-pyroute2_0.5.2.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-helpers-namespace.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-helpers-namespace.inc
new file mode 100644
index 0000000..a69867d
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-helpers-namespace.inc
@@ -0,0 +1,10 @@
+DESCRIPTION = "This plugin does not provide any helpers to pytest, it does, however, provide a helpers namespace in pytest which enables you to register helper functions in your conftest.py to be used within your tests without having to import them."
+HOMEPAGE = "https://github.com/saltstack/pytest-helpers-namespace"
+SECTION = "devel/python"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://PKG-INFO;md5=71fac4dfeee99c39c51f617e9486237c"
+
+SRC_URI[md5sum] = "80fe3e515f640b1459709b539f6b857e"
+SRC_URI[sha256sum] = "d8bdb017c0f7271699c08850b6b12e1ce9e52913cbd4461b5febd21082a29113"
+
+inherit pypi
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-helpers-namespace_2016.7.10.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-helpers-namespace_2016.7.10.bb
new file mode 100644
index 0000000..2b6ee85
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-helpers-namespace_2016.7.10.bb
@@ -0,0 +1,7 @@
+require python-pytest-helpers-namespace.inc
+
+inherit setuptools
+
+RDEPENDS_${PN} += " \
+    python-pytest \
+    "
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-runner.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-runner.inc
index 7546743..3b057b0 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-runner.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-runner.inc
@@ -2,8 +2,8 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=a33f38bbf47d48c70fe0d40e5f77498e"
 
-SRC_URI[md5sum] = "8f8363a52bbabc4cedd5e239beb2ba11"
-SRC_URI[sha256sum] = "0f7c3a3cf5aead13f54baaa01ceb49e5ae92aba5d3ff1928e81e189c40bc6703"
+SRC_URI[md5sum] = "4b696b0f35767f0694f183d0a1855300"
+SRC_URI[sha256sum] = "d23f117be39919f00dd91bffeb4f15e031ec797501b717a245e377aee0f577be"
 
 inherit pypi
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-runner_3.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-runner_4.2.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-pytest-runner_3.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-pytest-runner_4.2.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-tempdir.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-tempdir.inc
new file mode 100644
index 0000000..196f6d6
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-tempdir.inc
@@ -0,0 +1,10 @@
+DESCRIPTION = "Adds support for a predictable and repeatable temporary directory."
+HOMEPAGE = "https://github.com/saltstack/pytest-tempdir"
+SECTION = "devel/python"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://PKG-INFO;md5=8751a9cf4a70be4f02697a9b89e686ce"
+
+SRC_URI[md5sum] = "f87f2583f5f8aaca7203d57ada3948b5"
+SRC_URI[sha256sum] = "65ff815966ea6dfc07ca1b43747c9888a6d883971170e67b16290f9f50d434ea"
+
+inherit pypi
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-tempdir_2016.8.20.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-tempdir_2016.8.20.bb
new file mode 100644
index 0000000..8a9b83e
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pytest-tempdir_2016.8.20.bb
@@ -0,0 +1,7 @@
+require python-pytest-tempdir.inc
+
+inherit setuptools
+
+RDEPENDS_${PN} += " \
+    python-pytest \
+    "
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pytz.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pytz.inc
index 519487f..aedffe1 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pytz.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pytz.inc
@@ -5,8 +5,8 @@
 
 inherit pypi
 
-SRC_URI[md5sum] = "f054437920c895dd14a4509fabafe029"
-SRC_URI[sha256sum] = "c06425302f2cf668f1bba7a0a03f3c1d34d4ebeef2c72003da308b3947c7f749"
+SRC_URI[md5sum] = "45409cbfa3927bdd2f3ee914dd5b1060"
+SRC_URI[sha256sum] = "ffb9ef1de172603304d9d2819af6f5ece76f2e85ec10692a524dd876e72bf277"
 
 RDEPENDS_${PN}_class-target += "\
     ${PYTHON_PN}-datetime \
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pytz_2018.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pytz_2018.5.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-pytz_2018.4.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-pytz_2018.5.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyudev.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pyudev.inc
index cb906c9..683a75c 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pyudev.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyudev.inc
@@ -15,4 +15,5 @@
     ${PYTHON_PN}-misc \
     ${PYTHON_PN}-six \
     ${PYTHON_PN}-threading \
+    libudev \
 "
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyyaml.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pyyaml.inc
index 3fef0ca..afce543 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pyyaml.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyyaml.inc
@@ -2,14 +2,14 @@
 HOMEPAGE = "http://www.pyyaml.org"
 SECTION = "devel/python"
 LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=6015f088759b10e0bc2bf64898d4ae17"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=5591701d32590f9fa94f3bfee820b634"
 DEPENDS = "libyaml ${PYTHON_PN}-cython-native ${PYTHON_PN}"
 
 PYPI_PACKAGE = "PyYAML"
 inherit pypi
 
-SRC_URI[md5sum] = "4c129761b661d181ebf7ff4eb2d79950"
-SRC_URI[sha256sum] = "592766c6303207a20efc445587778322d7f73b161bd994f227adaa341ba212ab"
+SRC_URI[md5sum] = "b78b96636d68ac581c0e2f38158c224f"
+SRC_URI[sha256sum] = "3ef3092145e9b70e3ddd2c7ad59bdd0252a94dfe3949721633e41344de00a6bf"
 
 RDEPENDS_${PN} += "\
     ${PYTHON_PN}-datetime \
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyyaml_3.12.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pyyaml_3.13.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-pyyaml_3.12.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-pyyaml_3.13.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyzmq.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-pyzmq.inc
new file mode 100644
index 0000000..2447c2f
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyzmq.inc
@@ -0,0 +1,27 @@
+SUMMARY = "Pyzmq provides Zero message queue access for the Python language"
+HOMEPAGE = "http://zeromq.org/bindings:python"
+LICENSE = "BSD & LGPL-3.0"
+LIC_FILES_CHKSUM = "file://COPYING.BSD;md5=11c65680f637c3df7f58bbc8d133e96e \
+                    file://COPYING.LESSER;md5=12c592fa0bcfff3fb0977b066e9cb69e"
+DEPENDS = "zeromq"
+
+FILESEXTRAPATHS_prepend := "${THISDIR}/python-pyzmq:"
+
+SRC_URI += "file://club-rpath-out.patch"
+SRC_URI[md5sum] = "aecdfc328193fbd81f6dc23228319943"
+SRC_URI[sha256sum] = "2199f753a230e26aec5238b0518b036780708a4c887d4944519681a920b9dee4"
+
+inherit pypi pkgconfig
+
+RDEPENDS_${PN} += "${PYTHON_PN}-multiprocessing"
+
+FILES_${PN}-dbg =+ "${PYTHON_SITEPACKAGES_DIR}/zmq/backend/cython/.debug"
+
+do_compile_prepend() {
+    echo [global] > ${S}/setup.cfg
+    echo zmq_prefix = ${STAGING_DIR_HOST} >> ${S}/setup.cfg
+    echo have_sys_un_h = True >> ${S}/setup.cfg
+    echo skip_check_zmq = True >> ${S}/setup.cfg
+    echo libzmq_extension = False >> ${S}/setup.cfg
+    echo no_libzmq_extension = True >> ${S}/setup.cfg
+}
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyzmq/club-rpath-out.patch b/meta-openembedded/meta-python/recipes-devtools/python/python-pyzmq/club-rpath-out.patch
index 2dc3b73..936f165 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pyzmq/club-rpath-out.patch
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyzmq/club-rpath-out.patch
@@ -1,26 +1,13 @@
 diff --git a/setup.py b/setup.py
-index 62df445..1fdbdeb 100755
+index d243eaa..98099bc 100755
 --- a/setup.py
 +++ b/setup.py
-@@ -213,12 +213,6 @@ def settings_from_prefix(prefix=None, bundle_libzmq_dylib=False):
-                 pass
-                 # unused rpath args for OS X:
-                 # settings['extra_link_args'] = ['-Wl,-rpath','-Wl,$ORIGIN/..']
--            else:
--                settings['runtime_library_dirs'] += ['$ORIGIN/..']
--        elif sys.platform != 'darwin':
--            settings['runtime_library_dirs'] += [
--                os.path.abspath(x) for x in settings['library_dirs']
--            ]
-     
-     return settings
+@@ -192,8 +192,6 @@ def _add_rpath(settings, path):
+     """
+     if sys.platform == 'darwin':
+         settings['extra_link_args'].extend(['-Wl,-rpath','-Wl,%s' % path])
+-    else:
+-        settings['runtime_library_dirs'].append(path)
  
-@@ -592,8 +586,6 @@ class Configure(build_ext):
-                 pass
-                 # unused rpath args for OS X:
-                 # settings['extra_link_args'] = ['-Wl,-rpath','-Wl,$ORIGIN/../zmq']
--            else:
--                settings['runtime_library_dirs'] = [ os.path.abspath(pjoin('.', 'zmq')) ]
-         
-         line()
-         info("Configure: Autodetecting ZMQ settings...")
+ def settings_from_prefix(prefix=None, bundle_libzmq_dylib=False):
+     """load appropriate library/include settings from ZMQ prefix"""
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyzmq_14.7.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pyzmq_14.7.0.bb
deleted file mode 100644
index b5baf82..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-pyzmq_14.7.0.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-SUMMARY = "Pyzmq provides Zero message queue access for the Python language"
-HOMEPAGE = "http://zeromq.org/bindings:python"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING.BSD;md5=11c65680f637c3df7f58bbc8d133e96e"
-DEPENDS = "zeromq"
-
-SRC_URI = "file://club-rpath-out.patch"
-SRC_URI[md5sum] = "87e3abb33af5794db5ae85c667bbf324"
-SRC_URI[sha256sum] = "77994f80360488e7153e64e5959dc5471531d1648e3a4bff14a714d074a38cc2"
-
-inherit pypi setuptools pkgconfig
-
-RDEPENDS_${PN} += "python-multiprocessing"
-
-FILES_${PN}-dbg =+ "${PYTHON_SITEPACKAGES_DIR}/zmq/backend/cython/.debug"
-
-do_compile_prepend() {
-    echo [global] > ${S}/setup.cfg
-    echo zmq_prefix = ${STAGING_DIR_HOST} >> ${S}/setup.cfg
-    echo have_sys_un_h = True >> ${S}/setup.cfg
-    echo skip_check_zmq = True >> ${S}/setup.cfg
-    echo libzmq_extension = False >> ${S}/setup.cfg
-    echo no_libzmq_extension = True >> ${S}/setup.cfg
-}
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyzmq_17.1.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-pyzmq_17.1.0.bb
new file mode 100644
index 0000000..b690106
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyzmq_17.1.0.bb
@@ -0,0 +1,2 @@
+require python-pyzmq.inc
+inherit setuptools
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-requests.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-requests.inc
index 5d6dca5..301c2f8 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-requests.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-requests.inc
@@ -1,10 +1,16 @@
 DESCRIPTION = "Python HTTP for Humans."
 HOMEPAGE = "http://python-requests.org"
 LICENSE = "Apache-2.0"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=979d6a23b143e13ea0e5e3aa81248820"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=bfbeafb85a2cee261510d65d5ec19156"
 
-SRC_URI[md5sum] = "081412b2ef79bdc48229891af13f4d82"
-SRC_URI[sha256sum] = "9c443e7324ba5b85070c4a818ade28bfabedf16ea10206da1132edaa6dda237e"
+FILESEXTRAPATHS_prepend := "${THISDIR}/python-requests:"
+
+SRC_URI += "file://0001-Strip-Authorization-header-whenever-root-URL-changes.patch \
+            file://0002-Rework-authorization-stripping-logic-as-discussed.patch \
+            "
+
+SRC_URI[md5sum] = "6c1a31afec9d614e2e71a91ee6ca2878"
+SRC_URI[sha256sum] = "ec22d826a36ed72a7358ff3fe56cbd4ba69dd7a6718ffd450ff0e9df7a47ce6a"
 
 inherit pypi
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-requests/0001-Strip-Authorization-header-whenever-root-URL-changes.patch b/meta-openembedded/meta-python/recipes-devtools/python/python-requests/0001-Strip-Authorization-header-whenever-root-URL-changes.patch
new file mode 100644
index 0000000..80ef5ff
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-requests/0001-Strip-Authorization-header-whenever-root-URL-changes.patch
@@ -0,0 +1,62 @@
+From fb0d391138df48e93c44a2087ea796cca5e229c0 Mon Sep 17 00:00:00 2001
+From: Bruce Merry <bmerry@ska.ac.za>
+Date: Thu, 28 Jun 2018 16:38:42 +0200
+Subject: [PATCH 1/2] Strip Authorization header whenever root URL changes
+
+Previously the header was stripped only if the hostname changed, but in
+an https -> http redirect that can leak the credentials on the wire
+(#4716). Based on with RFC 7235 section 2.2, the header is now stripped
+if the "canonical root URL" (scheme+authority) has changed, by checking
+scheme, hostname and port.
+
+Upstream-Status: Backport
+
+Fix CVE-2018-18074
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ requests/sessions.py   |  4 +++-
+ tests/test_requests.py | 12 +++++++++++-
+ 2 files changed, 14 insertions(+), 2 deletions(-)
+
+diff --git a/requests/sessions.py b/requests/sessions.py
+index ba13526..2969d83 100644
+--- a/requests/sessions.py
++++ b/requests/sessions.py
+@@ -242,7 +242,9 @@ class SessionRedirectMixin(object):
+             original_parsed = urlparse(response.request.url)
+             redirect_parsed = urlparse(url)
+ 
+-            if (original_parsed.hostname != redirect_parsed.hostname):
++            if (original_parsed.hostname != redirect_parsed.hostname
++                    or original_parsed.port != redirect_parsed.port
++                    or original_parsed.scheme != redirect_parsed.scheme):
+                 del headers['Authorization']
+ 
+         # .netrc might have more auth for us on our new host.
+diff --git a/tests/test_requests.py b/tests/test_requests.py
+index fcddb1d..e0e801a 100644
+--- a/tests/test_requests.py
++++ b/tests/test_requests.py
+@@ -1575,7 +1575,17 @@ class TestRequests:
+             auth=('user', 'pass'),
+         )
+         assert r.history[0].request.headers['Authorization']
+-        assert not r.request.headers.get('Authorization', '')
++        assert 'Authorization' not in r.request.headers
++
++    def test_auth_is_stripped_on_scheme_redirect(self, httpbin, httpbin_secure, httpbin_ca_bundle):
++        r = requests.get(
++            httpbin_secure('redirect-to'),
++            params={'url': httpbin('get')},
++            auth=('user', 'pass'),
++            verify=httpbin_ca_bundle
++        )
++        assert r.history[0].request.headers['Authorization']
++        assert 'Authorization' not in r.request.headers
+ 
+     def test_auth_is_retained_for_redirect_on_host(self, httpbin):
+         r = requests.get(httpbin('redirect/1'), auth=('user', 'pass'))
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-requests/0002-Rework-authorization-stripping-logic-as-discussed.patch b/meta-openembedded/meta-python/recipes-devtools/python/python-requests/0002-Rework-authorization-stripping-logic-as-discussed.patch
new file mode 100644
index 0000000..ef069fb
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-requests/0002-Rework-authorization-stripping-logic-as-discussed.patch
@@ -0,0 +1,118 @@
+From 698c2fa850bfc8b3bdb768e1c1cd6d57e643811d Mon Sep 17 00:00:00 2001
+From: Bruce Merry <bmerry@ska.ac.za>
+Date: Tue, 14 Aug 2018 13:30:43 +0200
+Subject: [PATCH 2/2] Rework authorization stripping logic as discussed
+
+The exception for http->https upgrade now requires the standard HTTP(S)
+ports to be used, either implicitly (no port specified) or explicitly.
+
+Upstream-Status: Backport
+
+Follow-up fix for CVE-2018-18074
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ requests/sessions.py   | 26 ++++++++++++++++++--------
+ tests/test_requests.py | 33 ++++++++++++++++++++++-----------
+ 2 files changed, 40 insertions(+), 19 deletions(-)
+
+diff --git a/requests/sessions.py b/requests/sessions.py
+index 2969d83..c11a3a2 100644
+--- a/requests/sessions.py
++++ b/requests/sessions.py
+@@ -115,6 +115,22 @@ class SessionRedirectMixin(object):
+             return to_native_string(location, 'utf8')
+         return None
+ 
++    def should_strip_auth(self, old_url, new_url):
++        """Decide whether Authorization header should be removed when redirecting"""
++        old_parsed = urlparse(old_url)
++        new_parsed = urlparse(new_url)
++        if old_parsed.hostname != new_parsed.hostname:
++            return True
++        # Special case: allow http -> https redirect when using the standard
++        # ports. This isn't specified by RFC 7235, but is kept to avoid
++        # breaking backwards compatibility with older versions of requests
++        # that allowed any redirects on the same host.
++        if (old_parsed.scheme == 'http' and old_parsed.port in (80, None)
++                and new_parsed.scheme == 'https' and new_parsed.port in (443, None)):
++            return False
++        # Standard case: root URI must match
++        return old_parsed.port != new_parsed.port or old_parsed.scheme != new_parsed.scheme
++
+     def resolve_redirects(self, resp, req, stream=False, timeout=None,
+                           verify=True, cert=None, proxies=None, yield_requests=False, **adapter_kwargs):
+         """Receives a Response. Returns a generator of Responses or Requests."""
+@@ -236,16 +252,10 @@ class SessionRedirectMixin(object):
+         headers = prepared_request.headers
+         url = prepared_request.url
+ 
+-        if 'Authorization' in headers:
++        if 'Authorization' in headers and self.should_strip_auth(response.request.url, url):
+             # If we get redirected to a new host, we should strip out any
+             # authentication headers.
+-            original_parsed = urlparse(response.request.url)
+-            redirect_parsed = urlparse(url)
+-
+-            if (original_parsed.hostname != redirect_parsed.hostname
+-                    or original_parsed.port != redirect_parsed.port
+-                    or original_parsed.scheme != redirect_parsed.scheme):
+-                del headers['Authorization']
++            del headers['Authorization']
+ 
+         # .netrc might have more auth for us on our new host.
+         new_auth = get_netrc_auth(url) if self.trust_env else None
+diff --git a/tests/test_requests.py b/tests/test_requests.py
+index e0e801a..148067b 100644
+--- a/tests/test_requests.py
++++ b/tests/test_requests.py
+@@ -1567,17 +1567,7 @@ class TestRequests:
+             preq = req.prepare()
+             assert test_url == preq.url
+ 
+-    @pytest.mark.xfail(raises=ConnectionError)
+-    def test_auth_is_stripped_on_redirect_off_host(self, httpbin):
+-        r = requests.get(
+-            httpbin('redirect-to'),
+-            params={'url': 'http://www.google.co.uk'},
+-            auth=('user', 'pass'),
+-        )
+-        assert r.history[0].request.headers['Authorization']
+-        assert 'Authorization' not in r.request.headers
+-
+-    def test_auth_is_stripped_on_scheme_redirect(self, httpbin, httpbin_secure, httpbin_ca_bundle):
++    def test_auth_is_stripped_on_http_downgrade(self, httpbin, httpbin_secure, httpbin_ca_bundle):
+         r = requests.get(
+             httpbin_secure('redirect-to'),
+             params={'url': httpbin('get')},
+@@ -1594,6 +1584,27 @@ class TestRequests:
+ 
+         assert h1 == h2
+ 
++    def test_should_strip_auth_host_change(self):
++        s = requests.Session()
++        assert s.should_strip_auth('http://example.com/foo', 'http://another.example.com/')
++
++    def test_should_strip_auth_http_downgrade(self):
++        s = requests.Session()
++        assert s.should_strip_auth('https://example.com/foo', 'http://example.com/bar')
++
++    def test_should_strip_auth_https_upgrade(self):
++        s = requests.Session()
++        assert not s.should_strip_auth('http://example.com/foo', 'https://example.com/bar')
++        assert not s.should_strip_auth('http://example.com:80/foo', 'https://example.com/bar')
++        assert not s.should_strip_auth('http://example.com/foo', 'https://example.com:443/bar')
++        # Non-standard ports should trigger stripping
++        assert s.should_strip_auth('http://example.com:8080/foo', 'https://example.com/bar')
++        assert s.should_strip_auth('http://example.com/foo', 'https://example.com:8443/bar')
++
++    def test_should_strip_auth_port_change(self):
++        s = requests.Session()
++        assert s.should_strip_auth('http://example.com:1234/foo', 'https://example.com:4321/bar')
++
+     def test_manual_redirect_with_partial_body_read(self, httpbin):
+         s = requests.Session()
+         r1 = s.get(httpbin('redirect/2'), allow_redirects=False, stream=True)
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-requests_2.18.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-requests_2.19.1.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-requests_2.18.4.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-requests_2.19.1.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-robotframework-seriallibrary.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-robotframework-seriallibrary.inc
new file mode 100644
index 0000000..9f07b65
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-robotframework-seriallibrary.inc
@@ -0,0 +1,15 @@
+SUMMARY = "Robot Framework test library for serial connection"
+HOMEPAGE = "https://github.com/whosaysni/robotframework-seriallibrary"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10"
+
+SRC_URI[md5sum] = "b7c9565d54c30df7cd3f3c0e29adffa3"
+SRC_URI[sha256sum] = "256ad60fc0b7df4be44d82c302f5ed8fad4935cda99e4b45942e3c88179d1e19"
+
+SRC_URI = "https://files.pythonhosted.org/packages/ce/e1/1e337dc84a20b9d92d7b243d16bb9f6fc0084967eca7454228bb546efec7/robotframework-seriallibrary-0.3.1.tar.gz"
+RDEPENDS_${PN} += " \
+    ${PYTHON_PN}-pyserial \
+    ${PYTHON_PN}-robotframework \
+"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-robotframework-seriallibrary_0.3.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-robotframework-seriallibrary_0.3.1.bb
new file mode 100644
index 0000000..440f69c
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-robotframework-seriallibrary_0.3.1.bb
@@ -0,0 +1,2 @@
+inherit pypi setuptools
+require python-robotframework-seriallibrary.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-robotframework.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-robotframework.inc
index 78bbbc6..e920c51 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-robotframework.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-robotframework.inc
@@ -11,8 +11,8 @@
 
 inherit pypi
 
-SRC_URI[md5sum] = "ea49a54b9d7e38302712194e85c37eaa"
-SRC_URI[sha256sum] = "2018f233568227f9af8c366f93e243a157b742f3baf5b649ecc9750ac0ee1ff7"
+SRC_URI[md5sum] = "ee753415645ff4831ff0d366a0467fe7"
+SRC_URI[sha256sum] = "ab94257cbd848dfca7148e092d233a12853cc7e840ce8231af9cbb5e7f51aa47"
 
 RDEPENDS_${PN} += " \
     ${PYTHON_PN}-shell \
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-robotframework_3.0.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-robotframework_3.0.4.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-robotframework_3.0.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-robotframework_3.0.4.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-semver.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-semver.inc
new file mode 100644
index 0000000..3c95c06
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-semver.inc
@@ -0,0 +1,12 @@
+DESCRIPTION = "Python module for Semantic Versioning"
+HOMEPAGE = "https://github.com/k-bx/python-semver"
+BUGTRACKER = "https://github.com/k-bx/python-semver/issues"
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://PKG-INFO;beginline=8;endline=8;md5=e910b35b0ef4e1f665b9a75d6afb7709"
+
+SRC_URI[md5sum] = "dc579ba9d0bb2137bad5324d4bdb7e40"
+SRC_URI[sha256sum] = "5b09010a66d9a3837211bb7ae5a20d10ba88f8cb49e92cb139a69ef90d5060d8"
+
+inherit pypi
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-semver_2.8.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-semver_2.8.1.bb
new file mode 100644
index 0000000..0572feb
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-semver_2.8.1.bb
@@ -0,0 +1,2 @@
+inherit setuptools
+require python-semver.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-serpent.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-serpent.inc
index 3f51bc2..2ba6570 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-serpent.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-serpent.inc
@@ -1,9 +1,9 @@
 SUMMARY = "Serialization based on ast.literal_eval"
 LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://PKG-INFO;md5=acdea68f0e5a89eb6cbfdf54e38c356e"
+LIC_FILES_CHKSUM = "file://PKG-INFO;md5=5a8193ba89f1083617f32d522f6485e9"
 
-SRC_URI[md5sum] = "d0c50f1943ff86d830eb3fe40f6dc1e3"
-SRC_URI[sha256sum] = "b6855483d95a03b6aee358363684cd38a3a670240da5bc6da4253079cb07b8df"
+SRC_URI[md5sum] = "0f9684622125a527fa4fbe2587738973"
+SRC_URI[sha256sum] = "264a028e059c1b557701ae7c567cdab330dbd228ff924489343efcb39bd828a0"
 
 inherit pypi
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-serpent_1.24.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-serpent_1.25.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-serpent_1.24.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-serpent_1.25.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-setuptools-scm.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-setuptools-scm.inc
index eb66580..98883ec 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-setuptools-scm.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-setuptools-scm.inc
@@ -2,8 +2,8 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://PKG-INFO;beginline=8;endline=8;md5=8227180126797a0148f94f483f3e1489"
 
-SRC_URI[md5sum] = "1b55f9cedde4a33ab5d286c5f30e86db"
-SRC_URI[sha256sum] = "e163e8a12d2121f77575773cfc2b5988275dc1f1d2541fdf780127c29dbbea9c"
+SRC_URI[md5sum] = "cfec5d2dbbd0a85c40066f79035b5878"
+SRC_URI[sha256sum] = "a767141fecdab1c0b3c8e4c788ac912d7c94a0d6c452d40777ba84f918316379"
 
 PYPI_PACKAGE = "setuptools_scm"
 inherit pypi
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-setuptools-scm_1.15.7.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-setuptools-scm_2.1.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-setuptools-scm_1.15.7.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-setuptools-scm_2.1.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-sh.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-sh.inc
new file mode 100644
index 0000000..f2fd562
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-sh.inc
@@ -0,0 +1,32 @@
+SUMMARY = "Python subprocess replacement"
+HOMEPAGE = "https://github.com/amoffat/sh"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=5317094292296f03405f59ae5f6544b6"
+
+SRC_URI[md5sum] = "a8351aef25d25f707c17e0a7a6280251"
+SRC_URI[sha256sum] = "b52bf5833ed01c7b5c5fb73a7f71b3d98d48e9b9b8764236237bdc7ecae850fc"
+
+PYPI_PACKAGE = "sh"
+
+inherit pypi
+
+RDEPENDS_${PN} += " \
+    ${PYTHON_PN}-codecs \
+    ${PYTHON_PN}-core \
+    ${PYTHON_PN}-io \
+    ${PYTHON_PN}-logging \
+    ${PYTHON_PN}-resource \
+    ${PYTHON_PN}-shell \
+    ${PYTHON_PN}-terminal \
+    ${PYTHON_PN}-tests \
+    ${PYTHON_PN}-threading \
+    ${PYTHON_PN}-unixadmin \
+"
+
+# WARNING: We were unable to map the following python package/module
+# dependencies to the bitbake packages which include them:
+#    coverage - only used in test and there is a check to see if it is
+#               available before importing.
+#    queue - part of threading
+#    signal - part of core in python3. not sure how it is imported in python2.
+#             No complants in compiling.
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-sh_1.12.14.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-sh_1.12.14.bb
new file mode 100644
index 0000000..7cb5140
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-sh_1.12.14.bb
@@ -0,0 +1,8 @@
+require python-sh.inc
+inherit setuptools
+
+RDEPENDS_${PN} += " \
+    ${PYTHON_PN}-contextlib \
+    ${PYTHON_PN}-lang \
+    ${PYTHON_PN}-textutils \
+"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-sijax.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-sijax.inc
new file mode 100644
index 0000000..9e46893
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-sijax.inc
@@ -0,0 +1,8 @@
+DESCRIPTION = "An easy to use AJAX library for Python based on jQuery.ajax"
+HOMEPAGE = "https://github.com/spantaleev/sijax-python"
+LICENSE = "BSD-3-Clause"
+
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=16e213d75641a392478df50cf0841903"
+
+PYPI_PACKAGE = "Sijax"
+inherit pypi
\ No newline at end of file
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-sijax_0.3.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-sijax_0.3.2.bb
new file mode 100644
index 0000000..4226c42
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-sijax_0.3.2.bb
@@ -0,0 +1,11 @@
+DESCRIPTION = "An easy to use AJAX library for Python based on jQuery.ajax"
+HOMEPAGE = "https://github.com/spantaleev/sijax-python"
+LICENSE = "BSD-3-Clause"
+
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=16e213d75641a392478df50cf0841903"
+
+PYPI_PACKAGE = "Sijax"
+inherit setuptools
+require python-sijax.inc
+
+SRC_URI[sha256sum] = "11b062f4a8b2aad95c87e7c09e5daf5a6b0d0f08abf9efe5f91a0075c6be7c0d"
\ No newline at end of file
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-simplejson.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-simplejson.inc
index e28d518..3d36f96 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-simplejson.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-simplejson.inc
@@ -4,8 +4,8 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=c6338d7abd321c0b50a2a547e441c52e"
 
-SRC_URI[md5sum] = "870bf6257465ce2ee8cad14e2394f7eb"
-SRC_URI[sha256sum] = "4c4ecf20e054716cc1e5a81cadc44d3f4027108d8dd0861d8b1e3bd7a32d4f0a"
+SRC_URI[md5sum] = "744fa99aed207478f8fbf9dd9f04fad3"
+SRC_URI[sha256sum] = "b1f329139ba647a9548aa05fb95d046b4a677643070dc2afc05fa2e975d09ca5"
 
 inherit pypi
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-simplejson_3.13.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-simplejson_3.16.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-simplejson_3.13.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-simplejson_3.16.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-slip-dbus_0.6.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-slip-dbus_0.6.1.bb
index 8081416..dc587e7 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-slip-dbus_0.6.1.bb
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-slip-dbus_0.6.1.bb
@@ -25,3 +25,7 @@
 do_compile_prepend() {
     sed -e 's/@VERSION@/${PV}/g' setup.py.in > setup.py
 }
+
+# http://errors.yoctoproject.org/Errors/Details/184713/
+# python-native/python: can't open file 'setup.py': [Errno 2] No such file or directory
+CLEANBROKEN = "1"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-stevedore.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-stevedore.inc
new file mode 100644
index 0000000..14ebc0e
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-stevedore.inc
@@ -0,0 +1,15 @@
+DESCRIPTION = "Manage dynamic plugins for Python applications"
+HOMEPAGE = "https://github.com/dreamhost/stevedore"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
+
+SRC_URI[md5sum] = "525186cba577852e0408c92c3f8fac65"
+SRC_URI[sha256sum] = "1e153545aca7a6a49d8337acca4f41c212fbfa60bf864ecd056df0cafb9627e8"
+
+inherit pypi
+
+DEPENDS += "${PYTHON_PN}-pbr-native"
+
+RDEPENDS_${PN} += "${PYTHON_PN}-pbr ${PYTHON_PN}-six"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-stevedore_1.29.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-stevedore_1.29.0.bb
new file mode 100644
index 0000000..70a00c1
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-stevedore_1.29.0.bb
@@ -0,0 +1,2 @@
+inherit setuptools
+require python-stevedore.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-tornado.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-tornado.inc
index 29d10da..16899f8 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-tornado.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-tornado.inc
@@ -4,10 +4,10 @@
 polling, WebSockets, and other applications that require a long-lived connection to each user."
 HOMEPAGE = "http://www.tornadoweb.org/en/stable/"
 LICENSE = "Apache-2.0"
-LIC_FILES_CHKSUM = "file://setup.py;beginline=3;endline=15;md5=8d463fc66ff8f275354ffe88d1896e12"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
 
-SRC_URI[md5sum] = "a5fc7fd4aea94867609a491ce65786f1"
-SRC_URI[sha256sum] = "6d14e47eab0e15799cf3cdcc86b0b98279da68522caace2bd7ce644287685f0a"
+SRC_URI[md5sum] = "bd264851c409f926d1dae1ad5055d28d"
+SRC_URI[sha256sum] = "4f66a2172cb947387193ca4c2c3e19131f1c70fa8be470ddbbd9317fd0801582"
 
 RDEPENDS_${PN} += "${PYTHON_PN}-compression ${PYTHON_PN}-numbers ${PYTHON_PN}-email \
                    ${PYTHON_PN}-pkgutil ${PYTHON_PN}-html ${PYTHON_PN}-json ${PYTHON_PN}-certifi ${PYTHON_PN}-threading \
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-tornado_4.5.3.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-tornado_5.1.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-tornado_4.5.3.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-tornado_5.1.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-traceback2_1.4.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-traceback2_1.4.0.bb
new file mode 100644
index 0000000..696c875
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-traceback2_1.4.0.bb
@@ -0,0 +1,15 @@
+SUMMARY = "A backport of traceback to older supported Pythons"
+HOMEPAGE = "https://github.com/testing-cabal/traceback2"
+LICENSE = "Python-2.0"
+LIC_FILES_CHKSUM = "file://PKG-INFO;beginline=31;endline=31;md5=368ddc8588431c180ae7c33f4fb57519"
+
+DEPENDS = "${PYTHON_PN}-pbr-native"
+
+SRC_URI[md5sum] = "9e9723f4d70bfc6308fa992dd193c400"
+SRC_URI[sha256sum] = "05acc67a09980c2ecfedd3423f7ae0104839eccb55fc645773e1caa0951c3030"
+
+inherit pypi setuptools
+
+CLEANBROKEN = "1"
+
+RDEPENDS_${PN} = "${PYTHON_PN}-linecache2"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-twisted.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-twisted.inc
index 6480ad5..01616b1 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-twisted.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-twisted.inc
@@ -5,10 +5,10 @@
 
 #twisted/topfiles/NEWS:655: - Relicensed: Now under the MIT license, rather than LGPL.
 LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=8a9c2fbfcba7d70504e3ba545e1820ed"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=04e7730aecedc79d805625a91bc06145"
 
-SRC_URI[md5sum] = "6dbedb918f0c7288a4c670f59393ecf8"
-SRC_URI[sha256sum] = "0da1a7e35d5fcae37bc9c7978970b5feb3bc82822155b8654ec63925c05af75c"
+SRC_URI[sha256sum] = "a4cc164a781859c74de47f17f0e85f4bce8a3321a9d0892c015c8f80c4158ad9"
+SRC_URI[md5sum] = "da8142ad4e9971a75fe751ac96a33b95"
 
 PYPI_PACKAGE = "Twisted"
 PYPI_PACKAGE_EXT = "tar.bz2"
@@ -49,9 +49,12 @@
     ${PN}-conch \
     ${PN}-mail \
     ${PN}-names \
+    ${PN}-pair \
+    ${PN}-protocols \
     ${PN}-runner \
     ${PN}-web \
     ${PN}-words \
+    ${PN}-zsh \
 "
 
 RDEPENDS_${PN}-core = "${PYTHON_PN}-core ${PYTHON_PN}-zopeinterface ${PYTHON_PN}-incremental ${PYTHON_PN}-constantly ${PYTHON_PN}-hyperlink ${PYTHON_PN}-automat"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-twisted_17.9.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-twisted_17.9.0.bb
deleted file mode 100644
index 2be1709..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-twisted_17.9.0.bb
+++ /dev/null
@@ -1,4 +0,0 @@
-inherit pypi setuptools
-require python-twisted.inc
-
-RDEPENDS_${PN}-core += "${PYTHON_PN}-contextlib"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-twisted_18.4.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-twisted_18.4.0.bb
new file mode 100644
index 0000000..5903db3
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-twisted_18.4.0.bb
@@ -0,0 +1,8 @@
+inherit pypi setuptools
+require python-twisted.inc
+
+RDEPENDS_${PN}-core += "${PYTHON_PN}-contextlib"
+
+RDEPENDS_${PN} += " \
+    ${PN}-news \
+"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-urllib3.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-urllib3.inc
index cf79926..288ed8b 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-urllib3.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-urllib3.inc
@@ -3,8 +3,8 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=ea114851ad9a8c311aac8728a681a067"
 
-SRC_URI[md5sum] = "0da7bed3fe94bf7dc59ae37885cc72f7"
-SRC_URI[sha256sum] = "cc44da8e1145637334317feebd728bd869a35285b93cbb4cca2577da7e62db4f"
+SRC_URI[md5sum] = "1ad43e4b5ab7a0794c89dc057e1d7179"
+SRC_URI[sha256sum] = "a68ac5e15e76e7e5dd2b8f94007233e01effe3e50e8daddf69acfd81cb686baf"
 
 RDEPENDS_${PN} += "\
     ${PYTHON_PN}-certifi \
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-urllib3_1.22.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-urllib3_1.23.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-urllib3_1.22.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-urllib3_1.23.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-vobject_0.9.5.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-vobject_0.9.5.bb
deleted file mode 100644
index d2f343e..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-vobject_0.9.5.bb
+++ /dev/null
@@ -1,15 +0,0 @@
-SUMMARY = "Python package for parsing and generating vCard and vCalendar files"
-HOMEPAGE = "http://vobject.skyhouseconsulting.com/"
-
-LICENSE = "Apache-2.0"
-LIC_FILES_CHKSUM = "file://LICENSE-2.0.txt;md5=3b83ef96387f14655fc854ddc3c6bd57"
-
-SRC_URI[md5sum] = "aa629d6ae95db5edfd5b2402eb1073cb"
-SRC_URI[sha256sum] = "0f56cae196303d875682b9648b4bb43ffc769d2f0f800958e0a506af867b1243"
-
-inherit pypi setuptools
-
-RDEPENDS_${PN} += "\
-    ${PYTHON_PN}-dateutil \
-    ${PYTHON_PN}-numbers \
-    "
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-vobject_0.9.6.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-vobject_0.9.6.1.bb
new file mode 100644
index 0000000..d31f2f5
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-vobject_0.9.6.1.bb
@@ -0,0 +1,15 @@
+SUMMARY = "Python package for parsing and generating vCard and vCalendar files"
+HOMEPAGE = "http://vobject.skyhouseconsulting.com/"
+
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE-2.0.txt;md5=3b83ef96387f14655fc854ddc3c6bd57"
+
+SRC_URI[md5sum] = "06357e96a84d55de2a71b36d39f6853e"
+SRC_URI[sha256sum] = "96512aec74b90abb71f6b53898dd7fe47300cc940104c4f79148f0671f790101"
+
+inherit pypi setuptools
+
+RDEPENDS_${PN} += "\
+    ${PYTHON_PN}-dateutil \
+    ${PYTHON_PN}-numbers \
+    "
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-wtforms.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-wtforms.inc
index 916697f..868686b 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-wtforms.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-wtforms.inc
@@ -2,13 +2,12 @@
 HOMEPAGE = "https://pypi.python.org/pypi/WTForms"
 SECTION = "devel/python"
 LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://PKG-INFO;md5=c459accc90c6ed6a94878c8fe0535be2"
+LIC_FILES_CHKSUM = "file://PKG-INFO;md5=c4660c132770d5d0a5757541f6b79493"
 
-SRC_URI[md5sum] = "6938a541fafd1a1ae2f6b9b88588eef2"
-SRC_URI[sha256sum] = "ffdf10bd1fa565b8233380cb77a304cd36fd55c73023e91d4b803c96bc11d46f"
+SRC_URI[md5sum] = "41c0008dbe7bd98892c58f7457a46a4a"
+SRC_URI[sha256sum] = "0cdbac3e7f6878086c334aa25dc5a33869a3954e9d1e015130d65a69309b3b61"
 
 PYPI_PACKAGE = "WTForms"
-PYPI_PACKAGE_EXT = "zip"
 
 RDEPENDS_${PN} += "\
     ${PYTHON_PN}-netserver \
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-wtforms_2.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-wtforms_2.2.1.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-wtforms_2.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-wtforms_2.2.1.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-zopeinterface.inc b/meta-openembedded/meta-python/recipes-devtools/python/python-zopeinterface.inc
index 1fab2cc..12623c9 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-zopeinterface.inc
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-zopeinterface.inc
@@ -2,8 +2,8 @@
 LICENSE = "ZPL-2.1"
 LIC_FILES_CHKSUM = "file://PKG-INFO;beginline=8;endline=8;md5=e54fd776274c1b7423ec128974bd9d46"
 
-SRC_URI[md5sum] = "8700a4f527c1203b34b10c2b4e7a6912"
-SRC_URI[sha256sum] = "d6d26d5dfbfd60c65152938fcb82f949e8dada37c041f72916fef6621ba5c5ce"
+SRC_URI[md5sum] = "7b669cd692d817772c61d2e3ad0f1e71"
+SRC_URI[sha256sum] = "57c38470d9f57e37afb460c399eb254e7193ac7fb8042bd09bdc001981a9c74c"
 
 PYPI_PACKAGE = "zope.interface"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-zopeinterface_4.4.3.bb b/meta-openembedded/meta-python/recipes-devtools/python/python-zopeinterface_4.5.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python-zopeinterface_4.4.3.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python-zopeinterface_4.5.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-alembic_0.9.8.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-alembic_1.0.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-alembic_0.9.8.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-alembic_1.0.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-astroid_1.6.3.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-astroid_1.6.5.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-astroid_1.6.3.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-astroid_1.6.5.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-attrs_17.4.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-attrs_18.1.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-attrs_17.4.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-attrs_18.1.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-automat_0.6.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-automat_0.7.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-automat_0.6.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-automat_0.7.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-aws-iot-device-sdk-python_1.3.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-aws-iot-device-sdk-python_1.4.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-aws-iot-device-sdk-python_1.3.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-aws-iot-device-sdk-python_1.4.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-babel_2.5.3.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-babel_2.6.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-babel_2.5.3.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-babel_2.6.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-bandit_1.4.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-bandit_1.4.0.bb
new file mode 100644
index 0000000..84f4761
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-bandit_1.4.0.bb
@@ -0,0 +1,12 @@
+SUMMARY = "Security oriented static analyser for python code."
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=1dece7821bf3fd70fe1309eaa37d52a2"
+
+SRC_URI[md5sum] = "f74155cb9921be857693b32d2531e857"
+SRC_URI[sha256sum] = "cb977045497f83ec3a02616973ab845c829cdab8144ce2e757fe031104a9abd4"
+
+DEPENDS = "python3-pyyaml python3-six python3-stevedore python3-pbr-native"
+
+inherit setuptools3 pypi
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-behave_1.2.6.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-behave_1.2.6.bb
new file mode 100644
index 0000000..1c55871
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-behave_1.2.6.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-behave.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-bitarray_0.8.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-bitarray_0.8.3.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-bitarray_0.8.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-bitarray_0.8.3.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-can_2.1.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-can_2.2.1.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-can_2.1.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-can_2.2.1.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-cassandra-driver_3.13.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-cassandra-driver_3.14.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-cassandra-driver_3.13.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-cassandra-driver_3.14.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-certifi_2018.1.18.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-certifi_2018.8.13.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-certifi_2018.1.18.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-certifi_2018.8.13.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-chardet_3.0.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-chardet_3.0.4.bb
index 038043c..38d8122 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python3-chardet_3.0.4.bb
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-chardet_3.0.4.bb
@@ -1,2 +1,7 @@
 inherit setuptools3
 require python-chardet.inc
+
+do_install_append () {
+    # rename scripts that would conflict with the Python 2 build of chardet
+    mv ${D}${bindir}/chardetect ${D}${bindir}/chardetect3
+}
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-crcmod_1.7.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-crcmod_1.7.bb
new file mode 100644
index 0000000..6996b13
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-crcmod_1.7.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-crcmod.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-cryptography-vectors_2.1.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-cryptography-vectors_2.3.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-cryptography-vectors_2.1.4.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-cryptography-vectors_2.3.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-cryptography_2.1.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-cryptography_2.3.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-cryptography_2.1.4.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-cryptography_2.3.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-cython_0.28.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-cython_0.28.5.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-cython_0.28.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-cython_0.28.5.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-dateutil_2.7.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-dateutil_2.7.3.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-dateutil_2.7.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-dateutil_2.7.3.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-django_1.11.10.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-django_1.11.14.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-django_1.11.10.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-django_1.11.14.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-djangorestframework_3.9.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-djangorestframework_3.9.0.bb
new file mode 100644
index 0000000..9ed6d17
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-djangorestframework_3.9.0.bb
@@ -0,0 +1,2 @@
+require python-djangorestframework.inc
+inherit setuptools3
\ No newline at end of file
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-flask-migrate_2.1.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-flask-migrate_2.2.1.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-flask-migrate_2.1.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-flask-migrate_2.2.1.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-flask-sijax_0.4.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-flask-sijax_0.4.1.bb
new file mode 100644
index 0000000..e9a65c4
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-flask-sijax_0.4.1.bb
@@ -0,0 +1,4 @@
+inherit pypi setuptools3
+require python-flask-sijax.inc
+
+SRC_URI[sha256sum] = "fb2bf2d4f75408185102195055d75549fee8d9c9e954dca2427186925cdc429f"
\ No newline at end of file
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-flask_0.12.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-flask_1.0.2.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-flask_0.12.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-flask_1.0.2.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-future_0.16.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-future_0.16.0.bb
new file mode 100644
index 0000000..f059186
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-future_0.16.0.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-future.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-greenlet_0.4.13.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-greenlet_0.4.14.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-greenlet_0.4.13.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-greenlet_0.4.14.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-grpcio-tools_1.14.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-grpcio-tools_1.14.1.bb
new file mode 100644
index 0000000..2da1a4d
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-grpcio-tools_1.14.1.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-grpcio-tools.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-grpcio_1.14.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-grpcio_1.14.1.bb
new file mode 100644
index 0000000..d4720b4
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-grpcio_1.14.1.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-grpcio.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-hyperlink_17.3.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-hyperlink_18.0.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-hyperlink_17.3.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-hyperlink_18.0.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-idna_2.6.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-idna_2.7.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-idna_2.6.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-idna_2.7.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-inflection_0.3.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-inflection_0.3.1.bb
new file mode 100644
index 0000000..cc36a02
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-inflection_0.3.1.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-inflection.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-intervals_1.5.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-intervals_1.5.4.bb
new file mode 100644
index 0000000..8cbe109
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-intervals_1.5.4.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-intervals.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-langtable_0.0.38.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-langtable_0.0.38.bb
index 0ca58c7..eb42fe9 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python3-langtable_0.0.38.bb
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-langtable_0.0.38.bb
@@ -16,8 +16,8 @@
 
 inherit setuptools3 python3native
 
-DISTUTILS_INSTALL_ARGS = "--prefix=${D}/${prefix} \
-    --install-data=${D}/${datadir}/langtable"
+DISTUTILS_INSTALL_ARGS += " \
+    --install-data=${datadir}/langtable"
 
 FILES_${PN} += "${datadir}/*"
 
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-lxml_4.2.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-lxml_4.2.1.bb
deleted file mode 100644
index ff4bc7f..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python3-lxml_4.2.1.bb
+++ /dev/null
@@ -1,2 +0,0 @@
-inherit setuptools3
-require python-lxml.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-lxml_4.2.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-lxml_4.2.4.bb
new file mode 100644
index 0000000..b95d7ba
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-lxml_4.2.4.bb
@@ -0,0 +1,3 @@
+inherit setuptools3
+require python-lxml.inc
+CLEANBROKEN = "1"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-m2crypto_0.30.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-m2crypto_0.30.1.bb
new file mode 100644
index 0000000..4d63d4b
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-m2crypto_0.30.1.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-m2crypto.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-ndg-httpsclient_0.4.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-ndg-httpsclient_0.4.4.bb
deleted file mode 100644
index 3f07b2e..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python3-ndg-httpsclient_0.4.4.bb
+++ /dev/null
@@ -1,2 +0,0 @@
-inherit pypi setuptools3
-require python-ndg-httpsclient.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-ndg-httpsclient_0.5.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-ndg-httpsclient_0.5.1.bb
new file mode 100644
index 0000000..65a8c81
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-ndg-httpsclient_0.5.1.bb
@@ -0,0 +1,6 @@
+inherit pypi setuptools3 update-alternatives
+require python-ndg-httpsclient.inc
+
+ALTERNATIVE_${PN} = "ndg_httpclient"
+ALTERNATIVE_LINK_NAME[ndg_httpclient] = "${bindir}/ndg_httpclient"
+ALTERNATIVE_PRIORITY = "30"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-ordered-set_2.0.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-ordered-set_2.0.2.bb
deleted file mode 100644
index be6d4e1..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python3-ordered-set_2.0.2.bb
+++ /dev/null
@@ -1,10 +0,0 @@
-SUMMARY = "A MutableSet that remembers its order, so that every entry has an index."
-HOMEPAGE = "http://github.com/LuminosoInsight/ordered-set"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://MIT-LICENSE;md5=0feb0c85b722f488b87844fb5f81d2dc"
-
-SRC_URI[md5sum] = "7b8d73dc64fd3c783ecb48e050bfcc0d"
-SRC_URI[sha256sum] = "942cad5d7d5b0760d5cbe93dfb385ac2ed402ca1d48c9f4e102d7d5cce3a90eb"
-
-inherit pypi setuptools3
-
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-ordered-set_3.0.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-ordered-set_3.0.1.bb
new file mode 100644
index 0000000..662d3ee
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-ordered-set_3.0.1.bb
@@ -0,0 +1,11 @@
+SUMMARY = "A MutableSet that remembers its order, so that every entry has an index."
+HOMEPAGE = "http://github.com/LuminosoInsight/ordered-set"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://MIT-LICENSE;md5=2b36be0d99854aa2ae292a800a7c1d4e"
+
+SRC_URI[md5sum] = "a8059c7b99cde0f8dda01ddee6b43c2c"
+SRC_URI[sha256sum] = "3d6fd7bffbb15f613a9e8a6281bf97c2d67f7bb8677deca8249df2fbdd9cce7b"
+
+inherit pypi setuptools3
+
+DEPENDS += "python3-pytest-runner-native"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pandas_0.22.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pandas_0.23.4.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-pandas_0.22.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-pandas_0.23.4.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-parse-type_0.4.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-parse-type_0.4.2.bb
new file mode 100644
index 0000000..91d9ce2
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-parse-type_0.4.2.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-parse-type.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-parse_1.8.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-parse_1.8.4.bb
new file mode 100644
index 0000000..b124254
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-parse_1.8.4.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-parse.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-periphery_1.1.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-periphery_1.1.1.bb
new file mode 100644
index 0000000..ba9a95d
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-periphery_1.1.1.bb
@@ -0,0 +1,4 @@
+inherit pypi setuptools3
+require python-periphery.inc
+
+SRC_URI[sha256sum] = "fe8f351934edce72cd919b4eb070878ebff551db5e21aea61e0f446101f0a79f"
\ No newline at end of file
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pexpect_4.5.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pexpect_4.6.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-pexpect_4.5.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-pexpect_4.6.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pint_0.8.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pint_0.8.1.bb
new file mode 100644
index 0000000..f793ac4
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-pint_0.8.1.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-pint.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-prctl_1.6.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-prctl_1.6.1.bb
deleted file mode 100644
index 5de83ce..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python3-prctl_1.6.1.bb
+++ /dev/null
@@ -1,22 +0,0 @@
-SUMMARY  = "Control process attributes through prctl"
-DESCRIPTION = "The linux prctl function allows you to control specific characteristics of a \
-process' behaviour. Usage of the function is fairly messy though, due to \
-limitations in C and linux. This module provides a nice non-messy python(ic) \
-interface."
-SECTION = "devel/python"
-LICENSE = "GPLv3"
-LIC_FILES_CHKSUM = "file://COPYING;md5=5eb2f4bcd60326f83e5deb542372d52f"
-
-S = "${WORKDIR}/git"
-B = "${S}"
-
-SRCREV = "1107d0be7bec4b28c85c62c454882d16844c930a"
-PV = "1.6.1+git${SRCPV}"
-
-SRC_URI = "git://github.com/seveas/python-prctl;branch=master \
-           file://0001-support-cross-complication.patch \
-"
-inherit setuptools3 python3native
-
-DEPENDS += "libcap"
-
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-prctl_1.7.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-prctl_1.7.bb
new file mode 100644
index 0000000..54620a0
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-prctl_1.7.bb
@@ -0,0 +1,22 @@
+SUMMARY  = "Control process attributes through prctl"
+DESCRIPTION = "The linux prctl function allows you to control specific characteristics of a \
+process' behaviour. Usage of the function is fairly messy though, due to \
+limitations in C and linux. This module provides a nice non-messy python(ic) \
+interface."
+SECTION = "devel/python"
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=23ff9f50449d4bd0e513df16e4d9755f"
+
+S = "${WORKDIR}/git"
+B = "${S}"
+
+SRCREV = "57cd0a7cad76e8f8792eea22ee5b5d17bae0a90f"
+PV = "1.7+git${SRCPV}"
+
+SRC_URI = "git://github.com/seveas/python-prctl;branch=master \
+           file://0001-support-cross-complication.patch \
+"
+inherit setuptools3 python3native
+
+DEPENDS += "libcap"
+
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-progress_1.3.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-progress_1.4.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-progress_1.3.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-progress_1.4.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-prompt-toolkit_1.0.15.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-prompt-toolkit_2.0.4.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-prompt-toolkit_1.0.15.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-prompt-toolkit_2.0.4.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-protobuf_3.5.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-protobuf_3.6.1.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-protobuf_3.5.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-protobuf_3.6.1.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-psutil_5.4.3.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-psutil_5.4.6.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-psutil_5.4.3.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-psutil_5.4.6.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-ptyprocess_0.5.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-ptyprocess_0.6.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-ptyprocess_0.5.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-ptyprocess_0.6.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-py_1.5.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-py_1.6.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-py_1.5.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-py_1.6.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pyasn1-modules_0.2.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pyasn1-modules_0.2.2.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-pyasn1-modules_0.2.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-pyasn1-modules_0.2.2.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pyasn1_0.4.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pyasn1_0.4.4.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-pyasn1_0.4.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-pyasn1_0.4.4.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pybind11_2.2.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pybind11_2.2.3.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-pybind11_2.2.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-pybind11_2.2.3.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pycodestyle_2.4.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pycodestyle_2.4.0.bb
new file mode 100644
index 0000000..cedcdb3
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-pycodestyle_2.4.0.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-pycodestyle.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pydbus/0001-Support-asynchronous-calls-58.patch b/meta-openembedded/meta-python/recipes-devtools/python/python3-pydbus/0001-Support-asynchronous-calls-58.patch
new file mode 100644
index 0000000..c5cb9a8
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-pydbus/0001-Support-asynchronous-calls-58.patch
@@ -0,0 +1,93 @@
+From 39a7d79ee6c548902fbac8b95c934af7e4c69260 Mon Sep 17 00:00:00 2001
+From: Vendula Poncova <vponcova@redhat.com>
+Date: Thu, 2 Aug 2018 15:30:45 +0800
+Subject: [PATCH 1/2] Support asynchronous calls (#58)
+
+Added support for asynchronous calls of methods. A method is called
+synchronously unless its callback parameter is specified. A callback
+is a function f(*args, returned=None, error=None), where args is
+callback_args specified in the method call, returned is a return
+value of the method and error is an exception raised by the method.
+
+Example of an asynchronous call:
+
+def func(x, y, returned=None, error=None):
+  pass
+
+proxy.Method(a, b, callback=func, callback_args=(x, y))
+
+Upstream-Status: Cherry-pick [https://src.fedoraproject.org/cgit/rpms/python-pydbus.git/]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ pydbus/proxy_method.py | 44 ++++++++++++++++++++++++++++++++++++++------
+ 1 file changed, 38 insertions(+), 6 deletions(-)
+
+diff --git a/pydbus/proxy_method.py b/pydbus/proxy_method.py
+index 8798edd..4ea4304 100644
+--- a/pydbus/proxy_method.py
++++ b/pydbus/proxy_method.py
+@@ -65,15 +65,34 @@ class ProxyMethod(object):
+ 
+ 		# Python 2 sux
+ 		for kwarg in kwargs:
+-			if kwarg not in ("timeout",):
++			if kwarg not in ("timeout", "callback", "callback_args"):
+ 				raise TypeError(self.__qualname__ + " got an unexpected keyword argument '{}'".format(kwarg))
+ 		timeout = kwargs.get("timeout", None)
++		callback = kwargs.get("callback", None)
++		callback_args = kwargs.get("callback_args", tuple())
++
++		call_args = (
++			instance._bus_name,
++			instance._path,
++			self._iface_name,
++			self.__name__,
++			GLib.Variant(self._sinargs, args),
++			GLib.VariantType.new(self._soutargs),
++			0,
++			timeout_to_glib(timeout),
++			None
++		)
++
++		if callback:
++			call_args += (self._finish_async_call, (callback, callback_args))
++			instance._bus.con.call(*call_args)
++			return None
++		else:
++			ret = instance._bus.con.call_sync(*call_args)
++			return self._unpack_return(ret)
+ 
+-		ret = instance._bus.con.call_sync(
+-			instance._bus_name, instance._path,
+-			self._iface_name, self.__name__, GLib.Variant(self._sinargs, args), GLib.VariantType.new(self._soutargs),
+-			0, timeout_to_glib(timeout), None).unpack()
+-
++	def _unpack_return(self, values):
++		ret = values.unpack()
+ 		if len(self._outargs) == 0:
+ 			return None
+ 		elif len(self._outargs) == 1:
+@@ -81,6 +100,19 @@ class ProxyMethod(object):
+ 		else:
+ 			return ret
+ 
++	def _finish_async_call(self, source, result, user_data):
++		error = None
++		return_args = None
++
++		try:
++			ret = source.call_finish(result)
++			return_args = self._unpack_return(ret)
++		except Exception as err:
++			error = err
++
++		callback, callback_args = user_data
++		callback(*callback_args, returned=return_args, error=error)
++
+ 	def __get__(self, instance, owner):
+ 		if instance is None:
+ 			return self
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pydbus/0002-Support-transformation-between-D-Bus-errors-and-exce.patch b/meta-openembedded/meta-python/recipes-devtools/python/python3-pydbus/0002-Support-transformation-between-D-Bus-errors-and-exce.patch
new file mode 100644
index 0000000..f5c0390
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-pydbus/0002-Support-transformation-between-D-Bus-errors-and-exce.patch
@@ -0,0 +1,203 @@
+From 69968dec867053e38de0b91d76ac41d5a5735e36 Mon Sep 17 00:00:00 2001
+From: Vendula Poncova <vponcova@redhat.com>
+Date: Thu, 2 Aug 2018 15:31:56 +0800
+Subject: [PATCH 2/2] Support transformation between D-Bus errors and
+ exceptions.
+
+Exceptions can be registered with decorators, raised in a remote
+method and recreated after return from the remote call.
+
+Upstream-Status: Cherry-pick [https://src.fedoraproject.org/cgit/rpms/python-pydbus.git/]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ pydbus/error.py        | 97 ++++++++++++++++++++++++++++++++++++++++++++++++++
+ pydbus/proxy_method.py | 18 ++++++++--
+ pydbus/registration.py | 16 ++++++---
+ 3 files changed, 123 insertions(+), 8 deletions(-)
+ create mode 100644 pydbus/error.py
+
+diff --git a/pydbus/error.py b/pydbus/error.py
+new file mode 100644
+index 0000000..aaa3510
+--- /dev/null
++++ b/pydbus/error.py
+@@ -0,0 +1,97 @@
++from gi.repository import GLib, Gio
++
++
++def register_error(name, domain, code):
++	"""Register and map decorated exception class to a DBus error."""
++	def decorated(cls):
++		error_registration.register_error(cls, name, domain, code)
++		return cls
++
++	return decorated
++
++
++def map_error(error_name):
++	"""Map decorated exception class to a DBus error."""
++	def decorated(cls):
++		error_registration.map_error(cls, error_name)
++		return cls
++
++	return decorated
++
++
++def map_by_default(cls):
++	"""Map decorated exception class to all unknown DBus errors."""
++	error_registration.map_by_default(cls)
++	return cls
++
++
++class ErrorRegistration(object):
++	"""Class for mapping exceptions to DBus errors."""
++
++	_default = None
++	_map = dict()
++	_reversed_map = dict()
++
++	def map_by_default(self, exception_cls):
++		"""Set the exception class as a default."""
++		self._default = exception_cls
++
++	def map_error(self, exception_cls, name):
++		"""Map the exception class to a DBus name."""
++		self._map[name] = exception_cls
++		self._reversed_map[exception_cls] = name
++
++	def register_error(self, exception_cls, name, domain, code):
++		"""Map and register the exception class to a DBus name."""
++		self.map_error(exception_cls, name)
++		return Gio.DBusError.register_error(domain, code, name)
++
++	def is_registered_exception(self, obj):
++		"""Is the exception registered?"""
++		return obj.__class__ in self._reversed_map
++
++	def get_dbus_name(self, obj):
++		"""Get the DBus name of the exception."""
++		return self._reversed_map.get(obj.__class__)
++
++	def get_exception_class(self, name):
++		"""Get the exception class mapped to the DBus name."""
++		return self._map.get(name, self._default)
++
++	def transform_message(self, name, message):
++		"""Transform the message of the exception."""
++		prefix = "{}:{}: ".format("GDBus.Error", name)
++
++		if message.startswith(prefix):
++			return message[len(prefix):]
++
++		return message
++
++	def transform_exception(self, e):
++		"""Transform the remote error to the exception."""
++		if not isinstance(e, GLib.Error):
++			return e
++
++		if not Gio.DBusError.is_remote_error(e):
++			return e
++
++		# Get DBus name of the error.
++		name = Gio.DBusError.get_remote_error(e)
++		# Get the exception class.
++		exception_cls = self.get_exception_class(name)
++
++		# Return the original exception.
++		if not exception_cls:
++			return e
++
++		# Return new exception.
++		message = self.transform_message(name, e.message)
++		exception = exception_cls(message)
++		exception.dbus_name = name
++		exception.dbus_domain = e.domain
++		exception.dbus_code = e.code
++		return exception
++
++
++# Default error registration.
++error_registration = ErrorRegistration()
+diff --git a/pydbus/proxy_method.py b/pydbus/proxy_method.py
+index 4ea4304..e9496f5 100644
+--- a/pydbus/proxy_method.py
++++ b/pydbus/proxy_method.py
+@@ -2,6 +2,7 @@ from gi.repository import GLib
+ from .generic import bound_method
+ from .identifier import filter_identifier
+ from .timeout import timeout_to_glib
++from .error import error_registration
+ 
+ try:
+ 	from inspect import Signature, Parameter
+@@ -87,9 +88,20 @@ class ProxyMethod(object):
+ 			call_args += (self._finish_async_call, (callback, callback_args))
+ 			instance._bus.con.call(*call_args)
+ 			return None
++
+ 		else:
+-			ret = instance._bus.con.call_sync(*call_args)
+-			return self._unpack_return(ret)
++			result = None
++			error = None
++
++			try:
++				result = instance._bus.con.call_sync(*call_args)
++			except Exception as e:
++				error = error_registration.transform_exception(e)
++
++			if error:
++				raise error
++
++			return self._unpack_return(result)
+ 
+ 	def _unpack_return(self, values):
+ 		ret = values.unpack()
+@@ -108,7 +120,7 @@ class ProxyMethod(object):
+ 			ret = source.call_finish(result)
+ 			return_args = self._unpack_return(ret)
+ 		except Exception as err:
+-			error = err
++			error = error_registration.transform_exception(err)
+ 
+ 		callback, callback_args = user_data
+ 		callback(*callback_args, returned=return_args, error=error)
+diff --git a/pydbus/registration.py b/pydbus/registration.py
+index f531539..1d2cbcb 100644
+--- a/pydbus/registration.py
++++ b/pydbus/registration.py
+@@ -5,6 +5,7 @@ from . import generic
+ from .exitable import ExitableWithAliases
+ from functools import partial
+ from .method_call_context import MethodCallContext
++from .error import error_registration
+ import logging
+ 
+ try:
+@@ -91,11 +92,16 @@ class ObjectWrapper(ExitableWithAliases("unwrap")):
+ 			logger = logging.getLogger(__name__)
+ 			logger.exception("Exception while handling %s.%s()", interface_name, method_name)
+ 
+-			#TODO Think of a better way to translate Python exception types to DBus error types.
+-			e_type = type(e).__name__
+-			if not "." in e_type:
+-				e_type = "unknown." + e_type
+-			invocation.return_dbus_error(e_type, str(e))
++			if error_registration.is_registered_exception(e):
++				name = error_registration.get_dbus_name(e)
++				invocation.return_dbus_error(name, str(e))
++			else:
++				logger.info("name is not registered")
++				e_type = type(e).__name__
++				if not "." in e_type:
++					e_type = "unknown." + e_type
++
++				invocation.return_dbus_error(e_type, str(e))
+ 
+ 	def Get(self, interface_name, property_name):
+ 		type = self.readable_properties[interface_name + "." + property_name]
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pydbus_0.6.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pydbus_0.6.0.bb
index 7ed1c63..adaa86d 100644
--- a/meta-openembedded/meta-python/recipes-devtools/python/python3-pydbus_0.6.0.bb
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-pydbus_0.6.0.bb
@@ -1,2 +1,6 @@
 require python-pydbus.inc
 inherit pypi setuptools3
+
+SRC_URI += "file://0001-Support-asynchronous-calls-58.patch \
+            file://0002-Support-transformation-between-D-Bus-errors-and-exce.patch \
+"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pyiface_0.0.5.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pyiface_0.0.11.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-pyiface_0.0.5.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-pyiface_0.0.11.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pyjwt_1.6.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pyjwt_1.6.4.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-pyjwt_1.6.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-pyjwt_1.6.4.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pymisp_2.4.89.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pymisp_2.4.93.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-pymisp_2.4.89.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-pymisp_2.4.93.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pymongo_3.6.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pymongo_3.7.1.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-pymongo_3.6.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-pymongo_3.7.1.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pyopenssl_17.5.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pyopenssl_18.0.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-pyopenssl_17.5.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-pyopenssl_18.0.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pyperclip_1.6.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pyperclip_1.6.2.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-pyperclip_1.6.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-pyperclip_1.6.2.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pyroute2_0.4.21.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pyroute2_0.5.2.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-pyroute2_0.4.21.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-pyroute2_0.5.2.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pytest-helpers-namespace_2016.7.10.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pytest-helpers-namespace_2016.7.10.bb
new file mode 100644
index 0000000..f03f5d4
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-pytest-helpers-namespace_2016.7.10.bb
@@ -0,0 +1,7 @@
+require python-pytest-helpers-namespace.inc
+
+inherit setuptools3
+
+RDEPENDS_${PN} += " \
+    python3-pytest \
+    "
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pytest-runner_3.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pytest-runner_4.2.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-pytest-runner_3.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-pytest-runner_4.2.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pytest-tempdir_2016.8.20.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pytest-tempdir_2016.8.20.bb
new file mode 100644
index 0000000..02e8215
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-pytest-tempdir_2016.8.20.bb
@@ -0,0 +1,7 @@
+require python-pytest-tempdir.inc
+
+inherit setuptools3
+
+RDEPENDS_${PN} += " \
+    python3-pytest \
+    "
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pytz_2018.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pytz_2018.5.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-pytz_2018.4.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-pytz_2018.5.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pyyaml_3.12.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pyyaml_3.13.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-pyyaml_3.12.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-pyyaml_3.13.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-pyzmq_17.1.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-pyzmq_17.1.0.bb
new file mode 100644
index 0000000..050f53a
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-pyzmq_17.1.0.bb
@@ -0,0 +1,2 @@
+require python-pyzmq.inc
+inherit setuptools3
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-requests-file_1.4.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-requests-file_1.4.2.bb
deleted file mode 100644
index 8652876..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python3-requests-file_1.4.2.bb
+++ /dev/null
@@ -1,14 +0,0 @@
-SUMMARY = "File transport adapter for Requests"
-HOMEPAGE = "http://github.com/dashea/requests-file"
-LICENSE = "Apache-2.0"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=9cc728d6087e43796227b0a31422de6b"
-
-SRC_URI[md5sum] = "a907efb75faf0ccbb1857432bf9d8c0f"
-SRC_URI[sha256sum] = "f518e7cfe048e053fd1019dfb891b4c55b871c56c5a31693d733240c80b8f191"
-
-inherit pypi setuptools3
-
-RDEPENDS_${PN} += " \
-    python3-requests \
-"
-
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-requests-file_1.4.3.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-requests-file_1.4.3.bb
new file mode 100644
index 0000000..0407779
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-requests-file_1.4.3.bb
@@ -0,0 +1,14 @@
+SUMMARY = "File transport adapter for Requests"
+HOMEPAGE = "http://github.com/dashea/requests-file"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=9cc728d6087e43796227b0a31422de6b"
+
+SRC_URI[md5sum] = "470711c9b7e0de1057f7b72a58b7ab51"
+SRC_URI[sha256sum] = "8f04aa6201bacda0567e7ac7f677f1499b0fc76b22140c54bc06edf1ba92e2fa"
+
+inherit pypi setuptools3
+
+RDEPENDS_${PN} += " \
+    python3-requests \
+"
+
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-requests_2.18.4.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-requests_2.19.1.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-requests_2.18.4.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-requests_2.19.1.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-robotframework-seriallibrary_0.3.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-robotframework-seriallibrary_0.3.1.bb
new file mode 100644
index 0000000..440f69c
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-robotframework-seriallibrary_0.3.1.bb
@@ -0,0 +1,2 @@
+inherit pypi setuptools
+require python-robotframework-seriallibrary.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-robotframework_3.0.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-robotframework_3.0.4.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-robotframework_3.0.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-robotframework_3.0.4.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-scapy_0.23.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-scapy_0.23.bb
deleted file mode 100644
index 3e7baf4..0000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python3-scapy_0.23.bb
+++ /dev/null
@@ -1,13 +0,0 @@
-DESCRIPTION = "Packet crafting/sending/sniffing, PCAP processing tool,\
-based on scapy with python3 compatibility"
-SECTION = "devel/python"
-HOMEPAGE = "https://github.com/phaethon/scapy"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://PKG-INFO;md5=95ea6ecfc360eb47fe6f470ad736d7cd"
-
-inherit pypi setuptools3
-
-PYPI_PACKAGE = "scapy-python3"
-
-SRC_URI[md5sum] = "8642d09ca727e7e2b455223ae94059b7"
-SRC_URI[sha256sum] = "8760991a67162f43af4d9e64828bcefc100ba88859b75177ae9f7ace56e58186"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-scapy_0.25.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-scapy_0.25.bb
new file mode 100644
index 0000000..f785a2f
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-scapy_0.25.bb
@@ -0,0 +1,13 @@
+DESCRIPTION = "Packet crafting/sending/sniffing, PCAP processing tool,\
+based on scapy with python3 compatibility"
+SECTION = "devel/python"
+HOMEPAGE = "https://github.com/phaethon/scapy"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://PKG-INFO;md5=a4282d4d80227fa599a99e77fdd95e71"
+
+inherit pypi setuptools3
+
+PYPI_PACKAGE = "scapy-python3"
+
+SRC_URI[md5sum] = "c9003d39def73c028cb8c71bcbb42629"
+SRC_URI[sha256sum] = "2ae1b3bd9759844e830a6cc3ba11c3f25b08433a8ee3e7eddc08224905e5ef2b"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-semver_2.8.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-semver_2.8.1.bb
new file mode 100644
index 0000000..77925ae
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-semver_2.8.1.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-semver.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-serpent_1.24.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-serpent_1.25.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-serpent_1.24.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-serpent_1.25.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-setuptools-scm_1.15.7.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-setuptools-scm_2.1.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-setuptools-scm_1.15.7.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-setuptools-scm_2.1.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-sh_1.12.14.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-sh_1.12.14.bb
new file mode 100644
index 0000000..812bd4b
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-sh_1.12.14.bb
@@ -0,0 +1,5 @@
+require python-sh.inc
+inherit setuptools3
+
+RDEPENDS_${PN} += " \
+"
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-sijax_0.3.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-sijax_0.3.2.bb
new file mode 100644
index 0000000..24e6833
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-sijax_0.3.2.bb
@@ -0,0 +1,4 @@
+inherit setuptools3
+require python-sijax.inc
+
+SRC_URI[sha256sum] = "11b062f4a8b2aad95c87e7c09e5daf5a6b0d0f08abf9efe5f91a0075c6be7c0d"
\ No newline at end of file
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-simplejson_3.13.2.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-simplejson_3.16.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-simplejson_3.13.2.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-simplejson_3.16.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-stevedore_1.29.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-stevedore_1.29.0.bb
new file mode 100644
index 0000000..3f557f2
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python3-stevedore_1.29.0.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-stevedore.inc
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-tornado_4.5.3.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-tornado_5.1.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-tornado_4.5.3.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-tornado_5.1.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-twisted_17.9.0.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-twisted_18.4.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-twisted_17.9.0.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-twisted_18.4.0.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-urllib3_1.22.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-urllib3_1.23.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-urllib3_1.22.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-urllib3_1.23.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-wtforms_2.1.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-wtforms_2.2.1.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-wtforms_2.1.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-wtforms_2.2.1.bb
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python3-zopeinterface_4.4.3.bb b/meta-openembedded/meta-python/recipes-devtools/python/python3-zopeinterface_4.5.0.bb
similarity index 100%
rename from meta-openembedded/meta-python/recipes-devtools/python/python3-zopeinterface_4.4.3.bb
rename to meta-openembedded/meta-python/recipes-devtools/python/python3-zopeinterface_4.5.0.bb
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0001-comment-out-selinux.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0001-comment-out-selinux.patch
index 0ee3205..c77b86a 100644
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0001-comment-out-selinux.patch
+++ b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0001-comment-out-selinux.patch
@@ -1,7 +1,7 @@
-From 7d483c27ac0a23ca3bba7f320918afc40013bd8e Mon Sep 17 00:00:00 2001
+From 648a18bfc447f076d48ae4147d984b8ef56e37aa Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Mon, 8 May 2017 14:25:52 +0800
-Subject: [PATCH 01/13] comment out selinux
+Date: Mon, 30 Jul 2018 16:13:40 +0800
+Subject: [PATCH 01/11] comment out selinux
 
 Upstream-Status: Inappropriate [oe specific]
 
@@ -12,7 +12,7 @@
  2 files changed, 8 insertions(+), 3 deletions(-)
 
 diff --git a/blivet/flags.py b/blivet/flags.py
-index 06822db..b55a93f 100644
+index 1840121..8789390 100644
 --- a/blivet/flags.py
 +++ b/blivet/flags.py
 @@ -20,7 +20,7 @@
@@ -24,7 +24,7 @@
  
  
  class Flags(object):
-@@ -49,7 +49,8 @@ class Flags(object):
+@@ -47,7 +47,8 @@ class Flags(object):
          #
          # enable/disable functionality
          #
@@ -35,19 +35,19 @@
          self.dmraid = True
          self.ibft = True
 diff --git a/blivet/util.py b/blivet/util.py
-index e3e71ce..0cf5188 100644
+index 7334ff6..0f2a995 100644
 --- a/blivet/util.py
 +++ b/blivet/util.py
-@@ -4,7 +4,7 @@ import glob
+@@ -3,7 +3,7 @@ import functools
+ import glob
  import itertools
  import os
- import shutil
 -import selinux
 +#import selinux
  import subprocess
  import re
  import sys
-@@ -431,6 +431,8 @@ def get_cow_sysfs_path(dev_path, dev_sysfsPath):
+@@ -430,6 +430,8 @@ def get_cow_sysfs_path(dev_path, dev_sysfsPath):
  def match_path_context(path):
      """ Return the default SELinux context for the given path. """
      context = None
@@ -56,7 +56,7 @@
      try:
          context = selinux.matchpathcon(os.path.normpath(path), 0)[1]
      except OSError as e:
-@@ -455,6 +457,8 @@ def set_file_context(path, context, root=None):
+@@ -454,6 +456,8 @@ def set_file_context(path, context, root=None):
  
              True if successful, False if not.
      """
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0002-run_program-support-timeout.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0002-run_program-support-timeout.patch
index 01e71be..fea2254 100644
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0002-run_program-support-timeout.patch
+++ b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0002-run_program-support-timeout.patch
@@ -1,7 +1,7 @@
-From 86744d408b91acdcb086a03d7779fcda152f2ac3 Mon Sep 17 00:00:00 2001
+From 596979ed58109141a7fee680ab95b27296c022b1 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Mon, 8 May 2017 14:39:56 +0800
-Subject: [PATCH 02/13] run_program support timeout
+Subject: [PATCH 02/11] run_program support timeout
 
 Upstream-Status: Pending
 
@@ -11,10 +11,10 @@
  1 file changed, 39 insertions(+), 29 deletions(-)
 
 diff --git a/blivet/util.py b/blivet/util.py
-index 0cf5188..d4bd9bb 100644
+index 0f2a995..05a253c 100644
 --- a/blivet/util.py
 +++ b/blivet/util.py
-@@ -158,6 +158,30 @@ class Path(str):
+@@ -157,6 +157,30 @@ class Path(str):
      def __hash__(self):
          return self._path.__hash__()
  
@@ -45,7 +45,7 @@
  
  def _run_program(argv, root='/', stdin=None, env_prune=None, stderr_to_stdout=False, binary_output=False):
      if env_prune is None:
-@@ -180,36 +204,22 @@ def _run_program(argv, root='/', stdin=None, env_prune=None, stderr_to_stdout=Fa
+@@ -179,36 +203,22 @@ def _run_program(argv, root='/', stdin=None, env_prune=None, stderr_to_stdout=Fa
              stderr_dir = subprocess.STDOUT
          else:
              stderr_dir = subprocess.PIPE
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0003-support-infinit-timeout.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0003-support-infinit-timeout.patch
index 489fb56..38f061e 100644
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0003-support-infinit-timeout.patch
+++ b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0003-support-infinit-timeout.patch
@@ -1,7 +1,7 @@
-From 923265e04df5920fc99393aa05f584032aa1b383 Mon Sep 17 00:00:00 2001
+From 325898f3f2951bbde07da47888175c427b11ddc3 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Mon, 8 May 2017 16:18:02 +0800
-Subject: [PATCH 03/13] support infinit timeout
+Subject: [PATCH 03/11] support infinit timeout
 
 Upstream-Status: Pending
 
@@ -11,10 +11,10 @@
  1 file changed, 8 insertions(+), 4 deletions(-)
 
 diff --git a/blivet/util.py b/blivet/util.py
-index d4bd9bb..44a2da5 100644
+index 05a253c..d6804be 100644
 --- a/blivet/util.py
 +++ b/blivet/util.py
-@@ -158,6 +158,7 @@ class Path(str):
+@@ -157,6 +157,7 @@ class Path(str):
      def __hash__(self):
          return self._path.__hash__()
  
@@ -22,7 +22,7 @@
  def timeout_command(argv, timeout, *args, **kwargs):
      """call shell-command and either return its output or kill it
      if it doesn't normally exit within timeout seconds and return None"""
-@@ -169,7 +170,7 @@ def timeout_command(argv, timeout, *args, **kwargs):
+@@ -168,7 +169,7 @@ def timeout_command(argv, timeout, *args, **kwargs):
          while proc.poll() is None:
              time.sleep(0.1)
              now = datetime.datetime.now()
@@ -31,7 +31,7 @@
                  os.kill(proc.pid, signal.SIGKILL)
                  os.waitpid(-1, os.WNOHANG)
                  program_log.debug("%d seconds timeout" % timeout)
-@@ -183,7 +184,7 @@ def timeout_command(argv, timeout, *args, **kwargs):
+@@ -182,7 +183,7 @@ def timeout_command(argv, timeout, *args, **kwargs):
      program_log.debug("Return code: %d", proc.returncode)
      return (proc.returncode, proc.stdout.read())
  
@@ -40,7 +40,7 @@
      if env_prune is None:
          env_prune = []
  
-@@ -192,7 +193,10 @@ def _run_program(argv, root='/', stdin=None, env_prune=None, stderr_to_stdout=Fa
+@@ -191,7 +192,10 @@ def _run_program(argv, root='/', stdin=None, env_prune=None, stderr_to_stdout=Fa
              os.chroot(root)
  
      with program_log_lock:  # pylint: disable=not-context-manager
@@ -52,7 +52,7 @@
  
          env = os.environ.copy()
          env.update({"LC_ALL": "C",
-@@ -205,7 +209,7 @@ def _run_program(argv, root='/', stdin=None, env_prune=None, stderr_to_stdout=Fa
+@@ -204,7 +208,7 @@ def _run_program(argv, root='/', stdin=None, env_prune=None, stderr_to_stdout=Fa
          else:
              stderr_dir = subprocess.PIPE
  
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0004-Mount-var-volatile-during-install.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0004-Mount-var-volatile-during-install.patch
deleted file mode 100644
index cb837e2..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0004-Mount-var-volatile-during-install.patch
+++ /dev/null
@@ -1,59 +0,0 @@
-From c3959bd00665e24a955bbdbea1ef555e76372f12 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Mon, 8 May 2017 16:25:16 +0800
-Subject: [PATCH 04/13] Mount /var/volatile during install
-
-The installed system needs /var/volatile clean, otherwise it
-caused systemd's journalctl failed to record boot log.
-
-Upstream-Status: Inappropriate [oe specific]
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- blivet/osinstall.py | 9 +++++++++
- 1 file changed, 9 insertions(+)
-
-diff --git a/blivet/osinstall.py b/blivet/osinstall.py
-index a4f9535..61819c2 100644
---- a/blivet/osinstall.py
-+++ b/blivet/osinstall.py
-@@ -294,6 +294,7 @@ class FSSet(object):
-         self._sysfs = None
-         self._proc = None
-         self._devshm = None
-+        self._volatile = None
-         self._usb = None
-         self._selinux = None
-         self._run = None
-@@ -335,6 +336,12 @@ class FSSet(object):
-         return self._devshm
- 
-     @property
-+    def volatile(self):
-+        if not self._volatile:
-+            self._volatile = NoDevice(fmt=get_format("tmpfs", device="tmpfs", mountpoint="/var/volatile"))
-+        return self._volatile
-+
-+    @property
-     def usb(self):
-         if not self._usb:
-             self._usb = NoDevice(fmt=get_format("usbfs", device="usbfs", mountpoint="/proc/bus/usb"))
-@@ -591,6 +598,7 @@ class FSSet(object):
- 
-         devices = list(self.mountpoints.values()) + self.swap_devices
-         devices.extend([self.dev, self.devshm, self.devpts, self.sysfs,
-+                        self.volatile,
-                         self.proc, self.selinux, self.usb, self.run])
-         if isinstance(_platform, EFI):
-             devices.append(self.efivars)
-@@ -650,6 +658,7 @@ class FSSet(object):
-         """ unmount filesystems, except swap if swapoff == False """
-         devices = list(self.mountpoints.values()) + self.swap_devices
-         devices.extend([self.dev, self.devshm, self.devpts, self.sysfs,
-+                        self.volatile,
-                         self.proc, self.usb, self.selinux, self.run])
-         if isinstance(_platform, EFI):
-             devices.append(self.efivars)
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0004-fix-new.roots-object-is-not-iterable.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0004-fix-new.roots-object-is-not-iterable.patch
new file mode 100644
index 0000000..be997ac
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0004-fix-new.roots-object-is-not-iterable.patch
@@ -0,0 +1,28 @@
+From c31df1c0f5323ddc70e0d1c6d11db2fbf7a024ad Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Mon, 8 May 2017 16:30:20 +0800
+Subject: [PATCH 04/11] fix new.roots object is not iterable
+
+Upstream-Status: Pending
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ blivet/blivet.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/blivet/blivet.py b/blivet/blivet.py
+index 3405810..f42b73b 100644
+--- a/blivet/blivet.py
++++ b/blivet/blivet.py
+@@ -1198,7 +1198,7 @@ class Blivet(object):
+             p = partition.disk.format.parted_disk.getPartitionByPath(partition.path)
+             partition.parted_partition = p
+ 
+-        for root in new.roots:
++        for root in new.roots or []:
+             root.swaps = [new.devicetree.get_device_by_id(d.id, hidden=True) for d in root.swaps]
+             root.swaps = [s for s in root.swaps if s]
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0005-fix-incorrect-timeout-while-system-time-changed.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0005-fix-incorrect-timeout-while-system-time-changed.patch
new file mode 100644
index 0000000..ecb9503
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0005-fix-incorrect-timeout-while-system-time-changed.patch
@@ -0,0 +1,48 @@
+From b30a74671ca603e6bfd514f72d4fd7fd6fceef54 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Fri, 26 Aug 2016 02:02:49 -0400
+Subject: [PATCH 05/11] fix incorrect timeout while system time changed
+
+While system time changed by NTP, invoking timeout_command
+breaks with incorrect timeout.
+--------
+|05:40:55,872 INFO program: Running... mount -t ext2 -o
+  defaults,ro /dev/sda2 /mnt/sysimage
+|01:40:55,086 DEBUG program: 10 seconds timeout
+--------
+
+Use numbert count to replace current time count could workaround
+the issue.
+
+Upstream-Status: Pending
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ blivet/util.py | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/blivet/util.py b/blivet/util.py
+index d6804be..bc08af5 100644
+--- a/blivet/util.py
++++ b/blivet/util.py
+@@ -162,14 +162,14 @@ def timeout_command(argv, timeout, *args, **kwargs):
+     """call shell-command and either return its output or kill it
+     if it doesn't normally exit within timeout seconds and return None"""
+     import subprocess, datetime, os, time, signal
+-    start = datetime.datetime.now()
++    count = 0
+ 
+     try:
+         proc = subprocess.Popen(argv, *args, **kwargs)
+         while proc.poll() is None:
+             time.sleep(0.1)
+-            now = datetime.datetime.now()
+-            if timeout != -1 and (now - start).seconds> timeout:
++            count += 1
++            if timeout != -1 and count > timeout*10:
+                 os.kill(proc.pid, signal.SIGKILL)
+                 os.waitpid(-1, os.WNOHANG)
+                 program_log.debug("%d seconds timeout" % timeout)
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0005-update-fstab-by-appending.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0005-update-fstab-by-appending.patch
deleted file mode 100644
index 4f343b7..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0005-update-fstab-by-appending.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From 386ff899763f8473eb93a7a1578fb7cc4f86f66d Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Mon, 8 May 2017 16:28:12 +0800
-Subject: [PATCH 05/13] update fstab by appending
-
-The 'storage.write()' has updated fstab by overwriting
-the original one, we should update fstab by appending
-to keep original tmpfs partitions.
-
-Upstream-Status: Inappropriate [oe specific]
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- blivet/osinstall.py | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/blivet/osinstall.py b/blivet/osinstall.py
-index 61819c2..afa82db 100644
---- a/blivet/osinstall.py
-+++ b/blivet/osinstall.py
-@@ -728,7 +728,7 @@ class FSSet(object):
-         # /etc/fstab
-         fstab_path = os.path.normpath("%s/etc/fstab" % get_sysroot())
-         fstab = self.fstab()
--        open(fstab_path, "w").write(fstab)
-+        open(fstab_path, "a").write(fstab)
- 
-         # /etc/crypttab
-         crypttab_path = os.path.normpath("%s/etc/crypttab" % get_sysroot())
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0006-fix-new.roots-object-is-not-iterable.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0006-fix-new.roots-object-is-not-iterable.patch
deleted file mode 100644
index f5ff754..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0006-fix-new.roots-object-is-not-iterable.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From cd92eea8fab37ba6b0c7f03daa5255343dc75716 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Mon, 8 May 2017 16:30:20 +0800
-Subject: [PATCH 06/13] fix new.roots object is not iterable
-
-Upstream-Status: Pending
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- blivet/blivet.py | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/blivet/blivet.py b/blivet/blivet.py
-index 6a33e9c..79ae91a 100644
---- a/blivet/blivet.py
-+++ b/blivet/blivet.py
-@@ -1761,7 +1761,7 @@ class Blivet(object):
-             p = partition.disk.format.parted_disk.getPartitionByPath(partition.path)
-             partition.parted_partition = p
- 
--        for root in new.roots:
-+        for root in new.roots or []:
-             root.swaps = [new.devicetree.get_device_by_id(d.id, hidden=True) for d in root.swaps]
-             root.swaps = [s for s in root.swaps if s]
- 
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0006-tweak-btrfs-packages.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0006-tweak-btrfs-packages.patch
new file mode 100644
index 0000000..da568a4
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0006-tweak-btrfs-packages.patch
@@ -0,0 +1,45 @@
+From 0659d8a85bcdd76c0b23b8b5af6958783d35ac65 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Mon, 8 May 2017 16:33:15 +0800
+Subject: [PATCH 06/11] tweak btrfs packages
+
+In oe-cre/yocto, we name btrfs package with btrfs-tools,
+rather than btrfs-progs.
+
+Upstream-Status: Inappropriate [oe specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ blivet/devices/btrfs.py | 2 +-
+ blivet/formats/fs.py    | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/blivet/devices/btrfs.py b/blivet/devices/btrfs.py
+index cada940..7e4d4b8 100644
+--- a/blivet/devices/btrfs.py
++++ b/blivet/devices/btrfs.py
+@@ -55,7 +55,7 @@ class BTRFSDevice(StorageDevice):
+ 
+     """ Base class for BTRFS volume and sub-volume devices. """
+     _type = "btrfs"
+-    _packages = ["btrfs-progs"]
++    _packages = ["btrfs-tools"]
+     _external_dependencies = [availability.BLOCKDEV_BTRFS_PLUGIN]
+ 
+     def __init__(self, *args, **kwargs):
+diff --git a/blivet/formats/fs.py b/blivet/formats/fs.py
+index 81e367f..55e5d57 100644
+--- a/blivet/formats/fs.py
++++ b/blivet/formats/fs.py
+@@ -926,7 +926,7 @@ class BTRFS(FS):
+     _formattable = True
+     _linux_native = True
+     _supported = True
+-    _packages = ["btrfs-progs"]
++    _packages = ["btrfs-tools"]
+     _min_size = Size("256 MiB")
+     _max_size = Size("16 EiB")
+     _mkfs_class = fsmkfs.BTRFSMkfs
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0007-fix-incorrect-timeout-while-system-time-changed.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0007-fix-incorrect-timeout-while-system-time-changed.patch
deleted file mode 100644
index 6512d86..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0007-fix-incorrect-timeout-while-system-time-changed.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-From 78ee2b9090f9400ccc4f730e674f5ae972740ccb Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Fri, 26 Aug 2016 02:02:49 -0400
-Subject: [PATCH 07/13] fix incorrect timeout while system time changed
-
-While system time changed by NTP, invoking timeout_command
-breaks with incorrect timeout.
---------
-|05:40:55,872 INFO program: Running... mount -t ext2 -o
-  defaults,ro /dev/sda2 /mnt/sysimage
-|01:40:55,086 DEBUG program: 10 seconds timeout
---------
-
-Use numbert count to replace current time count could workaround
-the issue.
-
-Upstream-Status: Pending
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- blivet/util.py | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/blivet/util.py b/blivet/util.py
-index 44a2da5..b3c45ac 100644
---- a/blivet/util.py
-+++ b/blivet/util.py
-@@ -163,14 +163,14 @@ def timeout_command(argv, timeout, *args, **kwargs):
-     """call shell-command and either return its output or kill it
-     if it doesn't normally exit within timeout seconds and return None"""
-     import subprocess, datetime, os, time, signal
--    start = datetime.datetime.now()
-+    count = 0
- 
-     try:
-         proc = subprocess.Popen(argv, *args, **kwargs)
-         while proc.poll() is None:
-             time.sleep(0.1)
--            now = datetime.datetime.now()
--            if timeout != -1 and (now - start).seconds> timeout:
-+            count += 1
-+            if timeout != -1 and count > timeout*10:
-                 os.kill(proc.pid, signal.SIGKILL)
-                 os.waitpid(-1, os.WNOHANG)
-                 program_log.debug("%d seconds timeout" % timeout)
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0007-invoking-mount-with-infinite-timeout.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0007-invoking-mount-with-infinite-timeout.patch
new file mode 100644
index 0000000..e301219
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0007-invoking-mount-with-infinite-timeout.patch
@@ -0,0 +1,31 @@
+From 9c7a15312259854f12137a30229e52c30fb7c770 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Wed, 31 Aug 2016 21:30:32 -0400
+Subject: [PATCH 07/11] invoking mount with infinite timeout
+
+This large timeout is needed when running on machines with
+lots of disks, or with slow disks.
+
+Upstream-Status: Pending
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ blivet/util.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/blivet/util.py b/blivet/util.py
+index bc08af5..b672787 100644
+--- a/blivet/util.py
++++ b/blivet/util.py
+@@ -256,7 +256,7 @@ def mount(device, mountpoint, fstype, options=None):
+ 
+     argv = ["mount", "-t", fstype, "-o", options, device, mountpoint]
+     try:
+-        rc = run_program(argv)
++        rc = run_program(argv, timeout=-1)
+     except OSError:
+         raise
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0008-tweak-btrfs-packages.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0008-tweak-btrfs-packages.patch
deleted file mode 100644
index 121336e..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0008-tweak-btrfs-packages.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-From 6f661a511eea096c073888c7adb836a9a880b476 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Mon, 8 May 2017 16:33:15 +0800
-Subject: [PATCH 08/13] tweak btrfs packages
-
-In oe-cre/yocto, we name btrfs package with btrfs-tools,
-rather than btrfs-progs.
-
-Upstream-Status: Inappropriate [oe specific]
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- blivet/devices/btrfs.py | 2 +-
- blivet/formats/fs.py    | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/blivet/devices/btrfs.py b/blivet/devices/btrfs.py
-index c5cb21f..9d417b2 100644
---- a/blivet/devices/btrfs.py
-+++ b/blivet/devices/btrfs.py
-@@ -55,7 +55,7 @@ class BTRFSDevice(StorageDevice):
- 
-     """ Base class for BTRFS volume and sub-volume devices. """
-     _type = "btrfs"
--    _packages = ["btrfs-progs"]
-+    _packages = ["btrfs-tools"]
-     _external_dependencies = [availability.BLOCKDEV_BTRFS_PLUGIN]
- 
-     def __init__(self, *args, **kwargs):
-diff --git a/blivet/formats/fs.py b/blivet/formats/fs.py
-index a49826f..e8f216d 100644
---- a/blivet/formats/fs.py
-+++ b/blivet/formats/fs.py
-@@ -918,7 +918,7 @@ class BTRFS(FS):
-     _formattable = True
-     _linux_native = True
-     _supported = True
--    _packages = ["btrfs-progs"]
-+    _packages = ["btrfs-tools"]
-     _min_size = Size("256 MiB")
-     _max_size = Size("16 EiB")
-     _mkfs_class = fsmkfs.BTRFSMkfs
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0008-use-oe-variable-to-replace-hardcoded-dir.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0008-use-oe-variable-to-replace-hardcoded-dir.patch
new file mode 100644
index 0000000..feb5647
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0008-use-oe-variable-to-replace-hardcoded-dir.patch
@@ -0,0 +1,34 @@
+From 7f57b2cd145d67c20beb02d5495b502f7af012cd Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Mon, 8 May 2017 03:54:12 -0400
+Subject: [PATCH 08/11] use oe variable to replace hardcoded dir
+
+Upstream-Status: Pending
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ setup.py | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/setup.py b/setup.py
+index 7edab2c..9be3187 100644
+--- a/setup.py
++++ b/setup.py
+@@ -61,10 +61,10 @@ class blivet_sdist(sdist):
+ 
+ 
+ data_files = [
+-    ('/etc/dbus-1/system.d', ['dbus/blivet.conf']),
+-    ('/usr/share/dbus-1/system-services', ['dbus/com.redhat.Blivet1.service']),
+-    ('/usr/libexec', ['dbus/blivetd']),
+-    ('/usr/lib/systemd/system', ['dbus/blivet.service'])
++    (os.environ.get('sysconfdir')+'/dbus-1/system.d', ['dbus/blivet.conf']),
++    (os.environ.get('datadir')+'/dbus-1/system-services', ['dbus/com.redhat.Blivet1.service']),
++    (os.environ.get('libexecdir'), ['dbus/blivetd']),
++    (os.environ.get('systemd_system_unitdir'), ['dbus/blivet.service'])
+ ]
+ 
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0009-invoking-fsck-with-infinite-timeout.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0009-invoking-fsck-with-infinite-timeout.patch
new file mode 100644
index 0000000..30d2d3e
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0009-invoking-fsck-with-infinite-timeout.patch
@@ -0,0 +1,31 @@
+From c757666f42f543baeed5df61269798c085665d9b Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 1 Jun 2017 16:05:27 +0800
+Subject: [PATCH 09/11] invoking fsck with infinite timeout
+
+This large timeout is needed when running on machines with
+lots of disks, or with slow disks.
+
+Upstream-Status: Pending
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ blivet/tasks/fsck.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/blivet/tasks/fsck.py b/blivet/tasks/fsck.py
+index 5274f13..6e074c4 100644
+--- a/blivet/tasks/fsck.py
++++ b/blivet/tasks/fsck.py
+@@ -77,7 +77,7 @@ class FSCK(task.BasicApplication, fstask.FSTask):
+             raise FSError("\n".join(error_msgs))
+ 
+         try:
+-            rc = util.run_program(self._fsck_command)
++            rc = util.run_program(self._fsck_command, timeout=-1)
+         except OSError as e:
+             raise FSError("filesystem check failed: %s" % e)
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0009-invoking-mount-with-infinite-timeout.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0009-invoking-mount-with-infinite-timeout.patch
deleted file mode 100644
index fc084b1..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0009-invoking-mount-with-infinite-timeout.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From a6ac2157ee6793302e23ddbc5e3b249fa7da5b7e Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Wed, 31 Aug 2016 21:30:32 -0400
-Subject: [PATCH 09/13] invoking mount with infinite timeout
-
-This large timeout is needed when running on machines with
-lots of disks, or with slow disks.
-
-Upstream-Status: Pending
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- blivet/util.py | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/blivet/util.py b/blivet/util.py
-index b3c45ac..9f02b18 100644
---- a/blivet/util.py
-+++ b/blivet/util.py
-@@ -257,7 +257,7 @@ def mount(device, mountpoint, fstype, options=None):
- 
-     argv = ["mount", "-t", fstype, "-o", options, device, mountpoint]
-     try:
--        rc = run_program(argv)
-+        rc = run_program(argv, timeout=-1)
-     except OSError:
-         raise
- 
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0010-invoking-mkfs-with-infinite-timeout.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0010-invoking-mkfs-with-infinite-timeout.patch
new file mode 100644
index 0000000..b2f4501
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0010-invoking-mkfs-with-infinite-timeout.patch
@@ -0,0 +1,31 @@
+From 42d8e57c748951098534bf7f52c4ebc790ef66e9 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Fri, 16 Jun 2017 15:43:00 +0800
+Subject: [PATCH 10/11] invoking mkfs with infinite timeout
+
+This large timeout is needed when running on machines with
+lots of disks, or with slow disks.
+
+Upstream-Status: Pending
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ blivet/tasks/fsmkfs.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/blivet/tasks/fsmkfs.py b/blivet/tasks/fsmkfs.py
+index ad166aa..7bf5075 100644
+--- a/blivet/tasks/fsmkfs.py
++++ b/blivet/tasks/fsmkfs.py
+@@ -170,7 +170,7 @@ class FSMkfs(task.BasicApplication, FSMkfsTask):
+         options = options or []
+         cmd = self._mkfs_command(options, label, set_uuid)
+         try:
+-            ret = util.run_program(cmd)
++            ret = util.run_program(cmd, timeout=-1)
+         except OSError as e:
+             raise FSError(e)
+ 
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0010-use-oe-variable-to-replace-hardcoded-dir.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0010-use-oe-variable-to-replace-hardcoded-dir.patch
deleted file mode 100644
index 45d8fab..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0010-use-oe-variable-to-replace-hardcoded-dir.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From e07133dbcf3c52e1ddd2f12797dcd16145269273 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Mon, 8 May 2017 03:54:12 -0400
-Subject: [PATCH 10/13] use oe variable to replace hardcoded dir
-
-Upstream-Status: Pending
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- setup.py | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/setup.py b/setup.py
-index 4d06a33..a994d06 100644
---- a/setup.py
-+++ b/setup.py
-@@ -61,10 +61,10 @@ class blivet_sdist(sdist):
- 
- 
- data_files = [
--    ('/etc/dbus-1/system.d', ['dbus/blivet.conf']),
--    ('/usr/share/dbus-1/system-services', ['dbus/com.redhat.Blivet1.service']),
--    ('/usr/libexec', ['dbus/blivetd']),
--    ('/usr/lib/systemd/system', ['dbus/blivet.service'])
-+    (os.environ.get('sysconfdir')+'/dbus-1/system.d', ['dbus/blivet.conf']),
-+    (os.environ.get('datadir')+'/dbus-1/system-services', ['dbus/com.redhat.Blivet1.service']),
-+    (os.environ.get('libexecdir'), ['dbus/blivetd']),
-+    (os.environ.get('systemd_system_unitdir'), ['dbus/blivet.service'])
- ]
- 
- 
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0011-invoking-dd-with-infinite-timeout.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0011-invoking-dd-with-infinite-timeout.patch
new file mode 100644
index 0000000..f24ce0a
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0011-invoking-dd-with-infinite-timeout.patch
@@ -0,0 +1,31 @@
+From a4753b3cbbd5aee59dc53eb16564cafd9862763e Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Tue, 6 Mar 2018 17:28:56 +0800
+Subject: [PATCH 11/11] invoking dd with infinite timeout
+
+This large timeout is needed when running on machines with
+lots of disks, or with slow disks.
+
+Upstream-Status: Pending
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ blivet/devices/partition.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/blivet/devices/partition.py b/blivet/devices/partition.py
+index 47ff547..0cd1614 100644
+--- a/blivet/devices/partition.py
++++ b/blivet/devices/partition.py
+@@ -621,7 +621,7 @@ class PartitionDevice(StorageDevice):
+         cmd = ["dd", "if=/dev/zero", "of=%s" % device, "bs=%d" % bs,
+                "seek=%d" % start, "count=%d" % count]
+         try:
+-            util.run_program(cmd)
++            util.run_program(cmd, timeout=-1)
+         except OSError as e:
+             log.error(str(e))
+         finally:
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0011-invoking-fsck-with-infinite-timeout.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0011-invoking-fsck-with-infinite-timeout.patch
deleted file mode 100644
index c61fe01..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0011-invoking-fsck-with-infinite-timeout.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From e9ab4376a18cc1bd413c000b036320833eec80d7 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Thu, 1 Jun 2017 16:05:27 +0800
-Subject: [PATCH 11/13] invoking fsck with infinite timeout
-
-This large timeout is needed when running on machines with
-lots of disks, or with slow disks.
-
-Upstream-Status: Pending
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- blivet/tasks/fsck.py | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/blivet/tasks/fsck.py b/blivet/tasks/fsck.py
-index c4214dc..e13ac6b 100644
---- a/blivet/tasks/fsck.py
-+++ b/blivet/tasks/fsck.py
-@@ -77,7 +77,7 @@ class FSCK(task.BasicApplication, fstask.FSTask):
-             raise FSError("\n".join(error_msgs))
- 
-         try:
--            rc = util.run_program(self._fsck_command)
-+            rc = util.run_program(self._fsck_command, timeout=-1)
-         except OSError as e:
-             raise FSError("filesystem check failed: %s" % e)
- 
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0012-invoking-mkfs-with-infinite-timeout.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0012-invoking-mkfs-with-infinite-timeout.patch
deleted file mode 100644
index 33bdbe8..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0012-invoking-mkfs-with-infinite-timeout.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 9f5a048181cf29d241d96814e736b8235b3d42b1 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Fri, 16 Jun 2017 15:43:00 +0800
-Subject: [PATCH 12/13] invoking mkfs with infinite timeout
-
-This large timeout is needed when running on machines with
-lots of disks, or with slow disks.
-
-Upstream-Status: Pending
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- blivet/tasks/fsmkfs.py | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/blivet/tasks/fsmkfs.py b/blivet/tasks/fsmkfs.py
-index ad166aa..7bf5075 100644
---- a/blivet/tasks/fsmkfs.py
-+++ b/blivet/tasks/fsmkfs.py
-@@ -170,7 +170,7 @@ class FSMkfs(task.BasicApplication, FSMkfsTask):
-         options = options or []
-         cmd = self._mkfs_command(options, label, set_uuid)
-         try:
--            ret = util.run_program(cmd)
-+            ret = util.run_program(cmd, timeout=-1)
-         except OSError as e:
-             raise FSError(e)
- 
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0012-remove-dmraid-dependency-check.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0012-remove-dmraid-dependency-check.patch
new file mode 100644
index 0000000..886e3ff
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0012-remove-dmraid-dependency-check.patch
@@ -0,0 +1,31 @@
+From 4476e846a1e64dde17df2e2370c803ce695514f9 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Mon, 6 Aug 2018 17:18:27 +0800
+Subject: [PATCH] remove dmraid dependency check
+
+OE does not support dmraid, remove it from dependency check
+
+Upstream-Status: Inappropriate [oe specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ blivet/tasks/availability.py | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+diff --git a/blivet/tasks/availability.py b/blivet/tasks/availability.py
+index 9a87cfd..843cf6a 100644
+--- a/blivet/tasks/availability.py
++++ b/blivet/tasks/availability.py
+@@ -316,8 +316,7 @@ BLOCKDEV_DM_ALL_MODES = (blockdev.DMTechMode.CREATE_ACTIVATE |
+                          blockdev.DMTechMode.QUERY)
+ BLOCKDEV_DM = BlockDevTechInfo(plugin_name="dm",
+                                check_fn=blockdev.dm_is_tech_avail,
+-                               technologies={blockdev.DMTech.MAP: BLOCKDEV_DM_ALL_MODES,
+-                                             blockdev.DMTech.RAID: BLOCKDEV_DM_ALL_MODES})
++                               technologies={blockdev.DMTech.MAP: BLOCKDEV_DM_ALL_MODES})
+ BLOCKDEV_DM_TECH = BlockDevMethod(BLOCKDEV_DM)
+ 
+ # libblockdev loop plugin required technologies and modes
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0013-Revert-Adapt-to-logging-module-name-change.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0013-Revert-Adapt-to-logging-module-name-change.patch
deleted file mode 100644
index 6bdf4ce..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0013-Revert-Adapt-to-logging-module-name-change.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From bfdaf79a2109ac6aed408f0c94f69766991e60e2 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Thu, 27 Jul 2017 14:34:30 +0800
-Subject: [PATCH 13/13] Revert "Adapt to logging module name change"
-
-Upstream-Status: Inappropriate [oe specific, sync with anaconda f26-release]
-
-This reverts commit c367d62a516e541ad28636c8259321f1c53417ce.
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- blivet/__init__.py | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/blivet/__init__.py b/blivet/__init__.py
-index 49277cb..a01e487 100644
---- a/blivet/__init__.py
-+++ b/blivet/__init__.py
-@@ -124,7 +124,7 @@ def enable_installer_mode():
-         from pyanaconda.constants import ROOT_PATH  # pylint: disable=redefined-outer-name,no-name-in-module
-         _storage_root = _sysroot = ROOT_PATH
- 
--    from pyanaconda.anaconda_logging import program_log_lock
-+    from pyanaconda.anaconda_log import program_log_lock
-     util.program_log_lock = program_log_lock
- 
-     flags.installer_mode = True
--- 
-2.7.4
-
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0013-add-Z-y-and-y-to-lvm.pvcreate.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0013-add-Z-y-and-y-to-lvm.pvcreate.patch
new file mode 100644
index 0000000..33b5f51
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0013-add-Z-y-and-y-to-lvm.pvcreate.patch
@@ -0,0 +1,41 @@
+From bddbfa499df16b108f2d892ee48d65617523c33d Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 9 Aug 2018 11:00:39 +0800
+Subject: [PATCH] add `-Z y' and `-y' to lvm.pvcreate
+
+While reinstall a crypt fs, it occasionally failed
+[snip]
+|gi.overrides.BlockDev.LVMError: Process reported exit code 5:
+WARNING: atari signature detected on /dev/mapper/luks-0e5f891c
+-7701-48bc-a41e-8d626b6ef953 at offset 466. Wipe it? [y/n]:
+[snip]
+
+Add `-Z y' and `-y' to lvm.pvcreate
+
+Upstream-Status: Submitted [https://github.com/storaged-project/blivet/pull/714]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ blivet/formats/lvmpv.py | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/blivet/formats/lvmpv.py b/blivet/formats/lvmpv.py
+index 260cc0b..4bbb46f 100644
+--- a/blivet/formats/lvmpv.py
++++ b/blivet/formats/lvmpv.py
+@@ -120,9 +120,9 @@ class LVMPhysicalVolume(DeviceFormat):
+         log_method_call(self, device=self.device,
+                         type=self.type, status=self.status)
+ 
+-        # Consider use of -Z|--zero
+-        # -f|--force or -y|--yes may be required
+-        blockdev.lvm.pvcreate(self.device, data_alignment=self.data_alignment)
++        ea_zero = blockdev.ExtraArg.new("-Z", "y")
++        ea_yes = blockdev.ExtraArg.new("-y", "")
++        blockdev.lvm.pvcreate(self.device, data_alignment=self.data_alignment, extra=[ea_zero, ea_yes])
+ 
+     def _destroy(self, **kwargs):
+         log_method_call(self, device=self.device,
+-- 
+2.7.4
+
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0014-invoking-dd-with-infinite-timeout.patch b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0014-invoking-dd-with-infinite-timeout.patch
deleted file mode 100644
index 12a9e4f..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet/0014-invoking-dd-with-infinite-timeout.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 92fe7dfd01131c93a9b2013cabf77d5f46900fab Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Tue, 6 Mar 2018 17:28:56 +0800
-Subject: [PATCH] invoking dd with infinite timeout
-
-This large timeout is needed when running on machines with
-lots of disks, or with slow disks.
-
-Upstream-Status: Pending
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- blivet/devices/partition.py | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/blivet/devices/partition.py b/blivet/devices/partition.py
-index a7372fb..8947472 100644
---- a/blivet/devices/partition.py
-+++ b/blivet/devices/partition.py
-@@ -594,7 +594,7 @@ class PartitionDevice(StorageDevice):
-         cmd = ["dd", "if=/dev/zero", "of=%s" % device, "bs=%d" % bs,
-                "seek=%d" % start, "count=%d" % count]
-         try:
--            util.run_program(cmd)
-+            util.run_program(cmd, timeout=-1)
-         except OSError as e:
-             log.error(str(e))
-         finally:
--- 
-1.8.3.1
-
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet_2.2.0.bb b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet_2.2.0.bb
deleted file mode 100644
index 46dc32d..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet_2.2.0.bb
+++ /dev/null
@@ -1,47 +0,0 @@
-DESCRIPTION = "A python module for system storage configuration"
-HOMEPAGE = "http://fedoraproject.org/wiki/blivet"
-LICENSE = "LGPLv2+"
-SECTION = "devel/python"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-
-S = "${WORKDIR}/git"
-B = "${S}"
-
-SRCREV = "39db82f20d8d4904c0c4dc8912e595177c59e091"
-SRC_URI = "git://github.com/rhinstaller/blivet;branch=2.2-devel \
-           file://0001-comment-out-selinux.patch \
-           file://0002-run_program-support-timeout.patch\
-           file://0003-support-infinit-timeout.patch \
-           file://0004-Mount-var-volatile-during-install.patch \
-           file://0005-update-fstab-by-appending.patch \
-           file://0006-fix-new.roots-object-is-not-iterable.patch \
-           file://0007-fix-incorrect-timeout-while-system-time-changed.patch \
-           file://0008-tweak-btrfs-packages.patch \
-           file://0009-invoking-mount-with-infinite-timeout.patch \
-           file://0010-use-oe-variable-to-replace-hardcoded-dir.patch \
-           file://0011-invoking-fsck-with-infinite-timeout.patch \
-           file://0012-invoking-mkfs-with-infinite-timeout.patch \
-           file://0013-Revert-Adapt-to-logging-module-name-change.patch \
-           file://0014-invoking-dd-with-infinite-timeout.patch \
-"
-
-inherit distro_features_check
-REQUIRED_DISTRO_FEATURES = "systemd"
-
-inherit setuptools3 python3native
-
-RDEPENDS_${PN} = "python3-pykickstart python3-pyudev \
-                  parted python3-pyparted multipath-tools \
-                  lsof cryptsetup libblockdev \
-                  libbytesize \
-"
-
-FILES_${PN} += " \
-    ${datadir}/dbus-1/system-services \
-"
-
-inherit systemd
-
-SYSTEMD_AUTO_ENABLE = "disable"
-SYSTEMD_SERVICE_${PN} = "blivet.service"
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet_3.0.1.bb b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet_3.0.1.bb
new file mode 100644
index 0000000..75f02f1
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivet_3.0.1.bb
@@ -0,0 +1,48 @@
+DESCRIPTION = "A python module for system storage configuration"
+HOMEPAGE = "http://fedoraproject.org/wiki/blivet"
+LICENSE = "LGPLv2+"
+SECTION = "devel/python"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+S = "${WORKDIR}/git"
+B = "${S}"
+
+SRCREV = "ddc24c71bad10208b11ea0c45853898fadd7030b"
+SRC_URI = "git://github.com/rhinstaller/blivet;branch=3.1-release \
+           file://0001-comment-out-selinux.patch \
+           file://0002-run_program-support-timeout.patch \
+           file://0003-support-infinit-timeout.patch \
+           file://0004-fix-new.roots-object-is-not-iterable.patch \
+           file://0005-fix-incorrect-timeout-while-system-time-changed.patch \
+           file://0006-tweak-btrfs-packages.patch \
+           file://0007-invoking-mount-with-infinite-timeout.patch \
+           file://0008-use-oe-variable-to-replace-hardcoded-dir.patch \
+           file://0009-invoking-fsck-with-infinite-timeout.patch \
+           file://0010-invoking-mkfs-with-infinite-timeout.patch \
+           file://0011-invoking-dd-with-infinite-timeout.patch \
+           file://0012-remove-dmraid-dependency-check.patch \
+           file://0013-add-Z-y-and-y-to-lvm.pvcreate.patch \
+"
+
+UPSTREAM_CHECK_GITTAGREGEX = "blivet-(?P<pver>\d+(\.\d+)+)$"
+
+inherit distro_features_check
+REQUIRED_DISTRO_FEATURES = "systemd"
+
+inherit setuptools3 python3native
+
+RDEPENDS_${PN} = "python3-pykickstart python3-pyudev \
+                  parted python3-pyparted multipath-tools \
+                  lsof cryptsetup libblockdev \
+                  libbytesize \
+"
+
+FILES_${PN} += " \
+    ${datadir}/dbus-1/system-services \
+"
+
+inherit systemd
+
+SYSTEMD_AUTO_ENABLE = "disable"
+SYSTEMD_SERVICE_${PN} = "blivet.service"
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivetgui_2.1.5.bb b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivetgui_2.1.5.bb
deleted file mode 100644
index 28c2565..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivetgui_2.1.5.bb
+++ /dev/null
@@ -1,27 +0,0 @@
-DESCRIPTION = "GUI tool for storage configuration using blivet library"
-HOMEPAGE = "https://github.com/rhinstaller/blivet-gui"
-LICENSE = "GPLv2+"
-SECTION = "devel/python"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-
-S = "${WORKDIR}/git"
-B = "${S}"
-
-SRCREV = "52ae8c000843c05abd1d8749f44bbe2e5d891d3d"
-SRC_URI = "git://github.com/rhinstaller/blivet-gui;branch=master \
-"
-
-inherit distro_features_check
-REQUIRED_DISTRO_FEATURES = "x11 systemd"
-
-inherit setuptools3 python3native
-
-RDEPENDS_${PN} = "python3-pygobject python3 \
-                  python3-blivet gtk+3  \
-                  python3-pid libreport \
-"
-
-FILES_${PN} += " \
-    ${datadir}/* \
-    "
diff --git a/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivetgui_2.1.8.bb b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivetgui_2.1.8.bb
new file mode 100644
index 0000000..91f0dff
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/python-blivet/python3-blivetgui_2.1.8.bb
@@ -0,0 +1,27 @@
+DESCRIPTION = "GUI tool for storage configuration using blivet library"
+HOMEPAGE = "https://github.com/rhinstaller/blivet-gui"
+LICENSE = "GPLv2+"
+SECTION = "devel/python"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+S = "${WORKDIR}/git"
+B = "${S}"
+
+SRCREV = "a4fd427ee2acc5a8f5fb030bf7816917cee63bd8"
+SRC_URI = "git://github.com/rhinstaller/blivet-gui;branch=master \
+"
+
+inherit distro_features_check
+REQUIRED_DISTRO_FEATURES = "x11 systemd"
+
+inherit setuptools3 python3native
+
+RDEPENDS_${PN} = "python3-pygobject python3 \
+                  python3-blivet gtk+3  \
+                  python3-pid libreport \
+"
+
+FILES_${PN} += " \
+    ${datadir}/* \
+    "
diff --git a/meta-openembedded/meta-python/recipes-extended/python-meh/python3-meh_0.46.bb b/meta-openembedded/meta-python/recipes-extended/python-meh/python3-meh_0.46.bb
deleted file mode 100644
index 40e2cbd..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-meh/python3-meh_0.46.bb
+++ /dev/null
@@ -1,17 +0,0 @@
-SUMMARY = "A python library for handling exceptions"
-DESCRIPTION = "The python-meh package is a python library for handling, saving, and reporting \
-exceptions."
-HOMEPAGE = "http://git.fedorahosted.org/git/?p=python-meh.git"
-LICENSE = "GPLv2+"
-
-inherit setuptools3
-
-S = "${WORKDIR}/git"
-
-SRC_URI = "git://github.com/rhinstaller/python-meh.git;protocol=https;branch=master \
-"
-SRCREV = "bb1156728a4f76e5e3638ab20b9454a1568a99db"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-
-FILES_${PN} += "${datadir}/*"
-
diff --git a/meta-openembedded/meta-python/recipes-extended/python-meh/python3-meh_0.47.bb b/meta-openembedded/meta-python/recipes-extended/python-meh/python3-meh_0.47.bb
new file mode 100644
index 0000000..95d6d18
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/python-meh/python3-meh_0.47.bb
@@ -0,0 +1,17 @@
+SUMMARY = "A python library for handling exceptions"
+DESCRIPTION = "The python-meh package is a python library for handling, saving, and reporting \
+exceptions."
+HOMEPAGE = "http://git.fedorahosted.org/git/?p=python-meh.git"
+LICENSE = "GPLv2+"
+
+inherit setuptools3
+
+S = "${WORKDIR}/git"
+
+SRC_URI = "git://github.com/rhinstaller/python-meh.git;protocol=https;branch=master \
+"
+SRCREV = "78d868d99104317ce8820f39f61d207566e61a55"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+FILES_${PN} += "${datadir}/*"
+
diff --git a/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0001-support-authentication-for-kickstart.patch b/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0001-support-authentication-for-kickstart.patch
index 617699d..e7533f4 100644
--- a/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0001-support-authentication-for-kickstart.patch
+++ b/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0001-support-authentication-for-kickstart.patch
@@ -1,6 +1,6 @@
-From d0d8890b5ef74c315381c9e1cff4b1d32892116b Mon Sep 17 00:00:00 2001
+From f05f5fc363e2510f6943532f3e14a6423f6a2cf1 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Thu, 1 Jun 2017 15:07:36 +0800
+Date: Tue, 31 Jul 2018 17:24:47 +0800
 Subject: [PATCH 1/4] support authentication for kickstart
 
 While download kickstart file from web server,
@@ -13,30 +13,29 @@
 
 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
- pykickstart/errors.py | 19 +++++++++++++++++++
- pykickstart/load.py   | 32 +++++++++++++++++++++++++++-----
+ pykickstart/errors.py | 17 +++++++++++++++++
+ pykickstart/load.py   | 34 ++++++++++++++++++++++++++++------
  pykickstart/parser.py |  4 ++--
- 3 files changed, 48 insertions(+), 7 deletions(-)
+ 3 files changed, 47 insertions(+), 8 deletions(-)
 
 diff --git a/pykickstart/errors.py b/pykickstart/errors.py
-index b76e84c..fd81bc8 100644
+index bf08ac5..aada7aa 100644
 --- a/pykickstart/errors.py
 +++ b/pykickstart/errors.py
-@@ -35,6 +35,10 @@ It also exports several exception classes:
- 
+@@ -32,6 +32,9 @@ This module exports several exception classes:
      KickstartVersionError - An exception for errors relating to unsupported
                              syntax versions.
-+
+ 
 +    KickstartAuthError - An exception for errors relating to authentication
 +                         failed while downloading kickstart from web server
 +
- """
- import warnings
+ And some warning classes:
  
-@@ -103,3 +107,18 @@ class KickstartVersionError(KickstartError):
- 
-     def __str__ (self):
-         return self.value
+     KickstartWarning - A generic warning class.
+@@ -131,3 +134,17 @@ class KickstartDeprecationWarning(KickstartParseWarning, DeprecationWarning):
+        commands and options.
+     """
+     pass
 +
 +class KickstartAuthError(KickstartError):
 +    """An exception for errors relating to authentication failed while
@@ -51,9 +50,8 @@
 +
 +    def __str__(self):
 +        return self.value
-+
 diff --git a/pykickstart/load.py b/pykickstart/load.py
-index 1f69b9c..0f5741b 100644
+index fb935f2..41a2e9e 100644
 --- a/pykickstart/load.py
 +++ b/pykickstart/load.py
 @@ -18,10 +18,13 @@
@@ -71,7 +69,7 @@
  from pykickstart.i18n import _
  from requests.exceptions import SSLError, RequestException
  
-@@ -29,7 +32,7 @@ _is_url = lambda location: '://' in location # RFC 3986
+@@ -29,7 +32,7 @@ _is_url = lambda location: '://' in location  # RFC 3986
  
  SSL_VERIFY = True
  
@@ -89,10 +87,12 @@
      else:
          return _load_file(location)
  
-@@ -71,13 +74,32 @@ def load_to_file(location, destination):
+@@ -70,11 +73,30 @@ def load_to_file(location, destination):
          _copy_file(location, destination)
          return destination
  
+-def _load_url(location):
+-    '''Load a location (URL or filename) and return contents as string'''
 +def _get_auth(location, user=None, passwd=None):
 +
 +    auth = None
@@ -109,15 +109,12 @@
 +            auth = HTTPBasicAuth(user, passwd)
 +        elif auth_type == "Digest":
 +            auth=HTTPDigestAuth(user, passwd)
- 
--def _load_url(location):
++
 +    return auth
 +
 +def _load_url(location, user=None, passwd=None):
-     '''Load a location (URL or filename) and return contents as string'''
- 
++    '''Load a location (URL or filename) and return contents as string'''
 +    auth = _get_auth(location, user=user, passwd=passwd)
-+
      try:
 -        request = requests.get(location, verify=SSL_VERIFY)
 +        request = requests.get(location, verify=SSL_VERIFY, auth=auth)
@@ -125,26 +122,26 @@
          raise KickstartError(_('Error securely accessing URL "%s"') % location + ': {e}'.format(e=str(e)))
      except RequestException as e:
 diff --git a/pykickstart/parser.py b/pykickstart/parser.py
-index d2b0fbe..26b5de9 100644
+index d8880eb..22d14cb 100644
 --- a/pykickstart/parser.py
 +++ b/pykickstart/parser.py
-@@ -773,7 +773,7 @@ class KickstartParser(object):
+@@ -787,7 +787,7 @@ class KickstartParser(object):
          i = PutBackIterator(s.splitlines(True) + [""])
-         self._stateMachine (i)
+         self._stateMachine(i)
  
 -    def readKickstart(self, f, reset=True):
 +    def readKickstart(self, f, reset=True, username=None, password=None):
          """Process a kickstart file, given by the filename f."""
          if reset:
              self._reset()
-@@ -794,7 +794,7 @@ class KickstartParser(object):
+@@ -808,7 +808,7 @@ class KickstartParser(object):
          self.currentdir[self._includeDepth] = cd
  
          try:
 -            s = load_to_str(f)
 +            s = load_to_str(f, user=username, passwd=password)
          except KickstartError as e:
-             raise KickstartError(formatErrorMsg(0, msg=_("Unable to open input kickstart file: %s") % str(e)))
+             raise KickstartError(_("Unable to open input kickstart file: %s") % str(e), lineno=0)
  
 -- 
 2.7.4
diff --git a/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0002-pykickstart-parser.py-add-lock-for-readKickstart-and.patch b/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0002-pykickstart-parser.py-add-lock-for-readKickstart-and.patch
index cb21235..4a001f3 100644
--- a/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0002-pykickstart-parser.py-add-lock-for-readKickstart-and.patch
+++ b/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0002-pykickstart-parser.py-add-lock-for-readKickstart-and.patch
@@ -1,28 +1,26 @@
-From e6e747b883114bfad51ad93f823e65f5a4d6438a Mon Sep 17 00:00:00 2001
+From 62fdead139edb0f29b2f222efcb8f39be15b057e Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Thu, 1 Jun 2017 15:12:29 +0800
-Subject: [PATCH 2/4] pykickstart/parser.py: add lock for readKickstart and
+Date: Mon, 30 Jul 2018 15:47:13 +0800
+Subject: [PATCH 2/4] pykickstart/parser.py: add lock for readKickstart and 
  support https without certification
 
 - Add lock for readKickstart to fix race issue
 
 - Support to download kickstart file through https without certification
 
-Upstream-Status: Inappropriate[oe specific]
-
 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
  pykickstart/load.py   |  2 +-
- pykickstart/parser.py | 24 ++++++++++++++++++++++++
- 2 files changed, 25 insertions(+), 1 deletion(-)
+ pykickstart/parser.py | 18 ++++++++++++++++++
+ 2 files changed, 19 insertions(+), 1 deletion(-)
 
 diff --git a/pykickstart/load.py b/pykickstart/load.py
-index 0f5741b..48c8276 100644
+index c6f013f..7adb751 100644
 --- a/pykickstart/load.py
 +++ b/pykickstart/load.py
 @@ -30,7 +30,7 @@ from requests.exceptions import SSLError, RequestException
  
- _is_url = lambda location: '://' in location # RFC 3986
+ _is_url = lambda location: '://' in location  # RFC 3986
  
 -SSL_VERIFY = True
 +SSL_VERIFY = False
@@ -30,38 +28,32 @@
  def load_to_str(location, user=None, passwd=None):
      '''Load a destination URL or file into a string.
 diff --git a/pykickstart/parser.py b/pykickstart/parser.py
-index 26b5de9..264ba05 100644
+index e44099b..e68174d 100644
 --- a/pykickstart/parser.py
 +++ b/pykickstart/parser.py
-@@ -57,6 +57,26 @@ STATE_COMMANDS = "commands"
+@@ -55,6 +55,20 @@ from pykickstart.i18n import _
+ STATE_END = "end"
+ STATE_COMMANDS = "commands"
  
- ver = version.DEVEL
- 
-+import logging
-+log = logging.getLogger("anaconda")
-+
-+import inspect
 +import threading
 +_private_ks_lock = threading.RLock()
 +
 +class KsLock(object):
 +    def __enter__(self):
-+        log.info("%s %s" % (self.__class__.__name__, inspect.stack()[0][3]))
 +        _private_ks_lock.acquire()
 +        return _private_ks_lock
 +
 +    def __exit__(self, exc_type, exc_val, exc_tb):
-+        log.info("%s %s" % (self.__class__.__name__, inspect.stack()[0][3]))
 +        _private_ks_lock.release()
 +
 +
 +_ks_lock = KsLock()
 +
- def _preprocessStateMachine (lineIter):
+ def _preprocessStateMachine(lineIter):
      l = None
      lineno = 0
-@@ -774,6 +794,10 @@ class KickstartParser(object):
-         self._stateMachine (i)
+@@ -788,6 +802,10 @@ class KickstartParser(object):
+         self._stateMachine(i)
  
      def readKickstart(self, f, reset=True, username=None, password=None):
 +        with _ks_lock:
diff --git a/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0003-comment-out-sections-shutdown-and-environment-in-gen.patch b/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0003-comment-out-sections-shutdown-and-environment-in-gen.patch
index 9fb25fb..81e351b 100644
--- a/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0003-comment-out-sections-shutdown-and-environment-in-gen.patch
+++ b/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0003-comment-out-sections-shutdown-and-environment-in-gen.patch
@@ -1,4 +1,4 @@
-From be6012a5dd49ae5e8ac035654ab1c6f37f0dc8f4 Mon Sep 17 00:00:00 2001
+From 44226393812399c61de9ca9281efa002ad4f4c01 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Thu, 1 Jun 2017 15:15:15 +0800
 Subject: [PATCH 3/4] comment out sections shutdown and environment in
@@ -17,10 +17,10 @@
  2 files changed, 4 insertions(+), 1 deletion(-)
 
 diff --git a/pykickstart/commands/reboot.py b/pykickstart/commands/reboot.py
-index 88799ba..2d0cea9 100644
+index 2c1b1c0..b3ec717 100644
 --- a/pykickstart/commands/reboot.py
 +++ b/pykickstart/commands/reboot.py
-@@ -41,6 +41,9 @@ class FC3_Reboot(KickstartCommand):
+@@ -43,6 +43,9 @@ class FC3_Reboot(KickstartCommand):
          elif self.action == KS_SHUTDOWN:
              retval += "# Shutdown after installation\nshutdown"
              retval += self._getArgsAsStr() + "\n"
@@ -31,10 +31,10 @@
          return retval
  
 diff --git a/pykickstart/parser.py b/pykickstart/parser.py
-index 264ba05..b3f33d7 100644
+index e68174d..efd78a6 100644
 --- a/pykickstart/parser.py
 +++ b/pykickstart/parser.py
-@@ -383,7 +383,7 @@ class Packages(KickstartObject):
+@@ -385,7 +385,7 @@ class Packages(KickstartObject):
  
          if not self.default:
              if self.environment:
diff --git a/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0004-load.py-retry-to-invoke-request-with-timeout.patch b/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0004-load.py-retry-to-invoke-request-with-timeout.patch
index 70254f6..6ed15ab 100644
--- a/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0004-load.py-retry-to-invoke-request-with-timeout.patch
+++ b/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0004-load.py-retry-to-invoke-request-with-timeout.patch
@@ -1,6 +1,6 @@
-From c0e63f0d3c09bdabb0ad2c88b7cc73e7618dd86a Mon Sep 17 00:00:00 2001
+From ffe06c6dd812b604d6482e4353d5564fad78bc90 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Thu, 15 Jun 2017 17:35:33 +0800
+Date: Mon, 30 Jul 2018 15:52:21 +0800
 Subject: [PATCH 4/4] load.py: retry to invoke request with timeout
 
 While networkless, use request to fetch kickstart file from
@@ -12,11 +12,11 @@
 
 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
- pykickstart/load.py | 30 ++++++++++++++++++++++++++++++
- 1 file changed, 30 insertions(+)
+ pykickstart/load.py | 31 +++++++++++++++++++++++++++++++
+ 1 file changed, 31 insertions(+)
 
 diff --git a/pykickstart/load.py b/pykickstart/load.py
-index 48c8276..74b266b 100644
+index ad3bad1..a5cbbc5 100644
 --- a/pykickstart/load.py
 +++ b/pykickstart/load.py
 @@ -21,6 +21,7 @@ import requests
@@ -32,12 +32,12 @@
  from requests.exceptions import SSLError, RequestException
  
 +import logging
-+log = logging.getLogger("anaconda")
++log = logging.getLogger("anaconda.main")
 +
- _is_url = lambda location: '://' in location # RFC 3986
+ _is_url = lambda location: '://' in location  # RFC 3986
  
  SSL_VERIFY = False
-@@ -74,6 +78,29 @@ def load_to_file(location, destination):
+@@ -73,6 +77,29 @@ def load_to_file(location, destination):
          _copy_file(location, destination)
          return destination
  
@@ -67,16 +67,17 @@
  def _get_auth(location, user=None, passwd=None):
  
      auth = None
-@@ -96,6 +123,9 @@ def _get_auth(location, user=None, passwd=None):
+@@ -94,6 +121,10 @@ def _get_auth(location, user=None, passwd=None):
+ 
  def _load_url(location, user=None, passwd=None):
      '''Load a location (URL or filename) and return contents as string'''
- 
++
 +    if not _access_url(location):
 +        raise KickstartError(_("Connection %s failed" % location))
 +
      auth = _get_auth(location, user=user, passwd=passwd)
- 
      try:
+         request = requests.get(location, verify=SSL_VERIFY, auth=auth)
 -- 
 2.7.4
 
diff --git a/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0005-tweak-shebang-to-python3.patch b/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0005-tweak-shebang-to-python3.patch
deleted file mode 100644
index 3d61495..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-pykickstart/files/0005-tweak-shebang-to-python3.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 8a1f598223bd4cbcc877eb2aba3f5586c75c9d14 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Mon, 21 Aug 2017 10:05:06 +0800
-Subject: [PATCH] tweak shebang to python3
-
-Upstream-Status: Pending
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- tools/ksvalidator.py | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/tools/ksvalidator.py b/tools/ksvalidator.py
-index d6051d5..c3682e8 100755
---- a/tools/ksvalidator.py
-+++ b/tools/ksvalidator.py
-@@ -1,4 +1,4 @@
--#!/usr/bin/python
-+#!/usr/bin/python3
- #
- # Chris Lumens <clumens@redhat.com>
- #
--- 
-1.8.3.1
-
diff --git a/meta-openembedded/meta-python/recipes-extended/python-pykickstart/python3-pykickstart_2.35.bb b/meta-openembedded/meta-python/recipes-extended/python-pykickstart/python3-pykickstart_2.35.bb
deleted file mode 100644
index 7fe603b..0000000
--- a/meta-openembedded/meta-python/recipes-extended/python-pykickstart/python3-pykickstart_2.35.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-DESCRIPTION = "A python library for manipulating kickstart files"
-HOMEPAGE = "http://fedoraproject.org/wiki/pykickstart"
-LICENSE = "GPLv2+"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=8ca43cbc842c2336e835926c2166c28b"
-FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
-
-DEPENDS = "python3"
-RDEPENDS_${PN} = "python3 \
-                  python3-requests \
-                  python3-six \
-"
-
-S = "${WORKDIR}/git"
-SRC_URI = "git://github.com/rhinstaller/pykickstart.git;protocol=https;branch=pykickstart-2 \
-           file://0001-support-authentication-for-kickstart.patch \
-           file://0002-pykickstart-parser.py-add-lock-for-readKickstart-and.patch \
-           file://0003-comment-out-sections-shutdown-and-environment-in-gen.patch \
-           file://0004-load.py-retry-to-invoke-request-with-timeout.patch \
-           file://0005-tweak-shebang-to-python3.patch \
-           "
-SRCREV = "b2787a818540e678c2f9c5dca0c6bbd65b8b55e5"
-
-inherit setuptools3
diff --git a/meta-openembedded/meta-python/recipes-extended/python-pykickstart/python3-pykickstart_3.15.bb b/meta-openembedded/meta-python/recipes-extended/python-pykickstart/python3-pykickstart_3.15.bb
new file mode 100644
index 0000000..07876a9
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/python-pykickstart/python3-pykickstart_3.15.bb
@@ -0,0 +1,25 @@
+DESCRIPTION = "A python library for manipulating kickstart files"
+HOMEPAGE = "http://fedoraproject.org/wiki/pykickstart"
+LICENSE = "GPLv2+"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=8ca43cbc842c2336e835926c2166c28b"
+FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
+
+DEPENDS = "python3"
+RDEPENDS_${PN} = "python3 \
+                  python3-requests \
+                  python3-six \
+"
+
+S = "${WORKDIR}/git"
+SRC_URI = "git://github.com/rhinstaller/pykickstart.git;protocol=https;branch=master \
+           file://0001-support-authentication-for-kickstart.patch \
+           file://0002-pykickstart-parser.py-add-lock-for-readKickstart-and.patch \
+           file://0003-comment-out-sections-shutdown-and-environment-in-gen.patch \
+           file://0004-load.py-retry-to-invoke-request-with-timeout.patch \
+           "
+SRCREV = "07c4d89129fa6b460acc86daf58eb5ff64cdc832"
+
+UPSTREAM_CHECK_GITTAGREGEX = "r(?P<pver>\d+(\.\d+)+(-\d+)*)"
+
+inherit setuptools3
diff --git a/meta-openembedded/meta-python/recipes-extended/pywbem/python-pywbem.inc b/meta-openembedded/meta-python/recipes-extended/pywbem/python-pywbem.inc
new file mode 100644
index 0000000..5151c33
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/pywbem/python-pywbem.inc
@@ -0,0 +1,48 @@
+SUMMARY = "Python WBEM Client and Provider Interface"
+DESCRIPTION = "\
+A Python library for making CIM (Common Information Model) operations over \
+HTTP using the WBEM CIM-XML protocol. It is based on the idea that a good \
+WBEM client should be easy to use and not necessarily require a large amount \
+of programming knowledge. It is suitable for a large range of tasks from \
+simply poking around to writing web and GUI applications. \
+\
+WBEM, or Web Based Enterprise Management is a manageability protocol, like \
+SNMP, standardised by the Distributed Management Task Force (DMTF) available \
+at http://www.dmtf.org/standards/wbem. \
+\
+It also provides a Python provider interface, and is the fastest and easiest \
+way to write providers on the planet."
+HOMEPAGE = "http://pywbem.github.io"
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://pywbem/LICENSE.txt;md5=fbc093901857fcd118f065f900982c24"
+SRC_URI[md5sum] = "1465dfa92e4cbe558c773838b9b00711"
+SRC_URI[sha256sum] = "2a05f2c1a6ab4b08560a6da55fdaabd0f52f4d1e6df6e288b9ed927bf5c289ed"
+
+inherit pypi 
+
+DEPENDS += " \
+    ${PYTHON_PN}-ply-native \
+    ${PYTHON_PN}-pyyaml-native \
+    ${PYTHON_PN}-six-native \
+"
+
+do_install_append() {
+    mv ${D}${bindir}/wbemcli.py ${D}${bindir}/pywbemcli
+
+    rm -f ${D}${bindir}/*.bat
+}
+
+RDEPENDS_${PN}_class-target += "\
+    ${PYTHON_PN}-datetime \
+    ${PYTHON_PN}-io \
+    ${PYTHON_PN}-netclient \
+    ${PYTHON_PN}-ply \
+    ${PYTHON_PN}-pyyaml \
+    ${PYTHON_PN}-six \
+    ${PYTHON_PN}-stringold \
+    ${PYTHON_PN}-threading \
+    ${PYTHON_PN}-unixadmin \
+    ${PYTHON_PN}-xml \
+"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-python/recipes-extended/pywbem/python-pywbem_0.11.0.bb b/meta-openembedded/meta-python/recipes-extended/pywbem/python-pywbem_0.11.0.bb
new file mode 100644
index 0000000..7410749
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/pywbem/python-pywbem_0.11.0.bb
@@ -0,0 +1,13 @@
+require python-pywbem.inc
+inherit setuptools
+
+DEPENDS += " \
+    ${PYTHON_PN}-m2crypto-native \
+    ${PYTHON_PN}-typing-native \
+"
+
+RDEPENDS_${PN}_class-target += "\
+    ${PYTHON_PN}-argparse \
+    ${PYTHON_PN}-m2crypto \
+    ${PYTHON_PN}-subprocess \
+"
diff --git a/meta-openembedded/meta-python/recipes-extended/pywbem/python3-pywbem_0.11.0.bb b/meta-openembedded/meta-python/recipes-extended/pywbem/python3-pywbem_0.11.0.bb
new file mode 100644
index 0000000..6a35a87
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-extended/pywbem/python3-pywbem_0.11.0.bb
@@ -0,0 +1,2 @@
+require python-pywbem.inc
+inherit setuptools3
diff --git a/meta-openembedded/meta-python/recipes-extended/pywbem/pywbem_0.8.0.bb b/meta-openembedded/meta-python/recipes-extended/pywbem/pywbem_0.8.0.bb
deleted file mode 100644
index 7f1986e..0000000
--- a/meta-openembedded/meta-python/recipes-extended/pywbem/pywbem_0.8.0.bb
+++ /dev/null
@@ -1,36 +0,0 @@
-SUMMARY = "Python WBEM Client and Provider Interface"
-DESCRIPTION = "\
-A Python library for making CIM (Common Information Model) operations over \
-HTTP using the WBEM CIM-XML protocol. It is based on the idea that a good \
-WBEM client should be easy to use and not necessarily require a large amount \
-of programming knowledge. It is suitable for a large range of tasks from \
-simply poking around to writing web and GUI applications. \
-\
-WBEM, or Web Based Enterprise Management is a manageability protocol, like \
-SNMP, standardised by the Distributed Management Task Force (DMTF) available \
-at http://www.dmtf.org/standards/wbem. \
-\
-It also provides a Python provider interface, and is the fastest and easiest \
-way to write providers on the planet."
-HOMEPAGE = "http://pywbem.sf.net/"
-LICENSE = "LGPLv2"
-LIC_FILES_CHKSUM = "file://pywbem/LICENSE.txt;md5=fbc093901857fcd118f065f900982c24"
-SECTION = "Development/Libraries"
-DEPENDS = "python-m2crypto-native python-typing-native"
-SRC_URI = "http://jaist.dl.sourceforge.net/project/${BPN}/${BPN}/${BP}/${BP}-dev.r704.zip"
-SRC_URI[md5sum] = "84072451dcdd1aa9ee82363848faf7ad"
-SRC_URI[sha256sum] = "898035866d3cc741bbcd62c4ac26e633ad07b7c11d89db2472b9f923f3fd3ed8"
-
-S = "${WORKDIR}/${BP}-dev"
-
-inherit setuptools python-dir
-
-do_install_append() {
-    mv ${D}${bindir}/wbemcli.py ${D}${bindir}/pywbemcli
-    mv ${D}${bindir}/mof_compiler.py ${D}${bindir}/mofcomp
-
-    rm ${D}${libdir}/python2.7/site-packages/${BPN}/wbemcli.py*
-    rm ${D}${libdir}/python2.7/site-packages/${BPN}/mof_compiler.py*
-}
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-webserver/README b/meta-openembedded/meta-webserver/README
index 7b60630..4d2c710 100644
--- a/meta-openembedded/meta-webserver/README
+++ b/meta-openembedded/meta-webserver/README
@@ -13,14 +13,14 @@
 
 URI: git://github.com/openembedded/oe-core.git
 subdirectory: meta
-branch: master
+branch: thud
 revision: HEAD
 
 For some recipes, the meta-oe layer is required:
 
 URI: git://github.com/openembedded/meta-oe.git
 subdirectory: meta-oe
-branch: master
+branch: thud
 revision: HEAD
 
 
@@ -52,9 +52,9 @@
 -----------
 
 Send patches / pull requests to openembedded-devel@lists.openembedded.org
-with '[meta-webserver]' in the subject.
+with '[meta-webserver][thud]' in the subject.
 
-Layer maintainer: Derek Straka <derek@asterius.io>
+Thud Maintainer: Armin Kuster <akuster808@gmail.com>
 
 
 License
diff --git a/meta-openembedded/meta-webserver/conf/layer.conf b/meta-openembedded/meta-webserver/conf/layer.conf
index f205ef2..aaa3a95 100644
--- a/meta-openembedded/meta-webserver/conf/layer.conf
+++ b/meta-openembedded/meta-webserver/conf/layer.conf
@@ -17,7 +17,7 @@
 
 LAYERDEPENDS_webserver = "core openembedded-layer"
 
-LAYERSERIES_COMPAT_webserver = "sumo"
+LAYERSERIES_COMPAT_webserver = "thud"
 
 LICENSE_PATH += "${LAYERDIR}/licenses"
 
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2-native_2.4.29.bb b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2-native_2.4.29.bb
deleted file mode 100644
index 36f073c..0000000
--- a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2-native_2.4.29.bb
+++ /dev/null
@@ -1,45 +0,0 @@
-DESCRIPTION = "The Apache HTTP Server is a powerful, efficient, and \
-extensible web server."
-SUMMARY = "Apache HTTP Server"
-HOMEPAGE = "http://httpd.apache.org/"
-DEPENDS = "expat-native pcre-native apr-native apr-util-native"
-SECTION = "net"
-LICENSE = "Apache-2.0"
-
-inherit autotools pkgconfig native
-
-SRC_URI = "${APACHE_MIRROR}/httpd/httpd-${PV}.tar.bz2 \
-           file://0001-configure-use-pkg-config-for-PCRE-detection.patch \
-          "
-
-S = "${WORKDIR}/httpd-${PV}"
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=a62b0c7623826ff99766ff13fb9007f8"
-SRC_URI[md5sum] = "0c599404ef6b69eee95bcd9fcd094407"
-SRC_URI[sha256sum] = "777753a5a25568a2a27428b2214980564bc1c38c1abf9ccc7630b639991f7f00"
-
-EXTRA_OECONF = "--with-apr=${STAGING_BINDIR_CROSS}/apr-1-config \
-                --with-apr-util=${STAGING_BINDIR_CROSS}/apu-1-config \
-                --prefix=${prefix} --datadir=${datadir}/apache2 \
-               "
-
-do_install () {
-    install -d ${D}${bindir} ${D}${libdir}
-    cp server/gen_test_char ${D}${bindir}
-    install -m 755 support/apxs ${D}${bindir}/
-    install -m 755 httpd ${D}${bindir}/
-    install -d ${D}${datadir}/apache2/build
-    cp ${S}/build/*.mk ${D}${datadir}/apache2/build
-    cp build/*.mk ${D}${datadir}/apache2/build
-    cp ${S}/build/instdso.sh ${D}${datadir}/apache2/build
-
-    install -d ${D}${includedir}/apache2
-    cp ${S}/include/* ${D}${includedir}/apache2
-    cp include/* ${D}${includedir}/apache2
-    cp ${S}/os/unix/os.h ${D}${includedir}/apache2
-    cp ${S}/os/unix/unixd.h ${D}${includedir}/apache2
-
-    cp support/envvars-std ${D}${bindir}/envvars
-    chmod 755 ${D}${bindir}/envvars
-}
-
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2-native_2.4.34.bb b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2-native_2.4.34.bb
new file mode 100644
index 0000000..4cc3845
--- /dev/null
+++ b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2-native_2.4.34.bb
@@ -0,0 +1,46 @@
+DESCRIPTION = "The Apache HTTP Server is a powerful, efficient, and \
+extensible web server."
+SUMMARY = "Apache HTTP Server"
+HOMEPAGE = "http://httpd.apache.org/"
+DEPENDS = "expat-native pcre-native apr-native apr-util-native"
+SECTION = "net"
+LICENSE = "Apache-2.0"
+
+inherit autotools pkgconfig native
+
+SRC_URI = "${APACHE_MIRROR}/httpd/httpd-${PV}.tar.bz2 \
+           file://0001-configure-use-pkg-config-for-PCRE-detection.patch \
+           file://CVE-2018-11763.patch \
+          "
+
+S = "${WORKDIR}/httpd-${PV}"
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=d52d0fd0bc788f068e647116c01ddfcd"
+SRC_URI[md5sum] = "818adca52f3be187fe45d6822755be95"
+SRC_URI[sha256sum] = "fa53c95631febb08a9de41fd2864cfff815cf62d9306723ab0d4b8d7aa1638f0"
+
+EXTRA_OECONF = "--with-apr=${STAGING_BINDIR_CROSS}/apr-1-config \
+                --with-apr-util=${STAGING_BINDIR_CROSS}/apu-1-config \
+                --prefix=${prefix} --datadir=${datadir}/apache2 \
+               "
+
+do_install () {
+    install -d ${D}${bindir} ${D}${libdir}
+    cp server/gen_test_char ${D}${bindir}
+    install -m 755 support/apxs ${D}${bindir}/
+    install -m 755 httpd ${D}${bindir}/
+    install -d ${D}${datadir}/apache2/build
+    cp ${S}/build/*.mk ${D}${datadir}/apache2/build
+    cp build/*.mk ${D}${datadir}/apache2/build
+    cp ${S}/build/instdso.sh ${D}${datadir}/apache2/build
+
+    install -d ${D}${includedir}/apache2
+    cp ${S}/include/* ${D}${includedir}/apache2
+    cp include/* ${D}${includedir}/apache2
+    cp ${S}/os/unix/os.h ${D}${includedir}/apache2
+    cp ${S}/os/unix/unixd.h ${D}${includedir}/apache2
+
+    cp support/envvars-std ${D}${bindir}/envvars
+    chmod 755 ${D}${bindir}/envvars
+}
+
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/0001-configure-use-pkg-config-for-PCRE-detection.patch b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/0001-configure-use-pkg-config-for-PCRE-detection.patch
new file mode 100644
index 0000000..da38a8c
--- /dev/null
+++ b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/0001-configure-use-pkg-config-for-PCRE-detection.patch
@@ -0,0 +1,51 @@
+From 419181e242892ded050f5a375a709b9588fb581d Mon Sep 17 00:00:00 2001
+From: Koen Kooi <koen.kooi@linaro.org>
+Date: Tue, 17 Jun 2014 09:10:57 +0200
+Subject: [PATCH] configure: use pkg-config for PCRE detection
+
+Upstream-Status: Pending
+
+Signed-off-by: Koen Kooi <koen.kooi@linaro.org>
+
+---
+ configure.in | 27 +++++----------------------
+ 1 file changed, 5 insertions(+), 22 deletions(-)
+
+diff --git a/configure.in b/configure.in
+index be7bd25..54dfd0d 100644
+--- a/configure.in
++++ b/configure.in
+@@ -215,28 +215,11 @@ fi
+ AC_ARG_WITH(pcre,
+ APACHE_HELP_STRING(--with-pcre=PATH,Use external PCRE library))
+ 
+-AC_PATH_PROG(PCRE_CONFIG, pcre-config, false)
+-if test -d "$with_pcre" && test -x "$with_pcre/bin/pcre-config"; then
+-   PCRE_CONFIG=$with_pcre/bin/pcre-config
+-elif test -x "$with_pcre"; then
+-   PCRE_CONFIG=$with_pcre
+-fi
+-
+-if test "$PCRE_CONFIG" != "false"; then
+-  if $PCRE_CONFIG --version >/dev/null 2>&1; then :; else
+-    AC_MSG_ERROR([Did not find pcre-config script at $PCRE_CONFIG])
+-  fi
+-  case `$PCRE_CONFIG --version` in
+-  [[1-5].*])
+-    AC_MSG_ERROR([Need at least pcre version 6.0])
+-    ;;
+-  esac
+-  AC_MSG_NOTICE([Using external PCRE library from $PCRE_CONFIG])
+-  APR_ADDTO(PCRE_INCLUDES, [`$PCRE_CONFIG --cflags`])
+-  APR_ADDTO(PCRE_LIBS, [`$PCRE_CONFIG --libs`])
+-else
+-  AC_MSG_ERROR([pcre-config for libpcre not found. PCRE is required and available from http://pcre.org/])
+-fi
++PKG_CHECK_MODULES([PCRE], [libpcre], [
++  AC_DEFINE([HAVE_PCRE], [1], [Define if you have PCRE library])
++], [
++  AC_MSG_ERROR([$PCRE_PKG_ERRORS])
++])
+ APACHE_SUBST(PCRE_LIBS)
+ 
+ AC_MSG_NOTICE([])
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/CVE-2018-11763.patch b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/CVE-2018-11763.patch
new file mode 100644
index 0000000..a2c5b2e
--- /dev/null
+++ b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/CVE-2018-11763.patch
@@ -0,0 +1,512 @@
+From 484aba5048e3457dc1d15189f1910d007b1a4a76 Mon Sep 17 00:00:00 2001
+From: Jim Jagielski <jim@apache.org>
+Date: Wed, 12 Sep 2018 20:38:02 +0000
+Subject: [PATCH] Merge r1840010 from trunk:
+
+On the trunk:
+
+mod_http2: connection IO event handling reworked. Instead of reacting on
+     incoming bytes, the state machine now acts on incoming frames that are
+     affecting it. This reduces state transitions.
+
+
+Submitted by: icing
+Reviewed by: icing, ylavic, jim
+
+
+git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1840757 13f79535-47bb-0310-9956-ffa450edef68
+CVE: CVE-2018-11763
+Upstream-Status: Backport [https://github.com/apache/httpd/commit/484aba5048e3457dc1d15189f1910d007b1a4a76]
+
+Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
+---
+ modules/http2/h2_session.c | 238 +++++++++++++++++++++++--------------
+ modules/http2/h2_session.h |   7 +-
+ modules/http2/h2_version.h |   4 +-
+ 3 files changed, 158 insertions(+), 97 deletions(-)
+
+diff --git a/modules/http2/h2_session.c b/modules/http2/h2_session.c
+index 805d6774dc..a1b31d2b30 100644
+--- a/modules/http2/h2_session.c
++++ b/modules/http2/h2_session.c
+@@ -235,6 +235,7 @@ static int on_data_chunk_recv_cb(nghttp2_session *ngh2, uint8_t flags,
+     stream = h2_session_stream_get(session, stream_id);
+     if (stream) {
+         status = h2_stream_recv_DATA(stream, flags, data, len);
++        dispatch_event(session, H2_SESSION_EV_STREAM_CHANGE, 0, "stream data rcvd");
+     }
+     else {
+         ap_log_cerror(APLOG_MARK, APLOG_DEBUG, 0, session->c, APLOGNO(03064)
+@@ -317,9 +318,9 @@ static int on_header_cb(nghttp2_session *ngh2, const nghttp2_frame *frame,
+ }
+ 
+ /**
+- * nghttp2 session has received a complete frame. Most, it uses
+- * for processing of internal state. HEADER and DATA frames however
+- * we need to handle ourself.
++ * nghttp2 session has received a complete frame. Most are used by nghttp2
++ * for processing of internal state. Some, like HEADER and DATA frames,
++ * we need to act on.
+  */
+ static int on_frame_recv_cb(nghttp2_session *ng2s,
+                             const nghttp2_frame *frame,
+@@ -378,6 +379,9 @@ static int on_frame_recv_cb(nghttp2_session *ng2s,
+                           "h2_stream(%ld-%d): WINDOW_UPDATE incr=%d", 
+                           session->id, (int)frame->hd.stream_id,
+                           frame->window_update.window_size_increment);
++            if (nghttp2_session_want_write(session->ngh2)) {
++                dispatch_event(session, H2_SESSION_EV_FRAME_RCVD, 0, "window update");
++            }
+             break;
+         case NGHTTP2_RST_STREAM:
+             ap_log_cerror(APLOG_MARK, APLOG_DEBUG, 0, session->c, APLOGNO(03067)
+@@ -404,6 +408,12 @@ static int on_frame_recv_cb(nghttp2_session *ng2s,
+                                frame->goaway.error_code, NULL);
+             }
+             break;
++        case NGHTTP2_SETTINGS:
++            if (APLOGctrace2(session->c)) {
++                ap_log_cerror(APLOG_MARK, APLOG_TRACE2, 0, session->c,
++                              H2_SSSN_MSG(session, "SETTINGS, len=%ld"), (long)frame->hd.length);
++            }
++            break;
+         default:
+             if (APLOGctrace2(session->c)) {
+                 char buffer[256];
+@@ -415,7 +425,40 @@ static int on_frame_recv_cb(nghttp2_session *ng2s,
+             }
+             break;
+     }
+-    return (APR_SUCCESS == rv)? 0 : NGHTTP2_ERR_PROTO;
++    
++    if (session->state == H2_SESSION_ST_IDLE) {
++        /* We received a frame, but session is in state IDLE. That means the frame
++         * did not really progress any of the (possibly) open streams. It was a meta
++         * frame, e.g. SETTINGS/WINDOW_UPDATE/unknown/etc.
++         * Remember: IDLE means we cannot send because either there are no streams open or
++         * all open streams are blocked on exhausted WINDOWs for outgoing data.
++         * The more frames we receive that do not change this, the less interested we
++         * become in serving this connection. This is expressed in increasing "idle_delays".
++         * Eventually, the connection will timeout and we'll close it. */
++        session->idle_frames = H2MIN(session->idle_frames + 1, session->frames_received);
++            ap_log_cerror( APLOG_MARK, APLOG_TRACE2, 0, session->c,
++                          H2_SSSN_MSG(session, "session has %ld idle frames"), 
++                          (long)session->idle_frames);
++        if (session->idle_frames > 10) {
++            apr_size_t busy_frames = H2MAX(session->frames_received - session->idle_frames, 1);
++            int idle_ratio = (int)(session->idle_frames / busy_frames); 
++            if (idle_ratio > 100) {
++                session->idle_delay = apr_time_from_msec(H2MIN(1000, idle_ratio));
++            }
++            else if (idle_ratio > 10) {
++                session->idle_delay = apr_time_from_msec(10);
++            }
++            else if (idle_ratio > 1) {
++                session->idle_delay = apr_time_from_msec(1);
++            }
++            else {
++                session->idle_delay = 0;
++            }
++        }
++    }
++    
++    if (APR_SUCCESS != rv) return NGHTTP2_ERR_PROTO;
++    return 0;
+ }
+ 
+ static int h2_session_continue_data(h2_session *session) {
+@@ -1603,23 +1646,57 @@ static void update_child_status(h2_session *session, int status, const char *msg
+ 
+ static void transit(h2_session *session, const char *action, h2_session_state nstate)
+ {
++    apr_time_t timeout;
++    int ostate, loglvl;
++    const char *s;
++    
+     if (session->state != nstate) {
+-        int loglvl = APLOG_DEBUG;
+-        if ((session->state == H2_SESSION_ST_BUSY && nstate == H2_SESSION_ST_WAIT)
+-            || (session->state == H2_SESSION_ST_WAIT && nstate == H2_SESSION_ST_BUSY)){
++        ostate = session->state;
++        session->state = nstate;
++        
++        loglvl = APLOG_DEBUG;
++        if ((ostate == H2_SESSION_ST_BUSY && nstate == H2_SESSION_ST_WAIT)
++            || (ostate == H2_SESSION_ST_WAIT && nstate == H2_SESSION_ST_BUSY)){
+             loglvl = APLOG_TRACE1;
+         }
+         ap_log_cerror(APLOG_MARK, loglvl, 0, session->c, 
+                       H2_SSSN_LOG(APLOGNO(03078), session, 
+                       "transit [%s] -- %s --> [%s]"), 
+-                      h2_session_state_str(session->state), action, 
++                      h2_session_state_str(ostate), action, 
+                       h2_session_state_str(nstate));
+-        session->state = nstate;
++        
+         switch (session->state) {
+             case H2_SESSION_ST_IDLE:
+-                update_child_status(session, (session->open_streams == 0? 
+-                                              SERVER_BUSY_KEEPALIVE
+-                                              : SERVER_BUSY_READ), "idle");
++                if (!session->remote.emitted_count) {
++                    /* on fresh connections, with async mpm, do not return
++                     * to mpm for a second. This gives the first request a better
++                     * chance to arrive (und connection leaving IDLE state).
++                     * If we return to mpm right away, this connection has the
++                     * same chance of being cleaned up by the mpm as connections
++                     * that already served requests - not fair. */
++                    session->idle_sync_until = apr_time_now() + apr_time_from_sec(1);
++                    s = "timeout";
++                    timeout = H2MAX(session->s->timeout, session->s->keep_alive_timeout);
++                    update_child_status(session, SERVER_BUSY_READ, "idle");
++                    ap_log_cerror(APLOG_MARK, APLOG_TRACE1, 0, session->c, 
++                                  H2_SSSN_LOG("", session, "enter idle, timeout = %d sec"), 
++                                  (int)apr_time_sec(H2MAX(session->s->timeout, session->s->keep_alive_timeout)));
++                }
++                else if (session->open_streams) {
++                    s = "timeout";
++                    timeout = session->s->keep_alive_timeout;
++                    update_child_status(session, SERVER_BUSY_KEEPALIVE, "idle");
++                }
++                else {
++                    /* normal keepalive setup */
++                    s = "keepalive";
++                    timeout = session->s->keep_alive_timeout;
++                    update_child_status(session, SERVER_BUSY_KEEPALIVE, "idle");
++                }
++                session->idle_until = apr_time_now() + timeout; 
++                ap_log_cerror(APLOG_MARK, APLOG_TRACE1, 0, session->c, 
++                              H2_SSSN_LOG("", session, "enter idle, %s = %d sec"), 
++                              s, (int)apr_time_sec(timeout));
+                 break;
+             case H2_SESSION_ST_DONE:
+                 update_child_status(session, SERVER_CLOSING, "done");
+@@ -1726,8 +1803,6 @@ static void h2_session_ev_no_io(h2_session *session, int arg, const char *msg)
+                      * This means we only wait for WINDOW_UPDATE from the 
+                      * client and can block on READ. */
+                     transit(session, "no io (flow wait)", H2_SESSION_ST_IDLE);
+-                    session->idle_until = apr_time_now() + session->s->timeout;
+-                    session->keep_sync_until = session->idle_until;
+                     /* Make sure we have flushed all previously written output
+                      * so that the client will react. */
+                     if (h2_conn_io_flush(&session->io) != APR_SUCCESS) {
+@@ -1738,12 +1813,7 @@ static void h2_session_ev_no_io(h2_session *session, int arg, const char *msg)
+             }
+             else if (session->local.accepting) {
+                 /* When we have no streams, but accept new, switch to idle */
+-                apr_time_t now = apr_time_now();
+                 transit(session, "no io (keepalive)", H2_SESSION_ST_IDLE);
+-                session->idle_until = (session->remote.emitted_count? 
+-                                       session->s->keep_alive_timeout : 
+-                                       session->s->timeout) + now;
+-                session->keep_sync_until = now + apr_time_from_sec(1);
+             }
+             else {
+                 /* We are no longer accepting new streams and there are
+@@ -1758,12 +1828,25 @@ static void h2_session_ev_no_io(h2_session *session, int arg, const char *msg)
+     }
+ }
+ 
+-static void h2_session_ev_data_read(h2_session *session, int arg, const char *msg)
++static void h2_session_ev_frame_rcvd(h2_session *session, int arg, const char *msg)
++{
++    switch (session->state) {
++        case H2_SESSION_ST_IDLE:
++        case H2_SESSION_ST_WAIT:
++            transit(session, "frame received", H2_SESSION_ST_BUSY);
++            break;
++        default:
++            /* nop */
++            break;
++    }
++}
++
++static void h2_session_ev_stream_change(h2_session *session, int arg, const char *msg)
+ {
+     switch (session->state) {
+         case H2_SESSION_ST_IDLE:
+         case H2_SESSION_ST_WAIT:
+-            transit(session, "data read", H2_SESSION_ST_BUSY);
++            transit(session, "stream change", H2_SESSION_ST_BUSY);
+             break;
+         default:
+             /* nop */
+@@ -1803,16 +1886,6 @@ static void h2_session_ev_pre_close(h2_session *session, int arg, const char *ms
+ static void ev_stream_open(h2_session *session, h2_stream *stream)
+ {
+     h2_iq_append(session->in_process, stream->id);
+-    switch (session->state) {
+-        case H2_SESSION_ST_IDLE:
+-            if (session->open_streams == 1) {
+-                /* enter timeout, since we have a stream again */
+-                session->idle_until = (session->s->timeout + apr_time_now());
+-            }
+-            break;
+-        default:
+-            break;
+-    }
+ }
+ 
+ static void ev_stream_closed(h2_session *session, h2_stream *stream)
+@@ -1825,11 +1898,6 @@ static void ev_stream_closed(h2_session *session, h2_stream *stream)
+     }
+     switch (session->state) {
+         case H2_SESSION_ST_IDLE:
+-            if (session->open_streams == 0) {
+-                /* enter keepalive timeout, since we no longer have streams */
+-                session->idle_until = (session->s->keep_alive_timeout
+-                                       + apr_time_now());
+-            }
+             break;
+         default:
+             break;
+@@ -1887,6 +1955,7 @@ static void on_stream_state_enter(void *ctx, h2_stream *stream)
+         default:
+             break;
+     }
++    dispatch_event(session, H2_SESSION_EV_STREAM_CHANGE, 0, "stream state change");
+ }
+ 
+ static void on_stream_event(void *ctx, h2_stream *stream, 
+@@ -1945,8 +2014,8 @@ static void dispatch_event(h2_session *session, h2_session_event_t ev,
+         case H2_SESSION_EV_NO_IO:
+             h2_session_ev_no_io(session, arg, msg);
+             break;
+-        case H2_SESSION_EV_DATA_READ:
+-            h2_session_ev_data_read(session, arg, msg);
++        case H2_SESSION_EV_FRAME_RCVD:
++            h2_session_ev_frame_rcvd(session, arg, msg);
+             break;
+         case H2_SESSION_EV_NGH2_DONE:
+             h2_session_ev_ngh2_done(session, arg, msg);
+@@ -1957,6 +2026,9 @@ static void dispatch_event(h2_session *session, h2_session_event_t ev,
+         case H2_SESSION_EV_PRE_CLOSE:
+             h2_session_ev_pre_close(session, arg, msg);
+             break;
++        case H2_SESSION_EV_STREAM_CHANGE:
++            h2_session_ev_stream_change(session, arg, msg);
++            break;
+         default:
+             ap_log_cerror(APLOG_MARK, APLOG_TRACE1, 0, session->c,
+                           H2_SSSN_MSG(session, "unknown event %d"), ev);
+@@ -1990,13 +2062,15 @@ apr_status_t h2_session_process(h2_session *session, int async)
+     apr_status_t status = APR_SUCCESS;
+     conn_rec *c = session->c;
+     int rv, mpm_state, trace = APLOGctrace3(c);
+-
++    apr_time_t now;
++    
+     if (trace) {
+         ap_log_cerror( APLOG_MARK, APLOG_TRACE3, status, c,
+                       H2_SSSN_MSG(session, "process start, async=%d"), async);
+     }
+                   
+     while (session->state != H2_SESSION_ST_DONE) {
++        now = apr_time_now();
+         session->have_read = session->have_written = 0;
+ 
+         if (session->local.accepting 
+@@ -2034,39 +2108,42 @@ apr_status_t h2_session_process(h2_session *session, int async)
+                 break;
+                 
+             case H2_SESSION_ST_IDLE:
+-                /* We trust our connection into the default timeout/keepalive
+-                 * handling of the core filters/mpm iff:
+-                 * - keep_sync_until is not set
+-                 * - we have an async mpm
+-                 * - we have no open streams to process
+-                 * - we are not sitting on a Upgrade: request
+-                 * - we already have seen at least one request
+-                 */
+-                if (!session->keep_sync_until && async && !session->open_streams
+-                    && !session->r && session->remote.emitted_count) {
++                if (session->idle_until && (apr_time_now() + session->idle_delay) > session->idle_until) {
++                    ap_log_cerror( APLOG_MARK, APLOG_TRACE1, status, c,
++                                  H2_SSSN_MSG(session, "idle, timeout reached, closing"));
++                    if (session->idle_delay) {
++                        apr_table_setn(session->c->notes, "short-lingering-close", "1"); 
++                    }
++                    dispatch_event(session, H2_SESSION_EV_CONN_TIMEOUT, 0, "timeout");
++                    goto out;
++                }
++                
++                if (session->idle_delay) {
++                    /* we are less interested in spending time on this connection */
++                    ap_log_cerror( APLOG_MARK, APLOG_TRACE2, status, c,
++                                  H2_SSSN_MSG(session, "session is idle (%ld ms), idle wait %ld sec left"), 
++                                  (long)apr_time_as_msec(session->idle_delay),
++                                  (long)apr_time_sec(session->idle_until - now));
++                    apr_sleep(session->idle_delay);
++                    session->idle_delay = 0;
++                }
++
++                h2_conn_io_flush(&session->io);
++                if (async && !session->r && (now > session->idle_sync_until)) {
+                     if (trace) {
+                         ap_log_cerror(APLOG_MARK, APLOG_TRACE3, status, c,
+                                       H2_SSSN_MSG(session, 
+                                       "nonblock read, %d streams open"), 
+                                       session->open_streams);
+                     }
+-                    h2_conn_io_flush(&session->io);
+                     status = h2_session_read(session, 0);
+                     
+                     if (status == APR_SUCCESS) {
+                         session->have_read = 1;
+-                        dispatch_event(session, H2_SESSION_EV_DATA_READ, 0, NULL);
+                     }
+-                    else if (APR_STATUS_IS_EAGAIN(status) 
+-                        || APR_STATUS_IS_TIMEUP(status)) {
+-                        if (apr_time_now() > session->idle_until) {
+-                            dispatch_event(session, 
+-                                           H2_SESSION_EV_CONN_TIMEOUT, 0, NULL);
+-                        }
+-                        else {
+-                            status = APR_EAGAIN;
+-                            goto out;
+-                        }
++                    else if (APR_STATUS_IS_EAGAIN(status) || APR_STATUS_IS_TIMEUP(status)) {
++                        status = APR_EAGAIN;
++                        goto out;
+                     }
+                     else {
+                         ap_log_cerror(APLOG_MARK, APLOG_DEBUG, status, c,
+@@ -2078,7 +2155,6 @@ apr_status_t h2_session_process(h2_session *session, int async)
+                 }
+                 else {
+                     /* make certain, we send everything before we idle */
+-                    h2_conn_io_flush(&session->io);
+                     if (trace) {
+                         ap_log_cerror(APLOG_MARK, APLOG_TRACE3, status, c,
+                                       H2_SSSN_MSG(session, 
+@@ -2090,7 +2166,6 @@ apr_status_t h2_session_process(h2_session *session, int async)
+                      */
+                     status = h2_mplx_idle(session->mplx);
+                     if (status == APR_EAGAIN) {
+-                        dispatch_event(session, H2_SESSION_EV_DATA_READ, 0, NULL);
+                         break;
+                     }
+                     else if (status != APR_SUCCESS) {
+@@ -2101,33 +2176,11 @@ apr_status_t h2_session_process(h2_session *session, int async)
+                     status = h2_session_read(session, 1);
+                     if (status == APR_SUCCESS) {
+                         session->have_read = 1;
+-                        dispatch_event(session, H2_SESSION_EV_DATA_READ, 0, NULL);
+                     }
+                     else if (status == APR_EAGAIN) {
+                         /* nothing to read */
+                     }
+                     else if (APR_STATUS_IS_TIMEUP(status)) {
+-                        apr_time_t now = apr_time_now();
+-                        if (now > session->keep_sync_until) {
+-                            /* if we are on an async mpm, now is the time that
+-                             * we may dare to pass control to it. */
+-                            session->keep_sync_until = 0;
+-                        }
+-                        if (now > session->idle_until) {
+-                            if (trace) {
+-                                ap_log_cerror(APLOG_MARK, APLOG_TRACE3, status, c,
+-                                              H2_SSSN_MSG(session, 
+-                                              "keepalive timeout"));
+-                            }
+-                            dispatch_event(session, 
+-                                           H2_SESSION_EV_CONN_TIMEOUT, 0, "timeout");
+-                        }
+-                        else if (trace) {                        
+-                            ap_log_cerror(APLOG_MARK, APLOG_TRACE3, status, c,
+-                                          H2_SSSN_MSG(session, 
+-                                          "keepalive, %f sec left"),
+-                                          (session->idle_until - now) / 1000000.0f);
+-                        }
+                         /* continue reading handling */
+                     }
+                     else if (APR_STATUS_IS_ECONNABORTED(status)
+@@ -2145,6 +2198,18 @@ apr_status_t h2_session_process(h2_session *session, int async)
+                         dispatch_event(session, H2_SESSION_EV_CONN_ERROR, 0, "error");
+                     }
+                 }
++                if (nghttp2_session_want_write(session->ngh2)) {
++                    ap_update_child_status(session->c->sbh, SERVER_BUSY_WRITE, NULL);
++                    status = h2_session_send(session);
++                    if (status == APR_SUCCESS) {
++                        status = h2_conn_io_flush(&session->io);
++                    }
++                    if (status != APR_SUCCESS) {
++                        dispatch_event(session, H2_SESSION_EV_CONN_ERROR, 
++                                       H2_ERR_INTERNAL_ERROR, "writing");
++                        break;
++                    }
++                }
+                 break;
+                 
+             case H2_SESSION_ST_BUSY:
+@@ -2154,7 +2219,6 @@ apr_status_t h2_session_process(h2_session *session, int async)
+                     status = h2_session_read(session, 0);
+                     if (status == APR_SUCCESS) {
+                         session->have_read = 1;
+-                        dispatch_event(session, H2_SESSION_EV_DATA_READ, 0, NULL);
+                     }
+                     else if (status == APR_EAGAIN) {
+                         /* nothing to read */
+@@ -2218,7 +2282,7 @@ apr_status_t h2_session_process(h2_session *session, int async)
+                                              session->iowait);
+                 if (status == APR_SUCCESS) {
+                     session->wait_us = 0;
+-                    dispatch_event(session, H2_SESSION_EV_DATA_READ, 0, NULL);
++                        dispatch_event(session, H2_SESSION_EV_STREAM_CHANGE, 0, NULL);
+                 }
+                 else if (APR_STATUS_IS_TIMEUP(status)) {
+                     /* go back to checking all inputs again */
+diff --git a/modules/http2/h2_session.h b/modules/http2/h2_session.h
+index 486938b009..df2a862445 100644
+--- a/modules/http2/h2_session.h
++++ b/modules/http2/h2_session.h
+@@ -66,10 +66,11 @@ typedef enum {
+     H2_SESSION_EV_PROTO_ERROR,      /* protocol error */
+     H2_SESSION_EV_CONN_TIMEOUT,     /* connection timeout */
+     H2_SESSION_EV_NO_IO,            /* nothing has been read or written */
+-    H2_SESSION_EV_DATA_READ,        /* connection data has been read */
++    H2_SESSION_EV_FRAME_RCVD,       /* a frame has been received */
+     H2_SESSION_EV_NGH2_DONE,        /* nghttp2 wants neither read nor write anything */
+     H2_SESSION_EV_MPM_STOPPING,     /* the process is stopping */
+     H2_SESSION_EV_PRE_CLOSE,        /* connection will close after this */
++    H2_SESSION_EV_STREAM_CHANGE,    /* a stream (state/input/output) changed */
+ } h2_session_event_t;
+ 
+ typedef struct h2_session {
+@@ -118,7 +119,9 @@ typedef struct h2_session {
+     apr_size_t max_stream_mem;      /* max buffer memory for a single stream */
+     
+     apr_time_t idle_until;          /* Time we shut down due to sheer boredom */
+-    apr_time_t keep_sync_until;     /* Time we sync wait until passing to async mpm */
++    apr_time_t idle_sync_until;     /* Time we sync wait until keepalive handling kicks in */
++    apr_size_t idle_frames;         /* number of rcvd frames that kept session in idle state */
++    apr_interval_time_t idle_delay; /* Time we delay processing rcvd frames in idle state */
+     
+     apr_bucket_brigade *bbtmp;      /* brigade for keeping temporary data */
+     struct apr_thread_cond_t *iowait; /* our cond when trywaiting for data */
+diff --git a/modules/http2/h2_version.h b/modules/http2/h2_version.h
+index 5c53abd575..2ac718fc0f 100644
+--- a/modules/http2/h2_version.h
++++ b/modules/http2/h2_version.h
+@@ -27,7 +27,7 @@
+  * @macro
+  * Version number of the http2 module as c string
+  */
+-#define MOD_HTTP2_VERSION "1.10.20"
++#define MOD_HTTP2_VERSION "1.11.0"
+ 
+ /**
+  * @macro
+@@ -35,7 +35,7 @@
+  * release. This is a 24 bit number with 8 bits for major number, 8 bits
+  * for minor and 8 bits for patch. Version 1.2.3 becomes 0x010203.
+  */
+-#define MOD_HTTP2_VERSION_NUM 0x010a14
++#define MOD_HTTP2_VERSION_NUM 0x010b00
+ 
+ 
+ #endif /* mod_h2_h2_version_h */
+-- 
+2.17.1
+
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/apache-configure_perlbin.patch b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/apache-configure_perlbin.patch
index 92c53f3..a2bc6e0 100644
--- a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/apache-configure_perlbin.patch
+++ b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/apache-configure_perlbin.patch
@@ -1,14 +1,19 @@
-# Author: echo <fei.geng@windriver.com>
-# Date: April 28 2009
-# Summary:Fix perl install directory to /usr/bin
-#
-# Upstream-Status: Inappropriate [configuration]
+From 5412077c398dec74321388fe6e593a44c4c80de6 Mon Sep 17 00:00:00 2001
+From: echo <fei.geng@windriver.com>
+Date: Tue, 28 Apr 2009 03:11:06 +0000
+Subject: [PATCH] Fix perl install directory to /usr/bin
 
-Index: httpd-2.4.29/configure.in
-===================================================================
---- httpd-2.4.29.orig/configure.in
-+++ httpd-2.4.29/configure.in
-@@ -855,10 +855,7 @@ AC_DEFINE_UNQUOTED(SERVER_CONFIG_FILE, "
+Upstream-Status: Inappropriate [configuration]
+
+---
+ configure.in | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
+diff --git a/configure.in b/configure.in
+index d828512..be7bd25 100644
+--- a/configure.in
++++ b/configure.in
+@@ -855,10 +855,7 @@ AC_DEFINE_UNQUOTED(SERVER_CONFIG_FILE, "${rel_sysconfdir}/${progname}.conf",
  AC_DEFINE_UNQUOTED(AP_TYPES_CONFIG_FILE, "${rel_sysconfdir}/mime.types",
  	[Location of the MIME types config file, relative to the Apache root directory])
  
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/apache-ssl-ltmain-rpath.patch b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/apache-ssl-ltmain-rpath.patch
deleted file mode 100644
index f13da91..0000000
--- a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/apache-ssl-ltmain-rpath.patch
+++ /dev/null
@@ -1,81 +0,0 @@
- build/ltmain.sh | 32 +++++++++++++++++++++++++++-----
- 1 file changed, 27 insertions(+), 5 deletions(-)
-
-Index: httpd-2.4.29/build/ltmain.sh
-===================================================================
---- httpd-2.4.29.orig/build/ltmain.sh
-+++ httpd-2.4.29/build/ltmain.sh
-@@ -6969,7 +6969,7 @@ func_mode_link ()
- 	dir=$func_resolve_sysroot_result
- 	# We need an absolute path.
- 	case $dir in
--	[\\/]* | [A-Za-z]:[\\/]*) ;;
-+	=* | [\\/]* | [A-Za-z]:[\\/]*) ;;
- 	*)
- 	  absdir=`cd "$dir" && pwd`
- 	  test -z "$absdir" && \
-@@ -8167,7 +8167,7 @@ func_mode_link ()
- 	    $ECHO "*** $linklib is not portable!"
- 	  fi
- 	  if test lib = "$linkmode" &&
--	     test yes = "$hardcode_into_libs"; then
-+	     test "x$wrs_use_rpaths" = "xyes" && test "$hardcode_into_libs" = yes; then
- 	    # Hardcode the library path.
- 	    # Skip directories that are in the system default run-time
- 	    # search path.
-@@ -8434,7 +8434,7 @@ func_mode_link ()
- 
- 	if test lib = "$linkmode"; then
- 	  if test -n "$dependency_libs" &&
--	     { test yes != "$hardcode_into_libs" ||
-+              { test yes != "$hardcode_into_libs" || test "x$wrs_use_rpaths" != "xyes" ||
- 	       test yes = "$build_old_libs" ||
- 	       test yes = "$link_static"; }; then
- 	    # Extract -R from dependency_libs
-@@ -9086,7 +9086,8 @@ func_mode_link ()
- 	  *) func_append finalize_rpath " $libdir" ;;
- 	  esac
- 	done
--	if test yes != "$hardcode_into_libs" || test yes = "$build_old_libs"; then
-+        if test yes != "$hardcode_into_libs"  || test "x$wrs_use_rpaths" != "xyes" ||
-+           test yes = "$build_old_libs"; then
- 	  dependency_libs="$temp_xrpath $dependency_libs"
- 	fi
-       fi
-@@ -9534,7 +9535,7 @@ EOF
- 	case $archive_cmds in
- 	  *\$LD\ *) wl= ;;
-         esac
--	if test yes = "$hardcode_into_libs"; then
-+	if test yes = "$hardcode_into_libs" && test "x$wrs_use_rpaths" = "xyes"; then
- 	  # Hardcode the library paths
- 	  hardcode_libdirs=
- 	  dep_rpath=
-@@ -10272,6 +10273,27 @@ EOF
-       # Now hardcode the library paths
-       rpath=
-       hardcode_libdirs=
-+
-+      # short circuit putting rpaths in executables
-+      #
-+      if test "x$wrs_use_rpaths" != "xyes" ; then
-+        flag=
-+        for libdir in $compile_rpath; do
-+          case $(echo $libdir | ${SED} 's,/[/]*,/,g') in
-+            /usr/lib/* | /usr/lib32/* | /usr/lib64/* ) flag="$flag $libdir" ;;
-+          esac
-+        done
-+        compile_rpath="$flag"
-+
-+        flag=
-+        for libdir in $finalize_rpath; do
-+          case $(echo $libdir | ${SED} 's,/[/]*,/,g') in
-+            /usr/lib/* | /usr/lib32/* | /usr/lib64/* ) flag="$flag $libdir" ;;
-+          esac
-+        done
-+        finalize_rpath="$flag"
-+      fi
-+
-       for libdir in $compile_rpath $finalize_rpath; do
- 	if test -n "$hardcode_libdir_flag_spec"; then
- 	  if test -n "$hardcode_libdir_separator"; then
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/configure-allow-to-disable-selinux-support.patch b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/configure-allow-to-disable-selinux-support.patch
new file mode 100644
index 0000000..a6ccfb6
--- /dev/null
+++ b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/configure-allow-to-disable-selinux-support.patch
@@ -0,0 +1,38 @@
+From 166cbc02f72d13d5e7bf08ac2351c0f07e1ff4b9 Mon Sep 17 00:00:00 2001
+From: Wenzong Fan <wenzong.fan@windriver.com>
+Date: Mon, 1 Dec 2014 02:08:27 -0500
+Subject: [PATCH] apache2: allow to disable selinux support
+
+Upstream-Status: Pending
+
+Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
+
+---
+ configure.in | 14 ++++++++++----
+ 1 file changed, 10 insertions(+), 4 deletions(-)
+
+diff --git a/configure.in b/configure.in
+index 54dfd0d..377e062 100644
+--- a/configure.in
++++ b/configure.in
+@@ -466,10 +466,16 @@ getloadavg
+ dnl confirm that a void pointer is large enough to store a long integer
+ APACHE_CHECK_VOID_PTR_LEN
+ 
+-AC_CHECK_LIB(selinux, is_selinux_enabled, [
+-   AC_DEFINE(HAVE_SELINUX, 1, [Defined if SELinux is supported])
+-   APR_ADDTO(AP_LIBS, [-lselinux])
+-])
++# SELinux support
++AC_ARG_ENABLE(selinux,APACHE_HELP_STRING(--enable-selinux,Enable SELinux support [default=auto]),
++    [],[enable_selinux=auto])
++
++if test x$enable_selinux != xno; then
++    AC_CHECK_LIB(selinux, is_selinux_enabled, [
++        AC_DEFINE(HAVE_SELINUX, 1, [Defined if SELinux is supported])
++        APR_ADDTO(AP_LIBS, [-lselinux])
++    ])
++fi
+ 
+ AC_CACHE_CHECK([for gettid()], ac_cv_gettid,
+ [AC_TRY_RUN(#define _GNU_SOURCE
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/httpd-2.4.1-corelimit.patch b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/httpd-2.4.1-corelimit.patch
index 18e4107..ae4ff0c 100644
--- a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/httpd-2.4.1-corelimit.patch
+++ b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/httpd-2.4.1-corelimit.patch
@@ -1,15 +1,25 @@
+From 55ebb07cc57854cbfb372c3a688365039b809bc8 Mon Sep 17 00:00:00 2001
+From: Paul Eggleton <paul.eggleton@linux.intel.com>
+Date: Tue, 17 Jul 2012 11:27:39 +0100
+Subject: [PATCH] apache2: add from OE-Classic, update to version 2.4.2 and fix
 
 Bump up the core size limit if CoreDumpDirectory is
 configured.
 
-Upstream-Status: Pending 
+Upstream-Status: Pending
 
 Note: upstreaming was discussed but there are competing desires;
 	there are portability oddities here too.
 
---- httpd-2.4.1/server/core.c.corelimit
-+++ httpd-2.4.1/server/core.c
-@@ -4433,6 +4433,25 @@ static int core_post_config(apr_pool_t *
+---
+ server/core.c | 19 +++++++++++++++++++
+ 1 file changed, 19 insertions(+)
+
+diff --git a/server/core.c b/server/core.c
+index 4af0816..4fd2b9f 100644
+--- a/server/core.c
++++ b/server/core.c
+@@ -4940,6 +4940,25 @@ static int core_post_config(apr_pool_t *pconf, apr_pool_t *plog, apr_pool_t *pte
      }
      apr_pool_cleanup_register(pconf, NULL, ap_mpm_end_gen_helper,
                                apr_pool_cleanup_null);
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/httpd-2.4.1-selinux.patch b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/httpd-2.4.1-selinux.patch
index 873328d..015034c 100644
--- a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/httpd-2.4.1-selinux.patch
+++ b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/httpd-2.4.1-selinux.patch
@@ -1,3 +1,7 @@
+From 33c0f2d88ccfe02777f183eb785bb2b891aff168 Mon Sep 17 00:00:00 2001
+From: Paul Eggleton <paul.eggleton@linux.intel.com>
+Date: Tue, 17 Jul 2012 11:27:39 +0100
+Subject: [PATCH] Log the SELinux context at startup.
 
 Log the SELinux context at startup.
 
@@ -5,9 +9,16 @@
 
 Note: unlikely to be any interest in this upstream
 
---- httpd-2.4.1/configure.in.selinux
-+++ httpd-2.4.1/configure.in
-@@ -458,6 +458,11 @@ fopen64
+---
+ configure.in  |  5 +++++
+ server/core.c | 26 ++++++++++++++++++++++++++
+ 2 files changed, 31 insertions(+)
+
+diff --git a/configure.in b/configure.in
+index 761e836..d828512 100644
+--- a/configure.in
++++ b/configure.in
+@@ -483,6 +483,11 @@ getloadavg
  dnl confirm that a void pointer is large enough to store a long integer
  APACHE_CHECK_VOID_PTR_LEN
  
@@ -19,9 +30,11 @@
  AC_CACHE_CHECK([for gettid()], ac_cv_gettid,
  [AC_TRY_RUN(#define _GNU_SOURCE
  #include <unistd.h>
---- httpd-2.4.1/server/core.c.selinux
-+++ httpd-2.4.1/server/core.c
-@@ -58,6 +58,10 @@
+diff --git a/server/core.c b/server/core.c
+index 4fd2b9f..c61304a 100644
+--- a/server/core.c
++++ b/server/core.c
+@@ -59,6 +59,10 @@
  #include <unistd.h>
  #endif
  
@@ -32,7 +45,7 @@
  /* LimitRequestBody handling */
  #define AP_LIMIT_REQ_BODY_UNSET         ((apr_off_t) -1)
  #define AP_DEFAULT_LIMIT_REQ_BODY       ((apr_off_t) 0)
-@@ -4452,6 +4456,28 @@ static int core_post_config(apr_pool_t *
+@@ -4959,6 +4963,28 @@ static int core_post_config(apr_pool_t *pconf, apr_pool_t *plog, apr_pool_t *pte
      }
  #endif
  
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/httpd-2.4.3-fix-race-issue-of-dir-install.patch b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/httpd-2.4.3-fix-race-issue-of-dir-install.patch
new file mode 100644
index 0000000..2262e9f
--- /dev/null
+++ b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/httpd-2.4.3-fix-race-issue-of-dir-install.patch
@@ -0,0 +1,33 @@
+From 3b079a9df7582e305246fd805837d87a2c4ef534 Mon Sep 17 00:00:00 2001
+From: Zhenhua Luo <zhenhua.luo@freescale.com>
+Date: Fri, 25 Jan 2013 18:10:50 +0800
+Subject: [PATCH] apache2: fix the race issue of parallel installation
+
+Upstream-Status: Pending
+
+fix following race issue when do parallel install
+| mkdir: cannot create directory `/home/mypc/workspace/poky/build_p4080ds_release/tmp/work/ppce500mc-fsl_networking-linux/apache2/2.4.3-r1/image/usr/share/apache2': File exists
+...
+| mkdir: cannot create directory `/home/mypc/workspace/poky/build_p4080ds_release/tmp/work/ppce500mc-fsl_networking-linux/apache2/2.4.3-r1/image/usr/share/apache2': File exists
+| make[1]: *** [install-man] Error 1
+| make[1]: *** Waiting for unfinished jobs....
+
+Signed-off-by: Zhenhua Luo <zhenhua.luo@freescale.com>
+
+---
+ build/mkdir.sh | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/build/mkdir.sh b/build/mkdir.sh
+index e2d5bb6..dde5ae0 100755
+--- a/build/mkdir.sh
++++ b/build/mkdir.sh
+@@ -39,7 +39,7 @@ for file in ${1+"$@"} ; do
+         esac
+         if test ! -d "$pathcomp"; then
+             echo "mkdir $pathcomp" 1>&2
+-            mkdir "$pathcomp" || errstatus=$?
++            mkdir -p "$pathcomp" || errstatus=$?
+         fi
+         pathcomp="$pathcomp/"
+     done
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/httpd-2.4.4-export.patch b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/httpd-2.4.4-export.patch
index afbed8e..843226c 100644
--- a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/httpd-2.4.4-export.patch
+++ b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/httpd-2.4.4-export.patch
@@ -1,19 +1,27 @@
+From a5627edbcc88cd50caaa42ca051ac7ed3d870172 Mon Sep 17 00:00:00 2001
+From: Paul Eggleton <paul.eggleton@linux.intel.com>
+Date: Tue, 17 Jul 2012 11:27:39 +0100
+Subject: [PATCH] apache2: add from OE-Classic, update to version 2.4.2 and fix
 
 There is no need to "suck in" the apr/apr-util symbols when using
 a shared libapr{,util}, it just bloats the symbol table; so don't.
 
-Upstream-HEAD: needed
-Upstream-2.0: omit
 Upstream-Status: Pending
 
 Note: EXPORT_DIRS change is conditional on using shared apr
 
---- httpd-2.4.4/server/Makefile.in.export
-+++ httpd-2.4.4/server/Makefile.in
-@@ -57,9 +57,6 @@ export_files:
- 	( for dir in $(EXPORT_DIRS); do \
+---
+ server/Makefile.in | 3 ---
+ 1 file changed, 3 deletions(-)
+
+diff --git a/server/Makefile.in b/server/Makefile.in
+index cb11684..0d48924 100644
+--- a/server/Makefile.in
++++ b/server/Makefile.in
+@@ -60,9 +60,6 @@ export_files:
  	      ls $$dir/*.h ; \
  	  done; \
+ 	  echo "$(top_srcdir)/server/mpm_fdqueue.h"; \
 -	  for dir in $(EXPORT_DIRS_APR); do \
 -	      ls $$dir/ap[ru].h $$dir/ap[ru]_*.h 2>/dev/null; \
 -	  done; \
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/replace-lynx-to-curl-in-apachectl-script.patch b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/replace-lynx-to-curl-in-apachectl-script.patch
index e4e01b2..020f1d7 100644
--- a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/replace-lynx-to-curl-in-apachectl-script.patch
+++ b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/replace-lynx-to-curl-in-apachectl-script.patch
@@ -1,4 +1,4 @@
-From 760ccbb2fb046621a2aeaecabb2b1ef9aa280cf1 Mon Sep 17 00:00:00 2001
+From 94a9e2241ea27e75babbfdeb38043b13049e23b0 Mon Sep 17 00:00:00 2001
 From: Yulong Pei <Yulong.pei@windriver.com>
 Date: Thu, 1 Sep 2011 01:03:14 +0800
 Subject: [PATCH] replace lynx to curl in apachectl script
@@ -6,14 +6,15 @@
 Upstream-Status: Inappropriate [configuration]
 
 Signed-off-by: Yulong Pei <Yulong.pei@windriver.com>
----
- support/apachectl.in |   14 ++++++++++----
- 1 files changed, 10 insertions(+), 4 deletions(-)
 
-Index: httpd-2.4.29/support/apachectl.in
-===================================================================
---- httpd-2.4.29.orig/support/apachectl.in
-+++ httpd-2.4.29/support/apachectl.in
+---
+ support/apachectl.in | 14 ++++++++++----
+ 1 file changed, 10 insertions(+), 4 deletions(-)
+
+diff --git a/support/apachectl.in b/support/apachectl.in
+index 3281c2e..6ab4ba5 100644
+--- a/support/apachectl.in
++++ b/support/apachectl.in
 @@ -52,11 +52,11 @@ fi
  # a command that outputs a formatted text version of the HTML at the
  # url given on the command line.  Designed for lynx, however other
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/server-makefile.patch b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/server-makefile.patch
index f1349cb..5476d4f 100644
--- a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/server-makefile.patch
+++ b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2/server-makefile.patch
@@ -1,6 +1,18 @@
---- http-2.0.54/server/Makefile.in-old	2005-12-20 13:26:56.000000000 -0500
-+++ http-2.0.54/server/Makefile.in	2005-12-20 13:27:22.000000000 -0500
-@@ -27,7 +27,7 @@
+From aa02bbfd8f16871db5563a95fa94dd170964949f Mon Sep 17 00:00:00 2001
+From: Paul Eggleton <paul.eggleton@linux.intel.com>
+Date: Tue, 17 Jul 2012 11:27:39 +0100
+
+Upstream-Status: Inappropriate [embedded specific]
+
+---
+ server/Makefile.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/server/Makefile.in b/server/Makefile.in
+index 1fa3344..cb11684 100644
+--- a/server/Makefile.in
++++ b/server/Makefile.in
+@@ -29,7 +29,7 @@ gen_test_char: $(gen_test_char_OBJECTS)
  	$(LINK) $(EXTRA_LDFLAGS) $(gen_test_char_OBJECTS) $(EXTRA_LIBS)
  
  test_char.h: gen_test_char
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2_2.4.29.bb b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2_2.4.29.bb
deleted file mode 100644
index f0298b9..0000000
--- a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2_2.4.29.bb
+++ /dev/null
@@ -1,194 +0,0 @@
-DESCRIPTION = "The Apache HTTP Server is a powerful, efficient, and \
-extensible web server."
-SUMMARY = "Apache HTTP Server"
-HOMEPAGE = "http://httpd.apache.org/"
-DEPENDS = "libtool-native apache2-native openssl expat pcre apr apr-util"
-SECTION = "net"
-LICENSE = "Apache-2.0"
-
-SRC_URI = "${APACHE_MIRROR}/httpd/httpd-${PV}.tar.bz2 \
-           file://server-makefile.patch \
-           file://httpd-2.4.1-corelimit.patch \
-           file://httpd-2.4.4-export.patch \
-           file://httpd-2.4.1-selinux.patch \
-           file://apache-configure_perlbin.patch \
-           file://replace-lynx-to-curl-in-apachectl-script.patch \
-           file://apache-ssl-ltmain-rpath.patch \
-           file://httpd-2.4.3-fix-race-issue-of-dir-install.patch \
-           file://0001-configure-use-pkg-config-for-PCRE-detection.patch \
-           file://configure-allow-to-disable-selinux-support.patch \
-           file://init \
-           file://apache2-volatile.conf \
-           file://apache2.service \
-           file://volatiles.04_apache2 \
-          "
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=a62b0c7623826ff99766ff13fb9007f8"
-SRC_URI[md5sum] = "0c599404ef6b69eee95bcd9fcd094407"
-SRC_URI[sha256sum] = "777753a5a25568a2a27428b2214980564bc1c38c1abf9ccc7630b639991f7f00"
-
-S = "${WORKDIR}/httpd-${PV}"
-
-inherit autotools update-rc.d pkgconfig systemd
-
-SYSTEMD_SERVICE_${PN} = "apache2.service"
-SYSTEMD_AUTO_ENABLE_${PN} = "disable"
-
-SSTATE_SCAN_FILES += "apxs config_vars.mk config.nice"
-
-CFLAGS_append = " -DPATH_MAX=4096"
-CFLAGS_prepend = "-I${STAGING_INCDIR}/openssl "
-EXTRA_OECONF = "--enable-ssl \
-    --with-ssl=${STAGING_LIBDIR}/.. \
-    --with-expat=${STAGING_LIBDIR}/.. \
-    --with-apr=${STAGING_BINDIR_CROSS}/apr-1-config \
-    --with-apr-util=${STAGING_BINDIR_CROSS}/apu-1-config \
-    --enable-info \
-    --enable-rewrite \
-    --with-dbm=sdbm \
-    --with-berkeley-db=no \
-    --localstatedir=/var/${BPN} \
-    --with-gdbm=no \
-    --with-ndbm=no \
-    --includedir=${includedir}/${BPN} \
-    --datadir=${datadir}/${BPN} \
-    --sysconfdir=${sysconfdir}/${BPN} \
-    --libexecdir=${libdir}/${BPN}/modules \
-    ap_cv_void_ptr_lt_long=no \
-    --enable-mpms-shared \
-    ac_cv_have_threadsafe_pollset=no"
-
-PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'selinux', d)}"
-PACKAGECONFIG[selinux] = "--enable-selinux --enable-layout=Debian --prefix=${base_prefix}/,--disable-selinux,libselinux,libselinux"
-PACKAGECONFIG[openldap] = "--enable-ldap --enable-authnz-ldap,--disable-ldap --disable-authnz-ldap,openldap"
-
-do_configure_prepend() {
-        sed -i -e 's:$''{prefix}/usr/lib/cgi-bin:$''{libdir}/cgi-bin:g' ${S}/config.layout
-}
-
-do_install_append() {
-    install -d ${D}/${sysconfdir}/init.d
-    cat ${WORKDIR}/init | \
-        sed -e 's,/usr/sbin/,${sbindir}/,g' \
-            -e 's,/usr/bin/,${bindir}/,g' \
-            -e 's,/usr/lib,${libdir}/,g' \
-            -e 's,/etc/,${sysconfdir}/,g' \
-            -e 's,/usr/,${prefix}/,g' > ${D}/${sysconfdir}/init.d/${BPN}
-    chmod 755 ${D}/${sysconfdir}/init.d/${BPN}
-    # remove the goofy original files...
-    rm -rf ${D}/${sysconfdir}/${BPN}/original
-    # Expat should be found in the staging area via DEPENDS...
-    rm -f ${D}/${libdir}/libexpat.*
-
-    install -d ${D}${sysconfdir}/${BPN}/conf.d
-    install -d ${D}${sysconfdir}/${BPN}/modules.d
-
-    # Ensure configuration file pulls in conf.d and modules.d
-    printf "\nIncludeOptional ${sysconfdir}/${BPN}/conf.d/*.conf" >> ${D}/${sysconfdir}/${BPN}/httpd.conf
-    printf "\nIncludeOptional ${sysconfdir}/${BPN}/modules.d/*.load" >> ${D}/${sysconfdir}/${BPN}/httpd.conf
-    printf "\nIncludeOptional ${sysconfdir}/${BPN}/modules.d/*.conf\n\n" >> ${D}/${sysconfdir}/${BPN}/httpd.conf
-    # match with that is in init script
-    printf "\nPidFile /run/httpd.pid" >> ${D}/${sysconfdir}/${BPN}/httpd.conf
-    # Set 'ServerName' to fix error messages when restart apache service
-    sed -i 's/^#ServerName www.example.com/ServerName localhost/' ${D}/${sysconfdir}/${BPN}/httpd.conf
-
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-        install -d ${D}${sysconfdir}/tmpfiles.d/
-        install -m 0644 ${WORKDIR}/apache2-volatile.conf ${D}${sysconfdir}/tmpfiles.d/
-    elif ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
-        install -d ${D}${sysconfdir}/default/volatiles
-        install -m 0644 ${WORKDIR}/volatiles.04_apache2 ${D}${sysconfdir}/default/volatiles/04_apache2
-    fi
-
-    install -d ${D}${systemd_unitdir}/system
-    install -m 0644 ${WORKDIR}/apache2.service ${D}${systemd_unitdir}/system
-    sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/apache2.service
-    sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' ${D}${systemd_unitdir}/system/apache2.service
-
-    chown -R root:root ${D}
-}
-
-do_install_append_class-target() {
-    sed -i -e 's,${STAGING_DIR_HOST},,g' \
-           -e 's,APU_INCLUDEDIR = .*,APU_INCLUDEDIR = ,g' \
-           -e 's,APU_CONFIG = .*,APU_CONFIG = ,g' ${D}${datadir}/apache2/build/config_vars.mk
-
-    sed -i -e 's,${STAGING_DIR_HOST},,g' \
-           -e 's,".*/configure","configure",g' ${D}${datadir}/apache2/build/config.nice
-    rm -rf ${D}${localstatedir}/run
-}
-
-SYSROOT_PREPROCESS_FUNCS += "apache_sysroot_preprocess"
-
-apache_sysroot_preprocess () {
-    install -d ${SYSROOT_DESTDIR}${bindir_crossscripts}/
-    install -m 755 ${D}${bindir}/apxs ${SYSROOT_DESTDIR}${bindir_crossscripts}/
-    install -d ${SYSROOT_DESTDIR}${sbindir}/
-    install -m 755 ${D}${sbindir}/apachectl ${SYSROOT_DESTDIR}${sbindir}/
-    sed -i 's!my $installbuilddir = .*!my $installbuilddir = "${STAGING_DIR_HOST}/${datadir}/${BPN}/build";!' ${SYSROOT_DESTDIR}${bindir_crossscripts}/apxs
-    sed -i 's!my $libtool = .*!my $libtool = "${STAGING_BINDIR_CROSS}/${HOST_SYS}-libtool";!' ${SYSROOT_DESTDIR}${bindir_crossscripts}/apxs
-
-    sed -i 's!^APR_CONFIG = .*!APR_CONFIG = ${STAGING_BINDIR_CROSS}/apr-1-config!' ${SYSROOT_DESTDIR}${datadir}/${BPN}/build/config_vars.mk
-    sed -i 's!^APU_CONFIG = .*!APU_CONFIG = ${STAGING_BINDIR_CROSS}/apu-1-config!' ${SYSROOT_DESTDIR}${datadir}/${BPN}/build/config_vars.mk
-    sed -i 's!^includedir = .*!includedir = ${STAGING_INCDIR}/apache2!' ${SYSROOT_DESTDIR}${datadir}/${BPN}/build/config_vars.mk
-    sed -i 's!^CFLAGS = -I[^ ]*!CFLAGS = -I${STAGING_INCDIR}/openssl!' ${SYSROOT_DESTDIR}${datadir}/${BPN}/build/config_vars.mk
-    sed -i 's!^EXTRA_LDFLAGS = .*!EXTRA_LDFLAGS = -L${STAGING_LIBDIR}!' ${SYSROOT_DESTDIR}${datadir}/${BPN}/build/config_vars.mk
-    sed -i 's!^EXTRA_INCLUDES = .*!EXTRA_INCLUDES = -I$(includedir) -I. -I${STAGING_INCDIR}!' ${SYSROOT_DESTDIR}${datadir}/${BPN}/build/config_vars.mk
-    sed -i 's!--sysroot=[^ ]*!--sysroot=${STAGING_DIR_HOST}!' ${SYSROOT_DESTDIR}${datadir}/${BPN}/build/config_vars.mk
-}
-
-#
-# implications - used by update-rc.d scripts
-#
-INITSCRIPT_NAME = "apache2"
-INITSCRIPT_PARAMS = "defaults 91 20"
-LEAD_SONAME = "libapr-1.so.0"
-
-PACKAGES = "${PN}-scripts ${PN}-doc ${PN}-dev ${PN}-dbg ${PN}"
-
-CONFFILES_${PN} = "${sysconfdir}/${BPN}/httpd.conf \
-                   ${sysconfdir}/${BPN}/magic \
-                   ${sysconfdir}/${BPN}/mime.types \
-                   ${sysconfdir}/init.d/${BPN} "
-
-# we override here rather than append so that .so links are
-# included in the runtime package rather than here (-dev)
-# and to get build, icons, error into the -dev package
-FILES_${PN}-dev = "${datadir}/${BPN}/build \
-                   ${datadir}/${BPN}/icons \
-                   ${datadir}/${BPN}/error \
-                   ${bindir}/apr-config ${bindir}/apu-config \
-                   ${libdir}/apr*.exp \
-                   ${includedir}/${BPN} \
-                   ${libdir}/*.la \
-                   ${libdir}/*.a \
-                   ${bindir}/apxs \
-                "
-
-
-# manual to manual
-FILES_${PN}-doc += " ${datadir}/${BPN}/manual"
-
-FILES_${PN}-scripts += "${bindir}/dbmmanage"
-
-#
-# override this too - here is the default, less datadir
-#
-FILES_${PN} =  "${bindir} ${sbindir} ${libexecdir} ${libdir}/lib*.so.* ${sysconfdir} \
-                ${sharedstatedir} ${localstatedir} /bin /sbin /lib/*.so* \
-                ${libdir}/${BPN}"
-
-# we want htdocs and cgi-bin to go with the binary
-FILES_${PN} += "${datadir}/${BPN}/htdocs ${datadir}/${BPN}/cgi-bin"
-
-#make sure the lone .so links also get wrapped in the base package
-FILES_${PN} += "${libdir}/lib*.so ${libdir}/pkgconfig/*"
-
-FILES_${PN}-dbg += "${libdir}/${BPN}/modules/.debug"
-
-RDEPENDS_${PN} += "openssl libgcc"
-RDEPENDS_${PN}-scripts += "perl ${PN}"
-RDEPENDS_${PN}-dev = "perl"
-
-FILES_${PN} += "${libdir}/cgi-bin"
-FILES_${PN} += "${datadir}/${BPN}/"
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2_2.4.34.bb b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2_2.4.34.bb
new file mode 100644
index 0000000..a87e384
--- /dev/null
+++ b/meta-openembedded/meta-webserver/recipes-httpd/apache2/apache2_2.4.34.bb
@@ -0,0 +1,200 @@
+DESCRIPTION = "The Apache HTTP Server is a powerful, efficient, and \
+extensible web server."
+SUMMARY = "Apache HTTP Server"
+HOMEPAGE = "http://httpd.apache.org/"
+DEPENDS = "libtool-native apache2-native openssl expat pcre apr apr-util"
+SECTION = "net"
+LICENSE = "Apache-2.0"
+
+SRC_URI = "${APACHE_MIRROR}/httpd/httpd-${PV}.tar.bz2 \
+           file://server-makefile.patch \
+           file://httpd-2.4.1-corelimit.patch \
+           file://httpd-2.4.4-export.patch \
+           file://httpd-2.4.1-selinux.patch \
+           file://apache-configure_perlbin.patch \
+           file://replace-lynx-to-curl-in-apachectl-script.patch \
+           file://httpd-2.4.3-fix-race-issue-of-dir-install.patch \
+           file://0001-configure-use-pkg-config-for-PCRE-detection.patch \
+           file://configure-allow-to-disable-selinux-support.patch \
+           file://CVE-2018-11763.patch \
+           file://init \
+           file://apache2-volatile.conf \
+           file://apache2.service \
+           file://volatiles.04_apache2 \
+          "
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=d52d0fd0bc788f068e647116c01ddfcd"
+SRC_URI[md5sum] = "818adca52f3be187fe45d6822755be95"
+SRC_URI[sha256sum] = "fa53c95631febb08a9de41fd2864cfff815cf62d9306723ab0d4b8d7aa1638f0"
+
+S = "${WORKDIR}/httpd-${PV}"
+
+inherit autotools update-rc.d pkgconfig systemd update-alternatives
+
+ALTERNATIVE_${PN}-doc = "htpasswd.1"
+ALTERNATIVE_LINK_NAME[htpasswd.1] = "${mandir}/man1/htpasswd.1"
+
+SYSTEMD_SERVICE_${PN} = "apache2.service"
+SYSTEMD_AUTO_ENABLE_${PN} = "disable"
+
+SSTATE_SCAN_FILES += "apxs config_vars.mk config.nice"
+
+CFLAGS_append = " -DPATH_MAX=4096"
+CFLAGS_prepend = "-I${STAGING_INCDIR}/openssl "
+EXTRA_OECONF = "--enable-ssl \
+    --with-ssl=${STAGING_LIBDIR}/.. \
+    --with-expat=${STAGING_LIBDIR}/.. \
+    --with-apr=${STAGING_BINDIR_CROSS}/apr-1-config \
+    --with-apr-util=${STAGING_BINDIR_CROSS}/apu-1-config \
+    --enable-info \
+    --enable-rewrite \
+    --with-dbm=sdbm \
+    --with-berkeley-db=no \
+    --localstatedir=/var/${BPN} \
+    --with-gdbm=no \
+    --with-ndbm=no \
+    --includedir=${includedir}/${BPN} \
+    --datadir=${datadir}/${BPN} \
+    --sysconfdir=${sysconfdir}/${BPN} \
+    --libexecdir=${libdir}/${BPN}/modules \
+    ap_cv_void_ptr_lt_long=no \
+    --enable-mpms-shared \
+    ac_cv_have_threadsafe_pollset=no \
+    --enable-layout=Debian \
+    --prefix=${base_prefix}/"
+
+PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'selinux', d)}"
+PACKAGECONFIG[selinux] = "--enable-selinux,--disable-selinux,libselinux,libselinux"
+PACKAGECONFIG[openldap] = "--enable-ldap --enable-authnz-ldap,--disable-ldap --disable-authnz-ldap,openldap"
+PACKAGECONFIG[zlib] = "--enable-deflate --with-z=${STAGING_LIBDIR},,zlib,zlib"
+
+do_configure_prepend() {
+        sed -i -e 's:$''{prefix}/usr/lib/cgi-bin:$''{libdir}/cgi-bin:g' ${S}/config.layout
+}
+
+do_install_append() {
+    install -d ${D}/${sysconfdir}/init.d
+    cat ${WORKDIR}/init | \
+        sed -e 's,/usr/sbin/,${sbindir}/,g' \
+            -e 's,/usr/bin/,${bindir}/,g' \
+            -e 's,/usr/lib,${libdir}/,g' \
+            -e 's,/etc/,${sysconfdir}/,g' \
+            -e 's,/usr/,${prefix}/,g' > ${D}/${sysconfdir}/init.d/${BPN}
+    chmod 755 ${D}/${sysconfdir}/init.d/${BPN}
+    # remove the goofy original files...
+    rm -rf ${D}/${sysconfdir}/${BPN}/original
+    # Expat should be found in the staging area via DEPENDS...
+    rm -f ${D}/${libdir}/libexpat.*
+
+    install -d ${D}${sysconfdir}/${BPN}/conf.d
+    install -d ${D}${sysconfdir}/${BPN}/modules.d
+
+    # Ensure configuration file pulls in conf.d and modules.d
+    printf "\nIncludeOptional ${sysconfdir}/${BPN}/conf.d/*.conf" >> ${D}/${sysconfdir}/${BPN}/httpd.conf
+    printf "\nIncludeOptional ${sysconfdir}/${BPN}/modules.d/*.load" >> ${D}/${sysconfdir}/${BPN}/httpd.conf
+    printf "\nIncludeOptional ${sysconfdir}/${BPN}/modules.d/*.conf\n\n" >> ${D}/${sysconfdir}/${BPN}/httpd.conf
+    # match with that is in init script
+    printf "\nPidFile /run/httpd.pid" >> ${D}/${sysconfdir}/${BPN}/httpd.conf
+    # Set 'ServerName' to fix error messages when restart apache service
+    sed -i 's/^#ServerName www.example.com/ServerName localhost/' ${D}/${sysconfdir}/${BPN}/httpd.conf
+
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+        install -d ${D}${sysconfdir}/tmpfiles.d/
+        install -m 0644 ${WORKDIR}/apache2-volatile.conf ${D}${sysconfdir}/tmpfiles.d/
+    elif ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
+        install -d ${D}${sysconfdir}/default/volatiles
+        install -m 0644 ${WORKDIR}/volatiles.04_apache2 ${D}${sysconfdir}/default/volatiles/04_apache2
+    fi
+
+    install -d ${D}${systemd_unitdir}/system
+    install -m 0644 ${WORKDIR}/apache2.service ${D}${systemd_unitdir}/system
+    sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/apache2.service
+    sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' ${D}${systemd_unitdir}/system/apache2.service
+
+    chown -R root:root ${D}
+}
+
+do_install_append_class-target() {
+    sed -i -e 's,${STAGING_DIR_HOST},,g' \
+           -e 's,APU_INCLUDEDIR = .*,APU_INCLUDEDIR = ,g' \
+           -e 's,APU_CONFIG = .*,APU_CONFIG = ,g' ${D}${datadir}/apache2/build/config_vars.mk
+
+    sed -i -e 's,${STAGING_DIR_HOST},,g' \
+           -e 's,".*/configure","configure",g' ${D}${datadir}/apache2/build/config.nice
+    rm -rf ${D}${localstatedir}/run
+}
+
+SYSROOT_PREPROCESS_FUNCS += "apache_sysroot_preprocess"
+
+apache_sysroot_preprocess () {
+    install -d ${SYSROOT_DESTDIR}${bindir_crossscripts}/
+    install -m 755 ${D}${bindir}/apxs ${SYSROOT_DESTDIR}${bindir_crossscripts}/
+    install -d ${SYSROOT_DESTDIR}${sbindir}/
+    install -m 755 ${D}${sbindir}/apachectl ${SYSROOT_DESTDIR}${sbindir}/
+    sed -i 's!my $installbuilddir = .*!my $installbuilddir = "${STAGING_DIR_HOST}/${datadir}/${BPN}/build";!' ${SYSROOT_DESTDIR}${bindir_crossscripts}/apxs
+    sed -i 's!my $libtool = .*!my $libtool = "${STAGING_BINDIR_CROSS}/${HOST_SYS}-libtool";!' ${SYSROOT_DESTDIR}${bindir_crossscripts}/apxs
+
+    sed -i 's!^APR_CONFIG = .*!APR_CONFIG = ${STAGING_BINDIR_CROSS}/apr-1-config!' ${SYSROOT_DESTDIR}${datadir}/${BPN}/build/config_vars.mk
+    sed -i 's!^APU_CONFIG = .*!APU_CONFIG = ${STAGING_BINDIR_CROSS}/apu-1-config!' ${SYSROOT_DESTDIR}${datadir}/${BPN}/build/config_vars.mk
+    sed -i 's!^includedir = .*!includedir = ${STAGING_INCDIR}/apache2!' ${SYSROOT_DESTDIR}${datadir}/${BPN}/build/config_vars.mk
+    sed -i 's!^CFLAGS = -I[^ ]*!CFLAGS = -I${STAGING_INCDIR}/openssl!' ${SYSROOT_DESTDIR}${datadir}/${BPN}/build/config_vars.mk
+    sed -i 's!^EXTRA_LDFLAGS = .*!EXTRA_LDFLAGS = -L${STAGING_LIBDIR}!' ${SYSROOT_DESTDIR}${datadir}/${BPN}/build/config_vars.mk
+    sed -i 's!^EXTRA_INCLUDES = .*!EXTRA_INCLUDES = -I$(includedir) -I. -I${STAGING_INCDIR}!' ${SYSROOT_DESTDIR}${datadir}/${BPN}/build/config_vars.mk
+    sed -i 's!--sysroot=[^ ]*!--sysroot=${STAGING_DIR_HOST}!' ${SYSROOT_DESTDIR}${datadir}/${BPN}/build/config_vars.mk
+}
+
+#
+# implications - used by update-rc.d scripts
+#
+INITSCRIPT_NAME = "apache2"
+INITSCRIPT_PARAMS = "defaults 91 20"
+LEAD_SONAME = "libapr-1.so.0"
+
+PACKAGES = "${PN}-scripts ${PN}-doc ${PN}-dev ${PN}-dbg ${PN}"
+
+CONFFILES_${PN} = "${sysconfdir}/${BPN}/httpd.conf \
+                   ${sysconfdir}/${BPN}/magic \
+                   ${sysconfdir}/${BPN}/mime.types \
+                   ${sysconfdir}/init.d/${BPN} "
+
+# we override here rather than append so that .so links are
+# included in the runtime package rather than here (-dev)
+# and to get build, icons, error into the -dev package
+FILES_${PN}-dev = "${datadir}/${BPN}/build \
+                   ${datadir}/${BPN}/icons \
+                   ${datadir}/${BPN}/error \
+                   ${bindir}/apr-config ${bindir}/apu-config \
+                   ${libdir}/apr*.exp \
+                   ${includedir}/${BPN} \
+                   ${libdir}/*.la \
+                   ${libdir}/*.a \
+                   ${bindir}/apxs \
+                "
+
+
+# manual to manual
+FILES_${PN}-doc += " ${datadir}/${BPN}/manual"
+
+FILES_${PN}-scripts += "${bindir}/dbmmanage"
+
+#
+# override this too - here is the default, less datadir
+#
+FILES_${PN} =  "${bindir} ${sbindir} ${libexecdir} ${libdir}/lib*.so.* ${sysconfdir} \
+                ${sharedstatedir} ${localstatedir} /bin /sbin /lib/*.so* \
+                ${libdir}/${BPN}"
+
+# we want htdocs and cgi-bin to go with the binary
+FILES_${PN} += "${datadir}/${BPN}/htdocs ${datadir}/${BPN}/cgi-bin"
+
+#make sure the lone .so links also get wrapped in the base package
+FILES_${PN} += "${libdir}/lib*.so ${libdir}/pkgconfig/*"
+
+FILES_${PN}-dbg += "${libdir}/${BPN}/modules/.debug"
+
+RDEPENDS_${PN} += "openssl libgcc"
+RDEPENDS_${PN}-scripts += "perl ${PN}"
+RDEPENDS_${PN}-dev = "perl"
+
+FILES_${PN} += "${libdir}/cgi-bin"
+FILES_${PN} += "${datadir}/${BPN}/"
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/files/0001-configure-use-pkg-config-for-PCRE-detection.patch b/meta-openembedded/meta-webserver/recipes-httpd/apache2/files/0001-configure-use-pkg-config-for-PCRE-detection.patch
deleted file mode 100644
index 63096db..0000000
--- a/meta-openembedded/meta-webserver/recipes-httpd/apache2/files/0001-configure-use-pkg-config-for-PCRE-detection.patch
+++ /dev/null
@@ -1,52 +0,0 @@
-From d8837756f2a48adcfe5d645c39cf163d96eac76c Mon Sep 17 00:00:00 2001
-From: Koen Kooi <koen.kooi@linaro.org>
-Date: Tue, 17 Jun 2014 09:10:57 +0200
-Subject: [PATCH] configure: use pkg-config for PCRE detection
-
-Signed-off-by: Koen Kooi <koen.kooi@linaro.org>
-Upstream-Status: pending
----
- configure.in | 27 +++++----------------------
- 1 file changed, 5 insertions(+), 22 deletions(-)
-
-diff --git a/configure.in b/configure.in
-index 864d7c7..da4138e 100644
---- a/configure.in
-+++ b/configure.in
-@@ -215,28 +215,11 @@ fi
- AC_ARG_WITH(pcre,
- APACHE_HELP_STRING(--with-pcre=PATH,Use external PCRE library))
- 
--AC_PATH_PROG(PCRE_CONFIG, pcre-config, false)
--if test -d "$with_pcre" && test -x "$with_pcre/bin/pcre-config"; then
--   PCRE_CONFIG=$with_pcre/bin/pcre-config
--elif test -x "$with_pcre"; then
--   PCRE_CONFIG=$with_pcre
--fi
--
--if test "$PCRE_CONFIG" != "false"; then
--  if $PCRE_CONFIG --version >/dev/null 2>&1; then :; else
--    AC_MSG_ERROR([Did not find pcre-config script at $PCRE_CONFIG])
--  fi
--  case `$PCRE_CONFIG --version` in
--  [[1-5].*])
--    AC_MSG_ERROR([Need at least pcre version 6.0])
--    ;;
--  esac
--  AC_MSG_NOTICE([Using external PCRE library from $PCRE_CONFIG])
--  APR_ADDTO(PCRE_INCLUDES, [`$PCRE_CONFIG --cflags`])
--  APR_ADDTO(PCRE_LIBS, [`$PCRE_CONFIG --libs`])
--else
--  AC_MSG_ERROR([pcre-config for libpcre not found. PCRE is required and available from http://pcre.org/])
--fi
-+PKG_CHECK_MODULES([PCRE], [libpcre], [
-+  AC_DEFINE([HAVE_PCRE], [1], [Define if you have PCRE library])
-+], [
-+  AC_MSG_ERROR([$PCRE_PKG_ERRORS])
-+])
- APACHE_SUBST(PCRE_LIBS)
- 
- AC_MSG_NOTICE([])
--- 
-1.9.3
-
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/files/configure-allow-to-disable-selinux-support.patch b/meta-openembedded/meta-webserver/recipes-httpd/apache2/files/configure-allow-to-disable-selinux-support.patch
deleted file mode 100644
index 5b5c297..0000000
--- a/meta-openembedded/meta-webserver/recipes-httpd/apache2/files/configure-allow-to-disable-selinux-support.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From d23dd33e373340f6fddf11904839d1a118824401 Mon Sep 17 00:00:00 2001
-From: Wenzong Fan <wenzong.fan@windriver.com>
-Date: Mon, 1 Dec 2014 02:08:27 -0500
-Subject: [PATCH] apache2: allow to disable selinux support
-
-Upstream-Status: Pending
-
-Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
----
- configure.in |   14 ++++++++++----
- 1 file changed, 10 insertions(+), 4 deletions(-)
-
-diff --git a/configure.in b/configure.in
-index df94ee5..8c3ab21 100644
---- a/configure.in
-+++ b/configure.in
-@@ -466,10 +466,16 @@ getloadavg
- dnl confirm that a void pointer is large enough to store a long integer
- APACHE_CHECK_VOID_PTR_LEN
- 
--AC_CHECK_LIB(selinux, is_selinux_enabled, [
--   AC_DEFINE(HAVE_SELINUX, 1, [Defined if SELinux is supported])
--   APR_ADDTO(AP_LIBS, [-lselinux])
--])
-+# SELinux support
-+AC_ARG_ENABLE(selinux,APACHE_HELP_STRING(--enable-selinux,Enable SELinux support [default=auto]),
-+    [],[enable_selinux=auto])
-+
-+if test x$enable_selinux != xno; then
-+    AC_CHECK_LIB(selinux, is_selinux_enabled, [
-+        AC_DEFINE(HAVE_SELINUX, 1, [Defined if SELinux is supported])
-+        APR_ADDTO(AP_LIBS, [-lselinux])
-+    ])
-+fi
- 
- AC_CACHE_CHECK([for gettid()], ac_cv_gettid,
- [AC_TRY_RUN(#define _GNU_SOURCE
--- 
-1.7.9.5
-
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/apache2/files/httpd-2.4.3-fix-race-issue-of-dir-install.patch b/meta-openembedded/meta-webserver/recipes-httpd/apache2/files/httpd-2.4.3-fix-race-issue-of-dir-install.patch
deleted file mode 100644
index b948753..0000000
--- a/meta-openembedded/meta-webserver/recipes-httpd/apache2/files/httpd-2.4.3-fix-race-issue-of-dir-install.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-Upstream-Status: Pending
-
-fix following race issue when do parallel install
-| mkdir: cannot create directory `/home/mypc/workspace/poky/build_p4080ds_release/tmp/work/ppce500mc-fsl_networking-linux/apache2/2.4.3-r1/image/usr/share/apache2': File exists
-...
-| mkdir: cannot create directory `/home/mypc/workspace/poky/build_p4080ds_release/tmp/work/ppce500mc-fsl_networking-linux/apache2/2.4.3-r1/image/usr/share/apache2': File exists
-| make[1]: *** [install-man] Error 1
-| make[1]: *** Waiting for unfinished jobs....
-
--Signed-off-by: Zhenhua Luo <zhenhua.luo@freescale.com>
---- httpd-2.4.3/build/mkdir.sh.orig	2013-01-25 03:47:21.565255420 -0600
-+++ httpd-2.4.3/build/mkdir.sh	2013-01-25 03:46:17.833051230 -0600
-@@ -39,7 +39,7 @@
-         esac
-         if test ! -d "$pathcomp"; then
-             echo "mkdir $pathcomp" 1>&2
--            mkdir "$pathcomp" || errstatus=$?
-+            mkdir -p "$pathcomp" || errstatus=$?
-         fi
-         pathcomp="$pathcomp/"
-     done
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/hiawatha/hiawatha_10.7.bb b/meta-openembedded/meta-webserver/recipes-httpd/hiawatha/hiawatha_10.7.bb
index 4c3ca55..d6c449b 100644
--- a/meta-openembedded/meta-webserver/recipes-httpd/hiawatha/hiawatha_10.7.bb
+++ b/meta-openembedded/meta-webserver/recipes-httpd/hiawatha/hiawatha_10.7.bb
@@ -2,7 +2,7 @@
 HOMEPAGE = "http://www.hiawatha-webserver.org"
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=751419260aa954499f7abaabaa882bbe"
-DEPENDS = "libxml2 libxslt"
+DEPENDS = "libxml2 libxslt virtual/crypt"
 
 SECTION = "net"
 
@@ -23,7 +23,7 @@
 EXTRA_OECMAKE = " -DENABLE_IPV6=OFF \
                   -DENABLE_CACHE=OFF \
                   -DENABLE_DEBUG=OFF \
-                  -DENABLE_SSL=OFF \
+                  -DENABLE_TLS=OFF \
                   -DENABLE_TOOLKIT=OFF \
                   -DENABLE_CHROOT=OFF \
                   -DENABLE_XSLT=ON \
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx.inc b/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx.inc
index e6ae52a..24c2ced 100644
--- a/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx.inc
+++ b/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx.inc
@@ -9,7 +9,7 @@
 
 SECTION = "net"
 
-DEPENDS = "libpcre zlib openssl"
+DEPENDS = "libpcre zlib"
 
 SRC_URI = " \
     http://nginx.org/download/nginx-${PV}.tar.gz \
@@ -34,7 +34,10 @@
 EXTRA_OECONF = ""
 DISABLE_STATIC = ""
 
+PACKAGECONFIG ??= "ssl"
+
 PACKAGECONFIG[http2] = "--with-http_v2_module,,"
+PACKAGECONFIG[ssl] = "--with-http_ssl_module,,openssl"
 
 do_configure () {
     if [ "${SITEINFO_BITS}" = "64" ]; then
@@ -71,7 +74,7 @@
     --http-scgi-temp-path=/run/nginx/scgi_temp \
     --pid-path=/run/nginx/nginx.pid \
     --prefix=${prefix} \
-    --with-http_ssl_module \
+    --with-threads \
     --with-http_gzip_static_module \
     ${EXTRA_OECONF} ${PACKAGECONFIG_CONFARGS}
 }
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx_1.12.2.bb b/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx_1.12.2.bb
deleted file mode 100644
index 85ad29b..0000000
--- a/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx_1.12.2.bb
+++ /dev/null
@@ -1,6 +0,0 @@
-require nginx.inc
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=903753de5f86a1ee0341fd2f9491b282"
-
-SRC_URI[md5sum] = "4d2fc76211435f029271f1cf6d7eeae3"
-SRC_URI[sha256sum] = "305f379da1d5fb5aefa79e45c829852ca6983c7cd2a79328f8e084a324cf0416"
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx_1.13.9.bb b/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx_1.13.9.bb
deleted file mode 100644
index 9234794..0000000
--- a/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx_1.13.9.bb
+++ /dev/null
@@ -1,10 +0,0 @@
-require nginx.inc
-
-# 1.12.x branch is the current stable branch, the recommended default
-# 1.13.x is the current mainline branches containing all new features
-DEFAULT_PREFERENCE = "-1"
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=3691402cc54ce09f800ca348634a2dfe"
-
-SRC_URI[md5sum] = "dcd482dd98d2022659212f183e8fe81b"
-SRC_URI[sha256sum] = "5faea18857516fe68d30be39c3032bd22ed9cf85e1a6fdf32e3721d96ff7fa42"
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx_1.15.1.bb b/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx_1.15.1.bb
new file mode 100644
index 0000000..0f1ba8f
--- /dev/null
+++ b/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx_1.15.1.bb
@@ -0,0 +1,10 @@
+require nginx.inc
+
+# 1.14.x branch is the current stable branch, the recommended default
+# 1.15.x is the current mainline branches containing all new features
+DEFAULT_PREFERENCE = "-1"
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=3691402cc54ce09f800ca348634a2dfe"
+
+SRC_URI[md5sum] = "2dd5a265c54a76b699443931d80a61b9"
+SRC_URI[sha256sum] = "c7206858d7f832b8ef73a45c9b8f8e436bcb1ee88db2bc85b8e438ecec9d5460"
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx_1.15.2.bb b/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx_1.15.2.bb
new file mode 100644
index 0000000..3694f5b
--- /dev/null
+++ b/meta-openembedded/meta-webserver/recipes-httpd/nginx/nginx_1.15.2.bb
@@ -0,0 +1,6 @@
+require nginx.inc
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=3691402cc54ce09f800ca348634a2dfe"
+
+SRC_URI[md5sum] = "d063f746d3dc4298aed9c518f1684166"
+SRC_URI[sha256sum] = "eeba09aecfbe8277ac33a5a2486ec2d6731739f3c1c701b42a0c3784af67ad90"
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/nostromo/nostromo_1.9.6.bb b/meta-openembedded/meta-webserver/recipes-httpd/nostromo/nostromo_1.9.6.bb
index 16f45ce..a6b1ff0 100644
--- a/meta-openembedded/meta-webserver/recipes-httpd/nostromo/nostromo_1.9.6.bb
+++ b/meta-openembedded/meta-webserver/recipes-httpd/nostromo/nostromo_1.9.6.bb
@@ -16,7 +16,7 @@
 
 TARGET_CC_ARCH += "${LDFLAGS}"
 
-DEPENDS = "openssl groff-native base-passwd"
+DEPENDS = "openssl groff-native base-passwd virtual/crypt"
 
 inherit update-rc.d
 
diff --git a/meta-openembedded/meta-webserver/recipes-httpd/sthttpd/sthttpd_2.27.1.bb b/meta-openembedded/meta-webserver/recipes-httpd/sthttpd/sthttpd_2.27.1.bb
index 37bd753..8632b97 100644
--- a/meta-openembedded/meta-webserver/recipes-httpd/sthttpd/sthttpd_2.27.1.bb
+++ b/meta-openembedded/meta-webserver/recipes-httpd/sthttpd/sthttpd_2.27.1.bb
@@ -4,7 +4,7 @@
 LICENSE = "BSD-2-Clause"
 LIC_FILES_CHKSUM = "file://src/thttpd.c;beginline=1;endline=26;md5=0c5762c2c34dcbe9eb18815516502872"
 
-DEPENDS += "base-passwd"
+DEPENDS += "base-passwd virtual/crypt"
 
 SRC_URI = "https://github.com/blueness/${BPN}/archive/v${PV}.tar.gz;downloadfilename=${BP}.tar.gz \
            file://thttpd.service \
@@ -19,7 +19,11 @@
 
 S = "${WORKDIR}/sthttpd-${PV}"
 
-inherit autotools update-rc.d systemd
+inherit autotools update-rc.d systemd update-alternatives
+
+ALTERNATIVE_PRIORITY = "100"
+ALTERNATIVE_${PN}-doc = "htpasswd.1"
+ALTERNATIVE_LINK_NAME[htpasswd.1] = "${mandir}/man1/htpasswd.1"
 
 SRV_DIR ?= "${servicedir}/www"
 
diff --git a/meta-openembedded/meta-webserver/recipes-php/phpmyadmin/phpmyadmin_4.7.9.bb b/meta-openembedded/meta-webserver/recipes-php/phpmyadmin/phpmyadmin_4.7.9.bb
deleted file mode 100644
index 071572d..0000000
--- a/meta-openembedded/meta-webserver/recipes-php/phpmyadmin/phpmyadmin_4.7.9.bb
+++ /dev/null
@@ -1,41 +0,0 @@
-SUMMARY = "Web-based MySQL administration interface"
-HOMEPAGE = "http://www.phpmyadmin.net"
-# Main code is GPLv2, vendor/tecnickcom/tcpdf is under LGPLv3, js/jquery is under MIT
-LICENSE = "GPLv2 & LGPLv3 & MIT"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-                    file://vendor/tecnickcom/tcpdf/LICENSE.TXT;md5=5c87b66a5358ebcc495b03e0afcd342c \
-                    file://js/jquery/MIT-LICENSE.txt;md5=e43aa437a6a1ba421653bd5034333bf9 \
-"
-
-SRC_URI = "https://files.phpmyadmin.net/phpMyAdmin/${PV}/phpMyAdmin-${PV}-all-languages.tar.xz \
-           file://apache.conf \
-"
-
-SRC_URI[md5sum] = "0a862e3fa52c8b9078e0441ee82be831"
-SRC_URI[sha256sum] = "f19b503f0afb0dd3389d4bb11dab3f438d36e85eef11a5c400c592fd5f539398"
-
-UPSTREAM_CHECK_URI = "https://www.phpmyadmin.net/downloads/"
-UPSTREAM_CHECK_REGEX = "phpMyAdmin-(?P<pver>\d+(\.\d+)+)-all-languages.tar.xz"
-
-S = "${WORKDIR}/phpMyAdmin-${PV}-all-languages"
-
-inherit allarch
-
-do_install() {
-    install -d ${D}${datadir}/${BPN}
-    cp -R --no-dereference --preserve=mode,links -v * ${D}${datadir}/${BPN}
-    chown -R root:root ${D}${datadir}/${BPN}
-    # Don't install patches to target
-    rm -rf ${D}${datadir}/${BPN}/patches
-
-    install -d ${D}${sysconfdir}/apache2/conf.d
-    install -m 0644 ${WORKDIR}/apache.conf ${D}${sysconfdir}/apache2/conf.d/phpmyadmin.conf
-
-    # Remove a few scripts that explicitly require bash (!)
-    rm -f ${D}${datadir}/phpmyadmin/libraries/transformations/*.sh
-}
-
-FILES_${PN} = "${datadir}/${BPN} \
-               ${sysconfdir}/apache2/conf.d"
-
-RDEPENDS_${PN} += "bash"
diff --git a/meta-openembedded/meta-webserver/recipes-php/phpmyadmin/phpmyadmin_4.8.3.bb b/meta-openembedded/meta-webserver/recipes-php/phpmyadmin/phpmyadmin_4.8.3.bb
new file mode 100644
index 0000000..975f631
--- /dev/null
+++ b/meta-openembedded/meta-webserver/recipes-php/phpmyadmin/phpmyadmin_4.8.3.bb
@@ -0,0 +1,41 @@
+SUMMARY = "Web-based MySQL administration interface"
+HOMEPAGE = "http://www.phpmyadmin.net"
+# Main code is GPLv2, vendor/tecnickcom/tcpdf is under LGPLv3, js/jquery is under MIT
+LICENSE = "GPLv2 & LGPLv3 & MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                    file://vendor/tecnickcom/tcpdf/LICENSE.TXT;md5=5c87b66a5358ebcc495b03e0afcd342c \
+                    file://js/vendor/jquery/MIT-LICENSE.txt;md5=e43aa437a6a1ba421653bd5034333bf9 \
+"
+
+SRC_URI = "https://files.phpmyadmin.net/phpMyAdmin/${PV}/phpMyAdmin-${PV}-all-languages.tar.xz \
+           file://apache.conf \
+"
+
+SRC_URI[md5sum] = "c8a603f4b78d1dbcefc191b8ae598c79"
+SRC_URI[sha256sum] = "95f2692094d31c2c323d4767023583ab112ad54fff9e3af372710fcb676151af"
+
+UPSTREAM_CHECK_URI = "https://www.phpmyadmin.net/downloads/"
+UPSTREAM_CHECK_REGEX = "phpMyAdmin-(?P<pver>\d+(\.\d+)+)-all-languages.tar.xz"
+
+S = "${WORKDIR}/phpMyAdmin-${PV}-all-languages"
+
+inherit allarch
+
+do_install() {
+    install -d ${D}${datadir}/${BPN}
+    cp -R --no-dereference --preserve=mode,links -v * ${D}${datadir}/${BPN}
+    chown -R root:root ${D}${datadir}/${BPN}
+    # Don't install patches to target
+    rm -rf ${D}${datadir}/${BPN}/patches
+
+    install -d ${D}${sysconfdir}/apache2/conf.d
+    install -m 0644 ${WORKDIR}/apache.conf ${D}${sysconfdir}/apache2/conf.d/phpmyadmin.conf
+
+    # Remove a few scripts that explicitly require bash (!)
+    rm -f ${D}${datadir}/phpmyadmin/libraries/transformations/*.sh
+}
+
+FILES_${PN} = "${datadir}/${BPN} \
+               ${sysconfdir}/apache2/conf.d"
+
+RDEPENDS_${PN} += "bash php-cli"
diff --git a/meta-openembedded/meta-webserver/recipes-php/xdebug/xdebug_2.6.0.bb b/meta-openembedded/meta-webserver/recipes-php/xdebug/xdebug_2.6.0.bb
deleted file mode 100644
index 6516988..0000000
--- a/meta-openembedded/meta-webserver/recipes-php/xdebug/xdebug_2.6.0.bb
+++ /dev/null
@@ -1,33 +0,0 @@
-SUMMARY = "Debugging and profiling extension for PHP"
-LICENSE = "Xdebug"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=34df3a274aa12b795417c65634c07f16"
-
-DEPENDS = "php re2c-native"
-
-SRC_URI = "http://xdebug.org/files/xdebug-${PV}.tgz"
-
-SRC_URI[md5sum] = "ed3545852e6f4a00fb8730362d0431ee"
-SRC_URI[sha256sum] = "b5264cc03bf68fcbb04b97229f96dca505d7b87ec2fb3bd4249896783d29cbdc"
-
-inherit autotools
-
-EXTRA_OECONF += "--enable-xdebug -with-php-config=${STAGING_BINDIR_CROSS}/php-config"
-
-do_configure() {
-    cd ${S}
-    ${STAGING_BINDIR_CROSS}/phpize
-    cd ${B}
-
-    # Running autoreconf as autotools_do_configure would do here
-    # breaks the libtool configuration resulting in a failure later
-    # in do_compile. It's possible this may be fixable, however the
-    # easiest course of action for the moment is to avoid doing that.
-    oe_runconf
-}
-
-do_install() {
-    oe_runmake install INSTALL_ROOT=${D}
-}
-
-FILES_${PN} += "${libdir}/php*/extensions/*/*.so"
-FILES_${PN}-dbg += "${libdir}/php*/extensions/*/.debug"
diff --git a/meta-openembedded/meta-webserver/recipes-php/xdebug/xdebug_2.6.1.bb b/meta-openembedded/meta-webserver/recipes-php/xdebug/xdebug_2.6.1.bb
new file mode 100644
index 0000000..773dbf3
--- /dev/null
+++ b/meta-openembedded/meta-webserver/recipes-php/xdebug/xdebug_2.6.1.bb
@@ -0,0 +1,35 @@
+SUMMARY = "Debugging and profiling extension for PHP"
+LICENSE = "Xdebug"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=34df3a274aa12b795417c65634c07f16"
+
+DEPENDS = "php re2c-native"
+
+SRC_URI = "http://xdebug.org/files/xdebug-${PV}.tgz"
+
+SRC_URI[md5sum] = "35cc0f2e8b7d40556a9ad9afd9c49aee"
+SRC_URI[sha256sum] = "dae691d6c052073b886e0c6e1306a707bca9fd18a1e3485384ef6c4aacf1bd77"
+
+UPSTREAM_CHECK_REGEX = "xdebug-(?P<pver>\d+(\.\d+)+)\.tgz"
+
+inherit autotools
+
+EXTRA_OECONF += "--enable-xdebug -with-php-config=${STAGING_BINDIR_CROSS}/php-config"
+
+do_configure() {
+    cd ${S}
+    ${STAGING_BINDIR_CROSS}/phpize
+    cd ${B}
+
+    # Running autoreconf as autotools_do_configure would do here
+    # breaks the libtool configuration resulting in a failure later
+    # in do_compile. It's possible this may be fixable, however the
+    # easiest course of action for the moment is to avoid doing that.
+    oe_runconf
+}
+
+do_install() {
+    oe_runmake install INSTALL_ROOT=${D}
+}
+
+FILES_${PN} += "${libdir}/php*/extensions/*/*.so"
+FILES_${PN}-dbg += "${libdir}/php*/extensions/*/.debug"
diff --git a/meta-openembedded/meta-webserver/recipes-support/fcgi/fcgi/Fix_EOF_not_declared_issue.patch b/meta-openembedded/meta-webserver/recipes-support/fcgi/fcgi/Fix_EOF_not_declared_issue.patch
deleted file mode 100644
index 51ddeaa..0000000
--- a/meta-openembedded/meta-webserver/recipes-support/fcgi/fcgi/Fix_EOF_not_declared_issue.patch
+++ /dev/null
@@ -1,17 +0,0 @@
-Upstream-Status: Pending
-
-Fix EOF not declared issue, following is the error log.
-fcgio.cpp:70:72: error: 'EOF' was not declared in this scope
-              if (FCGX_PutStr(pbase(), plen, this->fcgx) != plen) return EOF;
-
-Signed-off-by: Yang Haibo <b40869@freescale.com>
---- fcgi-ori/libfcgi/fcgio.cpp 2014-07-28 18:01:00.000000000 +0800
-+++ fcgi-2.4.0/libfcgi/fcgio.cpp       2014-07-28 18:01:22.000000000 +0800
-@@ -22,6 +22,7 @@
- #define DLLAPI  __declspec(dllexport)
- #endif
-
-+#include <stdio.h>
- #include <limits.h>
- #include "fcgio.h"
-
diff --git a/meta-openembedded/meta-webserver/recipes-support/fcgi/fcgi/add_foreign_to_AM_INIT_AUTOMAKE.patch b/meta-openembedded/meta-webserver/recipes-support/fcgi/fcgi/add_foreign_to_AM_INIT_AUTOMAKE.patch
index eca694a..eec9dd7 100644
--- a/meta-openembedded/meta-webserver/recipes-support/fcgi/fcgi/add_foreign_to_AM_INIT_AUTOMAKE.patch
+++ b/meta-openembedded/meta-webserver/recipes-support/fcgi/fcgi/add_foreign_to_AM_INIT_AUTOMAKE.patch
@@ -10,8 +10,8 @@
  dnl     to configure the system for the local environment.
  
 -AC_INIT
--AM_INIT_AUTOMAKE(fcgi, 2.4.0)
-+AC_INIT([fcgi], [2.4.0])
+-AM_INIT_AUTOMAKE(fcgi, 2.4.1-SNAP-0910052249)
++AC_INIT([fcgi], [2.4.1-SNAP-0910052249])
 +AM_INIT_AUTOMAKE([foreign])
  
  AM_CONFIG_HEADER(fcgi_config.h)
diff --git a/meta-openembedded/meta-webserver/recipes-support/fcgi/fcgi_2.4.0.bb b/meta-openembedded/meta-webserver/recipes-support/fcgi/fcgi_2.4.0.bb
deleted file mode 100644
index 48c5944..0000000
--- a/meta-openembedded/meta-webserver/recipes-support/fcgi/fcgi_2.4.0.bb
+++ /dev/null
@@ -1,15 +0,0 @@
-DESCRIPTION = "FastCGI is a protocol for interfacing interactive programs with a web server."
-HOMEPAGE = "http://www.fastcgi.com"
-LICENSE = "OML"
-LIC_FILES_CHKSUM = "file://LICENSE.TERMS;md5=e3aacac3a647af6e7e31f181cda0a06a"
-
-SRC_URI = "http://fossies.org/linux/www/old/${BP}.tar.gz \
-           file://Fix_EOF_not_declared_issue.patch \
-           file://add_foreign_to_AM_INIT_AUTOMAKE.patch \
-"
-SRC_URI[md5sum] = "d15060a813b91383a9f3c66faf84867e"
-SRC_URI[sha256sum] = "66fc45c6b36a21bf2fbbb68e90f780cc21a9da1fffbae75e76d2b4402d3f05b9"
-
-inherit autotools
-
-PARALLEL_MAKE = ""
diff --git a/meta-openembedded/meta-webserver/recipes-support/fcgi/fcgi_git.bb b/meta-openembedded/meta-webserver/recipes-support/fcgi/fcgi_git.bb
new file mode 100644
index 0000000..a17e70f
--- /dev/null
+++ b/meta-openembedded/meta-webserver/recipes-support/fcgi/fcgi_git.bb
@@ -0,0 +1,17 @@
+DESCRIPTION = "FastCGI is a protocol for interfacing interactive programs with a web server."
+HOMEPAGE = "http://www.fastcgi.com"
+LICENSE = "OML"
+LIC_FILES_CHKSUM = "file://LICENSE.TERMS;md5=e3aacac3a647af6e7e31f181cda0a06a"
+
+SRCREV = "68100b5b8cb26f04b784778ed19ccef4fe389f57"
+PV = "2.4.1+git${SRCPV}"
+
+SRC_URI = "git://github.com/FastCGI-Archives/fcgi2.git;protocol=https \
+           file://add_foreign_to_AM_INIT_AUTOMAKE.patch \
+"
+
+S = "${WORKDIR}/git"
+
+inherit autotools
+
+PARALLEL_MAKE = ""
diff --git a/meta-openembedded/meta-xfce/README b/meta-openembedded/meta-xfce/README
index 7431e8b..4d8dc45 100644
--- a/meta-openembedded/meta-xfce/README
+++ b/meta-openembedded/meta-xfce/README
@@ -1,11 +1,11 @@
 This layer depends on:
 
 URI: git://github.com/openembedded/oe-core.git
-branch: master
+branch: thud
 revision: HEAD
 
 URI: git://github.com/openembedded/meta-oe.git
-branch: master
+branch: thud
 revision: HEAD
 meta-xfce depends on meta-oe, meta-gnome and meta-multimedia in this repository.
 
@@ -14,9 +14,9 @@
 
 BBMASK = "meta-xfce/recipes-multimedia"
 
-Send pull requests to openembedded-devel@lists.openembedded.org with '[meta-xfce]' in the subject'
+Send pull requests to openembedded-devel@lists.openembedded.org with '[meta-xfce][thud]' in the subject'
 
 When sending single patches, please using something like:
-'git send-email -M -1 --to openembedded-devel@lists.openembedded.org --subject-prefix=meta-xfce][PATCH'
+'git send-email -M -1 --to openembedded-devel@lists.openembedded.org --subject-prefix=meta-xfce][thud][PATCH'
 
-Layer maintainer: Andreas Müller <schnitzeltony@googlemail.com>
+Thud Maintainer: Armin Kuster <akuster808@gmail.com>
diff --git a/meta-openembedded/meta-xfce/classes/thunar-plugin.bbclass b/meta-openembedded/meta-xfce/classes/thunar-plugin.bbclass
index 95f7d00..76b0e72 100644
--- a/meta-openembedded/meta-xfce/classes/thunar-plugin.bbclass
+++ b/meta-openembedded/meta-xfce/classes/thunar-plugin.bbclass
@@ -6,7 +6,6 @@
 
 SRC_URI = "http://archive.xfce.org/src/thunar-plugins/${BPN}/${@'${PV}'[0:3]}/${BPN}-${PV}.tar.bz2"
 
-FILES_${PN} += "${libdir}/thunarx-2/*.so"
-FILES_${PN}-dbg += "${libdir}/thunarx-2/.debug"
-FILES_${PN}-dev += "${libdir}/thunarx-2/*.la"
+FILES_${PN} += "${libdir}/thunarx-3/*.so"
 
+FILES_${PN}-dev += "${libdir}/thunarx-3/*.la"
diff --git a/meta-openembedded/meta-xfce/classes/xfce-panel-plugin.bbclass b/meta-openembedded/meta-xfce/classes/xfce-panel-plugin.bbclass
index 6515dc0..29c1245 100644
--- a/meta-openembedded/meta-xfce/classes/xfce-panel-plugin.bbclass
+++ b/meta-openembedded/meta-xfce/classes/xfce-panel-plugin.bbclass
@@ -10,4 +10,5 @@
 FILES_${PN} += "${datadir}/xfce4/panel/plugins/"
 FILES_${PN} += "${libdir}/xfce4/panel-plugins/*.so"
 FILES_${PN} += "${libdir}/xfce4/panel/plugins/*.so"
-FILES_${PN}-dbg += "${libexecdir}/xfce4/panel-plugins/.debug"
+
+FILES_${PN}-dev += "${libdir}/xfce4/panel/plugins/*.la"
\ No newline at end of file
diff --git a/meta-openembedded/meta-xfce/classes/xfce.bbclass b/meta-openembedded/meta-xfce/classes/xfce.bbclass
index b49bba1..7abe46f 100644
--- a/meta-openembedded/meta-xfce/classes/xfce.bbclass
+++ b/meta-openembedded/meta-xfce/classes/xfce.bbclass
@@ -12,11 +12,3 @@
 
 FILES_${PN} += "${datadir}/icons/* ${datadir}/applications/* ${libdir}/xfce4/modules/*.so*"
 FILES_${PN}-doc += "${datadir}/xfce4/doc"
-
-FILES_${PN}-dev += "${libdir}/xfce4/*/*.la"
-FILES_${PN}-dev += "${libdir}/xfce4/*/*/*.la"
-FILES_${PN}-staticdev += "${libdir}/xfce4/*/*.a"
-FILES_${PN}-staticdev += "${libdir}/xfce4/*/*/*.a"
-FILES_${PN}-dbg += "${libdir}/xfce4/*/.debug"
-FILES_${PN}-dbg += "${libdir}/xfce4/*/*/.debug"
-
diff --git a/meta-openembedded/meta-xfce/conf/layer.conf b/meta-openembedded/meta-xfce/conf/layer.conf
index bee8e70..f5f44d6 100644
--- a/meta-openembedded/meta-xfce/conf/layer.conf
+++ b/meta-openembedded/meta-xfce/conf/layer.conf
@@ -18,7 +18,7 @@
 LAYERDEPENDS_xfce-layer += "multimedia-layer"
 LAYERDEPENDS_xfce-layer += "meta-python"
 
-LAYERSERIES_COMPAT_xfce-layer = "sumo"
+LAYERSERIES_COMPAT_xfce-layer = "thud"
 
 SIGGEN_EXCLUDE_SAFE_RECIPE_DEPS += " \
   xfce4-session->machine-host \
diff --git a/meta-openembedded/meta-xfce/recipes-apps/catfish/catfish_1.4.6.bb b/meta-openembedded/meta-xfce/recipes-apps/catfish/catfish_1.4.6.bb
new file mode 100644
index 0000000..229f882
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-apps/catfish/catfish_1.4.6.bb
@@ -0,0 +1,17 @@
+SUMMARY = "Catfish is a handy file searching tool for linux and unix"
+SECTION = "x11/application"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=4325afd396febcb659c36b49533135d4"
+
+inherit xfce-app distutils3 gtk-icon-cache
+
+DEPENDS += "python3-distutils-extra-native"
+
+B = "${S}"
+
+SRC_URI[md5sum] = "879197c9400be2a80d51abf494bfffb6"
+SRC_URI[sha256sum] = "e1caee14c5268ac781434701c0eb26eddfced2c0f1ae066549583ed05f99adbf"
+
+FILES_${PN} += "${datadir}/metainfo"
+
+RDEPENDS_${PN} += "python3-pygobject"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/menulibre/menulibre_2.1.5.bb b/meta-openembedded/meta-xfce/recipes-apps/menulibre/menulibre_2.1.5.bb
deleted file mode 100644
index d1f3471..0000000
--- a/meta-openembedded/meta-xfce/recipes-apps/menulibre/menulibre_2.1.5.bb
+++ /dev/null
@@ -1,41 +0,0 @@
-DESCRIPTION = "An advanced menu editor"
-HOMEPAGE = "https://launchpad.net/menulibre"
-SECTION = "x11/graphics"
-LICENSE = "GPLv3"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
-
-DEPENDS = " \
-    python3-distutils-extra-native \
-    intltool-native \
-"
-
-inherit distutils3 gtk-icon-cache distro_features_check
-
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI = "https://launchpad.net/menulibre/2.1/${PV}/+download/${PN}-${PV}.tar.gz"
-SRC_URI[md5sum] = "efc7edb49bb0e5fea49e158b40573334"
-SRC_URI[sha256sum] = "ef05b2722bab2acb7070d6c8ed0e7bd58bd4a4540bf498af9e889944f9da08b5"
-
-do_compile() {
-}
-
-do_install_append() {
-    sed -i 's:${D}::g' ${D}${datadir}/applications/menulibre.desktop
-    sed -i 's:share/share:share:g' ${D}${PYTHON_SITEPACKAGES_DIR}/menulibre_lib/menulibreconfig.py
-}
-
-FILES_${PN} += " \
-    ${datadir}/applications \
-    ${datadir}/menulibre \
-    ${datadir}/icons \
-"
-
-RDEPENDS_${PN} += " \
-    gtk+3 \
-    gtksourceview3 \
-    python3-pygobject \
-    gnome-menus3 \
-    python3-unixadmin \
-    python3-psutil \
-"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/menulibre/menulibre_2.2.0.bb b/meta-openembedded/meta-xfce/recipes-apps/menulibre/menulibre_2.2.0.bb
new file mode 100644
index 0000000..b0e4784
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-apps/menulibre/menulibre_2.2.0.bb
@@ -0,0 +1,41 @@
+DESCRIPTION = "An advanced menu editor"
+HOMEPAGE = "https://launchpad.net/menulibre"
+SECTION = "x11/graphics"
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
+
+DEPENDS = " \
+    python3-distutils-extra-native \
+    intltool-native \
+"
+
+inherit distutils3 gtk-icon-cache distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI = "https://launchpad.net/menulibre/2.2/${PV}/+download/${PN}-${PV}.tar.gz"
+SRC_URI[md5sum] = "9690848dbf9196c3f7baa574e90378d8"
+SRC_URI[sha256sum] = "546fec87f451c8f5c220d02b1f36dd850f4ce9ab607f8e9711ed8f2009e349fe"
+
+do_compile() {
+}
+
+do_install_append() {
+    sed -i 's:${D}::g' ${D}${datadir}/applications/menulibre.desktop
+    sed -i 's:share/share:share:g' ${D}${PYTHON_SITEPACKAGES_DIR}/menulibre_lib/menulibreconfig.py
+}
+
+FILES_${PN} += " \
+    ${datadir}/applications \
+    ${datadir}/menulibre \
+    ${datadir}/icons \
+"
+
+RDEPENDS_${PN} += " \
+    gtk+3 \
+    gtksourceview3 \
+    python3-pygobject \
+    gnome-menus3 \
+    python3-unixadmin \
+    python3-psutil \
+"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/mousepad/mousepad_0.4.0.bb b/meta-openembedded/meta-xfce/recipes-apps/mousepad/mousepad_0.4.0.bb
deleted file mode 100644
index 4ca21a6..0000000
--- a/meta-openembedded/meta-xfce/recipes-apps/mousepad/mousepad_0.4.0.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-SUMMARY = "A simple text editor for Xfce"
-SECTION = "x11/application"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
-
-# intltool to provide intltool.m4 with AC_PROG_INTLTOOL
-# xfce4-dev-tools-native for XDT_I18N macro and more importantly XDT_CHECK_OPTIONAL_PACKAGE
-# which fixes mousepad/Makefile.am:72: error: HAVE_DBUS does not appear in AM_CONDITIONAL
-DEPENDS = "gtk+ dbus dbus-glib gtksourceview2 intltool-native xfce4-dev-tools-native"
-
-inherit xfce-app gsettings
-
-SRC_URI[md5sum] = "f55314c5dda6323883241e6cf01550a7"
-SRC_URI[sha256sum] = "60114431eac8db6bb6ce18bd38f1630cccb684375b97a445a1b6fd619848d132"
-
-# we have no gtksourceview 3.x around
-EXTRA_OECONF = "--disable-gtk3"
-
-FILES_${PN} += "${datadir}/glib-2.0/schemas"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/mousepad/mousepad_0.4.1.bb b/meta-openembedded/meta-xfce/recipes-apps/mousepad/mousepad_0.4.1.bb
new file mode 100644
index 0000000..d122bfe
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-apps/mousepad/mousepad_0.4.1.bb
@@ -0,0 +1,19 @@
+SUMMARY = "A simple text editor for Xfce"
+SECTION = "x11/application"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+
+# intltool to provide intltool.m4 with AC_PROG_INTLTOOL
+# xfce4-dev-tools-native for XDT_I18N macro and more importantly XDT_CHECK_OPTIONAL_PACKAGE
+# which fixes mousepad/Makefile.am:72: error: HAVE_DBUS does not appear in AM_CONDITIONAL
+DEPENDS = "gtk+ dbus dbus-glib gtksourceview2 intltool-native xfce4-dev-tools-native"
+
+inherit xfce-app gsettings
+
+SRC_URI[md5sum] = "fb85c23bcb096a46aee9ec22b4e4fdf5"
+SRC_URI[sha256sum] = "39a7379b929d964665299c385b2cf705e32e8760698ccc34f91c990bb733518b"
+
+# we have no gtksourceview 3.x around
+EXTRA_OECONF = "--disable-gtk3"
+
+FILES_${PN} += "${datadir}/glib-2.0/schemas"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/orage/orage_4.12.1.bb b/meta-openembedded/meta-xfce/recipes-apps/orage/orage_4.12.1.bb
index a2f2568..eb9da2d 100644
--- a/meta-openembedded/meta-xfce/recipes-apps/orage/orage_4.12.1.bb
+++ b/meta-openembedded/meta-xfce/recipes-apps/orage/orage_4.12.1.bb
@@ -14,6 +14,5 @@
 
 PACKAGES =+ "xfce4-orageclock-plugin"
 FILES_${PN} += "${datadir}/dbus-1"
-FILES_${PN}-dbg += "${libdir}/xfce4/panel/plugins/.debug"
 FILES_xfce4-orageclock-plugin = "${libdir}/xfce4/panel/plugins/*.so ${datadir}/xfce4/panel/plugins"
-
+FILES_${PN}-dev += "${libdir}/xfce4/panel/plugins/*.la"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/ristretto/files/0001-Fix-build-after-update-of-xfconf.patch b/meta-openembedded/meta-xfce/recipes-apps/ristretto/files/0001-Fix-build-after-update-of-xfconf.patch
new file mode 100644
index 0000000..5cdc8c7
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-apps/ristretto/files/0001-Fix-build-after-update-of-xfconf.patch
@@ -0,0 +1,40 @@
+From 2b6bdb860ef53975c7e866f393b61d253c00754d Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
+Date: Mon, 22 Jan 2018 15:52:09 +0100
+Subject: [PATCH] Fix build after update of xfconf
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+xfconf stopped using dbus-glib so required flags must be included here
+
+Upstream-Status: Pending
+
+Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
+---
+ src/Makefile.am | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/src/Makefile.am b/src/Makefile.am
+index 36a31dc..3dd56bc 100644
+--- a/src/Makefile.am
++++ b/src/Makefile.am
+@@ -30,6 +30,7 @@ ristretto_CFLAGS = \
+ 	$(GIO_UNIX_CFLAGS) \
+ 	$(LIBEXIF_CFLAGS) \
+ 	$(XFCONF_CFLAGS) \
++	$(DBUS_GLIB_CFLAGS) \
+ 	$(EXO_CFLAGS) \
+ 	$(CAIRO_CFLAGS) \
+ 	$(LIBXFCE4UTIL_CFLAGS) \
+@@ -48,6 +49,7 @@ ristretto_LDADD = \
+ 	$(GIO_UNIX_LIBS) \
+ 	$(LIBEXIF_LIBS) \
+ 	$(XFCONF_LIBS) \
++	$(DBUS_GLIB_LIBS) \
+ 	$(EXO_LIBS) \
+ 	$(CAIRO_LIBS) \
+ 	$(LIBXFCE4UTIL_LIBS) \
+-- 
+2.14.3
+
diff --git a/meta-openembedded/meta-xfce/recipes-apps/ristretto/ristretto_0.8.2.bb b/meta-openembedded/meta-xfce/recipes-apps/ristretto/ristretto_0.8.2.bb
deleted file mode 100644
index c4baa72..0000000
--- a/meta-openembedded/meta-xfce/recipes-apps/ristretto/ristretto_0.8.2.bb
+++ /dev/null
@@ -1,15 +0,0 @@
-SUMMARY = "Tiny image-viewer"
-HOMEPAGE = "http://goodies.xfce.org/projects/applications/ristretto"
-SECTION = "x11/application"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=35d145429ad3cbf5308d1dc93f66376b"
-DEPENDS = "exo libexif gtk+ dbus-glib libxfce4ui libxfce4util xfconf cairo file"
-
-inherit xfce-app
-
-RRECOMMENDS_${PN} += "tumbler"
-
-SRC_URI[md5sum] = "a8d8bb6b8fa7f868cfa3ae778630946e"
-SRC_URI[sha256sum] = "f8f3b77ca6fc77ddf8cff1bb52e5c5802c462663f72f324393b3a0360f6901b8"
-
-FILES_${PN} += "${datadir}/appdata"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/ristretto/ristretto_0.8.3.bb b/meta-openembedded/meta-xfce/recipes-apps/ristretto/ristretto_0.8.3.bb
new file mode 100644
index 0000000..d9b9b2c
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-apps/ristretto/ristretto_0.8.3.bb
@@ -0,0 +1,16 @@
+SUMMARY = "Tiny image-viewer"
+HOMEPAGE = "http://goodies.xfce.org/projects/applications/ristretto"
+SECTION = "x11/application"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=35d145429ad3cbf5308d1dc93f66376b"
+DEPENDS = "exo libexif gtk+ dbus-glib libxfce4ui libxfce4util xfconf cairo file"
+
+inherit xfce-app
+
+RRECOMMENDS_${PN} += "tumbler"
+
+SRC_URI[md5sum] = "5866b4e11c32a38f72bc737239102544"
+SRC_URI[sha256sum] = "8c9c11760816dfd9ed57fb8b9df86c6a98a2604ab551be3133996a1c32ca2665"
+SRC_URI += "file://0001-Fix-build-after-update-of-xfconf.patch"
+
+FILES_${PN} += "${datadir}/appdata"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/xfce4-mixer/files/0001-Fix-build-after-update-of-xfconf.patch b/meta-openembedded/meta-xfce/recipes-apps/xfce4-mixer/files/0001-Fix-build-after-update-of-xfconf.patch
new file mode 100644
index 0000000..31216c0
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-apps/xfce4-mixer/files/0001-Fix-build-after-update-of-xfconf.patch
@@ -0,0 +1,61 @@
+From 6ecaeced291f935a9d41e9bc33411358c95a5e91 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
+Date: Mon, 22 Jan 2018 15:35:08 +0100
+Subject: [PATCH] Fix build after update of xfconf
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+xfconf stopped using dbus-glib so required flags must be included here
+
+Upstream-Status: Pending
+
+Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
+---
+ panel-plugin/Makefile.am | 2 ++
+ xfce4-mixer/Makefile.am  | 2 ++
+ 2 files changed, 4 insertions(+)
+
+diff --git a/panel-plugin/Makefile.am b/panel-plugin/Makefile.am
+index a494682..b094472 100644
+--- a/panel-plugin/Makefile.am
++++ b/panel-plugin/Makefile.am
+@@ -27,6 +27,7 @@ libmixer_la_CFLAGS =							\
+ 	$(LIBXFCE4UI_CFLAGS)						\
+ 	$(LIBXFCE4PANEL_CFLAGS)						\
+ 	$(XFCONF_CFLAGS)						\
++	$(DBUS_GLIB_CFLAGS)						\
+ 	$(GST_PLUGINS_BASE_CFLAGS)					\
+ 	$(KEYBINDER_CFLAGS)
+ 
+@@ -48,6 +49,7 @@ libmixer_la_LIBADD =							\
+ 	$(LIBXFCE4UI_LIBS)						\
+ 	$(LIBXFCE4PANEL_LIBS)						\
+ 	$(XFCONF_LIBS)							\
++	$(DBUS_GLIB_LIBS)						\
+ 	$(GST_PLUGINS_BASE_LIBS)					\
+ 	-lgstaudio-0.10							\
+ 	-lgstinterfaces-0.10						\
+diff --git a/xfce4-mixer/Makefile.am b/xfce4-mixer/Makefile.am
+index 4af69e9..e076fc8 100644
+--- a/xfce4-mixer/Makefile.am
++++ b/xfce4-mixer/Makefile.am
+@@ -32,6 +32,7 @@ xfce4_mixer_CFLAGS = 							\
+ 	$(UNIQUE_CFLAGS)						\
+ 	$(LIBXFCE4UTIL_CFLAGS)						\
+ 	$(LIBXFCE4UI_CFLAGS)						\
++	$(DBUS_GLIB_CFLAGS)						\
+ 	$(XFCONF_CFLAGS)						\
+ 	$(GST_PLUGINS_BASE_CFLAGS)
+ 
+@@ -46,6 +47,7 @@ xfce4_mixer_LDFLAGS = 							\
+ 	$(UNIQUE_LIBS)							\
+ 	$(LIBXFCE4UTIL_LIBS)						\
+ 	$(LIBXFCE4UI_LIBS)						\
++	$(DBUS_GLIB_LIBS)						\
+ 	$(XFCONF_LIBS)							\
+ 	$(GST_PLUGINS_BASE_LIBS)					\
+ 	-lgstaudio-0.10							\
+-- 
+2.14.3
+
diff --git a/meta-openembedded/meta-xfce/recipes-apps/xfce4-mixer/xfce4-mixer_4.11.0.bb b/meta-openembedded/meta-xfce/recipes-apps/xfce4-mixer/xfce4-mixer_4.11.0.bb
index bdbec45..6c057d8 100644
--- a/meta-openembedded/meta-xfce/recipes-apps/xfce4-mixer/xfce4-mixer_4.11.0.bb
+++ b/meta-openembedded/meta-xfce/recipes-apps/xfce4-mixer/xfce4-mixer_4.11.0.bb
@@ -6,7 +6,10 @@
 
 DEPENDS += "glib-2.0 gst-plugins-base gtk+ xfconf libunique"
 
-SRC_URI = "http://archive.xfce.org/src/apps/${BPN}/${@xfce_verdir("${PV}")}/${BPN}-${PV}.tar.bz2"
+SRC_URI = " \
+    http://archive.xfce.org/src/apps/${BPN}/${@xfce_verdir("${PV}")}/${BPN}-${PV}.tar.bz2 \
+    file://0001-Fix-build-after-update-of-xfconf.patch \
+"
 
 SRC_URI[md5sum] = "1b3753b91224867a3a2dfddda239c28d"
 SRC_URI[sha256sum] = "fb0c1df201ed1130f54f15b914cbe5a59286e994a137acda5609570c57112de2"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/xfce4-notifyd/xfce4-notifyd_0.4.2.bb b/meta-openembedded/meta-xfce/recipes-apps/xfce4-notifyd/xfce4-notifyd_0.4.2.bb
deleted file mode 100644
index 15ec51b..0000000
--- a/meta-openembedded/meta-xfce/recipes-apps/xfce4-notifyd/xfce4-notifyd_0.4.2.bb
+++ /dev/null
@@ -1,35 +0,0 @@
-SUMMARY = "Easily themable notification daemon with transparency effects"
-HOMEPAGE = "http://goodies.xfce.org/projects/applications/xfce4-notifyd"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
-DEPENDS = " \
-    dbus \
-    dbus-glib \
-    dbus-glib-native \
-    libnotify \
-    libxfce4util \
-    libxfce4ui \
-    xfconf \
-    xfce4-panel \
-"
-
-inherit xfce-app
-
-SRC_URI[md5sum] = "ecb930ef6ae6e1f310a5afe5f638eff8"
-SRC_URI[sha256sum] = "f6f28af47fdfb41db84bd003f0d76f5f4abf2137d1e27e9d378f063bb8f82356"
-
-# Avoid trouble with other desktops e.g KDE which also ships dbus service named
-# org.freedesktop.Notifications
-EXTRA_OECONF = "--disable-dbus-start-daemon"
-
-do_compile_prepend() {
-    mkdir -p xfce4-notifyd xfce4-notifyd-config
-}
-
-FILES_${PN} += " \
-    ${systemd_user_unitdir} \
-    ${datadir}/xfce4 \
-    ${datadir}/themes \
-    ${datadir}/dbus-1 \
-    ${libdir}/xfce4 \
-"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/xfce4-notifyd/xfce4-notifyd_0.4.3.bb b/meta-openembedded/meta-xfce/recipes-apps/xfce4-notifyd/xfce4-notifyd_0.4.3.bb
new file mode 100644
index 0000000..d771905
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-apps/xfce4-notifyd/xfce4-notifyd_0.4.3.bb
@@ -0,0 +1,35 @@
+SUMMARY = "Easily themable notification daemon with transparency effects"
+HOMEPAGE = "http://goodies.xfce.org/projects/applications/xfce4-notifyd"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+DEPENDS = " \
+    dbus \
+    dbus-glib \
+    dbus-glib-native \
+    libnotify \
+    libxfce4util \
+    libxfce4ui \
+    xfconf \
+    xfce4-panel \
+"
+
+inherit xfce-app
+
+SRC_URI[md5sum] = "4887c62dfcb4c3e4f45c9acfb3def515"
+SRC_URI[sha256sum] = "293dda084cfca4887ae740e2725fdfc64412bc10eac7a55a924eb14482dceac0"
+
+# Avoid trouble with other desktops e.g KDE which also ships dbus service named
+# org.freedesktop.Notifications
+EXTRA_OECONF = "--disable-dbus-start-daemon"
+
+do_compile_prepend() {
+    mkdir -p xfce4-notifyd xfce4-notifyd-config
+}
+
+FILES_${PN} += " \
+    ${systemd_user_unitdir} \
+    ${datadir}/xfce4 \
+    ${datadir}/themes \
+    ${datadir}/dbus-1 \
+    ${libdir}/xfce4 \
+"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/xfce4-panel-profiles/xfce4-panel-profiles_1.0.8.bb b/meta-openembedded/meta-xfce/recipes-apps/xfce4-panel-profiles/xfce4-panel-profiles_1.0.8.bb
new file mode 100644
index 0000000..5fa2a7b
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-apps/xfce4-panel-profiles/xfce4-panel-profiles_1.0.8.bb
@@ -0,0 +1,28 @@
+SUMMARY = "Backup, restore, import, and export panel layouts"
+SECTION = "x11/application"
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
+
+inherit python3native gettext distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+DEPENDS += "intltool-native"
+
+SRC_URI = "http://archive.xfce.org/src/apps/${BPN}/1.0/${BPN}-${PV}.tar.bz2"
+SRC_URI[md5sum] = "bc75a143423fba3a82f114f47e86580c"
+SRC_URI[sha256sum] = "a69e20f5e637319e14898b5c13ff7ba31d001a6e38e7516d70dbfd7600ad72db"
+
+do_configure() {
+    # special configure - no autotools...
+    ./configure --prefix=${prefix}
+}
+
+do_install() {
+	oe_runmake 'DESTDIR=${D}' install
+    sed -i 's:${PYTHON}:python3:g' ${D}${bindir}/xfce4-panel-profiles
+}
+
+FILES_${PN} += "${datadir}/metainfo"
+
+RDEPENDS_${PN} += "python3-pygobject python3-pexpect"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/xfce4-screenshooter/xfce4-screenshooter_1.9.1.bb b/meta-openembedded/meta-xfce/recipes-apps/xfce4-screenshooter/xfce4-screenshooter_1.9.1.bb
deleted file mode 100644
index e449dce..0000000
--- a/meta-openembedded/meta-xfce/recipes-apps/xfce4-screenshooter/xfce4-screenshooter_1.9.1.bb
+++ /dev/null
@@ -1,22 +0,0 @@
-SUMMARY = "Application to take screenshots"
-HOMEPAGE = "http://goodies.xfce.org/projects/applications/xfce4-screenshooter"
-SECTION = "x11/application"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d791728a073bc009b4ffaf00b7599855"
-DEPENDS = "xfce4-panel libxfce4util libxfce4ui gdk-pixbuf gtk+ glib-2.0 libsoup-2.4 exo libxfixes xext virtual/libx11"
-
-inherit xfce-app
-
-SRC_URI[md5sum] = "75e1501418f904769e4fd25eff6a3946"
-SRC_URI[sha256sum] = "e62b31d9cf06a7414a26400c2ebe7a2ae7c2b22aa60f997f25145ea9ebe6e0db"
-
-do_compile_prepend() {
-    mkdir -p lib
-    mkdir -p src
-}
-
-FILES_${PN} += " \
-    ${datadir}/appdata \
-    ${datadir}/xfce4/panel/plugins \
-    ${libdir}/xfce4/panel/plugins \
-"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/xfce4-screenshooter/xfce4-screenshooter_1.9.3.bb b/meta-openembedded/meta-xfce/recipes-apps/xfce4-screenshooter/xfce4-screenshooter_1.9.3.bb
new file mode 100644
index 0000000..c6a4cdb
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-apps/xfce4-screenshooter/xfce4-screenshooter_1.9.3.bb
@@ -0,0 +1,22 @@
+SUMMARY = "Application to take screenshots"
+HOMEPAGE = "http://goodies.xfce.org/projects/applications/xfce4-screenshooter"
+SECTION = "x11/application"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d791728a073bc009b4ffaf00b7599855"
+DEPENDS = "xfce4-panel libxfce4util libxfce4ui gdk-pixbuf gtk+ glib-2.0 libsoup-2.4 exo libxfixes xext virtual/libx11"
+
+inherit xfce-app
+
+SRC_URI[md5sum] = "f783eb575e2015f39e1c1aae499b113f"
+SRC_URI[sha256sum] = "364ebddc4c9971b4023aa8019d4e3bd08f091b65dc98b218beb55851f69ceda2"
+
+do_compile_prepend() {
+    mkdir -p lib
+    mkdir -p src panel-plugin
+}
+
+FILES_${PN} += " \
+    ${datadir}/appdata \
+    ${datadir}/xfce4/panel/plugins \
+    ${libdir}/xfce4/panel/plugins \
+"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/xfce4-taskmanager/xfce4-taskmanager_1.2.0.bb b/meta-openembedded/meta-xfce/recipes-apps/xfce4-taskmanager/xfce4-taskmanager_1.2.0.bb
deleted file mode 100644
index f955585..0000000
--- a/meta-openembedded/meta-xfce/recipes-apps/xfce4-taskmanager/xfce4-taskmanager_1.2.0.bb
+++ /dev/null
@@ -1,10 +0,0 @@
-SUMMARY = "Easy to use task manager"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
-
-inherit xfce-app
-
-DEPENDS += "gtk+ cairo libwnck libxmu xfce4-dev-tools-native exo-native"
-
-SRC_URI[md5sum] = "6f30ce3c688454812008281065a6e05c"
-SRC_URI[sha256sum] = "5746d473ad428b13db7c05cfcbc8099fbea13da6be26d3a9359bcb4de971ba69"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/xfce4-taskmanager/xfce4-taskmanager_1.2.1.bb b/meta-openembedded/meta-xfce/recipes-apps/xfce4-taskmanager/xfce4-taskmanager_1.2.1.bb
new file mode 100644
index 0000000..8afea1d
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-apps/xfce4-taskmanager/xfce4-taskmanager_1.2.1.bb
@@ -0,0 +1,10 @@
+SUMMARY = "Easy to use task manager"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+
+inherit xfce-app
+
+DEPENDS += "gtk+ cairo libwnck libxmu xfce4-dev-tools-native exo-native"
+
+SRC_URI[md5sum] = "4a2d0b1e8001fb343139a97d57b56eaa"
+SRC_URI[sha256sum] = "22e523e2ee231713f40a48890d8cbae99320ac1173f7c68502f490318e1e0409"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/xfce4-terminal/xfce4-terminal_0.8.7.3.bb b/meta-openembedded/meta-xfce/recipes-apps/xfce4-terminal/xfce4-terminal_0.8.7.3.bb
deleted file mode 100644
index 7630abc..0000000
--- a/meta-openembedded/meta-xfce/recipes-apps/xfce4-terminal/xfce4-terminal_0.8.7.3.bb
+++ /dev/null
@@ -1,12 +0,0 @@
-SUMMARY = "Terminal emulator for the Xfce desktop environment"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-DEPENDS = "glib-2.0 gtk+3 vte libxfce4ui"
-
-inherit xfce-app
-
-FILES_${PN} += "${datadir}/xfce4 \
-                ${datadir}/gnome-control-center"
-
-SRC_URI[md5sum] = "f014d613438848b452f1f9eecbf7027d"
-SRC_URI[sha256sum] = "dafa155177934fc7dce2d4efb33402f74b1a593a17ff17d2187a6429f599dfd6"
diff --git a/meta-openembedded/meta-xfce/recipes-apps/xfce4-terminal/xfce4-terminal_0.8.7.4.bb b/meta-openembedded/meta-xfce/recipes-apps/xfce4-terminal/xfce4-terminal_0.8.7.4.bb
new file mode 100644
index 0000000..7fc638e
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-apps/xfce4-terminal/xfce4-terminal_0.8.7.4.bb
@@ -0,0 +1,12 @@
+SUMMARY = "Terminal emulator for the Xfce desktop environment"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+DEPENDS = "glib-2.0 gtk+3 vte libxfce4ui"
+
+inherit xfce-app
+
+FILES_${PN} += "${datadir}/xfce4 \
+                ${datadir}/gnome-control-center"
+
+SRC_URI[md5sum] = "c861540dd1dd05f56e62382b3851cf66"
+SRC_URI[sha256sum] = "a88f98af4da72394f2cfbd7f14b0f053ec0a3b58a4f6a577836357c60a6c42ab"
diff --git a/meta-openembedded/meta-xfce/recipes-bindings/vala/xfce4-vala_4.10.3.bb b/meta-openembedded/meta-xfce/recipes-bindings/vala/xfce4-vala_4.10.3.bb
index 28f9cde..97007be 100644
--- a/meta-openembedded/meta-xfce/recipes-bindings/vala/xfce4-vala_4.10.3.bb
+++ b/meta-openembedded/meta-xfce/recipes-bindings/vala/xfce4-vala_4.10.3.bb
@@ -11,7 +11,7 @@
 SRC_URI[md5sum] = "0bbb1d6e473e0fe9b335b7b1b49d8a71"
 SRC_URI[sha256sum] = "07a8f2b7c09fcdd3d86e0c52adea3c58ca011d0142a93997a01b4af77260ae7b"
 
-EXTRA_OECONF = "-with-vala-api=0.38"
+EXTRA_OECONF = "-with-vala-api=0.42"
 
 FILES_${PN} += "${datadir}/vala-*/vapi"
 
diff --git a/meta-openembedded/meta-xfce/recipes-connectivity/blueman/blueman_%.bbappend b/meta-openembedded/meta-xfce/recipes-connectivity/blueman/blueman_%.bbappend
new file mode 100644
index 0000000..c475223
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-connectivity/blueman/blueman_%.bbappend
@@ -0,0 +1 @@
+PACKAGECONFIG_append = " thunar"
diff --git a/meta-openembedded/meta-xfce/recipes-extended/libunique/libunique_1.1.6.bb b/meta-openembedded/meta-xfce/recipes-extended/libunique/libunique_1.1.6.bb
index 49ed07a..a6475ce 100644
--- a/meta-openembedded/meta-xfce/recipes-extended/libunique/libunique_1.1.6.bb
+++ b/meta-openembedded/meta-xfce/recipes-extended/libunique/libunique_1.1.6.bb
@@ -28,3 +28,7 @@
 inherit autotools pkgconfig gobject-introspection distro_features_check gtk-doc
 
 REQUIRED_DISTRO_FEATURES = "x11"
+
+do_install_append () {
+    rmdir --ignore-fail-on-non-empty ${D}${datadir}
+}
diff --git a/meta-openembedded/meta-xfce/recipes-multimedia/parole/parole_1.0.0.bb b/meta-openembedded/meta-xfce/recipes-multimedia/parole/parole_1.0.0.bb
deleted file mode 100644
index 479f1a4..0000000
--- a/meta-openembedded/meta-xfce/recipes-multimedia/parole/parole_1.0.0.bb
+++ /dev/null
@@ -1,38 +0,0 @@
-DESCRIPTION = "Parole is a modern simple media player based on the GStreamer framework"
-HOMEPAGE = "http://goodies.xfce.org/projects/applications/parole"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552"
-
-inherit xfce-app gtk-doc mime
-
-DEPENDS += " \
-    glib-2.0 \
-    dbus-glib \
-    gtk+3 \
-    \
-    xfce4-dev-tools-native \
-    libxfce4util \
-    libxfce4ui \
-    xfconf \
-    \
-    gstreamer1.0-plugins-base \
-    taglib \
-"
-
-SRC_URI[md5sum] = "d00d3ca571900826bf5e1f6986e42992"
-SRC_URI[sha256sum] = "6666b335aeb690fb527f77b62c322baf34834b593659fdcd21d21ed3f1e14010"
-
-RDEPENDS_${PN} += "gstreamer1.0-plugins-good"
-
-EXTRA_OECONF = "--disable-gtk-doc"
-
-PACKAGECONFIG ??= "notify"
-PACKAGECONFIG[clutter] = "--enable-clutter, --disable-clutter, clutter"
-PACKAGECONFIG[notify] = "--enable-notify-plugin, --disable-notify-plugin, libnotify"
-
-FILES_${PN} += " \
-    ${datadir}/appdata \
-    ${libdir}/parole-0/*.so \
-"
-FILES_${PN}-dbg += "${libdir}/parole-0/.debug"
-FILES_${PN}-dev += "${libdir}/parole-0/*.la"
diff --git a/meta-openembedded/meta-xfce/recipes-multimedia/parole/parole_1.0.1.bb b/meta-openembedded/meta-xfce/recipes-multimedia/parole/parole_1.0.1.bb
new file mode 100644
index 0000000..2b4e974
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-multimedia/parole/parole_1.0.1.bb
@@ -0,0 +1,38 @@
+DESCRIPTION = "Parole is a modern simple media player based on the GStreamer framework"
+HOMEPAGE = "http://goodies.xfce.org/projects/applications/parole"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552"
+
+inherit xfce-app gtk-doc mime
+
+DEPENDS += " \
+    glib-2.0 \
+    dbus-glib \
+    gtk+3 \
+    \
+    xfce4-dev-tools-native \
+    libxfce4util \
+    libxfce4ui \
+    xfconf \
+    \
+    gstreamer1.0-plugins-base \
+    taglib \
+"
+
+SRC_URI[md5sum] = "46fe86bbe0c4aa02c53244d66e62e90c"
+SRC_URI[sha256sum] = "8ad2931fdb35415cc3d7551b5f2207bfaa1aba15545accbacbb4984cdabd7099"
+
+RDEPENDS_${PN} += "gstreamer1.0-plugins-good"
+
+EXTRA_OECONF = "--disable-gtk-doc"
+
+PACKAGECONFIG ??= "notify"
+PACKAGECONFIG[clutter] = "--enable-clutter, --disable-clutter, clutter"
+PACKAGECONFIG[notify] = "--enable-notify-plugin, --disable-notify-plugin, libnotify"
+
+FILES_${PN} += " \
+    ${datadir}/appdata \
+    ${libdir}/parole-0/*.so \
+"
+
+FILES_${PN}-dev += "${libdir}/parole-0/*.la"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/battery/xfce4-battery-plugin_1.1.0.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/battery/xfce4-battery-plugin_1.1.0.bb
deleted file mode 100644
index 9d2d954..0000000
--- a/meta-openembedded/meta-xfce/recipes-panel-plugins/battery/xfce4-battery-plugin_1.1.0.bb
+++ /dev/null
@@ -1,9 +0,0 @@
-SUMMARY = "A battery monitor panel plugin for Xfce4, compatible with APM and ACP"
-HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-battery-plugin"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
-
-inherit xfce-panel-plugin
-
-SRC_URI[md5sum] = "f78d8d0cc13d40753a207a836869b953"
-SRC_URI[sha256sum] = "8c9deec8d95da4cc39d6d9091433e5822b6bbe07d80117045dd4dd3480427ece"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/battery/xfce4-battery-plugin_1.1.1.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/battery/xfce4-battery-plugin_1.1.1.bb
new file mode 100644
index 0000000..af7c65a
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-panel-plugins/battery/xfce4-battery-plugin_1.1.1.bb
@@ -0,0 +1,9 @@
+SUMMARY = "A battery monitor panel plugin for Xfce4, compatible with APM and ACP"
+HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-battery-plugin"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+
+inherit xfce-panel-plugin
+
+SRC_URI[md5sum] = "26941c579ebf4143b7e49aa08ee9b30a"
+SRC_URI[sha256sum] = "1e94969b93e0c1d6da87364b64c0cdfb40bae5e4a055039be8b67b9e5b3dd44b"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/clipman/xfce4-clipman-plugin_1.4.2.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/clipman/xfce4-clipman-plugin_1.4.2.bb
deleted file mode 100644
index 96bdf0e..0000000
--- a/meta-openembedded/meta-xfce/recipes-panel-plugins/clipman/xfce4-clipman-plugin_1.4.2.bb
+++ /dev/null
@@ -1,17 +0,0 @@
-SUMMARY = "Clipman is a clipboard manager for Xfce"
-HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-clipman-plugin"
-SECTION = "x11/application"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
-
-inherit xfce-panel-plugin
-
-DEPENDS += "xfconf xproto libxtst"
-
-SRC_URI[md5sum] = "9169140af7c9d3fddd8a5c9e0efb5a61"
-SRC_URI[sha256sum] = "cf2b45e327e67cc187dcb99a6ef6d95570463045accd24540e17172f005189b3"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[qrencode] = "--enable-libqrencode,--disable-libqrencode,qrencode"
-
-FILES_${PN} += "${datadir}/appdata"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/clipman/xfce4-clipman-plugin_1.4.3.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/clipman/xfce4-clipman-plugin_1.4.3.bb
new file mode 100644
index 0000000..a1ac057
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-panel-plugins/clipman/xfce4-clipman-plugin_1.4.3.bb
@@ -0,0 +1,17 @@
+SUMMARY = "Clipman is a clipboard manager for Xfce"
+HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-clipman-plugin"
+SECTION = "x11/application"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
+
+inherit xfce-panel-plugin
+
+DEPENDS += "xfconf xorgproto libxtst"
+
+SRC_URI[md5sum] = "fa0acd5f5e3298e56ebd47d2944cd02b"
+SRC_URI[sha256sum] = "29cdb85efb54bd5c9c04cc695b7c4914d6dff972b9fd969cbfb5504e9c632ad2"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[qrencode] = "--enable-libqrencode,--disable-libqrencode,qrencode"
+
+FILES_${PN} += "${datadir}/appdata"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/cpufreq/xfce4-cpufreq-plugin_1.1.3.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/cpufreq/xfce4-cpufreq-plugin_1.1.3.bb
deleted file mode 100644
index d454787..0000000
--- a/meta-openembedded/meta-xfce/recipes-panel-plugins/cpufreq/xfce4-cpufreq-plugin_1.1.3.bb
+++ /dev/null
@@ -1,9 +0,0 @@
-SUMMARY = "Panel plugin to display frequency of all cpus"
-HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-cpufreq-plugin"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=1f6f1c0be32491a0c8d2915607a28f36"
-
-inherit xfce-panel-plugin
-
-SRC_URI[md5sum] = "859122da0a8cd991ee2fbeee434bc948"
-SRC_URI[sha256sum] = "74a162c7e101db0495d5da147aba1f404c33544f04e8c34d7d1d705668102d33"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/cpufreq/xfce4-cpufreq-plugin_1.2.1.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/cpufreq/xfce4-cpufreq-plugin_1.2.1.bb
new file mode 100644
index 0000000..3f5587d
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-panel-plugins/cpufreq/xfce4-cpufreq-plugin_1.2.1.bb
@@ -0,0 +1,9 @@
+SUMMARY = "Panel plugin to display frequency of all cpus"
+HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-cpufreq-plugin"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=1f6f1c0be32491a0c8d2915607a28f36"
+
+inherit xfce-panel-plugin
+
+SRC_URI[md5sum] = "ccd8f0f7aef51bc4caf1049986d9614f"
+SRC_URI[sha256sum] = "c5e044c0dc401d2066f208a3df82a588b3e51ff01425f155d0a1d0f8fce8f5b5"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/diskperf/xfce4-diskperf-plugin/0001-panel-plugin-Include-sys-sysmacros.h-for-major-minor.patch b/meta-openembedded/meta-xfce/recipes-panel-plugins/diskperf/xfce4-diskperf-plugin/0001-panel-plugin-Include-sys-sysmacros.h-for-major-minor.patch
new file mode 100644
index 0000000..007d3e5
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-panel-plugins/diskperf/xfce4-diskperf-plugin/0001-panel-plugin-Include-sys-sysmacros.h-for-major-minor.patch
@@ -0,0 +1,30 @@
+From c35a8cb24e8adafb11cbc261de37d97244e55927 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 11 Aug 2018 10:08:27 -0700
+Subject: [PATCH] panel-plugin: Include sys/sysmacros.h for major/minor
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+glibc 2.28+ needs it
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Cc: Andreas Müller <schnitzeltony@googlemail.com>
+---
+ panel-plugin/devperf.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/panel-plugin/devperf.c b/panel-plugin/devperf.c
+index 175fd44..cb2e88a 100644
+--- a/panel-plugin/devperf.c
++++ b/panel-plugin/devperf.c
+@@ -34,6 +34,7 @@
+ #include <errno.h>
+ #include <sys/time.h>
+ /* for major() and minor() */
++#include <sys/sysmacros.h>
+ #define _BSD_SOURCE
+ #include <sys/types.h>
+ 
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/diskperf/xfce4-diskperf-plugin_2.6.1.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/diskperf/xfce4-diskperf-plugin_2.6.1.bb
index 161b2bb..dc7f1fc 100644
--- a/meta-openembedded/meta-xfce/recipes-panel-plugins/diskperf/xfce4-diskperf-plugin_2.6.1.bb
+++ b/meta-openembedded/meta-xfce/recipes-panel-plugins/diskperf/xfce4-diskperf-plugin_2.6.1.bb
@@ -5,5 +5,8 @@
 
 inherit xfce-panel-plugin
 
+SRC_URI = "http://archive.xfce.org/src/panel-plugins/${BPN}/${@'${PV}'[0:3]}/${BPN}-${PV}.tar.bz2 \
+           file://0001-panel-plugin-Include-sys-sysmacros.h-for-major-minor.patch \
+           "
 SRC_URI[md5sum] = "63d5f03934c2dbddb3ad7bf7f535cc23"
 SRC_URI[sha256sum] = "212ddc742be3eecb6ad5554e1b1df03d5685cb71f48a558d5f895de37c57e4fa"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/embed/xfce4-embed-plugin_1.0.0.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/embed/xfce4-embed-plugin_1.0.0.bb
deleted file mode 100644
index 32d6edf..0000000
--- a/meta-openembedded/meta-xfce/recipes-panel-plugins/embed/xfce4-embed-plugin_1.0.0.bb
+++ /dev/null
@@ -1,12 +0,0 @@
-DESCRIPTION = "A panel plugin that embeds arbitrary windows (or GtkPlug widgets) into the panel."
-HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-embed-plugin"
-SECTION = "x11/application"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
-
-inherit xfce-panel-plugin
-
-# DEPENDS += "xfconf xproto libxtst"
-
-SRC_URI[md5sum] = "c5b86cbc1c54ee7c1d2e95a4502fed8e"
-SRC_URI[sha256sum] = "35d4c6c56dd6468c0e5afe66f657c1526f2d830a577105a51da43657651832e3"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/embed/xfce4-embed-plugin_1.6.0.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/embed/xfce4-embed-plugin_1.6.0.bb
new file mode 100644
index 0000000..387b183
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-panel-plugins/embed/xfce4-embed-plugin_1.6.0.bb
@@ -0,0 +1,12 @@
+DESCRIPTION = "A panel plugin that embeds arbitrary windows (or GtkPlug widgets) into the panel."
+HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-embed-plugin"
+SECTION = "x11/application"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+inherit xfce-panel-plugin
+
+# DEPENDS += "xfconf xorgproto libxtst"
+
+SRC_URI[md5sum] = "6870b116b85e4fa68d1b9ef76bd1d279"
+SRC_URI[sha256sum] = "c767df6360e8194b32bc24823dd000975edba0cafe525c23d7854029359ee228"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/eyes/xfce4-eyes-plugin_4.4.5.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/eyes/xfce4-eyes-plugin_4.4.5.bb
deleted file mode 100644
index 4e4c410..0000000
--- a/meta-openembedded/meta-xfce/recipes-panel-plugins/eyes/xfce4-eyes-plugin_4.4.5.bb
+++ /dev/null
@@ -1,11 +0,0 @@
-SUMMARY = "Panel plugin with graphical representation of the cpu frequency"
-HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-eyes-plugin"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-
-inherit xfce-panel-plugin
-
-SRC_URI[md5sum] = "b2881924fdcc1230d9fa82c10f1a6afe"
-SRC_URI[sha256sum] = "648f7a1738d852af9482d11330b8ab33901f05256984de73d8cea4d7d7311937"
-
-FILES_${PN} += "${datadir}/xfce4/eyes"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/eyes/xfce4-eyes-plugin_4.5.0.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/eyes/xfce4-eyes-plugin_4.5.0.bb
new file mode 100644
index 0000000..e5c21a1
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-panel-plugins/eyes/xfce4-eyes-plugin_4.5.0.bb
@@ -0,0 +1,11 @@
+SUMMARY = "Panel plugin with graphical representation of the cpu frequency"
+HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-eyes-plugin"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+inherit xfce-panel-plugin
+
+SRC_URI[md5sum] = "6e274ceda37c7a8ae0821d9d49e965e9"
+SRC_URI[sha256sum] = "fdae00036383105a15d12e9809abd5945a8f2152b17e16ccdfbfe5bd9733f29d"
+
+FILES_${PN} += "${datadir}/xfce4/eyes"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/genmon/xfce4-genmon-plugin_4.0.0.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/genmon/xfce4-genmon-plugin_4.0.0.bb
deleted file mode 100644
index 0624fe9..0000000
--- a/meta-openembedded/meta-xfce/recipes-panel-plugins/genmon/xfce4-genmon-plugin_4.0.0.bb
+++ /dev/null
@@ -1,9 +0,0 @@
-DESCRIPTION = "This plugin cyclically spawns the indicated script/program, captures its output (stdout) and displays the resulting string into the panel."
-HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-genmon-plugin"
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=68ad62c64cc6c620126241fd429e68fe"
-
-inherit xfce-panel-plugin
-
-SRC_URI[md5sum] = "f28cfbf9c82e758a236c1f5fcbcb8a35"
-SRC_URI[sha256sum] = "a7db4f786166643076323dcde99ad12e92383cc29b4b806862d5483ec468c3e3"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/genmon/xfce4-genmon-plugin_4.0.1.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/genmon/xfce4-genmon-plugin_4.0.1.bb
new file mode 100644
index 0000000..002e93d
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-panel-plugins/genmon/xfce4-genmon-plugin_4.0.1.bb
@@ -0,0 +1,9 @@
+DESCRIPTION = "This plugin cyclically spawns the indicated script/program, captures its output (stdout) and displays the resulting string into the panel."
+HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-genmon-plugin"
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=68ad62c64cc6c620126241fd429e68fe"
+
+inherit xfce-panel-plugin
+
+SRC_URI[md5sum] = "9dd0681c179302d56d92bbda5765bd09"
+SRC_URI[sha256sum] = "4c6ce37fbe71094548b44862587c2813da991aeaaecff8e572724dbbec83ab86"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/hotcorner/xfce4-hotcorner-plugin/0001-CMakeLists.txt-fix-library-install-path.patch b/meta-openembedded/meta-xfce/recipes-panel-plugins/hotcorner/xfce4-hotcorner-plugin/0001-CMakeLists.txt-fix-library-install-path.patch
new file mode 100644
index 0000000..df348dc
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-panel-plugins/hotcorner/xfce4-hotcorner-plugin/0001-CMakeLists.txt-fix-library-install-path.patch
@@ -0,0 +1,39 @@
+Upstream-Status: Submitted [https://github.com/brianhsu/xfce4-hotcorner-plugin/pull/8]
+
+The library install path may be ${CMAKE_INSTALL_PREFIX}/lib64 rather
+than fixed ${CMAKE_INSTALL_PREFIX}/lib. Provide a variable to make it
+could override by cmake command line.
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+---
+ CMakeLists.txt | 7 ++++---
+ 1 file changed, 4 insertions(+), 3 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index e193787..84cb52d 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -10,8 +10,9 @@ include(GNUInstallDirs)
+ 
+ PKG_CHECK_MODULES(GTK REQUIRED libxfce4panel-1.0 libxfce4ui-1 libwnck-3.0)
+ 
+-set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
+-set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
++set(BASE_LIB_PATH "lib" CACHE STRING "base library install path")
++set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/${BASE_LIB_PATH})
++set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/${BASE_LIB_PATH})
+ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
+  
+ INCLUDE_DIRECTORIES(${GTK_INCLUDE_DIRS})
+@@ -28,7 +29,7 @@ ADD_LIBRARY(hotcorner SHARED src/hotcorner.c src/util.c)
+  
+ TARGET_LINK_LIBRARIES(hotcorner ${GTK_LIBRARIES})
+ 
+-INSTALL(TARGETS hotcorner  LIBRARY DESTINATION lib/xfce4/panel/plugins/)
++INSTALL(TARGETS hotcorner  LIBRARY DESTINATION ${BASE_LIB_PATH}/xfce4/panel/plugins/)
+ INSTALL(FILES hotcorner.desktop DESTINATION share/xfce4/panel/plugins/)
+ GETTEXT_CREATE_TRANSLATIONS(po/xfce4-hotcorner-plugin.pot ALL po/zh_TW.po)
+ 
+-- 
+2.11.0
+
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/hotcorner/xfce4-hotcorner-plugin_0.0.2.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/hotcorner/xfce4-hotcorner-plugin_0.0.2.bb
index f86c92e..57a815b 100644
--- a/meta-openembedded/meta-xfce/recipes-panel-plugins/hotcorner/xfce4-hotcorner-plugin_0.0.2.bb
+++ b/meta-openembedded/meta-xfce/recipes-panel-plugins/hotcorner/xfce4-hotcorner-plugin_0.0.2.bb
@@ -6,6 +6,9 @@
 
 DEPENDS += "libwnck3"
 
-SRC_URI = "https://github.com/brianhsu/${BPN}/releases/download/${PV}/${BPN}-${PV}.tar.gz"
+SRC_URI = "https://github.com/brianhsu/${BPN}/releases/download/${PV}/${BPN}-${PV}.tar.gz \
+           file://0001-CMakeLists.txt-fix-library-install-path.patch"
 SRC_URI[md5sum] = "ac31b45cda1867cb6bd69bb285638263"
 SRC_URI[sha256sum] = "942684c92f96a158e1417e597947f822769ac56aa1993a8c9f166ee633ef2b8d"
+
+EXTRA_OECMAKE = "-DBASE_LIB_PATH=${baselib}"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/mount/xfce4-mount-plugin_1.1.2.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/mount/xfce4-mount-plugin_1.1.2.bb
deleted file mode 100644
index 6700937..0000000
--- a/meta-openembedded/meta-xfce/recipes-panel-plugins/mount/xfce4-mount-plugin_1.1.2.bb
+++ /dev/null
@@ -1,11 +0,0 @@
-SUMMARY = "Mount/umount utility for the xfce panel"
-HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-mount-plugin"
-SECTION = "x11/application"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
-
-inherit xfce-panel-plugin
-
-SRC_URI += "file://0001-check-for-fstab.h-during-configure.patch"
-SRC_URI[md5sum] = "7eba9696d82433a5577741214d34b588"
-SRC_URI[sha256sum] = "54578447abaf9da630a750d64acdc37d4fd20dda6460208d6d1ffaa9e43ee1a6"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/mount/xfce4-mount-plugin_1.1.3.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/mount/xfce4-mount-plugin_1.1.3.bb
new file mode 100644
index 0000000..4600104
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-panel-plugins/mount/xfce4-mount-plugin_1.1.3.bb
@@ -0,0 +1,11 @@
+SUMMARY = "Mount/umount utility for the xfce panel"
+HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-mount-plugin"
+SECTION = "x11/application"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+
+inherit xfce-panel-plugin
+
+SRC_URI += "file://0001-check-for-fstab.h-during-configure.patch"
+SRC_URI[md5sum] = "2f1f903d0bdf6ee6776afd8af73497ac"
+SRC_URI[sha256sum] = "aae5bd6b984bc78daf6b5fb9d15817a27253674a4264ad60f62ccb1aa194911e"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/pulseaudio/xfce4-pulseaudio-plugin_0.4.0.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/pulseaudio/xfce4-pulseaudio-plugin_0.4.0.bb
deleted file mode 100644
index f5417a1..0000000
--- a/meta-openembedded/meta-xfce/recipes-panel-plugins/pulseaudio/xfce4-pulseaudio-plugin_0.4.0.bb
+++ /dev/null
@@ -1,17 +0,0 @@
-SUMMARY = "Pulseaudio mixer for the xfce panel"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=f5eac6bb0d6ec0dc655e417781d4015f"
-
-inherit xfce-panel-plugin distro_features_check
-
-REQUIRED_DISTRO_FEATURES = "pulseaudio x11"
-
-DEPENDS += "pulseaudio"
-
-SRC_URI[md5sum] = "12f3dd97e02c604e2023b5baf30d4a6c"
-SRC_URI[sha256sum] = "aef9ad68a0b604a6aeca4c08146f3eb42bedb4fe1c8b65b82679cec0e2fc1cb3"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[libnotify] = "--enable-libnotify,--disable-libnotify,libnotify"
-
-RRECOMMENDS_${PN} = "pavucontrol"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/pulseaudio/xfce4-pulseaudio-plugin_0.4.1.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/pulseaudio/xfce4-pulseaudio-plugin_0.4.1.bb
new file mode 100644
index 0000000..b423707
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-panel-plugins/pulseaudio/xfce4-pulseaudio-plugin_0.4.1.bb
@@ -0,0 +1,17 @@
+SUMMARY = "Pulseaudio mixer for the xfce panel"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=f5eac6bb0d6ec0dc655e417781d4015f"
+
+inherit xfce-panel-plugin distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "pulseaudio x11"
+
+DEPENDS += "pulseaudio"
+
+SRC_URI[md5sum] = "7df7280c19c2c8b8c5bc4f4f2136d1dd"
+SRC_URI[sha256sum] = "6ca88314dbac3e24c0e1bfc593fad6edb66319766be62e8256c81b0314f049f0"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[libnotify] = "--enable-libnotify,--disable-libnotify,libnotify"
+
+RRECOMMENDS_${PN} = "pavucontrol"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/weather/xfce4-weather-plugin_0.8.10.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/weather/xfce4-weather-plugin_0.8.10.bb
deleted file mode 100644
index 649eaaa..0000000
--- a/meta-openembedded/meta-xfce/recipes-panel-plugins/weather/xfce4-weather-plugin_0.8.10.bb
+++ /dev/null
@@ -1,13 +0,0 @@
-SUMMARY = "Panel plugin to display current temperature and weather condition"
-HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-weather-plugin"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-
-inherit xfce-panel-plugin
-
-DEPENDS += "libsoup-2.4 dbus-glib upower"
-
-SRC_URI[md5sum] = "bba7f750b97c8fc3656715268edad792"
-SRC_URI[sha256sum] = "ee6d43c444904631c240470e15e96215c2ce451158bfdbf234bce892bf60eab8"
-
-FILES_${PN} += "${datadir}/xfce4/weather"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/weather/xfce4-weather-plugin_0.9.0.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/weather/xfce4-weather-plugin_0.9.0.bb
new file mode 100644
index 0000000..1663bb9
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-panel-plugins/weather/xfce4-weather-plugin_0.9.0.bb
@@ -0,0 +1,13 @@
+SUMMARY = "Panel plugin to display current temperature and weather condition"
+HOMEPAGE = "http://goodies.xfce.org/projects/panel-plugins/xfce4-weather-plugin"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+inherit xfce-panel-plugin
+
+DEPENDS += "libsoup-2.4 dbus-glib upower"
+
+SRC_URI[md5sum] = "25d3d9fb2e688a619201655f6eea51c2"
+SRC_URI[sha256sum] = "34368cf2332774ad2a05226b2914ecb60e7550e9b2164be53ebe8f370198bb3d"
+
+FILES_${PN} += "${datadir}/xfce4/weather"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/whiskermenu/xfce4-whiskermenu-plugin_2.1.6.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/whiskermenu/xfce4-whiskermenu-plugin_2.1.6.bb
deleted file mode 100644
index 762cff0..0000000
--- a/meta-openembedded/meta-xfce/recipes-panel-plugins/whiskermenu/xfce4-whiskermenu-plugin_2.1.6.bb
+++ /dev/null
@@ -1,11 +0,0 @@
-SUMMARY = "An alternate menu for the Xfce desktop environment"
-HOMEPAGE = "http://gottcode.org/xfce4-whiskermenu-plugin/"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-
-inherit xfce-panel-plugin cmake
-
-SRC_URI[md5sum] = "b2b2bacc8d5f3c3119a0f317b6074276"
-SRC_URI[sha256sum] = "8b2a8ee1445df39a2cda139e353f2e9ec3720a780296dc41b7d4aebde57371fc"
-
-RRECOMMENDS_${PN} += "menulibre"
diff --git a/meta-openembedded/meta-xfce/recipes-panel-plugins/whiskermenu/xfce4-whiskermenu-plugin_2.3.0.bb b/meta-openembedded/meta-xfce/recipes-panel-plugins/whiskermenu/xfce4-whiskermenu-plugin_2.3.0.bb
new file mode 100644
index 0000000..24a32fc
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-panel-plugins/whiskermenu/xfce4-whiskermenu-plugin_2.3.0.bb
@@ -0,0 +1,11 @@
+SUMMARY = "An alternate menu for the Xfce desktop environment"
+HOMEPAGE = "http://gottcode.org/xfce4-whiskermenu-plugin/"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+inherit xfce-panel-plugin cmake
+
+SRC_URI[md5sum] = "d2383c3eb1b54adf5a206973bd20f159"
+SRC_URI[sha256sum] = "7e569bb0dff7e3db3d964e23323f54c6de7249741c6a0e33a0fa501d83040b16"
+
+RRECOMMENDS_${PN} += "menulibre"
diff --git a/meta-openembedded/meta-xfce/recipes-thunar-plugins/archive/thunar-archive-plugin_0.3.1.bb b/meta-openembedded/meta-xfce/recipes-thunar-plugins/archive/thunar-archive-plugin_0.3.1.bb
deleted file mode 100644
index 90ab6af..0000000
--- a/meta-openembedded/meta-xfce/recipes-thunar-plugins/archive/thunar-archive-plugin_0.3.1.bb
+++ /dev/null
@@ -1,12 +0,0 @@
-DESCRIPTION = "Thunar Archive Plugin allows you to create and extract archive files using file context menus in Thunar"
-HOMEPAGE = "http://goodies.xfce.org/projects/thunar-plugins/thunar-archive-plugin"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=252890d9eee26aab7b432e8b8a616475"
-
-inherit thunar-plugin
-
-SRC_URI[md5sum] = "425f4faaace6dc7a4716a35b7795463a"
-SRC_URI[sha256sum] = "9ad559b0c11308f6897ad56604e5a06dc8f369f649eb20120b2d3018ef5da54c"
-
-# install tap files in ${libdir}/thunar-archive-plugin
-EXTRA_OECONF += "--libexecdir=${libdir}"
diff --git a/meta-openembedded/meta-xfce/recipes-thunar-plugins/archive/thunar-archive-plugin_0.4.0.bb b/meta-openembedded/meta-xfce/recipes-thunar-plugins/archive/thunar-archive-plugin_0.4.0.bb
new file mode 100644
index 0000000..144e260
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-thunar-plugins/archive/thunar-archive-plugin_0.4.0.bb
@@ -0,0 +1,12 @@
+DESCRIPTION = "Thunar Archive Plugin allows you to create and extract archive files using file context menus in Thunar"
+HOMEPAGE = "http://goodies.xfce.org/projects/thunar-plugins/thunar-archive-plugin"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=252890d9eee26aab7b432e8b8a616475"
+
+inherit thunar-plugin
+
+SRC_URI[md5sum] = "0a7738a3a5f84bf218ece3ffb5241c63"
+SRC_URI[sha256sum] = "bf82fa86a388124eb3c4854249c30712b2922e61789607268ee14548549b3115"
+
+# install tap files in ${libdir}/thunar-archive-plugin
+EXTRA_OECONF += "--libexecdir=${libdir}"
diff --git a/meta-openembedded/meta-xfce/recipes-thunar-plugins/media-tags/thunar-media-tags-plugin_0.2.1.bb b/meta-openembedded/meta-xfce/recipes-thunar-plugins/media-tags/thunar-media-tags-plugin_0.2.1.bb
deleted file mode 100644
index 90f150b..0000000
--- a/meta-openembedded/meta-xfce/recipes-thunar-plugins/media-tags/thunar-media-tags-plugin_0.2.1.bb
+++ /dev/null
@@ -1,11 +0,0 @@
-SUMMARY = "Adds ID3/OGG tag support to the Thunar bulk rename dialog"
-HOMEPAGE = "http://thunar.xfce.org"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
-
-inherit thunar-plugin
-
-DEPENDS += "taglib"
-
-SRC_URI[md5sum] = "0106e900714f86ccbafdc72238d3cf8d"
-SRC_URI[sha256sum] = "056d012a10403ee3e2e55b6ff2faecb796821de9ebee000315589b95d95ed253"
diff --git a/meta-openembedded/meta-xfce/recipes-thunar-plugins/media-tags/thunar-media-tags-plugin_0.3.0.bb b/meta-openembedded/meta-xfce/recipes-thunar-plugins/media-tags/thunar-media-tags-plugin_0.3.0.bb
new file mode 100644
index 0000000..a61e764
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-thunar-plugins/media-tags/thunar-media-tags-plugin_0.3.0.bb
@@ -0,0 +1,11 @@
+SUMMARY = "Adds ID3/OGG tag support to the Thunar bulk rename dialog"
+HOMEPAGE = "http://thunar.xfce.org"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+
+inherit thunar-plugin
+
+DEPENDS += "taglib"
+
+SRC_URI[md5sum] = "5e332113e4b0e548ee7abd87629667f7"
+SRC_URI[sha256sum] = "e265c4415abac40337cc5566c6f706efcf0be4e97723abe22ba8b874c93a591b"
diff --git a/meta-openembedded/meta-xfce/recipes-thunar-plugins/shares/thunar-shares-plugin_0.3.0.bb b/meta-openembedded/meta-xfce/recipes-thunar-plugins/shares/thunar-shares-plugin_0.3.0.bb
new file mode 100644
index 0000000..994c652
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-thunar-plugins/shares/thunar-shares-plugin_0.3.0.bb
@@ -0,0 +1,11 @@
+SUMMARY = "Quickly share a folder using Samba from Thunar"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552"
+
+inherit thunar-plugin distro_features_check
+REQUIRED_DISTRO_FEATURES = "pam"
+
+SRC_URI[md5sum] = "a1773168c0b3c7c0f253a339f02e5ae2"
+SRC_URI[sha256sum] = "d6adc01ca45a3d2567a2a969a3b16d1799a8975453ab1803a065fa82496b5b65"
+
+RDEPENDS_${PN} += "samba-server"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/exo/exo_0.12.0.bb b/meta-openembedded/meta-xfce/recipes-xfce/exo/exo_0.12.0.bb
deleted file mode 100644
index d256b57..0000000
--- a/meta-openembedded/meta-xfce/recipes-xfce/exo/exo_0.12.0.bb
+++ /dev/null
@@ -1,39 +0,0 @@
-DESCRIPTION="Application library for the Xfce desktop environment"
-SECTION = "x11"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-DEPENDS = "gtk+ libxfce4util libxfce4ui virtual/libx11 liburi-perl-native cairo"
-DEPENDS_class-native = "glib-2.0-native xfce4-dev-tools-native intltool-native"
-
-inherit xfce pythonnative perlnative gtk-doc distro_features_check
-
-REQUIRED_DISTRO_FEATURES = "x11"
-REQUIRED_DISTRO_FEATURES_class-native = ""
-
-# SRC_URI must follow inherited one
-SRC_URI += " \
-    file://exo-no-tests-0.8.patch \
-    file://configure.patch \
-"
-
-SRC_URI_append_class-native = " \
-    file://reduce-build-to-exo-csource-only.patch \
-"
-
-SRC_URI[md5sum] = "724afcca224f5fb22b510926d2740e52"
-SRC_URI[sha256sum] = "64b88271a37d0ec7dca062c7bc61ca323116f7855092ac39698c421a2f30a18f"
-
-PACKAGES =+ "exo-csource"
-
-# Note: python bindings did not work in oe-dev and are about to be moved to
-# pyxfce see http://comments.gmane.org/gmane.comp.desktop.xfce.devel.version4/19560
-FILES_${PN} += "${datadir}/xfce4/ \
-                ${libdir}/xfce4/exo-1 \
-"
-
-FILES_${PN}-dbg += "${libdir}/gio/modules/.debug \
-"
-
-FILES_exo-csource += "${bindir}/exo-csource"
-
-BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/exo/exo_0.12.3.bb b/meta-openembedded/meta-xfce/recipes-xfce/exo/exo_0.12.3.bb
new file mode 100644
index 0000000..9c4829b
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-xfce/exo/exo_0.12.3.bb
@@ -0,0 +1,36 @@
+DESCRIPTION="Application library for the Xfce desktop environment"
+SECTION = "x11"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+DEPENDS = "gtk+ libxfce4util libxfce4ui virtual/libx11 liburi-perl-native cairo"
+DEPENDS_class-native = "glib-2.0-native xfce4-dev-tools-native intltool-native"
+
+inherit xfce pythonnative perlnative gtk-doc distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "x11"
+REQUIRED_DISTRO_FEATURES_class-native = ""
+
+# SRC_URI must follow inherited one
+SRC_URI += " \
+    file://exo-no-tests-0.8.patch \
+    file://configure.patch \
+"
+
+SRC_URI_append_class-native = " \
+    file://reduce-build-to-exo-csource-only.patch \
+"
+
+SRC_URI[md5sum] = "da934c5939f2ee4540f5d48991053f01"
+SRC_URI[sha256sum] = "b96fe86bb504aa9b3332b96105d755f5d9052c903fd6574b512a5ef76c0ad439"
+
+PACKAGES =+ "exo-csource"
+
+# Note: python bindings did not work in oe-dev and are about to be moved to
+# pyxfce see http://comments.gmane.org/gmane.comp.desktop.xfce.devel.version4/19560
+FILES_${PN} += "${datadir}/xfce4/ \
+                ${libdir}/xfce4/exo-1 \
+"
+
+FILES_exo-csource += "${bindir}/exo-csource"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/gtk-xfce-engine/gtk-xfce-engine_3.2.0.bb b/meta-openembedded/meta-xfce/recipes-xfce/gtk-xfce-engine/gtk-xfce-engine_3.2.0.bb
index ef4f4bf..805e893 100644
--- a/meta-openembedded/meta-xfce/recipes-xfce/gtk-xfce-engine/gtk-xfce-engine_3.2.0.bb
+++ b/meta-openembedded/meta-xfce/recipes-xfce/gtk-xfce-engine/gtk-xfce-engine_3.2.0.bb
@@ -21,10 +21,10 @@
 FILES_gtk3-xfce-engine += "${libdir}/gtk-3.0/*/theming-engines/*.so"
 FILES_${PN}-themes += "${datadir}/themes"
 
-FILES_${PN}-dbg += "${libdir}/gtk-3.0/*/theming-engines/.debug \
-                    ${libdir}/gtk-2.0/*/engines/.debug"
-FILES_${PN}-dev += "${libdir}/gtk-2.0/*/engines/*.la \
-                    ${libdir}/gtk-3.0/*/theming-engines/*.la"
+FILES_${PN}-dev += " \
+    ${libdir}/gtk-2.0/*/engines/*.la \
+    ${libdir}/gtk-3.0/*/theming-engines/*.la \
+"
 
 RDEPENDS_${PN} += "${PN}-themes"
 RDEPENDS_gtk3-xfce-engine += "${PN}-themes"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/libxfce4ui/libxfce4ui_4.12.1.bb b/meta-openembedded/meta-xfce/recipes-xfce/libxfce4ui/libxfce4ui_4.12.1.bb
deleted file mode 100644
index 4843e0e..0000000
--- a/meta-openembedded/meta-xfce/recipes-xfce/libxfce4ui/libxfce4ui_4.12.1.bb
+++ /dev/null
@@ -1,35 +0,0 @@
-SUMMARY = "Xfce4 Widget library and X Window System interaction"
-SECTION = "x11/libs"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=252890d9eee26aab7b432e8b8a616475"
-DEPENDS = "perl-native glib-2.0 gtk+ gtk+3 intltool-native libxfce4util xfconf xfce4-dev-tools virtual/libx11 libsm libice"
-
-inherit xfce autotools gettext gtk-doc distro_features_check
-
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI += " \
-    file://0001-libxfce4kbd-private-xfce4-keyboard-shortcuts.xml-fix.patch \
-"
-SRC_URI[md5sum] = "ea9fad7d059fe8f531fe8db42dabb5a9"
-SRC_URI[sha256sum] = "3d619811bfbe7478bb984c16543d980cadd08586365a7bc25e59e3ca6384ff43"
-
-EXTRA_OECONF += "--with-vendor-info=${DISTRO}"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[gladeui] = "--enable-gladeui,--disable-gladeui,glade3"
-PACKAGECONFIG[startup-notification] = "--enable-startup-notification,--disable-startup-notification,startup-notification"
-
-PACKAGES =+ "${PN}-gtk2 ${PN}-gtk3"
-FILES_${PN}-gtk2 += "${libdir}/libxfce4ui-1.so.* ${libdir}/libxfce4kbd-private-2.so.*"
-FILES_${PN}-gtk3 += "${libdir}/libxfce4ui-2.so.* ${libdir}/libxfce4kbd-private-3.so.*"
-
-FILES_${PN}-dbg += "${libdir}/glade3/modules/.debug"
-FILES_${PN}-dev += "${libdir}/glade3/modules/*.la \
-                   ${datadir}/glade3/catalogs/*.in"
-PACKAGES += "${PN}-glade"
-FILES_${PN}-glade = "${libdir}/glade3 \
-                     ${datadir}/glade3"
-
-RDEPENDS_${PN}-gtk2 = "${PN}"
-RDEPENDS_${PN}-gtk3 = "${PN}"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/libxfce4ui/libxfce4ui_4.13.4.bb b/meta-openembedded/meta-xfce/recipes-xfce/libxfce4ui/libxfce4ui_4.13.4.bb
new file mode 100644
index 0000000..8a385ba
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-xfce/libxfce4ui/libxfce4ui_4.13.4.bb
@@ -0,0 +1,32 @@
+SUMMARY = "Xfce4 Widget library and X Window System interaction"
+SECTION = "x11/libs"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=252890d9eee26aab7b432e8b8a616475"
+DEPENDS = "perl-native glib-2.0 gtk+ gtk+3 intltool-native libxfce4util xfconf xfce4-dev-tools virtual/libx11 libsm libice"
+
+inherit xfce autotools gettext gtk-doc gobject-introspection distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI += " \
+    file://0001-libxfce4kbd-private-xfce4-keyboard-shortcuts.xml-fix.patch \
+"
+SRC_URI[md5sum] = "b407cdab73ebd5c33c90db6bdb3ec5ff"
+SRC_URI[sha256sum] = "d63fcdb8e5acb6f0d26075ea17d320dbfbec2058567cd67cb99824c7402a1f79"
+
+EXTRA_OECONF += "--with-vendor-info=${DISTRO}"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[gladeui] = "--enable-gladeui,--disable-gladeui,glade3"
+PACKAGECONFIG[startup-notification] = "--enable-startup-notification,--disable-startup-notification,startup-notification"
+
+PACKAGES =+ "${PN}-gtk2 ${PN}-gtk3"
+FILES_${PN}-gtk2 += "${libdir}/libxfce4ui-1.so.* ${libdir}/libxfce4kbd-private-2.so.*"
+FILES_${PN}-gtk3 += "${libdir}/libxfce4ui-2.so.* ${libdir}/libxfce4kbd-private-3.so.*"
+
+PACKAGES += "${PN}-glade"
+FILES_${PN}-glade = "${libdir}/glade3 \
+                     ${datadir}/glade3"
+
+RDEPENDS_${PN}-gtk2 = "${PN}"
+RDEPENDS_${PN}-gtk3 = "${PN}"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/libxfce4util/libxfce4util_4.12.1.bb b/meta-openembedded/meta-xfce/recipes-xfce/libxfce4util/libxfce4util_4.12.1.bb
deleted file mode 100644
index d985a00..0000000
--- a/meta-openembedded/meta-xfce/recipes-xfce/libxfce4util/libxfce4util_4.12.1.bb
+++ /dev/null
@@ -1,10 +0,0 @@
-SUMMARY = "Basic utility library for Xfce4"
-SECTION = "x11/libs"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=252890d9eee26aab7b432e8b8a616475"
-DEPENDS = "intltool-native xfce4-dev-tools-native glib-2.0"
-
-inherit xfce gtk-doc
-
-SRC_URI[md5sum] = "4eb012b6c1292ceedb3a83ebfc1ff08d"
-SRC_URI[sha256sum] = "876bdefa2e13cbf68b626b2158892fb93e824e1ef59cf951123a96cefbc8881d"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/libxfce4util/libxfce4util_4.13.2.bb b/meta-openembedded/meta-xfce/recipes-xfce/libxfce4util/libxfce4util_4.13.2.bb
new file mode 100644
index 0000000..21cc1db
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-xfce/libxfce4util/libxfce4util_4.13.2.bb
@@ -0,0 +1,10 @@
+SUMMARY = "Basic utility library for Xfce4"
+SECTION = "x11/libs"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=252890d9eee26aab7b432e8b8a616475"
+DEPENDS = "intltool-native xfce4-dev-tools-native glib-2.0"
+
+inherit xfce gtk-doc gobject-introspection
+
+SRC_URI[md5sum] = "e3e8b9dd7e12028d3e642345b85d6ef1"
+SRC_URI[sha256sum] = "c58275ff650080369e742695862c811cb78402c85f243ea0b5aec186027be361"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/packagegroups/packagegroup-xfce-extended.bb b/meta-openembedded/meta-xfce/recipes-xfce/packagegroups/packagegroup-xfce-extended.bb
index b73c9ee..5f8c03c 100644
--- a/meta-openembedded/meta-xfce/recipes-xfce/packagegroups/packagegroup-xfce-extended.bb
+++ b/meta-openembedded/meta-xfce/recipes-xfce/packagegroups/packagegroup-xfce-extended.bb
@@ -56,6 +56,7 @@
     xfce4-verve-plugin \
     \
     xfce-polkit \
+    ${@bb.utils.contains("DISTRO_FEATURES", "bluetooth", "blueman", "", d)} \
     \
     thunar-media-tags-plugin \
     thunar-archive-plugin \
@@ -67,4 +68,7 @@
     ristretto \
     xfce4-taskmanager \
     gigolo \
+    mousepad \
+    catfish \
+    xfce4-panel-profiles \
 "
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/thunar-volman/thunar-volman/0001-Fix-return-with-no-value-in-function-returning-non-v.patch b/meta-openembedded/meta-xfce/recipes-xfce/thunar-volman/thunar-volman/0001-Fix-return-with-no-value-in-function-returning-non-v.patch
deleted file mode 100644
index 7233ea7..0000000
--- a/meta-openembedded/meta-xfce/recipes-xfce/thunar-volman/thunar-volman/0001-Fix-return-with-no-value-in-function-returning-non-v.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-From 2e295e9ce8f7f60a271adf004588b0d8db88db09 Mon Sep 17 00:00:00 2001
-From: Matt Thirtytwo <matt.59491@gmail.com>
-Date: Sat, 7 Mar 2015 22:50:32 +0100
-Subject: [PATCH] Fix return with no value in function returning non-void (bug
- #11656)
-
----
- thunar-volman/tvm-block-device.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/thunar-volman/tvm-block-device.c b/thunar-volman/tvm-block-device.c
-index da31efa..edb6cad 100644
---- a/thunar-volman/tvm-block-device.c
-+++ b/thunar-volman/tvm-block-device.c
-@@ -714,7 +714,7 @@ tvm_block_device_mount (TvmContext *context)
-   GMountOperation *mount_operation;
-   GVolume         *volume;
- 
--  g_return_if_fail (context != NULL);
-+  g_return_val_if_fail ((context != NULL), FALSE);
- 
-   /* determine the GVolume corresponding to the udev device */
-   volume = 
--- 
-1.9.0
-
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/thunar-volman/thunar-volman_0.8.1.bb b/meta-openembedded/meta-xfce/recipes-xfce/thunar-volman/thunar-volman_0.8.1.bb
deleted file mode 100644
index c61d451..0000000
--- a/meta-openembedded/meta-xfce/recipes-xfce/thunar-volman/thunar-volman_0.8.1.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-SUMMARY = "Automatic management of removable drives and media for thunar"
-SECTION = "x11"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
-DEPENDS = "exo glib-2.0 gtk+ libxfce4ui libxfce4util xfconf libnotify libgudev"
-
-inherit xfce distro_features_check
-
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI += "file://0001-Fix-return-with-no-value-in-function-returning-non-v.patch"
-SRC_URI[md5sum] = "65ab6e05b2e808d1dcc8d36683a59b7e"
-SRC_URI[sha256sum] = "5a08bb5ce32c296a64dfbdb2406d4e45a208b2c91e4efa831dc28f1d6c2ac2bd"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[notify] = "--enable-notifications,--disable-notifications,libnotify"
-
-RDEPENDS_${PN} = "eject"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/thunar-volman/thunar-volman_0.9.0.bb b/meta-openembedded/meta-xfce/recipes-xfce/thunar-volman/thunar-volman_0.9.0.bb
new file mode 100644
index 0000000..5a37b69
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-xfce/thunar-volman/thunar-volman_0.9.0.bb
@@ -0,0 +1,17 @@
+SUMMARY = "Automatic management of removable drives and media for thunar"
+SECTION = "x11"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+DEPENDS = "exo glib-2.0 libxfce4ui libxfce4util xfconf libnotify libgudev"
+
+inherit xfce distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI[md5sum] = "3b403a4f846927391ea4bee765a055df"
+SRC_URI[sha256sum] = "e4bffcfee15530e277fa80865eb1de31e63c7effaf8835c9fa7c71e5a0076b2e"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[notify] = "--enable-notifications,--disable-notifications,libnotify"
+
+RDEPENDS_${PN} = "eject"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/thunar/thunar_1.6.15.bb b/meta-openembedded/meta-xfce/recipes-xfce/thunar/thunar_1.6.15.bb
deleted file mode 100644
index 170e250..0000000
--- a/meta-openembedded/meta-xfce/recipes-xfce/thunar/thunar_1.6.15.bb
+++ /dev/null
@@ -1,35 +0,0 @@
-SUMMARY = "File manager for the Xfce Desktop Environment"
-SECTION = "x11"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
-DEPENDS = "exo glib-2.0 gtk+ gdk-pixbuf libxfce4util libxfce4ui xfconf libsm dbus-glib startup-notification libnotify xfce4-panel udev"
-
-inherit xfce distro_features_check
-
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI = "http://archive.xfce.org/src/xfce/${BPN}/${@'${PV}'[0:3]}/Thunar-${PV}.tar.bz2"
-SRC_URI[md5sum] = "8fea2af69c3acbb273fd1a177d3d8e47"
-SRC_URI[sha256sum] = "e81291a8519f495e0a059ff1f2d29608bc6d37c0be83b1f38f3c9aa25f8d252d"
-
-S = "${WORKDIR}/Thunar-${PV}/"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[pcre] = "--enable-pcre,--disable-pcre,libpcre"
-
-FILES_${PN} += " \
-    ${libdir}/thunarx-2/* \
-    ${libdir}/xfce4/panel/plugins/* \
-    ${libdir}/Thunar/[Tt]hunar* \
-    ${datadir}/appdata \
-    ${datadir}/dbus-1 \
-    ${datadir}/polkit-1 \
-    ${datadir}/Thunar \
-    ${datadir}/xfce4/panel/plugins/* \
-"
-
-FILES_${PN}-dbg += "${libdir}/thunarx-2/.debug/ \
-                    ${libdir}/xfce4/panel/plugins/.debug/ \
-                    ${libdir}/Thunar/.debug/"
-
-RRECOMMENDS_${PN} = "gvfs gvfsd-trash"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/thunar/thunar_1.8.2.bb b/meta-openembedded/meta-xfce/recipes-xfce/thunar/thunar_1.8.2.bb
new file mode 100644
index 0000000..d2a0e30
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-xfce/thunar/thunar_1.8.2.bb
@@ -0,0 +1,32 @@
+SUMMARY = "File manager for the Xfce Desktop Environment"
+SECTION = "x11"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+DEPENDS = "exo glib-2.0 gtk+3 gdk-pixbuf libxfce4util libxfce4ui xfconf libsm dbus-glib startup-notification libnotify xfce4-panel udev"
+
+inherit xfce gobject-introspection distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI = "http://archive.xfce.org/src/xfce/${BPN}/${@'${PV}'[0:3]}/Thunar-${PV}.tar.bz2"
+SRC_URI[md5sum] = "51a0988625a7e2c944377e75d3effc71"
+SRC_URI[sha256sum] = "75f91045541eb5983e772a564d97f23e5995256bfb9863e0f4a015393421d428"
+
+S = "${WORKDIR}/Thunar-${PV}/"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[pcre] = "--enable-pcre,--disable-pcre,libpcre"
+
+FILES_${PN} += " \
+    ${libdir}/thunarx-3/* \
+    ${libdir}/xfce4/panel/plugins/* \
+    ${libdir}/Thunar/[Tt]hunar* \
+    ${systemd_user_unitdir} \
+    ${datadir}/dbus-1 \
+    ${datadir}/metainfo \
+    ${datadir}/polkit-1 \
+    ${datadir}/Thunar \
+    ${datadir}/xfce4/panel/plugins/* \
+"
+
+RRECOMMENDS_${PN} = "gvfs gvfsd-trash"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/tumbler/tumbler_0.2.0.bb b/meta-openembedded/meta-xfce/recipes-xfce/tumbler/tumbler_0.2.0.bb
index 7e0c555..9d26694 100644
--- a/meta-openembedded/meta-xfce/recipes-xfce/tumbler/tumbler_0.2.0.bb
+++ b/meta-openembedded/meta-xfce/recipes-xfce/tumbler/tumbler_0.2.0.bb
@@ -28,8 +28,5 @@
 "
 
 FILES_${PN}-dev += "${libdir}/tumbler-1/plugins/*.la \
-                    ${libdir}/tumbler-1/plugins/cache/*.la"
-FILES_${PN}-dbg += "${libdir}/tumbler-1/.debug \
-                    ${libdir}/tumbler-1/plugins/.debug \
-                    ${libdir}/tumbler-1/plugins/cache/.debug \
+                    ${libdir}/tumbler-1/plugins/cache/*.la \
 "
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-appfinder/xfce4-appfinder_4.13.0.bb b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-appfinder/xfce4-appfinder_4.13.0.bb
deleted file mode 100644
index 7e73911..0000000
--- a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-appfinder/xfce4-appfinder_4.13.0.bb
+++ /dev/null
@@ -1,14 +0,0 @@
-DESCRIPTION="Xfce4 Application Finder"
-SECTION = "x11"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
-DEPENDS="glib-2.0 gtk+3 libxfce4util libxfce4ui garcon dbus-glib xfconf"
-
-inherit xfce distro_features_check
-
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI[md5sum] = "6b6cf080c891f7945953f8084a901552"
-SRC_URI[sha256sum] = "c0eb3b29eba3cfa9175ed35174e83a21faa2a2423ddb79501fe8846cc430e3ae"
-
-FILES_${PN} += "${datadir}/appdata"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-appfinder/xfce4-appfinder_4.13.1.bb b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-appfinder/xfce4-appfinder_4.13.1.bb
new file mode 100644
index 0000000..0336f54
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-appfinder/xfce4-appfinder_4.13.1.bb
@@ -0,0 +1,14 @@
+DESCRIPTION="Xfce4 Application Finder"
+SECTION = "x11"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+DEPENDS="glib-2.0 gtk+3 libxfce4util libxfce4ui garcon dbus-glib xfconf"
+
+inherit xfce distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI[md5sum] = "9e2a1f9b4ae3183c461b79891224c33f"
+SRC_URI[sha256sum] = "5cabb27bbe0a0864b785e1a38535a91516763e38d6bff41a3915a61d28254b03"
+
+FILES_${PN} += "${datadir}/appdata"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-panel/files/0001-clock-time-make-change-of-system-s-timezone-change-t.patch b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-panel/files/0001-clock-time-make-change-of-system-s-timezone-change-t.patch
deleted file mode 100644
index 9dca3ba..0000000
--- a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-panel/files/0001-clock-time-make-change-of-system-s-timezone-change-t.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From c582338ef4f33b3dc07a2636340d55b9fb530650 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@googlemail.com>
-Date: Wed, 17 Feb 2016 00:15:44 +0100
-Subject: [PATCH] clock-time: make change of system's timezone change time for
- DEFAULT_TIMEZONE
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-clock_time->timezone is set in clock_time_init so the condition
-
-'clock_time->timezone != NULL
-
-is matching always.
-
-Tested by selecting seconds displayed (-> quick update) and changing timezone.
-
-Upstream-Status: Submitted [1]
-
-[1] https://bugzilla.xfce.org/show_bug.cgi?id=12453
-
-Signed-off-by: Andreas Müller <schnitzeltony@googlemail.com>
----
- plugins/clock/clock-time.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/plugins/clock/clock-time.c b/plugins/clock/clock-time.c
-index b015b13..4459b85 100644
---- a/plugins/clock/clock-time.c
-+++ b/plugins/clock/clock-time.c
-@@ -198,7 +198,7 @@ clock_time_get_time (ClockTime *clock_time)
- 
-   panel_return_val_if_fail (XFCE_IS_CLOCK_TIME (clock_time), NULL);
- 
--  if (clock_time->timezone != NULL)
-+  if (g_strcmp0 (clock_time->timezone_name, DEFAULT_TIMEZONE) != 0)
-     date_time = g_date_time_new_now (clock_time->timezone);
-   else
-     date_time = g_date_time_new_now_local ();
--- 
-2.5.0
-
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-panel/files/0001-windowmenu-do-not-display-desktop-icon-when-no-windo.patch b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-panel/files/0001-windowmenu-do-not-display-desktop-icon-when-no-windo.patch
new file mode 100644
index 0000000..1adb145
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-panel/files/0001-windowmenu-do-not-display-desktop-icon-when-no-windo.patch
@@ -0,0 +1,60 @@
+From 0651f228cef01a6c3e4758a991cace1cd7721031 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@googlemail.com>
+Date: Mon, 24 Sep 2012 09:57:46 +0200
+Subject: [PATCH] windowmenu: do not display desktop icon when no window is
+ active
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+* desktop icon is of no use
+* desktop icon confuses when using showdesktop plugin
+
+Upstream-Status: Pending
+
+Signed-off-by: Andreas Müller <schnitzeltony@googlemail.com>
+---
+ plugins/windowmenu/windowmenu.c | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/plugins/windowmenu/windowmenu.c b/plugins/windowmenu/windowmenu.c
+index f47e993e..061d6544 100644
+--- a/plugins/windowmenu/windowmenu.c
++++ b/plugins/windowmenu/windowmenu.c
+@@ -251,7 +251,7 @@ window_menu_plugin_init (WindowMenuPlugin *plugin)
+   g_signal_connect (G_OBJECT (plugin->button), "toggled",
+       G_CALLBACK (window_menu_plugin_menu), plugin);
+ 
+-  plugin->icon = gtk_image_new_from_icon_name ("user-desktop", GTK_ICON_SIZE_BUTTON);
++  plugin->icon = gtk_image_new_from_icon_name (NULL, GTK_ICON_SIZE_BUTTON);
+   gtk_container_add (GTK_CONTAINER (plugin->button), plugin->icon);
+   gtk_widget_show (plugin->icon);
+ }
+@@ -640,7 +640,7 @@ window_menu_plugin_active_window_changed (WnckScreen       *screen,
+           /* skip 'fake' windows */
+           type = wnck_window_get_window_type (window);
+           if (type == WNCK_WINDOW_DESKTOP || type == WNCK_WINDOW_DOCK)
+-            goto show_desktop_icon;
++            goto show_no_icon;
+ 
+           /* get the window icon and set the tooltip */
+           gtk_widget_set_tooltip_text (GTK_WIDGET (icon),
+@@ -660,12 +660,12 @@ window_menu_plugin_active_window_changed (WnckScreen       *screen,
+         }
+       else
+         {
+-          show_desktop_icon:
++          show_no_icon:
+ 
+           /* desktop is shown right now */
+-          gtk_image_set_from_icon_name (GTK_IMAGE (icon), "user-desktop", icon_size);
++          gtk_image_set_from_icon_name (GTK_IMAGE (icon), NULL, icon_size);
+           gtk_image_set_pixel_size (GTK_IMAGE (icon), icon_size);
+-          gtk_widget_set_tooltip_text (GTK_WIDGET (icon), _("Desktop"));
++          gtk_widget_set_tooltip_text (GTK_WIDGET (icon), _("No Windows"));
+         }
+     }
+ }
+-- 
+2.14.3
+
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-panel/files/0002-windowmenu-do-not-display-desktop-icon-when-no-windo.patch b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-panel/files/0002-windowmenu-do-not-display-desktop-icon-when-no-windo.patch
deleted file mode 100644
index b2d960c..0000000
--- a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-panel/files/0002-windowmenu-do-not-display-desktop-icon-when-no-windo.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-From 0651f228cef01a6c3e4758a991cace1cd7721031 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@googlemail.com>
-Date: Mon, 24 Sep 2012 09:57:46 +0200
-Subject: [PATCH] windowmenu: do not display desktop icon when no window is
- active
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-* desktop icon is of no use
-* desktop icon confuses when using showdesktop plugin
-
-Upstream-Status: Pending
-
-Signed-off-by: Andreas Müller <schnitzeltony@googlemail.com>
----
- plugins/windowmenu/windowmenu.c |   12 ++++++------
- 1 files changed, 6 insertions(+), 6 deletions(-)
-
-diff --git a/plugins/windowmenu/windowmenu.c b/plugins/windowmenu/windowmenu.c
-index c96123a..9404021 100644
---- a/plugins/windowmenu/windowmenu.c
-+++ b/plugins/windowmenu/windowmenu.c
-@@ -256,7 +256,7 @@ window_menu_plugin_init (WindowMenuPlugin *plugin)
-   g_signal_connect (G_OBJECT (plugin->button), "toggled",
-       G_CALLBACK (window_menu_plugin_menu), plugin);
- 
--  plugin->icon = xfce_panel_image_new_from_source ("user-desktop");
-+  plugin->icon = xfce_panel_image_new_from_source (NULL);
-   gtk_container_add (GTK_CONTAINER (plugin->button), plugin->icon);
-   gtk_widget_show (plugin->icon);
- }
-@@ -634,7 +634,7 @@ window_menu_plugin_active_window_changed (WnckScreen       *screen,
-           /* skip 'fake' windows */
-           type = wnck_window_get_window_type (window);
-           if (type == WNCK_WINDOW_DESKTOP || type == WNCK_WINDOW_DOCK)
--            goto show_desktop_icon;
-+            goto show_no_icon;
- 
-           /* get the window icon and set the tooltip */
-           gtk_widget_set_tooltip_text (GTK_WIDGET (icon),
-@@ -648,11 +648,11 @@ window_menu_plugin_active_window_changed (WnckScreen       *screen,
-         }
-       else
-         {
--          show_desktop_icon:
-+          show_no_icon:
- 
--          /* desktop is shown right now */
--          xfce_panel_image_set_from_source (icon, "user-desktop");
--          gtk_widget_set_tooltip_text (GTK_WIDGET (icon), _("Desktop"));
-+          /* no icon is shown right now */
-+          xfce_panel_image_set_from_source (icon, NULL);
-+          gtk_widget_set_tooltip_text (GTK_WIDGET (icon), _("No Windows"));
-         }
-     }
- }
--- 
-1.7.6.5
-
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-panel/xfce4-panel_4.12.2.bb b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-panel/xfce4-panel_4.12.2.bb
deleted file mode 100644
index 9cc9a4b..0000000
--- a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-panel/xfce4-panel_4.12.2.bb
+++ /dev/null
@@ -1,44 +0,0 @@
-SUMMARY = "Xfce4 Panel"
-SECTION = "x11"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=26a8bd75d8f8498bdbbe64a27791d4ee"
-DEPENDS = "libxfce4util garcon libxfce4ui xfconf exo gtk+ gtk+3 dbus cairo virtual/libx11 libxml2 libwnck"
-
-inherit xfce gtk-doc distro_features_check gtk-icon-cache
-
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI[md5sum] = "803c9aabc2925dc97f96de125c52ba2e"
-SRC_URI[sha256sum] = "42058abb81b8f87691d3999627447de71c3285bcf055f308aab5cefab2de0ce9"
-SRC_URI += " \
-    file://0001-clock-time-make-change-of-system-s-timezone-change-t.patch \
-    file://0002-windowmenu-do-not-display-desktop-icon-when-no-windo.patch \
-"
-
-EXTRA_OECONF += "--enable-gtk3"
-
-python populate_packages_prepend() {
-    plugin_dir = d.expand('${libdir}/xfce4/panel/plugins/')
-    plugin_name = d.expand('${PN}-plugin-%s')
-    do_split_packages(d, plugin_dir, '^lib(.*).so$', plugin_name,
-                      '${PN} plugin for %s', extra_depends='', prepend=True,
-                      aux_files_pattern=['${datadir}/xfce4/panel/plugins/%s.desktop',
-                                         '${sysconfdir}/xdg/xfce/panel/%s-*',
-                                         '${datadir}/icons/hicolor/48x48/apps/*-%s.png',
-                                         '${bindir}/*%s*'])
-}
-
-PACKAGES_DYNAMIC += "^${PN}-plugin-.*"
-
-PACKAGES =+ "${PN}-gtk3"
-
-FILES_${PN} += "${libdir}/xfce4/panel/migrate \
-                ${libdir}/xfce4/panel/wrapper-1.0"
-
-FILES_${PN}-gtk3 = " \
-    ${libdir}/libxfce4panel-2.0${SOLIBS} \
-    ${libdir}/xfce4/panel/wrapper-2.0 \
-"
-FILES_${PN}-dbg += " \
-    ${libdir}/xfce4/panel/plugins/.debug \
-"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-panel/xfce4-panel_4.13.3.bb b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-panel/xfce4-panel_4.13.3.bb
new file mode 100644
index 0000000..f1abf66
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-panel/xfce4-panel_4.13.3.bb
@@ -0,0 +1,40 @@
+SUMMARY = "Xfce4 Panel"
+SECTION = "x11"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=26a8bd75d8f8498bdbbe64a27791d4ee"
+DEPENDS = "libxfce4util garcon libxfce4ui xfconf exo gtk+ gtk+3 dbus cairo virtual/libx11 libxml2 libwnck3 vala-native"
+
+inherit xfce gtk-doc gobject-introspection distro_features_check gtk-icon-cache remove-libtool
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI[md5sum] = "0ccb448e3792949eb0ae9db8dc22789b"
+SRC_URI[sha256sum] = "b467feb7ee9797ad12f56a152570e42a96b94ad63580d45536aabee282440ce8"
+SRC_URI += " \
+    file://0001-windowmenu-do-not-display-desktop-icon-when-no-windo.patch \
+"
+
+python populate_packages_prepend() {
+    plugin_dir = d.expand('${libdir}/xfce4/panel/plugins/')
+    plugin_name = d.expand('${PN}-plugin-%s')
+    do_split_packages(d, plugin_dir, '^lib(.*).so$', plugin_name,
+                      '${PN} plugin for %s', extra_depends='', prepend=True,
+                      aux_files_pattern=['${datadir}/xfce4/panel/plugins/%s.desktop',
+                                         '${sysconfdir}/xdg/xfce/panel/%s-*',
+                                         '${datadir}/icons/hicolor/48x48/apps/*-%s.png',
+                                         '${bindir}/*%s*'])
+}
+
+PACKAGES_DYNAMIC += "^${PN}-plugin-.*"
+
+PACKAGES =+ "${PN}-gtk3"
+
+FILES_${PN} += "${libdir}/xfce4/panel/migrate \
+                ${libdir}/xfce4/panel/wrapper-1.0"
+
+FILES_${PN}-dev += "${libdir}/xfce4/panel/plugins/*.la"
+
+FILES_${PN}-gtk3 = " \
+    ${libdir}/libxfce4panel-2.0${SOLIBS} \
+    ${libdir}/xfce4/panel/wrapper-2.0 \
+"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-session/xfce4-session_4.12.1.bb b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-session/xfce4-session_4.12.1.bb
deleted file mode 100644
index a247206..0000000
--- a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-session/xfce4-session_4.12.1.bb
+++ /dev/null
@@ -1,32 +0,0 @@
-SUMMARY = "xfce4-session is a session manager for Xfce 4 Desktop Environment"
-SECTION = "x11"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=9ac2e7cff1ddaf48b6eab6028f23ef88"
-DEPENDS = "virtual/libx11 libsm libxfce4util libxfce4ui gtk+ libwnck dbus dbus-glib xfconf polkit"
-RDEPENDS_${PN} = "netbase xinit dbus-x11 iceauth upower"
-
-inherit xfce update-alternatives distro_features_check
-
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI[md5sum] = "f4921fb2e606e74643daf1212263076c"
-SRC_URI[sha256sum] = "97d7f2a2d0af7f3623b68d1f04091e02913b28f9555dab8b0d26c8a1299d08fd"
-SRC_URI += " \
-    file://0001-configure.in-hard-code-path-to-iceauth.patch \
-"
-
-ALTERNATIVE_${PN} = "x-session-manager"
-ALTERNATIVE_TARGET[x-session-manager] = "${bindir}/xfce4-session"
-ALTERNATIVE_PRIORITY_${PN} = "100"
-
-FILES_${PN} += " \
-    ${libdir}/xfce4/*/*/*.so \
-    ${libdir}/xfce4/session/*-*-* \
-    ${datadir}/xsessions \
-    ${datadir}/themes/Default/balou/* \
-    ${datadir}/polkit-1 \
-"
-
-FILES_${PN}-dbg += "${libdir}/xfce4/*/*/.debug"
-
-RDEPENDS_${PN} += "machine-host"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-session/xfce4-session_4.13.1.bb b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-session/xfce4-session_4.13.1.bb
new file mode 100644
index 0000000..b11aaa4
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-session/xfce4-session_4.13.1.bb
@@ -0,0 +1,34 @@
+SUMMARY = "xfce4-session is a session manager for Xfce 4 Desktop Environment"
+SECTION = "x11"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=9ac2e7cff1ddaf48b6eab6028f23ef88"
+DEPENDS = "virtual/libx11 libsm libxfce4util libxfce4ui gtk+ libwnck3 dbus dbus-glib xfconf polkit"
+RDEPENDS_${PN} = "netbase xinit dbus-x11 iceauth upower"
+
+inherit xfce update-alternatives distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI += " \
+    file://0001-configure.in-hard-code-path-to-iceauth.patch \
+"
+SRC_URI[md5sum] = "a47988a2c871a411c19e3af1eefe591e"
+SRC_URI[sha256sum] = "c789f0f8234e06f5266f0c6ccdbdcc3c085e8d9eea06a0eafe8f7cfc4fe23af4"
+
+ALTERNATIVE_${PN} = "x-session-manager"
+ALTERNATIVE_TARGET[x-session-manager] = "${bindir}/xfce4-session"
+ALTERNATIVE_PRIORITY_${PN} = "100"
+
+FILES_${PN} += " \
+    ${libdir}/xfce4/*/*/*.so \
+    ${libdir}/xfce4/session/*-*-* \
+    ${datadir}/xsessions \
+    ${datadir}/themes/Default/balou/* \
+    ${datadir}/polkit-1 \
+"
+
+FILES_${PN} += " \
+    ${libdir}/xfce4/session/splash-engines/*.la \
+"
+
+RDEPENDS_${PN} += "machine-host"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-settings/files/0002-Fix-linking-to-dbus-glib-bug-13633.patch b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-settings/files/0002-Fix-linking-to-dbus-glib-bug-13633.patch
new file mode 100644
index 0000000..109b7b1
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-settings/files/0002-Fix-linking-to-dbus-glib-bug-13633.patch
@@ -0,0 +1,41 @@
+From b6e46e6a84e45f7bd954687be703987825a54c1e Mon Sep 17 00:00:00 2001
+From: Eric Koegel <eric.koegel@gmail.com>
+Date: Sun, 11 Jun 2017 11:38:26 +0300
+Subject: [PATCH] Fix linking to dbus-glib (bug #13633)
+
+With xfconf moving to GDBus nothing provides the libs for dbus-glib
+that xfce4-settings requires. This patch adds the libs back in until
+settings can be ported to GDBus.
+
+Signed-off-by: Sean Davis <smd.seandavis@gmail.com>
+
+Upstream-Status: Backport
+---
+ xfce4-settings-editor/Makefile.am | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/xfce4-settings-editor/Makefile.am b/xfce4-settings-editor/Makefile.am
+index 5964366..c2c7c4b 100644
+--- a/xfce4-settings-editor/Makefile.am
++++ b/xfce4-settings-editor/Makefile.am
+@@ -28,6 +28,7 @@ xfce4_settings_editor_CFLAGS = \
+ 	$(LIBXFCE4UTIL_CFLAGS) \
+ 	$(LIBXFCE4UI_CFLAGS) \
+ 	$(XFCONF_CFLAGS) \
++	$(DBUS_GLIB_CFLAGS) \
+ 	$(PLATFORM_CFLAGS)
+ 
+ xfce4_settings_editor_LDFLAGS = \
+@@ -39,7 +40,8 @@ xfce4_settings_editor_LDADD = \
+ 	$(DBUS_GLIB_LIBS) \
+ 	$(LIBXFCE4UTIL_LIBS) \
+ 	$(LIBXFCE4UI_LIBS) \
+-	$(XFCONF_LIBS)
++	$(XFCONF_LIBS) \
++	$(DBUS_GLIB_LIBS)
+ 
+ desktopdir = $(datadir)/applications
+ desktop_in_files = xfce4-settings-editor.desktop.in
+-- 
+2.14.3
+
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-settings/xfce4-settings_git.bb b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-settings/xfce4-settings_git.bb
index bf9bd31..a4685ae 100644
--- a/meta-openembedded/meta-xfce/recipes-xfce/xfce4-settings/xfce4-settings_git.bb
+++ b/meta-openembedded/meta-xfce/recipes-xfce/xfce4-settings/xfce4-settings_git.bb
@@ -13,12 +13,13 @@
 # + minor bugfixes - sent mainline but no response
 # + option to hide mousepointer for a specific (touch) input device - sent mainline but no response
 SRC_URI = " \
-    git://github.com/schnitzeltony/xfce4-settings.git;protocol=git;branch=for-oe-4.12.3 \
+    git://github.com/schnitzeltony/xfce4-settings.git;protocol=git;branch=for-oe-4.12.4 \
     file://0001-xsettings.xml-Set-default-themes.patch \
+    file://0002-Fix-linking-to-dbus-glib-bug-13633.patch \
 "
-SRCREV = "b701ac8b66b83c17469dd5009da51eeb59eba442"
+SRCREV = "75d7c9b15e5ccce12b0864d3659ae9b6de96e245"
 S = "${WORKDIR}/git"
-PV = "4.12.3+git${SRCPV}"
+PV = "4.12.4+git${SRCPV}"
 
 EXTRA_OECONF += "--enable-maintainer-mode --disable-debug"
 
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfconf/xfconf_4.12.1.bb b/meta-openembedded/meta-xfce/recipes-xfce/xfconf/xfconf_4.12.1.bb
deleted file mode 100644
index a42426f..0000000
--- a/meta-openembedded/meta-xfce/recipes-xfce/xfconf/xfconf_4.12.1.bb
+++ /dev/null
@@ -1,15 +0,0 @@
-SUMMARY = "Xfce configuration daemon and utilities"
-SECTION = "x11/wm"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552"
-DEPENDS = "dbus-glib libxfce4util perl intltool-native xfce4-dev-tools-native"
-
-inherit xfce gtk-doc
-
-EXTRA_OECONF += "PERL=${STAGING_DIR_TARGET}/usr/bin/perl"
-
-SRC_URI[md5sum] = "20dc8d2bfd80ba136bf4964021b32757"
-SRC_URI[sha256sum] = "35f48564e5694faa54fdc180cd3268e16fc2352946a89a3c2fc12cbe400ada36"
-
-FILES_${PN} += "${libdir}/xfce4/xfconf/xfconfd \
-                ${datadir}/dbus-1/services/org.xfce.Xfconf.service"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfconf/xfconf_4.13.6.bb b/meta-openembedded/meta-xfce/recipes-xfce/xfconf/xfconf_4.13.6.bb
new file mode 100644
index 0000000..2667ff9
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-xfce/xfconf/xfconf_4.13.6.bb
@@ -0,0 +1,18 @@
+SUMMARY = "Xfce configuration daemon and utilities"
+SECTION = "x11/wm"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552"
+DEPENDS = "dbus-glib libxfce4util perl intltool-native xfce4-dev-tools-native"
+
+inherit xfce gtk-doc
+
+EXTRA_OECONF += "PERL=${STAGING_DIR_TARGET}/usr/bin/perl"
+
+SRC_URI[md5sum] = "da19df12dbc494c8a4da3974e376d639"
+SRC_URI[sha256sum] = "d1a3d442dae188b5a7380b5815377e5488578cdafb03ae363e9426e3b01185df"
+
+FILES_${PN} += "${libdir}/xfce4/xfconf/xfconfd \
+                ${libdir}/gio/modules/libxfconfgsettingsbackend.so \
+                ${datadir}/dbus-1/services/org.xfce.Xfconf.service"
+
+FILES_${PN}-dev += "${libdir}/gio/modules/libxfconfgsettingsbackend.la"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfdesktop/xfdesktop_4.12.4.bb b/meta-openembedded/meta-xfce/recipes-xfce/xfdesktop/xfdesktop_4.12.4.bb
deleted file mode 100644
index d9cbe71..0000000
--- a/meta-openembedded/meta-xfce/recipes-xfce/xfdesktop/xfdesktop_4.12.4.bb
+++ /dev/null
@@ -1,17 +0,0 @@
-SUMMARY = "Xfce4 Desktop Manager"
-SECTION = "x11/base"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
-DEPENDS = "glib-2.0 gtk+ libxfce4util libxfce4ui libwnck xfconf dbus-glib dbus-glib-native thunar garcon exo"
-
-inherit xfce distro_features_check
-
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI[md5sum] = "7571889368be72df185ce2d470f37198"
-SRC_URI[sha256sum] = "098a35510562907e1431d5adbfa8307484a235c1dec6a43e2d58d2ac4241f1cb"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[notify] = "--enable-notifications,--disable-notifications,libnotify"
-
-FILES_${PN} += "${datadir}/backgrounds"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfdesktop/xfdesktop_4.13.2.bb b/meta-openembedded/meta-xfce/recipes-xfce/xfdesktop/xfdesktop_4.13.2.bb
new file mode 100644
index 0000000..85696a1
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-xfce/xfdesktop/xfdesktop_4.13.2.bb
@@ -0,0 +1,17 @@
+SUMMARY = "Xfce4 Desktop Manager"
+SECTION = "x11/base"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+DEPENDS = "libxfce4util libxfce4ui libwnck xfconf dbus-glib dbus-glib-native thunar garcon exo"
+
+inherit xfce distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI[md5sum] = "c05569c1c39ccd314fb5da20d5086909"
+SRC_URI[sha256sum] = "387f43d8a4615f44060c019cad212ac12df62c58eea2605813743116f71ad3bd"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[notify] = "--enable-notifications,--disable-notifications,libnotify"
+
+FILES_${PN} += "${datadir}/backgrounds"
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfwm4/xfwm4_4.12.4.bb b/meta-openembedded/meta-xfce/recipes-xfce/xfwm4/xfwm4_4.12.4.bb
deleted file mode 100644
index 2aa68e3..0000000
--- a/meta-openembedded/meta-xfce/recipes-xfce/xfwm4/xfwm4_4.12.4.bb
+++ /dev/null
@@ -1,30 +0,0 @@
-DESCRIPTION="Xfce4 Window Manager"
-SECTION = "x11/wm"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d791728a073bc009b4ffaf00b7599855"
-DEPENDS = "virtual/libx11 libxpm gtk+ libxfce4util libxfce4ui xfconf libwnck dbus-glib startup-notification exo-native"
-
-inherit xfce update-alternatives distro_features_check
-
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI[md5sum] = "3ec136efc5387fd3b53cd66b684f52d7"
-SRC_URI[sha256sum] = "fa74048a75649a6e92df763a3cfb706d3fed1e1a6adf567f6693325a5a6efb36"
-
-python populate_packages_prepend () {
-    themedir = d.expand('${datadir}/themes')
-    do_split_packages(d, themedir, '^(.*)', 'xfwm4-theme-%s', 'XFWM4 theme %s', allow_dirs=True)
-}
-
-PACKAGES_DYNAMIC += "^xfwm4-theme-.*"
-
-ALTERNATIVE_${PN} = "x-window-manager"
-ALTERNATIVE_TARGET[x-window-manager] = "${bindir}/xfwm4"
-ALTERNATIVE_PRIORITY[x-window-manager] = "30"
-
-RDEPENDS_${PN} = "xfwm4-theme-default"
-FILES_${PN} += "${libdir}/xfce4/xfwm4/helper-dialog \
-                ${datadir}/xfwm4/defaults \
-"
-FILES_${PN}-dbg += "${libexecdir}/xfce4/xfwm4/.debug/*"
-
diff --git a/meta-openembedded/meta-xfce/recipes-xfce/xfwm4/xfwm4_4.13.1.bb b/meta-openembedded/meta-xfce/recipes-xfce/xfwm4/xfwm4_4.13.1.bb
new file mode 100644
index 0000000..64ad9f6
--- /dev/null
+++ b/meta-openembedded/meta-xfce/recipes-xfce/xfwm4/xfwm4_4.13.1.bb
@@ -0,0 +1,38 @@
+DESCRIPTION="Xfce4 Window Manager"
+SECTION = "x11/wm"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d791728a073bc009b4ffaf00b7599855"
+DEPENDS = "virtual/libx11 libxfce4util libxfce4ui xfconf libwnck3 dbus-glib libxinerama exo-native"
+
+inherit xfce update-alternatives distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI[md5sum] = "1a78bcc2100c03f6fea0dbce0ca813cf"
+SRC_URI[sha256sum] = "75ebc20d313cff4905e76fc320254c30461dbfa985461b8e75dca04770cedf12"
+
+PACKAGECONFIG ?= " \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'epoxy', '', d)} \
+    xpresent \
+    startup-notification \
+"
+
+PACKAGECONFIG[epoxy] = "--enable-epoxy,--disable-epoxy,libepoxy"
+PACKAGECONFIG[xpresent] = "--enable-xpresent,--disable-xpresent,libxpresent"
+PACKAGECONFIG[startup-notification] = "--enable-startup-notification,--disable-startup-notification,startup-notification"
+
+python populate_packages_prepend () {
+    themedir = d.expand('${datadir}/themes')
+    do_split_packages(d, themedir, '^(.*)', 'xfwm4-theme-%s', 'XFWM4 theme %s', allow_dirs=True)
+}
+
+PACKAGES_DYNAMIC += "^xfwm4-theme-.*"
+
+ALTERNATIVE_${PN} = "x-window-manager"
+ALTERNATIVE_TARGET[x-window-manager] = "${bindir}/xfwm4"
+ALTERNATIVE_PRIORITY[x-window-manager] = "30"
+
+RDEPENDS_${PN} = "xfwm4-theme-default"
+FILES_${PN} += "${libdir}/xfce4/xfwm4/helper-dialog \
+                ${datadir}/xfwm4/defaults \
+"
diff --git a/meta-openpower/conf/layer.conf b/meta-openpower/conf/layer.conf
index bb727b5..fafc941 100644
--- a/meta-openpower/conf/layer.conf
+++ b/meta-openpower/conf/layer.conf
@@ -8,7 +8,7 @@
 BBFILE_COLLECTIONS += "openpower-layer"
 BBFILE_PATTERN_openpower-layer = "^${LAYERDIR}/"
 LAYERVERSION_openpower-layer = "1"
-LAYERSERIES_COMPAT_openpower-layer = "sumo"
+LAYERSERIES_COMPAT_openpower-layer = "thud"
 
 # Provide a variable that points the base of the openpower layer.
 OPENPOWERBASE = '${@os.path.normpath("${LAYERDIR}/")}'
diff --git a/meta-phosphor/classes/image_types_phosphor.bbclass b/meta-phosphor/classes/image_types_phosphor.bbclass
index 2437390..1edf3a3 100644
--- a/meta-phosphor/classes/image_types_phosphor.bbclass
+++ b/meta-phosphor/classes/image_types_phosphor.bbclass
@@ -9,7 +9,7 @@
 # The reference BMC software update implementation.
 
 # Image composition
-FLASH_KERNEL_IMAGE ?= "fitImage-${INITRAMFS_IMAGE}-${MACHINE}.bin"
+FLASH_KERNEL_IMAGE ?= "fitImage-${INITRAMFS_IMAGE}-${MACHINE}-${MACHINE}"
 FLASH_KERNEL_IMAGE_df-obmc-ubi-fs ?= "fitImage-${MACHINE}.bin"
 
 IMAGE_BASETYPE ?= "squashfs-xz"
diff --git a/meta-phosphor/conf/layer.conf b/meta-phosphor/conf/layer.conf
index 3f2cf39..c4a3f43 100644
--- a/meta-phosphor/conf/layer.conf
+++ b/meta-phosphor/conf/layer.conf
@@ -8,7 +8,7 @@
 BBFILE_COLLECTIONS += "phosphor-layer"
 BBFILE_PATTERN_phosphor-layer = "^${LAYERDIR}/"
 LAYERVERSION_phosphor-layer = "1"
-LAYERSERIES_COMPAT_phosphor-layer = "sumo"
+LAYERSERIES_COMPAT_phosphor-layer = "thud"
 
 # Provide a variable that points the base of the phosphor layer.
 PHOSPHORBASE = '${@os.path.normpath("${LAYERDIR}/")}'
diff --git a/meta-phosphor/recipes-connectivity/openssl/openssl_%.bbappend b/meta-phosphor/recipes-connectivity/openssl/openssl_%.bbappend
index e248be6..51e64ad 100644
--- a/meta-phosphor/recipes-connectivity/openssl/openssl_%.bbappend
+++ b/meta-phosphor/recipes-connectivity/openssl/openssl_%.bbappend
@@ -1,12 +1,12 @@
 # General config settings.
-EXTRA_OECONF_append_class-target = " shared no-hw no-err no-psk no-srp no-engines "
+EXTRA_OECONF_append_class-target = " shared no-hw no-err no-psk no-srp "
 
 # Disable SSL (keep TLS only).
 EXTRA_OECONF_append_class-target = " no-ssl2 no-ssl3 "
 
 # Disable various algorithms.
 EXTRA_OECONF_append_class-target = " no-idea no-md2 no-mdc2 no-rc5 no-md4 \
-        no-ripemd160 no-rmd160 no-whirlpool no-sha0 no-camellia \
+        no-rmd160 no-whirlpool no-camellia \
         no-rc2 no-rc4 no-bf no-cast no-seed no-gost "
 
 do_configure_append() {
diff --git a/meta-phosphor/recipes-core/busybox/busybox/0001-Stop-watchdog-first-on-startup.patch b/meta-phosphor/recipes-core/busybox/busybox/0001-Stop-watchdog-first-on-startup.patch
deleted file mode 100644
index 7128b81..0000000
--- a/meta-phosphor/recipes-core/busybox/busybox/0001-Stop-watchdog-first-on-startup.patch
+++ /dev/null
@@ -1,63 +0,0 @@
-From a4c493ae42926ab36fdc805a5da9f0682bb98b45 Mon Sep 17 00:00:00 2001
-From: Matt Spinler <spinler@us.ibm.com>
-Date: Tue, 13 Jun 2017 15:26:49 -0500
-Subject: [PATCH] Stop watchdog first on startup
-
-Some watchdog implementations may do things other than issue
-a reboot on a watchdog timeout.  In this case, there's the
-possibility of restarting this program from the state of
-the watchdog device not being properly stopped (done by writing
-a 'V' and closing the device).  Since it wasn't stopped, the
-driver may not be able to restart the watchdog when this program
-reopens it and starts pinging it.
-
-To fix this, the code will always first issue the stop when it
-starts up.
-
-Signed-off-by: Matt Spinler <spinler@us.ibm.com>
----
- miscutils/watchdog.c | 21 +++++++++++++++++++--
- 1 file changed, 19 insertions(+), 2 deletions(-)
-
-diff --git a/miscutils/watchdog.c b/miscutils/watchdog.c
-index 07ae64e52..223e3c32d 100644
---- a/miscutils/watchdog.c
-+++ b/miscutils/watchdog.c
-@@ -53,6 +53,24 @@ static void watchdog_shutdown(int sig UNUSED_PARAM)
- 	_exit(EXIT_SUCCESS);
- }
- 
-+static void watchdog_open(const char* device)
-+{
-+	static const char magic_value = 'V';
-+
-+	/* If the watchdog driver can do something other than cause a reboot
-+	 * on a timeout, then it's possible this program may be starting from
-+	 * a state when the watchdog hadn't been previously stopped with
-+	 * the magic write followed by a close.  In this case the driver may
-+	 * not start properly, so always do the proper stop first just in case.
-+	 */
-+
-+	/* Use known fd # - avoid needing global 'int fd' */
-+	xmove_fd(xopen(device, O_WRONLY), 3);
-+	write(3, &magic_value, 1);
-+	close(3);
-+	xmove_fd(xopen(device, O_WRONLY), 3);
-+}
-+
- int watchdog_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
- int watchdog_main(int argc, char **argv)
- {
-@@ -88,8 +106,7 @@ int watchdog_main(int argc, char **argv)
- 
- 	bb_signals(BB_FATAL_SIGS, watchdog_shutdown);
- 
--	/* Use known fd # - avoid needing global 'int fd' */
--	xmove_fd(xopen(argv[argc - 1], O_WRONLY), 3);
-+	watchdog_open(argv[argc - 1]);
- 
- 	/* WDIOC_SETTIMEOUT takes seconds, not milliseconds */
- 	htimer_duration = htimer_duration / 1000;
--- 
-2.11.0
-
diff --git a/meta-phosphor/recipes-core/busybox/busybox_%.bbappend b/meta-phosphor/recipes-core/busybox/busybox_%.bbappend
index cc88bcc..8907b08 100644
--- a/meta-phosphor/recipes-core/busybox/busybox_%.bbappend
+++ b/meta-phosphor/recipes-core/busybox/busybox_%.bbappend
@@ -2,5 +2,4 @@
 SRC_URI += "file://busybox.cfg"
 SRC_URI += "file://flash.cfg"
 SRC_URI += "file://mountpoint.cfg"
-SRC_URI += "file://0001-Stop-watchdog-first-on-startup.patch"
 SRC_URI += "${@bb.utils.contains('DISTRO_FEATURES', 'obmc-ubi-fs', '', 'file://reboot.cfg', d)}"
diff --git a/meta-phosphor/recipes-core/dropbear/dropbear/0001-Only-load-dropbear-default-host-keys-if-a-key-is-not.patch b/meta-phosphor/recipes-core/dropbear/dropbear/0001-Only-load-dropbear-default-host-keys-if-a-key-is-not.patch
deleted file mode 100644
index e32baec..0000000
--- a/meta-phosphor/recipes-core/dropbear/dropbear/0001-Only-load-dropbear-default-host-keys-if-a-key-is-not.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From 95eff1ca0beea55259c2cdc7f1bb9f930bf57bc8 Mon Sep 17 00:00:00 2001
-From: CamVan Nguyen <ctnguyen@us.ibm.com>
-Date: Tue, 13 Feb 2018 15:37:47 -0600
-Subject: [PATCH 1/1] Only load dropbear default host keys if a key is not
- specified
-
----
- svr-runopts.c | 10 +++++++---
- 1 file changed, 7 insertions(+), 3 deletions(-)
-
-diff --git a/svr-runopts.c b/svr-runopts.c
-index 8f60059..c5c2148 100644
---- a/svr-runopts.c
-+++ b/svr-runopts.c
-@@ -488,17 +488,21 @@ void load_all_hostkeys() {
- 		m_free(hostkey_file);
- 	}
- 
-+	/* Only load default host keys if a host key is not specified by the
-+	 * user */
-+	if (0 ==  svr_opts.num_hostkey_files) {
- #ifdef DROPBEAR_RSA
--	loadhostkey(RSA_PRIV_FILENAME, 0);
-+		loadhostkey(RSA_PRIV_FILENAME, 0);
- #endif
- 
- #ifdef DROPBEAR_DSS
--	loadhostkey(DSS_PRIV_FILENAME, 0);
-+		loadhostkey(DSS_PRIV_FILENAME, 0);
- #endif
- 
- #ifdef DROPBEAR_ECDSA
--	loadhostkey(ECDSA_PRIV_FILENAME, 0);
-+		loadhostkey(ECDSA_PRIV_FILENAME, 0);
- #endif
-+	}
- 
- #ifdef DROPBEAR_DELAY_HOSTKEY
- 	if (svr_opts.delay_hostkey) {
--- 
-1.8.2.2
-
diff --git a/meta-phosphor/recipes-core/dropbear/dropbear/0001-dropbear-Add-c-command-option-to-force-a-specific-co.patch b/meta-phosphor/recipes-core/dropbear/dropbear/0001-dropbear-Add-c-command-option-to-force-a-specific-co.patch
deleted file mode 100644
index 88d0ac0..0000000
--- a/meta-phosphor/recipes-core/dropbear/dropbear/0001-dropbear-Add-c-command-option-to-force-a-specific-co.patch
+++ /dev/null
@@ -1,91 +0,0 @@
-From b4e094381ec846f4387dc6a3c210c2205a8db58a Mon Sep 17 00:00:00 2001
-From: Jeremy Kerr <jk@ozlabs.org>
-Date: Tue, 12 Apr 2016 11:11:40 +0800
-Subject: [PATCH] dropbear: Add -c <command> option to force a specific command
-
-This change adds a -c option to dropbear, to force the session to use a
-specific command, in a similar fashion to OpenSSH's ForceCommand
-configuration option.
-
-This is useful to provide a simple fixed service over ssh, without
-requiring an authorized key file for the per-key forced_command option.
-
-This setting takes precedence over the channel session's provided
-command, and the per-key forced_command setting.
-
-Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
----
- runopts.h         |  2 ++
- svr-chansession.c | 12 ++++++++++--
- svr-runopts.c     |  5 +++++
- 3 files changed, 17 insertions(+), 2 deletions(-)
-
-diff --git a/runopts.h b/runopts.h
-index f7c869d..ffb573e 100644
---- a/runopts.h
-+++ b/runopts.h
-@@ -114,6 +114,8 @@ typedef struct svr_runopts {
- 	buffer * banner;
- 	char * pidfile;
- 
-+	char * command;
-+
- } svr_runopts;
- 
- extern svr_runopts svr_opts;
-diff --git a/svr-chansession.c b/svr-chansession.c
-index bfaf7f6..d6c9330 100644
---- a/svr-chansession.c
-+++ b/svr-chansession.c
-@@ -671,8 +671,16 @@ static int sessioncommand(struct Channel *channel, struct ChanSess *chansess,
- 		}
- 	}
- 	
--	/* take public key option 'command' into account */
--	svr_pubkey_set_forced_command(chansess);
-+
-+	/* take global command into account */
-+	if (svr_opts.command) {
-+		chansess->original_command = chansess->cmd ? : m_strdup("");
-+		chansess->cmd = m_strdup(svr_opts.command);
-+	} else {
-+		/* take public key option 'command' into account */
-+		svr_pubkey_set_forced_command(chansess);
-+	}
-+
- 
- #ifdef LOG_COMMANDS
- 	if (chansess->cmd) {
-diff --git a/svr-runopts.c b/svr-runopts.c
-index 8f60059..f845300 100644
---- a/svr-runopts.c
-+++ b/svr-runopts.c
-@@ -79,6 +79,7 @@ static void printhelp(const char * progname) {
- #ifdef ENABLE_SVR_REMOTETCPFWD
- 					"-k		Disable remote port forwarding\n"
- 					"-a		Allow connections to forwarded ports from any host\n"
-+					"-c command	Force executed command\n"
- #endif
- 					"-p [address:]port\n"
- 					"		Listen on specified tcp port (and optionally address),\n"
-@@ -125,6 +126,7 @@ void svr_getopts(int argc, char ** argv) {
- 	/* see printhelp() for options */
- 	svr_opts.bannerfile = NULL;
- 	svr_opts.banner = NULL;
-+	svr_opts.command = NULL;
- 	svr_opts.forkbg = 1;
- 	svr_opts.norootlogin = 0;
- 	svr_opts.noauthpass = 0;
-@@ -177,6 +179,9 @@ void svr_getopts(int argc, char ** argv) {
- 				case 'b':
- 					next = &svr_opts.bannerfile;
- 					break;
-+				case 'c':
-+					next = &svr_opts.command;
-+					break;
- 				case 'd':
- 				case 'r':
- 					next = &keyfile;
--- 
-2.5.0
-
diff --git a/meta-phosphor/recipes-core/dropbear/dropbear/localoptions.h b/meta-phosphor/recipes-core/dropbear/dropbear/localoptions.h
new file mode 100644
index 0000000..8aec3b3
--- /dev/null
+++ b/meta-phosphor/recipes-core/dropbear/dropbear/localoptions.h
@@ -0,0 +1,6 @@
+// Disable CBC ciphers for modern security.
+#define DROPBEAR_ENABLE_CBC_MODE 0
+
+#define DROPBEAR_SHA1_96_HMAC 0
+#define DROPBEAR_SHA2_256_HMAC 1
+#define DROPBEAR_SHA2_512_HMAC 1
diff --git a/meta-phosphor/recipes-core/dropbear/dropbear_%.bbappend b/meta-phosphor/recipes-core/dropbear/dropbear_%.bbappend
index 8071497..cab454a 100644
--- a/meta-phosphor/recipes-core/dropbear/dropbear_%.bbappend
+++ b/meta-phosphor/recipes-core/dropbear/dropbear_%.bbappend
@@ -3,5 +3,4 @@
 # to yocto 2.5 or later which will pull in the latest dropbear code.
 FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
 SRC_URI += "file://dropbearkey.service \
-	    file://0001-dropbear-Add-c-command-option-to-force-a-specific-co.patch \
-	    file://0001-Only-load-dropbear-default-host-keys-if-a-key-is-not.patch"
+            file://localoptions.h"
diff --git a/meta-phosphor/recipes-core/dropbear/dropbear_2017.75.bbappend b/meta-phosphor/recipes-core/dropbear/dropbear_2017.75.bbappend
deleted file mode 100644
index 0bcdf6f..0000000
--- a/meta-phosphor/recipes-core/dropbear/dropbear_2017.75.bbappend
+++ /dev/null
@@ -1,4 +0,0 @@
-# TODO: Dropbear 2018.76 controls options in a different way.  See
-# https://github.com/openbmc/openbmc/issues/3186
-FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
-SRC_URI += "file://options.patch"
diff --git a/meta-phosphor/recipes-core/systemd/systemd/0006-core-fix-the-check-if-CONFIG_CGROUP_BPF-is-on.patch b/meta-phosphor/recipes-core/systemd/systemd/0006-core-fix-the-check-if-CONFIG_CGROUP_BPF-is-on.patch
index fc3f9e1..3645100 100644
--- a/meta-phosphor/recipes-core/systemd/systemd/0006-core-fix-the-check-if-CONFIG_CGROUP_BPF-is-on.patch
+++ b/meta-phosphor/recipes-core/systemd/systemd/0006-core-fix-the-check-if-CONFIG_CGROUP_BPF-is-on.patch
@@ -1,6 +1,6 @@
-From 501fa6c60d303f0d6e747939172281d77247626e Mon Sep 17 00:00:00 2001
-From: Alexander Filippov <a.filippov@yadro.com>
-Date: Mon, 17 Sep 2018 13:33:06 +0300
+From 4ea79c18f1e2081d59eaa0f1df479dbc7700779e Mon Sep 17 00:00:00 2001
+From: Ed Tanous <ed.tanous@intel.com>
+Date: Sun, 16 Dec 2018 18:27:06 -0800
 Subject: [PATCH] core: fix the check if CONFIG_CGROUP_BPF is on
 
 Since the commit torvalds/linux@fdb5c4531c1e0e50e609df83f736b6f3a02896e2
@@ -14,16 +14,19 @@
 Resolves openbmc/linux#159
 See also systemd/systemd#7054
 
-Signed-off-by: Alexander Filippov <a.filippov@yadro.com>
+Originally written by:
+Alexander Filippov <a.filippov@yadro.com>
+
+Signed-off-by: Ed Tanous <ed.tanous@intel.com>
 ---
- src/core/bpf-firewall.c | 10 +++++-----
- 1 file changed, 5 insertions(+), 5 deletions(-)
+ src/core/bpf-firewall.c | 14 +++++++-------
+ 1 file changed, 7 insertions(+), 7 deletions(-)
 
 diff --git a/src/core/bpf-firewall.c b/src/core/bpf-firewall.c
-index f3f40fb0e8..51dc5b9506 100644
+index 8b66ef73d..e68b70d0c 100644
 --- a/src/core/bpf-firewall.c
 +++ b/src/core/bpf-firewall.c
-@@ -658,7 +658,7 @@ int bpf_firewall_supported(void) {
+@@ -660,7 +660,7 @@ int bpf_firewall_supported(void) {
           * b) whether the unified hierarchy is being used
           * c) the BPF implementation in the kernel supports BPF LPM TRIE maps, which we require
           * d) the BPF implementation in the kernel supports BPF_PROG_TYPE_CGROUP_SKB programs, which we require
@@ -32,7 +35,7 @@
           *
           */
  
-@@ -711,7 +711,7 @@ int bpf_firewall_supported(void) {
+@@ -714,7 +714,7 @@ int bpf_firewall_supported(void) {
           * is turned off at kernel compilation time. This sucks of course: why does it allow us to create a cgroup BPF
           * program if we can't do a thing with it later?
           *
@@ -41,24 +44,43 @@
           * CONFIG_CGROUP_BPF is turned off, then the call will fail early with EINVAL. If it is turned on the
           * parameters are validated however, and that'll fail with EBADF then. */
  
-@@ -721,14 +721,14 @@ int bpf_firewall_supported(void) {
+@@ -724,15 +724,15 @@ int bpf_firewall_supported(void) {
                  .attach_bpf_fd = -1,
          };
  
--        r = bpf(BPF_PROG_ATTACH, &attr, sizeof(attr));
-+        r = bpf(BPF_PROG_DETACH, &attr, sizeof(attr));
-         if (r < 0) {
-                 if (errno == EBADF) /* YAY! */
-                         return supported = true;
+-        if (bpf(BPF_PROG_ATTACH, &attr, sizeof(attr)) < 0) {
++        if (bpf(BPF_PROG_DETACH, &attr, sizeof(attr)) < 0) {
+                 if (errno != EBADF) {
+-                        log_debug_errno(errno, "Didn't get EBADF from BPF_PROG_ATTACH, BPF firewalling is not supported: %m");
++                        log_debug_errno(errno, "Didn't get EBADF from BPF_PROG_DETACH, BPF firewalling is not supported: %m");
+                         return supported = BPF_FIREWALL_UNSUPPORTED;
+                 }
  
--                log_debug_errno(errno, "Didn't get EBADF from BPF_PROG_ATTACH, BPF firewalling is not supported: %m");
-+                log_debug_errno(errno, "Didn't get EBADF from BPF_PROG_DETACH, BPF firewalling is not supported: %m");
-         } else
--                log_debug("Wut? kernel accepted our invalid BPF_PROG_ATTACH call? Something is weird, assuming BPF firewalling is broken and hence not supported.");
-+                log_debug("Wut? kernel accepted our invalid BPF_PROG_DETACH call? Something is weird, assuming BPF firewalling is broken and hence not supported.");
+                 /* YAY! */
+         } else {
+-                log_debug("Wut? Kernel accepted our invalid BPF_PROG_ATTACH call? Something is weird, assuming BPF firewalling is broken and hence not supported.");
++                log_debug("Wut? Kernel accepted our invalid BPF_PROG_DETACH call? Something is weird, assuming BPF firewalling is broken and hence not supported.");
+                 return supported = BPF_FIREWALL_UNSUPPORTED;
+         }
  
-         return supported = false;
+@@ -748,7 +748,7 @@ int bpf_firewall_supported(void) {
+                 .attach_flags = BPF_F_ALLOW_MULTI,
+         };
+ 
+-        if (bpf(BPF_PROG_ATTACH, &attr, sizeof(attr)) < 0) {
++        if (bpf(BPF_PROG_DETACH, &attr, sizeof(attr)) < 0) {
+                 if (errno == EBADF) {
+                         log_debug_errno(errno, "Got EBADF when using BPF_F_ALLOW_MULTI, which indicates it is supported. Yay!");
+                         return supported = BPF_FIREWALL_SUPPORTED_WITH_MULTI;
+@@ -761,7 +761,7 @@ int bpf_firewall_supported(void) {
+ 
+                 return supported = BPF_FIREWALL_SUPPORTED;
+         } else {
+-                log_debug("Wut? Kernel accepted our invalid BPF_PROG_ATTACH+BPF_F_ALLOW_MULTI call? Something is weird, assuming BPF firewalling is broken and hence not supported.");
++                log_debug("Wut? Kernel accepted our invalid BPF_PROG_DETACH+BPF_F_ALLOW_MULTI call? Something is weird, assuming BPF firewalling is broken and hence not supported.");
+                 return supported = BPF_FIREWALL_UNSUPPORTED;
+         }
  }
 -- 
-2.14.4
+2.17.1
 
diff --git a/meta-phosphor/recipes-support/libgpg-error/libgpg-error/0001-syscfg-Add-ppc64le-cross-build-support.patch b/meta-phosphor/recipes-support/libgpg-error/libgpg-error/0001-syscfg-Add-ppc64le-cross-build-support.patch
deleted file mode 100644
index e171b31..0000000
--- a/meta-phosphor/recipes-support/libgpg-error/libgpg-error/0001-syscfg-Add-ppc64le-cross-build-support.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-From 7f8ca0ae0b89f4f4442bf4f7f05677f255121dd6 Mon Sep 17 00:00:00 2001
-From: Brad Bishop <bradleyb@fuzziesquirrel.com>
-Date: Wed, 14 Mar 2018 16:03:38 -0400
-Subject: [PATCH] syscfg: Add ppc64le cross build support.
-
-* src/syscfg/lock-obj-pub.ppc64le-unknown-linux-gnu.h: New.
-* src/Makefile.am (lock_obj_pub): Add.
---
-
-Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
----
- src/Makefile.am                                    |  1 +
- .../lock-obj-pub.ppc64le-unknown-linux-gnu.h       | 25 ++++++++++++++++++++++
- 2 files changed, 26 insertions(+)
- create mode 100644 src/syscfg/lock-obj-pub.ppc64le-unknown-linux-gnu.h
-
-diff --git a/src/Makefile.am b/src/Makefile.am
-index 268c2ab..e3ed6c1 100644
---- a/src/Makefile.am
-+++ b/src/Makefile.am
-@@ -64,6 +64,7 @@ lock_obj_pub = \
-         syscfg/lock-obj-pub.powerpc-unknown-linux-gnu.h     \
-         syscfg/lock-obj-pub.powerpc64-unknown-linux-gnu.h   \
- 	syscfg/lock-obj-pub.powerpc64le-unknown-linux-gnu.h \
-+	syscfg/lock-obj-pub.ppc64le-unknown-linux-gnu.h     \
- 	syscfg/lock-obj-pub.powerpc-unknown-linux-gnuspe.h  \
- 	syscfg/lock-obj-pub.riscv64-unknown-linux-gnu.h     \
-         syscfg/lock-obj-pub.s390x-ibm-linux-gnu.h           \
-diff --git a/src/syscfg/lock-obj-pub.ppc64le-unknown-linux-gnu.h b/src/syscfg/lock-obj-pub.ppc64le-unknown-linux-gnu.h
-new file mode 100644
-index 0000000..b9407d4
---- /dev/null
-+++ b/src/syscfg/lock-obj-pub.ppc64le-unknown-linux-gnu.h
-@@ -0,0 +1,25 @@
-+## lock-obj-pub.ppc64le-unknown-linux-gnu.h
-+## File created by gen-posix-lock-obj - DO NOT EDIT
-+## To be included by mkheader into gpg-error.h
-+
-+typedef struct
-+{
-+  long _vers;
-+  union {
-+    volatile char _priv[40];
-+    long _x_align;
-+    long *_xp_align;
-+  } u;
-+} gpgrt_lock_t;
-+
-+#define GPGRT_LOCK_INITIALIZER {1,{{0,0,0,0,0,0,0,0, \
-+                                    0,0,0,0,0,0,0,0, \
-+                                    0,0,0,0,0,0,0,0, \
-+                                    0,0,0,0,0,0,0,0, \
-+                                    0,0,0,0,0,0,0,0}}}
-+##
-+## Local Variables:
-+## mode: c
-+## buffer-read-only: t
-+## End:
-+##
--- 
-2.5.0
-
diff --git a/meta-phosphor/recipes-support/libgpg-error/libgpg-error_%.bbappend b/meta-phosphor/recipes-support/libgpg-error/libgpg-error_%.bbappend
deleted file mode 100644
index 16137de..0000000
--- a/meta-phosphor/recipes-support/libgpg-error/libgpg-error_%.bbappend
+++ /dev/null
@@ -1,3 +0,0 @@
-FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
-
-SRC_URI += "file://0001-syscfg-Add-ppc64le-cross-build-support.patch"
diff --git a/meta-raspberrypi/classes/sdcard_image-rpi.bbclass b/meta-raspberrypi/classes/sdcard_image-rpi.bbclass
index e7c34c6..6244ee5 100644
--- a/meta-raspberrypi/classes/sdcard_image-rpi.bbclass
+++ b/meta-raspberrypi/classes/sdcard_image-rpi.bbclass
@@ -28,9 +28,6 @@
 # Set kernel and boot loader
 IMAGE_BOOTLOADER ?= "bcm2835-bootfiles"
 
-# Set initramfs extension
-KERNEL_INITRAMFS ?= ""
-
 # Kernel image name
 SDIMG_KERNELIMAGE_raspberrypi  ?= "kernel.img"
 SDIMG_KERNELIMAGE_raspberrypi2 ?= "kernel7.img"
@@ -49,6 +46,9 @@
 SDIMG_ROOTFS_TYPE ?= "ext3"
 SDIMG_ROOTFS = "${IMGDEPLOYDIR}/${IMAGE_LINK_NAME}.${SDIMG_ROOTFS_TYPE}"
 
+# For the names of kernel artifacts
+inherit kernel-artifact-names
+
 do_image_rpi_sdimg[depends] = " \
     parted-native:do_populate_sysroot \
     mtools-native:do_populate_sysroot \
@@ -75,6 +75,7 @@
 FATPAYLOAD ?= ""
 
 # SD card vfat partition image name
+SDIMG_VFAT_DEPLOY ?= "${RPI_USE_U_BOOT}"
 SDIMG_VFAT = "${IMAGE_NAME}.vfat"
 SDIMG_LINK_VFAT = "${IMGDEPLOYDIR}/${IMAGE_LINK_NAME}.vfat"
 
@@ -135,10 +136,18 @@
     fi
     if [ "${RPI_USE_U_BOOT}" = "1" ]; then
         mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/u-boot.bin ::${SDIMG_KERNELIMAGE}
-        mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}${KERNEL_INITRAMFS}-${MACHINE}.bin ::${KERNEL_IMAGETYPE}
         mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/boot.scr ::boot.scr
+        if [ ! -z "${INITRAMFS_IMAGE}" -a "${INITRAMFS_IMAGE_BUNDLE}" = "1" ]; then
+            mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}-${INITRAMFS_LINK_NAME}.bin ::${KERNEL_IMAGETYPE}
+        else
+            mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE} ::${KERNEL_IMAGETYPE}
+        fi
     else
-        mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}${KERNEL_INITRAMFS}-${MACHINE}.bin ::${SDIMG_KERNELIMAGE}
+        if [ ! -z "${INITRAMFS_IMAGE}" -a "${INITRAMFS_IMAGE_BUNDLE}" = "1" ]; then
+            mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}-${INITRAMFS_LINK_NAME}.bin ::${SDIMG_KERNELIMAGE}
+        else
+            mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE} ::${SDIMG_KERNELIMAGE}
+        fi
     fi
 
     if [ -n ${FATPAYLOAD} ] ; then
@@ -153,8 +162,8 @@
     echo "${IMAGE_NAME}" > ${WORKDIR}/image-version-info
     mcopy -i ${WORKDIR}/boot.img -v ${WORKDIR}/image-version-info ::
 
-    # Deploy vfat partition (for u-boot case only)
-    if [ "${RPI_USE_U_BOOT}" = "1" ]; then
+    # Deploy vfat partition
+    if [ "${SDIMG_VFAT_DEPLOY}" = "1" ]; then
         cp ${WORKDIR}/boot.img ${IMGDEPLOYDIR}/${SDIMG_VFAT}
         ln -sf ${SDIMG_VFAT} ${SDIMG_LINK_VFAT}
     fi
diff --git a/meta-raspberrypi/conf/layer.conf b/meta-raspberrypi/conf/layer.conf
index cfc2234..6e2fdf6 100644
--- a/meta-raspberrypi/conf/layer.conf
+++ b/meta-raspberrypi/conf/layer.conf
@@ -9,7 +9,7 @@
 BBFILE_PATTERN_raspberrypi := "^${LAYERDIR}/"
 BBFILE_PRIORITY_raspberrypi = "9"
 
-LAYERSERIES_COMPAT_raspberrypi = "sumo"
+LAYERSERIES_COMPAT_raspberrypi = "sumo thud"
 
 # Additional license directories.
 LICENSE_PATH += "${LAYERDIR}/files/custom-licenses"
@@ -23,3 +23,8 @@
                for layer in BBFILE_COLLECTIONS.split())}"
 BBFILES += "${@' '.join('${LAYERDIR}/dynamic-layers/%s/recipes*/*/*.bb' % layer \
                for layer in BBFILE_COLLECTIONS.split())}"
+
+BBFILES_DYNAMIC += " \
+    qt5-layer:${LAYERDIR}/dynamic-layers/qt5-layer/*/*/*.bb \
+    qt5-layer:${LAYERDIR}/dynamic-layers/qt5-layer/*/*/*.bbappend \
+"
diff --git a/meta-raspberrypi/conf/machine/include/rpi-base.inc b/meta-raspberrypi/conf/machine/include/rpi-base.inc
index 539d1bc..4bbd576 100644
--- a/meta-raspberrypi/conf/machine/include/rpi-base.inc
+++ b/meta-raspberrypi/conf/machine/include/rpi-base.inc
@@ -15,7 +15,9 @@
     "
 
 RPI_KERNEL_DEVICETREE_OVERLAYS ?= " \
+    overlays/at86rf233.dtbo \
     overlays/dwc2.dtbo \
+    overlays/gpio-key.dtbo \
     overlays/hifiberry-amp.dtbo \
     overlays/hifiberry-dac.dtbo \
     overlays/hifiberry-dacplus.dtbo \
@@ -24,18 +26,17 @@
     overlays/iqaudio-dac.dtbo \
     overlays/iqaudio-dacplus.dtbo \
     overlays/lirc-rpi.dtbo \
+    overlays/pi3-disable-bt.dtbo \
+    overlays/pi3-miniuart-bt.dtbo \
     overlays/pitft22.dtbo \
     overlays/pitft28-resistive.dtbo \
     overlays/pitft35-resistive.dtbo \
     overlays/pps-gpio.dtbo \
     overlays/rpi-ft5406.dtbo \
     overlays/rpi-poe.dtbo \
-    overlays/w1-gpio.dtbo \
-    overlays/w1-gpio-pullup.dtbo \
-    overlays/pi3-disable-bt.dtbo \
-    overlays/pi3-miniuart-bt.dtbo \
     overlays/vc4-kms-v3d.dtbo \
-    overlays/at86rf233.dtbo \
+    overlays/w1-gpio-pullup.dtbo \
+    overlays/w1-gpio.dtbo \
     "
 
 RPI_KERNEL_DEVICETREE ?= " \
@@ -84,23 +85,18 @@
     imgtyp = d.getVar('KERNEL_IMAGETYPE')
 
     def transform(dtb):
+        base = os.path.basename(dtb)
         if dtb.endswith('dtb'):
             # eg: whatever/bcm2708-rpi-b.dtb has:
-            #     DEPLOYDIR file: ${KERNEL_IMAGETYPE}-bcm2708-rpi-b.dtb
+            #     DEPLOYDIR file: bcm2708-rpi-b.dtb
             #     destination: bcm2708-rpi-b.dtb
-            base = os.path.basename(dtb)
-            src = '{}-{}'.format(imgtyp, base)
-            dst = base
-            return '{};{}'.format(src, dst)
+            return base
         elif dtb.endswith('dtbo'):
             # overlay dtb:
             # eg: overlays/hifiberry-amp.dtbo has:
-            #     DEPLOYDIR file: ${KERNEL_IMAGETYPE}-hifiberry-amp.dtbo
+            #     DEPLOYDIR file: hifiberry-amp.dtbo
             #     destination: overlays/hifiberry-amp.dtbo
-            base = os.path.basename(dtb)
-            src = '{}-{}'.format(imgtyp, base)
-            dst = dtb
-            return '{};{}'.format(src, dtb)
+            return '{};{}'.format(base, dtb)
 
     return ' '.join([transform(dtb) for dtb in alldtbs.split(' ') if dtb])
 
diff --git a/meta-raspberrypi/conf/machine/raspberrypi-cm3.conf b/meta-raspberrypi/conf/machine/raspberrypi-cm3.conf
index 153d5d5..5f6d3b6 100644
--- a/meta-raspberrypi/conf/machine/raspberrypi-cm3.conf
+++ b/meta-raspberrypi/conf/machine/raspberrypi-cm3.conf
@@ -2,5 +2,5 @@
 #@NAME: RaspberryPi Compute Module 3 (CM3)
 #@DESCRIPTION: Machine configuration for the RaspberryPi Compute Module 3 (CM3)
 
-MACHINEOVERRIDES = "raspberrypi2:${MACHINE}"
-include conf/machine/raspberrypi2.conf
+MACHINEOVERRIDES = "raspberrypi3:${MACHINE}"
+include conf/machine/raspberrypi3.conf
diff --git a/meta-raspberrypi/conf/machine/raspberrypi.conf b/meta-raspberrypi/conf/machine/raspberrypi.conf
index ddd3801..e94ad86 100644
--- a/meta-raspberrypi/conf/machine/raspberrypi.conf
+++ b/meta-raspberrypi/conf/machine/raspberrypi.conf
@@ -7,7 +7,6 @@
 require conf/machine/include/tune-arm1176jzf-s.inc
 include conf/machine/include/rpi-base.inc
 
-SERIAL_CONSOLE ?= "115200 ttyAMA0"
+SERIAL_CONSOLES ?= "115200;ttyAMA0"
 
 UBOOT_MACHINE = "rpi_config"
-VC4_CMA_SIZE_raspberrypi ?= "cma-64"
diff --git a/meta-raspberrypi/conf/machine/raspberrypi0-wifi.conf b/meta-raspberrypi/conf/machine/raspberrypi0-wifi.conf
index accdf3c..2c4f760 100644
--- a/meta-raspberrypi/conf/machine/raspberrypi0-wifi.conf
+++ b/meta-raspberrypi/conf/machine/raspberrypi0-wifi.conf
@@ -7,11 +7,10 @@
 include conf/machine/include/rpi-base.inc
 
 MACHINE_EXTRA_RRECOMMENDS += "\
-    linux-firmware-bcm43430 \
-    linux-firmware-bcm43430a1-hcd \
+    linux-firmware-rpidistro-bcm43430 \
+    bluez-firmware-rpidistro-bcm43430a1-hcd \
 "
 
 SDIMG_KERNELIMAGE ?= "kernel.img"
 UBOOT_MACHINE ?= "rpi_0_w_defconfig"
-SERIAL_CONSOLE ?= "115200 ttyS0"
-VC4_CMA_SIZE ?= "cma-128"
+SERIAL_CONSOLES ?= "115200;ttyS0"
diff --git a/meta-raspberrypi/conf/machine/raspberrypi0.conf b/meta-raspberrypi/conf/machine/raspberrypi0.conf
index 3bd9e95..80297b5 100644
--- a/meta-raspberrypi/conf/machine/raspberrypi0.conf
+++ b/meta-raspberrypi/conf/machine/raspberrypi0.conf
@@ -5,5 +5,4 @@
 MACHINEOVERRIDES = "raspberrypi:${MACHINE}"
 include conf/machine/raspberrypi.conf
 
-SERIAL_CONSOLE ?= "115200 ttyAMA0"
-VC4_CMA_SIZE ?= "cma-128"
+SERIAL_CONSOLES ?= "115200;ttyAMA0"
diff --git a/meta-raspberrypi/conf/machine/raspberrypi2.conf b/meta-raspberrypi/conf/machine/raspberrypi2.conf
index a17289c..bd191c3 100644
--- a/meta-raspberrypi/conf/machine/raspberrypi2.conf
+++ b/meta-raspberrypi/conf/machine/raspberrypi2.conf
@@ -7,7 +7,6 @@
 require conf/machine/include/tune-cortexa7.inc
 include conf/machine/include/rpi-base.inc
 
-SERIAL_CONSOLE ?= "115200 ttyAMA0"
+SERIAL_CONSOLES ?= "115200;ttyAMA0"
 
 UBOOT_MACHINE = "rpi_2_config"
-VC4_CMA_SIZE ?= "cma-256"
diff --git a/meta-raspberrypi/conf/machine/raspberrypi3-64.conf b/meta-raspberrypi/conf/machine/raspberrypi3-64.conf
index fb21b12..635e4f6 100644
--- a/meta-raspberrypi/conf/machine/raspberrypi3-64.conf
+++ b/meta-raspberrypi/conf/machine/raspberrypi3-64.conf
@@ -5,10 +5,10 @@
 MACHINEOVERRIDES = "raspberrypi3:${MACHINE}"
 
 MACHINE_EXTRA_RRECOMMENDS += "\
-    linux-firmware-bcm43430 \
-    linux-firmware-bcm43455 \
-    linux-firmware-bcm43430a1-hcd \
-    linux-firmware-bcm4345c0-hcd \
+    linux-firmware-rpidistro-bcm43430 \
+    linux-firmware-rpidistro-bcm43455 \
+    bluez-firmware-rpidistro-bcm43430a1-hcd \
+    bluez-firmware-rpidistro-bcm4345c0-hcd \
 "
 
 require conf/machine/include/arm/arch-armv8.inc
@@ -20,8 +20,7 @@
     broadcom/bcm2837-rpi-3-b.dtb \
     "
 
-SERIAL_CONSOLE ?= "115200 ttyS0"
-VC4_CMA_SIZE ?= "cma-256"
+SERIAL_CONSOLES ?= "115200;ttyS0"
 
 UBOOT_MACHINE = "rpi_3_config"
 MACHINE_FEATURES_append = " vc4graphics"
diff --git a/meta-raspberrypi/conf/machine/raspberrypi3.conf b/meta-raspberrypi/conf/machine/raspberrypi3.conf
index 8b5cce5..df64cbb 100644
--- a/meta-raspberrypi/conf/machine/raspberrypi3.conf
+++ b/meta-raspberrypi/conf/machine/raspberrypi3.conf
@@ -7,13 +7,12 @@
 include conf/machine/include/rpi-base.inc
 
 MACHINE_EXTRA_RRECOMMENDS += "\
-    linux-firmware-bcm43430 \
-    linux-firmware-bcm43455 \
-    linux-firmware-bcm43430a1-hcd \
-    linux-firmware-bcm4345c0-hcd \
+    linux-firmware-rpidistro-bcm43430 \
+    linux-firmware-rpidistro-bcm43455 \
+    bluez-firmware-rpidistro-bcm43430a1-hcd \
+    bluez-firmware-rpidistro-bcm4345c0-hcd \
 "
 
 SDIMG_KERNELIMAGE ?= "kernel7.img"
 UBOOT_MACHINE = "rpi_3_32b_config"
-SERIAL_CONSOLE ?= "115200 ttyS0"
-VC4_CMA_SIZE ?= "cma-256"
+SERIAL_CONSOLES ?= "115200;ttyS0"
diff --git a/meta-raspberrypi/docs/extra-build-config.md b/meta-raspberrypi/docs/extra-build-config.md
index 04314aa..732c102 100644
--- a/meta-raspberrypi/docs/extra-build-config.md
+++ b/meta-raspberrypi/docs/extra-build-config.md
@@ -158,17 +158,18 @@
 
 To build an initramfs image:
 
-* Set this 3 kernel variables (in linux-raspberrypi.inc for example)
+* Set this 3 kernel variables (in kernel's do_configure_prepend in linux-raspberrypi.inc after the line kernel_configure_variable LOCALVERSION "\"\""
+)
   - kernel_configure_variable BLK_DEV_INITRD y
   - kernel_configure_variable INITRAMFS_SOURCE ""
   - kernel_configure_variable RD_GZIP y
 
-* Set the yocto variables (in linux-raspberrypi.inc for example)
-  - `INITRAMFS_IMAGE = "<a name for your initramfs image>"`
+* Set the yocto variables (e.g. in local.conf)
+  - `INITRAMFS_IMAGE = "<name for your initramfs image>"`
   - `INITRAMFS_IMAGE_BUNDLE = "1"`
-
-* Set the meta-rasberrypi variable (in raspberrypi.conf for example)
-  - `KERNEL_INITRAMFS = "-initramfs"`
+  - `BOOT_SPACE = "1073741"`
+  - `INITRAMFS_MAXSIZE = "315400"`
+  - `IMAGE_FSTYPES_pn-${INITRAMFS_IMAGE} = "${INITRAMFS_FSTYPES}"`
 
 ## Enable SPI bus
 
diff --git a/meta-raspberrypi/dynamic-layers/qt5-layer/recipes-qt/qt5/qtbase_%.bbappend b/meta-raspberrypi/dynamic-layers/qt5-layer/recipes-qt/qt5/qtbase_%.bbappend
new file mode 100644
index 0000000..7d6ab84
--- /dev/null
+++ b/meta-raspberrypi/dynamic-layers/qt5-layer/recipes-qt/qt5/qtbase_%.bbappend
@@ -0,0 +1,17 @@
+PACKAGECONFIG_GL_rpi = "${@bb.utils.contains('DISTRO_FEATURES', 'x11 opengl', 'gl', \
+                        bb.utils.contains('DISTRO_FEATURES',     'opengl', 'eglfs gles2 linuxfb', \
+                                                                       '', d), d)}"
+#PACKAGECONFIG_GL_rpi = "${@bb.utils.any_distro_features('x11 wayland', '', 'eglfs', d)}"
+PACKAGECONFIG_FONTS_rpi = "fontconfig"
+PACKAGECONFIG_append_rpi = " libinput examples tslib xkb xkbcommon-evdev"
+PACKAGECONFIG_remove_rpi = "tests"
+
+OE_QTBASE_EGLFS_DEVICE_INTEGRATION_rpi = "${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', 'eglfs_kms', 'eglfs_brcm', d)}"
+
+do_configure_prepend_rpi() {
+    # Add the appropriate EGLFS_DEVICE_INTEGRATION
+    if [ "${@d.getVar('OE_QTBASE_EGLFS_DEVICE_INTEGRATION')}" != "" ]; then
+        echo "EGLFS_DEVICE_INTEGRATION = ${OE_QTBASE_EGLFS_DEVICE_INTEGRATION}" > ${S}/mkspecs/oe-device-extra.pri
+    fi
+}
+RDEPENDS_${PN}_append_rpi = " userland"
diff --git a/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config_git.bb b/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config_git.bb
index a85c916..d92b8e4 100644
--- a/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config_git.bb
+++ b/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config_git.bb
@@ -23,7 +23,6 @@
 PITFT35r="${@bb.utils.contains("MACHINE_FEATURES", "pitft35r", "1", "0", d)}"
 
 VC4GRAPHICS="${@bb.utils.contains("MACHINE_FEATURES", "vc4graphics", "1", "0", d)}"
-VC4DTBO_raspberrypi3-64 ?= "vc4-fkms-v3d"
 VC4DTBO ?= "vc4-kms-v3d"
 
 inherit deploy nopackages
@@ -159,7 +158,7 @@
     # VC4 Graphics support
     if [ "${VC4GRAPHICS}" = "1" ]; then
         echo "# Enable VC4 Graphics" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt
-        echo "dtoverlay=${VC4DTBO},${VC4_CMA_SIZE}" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt
+        echo "dtoverlay=${VC4DTBO}" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt
     fi
 
     # Waveshare "C" 1024x600 7" Rev2.1 IPS capacitive touch (http://www.waveshare.com/7inch-HDMI-LCD-C.htm)
diff --git a/meta-raspberrypi/recipes-bsp/common/firmware.inc b/meta-raspberrypi/recipes-bsp/common/firmware.inc
index 3baa1f8..7be848a 100644
--- a/meta-raspberrypi/recipes-bsp/common/firmware.inc
+++ b/meta-raspberrypi/recipes-bsp/common/firmware.inc
@@ -1,11 +1,11 @@
-RPIFW_DATE ?= "20180817"
-SRCREV ?= "53ac68e1eb02138f72a5056efed9dac9d3883a3f"
+RPIFW_DATE ?= "20180924"
+SRCREV ?= "5b49caa17e91d0e64024380119ad739bb201c674"
 RPIFW_SRC_URI ?= "https://github.com/raspberrypi/firmware/archive/${SRCREV}.tar.gz"
 RPIFW_S ?= "${WORKDIR}/firmware-${SRCREV}"
 
 SRC_URI = "${RPIFW_SRC_URI}"
-SRC_URI[md5sum] = "6b3d901decf2fe4fad151e3ebb28cb62"
-SRC_URI[sha256sum] = "3680de3ea9817b10fa8998b0dfa6811e58c96945474f4c782710dcd0a56c8cf0"
+SRC_URI[md5sum] = "51352972a029c6f47bde6d302b69440e"
+SRC_URI[sha256sum] = "d1f9c58957dfe681fff7e1cf1eabb9e0f6fdc99720f1d059fb24a37750573310"
 
 
 PV = "${RPIFW_DATE}"
diff --git a/meta-raspberrypi/recipes-bsp/u-boot/u-boot/0002-rpi_0_w-Add-configs-consistent-with-RpI3.patch b/meta-raspberrypi/recipes-bsp/u-boot/u-boot/0002-rpi_0_w-Add-configs-consistent-with-RpI3.patch
deleted file mode 100644
index e98fd85..0000000
--- a/meta-raspberrypi/recipes-bsp/u-boot/u-boot/0002-rpi_0_w-Add-configs-consistent-with-RpI3.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From 5d113dc0130ea2ea9faaa000fba9c737266b9747 Mon Sep 17 00:00:00 2001
-From: Drew Moseley <drew.moseley@northern.tech>
-Date: Fri, 9 Feb 2018 18:10:09 -0500
-Subject: [PATCH] rpi_0_w: Add configs consistent with RpI3
-
-Upstream-Status: Accepted [https://patchwork.ozlabs.org/patch/856572/]
-
-Signed-off-by: Drew Moseley <drew.moseley@northern.tech>
----
- configs/rpi_0_w_defconfig | 7 +++++++
- 1 file changed, 7 insertions(+)
-
-diff --git a/configs/rpi_0_w_defconfig b/configs/rpi_0_w_defconfig
-index 9a6d24b..1248294 100644
---- a/configs/rpi_0_w_defconfig
-+++ b/configs/rpi_0_w_defconfig
-@@ -12,14 +12,21 @@ CONFIG_SYS_PROMPT="U-Boot> "
- CONFIG_CMD_GPIO=y
- CONFIG_CMD_MMC=y
- CONFIG_CMD_USB=y
-+CONFIG_OF_EMBED=y
-+CONFIG_ENV_FAT_INTERFACE="mmc"
-+CONFIG_ENV_FAT_DEVICE_AND_PART="0:1"
-+CONFIG_DM_KEYBOARD=y
- CONFIG_DM_MMC=y
- CONFIG_MMC_SDHCI=y
- CONFIG_MMC_SDHCI_BCM2835=y
- CONFIG_DM_ETH=y
- CONFIG_USB=y
- CONFIG_DM_USB=y
-+CONFIG_USB_DWC2=y
- CONFIG_USB_STORAGE=y
- CONFIG_USB_KEYBOARD=y
-+CONFIG_USB_HOST_ETHER=y
-+CONFIG_USB_ETHER_SMSC95XX=y
- CONFIG_DM_VIDEO=y
- CONFIG_SYS_WHITE_ON_BLACK=y
- CONFIG_CONSOLE_SCROLL_LINES=10
--- 
-2.7.4
-
diff --git a/meta-raspberrypi/recipes-bsp/u-boot/u-boot_%.bbappend b/meta-raspberrypi/recipes-bsp/u-boot/u-boot_%.bbappend
index 7d4a49e..95015f4 100644
--- a/meta-raspberrypi/recipes-bsp/u-boot/u-boot_%.bbappend
+++ b/meta-raspberrypi/recipes-bsp/u-boot/u-boot_%.bbappend
@@ -1,7 +1 @@
-FILESEXTRAPATHS_prepend := "${THISDIR}/u-boot:"
-
-SRC_URI_append_rpi = " \
-    file://0002-rpi_0_w-Add-configs-consistent-with-RpI3.patch \
-"
-
 DEPENDS_append_rpi = " rpi-u-boot-scr"
diff --git a/meta-raspberrypi/recipes-connectivity/bluez5/bluez5/brcm43438.service b/meta-raspberrypi/recipes-connectivity/bluez5/bluez5/brcm43438.service
deleted file mode 100644
index a51f6bc..0000000
--- a/meta-raspberrypi/recipes-connectivity/bluez5/bluez5/brcm43438.service
+++ /dev/null
@@ -1,14 +0,0 @@
-[Unit]
-Description=Broadcom BCM43438 bluetooth HCI
-ConditionPathIsDirectory=/proc/device-tree/soc/gpio@7e200000/bt_pins
-Before=bluetooth.service
-BindsTo=dev-serial1.device
-After=dev-serial1.device
-
-[Service]
-Type=oneshot
-RemainAfterExit=yes
-ExecStart=/usr/bin/btuart
-
-[Install]
-WantedBy=multi-user.target
diff --git a/meta-raspberrypi/recipes-connectivity/bluez5/bluez5_%.bbappend b/meta-raspberrypi/recipes-connectivity/bluez5/bluez5_%.bbappend
index d1b84df..6651fb8 100644
--- a/meta-raspberrypi/recipes-connectivity/bluez5/bluez5_%.bbappend
+++ b/meta-raspberrypi/recipes-connectivity/bluez5/bluez5_%.bbappend
@@ -5,41 +5,12 @@
     file://0002-bcm43xx-The-UART-speed-must-be-reset-after-the-firmw.patch \
     file://0003-Increase-firmware-load-timeout-to-30s.patch \
     file://0004-Move-the-43xx-firmware-into-lib-firmware.patch \
-    file://brcm43438.service \
-    "
-
-BCM_BT_SERVICE = "brcm43438.service"
-
-enable_bcm_bluetooth() {
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-        install -d ${D}${systemd_unitdir}/system
-        install -m 0644 ${WORKDIR}/${BCM_BT_SERVICE} ${D}${systemd_unitdir}/system
-    fi
-}
-
-BCM_BT_RDEPENDS = "\
-    udev-rules-rpi \
-    pi-bluetooth \
 "
 
-# for raspberrypi3
+BCM_BT_RDEPENDS = "pi-bluetooth"
+
+SRC_URI_append_raspberrypi0-wifi = " ${BCM_BT_SOURCES}"
 SRC_URI_append_raspberrypi3 = " ${BCM_BT_SOURCES}"
 
-do_install_append_raspberrypi3() {
-    enable_bcm_bluetooth
-}
-
-SYSTEMD_SERVICE_${PN}_append_raspberrypi3 = " ${BCM_BT_SERVICE}"
-
-RDEPENDS_${PN}_append_raspberrypi3 = " ${BCM_BT_RDEPENDS}"
-
-# for raspberrypi0-wifi
-SRC_URI_append_raspberrypi0-wifi = " ${BCM_BT_SOURCES}"
-
-do_install_append_raspberrypi0-wifi() {
-    enable_bcm_bluetooth
-}
-
-SYSTEMD_SERVICE_${PN}_append_raspberrypi0-wifi = " ${BCM_BT_SERVICE}"
-
 RDEPENDS_${PN}_append_raspberrypi0-wifi = " ${BCM_BT_RDEPENDS}"
+RDEPENDS_${PN}_append_raspberrypi3 = " ${BCM_BT_RDEPENDS}"
diff --git a/meta-raspberrypi/recipes-connectivity/pi-bluetooth/pi-bluetooth/0001-bthelper-correct-path-for-hciconfig-under-Yocto.patch b/meta-raspberrypi/recipes-connectivity/pi-bluetooth/pi-bluetooth/0001-bthelper-correct-path-for-hciconfig-under-Yocto.patch
new file mode 100644
index 0000000..4583905
--- /dev/null
+++ b/meta-raspberrypi/recipes-connectivity/pi-bluetooth/pi-bluetooth/0001-bthelper-correct-path-for-hciconfig-under-Yocto.patch
@@ -0,0 +1,28 @@
+From af91c96951a11f81f5cea88a0010161592c89310 Mon Sep 17 00:00:00 2001
+From: "Peter A. Bigot" <pab@pabigot.com>
+Date: Wed, 14 Nov 2018 09:19:51 -0600
+Subject: [PATCH] bthelper: correct path for hciconfig under Yocto
+
+Upstream-Status: Inapproprate [OE-specific]
+Signed-off-by: Peter A. Bigot <pab@pabigot.com>
+---
+ usr/bin/bthelper | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/usr/bin/bthelper b/usr/bin/bthelper
+index 255fdeb..4e1a1a4 100755
+--- a/usr/bin/bthelper
++++ b/usr/bin/bthelper
+@@ -10,7 +10,7 @@ fi
+ 
+ dev="$1"
+ # Need to bring hci up before looking at MAC as it can be all zeros during init
+-/bin/hciconfig "$dev" up
+-/bin/hciconfig "$dev" |grep -q "BD Address: B8:27:EB:" || exit 0
++/usr/bin/hciconfig "$dev" up
++/usr/bin/hciconfig "$dev" |grep -q "BD Address: B8:27:EB:" || exit 0
+ /usr/bin/hcitool -i "$dev" cmd 0x3f 0x1c 0x01 0x02 0x00 0x01 0x01 > /dev/null
+ 
+-- 
+2.17.1
+
diff --git a/meta-raspberrypi/recipes-connectivity/pi-bluetooth/pi-bluetooth_git.bb b/meta-raspberrypi/recipes-connectivity/pi-bluetooth/pi-bluetooth_git.bb
index e185f25..b2401b9 100644
--- a/meta-raspberrypi/recipes-connectivity/pi-bluetooth/pi-bluetooth_git.bb
+++ b/meta-raspberrypi/recipes-connectivity/pi-bluetooth/pi-bluetooth_git.bb
@@ -6,17 +6,41 @@
     file://debian/copyright;md5=6af8de3c8ee71f8e91e9b22f84ff2022 \
 "
 
-SRC_URI = "git://github.com/RPi-Distro/pi-bluetooth"
-SRCREV = "2a7477966bb3c69838b224f3ea92cb49a88124d5"
-UPSTREAM_VERSION_UNKNOWN = "1"
+SRC_URI = "\
+    git://github.com/RPi-Distro/pi-bluetooth \
+    file://0001-bthelper-correct-path-for-hciconfig-under-Yocto.patch \
+"
+SRCREV = "2e1a393955910aea67bbf3c921be35a66e8a8fbe"
+PV = "1.1+git${SRCPV}"
 
 S = "${WORKDIR}/git"
 
+# hciuart.service replaces what was brcm43438.service 
+inherit systemd
+SYSTEMD_SERVICE_${PN} = "\
+    hciuart.service \
+    bthelper@.service \
+"
+
 inherit allarch
 
 do_install() {
+    install -d ${D}${sysconfdir}/udev/rules.d
+    install -m 0644 ${S}/lib/udev/rules.d/* ${D}${sysconfdir}/udev/rules.d
+
     install -d ${D}${bindir}
+    install -m 0755 ${S}/usr/bin/bthelper ${D}${bindir}
     install -m 0755 ${S}/usr/bin/btuart ${D}${bindir}
+
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+        install -d ${D}${systemd_system_unitdir}
+        install -m 0644 ${S}/debian/pi-bluetooth.bthelper@.service ${D}${systemd_system_unitdir}/bthelper@.service
+        install -m 0644 ${S}/debian/pi-bluetooth.hciuart.service ${D}${systemd_system_unitdir}/hciuart.service
+    fi
 }
 
-FILES_${PN} = "${bindir}"
+FILES_${PN} = "\
+    ${bindir} \
+    ${sysconfdir} \
+    ${systemd_unitdir}/system \
+"
diff --git a/meta-raspberrypi/recipes-core/packagegroups/packagegroup-core-tools-testapps.bbappend b/meta-raspberrypi/recipes-core/packagegroups/packagegroup-core-tools-testapps.bbappend
new file mode 100644
index 0000000..500d871
--- /dev/null
+++ b/meta-raspberrypi/recipes-core/packagegroups/packagegroup-core-tools-testapps.bbappend
@@ -0,0 +1,2 @@
+# mesa-demos needs gles1 and userland driver does not have it, works ok with vc4 graphics driver
+X11GLTOOLS_remove_rpi = "${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', '', 'mesa-demos', d)}"
diff --git a/meta-raspberrypi/recipes-core/packagegroups/packagegroup-rpi-test.bb b/meta-raspberrypi/recipes-core/packagegroups/packagegroup-rpi-test.bb
index d91ce0b..9159346 100644
--- a/meta-raspberrypi/recipes-core/packagegroups/packagegroup-rpi-test.bb
+++ b/meta-raspberrypi/recipes-core/packagegroups/packagegroup-rpi-test.bb
@@ -6,8 +6,7 @@
 
 COMPATIBLE_MACHINE = "^rpi$"
 
-OMXPLAYER_rpi = "omxplayer"
-OMXPLAYER_rpi_aarch64 = ""
+OMXPLAYER  = "${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', '', 'omxplayer', d)}"
 
 RDEPENDS_${PN} = "\
     ${OMXPLAYER} \
diff --git a/meta-raspberrypi/recipes-devtools/pi-blaster/files/0001-pi-blaster-Include-sys-sysmacros.h-for-makedev.patch b/meta-raspberrypi/recipes-devtools/pi-blaster/files/0001-pi-blaster-Include-sys-sysmacros.h-for-makedev.patch
new file mode 100644
index 0000000..b4bc4b2
--- /dev/null
+++ b/meta-raspberrypi/recipes-devtools/pi-blaster/files/0001-pi-blaster-Include-sys-sysmacros.h-for-makedev.patch
@@ -0,0 +1,32 @@
+From 6a6b705ff5cba960c54bdb4d4bcdaa3b00a854a2 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 11 Aug 2018 10:24:24 -0700
+Subject: [PATCH] pi-blaster: Include sys/sysmacros.h for makedev()
+
+In glibc 2.28+ this header is not included indirectly anymore
+
+fixes
+
+ld: pi-blaster.o: in function `mbox_open':
+pi-blaster.c:(.text+0x28): undefined reference to `makedev'
+collect2: error: ld returned 1 exit status
+
+Upstream-Status: Submitted [https://github.com/sarfata/pi-blaster/pull/100]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ pi-blaster.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/pi-blaster.c b/pi-blaster.c
+index 6cfd010..fc4e686 100644
+--- a/pi-blaster.c
++++ b/pi-blaster.c
+@@ -41,6 +41,7 @@ static char VERSION[] = "SNAPSHOT";
+ #include <sys/time.h>
+ #include <sys/types.h>
+ #include <sys/stat.h>
++#include <sys/sysmacros.h>
+ #include <fcntl.h>
+ #include <sys/mman.h>
+ #include "mailbox.h"
diff --git a/meta-raspberrypi/recipes-devtools/pi-blaster/pi-blaster_git.bb b/meta-raspberrypi/recipes-devtools/pi-blaster/pi-blaster_git.bb
index 2748459..9cedf5e 100644
--- a/meta-raspberrypi/recipes-devtools/pi-blaster/pi-blaster_git.bb
+++ b/meta-raspberrypi/recipes-devtools/pi-blaster/pi-blaster_git.bb
@@ -2,15 +2,16 @@
 HOMEPAGE = "https://github.com/sarfata/pi-blaster/"
 SECTION = "devel/libs"
 LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://README.md;beginline=225;endline=252;md5=a012868ef5f83b9f257af253d7cb07a3"
+LIC_FILES_CHKSUM = "file://README.md;beginline=244;endline=268;md5=86d10e4bcf4b4014d306dde7c1d2a80d"
 
 SRC_URI = "git://github.com/sarfata/pi-blaster \
            file://remove-initscript-lsb-dependency.patch \
-"
+           file://0001-pi-blaster-Include-sys-sysmacros.h-for-makedev.patch \
+           "
 
 S = "${WORKDIR}/git"
 
-SRCREV = "1035ad7dffb270c40eec1bb3a654171a755fba98"
+SRCREV = "e981aa5d7624c75a4d4afcddcbd235f25e32ffe4"
 
 inherit update-rc.d autotools
 
diff --git a/meta-raspberrypi/recipes-devtools/wiringpi/files/0001-Add-initial-cross-compile-support.patch b/meta-raspberrypi/recipes-devtools/wiringpi/files/0001-Add-initial-cross-compile-support.patch
index 01e0546..d97bbef 100644
--- a/meta-raspberrypi/recipes-devtools/wiringpi/files/0001-Add-initial-cross-compile-support.patch
+++ b/meta-raspberrypi/recipes-devtools/wiringpi/files/0001-Add-initial-cross-compile-support.patch
@@ -1,8 +1,11 @@
-From ca25788e2563bad0d554deb9f4300d1e7d062825 Mon Sep 17 00:00:00 2001
-From: Aurelian Zanoschi <aurelian17@gmail.com>
-Date: Mon, 31 Jul 2017 20:25:15 +0300
+From 9a47fd5da546d148886c8890cd48249ebe826948 Mon Sep 17 00:00:00 2001
+From: Daniel Rank <dwrank@gmail.com>
+Date: Wed, 1 Aug 2018 23:32:00 -0700
 Subject: [PATCH] Add initial cross compile support
 
+Upstream-Status: Pending
+Signed-off-by: Daniel Rank <dwrank@gmail.com>
+
 ---
  devLib/Makefile             | 54 +++++++++++++++++++++++++--------------------
  examples/Gertboard/Makefile | 22 +++++++++++-------
@@ -11,8 +14,8 @@
  examples/PiGlow/Makefile    |  4 ++--
  examples/q2w/Makefile       |  4 ++--
  gpio/Makefile               | 29 ++++++++++++------------
- wiringPi/Makefile           | 52 ++++++++++++++++++++++++-------------------
- 8 files changed, 120 insertions(+), 89 deletions(-)
+ wiringPi/Makefile           | 46 +++++++++++++++++++++-----------------
+ 8 files changed, 117 insertions(+), 86 deletions(-)
 
 diff --git a/devLib/Makefile b/devLib/Makefile
 index cf665d6..040c03a 100644
@@ -248,7 +251,7 @@
  
  ###############################################################################
 diff --git a/gpio/Makefile b/gpio/Makefile
-index f41a005..22753ee 100644
+index 9ec160d..a294242 100644
 --- a/gpio/Makefile
 +++ b/gpio/Makefile
 @@ -30,13 +30,17 @@ ifneq ($V,1)
@@ -284,8 +287,8 @@
 -	$Q chown root.root	$(DESTDIR)$(PREFIX)/bin/gpio
 -	$Q chmod 4755		$(DESTDIR)$(PREFIX)/bin/gpio
 -endif
--	$Q mkdir -p		$(DESTDIR)$(PREFIX)/man/man1
--	$Q cp gpio.1		$(DESTDIR)$(PREFIX)/man/man1
+-	$Q mkdir -p		$(DESTDIR)$(PREFIX)/share/man/man1
+-	$Q cp gpio.1		$(DESTDIR)$(PREFIX)/share/man/man1
 +	$Q install -d $(BIN_DIR)
 +	$Q install -m 4755 -o root -g root gpio $(BIN_DIR)
 +	$Q install -d $(DESTDIR)$(PREFIX)/share/man/man1
@@ -299,14 +302,14 @@
  	$Q echo "[UnInstall]"
 -	$Q rm -f $(DESTDIR)$(PREFIX)/bin/gpio
 +	$Q rm -f $(BIN_DIR)/gpio
- 	$Q rm -f $(DESTDIR)$(PREFIX)/man/man1/gpio.1
+ 	$Q rm -f $(DESTDIR)$(PREFIX)/share/man/man1/gpio.1
  
  .PHONY:	depend
 diff --git a/wiringPi/Makefile b/wiringPi/Makefile
-index e1868b9..750d290 100644
+index 287fa58..670a6db 100644
 --- a/wiringPi/Makefile
 +++ b/wiringPi/Makefile
-@@ -25,21 +25,25 @@ VERSION=$(shell cat ../VERSION)
+@@ -25,22 +25,26 @@ VERSION=$(shell cat ../VERSION)
  DESTDIR?=/usr
  PREFIX?=/local
  
@@ -335,11 +338,13 @@
 +INCLUDE	?= -I.
  DEFS	= -D_GNU_SOURCE
 -CFLAGS	= $(DEBUG) $(DEFS) -Wformat=2 -Wall -Wextra -Winline $(INCLUDE) -pipe -fPIC
+-#CFLAGS	= $(DEBUG) $(DEFS) -Wformat=2 -Wall -Wextra -Wconversion -Winline $(INCLUDE) -pipe -fPIC
 +CFLAGS	= $(DEBUG) $(DEFS) $(INCLUDE) -Wformat=2 -Wall -Wextra -Winline -pipe -fPIC
++#CFLAGS	= $(DEBUG) $(DEFS) $(INCLUDE) -Wformat=2 -Wall -Wextra -Wconversion -Winline -pipe -fPIC
  
  LIBS    = -lm -lpthread -lrt -lcrypt
  
-@@ -78,17 +82,17 @@ $(STATIC):	$(OBJ)
+@@ -75,17 +79,17 @@ static:
  
  $(DYNAMIC):	$(OBJ)
  	$Q echo "[Link (Dynamic)]"
@@ -360,7 +365,7 @@
  
  .PHONY:	tags
  tags:	$(SRC)
-@@ -99,22 +103,22 @@ tags:	$(SRC)
+@@ -96,13 +100,13 @@ tags:	$(SRC)
  .PHONY:	install
  install:	$(DYNAMIC)
  	$Q echo "[Install Headers]"
@@ -378,22 +383,9 @@
 +	$Q ln -sf $(DYNAMIC)						$(LIB_DIR)/$(BASE_NAME).so
 +	$Q ln -sf $(DYNAMIC)						$(LIB_DIR)/$(BASE_NAME).so.$(DYN_VERS_MAJ)
  
- .PHONY:	install-static
- install-static:	$(STATIC)
- 	$Q echo "[Install Headers]"
--	$Q install -m 0755 -d						$(DESTDIR)$(PREFIX)/include
--	$Q install -m 0644 $(HEADERS)					$(DESTDIR)$(PREFIX)/include
-+	$Q install -m 0755 -d						$(INCLUDE_DIR)
-+	$Q install -m 0644 $(HEADERS)					$(INCLUDE_DIR)
- 	$Q echo "[Install Static Lib]"
--	$Q install -m 0755 -d						$(DESTDIR)$(PREFIX)/lib
--	$Q install -m 0755 libwiringPi.a					$(DESTDIR)$(PREFIX)/lib
-+	$Q install -m 0755 -d						$(LIB_DIR)
-+	$Q install -m 0755 $(STATIC)					$(LIB_DIR)
- 
  .PHONY:	install-deb
  install-deb:	$(DYNAMIC)
-@@ -129,9 +133,11 @@ install-deb:	$(DYNAMIC)
+@@ -117,9 +121,11 @@ install-deb:	$(DYNAMIC)
  .PHONY:	uninstall
  uninstall:
  	$Q echo "[UnInstall]"
diff --git a/meta-raspberrypi/recipes-devtools/wiringpi/wiringpi_git.bb b/meta-raspberrypi/recipes-devtools/wiringpi/wiringpi_git.bb
index f1b01db..e78c58a 100644
--- a/meta-raspberrypi/recipes-devtools/wiringpi/wiringpi_git.bb
+++ b/meta-raspberrypi/recipes-devtools/wiringpi/wiringpi_git.bb
@@ -4,8 +4,10 @@
 LICENSE = "LGPLv3+"
 LIC_FILES_CHKSUM = "file://COPYING.LESSER;md5=e6a600fd5e1d9cbde2d983680233ad02"
 
-# tag 2.44
-SRCREV = "96344ff7125182989f98d3be8d111952a8f74e15"
+DEPENDS += "virtual/crypt"
+
+# tag 2.46
+SRCREV = "8d188fa0e00bb8c6ff6eddd07bf92857e9bd533a"
 
 S = "${WORKDIR}/git"
 
diff --git a/meta-raspberrypi/recipes-graphics/eglinfo/eglinfo-fb_%.bbappend b/meta-raspberrypi/recipes-graphics/eglinfo/eglinfo-fb_%.bbappend
index 7692133..c152bd9 100644
--- a/meta-raspberrypi/recipes-graphics/eglinfo/eglinfo-fb_%.bbappend
+++ b/meta-raspberrypi/recipes-graphics/eglinfo/eglinfo-fb_%.bbappend
@@ -1,2 +1,2 @@
 EGLINFO_DEVICE_rpi  = "raspberrypi"
-COMPATIBLE_HOST_rpi = "${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', 'null', '"(.*)"', d)}"
+COMPATIBLE_HOST_rpi = "${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', 'null', '(.*)', d)}"
diff --git a/meta-raspberrypi/recipes-graphics/kmscube/kmscube_%.bbappend b/meta-raspberrypi/recipes-graphics/kmscube/kmscube_%.bbappend
new file mode 100644
index 0000000..9343fb0
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/kmscube/kmscube_%.bbappend
@@ -0,0 +1,2 @@
+# userland driver EGL implementation does not have all needed bits for it so remove it from build
+COMPATIBLE_HOST_rpi = "${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', '(.*)', 'null', d)}"
diff --git a/meta-raspberrypi/recipes-graphics/mesa/mesa-demos_%.bbappend b/meta-raspberrypi/recipes-graphics/mesa/mesa-demos_%.bbappend
new file mode 100644
index 0000000..c187ab9
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/mesa/mesa-demos_%.bbappend
@@ -0,0 +1,2 @@
+# mesa-demos need libgles1 and userland driver does not have it
+COMPATIBLE_HOST_rpi = "${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', '(.*)', 'null', d)}"
diff --git a/meta-raspberrypi/recipes-graphics/mesa/mesa_%.bbappend b/meta-raspberrypi/recipes-graphics/mesa/mesa_%.bbappend
index 52fe757..8152cc3 100644
--- a/meta-raspberrypi/recipes-graphics/mesa/mesa_%.bbappend
+++ b/meta-raspberrypi/recipes-graphics/mesa/mesa_%.bbappend
@@ -3,5 +3,5 @@
 # as default. To state out clearly that Raspi needs dri3 and to avoid surprises
 # in case oe-core changes this default, we set dri3 explicitly.
 PACKAGECONFIG_append_rpi = " gallium ${@bb.utils.contains('DISTRO_FEATURES', 'x11 opengl', 'x11 dri3', '', d)}"
-GALLIUMDRIVERS_rpi = "vc4"
+GALLIUMDRIVERS_append_rpi = ",vc4"
 DRIDRIVERS_rpi = ""
diff --git a/meta-raspberrypi/recipes-graphics/piglit/piglit_%.bbappend b/meta-raspberrypi/recipes-graphics/piglit/piglit_%.bbappend
new file mode 100644
index 0000000..0503fd0
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/piglit/piglit_%.bbappend
@@ -0,0 +1,5 @@
+# mesa-demos need libgles1 and userland driver does not have it so remove it from piglit rdeps
+RDEPENDS_${PN}_remove_rpi = "${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', '', 'mesa-demos', d)}"
+# it needs EGL >= 11 but userland says it provided version 10, remove it from build
+# | --   Requested 'egl >= 11.0' but version of EGL is 10
+COMPATIBLE_HOST_rpi = "${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', '(.*)', 'null', d)}"
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0001-Allow-applications-to-set-next-resource-handle.patch b/meta-raspberrypi/recipes-graphics/userland/files/0001-Allow-applications-to-set-next-resource-handle.patch
new file mode 100644
index 0000000..d6b2abb
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0001-Allow-applications-to-set-next-resource-handle.patch
@@ -0,0 +1,208 @@
+From 08d56c1174e27573ae8df2a7b9e6632afd0bfe86 Mon Sep 17 00:00:00 2001
+From: Dom Cobley <dc4@broadcom.com>
+Date: Tue, 9 Jul 2013 09:26:26 -0400
+Subject: [PATCH 01/18] Allow applications to set next resource handle
+
+This patch adds provisions in userland to
+let apps callers set the next rendereing dispmanx resource.
+It's useful for implementing, say, a buffer carousel.
+---
+ interface/khronos/common/khrn_client_rpc.h |  2 ++
+ interface/khronos/common/khrn_int_ids.h    |  2 ++
+ interface/khronos/egl/egl_client.c         | 30 +++++++++++++++++++---
+ interface/khronos/egl/egl_client_surface.c | 24 ++++++++++++++++-
+ interface/khronos/egl/egl_client_surface.h |  3 ++-
+ interface/khronos/egl/egl_int_impl.h       |  5 ++--
+ 6 files changed, 59 insertions(+), 7 deletions(-)
+
+diff --git a/interface/khronos/common/khrn_client_rpc.h b/interface/khronos/common/khrn_client_rpc.h
+index dc4351d..10ea060 100644
+--- a/interface/khronos/common/khrn_client_rpc.h
++++ b/interface/khronos/common/khrn_client_rpc.h
+@@ -685,6 +685,7 @@ static INLINE void rpc_call12_out_ctrl(CLIENT_THREAD_STATE_T *thread,uint32_t id
+ static INLINE void rpc_call13_out_ctrl(CLIENT_THREAD_STATE_T *thread,uint32_t id, uint32_t p0, uint32_t p1, uint32_t p2, uint32_t p3, uint32_t p4, uint32_t p5, uint32_t p6, uint32_t p7, uint32_t p8, uint32_t p9, uint32_t p10, uint32_t p11, void *out)               { rpc_begin(thread); RPC_CALL(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11);      rpc_recv(thread, out, NULL, (RPC_RECV_FLAG_T)(RPC_RECV_FLAG_CTRL | RPC_RECV_FLAG_LEN)); rpc_end(thread); }
+ static INLINE void rpc_call14_out_ctrl(CLIENT_THREAD_STATE_T *thread,uint32_t id, uint32_t p0, uint32_t p1, uint32_t p2, uint32_t p3, uint32_t p4, uint32_t p5, uint32_t p6, uint32_t p7, uint32_t p8, uint32_t p9, uint32_t p10, uint32_t p11, uint32_t p12, void *out) { rpc_begin(thread); RPC_CALL(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12); rpc_recv(thread, out, NULL, (RPC_RECV_FLAG_T)(RPC_RECV_FLAG_CTRL | RPC_RECV_FLAG_LEN)); rpc_end(thread); }
+ static INLINE void rpc_call15_out_ctrl(CLIENT_THREAD_STATE_T *thread,uint32_t id, uint32_t p0, uint32_t p1, uint32_t p2, uint32_t p3, uint32_t p4, uint32_t p5, uint32_t p6, uint32_t p7, uint32_t p8, uint32_t p9, uint32_t p10, uint32_t p11, uint32_t p12, uint32_t p13, void *out) { rpc_begin(thread); RPC_CALL(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13); rpc_recv(thread, out, NULL, (RPC_RECV_FLAG_T)(RPC_RECV_FLAG_CTRL | RPC_RECV_FLAG_LEN)); rpc_end(thread); }
++static INLINE void rpc_call16_out_ctrl(CLIENT_THREAD_STATE_T *thread,uint32_t id, uint32_t p0, uint32_t p1, uint32_t p2, uint32_t p3, uint32_t p4, uint32_t p5, uint32_t p6, uint32_t p7, uint32_t p8, uint32_t p9, uint32_t p10, uint32_t p11, uint32_t p12, uint32_t p13, uint32_t p14, void *out) { rpc_begin(thread); RPC_CALL(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14); rpc_recv(thread, out, NULL, (RPC_RECV_FLAG_T)(RPC_RECV_FLAG_CTRL | RPC_RECV_FLAG_LEN)); rpc_end(thread); }
+ #endif
+ 
+ #define RPC_CALL1_OUT_CTRL(fn, thread, id, out)                                               rpc_call1_out_ctrl(thread, id, out)
+@@ -702,6 +703,7 @@ static INLINE void rpc_call15_out_ctrl(CLIENT_THREAD_STATE_T *thread,uint32_t id
+ #define RPC_CALL13_OUT_CTRL(fn, thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, out)      rpc_call13_out_ctrl(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, out)
+ #define RPC_CALL14_OUT_CTRL(fn, thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, out) rpc_call14_out_ctrl(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, out)
+ #define RPC_CALL15_OUT_CTRL(fn, thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, out) rpc_call15_out_ctrl(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, out)
++#define RPC_CALL16_OUT_CTRL(fn, thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, out) rpc_call16_out_ctrl(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, out)
+ 
+ # if !defined(__SYMBIAN32__)  //use functions defined in khrpc.cpp
+ static INLINE uint32_t rpc_call1_out_ctrl_res(CLIENT_THREAD_STATE_T *thread,uint32_t id, void *out)                                                                                                                       { uint32_t res; rpc_begin(thread); RPC_CALL(thread, id);                                     res = rpc_recv(thread, out, NULL, (RPC_RECV_FLAG_T)(RPC_RECV_FLAG_RES | RPC_RECV_FLAG_CTRL | RPC_RECV_FLAG_LEN)); rpc_end(thread); return res; }
+diff --git a/interface/khronos/common/khrn_int_ids.h b/interface/khronos/common/khrn_int_ids.h
+index 8378f4a..ec961e0 100644
+--- a/interface/khronos/common/khrn_int_ids.h
++++ b/interface/khronos/common/khrn_int_ids.h
+@@ -367,6 +367,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+ 
+ #define EGLINTCREATESURFACE_ID            0x4000
++#define EGLINTCREATESURFACE_ID_V2         0x4100
+ #define EGLINTCREATEGLES11_ID             0x4001
+ #define EGLINTCREATEGLES20_ID             0x4002
+ #define EGLINTCREATEVG_ID                 0x4003
+@@ -377,6 +378,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ #define EGLINTMAKECURRENT_ID              0x4008
+ #define EGLINTFLUSHANDWAIT_ID             0x4009
+ #define EGLINTSWAPBUFFERS_ID              0x400a
++#define EGLINTSWAPBUFFERS_ID_V2           0x410a
+ #define EGLINTSELECTMIPMAP_ID             0x400b
+ #define EGLINTFLUSH_ID                    0x400c
+ #define EGLINTGETCOLORDATA_ID             0x400d
+diff --git a/interface/khronos/egl/egl_client.c b/interface/khronos/egl/egl_client.c
+index 9d617c8..b8bb374 100644
+--- a/interface/khronos/egl/egl_client.c
++++ b/interface/khronos/egl/egl_client.c
+@@ -162,6 +162,17 @@ static void egl_current_release(CLIENT_PROCESS_STATE_T *process, EGL_CURRENT_T *
+ void egl_gl_flush_callback(bool wait);
+ void egl_vg_flush_callback(bool wait);
+ 
++#include "interface/vmcs_host/vc_dispmanx_types.h"
++/**HACKHACK - give us the ability to inject a DispmanX 
++ * resource handle into the CreateWindowSurface and 
++ * SwapBuffers calls */ 
++static DISPMANX_RESOURCE_HANDLE_T next_resource_handle;
++
++EGLAPI EGLBoolean EGLAPIENTRY eglSetNextResourceHandle(DISPMANX_RESOURCE_HANDLE_T handle)
++{
++   next_resource_handle = handle;
++}
++
+ /*
+ TODO: do an RPC call to make sure the Khronos vll is loaded (and that it stays loaded until eglTerminate)
+ Also affects global image (and possibly others?)
+@@ -644,7 +655,8 @@ EGLAPI EGLSurface EGLAPIENTRY eglCreateWindowSurface(EGLDisplay dpy, EGLConfig c
+                                 false,
+                                 EGL_NO_TEXTURE,
+                                 EGL_NO_TEXTURE,
+-                                0, 0);
++                                0, 0,
++                                next_resource_handle);
+ 
+                if (surface) {
+                   if (khrn_pointer_map_insert(&process->surfaces, process->next_surface, surface)) {
+@@ -889,7 +901,7 @@ EGLAPI EGLSurface EGLAPIENTRY eglCreatePbufferSurface(EGLDisplay dpy, EGLConfig
+                              mipmap_texture,
+                              texture_format,
+                              texture_target,
+-                             0, 0);
++                             0, 0, 0);
+ 
+             if (surface) {
+                if (khrn_pointer_map_insert(&process->surfaces, process->next_surface, surface)) {
+@@ -1031,7 +1043,7 @@ EGLAPI EGLSurface EGLAPIENTRY eglCreatePixmapSurface(EGLDisplay dpy, EGLConfig c
+                                    false,
+                                    EGL_NO_TEXTURE,
+                                    EGL_NO_TEXTURE,
+-                                   pixmap, ((server_handle[0] == 0) && (server_handle[1] == (uint32_t)(-1))) ? NULL : server_handle);
++                                   pixmap, ((server_handle[0] == 0) && (server_handle[1] == (uint32_t)(-1))) ? NULL : server_handle, 0);
+ 
+                      if (surface) {
+                         if (khrn_pointer_map_insert(&process->surfaces, process->next_surface, surface)) {
+@@ -2303,6 +2315,18 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+ 
+                vcos_log_trace("eglSwapBuffers server call");
+ 
++               if (next_resource_handle)
++               RPC_CALL7(eglIntSwapBuffers_impl,
++                     thread,
++                     EGLINTSWAPBUFFERS_ID_V2,
++                     RPC_UINT(surface->serverbuffer),
++                     RPC_UINT(surface->width),
++                     RPC_UINT(surface->height),
++                     RPC_UINT(surface->internal_handle),
++                     RPC_UINT(surface->swap_behavior == EGL_BUFFER_PRESERVED ? 1 : 0),
++                     RPC_UINT(khrn_platform_get_window_position(surface->win)),
++                     RPC_INT(next_resource_handle));
++               else
+                RPC_CALL6(eglIntSwapBuffers_impl,
+                      thread,
+                      EGLINTSWAPBUFFERS_ID,
+diff --git a/interface/khronos/egl/egl_client_surface.c b/interface/khronos/egl/egl_client_surface.c
+index 6846dfa..128325e 100644
+--- a/interface/khronos/egl/egl_client_surface.c
++++ b/interface/khronos/egl/egl_client_surface.c
+@@ -314,7 +314,8 @@ EGL_SURFACE_T *egl_surface_create(
+    EGLenum texture_format,
+    EGLenum texture_target,
+    EGLNativePixmapType pixmap,
+-   const uint32_t *pixmap_server_handle)
++   const uint32_t *pixmap_server_handle,
++   DISPMANX_RESOURCE_HANDLE_T next_resource_handle)
+ {
+    KHRN_IMAGE_FORMAT_T color;
+    KHRN_IMAGE_FORMAT_T depth;
+@@ -473,6 +474,27 @@ EGL_SURFACE_T *egl_surface_create(
+ #endif
+          uint32_t results[3];
+ 
++         if (next_resource_handle)
++         RPC_CALL16_OUT_CTRL(eglIntCreateSurface_impl,
++                             thread,
++                             EGLINTCREATESURFACE_ID_V2,
++                             RPC_UINT(serverwin),
++                             RPC_UINT(buffers),
++                             RPC_UINT(width),
++                             RPC_UINT(height),
++                             RPC_UINT(color),
++                             RPC_UINT(depth),
++                             RPC_UINT(mask),
++                             RPC_UINT(multi),
++                             RPC_UINT(largest_pbuffer),
++                             RPC_UINT(mipmap_texture),
++                             RPC_UINT(config_depth_bits),
++                             RPC_UINT(config_stencil_bits),
++                             RPC_UINT(sem_name),
++                             RPC_UINT(type),
++                             RPC_INT(next_resource_handle),
++                             results);
++         else
+          RPC_CALL15_OUT_CTRL(eglIntCreateSurface_impl,
+                              thread,
+                              EGLINTCREATESURFACE_ID,
+diff --git a/interface/khronos/egl/egl_client_surface.h b/interface/khronos/egl/egl_client_surface.h
+index c99d44c..b5bf70a 100644
+--- a/interface/khronos/egl/egl_client_surface.h
++++ b/interface/khronos/egl/egl_client_surface.h
+@@ -322,7 +322,8 @@ extern EGL_SURFACE_T *egl_surface_create(
+    EGLenum texture_format,
+    EGLenum texture_target,
+    EGLNativePixmapType pixmap,
+-   const uint32_t *pixmap_server_handle);
++   const uint32_t *pixmap_server_handle,
++   DISPMANX_RESOURCE_HANDLE_T next_resource_handle);
+ extern EGL_SURFACE_T *egl_surface_from_vg_image(
+    VGImage vg_handle,
+    EGLSurface name,
+diff --git a/interface/khronos/egl/egl_int_impl.h b/interface/khronos/egl/egl_int_impl.h
+index 8a5734c..51b3580 100644
+--- a/interface/khronos/egl/egl_int_impl.h
++++ b/interface/khronos/egl/egl_int_impl.h
+@@ -56,7 +56,8 @@ FN(int, eglIntCreateSurface_impl, (
+    uint32_t config_stencil_bits,
+    uint32_t sem,
+    uint32_t type,
+-   uint32_t *results))
++   uint32_t *results,
++   DISPMANX_RESOURCE_HANDLE_T next_resource_handle))
+ 
+ FN(int, eglIntCreatePbufferFromVGImage_impl, (
+    VGImage vg_handle,
+@@ -110,7 +111,7 @@ FN(void, eglIntMakeCurrent_impl, (uint32_t pid_0, uint32_t pid_1, uint32_t glver
+ FN(int, eglIntFlushAndWait_impl, (uint32_t flushgl, uint32_t flushvg))
+ FN(void, eglIntFlush_impl, (uint32_t flushgl, uint32_t flushvg))
+ 
+-FN(void, eglIntSwapBuffers_impl, (EGL_SURFACE_ID_T s, uint32_t width, uint32_t height, uint32_t handle, uint32_t preserve, uint32_t position))
++FN(void, eglIntSwapBuffers_impl, (EGL_SURFACE_ID_T s, uint32_t width, uint32_t height, uint32_t handle, uint32_t preserve, uint32_t position, DISPMANX_RESOURCE_HANDLE_T new_back_buffer))
+ FN(void, eglIntSelectMipmap_impl, (EGL_SURFACE_ID_T s, int level))
+ 
+ FN(void, eglIntGetColorData_impl, (EGL_SURFACE_ID_T s, KHRN_IMAGE_FORMAT_T format, uint32_t width, uint32_t height, int32_t stride, uint32_t y_offset, void *data))
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0002-wayland-Add-support-for-the-Wayland-winsys.patch b/meta-raspberrypi/recipes-graphics/userland/files/0002-wayland-Add-support-for-the-Wayland-winsys.patch
new file mode 100644
index 0000000..c41cde7
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0002-wayland-Add-support-for-the-Wayland-winsys.patch
@@ -0,0 +1,1898 @@
+From da60a2a34a48e2b324fceae608964814488cc8fb Mon Sep 17 00:00:00 2001
+From: Tomeu Vizoso <tomeu.vizoso@collabora.com>
+Date: Tue, 1 Oct 2013 13:19:20 +0200
+Subject: [PATCH 02/18] wayland: Add support for the Wayland winsys
+
+* Adds EGL_WL_bind_wayland_display extension
+* Adds wayland-egl library
+* Adds wl_dispmanx_buffer protocol extension
+
+TODO: Check that platform_get_dimensions() returning swapchain_count == 1 is correct
+
+TODO: Remove the requirement of passing a valid DispmanX element handle to
+the SwapBuffers and CreateSurface RPC calls. This will remove the need to open
+a DispmanX display from the clients.
+
+TODO: wl_dispmanx_server_buffer should probably be defined in a
+private header that can be included from EGL and vc_* instead of in
+vc_vchi_dispmanx.h
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ .gitignore                                    |   1 +
+ CMakeLists.txt                                |  11 +
+ README.md                                     |   4 +
+ buildme                                       |  10 +-
+ .../linux/apps/raspicam/CMakeLists.txt        |   2 +-
+ interface/khronos/CMakeLists.txt              |  54 +++-
+ interface/khronos/common/khrn_client.c        |  15 ++
+ interface/khronos/common/khrn_client.h        |  10 +
+ interface/khronos/common/khrn_client_mangle.h |   3 +
+ .../khronos/common/khrn_client_platform.h     |   8 +
+ .../khronos/common/khrn_client_unmangle.h     |   3 +
+ .../common/linux/khrn_client_platform_linux.c | 115 +++++++-
+ interface/khronos/common/linux/khrn_wayland.c | 215 +++++++++++++++
+ .../common/linux/khrn_wayland.h}              |  46 +---
+ interface/khronos/egl/egl_client.c            |  92 +++++--
+ interface/khronos/egl/egl_client_get_proc.c   |  11 +
+ interface/khronos/egl/egl_client_surface.c    |  42 ++-
+ interface/khronos/egl/egl_client_surface.h    |  38 ++-
+ interface/khronos/egl/egl_int_impl.h          |   2 +-
+ interface/khronos/ext/egl_wayland.c           | 246 ++++++++++++++++++
+ interface/khronos/include/EGL/eglext.h        |  23 ++
+ .../khronos/wayland-egl/wayland-egl-priv.h    |  53 ++++
+ interface/khronos/wayland-egl/wayland-egl.c   |  59 +++++
+ .../khronos/wayland-egl/wayland-egl.pc.in     |  10 +
+ interface/vmcs_host/CMakeLists.txt            |  21 +-
+ interface/vmcs_host/vc_dispmanx.h             |  10 +
+ interface/vmcs_host/vc_vchi_dispmanx.c        |  42 +++
+ interface/vmcs_host/vc_vchi_dispmanx.h        |  15 ++
+ interface/wayland/dispmanx.xml                | 123 +++++++++
+ makefiles/cmake/Wayland.cmake                 |  72 +++++
+ 30 files changed, 1257 insertions(+), 99 deletions(-)
+ create mode 100644 interface/khronos/common/linux/khrn_wayland.c
+ copy interface/{vmcs_host/vc_vchi_dispmanx.h => khronos/common/linux/khrn_wayland.h} (56%)
+ create mode 100644 interface/khronos/ext/egl_wayland.c
+ create mode 100644 interface/khronos/wayland-egl/wayland-egl-priv.h
+ create mode 100644 interface/khronos/wayland-egl/wayland-egl.c
+ create mode 100644 interface/khronos/wayland-egl/wayland-egl.pc.in
+ create mode 100644 interface/wayland/dispmanx.xml
+ create mode 100644 makefiles/cmake/Wayland.cmake
+
+diff --git a/.gitignore b/.gitignore
+index 63570f1..1459436 100644
+--- a/.gitignore
++++ b/.gitignore
+@@ -30,3 +30,4 @@ build/
+ *.pts
+ *.ppm
+ *.mkv
++*~
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index cfc8ae5..673a5ad 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -24,6 +24,17 @@ include(makefiles/cmake/global_settings.cmake)
+ include(makefiles/cmake/arm-linux.cmake)
+ include(makefiles/cmake/vmcs.cmake)
+ 
++if (BUILD_WAYLAND)
++   include(makefiles/cmake/Wayland.cmake)
++
++   # Find Wayland libraries
++   find_package(PkgConfig)
++   pkg_check_modules(WAYLAND_CLIENT wayland-client REQUIRED)
++   pkg_check_modules(WAYLAND_SERVER wayland-server REQUIRED)
++
++   set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DBUILD_WAYLAND")
++endif()
++
+ enable_language(ASM)
+ 
+ # Global include paths
+diff --git a/README.md b/README.md
+index 94b93b8..50b90b1 100644
+--- a/README.md
++++ b/README.md
+@@ -6,3 +6,7 @@ Use buildme to build. It requires cmake to be installed and an arm cross compile
+ https://github.com/raspberrypi/tools/tree/master/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian
+ 
+ Note that this repository does not contain the source for the edid_parser and vcdbg binaries due to licensing restrictions.
++
++To build support for the Wayland winsys in EGL, execute the buildme script like this:
++
++$ BUILD_WAYLAND=1 ./buildme.
+diff --git a/buildme b/buildme
+index b8fd440..a780bb6 100755
+--- a/buildme
++++ b/buildme
+@@ -8,6 +8,10 @@ fi
+ 
+ BUILDSUBDIR=`echo $BUILDTYPE | tr '[A-Z]' '[a-z]'`;
+ 
++if [ -n "$BUILD_WAYLAND" ]; then
++       WAYLAND_VARS="-DBUILD_WAYLAND=TRUE"
++fi
++
+ if [ "armv6l" = `arch` ] || [ "armv7l" = `arch` ]; then
+ 	# Native compile on the Raspberry Pi
+ 	mkdir -p build/raspberry/$BUILDSUBDIR
+@@ -32,9 +36,13 @@ elif [ "$1" = "--native" ]; then
+ 	make -j `nproc` $*
+ else
+ 	# Cross compile on a more capable machine
++	if [ -n "$BUILD_WAYLAND" ]; then
++		# Use wayland-scanner from the build platform
++		WAYLAND_VARS+=" -DWAYLAND_SCANNER_EXECUTABLE:FILEPATH=/usr/bin/wayland-scanner"
++	fi
+ 	mkdir -p build/arm-linux/$BUILDSUBDIR
+ 	pushd build/arm-linux/$BUILDSUBDIR
+-	cmake -DCMAKE_TOOLCHAIN_FILE=../../../makefiles/cmake/toolchains/arm-linux-gnueabihf.cmake -DCMAKE_BUILD_TYPE=$BUILDTYPE ../../..
++	cmake -DCMAKE_TOOLCHAIN_FILE=../../../makefiles/cmake/toolchains/arm-linux-gnueabihf.cmake -DCMAKE_BUILD_TYPE=$BUILDTYPE $WAYLAND_VARS ../../..
+ 	make -j `nproc`
+ 
+ 	if [ "$1" != "" ]; then
+diff --git a/host_applications/linux/apps/raspicam/CMakeLists.txt b/host_applications/linux/apps/raspicam/CMakeLists.txt
+index 42636e8..d47ad55 100644
+--- a/host_applications/linux/apps/raspicam/CMakeLists.txt
++++ b/host_applications/linux/apps/raspicam/CMakeLists.txt
+@@ -33,7 +33,7 @@ add_executable(raspividyuv  ${COMMON_SOURCES} RaspiVidYUV.c)
+ 
+ set (MMAL_LIBS mmal_core mmal_util mmal_vc_client)
+ 
+-target_link_libraries(raspistill ${MMAL_LIBS} vcos bcm_host brcmGLESv2 brcmEGL m dl)
++target_link_libraries(raspistill ${MMAL_LIBS} vcos bcm_host brcmGLESv2 brcmEGL m dl ${WAYLAND_SERVER_LIBRARIES} ${WAYLAND_CLIENT_LIBRARIES})
+ target_link_libraries(raspiyuv   ${MMAL_LIBS} vcos bcm_host)
+ target_link_libraries(raspivid   ${MMAL_LIBS} vcos bcm_host)
+ target_link_libraries(raspividyuv   ${MMAL_LIBS} vcos bcm_host)
+diff --git a/interface/khronos/CMakeLists.txt b/interface/khronos/CMakeLists.txt
+index 9ad615b..95c0e11 100644
+--- a/interface/khronos/CMakeLists.txt
++++ b/interface/khronos/CMakeLists.txt
+@@ -6,6 +6,12 @@
+ # have quite a few circular dependencies, and so the only way
+ # to make it work seems to be to have everything static.
+ 
++if (BUILD_WAYLAND)
++include_directories(
++   ${WAYLAND_SERVER_INCLUDE_DIRS}
++)
++endif ()
++
+ set(EGL_SOURCE
+    egl/egl_client_config.c
+    egl/egl_client_context.c
+@@ -55,12 +61,55 @@ set(CLIENT_SOURCE
+    common/khrn_int_hash_asm.s
+    common/khrn_client_cache.c)
+ 
++set(EGL_LIBS
++   khrn_client
++   vchiq_arm
++   vcos
++   bcm_host)
++
++if (BUILD_WAYLAND)
++   set(EGL_SOURCE
++      ${EGL_SOURCE}
++      ext/egl_wayland.c
++      common/linux/khrn_wayland.c)
++
++   set(EGL_LIBS
++      ${EGL_LIBS}
++      wayland-client
++      wayland-server)
++
++   set(WAYLAND_EGL_SOURCE
++      wayland-egl/wayland-egl.c)
++
++   wayland_add_protocol_server(
++       EGL_SOURCE
++       ../../interface/wayland/dispmanx.xml
++       dispmanx
++   )
++
++   wayland_add_protocol_client(
++       EGL_SOURCE
++       ../../interface/wayland/dispmanx.xml
++       dispmanx
++   )
++
++   add_library(wayland-egl ${SHARED} ${WAYLAND_EGL_SOURCE})
++   install(TARGETS wayland-egl DESTINATION lib)
++
++   configure_file ("wayland-egl/wayland-egl.pc.in" "wayland-egl/wayland-egl.pc" @ONLY)
++   install (FILES "${CMAKE_CURRENT_BINARY_DIR}/wayland-egl/wayland-egl.pc"
++            DESTINATION lib/pkgconfig)
++endif ()
++
+ add_library(EGL ${SHARED} ${EGL_SOURCE})
+ add_library(GLESv2 ${SHARED} ${GLES_SOURCE})
+ add_library(OpenVG ${SHARED} ${VG_SOURCE})
+ add_library(WFC ${SHARED} ${WFC_SOURCE})
+ add_library(khrn_client ${CLIENT_SOURCE})
+ 
++set_target_properties(EGL PROPERTIES SOVERSION 1 VERSION 1.0.0)
++set_target_properties(GLESv2 PROPERTIES SOVERSION 2 VERSION 2.0.0)
++
+ # TODO do we need EGL_static and GLESv2_static now that khrn_static exists?
+ add_library(EGL_static STATIC ${EGL_SOURCE})
+ add_library(GLESv2_static STATIC ${GLES_SOURCE})
+@@ -72,8 +121,7 @@ include_directories (../../host_applications/linux/libs/sm )
+ set(VCSM_LIBS vcsm)
+ add_definitions(-DKHRONOS_HAVE_VCSM)
+ endif()
+-
+-target_link_libraries(EGL khrn_client vchiq_arm vcos bcm_host ${VCSM_LIBS} -lm)
++target_link_libraries(EGL ${EGL_LIBS} ${VCSM_LIBS} -lm)
+ target_link_libraries(GLESv2 EGL khrn_client vcos)
+ target_link_libraries(WFC EGL)
+ target_link_libraries(OpenVG EGL)
+@@ -87,7 +135,7 @@ add_library(brcmGLESv2 ${SHARED} ${GLES_SOURCE})
+ add_library(brcmOpenVG ${SHARED} ${VG_SOURCE})
+ add_library(brcmWFC ${SHARED} ${WFC_SOURCE})
+ 
+-target_link_libraries(brcmEGL khrn_client vchiq_arm vcos bcm_host ${VCSM_LIBS} -lm)
++target_link_libraries(brcmEGL ${EGL_LIBS} ${VCSM_LIBS} -lm)
+ target_link_libraries(brcmGLESv2 brcmEGL khrn_client vcos)
+ target_link_libraries(brcmWFC brcmEGL)
+ target_link_libraries(brcmOpenVG brcmEGL)
+diff --git a/interface/khronos/common/khrn_client.c b/interface/khronos/common/khrn_client.c
+index ef4babd..d7e798e 100644
+--- a/interface/khronos/common/khrn_client.c
++++ b/interface/khronos/common/khrn_client.c
+@@ -54,6 +54,10 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ #include "applications/vmcs/khronos/khronos_server.h"
+ #endif
+ 
++#ifdef BUILD_WAYLAND
++#include "interface/khronos/common/linux/khrn_wayland.h"
++#endif
++
+ VCOS_LOG_CAT_T khrn_client_log = VCOS_LOG_INIT("khrn_client", VCOS_LOG_WARN);
+ 
+ /*
+@@ -142,6 +146,10 @@ void client_try_unload_server(CLIENT_PROCESS_STATE_T *process)
+ bool client_process_state_init(CLIENT_PROCESS_STATE_T *process)
+ {
+    if (!process->inited) {
++#ifdef BUILD_WAYLAND
++      process->wl_global = NULL;
++#endif
++
+       if (!khrn_pointer_map_init(&process->contexts, 64))
+          return false;
+ 
+@@ -194,6 +202,13 @@ bool client_process_state_init(CLIENT_PROCESS_STATE_T *process)
+       }
+ #endif
+ 
++#ifdef BUILD_WAYLAND
++      struct wl_display *wl_display = khrn_platform_get_wl_display();
++      if (wl_display)
++         if (!init_process_wayland(process))
++            return false;
++#endif
++
+       process->inited = true;
+    }
+ 
+diff --git a/interface/khronos/common/khrn_client.h b/interface/khronos/common/khrn_client.h
+index 804039b..615f7b4 100644
+--- a/interface/khronos/common/khrn_client.h
++++ b/interface/khronos/common/khrn_client.h
+@@ -310,6 +310,16 @@ struct CLIENT_PROCESS_STATE {
+ #ifdef RPC_LIBRARY
+    KHRONOS_SERVER_CONNECTION_T khrn_connection;
+ #endif
++
++#ifdef BUILD_WAYLAND
++   /* Client-side Wayland state */
++   struct wl_registry *wl_registry;
++   struct wl_dispmanx *wl_dispmanx;
++   struct wl_event_queue *wl_queue;
++
++   /* Compositor-side Wayland state */
++   struct wl_global *wl_global;
++#endif
+ };
+ 
+ extern bool client_process_state_init(CLIENT_PROCESS_STATE_T *process);
+diff --git a/interface/khronos/common/khrn_client_mangle.h b/interface/khronos/common/khrn_client_mangle.h
+index b3c04f4..b7b21c5 100644
+--- a/interface/khronos/common/khrn_client_mangle.h
++++ b/interface/khronos/common/khrn_client_mangle.h
+@@ -83,6 +83,9 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ #define eglReleaseGlobalImageBRCM mangled_eglReleaseGlobalImageBRCM
+ #define eglInitGlobalImageBRCM mangled_eglInitGlobalImageBRCM
+ #define eglTermGlobalImageBRCM mangled_eglTermGlobalImageBRCM
++#define eglBindWaylandDisplayWL mangled_eglBindWaylandDisplayWL
++#define eglUnbindWaylandDisplayWL mangled_eglUnbindWaylandDisplayWL
++#define eglQueryWaylandBufferWL mangled_eglQueryWaylandBufferWL
+ 
+ /* OpenGL ES 1.1 and 2.0 functions */
+ 
+diff --git a/interface/khronos/common/khrn_client_platform.h b/interface/khronos/common/khrn_client_platform.h
+index 1c9da3a..715c67e 100644
+--- a/interface/khronos/common/khrn_client_platform.h
++++ b/interface/khronos/common/khrn_client_platform.h
+@@ -48,6 +48,10 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ #include "interface/khronos/common/vcos/khrn_client_platform_filler_vcos.h"
+ #endif
+ 
++#ifdef BUILD_WAYLAND
++#include <wayland-client.h>
++#endif
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+@@ -328,4 +332,8 @@ typedef struct
+ 
+ void *platform_wfc_bounce_thread(void *param);
+ 
++#ifdef BUILD_WAYLAND
++struct wl_display *khrn_platform_get_wl_display();
++#endif
++
+ #endif // KHRN_CLIENT_PLATFORM_H
+diff --git a/interface/khronos/common/khrn_client_unmangle.h b/interface/khronos/common/khrn_client_unmangle.h
+index 4f3ce49..84f6ec0 100644
+--- a/interface/khronos/common/khrn_client_unmangle.h
++++ b/interface/khronos/common/khrn_client_unmangle.h
+@@ -83,6 +83,9 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ #undef eglReleaseGlobalImageBRCM
+ #undef eglInitGlobalImageBRCM
+ #undef eglTermGlobalImageBRCM
++#undef eglBindWaylandDisplayWL
++#undef eglUnbindWaylandDisplayWL
++#undef eglQueryWaylandBufferWL
+ 
+ /* OpenGL ES 1.1 and 2.0 functions */
+ 
+diff --git a/interface/khronos/common/linux/khrn_client_platform_linux.c b/interface/khronos/common/linux/khrn_client_platform_linux.c
+index 710d20f..50d60a6 100644
+--- a/interface/khronos/common/linux/khrn_client_platform_linux.c
++++ b/interface/khronos/common/linux/khrn_client_platform_linux.c
+@@ -37,6 +37,11 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ #include "X11/Xlib.h"
+ #endif
+ 
++#ifdef BUILD_WAYLAND
++#include <wayland-client.h>
++#include "interface/khronos/wayland-egl/wayland-egl-priv.h"
++#endif
++
+ extern VCOS_LOG_CAT_T khrn_client_log;
+ 
+ extern void vc_vchi_khronos_init();
+@@ -464,13 +469,36 @@ EGLDisplay khrn_platform_set_display_id(EGLNativeDisplayType display_id)
+ 	   return EGL_NO_DISPLAY;
+ }
+ #else
++
++#ifdef BUILD_WAYLAND
++static struct wl_display *hacky_display = NULL;
++#endif
++
+ EGLDisplay khrn_platform_set_display_id(EGLNativeDisplayType display_id)
+ {
+    if (display_id == EGL_DEFAULT_DISPLAY)
+       return (EGLDisplay)1;
+-   else
+-      return EGL_NO_DISPLAY;
++   else {
++#ifdef BUILD_WAYLAND
++      void *first_pointer = *(void **) display_id;
++
++      /* wl_display is a wl_proxy, which is a wl_object.
++       * wl_object's first element points to the interfacetype. */
++      if (first_pointer == &wl_display_interface) {
++         hacky_display = (struct wl_display*)display_id;
++         return (EGLDisplay)1;
++      } else
++#endif
++         return EGL_NO_DISPLAY;
++   }
+ }
++
++#ifdef BUILD_WAYLAND
++struct wl_display *khrn_platform_get_wl_display()
++{
++   return hacky_display;
++}
++#endif
+ #endif
+ 
+ #ifdef WANT_X
+@@ -805,22 +833,81 @@ static EGL_DISPMANX_WINDOW_T *check_default(EGLNativeWindowType win)
+ void platform_get_dimensions(EGLDisplay dpy, EGLNativeWindowType win,
+       uint32_t *width, uint32_t *height, uint32_t *swapchain_count)
+ {
+-   EGL_DISPMANX_WINDOW_T *dwin = check_default(win);
+-   vcos_assert(dwin);
+-   vcos_assert(dwin->width < 1<<16); // sanity check
+-   vcos_assert(dwin->height < 1<<16); // sanity check
+-   *width = dwin->width;
+-   *height = dwin->height;
+-   *swapchain_count = 0;
++#ifdef BUILD_WAYLAND
++   if(khrn_platform_get_wl_display()) {
++      struct wl_egl_window *wl_egl_window = (struct wl_egl_window*)win;
++      *width = wl_egl_window->width;
++      *height = wl_egl_window->height;
++      /* This seems to be used for sync'ing with the VC on buffer creation, but
++         we are managing them on the CPU side */
++      *swapchain_count = 1;
++   } else {
++#endif
++      EGL_DISPMANX_WINDOW_T *dwin = check_default(win);
++      vcos_assert(dwin);
++      vcos_assert(dwin->width < 1<<16); // sanity check
++      vcos_assert(dwin->height < 1<<16); // sanity check
++      *width = dwin->width;
++      *height = dwin->height;
++      *swapchain_count = 0;
++#ifdef BUILD_WAYLAND
++   }
++#endif
+ }
+ 
++#ifdef BUILD_WAYLAND
++static DISPMANX_ELEMENT_HANDLE_T create_dummy_element()
++{
++   DISPMANX_DISPLAY_HANDLE_T display = vc_dispmanx_display_open(0);
++   DISPMANX_UPDATE_HANDLE_T update = vc_dispmanx_update_start(0);
++   DISPMANX_ELEMENT_HANDLE_T element;
++   VC_DISPMANX_ALPHA_T alpha = {DISPMANX_FLAGS_ALPHA_FIXED_ALL_PIXELS, 255, 0};
++   VC_RECT_T src_rect;
++   VC_RECT_T dst_rect;
++
++   src_rect.x = 0;
++   src_rect.y = 0;
++   src_rect.width = 1 << 16;
++   src_rect.height = 1 << 16;
++
++   dst_rect.x = 0;
++   dst_rect.y = 0;
++   dst_rect.width = 1;
++   dst_rect.height = 1;
++
++   element = vc_dispmanx_element_add(update, display, 0/*layer*/, &dst_rect,
++                                     0/*src*/, &src_rect,
++                                     DISPMANX_PROTECTION_NONE, &alpha,
++                                     0/*clamp*/, 0/*transform*/);
++
++   vc_dispmanx_update_submit_sync(update);
++
++   vc_dispmanx_display_close(display);
++
++   return element;
++}
++#endif
++
+ uint32_t platform_get_handle(EGLDisplay dpy, EGLNativeWindowType win)
+ {
+-   EGL_DISPMANX_WINDOW_T *dwin = check_default(win);
+-   vcos_assert(dwin);
+-   vcos_assert(dwin->width < 1<<16); // sanity check
+-   vcos_assert(dwin->height < 1<<16); // sanity check
+-   return dwin->element;
++#ifdef BUILD_WAYLAND
++   if(khrn_platform_get_wl_display()) {
++      struct wl_egl_window *wl_egl_window = (struct wl_egl_window*)win;
++
++      if (wl_egl_window->dummy_element == PLATFORM_WIN_NONE)
++         wl_egl_window->dummy_element = create_dummy_element();
++
++      return wl_egl_window->dummy_element;
++   } else {
++#endif
++      EGL_DISPMANX_WINDOW_T *dwin = check_default(win);
++      vcos_assert(dwin);
++      vcos_assert(dwin->width < 1<<16); // sanity check
++      vcos_assert(dwin->height < 1<<16); // sanity check
++      return dwin->element;
++#ifdef BUILD_WAYLAND
++   }
++#endif
+ }
+ 
+ #endif
+diff --git a/interface/khronos/common/linux/khrn_wayland.c b/interface/khronos/common/linux/khrn_wayland.c
+new file mode 100644
+index 0000000..0e1b9e7
+--- /dev/null
++++ b/interface/khronos/common/linux/khrn_wayland.c
+@@ -0,0 +1,215 @@
++/*
++Copyright (c) 2013, Raspberry Pi Foundation
++All rights reserved.
++
++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 copyright holder 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 HOLDER 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.
++*/
++
++#define VCOS_LOG_CATEGORY (&khrn_client_log)
++
++#include "interface/khronos/common/linux/khrn_wayland.h"
++#include "interface/khronos/wayland-dispmanx-client-protocol.h"
++#include "interface/khronos/wayland-egl/wayland-egl-priv.h"
++
++extern VCOS_LOG_CAT_T khrn_client_log;
++
++static void handle_dispmanx_format(void *data, struct wl_dispmanx *dispmanx,
++                                   uint32_t format)
++{
++}
++
++static void handle_dispmanx_allocated(void *data, struct wl_dispmanx *dispmanx,
++                                      struct wl_buffer *wl_buffer,
++                                      uint32_t resource_handle)
++{
++    struct wl_dispmanx_client_buffer *buffer = wl_buffer_get_user_data(wl_buffer);
++
++    buffer->pending_allocation = 0;
++    buffer->resource = resource_handle;
++}
++
++static const struct wl_dispmanx_listener dispmanx_listener = {
++    handle_dispmanx_format,
++    handle_dispmanx_allocated,
++};
++
++static void
++sync_callback(void *data, struct wl_callback *callback, uint32_t serial)
++{
++   int *done = data;
++
++   *done = 1;
++
++   wl_callback_destroy(callback);
++}
++
++static const struct wl_callback_listener sync_listener = {
++   sync_callback
++};
++
++static int
++roundtrip(CLIENT_PROCESS_STATE_T *process)
++{
++   struct wl_display *wl_display = khrn_platform_get_wl_display();
++   struct wl_callback *callback;
++   int done = 0, ret = 0;
++
++   callback = wl_display_sync(wl_display);
++   wl_callback_add_listener(callback, &sync_listener, &done);
++   wl_proxy_set_queue((struct wl_proxy *) callback, process->wl_queue);
++   while (ret != -1 && !done)
++      ret = wl_display_dispatch_queue(wl_display, process->wl_queue);
++
++   if (!done)
++      wl_callback_destroy(callback);
++
++   return ret;
++}
++
++int do_wl_roundtrip()
++{
++   CLIENT_PROCESS_STATE_T *process = CLIENT_GET_PROCESS_STATE();
++   return roundtrip(process);
++}
++
++static void
++registry_handle_global(void *data, struct wl_registry *registry,
++                       uint32_t name, const char *interface, uint32_t version)
++{
++   struct wl_display *wl_display = khrn_platform_get_wl_display();
++   CLIENT_PROCESS_STATE_T *process = (CLIENT_PROCESS_STATE_T *)data;
++
++   if (strcmp(interface, "wl_dispmanx") == 0) {
++      process->wl_dispmanx = wl_registry_bind(registry, name,
++	       &wl_dispmanx_interface, 1);
++
++      wl_proxy_set_queue((struct wl_proxy *) process->wl_dispmanx,
++                         process->wl_queue);
++      wl_dispmanx_add_listener(process->wl_dispmanx, &dispmanx_listener, wl_display);
++      roundtrip(process);
++   }
++}
++
++static void
++registry_handle_global_remove(void *data, struct wl_registry *registry,
++                              uint32_t name)
++{
++}
++
++static const struct wl_registry_listener registry_listener = {
++	registry_handle_global,
++	registry_handle_global_remove
++};
++
++int
++init_process_wayland(CLIENT_PROCESS_STATE_T *process)
++{
++    struct wl_display *wl_display = khrn_platform_get_wl_display();
++
++    process->wl_queue = wl_display_create_queue(wl_display);
++    if (!process->wl_queue) {
++        vcos_log_error("wl_display_create_queue failed\n");
++        return false;
++    }
++    wl_display_dispatch_pending(wl_display);
++
++    process->wl_registry = wl_display_get_registry(wl_display);
++    if (!process->wl_registry) {
++        vcos_log_error("wl_display_get_registry failed\n");
++        return false;
++    }
++
++    wl_proxy_set_queue((struct wl_proxy *) process->wl_registry,
++    process->wl_queue);
++
++    wl_registry_add_listener(process->wl_registry, &registry_listener, process);
++
++    if (roundtrip(process) < 0 || process->wl_dispmanx == NULL) {
++        vcos_log_error("failed to get wl_dispmanx\n");
++        return false;
++    }
++
++    return true;
++}
++
++#ifndef ALIGN_UP
++#define ALIGN_UP(x,y)  ((x + (y)-1) & ~((y)-1))
++#endif
++
++static void handle_buffer_release(void *data, struct wl_buffer *buffer_wl)
++{
++   struct wl_dispmanx_client_buffer *wl_dispmanx_client_buffer = data;
++   wl_dispmanx_client_buffer->in_use = 0;
++}
++
++static const struct wl_buffer_listener buffer_listener = {
++   handle_buffer_release
++};
++
++struct wl_dispmanx_client_buffer *
++allocate_wl_buffer(struct wl_egl_window *window, KHRN_IMAGE_FORMAT_T color)
++{
++   CLIENT_PROCESS_STATE_T *process = CLIENT_GET_PROCESS_STATE();
++   struct wl_dispmanx_client_buffer *wl_dispmanx_client_buffer;
++   struct wl_buffer *wl_buffer;
++   uint32_t stride = ALIGN_UP(window->width * 4, 16);
++   uint32_t buffer_height = ALIGN_UP(window->height, 16);
++   enum wl_dispmanx_format color_format;
++   int ret = 0;
++
++   switch (color) {
++   case ABGR_8888:
++      color_format = WL_DISPMANX_FORMAT_ABGR8888;
++      break;
++   case XBGR_8888:
++      color_format = WL_DISPMANX_FORMAT_XBGR8888;
++      break;
++   case RGB_565:
++      color_format = WL_DISPMANX_FORMAT_RGB565;
++      break;
++   default:
++      vcos_log_error("unknown KHRN_IMAGE_FORMAT_T 0x%x\n", color);
++      return NULL;
++   }
++
++   wl_buffer = wl_dispmanx_create_buffer(process->wl_dispmanx, window->width,
++                                         window->height, stride, buffer_height,
++                                         color_format);
++   if (wl_buffer == NULL)
++      return NULL;
++
++   wl_dispmanx_client_buffer = calloc(1, sizeof(struct wl_dispmanx_client_buffer));
++   wl_dispmanx_client_buffer->wl_buffer = wl_buffer;
++   wl_dispmanx_client_buffer->in_use = 0;
++   wl_dispmanx_client_buffer->pending_allocation = 1;
++   wl_dispmanx_client_buffer->width = window->width;
++   wl_dispmanx_client_buffer->height = window->height;
++
++   wl_proxy_set_queue((struct wl_proxy *) wl_buffer, process->wl_queue);
++   wl_buffer_add_listener(wl_buffer, &buffer_listener, wl_dispmanx_client_buffer);
++
++   while (ret != -1 && wl_dispmanx_client_buffer->pending_allocation)
++      ret = do_wl_roundtrip();
++
++   return wl_dispmanx_client_buffer;
++}
+diff --git a/interface/vmcs_host/vc_vchi_dispmanx.h b/interface/khronos/common/linux/khrn_wayland.h
+similarity index 56%
+copy from interface/vmcs_host/vc_vchi_dispmanx.h
+copy to interface/khronos/common/linux/khrn_wayland.h
+index b723b76..b9bf08c 100644
+--- a/interface/vmcs_host/vc_vchi_dispmanx.h
++++ b/interface/khronos/common/linux/khrn_wayland.h
+@@ -1,5 +1,5 @@
+ /*
+-Copyright (c) 2012, Broadcom Europe Ltd
++Copyright (c) 2013, Raspberry Pi Foundation
+ All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+@@ -25,45 +25,9 @@ ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+ 
+-#ifndef VC_VCHI_DISPMANX_H
+-#define VC_VCHI_DISPMANX_H
++#include "interface/khronos/common/khrn_client.h"
+ 
+-#include "interface/peer/vc_vchi_dispmanx_common.h"
++int init_process_wayland(CLIENT_PROCESS_STATE_T *process);
++int do_wl_roundtrip();
+ 
+-#define VC_NUM_HOST_RESOURCES 64
+-#define DISPMANX_MSGFIFO_SIZE 1024
+-#define DISPMANX_CLIENT_NAME MAKE_FOURCC("DISP")
+-#define DISPMANX_NOTIFY_NAME MAKE_FOURCC("UPDH")
+-
+-//Or with command to indicate we don't need a response
+-#define DISPMANX_NO_REPLY_MASK (1<<31)
+-
+-typedef struct {
+-   char     description[32];
+-   uint32_t width;
+-   uint32_t height;
+-   uint32_t aspect_pixwidth;
+-   uint32_t aspect_pixheight;
+-   uint32_t fieldrate_num;
+-   uint32_t fieldrate_denom;
+-   uint32_t fields_per_frame;
+-   uint32_t transform;        
+-} GET_MODES_DATA_T;
+-
+-typedef struct {
+-   int32_t  response;
+-   uint32_t width;
+-   uint32_t height;
+-   uint32_t transform;
+-   uint32_t input_format;
+-} GET_INFO_DATA_T;
+-
+-//Attributes changes flag mask
+-#define ELEMENT_CHANGE_LAYER          (1<<0)
+-#define ELEMENT_CHANGE_OPACITY        (1<<1)
+-#define ELEMENT_CHANGE_DEST_RECT      (1<<2)
+-#define ELEMENT_CHANGE_SRC_RECT       (1<<3)
+-#define ELEMENT_CHANGE_MASK_RESOURCE  (1<<4)
+-#define ELEMENT_CHANGE_TRANSFORM      (1<<5)
+-
+-#endif
++struct wl_dispmanx_client_buffer *allocate_wl_buffer(struct wl_egl_window *window, KHRN_IMAGE_FORMAT_T color);
+diff --git a/interface/khronos/egl/egl_client.c b/interface/khronos/egl/egl_client.c
+index b8bb374..03fe67b 100644
+--- a/interface/khronos/egl/egl_client.c
++++ b/interface/khronos/egl/egl_client.c
+@@ -153,6 +153,10 @@ by an attribute value"
+ #include <stdlib.h>
+ #include <string.h>
+ 
++#ifdef BUILD_WAYLAND
++#include "interface/khronos/wayland-egl/wayland-egl-priv.h"
++#include "interface/khronos/common/linux/khrn_wayland.h"
++#endif
+ 
+ #include "interface/khronos/egl/egl_client_cr.c"
+ 
+@@ -162,17 +166,6 @@ static void egl_current_release(CLIENT_PROCESS_STATE_T *process, EGL_CURRENT_T *
+ void egl_gl_flush_callback(bool wait);
+ void egl_vg_flush_callback(bool wait);
+ 
+-#include "interface/vmcs_host/vc_dispmanx_types.h"
+-/**HACKHACK - give us the ability to inject a DispmanX 
+- * resource handle into the CreateWindowSurface and 
+- * SwapBuffers calls */ 
+-static DISPMANX_RESOURCE_HANDLE_T next_resource_handle;
+-
+-EGLAPI EGLBoolean EGLAPIENTRY eglSetNextResourceHandle(DISPMANX_RESOURCE_HANDLE_T handle)
+-{
+-   next_resource_handle = handle;
+-}
+-
+ /*
+ TODO: do an RPC call to make sure the Khronos vll is loaded (and that it stays loaded until eglTerminate)
+ Also affects global image (and possibly others?)
+@@ -450,6 +443,9 @@ EGLAPI const char EGLAPIENTRY * eglQueryString(EGLDisplay dpy, EGLint name)
+ #ifdef EGL_KHR_fence_sync
+             "EGL_KHR_fence_sync "
+ #endif
++#endif
++#if EGL_WL_bind_wayland_display
++            "EGL_WL_bind_wayland_display "
+ #endif
+             ;
+          break;
+@@ -655,8 +651,7 @@ EGLAPI EGLSurface EGLAPIENTRY eglCreateWindowSurface(EGLDisplay dpy, EGLConfig c
+                                 false,
+                                 EGL_NO_TEXTURE,
+                                 EGL_NO_TEXTURE,
+-                                0, 0,
+-                                next_resource_handle);
++                                0, 0);
+ 
+                if (surface) {
+                   if (khrn_pointer_map_insert(&process->surfaces, process->next_surface, surface)) {
+@@ -901,7 +896,7 @@ EGLAPI EGLSurface EGLAPIENTRY eglCreatePbufferSurface(EGLDisplay dpy, EGLConfig
+                              mipmap_texture,
+                              texture_format,
+                              texture_target,
+-                             0, 0, 0);
++                             0, 0);
+ 
+             if (surface) {
+                if (khrn_pointer_map_insert(&process->surfaces, process->next_surface, surface)) {
+@@ -1043,7 +1038,7 @@ EGLAPI EGLSurface EGLAPIENTRY eglCreatePixmapSurface(EGLDisplay dpy, EGLConfig c
+                                    false,
+                                    EGL_NO_TEXTURE,
+                                    EGL_NO_TEXTURE,
+-                                   pixmap, ((server_handle[0] == 0) && (server_handle[1] == (uint32_t)(-1))) ? NULL : server_handle, 0);
++                                   pixmap, ((server_handle[0] == 0) && (server_handle[1] == (uint32_t)(-1))) ? NULL : server_handle);
+ 
+                      if (surface) {
+                         if (khrn_pointer_map_insert(&process->surfaces, process->next_surface, surface)) {
+@@ -2245,6 +2240,9 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+    CLIENT_THREAD_STATE_T *thread;
+    CLIENT_PROCESS_STATE_T *process;
+    EGLBoolean result;
++#ifdef BUILD_WAYLAND
++   struct wl_display *wl_display = khrn_platform_get_wl_display();
++#endif
+ 
+    vcos_log_trace("eglSwapBuffers start. dpy=%d. surf=%d.", (int)dpy, (int)surf);
+ 
+@@ -2315,18 +2313,58 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+ 
+                vcos_log_trace("eglSwapBuffers server call");
+ 
+-               if (next_resource_handle)
+-               RPC_CALL7(eglIntSwapBuffers_impl,
+-                     thread,
+-                     EGLINTSWAPBUFFERS_ID_V2,
+-                     RPC_UINT(surface->serverbuffer),
+-                     RPC_UINT(surface->width),
+-                     RPC_UINT(surface->height),
+-                     RPC_UINT(surface->internal_handle),
+-                     RPC_UINT(surface->swap_behavior == EGL_BUFFER_PRESERVED ? 1 : 0),
+-                     RPC_UINT(khrn_platform_get_window_position(surface->win)),
+-                     RPC_INT(next_resource_handle));
+-               else
++#ifdef BUILD_WAYLAND
++               if (wl_display) {
++                  struct wl_egl_window *wl_egl_window = surface->wl_egl_window;
++                  struct wl_dispmanx_client_buffer *buffer_temp;
++                  uint32_t configid;
++                  KHRN_IMAGE_FORMAT_T color;
++                  int ret = 0;
++
++                  buffer_temp = surface->front_wl_buffer;
++                  surface->front_wl_buffer = surface->back_wl_buffer;
++                  surface->back_wl_buffer = buffer_temp;
++
++                  configid = egl_config_to_id(surface->config);
++                  color = egl_config_get_color_format(configid);
++
++                  if (surface->back_wl_buffer == NULL)
++                     surface->back_wl_buffer = allocate_wl_buffer(wl_egl_window, color);
++                  else if (surface->back_wl_buffer->width != width ||
++                           surface->back_wl_buffer->height != height) {
++
++                     struct wl_dispmanx_client_buffer *buffer;
++
++                     wl_buffer_destroy(surface->back_wl_buffer->wl_buffer);
++                     free(surface->back_wl_buffer);
++
++                     buffer = allocate_wl_buffer(wl_egl_window, color);
++                     surface->back_wl_buffer = buffer;
++                  }
++
++                  RPC_CALL7(eglIntSwapBuffers_impl,
++                        thread,
++                        EGLINTSWAPBUFFERS_ID_V2,
++                        RPC_UINT(surface->serverbuffer),
++                        RPC_UINT(surface->width),
++                        RPC_UINT(surface->height),
++                        RPC_UINT(surface->internal_handle),
++                        RPC_UINT(surface->swap_behavior == EGL_BUFFER_PRESERVED ? 1 : 0),
++                        RPC_UINT(khrn_platform_get_window_position(surface->win)),
++                        RPC_INT(surface->back_wl_buffer->resource));
++
++                  surface->front_wl_buffer->in_use = 1;
++                  wl_surface_attach(wl_egl_window->wl_surface,
++                                    surface->front_wl_buffer->wl_buffer,
++                                    0, 0);
++                  wl_surface_damage(wl_egl_window->wl_surface, 0, 0,
++                                    surface->width, surface->height);
++                  wl_surface_commit(wl_egl_window->wl_surface);
++
++                  while(ret != -1 && surface->back_wl_buffer->in_use)
++                     ret = wl_display_dispatch_queue(wl_display, process->wl_queue);
++               } else
++#endif
+                RPC_CALL6(eglIntSwapBuffers_impl,
+                      thread,
+                      EGLINTSWAPBUFFERS_ID,
+diff --git a/interface/khronos/egl/egl_client_get_proc.c b/interface/khronos/egl/egl_client_get_proc.c
+index 4cfa9ff..6a715af 100644
+--- a/interface/khronos/egl/egl_client_get_proc.c
++++ b/interface/khronos/egl/egl_client_get_proc.c
+@@ -254,6 +254,17 @@ EGLAPI void EGLAPIENTRY (* eglGetProcAddress(const char *procname))(void)
+       return (void(*)(void))eglQueryGlobalImageBRCM;
+ #endif
+ 
++#ifdef BUILD_WAYLAND
++#if EGL_WL_bind_wayland_display
++   if (!strcmp(procname, "eglBindWaylandDisplayWL"))
++      return (void(*)(void))eglBindWaylandDisplayWL;
++   if (!strcmp(procname, "eglUnbindWaylandDisplayWL"))
++      return (void(*)(void))eglUnbindWaylandDisplayWL;
++   if (!strcmp(procname, "eglQueryWaylandBufferWL"))
++      return (void(*)(void))eglQueryWaylandBufferWL;
++#endif
++#endif
++
+    return (void(*)(void)) NULL;
+ }
+ 
+diff --git a/interface/khronos/egl/egl_client_surface.c b/interface/khronos/egl/egl_client_surface.c
+index 128325e..42350bf 100644
+--- a/interface/khronos/egl/egl_client_surface.c
++++ b/interface/khronos/egl/egl_client_surface.c
+@@ -46,6 +46,11 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ #include "interface/khronos/egl/egl_int_impl.h"
+ #endif
+ 
++#ifdef BUILD_WAYLAND
++#include "interface/khronos/wayland-egl/wayland-egl-priv.h"
++#include "interface/khronos/common/linux/khrn_wayland.h"
++#endif
++
+ #include <stdlib.h>
+ 
+ 
+@@ -314,8 +319,7 @@ EGL_SURFACE_T *egl_surface_create(
+    EGLenum texture_format,
+    EGLenum texture_target,
+    EGLNativePixmapType pixmap,
+-   const uint32_t *pixmap_server_handle,
+-   DISPMANX_RESOURCE_HANDLE_T next_resource_handle)
++   const uint32_t *pixmap_server_handle)
+ {
+    KHRN_IMAGE_FORMAT_T color;
+    KHRN_IMAGE_FORMAT_T depth;
+@@ -326,6 +330,10 @@ EGL_SURFACE_T *egl_surface_create(
+    EGLint   config_depth_bits;
+    EGLint   config_stencil_bits;
+    CLIENT_THREAD_STATE_T *thread = CLIENT_GET_THREAD_STATE();
++#ifdef BUILD_WAYLAND
++   struct wl_display *wl_display = khrn_platform_get_wl_display();
++   DISPMANX_RESOURCE_HANDLE_T resource;
++#endif
+ 
+    EGL_SURFACE_T *surface = egl_surface_pool_alloc();
+ 
+@@ -390,6 +398,18 @@ EGL_SURFACE_T *egl_surface_create(
+ 
+    vcos_assert(color != IMAGE_FORMAT_INVALID);
+ 
++#ifdef BUILD_WAYLAND
++   if (type == WINDOW && wl_display) {
++      surface->wl_egl_window = (struct wl_egl_window*)win;
++      surface->back_wl_buffer = allocate_wl_buffer(
++            surface->wl_egl_window, color);
++      resource = surface->back_wl_buffer->resource;
++   } else {
++      surface->wl_egl_window = NULL;
++      resource = DISPMANX_NO_HANDLE;
++   }
++#endif
++
+ #ifdef KHRONOS_EGL_PLATFORM_OPENWFC
+    // Create stream for this window
+    if(type != PBUFFER)
+@@ -474,7 +494,8 @@ EGL_SURFACE_T *egl_surface_create(
+ #endif
+          uint32_t results[3];
+ 
+-         if (next_resource_handle)
++#ifdef BUILD_WAYLAND
++         if (resource != DISPMANX_NO_HANDLE)
+          RPC_CALL16_OUT_CTRL(eglIntCreateSurface_impl,
+                              thread,
+                              EGLINTCREATESURFACE_ID_V2,
+@@ -492,9 +513,10 @@ EGL_SURFACE_T *egl_surface_create(
+                              RPC_UINT(config_stencil_bits),
+                              RPC_UINT(sem_name),
+                              RPC_UINT(type),
+-                             RPC_INT(next_resource_handle),
++                             RPC_INT(resource),
+                              results);
+          else
++#endif
+          RPC_CALL15_OUT_CTRL(eglIntCreateSurface_impl,
+                              thread,
+                              EGLINTCREATESURFACE_ID,
+@@ -663,6 +685,18 @@ void egl_surface_free(EGL_SURFACE_T *surface)
+    if( surface->type == WINDOW ) {
+       vcos_log_trace("egl_surface_free: calling platform_destroy_winhandle...");
+       platform_destroy_winhandle( surface->win, surface->internal_handle );
++
++#ifdef BUILD_WAYLAND
++      if (surface->back_wl_buffer) {
++         wl_buffer_destroy(surface->back_wl_buffer->wl_buffer);
++         free(surface->back_wl_buffer);
++      }
++
++      if (surface->front_wl_buffer) {
++         wl_buffer_destroy(surface->front_wl_buffer->wl_buffer);
++         free(surface->front_wl_buffer);
++      }
++#endif
+    }
+    /* return value ignored -- read performed to ensure blocking. we want this to
+     * block so clients can safely destroy the surface's window as soon as the
+diff --git a/interface/khronos/egl/egl_client_surface.h b/interface/khronos/egl/egl_client_surface.h
+index b5bf70a..e328b77 100644
+--- a/interface/khronos/egl/egl_client_surface.h
++++ b/interface/khronos/egl/egl_client_surface.h
+@@ -288,6 +288,41 @@ typedef struct {
+       type == PIXMAP
+    */
+    bool server_owned;
++
++#ifdef BUILD_WAYLAND
++   /*
++      wl_egl_window
++
++      Validity:
++      type == WINDOW
++
++      Invariant:
++      wayland EGL window
++   */
++   struct wl_egl_window *wl_egl_window;
++
++   /*
++      front_wl_buffer
++
++      Validity:
++      type == WINDOW
++
++      Invariant:
++      client-side information about the wl_buffer in the front
++   */
++   struct wl_dispmanx_client_buffer *front_wl_buffer;
++
++   /*
++      back_wl_buffer
++
++      Validity:
++      type == WINDOW
++
++      Invariant:
++      client-side information about the wl_buffer in the back
++   */
++   struct wl_dispmanx_client_buffer *back_wl_buffer;
++#endif
+ } EGL_SURFACE_T;
+ 
+ extern bool egl_surface_check_attribs(
+@@ -322,8 +357,7 @@ extern EGL_SURFACE_T *egl_surface_create(
+    EGLenum texture_format,
+    EGLenum texture_target,
+    EGLNativePixmapType pixmap,
+-   const uint32_t *pixmap_server_handle,
+-   DISPMANX_RESOURCE_HANDLE_T next_resource_handle);
++   const uint32_t *pixmap_server_handle);
+ extern EGL_SURFACE_T *egl_surface_from_vg_image(
+    VGImage vg_handle,
+    EGLSurface name,
+diff --git a/interface/khronos/egl/egl_int_impl.h b/interface/khronos/egl/egl_int_impl.h
+index 51b3580..6863a3b 100644
+--- a/interface/khronos/egl/egl_int_impl.h
++++ b/interface/khronos/egl/egl_int_impl.h
+@@ -57,7 +57,7 @@ FN(int, eglIntCreateSurface_impl, (
+    uint32_t sem,
+    uint32_t type,
+    uint32_t *results,
+-   DISPMANX_RESOURCE_HANDLE_T next_resource_handle))
++   DISPMANX_RESOURCE_HANDLE_T resource_handle))
+ 
+ FN(int, eglIntCreatePbufferFromVGImage_impl, (
+    VGImage vg_handle,
+diff --git a/interface/khronos/ext/egl_wayland.c b/interface/khronos/ext/egl_wayland.c
+new file mode 100644
+index 0000000..5730743
+--- /dev/null
++++ b/interface/khronos/ext/egl_wayland.c
+@@ -0,0 +1,246 @@
++/*
++Copyright (c) 2013, Raspberry Pi Foundation
++All rights reserved.
++
++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 copyright holder 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 HOLDER 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.
++*/
++
++#include "interface/khronos/common/khrn_client_mangle.h"
++#include "interface/khronos/common/khrn_client_rpc.h"
++
++#include "interface/khronos/ext/egl_khr_sync_client.h"
++#include "interface/khronos/include/EGL/egl.h"
++#include "interface/khronos/include/EGL/eglext.h"
++
++#include "interface/vmcs_host/vc_vchi_dispmanx.h"
++
++#include <wayland-server.h>
++#include "interface/khronos/wayland-dispmanx-server-protocol.h"
++
++static void
++destroy_buffer(struct wl_resource *resource)
++{
++   struct wl_dispmanx_server_buffer *buffer = wl_resource_get_user_data(resource);
++
++   if(!buffer->in_use)
++      vc_dispmanx_resource_delete(buffer->handle);
++
++   free(buffer);
++}
++
++static void
++buffer_destroy(struct wl_client *client, struct wl_resource *resource)
++{
++   wl_resource_destroy(resource);
++}
++
++static const struct wl_buffer_interface dispmanx_buffer_interface = {
++   buffer_destroy
++};
++
++static VC_IMAGE_TYPE_T
++get_vc_format(enum wl_dispmanx_format format)
++{
++	/* XXX: The app is likely to have been premultiplying in its shaders,
++	 * but the VC scanout hardware on the RPi cannot mix premultiplied alpha
++	 * channel with the element's alpha.
++	 */
++	switch (format) {
++	case WL_DISPMANX_FORMAT_ABGR8888:
++		return VC_IMAGE_RGBA32;
++	case WL_DISPMANX_FORMAT_XBGR8888:
++		return VC_IMAGE_BGRX8888;
++	case WL_DISPMANX_FORMAT_RGB565:
++		return VC_IMAGE_RGB565;
++	default:
++		/* invalid format */
++		return VC_IMAGE_MIN;
++	}
++}
++
++static void
++dispmanx_create_buffer(struct wl_client *client, struct wl_resource *resource,
++                       uint32_t id, int32_t width, int32_t height,
++                       uint32_t stride, uint32_t buffer_height, uint32_t format)
++{
++   struct wl_dispmanx_server_buffer *buffer;
++   VC_IMAGE_TYPE_T vc_format = get_vc_format(format);
++   uint32_t dummy;
++
++   if(vc_format == VC_IMAGE_MIN) {
++      wl_resource_post_error(resource,
++                             WL_DISPMANX_ERROR_INVALID_FORMAT,
++                             "invalid format");
++      return;
++   }
++
++   buffer = calloc(1, sizeof *buffer);
++   if (buffer == NULL) {
++      wl_resource_post_no_memory(resource);
++      return;
++   }
++
++   buffer->handle = vc_dispmanx_resource_create(vc_format,
++                                                width | (stride << 16),
++                                                height | (buffer_height << 16),
++                                                &dummy);
++   if(buffer->handle == DISPMANX_NO_HANDLE) {
++      wl_resource_post_error(resource,
++                             WL_DISPMANX_ERROR_ALLOC_FAILED,
++                             "allocation failed");
++      free(buffer);
++      return;
++   }
++
++   buffer->width = width;
++   buffer->height = height;
++   buffer->format = format;
++
++   buffer->resource = wl_resource_create(resource->client, &wl_buffer_interface,
++                                         1, id);
++   if (!buffer->resource) {
++      wl_resource_post_no_memory(resource);
++      vc_dispmanx_resource_delete(buffer->handle);
++      free(buffer);
++      return;
++   }
++
++   wl_resource_set_implementation(buffer->resource,
++				       (void (**)(void)) &dispmanx_buffer_interface,
++				       buffer, destroy_buffer);
++
++   wl_dispmanx_send_buffer_allocated(resource, buffer->resource,
++                                     buffer->handle);
++}
++
++static const struct wl_dispmanx_interface dispmanx_interface = {
++   dispmanx_create_buffer,
++};
++
++static void
++bind_dispmanx(struct wl_client *client, void *data, uint32_t version, uint32_t id)
++{
++   struct wl_resource *resource;
++
++   resource = wl_resource_create(client, &wl_dispmanx_interface, 1, id);
++   wl_resource_set_implementation(resource, &dispmanx_interface, NULL, NULL);
++
++   wl_resource_post_event(resource, WL_DISPMANX_FORMAT,
++                          WL_DISPMANX_FORMAT_ARGB8888);
++
++   wl_resource_post_event(resource, WL_DISPMANX_FORMAT,
++                          WL_DISPMANX_FORMAT_XRGB8888);
++
++   wl_resource_post_event(resource, WL_DISPMANX_FORMAT,
++                          WL_DISPMANX_FORMAT_ABGR8888);
++
++   wl_resource_post_event(resource, WL_DISPMANX_FORMAT,
++                          WL_DISPMANX_FORMAT_XBGR8888);
++
++   wl_resource_post_event(resource, WL_DISPMANX_FORMAT,
++                          WL_DISPMANX_FORMAT_RGB565);
++}
++
++EGLBoolean EGLAPIENTRY
++eglBindWaylandDisplayWL(EGLDisplay dpy, struct wl_display *display)
++{
++   CLIENT_THREAD_STATE_T *thread;
++   CLIENT_PROCESS_STATE_T *process;
++
++   if (!CLIENT_LOCK_AND_GET_STATES(dpy, &thread, &process))
++      return EGL_FALSE;
++
++   if (process->wl_global != NULL)
++      goto error;
++
++   process->wl_global = wl_global_create(display, &wl_dispmanx_interface, 1,
++                                         NULL, bind_dispmanx);
++   if (process->wl_global == NULL)
++      goto error;
++
++   return EGL_TRUE;
++
++error:
++   CLIENT_UNLOCK();
++   return EGL_FALSE;
++}
++
++EGLBoolean EGLAPIENTRY
++eglUnbindWaylandDisplayWL(EGLDisplay dpy, struct wl_display *display)
++{
++   CLIENT_THREAD_STATE_T *thread;
++   CLIENT_PROCESS_STATE_T *process;
++
++   if (!CLIENT_LOCK_AND_GET_STATES(dpy, &thread, &process))
++      return EGL_FALSE;
++
++   wl_global_destroy(process->wl_global);
++   process->wl_global = NULL;
++
++   CLIENT_UNLOCK();
++
++   return EGL_TRUE;
++}
++
++static int
++get_egl_format(enum wl_dispmanx_format format)
++{
++	switch (format) {
++	case WL_DISPMANX_FORMAT_ABGR8888:
++		return EGL_TEXTURE_RGBA;
++	case WL_DISPMANX_FORMAT_XBGR8888:
++		return EGL_TEXTURE_RGB;
++	case WL_DISPMANX_FORMAT_RGB565:
++		return EGL_TEXTURE_RGB;
++	default:
++		/* invalid format */
++		return EGL_NO_TEXTURE;
++	}
++}
++
++EGLBoolean EGLAPIENTRY
++eglQueryWaylandBufferWL(EGLDisplay dpy, struct wl_resource *_buffer,
++         EGLint attribute, EGLint *value)
++{
++   struct wl_dispmanx_server_buffer *buffer = wl_resource_get_user_data(_buffer);
++
++   if (wl_resource_instance_of(_buffer, &wl_dispmanx_interface,
++                               &dispmanx_buffer_interface))
++      return EGL_FALSE;
++
++   switch (attribute) {
++   case EGL_TEXTURE_FORMAT:
++      *value = get_egl_format(buffer->format);
++      if (*value == EGL_NO_TEXTURE)
++         return EGL_FALSE;
++      return EGL_TRUE;
++   case EGL_WIDTH:
++      *value = buffer->width;
++      return EGL_TRUE;
++   case EGL_HEIGHT:
++      *value = buffer->height;
++      return EGL_TRUE;
++   }
++
++   return EGL_FALSE;
++}
+diff --git a/interface/khronos/include/EGL/eglext.h b/interface/khronos/include/EGL/eglext.h
+index 89a3369..d7e5ba7 100755
+--- a/interface/khronos/include/EGL/eglext.h
++++ b/interface/khronos/include/EGL/eglext.h
+@@ -191,6 +191,29 @@ typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETSYNCATTRIBKHRPROC) (EGLDisplay dpy, EG
+ #endif
+ 
+ 
++#ifndef EGL_WL_bind_wayland_display
++#define EGL_WL_bind_wayland_display 1
++
++#define EGL_WAYLAND_BUFFER_WL		0x31D5 /* eglCreateImageKHR target */
++#define EGL_WAYLAND_PLANE_WL		0x31D6 /* eglCreateImageKHR target */
++#define EGL_TEXTURE_Y_U_V_WL            0x31D7
++#define EGL_TEXTURE_Y_UV_WL             0x31D8
++#define EGL_TEXTURE_Y_XUXV_WL           0x31D9
++
++struct wl_display;
++struct wl_resource;
++#ifdef EGL_EGLEXT_PROTOTYPES
++EGLAPI EGLBoolean EGLAPIENTRY eglBindWaylandDisplayWL(EGLDisplay dpy, struct wl_display *display);
++EGLAPI EGLBoolean EGLAPIENTRY eglUnbindWaylandDisplayWL(EGLDisplay dpy, struct wl_display *display);
++EGLAPI EGLBoolean EGLAPIENTRY eglQueryWaylandBufferWL(EGLDisplay dpy, struct wl_resource *buffer, EGLint attribute, EGLint *value);
++#endif
++typedef EGLBoolean (EGLAPIENTRYP PFNEGLBINDWAYLANDDISPLAYWL) (EGLDisplay dpy, struct wl_display *display);
++typedef EGLBoolean (EGLAPIENTRYP PFNEGLUNBINDWAYLANDDISPLAYWL) (EGLDisplay dpy, struct wl_display *display);
++typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYWAYLANDBUFFERWL) (EGLDisplay dpy, struct wl_resource *buffer, EGLint attribute, EGLint *value);
++
++#endif
++
++
+ #ifdef __cplusplus
+ }
+ #endif
+diff --git a/interface/khronos/wayland-egl/wayland-egl-priv.h b/interface/khronos/wayland-egl/wayland-egl-priv.h
+new file mode 100644
+index 0000000..8e38d36
+--- /dev/null
++++ b/interface/khronos/wayland-egl/wayland-egl-priv.h
+@@ -0,0 +1,53 @@
++/* Copied from Mesa */
++
++#ifndef _WAYLAND_EGL_PRIV_H
++#define _WAYLAND_EGL_PRIV_H
++
++#ifdef  __cplusplus
++extern "C" {
++#endif
++
++/* GCC visibility */
++#if defined(__GNUC__) && __GNUC__ >= 4
++#define WL_EGL_EXPORT __attribute__ ((visibility("default")))
++#else
++#define WL_EGL_EXPORT
++#endif
++
++#include "interface/vmcs_host/vc_dispmanx.h"
++#include "interface/khronos/egl/egl_client_surface.h"
++
++#include <wayland-client.h>
++
++struct wl_dispmanx_client_buffer {
++	struct wl_buffer *wl_buffer;
++	DISPMANX_RESOURCE_HANDLE_T resource;
++
++	int pending_allocation;
++	int in_use;
++	int width;
++	int height;
++};
++
++struct wl_egl_window {
++	struct wl_surface *wl_surface;
++
++	int width;
++	int height;
++	int dx;
++	int dy;
++
++	int attached_width;
++	int attached_height;
++
++	/* XXX: The VC side seems to expect a valid element handle to be
++	   passed to eglIntCreateSurface_impl and/or eglIntSwapBuffers_impl,
++	   even for host-managed surfaces. */
++	DISPMANX_ELEMENT_HANDLE_T dummy_element;
++};
++
++#ifdef  __cplusplus
++}
++#endif
++
++#endif
+diff --git a/interface/khronos/wayland-egl/wayland-egl.c b/interface/khronos/wayland-egl/wayland-egl.c
+new file mode 100644
+index 0000000..b8f050b
+--- /dev/null
++++ b/interface/khronos/wayland-egl/wayland-egl.c
+@@ -0,0 +1,59 @@
++/* Copied from Mesa */
++
++#include <stdlib.h>
++
++#include <wayland-client.h>
++#include <wayland-egl.h>
++#include "wayland-egl-priv.h"
++
++WL_EGL_EXPORT void
++wl_egl_window_resize(struct wl_egl_window *egl_window,
++		     int width, int height,
++		     int dx, int dy)
++{
++        if (egl_window->width == width &&
++	    egl_window->height == height &&
++	    egl_window->dx == dx &&
++	    egl_window->dy == dy)
++		return;
++
++	egl_window->width = width;
++	egl_window->height = height;
++	egl_window->dx = dx;
++	egl_window->dy = dy;
++}
++
++WL_EGL_EXPORT struct wl_egl_window *
++wl_egl_window_create(struct wl_surface *surface,
++		     int width, int height)
++{
++	struct wl_egl_window *egl_window;
++
++	egl_window = calloc(1, sizeof *egl_window);
++	if (!egl_window)
++		return NULL;
++
++	egl_window->wl_surface = surface;
++	wl_egl_window_resize(egl_window, width, height, 0, 0);
++	egl_window->attached_width  = 0;
++	egl_window->attached_height = 0;
++	egl_window->dummy_element = PLATFORM_WIN_NONE;
++
++	return egl_window;
++}
++
++WL_EGL_EXPORT void
++wl_egl_window_destroy(struct wl_egl_window *egl_window)
++{
++	free(egl_window);
++}
++
++WL_EGL_EXPORT void
++wl_egl_window_get_attached_size(struct wl_egl_window *egl_window,
++				int *width, int *height)
++{
++	if (width)
++		*width = egl_window->attached_width;
++	if (height)
++		*height = egl_window->attached_height;
++}
+diff --git a/interface/khronos/wayland-egl/wayland-egl.pc.in b/interface/khronos/wayland-egl/wayland-egl.pc.in
+new file mode 100644
+index 0000000..8bafc15
+--- /dev/null
++++ b/interface/khronos/wayland-egl/wayland-egl.pc.in
+@@ -0,0 +1,10 @@
++prefix=@CMAKE_INSTALL_PREFIX@
++exec_prefix=${prefix}
++libdir=${exec_prefix}/lib
++includedir=${prefix}/include
++
++Name: wayland-egl
++Description: VideoCore wayland-egl library
++Version: @PROJECT_APIVER@
++Libs: -L${libdir} -lwayland-egl
++Cflags: -I${includedir}
+diff --git a/interface/vmcs_host/CMakeLists.txt b/interface/vmcs_host/CMakeLists.txt
+index fde18da..6718215 100755
+--- a/interface/vmcs_host/CMakeLists.txt
++++ b/interface/vmcs_host/CMakeLists.txt
+@@ -9,13 +9,24 @@ add_definitions(-fno-strict-aliasing)
+ 
+ include_directories(${VMCS_TARGET}/vcfiled)
+ 
+-add_library(vchostif
+-            ${VMCS_TARGET}/vcfilesys.c ${VMCS_TARGET}/vcmisc.c
+-            vc_vchi_gencmd.c vc_vchi_filesys.c vc_vchi_gpuserv.c
+-            vc_vchi_tvservice.c vc_vchi_cecservice.c
+-            vc_vchi_dispmanx.c vc_service_common.c)
++set(VCHOSTIF_SOURCE
++    ${VMCS_TARGET}/vcfilesys.c ${VMCS_TARGET}/vcmisc.c
++    vc_vchi_gencmd.c vc_vchi_filesys.c vc_vchi_gpuserv.c
++    vc_vchi_tvservice.c vc_vchi_cecservice.c
++    vc_vchi_dispmanx.c vc_service_common.c)
+ #            ${VMCS_TARGET}/vmcs_main.c
+ #  vc_vchi_haud.c
++
++if (BUILD_WAYLAND)
++wayland_add_protocol_server(
++    VCHOSTIF_SOURCE
++    ../../interface/wayland/dispmanx.xml
++    dispmanx
++)
++endif ()
++
++add_library(vchostif ${VCHOSTIF_SOURCE})
++
+ #add_library(bufman            vc_vchi_bufman.c            )
+ 
+ # OpenMAX/IL component service
+diff --git a/interface/vmcs_host/vc_dispmanx.h b/interface/vmcs_host/vc_dispmanx.h
+index 37fdae1..fe3619a 100755
+--- a/interface/vmcs_host/vc_dispmanx.h
++++ b/interface/vmcs_host/vc_dispmanx.h
+@@ -39,6 +39,11 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
++
++#ifdef BUILD_WAYLAND
++struct wl_resource;
++#endif
++
+ // Same function as above, to aid migration of code.
+ VCHPRE_ int VCHPOST_ vc_dispman_init( void );
+ // Stop the service from being used
+@@ -135,6 +140,11 @@ VCHPRE_ int VCHPOST_ vc_dispmanx_resource_set_palette( DISPMANX_RESOURCE_HANDLE_
+ // Start triggering callbacks synced to vsync
+ VCHPRE_ int VCHPOST_ vc_dispmanx_vsync_callback( DISPMANX_DISPLAY_HANDLE_T display, DISPMANX_CALLBACK_FUNC_T cb_func, void *cb_arg );
+ 
++#ifdef BUILD_WAYLAND
++VCHPRE_ DISPMANX_RESOURCE_HANDLE_T VCHPOST_ vc_dispmanx_get_handle_from_wl_buffer( struct wl_resource *_buffer );
++
++VCHPRE_ void VCHPOST_ vc_dispmanx_set_wl_buffer_in_use( struct wl_resource *_buffer, int in_use );
++#endif
+ #ifdef __cplusplus
+ }
+ #endif
+diff --git a/interface/vmcs_host/vc_vchi_dispmanx.c b/interface/vmcs_host/vc_vchi_dispmanx.c
+index 7a6cdcd..eab146e 100755
+--- a/interface/vmcs_host/vc_vchi_dispmanx.c
++++ b/interface/vmcs_host/vc_vchi_dispmanx.c
+@@ -1319,3 +1319,45 @@ static void *dispmanx_notify_func( void *arg ) {
+    }
+    return 0;
+ }
++
++
++#ifdef BUILD_WAYLAND
++/***********************************************************
++ * Name: vc_dispmanx_get_handle_from_wl_buffer
++ *
++ * Arguments:
++ *       struct wl_resource *_buffer
++ *
++ * Description: Return the handle of the resource associated to this Wayland buffer
++ *
++ * Returns: A resource handle
++ *
++ ***********************************************************/
++VCHPRE_ DISPMANX_RESOURCE_HANDLE_T VCHPOST_ vc_dispmanx_get_handle_from_wl_buffer( struct wl_resource *_buffer )
++{
++	struct wl_dispmanx_server_buffer *buffer = (struct wl_dispmanx_server_buffer*)_buffer->data;
++	if (!buffer)
++		return DISPMANX_NO_HANDLE;
++
++	return buffer->handle;
++}
++
++/***********************************************************
++ * Name: vc_dispmanx_set_wl_buffer_in_use
++ *
++ * Arguments:
++ *       struct wl_resource *_buffer
++ *       int in_use
++ *
++ * Description: Mark this Wayland buffer as being in use by the compositor
++ *
++ ***********************************************************/
++VCHPRE_ void VCHPOST_ vc_dispmanx_set_wl_buffer_in_use( struct wl_resource *_buffer, int in_use )
++{
++	struct wl_dispmanx_server_buffer *buffer = (struct wl_dispmanx_server_buffer*)_buffer->data;
++	if (!buffer)
++		return;
++
++	buffer->in_use = in_use;
++}
++#endif
+diff --git a/interface/vmcs_host/vc_vchi_dispmanx.h b/interface/vmcs_host/vc_vchi_dispmanx.h
+index b723b76..f0bae30 100644
+--- a/interface/vmcs_host/vc_vchi_dispmanx.h
++++ b/interface/vmcs_host/vc_vchi_dispmanx.h
+@@ -66,4 +66,19 @@ typedef struct {
+ #define ELEMENT_CHANGE_MASK_RESOURCE  (1<<4)
+ #define ELEMENT_CHANGE_TRANSFORM      (1<<5)
+ 
++#ifdef BUILD_WAYLAND
++/* XXX: This should be in a private header that can be included from EGL and vc_* */
++#include <wayland-server.h>
++#include "interface/vmcs_host/wayland-dispmanx-server-protocol.h"
++struct wl_dispmanx_server_buffer {
++	struct wl_resource *resource;
++	struct wl_dispmanx *dispmanx;
++	enum wl_dispmanx_format format;
++	DISPMANX_RESOURCE_HANDLE_T handle;
++	int32_t width;
++	int32_t height;
++	int in_use;
++};
++#endif
++
+ #endif
+diff --git a/interface/wayland/dispmanx.xml b/interface/wayland/dispmanx.xml
+new file mode 100644
+index 0000000..c18626d
+--- /dev/null
++++ b/interface/wayland/dispmanx.xml
+@@ -0,0 +1,123 @@
++<?xml version="1.0" encoding="UTF-8"?>
++<protocol name="dispmanx">
++
++  <copyright>
++    Copyright © 2008-2011 Kristian Høgsberg
++    Copyright © 2010-2011 Intel Corporation
++    Copyright © 2013 Raspberry Pi Foundation
++
++    Permission to use, copy, modify, distribute, and sell this
++    software and its documentation for any purpose is hereby granted
++    without fee, provided that\n the above copyright notice appear in
++    all copies and that both that copyright notice and this permission
++    notice appear in supporting documentation, and that the name of
++    the copyright holders not be used in advertising or publicity
++    pertaining to distribution of the software without specific,
++    written prior permission.  The copyright holders make no
++    representations about the suitability of this software for any
++    purpose.  It is provided "as is" without express or implied
++    warranty.
++
++    THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS
++    SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
++    FITNESS, IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY
++    SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
++    WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
++    AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
++    ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
++    THIS SOFTWARE.
++  </copyright>
++
++  <!-- DispManX support. This object is created by the server and published
++       using the display's global event. -->
++  <interface name="wl_dispmanx" version="1">
++    <enum name="error">
++      <entry name="alloc_failed" value="0"/>
++      <entry name="invalid_format" value="1"/>
++    </enum>
++
++    <enum name="format">
++      <!-- The pixel format codes match the #defines in drm_fourcc.h.
++           The formats actually supported by the compositor will be
++           reported by the format event. -->
++      <entry name="c8" value="0x20203843"/>
++      <entry name="rgb332" value="0x38424752"/>
++      <entry name="bgr233" value="0x38524742"/>
++      <entry name="xrgb4444" value="0x32315258"/>
++      <entry name="xbgr4444" value="0x32314258"/>
++      <entry name="rgbx4444" value="0x32315852"/>
++      <entry name="bgrx4444" value="0x32315842"/>
++      <entry name="argb4444" value="0x32315241"/>
++      <entry name="abgr4444" value="0x32314241"/>
++      <entry name="rgba4444" value="0x32314152"/>
++      <entry name="bgra4444" value="0x32314142"/>
++      <entry name="xrgb1555" value="0x35315258"/>
++      <entry name="xbgr1555" value="0x35314258"/>
++      <entry name="rgbx5551" value="0x35315852"/>
++      <entry name="bgrx5551" value="0x35315842"/>
++      <entry name="argb1555" value="0x35315241"/>
++      <entry name="abgr1555" value="0x35314241"/>
++      <entry name="rgba5551" value="0x35314152"/>
++      <entry name="bgra5551" value="0x35314142"/>
++      <entry name="rgb565" value="0x36314752"/>
++      <entry name="bgr565" value="0x36314742"/>
++      <entry name="rgb888" value="0x34324752"/>
++      <entry name="bgr888" value="0x34324742"/>
++      <entry name="xrgb8888" value="0x34325258"/>
++      <entry name="xbgr8888" value="0x34324258"/>
++      <entry name="rgbx8888" value="0x34325852"/>
++      <entry name="bgrx8888" value="0x34325842"/>
++      <entry name="argb8888" value="0x34325241"/>
++      <entry name="abgr8888" value="0x34324241"/>
++      <entry name="rgba8888" value="0x34324152"/>
++      <entry name="bgra8888" value="0x34324142"/>
++      <entry name="xrgb2101010" value="0x30335258"/>
++      <entry name="xbgr2101010" value="0x30334258"/>
++      <entry name="rgbx1010102" value="0x30335852"/>
++      <entry name="bgrx1010102" value="0x30335842"/>
++      <entry name="argb2101010" value="0x30335241"/>
++      <entry name="abgr2101010" value="0x30334241"/>
++      <entry name="rgba1010102" value="0x30334152"/>
++      <entry name="bgra1010102" value="0x30334142"/>
++      <entry name="yuyv" value="0x56595559"/>
++      <entry name="yvyu" value="0x55595659"/>
++      <entry name="uyvy" value="0x59565955"/>
++      <entry name="vyuy" value="0x59555956"/>
++      <entry name="ayuv" value="0x56555941"/>
++      <entry name="nv12" value="0x3231564e"/>
++      <entry name="nv21" value="0x3132564e"/>
++      <entry name="nv16" value="0x3631564e"/>
++      <entry name="nv61" value="0x3136564e"/>
++      <entry name="yuv410" value="0x39565559"/>
++      <entry name="yvu410" value="0x39555659"/>
++      <entry name="yuv411" value="0x31315559"/>
++      <entry name="yvu411" value="0x31315659"/>
++      <entry name="yuv420" value="0x32315559"/>
++      <entry name="yvu420" value="0x32315659"/>
++      <entry name="yuv422" value="0x36315559"/>
++      <entry name="yvu422" value="0x36315659"/>
++      <entry name="yuv444" value="0x34325559"/>
++      <entry name="yvu444" value="0x34325659"/>
++    </enum>
++
++    <event name="format">
++      <arg name="format" type="uint"/>
++    </event>
++
++    <!-- Create a wayland buffer for the DispManX resource. -->
++    <request name="create_buffer">
++      <arg name="id" type="new_id" interface="wl_buffer"/>
++      <arg name="width" type="int"/>
++      <arg name="height" type="int"/>
++      <arg name="stride" type="uint"/>
++      <arg name="buffer_height" type="uint"/>
++      <arg name="format" type="uint"/>
++    </request>
++
++    <event name="buffer_allocated">
++      <arg name="buffer" type="object" interface="wl_buffer"/>
++      <arg name="handle" type="uint"/>
++    </event>
++  </interface>
++
++</protocol>
+diff --git a/makefiles/cmake/Wayland.cmake b/makefiles/cmake/Wayland.cmake
+new file mode 100644
+index 0000000..ad90d30
+--- /dev/null
++++ b/makefiles/cmake/Wayland.cmake
+@@ -0,0 +1,72 @@
++#=============================================================================
++# Copyright (C) 2012-2013 Pier Luigi Fiorini <pierluigi.fiorini@gmail.com>
++# All rights reserved.
++#
++# 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 Pier Luigi Fiorini nor the names of his
++#   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
++# HOLDER 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.
++#=============================================================================
++
++find_program(WAYLAND_SCANNER_EXECUTABLE NAMES wayland-scanner)
++
++# wayland_add_protocol_client(outfiles inputfile basename)
++function(WAYLAND_ADD_PROTOCOL_CLIENT _sources _protocol _basename)
++    if(NOT WAYLAND_SCANNER_EXECUTABLE)
++        message(FATAL "The wayland-scanner executable has nto been found on your system. You must install it.")
++    endif()
++
++    get_filename_component(_infile ${_protocol} ABSOLUTE)
++    set(_client_header "${CMAKE_CURRENT_BINARY_DIR}/wayland-${_basename}-client-protocol.h")
++    set(_code "${CMAKE_CURRENT_BINARY_DIR}/wayland-${_basename}-protocol.c")
++
++    add_custom_command(OUTPUT "${_client_header}"
++        COMMAND ${WAYLAND_SCANNER_EXECUTABLE} client-header < ${_infile} > ${_client_header}
++        DEPENDS ${_infile} VERBATIM)
++
++    add_custom_command(OUTPUT "${_code}"
++        COMMAND ${WAYLAND_SCANNER_EXECUTABLE} code < ${_infile} > ${_code}
++        DEPENDS ${_infile} VERBATIM)
++
++    list(APPEND ${_sources} "${_client_header}" "${_code}")
++    set(${_sources} ${${_sources}} PARENT_SCOPE)
++endfunction()
++
++# wayland_add_protocol_server(outfiles inputfile basename)
++function(WAYLAND_ADD_PROTOCOL_SERVER _sources _protocol _basename)
++    if(NOT WAYLAND_SCANNER_EXECUTABLE)
++        message(FATAL "The wayland-scanner executable has nto been found on your system. You must install it.")
++    endif()
++
++    get_filename_component(_infile ${_protocol} ABSOLUTE)
++    set(_server_header "${CMAKE_CURRENT_BINARY_DIR}/wayland-${_basename}-server-protocol.h")
++
++    add_custom_command(OUTPUT "${_server_header}"
++        COMMAND ${WAYLAND_SCANNER_EXECUTABLE} server-header < ${_infile} > ${_server_header}
++        DEPENDS ${_infile} VERBATIM)
++
++    list(APPEND ${_sources} "${_server_header}")
++    set(${_sources} ${${_sources}} PARENT_SCOPE)
++endfunction()
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0003-wayland-Add-Wayland-example.patch b/meta-raspberrypi/recipes-graphics/userland/files/0003-wayland-Add-Wayland-example.patch
new file mode 100644
index 0000000..d83a9e5
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0003-wayland-Add-Wayland-example.patch
Binary files differ
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0004-wayland-egl-Add-bcm_host-to-dependencies.patch b/meta-raspberrypi/recipes-graphics/userland/files/0004-wayland-egl-Add-bcm_host-to-dependencies.patch
new file mode 100644
index 0000000..a42aa14
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0004-wayland-egl-Add-bcm_host-to-dependencies.patch
@@ -0,0 +1,28 @@
+From c379bd2dc575256084d9e36fc11a347e20660130 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 10 Aug 2015 02:38:27 -0700
+Subject: [PATCH 04/18] wayland-egl: Add bcm_host to dependencies
+
+It uses headers like vcos_platform_types.h but does not
+depend on module which should add the required include paths
+lets add the dependency on bcm_host module which should do it
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ interface/khronos/wayland-egl/wayland-egl.pc.in | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/interface/khronos/wayland-egl/wayland-egl.pc.in b/interface/khronos/wayland-egl/wayland-egl.pc.in
+index 8bafc15..fd259c9 100644
+--- a/interface/khronos/wayland-egl/wayland-egl.pc.in
++++ b/interface/khronos/wayland-egl/wayland-egl.pc.in
+@@ -6,5 +6,6 @@ includedir=${prefix}/include
+ Name: wayland-egl
+ Description: VideoCore wayland-egl library
+ Version: @PROJECT_APIVER@
++Requires: bcm_host
+ Libs: -L${libdir} -lwayland-egl
+ Cflags: -I${includedir}
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0005-interface-remove-faulty-assert-to-make-weston-happy-.patch b/meta-raspberrypi/recipes-graphics/userland/files/0005-interface-remove-faulty-assert-to-make-weston-happy-.patch
new file mode 100644
index 0000000..bbaadda
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0005-interface-remove-faulty-assert-to-make-weston-happy-.patch
@@ -0,0 +1,29 @@
+From bd940c32878d401f311215270579ff513c2f3999 Mon Sep 17 00:00:00 2001
+From: "Yann E. MORIN" <yann.morin.1998@free.fr>
+Date: Sat, 24 Jan 2015 22:07:19 +0100
+Subject: [PATCH 05/18] interface: remove faulty assert() to make weston happy
+ at runtime
+
+This was removed after a discussion on IRC with the weston guys
+('daniels' on irc.freenode.net/#wayland).
+
+Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
+---
+ interface/vmcs_host/vc_vchi_dispmanx.c | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/interface/vmcs_host/vc_vchi_dispmanx.c b/interface/vmcs_host/vc_vchi_dispmanx.c
+index eab146e..29e0dee 100755
+--- a/interface/vmcs_host/vc_vchi_dispmanx.c
++++ b/interface/vmcs_host/vc_vchi_dispmanx.c
+@@ -1306,7 +1306,6 @@ static void *dispmanx_notify_func( void *arg ) {
+             // Decrement the use count - the corresponding "use" is in vc_dispmanx_update_submit.
+             vchi_service_release(dispmanx_client.notify_handle[0]);
+             if (dispmanx_client.update_callback ) {
+-               vcos_assert( dispmanx_client.pending_update_handle == handle);
+                dispmanx_client.update_callback(handle, dispmanx_client.update_callback_param);
+             }
+          } else {
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0006-zero-out-wl-buffers-in-egl_surface_free.patch b/meta-raspberrypi/recipes-graphics/userland/files/0006-zero-out-wl-buffers-in-egl_surface_free.patch
new file mode 100644
index 0000000..1a5e14f
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0006-zero-out-wl-buffers-in-egl_surface_free.patch
@@ -0,0 +1,33 @@
+From 466f28ce302f68ac39be750f4b55285791f43ab1 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 6 Feb 2016 11:10:47 -0800
+Subject: [PATCH 06/18] zero-out wl buffers in egl_surface_free
+
+origins from buildroot
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ interface/khronos/egl/egl_client_surface.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/interface/khronos/egl/egl_client_surface.c b/interface/khronos/egl/egl_client_surface.c
+index 42350bf..1f923d9 100644
+--- a/interface/khronos/egl/egl_client_surface.c
++++ b/interface/khronos/egl/egl_client_surface.c
+@@ -690,11 +690,13 @@ void egl_surface_free(EGL_SURFACE_T *surface)
+       if (surface->back_wl_buffer) {
+          wl_buffer_destroy(surface->back_wl_buffer->wl_buffer);
+          free(surface->back_wl_buffer);
++         surface->back_wl_buffer = 0;
+       }
+ 
+       if (surface->front_wl_buffer) {
+          wl_buffer_destroy(surface->front_wl_buffer->wl_buffer);
+          free(surface->front_wl_buffer);
++         surface->front_wl_buffer = 0;
+       }
+ #endif
+    }
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0007-initialize-front-back-wayland-buffers.patch b/meta-raspberrypi/recipes-graphics/userland/files/0007-initialize-front-back-wayland-buffers.patch
new file mode 100644
index 0000000..72264e4
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0007-initialize-front-back-wayland-buffers.patch
@@ -0,0 +1,34 @@
+From b4a2967513f7d0f5f3caee8cf6cbc7a7a085ebac Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 6 Feb 2016 11:11:41 -0800
+Subject: [PATCH 07/18] initialize front back wayland buffers
+
+origins from metrological wayland support
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ interface/khronos/egl/egl_client_surface.c | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/interface/khronos/egl/egl_client_surface.c b/interface/khronos/egl/egl_client_surface.c
+index 1f923d9..9a9582c 100644
+--- a/interface/khronos/egl/egl_client_surface.c
++++ b/interface/khronos/egl/egl_client_surface.c
+@@ -401,11 +401,14 @@ EGL_SURFACE_T *egl_surface_create(
+ #ifdef BUILD_WAYLAND
+    if (type == WINDOW && wl_display) {
+       surface->wl_egl_window = (struct wl_egl_window*)win;
++      surface->front_wl_buffer = NULL;
+       surface->back_wl_buffer = allocate_wl_buffer(
+             surface->wl_egl_window, color);
+       resource = surface->back_wl_buffer->resource;
+    } else {
+       surface->wl_egl_window = NULL;
++      surface->front_wl_buffer = NULL;
++      surface->back_wl_buffer = NULL;
+       resource = DISPMANX_NO_HANDLE;
+    }
+ #endif
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0008-Remove-RPC_FLUSH.patch b/meta-raspberrypi/recipes-graphics/userland/files/0008-Remove-RPC_FLUSH.patch
new file mode 100644
index 0000000..a100e39
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0008-Remove-RPC_FLUSH.patch
@@ -0,0 +1,27 @@
+From 14c22987dfa9fec02794856cd15b2d64b4b81c32 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 6 Feb 2016 11:09:18 -0800
+Subject: [PATCH 08/18] Remove RPC_FLUSH
+
+Origins from buildroot
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ interface/khronos/ext/gl_oes_egl_image_client.c | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/interface/khronos/ext/gl_oes_egl_image_client.c b/interface/khronos/ext/gl_oes_egl_image_client.c
+index f9b7287..b04ffef 100644
+--- a/interface/khronos/ext/gl_oes_egl_image_client.c
++++ b/interface/khronos/ext/gl_oes_egl_image_client.c
+@@ -107,7 +107,6 @@ GL_API void GL_APIENTRY glEGLImageTargetTexture2DOES (GLenum target, GLeglImageO
+                    GLEGLIMAGETARGETTEXTURE2DOES_ID,
+                    RPC_ENUM(target),
+                    RPC_EGLID(image));
+-         RPC_FLUSH(thread);
+ #if EGL_BRCM_global_image
+       }
+ #endif
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0009-fix-cmake-dependency-race.patch b/meta-raspberrypi/recipes-graphics/userland/files/0009-fix-cmake-dependency-race.patch
new file mode 100644
index 0000000..4609455
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0009-fix-cmake-dependency-race.patch
@@ -0,0 +1,78 @@
+From e510be221276d06e630ab93452ecb712d3921790 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 6 Feb 2016 13:12:47 -0800
+Subject: [PATCH 09/18] fix cmake dependency race
+
+Fixes errors like
+
+/a/builder/mnt/build-oe/tmp-glibc/work/raspberrypi2-oe-linux-gnueabi/userland/git-r5/git/interface/vmcs_host/vc_vchi_dispmanx.h:72:66:
+fatal error: interface/vmcs_host/wayland-dispmanx-server-protocol.h: No
+such file or directory
+compilation terminated.
+interface/khronos/CMakeFiles/EGL_static.dir/build.make:773: recipe for
+target 'interface/khronos/CMakeFiles/EGL_static.dir/ext/egl_wayland.c.o'
+failed
+make[2]: ***
+[interface/khronos/CMakeFiles/EGL_static.dir/ext/egl_wayland.c.o] Error 1
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ interface/vcos/pthreads/CMakeLists.txt | 8 ++++++++
+ interface/vmcs_host/CMakeLists.txt     | 8 --------
+ interface/vmcs_host/vc_vchi_dispmanx.h | 2 +-
+ 3 files changed, 9 insertions(+), 9 deletions(-)
+
+diff --git a/interface/vcos/pthreads/CMakeLists.txt b/interface/vcos/pthreads/CMakeLists.txt
+index 1d81ca3..d6cd415 100644
+--- a/interface/vcos/pthreads/CMakeLists.txt
++++ b/interface/vcos/pthreads/CMakeLists.txt
+@@ -33,6 +33,14 @@ set (SOURCES
+    ../generic/vcos_generic_blockpool.c
+ )
+ 
++if (BUILD_WAYLAND)
++wayland_add_protocol_server(
++    SOURCES
++    ../../../interface/wayland/dispmanx.xml
++    dispmanx
++)
++endif ()
++
+ if (VCOS_PTHREADS_BUILD_SHARED)
+    add_library (vcos SHARED ${SOURCES})
+    target_link_libraries (vcos pthread dl rt)
+diff --git a/interface/vmcs_host/CMakeLists.txt b/interface/vmcs_host/CMakeLists.txt
+index 6718215..c415176 100755
+--- a/interface/vmcs_host/CMakeLists.txt
++++ b/interface/vmcs_host/CMakeLists.txt
+@@ -17,14 +17,6 @@ set(VCHOSTIF_SOURCE
+ #            ${VMCS_TARGET}/vmcs_main.c
+ #  vc_vchi_haud.c
+ 
+-if (BUILD_WAYLAND)
+-wayland_add_protocol_server(
+-    VCHOSTIF_SOURCE
+-    ../../interface/wayland/dispmanx.xml
+-    dispmanx
+-)
+-endif ()
+-
+ add_library(vchostif ${VCHOSTIF_SOURCE})
+ 
+ #add_library(bufman            vc_vchi_bufman.c            )
+diff --git a/interface/vmcs_host/vc_vchi_dispmanx.h b/interface/vmcs_host/vc_vchi_dispmanx.h
+index f0bae30..8c44c58 100644
+--- a/interface/vmcs_host/vc_vchi_dispmanx.h
++++ b/interface/vmcs_host/vc_vchi_dispmanx.h
+@@ -69,7 +69,7 @@ typedef struct {
+ #ifdef BUILD_WAYLAND
+ /* XXX: This should be in a private header that can be included from EGL and vc_* */
+ #include <wayland-server.h>
+-#include "interface/vmcs_host/wayland-dispmanx-server-protocol.h"
++#include "interface/vcos/pthreads/wayland-dispmanx-server-protocol.h"
+ struct wl_dispmanx_server_buffer {
+ 	struct wl_resource *resource;
+ 	struct wl_dispmanx *dispmanx;
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0010-Fix-for-framerate-with-nested-composition.patch b/meta-raspberrypi/recipes-graphics/userland/files/0010-Fix-for-framerate-with-nested-composition.patch
new file mode 100644
index 0000000..dd0b95e
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0010-Fix-for-framerate-with-nested-composition.patch
@@ -0,0 +1,60 @@
+From 8e6cde08077eadfe563dc17c19995ebc48e30b97 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 29 Mar 2016 20:38:30 -0700
+Subject: [PATCH 10/18] Fix for framerate with nested composition
+
+frame rate appears irregular and lower than expected when using nested composition.
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ interface/khronos/egl/egl_client.c | 8 ++++++++
+ 1 file changed, 8 insertions(+)
+
+diff --git a/interface/khronos/egl/egl_client.c b/interface/khronos/egl/egl_client.c
+index 03fe67b..13a110c 100644
+--- a/interface/khronos/egl/egl_client.c
++++ b/interface/khronos/egl/egl_client.c
+@@ -2342,6 +2342,9 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+                      surface->back_wl_buffer = buffer;
+                   }
+ 
++                  glFlush();
++                  glFinish();
++
+                   RPC_CALL7(eglIntSwapBuffers_impl,
+                         thread,
+                         EGLINTSWAPBUFFERS_ID_V2,
+@@ -2353,6 +2356,8 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+                         RPC_UINT(khrn_platform_get_window_position(surface->win)),
+                         RPC_INT(surface->back_wl_buffer->resource));
+ 
++                  RPC_FLUSH(thread);
++
+                   surface->front_wl_buffer->in_use = 1;
+                   wl_surface_attach(wl_egl_window->wl_surface,
+                                     surface->front_wl_buffer->wl_buffer,
+@@ -2360,11 +2365,13 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+                   wl_surface_damage(wl_egl_window->wl_surface, 0, 0,
+                                     surface->width, surface->height);
+                   wl_surface_commit(wl_egl_window->wl_surface);
++                  wl_display_flush(wl_display);
+ 
+                   while(ret != -1 && surface->back_wl_buffer->in_use)
+                      ret = wl_display_dispatch_queue(wl_display, process->wl_queue);
+                } else
+ #endif
++               {
+                RPC_CALL6(eglIntSwapBuffers_impl,
+                      thread,
+                      EGLINTSWAPBUFFERS_ID,
+@@ -2376,6 +2383,7 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+                      RPC_UINT(khrn_platform_get_window_position(surface->win)));
+ 
+                RPC_FLUSH(thread);
++               }
+ 
+ #ifdef ANDROID
+                CLIENT_UNLOCK();
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0011-build-shared-library-for-vchostif.patch b/meta-raspberrypi/recipes-graphics/userland/files/0011-build-shared-library-for-vchostif.patch
new file mode 100644
index 0000000..4bd5320
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0011-build-shared-library-for-vchostif.patch
@@ -0,0 +1,28 @@
+From 9a97d60262999093d6ce8cb688279506c210d802 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 2 Apr 2016 10:37:24 -0700
+Subject: [PATCH 11/18] build shared library for vchostif
+
+Fixes #149
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ interface/vmcs_host/CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/interface/vmcs_host/CMakeLists.txt b/interface/vmcs_host/CMakeLists.txt
+index c415176..d0cca1a 100755
+--- a/interface/vmcs_host/CMakeLists.txt
++++ b/interface/vmcs_host/CMakeLists.txt
+@@ -17,7 +17,7 @@ set(VCHOSTIF_SOURCE
+ #            ${VMCS_TARGET}/vmcs_main.c
+ #  vc_vchi_haud.c
+ 
+-add_library(vchostif ${VCHOSTIF_SOURCE})
++add_library(vchostif SHARED ${VCHOSTIF_SOURCE})
+ 
+ #add_library(bufman            vc_vchi_bufman.c            )
+ 
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0012-implement-buffer-wrapping-interface-for-dispmanx.patch b/meta-raspberrypi/recipes-graphics/userland/files/0012-implement-buffer-wrapping-interface-for-dispmanx.patch
new file mode 100644
index 0000000..9684b4c
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0012-implement-buffer-wrapping-interface-for-dispmanx.patch
@@ -0,0 +1,92 @@
+From fedd7668152049c15ed58c7058e5f4a9c1fac7cb Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 2 Apr 2016 10:54:59 -0700
+Subject: [PATCH 12/18] implement buffer wrapping interface for dispmanx
+
+Courtesy: Zan Dobersek
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ interface/khronos/ext/egl_wayland.c | 42 +++++++++++++++++++++++++++++
+ interface/wayland/dispmanx.xml      | 10 +++++++
+ 2 files changed, 52 insertions(+)
+
+diff --git a/interface/khronos/ext/egl_wayland.c b/interface/khronos/ext/egl_wayland.c
+index 5730743..9ef89cd 100644
+--- a/interface/khronos/ext/egl_wayland.c
++++ b/interface/khronos/ext/egl_wayland.c
+@@ -133,8 +133,50 @@ dispmanx_create_buffer(struct wl_client *client, struct wl_resource *resource,
+                                      buffer->handle);
+ }
+ 
++static void
++dispmanx_wrap_buffer(struct wl_client *client, struct wl_resource *resource,
++                     uint32_t id, uint32_t handle, int32_t width, int32_t height,
++                     uint32_t stride, uint32_t buffer_height, uint32_t format)
++{
++   struct wl_dispmanx_server_buffer *buffer;
++   VC_IMAGE_TYPE_T vc_format = get_vc_format(format);
++   uint32_t dummy;
++
++   if(vc_format == VC_IMAGE_MIN) {
++      wl_resource_post_error(resource,
++                             WL_DISPMANX_ERROR_INVALID_FORMAT,
++                             "invalid format");
++      return;
++   }
++
++   buffer = calloc(1, sizeof *buffer);
++   if (buffer == NULL) {
++      wl_resource_post_no_memory(resource);
++      return;
++   }
++
++   buffer->handle = handle;
++   buffer->width = width;
++   buffer->height = height;
++   buffer->format = format;
++
++   buffer->resource = wl_resource_create(resource->client, &wl_buffer_interface,
++                                         1, id);
++   if (!buffer->resource) {
++      wl_resource_post_no_memory(resource);
++      vc_dispmanx_resource_delete(buffer->handle);
++      free(buffer);
++      return;
++   }
++
++   wl_resource_set_implementation(buffer->resource,
++				       (void (**)(void)) &dispmanx_buffer_interface,
++				       buffer, destroy_buffer);
++}
++
+ static const struct wl_dispmanx_interface dispmanx_interface = {
+    dispmanx_create_buffer,
++   dispmanx_wrap_buffer,
+ };
+ 
+ static void
+diff --git a/interface/wayland/dispmanx.xml b/interface/wayland/dispmanx.xml
+index c18626d..11ed1ef 100644
+--- a/interface/wayland/dispmanx.xml
++++ b/interface/wayland/dispmanx.xml
+@@ -118,6 +118,16 @@
+       <arg name="buffer" type="object" interface="wl_buffer"/>
+       <arg name="handle" type="uint"/>
+     </event>
++
++    <request name="wrap_buffer">
++      <arg name="id" type="new_id" interface="wl_buffer"/>
++      <arg name="handle" type="uint"/>
++      <arg name="width" type="int"/>
++      <arg name="height" type="int"/>
++      <arg name="stride" type="uint"/>
++      <arg name="buffer_height" type="uint"/>
++      <arg name="format" type="uint"/>
++    </request>
+   </interface>
+ 
+ </protocol>
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0013-Implement-triple-buffering-for-wayland.patch b/meta-raspberrypi/recipes-graphics/userland/files/0013-Implement-triple-buffering-for-wayland.patch
new file mode 100644
index 0000000..3052168
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0013-Implement-triple-buffering-for-wayland.patch
@@ -0,0 +1,90 @@
+From 65f8bca55aead676cd06fc3210aeffef1f2158c6 Mon Sep 17 00:00:00 2001
+From: Jeff Wannamaker <jeff_wannamaker@cable.comcast.com>
+Date: Thu, 19 Jan 2017 18:56:07 +0000
+Subject: [PATCH 13/18] Implement triple buffering for wayland
+
+Change from double to triple buffering for wayland.
+This enables higher frame rates without tearing artifacts
+by allowing both the glFinish and the buffer release
+interlock to operate without pushing the frame period
+to two vertical intervals
+
+Signed-off-by: Jeff Wannamaker <jeff_wannamaker@cable.comcast.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ interface/khronos/egl/egl_client.c         |  3 ++-
+ interface/khronos/egl/egl_client_surface.c |  8 ++++++++
+ interface/khronos/egl/egl_client_surface.h | 11 +++++++++++
+ 3 files changed, 21 insertions(+), 1 deletion(-)
+
+diff --git a/interface/khronos/egl/egl_client.c b/interface/khronos/egl/egl_client.c
+index 13a110c..0380274 100644
+--- a/interface/khronos/egl/egl_client.c
++++ b/interface/khronos/egl/egl_client.c
+@@ -2323,7 +2323,8 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+ 
+                   buffer_temp = surface->front_wl_buffer;
+                   surface->front_wl_buffer = surface->back_wl_buffer;
+-                  surface->back_wl_buffer = buffer_temp;
++                  surface->back_wl_buffer = surface->middle_wl_buffer;
++                  surface->middle_wl_buffer = buffer_temp;
+ 
+                   configid = egl_config_to_id(surface->config);
+                   color = egl_config_get_color_format(configid);
+diff --git a/interface/khronos/egl/egl_client_surface.c b/interface/khronos/egl/egl_client_surface.c
+index 9a9582c..10b3b04 100644
+--- a/interface/khronos/egl/egl_client_surface.c
++++ b/interface/khronos/egl/egl_client_surface.c
+@@ -402,12 +402,14 @@ EGL_SURFACE_T *egl_surface_create(
+    if (type == WINDOW && wl_display) {
+       surface->wl_egl_window = (struct wl_egl_window*)win;
+       surface->front_wl_buffer = NULL;
++      surface->middle_wl_buffer = NULL;
+       surface->back_wl_buffer = allocate_wl_buffer(
+             surface->wl_egl_window, color);
+       resource = surface->back_wl_buffer->resource;
+    } else {
+       surface->wl_egl_window = NULL;
+       surface->front_wl_buffer = NULL;
++      surface->middle_wl_buffer = NULL;
+       surface->back_wl_buffer = NULL;
+       resource = DISPMANX_NO_HANDLE;
+    }
+@@ -696,6 +698,12 @@ void egl_surface_free(EGL_SURFACE_T *surface)
+          surface->back_wl_buffer = 0;
+       }
+ 
++      if (surface->middle_wl_buffer) {
++         wl_buffer_destroy(surface->middle_wl_buffer->wl_buffer);
++         free(surface->middle_wl_buffer);
++         surface->middle_wl_buffer = 0;
++      }
++
+       if (surface->front_wl_buffer) {
+          wl_buffer_destroy(surface->front_wl_buffer->wl_buffer);
+          free(surface->front_wl_buffer);
+diff --git a/interface/khronos/egl/egl_client_surface.h b/interface/khronos/egl/egl_client_surface.h
+index e328b77..58a3184 100644
+--- a/interface/khronos/egl/egl_client_surface.h
++++ b/interface/khronos/egl/egl_client_surface.h
+@@ -312,6 +312,17 @@ typedef struct {
+    */
+    struct wl_dispmanx_client_buffer *front_wl_buffer;
+ 
++   /*
++      middle_wl_buffer
++
++      Validity:
++      type == WINDOW
++
++      Invariant:
++      client-side information about the wl_buffer in the middle
++   */
++   struct wl_dispmanx_client_buffer *middle_wl_buffer;
++
+    /*
+       back_wl_buffer
+ 
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0014-GLES2-gl2ext.h-Define-GL_R8_EXT-and-GL_RG8_EXT.patch b/meta-raspberrypi/recipes-graphics/userland/files/0014-GLES2-gl2ext.h-Define-GL_R8_EXT-and-GL_RG8_EXT.patch
new file mode 100644
index 0000000..037d708
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0014-GLES2-gl2ext.h-Define-GL_R8_EXT-and-GL_RG8_EXT.patch
@@ -0,0 +1,35 @@
+From dc1d07d835e1fe70c957a655d6fbb8cde65775af Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 10 May 2017 06:39:34 +0000
+Subject: [PATCH 14/18] GLES2/gl2ext.h: Define GL_R8_EXT and GL_RG8_EXT
+
+weston code uses these defines
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ interface/khronos/include/GLES2/gl2ext.h | 8 ++++++++
+ 1 file changed, 8 insertions(+)
+
+diff --git a/interface/khronos/include/GLES2/gl2ext.h b/interface/khronos/include/GLES2/gl2ext.h
+index 4eacf7f..b1acc9f 100644
+--- a/interface/khronos/include/GLES2/gl2ext.h
++++ b/interface/khronos/include/GLES2/gl2ext.h
+@@ -327,6 +327,14 @@ typedef void* GLeglImageOES;
+ #define GL_RGBX_BRCM                                            0x80EE
+ #endif
+ 
++#ifndef GL_EXT_texture_rg
++#define GL_EXT_texture_rg 1
++#define GL_RED_EXT                                              0x1903
++#define GL_RG_EXT                                               0x8227
++#define GL_R8_EXT                                               0x8229
++#define GL_RG8_EXT                                              0x822B
++#endif /* GL_EXT_texture_rg */
++
+ /* GL_EXT_texture_type_2_10_10_10_REV */
+ #ifndef GL_EXT_texture_type_2_10_10_10_REV
+ #define GL_UNSIGNED_INT_2_10_10_10_REV_EXT                      0x8368
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0015-EGL-glplatform.h-define-EGL_CAST.patch b/meta-raspberrypi/recipes-graphics/userland/files/0015-EGL-glplatform.h-define-EGL_CAST.patch
new file mode 100644
index 0000000..02cecb8
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0015-EGL-glplatform.h-define-EGL_CAST.patch
@@ -0,0 +1,32 @@
+From b5fa294c0d8fcb6dd5bfbfb96a0885dd9f3ae609 Mon Sep 17 00:00:00 2001
+From: Andrea Galbusera <gizero@gmail.com>
+Date: Fri, 14 Jul 2017 09:52:54 +0200
+Subject: [PATCH 15/18] EGL/glplatform.h: define EGL_CAST
+
+C++ / C typecast macros for special EGL handle values: used by libepoxy code
+The definition comes from the updated version of this header in mesa.
+
+Upstream-Status: Pending
+---
+ interface/khronos/include/EGL/eglplatform.h | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git a/interface/khronos/include/EGL/eglplatform.h b/interface/khronos/include/EGL/eglplatform.h
+index 1f7c930..c39d425 100644
+--- a/interface/khronos/include/EGL/eglplatform.h
++++ b/interface/khronos/include/EGL/eglplatform.h
+@@ -202,4 +202,11 @@ EGLAPI void EGLAPIENTRY BEGL_GetDefaultDriverInterfaces(BEGL_DriverInterfaces *i
+ #include "interface/khronos/common/khrn_client_mangle.h"
+ #endif
+ 
++/* C++ / C typecast macros for special EGL handle values */
++#if defined(__cplusplus)
++#define EGL_CAST(type, value) (static_cast<type>(value))
++#else
++#define EGL_CAST(type, value) ((type) (value))
++#endif
++
+ #endif /* __eglplatform_h */
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0016-Allow-multiple-wayland-compositor-state-data-per-pro.patch b/meta-raspberrypi/recipes-graphics/userland/files/0016-Allow-multiple-wayland-compositor-state-data-per-pro.patch
new file mode 100644
index 0000000..34ad90c
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0016-Allow-multiple-wayland-compositor-state-data-per-pro.patch
@@ -0,0 +1,145 @@
+From bff03f92c0d8bae113e0c7234c719f8385808b38 Mon Sep 17 00:00:00 2001
+From: Jeff Wannamaker <jeff_wannamaker@cable.comcast.com>
+Date: Sat, 27 Jan 2018 12:28:31 -0500
+Subject: [PATCH 16/18] Allow multiple wayland compositor state data per
+ process
+
+When eglBindWaylandDisplayWL is called store the wl_global
+created in a list associated with the wayland display.
+This allows multiple wayland compositor instances to be
+created and used per process. This scenario is common for
+applications integrating externl process UI elements
+via embedded composition e.g. westeros
+
+Signed-off-by: Jeff Wannamaker <jeff_wannamaker@cable.comcast.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ interface/khronos/common/khrn_client.c |  2 +-
+ interface/khronos/common/khrn_client.h | 11 +++++-
+ interface/khronos/ext/egl_wayland.c    | 50 ++++++++++++++++++++++----
+ 3 files changed, 55 insertions(+), 8 deletions(-)
+
+diff --git a/interface/khronos/common/khrn_client.c b/interface/khronos/common/khrn_client.c
+index d7e798e..60bdb63 100644
+--- a/interface/khronos/common/khrn_client.c
++++ b/interface/khronos/common/khrn_client.c
+@@ -147,7 +147,7 @@ bool client_process_state_init(CLIENT_PROCESS_STATE_T *process)
+ {
+    if (!process->inited) {
+ #ifdef BUILD_WAYLAND
+-      process->wl_global = NULL;
++      process->wlStateMap = NULL;
+ #endif
+ 
+       if (!khrn_pointer_map_init(&process->contexts, 64))
+diff --git a/interface/khronos/common/khrn_client.h b/interface/khronos/common/khrn_client.h
+index 615f7b4..4fa86f7 100644
+--- a/interface/khronos/common/khrn_client.h
++++ b/interface/khronos/common/khrn_client.h
+@@ -170,6 +170,15 @@ static INLINE CLIENT_THREAD_STATE_T *CLIENT_GET_CHECK_THREAD_STATE(void)
+    return (CLIENT_THREAD_STATE_T *)platform_tls_get_check(client_tls);
+ }
+ 
++#ifdef BUILD_WAYLAND
++typedef struct WAYLAND_STATE
++{
++   struct WAYLAND_STATE *next;
++   struct wl_display *display;
++   struct wl_global *wl_global;
++} WAYLAND_STATE_T;
++#endif
++
+ /*
+    per-process state
+ 
+@@ -318,7 +327,7 @@ struct CLIENT_PROCESS_STATE {
+    struct wl_event_queue *wl_queue;
+ 
+    /* Compositor-side Wayland state */
+-   struct wl_global *wl_global;
++   WAYLAND_STATE_T *wlStateMap;
+ #endif
+ };
+ 
+diff --git a/interface/khronos/ext/egl_wayland.c b/interface/khronos/ext/egl_wayland.c
+index 9ef89cd..abd5ab3 100644
+--- a/interface/khronos/ext/egl_wayland.c
++++ b/interface/khronos/ext/egl_wayland.c
+@@ -208,17 +208,38 @@ eglBindWaylandDisplayWL(EGLDisplay dpy, struct wl_display *display)
+ {
+    CLIENT_THREAD_STATE_T *thread;
+    CLIENT_PROCESS_STATE_T *process;
++   WAYLAND_STATE_T *stateIter;
++   WAYLAND_STATE_T *stateNew;
++   struct wl_global *wl_global;
+ 
+    if (!CLIENT_LOCK_AND_GET_STATES(dpy, &thread, &process))
+       return EGL_FALSE;
+ 
+-   if (process->wl_global != NULL)
++   stateIter= process->wlStateMap;
++   while( stateIter )
++   {
++      if ( stateIter->display == display )
++         goto error;
++      stateIter= stateIter->next;
++   }
++
++   wl_global = wl_global_create(display, &wl_dispmanx_interface, 1,
++                                NULL, bind_dispmanx);
++   if (wl_global == NULL)
+       goto error;
+ 
+-   process->wl_global = wl_global_create(display, &wl_dispmanx_interface, 1,
+-                                         NULL, bind_dispmanx);
+-   if (process->wl_global == NULL)
++   stateNew= (WAYLAND_STATE_T*)calloc( 1, sizeof(WAYLAND_STATE_T));
++   if (stateNew == NULL )
++   {
++      wl_global_destroy(wl_global);
+       goto error;
++   }
++
++   stateNew->next= process->wlStateMap;
++   stateNew->display= display;
++   stateNew->wl_global= wl_global;
++   process->wlStateMap= stateNew;
++   CLIENT_UNLOCK();
+ 
+    return EGL_TRUE;
+ 
+@@ -232,12 +253,29 @@ eglUnbindWaylandDisplayWL(EGLDisplay dpy, struct wl_display *display)
+ {
+    CLIENT_THREAD_STATE_T *thread;
+    CLIENT_PROCESS_STATE_T *process;
++   WAYLAND_STATE_T *stateIter;
++   WAYLAND_STATE_T *statePrev;
+ 
+    if (!CLIENT_LOCK_AND_GET_STATES(dpy, &thread, &process))
+       return EGL_FALSE;
+ 
+-   wl_global_destroy(process->wl_global);
+-   process->wl_global = NULL;
++   statePrev= NULL;
++   stateIter= process->wlStateMap;
++   while( stateIter )
++   {
++      if ( stateIter->display == display )
++      {
++         wl_global_destroy(stateIter->wl_global);
++         if ( statePrev )
++            statePrev->next= stateIter->next;
++         else
++            process->wlStateMap= stateIter->next;
++         free( stateIter );
++         break;
++      }
++      statePrev= stateIter;
++      stateIter= stateIter->next;
++   }
+ 
+    CLIENT_UNLOCK();
+ 
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0017-khronos-backport-typedef-for-EGL_EXT_image_dma_buf_i.patch b/meta-raspberrypi/recipes-graphics/userland/files/0017-khronos-backport-typedef-for-EGL_EXT_image_dma_buf_i.patch
new file mode 100644
index 0000000..546cd58
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0017-khronos-backport-typedef-for-EGL_EXT_image_dma_buf_i.patch
@@ -0,0 +1,38 @@
+From 8efd81e96bdd3be68063a6fd32be4755225e93b2 Mon Sep 17 00:00:00 2001
+From: Hugo Hromic <hhromic@gmail.com>
+Date: Sun, 13 May 2018 10:49:04 +0100
+Subject: [PATCH 17/18] khronos: backport typedef for
+ EGL_EXT_image_dma_buf_import
+
+The `gstreamer1.0-plugins-base` package version `1.14` uses `EGL_EXT_image_dma_buf_import`, which
+expects the `EGLuint64KHR` typedef that is present in recent versions of Khronos.
+However, the older version included in userland does not provide it.
+
+This patch backports the missing typedef from recent Khronos into userland.
+See: <https://www.khronos.org/registry/EGL/api/EGL/eglext.h>
+
+Submitted to userland in <https://github.com/raspberrypi/userland/pull/467>
+
+Upstream-Status: Submitted
+---
+ interface/khronos/include/EGL/eglext.h | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/interface/khronos/include/EGL/eglext.h b/interface/khronos/include/EGL/eglext.h
+index d7e5ba7..dcc90ce 100755
+--- a/interface/khronos/include/EGL/eglext.h
++++ b/interface/khronos/include/EGL/eglext.h
+@@ -190,6 +190,10 @@ typedef EGLBoolean (EGLAPIENTRYP PFNEGLSIGNALSYNCKHRPROC) (EGLDisplay dpy, EGLSy
+ typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETSYNCATTRIBKHRPROC) (EGLDisplay dpy, EGLSyncKHR sync, EGLint attribute, EGLint *value);
+ #endif
+ 
++#ifndef EGL_KHR_uint64_typedef
++#define EGL_KHR_uint64_typedef 1
++typedef khronos_uint64_t EGLuint64KHR;
++#endif /* EGL_KHR_uint64_typedef */
+ 
+ #ifndef EGL_WL_bind_wayland_display
+ #define EGL_WL_bind_wayland_display 1
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0018-Add-EGL_IMG_context_priority-related-defines.patch b/meta-raspberrypi/recipes-graphics/userland/files/0018-Add-EGL_IMG_context_priority-related-defines.patch
new file mode 100644
index 0000000..f4d865e
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/userland/files/0018-Add-EGL_IMG_context_priority-related-defines.patch
@@ -0,0 +1,35 @@
+From 9cfea4761ba68776fd9bfac671b74c7174f99029 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 15 Jul 2018 00:48:38 -0700
+Subject: [PATCH 18/18] Add EGL_IMG_context_priority related defines
+
+These defines are needed for compiling weston 4.x
+taken from Khronos headers
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ interface/khronos/include/EGL/eglext.h | 8 ++++++++
+ 1 file changed, 8 insertions(+)
+
+diff --git a/interface/khronos/include/EGL/eglext.h b/interface/khronos/include/EGL/eglext.h
+index dcc90ce..6842bf9 100755
+--- a/interface/khronos/include/EGL/eglext.h
++++ b/interface/khronos/include/EGL/eglext.h
+@@ -93,6 +93,14 @@ typedef EGLImageKHR (EGLAPIENTRYP PFNEGLCREATEIMAGEKHRPROC) (EGLDisplay dpy, EGL
+ typedef EGLBoolean (EGLAPIENTRYP PFNEGLDESTROYIMAGEKHRPROC) (EGLDisplay dpy, EGLImageKHR image);
+ #endif
+ 
++#ifndef EGL_IMG_context_priority
++#define EGL_IMG_context_priority 1
++#define EGL_CONTEXT_PRIORITY_LEVEL_IMG		0x3102
++#define EGL_CONTEXT_PRIORITY_HIGH_IMG		0x3101
++#define EGL_CONTEXT_PRIORITY_MEDIUM_IMG		0x3102
++#define EGL_CONTEXT_PRIORITY_LOW_IMG		0x3103
++#endif /* EGL_IMG_context_priority */
++
+ #ifndef EGL_KHR_vg_parent_image
+ #define EGL_KHR_vg_parent_image 1
+ #define EGL_VG_PARENT_IMAGE_KHR			0x30BA	/* eglCreateImageKHR target */
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0001-Allow-applications-to-set-next-resource-handle.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0001-Allow-applications-to-set-next-resource-handle.patch
deleted file mode 100644
index 933f279..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0001-Allow-applications-to-set-next-resource-handle.patch
+++ /dev/null
@@ -1,208 +0,0 @@
-From 0a64dc61d3d7db69389157ae757203b4b3afdbfa Mon Sep 17 00:00:00 2001
-From: Dom Cobley <dc4@broadcom.com>
-Date: Tue, 9 Jul 2013 09:26:26 -0400
-Subject: [PATCH 01/16] Allow applications to set next resource handle
-
-This patch adds provisions in userland to
-let apps callers set the next rendereing dispmanx resource.
-It's useful for implementing, say, a buffer carousel.
----
- interface/khronos/common/khrn_client_rpc.h |  2 ++
- interface/khronos/common/khrn_int_ids.h    |  2 ++
- interface/khronos/egl/egl_client.c         | 30 +++++++++++++++++++++++++++---
- interface/khronos/egl/egl_client_surface.c | 24 +++++++++++++++++++++++-
- interface/khronos/egl/egl_client_surface.h |  3 ++-
- interface/khronos/egl/egl_int_impl.h       |  5 +++--
- 6 files changed, 59 insertions(+), 7 deletions(-)
-
-diff --git a/interface/khronos/common/khrn_client_rpc.h b/interface/khronos/common/khrn_client_rpc.h
-index dc4351d..10ea060 100644
---- a/interface/khronos/common/khrn_client_rpc.h
-+++ b/interface/khronos/common/khrn_client_rpc.h
-@@ -685,6 +685,7 @@ static INLINE void rpc_call12_out_ctrl(CLIENT_THREAD_STATE_T *thread,uint32_t id
- static INLINE void rpc_call13_out_ctrl(CLIENT_THREAD_STATE_T *thread,uint32_t id, uint32_t p0, uint32_t p1, uint32_t p2, uint32_t p3, uint32_t p4, uint32_t p5, uint32_t p6, uint32_t p7, uint32_t p8, uint32_t p9, uint32_t p10, uint32_t p11, void *out)               { rpc_begin(thread); RPC_CALL(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11);      rpc_recv(thread, out, NULL, (RPC_RECV_FLAG_T)(RPC_RECV_FLAG_CTRL | RPC_RECV_FLAG_LEN)); rpc_end(thread); }
- static INLINE void rpc_call14_out_ctrl(CLIENT_THREAD_STATE_T *thread,uint32_t id, uint32_t p0, uint32_t p1, uint32_t p2, uint32_t p3, uint32_t p4, uint32_t p5, uint32_t p6, uint32_t p7, uint32_t p8, uint32_t p9, uint32_t p10, uint32_t p11, uint32_t p12, void *out) { rpc_begin(thread); RPC_CALL(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12); rpc_recv(thread, out, NULL, (RPC_RECV_FLAG_T)(RPC_RECV_FLAG_CTRL | RPC_RECV_FLAG_LEN)); rpc_end(thread); }
- static INLINE void rpc_call15_out_ctrl(CLIENT_THREAD_STATE_T *thread,uint32_t id, uint32_t p0, uint32_t p1, uint32_t p2, uint32_t p3, uint32_t p4, uint32_t p5, uint32_t p6, uint32_t p7, uint32_t p8, uint32_t p9, uint32_t p10, uint32_t p11, uint32_t p12, uint32_t p13, void *out) { rpc_begin(thread); RPC_CALL(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13); rpc_recv(thread, out, NULL, (RPC_RECV_FLAG_T)(RPC_RECV_FLAG_CTRL | RPC_RECV_FLAG_LEN)); rpc_end(thread); }
-+static INLINE void rpc_call16_out_ctrl(CLIENT_THREAD_STATE_T *thread,uint32_t id, uint32_t p0, uint32_t p1, uint32_t p2, uint32_t p3, uint32_t p4, uint32_t p5, uint32_t p6, uint32_t p7, uint32_t p8, uint32_t p9, uint32_t p10, uint32_t p11, uint32_t p12, uint32_t p13, uint32_t p14, void *out) { rpc_begin(thread); RPC_CALL(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14); rpc_recv(thread, out, NULL, (RPC_RECV_FLAG_T)(RPC_RECV_FLAG_CTRL | RPC_RECV_FLAG_LEN)); rpc_end(thread); }
- #endif
- 
- #define RPC_CALL1_OUT_CTRL(fn, thread, id, out)                                               rpc_call1_out_ctrl(thread, id, out)
-@@ -702,6 +703,7 @@ static INLINE void rpc_call15_out_ctrl(CLIENT_THREAD_STATE_T *thread,uint32_t id
- #define RPC_CALL13_OUT_CTRL(fn, thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, out)      rpc_call13_out_ctrl(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, out)
- #define RPC_CALL14_OUT_CTRL(fn, thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, out) rpc_call14_out_ctrl(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, out)
- #define RPC_CALL15_OUT_CTRL(fn, thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, out) rpc_call15_out_ctrl(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, out)
-+#define RPC_CALL16_OUT_CTRL(fn, thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, out) rpc_call16_out_ctrl(thread, id, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, out)
- 
- # if !defined(__SYMBIAN32__)  //use functions defined in khrpc.cpp
- static INLINE uint32_t rpc_call1_out_ctrl_res(CLIENT_THREAD_STATE_T *thread,uint32_t id, void *out)                                                                                                                       { uint32_t res; rpc_begin(thread); RPC_CALL(thread, id);                                     res = rpc_recv(thread, out, NULL, (RPC_RECV_FLAG_T)(RPC_RECV_FLAG_RES | RPC_RECV_FLAG_CTRL | RPC_RECV_FLAG_LEN)); rpc_end(thread); return res; }
-diff --git a/interface/khronos/common/khrn_int_ids.h b/interface/khronos/common/khrn_int_ids.h
-index 8378f4a..ec961e0 100644
---- a/interface/khronos/common/khrn_int_ids.h
-+++ b/interface/khronos/common/khrn_int_ids.h
-@@ -367,6 +367,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
- 
- #define EGLINTCREATESURFACE_ID            0x4000
-+#define EGLINTCREATESURFACE_ID_V2         0x4100
- #define EGLINTCREATEGLES11_ID             0x4001
- #define EGLINTCREATEGLES20_ID             0x4002
- #define EGLINTCREATEVG_ID                 0x4003
-@@ -377,6 +378,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- #define EGLINTMAKECURRENT_ID              0x4008
- #define EGLINTFLUSHANDWAIT_ID             0x4009
- #define EGLINTSWAPBUFFERS_ID              0x400a
-+#define EGLINTSWAPBUFFERS_ID_V2           0x410a
- #define EGLINTSELECTMIPMAP_ID             0x400b
- #define EGLINTFLUSH_ID                    0x400c
- #define EGLINTGETCOLORDATA_ID             0x400d
-diff --git a/interface/khronos/egl/egl_client.c b/interface/khronos/egl/egl_client.c
-index 9d617c8..b8bb374 100644
---- a/interface/khronos/egl/egl_client.c
-+++ b/interface/khronos/egl/egl_client.c
-@@ -162,6 +162,17 @@ static void egl_current_release(CLIENT_PROCESS_STATE_T *process, EGL_CURRENT_T *
- void egl_gl_flush_callback(bool wait);
- void egl_vg_flush_callback(bool wait);
- 
-+#include "interface/vmcs_host/vc_dispmanx_types.h"
-+/**HACKHACK - give us the ability to inject a DispmanX 
-+ * resource handle into the CreateWindowSurface and 
-+ * SwapBuffers calls */ 
-+static DISPMANX_RESOURCE_HANDLE_T next_resource_handle;
-+
-+EGLAPI EGLBoolean EGLAPIENTRY eglSetNextResourceHandle(DISPMANX_RESOURCE_HANDLE_T handle)
-+{
-+   next_resource_handle = handle;
-+}
-+
- /*
- TODO: do an RPC call to make sure the Khronos vll is loaded (and that it stays loaded until eglTerminate)
- Also affects global image (and possibly others?)
-@@ -644,7 +655,8 @@ EGLAPI EGLSurface EGLAPIENTRY eglCreateWindowSurface(EGLDisplay dpy, EGLConfig c
-                                 false,
-                                 EGL_NO_TEXTURE,
-                                 EGL_NO_TEXTURE,
--                                0, 0);
-+                                0, 0,
-+                                next_resource_handle);
- 
-                if (surface) {
-                   if (khrn_pointer_map_insert(&process->surfaces, process->next_surface, surface)) {
-@@ -889,7 +901,7 @@ EGLAPI EGLSurface EGLAPIENTRY eglCreatePbufferSurface(EGLDisplay dpy, EGLConfig
-                              mipmap_texture,
-                              texture_format,
-                              texture_target,
--                             0, 0);
-+                             0, 0, 0);
- 
-             if (surface) {
-                if (khrn_pointer_map_insert(&process->surfaces, process->next_surface, surface)) {
-@@ -1031,7 +1043,7 @@ EGLAPI EGLSurface EGLAPIENTRY eglCreatePixmapSurface(EGLDisplay dpy, EGLConfig c
-                                    false,
-                                    EGL_NO_TEXTURE,
-                                    EGL_NO_TEXTURE,
--                                   pixmap, ((server_handle[0] == 0) && (server_handle[1] == (uint32_t)(-1))) ? NULL : server_handle);
-+                                   pixmap, ((server_handle[0] == 0) && (server_handle[1] == (uint32_t)(-1))) ? NULL : server_handle, 0);
- 
-                      if (surface) {
-                         if (khrn_pointer_map_insert(&process->surfaces, process->next_surface, surface)) {
-@@ -2303,6 +2315,18 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
- 
-                vcos_log_trace("eglSwapBuffers server call");
- 
-+               if (next_resource_handle)
-+               RPC_CALL7(eglIntSwapBuffers_impl,
-+                     thread,
-+                     EGLINTSWAPBUFFERS_ID_V2,
-+                     RPC_UINT(surface->serverbuffer),
-+                     RPC_UINT(surface->width),
-+                     RPC_UINT(surface->height),
-+                     RPC_UINT(surface->internal_handle),
-+                     RPC_UINT(surface->swap_behavior == EGL_BUFFER_PRESERVED ? 1 : 0),
-+                     RPC_UINT(khrn_platform_get_window_position(surface->win)),
-+                     RPC_INT(next_resource_handle));
-+               else
-                RPC_CALL6(eglIntSwapBuffers_impl,
-                      thread,
-                      EGLINTSWAPBUFFERS_ID,
-diff --git a/interface/khronos/egl/egl_client_surface.c b/interface/khronos/egl/egl_client_surface.c
-index 6846dfa..128325e 100644
---- a/interface/khronos/egl/egl_client_surface.c
-+++ b/interface/khronos/egl/egl_client_surface.c
-@@ -314,7 +314,8 @@ EGL_SURFACE_T *egl_surface_create(
-    EGLenum texture_format,
-    EGLenum texture_target,
-    EGLNativePixmapType pixmap,
--   const uint32_t *pixmap_server_handle)
-+   const uint32_t *pixmap_server_handle,
-+   DISPMANX_RESOURCE_HANDLE_T next_resource_handle)
- {
-    KHRN_IMAGE_FORMAT_T color;
-    KHRN_IMAGE_FORMAT_T depth;
-@@ -473,6 +474,27 @@ EGL_SURFACE_T *egl_surface_create(
- #endif
-          uint32_t results[3];
- 
-+         if (next_resource_handle)
-+         RPC_CALL16_OUT_CTRL(eglIntCreateSurface_impl,
-+                             thread,
-+                             EGLINTCREATESURFACE_ID_V2,
-+                             RPC_UINT(serverwin),
-+                             RPC_UINT(buffers),
-+                             RPC_UINT(width),
-+                             RPC_UINT(height),
-+                             RPC_UINT(color),
-+                             RPC_UINT(depth),
-+                             RPC_UINT(mask),
-+                             RPC_UINT(multi),
-+                             RPC_UINT(largest_pbuffer),
-+                             RPC_UINT(mipmap_texture),
-+                             RPC_UINT(config_depth_bits),
-+                             RPC_UINT(config_stencil_bits),
-+                             RPC_UINT(sem_name),
-+                             RPC_UINT(type),
-+                             RPC_INT(next_resource_handle),
-+                             results);
-+         else
-          RPC_CALL15_OUT_CTRL(eglIntCreateSurface_impl,
-                              thread,
-                              EGLINTCREATESURFACE_ID,
-diff --git a/interface/khronos/egl/egl_client_surface.h b/interface/khronos/egl/egl_client_surface.h
-index c99d44c..b5bf70a 100644
---- a/interface/khronos/egl/egl_client_surface.h
-+++ b/interface/khronos/egl/egl_client_surface.h
-@@ -322,7 +322,8 @@ extern EGL_SURFACE_T *egl_surface_create(
-    EGLenum texture_format,
-    EGLenum texture_target,
-    EGLNativePixmapType pixmap,
--   const uint32_t *pixmap_server_handle);
-+   const uint32_t *pixmap_server_handle,
-+   DISPMANX_RESOURCE_HANDLE_T next_resource_handle);
- extern EGL_SURFACE_T *egl_surface_from_vg_image(
-    VGImage vg_handle,
-    EGLSurface name,
-diff --git a/interface/khronos/egl/egl_int_impl.h b/interface/khronos/egl/egl_int_impl.h
-index 8a5734c..51b3580 100644
---- a/interface/khronos/egl/egl_int_impl.h
-+++ b/interface/khronos/egl/egl_int_impl.h
-@@ -56,7 +56,8 @@ FN(int, eglIntCreateSurface_impl, (
-    uint32_t config_stencil_bits,
-    uint32_t sem,
-    uint32_t type,
--   uint32_t *results))
-+   uint32_t *results,
-+   DISPMANX_RESOURCE_HANDLE_T next_resource_handle))
- 
- FN(int, eglIntCreatePbufferFromVGImage_impl, (
-    VGImage vg_handle,
-@@ -110,7 +111,7 @@ FN(void, eglIntMakeCurrent_impl, (uint32_t pid_0, uint32_t pid_1, uint32_t glver
- FN(int, eglIntFlushAndWait_impl, (uint32_t flushgl, uint32_t flushvg))
- FN(void, eglIntFlush_impl, (uint32_t flushgl, uint32_t flushvg))
- 
--FN(void, eglIntSwapBuffers_impl, (EGL_SURFACE_ID_T s, uint32_t width, uint32_t height, uint32_t handle, uint32_t preserve, uint32_t position))
-+FN(void, eglIntSwapBuffers_impl, (EGL_SURFACE_ID_T s, uint32_t width, uint32_t height, uint32_t handle, uint32_t preserve, uint32_t position, DISPMANX_RESOURCE_HANDLE_T new_back_buffer))
- FN(void, eglIntSelectMipmap_impl, (EGL_SURFACE_ID_T s, int level))
- 
- FN(void, eglIntGetColorData_impl, (EGL_SURFACE_ID_T s, KHRN_IMAGE_FORMAT_T format, uint32_t width, uint32_t height, int32_t stride, uint32_t y_offset, void *data))
--- 
-2.16.1
-
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0002-wayland-Add-support-for-the-Wayland-winsys.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0002-wayland-Add-support-for-the-Wayland-winsys.patch
deleted file mode 100644
index 4613504..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0002-wayland-Add-support-for-the-Wayland-winsys.patch
+++ /dev/null
@@ -1,1861 +0,0 @@
-From 5608ec8002be8370e78c9dbb1e07cee4cfb18b58 Mon Sep 17 00:00:00 2001
-From: Tomeu Vizoso <tomeu.vizoso@collabora.com>
-Date: Tue, 1 Oct 2013 13:19:20 +0200
-Subject: [PATCH 02/16] wayland: Add support for the Wayland winsys
-
-* Adds EGL_WL_bind_wayland_display extension
-* Adds wayland-egl library
-* Adds wl_dispmanx_buffer protocol extension
-
-TODO: Check that platform_get_dimensions() returning swapchain_count == 1 is correct
-
-TODO: Remove the requirement of passing a valid DispmanX element handle to
-the SwapBuffers and CreateSurface RPC calls. This will remove the need to open
-a DispmanX display from the clients.
-
-TODO: wl_dispmanx_server_buffer should probably be defined in a
-private header that can be included from EGL and vc_* instead of in
-vc_vchi_dispmanx.h
----
- .gitignore                                         |   1 +
- CMakeLists.txt                                     |  11 +
- README.md                                          |   4 +
- buildme                                            |  10 +-
- .../linux/apps/raspicam/CMakeLists.txt             |   2 +-
- interface/khronos/CMakeLists.txt                   |  53 ++++-
- interface/khronos/common/khrn_client.c             |  15 ++
- interface/khronos/common/khrn_client.h             |  10 +
- interface/khronos/common/khrn_client_mangle.h      |   3 +
- interface/khronos/common/khrn_client_platform.h    |   8 +
- interface/khronos/common/khrn_client_unmangle.h    |   3 +
- .../common/linux/khrn_client_platform_linux.c      | 115 ++++++++--
- interface/khronos/common/linux/khrn_wayland.c      | 215 ++++++++++++++++++
- .../common/linux/khrn_wayland.h}                   |  46 +---
- interface/khronos/egl/egl_client.c                 |  92 +++++---
- interface/khronos/egl/egl_client_get_proc.c        |  11 +
- interface/khronos/egl/egl_client_surface.c         |  42 +++-
- interface/khronos/egl/egl_client_surface.h         |  38 +++-
- interface/khronos/egl/egl_int_impl.h               |   2 +-
- interface/khronos/ext/egl_wayland.c                | 246 +++++++++++++++++++++
- interface/khronos/include/EGL/eglext.h             |  23 ++
- interface/khronos/wayland-egl/wayland-egl-priv.h   |  53 +++++
- interface/khronos/wayland-egl/wayland-egl.c        |  59 +++++
- interface/khronos/wayland-egl/wayland-egl.pc.in    |  10 +
- interface/vmcs_host/CMakeLists.txt                 |  21 +-
- interface/vmcs_host/vc_dispmanx.h                  |  10 +
- interface/vmcs_host/vc_vchi_dispmanx.c             |  42 ++++
- interface/vmcs_host/vc_vchi_dispmanx.h             |  15 ++
- interface/wayland/dispmanx.xml                     | 123 +++++++++++
- makefiles/cmake/Wayland.cmake                      |  72 ++++++
- 30 files changed, 1257 insertions(+), 98 deletions(-)
- create mode 100644 interface/khronos/common/linux/khrn_wayland.c
- copy interface/{vmcs_host/vc_vchi_dispmanx.h => khronos/common/linux/khrn_wayland.h} (56%)
- create mode 100644 interface/khronos/ext/egl_wayland.c
- create mode 100644 interface/khronos/wayland-egl/wayland-egl-priv.h
- create mode 100644 interface/khronos/wayland-egl/wayland-egl.c
- create mode 100644 interface/khronos/wayland-egl/wayland-egl.pc.in
- create mode 100644 interface/wayland/dispmanx.xml
- create mode 100644 makefiles/cmake/Wayland.cmake
-
-Index: git/.gitignore
-===================================================================
---- git.orig/.gitignore
-+++ git/.gitignore
-@@ -30,3 +30,4 @@ build/
- *.pts
- *.ppm
- *.mkv
-+*~
-Index: git/CMakeLists.txt
-===================================================================
---- git.orig/CMakeLists.txt
-+++ git/CMakeLists.txt
-@@ -24,6 +24,17 @@ include(makefiles/cmake/global_settings.
- include(makefiles/cmake/arm-linux.cmake)
- include(makefiles/cmake/vmcs.cmake)
- 
-+if (BUILD_WAYLAND)
-+   include(makefiles/cmake/Wayland.cmake)
-+
-+   # Find Wayland libraries
-+   find_package(PkgConfig)
-+   pkg_check_modules(WAYLAND_CLIENT wayland-client REQUIRED)
-+   pkg_check_modules(WAYLAND_SERVER wayland-server REQUIRED)
-+
-+   set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DBUILD_WAYLAND")
-+endif()
-+
- enable_language(ASM)
- 
- # Global include paths
-Index: git/README.md
-===================================================================
---- git.orig/README.md
-+++ git/README.md
-@@ -6,3 +6,7 @@ Use buildme to build. It requires cmake
- https://github.com/raspberrypi/tools/tree/master/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian
- 
- Note that this repository does not contain the source for the edid_parser and vcdbg binaries due to licensing restrictions.
-+
-+To build support for the Wayland winsys in EGL, execute the buildme script like this:
-+
-+$ BUILD_WAYLAND=1 ./buildme.
-Index: git/buildme
-===================================================================
---- git.orig/buildme
-+++ git/buildme
-@@ -8,6 +8,10 @@ fi
- 
- BUILDSUBDIR=`echo $BUILDTYPE | tr '[A-Z]' '[a-z]'`;
- 
-+if [ -n "$BUILD_WAYLAND" ]; then
-+       WAYLAND_VARS="-DBUILD_WAYLAND=TRUE"
-+fi
-+
- if [ "armv6l" = `arch` ] || [ "armv7l" = `arch` ]; then
- 	# Native compile on the Raspberry Pi
- 	mkdir -p build/raspberry/$BUILDSUBDIR
-@@ -32,9 +36,13 @@ elif [ "$1" = "--native" ]; then
- 	make -j `nproc` $*
- else
- 	# Cross compile on a more capable machine
-+	if [ -n "$BUILD_WAYLAND" ]; then
-+		# Use wayland-scanner from the build platform
-+		WAYLAND_VARS+=" -DWAYLAND_SCANNER_EXECUTABLE:FILEPATH=/usr/bin/wayland-scanner"
-+	fi
- 	mkdir -p build/arm-linux/$BUILDSUBDIR
- 	pushd build/arm-linux/$BUILDSUBDIR
--	cmake -DCMAKE_TOOLCHAIN_FILE=../../../makefiles/cmake/toolchains/arm-linux-gnueabihf.cmake -DCMAKE_BUILD_TYPE=$BUILDTYPE ../../..
-+	cmake -DCMAKE_TOOLCHAIN_FILE=../../../makefiles/cmake/toolchains/arm-linux-gnueabihf.cmake -DCMAKE_BUILD_TYPE=$BUILDTYPE $WAYLAND_VARS ../../..
- 	make -j `nproc`
- 
- 	if [ "$1" != "" ]; then
-Index: git/host_applications/linux/apps/raspicam/CMakeLists.txt
-===================================================================
---- git.orig/host_applications/linux/apps/raspicam/CMakeLists.txt
-+++ git/host_applications/linux/apps/raspicam/CMakeLists.txt
-@@ -28,7 +28,7 @@ add_executable(raspividyuv  ${COMMON_SOU
- 
- set (MMAL_LIBS mmal_core mmal_util mmal_vc_client)
- 
--target_link_libraries(raspistill ${MMAL_LIBS} vcos bcm_host brcmGLESv2 brcmEGL m)
-+target_link_libraries(raspistill ${MMAL_LIBS} vcos bcm_host brcmGLESv2 brcmEGL m ${WAYLAND_SERVER_LIBRARIES} ${WAYLAND_CLIENT_LIBRARIES})
- target_link_libraries(raspiyuv   ${MMAL_LIBS} vcos bcm_host)
- target_link_libraries(raspivid   ${MMAL_LIBS} vcos bcm_host)
- target_link_libraries(raspividyuv   ${MMAL_LIBS} vcos bcm_host)
-Index: git/interface/khronos/CMakeLists.txt
-===================================================================
---- git.orig/interface/khronos/CMakeLists.txt
-+++ git/interface/khronos/CMakeLists.txt
-@@ -6,6 +6,12 @@
- # have quite a few circular dependencies, and so the only way
- # to make it work seems to be to have everything static.
- 
-+if (BUILD_WAYLAND)
-+include_directories(
-+   ${WAYLAND_SERVER_INCLUDE_DIRS}
-+)
-+endif ()
-+
- set(EGL_SOURCE
-    egl/egl_client_config.c
-    egl/egl_client_context.c
-@@ -55,12 +61,55 @@ set(CLIENT_SOURCE
-    common/khrn_int_hash_asm.s
-    common/khrn_client_cache.c)
- 
-+set(EGL_LIBS
-+   khrn_client
-+   vchiq_arm
-+   vcos
-+   bcm_host)
-+
-+if (BUILD_WAYLAND)
-+   set(EGL_SOURCE
-+      ${EGL_SOURCE}
-+      ext/egl_wayland.c
-+      common/linux/khrn_wayland.c)
-+
-+   set(EGL_LIBS
-+      ${EGL_LIBS}
-+      wayland-client
-+      wayland-server)
-+
-+   set(WAYLAND_EGL_SOURCE
-+      wayland-egl/wayland-egl.c)
-+
-+   wayland_add_protocol_server(
-+       EGL_SOURCE
-+       ../../interface/wayland/dispmanx.xml
-+       dispmanx
-+   )
-+
-+   wayland_add_protocol_client(
-+       EGL_SOURCE
-+       ../../interface/wayland/dispmanx.xml
-+       dispmanx
-+   )
-+
-+   add_library(wayland-egl ${SHARED} ${WAYLAND_EGL_SOURCE})
-+   install(TARGETS wayland-egl DESTINATION lib)
-+
-+   configure_file ("wayland-egl/wayland-egl.pc.in" "wayland-egl/wayland-egl.pc" @ONLY)
-+   install (FILES "${CMAKE_CURRENT_BINARY_DIR}/wayland-egl/wayland-egl.pc"
-+            DESTINATION lib/pkgconfig)
-+endif ()
-+
- add_library(EGL ${SHARED} ${EGL_SOURCE})
- add_library(GLESv2 ${SHARED} ${GLES_SOURCE})
- add_library(OpenVG ${SHARED} ${VG_SOURCE})
- add_library(WFC ${SHARED} ${WFC_SOURCE})
- add_library(khrn_client ${CLIENT_SOURCE})
- 
-+set_target_properties(EGL PROPERTIES SOVERSION 1 VERSION 1.0.0)
-+set_target_properties(GLESv2 PROPERTIES SOVERSION 2 VERSION 2.0.0)
-+
- # TODO do we need EGL_static and GLESv2_static now that khrn_static exists?
- add_library(EGL_static STATIC ${EGL_SOURCE})
- add_library(GLESv2_static STATIC ${GLES_SOURCE})
-@@ -72,8 +121,7 @@ include_directories (../../host_applicat
- set(VCSM_LIBS vcsm)
- add_definitions(-DKHRONOS_HAVE_VCSM)
- endif()
--
--target_link_libraries(EGL khrn_client vchiq_arm vcos bcm_host ${VCSM_LIBS} -lm)
-+target_link_libraries(EGL ${EGL_LIBS} ${VCSM_LIBS} -lm)
- target_link_libraries(GLESv2 EGL khrn_client vcos)
- target_link_libraries(WFC EGL)
- target_link_libraries(OpenVG EGL)
-@@ -87,7 +135,7 @@ add_library(brcmGLESv2 ${SHARED} ${GLES_
- add_library(brcmOpenVG ${SHARED} ${VG_SOURCE})
- add_library(brcmWFC ${SHARED} ${WFC_SOURCE})
- 
--target_link_libraries(brcmEGL khrn_client vchiq_arm vcos bcm_host ${VCSM_LIBS} -lm)
-+target_link_libraries(brcmEGL ${EGL_LIBS} ${VCSM_LIBS} -lm)
- target_link_libraries(brcmGLESv2 brcmEGL khrn_client vcos)
- target_link_libraries(brcmWFC brcmEGL)
- target_link_libraries(brcmOpenVG brcmEGL)
-Index: git/interface/khronos/common/khrn_client.c
-===================================================================
---- git.orig/interface/khronos/common/khrn_client.c
-+++ git/interface/khronos/common/khrn_client.c
-@@ -54,6 +54,10 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBI
- #include "applications/vmcs/khronos/khronos_server.h"
- #endif
- 
-+#ifdef BUILD_WAYLAND
-+#include "interface/khronos/common/linux/khrn_wayland.h"
-+#endif
-+
- VCOS_LOG_CAT_T khrn_client_log = VCOS_LOG_INIT("khrn_client", VCOS_LOG_WARN);
- 
- /*
-@@ -142,6 +146,10 @@ void client_try_unload_server(CLIENT_PRO
- bool client_process_state_init(CLIENT_PROCESS_STATE_T *process)
- {
-    if (!process->inited) {
-+#ifdef BUILD_WAYLAND
-+      process->wl_global = NULL;
-+#endif
-+
-       if (!khrn_pointer_map_init(&process->contexts, 64))
-          return false;
- 
-@@ -194,6 +202,13 @@ bool client_process_state_init(CLIENT_PR
-       }
- #endif
- 
-+#ifdef BUILD_WAYLAND
-+      struct wl_display *wl_display = khrn_platform_get_wl_display();
-+      if (wl_display)
-+         if (!init_process_wayland(process))
-+            return false;
-+#endif
-+
-       process->inited = true;
-    }
- 
-Index: git/interface/khronos/common/khrn_client.h
-===================================================================
---- git.orig/interface/khronos/common/khrn_client.h
-+++ git/interface/khronos/common/khrn_client.h
-@@ -310,6 +310,16 @@ struct CLIENT_PROCESS_STATE {
- #ifdef RPC_LIBRARY
-    KHRONOS_SERVER_CONNECTION_T khrn_connection;
- #endif
-+
-+#ifdef BUILD_WAYLAND
-+   /* Client-side Wayland state */
-+   struct wl_registry *wl_registry;
-+   struct wl_dispmanx *wl_dispmanx;
-+   struct wl_event_queue *wl_queue;
-+
-+   /* Compositor-side Wayland state */
-+   struct wl_global *wl_global;
-+#endif
- };
- 
- extern bool client_process_state_init(CLIENT_PROCESS_STATE_T *process);
-Index: git/interface/khronos/common/khrn_client_mangle.h
-===================================================================
---- git.orig/interface/khronos/common/khrn_client_mangle.h
-+++ git/interface/khronos/common/khrn_client_mangle.h
-@@ -83,6 +83,9 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBI
- #define eglReleaseGlobalImageBRCM mangled_eglReleaseGlobalImageBRCM
- #define eglInitGlobalImageBRCM mangled_eglInitGlobalImageBRCM
- #define eglTermGlobalImageBRCM mangled_eglTermGlobalImageBRCM
-+#define eglBindWaylandDisplayWL mangled_eglBindWaylandDisplayWL
-+#define eglUnbindWaylandDisplayWL mangled_eglUnbindWaylandDisplayWL
-+#define eglQueryWaylandBufferWL mangled_eglQueryWaylandBufferWL
- 
- /* OpenGL ES 1.1 and 2.0 functions */
- 
-Index: git/interface/khronos/common/khrn_client_platform.h
-===================================================================
---- git.orig/interface/khronos/common/khrn_client_platform.h
-+++ git/interface/khronos/common/khrn_client_platform.h
-@@ -48,6 +48,10 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBI
- #include "interface/khronos/common/vcos/khrn_client_platform_filler_vcos.h"
- #endif
- 
-+#ifdef BUILD_WAYLAND
-+#include <wayland-client.h>
-+#endif
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
-@@ -328,4 +332,8 @@ typedef struct
- 
- void *platform_wfc_bounce_thread(void *param);
- 
-+#ifdef BUILD_WAYLAND
-+struct wl_display *khrn_platform_get_wl_display();
-+#endif
-+
- #endif // KHRN_CLIENT_PLATFORM_H
-Index: git/interface/khronos/common/khrn_client_unmangle.h
-===================================================================
---- git.orig/interface/khronos/common/khrn_client_unmangle.h
-+++ git/interface/khronos/common/khrn_client_unmangle.h
-@@ -83,6 +83,9 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBI
- #undef eglReleaseGlobalImageBRCM
- #undef eglInitGlobalImageBRCM
- #undef eglTermGlobalImageBRCM
-+#undef eglBindWaylandDisplayWL
-+#undef eglUnbindWaylandDisplayWL
-+#undef eglQueryWaylandBufferWL
- 
- /* OpenGL ES 1.1 and 2.0 functions */
- 
-Index: git/interface/khronos/common/linux/khrn_client_platform_linux.c
-===================================================================
---- git.orig/interface/khronos/common/linux/khrn_client_platform_linux.c
-+++ git/interface/khronos/common/linux/khrn_client_platform_linux.c
-@@ -37,6 +37,11 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBI
- #include "X11/Xlib.h"
- #endif
- 
-+#ifdef BUILD_WAYLAND
-+#include <wayland-client.h>
-+#include "interface/khronos/wayland-egl/wayland-egl-priv.h"
-+#endif
-+
- extern VCOS_LOG_CAT_T khrn_client_log;
- 
- extern void vc_vchi_khronos_init();
-@@ -464,14 +469,37 @@ EGLDisplay khrn_platform_set_display_id(
- 	   return EGL_NO_DISPLAY;
- }
- #else
-+
-+#ifdef BUILD_WAYLAND
-+static struct wl_display *hacky_display = NULL;
-+#endif
-+
- EGLDisplay khrn_platform_set_display_id(EGLNativeDisplayType display_id)
- {
-    if (display_id == EGL_DEFAULT_DISPLAY)
-       return (EGLDisplay)1;
--   else
--      return EGL_NO_DISPLAY;
-+   else {
-+#ifdef BUILD_WAYLAND
-+      void *first_pointer = *(void **) display_id;
-+
-+      /* wl_display is a wl_proxy, which is a wl_object.
-+       * wl_object's first element points to the interfacetype. */
-+      if (first_pointer == &wl_display_interface) {
-+         hacky_display = (struct wl_display*)display_id;
-+         return (EGLDisplay)1;
-+      } else
-+#endif
-+         return EGL_NO_DISPLAY;
-+   }
-+}
-+
-+#ifdef BUILD_WAYLAND
-+struct wl_display *khrn_platform_get_wl_display()
-+{
-+   return hacky_display;
- }
- #endif
-+#endif
- 
- #ifdef WANT_X
- static void dump_hierarchy(Window w, Window thisw, Window look, int level)
-@@ -805,22 +833,81 @@ static EGL_DISPMANX_WINDOW_T *check_defa
- void platform_get_dimensions(EGLDisplay dpy, EGLNativeWindowType win,
-       uint32_t *width, uint32_t *height, uint32_t *swapchain_count)
- {
--   EGL_DISPMANX_WINDOW_T *dwin = check_default(win);
--   vcos_assert(dwin);
--   vcos_assert(dwin->width < 1<<16); // sanity check
--   vcos_assert(dwin->height < 1<<16); // sanity check
--   *width = dwin->width;
--   *height = dwin->height;
--   *swapchain_count = 0;
-+#ifdef BUILD_WAYLAND
-+   if(khrn_platform_get_wl_display()) {
-+      struct wl_egl_window *wl_egl_window = (struct wl_egl_window*)win;
-+      *width = wl_egl_window->width;
-+      *height = wl_egl_window->height;
-+      /* This seems to be used for sync'ing with the VC on buffer creation, but
-+         we are managing them on the CPU side */
-+      *swapchain_count = 1;
-+   } else {
-+#endif
-+      EGL_DISPMANX_WINDOW_T *dwin = check_default(win);
-+      vcos_assert(dwin);
-+      vcos_assert(dwin->width < 1<<16); // sanity check
-+      vcos_assert(dwin->height < 1<<16); // sanity check
-+      *width = dwin->width;
-+      *height = dwin->height;
-+      *swapchain_count = 0;
-+#ifdef BUILD_WAYLAND
-+   }
-+#endif
-+}
-+
-+#ifdef BUILD_WAYLAND
-+static DISPMANX_ELEMENT_HANDLE_T create_dummy_element()
-+{
-+   DISPMANX_DISPLAY_HANDLE_T display = vc_dispmanx_display_open(0);
-+   DISPMANX_UPDATE_HANDLE_T update = vc_dispmanx_update_start(0);
-+   DISPMANX_ELEMENT_HANDLE_T element;
-+   VC_DISPMANX_ALPHA_T alpha = {DISPMANX_FLAGS_ALPHA_FIXED_ALL_PIXELS, 255, 0};
-+   VC_RECT_T src_rect;
-+   VC_RECT_T dst_rect;
-+
-+   src_rect.x = 0;
-+   src_rect.y = 0;
-+   src_rect.width = 1 << 16;
-+   src_rect.height = 1 << 16;
-+
-+   dst_rect.x = 0;
-+   dst_rect.y = 0;
-+   dst_rect.width = 1;
-+   dst_rect.height = 1;
-+
-+   element = vc_dispmanx_element_add(update, display, 0/*layer*/, &dst_rect,
-+                                     0/*src*/, &src_rect,
-+                                     DISPMANX_PROTECTION_NONE, &alpha,
-+                                     0/*clamp*/, 0/*transform*/);
-+
-+   vc_dispmanx_update_submit_sync(update);
-+
-+   vc_dispmanx_display_close(display);
-+
-+   return element;
- }
-+#endif
- 
- uint32_t platform_get_handle(EGLDisplay dpy, EGLNativeWindowType win)
- {
--   EGL_DISPMANX_WINDOW_T *dwin = check_default(win);
--   vcos_assert(dwin);
--   vcos_assert(dwin->width < 1<<16); // sanity check
--   vcos_assert(dwin->height < 1<<16); // sanity check
--   return dwin->element;
-+#ifdef BUILD_WAYLAND
-+   if(khrn_platform_get_wl_display()) {
-+      struct wl_egl_window *wl_egl_window = (struct wl_egl_window*)win;
-+
-+      if (wl_egl_window->dummy_element == PLATFORM_WIN_NONE)
-+         wl_egl_window->dummy_element = create_dummy_element();
-+
-+      return wl_egl_window->dummy_element;
-+   } else {
-+#endif
-+      EGL_DISPMANX_WINDOW_T *dwin = check_default(win);
-+      vcos_assert(dwin);
-+      vcos_assert(dwin->width < 1<<16); // sanity check
-+      vcos_assert(dwin->height < 1<<16); // sanity check
-+      return dwin->element;
-+#ifdef BUILD_WAYLAND
-+   }
-+#endif
- }
- 
- #endif
-Index: git/interface/khronos/common/linux/khrn_wayland.c
-===================================================================
---- /dev/null
-+++ git/interface/khronos/common/linux/khrn_wayland.c
-@@ -0,0 +1,215 @@
-+/*
-+Copyright (c) 2013, Raspberry Pi Foundation
-+All rights reserved.
-+
-+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 copyright holder 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 HOLDER 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.
-+*/
-+
-+#define VCOS_LOG_CATEGORY (&khrn_client_log)
-+
-+#include "interface/khronos/common/linux/khrn_wayland.h"
-+#include "interface/khronos/wayland-dispmanx-client-protocol.h"
-+#include "interface/khronos/wayland-egl/wayland-egl-priv.h"
-+
-+extern VCOS_LOG_CAT_T khrn_client_log;
-+
-+static void handle_dispmanx_format(void *data, struct wl_dispmanx *dispmanx,
-+                                   uint32_t format)
-+{
-+}
-+
-+static void handle_dispmanx_allocated(void *data, struct wl_dispmanx *dispmanx,
-+                                      struct wl_buffer *wl_buffer,
-+                                      uint32_t resource_handle)
-+{
-+    struct wl_dispmanx_client_buffer *buffer = wl_buffer_get_user_data(wl_buffer);
-+
-+    buffer->pending_allocation = 0;
-+    buffer->resource = resource_handle;
-+}
-+
-+static const struct wl_dispmanx_listener dispmanx_listener = {
-+    handle_dispmanx_format,
-+    handle_dispmanx_allocated,
-+};
-+
-+static void
-+sync_callback(void *data, struct wl_callback *callback, uint32_t serial)
-+{
-+   int *done = data;
-+
-+   *done = 1;
-+
-+   wl_callback_destroy(callback);
-+}
-+
-+static const struct wl_callback_listener sync_listener = {
-+   sync_callback
-+};
-+
-+static int
-+roundtrip(CLIENT_PROCESS_STATE_T *process)
-+{
-+   struct wl_display *wl_display = khrn_platform_get_wl_display();
-+   struct wl_callback *callback;
-+   int done = 0, ret = 0;
-+
-+   callback = wl_display_sync(wl_display);
-+   wl_callback_add_listener(callback, &sync_listener, &done);
-+   wl_proxy_set_queue((struct wl_proxy *) callback, process->wl_queue);
-+   while (ret != -1 && !done)
-+      ret = wl_display_dispatch_queue(wl_display, process->wl_queue);
-+
-+   if (!done)
-+      wl_callback_destroy(callback);
-+
-+   return ret;
-+}
-+
-+int do_wl_roundtrip()
-+{
-+   CLIENT_PROCESS_STATE_T *process = CLIENT_GET_PROCESS_STATE();
-+   return roundtrip(process);
-+}
-+
-+static void
-+registry_handle_global(void *data, struct wl_registry *registry,
-+                       uint32_t name, const char *interface, uint32_t version)
-+{
-+   struct wl_display *wl_display = khrn_platform_get_wl_display();
-+   CLIENT_PROCESS_STATE_T *process = (CLIENT_PROCESS_STATE_T *)data;
-+
-+   if (strcmp(interface, "wl_dispmanx") == 0) {
-+      process->wl_dispmanx = wl_registry_bind(registry, name,
-+	       &wl_dispmanx_interface, 1);
-+
-+      wl_proxy_set_queue((struct wl_proxy *) process->wl_dispmanx,
-+                         process->wl_queue);
-+      wl_dispmanx_add_listener(process->wl_dispmanx, &dispmanx_listener, wl_display);
-+      roundtrip(process);
-+   }
-+}
-+
-+static void
-+registry_handle_global_remove(void *data, struct wl_registry *registry,
-+                              uint32_t name)
-+{
-+}
-+
-+static const struct wl_registry_listener registry_listener = {
-+	registry_handle_global,
-+	registry_handle_global_remove
-+};
-+
-+int
-+init_process_wayland(CLIENT_PROCESS_STATE_T *process)
-+{
-+    struct wl_display *wl_display = khrn_platform_get_wl_display();
-+
-+    process->wl_queue = wl_display_create_queue(wl_display);
-+    if (!process->wl_queue) {
-+        vcos_log_error("wl_display_create_queue failed\n");
-+        return false;
-+    }
-+    wl_display_dispatch_pending(wl_display);
-+
-+    process->wl_registry = wl_display_get_registry(wl_display);
-+    if (!process->wl_registry) {
-+        vcos_log_error("wl_display_get_registry failed\n");
-+        return false;
-+    }
-+
-+    wl_proxy_set_queue((struct wl_proxy *) process->wl_registry,
-+    process->wl_queue);
-+
-+    wl_registry_add_listener(process->wl_registry, &registry_listener, process);
-+
-+    if (roundtrip(process) < 0 || process->wl_dispmanx == NULL) {
-+        vcos_log_error("failed to get wl_dispmanx\n");
-+        return false;
-+    }
-+
-+    return true;
-+}
-+
-+#ifndef ALIGN_UP
-+#define ALIGN_UP(x,y)  ((x + (y)-1) & ~((y)-1))
-+#endif
-+
-+static void handle_buffer_release(void *data, struct wl_buffer *buffer_wl)
-+{
-+   struct wl_dispmanx_client_buffer *wl_dispmanx_client_buffer = data;
-+   wl_dispmanx_client_buffer->in_use = 0;
-+}
-+
-+static const struct wl_buffer_listener buffer_listener = {
-+   handle_buffer_release
-+};
-+
-+struct wl_dispmanx_client_buffer *
-+allocate_wl_buffer(struct wl_egl_window *window, KHRN_IMAGE_FORMAT_T color)
-+{
-+   CLIENT_PROCESS_STATE_T *process = CLIENT_GET_PROCESS_STATE();
-+   struct wl_dispmanx_client_buffer *wl_dispmanx_client_buffer;
-+   struct wl_buffer *wl_buffer;
-+   uint32_t stride = ALIGN_UP(window->width * 4, 16);
-+   uint32_t buffer_height = ALIGN_UP(window->height, 16);
-+   enum wl_dispmanx_format color_format;
-+   int ret = 0;
-+
-+   switch (color) {
-+   case ABGR_8888:
-+      color_format = WL_DISPMANX_FORMAT_ABGR8888;
-+      break;
-+   case XBGR_8888:
-+      color_format = WL_DISPMANX_FORMAT_XBGR8888;
-+      break;
-+   case RGB_565:
-+      color_format = WL_DISPMANX_FORMAT_RGB565;
-+      break;
-+   default:
-+      vcos_log_error("unknown KHRN_IMAGE_FORMAT_T 0x%x\n", color);
-+      return NULL;
-+   }
-+
-+   wl_buffer = wl_dispmanx_create_buffer(process->wl_dispmanx, window->width,
-+                                         window->height, stride, buffer_height,
-+                                         color_format);
-+   if (wl_buffer == NULL)
-+      return NULL;
-+
-+   wl_dispmanx_client_buffer = calloc(1, sizeof(struct wl_dispmanx_client_buffer));
-+   wl_dispmanx_client_buffer->wl_buffer = wl_buffer;
-+   wl_dispmanx_client_buffer->in_use = 0;
-+   wl_dispmanx_client_buffer->pending_allocation = 1;
-+   wl_dispmanx_client_buffer->width = window->width;
-+   wl_dispmanx_client_buffer->height = window->height;
-+
-+   wl_proxy_set_queue((struct wl_proxy *) wl_buffer, process->wl_queue);
-+   wl_buffer_add_listener(wl_buffer, &buffer_listener, wl_dispmanx_client_buffer);
-+
-+   while (ret != -1 && wl_dispmanx_client_buffer->pending_allocation)
-+      ret = do_wl_roundtrip();
-+
-+   return wl_dispmanx_client_buffer;
-+}
-Index: git/interface/vmcs_host/vc_vchi_dispmanx.h
-===================================================================
---- git.orig/interface/vmcs_host/vc_vchi_dispmanx.h
-+++ git/interface/vmcs_host/vc_vchi_dispmanx.h
-@@ -66,4 +66,19 @@ typedef struct {
- #define ELEMENT_CHANGE_MASK_RESOURCE  (1<<4)
- #define ELEMENT_CHANGE_TRANSFORM      (1<<5)
- 
-+#ifdef BUILD_WAYLAND
-+/* XXX: This should be in a private header that can be included from EGL and vc_* */
-+#include <wayland-server.h>
-+#include "interface/vmcs_host/wayland-dispmanx-server-protocol.h"
-+struct wl_dispmanx_server_buffer {
-+	struct wl_resource *resource;
-+	struct wl_dispmanx *dispmanx;
-+	enum wl_dispmanx_format format;
-+	DISPMANX_RESOURCE_HANDLE_T handle;
-+	int32_t width;
-+	int32_t height;
-+	int in_use;
-+};
-+#endif
-+
- #endif
-Index: git/interface/khronos/common/linux/khrn_wayland.h
-===================================================================
---- /dev/null
-+++ git/interface/khronos/common/linux/khrn_wayland.h
-@@ -0,0 +1,33 @@
-+/*
-+Copyright (c) 2013, Raspberry Pi Foundation
-+All rights reserved.
-+
-+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 copyright holder 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 HOLDER 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.
-+*/
-+
-+#include "interface/khronos/common/khrn_client.h"
-+
-+int init_process_wayland(CLIENT_PROCESS_STATE_T *process);
-+int do_wl_roundtrip();
-+
-+struct wl_dispmanx_client_buffer *allocate_wl_buffer(struct wl_egl_window *window, KHRN_IMAGE_FORMAT_T color);
-Index: git/interface/khronos/egl/egl_client.c
-===================================================================
---- git.orig/interface/khronos/egl/egl_client.c
-+++ git/interface/khronos/egl/egl_client.c
-@@ -153,6 +153,10 @@ by an attribute value"
- #include <stdlib.h>
- #include <string.h>
- 
-+#ifdef BUILD_WAYLAND
-+#include "interface/khronos/wayland-egl/wayland-egl-priv.h"
-+#include "interface/khronos/common/linux/khrn_wayland.h"
-+#endif
- 
- #include "interface/khronos/egl/egl_client_cr.c"
- 
-@@ -162,17 +166,6 @@ static void egl_current_release(CLIENT_P
- void egl_gl_flush_callback(bool wait);
- void egl_vg_flush_callback(bool wait);
- 
--#include "interface/vmcs_host/vc_dispmanx_types.h"
--/**HACKHACK - give us the ability to inject a DispmanX 
-- * resource handle into the CreateWindowSurface and 
-- * SwapBuffers calls */ 
--static DISPMANX_RESOURCE_HANDLE_T next_resource_handle;
--
--EGLAPI EGLBoolean EGLAPIENTRY eglSetNextResourceHandle(DISPMANX_RESOURCE_HANDLE_T handle)
--{
--   next_resource_handle = handle;
--}
--
- /*
- TODO: do an RPC call to make sure the Khronos vll is loaded (and that it stays loaded until eglTerminate)
- Also affects global image (and possibly others?)
-@@ -451,6 +444,9 @@ EGLAPI const char EGLAPIENTRY * eglQuery
-             "EGL_KHR_fence_sync "
- #endif
- #endif
-+#if EGL_WL_bind_wayland_display
-+            "EGL_WL_bind_wayland_display "
-+#endif
-             ;
-          break;
-       case EGL_VENDOR:
-@@ -655,8 +651,7 @@ EGLAPI EGLSurface EGLAPIENTRY eglCreateW
-                                 false,
-                                 EGL_NO_TEXTURE,
-                                 EGL_NO_TEXTURE,
--                                0, 0,
--                                next_resource_handle);
-+                                0, 0);
- 
-                if (surface) {
-                   if (khrn_pointer_map_insert(&process->surfaces, process->next_surface, surface)) {
-@@ -901,7 +896,7 @@ EGLAPI EGLSurface EGLAPIENTRY eglCreateP
-                              mipmap_texture,
-                              texture_format,
-                              texture_target,
--                             0, 0, 0);
-+                             0, 0);
- 
-             if (surface) {
-                if (khrn_pointer_map_insert(&process->surfaces, process->next_surface, surface)) {
-@@ -1043,7 +1038,7 @@ EGLAPI EGLSurface EGLAPIENTRY eglCreateP
-                                    false,
-                                    EGL_NO_TEXTURE,
-                                    EGL_NO_TEXTURE,
--                                   pixmap, ((server_handle[0] == 0) && (server_handle[1] == (uint32_t)(-1))) ? NULL : server_handle, 0);
-+                                   pixmap, ((server_handle[0] == 0) && (server_handle[1] == (uint32_t)(-1))) ? NULL : server_handle);
- 
-                      if (surface) {
-                         if (khrn_pointer_map_insert(&process->surfaces, process->next_surface, surface)) {
-@@ -2245,6 +2240,9 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuf
-    CLIENT_THREAD_STATE_T *thread;
-    CLIENT_PROCESS_STATE_T *process;
-    EGLBoolean result;
-+#ifdef BUILD_WAYLAND
-+   struct wl_display *wl_display = khrn_platform_get_wl_display();
-+#endif
- 
-    vcos_log_trace("eglSwapBuffers start. dpy=%d. surf=%d.", (int)dpy, (int)surf);
- 
-@@ -2315,18 +2313,58 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuf
- 
-                vcos_log_trace("eglSwapBuffers server call");
- 
--               if (next_resource_handle)
--               RPC_CALL7(eglIntSwapBuffers_impl,
--                     thread,
--                     EGLINTSWAPBUFFERS_ID_V2,
--                     RPC_UINT(surface->serverbuffer),
--                     RPC_UINT(surface->width),
--                     RPC_UINT(surface->height),
--                     RPC_UINT(surface->internal_handle),
--                     RPC_UINT(surface->swap_behavior == EGL_BUFFER_PRESERVED ? 1 : 0),
--                     RPC_UINT(khrn_platform_get_window_position(surface->win)),
--                     RPC_INT(next_resource_handle));
--               else
-+#ifdef BUILD_WAYLAND
-+               if (wl_display) {
-+                  struct wl_egl_window *wl_egl_window = surface->wl_egl_window;
-+                  struct wl_dispmanx_client_buffer *buffer_temp;
-+                  uint32_t configid;
-+                  KHRN_IMAGE_FORMAT_T color;
-+                  int ret = 0;
-+
-+                  buffer_temp = surface->front_wl_buffer;
-+                  surface->front_wl_buffer = surface->back_wl_buffer;
-+                  surface->back_wl_buffer = buffer_temp;
-+
-+                  configid = egl_config_to_id(surface->config);
-+                  color = egl_config_get_color_format(configid);
-+
-+                  if (surface->back_wl_buffer == NULL)
-+                     surface->back_wl_buffer = allocate_wl_buffer(wl_egl_window, color);
-+                  else if (surface->back_wl_buffer->width != width ||
-+                           surface->back_wl_buffer->height != height) {
-+
-+                     struct wl_dispmanx_client_buffer *buffer;
-+
-+                     wl_buffer_destroy(surface->back_wl_buffer->wl_buffer);
-+                     free(surface->back_wl_buffer);
-+
-+                     buffer = allocate_wl_buffer(wl_egl_window, color);
-+                     surface->back_wl_buffer = buffer;
-+                  }
-+
-+                  RPC_CALL7(eglIntSwapBuffers_impl,
-+                        thread,
-+                        EGLINTSWAPBUFFERS_ID_V2,
-+                        RPC_UINT(surface->serverbuffer),
-+                        RPC_UINT(surface->width),
-+                        RPC_UINT(surface->height),
-+                        RPC_UINT(surface->internal_handle),
-+                        RPC_UINT(surface->swap_behavior == EGL_BUFFER_PRESERVED ? 1 : 0),
-+                        RPC_UINT(khrn_platform_get_window_position(surface->win)),
-+                        RPC_INT(surface->back_wl_buffer->resource));
-+
-+                  surface->front_wl_buffer->in_use = 1;
-+                  wl_surface_attach(wl_egl_window->wl_surface,
-+                                    surface->front_wl_buffer->wl_buffer,
-+                                    0, 0);
-+                  wl_surface_damage(wl_egl_window->wl_surface, 0, 0,
-+                                    surface->width, surface->height);
-+                  wl_surface_commit(wl_egl_window->wl_surface);
-+
-+                  while(ret != -1 && surface->back_wl_buffer->in_use)
-+                     ret = wl_display_dispatch_queue(wl_display, process->wl_queue);
-+               } else
-+#endif
-                RPC_CALL6(eglIntSwapBuffers_impl,
-                      thread,
-                      EGLINTSWAPBUFFERS_ID,
-Index: git/interface/khronos/egl/egl_client_get_proc.c
-===================================================================
---- git.orig/interface/khronos/egl/egl_client_get_proc.c
-+++ git/interface/khronos/egl/egl_client_get_proc.c
-@@ -254,6 +254,17 @@ EGLAPI void EGLAPIENTRY (* eglGetProcAdd
-       return (void(*)(void))eglQueryGlobalImageBRCM;
- #endif
- 
-+#ifdef BUILD_WAYLAND
-+#if EGL_WL_bind_wayland_display
-+   if (!strcmp(procname, "eglBindWaylandDisplayWL"))
-+      return (void(*)(void))eglBindWaylandDisplayWL;
-+   if (!strcmp(procname, "eglUnbindWaylandDisplayWL"))
-+      return (void(*)(void))eglUnbindWaylandDisplayWL;
-+   if (!strcmp(procname, "eglQueryWaylandBufferWL"))
-+      return (void(*)(void))eglQueryWaylandBufferWL;
-+#endif
-+#endif
-+
-    return (void(*)(void)) NULL;
- }
- 
-Index: git/interface/khronos/egl/egl_client_surface.c
-===================================================================
---- git.orig/interface/khronos/egl/egl_client_surface.c
-+++ git/interface/khronos/egl/egl_client_surface.c
-@@ -46,6 +46,11 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBI
- #include "interface/khronos/egl/egl_int_impl.h"
- #endif
- 
-+#ifdef BUILD_WAYLAND
-+#include "interface/khronos/wayland-egl/wayland-egl-priv.h"
-+#include "interface/khronos/common/linux/khrn_wayland.h"
-+#endif
-+
- #include <stdlib.h>
- 
- 
-@@ -314,8 +319,7 @@ EGL_SURFACE_T *egl_surface_create(
-    EGLenum texture_format,
-    EGLenum texture_target,
-    EGLNativePixmapType pixmap,
--   const uint32_t *pixmap_server_handle,
--   DISPMANX_RESOURCE_HANDLE_T next_resource_handle)
-+   const uint32_t *pixmap_server_handle)
- {
-    KHRN_IMAGE_FORMAT_T color;
-    KHRN_IMAGE_FORMAT_T depth;
-@@ -326,6 +330,10 @@ EGL_SURFACE_T *egl_surface_create(
-    EGLint   config_depth_bits;
-    EGLint   config_stencil_bits;
-    CLIENT_THREAD_STATE_T *thread = CLIENT_GET_THREAD_STATE();
-+#ifdef BUILD_WAYLAND
-+   struct wl_display *wl_display = khrn_platform_get_wl_display();
-+   DISPMANX_RESOURCE_HANDLE_T resource;
-+#endif
- 
-    EGL_SURFACE_T *surface = egl_surface_pool_alloc();
- 
-@@ -390,6 +398,18 @@ EGL_SURFACE_T *egl_surface_create(
- 
-    vcos_assert(color != IMAGE_FORMAT_INVALID);
- 
-+#ifdef BUILD_WAYLAND
-+   if (type == WINDOW && wl_display) {
-+      surface->wl_egl_window = (struct wl_egl_window*)win;
-+      surface->back_wl_buffer = allocate_wl_buffer(
-+            surface->wl_egl_window, color);
-+      resource = surface->back_wl_buffer->resource;
-+   } else {
-+      surface->wl_egl_window = NULL;
-+      resource = DISPMANX_NO_HANDLE;
-+   }
-+#endif
-+
- #ifdef KHRONOS_EGL_PLATFORM_OPENWFC
-    // Create stream for this window
-    if(type != PBUFFER)
-@@ -474,7 +494,8 @@ EGL_SURFACE_T *egl_surface_create(
- #endif
-          uint32_t results[3];
- 
--         if (next_resource_handle)
-+#ifdef BUILD_WAYLAND
-+         if (resource != DISPMANX_NO_HANDLE)
-          RPC_CALL16_OUT_CTRL(eglIntCreateSurface_impl,
-                              thread,
-                              EGLINTCREATESURFACE_ID_V2,
-@@ -492,9 +513,10 @@ EGL_SURFACE_T *egl_surface_create(
-                              RPC_UINT(config_stencil_bits),
-                              RPC_UINT(sem_name),
-                              RPC_UINT(type),
--                             RPC_INT(next_resource_handle),
-+                             RPC_INT(resource),
-                              results);
-          else
-+#endif
-          RPC_CALL15_OUT_CTRL(eglIntCreateSurface_impl,
-                              thread,
-                              EGLINTCREATESURFACE_ID,
-@@ -663,6 +685,18 @@ void egl_surface_free(EGL_SURFACE_T *sur
-    if( surface->type == WINDOW ) {
-       vcos_log_trace("egl_surface_free: calling platform_destroy_winhandle...");
-       platform_destroy_winhandle( surface->win, surface->internal_handle );
-+
-+#ifdef BUILD_WAYLAND
-+      if (surface->back_wl_buffer) {
-+         wl_buffer_destroy(surface->back_wl_buffer->wl_buffer);
-+         free(surface->back_wl_buffer);
-+      }
-+
-+      if (surface->front_wl_buffer) {
-+         wl_buffer_destroy(surface->front_wl_buffer->wl_buffer);
-+         free(surface->front_wl_buffer);
-+      }
-+#endif
-    }
-    /* return value ignored -- read performed to ensure blocking. we want this to
-     * block so clients can safely destroy the surface's window as soon as the
-Index: git/interface/khronos/egl/egl_client_surface.h
-===================================================================
---- git.orig/interface/khronos/egl/egl_client_surface.h
-+++ git/interface/khronos/egl/egl_client_surface.h
-@@ -288,6 +288,41 @@ typedef struct {
-       type == PIXMAP
-    */
-    bool server_owned;
-+
-+#ifdef BUILD_WAYLAND
-+   /*
-+      wl_egl_window
-+
-+      Validity:
-+      type == WINDOW
-+
-+      Invariant:
-+      wayland EGL window
-+   */
-+   struct wl_egl_window *wl_egl_window;
-+
-+   /*
-+      front_wl_buffer
-+
-+      Validity:
-+      type == WINDOW
-+
-+      Invariant:
-+      client-side information about the wl_buffer in the front
-+   */
-+   struct wl_dispmanx_client_buffer *front_wl_buffer;
-+
-+   /*
-+      back_wl_buffer
-+
-+      Validity:
-+      type == WINDOW
-+
-+      Invariant:
-+      client-side information about the wl_buffer in the back
-+   */
-+   struct wl_dispmanx_client_buffer *back_wl_buffer;
-+#endif
- } EGL_SURFACE_T;
- 
- extern bool egl_surface_check_attribs(
-@@ -322,8 +357,7 @@ extern EGL_SURFACE_T *egl_surface_create
-    EGLenum texture_format,
-    EGLenum texture_target,
-    EGLNativePixmapType pixmap,
--   const uint32_t *pixmap_server_handle,
--   DISPMANX_RESOURCE_HANDLE_T next_resource_handle);
-+   const uint32_t *pixmap_server_handle);
- extern EGL_SURFACE_T *egl_surface_from_vg_image(
-    VGImage vg_handle,
-    EGLSurface name,
-Index: git/interface/khronos/egl/egl_int_impl.h
-===================================================================
---- git.orig/interface/khronos/egl/egl_int_impl.h
-+++ git/interface/khronos/egl/egl_int_impl.h
-@@ -57,7 +57,7 @@ FN(int, eglIntCreateSurface_impl, (
-    uint32_t sem,
-    uint32_t type,
-    uint32_t *results,
--   DISPMANX_RESOURCE_HANDLE_T next_resource_handle))
-+   DISPMANX_RESOURCE_HANDLE_T resource_handle))
- 
- FN(int, eglIntCreatePbufferFromVGImage_impl, (
-    VGImage vg_handle,
-Index: git/interface/khronos/ext/egl_wayland.c
-===================================================================
---- /dev/null
-+++ git/interface/khronos/ext/egl_wayland.c
-@@ -0,0 +1,246 @@
-+/*
-+Copyright (c) 2013, Raspberry Pi Foundation
-+All rights reserved.
-+
-+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 copyright holder 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 HOLDER 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.
-+*/
-+
-+#include "interface/khronos/common/khrn_client_mangle.h"
-+#include "interface/khronos/common/khrn_client_rpc.h"
-+
-+#include "interface/khronos/ext/egl_khr_sync_client.h"
-+#include "interface/khronos/include/EGL/egl.h"
-+#include "interface/khronos/include/EGL/eglext.h"
-+
-+#include "interface/vmcs_host/vc_vchi_dispmanx.h"
-+
-+#include <wayland-server.h>
-+#include "interface/khronos/wayland-dispmanx-server-protocol.h"
-+
-+static void
-+destroy_buffer(struct wl_resource *resource)
-+{
-+   struct wl_dispmanx_server_buffer *buffer = wl_resource_get_user_data(resource);
-+
-+   if(!buffer->in_use)
-+      vc_dispmanx_resource_delete(buffer->handle);
-+
-+   free(buffer);
-+}
-+
-+static void
-+buffer_destroy(struct wl_client *client, struct wl_resource *resource)
-+{
-+   wl_resource_destroy(resource);
-+}
-+
-+static const struct wl_buffer_interface dispmanx_buffer_interface = {
-+   buffer_destroy
-+};
-+
-+static VC_IMAGE_TYPE_T
-+get_vc_format(enum wl_dispmanx_format format)
-+{
-+	/* XXX: The app is likely to have been premultiplying in its shaders,
-+	 * but the VC scanout hardware on the RPi cannot mix premultiplied alpha
-+	 * channel with the element's alpha.
-+	 */
-+	switch (format) {
-+	case WL_DISPMANX_FORMAT_ABGR8888:
-+		return VC_IMAGE_RGBA32;
-+	case WL_DISPMANX_FORMAT_XBGR8888:
-+		return VC_IMAGE_BGRX8888;
-+	case WL_DISPMANX_FORMAT_RGB565:
-+		return VC_IMAGE_RGB565;
-+	default:
-+		/* invalid format */
-+		return VC_IMAGE_MIN;
-+	}
-+}
-+
-+static void
-+dispmanx_create_buffer(struct wl_client *client, struct wl_resource *resource,
-+                       uint32_t id, int32_t width, int32_t height,
-+                       uint32_t stride, uint32_t buffer_height, uint32_t format)
-+{
-+   struct wl_dispmanx_server_buffer *buffer;
-+   VC_IMAGE_TYPE_T vc_format = get_vc_format(format);
-+   uint32_t dummy;
-+
-+   if(vc_format == VC_IMAGE_MIN) {
-+      wl_resource_post_error(resource,
-+                             WL_DISPMANX_ERROR_INVALID_FORMAT,
-+                             "invalid format");
-+      return;
-+   }
-+
-+   buffer = calloc(1, sizeof *buffer);
-+   if (buffer == NULL) {
-+      wl_resource_post_no_memory(resource);
-+      return;
-+   }
-+
-+   buffer->handle = vc_dispmanx_resource_create(vc_format,
-+                                                width | (stride << 16),
-+                                                height | (buffer_height << 16),
-+                                                &dummy);
-+   if(buffer->handle == DISPMANX_NO_HANDLE) {
-+      wl_resource_post_error(resource,
-+                             WL_DISPMANX_ERROR_ALLOC_FAILED,
-+                             "allocation failed");
-+      free(buffer);
-+      return;
-+   }
-+
-+   buffer->width = width;
-+   buffer->height = height;
-+   buffer->format = format;
-+
-+   buffer->resource = wl_resource_create(resource->client, &wl_buffer_interface,
-+                                         1, id);
-+   if (!buffer->resource) {
-+      wl_resource_post_no_memory(resource);
-+      vc_dispmanx_resource_delete(buffer->handle);
-+      free(buffer);
-+      return;
-+   }
-+
-+   wl_resource_set_implementation(buffer->resource,
-+				       (void (**)(void)) &dispmanx_buffer_interface,
-+				       buffer, destroy_buffer);
-+
-+   wl_dispmanx_send_buffer_allocated(resource, buffer->resource,
-+                                     buffer->handle);
-+}
-+
-+static const struct wl_dispmanx_interface dispmanx_interface = {
-+   dispmanx_create_buffer,
-+};
-+
-+static void
-+bind_dispmanx(struct wl_client *client, void *data, uint32_t version, uint32_t id)
-+{
-+   struct wl_resource *resource;
-+
-+   resource = wl_resource_create(client, &wl_dispmanx_interface, 1, id);
-+   wl_resource_set_implementation(resource, &dispmanx_interface, NULL, NULL);
-+
-+   wl_resource_post_event(resource, WL_DISPMANX_FORMAT,
-+                          WL_DISPMANX_FORMAT_ARGB8888);
-+
-+   wl_resource_post_event(resource, WL_DISPMANX_FORMAT,
-+                          WL_DISPMANX_FORMAT_XRGB8888);
-+
-+   wl_resource_post_event(resource, WL_DISPMANX_FORMAT,
-+                          WL_DISPMANX_FORMAT_ABGR8888);
-+
-+   wl_resource_post_event(resource, WL_DISPMANX_FORMAT,
-+                          WL_DISPMANX_FORMAT_XBGR8888);
-+
-+   wl_resource_post_event(resource, WL_DISPMANX_FORMAT,
-+                          WL_DISPMANX_FORMAT_RGB565);
-+}
-+
-+EGLBoolean EGLAPIENTRY
-+eglBindWaylandDisplayWL(EGLDisplay dpy, struct wl_display *display)
-+{
-+   CLIENT_THREAD_STATE_T *thread;
-+   CLIENT_PROCESS_STATE_T *process;
-+
-+   if (!CLIENT_LOCK_AND_GET_STATES(dpy, &thread, &process))
-+      return EGL_FALSE;
-+
-+   if (process->wl_global != NULL)
-+      goto error;
-+
-+   process->wl_global = wl_global_create(display, &wl_dispmanx_interface, 1,
-+                                         NULL, bind_dispmanx);
-+   if (process->wl_global == NULL)
-+      goto error;
-+
-+   return EGL_TRUE;
-+
-+error:
-+   CLIENT_UNLOCK();
-+   return EGL_FALSE;
-+}
-+
-+EGLBoolean EGLAPIENTRY
-+eglUnbindWaylandDisplayWL(EGLDisplay dpy, struct wl_display *display)
-+{
-+   CLIENT_THREAD_STATE_T *thread;
-+   CLIENT_PROCESS_STATE_T *process;
-+
-+   if (!CLIENT_LOCK_AND_GET_STATES(dpy, &thread, &process))
-+      return EGL_FALSE;
-+
-+   wl_global_destroy(process->wl_global);
-+   process->wl_global = NULL;
-+
-+   CLIENT_UNLOCK();
-+
-+   return EGL_TRUE;
-+}
-+
-+static int
-+get_egl_format(enum wl_dispmanx_format format)
-+{
-+	switch (format) {
-+	case WL_DISPMANX_FORMAT_ABGR8888:
-+		return EGL_TEXTURE_RGBA;
-+	case WL_DISPMANX_FORMAT_XBGR8888:
-+		return EGL_TEXTURE_RGB;
-+	case WL_DISPMANX_FORMAT_RGB565:
-+		return EGL_TEXTURE_RGB;
-+	default:
-+		/* invalid format */
-+		return EGL_NO_TEXTURE;
-+	}
-+}
-+
-+EGLBoolean EGLAPIENTRY
-+eglQueryWaylandBufferWL(EGLDisplay dpy, struct wl_resource *_buffer,
-+         EGLint attribute, EGLint *value)
-+{
-+   struct wl_dispmanx_server_buffer *buffer = wl_resource_get_user_data(_buffer);
-+
-+   if (wl_resource_instance_of(_buffer, &wl_dispmanx_interface,
-+                               &dispmanx_buffer_interface))
-+      return EGL_FALSE;
-+
-+   switch (attribute) {
-+   case EGL_TEXTURE_FORMAT:
-+      *value = get_egl_format(buffer->format);
-+      if (*value == EGL_NO_TEXTURE)
-+         return EGL_FALSE;
-+      return EGL_TRUE;
-+   case EGL_WIDTH:
-+      *value = buffer->width;
-+      return EGL_TRUE;
-+   case EGL_HEIGHT:
-+      *value = buffer->height;
-+      return EGL_TRUE;
-+   }
-+
-+   return EGL_FALSE;
-+}
-Index: git/interface/khronos/include/EGL/eglext.h
-===================================================================
---- git.orig/interface/khronos/include/EGL/eglext.h
-+++ git/interface/khronos/include/EGL/eglext.h
-@@ -191,6 +191,29 @@ typedef EGLBoolean (EGLAPIENTRYP PFNEGLG
- #endif
- 
- 
-+#ifndef EGL_WL_bind_wayland_display
-+#define EGL_WL_bind_wayland_display 1
-+
-+#define EGL_WAYLAND_BUFFER_WL		0x31D5 /* eglCreateImageKHR target */
-+#define EGL_WAYLAND_PLANE_WL		0x31D6 /* eglCreateImageKHR target */
-+#define EGL_TEXTURE_Y_U_V_WL            0x31D7
-+#define EGL_TEXTURE_Y_UV_WL             0x31D8
-+#define EGL_TEXTURE_Y_XUXV_WL           0x31D9
-+
-+struct wl_display;
-+struct wl_resource;
-+#ifdef EGL_EGLEXT_PROTOTYPES
-+EGLAPI EGLBoolean EGLAPIENTRY eglBindWaylandDisplayWL(EGLDisplay dpy, struct wl_display *display);
-+EGLAPI EGLBoolean EGLAPIENTRY eglUnbindWaylandDisplayWL(EGLDisplay dpy, struct wl_display *display);
-+EGLAPI EGLBoolean EGLAPIENTRY eglQueryWaylandBufferWL(EGLDisplay dpy, struct wl_resource *buffer, EGLint attribute, EGLint *value);
-+#endif
-+typedef EGLBoolean (EGLAPIENTRYP PFNEGLBINDWAYLANDDISPLAYWL) (EGLDisplay dpy, struct wl_display *display);
-+typedef EGLBoolean (EGLAPIENTRYP PFNEGLUNBINDWAYLANDDISPLAYWL) (EGLDisplay dpy, struct wl_display *display);
-+typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYWAYLANDBUFFERWL) (EGLDisplay dpy, struct wl_resource *buffer, EGLint attribute, EGLint *value);
-+
-+#endif
-+
-+
- #ifdef __cplusplus
- }
- #endif
-Index: git/interface/khronos/wayland-egl/wayland-egl-priv.h
-===================================================================
---- /dev/null
-+++ git/interface/khronos/wayland-egl/wayland-egl-priv.h
-@@ -0,0 +1,53 @@
-+/* Copied from Mesa */
-+
-+#ifndef _WAYLAND_EGL_PRIV_H
-+#define _WAYLAND_EGL_PRIV_H
-+
-+#ifdef  __cplusplus
-+extern "C" {
-+#endif
-+
-+/* GCC visibility */
-+#if defined(__GNUC__) && __GNUC__ >= 4
-+#define WL_EGL_EXPORT __attribute__ ((visibility("default")))
-+#else
-+#define WL_EGL_EXPORT
-+#endif
-+
-+#include "interface/vmcs_host/vc_dispmanx.h"
-+#include "interface/khronos/egl/egl_client_surface.h"
-+
-+#include <wayland-client.h>
-+
-+struct wl_dispmanx_client_buffer {
-+	struct wl_buffer *wl_buffer;
-+	DISPMANX_RESOURCE_HANDLE_T resource;
-+
-+	int pending_allocation;
-+	int in_use;
-+	int width;
-+	int height;
-+};
-+
-+struct wl_egl_window {
-+	struct wl_surface *wl_surface;
-+
-+	int width;
-+	int height;
-+	int dx;
-+	int dy;
-+
-+	int attached_width;
-+	int attached_height;
-+
-+	/* XXX: The VC side seems to expect a valid element handle to be
-+	   passed to eglIntCreateSurface_impl and/or eglIntSwapBuffers_impl,
-+	   even for host-managed surfaces. */
-+	DISPMANX_ELEMENT_HANDLE_T dummy_element;
-+};
-+
-+#ifdef  __cplusplus
-+}
-+#endif
-+
-+#endif
-Index: git/interface/khronos/wayland-egl/wayland-egl.c
-===================================================================
---- /dev/null
-+++ git/interface/khronos/wayland-egl/wayland-egl.c
-@@ -0,0 +1,59 @@
-+/* Copied from Mesa */
-+
-+#include <stdlib.h>
-+
-+#include <wayland-client.h>
-+#include <wayland-egl.h>
-+#include "wayland-egl-priv.h"
-+
-+WL_EGL_EXPORT void
-+wl_egl_window_resize(struct wl_egl_window *egl_window,
-+		     int width, int height,
-+		     int dx, int dy)
-+{
-+        if (egl_window->width == width &&
-+	    egl_window->height == height &&
-+	    egl_window->dx == dx &&
-+	    egl_window->dy == dy)
-+		return;
-+
-+	egl_window->width = width;
-+	egl_window->height = height;
-+	egl_window->dx = dx;
-+	egl_window->dy = dy;
-+}
-+
-+WL_EGL_EXPORT struct wl_egl_window *
-+wl_egl_window_create(struct wl_surface *surface,
-+		     int width, int height)
-+{
-+	struct wl_egl_window *egl_window;
-+
-+	egl_window = calloc(1, sizeof *egl_window);
-+	if (!egl_window)
-+		return NULL;
-+
-+	egl_window->wl_surface = surface;
-+	wl_egl_window_resize(egl_window, width, height, 0, 0);
-+	egl_window->attached_width  = 0;
-+	egl_window->attached_height = 0;
-+	egl_window->dummy_element = PLATFORM_WIN_NONE;
-+
-+	return egl_window;
-+}
-+
-+WL_EGL_EXPORT void
-+wl_egl_window_destroy(struct wl_egl_window *egl_window)
-+{
-+	free(egl_window);
-+}
-+
-+WL_EGL_EXPORT void
-+wl_egl_window_get_attached_size(struct wl_egl_window *egl_window,
-+				int *width, int *height)
-+{
-+	if (width)
-+		*width = egl_window->attached_width;
-+	if (height)
-+		*height = egl_window->attached_height;
-+}
-Index: git/interface/khronos/wayland-egl/wayland-egl.pc.in
-===================================================================
---- /dev/null
-+++ git/interface/khronos/wayland-egl/wayland-egl.pc.in
-@@ -0,0 +1,10 @@
-+prefix=@CMAKE_INSTALL_PREFIX@
-+exec_prefix=${prefix}
-+libdir=${exec_prefix}/lib
-+includedir=${prefix}/include
-+
-+Name: wayland-egl
-+Description: VideoCore wayland-egl library
-+Version: @PROJECT_APIVER@
-+Libs: -L${libdir} -lwayland-egl
-+Cflags: -I${includedir}
-Index: git/interface/vmcs_host/CMakeLists.txt
-===================================================================
---- git.orig/interface/vmcs_host/CMakeLists.txt
-+++ git/interface/vmcs_host/CMakeLists.txt
-@@ -9,13 +9,24 @@ add_definitions(-fno-strict-aliasing)
- 
- include_directories(${VMCS_TARGET}/vcfiled)
- 
--add_library(vchostif
--            ${VMCS_TARGET}/vcfilesys.c ${VMCS_TARGET}/vcmisc.c
--            vc_vchi_gencmd.c vc_vchi_filesys.c vc_vchi_gpuserv.c
--            vc_vchi_tvservice.c vc_vchi_cecservice.c
--            vc_vchi_dispmanx.c vc_service_common.c)
-+set(VCHOSTIF_SOURCE
-+    ${VMCS_TARGET}/vcfilesys.c ${VMCS_TARGET}/vcmisc.c
-+    vc_vchi_gencmd.c vc_vchi_filesys.c vc_vchi_gpuserv.c
-+    vc_vchi_tvservice.c vc_vchi_cecservice.c
-+    vc_vchi_dispmanx.c vc_service_common.c)
- #            ${VMCS_TARGET}/vmcs_main.c
- #  vc_vchi_haud.c
-+
-+if (BUILD_WAYLAND)
-+wayland_add_protocol_server(
-+    VCHOSTIF_SOURCE
-+    ../../interface/wayland/dispmanx.xml
-+    dispmanx
-+)
-+endif ()
-+
-+add_library(vchostif ${VCHOSTIF_SOURCE})
-+
- #add_library(bufman            vc_vchi_bufman.c            )
- 
- # OpenMAX/IL component service
-Index: git/interface/vmcs_host/vc_dispmanx.h
-===================================================================
---- git.orig/interface/vmcs_host/vc_dispmanx.h
-+++ git/interface/vmcs_host/vc_dispmanx.h
-@@ -39,6 +39,11 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBI
- #ifdef __cplusplus
- extern "C" {
- #endif
-+
-+#ifdef BUILD_WAYLAND
-+struct wl_resource;
-+#endif
-+
- // Same function as above, to aid migration of code.
- VCHPRE_ int VCHPOST_ vc_dispman_init( void );
- // Stop the service from being used
-@@ -135,6 +140,11 @@ VCHPRE_ int VCHPOST_ vc_dispmanx_resourc
- // Start triggering callbacks synced to vsync
- VCHPRE_ int VCHPOST_ vc_dispmanx_vsync_callback( DISPMANX_DISPLAY_HANDLE_T display, DISPMANX_CALLBACK_FUNC_T cb_func, void *cb_arg );
- 
-+#ifdef BUILD_WAYLAND
-+VCHPRE_ DISPMANX_RESOURCE_HANDLE_T VCHPOST_ vc_dispmanx_get_handle_from_wl_buffer( struct wl_resource *_buffer );
-+
-+VCHPRE_ void VCHPOST_ vc_dispmanx_set_wl_buffer_in_use( struct wl_resource *_buffer, int in_use );
-+#endif
- #ifdef __cplusplus
- }
- #endif
-Index: git/interface/vmcs_host/vc_vchi_dispmanx.c
-===================================================================
---- git.orig/interface/vmcs_host/vc_vchi_dispmanx.c
-+++ git/interface/vmcs_host/vc_vchi_dispmanx.c
-@@ -1319,3 +1319,45 @@ static void *dispmanx_notify_func( void
-    }
-    return 0;
- }
-+
-+
-+#ifdef BUILD_WAYLAND
-+/***********************************************************
-+ * Name: vc_dispmanx_get_handle_from_wl_buffer
-+ *
-+ * Arguments:
-+ *       struct wl_resource *_buffer
-+ *
-+ * Description: Return the handle of the resource associated to this Wayland buffer
-+ *
-+ * Returns: A resource handle
-+ *
-+ ***********************************************************/
-+VCHPRE_ DISPMANX_RESOURCE_HANDLE_T VCHPOST_ vc_dispmanx_get_handle_from_wl_buffer( struct wl_resource *_buffer )
-+{
-+	struct wl_dispmanx_server_buffer *buffer = (struct wl_dispmanx_server_buffer*)_buffer->data;
-+	if (!buffer)
-+		return DISPMANX_NO_HANDLE;
-+
-+	return buffer->handle;
-+}
-+
-+/***********************************************************
-+ * Name: vc_dispmanx_set_wl_buffer_in_use
-+ *
-+ * Arguments:
-+ *       struct wl_resource *_buffer
-+ *       int in_use
-+ *
-+ * Description: Mark this Wayland buffer as being in use by the compositor
-+ *
-+ ***********************************************************/
-+VCHPRE_ void VCHPOST_ vc_dispmanx_set_wl_buffer_in_use( struct wl_resource *_buffer, int in_use )
-+{
-+	struct wl_dispmanx_server_buffer *buffer = (struct wl_dispmanx_server_buffer*)_buffer->data;
-+	if (!buffer)
-+		return;
-+
-+	buffer->in_use = in_use;
-+}
-+#endif
-Index: git/interface/wayland/dispmanx.xml
-===================================================================
---- /dev/null
-+++ git/interface/wayland/dispmanx.xml
-@@ -0,0 +1,123 @@
-+<?xml version="1.0" encoding="UTF-8"?>
-+<protocol name="dispmanx">
-+
-+  <copyright>
-+    Copyright © 2008-2011 Kristian Høgsberg
-+    Copyright © 2010-2011 Intel Corporation
-+    Copyright © 2013 Raspberry Pi Foundation
-+
-+    Permission to use, copy, modify, distribute, and sell this
-+    software and its documentation for any purpose is hereby granted
-+    without fee, provided that\n the above copyright notice appear in
-+    all copies and that both that copyright notice and this permission
-+    notice appear in supporting documentation, and that the name of
-+    the copyright holders not be used in advertising or publicity
-+    pertaining to distribution of the software without specific,
-+    written prior permission.  The copyright holders make no
-+    representations about the suitability of this software for any
-+    purpose.  It is provided "as is" without express or implied
-+    warranty.
-+
-+    THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS
-+    SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
-+    FITNESS, IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY
-+    SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
-+    WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
-+    AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
-+    ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
-+    THIS SOFTWARE.
-+  </copyright>
-+
-+  <!-- DispManX support. This object is created by the server and published
-+       using the display's global event. -->
-+  <interface name="wl_dispmanx" version="1">
-+    <enum name="error">
-+      <entry name="alloc_failed" value="0"/>
-+      <entry name="invalid_format" value="1"/>
-+    </enum>
-+
-+    <enum name="format">
-+      <!-- The pixel format codes match the #defines in drm_fourcc.h.
-+           The formats actually supported by the compositor will be
-+           reported by the format event. -->
-+      <entry name="c8" value="0x20203843"/>
-+      <entry name="rgb332" value="0x38424752"/>
-+      <entry name="bgr233" value="0x38524742"/>
-+      <entry name="xrgb4444" value="0x32315258"/>
-+      <entry name="xbgr4444" value="0x32314258"/>
-+      <entry name="rgbx4444" value="0x32315852"/>
-+      <entry name="bgrx4444" value="0x32315842"/>
-+      <entry name="argb4444" value="0x32315241"/>
-+      <entry name="abgr4444" value="0x32314241"/>
-+      <entry name="rgba4444" value="0x32314152"/>
-+      <entry name="bgra4444" value="0x32314142"/>
-+      <entry name="xrgb1555" value="0x35315258"/>
-+      <entry name="xbgr1555" value="0x35314258"/>
-+      <entry name="rgbx5551" value="0x35315852"/>
-+      <entry name="bgrx5551" value="0x35315842"/>
-+      <entry name="argb1555" value="0x35315241"/>
-+      <entry name="abgr1555" value="0x35314241"/>
-+      <entry name="rgba5551" value="0x35314152"/>
-+      <entry name="bgra5551" value="0x35314142"/>
-+      <entry name="rgb565" value="0x36314752"/>
-+      <entry name="bgr565" value="0x36314742"/>
-+      <entry name="rgb888" value="0x34324752"/>
-+      <entry name="bgr888" value="0x34324742"/>
-+      <entry name="xrgb8888" value="0x34325258"/>
-+      <entry name="xbgr8888" value="0x34324258"/>
-+      <entry name="rgbx8888" value="0x34325852"/>
-+      <entry name="bgrx8888" value="0x34325842"/>
-+      <entry name="argb8888" value="0x34325241"/>
-+      <entry name="abgr8888" value="0x34324241"/>
-+      <entry name="rgba8888" value="0x34324152"/>
-+      <entry name="bgra8888" value="0x34324142"/>
-+      <entry name="xrgb2101010" value="0x30335258"/>
-+      <entry name="xbgr2101010" value="0x30334258"/>
-+      <entry name="rgbx1010102" value="0x30335852"/>
-+      <entry name="bgrx1010102" value="0x30335842"/>
-+      <entry name="argb2101010" value="0x30335241"/>
-+      <entry name="abgr2101010" value="0x30334241"/>
-+      <entry name="rgba1010102" value="0x30334152"/>
-+      <entry name="bgra1010102" value="0x30334142"/>
-+      <entry name="yuyv" value="0x56595559"/>
-+      <entry name="yvyu" value="0x55595659"/>
-+      <entry name="uyvy" value="0x59565955"/>
-+      <entry name="vyuy" value="0x59555956"/>
-+      <entry name="ayuv" value="0x56555941"/>
-+      <entry name="nv12" value="0x3231564e"/>
-+      <entry name="nv21" value="0x3132564e"/>
-+      <entry name="nv16" value="0x3631564e"/>
-+      <entry name="nv61" value="0x3136564e"/>
-+      <entry name="yuv410" value="0x39565559"/>
-+      <entry name="yvu410" value="0x39555659"/>
-+      <entry name="yuv411" value="0x31315559"/>
-+      <entry name="yvu411" value="0x31315659"/>
-+      <entry name="yuv420" value="0x32315559"/>
-+      <entry name="yvu420" value="0x32315659"/>
-+      <entry name="yuv422" value="0x36315559"/>
-+      <entry name="yvu422" value="0x36315659"/>
-+      <entry name="yuv444" value="0x34325559"/>
-+      <entry name="yvu444" value="0x34325659"/>
-+    </enum>
-+
-+    <event name="format">
-+      <arg name="format" type="uint"/>
-+    </event>
-+
-+    <!-- Create a wayland buffer for the DispManX resource. -->
-+    <request name="create_buffer">
-+      <arg name="id" type="new_id" interface="wl_buffer"/>
-+      <arg name="width" type="int"/>
-+      <arg name="height" type="int"/>
-+      <arg name="stride" type="uint"/>
-+      <arg name="buffer_height" type="uint"/>
-+      <arg name="format" type="uint"/>
-+    </request>
-+
-+    <event name="buffer_allocated">
-+      <arg name="buffer" type="object" interface="wl_buffer"/>
-+      <arg name="handle" type="uint"/>
-+    </event>
-+  </interface>
-+
-+</protocol>
-Index: git/makefiles/cmake/Wayland.cmake
-===================================================================
---- /dev/null
-+++ git/makefiles/cmake/Wayland.cmake
-@@ -0,0 +1,72 @@
-+#=============================================================================
-+# Copyright (C) 2012-2013 Pier Luigi Fiorini <pierluigi.fiorini@gmail.com>
-+# All rights reserved.
-+#
-+# 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 Pier Luigi Fiorini nor the names of his
-+#   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
-+# HOLDER 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.
-+#=============================================================================
-+
-+find_program(WAYLAND_SCANNER_EXECUTABLE NAMES wayland-scanner)
-+
-+# wayland_add_protocol_client(outfiles inputfile basename)
-+function(WAYLAND_ADD_PROTOCOL_CLIENT _sources _protocol _basename)
-+    if(NOT WAYLAND_SCANNER_EXECUTABLE)
-+        message(FATAL "The wayland-scanner executable has nto been found on your system. You must install it.")
-+    endif()
-+
-+    get_filename_component(_infile ${_protocol} ABSOLUTE)
-+    set(_client_header "${CMAKE_CURRENT_BINARY_DIR}/wayland-${_basename}-client-protocol.h")
-+    set(_code "${CMAKE_CURRENT_BINARY_DIR}/wayland-${_basename}-protocol.c")
-+
-+    add_custom_command(OUTPUT "${_client_header}"
-+        COMMAND ${WAYLAND_SCANNER_EXECUTABLE} client-header < ${_infile} > ${_client_header}
-+        DEPENDS ${_infile} VERBATIM)
-+
-+    add_custom_command(OUTPUT "${_code}"
-+        COMMAND ${WAYLAND_SCANNER_EXECUTABLE} code < ${_infile} > ${_code}
-+        DEPENDS ${_infile} VERBATIM)
-+
-+    list(APPEND ${_sources} "${_client_header}" "${_code}")
-+    set(${_sources} ${${_sources}} PARENT_SCOPE)
-+endfunction()
-+
-+# wayland_add_protocol_server(outfiles inputfile basename)
-+function(WAYLAND_ADD_PROTOCOL_SERVER _sources _protocol _basename)
-+    if(NOT WAYLAND_SCANNER_EXECUTABLE)
-+        message(FATAL "The wayland-scanner executable has nto been found on your system. You must install it.")
-+    endif()
-+
-+    get_filename_component(_infile ${_protocol} ABSOLUTE)
-+    set(_server_header "${CMAKE_CURRENT_BINARY_DIR}/wayland-${_basename}-server-protocol.h")
-+
-+    add_custom_command(OUTPUT "${_server_header}"
-+        COMMAND ${WAYLAND_SCANNER_EXECUTABLE} server-header < ${_infile} > ${_server_header}
-+        DEPENDS ${_infile} VERBATIM)
-+
-+    list(APPEND ${_sources} "${_server_header}")
-+    set(${_sources} ${${_sources}} PARENT_SCOPE)
-+endfunction()
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0003-wayland-Add-Wayland-example.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0003-wayland-Add-Wayland-example.patch
deleted file mode 100644
index e3a0cf2..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0003-wayland-Add-Wayland-example.patch
+++ /dev/null
Binary files differ
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0004-wayland-egl-Add-bcm_host-to-dependencies.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0004-wayland-egl-Add-bcm_host-to-dependencies.patch
deleted file mode 100644
index 713fc3e..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0004-wayland-egl-Add-bcm_host-to-dependencies.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From f17879b691984b5c4950e4b94ebf102c78797ede Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 10 Aug 2015 02:38:27 -0700
-Subject: [PATCH 04/16] wayland-egl: Add bcm_host to dependencies
-
-It uses headers like vcos_platform_types.h but does not
-depend on module which should add the required include paths
-lets add the dependency on bcm_host module which should do it
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- interface/khronos/wayland-egl/wayland-egl.pc.in | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/interface/khronos/wayland-egl/wayland-egl.pc.in b/interface/khronos/wayland-egl/wayland-egl.pc.in
-index 8bafc15..fd259c9 100644
---- a/interface/khronos/wayland-egl/wayland-egl.pc.in
-+++ b/interface/khronos/wayland-egl/wayland-egl.pc.in
-@@ -6,5 +6,6 @@ includedir=${prefix}/include
- Name: wayland-egl
- Description: VideoCore wayland-egl library
- Version: @PROJECT_APIVER@
-+Requires: bcm_host
- Libs: -L${libdir} -lwayland-egl
- Cflags: -I${includedir}
--- 
-2.16.1
-
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0005-interface-remove-faulty-assert-to-make-weston-happy-.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0005-interface-remove-faulty-assert-to-make-weston-happy-.patch
deleted file mode 100644
index 8d78333..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0005-interface-remove-faulty-assert-to-make-weston-happy-.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From 0273b7b9d7a27d8fe7d3ad8680b799f997e75dca Mon Sep 17 00:00:00 2001
-From: "Yann E. MORIN" <yann.morin.1998@free.fr>
-Date: Sat, 24 Jan 2015 22:07:19 +0100
-Subject: [PATCH 05/16] interface: remove faulty assert() to make weston happy
- at runtime
-
-This was removed after a discussion on IRC with the weston guys
-('daniels' on irc.freenode.net/#wayland).
-
-Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
----
- interface/vmcs_host/vc_vchi_dispmanx.c | 1 -
- 1 file changed, 1 deletion(-)
-
-diff --git a/interface/vmcs_host/vc_vchi_dispmanx.c b/interface/vmcs_host/vc_vchi_dispmanx.c
-index eab146e..29e0dee 100755
---- a/interface/vmcs_host/vc_vchi_dispmanx.c
-+++ b/interface/vmcs_host/vc_vchi_dispmanx.c
-@@ -1306,7 +1306,6 @@ static void *dispmanx_notify_func( void *arg ) {
-             // Decrement the use count - the corresponding "use" is in vc_dispmanx_update_submit.
-             vchi_service_release(dispmanx_client.notify_handle[0]);
-             if (dispmanx_client.update_callback ) {
--               vcos_assert( dispmanx_client.pending_update_handle == handle);
-                dispmanx_client.update_callback(handle, dispmanx_client.update_callback_param);
-             }
-          } else {
--- 
-2.16.1
-
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0006-zero-out-wl-buffers-in-egl_surface_free.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0006-zero-out-wl-buffers-in-egl_surface_free.patch
deleted file mode 100644
index 43eb7f0..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0006-zero-out-wl-buffers-in-egl_surface_free.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 0d678cd2042551cc4e26ec42fa3aba7c72d033b4 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 6 Feb 2016 11:10:47 -0800
-Subject: [PATCH 06/16] zero-out wl buffers in egl_surface_free
-
-origins from buildroot
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- interface/khronos/egl/egl_client_surface.c | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/interface/khronos/egl/egl_client_surface.c b/interface/khronos/egl/egl_client_surface.c
-index 42350bf..1f923d9 100644
---- a/interface/khronos/egl/egl_client_surface.c
-+++ b/interface/khronos/egl/egl_client_surface.c
-@@ -690,11 +690,13 @@ void egl_surface_free(EGL_SURFACE_T *surface)
-       if (surface->back_wl_buffer) {
-          wl_buffer_destroy(surface->back_wl_buffer->wl_buffer);
-          free(surface->back_wl_buffer);
-+         surface->back_wl_buffer = 0;
-       }
- 
-       if (surface->front_wl_buffer) {
-          wl_buffer_destroy(surface->front_wl_buffer->wl_buffer);
-          free(surface->front_wl_buffer);
-+         surface->front_wl_buffer = 0;
-       }
- #endif
-    }
--- 
-2.16.1
-
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0007-initialize-front-back-wayland-buffers.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0007-initialize-front-back-wayland-buffers.patch
deleted file mode 100644
index 987740b..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0007-initialize-front-back-wayland-buffers.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From ec2e00989bf614b259bc9a47b5035f8586e8a214 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 6 Feb 2016 11:11:41 -0800
-Subject: [PATCH 07/16] initialize front back wayland buffers
-
-origins from metrological wayland support
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- interface/khronos/egl/egl_client_surface.c | 3 +++
- 1 file changed, 3 insertions(+)
-
-diff --git a/interface/khronos/egl/egl_client_surface.c b/interface/khronos/egl/egl_client_surface.c
-index 1f923d9..9a9582c 100644
---- a/interface/khronos/egl/egl_client_surface.c
-+++ b/interface/khronos/egl/egl_client_surface.c
-@@ -401,11 +401,14 @@ EGL_SURFACE_T *egl_surface_create(
- #ifdef BUILD_WAYLAND
-    if (type == WINDOW && wl_display) {
-       surface->wl_egl_window = (struct wl_egl_window*)win;
-+      surface->front_wl_buffer = NULL;
-       surface->back_wl_buffer = allocate_wl_buffer(
-             surface->wl_egl_window, color);
-       resource = surface->back_wl_buffer->resource;
-    } else {
-       surface->wl_egl_window = NULL;
-+      surface->front_wl_buffer = NULL;
-+      surface->back_wl_buffer = NULL;
-       resource = DISPMANX_NO_HANDLE;
-    }
- #endif
--- 
-2.16.1
-
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0008-Remove-RPC_FLUSH.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0008-Remove-RPC_FLUSH.patch
deleted file mode 100644
index 4bf05c1..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0008-Remove-RPC_FLUSH.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 59ba66c2ea17f7a57124b9fd6c9bdff4325ff5c9 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 6 Feb 2016 11:09:18 -0800
-Subject: [PATCH 08/16] Remove RPC_FLUSH
-
-Origins from buildroot
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- interface/khronos/ext/gl_oes_egl_image_client.c | 1 -
- 1 file changed, 1 deletion(-)
-
-diff --git a/interface/khronos/ext/gl_oes_egl_image_client.c b/interface/khronos/ext/gl_oes_egl_image_client.c
-index f9b7287..b04ffef 100644
---- a/interface/khronos/ext/gl_oes_egl_image_client.c
-+++ b/interface/khronos/ext/gl_oes_egl_image_client.c
-@@ -107,7 +107,6 @@ GL_API void GL_APIENTRY glEGLImageTargetTexture2DOES (GLenum target, GLeglImageO
-                    GLEGLIMAGETARGETTEXTURE2DOES_ID,
-                    RPC_ENUM(target),
-                    RPC_EGLID(image));
--         RPC_FLUSH(thread);
- #if EGL_BRCM_global_image
-       }
- #endif
--- 
-2.16.1
-
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0009-fix-cmake-dependency-race.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0009-fix-cmake-dependency-race.patch
deleted file mode 100644
index a2c1df5..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0009-fix-cmake-dependency-race.patch
+++ /dev/null
@@ -1,78 +0,0 @@
-From 264d82387ea1e607b2e5c899ff6bd46807c7b185 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 6 Feb 2016 13:12:47 -0800
-Subject: [PATCH 09/16] fix cmake dependency race
-
-Fixes errors like
-
-/a/builder/mnt/build-oe/tmp-glibc/work/raspberrypi2-oe-linux-gnueabi/userland/git-r5/git/interface/vmcs_host/vc_vchi_dispmanx.h:72:66:
-fatal error: interface/vmcs_host/wayland-dispmanx-server-protocol.h: No
-such file or directory
-compilation terminated.
-interface/khronos/CMakeFiles/EGL_static.dir/build.make:773: recipe for
-target 'interface/khronos/CMakeFiles/EGL_static.dir/ext/egl_wayland.c.o'
-failed
-make[2]: ***
-[interface/khronos/CMakeFiles/EGL_static.dir/ext/egl_wayland.c.o] Error 1
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- interface/vcos/pthreads/CMakeLists.txt | 8 ++++++++
- interface/vmcs_host/CMakeLists.txt     | 8 --------
- interface/vmcs_host/vc_vchi_dispmanx.h | 2 +-
- 3 files changed, 9 insertions(+), 9 deletions(-)
-
-diff --git a/interface/vcos/pthreads/CMakeLists.txt b/interface/vcos/pthreads/CMakeLists.txt
-index 1d81ca3..d6cd415 100644
---- a/interface/vcos/pthreads/CMakeLists.txt
-+++ b/interface/vcos/pthreads/CMakeLists.txt
-@@ -33,6 +33,14 @@ set (SOURCES
-    ../generic/vcos_generic_blockpool.c
- )
- 
-+if (BUILD_WAYLAND)
-+wayland_add_protocol_server(
-+    SOURCES
-+    ../../../interface/wayland/dispmanx.xml
-+    dispmanx
-+)
-+endif ()
-+
- if (VCOS_PTHREADS_BUILD_SHARED)
-    add_library (vcos SHARED ${SOURCES})
-    target_link_libraries (vcos pthread dl rt)
-diff --git a/interface/vmcs_host/CMakeLists.txt b/interface/vmcs_host/CMakeLists.txt
-index 6718215..c415176 100755
---- a/interface/vmcs_host/CMakeLists.txt
-+++ b/interface/vmcs_host/CMakeLists.txt
-@@ -17,14 +17,6 @@ set(VCHOSTIF_SOURCE
- #            ${VMCS_TARGET}/vmcs_main.c
- #  vc_vchi_haud.c
- 
--if (BUILD_WAYLAND)
--wayland_add_protocol_server(
--    VCHOSTIF_SOURCE
--    ../../interface/wayland/dispmanx.xml
--    dispmanx
--)
--endif ()
--
- add_library(vchostif ${VCHOSTIF_SOURCE})
- 
- #add_library(bufman            vc_vchi_bufman.c            )
-diff --git a/interface/vmcs_host/vc_vchi_dispmanx.h b/interface/vmcs_host/vc_vchi_dispmanx.h
-index f0bae30..8c44c58 100644
---- a/interface/vmcs_host/vc_vchi_dispmanx.h
-+++ b/interface/vmcs_host/vc_vchi_dispmanx.h
-@@ -69,7 +69,7 @@ typedef struct {
- #ifdef BUILD_WAYLAND
- /* XXX: This should be in a private header that can be included from EGL and vc_* */
- #include <wayland-server.h>
--#include "interface/vmcs_host/wayland-dispmanx-server-protocol.h"
-+#include "interface/vcos/pthreads/wayland-dispmanx-server-protocol.h"
- struct wl_dispmanx_server_buffer {
- 	struct wl_resource *resource;
- 	struct wl_dispmanx *dispmanx;
--- 
-2.16.1
-
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0010-Fix-for-framerate-with-nested-composition.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0010-Fix-for-framerate-with-nested-composition.patch
deleted file mode 100644
index a6c9a59..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0010-Fix-for-framerate-with-nested-composition.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-From 7c51c2d37bfadaabbbf205237d932b685b09d34f Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 29 Mar 2016 20:38:30 -0700
-Subject: [PATCH 10/16] Fix for framerate with nested composition
-
-frame rate appears irregular and lower than expected when using nested composition.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- interface/khronos/egl/egl_client.c | 8 ++++++++
- 1 file changed, 8 insertions(+)
-
-diff --git a/interface/khronos/egl/egl_client.c b/interface/khronos/egl/egl_client.c
-index 03fe67b..13a110c 100644
---- a/interface/khronos/egl/egl_client.c
-+++ b/interface/khronos/egl/egl_client.c
-@@ -2342,6 +2342,9 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
-                      surface->back_wl_buffer = buffer;
-                   }
- 
-+                  glFlush();
-+                  glFinish();
-+
-                   RPC_CALL7(eglIntSwapBuffers_impl,
-                         thread,
-                         EGLINTSWAPBUFFERS_ID_V2,
-@@ -2353,6 +2356,8 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
-                         RPC_UINT(khrn_platform_get_window_position(surface->win)),
-                         RPC_INT(surface->back_wl_buffer->resource));
- 
-+                  RPC_FLUSH(thread);
-+
-                   surface->front_wl_buffer->in_use = 1;
-                   wl_surface_attach(wl_egl_window->wl_surface,
-                                     surface->front_wl_buffer->wl_buffer,
-@@ -2360,11 +2365,13 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
-                   wl_surface_damage(wl_egl_window->wl_surface, 0, 0,
-                                     surface->width, surface->height);
-                   wl_surface_commit(wl_egl_window->wl_surface);
-+                  wl_display_flush(wl_display);
- 
-                   while(ret != -1 && surface->back_wl_buffer->in_use)
-                      ret = wl_display_dispatch_queue(wl_display, process->wl_queue);
-                } else
- #endif
-+               {
-                RPC_CALL6(eglIntSwapBuffers_impl,
-                      thread,
-                      EGLINTSWAPBUFFERS_ID,
-@@ -2376,6 +2383,7 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
-                      RPC_UINT(khrn_platform_get_window_position(surface->win)));
- 
-                RPC_FLUSH(thread);
-+               }
- 
- #ifdef ANDROID
-                CLIENT_UNLOCK();
--- 
-2.16.1
-
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0011-build-shared-library-for-vchostif.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0011-build-shared-library-for-vchostif.patch
deleted file mode 100644
index 55a5be8..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0011-build-shared-library-for-vchostif.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From fb3002f77a175633af31019c513754d2ef5f3ac0 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 2 Apr 2016 10:37:24 -0700
-Subject: [PATCH 11/16] build shared library for vchostif
-
-Fixes #149
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- interface/vmcs_host/CMakeLists.txt | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/interface/vmcs_host/CMakeLists.txt b/interface/vmcs_host/CMakeLists.txt
-index c415176..d0cca1a 100755
---- a/interface/vmcs_host/CMakeLists.txt
-+++ b/interface/vmcs_host/CMakeLists.txt
-@@ -17,7 +17,7 @@ set(VCHOSTIF_SOURCE
- #            ${VMCS_TARGET}/vmcs_main.c
- #  vc_vchi_haud.c
- 
--add_library(vchostif ${VCHOSTIF_SOURCE})
-+add_library(vchostif SHARED ${VCHOSTIF_SOURCE})
- 
- #add_library(bufman            vc_vchi_bufman.c            )
- 
--- 
-2.16.1
-
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0012-implement-buffer-wrapping-interface-for-dispmanx.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0012-implement-buffer-wrapping-interface-for-dispmanx.patch
deleted file mode 100644
index 28a5fc6..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0012-implement-buffer-wrapping-interface-for-dispmanx.patch
+++ /dev/null
@@ -1,92 +0,0 @@
-From df8b9633a45069bdd1bf256d974636ef11aa39cb Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 2 Apr 2016 10:54:59 -0700
-Subject: [PATCH 12/16] implement buffer wrapping interface for dispmanx
-
-Courtesy: Zan Dobersek
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- interface/khronos/ext/egl_wayland.c | 42 +++++++++++++++++++++++++++++++++++++
- interface/wayland/dispmanx.xml      | 10 +++++++++
- 2 files changed, 52 insertions(+)
-
-diff --git a/interface/khronos/ext/egl_wayland.c b/interface/khronos/ext/egl_wayland.c
-index 5730743..9ef89cd 100644
---- a/interface/khronos/ext/egl_wayland.c
-+++ b/interface/khronos/ext/egl_wayland.c
-@@ -133,8 +133,50 @@ dispmanx_create_buffer(struct wl_client *client, struct wl_resource *resource,
-                                      buffer->handle);
- }
- 
-+static void
-+dispmanx_wrap_buffer(struct wl_client *client, struct wl_resource *resource,
-+                     uint32_t id, uint32_t handle, int32_t width, int32_t height,
-+                     uint32_t stride, uint32_t buffer_height, uint32_t format)
-+{
-+   struct wl_dispmanx_server_buffer *buffer;
-+   VC_IMAGE_TYPE_T vc_format = get_vc_format(format);
-+   uint32_t dummy;
-+
-+   if(vc_format == VC_IMAGE_MIN) {
-+      wl_resource_post_error(resource,
-+                             WL_DISPMANX_ERROR_INVALID_FORMAT,
-+                             "invalid format");
-+      return;
-+   }
-+
-+   buffer = calloc(1, sizeof *buffer);
-+   if (buffer == NULL) {
-+      wl_resource_post_no_memory(resource);
-+      return;
-+   }
-+
-+   buffer->handle = handle;
-+   buffer->width = width;
-+   buffer->height = height;
-+   buffer->format = format;
-+
-+   buffer->resource = wl_resource_create(resource->client, &wl_buffer_interface,
-+                                         1, id);
-+   if (!buffer->resource) {
-+      wl_resource_post_no_memory(resource);
-+      vc_dispmanx_resource_delete(buffer->handle);
-+      free(buffer);
-+      return;
-+   }
-+
-+   wl_resource_set_implementation(buffer->resource,
-+				       (void (**)(void)) &dispmanx_buffer_interface,
-+				       buffer, destroy_buffer);
-+}
-+
- static const struct wl_dispmanx_interface dispmanx_interface = {
-    dispmanx_create_buffer,
-+   dispmanx_wrap_buffer,
- };
- 
- static void
-diff --git a/interface/wayland/dispmanx.xml b/interface/wayland/dispmanx.xml
-index c18626d..11ed1ef 100644
---- a/interface/wayland/dispmanx.xml
-+++ b/interface/wayland/dispmanx.xml
-@@ -118,6 +118,16 @@
-       <arg name="buffer" type="object" interface="wl_buffer"/>
-       <arg name="handle" type="uint"/>
-     </event>
-+
-+    <request name="wrap_buffer">
-+      <arg name="id" type="new_id" interface="wl_buffer"/>
-+      <arg name="handle" type="uint"/>
-+      <arg name="width" type="int"/>
-+      <arg name="height" type="int"/>
-+      <arg name="stride" type="uint"/>
-+      <arg name="buffer_height" type="uint"/>
-+      <arg name="format" type="uint"/>
-+    </request>
-   </interface>
- 
- </protocol>
--- 
-2.16.1
-
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0013-Implement-triple-buffering-for-wayland.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0013-Implement-triple-buffering-for-wayland.patch
deleted file mode 100644
index ebff314..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0013-Implement-triple-buffering-for-wayland.patch
+++ /dev/null
@@ -1,90 +0,0 @@
-From 2e0e331da8556fecd841349cfae294baf0f14485 Mon Sep 17 00:00:00 2001
-From: Jeff Wannamaker <jeff_wannamaker@cable.comcast.com>
-Date: Thu, 19 Jan 2017 18:56:07 +0000
-Subject: [PATCH 13/16] Implement triple buffering for wayland
-
-Change from double to triple buffering for wayland.
-This enables higher frame rates without tearing artifacts
-by allowing both the glFinish and the buffer release
-interlock to operate without pushing the frame period
-to two vertical intervals
-
-Signed-off-by: Jeff Wannamaker <jeff_wannamaker@cable.comcast.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- interface/khronos/egl/egl_client.c         |  3 ++-
- interface/khronos/egl/egl_client_surface.c |  8 ++++++++
- interface/khronos/egl/egl_client_surface.h | 11 +++++++++++
- 3 files changed, 21 insertions(+), 1 deletion(-)
-
-diff --git a/interface/khronos/egl/egl_client.c b/interface/khronos/egl/egl_client.c
-index 13a110c..0380274 100644
---- a/interface/khronos/egl/egl_client.c
-+++ b/interface/khronos/egl/egl_client.c
-@@ -2323,7 +2323,8 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
- 
-                   buffer_temp = surface->front_wl_buffer;
-                   surface->front_wl_buffer = surface->back_wl_buffer;
--                  surface->back_wl_buffer = buffer_temp;
-+                  surface->back_wl_buffer = surface->middle_wl_buffer;
-+                  surface->middle_wl_buffer = buffer_temp;
- 
-                   configid = egl_config_to_id(surface->config);
-                   color = egl_config_get_color_format(configid);
-diff --git a/interface/khronos/egl/egl_client_surface.c b/interface/khronos/egl/egl_client_surface.c
-index 9a9582c..10b3b04 100644
---- a/interface/khronos/egl/egl_client_surface.c
-+++ b/interface/khronos/egl/egl_client_surface.c
-@@ -402,12 +402,14 @@ EGL_SURFACE_T *egl_surface_create(
-    if (type == WINDOW && wl_display) {
-       surface->wl_egl_window = (struct wl_egl_window*)win;
-       surface->front_wl_buffer = NULL;
-+      surface->middle_wl_buffer = NULL;
-       surface->back_wl_buffer = allocate_wl_buffer(
-             surface->wl_egl_window, color);
-       resource = surface->back_wl_buffer->resource;
-    } else {
-       surface->wl_egl_window = NULL;
-       surface->front_wl_buffer = NULL;
-+      surface->middle_wl_buffer = NULL;
-       surface->back_wl_buffer = NULL;
-       resource = DISPMANX_NO_HANDLE;
-    }
-@@ -696,6 +698,12 @@ void egl_surface_free(EGL_SURFACE_T *surface)
-          surface->back_wl_buffer = 0;
-       }
- 
-+      if (surface->middle_wl_buffer) {
-+         wl_buffer_destroy(surface->middle_wl_buffer->wl_buffer);
-+         free(surface->middle_wl_buffer);
-+         surface->middle_wl_buffer = 0;
-+      }
-+
-       if (surface->front_wl_buffer) {
-          wl_buffer_destroy(surface->front_wl_buffer->wl_buffer);
-          free(surface->front_wl_buffer);
-diff --git a/interface/khronos/egl/egl_client_surface.h b/interface/khronos/egl/egl_client_surface.h
-index e328b77..58a3184 100644
---- a/interface/khronos/egl/egl_client_surface.h
-+++ b/interface/khronos/egl/egl_client_surface.h
-@@ -312,6 +312,17 @@ typedef struct {
-    */
-    struct wl_dispmanx_client_buffer *front_wl_buffer;
- 
-+   /*
-+      middle_wl_buffer
-+
-+      Validity:
-+      type == WINDOW
-+
-+      Invariant:
-+      client-side information about the wl_buffer in the middle
-+   */
-+   struct wl_dispmanx_client_buffer *middle_wl_buffer;
-+
-    /*
-       back_wl_buffer
- 
--- 
-2.16.1
-
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0014-GLES2-gl2ext.h-Define-GL_R8_EXT-and-GL_RG8_EXT.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0014-GLES2-gl2ext.h-Define-GL_R8_EXT-and-GL_RG8_EXT.patch
deleted file mode 100644
index 025b6bc..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0014-GLES2-gl2ext.h-Define-GL_R8_EXT-and-GL_RG8_EXT.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 8d9299d219a2a4f76f8278973584e1a9f7116c78 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 10 May 2017 06:39:34 +0000
-Subject: [PATCH 14/16] GLES2/gl2ext.h: Define GL_R8_EXT and GL_RG8_EXT
-
-weston code uses these defines
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- interface/khronos/include/GLES2/gl2ext.h | 3 +++
- 1 file changed, 3 insertions(+)
-
-diff --git a/interface/khronos/include/GLES2/gl2ext.h b/interface/khronos/include/GLES2/gl2ext.h
-index 4eacf7f..283e3e1 100644
---- a/interface/khronos/include/GLES2/gl2ext.h
-+++ b/interface/khronos/include/GLES2/gl2ext.h
-@@ -327,6 +327,9 @@ typedef void* GLeglImageOES;
- #define GL_RGBX_BRCM                                            0x80EE
- #endif
- 
-+#define GL_R8_EXT                                               0x8229
-+#define GL_RG8_EXT                                              0x822B
-+
- /* GL_EXT_texture_type_2_10_10_10_REV */
- #ifndef GL_EXT_texture_type_2_10_10_10_REV
- #define GL_UNSIGNED_INT_2_10_10_10_REV_EXT                      0x8368
--- 
-2.16.1
-
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0015-EGL-glplatform.h-define-EGL_CAST.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0015-EGL-glplatform.h-define-EGL_CAST.patch
deleted file mode 100644
index 605d0c0..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0015-EGL-glplatform.h-define-EGL_CAST.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From a2182e5437a6664cdb0f3330f6cbee873b6f975a Mon Sep 17 00:00:00 2001
-From: Andrea Galbusera <gizero@gmail.com>
-Date: Fri, 14 Jul 2017 09:52:54 +0200
-Subject: [PATCH 15/16] EGL/glplatform.h: define EGL_CAST
-
-C++ / C typecast macros for special EGL handle values: used by libepoxy code
-The definition comes from the updated version of this header in mesa.
-
-Upstream-Status: Pending
----
- interface/khronos/include/EGL/eglplatform.h | 7 +++++++
- 1 file changed, 7 insertions(+)
-
-diff --git a/interface/khronos/include/EGL/eglplatform.h b/interface/khronos/include/EGL/eglplatform.h
-index 1f7c930..c39d425 100644
---- a/interface/khronos/include/EGL/eglplatform.h
-+++ b/interface/khronos/include/EGL/eglplatform.h
-@@ -202,4 +202,11 @@ EGLAPI void EGLAPIENTRY BEGL_GetDefaultDriverInterfaces(BEGL_DriverInterfaces *i
- #include "interface/khronos/common/khrn_client_mangle.h"
- #endif
- 
-+/* C++ / C typecast macros for special EGL handle values */
-+#if defined(__cplusplus)
-+#define EGL_CAST(type, value) (static_cast<type>(value))
-+#else
-+#define EGL_CAST(type, value) ((type) (value))
-+#endif
-+
- #endif /* __eglplatform_h */
--- 
-2.16.1
-
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland/0016-Allow-multiple-wayland-compositor-state-data-per-pro.patch b/meta-raspberrypi/recipes-graphics/userland/userland/0016-Allow-multiple-wayland-compositor-state-data-per-pro.patch
deleted file mode 100644
index d20ec82..0000000
--- a/meta-raspberrypi/recipes-graphics/userland/userland/0016-Allow-multiple-wayland-compositor-state-data-per-pro.patch
+++ /dev/null
@@ -1,145 +0,0 @@
-From 6b4c4d469d435bfcfb464356b6ccc9421c6b8fd5 Mon Sep 17 00:00:00 2001
-From: Jeff Wannamaker <jeff_wannamaker@cable.comcast.com>
-Date: Sat, 27 Jan 2018 12:28:31 -0500
-Subject: [PATCH 16/16] Allow multiple wayland compositor state data per
- process
-
-When eglBindWaylandDisplayWL is called store the wl_global
-created in a list associated with the wayland display.
-This allows multiple wayland compositor instances to be
-created and used per process. This scenario is common for
-applications integrating externl process UI elements
-via embedded composition e.g. westeros
-
-Signed-off-by: Jeff Wannamaker <jeff_wannamaker@cable.comcast.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- interface/khronos/common/khrn_client.c |  2 +-
- interface/khronos/common/khrn_client.h | 11 +++++++-
- interface/khronos/ext/egl_wayland.c    | 50 ++++++++++++++++++++++++++++++----
- 3 files changed, 55 insertions(+), 8 deletions(-)
-
-diff --git a/interface/khronos/common/khrn_client.c b/interface/khronos/common/khrn_client.c
-index d7e798e..60bdb63 100644
---- a/interface/khronos/common/khrn_client.c
-+++ b/interface/khronos/common/khrn_client.c
-@@ -147,7 +147,7 @@ bool client_process_state_init(CLIENT_PROCESS_STATE_T *process)
- {
-    if (!process->inited) {
- #ifdef BUILD_WAYLAND
--      process->wl_global = NULL;
-+      process->wlStateMap = NULL;
- #endif
- 
-       if (!khrn_pointer_map_init(&process->contexts, 64))
-diff --git a/interface/khronos/common/khrn_client.h b/interface/khronos/common/khrn_client.h
-index 615f7b4..4fa86f7 100644
---- a/interface/khronos/common/khrn_client.h
-+++ b/interface/khronos/common/khrn_client.h
-@@ -170,6 +170,15 @@ static INLINE CLIENT_THREAD_STATE_T *CLIENT_GET_CHECK_THREAD_STATE(void)
-    return (CLIENT_THREAD_STATE_T *)platform_tls_get_check(client_tls);
- }
- 
-+#ifdef BUILD_WAYLAND
-+typedef struct WAYLAND_STATE
-+{
-+   struct WAYLAND_STATE *next;
-+   struct wl_display *display;
-+   struct wl_global *wl_global;
-+} WAYLAND_STATE_T;
-+#endif
-+
- /*
-    per-process state
- 
-@@ -318,7 +327,7 @@ struct CLIENT_PROCESS_STATE {
-    struct wl_event_queue *wl_queue;
- 
-    /* Compositor-side Wayland state */
--   struct wl_global *wl_global;
-+   WAYLAND_STATE_T *wlStateMap;
- #endif
- };
- 
-diff --git a/interface/khronos/ext/egl_wayland.c b/interface/khronos/ext/egl_wayland.c
-index 9ef89cd..abd5ab3 100644
---- a/interface/khronos/ext/egl_wayland.c
-+++ b/interface/khronos/ext/egl_wayland.c
-@@ -208,17 +208,38 @@ eglBindWaylandDisplayWL(EGLDisplay dpy, struct wl_display *display)
- {
-    CLIENT_THREAD_STATE_T *thread;
-    CLIENT_PROCESS_STATE_T *process;
-+   WAYLAND_STATE_T *stateIter;
-+   WAYLAND_STATE_T *stateNew;
-+   struct wl_global *wl_global;
- 
-    if (!CLIENT_LOCK_AND_GET_STATES(dpy, &thread, &process))
-       return EGL_FALSE;
- 
--   if (process->wl_global != NULL)
-+   stateIter= process->wlStateMap;
-+   while( stateIter )
-+   {
-+      if ( stateIter->display == display )
-+         goto error;
-+      stateIter= stateIter->next;
-+   }
-+
-+   wl_global = wl_global_create(display, &wl_dispmanx_interface, 1,
-+                                NULL, bind_dispmanx);
-+   if (wl_global == NULL)
-       goto error;
- 
--   process->wl_global = wl_global_create(display, &wl_dispmanx_interface, 1,
--                                         NULL, bind_dispmanx);
--   if (process->wl_global == NULL)
-+   stateNew= (WAYLAND_STATE_T*)calloc( 1, sizeof(WAYLAND_STATE_T));
-+   if (stateNew == NULL )
-+   {
-+      wl_global_destroy(wl_global);
-       goto error;
-+   }
-+
-+   stateNew->next= process->wlStateMap;
-+   stateNew->display= display;
-+   stateNew->wl_global= wl_global;
-+   process->wlStateMap= stateNew;
-+   CLIENT_UNLOCK();
- 
-    return EGL_TRUE;
- 
-@@ -232,12 +253,29 @@ eglUnbindWaylandDisplayWL(EGLDisplay dpy, struct wl_display *display)
- {
-    CLIENT_THREAD_STATE_T *thread;
-    CLIENT_PROCESS_STATE_T *process;
-+   WAYLAND_STATE_T *stateIter;
-+   WAYLAND_STATE_T *statePrev;
- 
-    if (!CLIENT_LOCK_AND_GET_STATES(dpy, &thread, &process))
-       return EGL_FALSE;
- 
--   wl_global_destroy(process->wl_global);
--   process->wl_global = NULL;
-+   statePrev= NULL;
-+   stateIter= process->wlStateMap;
-+   while( stateIter )
-+   {
-+      if ( stateIter->display == display )
-+      {
-+         wl_global_destroy(stateIter->wl_global);
-+         if ( statePrev )
-+            statePrev->next= stateIter->next;
-+         else
-+            process->wlStateMap= stateIter->next;
-+         free( stateIter );
-+         break;
-+      }
-+      statePrev= stateIter;
-+      stateIter= stateIter->next;
-+   }
- 
-    CLIENT_UNLOCK();
- 
--- 
-2.16.1
-
diff --git a/meta-raspberrypi/recipes-graphics/userland/userland_git.bb b/meta-raspberrypi/recipes-graphics/userland/userland_git.bb
index 7f2dca6..e6af4bf 100644
--- a/meta-raspberrypi/recipes-graphics/userland/userland_git.bb
+++ b/meta-raspberrypi/recipes-graphics/userland/userland_git.bb
@@ -5,20 +5,18 @@
 LICENSE = "BSD-3-Clause"
 LIC_FILES_CHKSUM = "file://LICENCE;md5=0448d6488ef8cc380632b1569ee6d196"
 
-PROVIDES = "virtual/libgles2 \
-            virtual/egl"
+PROVIDES += "${@bb.utils.contains("MACHINE_FEATURES", "vc4graphics", "", "virtual/libgles2 virtual/egl", d)}"
 
-RPROVIDES_${PN} += "libgles2 egl libegl"
-
+RPROVIDES_${PN} += "${@bb.utils.contains("MACHINE_FEATURES", "vc4graphics", "", "libgles2 egl libegl libegl1 libgl1 libglesv2-2", d)}"
 COMPATIBLE_MACHINE = "^rpi$"
 
 SRCBRANCH = "master"
 SRCFORK = "raspberrypi"
-SRCREV = "11389772c79685442e0ab8aa9be8ad0e32703f68"
+SRCREV = "d574b51a60a075baefe863670466ee24e6c4256e"
 
 # Use the date of the above commit as the package version. Update this when
 # SRCREV is changed.
-PV = "20180219"
+PV = "20181120"
 
 SRC_URI = "\
     git://github.com/${SRCFORK}/userland.git;protocol=git;branch=${SRCBRANCH} \
@@ -38,6 +36,8 @@
     file://0014-GLES2-gl2ext.h-Define-GL_R8_EXT-and-GL_RG8_EXT.patch \
     file://0015-EGL-glplatform.h-define-EGL_CAST.patch \
     file://0016-Allow-multiple-wayland-compositor-state-data-per-pro.patch \
+    file://0017-khronos-backport-typedef-for-EGL_EXT_image_dma_buf_i.patch \
+    file://0018-Add-EGL_IMG_context_priority-related-defines.patch \
 "
 S = "${WORKDIR}/git"
 
@@ -64,6 +64,14 @@
 		sed -i 's/include "vcos_futex_mutex.h"/include "pthreads\/vcos_futex_mutex.h"/g' ${f}
 		sed -i 's/include "vcos_platform_types.h"/include "pthreads\/vcos_platform_types.h"/g' ${f}
 	done
+	if [ "${@bb.utils.contains("MACHINE_FEATURES", "vc4graphics", "1", "0", d)}" = "1" ]; then
+		rm -rf ${D}${libdir}/libEGL*
+		rm -rf ${D}${libdir}/libGLES*
+		rm -rf ${D}${libdir}/libwayland-*
+		rm -rf ${D}${libdir}/pkgconfig/egl.pc ${D}${libdir}/pkgconfig/glesv2.pc \
+			${D}${libdir}/pkgconfig/wayland-egl.pc
+		rm -rf ${D}${includedir}/EGL ${D}${includedir}/GLES* ${D}${includedir}/KHR
+	fi
 }
 
 # Shared libs from userland package  build aren't versioned, so we need
@@ -83,3 +91,4 @@
 PACKAGE_ARCH = "${MACHINE_ARCH}"
 
 RDEPENDS_${PN} += "bash"
+RDEPENDS_${PN} += "${@bb.utils.contains("MACHINE_FEATURES", "vc4graphics", "libegl1", "", d)}"
diff --git a/meta-raspberrypi/recipes-graphics/wayland/wayland_%.bbappend b/meta-raspberrypi/recipes-graphics/wayland/wayland_%.bbappend
new file mode 100644
index 0000000..e5bbf4a
--- /dev/null
+++ b/meta-raspberrypi/recipes-graphics/wayland/wayland_%.bbappend
@@ -0,0 +1,7 @@
+# until fully tested, prefer `libwayland-egl` provided by `userland` instead of `wayland` when not using vc4graphics
+do_install_append_rpi () {
+    if [ "${@bb.utils.contains("MACHINE_FEATURES", "vc4graphics", "1", "0", d)}" = "0" ]; then
+        rm -f ${D}${libdir}/libwayland-egl*
+        rm -f ${D}${libdir}/pkgconfig/wayland-egl.pc
+    fi
+}
diff --git a/meta-raspberrypi/recipes-graphics/xorg-xserver/xserver-xf86-config/rpi/xorg.conf.d/10-noglamor.conf b/meta-raspberrypi/recipes-graphics/xorg-xserver/xserver-xf86-config/rpi/xorg.conf.d/10-noglamor.conf
deleted file mode 100644
index 1a562ea..0000000
--- a/meta-raspberrypi/recipes-graphics/xorg-xserver/xserver-xf86-config/rpi/xorg.conf.d/10-noglamor.conf
+++ /dev/null
@@ -1,6 +0,0 @@
-# 
-Section "Device"
-	Identifier "modeset"
-	Driver "modesetting"
-	Option "AccelMethod" "None"
-EndSection
diff --git a/meta-raspberrypi/recipes-graphics/xorg-xserver/xserver-xf86-config_%.bbappend b/meta-raspberrypi/recipes-graphics/xorg-xserver/xserver-xf86-config_%.bbappend
index 919e95e..71e0adc 100644
--- a/meta-raspberrypi/recipes-graphics/xorg-xserver/xserver-xf86-config_%.bbappend
+++ b/meta-raspberrypi/recipes-graphics/xorg-xserver/xserver-xf86-config_%.bbappend
@@ -3,19 +3,14 @@
 SRC_URI_append_rpi = " \
     file://xorg.conf.d/98-pitft.conf \
     file://xorg.conf.d/99-calibration.conf \
-    file://xorg.conf.d/10-noglamor.conf \
 "
 do_install_append_rpi () {
     PITFT="${@bb.utils.contains("MACHINE_FEATURES", "pitft", "1", "0", d)}"
-    VC4="${@bb.utils.contains("MACHINE_FEATURES", "vc4graphics", "1", "0", d)}"
     if [ "${PITFT}" = "1" ]; then
         install -d ${D}/${sysconfdir}/X11/xorg.conf.d/
         install -m 0644 ${WORKDIR}/xorg.conf.d/98-pitft.conf ${D}/${sysconfdir}/X11/xorg.conf.d/
         install -m 0644 ${WORKDIR}/xorg.conf.d/99-calibration.conf ${D}/${sysconfdir}/X11/xorg.conf.d/
     fi
-    if [ "${VC4}" = "1" ]; then
-        install -Dm 0644 ${WORKDIR}/xorg.conf.d/10-noglamor.conf ${D}/${sysconfdir}/X11/xorg.conf.d/10-noglamor.conf
-    fi
 }
 
 FILES_${PN}_rpi += "${sysconfdir}/X11/xorg.conf ${sysconfdir}/X11/xorg.conf.d/*"
diff --git a/meta-raspberrypi/recipes-kernel/bluez-firmware-rpidistro/bluez-firmware-rpidistro_git.bb b/meta-raspberrypi/recipes-kernel/bluez-firmware-rpidistro/bluez-firmware-rpidistro_git.bb
new file mode 100644
index 0000000..b16b2c1
--- /dev/null
+++ b/meta-raspberrypi/recipes-kernel/bluez-firmware-rpidistro/bluez-firmware-rpidistro_git.bb
@@ -0,0 +1,84 @@
+SUMMARY = "Linux kernel Bluetooth firmware files from Raspbian distribution"
+DESCRIPTION = "Updated Bluetooth firmware files for RaspberryPi hardware. \
+RPi-Distro obtains these directly from Cypress; they are not submitted \
+to linux-firmware for general use."
+HOMEPAGE = "https://github.com/RPi-Distro/bluez-firmware"
+SECTION = "kernel"
+
+# Upstream has provided[^1] licensing information in the Debian
+# copyright file.  The wording of the Cypress license subsequently
+# changed in linux-firmware.
+#
+# Rather than make assumptions about what's supposed to be what, we'll
+# use the license implied by the source of these files, named to avoid
+# conflicts with linux-firmware.
+#
+# [^1]: https://github.com/RPi-Distro/bluez-firmware/issues/1
+LICENSE = "Firmware-cypress-rpidistro"
+LIC_FILES_CHKSUM = "\
+    file://LICENCE.cypress-rpidistro;md5=852f9d10cbedba1f6c439729bd0617b4 \
+"
+
+# These are not common licenses, set NO_GENERIC_LICENSE for them
+# so that the license files will be copied from fetched source
+NO_GENERIC_LICENSE[Firmware-cypress-rpidistro] = "LICENCE.cypress-rpidistro"
+
+SRC_URI = "git://github.com/RPi-Distro/bluez-firmware"
+SRCREV = "ade2bae1aaaebede09abb8fb546f767a0e4c7804"
+PV = "0.0+git${SRCPV}"
+
+S = "${WORKDIR}/git"
+
+inherit allarch
+
+CLEANBROKEN = "1"
+
+do_extract_lic() {
+    # Extract the license from the Debian copyright file
+    sed -e '1,23d' ${S}/debian/copyright > ${S}/LICENCE.cypress-rpidistro
+}
+# Must be before both do_install and do_populate_lic.  Putting it before
+# their common ancestor works; other approaches do not.
+addtask extract_lic after do_unpack before do_patch
+
+do_compile() {
+    :
+}
+
+do_install() {
+    install -d ${D}${nonarch_base_libdir}/firmware/brcm
+
+    cp LICENCE.cypress-rpidistro ${D}${nonarch_base_libdir}/firmware
+    install -m 0644 broadcom/BCM434*.hcd ${D}${nonarch_base_libdir}/firmware/brcm/
+}
+
+PACKAGES = "\
+    ${PN}-cypress-license \
+    ${PN}-bcm43430a1-hcd \
+    ${PN}-bcm4345c0-hcd \
+"
+
+LICENSE_${PN}-bcm43430a1-hcd = "Firmware-cypress-rpidistro"
+LICENSE_${PN}-bcm4345c0-hcd = "Firmware-cypress-rpidistro"
+LICENSE_${PN}-cypress-license = "Firmware-cypress-rpidistro"
+
+FILES_${PN}-cypress-license = "\
+    ${nonarch_base_libdir}/firmware/LICENCE.cypress-rpidistro \
+"
+FILES_${PN}-bcm43430a1-hcd = "\
+    ${nonarch_base_libdir}/firmware/brcm/BCM43430A1.hcd \
+"
+FILES_${PN}-bcm4345c0-hcd = "\
+    ${nonarch_base_libdir}/firmware/brcm/BCM4345C0.hcd \
+"
+
+RDEPENDS_${PN}-bcm43430a1-hcd += "${PN}-cypress-license"
+RDEPENDS_${PN}-bcm4345c0-hcd += "${PN}-cypress-license"
+RCONFLICTS_${PN}-bcm43430a1-hcd = "linux-firmware-bcm43430a1-hcd"
+RREPLACES_${PN}-bcm43430a1-hcd = "linux-firmware-bcm43430a1-hcd"
+RCONFLICTS_${PN}-bcm43435c0-hcd = "linux-firmware-bcm4345c0-hcd"
+RREPLACES_${PN}-bcm43435c0-hcd = "linux-firmware-bcm4345c0-hcd"
+
+# Firmware files are generally not run on the CPU, so they can be
+# allarch despite being architecture specific
+INSANE_SKIP = "arch"
diff --git a/meta-raspberrypi/recipes-kernel/linux-firmware-rpidistro/linux-firmware-rpidistro_git.bb b/meta-raspberrypi/recipes-kernel/linux-firmware-rpidistro/linux-firmware-rpidistro_git.bb
new file mode 100644
index 0000000..1f63c32
--- /dev/null
+++ b/meta-raspberrypi/recipes-kernel/linux-firmware-rpidistro/linux-firmware-rpidistro_git.bb
@@ -0,0 +1,96 @@
+SUMMARY = "Linux kernel firmware files from Raspbian distribution"
+DESCRIPTION = "Updated firmware files for RaspberryPi hardware. \
+RPi-Distro obtains these directly from Cypress; they are not submitted \
+to linux-firmware for general use."
+HOMEPAGE = "https://github.com/RPi-Distro/firmware-nonfree"
+SECTION = "kernel"
+
+# In maintained upstream linux-firmware:
+# * brcmfmac43430-sdio falls under LICENCE.cypress
+# * brcmfmac43455-sdio falls under LICENCE.broadcom_bcm43xx
+#
+# It is likely[^1] that both of these should be under LICENCE.cypress.
+# Further, at this time the text of LICENCE.broadcom_bcm43xx is the same
+# in linux-firmware and RPi-Distro/firmware-nonfree, but this may
+# change.
+#
+# Rather than make assumptions about what's supposed to be what, we'll
+# use the license implied by the source of these files, named to avoid
+# conflicts with linux-firmware.
+#
+# [^1]: https://github.com/RPi-Distro/bluez-firmware/issues/1
+LICENSE = "\
+    Firmware-broadcom_bcm43xx-rpidistro \
+    & WHENCE \
+"
+LIC_FILES_CHKSUM = "\
+    file://LICENCE.broadcom_bcm43xx;md5=3160c14df7228891b868060e1951dfbc \
+    file://WHENCE;md5=a9c2c217f513c20e1d16b384b3e2c12d \
+"
+
+# These are not common licenses, set NO_GENERIC_LICENSE for them
+# so that the license files will be copied from fetched source
+NO_GENERIC_LICENSE[Firmware-broadcom_bcm43xx-rpidistro] = "LICENCE.broadcom_bcm43xx"
+NO_GENERIC_LICENSE[WHENCE] = "WHENCE"
+
+SRC_URI = "git://github.com/RPi-Distro/firmware-nonfree"
+SRCREV = "b518de45ced519e8f7a499f4778100173402ae43"
+PV = "0.0+git${SRCPV}"
+
+S = "${WORKDIR}/git"
+
+inherit allarch
+
+CLEANBROKEN = "1"
+
+do_compile() {
+    :
+}
+
+do_install() {
+    install -d ${D}${nonarch_base_libdir}/firmware/brcm
+
+    cp ./LICENCE.broadcom_bcm43xx ${D}${nonarch_base_libdir}/firmware/LICENCE.broadcom_bcm43xx-rpidistro
+
+    # Replace outdated linux-firmware files with updated ones from
+    # raspbian firmware-nonfree. Raspbian adds blobs and nvram
+    # definitions that are also necessary so copy those too.
+    for fw in brcmfmac43430-sdio brcmfmac43455-sdio ; do
+        install -m 0644 brcm/${fw}.* ${D}${nonarch_base_libdir}/firmware/brcm/
+    done
+}
+
+PACKAGES = "\
+    ${PN}-broadcom-license \
+    ${PN}-bcm43430 \
+    ${PN}-bcm43455 \
+"
+
+LICENSE_${PN}-bcm43430 = "Firmware-broadcom_bcm43xx-rpidistro"
+LICENSE_${PN}-bcm43455 = "Firmware-broadcom_bcm43xx-rpidistro"
+LICENSE_${PN}-broadcom-license = "Firmware-broadcom_bcm43xx-rpidistro"
+FILES_${PN}-broadcom-license = "${nonarch_base_libdir}/firmware/LICENCE.broadcom_bcm43xx-rpidistro"
+FILES_${PN}-bcm43430 = "${nonarch_base_libdir}/firmware/brcm/brcmfmac43430*"
+FILES_${PN}-bcm43455 = "${nonarch_base_libdir}/firmware/brcm/brcmfmac43455*"
+RDEPENDS_${PN}-bcm43430 += "${PN}-broadcom-license"
+RDEPENDS_${PN}-bcm43455 += "${PN}-broadcom-license"
+RCONFLICTS_${PN}-bcm43430 = "\
+    linux-firmware-bcm43430 \
+    linux-firmware-raspbian-bcm43430 \
+"
+RREPLACES_${PN}-bcm43430 = "\
+    linux-firmware-bcm43430 \
+    linux-firmware-raspbian-bcm43430 \
+"
+RCONFLICTS_${PN}-bcm43455 = "\
+    linux-firmware-bcm43455 \
+    linux-firmware-raspbian-bcm43455 \
+"
+RREPLACES_${PN}-bcm43455 = "\
+    linux-firmware-bcm43455 \
+    linux-firmware-raspbian-bcm43455 \
+"
+
+# Firmware files are generally not run on the CPU, so they can be
+# allarch despite being architecture specific
+INSANE_SKIP = "arch"
diff --git a/meta-raspberrypi/recipes-kernel/linux-firmware/linux-firmware_%.bbappend b/meta-raspberrypi/recipes-kernel/linux-firmware/linux-firmware_%.bbappend
deleted file mode 100644
index c0f9e17..0000000
--- a/meta-raspberrypi/recipes-kernel/linux-firmware/linux-firmware_%.bbappend
+++ /dev/null
@@ -1,69 +0,0 @@
-# Augments upstream linux-firmware with additional and updated images
-# from Raspbian:
-# https://github.com/RPi-Distro/firmware-nonfree
-# https://github.com/RPi-Distro/bluez-firmware
-
-SRC_URI_append_rpi = " \
-    git://github.com/RPi-Distro/firmware-nonfree;destsuffix=raspbian-nf;name=raspbian-nf \
-    git://github.com/RPi-Distro/bluez-firmware;destsuffix=raspbian-bluez;name=raspbian-bluez \
-"
-
-SRCREV_raspbian-nf = "86e88fbf0345da49555d0ec34c80b4fbae7d0cd3"
-SRCREV_raspbian-bluez = "e28cd7ee8615de33aa7ec2b41d556af61a4a2707"
-SRCREV_FORMAT_rpi = "default+raspbian-nf+raspbian-bluez"
-
-do_install_append_rpi() {
-    install -d ${D}${nonarch_base_libdir}/firmware/brcm/
-
-    # Replace outdated linux-firmware files with updated ones from
-    # raspbian firmware-nonfree. Raspbian adds blobs and nvram
-    # definitions that are also necessary so copy those too.
-    for fw in brcmfmac43430-sdio brcmfmac43455-sdio ; do
-        install -m 0644 ${WORKDIR}/raspbian-nf/brcm/${fw}.* ${D}${nonarch_base_libdir}/firmware/brcm/
-    done
-
-    # Add missing Cypress Bluetooth files from raspbian bluez-firmware
-    for fw in BCM43430A1.hcd BCM4345C0.hcd ; do
-        install -m 0644 ${WORKDIR}/raspbian-bluez/broadcom/${fw} ${D}${nonarch_base_libdir}/firmware/brcm/
-    done
-}
-
-# NB: Must prepend, else these become empty and their content is left in
-# the roll-up package which precedes them.
-PACKAGES_prepend_rpi = "\
-    ${PN}-bcm43430a1-hcd \
-    ${PN}-bcm4345c0-hcd \
-"
-
-# ${PN}-bcm43455 package and brcmfmac43455-sdio from linux-firmware
-# is already included in the oe-core recipe, so don't add it to PACKAGES
-# again, the version from raspbian-nf seems a bit newer:
-# $ strings ./1_0.0+gitAUTOINC+d114732723+86e88fbf03+e28cd7ee86-r0/git/brcm/brcmfmac43455-sdio.bin | grep Ver
-# Version: 7.45.18.0 CRC: d7226371 Date: Sun 2015-03-01 07:31:57 PST Ucode Ver: 1026.2 FWID: 01-6a2c8ad4
-# $ strings ./1_0.0+gitAUTOINC+d114732723+86e88fbf03+e28cd7ee86-r0/raspbian-nf/brcm/brcmfmac43455-sdio.bin | grep Ver
-# Version: 7.45.154 (r684107 CY) CRC: b1f79383 Date: Tue 2018-02-27 03:18:17 PST Ucode Ver: 1043.2105 FWID 01-4fbe0b04
-
-# For additional Broadcom
-LICENSE_${PN}-bcm43455 = "Firmware-broadcom_bcm43xx"
-
-FILES_${PN}-bcm43430_append_rpi = " \
-  ${nonarch_base_libdir}/firmware/brcm/brcmfmac43430-sdio.txt \
-"
-FILES_${PN}-bcm43455 = " \
-  ${nonarch_base_libdir}/firmware/brcm/brcmfmac43455-sdio.* \
-"
-
-RDEPENDS_${PN}-bcm43455 += "${PN}-broadcom-license"
-
-LICENSE_${PN}-bcm43430a1-hcd = "Firmware-cypress"
-LICENSE_${PN}-bcm4345c0-hcd = "Firmware-cypress"
-
-FILES_${PN}-bcm43430a1-hcd = " \
-  ${nonarch_base_libdir}/firmware/brcm/BCM43430A1.hcd \
-"
-FILES_${PN}-bcm4345c0-hcd = " \
-  ${nonarch_base_libdir}/firmware/brcm/BCM4345C0.hcd \
-"
-
-RDEPENDS_${PN}-bcm43430a1-hcd += "${PN}-cypress-license"
-RDEPENDS_${PN}-bcm4345c0-hcd += "${PN}-cypress-license"
diff --git a/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi-rt_4.14.bb b/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi-rt_4.14.bb
new file mode 100644
index 0000000..1a990fe
--- /dev/null
+++ b/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi-rt_4.14.bb
@@ -0,0 +1,9 @@
+LINUX_VERSION ?= "4.14.81"
+
+SRCREV = "acf578d07d57480674d5361df9171fe9528765cb"
+SRC_URI = " \
+    git://github.com/raspberrypi/linux.git;branch=rpi-4.14.y-rt \
+    file://0001-menuconfig-check-lxdiaglog.sh-Allow-specification-of.patch \
+    "
+
+require linux-raspberrypi.inc
diff --git a/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi.inc b/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi.inc
index 03acfb4..01f2425 100644
--- a/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi.inc
+++ b/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi.inc
@@ -35,8 +35,6 @@
 CMDLINE_DEBUG ?= ""
 CMDLINE_append = " ${CMDLINE_DEBUG}"
 
-KERNEL_INITRAMFS ?= '${@oe.utils.conditional("INITRAMFS_IMAGE_BUNDLE", "1", "1", "", d)}'
-
 KERNEL_MODULE_AUTOLOAD += "${@bb.utils.contains("MACHINE_FEATURES", "pitft28r", "stmpe-ts", "", d)}"
 
 # A LOADADDR is needed when building a uImage format kernel. This value is not
@@ -101,7 +99,7 @@
     # Localversion
     kernel_configure_variable LOCALVERSION "\"\""
 
-    if [ ! -z "${KERNEL_INITRAMFS}" ]; then
+    if [ "${INITRAMFS_IMAGE_BUNDLE}" = "1" ]; then
         kernel_configure_variable OVERLAY_FS y
         kernel_configure_variable SQUASHFS y
         kernel_configure_variable UBIFS_FS y
@@ -109,7 +107,7 @@
 
     # Activate the configuration options for VC4
     VC4GRAPHICS="${@bb.utils.contains("MACHINE_FEATURES", "vc4graphics", "1", "0", d)}"
-    if [ ${VC4GRAPHICS} = "1" ]; then
+    if [ "${VC4GRAPHICS}" = "1" ]; then
         kernel_configure_variable I2C_BCM2835 y
         kernel_configure_variable DRM y
         kernel_configure_variable DRM_FBDEV_EMULATION y
diff --git a/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_4.14.bb b/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_4.14.bb
index 54936fa..d11b599 100644
--- a/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_4.14.bb
+++ b/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_4.14.bb
@@ -1,6 +1,6 @@
-LINUX_VERSION ?= "4.14.68"
+LINUX_VERSION ?= "4.14.79"
 
-SRCREV = "8c8666ff6c1254d325cfa300d16f9928b3f31fc0"
+SRCREV = "9ca74c53cbda1f104bce3b33850fd3bf33eb3793"
 SRC_URI = " \
     git://github.com/raspberrypi/linux.git;branch=rpi-4.14.y \
     file://0001-menuconfig-check-lxdiaglog.sh-Allow-specification-of.patch \
diff --git a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.12/0002-fix-decoder-flushing.patch b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.12/0002-fix-decoder-flushing.patch
deleted file mode 100644
index 122ddb3..0000000
--- a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.12/0002-fix-decoder-flushing.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-From fc4773f36aa31b4ae0fc97d3aa3f94db0c88f194 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 11 Feb 2016 12:53:20 -0800
-
----
- omx/gstomx.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/omx/gstomx.c b/omx/gstomx.c
-index 0237f3c..45732c3 100644
---- a/omx/gstomx.c
-+++ b/omx/gstomx.c
-@@ -1538,8 +1538,8 @@ gst_omx_port_set_flushing (GstOMXPort * port, GstClockTime timeout,
-     last_error = OMX_ErrorNone;
-     gst_omx_component_handle_messages (comp);
-     while (signalled && last_error == OMX_ErrorNone && !port->flushed
--        && port->buffers
--        && port->buffers->len > g_queue_get_length (&port->pending_buffers)) {
-+     /* && port->buffers
-+        && port->buffers->len > g_queue_get_length (&port->pending_buffers) */) {
-       signalled = gst_omx_component_wait_message (comp, timeout);
-       if (signalled)
-         gst_omx_component_handle_messages (comp);
diff --git a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.12/0004-Properly-handle-drain-requests-while-flushing.patch b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.12/0004-Properly-handle-drain-requests-while-flushing.patch
deleted file mode 100644
index b02072a..0000000
--- a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.12/0004-Properly-handle-drain-requests-while-flushing.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From f00912f0628aff15e882bdc1619f5de1ddf5c720 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Enrique=20Oca=C3=B1a=20Gonz=C3=A1lez?= <eocanha@igalia.com>
-Date: Tue, 17 Nov 2015 16:51:27 +0000
-Subject: [PATCH] Properly handle drain requests while flushing
-
-Without this commit the decoder streaming thread stops without ever attending
-the drain request, leaving the decoder input thread waiting forever.
-
----
- omx/gstomx.c | 7 +++++++
- 1 file changed, 7 insertions(+)
-
-diff --git a/omx/gstomx.c b/omx/gstomx.c
-index 45732c3..784a5d7 100644
---- a/omx/gstomx.c
-+++ b/omx/gstomx.c
-@@ -737,6 +737,13 @@ gst_omx_component_new (GstObject * parent, const gchar * core_name,
- 
-   g_mutex_lock (&comp->lock);
-   gst_omx_component_handle_messages (comp);
-+
-+  if (err != OMX_ErrorNone && comp->last_error == OMX_ErrorNone) {
-+    GST_ERROR_OBJECT (comp->parent,
-+        "Last operation returned an error. Setting last_error manually.");
-+    comp->last_error = err;
-+  }
-+
-   g_mutex_unlock (&comp->lock);
- 
-   return comp;
diff --git a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.12/0005-Don-t-abort-gst_omx_video_dec_set_format-if-there-s-.patch b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.12/0005-Don-t-abort-gst_omx_video_dec_set_format-if-there-s-.patch
deleted file mode 100644
index fdfdd1b..0000000
--- a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.12/0005-Don-t-abort-gst_omx_video_dec_set_format-if-there-s-.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 0d2ad639e6158c8023c157e206ef3ff7abdc089c Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Enrique=20Oca=C3=B1a=20Gonz=C3=A1lez?= <eocanha@igalia.com>
-Date: Fri, 4 Dec 2015 18:39:59 +0100
-Subject: [PATCH] Don't abort gst_omx_video_dec_set_format() if there's a
- timeout releasing the buffers taken by the egl_render out port
-
----
- omx/gstomxvideodec.c | 5 ++++-
- 1 file changed, 4 insertions(+), 1 deletion(-)
-
-diff --git a/omx/gstomxvideodec.c b/omx/gstomxvideodec.c
-index bad6335..c63b972 100644
---- a/omx/gstomxvideodec.c
-+++ b/omx/gstomxvideodec.c
-@@ -1911,8 +1911,11 @@ gst_omx_video_dec_set_format (GstVideoDecoder * decoder,
-               5 * GST_SECOND) != OMX_ErrorNone)
-         return FALSE;
-       if (gst_omx_port_wait_buffers_released (out_port,
--              1 * GST_SECOND) != OMX_ErrorNone)
-+              1 * GST_SECOND) != OMX_ErrorNone) {
-+#if !(defined (USE_OMX_TARGET_RPI) && defined (HAVE_GST_GL))
-         return FALSE;
-+#endif
-+      }
-       if (gst_omx_port_deallocate_buffers (self->dec_in_port) != OMX_ErrorNone)
-         return FALSE;
-       if (gst_omx_video_dec_deallocate_output_buffers (self) != OMX_ErrorNone)
diff --git a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.12/0001-Don-t-try-to-acquire-buffer-when-src-pad-isn-t-activ.patch b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.14/0001-Don-t-try-to-acquire-buffer-when-src-pad-isn-t-activ.patch
similarity index 100%
rename from meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.12/0001-Don-t-try-to-acquire-buffer-when-src-pad-isn-t-activ.patch
rename to meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.14/0001-Don-t-try-to-acquire-buffer-when-src-pad-isn-t-activ.patch
diff --git a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.12/0001-config-files-path.patch b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.14/0001-config-files-path.patch
similarity index 100%
rename from meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.12/0001-config-files-path.patch
rename to meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.14/0001-config-files-path.patch
diff --git a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.12/0003-no-timeout-on-get-state.patch b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.14/0003-no-timeout-on-get-state.patch
similarity index 100%
rename from meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.12/0003-no-timeout-on-get-state.patch
rename to meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.14/0003-no-timeout-on-get-state.patch
diff --git a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.14/0004-Properly-handle-drain-requests-while-flushing.patch b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.14/0004-Properly-handle-drain-requests-while-flushing.patch
new file mode 100644
index 0000000..3c9dd2c
--- /dev/null
+++ b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.14/0004-Properly-handle-drain-requests-while-flushing.patch
@@ -0,0 +1,30 @@
+From f00912f0628aff15e882bdc1619f5de1ddf5c720 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Enrique=20Oca=C3=B1a=20Gonz=C3=A1lez?= <eocanha@igalia.com>
+Date: Tue, 17 Nov 2015 16:51:27 +0000
+Subject: [PATCH] Properly handle drain requests while flushing
+
+Without this commit the decoder streaming thread stops without ever attending
+the drain request, leaving the decoder input thread waiting forever.
+
+---
+ omx/gstomx.c | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+Index: gst-omx-1.14.0/omx/gstomx.c
+===================================================================
+--- gst-omx-1.14.0.orig/omx/gstomx.c
++++ gst-omx-1.14.0/omx/gstomx.c
+@@ -837,6 +837,13 @@ gst_omx_component_new (GstObject * paren
+ 
+   g_mutex_lock (&comp->lock);
+   gst_omx_component_handle_messages (comp);
++
++  if (err != OMX_ErrorNone && comp->last_error == OMX_ErrorNone) {
++    GST_ERROR_OBJECT (comp->parent,
++        "Last operation returned an error. Setting last_error manually.");
++    comp->last_error = err;
++  }
++
+   g_mutex_unlock (&comp->lock);
+ 
+   return comp;
diff --git a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.14/0005-Don-t-abort-gst_omx_video_dec_set_format-if-there-s-.patch b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.14/0005-Don-t-abort-gst_omx_video_dec_set_format-if-there-s-.patch
new file mode 100644
index 0000000..ed8645e
--- /dev/null
+++ b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx-1.14/0005-Don-t-abort-gst_omx_video_dec_set_format-if-there-s-.patch
@@ -0,0 +1,24 @@
+From 0d2ad639e6158c8023c157e206ef3ff7abdc089c Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Enrique=20Oca=C3=B1a=20Gonz=C3=A1lez?= <eocanha@igalia.com>
+Date: Fri, 4 Dec 2015 18:39:59 +0100
+Subject: [PATCH] Don't abort gst_omx_video_dec_set_format() if there's a
+ timeout releasing the buffers taken by the egl_render out port
+
+---
+ omx/gstomxvideodec.c | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+Index: gst-omx-1.14.0/omx/gstomxvideodec.c
+===================================================================
+--- gst-omx-1.14.0.orig/omx/gstomxvideodec.c
++++ gst-omx-1.14.0/omx/gstomxvideodec.c
+@@ -2214,7 +2214,9 @@ gst_omx_video_dec_disable (GstOMXVideoDe
+       return FALSE;
+     if (gst_omx_port_wait_buffers_released (out_port,
+             1 * GST_SECOND) != OMX_ErrorNone)
++#if !(defined (USE_OMX_TARGET_RPI) && defined (HAVE_GST_GL))
+       return FALSE;
++#endif
+     if (gst_omx_video_dec_deallocate_output_buffers (self) != OMX_ErrorNone)
+       return FALSE;
+     if (gst_omx_port_wait_enabled (out_port, 1 * GST_SECOND) != OMX_ErrorNone)
diff --git a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx_%.bbappend b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx_%.bbappend
index 67e46de..f892c66 100644
--- a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx_%.bbappend
+++ b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx_%.bbappend
@@ -1,9 +1,9 @@
+DEPENDS_append_rpi = " userland"
 GSTREAMER_1_0_OMX_TARGET_rpi = "rpi"
 GSTREAMER_1_0_OMX_CORE_NAME_rpi = "${libdir}/libopenmaxil.so"
-
-
 # How to make this RPI specific?
 EXTRA_OECONF_append_rpi  = " CFLAGS="$CFLAGS -I${STAGING_DIR_TARGET}/usr/include/IL -I${STAGING_DIR_TARGET}/usr/include/interface/vcos/pthreads -I${STAGING_DIR_TARGET}/usr/include/interface/vmcs_host/linux""
 #examples only build with GL but not GLES, so disable it for RPI
 EXTRA_OECONF_append_rpi = " --disable-examples"
 
+RDEPENDS_${PN}_append_rpi = " userland"
diff --git a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx_1.12%.bbappend b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx_1.12%.bbappend
deleted file mode 100644
index 93381a4..0000000
--- a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx_1.12%.bbappend
+++ /dev/null
@@ -1,13 +0,0 @@
-#
-# Need to make this conditional to gstreamer1
-#
-SRC_URI_append_rpi = " \
-             file://0001-config-files-path.patch \
-             file://0001-Don-t-try-to-acquire-buffer-when-src-pad-isn-t-activ.patch \
-             file://0002-fix-decoder-flushing.patch \
-             file://0003-no-timeout-on-get-state.patch \
-             file://0004-Properly-handle-drain-requests-while-flushing.patch \
-             file://0005-Don-t-abort-gst_omx_video_dec_set_format-if-there-s-.patch \
-"
-
-FILESEXTRAPATHS_prepend := "${THISDIR}/gstreamer1.0-omx-1.12:"
diff --git a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx_1.14%.bbappend b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx_1.14%.bbappend
new file mode 100644
index 0000000..cb7986b
--- /dev/null
+++ b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-omx_1.14%.bbappend
@@ -0,0 +1,12 @@
+#
+# Need to make this conditional to gstreamer1
+#
+SRC_URI_append_rpi = " \
+             file://0001-config-files-path.patch \
+             file://0001-Don-t-try-to-acquire-buffer-when-src-pad-isn-t-activ.patch \
+             file://0003-no-timeout-on-get-state.patch \
+             file://0004-Properly-handle-drain-requests-while-flushing.patch \
+             file://0005-Don-t-abort-gst_omx_video_dec_set_format-if-there-s-.patch \
+"
+
+FILESEXTRAPATHS_prepend := "${THISDIR}/gstreamer1.0-omx-1.14:"
diff --git a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_%.bbappend b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_%.bbappend
index 7292f90..899a2d4 100644
--- a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_%.bbappend
+++ b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_%.bbappend
@@ -1,12 +1 @@
-EXTRA_OECONF_append_rpi = " CPPFLAGS='-I${STAGING_INCDIR}/interface/vcos/pthreads \
-                                   -I${STAGING_INCDIR}/interface/vmcs_host/linux'"
-
-# if using bcm driver enable dispmanx not when using VC4 driver
-
-PACKAGECONFIG_append_rpi = "${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', '', ' dispmanx', d)}"
-
-PACKAGECONFIG_GL_rpi = "egl gles2"
-
 PACKAGECONFIG_append_rpi = " hls libmms faad"
-
-PACKAGECONFIG[dispmanx] = "--enable-dispmanx,--disable-dispmanx,userland"
diff --git a/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_%.bbappend b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_%.bbappend
new file mode 100644
index 0000000..9e86c00
--- /dev/null
+++ b/meta-raspberrypi/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_%.bbappend
@@ -0,0 +1,10 @@
+EXTRA_OECONF_append_rpi = " CPPFLAGS='-I${STAGING_INCDIR}/interface/vcos/pthreads \
+                                   -I${STAGING_INCDIR}/interface/vmcs_host/linux'"
+
+# if using bcm driver enable dispmanx not when using VC4 driver
+
+PACKAGECONFIG_append_rpi = "${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', '', ' dispmanx', d)}"
+
+PACKAGECONFIG_GL_rpi = "egl gles2"
+
+PACKAGECONFIG[dispmanx] = "--enable-dispmanx,--disable-dispmanx,userland"
diff --git a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0001-Fix-build-with-vc4-driver.patch b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0001-Fix-build-with-vc4-driver.patch
new file mode 100644
index 0000000..37d0724
--- /dev/null
+++ b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0001-Fix-build-with-vc4-driver.patch
@@ -0,0 +1,49 @@
+From 25302469b6ceb2fa10ac68c07da25c6068ffd218 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 7 Nov 2018 01:16:59 -0800
+Subject: [PATCH] Fix build with vc4 driver
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ SubtitleRenderer.cpp | 7 ++++++-
+ SubtitleRenderer.h   | 1 +
+ 2 files changed, 7 insertions(+), 1 deletion(-)
+
+diff --git a/SubtitleRenderer.cpp b/SubtitleRenderer.cpp
+index 540162f..fcfc708 100644
+--- a/SubtitleRenderer.cpp
++++ b/SubtitleRenderer.cpp
+@@ -36,6 +36,11 @@
+ #include <algorithm>
+ 
+ #include "bcm_host.h"
++typedef struct {
++  DISPMANX_ELEMENT_HANDLE_T element;
++  int width;
++  int height;
++} EGL_DISPMANX_WINDOW_T;
+ 
+ class BoxRenderer {
+   VGPath path_;
+@@ -618,4 +623,4 @@ void SubtitleRenderer::set_rect(int x1, int y1, int x2, int y2) BOOST_NOEXCEPT
+     float font_size = height*font_size_;
+     ENFORCE(!FT_Set_Pixel_Sizes(ft_face_, 0, font_size));
+     ENFORCE(!FT_Set_Pixel_Sizes(ft_face_italic_, 0, font_size));
+-}
+\ No newline at end of file
++}
+diff --git a/SubtitleRenderer.h b/SubtitleRenderer.h
+index 3f60798..ebac9a1 100644
+--- a/SubtitleRenderer.h
++++ b/SubtitleRenderer.h
+@@ -26,6 +26,7 @@
+ // ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+ // DEALINGS IN THE SOFTWARE.
+ 
++#include <interface/vmcs_host/vc_dispmanx.h>
+ #include <EGL/egl.h>
+ #include <VG/openvg.h>
+ #include <ft2build.h>
+-- 
+2.19.1
+
diff --git a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0001-Remove-Makefile.include-which-includes-hardcoded.patch b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0001-Remove-Makefile.include-which-includes-hardcoded.patch
index 151c33c..0c8843e 100644
--- a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0001-Remove-Makefile.include-which-includes-hardcoded.patch
+++ b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0001-Remove-Makefile.include-which-includes-hardcoded.patch
@@ -1,4 +1,4 @@
-From a2a28fb7c4e8354cc0f90454e9bd151c16a6bf8b Mon Sep 17 00:00:00 2001
+From 19c9bc5fd8f43d3e9117906c3c48a3891357f8bc Mon Sep 17 00:00:00 2001
 From: Andrei Gherzan <andrei@gherzan.ro>
 Date: Tue, 20 Aug 2013 16:10:51 +0300
 Subject: [PATCH] Remove Makefile.include which includes hardcoded
@@ -11,8 +11,15 @@
 
 Updated patch to apply to c0dd9502ed2c43c487674939195c69680f3d98b0 revision
 
+---
+ Makefile         |  1 -
+ Makefile.ffmpeg  |  1 -
+ Makefile.include | 40 ----------------------------------------
+ 3 files changed, 42 deletions(-)
+ delete mode 100644 Makefile.include
+
 diff --git a/Makefile b/Makefile
-index f348465..65f7637 100644
+index 2857e94..76ee9bf 100644
 --- a/Makefile
 +++ b/Makefile
 @@ -1,4 +1,3 @@
@@ -21,7 +28,7 @@
  CFLAGS+=-std=c++0x -D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS -DTARGET_POSIX -DTARGET_LINUX -fPIC -DPIC -D_REENTRANT -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -DHAVE_CMAKE_CONFIG -D__VIDEOCORE4__ -U_FORTIFY_SOURCE -Wall -DHAVE_OMXLIB -DUSE_EXTERNAL_FFMPEG  -DHAVE_LIBAVCODEC_AVCODEC_H -DHAVE_LIBAVUTIL_OPT_H -DHAVE_LIBAVUTIL_MEM_H -DHAVE_LIBAVUTIL_AVUTIL_H -DHAVE_LIBAVFORMAT_AVFORMAT_H -DHAVE_LIBAVFILTER_AVFILTER_H -DHAVE_LIBSWRESAMPLE_SWRESAMPLE_H -DOMX -DOMX_SKIP64BIT -ftree-vectorize -DUSE_EXTERNAL_OMX -DTARGET_RASPBERRY_PI -DUSE_EXTERNAL_LIBBCM_HOST
  
 diff --git a/Makefile.ffmpeg b/Makefile.ffmpeg
-index 083e214..3b31a82 100644
+index ea12aad..749f47f 100644
 --- a/Makefile.ffmpeg
 +++ b/Makefile.ffmpeg
 @@ -1,4 +1,3 @@
diff --git a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0001-Specify-cc-cxx-and-ld-variables-from-environment.patch b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0001-Specify-cc-cxx-and-ld-variables-from-environment.patch
new file mode 100644
index 0000000..82dfd3e
--- /dev/null
+++ b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0001-Specify-cc-cxx-and-ld-variables-from-environment.patch
@@ -0,0 +1,42 @@
+From 9b4b7f8726171e97f12c587d50e54bab0dc42da5 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 12 Sep 2018 22:18:07 -0700
+Subject: [PATCH] Specify --cc, --cxx and --ld variables from environment
+
+This helps in compiling with non-gcc compilers
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ Makefile.ffmpeg | 22 ++++++++++++++--------
+ 1 file changed, 14 insertions(+), 8 deletions(-)
+
+Index: git/Makefile.ffmpeg
+===================================================================
+--- git.orig/Makefile.ffmpeg
++++ git/Makefile.ffmpeg
+@@ -22,12 +22,15 @@ configure:
+ 	CFLAGS="$(CFLAGS) ${INCLUDES}" \
+ 	LDFLAGS="" \
+   ./configure \
++			--ld="${CCLD}" \
++			--cc="${CC}" \
++			--cxx="${CXX}" \
+ 			--extra-cflags="$(FFMPEG_EXTRA_CFLAGS)" \
+ 			--extra-ldflags="$(FFMPEG_EXTRA_LDFLAGS)" \
+ 			--enable-shared \
+ 			--disable-static \
+ 			--arch=arm \
+-			--cpu=arm1176jzf-s \
++			--cpu=$(CPU) \
+ 			--target-os=linux \
+ 			--disable-hwaccels \
+ 			--enable-parsers \
+@@ -42,7 +45,7 @@ configure:
+ 			--enable-gpl \
+ 			--enable-version3 \
+ 			--enable-protocols \
+-			--enable-libsmbclient \
++			--disable-libsmbclient \
+ 			--enable-libssh \
+ 			--enable-nonfree \
+ 			--enable-openssl \
diff --git a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0002-Libraries-and-headers-from-ffmpeg-are-installed-in-u.patch b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0002-Libraries-and-headers-from-ffmpeg-are-installed-in-u.patch
index 203f34b..dd1d4f3 100644
--- a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0002-Libraries-and-headers-from-ffmpeg-are-installed-in-u.patch
+++ b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0002-Libraries-and-headers-from-ffmpeg-are-installed-in-u.patch
@@ -1,4 +1,4 @@
-From 1e92da659375eae1622984d4cc0ffd2a7b082fcf Mon Sep 17 00:00:00 2001
+From e46208c4a3e35da461e0e8f662970339eae47fca Mon Sep 17 00:00:00 2001
 From: Andrei Gherzan <andrei@gherzan.ro>
 Date: Sun, 24 Aug 2014 00:13:13 +0200
 Subject: [PATCH] Libraries and headers from ffmpeg are installed in /usr.
@@ -9,6 +9,7 @@
 
 Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
 Signed-off-by: Jonathan Liu <net147@gmail.com>
+
 ---
  Makefile        | 6 +++---
  Makefile.ffmpeg | 2 +-
@@ -18,30 +19,42 @@
 ===================================================================
 --- git.orig/Makefile
 +++ git/Makefile
-@@ -1,9 +1,9 @@
- 
+@@ -2,9 +2,9 @@ CFLAGS=-pipe -mfloat-abi=hard -mcpu=arm1
  CFLAGS+=-std=c++0x -D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS -DTARGET_POSIX -DTARGET_LINUX -fPIC -DPIC -D_REENTRANT -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -DHAVE_CMAKE_CONFIG -D__VIDEOCORE4__ -U_FORTIFY_SOURCE -Wall -DHAVE_OMXLIB -DUSE_EXTERNAL_FFMPEG  -DHAVE_LIBAVCODEC_AVCODEC_H -DHAVE_LIBAVUTIL_OPT_H -DHAVE_LIBAVUTIL_MEM_H -DHAVE_LIBAVUTIL_AVUTIL_H -DHAVE_LIBAVFORMAT_AVFORMAT_H -DHAVE_LIBAVFILTER_AVFILTER_H -DHAVE_LIBSWRESAMPLE_SWRESAMPLE_H -DOMX -DOMX_SKIP64BIT -ftree-vectorize -DUSE_EXTERNAL_OMX -DTARGET_RASPBERRY_PI -DUSE_EXTERNAL_LIBBCM_HOST
  
--LDFLAGS+=-L./ -Lffmpeg_compiled/usr/local/lib/ -lc -lWFC -lGLESv2 -lEGL -lbcm_host -lopenmaxil -lfreetype -lz -lasound
-+LDFLAGS+=-L./ -Lffmpeg_compiled/usr/lib/ -lc -lWFC -lGLESv2 -lEGL -lbcm_host -lopenmaxil -lfreetype -lz -lasound
+ LDFLAGS=-L$(SDKSTAGE)/opt/vc/lib/
+-LDFLAGS+=-L./ -Lffmpeg_compiled/usr/local/lib/ -lc -lbrcmGLESv2 -lbrcmEGL -lbcm_host -lopenmaxil -lfreetype -lz -lasound
++LDFLAGS+=-L./ -Lffmpeg_compiled/usr/lib/ -lc -lbrcmGLESv2 -lbrcmEGL -lbcm_host -lopenmaxil -lfreetype -lz -lasound
  
--INCLUDES+=-I./ -Ilinux -Iffmpeg_compiled/usr/local/include/ -I /usr/include/dbus-1.0 -I /usr/lib/arm-linux-gnueabihf/dbus-1.0/include
-+INCLUDES+=-I./ -Ilinux -Iffmpeg_compiled/usr/include/ -I=/usr/include/dbus-1.0
+-INCLUDES+=-I./ -Ilinux -Iffmpeg_compiled/usr/local/include/ -I /usr/include/dbus-1.0 -I /usr/lib/arm-linux-gnueabihf/dbus-1.0/include -I/usr/include/freetype2 -isystem$(SDKSTAGE)/opt/vc/include -isystem$(SDKSTAGE)/opt/vc/include/interface/vcos/pthreads
++INCLUDES+=-I./ -Ilinux
  
  DIST ?= omxplayer-dist
- 
-@@ -88,5 +88,5 @@ dist: omxplayer.bin omxplayer.1
+ STRIP ?= strip
+@@ -90,7 +90,7 @@ dist: omxplayer.bin omxplayer.1
  	cp COPYING $(DIST)/usr/share/doc/omxplayer
  	cp README.md $(DIST)/usr/share/doc/omxplayer/README
  	cp omxplayer.1 $(DIST)/usr/share/man/man1
 -	cp -P ffmpeg_compiled/usr/local/lib/*.so* $(DIST)/usr/lib/omxplayer/
 +	cp -P ffmpeg_compiled/usr/lib/*.so* $(DIST)/usr/lib/omxplayer/
  	cd $(DIST); tar -czf ../$(DIST).tgz *
+ 
+ install:
 Index: git/Makefile.ffmpeg
 ===================================================================
 --- git.orig/Makefile.ffmpeg
 +++ git/Makefile.ffmpeg
-@@ -254,5 +254,5 @@ checkout:
+@@ -238,7 +238,8 @@ configure:
+ 			--disable-decoder=xbin \
+ 			--disable-decoder=idf \
+ 			--disable-decoder=hevc \
+-			--enable-decoder=opus
++			--enable-decoder=opus \
++			--disable-stripping
+ 
+ .PHONY : clean
+ clean:
+@@ -251,5 +252,5 @@ checkout:
  .PHONY : install
  install:
  	cd ffmpeg; make -j9 DESTDIR="$(WORK)/ffmpeg_compiled" install
diff --git a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0003-Remove-strip-step-in-Makefile.patch b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0003-Remove-strip-step-in-Makefile.patch
index 7f31330..0b6aafd 100644
--- a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0003-Remove-strip-step-in-Makefile.patch
+++ b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0003-Remove-strip-step-in-Makefile.patch
@@ -1,4 +1,4 @@
-From b738724c6ca45ee5fecebed01c7ac91c92446123 Mon Sep 17 00:00:00 2001
+From 6975d8a902837dd6c604f7fdd2a2f977285855ed Mon Sep 17 00:00:00 2001
 From: Andrei Gherzan <andrei@gherzan.ro>
 Date: Sun, 24 Aug 2014 00:18:05 +0200
 Subject: [PATCH] Remove strip step in Makefile
@@ -10,30 +10,18 @@
 
 Upstream-Status: Inappropriate [embedded specific]
 Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
+
 ---
  Makefile.ffmpeg | 5 ++---
- 1 file changed, 2 insertions(+), 3 deletions(-)
+ 1 files changed, 2 insertions(+), 3 deletions(-)
 
-diff --git a/Makefile.ffmpeg b/Makefile.ffmpeg
-index 9d66a85..00df197 100644
---- a/Makefile.ffmpeg
-+++ b/Makefile.ffmpeg
-@@ -243,7 +243,8 @@ configure:
- 			--disable-decoder=xbin \
- 			--disable-decoder=idf \
- 			--enable-decoder=opus \
--			--cross-prefix=$(HOST)-
-+			--cross-prefix=$(HOST)- \
-+			--disable-stripping
- 
- .PHONY : clean
- clean:
-@@ -256,5 +257,3 @@ checkout:
+Index: git/Makefile.ffmpeg
+===================================================================
+--- git.orig/Makefile.ffmpeg
++++ git/Makefile.ffmpeg
+@@ -252,5 +252,3 @@ checkout:
  .PHONY : install
  install:
  	cd ffmpeg; make -j9 DESTDIR="$(WORK)/ffmpeg_compiled" install
 -	$(HOST)-strip ffmpeg_compiled/usr/lib/*.so
 -
--- 
-1.9.3
-
diff --git a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0004-Add-FFMPEG_EXTRA_CFLAGS-and-FFMPEG_EXTRA_LDFLAGS.patch b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0004-Add-FFMPEG_EXTRA_CFLAGS-and-FFMPEG_EXTRA_LDFLAGS.patch
index ea8530d..383cdf7 100644
--- a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0004-Add-FFMPEG_EXTRA_CFLAGS-and-FFMPEG_EXTRA_LDFLAGS.patch
+++ b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0004-Add-FFMPEG_EXTRA_CFLAGS-and-FFMPEG_EXTRA_LDFLAGS.patch
@@ -1,4 +1,4 @@
-From 100982ee1fc1cb571c7453d14f9acd60e67d4765 Mon Sep 17 00:00:00 2001
+From be007b01e7d91f5f83518c0388c16db8dab31d2e Mon Sep 17 00:00:00 2001
 From: Andrei Gherzan <andrei.gherzan@windriver.com>
 Date: Sun, 25 Jan 2015 11:13:51 +0200
 Subject: [PATCH] Add FFMPEG_EXTRA_CFLAGS and FFMPEG_EXTRA_LDFLAGS
@@ -8,16 +8,16 @@
 
 Upstream-Status: Inappropriate [embedded specific]
 Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
+
 ---
- Makefile.ffmpeg | 3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
+ Makefile.ffmpeg | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
 
 Index: git/Makefile.ffmpeg
 ===================================================================
 --- git.orig/Makefile.ffmpeg
 +++ git/Makefile.ffmpeg
-@@ -1,6 +1,8 @@
- 
+@@ -1,5 +1,7 @@
  CFLAGS=-D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS -DTARGET_POSIX -DTARGET_LINUX -fPIC -DPIC -D_REENTRANT -D_HAVE_SBRK -D_LARGEFILE64_SOURCE -DHAVE_CMAKE_CONFIG -DHAVE_VMCS_CONFIG -D_REENTRANT -DUSE_VCHIQ_ARM -DVCHI_BULK_ALIGN=1 -DVCHI_BULK_GRANULARITY=1 -DEGL_SERVER_DISPMANX -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D__VIDEOCORE4__ -DGRAPHICS_X_VG=1 -U_FORTIFY_SOURCE -Wall -DHAVE_OMXLIB -DUSE_EXTERNAL_FFMPEG  -DHAVE_LIBAVCODEC_AVCODEC_H -DHAVE_LIBAVUTIL_MEM_H -DHAVE_LIBAVUTIL_AVUTIL_H -DHAVE_LIBAVFORMAT_AVFORMAT_H -DHAVE_LIBAVFILTER_AVFILTER_H -DOMX -DOMX_SKIP64BIT
  
 +FFMPEG_EXTRA_CFLAGS?=-mfpu=vfp -mfloat-abi=$(FLOAT) -mno-apcs-stack-check -mstructure-size-boundary=32 -mno-sched-prolog
@@ -25,13 +25,13 @@
  WORK=$(PWD)
  
  .PHONY : all
-@@ -21,7 +23,8 @@ configure:
+@@ -20,7 +22,8 @@ configure:
  	CFLAGS="$(CFLAGS) ${INCLUDES}" \
  	LDFLAGS="" \
    ./configure \
--			--extra-cflags="-mfpu=vfp -mfloat-abi=$(FLOAT) -mno-apcs-stack-check -mstructure-size-boundary=32 -mno-sched-prolog" \
+-			--extra-cflags="-mfpu=vfp -mfloat-abi=hard -mno-apcs-stack-check -mstructure-size-boundary=32 -mno-sched-prolog" \
 +			--extra-cflags="$(FFMPEG_EXTRA_CFLAGS)" \
 +			--extra-ldflags="$(FFMPEG_EXTRA_LDFLAGS)" \
- 			--enable-cross-compile \
  			--enable-shared \
  			--disable-static \
+ 			--arch=arm \
diff --git a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0005-Don-t-require-internet-connection-during-build.patch b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0005-Don-t-require-internet-connection-during-build.patch
index 4f56ad2..f6abd7b 100644
--- a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0005-Don-t-require-internet-connection-during-build.patch
+++ b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0005-Don-t-require-internet-connection-during-build.patch
@@ -1,4 +1,4 @@
-From 97cb9405f281f54d4083f3126d441c8b44eafb89 Mon Sep 17 00:00:00 2001
+From 81d1f8bc102b23bdfa63a01f252f3e4c74ae7da9 Mon Sep 17 00:00:00 2001
 From: Paul Barker <pbarker@toganlabs.com>
 Date: Thu, 7 Sep 2017 19:14:20 +0000
 Subject: [PATCH] Don't require internet connection during build
@@ -11,16 +11,17 @@
 
 Signed-off-by: Paul Barker <pbarker@toganlabs.com>
 Upstream-status: Inappropriate
+
 ---
  Makefile        | 6 ++----
  Makefile.ffmpeg | 2 +-
  2 files changed, 3 insertions(+), 5 deletions(-)
 
-diff --git a/Makefile b/Makefile
-index 60501b1..6471f0f 100644
---- a/Makefile
-+++ b/Makefile
-@@ -79,14 +79,12 @@ ffmpeg:
+Index: git/Makefile
+===================================================================
+--- git.orig/Makefile
++++ git/Makefile
+@@ -81,17 +81,14 @@ ffmpeg:
  	make -f Makefile.ffmpeg
  	make -f Makefile.ffmpeg install
  
@@ -36,13 +37,14 @@
 -	cp omxplayer.1 $(DIST)/usr/share/man/man1
  	cp -P ffmpeg_compiled/usr/lib/*.so* $(DIST)/usr/lib/omxplayer/
 -	tar -czf omxplayer-dist.tar.gz $(DIST)
-\ No newline at end of file
-+	tar -czf omxplayer-dist.tar.gz $(DIST)
-diff --git a/Makefile.ffmpeg b/Makefile.ffmpeg
-index 22d495c..8651724 100644
---- a/Makefile.ffmpeg
-+++ b/Makefile.ffmpeg
-@@ -6,7 +6,7 @@ FFMPEG_EXTRA_CFLAGS?=-mfpu=vfp -mfloat-abi=$(FLOAT) -mno-apcs-stack-check -mstru
+ 
+ install:
+ 	cp -r $(DIST)/* /
+Index: git/Makefile.ffmpeg
+===================================================================
+--- git.orig/Makefile.ffmpeg
++++ git/Makefile.ffmpeg
+@@ -5,7 +5,7 @@ FFMPEG_EXTRA_CFLAGS?=-mfpu=vfp -mfloat-a
  WORK=$(PWD)
  
  .PHONY : all
@@ -51,6 +53,3 @@
  
  .PHONY : copy
  copy:
--- 
-2.7.4
-
diff --git a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0006-Prevent-ffmpeg-configure-compile-race-condition.patch b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0006-Prevent-ffmpeg-configure-compile-race-condition.patch
index 3fac2d1..890adde 100644
--- a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0006-Prevent-ffmpeg-configure-compile-race-condition.patch
+++ b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/0006-Prevent-ffmpeg-configure-compile-race-condition.patch
@@ -1,4 +1,4 @@
-From 4a13419e3805b541fc58e57f1f27c4a388609ef5 Mon Sep 17 00:00:00 2001
+From f570b9985ff2d57d21c1e64ed08c43b6d89fd0b1 Mon Sep 17 00:00:00 2001
 From: Paul Barker <pbarker@toganlabs.com>
 Date: Thu, 7 Sep 2017 20:02:15 +0000
 Subject: [PATCH] Prevent ffmpeg configure/compile race condition
@@ -8,15 +8,16 @@
 
 Signed-off-by: Paul Barker <pbarker@toganlabs.com>
 Upstream-status: Pending
+
 ---
  Makefile.ffmpeg | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
 
-diff --git a/Makefile.ffmpeg b/Makefile.ffmpeg
-index 8651724..619c49a 100644
---- a/Makefile.ffmpeg
-+++ b/Makefile.ffmpeg
-@@ -6,7 +6,7 @@ FFMPEG_EXTRA_CFLAGS?=-mfpu=vfp -mfloat-abi=$(FLOAT) -mno-apcs-stack-check -mstru
+Index: git/Makefile.ffmpeg
+===================================================================
+--- git.orig/Makefile.ffmpeg
++++ git/Makefile.ffmpeg
+@@ -5,7 +5,7 @@ FFMPEG_EXTRA_CFLAGS?=-mfpu=vfp -mfloat-a
  WORK=$(PWD)
  
  .PHONY : all
@@ -25,15 +26,12 @@
  
  .PHONY : copy
  copy:
-@@ -14,7 +14,7 @@ copy:
+@@ -13,7 +13,7 @@ copy:
  	$(HOST)-strip *.so*
  
  .PHONY : compile
 -compile: 
 +compile: configure
- 	+$(MAKE) -C ffmpeg
+ 	+$(MAKE) -j$(shell nproc) -C ffmpeg
  
  .PHONY : configure
--- 
-2.7.4
-
diff --git a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/cross-crompile-ffmpeg.patch b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/cross-crompile-ffmpeg.patch
new file mode 100644
index 0000000..20ed7c7
--- /dev/null
+++ b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/cross-crompile-ffmpeg.patch
@@ -0,0 +1,12 @@
+Index: git/Makefile.ffmpeg
+===================================================================
+--- git.orig/Makefile.ffmpeg
++++ git/Makefile.ffmpeg
+@@ -22,6 +22,7 @@ configure:
+ 	CFLAGS="$(CFLAGS) ${INCLUDES}" \
+ 	LDFLAGS="" \
+   ./configure \
++			--enable-cross-compile \
+ 			--ld="${CCLD}" \
+ 			--cc="${CC}" \
+ 			--cxx="${CXX}" \
diff --git a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/fix-tar-command-with-DIST.patch b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/fix-tar-command-with-DIST.patch
index ab40e40..70859aa 100644
--- a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/fix-tar-command-with-DIST.patch
+++ b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/fix-tar-command-with-DIST.patch
@@ -1,3 +1,8 @@
+From 23a97efde2aef171312000f7859ef4c573ce2ada Mon Sep 17 00:00:00 2001
+From: Andrei Gherzan <andrei@gherzan.ro>
+Date: Sun, 19 Jan 2014 20:35:29 +0200
+Subject: [PATCH] omxplayer: Update to remote HEAD
+
 Revert the tar command change introduced in:
 https://github.com/popcornmix/omxplayer/commit/201c77973155861e60492e45d35467b19b69c1c4
 
@@ -8,14 +13,20 @@
 Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
 Signed-off-by: Jonathan Liu <net147@gmail.com>
 
+---
+ Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
 Index: git/Makefile
 ===================================================================
 --- git.orig/Makefile
 +++ git/Makefile
-@@ -71,4 +71,4 @@ dist: omxplayer.bin
- 	cp COPYING $(DIST)/usr/share/doc/
- 	cp README.md $(DIST)/usr/share/doc/README
+@@ -91,7 +91,7 @@ dist: omxplayer.bin omxplayer.1
+ 	cp README.md $(DIST)/usr/share/doc/omxplayer/README
+ 	cp omxplayer.1 $(DIST)/usr/share/man/man1
  	cp -P ffmpeg_compiled/usr/lib/*.so* $(DIST)/usr/lib/omxplayer/
 -	cd $(DIST); tar -czf ../$(DIST).tgz *
 +	tar -czf omxplayer-dist.tar.gz $(DIST)
-\ No newline at end of file
+ 
+ install:
+ 	cp -r $(DIST)/* /
diff --git a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/use-native-pkg-config.patch b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/use-native-pkg-config.patch
index ed81999..e580470 100644
--- a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/use-native-pkg-config.patch
+++ b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer/use-native-pkg-config.patch
@@ -1,16 +1,25 @@
+From da6c24a2a87b8cf9692017e32be25d30c0cc7ef4 Mon Sep 17 00:00:00 2001
+From: Andrei Gherzan <andrei@gherzan.ro>
+Date: Tue, 10 Feb 2015 00:52:18 +0100
+Subject: [PATCH] omxplayer: Bump SRCREV
+
 Force the pkg-config native tool. Strangely ffmpeg prepends cross_prefix
 to the default value which obviously is wrong.
 
 Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
 
+---
+ Makefile.ffmpeg | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
 Index: git/Makefile.ffmpeg
 ===================================================================
 --- git.orig/Makefile.ffmpeg
 +++ git/Makefile.ffmpeg
-@@ -245,7 +245,8 @@ configure:
+@@ -242,7 +242,8 @@ configure:
  			--disable-decoder=idf \
+ 			--disable-decoder=hevc \
  			--enable-decoder=opus \
- 			--cross-prefix=$(HOST)- \
 -			--disable-stripping
 +			--disable-stripping \
 +			--pkg-config=pkg-config
diff --git a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer_git.bb b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer_git.bb
index 1df41a5..aad2fed 100644
--- a/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer_git.bb
+++ b/meta-raspberrypi/recipes-multimedia/omxplayer/omxplayer_git.bb
@@ -7,10 +7,11 @@
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
 
-DEPENDS = "libpcre libav virtual/egl boost freetype dbus openssl libssh libomxil coreutils-native curl-native"
+DEPENDS = "libpcre libav virtual/egl boost freetype dbus openssl libssh libomxil coreutils-native curl-native userland"
+
 PR = "r4"
 
-SRCREV_default = "b8ff59dccd9307f10dad71bec2525a95bd6c603b"
+SRCREV_default = "b4bbef8fac5e8c2ddafa895f98456ba715b39c6b"
 
 # omxplayer builds its own copy of ffmpeg from source instead of using the
 # system's ffmpeg library. This isn't ideal but it's ok for now. We do however
@@ -18,12 +19,11 @@
 # fetching the latest commit on a release branch (which is what the checkout job
 # in Makefile.ffmpeg in the omxplayer source tree does).
 #
-# This SRCREV corresponds to the v3.1.10 release of ffmpeg.
-SRCREV_ffmpeg = "afa34cb36edca0ff809b7e58474bbce12271ecba"
+# This SRCREV corresponds to the v4.0.3 release of ffmpeg.
+SRCREV_ffmpeg = "fcbd117df3077bad495e99e20f01cf93737bce76"
 
 SRC_URI = "git://github.com/popcornmix/omxplayer.git;protocol=git;branch=master \
-           git://source.ffmpeg.org/ffmpeg;branch=release/3.1;protocol=git;depth=1;name=ffmpeg;destsuffix=git/ffmpeg \
-           file://0001-Remove-Makefile.include-which-includes-hardcoded.patch \
+           git://github.com/FFmpeg/FFmpeg;branch=release/4.0;protocol=git;depth=1;name=ffmpeg;destsuffix=git/ffmpeg \
            file://0002-Libraries-and-headers-from-ffmpeg-are-installed-in-u.patch \
            file://0003-Remove-strip-step-in-Makefile.patch \
            file://0004-Add-FFMPEG_EXTRA_CFLAGS-and-FFMPEG_EXTRA_LDFLAGS.patch \
@@ -31,12 +31,23 @@
            file://use-native-pkg-config.patch \
            file://0005-Don-t-require-internet-connection-during-build.patch \
            file://0006-Prevent-ffmpeg-configure-compile-race-condition.patch \
+           file://0001-Specify-cc-cxx-and-ld-variables-from-environment.patch \
+           file://cross-crompile-ffmpeg.patch \
            "
+
+SRC_URI_append = "${@bb.utils.contains("MACHINE_FEATURES", "vc4graphics", " file://0001-Fix-build-with-vc4-driver.patch ", "", d)}"
+
 S = "${WORKDIR}/git"
 
-COMPATIBLE_MACHINE ?= "null"
-COMPATIBLE_MACHINE_rpi_aarch64 = "null"
-COMPATIBLE_MACHINE_rpi = "(.*)"
+COMPATIBLE_MACHINE = "^rpi$"
+
+def cpu(d):
+    for arg in (d.getVar('TUNE_CCARGS') or '').split():
+        if arg.startswith('-mcpu='):
+            return arg[6:]
+    return 'generic'
+
+export CPU = "${@cpu(d)}"
 
 inherit autotools-brokensep pkgconfig
 
@@ -55,11 +66,13 @@
 export FFMPEG_EXTRA_LDFLAGS  = "${TUNE_CCARGS} ${TOOLCHAIN_OPTIONS}"
 
 # Needed in top Makefile
+
 export LDFLAGS = "-L${S}/ffmpeg_compiled/usr/lib \
                   -L${STAGING_DIR_HOST}/lib \
                   -L${STAGING_DIR_HOST}/usr/lib \
                  "
-export INCLUDES = "-isystem${STAGING_DIR_HOST}/usr/include/interface/vcos/pthreads \
+export INCLUDES = "${@bb.utils.contains("MACHINE_FEATURES", "vc4graphics", " -D__GBM__", "", d)} \
+                   -isystem${STAGING_DIR_HOST}/usr/include/interface/vcos/pthreads \
                    -isystem${STAGING_DIR_HOST}/usr/include/freetype2 \
                    -isystem${STAGING_DIR_HOST}/usr/include/interface/vmcs_host/linux \
                    -isystem${STAGING_DIR_HOST}/usr/include/dbus-1.0 \
@@ -90,4 +103,4 @@
 
 FILES_${PN}-dev += "${libdir}/omxplayer/*.so"
 
-RDEPENDS_${PN} += "bash procps"
+RDEPENDS_${PN} += "bash procps userland"
diff --git a/meta-security/README b/meta-security/README
index ef80f2b..e238271 100644
--- a/meta-security/README
+++ b/meta-security/README
@@ -48,209 +48,6 @@
     /path/to/meta-openembedded/meta-networking \
     /path/to/layer/meta-security \
 
-Contents and Help
-=================
-
-In this section the contents of the layer is listed, along with a short
-help for each package.
-
-         == bastille ==
-
-        Bastille  is  a  system hardening / lockdown program which enhances the
-        security of a Unix host.  It configures daemons, system settings and
-        firewalls to be more secure.  It can shut off unneeded services
-        like rcp and rlogin, and helps create "chroot jails" that help limit the
-        vulnerability of common Internet services like Web services and DNS.
-
-        usage : The functionality of Bastille which is available is
-                restricted to a purely informational one. The command:
-                bastille -c --os Yocto
-                will cause a series of menus containing security questions
-                about the system to be displayed to the user. For each
-                question, a default response, specified in the configuration
-                file which is installed with Bastille, will be selected.
-                The user may select an alternate response. When the user
-                has completed the sequence of menus Bastille saves the
-                responses to the configuration file.
-
-                The command:
-                bastille -l lists the configuration files that Bastille
-                is able to locate.
-
-                The other functionality which Bastille is intended to provide
-                is actually unavailable. This is not due to errors in poky
-                installation or configuration of the application. The Bastille
-                distribution is no longer supported. Significant modifications
-                would be required to make it possible to make use of the
-                functionality which is currently unavailable.
-
-
-        Additional information about Bastille can be found in the package
-        README file and other documentation.
-
-        Alternatives to Bastille include buck-security and checksecurity,
-        described elsewhere in this file.
-
-
-        == redhat-security ==
-
-        Sometimes you want to check different aspects of a distribution for security problems.
-        This can be anything from file permissions to correctness of code. This is a collection of those tools.
-        Depending on what information the tool has to access, it may need to be run as root.
-
-        - rpm-chksec.sh : This will take an rpm name as input and verify each ELF file to see if its compiled with the intended flags
-                          to most effectively use PIE and RELRO. Green is good, Orange could use work but is acceptable, and Red needs fixing.
-                          It has a mode --all that is the equivalent of using rpm -qa and feeding the packages to it.
-                          In this mode it will only give a summary result for the package. To find which files don't comply,
-                          re-run using just the package name.
-
-		!!! WARNING !!! - in order to use this script you need to add to your conf/local.conf file the following lines:
-						IMAGE_ROOTFS_EXTRA_SPACE = ""  - specifying the extra space of the image
-						IMAGE_FEATURES += "package management" - for the correct output of rpm -qa
-
-        - find-nodrop-groups.sh : This will scan a whole file system to see if a program makes calls to change UID
-                                  and GID without also calling setgroups or initgroups.
-
-        - rpm-drop-groups.sh : Same as above, but takes an rpm name instead.
-
-        - find-chroot.sh : This script scans the whole file system looking for ELF files that calls chroot(2) that also do not include a call to chdir.
-                           Programs that fail to do this do not have the cwd inside the chroot. This means the app can escape the protection that was intended.
-
-        - find-chroot-py.sh : This test is like the one above except it examines python scripts for the same problem.
-
-        - find-execstack.sh : This program scans the whole file system for ELF programs that have marked the stack as being executable.
-                              This means that if the program has another vulnerablity such as stack buffer overflow,
-                              any code the attacker places there is executable. Any program found must be fixed.
-
-        - find-hidden-exec.sh : This program scans the whole file system looking for excutables that are hidden.
-                                Anything found must be investigated since its highly unusual for executables to be hidden.
-
-        - find-sh4errors.sh : This program scans the whole file system looking for shell scripts.
-                              It then does a sh -n on the script which causes bash to parse the file to see if there are any mistakes.
-
-        - selinux-check-devices.sh : This script checks the /dev directory to see if there are any devices that are not correctly labeled.
-                                     Anything found by this test should be reported so that selinux policy can be fixed.
-                                     This test is very hardware specific, so to be effective a lot of people with different hardware
-                                     should run this test each upstream kernel version release.
-
-        - selinux-ls-unconfined.sh :  This script scans the running processes and looks for anything labeled with initrc_t or inetd.
-                                      These both mean that there are daemons that do not have policy and are therefore running unconfined.
-                                      These should be reported as SE Linux policy problems. Because it checks currently running daemons,
-                                      the more you have running, the better the test is.
-
-        - find-sh4tmp.sh : This script scans the whole filesystem to check if shell scripts are using well known tmp file names
-                           instead of obscure ones created by something like mktemp.
-
-        - find-elf4tmp.sh : This script scans the whole file system for ELF files using /tmp. When it finds this,
-                            it also looks to see if any of the known good random name generator functions is called by looking
-                            at the symbol table. If not, it will output the string.
-
-        - lib-bin-check.sh : This will check all installed library packages to see if an application is also part of the package.
-                             The relationship to security is that the SHA256 hash check will fail if a 32 bit version overwrites it.
-                             Also, the less binaries on a system, the more secure it is by virtue of removing the chance for an exploitable bug.
-
-
-                usage : simply invoke the script name in the terminal.
-
-
-        == pax-utils ==
-
-		( This package can be found in oe-core )
-
-        pax-utils is a small set of various PaX aware and related utilities for
-        ELF binaries.
-
-        - scanelf : With this application you can print out information specific to the ELF structure of a binary.
-                    For more help please consult the man pages or the readme file.
-
-        - pspax : is a user-space utility that scans the proc directory and list
-                  ELF types, as well as their respective PaX flags and filenames and
-                  attributes. Depending on build options, it may additionaly display the
-                  process running set of capabilities.
-
-        - scanmacho : is a user-space utility to quickly scan given
-                      Mach-Os, directories, or common system paths for different information. This
-                      may include Mach-O types, their install_names, etc.
-
-        - dumpelf : is a user-space utility to dump all of the internal
-                    ELF structures into the equivalent C structures for fun debugging and/or
-                    reference purposes.
-
-
-                usage : simply invoke the script name in the terminal.
-
-
-        == buck-security ==
-
-        Buck-Security is a security scanner for Debian and Ubuntu Linux. It runs a couple of important checks and helps you to harden your Linux
-        system. This enables you to quickly overview the security status of your Linux system.
-
-                usage :	!!! before starting to use this tool please run the following command: !!!
-
-						export GPG_TTY=`tty`
-
-						This command is needed for the usage of the comand --make-checksum, which creates
-						a checksum for the files in the system.
-
-						switch to directory /usr/local/buck-security.
-                        before running the script, you should check the activated checks in conf/buck-security.conf file.
-                        after altering the changes, save the file and simply run :
-
-                        ./buck-security
-
-                        you can choose between different outputs : 1, 2(default) or 3.
-
-                        More detailed usage can be found typing ./buck-security --help
-
-
-        == libseccomp ==
-
-        The libseccomp library provides and easy to use, platform independent, interface to the Linux Kernel's syscall filtering mechanism: seccomp.
-        The libseccomp API is designed to abstract away the underlying BPF based syscall filter language and present a more conventional
-        function-call based filtering interface that should be familiar to, and easily adopted by application developers.
-
-                usage : More detailed usage can be found in the man pages and README file of the package.
-
-
-
-        == checksecurity ==
-
-        checksecurity is a simple package which will scan your system for several simple security holes.
-        It uses a simple collection of plugins, all of which are shell scripts which are configured by environmental variables.
-
-
-                usage : To start checksecurity simply write in the terminal :
-
-                        checksecurity
-
-        More detailed usage can be found in the man pages and README file of the package.
-
-
-        == nikto ==
-
-        Nikto is an Open Source (GPL) web server scanner which performs comprehensive tests against web servers for multiple items,
-        including over 6500 potentially dangerous files/CGIs, checks for outdated versions of over 1250 servers, and version specific
-        problems on over 270 servers. It also checks for server configuration items such as the presence of multiple index files,
-        HTTP server options, and will attempt to identify installed web servers and software.
-
-                usage : To start nikto simply write in the terminal :
-
-                        nikto
-
-        More detailed usage can be found in the man pages and README file of the package.
-
-
-        == nmap ==
-
-        Nmap ("Network Mapper") is a free and open source (license) utility for network discovery and security auditing.
-        Many systems and network administrators also find it useful for tasks such as network inventory,
-        managing service upgrade schedules, and monitoring host or service uptime.
-
-                usage : To start nikto simply write in the terminal :
-
-                        nmap
-
-        More detailed usage can be found in the man pages and README file of the package.
 
 Maintenance
 -----------
@@ -260,8 +57,8 @@
 When sending single patches, please using something like:
 'git send-email -1 --to yocto@yoctoproject.org --subject-prefix=meta-security][PATCH'
 
-Maintainers:    Saul Wold <sgw@linux.intel.com>
-                Armin Kuster <akuster@mvista.com>
+Maintainers:    Armin Kuster <akuster808@gmail.com>
+                Saul Wold <sgw@linux.intel.com>
 
 
 License
diff --git a/meta-security/conf/layer.conf b/meta-security/conf/layer.conf
index efc426e..19e647e 100644
--- a/meta-security/conf/layer.conf
+++ b/meta-security/conf/layer.conf
@@ -7,8 +7,10 @@
 
 BBFILE_COLLECTIONS += "security"
 BBFILE_PATTERN_security = "^${LAYERDIR}/"
-BBFILE_PRIORITY_security = "6"
+BBFILE_PRIORITY_security = "8"
 
-LAYERSERIES_COMPAT_security = "sumo"
+LAYERSERIES_COMPAT_security = "thud"
 
 LAYERDEPENDS_security = "core openembedded-layer perl-layer networking-layer meta-python"
+
+DEFAULT_TEST_SUITES_pn-security-build-image = " ${PTESTTESTSUITE}"
diff --git a/meta-security/docs/overview.txt b/meta-security/docs/overview.txt
new file mode 100644
index 0000000..ed3135a
--- /dev/null
+++ b/meta-security/docs/overview.txt
@@ -0,0 +1,197 @@
+Meta-security Docs
+=============
+
+In this section the contents of the layer is listed, along with a short
+help for each package.
+
+         == bastille ==
+
+        Bastille  is  a  system hardening / lockdown program which enhances the
+        security of a Unix host.  It configures daemons, system settings and
+        firewalls to be more secure.  It can shut off unneeded services
+        like rcp and rlogin, and helps create "chroot jails" that help limit the
+        vulnerability of common Internet services like Web services and DNS.
+
+        usage : The functionality of Bastille which is available is
+                restricted to a purely informational one. The command:
+                bastille -c --os Yocto
+                will cause a series of menus containing security questions
+                about the system to be displayed to the user. For each
+                question, a default response, specified in the configuration
+                file which is installed with Bastille, will be selected.
+                The user may select an alternate response. When the user
+                has completed the sequence of menus Bastille saves the
+                responses to the configuration file.
+
+                The command:
+                bastille -l lists the configuration files that Bastille
+                is able to locate.
+
+                The other functionality which Bastille is intended to provide
+                is actually unavailable. This is not due to errors in poky
+                installation or configuration of the application. The Bastille
+                distribution is no longer supported. Significant modifications
+                would be required to make it possible to make use of the
+                functionality which is currently unavailable.
+
+
+        Additional information about Bastille can be found in the package
+        README file and other documentation.
+
+        Alternatives to Bastille include buck-security and checksecurity,
+        described elsewhere in this file.
+
+
+        == redhat-security ==
+
+        Sometimes you want to check different aspects of a distribution for security problems.
+        This can be anything from file permissions to correctness of code. This is a collection of those tools.
+        Depending on what information the tool has to access, it may need to be run as root.
+
+        - rpm-chksec.sh : This will take an rpm name as input and verify each ELF file to see if its compiled with the intended flags
+                          to most effectively use PIE and RELRO. Green is good, Orange could use work but is acceptable, and Red needs fixing.
+                          It has a mode --all that is the equivalent of using rpm -qa and feeding the packages to it.
+                          In this mode it will only give a summary result for the package. To find which files don't comply,
+                          re-run using just the package name.
+
+		!!! WARNING !!! - in order to use this script you need to add to your conf/local.conf file the following lines:
+						IMAGE_ROOTFS_EXTRA_SPACE = ""  - specifying the extra space of the image
+						IMAGE_FEATURES += "package management" - for the correct output of rpm -qa
+
+        - find-nodrop-groups.sh : This will scan a whole file system to see if a program makes calls to change UID
+                                  and GID without also calling setgroups or initgroups.
+
+        - rpm-drop-groups.sh : Same as above, but takes an rpm name instead.
+
+        - find-chroot.sh : This script scans the whole file system looking for ELF files that calls chroot(2) that also do not include a call to chdir.
+                           Programs that fail to do this do not have the cwd inside the chroot. This means the app can escape the protection that was intended.
+
+        - find-chroot-py.sh : This test is like the one above except it examines python scripts for the same problem.
+
+        - find-execstack.sh : This program scans the whole file system for ELF programs that have marked the stack as being executable.
+                              This means that if the program has another vulnerablity such as stack buffer overflow,
+                              any code the attacker places there is executable. Any program found must be fixed.
+
+        - find-hidden-exec.sh : This program scans the whole file system looking for excutables that are hidden.
+                                Anything found must be investigated since its highly unusual for executables to be hidden.
+
+        - find-sh4errors.sh : This program scans the whole file system looking for shell scripts.
+                              It then does a sh -n on the script which causes bash to parse the file to see if there are any mistakes.
+
+        - selinux-check-devices.sh : This script checks the /dev directory to see if there are any devices that are not correctly labeled.
+                                     Anything found by this test should be reported so that selinux policy can be fixed.
+                                     This test is very hardware specific, so to be effective a lot of people with different hardware
+                                     should run this test each upstream kernel version release.
+
+        - selinux-ls-unconfined.sh :  This script scans the running processes and looks for anything labeled with initrc_t or inetd.
+                                      These both mean that there are daemons that do not have policy and are therefore running unconfined.
+                                      These should be reported as SE Linux policy problems. Because it checks currently running daemons,
+                                      the more you have running, the better the test is.
+
+        - find-sh4tmp.sh : This script scans the whole filesystem to check if shell scripts are using well known tmp file names
+                           instead of obscure ones created by something like mktemp.
+
+        - find-elf4tmp.sh : This script scans the whole file system for ELF files using /tmp. When it finds this,
+                            it also looks to see if any of the known good random name generator functions is called by looking
+                            at the symbol table. If not, it will output the string.
+
+        - lib-bin-check.sh : This will check all installed library packages to see if an application is also part of the package.
+                             The relationship to security is that the SHA256 hash check will fail if a 32 bit version overwrites it.
+                             Also, the less binaries on a system, the more secure it is by virtue of removing the chance for an exploitable bug.
+
+
+                usage : simply invoke the script name in the terminal.
+
+
+        == pax-utils ==
+
+		( This package can be found in oe-core )
+
+        pax-utils is a small set of various PaX aware and related utilities for
+        ELF binaries.
+
+        - scanelf : With this application you can print out information specific to the ELF structure of a binary.
+                    For more help please consult the man pages or the readme file.
+
+        - pspax : is a user-space utility that scans the proc directory and list
+                  ELF types, as well as their respective PaX flags and filenames and
+                  attributes. Depending on build options, it may additionaly display the
+                  process running set of capabilities.
+
+        - scanmacho : is a user-space utility to quickly scan given
+                      Mach-Os, directories, or common system paths for different information. This
+                      may include Mach-O types, their install_names, etc.
+
+        - dumpelf : is a user-space utility to dump all of the internal
+                    ELF structures into the equivalent C structures for fun debugging and/or
+                    reference purposes.
+
+
+                usage : simply invoke the script name in the terminal.
+
+
+        == buck-security ==
+
+        Buck-Security is a security scanner for Debian and Ubuntu Linux. It runs a couple of important checks and helps you to harden your Linux
+        system. This enables you to quickly overview the security status of your Linux system.
+
+                usage :	!!! before starting to use this tool please run the following command: !!!
+
+						export GPG_TTY=`tty`
+
+						This command is needed for the usage of the comand --make-checksum, which creates
+						a checksum for the files in the system.
+
+						switch to directory /usr/local/buck-security.
+                        before running the script, you should check the activated checks in conf/buck-security.conf file.
+                        after altering the changes, save the file and simply run :
+
+                        ./buck-security
+
+                        you can choose between different outputs : 1, 2(default) or 3.
+
+                        More detailed usage can be found typing ./buck-security --help
+
+
+        == libseccomp ==
+
+        The libseccomp library provides and easy to use, platform independent, interface to the Linux Kernel's syscall filtering mechanism: seccomp.
+        The libseccomp API is designed to abstract away the underlying BPF based syscall filter language and present a more conventional
+        function-call based filtering interface that should be familiar to, and easily adopted by application developers.
+
+                usage : More detailed usage can be found in the man pages and README file of the package.
+
+
+
+        == checksecurity ==
+
+        checksecurity is a simple package which will scan your system for several simple security holes.
+        It uses a simple collection of plugins, all of which are shell scripts which are configured by environmental variables.
+
+
+                usage : To start checksecurity simply write in the terminal :
+
+                        checksecurity
+
+        More detailed usage can be found in the man pages and README file of the package.
+
+
+        == nikto ==
+
+        Nikto is an Open Source (GPL) web server scanner which performs comprehensive tests against web servers for multiple items,
+        including over 6500 potentially dangerous files/CGIs, checks for outdated versions of over 1250 servers, and version specific
+        problems on over 270 servers. It also checks for server configuration items such as the presence of multiple index files,
+        HTTP server options, and will attempt to identify installed web servers and software.
+
+                usage : To start nikto simply write in the terminal :
+
+                        nikto
+
+        More detailed usage can be found in the man pages and README file of the package.
+
+License
+=======
+
+All metadata is MIT licensed unless otherwise stated. Source code included
+in tree for individual recipes is under the LICENSE stated in each recipe
+(.bb file) unless otherwise stated.
diff --git a/meta-security/meta-security-compliance/conf/layer.conf b/meta-security/meta-security-compliance/conf/layer.conf
index 31716d6..fcc5cd6 100644
--- a/meta-security/meta-security-compliance/conf/layer.conf
+++ b/meta-security/meta-security-compliance/conf/layer.conf
@@ -6,9 +6,9 @@
 
 BBFILE_COLLECTIONS += "scanners-layer"
 BBFILE_PATTERN_scanners-layer = "^${LAYERDIR}/"
-BBFILE_PRIORITY_scanners-layer = "6"
+BBFILE_PRIORITY_scanners-layer = "10"
 
-LAYERSERIES_COMPAT_scanners-layer = "sumo"
+LAYERSERIES_COMPAT_scanners-layer = "thud"
 
 LAYERDEPENDS_scanners-layer = " \
     core \
diff --git a/meta-security/meta-security-compliance/recipes-auditors/lynis/lynis_2.5.1.bb b/meta-security/meta-security-compliance/recipes-auditors/lynis/lynis_2.5.1.bb
deleted file mode 100644
index 884999c..0000000
--- a/meta-security/meta-security-compliance/recipes-auditors/lynis/lynis_2.5.1.bb
+++ /dev/null
@@ -1,38 +0,0 @@
-# Copyright (C) 2017 Armin Kuster  <akuster808@gmail.com>
-# Released under the MIT license (see COPYING.MIT for the terms)
-
-SUMMARY = "Lynis is a free and open source security and auditing tool."
-HOMEDIR = "https://cisofy.com/"
-LICENSE = "GPL-3.0"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=3edd6782854304fd11da4975ab9799c1"
-
-SRCREV= "1be5154b35ce144db4f386856debe8a06b403899"
-SRC_URI = "git://github.com/CISOfy/Lynis.git"
-S = "${WORKDIR}/git"
-
-inherit autotools-brokensep
-
-do_compile[noexec] = "1"
-do_configure[noexec] = "1"
-
-do_install () {
-	install -d ${D}/${bindir}
-	install -d ${D}/${sysconfdir}/lynis
-	install -m 555 ${S}/lynis ${D}/${bindir}
-
-	install -d ${D}/${datadir}/lynis/db
-	install -d ${D}/${datadir}/lynis/plugins
-	install -d ${D}/${datadir}/lynis/include
-	install -d ${D}/${datadir}/lynis/extras
-
-	cp -r ${S}/db/* ${D}/${datadir}/lynis/db/.
-	cp -r ${S}/plugins/*  ${D}/${datadir}/lynis/plugins/.
-	cp -r ${S}/include/* ${D}/${datadir}/lynis/include/.
-	cp -r ${S}/extras/*  ${D}/${datadir}/lynis/extras/.
-        cp ${S}/*.prf ${D}/${sysconfdir}/lynis
-}
-
-FILES_${PN} += "${sysconfdir}/developer.prf ${sysconfdir}/default.prf"
-FILES_${PN}-doc += "lynis.8 FAQ README CHANGELOG.md CONTRIBUTIONS.md CONTRIBUTORS.md" 
-
-RDEPENDS_${PN} += "procps"
diff --git a/meta-security/meta-security-compliance/recipes-auditors/lynis/lynis_2.6.8.bb b/meta-security/meta-security-compliance/recipes-auditors/lynis/lynis_2.6.8.bb
new file mode 100644
index 0000000..28a4469
--- /dev/null
+++ b/meta-security/meta-security-compliance/recipes-auditors/lynis/lynis_2.6.8.bb
@@ -0,0 +1,41 @@
+# Copyright (C) 2017 Armin Kuster  <akuster808@gmail.com>
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+SUMMARY = "Lynis is a free and open source security and auditing tool."
+HOMEDIR = "https://cisofy.com/"
+LICENSE = "GPL-3.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=3edd6782854304fd11da4975ab9799c1"
+
+SRC_URI = "https://cisofy.com/files/${BPN}-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "91a538055bfb682733ef8e4fe7eb0902"
+SRC_URI[sha256sum] = "2e4c5157a4f2d9bb37d3f0f1f5bea03f92233a2a7d4df6eddf231a784087dfac"
+
+S = "${WORKDIR}/${BPN}"
+
+inherit autotools-brokensep
+
+do_compile[noexec] = "1"
+do_configure[noexec] = "1"
+
+do_install () {
+	install -d ${D}/${bindir}
+	install -d ${D}/${sysconfdir}/lynis
+	install -m 555 ${S}/lynis ${D}/${bindir}
+
+	install -d ${D}/${datadir}/lynis/db
+	install -d ${D}/${datadir}/lynis/plugins
+	install -d ${D}/${datadir}/lynis/include
+	install -d ${D}/${datadir}/lynis/extras
+
+	cp -r ${S}/db/* ${D}/${datadir}/lynis/db/.
+	cp -r ${S}/plugins/*  ${D}/${datadir}/lynis/plugins/.
+	cp -r ${S}/include/* ${D}/${datadir}/lynis/include/.
+	cp -r ${S}/extras/*  ${D}/${datadir}/lynis/extras/.
+        cp ${S}/*.prf ${D}/${sysconfdir}/lynis
+}
+
+FILES_${PN} += "${sysconfdir}/developer.prf ${sysconfdir}/default.prf"
+FILES_${PN}-doc += "lynis.8 FAQ README CHANGELOG.md CONTRIBUTIONS.md CONTRIBUTORS.md" 
+
+RDEPENDS_${PN} += "procps"
diff --git a/meta-security/meta-security-compliance/recipes-core/os-release/os-release.bbappend b/meta-security/meta-security-compliance/recipes-core/os-release/os-release.bbappend
index e9fd44a..604bacb 100644
--- a/meta-security/meta-security-compliance/recipes-core/os-release/os-release.bbappend
+++ b/meta-security/meta-security-compliance/recipes-core/os-release/os-release.bbappend
@@ -1,4 +1 @@
-OS_RELEASE_FIELDS += "CPE_NAME"
-
 CPE_NAME="cpe:/o:openembedded:nodistro:0"
-
diff --git a/meta-security/meta-security-compliance/recipes-openscap/openscap-daemon/openscap-daemon_0.1.10.bb b/meta-security/meta-security-compliance/recipes-openscap/openscap-daemon/openscap-daemon_0.1.10.bb
new file mode 100644
index 0000000..a6a9373
--- /dev/null
+++ b/meta-security/meta-security-compliance/recipes-openscap/openscap-daemon/openscap-daemon_0.1.10.bb
@@ -0,0 +1,18 @@
+# Copyright (C) 2017 Armin Kuster  <akuster808@gmail.com>
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+SUMARRY = "The OpenSCAP Daemon is a service that runs in the background."
+HOME_URL = "https://www.open-scap.org/tools/openscap-daemon/"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=40d2542b8c43a3ec2b7f5da31a697b88"
+LICENSE = "LGPL-2.1"
+
+DEPENDS = "python3-dbus"
+
+SRCREV = "f25b16afb6ac761fea13132ff406fba4cdfd2b76"
+SRC_URI = "git://github.com/OpenSCAP/openscap-daemon.git"
+
+inherit setuptools3
+
+S = "${WORKDIR}/git"
+
+RDEPENDS_${PN} = "python"
diff --git a/meta-security/meta-security-compliance/recipes-openscap/openscap-daemon/openscap-daemon_0.1.6.bb b/meta-security/meta-security-compliance/recipes-openscap/openscap-daemon/openscap-daemon_0.1.6.bb
deleted file mode 100644
index fb01a11..0000000
--- a/meta-security/meta-security-compliance/recipes-openscap/openscap-daemon/openscap-daemon_0.1.6.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-# Copyright (C) 2017 Armin Kuster  <akuster808@gmail.com>
-# Released under the MIT license (see COPYING.MIT for the terms)
-
-SUMARRY = "The OpenSCAP Daemon is a service that runs in the background."
-HOME_URL = "https://www.open-scap.org/tools/openscap-daemon/"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=40d2542b8c43a3ec2b7f5da31a697b88"
-LICENSE = "LGPL-2.1"
-
-DEPENDS = "python3-dbus"
-
-SRCREV = "3fd5c75a08223de35a865d026d2a6980ec9c1d74"
-SRC_URI = "git://github.com/OpenSCAP/openscap-daemon.git"
-
-PV = "0.1.6+git${SRCPV}"
-
-inherit setuptools3
-
-S = "${WORKDIR}/git"
-
-RDEPENDS_${PN} = "python"
diff --git a/meta-security/meta-security-compliance/recipes-openscap/openscap/openscap_1.2.15.bb b/meta-security/meta-security-compliance/recipes-openscap/openscap/openscap_1.2.15.bb
deleted file mode 100644
index 7cbb1e2..0000000
--- a/meta-security/meta-security-compliance/recipes-openscap/openscap/openscap_1.2.15.bb
+++ /dev/null
@@ -1,86 +0,0 @@
-# Copyright (C) 2017 Armin Kuster  <akuster808@gmail.com>
-# Released under the MIT license (see COPYING.MIT for the terms)
-
-SUMARRY = "NIST Certified SCAP 1.2 toolkit"
-HOME_URL = "https://www.open-scap.org/tools/openscap-base/"
-LIC_FILES_CHKSUM = "file://COPYING;md5=fbc093901857fcd118f065f900982c24"
-LICENSE = "LGPL-2.1"
-
-DEPENDS = "autoconf-archive pkgconfig gconf procps curl libxml2 rpm \
-          libxslt libcap swig swig-native"
-
-DEPENDS_class-native = "autoconf-archive-native pkgconfig-native swig-native curl-native libxml2-native libxslt-native dpkg-native libgcrypt-native nss-native"
-
-SRCREV = "240930d42611983c65ecae16dbca3248ce130921"
-SRC_URI = "git://github.com/akuster/openscap.git;branch=oe \
-           file://crypto_pkgconfig.patch \
-           file://run-ptest \
-"
-
-inherit autotools-brokensep pkgconfig python3native perlnative ptest
-
-S = "${WORKDIR}/git"
-
-PACKAGECONFIG ?= "nss3 pcre rpm"
-PACKAGECONFIG[pcre] = ",--enable-regex-posix, libpcre"
-PACKAGECONFIG[gcrypt] = "--with-crypto=gcrypt,, libgcrypt "
-PACKAGECONFIG[nss3] = "--with-crypto=nss3,, nss"
-PACKAGECONFIG[python] = "--enable-python, --disable-python, python, python"
-PACKAGECONFIG[python3] = "--enable-python3, --disable-python3, python3, python3"
-PACKAGECONFIG[perl] = "--enable-perl, --disable-perl, perl, perl"
-PACKAGECONFIG[rpm] = " --enable-util-scap-as-rpm, --disable-util-scap-as-rpm, rpm, rpm"
-
-export LDFLAGS += " -ldl"
-
-EXTRA_OECONF += "--enable-probes-independent --enable-probes-linux \
-		--enable-probes-solaris --enable-probes-unix  --disable-util-oscap-docker\
-		--enable-util-oscap-ssh --enable-util-oscap --enable-ssp --enable-sce \
-"
-
-EXTRA_OECONF_class-native += "--disable-probes-independent --enable-probes-linux \
-		--disable-probes-solaris --disable-probes-unix \
-		--enable-util-oscap \
-"
-
-do_configure_prepend () {
-	sed -i 's:-I/usr/include:-I${STAGING_INCDIR}:' ${S}/swig/perl/Makefile.am
-	sed -i 's:-I/usr/include:-I${STAGING_INCDIR}:' ${S}/swig/python3/Makefile.am
-	sed -i 's:-I/usr/include:-I${STAGING_INCDIR}:' ${S}/swig/python2/Makefile.am
-}
-
-
-include openscap.inc
-
-do_configure_append_class-native () {
-	sed -i 's:OSCAP_DEFAULT_CPE_PATH.*$:OSCAP_DEFAULT_CPE_PATH "${STAGING_OSCAP_BUILDDIR}${datadir_native}/openscap/cpe":' ${S}/config.h
-	sed -i 's:OSCAP_DEFAULT_SCHEMA_PATH.*$:OSCAP_DEFAULT_SCHEMA_PATH "${STAGING_OSCAP_BUILDDIR}${datadir_native}/openscap/schemas":' ${S}/config.h
-	sed -i 's:OSCAP_DEFAULT_XSLT_PATH.*$:OSCAP_DEFAULT_XSLT_PATH "${STAGING_OSCAP_BUILDDIR}${datadir_native}/openscap/xsl":' ${S}/config.h
-}
-
-do_clean[cleandirs] += " ${STAGING_OSCAP_BUILDDIR}"
-
-do_install_append_class-native () {
-	oscapdir=${STAGING_OSCAP_BUILDDIR}/${datadir_native}
-	install -d $oscapdir	
-	cp -a ${D}/${STAGING_DATADIR_NATIVE}/openscap $oscapdir
-}
-
-TESTDIR = "tests"
-
-do_compile_ptest() {
-    sed -i 's:python2:python:' ${S}/${TESTDIR}/nist/test_worker.py
-    echo 'buildtest-TESTS: $(check)' >> ${TESTDIR}/Makefile
-    oe_runmake -C ${TESTDIR} buildtest-TESTS
-}
-
-do_install_ptest() {
-    # install the tests
-    cp -rf ${B}/${TESTDIR} ${D}${PTEST_PATH}
-}
-
-FILES_${PN} += "${PYTHON_SITEPACKAGES_DIR}"
-
-RDEPENDS_${PN} += "libxml2 python libgcc"
-RDEPENDS_${PN}-ptest = "bash perl python"
-
-BBCLASSEXTEND = "native"
diff --git a/meta-security/meta-security-compliance/recipes-openscap/openscap/openscap_1.2.17.bb b/meta-security/meta-security-compliance/recipes-openscap/openscap/openscap_1.2.17.bb
new file mode 100644
index 0000000..e2a4fa2
--- /dev/null
+++ b/meta-security/meta-security-compliance/recipes-openscap/openscap/openscap_1.2.17.bb
@@ -0,0 +1,87 @@
+# Copyright (C) 2017 Armin Kuster  <akuster808@gmail.com>
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+SUMARRY = "NIST Certified SCAP 1.2 toolkit"
+HOME_URL = "https://www.open-scap.org/tools/openscap-base/"
+LIC_FILES_CHKSUM = "file://COPYING;md5=fbc093901857fcd118f065f900982c24"
+LICENSE = "LGPL-2.1"
+
+DEPENDS = "autoconf-archive pkgconfig gconf procps curl libxml2 rpm \
+          libxslt libcap swig swig-native"
+
+DEPENDS_class-native = "autoconf-archive-native pkgconfig-native swig-native curl-native libxml2-native libxslt-native dpkg-native libgcrypt-native nss-native"
+
+SRCREV = "59c234b3e9907480c89dfbd1b466a6bf72a2d2ed"
+SRC_URI = "git://github.com/akuster/openscap.git;branch=oe \
+           file://crypto_pkgconfig.patch \
+           file://run-ptest \
+"
+
+inherit autotools-brokensep pkgconfig python3native perlnative ptest
+
+S = "${WORKDIR}/git"
+
+PACKAGECONFIG ?= "nss3 pcre rpm"
+PACKAGECONFIG[pcre] = ",--enable-regex-posix, libpcre"
+PACKAGECONFIG[gcrypt] = "--with-crypto=gcrypt,, libgcrypt "
+PACKAGECONFIG[nss3] = "--with-crypto=nss3,, nss"
+PACKAGECONFIG[python] = "--enable-python, --disable-python, python, python"
+PACKAGECONFIG[python3] = "--enable-python3, --disable-python3, python3, python3"
+PACKAGECONFIG[perl] = "--enable-perl, --disable-perl, perl, perl"
+PACKAGECONFIG[rpm] = " --enable-util-scap-as-rpm, --disable-util-scap-as-rpm, rpm, rpm"
+
+export LDFLAGS += " -ldl"
+
+EXTRA_OECONF += "--enable-probes-independent --enable-probes-linux \
+		--enable-probes-solaris --enable-probes-unix  --disable-util-oscap-docker\
+		--enable-util-oscap-ssh --enable-util-oscap --enable-ssp --enable-sce \
+"
+
+EXTRA_OECONF_class-native += "--disable-probes-independent --enable-probes-linux \
+		--disable-probes-solaris --disable-probes-unix \
+		--enable-util-oscap \
+"
+
+do_configure_prepend () {
+	sed -i 's:-I/usr/include:-I${STAGING_INCDIR}:' ${S}/swig/perl/Makefile.am
+	sed -i 's:-I/usr/include:-I${STAGING_INCDIR}:' ${S}/swig/python3/Makefile.am
+	sed -i 's:-I/usr/include:-I${STAGING_INCDIR}:' ${S}/swig/python2/Makefile.am
+	sed -i 's:python2:python:' ${S}/utils/scap-as-rpm
+}
+
+
+include openscap.inc
+
+do_configure_append_class-native () {
+	sed -i 's:OSCAP_DEFAULT_CPE_PATH.*$:OSCAP_DEFAULT_CPE_PATH "${STAGING_OSCAP_BUILDDIR}${datadir_native}/openscap/cpe":' ${S}/config.h
+	sed -i 's:OSCAP_DEFAULT_SCHEMA_PATH.*$:OSCAP_DEFAULT_SCHEMA_PATH "${STAGING_OSCAP_BUILDDIR}${datadir_native}/openscap/schemas":' ${S}/config.h
+	sed -i 's:OSCAP_DEFAULT_XSLT_PATH.*$:OSCAP_DEFAULT_XSLT_PATH "${STAGING_OSCAP_BUILDDIR}${datadir_native}/openscap/xsl":' ${S}/config.h
+}
+
+do_clean[cleandirs] += " ${STAGING_OSCAP_BUILDDIR}"
+
+do_install_append_class-native () {
+	oscapdir=${STAGING_OSCAP_BUILDDIR}/${datadir_native}
+	install -d $oscapdir	
+	cp -a ${D}/${STAGING_DATADIR_NATIVE}/openscap $oscapdir
+}
+
+TESTDIR = "tests"
+
+do_compile_ptest() {
+    sed -i 's:python2:python:' ${S}/${TESTDIR}/nist/test_worker.py
+    echo 'buildtest-TESTS: $(check)' >> ${TESTDIR}/Makefile
+    oe_runmake -C ${TESTDIR} buildtest-TESTS
+}
+
+do_install_ptest() {
+    # install the tests
+    cp -rf ${B}/${TESTDIR} ${D}${PTEST_PATH}
+}
+
+FILES_${PN} += "${PYTHON_SITEPACKAGES_DIR}"
+
+RDEPENDS_${PN} += "libxml2 python libgcc"
+RDEPENDS_${PN}-ptest = "bash perl python"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-security/meta-tpm/conf/layer.conf b/meta-security/meta-tpm/conf/layer.conf
index a2f0cab..1b5f7d5 100644
--- a/meta-security/meta-tpm/conf/layer.conf
+++ b/meta-security/meta-tpm/conf/layer.conf
@@ -6,9 +6,9 @@
 
 BBFILE_COLLECTIONS += "tpm-layer"
 BBFILE_PATTERN_tpm-layer = "^${LAYERDIR}/"
-BBFILE_PRIORITY_tpm-layer = "6"
+BBFILE_PRIORITY_tpm-layer = "10"
 
-LAYERSERIES_COMPAT_tpm-layer = "sumo"
+LAYERSERIES_COMPAT_tpm-layer = "thud"
 
 LAYERDEPENDS_tpm-layer = " \
     core \
diff --git a/meta-security/meta-tpm/recipes-core/packagegroup/packagegroup-security-tpm2.bb b/meta-security/meta-tpm/recipes-core/packagegroup/packagegroup-security-tpm2.bb
index 13b505f..c4c8fb2 100644
--- a/meta-security/meta-tpm/recipes-core/packagegroup/packagegroup-security-tpm2.bb
+++ b/meta-security/meta-tpm/recipes-core/packagegroup/packagegroup-security-tpm2.bb
@@ -1,4 +1,4 @@
-DESCRIPTION = "Security packagegroup for Poky"
+DESCRIPTION = "TPM2 packagegroup for Security"
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302 \
                     file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
@@ -12,7 +12,7 @@
     tpm2.0-tools \
     trousers \
     libtss2 \
-    libtctidevice \
-    libtctisocket \
-    resourcemgr \
+    libtss2-tcti-device \
+    libtss2-tcti-mssim \
+    tpm2-abrmd \
     "
diff --git a/meta-security/meta-tpm/recipes-tpm/libtpm/libtpm_1.0.bb b/meta-security/meta-tpm/recipes-tpm/libtpm/libtpm_1.0.bb
index b29ec6b..a930d7b 100644
--- a/meta-security/meta-tpm/recipes-tpm/libtpm/libtpm_1.0.bb
+++ b/meta-security/meta-tpm/recipes-tpm/libtpm/libtpm_1.0.bb
@@ -1,11 +1,9 @@
 SUMMARY = "LIBPM - Software TPM Library"
 LICENSE = "BSD-3-Clause"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=97e5eea8d700d76b3ddfd35c4c96485f"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=e73f0786a936da3814896df06ad225a9"
 
-SRCREV = "3388d45082bdc588c6fc0672f44d6d7d0aaa86ff"
-SRC_URI = " \
-	git://github.com/stefanberger/libtpms.git \
-	"
+SRCREV = "4111bd1bcf721e6e7b5f11ed9c2b93083677aa25"
+SRC_URI = "git://github.com/stefanberger/libtpms.git"
 
 S = "${WORKDIR}/git"
 inherit autotools-brokensep pkgconfig
diff --git a/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0001-create-tpm-key-support-well-known-key-option.patch b/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0001-create-tpm-key-support-well-known-key-option.patch
index 67071b6..bed8b92 100644
--- a/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0001-create-tpm-key-support-well-known-key-option.patch
+++ b/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0001-create-tpm-key-support-well-known-key-option.patch
@@ -8,20 +8,20 @@
 
 Signed-off-by: Junxian.Xiao <Junxian.Xiao@windriver.com>
 
-diff --git a/create_tpm_key.c b/create_tpm_key.c
-index fee917f..7b94d62 100644
---- a/create_tpm_key.c
-+++ b/create_tpm_key.c
-@@ -46,6 +46,8 @@
- #include <trousers/tss.h>
- #include <trousers/trousers.h>
+Index: git/src/create_tpm_key.c
+===================================================================
+--- git.orig/src/create_tpm_key.c
++++ git/src/create_tpm_key.c
+@@ -48,6 +48,8 @@
+ 
+ #include "ssl_compat.h"
  
 +#define TPM_WELL_KNOWN_KEY_LEN 20   /*well know key length is 20 bytes zero*/
 +
  #define print_error(a,b) \
  	fprintf(stderr, "%s:%d %s result: 0x%x (%s)\n", __FILE__, __LINE__, \
  		a, b, Trspi_Error_String(b))
-@@ -70,6 +72,7 @@ usage(char *argv0)
+@@ -72,6 +74,7 @@ usage(char *argv0)
  		"\t\t-e|--enc-scheme  encryption scheme to use [PKCSV15] or OAEP\n"
  		"\t\t-q|--sig-scheme  signature scheme to use [DER] or SHA1\n"
  		"\t\t-s|--key-size    key size in bits [2048]\n"
@@ -29,7 +29,7 @@
  		"\t\t-a|--auth        require a password for the key [NO]\n"
  		"\t\t-p|--popup       use TSS GUI popup dialogs to get the password "
  		"for the\n\t\t\t\t key [NO] (implies --auth)\n"
-@@ -147,6 +150,7 @@ int main(int argc, char **argv)
+@@ -154,6 +157,7 @@ int main(int argc, char **argv)
  	int		asn1_len;
  	char		*filename, c, *openssl_key = NULL;
  	int		option_index, auth = 0, popup = 0, wrap = 0;
@@ -37,7 +37,7 @@
  	UINT32		enc_scheme = TSS_ES_RSAESPKCSV15;
  	UINT32		sig_scheme = TSS_SS_RSASSAPKCS1V15_DER;
  	UINT32		key_size = 2048;
-@@ -154,12 +158,15 @@ int main(int argc, char **argv)
+@@ -161,12 +165,15 @@ int main(int argc, char **argv)
  
  	while (1) {
  		option_index = 0;
@@ -54,7 +54,7 @@
  			case 'a':
  				initFlags |= TSS_KEY_AUTHORIZATION;
  				auth = 1;
-@@ -293,6 +300,8 @@ int main(int argc, char **argv)
+@@ -300,6 +307,8 @@ int main(int argc, char **argv)
  
  	if (srk_authusage) {
  		char *authdata = calloc(1, 128);
@@ -63,7 +63,7 @@
  
  		if (!authdata) {
  			fprintf(stderr, "malloc failed.\n");
-@@ -309,17 +318,26 @@ int main(int argc, char **argv)
+@@ -316,17 +325,26 @@ int main(int argc, char **argv)
  			exit(result);
  		}
  
diff --git a/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0002-libtpm-support-env-TPM_SRK_PW.patch b/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0002-libtpm-support-env-TPM_SRK_PW.patch
index f718f2e..2caaaf0 100644
--- a/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0002-libtpm-support-env-TPM_SRK_PW.patch
+++ b/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0002-libtpm-support-env-TPM_SRK_PW.patch
@@ -9,20 +9,20 @@
 
 Signed-off-by: Junxian.Xiao <Junxian.Xiao@windriver.com>
 
-diff --git a/e_tpm.c b/e_tpm.c
-index f3e8bcf..7dcb75a 100644
---- a/e_tpm.c
-+++ b/e_tpm.c
+Index: git/src/e_tpm.c
+===================================================================
+--- git.orig/src/e_tpm.c
++++ git/src/e_tpm.c
 @@ -38,6 +38,8 @@
- 
  #include "e_tpm.h"
+ #include "ssl_compat.h"
  
 +#define TPM_WELL_KNOWN_KEY_LEN 20   /*well know key length is 20 bytes zero*/
 +
  //#define DLOPEN_TSPI
  
  #ifndef OPENSSL_NO_HW
-@@ -248,6 +250,10 @@ int tpm_load_srk(UI_METHOD *ui, void *cb_data)
+@@ -262,6 +264,10 @@ int tpm_load_srk(UI_METHOD *ui, void *cb
  	TSS_RESULT result;
  	UINT32 authusage;
  	BYTE *auth;
@@ -33,7 +33,7 @@
  
  	if (hSRK != NULL_HKEY) {
  		DBGFN("SRK is already loaded.");
-@@ -299,18 +305,36 @@ int tpm_load_srk(UI_METHOD *ui, void *cb_data)
+@@ -313,18 +319,36 @@ int tpm_load_srk(UI_METHOD *ui, void *cb
  		return 0;
  	}
  
diff --git a/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0003-Fix-not-building-libtpm.la.patch b/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0003-Fix-not-building-libtpm.la.patch
deleted file mode 100644
index d24a150..0000000
--- a/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0003-Fix-not-building-libtpm.la.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 7848445a1f4c750ef73bf96f5e89d402f87a1756 Mon Sep 17 00:00:00 2001
-From: Lans Zhang <jia.zhang@windriver.com>
-Date: Mon, 19 Jun 2017 14:54:28 +0800
-Subject: [PATCH] Fix not building libtpm.la
-
-Signed-off-by: Lans Zhang <jia.zhang@windriver.com>
----
- Makefile.am | 4 +++-
- 1 file changed, 3 insertions(+), 1 deletion(-)
-
-diff --git a/Makefile.am b/Makefile.am
-index 6695656..634a7e6 100644
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -10,4 +10,6 @@ libtpm_la_LIBADD=-lcrypto -lc -ltspi
- libtpm_la_SOURCES=e_tpm.c e_tpm.h e_tpm_err.c
- 
- create_tpm_key_SOURCES=create_tpm_key.c
--create_tpm_key_LDADD=-ltspi
-+create_tpm_key_LDFLAGS=-ltspi
-+
-+LDADD=libtpm.la
--- 
-2.7.5
-
diff --git a/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0003-tpm-openssl-tpm-engine-parse-an-encrypted-tpm-SRK-pa.patch b/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0003-tpm-openssl-tpm-engine-parse-an-encrypted-tpm-SRK-pa.patch
index a88148f..cc8772d 100644
--- a/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0003-tpm-openssl-tpm-engine-parse-an-encrypted-tpm-SRK-pa.patch
+++ b/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0003-tpm-openssl-tpm-engine-parse-an-encrypted-tpm-SRK-pa.patch
@@ -22,11 +22,11 @@
  e_tpm_err.c |   4 ++
  3 files changed, 164 insertions(+), 1 deletion(-)
 
-diff --git a/e_tpm.c b/e_tpm.c
-index 7dcb75a..11bf74b 100644
---- a/e_tpm.c
-+++ b/e_tpm.c
-@@ -245,6 +245,118 @@ void ENGINE_load_tpm(void)
+Index: git/src/e_tpm.c
+===================================================================
+--- git.orig/src/e_tpm.c
++++ git/src/e_tpm.c
+@@ -259,6 +259,118 @@ void ENGINE_load_tpm(void)
  	ERR_clear_error();
  }
  
@@ -145,7 +145,7 @@
  int tpm_load_srk(UI_METHOD *ui, void *cb_data)
  {
  	TSS_RESULT result;
-@@ -305,8 +417,50 @@ int tpm_load_srk(UI_METHOD *ui, void *cb_data)
+@@ -319,8 +431,50 @@ int tpm_load_srk(UI_METHOD *ui, void *cb
  		return 0;
  	}
  
@@ -197,7 +197,7 @@
  		if (0 == strcmp(srkPasswd, "#WELLKNOWN#")) {
  			memset(auth, 0, TPM_WELL_KNOWN_KEY_LEN);
  			secretMode = TSS_SECRET_MODE_SHA1;
-@@ -319,6 +473,7 @@ int tpm_load_srk(UI_METHOD *ui, void *cb_data)
+@@ -333,6 +487,7 @@ int tpm_load_srk(UI_METHOD *ui, void *cb
  			authlen = strlen(auth);
  		}
  	}
@@ -205,11 +205,11 @@
  	else {
  		if (!tpm_engine_get_auth(ui, (char *)auth, 128,
  				"SRK authorization: ", cb_data)) {
-diff --git a/e_tpm.h b/e_tpm.h
-index 6316e0b..56ff202 100644
---- a/e_tpm.h
-+++ b/e_tpm.h
-@@ -66,6 +66,8 @@ void ERR_TSS_error(int function, int reason, char *file, int line);
+Index: git/src/e_tpm.h
+===================================================================
+--- git.orig/src/e_tpm.h
++++ git/src/e_tpm.h
+@@ -66,6 +66,8 @@ void ERR_TSS_error(int function, int rea
  #define TPM_F_TPM_FILL_RSA_OBJECT		116
  #define TPM_F_TPM_ENGINE_GET_AUTH		117
  #define TPM_F_TPM_CREATE_SRK_POLICY		118
@@ -218,7 +218,7 @@
  
  /* Reason codes. */
  #define TPM_R_ALREADY_LOADED			100
-@@ -96,6 +98,8 @@ void ERR_TSS_error(int function, int reason, char *file, int line);
+@@ -96,6 +98,8 @@ void ERR_TSS_error(int function, int rea
  #define TPM_R_ID_INVALID			125
  #define TPM_R_UI_METHOD_FAILED			126
  #define TPM_R_UNKNOWN_SECRET_MODE		127
@@ -227,11 +227,11 @@
  
  /* structure pointed to by the RSA object's app_data pointer */
  struct rsa_app_data
-diff --git a/e_tpm_err.c b/e_tpm_err.c
-index 25a5d0f..439e267 100644
---- a/e_tpm_err.c
-+++ b/e_tpm_err.c
-@@ -235,6 +235,8 @@ static ERR_STRING_DATA TPM_str_functs[] = {
+Index: git/src/e_tpm_err.c
+===================================================================
+--- git.orig/src/e_tpm_err.c
++++ git/src/e_tpm_err.c
+@@ -234,6 +234,8 @@ static ERR_STRING_DATA TPM_str_functs[]
  	{ERR_PACK(0, TPM_F_TPM_BIND_FN, 0), "TPM_BIND_FN"},
  	{ERR_PACK(0, TPM_F_TPM_FILL_RSA_OBJECT, 0), "TPM_FILL_RSA_OBJECT"},
  	{ERR_PACK(0, TPM_F_TPM_ENGINE_GET_AUTH, 0), "TPM_ENGINE_GET_AUTH"},
@@ -240,7 +240,7 @@
  	{0, NULL}
  };
  
-@@ -265,6 +267,8 @@ static ERR_STRING_DATA TPM_str_reasons[] = {
+@@ -264,6 +266,8 @@ static ERR_STRING_DATA TPM_str_reasons[]
  	{TPM_R_FILE_READ_FAILED, "failed reading the key file"},
  	{TPM_R_ID_INVALID, "engine id doesn't match"},
  	{TPM_R_UI_METHOD_FAILED, "ui function failed"},
@@ -249,6 +249,3 @@
  	{0, NULL}
  };
  
--- 
-2.9.3
-
diff --git a/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0004-tpm-openssl-tpm-engine-change-variable-c-type-from-c.patch b/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0004-tpm-openssl-tpm-engine-change-variable-c-type-from-c.patch
index 076704d..535472a 100644
--- a/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0004-tpm-openssl-tpm-engine-change-variable-c-type-from-c.patch
+++ b/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0004-tpm-openssl-tpm-engine-change-variable-c-type-from-c.patch
@@ -15,11 +15,11 @@
  create_tpm_key.c |    3 ++-
  1 file changed, 2 insertions(+), 1 deletion(-)
 
-diff --git a/create_tpm_key.c b/create_tpm_key.c
-index 7b94d62..f30af90 100644
---- a/create_tpm_key.c
-+++ b/create_tpm_key.c
-@@ -148,7 +148,8 @@ int main(int argc, char **argv)
+Index: git/src/create_tpm_key.c
+===================================================================
+--- git.orig/src/create_tpm_key.c
++++ git/src/create_tpm_key.c
+@@ -155,7 +155,8 @@ int main(int argc, char **argv)
  	ASN1_OCTET_STRING *blob_str;
  	unsigned char	*blob_asn1 = NULL;
  	int		asn1_len;
@@ -29,6 +29,3 @@
  	int		option_index, auth = 0, popup = 0, wrap = 0;
  	int		wellknownkey = 0;
  	UINT32		enc_scheme = TSS_ES_RSAESPKCSV15;
--- 
-1.7.9.5
-
diff --git a/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/openssl11_build_fix.patch b/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/openssl11_build_fix.patch
new file mode 100644
index 0000000..2f8eb81
--- /dev/null
+++ b/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/files/openssl11_build_fix.patch
@@ -0,0 +1,34 @@
+Fix compiling for openssl 1.1
+
+Upstream-Status: Pending
+Signed-off-by: Armin Kuster <akuster808@gmail.com>
+
+Index: git/src/e_tpm.c
+===================================================================
+--- git.orig/src/e_tpm.c
++++ git/src/e_tpm.c
+@@ -265,19 +265,20 @@ static int tpm_decode_base64(unsigned ch
+ 				int *out_len)
+ {
+ 	int total_len, len, ret;
+-	EVP_ENCODE_CTX dctx;
++	EVP_ENCODE_CTX *dctx;
+ 
+-	EVP_DecodeInit(&dctx);
++	dctx = EVP_ENCODE_CTX_new();
++	EVP_DecodeInit(dctx);
+ 
+ 	total_len = 0;
+-	ret = EVP_DecodeUpdate(&dctx, outdata, &len, indata, in_len);
++	ret = EVP_DecodeUpdate(dctx, outdata, &len, indata, in_len);
+ 	if (ret < 0) {
+ 		TSSerr(TPM_F_TPM_DECODE_BASE64, TPM_R_DECODE_BASE64_FAILED);
+ 		return 1;
+ 	}
+ 
+ 	total_len += len;
+-	ret = EVP_DecodeFinal(&dctx, outdata, &len);
++	ret = EVP_DecodeFinal(dctx, outdata, &len);
+ 	if (ret < 0) {
+ 		TSSerr(TPM_F_TPM_DECODE_BASE64, TPM_R_DECODE_BASE64_FAILED);
+ 		return 1;
diff --git a/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/openssl-tpm-engine_0.4.2.bb b/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/openssl-tpm-engine_0.4.2.bb
deleted file mode 100644
index 4854f70..0000000
--- a/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/openssl-tpm-engine_0.4.2.bb
+++ /dev/null
@@ -1,78 +0,0 @@
-DESCRIPTION = "OpenSSL secure engine based on TPM hardware"
-HOMEPAGE = "https://sourceforge.net/projects/trousers/"
-SECTION = "security/tpm"
-
-LICENSE = "openssl"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=11f0ee3af475c85b907426e285c9bb52"
-
-DEPENDS += "openssl trousers"
-
-SRC_URI = "\
-    git://git.code.sf.net/p/trousers/openssl_tpm_engine \
-    file://0001-create-tpm-key-support-well-known-key-option.patch \
-    file://0002-libtpm-support-env-TPM_SRK_PW.patch \
-    file://0003-Fix-not-building-libtpm.la.patch \
-    file://0003-tpm-openssl-tpm-engine-parse-an-encrypted-tpm-SRK-pa.patch \
-    file://0004-tpm-openssl-tpm-engine-change-variable-c-type-from-c.patch \
-"
-SRCREV = "bbc2b1af809f20686e0d3553a62f0175742c0d60"
-
-S = "${WORKDIR}/git"
-
-inherit autotools-brokensep
-
-# The definitions below are used to decrypt the srk password.
-# It is allowed to define the values in 3 forms: string, hex number and
-# the hybrid, e.g,
-# srk_dec_pw = "incendia"
-# srk_dec_pw = "\x69\x6e\x63\x65\x6e\x64\x69\x61"
-# srk_dec_pw = "\x1""nc""\x3""nd""\x1""a"
-#
-# Due to the limit of escape character, the hybrid must be written in
-# above style. The actual values defined below in C code style are:
-# srk_dec_pw[] = { 0x01, 'n', 'c', 0x03, 'n', 'd', 0x01, 'a' };
-# srk_dec_salt[] = { 'r', 0x00, 0x00, 't' };
-srk_dec_pw ?= "\\"\\\x1\\"\\"nc\\"\\"\\\x3\\"\\"nd\\"\\"\\\x1\\"\\"a\\""
-srk_dec_salt ?= "\\"r\\"\\"\\\x00\\\x00\\"\\"t\\""
-
-CFLAGS_append += "-DSRK_DEC_PW=${srk_dec_pw} -DSRK_DEC_SALT=${srk_dec_salt}"
-
-# Uncomment below line if using the plain srk password for development
-#CFLAGS_append += "-DTPM_SRK_PLAIN_PW"
-
-do_configure_prepend() {
-    cd "${S}"
-    cp LICENSE COPYING
-    touch NEWS AUTHORS ChangeLog
-}
-
-do_install_append() {
-    install -m 0755 -d "${D}${libdir}/engines"
-    install -m 0755 -d "${D}${prefix}/local/ssl/lib/engines"
-    install -m 0755 -d "${D}${libdir}/ssl/engines"
-
-    cp -f "${D}${libdir}/openssl/engines/libtpm.so.0.0.0" "${D}${libdir}/libtpm.so.0"
-    cp -f "${D}${libdir}/openssl/engines/libtpm.so.0.0.0" "${D}${libdir}/engines/libtpm.so"
-    cp -f "${D}${libdir}/openssl/engines/libtpm.so.0.0.0" "${D}${prefix}/local/ssl/lib/engines/libtpm.so"
-    mv -f "${D}${libdir}/openssl/engines/libtpm.so.0.0.0" "${D}${libdir}/ssl/engines/libtpm.so"
-    mv -f "${D}${libdir}/openssl/engines/libtpm.la" "${D}${libdir}/ssl/engines/libtpm.la"
-    rm -rf "${D}${libdir}/openssl"
-}
-
-FILES_${PN}-staticdev += "${libdir}/ssl/engines/libtpm.la"
-FILES_${PN}-dbg += "\
-    ${libdir}/ssl/engines/.debug \
-    ${libdir}/engines/.debug \
-    ${prefix}/local/ssl/lib/engines/.debug \
-"
-FILES_${PN} += "\
-    ${libdir}/ssl/engines/libtpm.so* \
-    ${libdir}/engines/libtpm.so* \
-    ${libdir}/libtpm.so* \
-    ${prefix}/local/ssl/lib/engines/libtpm.so* \
-"
-
-RDEPENDS_${PN} += "libcrypto libtspi"
-
-INSANE_SKIP_${PN} = "libdir"
-INSANE_SKIP_${PN}-dbg = "libdir"
diff --git a/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/openssl-tpm-engine_0.5.0.bb b/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/openssl-tpm-engine_0.5.0.bb
new file mode 100644
index 0000000..0f98b79
--- /dev/null
+++ b/meta-security/meta-tpm/recipes-tpm/openssl-tpm-engine/openssl-tpm-engine_0.5.0.bb
@@ -0,0 +1,65 @@
+DESCRIPTION = "OpenSSL secure engine based on TPM hardware"
+HOMEPAGE = "https://github.com/mgerstner/openssl_tpm_engine"
+SECTION = "security/tpm"
+
+LICENSE = "openssl"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=11f0ee3af475c85b907426e285c9bb52"
+
+DEPENDS += "openssl trousers"
+
+SRC_URI = "\
+    git://github.com/mgerstner/openssl_tpm_engine.git \
+    file://0001-create-tpm-key-support-well-known-key-option.patch \
+    file://0002-libtpm-support-env-TPM_SRK_PW.patch \
+    file://0003-tpm-openssl-tpm-engine-parse-an-encrypted-tpm-SRK-pa.patch \
+    file://0004-tpm-openssl-tpm-engine-change-variable-c-type-from-c.patch \
+    file://openssl11_build_fix.patch \
+"
+SRCREV = "b28de5065e6eb9aa5d5afe2276904f7624c2cbaf"
+
+S = "${WORKDIR}/git"
+
+inherit autotools-brokensep pkgconfig
+
+# The definitions below are used to decrypt the srk password.
+# It is allowed to define the values in 3 forms: string, hex number and
+# the hybrid, e.g,
+# srk_dec_pw = "incendia"
+# srk_dec_pw = "\x69\x6e\x63\x65\x6e\x64\x69\x61"
+# srk_dec_pw = "\x1""nc""\x3""nd""\x1""a"
+#
+# Due to the limit of escape character, the hybrid must be written in
+# above style. The actual values defined below in C code style are:
+# srk_dec_pw[] = { 0x01, 'n', 'c', 0x03, 'n', 'd', 0x01, 'a' };
+# srk_dec_salt[] = { 'r', 0x00, 0x00, 't' };
+srk_dec_pw ?= "\\"\\\x1\\"\\"nc\\"\\"\\\x3\\"\\"nd\\"\\"\\\x1\\"\\"a\\""
+srk_dec_salt ?= "\\"r\\"\\"\\\x00\\\x00\\"\\"t\\""
+
+CFLAGS_append += "-DSRK_DEC_PW=${srk_dec_pw} -DSRK_DEC_SALT=${srk_dec_salt}"
+
+# Uncomment below line if using the plain srk password for development
+#CFLAGS_append += "-DTPM_SRK_PLAIN_PW"
+
+do_configure_prepend() {
+    cd ${B}
+    cp LICENSE COPYING
+    touch NEWS AUTHORS ChangeLog README
+}
+
+FILES_${PN}-staticdev += "${libdir}/ssl/engines-1.1/tpm.la"
+FILES_${PN}-dbg += "\
+    ${libdir}/ssl/engines-1.1/.debug \
+    ${libdir}/engines-1.1/.debug \
+    ${prefix}/local/ssl/lib/engines-1.1/.debug \
+"
+FILES_${PN} += "\
+    ${libdir}/ssl/engines-1.1/tpm.so* \
+    ${libdir}/engines-1.1/tpm.so* \
+    ${libdir}/libtpm.so* \
+    ${prefix}/local/ssl/lib/engines-1.1/tpm.so* \
+"
+
+RDEPENDS_${PN} += "libcrypto libtspi"
+
+INSANE_SKIP_${PN} = "libdir"
+INSANE_SKIP_${PN}-dbg = "libdir"
diff --git a/meta-security/meta-tpm/recipes-tpm/pcr-extend/files/fix_openssl11_build.patch b/meta-security/meta-tpm/recipes-tpm/pcr-extend/files/fix_openssl11_build.patch
new file mode 100644
index 0000000..cf2d437
--- /dev/null
+++ b/meta-security/meta-tpm/recipes-tpm/pcr-extend/files/fix_openssl11_build.patch
@@ -0,0 +1,45 @@
+Enable building with openssl 1.1
+
+Upstream-Status: Pending
+Signed-off-by: Armin Kuster <akuster808@gmail.com>
+
+Index: git/src/pcr-extend.c
+===================================================================
+--- git.orig/src/pcr-extend.c
++++ git/src/pcr-extend.c
+@@ -118,7 +118,7 @@ dump_buf (FILE *file, char *buf, size_t
+ static unsigned char*
+ sha1_file (FILE *file, unsigned int *hash_len)
+ {
+-    EVP_MD_CTX ctx = { 0 };
++    EVP_MD_CTX *ctx = EVP_MD_CTX_new();
+     unsigned char *buf = NULL, *hash = NULL;
+     size_t num_read = 0;
+ 
+@@ -127,7 +127,7 @@ sha1_file (FILE *file, unsigned int *has
+         perror ("malloc:\n");
+         goto sha1_fail;
+     }
+-    if (EVP_DigestInit (&ctx, EVP_sha1 ()) == 0) {
++    if (EVP_DigestInit (ctx, EVP_sha1 ()) == 0) {
+         ERR_print_errors_fp (stderr);
+         goto sha1_fail;
+     }
+@@ -135,7 +135,7 @@ sha1_file (FILE *file, unsigned int *has
+         num_read = fread (buf, 1, BUF_SIZE, file);
+         if (num_read <= 0)
+             break;
+-        if (EVP_DigestUpdate (&ctx, buf, num_read) == 0) {
++        if (EVP_DigestUpdate (ctx, buf, num_read) == 0) {
+             ERR_print_errors_fp (stderr);
+             goto sha1_fail;
+         }
+@@ -149,7 +149,7 @@ sha1_file (FILE *file, unsigned int *has
+         perror ("calloc of hash buffer:\n");
+         goto sha1_fail;
+     }
+-    if (EVP_DigestFinal (&ctx, hash, hash_len) == 0) {
++    if (EVP_DigestFinal (ctx, hash, hash_len) == 0) {
+         ERR_print_errors_fp (stderr);
+         goto sha1_fail;
+     }
diff --git a/meta-security/meta-tpm/recipes-tpm/pcr-extend/pcr-extend_git.bb b/meta-security/meta-tpm/recipes-tpm/pcr-extend/pcr-extend_git.bb
index 0cc4f63..f8347b7 100644
--- a/meta-security/meta-tpm/recipes-tpm/pcr-extend/pcr-extend_git.bb
+++ b/meta-security/meta-tpm/recipes-tpm/pcr-extend/pcr-extend_git.bb
@@ -9,7 +9,8 @@
 PV = "0.1+git${SRCPV}"
 SRCREV = "c02ad8f628b3d99f6d4c087b402fe31a40ee6316"
 
-SRC_URI = "git://github.com/flihp/pcr-extend.git "
+SRC_URI = "git://github.com/flihp/pcr-extend.git \
+           file://fix_openssl11_build.patch "
 
 inherit autotools
 
diff --git a/meta-security/meta-tpm/recipes-tpm/swtpm/swtpm_1.0.bb b/meta-security/meta-tpm/recipes-tpm/swtpm/swtpm_1.0.bb
index 7476020..3fe1393 100644
--- a/meta-security/meta-tpm/recipes-tpm/swtpm/swtpm_1.0.bb
+++ b/meta-security/meta-tpm/recipes-tpm/swtpm/swtpm_1.0.bb
@@ -3,23 +3,21 @@
 LIC_FILES_CHKSUM = "file://LICENSE;md5=fe8092c832b71ef20dfe4c6d3decb3a8"
 SECTION = "apps"
 
-DEPENDS = "libtasn1 expect socat glib-2.0 libtpm libtpm-native"
+DEPENDS = "libtasn1 expect socat glib-2.0 net-tools-native libtpm libtpm-native"
 
 # configure checks for the tools already during compilation and
 # then swtpm_setup needs them at runtime
 DEPENDS += "tpm-tools-native expect-native socat-native"
-RDEPENDS_${PN} += "tpm-tools"
 
-SRCREV = "4f4f2f0a7e3195f6df8d235d58630a08e69403d8"
-SRC_URI = "git://github.com/stefanberger/swtpm.git \
-           file://fix_lib_search_path.patch \
+SRCREV = "94bb9f2d716d09bcc6cd2a2e033018f8592008e7"
+SRC_URI = "git://github.com/stefanberger/swtpm.git;branch=tpm2-preview.v2 \
            file://fix_fcntl_h.patch \
            file://ioctl_h.patch \
            "
 
 S = "${WORKDIR}/git"
 
-inherit autotools-brokensep pkgconfig
+inherit autotools pkgconfig
 PARALLEL_MAKE = ""
 
 TSS_USER="tss"
@@ -36,21 +34,12 @@
 
 export SEARCH_DIR = "${STAGING_LIBDIR_NATIVE}"
 
-# dup bootstrap 
-do_configure_prepend () {
-	libtoolize --force --copy
-	autoheader
-	aclocal
-	automake --add-missing -c
-	autoconf
-}
-
 USERADD_PACKAGES = "${PN}"
 GROUPADD_PARAM_${PN} = "--system ${TSS_USER}"
 USERADD_PARAM_${PN} = "--system -g ${TSS_GROUP} --home-dir  \
     --no-create-home  --shell /bin/false ${BPN}"
 
-RDEPENDS_${PN} = "libtpm expect socat bash"
+RDEPENDS_${PN} = "libtpm expect socat bash tpm-tools"
 
 BBCLASSEXTEND = "native nativesdk"
 
diff --git a/meta-security/meta-tpm/recipes-tpm/tpm-tools/files/04-fix-FTBFS-clang.patch b/meta-security/meta-tpm/recipes-tpm/tpm-tools/files/04-fix-FTBFS-clang.patch
new file mode 100644
index 0000000..5018d45
--- /dev/null
+++ b/meta-security/meta-tpm/recipes-tpm/tpm-tools/files/04-fix-FTBFS-clang.patch
@@ -0,0 +1,56 @@
+Title: Fix FTBFS with clang due to uninitialized values
+Date: 2015-06-28
+Author: Alexander <sanek23994@gmail.com>
+Bug-Debian: http://bugs.debian.org/753063
+
+Upstream-Status: Backport
+tpm-tools_1.3.9.1-0.1.debian.tar
+
+Signed-off-by: Armin kuster <akuster808@gmail.com>
+
+--- tpm-tools-1.3.8/src/tpm_mgmt/tpm_present.c	2012-05-17 21:49:58.000000000 +0400
++++ tpm-tools-1.3.8-my/src/tpm_mgmt/tpm_present.c	2014-06-29 01:01:11.502081468 +0400
+@@ -165,7 +165,7 @@
+ 
+ 	TSS_BOOL bCmd, bHwd;
+ 	BOOL bRc;
+-	TSS_HPOLICY hTpmPolicy;
++	TSS_HPOLICY hTpmPolicy = 0;
+ 	char *pwd = NULL;
+ 	int pswd_len;
+ 	char rsp[5];
+--- tpm-tools-1.3.8/src/tpm_mgmt/tpm_takeownership.c	2010-09-30 21:28:09.000000000 +0400
++++ tpm-tools-1.3.8-my/src/tpm_mgmt/tpm_takeownership.c	2014-06-29 01:01:51.069373655 +0400
+@@ -67,7 +67,7 @@
+ 	char *szSrkPasswd = NULL;
+ 	int tpm_len, srk_len;
+ 	TSS_HTPM hTpm;
+-	TSS_HKEY hSrk;
++	TSS_HKEY hSrk = 0;
+ 	TSS_FLAG fSrkAttrs;
+ 	TSS_HPOLICY hTpmPolicy, hSrkPolicy;
+ 	int iRc = -1;
+--- tpm-tools-1.3.8/src/tpm_mgmt/tpm_nvwrite.c	2011-08-17 16:20:35.000000000 +0400
++++ tpm-tools-1.3.8-my/src/tpm_mgmt/tpm_nvwrite.c	2014-06-29 01:02:45.836397172 +0400
+@@ -220,7 +220,7 @@
+ 		close(fd);
+ 		fd = -1;
+ 	} else if (fillvalue >= 0) {
+-		if (length < 0) {
++		if (length == 0) {
+ 			logError(_("Requiring size parameter.\n"));
+ 			return -1;
+ 		}
+--- tpm-tools-1.3.8/src/data_mgmt/data_protect.c	2012-05-17 21:49:58.000000000 +0400
++++ tpm-tools-1.3.8-my/src/data_mgmt/data_protect.c	2014-06-29 01:03:49.863254459 +0400
+@@ -432,8 +432,8 @@
+ 
+ 	char *pszPin = NULL;
+ 
+-	CK_RV              rv;
+-	CK_SESSION_HANDLE  hSession;
++	CK_RV              rv = 0;
++	CK_SESSION_HANDLE  hSession = 0;
+ 	CK_OBJECT_HANDLE   hObject;
+ 	CK_MECHANISM       tMechanism = { CKM_AES_ECB, NULL, 0 };
+ 
diff --git a/meta-security/meta-tpm/recipes-tpm/tpm-tools/files/05-openssl1.1_fix_data_mgmt.patch b/meta-security/meta-tpm/recipes-tpm/tpm-tools/files/05-openssl1.1_fix_data_mgmt.patch
new file mode 100644
index 0000000..c2a264b
--- /dev/null
+++ b/meta-security/meta-tpm/recipes-tpm/tpm-tools/files/05-openssl1.1_fix_data_mgmt.patch
@@ -0,0 +1,110 @@
+Author: Philipp Kern <pkern@debian.org>
+Subject: Fix openssl1.1 support in data_mgmt
+Date: Tue, 31 Jan 2017 22:40:10 +0100
+
+Upstream-Status: Backport
+tpm-tools_1.3.9.1-0.1.debian.tar
+
+Signed-off-by: Armin kuster <akuster808@gmail.com>
+
+---
+ src/data_mgmt/data_import.c |   60 ++++++++++++++++++++++++++++----------------
+ 1 file changed, 39 insertions(+), 21 deletions(-)
+
+--- a/src/data_mgmt/data_import.c
++++ b/src/data_mgmt/data_import.c
+@@ -372,7 +372,7 @@ readX509Cert( const char  *a_pszFile,
+ 		goto out;
+ 	}
+ 
+-	if ( EVP_PKEY_type( pKey->type ) != EVP_PKEY_RSA ) {
++	if ( EVP_PKEY_base_id( pKey ) != EVP_PKEY_RSA ) {
+ 		logError( TOKEN_RSA_KEY_ERROR );
+ 
+ 		X509_free( pX509 );
+@@ -691,8 +691,13 @@ createRsaPubKeyObject( RSA
+ 
+ 	int  rc = -1;
+ 
+-	int  nLen = BN_num_bytes( a_pRsa->n );
+-	int  eLen = BN_num_bytes( a_pRsa->e );
++	const BIGNUM *bn;
++	const BIGNUM *be;
++
++	RSA_get0_key( a_pRsa, &bn, &be, NULL );
++
++	int  nLen = BN_num_bytes( bn );
++	int  eLen = BN_num_bytes( be );
+ 
+ 	CK_RV  rv;
+ 
+@@ -732,8 +737,8 @@ createRsaPubKeyObject( RSA
+ 	}
+ 
+ 	// Get binary representations of the RSA key information
+-	BN_bn2bin( a_pRsa->n, n );
+-	BN_bn2bin( a_pRsa->e, e );
++	BN_bn2bin( bn, n );
++	BN_bn2bin( be, e );
+ 
+ 	// Create the RSA public key object
+ 	rv = createObject( a_hSession, tAttr, ulAttrCount, a_hObject );
+@@ -760,14 +765,27 @@ createRsaPrivKeyObject( RSA
+ 
+ 	int  rc = -1;
+ 
+-	int  nLen = BN_num_bytes( a_pRsa->n );
+-	int  eLen = BN_num_bytes( a_pRsa->e );
+-	int  dLen = BN_num_bytes( a_pRsa->d );
+-	int  pLen = BN_num_bytes( a_pRsa->p );
+-	int  qLen = BN_num_bytes( a_pRsa->q );
+-	int  dmp1Len = BN_num_bytes( a_pRsa->dmp1 );
+-	int  dmq1Len = BN_num_bytes( a_pRsa->dmq1 );
+-	int  iqmpLen = BN_num_bytes( a_pRsa->iqmp );
++	const BIGNUM *bn;
++	const BIGNUM *be;
++	const BIGNUM *bd;
++	const BIGNUM *bp;
++	const BIGNUM *bq;
++	const BIGNUM *bdmp1;
++	const BIGNUM *bdmq1;
++	const BIGNUM *biqmp;
++
++	RSA_get0_key( a_pRsa, &bn, &be, &bd);
++	RSA_get0_factors( a_pRsa, &bp, &bq);
++	RSA_get0_crt_params( a_pRsa, &bdmp1, &bdmq1, &biqmp );
++
++	int  nLen = BN_num_bytes( bn );
++	int  eLen = BN_num_bytes( be );
++	int  dLen = BN_num_bytes( bd );
++	int  pLen = BN_num_bytes( bp );
++	int  qLen = BN_num_bytes( bq );
++	int  dmp1Len = BN_num_bytes( bdmp1 );
++	int  dmq1Len = BN_num_bytes( bdmq1 );
++	int  iqmpLen = BN_num_bytes( biqmp );
+ 
+ 	CK_RV  rv;
+ 
+@@ -821,14 +839,14 @@ createRsaPrivKeyObject( RSA
+ 	}
+ 
+ 	// Get binary representations of the RSA key information
+-	BN_bn2bin( a_pRsa->n, n );
+-	BN_bn2bin( a_pRsa->e, e );
+-	BN_bn2bin( a_pRsa->d, d );
+-	BN_bn2bin( a_pRsa->p, p );
+-	BN_bn2bin( a_pRsa->q, q );
+-	BN_bn2bin( a_pRsa->dmp1, dmp1 );
+-	BN_bn2bin( a_pRsa->dmq1, dmq1 );
+-	BN_bn2bin( a_pRsa->iqmp, iqmp );
++	BN_bn2bin( bn, n );
++	BN_bn2bin( be, e );
++	BN_bn2bin( bd, d );
++	BN_bn2bin( bp, p );
++	BN_bn2bin( bq, q );
++	BN_bn2bin( bdmp1, dmp1 );
++	BN_bn2bin( bdmq1, dmq1 );
++	BN_bn2bin( biqmp, iqmp );
+ 
+ 	// Create the RSA private key object
+ 	rv = createObject( a_hSession, tAttr, ulAttrCount, a_hObject );
diff --git a/meta-security/meta-tpm/recipes-tpm/tpm-tools/files/openssl1.1_fix.patch b/meta-security/meta-tpm/recipes-tpm/tpm-tools/files/openssl1.1_fix.patch
new file mode 100644
index 0000000..9ae3f72
--- /dev/null
+++ b/meta-security/meta-tpm/recipes-tpm/tpm-tools/files/openssl1.1_fix.patch
@@ -0,0 +1,18 @@
+Upstream-Status: Pending
+Update to build with openssl 1.1.x
+
+Signed-off-by: Armin Kuster <akuster808@gmail.com>
+
+Index: git/src/cmds/tpm_extendpcr.c
+===================================================================
+--- git.orig/src/cmds/tpm_extendpcr.c
++++ git/src/cmds/tpm_extendpcr.c
+@@ -136,7 +136,7 @@ int main(int argc, char **argv)
+ 
+ 		unsigned char msg[EVP_MAX_MD_SIZE];
+ 		unsigned int msglen;
+-		EVP_MD_CTX ctx;
++		EVP_MD_CTX *ctx = EVP_MD_CTX_new();
+ 		EVP_DigestInit(&ctx, EVP_sha1());
+ 		while ((lineLen = BIO_read(bin, line, sizeof(line))) > 0)
+ 			EVP_DigestUpdate(&ctx, line, lineLen);
diff --git a/meta-security/meta-tpm/recipes-tpm/tpm-tools/files/tpm-tools-extendpcr.patch b/meta-security/meta-tpm/recipes-tpm/tpm-tools/files/tpm-tools-extendpcr.patch
index ab5e683..40150af 100644
--- a/meta-security/meta-tpm/recipes-tpm/tpm-tools/files/tpm-tools-extendpcr.patch
+++ b/meta-security/meta-tpm/recipes-tpm/tpm-tools/files/tpm-tools-extendpcr.patch
@@ -1,8 +1,8 @@
-Index: tpm-tools-1.3.8/include/tpm_tspi.h
+Index: git/include/tpm_tspi.h
 ===================================================================
---- tpm-tools-1.3.8.orig/include/tpm_tspi.h	2011-08-17 08:20:35.000000000 -0400
-+++ tpm-tools-1.3.8/include/tpm_tspi.h	2013-01-05 23:26:31.571598217 -0500
-@@ -117,6 +117,10 @@
+--- git.orig/include/tpm_tspi.h
++++ git/include/tpm_tspi.h
+@@ -117,6 +117,10 @@ TSS_RESULT tpmPcrRead(TSS_HTPM a_hTpm, U
  			UINT32 *a_PcrSize, BYTE **a_PcrValue);
  TSS_RESULT pcrcompositeSetPcrValue(TSS_HPCRS a_hPcrs, UINT32 a_Idx,
  					UINT32 a_PcrSize, BYTE *a_PcrValue);
@@ -13,11 +13,11 @@
  #ifdef TSS_LIB_IS_12
  TSS_RESULT unloadVersionInfo(UINT64 *offset, BYTE *blob, TPM_CAP_VERSION_INFO *v);
  TSS_RESULT pcrcompositeSetPcrLocality(TSS_HPCRS a_hPcrs, UINT32 localityValue);
-Index: tpm-tools-1.3.8/lib/tpm_tspi.c
+Index: git/lib/tpm_tspi.c
 ===================================================================
---- tpm-tools-1.3.8.orig/lib/tpm_tspi.c	2011-08-17 08:20:35.000000000 -0400
-+++ tpm-tools-1.3.8/lib/tpm_tspi.c	2013-01-05 23:27:37.731593490 -0500
-@@ -594,6 +594,20 @@
+--- git.orig/lib/tpm_tspi.c
++++ git/lib/tpm_tspi.c
+@@ -594,6 +594,20 @@ pcrcompositeSetPcrValue(TSS_HPCRS a_hPcr
  	return result;
  }
  
@@ -38,10 +38,10 @@
  #ifdef TSS_LIB_IS_12
  /*
   * These getPasswd functions will wrap calls to the other functions and check to see if the TSS
-Index: tpm-tools-1.3.8/src/cmds/Makefile.am
+Index: git/src/cmds/Makefile.am
 ===================================================================
---- tpm-tools-1.3.8.orig/src/cmds/Makefile.am	2011-08-15 13:52:08.000000000 -0400
-+++ tpm-tools-1.3.8/src/cmds/Makefile.am	2013-01-05 23:30:46.223593698 -0500
+--- git.orig/src/cmds/Makefile.am
++++ git/src/cmds/Makefile.am
 @@ -22,6 +22,7 @@
  #
  
@@ -50,16 +50,16 @@
  			tpm_unsealdata
  
  if TSS_LIB_IS_12
-@@ -33,4 +34,5 @@
- LDADD		=	$(top_builddir)/lib/libtpm_tspi.la -ltspi $(top_builddir)/lib/libtpm_unseal.la -ltpm_unseal -lcrypto
+@@ -33,4 +34,5 @@ endif
+ LDADD		=	$(top_builddir)/lib/libtpm_tspi.la -ltspi $(top_builddir)/lib/libtpm_unseal.la -ltpm_unseal -lcrypto @INTLLIBS@
  
  tpm_sealdata_SOURCES = tpm_sealdata.c
 +tpm_extendpcr_SOURCES = tpm_extendpcr.c
  tpm_unsealdata_SOURCES = tpm_unsealdata.c
-Index: tpm-tools-1.3.8/src/cmds/tpm_extendpcr.c
+Index: git/src/cmds/tpm_extendpcr.c
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ tpm-tools-1.3.8/src/cmds/tpm_extendpcr.c	2013-01-05 23:37:43.403585514 -0500
+--- /dev/null
++++ git/src/cmds/tpm_extendpcr.c
 @@ -0,0 +1,181 @@
 +/*
 + * The Initial Developer of the Original Code is International
diff --git a/meta-security/meta-tpm/recipes-tpm/tpm-tools/tpm-tools_1.3.9.1.bb b/meta-security/meta-tpm/recipes-tpm/tpm-tools/tpm-tools_1.3.9.1.bb
new file mode 100644
index 0000000..88ef19f
--- /dev/null
+++ b/meta-security/meta-tpm/recipes-tpm/tpm-tools/tpm-tools_1.3.9.1.bb
@@ -0,0 +1,36 @@
+SUMMARY = "The tpm-tools package contains commands to allow the platform administrator the ability to manage and diagnose the platform's TPM."
+DESCRIPTION = " \
+  The tpm-tools package contains commands to allow the platform administrator \
+  the ability to manage and diagnose the platform's TPM.  Additionally, the \
+  package contains commands to utilize some of the capabilities available \
+  in the TPM PKCS#11 interface implemented in the openCryptoki project. \
+  "
+SECTION = "tpm"
+LICENSE = "CPL-1.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=059e8cd6165cb4c31e351f2b69388fd9"
+
+DEPENDS = "libtspi openssl"
+DEPENDS_class-native = "trousers-native"
+
+SRCREV = "bdf9f1bc8f63cd6fc370c2deb58d03ac55079e84"
+SRC_URI = " \
+	git://git.code.sf.net/p/trousers/tpm-tools \
+	file://tpm-tools-extendpcr.patch \
+	file://04-fix-FTBFS-clang.patch \
+	file://05-openssl1.1_fix_data_mgmt.patch \
+        file://openssl1.1_fix.patch \
+	"
+
+inherit autotools-brokensep gettext
+
+S = "${WORKDIR}/git"
+
+do_configure_prepend () {
+	mkdir -p po
+	mkdir -p m4
+	cp -R po_/* po/
+	touch po/Makefile.in.in
+	touch m4/Makefile.am
+}
+
+BBCLASSEXTEND = "native"
diff --git a/meta-security/meta-tpm/recipes-tpm/tpm-tools/tpm-tools_git.bb b/meta-security/meta-tpm/recipes-tpm/tpm-tools/tpm-tools_git.bb
deleted file mode 100644
index f670bff..0000000
--- a/meta-security/meta-tpm/recipes-tpm/tpm-tools/tpm-tools_git.bb
+++ /dev/null
@@ -1,35 +0,0 @@
-SUMMARY = "The tpm-tools package contains commands to allow the platform administrator the ability to manage and diagnose the platform's TPM."
-DESCRIPTION = " \
-  The tpm-tools package contains commands to allow the platform administrator \
-  the ability to manage and diagnose the platform's TPM.  Additionally, the \
-  package contains commands to utilize some of the capabilities available \
-  in the TPM PKCS#11 interface implemented in the openCryptoki project. \
-  "
-SECTION = "tpm"
-LICENSE = "CPL-1.0"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=059e8cd6165cb4c31e351f2b69388fd9"
-
-DEPENDS = "libtspi openssl"
-DEPENDS_class-native = "trousers-native"
-
-SRCREV = "5c5126bedf2da97906358adcfb8c43c86e7dd0ee"
-SRC_URI = " \
-	git://git.code.sf.net/p/trousers/tpm-tools \
-	file://tpm-tools-extendpcr.patch \
-	"
-
-PV = "1.3.9.1+git${SRCPV}"
-
-inherit autotools-brokensep gettext
-
-S = "${WORKDIR}/git"
-
-do_configure_prepend () {
-	mkdir -p po
-	mkdir -p m4
-	cp -R po_/* po/
-	touch po/Makefile.in.in
-	touch m4/Makefile.am
-}
-
-BBCLASSEXTEND = "native"
diff --git a/meta-security/meta-tpm/recipes-tpm/tpm2-abrmd/tpm2-abrmd_1.2.0.bb b/meta-security/meta-tpm/recipes-tpm/tpm2-abrmd/tpm2-abrmd_1.2.0.bb
deleted file mode 100644
index a5d6843..0000000
--- a/meta-security/meta-tpm/recipes-tpm/tpm2-abrmd/tpm2-abrmd_1.2.0.bb
+++ /dev/null
@@ -1,54 +0,0 @@
-SUMMARY = "TPM2 Access Broker & Resource Manager"
-DESCRIPTION = "This is a system daemon implementing the TPM2 access \
-broker (TAB) & Resource Manager (RM) spec from the TCG. The daemon (tpm2-abrmd) \
-is implemented using Glib and the GObject system. In this documentation and \
-in the code we use `tpm2-abrmd` and `tabrmd` interchangeably. \
-"
-SECTION = "security/tpm"
-
-LICENSE = "BSD-2-Clause"
-LIC_FILES_CHKSUM = "file://${S}/LICENSE;md5=500b2e742befc3da00684d8a1d5fd9da"
-
-DEPENDS += "autoconf-archive dbus glib-2.0 pkgconfig tpm2.0-tss glib-2.0-native"
-
-SRC_URI = "\
-    git://github.com/01org/tpm2-abrmd.git \
-    file://tpm2-abrmd-init.sh \
-    file://tpm2-abrmd.default \
-"
-SRCREV = "59ce1008e5fa3bd5a143437b0f7390851fd25bd8"
-
-S = "${WORKDIR}/git"
-
-inherit autotools pkgconfig systemd update-rc.d useradd
-
-SYSTEMD_PACKAGES += "${PN}"
-SYSTEMD_SERVICE_${PN} = "tpm2-abrmd.service"
-SYSTEMD_AUTO_ENABLE_${PN} = "disable"
-
-INITSCRIPT_NAME = "${PN}"
-INITSCRIPT_PARAMS = "start 99 2 3 4 5 . stop 19 0 1 6 ."
-
-USERADD_PACKAGES = "${PN}"
-GROUPADD_PARAM_${PN} = "tss"
-USERADD_PARAM_${PN} = "--system -M -d /var/lib/tpm -s /bin/false -g tss tss"
-
-PACKAGECONFIG ?="udev"
-PACKAGECONFIG += "${@bb.utils.contains('DISTRO_FEATURES','systemd','systemd', '', d)}"
-
-PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_system_unitdir}, --with-systemdsystemunitdir=no"
-PACKAGECONFIG[udev] = "--with-udevrulesdir=${sysconfdir}/udev/rules.d, --without-udevrulesdir"
-
-do_install_append() {
-    install -d "${D}${sysconfdir}/init.d"
-    install -m 0755 "${WORKDIR}/tpm2-abrmd-init.sh" "${D}${sysconfdir}/init.d/tpm2-abrmd"
-
-    install -d "${D}${sysconfdir}/default"
-    install -m 0644 "${WORKDIR}/tpm2-abrmd.default" "${D}${sysconfdir}/default/tpm2-abrmd"
-}
-
-FILES_${PN} += "${libdir}/systemd/system-preset"
-
-RDEPENDS_${PN} += "libgcc dbus-glib libtss2 libtctidevice libtctisocket"
-
-BBCLASSEXTEND = "native"
diff --git a/meta-security/meta-tpm/recipes-tpm/tpm2-abrmd/tpm2-abrmd_2.0.2.bb b/meta-security/meta-tpm/recipes-tpm/tpm2-abrmd/tpm2-abrmd_2.0.2.bb
new file mode 100644
index 0000000..6347379
--- /dev/null
+++ b/meta-security/meta-tpm/recipes-tpm/tpm2-abrmd/tpm2-abrmd_2.0.2.bb
@@ -0,0 +1,54 @@
+SUMMARY = "TPM2 Access Broker & Resource Manager"
+DESCRIPTION = "This is a system daemon implementing the TPM2 access \
+broker (TAB) & Resource Manager (RM) spec from the TCG. The daemon (tpm2-abrmd) \
+is implemented using Glib and the GObject system. In this documentation and \
+in the code we use `tpm2-abrmd` and `tabrmd` interchangeably. \
+"
+SECTION = "security/tpm"
+
+LICENSE = "BSD-2-Clause"
+LIC_FILES_CHKSUM = "file://${S}/LICENSE;md5=500b2e742befc3da00684d8a1d5fd9da"
+
+DEPENDS = "autoconf-archive dbus glib-2.0 tpm2.0-tss glib-2.0-native \
+            libtss2 libtss2-mu libtss2-tcti-device libtss2-tcti-mssim"
+
+
+SRC_URI = "\
+    git://github.com/01org/tpm2-abrmd.git \
+    file://tpm2-abrmd-init.sh \
+    file://tpm2-abrmd.default \
+"
+SRCREV = "d0120ace58d97bc9520c0d558657eaca87ae73b1"
+
+S = "${WORKDIR}/git"
+
+inherit autotools pkgconfig systemd update-rc.d useradd
+
+SYSTEMD_PACKAGES += "${PN}"
+SYSTEMD_SERVICE_${PN} = "tpm2-abrmd.service"
+SYSTEMD_AUTO_ENABLE_${PN} = "disable"
+
+INITSCRIPT_NAME = "${PN}"
+INITSCRIPT_PARAMS = "start 99 2 3 4 5 . stop 19 0 1 6 ."
+
+USERADD_PACKAGES = "${PN}"
+GROUPADD_PARAM_${PN} = "tss"
+USERADD_PARAM_${PN} = "--system -M -d /var/lib/tpm -s /bin/false -g tss tss"
+
+PACKAGECONFIG ?="${@bb.utils.contains('DISTRO_FEATURES','systemd','systemd', '', d)}"
+PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_system_unitdir}, --with-systemdsystemunitdir=no"
+
+do_install_append() {
+    install -d "${D}${sysconfdir}/init.d"
+    install -m 0755 "${WORKDIR}/tpm2-abrmd-init.sh" "${D}${sysconfdir}/init.d/tpm2-abrmd"
+
+    install -d "${D}${sysconfdir}/default"
+    install -m 0644 "${WORKDIR}/tpm2-abrmd.default" "${D}${sysconfdir}/default/tpm2-abrmd"
+}
+
+FILES_${PN} += "${libdir}/systemd/system-preset \
+		${datadir}/dbus-1"
+
+RDEPENDS_${PN} += "tpm2.0-tss"
+
+BBCLASSEXTEND = "native"
diff --git a/meta-security/meta-tpm/recipes-tpm/tpm2.0-tools/tpm2.0-tools_3.1.2.bb b/meta-security/meta-tpm/recipes-tpm/tpm2.0-tools/tpm2.0-tools_3.1.2.bb
new file mode 100644
index 0000000..3f40eb7
--- /dev/null
+++ b/meta-security/meta-tpm/recipes-tpm/tpm2.0-tools/tpm2.0-tools_3.1.2.bb
@@ -0,0 +1,15 @@
+SUMMARY = "Tools for TPM2."
+DESCRIPTION = "tpm2.0-tools"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=91b7c548d73ea16537799e8060cea819"
+SECTION = "tpm"
+
+DEPENDS = "pkgconfig tpm2.0-tss openssl curl autoconf-archive"
+
+SRCREV = "5e2f1aafc58e60c5050f85147a14914561f28ad9"
+
+SRC_URI = "git://github.com/01org/tpm2.0-tools.git;name=tpm2.0-tools;destsuffix=tpm2.0-tools;branch=3.X"
+
+S = "${WORKDIR}/tpm2.0-tools"
+
+inherit autotools pkgconfig
diff --git a/meta-security/meta-tpm/recipes-tpm/tpm2.0-tools/tpm2.0-tools_git.bb b/meta-security/meta-tpm/recipes-tpm/tpm2.0-tools/tpm2.0-tools_git.bb
deleted file mode 100644
index 7ec12fc..0000000
--- a/meta-security/meta-tpm/recipes-tpm/tpm2.0-tools/tpm2.0-tools_git.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-SUMMARY = "Tools for TPM2."
-DESCRIPTION = "tpm2.0-tools"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=91b7c548d73ea16537799e8060cea819"
-SECTION = "tpm"
-
-DEPENDS = "pkgconfig tpm2.0-tss openssl curl autoconf-archive"
-
-# July 10, 2017
-SRCREV = "26c0557040c1cf8107fa3ebbcf2a5b07cc84b881"
-
-SRC_URI = "git://github.com/01org/tpm2.0-tools.git;name=tpm2.0-tools;destsuffix=tpm2.0-tools"
-
-S = "${WORKDIR}/tpm2.0-tools"
-
-PV = "2.0.0+git${SRCPV}"
-
-inherit autotools pkgconfig
diff --git a/meta-security/meta-tpm/recipes-tpm/tpm2.0-tss/tpm2.0-tss_1.3.0.bb b/meta-security/meta-tpm/recipes-tpm/tpm2.0-tss/tpm2.0-tss_1.3.0.bb
deleted file mode 100644
index b673c2b..0000000
--- a/meta-security/meta-tpm/recipes-tpm/tpm2.0-tss/tpm2.0-tss_1.3.0.bb
+++ /dev/null
@@ -1,99 +0,0 @@
-SUMMARY = "Software stack for TPM2."
-DESCRIPTION = "tpm2.0-tss like woah."
-LICENSE = "BSD-2-Clause"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=500b2e742befc3da00684d8a1d5fd9da"
-SECTION = "tpm"
-
-DEPENDS = "autoconf-archive pkgconfig"
-
-SRCREV = "b1d9ece8c6bea2e3043943b2edfaebcdca330c38"
-
-SRC_URI = " \
-    git://github.com/tpm2-software/tpm2-tss.git;branch=1.x \
-    file://ax_pthread.m4 \
-"
-
-inherit autotools pkgconfig systemd
-
-S = "${WORKDIR}/git"
-
-do_configure_prepend () {
-	mkdir -p ${S}/m4
-	cp ${WORKDIR}/ax_pthread.m4 ${S}/m4
-	# execute the bootstrap script
-	currentdir=$(pwd)
-	cd ${S}
-	ACLOCAL="aclocal --system-acdir=${STAGING_DATADIR}/aclocal" ./bootstrap
-	cd $currentdir
-}
-
-INHERIT += "extrausers"
-EXTRA_USERS_PARAMS = "\
-	useradd -p '' tss; \
-	groupadd tss; \
-	"
-
-SYSTEMD_PACKAGES = "resourcemgr"
-SYSTEMD_SERVICE_resourcemgr = "resourcemgr.service"
-SYSTEMD_AUTO_ENABLE_resourcemgr = "enable"
-
-do_patch[postfuncs] += "${@bb.utils.contains('VIRTUAL-RUNTIME_init_manager','systemd','fix_systemd_unit','', d)}"
-fix_systemd_unit () {
-    sed -i -e 's;^ExecStart=.*/resourcemgr;ExecStart=${sbindir}/resourcemgr;' ${S}/contrib/resourcemgr.service
-}
-
-do_install_append() {
-    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
-        install -d ${D}${systemd_system_unitdir}
-        install -m0644 ${S}/contrib/resourcemgr.service ${D}${systemd_system_unitdir}/resourcemgr.service
-    fi
-}
-
-PROVIDES = "${PACKAGES}"
-PACKAGES = " \
-    ${PN}-dbg \
-    ${PN}-doc \
-    libtss2 \
-    libtss2-dev \
-    libtss2-staticdev \
-    libtctidevice \
-    libtctidevice-dev \
-    libtctidevice-staticdev \
-    libtctisocket \
-    libtctisocket-dev \
-    libtctisocket-staticdev \
-    resourcemgr \
-"
-
-FILES_libtss2 = " \
-	${libdir}/libsapi.so.0.0.0 \
-	${libdir}/libmarshal.so.0.0.0 \
-"
-FILES_libtss2-dev = " \
-    ${includedir}/sapi \
-    ${includedir}/tcti/common.h \
-    ${libdir}/libsapi.so* \
-    ${libdir}/libmarshal.so* \
-    ${libdir}/pkgconfig/sapi.pc \
-"
-FILES_libtss2-staticdev = " \
-    ${libdir}/libsapi.a \
-    ${libdir}/libsapi.la \
-    ${libdir}/libmarshal.a \
-    ${libdir}/libmarshal.la \
-"
-FILES_libtctidevice = "${libdir}/libtcti-device.so.0.0.0"
-FILES_libtctidevice-dev = " \
-    ${includedir}/tcti/tcti_device.h \
-    ${libdir}/libtcti-device.so* \
-    ${libdir}/pkgconfig/tcti-device.pc \
-"
-FILES_libtctidevice-staticdev = "${libdir}/libtcti-device.*a"
-FILES_libtctisocket = "${libdir}/libtcti-socket.so.0.0.0"
-FILES_libtctisocket-dev = " \
-    ${includedir}/tcti/tcti_socket.h \
-    ${libdir}/libtcti-socket.so* \
-    ${libdir}/pkgconfig/tcti-socket.pc \
-"
-FILES_libtctisocket-staticdev = "${libdir}/libtcti-socket.*a"
-FILES_resourcemgr = "${sbindir}/resourcemgr ${systemd_system_unitdir}/resourcemgr.service"
diff --git a/meta-security/meta-tpm/recipes-tpm/tpm2.0-tss/tpm2.0-tss_2.0.1.bb b/meta-security/meta-tpm/recipes-tpm/tpm2.0-tss/tpm2.0-tss_2.0.1.bb
new file mode 100644
index 0000000..9d1ff72
--- /dev/null
+++ b/meta-security/meta-tpm/recipes-tpm/tpm2.0-tss/tpm2.0-tss_2.0.1.bb
@@ -0,0 +1,74 @@
+SUMMARY = "Software stack for TPM2."
+DESCRIPTION = "tpm2.0-tss like woah."
+LICENSE = "BSD-2-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=0b1d631c4218b72f6b05cb58613606f4"
+SECTION = "tpm"
+
+DEPENDS = "autoconf-archive-native libgcrypt"
+
+SRCREV = "dc31e8dca9dbc77d16e419dc514ce8c526cd3351"
+
+SRC_URI = "git://github.com/tpm2-software/tpm2-tss.git;branch=2.0.x"
+
+inherit autotools-brokensep pkgconfig systemd
+
+S = "${WORKDIR}/git"
+
+do_configure_prepend () {
+       ./bootstrap
+}
+
+INHERIT += "extrausers"
+EXTRA_USERS_PARAMS = "\
+	useradd -p '' tss; \
+	groupadd tss; \
+	"
+
+PROVIDES = "${PACKAGES}"
+PACKAGES = " \
+    ${PN} \
+    ${PN}-dbg \
+    ${PN}-doc \
+    libtss2-mu \
+    libtss2-mu-dev \
+    libtss2-mu-staticdev \
+    libtss2-tcti-device \
+    libtss2-tcti-device-dev \
+    libtss2-tcti-device-staticdev \
+    libtss2-tcti-mssim \
+    libtss2-tcti-mssim-dev \
+    libtss2-tcti-mssim-staticdev \
+    libtss2 \
+    libtss2-dev \
+    libtss2-staticdev \
+"
+
+FILES_libtss2-tcti-device = "${libdir}/libtss2-tcti-device.so.*"
+FILES_libtss2-tcti-device-dev = " \
+    ${includedir}/tss2/tss2_tcti_device.h \
+    ${libdir}/pkgconfig/tss2-tcti-device.pc \
+    ${libdir}/libtss2-tcti-device.so"
+FILES_libtss2-tcti-device-staticdev = "${libdir}/libtss2-tcti-device.*a"
+
+FILES_libtss2-tcti-mssim = "${libdir}/libtss2-tcti-mssim.so.*"
+FILES_libtss2-tcti-mssim-dev = " \
+    ${includedir}/tss2/tss2_tcti_mssim.h \
+    ${libdir}/pkgconfig/tss2-tcti-mssim.pc \
+    ${libdir}/libtss2-tcti-mssim.so"
+FILES_libtss2-tcti-mssim-staticdev = "${libdir}/libtss2-tcti-mssim.*a"
+
+FILES_libtss2-mu = "${libdir}/libtss2-mu.so.*"
+FILES_libtss2-mu-dev = " \
+    ${includedir}/tss2/tss2_mu.h \
+    ${libdir}/pkgconfig/tss2-mu.pc \
+    ${libdir}/libtss2-mu.so"
+FILES_libtss2-mu-staticdev = "${libdir}/libtss2-mu.*a"
+
+FILES_libtss2 = "${libdir}/libtss2*so.*"
+FILES_libtss2-dev = " \
+    ${includedir} \
+    ${libdir}/pkgconfig \
+    ${libdir}/libtss2*so"
+FILES_libtss2-staticdev = "${libdir}/libtss*a"
+
+FILES_${PN} = "${libdir}/udev"
diff --git a/meta-security/meta-tpm/recipes-tpm/tpm2simulator/tpm2simulator-native_138.bb b/meta-security/meta-tpm/recipes-tpm/tpm2simulator/tpm2simulator_138.bb
similarity index 100%
rename from meta-security/meta-tpm/recipes-tpm/tpm2simulator/tpm2simulator-native_138.bb
rename to meta-security/meta-tpm/recipes-tpm/tpm2simulator/tpm2simulator_138.bb
diff --git a/meta-security/recipes-browers/tor/tor_6.5.2.bb b/meta-security/recipes-browers/tor/tor_6.5.2.bb
deleted file mode 100644
index 1e3a812..0000000
--- a/meta-security/recipes-browers/tor/tor_6.5.2.bb
+++ /dev/null
@@ -1,7 +0,0 @@
-SUMMARY = "Tor is free software and an open network that helps you defend against traffic analysis, a form of network surveillance that threatens personal freedom and privacy, confidential business activities and relationships, and state security."
-
-HOMEPAGE = "https://www.torproject.org/"
-
-LICENSE = "GPV-v2"
-
-SRC_URI = "https://github.com/TheTorProject/gettorbrowser/archive/v6.5.2.tar.gz"
diff --git a/meta-security/recipes-forensic/afflib/afflib_3.6.6.bb b/meta-security/recipes-forensic/afflib/afflib_3.6.6.bb
deleted file mode 100644
index a826d1d..0000000
--- a/meta-security/recipes-forensic/afflib/afflib_3.6.6.bb
+++ /dev/null
@@ -1,30 +0,0 @@
-SUMMARY = "The Advanced Forensic Format (AFF) is on-disk format for storing computer forensic information."
-HOMEPAGE = "http://www.afflib.org/"
-LICENSE = " BSD-4-Clause  & CPL-1.0"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d1b2c6d0d6908f45d143ef6380727828"
-
-DEPENDS = " zlib ncurses readline openssl libgcrypt"
-
-SRC_URI = "http://archive.ubuntu.com/ubuntu/pool/universe/a/${BPN}/${BPN}_${PV}.orig.tar.gz;name=orig \
-        http://archive.ubuntu.com/ubuntu/pool/universe/a/${BPN}/${BPN}_${PV}-1.1.diff.gz;name=dpatch \
-        file://configure_rm_ms_flags.patch \
-        "
-
-SRC_URI[orig.md5sum] = "b7ff4d2945882018eb1536cad182ad01"
-SRC_URI[orig.sha256sum] = "19cacfd558dc00e11975e820e3c4383b52aabbd5ca081d27bb7994a035d2f4ad"
-SRC_URI[dpatch.md5sum] = "171e871024545b487589e6c85290576f"
-SRC_URI[dpatch.sha256sum] = "db632e254ee51a1e4328cd4449d414eff4795053d4e36bfa8e0020fcb4085cdd"
-
-inherit autotools-brokensep pkgconfig
-
-CPPFLAGS = "-I${STAGING_INCDIR}"
-LDFLAGS = "-L${STAGING_LIBDIR}"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[curl] = "--with-curl=${STAGING_LIBDIR}, --without-curl, curl"
-PACKAGECONFIG[expat] = "--with-expat=${STAGING_LIBDIR}, --without-expat, expat"
-PACKAGECONFIG[fuse] = "--enable-fuse=yes, --enable-fuse=no, fuse"
-PACKAGECONFIG[python] = "--enable-python=yes, --enable-python=no, python"
-
-EXTRA_OECONF += "--enable-s3=no CPPFLAGS=-I${STAGING_INCDIR} LDFLAGS=-L${STAGING_LIBDIR}"
-EXTRA_OEMAKE += "CPPFLAGS='${CPPFLAGS}' LDFLAGS='-L${STAGING_LIBDIR} -I${STAGING_INCDIR}'"
diff --git a/meta-security/recipes-forensic/afflib/files/configure_rm_ms_flags.patch b/meta-security/recipes-forensic/afflib/files/configure_rm_ms_flags.patch
deleted file mode 100644
index ac33500..0000000
--- a/meta-security/recipes-forensic/afflib/files/configure_rm_ms_flags.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-Upstream-Status: Inappropriate [configuration]
-
-remove ms lib options when cross compiling
-
-Signed-Off-By: Armin Kuster <akuster808@gmail.com>
-
-Index: configure.ac
-===================================================================
---- a.orig/configure.ac
-+++ a/configure.ac
-@@ -47,7 +47,6 @@ if test x"${cross_compiling}" = "xno" ;
-   AC_MSG_NOTICE([ LDFLAGS = ${LDFLAGS} ])
- else
-   AC_MSG_NOTICE([Cross Compiling --- will not update CPPFALGS or LDFLAGS with /usr/local, /opt/local or /sw])
--  LIBS="$LIBS -lws2_32 -lgdi32"
- fi
- 
- if test -r /bin/uname.exe ; then
diff --git a/meta-security/recipes-forensic/libewf/files/gcc5_fix.patch b/meta-security/recipes-forensic/libewf/files/gcc5_fix.patch
deleted file mode 100644
index 0881f25..0000000
--- a/meta-security/recipes-forensic/libewf/files/gcc5_fix.patch
+++ /dev/null
@@ -1,22 +0,0 @@
-Upstream Status: pending
-
-Don't use inline with gcc 5.0
-
-fixes:
-undefined reference to `libuna_unicode_character_size_to_utf8'
-
-Signed-off-by: Armin Kuster <akuster808@gmail.com>
-
-Index: libuna/libuna_inline.h
-===================================================================
---- a/libuna/libuna_inline.h
-+++ b/libuna/libuna_inline.h
-@@ -27,7 +27,7 @@
- #if defined( _MSC_VER )
- #define LIBUNA_INLINE _inline
- 
--#elif defined( __BORLANDC__ ) || defined( __clang__ )
-+#elif defined( __BORLANDC__ ) || defined( __clang__ ) || ( __GNUC__ > 4 )
- #define LIBUNA_INLINE /* inline */
- 
- #else
diff --git a/meta-security/recipes-forensic/libewf/libewf_20140608.bb b/meta-security/recipes-forensic/libewf/libewf_20140608.bb
deleted file mode 100644
index f7dce12..0000000
--- a/meta-security/recipes-forensic/libewf/libewf_20140608.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-SUMMARY = "library with support for Expert Witness Compression Format"
-LICENSE = "LGPLv3+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=58c39b26c0549f8e1bb4122173f474cd"
-
-DEPENDS = "virtual/gettext libtool"
-
-SRC_URI = "http://archive.ubuntu.com/ubuntu/pool/universe/libe/${BPN}/${BPN}_${PV}.orig.tar.gz;name=orig \
-        file://gcc5_fix.patch \
-        "
-SRC_URI[orig.md5sum] = "fdf615f23937fad8e02b60b9e3e5fb35"
-SRC_URI[orig.sha256sum] = "d14030ce6122727935fbd676d0876808da1e112721f3cb108564a4d9bf73da71"
-
-inherit autotools-brokensep pkgconfig gettext
-
-PACKAGECONFIG ??= "zlib ssl bz2"
-PACKAGECONFIG[zlib] = "--with-zlib, --without-zlib, zlib, zlib"
-PACKAGECONFIG[bz2] = "--with-bzip2, --without-bzip2, bzip2, bzip2"
-PACKAGECONFIG[ssl] = "--with-openssl, --without-openssl, openssl, openssl"
-PACKAGECONFIG[fuse] = "--with-libfuse, --without-libfuse, fuse"
-PACKAGECONFIG[python] = "--enable-python, --disable-python, python"
-
-EXTRA_OECONF += "--with-gnu-ld --disable-rpath"
-
-RDEPENDS_${PN} += " util-linux-libuuid"
diff --git a/meta-security/recipes-forensic/sleuth/files/fix_host_poison.patch b/meta-security/recipes-forensic/sleuth/files/fix_host_poison.patch
deleted file mode 100644
index 03b1fb9..0000000
--- a/meta-security/recipes-forensic/sleuth/files/fix_host_poison.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-Upstream-Status: Inappropriate [configuration]
-
-Don't use host include or lib paths in *FLAGS
-
-Signed-off-by: Armin Kuster <akuster808@gmail.com>
-
-Index: configure.ac
-===================================================================
---- a/configure.ac
-+++ b/configure.ac
-@@ -84,12 +84,6 @@ AX_PTHREAD([
-     LDFLAGS="$LDFLAGS $PTHREAD_CFLAGS"
-     CC="$PTHREAD_CC"],[])
- 
--dnl Not all compilers include /usr/local in the include and link path
--if test -d /usr/local/include; then
--    CPPFLAGS="$CPPFLAGS -I/usr/local/include"
--    LDFLAGS="$LDFLAGS -L/usr/local/lib"
--fi
--
- dnl Add enable/disable option
- AC_ARG_ENABLE([java],
-     [AS_HELP_STRING([--disable-java], [Do not build the java bindings or jar file])])
diff --git a/meta-security/recipes-forensic/sleuth/sleuthkit_4.1.3.bb b/meta-security/recipes-forensic/sleuth/sleuthkit_4.1.3.bb
deleted file mode 100644
index ba335f3..0000000
--- a/meta-security/recipes-forensic/sleuth/sleuthkit_4.1.3.bb
+++ /dev/null
@@ -1,31 +0,0 @@
-SUMMARY = "The Sleuth Kit (TSK) is a library and collection of command line tools that allow you to investigate disk images."
-HOMEPAGE = "http://www.sleuthkit.org/sleuthkit/"
-LICENSE = "IPL-1.0 & GPLv2 & CPL-1.0"
-LIC_FILES_CHKSUM = "file://licenses/GNU-COPYING;startline=4;endline=5;md5=475b4784903850b579dc6e6310bd5f08\
-    file://licenses/IBM-LICENSE;startline=1;endline=2;md5=1fc3300388b0d6e6216825dd89c2e3a2\
-    file://licenses/cpl1.0.txt;startline=1;endline=2;md5=9e58c878202c73a4e3ed4be72598fb92"
-
-DEPENDS = "libtool"
-
-SRC_URI = "http://archive.ubuntu.com/ubuntu/pool/universe/s/${BPN}/${BPN}_${PV}.orig.tar.gz;name=orig \
-            file://fix_host_poison.patch \
-        "
-SRC_URI[orig.md5sum] = "139a12f06952d8a40bbe07884994cf5d"
-SRC_URI[orig.sha256sum] = "67f9d2a31a8884d58698d6122fc1a1bfa9bf238582bde2b49228ec9b899f0327"
-
-inherit autotools-brokensep pkgconfig gettext
-
-PACKAGECONFIG ??= "aff zlib ewf"
-PACKAGECONFIG[aff] = "--with-afflib=${STAGING_DIR_HOST}/usr, --without-afflib, afflib"
-PACKAGECONFIG[zlib] = "--with-zlib=${STAGING_DIR_HOST}/usr, --without-zlib, zlib"
-PACKAGECONFIG[ewf] = "--with-libewf=${STAGING_DIR_HOST}/usr, --without-libewf, libewf"
-
-#--with-gnu-ld
-EXTRA_OECONF += "--enable-static=no --disable-java LIBS='-L${STAGING_LIBDIR}' LDFLAGS='-L${STAGING_LIBDIR}' CPPFLAGS='-I${STAGING_INCDIR}'"
-
-# Avoid QA Issue: No GNU_HASH in the elf binary
-INSANE_SKIP_${PN} = "ldflags" 
-
-FILES_${PN} += " ${datadir}/tsk"
-
-RDEPENDS_${PN} += " perl"
diff --git a/meta-security/recipes-security/AppArmor/apparmor_2.11.0.bb b/meta-security/recipes-security/AppArmor/apparmor_2.11.0.bb
deleted file mode 100644
index fc9b614..0000000
--- a/meta-security/recipes-security/AppArmor/apparmor_2.11.0.bb
+++ /dev/null
@@ -1,159 +0,0 @@
-SUMMARY = "AppArmor another MAC control system"
-DESCRIPTION = "user-space parser utility for AppArmor \
- This provides the system initialization scripts needed to use the \
- AppArmor Mandatory Access Control system, including the AppArmor Parser \
- which is required to convert AppArmor text profiles into machine-readable \
- policies that are loaded into the kernel for use with the AppArmor Linux \
- Security Module."
-HOMEAPAGE = "http://apparmor.net/"
-SECTION = "admin"
-
-LICENSE = "GPLv2 & GPLv2+ & BSD-3-Clause & LGPLv2.1+"
-LIC_FILES_CHKSUM = "file://${S}/LICENSE;md5=fd57a4b0bc782d7b80fd431f10bbf9d0"
-
-DEPENDS = "bison-native apr gettext-native coreutils-native"
-
-SRC_URI = " \
-	http://archive.ubuntu.com/ubuntu/pool/main/a/${BPN}/${BPN}_${PV}.orig.tar.gz \
-	file://disable_perl_h_check.patch \
-	file://crosscompile_perl_bindings.patch \
-	file://apparmor.rc \
-	file://functions \
-	file://apparmor \
-	file://apparmor.service \
-        file://run-ptest \
-	"
-
-SRC_URI[md5sum] = "899fd834dc5c8ebf2d52b97e4a174af7"
-SRC_URI[sha256sum] = "b1c489ea11e7771b8e6b181532cafbf9ebe6603e3cb00e2558f21b7a5bdd739a"
-
-PARALLEL_MAKE = ""
-
-inherit pkgconfig autotools-brokensep update-rc.d python3native perlnative ptest cpan
-inherit ${@bb.utils.contains('VIRTUAL-RUNTIME_init_manager','systemd','systemd','', d)}
-
-S = "${WORKDIR}/apparmor-${PV}"
-
-PACKAGECONFIG ?="man python perl"
-PACKAGECONFIG[man] = "--enable-man-pages, --disable-man-pages"
-PACKAGECONFIG[python] = "--with-python, --without-python, python3 swig-native"
-PACKAGECONFIG[perl] = "--with-perl, --without-perl, perl perl-native swig-native"
-PACKAGECONFIG[apache2] = ",,apache2,"
-
-PAMLIB="${@bb.utils.contains('DISTRO_FEATURES', 'pam', '1', '0', d)}"
-HTTPD="${@bb.utils.contains('PACKAGECONFIG', 'apache2', '1', '0', d)}"
-
-
-python() {
-    if 'apache2' in d.getVar('PACKAGECONFIG').split() and \
-	'webserver' not in d.getVar('BBFILE_COLLECTIONS').split():
-        raise bb.parse.SkipRecipe('Requires meta-webserver to be present.')
-}
-
-CONFIGUREOPTS_remove = "--disable-static"
-EXTRA_OECONF_append = " --enable-static"
-
-do_configure() {
-	cd ${S}/libraries/libapparmor
-	aclocal
-	autoconf --force
-	libtoolize --automake -c --force
-	automake -ac
-	./configure ${CONFIGUREOPTS} ${EXTRA_OECONF}
-	sed -i -e 's#^YACC.*#YACC := bison#' ${S}/parser/Makefile
-	sed -i -e 's#^LEX.*#LEX := flex#' ${S}/parser/Makefile
-}
-
-do_compile () {
-	oe_runmake -C ${B}/libraries/libapparmor
-        oe_runmake -C ${B}/binutils
-        oe_runmake -C ${B}/utils
-        oe_runmake -C ${B}/parser
-        oe_runmake -C ${B}/profiles
-
-	if test -z "${HTTPD}" ; then
-        	oe_runmake -C ${B}/changehat/mod_apparmor
-	fi	
-
-	if test -z "${PAMLIB}" ; then
-        	oe_runmake -C ${B}/changehat/pam_apparmor
-	fi
-}
-
-do_install () {
-	install -d ${D}/${INIT_D_DIR}
-	install -d ${D}/lib/apparmor
-		
-	oe_runmake -C ${B}/libraries/libapparmor DESTDIR="${D}" install
-	oe_runmake -C ${B}/binutils DESTDIR="${D}" install
-	oe_runmake -C ${B}/utils DESTDIR="${D}" install
-	oe_runmake -C ${B}/parser DESTDIR="${D}" install
-	oe_runmake -C ${B}/profiles DESTDIR="${D}" install
-
-	if test -z "${HTTPD}" ; then
-		oe_runmake -C ${B}/changehat/mod_apparmor DESTDIR="${D}" install
-	fi
-
-	if test -z "${PAMLIB}" ; then
-		oe_runmake -C ${B}/changehat/pam_apparmor DESTDIR="${D}" install
-	fi
-
-	# aa-easyprof is installed by python-tools-setup.py, fix it up
-	sed -i -e 's:/usr/bin/env.*:/usr/bin/python3:' ${D}${bindir}/aa-easyprof
-	chmod 0755 ${D}${bindir}/aa-easyprof
-
-	install ${WORKDIR}/apparmor ${D}/${INIT_D_DIR}/apparmor
-	install ${WORKDIR}/functions ${D}/lib/apparmor
-	if [ "${VIRTUAL-RUNTIME_init_manager}" = "systemd" ]; then
-		install -d ${D}${systemd_system_unitdir}
-		install ${WORKDIR}/apparmor.service \
-			${D}${systemd_system_unitdir}
-	fi
-}
-
-do_compile_ptest () {
-        oe_runmake -C ${B}/tests/regression/apparmor
-        oe_runmake -C ${B}/parser/tst
-        oe_runmake -C ${B}/libraries/libapparmor
-}
-
-do_install_ptest () {
-	t=${D}/${PTEST_PATH}/testsuite
-	install -d ${t}
-	install -d ${t}/tests/regression/apparmor
-	cp -rf ${B}/tests/regression/apparmor ${t}/tests/regression
-
-	install -d ${t}/parser/tst
-	cp -rf ${B}/parser/tst ${t}/parser
-	cp ${B}/parser/apparmor_parser ${t}/parser
-	cp ${B}/parser/frob_slack_rc ${t}/parser
-
-	install -d ${t}/libraries/libapparmor
-	cp -rf ${B}/libraries/libapparmor ${t}/libraries
-
-	install -d ${t}/common
-	cp -rf ${B}/common ${t}
-
-	install -d ${t}/binutils
-	cp -rf ${B}/binutils ${t}
-}
-
-INITSCRIPT_PACKAGES = "${PN}"
-INITSCRIPT_NAME = "apparmor"
-INITSCRIPT_PARAMS = "start 16 2 3 4 5 . stop 35 0 1 6 ."
-
-SYSTEMD_PACKAGES = "${PN}"
-SYSTEMD_SERVICE_${PN} = "apparmor.service"
-SYSTEMD_AUTO_ENABLE = "disable"
-
-PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'apache2', 'mod-${PN}', '', d)}"
-
-FILES_${PN} += "/lib/apparmor/ ${sysconfdir}/apparmor ${PYTHON_SITEPACKAGES_DIR}"
-FILES_mod-${PN} = "${libdir}/apache2/modules/*"
-
-ALLOW_EMPTY_${PN} = "1"
-
-RDEPENDS_${PN} += "bash lsb"
-RDEPENDS_${PN} += "${@bb.utils.contains('PACKAGECONFIG','python','python3 python3-modules','', d)}"
-RDEPENDS_${PN}_remove += "${@bb.utils.contains('PACKAGECONFIG','perl','','perl', d)}"
-RDEPENDS_${PN}-ptest += "perl coreutils dbus-lib"
diff --git a/meta-security/recipes-security/AppArmor/apparmor_2.12.bb b/meta-security/recipes-security/AppArmor/apparmor_2.12.bb
new file mode 100644
index 0000000..e3f8dc9
--- /dev/null
+++ b/meta-security/recipes-security/AppArmor/apparmor_2.12.bb
@@ -0,0 +1,159 @@
+SUMMARY = "AppArmor another MAC control system"
+DESCRIPTION = "user-space parser utility for AppArmor \
+ This provides the system initialization scripts needed to use the \
+ AppArmor Mandatory Access Control system, including the AppArmor Parser \
+ which is required to convert AppArmor text profiles into machine-readable \
+ policies that are loaded into the kernel for use with the AppArmor Linux \
+ Security Module."
+HOMEAPAGE = "http://apparmor.net/"
+SECTION = "admin"
+
+LICENSE = "GPLv2 & GPLv2+ & BSD-3-Clause & LGPLv2.1+"
+LIC_FILES_CHKSUM = "file://${S}/LICENSE;md5=fd57a4b0bc782d7b80fd431f10bbf9d0"
+
+DEPENDS = "bison-native apr gettext-native coreutils-native"
+
+SRC_URI = " \
+	http://archive.ubuntu.com/ubuntu/pool/main/a/${BPN}/${BPN}_${PV}.orig.tar.gz \
+	file://disable_perl_h_check.patch \
+	file://crosscompile_perl_bindings.patch \
+	file://apparmor.rc \
+	file://functions \
+	file://apparmor \
+	file://apparmor.service \
+	file://run-ptest \
+	"
+
+SRC_URI[md5sum] = "49054f58042f8e51ea92cc866575a833"
+SRC_URI[sha256sum] = "8a2b0cd083faa4d0640f579024be3a629faa7db3b99540798a1a050e2eaba056"
+
+PARALLEL_MAKE = ""
+
+inherit pkgconfig autotools-brokensep update-rc.d python3native perlnative ptest cpan
+inherit ${@bb.utils.contains('VIRTUAL-RUNTIME_init_manager','systemd','systemd','', d)}
+
+S = "${WORKDIR}/apparmor-${PV}"
+
+PACKAGECONFIG ?="man python perl"
+PACKAGECONFIG[man] = "--enable-man-pages, --disable-man-pages"
+PACKAGECONFIG[python] = "--with-python, --without-python, python3 swig-native"
+PACKAGECONFIG[perl] = "--with-perl, --without-perl, perl perl-native swig-native"
+PACKAGECONFIG[apache2] = ",,apache2,"
+
+PAMLIB="${@bb.utils.contains('DISTRO_FEATURES', 'pam', '1', '0', d)}"
+HTTPD="${@bb.utils.contains('PACKAGECONFIG', 'apache2', '1', '0', d)}"
+
+
+python() {
+    if 'apache2' in d.getVar('PACKAGECONFIG').split() and \
+            'webserver' not in d.getVar('BBFILE_COLLECTIONS').split():
+        raise bb.parse.SkipRecipe('Requires meta-webserver to be present.')
+}
+
+CONFIGUREOPTS_remove = "--disable-static"
+EXTRA_OECONF_append = " --enable-static"
+
+do_configure() {
+	cd ${S}/libraries/libapparmor
+	aclocal
+	autoconf --force
+	libtoolize --automake -c --force
+	automake -ac
+	./configure ${CONFIGUREOPTS} ${EXTRA_OECONF}
+	sed -i -e 's#^YACC.*#YACC := bison#' ${S}/parser/Makefile
+	sed -i -e 's#^LEX.*#LEX := flex#' ${S}/parser/Makefile
+}
+
+do_compile () {
+	oe_runmake -C ${B}/libraries/libapparmor
+        oe_runmake -C ${B}/binutils
+        oe_runmake -C ${B}/utils
+        oe_runmake -C ${B}/parser
+        oe_runmake -C ${B}/profiles
+
+	if test -z "${HTTPD}" ; then
+        	oe_runmake -C ${B}/changehat/mod_apparmor
+	fi	
+
+	if test -z "${PAMLIB}" ; then
+        	oe_runmake -C ${B}/changehat/pam_apparmor
+	fi
+}
+
+do_install () {
+	install -d ${D}/${INIT_D_DIR}
+	install -d ${D}/lib/apparmor
+		
+	oe_runmake -C ${B}/libraries/libapparmor DESTDIR="${D}" install
+	oe_runmake -C ${B}/binutils DESTDIR="${D}" install
+	oe_runmake -C ${B}/utils DESTDIR="${D}" install
+	oe_runmake -C ${B}/parser DESTDIR="${D}" install
+	oe_runmake -C ${B}/profiles DESTDIR="${D}" install
+
+	if test -z "${HTTPD}" ; then
+		oe_runmake -C ${B}/changehat/mod_apparmor DESTDIR="${D}" install
+	fi
+
+	if test -z "${PAMLIB}" ; then
+		oe_runmake -C ${B}/changehat/pam_apparmor DESTDIR="${D}" install
+	fi
+
+	# aa-easyprof is installed by python-tools-setup.py, fix it up
+	sed -i -e 's:/usr/bin/env.*:/usr/bin/python3:' ${D}${bindir}/aa-easyprof
+	chmod 0755 ${D}${bindir}/aa-easyprof
+
+	install ${WORKDIR}/apparmor ${D}/${INIT_D_DIR}/apparmor
+	install ${WORKDIR}/functions ${D}/lib/apparmor
+	if [ "${VIRTUAL-RUNTIME_init_manager}" = "systemd" ]; then
+		install -d ${D}${systemd_system_unitdir}
+		install ${WORKDIR}/apparmor.service \
+			${D}${systemd_system_unitdir}
+	fi
+}
+
+do_compile_ptest () {
+        oe_runmake -C ${B}/tests/regression/apparmor
+        oe_runmake -C ${B}/parser/tst
+        oe_runmake -C ${B}/libraries/libapparmor
+}
+
+do_install_ptest () {
+	t=${D}/${PTEST_PATH}/testsuite
+	install -d ${t}
+	install -d ${t}/tests/regression/apparmor
+	cp -rf ${B}/tests/regression/apparmor ${t}/tests/regression
+
+	install -d ${t}/parser/tst
+	cp -rf ${B}/parser/tst ${t}/parser
+	cp ${B}/parser/apparmor_parser ${t}/parser
+	cp ${B}/parser/frob_slack_rc ${t}/parser
+
+	install -d ${t}/libraries/libapparmor
+	cp -rf ${B}/libraries/libapparmor ${t}/libraries
+
+	install -d ${t}/common
+	cp -rf ${B}/common ${t}
+
+	install -d ${t}/binutils
+	cp -rf ${B}/binutils ${t}
+}
+
+INITSCRIPT_PACKAGES = "${PN}"
+INITSCRIPT_NAME = "apparmor"
+INITSCRIPT_PARAMS = "start 16 2 3 4 5 . stop 35 0 1 6 ."
+
+SYSTEMD_PACKAGES = "${PN}"
+SYSTEMD_SERVICE_${PN} = "apparmor.service"
+SYSTEMD_AUTO_ENABLE = "disable"
+
+PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'apache2', 'mod-${PN}', '', d)}"
+
+FILES_${PN} += "/lib/apparmor/ ${sysconfdir}/apparmor ${PYTHON_SITEPACKAGES_DIR}"
+FILES_mod-${PN} = "${libdir}/apache2/modules/*"
+
+ALLOW_EMPTY_${PN} = "1"
+
+RDEPENDS_${PN} += "bash lsb"
+RDEPENDS_${PN} += "${@bb.utils.contains('PACKAGECONFIG','python','python3 python3-modules','', d)}"
+RDEPENDS_${PN}_remove += "${@bb.utils.contains('PACKAGECONFIG','perl','','perl', d)}"
+RDEPENDS_${PN}-ptest += "perl coreutils dbus-lib"
diff --git a/meta-security/recipes-security/aircrack-ng/aircrack-ng_1.2.bb b/meta-security/recipes-security/aircrack-ng/aircrack-ng_1.2.bb
deleted file mode 100644
index 4df072e..0000000
--- a/meta-security/recipes-security/aircrack-ng/aircrack-ng_1.2.bb
+++ /dev/null
@@ -1,37 +0,0 @@
-SUMMARY = "Aircrack-ng is a set of tools for auditing wireless networks"
-DESCRIPTION = "Aircrack-ng is an 802.11 WEP and WPA-PSK keys cracking program that can recover keys once enough data packets have been captured. It implements the standard FMS attack along with some optimizations like KoreK attacks, as well as the PTW attack, thus making the attack much faster compared to other WEP cracking tools."
-SECTION = "security"
-LICENSE = "GPL-2.0"
-
-LIC_FILES_CHKSUM = "file://LICENSE;beginline=1;endline=2;md5=1fbd81241fe252ec0f5658a521ab7dd8"
-
-DEPENDS = "libnl openssl sqlite3 libpcre libpcap"
-RC = "rc2"
-SRC_URI = "http://download.aircrack-ng.org/${BP}-${RC}.tar.gz \
-            file://fixup_cflags.patch"
-
-SRC_URI[md5sum] = "ebe9d537f06f4d6956213af09c4476da"
-SRC_URI[sha256sum] = "ba5b3eda44254efc5b7c9f776eb756f7cc323ad5d0813c101e92edb483d157e9"
-
-inherit autotools-brokensep pkgconfig
-
-S = "${WORKDIR}/${BP}-rc2"
-
-PACKAGECONFIG ?= ""
-CFLAGS += " -I${S}/src/include"
-
-OEMAKE_EXTRA = "sqlite=true experimental=true pcre=true \
-                prefix=${prefix} \
-                "
-
-do_compile () {
-    make ${OEMAKE_EXTRA} TOOL_PREFIX=${TARGET_SYS}-
-}
-
-do_install () {
-    make DESTDIR=${D} ${OEMAKE_EXTRA} ext_scripts=true install
-}
-
-FILES_${PN} += "/usr/local/"
-
-RDEPENDS_${PN} = "libpcap"
diff --git a/meta-security/recipes-security/aircrack-ng/aircrack-ng_1.3.bb b/meta-security/recipes-security/aircrack-ng/aircrack-ng_1.3.bb
new file mode 100644
index 0000000..d739227
--- /dev/null
+++ b/meta-security/recipes-security/aircrack-ng/aircrack-ng_1.3.bb
@@ -0,0 +1,34 @@
+SUMMARY = "Aircrack-ng is a set of tools for auditing wireless networks"
+DESCRIPTION = "Aircrack-ng is an 802.11 WEP and WPA-PSK keys cracking program that can recover keys once enough data packets have been captured. It implements the standard FMS attack along with some optimizations like KoreK attacks, as well as the PTW attack, thus making the attack much faster compared to other WEP cracking tools."
+SECTION = "security"
+LICENSE = "GPL-2.0"
+
+LIC_FILES_CHKSUM = "file://LICENSE;beginline=1;endline=2;md5=1fbd81241fe252ec0f5658a521ab7dd8"
+
+DEPENDS = "libnl openssl sqlite3 libpcre libpcap"
+
+SRC_URI = "http://download.aircrack-ng.org/${BP}.tar.gz"
+
+SRC_URI[md5sum] = "c7c5b076dee0c25ee580b0f56f455623"
+SRC_URI[sha256sum] = "8ae08a7c28741f6ace2769267112053366550e7f746477081188ad38410383ca"
+
+inherit autotools-brokensep pkgconfig
+
+PACKAGECONFIG ?= ""
+CFLAGS += " -I${S}/src/include"
+
+OEMAKE_EXTRA = "sqlite=true experimental=true pcre=true \
+                prefix=${prefix} \
+                "
+
+do_compile () {
+    make ${OEMAKE_EXTRA} TOOL_PREFIX=${TARGET_SYS}-
+}
+
+do_install () {
+    make DESTDIR=${D} ${OEMAKE_EXTRA} ext_scripts=true install
+}
+
+FILES_${PN} += "/usr/local/"
+
+RDEPENDS_${PN} = "libpcap"
diff --git a/meta-security/recipes-security/aircrack-ng/files/fixup_cflags.patch b/meta-security/recipes-security/aircrack-ng/files/fixup_cflags.patch
deleted file mode 100644
index e13dd24..0000000
--- a/meta-security/recipes-security/aircrack-ng/files/fixup_cflags.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-Upstream Status: Iinappropriate
-
-Issues do to build env.
-
-Signed-off-by: Armin Kuster <akuster808@gmail.com>
-
-Index: aircrack-ng-1.2-rc2/src/Makefile
-===================================================================
---- aircrack-ng-1.2-rc2.orig/src/Makefile
-+++ aircrack-ng-1.2-rc2/src/Makefile
-@@ -3,8 +3,6 @@ include $(AC_ROOT)/common.mak
- 
- TEST_DIR	= $(AC_ROOT)/test
- 
--CFLAGS		+= -Iinclude
--
- iCC             = $(shell find /opt/intel/cc/*/bin/icc)
- iCFLAGS         = -w -mcpu=pentiumpro -march=pentiumpro $(COMMON_CFLAGS)
- iOPTFLAGS       = -O3 -ip -ipo -D_FILE_OFFSET_BITS=64
-@@ -102,7 +100,7 @@ endif
- 
- 
- ifeq ($(subst TRUE,true,$(filter TRUE true,$(sqlite) $(SQLITE))),true)
--	LIBSQL		= -L/usr/local/lib -lsqlite3
-+	LIBSQL		= -lsqlite3
- else
- 	LIBSQL		=
- endif
diff --git a/meta-security/recipes-security/bastille/bastille_3.2.1.bb b/meta-security/recipes-security/bastille/bastille_3.2.1.bb
index eee1a38..152c03a 100644
--- a/meta-security/recipes-security/bastille/bastille_3.2.1.bb
+++ b/meta-security/recipes-security/bastille/bastille_3.2.1.bb
@@ -9,7 +9,7 @@
 RDEPENDS_${PN} = "perl bash tcl perl-module-getopt-long perl-module-text-wrap lib-perl perl-module-file-path perl-module-mime-base64 perl-module-file-find perl-module-errno perl-module-file-glob perl-module-tie-hash-namedcapture perl-module-file-copy perl-module-english perl-module-exporter perl-module-cwd libcurses-perl coreutils"
 FILES_${PN} += "/run/lock/subsys/bastille"
 
-inherit allarch module-base
+inherit module-base
 
 SRC_URI = "http://sourceforge.net/projects/bastille-linux/files/bastille-linux/3.2.1/Bastille-3.2.1.tar.bz2 \
            file://AccountPermission.pm \
diff --git a/meta-security/recipes-security/clamav/clamav_0.99.3.bb b/meta-security/recipes-security/clamav/clamav_0.99.3.bb
deleted file mode 100644
index 688250d..0000000
--- a/meta-security/recipes-security/clamav/clamav_0.99.3.bb
+++ /dev/null
@@ -1,158 +0,0 @@
-SUMMARY = "ClamAV anti-virus utility for Unix - command-line interface"
-DESCRIPTION = "ClamAV is an open source antivirus engine for detecting trojans, viruses, malware & other malicious threats."
-HOMEPAGE = "http://www.clamav.net/index.html"
-SECTION = "security"
-LICENSE = "LGPL-2.1"
-
-DEPENDS = "libtool db libmspack chrpath-replacement-native"
-
-LIC_FILES_CHKSUM = "file://COPYING.LGPL;beginline=2;endline=3;md5=4b89c05acc71195e9a06edfa2fa7d092"
-
-SRCREV = "224f73461a44e278e9fa50ba59f51ee5e64373e0"
-
-SRC_URI = "git://github.com/vrtadmin/clamav-devel;branch=rel/0.99 \
-    file://clamd.conf \
-    file://freshclam.conf \
-    file://volatiles.03_clamav \
-    file://${BPN}.service \
-    "
-
-S = "${WORKDIR}/git"
-
-LEAD_SONAME = "libclamav.so"
-SO_VER = "7.1.1"
-
-EXTRANATIVEPATH += "chrpath-native"
-
-inherit autotools-brokensep pkgconfig useradd systemd
-
-UID = "clamav"
-GID = "clamav"
-
-# Clamav has a built llvm version 2 but does not build with gcc 6.x,
-# disable the internal one. This is a known issue
-# If you want LLVM support, use meta-oe llvm3.3 to build for GCC 6.X,
-# as defined below
-
-CLAMAV_LLVM ?= "oellvm"
-CLAMAV_LLVM_RELEASE ?= "6.0"
-
-PACKAGECONFIG ?= "ncurses openssl bz2 zlib ${CLAMAV_LLVM}"
-PACKAGECONFIG += " ${@bb.utils.contains("DISTRO_FEATURES", "ipv6", "ipv6", "", d)}"
-PACKAGECONFIG += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', '', d)}"
-
-PACKAGECONFIG[oellvm] = "--with-system-llvm --with-llvm-linking=dynamic --disable-llvm, ,llvm${CLAMAV_LLVM_RELEASE}"
-
-PACKAGECONFIG[pcre] = "--with-pcre=${STAGING_LIBDIR},  --without-pcre, libpcre"
-PACKAGECONFIG[xml] = "--with-xml=${STAGING_LIBDIR}/.., --with-xml=no, libxml2,"
-PACKAGECONFIG[json] = "--with-libjson=${STAGING_LIBDIR}, --without-libjson, json,"
-PACKAGECONFIG[curl] = "--with-libcurl=${STAGING_LIBDIR}, --without-libcurl, curl,"
-PACKAGECONFIG[ipv6] = "--enable-ipv6, --disable-ipv6"
-PACKAGECONFIG[openssl] = "--with-openssl=${STAGING_DIR_HOST}/usr, --without-openssl, openssl, openssl"
-PACKAGECONFIG[zlib] = "--with-zlib=${STAGING_DIR_HOST}/usr --disable-zlib-vcheck , --without-zlib, zlib, "
-PACKAGECONFIG[bz2] = "--with-libbz2-prefix=${STAGING_LIBDIR}/.., --without-libbz2-prefix, "
-PACKAGECONFIG[ncurses] = "--with-libncurses-prefix=${STAGING_LIBDIR}/.., --without-libncurses-prefix, ncurses, "
-PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/, --without-systemdsystemunitdir, "
-
-EXTRA_OECONF += " --with-user=${UID}  --with-group=${GID} \
-            --without-libcheck-prefix --disable-unrar \
-            --disable-mempool \
-            --program-prefix="" \
-            --disable-yara \
-            --disable-rpath \
-            "
-
-do_configure () {
-    cd ${S}
-    ./configure ${CONFIGUREOPTS} ${EXTRA_OECONF} 
-}
-
-do_compile_append() {
-    # brute force removing RPATH
-    chrpath -d  ${B}/libclamav/.libs/libclamav.so.${SO_VER}
-    chrpath -d  ${B}/sigtool/.libs/sigtool
-    chrpath -d  ${B}/clambc/.libs/clambc
-    chrpath -d  ${B}/clamscan/.libs/clamscan
-    chrpath -d  ${B}/clamconf/.libs/clamconf
-    chrpath -d  ${B}/clamd/.libs/clamd
-    chrpath -d  ${B}/freshclam/.libs/freshclam
-}
-
-do_install_append() {
-    install -d ${D}/${sysconfdir}
-    install -d ${D}/${localstatedir}/lib/clamav
-    install -d ${D}${sysconfdir}/clamav ${D}${sysconfdir}/default/volatiles
-
-    install -m 644 ${WORKDIR}/clamd.conf ${D}/${sysconfdir}
-    install -m 644 ${WORKDIR}/freshclam.conf ${D}/${sysconfdir}
-    install -m 0644 ${WORKDIR}/volatiles.03_clamav  ${D}${sysconfdir}/default/volatiles/volatiles.03_clamav
-    sed -i -e 's#${STAGING_DIR_HOST}##g' ${D}${libdir}/pkgconfig/libclamav.pc
-    rm ${D}/${libdir}/libclamav.so
-    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)};then
-        install -D -m 0644 ${WORKDIR}/clamav.service ${D}${systemd_unitdir}/system/clamav.service
-    fi
-}
-
-pkg_postinst_ontarget_${PN} () {
-    if [ -e /etc/init.d/populate-volatile.sh ] ; then
-        ${sysconfdir}/init.d/populate-volatile.sh update
-    fi
-    chown ${UID}:${GID} ${localstatedir}/lib/clamav
-}
-
-
-PACKAGES = "${PN} ${PN}-dev ${PN}-dbg ${PN}-daemon ${PN}-doc \
-            ${PN}-clamdscan ${PN}-freshclam ${PN}-libclamav ${PN}-staticdev"
-
-FILES_${PN} = "${bindir}/clambc ${bindir}/clamscan ${bindir}/clamsubmit \
-                ${bindir}/*sigtool ${mandir}/man1/clambc* ${mandir}/man1/clamscan* \
-                ${mandir}/man1/sigtool* ${mandir}/man1/clambsubmit*  \
-                ${docdir}/clamav/* "
-
-FILES_${PN}-clamdscan = " ${bindir}/clamdscan \
-                        ${docdir}/clamdscan/* \
-                        ${mandir}/man1/clamdscan* \
-                        "
-
-FILES_${PN}-daemon = "${bindir}/clamconf ${bindir}/clamdtop ${sbindir}/clamd \
-                        ${mandir}/man1/clamconf* ${mandir}/man1/clamdtop* \
-                        ${mandir}/man5/clamd*  ${mandir}/man8/clamd* \
-                        ${sysconfdir}/clamd.conf* \
-                        ${systemd_unitdir}/system/clamav-daemon/* \
-                        ${docdir}/clamav-daemon/*  ${sysconfdir}/clamav-daemon \
-                        ${sysconfdir}/logcheck/ignore.d.server/clamav-daemon "
-
-FILES_${PN}-freshclam = "${bindir}/freshclam \
-                        ${sysconfdir}/freshclam.conf*  \
-                        ${sysconfdir}/clamav ${sysconfdir}/default/volatiles \
-                        ${localstatedir}/lib/clamav \
-                        ${docdir}/${PN}-freshclam ${mandir}/man1/freshclam.* \
-                        ${mandir}/man5/freshclam.conf.* \
-                        ${systemd_unitdir}/system/clamav-freshclam.service"
-
-FILES_${PN}-dev = " ${bindir}/clamav-config ${libdir}/*.la \
-                    ${libdir}/pkgconfig/*.pc \
-                    ${mandir}/man1/clamav-config.* \
-                    ${includedir}/*.h ${docdir}/libclamav* "
-
-FILES_${PN}-staticdev = "${libdir}/*.a"
-
-FILES_${PN}-libclamav = "${libdir}/libclamav.so* ${libdir}/libmspack.so*\
-                          ${docdir}/libclamav/* "
-
-FILES_${PN}-doc = "${mandir}/man/* \
-                   ${datadir}/man/* \
-                   ${docdir}/* "
-
-USERADD_PACKAGES = "${PN}"
-GROUPADD_PARAM_${PN} = "--system ${UID}"
-USERADD_PARAM_${PN} = "--system -g ${GID} --home-dir  \
-    ${localstatedir}/spool/${BPN} \
-    --no-create-home  --shell /bin/false ${BPN}"
-
-RPROVIDES_${PN} += "${PN}-systemd"
-RREPLACES_${PN} += "${PN}-systemd"
-RCONFLICTS_${PN} += "${PN}-systemd"
-SYSTEMD_SERVICE_${PN} = "${BPN}.service"
-
-RDEPENDS_${PN} += "openssl ncurses-libncurses libbz2 ncurses-libtinfo clamav-freshclam clamav-libclamav"
diff --git a/meta-security/recipes-security/clamav/clamav_0.99.4.bb b/meta-security/recipes-security/clamav/clamav_0.99.4.bb
new file mode 100644
index 0000000..8c2c2fa
--- /dev/null
+++ b/meta-security/recipes-security/clamav/clamav_0.99.4.bb
@@ -0,0 +1,158 @@
+SUMMARY = "ClamAV anti-virus utility for Unix - command-line interface"
+DESCRIPTION = "ClamAV is an open source antivirus engine for detecting trojans, viruses, malware & other malicious threats."
+HOMEPAGE = "http://www.clamav.net/index.html"
+SECTION = "security"
+LICENSE = "LGPL-2.1"
+
+DEPENDS = "libtool db libmspack chrpath-replacement-native"
+
+LIC_FILES_CHKSUM = "file://COPYING.LGPL;beginline=2;endline=3;md5=4b89c05acc71195e9a06edfa2fa7d092"
+
+SRCREV = "b66e5e27b48c0a07494f9df9b809ed933cede047"
+
+SRC_URI = "git://github.com/vrtadmin/clamav-devel;branch=rel/0.99 \
+    file://clamd.conf \
+    file://freshclam.conf \
+    file://volatiles.03_clamav \
+    file://${BPN}.service \
+    "
+
+S = "${WORKDIR}/git"
+
+LEAD_SONAME = "libclamav.so"
+SO_VER = "7.1.1"
+
+EXTRANATIVEPATH += "chrpath-native"
+
+inherit autotools-brokensep pkgconfig useradd systemd
+
+UID = "clamav"
+GID = "clamav"
+
+# Clamav has a built llvm version 2 but does not build with gcc 6.x,
+# disable the internal one. This is a known issue
+# If you want LLVM support, use meta-oe llvm3.3 to build for GCC 6.X,
+# as defined below
+
+CLAMAV_LLVM ?= "oellvm"
+CLAMAV_LLVM_RELEASE ?= "6.0"
+
+PACKAGECONFIG ?= "ncurses openssl bz2 zlib ${CLAMAV_LLVM}"
+PACKAGECONFIG += " ${@bb.utils.contains("DISTRO_FEATURES", "ipv6", "ipv6", "", d)}"
+PACKAGECONFIG += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', '', d)}"
+
+PACKAGECONFIG[oellvm] = "--with-system-llvm --with-llvm-linking=dynamic --disable-llvm, ,llvm${CLAMAV_LLVM_RELEASE}"
+
+PACKAGECONFIG[pcre] = "--with-pcre=${STAGING_LIBDIR},  --without-pcre, libpcre"
+PACKAGECONFIG[xml] = "--with-xml=${STAGING_LIBDIR}/.., --with-xml=no, libxml2,"
+PACKAGECONFIG[json] = "--with-libjson=${STAGING_LIBDIR}, --without-libjson, json,"
+PACKAGECONFIG[curl] = "--with-libcurl=${STAGING_LIBDIR}, --without-libcurl, curl,"
+PACKAGECONFIG[ipv6] = "--enable-ipv6, --disable-ipv6"
+PACKAGECONFIG[openssl] = "--with-openssl=${STAGING_DIR_HOST}/usr, --without-openssl, openssl, openssl"
+PACKAGECONFIG[zlib] = "--with-zlib=${STAGING_DIR_HOST}/usr --disable-zlib-vcheck , --without-zlib, zlib, "
+PACKAGECONFIG[bz2] = "--with-libbz2-prefix=${STAGING_LIBDIR}/.., --without-libbz2-prefix, "
+PACKAGECONFIG[ncurses] = "--with-libncurses-prefix=${STAGING_LIBDIR}/.., --without-libncurses-prefix, ncurses, "
+PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/, --without-systemdsystemunitdir, "
+
+EXTRA_OECONF += " --with-user=${UID}  --with-group=${GID} \
+            --without-libcheck-prefix --disable-unrar \
+            --disable-mempool \
+            --program-prefix="" \
+            --disable-yara \
+            --disable-rpath \
+            "
+
+do_configure () {
+    cd ${S}
+    ./configure ${CONFIGUREOPTS} ${EXTRA_OECONF} 
+}
+
+do_compile_append() {
+    # brute force removing RPATH
+    chrpath -d  ${B}/libclamav/.libs/libclamav.so.${SO_VER}
+    chrpath -d  ${B}/sigtool/.libs/sigtool
+    chrpath -d  ${B}/clambc/.libs/clambc
+    chrpath -d  ${B}/clamscan/.libs/clamscan
+    chrpath -d  ${B}/clamconf/.libs/clamconf
+    chrpath -d  ${B}/clamd/.libs/clamd
+    chrpath -d  ${B}/freshclam/.libs/freshclam
+}
+
+do_install_append() {
+    install -d ${D}/${sysconfdir}
+    install -d ${D}/${localstatedir}/lib/clamav
+    install -d ${D}${sysconfdir}/clamav ${D}${sysconfdir}/default/volatiles
+
+    install -m 644 ${WORKDIR}/clamd.conf ${D}/${sysconfdir}
+    install -m 644 ${WORKDIR}/freshclam.conf ${D}/${sysconfdir}
+    install -m 0644 ${WORKDIR}/volatiles.03_clamav  ${D}${sysconfdir}/default/volatiles/volatiles.03_clamav
+    sed -i -e 's#${STAGING_DIR_HOST}##g' ${D}${libdir}/pkgconfig/libclamav.pc
+    rm ${D}/${libdir}/libclamav.so
+    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)};then
+        install -D -m 0644 ${WORKDIR}/clamav.service ${D}${systemd_unitdir}/system/clamav.service
+    fi
+}
+
+pkg_postinst_ontarget_${PN} () {
+    if [ -e /etc/init.d/populate-volatile.sh ] ; then
+        ${sysconfdir}/init.d/populate-volatile.sh update
+    fi
+    chown ${UID}:${GID} ${localstatedir}/lib/clamav
+}
+
+
+PACKAGES = "${PN} ${PN}-dev ${PN}-dbg ${PN}-daemon ${PN}-doc \
+            ${PN}-clamdscan ${PN}-freshclam ${PN}-libclamav ${PN}-staticdev"
+
+FILES_${PN} = "${bindir}/clambc ${bindir}/clamscan ${bindir}/clamsubmit \
+                ${bindir}/*sigtool ${mandir}/man1/clambc* ${mandir}/man1/clamscan* \
+                ${mandir}/man1/sigtool* ${mandir}/man1/clambsubmit*  \
+                ${docdir}/clamav/* "
+
+FILES_${PN}-clamdscan = " ${bindir}/clamdscan \
+                        ${docdir}/clamdscan/* \
+                        ${mandir}/man1/clamdscan* \
+                        "
+
+FILES_${PN}-daemon = "${bindir}/clamconf ${bindir}/clamdtop ${sbindir}/clamd \
+                        ${mandir}/man1/clamconf* ${mandir}/man1/clamdtop* \
+                        ${mandir}/man5/clamd*  ${mandir}/man8/clamd* \
+                        ${sysconfdir}/clamd.conf* \
+                        ${systemd_unitdir}/system/clamav-daemon/* \
+                        ${docdir}/clamav-daemon/*  ${sysconfdir}/clamav-daemon \
+                        ${sysconfdir}/logcheck/ignore.d.server/clamav-daemon "
+
+FILES_${PN}-freshclam = "${bindir}/freshclam \
+                        ${sysconfdir}/freshclam.conf*  \
+                        ${sysconfdir}/clamav ${sysconfdir}/default/volatiles \
+                        ${localstatedir}/lib/clamav \
+                        ${docdir}/${PN}-freshclam ${mandir}/man1/freshclam.* \
+                        ${mandir}/man5/freshclam.conf.* \
+                        ${systemd_unitdir}/system/clamav-freshclam.service"
+
+FILES_${PN}-dev = " ${bindir}/clamav-config ${libdir}/*.la \
+                    ${libdir}/pkgconfig/*.pc \
+                    ${mandir}/man1/clamav-config.* \
+                    ${includedir}/*.h ${docdir}/libclamav* "
+
+FILES_${PN}-staticdev = "${libdir}/*.a"
+
+FILES_${PN}-libclamav = "${libdir}/libclamav.so* ${libdir}/libmspack.so*\
+                          ${docdir}/libclamav/* "
+
+FILES_${PN}-doc = "${mandir}/man/* \
+                   ${datadir}/man/* \
+                   ${docdir}/* "
+
+USERADD_PACKAGES = "${PN}"
+GROUPADD_PARAM_${PN} = "--system ${UID}"
+USERADD_PARAM_${PN} = "--system -g ${GID} --home-dir  \
+    ${localstatedir}/spool/${BPN} \
+    --no-create-home  --shell /bin/false ${BPN}"
+
+RPROVIDES_${PN} += "${PN}-systemd"
+RREPLACES_${PN} += "${PN}-systemd"
+RCONFLICTS_${PN} += "${PN}-systemd"
+SYSTEMD_SERVICE_${PN} = "${BPN}.service"
+
+RDEPENDS_${PN} += "openssl ncurses-libncurses libbz2 ncurses-libtinfo clamav-freshclam clamav-libclamav"
diff --git a/meta-security/recipes-security/ecryptfs-utils/ecryptfs-utils_111.bb b/meta-security/recipes-security/ecryptfs-utils/ecryptfs-utils_111.bb
index f55b0c3..1f780f9 100644
--- a/meta-security/recipes-security/ecryptfs-utils/ecryptfs-utils_111.bb
+++ b/meta-security/recipes-security/ecryptfs-utils/ecryptfs-utils_111.bb
@@ -29,6 +29,7 @@
     --libdir=${base_libdir} \
     --disable-pywrap \
     --disable-nls \
+    --with-pamdir=${base_libdir}/security \
     "
 
 PACKAGECONFIG ??= "nss \
@@ -43,12 +44,16 @@
     export NSS_LIBS="-L${STAGING_BASELIBDIR} -lssl3 -lsmime3 -lnss3 -lsoftokn3 -lnssutil3"
     export KEYUTILS_CFLAGS="-I${STAGING_INCDIR}"
     export KEYUTILS_LIBS="-L${STAGING_LIBDIR} -lkeyutils"
+    sed -i -e "s;rootsbindir=\"/sbin\";rootsbindir=\"\${base_sbindir}\";g" ${S}/configure.ac
 }
 
 do_install_append() {
     chmod 4755 ${D}${base_sbindir}/mount.ecryptfs_private
-    mkdir -p ${D}/${libdir}
-    mv ${D}/${base_libdir}/pkgconfig ${D}/${libdir}
+    # ${base_libdir} is identical to ${libdir} when usrmerge enabled
+    if ! ${@bb.utils.contains('DISTRO_FEATURES','usrmerge','true','false',d)}; then
+        mkdir -p ${D}/${libdir}
+        mv ${D}/${base_libdir}/pkgconfig ${D}/${libdir}
+    fi
     sed -i -e 's:-I${STAGING_INCDIR}::' \
            -e 's:-L${STAGING_LIBDIR}::' ${D}/${libdir}/pkgconfig/libecryptfs.pc
     sed -i -e "s: ${base_sbindir}/cryptsetup: ${sbindir}/cryptsetup:" ${D}${bindir}/ecryptfs-setup-swap
diff --git a/meta-security/recipes-security/fail2ban/fail2ban_0.10.2.bb b/meta-security/recipes-security/fail2ban/fail2ban_0.10.2.bb
deleted file mode 100644
index 7e2deba..0000000
--- a/meta-security/recipes-security/fail2ban/fail2ban_0.10.2.bb
+++ /dev/null
@@ -1,41 +0,0 @@
-SUMMARY = "Daemon to ban hosts that cause multiple authentication errors."
-DESCRIPTION = "Fail2Ban scans log files like /var/log/auth.log and bans IP addresses having too \
-many failed login attempts. It does this by updating system firewall rules to reject new \
-connections from those IP addresses, for a configurable amount of time. Fail2Ban comes \
-out-of-the-box ready to read many standard log files, such as those for sshd and Apache, \
-and is easy to configure to read any log file you choose, for any error you choose."
-HOMEPAGE = "http://www.fail2ban.org"
-
-LICENSE = "GPL-2.0"
-LIC_FILES_CHKSUM = "file://COPYING;md5=ecabc31e90311da843753ba772885d9f"
-
-SRCREV ="a45488465e0dd547eb8479c0fa9fd577c1837213"
-SRC_URI = " \
-	git://github.com/fail2ban/fail2ban.git;branch=0.10 \
-	file://initd \
-	file://fail2ban_setup.py \
-"
-
-inherit update-rc.d setuptools
-
-S = "${WORKDIR}/git"
-
-INITSCRIPT_PACKAGES = "${PN}"
-INITSCRIPT_NAME = "fail2ban-server"
-INITSCRIPT_PARAMS = "defaults 25"
-
-do_compile_prepend () {
-    cp ${WORKDIR}/fail2ban_setup.py ${S}/setup.py
-}
-
-do_install_append () {
-	install -d ${D}/${sysconfdir}/fail2ban
-	install -d ${D}/${sysconfdir}/init.d
-    	install -m 0755 ${WORKDIR}/initd ${D}${sysconfdir}/init.d/fail2ban-server
-}
-
-FILES_${PN} += "/run"
-
-INSANE_SKIP_${PN}_append = "already-stripped"
-
-RDEPENDS_${PN} = "sysklogd iptables sqlite3 python python-pyinotify"
diff --git a/meta-security/recipes-security/fail2ban/files/run-ptest b/meta-security/recipes-security/fail2ban/files/run-ptest
new file mode 100644
index 0000000..9f6aebe
--- /dev/null
+++ b/meta-security/recipes-security/fail2ban/files/run-ptest
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+##PYTHON## fail2ban-testcases
diff --git a/meta-security/recipes-security/fail2ban/python-fail2ban.inc b/meta-security/recipes-security/fail2ban/python-fail2ban.inc
new file mode 100644
index 0000000..9245f17
--- /dev/null
+++ b/meta-security/recipes-security/fail2ban/python-fail2ban.inc
@@ -0,0 +1,49 @@
+SUMMARY = "Daemon to ban hosts that cause multiple authentication errors."
+DESCRIPTION = "Fail2Ban scans log files like /var/log/auth.log and bans IP addresses having too \
+many failed login attempts. It does this by updating system firewall rules to reject new \
+connections from those IP addresses, for a configurable amount of time. Fail2Ban comes \
+out-of-the-box ready to read many standard log files, such as those for sshd and Apache, \
+and is easy to configure to read any log file you choose, for any error you choose."
+HOMEPAGE = "http://www.fail2ban.org"
+
+LICENSE = "GPL-2.0"
+LIC_FILES_CHKSUM = "file://COPYING;md5=ecabc31e90311da843753ba772885d9f"
+
+SRCREV ="ac0d441fd68852ffda7b15c71f16b7f4fde1a7ee"
+SRC_URI = " \
+	git://github.com/fail2ban/fail2ban.git;branch=0.11 \
+	file://initd \
+        file://fail2ban_setup.py \
+        file://run-ptest \
+"
+
+inherit update-rc.d ptest
+
+S = "${WORKDIR}/git"
+
+INITSCRIPT_PACKAGES = "${PN}"
+INITSCRIPT_NAME = "fail2ban-server"
+INITSCRIPT_PARAMS = "defaults 25"
+
+do_compile_prepend () {
+    cp ${WORKDIR}/fail2ban_setup.py ${S}/setup.py
+}
+
+do_install_append () {
+	install -d ${D}/${sysconfdir}/fail2ban
+	install -d ${D}/${sysconfdir}/init.d
+    	install -m 0755 ${WORKDIR}/initd ${D}${sysconfdir}/init.d/fail2ban-server
+	chown -R root:root ${D}/${bindir}
+}
+
+do_install_ptest_append () {
+        install -d ${D}${PTEST_PATH}
+        sed -i -e 's/##PYTHON##/${PYTHON_PN}/g' ${D}${PTEST_PATH}/run-ptest
+        install -D ${S}/bin/fail2ban-testcases ${D}${PTEST_PATH}
+}
+
+FILES_${PN} += "/run"
+
+INSANE_SKIP_${PN}_append = "already-stripped"
+
+RDEPENDS_${PN} = "sysklogd iptables sqlite3 ${PYTHON_PN} ${PYTHON_PN}-pyinotify"
diff --git a/meta-security/recipes-security/fail2ban/python-fail2ban_0.10.3.1.bb b/meta-security/recipes-security/fail2ban/python-fail2ban_0.10.3.1.bb
new file mode 100644
index 0000000..17a7dd8
--- /dev/null
+++ b/meta-security/recipes-security/fail2ban/python-fail2ban_0.10.3.1.bb
@@ -0,0 +1,4 @@
+inherit setuptools
+require python-fail2ban.inc
+
+RDEPENDS_${PN}-ptest = "python python-modules python-fail2ban"
diff --git a/meta-security/recipes-security/fail2ban/python3-fail2ban_0.10.3.1.bb b/meta-security/recipes-security/fail2ban/python3-fail2ban_0.10.3.1.bb
new file mode 100644
index 0000000..5c887e8
--- /dev/null
+++ b/meta-security/recipes-security/fail2ban/python3-fail2ban_0.10.3.1.bb
@@ -0,0 +1,4 @@
+inherit setuptools3
+require python-fail2ban.inc
+
+RDEPENDS_${PN}-ptest = "python3-core python3-io python3-modules python3-fail2ban"
diff --git a/meta-security/recipes-security/fscryptctl/fscryptctl_0.1.0.bb b/meta-security/recipes-security/fscryptctl/fscryptctl_0.1.0.bb
index 4f0b12c..8847a0f 100644
--- a/meta-security/recipes-security/fscryptctl/fscryptctl_0.1.0.bb
+++ b/meta-security/recipes-security/fscryptctl/fscryptctl_0.1.0.bb
@@ -9,7 +9,7 @@
 LICENSE = "Apache-2.0"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
 
-SRCREV = "e4c4d0984dee2531897e13c32a18d5e54a2a4aa6"
+SRCREV = "142326810eb19d6794793db6d24d0775a15aa8e5"
 SRC_URI = "git://github.com/google/fscryptctl.git"
 
 S = "${WORKDIR}/git"
diff --git a/meta-security/recipes-security/images/security-build-image.bb b/meta-security/recipes-security/images/security-build-image.bb
index 1a7af86..a8757f9 100644
--- a/meta-security/recipes-security/images/security-build-image.bb
+++ b/meta-security/recipes-security/images/security-build-image.bb
@@ -6,9 +6,7 @@
     packagegroup-base \
     packagegroup-core-boot \
     packagegroup-core-security \
-    os-release \
-    ${@bb.utils.contains("DISTRO_FEATURES", "x11", "packagegroup-xfce-base", "", d)} \
-    ${CORE_IMAGE_EXTRA_INSTALL}"
+    os-release" 
 
 IMAGE_LINGUAS ?= " "
 
diff --git a/meta-security/recipes-security/keynote/keynote-2.3/configure-remove-hardcode-path.patch b/meta-security/recipes-security/keynote/keynote-2.3/configure-remove-hardcode-path.patch
deleted file mode 100644
index af3ef42..0000000
--- a/meta-security/recipes-security/keynote/keynote-2.3/configure-remove-hardcode-path.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-Remove the hardcoded lib and include dirs
-
-Upstream-Status: Inappropriate [cross compile specific]
-
-written by: Amy Fong <amy.fong@windriver.com>
-Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
-
---- keynote-2.3/configure.in.orig	2010-05-24 04:44:16.000000000 -0700
-+++ keynote-2.3/configure.in	2010-05-24 04:44:55.000000000 -0700
-@@ -21,27 +21,16 @@
- AC_PATH_PROG(ECHO, echo, /bin/echo)
- AC_PATH_PROG(SED, sed, /usr/bin/sed)
- 
--dnl Checks for libraries.
--LIBS="-L/usr/lib -L/usr/local/lib -L/usr/ssl/lib -L/usr/openssl/lib\
-- -L/usr/local/ssl/lib -L/usr/local/openssl/lib -L/usr/pkg/lib -L/pkg/lib"
--
- AC_CHECK_LIB(m, floor, LIBS="$LIBS -lm")
- AC_CHECK_LIB(rsaref, RSAPrivateDecrypt, LIBS="$LIBS -lrsaref")
- AC_CHECK_LIB(crypto, i2a_ASN1_STRING, LIBS="$LIBS -lcrypto")
- AC_CHECK_LIB(RSAglue, RSA_ref_private_encrypt, LIBS="$LIBS -lRSAglue")
- 
--dnl Checks for header files.
--CPPFLAGS="-I/usr/include -I/usr/local/include -I/usr/ssl/include\
-- -I/usr/local/ssl/include -I/usr/openssl/include -I/usr/pkg/include\
-- -I/usr/local/openssl/include -I/pkg/include"
--
- AC_HEADER_STDC
- AC_HEADER_TIME
- AC_CHECK_HEADERS(fcntl.h limits.h unistd.h regex.h sys/time.h io.h)
- AC_CHECK_HEADERS(ssl/crypto.h openssl/crypto.h crypto.h memory.h)
- 
--dnl Checks for other files
--
- dnl Checks for typedefs, structures, and compiler characteristics.
- AC_C_CONST
- AC_CHECK_TYPE(u_int, unsigned int)
diff --git a/meta-security/recipes-security/keynote/keynote-2.3/makefile-add-ldflags.patch b/meta-security/recipes-security/keynote/keynote-2.3/makefile-add-ldflags.patch
deleted file mode 100644
index 80d87cf..0000000
--- a/meta-security/recipes-security/keynote/keynote-2.3/makefile-add-ldflags.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-Add LDFLAGS variable to Makefile so that extra linker flags can be sent via this variable.
-
-Upstream-Status: Pending
-
-Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
-
-diff --git a/Makefile.in b/Makefile.in
-index b216648..42b4827 100644
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -35,6 +35,7 @@ MKDIR = @MKDIR@
- SED = @SED@
- ECHO = @ECHO@
- TR = @TR@
-+LDFLAGS = @LDFLAGS@
- 
- TARFLAGS = -cvzf ${DISTFILE}
- YACCFLAGS2 = -d -p kv -b z
-@@ -83,7 +84,7 @@ $(TARGET): $(OBJS)
- 	$(RANLIB) $(TARGET)
- 
- $(TARGET2): $(TARGET) $(OBJS2)
--	$(CC) $(CFLAGS) -o $(TARGET2) $(OBJS2) $(LIBS)
-+	$(CC) $(CFLAGS) $(LDFLAGS) -o $(TARGET2) $(OBJS2) $(LIBS)
- 
- k.tab.c: keynote.y header.h keynote.h assertion.h config.h
- 	$(YACC) $(YACCFLAGS) keynote.y
-@@ -131,7 +132,7 @@ $(SSLCERT) $(SSLKEY):
- 	-keyout $(SSLKEY)
- 
- test-sample: all $(OBJS3)
--	$(CC) $(CFLAGS) -o $(TARGET3) $(OBJS3) $(LIBS)
-+	$(CC) $(CFLAGS) $(LDFLAGS) -o $(TARGET3) $(OBJS3) $(LIBS)
- 
- test-sig: all $(SSLCERT) $(SSLKEY)
- 	$(SED) -e 's/--.*//' < $(SSLCERT) > $(SSLCERT).1
diff --git a/meta-security/recipes-security/keynote/keynote-2.3/run-ptest b/meta-security/recipes-security/keynote/keynote-2.3/run-ptest
deleted file mode 100644
index 4dc35c9..0000000
--- a/meta-security/recipes-security/keynote/keynote-2.3/run-ptest
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/bin/sh
-
-cd @PTEST_PATH@
-keynote verify -e testsuite/test-env \
-               -r false,maybe,probably,true \
-               -k testsuite/auth1 -k testsuite/auth2 \
-               -k testsuite/auth3 -k testsuite/auth4 \
-               -l testsuite/test-assertion1 \
-               -l testsuite/test-assertion2 \
-               -l testsuite/test-assertion3 \
-               -l testsuite/test-assertion4 \
-               -l testsuite/test-assertion5 \
-               -l testsuite/test-assertion6 \
-               -l testsuite/test-assertion7 \
-               && echo "PASS: keynote-ptest" \
-               || echo "FAIL: keynote-ptest"
diff --git a/meta-security/recipes-security/keynote/keynote_2.3.bb b/meta-security/recipes-security/keynote/keynote_2.3.bb
deleted file mode 100644
index e692485..0000000
--- a/meta-security/recipes-security/keynote/keynote_2.3.bb
+++ /dev/null
@@ -1,40 +0,0 @@
-SUMMARY = "Keynote tool and library"
-DESCRIPTION = "KeyNote is a simple and flexible trust-management \
-  system designed to work well for a variety of large- and small- \
-  scale Internet-based applications. \
-"
-HOMEPAGE = "http://www.cs.columbia.edu/~angelos/keynote.html"
-SECTION = "security"
-
-LICENSE = "ISC"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=3a265095c549c1808686a676f2699c98"
-
-MAIN_ID = "${@d.getVar('PV').split('.')[0]}"
-MINOR_ID = "${@d.getVar('PV').split('.')[1]}"
-SRC_URI = "${SOURCEFORGE_MIRROR}/project/${BPN}-${MAIN_ID}-${MINOR_ID}/${BPN}_${PV}.tar.gz \
-       file://configure-remove-hardcode-path.patch \
-       file://makefile-add-ldflags.patch \
-       file://run-ptest \
-"
-S = "${WORKDIR}/${BPN}-${PV}+dfsg.orig"
-
-inherit autotools-brokensep ptest
-
-SRC_URI[md5sum] = "a14553e6ad921b5c85026ce5bec3afe7"
-SRC_URI[sha256sum] = "38d2acfa1c3630a07adcb5c8fe92d2aef7f0e6d242b8998b2bbb1c6e4c408d46"
-
-DEPENDS = "flex openssl"
-
-EXTRA_OEMAKE += "test-sample -j1"
-
-do_install() {
-    install -D -m 0755 ${S}/keynote ${D}${bindir}/keynote
-    install -D -m 0644 ${S}/libkeynote.a ${D}${libdir}/libkeynote.a
-    install -D -m 0644 ${S}/keynote.h ${D}${includedir}/keynote.h
-}
-
-do_install_ptest() {
-    install -D -m 0755 ${S}/sample-app ${D}${PTEST_PATH}
-    cp -r ${S}/testsuite ${D}${PTEST_PATH}
-    sed -i 's|@PTEST_PATH@|${PTEST_PATH}|' ${D}${PTEST_PATH}/run-ptest
-}
diff --git a/meta-security/recipes-security/keyutils/keyutils_1.5.10.bb b/meta-security/recipes-security/keyutils/keyutils_1.5.10.bb
index 2ead8fa..a4222b9 100644
--- a/meta-security/recipes-security/keyutils/keyutils_1.5.10.bb
+++ b/meta-security/recipes-security/keyutils/keyutils_1.5.10.bb
@@ -27,6 +27,8 @@
 
 EXTRA_OEMAKE = "'CFLAGS=${CFLAGS} -Wall' \
     NO_ARLIB=1 \
+    BINDIR=${base_bindir} \
+    SBINDIR=${base_sbindir} \
     LIBDIR=${base_libdir} \
     USRLIBDIR=${base_libdir} \
     BUILDFOR=${SITEINFO_BITS}-bit \
diff --git a/meta-security/recipes-security/libseccomp/libseccomp_2.3.3.bb b/meta-security/recipes-security/libseccomp/libseccomp_2.3.3.bb
index 8d58163..9c66db6 100644
--- a/meta-security/recipes-security/libseccomp/libseccomp_2.3.3.bb
+++ b/meta-security/recipes-security/libseccomp/libseccomp_2.3.3.bb
@@ -35,8 +35,7 @@
     done
 }
 
-FILES_${PN} = "${bindir} ${libdir}/${PN}.so*"
+FILES_${PN} = "${bindir} ${libdir}/${BPN}.so*"
 FILES_${PN}-dbg += "${libdir}/${PN}/tests/.debug/* ${libdir}/${PN}/tools/.debug"
 
-RDEPENDS_${PN} = "bash"
 RDEPENDS_${PN}-ptest = "bash"
diff --git a/meta-security/recipes-security/nmap/nmap_7.60.bb b/meta-security/recipes-security/nmap/nmap_7.60.bb
deleted file mode 100644
index a6616eb..0000000
--- a/meta-security/recipes-security/nmap/nmap_7.60.bb
+++ /dev/null
@@ -1,54 +0,0 @@
-SUMMARY = "network auditing tool"
-DESCRIPTION = "Nmap ("Network Mapper") is a free and open source (license) utility for network discovery and security auditing.\nGui support via appending to IMAGE_FEATURES x11-base in local.conf"
-SECTION = "security"
-LICENSE = "GPL-2.0"
-
-LIC_FILES_CHKSUM = "file://COPYING;beginline=7;endline=12;md5=700c690f4ca6b1754f3f1db8645e42d9"
-
-SRC_URI = "http://nmap.org/dist/${BP}.tar.bz2 \
-           file://nmap-redefine-the-python-library-dir.patch \
-           file://nmap-replace-shtool-mkdir-with-coreutils-mkdir-command.patch \
-"
-
-SRC_URI[md5sum] = "4e454266559ddf2c4e2109866c62560c"
-SRC_URI[sha256sum] = "a8796ecc4fa6c38aad6139d9515dc8113023a82e9d787e5a5fb5fa1b05516f21"
-
-inherit autotools-brokensep pkgconfig pythonnative distro_features_check
-
-PACKAGECONFIG ?= "ncat nping ndiff pcap"
-PACKAGECONFIG += " ${@bb.utils.contains('IMAGE_FEATURES', 'x11-base', 'zenmap', '', d)}"
-
-PACKAGECONFIG[pcap] = "--with-pcap=linux, --without-pcap, libpcap, libpcap"
-PACKAGECONFIG[pcre] = "--with-libpcre=${STAGING_LIBDIR}/.., --with-libpcre=included, libpre"
-PACKAGECONFIG[ssl] = "--with-openssl=${STAGING_LIBDIR}/.., --without-openssl, openssl, openssl"
-PACKAGECONFIG[ssh2] = "--with-openssh2=${STAGING_LIBDIR}/.., --without-openssh2, libssh2, libssh2"
-PACKAGECONFIG[libz] = "--with-libz=${STAGING_LIBDIR}/.., --without-libz, zlib, zlib"
-
-#disable/enable packages
-PACKAGECONFIG[nping] = ",--without-nping,"
-PACKAGECONFIG[ncat] = ",--without-ncat,"
-PACKAGECONFIG[ndiff] = ",--without-ndiff,python"
-PACKAGECONFIG[update] = ",--without-nmap-update,"
-
-#Add gui
-PACKAGECONFIG[zenmap] = "--with-zenmap, --without-zenmap, gtk+ python-core python-codecs python-io python-logging python-unittest python-xml python-netclient python-doctest python-subprocess python-pygtk, python-core python-codecs python-io python-logging python-netclient python-xml python-unittest python-doctest python-subprocess  python-pygtk gtk+"
-
-EXTRA_OECONF = "--with-libdnet=included --with-liblinear=included --without-subversion --with-liblua=included"
-
-export PYTHON_SITEPACKAGES_DIR
-
-do_configure() {
-    # strip hard coded python2#
-    sed -i -e 's=python2\.*=python=g'  ${S}/configure.ac
-    sed -i -e 's=python2\.*=python=g'  ${S}/configure
-    autoconf
-    oe_runconf
-}
-
-PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'zenmap', '${PN}-zenmap', '', d)}"
-
-FILES_${PN} += "${PYTHON_SITEPACKAGES_DIR}"
-FILES_${PN}-zenmap = "${@bb.utils.contains("PACKAGECONFIG", "zenmap", "${bindir}/*zenmap ${bindir}/xnmap ${datadir}/applications/*  ${bindir}/nmapfe ${datadir}/zenmap/* ${PYTHON_SITEPACKAGES_DIR}/radialnet/* ${PYTHON_SITEPACKAGES_DIR}/zenmap*", "", d)}"
-
-RDEPENDS_${PN} = "python"
-RDEPENDS_${PN}-zenmap = "nmap"
diff --git a/meta-security/recipes-security/packagegroup/packagegroup-core-security.bb b/meta-security/recipes-security/packagegroup/packagegroup-core-security.bb
index 6682d29..e847847 100644
--- a/meta-security/recipes-security/packagegroup/packagegroup-core-security.bb
+++ b/meta-security/recipes-security/packagegroup/packagegroup-core-security.bb
@@ -12,6 +12,7 @@
     packagegroup-security-ids  \
     packagegroup-security-mac  \
     ${@bb.utils.contains("MACHINE_FEATURES", "tpm", "packagegroup-security-tpm", "",d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "ptest", "packagegroup-security-ptest", "", d)} \
     "
 
 RDEPENDS_packagegroup-core-security = "\
@@ -20,6 +21,7 @@
     packagegroup-security-ids  \
     packagegroup-security-mac  \
     ${@bb.utils.contains("MACHINE_FEATURES", "tpm", "packagegroup-security-tpm", "",d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "ptest", "packagegroup-security-ptest", "", d)} \
     "
 
 SUMMARY_packagegroup-security-utils = "Security utilities"
@@ -27,7 +29,11 @@
     checksec \
     nmap \
     pinentry \
-    scapy \
+    python-scapy \
+    ding-libs \
+    xmlsec1 \
+    keyutils \
+    libseccomp \
     ${@bb.utils.contains("DISTRO_FEATURES", "pax", "pax-utils", "",d)} \
     "
 
@@ -52,13 +58,28 @@
 SUMMARY_packagegroup-security-ids = "Security Intrusion Detection systems"
 RDEPENDS_packagegroup-security-ids = " \
     tripwire \
-    samhain-client \
+    samhain-standalone \
     suricata \
     "
 
 SUMMARY_packagegroup-security-mac = "Security Mandatory Access Control systems"
 RDEPENDS_packagegroup-security-mac = " \
     ${@bb.utils.contains("DISTRO_FEATURES", "tomoyo", "ccs-tools", "",d)} \
-    ${@bb.utils.contains("DISTRO_FEATURES", "apparmor", "", "",d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "apparmor", "apparmor", "",d)} \
     ${@bb.utils.contains("DISTRO_FEATURES", "smack", "smack", "",d)} \
     "
+
+SUMMARY_packagegroup-security-ptest = "Security packages with ptests"
+RDEPENDS_packagegroup-security-ptest = " \
+    samhain-standalone-ptest \
+    xmlsec1-ptest \
+    keyutils-ptest \
+    libseccomp-ptest \
+    python-scapy-ptest \
+    suricata-ptest \
+    tripwire-ptest \
+    python3-fail2ban-ptest \
+    ${@bb.utils.contains("DISTRO_FEATURES", "apparmor", "apparmor-ptest", "",d)} \
+    ${@bb.utils.contains("DISTRO_FEATURES", "smack", "smack-ptest", "",d)} \
+    ptest-runner \
+    "
diff --git a/meta-security/recipes-security/samhain/samhain-client_4.2.2.bb b/meta-security/recipes-security/samhain/samhain-client_4.3.0.bb
similarity index 100%
rename from meta-security/recipes-security/samhain/samhain-client_4.2.2.bb
rename to meta-security/recipes-security/samhain/samhain-client_4.3.0.bb
diff --git a/meta-security/recipes-security/samhain/samhain-server_4.2.2.bb b/meta-security/recipes-security/samhain/samhain-server_4.3.0.bb
similarity index 100%
rename from meta-security/recipes-security/samhain/samhain-server_4.2.2.bb
rename to meta-security/recipes-security/samhain/samhain-server_4.3.0.bb
diff --git a/meta-security/recipes-security/samhain/samhain-standalone_4.2.2.bb b/meta-security/recipes-security/samhain/samhain-standalone_4.3.0.bb
similarity index 100%
rename from meta-security/recipes-security/samhain/samhain-standalone_4.2.2.bb
rename to meta-security/recipes-security/samhain/samhain-standalone_4.3.0.bb
diff --git a/meta-security/recipes-security/samhain/samhain.inc b/meta-security/recipes-security/samhain/samhain.inc
index db96264..944bf0d 100644
--- a/meta-security/recipes-security/samhain/samhain.inc
+++ b/meta-security/recipes-security/samhain/samhain.inc
@@ -19,8 +19,11 @@
            file://samhain.service \
            "
 
-SRC_URI[md5sum] = "f499d5d06bfd1d787073a45bf28dd60f"
-SRC_URI[sha256sum] = "0f3e64afb3f00064c9b136d34a72d580cd41248c5941eba0452f364a109003c7"
+SRC_URI[md5sum] = "a00e99375675fc6e50cca3e208f5207e"
+SRC_URI[sha256sum] = "8551dc3b0851889a2b979097e9c02309b40d48b4659f02efe7fe525ce8361a0d"
+
+UPSTREAM_CHECK_URI = "https://www.la-samhna.de/samhain/archive.html"
+UPSTREAM_CHECK_REGEX = "samhain_signed-(?P<pver>(\d+(\.\d+)+))\.tar"
 
 S = "${WORKDIR}/samhain-${PV}"
 
diff --git a/meta-security/recipes-security/scapy/scapy/run-ptest b/meta-security/recipes-security/scapy/files/run-ptest
similarity index 100%
rename from meta-security/recipes-security/scapy/scapy/run-ptest
rename to meta-security/recipes-security/scapy/files/run-ptest
diff --git a/meta-security/recipes-security/scapy/python-scapy.inc b/meta-security/recipes-security/scapy/python-scapy.inc
new file mode 100644
index 0000000..5abe7db
--- /dev/null
+++ b/meta-security/recipes-security/scapy/python-scapy.inc
@@ -0,0 +1,20 @@
+SUMMARY = "Network scanning and manipulation tool"
+DESCRIPTION = "Scapy is a powerful interactive packet manipulation program. It is able to forge or decode packets of a wide number of protocols, send them on the wire, capture them, match requests and replies, and much more. It can easily handle most classical tasks like scanning, tracerouting, probing, unit tests, attacks or network discovery (it can replace hping, 85% of nmap, arpspoof, arp-sk, arping, tcpdump, tethereal, p0f, etc.). It also performs very well at a lot of other specific tasks that most other tools can't handle, like sending invalid frames, injecting your own 802.11 frames, combining technics (VLAN hopping+ARP cache poisoning, VOIP decoding on WEP encrypted channel, ...), etc."
+SECTION = "security"
+LICENSE = "GPLv2"
+
+LIC_FILES_CHKSUM = "file://bin/scapy;beginline=9;endline=13;md5=1d5249872cc54cd4ca3d3879262d0c69"
+
+SRC_URI[md5sum] = "d7d3c4294f5a718e234775d38dbeb7ec"
+SRC_URI[sha256sum] = "452f714f5c2eac6fd0a6146b1dbddfc24dd5f4103f3ed76227995a488cfb2b73"
+
+inherit pypi ptest
+
+do_install_ptest() {
+    install -m 0644 ${S}/test/regression.uts ${D}${PTEST_PATH}
+    sed -i 's,@PTEST_PATH@,${PTEST_PATH},' ${D}${PTEST_PATH}/run-ptest
+}
+
+RDEPENDS_${PN} = "tcpdump ${PYTHON_PN}-compression ${PYTHON_PN}-netclient  \
+                  ${PYTHON_PN}-netserver ${PYTHON_PN}-pydoc ${PYTHON_PN}-pkgutil ${PYTHON_PN}-shell \
+                  ${PYTHON_PN}-threading ${PYTHON_PN}-numbers ${PYTHON_PN}-pycrypto"
diff --git a/meta-security/recipes-security/scapy/python-scapy_2.4.0.bb b/meta-security/recipes-security/scapy/python-scapy_2.4.0.bb
new file mode 100644
index 0000000..98db1fd
--- /dev/null
+++ b/meta-security/recipes-security/scapy/python-scapy_2.4.0.bb
@@ -0,0 +1,6 @@
+inherit setuptools
+require python-scapy.inc
+
+SRC_URI += "file://run-ptest"
+
+RDEPENDS_${PN} += "${PYTHON_PN}-subprocess"
diff --git a/meta-security/recipes-security/scapy/python3-scapy_2.4.0.bb b/meta-security/recipes-security/scapy/python3-scapy_2.4.0.bb
new file mode 100644
index 0000000..93ca7be
--- /dev/null
+++ b/meta-security/recipes-security/scapy/python3-scapy_2.4.0.bb
@@ -0,0 +1,4 @@
+inherit setuptools3
+require python-scapy.inc
+
+SRC_URI += "file://run-ptest"
diff --git a/meta-security/recipes-security/scapy/scapy_2.3.3.bb b/meta-security/recipes-security/scapy/scapy_2.3.3.bb
deleted file mode 100644
index 1c8685b..0000000
--- a/meta-security/recipes-security/scapy/scapy_2.3.3.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-SUMMARY = "Network scanning and manipulation tool"
-DESCRIPTION = "Scapy is a powerful interactive packet manipulation program. It is able to forge or decode packets of a wide number of protocols, send them on the wire, capture them, match requests and replies, and much more. It can easily handle most classical tasks like scanning, tracerouting, probing, unit tests, attacks or network discovery (it can replace hping, 85% of nmap, arpspoof, arp-sk, arping, tcpdump, tethereal, p0f, etc.). It also performs very well at a lot of other specific tasks that most other tools can't handle, like sending invalid frames, injecting your own 802.11 frames, combining technics (VLAN hopping+ARP cache poisoning, VOIP decoding on WEP encrypted channel, ...), etc."
-SECTION = "security"
-LICENSE = "GPLv2"
-
-LIC_FILES_CHKSUM = "file://bin/scapy;beginline=9;endline=13;md5=1d5249872cc54cd4ca3d3879262d0c69"
-
-SRC_URI = "https://github.com/secdev/${BPN}/archive/v${PV}.tar.gz;downloadfilename=${BP}.tar.gz \
-           file://run-ptest \
-"
-
-SRC_URI[md5sum] = "336d6832110efcf79ad30c9856ef5842"
-SRC_URI[sha256sum] = "67642cf7b806e02daeddd588577588caebddc3426db7904e7999a0b0334a63b5"
-
-inherit setuptools ptest
-
-do_install_ptest() {
-    install -m 0644 ${S}/test/regression.uts ${D}${PTEST_PATH}
-    sed -i 's,@PTEST_PATH@,${PTEST_PATH},' ${D}${PTEST_PATH}/run-ptest
-}
-
-RDEPENDS_${PN} = "tcpdump python-subprocess python-compression python-netclient  \
-                  python-netserver python-pydoc python-pkgutil python-shell \
-                  python-threading python-numbers python-pycrypto"
diff --git a/meta-security/recipes-security/sssd/sssd_1.16.0.bb b/meta-security/recipes-security/sssd/sssd_1.16.0.bb
deleted file mode 100644
index ff5b618..0000000
--- a/meta-security/recipes-security/sssd/sssd_1.16.0.bb
+++ /dev/null
@@ -1,73 +0,0 @@
-SUMMARY = "system security services daemon"
-DESCRIPTION = "SSSD is a system security services daemon"
-HOMEPAGE = "https://fedorahosted.org/sssd/"
-SECTION = "base"
-LICENSE = "GPLv3+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
-
-DEPENDS = "openldap cyrus-sasl libtdb ding-libs libpam c-ares krb5 autoconf-archive"
-DEPENDS += "libldb dbus libtalloc libpcre glib-2.0 popt e2fsprogs libtevent"
-
-SRC_URI = "https://releases.pagure.org/SSSD/${BPN}/${BP}.tar.gz\
-            file://sssd.conf "
-
-SRC_URI[md5sum] = "f721ace2ebfa6744cfea55e3ecd2d82f"
-SRC_URI[sha256sum] = "c581a6e5365cef87fca419c0c9563cf15eadbb682863d648d85ffcded7a3940f"
-
-inherit autotools pkgconfig gettext update-rc.d python-dir distro_features_check
-
-REQUIRED_DISTRO_FEATURES = "pam"
-
-CACHED_CONFIGUREVARS = "ac_cv_member_struct_ldap_conncb_lc_arg=no \
-    ac_cv_path_NSUPDATE=${bindir} \
-    ac_cv_path_PYTHON2=${PYTHON_DIR} ac_cv_prog_HAVE_PYTHON3=${PYTHON_DIR} \
-    "
-
-PACKAGECONFIG ?="nss nscd"
-PACKAGECONFIG += "${@bb.utils.contains('DISTRO_FEATURES', 'selinux', 'selinux', '', d)}"
-
-PACKAGECONFIG[ssh] = "--with-ssh, --with-ssh=no, "
-PACKAGECONFIG[samba] = "--with-samba, --with-samba=no, samba"
-PACKAGECONFIG[selinux] = "--with-selinux, --with-selinux=no --with-semanage=no, libselinux"
-PACKAGECONFIG[manpages] = "--with-manpages, --with-manpages=no"
-PACKAGECONFIG[python2] = "--with-python2-bindings, --without-python2-bindings"
-PACKAGECONFIG[python3] = "--with-python3-bindings, --without-python3-bindings"
-PACKAGECONFIG[nss] = "--with-crypto=nss, ,nss,"
-PACKAGECONFIG[cyrpto] = "--with-crypto=libcrypto, , libcrypto"
-PACKAGECONFIG[nscd] = "--with-nscd=${sbindir}, --with-nscd=no "
-PACKAGECONFIG[nl] = "--with-libnl, --with-libnl=no, libnl"
-PACKAGECONFIG[systemd] = "--with-systemdunitdir=${systemd_unitdir}/system/, --with-systemdunitdir="
-PACKAGECONFIG[http] = "--with-secrets, --without-secrets, apache2"
-PACKAGECONFIG[curl] = "--with-secrets --with-kcm, --without-secrets --without-kcm, curl"
-
-EXTRA_OECONF += "--disable-cifs-idmap-plugin --without-nfsv4-idmapd-plugin --without-ipa-getkeytab"
-
-do_configure_prepend() {
-    mkdir -p ${AUTOTOOLS_AUXDIR}/build
-    cp ${STAGING_DATADIR_NATIVE}/gettext/config.rpath ${AUTOTOOLS_AUXDIR}/build/
-
-    # libresove has host path, remove it
-    sed -i -e "s#\$sss_extra_libdir##" ${S}/src/external/libresolv.m4
-}
-
-do_install () {
-    oe_runmake install  DESTDIR="${D}"
-    rmdir --ignore-fail-on-non-empty "${D}/${bindir}"
-    install -d ${D}/${sysconfdir}/${BPN}
-    install -m 600 ${WORKDIR}/${BPN}.conf ${D}/${sysconfdir}/${BPN}
-}
-
-CONFFILES_${PN} = "${sysconfdir}/${BPN}/${BPN}.conf"
-
-INITSCRIPT_NAME = "sssd"
-INITSCRIPT_PARAMS = "start 02 5 3 2 . stop 20 0 1 6 ."
-SYSTEMD_SERVICE_${PN} = "${BPN}.service"
-SYSTEMD_AUTO_ENABLE = "disable"
-
-FILES_${PN} += "${libdir} ${datadir} /run ${libdir}/*.so* "
-FILES_${PN}-dev = " ${includedir}/* ${libdir}/*la ${libdir}/*/*la"
-
-# The package contains symlinks that trip up insane
-INSANE_SKIP_${PN} = "dev-so"
-
-RDEPENDS_${PN} += "bind dbus"
diff --git a/meta-security/recipes-security/sssd/sssd_1.16.3.bb b/meta-security/recipes-security/sssd/sssd_1.16.3.bb
new file mode 100644
index 0000000..8f7f805
--- /dev/null
+++ b/meta-security/recipes-security/sssd/sssd_1.16.3.bb
@@ -0,0 +1,73 @@
+SUMMARY = "system security services daemon"
+DESCRIPTION = "SSSD is a system security services daemon"
+HOMEPAGE = "https://pagure.io/SSSD/sssd/"
+SECTION = "base"
+LICENSE = "GPLv3+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
+
+DEPENDS = "openldap cyrus-sasl libtdb ding-libs libpam c-ares krb5 autoconf-archive"
+DEPENDS += "libldb dbus libtalloc libpcre glib-2.0 popt e2fsprogs libtevent"
+
+SRC_URI = "https://releases.pagure.org/SSSD/${BPN}/${BP}.tar.gz\
+            file://sssd.conf "
+
+SRC_URI[md5sum] = "af4288c9d1f9953e3b3b6e0b165a5ece"
+SRC_URI[sha256sum] = "ee5d17a0c663c09819cbab9364085b9e57faeca02406cc30efe14cc0cfc04ec4"
+
+inherit autotools pkgconfig gettext update-rc.d python-dir distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "pam"
+
+CACHED_CONFIGUREVARS = "ac_cv_member_struct_ldap_conncb_lc_arg=no \
+    ac_cv_path_NSUPDATE=${bindir} \
+    ac_cv_path_PYTHON2=${PYTHON_DIR} ac_cv_prog_HAVE_PYTHON3=${PYTHON_DIR} \
+    "
+
+PACKAGECONFIG ?="nss nscd"
+PACKAGECONFIG += "${@bb.utils.contains('DISTRO_FEATURES', 'selinux', 'selinux', '', d)}"
+
+PACKAGECONFIG[ssh] = "--with-ssh, --with-ssh=no, "
+PACKAGECONFIG[samba] = "--with-samba, --with-samba=no, samba"
+PACKAGECONFIG[selinux] = "--with-selinux, --with-selinux=no --with-semanage=no, libselinux"
+PACKAGECONFIG[manpages] = "--with-manpages, --with-manpages=no"
+PACKAGECONFIG[python2] = "--with-python2-bindings, --without-python2-bindings"
+PACKAGECONFIG[python3] = "--with-python3-bindings, --without-python3-bindings"
+PACKAGECONFIG[nss] = "--with-crypto=nss, ,nss,"
+PACKAGECONFIG[cyrpto] = "--with-crypto=libcrypto, , libcrypto"
+PACKAGECONFIG[nscd] = "--with-nscd=${sbindir}, --with-nscd=no "
+PACKAGECONFIG[nl] = "--with-libnl, --with-libnl=no, libnl"
+PACKAGECONFIG[systemd] = "--with-systemdunitdir=${systemd_unitdir}/system/, --with-systemdunitdir="
+PACKAGECONFIG[http] = "--with-secrets, --without-secrets, apache2"
+PACKAGECONFIG[curl] = "--with-secrets --with-kcm, --without-secrets --without-kcm, curl"
+
+EXTRA_OECONF += "--disable-cifs-idmap-plugin --without-nfsv4-idmapd-plugin --without-ipa-getkeytab"
+
+do_configure_prepend() {
+    mkdir -p ${AUTOTOOLS_AUXDIR}/build
+    cp ${STAGING_DATADIR_NATIVE}/gettext/config.rpath ${AUTOTOOLS_AUXDIR}/build/
+
+    # libresove has host path, remove it
+    sed -i -e "s#\$sss_extra_libdir##" ${S}/src/external/libresolv.m4
+}
+
+do_install () {
+    oe_runmake install  DESTDIR="${D}"
+    rmdir --ignore-fail-on-non-empty "${D}/${bindir}"
+    install -d ${D}/${sysconfdir}/${BPN}
+    install -m 600 ${WORKDIR}/${BPN}.conf ${D}/${sysconfdir}/${BPN}
+}
+
+CONFFILES_${PN} = "${sysconfdir}/${BPN}/${BPN}.conf"
+
+INITSCRIPT_NAME = "sssd"
+INITSCRIPT_PARAMS = "start 02 5 3 2 . stop 20 0 1 6 ."
+SYSTEMD_SERVICE_${PN} = "${BPN}.service"
+SYSTEMD_AUTO_ENABLE = "disable"
+
+FILES_${PN} += "${libdir} ${datadir} /run ${libdir}/*.so* "
+FILES_${PN}-dev = " ${includedir}/* ${libdir}/*la ${libdir}/*/*la"
+
+# The package contains symlinks that trip up insane
+INSANE_SKIP_${PN} = "dev-so"
+
+RDEPENDS_${PN} += "bind dbus"
diff --git a/meta-security/recipes-security/suricata/files/emerging.rules.tar.gz b/meta-security/recipes-security/suricata/files/emerging.rules.tar.gz
new file mode 100644
index 0000000..aed3754
--- /dev/null
+++ b/meta-security/recipes-security/suricata/files/emerging.rules.tar.gz
Binary files differ
diff --git a/meta-security/recipes-security/suricata/files/run-ptest b/meta-security/recipes-security/suricata/files/run-ptest
new file mode 100644
index 0000000..666ba9c
--- /dev/null
+++ b/meta-security/recipes-security/suricata/files/run-ptest
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+suricata -u
diff --git a/meta-security/recipes-security/suricata/files/suricata.service b/meta-security/recipes-security/suricata/files/suricata.service
new file mode 100644
index 0000000..a99a76e
--- /dev/null
+++ b/meta-security/recipes-security/suricata/files/suricata.service
@@ -0,0 +1,20 @@
+[Unit]
+Description=Suricata IDS/IDP daemon
+After=network.target
+Requires=network.target
+Documentation=man:suricata(8) man:suricatasc(8)
+Documentation=https://redmine.openinfosecfoundation.org/projects/suricata/wiki
+
+[Service]
+Type=simple
+CapabilityBoundingSet=CAP_NET_ADMIN CAP_NET_RAW
+RestrictAddressFamilies=
+ExecStart=/usr/bin/suricata -c /etc/suricata/suricata.yaml eth0
+ExecReload=/bin/kill -HUP $MAINPID
+PrivateTmp=yes
+ProtectHome=yes
+ProtectSystem=yes
+
+[Install]
+WantedBy=multi-user.target
+
diff --git a/meta-security/recipes-security/suricata/files/suricata.yaml b/meta-security/recipes-security/suricata/files/suricata.yaml
index 90417b0..8d06a27 100644
--- a/meta-security/recipes-security/suricata/files/suricata.yaml
+++ b/meta-security/recipes-security/suricata/files/suricata.yaml
@@ -787,7 +787,7 @@
       enabled: no
       filename: /var/log/suricata.log
   - syslog:
-      enabled: no
+      enabled: yes
       facility: local5
       format: "[%i] <%d> -- "
 
diff --git a/meta-security/recipes-security/suricata/libhtp_0.5.25.bb b/meta-security/recipes-security/suricata/libhtp_0.5.27.bb
similarity index 100%
rename from meta-security/recipes-security/suricata/libhtp_0.5.25.bb
rename to meta-security/recipes-security/suricata/libhtp_0.5.27.bb
diff --git a/meta-security/recipes-security/suricata/suricata.inc b/meta-security/recipes-security/suricata/suricata.inc
index a2d36eb..1f42121 100644
--- a/meta-security/recipes-security/suricata/suricata.inc
+++ b/meta-security/recipes-security/suricata/suricata.inc
@@ -2,8 +2,8 @@
 SECTION = "security Monitor/Admin"
 LICENSE = "GPLv2"
 
-VER = "4.0.0"
+VER = "4.0.5"
 SRC_URI = "http://www.openinfosecfoundation.org/download/suricata-${VER}.tar.gz"
 
-SRC_URI[md5sum] = "41fb91b4cbc6705b353e4bdd02c3df4b"
-SRC_URI[sha256sum] = "6b8b183a8409829ca92c71854cc1abed45f04ccfb7f14c08211f4edf571fa577"
+SRC_URI[md5sum] = "ea0cb823d6a86568152f75ade6de442f"
+SRC_URI[sha256sum] = "74dacb4359d57fbd3452e384eeeb1dd77b6ae00f02e9994ad5a7b461d5f4c6c2"
diff --git a/meta-security/recipes-security/suricata/suricata_4.0.0.bb b/meta-security/recipes-security/suricata/suricata_4.0.0.bb
deleted file mode 100644
index e163486..0000000
--- a/meta-security/recipes-security/suricata/suricata_4.0.0.bb
+++ /dev/null
@@ -1,60 +0,0 @@
-SUMMARY = "The Suricata Engine is an Open Source Next Generation Intrusion Detection and Prevention Engine"
-
-require suricata.inc
-
-LIC_FILES_CHKSUM = "file://LICENSE;beginline=1;endline=2;md5=c70d8d3310941dcdfcd1e02800a1f548"
-
-SRC_URI += " \
-           file://volatiles.03_suricata \
-           file://suricata.yaml \
-           "
-
-inherit autotools-brokensep pkgconfig python-dir 
-
-CFLAGS += "-D_DEFAULT_SOURCE"
-
-CACHED_CONFIGUREVARS = "ac_cv_header_htp_htp_h=yes ac_cv_lib_htp_htp_conn_create=yes "
-
-EXTRA_OECONF += " --disable-debug \
-    --enable-non-bundled-htp \
-    --disable-gccmarch-native \
-    "
-
-PACKAGECONFIG ??= "htp jansson file pcre yaml pcap cap-ng net nfnetlink nss nspr"
-PACKAGECONFIG[htp] = "--with-libhtp-includes=${STAGING_INCDIR} --with-libhtp-libraries=${STAGING_LIBDIR}, ,libhtp,"
-PACKAGECONFIG[pcre] = "--with-libpcre-includes=${STAGING_INCDIR} --with-libpcre-libraries=${STAGING_LIBDIR}, ,libpcre ," 
-PACKAGECONFIG[yaml] = "--with-libyaml-includes=${STAGING_INCDIR} --with-libyaml-libraries=${STAGING_LIBDIR}, ,libyaml ,"
-PACKAGECONFIG[pcap] = "--with-libpcap-includes=${STAGING_INCDIR} --with-libpcap-libraries=${STAGING_LIBDIR}, ,libpcap ," 
-PACKAGECONFIG[cap-ng] = "--with-libcap_ng-includes=${STAGING_INCDIR} --with-libcap_ng-libraries=${STAGING_LIBDIR}, ,libcap-ng , "
-PACKAGECONFIG[net] = "--with-libnet-includes=${STAGING_INCDIR} --with-libnet-libraries=${STAGING_LIBDIR}, , libnet," 
-PACKAGECONFIG[nfnetlink] = "--with-libnfnetlink-includes=${STAGING_INCDIR} --with-libnfnetlink-libraries=${STAGING_LIBDIR}, ,libnfnetlink ,"
-
-PACKAGECONFIG[jansson] = "--with-libjansson-includes=${STAGING_INCDIR} --with-libjansson-libraries=${STAGING_LIBDIR},,jansson, jansson"
-PACKAGECONFIG[file] = ",,file, file"
-PACKAGECONFIG[nss] = "--with-libnss-includes=${STAGING_INCDIR} --with-libnss-libraries=${STAGING_LIBDIR}, nss, nss," 
-PACKAGECONFIG[nspr] = "--with-libnspr-includes=${STAGING_INCDIR} --with-libnspr-libraries=${STAGING_LIBDIR}, nspr, nspr," 
-PACKAGECONFIG[python] = "--enable-python, --disable-python, python, python" 
-
-export logdir = "${localstatedir}/log"
-
-do_install_append () {
-    install -d ${D}${sysconfdir}/suricata
-    install -d ${D}${sysconfdir}/suricata ${D}${sysconfdir}/default/volatiles
-    install -m 644 classification.config ${D}${sysconfdir}/suricata
-    install -m 644 reference.config ${D}${sysconfdir}/suricata
-    install -m 644 ${WORKDIR}/suricata.yaml ${D}${sysconfdir}/suricata
-    install -m 0644 ${WORKDIR}/volatiles.03_suricata  ${D}${sysconfdir}/default/volatiles/volatiles.03_suricata
-}
-
-pkg_postinst_ontarget_${PN} () {
-if [ -e /etc/init.d/populate-volatile.sh ] ; then
-    ${sysconfdir}/init.d/populate-volatile.sh update
-fi
-    ${bindir}/suricata -c ${sysconfdir}/suricata.yaml -i eth0 
-}
-
-PACKAGES += "${PN}-python"
-FILES_${PN} = "${bindir}/suricata ${sysconfdir}/default ${sysconfdir}/suricata ${logdir}/suricata"
-FILES_${PN}-python = "${bindir}/suricatasc ${PYTHON_SITEPACKAGES_DIR}"
-
-RDEPENDS_${PN}-python = "python"
diff --git a/meta-security/recipes-security/suricata/suricata_4.0.5.bb b/meta-security/recipes-security/suricata/suricata_4.0.5.bb
new file mode 100644
index 0000000..6c0a109
--- /dev/null
+++ b/meta-security/recipes-security/suricata/suricata_4.0.5.bb
@@ -0,0 +1,96 @@
+SUMMARY = "The Suricata Engine is an Open Source Next Generation Intrusion Detection and Prevention Engine"
+
+require suricata.inc
+
+LIC_FILES_CHKSUM = "file://LICENSE;beginline=1;endline=2;md5=c70d8d3310941dcdfcd1e02800a1f548"
+
+SRC_URI += "file://emerging.rules.tar.gz;name=rules"
+
+SRC_URI += " \
+           file://volatiles.03_suricata \
+           file://suricata.yaml \
+           file://suricata.service \
+           file://run-ptest \
+           "
+
+SRC_URI[rules.md5sum] = "205c5e5b54e489207ed892c03ad75b33"
+SRC_URI[rules.sha256sum] = "4aa81011b246875a57181c6a0569ca887845e366904bcaf0043220f33bd69798"
+
+inherit autotools-brokensep pkgconfig python-dir systemd ptest
+
+CFLAGS += "-D_DEFAULT_SOURCE"
+
+CACHED_CONFIGUREVARS = "ac_cv_header_htp_htp_h=yes ac_cv_lib_htp_htp_conn_create=yes \
+                        ac_cv_path_HAVE_WGET=no ac_cv_path_HAVE_CURL=no "
+
+EXTRA_OECONF += " --disable-debug \
+    --enable-non-bundled-htp \
+    --disable-gccmarch-native \
+    "
+
+PACKAGECONFIG ??= "htp jansson file pcre yaml pcap cap-ng net nfnetlink nss nspr"
+PACKAGECONFIG_append = " ${@bb.utils.contains('DISTRO_FEATURES', 'ptest', 'unittests', '', d)}"
+
+PACKAGECONFIG[htp] = "--with-libhtp-includes=${STAGING_INCDIR} --with-libhtp-libraries=${STAGING_LIBDIR}, ,libhtp,"
+PACKAGECONFIG[pcre] = "--with-libpcre-includes=${STAGING_INCDIR} --with-libpcre-libraries=${STAGING_LIBDIR}, ,libpcre ," 
+PACKAGECONFIG[yaml] = "--with-libyaml-includes=${STAGING_INCDIR} --with-libyaml-libraries=${STAGING_LIBDIR}, ,libyaml ,"
+PACKAGECONFIG[pcap] = "--with-libpcap-includes=${STAGING_INCDIR} --with-libpcap-libraries=${STAGING_LIBDIR}, ,libpcap ," 
+PACKAGECONFIG[cap-ng] = "--with-libcap_ng-includes=${STAGING_INCDIR} --with-libcap_ng-libraries=${STAGING_LIBDIR}, ,libcap-ng , "
+PACKAGECONFIG[net] = "--with-libnet-includes=${STAGING_INCDIR} --with-libnet-libraries=${STAGING_LIBDIR}, , libnet," 
+PACKAGECONFIG[nfnetlink] = "--with-libnfnetlink-includes=${STAGING_INCDIR} --with-libnfnetlink-libraries=${STAGING_LIBDIR}, ,libnfnetlink ,"
+PACKAGECONFIG[nfq] = "--enable-nfqueue, --disable-nfqueue,libnetfilter-queue,"
+
+PACKAGECONFIG[jansson] = "--with-libjansson-includes=${STAGING_INCDIR} --with-libjansson-libraries=${STAGING_LIBDIR},,jansson, jansson"
+PACKAGECONFIG[file] = ",,file, file"
+PACKAGECONFIG[nss] = "--with-libnss-includes=${STAGING_INCDIR} --with-libnss-libraries=${STAGING_LIBDIR}, nss, nss," 
+PACKAGECONFIG[nspr] = "--with-libnspr-includes=${STAGING_INCDIR} --with-libnspr-libraries=${STAGING_LIBDIR}, nspr, nspr," 
+PACKAGECONFIG[python] = "--enable-python, --disable-python, python, python" 
+PACKAGECONFIG[unittests] = "--enable-unittests, --disable-unittests," 
+
+export logdir = "${localstatedir}/log"
+
+do_install_append () {
+
+    install -d ${D}${sysconfdir}/suricata
+
+    oe_runmake install-conf DESTDIR=${D}
+
+    # mimic move of downloaded rules to e_sysconfrulesdir
+    cp -rf  ${WORKDIR}/rules ${D}${sysconfdir}/suricata
+
+    oe_runmake install-rules DESTDIR=${D}
+
+    install -d ${D}${sysconfdir}/suricata ${D}${sysconfdir}/default/volatiles
+    install -m 0644 ${WORKDIR}/volatiles.03_suricata  ${D}${sysconfdir}/default/volatiles/volatiles.03_suricata
+
+    install -m 0644 ${S}/threshold.config ${D}${sysconfdir}/suricata
+
+    install -d ${D}${systemd_unitdir}/system
+    sed  -e s:/etc:${sysconfdir}:g \
+         -e s:/var/run:/run:g \
+         -e s:/var:${localstatedir}:g \
+         -e s:/usr/bin:${bindir}:g \
+         -e s:/bin/kill:${base_bindir}/kill:g \
+         -e s:/usr/lib:${libdir}:g \
+         ${WORKDIR}/suricata.service > ${D}${systemd_unitdir}/system/suricata.service
+
+    # Remove /var/run as it is created on startup
+    rm -rf ${D}${localstatedir}/run
+
+}
+
+pkg_postinst_ontarget_${PN} () {
+if [ -e /etc/init.d/populate-volatile.sh ] ; then
+    ${sysconfdir}/init.d/populate-volatile.sh update
+fi
+}
+
+SYSTEMD_PACKAGES = "${PN}"
+
+PACKAGES =+ "${PN}-socketcontrol"
+FILES_${PN} += "${systemd_unitdir}"
+FILES_${PN}-socketcontrol = "${bindir}/suricatasc ${PYTHON_SITEPACKAGES_DIR}"
+
+CONFFILES_${PN} = "${sysconfdir}/suricata/suricata.yaml"
+
+RDEPENDS_${PN}-python = "python"
diff --git a/meta-security/recipes-security/tripwire/files/run-ptest b/meta-security/recipes-security/tripwire/files/run-ptest
new file mode 100644
index 0000000..aedfddc
--- /dev/null
+++ b/meta-security/recipes-security/tripwire/files/run-ptest
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+./twtest.pl
diff --git a/meta-security/recipes-security/tripwire/tripwire_2.4.3.6.bb b/meta-security/recipes-security/tripwire/tripwire_2.4.3.6.bb
index 465960f..59d1f35 100644
--- a/meta-security/recipes-security/tripwire/tripwire_2.4.3.6.bb
+++ b/meta-security/recipes-security/tripwire/tripwire_2.4.3.6.bb
@@ -16,11 +16,12 @@
 	file://twcfg.txt \
 	file://twinstall.sh \
 	file://twpol-yocto.txt \
+	file://run-ptest \
        "
 
 S = "${WORKDIR}/git"
 
-inherit autotools-brokensep update-rc.d
+inherit autotools-brokensep update-rc.d ptest
 
 INITSCRIPT_NAME = "tripwire"
 INITSCRIPT_PARAMS = "start 40 S ."
@@ -58,9 +59,15 @@
     install -m 0644 ${WORKDIR}/tripwire.txt ${D}${docdir}/${BPN}
 }
 
+do_install_ptest_append () {
+	install -d ${D}${PTEST_PATH}/tests
+	cp -a ${S}/src/test-harness/* ${D}${PTEST_PATH}
+}
 
 FILES_${PN} += "${libdir} ${docdir}/${PN}/*"
 FILES_${PN}-dbg += "${sysconfdir}/${PN}/.debug"
 FILES_${PN}-staticdev += "${localstatedir}/lib/${PN}/lib*.a"
+FILES_${PN}-ptest += "${PTEST_PATH}/tests "
 
 RDEPENDS_${PN} += " perl nano msmtp cronie"
+RDEPENDS_${PN}-ptest = " perl lib-perl"
diff --git a/meta-security/recipes-security/xmlsec1/xmlsec1/change-finding-path-of-nss.patch b/meta-security/recipes-security/xmlsec1/xmlsec1/change-finding-path-of-nss.patch
index fcc63b3..1cec47f 100644
--- a/meta-security/recipes-security/xmlsec1/xmlsec1/change-finding-path-of-nss.patch
+++ b/meta-security/recipes-security/xmlsec1/xmlsec1/change-finding-path-of-nss.patch
@@ -1,4 +1,4 @@
-From 47379747e34f952d31af028c672940ca7859ae3c Mon Sep 17 00:00:00 2001
+From c1c980a95d85bcaf8802524d6148783522b300d7 Mon Sep 17 00:00:00 2001
 From: Yulong Pei <Yulong.pei@windriver.com>
 Date: Wed, 21 Jul 2010 22:33:43 +0800
 Subject: [PATCH] change finding path of nss and nspr
@@ -7,66 +7,61 @@
 
 Signed-off-by: Yulong Pei <Yulong.pei@windriver.com>
 Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
-
+Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
 ---
- configure.ac | 12 ++++++------
- 1 file changed, 6 insertions(+), 6 deletions(-)
+ configure.ac | 20 ++++++++++----------
+ 1 file changed, 10 insertions(+), 10 deletions(-)
 
 diff --git a/configure.ac b/configure.ac
-index 3278200..6edec7d 100644
+index 951b3eb..1fdeb0f 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -644,7 +644,7 @@ if test "z$NSS_FOUND" = "zno" ; then
+@@ -866,10 +866,10 @@ MOZILLA_MIN_VERSION="1.4"
+ NSS_CRYPTO_LIB="$XMLSEC_PACKAGE-nss"
+ NSPR_PACKAGE=mozilla-nspr
+ NSS_PACKAGE=mozilla-nss
+-NSPR_INCLUDE_MARKER="nspr/nspr.h"
++NSPR_INCLUDE_MARKER="nspr.h"
+ NSPR_LIB_MARKER="libnspr4$shrext"
+ NSPR_LIBS_LIST="-lnspr4 -lplds4 -lplc4"
+-NSS_INCLUDE_MARKER="nss/nss.h"
++NSS_INCLUDE_MARKER="nss3/nss.h"
+ NSS_LIB_MARKER="libnss3$shrext"
+ NSS_LIBS_LIST="-lnss3 -lsmime3"
  
-     if test "z$with_nspr" != "z" ; then
- 	NSPR_PREFIX="$with_nspr"
--	NSPR_CFLAGS="-I$with_nspr/include -I$with_nspr/include/nspr"
-+	NSPR_CFLAGS="-I$with_nspr/usr/include -I$with_nspr/usr/include/nspr4"
- 	if test "z$with_gnu_ld" = "zyes" ; then
- 	    NSPR_LIBS="-Wl,-rpath-link -Wl,$with_nspr/lib -L$with_nspr/lib $NSPR_LIBS_LIST"
- 	else
-@@ -652,7 +652,7 @@ if test "z$NSS_FOUND" = "zno" ; then
- 	fi
- 	NSPR_INCLUDES_FOUND="yes"
- 	NSPR_LIBS_FOUND="yes"
--	NSPR_PRINIT_H="$with_nspr/include/prinit.h"
-+	NSPR_PRINIT_H="$with_nspr/usr/include/nspr4/prinit.h"
+@@ -898,24 +898,24 @@ fi
+ dnl Priority 1: User specifies the path to installation
+ if test "z$NSPR_FOUND" = "zno" -a "z$with_nspr" != "z" -a "z$with_nspr" != "zyes" ; then
+     AC_MSG_CHECKING(for nspr library installation in "$with_nspr" folder)
+-    if test -f "$with_nspr/include/$NSPR_INCLUDE_MARKER" -a -f "$with_nspr/lib/$NSPR_LIB_MARKER" ; then
+-        NSPR_INCLUDE_PATH="$with_nspr/include"
+-        NSPR_LIB_PATH="$with_nspr/lib"
++    if test -f "$with_nspr/usr/include/$NSPR_INCLUDE_MARKER" -a -f "$with_nspr/${libdir}/$NSPR_LIB_MARKER" ; then
++        NSPR_INCLUDE_PATH="$with_nspr/usr/include"
++        NSPR_LIB_PATH="$with_nspr/${libdir}"
+         NSPR_FOUND="yes"
+         AC_MSG_RESULT([yes])
      else
- 	for dir in $ac_nss_inc_dir ; do
-     	    if test -f $dir/nspr/prinit.h ; then
-@@ -690,7 +690,7 @@ if test "z$NSS_FOUND" = "zno" ; then
- 	OLD_CPPFLAGS=$CPPFLAGS
- 	CPPFLAGS="$NSPR_CFLAGS"
- 	AC_EGREP_CPP(yes,[
--    	    #include <prinit.h>
-+	    #include <nspr4/prinit.h>
-             #if PR_VMAJOR >= 4
-                yes
-             #endif
-@@ -715,7 +715,7 @@ if test "z$NSS_FOUND" = "zno" ; then
-     NSS_NSS_H=""
+-        AC_MSG_ERROR([not found: "$with_nspr/include/$NSPR_INCLUDE_MARKER" and/or "$with_nspr/lib/$NSPR_LIB_MARKER" files don't exist), typo?])
++        AC_MSG_ERROR([not found: "$with_nspr/usr/include/$NSPR_INCLUDE_MARKER" and/or "$with_nspr/${libdir}/$NSPR_LIB_MARKER" files don't exist), typo?])
+     fi
+ fi
+ if test "z$NSS_FOUND" = "zno" -a "z$with_nss" != "z" -a "z$with_nss" != "zyes" ; then
+     AC_MSG_CHECKING(for nss library installation in "$with_nss" folder)
+-    if test -f "$with_nss/include/$NSS_INCLUDE_MARKER" -a -f "$with_nss/lib/$NSS_LIB_MARKER" ; then
+-        NSS_INCLUDE_PATH="$with_nss/include"
+-        NSS_LIB_PATH="$with_nss/lib"
++    if test -f "$with_nss/usr/include/$NSS_INCLUDE_MARKER" -a -f "$with_nss/${libdir}/$NSS_LIB_MARKER" ; then
++        NSS_INCLUDE_PATH="$with_nss/usr/include/nss3"
++        NSS_LIB_PATH="$with_nss/${libdir}"
+         NSS_FOUND="yes"
+         AC_MSG_RESULT([yes])
+     else
+-        AC_MSG_ERROR([not found: "$with_nss/include/$NSS_INCLUDE_MARKER" and/or "$with_nss/lib/$NSS_LIB_MARKER" files don't exist), typo?])
++        AC_MSG_ERROR([not found: "$with_nss/usr/include/$NSS_INCLUDE_MARKER" and/or "$with_nss/${libdir}/$NSS_LIB_MARKER" files don't exist), typo?])
+     fi
+ fi
  
-     if test "z$with_nss" != "z" ; then
--	NSS_CFLAGS="$NSS_CFLAGS -I$with_nss/include -I$with_nss/include/nss"
-+	NSS_CFLAGS="$NSS_CFLAGS -I$with_nss/usr/include -I$with_nss/usr/include/nss3 -I$with_nspr/usr/include/nspr4"
- 	if test "z$with_gnu_ld" = "zyes" ; then
- 	    NSS_LIBS="$NSS_LIBS -Wl,-rpath-link -Wl,$with_nss/lib -L$with_nss/lib $NSS_LIBS_LIST"
-         else
-@@ -723,7 +723,7 @@ if test "z$NSS_FOUND" = "zno" ; then
-         fi
- 	NSS_INCLUDES_FOUND="yes"
- 	NSS_LIBS_FOUND="yes"
--	NSS_NSS_H="$with_nss/include/nss.h"
-+	NSS_NSS_H="$with_nss/usr/include/nss3/nss.h"
-     else
- 	for dir in $ac_nss_inc_dir ; do
- 	    if test -f $dir/nss/nss.h ; then
-@@ -761,7 +761,7 @@ if test "z$NSS_FOUND" = "zno" ; then
-        OLD_CPPFLAGS=$CPPFLAGS
-        CPPFLAGS="$NSPR_CFLAGS $NSS_CFLAGS"
-        AC_EGREP_CPP(yes,[
--          #include <nss.h>
-+	  #include <nss3/nss.h>
-           #if NSS_VMAJOR >= 3 && NSS_VMINOR >= 2
-              yes
-           #endif
+-- 
+2.7.4
+
diff --git a/meta-security/recipes-security/xmlsec1/xmlsec1/xmlsec1-fix-a-typo-in-examples-verify3.c.patch b/meta-security/recipes-security/xmlsec1/xmlsec1/xmlsec1-fix-a-typo-in-examples-verify3.c.patch
deleted file mode 100644
index 5f967bb..0000000
--- a/meta-security/recipes-security/xmlsec1/xmlsec1/xmlsec1-fix-a-typo-in-examples-verify3.c.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-From 1d8ae4b32bd76c19ec238f30eb9b1ee582cbe990 Mon Sep 17 00:00:00 2001
-From: Jackie Huang <jackie.huang@windriver.com>
-Date: Fri, 2 Mar 2018 01:10:58 -0800
-Subject: [PATCH] xmlsec1: fix a typo in examples/verify3.c
-
-Upstream-Status: Submitted [https://github.com/lsh123/xmlsec/pull/153]
-
-Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
-
----
- examples/verify3.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/examples/verify3.c b/examples/verify3.c
-index 2d26ae7..68f52ab 100644
---- a/examples/verify3.c
-+++ b/examples/verify3.c
-@@ -1,4 +1,4 @@
--4/** 
-+/**
-  * XML Security Library example: Verifying a file signed with X509 certificate
-  *
-  * Verifies a file signed with X509 certificate. 
diff --git a/meta-security/recipes-security/xmlsec1/xmlsec1_1.2.25.bb b/meta-security/recipes-security/xmlsec1/xmlsec1_1.2.25.bb
deleted file mode 100644
index 341ca08..0000000
--- a/meta-security/recipes-security/xmlsec1/xmlsec1_1.2.25.bb
+++ /dev/null
@@ -1,57 +0,0 @@
-SUMMARY = "XML Security Library is a C library based on LibXML2"
-DESCRIPTION = "\
-    XML Security Library is a C library based on \
-    LibXML2 and OpenSSL. The library was created with a goal to support major \
-    XML security standards "XML Digital Signature" and "XML Encryption". \
-    "
-HOMEPAGE = "http://www.aleksey.com/xmlsec/"
-DEPENDS = "libtool libxml2 libxslt openssl zlib libgcrypt gnutls nss nspr libgpg-error"
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=352791d62092ea8104f085042de7f4d0"
-
-SECTION = "libs"
-
-SRC_URI = "http://www.aleksey.com/xmlsec/download/${BP}.tar.gz \
-    file://fix-ltmain.sh.patch \
-    file://change-finding-path-of-nss.patch \
-    file://makefile-ptest.patch \
-    file://xmlsec1-examples-allow-build-in-separate-dir.patch \
-    file://xmlsec1-fix-a-typo-in-examples-verify3.c.patch \
-    file://run-ptest \
-    "
-
-SRC_URI[md5sum] = "dbbef1efc69e61bc4629650205a05b41"
-SRC_URI[sha256sum] = "967ca83edf25ccb5b48a3c4a09ad3405a63365576503bf34290a42de1b92fcd2"
-
-inherit autotools-brokensep ptest pkgconfig
-
-CFLAGS += "-I${STAGING_INCDIR}/nspr4 -I${STAGING_INCDIR}/nss3"
-CPPFLAGS += "-I${STAGING_INCDIR}/nspr4 -I${STAGING_INCDIR}/nss3"
-
-EXTRA_OECONF = "\
-    --with-nss=${STAGING_LIBDIR}/../.. --with-nspr=${STAGING_LIBDIR}/../.. \
-    "
-
-FILES_${PN}-dev += "${libdir}/xmlsec1Conf.sh"
-FILES_${PN}-dbg += "${PTEST_PATH}/.debug/*"
-
-RDEPENDS_${PN}-ptest += "${PN}-dev"
-INSANE_SKIP_${PN}-ptest += "dev-deps"
-
-PTEST_EXTRA_ARGS = "top_srcdir=${S} top_builddir=${B}"
-
-do_compile_ptest () {
-    oe_runmake -C ${S}/examples ${PTEST_EXTRA_ARGS} all
-}
-
-do_install_append() {
-    for i in ${bindir}/xmlsec1-config ${libdir}/xmlsec1Conf.sh \
-        ${libdir}/pkgconfig/xmlsec1-openssl.pc; do
-        sed -i -e "s@${RECIPE_SYSROOT}@@g" ${D}$i
-    done
-}
-
-do_install_ptest () {
-    oe_runmake -C ${S}/examples DESTDIR=${D}${PTEST_PATH} ${PTEST_EXTRA_ARGS} install-ptest
-}
diff --git a/meta-security/recipes-security/xmlsec1/xmlsec1_1.2.26.bb b/meta-security/recipes-security/xmlsec1/xmlsec1_1.2.26.bb
new file mode 100644
index 0000000..2dbbf33
--- /dev/null
+++ b/meta-security/recipes-security/xmlsec1/xmlsec1_1.2.26.bb
@@ -0,0 +1,56 @@
+SUMMARY = "XML Security Library is a C library based on LibXML2"
+DESCRIPTION = "\
+    XML Security Library is a C library based on \
+    LibXML2 and OpenSSL. The library was created with a goal to support major \
+    XML security standards "XML Digital Signature" and "XML Encryption". \
+    "
+HOMEPAGE = "http://www.aleksey.com/xmlsec/"
+DEPENDS = "libtool libxml2 libxslt openssl zlib libgcrypt gnutls nss nspr libgpg-error"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=352791d62092ea8104f085042de7f4d0"
+
+SECTION = "libs"
+
+SRC_URI = "http://www.aleksey.com/xmlsec/download/${BP}.tar.gz \
+    file://fix-ltmain.sh.patch \
+    file://change-finding-path-of-nss.patch \
+    file://makefile-ptest.patch \
+    file://xmlsec1-examples-allow-build-in-separate-dir.patch \
+    file://run-ptest \
+    "
+
+SRC_URI[md5sum] = "9c4aaf9ff615a73921b9e3bf4988d878"
+SRC_URI[sha256sum] = "8d8276c9c720ca42a3b0023df8b7ae41a2d6c5f9aa8d20ed1672d84cc8982d50"
+
+inherit autotools-brokensep ptest pkgconfig
+
+CFLAGS += "-I${STAGING_INCDIR}/nspr4 -I${STAGING_INCDIR}/nss3"
+CPPFLAGS += "-I${STAGING_INCDIR}/nspr4 -I${STAGING_INCDIR}/nss3"
+
+EXTRA_OECONF = "\
+    --with-nss=${STAGING_LIBDIR}/../.. --with-nspr=${STAGING_LIBDIR}/../.. \
+    "
+
+FILES_${PN}-dev += "${libdir}/xmlsec1Conf.sh"
+FILES_${PN}-dbg += "${PTEST_PATH}/.debug/*"
+
+RDEPENDS_${PN}-ptest += "${PN}-dev"
+INSANE_SKIP_${PN}-ptest += "dev-deps"
+
+PTEST_EXTRA_ARGS = "top_srcdir=${S} top_builddir=${B}"
+
+do_compile_ptest () {
+    oe_runmake -C ${S}/examples ${PTEST_EXTRA_ARGS} all
+}
+
+do_install_append() {
+    for i in ${bindir}/xmlsec1-config ${libdir}/xmlsec1Conf.sh \
+        ${libdir}/pkgconfig/xmlsec1-openssl.pc; do
+        sed -i -e "s@${RECIPE_SYSROOT}@@g" ${D}$i
+    done
+}
+
+do_install_ptest () {
+    oe_runmake -C ${S}/examples DESTDIR=${D}${PTEST_PATH} ${PTEST_EXTRA_ARGS} install-ptest
+}
diff --git a/meta-xilinx/meta-xilinx-bsp/README.building.md b/meta-xilinx/meta-xilinx-bsp/README.building.md
index e0e3f26..54d61c3 100644
--- a/meta-xilinx/meta-xilinx-bsp/README.building.md
+++ b/meta-xilinx/meta-xilinx-bsp/README.building.md
@@ -11,9 +11,14 @@
 	BBLAYERS ?= " \
 		<path to layer>/oe-core/meta \
 		<path to layer>/meta-xilinx-bsp \
+		<path to layer>/meta-xilinx-standalone \
 		<path to layer>/meta-xilinx-contrib \
 		"
 
+meta-xilinx-standalone layer provides recipes which enable building baremetal
+toolchain for PMU firmware. This layer is required for ZU+ devices which
+depends on PMU firmware
+
 meta-xilinx-contrib is a contribution layer and is optional.
 
 To build a specific target BSP configure the associated machine in `local.conf`:
@@ -27,6 +32,36 @@
 Once complete the images for the target machine will be available in the output
 directory `tmp/deploy/images/<machine name>/`.
 
+Using multiconfig to build ZU+
+------------------------------
+
+multiconfig dependency has to be added in image file or local.conf.
+For example in core-image-minimal you will need  
+do_image[mcdepends] = "multiconfig:zcu102:pmu:pmu-firmware:do_deploy"
+
+Add conf/multiconfig in the build directory and create pmu.conf and zcu102.conf
+
+Add the following in pmu.conf:  
+	MACHINE="zynqmp-pmu"  
+	DISTRO="xilinx-standalone"  
+    	GCCVERSION="7.%"  
+    	TMPDIR="${TOPDIR}/pmutmp"  
+
+Add the following in zcu102.conf:  
+	MACHINE="zcu102-zynqmp"  
+    	DISTRO="poky"  
+
+In local.conf multiconfig is enabled by: BBMULTICONFIG ?= "zcu102 pmu"
+
+bitbake multiconfig:zcu102:core-image-minimal  
+
+More information about multiconfig:
+https://www.yoctoproject.org/docs/current/mega-manual/mega-manual.html#dev-building-images-for-multiple-targets-using-multiple-configurations
+
+Workaround:  
+There is additional workaround required in u-boot-xlnx recipe. Add the below dependency  
+do_compile[mcdepends] = "multiconfig:zcu102:pmu:pmu-firmware:do_deploy"
+
 Additional Information
 ----------------------
 
diff --git a/meta-xilinx/meta-xilinx-bsp/classes/image-wic-utils.bbclass b/meta-xilinx/meta-xilinx-bsp/classes/image-wic-utils.bbclass
new file mode 100644
index 0000000..6f66d55
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/classes/image-wic-utils.bbclass
@@ -0,0 +1,51 @@
+# Helper/utility functions to work with the IMAGE_BOOT_FILES variable and its
+# expected behvaior with regards to the contents of the DEPLOY_DIR_IMAGE.
+#
+# The use of these functions assume that the deploy directory is populated with
+# any dependent files/etc. Such that the recipe using these functions depends
+# on the recipe that provides the files being used/queried.
+
+def boot_files_split_expand(d):
+    # IMAGE_BOOT_FILES has extra renaming info in the format '<source>;<target>'
+    for f in (d.getVar("IMAGE_BOOT_FILES") or "").split(" "):
+        parts = f.split(";", 1)
+        sources = [parts[0]]
+        if "*" in parts[0]:
+            # has glob part
+            import glob
+            deployroot = d.getVar("DEPLOY_DIR_IMAGE")
+            sources = []
+            for i in glob.glob(os.path.join(deployroot, parts[0])):
+                sources.append(os.path.basename(i))
+
+        # for all sources, yield an entry
+        for s in sources:
+            if len(parts) == 2:
+                yield s, parts[1]
+            yield s, s
+
+def boot_files_bitstream(d):
+    expectedfiles = [("bitstream", True)]
+    expectedexts = [(".bit", True), (".bin", False)]
+    # search for bitstream paths, use the renamed file. First matching is used
+    for source, target in boot_files_split_expand(d):
+        # skip boot.bin and u-boot.bin, it is not a bitstream
+        skip = ["boot.bin", "u-boot.bin"]
+        if source in skip or target in skip:
+            continue
+
+        for e, t in expectedfiles:
+            if source == e or target == e:
+                return target, t
+        for e, t in expectedexts:
+            if source.endswith(e) or target.endswith(e):
+                return target, t
+    return "", False
+
+def boot_files_dtb_filepath(d):
+    dtbs = (d.getVar("IMAGE_BOOT_FILES") or "").split(" ")
+    for source, target in boot_files_split_expand(d):
+        if target.endswith(".dtb"):
+            return target
+    return ""
+
diff --git a/meta-xilinx/meta-xilinx-bsp/classes/kernel-simpleimage.bbclass b/meta-xilinx/meta-xilinx-bsp/classes/kernel-simpleimage.bbclass
new file mode 100644
index 0000000..be70ffa
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/classes/kernel-simpleimage.bbclass
@@ -0,0 +1,22 @@
+python __anonymous () {
+    kerneltypes = set((d.getVar("KERNEL_IMAGETYPE") or "").split())
+    kerneltypes |= set((d.getVar("KERNEL_IMAGETYPES") or "").split())
+    if any(t.startswith("simpleImage.") for t in kerneltypes):
+        # Enable building of simpleImage
+        bb.build.addtask('do_prep_simpleimage', 'do_compile', 'do_configure', d)
+    uarch = d.getVar("UBOOT_ARCH")
+    if uarch == "microblaze":
+        d.appendVarFlag('do_prep_simpleimage', 'depends', ' virtual/dtb:do_populate_sysroot')
+}
+
+do_prep_simpleimage[dirs] += "${B}"
+do_prep_simpleimage () {
+    install -d ${B}/arch/${ARCH}/boot/dts
+    for type in ${KERNEL_IMAGETYPES} ; do
+        if [[ "${type}" =~ "simpleImage" ]] && [ ${ARCH} = "microblaze" ]; then
+            ext="${type##*.}"
+            cp ${RECIPE_SYSROOT}/boot/devicetree/${ext}.dtb ${B}/arch/${ARCH}/boot/dts/
+        fi
+    done
+}
+
diff --git a/meta-xilinx/meta-xilinx-bsp/classes/xilinx-testimage.bbclass b/meta-xilinx/meta-xilinx-bsp/classes/xilinx-testimage.bbclass
new file mode 100644
index 0000000..d9086ec
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/classes/xilinx-testimage.bbclass
@@ -0,0 +1,9 @@
+inherit testimage
+
+HOSTTOOLS += 'ip ping ps scp ssh stty'
+
+python do_testimage_prepend () {
+    from oeqa.core.target.qemu import supported_fstypes
+    supported_fstypes.append('wic.qemu-sd')
+}
+
diff --git a/meta-xilinx/meta-xilinx-bsp/classes/zynqmp-pmu.bbclass b/meta-xilinx/meta-xilinx-bsp/classes/zynqmp-pmu.bbclass
deleted file mode 100644
index 714eb96..0000000
--- a/meta-xilinx/meta-xilinx-bsp/classes/zynqmp-pmu.bbclass
+++ /dev/null
@@ -1,122 +0,0 @@
-#
-# This class handles configuring a recipe to build for the ZynqMP PMU
-# architecture. The reason for this class is due to limitations of multilib
-# with regards to multiple architectures (which do not work correctly).
-#
-# This class is specifically intended to extend the binutils-cross, gcc-cross,
-# newlib, libgloss and pmu-firmware recipes so that binaries can be emitted
-# which target the PMU architecture alongside building for the APU architecture
-# (ARM64). But the class can be applied globally via BBCLASSEXTEND in for
-# example a <machine>.conf.
-#
-# This class is almost the same as a multilib variant with custom TUNE_* setup
-# to allow for a switched TUNE_ARCH.
-#
-
-ORIG_TARGET_ARCH := "${TARGET_ARCH}"
-
-# zynqmp-pmu target arch (hardcoded based on pre-gen data from arch-microblaze.inc)
-DEFAULTTUNE = "microblaze"
-ABIEXTENSION = ""
-TUNE_ARCH = "microblazeel"
-#TUNE_FEATURES_tune-microblaze += "v9.2 barrel-shift pattern-compare"
-TUNE_CCARGS = "-mlittle-endian -mxl-barrel-shift -mxl-pattern-compare -mno-xl-reorder -mcpu=v9.2 -mxl-soft-mul -mxl-soft-div"
-TUNE_LDARGS = ""
-TUNE_ASARGS = ""
-TUNE_PKGARCH = "microblazeel-v9.2-bs-cmp"
-TARGET_OS = "elf"
-TARGET_FPU = "fpu-soft"
-
-# rebuild the MACHINE overrides
-MACHINEOVERRIDES = "${MACHINE}${@':${SOC_FAMILY}' if d.getVar('SOC_FAMILY') else ''}:microblaze"
-
-# override tune provided archs
-PACKAGE_EXTRA_ARCHS = "${TUNE_PKGARCH}"
-
-# baremetal equivalent config (note the tclibc is not included, this is purely
-# for recipes/etc that check for the value)
-TCLIBC = "baremetal"
-LIBCEXTENSION = ""
-LIBCOVERRIDE = ":libc-baremetal"
-USE_NLS = "no"
-IMAGE_LINGUAS = ""
-LIBC_DEPENDENCIES = ""
-
-# gcc-cross specific baremetal setup (due to the override order this is important)
-EXTRA_OECONF_pn-${MLPREFIX}gcc-cross-${TARGET_ARCH}_append = " --without-headers"
-
-EXTRA_OECONF_GCC_FLOAT = ""
-
-# Setup a multiarch like prefix.
-prefix = "/usr/${TARGET_SYS}"
-# Make sure GCC can search in the prefix dir (for libgcc)
-TOOLCHAIN_OPTIONS += "-B${RECIPE_SYSROOT}${includedir}/ -B${RECIPE_SYSROOT}${libdir}/"
-TOOLCHAIN_OPTIONS += "-I =${includedir} -L =${libdir}"
-
-python multitarget_zynqmp_pmu_virtclass_handler () {
-    variant = "zynqmp-pmu"
-    pn = d.getVar("PN")
-    if not (pn.startswith(variant + "-") or pn.endswith("-" + variant)):
-        return
-
-    if bb.data.inherits_class('native', e.data) or bb.data.inherits_class('nativesdk', e.data) or bb.data.inherits_class('crosssdk', e.data):
-        raise bb.parse.SkipPackage("Can't extend native/nativesdk/crosssdk recipes")
-
-    initialpn = e.data.getVar("PN").replace("-" + variant, "").replace(variant + "-", "")
-    e.data.setVar("MLPREFIX", variant + "-")
-    e.data.setVar("OVERRIDES", e.data.getVar("OVERRIDES", False) + ":virtclass-" + variant)
-
-    # hide multilib variants, this class is not one but this works around recipes thinking it is (due to MLPREFIX).
-    e.data.setVar("MULTILIB_VARIANTS", "")
-
-    # work around for -cross recipes that embed the TARGET_ARCH value
-    if bb.data.inherits_class('cross', e.data):
-        if initialpn.endswith("-" + d.getVar("ORIG_TARGET_ARCH")):
-            initialpn = initialpn.replace("-" + d.getVar("ORIG_TARGET_ARCH"), "-" + d.getVar("TARGET_ARCH"))
-
-    e.data.setVar("PN", variant + "-" + initialpn)
-}
-
-addhandler multitarget_zynqmp_pmu_virtclass_handler
-multitarget_zynqmp_pmu_virtclass_handler[eventmask] = "bb.event.RecipePreFinalise"
-
-python () {
-    variant = "zynqmp-pmu"
-    pn = d.getVar("PN")
-    if not pn.startswith(variant + "-"):
-        return
-
-    if pn.endswith("gcc-cross-" + d.getVar("TARGET_ARCH")):
-        # work around, DEPENDS _remove being immediate in gcc-cross
-        d.setVar("DEPENDS_remove", "virtual/%slibc-for-gcc" % d.getVar("TARGET_PREFIX"))
-
-    if pn.endswith("libgcc"):
-        # work around, strip depends on libc via do_package* tasks (this class cannot set ASSUME_PROVIDED += libc)
-        for i in ["do_package", "do_package_write_ipk", "do_package_write_deb", "do_package_write_rpm"]:
-            sanitized = " ".join([dep for dep in d.getVarFlag(i, "depends").split() if not dep.startswith("virtual/%s-libc" % variant)])
-            d.setVarFlag(i, "depends", sanitized)
-
-    import oe.classextend
-
-    clsextend = oe.classextend.ClassExtender(variant, d)
-
-    clsextend.map_depends_variable("DEPENDS")
-    clsextend.map_variable("PROVIDES")
-
-    clsextend.rename_packages()
-    clsextend.rename_package_variables((d.getVar("PACKAGEVARS") or "").split())
-
-    clsextend.map_packagevars()
-    clsextend.map_regexp_variable("PACKAGES_DYNAMIC")
-    clsextend.map_variable("PACKAGE_INSTALL")
-}
-
-# microblaze elf insane definitions not currently in insane.bbclass
-PACKAGEQA_EXTRA_MACHDEFFUNCS += "package_qa_get_machine_dict_microblazeelf"
-def package_qa_get_machine_dict_microblazeelf(machdata, d):
-    machdata["elf"] =  {
-                        "microblaze":  (189,   0,    0,          False,         32),
-                        "microblazeeb":(189,   0,    0,          False,         32),
-                        "microblazeel":(189,   0,    0,          True,          32),
-                      }
-    return machdata
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/layer.conf b/meta-xilinx/meta-xilinx-bsp/conf/layer.conf
index 55f6680..fc51165 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/layer.conf
+++ b/meta-xilinx/meta-xilinx-bsp/conf/layer.conf
@@ -11,5 +11,5 @@
 
 LAYERDEPENDS_xilinx = "core"
 
-LAYERSERIES_COMPAT_xilinx = "sumo"
+LAYERSERIES_COMPAT_xilinx = "sumo thud"
 
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/include/machine-xilinx-board.inc b/meta-xilinx/meta-xilinx-bsp/conf/machine/include/machine-xilinx-board.inc
index ba9a36b..17041e4 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/include/machine-xilinx-board.inc
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/include/machine-xilinx-board.inc
@@ -2,5 +2,3 @@
 
 EXTRA_IMAGEDEPENDS += "virtual/bootloader"
 
-IMAGE_BOOT_FILES ?= "${KERNEL_IMAGETYPE} ${UBOOT_BINARY}"
-
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/include/machine-xilinx-default.inc b/meta-xilinx/meta-xilinx-bsp/conf/machine/include/machine-xilinx-default.inc
index 77fbec8..153a47f 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/include/machine-xilinx-default.inc
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/include/machine-xilinx-default.inc
@@ -25,6 +25,14 @@
 UBOOT_ELF ?= "u-boot"
 UBOOT_ELF_aarch64 ?= "u-boot.elf"
 
+#Hardware accelaration
+PREFERRED_PROVIDER_virtual/libgles1_mali400 = "libmali-xlnx"
+PREFERRED_PROVIDER_virtual/libgles2_mali400 = "libmali-xlnx"
+PREFERRED_PROVIDER_virtual/egl_mali400 = "libmali-xlnx"
+PREFERRED_PROVIDER_virtual/libgl_mali400 = "mesa-gl"
+PREFERRED_PROVIDER_virtual/mesa_mali400 = "mesa-gl"
+
+
 XSERVER ?= " \
 	xserver-xorg \
 	xf86-input-evdev \
@@ -34,6 +42,35 @@
 	${XSERVER_EXT} \
 	"
 
+IMAGE_BOOT_FILES ?= "${@get_default_image_boot_files(d)}"
+
+def get_default_image_boot_files(d):
+    files = []
+
+    # kernel images
+    kerneltypes = set((d.getVar("KERNEL_IMAGETYPE") or "").split())
+    kerneltypes |= set((d.getVar("KERNEL_IMAGETYPES") or "").split())
+    for i in kerneltypes:
+        files.append(i)
+
+    # u-boot image
+    if d.getVar("UBOOT_BINARY"):
+        files.append(d.getVar("UBOOT_BINARY"))
+
+    # device trees (device-tree only), these are first as they are likely desired over the kernel ones
+    if "device-tree" in (d.getVar("MACHINE_ESSENTIAL_EXTRA_RDEPENDS") or ""):
+        files.append("devicetree/*.dtb")
+
+
+    # device trees (kernel only)
+    if d.getVar("KERNEL_DEVICETREE"):
+        dtbs = d.getVar("KERNEL_DEVICETREE").split(" ")
+        dtbs = [os.path.basename(d) for d in dtbs]
+        for dtb in dtbs:
+            files.append(dtb)
+
+    return " ".join(files)
+
 XSERVER_EXT ?= ""
 XSERVER_EXT_zynqmp ?= "xf86-video-armsoc"
 
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/include/machine-xilinx-qemu.inc b/meta-xilinx/meta-xilinx-bsp/conf/machine/include/machine-xilinx-qemu.inc
index dd275f3..5eb4b5c 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/include/machine-xilinx-qemu.inc
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/include/machine-xilinx-qemu.inc
@@ -8,15 +8,11 @@
     if d.getVar("IMAGE_BOOT_FILES", True):
         dtbs = d.getVar("IMAGE_BOOT_FILES", True).split(" ")
         # IMAGE_BOOT_FILES has extra renaming info in the format '<source>;<target>'
+        # Note: Wildcard sources work here only because runqemu expands them at run time
         dtbs = [f.split(";")[0] for f in dtbs]
         dtbs = [f for f in dtbs if f.endswith(".dtb")]
         if len(dtbs) != 0:
             return dtbs[0]
-    if d.getVar("KERNEL_DEVICETREE", True):
-        dtbs = d.getVar("KERNEL_DEVICETREE", True).split(" ")
-        dtbs = [os.path.basename(d) for d in dtbs]
-        if len(dtbs) != 0:
-            return d.getVar("KERNEL_IMAGETYPE", True) + "-" + dtbs[0]
     return ""
 
 def qemu_default_serial(d):
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/include/tune-versal.inc b/meta-xilinx/meta-xilinx-bsp/conf/machine/include/tune-versal.inc
new file mode 100644
index 0000000..83acf6e
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/include/tune-versal.inc
@@ -0,0 +1,14 @@
+DEFAULTTUNE ?= "aarch64"
+SOC_FAMILY ?= "versal"
+
+# Available SOC_VARIANT's for versal:
+# virt
+
+SOC_VARIANT ?= ""
+
+require conf/machine/include/arm/arch-armv8.inc
+require conf/machine/include/soc-family.inc
+
+# Linux Configuration
+KERNEL_IMAGETYPE ?= "Image"
+
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/include/zynqmp-pmu-config.inc b/meta-xilinx/meta-xilinx-bsp/conf/machine/include/zynqmp-pmu-config.inc
deleted file mode 100644
index fd9e980..0000000
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/include/zynqmp-pmu-config.inc
+++ /dev/null
@@ -1,20 +0,0 @@
-
-# Enable the use of zynqmp-pmu for specific recipes only
-def zynqmp_pmu_enable_for_bpns(d):
-    bpn = d.getVar("BPN")
-    crossbpns = ["binutils", "gcc"]
-    targetbpns = ["libgcc", "newlib", "libgloss"]
-    if bpn in targetbpns:
-        return True
-    if bpn in crossbpns and bb.data.inherits_class('cross', d):
-        return True
-    return False
-
-BBCLASSEXTEND_append = "${@' zynqmp-pmu' if zynqmp_pmu_enable_for_bpns(d) else ''}"
-
-# Add the pkgarch to the extra list, this is done to avoid warnings about
-# missing manifests due to implicit dependency chains on populate_sysroot when
-# a recipe/task depends on a IMAGE_EXTRADEPENDS/do_deploy task which is
-# provided by a zynqmp-pmu-* target.
-PACKAGE_EXTRA_ARCHS_append = " microblazeel-v9.2-bs-cmp"
-
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/kc705-microblazeel.conf b/meta-xilinx/meta-xilinx-bsp/conf/machine/kc705-microblazeel.conf
index b777c24..73ff40f 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/kc705-microblazeel.conf
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/kc705-microblazeel.conf
@@ -5,7 +5,6 @@
 
 require conf/machine/include/tune-microblaze.inc
 require conf/machine/include/machine-xilinx-default.inc
-require conf/machine/include/machine-xilinx-board.inc
 
 TUNE_FEATURES_tune-microblaze += "v10.0 barrel-shift reorder pattern-compare multiply-high divide-hard"
 
@@ -20,6 +19,6 @@
 PREFERRED_PROVIDER_virtual/kernel ?= "linux-xlnx"
 PREFERRED_PROVIDER_virtual/bootloader ?= "u-boot-xlnx"
 
-EXTRA_IMAGEDEPENDS += "virtual/bitstream"
+EXTRA_IMAGEDEPENDS += "virtual/bitstream virtual/bootloader"
 
 UBOOT_MACHINE ?= "microblaze-generic_config"
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/microzed-zynq7.conf b/meta-xilinx/meta-xilinx-bsp/conf/machine/microzed-zynq7.conf
index 9cc97ec..8869424 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/microzed-zynq7.conf
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/microzed-zynq7.conf
@@ -7,27 +7,26 @@
 require conf/machine/include/tune-zynq.inc
 require conf/machine/include/machine-xilinx-overrides.inc
 require conf/machine/include/machine-xilinx-default.inc
-require conf/machine/include/machine-xilinx-board.inc
 
 MACHINE_FEATURES = "ext2 vfat usbhost"
 
 # u-boot configuration
 PREFERRED_PROVIDER_virtual/bootloader = "u-boot"
 UBOOT_MACHINE = "zynq_microzed_config"
-SPL_BINARY = "spl/boot.bin"
+SPL_BINARY ?= "spl/boot.bin"
 
 EXTRA_IMAGEDEPENDS += " \
 		u-boot-zynq-uenv \
 		virtual/boot-bin \
+		virtual/bootloader \
 		"
 
 SERIAL_CONSOLE = "115200 ttyPS0"
 
-MACHINE_ESSENTIAL_EXTRA_RDEPENDS += "device-tree"
+KERNEL_DEVICETREE = "zynq-microzed.dtb"
 
 IMAGE_BOOT_FILES += " \
 		boot.bin \
-		${MACHINE}.dtb \
 		uEnv.txt \
 		"
 
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/picozed-zynq7.conf b/meta-xilinx/meta-xilinx-bsp/conf/machine/picozed-zynq7.conf
index 8762832..911bf90 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/picozed-zynq7.conf
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/picozed-zynq7.conf
@@ -11,18 +11,18 @@
 require conf/machine/include/tune-zynq.inc
 require conf/machine/include/machine-xilinx-overrides.inc
 require conf/machine/include/machine-xilinx-default.inc
-require conf/machine/include/machine-xilinx-board.inc
 
 MACHINE_FEATURES = "ext2 vfat usbhost usbgadget"
 
 # u-boot configuration
 PREFERRED_PROVIDER_virtual/bootloader = "u-boot"
 UBOOT_MACHINE = "zynq_picozed_config"
-SPL_BINARY = "spl/boot.bin"
+SPL_BINARY ?= "spl/boot.bin"
 
 EXTRA_IMAGEDEPENDS += " \
 		u-boot-zynq-uenv \
 		virtual/boot-bin \
+		virtual/bootloader \
 		"
 
 SERIAL_CONSOLE = "115200 ttyPS0"
@@ -31,7 +31,6 @@
 
 IMAGE_BOOT_FILES += " \
 		boot.bin \
-		${MACHINE}.dtb \
 		uEnv.txt \
 		"
 
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/qemu-zynq7.conf b/meta-xilinx/meta-xilinx-bsp/conf/machine/qemu-zynq7.conf
index 2c86edb..9725104 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/qemu-zynq7.conf
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/qemu-zynq7.conf
@@ -14,7 +14,6 @@
 SERIAL_CONSOLE = "115200 ttyPS0"
 
 MACHINE_ESSENTIAL_EXTRA_RDEPENDS += "device-tree"
-IMAGE_BOOT_FILES += "${MACHINE}.dtb"
 
 # Use the networking setup from qemuarm
 FILESOVERRIDES_append_pn-init-ifupdown = ":qemuarm"
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/zc702-zynq7.conf b/meta-xilinx/meta-xilinx-bsp/conf/machine/zc702-zynq7.conf
index 9b08d1b..fbd58a6 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/zc702-zynq7.conf
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/zc702-zynq7.conf
@@ -13,25 +13,28 @@
 require conf/machine/include/tune-zynq.inc
 require conf/machine/include/machine-xilinx-overrides.inc
 require conf/machine/include/machine-xilinx-default.inc
-require conf/machine/include/machine-xilinx-board.inc
 require conf/machine/include/machine-xilinx-qemu.inc
 
 MACHINE_FEATURES = "rtc ext2 ext3 vfat usbhost"
 
 # u-boot configuration
 UBOOT_MACHINE = "zynq_zc702_config"
-SPL_BINARY = "spl/boot.bin"
+SPL_BINARY ?= "spl/boot.bin"
 
 EXTRA_IMAGEDEPENDS += " \
 		u-boot-zynq-uenv \
 		virtual/boot-bin \
+		virtual/bootloader \
 		"
 
 SERIAL_CONSOLE = "115200 ttyPS0"
 
 KERNEL_DEVICETREE = "zynq-zc702.dtb"
 
-IMAGE_BOOT_FILES += "boot.bin uEnv.txt ${KERNEL_IMAGETYPE}-zynq-zc702.dtb"
+IMAGE_BOOT_FILES += " \
+		boot.bin \
+		uEnv.txt \
+		"
 
 # Although not fully supported you can run this machine on the mainline QEMU 'xilinx-zynq-a9' machine
 IMAGE_CLASSES += "qemuboot"
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/zc706-zynq7.conf b/meta-xilinx/meta-xilinx-bsp/conf/machine/zc706-zynq7.conf
index 628d404..741ef5d 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/zc706-zynq7.conf
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/zc706-zynq7.conf
@@ -14,18 +14,18 @@
 require conf/machine/include/tune-zynq.inc
 require conf/machine/include/machine-xilinx-overrides.inc
 require conf/machine/include/machine-xilinx-default.inc
-require conf/machine/include/machine-xilinx-board.inc
 require conf/machine/include/machine-xilinx-qemu.inc
 
 MACHINE_FEATURES = "rtc ext2 ext3 vfat usbhost usbgadget"
 
 # u-boot configuration
 UBOOT_MACHINE = "zynq_zc706_config"
-SPL_BINARY = "spl/boot.bin"
+SPL_BINARY ?= "spl/boot.bin"
 
 EXTRA_IMAGEDEPENDS += " \
 		u-boot-zynq-uenv \
 		virtual/boot-bin \
+		virtual/bootloader \
 		"
 
 SERIAL_CONSOLE = "115200 ttyPS0"
@@ -34,7 +34,6 @@
 
 IMAGE_BOOT_FILES += " \
 		boot.bin \
-		${KERNEL_IMAGETYPE}-zynq-zc706.dtb \
 		uEnv.txt \
 		"
 
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/zcu102-zynqmp.conf b/meta-xilinx/meta-xilinx-bsp/conf/machine/zcu102-zynqmp.conf
index d7f19ca..fba55a3 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/zcu102-zynqmp.conf
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/zcu102-zynqmp.conf
@@ -7,14 +7,12 @@
 require conf/machine/include/tune-zynqmp.inc
 require conf/machine/include/machine-xilinx-overrides.inc
 require conf/machine/include/machine-xilinx-default.inc
-require conf/machine/include/machine-xilinx-board.inc
 require conf/machine/include/machine-xilinx-qemu.inc
-include conf/machine/include/zynqmp-pmu-config.inc
 
 MACHINE_FEATURES = "rtc ext2 ext3 vfat usbhost"
 
 UBOOT_MACHINE = "xilinx_zynqmp_zcu102_rev1_0_defconfig"
-SPL_BINARY = "spl/boot.bin"
+SPL_BINARY ?= "spl/boot.bin"
 
 # Default SD image build onfiguration, use qemu-sd to pad
 IMAGE_CLASSES += "image-types-xilinx-qemu"
@@ -28,23 +26,25 @@
 
 PREFERRED_PROVIDER_virtual/kernel ?= "linux-xlnx"
 PREFERRED_PROVIDER_virtual/bootloader ?= "u-boot-xlnx"
-PREFERRED_PROVIDER_virtual/pmu-firmware ?= "zynqmp-pmu-pmu-firmware"
 
 EXTRA_IMAGEDEPENDS += " \
 		u-boot-zynq-uenv \
 		arm-trusted-firmware \
 		qemu-devicetrees \
-		virtual/pmu-firmware \
 		virtual/boot-bin \
+		virtual/bootloader \
 		"
 
-IMAGE_BOOT_FILES += "uEnv.txt atf-uboot.ub ${KERNEL_IMAGETYPE}-zynqmp-zcu102-rev1.0.dtb"
+IMAGE_BOOT_FILES += " \
+		uEnv.txt \
+		atf-uboot.ub \
+		"
 
 # This machine has a QEMU model, runqemu setup:
 IMAGE_CLASSES += "qemuboot-xilinx"
 QB_MACHINE = "-machine xlnx-zcu102"
 QB_MEM = "-m 4096"
-QB_OPT_APPEND = "-nographic -serial mon:stdio -serial null"
+QB_OPT_APPEND ?= "-nographic -serial mon:stdio -serial null"
 QB_NETWORK_DEVICE = "-net nic -net nic -net nic -net nic,netdev=net0,macaddr=@MAC@"
 
 # Use qemu-xilinx instead of mainline
@@ -68,14 +68,18 @@
 
 # PMU instance args
 PMU_ROM ?= "${DEPLOY_DIR_IMAGE}/pmu-rom.elf"
+PMU_FIRMWARE_DEPLOY_DIR ?= "${TOPDIR}/pmutmp/deploy/images/zynqmp-pmu"
+PMU_FIRMWARE_IMAGE_NAME ?= "pmu-firmware-zynqmp-pmu"
+
 QB_PMU_OPT = " \
 		-M microblaze-fdt \
 		-display none \
 		-hw-dtb ${DEPLOY_DIR_IMAGE}/qemu-hw-devicetrees/multiarch/zynqmp-pmu.dtb \
 		-kernel ${PMU_ROM} \
-		-device loader,file=${DEPLOY_DIR_IMAGE}/pmu-firmware-${MACHINE}.elf \
+		-device loader,file=${PMU_FIRMWARE_DEPLOY_DIR}/${PMU_FIRMWARE_IMAGE_NAME}.elf \
 		-device loader,addr=0xfd1a0074,data=0x1011003,data-len=4 \
 		-device loader,addr=0xfd1a007C,data=0x1010f03,data-len=4 \
 		"
 QB_OPT_APPEND_append_qemuboot-xilinx = " -pmu-args '${QB_PMU_OPT}'"
 
+do_write_qemuboot_conf[depends] += "u-boot-zynq-uenv:do_deploy"
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/zcu104-zynqmp.conf b/meta-xilinx/meta-xilinx-bsp/conf/machine/zcu104-zynqmp.conf
index f5a2af9..c4b4a03 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/zcu104-zynqmp.conf
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/zcu104-zynqmp.conf
@@ -8,13 +8,11 @@
 require conf/machine/include/tune-zynqmp.inc
 require conf/machine/include/machine-xilinx-overrides.inc
 require conf/machine/include/machine-xilinx-default.inc
-require conf/machine/include/machine-xilinx-board.inc
-include conf/machine/include/zynqmp-pmu-config.inc
 
 MACHINE_FEATURES = "rtc ext2 ext3 vfat usbhost"
 
 UBOOT_MACHINE = "xilinx_zynqmp_zcu104_revC_defconfig"
-SPL_BINARY = "spl/boot.bin"
+SPL_BINARY ?= "spl/boot.bin"
 
 SERIAL_CONSOLE ?= "115200 ttyPS0"
 
@@ -24,15 +22,20 @@
 
 PREFERRED_PROVIDER_virtual/kernel ?= "linux-xlnx"
 PREFERRED_PROVIDER_virtual/bootloader ?= "u-boot-xlnx"
-PREFERRED_PROVIDER_virtual/pmu-firmware ?= "zynqmp-pmu-pmu-firmware"
+
+PMU_FIRMWARE_IMAGE_NAME ?= "pmu-firmware-zynqmp-pmu"
+PMU_FIRMWARE_DEPLOY_DIR ?= "${TOPDIR}/pmutmp/deploy/images/zynqmp-pmu"
 
 EXTRA_IMAGEDEPENDS += " \
 		u-boot-zynq-uenv \
 		arm-trusted-firmware \
-		virtual/pmu-firmware \
 		virtual/boot-bin \
+		virtual/bootloader \
 		"
-IMAGE_BOOT_FILES += "uEnv.txt atf-uboot.ub ${KERNEL_IMAGETYPE}-zynqmp-zcu104-revC.dtb"
+IMAGE_BOOT_FILES += " \
+		uEnv.txt \
+		atf-uboot.ub \
+		"
 
 MACHINE_HWCODECS = "libomxil-xlnx"
 
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/zcu106-zynqmp.conf b/meta-xilinx/meta-xilinx-bsp/conf/machine/zcu106-zynqmp.conf
index 628ec6c..136efb9 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/zcu106-zynqmp.conf
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/zcu106-zynqmp.conf
@@ -7,13 +7,11 @@
 require conf/machine/include/tune-zynqmp.inc
 require conf/machine/include/machine-xilinx-overrides.inc
 require conf/machine/include/machine-xilinx-default.inc
-require conf/machine/include/machine-xilinx-board.inc
-include conf/machine/include/zynqmp-pmu-config.inc
 
 MACHINE_FEATURES = "rtc ext2 ext3 vfat usbhost"
 
 UBOOT_MACHINE = "xilinx_zynqmp_zcu106_revA_defconfig"
-SPL_BINARY = "spl/boot.bin"
+SPL_BINARY ?= "spl/boot.bin"
 
 SERIAL_CONSOLE = "115200 ttyPS0"
 SERIAL_CONSOLES_CHECK = "${SERIAL_CONSOLES}"
@@ -22,15 +20,20 @@
 
 PREFERRED_PROVIDER_virtual/kernel ?= "linux-xlnx"
 PREFERRED_PROVIDER_virtual/bootloader ?= "u-boot-xlnx"
-PREFERRED_PROVIDER_virtual/pmu-firmware ?= "zynqmp-pmu-pmu-firmware"
+
+PMU_FIRMWARE_IMAGE_NAME ?= "pmu-firmware-zynqmp-pmu"
+PMU_FIRMWARE_DEPLOY_DIR ?= "${TOPDIR}/pmutmp/deploy/images/zynqmp-pmu"
 
 EXTRA_IMAGEDEPENDS += " \
 		u-boot-zynq-uenv \
 		arm-trusted-firmware \
-		virtual/pmu-firmware \
 		virtual/boot-bin \
+		virtual/bootloader \
 		"
 
-IMAGE_BOOT_FILES += "uEnv.txt atf-uboot.ub ${KERNEL_IMAGETYPE}-zynqmp-zcu106-revA.dtb"
+IMAGE_BOOT_FILES += " \
+		uEnv.txt \
+		atf-uboot.ub \
+		"
 
 MACHINE_HWCODECS = "libomxil-xlnx"
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/zedboard-zynq7.conf b/meta-xilinx/meta-xilinx-bsp/conf/machine/zedboard-zynq7.conf
index a329074..36c51b7 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/zedboard-zynq7.conf
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/zedboard-zynq7.conf
@@ -13,20 +13,23 @@
 require conf/machine/include/tune-zynq.inc
 require conf/machine/include/machine-xilinx-overrides.inc
 require conf/machine/include/machine-xilinx-default.inc
-require conf/machine/include/machine-xilinx-board.inc
 
 # u-boot configuration
 UBOOT_MACHINE = "zynq_zed_config"
-SPL_BINARY = "spl/boot.bin"
+SPL_BINARY ?= "spl/boot.bin"
 
 EXTRA_IMAGEDEPENDS += " \
 		u-boot-zynq-uenv \
 		virtual/boot-bin \
+		virtual/bootloader \
 		"
 
 SERIAL_CONSOLE = "115200 ttyPS0"
 
 KERNEL_DEVICETREE = "zynq-zed.dtb"
 
-IMAGE_BOOT_FILES += "boot.bin uEnv.txt ${KERNEL_IMAGETYPE}-zynq-zed.dtb"
+IMAGE_BOOT_FILES += " \
+		boot.bin \
+		uEnv.txt \
+		"
 
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/zybo-linux-bd-zynq7.conf b/meta-xilinx/meta-xilinx-bsp/conf/machine/zybo-linux-bd-zynq7.conf
index 27b6d07..ba355d5 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/zybo-linux-bd-zynq7.conf
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/zybo-linux-bd-zynq7.conf
@@ -10,7 +10,6 @@
 require conf/machine/include/tune-zynq.inc
 require conf/machine/include/machine-xilinx-overrides.inc
 require conf/machine/include/machine-xilinx-default.inc
-require conf/machine/include/machine-xilinx-board.inc
 
 PREFERRED_PROVIDER_virtual/kernel ?= "linux-xlnx"
 PREFERRED_PROVIDER_virtual/bootloader ?= "u-boot"
@@ -21,18 +20,18 @@
 MACHINE_ESSENTIAL_EXTRA_RDEPENDS += "device-tree"
 
 UBOOT_MACHINE = "zynq_zybo_config"
-SPL_BINARY = "spl/boot.bin"
+SPL_BINARY ?= "spl/boot.bin"
 FORCE_PLATFORM_INIT = "1"
 
 EXTRA_IMAGEDEPENDS += " \
 		u-boot-zynq-uenv \
 		virtual/boot-bin \
 		virtual/bitstream \
+		virtual/bootloader \
 		"
 
 IMAGE_BOOT_FILES += " \
 		boot.bin \
-		${MACHINE}.dtb \
 		bitstream \
 		uEnv.txt \
 		"
diff --git a/meta-xilinx/meta-xilinx-bsp/conf/machine/zybo-zynq7.conf b/meta-xilinx/meta-xilinx-bsp/conf/machine/zybo-zynq7.conf
index 5b40563..049add9 100644
--- a/meta-xilinx/meta-xilinx-bsp/conf/machine/zybo-zynq7.conf
+++ b/meta-xilinx/meta-xilinx-bsp/conf/machine/zybo-zynq7.conf
@@ -11,18 +11,18 @@
 require conf/machine/include/tune-zynq.inc
 require conf/machine/include/machine-xilinx-overrides.inc
 require conf/machine/include/machine-xilinx-default.inc
-require conf/machine/include/machine-xilinx-board.inc
 
 MACHINE_FEATURES = "ext2 vfat usbhost usbgadget"
 
 # u-boot configuration
 PREFERRED_PROVIDER_virtual/bootloader = "u-boot"
 UBOOT_MACHINE = "zynq_zybo_config"
-SPL_BINARY = "spl/boot.bin"
+SPL_BINARY ?= "spl/boot.bin"
 
 EXTRA_IMAGEDEPENDS += " \
 		u-boot-zynq-uenv \
 		virtual/boot-bin \
+		virtual/bootloader \
 		"
 
 SERIAL_CONSOLE = "115200 ttyPS0"
@@ -31,7 +31,6 @@
 
 IMAGE_BOOT_FILES += " \
 		boot.bin \
-		${KERNEL_IMAGETYPE}-zynq-zybo.dtb \
 		uEnv.txt \
 		"
 
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/arm-trusted-firmware/arm-trusted-firmware.inc b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/arm-trusted-firmware/arm-trusted-firmware.inc
index 02bbc73..d64fad9 100644
--- a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/arm-trusted-firmware/arm-trusted-firmware.inc
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/arm-trusted-firmware/arm-trusted-firmware.inc
@@ -1,7 +1,7 @@
 DESCRIPTION = "ARM Trusted Firmware"
 
 LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://license.rst;md5=33065335ea03d977d0569f270b39603e"
+LIC_FILES_CHKSUM = "file://license.rst;md5=e927e02bca647e14efd87e9e914b2443"
 
 PROVIDES = "virtual/arm-trusted-firmware"
 
@@ -28,6 +28,7 @@
 COMPATIBLE_MACHINE = "zynqmp"
 PLATFORM_zynqmp = "zynqmp"
 
+
 # requires CROSS_COMPILE set by hand as there is no configure script
 export CROSS_COMPILE="${TARGET_PREFIX}"
 
@@ -37,8 +38,23 @@
 AS[unexport] = "1"
 LD[unexport] = "1"
 
+ATF_CONSOLE ?= ""
+ATF_CONSOLE_zynqmp = "cadence"
+
+DEBUG ?= ""
+EXTRA_OEMAKE_zynqmp_append = "${@' ZYNQMP_CONSOLE=${ATF_CONSOLE}' if d.getVar('ATF_CONSOLE', True) != '' else ''}"
+EXTRA_OEMAKE_append = " ${@bb.utils.contains('DEBUG', '1', ' DEBUG=${DEBUG}', '', d)}"
+
+OUTPUT_DIR = "${@bb.utils.contains('DEBUG', '1', '${B}/${PLATFORM}/debug', '${B}/${PLATFORM}/release', d)}"
+
+ATF_MEM_BASE ?= ""
+ATF_MEM_SIZE ?= ""
+
+EXTRA_OEMAKE_zynqmp_append = "${@' ZYNQMP_ATF_MEM_BASE=${ATF_MEM_BASE}' if d.getVar('ATF_MEM_BASE', True) != '' else ''}"
+EXTRA_OEMAKE_zynqmp_append = "${@' ZYNQMP_ATF_MEM_SIZE=${ATF_MEM_SIZE}' if d.getVar('ATF_MEM_SIZE', True) != '' else ''}"
+
 do_configure() {
-	:
+	oe_runmake clean -C ${S} BUILD_BASE=${B} PLAT=${PLATFORM}
 }
 
 do_compile() {
@@ -49,8 +65,6 @@
 	:
 }
 
-OUTPUT_DIR = "${B}/${PLATFORM}/release"
-
 do_deploy() {
 	install -d ${DEPLOYDIR}
 	install -m 0644 ${OUTPUT_DIR}/bl31/bl31.elf ${DEPLOYDIR}/${ATF_BASE_NAME}.elf
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/arm-trusted-firmware/arm-trusted-firmware_2018.1.bb b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/arm-trusted-firmware/arm-trusted-firmware_2018.1.bb
deleted file mode 100644
index 6a9eea6..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/arm-trusted-firmware/arm-trusted-firmware_2018.1.bb
+++ /dev/null
@@ -1,7 +0,0 @@
-ATF_VERSION = "1.4"
-XILINX_RELEASE_VERSION = "v2018.1"
-BRANCH ?= "master"
-SRCREV ?= "df4a7e97d57494c7d79de51b1e0e450d982cea98"
-
-include arm-trusted-firmware.inc
-
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/arm-trusted-firmware/arm-trusted-firmware_2018.3.bb b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/arm-trusted-firmware/arm-trusted-firmware_2018.3.bb
new file mode 100644
index 0000000..8c8a5d0
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/arm-trusted-firmware/arm-trusted-firmware_2018.3.bb
@@ -0,0 +1,7 @@
+ATF_VERSION = "1.5"
+XILINX_RELEASE_VERSION = "v2018.3"
+BRANCH ?= "master"
+SRCREV ?= "08560c36ea5b6f48b962cb4bd9a79b35bb3d95ce"
+
+include arm-trusted-firmware.inc
+
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/device-tree/device-tree.bb b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/device-tree/device-tree.bb
index dc49cbb..81965c1 100644
--- a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/device-tree/device-tree.bb
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/device-tree/device-tree.bb
@@ -1,85 +1,39 @@
-SUMMARY = "Device Trees for BSPs"
-DESCRIPTION = "Device Tree generation and packaging for BSP Device Trees."
+SUMMARY = "Xilinx BSP device trees"
+DESCRIPTION = "Xilinx BSP device trees from within layer."
 SECTION = "bsp"
 
+# the device trees from within the layer are licensed as MIT, kernel includes are GPL
 LICENSE = "MIT & GPLv2"
 LIC_FILES_CHKSUM = " \
 		file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302 \
 		file://${COMMON_LICENSE_DIR}/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6 \
 		"
 
-inherit deploy kernel-arch
+inherit devicetree
 
 PROVIDES = "virtual/dtb"
 
-INHIBIT_DEFAULT_DEPS = "1"
-DEPENDS += "dtc-native"
+# common zynq include
+SRC_URI_append_zynq = " file://zynq-7000-qspi-dummy.dtsi"
 
-COMPATIBLE_MACHINE ?= "^$"
+# device tree sources for the various machines
+COMPATIBLE_MACHINE_picozed-zynq7 = ".*"
+SRC_URI_append_picozed-zynq7 = " file://picozed-zynq7.dts"
 
-PACKAGE_ARCH = "${MACHINE_ARCH}"
+COMPATIBLE_MACHINE_qemu-zynq7 = ".*"
+SRC_URI_append_qemu-zynq7 = " file://qemu-zynq7.dts"
 
-FILES_${PN} = "/boot/devicetree/*.dtb /boot/devicetree/*.dtbo"
-
-S = "${WORKDIR}"
-B = "${WORKDIR}/build"
-
-SYSROOT_DIRS += "/boot/devicetree"
-
-# By default provide the current kernel arch's boot/dts and boot/dts/include.
-KERNEL_DTS_INCLUDE ??= " \
-		${STAGING_KERNEL_DIR}/arch/${ARCH}/boot/dts \
-		${STAGING_KERNEL_DIR}/arch/${ARCH}/boot/dts/include \
-		"
-# For arm64/zynqmp the xilinx specific includes are subdired under a vendor directory.
-KERNEL_DTS_INCLUDE_append_zynqmp = " \
-		${STAGING_KERNEL_DIR}/arch/${ARCH}/boot/dts/xilinx \
+COMPATIBLE_MACHINE_zybo-linux-bd-zynq7 = ".*"
+SRC_URI_append_zybo-linux-bd-zynq7 = " \
+		file://zybo-linux-bd-zynq7.dts \
+		file://pcw.dtsi \
+		file://pl.dtsi \
 		"
 
-DTS_FILES_PATH ?= "${S}"
-DTS_INCLUDE ?= "${DTS_FILES_PATH} ${KERNEL_DTS_INCLUDE}"
-
-DT_PADDING_SIZE ?= "0x3000"
-DEVICETREE_FLAGS ?= " \
-		-R 8 -p ${DT_PADDING_SIZE} -b 0 \
-		${@' '.join(['-i %s' % i for i in d.getVar('DTS_INCLUDE', True).split()])} \
-               "
-DEVICETREE_OFLAGS ?= "-@ -H epapr"
-DEVICETREE_PP_FLAGS ?= " \
-		-nostdinc -Ulinux -x assembler-with-cpp \
-		${@' '.join(['-I%s' % i for i in d.getVar('DTS_INCLUDE', True).split()])} \
+COMPATIBLE_MACHINE_kc705-microblazeel = ".*"
+SRC_URI_append_kc705-microblazeel = " \
+		file://kc705-microblazeel.dts \
+		file://pl.dtsi \
+		file://system-conf.dtsi \
 		"
 
-python () {
-    # auto add dependency on kernel tree
-    if d.getVar("KERNEL_DTS_INCLUDE") != "":
-        d.appendVarFlag("do_compile", "depends", " virtual/kernel:do_configure")
-}
-
-do_compile() {
-	for DTS_FILE in ${DTS_FILES_PATH}/*.dts; do
-		DTS_NAME=`basename -s .dts ${DTS_FILE}`
-		${BUILD_CPP} ${DEVICETREE_PP_FLAGS} -o `basename ${DTS_FILE}`.pp ${DTS_FILE}
-
-		# for now use the existance of the '/plugin/' tag to detect overlays
-		if grep -qse "/plugin/;" `basename ${DTS_FILE}`.pp; then
-			dtc ${DEVICETREE_OFLAGS} -I dts -O dtb ${DEVICETREE_FLAGS} -o ${DTS_NAME}.dtbo `basename ${DTS_FILE}`.pp
-		else
-			dtc -I dts -O dtb ${DEVICETREE_FLAGS} -o ${DTS_NAME}.dtb `basename ${DTS_FILE}`.pp
-		fi
-	done
-}
-
-do_install() {
-	for DTB_FILE in `ls *.dtb *.dtbo`; do
-		install -Dm 0644 ${B}/${DTB_FILE} ${D}/boot/devicetree/${DTB_FILE}
-	done
-}
-
-do_deploy() {
-	for DTB_FILE in `ls *.dtb *.dtbo`; do
-		install -Dm 0644 ${B}/${DTB_FILE} ${DEPLOYDIR}/${DTB_FILE}
-	done
-}
-addtask deploy before do_build after do_install
-
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/device-tree/device-tree.bbappend b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/device-tree/device-tree.bbappend
deleted file mode 100644
index e128e0e..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/device-tree/device-tree.bbappend
+++ /dev/null
@@ -1,30 +0,0 @@
-
-FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
-
-# common zynq include
-SRC_URI_append_zynq = " file://zynq-7000-qspi-dummy.dtsi"
-
-# device tree sources for the various machines
-COMPATIBLE_MACHINE_picozed-zynq7 = ".*"
-SRC_URI_append_picozed-zynq7 = " file://picozed-zynq7.dts"
-
-COMPATIBLE_MACHINE_microzed-zynq7 = ".*"
-SRC_URI_append_microzed-zynq7 = " file://microzed-zynq7.dts"
-
-COMPATIBLE_MACHINE_qemu-zynq7 = ".*"
-SRC_URI_append_qemu-zynq7 = " file://qemu-zynq7.dts"
-
-COMPATIBLE_MACHINE_zybo-linux-bd-zynq7 = ".*"
-SRC_URI_append_zybo-linux-bd-zynq7 = " \
-		file://zybo-linux-bd-zynq7.dts \
-		file://pcw.dtsi \
-		file://pl.dtsi \
-		"
-
-COMPATIBLE_MACHINE_kc705-microblazeel = ".*"
-SRC_URI_append_kc705-microblazeel = " \
-		file://kc705-microblazeel.dts \
-		file://pl.dtsi \
-		file://system-conf.dtsi \
-		"
-
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/device-tree/files/microzed-zynq7.dts b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/device-tree/files/microzed-zynq7.dts
deleted file mode 100644
index b9376a4..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/device-tree/files/microzed-zynq7.dts
+++ /dev/null
@@ -1,96 +0,0 @@
-/*
- * Copyright (C) 2011 - 2014 Xilinx
- * Copyright (C) 2016 Jagan Teki <jteki@openedev.com>
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- */
-/dts-v1/;
-/include/ "zynq-7000.dtsi"
-
-/ {
-	model = "Zynq MicroZED Development Board";
-	compatible = "xlnx,zynq-microzed", "xlnx,zynq-7000";
-
-	aliases {
-		ethernet0 = &gem0;
-		serial0 = &uart1;
-	};
-
-	memory {
-		device_type = "memory";
-		reg = <0x0 0x40000000>;
-	};
-
-	chosen {
-		bootargs = "earlycon";
-		stdout-path = "serial0:115200n8";
-	};
-
-	usb_phy0: phy0 {
-		compatible = "usb-nop-xceiv";
-		#phy-cells = <0>;
-	};
-};
-
-&clkc {
-	ps-clk-frequency = <33333333>;
-};
-
-&gem0 {
-	status = "okay";
-	phy-mode = "rgmii-id";
-	phy-handle = <&ethernet_phy>;
-
-	ethernet_phy: ethernet-phy@0 {
-		reg = <0>;
-	};
-};
-
-&sdhci0 {
-	status = "okay";
-};
-
-&uart1 {
-	status = "okay";
-};
-
-&usb0 {
-	status = "okay";
-	dr_mode = "host";
-	usb-phy = <&usb_phy0>;
-	pinctrl-names = "default";
-	pinctrl-0 = <&pinctrl_usb0_default>;
-};
-
-&pinctrl0 {
-	pinctrl_usb0_default: usb0-default {
-		mux {
-			groups = "usb0_0_grp";
-			function = "usb0";
-		};
-
-		conf {
-			groups = "usb0_0_grp";
-			slew-rate = <0>;
-			io-standard = <1>;
-		};
-
-		conf-rx {
-			pins = "MIO29", "MIO31", "MIO36";
-			bias-high-impedance;
-		};
-
-		conf-tx {
-			pins = "MIO28", "MIO30", "MIO32", "MIO33", "MIO34",
-			       "MIO35", "MIO37", "MIO38", "MIO39";
-			bias-disable;
-		};
-	};
-};
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/pmu-firmware/pmu-firmware_2018.1.bb b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/pmu-firmware/pmu-firmware_2018.1.bb
deleted file mode 100644
index e54e103..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/pmu-firmware/pmu-firmware_2018.1.bb
+++ /dev/null
@@ -1,99 +0,0 @@
-SUMMARY = "Firmware for the PMU on the ZynqMP Programmable Silicon"
-HOMEPAGE = "https://github.com/Xilinx/embeddedsw"
-SECTION = "bsp"
-
-INHIBIT_DEFAULT_DEPS = "1"
-DEPENDS = "virtual/${TARGET_PREFIX}gcc newlib libgloss libgcc"
-
-# force this recipe to provide a target virtual/pmu-firmware. this is applied
-# after any class extender mapping and results in this recipe always providing
-# 'virtual/pmu-firmware'.
-python append_target_provides () {
-    d.appendVar("PROVIDES", " virtual/pmu-firmware")
-}
-addhandler append_target_provides
-append_target_provides[eventmask] = "bb.event.RecipeParsed"
-
-# This source links in a number of components with differing licenses, and some
-# licenses are not Open Source compatible. Additionally the pmu-firmware source
-# itself is licensed under a modified MIT license which restricts use to Xilinx
-# devices only.
-LICENSE = "Proprietary"
-LIC_FILES_CHKSUM = "file://../../../../license.txt;md5=04841c5ad8409b474da7180de5391926"
-
-inherit deploy
-
-XILINX_RELEASE_VERSION = "v2018.1"
-SRCREV = "aaa566bc3fa19255de4d434ebfa57ae3a9d261b2"
-PV = "${XILINX_RELEASE_VERSION}+git${SRCPV}"
-
-SRC_URI = "git://github.com/Xilinx/embeddedsw.git;protocol=https;nobranch=1"
-
-COMPATIBLE_HOST = "microblaze.*-elf"
-COMPATIBLE_MACHINE = "^$"
-COMPATIBLE_MACHINE_zynqmp = "zynqmp"
-
-PACKAGE_ARCH = "${MACHINE_ARCH}"
-
-S = "${WORKDIR}/git/lib/sw_apps/zynqmp_pmufw/src"
-
-# The makefile does not handle parallelization
-PARALLEL_MAKE = ""
-
-do_configure() {
-	# manually do the copy_bsp step first, so as to be able to fix up use of
-	# mb-* commands
-	${S}/../misc/copy_bsp.sh
-}
-
-COMPILER = "${CC}"
-COMPILER_FLAGS = "-O2 -c"
-EXTRA_COMPILER_FLAGS = "-g -Wall -Wextra -Os -flto -ffat-lto-objects"
-ARCHIVER = "${AR}"
-
-# HACK: fix the dirty bug where xilsecure wants to call this PSVersion
-# function, which is not implemented for microblaze. The symbols never make it
-# into the final elf as the xilsecure function that uses it is not called in
-# pmufw.
-EXTRA_COMPILER_FLAGS_append = " -DXGetPSVersion_Info=atexit"
-
-BSP_DIR ?= "${S}/../misc/zynqmp_pmufw_bsp"
-BSP_TARGETS_DIR ?= "${BSP_DIR}/psu_pmu_0/libsrc"
-
-def bsp_make_vars(d):
-    s = ["COMPILER", "CC", "COMPILER_FLAGS", "EXTRA_COMPILER_FLAGS", "ARCHIVER", "AR", "AS"]
-    return " ".join(["\"%s=%s\"" % (v, d.getVar(v)) for v in s])
-
-do_compile() {
-	# the Makefile in ${S}/../misc/Makefile, does not handle CC, AR, AS, etc
-	# properly. So do its job manually. Preparing the includes first, then libs.
-	for i in $(ls ${BSP_TARGETS_DIR}/*/src/Makefile); do
-		oe_runmake -C $(dirname $i) -s include ${@bsp_make_vars(d)}
-	done
-	for i in $(ls ${BSP_TARGETS_DIR}/*/src/Makefile); do
-		oe_runmake -C $(dirname $i) -s libs ${@bsp_make_vars(d)}
-	done
-
-	# --build-id=none is required due to linker script not defining a location for it.
-	oe_runmake CC="${CC}" CC_FLAGS="-MMD -MP -Wl,--build-id=none"
-}
-
-do_install() {
-	:
-}
-
-PMU_FIRMWARE_BASE_NAME ?= "${BPN}-${PKGE}-${PKGV}-${PKGR}-${MACHINE}-${DATETIME}"
-PMU_FIRMWARE_BASE_NAME[vardepsexclude] = "DATETIME"
-
-do_deploy() {
-	install -Dm 0644 ${B}/executable.elf ${DEPLOYDIR}/${PMU_FIRMWARE_BASE_NAME}.elf
-	ln -sf ${PMU_FIRMWARE_BASE_NAME}.elf ${DEPLOYDIR}/${BPN}-${MACHINE}.elf
-	ln -sf ${BPN}-${MACHINE}.elf ${DEPLOYDIR}/pmu-${MACHINE}.elf
-	${OBJCOPY} -O binary ${B}/executable.elf ${B}/executable.bin
-	install -m 0644 ${B}/executable.bin ${DEPLOYDIR}/${PMU_FIRMWARE_BASE_NAME}.bin
-	ln -sf ${PMU_FIRMWARE_BASE_NAME}.bin ${DEPLOYDIR}/${BPN}-${MACHINE}.bin
-	ln -sf ${BPN}-${MACHINE}.bin ${DEPLOYDIR}/pmu-${MACHINE}.bin
-}
-addtask deploy before do_build after do_install
-
-BBCLASSEXTEND = "zynqmp-pmu"
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/reference-design/kc705-bitstream_2018.1.bb b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/reference-design/kc705-bitstream_2018.1.bb
deleted file mode 100644
index 0b6ca20..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/reference-design/kc705-bitstream_2018.1.bb
+++ /dev/null
@@ -1,48 +0,0 @@
-SUMMARY = "KC705 Pre-built Bitstream"
-DESCRIPTION = "A Pre-built bitstream for the KC705, which is capable of booting a Linux system."
-HOMEPAGE = "http://www.xilinx.com"
-SECTION = "bsp"
-
-# The BSP package does not include any license information.
-LICENSE = "Proprietary"
-LICENSE_FLAGS = "xilinx"
-LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/Proprietary;md5=0557f9d92cf58f2ccdd50f62f8ac0b28"
-
-COMPATIBLE_MACHINE = "kc705-microblazeel"
-
-inherit deploy
-inherit xilinx-fetch-restricted
-
-BSP_NAME = "xilinx-kc705"
-BSP_FILE = "${BSP_NAME}-v${PV}-final.bsp"
-SRC_URI = "https://www.xilinx.com/member/forms/download/xef.html?filename=${BSP_FILE};downloadfilename=${BSP_FILE}"
-SRC_URI[md5sum] = "53e5e0ad87d0388fe5b11fa5fc029288"
-SRC_URI[sha256sum] = "301f994bd836ad78ebfc92af6c16470b53253121ca31762dc1f770a9ff11dc18"
-
-PROVIDES = "virtual/bitstream"
-
-FILES_${PN} += "/boot/download.bit"
-
-INHIBIT_DEFAULT_DEPS = "1"
-PACKAGE_ARCH = "${MACHINE_ARCH}"
-
-# deps needed to extract content from the .bsp file
-DEPENDS += "tar-native gzip-native"
-
-do_compile() {
-	# Extract the bitstream into workdir
-	tar -xf ${WORKDIR}/${BSP_FILE} ${BSP_NAME}-axi-full-${PV}/pre-built/linux/images/download.bit -C ${S}
-	# move the bit file to ${S}/ as it is in a subdir in the tar file
-	for i in $(find -type f -name download.bit); do mv $i ${S}; done
-}
-
-do_install() {
-	install -D ${S}/download.bit ${D}/boot/download.bit
-}
-
-do_deploy () {
-	install -D ${S}/download.bit ${DEPLOYDIR}/download.bit
-}
-
-addtask deploy before do_build after do_install
-
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/reference-design/kc705-bitstream_2018.3.bb b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/reference-design/kc705-bitstream_2018.3.bb
new file mode 100644
index 0000000..6a2ca7c
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/reference-design/kc705-bitstream_2018.3.bb
@@ -0,0 +1,48 @@
+SUMMARY = "KC705 Pre-built Bitstream"
+DESCRIPTION = "A Pre-built bitstream for the KC705, which is capable of booting a Linux system."
+HOMEPAGE = "http://www.xilinx.com"
+SECTION = "bsp"
+
+# The BSP package does not include any license information.
+LICENSE = "Proprietary"
+LICENSE_FLAGS = "xilinx"
+LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/Proprietary;md5=0557f9d92cf58f2ccdd50f62f8ac0b28"
+
+COMPATIBLE_MACHINE = "kc705-microblazeel"
+
+inherit deploy
+inherit xilinx-fetch-restricted
+
+BSP_NAME = "xilinx-kc705"
+BSP_FILE = "${BSP_NAME}-v${PV}-final.bsp"
+SRC_URI = "https://www.xilinx.com/member/forms/download/xef.html?filename=${BSP_FILE};downloadfilename=${BSP_FILE}"
+SRC_URI[md5sum] = "5c0365a8a26cc27b4419aa1d7dd82351"
+SRC_URI[sha256sum] = "a909a91a37a9925ee2f972ccb10f986a26ff9785c1a71a483545a192783bf773"
+
+PROVIDES = "virtual/bitstream"
+
+FILES_${PN} += "/boot/download.bit"
+
+INHIBIT_DEFAULT_DEPS = "1"
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+# deps needed to extract content from the .bsp file
+DEPENDS += "tar-native gzip-native"
+
+do_compile() {
+	# Extract the bitstream into workdir
+	tar -xf ${WORKDIR}/${BSP_FILE} ${BSP_NAME}-axi-full-${PV}/pre-built/linux/images/download.bit -C ${S}
+	# move the bit file to ${S}/ as it is in a subdir in the tar file
+	for i in $(find -type f -name download.bit); do mv $i ${S}; done
+}
+
+do_install() {
+	install -D ${S}/download.bit ${D}/boot/download.bit
+}
+
+do_deploy () {
+	install -D ${S}/download.bit ${DEPLOYDIR}/download.bit
+}
+
+addtask deploy before do_build after do_install
+
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-spl-zynq-init.inc b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-spl-zynq-init.inc
index 9cf09ff..cf8b9b7 100644
--- a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-spl-zynq-init.inc
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-spl-zynq-init.inc
@@ -64,10 +64,8 @@
         d.setVar("SPL_BINARY", "")
 
     if providesbin and d.getVar("SOC_FAMILY") in ["zynqmp"]:
-        # depend on the pmu-firmware build
-        d.appendVar("DEPENDS", " virtual/pmu-firmware")
         # determine the path relative to the source tree
-        relpath = os.path.relpath(d.expand("${DEPLOY_DIR_IMAGE}/pmu-${MACHINE}.bin"), d.getVar("S"))
+        relpath = os.path.relpath(d.expand("${PMU_FIRMWARE_DEPLOY_DIR}/${PMU_FIRMWARE_IMAGE_NAME}.bin"), d.getVar("S"))
         # setup PMU Firmware path via MAKEFLAGS
         d.appendVar("EXTRA_OEMAKE", " CONFIG_PMUFW_INIT_FILE=\"{0}\"".format(relpath))
 }
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-xlnx/v2018.1/microblaze-kc705-Convert-microblaze-generic-to-k.patch b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-xlnx/v2018.3/microblaze-kc705-Convert-microblaze-generic-to-k.patch
similarity index 100%
rename from meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-xlnx/v2018.1/microblaze-kc705-Convert-microblaze-generic-to-k.patch
rename to meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-xlnx/v2018.3/microblaze-kc705-Convert-microblaze-generic-to-k.patch
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-xlnx_2018.1.bb b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-xlnx_2018.1.bb
deleted file mode 100644
index fb2c618..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-xlnx_2018.1.bb
+++ /dev/null
@@ -1,27 +0,0 @@
-UBOOT_VERSION = "v2018.01"
-XILINX_RELEASE_VERSION = "v2018.1"
-
-UBRANCH ?= "master"
-
-SRCREV ?= "949e5cb9a736bac32ea8886e3953da55bdd30754"
-
-include u-boot-xlnx.inc
-include u-boot-spl-zynq-init.inc
-
-SRC_URI_append_kc705-microblazeel = " file://microblaze-kc705-Convert-microblaze-generic-to-k.patch"
-
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://README;beginline=1;endline=6;md5=157ab8408beab40cd8ce1dc69f702a6c"
-
-# u-boot-xlnx has support for these
-HAS_PLATFORM_INIT ?= " \
-		zynq_microzed_config \
-		zynq_zed_config \
-		zynq_zc702_config \
-		zynq_zc706_config \
-		zynq_zybo_config \
-		xilinx_zynqmp_zcu102_rev1_0_config \
-		xilinx_zynqmp_zcu106_revA_config \
-		xilinx_zynqmp_zcu104_revC_config \
-		"
-
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-xlnx_2018.3.bb b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-xlnx_2018.3.bb
new file mode 100644
index 0000000..c87672e
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-xlnx_2018.3.bb
@@ -0,0 +1,32 @@
+UBOOT_VERSION = "v2018.01"
+XILINX_RELEASE_VERSION = "v2018.3"
+
+UBRANCH ?= "master"
+
+SRCREV ?= "d8fc4b3b70bccf1577dab69f6ddfd4ada9a93bac"
+
+include u-boot-xlnx.inc
+include u-boot-spl-zynq-init.inc
+
+SRC_URI_append_kc705-microblazeel = " file://microblaze-kc705-Convert-microblaze-generic-to-k.patch"
+
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://README;beginline=1;endline=6;md5=157ab8408beab40cd8ce1dc69f702a6c"
+
+# u-boot-xlnx has support for these
+HAS_PLATFORM_INIT ?= " \
+		zynq_microzed_config \
+		zynq_zed_config \
+		zynq_zc702_config \
+		zynq_zc706_config \
+		zynq_zybo_config \
+		xilinx_zynqmp_zcu102_rev1_0_config \
+		xilinx_zynqmp_zcu106_revA_config \
+		xilinx_zynqmp_zcu104_revC_config \
+		xilinx_zynqmp_zcu100_revC_config \
+		xilinx_zynqmp_zcu111_revA_config \
+		xilinx_zynqmp_zc1275_revA_config \
+		xilinx_zynqmp_zc1275_revB_config \
+		xilinx_zynqmp_zc1254_revA_config \
+		"
+
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-zynq-uenv.bb b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-zynq-uenv.bb
index f6c2a00..952077d 100644
--- a/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-zynq-uenv.bb
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-bsp/u-boot/u-boot-zynq-uenv.bb
@@ -5,43 +5,28 @@
 INHIBIT_DEFAULT_DEPS = "1"
 PACKAGE_ARCH = "${MACHINE_ARCH}"
 
+python () {
+    # The device trees must be populated in the deploy directory to correctly
+    # detect them and their names. This means that this recipe needs to depend
+    # on those deployables just like the image recipe does.
+    deploydeps = ["virtual/kernel"]
+    for i in (d.getVar("MACHINE_ESSENTIAL_EXTRA_RDEPENDS") or "").split():
+        if i != d.getVar("BPN"):
+            deploydeps.append(i)
+    for i in (d.getVar("EXTRA_IMAGEDEPENDS") or "").split():
+        if i != d.getVar("BPN"):
+            deploydeps.append(i)
+
+    # add as DEPENDS since the targets might not have do_deploy tasks
+    if len(deploydeps) != 0:
+        d.appendVar("DEPENDS", " " + " ".join(deploydeps))
+}
+
 COMPATIBLE_MACHINE = "^$"
 COMPATIBLE_MACHINE_zynq = ".*"
 COMPATIBLE_MACHINE_zynqmp = ".*"
 
-inherit deploy
-
-def bootfiles_bitstream(d):
-    expectedfiles = [("bitstream", True)]
-    expectedexts = [(".bit", True), (".bin", False)]
-    # search for bitstream paths, use the renamed file. First matching is used
-    for f in (d.getVar("IMAGE_BOOT_FILES") or "").split():
-        sf, rf = f, f
-        if ';' in f:
-            sf, rf = f.split(';')
-
-        # skip boot.bin and u-boot.bin, it is not a bitstream
-        skip = ["boot.bin", "u-boot.bin"]
-        if sf in skip or rf in skip:
-            continue
-
-        for e, t in expectedfiles:
-            if sf == e or rf == e:
-                return rf, t
-        for e, t in expectedexts:
-            if sf.endswith(e) or rf.endswith(e):
-                return rf, t
-    return "", False
-
-def bootfiles_dtb_filepath(d):
-    if d.getVar("IMAGE_BOOT_FILES"):
-        dtbs = d.getVar("IMAGE_BOOT_FILES").split(" ")
-        # IMAGE_BOOT_FILES has extra renaming info in the format '<source>;<target>'
-        dtbs = [f.split(";")[0] for f in dtbs]
-        dtbs = [f for f in dtbs if f.endswith(".dtb")]
-        if len(dtbs) != 0:
-            return dtbs[0]
-    return ""
+inherit deploy image-wic-utils
 
 def uboot_boot_cmd(d):
     if d.getVar("KERNEL_IMAGETYPE") in ["uImage", "fitImage"]:
@@ -61,7 +46,7 @@
     env["kernel_image"] = d.getVar("KERNEL_IMAGETYPE")
     env["kernel_load_address"] = d.getVar("KERNEL_LOAD_ADDRESS")
 
-    env["devicetree_image"] = bootfiles_dtb_filepath(d)
+    env["devicetree_image"] = boot_files_dtb_filepath(d)
     env["devicetree_load_address"] = d.getVar("DEVICETREE_LOAD_ADDRESS")
 
     env["bootargs"] = d.getVar("KERNEL_BOOTARGS")
@@ -73,7 +58,7 @@
     # default uenvcmd does not load bitstream
     env["uenvcmd"] = "run bootkernel"
 
-    bitstream, bitstreamtype = bootfiles_bitstream(d)
+    bitstream, bitstreamtype = boot_files_bitstream(d)
     if bitstream:
         env["bitstream_image"] = bitstream
         env["bitstream_load_address"] = "0x100000"
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-core/newlib/libgloss_3.0.0.bb b/meta-xilinx/meta-xilinx-bsp/recipes-core/newlib/libgloss_3.0.0.bb
deleted file mode 100644
index cff4a26..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-core/newlib/libgloss_3.0.0.bb
+++ /dev/null
@@ -1,27 +0,0 @@
-
-require newlib.inc
-
-DEPENDS += "newlib"
-
-do_configure() {
-	${S}/libgloss/configure ${EXTRA_OECONF}
-}
-
-do_install_prepend() {
-	# install doesn't create this itself, avoid install error
-	install -d ${D}${prefix}/${TARGET_SYS}/lib
-}
-
-do_install_append() {
-	# Move libs to default directories so they can be picked up later
-	mv -v ${D}${prefix}/${TARGET_SYS}/lib ${D}${libdir}
-
-	# Remove original directory
-	rmdir ${D}${prefix}/${TARGET_SYS}
-}
-
-# Split packages correctly
-FILES_${PN} += "${libdir}/*.ld ${libdir}/*.specs"
-
-INHIBIT_PACKAGE_STRIP = "1"
-INHIBIT_PACKAGE_DEBUG_SPLIT = "1"
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-core/newlib/newlib.inc b/meta-xilinx/meta-xilinx-bsp/recipes-core/newlib/newlib.inc
deleted file mode 100644
index 37ad6be..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-core/newlib/newlib.inc
+++ /dev/null
@@ -1,58 +0,0 @@
-SUMMARY = "Newlib is a C library intended for use on embedded systems"
-HOMEPAGE = "https://sourceware.org/newlib/"
-DESCRIPTION = "It is a conglomeration of several library parts, all under free software licenses that make them easily usable on embedded products."
-SECTION = "libs"
-
-LICENSE = "GPLv2 & LGPLv3 & GPLv3 & LGPLv2"
-LIC_FILES_CHKSUM = " \
-		file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
-		file://COPYING3.LIB;md5=6a6a8e020838b23406c81b19c1d46df6 \
-		file://COPYING3;md5=d32239bcb673463ab874e80d47fae504 \
-		file://COPYING.LIBGLOSS;md5=73f5c98779aea7dba4a6c94a74ab0ae2 \
-		file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1 \
-		file://COPYING.NEWLIB;md5=956a4b1487f7677cdcceeee8f05a21f0 \
-		file://newlib/libc/posix/COPYRIGHT;md5=103468ff1982be840fdf4ee9f8b51bbf \
-		file://newlib/libc/sys/linux/linuxthreads/LICENSE;md5=73640207fbc79b198c7ffd4ad4d97aa0 \
-		"
-
-SRC_URI = "ftp://sourceware.org/pub/newlib/newlib-${PV}.tar.gz"
-SRC_URI[md5sum] = "81ec873108b8593c586f91ca65963952"
-SRC_URI[sha256sum] = "c8566335ee74e5fcaeb8595b4ebd0400c4b043d6acb3263ecb1314f8f5501332"
-
-INHIBIT_DEFAULT_DEPS = "1"
-DEPENDS = "virtual/${TARGET_PREFIX}gcc-initial"
-
-PATH_prepend = "${STAGING_BINDIR_TOOLCHAIN}.${STAGINGCC}:"
-STAGINGCC = "${MLPREFIX}gcc-cross-initial-${TARGET_ARCH}"
-
-S = "${WORKDIR}/newlib-${PV}"
-B = "${WORKDIR}/build"
-
-# Disable use of a link hash style
-TARGET_LINK_HASH_STYLE_microblaze = ""
-
-# disable stdlib
-TARGET_CC_ARCH_append = " -nostdlib"
-
-EXTRA_OECONF = " \
-                --build=${BUILD_SYS}  \
-                --target=${TARGET_SYS} \
-		--host=${HOST_SYS} \
-                --prefix=${prefix}  \
-                --exec-prefix=${exec_prefix} \
-                --bindir=${bindir} \
-                --libdir=${libdir} \
-                --includedir=${includedir} \
-		--enable-languages=c \
-		--with-newlib \
-		--with-gnu-as \
-		--with-gnu-ld \
-		--disable-multilib \
-		"
-
-do_configure[cleandirs] = "${B}"
-
-do_install() {
-	oe_runmake install DESTDIR='${D}'
-}
-
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-core/newlib/newlib_3.0.0.bb b/meta-xilinx/meta-xilinx-bsp/recipes-core/newlib/newlib_3.0.0.bb
deleted file mode 100644
index 3d31350..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-core/newlib/newlib_3.0.0.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-require newlib.inc
-
-do_configure_prepend_microblaze() {
-	# hack for microblaze, which needs xilinx.ld to literally do any linking (its hard coded in its LINK_SPEC)
-	export CC="${CC} -L${S}/libgloss/microblaze"
-}
-
-do_configure() {
-	${S}/configure ${EXTRA_OECONF}
-}
-
-do_install_append() {
-	# Move include files and libs to default directories so they can be picked up later
-	mv -v ${D}${prefix}/${TARGET_SYS}/lib ${D}${libdir}
-	mv -v ${D}${prefix}/${TARGET_SYS}/include ${D}${includedir}
-
-	# Remove original directory
-	rmdir ${D}${prefix}/${TARGET_SYS}
-}
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/files/memfd.patch b/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/files/memfd.patch
deleted file mode 100644
index 62e8d38..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/files/memfd.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-Upstream-Status: Backport
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
-From 75e5b70e6b5dcc4f2219992d7cffa462aa406af0 Mon Sep 17 00:00:00 2001
-From: Paolo Bonzini <pbonzini@redhat.com>
-Date: Tue, 28 Nov 2017 11:51:27 +0100
-Subject: [PATCH] memfd: fix configure test
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Recent glibc added memfd_create in sys/mman.h.  This conflicts with
-the definition in util/memfd.c:
-
-    /builddir/build/BUILD/qemu-2.11.0-rc1/util/memfd.c:40:12: error: static declaration of memfd_create follows non-static declaration
-
-Fix the configure test, and remove the sys/memfd.h inclusion since the
-file actually does not exist---it is a typo in the memfd_create(2) man
-page.
-
-Cc: Marc-André Lureau <marcandre.lureau@redhat.com>
-Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
----
- configure    | 2 +-
- util/memfd.c | 4 +---
- 2 files changed, 2 insertions(+), 4 deletions(-)
-
-diff --git a/configure b/configure
-index 9c8aa5a98b..99ccc1725a 100755
---- a/configure
-+++ b/configure
-@@ -3923,7 +3923,7 @@ fi
- # check if memfd is supported
- memfd=no
- cat > $TMPC << EOF
--#include <sys/memfd.h>
-+#include <sys/mman.h>
- 
- int main(void)
- {
-diff --git a/util/memfd.c b/util/memfd.c
-index 4571d1aba8..412e94a405 100644
---- a/util/memfd.c
-+++ b/util/memfd.c
-@@ -31,9 +31,7 @@
- 
- #include "qemu/memfd.h"
- 
--#ifdef CONFIG_MEMFD
--#include <sys/memfd.h>
--#elif defined CONFIG_LINUX
-+#if defined CONFIG_LINUX && !defined CONFIG_MEMFD
- #include <sys/syscall.h>
- #include <asm/unistd.h>
- 
--- 
-2.11.0
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/files/qemu-system-aarch64-multiarch b/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/files/qemu-system-aarch64-multiarch
index 15124c1..2c92c68 100644
--- a/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/files/qemu-system-aarch64-multiarch
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/files/qemu-system-aarch64-multiarch
@@ -1,32 +1,54 @@
-#!/bin/bash
+#!/usr/bin/env python3
 
-BINPATH=$(dirname $0)
-MACHINE_PATH=$(mktemp -d)
+# Xilinx QEMU wrapper to launch both PMU and APU instances (multiarch)
+import os
+import subprocess
+import sys
+import tempfile
+import shutil
 
-APU_ARGS=
-PMU_ARGS=
+binpath = os.path.dirname(os.path.abspath(__file__))
+mach_path = tempfile.mkdtemp()
 
-while [ ! -z "$1" ]; do
-	if [ "$1" = "-pmu-args" ]; then
-		PMU_ARGS+=" $2"
-		shift
-	else
-		APU_ARGS+=" $1"
-	fi
-	shift
-done
 
-PMU_ROM=$(last=; for i in $PMU_ARGS; do if [ "$last" = "-kernel" ]; then echo "$i"; break; fi; last=$i; done)
-if [ ! -e $PMU_ROM ]; then
-	echo "------"
-	echo "Error: Missing PMU ROM - $PMU_ROM"
-	echo "    See 'meta-xilinx/README.qemu.md' for more information on accquiring the PMU ROM."
-	echo "------"
-	exit 255
-fi
+# Separate PMU and APU arguments
+APU_args = sys.argv[1:]
+PMU_args = APU_args[APU_args.index('-pmu-args')+1]
+APU_args.remove('-pmu-args')
+APU_args.remove(PMU_args)
+PMU_args = PMU_args.split()
 
-# start the PMU instance
-$BINPATH/qemu-system-microblazeel $PMU_ARGS -machine-path $MACHINE_PATH &
-# start the APU instance
-$BINPATH/qemu-system-aarch64 $APU_ARGS -machine-path $MACHINE_PATH
+PMU_rom = PMU_args[PMU_args.index('-kernel')+1]
+error_msg = None
 
+if os.path.exists(PMU_rom):
+
+    # We need to switch tcp serial arguments (if they exist, e.g. qemurunner) to get the output correctly
+    tcp_serial_ports = [i for i, s in enumerate(APU_args) if 'tcp:127.0.0.1:' in s]
+
+    # We can only switch these if there are exactly two, otherwise we can't assume what is being executed so we leave it as is
+    if len(tcp_serial_ports) == 2:
+        APU_args[tcp_serial_ports[0]],APU_args[tcp_serial_ports[1]] = APU_args[tcp_serial_ports[1]],APU_args[tcp_serial_ports[0]]
+
+    pmu_cmd =  binpath + '/qemu-system-microblazeel ' + ' '.join(PMU_args) + ' -machine-path ' + mach_path
+    apu_cmd =  binpath + '/qemu-system-aarch64 ' + ' '.join(APU_args) + ' -machine-path ' + mach_path
+
+    # Debug prints
+    print('\nPMU instance cmd: %s\n' % pmu_cmd)
+    print('APU instance cmd: %s\n' % apu_cmd)
+
+
+    # Invoke QEMU pmu instance
+    process_pmu = subprocess.Popen(pmu_cmd, shell=True, stderr=subprocess.PIPE)
+
+    # Invoke QEMU APU instance
+    process_apu = subprocess.Popen(apu_cmd, shell=True, stderr=subprocess.PIPE)
+    if process_apu.wait():
+        error_msg = '\nQEMU APU instance failed:\n%s' % process_apu.stderr.read().decode()
+
+else:
+    error_msg = '\nError: Missing PMU ROM: %s' % PMU_rom
+    error_msg += '\nSee "meta-xilinx/README.qemu.md" for more information on accquiring the PMU ROM.\n'
+
+shutil.rmtree(mach_path)
+sys.exit(error_msg)
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-devicetrees_2018.1.bb b/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-devicetrees_2018.1.bb
deleted file mode 100644
index a73b9e5..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-devicetrees_2018.1.bb
+++ /dev/null
@@ -1,6 +0,0 @@
-require qemu-devicetrees.inc
-
-XILINX_RELEASE_VERSION = "v2018.1"
-
-BRANCH ?= "master"
-SRCREV ?= "d5017f8119b6493d8b2fcdfd5caa4e8b16580877"
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-devicetrees_2018.3.bb b/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-devicetrees_2018.3.bb
new file mode 100644
index 0000000..6f8eda2
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-devicetrees_2018.3.bb
@@ -0,0 +1,6 @@
+require qemu-devicetrees.inc
+
+XILINX_RELEASE_VERSION = "v2018.3"
+
+BRANCH ?= "master"
+SRCREV ?= "e3e40b8829894a479c7d7380fc8137886645dda8"
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-xilinx.inc b/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-xilinx.inc
index b6c5dee..daff5ff 100644
--- a/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-xilinx.inc
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-xilinx.inc
@@ -17,9 +17,7 @@
 REPO ?= "git://github.com/Xilinx/qemu.git;protocol=https"
 
 BRANCHARG = "${@['nobranch=1', 'branch=${BRANCH}'][d.getVar('BRANCH', True) != '']}"
-SRC_URI = "${REPO};${BRANCHARG} \
-	file://memfd.patch \
-	"
+SRC_URI = "${REPO};${BRANCHARG}"
 
 S = "${WORKDIR}/git"
 
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-xilinx_2018.1.bb b/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-xilinx_2018.1.bb
deleted file mode 100644
index 1d6697c..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-xilinx_2018.1.bb
+++ /dev/null
@@ -1,6 +0,0 @@
-require qemu-xilinx.inc
-
-XILINX_RELEASE_VERSION = "v2018.1"
-XILINX_QEMU_VERSION ?= "v2.11.0"
-BRANCH ?= "master"
-SRCREV ?= "1d5516986ea296d91a599ac23252e302a4003914"
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-xilinx_2018.3.bb b/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-xilinx_2018.3.bb
new file mode 100644
index 0000000..57547df
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-devtools/qemu/qemu-xilinx_2018.3.bb
@@ -0,0 +1,6 @@
+require qemu-xilinx.inc
+
+XILINX_RELEASE_VERSION = "v2018.3"
+XILINX_QEMU_VERSION ?= "v2.11.0"
+BRANCH ?= "master"
+SRCREV ?= "f70bd86859c7a1a075ac864b4765168f821f1aae"
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-graphics/libgles/files/gbm.pc b/meta-xilinx/meta-xilinx-bsp/recipes-graphics/libgles/files/gbm.pc
new file mode 100644
index 0000000..02ea94e
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-graphics/libgles/files/gbm.pc
@@ -0,0 +1,12 @@
+prefix=/usr
+exec_prefix=${prefix}
+libdir=/usr/lib
+includedir=/usr/include
+
+Name: gbm
+Description: MALI gbm library
+Requires.private:
+Version: r8p0
+Libs: -L${libdir} -lgbm
+Libs.private: -lm -lpthread -ldl
+Cflags: -I${includedir}
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-graphics/libgles/files/wayland-egl.pc b/meta-xilinx/meta-xilinx-bsp/recipes-graphics/libgles/files/wayland-egl.pc
new file mode 100644
index 0000000..719fb3e
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-graphics/libgles/files/wayland-egl.pc
@@ -0,0 +1,12 @@
+prefix=/usr
+exec_prefix=${prefix}
+libdir=/usr/lib
+includedir=/usr/include
+
+Name: wayland-egl
+Description: MALI wayland-egl library
+Requires.private:
+Version: r8p0
+Libs: -L${libdir} -lwayland-egl
+Libs.private: -lm -lpthread -ldl
+Cflags: -I${includedir}
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-graphics/libgles/libmali-xlnx.bb b/meta-xilinx/meta-xilinx-bsp/recipes-graphics/libgles/libmali-xlnx.bb
index 3e675d9..8c6ab3e 100644
--- a/meta-xilinx/meta-xilinx-bsp/recipes-graphics/libgles/libmali-xlnx.bb
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-graphics/libgles/libmali-xlnx.bb
@@ -9,7 +9,7 @@
 
 ANY_OF_DISTRO_FEATURES = "fbdev x11"
 
-PROVIDES += "virtual/libgles1 virtual/libgles2 virtual/egl"
+PROVIDES += "virtual/libgles1 virtual/libgles2 virtual/egl virtual/libgbm"
 
 FILESEXTRAPATHS_append := " \
                 ${THISDIR}/files: \
@@ -26,10 +26,12 @@
     file://glesv1_cm.pc \
     file://glesv1.pc \
     file://glesv2.pc \
+    file://wayland-egl.pc \
+    file://gbm.pc \
     "
 
-SRC_URI[md5sum] = "e75b147c8b4ee96616e24572cdc9c21f"
-SRC_URI[sha256sum] = "7b179ec2df54ee05a886cca1535c0bdc6cba77a646e22742adedc79bfc2b3017"
+SRC_URI[md5sum] = "4fd3456564ef8c818e21432221c9e1b7"
+SRC_URI[sha256sum] = "26d473ae77c36104a215710beca55a22a712850dc26547dde950c7398210602c"
 
 COMPATIBLE_MACHINE = "^$"
 COMPATIBLE_MACHINE_zynqmpeg = "zynqmpeg"
@@ -50,14 +52,16 @@
 
 DEPENDS = "\
 	${@bb.utils.contains('DISTRO_FEATURES', 'x11', '${X11DEPENDS}', '', d)} \
+	${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'wayland libdrm', '', d)} \
 	"
 
-EGL_TYPE = "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11',  \
-               bb.utils.contains('DISTRO_FEATURES', 'fbdev',  'fbdev', '', d), d)}"
+USE_X11 = "${@bb.utils.contains("DISTRO_FEATURES", "x11", "yes", "no", d)}"
+USE_FB = "${@bb.utils.contains("DISTRO_FEATURES", "fbdev", "yes", "no", d)}"
+USE_WL = "${@bb.utils.contains("DISTRO_FEATURES", "wayland", "yes", "no", d)}"
 
 do_compile() {
 	# Extract the MALI binaries into workdir
-	tar -xf ${WORKDIR}/mali/rel-v2018.1/r8p0-01rel0.tar -C ${S}
+	tar -xf ${WORKDIR}/mali/rel-v2018.3/r8p0-01rel0.tar -C ${S}
 }
 
 do_install() {
@@ -71,13 +75,13 @@
 
     # install headers
     install -d -m 0655 ${D}${includedir}/EGL
-    install -m 0644 ${S}/${PV}/${ARCH_PLATFORM_DIR}/${EGL_TYPE}/usr/include/EGL/*.h ${D}${includedir}/EGL/
+    install -m 0644 ${S}/${PV}/glesHeaders/EGL/*.h ${D}${includedir}/EGL/
     install -d -m 0655 ${D}${includedir}/GLES
-    install -m 0644 ${S}/${PV}/${ARCH_PLATFORM_DIR}/${EGL_TYPE}/usr/include/GLES/*.h ${D}${includedir}/GLES/
+    install -m 0644 ${S}/${PV}/glesHeaders/GLES/*.h ${D}${includedir}/GLES/
     install -d -m 0655 ${D}${includedir}/GLES2
-    install -m 0644 ${S}/${PV}/${ARCH_PLATFORM_DIR}/${EGL_TYPE}/usr/include/GLES2/*.h ${D}${includedir}/GLES2/
+    install -m 0644 ${S}/${PV}/glesHeaders/GLES2/*.h ${D}${includedir}/GLES2/
     install -d -m 0655 ${D}${includedir}/KHR
-    install -m 0644 ${S}/${PV}/${ARCH_PLATFORM_DIR}/${EGL_TYPE}/usr/include/KHR/*.h ${D}${includedir}/KHR/
+    install -m 0644 ${S}/${PV}/glesHeaders/KHR/*.h ${D}${includedir}/KHR/
 
     install -d ${D}${libdir}/pkgconfig
     install -m 0644 ${WORKDIR}/egl.pc ${D}${libdir}/pkgconfig/egl.pc
@@ -86,7 +90,26 @@
     install -m 0644 ${WORKDIR}/glesv1_cm.pc ${D}${libdir}/pkgconfig/glesv1_cm.pc
 
     install -d ${D}${libdir}
-    cp -a --no-preserve=ownership ${S}/${PV}/${ARCH_PLATFORM_DIR}/${EGL_TYPE}/usr/lib/*.so* ${D}${libdir}
+    install -d ${D}${includedir}
+
+    cp -a --no-preserve=ownership ${S}/${PV}/${ARCH_PLATFORM_DIR}/common/*.so* ${D}${libdir}
+
+    if [ "${USE_WL}" = "yes" ]; then
+	install -m 0644 ${S}/${PV}/glesHeaders/GBM/gbm.h ${D}${includedir}/
+	install -m 0644 ${WORKDIR}/gbm.pc ${D}${libdir}/pkgconfig/gbm.pc
+	install -m 0644 ${WORKDIR}/wayland-egl.pc ${D}${libdir}/pkgconfig/wayland-egl.pc
+	install -Dm 0644 ${S}/${PV}/${ARCH_PLATFORM_DIR}/wayland/libMali.so.8.0 ${D}${libdir}/wayland/libMali.so.8.0
+	ln -snf wayland/libMali.so.8.0 ${D}${libdir}/libMali.so.8.0
+    elif [ "${USE_X11}" = "yes" ]; then
+	install -Dm 0644 ${S}/${PV}/${ARCH_PLATFORM_DIR}/x11/libMali.so.8.0 ${D}${libdir}/x11/libMali.so.8.0
+	ln -snf x11/libMali.so.8.0 ${D}${libdir}/libMali.so.8.0
+    elif [ "${USE_FB}" = "yes" ]; then
+	install -Dm 0644 ${S}/${PV}/${ARCH_PLATFORM_DIR}/fbdev/libMali.so.8.0 ${D}${libdir}/fbdev/libMali.so.8.0
+	ln -snf fbdev/libMali.so.8.0 ${D}${libdir}/libMali.so.8.0
+    else
+	install -Dm 0644 ${S}/${PV}/${ARCH_PLATFORM_DIR}/headless/libMali.so.8.0 ${D}${libdir}/headless/libMali.so.8.0
+	ln -snf headless/libMali.so.8.0 ${D}${libdir}/libMali.so.8.0
+    fi
 
     if ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'false', 'true', d)}; then
         sed -i -e 's/^#if defined(MESA_EGL_NO_X11_HEADERS)$/#if (1)/' ${D}${includedir}/EGL/eglplatform.h
@@ -99,10 +122,11 @@
 INHIBIT_PACKAGE_STRIP = "1"
 INHIBIT_SYSROOT_STRIP = "1"
 
-RREPLACES_${PN} = "libegl libgles1 libglesv1-cm1 libgles2 libglesv2-2"
-RPROVIDES_${PN} = "libegl libgles1 libglesv1-cm1 libgles2 libglesv2-2"
-RCONFLICTS_${PN} = "libegl libgles1 libglesv1-cm1 libgles2 libglesv2-2"
+RREPLACES_${PN} = "libegl libgles1 libglesv1-cm1 libgles2 libglesv2-2 libgbm"
+RPROVIDES_${PN} = "libegl libgles1 libglesv1-cm1 libgles2 libglesv2-2 libgbm"
+RCONFLICTS_${PN} = "libegl libgles1 libglesv1-cm1 libgles2 libglesv2-2 libgbm"
 
 # These libraries shouldn't get installed in world builds unless something
 # explicitly depends upon them.
 EXCLUDE_FROM_WORLD = "1"
+FILES_${PN} += "${libdir}/*"
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/linux-xlnx.inc b/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/linux-xlnx.inc
index 7b4f9ac..ec056db 100644
--- a/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/linux-xlnx.inc
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/linux-xlnx.inc
@@ -23,6 +23,8 @@
 	[ -n "${KBUILD_DEFCONFIG}" ] && [ -e ${WORKDIR}/defconfig ] && rm ${WORKDIR}/defconfig
 }
 
+inherit kernel-simpleimage
+
 # Default to be only compatible with specific machines or soc families
 COMPATIBLE_MACHINE ?= "^$"
 COMPATIBLE_MACHINE_zynq = ".*"
@@ -42,4 +44,7 @@
 # MicroBlaze BSP fragments
 KERNEL_FEATURES_append_kc705-microblazeel = " bsp/kc705-microblazeel/kc705-microblazeel.scc"
 
-KERNEL_FEATURES_zynqmp += "${@bb.utils.contains('DISTRO_FEATURES', 'xen', ' bsp/xilinx/xen.scc', '', d)}"
+KERNEL_FEATURES_append_zynqmp = "${@bb.utils.contains('DISTRO_FEATURES', 'xen', ' bsp/xilinx/xen.scc', '', d)}"
+
+KERNEL_FEATURES_append_zynqmp = "${@bb.utils.contains('IMAGE_FEATURES', 'fpga-manager', ' features/overlay/overlay.scc', '', d)}"
+
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/linux-xlnx_2018.1.bb b/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/linux-xlnx_2018.1.bb
deleted file mode 100644
index c3a8f76..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/linux-xlnx_2018.1.bb
+++ /dev/null
@@ -1,7 +0,0 @@
-LINUX_VERSION = "4.14"
-XILINX_RELEASE_VERSION = "v2018.1"
-KBRANCH ?= "xlnx_rebase_v4.14"
-SRCREV ?= "4ac76ffacb54712b0361e51d0b7156e53d062e3c"
-
-include linux-xlnx.inc
-
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/linux-xlnx_2018.3.bb b/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/linux-xlnx_2018.3.bb
new file mode 100644
index 0000000..ade13e3
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/linux-xlnx_2018.3.bb
@@ -0,0 +1,7 @@
+LINUX_VERSION = "4.14"
+XILINX_RELEASE_VERSION = "v2018.3"
+KBRANCH ?= "xlnx_rebase_v4.14"
+SRCREV ?= "eeab73d1207d6fc2082776c954eb19fd7290bfbe"
+
+include linux-xlnx.inc
+
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/xilinx-kmeta/features/overlay/overlay.cfg b/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/xilinx-kmeta/features/overlay/overlay.cfg
new file mode 100644
index 0000000..44462be
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/xilinx-kmeta/features/overlay/overlay.cfg
@@ -0,0 +1,3 @@
+# Device Tree support
+CONFIG_OF_CONFIGFS=y
+CONFIG_OF_OVERLAY=y
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/xilinx-kmeta/features/overlay/overlay.scc b/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/xilinx-kmeta/features/overlay/overlay.scc
new file mode 100644
index 0000000..14f05ff
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-kernel/linux/xilinx-kmeta/features/overlay/overlay.scc
@@ -0,0 +1,4 @@
+define KFEATURE_DESCRIPTION "Enable overlay"
+define KFEATURE_COMPATIBILITY board
+
+kconfig hardware overlay.cfg
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils%.bbappend b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils%.bbappend
index 795c671..4470972 100644
--- a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils%.bbappend
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils%.bbappend
@@ -1,4 +1,4 @@
-FILESEXTRAPATHS_append_microblaze := "${THISDIR}/binutils-2.30:"
+FILESEXTRAPATHS_append_microblaze := "${THISDIR}/binutils-2.31:"
 SRC_URI_append_microblaze = " \
 		file://0001-MicroBlaze-Add-wdc.ext.clear-and-wdc.ext.flush-insns.patch \
 		file://0002-MicroBlaze-add-mlittle-endian-and-mbig-endian-flags.patch \
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0003-Disable-the-warning-message-for-eh_frame_hdr.patch b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0003-Disable-the-warning-message-for-eh_frame_hdr.patch
deleted file mode 100644
index 2b30c46..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0003-Disable-the-warning-message-for-eh_frame_hdr.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From dac72d809be9faf9380b181df0c19a2c6d744c54 Mon Sep 17 00:00:00 2001
-From: "Edgar E. Iglesias" <edgar.iglesias@gmail.com>
-Date: Mon, 28 Aug 2017 19:53:54 -0700
-Subject: [PATCH] Disable the warning message for eh_frame_hdr
-
-Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
-Signed-off-by: Manjukumar Matha <manjukumar.harthikote-matha@xilinx.com>
-Upstream-Status: Inappropriate [workaround]
-
----
- bfd/elf-eh-frame.c | 9 ++++++---
- 1 file changed, 6 insertions(+), 3 deletions(-)
-
-diff --git a/bfd/elf-eh-frame.c b/bfd/elf-eh-frame.c
-index 95697c4..704121d 100644
---- a/bfd/elf-eh-frame.c
-+++ b/bfd/elf-eh-frame.c
-@@ -1042,10 +1042,13 @@ _bfd_elf_parse_eh_frame (bfd *abfd, struct bfd_link_info *info,
-   goto success;
- 
-  free_no_table:
--  (*info->callbacks->einfo)
-+  /* FIXME: Remove the microblaze specifics when relaxing gets fixed.  */
-+  if (bfd_get_arch(abfd) != bfd_arch_microblaze) {
-     /* xgettext:c-format */
--    (_("%P: error in %B(%A); no .eh_frame_hdr table will be created.\n"),
--     abfd, sec);
-+    (*info->callbacks->einfo)
-+      (_("%P: error in %B(%A); no .eh_frame_hdr table will be created.\n"),
-+       abfd, sec);
-+  }
-   hdr_info->u.dwarf.table = FALSE;
-   if (sec_info)
-     free (sec_info);
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0005-Fixup-MicroBlaze-debug_loc-sections-after-linker-rel.patch b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0005-Fixup-MicroBlaze-debug_loc-sections-after-linker-rel.patch
deleted file mode 100644
index 3817234..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0005-Fixup-MicroBlaze-debug_loc-sections-after-linker-rel.patch
+++ /dev/null
@@ -1,242 +0,0 @@
-From 5bf68bc39976903929f730b6eed18686c3563c05 Mon Sep 17 00:00:00 2001
-From: Nagaraju Mekala <nagaraju.mekala@xilinx.com>
-Date: Mon, 28 Aug 2017 19:53:56 -0700
-Subject: [PATCH] Fixup MicroBlaze debug_loc sections after linker relaxation
-
-Fixup debug_loc sections after linker relaxation Adds a new reloctype
-R_MICROBLAZE_32_NONE, used for passing reloc info from the assembler to
-the linker when the linker manages to fully resolve a local symbol
-reference.
-
-This is a workaround for design flaws in the assembler to
-linker interface with regards to linker relaxation.
-
-03/2018
-Rebased for binutils 2.30
-
-Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
-Signed-off-by: Nagaraju Mekala <nmekala@xilinx.com>
-Signed-off-by: Manjukumar Matha <manjukumar.harthikote-matha@xilinx.com>
-Signed-off-by: Alejandro Enedino Hernandez Samaniego <alejandr@xilinx.com>
-
-Upstream-Status: Pending
-
----
- bfd/bfd-in2.h              |  9 +++++++--
- bfd/elf32-microblaze.c     | 45 ++++++++++++++++++++++++++++++++++++++-------
- bfd/libbfd.h               |  1 +
- bfd/reloc.c                |  6 ++++++
- binutils/readelf.c         |  4 ++++
- gas/config/tc-microblaze.c |  5 ++++-
- include/elf/microblaze.h   |  1 +
- 7 files changed, 61 insertions(+), 10 deletions(-)
-
-diff --git a/bfd/bfd-in2.h b/bfd/bfd-in2.h
-index 4228603..1906195 100644
---- a/bfd/bfd-in2.h
-+++ b/bfd/bfd-in2.h
-@@ -5826,10 +5826,15 @@ value relative to the read-write small data area anchor  */
- expressions of the form "Symbol Op Symbol"  */
-   BFD_RELOC_MICROBLAZE_32_SYM_OP_SYM,
- 
--/* This is a 64 bit reloc that stores the 32 bit pc relative
-+/* This is a 32 bit reloc that stores the 32 bit pc relative
- value in two words (with an imm instruction).  No relocation is
- done here - only used for relaxing  */
--  BFD_RELOC_MICROBLAZE_64_NONE,
-+  BFD_RELOC_MICROBLAZE_32_NONE,
-+
-+/* This is a 64 bit reloc that stores the 32 bit pc relative
-+ *  +value in two words (with an imm instruction).  No relocation is
-+ *   +done here - only used for relaxing  */
-+    BFD_RELOC_MICROBLAZE_64_NONE,
- 
- /* This is a 64 bit reloc that stores the 32 bit pc relative
- value in two words (with an imm instruction).  The relocation is
-diff --git a/bfd/elf32-microblaze.c b/bfd/elf32-microblaze.c
-index a1d810c..fc0d3e1 100644
---- a/bfd/elf32-microblaze.c
-+++ b/bfd/elf32-microblaze.c
-@@ -176,6 +176,20 @@ static reloc_howto_type microblaze_elf_howto_raw[] =
- 	  0x0000ffff,		/* Dest Mask.  */
- 	  FALSE),		/* PC relative offset?  */
- 
-+   HOWTO (R_MICROBLAZE_32_NONE,   /* Type.  */
-+          0,         /* Rightshift.  */
-+          2,            /* Size (0 = byte, 1 = short, 2 = long).  */
-+          32,           /* Bitsize.  */
-+          TRUE,         /* PC_relative.  */
-+          0,           /* Bitpos.  */
-+          complain_overflow_bitfield,  /* Complain on overflow.  */
-+          NULL,                  /* Special Function.  */
-+          "R_MICROBLAZE_32_NONE",/* Name.  */
-+          FALSE,       /* Partial Inplace.  */
-+          0,          /* Source Mask.  */
-+          0,         /* Dest Mask.  */
-+          FALSE),       /* PC relative offset?  */
-+
-    /* This reloc does nothing.	Used for relaxation.  */
-    HOWTO (R_MICROBLAZE_64_NONE,	/* Type.  */
- 	  0,			/* Rightshift.  */
-@@ -532,6 +546,9 @@ microblaze_elf_reloc_type_lookup (bfd * abfd ATTRIBUTE_UNUSED,
-     case BFD_RELOC_NONE:
-       microblaze_reloc = R_MICROBLAZE_NONE;
-       break;
-+    case BFD_RELOC_MICROBLAZE_32_NONE:
-+      microblaze_reloc = R_MICROBLAZE_32_NONE;
-+      break;
-     case BFD_RELOC_MICROBLAZE_64_NONE:
-       microblaze_reloc = R_MICROBLAZE_64_NONE;
-       break;
-@@ -1832,14 +1849,23 @@ microblaze_elf_relax_section (bfd *abfd,
- 		}
- 	      break;
- 	    case R_MICROBLAZE_NONE:
-+            case R_MICROBLAZE_32_NONE:
- 	      {
- 		/* This was a PC-relative instruction that was
- 		   completely resolved.  */
- 		int sfix, efix;
-+            unsigned int val;
- 		bfd_vma target_address;
- 		target_address = irel->r_addend + irel->r_offset;
- 		sfix = calc_fixup (irel->r_offset, 0, sec);
- 		efix = calc_fixup (target_address, 0, sec);
-+
-+            /* Validate the in-band val.  */
-+            val = bfd_get_32 (abfd, contents + irel->r_offset);
-+            if (val != irel->r_addend && ELF32_R_TYPE (irel->r_info) == R_MICROBLAZE_32_NONE) {
-+               fprintf(stderr, "%d: CORRUPT relax reloc %x %lx\n", __LINE__, val, irel->r_addend);
-+            }
-+
- 		irel->r_addend -= (efix - sfix);
- 		/* Should use HOWTO.  */
- 		microblaze_bfd_write_imm_value_32 (abfd, contents + irel->r_offset,
-@@ -1887,12 +1913,16 @@ microblaze_elf_relax_section (bfd *abfd,
- 	  irelscanend = irelocs + o->reloc_count;
- 	  for (irelscan = irelocs; irelscan < irelscanend; irelscan++)
- 	    {
--              if (ELF32_R_TYPE (irelscan->r_info) == (int) R_MICROBLAZE_NONE)
-+              if (1 && ELF32_R_TYPE (irelscan->r_info) == (int) R_MICROBLAZE_32_NONE)
-                 {
-                   unsigned int val;
- 
-                   isym = isymbuf + ELF32_R_SYM (irelscan->r_info);
- 
-+                  /* hax: We only do the following fixup for debug location lists.  */
-+                  if (strcmp(".debug_loc", o->name))
-+                    continue;
-+
-                   /* This was a PC-relative instruction that was completely resolved.  */
-                   if (ocontents == NULL)
-                     {
-@@ -1917,15 +1947,16 @@ microblaze_elf_relax_section (bfd *abfd,
-                         }
-                     }
- 
--                  irelscan->r_addend -= calc_fixup (irelscan->r_addend
--                                                    + isym->st_value, sec);
-                   val = bfd_get_32 (abfd, ocontents + irelscan->r_offset);
-+
-+                  if (val != irelscan->r_addend) {
-+                    fprintf(stderr, "%d: CORRUPT relax reloc! %x %lx\n", __LINE__, val, irelscan->r_addend);
-+                  }
-+                  irelscan->r_addend -= calc_fixup (irelscan->r_addend, 0, sec);
-+
-                   microblaze_bfd_write_imm_value_32 (abfd, ocontents + irelscan->r_offset,
-                                                      irelscan->r_addend);
-               }
--              if (ELF32_R_TYPE (irelscan->r_info) == (int) R_MICROBLAZE_64_NONE) {
--                  fprintf(stderr, "Unhandled NONE 64\n");
--              }
- 	      if (ELF32_R_TYPE (irelscan->r_info) == (int) R_MICROBLAZE_32)
- 		{
- 		  isym = isymbuf + ELF32_R_SYM (irelscan->r_info);
-@@ -1985,7 +2016,7 @@ microblaze_elf_relax_section (bfd *abfd,
- 			      elf_section_data (o)->this_hdr.contents = ocontents;
- 			    }
- 			}
--		      irelscan->r_addend -= calc_fixup (irel->r_addend
-+              irelscan->r_addend -= calc_fixup (irelscan->r_addend
- 							+ isym->st_value,
- 							0,
- 							sec);
-diff --git a/bfd/libbfd.h b/bfd/libbfd.h
-index 2f5f16e..854bb0c 100644
---- a/bfd/libbfd.h
-+++ b/bfd/libbfd.h
-@@ -2853,6 +2853,7 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
-   "BFD_RELOC_MICROBLAZE_32_ROSDA",
-   "BFD_RELOC_MICROBLAZE_32_RWSDA",
-   "BFD_RELOC_MICROBLAZE_32_SYM_OP_SYM",
-+  "BFD_RELOC_MICROBLAZE_32_NONE",
-   "BFD_RELOC_MICROBLAZE_64_NONE",
-   "BFD_RELOC_MICROBLAZE_64_GOTPC",
-   "BFD_RELOC_MICROBLAZE_64_GOT",
-diff --git a/bfd/reloc.c b/bfd/reloc.c
-index a1353a2..4b57de7 100644
---- a/bfd/reloc.c
-+++ b/bfd/reloc.c
-@@ -6903,6 +6903,12 @@ ENUMDOC
-   This is a 32 bit reloc for the microblaze to handle
-   expressions of the form "Symbol Op Symbol"
- ENUM
-+  BFD_RELOC_MICROBLAZE_32_NONE
-+ENUMDOC
-+  This is a 32 bit reloc that stores the 32 bit pc relative
-+  value in two words (with an imm instruction).  No relocation is
-+  done here - only used for relaxing
-+ENUM
-   BFD_RELOC_MICROBLAZE_64_NONE
- ENUMDOC
-   This is a 64 bit reloc that stores the 32 bit pc relative
-diff --git a/binutils/readelf.c b/binutils/readelf.c
-index fed0387..92f655d 100644
---- a/binutils/readelf.c
-+++ b/binutils/readelf.c
-@@ -12774,6 +12774,10 @@ is_none_reloc (Filedata * filedata, unsigned int reloc_type)
- 	      || reloc_type == 32 /* R_AVR_DIFF32.  */);
-     case EM_METAG:
-       return reloc_type == 3; /* R_METAG_NONE.  */
-+    case EM_MICROBLAZE:
-+      return reloc_type == 30 /* R_MICROBLAZE_32_NONE.  */
-+             || reloc_type == 0 /* R_MICROBLAZE_NONE.  */
-+             || reloc_type == 9; /* R_MICROBLAZE_64_NONE.  */
-     case EM_NDS32:
-       return (reloc_type == 0       /* R_XTENSA_NONE.  */
- 	      || reloc_type == 204  /* R_NDS32_DIFF8.  */
-diff --git a/gas/config/tc-microblaze.c b/gas/config/tc-microblaze.c
-index 50dbfc7..d66e949 100644
---- a/gas/config/tc-microblaze.c
-+++ b/gas/config/tc-microblaze.c
-@@ -2179,7 +2179,9 @@ md_apply_fix (fixS *   fixP,
-       /* This fixup has been resolved.  Create a reloc in case the linker
- 	 moves code around due to relaxing.  */
-       if (fixP->fx_r_type == BFD_RELOC_64_PCREL)
--	fixP->fx_r_type = BFD_RELOC_MICROBLAZE_64_NONE;
-+	    fixP->fx_r_type = BFD_RELOC_MICROBLAZE_64_NONE;
-+      else if (fixP->fx_r_type == BFD_RELOC_32)
-+        fixP->fx_r_type = BFD_RELOC_MICROBLAZE_32_NONE;
-       else
- 	fixP->fx_r_type = BFD_RELOC_NONE;
-       fixP->fx_addsy = section_symbol (absolute_section);
-@@ -2401,6 +2403,7 @@ tc_gen_reloc (asection * section ATTRIBUTE_UNUSED, fixS * fixp)
-   switch (fixp->fx_r_type)
-     {
-     case BFD_RELOC_NONE:
-+    case BFD_RELOC_MICROBLAZE_32_NONE: 
-     case BFD_RELOC_MICROBLAZE_64_NONE:
-     case BFD_RELOC_32:
-     case BFD_RELOC_MICROBLAZE_32_LO:
-diff --git a/include/elf/microblaze.h b/include/elf/microblaze.h
-index ae98099..c8cc57b 100644
---- a/include/elf/microblaze.h
-+++ b/include/elf/microblaze.h
-@@ -58,6 +58,7 @@ START_RELOC_NUMBERS (elf_microblaze_reloc_type)
-   RELOC_NUMBER (R_MICROBLAZE_TLSDTPREL64, 27)   /* TLS Offset Within TLS Block */
-   RELOC_NUMBER (R_MICROBLAZE_TLSGOTTPREL32, 28) /* TLS Offset From Thread Pointer */
-   RELOC_NUMBER (R_MICROBLAZE_TLSTPREL32, 29)    /* TLS Offset From Thread Pointer */
-+  RELOC_NUMBER (R_MICROBLAZE_32_NONE, 30)
-    
- END_RELOC_NUMBERS (R_MICROBLAZE_max)
- 
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0006-Fix-bug-in-MicroBlaze-TLSTPREL-Relocation.patch b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0006-Fix-bug-in-MicroBlaze-TLSTPREL-Relocation.patch
deleted file mode 100644
index a671cf8..0000000
--- a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0006-Fix-bug-in-MicroBlaze-TLSTPREL-Relocation.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From 0cad227ce495a975b32c10a8b6b0970c45024dd6 Mon Sep 17 00:00:00 2001
-From: Nagaraju Mekala <nagaraju.mekala@xilinx.com>
-Date: Mon, 28 Aug 2017 19:53:58 -0700
-Subject: [PATCH] Fix bug in MicroBlaze TLSTPREL Relocation
-
-Fixed the problem related to the fixup/relocations TLSTPREL.
-When the fixup is applied the addend is not added at the correct offset
-of the instruction. The offset is hard coded considering its big endian
-and it fails for Little endian. This patch allows support for both
-big & little-endian compilers
-
-Signed-off-by: Nagaraju Mekala <nagaraju.mekala@xilinx.com>
-Signed-off-by: Manjukumar Matha <manjukumar.harthikote-matha@xilinx.com>
-Upstream-Status: Pending
-
----
- bfd/elf32-microblaze.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/bfd/elf32-microblaze.c b/bfd/elf32-microblaze.c
-index fc0d3e1..a94799f 100644
---- a/bfd/elf32-microblaze.c
-+++ b/bfd/elf32-microblaze.c
-@@ -1402,9 +1402,9 @@ microblaze_elf_relocate_section (bfd *output_bfd,
- 	      relocation += addend;
- 	      relocation -= dtprel_base(info);
- 	      bfd_put_16 (input_bfd, (relocation >> 16) & 0xffff,
--			  contents + offset + 2);
-+			  contents + offset + endian);
- 	      bfd_put_16 (input_bfd, relocation & 0xffff,
--			  contents + offset + 2 + INST_WORD_SIZE);
-+			  contents + offset + endian + INST_WORD_SIZE);
- 	      break;
- 	    case (int) R_MICROBLAZE_64_PCREL :
- 	    case (int) R_MICROBLAZE_64:
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0001-MicroBlaze-Add-wdc.ext.clear-and-wdc.ext.flush-insns.patch b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0001-MicroBlaze-Add-wdc.ext.clear-and-wdc.ext.flush-insns.patch
similarity index 100%
rename from meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0001-MicroBlaze-Add-wdc.ext.clear-and-wdc.ext.flush-insns.patch
rename to meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0001-MicroBlaze-Add-wdc.ext.clear-and-wdc.ext.flush-insns.patch
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0002-MicroBlaze-add-mlittle-endian-and-mbig-endian-flags.patch b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0002-MicroBlaze-add-mlittle-endian-and-mbig-endian-flags.patch
similarity index 100%
rename from meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0002-MicroBlaze-add-mlittle-endian-and-mbig-endian-flags.patch
rename to meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0002-MicroBlaze-add-mlittle-endian-and-mbig-endian-flags.patch
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0003-Disable-the-warning-message-for-eh_frame_hdr.patch b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0003-Disable-the-warning-message-for-eh_frame_hdr.patch
new file mode 100644
index 0000000..aee0c01
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0003-Disable-the-warning-message-for-eh_frame_hdr.patch
@@ -0,0 +1,39 @@
+From dac72d809be9faf9380b181df0c19a2c6d744c54 Mon Sep 17 00:00:00 2001
+From: "Edgar E. Iglesias" <edgar.iglesias@gmail.com>
+Date: Mon, 28 Aug 2017 19:53:54 -0700
+Subject: [PATCH] Disable the warning message for eh_frame_hdr
+
+Upstream-Status: Inappropriate [workaround]
+
+Rebased to 2.31
+ - Error hanlder changed
+
+Signed-off-by: Alejandro Enedino Hernandez Samaniego <alejandr@xilinx.com>
+Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
+Signed-off-by: Manjukumar Matha <manjukumar.harthikote-matha@xilinx.com>
+
+---
+ bfd/elf-eh-frame.c | 9 ++++++---
+ 1 file changed, 6 insertions(+), 3 deletions(-)
+
+Index: git/bfd/elf-eh-frame.c
+===================================================================
+--- git.orig/bfd/elf-eh-frame.c
++++ git/bfd/elf-eh-frame.c
+@@ -1042,10 +1042,13 @@ _bfd_elf_parse_eh_frame (bfd *abfd, stru
+   goto success;
+ 
+  free_no_table:
+-  _bfd_error_handler
++  /* FIXME: Remove the microblaze specifics when relaxing gets fixed.  */
++  if (bfd_get_arch(abfd) != bfd_arch_microblaze) {
+     /* xgettext:c-format */
+-    (_("error in %pB(%pA); no .eh_frame_hdr table will be created"),
+-     abfd, sec);
++    _bfd_error_handler
++      (_("error in %pB(%pA); no .eh_frame_hdr table will be created"),
++       abfd, sec);
++  }
+   hdr_info->u.dwarf.table = FALSE;
+   if (sec_info)
+     free (sec_info);
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0004-Fix-relaxation-of-assembler-resolved-references.patch b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0004-Fix-relaxation-of-assembler-resolved-references.patch
similarity index 100%
rename from meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0004-Fix-relaxation-of-assembler-resolved-references.patch
rename to meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0004-Fix-relaxation-of-assembler-resolved-references.patch
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0005-Fixup-MicroBlaze-debug_loc-sections-after-linker-rel.patch b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0005-Fixup-MicroBlaze-debug_loc-sections-after-linker-rel.patch
new file mode 100644
index 0000000..6cdd2cc
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0005-Fixup-MicroBlaze-debug_loc-sections-after-linker-rel.patch
@@ -0,0 +1,243 @@
+From 5bf68bc39976903929f730b6eed18686c3563c05 Mon Sep 17 00:00:00 2001
+From: Nagaraju Mekala <nagaraju.mekala@xilinx.com>
+Date: Mon, 28 Aug 2017 19:53:56 -0700
+Subject: [PATCH] Fixup MicroBlaze debug_loc sections after linker relaxation
+
+Fixup debug_loc sections after linker relaxation Adds a new reloctype
+R_MICROBLAZE_32_NONE, used for passing reloc info from the assembler to
+the linker when the linker manages to fully resolve a local symbol
+reference.
+
+This is a workaround for design flaws in the assembler to
+linker interface with regards to linker relaxation.
+
+08/2018
+Rebased for binutils 2.31
+ - Some RELOC_NUMBERs were added upstream, rebased to use 33 instead of 30
+
+Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
+Signed-off-by: Nagaraju Mekala <nmekala@xilinx.com>
+Signed-off-by: Manjukumar Matha <manjukumar.harthikote-matha@xilinx.com>
+Signed-off-by: Alejandro Enedino Hernandez Samaniego <alejandr@xilinx.com>
+
+Upstream-Status: Pending
+
+---
+ bfd/bfd-in2.h              |  9 +++++++--
+ bfd/elf32-microblaze.c     | 45 ++++++++++++++++++++++++++++++++++++++-------
+ bfd/libbfd.h               |  1 +
+ bfd/reloc.c                |  6 ++++++
+ binutils/readelf.c         |  4 ++++
+ gas/config/tc-microblaze.c |  5 ++++-
+ include/elf/microblaze.h   |  1 +
+ 7 files changed, 61 insertions(+), 10 deletions(-)
+
+Index: git/bfd/bfd-in2.h
+===================================================================
+--- git.orig/bfd/bfd-in2.h
++++ git/bfd/bfd-in2.h
+@@ -5791,10 +5791,15 @@ value relative to the read-write small d
+ expressions of the form "Symbol Op Symbol"  */
+   BFD_RELOC_MICROBLAZE_32_SYM_OP_SYM,
+ 
+-/* This is a 64 bit reloc that stores the 32 bit pc relative
++/* This is a 32 bit reloc that stores the 32 bit pc relative
+ value in two words (with an imm instruction).  No relocation is
+ done here - only used for relaxing  */
+-  BFD_RELOC_MICROBLAZE_64_NONE,
++  BFD_RELOC_MICROBLAZE_32_NONE,
++
++/* This is a 64 bit reloc that stores the 32 bit pc relative
++ *  +value in two words (with an imm instruction).  No relocation is
++ *   +done here - only used for relaxing  */
++    BFD_RELOC_MICROBLAZE_64_NONE,
+ 
+ /* This is a 64 bit reloc that stores the 32 bit pc relative
+ value in two words (with an imm instruction).  The relocation is
+Index: git/bfd/elf32-microblaze.c
+===================================================================
+--- git.orig/bfd/elf32-microblaze.c
++++ git/bfd/elf32-microblaze.c
+@@ -176,6 +176,20 @@ static reloc_howto_type microblaze_elf_h
+ 	  0x0000ffff,		/* Dest Mask.  */
+ 	  FALSE),		/* PC relative offset?  */
+ 
++   HOWTO (R_MICROBLAZE_32_NONE,   /* Type.  */
++          0,         /* Rightshift.  */
++          2,            /* Size (0 = byte, 1 = short, 2 = long).  */
++          32,           /* Bitsize.  */
++          TRUE,         /* PC_relative.  */
++          0,           /* Bitpos.  */
++          complain_overflow_bitfield,  /* Complain on overflow.  */
++          NULL,                  /* Special Function.  */
++          "R_MICROBLAZE_32_NONE",/* Name.  */
++          FALSE,       /* Partial Inplace.  */
++          0,          /* Source Mask.  */
++          0,         /* Dest Mask.  */
++          FALSE),       /* PC relative offset?  */
++
+    /* This reloc does nothing.	Used for relaxation.  */
+    HOWTO (R_MICROBLAZE_64_NONE,	/* Type.  */
+ 	  0,			/* Rightshift.  */
+@@ -562,6 +576,9 @@ microblaze_elf_reloc_type_lookup (bfd *
+     case BFD_RELOC_NONE:
+       microblaze_reloc = R_MICROBLAZE_NONE;
+       break;
++    case BFD_RELOC_MICROBLAZE_32_NONE:
++      microblaze_reloc = R_MICROBLAZE_32_NONE;
++      break;
+     case BFD_RELOC_MICROBLAZE_64_NONE:
+       microblaze_reloc = R_MICROBLAZE_64_NONE;
+       break;
+@@ -1918,14 +1935,23 @@ microblaze_elf_relax_section (bfd *abfd,
+ 		}
+ 	      break;
+ 	    case R_MICROBLAZE_NONE:
++            case R_MICROBLAZE_32_NONE:
+ 	      {
+ 		/* This was a PC-relative instruction that was
+ 		   completely resolved.  */
+ 		int sfix, efix;
++            unsigned int val;
+ 		bfd_vma target_address;
+ 		target_address = irel->r_addend + irel->r_offset;
+ 		sfix = calc_fixup (irel->r_offset, 0, sec);
+ 		efix = calc_fixup (target_address, 0, sec);
++
++            /* Validate the in-band val.  */
++            val = bfd_get_32 (abfd, contents + irel->r_offset);
++            if (val != irel->r_addend && ELF32_R_TYPE (irel->r_info) == R_MICROBLAZE_32_NONE) {
++               fprintf(stderr, "%d: CORRUPT relax reloc %x %lx\n", __LINE__, val, irel->r_addend);
++            }
++
+ 		irel->r_addend -= (efix - sfix);
+ 		/* Should use HOWTO.  */
+ 		microblaze_bfd_write_imm_value_32 (abfd, contents + irel->r_offset,
+@@ -1973,12 +1999,16 @@ microblaze_elf_relax_section (bfd *abfd,
+ 	  irelscanend = irelocs + o->reloc_count;
+ 	  for (irelscan = irelocs; irelscan < irelscanend; irelscan++)
+ 	    {
+-              if (ELF32_R_TYPE (irelscan->r_info) == (int) R_MICROBLAZE_NONE)
++              if (1 && ELF32_R_TYPE (irelscan->r_info) == (int) R_MICROBLAZE_32_NONE)
+                 {
+                   unsigned int val;
+ 
+                   isym = isymbuf + ELF32_R_SYM (irelscan->r_info);
+ 
++                  /* hax: We only do the following fixup for debug location lists.  */
++                  if (strcmp(".debug_loc", o->name))
++                    continue;
++
+                   /* This was a PC-relative instruction that was completely resolved.  */
+                   if (ocontents == NULL)
+                     {
+@@ -2003,15 +2033,16 @@ microblaze_elf_relax_section (bfd *abfd,
+                         }
+                     }
+ 
+-                  irelscan->r_addend -= calc_fixup (irelscan->r_addend
+-                                                    + isym->st_value, sec);
+                   val = bfd_get_32 (abfd, ocontents + irelscan->r_offset);
++
++                  if (val != irelscan->r_addend) {
++                    fprintf(stderr, "%d: CORRUPT relax reloc! %x %lx\n", __LINE__, val, irelscan->r_addend);
++                  }
++                  irelscan->r_addend -= calc_fixup (irelscan->r_addend, 0, sec);
++
+                   microblaze_bfd_write_imm_value_32 (abfd, ocontents + irelscan->r_offset,
+                                                      irelscan->r_addend);
+               }
+-              if (ELF32_R_TYPE (irelscan->r_info) == (int) R_MICROBLAZE_64_NONE) {
+-                  fprintf(stderr, "Unhandled NONE 64\n");
+-              }
+ 	      if (ELF32_R_TYPE (irelscan->r_info) == (int) R_MICROBLAZE_32)
+ 		{
+ 		  isym = isymbuf + ELF32_R_SYM (irelscan->r_info);
+@@ -2071,7 +2102,7 @@ microblaze_elf_relax_section (bfd *abfd,
+ 			      elf_section_data (o)->this_hdr.contents = ocontents;
+ 			    }
+ 			}
+-		      irelscan->r_addend -= calc_fixup (irel->r_addend
++              irelscan->r_addend -= calc_fixup (irelscan->r_addend
+ 							+ isym->st_value,
+ 							0,
+ 							sec);
+Index: git/bfd/libbfd.h
+===================================================================
+--- git.orig/bfd/libbfd.h
++++ git/bfd/libbfd.h
+@@ -2862,6 +2862,7 @@ static const char *const bfd_reloc_code_
+   "BFD_RELOC_MICROBLAZE_32_ROSDA",
+   "BFD_RELOC_MICROBLAZE_32_RWSDA",
+   "BFD_RELOC_MICROBLAZE_32_SYM_OP_SYM",
++  "BFD_RELOC_MICROBLAZE_32_NONE",
+   "BFD_RELOC_MICROBLAZE_64_NONE",
+   "BFD_RELOC_MICROBLAZE_64_GOTPC",
+   "BFD_RELOC_MICROBLAZE_64_GOT",
+Index: git/bfd/reloc.c
+===================================================================
+--- git.orig/bfd/reloc.c
++++ git/bfd/reloc.c
+@@ -6865,6 +6865,12 @@ ENUMDOC
+   This is a 32 bit reloc for the microblaze to handle
+   expressions of the form "Symbol Op Symbol"
+ ENUM
++  BFD_RELOC_MICROBLAZE_32_NONE
++ENUMDOC
++  This is a 32 bit reloc that stores the 32 bit pc relative
++  value in two words (with an imm instruction).  No relocation is
++  done here - only used for relaxing
++ENUM
+   BFD_RELOC_MICROBLAZE_64_NONE
+ ENUMDOC
+   This is a 64 bit reloc that stores the 32 bit pc relative
+Index: git/binutils/readelf.c
+===================================================================
+--- git.orig/binutils/readelf.c
++++ git/binutils/readelf.c
+@@ -12908,6 +12908,10 @@ is_none_reloc (Filedata * filedata, unsi
+ 	      || reloc_type == 32 /* R_AVR_DIFF32.  */);
+     case EM_METAG:
+       return reloc_type == 3; /* R_METAG_NONE.  */
++    case EM_MICROBLAZE:
++      return reloc_type == 33 /* R_MICROBLAZE_32_NONE.  */
++             || reloc_type == 0 /* R_MICROBLAZE_NONE.  */
++             || reloc_type == 9; /* R_MICROBLAZE_64_NONE.  */
+     case EM_NDS32:
+       return (reloc_type == 0       /* R_XTENSA_NONE.  */
+ 	      || reloc_type == 204  /* R_NDS32_DIFF8.  */
+Index: git/gas/config/tc-microblaze.c
+===================================================================
+--- git.orig/gas/config/tc-microblaze.c
++++ git/gas/config/tc-microblaze.c
+@@ -2201,7 +2201,9 @@ md_apply_fix (fixS *   fixP,
+       /* This fixup has been resolved.  Create a reloc in case the linker
+ 	 moves code around due to relaxing.  */
+       if (fixP->fx_r_type == BFD_RELOC_64_PCREL)
+-	fixP->fx_r_type = BFD_RELOC_MICROBLAZE_64_NONE;
++	    fixP->fx_r_type = BFD_RELOC_MICROBLAZE_64_NONE;
++      else if (fixP->fx_r_type == BFD_RELOC_32)
++        fixP->fx_r_type = BFD_RELOC_MICROBLAZE_32_NONE;
+       else
+ 	fixP->fx_r_type = BFD_RELOC_NONE;
+       fixP->fx_addsy = section_symbol (absolute_section);
+@@ -2426,6 +2428,7 @@ tc_gen_reloc (asection * section ATTRIBU
+   switch (fixp->fx_r_type)
+     {
+     case BFD_RELOC_NONE:
++    case BFD_RELOC_MICROBLAZE_32_NONE: 
+     case BFD_RELOC_MICROBLAZE_64_NONE:
+     case BFD_RELOC_32:
+     case BFD_RELOC_MICROBLAZE_32_LO:
+Index: git/include/elf/microblaze.h
+===================================================================
+--- git.orig/include/elf/microblaze.h
++++ git/include/elf/microblaze.h
+@@ -61,6 +61,7 @@ START_RELOC_NUMBERS (elf_microblaze_relo
+   RELOC_NUMBER (R_MICROBLAZE_TEXTPCREL_64, 30)  /* PC-relative TEXT offset.  */
+   RELOC_NUMBER (R_MICROBLAZE_TEXTREL_64, 31)    /* TEXT Entry offset 64-bit.  */
+   RELOC_NUMBER (R_MICROBLAZE_TEXTREL_32_LO, 32) /* TEXT Entry offset 32-bit.  */
++  RELOC_NUMBER (R_MICROBLAZE_32_NONE, 33)
+ END_RELOC_NUMBERS (R_MICROBLAZE_max)
+ 
+ /* Global base address names.  */
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0006-Fix-bug-in-MicroBlaze-TLSTPREL-Relocation.patch b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0006-Fix-bug-in-MicroBlaze-TLSTPREL-Relocation.patch
new file mode 100644
index 0000000..8d3d538
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0006-Fix-bug-in-MicroBlaze-TLSTPREL-Relocation.patch
@@ -0,0 +1,35 @@
+From ca0336a49c33ccb78962530f2affff8982027e8e Mon Sep 17 00:00:00 2001
+From: Nagaraju Mekala <nagaraju.mekala@xilinx.com>
+Date: Mon, 28 Aug 2017 19:53:58 -0700
+Subject: [PATCH] Fix bug in MicroBlaze TLSTPREL Relocation
+
+Fixed the problem related to the fixup/relocations TLSTPREL.
+When the fixup is applied the addend is not added at the correct offset
+of the instruction. The offset is hard coded considering its big endian
+and it fails for Little endian. This patch allows support for both
+big & little-endian compilers
+
+Signed-off-by: Nagaraju Mekala <nagaraju.mekala@xilinx.com>
+Signed-off-by: Manjukumar Matha <manjukumar.harthikote-matha@xilinx.com>
+Upstream-Status: Pending
+
+---
+ bfd/elf32-microblaze.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/bfd/elf32-microblaze.c b/bfd/elf32-microblaze.c
+index 1dc56f7..d4e53de 100644
+--- a/bfd/elf32-microblaze.c
++++ b/bfd/elf32-microblaze.c
+@@ -1451,9 +1451,9 @@ microblaze_elf_relocate_section (bfd *output_bfd,
+ 	      relocation += addend;
+ 	      relocation -= dtprel_base(info);
+ 	      bfd_put_16 (input_bfd, (relocation >> 16) & 0xffff,
+-			  contents + offset + 2);
++			  contents + offset + endian);
+ 	      bfd_put_16 (input_bfd, relocation & 0xffff,
+-			  contents + offset + 2 + INST_WORD_SIZE);
++			  contents + offset + endian + INST_WORD_SIZE);
+ 	      break;
+ 	    case (int) R_MICROBLAZE_TEXTREL_64:
+ 	    case (int) R_MICROBLAZE_TEXTREL_32_LO:
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0007-Add-MicroBlaze-address-extension-instructions.patch b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0007-Add-MicroBlaze-address-extension-instructions.patch
similarity index 100%
rename from meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0007-Add-MicroBlaze-address-extension-instructions.patch
rename to meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0007-Add-MicroBlaze-address-extension-instructions.patch
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0008-Add-new-MicroBlaze-bit-field-instructions.patch b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0008-Add-new-MicroBlaze-bit-field-instructions.patch
similarity index 100%
rename from meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0008-Add-new-MicroBlaze-bit-field-instructions.patch
rename to meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0008-Add-new-MicroBlaze-bit-field-instructions.patch
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0009-Fixing-MicroBlaze-IMM-bug.patch b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0009-Fixing-MicroBlaze-IMM-bug.patch
similarity index 100%
rename from meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0009-Fixing-MicroBlaze-IMM-bug.patch
rename to meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0009-Fixing-MicroBlaze-IMM-bug.patch
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0010-Fixed-bug-in-GCC-so-that-it-will-support-.long-0U-an.patch b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0010-Fixed-bug-in-GCC-so-that-it-will-support-.long-0U-an.patch
similarity index 100%
rename from meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0010-Fixed-bug-in-GCC-so-that-it-will-support-.long-0U-an.patch
rename to meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0010-Fixed-bug-in-GCC-so-that-it-will-support-.long-0U-an.patch
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0011-Fixing-MicroBlaze-constant-range-check-issue.patch b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0011-Fixing-MicroBlaze-constant-range-check-issue.patch
similarity index 100%
rename from meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0011-Fixing-MicroBlaze-constant-range-check-issue.patch
rename to meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0011-Fixing-MicroBlaze-constant-range-check-issue.patch
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0012-MicroBlaze-fix-mask-for-barrel-shift-instructions.patch b/meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0012-MicroBlaze-fix-mask-for-barrel-shift-instructions.patch
similarity index 100%
rename from meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.30/0012-MicroBlaze-fix-mask-for-barrel-shift-instructions.patch
rename to meta-xilinx/meta-xilinx-bsp/recipes-microblaze/binutils/binutils-2.31/0012-MicroBlaze-fix-mask-for-barrel-shift-instructions.patch
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/kernel-module-vcu.bb b/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/kernel-module-vcu.bb
index e09dd5d..8d1380f 100644
--- a/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/kernel-module-vcu.bb
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/kernel-module-vcu.bb
@@ -5,14 +5,14 @@
 LIC_FILES_CHKSUM = "file://LICENSE.md;md5=eb723b61539feef013de476e68b5c50a"
 
 XILINX_VCU_VERSION = "1.0.0"
-XILINX_RELEASE_VERSION = "2018.1"
+XILINX_RELEASE_VERSION = "2018.3"
 PV = "${XILINX_VCU_VERSION}-xilinx-${XILINX_RELEASE_VERSION}+git${SRCPV}"
 
 S = "${WORKDIR}/git"
 
 BRANCH ?= "master"
 REPO ?= "git://github.com/xilinx/vcu-modules.git;protocol=https"
-SRCREV ?= "646185390cc1850969c0fa3db59fc8f0e511922e"
+SRCREV ?= "f6a9093ec32ee97a2df065aee8b8e676c2024f01"
 
 BRANCHARG = "${@['nobranch=1', 'branch=${BRANCH}'][d.getVar('BRANCH', True) != '']}"
 SRC_URI = "${REPO};${BRANCHARG}"
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/libomxil-xlnx.bb b/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/libomxil-xlnx.bb
index 76fdb9a..18fa032 100644
--- a/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/libomxil-xlnx.bb
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/libomxil-xlnx.bb
@@ -4,12 +4,12 @@
 LIC_FILES_CHKSUM = "file://LICENSE.md;md5=03a7aef7e6f6a76a59fd9b8ba450b493"
 
 XILINX_VCU_VERSION = "1.0.0"
-XILINX_RELEASE_VERSION = "2018.1"
+XILINX_RELEASE_VERSION = "2018.3"
 PV = "${XILINX_VCU_VERSION}-xilinx-${XILINX_RELEASE_VERSION}+git${SRCPV}"
 
 BRANCH ?= "master"
 REPO   ?= "git://github.com/xilinx/vcu-omx-il.git;protocol=https"
-SRCREV ?= "68e385ace99ab699feaa50f24b7a78680c411f75"
+SRCREV ?= "cf4b031ac88c7889e4f29ac7fc8ca7592bf12144"
 
 BRANCHARG = "${@['nobranch=1', 'branch=${BRANCH}'][d.getVar('BRANCH', True) != '']}"
 SRC_URI = "${REPO};${BRANCHARG}"
@@ -37,8 +37,8 @@
 
     install -m 0644 ${S}/omx_header/*.h ${D}${includedir}/vcu-omx-il
 
-    install -Dm 0755 ${S}/bin/omx_decoder.exe ${D}/${bindir}/omx_decoder.exe
-    install -Dm 0755 ${S}/bin/omx_encoder.exe ${D}/${bindir}/omx_encoder.exe
+    install -Dm 0755 ${S}/bin/omx_decoder ${D}/${bindir}/omx_decoder
+    install -Dm 0755 ${S}/bin/omx_encoder ${D}/${bindir}/omx_encoder
 
     oe_libinstall -C ${S}/bin/ -so libOMX.allegro.core ${D}/${libdir}/
     oe_libinstall -C ${S}/bin/ -so libOMX.allegro.video_decoder ${D}/${libdir}/
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/libvcu-xlnx.bb b/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/libvcu-xlnx.bb
index 8e2369b..b068aa8 100644
--- a/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/libvcu-xlnx.bb
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/libvcu-xlnx.bb
@@ -4,12 +4,12 @@
 LIC_FILES_CHKSUM = "file://LICENSE.md;md5=03a7aef7e6f6a76a59fd9b8ba450b493"
 
 XILINX_VCU_VERSION = "1.0.0"
-XILINX_RELEASE_VERSION = "2018.1"
+XILINX_RELEASE_VERSION = "2018.3"
 PV = "${XILINX_VCU_VERSION}-xilinx-${XILINX_RELEASE_VERSION}+git${SRCPV}"
 
 BRANCH ?= "master"
 REPO   ?= "git://github.com/xilinx/vcu-ctrl-sw.git;protocol=https"
-SRCREV = "aa4b6871346c915f28a069190afec5d30963762f"
+SRCREV ?= "1cb5281d319ea4f3c0eb5514864c80d95e78fe6e"
 
 BRANCHARG = "${@['nobranch=1', 'branch=${BRANCH}'][d.getVar('BRANCH', True) != '']}"
 SRC_URI = "${REPO};${BRANCHARG}"
@@ -29,8 +29,8 @@
     install -d ${D}${libdir}
     install -d ${D}${includedir}/vcu-ctrl-sw/include
 
-    install -Dm 0755 ${S}/bin/AL_Encoder.exe ${D}/${bindir}/AL_Encoder.exe
-    install -Dm 0755 ${S}/bin/AL_Decoder.exe ${D}/${bindir}/AL_Decoder.exe
+    install -Dm 0755 ${S}/bin/ctrlsw_encoder ${D}/${bindir}/ctrlsw_encoder
+    install -Dm 0755 ${S}/bin/ctrlsw_decoder ${D}/${bindir}/ctrlsw_decoder
 
     oe_runmake install_headers INSTALL_HDR_PATH=${D}${includedir}/vcu-ctrl-sw/include
     oe_libinstall -C ${S}/bin/ -so liballegro_decode ${D}/${libdir}/
diff --git a/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/vcu-firmware.bb b/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/vcu-firmware.bb
index 1cb2125..da447fc 100644
--- a/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/vcu-firmware.bb
+++ b/meta-xilinx/meta-xilinx-bsp/recipes-multimedia/vcu/vcu-firmware.bb
@@ -4,14 +4,14 @@
 LIC_FILES_CHKSUM = "file://LICENSE;md5=63b45903a9a50120df488435f03cf498"
 
 XILINX_VCU_VERSION = "1.0.0"
-XILINX_RELEASE_VERSION = "2018.1"
+XILINX_RELEASE_VERSION = "2018.3"
 PV = "${XILINX_VCU_VERSION}-xilinx-${XILINX_RELEASE_VERSION}+git${SRCPV}"
 
 S  = "${WORKDIR}/git"
 
 BRANCH ?= "master"
 REPO ?= "git://github.com/xilinx/vcu-firmware.git;protocol=https"
-SRCREV ?= "7c6f282da07253c1987665846ed676059925ef40"
+SRCREV ?= "d01951905e1aedb179d838a6b86016f34e2f4966"
 
 BRANCHARG = "${@['nobranch=1', 'branch=${BRANCH}'][d.getVar('BRANCH', True) != '']}"
 SRC_URI   = "${REPO};${BRANCHARG}"
diff --git a/meta-xilinx/meta-xilinx-contrib/conf/layer.conf b/meta-xilinx/meta-xilinx-contrib/conf/layer.conf
index ad24877..58c2a46 100644
--- a/meta-xilinx/meta-xilinx-contrib/conf/layer.conf
+++ b/meta-xilinx/meta-xilinx-contrib/conf/layer.conf
@@ -12,5 +12,5 @@
 LAYERDEPENDS_xilinx-contrib = "core"
 LAYERDEPENDS_xilinx-contrib = "xilinx"
 
-LAYERSERIES_COMPAT_xilinx-contrib = "sumo"
+LAYERSERIES_COMPAT_xilinx-contrib = "sumo thud"
 
diff --git a/meta-xilinx/meta-xilinx-contrib/conf/machine/minized-zynq7.conf b/meta-xilinx/meta-xilinx-contrib/conf/machine/minized-zynq7.conf
index 8ee1980..de617d0 100644
--- a/meta-xilinx/meta-xilinx-contrib/conf/machine/minized-zynq7.conf
+++ b/meta-xilinx/meta-xilinx-contrib/conf/machine/minized-zynq7.conf
@@ -4,18 +4,16 @@
 
 require conf/machine/include/tune-zynq.inc
 require conf/machine/include/machine-xilinx-default.inc
-require conf/machine/include/machine-xilinx-board.inc
 
 MACHINE_FEATURES = "ext2 vfat usbhost wifi bluetooth"
 
 # u-boot configuration
 PREFERRED_PROVIDER_virtual/bootloader = "u-boot"
 UBOOT_MACHINE = "zynq_minized_config"
-SPL_BINARY = "spl/boot.bin"
 
 EXTRA_IMAGEDEPENDS += " \
 		u-boot-zynq-uenv \
-		virtual/boot-bin \
+		virtual/bootloader \
 		"
 
 SERIAL_CONSOLE = "115200 ttyPS0"
@@ -26,7 +24,5 @@
 MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS += "linux-firmware-bcm43430"
 
 IMAGE_BOOT_FILES += " \
-		boot.bin \
-		${MACHINE}.dtb \
 		uEnv.txt \
 		"
diff --git a/meta-xilinx/meta-xilinx-contrib/recipes-bsp/u-boot/files/minized-u-boot.patch b/meta-xilinx/meta-xilinx-contrib/recipes-bsp/u-boot/files/minized-u-boot.patch
deleted file mode 100644
index 4b9d72b..0000000
--- a/meta-xilinx/meta-xilinx-contrib/recipes-bsp/u-boot/files/minized-u-boot.patch
+++ /dev/null
@@ -1,217 +0,0 @@
-From dfe572bcea9b74086d5bd9b963af26e64a043336 Mon Sep 17 00:00:00 2001
-From: Clement Laigle <clement.laigle8@gmail.com>
-Date: Sun, 10 Jun 2018 23:21:28 +0200
-Subject: [PATCH] zynq: Add initial support for Avnet MiniZed
-
-Initial support for Avnet MiniZed board.
-
-Signed-off-by: Clement Laigle <clement.laigle8@gmail.com>
----
- arch/arm/dts/Makefile          |   1 +
- arch/arm/dts/zynq-minized.dts  | 106 +++++++++++++++++++++++++++++++++++++++++
- configs/zynq_minized_defconfig |  68 ++++++++++++++++++++++++++
- 3 files changed, 175 insertions(+)
- create mode 100644 arch/arm/dts/zynq-minized.dts
- create mode 100644 configs/zynq_minized_defconfig
-
-diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
-index a895c70..32f9ae1 100644
---- a/arch/arm/dts/Makefile
-+++ b/arch/arm/dts/Makefile
-@@ -132,6 +132,7 @@ dtb-$(CONFIG_ARCH_ZYNQ) += \
- 	zynq-cse-qspi-single.dtb \
- 	zynq-microzed.dtb \
- 	zynq-picozed.dtb \
-+	zynq-minized.dtb \
- 	zynq-syzygy-hub.dtb \
- 	zynq-topic-miami.dtb \
- 	zynq-topic-miamilite.dtb \
-diff --git a/arch/arm/dts/zynq-minized.dts b/arch/arm/dts/zynq-minized.dts
-new file mode 100644
-index 0000000..3a05518
---- /dev/null
-+++ b/arch/arm/dts/zynq-minized.dts
-@@ -0,0 +1,106 @@
-+// SPDX-License-Identifier: GPL-2.0+
-+/*
-+ * dts file for Avnet MiniZed board
-+ *
-+ * (C) Copyright 2017 - 2018, Xilinx, Inc.
-+ *
-+ * Ibai Erkiaga <ibai.erkiaga-elorza@xilinx.com>
-+ */
-+
-+/dts-v1/;
-+#include "zynq-7000.dtsi"
-+
-+/ {
-+       model = "Avnet Zynq MiniZed Development Board";
-+       compatible = "avnet,minized", "xlnx,zynq-7000";
-+
-+       aliases {
-+               serial0 = &uart1;
-+               serial1 = &uart0;
-+               spi0 = &qspi;
-+               mmc0 = &sdhci0;
-+       };
-+
-+       memory@0 {
-+               device_type = "memory";
-+               reg = <0x0 0x20000000>;
-+       };
-+
-+       chosen {
-+               bootargs = "";
-+               stdout-path = "serial0:115200n8";
-+       };
-+
-+       usb_phy0: phy0 {
-+               compatible = "usb-nop-xceiv";
-+               #phy-cells = <0>;
-+       };
-+};
-+
-+&qspi {
-+       status = "okay";
-+       is-dual = <0>;
-+       num-cs = <1>;
-+       flash@0 {
-+               compatible = "micron,m25p128";
-+               reg = <0x0>;
-+               spi-tx-bus-width = <4>;
-+               spi-rx-bus-width = <4>;
-+               spi-max-frequency = <50000000>;
-+               partitions {
-+                       compatible = "fixed-partitions";
-+                       #address-cells = <1>;
-+                       #size-cells = <1>;
-+                       partition@0 {
-+                               label = "boot";
-+                               reg = <0x0 0xff0000>;
-+                       };
-+
-+                       partition@270000 {
-+                               label = "kernel";
-+                               reg = <0x270000 0xd80000>;
-+                       };
-+
-+                       partition@ff0000 {
-+                               label = "bootenv";
-+                               reg = <0xff0000 0x10000>;
-+                       };
-+
-+                       partition@1000000 {
-+                               label = "spare";
-+                               reg = <0x1000000 0x0>;
-+                       };
-+               };
-+       };
-+};
-+
-+&uart0 {
-+       status = "okay";
-+};
-+
-+&uart1 {
-+       u-boot,dm-pre-reloc;
-+       status = "okay";
-+};
-+
-+&usb0 {
-+       status = "okay";
-+       dr_mode = "host";
-+       usb-phy = <&usb_phy0>;
-+       usb-reset = <&gpio0 7 0>; /* USB_RST_N-MIO7 */
-+};
-+
-+&sdhci1 {
-+       status = "okay";
-+       non-removable;
-+       bus-width = <4>;
-+       max-frequency = <12000000>;
-+
-+       #address-cells = <1>;
-+       #size-cells = <0>;
-+       mmccard: mmccard@0 {
-+               compatible = "mmc-card";
-+               reg = <0>;
-+               broken-hpi;
-+       };
-+};
-diff --git a/configs/zynq_minized_defconfig b/configs/zynq_minized_defconfig
-new file mode 100644
-index 0000000..44d65fc
---- /dev/null
-+++ b/configs/zynq_minized_defconfig
-@@ -0,0 +1,68 @@
-+CONFIG_ARM=y
-+CONFIG_ARCH_ZYNQ=y
-+CONFIG_SYS_TEXT_BASE=0x4000000
-+CONFIG_SPL=y
-+CONFIG_SPL_STACK_R_ADDR=0x200000
-+CONFIG_DEFAULT_DEVICE_TREE="zynq-minized"
-+CONFIG_DEBUG_UART=y
-+CONFIG_DISTRO_DEFAULTS=y
-+# CONFIG_DISPLAY_CPUINFO is not set
-+CONFIG_FIT=y
-+CONFIG_FIT_SIGNATURE=y
-+CONFIG_FIT_VERBOSE=y
-+CONFIG_BOOTCOMMAND="run $modeboot || run distro_bootcmd"
-+CONFIG_SPL_STACK_R=y
-+CONFIG_SPL_OS_BOOT=y
-+CONFIG_SYS_PROMPT="Zynq> "
-+CONFIG_CMD_THOR_DOWNLOAD=y
-+CONFIG_CMD_DFU=y
-+# CONFIG_CMD_FLASH is not set
-+CONFIG_CMD_FPGA_LOADBP=y
-+CONFIG_CMD_FPGA_LOADFS=y
-+CONFIG_CMD_FPGA_LOADMK=y
-+CONFIG_CMD_FPGA_LOADP=y
-+CONFIG_CMD_GPIO=y
-+CONFIG_CMD_MMC=y
-+CONFIG_CMD_SF=y
-+CONFIG_CMD_USB=y
-+# CONFIG_CMD_SETEXPR is not set
-+CONFIG_CMD_TFTPPUT=y
-+CONFIG_CMD_CACHE=y
-+CONFIG_CMD_EXT4_WRITE=y
-+CONFIG_ENV_IS_IN_SPI_FLASH=y
-+CONFIG_NET_RANDOM_ETHADDR=y
-+CONFIG_SPL_DM_SEQ_ALIAS=y
-+CONFIG_DFU_MMC=y
-+CONFIG_DFU_RAM=y
-+CONFIG_FPGA_XILINX=y
-+CONFIG_FPGA_ZYNQPL=y
-+CONFIG_DM_GPIO=y
-+CONFIG_MMC_SDHCI=y
-+CONFIG_MMC_SDHCI_ZYNQ=y
-+CONFIG_SPI_FLASH=y
-+CONFIG_SPI_FLASH_BAR=y
-+CONFIG_SPI_FLASH_SPANSION=y
-+CONFIG_SPI_FLASH_STMICRO=y
-+CONFIG_SPI_FLASH_WINBOND=y
-+CONFIG_PHY_MARVELL=y
-+CONFIG_PHY_REALTEK=y
-+CONFIG_PHY_XILINX=y
-+CONFIG_ZYNQ_GEM=y
-+CONFIG_DEBUG_UART_ZYNQ=y
-+CONFIG_DEBUG_UART_BASE=0xe0001000
-+CONFIG_DEBUG_UART_CLOCK=50000000
-+CONFIG_ZYNQ_SERIAL=y
-+CONFIG_ZYNQ_QSPI=y
-+CONFIG_USB=y
-+CONFIG_USB_EHCI_HCD=y
-+CONFIG_USB_ULPI_VIEWPORT=y
-+CONFIG_USB_ULPI=y
-+CONFIG_USB_STORAGE=y
-+CONFIG_USB_GADGET=y
-+CONFIG_USB_GADGET_MANUFACTURER="Xilinx"
-+CONFIG_USB_GADGET_VENDOR_NUM=0x03fd
-+CONFIG_USB_GADGET_PRODUCT_NUM=0x0300
-+CONFIG_CI_UDC=y
-+CONFIG_USB_GADGET_DOWNLOAD=y
-+CONFIG_USB_FUNCTION_THOR=y
-+CONFIG_OF_EMBED=y
--- 
-2.7.4
-
diff --git a/meta-xilinx/meta-xilinx-contrib/recipes-bsp/u-boot/u-boot_%.bbappend b/meta-xilinx/meta-xilinx-contrib/recipes-bsp/u-boot/u-boot_%.bbappend
deleted file mode 100644
index 2fdbdb4..0000000
--- a/meta-xilinx/meta-xilinx-contrib/recipes-bsp/u-boot/u-boot_%.bbappend
+++ /dev/null
@@ -1,8 +0,0 @@
-FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
-
-SRC_URI_append = " file://minized-u-boot.patch"
-
-HAS_PLATFORM_INIT_append = " \
-		zynq_minized_config \
-		"
-
diff --git a/meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux-firmware/linux-firmware_%.bbappend b/meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux-firmware/linux-firmware_%.bbappend
index 7655caf..b34eea3 100644
--- a/meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux-firmware/linux-firmware_%.bbappend
+++ b/meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux-firmware/linux-firmware_%.bbappend
@@ -1,11 +1,3 @@
-LICENSE_append_minized-zynq7 = "\
-    & Firmware-cypress \
-"
-
-LIC_FILES_CHKSUM_append_minized-zynq7 = "\
-    file://LICENCE.cypress;md5=cbc5f665d04f741f1e006d2096236ba7 \
-"
-NO_GENERIC_LICENSE[Firmware-cypress] = "LICENCE.cypress"
 
 SRC_URI_append_minized-zynq7 = " \
        git://github.com/murata-wireless/cyw-fmac-nvram;protocol=git;branch=orga;destsuffix=cyw-fmac-nvram;name=cyw-fmac-nvram \
@@ -28,7 +20,6 @@
 }
 
 PACKAGES_prepend_minized-zynq7 = "\
-    ${PN}-cypress-license \
     ${PN}-bcm43430a1-hcd \
     ${PN}-mfgtest \
 "
@@ -41,11 +32,6 @@
        ${nonarch_base_libdir}/firmware/brcm/ brcmfmac43430-sdio.txt \
 "
 
-# For additional Cypress
-FILES_${PN}-cypress-license = "\
-  ${nonarch_base_libdir}/firmware/LICENCE.cypress \
-"
-
 LICENSE_${PN}-bcm43430a1-hcd = "Firmware-cypress"
 
 FILES_${PN}-bcm43430a1-hcd = " \
diff --git a/meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.1/0001-drm-xilinx-Add-encoder-for-Digilent-boards.patch b/meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.3/0001-drm-xilinx-Add-encoder-for-Digilent-boards.patch
similarity index 100%
rename from meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.1/0001-drm-xilinx-Add-encoder-for-Digilent-boards.patch
rename to meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.3/0001-drm-xilinx-Add-encoder-for-Digilent-boards.patch
diff --git a/meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.1/0002-clk-Add-driver-for-axi_dynclk-IP-Core.patch b/meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.3/0002-clk-Add-driver-for-axi_dynclk-IP-Core.patch
similarity index 100%
rename from meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.1/0002-clk-Add-driver-for-axi_dynclk-IP-Core.patch
rename to meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.3/0002-clk-Add-driver-for-axi_dynclk-IP-Core.patch
diff --git a/meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.1/0003-drm-xilinx-Fix-DPMS-transition-to-on.patch b/meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.3/0003-drm-xilinx-Fix-DPMS-transition-to-on.patch
similarity index 100%
rename from meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.1/0003-drm-xilinx-Fix-DPMS-transition-to-on.patch
rename to meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.3/0003-drm-xilinx-Fix-DPMS-transition-to-on.patch
diff --git a/meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.1/0004-minized-wifi-bluetooth.cfg b/meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.3/0004-minized-wifi-bluetooth.cfg
similarity index 100%
rename from meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.1/0004-minized-wifi-bluetooth.cfg
rename to meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx/v2018.3/0004-minized-wifi-bluetooth.cfg
diff --git a/meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx_2018.1.bbappend b/meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx_2018.3.bbappend
similarity index 100%
rename from meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx_2018.1.bbappend
rename to meta-xilinx/meta-xilinx-contrib/recipes-kernel/linux/linux-xlnx_2018.3.bbappend
diff --git a/meta-xilinx/meta-xilinx-standalone/README.md b/meta-xilinx/meta-xilinx-standalone/README.md
new file mode 100644
index 0000000..b800f37
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-standalone/README.md
@@ -0,0 +1,54 @@
+meta-xilinx-standalone
+======================
+
+This layer is meant to augment Yocto/OE functionality to provide a Baremetal/Standalone Toolchain.
+
+
+Maintainers, Mailing list, Patches
+==================================
+
+Please send any patches, pull requests, comments or questions for this layer to
+the [meta-xilinx mailing list](https://lists.yoctoproject.org/listinfo/meta-xilinx):
+
+	meta-xilinx@lists.yoctoproject.org
+
+Maintainers:
+
+	Alejandro Enedino Hernandez Samaniego <alejandr@xilinx.com>
+	Manjukumar Harthikote Matha <manjukumar.harthikote-matha@xilinx.com>
+
+Dependencies
+============
+
+This layer depends on:
+
+     URI: git://git.yoctoproject.org/poky
+
+     URI: git://git.yoctoproject.org/meta-xilinx/meta-xilinx-bsp
+
+Usage
+=====
+
+1.- Clone this layer along with the specified layers
+
+2.- $ source oe-init-build-env
+
+3.- Add this layer to BBLAYERS on conf/bblayers.conf
+
+4.- Add the following to your conf/local.conf to build for the microblaze architecture:
+
+DISTRO="xilinx-standalone"
+
+MACHINE="zynqmp-pmu"
+
+GCCVERSION="7.%"
+
+5.- Build a package:
+
+for example:
+
+$ bitbake newlib
+
+or
+
+$ bitbake meta-toolchain
diff --git a/meta-xilinx/meta-xilinx-standalone/conf/distro/xilinx-standalone.conf b/meta-xilinx/meta-xilinx-standalone/conf/distro/xilinx-standalone.conf
new file mode 100644
index 0000000..7cd23cc
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-standalone/conf/distro/xilinx-standalone.conf
@@ -0,0 +1,13 @@
+DISTRO = "xilinx-standalone"
+DISTRO_NAME = "Xilinx Standalone Distro"
+DISTRO_VERSION = "1.0"
+TARGET_VENDOR = "-xilinx"
+
+TCLIBC = "newlib"
+TCLIBCAPPEND =""
+
+# Change SDK name
+SDK_VERSION = "xilinx-standalone"
+
+require conf/distro/include/yocto-uninative.inc
+INHERIT += "uninative"
diff --git a/meta-xilinx/meta-xilinx-standalone/conf/layer.conf b/meta-xilinx/meta-xilinx-standalone/conf/layer.conf
new file mode 100644
index 0000000..7d9cc59
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-standalone/conf/layer.conf
@@ -0,0 +1,14 @@
+# We have a conf and classes directory, add to BBPATH
+BBPATH .= ":${LAYERDIR}"
+
+# We have recipes-* directories, add to BBFILES
+BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \
+	${LAYERDIR}/recipes-*/*/*.bbappend"
+
+BBFILE_COLLECTIONS += "xilinx-standalone"
+BBFILE_PATTERN_xilinx-standalone = "^${LAYERDIR}/"
+BBFILE_PRIORITY_xilinx-standalone = "5"
+
+LAYERDEPENDS_xilinx-standalone = "core xilinx"
+
+LAYERSERIES_COMPAT_xilinx-standalone = "thud"
diff --git a/meta-xilinx/meta-xilinx-standalone/conf/machine/zynqmp-pmu.conf b/meta-xilinx/meta-xilinx-standalone/conf/machine/zynqmp-pmu.conf
new file mode 100644
index 0000000..2f692db
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-standalone/conf/machine/zynqmp-pmu.conf
@@ -0,0 +1,11 @@
+DEFAULTTUNE ?= "microblaze"
+
+require conf/machine/include/microblaze/arch-microblaze.inc
+
+# Endianess, multiplier, barrel shift, pattern compare, floating point double or single, are the possibilities
+AVAILTUNES += "microblaze"
+TUNE_FEATURES_tune-microblaze = "microblaze v9.2 barrel-shift pattern-compare"
+PACKAGE_EXTRA_ARCHS_tune-microblaze = "${TUNE_PKGARCH}"
+SOC_FAMILY = "zynqmp"
+
+TARGET_LINK_HASH_STYLE_microblaze = ""
diff --git a/meta-xilinx/meta-xilinx-standalone/recipes-standalone/gcc/gcc-cross_%.bbappend b/meta-xilinx/meta-xilinx-standalone/recipes-standalone/gcc/gcc-cross_%.bbappend
new file mode 100644
index 0000000..bfcda3d
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-standalone/recipes-standalone/gcc/gcc-cross_%.bbappend
@@ -0,0 +1,18 @@
+# By using tclibc-baremetal we loose sysroot functionality due to some
+# append/override behavior We need to get that back , the following append
+# overrides everything on EXTRA_OECONF for gcc cross target it avoids
+# overlapping with crt0 because of --enable-linker-id from EXTRA_OECONF
+
+EXTRA_OECONF_BASE_pn-gcc-cross-${TARGET_ARCH}_append = " \
+    ${LTO} \
+    ${SSP} \
+    --enable-libitm \
+    --disable-bootstrap \
+    --disable-libmudflap \
+    --with-system-zlib \
+    --with-ppl=no \
+    --with-cloog=no \
+    --enable-checking=release \
+    --enable-cheaders=c_global \
+    --without-isl \
+"
diff --git a/meta-xilinx/meta-xilinx-standalone/recipes-standalone/newlib/libgloss_3.0.0.bbappend b/meta-xilinx/meta-xilinx-standalone/recipes-standalone/newlib/libgloss_3.0.0.bbappend
new file mode 100644
index 0000000..fc4db88
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-standalone/recipes-standalone/newlib/libgloss_3.0.0.bbappend
@@ -0,0 +1,10 @@
+do_configure_prepend_microblaze() {
+    # hack for microblaze, which needs xilinx.ld to literally do any linking (its hard coded in its LINK_SPEC)
+    export CC="${CC} -L${S}/libgloss/microblaze"
+}
+
+
+# We use libgloss as if it was libxil, to avoid linking issues
+do_install_append_zynqmp-pmu(){
+  cp ${D}/${libdir}/libgloss.a ${D}/${libdir}/libxil.a
+}
diff --git a/meta-xilinx/meta-xilinx-standalone/recipes-standalone/newlib/newlib_3.0.0.bbappend b/meta-xilinx/meta-xilinx-standalone/recipes-standalone/newlib/newlib_3.0.0.bbappend
new file mode 100644
index 0000000..e5249ab
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-standalone/recipes-standalone/newlib/newlib_3.0.0.bbappend
@@ -0,0 +1,4 @@
+do_configure_prepend_microblaze() {
+    # hack for microblaze, which needs xilinx.ld to literally do any linking (its hard coded in its LINK_SPEC)
+    export CC="${CC} -L${S}/libgloss/microblaze"
+}
diff --git a/meta-xilinx/meta-xilinx-standalone/recipes-standalone/pmu-firmware/pmu-firmware_2018.3.bb b/meta-xilinx/meta-xilinx-standalone/recipes-standalone/pmu-firmware/pmu-firmware_2018.3.bb
new file mode 100644
index 0000000..847e071
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-standalone/recipes-standalone/pmu-firmware/pmu-firmware_2018.3.bb
@@ -0,0 +1,71 @@
+inherit deploy
+
+LICENSE = "Proprietary"
+LIC_FILES_CHKSUM = "file://../../../../license.txt;md5=71602ce1bc2917a9be07ceee6fab6711"
+
+XILINX_RELEASE_VERSION = "v2018.3"
+SRCREV = "56f3da2afbc817988c9a45b0b26a7fef2ac91706"
+PV = "${XILINX_RELEASE_VERSION}+git${SRCPV}"
+
+SRC_URI = "git://github.com/Xilinx/embeddedsw.git;protocol=https;nobranch=1"
+
+COMPATIBLE_HOST = "microblaze.*-elf"
+COMPATIBLE_MACHINE = "^$"
+COMPATIBLE_MACHINE_zynqmp-pmu = "zynqmp-pmu"
+
+
+S = "${WORKDIR}/git/lib/sw_apps/zynqmp_pmufw/src"
+
+# The makefile does not handle parallelization
+PARALLEL_MAKE = ""
+
+do_configure() {
+    # manually do the copy_bsp step first, so as to be able to fix up use of
+    # mb-* commands
+    ${S}/../misc/copy_bsp.sh
+}
+
+COMPILER = "${CC}"
+COMPILER_FLAGS = "-O2 -c"
+EXTRA_COMPILER_FLAGS = "-g -Wall -Wextra -Os -flto -ffat-lto-objects"
+ARCHIVER = "${AR}"
+
+BSP_DIR ?= "${S}/../misc/zynqmp_pmufw_bsp"
+BSP_TARGETS_DIR ?= "${BSP_DIR}/psu_pmu_0/libsrc"
+
+def bsp_make_vars(d):
+    s = ["COMPILER", "CC", "COMPILER_FLAGS", "EXTRA_COMPILER_FLAGS", "ARCHIVER", "AR", "AS"]
+    return " ".join(["\"%s=%s\"" % (v, d.getVar(v)) for v in s])
+
+do_compile() {
+    # the Makefile in ${S}/../misc/Makefile, does not handle CC, AR, AS, etc
+    # properly. So do its job manually. Preparing the includes first, then libs.
+    for i in $(ls ${BSP_TARGETS_DIR}/*/src/Makefile); do
+        oe_runmake -C $(dirname $i) -s include ${@bsp_make_vars(d)}
+    done
+    for i in $(ls ${BSP_TARGETS_DIR}/*/src/Makefile); do
+        oe_runmake -C $(dirname $i) -s libs ${@bsp_make_vars(d)}
+    done
+
+    # --build-id=none is required due to linker script not defining a location for it.
+    # Again, recipe-systoot include is necessary
+    oe_runmake CC="${CC}" CC_FLAGS="-MMD -MP -Wl,--build-id=none -I${STAGING_DIR_TARGET}/usr/include"
+}
+
+do_install() {
+    :
+}
+
+PMU_FIRMWARE_BASE_NAME ?= "${BPN}-${PKGE}-${PKGV}-${PKGR}-${MACHINE}-${DATETIME}"
+PMU_FIRMWARE_BASE_NAME[vardepsexclude] = "DATETIME"
+
+do_deploy() {
+    install -Dm 0644 ${B}/executable.elf ${DEPLOYDIR}/${PMU_FIRMWARE_BASE_NAME}.elf
+    ln -sf ${PMU_FIRMWARE_BASE_NAME}.elf ${DEPLOYDIR}/${BPN}-${MACHINE}.elf
+    ${OBJCOPY} -O binary ${B}/executable.elf ${B}/executable.bin
+    install -m 0644 ${B}/executable.bin ${DEPLOYDIR}/${PMU_FIRMWARE_BASE_NAME}.bin
+    ln -sf ${PMU_FIRMWARE_BASE_NAME}.bin ${DEPLOYDIR}/${BPN}-${MACHINE}.bin
+}
+
+addtask deploy before do_build after do_install
+
diff --git a/poky/.gitignore b/poky/.gitignore
index d3ef473..ad1cb83 100644
--- a/poky/.gitignore
+++ b/poky/.gitignore
@@ -1,6 +1,7 @@
 *.pyc
 *.pyo
 /*.patch
+/.repo/
 /build*/
 pyshtables.py
 pstage/
diff --git a/poky/bitbake/bin/bitbake b/poky/bitbake/bin/bitbake
index 342cef9..57dec2a 100755
--- a/poky/bitbake/bin/bitbake
+++ b/poky/bitbake/bin/bitbake
@@ -38,7 +38,7 @@
 if sys.getfilesystemencoding() != "utf-8":
     sys.exit("Please use a locale setting which supports UTF-8 (such as LANG=en_US.UTF-8).\nPython can't change the filesystem locale after loading so we need a UTF-8 when Python starts or things won't work.")
 
-__version__ = "1.38.0"
+__version__ = "1.40.0"
 
 if __name__ == "__main__":
     if __version__ != bb.__version__:
diff --git a/poky/bitbake/bin/bitbake-selftest b/poky/bitbake/bin/bitbake-selftest
index afe1603..cfa7ac5 100755
--- a/poky/bitbake/bin/bitbake-selftest
+++ b/poky/bitbake/bin/bitbake-selftest
@@ -22,16 +22,21 @@
 import unittest
 try:
     import bb
+    import layerindexlib
 except RuntimeError as exc:
     sys.exit(str(exc))
 
 tests = ["bb.tests.codeparser",
+         "bb.tests.cooker",
          "bb.tests.cow",
          "bb.tests.data",
          "bb.tests.event",
          "bb.tests.fetch",
          "bb.tests.parse",
-         "bb.tests.utils"]
+         "bb.tests.utils",
+         "layerindexlib.tests.layerindexobj",
+         "layerindexlib.tests.restapi",
+         "layerindexlib.tests.cooker"]
 
 for t in tests:
     t = '.'.join(t.split('.')[:3])
diff --git a/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-intro.xml b/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-intro.xml
index 4cf0ed9..f7d312a 100644
--- a/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-intro.xml
+++ b/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-intro.xml
@@ -342,13 +342,14 @@
 
             <para>
                 When you name an append file, you can use the
-                wildcard character (%) to allow for matching recipe names.
+                "<filename>%</filename>" wildcard character to allow for matching
+                recipe names.
                 For example, suppose you have an append file named
                 as follows:
                 <literallayout class='monospaced'>
      busybox_1.21.%.bbappend
                 </literallayout>
-                That append file would match any <filename>busybox_1.21.x.bb</filename>
+                That append file would match any <filename>busybox_1.21.</filename><replaceable>x</replaceable><filename>.bb</filename>
                 version of the recipe.
                 So, the append file would match the following recipe names:
                 <literallayout class='monospaced'>
@@ -356,6 +357,14 @@
      busybox_1.21.2.bb
      busybox_1.21.3.bb
                 </literallayout>
+                <note><title>Important</title>
+                    The use of the "<filename>%</filename>" character
+                    is limited in that it only works directly in front of the
+                    <filename>.bbappend</filename> portion of the append file's
+                    name.
+                    You cannot use the wildcard character in any other
+                    location of the name.
+                </note>
                 If the <filename>busybox</filename> recipe was updated to
                 <filename>busybox_1.3.0.bb</filename>, the append name would not
                 match.
@@ -723,6 +732,163 @@
                     </literallayout>
                 </para>
             </section>
+
+            <section id='executing-a-multiple-configuration-build'>
+                <title>Executing a Multiple Configuration Build</title>
+
+                <para>
+                    BitBake is able to build multiple images or packages
+                    using a single command where the different targets
+                    require different configurations (multiple configuration
+                    builds).
+                    Each target, in this scenario, is referred to as a
+                    "multiconfig".
+                </para>
+
+                <para>
+                    To accomplish a multiple configuration build, you must
+                    define each target's configuration separately using
+                    a parallel configuration file in the build directory.
+                    The location for these multiconfig configuration files
+                    is specific.
+                    They must reside in the current build directory in
+                    a sub-directory of <filename>conf</filename> named
+                    <filename>multiconfig</filename>.
+                    Following is an example for two separate targets:
+                    <imagedata fileref="figures/bb_multiconfig_files.png" align="center" width="4in" depth="3in" />
+                </para>
+
+                <para>
+                    The reason for this required file hierarchy
+                    is because the <filename>BBPATH</filename> variable
+                    is not constructed until the layers are parsed.
+                    Consequently, using the configuration file as a
+                    pre-configuration file is not possible unless it is
+                    located in the current working directory.
+                </para>
+
+                <para>
+                    Minimally, each configuration file must define the
+                    machine and the temporary directory BitBake uses
+                    for the build.
+                    Suggested practice dictates that you do not
+                    overlap the temporary directories used during the
+                    builds.
+                </para>
+
+                <para>
+                    Aside from separate configuration files for each
+                    target, you must also enable BitBake to perform multiple
+                    configuration builds.
+                    Enabling is accomplished by setting the
+                    <link linkend='var-BBMULTICONFIG'><filename>BBMULTICONFIG</filename></link>
+                    variable in the <filename>local.conf</filename>
+                    configuration file.
+                    As an example, suppose you had configuration files
+                    for <filename>target1</filename> and
+                    <filename>target2</filename> defined in the build
+                    directory.
+                    The following statement in the
+                    <filename>local.conf</filename> file both enables
+                    BitBake to perform multiple configuration builds and
+                    specifies the two multiconfigs:
+                    <literallayout class='monospaced'>
+     BBMULTICONFIG = "target1 target2"
+                    </literallayout>
+                </para>
+
+                <para>
+                    Once the target configuration files are in place and
+                    BitBake has been enabled to perform multiple configuration
+                    builds, use the following command form to start the
+                    builds:
+                    <literallayout class='monospaced'>
+     $ bitbake [multiconfig:<replaceable>multiconfigname</replaceable>:]<replaceable>target</replaceable> [[[multiconfig:<replaceable>multiconfigname</replaceable>:]<replaceable>target</replaceable>] ... ]
+                    </literallayout>
+                    Here is an example for two multiconfigs:
+                    <filename>target1</filename> and
+                    <filename>target2</filename>:
+                    <literallayout class='monospaced'>
+     $ bitbake multiconfig:target1:<replaceable>target</replaceable> multiconfig:target2:<replaceable>target</replaceable>
+                    </literallayout>
+                </para>
+            </section>
+
+            <section id='bb-enabling-multiple-configuration-build-dependencies'>
+                <title>Enabling Multiple Configuration Build Dependencies</title>
+
+                <para>
+                    Sometimes dependencies can exist between targets
+                    (multiconfigs) in a multiple configuration build.
+                    For example, suppose that in order to build an image
+                    for a particular architecture, the root filesystem of
+                    another build for a different architecture needs to
+                    exist.
+                    In other words, the image for the first multiconfig depends
+                    on the root filesystem of the second multiconfig.
+                    This dependency is essentially that the task in the recipe
+                    that builds one multiconfig is dependent on the
+                    completion of the task in the recipe that builds
+                    another multiconfig.
+                </para>
+
+                <para>
+                    To enable dependencies in a multiple configuration
+                    build, you must declare the dependencies in the recipe
+                    using the following statement form:
+                    <literallayout class='monospaced'>
+     <replaceable>task_or_package</replaceable>[mcdepends] = "multiconfig:<replaceable>from_multiconfig</replaceable>:<replaceable>to_multiconfig</replaceable>:<replaceable>recipe_name</replaceable>:<replaceable>task_on_which_to_depend</replaceable>"
+                    </literallayout>
+                    To better show how to use this statement, consider an
+                    example with two multiconfigs: <filename>target1</filename>
+                    and <filename>target2</filename>:
+                    <literallayout class='monospaced'>
+     <replaceable>image_task</replaceable>[mcdepends] = "multiconfig:target1:target2:<replaceable>image2</replaceable>:<replaceable>rootfs_task</replaceable>"
+                    </literallayout>
+                    In this example, the
+                    <replaceable>from_multiconfig</replaceable> is "target1" and
+                    the <replaceable>to_multiconfig</replaceable> is "target2".
+                    The task on which the image whose recipe contains
+                    <replaceable>image_task</replaceable> depends on the
+                    completion of the <replaceable>rootfs_task</replaceable>
+                    used to build out <replaceable>image2</replaceable>, which
+                    is associated with the "target2" multiconfig.
+               </para>
+
+               <para>
+                   Once you set up this dependency, you can build the
+                   "target1" multiconfig using a BitBake command as follows:
+                   <literallayout class='monospaced'>
+     $ bitbake multiconfig:target1:<replaceable>image1</replaceable>
+                   </literallayout>
+                   This command executes all the tasks needed to create
+                   <replaceable>image1</replaceable> for the "target1"
+                   multiconfig.
+                   Because of the dependency, BitBake also executes through
+                   the <replaceable>rootfs_task</replaceable> for the "target2"
+                   multiconfig build.
+               </para>
+
+               <para>
+                   Having a recipe depend on the root filesystem of another
+                   build might not seem that useful.
+                   Consider this change to the statement in the
+                   <replaceable>image1</replaceable> recipe:
+                   <literallayout class='monospaced'>
+     <replaceable>image_task</replaceable>[mcdepends] = "multiconfig:target1:target2:<replaceable>image2</replaceable>:<replaceable>image_task</replaceable>"
+                   </literallayout>
+                   In this case, BitBake must create
+                   <replaceable>image2</replaceable> for the "target2"
+                   build since the "target1" build depends on it.
+               </para>
+
+               <para>
+                   Because "target1" and "target2" are enabled for multiple
+                   configuration builds and have separate configuration
+                   files, BitBake places the artifacts for each build in the
+                   respective temporary build directories.
+               </para>
+            </section>
         </section>
     </section>
 </chapter>
diff --git a/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-metadata.xml b/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-metadata.xml
index b4fc64e..2490f6e 100644
--- a/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-metadata.xml
+++ b/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-metadata.xml
@@ -342,7 +342,7 @@
 
             <para>
                 When you use this syntax, BitBake expects one or more strings.
-                Surrounding spaces are removed as well.
+                Surrounding spaces and spacing are preserved.
                 Here is an example:
                 <literallayout class='monospaced'>
      FOO = "123 456 789 123456 123 456 123 456"
@@ -352,8 +352,9 @@
      FOO2_remove = "abc def"
                 </literallayout>
                 The variable <filename>FOO</filename> becomes
-                "789 123456" and <filename>FOO2</filename> becomes
-                "ghi abcdef".
+                "&nbsp;&nbsp;789 123456&nbsp;&nbsp;&nbsp;&nbsp;"
+                and <filename>FOO2</filename> becomes
+                "&nbsp;&nbsp;ghi abcdef&nbsp;&nbsp;&nbsp;&nbsp;".
             </para>
 
             <para>
@@ -1929,6 +1930,38 @@
                         not careful.
                     </note>
                     </para></listitem>
+                <listitem><para><emphasis><filename>[number_threads]</filename>:</emphasis>
+                    Limits tasks to a specific number of simultaneous threads
+                    during execution.
+                    This varflag is useful when your build host has a large number
+                    of cores but certain tasks need to be rate-limited due to various
+                    kinds of resource constraints (e.g. to avoid network throttling).
+                    <filename>number_threads</filename> works similarly to the
+                    <link linkend='var-BB_NUMBER_THREADS'><filename>BB_NUMBER_THREADS</filename></link>
+                    variable but is task-specific.</para>
+
+                    <para>Set the value globally.
+                    For example, the following makes sure the
+                    <filename>do_fetch</filename> task uses no more than two
+                    simultaneous execution threads:
+                    <literallayout class='monospaced'>
+     do_fetch[number_threads] = "2"
+                    </literallayout>
+                    <note><title>Warnings</title>
+                        <itemizedlist>
+                            <listitem><para>
+                                Setting the varflag in individual recipes rather
+                                than globally can result in unpredictable behavior.
+                                </para></listitem>
+                            <listitem><para>
+                                Setting the varflag to a value greater than the
+                                value used in the <filename>BB_NUMBER_THREADS</filename>
+                                variable causes <filename>number_threads</filename>
+                                to have no effect.
+                                </para></listitem>
+                        </itemizedlist>
+                    </note>
+                    </para></listitem>
                 <listitem><para><emphasis><filename>[postfuncs]</filename>:</emphasis>
                     List of functions to call after the completion of the task.
                     </para></listitem>
@@ -2719,4 +2752,30 @@
             </itemizedlist>
         </para>
     </section>
+
+    <section id='wildcard-support-in-variables'>
+        <title>Wildcard Support in Variables</title>
+
+        <para>
+            Support for wildcard use in variables varies depending on the
+            context in which it is used.
+            For example, some variables and file names allow limited use of
+            wildcards through the "<filename>%</filename>" and
+            "<filename>*</filename>" characters.
+            Other variables or names support Python's
+            <ulink url='https://docs.python.org/3/library/glob.html'><filename>glob</filename></ulink>
+            syntax,
+            <ulink url='https://docs.python.org/3/library/fnmatch.html#module-fnmatch'><filename>fnmatch</filename></ulink>
+            syntax, or
+            <ulink url='https://docs.python.org/3/library/re.html#re'><filename>Regular Expression (re)</filename></ulink>
+            syntax.
+        </para>
+
+        <para>
+            For variables that have wildcard suport, the
+            documentation describes which form of wildcard, its
+            use, and its limitations.
+        </para>
+    </section>
+
 </chapter>
diff --git a/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-ref-variables.xml b/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-ref-variables.xml
index 0313359..a84b2bc 100644
--- a/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-ref-variables.xml
+++ b/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-ref-variables.xml
@@ -115,7 +115,8 @@
                             is either not set or set to "0".
                             </para></listitem>
                         <listitem><para>
-                            Limited support for wildcard matching against the
+                            Limited support for the "<filename>*</filename>"
+                            wildcard character for matching against the
                             beginning of host names exists.
                             For example, the following setting matches
                             <filename>git.gnu.org</filename>,
@@ -124,6 +125,20 @@
                             <literallayout class='monospaced'>
      BB_ALLOWED_NETWORKS = "*.gnu.org"
                             </literallayout>
+                            <note><title>Important</title>
+                                <para>The use of the "<filename>*</filename>"
+                                character only works at the beginning of
+                                a host name and it must be isolated from
+                                the remainder of the host name.
+                                You cannot use the wildcard character in any
+                                other location of the name or combined with
+                                the front part of the name.</para>
+
+                                <para>For example,
+                                <filename>*.foo.bar</filename> is supported,
+                                while <filename>*aa.foo.bar</filename> is not.
+                                </para>
+                            </note>
                             </para></listitem>
                         <listitem><para>
                             Mirrors not in the host list are skipped and
@@ -646,10 +661,10 @@
             <glossdef>
                 <para>
                     Contains the name of the currently executing task.
-                    The value does not include the "do_" prefix.
+                    The value includes the "do_" prefix.
                     For example, if the currently executing task is
                     <filename>do_config</filename>, the value is
-                    "config".
+                    "do_config".
                 </para>
             </glossdef>
         </glossentry>
@@ -1082,7 +1097,19 @@
 
         <glossentry id='var-BBFILES'><glossterm>BBFILES</glossterm>
             <glossdef>
-                <para>List of recipe files BitBake uses to build software.</para>
+                <para>
+                    A space-separated list of recipe files BitBake uses to
+                    build software.
+                </para>
+
+                <para>
+                    When specifying recipe files, you can pattern match using
+                    Python's
+                    <ulink url='https://docs.python.org/3/library/glob.html'><filename>glob</filename></ulink>
+                    syntax.
+                    For details on the syntax, see the documentation by
+                    following the previous link.
+                </para>
             </glossdef>
         </glossentry>
 
@@ -1166,15 +1193,19 @@
                     match any of the expressions.
                     It is as if BitBake does not see them at all.
                     Consequently, matching files are not parsed or otherwise
-                    used by BitBake.</para>
+                    used by BitBake.
+                </para>
+
                 <para>
                     The values you provide are passed to Python's regular
                     expression compiler.
+                    Consequently, the syntax follows Python's Regular
+                    Expression (re) syntax.
                     The expressions are compared against the full paths to
                     the files.
                     For complete syntax information, see Python's
                     documentation at
-                    <ulink url='http://docs.python.org/release/2.3/lib/re-syntax.html'></ulink>.
+                    <ulink url='http://docs.python.org/3/library/re.html#re'></ulink>.
                 </para>
 
                 <para>
@@ -1205,6 +1236,45 @@
             </glossdef>
         </glossentry>
 
+        <glossentry id='var-BBMULTICONFIG'><glossterm>BBMULTICONFIG</glossterm>
+            <info>
+                BBMULTICONFIG[doc] = "Enables BitBake to perform multiple configuration builds and lists each separate configuration (multiconfig)."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    Enables BitBake to perform multiple configuration builds
+                    and lists each separate configuration (multiconfig).
+                    You can use this variable to cause BitBake to build
+                    multiple targets where each target has a separate
+                    configuration.
+                    Define <filename>BBMULTICONFIG</filename> in your
+                    <filename>conf/local.conf</filename> configuration file.
+                </para>
+
+                <para>
+                    As an example, the following line specifies three
+                    multiconfigs, each having a separate configuration file:
+                    <literallayout class='monospaced'>
+     BBMULTIFONFIG = "configA configB configC"
+                    </literallayout>
+                    Each configuration file you use must reside in the
+                    build directory within a directory named
+                    <filename>conf/multiconfig</filename> (e.g.
+                    <replaceable>build_directory</replaceable><filename>/conf/multiconfig/configA.conf</filename>).
+                </para>
+
+                <para>
+                    For information on how to use
+                    <filename>BBMULTICONFIG</filename> in an environment that
+                    supports building targets with multiple configurations,
+                    see the
+                    "<link linkend='executing-a-multiple-configuration-build'>Executing a Multiple Configuration Build</link>"
+                    section.
+                </para>
+            </glossdef>
+        </glossentry>
+
         <glossentry id='var-BBPATH'><glossterm>BBPATH</glossterm>
             <glossdef>
                 <para>
@@ -1894,15 +1964,27 @@
                     you want to select, and you should set
                     <link linkend='var-PV'><filename>PV</filename></link>
                     accordingly for precedence.
-                    You can use the "<filename>%</filename>" character as a
-                    wildcard to match any number of characters, which can be
-                    useful when specifying versions that contain long revision
-                    numbers that could potentially change.
+                </para>
+
+                <para>
+                    The <filename>PREFERRED_VERSION</filename> variable
+                    supports limited wildcard use through the
+                    "<filename>%</filename>" character.
+                    You can use the character to match any number of
+                    characters, which can be useful when specifying versions
+                    that contain long revision numbers that potentially change.
                     Here are two examples:
                     <literallayout class='monospaced'>
      PREFERRED_VERSION_python = "2.7.3"
      PREFERRED_VERSION_linux-yocto = "4.12%"
                     </literallayout>
+                    <note><title>Important</title>
+                        The use of the "<filename>%</filename>" character
+                        is limited in that it only works at the end of the
+                        string.
+                        You cannot use the wildcard character in any other
+                        location of the string.
+                    </note>
                 </para>
             </glossdef>
         </glossentry>
diff --git a/poky/bitbake/doc/bitbake-user-manual/figures/bb_multiconfig_files.png b/poky/bitbake/doc/bitbake-user-manual/figures/bb_multiconfig_files.png
new file mode 100644
index 0000000..041f064
--- /dev/null
+++ b/poky/bitbake/doc/bitbake-user-manual/figures/bb_multiconfig_files.png
Binary files differ
diff --git a/poky/bitbake/lib/bb/COW.py b/poky/bitbake/lib/bb/COW.py
index bec6208..7817473 100644
--- a/poky/bitbake/lib/bb/COW.py
+++ b/poky/bitbake/lib/bb/COW.py
@@ -150,7 +150,7 @@
                 yield value
             if type == "items":
                 yield (key, value)
-        raise StopIteration()
+        return
 
     def iterkeys(cls):
         return cls.iter("keys")
diff --git a/poky/bitbake/lib/bb/__init__.py b/poky/bitbake/lib/bb/__init__.py
index d24adb8..4bc47c8 100644
--- a/poky/bitbake/lib/bb/__init__.py
+++ b/poky/bitbake/lib/bb/__init__.py
@@ -21,7 +21,7 @@
 # with this program; if not, write to the Free Software Foundation, Inc.,
 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
 
-__version__ = "1.38.0"
+__version__ = "1.40.0"
 
 import sys
 if sys.version_info < (3, 4, 0):
@@ -63,6 +63,10 @@
     def verbose(self, msg, *args, **kwargs):
         return self.log(logging.INFO - 1, msg, *args, **kwargs)
 
+    def verbnote(self, msg, *args, **kwargs):
+        return self.log(logging.INFO + 2, msg, *args, **kwargs)
+
+
 logging.raiseExceptions = False
 logging.setLoggerClass(BBLogger)
 
@@ -93,6 +97,18 @@
 def note(*args):
     mainlogger.info(''.join(args))
 
+#
+# A higher prioity note which will show on the console but isn't a warning
+#
+# Something is happening the user should be aware of but they probably did
+# something to make it happen
+#
+def verbnote(*args):
+    mainlogger.verbnote(''.join(args))
+
+#
+# Warnings - things the user likely needs to pay attention to and fix
+#
 def warn(*args):
     mainlogger.warning(''.join(args))
 
diff --git a/poky/bitbake/lib/bb/build.py b/poky/bitbake/lib/bb/build.py
index 4631abd..3e2a94e 100644
--- a/poky/bitbake/lib/bb/build.py
+++ b/poky/bitbake/lib/bb/build.py
@@ -41,8 +41,6 @@
 bblogger = logging.getLogger('BitBake')
 logger = logging.getLogger('BitBake.Build')
 
-NULL = open(os.devnull, 'r+')
-
 __mtime_cache = {}
 
 def cached_mtime_noerror(f):
@@ -533,7 +531,6 @@
                 self.triggered = True
 
     # Handle logfiles
-    si = open('/dev/null', 'r')
     try:
         bb.utils.mkdirhier(os.path.dirname(logfn))
         logfile = open(logfn, 'w')
@@ -547,7 +544,8 @@
     ose = [os.dup(sys.stderr.fileno()), sys.stderr.fileno()]
 
     # Replace those fds with our own
-    os.dup2(si.fileno(), osi[1])
+    with open('/dev/null', 'r') as si:
+        os.dup2(si.fileno(), osi[1])
     os.dup2(logfile.fileno(), oso[1])
     os.dup2(logfile.fileno(), ose[1])
 
@@ -608,7 +606,6 @@
         os.close(osi[0])
         os.close(oso[0])
         os.close(ose[0])
-        si.close()
 
         logfile.close()
         if os.path.exists(logfn) and os.path.getsize(logfn) == 0:
@@ -803,6 +800,7 @@
             if name in flags:
                 deptask = d.expand(flags[name])
                 task_deps[name][task] = deptask
+        getTask('mcdepends')
         getTask('depends')
         getTask('rdepends')
         getTask('deptask')
diff --git a/poky/bitbake/lib/bb/cache.py b/poky/bitbake/lib/bb/cache.py
index 168a77a..258d679 100644
--- a/poky/bitbake/lib/bb/cache.py
+++ b/poky/bitbake/lib/bb/cache.py
@@ -37,7 +37,7 @@
 
 logger = logging.getLogger("BitBake.Cache")
 
-__cache_version__ = "151"
+__cache_version__ = "152"
 
 def getCacheFile(path, filename, data_hash):
     return os.path.join(path, filename + "." + data_hash)
diff --git a/poky/bitbake/lib/bb/codeparser.py b/poky/bitbake/lib/bb/codeparser.py
index 530f44e..ddd1b97 100644
--- a/poky/bitbake/lib/bb/codeparser.py
+++ b/poky/bitbake/lib/bb/codeparser.py
@@ -140,7 +140,7 @@
     # so that an existing cache gets invalidated. Additionally you'll need
     # to increment __cache_version__ in cache.py in order to ensure that old
     # recipe caches don't trigger "Taskhash mismatch" errors.
-    CACHE_VERSION = 9
+    CACHE_VERSION = 10
 
     def __init__(self):
         MultiProcessCache.__init__(self)
@@ -214,7 +214,7 @@
         self.buffer = []
 
 class PythonParser():
-    getvars = (".getVar", ".appendVar", ".prependVar")
+    getvars = (".getVar", ".appendVar", ".prependVar", "oe.utils.conditional")
     getvarflags = (".getVarFlag", ".appendVarFlag", ".prependVarFlag")
     containsfuncs = ("bb.utils.contains", "base_contains")
     containsanyfuncs = ("bb.utils.contains_any",  "bb.utils.filter")
diff --git a/poky/bitbake/lib/bb/cooker.py b/poky/bitbake/lib/bb/cooker.py
index 1fda40d..16681ba 100644
--- a/poky/bitbake/lib/bb/cooker.py
+++ b/poky/bitbake/lib/bb/cooker.py
@@ -620,6 +620,27 @@
             runlist.append([mc, k, ktask, fn])
             bb.event.fire(bb.event.TreeDataPreparationProgress(current, len(fulltargetlist)), self.data)
 
+        mcdeps = taskdata[mc].get_mcdepends()
+        # No need to do check providers if there are no mcdeps or not an mc build
+        if mcdeps and mc:
+            # Make sure we can provide the multiconfig dependency
+            seen = set()
+            new = True
+            while new:
+                new = False
+                for mc in self.multiconfigs:
+                    for k in mcdeps:
+                        if k in seen:
+                            continue
+                        l = k.split(':')
+                        depmc = l[2]
+                        if depmc not in self.multiconfigs:
+                            bb.fatal("Multiconfig dependency %s depends on nonexistent mc configuration %s" % (k,depmc))
+                        else:
+                            logger.debug(1, "Adding providers for multiconfig dependency %s" % l[3])
+                            taskdata[depmc].add_provider(localdata[depmc], self.recipecaches[depmc], l[3])
+                            seen.add(k)
+                            new = True
         for mc in self.multiconfigs:
             taskdata[mc].add_unresolved(localdata[mc], self.recipecaches[mc])
 
@@ -706,8 +727,8 @@
             if not dotname in depend_tree["tdepends"]:
                 depend_tree["tdepends"][dotname] = []
             for dep in rq.rqdata.runtaskentries[tid].depends:
-                (depmc, depfn, deptaskname, deptaskfn) = bb.runqueue.split_tid_mcfn(dep)
-                deppn = self.recipecaches[mc].pkg_fn[deptaskfn]
+                (depmc, depfn, _, deptaskfn) = bb.runqueue.split_tid_mcfn(dep)
+                deppn = self.recipecaches[depmc].pkg_fn[deptaskfn]
                 depend_tree["tdepends"][dotname].append("%s.%s" % (deppn, bb.runqueue.taskname_from_tid(dep)))
             if taskfn not in seen_fns:
                 seen_fns.append(taskfn)
@@ -1566,7 +1587,7 @@
                     pkgs_to_build.append(t)
 
         if 'universe' in pkgs_to_build:
-            parselog.warning("The \"universe\" target is only intended for testing and may produce errors.")
+            parselog.verbnote("The \"universe\" target is only intended for testing and may produce errors.")
             parselog.debug(1, "collating packages for \"universe\"")
             pkgs_to_build.remove('universe')
             for mc in self.multiconfigs:
@@ -1633,7 +1654,10 @@
 class CookerCollectFiles(object):
     def __init__(self, priorities):
         self.bbappends = []
-        self.bbfile_config_priorities = priorities
+        # Priorities is a list of tupples, with the second element as the pattern.
+        # We need to sort the list with the longest pattern first, and so on to
+        # the shortest.  This allows nested layers to be properly evaluated.
+        self.bbfile_config_priorities = sorted(priorities, key=lambda tup: tup[1], reverse=True)
 
     def calc_bbfile_priority( self, filename, matched = None ):
         for _, _, regex, pri in self.bbfile_config_priorities:
diff --git a/poky/bitbake/lib/bb/daemonize.py b/poky/bitbake/lib/bb/daemonize.py
index 8300d1d..c937675 100644
--- a/poky/bitbake/lib/bb/daemonize.py
+++ b/poky/bitbake/lib/bb/daemonize.py
@@ -16,6 +16,10 @@
     background as a daemon, returning control to the caller.
     """
 
+    # Ensure stdout/stderror are flushed before forking to avoid duplicate output
+    sys.stdout.flush()
+    sys.stderr.flush()
+
     try:
         # Fork a child process so the parent can exit.  This returns control to
         # the command-line or shell.  It also guarantees that the child will not
@@ -49,8 +53,8 @@
             # exit() or _exit()?
             # _exit is like exit(), but it doesn't call any functions registered
             # with atexit (and on_exit) or any registered signal handlers.  It also
-            # closes any open file descriptors.  Using exit() may cause all stdio
-            # streams to be flushed twice and any temporary files may be unexpectedly
+            # closes any open file descriptors, but doesn't flush any buffered output.
+            # Using exit() may cause all any temporary files to be unexpectedly
             # removed.  It's therefore recommended that child branches of a fork()
             # and the parent branch(es) of a daemon use _exit().
             os._exit(0)
@@ -61,17 +65,19 @@
     # The second child.
 
     # Replace standard fds with our own
-    si = open('/dev/null', 'r')
-    os.dup2(si.fileno(), sys.stdin.fileno())
+    with open('/dev/null', 'r') as si:
+        os.dup2(si.fileno(), sys.stdin.fileno())
 
     try:
         so = open(logfile, 'a+')
-        se = so
         os.dup2(so.fileno(), sys.stdout.fileno())
-        os.dup2(se.fileno(), sys.stderr.fileno())
+        os.dup2(so.fileno(), sys.stderr.fileno())
     except io.UnsupportedOperation:
         sys.stdout = open(logfile, 'a+')
-        sys.stderr = sys.stdout
+
+    # Have stdout and stderr be the same so log output matches chronologically
+    # and there aren't two seperate buffers
+    sys.stderr = sys.stdout
 
     try:
         function()
@@ -79,4 +85,9 @@
         traceback.print_exc()
     finally:
         bb.event.print_ui_queue()
+        # os._exit() doesn't flush open files like os.exit() does. Manually flush
+        # stdout and stderr so that any logging output will be seen, particularly
+        # exception tracebacks.
+        sys.stdout.flush()
+        sys.stderr.flush()
         os._exit(0)
diff --git a/poky/bitbake/lib/bb/data.py b/poky/bitbake/lib/bb/data.py
index 80a7879..d66d98c 100644
--- a/poky/bitbake/lib/bb/data.py
+++ b/poky/bitbake/lib/bb/data.py
@@ -38,6 +38,7 @@
 # Based on functions from the base bb module, Copyright 2003 Holger Schurig
 
 import sys, os, re
+import hashlib
 if sys.argv[0][-5:] == "pydoc":
     path = os.path.dirname(os.path.dirname(sys.argv[1]))
 else:
@@ -283,14 +284,12 @@
     try:
         if key[-1] == ']':
             vf = key[:-1].split('[')
-            value = d.getVarFlag(vf[0], vf[1], False)
-            parser = d.expandWithRefs(value, key)
+            value, parser = d.getVarFlag(vf[0], vf[1], False, retparser=True)
             deps |= parser.references
             deps = deps | (keys & parser.execs)
             return deps, value
         varflags = d.getVarFlags(key, ["vardeps", "vardepvalue", "vardepsexclude", "exports", "postfuncs", "prefuncs", "lineno", "filename"]) or {}
         vardeps = varflags.get("vardeps")
-        value = d.getVarFlag(key, "_content", False)
 
         def handle_contains(value, contains, d):
             newvalue = ""
@@ -309,10 +308,19 @@
                 return newvalue
             return value + newvalue
 
+        def handle_remove(value, deps, removes, d):
+            for r in sorted(removes):
+                r2 = d.expandWithRefs(r, None)
+                value += "\n_remove of %s" % r
+                deps |= r2.references
+                deps = deps | (keys & r2.execs)
+            return value
+
         if "vardepvalue" in varflags:
-           value = varflags.get("vardepvalue")
+            value = varflags.get("vardepvalue")
         elif varflags.get("func"):
             if varflags.get("python"):
+                value = d.getVarFlag(key, "_content", False)
                 parser = bb.codeparser.PythonParser(key, logger)
                 if value and "\t" in value:
                     logger.warning("Variable %s contains tabs, please remove these (%s)" % (key, d.getVar("FILE")))
@@ -321,13 +329,15 @@
                 deps = deps | (keys & parser.execs)
                 value = handle_contains(value, parser.contains, d)
             else:
-                parsedvar = d.expandWithRefs(value, key)
+                value, parsedvar = d.getVarFlag(key, "_content", False, retparser=True)
                 parser = bb.codeparser.ShellParser(key, logger)
                 parser.parse_shell(parsedvar.value)
                 deps = deps | shelldeps
                 deps = deps | parsedvar.references
                 deps = deps | (keys & parser.execs) | (keys & parsedvar.execs)
                 value = handle_contains(value, parsedvar.contains, d)
+                if hasattr(parsedvar, "removes"):
+                    value = handle_remove(value, deps, parsedvar.removes, d)
             if vardeps is None:
                 parser.log.flush()
             if "prefuncs" in varflags:
@@ -337,10 +347,12 @@
             if "exports" in varflags:
                 deps = deps | set(varflags["exports"].split())
         else:
-            parser = d.expandWithRefs(value, key)
+            value, parser = d.getVarFlag(key, "_content", False, retparser=True)
             deps |= parser.references
             deps = deps | (keys & parser.execs)
             value = handle_contains(value, parser.contains, d)
+            if hasattr(parser, "removes"):
+                value = handle_remove(value, deps, parser.removes, d)
 
         if "vardepvalueexclude" in varflags:
             exclude = varflags.get("vardepvalueexclude")
@@ -394,6 +406,43 @@
         #print "For %s: %s" % (task, str(deps[task]))
     return tasklist, deps, values
 
+def generate_dependency_hash(tasklist, gendeps, lookupcache, whitelist, fn):
+    taskdeps = {}
+    basehash = {}
+
+    for task in tasklist:
+        data = lookupcache[task]
+
+        if data is None:
+            bb.error("Task %s from %s seems to be empty?!" % (task, fn))
+            data = ''
+
+        gendeps[task] -= whitelist
+        newdeps = gendeps[task]
+        seen = set()
+        while newdeps:
+            nextdeps = newdeps
+            seen |= nextdeps
+            newdeps = set()
+            for dep in nextdeps:
+                if dep in whitelist:
+                    continue
+                gendeps[dep] -= whitelist
+                newdeps |= gendeps[dep]
+            newdeps -= seen
+
+        alldeps = sorted(seen)
+        for dep in alldeps:
+            data = data + dep
+            var = lookupcache[dep]
+            if var is not None:
+                data = data + str(var)
+        k = fn + "." + task
+        basehash[k] = hashlib.md5(data.encode("utf-8")).hexdigest()
+        taskdeps[task] = alldeps
+
+    return taskdeps, basehash
+
 def inherits_class(klass, d):
     val = d.getVar('__inherit_cache', False) or []
     needle = os.path.join('classes', '%s.bbclass' % klass)
diff --git a/poky/bitbake/lib/bb/data_smart.py b/poky/bitbake/lib/bb/data_smart.py
index 7b09af5..6b94fc4 100644
--- a/poky/bitbake/lib/bb/data_smart.py
+++ b/poky/bitbake/lib/bb/data_smart.py
@@ -42,6 +42,7 @@
 __setvar_regexp__ = re.compile('(?P<base>.*?)(?P<keyword>_append|_prepend|_remove)(_(?P<add>[^A-Z]*))?$')
 __expand_var_regexp__ = re.compile(r"\${[^{}@\n\t :]+}")
 __expand_python_regexp__ = re.compile(r"\${@.+?}")
+__whitespace_split__ = re.compile('(\s)')
 
 def infer_caller_details(loginfo, parent = False, varval = True):
     """Save the caller the trouble of specifying everything."""
@@ -104,11 +105,7 @@
             if self.varname and key:
                 if self.varname == key:
                     raise Exception("variable %s references itself!" % self.varname)
-            if key in self.d.expand_cache:
-                varparse = self.d.expand_cache[key]
-                var = varparse.value
-            else:
-                var = self.d.getVarFlag(key, "_content")
+            var = self.d.getVarFlag(key, "_content")
             self.references.add(key)
             if var is not None:
                 return var
@@ -267,6 +264,16 @@
             return
         self.variables[var].append(loginfo.copy())
 
+    def rename_variable_hist(self, oldvar, newvar):
+        if not self.dataroot._tracking:
+            return
+        if oldvar not in self.variables:
+            return
+        if newvar not in self.variables:
+            self.variables[newvar] = []
+        for i in self.variables[oldvar]:
+            self.variables[newvar].append(i.copy())
+
     def variable(self, var):
         remote_connector = self.dataroot.getVar('_remote_data', False)
         if remote_connector:
@@ -401,9 +408,6 @@
         if not isinstance(s, str): # sanity check
             return VariableParse(varname, self, s)
 
-        if varname and varname in self.expand_cache:
-            return self.expand_cache[varname]
-
         varparse = VariableParse(varname, self)
 
         while s.find('${') != -1:
@@ -427,9 +431,6 @@
 
         varparse.value = s
 
-        if varname:
-            self.expand_cache[varname] = varparse
-
         return varparse
 
     def expand(self, s, varname = None):
@@ -498,6 +499,7 @@
 
     def setVar(self, var, value, **loginfo):
         #print("var=" + str(var) + "  val=" + str(value))
+        self.expand_cache = {}
         parsing=False
         if 'parsing' in loginfo:
             parsing=True
@@ -510,7 +512,7 @@
 
         if 'op' not in loginfo:
             loginfo['op'] = "set"
-        self.expand_cache = {}
+
         match  = __setvar_regexp__.match(var)
         if match and match.group("keyword") in __setvar_keyword__:
             base = match.group('base')
@@ -619,6 +621,7 @@
 
         val = self.getVar(key, 0, parsing=True)
         if val is not None:
+            self.varhistory.rename_variable_hist(key, newkey)
             loginfo['variable'] = newkey
             loginfo['op'] = 'rename from %s' % key
             loginfo['detail'] = val
@@ -660,6 +663,7 @@
         self.setVar(var + "_prepend", value, ignore=True, parsing=True)
 
     def delVar(self, var, **loginfo):
+        self.expand_cache = {}
         if '_remote_data' in self.dict:
             connector = self.dict["_remote_data"]["_content"]
             res = connector.delVar(var)
@@ -669,7 +673,6 @@
         loginfo['detail'] = ""
         loginfo['op'] = 'del'
         self.varhistory.record(**loginfo)
-        self.expand_cache = {}
         self.dict[var] = {}
         if var in self.overridedata:
             del self.overridedata[var]
@@ -692,13 +695,13 @@
                          override = None
 
     def setVarFlag(self, var, flag, value, **loginfo):
+        self.expand_cache = {}
         if '_remote_data' in self.dict:
             connector = self.dict["_remote_data"]["_content"]
             res = connector.setVarFlag(var, flag, value)
             if not res:
                 return
 
-        self.expand_cache = {}
         if 'op' not in loginfo:
             loginfo['op'] = "set"
         loginfo['flag'] = flag
@@ -719,9 +722,21 @@
                 self.dict["__exportlist"]["_content"] = set()
             self.dict["__exportlist"]["_content"].add(var)
 
-    def getVarFlag(self, var, flag, expand=True, noweakdefault=False, parsing=False):
+    def getVarFlag(self, var, flag, expand=True, noweakdefault=False, parsing=False, retparser=False):
+        if flag == "_content":
+            cachename = var
+        else:
+            if not flag:
+                bb.warn("Calling getVarFlag with flag unset is invalid")
+                return None
+            cachename = var + "[" + flag + "]"
+
+        if expand and cachename in self.expand_cache:
+            return self.expand_cache[cachename].value
+
         local_var, overridedata = self._findVar(var)
         value = None
+        removes = set()
         if flag == "_content" and overridedata is not None and not parsing:
             match = False
             active = {}
@@ -748,7 +763,11 @@
                             match = active[a]
                             del active[a]
             if match:
-                value = self.getVar(match, False)
+                value, subparser = self.getVarFlag(match, "_content", False, retparser=True)
+                if hasattr(subparser, "removes"):
+                    # We have to carry the removes from the overridden variable to apply at the
+                    # end of processing
+                    removes = subparser.removes
 
         if local_var is not None and value is None:
             if flag in local_var:
@@ -784,17 +803,13 @@
                 if match:
                     value = r + value
 
-        if expand and value:
-            # Only getvar (flag == _content) hits the expand cache
-            cachename = None
-            if flag == "_content":
-                cachename = var
-            else:
-                cachename = var + "[" + flag + "]"
-            value = self.expand(value, cachename)
+        parser = None
+        if expand or retparser:
+            parser = self.expandWithRefs(value, cachename)
+        if expand:
+            value = parser.value
 
-        if value and flag == "_content" and local_var is not None and "_remove" in local_var:
-            removes = []
+        if value and flag == "_content" and local_var is not None and "_remove" in local_var and not parsing:
             self.need_overrides()
             for (r, o) in local_var["_remove"]:
                 match = True
@@ -803,26 +818,45 @@
                         if not o2 in self.overrides:
                             match = False                            
                 if match:
-                    removes.extend(self.expand(r).split())
+                    removes.add(r)
 
-            if removes:
-                filtered = filter(lambda v: v not in removes,
-                                  value.split())
-                value = " ".join(filtered)
-                if expand and var in self.expand_cache:
-                    # We need to ensure the expand cache has the correct value
-                    # flag == "_content" here
-                    self.expand_cache[var].value = value
+        if value and flag == "_content" and not parsing:
+            if removes and parser:
+                expanded_removes = {}
+                for r in removes:
+                    expanded_removes[r] = self.expand(r).split()
+
+                parser.removes = set()
+                val = ""
+                for v in __whitespace_split__.split(parser.value):
+                    skip = False
+                    for r in removes:
+                        if v in expanded_removes[r]:
+                            parser.removes.add(r)
+                            skip = True
+                    if skip:
+                        continue
+                    val = val + v
+                parser.value = val
+                if expand:
+                    value = parser.value
+
+        if parser:
+            self.expand_cache[cachename] = parser
+
+        if retparser:
+            return value, parser
+
         return value
 
     def delVarFlag(self, var, flag, **loginfo):
+        self.expand_cache = {}
         if '_remote_data' in self.dict:
             connector = self.dict["_remote_data"]["_content"]
             res = connector.delVarFlag(var, flag)
             if not res:
                 return
 
-        self.expand_cache = {}
         local_var, _ = self._findVar(var)
         if not local_var:
             return
diff --git a/poky/bitbake/lib/bb/event.py b/poky/bitbake/lib/bb/event.py
index 5d00496..5b1b094 100644
--- a/poky/bitbake/lib/bb/event.py
+++ b/poky/bitbake/lib/bb/event.py
@@ -141,6 +141,9 @@
     logger = logging.getLogger("BitBake")
     if not _uiready:
         from bb.msg import BBLogFormatter
+        # Flush any existing buffered content
+        sys.stdout.flush()
+        sys.stderr.flush()
         stdout = logging.StreamHandler(sys.stdout)
         stderr = logging.StreamHandler(sys.stderr)
         formatter = BBLogFormatter("%(levelname)s: %(message)s")
@@ -395,7 +398,7 @@
         Event.__init__(self)
 
 class RecipePreFinalise(RecipeEvent):
-    """ Recipe Parsing Complete but not yet finialised"""
+    """ Recipe Parsing Complete but not yet finalised"""
 
 class RecipeTaskPreProcess(RecipeEvent):
     """
diff --git a/poky/bitbake/lib/bb/fetch2/__init__.py b/poky/bitbake/lib/bb/fetch2/__init__.py
index 72d6092..3b8389e 100644
--- a/poky/bitbake/lib/bb/fetch2/__init__.py
+++ b/poky/bitbake/lib/bb/fetch2/__init__.py
@@ -256,7 +256,7 @@
 
         # Identify if the URI is relative or not
         if urlp.scheme in self._relative_schemes and \
-           re.compile("^\w+:(?!//)").match(uri):
+           re.compile(r"^\w+:(?!//)").match(uri):
             self.relative = True
 
         if not self.relative:
@@ -383,7 +383,7 @@
         path = location
     else:
         host = location
-        path = ""
+        path = "/"
     if user:
         m = re.compile('(?P<user>[^:]+)(:?(?P<pswd>.*))').match(user)
         if m:
@@ -452,8 +452,8 @@
             # Handle URL parameters
             if i:
                 # Any specified URL parameters must match
-                for k in uri_replace_decoded[loc]:
-                    if uri_decoded[loc][k] != uri_replace_decoded[loc][k]:
+                for k in uri_find_decoded[loc]:
+                    if uri_decoded[loc][k] != uri_find_decoded[loc][k]:
                         return None
             # Overwrite any specified replacement parameters
             for k in uri_replace_decoded[loc]:
@@ -827,6 +827,7 @@
                   'NO_PROXY', 'no_proxy',
                   'ALL_PROXY', 'all_proxy',
                   'GIT_PROXY_COMMAND',
+                  'GIT_SSH',
                   'GIT_SSL_CAINFO',
                   'GIT_SMART_HTTP',
                   'SSH_AUTH_SOCK', 'SSH_AGENT_PID',
@@ -837,14 +838,16 @@
     if not cleanup:
         cleanup = []
 
-    # If PATH contains WORKDIR which contains PV which contains SRCPV we
+    # If PATH contains WORKDIR which contains PV-PR which contains SRCPV we
     # can end up in circular recursion here so give the option of breaking it
     # in a data store copy.
     try:
         d.getVar("PV")
+        d.getVar("PR")
     except bb.data_smart.ExpansionError:
         d = bb.data.createCopy(d)
         d.setVar("PV", "fetcheravoidrecurse")
+        d.setVar("PR", "fetcheravoidrecurse")
 
     origenv = d.getVar("BB_ORIGENV", False)
     for var in exportvars:
@@ -1016,16 +1019,7 @@
                     origud.method.build_mirror_data(origud, ld)
             return origud.localpath
         # Otherwise the result is a local file:// and we symlink to it
-        if not os.path.exists(origud.localpath):
-            if os.path.islink(origud.localpath):
-                # Broken symbolic link
-                os.unlink(origud.localpath)
-
-            # As per above, in case two tasks end up here simultaneously.
-            try:
-                os.symlink(ud.localpath, origud.localpath)
-            except FileExistsError:
-                pass
+        ensure_symlink(ud.localpath, origud.localpath)
         update_stamp(origud, ld)
         return ud.localpath
 
@@ -1059,6 +1053,22 @@
             bb.utils.unlockfile(lf)
 
 
+def ensure_symlink(target, link_name):
+    if not os.path.exists(link_name):
+        if os.path.islink(link_name):
+            # Broken symbolic link
+            os.unlink(link_name)
+
+        # In case this is executing without any file locks held (as is
+        # the case for file:// URLs), two tasks may end up here at the
+        # same time, in which case we do not want the second task to
+        # fail when the link has already been created by the first task.
+        try:
+            os.symlink(target, link_name)
+        except FileExistsError:
+            pass
+
+
 def try_mirrors(fetch, d, origud, mirrors, check = False):
     """
     Try to use a mirrored version of the sources.
@@ -1088,7 +1098,9 @@
         return True
 
     pkgname = d.expand(d.getVar('PN', False))
-    trusted_hosts = d.getVarFlag('BB_ALLOWED_NETWORKS', pkgname, False)
+    trusted_hosts = None
+    if pkgname:
+        trusted_hosts = d.getVarFlag('BB_ALLOWED_NETWORKS', pkgname, False)
 
     if not trusted_hosts:
         trusted_hosts = d.getVar('BB_ALLOWED_NETWORKS')
diff --git a/poky/bitbake/lib/bb/fetch2/bzr.py b/poky/bitbake/lib/bb/fetch2/bzr.py
index 16123f8..658502f 100644
--- a/poky/bitbake/lib/bb/fetch2/bzr.py
+++ b/poky/bitbake/lib/bb/fetch2/bzr.py
@@ -41,8 +41,9 @@
         init bzr specific variable within url data
         """
         # Create paths to bzr checkouts
+        bzrdir = d.getVar("BZRDIR") or (d.getVar("DL_DIR") + "/bzr")
         relpath = self._strip_leading_slashes(ud.path)
-        ud.pkgdir = os.path.join(d.expand('${BZRDIR}'), ud.host, relpath)
+        ud.pkgdir = os.path.join(bzrdir, ud.host, relpath)
 
         ud.setup_revisions(d)
 
@@ -57,7 +58,7 @@
         command is "fetch", "update", "revno"
         """
 
-        basecmd = d.expand('${FETCHCMD_bzr}')
+        basecmd = d.getVar("FETCHCMD_bzr") or "/usr/bin/env bzr"
 
         proto =  ud.parm.get('protocol', 'http')
 
diff --git a/poky/bitbake/lib/bb/fetch2/cvs.py b/poky/bitbake/lib/bb/fetch2/cvs.py
index 490c954..0e0a319 100644
--- a/poky/bitbake/lib/bb/fetch2/cvs.py
+++ b/poky/bitbake/lib/bb/fetch2/cvs.py
@@ -110,7 +110,7 @@
         if ud.tag:
             options.append("-r %s" % ud.tag)
 
-        cvsbasecmd = d.getVar("FETCHCMD_cvs")
+        cvsbasecmd = d.getVar("FETCHCMD_cvs") or "/usr/bin/env cvs"
         cvscmd = cvsbasecmd + " '-d" + cvsroot + "' co " + " ".join(options) + " " + ud.module
         cvsupdatecmd = cvsbasecmd + " '-d" + cvsroot + "' update -d -P " + " ".join(options)
 
@@ -121,7 +121,8 @@
         # create module directory
         logger.debug(2, "Fetch: checking for module directory")
         pkg = d.getVar('PN')
-        pkgdir = os.path.join(d.getVar('CVSDIR'), pkg)
+        cvsdir = d.getVar("CVSDIR") or (d.getVar("DL_DIR") + "/cvs")
+        pkgdir = os.path.join(cvsdir, pkg)
         moddir = os.path.join(pkgdir, localdir)
         workdir = None
         if os.access(os.path.join(moddir, 'CVS'), os.R_OK):
diff --git a/poky/bitbake/lib/bb/fetch2/git.py b/poky/bitbake/lib/bb/fetch2/git.py
index 7b618c6..59a2ee8 100644
--- a/poky/bitbake/lib/bb/fetch2/git.py
+++ b/poky/bitbake/lib/bb/fetch2/git.py
@@ -261,7 +261,7 @@
                 gitsrcname = gitsrcname + '_' + ud.revisions[name]
 
         dl_dir = d.getVar("DL_DIR")
-        gitdir = d.getVar("GITDIR") or (dl_dir + "/git2/")
+        gitdir = d.getVar("GITDIR") or (dl_dir + "/git2")
         ud.clonedir = os.path.join(gitdir, gitsrcname)
         ud.localfile = ud.clonedir
 
@@ -299,17 +299,22 @@
         return ud.clonedir
 
     def need_update(self, ud, d):
+        return self.clonedir_need_update(ud, d) or self.shallow_tarball_need_update(ud) or self.tarball_need_update(ud)
+
+    def clonedir_need_update(self, ud, d):
         if not os.path.exists(ud.clonedir):
             return True
         for name in ud.names:
             if not self._contains_ref(ud, d, name, ud.clonedir):
                 return True
-        if ud.shallow and ud.write_shallow_tarballs and not os.path.exists(ud.fullshallow):
-            return True
-        if ud.write_tarballs and not os.path.exists(ud.fullmirror):
-            return True
         return False
 
+    def shallow_tarball_need_update(self, ud):
+        return ud.shallow and ud.write_shallow_tarballs and not os.path.exists(ud.fullshallow)
+
+    def tarball_need_update(self, ud):
+        return ud.write_tarballs and not os.path.exists(ud.fullmirror)
+
     def try_premirror(self, ud, d):
         # If we don't do this, updating an existing checkout with only premirrors
         # is not possible
@@ -322,16 +327,13 @@
     def download(self, ud, d):
         """Fetch url"""
 
-        no_clone = not os.path.exists(ud.clonedir)
-        need_update = no_clone or self.need_update(ud, d)
-
         # A current clone is preferred to either tarball, a shallow tarball is
         # preferred to an out of date clone, and a missing clone will use
         # either tarball.
-        if ud.shallow and os.path.exists(ud.fullshallow) and need_update:
+        if ud.shallow and os.path.exists(ud.fullshallow) and self.need_update(ud, d):
             ud.localpath = ud.fullshallow
             return
-        elif os.path.exists(ud.fullmirror) and no_clone:
+        elif os.path.exists(ud.fullmirror) and not os.path.exists(ud.clonedir):
             bb.utils.mkdirhier(ud.clonedir)
             runfetchcmd("tar -xzf %s" % ud.fullmirror, d, workdir=ud.clonedir)
 
@@ -353,6 +355,8 @@
         for name in ud.names:
             if not self._contains_ref(ud, d, name, ud.clonedir):
                 needupdate = True
+                break
+
         if needupdate:
             output = runfetchcmd("%s remote" % ud.basecmd, d, quiet=True, workdir=ud.clonedir)
             if "origin" in output:
@@ -372,6 +376,7 @@
             except OSError as exc:
                 if exc.errno != errno.ENOENT:
                     raise
+
         for name in ud.names:
             if not self._contains_ref(ud, d, name, ud.clonedir):
                 raise bb.fetch2.FetchError("Unable to find revision %s in branch %s even from upstream" % (ud.revisions[name], ud.branches[name]))
@@ -471,11 +476,30 @@
         if os.path.exists(destdir):
             bb.utils.prunedir(destdir)
 
-        if ud.shallow and (not os.path.exists(ud.clonedir) or self.need_update(ud, d)):
-            bb.utils.mkdirhier(destdir)
-            runfetchcmd("tar -xzf %s" % ud.fullshallow, d, workdir=destdir)
-        else:
-            runfetchcmd("%s clone %s %s/ %s" % (ud.basecmd, ud.cloneflags, ud.clonedir, destdir), d)
+        source_found = False
+        source_error = []
+
+        if not source_found:
+            clonedir_is_up_to_date = not self.clonedir_need_update(ud, d)
+            if clonedir_is_up_to_date:
+                runfetchcmd("%s clone %s %s/ %s" % (ud.basecmd, ud.cloneflags, ud.clonedir, destdir), d)
+                source_found = True
+            else:
+                source_error.append("clone directory not available or not up to date: " + ud.clonedir)
+
+        if not source_found:
+            if ud.shallow:
+                if os.path.exists(ud.fullshallow):
+                    bb.utils.mkdirhier(destdir)
+                    runfetchcmd("tar -xzf %s" % ud.fullshallow, d, workdir=destdir)
+                    source_found = True
+                else:
+                    source_error.append("shallow clone not available: " + ud.fullshallow)
+            else:
+                source_error.append("shallow clone not enabled")
+
+        if not source_found:
+            raise bb.fetch2.UnpackError("No up to date source found: " + "; ".join(source_error), ud.url)
 
         repourl = self._get_repo_url(ud)
         runfetchcmd("%s remote set-url origin %s" % (ud.basecmd, repourl), d, workdir=destdir)
diff --git a/poky/bitbake/lib/bb/fetch2/gitsm.py b/poky/bitbake/lib/bb/fetch2/gitsm.py
index 0aff100..35729db 100644
--- a/poky/bitbake/lib/bb/fetch2/gitsm.py
+++ b/poky/bitbake/lib/bb/fetch2/gitsm.py
@@ -31,9 +31,12 @@
 
 import os
 import bb
+import copy
 from   bb.fetch2.git import Git
 from   bb.fetch2 import runfetchcmd
 from   bb.fetch2 import logger
+from   bb.fetch2 import Fetch
+from   bb.fetch2 import BBFetchException
 
 class GitSM(Git):
     def supports(self, ud, d):
@@ -42,94 +45,206 @@
         """
         return ud.type in ['gitsm']
 
-    def uses_submodules(self, ud, d, wd):
-        for name in ud.names:
-            try:
-                runfetchcmd("%s show %s:.gitmodules" % (ud.basecmd, ud.revisions[name]), d, quiet=True, workdir=wd)
-                return True
-            except bb.fetch.FetchError:
-                pass
-        return False
-
-    def _set_relative_paths(self, repopath):
-        """
-        Fix submodule paths to be relative instead of absolute,
-        so that when we move the repo it doesn't break
-        (In Git 1.7.10+ this is done automatically)
-        """
-        submodules = []
-        with open(os.path.join(repopath, '.gitmodules'), 'r') as f:
-            for line in f.readlines():
-                if line.startswith('[submodule'):
-                    submodules.append(line.split('"')[1])
-
-        for module in submodules:
-            repo_conf = os.path.join(repopath, module, '.git')
-            if os.path.exists(repo_conf):
-                with open(repo_conf, 'r') as f:
-                    lines = f.readlines()
-                newpath = ''
-                for i, line in enumerate(lines):
-                    if line.startswith('gitdir:'):
-                        oldpath = line.split(': ')[-1].rstrip()
-                        if oldpath.startswith('/'):
-                            newpath = '../' * (module.count('/') + 1) + '.git/modules/' + module
-                            lines[i] = 'gitdir: %s\n' % newpath
-                            break
-                if newpath:
-                    with open(repo_conf, 'w') as f:
-                        for line in lines:
-                            f.write(line)
-
-            repo_conf2 = os.path.join(repopath, '.git', 'modules', module, 'config')
-            if os.path.exists(repo_conf2):
-                with open(repo_conf2, 'r') as f:
-                    lines = f.readlines()
-                newpath = ''
-                for i, line in enumerate(lines):
-                    if line.lstrip().startswith('worktree = '):
-                        oldpath = line.split(' = ')[-1].rstrip()
-                        if oldpath.startswith('/'):
-                            newpath = '../' * (module.count('/') + 3) + module
-                            lines[i] = '\tworktree = %s\n' % newpath
-                            break
-                if newpath:
-                    with open(repo_conf2, 'w') as f:
-                        for line in lines:
-                            f.write(line)
+    @staticmethod
+    def parse_gitmodules(gitmodules):
+        modules = {}
+        module = ""
+        for line in gitmodules.splitlines():
+            if line.startswith('[submodule'):
+                module = line.split('"')[1]
+                modules[module] = {}
+            elif module and line.strip().startswith('path'):
+                path = line.split('=')[1].strip()
+                modules[module]['path'] = path
+            elif module and line.strip().startswith('url'):
+                url = line.split('=')[1].strip()
+                modules[module]['url'] = url
+        return modules
 
     def update_submodules(self, ud, d):
-        # We have to convert bare -> full repo, do the submodule bit, then convert back
-        tmpclonedir = ud.clonedir + ".tmp"
-        gitdir = tmpclonedir + os.sep + ".git"
-        bb.utils.remove(tmpclonedir, True)
-        os.mkdir(tmpclonedir)
-        os.rename(ud.clonedir, gitdir)
-        runfetchcmd("sed " + gitdir + "/config -i -e 's/bare.*=.*true/bare = false/'", d)
-        runfetchcmd(ud.basecmd + " reset --hard", d, workdir=tmpclonedir)
-        runfetchcmd(ud.basecmd + " checkout -f " + ud.revisions[ud.names[0]], d, workdir=tmpclonedir)
-        runfetchcmd(ud.basecmd + " submodule update --init --recursive", d, workdir=tmpclonedir)
-        self._set_relative_paths(tmpclonedir)
-        runfetchcmd("sed " + gitdir + "/config -i -e 's/bare.*=.*false/bare = true/'", d, workdir=tmpclonedir)
-        os.rename(gitdir, ud.clonedir,)
-        bb.utils.remove(tmpclonedir, True)
+        submodules = []
+        paths = {}
+        uris = {}
+        local_paths = {}
+
+        for name in ud.names:
+            try:
+                gitmodules = runfetchcmd("%s show %s:.gitmodules" % (ud.basecmd, ud.revisions[name]), d, quiet=True, workdir=ud.clonedir)
+            except:
+                # No submodules to update
+                continue
+
+            for m, md in self.parse_gitmodules(gitmodules).items():
+                submodules.append(m)
+                paths[m] = md['path']
+                uris[m] = md['url']
+                if uris[m].startswith('..'):
+                    newud = copy.copy(ud)
+                    newud.path = os.path.realpath(os.path.join(newud.path, md['url']))
+                    uris[m] = Git._get_repo_url(self, newud)
+
+        for module in submodules:
+            module_hash = runfetchcmd("%s ls-tree -z -d %s %s" % (ud.basecmd, ud.revisions[name], paths[module]), d, quiet=True, workdir=ud.clonedir)
+            module_hash = module_hash.split()[2]
+
+            # Build new SRC_URI
+            proto = uris[module].split(':', 1)[0]
+            url = uris[module].replace('%s:' % proto, 'gitsm:', 1)
+            url += ';protocol=%s' % proto
+            url += ";name=%s" % module
+            url += ";bareclone=1;nocheckout=1;nobranch=1"
+
+            ld = d.createCopy()
+            # Not necessary to set SRC_URI, since we're passing the URI to
+            # Fetch.
+            #ld.setVar('SRC_URI', url)
+            ld.setVar('SRCREV_%s' % module, module_hash)
+
+            # Workaround for issues with SRCPV/SRCREV_FORMAT errors
+            # error refer to 'multiple' repositories.  Only the repository
+            # in the original SRC_URI actually matters...
+            ld.setVar('SRCPV', d.getVar('SRCPV'))
+            ld.setVar('SRCREV_FORMAT', module)
+
+            newfetch = Fetch([url], ld, cache=False)
+            newfetch.download()
+            local_paths[module] = newfetch.localpath(url)
+
+            # Correct the submodule references to the local download version...
+            runfetchcmd("%(basecmd)s config submodule.%(module)s.url %(url)s" % {'basecmd': ud.basecmd, 'module': module, 'url' : local_paths[module]}, d, workdir=ud.clonedir)
+
+            symlink_path = os.path.join(ud.clonedir, 'modules', paths[module])
+            if not os.path.exists(symlink_path):
+                try:
+                    os.makedirs(os.path.dirname(symlink_path), exist_ok=True)
+                except OSError:
+                    pass
+                os.symlink(local_paths[module], symlink_path)
+
+        return True
+
+    def need_update(self, ud, d):
+        main_repo_needs_update = Git.need_update(self, ud, d)
+
+        # First check that the main repository has enough history fetched. If it doesn't, then we don't
+        # even have the .gitmodules and gitlinks for the submodules to attempt asking whether the
+        # submodules' histories are recent enough.
+        if main_repo_needs_update:
+            return True
+
+        # Now check that the submodule histories are new enough. The git-submodule command doesn't have
+        # any clean interface for doing this aside from just attempting the checkout (with network
+        # fetched disabled).
+        return not self.update_submodules(ud, d)
 
     def download(self, ud, d):
         Git.download(self, ud, d)
 
         if not ud.shallow or ud.localpath != ud.fullshallow:
-            submodules = self.uses_submodules(ud, d, ud.clonedir)
-            if submodules:
-                self.update_submodules(ud, d)
+            self.update_submodules(ud, d)
+
+    def copy_submodules(self, submodules, ud, destdir, d):
+        if ud.bareclone:
+            repo_conf = destdir
+        else:
+            repo_conf = os.path.join(destdir, '.git')
+
+        if submodules and not os.path.exists(os.path.join(repo_conf, 'modules')):
+            os.mkdir(os.path.join(repo_conf, 'modules'))
+
+        for module, md in submodules.items():
+            srcpath = os.path.join(ud.clonedir, 'modules', md['path'])
+            modpath = os.path.join(repo_conf, 'modules', md['path'])
+
+            if os.path.exists(srcpath):
+                if os.path.exists(os.path.join(srcpath, '.git')):
+                    srcpath = os.path.join(srcpath, '.git')
+
+                target = modpath
+                if os.path.exists(modpath):
+                    target = os.path.dirname(modpath)
+
+                os.makedirs(os.path.dirname(target), exist_ok=True)
+                runfetchcmd("cp -fpLR %s %s" % (srcpath, target), d)
+            elif os.path.exists(modpath):
+                # Module already exists, likely unpacked from a shallow mirror clone
+                pass
+            else:
+                # This is fatal, as we do NOT want git-submodule to hit the network
+                raise bb.fetch2.FetchError('Submodule %s does not exist in %s or %s.' % (module, srcpath, modpath))
 
     def clone_shallow_local(self, ud, dest, d):
         super(GitSM, self).clone_shallow_local(ud, dest, d)
 
-        runfetchcmd('cp -fpPRH "%s/modules" "%s/"' % (ud.clonedir, os.path.join(dest, '.git')), d)
+        # Copy over the submodules' fetched histories too.
+        repo_conf = os.path.join(dest, '.git')
+
+        submodules = []
+        for name in ud.names:
+            try:
+                gitmodules = runfetchcmd("%s show %s:.gitmodules" % (ud.basecmd, ud.revision), d, quiet=True, workdir=dest)
+            except:
+                # No submodules to update
+                continue
+
+            submodules = self.parse_gitmodules(gitmodules)
+            self.copy_submodules(submodules, ud, dest, d)
 
     def unpack(self, ud, destdir, d):
         Git.unpack(self, ud, destdir, d)
 
-        if self.uses_submodules(ud, d, ud.destdir):
-            runfetchcmd(ud.basecmd + " checkout " + ud.revisions[ud.names[0]], d, workdir=ud.destdir)
-            runfetchcmd(ud.basecmd + " submodule update --init --recursive", d, workdir=ud.destdir)
+        # Copy over the submodules' fetched histories too.
+        if ud.bareclone:
+            repo_conf = ud.destdir
+        else:
+            repo_conf = os.path.join(ud.destdir, '.git')
+
+        update_submodules = False
+        paths = {}
+        uris = {}
+        local_paths = {}
+        for name in ud.names:
+            try:
+                gitmodules = runfetchcmd("%s show HEAD:.gitmodules" % (ud.basecmd), d, quiet=True, workdir=ud.destdir)
+            except:
+                # No submodules to update
+                continue
+
+            submodules = self.parse_gitmodules(gitmodules)
+            self.copy_submodules(submodules, ud, ud.destdir, d)
+
+            submodules_queue = [(module, os.path.join(repo_conf, 'modules', md['path'])) for module, md in submodules.items()]
+            while len(submodules_queue) != 0:
+                module, modpath = submodules_queue.pop()
+
+                # add submodule children recursively
+                try:
+                    gitmodules = runfetchcmd("%s show HEAD:.gitmodules" % (ud.basecmd), d, quiet=True, workdir=modpath)
+                    for m, md in self.parse_gitmodules(gitmodules).items():
+                        submodules_queue.append([m, os.path.join(modpath, 'modules', md['path'])])
+                except:
+                    # no children
+                    pass
+
+
+                # There are submodules to update
+                update_submodules = True
+
+                # Determine (from the submodule) the correct url to reference
+                try:
+                    output = runfetchcmd("%(basecmd)s config remote.origin.url" % {'basecmd': ud.basecmd}, d, workdir=modpath)
+                except bb.fetch2.FetchError as e:
+                    # No remote url defined in this submodule
+                    continue
+
+                local_paths[module] = output
+
+                # Setup the local URL properly (like git submodule init or sync would do...)
+                runfetchcmd("%(basecmd)s config submodule.%(module)s.url %(url)s" % {'basecmd': ud.basecmd, 'module': module, 'url' : local_paths[module]}, d, workdir=ud.destdir)
+
+                # Ensure the submodule repository is NOT set to bare, since we're checking it out...
+                runfetchcmd("%s config core.bare false" % (ud.basecmd), d, quiet=True, workdir=modpath)
+
+        if update_submodules:
+            # Run submodule update, this sets up the directories -- without touching the config
+            runfetchcmd("%s submodule update --recursive --no-fetch" % (ud.basecmd), d, quiet=True, workdir=ud.destdir)
diff --git a/poky/bitbake/lib/bb/fetch2/hg.py b/poky/bitbake/lib/bb/fetch2/hg.py
index d0857e6..936d043 100644
--- a/poky/bitbake/lib/bb/fetch2/hg.py
+++ b/poky/bitbake/lib/bb/fetch2/hg.py
@@ -80,7 +80,7 @@
         ud.fullmirror = os.path.join(d.getVar("DL_DIR"), mirrortarball)
         ud.mirrortarballs = [mirrortarball]
 
-        hgdir = d.getVar("HGDIR") or (d.getVar("DL_DIR") + "/hg/")
+        hgdir = d.getVar("HGDIR") or (d.getVar("DL_DIR") + "/hg")
         ud.pkgdir = os.path.join(hgdir, hgsrcname)
         ud.moddir = os.path.join(ud.pkgdir, ud.module)
         ud.localfile = ud.moddir
diff --git a/poky/bitbake/lib/bb/fetch2/osc.py b/poky/bitbake/lib/bb/fetch2/osc.py
index 2b4f7d9..6c60456 100644
--- a/poky/bitbake/lib/bb/fetch2/osc.py
+++ b/poky/bitbake/lib/bb/fetch2/osc.py
@@ -32,8 +32,9 @@
         ud.module = ud.parm["module"]
 
         # Create paths to osc checkouts
+        oscdir = d.getVar("OSCDIR") or (d.getVar("DL_DIR") + "/osc")
         relpath = self._strip_leading_slashes(ud.path)
-        ud.pkgdir = os.path.join(d.getVar('OSCDIR'), ud.host)
+        ud.pkgdir = os.path.join(oscdir, ud.host)
         ud.moddir = os.path.join(ud.pkgdir, relpath, ud.module)
 
         if 'rev' in ud.parm:
@@ -54,7 +55,7 @@
         command is "fetch", "update", "info"
         """
 
-        basecmd = d.expand('${FETCHCMD_osc}')
+        basecmd = d.getVar("FETCHCMD_osc") or "/usr/bin/env osc"
 
         proto = ud.parm.get('protocol', 'ocs')
 
diff --git a/poky/bitbake/lib/bb/fetch2/perforce.py b/poky/bitbake/lib/bb/fetch2/perforce.py
index 3debad5..903a8e6 100644
--- a/poky/bitbake/lib/bb/fetch2/perforce.py
+++ b/poky/bitbake/lib/bb/fetch2/perforce.py
@@ -43,13 +43,9 @@
         provided by the env, use it.  If P4PORT is specified by the recipe, use
         its values, which may override the settings in P4CONFIG.
         """
-        ud.basecmd = d.getVar('FETCHCMD_p4')
-        if not ud.basecmd:
-            ud.basecmd = "/usr/bin/env p4"
+        ud.basecmd = d.getVar("FETCHCMD_p4") or "/usr/bin/env p4"
 
-        ud.dldir = d.getVar('P4DIR')
-        if not ud.dldir:
-            ud.dldir = '%s/%s' % (d.getVar('DL_DIR'), 'p4')
+        ud.dldir = d.getVar("P4DIR") or (d.getVar("DL_DIR") + "/p4")
 
         path = ud.url.split('://')[1]
         path = path.split(';')[0]
diff --git a/poky/bitbake/lib/bb/fetch2/repo.py b/poky/bitbake/lib/bb/fetch2/repo.py
index c22d9b5..8c7e818 100644
--- a/poky/bitbake/lib/bb/fetch2/repo.py
+++ b/poky/bitbake/lib/bb/fetch2/repo.py
@@ -45,6 +45,8 @@
         "master".
         """
 
+        ud.basecmd = d.getVar("FETCHCMD_repo") or "/usr/bin/env repo"
+
         ud.proto = ud.parm.get('protocol', 'git')
         ud.branch = ud.parm.get('branch', 'master')
         ud.manifest = ud.parm.get('manifest', 'default.xml')
@@ -60,8 +62,8 @@
             logger.debug(1, "%s already exists (or was stashed). Skipping repo init / sync.", ud.localpath)
             return
 
+        repodir = d.getVar("REPODIR") or (d.getVar("DL_DIR") + "/repo")
         gitsrcname = "%s%s" % (ud.host, ud.path.replace("/", "."))
-        repodir = d.getVar("REPODIR") or os.path.join(d.getVar("DL_DIR"), "repo")
         codir = os.path.join(repodir, gitsrcname, ud.manifest)
 
         if ud.user:
@@ -72,11 +74,11 @@
         repodir = os.path.join(codir, "repo")
         bb.utils.mkdirhier(repodir)
         if not os.path.exists(os.path.join(repodir, ".repo")):
-            bb.fetch2.check_network_access(d, "repo init -m %s -b %s -u %s://%s%s%s" % (ud.manifest, ud.branch, ud.proto, username, ud.host, ud.path), ud.url)
-            runfetchcmd("repo init -m %s -b %s -u %s://%s%s%s" % (ud.manifest, ud.branch, ud.proto, username, ud.host, ud.path), d, workdir=repodir)
+            bb.fetch2.check_network_access(d, "%s init -m %s -b %s -u %s://%s%s%s" % (ud.basecmd, ud.manifest, ud.branch, ud.proto, username, ud.host, ud.path), ud.url)
+            runfetchcmd("%s init -m %s -b %s -u %s://%s%s%s" % (ud.basecmd, ud.manifest, ud.branch, ud.proto, username, ud.host, ud.path), d, workdir=repodir)
 
-        bb.fetch2.check_network_access(d, "repo sync %s" % ud.url, ud.url)
-        runfetchcmd("repo sync", d, workdir=repodir)
+        bb.fetch2.check_network_access(d, "%s sync %s" % (ud.basecmd, ud.url), ud.url)
+        runfetchcmd("%s sync" % ud.basecmd, d, workdir=repodir)
 
         scmdata = ud.parm.get("scmdata", "")
         if scmdata == "keep":
diff --git a/poky/bitbake/lib/bb/fetch2/svn.py b/poky/bitbake/lib/bb/fetch2/svn.py
index 3f172ee..9dcf3eb 100644
--- a/poky/bitbake/lib/bb/fetch2/svn.py
+++ b/poky/bitbake/lib/bb/fetch2/svn.py
@@ -49,7 +49,7 @@
         if not "module" in ud.parm:
             raise MissingParameterError('module', ud.url)
 
-        ud.basecmd = d.getVar('FETCHCMD_svn')
+        ud.basecmd = d.getVar("FETCHCMD_svn") or "/usr/bin/env svn --non-interactive --trust-server-cert"
 
         ud.module = ud.parm["module"]
 
@@ -59,9 +59,13 @@
             ud.path_spec = ud.parm["path_spec"]
 
         # Create paths to svn checkouts
+        svndir = d.getVar("SVNDIR") or (d.getVar("DL_DIR") + "/svn")
         relpath = self._strip_leading_slashes(ud.path)
-        ud.pkgdir = os.path.join(d.expand('${SVNDIR}'), ud.host, relpath)
+        ud.pkgdir = os.path.join(svndir, ud.host, relpath)
         ud.moddir = os.path.join(ud.pkgdir, ud.module)
+        # Protects the repository from concurrent updates, e.g. from two
+        # recipes fetching different revisions at the same time
+        ud.svnlock = os.path.join(ud.pkgdir, "svn.lock")
 
         ud.setup_revisions(d)
 
@@ -122,35 +126,40 @@
 
         logger.debug(2, "Fetch: checking for module directory '" + ud.moddir + "'")
 
-        if os.access(os.path.join(ud.moddir, '.svn'), os.R_OK):
-            svnupdatecmd = self._buildsvncommand(ud, d, "update")
-            logger.info("Update " + ud.url)
-            # We need to attempt to run svn upgrade first in case its an older working format
-            try:
-                runfetchcmd(ud.basecmd + " upgrade", d, workdir=ud.moddir)
-            except FetchError:
-                pass
-            logger.debug(1, "Running %s", svnupdatecmd)
-            bb.fetch2.check_network_access(d, svnupdatecmd, ud.url)
-            runfetchcmd(svnupdatecmd, d, workdir=ud.moddir)
-        else:
-            svnfetchcmd = self._buildsvncommand(ud, d, "fetch")
-            logger.info("Fetch " + ud.url)
-            # check out sources there
-            bb.utils.mkdirhier(ud.pkgdir)
-            logger.debug(1, "Running %s", svnfetchcmd)
-            bb.fetch2.check_network_access(d, svnfetchcmd, ud.url)
-            runfetchcmd(svnfetchcmd, d, workdir=ud.pkgdir)
+        lf = bb.utils.lockfile(ud.svnlock)
 
-        scmdata = ud.parm.get("scmdata", "")
-        if scmdata == "keep":
-            tar_flags = ""
-        else:
-            tar_flags = "--exclude='.svn'"
+        try:
+            if os.access(os.path.join(ud.moddir, '.svn'), os.R_OK):
+                svnupdatecmd = self._buildsvncommand(ud, d, "update")
+                logger.info("Update " + ud.url)
+                # We need to attempt to run svn upgrade first in case its an older working format
+                try:
+                    runfetchcmd(ud.basecmd + " upgrade", d, workdir=ud.moddir)
+                except FetchError:
+                    pass
+                logger.debug(1, "Running %s", svnupdatecmd)
+                bb.fetch2.check_network_access(d, svnupdatecmd, ud.url)
+                runfetchcmd(svnupdatecmd, d, workdir=ud.moddir)
+            else:
+                svnfetchcmd = self._buildsvncommand(ud, d, "fetch")
+                logger.info("Fetch " + ud.url)
+                # check out sources there
+                bb.utils.mkdirhier(ud.pkgdir)
+                logger.debug(1, "Running %s", svnfetchcmd)
+                bb.fetch2.check_network_access(d, svnfetchcmd, ud.url)
+                runfetchcmd(svnfetchcmd, d, workdir=ud.pkgdir)
 
-        # tar them up to a defined filename
-        runfetchcmd("tar %s -czf %s %s" % (tar_flags, ud.localpath, ud.path_spec), d,
-                    cleanup=[ud.localpath], workdir=ud.pkgdir)
+            scmdata = ud.parm.get("scmdata", "")
+            if scmdata == "keep":
+                tar_flags = ""
+            else:
+                tar_flags = "--exclude='.svn'"
+
+            # tar them up to a defined filename
+            runfetchcmd("tar %s -czf %s %s" % (tar_flags, ud.localpath, ud.path_spec), d,
+                        cleanup=[ud.localpath], workdir=ud.pkgdir)
+        finally:
+            bb.utils.unlockfile(lf)
 
     def clean(self, ud, d):
         """ Clean SVN specific files and dirs """
diff --git a/poky/bitbake/lib/bb/msg.py b/poky/bitbake/lib/bb/msg.py
index f1723be..96f077e 100644
--- a/poky/bitbake/lib/bb/msg.py
+++ b/poky/bitbake/lib/bb/msg.py
@@ -40,6 +40,7 @@
     VERBOSE = logging.INFO - 1
     NOTE = logging.INFO
     PLAIN = logging.INFO + 1
+    VERBNOTE = logging.INFO + 2
     ERROR = logging.ERROR
     WARNING = logging.WARNING
     CRITICAL = logging.CRITICAL
@@ -51,6 +52,7 @@
         VERBOSE: 'NOTE',
         NOTE    : 'NOTE',
         PLAIN  : '',
+        VERBNOTE: 'NOTE',
         WARNING : 'WARNING',
         ERROR   : 'ERROR',
         CRITICAL: 'ERROR',
@@ -66,6 +68,7 @@
         VERBOSE : BASECOLOR,
         NOTE    : BASECOLOR,
         PLAIN   : BASECOLOR,
+        VERBNOTE: BASECOLOR,
         WARNING : YELLOW,
         ERROR   : RED,
         CRITICAL: RED,
diff --git a/poky/bitbake/lib/bb/parse/ast.py b/poky/bitbake/lib/bb/parse/ast.py
index 6690dc5..9d20c32 100644
--- a/poky/bitbake/lib/bb/parse/ast.py
+++ b/poky/bitbake/lib/bb/parse/ast.py
@@ -343,30 +343,31 @@
 
 def finalize(fn, d, variant = None):
     saved_handlers = bb.event.get_handlers().copy()
+    try:
+        for var in d.getVar('__BBHANDLERS', False) or []:
+            # try to add the handler
+            handlerfn = d.getVarFlag(var, "filename", False)
+            if not handlerfn:
+                bb.fatal("Undefined event handler function '%s'" % var)
+            handlerln = int(d.getVarFlag(var, "lineno", False))
+            bb.event.register(var, d.getVar(var, False), (d.getVarFlag(var, "eventmask") or "").split(), handlerfn, handlerln)
 
-    for var in d.getVar('__BBHANDLERS', False) or []:
-        # try to add the handler
-        handlerfn = d.getVarFlag(var, "filename", False)
-        if not handlerfn:
-            bb.fatal("Undefined event handler function '%s'" % var)
-        handlerln = int(d.getVarFlag(var, "lineno", False))
-        bb.event.register(var, d.getVar(var, False), (d.getVarFlag(var, "eventmask") or "").split(), handlerfn, handlerln)
+        bb.event.fire(bb.event.RecipePreFinalise(fn), d)
 
-    bb.event.fire(bb.event.RecipePreFinalise(fn), d)
+        bb.data.expandKeys(d)
+        runAnonFuncs(d)
 
-    bb.data.expandKeys(d)
-    runAnonFuncs(d)
+        tasklist = d.getVar('__BBTASKS', False) or []
+        bb.event.fire(bb.event.RecipeTaskPreProcess(fn, list(tasklist)), d)
+        bb.build.add_tasks(tasklist, d)
 
-    tasklist = d.getVar('__BBTASKS', False) or []
-    bb.event.fire(bb.event.RecipeTaskPreProcess(fn, list(tasklist)), d)
-    bb.build.add_tasks(tasklist, d)
+        bb.parse.siggen.finalise(fn, d, variant)
 
-    bb.parse.siggen.finalise(fn, d, variant)
+        d.setVar('BBINCLUDED', bb.parse.get_file_depends(d))
 
-    d.setVar('BBINCLUDED', bb.parse.get_file_depends(d))
-
-    bb.event.fire(bb.event.RecipeParsed(fn), d)
-    bb.event.set_handlers(saved_handlers)
+        bb.event.fire(bb.event.RecipeParsed(fn), d)
+    finally:
+        bb.event.set_handlers(saved_handlers)
 
 def _create_variants(datastores, names, function, onlyfinalise):
     def create_variant(name, orig_d, arg = None):
diff --git a/poky/bitbake/lib/bb/runqueue.py b/poky/bitbake/lib/bb/runqueue.py
index 480a851..4d5d876 100644
--- a/poky/bitbake/lib/bb/runqueue.py
+++ b/poky/bitbake/lib/bb/runqueue.py
@@ -94,13 +94,13 @@
         self.active = self.active - 1
         self.failed = self.failed + 1
 
-    def taskCompleted(self, number = 1):
-        self.active = self.active - number
-        self.completed = self.completed + number
+    def taskCompleted(self):
+        self.active = self.active - 1
+        self.completed = self.completed + 1
 
-    def taskSkipped(self, number = 1):
-        self.active = self.active + number
-        self.skipped = self.skipped + number
+    def taskSkipped(self):
+        self.active = self.active + 1
+        self.skipped = self.skipped + 1
 
     def taskActive(self):
         self.active = self.active + 1
@@ -134,6 +134,7 @@
         self.prio_map = [self.rqdata.runtaskentries.keys()]
 
         self.buildable = []
+        self.skip_maxthread = {}
         self.stamps = {}
         for tid in self.rqdata.runtaskentries:
             (mc, fn, taskname, taskfn) = split_tid_mcfn(tid)
@@ -150,8 +151,25 @@
         self.buildable = [x for x in self.buildable if x not in self.rq.runq_running]
         if not self.buildable:
             return None
+
+        # Filter out tasks that have a max number of threads that have been exceeded
+        skip_buildable = {}
+        for running in self.rq.runq_running.difference(self.rq.runq_complete):
+            rtaskname = taskname_from_tid(running)
+            if rtaskname not in self.skip_maxthread:
+                self.skip_maxthread[rtaskname] = self.rq.cfgData.getVarFlag(rtaskname, "number_threads")
+            if not self.skip_maxthread[rtaskname]:
+                continue
+            if rtaskname in skip_buildable:
+                skip_buildable[rtaskname] += 1
+            else:
+                skip_buildable[rtaskname] = 1
+
         if len(self.buildable) == 1:
             tid = self.buildable[0]
+            taskname = taskname_from_tid(tid)
+            if taskname in skip_buildable and skip_buildable[taskname] >= int(self.skip_maxthread[taskname]):
+                return None
             stamp = self.stamps[tid]
             if stamp not in self.rq.build_stamps.values():
                 return tid
@@ -164,6 +182,9 @@
         best = None
         bestprio = None
         for tid in self.buildable:
+            taskname = taskname_from_tid(tid)
+            if taskname in skip_buildable and skip_buildable[taskname] >= int(self.skip_maxthread[taskname]):
+                continue
             prio = self.rev_prio_map[tid]
             if bestprio is None or bestprio > prio:
                 stamp = self.stamps[tid]
@@ -178,7 +199,7 @@
         """
         Return the id of the task we should build next
         """
-        if self.rq.stats.active < self.rq.number_tasks:
+        if self.rq.can_start_task():
             return self.next_buildable_task()
 
     def newbuildable(self, task):
@@ -581,6 +602,19 @@
                     if t in taskData[mc].taskentries:
                         depends.add(t)
 
+        def add_mc_dependencies(mc, tid):
+            mcdeps = taskData[mc].get_mcdepends()
+            for dep in mcdeps:
+                mcdependency = dep.split(':')
+                pn = mcdependency[3]
+                frommc = mcdependency[1]
+                mcdep = mcdependency[2]
+                deptask = mcdependency[4]
+                if mc == frommc:
+                    fn = taskData[mcdep].build_targets[pn][0]
+                    newdep = '%s:%s' % (fn,deptask)
+                    taskData[mc].taskentries[tid].tdepends.append(newdep)
+
         for mc in taskData:
             for tid in taskData[mc].taskentries:
 
@@ -597,12 +631,16 @@
                 if fn in taskData[mc].failed_fns:
                     continue
 
+                # We add multiconfig dependencies before processing internal task deps (tdepends)
+                if 'mcdepends' in task_deps and taskname in task_deps['mcdepends']:
+                    add_mc_dependencies(mc, tid)
+
                 # Resolve task internal dependencies
                 #
                 # e.g. addtask before X after Y
                 for t in taskData[mc].taskentries[tid].tdepends:
-                    (_, depfn, deptaskname, _) = split_tid_mcfn(t)
-                    depends.add(build_tid(mc, depfn, deptaskname))
+                    (depmc, depfn, deptaskname, _) = split_tid_mcfn(t)
+                    depends.add(build_tid(depmc, depfn, deptaskname))
 
                 # Resolve 'deptask' dependencies
                 #
@@ -1032,7 +1070,7 @@
                     msg += "\n%s has unique rprovides:\n  %s" % (provfn, "\n  ".join(rprovide_results[provfn] - commonrprovs))
 
                 if self.warn_multi_bb:
-                    logger.warning(msg)
+                    logger.verbnote(msg)
                 else:
                     logger.error(msg)
 
@@ -1040,7 +1078,7 @@
 
         # Create a whitelist usable by the stamp checks
         self.stampfnwhitelist = {}
-        for mc in self.taskData: 
+        for mc in self.taskData:
             self.stampfnwhitelist[mc] = []
             for entry in self.stampwhitelist.split():
                 if entry not in self.taskData[mc].build_targets:
@@ -1072,7 +1110,7 @@
                     bb.debug(1, "Task %s is marked nostamp, cannot invalidate this task" % taskname)
             else:
                 logger.verbose("Invalidate task %s, %s", taskname, fn)
-                bb.parse.siggen.invalidate_task(taskname, self.dataCaches[mc], fn)
+                bb.parse.siggen.invalidate_task(taskname, self.dataCaches[mc], taskfn)
 
         self.init_progress_reporter.next_stage()
 
@@ -1717,6 +1755,10 @@
         valid = bb.utils.better_eval(call, locs)
         return valid
 
+    def can_start_task(self):
+        can_start = self.stats.active < self.number_tasks
+        return can_start
+
 class RunQueueExecuteDummy(RunQueueExecute):
     def __init__(self, rq):
         self.rq = rq
@@ -1790,13 +1832,14 @@
             bb.build.del_stamp(taskname, self.rqdata.dataCaches[mc], taskfn)
             self.rq.scenequeue_covered.remove(tid)
 
-        toremove = covered_remove
+        toremove = covered_remove | self.rq.scenequeue_notcovered
         for task in toremove:
             logger.debug(1, 'Not skipping task %s due to setsceneverify', task)
         while toremove:
             covered_remove = []
             for task in toremove:
-                removecoveredtask(task)
+                if task in self.rq.scenequeue_covered:
+                    removecoveredtask(task)
                 for deptask in self.rqdata.runtaskentries[task].depends:
                     if deptask not in self.rq.scenequeue_covered:
                         continue
@@ -1866,14 +1909,13 @@
                 continue
             if revdep in self.runq_buildable:
                 continue
-            alldeps = 1
+            alldeps = True
             for dep in self.rqdata.runtaskentries[revdep].depends:
                 if dep not in self.runq_complete:
-                    alldeps = 0
-            if alldeps == 1:
+                    alldeps = False
+                    break
+            if alldeps:
                 self.setbuildable(revdep)
-                fn = fn_from_tid(revdep)
-                taskname = taskname_from_tid(revdep)
                 logger.debug(1, "Marking task %s as buildable", revdep)
 
     def task_complete(self, task):
@@ -1897,8 +1939,8 @@
         self.setbuildable(task)
         bb.event.fire(runQueueTaskSkipped(task, self.stats, self.rq, reason), self.cfgData)
         self.task_completeoutright(task)
-        self.stats.taskCompleted()
         self.stats.taskSkipped()
+        self.stats.taskCompleted()
 
     def execute(self):
         """
@@ -2008,7 +2050,7 @@
             self.build_stamps2.append(self.build_stamps[task])
             self.runq_running.add(task)
             self.stats.taskActive()
-            if self.stats.active < self.number_tasks:
+            if self.can_start_task():
                 return True
 
         if self.stats.active > 0:
@@ -2063,6 +2105,7 @@
         # If we don't have any setscene functions, skip this step
         if len(self.rqdata.runq_setscene_tids) == 0:
             rq.scenequeue_covered = set()
+            rq.scenequeue_notcovered = set()
             rq.state = runQueueRunInit
             return
 
@@ -2278,10 +2321,15 @@
                 sq_hash.append(self.rqdata.runtaskentries[tid].hash)
                 sq_taskname.append(taskname)
                 sq_task.append(tid)
+
+            self.cooker.data.setVar("BB_SETSCENE_STAMPCURRENT_COUNT", len(stamppresent))
+
             call = self.rq.hashvalidate + "(sq_fn, sq_task, sq_hash, sq_hashfn, d)"
             locs = { "sq_fn" : sq_fn, "sq_task" : sq_taskname, "sq_hash" : sq_hash, "sq_hashfn" : sq_hashfn, "d" : self.cooker.data }
             valid = bb.utils.better_eval(call, locs)
 
+            self.cooker.data.delVar("BB_SETSCENE_STAMPCURRENT_COUNT")
+
             valid_new = stamppresent
             for v in valid:
                 valid_new.append(sq_task[v])
@@ -2343,8 +2391,8 @@
     def task_failoutright(self, task):
         self.runq_running.add(task)
         self.runq_buildable.add(task)
-        self.stats.taskCompleted()
         self.stats.taskSkipped()
+        self.stats.taskCompleted()
         self.scenequeue_notcovered.add(task)
         self.scenequeue_updatecounters(task, True)
 
@@ -2352,8 +2400,8 @@
         self.runq_running.add(task)
         self.runq_buildable.add(task)
         self.task_completeoutright(task)
-        self.stats.taskCompleted()
         self.stats.taskSkipped()
+        self.stats.taskCompleted()
 
     def execute(self):
         """
@@ -2363,7 +2411,7 @@
         self.rq.read_workers()
 
         task = None
-        if self.stats.active < self.number_tasks:
+        if self.can_start_task():
             # Find the next setscene to run
             for nexttask in self.rqdata.runq_setscene_tids:
                 if nexttask in self.runq_buildable and nexttask not in self.runq_running and self.stamps[nexttask] not in self.build_stamps.values():
@@ -2422,7 +2470,7 @@
             self.build_stamps2.append(self.build_stamps[task])
             self.runq_running.add(task)
             self.stats.taskActive()
-            if self.stats.active < self.number_tasks:
+            if self.can_start_task():
                 return True
 
         if self.stats.active > 0:
diff --git a/poky/bitbake/lib/bb/server/process.py b/poky/bitbake/lib/bb/server/process.py
index 0749b5b..42d7907 100644
--- a/poky/bitbake/lib/bb/server/process.py
+++ b/poky/bitbake/lib/bb/server/process.py
@@ -377,11 +377,12 @@
         if os.path.exists(sockname):
             os.unlink(sockname)
 
+        # Place the log in the builddirectory alongside the lock file
+        logfile = os.path.join(os.path.dirname(self.bitbake_lock.name), "bitbake-cookerdaemon.log")
+
         self.sock = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM)
         # AF_UNIX has path length issues so chdir here to workaround
         cwd = os.getcwd()
-        logfile = os.path.join(cwd, "bitbake-cookerdaemon.log")
-
         try:
             os.chdir(os.path.dirname(sockname))
             self.sock.bind(os.path.basename(sockname))
@@ -394,11 +395,16 @@
         bb.daemonize.createDaemon(self._startServer, logfile)
         self.sock.close()
         self.bitbake_lock.close()
+        os.close(self.readypipein)
 
         ready = ConnectionReader(self.readypipe)
         r = ready.poll(30)
         if r:
-            r = ready.get()
+            try:
+                r = ready.get()
+            except EOFError:
+                # Trap the child exitting/closing the pipe and error out
+                r = None
         if not r or r != "ready":
             ready.close()
             bb.error("Unable to start bitbake server")
@@ -424,7 +430,6 @@
                         bb.error("Server log for this session (%s):\n%s" % (logfile, "".join(lines)))
             raise SystemExit(1)
         ready.close()
-        os.close(self.readypipein)
 
     def _startServer(self):
         print(self.start_log_format % (os.getpid(), datetime.datetime.now().strftime(self.start_log_datetime_format)))
@@ -432,15 +437,11 @@
 
         server = ProcessServer(self.bitbake_lock, self.sock, self.sockname)
         self.configuration.setServerRegIdleCallback(server.register_idle_function)
+        os.close(self.readypipe)
         writer = ConnectionWriter(self.readypipein)
-        try:
-            self.cooker = bb.cooker.BBCooker(self.configuration, self.featureset)
-            writer.send("ready")
-        except:
-            writer.send("fail")
-            raise
-        finally:
-            os.close(self.readypipein)
+        self.cooker = bb.cooker.BBCooker(self.configuration, self.featureset)
+        writer.send("ready")
+        writer.close()
         server.cooker = self.cooker
         server.server_timeout = self.configuration.server_timeout
         server.xmlrpcinterface = self.configuration.xmlrpcinterface
@@ -455,9 +456,6 @@
     # AF_UNIX has path length issues so chdir here to workaround
     cwd = os.getcwd()
 
-    readfd = writefd = readfd1 = writefd1 = readfd2 = writefd2 = None
-    eq = command_chan_recv = command_chan = None
-
     try:
         try:
             os.chdir(os.path.dirname(sockname))
@@ -465,6 +463,9 @@
         finally:
             os.chdir(cwd)
 
+        readfd = writefd = readfd1 = writefd1 = readfd2 = writefd2 = None
+        eq = command_chan_recv = command_chan = None
+
         # Send an fd for the remote to write events to
         readfd, writefd = os.pipe()
         eq = BBUIEventQueue(readfd)
diff --git a/poky/bitbake/lib/bb/siggen.py b/poky/bitbake/lib/bb/siggen.py
index 5ef82d7..fdbb2a3 100644
--- a/poky/bitbake/lib/bb/siggen.py
+++ b/poky/bitbake/lib/bb/siggen.py
@@ -110,42 +110,13 @@
         ignore_mismatch = ((d.getVar("BB_HASH_IGNORE_MISMATCH") or '') == '1')
         tasklist, gendeps, lookupcache = bb.data.generate_dependencies(d)
 
-        taskdeps = {}
-        basehash = {}
+        taskdeps, basehash = bb.data.generate_dependency_hash(tasklist, gendeps, lookupcache, self.basewhitelist, fn)
 
         for task in tasklist:
-            data = lookupcache[task]
-
-            if data is None:
-                bb.error("Task %s from %s seems to be empty?!" % (task, fn))
-                data = ''
-
-            gendeps[task] -= self.basewhitelist
-            newdeps = gendeps[task]
-            seen = set()
-            while newdeps:
-                nextdeps = newdeps
-                seen |= nextdeps
-                newdeps = set()
-                for dep in nextdeps:
-                    if dep in self.basewhitelist:
-                        continue
-                    gendeps[dep] -= self.basewhitelist
-                    newdeps |= gendeps[dep]
-                newdeps -= seen
-
-            alldeps = sorted(seen)
-            for dep in alldeps:
-                data = data + dep
-                var = lookupcache[dep]
-                if var is not None:
-                    data = data + str(var)
-            datahash = hashlib.md5(data.encode("utf-8")).hexdigest()
             k = fn + "." + task
-            if not ignore_mismatch and k in self.basehash and self.basehash[k] != datahash:
-                bb.error("When reparsing %s, the basehash value changed from %s to %s. The metadata is not deterministic and this needs to be fixed." % (k, self.basehash[k], datahash))
-            self.basehash[k] = datahash
-            taskdeps[task] = alldeps
+            if not ignore_mismatch and k in self.basehash and self.basehash[k] != basehash[k]:
+                bb.error("When reparsing %s, the basehash value changed from %s to %s. The metadata is not deterministic and this needs to be fixed." % (k, self.basehash[k], basehash[k]))
+            self.basehash[k] = basehash[k]
 
         self.taskdeps[fn] = taskdeps
         self.gendeps[fn] = gendeps
@@ -193,19 +164,28 @@
         return taint
 
     def get_taskhash(self, fn, task, deps, dataCache):
+
+        mc = ''
+        if fn.startswith('multiconfig:'):
+            mc = fn.split(':')[1]
         k = fn + "." + task
+
         data = dataCache.basetaskhash[k]
         self.basehash[k] = data
         self.runtaskdeps[k] = []
         self.file_checksum_values[k] = []
         recipename = dataCache.pkg_fn[fn]
-
         for dep in sorted(deps, key=clean_basepath):
-            depname = dataCache.pkg_fn[self.pkgnameextract.search(dep).group('fn')]
+            pkgname = self.pkgnameextract.search(dep).group('fn')
+            if mc:
+                depmc = pkgname.split(':')[1]
+                if mc != depmc:
+                    continue
+            depname = dataCache.pkg_fn[pkgname]
             if not self.rundep_check(fn, recipename, task, dep, depname, dataCache):
                 continue
             if dep not in self.taskhash:
-                bb.fatal("%s is not in taskhash, caller isn't calling in dependency order?", dep)
+                bb.fatal("%s is not in taskhash, caller isn't calling in dependency order?" % dep)
             data = data + self.taskhash[dep]
             self.runtaskdeps[k].append(dep)
 
@@ -347,7 +327,7 @@
 
     def stampcleanmask(self, stampbase, fn, taskname, extrainfo):
         return self.stampfile(stampbase, fn, taskname, extrainfo, clean=True)
-        
+
     def invalidate_task(self, task, d, fn):
         bb.note("Tainting hash to force rebuild of task %s, %s" % (fn, task))
         bb.build.write_taint(task, d, fn)
@@ -362,10 +342,10 @@
 def init_colors(enable_color):
     """Initialise colour dict for passing to compare_sigfiles()"""
     # First set up the colours
-    colors = {'color_title':   '\033[1;37;40m',
-              'color_default': '\033[0;37;40m',
-              'color_add':     '\033[1;32;40m',
-              'color_remove':  '\033[1;31;40m',
+    colors = {'color_title':   '\033[1m',
+              'color_default': '\033[0m',
+              'color_add':     '\033[0;32m',
+              'color_remove':  '\033[0;31m',
              }
     # Leave all keys present but clear the values
     if not enable_color:
@@ -636,7 +616,7 @@
                         if collapsed:
                             output.extend(recout)
                         else:
-                            # If a dependent hash changed, might as well print the line above and then defer to the changes in 
+                            # If a dependent hash changed, might as well print the line above and then defer to the changes in
                             # that hash since in all likelyhood, they're the same changes this task also saw.
                             output = [output[-1]] + recout
 
diff --git a/poky/bitbake/lib/bb/taskdata.py b/poky/bitbake/lib/bb/taskdata.py
index 0ea6c0b..94e822c 100644
--- a/poky/bitbake/lib/bb/taskdata.py
+++ b/poky/bitbake/lib/bb/taskdata.py
@@ -70,6 +70,8 @@
 
         self.skiplist = skiplist
 
+        self.mcdepends = []
+
     def add_tasks(self, fn, dataCache):
         """
         Add tasks for a given fn to the database
@@ -88,6 +90,13 @@
 
         self.add_extra_deps(fn, dataCache)
 
+        def add_mcdepends(task):
+            for dep in task_deps['mcdepends'][task].split():
+                if len(dep.split(':')) != 5:
+                    bb.msg.fatal("TaskData", "Error for %s:%s[%s], multiconfig dependency %s does not contain exactly four  ':' characters.\n Task '%s' should be specified in the form 'multiconfig:fromMC:toMC:packagename:task'" % (fn, task, 'mcdepends', dep, 'mcdepends'))
+                if dep not in self.mcdepends:
+                    self.mcdepends.append(dep)
+
         # Common code for dep_name/depends = 'depends'/idepends and 'rdepends'/irdepends
         def handle_deps(task, dep_name, depends, seen):
             if dep_name in task_deps and task in task_deps[dep_name]:
@@ -110,16 +119,20 @@
             parentids = []
             for dep in task_deps['parents'][task]:
                 if dep not in task_deps['tasks']:
-                    bb.debug(2, "Not adding dependeny of %s on %s since %s does not exist" % (task, dep, dep))
+                    bb.debug(2, "Not adding dependency of %s on %s since %s does not exist" % (task, dep, dep))
                     continue
                 parentid = "%s:%s" % (fn, dep)
                 parentids.append(parentid)
             self.taskentries[tid].tdepends.extend(parentids)
 
+
             # Touch all intertask dependencies
             handle_deps(task, 'depends', self.taskentries[tid].idepends, self.seen_build_target)
             handle_deps(task, 'rdepends', self.taskentries[tid].irdepends, self.seen_run_target)
 
+            if 'mcdepends' in task_deps and task in task_deps['mcdepends']:
+                add_mcdepends(task)
+
         # Work out build dependencies
         if not fn in self.depids:
             dependids = set()
@@ -537,6 +550,9 @@
                     provmap[name] = provider[0]
         return provmap
 
+    def get_mcdepends(self):
+        return self.mcdepends
+
     def dump_data(self):
         """
         Dump some debug information on the internal data structures
diff --git a/poky/bitbake/lib/bb/tests/cooker.py b/poky/bitbake/lib/bb/tests/cooker.py
new file mode 100644
index 0000000..2b44236
--- /dev/null
+++ b/poky/bitbake/lib/bb/tests/cooker.py
@@ -0,0 +1,83 @@
+# ex:ts=4:sw=4:sts=4:et
+# -*- tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*-
+#
+# BitBake Tests for cooker.py
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License version 2 as
+# published by the Free Software Foundation.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License along
+# with this program; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+#
+
+import unittest
+import tempfile
+import os
+import bb, bb.cooker
+import re
+import logging
+
+# Cooker tests
+class CookerTest(unittest.TestCase):
+    def setUp(self):
+        # At least one variable needs to be set
+        self.d = bb.data.init()
+        topdir = os.path.join(os.path.dirname(os.path.realpath(__file__)), "testdata/cooker")
+        self.d.setVar('TOPDIR', topdir)
+
+    def test_CookerCollectFiles_sublayers(self):
+        '''Test that a sublayer of an existing layer does not trigger
+           No bb files matched ...'''
+
+        def append_collection(topdir, path, d):
+            collection = path.split('/')[-1]
+            pattern = "^" + topdir + "/" + path + "/"
+            regex = re.compile(pattern)
+            priority = 5
+
+            d.setVar('BBFILE_COLLECTIONS', (d.getVar('BBFILE_COLLECTIONS') or "") + " " + collection)
+            d.setVar('BBFILE_PATTERN_%s' % (collection), pattern)
+            d.setVar('BBFILE_PRIORITY_%s' % (collection), priority)
+
+            return (collection, pattern, regex, priority)
+
+        topdir = self.d.getVar("TOPDIR")
+
+        # Priorities: list of (collection, pattern, regex, priority)
+        bbfile_config_priorities = []
+        # Order is important for this test, shortest to longest is typical failure case
+        bbfile_config_priorities.append( append_collection(topdir, 'first', self.d) )
+        bbfile_config_priorities.append( append_collection(topdir, 'second', self.d) )
+        bbfile_config_priorities.append( append_collection(topdir, 'second/third', self.d) )
+
+        pkgfns = [ topdir + '/first/recipes/sample1_1.0.bb',
+                   topdir + '/second/recipes/sample2_1.0.bb',
+                   topdir + '/second/third/recipes/sample3_1.0.bb' ]
+
+        class LogHandler(logging.Handler):
+            def __init__(self):
+                logging.Handler.__init__(self)
+                self.logdata = []
+
+            def emit(self, record):
+                self.logdata.append(record.getMessage())
+
+        # Move cooker to use my special logging
+        logger = bb.cooker.logger
+        log_handler = LogHandler()
+        logger.addHandler(log_handler)
+        collection = bb.cooker.CookerCollectFiles(bbfile_config_priorities)
+        collection.collection_priorities(pkgfns, self.d)
+        logger.removeHandler(log_handler)
+
+        # Should be empty (no generated messages)
+        expected = []
+
+        self.assertEqual(log_handler.logdata, expected)
diff --git a/poky/bitbake/lib/bb/tests/data.py b/poky/bitbake/lib/bb/tests/data.py
index a4a9dd3..db3e201 100644
--- a/poky/bitbake/lib/bb/tests/data.py
+++ b/poky/bitbake/lib/bb/tests/data.py
@@ -281,7 +281,7 @@
     def test_remove(self):
         self.d.setVar("TEST", "${VAL} ${BAR}")
         self.d.setVar("TEST_remove", "val")
-        self.assertEqual(self.d.getVar("TEST"), "bar")
+        self.assertEqual(self.d.getVar("TEST"), " bar")
 
     def test_remove_cleared(self):
         self.d.setVar("TEST", "${VAL} ${BAR}")
@@ -300,7 +300,7 @@
         self.d.setVar("TEST", "${VAL} ${BAR}")
         self.d.setVar("TEST_remove", "val")
         self.d.setVar("TEST_TEST", "${TEST} ${TEST}")
-        self.assertEqual(self.d.getVar("TEST_TEST"), "bar bar")
+        self.assertEqual(self.d.getVar("TEST_TEST"), " bar  bar")
 
     def test_empty_remove(self):
         self.d.setVar("TEST", "")
@@ -311,13 +311,25 @@
         self.d.setVar("BAR", "Z")
         self.d.setVar("TEST", "${BAR}/X Y")
         self.d.setVar("TEST_remove", "${BAR}/X")
-        self.assertEqual(self.d.getVar("TEST"), "Y")
+        self.assertEqual(self.d.getVar("TEST"), " Y")
 
     def test_remove_expansion_items(self):
         self.d.setVar("TEST", "A B C D")
         self.d.setVar("BAR", "B D")
         self.d.setVar("TEST_remove", "${BAR}")
-        self.assertEqual(self.d.getVar("TEST"), "A C")
+        self.assertEqual(self.d.getVar("TEST"), "A  C ")
+
+    def test_remove_preserve_whitespace(self):
+        # When the removal isn't active, the original value should be preserved
+        self.d.setVar("TEST", " A B")
+        self.d.setVar("TEST_remove", "C")
+        self.assertEqual(self.d.getVar("TEST"), " A B")
+
+    def test_remove_preserve_whitespace2(self):
+        # When the removal is active preserve the whitespace
+        self.d.setVar("TEST", " A B")
+        self.d.setVar("TEST_remove", "B")
+        self.assertEqual(self.d.getVar("TEST"), " A ")
 
 class TestOverrides(unittest.TestCase):
     def setUp(self):
@@ -374,6 +386,15 @@
         self.d.setVar("OVERRIDES", "foo:bar:some_val")
         self.assertEqual(self.d.getVar("TEST"), "testvalue3")
 
+    def test_remove_with_override(self):
+        self.d.setVar("TEST_bar", "testvalue2")
+        self.d.setVar("TEST_some_val", "testvalue3 testvalue5")
+        self.d.setVar("TEST_some_val_remove", "testvalue3")
+        self.d.setVar("TEST_foo", "testvalue4")
+        self.d.setVar("OVERRIDES", "foo:bar:some_val")
+        self.assertEqual(self.d.getVar("TEST"), " testvalue5")
+
+
 class TestKeyExpansion(unittest.TestCase):
     def setUp(self):
         self.d = bb.data.init()
@@ -443,6 +464,54 @@
         self.assertFalse(bb.utils.contains_any("SOMEFLAG", "x y z", True, False, self.d))
 
 
+class TaskHash(unittest.TestCase):
+    def test_taskhashes(self):
+        def gettask_bashhash(taskname, d):
+            tasklist, gendeps, lookupcache = bb.data.generate_dependencies(d)
+            taskdeps, basehash = bb.data.generate_dependency_hash(tasklist, gendeps, lookupcache, set(), "somefile")
+            bb.warn(str(lookupcache))
+            return basehash["somefile." + taskname]
+
+        d = bb.data.init()
+        d.setVar("__BBTASKS", ["mytask"])
+        d.setVar("__exportlist", [])
+        d.setVar("mytask", "${MYCOMMAND}")
+        d.setVar("MYCOMMAND", "${VAR}; foo; bar; exit 0")
+        d.setVar("VAR", "val")
+        orighash = gettask_bashhash("mytask", d)
+
+        # Changing a variable should change the hash
+        d.setVar("VAR", "val2")
+        nexthash = gettask_bashhash("mytask", d)
+        self.assertNotEqual(orighash, nexthash)
+
+        d.setVar("VAR", "val")
+        # Adding an inactive removal shouldn't change the hash
+        d.setVar("BAR", "notbar")
+        d.setVar("MYCOMMAND_remove", "${BAR}")
+        nexthash = gettask_bashhash("mytask", d)
+        self.assertEqual(orighash, nexthash)
+
+        # Adding an active removal should change the hash
+        d.setVar("BAR", "bar;")
+        nexthash = gettask_bashhash("mytask", d)
+        self.assertNotEqual(orighash, nexthash)
+
+        # Setup an inactive contains()
+        d.setVar("VAR", "${@bb.utils.contains('VAR2', 'A', 'val', '', d)}")
+        orighash = gettask_bashhash("mytask", d)
+
+        # Activate the contains() and the hash should change
+        d.setVar("VAR2", "A")
+        nexthash = gettask_bashhash("mytask", d)
+        self.assertNotEqual(orighash, nexthash)
+
+        # The contains should be inactive but even though VAR2 has a
+        # different value the hash should match the original
+        d.setVar("VAR2", "B")
+        nexthash = gettask_bashhash("mytask", d)
+        self.assertEqual(orighash, nexthash)
+
 class Serialize(unittest.TestCase):
 
     def test_serialize(self):
diff --git a/poky/bitbake/lib/bb/tests/fetch.py b/poky/bitbake/lib/bb/tests/fetch.py
index 68eb388..6848095 100644
--- a/poky/bitbake/lib/bb/tests/fetch.py
+++ b/poky/bitbake/lib/bb/tests/fetch.py
@@ -402,6 +402,12 @@
             : "git://somewhere.org/somedir/mtd-utils.git;tag=1234567890123456789012345678901234567890;protocol=http", 
         ("git://git.invalid.infradead.org/foo/mtd-utils.git;tag=1234567890123456789012345678901234567890", "git://.*/.*", "git://somewhere.org/somedir/MIRRORNAME;protocol=http") 
             : "git://somewhere.org/somedir/git.invalid.infradead.org.foo.mtd-utils.git;tag=1234567890123456789012345678901234567890;protocol=http", 
+        ("http://somewhere.org/somedir1/somedir2/somefile_1.2.3.tar.gz", "http://.*/.*", "http://somewhere2.org")
+            : "http://somewhere2.org/somefile_1.2.3.tar.gz",
+        ("http://somewhere.org/somedir1/somedir2/somefile_1.2.3.tar.gz", "http://.*/.*", "http://somewhere2.org/")
+            : "http://somewhere2.org/somefile_1.2.3.tar.gz",
+        ("git://someserver.org/bitbake;tag=1234567890123456789012345678901234567890;branch=master", "git://someserver.org/bitbake;branch=master", "git://git.openembedded.org/bitbake;protocol=http")
+            : "git://git.openembedded.org/bitbake;tag=1234567890123456789012345678901234567890;branch=master;protocol=http",
 
         #Renaming files doesn't work
         #("http://somewhere.org/somedir1/somefile_1.2.3.tar.gz", "http://somewhere.org/somedir1/somefile_1.2.3.tar.gz", "http://somewhere2.org/somedir3/somefile_2.3.4.tar.gz") : "http://somewhere2.org/somedir3/somefile_2.3.4.tar.gz"
@@ -457,6 +463,124 @@
                                 'https://BBBB/B/B/B/bitbake/bitbake-1.0.tar.gz',
                                 'http://AAAA/A/A/A/B/B/bitbake/bitbake-1.0.tar.gz'])
 
+
+class GitDownloadDirectoryNamingTest(FetcherTest):
+    def setUp(self):
+        super(GitDownloadDirectoryNamingTest, self).setUp()
+        self.recipe_url = "git://git.openembedded.org/bitbake"
+        self.recipe_dir = "git.openembedded.org.bitbake"
+        self.mirror_url = "git://github.com/openembedded/bitbake.git"
+        self.mirror_dir = "github.com.openembedded.bitbake.git"
+
+        self.d.setVar('SRCREV', '82ea737a0b42a8b53e11c9cde141e9e9c0bd8c40')
+
+    def setup_mirror_rewrite(self):
+        self.d.setVar("PREMIRRORS", self.recipe_url + " " + self.mirror_url + " \n")
+
+    @skipIfNoNetwork()
+    def test_that_directory_is_named_after_recipe_url_when_no_mirroring_is_used(self):
+        self.setup_mirror_rewrite()
+        fetcher = bb.fetch.Fetch([self.recipe_url], self.d)
+
+        fetcher.download()
+
+        dir = os.listdir(self.dldir + "/git2")
+        self.assertIn(self.recipe_dir, dir)
+
+    @skipIfNoNetwork()
+    def test_that_directory_exists_for_mirrored_url_and_recipe_url_when_mirroring_is_used(self):
+        self.setup_mirror_rewrite()
+        fetcher = bb.fetch.Fetch([self.recipe_url], self.d)
+
+        fetcher.download()
+
+        dir = os.listdir(self.dldir + "/git2")
+        self.assertIn(self.mirror_dir, dir)
+        self.assertIn(self.recipe_dir, dir)
+
+    @skipIfNoNetwork()
+    def test_that_recipe_directory_and_mirrored_directory_exists_when_mirroring_is_used_and_the_mirrored_directory_already_exists(self):
+        self.setup_mirror_rewrite()
+        fetcher = bb.fetch.Fetch([self.mirror_url], self.d)
+        fetcher.download()
+        fetcher = bb.fetch.Fetch([self.recipe_url], self.d)
+
+        fetcher.download()
+
+        dir = os.listdir(self.dldir + "/git2")
+        self.assertIn(self.mirror_dir, dir)
+        self.assertIn(self.recipe_dir, dir)
+
+
+class TarballNamingTest(FetcherTest):
+    def setUp(self):
+        super(TarballNamingTest, self).setUp()
+        self.recipe_url = "git://git.openembedded.org/bitbake"
+        self.recipe_tarball = "git2_git.openembedded.org.bitbake.tar.gz"
+        self.mirror_url = "git://github.com/openembedded/bitbake.git"
+        self.mirror_tarball = "git2_github.com.openembedded.bitbake.git.tar.gz"
+
+        self.d.setVar('BB_GENERATE_MIRROR_TARBALLS', '1')
+        self.d.setVar('SRCREV', '82ea737a0b42a8b53e11c9cde141e9e9c0bd8c40')
+
+    def setup_mirror_rewrite(self):
+        self.d.setVar("PREMIRRORS", self.recipe_url + " " + self.mirror_url + " \n")
+
+    @skipIfNoNetwork()
+    def test_that_the_recipe_tarball_is_created_when_no_mirroring_is_used(self):
+        fetcher = bb.fetch.Fetch([self.recipe_url], self.d)
+
+        fetcher.download()
+
+        dir = os.listdir(self.dldir)
+        self.assertIn(self.recipe_tarball, dir)
+
+    @skipIfNoNetwork()
+    def test_that_the_mirror_tarball_is_created_when_mirroring_is_used(self):
+        self.setup_mirror_rewrite()
+        fetcher = bb.fetch.Fetch([self.recipe_url], self.d)
+
+        fetcher.download()
+
+        dir = os.listdir(self.dldir)
+        self.assertIn(self.mirror_tarball, dir)
+
+
+class GitShallowTarballNamingTest(FetcherTest):
+    def setUp(self):
+        super(GitShallowTarballNamingTest, self).setUp()
+        self.recipe_url = "git://git.openembedded.org/bitbake"
+        self.recipe_tarball = "gitshallow_git.openembedded.org.bitbake_82ea737-1_master.tar.gz"
+        self.mirror_url = "git://github.com/openembedded/bitbake.git"
+        self.mirror_tarball = "gitshallow_github.com.openembedded.bitbake.git_82ea737-1_master.tar.gz"
+
+        self.d.setVar('BB_GIT_SHALLOW', '1')
+        self.d.setVar('BB_GENERATE_SHALLOW_TARBALLS', '1')
+        self.d.setVar('SRCREV', '82ea737a0b42a8b53e11c9cde141e9e9c0bd8c40')
+
+    def setup_mirror_rewrite(self):
+        self.d.setVar("PREMIRRORS", self.recipe_url + " " + self.mirror_url + " \n")
+
+    @skipIfNoNetwork()
+    def test_that_the_tarball_is_named_after_recipe_url_when_no_mirroring_is_used(self):
+        fetcher = bb.fetch.Fetch([self.recipe_url], self.d)
+
+        fetcher.download()
+
+        dir = os.listdir(self.dldir)
+        self.assertIn(self.recipe_tarball, dir)
+
+    @skipIfNoNetwork()
+    def test_that_the_mirror_tarball_is_created_when_mirroring_is_used(self):
+        self.setup_mirror_rewrite()
+        fetcher = bb.fetch.Fetch([self.recipe_url], self.d)
+
+        fetcher.download()
+
+        dir = os.listdir(self.dldir)
+        self.assertIn(self.mirror_tarball, dir)
+
+
 class FetcherLocalTest(FetcherTest):
     def setUp(self):
         def touch(fn):
@@ -745,27 +869,27 @@
         self.assertRaises(bb.fetch.ParameterError, self.gitfetcher, url, url)
 
     @skipIfNoNetwork()
-    def test_gitfetch_premirror(self):
-        url1 = "git://git.openembedded.org/bitbake"
-        url2 = "git://someserver.org/bitbake"
+    def test_gitfetch_finds_local_tarball_for_mirrored_url_when_previous_downloaded_by_the_recipe_url(self):
+        recipeurl = "git://git.openembedded.org/bitbake"
+        mirrorurl = "git://someserver.org/bitbake"
         self.d.setVar("PREMIRRORS", "git://someserver.org/bitbake git://git.openembedded.org/bitbake \n")
-        self.gitfetcher(url1, url2)
+        self.gitfetcher(recipeurl, mirrorurl)
 
     @skipIfNoNetwork()
-    def test_gitfetch_premirror2(self):
-        url1 = url2 = "git://someserver.org/bitbake"
+    def test_gitfetch_finds_local_tarball_when_previous_downloaded_from_a_premirror(self):
+        recipeurl = "git://someserver.org/bitbake"
         self.d.setVar("PREMIRRORS", "git://someserver.org/bitbake git://git.openembedded.org/bitbake \n")
-        self.gitfetcher(url1, url2)
+        self.gitfetcher(recipeurl, recipeurl)
 
     @skipIfNoNetwork()
-    def test_gitfetch_premirror3(self):
+    def test_gitfetch_finds_local_repository_when_premirror_rewrites_the_recipe_url(self):
         realurl = "git://git.openembedded.org/bitbake"
-        dummyurl = "git://someserver.org/bitbake"
+        recipeurl = "git://someserver.org/bitbake"
         self.sourcedir = self.unpackdir.replace("unpacked", "sourcemirror.git")
         os.chdir(self.tempdir)
         bb.process.run("git clone %s %s 2> /dev/null" % (realurl, self.sourcedir), shell=True)
-        self.d.setVar("PREMIRRORS", "%s git://%s;protocol=file \n" % (dummyurl, self.sourcedir))
-        self.gitfetcher(dummyurl, dummyurl)
+        self.d.setVar("PREMIRRORS", "%s git://%s;protocol=file \n" % (recipeurl, self.sourcedir))
+        self.gitfetcher(recipeurl, recipeurl)
 
     @skipIfNoNetwork()
     def test_git_submodule(self):
@@ -832,7 +956,7 @@
     # decodeurl and we need to handle them
     decodedata = datatable.copy()
     decodedata.update({
-       "http://somesite.net;someparam=1": ('http', 'somesite.net', '', '', '', {'someparam': '1'}),
+       "http://somesite.net;someparam=1": ('http', 'somesite.net', '/', '', '', {'someparam': '1'}),
     })
 
     def test_decodeurl(self):
@@ -861,12 +985,12 @@
         ("dtc", "git://git.qemu.org/dtc.git", "65cc4d2748a2c2e6f27f1cf39e07a5dbabd80ebf", "")
             : "1.4.0",
         # combination version pattern
-        ("sysprof", "git://gitlab.gnome.org/GNOME/sysprof;protocol=https", "cd44ee6644c3641507fb53b8a2a69137f2971219", "")
+        ("sysprof", "git://gitlab.gnome.org/GNOME/sysprof.git;protocol=https", "cd44ee6644c3641507fb53b8a2a69137f2971219", "")
             : "1.2.0",
         ("u-boot-mkimage", "git://git.denx.de/u-boot.git;branch=master;protocol=git", "62c175fbb8a0f9a926c88294ea9f7e88eb898f6c", "")
             : "2014.01",
         # version pattern "yyyymmdd"
-        ("mobile-broadband-provider-info", "git://gitlab.gnome.org/GNOME/mobile-broadband-provider-info;protocol=https", "4ed19e11c2975105b71b956440acdb25d46a347d", "")
+        ("mobile-broadband-provider-info", "git://gitlab.gnome.org/GNOME/mobile-broadband-provider-info.git;protocol=https", "4ed19e11c2975105b71b956440acdb25d46a347d", "")
             : "20120614",
         # packages with a valid UPSTREAM_CHECK_GITTAGREGEX
         ("xf86-video-omap", "git://anongit.freedesktop.org/xorg/driver/xf86-video-omap", "ae0394e687f1a77e966cf72f895da91840dffb8f", "(?P<pver>(\d+\.(\d\.?)*))")
@@ -1338,6 +1462,9 @@
         smdir = os.path.join(self.tempdir, 'gitsubmodule')
         bb.utils.mkdirhier(smdir)
         self.git('init', cwd=smdir)
+        # Make this look like it was cloned from a remote...
+        self.git('config --add remote.origin.url "%s"' % smdir, cwd=smdir)
+        self.git('config --add remote.origin.fetch "+refs/heads/*:refs/remotes/origin/*"', cwd=smdir)
         self.add_empty_file('asub', cwd=smdir)
 
         self.git('submodule init', cwd=self.srcdir)
@@ -1571,3 +1698,29 @@
         self.assertNotEqual(orig_revs, revs)
         self.assertRefs(['master', 'origin/master'])
         self.assertRevCount(orig_revs - 1758)
+
+    def test_that_unpack_throws_an_error_when_the_git_clone_nor_shallow_tarball_exist(self):
+        self.add_empty_file('a')
+        fetcher, ud = self.fetch()
+        bb.utils.remove(self.gitdir, recurse=True)
+        bb.utils.remove(self.dldir, recurse=True)
+
+        with self.assertRaises(bb.fetch2.UnpackError) as context:
+            fetcher.unpack(self.d.getVar('WORKDIR'))
+
+        self.assertIn("No up to date source found", context.exception.msg)
+        self.assertIn("clone directory not available or not up to date", context.exception.msg)
+
+    @skipIfNoNetwork()
+    def test_that_unpack_does_work_when_using_git_shallow_tarball_but_tarball_is_not_available(self):
+        self.d.setVar('SRCREV', 'e5939ff608b95cdd4d0ab0e1935781ab9a276ac0')
+        self.d.setVar('BB_GIT_SHALLOW', '1')
+        self.d.setVar('BB_GENERATE_SHALLOW_TARBALLS', '1')
+        fetcher = bb.fetch.Fetch(["git://git.yoctoproject.org/fstests"], self.d)
+        fetcher.download()
+
+        bb.utils.remove(self.dldir + "/*.tar.gz")
+        fetcher.unpack(self.unpackdir)
+
+        dir = os.listdir(self.unpackdir + "/git/")
+        self.assertIn("fstests.doap", dir)
diff --git a/poky/bitbake/lib/bb/tests/parse.py b/poky/bitbake/lib/bb/tests/parse.py
index 8f16ba4..1bc4740 100644
--- a/poky/bitbake/lib/bb/tests/parse.py
+++ b/poky/bitbake/lib/bb/tests/parse.py
@@ -44,9 +44,13 @@
 """
 
     def setUp(self):
+        self.origdir = os.getcwd()
         self.d = bb.data.init()
         bb.parse.siggen = bb.siggen.init(self.d)
 
+    def tearDown(self):
+        os.chdir(self.origdir)
+
     def parsehelper(self, content, suffix = ".bb"):
 
         f = tempfile.NamedTemporaryFile(suffix = suffix)
diff --git a/poky/bitbake/lib/bb/ui/buildinfohelper.py b/poky/bitbake/lib/bb/ui/buildinfohelper.py
index 524a5b0..31323d2 100644
--- a/poky/bitbake/lib/bb/ui/buildinfohelper.py
+++ b/poky/bitbake/lib/bb/ui/buildinfohelper.py
@@ -1603,14 +1603,14 @@
         mockevent.lineno = -1
         self.store_log_event(mockevent)
 
-    def store_log_event(self, event):
+    def store_log_event(self, event,cli_backlog=True):
         self._ensure_build()
 
         if event.levelno < formatter.WARNING:
             return
 
         # early return for CLI builds
-        if self.brbe is None:
+        if cli_backlog and self.brbe is None:
             if not 'backlog' in self.internal_state:
                 self.internal_state['backlog'] = []
             self.internal_state['backlog'].append(event)
@@ -1622,7 +1622,7 @@
                 tempevent = self.internal_state['backlog'].pop()
                 logger.debug(1, "buildinfohelper: Saving stored event %s "
                              % tempevent)
-                self.store_log_event(tempevent)
+                self.store_log_event(tempevent,cli_backlog)
             else:
                 logger.info("buildinfohelper: All events saved")
                 del self.internal_state['backlog']
@@ -1987,7 +1987,8 @@
         if 'backlog' in self.internal_state:
             # we save missed events in the database for the current build
             tempevent = self.internal_state['backlog'].pop()
-            self.store_log_event(tempevent)
+            # Do not skip command line build events
+            self.store_log_event(tempevent,False)
 
         if not connection.features.autocommits_when_autocommit_is_off:
             transaction.set_autocommit(True)
diff --git a/poky/bitbake/lib/bb/ui/taskexp.py b/poky/bitbake/lib/bb/ui/taskexp.py
index 0e8e9d4..8305d70 100644
--- a/poky/bitbake/lib/bb/ui/taskexp.py
+++ b/poky/bitbake/lib/bb/ui/taskexp.py
@@ -103,9 +103,16 @@
         self.pkg_treeview.get_selection().connect("changed", self.on_cursor_changed)
         column = Gtk.TreeViewColumn("Package", Gtk.CellRendererText(), text=COL_PKG_NAME)
         self.pkg_treeview.append_column(column)
-        pane.add1(scrolled)
         scrolled.add(self.pkg_treeview)
 
+        self.search_entry = Gtk.SearchEntry.new()
+        self.pkg_treeview.set_search_entry(self.search_entry)
+
+        left_panel = Gtk.VPaned()
+        left_panel.add(self.search_entry)
+        left_panel.add(scrolled)
+        pane.add1(left_panel)
+
         box = Gtk.VBox(homogeneous=True, spacing=4)
 
         # Task Depends
@@ -129,6 +136,7 @@
         pane.add2(box)
 
         self.show_all()
+        self.search_entry.grab_focus()
 
     def on_package_activated(self, treeview, path, column, data_col):
         model = treeview.get_model()
diff --git a/poky/bitbake/lib/bb/utils.py b/poky/bitbake/lib/bb/utils.py
index 2ff7e82..73b6cb4 100644
--- a/poky/bitbake/lib/bb/utils.py
+++ b/poky/bitbake/lib/bb/utils.py
@@ -497,7 +497,11 @@
                 if statinfo.st_ino == statinfo2.st_ino:
                     return lf
             lf.close()
-        except Exception:
+        except OSError as e:
+            if e.errno == errno.EACCES:
+                logger.error("Unable to acquire lock '%s', %s",
+                             e.strerror, name)
+                sys.exit(1)
             try:
                 lf.close()
             except Exception:
@@ -906,6 +910,23 @@
         newmtime = sstat[stat.ST_MTIME]
     return newmtime
 
+def break_hardlinks(src, sstat = None):
+    """
+    Ensures src is the only hardlink to this file.  Other hardlinks,
+    if any, are not affected (other than in their st_nlink value, of
+    course).  Returns true on success and false on failure.
+
+    """
+    try:
+        if not sstat:
+            sstat = os.lstat(src)
+    except Exception as e:
+        logger.warning("break_hardlinks: stat of %s failed (%s)" % (src, e))
+        return False
+    if sstat[stat.ST_NLINK] == 1:
+        return True
+    return copyfile(src, src, sstat=sstat)
+
 def which(path, item, direction = 0, history = False, executable=False):
     """
     Locate `item` in the list of paths `path` (colon separated string like $PATH).
@@ -1290,7 +1311,7 @@
     return updated
 
 
-def edit_bblayers_conf(bblayers_conf, add, remove):
+def edit_bblayers_conf(bblayers_conf, add, remove, edit_cb=None):
     """Edit bblayers.conf, adding and/or removing layers
     Parameters:
         bblayers_conf: path to bblayers.conf file to edit
@@ -1298,6 +1319,8 @@
             list to add nothing
         remove: layer path (or list of layer paths) to remove; None or
             empty list to remove nothing
+        edit_cb: optional callback function that will be called after
+            processing adds/removes once per existing entry.
     Returns a tuple:
         notadded: list of layers specified to be added but weren't
             (because they were already in the list)
@@ -1361,6 +1384,17 @@
                     bblayers.append(addlayer)
             del addlayers[:]
 
+        if edit_cb:
+            newlist = []
+            for layer in bblayers:
+                res = edit_cb(layer, canonicalise_path(layer))
+                if res != layer:
+                    newlist.append(res)
+                    updated = True
+                else:
+                    newlist.append(layer)
+            bblayers = newlist
+
         if updated:
             if op == '+=' and not bblayers:
                 bblayers = None
diff --git a/poky/bitbake/lib/bblayers/action.py b/poky/bitbake/lib/bblayers/action.py
index aa575d1..a3f658f 100644
--- a/poky/bitbake/lib/bblayers/action.py
+++ b/poky/bitbake/lib/bblayers/action.py
@@ -45,7 +45,7 @@
             notadded, _ = bb.utils.edit_bblayers_conf(bblayers_conf, layerdirs, None)
             if not (args.force or notadded):
                 try:
-                    self.tinfoil.parseRecipes()
+                    self.tinfoil.run_command('parseConfiguration')
                 except bb.tinfoil.TinfoilUIException:
                     # Restore the back up copy of bblayers.conf
                     shutil.copy2(backup, bblayers_conf)
diff --git a/poky/bitbake/lib/bblayers/layerindex.py b/poky/bitbake/lib/bblayers/layerindex.py
index 9af385d..9f02a9d 100644
--- a/poky/bitbake/lib/bblayers/layerindex.py
+++ b/poky/bitbake/lib/bblayers/layerindex.py
@@ -1,10 +1,9 @@
+import layerindexlib
+
 import argparse
-import http.client
-import json
 import logging
 import os
 import subprocess
-import urllib.parse
 
 from bblayers.action import ActionPlugin
 
@@ -21,110 +20,6 @@
     This class inherits ActionPlugin to get do_add_layer.
     """
 
-    def get_json_data(self, apiurl):
-        proxy_settings = os.environ.get("http_proxy", None)
-        conn = None
-        _parsedurl = urllib.parse.urlparse(apiurl)
-        path = _parsedurl.path
-        query = _parsedurl.query
-
-        def parse_url(url):
-            parsedurl = urllib.parse.urlparse(url)
-            if parsedurl.netloc[0] == '[':
-                host, port = parsedurl.netloc[1:].split(']', 1)
-                if ':' in port:
-                    port = port.rsplit(':', 1)[1]
-                else:
-                    port = None
-            else:
-                if parsedurl.netloc.count(':') == 1:
-                    (host, port) = parsedurl.netloc.split(":")
-                else:
-                    host = parsedurl.netloc
-                    port = None
-            return (host, 80 if port is None else int(port))
-
-        if proxy_settings is None:
-            host, port = parse_url(apiurl)
-            conn = http.client.HTTPConnection(host, port)
-            conn.request("GET", path + "?" + query)
-        else:
-            host, port = parse_url(proxy_settings)
-            conn = http.client.HTTPConnection(host, port)
-            conn.request("GET", apiurl)
-
-        r = conn.getresponse()
-        if r.status != 200:
-            raise Exception("Failed to read " + path + ": %d %s" % (r.status, r.reason))
-        return json.loads(r.read().decode())
-
-    def get_layer_deps(self, layername, layeritems, layerbranches, layerdependencies, branchnum, selfname=False):
-        def layeritems_info_id(items_name, layeritems):
-            litems_id = None
-            for li in layeritems:
-                if li['name'] == items_name:
-                    litems_id = li['id']
-                    break
-            return litems_id
-
-        def layerbranches_info(items_id, layerbranches):
-            lbranch = {}
-            for lb in layerbranches:
-                if lb['layer'] == items_id and lb['branch'] == branchnum:
-                    lbranch['id'] = lb['id']
-                    lbranch['vcs_subdir'] = lb['vcs_subdir']
-                    break
-            return lbranch
-
-        def layerdependencies_info(lb_id, layerdependencies):
-            ld_deps = []
-            for ld in layerdependencies:
-                if ld['layerbranch'] == lb_id and not ld['dependency'] in ld_deps:
-                    ld_deps.append(ld['dependency'])
-            if not ld_deps:
-                logger.error("The dependency of layerDependencies is not found.")
-            return ld_deps
-
-        def layeritems_info_name_subdir(items_id, layeritems):
-            litems = {}
-            for li in layeritems:
-                if li['id'] == items_id:
-                    litems['vcs_url'] = li['vcs_url']
-                    litems['name'] = li['name']
-                    break
-            return litems
-
-        if selfname:
-            selfid = layeritems_info_id(layername, layeritems)
-            lbinfo = layerbranches_info(selfid, layerbranches)
-            if lbinfo:
-                selfsubdir = lbinfo['vcs_subdir']
-            else:
-                logger.error("%s is not found in the specified branch" % layername)
-                return
-            selfurl = layeritems_info_name_subdir(selfid, layeritems)['vcs_url']
-            if selfurl:
-                return selfurl, selfsubdir
-            else:
-                logger.error("Cannot get layer %s git repo and subdir" % layername)
-                return
-        ldict = {}
-        itemsid = layeritems_info_id(layername, layeritems)
-        if not itemsid:
-            return layername, None
-        lbid = layerbranches_info(itemsid, layerbranches)
-        if lbid:
-            lbid = layerbranches_info(itemsid, layerbranches)['id']
-        else:
-            logger.error("%s is not found in the specified branch" % layername)
-            return None, None
-        for dependency in layerdependencies_info(lbid, layerdependencies):
-            lname = layeritems_info_name_subdir(dependency, layeritems)['name']
-            lurl = layeritems_info_name_subdir(dependency, layeritems)['vcs_url']
-            lsubdir = layerbranches_info(dependency, layerbranches)['vcs_subdir']
-            ldict[lname] = lurl, lsubdir
-        return None, ldict
-
     def get_fetch_layer(self, fetchdir, url, subdir, fetch_layer):
         layername = self.get_layer_name(url)
         if os.path.splitext(layername)[1] == '.git':
@@ -136,95 +31,124 @@
                 result = subprocess.call('git clone %s %s' % (url, repodir), shell = True)
                 if result:
                     logger.error("Failed to download %s" % url)
-                    return None, None
+                    return None, None, None
                 else:
-                    return layername, layerdir
+                    return subdir, layername, layerdir
             else:
                 logger.plain("Repository %s needs to be fetched" % url)
-                return layername, layerdir
+                return subdir, layername, layerdir
         elif os.path.exists(layerdir):
-            return layername, layerdir
+            return subdir, layername, layerdir
         else:
             logger.error("%s is not in %s" % (url, subdir))
-        return None, None
+        return None, None, None
 
     def do_layerindex_fetch(self, args):
         """Fetches a layer from a layer index along with its dependent layers, and adds them to conf/bblayers.conf.
 """
-        apiurl = self.tinfoil.config_data.getVar('BBLAYERS_LAYERINDEX_URL')
-        if not apiurl:
-            logger.error("Cannot get BBLAYERS_LAYERINDEX_URL")
-            return 1
-        else:
-            if apiurl[-1] != '/':
-                apiurl += '/'
-            apiurl += "api/"
-        apilinks = self.get_json_data(apiurl)
-        branches = self.get_json_data(apilinks['branches'])
 
-        branchnum = 0
-        for branch in branches:
-            if branch['name'] == args.branch:
-                branchnum = branch['id']
-                break
-        if branchnum == 0:
-            validbranches = ', '.join([branch['name'] for branch in branches])
-            logger.error('Invalid layer branch name "%s". Valid branches: %s' % (args.branch, validbranches))
-            return 1
+        def _construct_url(baseurls, branches):
+            urls = []
+            for baseurl in baseurls:
+                if baseurl[-1] != '/':
+                    baseurl += '/'
+
+                if not baseurl.startswith('cooker'):
+                    baseurl += "api/"
+
+                if branches:
+                    baseurl += ";branch=%s" % ','.join(branches)
+
+                urls.append(baseurl)
+
+            return urls
+
+
+        # Set the default...
+        if args.branch:
+            branches = [args.branch]
+        else:
+            branches = (self.tinfoil.config_data.getVar('LAYERSERIES_CORENAMES') or 'master').split()
+        logger.debug(1, 'Trying branches: %s' % branches)
 
         ignore_layers = []
-        for collection in self.tinfoil.config_data.getVar('BBFILE_COLLECTIONS').split():
-            lname = self.tinfoil.config_data.getVar('BBLAYERS_LAYERINDEX_NAME_%s' % collection)
-            if lname:
-                ignore_layers.append(lname)
-
         if args.ignore:
             ignore_layers.extend(args.ignore.split(','))
 
-        layeritems = self.get_json_data(apilinks['layerItems'])
-        layerbranches = self.get_json_data(apilinks['layerBranches'])
-        layerdependencies = self.get_json_data(apilinks['layerDependencies'])
-        invaluenames = []
-        repourls = {}
-        printlayers = []
+        # Load the cooker DB
+        cookerIndex = layerindexlib.LayerIndex(self.tinfoil.config_data)
+        cookerIndex.load_layerindex('cooker://', load='layerDependencies')
 
-        def query_dependencies(layers, layeritems, layerbranches, layerdependencies, branchnum):
-            depslayer = []
-            for layername in layers:
-                invaluename, layerdict = self.get_layer_deps(layername, layeritems, layerbranches, layerdependencies, branchnum)
-                if layerdict:
-                    repourls[layername] = self.get_layer_deps(layername, layeritems, layerbranches, layerdependencies, branchnum, selfname=True)
-                    for layer in layerdict:
-                        if not layer in ignore_layers:
-                            depslayer.append(layer)
-                        printlayers.append((layername, layer, layerdict[layer][0], layerdict[layer][1]))
-                        if not layer in ignore_layers and not layer in repourls:
-                            repourls[layer] = (layerdict[layer][0], layerdict[layer][1])
-                if invaluename and not invaluename in invaluenames:
-                    invaluenames.append(invaluename)
-            return depslayer
+        # Fast path, check if we already have what has been requested!
+        (dependencies, invalidnames) = cookerIndex.find_dependencies(names=args.layername, ignores=ignore_layers)
+        if not args.show_only and not invalidnames:
+            logger.plain("You already have the requested layer(s): %s" % args.layername)
+            return 0
 
-        depslayers = query_dependencies(args.layername, layeritems, layerbranches, layerdependencies, branchnum)
-        while depslayers:
-            depslayer = query_dependencies(depslayers, layeritems, layerbranches, layerdependencies, branchnum)
-            depslayers = depslayer
-        if invaluenames:
-            for invaluename in invaluenames:
-                logger.error('Layer "%s" not found in layer index' % invaluename)
-            return 1
-        logger.plain("%s  %s  %s  %s" % ("Layer".ljust(19), "Required by".ljust(19), "Git repository".ljust(54), "Subdirectory"))
-        logger.plain('=' * 115)
-        for layername in args.layername:
-            layerurl = repourls[layername]
-            logger.plain("%s %s %s %s" % (layername.ljust(20), '-'.ljust(20), layerurl[0].ljust(55), layerurl[1]))
-        printedlayers = []
-        for layer, dependency, gitrepo, subdirectory in printlayers:
-            if dependency in printedlayers:
-                continue
-            logger.plain("%s %s %s %s" % (dependency.ljust(20), layer.ljust(20), gitrepo.ljust(55), subdirectory))
-            printedlayers.append(dependency)
+        # The information to show is already in the cookerIndex
+        if invalidnames:
+            # General URL to use to access the layer index
+            # While there is ONE right now, we're expect users could enter several
+            apiurl = self.tinfoil.config_data.getVar('BBLAYERS_LAYERINDEX_URL').split()
+            if not apiurl:
+                logger.error("Cannot get BBLAYERS_LAYERINDEX_URL")
+                return 1
 
-        if repourls:
+            remoteIndex = layerindexlib.LayerIndex(self.tinfoil.config_data)
+
+            for remoteurl in _construct_url(apiurl, branches):
+                logger.plain("Loading %s..." % remoteurl)
+                remoteIndex.load_layerindex(remoteurl)
+
+            if remoteIndex.is_empty():
+                logger.error("Remote layer index %s is empty for branches %s" % (apiurl, branches))
+                return 1
+
+            lIndex = cookerIndex + remoteIndex
+
+            (dependencies, invalidnames) = lIndex.find_dependencies(names=args.layername, ignores=ignore_layers)
+
+            if invalidnames:
+                for invaluename in invalidnames:
+                    logger.error('Layer "%s" not found in layer index' % invaluename)
+                return 1
+
+        logger.plain("%s  %s  %s" % ("Layer".ljust(49), "Git repository (branch)".ljust(54), "Subdirectory"))
+        logger.plain('=' * 125)
+
+        for deplayerbranch in dependencies:
+            layerBranch = dependencies[deplayerbranch][0]
+
+            # TODO: Determine display behavior
+            # This is the local content, uncomment to hide local
+            # layers from the display.
+            #if layerBranch.index.config['TYPE'] == 'cooker':
+            #    continue
+
+            layerDeps = dependencies[deplayerbranch][1:]
+
+            requiredby = []
+            recommendedby = []
+            for dep in layerDeps:
+                if dep.required:
+                    requiredby.append(dep.layer.name)
+                else:
+                    recommendedby.append(dep.layer.name)
+
+            logger.plain('%s %s %s' % (("%s:%s:%s" %
+                                  (layerBranch.index.config['DESCRIPTION'],
+                                  layerBranch.branch.name,
+                                  layerBranch.layer.name)).ljust(50),
+                                  ("%s (%s)" % (layerBranch.layer.vcs_url,
+                                  layerBranch.actual_branch)).ljust(55),
+                                  layerBranch.vcs_subdir
+                                               ))
+            if requiredby:
+                logger.plain('  required by: %s' % ' '.join(requiredby))
+            if recommendedby:
+                logger.plain('  recommended by: %s' % ' '.join(recommendedby))
+
+        if dependencies:
             fetchdir = self.tinfoil.config_data.getVar('BBLAYERS_FETCH_DIR')
             if not fetchdir:
                 logger.error("Cannot get BBLAYERS_FETCH_DIR")
@@ -232,26 +156,39 @@
             if not os.path.exists(fetchdir):
                 os.makedirs(fetchdir)
             addlayers = []
-            for repourl, subdir in repourls.values():
-                name, layerdir = self.get_fetch_layer(fetchdir, repourl, subdir, not args.show_only)
+
+            for deplayerbranch in dependencies:
+                layerBranch = dependencies[deplayerbranch][0]
+
+                if layerBranch.index.config['TYPE'] == 'cooker':
+                    # Anything loaded via cooker is already local, skip it
+                    continue
+
+                subdir, name, layerdir = self.get_fetch_layer(fetchdir,
+                                                      layerBranch.layer.vcs_url,
+                                                      layerBranch.vcs_subdir,
+                                                      not args.show_only)
                 if not name:
                     # Error already shown
                     return 1
                 addlayers.append((subdir, name, layerdir))
         if not args.show_only:
-            for subdir, name, layerdir in set(addlayers):
+            localargs = argparse.Namespace()
+            localargs.layerdir = []
+            localargs.force = args.force
+            for subdir, name, layerdir in addlayers:
                 if os.path.exists(layerdir):
                     if subdir:
-                        logger.plain("Adding layer \"%s\" to conf/bblayers.conf" % subdir)
+                        logger.plain("Adding layer \"%s\" (%s) to conf/bblayers.conf" % (subdir, layerdir))
                     else:
-                        logger.plain("Adding layer \"%s\" to conf/bblayers.conf" % name)
-                    localargs = argparse.Namespace()
-                    localargs.layerdir = layerdir
-                    localargs.force = args.force
-                    self.do_add_layer(localargs)
+                        logger.plain("Adding layer \"%s\" (%s) to conf/bblayers.conf" % (name, layerdir))
+                    localargs.layerdir.append(layerdir)
                 else:
                     break
 
+            if localargs.layerdir:
+                self.do_add_layer(localargs)
+
     def do_layerindex_show_depends(self, args):
         """Find layer dependencies from layer index.
 """
@@ -260,12 +197,12 @@
         self.do_layerindex_fetch(args)
 
     def register_commands(self, sp):
-        parser_layerindex_fetch = self.add_command(sp, 'layerindex-fetch', self.do_layerindex_fetch)
+        parser_layerindex_fetch = self.add_command(sp, 'layerindex-fetch', self.do_layerindex_fetch, parserecipes=False)
         parser_layerindex_fetch.add_argument('-n', '--show-only', help='show dependencies and do nothing else', action='store_true')
-        parser_layerindex_fetch.add_argument('-b', '--branch', help='branch name to fetch (default %(default)s)', default='master')
+        parser_layerindex_fetch.add_argument('-b', '--branch', help='branch name to fetch')
         parser_layerindex_fetch.add_argument('-i', '--ignore', help='assume the specified layers do not need to be fetched/added (separate multiple layers with commas, no spaces)', metavar='LAYER')
         parser_layerindex_fetch.add_argument('layername', nargs='+', help='layer to fetch')
 
-        parser_layerindex_show_depends = self.add_command(sp, 'layerindex-show-depends', self.do_layerindex_show_depends)
-        parser_layerindex_show_depends.add_argument('-b', '--branch', help='branch name to fetch (default %(default)s)', default='master')
+        parser_layerindex_show_depends = self.add_command(sp, 'layerindex-show-depends', self.do_layerindex_show_depends, parserecipes=False)
+        parser_layerindex_show_depends.add_argument('-b', '--branch', help='branch name to fetch')
         parser_layerindex_show_depends.add_argument('layername', nargs='+', help='layer to query')
diff --git a/poky/bitbake/lib/layerindexlib/README b/poky/bitbake/lib/layerindexlib/README
new file mode 100644
index 0000000..5d927af
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/README
@@ -0,0 +1,28 @@
+The layerindexlib module is designed to permit programs to work directly
+with layer index information.  (See layers.openembedded.org...)
+
+The layerindexlib module includes a plugin interface that is used to extend
+the basic functionality.  There are two primary plugins available: restapi
+and cooker.
+
+The restapi plugin works with a web based REST Api compatible with the
+layerindex-web project, as well as the ability to store and retried a
+the information for one or more files on the disk.
+
+The cooker plugin works by reading the information from the current build
+project and processing it as if it were a layer index.
+
+
+TODO:
+
+__init__.py:
+Implement local on-disk caching (using the rest api store/load)
+Implement layer index style query operations on a combined index
+
+common.py:
+Stop network access if BB_NO_NETWORK or allowed hosts is restricted
+
+cooker.py:
+Cooker - Implement recipe parsing
+
+
diff --git a/poky/bitbake/lib/layerindexlib/__init__.py b/poky/bitbake/lib/layerindexlib/__init__.py
new file mode 100644
index 0000000..cb79cb3
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/__init__.py
@@ -0,0 +1,1363 @@
+# Copyright (C) 2016-2018 Wind River Systems, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License version 2 as
+# published by the Free Software Foundation.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+import datetime
+
+import logging
+import imp
+
+from collections import OrderedDict
+from layerindexlib.plugin import LayerIndexPluginUrlError
+
+logger = logging.getLogger('BitBake.layerindexlib')
+
+# Exceptions
+
+class LayerIndexException(Exception):
+    '''LayerIndex Generic Exception'''
+    def __init__(self, message):
+         self.msg = message
+         Exception.__init__(self, message)
+
+    def __str__(self):
+         return self.msg
+
+class LayerIndexUrlError(LayerIndexException):
+    '''Exception raised when unable to access a URL for some reason'''
+    def __init__(self, url, message=""):
+        if message:
+            msg = "Unable to access layerindex url %s: %s" % (url, message)
+        else:
+            msg = "Unable to access layerindex url %s" % url
+        self.url = url
+        LayerIndexException.__init__(self, msg)
+
+class LayerIndexFetchError(LayerIndexException):
+    '''General layerindex fetcher exception when something fails'''
+    def __init__(self, url, message=""):
+        if message:
+            msg = "Unable to fetch layerindex url %s: %s" % (url, message)
+        else:
+            msg = "Unable to fetch layerindex url %s" % url
+        self.url = url
+        LayerIndexException.__init__(self, msg)
+
+
+# Interface to the overall layerindex system
+# the layer may contain one or more individual indexes
+class LayerIndex():
+    def __init__(self, d):
+        if not d:
+            raise LayerIndexException("Must be initialized with bb.data.")
+
+        self.data = d
+
+        # List of LayerIndexObj
+        self.indexes = []
+
+        self.plugins = []
+
+        import bb.utils
+        bb.utils.load_plugins(logger, self.plugins, os.path.dirname(__file__))
+        for plugin in self.plugins:
+            if hasattr(plugin, 'init'):
+                plugin.init(self)
+
+    def __add__(self, other):
+        newIndex = LayerIndex(self.data)
+
+        if self.__class__ != newIndex.__class__ or \
+           other.__class__ != newIndex.__class__:
+            raise TypeException("Can not add different types.")
+
+        for indexEnt in self.indexes:
+            newIndex.indexes.append(indexEnt)
+
+        for indexEnt in other.indexes:
+            newIndex.indexes.append(indexEnt)
+
+        return newIndex
+
+    def _parse_params(self, params):
+        '''Take a parameter list, return a dictionary of parameters.
+
+           Expected to be called from the data of urllib.parse.urlparse(url).params
+
+           If there are two conflicting parameters, last in wins...
+        '''
+
+        param_dict = {}
+        for param in params.split(';'):
+           if not param:
+               continue
+           item = param.split('=', 1)
+           logger.debug(1, item)
+           param_dict[item[0]] = item[1]
+
+        return param_dict
+
+    def _fetch_url(self, url, username=None, password=None, debuglevel=0):
+        '''Fetch data from a specific URL.
+
+           Fetch something from a specific URL.  This is specifically designed to
+           fetch data from a layerindex-web instance, but may be useful for other
+           raw fetch actions.
+
+           It is not designed to be used to fetch recipe sources or similar.  the
+           regular fetcher class should used for that.
+
+           It is the responsibility of the caller to check BB_NO_NETWORK and related
+           BB_ALLOWED_NETWORKS.
+        '''
+
+        if not url:
+            raise LayerIndexUrlError(url, "empty url")
+
+        import urllib
+        from urllib.request import urlopen, Request
+        from urllib.parse import urlparse
+
+        up = urlparse(url)
+
+        if username:
+            logger.debug(1, "Configuring authentication for %s..." % url)
+            password_mgr = urllib.request.HTTPPasswordMgrWithDefaultRealm()
+            password_mgr.add_password(None, "%s://%s" % (up.scheme, up.netloc), username, password)
+            handler = urllib.request.HTTPBasicAuthHandler(password_mgr)
+            opener = urllib.request.build_opener(handler, urllib.request.HTTPSHandler(debuglevel=debuglevel))
+        else:
+            opener = urllib.request.build_opener(urllib.request.HTTPSHandler(debuglevel=debuglevel))
+
+        urllib.request.install_opener(opener)
+
+        logger.debug(1, "Fetching %s (%s)..." % (url, ["without authentication", "with authentication"][bool(username)]))
+
+        try:
+            res = urlopen(Request(url, headers={'User-Agent': 'Mozilla/5.0 (bitbake/lib/layerindex)'}, unverifiable=True))
+        except urllib.error.HTTPError as e:
+            logger.debug(1, "HTTP Error: %s: %s" % (e.code, e.reason))
+            logger.debug(1, " Requested: %s" % (url))
+            logger.debug(1, " Actual:    %s" % (e.geturl()))
+
+            if e.code == 404:
+                logger.debug(1, "Request not found.")
+                raise LayerIndexFetchError(url, e)
+            else:
+                logger.debug(1, "Headers:\n%s" % (e.headers))
+                raise LayerIndexFetchError(url, e)
+        except OSError as e:
+            error = 0
+            reason = ""
+
+            # Process base OSError first...
+            if hasattr(e, 'errno'):
+                error = e.errno
+                reason = e.strerror
+
+            # Process gaierror (socket error) subclass if available.
+            if hasattr(e, 'reason') and hasattr(e.reason, 'errno') and hasattr(e.reason, 'strerror'):
+                error = e.reason.errno
+                reason = e.reason.strerror
+                if error == -2:
+                    raise LayerIndexFetchError(url, "%s: %s" % (e, reason))
+
+            if error and error != 0:
+                raise LayerIndexFetchError(url, "Unexpected exception: [Error %s] %s" % (error, reason))
+            else:
+                raise LayerIndexFetchError(url, "Unable to fetch OSError exception: %s" % e)
+
+        finally:
+            logger.debug(1, "...fetching %s (%s), done." % (url, ["without authentication", "with authentication"][bool(username)]))
+
+        return res
+
+
+    def load_layerindex(self, indexURI, load=['layerDependencies', 'recipes', 'machines', 'distros'], reload=False):
+        '''Load the layerindex.
+
+           indexURI - An index to load.  (Use multiple calls to load multiple indexes)
+           
+           reload - If reload is True, then any previously loaded indexes will be forgotten.
+           
+           load - List of elements to load.  Default loads all items.
+                  Note: plugs may ignore this.
+
+The format of the indexURI:
+
+  <url>;branch=<branch>;cache=<cache>;desc=<description>
+
+  Note: the 'branch' parameter if set can select multiple branches by using
+  comma, such as 'branch=master,morty,pyro'.  However, many operations only look
+  at the -first- branch specified!
+
+  The cache value may be undefined, in this case a network failure will
+  result in an error, otherwise the system will look for a file of the cache
+  name and load that instead.
+
+  For example:
+
+  http://layers.openembedded.org/layerindex/api/;branch=master;desc=OpenEmbedded%20Layer%20Index
+  cooker://
+'''
+        if reload:
+            self.indexes = []
+
+        logger.debug(1, 'Loading: %s' % indexURI)
+
+        if not self.plugins:
+            raise LayerIndexException("No LayerIndex Plugins available")
+
+        for plugin in self.plugins:
+            # Check if the plugin was initialized
+            logger.debug(1, 'Trying %s' % plugin.__class__)
+            if not hasattr(plugin, 'type') or not plugin.type:
+                continue
+            try:
+                # TODO: Implement 'cache', for when the network is not available
+                indexEnt = plugin.load_index(indexURI, load)
+                break
+            except LayerIndexPluginUrlError as e:
+                logger.debug(1, "%s doesn't support %s" % (plugin.type, e.url))
+            except NotImplementedError:
+                pass
+        else:
+            logger.debug(1, "No plugins support %s" % indexURI)
+            raise LayerIndexException("No plugins support %s" % indexURI)
+
+        # Mark CONFIG data as something we've added...
+        indexEnt.config['local'] = []
+        indexEnt.config['local'].append('config')
+
+        # No longer permit changes..
+        indexEnt.lockData()
+
+        self.indexes.append(indexEnt)
+
+    def store_layerindex(self, indexURI, index=None):
+        '''Store one layerindex
+
+Typically this will be used to create a local cache file of a remote index.
+
+  file://<path>;branch=<branch>
+
+We can write out in either the restapi or django formats.  The split option
+will write out the individual elements split by layer and related components.
+'''
+        if not index:
+            logger.warning('No index to write, nothing to do.')
+            return
+
+        if not self.plugins:
+            raise LayerIndexException("No LayerIndex Plugins available")
+
+        for plugin in self.plugins:
+            # Check if the plugin was initialized
+            logger.debug(1, 'Trying %s' % plugin.__class__)
+            if not hasattr(plugin, 'type') or not plugin.type:
+                continue
+            try:
+                plugin.store_index(indexURI, index)
+                break
+            except LayerIndexPluginUrlError as e:
+                logger.debug(1, "%s doesn't support %s" % (plugin.type, e.url))
+            except NotImplementedError:
+                logger.debug(1, "Store not implemented in %s" % plugin.type)
+                pass
+        else:
+            logger.debug(1, "No plugins support %s" % url)
+            raise LayerIndexException("No plugins support %s" % url)
+
+
+    def is_empty(self):
+        '''Return True or False if the index has any usable data.
+
+We check the indexes entries to see if they have a branch set, as well as
+layerBranches set.  If not, they are effectively blank.'''
+
+        found = False
+        for index in self.indexes:
+            if index.__bool__():
+                found = True
+                break
+        return not found
+
+
+    def find_vcs_url(self, vcs_url, branch=None):
+        '''Return the first layerBranch with the given vcs_url
+
+           If a branch has not been specified, we will iterate over the branches in
+           the default configuration until the first vcs_url/branch match.'''
+
+        for index in self.indexes:
+            logger.debug(1, ' searching %s' % index.config['DESCRIPTION'])
+            layerBranch = index.find_vcs_url(vcs_url, [branch])
+            if layerBranch:
+                return layerBranch
+        return None
+
+    def find_collection(self, collection, version=None, branch=None):
+        '''Return the first layerBranch with the given collection name
+
+           If a branch has not been specified, we will iterate over the branches in
+           the default configuration until the first collection/branch match.'''
+
+        logger.debug(1, 'find_collection: %s (%s) %s' % (collection, version, branch))
+
+        if branch:
+            branches = [branch]
+        else:
+            branches = None
+
+        for index in self.indexes:
+            logger.debug(1, ' searching %s' % index.config['DESCRIPTION'])
+            layerBranch = index.find_collection(collection, version, branches)
+            if layerBranch:
+                return layerBranch
+        else:
+            logger.debug(1, 'Collection %s (%s) not found for branch (%s)' % (collection, version, branch))
+        return None
+
+    def find_layerbranch(self, name, branch=None):
+        '''Return the layerBranch item for a given name and branch
+
+           If a branch has not been specified, we will iterate over the branches in
+           the default configuration until the first name/branch match.'''
+
+        if branch:
+            branches = [branch]
+        else:
+            branches = None
+
+        for index in self.indexes:
+            layerBranch = index.find_layerbranch(name, branches)
+            if layerBranch:
+                return layerBranch
+        return None
+
+    def find_dependencies(self, names=None, layerbranches=None, ignores=None):
+        '''Return a tuple of all dependencies and valid items for the list of (layer) names
+
+        The dependency scanning happens depth-first.  The returned
+        dependencies should be in the best order to define bblayers.
+
+          names - list of layer names (searching layerItems)
+          branches - when specified (with names) only this list of branches are evaluated
+
+          layerbranches - list of layerbranches to resolve dependencies
+
+          ignores - list of layer names to ignore
+
+        return: (dependencies, invalid)
+
+          dependencies[LayerItem.name] = [ LayerBranch, LayerDependency1, LayerDependency2, ... ]
+          invalid = [ LayerItem.name1, LayerItem.name2, ... ]
+        '''
+
+        invalid = []
+
+        # Convert name/branch to layerbranches
+        if layerbranches is None:
+            layerbranches = []
+
+        for name in names:
+            if ignores and name in ignores:
+                continue
+
+            for index in self.indexes:
+                layerbranch = index.find_layerbranch(name)
+                if not layerbranch:
+                    # Not in this index, hopefully it's in another...
+                    continue
+                layerbranches.append(layerbranch)
+                break
+            else:
+                invalid.append(name)
+
+
+        def _resolve_dependencies(layerbranches, ignores, dependencies, invalid):
+            for layerbranch in layerbranches:
+                if ignores and layerbranch.layer.name in ignores:
+                    continue
+
+                # Get a list of dependencies and then recursively process them
+                for layerdependency in layerbranch.index.layerDependencies_layerBranchId[layerbranch.id]:
+                    deplayerbranch = layerdependency.dependency_layerBranch
+
+                    if ignores and deplayerbranch.layer.name in ignores:
+                        continue
+
+                    # This little block is why we can't re-use the LayerIndexObj version,
+                    # we must be able to satisfy each dependencies across layer indexes and
+                    # use the layer index order for priority.  (r stands for replacement below)
+
+                    # If this is the primary index, we can fast path and skip this
+                    if deplayerbranch.index != self.indexes[0]:
+                        # Is there an entry in a prior index for this collection/version?
+                        rdeplayerbranch = self.find_collection(
+                                              collection=deplayerbranch.collection,
+                                              version=deplayerbranch.version
+                                          )
+                        if rdeplayerbranch != deplayerbranch:
+                                logger.debug(1, 'Replaced %s:%s:%s with %s:%s:%s' % \
+                                      (deplayerbranch.index.config['DESCRIPTION'],
+                                       deplayerbranch.branch.name,
+                                       deplayerbranch.layer.name,
+                                       rdeplayerbranch.index.config['DESCRIPTION'],
+                                       rdeplayerbranch.branch.name,
+                                       rdeplayerbranch.layer.name))
+                                deplayerbranch = rdeplayerbranch
+
+                    # New dependency, we need to resolve it now... depth-first
+                    if deplayerbranch.layer.name not in dependencies:
+                        (dependencies, invalid) = _resolve_dependencies([deplayerbranch], ignores, dependencies, invalid)
+
+                    if deplayerbranch.layer.name not in dependencies:
+                        dependencies[deplayerbranch.layer.name] = [deplayerbranch, layerdependency]
+                    else:
+                        if layerdependency not in dependencies[deplayerbranch.layer.name]:
+                            dependencies[deplayerbranch.layer.name].append(layerdependency)
+
+            return (dependencies, invalid)
+
+        # OK, resolve this one...
+        dependencies = OrderedDict()
+        (dependencies, invalid) = _resolve_dependencies(layerbranches, ignores, dependencies, invalid)
+
+        for layerbranch in layerbranches:
+            if layerbranch.layer.name not in dependencies:
+                dependencies[layerbranch.layer.name] = [layerbranch]
+
+        return (dependencies, invalid)
+
+
+    def list_obj(self, object):
+        '''Print via the plain logger object information
+
+This function is used to implement debugging and provide the user info.
+'''
+        for lix in self.indexes:
+            if not hasattr(lix, object):
+                continue
+
+            logger.plain ('')
+            logger.plain ('Index: %s' % lix.config['DESCRIPTION'])
+
+            output = []
+
+            if object == 'branches':
+                logger.plain ('%s %s %s' % ('{:26}'.format('branch'), '{:34}'.format('description'), '{:22}'.format('bitbake branch')))
+                logger.plain ('{:-^80}'.format(""))
+                for branchid in lix.branches:
+                    output.append('%s %s %s' % (
+                                  '{:26}'.format(lix.branches[branchid].name),
+                                  '{:34}'.format(lix.branches[branchid].short_description),
+                                  '{:22}'.format(lix.branches[branchid].bitbake_branch)
+                                 ))
+                for line in sorted(output):
+                    logger.plain (line)
+
+                continue
+
+            if object == 'layerItems':
+                logger.plain ('%s %s' % ('{:26}'.format('layer'), '{:34}'.format('description')))
+                logger.plain ('{:-^80}'.format(""))
+                for layerid in lix.layerItems:
+                    output.append('%s %s' % (
+                                  '{:26}'.format(lix.layerItems[layerid].name),
+                                  '{:34}'.format(lix.layerItems[layerid].summary)
+                                 ))
+                for line in sorted(output):
+                    logger.plain (line)
+
+                continue
+
+            if object == 'layerBranches':
+                logger.plain ('%s %s %s' % ('{:26}'.format('layer'), '{:34}'.format('description'), '{:19}'.format('collection:version')))
+                logger.plain ('{:-^80}'.format(""))
+                for layerbranchid in lix.layerBranches:
+                    output.append('%s %s %s' % (
+                                  '{:26}'.format(lix.layerBranches[layerbranchid].layer.name),
+                                  '{:34}'.format(lix.layerBranches[layerbranchid].layer.summary),
+                                  '{:19}'.format("%s:%s" %
+                                                          (lix.layerBranches[layerbranchid].collection,
+                                                           lix.layerBranches[layerbranchid].version)
+                                                )
+                                 ))
+                for line in sorted(output):
+                    logger.plain (line)
+
+                continue
+
+            if object == 'layerDependencies':
+                logger.plain ('%s %s %s %s' % ('{:19}'.format('branch'), '{:26}'.format('layer'), '{:11}'.format('dependency'), '{:26}'.format('layer')))
+                logger.plain ('{:-^80}'.format(""))
+                for layerDependency in lix.layerDependencies:
+                    if not lix.layerDependencies[layerDependency].dependency_layerBranch:
+                        continue
+
+                    output.append('%s %s %s %s' % (
+                                  '{:19}'.format(lix.layerDependencies[layerDependency].layerbranch.branch.name),
+                                  '{:26}'.format(lix.layerDependencies[layerDependency].layerbranch.layer.name),
+                                  '{:11}'.format('requires' if lix.layerDependencies[layerDependency].required else 'recommends'),
+                                  '{:26}'.format(lix.layerDependencies[layerDependency].dependency_layerBranch.layer.name)
+                                 ))
+                for line in sorted(output):
+                    logger.plain (line)
+
+                continue
+
+            if object == 'recipes':
+                logger.plain ('%s %s %s' % ('{:20}'.format('recipe'), '{:10}'.format('version'), 'layer'))
+                logger.plain ('{:-^80}'.format(""))
+                output = []
+                for recipe in lix.recipes:
+                    output.append('%s %s %s' % (
+                                  '{:30}'.format(lix.recipes[recipe].pn),
+                                  '{:30}'.format(lix.recipes[recipe].pv),
+                                  lix.recipes[recipe].layer.name
+                                 ))
+                for line in sorted(output):
+                    logger.plain (line)
+
+                continue
+
+            if object == 'machines':
+                logger.plain ('%s %s %s' % ('{:24}'.format('machine'), '{:34}'.format('description'), '{:19}'.format('layer')))
+                logger.plain ('{:-^80}'.format(""))
+                for machine in lix.machines:
+                    output.append('%s %s %s' % (
+                                  '{:24}'.format(lix.machines[machine].name),
+                                  '{:34}'.format(lix.machines[machine].description)[:34],
+                                  '{:19}'.format(lix.machines[machine].layerbranch.layer.name)
+                                 ))
+                for line in sorted(output):
+                    logger.plain (line)
+
+                continue
+
+            if object == 'distros':
+                logger.plain ('%s %s %s' % ('{:24}'.format('distro'), '{:34}'.format('description'), '{:19}'.format('layer')))
+                logger.plain ('{:-^80}'.format(""))
+                for distro in lix.distros:
+                    output.append('%s %s %s' % (
+                                  '{:24}'.format(lix.distros[distro].name),
+                                  '{:34}'.format(lix.distros[distro].description)[:34],
+                                  '{:19}'.format(lix.distros[distro].layerbranch.layer.name)
+                                 ))
+                for line in sorted(output):
+                    logger.plain (line)
+
+                continue
+
+        logger.plain ('')
+
+
+# This class holds a single layer index instance
+# The LayerIndexObj is made up of dictionary of elements, such as:
+#   index['config'] - configuration data for this index
+#   index['branches'] - dictionary of Branch objects, by id number
+#   index['layerItems'] - dictionary of layerItem objects, by id number
+#   ...etc...  (See: http://layers.openembedded.org/layerindex/api/)
+#
+# The class needs to manage the 'index' entries and allow easily adding
+# of new items, as well as simply loading of the items.
+class LayerIndexObj():
+    def __init__(self):
+        super().__setattr__('_index', {})
+        super().__setattr__('_lock', False)
+
+    def __bool__(self):
+        '''False if the index is effectively empty
+
+           We check the index to see if it has a branch set, as well as
+           layerbranches set.  If not, it is effectively blank.'''
+
+        if not bool(self._index):
+            return False
+
+        try:
+            if self.branches and self.layerBranches:
+                return True
+        except AttributeError:
+            pass
+
+        return False
+
+    def __getattr__(self, name):
+        if name.startswith('_'):
+            return super().__getattribute__(name)
+
+        if name not in self._index:
+            raise AttributeError('%s not in index datastore' % name)
+
+        return self._index[name]
+
+    def __setattr__(self, name, value):
+        if self.isLocked():
+            raise TypeError("Can not set attribute '%s': index is locked" % name)
+
+        if name.startswith('_'):
+            super().__setattr__(name, value)
+            return
+
+        self._index[name] = value
+
+    def __delattr__(self, name):
+        if self.isLocked():
+            raise TypeError("Can not delete attribute '%s': index is locked" % name)
+
+        if name.startswith('_'):
+            super().__delattr__(name)
+
+        self._index.pop(name)
+
+    def lockData(self):
+        '''Lock data object (make it readonly)'''
+        super().__setattr__("_lock", True)
+
+    def unlockData(self):
+        '''unlock data object (make it readonly)'''
+        super().__setattr__("_lock", False)
+
+        # When the data is unlocked, we have to clear the caches, as
+        # modification is allowed!
+        del(self._layerBranches_layerId_branchId)
+        del(self._layerDependencies_layerBranchId)
+        del(self._layerBranches_vcsUrl)
+
+    def isLocked(self):
+        '''Is this object locked (readonly)?'''
+        return self._lock
+
+    def add_element(self, indexname, objs):
+        '''Add a layer index object to index.<indexname>'''
+        if indexname not in self._index:
+            self._index[indexname] = {}
+
+        for obj in objs:
+            if obj.id in self._index[indexname]:
+                if self._index[indexname][obj.id] == obj:
+                    continue
+                raise LayerIndexError('Conflict adding object %s(%s) to index' % (indexname, obj.id))
+            self._index[indexname][obj.id] = obj
+
+    def add_raw_element(self, indexname, objtype, rawobjs):
+        '''Convert a raw layer index data item to a layer index item object and add to the index'''
+        objs = []
+        for entry in rawobjs:
+            objs.append(objtype(self, entry))
+        self.add_element(indexname, objs)
+
+    # Quick lookup table for searching layerId and branchID combos
+    @property
+    def layerBranches_layerId_branchId(self):
+        def createCache(self):
+            cache = {}
+            for layerbranchid in self.layerBranches:
+                layerbranch = self.layerBranches[layerbranchid]
+                cache["%s:%s" % (layerbranch.layer_id, layerbranch.branch_id)] = layerbranch
+            return cache
+
+        if self.isLocked():
+            cache = getattr(self, '_layerBranches_layerId_branchId', None)
+        else:
+            cache = None
+
+        if not cache:
+            cache = createCache(self)
+
+        if self.isLocked():
+            super().__setattr__('_layerBranches_layerId_branchId', cache)
+
+        return cache
+
+    # Quick lookup table for finding all dependencies of a layerBranch
+    @property
+    def layerDependencies_layerBranchId(self):
+        def createCache(self):
+            cache = {}
+            # This ensures empty lists for all branchids
+            for layerbranchid in self.layerBranches:
+                cache[layerbranchid] = []
+
+            for layerdependencyid in self.layerDependencies:
+                layerdependency = self.layerDependencies[layerdependencyid]
+                cache[layerdependency.layerbranch_id].append(layerdependency)
+            return cache
+
+        if self.isLocked():
+            cache = getattr(self, '_layerDependencies_layerBranchId', None)
+        else:
+            cache = None
+
+        if not cache:
+            cache = createCache(self)
+
+        if self.isLocked():
+            super().__setattr__('_layerDependencies_layerBranchId', cache)
+
+        return cache
+
+    # Quick lookup table for finding all instances of a vcs_url
+    @property
+    def layerBranches_vcsUrl(self):
+        def createCache(self):
+            cache = {}
+            for layerbranchid in self.layerBranches:
+                layerbranch = self.layerBranches[layerbranchid]
+                if layerbranch.layer.vcs_url not in cache:
+                   cache[layerbranch.layer.vcs_url] = [layerbranch]
+                else:
+                   cache[layerbranch.layer.vcs_url].append(layerbranch)
+            return cache
+
+        if self.isLocked():
+            cache = getattr(self, '_layerBranches_vcsUrl', None)
+        else:
+            cache = None
+
+        if not cache:
+            cache = createCache(self)
+
+        if self.isLocked():
+            super().__setattr__('_layerBranches_vcsUrl', cache)
+
+        return cache
+
+
+    def find_vcs_url(self, vcs_url, branches=None):
+        ''''Return the first layerBranch with the given vcs_url
+
+            If a list of branches has not been specified, we will iterate on
+            all branches until the first vcs_url is found.'''
+
+        if not self.__bool__():
+            return None
+
+        for layerbranch in self.layerBranches_vcsUrl:
+            if branches and layerbranch.branch.name not in branches:
+                continue
+
+            return layerbranch
+
+        return None
+
+
+    def find_collection(self, collection, version=None, branches=None):
+        '''Return the first layerBranch with the given collection name
+
+           If a list of branches has not been specified, we will iterate on
+           all branches until the first collection is found.'''
+
+        if not self.__bool__():
+            return None
+
+        for layerbranchid in self.layerBranches:
+            layerbranch = self.layerBranches[layerbranchid]
+            if branches and layerbranch.branch.name not in branches:
+                continue
+
+            if layerbranch.collection == collection and \
+                (version is None or version == layerbranch.version):
+                return layerbranch
+
+        return None
+
+
+    def find_layerbranch(self, name, branches=None):
+        '''Return the first layerbranch whose layer name matches
+
+           If a list of branches has not been specified, we will iterate on
+           all branches until the first layer with that name is found.'''
+
+        if not self.__bool__():
+            return None
+
+        for layerbranchid in self.layerBranches:
+            layerbranch = self.layerBranches[layerbranchid]
+            if branches and layerbranch.branch.name not in branches:
+                continue
+
+            if layerbranch.layer.name == name:
+                return layerbranch
+
+        return None
+
+    def find_dependencies(self, names=None, branches=None, layerBranches=None, ignores=None):
+        '''Return a tuple of all dependencies and valid items for the list of (layer) names
+
+        The dependency scanning happens depth-first.  The returned
+        dependencies should be in the best order to define bblayers.
+
+          names - list of layer names (searching layerItems)
+          branches - when specified (with names) only this list of branches are evaluated
+
+          layerBranches - list of layerBranches to resolve dependencies
+
+          ignores - list of layer names to ignore
+
+        return: (dependencies, invalid)
+
+          dependencies[LayerItem.name] = [ LayerBranch, LayerDependency1, LayerDependency2, ... ]
+          invalid = [ LayerItem.name1, LayerItem.name2, ... ]'''
+
+        invalid = []
+
+        # Convert name/branch to layerBranches
+        if layerbranches is None:
+            layerbranches = []
+
+        for name in names:
+            if ignores and name in ignores:
+                continue
+
+            layerbranch = self.find_layerbranch(name, branches)
+            if not layerbranch:
+                invalid.append(name)
+            else:
+                layerbranches.append(layerbranch)
+
+        for layerbranch in layerbranches:
+            if layerbranch.index != self:
+                raise LayerIndexException("Can not resolve dependencies across indexes with this class function!")
+
+        def _resolve_dependencies(layerbranches, ignores, dependencies, invalid):
+            for layerbranch in layerbranches:
+                if ignores and layerBranch.layer.name in ignores:
+                    continue
+
+                for layerdependency in layerbranch.index.layerDependencies_layerBranchId[layerBranch.id]:
+                    deplayerbranch = layerDependency.dependency_layerBranch
+
+                    if ignores and deplayerbranch.layer.name in ignores:
+                        continue
+
+                    # New dependency, we need to resolve it now... depth-first
+                    if deplayerbranch.layer.name not in dependencies:
+                        (dependencies, invalid) = _resolve_dependencies([deplayerbranch], ignores, dependencies, invalid)
+
+                    if deplayerbranch.layer.name not in dependencies:
+                        dependencies[deplayerbranch.layer.name] = [deplayerbranch, layerdependency]
+                    else:
+                        if layerdependency not in dependencies[deplayerbranch.layer.name]:
+                            dependencies[deplayerbranch.layer.name].append(layerdependency)
+
+                return (dependencies, invalid)
+
+        # OK, resolve this one...
+        dependencies = OrderedDict()
+        (dependencies, invalid) = _resolve_dependencies(layerbranches, ignores, dependencies, invalid)
+
+        # Is this item already in the list, if not add it
+        for layerbranch in layerbranches:
+            if layerbranch.layer.name not in dependencies:
+                dependencies[layerbranch.layer.name] = [layerbranch]
+
+        return (dependencies, invalid)
+
+
+# Define a basic LayerIndexItemObj.  This object forms the basis for all other
+# objects.  The raw Layer Index data is stored in the _data element, but we
+# do not want users to access data directly.  So wrap this and protect it
+# from direct manipulation.
+#
+# It is up to the insantiators of the objects to fill them out, and once done
+# lock the objects to prevent further accidently manipulation.
+#
+# Using the getattr, setattr and properties we can access and manipulate
+# the data within the data element.
+class LayerIndexItemObj():
+    def __init__(self, index, data=None, lock=False):
+        if data is None:
+            data = {}
+
+        if type(data) != type(dict()):
+            raise TypeError('data (%s) is not a dict' % type(data))
+
+        super().__setattr__('_lock',  lock)
+        super().__setattr__('index', index)
+        super().__setattr__('_data',  data)
+
+    def __eq__(self, other):
+        if self.__class__ != other.__class__:
+            return False
+        res=(self._data == other._data)
+        return res
+
+    def __bool__(self):
+        return bool(self._data)
+
+    def __getattr__(self, name):
+        # These are internal to THIS class, and not part of data
+        if name == "index" or name.startswith('_'):
+            return super().__getattribute__(name)
+
+        if name not in self._data:
+            raise AttributeError('%s not in datastore' % name)
+
+        return self._data[name]
+
+    def _setattr(self, name, value, prop=True):
+        '''__setattr__ like function, but with control over property object behavior'''
+        if self.isLocked():
+            raise TypeError("Can not set attribute '%s': Object data is locked" % name)
+
+        if name.startswith('_'):
+            super().__setattr__(name, value)
+            return
+
+        # Since __setattr__ runs before properties, we need to check if
+        # there is a setter property and then execute it
+        # ... or return self._data[name]
+        propertyobj = getattr(self.__class__, name, None)
+        if prop and isinstance(propertyobj, property):
+            if propertyobj.fset:
+                propertyobj.fset(self, value)
+            else:
+                raise AttributeError('Attribute %s is readonly, and may not be set' % name)
+        else:
+            self._data[name] = value
+
+    def __setattr__(self, name, value):
+        self._setattr(name, value, prop=True)
+
+    def _delattr(self, name, prop=True):
+        # Since __delattr__ runs before properties, we need to check if
+        # there is a deleter property and then execute it
+        # ... or we pop it ourselves..
+        propertyobj = getattr(self.__class__, name, None)
+        if prop and isinstance(propertyobj, property):
+            if propertyobj.fdel:
+                propertyobj.fdel(self)
+            else:
+                raise AttributeError('Attribute %s is readonly, and may not be deleted' % name)
+        else:
+            self._data.pop(name)
+
+    def __delattr__(self, name):
+        self._delattr(name, prop=True)
+
+    def lockData(self):
+        '''Lock data object (make it readonly)'''
+        super().__setattr__("_lock", True)
+
+    def unlockData(self):
+        '''unlock data object (make it readonly)'''
+        super().__setattr__("_lock", False)
+
+    def isLocked(self):
+        '''Is this object locked (readonly)?'''
+        return self._lock
+
+# Branch object
+class Branch(LayerIndexItemObj):
+    def define_data(self, id, name, bitbake_branch,
+                 short_description=None, sort_priority=1,
+                 updates_enabled=True, updated=None,
+                 update_environment=None):
+        self.id = id
+        self.name = name
+        self.bitbake_branch = bitbake_branch
+        self.short_description = short_description or name
+        self.sort_priority = sort_priority
+        self.updates_enabled = updates_enabled
+        self.updated = updated or datetime.datetime.today().isoformat()
+        self.update_environment = update_environment
+
+    @property
+    def name(self):
+        return self.__getattr__('name')
+
+    @name.setter
+    def name(self, value):
+        self._data['name'] = value
+
+        if self.bitbake_branch == value:
+            self.bitbake_branch = ""
+
+    @name.deleter
+    def name(self):
+        self._delattr('name', prop=False)
+
+    @property
+    def bitbake_branch(self):
+        try:
+            return self.__getattr__('bitbake_branch')
+        except AttributeError:
+            return self.name
+
+    @bitbake_branch.setter
+    def bitbake_branch(self, value):
+        if self.name == value:
+            self._data['bitbake_branch'] = ""
+        else:
+            self._data['bitbake_branch'] = value
+
+    @bitbake_branch.deleter
+    def bitbake_branch(self):
+        self._delattr('bitbake_branch', prop=False)
+
+
+class LayerItem(LayerIndexItemObj):
+    def define_data(self, id, name, status='P',
+                 layer_type='A', summary=None,
+                 description=None,
+                 vcs_url=None, vcs_web_url=None,
+                 vcs_web_tree_base_url=None,
+                 vcs_web_file_base_url=None,
+                 usage_url=None,
+                 mailing_list_url=None,
+                 index_preference=1,
+                 classic=False,
+                 updated=None):
+        self.id = id
+        self.name = name
+        self.status = status
+        self.layer_type = layer_type
+        self.summary = summary or name
+        self.description = description or summary or name
+        self.vcs_url = vcs_url
+        self.vcs_web_url = vcs_web_url
+        self.vcs_web_tree_base_url = vcs_web_tree_base_url
+        self.vcs_web_file_base_url = vcs_web_file_base_url
+        self.index_preference = index_preference
+        self.classic = classic
+        self.updated = updated or datetime.datetime.today().isoformat()
+
+
+class LayerBranch(LayerIndexItemObj):
+    def define_data(self, id, collection, version, layer, branch,
+                 vcs_subdir="", vcs_last_fetch=None,
+                 vcs_last_rev=None, vcs_last_commit=None,
+                 actual_branch="",
+                 updated=None):
+        self.id = id
+        self.collection = collection
+        self.version = version
+        if isinstance(layer, LayerItem):
+            self.layer = layer
+        else:
+            self.layer_id = layer
+
+        if isinstance(branch, Branch):
+            self.branch = branch
+        else:
+            self.branch_id = branch
+
+        self.vcs_subdir = vcs_subdir
+        self.vcs_last_fetch = vcs_last_fetch
+        self.vcs_last_rev = vcs_last_rev
+        self.vcs_last_commit = vcs_last_commit
+        self.actual_branch = actual_branch
+        self.updated = updated or datetime.datetime.today().isoformat()
+
+    # This is a little odd, the _data attribute is 'layer', but it's really
+    # referring to the layer id.. so lets adjust this to make it useful
+    @property
+    def layer_id(self):
+        return self.__getattr__('layer')
+
+    @layer_id.setter
+    def layer_id(self, value):
+        self._setattr('layer', value, prop=False)
+
+    @layer_id.deleter
+    def layer_id(self):
+        self._delattr('layer', prop=False)
+
+    @property
+    def layer(self):
+        try:
+            return self.index.layerItems[self.layer_id]
+        except KeyError:
+            raise AttributeError('Unable to find layerItems in index to map layer_id %s' % self.layer_id)
+        except IndexError:
+            raise AttributeError('Unable to find layer_id %s in index layerItems' % self.layer_id)
+
+    @layer.setter
+    def layer(self, value):
+        if not isinstance(value, LayerItem):
+            raise TypeError('value is not a LayerItem')
+        if self.index != value.index:
+            raise AttributeError('Object and value do not share the same index and thus key set.')
+        self.layer_id = value.id
+
+    @layer.deleter
+    def layer(self):
+        del self.layer_id
+
+    @property
+    def branch_id(self):
+        return self.__getattr__('branch')
+
+    @branch_id.setter
+    def branch_id(self, value):
+        self._setattr('branch', value, prop=False)
+
+    @branch_id.deleter
+    def branch_id(self):
+        self._delattr('branch', prop=False)
+
+    @property
+    def branch(self):
+        try:
+            logger.debug(1, "Get branch object from branches[%s]" % (self.branch_id))
+            return self.index.branches[self.branch_id]
+        except KeyError:
+            raise AttributeError('Unable to find branches in index to map branch_id %s' % self.branch_id)
+        except IndexError:
+            raise AttributeError('Unable to find branch_id %s in index branches' % self.branch_id)
+
+    @branch.setter
+    def branch(self, value):
+        if not isinstance(value, LayerItem):
+            raise TypeError('value is not a LayerItem')
+        if self.index != value.index:
+            raise AttributeError('Object and value do not share the same index and thus key set.')
+        self.branch_id = value.id
+
+    @branch.deleter
+    def branch(self):
+        del self.branch_id
+
+    @property
+    def actual_branch(self):
+        if self.__getattr__('actual_branch'):
+            return self.__getattr__('actual_branch')
+        else:
+            return self.branch.name
+
+    @actual_branch.setter
+    def actual_branch(self, value):
+        logger.debug(1, "Set actual_branch to %s .. name is %s" % (value, self.branch.name))
+        if value != self.branch.name:
+            self._setattr('actual_branch', value, prop=False)
+        else:
+            self._setattr('actual_branch', '', prop=False)
+
+    @actual_branch.deleter
+    def actual_branch(self):
+        self._delattr('actual_branch', prop=False)
+
+# Extend LayerIndexItemObj with common LayerBranch manipulations
+# All of the remaining LayerIndex objects refer to layerbranch, and it is
+# up to the user to follow that back through the LayerBranch object into
+# the layer object to get various attributes.  So add an intermediate set
+# of attributes that can easily get us the layerbranch as well as layer.
+
+class LayerIndexItemObj_LayerBranch(LayerIndexItemObj):
+    @property
+    def layerbranch_id(self):
+        return self.__getattr__('layerbranch')
+
+    @layerbranch_id.setter
+    def layerbranch_id(self, value):
+        self._setattr('layerbranch', value, prop=False)
+
+    @layerbranch_id.deleter
+    def layerbranch_id(self):
+        self._delattr('layerbranch', prop=False)
+
+    @property
+    def layerbranch(self):
+        try:
+            return self.index.layerBranches[self.layerbranch_id]
+        except KeyError:
+            raise AttributeError('Unable to find layerBranches in index to map layerbranch_id %s' % self.layerbranch_id)
+        except IndexError:
+            raise AttributeError('Unable to find layerbranch_id %s in index branches' % self.layerbranch_id)
+
+    @layerbranch.setter
+    def layerbranch(self, value):
+        if not isinstance(value, LayerBranch):
+            raise TypeError('value (%s) is not a layerBranch' % type(value))
+        if self.index != value.index:
+            raise AttributeError('Object and value do not share the same index and thus key set.')
+        self.layerbranch_id = value.id
+
+    @layerbranch.deleter
+    def layerbranch(self):
+        del self.layerbranch_id
+
+    @property
+    def layer_id(self):
+        return self.layerbranch.layer_id
+
+    # Doesn't make sense to set or delete layer_id
+
+    @property
+    def layer(self):
+        return self.layerbranch.layer
+
+    # Doesn't make sense to set or delete layer
+
+
+class LayerDependency(LayerIndexItemObj_LayerBranch):
+    def define_data(self, id, layerbranch, dependency, required=True):
+        self.id = id
+        if isinstance(layerbranch, LayerBranch):
+            self.layerbranch = layerbranch
+        else:
+            self.layerbranch_id = layerbranch
+        if isinstance(dependency, LayerDependency):
+            self.dependency = dependency
+        else:
+            self.dependency_id = dependency
+        self.required = required
+
+    @property
+    def dependency_id(self):
+        return self.__getattr__('dependency')
+
+    @dependency_id.setter
+    def dependency_id(self, value):
+        self._setattr('dependency', value, prop=False)
+
+    @dependency_id.deleter
+    def dependency_id(self):
+        self._delattr('dependency', prop=False)
+
+    @property
+    def dependency(self):
+        try:
+            return self.index.layerItems[self.dependency_id]
+        except KeyError:
+            raise AttributeError('Unable to find layerItems in index to map layerbranch_id %s' % self.dependency_id)
+        except IndexError:
+            raise AttributeError('Unable to find dependency_id %s in index layerItems' % self.dependency_id)
+
+    @dependency.setter
+    def dependency(self, value):
+        if not isinstance(value, LayerDependency):
+            raise TypeError('value (%s) is not a dependency' % type(value))
+        if self.index != value.index:
+            raise AttributeError('Object and value do not share the same index and thus key set.')
+        self.dependency_id = value.id
+
+    @dependency.deleter
+    def dependency(self):
+        self._delattr('dependency', prop=False)
+
+    @property
+    def dependency_layerBranch(self):
+        layerid = self.dependency_id
+        branchid = self.layerbranch.branch_id
+
+        try:
+            return self.index.layerBranches_layerId_branchId["%s:%s" % (layerid, branchid)]
+        except IndexError:
+            # layerBranches_layerId_branchId -- but not layerId:branchId
+            raise AttributeError('Unable to find layerId:branchId %s:%s in index layerBranches_layerId_branchId' % (layerid, branchid))
+        except KeyError:
+            raise AttributeError('Unable to find layerId:branchId %s:%s in layerItems and layerBranches' % (layerid, branchid))
+
+    # dependency_layerBranch doesn't make sense to set or del
+
+
+class Recipe(LayerIndexItemObj_LayerBranch):
+    def define_data(self, id,
+                    filename, filepath, pn, pv, layerbranch,
+                    summary="", description="", section="", license="",
+                    homepage="", bugtracker="", provides="", bbclassextend="",
+                    inherits="", blacklisted="", updated=None):
+        self.id = id
+        self.filename = filename
+        self.filepath = filepath
+        self.pn = pn
+        self.pv = pv
+        self.summary = summary
+        self.description = description
+        self.section = section
+        self.license = license
+        self.homepage = homepage
+        self.bugtracker = bugtracker
+        self.provides = provides
+        self.bbclassextend = bbclassextend
+        self.inherits = inherits
+        self.updated = updated or datetime.datetime.today().isoformat()
+        self.blacklisted = blacklisted
+        if isinstance(layerbranch, LayerBranch):
+            self.layerbranch = layerbranch
+        else:
+            self.layerbranch_id = layerbranch
+
+    @property
+    def fullpath(self):
+        return os.path.join(self.filepath, self.filename)
+
+    # Set would need to understand how to split it
+    # del would we del both parts?
+
+    @property
+    def inherits(self):
+        if 'inherits' not in self._data:
+            # Older indexes may not have this, so emulate it
+            if '-image-' in self.pn:
+                return 'image'
+        return self.__getattr__('inherits')
+
+    @inherits.setter
+    def inherits(self, value):
+        return self._setattr('inherits', value, prop=False)
+
+    @inherits.deleter
+    def inherits(self):
+        return self._delattr('inherits', prop=False)
+
+
+class Machine(LayerIndexItemObj_LayerBranch):
+    def define_data(self, id,
+                    name, description, layerbranch,
+                    updated=None):
+        self.id = id
+        self.name = name
+        self.description = description
+        if isinstance(layerbranch, LayerBranch):
+            self.layerbranch = layerbranch
+        else:
+            self.layerbranch_id = layerbranch
+        self.updated = updated or datetime.datetime.today().isoformat()
+
+class Distro(LayerIndexItemObj_LayerBranch):
+    def define_data(self, id,
+                    name, description, layerbranch,
+                    updated=None):
+        self.id = id
+        self.name = name
+        self.description = description
+        if isinstance(layerbranch, LayerBranch):
+            self.layerbranch = layerbranch
+        else:
+            self.layerbranch_id = layerbranch
+        self.updated = updated or datetime.datetime.today().isoformat()
+
+# When performing certain actions, we may need to sort the data.
+# This will allow us to keep it consistent from run to run.
+def sort_entry(item):
+    newitem = item
+    try:
+        if type(newitem) == type(dict()):
+            newitem = OrderedDict(sorted(newitem.items(), key=lambda t: t[0]))
+            for index in newitem:
+                newitem[index] = sort_entry(newitem[index])
+        elif type(newitem) == type(list()):
+            newitem.sort(key=lambda obj: obj['id'])
+            for index, _ in enumerate(newitem):
+                newitem[index] = sort_entry(newitem[index])
+    except:
+        logger.error('Sort failed for item %s' % type(item))
+        pass
+
+    return newitem
diff --git a/poky/bitbake/lib/layerindexlib/cooker.py b/poky/bitbake/lib/layerindexlib/cooker.py
new file mode 100644
index 0000000..848f0e2
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/cooker.py
@@ -0,0 +1,344 @@
+# Copyright (C) 2016-2018 Wind River Systems, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License version 2 as
+# published by the Free Software Foundation.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+import logging
+import json
+
+from collections import OrderedDict, defaultdict
+
+from urllib.parse import unquote, urlparse
+
+import layerindexlib
+
+import layerindexlib.plugin
+
+logger = logging.getLogger('BitBake.layerindexlib.cooker')
+
+import bb.utils
+
+def plugin_init(plugins):
+    return CookerPlugin()
+
+class CookerPlugin(layerindexlib.plugin.IndexPlugin):
+    def __init__(self):
+        self.type = "cooker"
+
+        self.server_connection = None
+        self.ui_module = None
+        self.server = None
+
+    def _run_command(self, command, path, default=None):
+        try:
+            result, _ = bb.process.run(command, cwd=path)
+            result = result.strip()
+        except bb.process.ExecutionError:
+            result = default
+        return result
+
+    def _handle_git_remote(self, remote):
+        if "://" not in remote:
+            if ':' in remote:
+                # This is assumed to be ssh
+                remote = "ssh://" + remote
+            else:
+                # This is assumed to be a file path
+                remote = "file://" + remote
+        return remote
+
+    def _get_bitbake_info(self):
+        """Return a tuple of bitbake information"""
+
+        # Our path SHOULD be .../bitbake/lib/layerindex/cooker.py
+        bb_path = os.path.dirname(__file__) # .../bitbake/lib/layerindex/cooker.py
+        bb_path = os.path.dirname(bb_path)  # .../bitbake/lib/layerindex
+        bb_path = os.path.dirname(bb_path)  # .../bitbake/lib
+        bb_path = os.path.dirname(bb_path)  # .../bitbake
+        bb_path = self._run_command('git rev-parse --show-toplevel', os.path.dirname(__file__), default=bb_path)
+        bb_branch = self._run_command('git rev-parse --abbrev-ref HEAD', bb_path, default="<unknown>")
+        bb_rev = self._run_command('git rev-parse HEAD', bb_path, default="<unknown>")
+        for remotes in self._run_command('git remote -v', bb_path, default="").split("\n"):
+            remote = remotes.split("\t")[1].split(" ")[0]
+            if "(fetch)" == remotes.split("\t")[1].split(" ")[1]:
+                bb_remote = self._handle_git_remote(remote)
+                break
+        else:
+            bb_remote = self._handle_git_remote(bb_path)
+
+        return (bb_remote, bb_branch, bb_rev, bb_path)
+
+    def _load_bblayers(self, branches=None):
+        """Load the BBLAYERS and related collection information"""
+
+        d = self.layerindex.data
+
+        if not branches:
+            raise LayerIndexFetchError("No branches specified for _load_bblayers!")
+
+        index = layerindexlib.LayerIndexObj()
+
+        branchId = 0
+        index.branches = {}
+
+        layerItemId = 0
+        index.layerItems = {}
+
+        layerBranchId = 0
+        index.layerBranches = {}
+
+        bblayers = d.getVar('BBLAYERS').split()
+
+        if not bblayers:
+            # It's blank!  Nothing to process...
+            return index
+
+        collections = d.getVar('BBFILE_COLLECTIONS')
+        layerconfs = d.varhistory.get_variable_items_files('BBFILE_COLLECTIONS', d)
+        bbfile_collections = {layer: os.path.dirname(os.path.dirname(path)) for layer, path in layerconfs.items()}
+
+        (_, bb_branch, _, _) = self._get_bitbake_info()
+
+        for branch in branches:
+            branchId += 1
+            index.branches[branchId] = layerindexlib.Branch(index, None)
+            index.branches[branchId].define_data(branchId, branch, bb_branch)
+
+        for entry in collections.split():
+            layerpath = entry
+            if entry in bbfile_collections:
+                layerpath = bbfile_collections[entry]
+
+            layername = d.getVar('BBLAYERS_LAYERINDEX_NAME_%s' % entry) or os.path.basename(layerpath)
+            layerversion = d.getVar('LAYERVERSION_%s' % entry) or ""
+            layerurl = self._handle_git_remote(layerpath)
+
+            layersubdir = ""
+            layerrev = "<unknown>"
+            layerbranch = "<unknown>"
+
+            if os.path.isdir(layerpath):
+                layerbasepath = self._run_command('git rev-parse --show-toplevel', layerpath, default=layerpath)
+                if os.path.abspath(layerpath) != os.path.abspath(layerbasepath):
+                    layersubdir = os.path.abspath(layerpath)[len(layerbasepath) + 1:]
+
+                layerbranch = self._run_command('git rev-parse --abbrev-ref HEAD', layerpath, default="<unknown>")
+                layerrev = self._run_command('git rev-parse HEAD', layerpath, default="<unknown>")
+
+                for remotes in self._run_command('git remote -v', layerpath, default="").split("\n"):
+                    if not remotes:
+                        layerurl = self._handle_git_remote(layerpath)
+                    else:
+                        remote = remotes.split("\t")[1].split(" ")[0]
+                        if "(fetch)" == remotes.split("\t")[1].split(" ")[1]:
+                            layerurl = self._handle_git_remote(remote)
+                            break
+
+            layerItemId += 1
+            index.layerItems[layerItemId] = layerindexlib.LayerItem(index, None)
+            index.layerItems[layerItemId].define_data(layerItemId, layername, description=layerpath, vcs_url=layerurl)
+
+            for branchId in index.branches:
+                layerBranchId += 1
+                index.layerBranches[layerBranchId] = layerindexlib.LayerBranch(index, None)
+                index.layerBranches[layerBranchId].define_data(layerBranchId, entry, layerversion, layerItemId, branchId,
+                                               vcs_subdir=layersubdir, vcs_last_rev=layerrev, actual_branch=layerbranch)
+
+        return index
+
+
+    def load_index(self, url, load):
+        """
+            Fetches layer information from a build configuration.
+
+            The return value is a dictionary containing API,
+            layer, branch, dependency, recipe, machine, distro, information.
+
+            url type should be 'cooker'.
+            url path is ignored
+        """
+
+        up = urlparse(url)
+
+        if up.scheme != 'cooker':
+            raise layerindexlib.plugin.LayerIndexPluginUrlError(self.type, url)
+
+        d = self.layerindex.data
+
+        params = self.layerindex._parse_params(up.params)
+
+        # Only reason to pass a branch is to emulate them...
+        if 'branch' in params:
+            branches = params['branch'].split(',')
+        else:
+            branches = ['HEAD']
+
+        logger.debug(1, "Loading cooker data branches %s" % branches)
+
+        index = self._load_bblayers(branches=branches)
+
+        index.config = {}
+        index.config['TYPE'] = self.type
+        index.config['URL'] = url
+
+        if 'desc' in params:
+            index.config['DESCRIPTION'] = unquote(params['desc'])
+        else:
+            index.config['DESCRIPTION'] = 'local'
+
+        if 'cache' in params:
+            index.config['CACHE'] = params['cache']
+
+        index.config['BRANCH'] = branches
+
+        # ("layerDependencies", layerindexlib.LayerDependency)
+        layerDependencyId = 0
+        if "layerDependencies" in load:
+            index.layerDependencies = {}
+            for layerBranchId in index.layerBranches:
+                branchName = index.layerBranches[layerBranchId].branch.name
+                collection = index.layerBranches[layerBranchId].collection
+
+                def add_dependency(layerDependencyId, index, deps, required):
+                    try:
+                        depDict = bb.utils.explode_dep_versions2(deps)
+                    except bb.utils.VersionStringException as vse:
+                        bb.fatal('Error parsing LAYERDEPENDS_%s: %s' % (c, str(vse)))
+
+                    for dep, oplist in list(depDict.items()):
+                        # We need to search ourselves, so use the _ version...
+                        depLayerBranch = index.find_collection(dep, branches=[branchName])
+                        if not depLayerBranch:
+                            # Missing dependency?!
+                            logger.error('Missing dependency %s (%s)' % (dep, branchName))
+                            continue
+
+                        # We assume that the oplist matches...
+                        layerDependencyId += 1
+                        layerDependency = layerindexlib.LayerDependency(index, None)
+                        layerDependency.define_data(id=layerDependencyId,
+                                        required=required, layerbranch=layerBranchId,
+                                        dependency=depLayerBranch.layer_id)
+
+                        logger.debug(1, '%s requires %s' % (layerDependency.layer.name, layerDependency.dependency.name))
+                        index.add_element("layerDependencies", [layerDependency])
+
+                    return layerDependencyId
+
+                deps = d.getVar("LAYERDEPENDS_%s" % collection)
+                if deps:
+                    layerDependencyId = add_dependency(layerDependencyId, index, deps, True)
+
+                deps = d.getVar("LAYERRECOMMENDS_%s" % collection)
+                if deps:
+                    layerDependencyId = add_dependency(layerDependencyId, index, deps, False)
+
+        # Need to load recipes here (requires cooker access)
+        recipeId = 0
+        ## TODO: NOT IMPLEMENTED
+        # The code following this is an example of what needs to be
+        # implemented.  However, it does not work as-is.
+        if False and 'recipes' in load:
+            index.recipes = {}
+
+            ret = self.ui_module.main(self.server_connection.connection, self.server_connection.events, config_params)
+
+            all_versions = self._run_command('allProviders')
+
+            all_versions_list = defaultdict(list, all_versions)
+            for pn in all_versions_list:
+                for ((pe, pv, pr), fpath) in all_versions_list[pn]:
+                    realfn = bb.cache.virtualfn2realfn(fpath)
+
+                    filepath = os.path.dirname(realfn[0])
+                    filename = os.path.basename(realfn[0])
+
+                    # This is all HORRIBLY slow, and likely unnecessary
+                    #dscon = self._run_command('parseRecipeFile', fpath, False, [])
+                    #connector = myDataStoreConnector(self, dscon.dsindex)
+                    #recipe_data = bb.data.init()
+                    #recipe_data.setVar('_remote_data', connector)
+
+                    #summary = recipe_data.getVar('SUMMARY')
+                    #description = recipe_data.getVar('DESCRIPTION')
+                    #section = recipe_data.getVar('SECTION')
+                    #license = recipe_data.getVar('LICENSE')
+                    #homepage = recipe_data.getVar('HOMEPAGE')
+                    #bugtracker = recipe_data.getVar('BUGTRACKER')
+                    #provides = recipe_data.getVar('PROVIDES')
+
+                    layer = bb.utils.get_file_layer(realfn[0], self.config_data)
+
+                    depBranchId = collection_layerbranch[layer]
+
+                    recipeId += 1
+                    recipe = layerindexlib.Recipe(index, None)
+                    recipe.define_data(id=recipeId,
+                                   filename=filename, filepath=filepath,
+                                   pn=pn, pv=pv,
+                                   summary=pn, description=pn, section='?',
+                                   license='?', homepage='?', bugtracker='?',
+                                   provides='?', bbclassextend='?', inherits='?',
+                                   blacklisted='?', layerbranch=depBranchId)
+
+                    index = addElement("recipes", [recipe], index)
+
+        # ("machines", layerindexlib.Machine)
+        machineId = 0
+        if 'machines' in load:
+            index.machines = {}
+
+            for layerBranchId in index.layerBranches:
+                # load_bblayers uses the description to cache the actual path...
+                machine_path = index.layerBranches[layerBranchId].layer.description
+                machine_path = os.path.join(machine_path, 'conf/machine')
+                if os.path.isdir(machine_path):
+                    for (dirpath, _, filenames) in os.walk(machine_path):
+                        # Ignore subdirs...
+                        if not dirpath.endswith('conf/machine'):
+                            continue
+                        for fname in filenames:
+                            if fname.endswith('.conf'):
+                                machineId += 1
+                                machine = layerindexlib.Machine(index, None)
+                                machine.define_data(id=machineId, name=fname[:-5],
+                                                    description=fname[:-5],
+                                                    layerbranch=index.layerBranches[layerBranchId])
+
+                                index.add_element("machines", [machine])
+
+        # ("distros", layerindexlib.Distro)
+        distroId = 0
+        if 'distros' in load:
+            index.distros = {}
+
+            for layerBranchId in index.layerBranches:
+                # load_bblayers uses the description to cache the actual path...
+                distro_path = index.layerBranches[layerBranchId].layer.description
+                distro_path = os.path.join(distro_path, 'conf/distro')
+                if os.path.isdir(distro_path):
+                    for (dirpath, _, filenames) in os.walk(distro_path):
+                        # Ignore subdirs...
+                        if not dirpath.endswith('conf/distro'):
+                            continue
+                        for fname in filenames:
+                            if fname.endswith('.conf'):
+                                distroId += 1
+                                distro = layerindexlib.Distro(index, None)
+                                distro.define_data(id=distroId, name=fname[:-5],
+                                                    description=fname[:-5],
+                                                    layerbranch=index.layerBranches[layerBranchId])
+
+                                index.add_element("distros", [distro])
+
+        return index
diff --git a/poky/bitbake/lib/layerindexlib/plugin.py b/poky/bitbake/lib/layerindexlib/plugin.py
new file mode 100644
index 0000000..92a2e97
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/plugin.py
@@ -0,0 +1,60 @@
+# Copyright (C) 2016-2018 Wind River Systems, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License version 2 as
+# published by the Free Software Foundation.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+# The file contains:
+#   LayerIndex exceptions
+#   Plugin base class
+#   Utility Functions for working on layerindex data
+
+import argparse
+import logging
+import os
+import bb.msg
+
+logger = logging.getLogger('BitBake.layerindexlib.plugin')
+
+class LayerIndexPluginException(Exception):
+    """LayerIndex Generic Exception"""
+    def __init__(self, message):
+         self.msg = message
+         Exception.__init__(self, message)
+
+    def __str__(self):
+         return self.msg
+
+class LayerIndexPluginUrlError(LayerIndexPluginException):
+    """Exception raised when a plugin does not support a given URL type"""
+    def __init__(self, plugin, url):
+        msg = "%s does not support %s:" % (plugin, url)
+        self.plugin = plugin
+        self.url = url
+        LayerIndexPluginException.__init__(self, msg)
+
+class IndexPlugin():
+    def __init__(self):
+        self.type = None
+
+    def init(self, layerindex):
+        self.layerindex = layerindex
+
+    def plugin_type(self):
+        return self.type
+
+    def load_index(self, uri):
+        raise NotImplementedError('load_index is not implemented')
+
+    def store_index(self, uri, index):
+        raise NotImplementedError('store_index is not implemented')
+
diff --git a/poky/bitbake/lib/layerindexlib/restapi.py b/poky/bitbake/lib/layerindexlib/restapi.py
new file mode 100644
index 0000000..d08eb20
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/restapi.py
@@ -0,0 +1,398 @@
+# Copyright (C) 2016-2018 Wind River Systems, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License version 2 as
+# published by the Free Software Foundation.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+import logging
+import json
+from urllib.parse import unquote
+from urllib.parse import urlparse
+
+import layerindexlib
+import layerindexlib.plugin
+
+logger = logging.getLogger('BitBake.layerindexlib.restapi')
+
+def plugin_init(plugins):
+    return RestApiPlugin()
+
+class RestApiPlugin(layerindexlib.plugin.IndexPlugin):
+    def __init__(self):
+        self.type = "restapi"
+
+    def load_index(self, url, load):
+        """
+            Fetches layer information from a local or remote layer index.
+
+            The return value is a LayerIndexObj.
+
+            url is the url to the rest api of the layer index, such as:
+            http://layers.openembedded.org/layerindex/api/
+
+            Or a local file...
+        """
+
+        up = urlparse(url)
+
+        if up.scheme == 'file':
+            return self.load_index_file(up, url, load)
+
+        if up.scheme == 'http' or up.scheme == 'https':
+            return self.load_index_web(up, url, load)
+
+        raise layerindexlib.plugin.LayerIndexPluginUrlError(self.type, url)
+
+
+    def load_index_file(self, up, url, load):
+        """
+            Fetches layer information from a local file or directory.
+
+            The return value is a LayerIndexObj.
+
+            ud is the parsed url to the local file or directory.
+        """
+        if not os.path.exists(up.path):
+            raise FileNotFoundError(up.path)
+
+        index = layerindexlib.LayerIndexObj()
+
+        index.config = {}
+        index.config['TYPE'] = self.type
+        index.config['URL'] = url
+
+        params = self.layerindex._parse_params(up.params)
+
+        if 'desc' in params:
+            index.config['DESCRIPTION'] = unquote(params['desc'])
+        else:
+            index.config['DESCRIPTION'] = up.path
+
+        if 'cache' in params:
+            index.config['CACHE'] = params['cache']
+
+        if 'branch' in params:
+            branches = params['branch'].split(',')
+            index.config['BRANCH'] = branches
+        else:
+            branches = ['*']
+
+
+        def load_cache(path, index, branches=[]):
+            logger.debug(1, 'Loading json file %s' % path)
+            with open(path, 'rt', encoding='utf-8') as f:
+                pindex = json.load(f)
+
+            # Filter the branches on loaded files...
+            newpBranch = []
+            for branch in branches:
+                if branch != '*':
+                    if 'branches' in pindex:
+                        for br in pindex['branches']:
+                            if br['name'] == branch:
+                                newpBranch.append(br)
+                else:
+                    if 'branches' in pindex:
+                        for br in pindex['branches']:
+                            newpBranch.append(br)
+
+            if newpBranch:
+                index.add_raw_element('branches', layerindexlib.Branch, newpBranch)
+            else:
+                logger.debug(1, 'No matching branches (%s) in index file(s)' % branches)
+                # No matching branches.. return nothing...
+                return
+
+            for (lName, lType) in [("layerItems", layerindexlib.LayerItem),
+                                   ("layerBranches", layerindexlib.LayerBranch),
+                                   ("layerDependencies", layerindexlib.LayerDependency),
+                                   ("recipes", layerindexlib.Recipe),
+                                   ("machines", layerindexlib.Machine),
+                                   ("distros", layerindexlib.Distro)]:
+                if lName in pindex:
+                    index.add_raw_element(lName, lType, pindex[lName])
+
+
+        if not os.path.isdir(up.path):
+            load_cache(up.path, index, branches)
+            return index
+
+        logger.debug(1, 'Loading from dir %s...' % (up.path))
+        for (dirpath, _, filenames) in os.walk(up.path):
+            for filename in filenames:
+                if not filename.endswith('.json'):
+                    continue
+                fpath = os.path.join(dirpath, filename)
+                load_cache(fpath, index, branches)
+
+        return index
+
+
+    def load_index_web(self, up, url, load):
+        """
+            Fetches layer information from a remote layer index.
+
+            The return value is a LayerIndexObj.
+
+            ud is the parsed url to the rest api of the layer index, such as:
+            http://layers.openembedded.org/layerindex/api/
+        """
+
+        def _get_json_response(apiurl=None, username=None, password=None, retry=True):
+            assert apiurl is not None
+
+            logger.debug(1, "fetching %s" % apiurl)
+
+            up = urlparse(apiurl)
+
+            username=up.username
+            password=up.password
+
+            # Strip username/password and params
+            if up.port:
+                up_stripped = up._replace(params="", netloc="%s:%s" % (up.hostname, up.port))
+            else:
+                up_stripped = up._replace(params="", netloc=up.hostname)
+
+            res = self.layerindex._fetch_url(up_stripped.geturl(), username=username, password=password)
+
+            try:
+                parsed = json.loads(res.read().decode('utf-8'))
+            except ConnectionResetError:
+                if retry:
+                    logger.debug(1, "%s: Connection reset by peer.  Retrying..." % url)
+                    parsed = _get_json_response(apiurl=up_stripped.geturl(), username=username, password=password, retry=False)
+                    logger.debug(1, "%s: retry successful.")
+                else:
+                    raise LayerIndexFetchError('%s: Connection reset by peer.  Is there a firewall blocking your connection?' % apiurl)
+
+            return parsed
+
+        index = layerindexlib.LayerIndexObj()
+
+        index.config = {}
+        index.config['TYPE'] = self.type
+        index.config['URL'] = url
+
+        params = self.layerindex._parse_params(up.params)
+
+        if 'desc' in params:
+            index.config['DESCRIPTION'] = unquote(params['desc'])
+        else:
+            index.config['DESCRIPTION'] = up.hostname
+
+        if 'cache' in params:
+            index.config['CACHE'] = params['cache']
+
+        if 'branch' in params:
+            branches = params['branch'].split(',')
+            index.config['BRANCH'] = branches
+        else:
+            branches = ['*']
+
+        try:
+            index.apilinks = _get_json_response(apiurl=url, username=up.username, password=up.password)
+        except Exception as e:
+            raise layerindexlib.LayerIndexFetchError(url, e)
+
+        # Local raw index set...
+        pindex = {}
+
+        # Load all the requested branches at the same time time,
+        # a special branch of '*' means load all branches
+        filter = ""
+        if "*" not in branches:
+            filter = "?filter=name:%s" % "OR".join(branches)
+
+        logger.debug(1, "Loading %s from %s" % (branches, index.apilinks['branches']))
+
+        # The link won't include username/password, so pull it from the original url
+        pindex['branches'] = _get_json_response(index.apilinks['branches'] + filter,
+                                                    username=up.username, password=up.password)
+        if not pindex['branches']:
+            logger.debug(1, "No valid branches (%s) found at url %s." % (branch, url))
+            return index
+        index.add_raw_element("branches", layerindexlib.Branch, pindex['branches'])
+
+        # Load all of the layerItems (these can not be easily filtered)
+        logger.debug(1, "Loading %s from %s" % ('layerItems', index.apilinks['layerItems']))
+
+
+        # The link won't include username/password, so pull it from the original url
+        pindex['layerItems'] = _get_json_response(index.apilinks['layerItems'],
+                                                  username=up.username, password=up.password)
+        if not pindex['layerItems']:
+            logger.debug(1, "No layers were found at url %s." % (url))
+            return index
+        index.add_raw_element("layerItems", layerindexlib.LayerItem, pindex['layerItems'])
+
+
+	# From this point on load the contents for each branch.  Otherwise we
+	# could run into a timeout.
+        for branch in index.branches:
+            filter = "?filter=branch__name:%s" % index.branches[branch].name
+
+            logger.debug(1, "Loading %s from %s" % ('layerBranches', index.apilinks['layerBranches']))
+
+            # The link won't include username/password, so pull it from the original url
+            pindex['layerBranches'] = _get_json_response(index.apilinks['layerBranches'] + filter,
+                                                  username=up.username, password=up.password)
+            if not pindex['layerBranches']:
+                logger.debug(1, "No valid layer branches (%s) found at url %s." % (branches or "*", url))
+                return index
+            index.add_raw_element("layerBranches", layerindexlib.LayerBranch, pindex['layerBranches'])
+
+
+            # Load the rest, they all have a similar format
+            # Note: the layer index has a few more items, we can add them if necessary
+            # in the future.
+            filter = "?filter=layerbranch__branch__name:%s" % index.branches[branch].name
+            for (lName, lType) in [("layerDependencies", layerindexlib.LayerDependency),
+                                   ("recipes", layerindexlib.Recipe),
+                                   ("machines", layerindexlib.Machine),
+                                   ("distros", layerindexlib.Distro)]:
+                if lName not in load:
+                    continue
+                logger.debug(1, "Loading %s from %s" % (lName, index.apilinks[lName]))
+
+                # The link won't include username/password, so pull it from the original url
+                pindex[lName] = _get_json_response(index.apilinks[lName] + filter,
+                                            username=up.username, password=up.password)
+                index.add_raw_element(lName, lType, pindex[lName])
+
+        return index
+
+    def store_index(self, url, index):
+        """
+            Store layer information into a local file/dir.
+
+            The return value is a dictionary containing API,
+            layer, branch, dependency, recipe, machine, distro, information.
+
+            ud is a parsed url to a directory or file.  If the path is a
+            directory, we will split the files into one file per layer.
+            If the path is to a file (exists or not) the entire DB will be
+            dumped into that one file.
+        """
+
+        up = urlparse(url)
+
+        if up.scheme != 'file':
+            raise layerindexlib.plugin.LayerIndexPluginUrlError(self.type, url)
+
+        logger.debug(1, "Storing to %s..." % up.path)
+
+        try:
+            layerbranches = index.layerBranches
+        except KeyError:
+            logger.error('No layerBranches to write.')
+            return
+
+
+        def filter_item(layerbranchid, objects):
+            filtered = []
+            for obj in getattr(index, objects, None):
+                try:
+                    if getattr(index, objects)[obj].layerbranch_id == layerbranchid:
+                       filtered.append(getattr(index, objects)[obj]._data)
+                except AttributeError:
+                    logger.debug(1, 'No obj.layerbranch_id: %s' % objects)
+                    # No simple filter method, just include it...
+                    try:
+                        filtered.append(getattr(index, objects)[obj]._data)
+                    except AttributeError:
+                        logger.debug(1, 'No obj._data: %s %s' % (objects, type(obj)))
+                        filtered.append(obj)
+            return filtered
+
+
+        # Write out to a single file.
+        # Filter out unnecessary items, then sort as we write for determinism
+        if not os.path.isdir(up.path):
+            pindex = {}
+
+            pindex['branches'] = []
+            pindex['layerItems'] = []
+            pindex['layerBranches'] = []
+
+            for layerbranchid in layerbranches:
+                if layerbranches[layerbranchid].branch._data not in pindex['branches']:
+                    pindex['branches'].append(layerbranches[layerbranchid].branch._data)
+
+                if layerbranches[layerbranchid].layer._data not in pindex['layerItems']:
+                    pindex['layerItems'].append(layerbranches[layerbranchid].layer._data)
+
+                if layerbranches[layerbranchid]._data not in pindex['layerBranches']:
+                    pindex['layerBranches'].append(layerbranches[layerbranchid]._data)
+
+                for entry in index._index:
+                    # Skip local items, apilinks and items already processed
+                    if entry in index.config['local'] or \
+                       entry == 'apilinks' or \
+                       entry == 'branches' or \
+                       entry == 'layerBranches' or \
+                       entry == 'layerItems':
+                        continue
+                    if entry not in pindex:
+                        pindex[entry] = []
+                    pindex[entry].extend(filter_item(layerbranchid, entry))
+
+            bb.debug(1, 'Writing index to %s' % up.path)
+            with open(up.path, 'wt') as f:
+                json.dump(layerindexlib.sort_entry(pindex), f, indent=4)
+            return
+
+
+        # Write out to a directory one file per layerBranch
+        # Prepare all layer related items, to create a minimal file.
+        # We have to sort the entries as we write so they are deterministic
+        for layerbranchid in layerbranches:
+            pindex = {}
+
+            for entry in index._index:
+                # Skip local items, apilinks and items already processed
+                if entry in index.config['local'] or \
+                   entry == 'apilinks' or \
+                   entry == 'branches' or \
+                   entry == 'layerBranches' or \
+                   entry == 'layerItems':
+                    continue
+                pindex[entry] = filter_item(layerbranchid, entry)
+
+            # Add the layer we're processing as the first one...
+            pindex['branches'] = [layerbranches[layerbranchid].branch._data]
+            pindex['layerItems'] = [layerbranches[layerbranchid].layer._data]
+            pindex['layerBranches'] = [layerbranches[layerbranchid]._data]
+
+            # We also need to include the layerbranch for any dependencies...
+            for layerdep in pindex['layerDependencies']:
+                layerdependency = layerindexlib.LayerDependency(index, layerdep)
+
+                layeritem = layerdependency.dependency
+                layerbranch = layerdependency.dependency_layerBranch
+
+                # We need to avoid duplicates...
+                if layeritem._data not in pindex['layerItems']:
+                    pindex['layerItems'].append(layeritem._data)
+
+                if layerbranch._data not in pindex['layerBranches']:
+                    pindex['layerBranches'].append(layerbranch._data)
+
+            # apply mirroring adjustments here....
+
+            fname = index.config['DESCRIPTION'] + '__' + pindex['branches'][0]['name'] + '__' + pindex['layerItems'][0]['name']
+            fname = fname.translate(str.maketrans('/ ', '__'))
+            fpath = os.path.join(up.path, fname)
+
+            bb.debug(1, 'Writing index to %s' % fpath + '.json')
+            with open(fpath + '.json', 'wt') as f:
+                json.dump(layerindexlib.sort_entry(pindex), f, indent=4)
diff --git a/poky/bitbake/lib/layerindexlib/tests/__init__.py b/poky/bitbake/lib/layerindexlib/tests/__init__.py
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/tests/__init__.py
diff --git a/poky/bitbake/lib/layerindexlib/tests/common.py b/poky/bitbake/lib/layerindexlib/tests/common.py
new file mode 100644
index 0000000..22a5458
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/tests/common.py
@@ -0,0 +1,43 @@
+# Copyright (C) 2017-2018 Wind River Systems, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License version 2 as
+# published by the Free Software Foundation.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+import unittest
+import tempfile
+import os
+import bb
+
+import logging
+
+class LayersTest(unittest.TestCase):
+
+    def setUp(self):
+        self.origdir = os.getcwd()
+        self.d = bb.data.init()
+        # At least one variable needs to be set
+        self.d.setVar('DL_DIR', os.getcwd())
+
+        if os.environ.get("BB_SKIP_NETTESTS") == "yes":
+            self.d.setVar('BB_NO_NETWORK', '1')
+
+        self.tempdir = tempfile.mkdtemp()
+        self.logger = logging.getLogger("BitBake")
+
+    def tearDown(self):
+        os.chdir(self.origdir)
+        if os.environ.get("BB_TMPDIR_NOCLEAN") == "yes":
+            print("Not cleaning up %s. Please remove manually." % self.tempdir)
+        else:
+            bb.utils.prunedir(self.tempdir)
+
diff --git a/poky/bitbake/lib/layerindexlib/tests/cooker.py b/poky/bitbake/lib/layerindexlib/tests/cooker.py
new file mode 100644
index 0000000..fdbf091
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/tests/cooker.py
@@ -0,0 +1,123 @@
+# Copyright (C) 2018 Wind River Systems, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License version 2 as
+# published by the Free Software Foundation.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+import unittest
+import tempfile
+import os
+import bb
+
+import layerindexlib
+from layerindexlib.tests.common import LayersTest
+
+import logging
+
+class LayerIndexCookerTest(LayersTest):
+
+    def setUp(self):
+        LayersTest.setUp(self)
+
+        # Note this is NOT a comprehensive test of cooker, as we can't easily
+        # configure the test data.  But we can emulate the basics of the layer.conf
+        # files, so that is what we will do.
+
+        new_topdir = os.path.join(os.path.dirname(os.path.realpath(__file__)), "testdata")
+        new_bbpath = os.path.join(new_topdir, "build")
+
+        self.d.setVar('TOPDIR', new_topdir)
+        self.d.setVar('BBPATH', new_bbpath)
+
+        self.d = bb.parse.handle("%s/conf/bblayers.conf" % new_bbpath, self.d, True)
+        for layer in self.d.getVar('BBLAYERS').split():
+            self.d = bb.parse.handle("%s/conf/layer.conf" % layer, self.d, True)
+
+        self.layerindex = layerindexlib.LayerIndex(self.d)
+        self.layerindex.load_layerindex('cooker://', load=['layerDependencies'])
+
+    def test_layerindex_is_empty(self):
+        self.assertFalse(self.layerindex.is_empty(), msg="Layerindex is not empty!")
+
+    def test_dependency_resolution(self):
+        # Verify depth first searching...
+        (dependencies, invalidnames) = self.layerindex.find_dependencies(names=['meta-python'])
+
+        first = True
+        for deplayerbranch in dependencies:
+            layerBranch = dependencies[deplayerbranch][0]
+            layerDeps = dependencies[deplayerbranch][1:]
+
+            if not first:
+                continue
+
+            first = False
+
+            # Top of the deps should be openembedded-core, since everything depends on it.
+            self.assertEqual(layerBranch.layer.name, "openembedded-core", msg='Top dependency not openembedded-core')
+
+            # meta-python should cause an openembedded-core dependency, if not assert!
+            for dep in layerDeps:
+                if dep.layer.name == 'meta-python':
+                    break
+            else:
+                self.assertTrue(False, msg='meta-python was not found')
+
+            # Only check the first element...
+            break
+        else:
+            if first:
+                # Empty list, this is bad.
+                self.assertTrue(False, msg='Empty list of dependencies')
+
+            # Last dep should be the requested item
+            layerBranch = dependencies[deplayerbranch][0]
+            self.assertEqual(layerBranch.layer.name, "meta-python", msg='Last dependency not meta-python')
+
+    def test_find_collection(self):
+        def _check(collection, expected):
+            self.logger.debug(1, "Looking for collection %s..." % collection)
+            result = self.layerindex.find_collection(collection)
+            if expected:
+                self.assertIsNotNone(result, msg="Did not find %s when it shouldn't be there" % collection)
+            else:
+                self.assertIsNone(result, msg="Found %s when it should be there" % collection)
+
+        tests = [ ('core', True),
+                  ('openembedded-core', False),
+                  ('networking-layer', True),
+                  ('meta-python', True),
+                  ('openembedded-layer', True),
+                  ('notpresent', False) ]
+
+        for collection,result in tests:
+            _check(collection, result)
+
+    def test_find_layerbranch(self):
+        def _check(name, expected):
+            self.logger.debug(1, "Looking for layerbranch %s..." % name)
+            result = self.layerindex.find_layerbranch(name)
+            if expected:
+                self.assertIsNotNone(result, msg="Did not find %s when it shouldn't be there" % collection)
+            else:
+                self.assertIsNone(result, msg="Found %s when it should be there" % collection)
+
+        tests = [ ('openembedded-core', True),
+                  ('core', False),
+                  ('networking-layer', True),
+                  ('meta-python', True),
+                  ('openembedded-layer', True),
+                  ('notpresent', False) ]
+
+        for collection,result in tests:
+            _check(collection, result)
+
diff --git a/poky/bitbake/lib/layerindexlib/tests/layerindexobj.py b/poky/bitbake/lib/layerindexlib/tests/layerindexobj.py
new file mode 100644
index 0000000..e2fbb95
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/tests/layerindexobj.py
@@ -0,0 +1,226 @@
+# Copyright (C) 2017-2018 Wind River Systems, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License version 2 as
+# published by the Free Software Foundation.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+import unittest
+import tempfile
+import os
+import bb
+
+from layerindexlib.tests.common import LayersTest
+
+import logging
+
+class LayerIndexObjectsTest(LayersTest):
+    def setUp(self):
+        from layerindexlib import LayerIndexObj, Branch, LayerItem, LayerBranch, LayerDependency, Recipe, Machine, Distro
+
+        LayersTest.setUp(self)
+
+        self.index = LayerIndexObj()
+
+        branchId = 0
+        layerItemId = 0
+        layerBranchId = 0
+        layerDependencyId = 0
+        recipeId = 0
+        machineId = 0
+        distroId = 0
+
+        self.index.branches = {}
+        self.index.layerItems = {}
+        self.index.layerBranches = {}
+        self.index.layerDependencies = {}
+        self.index.recipes = {}
+        self.index.machines = {}
+        self.index.distros = {}
+
+        branchId += 1
+        self.index.branches[branchId] = Branch(self.index)
+        self.index.branches[branchId].define_data(branchId,
+                                        'test_branch', 'bb_test_branch')
+        self.index.branches[branchId].lockData()
+
+        layerItemId +=1
+        self.index.layerItems[layerItemId] = LayerItem(self.index)
+        self.index.layerItems[layerItemId].define_data(layerItemId,
+                                        'test_layerItem', vcs_url='git://git_test_url/test_layerItem')
+        self.index.layerItems[layerItemId].lockData()
+
+        layerBranchId +=1
+        self.index.layerBranches[layerBranchId] = LayerBranch(self.index)
+        self.index.layerBranches[layerBranchId].define_data(layerBranchId,
+                                        'test_collection', '99', layerItemId,
+                                        branchId)
+
+        recipeId += 1
+        self.index.recipes[recipeId] = Recipe(self.index)
+        self.index.recipes[recipeId].define_data(recipeId, 'test_git.bb',
+                                        'recipes-test', 'test', 'git',
+                                        layerBranchId)
+
+        machineId += 1
+        self.index.machines[machineId] = Machine(self.index)
+        self.index.machines[machineId].define_data(machineId,
+                                        'test_machine', 'test_machine',
+                                        layerBranchId)
+
+        distroId += 1
+        self.index.distros[distroId] = Distro(self.index)
+        self.index.distros[distroId].define_data(distroId,
+                                        'test_distro', 'test_distro',
+                                        layerBranchId)
+
+        layerItemId +=1
+        self.index.layerItems[layerItemId] = LayerItem(self.index)
+        self.index.layerItems[layerItemId].define_data(layerItemId, 'test_layerItem 2',
+                                        vcs_url='git://git_test_url/test_layerItem')
+
+        layerBranchId +=1
+        self.index.layerBranches[layerBranchId] = LayerBranch(self.index)
+        self.index.layerBranches[layerBranchId].define_data(layerBranchId,
+                                        'test_collection_2', '72', layerItemId,
+                                        branchId, actual_branch='some_other_branch')
+
+        layerDependencyId += 1
+        self.index.layerDependencies[layerDependencyId] = LayerDependency(self.index)
+        self.index.layerDependencies[layerDependencyId].define_data(layerDependencyId,
+                                        layerBranchId, 1)
+
+        layerDependencyId += 1
+        self.index.layerDependencies[layerDependencyId] = LayerDependency(self.index)
+        self.index.layerDependencies[layerDependencyId].define_data(layerDependencyId,
+                                        layerBranchId, 1, required=False)
+
+    def test_branch(self):
+        branch = self.index.branches[1]
+        self.assertEqual(branch.id, 1)
+        self.assertEqual(branch.name, 'test_branch')
+        self.assertEqual(branch.short_description, 'test_branch')
+        self.assertEqual(branch.bitbake_branch, 'bb_test_branch')
+
+    def test_layerItem(self):
+        layerItem = self.index.layerItems[1]
+        self.assertEqual(layerItem.id, 1)
+        self.assertEqual(layerItem.name, 'test_layerItem')
+        self.assertEqual(layerItem.summary, 'test_layerItem')
+        self.assertEqual(layerItem.description, 'test_layerItem')
+        self.assertEqual(layerItem.vcs_url, 'git://git_test_url/test_layerItem')
+        self.assertEqual(layerItem.vcs_web_url, None)
+        self.assertIsNone(layerItem.vcs_web_tree_base_url)
+        self.assertIsNone(layerItem.vcs_web_file_base_url)
+        self.assertIsNotNone(layerItem.updated)
+
+        layerItem = self.index.layerItems[2]
+        self.assertEqual(layerItem.id, 2)
+        self.assertEqual(layerItem.name, 'test_layerItem 2')
+        self.assertEqual(layerItem.summary, 'test_layerItem 2')
+        self.assertEqual(layerItem.description, 'test_layerItem 2')
+        self.assertEqual(layerItem.vcs_url, 'git://git_test_url/test_layerItem')
+        self.assertIsNone(layerItem.vcs_web_url)
+        self.assertIsNone(layerItem.vcs_web_tree_base_url)
+        self.assertIsNone(layerItem.vcs_web_file_base_url)
+        self.assertIsNotNone(layerItem.updated)
+
+    def test_layerBranch(self):
+        layerBranch = self.index.layerBranches[1]
+        self.assertEqual(layerBranch.id, 1)
+        self.assertEqual(layerBranch.collection, 'test_collection')
+        self.assertEqual(layerBranch.version, '99')
+        self.assertEqual(layerBranch.vcs_subdir, '')
+        self.assertEqual(layerBranch.actual_branch, 'test_branch')
+        self.assertIsNotNone(layerBranch.updated)
+        self.assertEqual(layerBranch.layer_id, 1)
+        self.assertEqual(layerBranch.branch_id, 1)
+        self.assertEqual(layerBranch.layer, self.index.layerItems[1])
+        self.assertEqual(layerBranch.branch, self.index.branches[1])
+
+        layerBranch = self.index.layerBranches[2]
+        self.assertEqual(layerBranch.id, 2)
+        self.assertEqual(layerBranch.collection, 'test_collection_2')
+        self.assertEqual(layerBranch.version, '72')
+        self.assertEqual(layerBranch.vcs_subdir, '')
+        self.assertEqual(layerBranch.actual_branch, 'some_other_branch')
+        self.assertIsNotNone(layerBranch.updated)
+        self.assertEqual(layerBranch.layer_id, 2)
+        self.assertEqual(layerBranch.branch_id, 1)
+        self.assertEqual(layerBranch.layer, self.index.layerItems[2])
+        self.assertEqual(layerBranch.branch, self.index.branches[1])
+
+    def test_layerDependency(self):
+        layerDependency = self.index.layerDependencies[1]
+        self.assertEqual(layerDependency.id, 1)
+        self.assertEqual(layerDependency.layerbranch_id, 2)
+        self.assertEqual(layerDependency.layerbranch, self.index.layerBranches[2])
+        self.assertEqual(layerDependency.layer_id, 2)
+        self.assertEqual(layerDependency.layer, self.index.layerItems[2])
+        self.assertTrue(layerDependency.required)
+        self.assertEqual(layerDependency.dependency_id, 1)
+        self.assertEqual(layerDependency.dependency, self.index.layerItems[1])
+        self.assertEqual(layerDependency.dependency_layerBranch, self.index.layerBranches[1])
+
+        layerDependency = self.index.layerDependencies[2]
+        self.assertEqual(layerDependency.id, 2)
+        self.assertEqual(layerDependency.layerbranch_id, 2)
+        self.assertEqual(layerDependency.layerbranch, self.index.layerBranches[2])
+        self.assertEqual(layerDependency.layer_id, 2)
+        self.assertEqual(layerDependency.layer, self.index.layerItems[2])
+        self.assertFalse(layerDependency.required)
+        self.assertEqual(layerDependency.dependency_id, 1)
+        self.assertEqual(layerDependency.dependency, self.index.layerItems[1])
+        self.assertEqual(layerDependency.dependency_layerBranch, self.index.layerBranches[1])
+
+    def test_recipe(self):
+        recipe = self.index.recipes[1]
+        self.assertEqual(recipe.id, 1)
+        self.assertEqual(recipe.layerbranch_id, 1)
+        self.assertEqual(recipe.layerbranch, self.index.layerBranches[1])
+        self.assertEqual(recipe.layer_id, 1)
+        self.assertEqual(recipe.layer, self.index.layerItems[1])
+        self.assertEqual(recipe.filename, 'test_git.bb')
+        self.assertEqual(recipe.filepath, 'recipes-test')
+        self.assertEqual(recipe.fullpath, 'recipes-test/test_git.bb')
+        self.assertEqual(recipe.summary, "")
+        self.assertEqual(recipe.description, "")
+        self.assertEqual(recipe.section, "")
+        self.assertEqual(recipe.pn, 'test')
+        self.assertEqual(recipe.pv, 'git')
+        self.assertEqual(recipe.license, "")
+        self.assertEqual(recipe.homepage, "")
+        self.assertEqual(recipe.bugtracker, "")
+        self.assertEqual(recipe.provides, "")
+        self.assertIsNotNone(recipe.updated)
+        self.assertEqual(recipe.inherits, "")
+
+    def test_machine(self):
+        machine = self.index.machines[1]
+        self.assertEqual(machine.id, 1)
+        self.assertEqual(machine.layerbranch_id, 1)
+        self.assertEqual(machine.layerbranch, self.index.layerBranches[1])
+        self.assertEqual(machine.layer_id, 1)
+        self.assertEqual(machine.layer, self.index.layerItems[1])
+        self.assertEqual(machine.name, 'test_machine')
+        self.assertEqual(machine.description, 'test_machine')
+        self.assertIsNotNone(machine.updated)
+
+    def test_distro(self):
+        distro = self.index.distros[1]
+        self.assertEqual(distro.id, 1)
+        self.assertEqual(distro.layerbranch_id, 1)
+        self.assertEqual(distro.layerbranch, self.index.layerBranches[1])
+        self.assertEqual(distro.layer_id, 1)
+        self.assertEqual(distro.layer, self.index.layerItems[1])
+        self.assertEqual(distro.name, 'test_distro')
+        self.assertEqual(distro.description, 'test_distro')
+        self.assertIsNotNone(distro.updated)
diff --git a/poky/bitbake/lib/layerindexlib/tests/restapi.py b/poky/bitbake/lib/layerindexlib/tests/restapi.py
new file mode 100644
index 0000000..5876695
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/tests/restapi.py
@@ -0,0 +1,184 @@
+# Copyright (C) 2017-2018 Wind River Systems, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License version 2 as
+# published by the Free Software Foundation.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+import unittest
+import tempfile
+import os
+import bb
+
+import layerindexlib
+from layerindexlib.tests.common import LayersTest
+
+import logging
+
+def skipIfNoNetwork():
+    if os.environ.get("BB_SKIP_NETTESTS") == "yes":
+        return unittest.skip("Network tests being skipped")
+    return lambda f: f
+
+class LayerIndexWebRestApiTest(LayersTest):
+
+    @skipIfNoNetwork()
+    def setUp(self):
+        self.assertFalse(os.environ.get("BB_SKIP_NETTESTS") == "yes", msg="BB_SKIP_NETTESTS set, but we tried to test anyway")
+        LayersTest.setUp(self)
+        self.layerindex = layerindexlib.LayerIndex(self.d)
+        self.layerindex.load_layerindex('http://layers.openembedded.org/layerindex/api/;branch=sumo', load=['layerDependencies'])
+
+    @skipIfNoNetwork()
+    def test_layerindex_is_empty(self):
+        self.assertFalse(self.layerindex.is_empty(), msg="Layerindex is empty")
+
+    @skipIfNoNetwork()
+    def test_layerindex_store_file(self):
+        self.layerindex.store_layerindex('file://%s/file.json' % self.tempdir, self.layerindex.indexes[0])
+
+        self.assertTrue(os.path.isfile('%s/file.json' % self.tempdir), msg="Temporary file was not created by store_layerindex")
+
+        reload = layerindexlib.LayerIndex(self.d)
+        reload.load_layerindex('file://%s/file.json' % self.tempdir)
+
+        self.assertFalse(reload.is_empty(), msg="Layerindex is empty")
+
+        # Calculate layerItems in original index that should NOT be in reload
+        layerItemNames = []
+        for itemId in self.layerindex.indexes[0].layerItems:
+            layerItemNames.append(self.layerindex.indexes[0].layerItems[itemId].name)
+
+        for layerBranchId in self.layerindex.indexes[0].layerBranches:
+            layerItemNames.remove(self.layerindex.indexes[0].layerBranches[layerBranchId].layer.name)
+
+        for itemId in reload.indexes[0].layerItems:
+            self.assertFalse(reload.indexes[0].layerItems[itemId].name in layerItemNames, msg="Item reloaded when it shouldn't have been")
+
+        # Compare the original to what we wrote...
+        for type in self.layerindex.indexes[0]._index:
+            if type == 'apilinks' or \
+               type == 'layerItems' or \
+               type in self.layerindex.indexes[0].config['local']:
+                continue
+            for id in getattr(self.layerindex.indexes[0], type):
+                self.logger.debug(1, "type %s" % (type))
+
+                self.assertTrue(id in getattr(reload.indexes[0], type), msg="Id number not in reloaded index")
+
+                self.logger.debug(1, "%s ? %s" % (getattr(self.layerindex.indexes[0], type)[id], getattr(reload.indexes[0], type)[id]))
+
+                self.assertEqual(getattr(self.layerindex.indexes[0], type)[id], getattr(reload.indexes[0], type)[id], msg="Reloaded contents different")
+
+    @skipIfNoNetwork()
+    def test_layerindex_store_split(self):
+        self.layerindex.store_layerindex('file://%s' % self.tempdir, self.layerindex.indexes[0])
+
+        reload = layerindexlib.LayerIndex(self.d)
+        reload.load_layerindex('file://%s' % self.tempdir)
+
+        self.assertFalse(reload.is_empty(), msg="Layer index is empty")
+
+        for type in self.layerindex.indexes[0]._index:
+            if type == 'apilinks' or \
+               type == 'layerItems' or \
+               type in self.layerindex.indexes[0].config['local']:
+                continue
+            for id in getattr(self.layerindex.indexes[0] ,type):
+                self.logger.debug(1, "type %s" % (type))
+
+                self.assertTrue(id in getattr(reload.indexes[0], type), msg="Id number missing from reloaded data")
+
+                self.logger.debug(1, "%s ? %s" % (getattr(self.layerindex.indexes[0] ,type)[id], getattr(reload.indexes[0], type)[id]))
+
+                self.assertEqual(getattr(self.layerindex.indexes[0] ,type)[id], getattr(reload.indexes[0], type)[id], msg="reloaded data does not match original")
+
+    @skipIfNoNetwork()
+    def test_dependency_resolution(self):
+        # Verify depth first searching...
+        (dependencies, invalidnames) = self.layerindex.find_dependencies(names=['meta-python'])
+
+        first = True
+        for deplayerbranch in dependencies:
+            layerBranch = dependencies[deplayerbranch][0]
+            layerDeps = dependencies[deplayerbranch][1:]
+
+            if not first:
+                continue
+
+            first = False
+
+            # Top of the deps should be openembedded-core, since everything depends on it.
+            self.assertEqual(layerBranch.layer.name, "openembedded-core", msg='OpenEmbedded-Core is no the first dependency')
+
+            # meta-python should cause an openembedded-core dependency, if not assert!
+            for dep in layerDeps:
+                if dep.layer.name == 'meta-python':
+                    break
+            else:
+                self.logger.debug(1, "meta-python was not found")
+                self.assetTrue(False)
+
+            # Only check the first element...
+            break
+        else:
+            # Empty list, this is bad.
+            self.logger.debug(1, "Empty list of dependencies")
+            self.assertIsNotNone(first, msg="Empty list of dependencies")
+
+            # Last dep should be the requested item
+            layerBranch = dependencies[deplayerbranch][0]
+            self.assertEqual(layerBranch.layer.name, "meta-python", msg="Last dependency not meta-python")
+
+    @skipIfNoNetwork()
+    def test_find_collection(self):
+        def _check(collection, expected):
+            self.logger.debug(1, "Looking for collection %s..." % collection)
+            result = self.layerindex.find_collection(collection)
+            if expected:
+                self.assertIsNotNone(result, msg="Did not find %s when it should be there" % collection)
+            else:
+                self.assertIsNone(result, msg="Found %s when it shouldn't be there" % collection)
+
+        tests = [ ('core', True),
+                  ('openembedded-core', False),
+                  ('networking-layer', True),
+                  ('meta-python', True),
+                  ('openembedded-layer', True),
+                  ('notpresent', False) ]
+
+        for collection,result in tests:
+            _check(collection, result)
+
+    @skipIfNoNetwork()
+    def test_find_layerbranch(self):
+        def _check(name, expected):
+            self.logger.debug(1, "Looking for layerbranch %s..." % name)
+
+            for index in self.layerindex.indexes:
+                for layerbranchid in index.layerBranches:
+                    self.logger.debug(1, "Present: %s" % index.layerBranches[layerbranchid].layer.name)
+            result = self.layerindex.find_layerbranch(name)
+            if expected:
+                self.assertIsNotNone(result, msg="Did not find %s when it should be there" % collection)
+            else:
+                self.assertIsNone(result, msg="Found %s when it shouldn't be there" % collection)
+
+        tests = [ ('openembedded-core', True),
+                  ('core', False),
+                  ('meta-networking', True),
+                  ('meta-python', True),
+                  ('meta-oe', True),
+                  ('notpresent', False) ]
+
+        for collection,result in tests:
+            _check(collection, result)
+
diff --git a/poky/bitbake/lib/layerindexlib/tests/testdata/README b/poky/bitbake/lib/layerindexlib/tests/testdata/README
new file mode 100644
index 0000000..36ab40b
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/tests/testdata/README
@@ -0,0 +1,11 @@
+This test data is used to verify the 'cooker' module of the layerindex.
+
+The module consists of a faux project bblayers.conf with four layers defined.
+
+layer1 - openembedded-core
+layer2 - networking-layer
+layer3 - meta-python
+layer4 - openembedded-layer (meta-oe)
+
+Since we do not have a fully populated cooker, we use this to test the
+basic index generation, and not any deep recipe based contents.
diff --git a/poky/bitbake/lib/layerindexlib/tests/testdata/build/conf/bblayers.conf b/poky/bitbake/lib/layerindexlib/tests/testdata/build/conf/bblayers.conf
new file mode 100644
index 0000000..40429b2
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/tests/testdata/build/conf/bblayers.conf
@@ -0,0 +1,15 @@
+LAYERSERIES_CORENAMES = "sumo"
+
+# LAYER_CONF_VERSION is increased each time build/conf/bblayers.conf
+# changes incompatibly
+LCONF_VERSION = "7"
+
+BBPATH = "${TOPDIR}"
+BBFILES ?= ""
+
+BBLAYERS ?= " \
+  ${TOPDIR}/layer1 \
+  ${TOPDIR}/layer2 \
+  ${TOPDIR}/layer3 \
+  ${TOPDIR}/layer4 \
+  "
diff --git a/poky/bitbake/lib/layerindexlib/tests/testdata/layer1/conf/layer.conf b/poky/bitbake/lib/layerindexlib/tests/testdata/layer1/conf/layer.conf
new file mode 100644
index 0000000..966d531
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/tests/testdata/layer1/conf/layer.conf
@@ -0,0 +1,17 @@
+# We have a conf and classes directory, add to BBPATH
+BBPATH .= ":${LAYERDIR}"
+# We have recipes-* directories, add to BBFILES
+BBFILES += "${LAYERDIR}/recipes-*/*/*.bb"
+
+BBFILE_COLLECTIONS += "core"
+BBFILE_PATTERN_core = "^${LAYERDIR}/"
+BBFILE_PRIORITY_core = "5"
+
+LAYERSERIES_CORENAMES = "sumo"
+
+# This should only be incremented on significant changes that will
+# cause compatibility issues with other layers
+LAYERVERSION_core = "11"
+LAYERSERIES_COMPAT_core = "sumo"
+
+BBLAYERS_LAYERINDEX_NAME_core = "openembedded-core"
diff --git a/poky/bitbake/lib/layerindexlib/tests/testdata/layer2/conf/layer.conf b/poky/bitbake/lib/layerindexlib/tests/testdata/layer2/conf/layer.conf
new file mode 100644
index 0000000..7569d1c
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/tests/testdata/layer2/conf/layer.conf
@@ -0,0 +1,20 @@
+# We have a conf and classes directory, add to BBPATH
+BBPATH .= ":${LAYERDIR}"
+
+# We have a packages directory, add to BBFILES
+BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \
+            ${LAYERDIR}/recipes-*/*/*.bbappend"
+
+BBFILE_COLLECTIONS += "networking-layer"
+BBFILE_PATTERN_networking-layer := "^${LAYERDIR}/"
+BBFILE_PRIORITY_networking-layer = "5"
+
+# This should only be incremented on significant changes that will
+# cause compatibility issues with other layers
+LAYERVERSION_networking-layer = "1"
+
+LAYERDEPENDS_networking-layer = "core"
+LAYERDEPENDS_networking-layer += "openembedded-layer"
+LAYERDEPENDS_networking-layer += "meta-python"
+
+LAYERSERIES_COMPAT_networking-layer = "sumo"
diff --git a/poky/bitbake/lib/layerindexlib/tests/testdata/layer3/conf/layer.conf b/poky/bitbake/lib/layerindexlib/tests/testdata/layer3/conf/layer.conf
new file mode 100644
index 0000000..7089071
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/tests/testdata/layer3/conf/layer.conf
@@ -0,0 +1,19 @@
+# We might have a conf and classes directory, append to BBPATH
+BBPATH .= ":${LAYERDIR}"
+
+# We have recipes directories, add to BBFILES
+BBFILES += "${LAYERDIR}/recipes*/*/*.bb ${LAYERDIR}/recipes*/*/*.bbappend"
+
+BBFILE_COLLECTIONS += "meta-python"
+BBFILE_PATTERN_meta-python := "^${LAYERDIR}/"
+BBFILE_PRIORITY_meta-python = "7"
+
+# This should only be incremented on significant changes that will
+# cause compatibility issues with other layers
+LAYERVERSION_meta-python = "1"
+
+LAYERDEPENDS_meta-python = "core openembedded-layer"
+
+LAYERSERIES_COMPAT_meta-python = "sumo"
+
+LICENSE_PATH += "${LAYERDIR}/licenses"
diff --git a/poky/bitbake/lib/layerindexlib/tests/testdata/layer4/conf/layer.conf b/poky/bitbake/lib/layerindexlib/tests/testdata/layer4/conf/layer.conf
new file mode 100644
index 0000000..6649ee0
--- /dev/null
+++ b/poky/bitbake/lib/layerindexlib/tests/testdata/layer4/conf/layer.conf
@@ -0,0 +1,22 @@
+# We have a conf and classes directory, append to BBPATH
+BBPATH .= ":${LAYERDIR}"
+
+# We have a recipes directory, add to BBFILES
+BBFILES += "${LAYERDIR}/recipes-*/*/*.bb ${LAYERDIR}/recipes-*/*/*.bbappend"
+
+BBFILE_COLLECTIONS += "openembedded-layer"
+BBFILE_PATTERN_openembedded-layer := "^${LAYERDIR}/"
+
+# Define the priority for recipes (.bb files) from this layer,
+# choosing carefully how this layer interacts with all of the
+# other layers.
+
+BBFILE_PRIORITY_openembedded-layer = "6"
+
+# This should only be incremented on significant changes that will
+# cause compatibility issues with other layers
+LAYERVERSION_openembedded-layer = "1"
+
+LAYERDEPENDS_openembedded-layer = "core"
+
+LAYERSERIES_COMPAT_openembedded-layer = "sumo"
diff --git a/poky/bitbake/lib/toaster/bldcontrol/localhostbecontroller.py b/poky/bitbake/lib/toaster/bldcontrol/localhostbecontroller.py
index 63b4187..9490635 100644
--- a/poky/bitbake/lib/toaster/bldcontrol/localhostbecontroller.py
+++ b/poky/bitbake/lib/toaster/bldcontrol/localhostbecontroller.py
@@ -27,8 +27,9 @@
 import time
 from django.db import transaction
 from django.db.models import Q
-from bldcontrol.models import BuildEnvironment, BRLayer, BRVariable, BRTarget, BRBitbake
-from orm.models import CustomImageRecipe, Layer, Layer_Version, ProjectLayer, ToasterSetting
+from bldcontrol.models import BuildEnvironment, BuildRequest, BRLayer, BRVariable, BRTarget, BRBitbake, Build
+from orm.models import CustomImageRecipe, Layer, Layer_Version, Project, ProjectLayer, ToasterSetting
+from orm.models import signal_runbuilds
 import subprocess
 
 from toastermain import settings
@@ -38,6 +39,8 @@
 import logging
 logger = logging.getLogger("toaster")
 
+install_dir = os.environ.get('TOASTER_DIR')
+
 from pprint import pprint, pformat
 
 class LocalhostBEController(BuildEnvironmentController):
@@ -87,10 +90,10 @@
         #logger.debug("localhostbecontroller: using HEAD checkout in %s" % local_checkout_path)
         return local_checkout_path
 
-
-    def setCloneStatus(self,bitbake,status,total,current):
+    def setCloneStatus(self,bitbake,status,total,current,repo_name):
         bitbake.req.build.repos_cloned=current
         bitbake.req.build.repos_to_clone=total
+        bitbake.req.build.progress_item=repo_name
         bitbake.req.build.save()
 
     def setLayers(self, bitbake, layers, targets):
@@ -100,6 +103,7 @@
 
         layerlist = []
         nongitlayerlist = []
+        layer_index = 0
         git_env = os.environ.copy()
         # (note: add custom environment settings here)
 
@@ -113,7 +117,7 @@
         if bitbake.giturl and bitbake.commit:
             gitrepos[(bitbake.giturl, bitbake.commit)] = []
             gitrepos[(bitbake.giturl, bitbake.commit)].append(
-                ("bitbake", bitbake.dirpath))
+                ("bitbake", bitbake.dirpath, 0))
 
         for layer in layers:
             # We don't need to git clone the layer for the CustomImageRecipe
@@ -124,12 +128,13 @@
             # If we have local layers then we don't need clone them
             # For local layers giturl will be empty
             if not layer.giturl:
-                nongitlayerlist.append(layer.layer_version.layer.local_source_dir)
+                nongitlayerlist.append( "%03d:%s" % (layer_index,layer.local_source_dir) )
                 continue
 
             if not (layer.giturl, layer.commit) in gitrepos:
                 gitrepos[(layer.giturl, layer.commit)] = []
-            gitrepos[(layer.giturl, layer.commit)].append( (layer.name, layer.dirpath) )
+            gitrepos[(layer.giturl, layer.commit)].append( (layer.name,layer.dirpath,layer_index) )
+            layer_index += 1
 
 
         logger.debug("localhostbecontroller, our git repos are %s" % pformat(gitrepos))
@@ -159,9 +164,9 @@
         # 3. checkout the repositories
         clone_count=0
         clone_total=len(gitrepos.keys())
-        self.setCloneStatus(bitbake,'Started',clone_total,clone_count)
+        self.setCloneStatus(bitbake,'Started',clone_total,clone_count,'')
         for giturl, commit in gitrepos.keys():
-            self.setCloneStatus(bitbake,'progress',clone_total,clone_count)
+            self.setCloneStatus(bitbake,'progress',clone_total,clone_count,gitrepos[(giturl, commit)][0][0])
             clone_count += 1
 
             localdirname = os.path.join(self.be.sourcedir, self.getGitCloneDirectory(giturl, commit))
@@ -172,8 +177,11 @@
                 try:
                     localremotes = self._shellcmd("git remote -v",
                                                   localdirname,env=git_env)
-                    if not giturl in localremotes and commit != 'HEAD':
-                        raise BuildSetupException("Existing git repository at %s, but with different remotes ('%s', expected '%s'). Toaster will not continue out of fear of damaging something." % (localdirname, ", ".join(localremotes.split("\n")), giturl))
+                    # NOTE: this nice-to-have check breaks when using git remaping to get past firewall
+                    #       Re-enable later with .gitconfig remapping checks
+                    #if not giturl in localremotes and commit != 'HEAD':
+                    #    raise BuildSetupException("Existing git repository at %s, but with different remotes ('%s', expected '%s'). Toaster will not continue out of fear of damaging something." % (localdirname, ", ".join(localremotes.split("\n")), giturl))
+                    pass
                 except ShellCmdException:
                     # our localdirname might not be a git repository
                     #- that's fine
@@ -205,16 +213,16 @@
                     self._shellcmd("git clone -b \"%s\" \"%s\" \"%s\" " % (bitbake.commit, bitbake.giturl, os.path.join(self.pokydirname, 'bitbake')),env=git_env)
 
             # verify our repositories
-            for name, dirpath in gitrepos[(giturl, commit)]:
+            for name, dirpath, index in gitrepos[(giturl, commit)]:
                 localdirpath = os.path.join(localdirname, dirpath)
-                logger.debug("localhostbecontroller: localdirpath expected '%s'" % localdirpath)
+                logger.debug("localhostbecontroller: localdirpath expects '%s'" % localdirpath)
                 if not os.path.exists(localdirpath):
                     raise BuildSetupException("Cannot find layer git path '%s' in checked out repository '%s:%s'. Aborting." % (localdirpath, giturl, commit))
 
                 if name != "bitbake":
-                    layerlist.append(localdirpath.rstrip("/"))
+                    layerlist.append("%03d:%s" % (index,localdirpath.rstrip("/")))
 
-        self.setCloneStatus(bitbake,'complete',clone_total,clone_count)
+        self.setCloneStatus(bitbake,'complete',clone_total,clone_count,'')
         logger.debug("localhostbecontroller: current layer list %s " % pformat(layerlist))
 
         # Resolve self.pokydirname if not resolved yet, consider the scenario
@@ -244,7 +252,7 @@
                     customrecipe, layers)
 
                 if os.path.isdir(custom_layer_path):
-                    layerlist.append(custom_layer_path)
+                    layerlist.append("%03d:%s" % (layer_index,custom_layer_path))
 
             except CustomImageRecipe.DoesNotExist:
                 continue  # not a custom recipe, skip
@@ -252,7 +260,11 @@
         layerlist.extend(nongitlayerlist)
         logger.debug("\n\nset layers gives this list %s" % pformat(layerlist))
         self.islayerset = True
-        return layerlist
+
+        # restore the order of layer list for bblayers.conf
+        layerlist.sort()
+        sorted_layerlist = [l[4:] for l in layerlist]
+        return sorted_layerlist
 
     def setup_custom_image_recipe(self, customrecipe, layers):
         """ Set up toaster-custom-images layer and recipe files """
@@ -322,31 +334,115 @@
 
     def triggerBuild(self, bitbake, layers, variables, targets, brbe):
         layers = self.setLayers(bitbake, layers, targets)
+        is_merged_attr = bitbake.req.project.merged_attr
+
+        git_env = os.environ.copy()
+        # (note: add custom environment settings here)
+        try:
+            # insure that the project init/build uses the selected bitbake, and not Toaster's
+            del git_env['TEMPLATECONF']
+            del git_env['BBBASEDIR']
+            del git_env['BUILDDIR']
+        except KeyError:
+            pass
 
         # init build environment from the clone
-        builddir = '%s-toaster-%d' % (self.be.builddir, bitbake.req.project.id)
+        if bitbake.req.project.builddir:
+            builddir = bitbake.req.project.builddir
+        else:
+            builddir = '%s-toaster-%d' % (self.be.builddir, bitbake.req.project.id)
         oe_init = os.path.join(self.pokydirname, 'oe-init-build-env')
         # init build environment
         try:
             custom_script = ToasterSetting.objects.get(name="CUSTOM_BUILD_INIT_SCRIPT").value
             custom_script = custom_script.replace("%BUILDDIR%" ,builddir)
-            self._shellcmd("bash -c 'source %s'" % (custom_script))
+            self._shellcmd("bash -c 'source %s'" % (custom_script),env=git_env)
         except ToasterSetting.DoesNotExist:
             self._shellcmd("bash -c 'source %s %s'" % (oe_init, builddir),
-                       self.be.sourcedir)
+                       self.be.sourcedir,env=git_env)
 
         # update bblayers.conf
-        bblconfpath = os.path.join(builddir, "conf/toaster-bblayers.conf")
-        with open(bblconfpath, 'w') as bblayers:
-            bblayers.write('# line added by toaster build control\n'
-                           'BBLAYERS = "%s"' % ' '.join(layers))
+        if not is_merged_attr:
+            bblconfpath = os.path.join(builddir, "conf/toaster-bblayers.conf")
+            with open(bblconfpath, 'w') as bblayers:
+                bblayers.write('# line added by toaster build control\n'
+                               'BBLAYERS = "%s"' % ' '.join(layers))
 
-        # write configuration file
-        confpath = os.path.join(builddir, 'conf/toaster.conf')
-        with open(confpath, 'w') as conf:
-            for var in variables:
-                conf.write('%s="%s"\n' % (var.name, var.value))
-            conf.write('INHERIT+="toaster buildhistory"')
+            # write configuration file
+            confpath = os.path.join(builddir, 'conf/toaster.conf')
+            with open(confpath, 'w') as conf:
+                for var in variables:
+                    conf.write('%s="%s"\n' % (var.name, var.value))
+                conf.write('INHERIT+="toaster buildhistory"')
+        else:
+            # Append the Toaster-specific values directly to the bblayers.conf
+            bblconfpath = os.path.join(builddir, "conf/bblayers.conf")
+            bblconfpath_save = os.path.join(builddir, "conf/bblayers.conf.save")
+            shutil.copyfile(bblconfpath, bblconfpath_save)
+            with open(bblconfpath) as bblayers:
+                content = bblayers.readlines()
+            do_write = True
+            was_toaster = False
+            with open(bblconfpath,'w') as bblayers:
+                for line in content:
+                    #line = line.strip('\n')
+                    if 'TOASTER_CONFIG_PROLOG' in line:
+                        do_write = False
+                        was_toaster = True
+                    elif 'TOASTER_CONFIG_EPILOG' in line:
+                        do_write = True
+                    elif do_write:
+                        bblayers.write(line)
+                if not was_toaster:
+                    bblayers.write('\n')
+                bblayers.write('#=== TOASTER_CONFIG_PROLOG ===\n')
+                bblayers.write('BBLAYERS = "\\\n')
+                for layer in layers:
+                    bblayers.write('  %s \\\n' % layer)
+                bblayers.write('  "\n')
+                bblayers.write('#=== TOASTER_CONFIG_EPILOG ===\n')
+            # Append the Toaster-specific values directly to the local.conf
+            bbconfpath = os.path.join(builddir, "conf/local.conf")
+            bbconfpath_save = os.path.join(builddir, "conf/local.conf.save")
+            shutil.copyfile(bbconfpath, bbconfpath_save)
+            with open(bbconfpath) as f:
+                content = f.readlines()
+            do_write = True
+            was_toaster = False
+            with open(bbconfpath,'w') as conf:
+                for line in content:
+                    #line = line.strip('\n')
+                    if 'TOASTER_CONFIG_PROLOG' in line:
+                        do_write = False
+                        was_toaster = True
+                    elif 'TOASTER_CONFIG_EPILOG' in line:
+                        do_write = True
+                    elif do_write:
+                        conf.write(line)
+                if not was_toaster:
+                    conf.write('\n')
+                conf.write('#=== TOASTER_CONFIG_PROLOG ===\n')
+                for var in variables:
+                    if (not var.name.startswith("INTERNAL_")) and (not var.name == "BBLAYERS"):
+                        conf.write('%s="%s"\n' % (var.name, var.value))
+                conf.write('#=== TOASTER_CONFIG_EPILOG ===\n')
+
+        # If 'target' is just the project preparation target, then we are done
+        for target in targets:
+            if "_PROJECT_PREPARE_" == target.target:
+                logger.debug('localhostbecontroller: Project has been prepared. Done.')
+                # Update the Build Request and release the build environment
+                bitbake.req.state = BuildRequest.REQ_COMPLETED
+                bitbake.req.save()
+                self.be.lock = BuildEnvironment.LOCK_FREE
+                self.be.save()
+                # Close the project build and progress bar
+                bitbake.req.build.outcome = Build.SUCCEEDED
+                bitbake.req.build.save()
+                # Update the project status
+                bitbake.req.project.set_variable(Project.PROJECT_SPECIFIC_STATUS,Project.PROJECT_SPECIFIC_CLONING_SUCCESS)
+                signal_runbuilds()
+                return
 
         # clean the Toaster to build environment
         env_clean = 'unset BBPATH;' # clean BBPATH for <= YP-2.4.0
@@ -360,16 +456,19 @@
             for path in os.environ["PATH"].split(os.pathsep):
                 if os.path.exists(os.path.join(path, 'bitbake')):
                     bitbake = os.path.join(path, 'bitbake')
-                    logger.info("Found Bitbake at: %s" % path)
                     break
             else:
                 logger.error("Looks like Bitbake is not available, please fix your environment")
 
-        # run bitbake server from the clone
         toasterlayers = os.path.join(builddir,"conf/toaster-bblayers.conf")
-        self._shellcmd('%s bash -c \"source %s %s; BITBAKE_UI="knotty" %s --read %s --read %s '
-                       '--server-only -B 0.0.0.0:0\"' % (env_clean, oe_init,
-                       builddir, bitbake, confpath, toasterlayers), self.be.sourcedir)
+        if not is_merged_attr:
+            self._shellcmd('%s bash -c \"source %s %s; BITBAKE_UI="knotty" %s --read %s --read %s '
+                           '--server-only -B 0.0.0.0:0\"' % (env_clean, oe_init,
+                           builddir, bitbake, confpath, toasterlayers), self.be.sourcedir)
+        else:
+            self._shellcmd('%s bash -c \"source %s %s; BITBAKE_UI="knotty" %s '
+                           '--server-only -B 0.0.0.0:0\"' % (env_clean, oe_init,
+                           builddir, bitbake), self.be.sourcedir)
 
         # read port number from bitbake.lock
         self.be.bbport = -1
@@ -415,12 +514,20 @@
         log = os.path.join(builddir, 'toaster_ui.log')
         local_bitbake = os.path.join(os.path.dirname(os.getenv('BBBASEDIR')),
                                      'bitbake')
-        self._shellcmd(['%s bash -c \"(TOASTER_BRBE="%s" BBSERVER="0.0.0.0:%s" '
+        if not is_merged_attr:
+            self._shellcmd(['%s bash -c \"(TOASTER_BRBE="%s" BBSERVER="0.0.0.0:%s" '
                         '%s %s -u toasterui  --read %s --read %s --token="" >>%s 2>&1;'
                         'BITBAKE_UI="knotty" BBSERVER=0.0.0.0:%s %s -m)&\"' \
                         % (env_clean, brbe, self.be.bbport, local_bitbake, bbtargets, confpath, toasterlayers, log,
                         self.be.bbport, bitbake,)],
                         builddir, nowait=True)
+        else:
+            self._shellcmd(['%s bash -c \"(TOASTER_BRBE="%s" BBSERVER="0.0.0.0:%s" '
+                        '%s %s -u toasterui  --token="" >>%s 2>&1;'
+                        'BITBAKE_UI="knotty" BBSERVER=0.0.0.0:%s %s -m)&\"' \
+                        % (env_clean, brbe, self.be.bbport, local_bitbake, bbtargets, log,
+                        self.be.bbport, bitbake,)],
+                        builddir, nowait=True)
 
         logger.debug('localhostbecontroller: Build launched, exiting. '
                      'Follow build logs at %s' % log)
diff --git a/poky/bitbake/lib/toaster/bldcontrol/management/commands/runbuilds.py b/poky/bitbake/lib/toaster/bldcontrol/management/commands/runbuilds.py
index 791e53e..6a55dd4 100644
--- a/poky/bitbake/lib/toaster/bldcontrol/management/commands/runbuilds.py
+++ b/poky/bitbake/lib/toaster/bldcontrol/management/commands/runbuilds.py
@@ -49,7 +49,7 @@
                 # we could not find a BEC; postpone the BR
                 br.state = BuildRequest.REQ_QUEUED
                 br.save()
-                logger.debug("runbuilds: No build env")
+                logger.debug("runbuilds: No build env (%s)" % e)
                 return
 
             logger.info("runbuilds: starting build %s, environment %s" %
diff --git a/poky/bitbake/lib/toaster/orm/fixtures/oe-core.xml b/poky/bitbake/lib/toaster/orm/fixtures/oe-core.xml
index d7ea78d..fec93ab 100644
--- a/poky/bitbake/lib/toaster/orm/fixtures/oe-core.xml
+++ b/poky/bitbake/lib/toaster/orm/fixtures/oe-core.xml
@@ -23,14 +23,14 @@
     <field type="CharField" name="branch">master</field>
   </object>
   <object model="orm.bitbakeversion" pk="4">
-    <field type="CharField" name="name">rocko</field>
+    <field type="CharField" name="name">thud</field>
     <field type="CharField" name="giturl">git://git.openembedded.org/bitbake</field>
-    <field type="CharField" name="branch">1.36</field>
+    <field type="CharField" name="branch">1.40</field>
   </object>
 
   <!-- Releases available -->
   <object model="orm.release" pk="1">
-    <field type="CharField" name="name">rocko</field>
+    <field type="CharField" name="name">sumo</field>
     <field type="CharField" name="description">Openembedded Sumo</field>
     <field rel="ManyToOneRel" to="orm.bitbakeversion" name="bitbake_version">1</field>
     <field type="CharField" name="branch_name">sumo</field>
@@ -51,11 +51,11 @@
     <field type="TextField" name="helptext">Toaster will run your builds using the tip of the &lt;a href=\"http://cgit.openembedded.org/openembedded-core/log/\"&gt;OpenEmbedded master&lt;/a&gt; branch.</field>
   </object>
   <object model="orm.release" pk="4">
-    <field type="CharField" name="name">rocko</field>
+    <field type="CharField" name="name">thud</field>
     <field type="CharField" name="description">Openembedded Rocko</field>
     <field rel="ManyToOneRel" to="orm.bitbakeversion" name="bitbake_version">1</field>
-    <field type="CharField" name="branch_name">rocko</field>
-    <field type="TextField" name="helptext">Toaster will run your builds using the tip of the &lt;a href=\"http://cgit.openembedded.org/openembedded-core/log/?h=rocko\"&gt;OpenEmbedded Rocko&lt;/a&gt; branch.</field>
+    <field type="CharField" name="branch_name">thud</field>
+    <field type="TextField" name="helptext">Toaster will run your builds using the tip of the &lt;a href=\"http://cgit.openembedded.org/openembedded-core/log/?h=thud\"&gt;OpenEmbedded Thud&lt;/a&gt; branch.</field>
   </object>
 
   <!-- Default layers for each release -->
diff --git a/poky/bitbake/lib/toaster/orm/fixtures/poky.xml b/poky/bitbake/lib/toaster/orm/fixtures/poky.xml
index 6c966da..fb9a771 100644
--- a/poky/bitbake/lib/toaster/orm/fixtures/poky.xml
+++ b/poky/bitbake/lib/toaster/orm/fixtures/poky.xml
@@ -26,9 +26,9 @@
     <field type="CharField" name="dirpath">bitbake</field>
   </object>
   <object model="orm.bitbakeversion" pk="4">
-    <field type="CharField" name="name">rocko</field>
+    <field type="CharField" name="name">thud</field>
     <field type="CharField" name="giturl">git://git.yoctoproject.org/poky</field>
-    <field type="CharField" name="branch">rocko</field>
+    <field type="CharField" name="branch">thud</field>
     <field type="CharField" name="dirpath">bitbake</field>
   </object>
 
@@ -57,10 +57,10 @@
   </object>
   <object model="orm.release" pk="4">
     <field type="CharField" name="name">rocko</field>
-    <field type="CharField" name="description">Yocto Project 2.4 "Rocko"</field>
+    <field type="CharField" name="description">Yocto Project 2.6 "Thud"</field>
     <field rel="ManyToOneRel" to="orm.bitbakeversion" name="bitbake_version">1</field>
-    <field type="CharField" name="branch_name">rocko</field>
-    <field type="TextField" name="helptext">Toaster will run your builds using the tip of the &lt;a href="http://git.yoctoproject.org/cgit/cgit.cgi/poky/log/?h=rocko"&gt;Yocto Project Rocko branch&lt;/a&gt;.</field>
+    <field type="CharField" name="branch_name">thud</field>
+    <field type="TextField" name="helptext">Toaster will run your builds using the tip of the &lt;a href="http://git.yoctoproject.org/cgit/cgit.cgi/poky/log/?h=thud"&gt;Yocto Project Thud branch&lt;/a&gt;.</field>
   </object>
 
   <!-- Default project layers for each release -->
diff --git a/poky/bitbake/lib/toaster/orm/management/commands/lsupdates.py b/poky/bitbake/lib/toaster/orm/management/commands/lsupdates.py
index efc6b3a..66114ff 100644
--- a/poky/bitbake/lib/toaster/orm/management/commands/lsupdates.py
+++ b/poky/bitbake/lib/toaster/orm/management/commands/lsupdates.py
@@ -29,7 +29,6 @@
 import os
 import sys
 
-import json
 import logging
 import threading
 import time
@@ -37,6 +36,18 @@
 
 DEFAULT_LAYERINDEX_SERVER = "http://layers.openembedded.org/layerindex/api/"
 
+# Add path to bitbake modules for layerindexlib
+# lib/toaster/orm/management/commands/lsupdates.py (abspath)
+# lib/toaster/orm/management/commands (dirname)
+# lib/toaster/orm/management (dirname)
+# lib/toaster/orm (dirname)
+# lib/toaster/ (dirname)
+# lib/ (dirname)
+path = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))))
+sys.path.insert(0, path)
+
+import layerindexlib
+
 
 class Spinner(threading.Thread):
     """ A simple progress spinner to indicate download/parsing is happening"""
@@ -86,45 +97,6 @@
             self.apiurl = ToasterSetting.objects.get(name = 'CUSTOM_LAYERINDEX_SERVER').value
 
         assert self.apiurl is not None
-        try:
-            from urllib.request import urlopen, URLError
-            from urllib.parse import urlparse
-        except ImportError:
-            from urllib2 import urlopen, URLError
-            from urlparse import urlparse
-
-        proxy_settings = os.environ.get("http_proxy", None)
-
-        def _get_json_response(apiurl=None):
-            if None == apiurl:
-                apiurl=self.apiurl
-            http_progress = Spinner()
-            http_progress.start()
-
-            _parsedurl = urlparse(apiurl)
-            path = _parsedurl.path
-
-            # logger.debug("Fetching %s", apiurl)
-            try:
-                res = urlopen(apiurl)
-            except URLError as e:
-                raise Exception("Failed to read %s: %s" % (path, e.reason))
-
-            parsed = json.loads(res.read().decode('utf-8'))
-
-            http_progress.stop()
-            return parsed
-
-        # verify we can get the basic api
-        try:
-            apilinks = _get_json_response()
-        except Exception as e:
-            import traceback
-            if proxy_settings is not None:
-                logger.info("EE: Using proxy %s" % proxy_settings)
-            logger.warning("EE: could not connect to %s, skipping update:"
-                           "%s\n%s" % (self.apiurl, e, traceback.format_exc()))
-            return
 
         # update branches; only those that we already have names listed in the
         # Releases table
@@ -133,112 +105,118 @@
         if len(whitelist_branch_names) == 0:
             raise Exception("Failed to make list of branches to fetch")
 
-        logger.info("Fetching metadata releases for %s",
+        logger.info("Fetching metadata for %s",
                     " ".join(whitelist_branch_names))
 
-        branches_info = _get_json_response(apilinks['branches'] +
-                                           "?filter=name:%s"
-                                           % "OR".join(whitelist_branch_names))
+        # We require a non-empty bb.data, but we can fake it with a dictionary
+        layerindex = layerindexlib.LayerIndex({"DUMMY" : "VALUE"})
+
+        http_progress = Spinner()
+        http_progress.start()
+
+        if whitelist_branch_names:
+            url_branches = ";branch=%s" % ','.join(whitelist_branch_names)
+        else:
+            url_branches = ""
+        layerindex.load_layerindex("%s%s" % (self.apiurl, url_branches))
+
+        http_progress.stop()
+
+        # We know we're only processing one entry, so we reference it here
+        # (this is cheating...)
+        index = layerindex.indexes[0]
 
         # Map the layer index branches to toaster releases
         li_branch_id_to_toaster_release = {}
 
-        total = len(branches_info)
-        for i, branch in enumerate(branches_info):
-            li_branch_id_to_toaster_release[branch['id']] = \
-                    Release.objects.get(name=branch['name'])
+        logger.info("Processing releases")
+
+        total = len(index.branches)
+        for i, id in enumerate(index.branches):
+            li_branch_id_to_toaster_release[id] = \
+                    Release.objects.get(name=index.branches[id].name)
             self.mini_progress("Releases", i, total)
 
         # keep a track of the layerindex (li) id mappings so that
         # layer_versions can be created for these layers later on
         li_layer_id_to_toaster_layer_id = {}
 
-        logger.info("Fetching layers")
+        logger.info("Processing layers")
 
-        layers_info = _get_json_response(apilinks['layerItems'])
-
-        total = len(layers_info)
-        for i, li in enumerate(layers_info):
+        total = len(index.layerItems)
+        for i, id in enumerate(index.layerItems):
             try:
-                l, created = Layer.objects.get_or_create(name=li['name'])
-                l.up_date = li['updated']
-                l.summary = li['summary']
-                l.description = li['description']
+                l, created = Layer.objects.get_or_create(name=index.layerItems[id].name)
+                l.up_date = index.layerItems[id].updated
+                l.summary = index.layerItems[id].summary
+                l.description = index.layerItems[id].description
 
                 if created:
                     # predefined layers in the fixtures (for example poky.xml)
                     # always preempt the Layer Index for these values
-                    l.vcs_url = li['vcs_url']
-                    l.vcs_web_url = li['vcs_web_url']
-                    l.vcs_web_tree_base_url = li['vcs_web_tree_base_url']
-                    l.vcs_web_file_base_url = li['vcs_web_file_base_url']
+                    l.vcs_url = index.layerItems[id].vcs_url
+                    l.vcs_web_url = index.layerItems[id].vcs_web_url
+                    l.vcs_web_tree_base_url = index.layerItems[id].vcs_web_tree_base_url
+                    l.vcs_web_file_base_url = index.layerItems[id].vcs_web_file_base_url
                 l.save()
             except Layer.MultipleObjectsReturned:
                 logger.info("Skipped %s as we found multiple layers and "
                             "don't know which to update" %
-                            li['name'])
+                            index.layerItems[id].name)
 
-            li_layer_id_to_toaster_layer_id[li['id']] = l.pk
+            li_layer_id_to_toaster_layer_id[id] = l.pk
 
             self.mini_progress("layers", i, total)
 
         # update layer_versions
-        logger.info("Fetching layer versions")
-        layerbranches_info = _get_json_response(
-            apilinks['layerBranches'] + "?filter=branch__name:%s" %
-            "OR".join(whitelist_branch_names))
+        logger.info("Processing layer versions")
 
         # Map Layer index layer_branch object id to
         # layer_version toaster object id
         li_layer_branch_id_to_toaster_lv_id = {}
 
-        total = len(layerbranches_info)
-        for i, lbi in enumerate(layerbranches_info):
+        total = len(index.layerBranches)
+        for i, id in enumerate(index.layerBranches):
             # release as defined by toaster map to layerindex branch
-            release = li_branch_id_to_toaster_release[lbi['branch']]
+            release = li_branch_id_to_toaster_release[index.layerBranches[id].branch_id]
 
             try:
                 lv, created = Layer_Version.objects.get_or_create(
                     layer=Layer.objects.get(
-                        pk=li_layer_id_to_toaster_layer_id[lbi['layer']]),
+                        pk=li_layer_id_to_toaster_layer_id[index.layerBranches[id].layer_id]),
                     release=release
                 )
             except KeyError:
                 logger.warning(
                     "No such layerindex layer referenced by layerbranch %d" %
-                    lbi['layer'])
+                    index.layerBranches[id].layer_id)
                 continue
 
             if created:
-                lv.release = li_branch_id_to_toaster_release[lbi['branch']]
-                lv.up_date = lbi['updated']
-                lv.commit = lbi['actual_branch']
-                lv.dirpath = lbi['vcs_subdir']
+                lv.release = li_branch_id_to_toaster_release[index.layerBranches[id].branch_id]
+                lv.up_date = index.layerBranches[id].updated
+                lv.commit = index.layerBranches[id].actual_branch
+                lv.dirpath = index.layerBranches[id].vcs_subdir
                 lv.save()
 
-            li_layer_branch_id_to_toaster_lv_id[lbi['id']] =\
+            li_layer_branch_id_to_toaster_lv_id[index.layerBranches[id].id] =\
                 lv.pk
             self.mini_progress("layer versions", i, total)
 
-        logger.info("Fetching layer version dependencies")
-        # update layer dependencies
-        layerdependencies_info = _get_json_response(
-            apilinks['layerDependencies'] +
-            "?filter=layerbranch__branch__name:%s" %
-            "OR".join(whitelist_branch_names))
+        logger.info("Processing layer version dependencies")
 
         dependlist = {}
-        for ldi in layerdependencies_info:
+        for id in index.layerDependencies:
             try:
                 lv = Layer_Version.objects.get(
-                    pk=li_layer_branch_id_to_toaster_lv_id[ldi['layerbranch']])
+                    pk=li_layer_branch_id_to_toaster_lv_id[index.layerDependencies[id].layerbranch_id])
             except Layer_Version.DoesNotExist as e:
                 continue
 
             if lv not in dependlist:
                 dependlist[lv] = []
             try:
-                layer_id = li_layer_id_to_toaster_layer_id[ldi['dependency']]
+                layer_id = li_layer_id_to_toaster_layer_id[index.layerDependencies[id].dependency_id]
 
                 dependlist[lv].append(
                     Layer_Version.objects.get(layer__pk=layer_id,
@@ -247,7 +225,7 @@
             except Layer_Version.DoesNotExist:
                 logger.warning("Cannot find layer version (ls:%s),"
                                "up_id:%s lv:%s" %
-                               (self, ldi['dependency'], lv))
+                               (self, index.layerDependencies[id].dependency_id, lv))
 
         total = len(dependlist)
         for i, lv in enumerate(dependlist):
@@ -258,73 +236,61 @@
             self.mini_progress("Layer version dependencies", i, total)
 
         # update Distros
-        logger.info("Fetching distro information")
-        distros_info = _get_json_response(
-            apilinks['distros'] + "?filter=layerbranch__branch__name:%s" %
-            "OR".join(whitelist_branch_names))
+        logger.info("Processing distro information")
 
-        total = len(distros_info)
-        for i, di in enumerate(distros_info):
+        total = len(index.distros)
+        for i, id in enumerate(index.distros):
             distro, created = Distro.objects.get_or_create(
-                name=di['name'],
+                name=index.distros[id].name,
                 layer_version=Layer_Version.objects.get(
-                    pk=li_layer_branch_id_to_toaster_lv_id[di['layerbranch']]))
-            distro.up_date = di['updated']
-            distro.name = di['name']
-            distro.description = di['description']
+                    pk=li_layer_branch_id_to_toaster_lv_id[index.distros[id].layerbranch_id]))
+            distro.up_date = index.distros[id].updated
+            distro.name = index.distros[id].name
+            distro.description = index.distros[id].description
             distro.save()
             self.mini_progress("distros", i, total)
 
         # update machines
-        logger.info("Fetching machine information")
-        machines_info = _get_json_response(
-            apilinks['machines'] + "?filter=layerbranch__branch__name:%s" %
-            "OR".join(whitelist_branch_names))
+        logger.info("Processing machine information")
 
-        total = len(machines_info)
-        for i, mi in enumerate(machines_info):
+        total = len(index.machines)
+        for i, id in enumerate(index.machines):
             mo, created = Machine.objects.get_or_create(
-                name=mi['name'],
+                name=index.machines[id].name,
                 layer_version=Layer_Version.objects.get(
-                    pk=li_layer_branch_id_to_toaster_lv_id[mi['layerbranch']]))
-            mo.up_date = mi['updated']
-            mo.name = mi['name']
-            mo.description = mi['description']
+                    pk=li_layer_branch_id_to_toaster_lv_id[index.machines[id].layerbranch_id]))
+            mo.up_date = index.machines[id].updated
+            mo.name = index.machines[id].name
+            mo.description = index.machines[id].description
             mo.save()
             self.mini_progress("machines", i, total)
 
         # update recipes; paginate by layer version / layer branch
-        logger.info("Fetching recipe information")
-        recipes_info = _get_json_response(
-            apilinks['recipes'] + "?filter=layerbranch__branch__name:%s" %
-            "OR".join(whitelist_branch_names))
+        logger.info("Processing recipe information")
 
-        total = len(recipes_info)
-        for i, ri in enumerate(recipes_info):
+        total = len(index.recipes)
+        for i, id in enumerate(index.recipes):
             try:
-                lv_id = li_layer_branch_id_to_toaster_lv_id[ri['layerbranch']]
+                lv_id = li_layer_branch_id_to_toaster_lv_id[index.recipes[id].layerbranch_id]
                 lv = Layer_Version.objects.get(pk=lv_id)
 
                 ro, created = Recipe.objects.get_or_create(
                     layer_version=lv,
-                    name=ri['pn']
+                    name=index.recipes[id].pn
                 )
 
                 ro.layer_version = lv
-                ro.up_date = ri['updated']
-                ro.name = ri['pn']
-                ro.version = ri['pv']
-                ro.summary = ri['summary']
-                ro.description = ri['description']
-                ro.section = ri['section']
-                ro.license = ri['license']
-                ro.homepage = ri['homepage']
-                ro.bugtracker = ri['bugtracker']
-                ro.file_path = ri['filepath'] + "/" + ri['filename']
-                if 'inherits' in ri:
-                    ro.is_image = 'image' in ri['inherits'].split()
-                else:  # workaround for old style layer index
-                    ro.is_image = "-image-" in ri['pn']
+                ro.up_date = index.recipes[id].updated
+                ro.name = index.recipes[id].pn
+                ro.version = index.recipes[id].pv
+                ro.summary = index.recipes[id].summary
+                ro.description = index.recipes[id].description
+                ro.section = index.recipes[id].section
+                ro.license = index.recipes[id].license
+                ro.homepage = index.recipes[id].homepage
+                ro.bugtracker = index.recipes[id].bugtracker
+                ro.file_path = index.recipes[id].fullpath
+                ro.is_image = 'image' in index.recipes[id].inherits.split()
                 ro.save()
             except Exception as e:
                 logger.warning("Failed saving recipe %s", e)
diff --git a/poky/bitbake/lib/toaster/orm/migrations/0018_project_specific.py b/poky/bitbake/lib/toaster/orm/migrations/0018_project_specific.py
new file mode 100644
index 0000000..084ecad
--- /dev/null
+++ b/poky/bitbake/lib/toaster/orm/migrations/0018_project_specific.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+from __future__ import unicode_literals
+
+from django.db import migrations, models
+
+class Migration(migrations.Migration):
+
+    dependencies = [
+        ('orm', '0017_distro_clone'),
+    ]
+
+    operations = [
+        migrations.AddField(
+            model_name='Project',
+            name='builddir',
+            field=models.TextField(),
+        ),
+        migrations.AddField(
+            model_name='Project',
+            name='merged_attr',
+            field=models.BooleanField(default=False)
+        ),
+        migrations.AddField(
+            model_name='Build',
+            name='progress_item',
+            field=models.CharField(max_length=40)
+        ),
+    ]
diff --git a/poky/bitbake/lib/toaster/orm/models.py b/poky/bitbake/lib/toaster/orm/models.py
index 4b77e8f..7720290 100644
--- a/poky/bitbake/lib/toaster/orm/models.py
+++ b/poky/bitbake/lib/toaster/orm/models.py
@@ -121,8 +121,15 @@
 
 
 class ProjectManager(models.Manager):
-    def create_project(self, name, release):
-        if release is not None:
+    def create_project(self, name, release, existing_project=None):
+        if existing_project and (release is not None):
+            prj = existing_project
+            prj.bitbake_version = release.bitbake_version
+            prj.release = release
+            # Delete the previous ProjectLayer mappings
+            for pl in ProjectLayer.objects.filter(project=prj):
+                pl.delete()
+        elif release is not None:
             prj = self.model(name=name,
                              bitbake_version=release.bitbake_version,
                              release=release)
@@ -130,15 +137,14 @@
             prj = self.model(name=name,
                              bitbake_version=None,
                              release=None)
-
         prj.save()
 
         for defaultconf in ToasterSetting.objects.filter(
                 name__startswith="DEFCONF_"):
             name = defaultconf.name[8:]
-            ProjectVariable.objects.create(project=prj,
-                                           name=name,
-                                           value=defaultconf.value)
+            pv,create = ProjectVariable.objects.get_or_create(project=prj,name=name)
+            pv.value = defaultconf.value
+            pv.save()
 
         if release is None:
             return prj
@@ -197,6 +203,11 @@
     user_id = models.IntegerField(null=True)
     objects = ProjectManager()
 
+    # build directory override (e.g. imported)
+    builddir = models.TextField()
+    # merge the Toaster configure attributes directly into the standard conf files
+    merged_attr = models.BooleanField(default=False)
+
     # set to True for the project which is the default container
     # for builds initiated by the command line etc.
     is_default= models.BooleanField(default=False)
@@ -305,6 +316,15 @@
             return layer_versions
 
 
+    def get_default_image_recipe(self):
+        try:
+            return self.projectvariable_set.get(name="DEFAULT_IMAGE").value
+        except (ProjectVariable.DoesNotExist,IndexError):
+            return None;
+
+    def get_is_new(self):
+        return self.get_variable(Project.PROJECT_SPECIFIC_ISNEW)
+
     def get_available_machines(self):
         """ Returns QuerySet of all Machines which are provided by the
         Layers currently added to the Project """
@@ -353,6 +373,32 @@
 
         return queryset
 
+    # Project Specific status management
+    PROJECT_SPECIFIC_STATUS = 'INTERNAL_PROJECT_SPECIFIC_STATUS'
+    PROJECT_SPECIFIC_CALLBACK = 'INTERNAL_PROJECT_SPECIFIC_CALLBACK'
+    PROJECT_SPECIFIC_ISNEW = 'INTERNAL_PROJECT_SPECIFIC_ISNEW'
+    PROJECT_SPECIFIC_DEFAULTIMAGE = 'PROJECT_SPECIFIC_DEFAULTIMAGE'
+    PROJECT_SPECIFIC_NONE = ''
+    PROJECT_SPECIFIC_NEW = '1'
+    PROJECT_SPECIFIC_EDIT = '2'
+    PROJECT_SPECIFIC_CLONING = '3'
+    PROJECT_SPECIFIC_CLONING_SUCCESS = '4'
+    PROJECT_SPECIFIC_CLONING_FAIL = '5'
+
+    def get_variable(self,variable,default_value = ''):
+        try:
+            return self.projectvariable_set.get(name=variable).value
+        except (ProjectVariable.DoesNotExist,IndexError):
+            return default_value
+
+    def set_variable(self,variable,value):
+        pv,create = ProjectVariable.objects.get_or_create(project = self, name = variable)
+        pv.value = value
+        pv.save()
+
+    def get_default_image(self):
+        return self.get_variable(Project.PROJECT_SPECIFIC_DEFAULTIMAGE)
+
     def schedule_build(self):
 
         from bldcontrol.models import BuildRequest, BRTarget, BRLayer
@@ -459,6 +505,9 @@
     # number of repos cloned so far for this build (default off)
     repos_cloned = models.IntegerField(default=1)
 
+    # Hint on current progress item
+    progress_item = models.CharField(max_length=40)
+
     @staticmethod
     def get_recent(project=None):
         """
@@ -1701,8 +1750,8 @@
         if base_recipe_path:
             base_recipe = open(base_recipe_path, 'r').read()
         else:
-            raise IOError("Based on recipe file not found: %s" %
-                          base_recipe_path)
+            # Pass back None to trigger error message to user
+            return None
 
         # Add a special case for when the recipe we have based a custom image
         # recipe on requires another recipe.
@@ -1828,7 +1877,7 @@
     description = models.CharField(max_length=255)
 
     def get_vcs_distro_file_link_url(self):
-        path = self.name+'.conf'
+        path = 'conf/distro/%s.conf' % self.name
         return self.layer_version.get_vcs_file_link_url(path)
 
     def __unicode__(self):
diff --git a/poky/bitbake/lib/toaster/toastergui/api.py b/poky/bitbake/lib/toaster/toastergui/api.py
index ab6ba69..564d595 100644
--- a/poky/bitbake/lib/toaster/toastergui/api.py
+++ b/poky/bitbake/lib/toaster/toastergui/api.py
@@ -22,7 +22,9 @@
 import re
 import logging
 import json
+import subprocess
 from collections import Counter
+from shutil import copyfile
 
 from orm.models import Project, ProjectTarget, Build, Layer_Version
 from orm.models import LayerVersionDependency, LayerSource, ProjectLayer
@@ -38,6 +40,18 @@
 from django.db.models import Q, F
 from django.db import Error
 from toastergui.templatetags.projecttags import filtered_filesizeformat
+from django.utils import timezone
+import pytz
+
+# development/debugging support
+verbose = 2
+def _log(msg):
+    if 1 == verbose:
+        print(msg)
+    elif 2 == verbose:
+        f1=open('/tmp/toaster.log', 'a')
+        f1.write("|" + msg + "|\n" )
+        f1.close()
 
 logger = logging.getLogger("toaster")
 
@@ -137,6 +151,130 @@
         return response
 
 
+class XhrProjectUpdate(View):
+
+    def get(self, request, *args, **kwargs):
+        return HttpResponse()
+
+    def post(self, request, *args, **kwargs):
+        """
+          Project Update
+
+          Entry point: /xhr_projectupdate/<project_id>
+          Method: POST
+
+          Args:
+              pid: pid of project to update
+
+          Returns:
+              {"error": "ok"}
+            or
+              {"error": <error message>}
+        """
+
+        project = Project.objects.get(pk=kwargs['pid'])
+        logger.debug("ProjectUpdateCallback:project.pk=%d,project.builddir=%s" % (project.pk,project.builddir))
+
+        if 'do_update' in request.POST:
+
+            # Extract any default image recipe
+            if 'default_image' in request.POST:
+                project.set_variable(Project.PROJECT_SPECIFIC_DEFAULTIMAGE,str(request.POST['default_image']))
+            else:
+                project.set_variable(Project.PROJECT_SPECIFIC_DEFAULTIMAGE,'')
+
+            logger.debug("ProjectUpdateCallback:Chain to the build request")
+
+            # Chain to the build request
+            xhrBuildRequest = XhrBuildRequest()
+            return xhrBuildRequest.post(request, *args, **kwargs)
+
+        logger.warning("ERROR:XhrProjectUpdate")
+        response = HttpResponse()
+        response.status_code = 500
+        return response
+
+class XhrSetDefaultImageUrl(View):
+
+    def get(self, request, *args, **kwargs):
+        return HttpResponse()
+
+    def post(self, request, *args, **kwargs):
+        """
+          Project Update
+
+          Entry point: /xhr_setdefaultimage/<project_id>
+          Method: POST
+
+          Args:
+              pid: pid of project to update default image
+
+          Returns:
+              {"error": "ok"}
+            or
+              {"error": <error message>}
+        """
+
+        project = Project.objects.get(pk=kwargs['pid'])
+        logger.debug("XhrSetDefaultImageUrl:project.pk=%d" % (project.pk))
+
+        # set any default image recipe
+        if 'targets' in request.POST:
+            default_target = str(request.POST['targets'])
+            project.set_variable(Project.PROJECT_SPECIFIC_DEFAULTIMAGE,default_target)
+            logger.debug("XhrSetDefaultImageUrl,project.pk=%d,project.builddir=%s" % (project.pk,project.builddir))
+            return error_response('ok')
+
+        logger.warning("ERROR:XhrSetDefaultImageUrl")
+        response = HttpResponse()
+        response.status_code = 500
+        return response
+
+
+#
+# Layer Management
+#
+# Rules for 'local_source_dir' layers
+#  * Layers must have a unique name in the Layers table
+#  * A 'local_source_dir' layer is supposed to be shared
+#    by all projects that use it, so that it can have the
+#    same logical name
+#  * Each project that uses a layer will have its own
+#    LayerVersion and Project Layer for it
+#  * During the Paroject delete process, when the last
+#    LayerVersion for a 'local_source_dir' layer is deleted
+#    then the Layer record is deleted to remove orphans
+#
+
+def scan_layer_content(layer,layer_version):
+    # if this is a local layer directory, we can immediately scan its content
+    if layer.local_source_dir:
+        try:
+            # recipes-*/*/*.bb
+            cmd = '%s %s' % ('ls', os.path.join(layer.local_source_dir,'recipes-*/*/*.bb'))
+            recipes_list = subprocess.Popen(cmd, shell=True, stdout=subprocess.PIPE,stderr=subprocess.STDOUT).stdout.read()
+            recipes_list = recipes_list.decode("utf-8").strip()
+            if recipes_list and 'No such' not in recipes_list:
+                for recipe in recipes_list.split('\n'):
+                    recipe_path = recipe[recipe.rfind('recipes-'):]
+                    recipe_name = recipe[recipe.rfind('/')+1:].replace('.bb','')
+                    recipe_ver = recipe_name.rfind('_')
+                    if recipe_ver > 0:
+                        recipe_name = recipe_name[0:recipe_ver]
+                    if recipe_name:
+                        ro, created = Recipe.objects.get_or_create(
+                            layer_version=layer_version,
+                            name=recipe_name
+                        )
+                        if created:
+                            ro.file_path = recipe_path
+                            ro.summary = 'Recipe %s from layer %s' % (recipe_name,layer.name)
+                            ro.description = ro.summary
+                        ro.save()
+
+        except Exception as e:
+            logger.warning("ERROR:scan_layer_content: %s" % e)
+
 class XhrLayer(View):
     """ Delete, Get, Add and Update Layer information
 
@@ -265,6 +403,7 @@
             (csv)]
 
         """
+
         try:
             project = Project.objects.get(pk=kwargs['pid'])
 
@@ -285,7 +424,13 @@
             if layer_data['name'] in existing_layers:
                 return JsonResponse({"error": "layer-name-exists"})
 
-            layer = Layer.objects.create(name=layer_data['name'])
+            if ('local_source_dir' in layer_data):
+                # Local layer can be shared across projects. They have no 'release'
+                # and are not included in get_all_compatible_layer_versions() above
+                layer,created = Layer.objects.get_or_create(name=layer_data['name'])
+                _log("Local Layer created=%s" % created)
+            else:
+                layer = Layer.objects.create(name=layer_data['name'])
 
             layer_version = Layer_Version.objects.create(
                 layer=layer,
@@ -293,7 +438,7 @@
                 layer_source=LayerSource.TYPE_IMPORTED)
 
             # Local layer
-            if ('local_source_dir' in layer_data) and layer.local_source_dir:
+            if ('local_source_dir' in layer_data): ### and layer.local_source_dir:
                 layer.local_source_dir = layer_data['local_source_dir']
             # git layer
             elif 'vcs_url' in layer_data:
@@ -325,6 +470,9 @@
                              'layerdetailurl':
                              layer_dep.get_detailspage_url(project.pk)})
 
+            # Scan the layer's content and update components
+            scan_layer_content(layer,layer_version)
+
         except Layer_Version.DoesNotExist:
             return error_response("layer-dep-not-found")
         except Project.DoesNotExist:
@@ -529,7 +677,13 @@
         recipe_path = os.path.join(layerpath, "recipes", "%s.bb" %
                                    recipe.name)
         with open(recipe_path, "w") as recipef:
-            recipef.write(recipe.generate_recipe_file_contents())
+            content = recipe.generate_recipe_file_contents()
+            if not content:
+                # Delete this incomplete image recipe object
+                recipe.delete()
+                return error_response("recipe-parent-not-exist")
+            else:
+                recipef.write(recipe.generate_recipe_file_contents())
 
         return JsonResponse(
             {"error": "ok",
@@ -1014,8 +1168,24 @@
                     state=BuildRequest.REQ_INPROGRESS):
                 XhrBuildRequest.cancel_build(br)
 
+            # gather potential orphaned local layers attached to this project
+            project_local_layer_list = []
+            for pl in ProjectLayer.objects.filter(project=project):
+                if pl.layercommit.layer_source == LayerSource.TYPE_IMPORTED:
+                    project_local_layer_list.append(pl.layercommit.layer)
+
+            # deep delete the project and its dependencies
             project.delete()
 
+            # delete any local layers now orphaned
+            _log("LAYER_ORPHAN_CHECK:Check for orphaned layers")
+            for layer in project_local_layer_list:
+                layer_refs = Layer_Version.objects.filter(layer=layer)
+                _log("LAYER_ORPHAN_CHECK:Ref Count for '%s' = %d" % (layer.name,len(layer_refs)))
+                if 0 == len(layer_refs):
+                    _log("LAYER_ORPHAN_CHECK:DELETE orpahned '%s'" % (layer.name))
+                    Layer.objects.filter(pk=layer.id).delete()
+
         except Project.DoesNotExist:
             return error_response("Project %s does not exist" %
                                   kwargs['project_id'])
diff --git a/poky/bitbake/lib/toaster/toastergui/static/js/layerBtn.js b/poky/bitbake/lib/toaster/toastergui/static/js/layerBtn.js
index 9f9eda1..a5a6563 100644
--- a/poky/bitbake/lib/toaster/toastergui/static/js/layerBtn.js
+++ b/poky/bitbake/lib/toaster/toastergui/static/js/layerBtn.js
@@ -67,6 +67,18 @@
       });
   });
 
+  $("td .set-default-recipe-btn").unbind('click');
+  $("td .set-default-recipe-btn").click(function(e){
+    e.preventDefault();
+    var recipe = $(this).data('recipe-name');
+
+    libtoaster.setDefaultImage(null, recipe,
+      function(){
+        /* Success */
+        window.location.replace(libtoaster.ctx.projectSpecificPageUrl);
+      });
+  });
+
 
   $(".customise-btn").unbind('click');
   $(".customise-btn").click(function(e){
diff --git a/poky/bitbake/lib/toaster/toastergui/static/js/libtoaster.js b/poky/bitbake/lib/toaster/toastergui/static/js/libtoaster.js
index 6f9b5d0..f2c45c8 100644
--- a/poky/bitbake/lib/toaster/toastergui/static/js/libtoaster.js
+++ b/poky/bitbake/lib/toaster/toastergui/static/js/libtoaster.js
@@ -275,7 +275,8 @@
 
   function _addRmLayer(layerObj, add, doneCb){
     if (layerObj.xhrLayerUrl === undefined){
-      throw("xhrLayerUrl is undefined")
+      alert("ERROR: missing xhrLayerUrl object. Please file a bug.");
+      return;
     }
 
     if (add === true) {
@@ -465,6 +466,108 @@
     $.cookie('toaster-notification', JSON.stringify(data), { path: '/'});
   }
 
+  /* _updateProject:
+   * url: xhrProjectUpdateUrl or null for current project
+   * onsuccess: callback for successful execution
+   * onfail: callback for failed execution
+   */
+  function _updateProject (url, targets, default_image, onsuccess, onfail) {
+
+    if (!url)
+      url = libtoaster.ctx.xhrProjectUpdateUrl;
+
+    /* Flatten the array of targets into a space spearated list */
+    if (targets instanceof Array){
+      targets = targets.reduce(function(prevV, nextV){
+        return prev + ' ' + next;
+      });
+    }
+
+    $.ajax( {
+        type: "POST",
+        url: url,
+        data: { 'do_update' : 'True' , 'targets' : targets , 'default_image' : default_image , },
+        headers: { 'X-CSRFToken' : $.cookie('csrftoken')},
+        success: function (_data) {
+          if (_data.error !== "ok") {
+            console.warn(_data.error);
+          } else {
+            if (onsuccess !== undefined) onsuccess(_data);
+          }
+        },
+        error: function (_data) {
+          console.warn("Call failed");
+          console.warn(_data);
+          if (onfail) onfail(data);
+    } });
+  }
+
+  /* _cancelProject:
+   * url: xhrProjectUpdateUrl or null for current project
+   * onsuccess: callback for successful execution
+   * onfail: callback for failed execution
+   */
+  function _cancelProject (url, onsuccess, onfail) {
+
+    if (!url)
+      url = libtoaster.ctx.xhrProjectCancelUrl;
+
+    $.ajax( {
+        type: "POST",
+        url: url,
+        data: { 'do_cancel' : 'True'  },
+        headers: { 'X-CSRFToken' : $.cookie('csrftoken')},
+        success: function (_data) {
+          if (_data.error !== "ok") {
+            console.warn(_data.error);
+          } else {
+            if (onsuccess !== undefined) onsuccess(_data);
+          }
+        },
+        error: function (_data) {
+          console.warn("Call failed");
+          console.warn(_data);
+          if (onfail) onfail(data);
+    } });
+  }
+
+  /* _setDefaultImage:
+   * url: xhrSetDefaultImageUrl or null for current project
+   * targets: an array or space separated list of targets to set as default
+   * onsuccess: callback for successful execution
+   * onfail: callback for failed execution
+   */
+  function _setDefaultImage (url, targets, onsuccess, onfail) {
+
+    if (!url)
+      url = libtoaster.ctx.xhrSetDefaultImageUrl;
+
+    /* Flatten the array of targets into a space spearated list */
+    if (targets instanceof Array){
+      targets = targets.reduce(function(prevV, nextV){
+        return prev + ' ' + next;
+      });
+    }
+
+    $.ajax( {
+        type: "POST",
+        url: url,
+        data: { 'targets' : targets },
+        headers: { 'X-CSRFToken' : $.cookie('csrftoken')},
+        success: function (_data) {
+          if (_data.error !== "ok") {
+            console.warn(_data.error);
+          } else {
+            if (onsuccess !== undefined) onsuccess(_data);
+          }
+        },
+        error: function (_data) {
+          console.warn("Call failed");
+          console.warn(_data);
+          if (onfail) onfail(data);
+    } });
+  }
+
   return {
     enableAjaxLoadingTimer: _enableAjaxLoadingTimer,
     disableAjaxLoadingTimer: _disableAjaxLoadingTimer,
@@ -485,6 +588,9 @@
     createCustomRecipe: _createCustomRecipe,
     makeProjectNameValidation: _makeProjectNameValidation,
     setNotification: _setNotification,
+    updateProject : _updateProject,
+    cancelProject : _cancelProject,
+    setDefaultImage : _setDefaultImage,
   };
 })();
 
diff --git a/poky/bitbake/lib/toaster/toastergui/static/js/mrbsection.js b/poky/bitbake/lib/toaster/toastergui/static/js/mrbsection.js
index c0c5fa9..f07ccf8 100644
--- a/poky/bitbake/lib/toaster/toastergui/static/js/mrbsection.js
+++ b/poky/bitbake/lib/toaster/toastergui/static/js/mrbsection.js
@@ -86,7 +86,7 @@
           if (buildFinished(build)) {
             // a build finished: reload the whole page so that the build
             // shows up in the builds table
-            window.location.reload();
+            window.location.reload(true);
           }
           else if (stateChanged(build)) {
             // update the whole template
@@ -110,6 +110,8 @@
             // update the clone progress text
             selector = '#repos-cloned-percentage-' + build.id;
             $(selector).html(build.repos_cloned_percentage);
+            selector = '#repos-cloned-progressitem-' + build.id;
+            $(selector).html('('+build.progress_item+')');
 
             // update the recipe progress bar
             selector = '#repos-cloned-percentage-bar-' + build.id;
diff --git a/poky/bitbake/lib/toaster/toastergui/static/js/newcustomimage_modal.js b/poky/bitbake/lib/toaster/toastergui/static/js/newcustomimage_modal.js
index dace8e3..e55fffc 100644
--- a/poky/bitbake/lib/toaster/toastergui/static/js/newcustomimage_modal.js
+++ b/poky/bitbake/lib/toaster/toastergui/static/js/newcustomimage_modal.js
@@ -25,6 +25,8 @@
   var duplicateNameMsg = "An image with this name already exists. Image names must be unique.";
   var duplicateImageInProjectMsg = "An image with this name already exists in this project."
   var invalidBaseRecipeIdMsg = "Please select an image to customise.";
+  var missingParentRecipe = "The parent recipe file was not found. Cancel this action, build any target (like 'quilt-native') to force all new layers to clone, and try again";
+  var unknownError = "Unexpected error: ";
 
   // set button to "submit" state and enable text entry so user can
   // enter the custom recipe name
@@ -62,6 +64,7 @@
     if (nameInput.val().length > 0) {
       libtoaster.createCustomRecipe(nameInput.val(), baseRecipeId,
       function(ret) {
+        showSubmitState();
         if (ret.error !== "ok") {
           console.warn(ret.error);
           if (ret.error === "invalid-name") {
@@ -73,6 +76,10 @@
           } else if (ret.error === "image-already-exists") {
             showNameError(duplicateImageInProjectMsg);
             return;
+          } else if (ret.error === "recipe-parent-not-exist") {
+            showNameError(missingParentRecipe);
+          } else {
+            showNameError(unknownError + ret.error);
           }
         } else {
           imgCustomModal.modal('hide');
diff --git a/poky/bitbake/lib/toaster/toastergui/static/js/projecttopbar.js b/poky/bitbake/lib/toaster/toastergui/static/js/projecttopbar.js
index 69220aa..3f9e186 100644
--- a/poky/bitbake/lib/toaster/toastergui/static/js/projecttopbar.js
+++ b/poky/bitbake/lib/toaster/toastergui/static/js/projecttopbar.js
@@ -14,6 +14,9 @@
   var newBuildTargetBuildBtn = $("#build-button");
   var selectedTarget;
 
+  var updateProjectBtn = $("#update-project-button");
+  var cancelProjectBtn = $("#cancel-project-button");
+
   /* Project name change functionality */
   projectNameFormToggle.click(function(e){
     e.preventDefault();
@@ -89,6 +92,25 @@
     }, null);
   });
 
+  updateProjectBtn.click(function (e) {
+    e.preventDefault();
+
+    selectedTarget = { name: "_PROJECT_PREPARE_" };
+
+    /* Save current default build image, fire off the build */
+    libtoaster.updateProject(null, selectedTarget.name, newBuildTargetInput.val().trim(),
+      function(){
+        window.location.replace(libtoaster.ctx.projectSpecificPageUrl);
+    }, null);
+  });
+
+  cancelProjectBtn.click(function (e) {
+    e.preventDefault();
+
+    /* redirect to 'done/canceled' landing page */
+    window.location.replace(libtoaster.ctx.landingSpecificCancelURL);
+  });
+
   /* Call makeProjectNameValidation function */
   libtoaster.makeProjectNameValidation($("#project-name-change-input"),
       $("#hint-error-project-name"), $("#validate-project-name"),
diff --git a/poky/bitbake/lib/toaster/toastergui/tables.py b/poky/bitbake/lib/toaster/toastergui/tables.py
index dca2fa2..9ff756b 100644
--- a/poky/bitbake/lib/toaster/toastergui/tables.py
+++ b/poky/bitbake/lib/toaster/toastergui/tables.py
@@ -35,6 +35,8 @@
 from toastergui.tablefilter import TableFilterActionDateRange
 from toastergui.tablefilter import TableFilterActionDay
 
+import os
+
 class ProjectFilters(object):
     @staticmethod
     def in_project(project_layers):
@@ -339,6 +341,8 @@
             'filter_name' : "in_current_project",
             'static_data_name' : "add-del-layers",
             'static_data_template' : '{% include "recipe_btn.html" %}'}
+    if '1' == os.environ.get('TOASTER_PROJECTSPECIFIC'):
+            build_col['static_data_template'] = '{% include "recipe_add_btn.html" %}'
 
     def get_context_data(self, **kwargs):
         project = Project.objects.get(pk=kwargs['pid'])
@@ -1611,14 +1615,12 @@
                         hidden=True,
                         field_name="layer_version__get_vcs_reference")
 
-        wrtemplate_file_template = '''<code>conf/machine/{{data.name}}.conf</code>
-        <a href="{{data.get_vcs_machine_file_link_url}}" target="_blank"><span class="glyphicon glyphicon-new-window"></i></a>'''
-
+        distro_file_template = '''<code>conf/distro/{{data.name}}.conf</code>
+        {% if 'None' not in data.get_vcs_distro_file_link_url %}<a href="{{data.get_vcs_distro_file_link_url}}" target="_blank"><span class="glyphicon glyphicon-new-window"></i></a>{% endif %}'''
         self.add_column(title="Distro file",
                         hidden=True,
                         static_data_name="templatefile",
-                        static_data_template=wrtemplate_file_template)
-
+                        static_data_template=distro_file_template)
 
         self.add_column(title="Select",
                         help_text="Sets the selected distro to the project",
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/base_specific.html b/poky/bitbake/lib/toaster/toastergui/templates/base_specific.html
new file mode 100644
index 0000000..e377cad
--- /dev/null
+++ b/poky/bitbake/lib/toaster/toastergui/templates/base_specific.html
@@ -0,0 +1,128 @@
+<!DOCTYPE html>
+{% load static %}
+{% load projecttags %}
+{% load project_url_tag %}
+<html lang="en">
+  <head>
+    <title>
+      {% block title %} Toaster {% endblock %}
+    </title>
+    <link rel="stylesheet" href="{% static 'css/bootstrap.min.css' %}" type="text/css"/>
+    <!--link rel="stylesheet" href="{% static 'css/bootstrap-theme.css' %}" type="text/css"/-->
+    <link rel="stylesheet" href="{% static 'css/font-awesome.min.css' %}" type='text/css'/>
+    <link rel="stylesheet" href="{% static 'css/default.css' %}" type='text/css'/>
+
+    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
+    <meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
+    <script src="{% static 'js/jquery-2.0.3.min.js' %}">
+    </script>
+    <script src="{% static 'js/jquery.cookie.js' %}">
+    </script>
+    <script src="{% static 'js/bootstrap.min.js' %}">
+    </script>
+    <script src="{% static 'js/typeahead.jquery.js' %}">
+    </script>
+    <script src="{% static 'js/jsrender.min.js' %}">
+    </script>
+    <script src="{% static 'js/highlight.pack.js' %}">
+    </script>
+    <script src="{% static 'js/libtoaster.js' %}">
+    </script>
+    {% if DEBUG %}
+    <script>
+      libtoaster.debug = true;
+    </script>
+    {% endif %}
+    <script>
+      /* Set JsRender delimiters (mrb_section.html) different than Django's */
+      $.views.settings.delimiters("<%", "%>");
+
+      /* This table allows Django substitutions to be passed to libtoaster.js */
+      libtoaster.ctx = {
+        jsUrl : "{% static 'js/' %}",
+        htmlUrl : "{% static 'html/' %}",
+        projectsUrl : "{% url 'all-projects' %}",
+        projectsTypeAheadUrl: {% url 'xhr_projectstypeahead' as prjurl%}{{prjurl|json}},
+        {% if project.id %}
+        landingSpecificURL : "{% url 'landing_specific' project.id %}",
+        landingSpecificCancelURL : "{% url 'landing_specific_cancel' project.id %}",
+        projectId : {{project.id}},
+        projectPageUrl : {% url 'project' project.id as purl %}{{purl|json}},
+        projectSpecificPageUrl : {% url 'project_specific' project.id as purl %}{{purl|json}},
+        xhrProjectUrl : {% url 'xhr_project' project.id as pxurl %}{{pxurl|json}},
+        projectName : {{project.name|json}},
+        recipesTypeAheadUrl: {% url 'xhr_recipestypeahead' project.id as paturl%}{{paturl|json}},
+        layersTypeAheadUrl: {% url 'xhr_layerstypeahead' project.id as paturl%}{{paturl|json}},
+        machinesTypeAheadUrl: {% url 'xhr_machinestypeahead' project.id as paturl%}{{paturl|json}},
+        distrosTypeAheadUrl: {% url 'xhr_distrostypeahead' project.id as paturl%}{{paturl|json}},
+        projectBuildsUrl: {% url 'projectbuilds' project.id as pburl %}{{pburl|json}},
+        xhrCustomRecipeUrl : "{% url 'xhr_customrecipe' %}",
+        projectId : {{project.id}},
+        xhrBuildRequestUrl: "{% url 'xhr_buildrequest' project.id %}",
+        mostRecentBuildsUrl: "{% url 'most_recent_builds' %}?project_id={{project.id}}",
+        xhrProjectUpdateUrl: "{% url 'xhr_projectupdate' project.id %}",
+        xhrProjectCancelUrl: "{% url 'landing_specific_cancel' project.id %}",
+        xhrSetDefaultImageUrl: "{% url 'xhr_setdefaultimage' project.id %}",
+        {% else %}
+        mostRecentBuildsUrl: "{% url 'most_recent_builds' %}",
+        projectId : undefined,
+        projectPageUrl : undefined,
+        projectName : undefined,
+        {% endif %}
+      };
+    </script>
+    {% block extraheadcontent %}
+    {% endblock %}
+  </head>
+
+  <body>
+
+    {% csrf_token %}
+    <div id="loading-notification" class="alert alert-warning lead text-center" style="display:none">
+      Loading <i class="fa-pulse icon-spinner"></i>
+    </div>
+
+    <div id="change-notification" class="alert alert-info alert-dismissible change-notification" style="display:none">
+      <button type="button" class="close" id="hide-alert" data-toggle="alert">&times;</button>
+      <span id="change-notification-msg"></span>
+    </div>
+
+    <nav class="navbar navbar-default navbar-fixed-top">
+      <div class="container-fluid">
+        <div class="navbar-header">
+          <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#global-nav" aria-expanded="false">
+            <span class="sr-only">Toggle navigation</span>
+            <span class="icon-bar"></span>
+            <span class="icon-bar"></span>
+            <span class="icon-bar"></span>
+          </button>
+          <div class="toaster-navbar-brand">
+          	{% if project_specific %}
+              <img class="logo" src="{% static 'img/logo.png' %}" class="" alt="Yocto Project logo"/>
+              Toaster
+          	{% else %}
+            <a href="/">
+            </a>
+            <a href="/">
+              <img class="logo" src="{% static 'img/logo.png' %}" class="" alt="Yocto Project logo"/>
+            </a>
+            <a class="brand" href="/">Toaster</a>
+            {% endif %}
+            {% if DEBUG %}
+            <span class="glyphicon glyphicon-info-sign" title="<strong>Toaster version information</strong>" data-content="<dl><dt>Git branch</dt><dd>{{TOASTER_BRANCH}}</dd><dt>Git revision</dt><dd>{{TOASTER_REVISION}}</dd></dl>"></i>
+            {% endif %}
+          </div>
+        </div>
+        <div class="collapse navbar-collapse" id="global-nav">
+            <ul class="nav navbar-nav">
+            <h3> Project Configuration Page </h3>
+        </div>
+      </div>
+    </nav>
+
+    <div class="container-fluid">
+      {% block pagecontent %}
+      {% endblock %}
+    </div>
+  </body>
+</html>
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/baseprojectspecificpage.html b/poky/bitbake/lib/toaster/toastergui/templates/baseprojectspecificpage.html
new file mode 100644
index 0000000..d0b588d
--- /dev/null
+++ b/poky/bitbake/lib/toaster/toastergui/templates/baseprojectspecificpage.html
@@ -0,0 +1,48 @@
+{% extends "base_specific.html" %}
+
+{% load projecttags %}
+{% load humanize %}
+
+{% block title %} {{title}} - {{project.name}} - Toaster {% endblock %}
+
+{% block pagecontent %}
+
+<div class="row">
+  {% include "project_specific_topbar.html" %}
+  <script type="text/javascript">
+$(document).ready(function(){
+    $("#config-nav .nav li a").each(function(){
+      if (window.location.pathname === $(this).attr('href'))
+      $(this).parent().addClass('active');
+      else
+      $(this).parent().removeClass('active');
+      });
+
+    $("#topbar-configuration-tab").addClass("active")
+    });
+  </script>
+
+  <!-- only on config pages -->
+  <div id="config-nav" class="col-md-2">
+    <ul class="nav nav-pills nav-stacked">
+      <li><a class="nav-parent" href="{% url 'project' project.id %}">Configuration</a></li>
+      <li class="nav-header">Compatible metadata</li>
+      <li><a href="{% url 'projectcustomimages' project.id %}">Custom images</a></li>
+      <li><a href="{% url 'projectimagerecipes' project.id %}">Image recipes</a></li>
+      <li><a href="{% url 'projectsoftwarerecipes' project.id %}">Software recipes</a></li>
+      <li><a href="{% url 'projectmachines' project.id %}">Machines</a></li>
+      <li><a href="{% url 'projectlayers' project.id %}">Layers</a></li>
+      <li><a href="{% url 'projectdistros' project.id %}">Distros</a></li>
+      <li class="nav-header">Extra configuration</li>
+      <li><a href="{% url 'projectconf' project.id %}">BitBake variables</a></li>
+
+      <li class="nav-header">Actions</li>
+    </ul>
+  </div>
+  <div class="col-md-10">
+    {% block projectinfomain %}{% endblock %}
+  </div>
+
+</div>
+{% endblock %}
+
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/customise_btn.html b/poky/bitbake/lib/toaster/toastergui/templates/customise_btn.html
index 38c258a..ce46240 100644
--- a/poky/bitbake/lib/toaster/toastergui/templates/customise_btn.html
+++ b/poky/bitbake/lib/toaster/toastergui/templates/customise_btn.html
@@ -5,7 +5,11 @@
   >
   Customise
 </button>
-<button class="btn btn-default btn-block layer-add-{{data.layer_version.pk}} layerbtn" data-layer='{ "id": {{data.layer_version.pk}}, "name":  "{{data.layer_version.layer.name}}", "layerdetailurl": "{%url 'layerdetails' extra.pid data.layer_version.pk%}"}' data-directive="add"
+<button class="btn btn-default btn-block layer-add-{{data.layer_version.pk}} layerbtn"
+    data-layer='{ "id": {{data.layer_version.pk}}, "name":  "{{data.layer_version.layer.name}}",
+      "layerdetailurl": "{%url 'layerdetails' extra.pid data.layer_version.pk%}",
+      "xhrLayerUrl": "{% url "xhr_layer" extra.pid data.layer_version.pk %}"}'
+    data-directive="add"
     {% if data.layer_version.pk in extra.current_layers %}
     style="display:none;"
     {% endif %}
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/generic-toastertable-page.html b/poky/bitbake/lib/toaster/toastergui/templates/generic-toastertable-page.html
index b3eabe1..99fbb38 100644
--- a/poky/bitbake/lib/toaster/toastergui/templates/generic-toastertable-page.html
+++ b/poky/bitbake/lib/toaster/toastergui/templates/generic-toastertable-page.html
@@ -1,4 +1,4 @@
-{% extends "baseprojectpage.html" %}
+{% extends project_specific|yesno:"baseprojectspecificpage.html,baseprojectpage.html" %}
 {% load projecttags %}
 {% load humanize %}
 {% load static %}
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/importlayer.html b/poky/bitbake/lib/toaster/toastergui/templates/importlayer.html
index 97d52c7..e0c987e 100644
--- a/poky/bitbake/lib/toaster/toastergui/templates/importlayer.html
+++ b/poky/bitbake/lib/toaster/toastergui/templates/importlayer.html
@@ -1,4 +1,4 @@
-{% extends "base.html" %}
+{% extends project_specific|yesno:"baseprojectspecificpage.html,base.html" %}
 {% load projecttags %}
 {% load humanize %}
 {% load static %}
@@ -6,7 +6,7 @@
 {% block pagecontent %}
 
 <div class="row">
-  {% include "projecttopbar.html" %}
+  {% include project_specific|yesno:"project_specific_topbar.html,projecttopbar.html" %}
   {% if project and project.release %}
   <script src="{% static 'js/layerDepsModal.js' %}"></script>
   <script src="{% static 'js/importlayer.js' %}"></script>
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/landing_specific.html b/poky/bitbake/lib/toaster/toastergui/templates/landing_specific.html
new file mode 100644
index 0000000..e289c7d
--- /dev/null
+++ b/poky/bitbake/lib/toaster/toastergui/templates/landing_specific.html
@@ -0,0 +1,50 @@
+{% extends "base_specific.html" %}
+
+{% load static %}
+{% load projecttags %}
+{% load humanize %}
+
+{% block title %} Welcome to Toaster {% endblock %}
+
+{% block pagecontent %}
+
+  <div class="container">
+   <div class="row">
+    <!-- Empty - no build module -->
+    <div class="page-header top-air">
+     <h1>
+       Configuration {% if status == "cancel" %}Canceled{% else %}Completed{% endif %}! You can now close this window.
+     </h1>
+    </div>
+    <div class="alert alert-info lead">
+     <p>
+     Your project configuration {% if status == "cancel" %}changes have been canceled{% else %}has completed!{% endif %}
+     <br>
+     <br>
+     <ul>
+       <li>
+       The Toaster instance for project configuration has been shut down
+       </li>
+       <li>
+       You can start Toaster independently for advanced project management and analysis:
+         <pre><code>
+         Set up bitbake environment:
+         $ cd {{install_dir}}
+         $ . oe-init-build-env [toaster_server]
+
+         Option 1: Start a local Toaster server, open local browser to "localhost:8000"
+         $ . toaster start webport=8000
+
+         Option 2: Start a shared Toaster server, open any browser to "[host_ip]:8000"
+         $ . toaster start webport=0.0.0.0:8000
+
+         To stop the Toaster server:
+         $ . toaster stop
+         </code></pre>
+       </li>
+     </ul>
+     </p>
+    </div>
+   </div>
+
+{% endblock %}
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/layerdetails.html b/poky/bitbake/lib/toaster/toastergui/templates/layerdetails.html
index e0069db..1e26e31 100644
--- a/poky/bitbake/lib/toaster/toastergui/templates/layerdetails.html
+++ b/poky/bitbake/lib/toaster/toastergui/templates/layerdetails.html
@@ -1,4 +1,4 @@
-{% extends "base.html" %}
+{% extends project_specific|yesno:"baseprojectspecificpage.html,base.html" %}
 {% load projecttags %}
 {% load humanize %}
 {% load static %}
@@ -310,6 +310,7 @@
             {% endwith %}
             {% endwith %}
           </div>
+
         </div> <!-- end tab content -->
       </div> <!-- end tabable -->
 
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/mrb_section.html b/poky/bitbake/lib/toaster/toastergui/templates/mrb_section.html
index c5b9fe9..98d9fac 100644
--- a/poky/bitbake/lib/toaster/toastergui/templates/mrb_section.html
+++ b/poky/bitbake/lib/toaster/toastergui/templates/mrb_section.html
@@ -119,7 +119,7 @@
           title="Toaster is cloning the repos required for your build">
     </span>
 
-    Cloning <span id="repos-cloned-percentage-<%:id%>"><%:repos_cloned_percentage%></span>% complete
+    Cloning <span id="repos-cloned-percentage-<%:id%>"><%:repos_cloned_percentage%></span>% complete <span id="repos-cloned-progressitem-<%:id%>">(<%:progress_item%>)</span>
 
     <%include tmpl='#cancel-template'/%>
   </div>
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/newcustomimage.html b/poky/bitbake/lib/toaster/toastergui/templates/newcustomimage.html
index 980179a..0766e5e 100644
--- a/poky/bitbake/lib/toaster/toastergui/templates/newcustomimage.html
+++ b/poky/bitbake/lib/toaster/toastergui/templates/newcustomimage.html
@@ -1,4 +1,4 @@
-{% extends "base.html" %}
+{% extends project_specific|yesno:"baseprojectspecificpage.html,base.html" %}
 {% load projecttags %}
 {% load humanize %}
 {% load static %}
@@ -8,7 +8,7 @@
 
 <div class="row">
 
-  {% include "projecttopbar.html" %}
+  {% include project_specific|yesno:"project_specific_topbar.html,projecttopbar.html" %}
 
   <div class="col-md-12">
     {% url table_name project.id as xhr_table_url %}
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/newproject.html b/poky/bitbake/lib/toaster/toastergui/templates/newproject.html
index bd03bb5..7e1ebb3 100644
--- a/poky/bitbake/lib/toaster/toastergui/templates/newproject.html
+++ b/poky/bitbake/lib/toaster/toastergui/templates/newproject.html
@@ -20,23 +20,19 @@
             <input type="text" class="form-control" required id="new-project-name" name="projectname">
           </div>
           <p class="help-block text-danger" style="display: none;" id="hint-error-project-name">A project with this name exists. Project names must be unique.</p>
-<!--
-            <fieldset>
-                <label class="project-form">Project type</label>
-                    <label class="project-form radio"><input type="radio" name="ptype" value="analysis" checked/> Analysis Project</label>
 
+                <label class="project-form">Project type:</label>
                 {% if releases.count > 0 %}
-                    <label class="project-form radio"><input type="radio" name="ptype" value="build" checked /> Build Project</label>
+                    <label class="project-form radio" style="padding-left: 35px;"><input id='type-new'    type="radio" name="ptype" value="new"/> New project</label>
                 {% endif %}
-              </fieldset> -->
-        <input type="hidden" name="ptype" value="build" />
+                    <label class="project-form radio" style="padding-left: 35px;"><input id='type-import' type="radio" name="ptype" value="import"/> Import command line project</label>
 
         {% if releases.count > 0 %}
-				<div class="release form-group">
+          <div class="release form-group">
             {% if releases.count > 1 %}
               <label class="control-label">
                 Release
-                <span class="glyphicon glyphicon-question-sign get-help" title="The version of the build system you want to use"></span>
+                <span class="glyphicon glyphicon-question-sign get-help" title="The version of the build system you want to use for this project"></span>
               </label>
               <select name="projectversion" id="projectversion" class="form-control">
                 {% for release in releases %}
@@ -59,28 +55,26 @@
             {% else %}
               <input type="hidden" name="projectversion" value="{{releases.0.id}}"/>
             {% endif %}
-                </div>
+
+              <input type="checkbox" class="checkbox-mergeattr" name="mergeattr" value="mergeattr">  Merged Toaster settings (Command line user compatibility)
+              <span class="glyphicon glyphicon-question-sign get-help" title="Place the Toaster settings into the standard 'local.conf' and 'bblayers.conf' instead of 'toaster_bblayers.conf' and 'toaster.conf'"></span>
+
+           </div>
         {% endif %}
+
+            <div class="build-import form-group" id="import-project">
+              <label class="control-label">Import existing project directory
+                <span class="glyphicon glyphicon-question-sign get-help" title="Enter a path to an existing build directory, import the existing settings, and create a Toaster Project for it."></span>
+              </label>
+              <input style="width: 33%;"type="text" class="form-control" required id="import-project-dir" name="importdir">
+            </div>
+
             <div class="top-air">
               <input type="submit" id="create-project-button" class="btn btn-primary btn-lg" value="Create project"/>
               <span class="help-inline" style="vertical-align:middle;">To create a project, you need to enter a project name</span>
             </div>
 
         </form>
-        <!--
-        <div class="col-md-5 well">
-                <span class="help-block">
-                 <h4>Toaster project types</h4>
-                 <p>With a <strong>build project</strong> you configure and run your builds from Toaster.</p>
-                 <p>With an <strong>analysis project</strong>, the builds are configured and run by another tool
-                 (something like Buildbot or Jenkins), and the project only collects the information about the
-                 builds (packages, recipes, dependencies, logs, etc). </p>
-                 <p>You can read more on <a href="#">how to set up an analysis project</a>
-                 in the Toaster manual.</p>
-                 <h4>Release</h4>
-                 <p>If you create a <strong>build project</strong>, you will need to select a <strong>release</strong>,
-                 which is the version of the build system you want to use to run your builds.</p>
-             </div> -->
       </div>
     </div>
 
@@ -89,6 +83,7 @@
             // hide the new project button
             $("#new-project-button").hide();
             $('.btn-primary').attr('disabled', 'disabled');
+            $('#type-new').attr('checked', 'checked');
 
             // enable submit button when all required fields are populated
             $("input#new-project-name").on('input', function() {
@@ -118,20 +113,24 @@
                  $(".btn-primary"));
 
 
-/*			// Hide the project release when you select an analysis project
+			// Hide the project release when you select an analysis project
 			function projectType() {
-				if ($("input[type='radio']:checked").val() == 'build') {
+				if ($("input[type='radio']:checked").val() == 'new') {
+					$('.build-import').fadeOut();
 					$('.release').fadeIn();
+                    $('#import-project-dir').removeAttr('required');
 				}
 				else {
 					$('.release').fadeOut();
+					$('.build-import').fadeIn();
+                    $('#import-project-dir').attr('required', 'required');
 				}
 			}
 			projectType();
 
 			$('input:radio').change(function(){
 				projectType();
-			}); */
+			});
         });
     </script>
 
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/newproject_specific.html b/poky/bitbake/lib/toaster/toastergui/templates/newproject_specific.html
new file mode 100644
index 0000000..cfa77f2
--- /dev/null
+++ b/poky/bitbake/lib/toaster/toastergui/templates/newproject_specific.html
@@ -0,0 +1,95 @@
+{% extends "base.html" %}
+{% load projecttags %}
+{% load humanize %}
+
+{% block title %} Create a new project - Toaster {% endblock %}
+
+{% block pagecontent %}
+<div class="row">
+  <div class="col-md-12">
+    <div class="page-header">
+          <h1>Create a new project</h1>
+        </div>
+    {% if alert %}
+      <div class="alert alert-danger" role="alert">{{alert}}</div>
+    {% endif %}
+
+        <form method="POST"  action="{%url "newproject_specific" project_pk %}">{% csrf_token %}
+          <div class="form-group" id="validate-project-name">
+            <label class="control-label">Project name <span class="text-muted">(required)</span></label>
+            <input type="text" class="form-control" required id="new-project-name" name="display_projectname" value="{{projectname}}" disabled>
+          </div>
+          <p class="help-block text-danger" style="display: none;" id="hint-error-project-name">A project with this name exists. Project names must be unique.</p>
+        <input type="hidden" name="ptype" value="build" />
+        <input type="hidden" name="projectname" value="{{projectname}}" />
+
+        {% if releases.count > 0 %}
+				<div class="release form-group">
+            {% if releases.count > 1 %}
+              <label class="control-label">
+                Release
+                <span class="glyphicon glyphicon-question-sign get-help" title="The version of the build system you want to use"></span>
+              </label>
+              <select name="projectversion" id="projectversion" class="form-control">
+                {% for release in releases %}
+                    <option value="{{release.id}}"
+                        {%if defaultbranch == release.name %}
+                            selected
+                        {%endif%}
+                     >{{release.description}}</option>
+                {% endfor %}
+              </select>
+              <div class="row">
+                <div class="col-md-4">
+                {% for release in releases %}
+                  <div class="helptext" id="description-{{release.id}}" style="display: none">
+                    <span class="help-block">{{release.helptext|safe}}</span>
+                  </div>
+                {% endfor %}
+            {% else %}
+              <input type="hidden" name="projectversion" value="{{releases.0.id}}"/>
+            {% endif %}
+                </div>
+              </div>
+            </fieldset>
+        {% endif %}
+            <div class="top-air">
+              <input type="submit" id="create-project-button" class="btn btn-primary btn-lg" value="Create project"/>
+              <span class="help-inline" style="vertical-align:middle;">To create a project, you need to specify the release</span>
+            </div>
+
+        </form>
+      </div>
+    </div>
+
+    <script type="text/javascript">
+        $(document).ready(function () {
+            // hide the new project button, name is preset
+            $("#new-project-button").hide();
+
+            // enable submit button when all required fields are populated
+            $("input#new-project-name").on('input', function() {
+                if ($("input#new-project-name").val().length > 0 ){
+                    $('.btn-primary').removeAttr('disabled');
+                    $(".help-inline").css('visibility','hidden');
+                }
+                else {
+                    $('.btn-primary').attr('disabled', 'disabled');
+                    $(".help-inline").css('visibility','visible');
+                }
+            });
+
+            // show relevant help text for the selected release
+            var selected_release = $('select').val();
+            $("#description-" + selected_release).show();
+
+            $('select').change(function(){
+                var new_release = $('select').val();
+                $(".helptext").hide();
+                $('#description-' + new_release).fadeIn();
+            });
+
+        });
+    </script>
+
+{% endblock %}
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/project.html b/poky/bitbake/lib/toaster/toastergui/templates/project.html
index 11603d1..fa41e3c 100644
--- a/poky/bitbake/lib/toaster/toastergui/templates/project.html
+++ b/poky/bitbake/lib/toaster/toastergui/templates/project.html
@@ -1,4 +1,4 @@
-{% extends "baseprojectpage.html" %}
+{% extends project_specific|yesno:"baseprojectspecificpage.html,baseprojectpage.html" %}
 
 {% load projecttags %}
 {% load humanize %}
@@ -18,7 +18,7 @@
     try {
       projectPageInit(ctx);
     } catch (e) {
-      document.write("Sorry, An error has occurred loading this page");
+      document.write("Sorry, An error has occurred loading this page (project):"+e);
       console.warn(e);
     }
   });
@@ -93,6 +93,7 @@
       </form>
     </div>
 
+	{% if not project_specific %}
     <div class="well well-transparent">
       <h3>Most built recipes</h3>
 
@@ -105,6 +106,7 @@
       </ul>
       <button class="btn btn-primary" id="freq-build-btn" disabled="disabled">Build selected recipes</button>
     </div>
+    {% endif %}
 
     <div class="well well-transparent">
       <h3>Project release</h3>
@@ -157,5 +159,6 @@
       <ul class="list-unstyled lead" id="layers-in-project-list">
       </ul>
   </div>
+
 </div>
 {% endblock %}
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/project_specific.html b/poky/bitbake/lib/toaster/toastergui/templates/project_specific.html
new file mode 100644
index 0000000..f625d18
--- /dev/null
+++ b/poky/bitbake/lib/toaster/toastergui/templates/project_specific.html
@@ -0,0 +1,162 @@
+{% extends "baseprojectspecificpage.html" %}
+
+{% load projecttags %}
+{% load humanize %}
+{% load static %}
+
+{% block title %} Configuration - {{project.name}} - Toaster {% endblock %}
+{% block projectinfomain %}
+
+<script src="{% static 'js/layerDepsModal.js' %}"></script>
+<script src="{% static 'js/projectpage.js' %}"></script>
+<script>
+  $(document).ready(function (){
+    var ctx = {
+      testReleaseChangeUrl: "{% url 'xhr_testreleasechange' project.id %}",
+    };
+
+    try {
+      projectPageInit(ctx);
+    } catch (e) {
+      document.write("Sorry, An error has occurred loading this page");
+      console.warn(e);
+    }
+  });
+</script>
+
+<div id="delete-project-modal" class="modal fade" tabindex="-1" role="dialog" data-backdrop="static" data-keyboard="false">
+  <div class="modal-dialog">
+    <div class="modal-content">
+      <div class="modal-header">
+        <h4>Are you sure you want to delete this project?</h4>
+      </div>
+      <div class="modal-body">
+        <p>Deleting the <strong class="project-name"></strong> project
+        will:</p>
+        <ul>
+          <li>Cancel its builds currently in progress</li>
+          <li>Remove its configuration information</li>
+          <li>Remove its imported layers</li>
+          <li>Remove its custom images</li>
+          <li>Remove all its build information</li>
+        </ul>
+      </div>
+      <div class="modal-footer">
+        <button type="button" class="btn btn-primary" id="delete-project-confirmed">
+          <span data-role="submit-state">Delete project</span>
+          <span data-role="loading-state" style="display:none">
+            <span class="fa-pulse">
+            <i class="fa-pulse icon-spinner"></i>
+          </span>
+            &nbsp;Deleting project...
+          </span>
+        </button>
+        <button type="button" class="btn btn-link" data-dismiss="modal">Cancel</button>
+      </div>
+    </div><!-- /.modal-content -->
+  </div><!-- /.modal-dialog -->
+</div>
+
+
+<div class="row" id="project-page" style="display:none">
+  <div class="col-md-6">
+    <div class="well well-transparent" id="machine-section">
+      <h3>Machine</h3>
+
+      <p class="lead"><span id="project-machine-name"></span> <span class="glyphicon glyphicon-edit" id="change-machine-toggle"></span></p>
+
+      <form id="select-machine-form" style="display:none;" class="form-inline">
+        <span class="help-block">Machine suggestions come from the list of layers added to your project. If you don't see the machine you are looking for, <a href="{% url 'projectmachines' project.id %}">check the full list of machines</a></span>
+        <div class="form-group" id="machine-input-form">
+          <input class="form-control" id="machine-change-input" autocomplete="off" value="" data-provide="typeahead" data-minlength="1" data-autocomplete="off" type="text">
+        </div>
+        <button id="machine-change-btn" class="btn btn-default" type="button">Save</button>
+        <a href="#" id="cancel-machine-change" class="btn btn-link">Cancel</a>
+        <span class="help-block text-danger" id="invalid-machine-name-help" style="display:none">A valid machine name cannot include spaces.</span>
+        <p class="form-link"><a href="{% url 'projectmachines' project.id %}">View compatible machines</a></p>
+      </form>
+    </div>
+
+    <div class="well well-transparent" id="distro-section">
+      <h3>Distro</h3>
+
+      <p class="lead"><span id="project-distro-name"></span> <span class="glyphicon glyphicon-edit" id="change-distro-toggle"></span></p>
+
+      <form id="select-distro-form" style="display:none;" class="form-inline">
+        <span class="help-block">Distro suggestions come from the Layer Index</a></span>
+        <div class="form-group">
+          <input class="form-control" id="distro-change-input" autocomplete="off" value="" data-provide="typeahead" data-minlength="1" data-autocomplete="off" type="text">
+        </div>
+        <button id="distro-change-btn" class="btn btn-default" type="button">Save</button>
+        <a href="#" id="cancel-distro-change" class="btn btn-link">Cancel</a>
+        <p class="form-link"><a href="{% url 'projectdistros' project.id %}">View compatible distros</a></p>
+      </form>
+    </div>
+
+    <div class="well well-transparent">
+      <h3>Most built recipes</h3>
+
+      <div class="alert alert-info" style="display:none" id="no-most-built">
+        <h4>You haven't built any recipes yet</h4>
+        <p class="form-link"><a href="{% url 'projectimagerecipes' project.id %}">Choose a recipe to build</a></p>
+      </div>
+
+      <ul class="list-unstyled lead" id="freq-build-list">
+      </ul>
+      <button class="btn btn-primary" id="freq-build-btn" disabled="disabled">Build selected recipes</button>
+    </div>
+
+    <div class="well well-transparent">
+      <h3>Project release</h3>
+
+      <p class="lead"><span id="project-release-title"></span>
+
+      <!-- Comment out the ability to change the project release, until we decide what to do with this functionality -->
+
+      <!--i title="" data-original-title="" id="release-change-toggle" class="icon-pencil"></i-->
+      </p>
+
+      <!-- Comment out the ability to change the project release, until we decide what to do with this functionality -->
+
+      <!--form class="form-inline" id="change-release-form" style="display:none;">
+        <select></select>
+        <button class="btn" style="margin-left:5px;" id="change-release-btn">Change</button> <a href="#" id="cancel-release-change" class="btn btn-link">Cancel</a>
+      </form-->
+    </div>
+  </div>
+
+  <div class="col-md-6">
+    <div class="well well-transparent" id="layer-container">
+      <h3>Layers <span class="counter">(<span id="project-layers-count"></span>)</span>
+        <span title="OpenEmbedded organises recipes and machines into thematic groups called <strong>layers</strong>. Click on a layer name to see the recipes and machines it includes." class="glyphicon glyphicon-question-sign get-help"></span>
+      </h3>
+
+      <div class="alert alert-warning" id="no-layers-in-project" style="display:none">
+        <h4>This project has no layers</h4>
+        In order to build this project you need to add some layers first. For that you can:
+        <ul>
+          <li><a href="{% url 'projectlayers' project.id %}">Choose from the layers compatible with this project</a></li>
+          <li><a href="{% url 'importlayer' project.id %}">Import a layer</a></li>
+          <li><a href="http://www.yoctoproject.org/docs/current/dev-manual/dev-manual.html#understanding-and-creating-layers" target="_blank">Read about layers in the documentation</a></li>
+          <li>Or type a layer name below</li>
+        </ul>
+      </div>
+
+      <form class="form-inline">
+        <div class="form-group">
+          <input id="layer-add-input" class="form-control" autocomplete="off" placeholder="Type a layer name" data-minlength="1" data-autocomplete="off" data-provide="typeahead" data-source="" type="text">
+        </div>
+        <button id="add-layer-btn" class="btn btn-default" disabled>Add layer</button>
+        <p class="form-link">
+          <a href="{% url 'projectlayers' project.id %}" id="view-compatible-layers">View compatible layers</a>
+          <span class="text-muted">|</span>
+          <a href="{% url 'importlayer' project.id %}">Import layer</a>
+        </p>
+      </form>
+
+      <ul class="list-unstyled lead" id="layers-in-project-list">
+      </ul>
+  </div>
+
+</div>
+{% endblock %}
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/project_specific_topbar.html b/poky/bitbake/lib/toaster/toastergui/templates/project_specific_topbar.html
new file mode 100644
index 0000000..622787c
--- /dev/null
+++ b/poky/bitbake/lib/toaster/toastergui/templates/project_specific_topbar.html
@@ -0,0 +1,80 @@
+{% load static %}
+<script src="{% static 'js/projecttopbar.js' %}"></script>
+<script>
+  $(document).ready(function () {
+    var ctx = {
+      numProjectLayers : {{project.get_project_layer_versions.count}},
+      machine : "{{project.get_current_machine_name|default_if_none:""}}",
+    }
+
+    try {
+      projectTopBarInit(ctx);
+    } catch (e) {
+      document.write("Sorry, An error has occurred loading this page (pstb):"+e);
+      console.warn(e);
+    }
+  });
+</script>
+
+<div class="col-md-12">
+  <div class="alert alert-success alert-dismissible change-notification" id="project-created-notification" style="display:none">
+    <button type="button" class="close" data-dismiss="alert">&times;</button>
+		<p>Your project <strong>{{project.name}}</strong> has been created. You can now <a class="alert-link" href="{% url 'projectmachines' project.id %}">select your target machine</a> and <a class="alert-link" href="{% url 'projectimagerecipes' project.id %}">choose image recipes</a> to build.</p>
+  </div>
+  <!-- project name -->
+  <div class="page-header">
+    <h1 id="project-name-container">
+      <span class="project-name">{{project.name}}</span>
+      {% if project.is_default %}
+      <span class="glyphicon glyphicon-question-sign get-help" title="This project shows information about the builds you start from the command line while Toaster is running"></span>
+      {% endif %}
+    </h1>
+    <form id="project-name-change-form" class="form-inline" style="display: none;">
+      <div class="form-group">
+        <input class="form-control input-lg" type="text" id="project-name-change-input" autocomplete="off" value="{{project.name}}">
+      </div>
+      <button id="project-name-change-btn" class="btn btn-default btn-lg" type="button">Save</button>
+      <a href="#" id="project-name-change-cancel" class="btn btn-lg btn-link">Cancel</a>
+    </form>
+  </div>
+
+  {% with mrb_type='project' %}
+    {% include "mrb_section.html" %}
+  {% endwith %}
+
+  {% if not project.is_default %}
+  <div id="project-topbar">
+    <ul class="nav nav-tabs">
+      <li id="topbar-configuration-tab">
+      <a href="{% url 'project_specific' project.id %}">
+        Configuration
+      </a>
+      </li>
+      <li>
+      <a href="{% url 'importlayer' project.id %}">
+        Import layer
+      </a>
+      </li>
+      <li>
+      <a href="{% url 'newcustomimage' project.id %}">
+        New custom image
+      </a>
+      </li>
+      <li class="pull-right">
+        <form class="form-inline">
+          <div class="form-group">
+            <span class="glyphicon glyphicon-question-sign get-help" data-placement="left" title="Type the name of one or more recipes you want to build, separated by a space. You can also specify a task by appending a colon and a task name to the recipe name, like so: <code>busybox:clean</code>"></span>
+                <input id="build-input" type="text" class="form-control input-lg" placeholder="Select the default image recipe" autocomplete="off" disabled value="{{project.get_default_image}}">
+          </div>
+          {% if project.get_is_new %}
+            <button id="update-project-button" class="btn btn-primary btn-lg" data-project-id="{{project.id}}">Prepare Project</button>
+          {% else %}
+            <button id="cancel-project-button" class="btn info btn-lg" data-project-id="{{project.id}}">Cancel</button>
+            <button id="update-project-button" class="btn btn-primary btn-lg" data-project-id="{{project.id}}">Update</button>
+          {% endif %}
+        </form>
+      </li>
+    </ul>
+  </div>
+  {% endif %}
+</div>
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/projectconf.html b/poky/bitbake/lib/toaster/toastergui/templates/projectconf.html
index 933c588..fb20b26 100644
--- a/poky/bitbake/lib/toaster/toastergui/templates/projectconf.html
+++ b/poky/bitbake/lib/toaster/toastergui/templates/projectconf.html
@@ -1,4 +1,4 @@
-{% extends "baseprojectpage.html" %}
+{% extends project_specific|yesno:"baseprojectspecificpage.html,baseprojectpage.html" %}
 {% load projecttags %}
 {% load humanize %}
 
@@ -438,8 +438,11 @@
         var_context='m';
       }
     }
+    if (configvars_sorted[i][0].startsWith("INTERNAL_")) {
+        var_context='m';
+    }
     if (var_context == undefined) {
-      orightml += '<dt><span id="config_var_entry_'+configvars_sorted[i][2]+'" class="js-config-var-name"></span><span class="glyphicon glyphicon-trash js-icon-trash-config_var" id="config_var_trash_'+configvars_sorted[i][2]+'" x-data="'+configvars_sorted[i][2]+'"></span> </dt>'
+        orightml += '<dt><span id="config_var_entry_'+configvars_sorted[i][2]+'" class="js-config-var-name"></span><span class="glyphicon glyphicon-trash js-icon-trash-config_var" id="config_var_trash_'+configvars_sorted[i][2]+'" x-data="'+configvars_sorted[i][2]+'"></span> </dt>'
         orightml += '<dd class="variable-list">'
         orightml += '    <span class="lead" id="config_var_value_'+configvars_sorted[i][2]+'"></span>'
         orightml += '    <span class="glyphicon glyphicon-edit js-icon-pencil-config_var" x-data="'+configvars_sorted[i][2]+'"></span>'
diff --git a/poky/bitbake/lib/toaster/toastergui/templates/recipe_add_btn.html b/poky/bitbake/lib/toaster/toastergui/templates/recipe_add_btn.html
new file mode 100644
index 0000000..06c4645
--- /dev/null
+++ b/poky/bitbake/lib/toaster/toastergui/templates/recipe_add_btn.html
@@ -0,0 +1,23 @@
+<a data-recipe-name="{{data.name}}" class="btn btn-default btn-block layer-exists-{{data.layer_version.pk}} set-default-recipe-btn" style="margin-top: 5px;
+  {% if data.layer_version.pk not in extra.current_layers %}
+    display:none;
+  {% endif %}"
+ >
+  Set recipe
+</a>
+<a class="btn btn-default btn-block layerbtn layer-add-{{data.layer_version.pk}}"
+  data-layer='{
+  "id": {{data.layer_version.pk}},
+  "name":  "{{data.layer_version.layer.name}}",
+  "layerdetailurl": "{%url "layerdetails" extra.pid data.layer_version.pk%}",
+   "xhrLayerUrl": "{% url "xhr_layer" extra.pid data.layer_version.pk %}"
+   }' data-directive="add"
+    {% if data.layer_version.pk in extra.current_layers %}
+     style="display:none;"
+    {% endif %}
+>
+  <span class="glyphicon glyphicon-plus"></span>
+  Add layer
+  <span class="glyphicon glyphicon-question-sign get-help" title="To set this
+      recipe you must first add the {{data.layer_version.layer.name}} layer to your project"></i>
+</a>
diff --git a/poky/bitbake/lib/toaster/toastergui/urls.py b/poky/bitbake/lib/toaster/toastergui/urls.py
index e07b0ef..dc03e30 100644
--- a/poky/bitbake/lib/toaster/toastergui/urls.py
+++ b/poky/bitbake/lib/toaster/toastergui/urls.py
@@ -116,6 +116,11 @@
             tables.ProjectBuildsTable.as_view(template_name="projectbuilds-toastertable.html"),
             name='projectbuilds'),
 
+        url(r'^newproject_specific/(?P<pid>\d+)/$', views.newproject_specific, name='newproject_specific'),
+        url(r'^project_specific/(?P<pid>\d+)/$', views.project_specific, name='project_specific'),
+        url(r'^landing_specific/(?P<pid>\d+)/$', views.landing_specific, name='landing_specific'),
+        url(r'^landing_specific_cancel/(?P<pid>\d+)/$', views.landing_specific_cancel, name='landing_specific_cancel'),
+
         # the import layer is a project-specific functionality;
         url(r'^project/(?P<pid>\d+)/importlayer$', views.importlayer, name='importlayer'),
 
@@ -233,6 +238,14 @@
             api.XhrBuildRequest.as_view(),
             name='xhr_buildrequest'),
 
+        url(r'^xhr_projectupdate/project/(?P<pid>\d+)$',
+            api.XhrProjectUpdate.as_view(),
+            name='xhr_projectupdate'),
+
+        url(r'^xhr_setdefaultimage/project/(?P<pid>\d+)$',
+            api.XhrSetDefaultImageUrl.as_view(),
+            name='xhr_setdefaultimage'),
+
         url(r'xhr_project/(?P<project_id>\d+)$',
             api.XhrProject.as_view(),
             name='xhr_project'),
diff --git a/poky/bitbake/lib/toaster/toastergui/views.py b/poky/bitbake/lib/toaster/toastergui/views.py
old mode 100755
new mode 100644
index 34ed2b2..c712b06
--- a/poky/bitbake/lib/toaster/toastergui/views.py
+++ b/poky/bitbake/lib/toaster/toastergui/views.py
@@ -25,6 +25,7 @@
 from django.db.models import F, Q, Sum
 from django.db import IntegrityError
 from django.shortcuts import render, redirect, get_object_or_404
+from django.utils.http import urlencode
 from orm.models import Build, Target, Task, Layer, Layer_Version, Recipe
 from orm.models import LogMessage, Variable, Package_Dependency, Package
 from orm.models import Task_Dependency, Package_File
@@ -51,6 +52,7 @@
 
 # Project creation and managed build enable
 project_enable = ('1' == os.environ.get('TOASTER_BUILDSERVER'))
+is_project_specific = ('1' == os.environ.get('TOASTER_PROJECTSPECIFIC'))
 
 class MimeTypeFinder(object):
     # setting this to False enables additional non-standard mimetypes
@@ -70,6 +72,7 @@
 # single point to add global values into the context before rendering
 def toaster_render(request, page, context):
     context['project_enable'] = project_enable
+    context['project_specific'] = is_project_specific
     return render(request, page, context)
 
 
@@ -1395,6 +1398,86 @@
             mandatory_fields = ['projectname', 'ptype']
             try:
                 ptype = request.POST.get('ptype')
+                if ptype == "import":
+                    mandatory_fields.append('importdir')
+                else:
+                    mandatory_fields.append('projectversion')
+                # make sure we have values for all mandatory_fields
+                missing = [field for field in mandatory_fields if len(request.POST.get(field, '')) == 0]
+                if missing:
+                    # set alert for missing fields
+                    raise BadParameterException("Fields missing: %s" % ", ".join(missing))
+
+                if not request.user.is_authenticated():
+                    user = authenticate(username = request.POST.get('username', '_anonuser'), password = 'nopass')
+                    if user is None:
+                        user = User.objects.create_user(username = request.POST.get('username', '_anonuser'), email = request.POST.get('email', ''), password = "nopass")
+
+                        user = authenticate(username = user.username, password = 'nopass')
+                    login(request, user)
+
+                #  save the project
+                if ptype == "import":
+                    if not os.path.isdir('%s/conf' % request.POST['importdir']):
+                        raise BadParameterException("Bad path or missing 'conf' directory (%s)" % request.POST['importdir'])
+                    from django.core import management
+                    management.call_command('buildimport', '--command=import', '--name=%s' % request.POST['projectname'], '--path=%s' % request.POST['importdir'], interactive=False)
+                    prj = Project.objects.get(name = request.POST['projectname'])
+                    prj.merged_attr = True
+                    prj.save()
+                else:
+                    release = Release.objects.get(pk = request.POST.get('projectversion', None ))
+                    prj = Project.objects.create_project(name = request.POST['projectname'], release = release)
+                    prj.user_id = request.user.pk
+                    if 'mergeattr' == request.POST.get('mergeattr', ''):
+                        prj.merged_attr = True
+                    prj.save()
+
+                return redirect(reverse(project, args=(prj.pk,)) + "?notify=new-project")
+
+            except (IntegrityError, BadParameterException) as e:
+                # fill in page with previously submitted values
+                for field in mandatory_fields:
+                    context.__setitem__(field, request.POST.get(field, "-- missing"))
+                if isinstance(e, IntegrityError) and "username" in str(e):
+                    context['alert'] = "Your chosen username is already used"
+                else:
+                    context['alert'] = str(e)
+                return toaster_render(request, template, context)
+
+        raise Exception("Invalid HTTP method for this page")
+
+    # new project
+    def newproject_specific(request, pid):
+        if not project_enable:
+            return redirect( landing )
+
+        project = Project.objects.get(pk=pid)
+        template = "newproject_specific.html"
+        context = {
+            'email': request.user.email if request.user.is_authenticated() else '',
+            'username': request.user.username if request.user.is_authenticated() else '',
+            'releases': Release.objects.order_by("description"),
+            'projectname': project.name,
+            'project_pk': project.pk,
+        }
+
+        # WORKAROUND: if we already know release, redirect 'newproject_specific' to 'project_specific'
+        if '1' == project.get_variable('INTERNAL_PROJECT_SPECIFIC_SKIPRELEASE'):
+            return redirect(reverse(project_specific, args=(project.pk,)))
+
+        try:
+            context['defaultbranch'] = ToasterSetting.objects.get(name = "DEFAULT_RELEASE").value
+        except ToasterSetting.DoesNotExist:
+            pass
+
+        if request.method == "GET":
+            # render new project page
+            return toaster_render(request, template, context)
+        elif request.method == "POST":
+            mandatory_fields = ['projectname', 'ptype']
+            try:
+                ptype = request.POST.get('ptype')
                 if ptype == "build":
                     mandatory_fields.append('projectversion')
                 # make sure we have values for all mandatory_fields
@@ -1417,10 +1500,10 @@
                 else:
                     release = Release.objects.get(pk = request.POST.get('projectversion', None ))
 
-                prj = Project.objects.create_project(name = request.POST['projectname'], release = release)
+                prj = Project.objects.create_project(name = request.POST['projectname'], release = release, existing_project = project)
                 prj.user_id = request.user.pk
                 prj.save()
-                return redirect(reverse(project, args=(prj.pk,)) + "?notify=new-project")
+                return redirect(reverse(project_specific, args=(prj.pk,)) + "?notify=new-project")
 
             except (IntegrityError, BadParameterException) as e:
                 # fill in page with previously submitted values
@@ -1437,9 +1520,87 @@
     # Shows the edit project page
     def project(request, pid):
         project = Project.objects.get(pk=pid)
+
+        if '1' == os.environ.get('TOASTER_PROJECTSPECIFIC'):
+            if request.GET:
+                #Example:request.GET=<QueryDict: {'setMachine': ['qemuarm']}>
+                params = urlencode(request.GET).replace('%5B%27','').replace('%27%5D','')
+                return redirect("%s?%s" % (reverse(project_specific, args=(project.pk,)),params))
+            else:
+                return redirect(reverse(project_specific, args=(project.pk,)))
         context = {"project": project}
         return toaster_render(request, "project.html", context)
 
+    # Shows the edit project-specific page
+    def project_specific(request, pid):
+        project = Project.objects.get(pk=pid)
+
+        # Are we refreshing from a successful project specific update clone?
+        if Project.PROJECT_SPECIFIC_CLONING_SUCCESS == project.get_variable(Project.PROJECT_SPECIFIC_STATUS):
+            return redirect(reverse(landing_specific,args=(project.pk,)))
+
+        context = {
+            "project": project,
+            "is_new" : project.get_variable(Project.PROJECT_SPECIFIC_ISNEW),
+            "default_image_recipe" : project.get_variable(Project.PROJECT_SPECIFIC_DEFAULTIMAGE),
+            "mru" : Build.objects.all().filter(project=project,outcome=Build.IN_PROGRESS),
+            }
+        if project.build_set.filter(outcome=Build.IN_PROGRESS).count() > 0:
+            context['build_in_progress_none_completed'] = True
+        else:
+            context['build_in_progress_none_completed'] = False
+        return toaster_render(request, "project.html", context)
+
+    # perform the final actions for the project specific page
+    def project_specific_finalize(cmnd, pid):
+        project = Project.objects.get(pk=pid)
+        callback = project.get_variable(Project.PROJECT_SPECIFIC_CALLBACK)
+        if "update" == cmnd:
+            # Delete all '_PROJECT_PREPARE_' builds
+            for b in Build.objects.all().filter(project=project):
+                delete_build = False
+                for t in b.target_set.all():
+                    if '_PROJECT_PREPARE_' == t.target:
+                        delete_build = True
+                if delete_build:
+                    from django.core import management
+                    management.call_command('builddelete', str(b.id), interactive=False)
+            # perform callback at this last moment if defined, in case Toaster gets shutdown next
+            default_target = project.get_variable(Project.PROJECT_SPECIFIC_DEFAULTIMAGE)
+            if callback:
+                callback = callback.replace("<IMAGE>",default_target)
+        if "cancel" == cmnd:
+            if callback:
+                callback = callback.replace("<IMAGE>","none")
+                callback = callback.replace("--update","--cancel")
+        # perform callback at this last moment if defined, in case this Toaster gets shutdown next
+        ret = ''
+        if callback:
+            ret = os.system('bash -c "%s"' % callback)
+            project.set_variable(Project.PROJECT_SPECIFIC_CALLBACK,'')
+        # Delete the temp project specific variables
+        project.set_variable(Project.PROJECT_SPECIFIC_ISNEW,'')
+        project.set_variable(Project.PROJECT_SPECIFIC_STATUS,Project.PROJECT_SPECIFIC_NONE)
+        # WORKAROUND: Release this workaround flag
+        project.set_variable('INTERNAL_PROJECT_SPECIFIC_SKIPRELEASE','')
+
+    # Shows the final landing page for project specific update
+    def landing_specific(request, pid):
+        project_specific_finalize("update", pid)
+        context = {
+            "install_dir": os.environ['TOASTER_DIR'],
+        }
+        return toaster_render(request, "landing_specific.html", context)
+
+    # Shows the related landing-specific page
+    def landing_specific_cancel(request, pid):
+        project_specific_finalize("cancel", pid)
+        context = {
+            "install_dir": os.environ['TOASTER_DIR'],
+            "status": "cancel",
+        }
+        return toaster_render(request, "landing_specific.html", context)
+
     def jsunittests(request):
         """ Provides a page for the js unit tests """
         bbv = BitbakeVersion.objects.filter(branch="master").first()
diff --git a/poky/bitbake/lib/toaster/toastergui/widgets.py b/poky/bitbake/lib/toaster/toastergui/widgets.py
index feef7c5..db5c3aa 100644
--- a/poky/bitbake/lib/toaster/toastergui/widgets.py
+++ b/poky/bitbake/lib/toaster/toastergui/widgets.py
@@ -89,6 +89,10 @@
 
         # global variables
         context['project_enable'] = ('1' == os.environ.get('TOASTER_BUILDSERVER'))
+        try:
+            context['project_specific'] = ('1' == os.environ.get('TOASTER_PROJECTSPECIFIC'))
+        except:
+            context['project_specific'] = ''
 
         return context
 
@@ -524,6 +528,8 @@
             else:
                 build['repos_cloned_percentage'] = 0
 
+            build['progress_item'] = build_obj.progress_item
+
             tasks_complete_percentage = 0
             if build_obj.outcome in (Build.SUCCEEDED, Build.FAILED):
                 tasks_complete_percentage = 100
diff --git a/poky/bitbake/lib/toaster/toastermain/management/commands/builddelete.py b/poky/bitbake/lib/toaster/toastermain/management/commands/builddelete.py
index 0bef8d4..bf69a8f 100644
--- a/poky/bitbake/lib/toaster/toastermain/management/commands/builddelete.py
+++ b/poky/bitbake/lib/toaster/toastermain/management/commands/builddelete.py
@@ -10,8 +10,12 @@
     args    = '<buildID1 buildID2 .....>'
     help    = "Deletes selected build(s)"
 
+    def add_arguments(self, parser):
+        parser.add_argument('buildids', metavar='N', type=int, nargs='+',
+                    help="Build ID's to delete")
+
     def handle(self, *args, **options):
-        for bid in args:
+        for bid in options['buildids']:
             try:
                 b = Build.objects.get(pk = bid)
             except ObjectDoesNotExist:
diff --git a/poky/bitbake/lib/toaster/toastermain/management/commands/buildimport.py b/poky/bitbake/lib/toaster/toastermain/management/commands/buildimport.py
new file mode 100644
index 0000000..2d57ab5
--- /dev/null
+++ b/poky/bitbake/lib/toaster/toastermain/management/commands/buildimport.py
@@ -0,0 +1,584 @@
+#
+# ex:ts=4:sw=4:sts=4:et
+# -*- tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*-
+#
+# BitBake Toaster Implementation
+#
+# Copyright (C) 2018        Wind River Systems
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License version 2 as
+# published by the Free Software Foundation.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License along
+# with this program; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+# buildimport: import a project for project specific configuration
+#
+# Usage:
+#  (a) Set up Toaster environent
+#
+#  (b) Call buildimport
+#      $ /path/to/bitbake/lib/toaster/manage.py buildimport \
+#        --name=$PROJECTNAME \
+#        --path=$BUILD_DIRECTORY \
+#        --callback="$CALLBACK_SCRIPT" \
+#        --command="configure|reconfigure|import"
+#
+#  (c) Return is "|Default_image=%s|Project_id=%d"
+#
+#  (d) Open Toaster to this project using for example:
+#      $ xdg-open http://localhost:$toaster_port/toastergui/project_specific/$project_id
+#
+#  (e) To delete a project:
+#      $ /path/to/bitbake/lib/toaster/manage.py buildimport \
+#        --name=$PROJECTNAME --delete-project
+#
+
+
+# ../bitbake/lib/toaster/manage.py buildimport --name=test --path=`pwd` --callback="" --command=import
+
+from django.core.management.base import BaseCommand, CommandError
+from django.core.exceptions import ObjectDoesNotExist
+from orm.models import ProjectManager, Project, Release, ProjectVariable
+from orm.models import Layer, Layer_Version, LayerSource, ProjectLayer
+from toastergui.api import scan_layer_content
+from django.db import OperationalError
+
+import os
+import re
+import os.path
+import subprocess
+import shutil
+
+# Toaster variable section delimiters
+TOASTER_PROLOG = '#=== TOASTER_CONFIG_PROLOG ==='
+TOASTER_EPILOG = '#=== TOASTER_CONFIG_EPILOG ==='
+
+# quick development/debugging support
+verbose = 2
+def _log(msg):
+    if 1 == verbose:
+        print(msg)
+    elif 2 == verbose:
+        f1=open('/tmp/toaster.log', 'a')
+        f1.write("|" + msg + "|\n" )
+        f1.close()
+
+
+__config_regexp__  = re.compile( r"""
+    ^
+    (?P<exp>export\s+)?
+    (?P<var>[a-zA-Z0-9\-_+.${}/~]+?)
+    (\[(?P<flag>[a-zA-Z0-9\-_+.]+)\])?
+
+    \s* (
+        (?P<colon>:=) |
+        (?P<lazyques>\?\?=) |
+        (?P<ques>\?=) |
+        (?P<append>\+=) |
+        (?P<prepend>=\+) |
+        (?P<predot>=\.) |
+        (?P<postdot>\.=) |
+        =
+    ) \s*
+
+    (?!'[^']*'[^']*'$)
+    (?!\"[^\"]*\"[^\"]*\"$)
+    (?P<apo>['\"])
+    (?P<value>.*)
+    (?P=apo)
+    $
+    """, re.X)
+
+class Command(BaseCommand):
+    args    = "<name> <path> <release>"
+    help    = "Import a command line build directory"
+    vars    = {}
+    toaster_vars = {}
+
+    def add_arguments(self, parser):
+        parser.add_argument(
+            '--name', dest='name', required=True,
+            help='name of the project',
+            )
+        parser.add_argument(
+            '--path', dest='path', required=True,
+            help='path to the project',
+            )
+        parser.add_argument(
+            '--release', dest='release', required=False,
+            help='release for the project',
+            )
+        parser.add_argument(
+            '--callback', dest='callback', required=False,
+            help='callback for project config update',
+            )
+        parser.add_argument(
+            '--delete-project', dest='delete_project', required=False,
+            help='delete this project from the database',
+            )
+        parser.add_argument(
+            '--command', dest='command', required=False,
+            help='command (configure,reconfigure,import)',
+            )
+
+    # Extract the bb variables from a conf file
+    def scan_conf(self,fn):
+        vars = self.vars
+        toaster_vars = self.toaster_vars
+
+        #_log("scan_conf:%s" % fn)
+        if not os.path.isfile(fn):
+            return
+        f = open(fn, 'r')
+
+        #statements = ast.StatementGroup()
+        lineno = 0
+        is_toaster_section = False
+        while True:
+            lineno = lineno + 1
+            s = f.readline()
+            if not s:
+                break
+            w = s.strip()
+            # skip empty lines
+            if not w:
+                continue
+            # evaluate Toaster sections
+            if w.startswith(TOASTER_PROLOG):
+                is_toaster_section = True
+                continue
+            if w.startswith(TOASTER_EPILOG):
+                is_toaster_section = False
+                continue
+            s = s.rstrip()
+            while s[-1] == '\\':
+                s2 = f.readline().strip()
+                lineno = lineno + 1
+                if (not s2 or s2 and s2[0] != "#") and s[0] == "#" :
+                    echo("There is a confusing multiline, partially commented expression on line %s of file %s (%s).\nPlease clarify whether this is all a comment or should be parsed." % (lineno, fn, s))
+                s = s[:-1] + s2
+            # skip comments
+            if s[0] == '#':
+                continue
+            # process the line for just assignments
+            m = __config_regexp__.match(s)
+            if m:
+                groupd = m.groupdict()
+                var = groupd['var']
+                value = groupd['value']
+
+                if groupd['lazyques']:
+                    if not var in vars:
+                        vars[var] = value
+                    continue
+                if groupd['ques']:
+                    if not var in vars:
+                        vars[var] = value
+                    continue
+                # preset empty blank for remaining operators
+                if not var in vars:
+                    vars[var] = ''
+                if groupd['append']:
+                    vars[var] += value
+                elif groupd['prepend']:
+                    vars[var] = "%s%s" % (value,vars[var])
+                elif groupd['predot']:
+                    vars[var] = "%s %s" % (value,vars[var])
+                elif groupd['postdot']:
+                    vars[var] = "%s %s" % (vars[var],value)
+                else:
+                    vars[var] = "%s" % (value)
+                # capture vars in a Toaster section
+                if is_toaster_section:
+                    toaster_vars[var] = vars[var]
+
+        # DONE WITH PARSING
+        f.close()
+        self.vars = vars
+        self.toaster_vars = toaster_vars
+
+    # Update the scanned project variables
+    def update_project_vars(self,project,name):
+        pv, create = ProjectVariable.objects.get_or_create(project = project, name = name)
+        if (not name in self.vars.keys()) or (not self.vars[name]):
+            self.vars[name] = pv.value
+        else:
+            if pv.value != self.vars[name]:
+                pv.value = self.vars[name]
+        pv.save()
+
+    # Find the git version of the installation
+    def find_layer_dir_version(self,path):
+        #  * rocko               ...
+
+        install_version = ''
+        cwd = os.getcwd()
+        os.chdir(path)
+        p = subprocess.Popen(['git', 'branch', '-av'], stdout=subprocess.PIPE,
+                                                stderr=subprocess.PIPE)
+        out, err = p.communicate()
+        out = out.decode("utf-8")
+        for branch in out.split('\n'):
+            if ('*' == branch[0:1]) and ('no branch' not in branch):
+                install_version = re.sub(' .*','',branch[2:])
+                break
+            if 'remotes/m/master' in branch:
+                install_version = re.sub('.*base/','',branch)
+                break
+        os.chdir(cwd)
+        return install_version
+
+    # Compute table of the installation's registered layer versions (branch or commit)
+    def find_layer_dir_versions(self,INSTALL_URL_PREFIX):
+        lv_dict = {}
+        layer_versions = Layer_Version.objects.all()
+        for lv in layer_versions:
+            layer = Layer.objects.filter(pk=lv.layer.pk)[0]
+            if layer.vcs_url:
+                url_short = layer.vcs_url.replace(INSTALL_URL_PREFIX,'')
+            else:
+                url_short = ''
+            # register the core, branch, and the version variations
+            lv_dict["%s,%s,%s" % (url_short,lv.dirpath,'')] = (lv.id,layer.name)
+            lv_dict["%s,%s,%s" % (url_short,lv.dirpath,lv.branch)] = (lv.id,layer.name)
+            lv_dict["%s,%s,%s" % (url_short,lv.dirpath,lv.commit)] = (lv.id,layer.name)
+            #_log("  (%s,%s,%s|%s) = (%s,%s)" % (url_short,lv.dirpath,lv.branch,lv.commit,lv.id,layer.name))
+        return lv_dict
+
+    # Apply table of all layer versions
+    def extract_bblayers(self):
+        # set up the constants
+        bblayer_str = self.vars['BBLAYERS']
+        TOASTER_DIR = os.environ.get('TOASTER_DIR')
+        INSTALL_CLONE_PREFIX = os.path.dirname(TOASTER_DIR) + "/"
+        TOASTER_CLONE_PREFIX = TOASTER_DIR + "/_toaster_clones/"
+        INSTALL_URL_PREFIX = ''
+        layers = Layer.objects.filter(name='openembedded-core')
+        for layer in layers:
+            if layer.vcs_url:
+                INSTALL_URL_PREFIX = layer.vcs_url
+                break
+        INSTALL_URL_PREFIX = INSTALL_URL_PREFIX.replace("/poky","/")
+        INSTALL_VERSION_DIR = TOASTER_DIR
+        INSTALL_URL_POSTFIX = INSTALL_URL_PREFIX.replace(':','_')
+        INSTALL_URL_POSTFIX = INSTALL_URL_POSTFIX.replace('/','_')
+        INSTALL_URL_POSTFIX = "%s_%s" % (TOASTER_CLONE_PREFIX,INSTALL_URL_POSTFIX)
+
+        # get the set of available layer:layer_versions
+        lv_dict = self.find_layer_dir_versions(INSTALL_URL_PREFIX)
+
+        # compute the layer matches
+        layers_list = []
+        for line in bblayer_str.split(' '):
+            if not line:
+                continue
+            if line.endswith('/local'):
+                continue
+
+            # isolate the repo
+            layer_path = line
+            line = line.replace(INSTALL_URL_POSTFIX,'').replace(INSTALL_CLONE_PREFIX,'').replace('/layers/','/').replace('/poky/','/')
+
+            # isolate the sub-path
+            path_index = line.rfind('/')
+            if path_index > 0:
+                sub_path = line[path_index+1:]
+                line = line[0:path_index]
+            else:
+                sub_path = ''
+
+            # isolate the version
+            if TOASTER_CLONE_PREFIX in layer_path:
+                is_toaster_clone = True
+                # extract version from name syntax
+                version_index = line.find('_')
+                if version_index > 0:
+                    version = line[version_index+1:]
+                    line = line[0:version_index]
+                else:
+                    version = ''
+                _log("TOASTER_CLONE(%s/%s), version=%s" % (line,sub_path,version))
+            else:
+                is_toaster_clone = False
+                # version is from the installation
+                version = self.find_layer_dir_version(layer_path)
+                _log("LOCAL_CLONE(%s/%s), version=%s" % (line,sub_path,version))
+
+            # capture the layer information into layers_list
+            layers_list.append( (line,sub_path,version,layer_path,is_toaster_clone) )
+        return layers_list,lv_dict
+
+    #
+    def find_import_release(self,layers_list,lv_dict,default_release):
+        #   poky,meta,rocko => 4;openembedded-core
+        release = default_release
+        for line,path,version,layer_path,is_toaster_clone in layers_list:
+            key = "%s,%s,%s" % (line,path,version)
+            if key in lv_dict:
+                lv_id = lv_dict[key]
+                if 'openembedded-core' == lv_id[1]:
+                    _log("Find_import_release(%s):version=%s,Toaster=%s" % (lv_id[1],version,is_toaster_clone))
+                    # only versions in Toaster managed layers are accepted
+                    if not is_toaster_clone:
+                        break
+                    try:
+                        release = Release.objects.get(name=version)
+                    except:
+                        pass
+                    break
+        _log("Find_import_release:RELEASE=%s" % release.name)
+        return release
+
+    # Apply the found conf layers
+    def apply_conf_bblayers(self,layers_list,lv_dict,project,release=None):
+        for line,path,version,layer_path,is_toaster_clone in layers_list:
+            # Assert release promote if present
+            if release:
+                version = release
+            # try to match the key to a layer_version
+            key = "%s,%s,%s" % (line,path,version)
+            key_short = "%s,%s,%s" % (line,path,'')
+            lv_id = ''
+            if key in lv_dict:
+                lv_id = lv_dict[key]
+                lv = Layer_Version.objects.get(pk=int(lv_id[0]))
+                pl,created = ProjectLayer.objects.get_or_create(project=project,
+                                                   layercommit=lv)
+                pl.optional=False
+                pl.save()
+                _log("  %s => %s;%s" % (key,lv_id[0],lv_id[1]))
+            elif key_short in lv_dict:
+                lv_id = lv_dict[key_short]
+                lv = Layer_Version.objects.get(pk=int(lv_id[0]))
+                pl,created = ProjectLayer.objects.get_or_create(project=project,
+                                                   layercommit=lv)
+                pl.optional=False
+                pl.save()
+                _log("  %s ?> %s" % (key,lv_dict[key_short]))
+            else:
+                _log("%s <= %s" % (key,layer_path))
+                found = False
+                # does local layer already exist in this project?
+                try:
+                    for pl in ProjectLayer.objects.filter(project=project):
+                        if pl.layercommit.layer.local_source_dir == layer_path:
+                            found = True
+                            _log("  Project Local Layer found!")
+                except Exception as e:
+                    _log("ERROR: Local Layer '%s'" % e)
+                    pass
+
+                if not found:
+                    # Does Layer name+path already exist?
+                    try:
+                        layer_name_base = os.path.basename(layer_path)
+                        _log("Layer_lookup: try '%s','%s'" % (layer_name_base,layer_path))
+                        layer = Layer.objects.get(name=layer_name_base,local_source_dir = layer_path)
+                        # Found! Attach layer_version and ProjectLayer
+                        layer_version = Layer_Version.objects.create(
+                            layer=layer,
+                            project=project,
+                            layer_source=LayerSource.TYPE_IMPORTED)
+                        layer_version.save()
+                        pl,created = ProjectLayer.objects.get_or_create(project=project,
+                                                           layercommit=layer_version)
+                        pl.optional=False
+                        pl.save()
+                        found = True
+                        # add layer contents to this layer version
+                        scan_layer_content(layer,layer_version)
+                        _log("  Parent Local Layer found in db!")
+                    except Exception as e:
+                        _log("Layer_exists_test_failed: Local Layer '%s'" % e)
+                        pass
+
+                if not found:
+                    # Insure that layer path exists, in case of user typo
+                    if not os.path.isdir(layer_path):
+                        _log("ERROR:Layer path '%s' not found" % layer_path)
+                        continue
+                    # Add layer to db and attach project to it
+                    layer_name_base = os.path.basename(layer_path)
+                    # generate a unique layer name
+                    layer_name_matches = {}
+                    for layer in Layer.objects.filter(name__contains=layer_name_base):
+                        layer_name_matches[layer.name] = '1'
+                    layer_name_idx = 0
+                    layer_name_test = layer_name_base
+                    while layer_name_test in layer_name_matches.keys():
+                        layer_name_idx += 1
+                        layer_name_test = "%s_%d" % (layer_name_base,layer_name_idx)
+                    # create the layer and layer_verion objects
+                    layer = Layer.objects.create(name=layer_name_test)
+                    layer.local_source_dir = layer_path
+                    layer_version = Layer_Version.objects.create(
+                        layer=layer,
+                        project=project,
+                        layer_source=LayerSource.TYPE_IMPORTED)
+                    layer.save()
+                    layer_version.save()
+                    pl,created = ProjectLayer.objects.get_or_create(project=project,
+                                                       layercommit=layer_version)
+                    pl.optional=False
+                    pl.save()
+                    # register the layer's content
+                    _log("  Local Layer Add content")
+                    scan_layer_content(layer,layer_version)
+                    _log("  Local Layer Added '%s'!" % layer_name_test)
+
+    # Scan the project's conf files (if any)
+    def scan_conf_variables(self,project_path):
+        # scan the project's settings, add any new layers or variables
+        if os.path.isfile("%s/conf/local.conf" % project_path):
+            self.scan_conf("%s/conf/local.conf" % project_path)
+            self.scan_conf("%s/conf/bblayers.conf" % project_path)
+            # Import then disable old style Toaster conf files (before 'merged_attr')
+            old_toaster_local = "%s/conf/toaster.conf" % project_path
+            if os.path.isfile(old_toaster_local):
+                self.scan_conf(old_toaster_local)
+                shutil.move(old_toaster_local, old_toaster_local+"_old")
+            old_toaster_layer = "%s/conf/toaster-bblayers.conf" % project_path
+            if os.path.isfile(old_toaster_layer):
+                self.scan_conf(old_toaster_layer)
+                shutil.move(old_toaster_layer, old_toaster_layer+"_old")
+
+    # Scan the found conf variables (if any)
+    def apply_conf_variables(self,project,layers_list,lv_dict,release=None):
+        if self.vars:
+            # Catch vars relevant to Toaster (in case no Toaster section)
+            self.update_project_vars(project,'DISTRO')
+            self.update_project_vars(project,'MACHINE')
+            self.update_project_vars(project,'IMAGE_INSTALL_append')
+            self.update_project_vars(project,'IMAGE_FSTYPES')
+            self.update_project_vars(project,'PACKAGE_CLASSES')
+            # These vars are typically only assigned by Toaster
+            #self.update_project_vars(project,'DL_DIR')
+            #self.update_project_vars(project,'SSTATE_DIR')
+
+            # Assert found Toaster vars
+            for var in self.toaster_vars.keys():
+                pv, create = ProjectVariable.objects.get_or_create(project = project, name = var)
+                pv.value = self.toaster_vars[var]
+                _log("* Add/update Toaster var '%s' = '%s'" % (pv.name,pv.value))
+                pv.save()
+
+            # Assert found BBLAYERS
+            if 0 < verbose:
+                for pl in ProjectLayer.objects.filter(project=project):
+                    release_name = 'None' if not pl.layercommit.release else pl.layercommit.release.name
+                    print(" BEFORE:ProjectLayer=%s,%s,%s,%s" % (pl.layercommit.layer.name,release_name,pl.layercommit.branch,pl.layercommit.commit))
+            self.apply_conf_bblayers(layers_list,lv_dict,project,release)
+            if 0 < verbose:
+                for pl in ProjectLayer.objects.filter(project=project):
+                    release_name = 'None' if not pl.layercommit.release else pl.layercommit.release.name
+                    print(" AFTER :ProjectLayer=%s,%s,%s,%s" % (pl.layercommit.layer.name,release_name,pl.layercommit.branch,pl.layercommit.commit))
+
+
+    def handle(self, *args, **options):
+        project_name = options['name']
+        project_path = options['path']
+        project_callback = options['callback'] if options['callback'] else ''
+        release_name = options['release'] if options['release'] else ''
+
+        #
+        # Delete project
+        #
+
+        if options['delete_project']:
+            try:
+                print("Project '%s' delete from Toaster database" % (project_name))
+                project = Project.objects.get(name=project_name)
+                # TODO: deep project delete
+                project.delete()
+                print("Project '%s' Deleted" % (project_name))
+                return
+            except Exception as e:
+                print("Project '%s' not found, not deleted (%s)" % (project_name,e))
+                return
+
+        #
+        # Create/Update/Import project
+        #
+
+        # See if project (by name) exists
+        project = None
+        try:
+            # Project already exists
+            project = Project.objects.get(name=project_name)
+        except Exception as e:
+            pass
+
+        # Find the installation's default release
+        default_release = Release.objects.get(id=1)
+
+        # SANITY: if 'reconfig' but project does not exist (deleted externally), switch to 'import'
+        if ("reconfigure" == options['command']) and (None == project):
+            options['command'] = 'import'
+
+        # 'Configure':
+        if "configure" == options['command']:
+            # Note: ignore any existing conf files
+            # create project, SANITY: reuse any project of same name
+            project = Project.objects.create_project(project_name,default_release,project)
+
+        # 'Re-configure':
+        if "reconfigure" == options['command']:
+            # Scan the directory's conf files
+            self.scan_conf_variables(project_path)
+            # Scan the layer list
+            layers_list,lv_dict = self.extract_bblayers()
+            # Apply any new layers or variables
+            self.apply_conf_variables(project,layers_list,lv_dict)
+
+        # 'Import':
+        if "import" == options['command']:
+            # Scan the directory's conf files
+            self.scan_conf_variables(project_path)
+            # Remove these Toaster controlled variables
+            for var in ('DL_DIR','SSTATE_DIR'):
+                self.vars.pop(var, None)
+                self.toaster_vars.pop(var, None)
+            # Scan the layer list
+            layers_list,lv_dict = self.extract_bblayers()
+            # Find the directory's release, and promote to default_release if local paths
+            release = self.find_import_release(layers_list,lv_dict,default_release)
+            # create project, SANITY: reuse any project of same name
+            project = Project.objects.create_project(project_name,release,project)
+            # Apply any new layers or variables
+            self.apply_conf_variables(project,layers_list,lv_dict,release)
+            # WORKAROUND: since we now derive the release, redirect 'newproject_specific' to 'project_specific'
+            project.set_variable('INTERNAL_PROJECT_SPECIFIC_SKIPRELEASE','1')
+
+        # Set up the project's meta data
+        project.builddir = project_path
+        project.merged_attr = True
+        project.set_variable(Project.PROJECT_SPECIFIC_CALLBACK,project_callback)
+        project.set_variable(Project.PROJECT_SPECIFIC_STATUS,Project.PROJECT_SPECIFIC_EDIT)
+        if ("configure" == options['command']) or ("import" == options['command']):
+            # preset the mode and default image recipe
+            project.set_variable(Project.PROJECT_SPECIFIC_ISNEW,Project.PROJECT_SPECIFIC_NEW)
+            project.set_variable(Project.PROJECT_SPECIFIC_DEFAULTIMAGE,"core-image-minimal")
+            # Assert any extended/custom actions or variables for new non-Toaster projects
+            if not len(self.toaster_vars):
+                pass
+        else:
+            project.set_variable(Project.PROJECT_SPECIFIC_ISNEW,Project.PROJECT_SPECIFIC_NONE)
+
+        # Save the updated Project
+        project.save()
+
+        _log("Buildimport:project='%s' at '%d'" % (project_name,project.id))
+
+        if ('DEFAULT_IMAGE' in self.vars) and (self.vars['DEFAULT_IMAGE']):
+            print("|Default_image=%s|Project_id=%d" % (self.vars['DEFAULT_IMAGE'],project.id))
+        else:
+            print("|Project_id=%d" % (project.id))
+
diff --git a/poky/bitbake/toaster-requirements.txt b/poky/bitbake/toaster-requirements.txt
index c0ec368..a682b08 100644
--- a/poky/bitbake/toaster-requirements.txt
+++ b/poky/bitbake/toaster-requirements.txt
@@ -1,3 +1,3 @@
-Django>1.8,<1.11.9
+Django>1.8,<1.12
 beautifulsoup4>=4.4.0
 pytz
diff --git a/poky/documentation/Makefile b/poky/documentation/Makefile
index e41d5a0..093422f 100644
--- a/poky/documentation/Makefile
+++ b/poky/documentation/Makefile
@@ -165,6 +165,7 @@
 TARFILES = dev-style.css dev-manual.html figures/buildhistory-web.png \
            figures/dev-title.png figures/buildhistory.png \
            figures/recipe-workflow.png figures/bitbake-build-flow.png \
+           figures/multiconfig_files.png \
            eclipse
 	endif
 
@@ -261,7 +262,7 @@
         figures/image-generation.png figures/key-dev-elements.png\
 	figures/sdk-generation.png figures/recipe-workflow.png \
 	figures/build-workspace-directory.png figures/mega-title.png \
-	figures/toaster-title.png figures/hosted-service.png \
+	figures/toaster-title.png figures/hosted-service.png figures/multiconfig_files.png \
 	figures/simple-configuration.png figures/poky-reference-distribution.png \
 	figures/compatible-layers.png figures/import-layer.png figures/new-project.png \
 	figures/sdk-environment.png figures/sdk-installed-standard-sdk-directory.png \
diff --git a/poky/documentation/brief-yoctoprojectqs/brief-yoctoprojectqs.xml b/poky/documentation/brief-yoctoprojectqs/brief-yoctoprojectqs.xml
index 62c4964..f8b01ec 100644
--- a/poky/documentation/brief-yoctoprojectqs/brief-yoctoprojectqs.xml
+++ b/poky/documentation/brief-yoctoprojectqs/brief-yoctoprojectqs.xml
@@ -37,17 +37,30 @@
             hardware.
             You will use Yocto Project to build a reference embedded OS
             called Poky.
-            <note>
-                The examples in this paper assume you are using a native Linux
-                system running a recent Ubuntu Linux distribution.
-                If the machine you want to use
-                Yocto Project on to build an image is not a native Linux
-                system, you can still perform these steps by using CROss
-                PlatformS (CROPS) and setting up a Poky container.
-                See the
-                <ulink url='&YOCTO_DOCS_DEV_URL;#setting-up-to-use-crops'>Setting Up to Use CROss PlatformS (CROPS)</ulink>"
-                section in the Yocto Project Development Tasks Manual for more
-                information.
+            <note><title>Notes</title>
+                <itemizedlist>
+                    <listitem><para>
+                        The examples in this paper assume you are using a
+                        native Linux system running a recent Ubuntu Linux
+                        distribution.
+                        If the machine you want to use Yocto Project on to
+                        build an image
+                        (<ulink url='&YOCTO_DOCS_REF_URL;#hardware-build-system-term'>build host</ulink>)
+                        is not a native Linux system, you can
+                        still perform these steps by using CROss PlatformS
+                        (CROPS) and setting up a Poky container.
+                        See the
+                        <ulink url='&YOCTO_DOCS_DEV_URL;#setting-up-to-use-crops'>Setting Up to Use CROss PlatformS (CROPS)</ulink>"
+                        section in the Yocto Project Development Tasks Manual for more
+                        information.
+                        </para></listitem>
+                    <listitem><para>
+                        You cannot use a build host that is using the
+                        <ulink url='https://en.wikipedia.org/wiki/Windows_Subsystem_for_Linux'>Windows Subsystem for Linux</ulink>
+                        (WSL).
+                        The Yocto Project is not compatible with WSL.
+                        </para></listitem>
+                </itemizedlist>
             </note>
         </para>
 
@@ -75,6 +88,10 @@
                     Linux distributions that support the Yocto Project, see the
                     "<ulink url='&YOCTO_DOCS_REF_URL;#detailed-supported-distros'>Supported Linux Distributions</ulink>"
                     section in the Yocto Project Reference Manual.
+                    For detailed information on preparing your build host, see
+                    the
+                    "<ulink url='&YOCTO_DOCS_DEV_URL;#dev-preparing-the-build-host'>Preparing the Build Host</ulink>"
+                    section in the Yocto Project Development Tasks Manual.
                     </para></listitem>
                 <listitem><para>
                     <itemizedlist>
@@ -110,7 +127,7 @@
             <note>
                 For host package requirements on all supported Linux
                 distributions, see the
-                "<ulink url='&YOCTO_DOCS_REF_URL;#required-packages-for-the-host-development-system'>Required Packages for the Host Development System</ulink>"
+                "<ulink url='&YOCTO_DOCS_REF_URL;#required-packages-for-the-build-host'>Required Packages for the Build Host</ulink>"
                 section in the Yocto Project Reference Manual.
             </note>
             <literallayout class='monospaced'>
diff --git a/poky/documentation/bsp-guide/bsp-guide.xml b/poky/documentation/bsp-guide/bsp-guide.xml
index 0389c72..0d5b6b1 100644
--- a/poky/documentation/bsp-guide/bsp-guide.xml
+++ b/poky/documentation/bsp-guide/bsp-guide.xml
@@ -122,14 +122,14 @@
                 <revremark>Released with the Yocto Project 2.5 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.1</revnumber>
-                <date>September 2018</date>
-                <revremark>The initial document released with the Yocto Project 2.5.1 Release.</revremark>
+                <revnumber>2.6</revnumber>
+                <date>November 2018</date>
+                <revremark>Released with the Yocto Project 2.6 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.2</revnumber>
+                <revnumber>2.6.1</revnumber>
                 <date>&REL_MONTH_YEAR;</date>
-                <revremark>The initial document released with the Yocto Project 2.5.2 Release.</revremark>
+                <revremark>Released with the Yocto Project 2.6.1 Release.</revremark>
             </revision>
         </revhistory>
 
diff --git a/poky/documentation/bsp-guide/bsp.xml b/poky/documentation/bsp-guide/bsp.xml
index 00a28b0..0bb0b68 100644
--- a/poky/documentation/bsp-guide/bsp.xml
+++ b/poky/documentation/bsp-guide/bsp.xml
@@ -187,7 +187,7 @@
                 <emphasis>Set Up the Build Environment:</emphasis>
                 Be sure you are set up to use BitBake in a shell.
                 See the
-                "<ulink url='&YOCTO_DOCS_DEV_URL;#setting-up-the-development-host-to-use-the-yocto-project'>Preparing the Build Host</ulink>"
+                "<ulink url='&YOCTO_DOCS_DEV_URL;#dev-preparing-the-build-host'>Preparing the Build Host</ulink>"
                 section in the Yocto Project Development Tasks Manual for information
                 on how to get a build host ready that is either a native
                 Linux machine or a machine that uses CROPS.
@@ -1012,7 +1012,7 @@
                 to Support Development Using the Yocto
                 Project</emphasis>:
                 See the
-                "<ulink url='&YOCTO_DOCS_DEV_URL;#setting-up-the-development-host-to-use-the-yocto-project'>Preparing the Build Host</ulink>"
+                "<ulink url='&YOCTO_DOCS_DEV_URL;#dev-preparing-the-build-host'>Preparing the Build Host</ulink>"
                 section in the Yocto Project Development Tasks
                 Manual for options on how to get a system ready
                 to use the Yocto Project.
diff --git a/poky/documentation/dev-manual/dev-manual-common-tasks.xml b/poky/documentation/dev-manual/dev-manual-common-tasks.xml
index fe1bfba..c75e718 100644
--- a/poky/documentation/dev-manual/dev-manual-common-tasks.xml
+++ b/poky/documentation/dev-manual/dev-manual-common-tasks.xml
@@ -189,8 +189,8 @@
                                 <ulink url='&YOCTO_WIKI_URL;/wiki/Releases'>Yocto Project</ulink>
                                 releases for which the current version is
                                 compatible.
-                                This variable is a good way to indicate how
-                                up-to-date your particular layer is.
+                                This variable is a good way to indicate if
+                                your particular layer is current.
                                 </para></listitem>
                         </itemizedlist>
                         </para></listitem>
@@ -3237,30 +3237,22 @@
                 post-installation script to be delayed until the first boot.
                 For example, the script might need to be executed on the
                 device itself.
-                To delay script execution until boot time, use the following
-                structure in the post-installation script:
-                <literallayout class='monospaced'>
-     pkg_postinst_<replaceable>PACKAGENAME</replaceable>() {
-     if [ x"$D" = "x" ]; then
-          # Actions to carry out on the device go here
-     else
-          exit 1
-     fi
-     }
-                </literallayout>
+                To delay script execution until boot time, you must explicitly
+                mark post installs to defer to the target.
+                You can use <filename>pkg_postinst_ontarget()</filename> or
+                call
+                <filename>postinst-intercepts defer_to_first_boot</filename>
+                from <filename>pkg_postinst()</filename>.
+                Any failure of a <filename>pkg_postinst()</filename> script
+                (including exit 1) triggers an error during the
+                <ulink url='&YOCTO_DOCS_REF_URL;#ref-tasks-rootfs'><filename>do_rootfs</filename></ulink>
+                task.
             </para>
 
             <para>
-                The previous example delays execution until the image boots
-                again because the environment variable <filename>D</filename>
-                points to the directory containing the image when
-                the root filesystem is created at build time but is unset
-                when executed on the first boot.
-            </para>
-
-            <para>
-                If you have recipes that use <filename>pkg_postinst</filename>
-                scripts and they require the use of non-standard native
+                If you have recipes that use
+                <filename>pkg_postinst</filename> function
+                and they require the use of non-standard native
                 tools that have dependencies during rootfs construction, you
                 need to use the
                 <ulink url='&YOCTO_DOCS_REF_URL;#var-PACKAGE_WRITE_DEPS'><filename>PACKAGE_WRITE_DEPS</filename></ulink>
@@ -3279,8 +3271,8 @@
                 <filename>pkg_prerm</filename>, and
                 <filename>pkg_postrm</filename>, respectively.
                 These scrips work in exactly the same way as does
-                <filename>pkg_postinst</filename> with the exception that they
-                run at different times.
+                <filename>pkg_postinst</filename> with the exception
+                that they run at different times.
                 Also, because of when they run, they are not applicable to
                 being run at image creation time like
                 <filename>pkg_postinst</filename>.
@@ -4264,7 +4256,7 @@
                         You need to be sure that your development host is
                         set up to use the Yocto Project.
                         For information on how to set up your host, see the
-                        "<link linkend='setting-up-the-development-host-to-use-the-yocto-project'>Preparing the Build Host</link>"
+                        "<link linkend='dev-preparing-the-build-host'>Preparing the Build Host</link>"
                         section.
                         </para></listitem>
                     <listitem><para>
@@ -5321,104 +5313,215 @@
             </para>
         </section>
 
-        <section id='platdev-building-targets-with-multiple-configurations'>
-            <title>Building Targets with Multiple Configurations</title>
+        <section id='dev-building-images-for-multiple-targets-using-multiple-configurations'>
+            <title>Building Images for Multiple Targets Using Multiple Configurations</title>
 
             <para>
-                Bitbake also has functionality that allows you to build
-                multiple targets at the same time, where each target uses
-                a different configuration.
+                You can use a single <filename>bitbake</filename> command
+                to build multiple images or packages for different targets
+                where each image or package requires a different configuration
+                (multiple configuration builds).
+                The builds, in this scenario, are sometimes referred to as
+                "multiconfigs", and this section uses that term throughout.
             </para>
 
             <para>
-                In order to accomplish this, you setup each of the configurations
-                you need to use in parallel by placing the configuration files in
-                your current build directory alongside the usual
-                <filename>local.conf</filename> file.
+                This section describes how to set up for multiple
+                configuration builds and how to account for cross-build
+                dependencies between the multiconfigs.
             </para>
 
-            <para>
-                Follow these guidelines to create an environment that supports
-                multiple configurations:
-                <itemizedlist>
-                    <listitem><para>
-                        <emphasis>Create Configuration Files</emphasis>:
-                        You need to create a single configuration file for each
-                        configuration for which you want to add support.
-                        These files would contain lines such as the following:
-                        <literallayout class='monospaced'>
-     MACHINE = "A"
-                        </literallayout>
-                        The files would contain any other variables that can
-                        be set and built in the same directory.
-                        <note>
-                            You can change the
-                            <ulink url='&YOCTO_DOCS_REF_URL;#var-TMPDIR'><filename>TMPDIR</filename></ulink>
-                            to not conflict.
-                        </note></para>
+            <section id='dev-setting-up-and-running-a-multiple-configuration-build'>
+                <title>Setting Up and Running a Multiple Configuration Build</title>
 
-                        <para>
-                        Furthermore, the configuration file must be located in the
-                        current build directory in a directory named
-                        <filename>multiconfig</filename> under the build's
-                        <filename>conf</filename> directory where
-                        <filename>local.conf</filename> resides.
-                        The reason for this restriction is because the
-                        <filename>BBPATH</filename> variable is not constructed
-                        until the layers are parsed.
-                        Consequently, using the configuration file as a
-                        pre-configuration file is not possible unless it is
-                        located in the current working directory.
-                        </para></listitem>
-                    <listitem><para>
-                        <emphasis>Add the BitBake Multi-Config Variable to you Local Configuration File</emphasis>:
-                        Use the
-                        <filename>BBMULTICONFIG</filename>
-                        variable in your <filename>conf/local.conf</filename>
-                        configuration file to specify each separate configuration.
-                        For example, the following line tells BitBake it should load
-                        <filename>conf/multiconfig/configA.conf</filename>,
-                        <filename>conf/multiconfig/configB.conf</filename>, and
-                        <filename>conf/multiconfig/configC.conf</filename>.
-                        <literallayout class='monospaced'>
-     BBMULTICONFIG = "configA configB configC"
-                        </literallayout>
-                        </para></listitem>
-                    <listitem><para>
-                        <emphasis>Launch BitBake</emphasis>:
-                        Use the following BitBake command form to launch the
-                        build:
-                        <literallayout class='monospaced'>
+                <para>
+                    To accomplish a multiple configuration build, you must
+                    define each target's configuration separately using
+                    a parallel configuration file in the
+                    <ulink url='&YOCTO_DOCS_REF_URL;#build-directory'>Build Directory</ulink>,
+                    and you must follow a required file hierarchy.
+                    Additionally, you must enable the multiple configuration
+                    builds in your <filename>local.conf</filename> file.
+                </para>
+
+                <para>
+                    Follow these steps to set up and execute multiple
+                    configuration builds:
+                    <itemizedlist>
+                        <listitem><para>
+                            <emphasis>Create Separate Configuration Files</emphasis>:
+                            You need to create a single configuration file for
+                            each build target (each multiconfig).
+                            Minimally, each configuration file must define the
+                            machine and the temporary directory BitBake uses
+                            for the build.
+                            Suggested practice dictates that you do not
+                            overlap the temporary directories
+                            used during the builds.
+                            However, it is possible that you can share the
+                            temporary directory
+                            (<ulink url='&YOCTO_DOCS_REF_URL;#var-TMPDIR'><filename>TMPDIR</filename></ulink>).
+                            For example, consider a scenario with two
+                            different multiconfigs for the same
+                            <ulink url='&YOCTO_DOCS_REF_URL;#var-MACHINE'><filename>MACHINE</filename></ulink>: "qemux86" built for
+                            two distributions such as "poky" and "poky-lsb".
+                            In this case, you might want to use the same
+                            <filename>TMPDIR</filename>.</para>
+
+                            <para>Here is an example showing the minimal
+                            statements needed in a configuration file for
+                            a "qemux86" target whose temporary build directory
+                            is <filename>tmpmultix86</filename>:
+                            <literallayout class='monospaced'>
+     MACHINE="qemux86"
+     TMPDIR="${TOPDIR}/tmpmultix86"
+                            </literallayout></para>
+
+                            <para>The location for these multiconfig
+                            configuration files is specific.
+                            They must reside in the current build directory in
+                            a sub-directory of <filename>conf</filename> named
+                            <filename>multiconfig</filename>.
+                            Following is an example that defines two
+                            configuration files for the "x86" and "arm"
+                            multiconfigs:
+                            <imagedata fileref="figures/multiconfig_files.png" align="center" width="4in" depth="3in" />
+                            </para>
+
+                            <para>The reason for this required file hierarchy
+                            is because the <filename>BBPATH</filename> variable
+                            is not constructed until the layers are parsed.
+                            Consequently, using the configuration file as a
+                            pre-configuration file is not possible unless it is
+                            located in the current working directory.
+                            </para></listitem>
+                        <listitem><para>
+                            <emphasis>Add the BitBake Multi-configuration Variable to the Local Configuration File</emphasis>:
+                            Use the
+                            <ulink url='&YOCTO_DOCS_REF_URL;#var-BBMULTICONFIG'><filename>BBMULTICONFIG</filename></ulink>
+                            variable in your
+                            <filename>conf/local.conf</filename> configuration
+                            file to specify each multiconfig.
+                            Continuing with the example from the previous
+                            figure, the <filename>BBMULTICONFIG</filename>
+                            variable needs to enable two multiconfigs: "x86"
+                            and "arm" by specifying each configuration file:
+                            <literallayout class='monospaced'>
+     BBMULTICONFIG = "x86 arm"
+                            </literallayout>
+                            </para></listitem>
+                        <listitem><para>
+                            <emphasis>Launch BitBake</emphasis>:
+                            Use the following BitBake command form to launch the
+                            multiple configuration build:
+                            <literallayout class='monospaced'>
      $ bitbake [multiconfig:<replaceable>multiconfigname</replaceable>:]<replaceable>target</replaceable> [[[multiconfig:<replaceable>multiconfigname</replaceable>:]<replaceable>target</replaceable>] ... ]
-                        </literallayout>
-                        Following is an example that supports building a minimal
-                        image for configuration A alongside a standard
-                        <filename>core-image-sato</filename>, which takes its
-                        configuration from <filename>local.conf</filename>:
-                        <literallayout class='monospaced'>
-     $ bitbake multiconfig:configA:core-image-minimal core-image-sato
-                        </literallayout>
-                        </para></listitem>
-                </itemizedlist>
-            </para>
-
-            <para>
-                Support for multiple configurations in this current release of
-                the Yocto Project (&DISTRO_NAME; &DISTRO;) has some known issues:
-                <itemizedlist>
-                    <listitem><para>
-                        No inter-multi-configuration dependencies exist.
-                        </para></listitem>
-                    <listitem><para>
-                        Shared State (sstate) optimizations do not exist.
-                        Consequently, if the build uses the same object twice
+                            </literallayout>
+                            For the example in this section, the following
+                            command applies:
+                            <literallayout class='monospaced'>
+     $ bitbake multiconfig:x86:core-image-minimal multiconfig:arm:core-image-sato
+                            </literallayout>
+                            The previous BitBake command builds a
+                            <filename>core-image-minimal</filename> image that
+                            is configured through the
+                            <filename>x86.conf</filename> configuration file
+                            and builds a <filename>core-image-sato</filename>
+                            image that is configured through the
+                            <filename>arm.conf</filename> configuration file.
+                            </para></listitem>
+                    </itemizedlist>
+                    <note>
+                        Support for multiple configuration builds in the
+                        Yocto Project &DISTRO; (&DISTRO_NAME;) Release does
+                        not include Shared State (sstate) optimizations.
+                        Consequently, if a build uses the same object twice
                         in, for example, two different
                         <filename>TMPDIR</filename> directories, the build
-                        will either load from an existing sstate cache at the
-                        start or build the object twice.
-                        </para></listitem>
-                </itemizedlist>
-            </para>
+                        either loads from an existing sstate cache for that
+                        build at the start or builds the object fresh.
+                    </note>
+                </para>
+            </section>
+
+            <section id='dev-enabling-multiple-configuration-build-dependencies'>
+                <title>Enabling Multiple Configuration Build Dependencies</title>
+
+                <para>
+                    Sometimes dependencies can exist between targets
+                    (multiconfigs) in a multiple configuration build.
+                    For example, suppose that in order to build a
+                    <filename>core-image-sato</filename> image for an "x86"
+                    multiconfig, the root filesystem of an "arm"
+                    multiconfig must exist.
+                    This dependency is essentially that the
+                    <ulink url='&YOCTO_DOCS_REF_URL;#ref-tasks-image'><filename>do_image</filename></ulink>
+                    task in the <filename>core-image-sato</filename> recipe
+                    depends on the completion of the
+                    <ulink url='&YOCTO_DOCS_REF_URL;#ref-tasks-rootfs'><filename>do_rootfs</filename></ulink>
+                    task of the <filename>core-image-minimal</filename>
+                    recipe.
+                </para>
+
+                <para>
+                    To enable dependencies in a multiple configuration
+                    build, you must declare the dependencies in the recipe
+                    using the following statement form:
+                    <literallayout class='monospaced'>
+     <replaceable>task_or_package</replaceable>[mcdepends] = "multiconfig:<replaceable>from_multiconfig</replaceable>:<replaceable>to_multiconfig</replaceable>:<replaceable>recipe_name</replaceable>:<replaceable>task_on_which_to_depend</replaceable>"
+                    </literallayout>
+                    To better show how to use this statement, consider the
+                    example scenario from the first paragraph of this section.
+                    The following statement needs to be added to the recipe
+                    that builds the <filename>core-image-sato</filename>
+                    image:
+                    <literallayout class='monospaced'>
+     do_image[mcdepends] = "multiconfig:x86:arm:core-image-minimal:do_rootfs"
+                    </literallayout>
+                    In this example, the
+                    <replaceable>from_multiconfig</replaceable> is "x86".
+                    The <replaceable>to_multiconfig</replaceable> is "arm".
+                    The task on which the <filename>do_image</filename> task
+                    in the recipe depends is the <filename>do_rootfs</filename>
+                    task from the <filename>core-image-minimal</filename>
+                    recipe associated with the "arm" multiconfig.
+               </para>
+
+               <para>
+                   Once you set up this dependency, you can build the
+                   "x86" multiconfig using a BitBake command as follows:
+                   <literallayout class='monospaced'>
+     $ bitbake multiconfig:x86:core-image-sato
+                   </literallayout>
+                   This command executes all the tasks needed to create
+                   the <filename>core-image-sato</filename> image for the
+                   "x86" multiconfig.
+                   Because of the dependency, BitBake also executes through
+                   the <filename>do_rootfs</filename> task for the "arm"
+                   multiconfig build.
+               </para>
+
+               <para>
+                   Having a recipe depend on the root filesystem of another
+                   build might not seem that useful.
+                   Consider this change to the statement in the
+                   <filename>core-image-sato</filename> recipe:
+                   <literallayout class='monospaced'>
+     do_image[mcdepends] = "multiconfig:x86:arm:core-image-minimal:do_image"
+                   </literallayout>
+                   In this case, BitBake must create the
+                   <filename>core-image-minimal</filename> image for the
+                   "arm" build since the "x86" build depends on it.
+               </para>
+
+               <para>
+                   Because "x86" and "arm" are enabled for multiple
+                   configuration builds and have separate configuration
+                   files, BitBake places the artifacts for each build in the
+                   respective temporary build directories (i.e.
+                   <ulink url='&YOCTO_DOCS_REF_URL;#var-TMPDIR'><filename>TMPDIR</filename></ulink>).
+               </para>
+            </section>
         </section>
 
         <section id='building-an-initramfs-image'>
@@ -7159,13 +7262,12 @@
                         easier-to-use and more flexible replacements for an
                         existing functionality in OE-Core's
                         <ulink url='&YOCTO_DOCS_REF_URL;#ref-classes-image-live'><filename>image-live</filename></ulink>
-                        class and <filename>mkefidisk.sh</filename> script.
-                        The difference between
-                        Wic and those examples is
-                        that with Wic the
-                        functionality of those scripts is implemented
-                        by a general-purpose partitioning language, which is
-                        based on Redhat kickstart syntax.</para></listitem>
+                        class.
+                        The difference between Wic and those examples is
+                        that with Wic the functionality of those scripts is
+                        implemented by a general-purpose partitioning language,
+                        which is based on Redhat kickstart syntax.
+                        </para></listitem>
                 </itemizedlist>
             </para>
         </section>
@@ -11400,8 +11502,8 @@
                             within a separately started QEMU or any
                             other virtual machine manager.
                             </para></listitem>
-                        <listitem><para><emphasis>"Systemd-bootTarget":</emphasis>
-                            Choose "Systemd-bootTarget" if your hardware is
+                        <listitem><para><emphasis>"SystemdbootTarget":</emphasis>
+                            Choose "SystemdbootTarget" if your hardware is
                             an EFI-based machine with
                             <filename>systemd-boot</filename> as bootloader and
                             <filename>core-image-testmaster</filename>
@@ -11409,10 +11511,10 @@
                             Also, your hardware under test must be in a
                             DHCP-enabled network that gives it the same IP
                             address for each reboot.</para>
-                            <para>If you choose "Systemd-bootTarget", there are
+                            <para>If you choose "SystemdbootTarget", there are
                             additional requirements and considerations.
                             See the
-                            "<link linkend='selecting-systemd-boottarget'>Selecting Systemd-bootTarget</link>"
+                            "<link linkend='selecting-systemdboottarget'>Selecting SystemdbootTarget</link>"
                             section, which follows, for more information.
                             </para></listitem>
                         <listitem><para><emphasis>"BeagleBoneTarget":</emphasis>
@@ -11458,12 +11560,12 @@
                 </para>
             </section>
 
-            <section id='selecting-systemd-boottarget'>
-                <title>Selecting Systemd-bootTarget</title>
+            <section id='selecting-systemdboottarget'>
+                <title>Selecting SystemdbootTarget</title>
 
                 <para>
                     If you did not set <filename>TEST_TARGET</filename> to
-                    "Systemd-bootTarget", then you do not need any information
+                    "SystemdbootTarget", then you do not need any information
                     in this section.
                     You can skip down to the
                     "<link linkend='qemu-image-running-tests'>Running Tests</link>"
@@ -11472,7 +11574,7 @@
 
                 <para>
                     If you did set <filename>TEST_TARGET</filename> to
-                    "Systemd-bootTarget", you also need to perform a one-time
+                    "SystemdbootTarget", you also need to perform a one-time
                     setup of your master image by doing the following:
                     <orderedlist>
                         <listitem><para><emphasis>Set <filename>EFI_PROVIDER</filename>:</emphasis>
@@ -11543,7 +11645,7 @@
 
                 <para>
                     The final thing you need to do when setting
-                    <filename>TEST_TARGET</filename> to "Systemd-bootTarget" is
+                    <filename>TEST_TARGET</filename> to "SystemdbootTarget" is
                     to set up the test image:
                     <orderedlist>
                         <listitem><para><emphasis>Set up your <filename>local.conf</filename> file:</emphasis>
@@ -11552,7 +11654,7 @@
                             <literallayout class='monospaced'>
      IMAGE_FSTYPES += "tar.gz"
      INHERIT += "testimage"
-     TEST_TARGET = "Systemd-bootTarget"
+     TEST_TARGET = "SystemdbootTarget"
      TEST_TARGET_IP = "192.168.2.3"
                             </literallayout>
                             </para></listitem>
@@ -11687,16 +11789,15 @@
                         To run the tests automatically after the
                         OpenEmbedded build system successfully creates an image,
                         first set the
-                        <ulink url='&YOCTO_DOCS_REF_URL;#var-TEST_IMAGE'><filename>TEST_IMAGE</filename></ulink>
+                        <ulink url='&YOCTO_DOCS_REF_URL;#var-TESTIMAGE_AUTO'><filename>TESTIMAGE_AUTO</filename></ulink>
                         variable to "1" in your <filename>local.conf</filename>
                         file in the
                         <ulink url='&YOCTO_DOCS_REF_URL;#build-directory'>Build Directory</ulink>:
                         <literallayout class='monospaced'>
-     TEST_IMAGE = "1"
+     TESTIMAGE_AUTO = "1"
                         </literallayout>
                         Next, build your image.
-                        If the image successfully builds, the tests will be
-                        run:
+                        If the image successfully builds, the tests run:
                         <literallayout class='monospaced'>
      bitbake core-image-sato
                         </literallayout></para></listitem>
@@ -11969,7 +12070,7 @@
                                     The target controller object used to deploy
                                     and start an image on a particular target
                                     (e.g. QemuTarget, SimpleRemote, and
-                                    Systemd-bootTarget).
+                                    SystemdbootTarget).
                                     Tests usually use the following:
                                     <itemizedlist>
                                         <listitem><para><emphasis><filename>ip</filename>:</emphasis>
@@ -15072,6 +15173,31 @@
                 </para>
             </section>
         </section>
+
+        <section id='copying-licenses-that-do-not-exist'>
+            <title>Copying Licenses that Do Not Exist</title>
+
+            <para>
+                Some packages, such as the linux-firmware package, have many
+                licenses that are not in any way common.
+                You can avoid adding a lot of these types of common license
+                files, which are only applicable to a specific package, by using
+                the
+                <ulink url='&YOCTO_DOCS_REF_URL;#var-NO_GENERIC_LICENSE'><filename>NO_GENERIC_LICENSE</filename></ulink>
+                variable.
+                Using this variable also avoids QA errors when you use a
+                non-common, non-CLOSED license in a recipe.
+            </para>
+
+            <para>
+                The following is an example that uses the
+                <filename>LICENSE.Abilis.txt</filename>
+                file as the license from the fetched source:
+                <literallayout class='monospaced'>
+     NO_GENERIC_LICENSE[Firmware-Abilis] = "LICENSE.Abilis.txt"
+                </literallayout>
+            </para>
+        </section>
     </section>
 
     <section id='using-the-error-reporting-tool'>
diff --git a/poky/documentation/dev-manual/dev-manual-intro.xml b/poky/documentation/dev-manual/dev-manual-intro.xml
index f457c80..3a34094 100644
--- a/poky/documentation/dev-manual/dev-manual-intro.xml
+++ b/poky/documentation/dev-manual/dev-manual-intro.xml
@@ -19,7 +19,7 @@
         </para>
 
         <para>
-            The following list describes what you can get from this manual:
+            This manual provides the following:
             <itemizedlist>
                 <listitem><para>
                     Procedures that help you get going with the Yocto Project.
@@ -44,7 +44,7 @@
         </para>
 
         <para>
-            This manual will not give you the following:
+            This manual does not provide the following:
             <itemizedlist>
                 <listitem><para>
                     Redundant Step-by-step Instructions:
diff --git a/poky/documentation/dev-manual/dev-manual-start.xml b/poky/documentation/dev-manual/dev-manual-start.xml
index d8726b4..3f971ba 100644
--- a/poky/documentation/dev-manual/dev-manual-start.xml
+++ b/poky/documentation/dev-manual/dev-manual-start.xml
@@ -10,8 +10,10 @@
     This chapter provides procedures related to getting set up to use the
     Yocto Project.
     You can learn about creating a team environment that develops using the
-    Yocto Project, how to set up a build host, how to locate Yocto Project
-    source repositories, and how to create local Git repositories.
+    Yocto Project, how to set up a
+    <ulink url='&YOCTO_DOCS_REF_URL;#hardware-build-system-term'>build host</ulink>,
+    how to locate Yocto Project source repositories, and how to create local
+    Git repositories.
 </para>
 
 <section id="usingpoky-changes-collaborate">
@@ -19,69 +21,71 @@
 
     <para>
         It might not be immediately clear how you can use the Yocto
-        Project in a team development environment, or scale it for a large
-        team of developers.
+        Project in a team development environment, or how to scale it for a
+        large team of developers.
         One of the strengths of the Yocto Project is that it is extremely
         flexible.
         Thus, you can adapt it to many different use cases and scenarios.
-        However, these characteristics can cause a struggle if you are trying
+        However, this flexibility could cause difficulties if you are trying
         to create a working setup that scales across a large team.
     </para>
 
     <para>
         To help you understand how to set up this type of environment,
-        this section presents a procedure that gives you the information
-        to learn how to get the results you want.
+        this section presents a procedure that gives you information
+        that can help you get the results you want.
         The procedure is high-level and presents some of the project's most
         successful experiences, practices, solutions, and available
-        technologies that work well.
+        technologies that have proved to work well in the past.
         Keep in mind, the procedure here is a starting point.
-        You can build off it and customize it to fit any
+        You can build off these steps and customize the procedure to fit any
         particular working environment and set of practices.
         <orderedlist>
             <listitem><para>
                 <emphasis>Determine Who is Going to be Developing:</emphasis>
                 You need to understand who is going to be doing anything
                 related to the Yocto Project and what their roles would be.
-                Making this determination is essential to completing the
+                Making this determination is essential to completing
                 steps two and three, which are to get your equipment together
                 and set up your development environment's hardware topology.
                 </para>
 
                 <para>The following roles exist:
-                <itemizedlist>
-                    <listitem><para>
-                        <emphasis>Application Development:</emphasis>
-                        These types of developers do application level work
-                        on top of an existing software stack.
-                        </para></listitem>
-                    <listitem><para>
-                        <emphasis>Core System Development:</emphasis>
-                        These types of developers work on the contents of the
-                        operating system image itself.
-                        </para></listitem>
-                    <listitem><para>
-                        <emphasis>Build Engineer:</emphasis>
-                        This type of developer manages Autobuilders and
-                        releases.
-                        Not all environments need a Build Engineer.
-                        </para></listitem>
-                    <listitem><para>
-                        <emphasis>Test Engineer:</emphasis>
-                        This type of developer creates and manages automated
-                        tests needed to ensure all application and core
-                        system development meets desired quality standards.
-                        </para></listitem>
-                </itemizedlist>
+                    <itemizedlist>
+                        <listitem><para>
+                            <emphasis>Application Developer:</emphasis>
+                            This type of developer does application level work
+                            on top of an existing software stack.
+                            </para></listitem>
+                        <listitem><para>
+                            <emphasis>Core System Developer:</emphasis>
+                            This type of developer works on the contents of the
+                            operating system image itself.
+                            </para></listitem>
+                        <listitem><para>
+                            <emphasis>Build Engineer:</emphasis>
+                            This type of developer manages Autobuilders and
+                            releases.
+                            Not all environments need a Build Engineer.
+                            </para></listitem>
+                        <listitem><para>
+                            <emphasis>Test Engineer:</emphasis>
+                            This type of developer creates and manages automated
+                            tests that are used to ensure all application and
+                            core system development meets desired quality
+                            standards.
+                            </para></listitem>
+                    </itemizedlist>
                 </para></listitem>
             <listitem><para>
                 <emphasis>Gather the Hardware:</emphasis>
                 Based on the size and make-up of the team, get the hardware
                 together.
-                Any development, build, or test engineer should be using
-                a system that is running a supported Linux distribution.
-                Systems, in general, should be high performance (e.g. dual,
-                six-core Xeons with 24 Gbytes of RAM and plenty of disk space).
+                Ideally, any development, build, or test engineer uses
+                a system that runs a supported Linux distribution.
+                These systems, in general, should be high performance
+                (e.g. dual, six-core Xeons with 24 Gbytes of RAM and plenty
+                of disk space).
                 You can help ensure efficiency by having any machines used
                 for testing or that run Autobuilders be as high performance
                 as possible.
@@ -107,11 +111,12 @@
                 <emphasis>Use Git as Your Source Control Manager (SCM):</emphasis>
                 Keeping your
                 <ulink url='&YOCTO_DOCS_REF_URL;#metadata'>Metadata</ulink>
-                and any software you are developing under the
-                control of an SCM system that is compatible
-                with the OpenEmbedded build system is advisable.
-                Of the SCMs BitBake supports, the
-                Yocto Project team strongly recommends using
+                (i.e. recipes, configuration files, classes, and so forth)
+                and any software you are developing under the control of an SCM
+                system that is compatible   with the OpenEmbedded build system
+                is advisable.
+                Of the SCMs BitBake supports, the Yocto Project team strongly
+                recommends using
                 <ulink url='&YOCTO_DOCS_OM_URL;#git'>Git</ulink>.
                 Git is a distributed system that is easy to backup,
                 allows you to work remotely, and then connects back to the
@@ -129,20 +134,19 @@
                 being used to generate the web interface that lets you view the
                 repositories.
                 The <filename>gitolite</filename> software identifies users
-                using SSH keys and allows branch-based
-                access controls to repositories that you can control as little
-                or as much as necessary.
-
+                using SSH keys and allows branch-based access controls to
+                repositories that you can control as little or as much as
+                necessary.
                 <note>
                    The setup of these services is beyond the scope of this
                    manual.
-                   However, sites such as these exist that describe how to
-                   perform setup:
+                   However, sites such as the following exist that describe
+                   how to perform setup:
                    <itemizedlist>
                        <listitem><para>
                            <ulink url='http://git-scm.com/book/ch4-8.html'>Git documentation</ulink>:
-                           Describes how to install <filename>gitolite</filename>
-                           on the server.
+                           Describes how to install
+                           <filename>gitolite</filename> on the server.
                            </para></listitem>
                        <listitem><para>
                            <ulink url='http://gitolite.com'>Gitolite</ulink>:
@@ -150,8 +154,8 @@
                             </para></listitem>
                         <listitem><para>
                             <ulink url='https://git.wiki.kernel.org/index.php/Interfaces,_frontends,_and_tools'>Interfaces, frontends, and tools</ulink>:
-                            Documentation on how to create interfaces and frontends
-                            for Git.
+                            Documentation on how to create interfaces and
+                            frontends for Git.
                             </para></listitem>
                     </itemizedlist>
                 </note>
@@ -161,23 +165,22 @@
                 As mentioned earlier, application developers are creating
                 applications on top of existing software stacks.
                 Following are some best practices for setting up machines
-                that do application development:
+                used for application development:
                 <itemizedlist>
                     <listitem><para>
-                        Use a pre-built toolchain that
-                        contains the software stack itself.
+                        Use a pre-built toolchain that contains the software
+                        stack itself.
                         Then, develop the application code on top of the
                         stack.
                         This method works well for small numbers of relatively
                         isolated applications.
                         </para></listitem>
                     <listitem><para>
-                        When possible, use the Yocto Project
-                        plug-in for the
+                        When possible, use the Yocto Project plug-in for the
                         <trademark class='trade'>Eclipse</trademark> IDE
                         and SDK development practices.
                         For more information, see the
-                        "<ulink url='&YOCTO_DOCS_SDK_URL;'>Yocto Project Application Development and the Extensible Software Development Kit (eSDK)</ulink>"
+                        <ulink url='&YOCTO_DOCS_SDK_URL;'>Yocto Project Application Development and the Extensible Software Development Kit (eSDK)</ulink>
                         manual.
                         </para></listitem>
                     <listitem><para>
@@ -186,27 +189,29 @@
                         toolchain downloads or as updates through a package
                         update mechanism using <filename>opkg</filename>
                         to provide updates to an existing toolchain.
-                        The exact mechanics of how and when to do this are a
-                        question for local policy.
+                        The exact mechanics of how and when to do this depend
+                        on local policy.
                         </para></listitem>
                     <listitem><para>
-                        Use multiple toolchains installed locally
-                        into different locations to allow development across
+                        Use multiple toolchains installed locally into
+                        different locations to allow development across
                         versions.
                         </para></listitem>
                 </itemizedlist>
                 </para></listitem>
             <listitem><para>
                 <emphasis>Set up the Core Development Machines:</emphasis>
-                As mentioned earlier, these types of developers work on the
-                contents of the operating system itself.
+                As mentioned earlier, core developers work on the contents of
+                the operating system itself.
                 Following are some best practices for setting up machines
                 used for developing images:
                 <itemizedlist>
                     <listitem><para>
-                        Have the Yocto Project build system itself available on
-                        the developer workstations so developers can run their own
-                        builds and directly rebuild the software stack.
+                        Have the
+                        <ulink url='&YOCTO_DOCS_REF_URL;#build-system-term'>OpenEmbedded build system</ulink>
+                        available on the developer workstations so developers
+                        can run their own builds and directly rebuild the
+                        software stack.
                         </para></listitem>
                     <listitem><para>
                         Keep the core system unchanged as much as
@@ -228,8 +233,9 @@
                 Autobuilders are often the core of the development
                 environment.
                 It is here that changes from individual developers are brought
-                together and centrally tested and subsequent decisions about
-                releases can be made.
+                together and centrally tested.
+                Based on this automated build and test environment, subsequent
+                decisions about releases can be made.
                 Autobuilders also allow for "continuous integration" style
                 testing of software components and regression identification
                 and tracking.</para>
@@ -239,22 +245,23 @@
                 The Yocto Project team has found this implementation
                 works well in this role.
                 A public example of this is the Yocto Project
-                Autobuilders, which we use to test the overall health of the
-                project.</para>
+                Autobuilders, which the Yocto Project team uses to test the
+                overall health of the project.</para>
 
                 <para>The features of this system are:
                 <itemizedlist>
                     <listitem><para>
-                         Highlights when commits break the build.
-                         </para></listitem>
-                    <listitem><para>
-                        Populates an sstate cache from which
-                        developers can pull rather than requiring local
-                        builds.
+                        Highlights when commits break the build.
                         </para></listitem>
                     <listitem><para>
-                        Allows commit hook triggers,
-                        which trigger builds when commits are made.
+                        Populates an
+                        <ulink url='&YOCTO_DOCS_OM_URL;#shared-state-cache'>sstate cache</ulink>
+                        from which developers can pull rather than requiring
+                        local builds.
+                        </para></listitem>
+                    <listitem><para>
+                        Allows commit hook triggers, which trigger builds when
+                        commits are made.
                         </para></listitem>
                     <listitem><para>
                         Allows triggering of automated image booting
@@ -275,19 +282,19 @@
                         Allows scheduling of builds so that resources
                         can be used efficiently.
                         </para></listitem>
-               </itemizedlist>
-               </para></listitem>
-           <listitem><para>
-               <emphasis>Set up Test Machines:</emphasis>
-               Use a small number of shared, high performance systems
-               for testing purposes.
-               Developers can use these systems for wider, more
-               extensive testing while they continue to develop
-               locally using their primary development system.
-               </para></listitem>
-           <listitem><para>
-               <emphasis>Document Policies and Change Flow:</emphasis>
-               The Yocto Project itself uses a hierarchical structure and a
+                </itemizedlist>
+                </para></listitem>
+            <listitem><para>
+                <emphasis>Set up Test Machines:</emphasis>
+                Use a small number of shared, high performance systems
+                for testing purposes.
+                Developers can use these systems for wider, more
+                extensive testing while they continue to develop
+                locally using their primary development system.
+                </para></listitem>
+            <listitem><para>
+                <emphasis>Document Policies and Change Flow:</emphasis>
+                The Yocto Project uses a hierarchical structure and a
                 pull model.
                 Scripts exist to create and send pull requests
                 (i.e. <filename>create-pull-request</filename> and
@@ -330,16 +337,20 @@
                     <listitem><para>
                         Maintain your Metadata in layers that make sense
                         for your situation.
-                        See the "<link linkend='understanding-and-creating-layers'>Understanding
-                        and Creating Layers</link>" section for more information on
-                        layers.
+                        See the
+                        "<ulink url='&YOCTO_DOCS_OM_URL;#the-yocto-project-layer-model'>The Yocto Project Layer Model</ulink>"
+                        section in the Yocto Project Overview and Concepts
+                        Manual and the
+                        "<link linkend='understanding-and-creating-layers'>Understanding and Creating Layers</link>"
+                        section for more information on layers.
                         </para></listitem>
                     <listitem><para>
                         Separate the project's Metadata and code by using
                         separate Git repositories.
                         See the
                         "<ulink url='&YOCTO_DOCS_OM_URL;#yocto-project-repositories'>Yocto Project Source Repositories</ulink>"
-                        section for information on these repositories.
+                        section in the Yocto Project Overview and Concepts
+                        Manual for information on these repositories.
                         See the
                         "<link linkend='locating-yocto-project-source-files'>Locating Yocto Project Source Files</link>"
                         section for information on how to set up local Git
@@ -360,7 +371,8 @@
                         </para></listitem>
                     <listitem><para>
                         The Yocto Project community encourages you
-                        to send patches to the project to fix bugs or add features.
+                        to send patches to the project to fix bugs or add
+                        features.
                         If you do submit patches, follow the project commit
                         guidelines for writing good commit messages.
                         See the "<link linkend='how-to-submit-a-change'>Submitting a Change to the Yocto Project</link>"
@@ -369,10 +381,12 @@
                     <listitem><para>
                         Send changes to the core sooner than later
                         as others are likely to run into the same issues.
-                        For some guidance on mailing lists to use, see the list in the
+                        For some guidance on mailing lists to use, see the list
+                        in the
                         "<link linkend='how-to-submit-a-change'>Submitting a Change to the Yocto Project</link>"
                         section.
-                        For a description of the available mailing lists, see the
+                        For a description of the available mailing lists, see
+                        the
                         "<ulink url='&YOCTO_DOCS_REF_URL;#resources-mailinglist'>Mailing Lists</ulink>"
                         section in the Yocto Project Reference Manual.
                         </para></listitem>
@@ -382,22 +396,28 @@
     </para>
 </section>
 
-<section id='setting-up-the-development-host-to-use-the-yocto-project'>
+<section id='dev-preparing-the-build-host'>
     <title>Preparing the Build Host</title>
 
     <para>
-        This section provides procedures to set up your development host to
-        use the Yocto Project.
-        You can use the Yocto Project on a native Linux development host or
-        you can use
+        This section provides procedures to set up a system to be used as your
+        <ulink url='&YOCTO_DOCS_REF_URL;#hardware-build-system-term'>build host</ulink>
+        for development using the Yocto Project.
+        Your build host can be a native Linux machine (recommended) or it can
+        be a machine (Linux, Mac, or Windows) that uses
         <ulink url='https://git.yoctoproject.org/cgit/cgit.cgi/crops/about/'>CROPS</ulink>,
         which leverages
-        <ulink url='https://www.docker.com/'>Docker Containers</ulink>,
-        to prepare any Linux, Mac, or Windows development host.
+        <ulink url='https://www.docker.com/'>Docker Containers</ulink>.
+        <note>
+            You cannot use a build host that is using the
+            <ulink url='https://en.wikipedia.org/wiki/Windows_Subsystem_for_Linux'>Windows Subsystem for Linux</ulink>
+            (WSL).
+            The Yocto Project is not compatible with WSL.
+        </note>
     </para>
 
     <para>
-        Once your development host is set up to use the Yocto Project,
+        Once your build host is set up to use the Yocto Project,
         further steps are necessary depending on what you want to
         accomplish.
         See the following references for information on how to prepare for
@@ -432,7 +452,7 @@
 
         <para>
             Follow these steps to prepare a native Linux machine as your
-            Yocto Project development host:
+            Yocto Project Build Host:
             <orderedlist>
                 <listitem><para>
                     <emphasis>Use a Supported Linux Distribution:</emphasis>
@@ -450,8 +470,8 @@
                     </para></listitem>
                 <listitem><para>
                     <emphasis>Have Enough Free Memory:</emphasis>
-                    You should have at least 50 Gbytes of free disk space
-                    for building images.
+                    Your system should have at least 50 Gbytes of free disk
+                    space for building images.
                     </para></listitem>
                 <listitem><para>
                     <emphasis>Meet Minimal Version Requirements:</emphasis>
@@ -480,14 +500,14 @@
                 <listitem><para>
                     <emphasis>Install Development Host Packages:</emphasis>
                     Required development host packages vary depending on your
-                    build machine and what you want to do with the Yocto
+                    build host and what you want to do with the Yocto
                     Project.
                     Collectively, the number of required packages is large
                     if you want to be able to cover all cases.</para>
 
                     <para>For lists of required packages for all scenarios,
                     see the
-                    "<ulink url='&YOCTO_DOCS_REF_URL;#required-packages-for-the-host-development-system'>Required Packages for the Host Development System</ulink>"
+                    "<ulink url='&YOCTO_DOCS_REF_URL;#required-packages-for-the-build-host'>Required Packages for the Build Host</ulink>"
                     section in the Yocto Project Reference Manual.
                     </para></listitem>
             </orderedlist>
@@ -514,7 +534,7 @@
 
         <para>
             With
-            <ulink url='https://git.yoctoproject.org/cgit/cgit.cgi/crops/about/'>CROPS</ulink>,
+            <ulink url='https://github.com/crops/crops/blob/master/README.md'>CROPS</ulink>,
             which leverages
             <ulink url='https://www.docker.com/'>Docker Containers</ulink>,
             you can create a Yocto Project development environment that
@@ -525,66 +545,101 @@
 
         <para>
             Follow these general steps to prepare a Windows, Mac, or Linux
-            machine as your Yocto Project development host:
+            machine as your Yocto Project build host:
             <orderedlist>
                 <listitem><para>
-                    <emphasis>Go to the Docker Installation Site:</emphasis>
+                    <emphasis>Determine What Your Build Host Needs:</emphasis>
                     <ulink url='https://www.docker.com/what-docker'>Docker</ulink>
                     is a software container platform that you need to install
-                    on the host development machine.
-                    To start the installation process, see the
-                    <ulink url='https://docs.docker.com/engine/installation/'>Docker Installation</ulink>
-                    site.
+                    on the build host.
+                    Depending on your build host, you might have to install
+                    different software to support Docker containers.
+                    Go to the Docker installation page and read about the
+                    platform requirements in
+                    "<ulink url='https://docs.docker.com/install/#supported-platforms'>Supported Platforms</ulink>"
+                    your build host needs to run containers.
                     </para></listitem>
                 <listitem><para>
-                    <emphasis>Choose Your Docker Edition:</emphasis>
-                    Docker comes in several editions.
-                    For the Yocto Project, the stable community edition
-                    (i.e. "Docker CE Stable") is adequate.
-                    You can learn more about the Docker editions from the
-                    site.
+                    <emphasis>Choose What To Install:</emphasis>
+                    Depending on whether or not your build host meets system
+                    requirements, you need to install "Docker CE Stable" or
+                    the "Docker Toolbox".
+                    Most situations call for Docker CE.
+                    However, if you have a build host that does not meet
+                    requirements (e.g. Pre-Windows 10 or Windows 10 "Home"
+                    version), you must install Docker Toolbox instead.
                     </para></listitem>
                 <listitem><para>
                     <emphasis>Go to the Install Site for Your Platform:</emphasis>
                     Click the link for the Docker edition associated with
-                    your development host machine's native software.
-                    For example, if your machine is running Microsoft
+                    your build host's native software.
+                    For example, if your build host is running Microsoft
                     Windows Version 10 and you want the Docker CE Stable
                     edition, click that link under "Supported Platforms".
                     </para></listitem>
                 <listitem><para>
-                    <emphasis>Understand What You Need:</emphasis>
-                    The install page has pre-requisites your machine must
-                    meet.
-                    Be sure you read through this page and make sure your
-                    machine meets the requirements to run Docker.
-                    If your machine does not meet the requirements, the page
-                    has instructions to handle exceptions.
-                    For example, to run Docker on Windows 10, you must have
-                    the pro version of the operating system.
-                    If you have the home version, you need to install the
-                    <ulink url='https://docs.docker.com/toolbox/overview/#ready-to-get-started'>Docker Toolbox</ulink>.
-                    </para>
-
-                    <para>Another example is that a Windows machine needs to
-                    have Microsoft Hyper-V.
-                    If you have a legacy version of the the Microsoft
-                    operating system or for any other reason you do not have
-                    Microsoft Hyper-V, you would have to enter the BIOS and
-                    enable virtualization.
-                    </para></listitem>
-                <listitem><para>
                     <emphasis>Install the Software:</emphasis>
                     Once you have understood all the pre-requisites, you can
                     download and install the appropriate software.
                     Follow the instructions for your specific machine and
-                    the type of the software you need to install.
+                    the type of the software you need to install:
+                    <itemizedlist>
+                        <listitem><para>
+                            Install
+                            <ulink url='https://docs.docker.com/docker-for-windows/install/#install-docker-for-windows-desktop-app'>Docker CE for Windows</ulink>
+                            for Windows build hosts that meet requirements.
+                            </para></listitem>
+                        <listitem><para>
+                            Install
+                            <ulink url='https://docs.docker.com/docker-for-mac/install/#install-and-run-docker-for-mac'>Docker CE for Macs</ulink>
+                            for Mac build hosts that meet requirements.
+                            </para></listitem>
+                        <listitem><para>
+                            Install
+                            <ulink url='https://docs.docker.com/toolbox/toolbox_install_windows/'>Docker Toolbox for Windows</ulink>
+                            for Windows build hosts that do not meet Docker
+                            requirements.
+                            </para></listitem>
+                        <listitem><para>
+                            Install
+                            <ulink url='https://docs.docker.com/toolbox/toolbox_install_mac/'>Docker Toolbox for MacOS</ulink>
+                            for Mac build hosts that do not meet Docker
+                            requirements.
+                            </para></listitem>
+                        <listitem><para>
+                            Install
+                            <ulink url='https://docs.docker.com/install/linux/docker-ce/centos/'>Docker CE for CentOS</ulink>
+                            for Linux build hosts running the CentOS
+                            distribution.
+                            </para></listitem>
+                        <listitem><para>
+                            Install
+                            <ulink url='https://docs.docker.com/install/linux/docker-ce/debian/'>Docker CE for Debian</ulink>
+                            for Linux build hosts running the Debian
+                            distribution.
+                            </para></listitem>
+                        <listitem><para>
+                            Install
+                            <ulink url='https://docs.docker.com/install/linux/docker-ce/fedora/'>Docker CE for Fedora</ulink>
+                            for Linux build hosts running the Fedora
+                            distribution.
+                            </para></listitem>
+                        <listitem><para>
+                            Install
+                            <ulink url='https://docs.docker.com/install/linux/docker-ce/ubuntu/'>Docker CE for Ubuntu</ulink>
+                            for Linux build hosts running the Ubuntu
+                            distribution.
+                            </para></listitem>
+                    </itemizedlist>
                     </para></listitem>
                 <listitem><para>
                     <emphasis>Optionally Orient Yourself With Docker:</emphasis>
                     If you are unfamiliar with Docker and the container
                     concept, you can learn more here -
                     <ulink url='https://docs.docker.com/get-started/'></ulink>.
+                    </para></listitem>
+                <listitem><para>
+                    <emphasis>Launch Docker or Docker Toolbox:</emphasis>
                     You should be able to launch Docker or the Docker Toolbox
                     and have a terminal shell on your development host.
                     </para></listitem>
@@ -593,7 +648,7 @@
                     Go to
                     <ulink url='https://github.com/crops/docker-win-mac-docs/wiki'></ulink>
                     and follow the directions for your particular
-                    development host (i.e. Linux, Mac, or Windows).</para>
+                    build host (i.e. Linux, Mac, or Windows).</para>
 
                     <para>Once you complete the setup instructions for your
                     machine, you have the Poky, Extensible SDK, and Toaster
@@ -622,8 +677,8 @@
     <title>Locating Yocto Project Source Files</title>
 
     <para>
-        This section contains procedures related to locating Yocto Project
-        files.
+        This section shows you how to locate and access the
+        source files that ship with the Yocto Project.
         You establish and use these local files to work on projects.
         <note><title>Notes</title>
             <itemizedlist>
@@ -670,7 +725,7 @@
                     </para></listitem>
                 <listitem><para>
                     <emphasis>Select the Repository:</emphasis>
-                    Click on the repository in which you are interested (i.e.
+                    Click on the repository in which you are interested (e.g.
                     <filename>poky</filename>).
                     </para></listitem>
                 <listitem><para>
@@ -704,6 +759,7 @@
                 The procedure in this section exists should you desire a
                 tarball snapshot of any given component.
             </note>
+            Follow these steps to locate and download a particular tarball:
             <orderedlist>
                 <listitem><para>
                     <emphasis>Access the Index of Releases:</emphasis>
@@ -753,7 +809,10 @@
             uses a "DOWNLOADS" page from which you can locate and download
             tarballs of any Yocto Project release.
             Rather than Git repositories, these files represent snapshot
-            tarballs.
+            tarballs similar to the tarballs located in the Index of Releases
+            described in the
+            "<link linkend='accessing-index-of-releases'>Accessing Index of Releases</link>"
+            section.
             <note><title>Tip</title>
                 The recommended method for accessing Yocto Project
                 components is to use Git to clone a repository and work from
@@ -771,18 +830,23 @@
                 <listitem><para>
                     <emphasis>Get to the Downloads Area:</emphasis>
                     Select the "DOWNLOADS" item from the pull-down
-                    "SOFTWARE" tab menu.
+                    "SOFTWARE" tab menu near the top of the page.
                     </para></listitem>
                 <listitem><para>
                     <emphasis>Select a Yocto Project Release:</emphasis>
                     Use the menu next to "RELEASE" to display and choose
-                    a Yocto Project release (e.g. sumo, rocko, pyro, and
-                    so forth.
-                    For a "map" of Yocto Project releases to version numbers,
-                    see the
-                    <ulink url='https://wiki.yoctoproject.org/wiki/Releases'>Releases</ulink>
-                    wiki page.
-                    </para></listitem>
+                    a recent or past supported Yocto Project release
+                    (e.g. &DISTRO_NAME_NO_CAP;,
+                    &DISTRO_NAME_NO_CAP_MINUS_ONE;, and so forth).
+                    <note><title>Tip</title>
+                        For a "map" of Yocto Project releases to version
+                        numbers, see the
+                        <ulink url='https://wiki.yoctoproject.org/wiki/Releases'>Releases</ulink>
+                        wiki page.
+                    </note>
+                    You can use the "RELEASE ARCHIVE" link to reveal a menu of
+                    all Yocto Project releases.
+                </para></listitem>
                 <listitem><para>
                     <emphasis>Download Tools or Board Support Packages (BSPs):</emphasis>
                     From the "DOWNLOADS" page, you can download tools or
@@ -799,8 +863,9 @@
         <para>
             Yocto Project maintains an area for nightly builds that contains
             tarball releases at <ulink url='&YOCTO_AB_NIGHTLY_URL;'/>.
-            These builds include Yocto Project releases, SDK installation
-            scripts, and experimental builds.
+            These builds include Yocto Project releases ("poky"),
+            toolchains, Yocto Project plugins for Eclipse, and builds for
+            supported machines.
         </para>
 
         <para>
@@ -808,14 +873,21 @@
             Yocto Project component, use the following procedure:
             <orderedlist>
                 <listitem><para>
-                    <emphasis>Access the Nightly Builds:</emphasis>
+                    <emphasis>Locate the Index of Nightly Builds:</emphasis>
                     Open a browser and go to
                     <ulink url='&YOCTO_AB_NIGHTLY_URL;'/> to access the
                     Nightly Builds.
                     </para></listitem>
                 <listitem><para>
+                    <emphasis>Select a Date:</emphasis>
+                    Click on the date in which you are interested.
+                    If you want the latest builds, use "CURRENT".
+                    </para></listitem>
+                <listitem><para>
                     <emphasis>Select a Build:</emphasis>
-                    Click on any build by date in which you are interested.
+                    Choose the area in which you are interested.
+                    For example, if you are looking for the most recent
+                    toolchains, select the "toolchain" link.
                     </para></listitem>
                 <listitem><para>
                     <emphasis>Find the Tarball:</emphasis>
@@ -831,27 +903,23 @@
     </section>
 </section>
 
-<section id='cloning-and-checking-out-branchs'>
+<section id='cloning-and-checking-out-branches'>
     <title>Cloning and Checking Out Branches</title>
 
     <para>
-        To use the Yocto Project, you need a release of the Yocto Project
-        locally installed on your development system.
-        The locally installed set of files is referred to as the
+        To use the Yocto Project for development, you need a release locally
+        installed on your development system.
+        This locally installed set of files is referred to as the
         <ulink url='&YOCTO_DOCS_REF_URL;#source-directory'>Source Directory</ulink>
         in the Yocto Project documentation.
     </para>
 
     <para>
-        You create your Source Directory by using
+        The preferred method of creating your Source Directory is by using
         <ulink url='&YOCTO_DOCS_OM_URL;#git'>Git</ulink> to clone a local
         copy of the upstream <filename>poky</filename> repository.
-        <note><title>Tip</title>
-            The preferred method of getting the Yocto Project Source
-            Directory set up is to clone the repository.
-        </note>
-        Working from a copy of the upstream repository allows you
-        to contribute back into the Yocto Project or simply work with
+        Working from a cloned copy of the upstream repository allows you
+        to contribute back into the Yocto Project or to simply work with
         the latest software on a development branch.
         Because Git maintains and creates an upstream repository with
         a complete history of changes and you are working with a local
@@ -871,21 +939,23 @@
             <orderedlist>
                 <listitem><para>
                     <emphasis>Set Your Directory:</emphasis>
-                    Be in the directory where you want to create your local
-                    copy of poky.
+                    Change your working directory to where you want to
+                    create your local copy of
+                    <filename>poky</filename>.
                     </para></listitem>
                 <listitem><para>
                     <emphasis>Clone the Repository:</emphasis>
-                    The following command clones the repository and uses
+                    The following example command clones the
+                    <filename>poky</filename> repository and uses
                     the default name "poky" for your local repository:
                     <literallayout class='monospaced'>
      $ git clone git://git.yoctoproject.org/poky
      Cloning into 'poky'...
-     remote: Counting objects: 367178, done.
-     remote: Compressing objects: 100% (88161/88161), done.
-     remote: Total 367178 (delta 272761), reused 366942 (delta 272525)
-     Receiving objects: 100% (367178/367178), 133.26 MiB | 6.40 MiB/s, done.
-     Resolving deltas: 100% (272761/272761), done.
+     remote: Counting objects: 416542, done.
+     remote: Compressing objects: 100% (98611/98611), done.
+     remote: Total 416542 (delta 311104), reused 416377 (delta 310939)
+     Receiving objects: 100% (416542/416542), 150.39 MiB | 15.77 MiB/s, done.
+     Resolving deltas: 100% (311104/311104), done.
      Checking connectivity... done.
                     </literallayout>
                     Unless you specify a specific development branch or
@@ -900,8 +970,8 @@
                     <link linkend='checkout-out-by-tag-in-poky'>Checking Out By Tag in Poky</link>"
                     sections, respectively.</para>
 
-                    <para>Once the repository is created, you can change to
-                    that directory and check its status.
+                    <para>Once the local repository is created, you can
+                    change to that directory and check its status.
                     Here, the single "master" branch exists on your system
                     and by default, it is checked out:
                     <literallayout class='monospaced'>
@@ -916,6 +986,10 @@
                     Your local repository of poky is identical to the
                     upstream poky repository at the time from which it was
                     cloned.
+                    As you work with the local branch, you can periodically
+                    use the <filename>git pull &dash;&dash;rebase</filename>
+                    command to be sure you are up-to-date with the upstream
+                    branch.
                     </para></listitem>
             </orderedlist>
         </para>
diff --git a/poky/documentation/dev-manual/dev-manual.xml b/poky/documentation/dev-manual/dev-manual.xml
index d473142..b54c0d6 100644
--- a/poky/documentation/dev-manual/dev-manual.xml
+++ b/poky/documentation/dev-manual/dev-manual.xml
@@ -107,14 +107,14 @@
                 <revremark>Released with the Yocto Project 2.5 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.1</revnumber>
-                <date>September 2018</date>
-                <revremark>The initial document released with the Yocto Project 2.5.1 Release.</revremark>
+                <revnumber>2.6</revnumber>
+                <date>November 2018</date>
+                <revremark>Released with the Yocto Project 2.6 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.2</revnumber>
+                <revnumber>2.6.1</revnumber>
                 <date>&REL_MONTH_YEAR;</date>
-                <revremark>The initial document released with the Yocto Project 2.5.2 Release.</revremark>
+                <revremark>Released with the Yocto Project 2.6.1 Release.</revremark>
             </revision>
         </revhistory>
 
diff --git a/poky/documentation/dev-manual/figures/multiconfig_files.png b/poky/documentation/dev-manual/figures/multiconfig_files.png
new file mode 100644
index 0000000..0b59338
--- /dev/null
+++ b/poky/documentation/dev-manual/figures/multiconfig_files.png
Binary files differ
diff --git a/poky/documentation/kernel-dev/kernel-dev-common.xml b/poky/documentation/kernel-dev/kernel-dev-common.xml
index 4c6fc35..9052876 100644
--- a/poky/documentation/kernel-dev/kernel-dev-common.xml
+++ b/poky/documentation/kernel-dev/kernel-dev-common.xml
@@ -25,7 +25,7 @@
             Before you can do any kernel development, you need to be
             sure your build host is set up to use the Yocto Project.
             For information on how to get set up, see the
-            "<ulink url='&YOCTO_DOCS_DEV_URL;#setting-up-the-development-host-to-use-the-yocto-project'>Preparing the Build Host</ulink>"
+            "<ulink url='&YOCTO_DOCS_DEV_URL;#dev-preparing-the-build-host'>Preparing the Build Host</ulink>"
             section in the Yocto Project Development Tasks Manual.
             Part of preparing the system is creating a local Git
             repository of the
diff --git a/poky/documentation/kernel-dev/kernel-dev.xml b/poky/documentation/kernel-dev/kernel-dev.xml
index e5e6fd1..fc46c20 100644
--- a/poky/documentation/kernel-dev/kernel-dev.xml
+++ b/poky/documentation/kernel-dev/kernel-dev.xml
@@ -92,14 +92,14 @@
                 <revremark>Released with the Yocto Project 2.5 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.1</revnumber>
-                <date>September 2018</date>
-                <revremark>The initial document released with the Yocto Project 2.5.1 Release.</revremark>
+                <revnumber>2.6</revnumber>
+                <date>November 2018</date>
+                <revremark>Released with the Yocto Project 2.6 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.2</revnumber>
+                <revnumber>2.6.1</revnumber>
                 <date>&REL_MONTH_YEAR;</date>
-                <revremark>The initial document released with the Yocto Project 2.5.2 Release.</revremark>
+                <revremark>Released with the Yocto Project 2.6.1 Release.</revremark>
             </revision>
         </revhistory>
 
diff --git a/poky/documentation/mega-manual/figures/multiconfig_files.png b/poky/documentation/mega-manual/figures/multiconfig_files.png
new file mode 100644
index 0000000..0b59338
--- /dev/null
+++ b/poky/documentation/mega-manual/figures/multiconfig_files.png
Binary files differ
diff --git a/poky/documentation/mega-manual/mega-manual.xml b/poky/documentation/mega-manual/mega-manual.xml
index 4a68999..7a41991 100644
--- a/poky/documentation/mega-manual/mega-manual.xml
+++ b/poky/documentation/mega-manual/mega-manual.xml
@@ -76,14 +76,14 @@
                 <revremark>Released with the Yocto Project 2.5 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.1</revnumber>
-                <date>September 2018</date>
-                <revremark>The initial document released with the Yocto Project 2.5.1 Release.</revremark>
+                <revnumber>2.6</revnumber>
+                <date>November 2018</date>
+                <revremark>Released with the Yocto Project 2.6 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.2</revnumber>
+                <revnumber>2.6.1</revnumber>
                 <date>&REL_MONTH_YEAR;</date>
-                <revremark>The initial document released with the Yocto Project 2.5.2 Release.</revremark>
+                <revremark>Released with the Yocto Project 2.6.1 Release.</revremark>
             </revision>
        </revhistory>
 
diff --git a/poky/documentation/overview-manual/overview-manual-yp-intro.xml b/poky/documentation/overview-manual/overview-manual-yp-intro.xml
index ccf5e27..d34b640 100644
--- a/poky/documentation/overview-manual/overview-manual-yp-intro.xml
+++ b/poky/documentation/overview-manual/overview-manual-yp-intro.xml
@@ -1296,7 +1296,7 @@
                     <para>It is worth noting that the term "package" can,
                     in general, have subtle meanings.
                     For example, the packages referred to in the
-                    "<ulink url='&YOCTO_DOCS_REF_URL;#required-packages-for-the-host-development-system'>Required Packages for the Host Development System</ulink>"
+                    "<ulink url='&YOCTO_DOCS_REF_URL;#required-packages-for-the-build-host'>Required Packages for the Build Host</ulink>"
                     section in the Yocto Project Reference Manual are compiled
                     binaries that, when installed, add functionality to your
                     Linux distribution.</para>
diff --git a/poky/documentation/overview-manual/overview-manual.xml b/poky/documentation/overview-manual/overview-manual.xml
index d7f04ab..320ca35 100644
--- a/poky/documentation/overview-manual/overview-manual.xml
+++ b/poky/documentation/overview-manual/overview-manual.xml
@@ -37,14 +37,14 @@
                 <revremark>The initial document released with the Yocto Project 2.5 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.1</revnumber>
-                <date>September 2018</date>
-                <revremark>The initial document released with the Yocto Project 2.5.1 Release.</revremark>
+                <revnumber>2.6</revnumber>
+                <date>November 2018</date>
+                <revremark>Released with the Yocto Project 2.6 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.2</revnumber>
+                <revnumber>2.6.1</revnumber>
                 <date>&REL_MONTH_YEAR;</date>
-                <revremark>The initial document released with the Yocto Project 2.5.2 Release.</revremark>
+                <revremark>Released with the Yocto Project 2.6.1 Release.</revremark>
             </revision>
         </revhistory>
 
diff --git a/poky/documentation/poky.ent b/poky/documentation/poky.ent
index 1b71b80..c76fe7b 100644
--- a/poky/documentation/poky.ent
+++ b/poky/documentation/poky.ent
@@ -1,17 +1,17 @@
-<!ENTITY DISTRO "2.5.2">
-<!ENTITY DISTRO_COMPRESSED "252">
-<!ENTITY DISTRO_NAME_NO_CAP "sumo">
-<!ENTITY DISTRO_NAME "Sumo">
-<!ENTITY DISTRO_NAME_NO_CAP_MINUS_ONE "rocko">
-<!ENTITY DISTRO_NAME_MINUS_ONE "Rocko">
-<!ENTITY YOCTO_DOC_VERSION "2.5.2">
-<!ENTITY YOCTO_DOC_VERSION_MINUS_ONE "2.4.4">
-<!ENTITY DISTRO_REL_TAG "yocto-2.5.2">
-<!ENTITY METAINTELVERSION "9.2">
+<!ENTITY DISTRO "2.6.1">
+<!ENTITY DISTRO_COMPRESSED "261">
+<!ENTITY DISTRO_NAME_NO_CAP "thud">
+<!ENTITY DISTRO_NAME "Thud">
+<!ENTITY DISTRO_NAME_NO_CAP_MINUS_ONE "sumo">
+<!ENTITY DISTRO_NAME_MINUS_ONE "Sumo">
+<!ENTITY YOCTO_DOC_VERSION "2.6.1">
+<!ENTITY YOCTO_DOC_VERSION_MINUS_ONE "2.5.2">
+<!ENTITY DISTRO_REL_TAG "yocto-2.6.1">
+<!ENTITY METAINTELVERSION "9.0">
 <!ENTITY REL_MONTH_YEAR "December 2018">
 <!ENTITY META_INTEL_REL_TAG "&METAINTELVERSION;-&DISTRO_NAME_NO_CAP;-&YOCTO_DOC_VERSION;">
-<!ENTITY POKYVERSION "20.0.2">
-<!ENTITY POKYVERSION_COMPRESSED "2002">
+<!ENTITY POKYVERSION "21.0.1">
+<!ENTITY POKYVERSION_COMPRESSED "2101">
 <!ENTITY YOCTO_POKY "poky-&DISTRO_NAME_NO_CAP;-&POKYVERSION;">
 <!ENTITY COPYRIGHT_YEAR "2010-2019">
 <!ENTITY YOCTO_DL_URL "http://downloads.yoctoproject.org">
diff --git a/poky/documentation/profile-manual/profile-manual-intro.xml b/poky/documentation/profile-manual/profile-manual-intro.xml
index d38d61a..f16db3f 100644
--- a/poky/documentation/profile-manual/profile-manual-intro.xml
+++ b/poky/documentation/profile-manual/profile-manual-intro.xml
@@ -92,7 +92,9 @@
      EXTRA_IMAGE_FEATURES = "debug-tweaks tools-profile dbg-pkgs"
             </literallayout>
             Additionally, in order to generate the right type of
-            debuginfo, we also need to add the following to local.conf:
+            debuginfo, we also need to set
+            <ulink url='&YOCTO_DOCS_REF_URL;#var-PACKAGE_DEBUG_SPLIT_STYLE'><filename>PACKAGE_DEBUG_SPLIT_STYLE</filename></ulink>
+            in the <filename>local.conf</filename> file:
             <literallayout class='monospaced'>
      PACKAGE_DEBUG_SPLIT_STYLE = 'debug-file-directory'
             </literallayout>
diff --git a/poky/documentation/profile-manual/profile-manual-usage.xml b/poky/documentation/profile-manual/profile-manual-usage.xml
index c0873e1..a1b5651 100644
--- a/poky/documentation/profile-manual/profile-manual-usage.xml
+++ b/poky/documentation/profile-manual/profile-manual-usage.xml
@@ -375,7 +375,9 @@
      EXTRA_IMAGE_FEATURES = "debug-tweaks tools-profile dbg-pkgs"
                 </literallayout>
                 Additionally, in order to generate the type of debuginfo that
-                perf understands, we also need to add the following to local.conf:
+                perf understands, we also need to set
+                <ulink url='&YOCTO_DOCS_REF_URL;#var-PACKAGE_DEBUG_SPLIT_STYLE'><filename>PACKAGE_DEBUG_SPLIT_STYLE</filename></ulink>
+                in the <filename>local.conf</filename> file:
                 <literallayout class='monospaced'>
      PACKAGE_DEBUG_SPLIT_STYLE = 'debug-file-directory'
                 </literallayout>
diff --git a/poky/documentation/profile-manual/profile-manual.xml b/poky/documentation/profile-manual/profile-manual.xml
index 7629386..10ca68e 100644
--- a/poky/documentation/profile-manual/profile-manual.xml
+++ b/poky/documentation/profile-manual/profile-manual.xml
@@ -92,14 +92,14 @@
                 <revremark>Released with the Yocto Project 2.5 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.1</revnumber>
-                <date>September 2018</date>
-                <revremark>The initial document released with the Yocto Project 2.5.1 Release.</revremark>
+                <revnumber>2.6</revnumber>
+                <date>November 2018</date>
+                <revremark>Released with the Yocto Project 2.6 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.2</revnumber>
+                <revnumber>2.6.1</revnumber>
                 <date>&REL_MONTH_YEAR;</date>
-                <revremark>The initial document released with the Yocto Project 2.5.2 Release.</revremark>
+                <revremark>Released with the Yocto Project 2.6.1 Release.</revremark>
             </revision>
         </revhistory>
 
diff --git a/poky/documentation/ref-manual/migration.xml b/poky/documentation/ref-manual/migration.xml
index b060968..c648d8d 100644
--- a/poky/documentation/ref-manual/migration.xml
+++ b/poky/documentation/ref-manual/migration.xml
@@ -3619,7 +3619,7 @@
 
         <para>
             The
-            <link linkend='var-KERNEL_IMAGE_BASE_NAME'><filename>KERNEL_IMAGE_BASE_NAME</filename></link>
+            <filename>KERNEL_IMAGE_BASE_NAME</filename>
             variable no longer uses the
             <link linkend='var-KERNEL_IMAGETYPE'><filename>KERNEL_IMAGETYPE</filename></link>
             variable to create the image's base name.
@@ -5557,8 +5557,9 @@
                     incompatible with other implementations.
                     </para></listitem>
                 <listitem><para>
-                    By default, the <filename>cmake</filename> class uses
-                    <filename>ninja</filename> instead of
+                    By default, the
+                    <link linkend='ref-classes-cmake'><filename>cmake</filename></link>
+                    class uses <filename>ninja</filename> instead of
                     <filename>make</filename> for building.
                     This improves build performance.
                     If a recipe is broken with <filename>ninja</filename>, then
@@ -5608,7 +5609,11 @@
                     Any failure of a <filename>pkg_postinst()</filename>
                     script (including <filename>exit 1</filename>)
                     will trigger a warning during
-                    <filename>do_rootfs</filename>.
+                    <filename>do_rootfs</filename>.</para>
+
+                    <para>For more information, see the
+                    "<ulink url='&YOCTO_DOCS_DEV_URL;#new-recipe-post-installation-scripts'>Post-Installation Scripts</ulink>"
+                    section in the Yocto Project Development Tasks Manual.
                     </para></listitem>
                 <listitem><para>
                     The <filename>elf</filename> image type has been removed.
@@ -5678,6 +5683,648 @@
         </para>
     </section>
 </section>
+
+<section id='moving-to-the-yocto-project-2.6-release'>
+    <title>Moving to the Yocto Project 2.6 Release</title>
+
+    <para>
+        This section provides migration information for moving to the
+        Yocto Project 2.6 Release from the prior release.
+    </para>
+
+    <section id='migration-2.6-gcc-changes'>
+        <title>GCC 8.2 is Now Used by Default</title>
+
+        <para>
+            The GNU Compiler Collection version 8.2 is now used by default
+            for compilation.
+            For more information on what has changed in the GCC 8.x release,
+            see
+            <ulink url='https://gcc.gnu.org/gcc-8/changes.html'></ulink>.
+        </para>
+
+        <para>
+            If you still need to compile with version 7.x, GCC 7.3 is
+            also provided.
+            You can select this version by setting the
+            and can be selected by setting the
+            <link linkend='var-GCCVERSION'><filename>GCCVERSION</filename></link>
+            variable to "7.%" in your configuration.
+        </para>
+    </section>
+
+    <section id='migration-2.6-removed-recipes'>
+        <title>Removed Recipes</title>
+
+        <para>
+            The following recipes have been removed:
+            <literallayout class='monospaced'>
+     <emphasis><filename>beecrypt</filename>:</emphasis> No longer needed since moving to RPM 4.
+     <emphasis><filename>bigreqsproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>calibrateproto</filename>:</emphasis> Removed in favor of <filename>xinput</filename>.
+     <emphasis><filename>compositeproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>damageproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>dmxproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>dri2proto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>dri3proto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>eee-acpi-scripts</filename>:</emphasis> Became obsolete.
+     <emphasis><filename>fixesproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>fontsproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>fstests</filename>:</emphasis> Became obsolete.
+     <emphasis><filename>gccmakedep</filename>:</emphasis> No longer used.
+     <emphasis><filename>glproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>gnome-desktop3</filename>:</emphasis> No longer needed.  This recipe has moved to <filename>meta-oe</filename>.
+     <emphasis><filename>icon-naming-utils</filename>:</emphasis> No longer used since the Sato theme was removed in 2016.
+     <emphasis><filename>inputproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>kbproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>libusb-compat</filename>:</emphasis> Became obsolete.
+     <emphasis><filename>libuser</filename>:</emphasis> Became obsolete.
+     <emphasis><filename>libnfsidmap</filename>:</emphasis> No longer an external requirement since <filename>nfs-utils</filename> 2.2.1.  <filename>libnfsidmap</filename> is now integrated.
+     <emphasis><filename>libxcalibrate</filename>:</emphasis> No longer needed with <filename>xinput</filename>
+     <emphasis><filename>mktemp</filename>:</emphasis> Became obsolete. The <filename>mktemp</filename> command is provided by both <filename>busybox</filename> and <filename>coreutils</filename>.
+     <emphasis><filename>ossp-uuid</filename>:</emphasis> Is not being maintained and has mostly been replaced by <filename>uuid.h</filename> in <filename>util-linux</filename>.
+     <emphasis><filename>pax-utils</filename>:</emphasis> No longer needed.  Previous QA tests that did use this recipe are now done at build time.
+     <emphasis><filename>pcmciautils</filename>:</emphasis> Became obsolete.
+     <emphasis><filename>pixz</filename>:</emphasis> No longer needed. <filename>xz</filename> now supports multi-threaded compression.
+     <emphasis><filename>presentproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>randrproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>recordproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>renderproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>resourceproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>scrnsaverproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>trace-cmd</filename>:</emphasis> Became obsolete.  <filename>perf</filename> replaced this recipe's functionally.
+     <emphasis><filename>videoproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>wireless-tools</filename>:</emphasis> Became obsolete.  Superseded by <filename>iw</filename>.
+     <emphasis><filename>xcmiscproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>xextproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>xf86dgaproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>xf86driproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>xf86miscproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>xf86-video-omapfb</filename>:</emphasis> Became obsolete.  Use kernel modesetting driver instead.
+     <emphasis><filename>xf86-video-omap</filename>:</emphasis> Became obsolete.  Use kernel modesetting driver instead.
+     <emphasis><filename>xf86vidmodeproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>xineramaproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>xproto</filename>:</emphasis> Replaced by <filename>xorgproto</filename>.
+     <emphasis><filename>yasm</filename>:</emphasis> No longer needed since previous usages are now satisfied by <filename>nasm</filename>.
+            </literallayout>
+        </para>
+    </section>
+
+    <section id='migration-2.6-packaging-changes'>
+        <title>Packaging Changes</title>
+
+        <para>
+            The following packaging changes have been made:
+            <itemizedlist>
+                <listitem><para>
+                    <emphasis><filename>cmake</filename>:</emphasis>
+                    <filename>cmake.m4</filename> and
+                    <filename>toolchain</filename> files have been moved to the
+                    main package.
+                    </para></listitem>
+                <listitem><para>
+                    <emphasis><filename>iptables</filename>:</emphasis>
+                    The <filename>iptables</filename> modules have been split
+                    into separate packages.
+                    </para></listitem>
+                <listitem><para>
+                    <emphasis><filename>alsa-lib</filename>:</emphasis>
+                    <filename>libasound</filename> is now in the main
+                    <filename>alsa-lib</filename> package instead of
+                    <filename>libasound</filename>.
+                    </para></listitem>
+                <listitem><para>
+                    <emphasis><filename>glibc</filename>:</emphasis>
+                    <filename>libnss-db</filename> is now in its own package
+                    along with a <filename>/var/db/makedbs.sh</filename>
+                    script to update databases.
+                    </para></listitem>
+                <listitem><para>
+                    <emphasis><filename>python</filename> and <filename>python3</filename>:</emphasis>
+                    The main package has been removed from the recipe.
+                    You must install specific packages or
+                    <filename>python-modules</filename> /
+                    <filename>python3-modules</filename> for everything.
+                    </para></listitem>
+                <listitem><para>
+                    <emphasis><filename>systemtap</filename>:</emphasis>
+                    Moved <filename>systemtap-exporter</filename> into its own
+                    package.
+                    </para></listitem>
+            </itemizedlist>
+        </para>
+    </section>
+
+    <section id='migration-2.6-xorg-protocol-dependencies'>
+        <title>XOrg Protocol dependencies</title>
+
+        <para>
+            The "*proto" upstream repositories have been combined into one
+            "xorgproto" repository.
+            Thus, the corresponding recipes have also been combined into a
+            single <filename>xorgproto</filename> recipe.
+            Any recipes that depend upon the older <filename>*proto</filename>
+            recipes need to be changed to depend on the newer
+            <filename>xorgproto</filename> recipe instead.
+        </para>
+
+        <para>
+            For names of recipes removed because of this repository change,
+            see the
+            <link linkend="migration-2.6-removed-recipes">Removed Recipes</link>
+            section.
+        </para>
+    </section>
+
+    <section id='migration-2.6-distutils-distutils3-fetching-dependencies'>
+        <title><filename>distutils</filename> and <filename>distutils3</filename> Now Prevent Fetching Dependencies During the <filename>do_configure</filename> Task</title>
+
+        <para>
+            Previously, it was possible for Python recipes that inherited
+            the
+            <link linkend='ref-classes-distutils'><filename>distutils</filename></link>
+            and
+            <link linkend='ref-classes-distutils3'><filename>distutils3</filename></link>
+            classes to fetch code during the
+            <link linkend='ref-tasks-configure'><filename>do_configure</filename></link>
+            task to satisfy dependencies mentioned in
+            <filename>setup.py</filename> if those dependencies were not
+            provided in the sysroot (i.e. recipes providing the dependencies
+            were missing from
+            <link linkend='var-DEPENDS'><filename>DEPENDS</filename></link>).
+            <note>
+                This change affects classes beyond just the two mentioned
+                (i.e. <filename>distutils</filename> and
+                <filename>distutils3</filename>).
+                Any recipe that inherits <filename>distutils*</filename>
+                classes are affected.
+                For example, the <filename>setuptools</filename> and
+                <filename>setuptools3</filename> recipes are affected since
+                they inherit the <filename>distutils*</filename> classes.
+            </note>
+        </para>
+
+        <para>
+            Fetching these types of dependencies that are not provided in the
+            sysroot negatively affects the ability to reproduce builds.
+            This type of fetching is now explicitly disabled.
+            Consequently, any missing dependencies in Python recipes that
+            use these classes now result in an error during the
+            <filename>do_configure</filename> task.
+        </para>
+    </section>
+
+    <section id='migration-2.6-linux-yocto-configuration-audit-issues-now-correctly-reported'>
+        <title><filename>linux-yocto</filename> Configuration Audit Issues Now Correctly Reported</title>
+
+        <para>
+            Due to a bug, the kernel configuration audit functionality was
+            not writing out any resulting warnings during the build.
+            This issue is now corrected.
+            You might notice these warnings now if you have a custom kernel
+            configuration with a <filename>linux-yocto</filename> style
+            kernel recipe.
+        </para>
+    </section>
+
+    <section id='migration-2.6-image-kernel-artifact-naming-changes'>
+        <title>Image/Kernel Artifact Naming Changes</title>
+
+        <para>
+            The following changes have been made:
+            <itemizedlist>
+                <listitem><para>
+                    Name variables (e.g.
+                    <link linkend='var-IMAGE_NAME'><filename>IMAGE_NAME</filename></link>)
+                    use a new <filename>IMAGE_VERSION_SUFFIX</filename>
+                    variable instead of
+                    <link linkend='var-DATETIME'><filename>DATETIME</filename></link>.
+                    Using <filename>IMAGE_VERSION_SUFFIX</filename> allows
+                    easier and more direct changes.</para>
+
+                    <para>The <filename>IMAGE_VERSION_SUFFIX</filename>
+                    variable is set in the
+                    <filename>bitbake.conf</filename> configuration file as
+                    follows:
+                    <literallayout class='monospaced'>
+     IMAGE_VERSION_SUFFIX = "-${DATETIME}"
+                    </literallayout>
+                    </para></listitem>
+                <listitem><para>
+                    Several variables have changed names for consistency:
+                    <literallayout class='monospaced'>
+    Old Variable Name               New Variable Name
+    ========================================================
+    KERNEL_IMAGE_BASE_NAME          <link linkend='var-KERNEL_IMAGE_NAME'>KERNEL_IMAGE_NAME</link>
+    KERNEL_IMAGE_SYMLINK_NAME       <link linkend='var-KERNEL_IMAGE_LINK_NAME'>KERNEL_IMAGE_LINK_NAME</link>
+    MODULE_TARBALL_BASE_NAME        <link linkend='var-MODULE_TARBALL_NAME'>MODULE_TARBALL_NAME</link>
+    MODULE_TARBALL_SYMLINK_NAME     <link linkend='var-MODULE_TARBALL_LINK_NAME'>MODULE_TARBALL_LINK_NAME</link>
+    INITRAMFS_BASE_NAME             <link linkend='var-INITRAMFS_NAME'>INITRAMFS_NAME</link>
+                    </literallayout>
+                    </para></listitem>
+                <listitem><para>
+                    The <filename>MODULE_IMAGE_BASE_NAME</filename> variable
+                    has been removed.
+                    The module tarball name is now controlled directly with the
+                    <link linkend='var-MODULE_TARBALL_NAME'><filename>MODULE_TARBALL_NAME</filename></link>
+                    variable.
+                    </para></listitem>
+                <listitem><para>
+                    The
+                    <link linkend='var-KERNEL_DTB_NAME'><filename>KERNEL_DTB_NAME</filename></link>
+                    and
+                    <link linkend='var-KERNEL_DTB_LINK_NAME'><filename>KERNEL_DTB_LINK_NAME</filename></link>
+                    variables have been introduced to control kernel Device
+                    Tree Binary (DTB) artifact names instead of mangling
+                    <filename>KERNEL_IMAGE_*</filename> variables.
+                    </para></listitem>
+                <listitem><para>
+                    The
+                    <link linkend='var-KERNEL_FIT_NAME'><filename>KERNEL_FIT_NAME</filename></link>
+                    and
+                    <link linkend='var-KERNEL_FIT_LINK_NAME'><filename>KERNEL_FIT_LINK_NAME</filename></link>
+                    variables have been introduced to specify the name of
+                    flattened image tree (FIT) kernel images similar to other
+                    deployed artifacts.
+                    </para></listitem>
+                <listitem><para>
+                    The
+                    <link linkend='var-MODULE_TARBALL_NAME'><filename>MODULE_TARBALL_NAME</filename></link>
+                    and
+                    <link linkend='var-MODULE_TARBALL_LINK_NAME'><filename>MODULE_TARBALL_LINK_NAME</filename></link>
+                    variable values no longer include the "module-" prefix or
+                    ".tgz" suffix.
+                    These parts are now hardcoded so that the values are
+                    consistent with other artifact naming variables.
+                    </para></listitem>
+                <listitem><para>
+                    Added the
+                    <link linkend='var-INITRAMFS_LINK_NAME'><filename>INITRAMFS_LINK_NAME</filename></link>
+                    variable so that the symlink can be controlled similarly
+                    to other artifact types.
+                    </para></listitem>
+                <listitem><para>
+                    <link linkend='var-INITRAMFS_NAME'><filename>INITRAMFS_NAME</filename></link>
+                    now uses
+                    "${PKGE}-${PKGV}-${PKGR}-${MACHINE}${IMAGE_VERSION_SUFFIX}"
+                    instead of
+                    "${PV}-${PR}-${MACHINE}-${DATETIME}", which
+                    makes it consistent with other variables.
+                    </para></listitem>
+            </itemizedlist>
+        </para>
+    </section>
+
+    <section id='migration-2.6-serial-console-deprecated'>
+        <title><filename>SERIAL_CONSOLE</filename> Deprecated</title>
+
+        <para>
+            The
+            <link linkend='var-SERIAL_CONSOLE'><filename>SERIAL_CONSOLE</filename></link>
+            variable has been functionally replaced by the
+            <link linkend='var-SERIAL_CONSOLES'><filename>SERIAL_CONSOLES</filename></link>
+            variable for some time.
+            With the Yocto Project 2.6 release,
+            <filename>SERIAL_CONSOLE</filename> has been officially deprecated.
+        </para>
+
+        <para>
+            <filename>SERIAL_CONSOLE</filename> will continue to work as
+            before for the 2.6 release.
+            However, for the sake of future compatibility, it is recommended
+            that you replace all instances of
+            <filename>SERIAL_CONSOLE</filename> with
+            <filename>SERIAL_CONSOLES</filename>.
+            <note>
+                The only difference in usage is that
+                <filename>SERIAL_CONSOLES</filename> expects entries to be
+                separated using semicolons as compared to
+                <filename>SERIAL_CONSOLE</filename>, which expects spaces.
+            </note>
+        </para>
+    </section>
+
+    <section id='migration-2.6-poky-sets-unknown-configure-option-to-qa-error'>
+        <title>Configure Script Reports Unknown Options as Errors</title>
+
+        <para>
+            If the configure script reports an unknown option, this now
+            triggers a QA error instead of a warning.
+            Any recipes that previously got away with specifying such unknown
+            options now need to be fixed.
+        </para>
+    </section>
+
+    <section id='migration-2.6-override-changes'>
+        <title>Override Changes</title>
+
+        <para>
+            The following changes have occurred:
+            <itemizedlist>
+                <listitem><para>
+                    <emphasis>The <filename>virtclass-native</filename> and
+                    <filename>virtclass-nativesdk</filename> Overrides Have
+                    Been Removed:</emphasis>
+                    The <filename>virtclass-native</filename> and
+                    <filename>virtclass-nativesdk</filename> overrides have
+                    been deprecated since 2012 in favor of
+                    <filename>class-native</filename> and
+                    <filename>class-nativesdk</filename>, respectively.
+                    Both <filename>virtclass-native</filename> and
+                    <filename>virtclass-nativesdk</filename> are now dropped.
+                    <note>
+                        The <filename>virtclass-multilib-</filename> overrides
+                        for multilib are still valid.
+                    </note>
+                    </para></listitem>
+                <listitem><para>
+                    <emphasis>The <filename>forcevariable</filename>
+                    Override Now Has a Higher Priority Than
+                    <filename>libc</filename> Overrides:</emphasis>
+                    The <filename>forcevariable</filename> override is
+                    documented to be the highest priority override.
+                    However, due to a long-standing quirk of how
+                    <link linkend='var-OVERRIDES'><filename>OVERRIDES</filename></link>
+                    is set, the <filename>libc</filename> overrides (e.g.
+                    <filename>libc-glibc</filename>,
+                    <filename>libc-musl</filename>, and so forth) erroneously
+                    had a higher priority.
+                    This issue is now corrected.</para>
+
+                    <para>It is likely this change will not cause any
+                    problems.
+                    However, it is possible with some unusual configurations
+                    that you might see a change in behavior if you were
+                    relying on the previous behavior.
+                    Be sure to check how you use
+                    <filename>forcevariable</filename> and
+                    <filename>libc-*</filename> overrides in your custom
+                    layers and configuration files to ensure they make sense.
+                    </para></listitem>
+                <listitem><para>
+                    <emphasis>The <filename>build-${BUILD_OS}</filename>
+                    Override Has Been Removed:</emphasis>
+                    The <filename>build-${BUILD_OS}</filename>, which is
+                    typically <filename>build-linux</filename>, override has
+                    been removed because building on a host operating system
+                    other than a recent version of Linux is neither supported
+                    nor recommended.
+                    Dropping the override avoids giving the impression that
+                    other host operating systems might be supported.
+                    </para></listitem>
+                <listitem><para>
+                    The "_remove" operator now preserves whitespace.
+                    Consequently, when specifying list items to remove, be
+                    aware that leading and trailing whitespace resulting from
+                    the removal is retained.</para>
+
+                    <para>See the
+                    "<ulink url='&YOCTO_DOCS_BB_URL;#removing-override-style-syntax'>Removal (Override Style Syntax)</ulink>"
+                    section in the BitBake User Manual for a detailed example.
+                    </para></listitem>
+            </itemizedlist>
+        </para>
+    </section>
+
+    <section id='migration-2.6-systemd-configuration-now-split-out-to-system-conf'>
+        <title><filename>systemd</filename> Configuration is Now Split Into <filename>systemd-conf</filename></title>
+
+        <para>
+            The configuration for the <filename>systemd</filename> recipe
+            has been moved into a <filename>system-conf</filename> recipe.
+            Moving this configuration to a separate recipe avoids the
+            <filename>systemd</filename> recipe from becoming machine-specific
+            for cases where machine-specific configurations need to be applied
+            (e.g. for <filename>qemu*</filename> machines).
+        </para>
+
+        <para>
+            Currently, the new recipe packages the following files:
+            <literallayout class='monospaced'>
+     ${sysconfdir}/machine-id
+     ${sysconfdir}/systemd/coredump.conf
+     ${sysconfdir}/systemd/journald.conf
+     ${sysconfdir}/systemd/logind.conf
+     ${sysconfdir}/systemd/system.conf
+     ${sysconfdir}/systemd/user.conf
+            </literallayout>
+            If you previously used bbappend files to append the
+            <filename>systemd</filename> recipe to change any of the
+            listed files, you must do so for the
+            <filename>systemd-conf</filename> recipe instead.
+        </para>
+    </section>
+
+    <section id='migration-2.6-automatic-testing-changes'>
+        <title>Automatic Testing Changes</title>
+
+        <para>
+            This section provides information about automatic testing
+            changes:
+            <itemizedlist>
+                <listitem><para>
+                    <emphasis><filename>TEST_IMAGE</filename> Variable Removed:</emphasis>
+                    Prior to this release, you set the
+                    <filename>TEST_IMAGE</filename> variable to "1" to
+                    enable automatic testing for successfully built images.
+                    The <filename>TEST_IMAGE</filename> variable no longer
+                    exists and has been replaced by the
+                    <link linkend='var-TESTIMAGE_AUTO'><filename>TESTIMAGE_AUTO</filename></link>
+                    variable.
+                    </para></listitem>
+                <listitem><para>
+                    <emphasis>Inheriting the <filename>testimage</filename> and
+                    <filename>testsdk</filename> Classes:</emphasis>
+                    Best practices now dictate that you use the
+                    <link linkend='var-IMAGE_CLASSES'><filename>IMAGE_CLASSES</filename></link>
+                    variable rather than the
+                    <link linkend='var-INHERIT'><filename>INHERIT</filename></link>
+                    variable when you inherit the
+                    <link linkend='ref-classes-testimage*'><filename>testimage</filename></link>
+                    and
+                    <link linkend='ref-classes-testsdk'><filename>testsdk</filename></link>
+                    classes used for automatic testing.
+                    </para></listitem>
+            </itemizedlist>
+        </para>
+    </section>
+
+    <section id='migration-2.6-openssl-changes'>
+        <title>OpenSSL Changes</title>
+
+        <para>
+            <ulink url='https://www.openssl.org/'>OpenSSL</ulink> has been
+            upgraded from 1.0 to 1.1.
+            By default, this upgrade could cause problems for recipes that
+            have both versions in their dependency chains.
+            The problem is that both versions cannot be installed together
+            at build time.
+            <note>
+                It is possible to have both versions of the library at runtime.
+            </note>
+        </para>
+    </section>
+
+    <section id='migration-2.6-bitbake-changes'>
+        <title>BitBake Changes</title>
+
+        <para>
+            The server logfile <filename>bitbake-cookerdaemon.log</filename> is
+            now always placed in the
+            <link linkend='build-directory'>Build Directory</link>
+            instead of the current directory.
+        </para>
+    </section>
+
+    <section id='migration-2.6-security-changes'>
+        <title>Security Changes</title>
+
+        <para>
+            The Poky distribution now uses security compiler flags by
+            default.
+            Inclusion of these flags could cause new failures due to stricter
+            checking for various potential security issues in code.
+        </para>
+    </section>
+
+    <section id='migration-2.6-post-installation-changes'>
+        <title>Post Installation Changes</title>
+
+        <para>
+            You must explicitly mark post installs to defer to the target.
+            If you want to explicitly defer a postinstall to first boot on
+            the target rather than at rootfs creation time, use
+            <filename>pkg_postinst_ontarget()</filename> or call
+            <filename>postinst-intercepts defer_to_first_boot</filename> from
+            <filename>pkg_postinst()</filename>.
+            Any failure of a <filename>pkg_postinst()</filename> script
+            (including exit 1) triggers an error during the
+            <link linkend='ref-tasks-rootfs'><filename>do_rootfs</filename></link> task.
+        </para>
+
+        <para>
+            For more information on post-installation behavior, see the
+            "<ulink url='&YOCTO_DOCS_DEV_URL;#new-recipe-post-installation-scripts'>Post-Installation Scripts</ulink>"
+            section in the Yocto Project Development Tasks Manual.
+        </para>
+    </section>
+
+    <section id='migration-2.6-python-3-profile-guided-optimizations'>
+        <title>Python 3 Profile-Guided Optimization</title>
+
+        <para>
+            The <filename>python3</filename> recipe now enables profile-guided
+            optimization.
+            Using this optimization requires a little extra build time in
+            exchange for improved performance on the target at runtime.
+            Additionally, the optimization is only enabled if the current
+            <link linkend='var-MACHINE'><filename>MACHINE</filename></link>
+            has support for user-mode emulation in QEMU (i.e. "qemu-usermode"
+            is in
+            <link linkend='var-MACHINE_FEATURES'><filename>MACHINE_FEATURES</filename></link>,
+            which it is by default).
+        </para>
+
+        <para>
+            If you wish to disable Python profile-guided optimization
+            regardless of the value of
+            <filename>MACHINE_FEATURES</filename>, then ensure that
+            <link linkend='var-PACKAGECONFIG'><filename>PACKAGECONFIG</filename></link>
+            for the <filename>python3</filename> recipe does not contain "pgo".
+            You could accomplish the latter using the following at the
+            configuration level:
+            <literallayout class='monospaced'>
+     PACKAGECONFIG_remove_pn-python3 = "pgo"
+            </literallayout>
+            Alternatively, you can set
+            <filename>PACKAGECONFIG</filename> using an append file for the
+            <filename>python3</filename> recipe.
+        </para>
+    </section>
+
+    <section id='migration-2.6-miscellaneous-changes'>
+        <title>Miscellaneous Changes</title>
+
+        <para>
+            The following miscellaneous changes occurred:
+            <itemizedlist>
+                <listitem><para>
+                    Default to using the Thumb-2 instruction set for armv7a
+                    and above.
+                    If you have any custom recipes that build software that
+                    needs to be built with the ARM instruction set, change the
+                    recipe to set the instruction set as follows:
+                    <literallayout class='monospaced'>
+     ARM_INSTRUCTION_SET = "arm"
+                    </literallayout>
+                    </para></listitem>
+                <listitem><para>
+                    <filename>run-postinsts</filename> no longer uses
+                    <filename>/etc/*-postinsts</filename> for
+                    <filename>dpkg/opkg</filename> in favor of built-in
+                    postinst support.
+                    RPM behavior remains unchanged.
+                    </para></listitem>
+                <listitem><para>
+                    The <filename>NOISO</filename> and
+                    <filename>NOHDD</filename> variables are no longer used.
+                    You now control building <filename>*.iso</filename> and
+                    <filename>*.hddimg</filename> image types directly
+                    by using the
+                    <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>
+                    variable.
+                    </para></listitem>
+                <listitem><para>
+                    The <filename>scripts/contrib/mkefidisk.sh</filename>
+                    has been removed in favor of Wic.
+                    </para></listitem>
+                <listitem><para>
+                    <filename>kernel-modules</filename> has been removed from
+                    <link linkend='var-RRECOMMENDS'><filename>RRECOMMENDS</filename></link>
+                    for <filename>qemumips</filename> and
+                    <filename>qemumips64</filename> machines.
+                    Removal also impacts the <filename>x86-base.inc</filename>
+                    file.
+                    <note>
+                        <filename>genericx86</filename> and
+                        <filename>genericx86-64</filename> retain
+                        <filename>kernel-modules</filename> as part of the
+                        <filename>RRECOMMENDS</filename> variable setting.
+                    </note>
+                    </para></listitem>
+                <listitem><para>
+                    The <filename>LGPLv2_WHITELIST_GPL-3.0</filename>
+                    variable has been removed.
+                    If you are setting this variable in your configuration,
+                    set or append it to the
+                    <filename>WHITELIST_GPL-3.0</filename> variable instead.
+                    </para></listitem>
+                <listitem><para>
+                    <filename>${ASNEEDED}</filename> is now included in
+                    the
+                    <link linkend='var-TARGET_LDFLAGS'><filename>TARGET_LDFLAGS</filename></link>
+                    variable directly.
+                    The remaining definitions from
+                    <filename>meta/conf/distro/include/as-needed.inc</filename>
+                    have been moved to corresponding recipes.
+                    </para></listitem>
+                <listitem><para>
+                    Support for DSA host keys has been dropped from the
+                    OpenSSH recipes.
+                    If you are still using DSA keys, you must switch over to a
+                    more secure algorithm as recommended by OpenSSH upstream.
+                    </para></listitem>
+                <listitem><para>
+                    The <filename>dhcp</filename> recipe now uses the
+                    <filename>dhcpd6.conf</filename> configuration file in
+                    <filename>dhcpd6.service</filename> for IPv6 DHCP rather
+                    than re-using <filename>dhcpd.conf</filename>, which is
+                    now reserved for IPv4.
+                    </para></listitem>
+            </itemizedlist>
+        </para>
+    </section>
+</section>
 </chapter>
 <!--
 vim: expandtab tw=80 ts=4
diff --git a/poky/documentation/ref-manual/ref-classes.xml b/poky/documentation/ref-manual/ref-classes.xml
index 77f21ed..d602851 100644
--- a/poky/documentation/ref-manual/ref-classes.xml
+++ b/poky/documentation/ref-manual/ref-classes.xml
@@ -449,12 +449,13 @@
     <title><filename>cmake.bbclass</filename></title>
 
     <para>
-        The <filename>cmake</filename> class allows for
-        recipes that need to build software using the CMake build system.
+        The <filename>cmake</filename> class allows for recipes that need to
+        build software using the
+        <ulink url='https://cmake.org/overview/'>CMake</ulink> build system.
         You can use the
         <link linkend='var-EXTRA_OECMAKE'><filename>EXTRA_OECMAKE</filename></link>
-        variable to specify additional configuration options to be passed on
-        the <filename>cmake</filename> command line.
+        variable to specify additional configuration options to be passed
+        using the <filename>cmake</filename> command line.
     </para>
 </section>
 
@@ -645,6 +646,54 @@
     </para>
 </section>
 
+<section id='ref-classes-devupstream'>
+    <title><filename>devupstream.bbclass</filename></title>
+
+    <para>
+        The <filename>devupstream</filename> class uses
+        <link linkend='var-BBCLASSEXTEND'><filename>BBCLASSEXTEND</filename></link>
+        to add a variant of the recipe that fetches from an alternative URI
+        (e.g. Git) instead of a tarball.
+        Following is an example:
+        <literallayout class='monospaced'>
+     BBCLASSEXTEND = "devupstream:target"
+     SRC_URI_class-devupstream = "git://git.example.com/example"
+     SRCREV_class-devupstream = "abcd1234"
+        </literallayout>
+        Adding the above statements to your recipe creates a variant that has
+        <link linkend='var-DEFAULT_PREFERENCE'><filename>DEFAULT_PREFERENCE</filename></link>
+        set to "-1".
+        Consequently, you need to select the variant of the recipe to use it.
+        Any development-specific adjustments can be done by using the
+        <filename>class-devupstream</filename> override.
+        Here is an example:
+        <literallayout class='monospaced'>
+     DEPENDS_append_class-devupstream = " gperf-native"
+
+     do_configure_prepend_class-devupstream() {
+        touch ${S}/README
+     }
+        </literallayout>
+        The class currently only supports creating a development variant of
+        the target recipe, not <filename>native</filename> or
+        <filename>nativesdk</filename> variants.
+    </para>
+
+    <para>
+        The <filename>BBCLASSEXTEND</filename> syntax
+        (i.e. <filename>devupstream:target</filename>) provides support for
+        <filename>native</filename> and <filename>nativesdk</filename>
+        variants.
+        Consequently, this functionality can be added in a future release.
+    </para>
+
+    <para>
+        Support for other version control systems such as Subversion is
+        limited due to BitBake's automatic fetch dependencies (e.g.
+        <filename>subversion-native</filename>).
+    </para>
+</section>
+
 <section id='ref-classes-distro_features_check'>
     <title><filename>distro_features_check.bbclass</filename></title>
 
@@ -1266,28 +1315,35 @@
     <title><filename>image_types.bbclass</filename></title>
 
     <para>
-        The <filename>image_types</filename> class defines all of
-        the standard image output types that you can enable through the
+        The <filename>image_types</filename> class defines all of the
+        standard image output types that you can enable through the
         <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>
         variable.
-        You can use this class as a reference on how to add support for custom
-        image output types.
+        You can use this class as a reference on how to add support for
+        custom image output types.
     </para>
 
     <para>
-        By default, this class is enabled through the
-        <link linkend='var-IMAGE_CLASSES'><filename>IMAGE_CLASSES</filename></link>
-        variable in
-        <link linkend='ref-classes-image'><filename>image.bbclass</filename></link>.
-        If you define your own image types using a custom BitBake class and
-        then use <filename>IMAGE_CLASSES</filename> to enable it, the custom
-        class must either inherit <filename>image_types</filename> or
-        <filename>image_types</filename> must also appear in
-        <filename>IMAGE_CLASSES</filename>.
+        By default, the
+        <link linkend='ref-classes-image'><filename>image</filename></link>
+        class automatically enables the <filename>image_types</filename> class.
+        The <filename>image</filename> class uses the
+        <filename>IMGCLASSES</filename> variable as follows:
+        <literallayout class='monospaced'>
+     IMGCLASSES = "rootfs_${IMAGE_PKGTYPE} image_types ${IMAGE_CLASSES}"
+     IMGCLASSES += "${@['populate_sdk_base', 'populate_sdk_ext']['linux' in d.getVar("SDK_OS")]}"
+     IMGCLASSES += "${@bb.utils.contains_any('IMAGE_FSTYPES', 'live iso hddimg', 'image-live', '', d)}"
+     IMGCLASSES += "${@bb.utils.contains('IMAGE_FSTYPES', 'container', 'image-container', '', d)}"
+     IMGCLASSES += "image_types_wic"
+     IMGCLASSES += "rootfs-postcommands"
+     IMGCLASSES += "image-postinst-intercepts"
+     inherit ${IMGCLASSES}
+        </literallayout>
     </para>
 
     <para>
-        This class also handles conversion and compression of images.
+        The <filename>image_types</filename> class also handles conversion and
+        compression of images.
         <note>
             To build a VMware VMDK image, you need to add "wic.vmdk" to
             <filename>IMAGE_FSTYPES</filename>.
@@ -1314,14 +1370,6 @@
         Normally, you do not use this class directly.
         Instead, you add "live" to
         <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>.
-        You can selectively build just one of these types through the
-        <link linkend='var-NOISO'><filename>NOISO</filename></link>
-        and
-        <link linkend='var-NOHDD'><filename>NOHDD</filename></link> variables.
-        For example, if you were building an ISO image, you would add "live"
-        to <filename>IMAGE_FSTYPES</filename>, set the
-        <filename>NOISO</filename> variable to "0" and the build system would
-        use the <filename>image-live</filename> class to build the ISO image.
     </para>
 </section>
 
@@ -2173,8 +2221,9 @@
 
     <para>
         The <filename>native</filename> class provides common
-        functionality for recipes that wish to build tools to run on the build
-        host (i.e. tools that use the compiler or other tools from the
+        functionality for recipes that build tools to run on the
+        <link linkend='hardware-build-system-term'>build host</link>
+        (i.e. tools that use the compiler or other tools from the
         build host).
     </para>
 
@@ -2182,30 +2231,35 @@
         You can create a recipe that builds tools that run natively on the
         host a couple different ways:
         <itemizedlist>
-            <listitem><para>Create a <replaceable>myrecipe</replaceable><filename>-native.bb</filename>
-                that inherits the <filename>native</filename> class.
+            <listitem><para>
+                Create a
+                <replaceable>myrecipe</replaceable><filename>-native.bb</filename>
+                recipe that inherits the <filename>native</filename> class.
                 If you use this method, you must order the inherit statement
                 in the recipe after all other inherit statements so that the
                 <filename>native</filename> class is inherited last.
+                <note><title>Warning</title>
+                    When creating a recipe this way, the recipe name must
+                    follow this naming convention:
+                    <literallayout class='monospaced'>
+     <replaceable>myrecipe</replaceable>-native.bb
+                    </literallayout>
+                    Not using this naming convention can lead to subtle
+                    problems caused by existing code that depends on that
+                    naming convention.
+                </note>
                 </para></listitem>
-            <listitem><para>Create or modify a target recipe that contains
-                the following:
+            <listitem><para>
+                Create or modify a target recipe that contains the following:
                 <literallayout class='monospaced'>
      <link linkend='var-BBCLASSEXTEND'><filename>BBCLASSEXTEND</filename></link> = "native"
                 </literallayout>
                 Inside the recipe, use <filename>_class-native</filename> and
                 <filename>_class-target</filename> overrides to specify any
                 functionality specific to the respective native or target
-                case.</para></listitem>
+                case.
+                </para></listitem>
         </itemizedlist>
-        <note><title>Warning</title>
-            When creating a recipe, you must follow this naming convention:
-            <literallayout class='monospaced'>
-     native-<replaceable>myrecipe</replaceable>.bb
-            </literallayout>
-            Not doing so can lead to subtle problems because code exists
-            that depends on the naming convention.
-        </note>
     </para>
 
     <para>
@@ -3145,12 +3199,6 @@
         and <filename><link linkend='var-SITEINFO_BITS'>SITEINFO_BITS</link></filename>
         that can be used elsewhere in the metadata.
     </para>
-
-    <para>
-        Because the
-        <link linkend='ref-classes-base'><filename>base</filename></link> class
-        includes the <filename>siteinfo</filename> class, it is always active.
-    </para>
 </section>
 
 <section id='ref-classes-spdx'>
@@ -3502,6 +3550,14 @@
         The classes handle loading the tests and starting the image.
         To use the classes, you need to perform steps to set up the
         environment.
+        <note><title>Tip</title>
+            Best practices include using
+            <link linkend='var-IMAGE_CLASSES'><filename>IMAGE_CLASSES</filename></link>
+            rather than
+            <link linkend='var-INHERIT'><filename>INHERIT</filename></link> to
+            inherit the <filename>testimage</filename> class for automated
+            image testing.
+        </note>
     </para>
 
     <para>
@@ -3519,7 +3575,7 @@
         </literallayout>
         The <filename>testimage-auto</filename> class runs tests on an image
         after the image is constructed (i.e.
-        <link linkend='var-TEST_IMAGE'><filename>TEST_IMAGE</filename></link>
+        <link linkend='var-TESTIMAGE_AUTO'><filename>TESTIMAGE_AUTO</filename></link>
         must be set to "1").
     </para>
 
@@ -3541,6 +3597,14 @@
         <literallayout class='monospaced'>
      $ bitbake -c testsdk image
         </literallayout>
+        <note><title>Tip</title>
+            Best practices include using
+            <link linkend='var-IMAGE_CLASSES'><filename>IMAGE_CLASSES</filename></link>
+            rather than
+            <link linkend='var-INHERIT'><filename>INHERIT</filename></link> to
+            inherit the <filename>testsdk</filename> class for automated
+            SDK testing.
+        </note>
     </para>
 </section>
 
diff --git a/poky/documentation/ref-manual/ref-manual.xml b/poky/documentation/ref-manual/ref-manual.xml
index 9d491e1..f834d2d 100644
--- a/poky/documentation/ref-manual/ref-manual.xml
+++ b/poky/documentation/ref-manual/ref-manual.xml
@@ -123,14 +123,14 @@
                 <revremark>Released with the Yocto Project 2.5 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.1</revnumber>
-                <date>September 2018</date>
-                <revremark>The initial document released with the Yocto Project 2.5.1 Release.</revremark>
+                <revnumber>2.6</revnumber>
+                <date>November 2018</date>
+                <revremark>Released with the Yocto Project 2.6 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.2</revnumber>
+                <revnumber>2.6.1</revnumber>
                 <date>&REL_MONTH_YEAR;</date>
-                <revremark>The initial document released with the Yocto Project 2.5.2 Release.</revremark>
+                <revremark>Released with the Yocto Project 2.6.1 Release.</revremark>
             </revision>
         </revhistory>
 
diff --git a/poky/documentation/ref-manual/ref-release-process.xml b/poky/documentation/ref-manual/ref-release-process.xml
index c665cd9..5efe174 100644
--- a/poky/documentation/ref-manual/ref-release-process.xml
+++ b/poky/documentation/ref-manual/ref-release-process.xml
@@ -189,7 +189,7 @@
                     Running <filename>oe-selftest</filename> requires
                     host packages beyond the "Essential" grouping.
                     See the
-                    "<link linkend='required-packages-for-the-host-development-system'>Required Packages for the Host Development System</link>"
+                    "<link linkend='required-packages-for-the-build-host'>Required Packages for the Build Host</link>"
                     section for more information.
                 </note>
                 </para></listitem>
diff --git a/poky/documentation/ref-manual/ref-system-requirements.xml b/poky/documentation/ref-manual/ref-system-requirements.xml
index aea1fdf..69d4b4e 100644
--- a/poky/documentation/ref-manual/ref-system-requirements.xml
+++ b/poky/documentation/ref-manual/ref-system-requirements.xml
@@ -66,6 +66,14 @@
                         below.
                         </para></listitem>
                     <listitem><para>
+                        The Yocto Project is not compatible with the
+                        <ulink url='https://en.wikipedia.org/wiki/Windows_Subsystem_for_Linux'>Windows Subsystem for Linux</ulink>
+                        (WSL).
+                        You cannot use a
+                        <link linkend='hardware-build-system-term'>build host</link>
+                        that is running WSL.
+                        </para></listitem>
+                    <listitem><para>
                         If you encounter problems, please go to
                         <ulink url='&YOCTO_BUGZILLA_URL;'>Yocto Project Bugzilla</ulink>
                         and submit a bug.
@@ -80,46 +88,49 @@
                 </itemizedlist>
             </note>
             <itemizedlist>
-<!--
-                <listitem><para>Ubuntu 10.04</para></listitem>
+<!--            <listitem><para>Ubuntu 10.04</para></listitem>
                 <listitem><para>Ubuntu 11.10</para></listitem>
                 <listitem><para>Ubuntu 12.04 (LTS)</para></listitem>
                 <listitem><para>Ubuntu 13.10</para></listitem>
-                <listitem><para>Ubuntu 14.04 (LTS)</para></listitem> -->
+                <listitem><para>Ubuntu 14.04 (LTS)</para></listitem>
                 <listitem><para>Ubuntu 14.10</para></listitem>
                 <listitem><para>Ubuntu 15.04</para></listitem>
-                <listitem><para>Ubuntu 15.10</para></listitem>
+                <listitem><para>Ubuntu 15.10</para></listitem> -->
                 <listitem><para>Ubuntu 16.04 (LTS)</para></listitem>
-<!--                <listitem><para>Fedora 16 (Verne)</para></listitem>
+                <listitem><para>Ubuntu 16.10 (LTS)</para></listitem>
+                <listitem><para>Ubuntu 17.04</para></listitem>
+<!--            <listitem><para>Fedora 16 (Verne)</para></listitem>
                 <listitem><para>Fedora 17 (Spherical)</para></listitem>
-                <listitem><para>Fedora release 19 (Schrödinger's Cat)</para></listitem>
-                <listitem><para>Fedora release 20 (Heisenbug)</para></listitem> -->
+                <listitem><para>Fedora 19 (Schrödinger's Cat)</para></listitem>
+                <listitem><para>Fedora release 20 (Heisenbug)</para></listitem>
                 <listitem><para>Fedora release 22</para></listitem>
                 <listitem><para>Fedora release 23</para></listitem>
-<!--                <listitem><para>Fedora release 24</para></listitem>
-                <listitem><para>CentOS release 5.6 (Final)</para></listitem>
+                <listitem><para>Fedora release 24</para></listitem> -->
+                <listitem><para>Fedora release 26</para></listitem>
+<!--            <listitem><para>CentOS release 5.6 (Final)</para></listitem>
                 <listitem><para>CentOS release 5.7 (Final)</para></listitem>
                 <listitem><para>CentOS release 5.8 (Final)</para></listitem>
                 <listitem><para>CentOS release 6.3 (Final)</para></listitem>
                 <listitem><para>CentOS release 6.x</para></listitem> -->
                 <listitem><para>CentOS release 7.x</para></listitem>
-<!--                <listitem><para>Debian GNU/Linux 6.0 (Squeeze)</para></listitem>
+<!--            <listitem><para>Debian GNU/Linux 6.0 (Squeeze)</para></listitem>
                 <listitem><para>Debian GNU/Linux 7.x (Wheezy)</para></listitem> -->
                 <listitem><para>Debian GNU/Linux 8.x (Jessie)</para></listitem>
                 <listitem><para>Debian GNU/Linux 9.x (Stretch)</para></listitem>
-<!--                <listitem><para>Debian GNU/Linux 7.1 (Wheezy)</para></listitem>
+<!--            <listitem><para>Debian GNU/Linux 7.1 (Wheezy)</para></listitem>
                 <listitem><para>Debian GNU/Linux 7.2 (Wheezy)</para></listitem>
                 <listitem><para>Debian GNU/Linux 7.3 (Wheezy)</para></listitem>
                 <listitem><para>Debian GNU/Linux 7.4 (Wheezy)</para></listitem>
                 <listitem><para>Debian GNU/Linux 7.5 (Wheezy)</para></listitem>
-                <listitem><para>Debian GNU/Linux 7.6 (Wheezy)</para></listitem> -->
-<!--                <listitem><para>openSUSE 11.4</para></listitem>
+                <listitem><para>Debian GNU/Linux 7.6 (Wheezy)</para></listitem>
+                <listitem><para>openSUSE 11.4</para></listitem>
                 <listitem><para>openSUSE 12.1</para></listitem>
                 <listitem><para>openSUSE 12.2</para></listitem>
                 <listitem><para>openSUSE 12.3</para></listitem>
-                <listitem><para>openSUSE 13.1</para></listitem> -->
-                <listitem><para>openSUSE 13.2</para></listitem>
+                <listitem><para>openSUSE 13.1</para></listitem>
+                <listitem><para>openSUSE 13.2</para></listitem> -->
                 <listitem><para>openSUSE 42.1</para></listitem>
+                <listitem><para>openSUSE 42.2</para></listitem>
             </itemizedlist>
         </para>
 
@@ -132,8 +143,8 @@
         </note>
     </section>
 
-    <section id='required-packages-for-the-host-development-system'>
-    <title>Required Packages for the Host Development System</title>
+    <section id='required-packages-for-the-build-host'>
+    <title>Required Packages for the Build Host</title>
 
         <para>
             The list of packages you need on the host development system can
diff --git a/poky/documentation/ref-manual/ref-tasks.xml b/poky/documentation/ref-manual/ref-tasks.xml
index e6cf686..8f3ff26 100644
--- a/poky/documentation/ref-manual/ref-tasks.xml
+++ b/poky/documentation/ref-manual/ref-tasks.xml
@@ -596,15 +596,6 @@
         </para>
     </section>
 
-    <section id='ref-tasks-rm_work_all'>
-        <title><filename>do_rm_work_all</filename></title>
-
-        <para>
-            Top-level task for removing work files after the build system has
-            finished with them.
-        </para>
-    </section>
-
     <section id='ref-tasks-unpack'>
         <title><filename>do_unpack</filename></title>
 
@@ -895,7 +886,7 @@
             Boots an image and performs runtime tests within the image
             immediately after it has been built.
             This task is enabled when you set
-            <link linkend='var-TEST_IMAGE'><filename>TEST_IMAGE</filename></link>
+            <link linkend='var-TESTIMAGE_AUTO'><filename>TESTIMAGE_AUTO</filename></link>
             equal to "1".
         </para>
 
diff --git a/poky/documentation/ref-manual/ref-terms.xml b/poky/documentation/ref-manual/ref-terms.xml
index cc09d3f..c573a52 100644
--- a/poky/documentation/ref-manual/ref-terms.xml
+++ b/poky/documentation/ref-manual/ref-terms.xml
@@ -29,11 +29,31 @@
                 information in the similarly-named recipe file.
                 For an example of an append file in use, see the
                 "<ulink url='&YOCTO_DOCS_DEV_URL;#using-bbappend-files'>Using .bbappend Files in Your Layer</ulink>"
-                section in the Yocto Project Development Tasks Manual.
-                <note>
-                    Append files can also use wildcard patterns in their
-                    version numbers so they can be applied to more than one
-                    version of the underlying recipe file.
+                section in the Yocto Project Development Tasks Manual.</para>
+
+                <para>When you name an append file, you can use the
+                "<filename>%</filename>" wildcard character to allow for
+                matching recipe names.
+                For example, suppose you have an append file named as follows:
+                <literallayout class='monospaced'>
+     busybox_1.21.%.bbappend
+                </literallayout>
+                That append file would match any
+                <filename>busybox_1.21.</filename><replaceable>x</replaceable><filename>.bb</filename>
+                version of the recipe.
+                So, the append file would match the following recipe names:
+                <literallayout class='monospaced'>
+     busybox_1.21.1.bb
+     busybox_1.21.2.bb
+     busybox_1.21.3.bb
+                </literallayout>
+                <note><title>Important</title>
+                    The use of the "<filename>%</filename>" character
+                    is limited in that it only works directly in front of the
+                    <filename>.bbappend</filename> portion of the append file's
+                    name.
+                    You cannot use the wildcard character in any other
+                    location of the name.
                 </note>
                 </para></listitem>
             <listitem><para id='bitbake-term'>
@@ -329,7 +349,7 @@
                 <para>It is worth noting that the term "package" can,
                 in general, have subtle meanings.
                 For example, the packages referred to in the
-                "<link linkend='required-packages-for-the-host-development-system'>Required Packages for the Host Development System</link>"
+                "<link linkend='required-packages-for-the-build-host'>Required Packages for the Build Host</link>"
                 section are compiled binaries that, when installed, add
                 functionality to your Linux distribution.</para>
 
diff --git a/poky/documentation/ref-manual/ref-variables.xml b/poky/documentation/ref-manual/ref-variables.xml
index e883896..9e51b75 100644
--- a/poky/documentation/ref-manual/ref-variables.xml
+++ b/poky/documentation/ref-manual/ref-variables.xml
@@ -679,6 +679,20 @@
                             <literallayout class='monospaced'>
      BB_ALLOWED_NETWORKS = "*.gnu.org"
                             </literallayout>
+                            <note><title>Important</title>
+                                <para>The use of the "<filename>*</filename>"
+                                character only works at the beginning of
+                                a host name and it must be isolated from
+                                the remainder of the host name.
+                                You cannot use the wildcard character in any
+                                other location of the name or combined with
+                                the front part of the name.</para>
+
+                                <para>For example,
+                                <filename>*.foo.bar</filename> is supported,
+                                while <filename>*aa.foo.bar</filename> is not.
+                                </para>
+                            </note>
                             </para></listitem>
                         <listitem><para>
                             Mirrors not in the host list are skipped and
@@ -1133,12 +1147,22 @@
 
         <glossentry id='var-BBFILES'><glossterm>BBFILES</glossterm>
             <info>
-                BBFILES[doc] = "List of recipe files used by BitBake to build software."
+                BBFILES[doc] = "A space-separated list of recipe files BitBake uses to build software."
             </info>
             <glossdef>
                 <para role="glossdeffirst">
 <!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
-                    List of recipe files used by BitBake to build software.
+                    A space-separated list of recipe files BitBake uses to
+                    build software.
+                </para>
+
+                <para>
+                    When specifying recipe files, you can pattern match using
+                    Python's
+                    <ulink url='https://docs.python.org/3/library/glob.html'><filename>glob</filename></ulink>
+                    syntax.
+                    For details on the syntax, see the documentation by
+                    following the previous link.
                 </para>
             </glossdef>
         </glossentry>
@@ -1267,15 +1291,19 @@
                     match any of the expressions.
                     It is as if BitBake does not see them at all.
                     Consequently, matching files are not parsed or otherwise
-                    used by BitBake.</para>
+                    used by BitBake.
+                </para>
+
                 <para>
                     The values you provide are passed to Python's regular
                     expression compiler.
+                    Consequently, the syntax follows Python's Regular
+                    Expression (re) syntax.
                     The expressions are compared against the full paths to
                     the files.
                     For complete syntax information, see Python's
-                    documentation for the appropriate release at
-                    <ulink url='http://docs.python.org/release/'></ulink>.
+                    documentation at
+                    <ulink url='http://docs.python.org/3/library/re.html#re'></ulink>.
                 </para>
 
                 <para>
@@ -1336,7 +1364,7 @@
                     <filename>BBMULTICONFIG</filename> in an environment that
                     supports building targets with multiple configurations,
                     see the
-                    "<ulink url='&YOCTO_DOCS_DEV_URL;#platdev-building-targets-with-multiple-configurations'>Building Targets with Multiple Configurations</ulink>"
+                    "<ulink url='&YOCTO_DOCS_DEV_URL;#dev-building-images-for-multiple-targets-using-multiple-configurations'>Building Images for Multiple Targets Using Multiple Configurations</ulink>"
                     section in the Yocto Project Development Tasks Manual.
                 </para>
             </glossdef>
@@ -1443,6 +1471,17 @@
                     set up during compilation so that they are correct for
                     use when installed into the sysroot and called by the
                     build processes of other recipes.
+                    <note>
+                        The <filename>BINCONFIG_GLOB</filename> variable
+                        uses
+                        <ulink url='http://tldp.org/LDP/abs/html/globbingref.html'>shell globbing</ulink>,
+                        which is recognition and expansion of wildcards during
+                        pattern matching.
+                        Shell globbing is very similar to
+                        <ulink url='https://docs.python.org/2/library/fnmatch.html#module-fnmatch'><filename>fnmatch</filename></ulink>
+                        and
+                        <ulink url='https://docs.python.org/2/library/glob.html'><filename>glob</filename></ulink>.
+                    </note>
                 </para>
 
                 <para>
@@ -2366,6 +2405,14 @@
                     Defines wildcards to match when installing a list of
                     complementary packages for all the packages explicitly
                     (or implicitly) installed in an image.
+                    <note>
+                        The <filename>COMPLEMENTARY_GLOB</filename> variable
+                        uses Unix filename pattern matching
+                        (<ulink url='https://docs.python.org/2/library/fnmatch.html#module-fnmatch'><filename>fnmatch</filename></ulink>),
+                        which is similar to the Unix style pathname pattern
+                        expansion
+                        (<ulink url='https://docs.python.org/2/library/glob.html'><filename>glob</filename></ulink>).
+                    </note>
                     The resulting list of complementary packages is associated
                     with an item that can be added to
                     <link linkend='var-IMAGE_FEATURES'><filename>IMAGE_FEATURES</filename></link>.
@@ -4586,7 +4633,12 @@
             <glossdef>
                 <para role="glossdeffirst">
 <!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
-                    Additional <filename>cmake</filename> options.
+                    Additional
+                    <ulink url='https://cmake.org/overview/'>CMake</ulink>
+                    options.
+                    See the
+                    <link linkend='ref-classes-cmake'><filename>cmake</filename></link>
+                    class for additional information.
                 </para>
             </glossdef>
         </glossentry>
@@ -4782,23 +4834,38 @@
                     <literallayout class='monospaced'>
      FILES_${PN} += "${bindir}/mydir1 ${bindir}/mydir2/myfile"
                     </literallayout>
+                    <note><title>Notes</title>
+                        <itemizedlist>
+                            <listitem><para>
+                                When specifying files or paths, you can pattern
+                                match using Python's
+                                <ulink url='https://docs.python.org/2/library/glob.html'><filename>glob</filename></ulink>
+                                syntax.
+                                For details on the syntax, see the
+                                documentation by following the previous link.
+                                </para></listitem>
+                            <listitem><para>
+                                When specifying paths as part of the
+                                <filename>FILES</filename> variable, it is
+                                good practice to use appropriate path
+                                variables.
+                                For example, use <filename>${sysconfdir}</filename>
+                                rather than <filename>/etc</filename>, or
+                                <filename>${bindir}</filename> rather than
+                                <filename>/usr/bin</filename>.
+                                You can find a list of these variables at the
+                                top of the
+                                <filename>meta/conf/bitbake.conf</filename>
+                                file in the
+                                <link linkend='source-directory'>Source Directory</link>.
+                                You will also find the default values of the
+                                various <filename>FILES_*</filename> variables
+                                in this file.
+                                </para></listitem>
+                        </itemizedlist>
+                    </note>
                 </para>
 
-                <note>
-                    When specifying paths as part of the
-                    <filename>FILES</filename> variable, it is good practice
-                    to use appropriate path variables.
-                    For example, use <filename>${sysconfdir}</filename> rather
-                    than <filename>/etc</filename>, or
-                    <filename>${bindir}</filename> rather than
-                    <filename>/usr/bin</filename>.
-                    You can find a list of these variables at the top of the
-                    <filename>meta/conf/bitbake.conf</filename> file in the
-                    <link linkend='source-directory'>Source Directory</link>.
-                    You will also find the default values of the various
-                    <filename>FILES_*</filename> variables in this file.
-                </note>
-
                 <para>
                     If some of the files you provide with the
                     <filename>FILES</filename> variable are editable and you
@@ -5166,6 +5233,28 @@
             </glossdef>
         </glossentry>
 
+        <glossentry id='var-GCCVERSION'><glossterm>GCCVERSION</glossterm>
+            <info>
+                GCCVERSION[doc] = "Specifies the default version of the GNU C Compiler (GCC) to use."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    Specifies the default version of the GNU C Compiler (GCC)
+                    used for compilation.
+                    By default, <filename>GCCVERSION</filename> is set to
+                    "8.x" in the
+                    <filename>meta/conf/distro/include/tcmode-default.inc</filename>
+                    include file:
+                    <literallayout class='monospaced'>
+     GCCVERSION ?= "8.%"
+                    </literallayout>
+                    You can override this value by setting it in a configuration
+                    file such as the <filename>local.conf</filename>.
+                </para>
+            </glossdef>
+        </glossentry>
+
         <glossentry id='var-GDB'><glossterm>GDB</glossterm>
             <info>
                 GDB[doc] = "The minimal command and arguments to run the GNU Debugger."
@@ -6940,6 +7029,61 @@
             </glossdef>
         </glossentry>
 
+        <glossentry id='var-INITRAMFS_LINK_NAME'><glossterm>INITRAMFS_LINK_NAME</glossterm>
+            <info>
+                INITRAMFS_LINK_NAME[doc] = "The link name of the initial RAM filesystem image."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    The link name of the initial RAM filesystem image.
+                    This variable is set in the
+                    <filename>meta/classes/kernel-artifact-names.bbclass</filename>
+                    file as follows:
+                    <literallayout class='monospaced'>
+     INITRAMFS_LINK_NAME ?= "initramfs-${KERNEL_ARTIFACT_LINK_NAME}"
+                    </literallayout>
+                    The value of the <filename>KERNEL_ARTIFACT_LINK_NAME</filename>
+                    variable, which is set in the same file, has the following
+                    value:
+                    <literallayout class='monospaced'>
+     KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}"
+                    </literallayout>
+                </para>
+
+                <para>
+                    See the
+                    <link linkend='var-MACHINE'><filename>MACHINE</filename></link>
+                    variable for additional information.
+                </para>
+            </glossdef>
+        </glossentry>
+
+        <glossentry id='var-INITRAMFS_NAME'><glossterm>INITRAMFS_NAME</glossterm>
+            <info>
+                INITRAMFS_NAME[doc] = "The base name of the initial RAM filesystem image."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    The base name of the initial RAM filesystem image.
+                    This variable is set in the
+                    <filename>meta/classes/kernel-artifact-names.bbclass</filename>
+                    file as follows:
+                    <literallayout class='monospaced'>
+     INITRAMFS_NAME ?= "initramfs-${KERNEL_ARTIFACT_NAME}"
+                    </literallayout>
+                    The value of the
+                    <link linkend='var-KERNEL_ARTIFACT_NAME'><filename>KERNEL_ARTIFACT_NAME</filename></link>
+                    variable, which is set in the same file, has the following
+                    value:
+                    <literallayout class='monospaced'>
+     KERNEL_ARTIFACT_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}${IMAGE_VERSION_SUFFIX}"
+                    </literallayout>
+                </para>
+            </glossdef>
+        </glossentry>
+
         <glossentry id='var-INITRD'><glossterm>INITRD</glossterm>
             <info>
                 INITRD[doc] = "Indicates a list of filesystem images to concatenate and use as an initial RAM disk (initrd)."
@@ -7316,6 +7460,45 @@
             </glossdef>
         </glossentry>
 
+        <glossentry id='var-KERNEL_ARTIFACT_NAME'><glossterm>KERNEL_ARTIFACT_NAME</glossterm>
+            <info>
+                KERNEL_ARTIFACT_NAME[doc] = "Specifies the name of all of the build artifacts."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    Specifies the name of all of the build artifacts.
+                    You can change the name of the artifacts by changing the
+                    <filename>KERNEL_ARTIFACT_NAME</filename> variable.
+                </para>
+
+                <para>
+                    The value of <filename>KERNEL_ARTIFACT_NAME</filename>,
+                    which is set in the
+                    <filename> meta/classes/kernel-artifact-names.bbclass</filename>
+                    file, has the following default value:
+                    <literallayout class='monospaced'>
+     KERNEL_ARTIFACT_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}${IMAGE_VERSION_SUFFIX}"
+                    </literallayout>
+                </para>
+
+                <para>
+                    See the
+                    <link linkend='var-PKGE'><filename>PKGE</filename></link>,
+                    <link linkend='var-PKGV'><filename>PKGV</filename></link>,
+                    <link linkend='var-PKGR'><filename>PKGR</filename></link>,
+                    and
+                    <link linkend='var-MACHINE'><filename>MACHINE</filename></link>
+                    variables for additional information.
+                    <note>
+                        The <filename>IMAGE_VERSION_SUFFIX</filename> variable
+                        is set to
+                        <link linkend='var-DATETIME'><filename>DATETIME</filename></link>.
+                    </note>
+                </para>
+            </glossdef>
+        </glossentry>
+
         <glossentry id='var-KERNEL_CLASSES'><glossterm>KERNEL_CLASSES</glossterm>
             <info>
                 KERNEL_CLASSES[doc] = "A list of classes defining kernel image types that kernel class should inherit."
@@ -7365,6 +7548,61 @@
             </glossdef>
         </glossentry>
 
+        <glossentry id='var-KERNEL_DTB_LINK_NAME'><glossterm>KERNEL_DTB_LINK_NAME</glossterm>
+            <info>
+                KERNEL_DTB_LINK_NAME[doc] = "The link name of the kernel device tree binary (DTB)."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    The link name of the kernel device tree binary (DTB).
+                    This variable is set in the
+                    <filename>meta/classes/kernel-artifact-names.bbclass</filename>
+                    file as follows:
+                    <literallayout class='monospaced'>
+     KERNEL_DTB_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}"
+                    </literallayout>
+                    The value of the <filename>KERNEL_ARTIFACT_LINK_NAME</filename>
+                    variable, which is set in the same file, has the following
+                    value:
+                    <literallayout class='monospaced'>
+     KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}"
+                    </literallayout>
+                </para>
+
+                <para>
+                    See the
+                    <link linkend='var-MACHINE'><filename>MACHINE</filename></link>
+                    variable for additional information.
+                </para>
+            </glossdef>
+        </glossentry>
+
+        <glossentry id='var-KERNEL_DTB_NAME'><glossterm>KERNEL_DTB_NAME</glossterm>
+            <info>
+                KERNEL_DTB_NAME[doc] = "The base name of the kernel device tree binary (DTB)."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    The base name of the kernel device tree binary (DTB).
+                    This variable is set in the
+                    <filename>meta/classes/kernel-artifact-names.bbclass</filename>
+                    file as follows:
+                    <literallayout class='monospaced'>
+     KERNEL_DTB_NAME ?= "${KERNEL_ARTIFACT_NAME}"
+                    </literallayout>
+                    The value of the
+                    <link linkend='var-KERNEL_ARTIFACT_NAME'><filename>KERNEL_ARTIFACT_NAME</filename></link>
+                    variable, which is set in the same file, has the following
+                    value:
+                    <literallayout class='monospaced'>
+     KERNEL_ARTIFACT_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}${IMAGE_VERSION_SUFFIX}"
+                    </literallayout>
+                </para>
+            </glossdef>
+        </glossentry>
+
         <glossentry id='var-KERNEL_EXTRA_ARGS'><glossterm>KERNEL_EXTRA_ARGS</glossterm>
             <info>
                 KERNEL_EXTRA_ARGS[doc] = "Specifies additional make command-line arguments the OpenEmbedded build system passes on when compiling the kernel."
@@ -7422,38 +7660,93 @@
                     <literallayout class='monospaced'>
      KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc features/taskstats/taskstats.scc"
      KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}"
-     KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc"
-     KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
-     KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc"
-                    </literallayout></para>
+     KERNEL_FEATURES_append_qemuall = " cfg/virtio.scc"
+     KERNEL_FEATURES_append_qemux86 = " cfg/sound.scc cfg/paravirt_kvm.scc"
+     KERNEL_FEATURES_append_qemux86-64 = " cfg/sound.scc"                    </literallayout></para>
             </glossdef>
         </glossentry>
 
-        <glossentry id='var-KERNEL_IMAGE_BASE_NAME'><glossterm>KERNEL_IMAGE_BASE_NAME</glossterm>
+        <glossentry id='var-KERNEL_FIT_LINK_NAME'><glossterm>KERNEL_FIT_LINK_NAME</glossterm>
             <info>
-                KERNEL_IMAGE_BASE_NAME[doc] = "The base name of the kernel image."
+                KERNEL_FIT_LINK_NAME[doc] = "The link name of the kernel flattened image tree (FIT) image."
             </info>
             <glossdef>
                 <para role="glossdeffirst">
 <!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
-                    The base name of the kernel image.
+                    The link name of the kernel flattened image tree (FIT) image.
                     This variable is set in the
-                    <link linkend='ref-classes-kernel'>kernel</link> class
-                    as follows:
+                    <filename>meta/classes/kernel-artifact-names.bbclass</filename>
+                    file as follows:
                     <literallayout class='monospaced'>
-     KERNEL_IMAGE_BASE_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}-${DATETIME}"
+     KERNEL_FIT_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}"
+                    </literallayout>
+                    The value of the <filename>KERNEL_ARTIFACT_LINK_NAME</filename>
+                    variable, which is set in the same file, has the following
+                    value:
+                    <literallayout class='monospaced'>
+     KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}"
                     </literallayout>
                 </para>
 
                 <para>
                     See the
-                    <link linkend='var-PKGE'><filename>PKGE</filename></link>,
-                    <link linkend='var-PKGV'><filename>PKGV</filename></link>,
-                    <link linkend='var-PKGR'><filename>PKGR</filename></link>,
-                    <link linkend='var-MACHINE'><filename>MACHINE</filename></link>,
-                    and
-                    <link linkend='var-DATETIME'><filename>DATETIME</filename></link>
-                    variables for additional information.
+                    <link linkend='var-MACHINE'><filename>MACHINE</filename></link>
+                    variable for additional information.
+                </para>
+            </glossdef>
+        </glossentry>
+
+        <glossentry id='var-KERNEL_FIT_NAME'><glossterm>KERNEL_FIT_NAME</glossterm>
+            <info>
+                KERNEL_FIT_NAME[doc] = "The base name of the kernel flattened image tree (FIT) image."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    The base name of the kernel flattened image tree (FIT) image.
+                    This variable is set in the
+                    <filename>meta/classes/kernel-artifact-names.bbclass</filename>
+                    file as follows:
+                    <literallayout class='monospaced'>
+     KERNEL_FIT_NAME ?= "${KERNEL_ARTIFACT_NAME}"
+                    </literallayout>
+                    The value of the
+                    <link linkend='var-KERNEL_ARTIFACT_NAME'><filename>KERNEL_ARTIFACT_NAME</filename></link>
+                    variable, which is set in the same file, has the following
+                    value:
+                    <literallayout class='monospaced'>
+     KERNEL_ARTIFACT_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}${IMAGE_VERSION_SUFFIX}"
+                    </literallayout>
+                </para>
+            </glossdef>
+        </glossentry>
+
+        <glossentry id='var-KERNEL_IMAGE_LINK_NAME'><glossterm>KERNEL_IMAGE_LINK_NAME</glossterm>
+            <info>
+                KERNEL_IMAGE_LINK_NAME[doc] = "The link name for the kernel image."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    The link name for the kernel image.
+                    This variable is set in the
+                    <filename>meta/classes/kernel-artifact-names.bbclass</filename>
+                    file as follows:
+                    <literallayout class='monospaced'>
+     KERNEL_IMAGE_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}"
+                    </literallayout>
+                    The value of the <filename>KERNEL_ARTIFACT_LINK_NAME</filename>
+                    variable, which is set in the same file, has the following
+                    value:
+                    <literallayout class='monospaced'>
+     KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}"
+                    </literallayout>
+                </para>
+
+                <para>
+                    See the
+                    <link linkend='var-MACHINE'><filename>MACHINE</filename></link>
+                    variable for additional information.
                 </para>
             </glossdef>
         </glossentry>
@@ -7489,6 +7782,31 @@
             </glossdef>
         </glossentry>
 
+        <glossentry id='var-KERNEL_IMAGE_NAME'><glossterm>KERNEL_IMAGE_NAME</glossterm>
+            <info>
+                KERNEL_IMAGE_NAME[doc] = "The base name of the kernel image."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    The base name of the kernel image.
+                    This variable is set in the
+                    <filename>meta/classes/kernel-artifact-names.bbclass</filename>
+                    file as follows:
+                    <literallayout class='monospaced'>
+     KERNEL_IMAGE_NAME ?= "${KERNEL_ARTIFACT_NAME}"
+                    </literallayout>
+                    The value of the
+                    <link linkend='var-KERNEL_ARTIFACT_NAME'><filename>KERNEL_ARTIFACT_NAME</filename></link>
+                    variable, which is set in the same file, has the following
+                    value:
+                    <literallayout class='monospaced'>
+     KERNEL_ARTIFACT_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}${IMAGE_VERSION_SUFFIX}"
+                    </literallayout>
+                </para>
+            </glossdef>
+        </glossentry>
+
         <glossentry id='var-KERNEL_IMAGETYPE'><glossterm>KERNEL_IMAGETYPE</glossterm>
             <info>
                 KERNEL_IMAGETYPE[doc] = "The type of kernel to build for a device, usually set by the machine configuration files and defaults to 'zImage'."
@@ -8902,35 +9220,6 @@
             </glossdef>
         </glossentry>
 
-        <glossentry id='var-MODULE_IMAGE_BASE_NAME'><glossterm>MODULE_IMAGE_BASE_NAME</glossterm>
-            <info>
-                MODULE_IMAGE_BASE_NAME[doc] = "The base name of the kernel modules tarball."
-            </info>
-            <glossdef>
-                <para role="glossdeffirst">
-<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
-                    The base name of the kernel modules tarball.
-                    This variable is set in the
-                    <link linkend='ref-classes-kernel'>kernel</link> class
-                    as follows:
-                    <literallayout class='monospaced'>
-     MODULE_IMAGE_BASE_NAME ?= "modules-${PKGE}-${PKGV}-${PKGR}-${MACHINE}-${DATETIME}"
-                    </literallayout>
-                </para>
-
-                <para>
-                    See the
-                    <link linkend='var-PKGE'><filename>PKGE</filename></link>,
-                    <link linkend='var-PKGV'><filename>PKGV</filename></link>,
-                    <link linkend='var-PKGR'><filename>PKGR</filename></link>,
-                    <link linkend='var-MACHINE'><filename>MACHINE</filename></link>,
-                    and
-                    <link linkend='var-DATETIME'><filename>DATETIME</filename></link>
-                    variables for additional information.
-                </para>
-            </glossdef>
-        </glossentry>
-
         <glossentry id='var-MODULE_TARBALL_DEPLOY'><glossterm>MODULE_TARBALL_DEPLOY</glossterm>
             <info>
                 MODULE_TARBALL_DEPLOY[doc] = "Controls creation of the modules-*.tgz file. Set this variable to "0" to disable creation of this file, which contains all of the kernel modules resulting from a kernel build."
@@ -8947,6 +9236,61 @@
             </glossdef>
         </glossentry>
 
+        <glossentry id='var-MODULE_TARBALL_LINK_NAME'><glossterm>MODULE_TARBALL_LINK_NAME</glossterm>
+            <info>
+                MODULE_TARBALL_LINK_NAME[doc] = "The link name of the kernel module tarball."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    The link name of the kernel module tarball.
+                    This variable is set in the
+                    <filename>meta/classes/kernel-artifact-names.bbclass</filename>
+                    file as follows:
+                    <literallayout class='monospaced'>
+     MODULE_TARBALL_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}"
+                    </literallayout>
+                    The value of the <filename>KERNEL_ARTIFACT_LINK_NAME</filename>
+                    variable, which is set in the same file, has the following
+                    value:
+                    <literallayout class='monospaced'>
+     KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}"
+                    </literallayout>
+                </para>
+
+                <para>
+                    See the
+                    <link linkend='var-MACHINE'><filename>MACHINE</filename></link>
+                    variable for additional information.
+                </para>
+            </glossdef>
+        </glossentry>
+
+        <glossentry id='var-MODULE_TARBALL_NAME'><glossterm>MODULE_TARBALL_NAME</glossterm>
+            <info>
+                MODULE_TARBALL_NAME[doc] = "The base name of the kernel module tarball."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    The base name of the kernel module tarball.
+                    This variable is set in the
+                    <filename>meta/classes/kernel-artifact-names.bbclass</filename>
+                    file as follows:
+                    <literallayout class='monospaced'>
+     MODULE_TARBALL_NAME ?= "${KERNEL_ARTIFACT_NAME}"
+                    </literallayout>
+                    The value of the
+                    <link linkend='var-KERNEL_ARTIFACT_NAME'><filename>KERNEL_ARTIFACT_NAME</filename></link>
+                    variable, which is set in the same file, has the following
+                    value:
+                    <literallayout class='monospaced'>
+     KERNEL_ARTIFACT_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}${IMAGE_VERSION_SUFFIX}"
+                    </literallayout>
+                </para>
+            </glossdef>
+        </glossentry>
+
 <!--
         <glossentry id='var-MULTIMACH_HOST_SYS'><glossterm>MULTIMACH_HOST_SYS</glossterm>
             <info>
@@ -9058,6 +9402,40 @@
             </glossdef>
         </glossentry>
 
+        <glossentry id='var-NO_GENERIC_LICENSE'><glossterm>NO_GENERIC_LICENSE</glossterm>
+            <info>
+                NO_GENERIC_LICENSE[doc] = "Used to allow copying a license that does not exist in common licenses."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    Avoids QA errors when you use a non-common, non-CLOSED
+                    license in a recipe.
+                    Packages exist, such as the linux-firmware package, with
+                    many licenses that are not in any way common.
+                    Also, new licenses are added occasionally to avoid
+                    introducing a lot of common license files, which are only
+                    applicable to a specific package.
+                    <filename>NO_GENERIC_LICENSE</filename> is used to allow
+                    copying a license that does not exist in common licenses.
+                </para>
+
+                <para>
+                    The following example shows how to add
+                    <filename>NO_GENERIC_LICENSE</filename> to a recipe:
+                    <literallayout class='monospaced'>
+     NO_GENERIC_LICENSE[<replaceable>license_name</replaceable>] = "<replaceable>license_file_in_fetched_source</replaceable>"
+                    </literallayout>
+                    The following is an example that uses the
+                    <filename>LICENSE.Abilis.txt</filename> file as the license
+                    from the fetched source:
+                    <literallayout class='monospaced'>
+     NO_GENERIC_LICENSE[Firmware-Abilis] = "LICENSE.Abilis.txt"
+                    </literallayout>
+                </para>
+            </glossdef>
+        </glossentry>
+
         <glossentry id='var-NO_RECOMMENDATIONS'><glossterm>NO_RECOMMENDATIONS</glossterm>
             <info>
                 NO_RECOMMENDATIONS[doc] = "When set to '1', no recommended packages will be installed. Some recommended packages might be required for certain system functionality, such as kernel-modules. It is up to the user to add packages to IMAGE_INSTALL as needed."
@@ -9141,44 +9519,6 @@
                 </para>
             </glossdef>
         </glossentry>
-
-        <glossentry id='var-NOHDD'><glossterm>NOHDD</glossterm>
-            <info>
-                NOHDD[doc] = "Causes the OpenEmbedded build system to skip building the .hddimg image."
-            </info>
-            <glossdef>
-                <para role="glossdeffirst">
-<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
-                    Causes the OpenEmbedded build system to skip building the
-                    <filename>.hddimg</filename> image.
-                    The <filename>NOHDD</filename> variable is used with the
-                    <link linkend='ref-classes-image-live'><filename>image-live</filename></link>
-                    class.
-                    Set the variable to "1" to prevent the
-                    <filename>.hddimg</filename> image from being built.
-                </para>
-            </glossdef>
-        </glossentry>
-
-        <glossentry id='var-NOISO'><glossterm>NOISO</glossterm>
-            <info>
-                NOISO[doc] = "Causes the OpenEmbedded build system to skip building the ISO image."
-            </info>
-            <glossdef>
-                <para role="glossdeffirst">
-<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
-                    Causes the OpenEmbedded build system to skip building the
-                    ISO image.
-                    The <filename>NOISO</filename> variable is used with the
-                    <link linkend='ref-classes-image-live'><filename>image-live</filename></link>
-                    class.
-                    Set the variable to "1" to prevent the ISO image from
-                    being built.
-                    To enable building an ISO image, set the variable to "0".
-                </para>
-            </glossdef>
-        </glossentry>
-
     </glossdiv>
 
     <glossdiv id='var-glossary-o'><title>O</title>
@@ -9612,6 +9952,12 @@
                             ".debug" previously described with the exception
                             that no source files are installed.
                             </para></listitem>.
+                        <listitem><para>
+                            "debug-with-srcpkg": The same behavior as
+                            ".debug" previously described with the exception
+                            that all source files are placed in a separate
+                            <filename>*-src</filename> pkg.
+                            </para></listitem>
                     </itemizedlist>
                 </para>
 
@@ -9991,9 +10337,9 @@
                     Here is the basic block structure:
                     <literallayout class='monospaced'>
      PACKAGECONFIG ??= "f1 f2 f3 ..."
-     PACKAGECONFIG[f1] = "--with-f1,--without-f1,build-deps-f1,rt-deps-f1"
-     PACKAGECONFIG[f2] = "--with-f2,--without-f2,build-deps-f2,rt-deps-f2"
-     PACKAGECONFIG[f3] = "--with-f3,--without-f3,build-deps-f3,rt-deps-f3"
+     PACKAGECONFIG[f1] = "--with-f1,--without-f1,build-deps-f1,rt-deps-f1,rt-recs-f1"
+     PACKAGECONFIG[f2] = "--with-f2,--without-f2,build-deps-f2,rt-deps-f2,rt-recs-f2"
+     PACKAGECONFIG[f3] = "--with-f3,--without-f3,build-deps-f3,rt-deps-f3,rt-recs-f3"
                     </literallayout>
                 </para>
 
@@ -10002,7 +10348,7 @@
                     variable itself specifies a space-separated list of the
                     features to enable.
                     Following the features, you can determine the behavior of
-                    each feature by providing up to four order-dependent
+                    each feature by providing up to five order-dependent
                     arguments, which are separated by commas.
                     You can omit any argument you like but must retain the
                     separating commas.
@@ -10028,6 +10374,10 @@
                             (<link linkend='var-RDEPENDS'><filename>RDEPENDS</filename></link>)
                             that should be added if the feature is enabled.
                             </para></listitem>
+                        <listitem><para>Additional runtime recommendations
+                            (<link linkend='var-RRECOMMENDS'><filename>RRECOMMENDS</filename></link>)
+                            that should be added if the feature is enabled.
+                            </para></listitem>
                     </orderedlist>
                 </para>
 
@@ -10076,7 +10426,7 @@
                             <filename>PACKAGECONFIG</filename>.
                             You can either completely override the variable:
                             <literallayout class='monospaced'>
-     PACKAGECONFIG="f4 f5"
+      PACKAGECONFIG = "f4 f5"
                             </literallayout>
                             Or, you can just append the variable:
                             <literallayout class='monospaced'>
@@ -10090,7 +10440,7 @@
                             As with append files previously described,
                             you can either completely override the variable:
                             <literallayout class='monospaced'>
-     PACKAGECONFIG_pn-<replaceable>recipename</replaceable>="f4 f5"
+     PACKAGECONFIG_pn-<replaceable>recipename</replaceable> = "f4 f5"
                             </literallayout>
                             Or, you can just amend the variable:
                             <literallayout class='monospaced'>
@@ -10708,17 +11058,16 @@
                     to build.
                     This variable works in conjunction with the
                     <link linkend='ref-classes-blacklist'><filename>blacklist</filename></link>
-                    class, which the recipe must inherit globally.
+                    class, which is inherited globally.
                 </para>
 
                 <para>
-                    To prevent a recipe from being built, inherit the class
-                    globally and use the variable in your
+                    To prevent a recipe from being built, use the
+                    <filename>PNBLACKLIST</filename> variable in your
                     <filename>local.conf</filename> file.
                     Here is an example that prevents
                     <filename>myrecipe</filename> from being built:
                     <literallayout class='monospaced'>
-     INHERIT += "blacklist"
      PNBLACKLIST[myrecipe] = "Not supported by our organization."
                     </literallayout>
                 </para>
@@ -10896,47 +11245,63 @@
             <glossdef>
                 <para role="glossdeffirst">
 <!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
-                    If there are multiple versions of recipes available, this
-                    variable determines which recipe should be given preference.
+                    If multiple versions of recipes exist, this
+                    variable determines which version is given preference.
                     You must always suffix the variable with the
                     <link linkend='var-PN'><filename>PN</filename></link>
                     you want to select, and you should set the
                     <link linkend='var-PV'><filename>PV</filename></link>
                     accordingly for precedence.
-                    You can use the "<filename>%</filename>" character as a
-                    wildcard to match any number of characters, which can be
-                    useful when specifying versions that contain long revision
-                    numbers that could potentially change.
+                </para>
+
+                <para>
+                    The <filename>PREFERRED_VERSION</filename> variable
+                    supports limited wildcard use through the
+                    "<filename>%</filename>" character.
+                    You can use the character to match any number of
+                    characters, which can be useful when specifying versions
+                    that contain long revision numbers that potentially change.
                     Here are two examples:
                     <literallayout class='monospaced'>
      PREFERRED_VERSION_python = "3.4.0"
      PREFERRED_VERSION_linux-yocto = "4.12%"
                     </literallayout>
-                    <note>
-                        The specified version is matched against
-                        <link linkend='var-PV'><filename>PV</filename></link>,
-                        which does not necessarily match the version part of
-                        the recipe's filename.
-                        For example, consider two recipes
-                        <filename>foo_1.2.bb</filename> and
-                        <filename>foo_git.bb</filename> where
-                        <filename>foo_git.bb</filename> contains the following
-                        assignment:
-                        <literallayout class='monospaced'>
-     PV = "1.1+git${SRCPV}"
-                        </literallayout>
-                        In this case, the correct way to select
-                        <filename>foo_git.bb</filename> is by using an
-                        assignment such as the following:
-                        <literallayout class='monospaced'>
-     PREFERRED_VERSION_foo = "1.1+git%"
-                        </literallayout>
-                        Compare that previous example against the following
-                        incorrect example, which does not work:
-                        <literallayout class='monospaced'>
-     PREFERRED_VERSION_foo = "git"
-                        </literallayout>
+                    <note><title>Important</title>
+                        The use of the "<filename>%</filename>" character
+                        is limited in that it only works at the end of the
+                        string.
+                        You cannot use the wildcard character in any other
+                        location of the string.
                     </note>
+                </para>
+
+                <para>
+                    The specified version is matched against
+                    <link linkend='var-PV'><filename>PV</filename></link>,
+                    which does not necessarily match the version part of
+                    the recipe's filename.
+                    For example, consider two recipes
+                    <filename>foo_1.2.bb</filename> and
+                    <filename>foo_git.bb</filename> where
+                    <filename>foo_git.bb</filename> contains the following
+                    assignment:
+                    <literallayout class='monospaced'>
+     PV = "1.1+git${SRCPV}"
+                    </literallayout>
+                    In this case, the correct way to select
+                    <filename>foo_git.bb</filename> is by using an
+                    assignment such as the following:
+                    <literallayout class='monospaced'>
+     PREFERRED_VERSION_foo = "1.1+git%"
+                    </literallayout>
+                    Compare that previous example against the following
+                    incorrect example, which does not work:
+                    <literallayout class='monospaced'>
+     PREFERRED_VERSION_foo = "git"
+                    </literallayout>
+                </para>
+
+                <para>
                     Sometimes the <filename>PREFERRED_VERSION</filename>
                     variable can be set by configuration files in a way that
                     is hard to change.
@@ -12566,22 +12931,33 @@
 
         <glossentry id='var-SDK_TITLE'><glossterm>SDK_TITLE</glossterm>
             <info>
-                SDK_TITLE[doc] = "Specifies a title to be printed when running the SDK installer."
+                SDK_TITLE[doc] = "The title to be printed when running the SDK installer."
             </info>
             <glossdef>
                 <para role="glossdeffirst">
 <!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
-                    Specifies a title to be printed when running the SDK
-                    installer.
-                    The <filename>SDK_TITLE</filename> variable defaults to
-                    "<replaceable>distro</replaceable> SDK" for the standard
-                    SDK and "<replaceable>distro</replaceable> Extensible SDK"
-                    for the extensible SDK, where
-                    <replaceable>distro</replaceable> is the first one of
+                    The title to be printed when running the SDK installer.
+                    By default, this title is based on the
                     <link linkend='var-DISTRO_NAME'><filename>DISTRO_NAME</filename></link>
                     or
                     <link linkend='var-DISTRO'><filename>DISTRO</filename></link>
-                    that is set in your configuration.
+                    variable and is set in the
+                    <link linkend='ref-classes-populate-sdk-*'><filename>populate_sdk_base</filename></link>
+                    class as follows:
+                    <literallayout class='monospaced'>
+     SDK_TITLE ??= "${@d.getVar('DISTRO_NAME') or d.getVar('DISTRO')} SDK"
+                    </literallayout>
+                    For the default distribution "poky",
+                    <filename>SDK_TITLE</filename> is set to
+                    "Poky (Yocto Project Reference Distro)".
+                </para>
+
+                <para>
+                    For information on how to change this default title,
+                    see the
+                    "<ulink url='&YOCTO_DOCS_SDK_URL;#sdk-changing-the-sdk-installer-title'>Changing the Extensible SDK Installer Title</ulink>"
+                    section in the Yocto Project Application Development and
+                    the Extensible Software Development Kit (eSDK) manual.
                 </para>
             </glossdef>
         </glossentry>
@@ -12640,6 +13016,36 @@
             </glossdef>
         </glossentry>
 
+        <glossentry id='var-SDKEXTPATH'><glossterm>SDKEXTPATH</glossterm>
+            <info>
+                SDKEXTPATH[doc] = "The default installation directory for the extensible SDK."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    The default installation directory for the Extensible SDK.
+                    By default, this directory is based on the
+                    <link linkend='var-DISTRO'><filename>DISTRO</filename></link>
+                    variable and is set in the
+                    <link linkend='ref-classes-populate-sdk-*'><filename>populate_sdk_base</filename></link>
+                    class as follows:
+                    <literallayout class='monospaced'>
+     SDKEXTPATH ??= "~/${@d.getVar('DISTRO')}_sdk"
+                    </literallayout>
+                    For the default distribution "poky", the
+                    <filename>SDKEXTPATH</filename> is set to "poky_sdk".
+                </para>
+
+                <para>
+                    For information on how to change this default directory,
+                    see the
+                    "<ulink url='&YOCTO_DOCS_SDK_URL;#sdk-changing-the-default-sdk-installation-directory'>Changing the Default SDK Installation Directory</ulink>"
+                    section in the Yocto Project Application Development and
+                    the Extensible Software Development Kit (eSDK) manual.
+                </para>
+            </glossdef>
+        </glossentry>
+
         <glossentry id='var-SDKIMAGE_FEATURES'><glossterm>SDKIMAGE_FEATURES</glossterm>
             <info>
                 SDKIMAGE_FEATURES[doc] = "Equivalent to IMAGE_FEATURES. However, this variable applies to the SDK generated from an image using the command 'bitbake -c populate_sdk imagename'."
@@ -13506,7 +13912,7 @@
                     <link linkend='var-MIRRORS'><filename>MIRRORS</filename></link>
                     and <link linkend='var-PREMIRRORS'><filename>PREMIRRORS</filename></link>
                     and points to the cache locations to check for the shared
-                    objects.
+                    state (sstate) objects.
                 </para>
 
                 <para>
@@ -13519,6 +13925,25 @@
                 </para>
 
                 <para>
+                    When pointing to sstate build artifacts on another machine
+                    that uses a different GCC version for native builds,
+                    you must configure <filename>SSTATE_MIRROR</filename>
+                    with a regular expression that maps local search paths
+                    to server paths.
+                    The paths need to take into account
+                    <link linkend='var-NATIVELSBSTRING'><filename>NATIVELSBSTRING</filename></link>
+                    set by the
+                    <link linkend='ref-classes-uninative'><filename>uninative</filename></link>
+                    class.
+                    For example, the following maps the local search path
+                    <filename>universal-4.9</filename> to the server-provided
+                    path <replaceable>server_url_sstate_path</replaceable>:
+                    <literallayout class='monospaced'>
+     SSTATE_MIRRORS ?= file://universal-4.9/(.*) http://<replaceable>server_url_sstate_path</replaceable>/universal-4.8/\1 \n
+                    </literallayout>
+                </para>
+
+                <para>
                     If a mirror uses the same structure as
                     <link linkend='var-SSTATE_DIR'><filename>SSTATE_DIR</filename></link>,
                     you need to add
@@ -14860,6 +15285,26 @@
             </glossdef>
         </glossentry>
 
+        <glossentry id='var-TCLIBC'><glossterm>TCLIBC</glossterm>
+            <info>
+                TCLIBC[doc] = "Specifies GNU standard C library (libc) variant to use during the build process. You can select 'glibc', 'musl' or "newlib."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    Specifies the GNU standard C library
+                    (<filename>libc</filename>) variant to use during the
+                    build process.
+                    This variable replaces <filename>POKYLIBC</filename>,
+                    which is no longer supported.
+                </para>
+
+                <para>
+                    You can select "glibc", "musl", "newlib", or "baremetal"
+                </para>
+            </glossdef>
+        </glossentry>
+
         <glossentry id='var-TCLIBCAPPEND'><glossterm>TCLIBCAPPEND</glossterm>
             <info>
                 TCLIBCAPPEND[doc] = "Specifies a suffix appended to TMPDIR that identifies the libc variant for the build."
@@ -14891,25 +15336,6 @@
             </glossdef>
         </glossentry>
 
-        <glossentry id='var-TCLIBC'><glossterm>TCLIBC</glossterm>
-            <info>
-                TCLIBC[doc] = "Specifies GNU standard C library (libc) variant to use during the build process. You can select 'glibc' or 'musl'."
-            </info>
-            <glossdef>
-                <para role="glossdeffirst">
-<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
-                    Specifies the GNU standard C library (<filename>libc</filename>)
-                    variant to use during the build process.
-                    This variable replaces <filename>POKYLIBC</filename>, which is no longer
-                    supported.
-                </para>
-
-                <para>
-                    You can select "glibc" or "musl".
-                </para>
-            </glossdef>
-        </glossentry>
-
         <glossentry id='var-TCMODE'><glossterm>TCMODE</glossterm>
             <info>
                 TCMODE[doc] = "Enables an external toolchain (where provided by an additional layer) if set to a value other than 'default'."
@@ -15017,41 +15443,6 @@
             </glossdef>
         </glossentry>
 
-        <glossentry id='var-TEST_IMAGE'><glossterm>TEST_IMAGE</glossterm>
-            <info>
-                TEST_IMAGE[doc] = "Enables test booting of virtual machine images under the QEMU emulator after any root filesystems are created and runs tests against those images."
-            </info>
-            <glossdef>
-                <para role="glossdeffirst">
-<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
-                    Automatically runs the series of automated tests for
-                    images when an image is successfully built.
-                </para>
-
-                <para>
-                    These tests are written in Python making use of the
-                    <filename>unittest</filename> module, and the majority of
-                    them run commands on the target system over
-                    <filename>ssh</filename>.
-                    You can set this variable to "1" in your
-                    <filename>local.conf</filename> file in the
-                    <link linkend='build-directory'>Build Directory</link>
-                    to have the OpenEmbedded build system automatically run
-                    these tests after an image successfully builds:
-                    <literallayout class='monospaced'>
-     TEST_IMAGE = "1"
-                    </literallayout>
-                    For more information on enabling, running, and writing
-                    these tests, see the
-                    "<ulink url='&YOCTO_DOCS_DEV_URL;#performing-automated-runtime-testing'>Performing Automated Runtime Testing</ulink>"
-                    section in the Yocto Project Development Tasks Manual and
-                    the
-                    "<link linkend='ref-classes-testimage*'><filename>testimage*.bbclass</filename></link>"
-                    section.
-                </para>
-            </glossdef>
-        </glossentry>
-
         <glossentry id='var-TEST_LOG_DIR'><glossterm>TEST_LOG_DIR</glossterm>
             <info>
                 TEST_LOG_DIR[doc] = "Holds the SSH log and the boot log for QEMU machines. The TEST_LOG_DIR variable defaults to "${WORKDIR}/testimage"."
@@ -15211,9 +15602,9 @@
 <!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
                     Specifies the target controller to use when running tests
                     against a test image.
-                    The default controller to use is "qemu":
+                    The default controller to use is "QemuTarget":
                     <literallayout class='monospaced'>
-     TEST_TARGET = "qemu"
+     TEST_TARGET = "QemuTarget"
                     </literallayout>
                 </para>
 
@@ -15232,35 +15623,24 @@
                     You can provide the following arguments with
                     <filename>TEST_TARGET</filename>:
                     <itemizedlist>
-                        <listitem><para><emphasis>"qemu" and "QemuTarget":</emphasis>
+                        <listitem><para><emphasis>"QemuTarget":</emphasis>
                             Boots a QEMU image and runs the tests.
                             See the
                             "<ulink url='&YOCTO_DOCS_DEV_URL;#qemu-image-enabling-tests'>Enabling Runtime Tests on QEMU</ulink>"
                             section in the Yocto Project Development Tasks
                             Manual for more information.
                             </para></listitem>
-                        <listitem><para><emphasis>"simpleremote" and "SimpleRemoteTarget":</emphasis>
+                        <listitem><para><emphasis>"SimpleRemoteTarget":</emphasis>
                             Runs the tests on target hardware that is already
                             up and running.
                             The hardware can be on the network or it can be
                             a device running an image on QEMU.
                             You must also set
                             <link linkend='var-TEST_TARGET_IP'><filename>TEST_TARGET_IP</filename></link>
-                            when you use "simpleremote" or "SimpleRemoteTarget".
+                            when you use "SimpleRemoteTarget".
                             <note>
                                 This argument is defined in
-                                <filename>meta/lib/oeqa/targetcontrol.py</filename>.
-                                The small caps names are kept for compatibility
-                                reasons.
-                            </note>
-                            </para></listitem>
-                        <listitem><para><emphasis>"GummibootTarget":</emphasis>
-                            Automatically deploys and runs tests on an
-                            EFI-enabled machine that has a master image
-                            installed.
-                            <note>
-                                This argument is defined in
-                                <filename>meta/lib/oeqa/controllers/masterimage.py</filename>.
+                                <filename>meta/lib/oeqa/controllers/simpleremote.py</filename>.
                             </note>
                             </para></listitem>
                     </itemizedlist>
@@ -15363,6 +15743,47 @@
             </glossdef>
         </glossentry>
 
+        <glossentry id='var-TESTIMAGE_AUTO'><glossterm>TESTIMAGE_AUTO</glossterm>
+            <info>
+                TESTIMAGE_AUTO[doc] = "Enables automatic testing of an image once it is built."
+            </info>
+            <glossdef>
+                <para role="glossdeffirst">
+<!--                <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+                    Automatically runs the series of automated tests for
+                    images when an image is successfully built.
+                    Setting <filename>TESTIMAGE_AUTO</filename> to "1"
+                    causes any image that successfully builds to automatically
+                    boot under QEMU.
+                    Using the variable also adds in dependencies so that any
+                    SDK for which testing is requested is automatically built
+                    first.
+                </para>
+
+                <para>
+                    These tests are written in Python making use of the
+                    <filename>unittest</filename> module, and the majority of
+                    them run commands on the target system over
+                    <filename>ssh</filename>.
+                    You can set this variable to "1" in your
+                    <filename>local.conf</filename> file in the
+                    <link linkend='build-directory'>Build Directory</link>
+                    to have the OpenEmbedded build system automatically run
+                    these tests after an image successfully builds:
+                    <literallayout class='monospaced'>
+     TESTIMAGE_AUTO = "1"
+                    </literallayout>
+                    For more information on enabling, running, and writing
+                    these tests, see the
+                    "<ulink url='&YOCTO_DOCS_DEV_URL;#performing-automated-runtime-testing'>Performing Automated Runtime Testing</ulink>"
+                    section in the Yocto Project Development Tasks Manual and
+                    the
+                    "<link linkend='ref-classes-testimage*'><filename>testimage*.bbclass</filename></link>"
+                    section.
+                </para>
+            </glossdef>
+        </glossentry>
+
         <glossentry id='var-THISDIR'><glossterm>THISDIR</glossterm>
             <info>
                 THISDIR[doc] = "The directory in which the file BitBake is currently parsing is located."
diff --git a/poky/documentation/sdk-manual/sdk-appendix-customizing.xml b/poky/documentation/sdk-manual/sdk-appendix-customizing.xml
index c3215e6..7454c90 100644
--- a/poky/documentation/sdk-manual/sdk-appendix-customizing.xml
+++ b/poky/documentation/sdk-manual/sdk-appendix-customizing.xml
@@ -7,7 +7,7 @@
 <title>Customizing the Extensible SDK</title>
 
 <para>
-    This appendix presents customizations you can apply to the extensible SDK.
+    This appendix describes customizations you can apply to the extensible SDK.
 </para>
 
 <section id='sdk-configuring-the-extensible-sdk'>
@@ -186,7 +186,13 @@
         You can change the displayed title for the SDK installer by setting
         the
         <ulink url='&YOCTO_DOCS_REF_URL;#var-SDK_TITLE'><filename>SDK_TITLE</filename></ulink>
-        variable.
+        variable and then rebuilding the the SDK installer.
+        For information on how to build an SDK installer, see the
+        "<link linkend='sdk-building-an-sdk-installer'>Building an SDK Installer</link>"
+        section.
+    </para>
+
+    <para>
         By default, this title is derived from
         <ulink url='&YOCTO_DOCS_REF_URL;#var-DISTRO_NAME'><filename>DISTRO_NAME</filename></ulink>
         when it is set.
@@ -198,11 +204,28 @@
 
     <para>
         The
-        <ulink url='&YOCTO_DOCS_REF_URL;#ref-classes-populate-sdk-*'><filename>populate_sdk_ext</filename></ulink>
+        <ulink url='&YOCTO_DOCS_REF_URL;#ref-classes-populate-sdk-*'><filename>populate_sdk_base</filename></ulink>
         class defines the default value of the <filename>SDK_TITLE</filename>
         variable as follows:
         <literallayout class='monospaced'>
-     SDK_TITLE_task-populate-sdk-ext = "${@d.getVar('DISTRO_NAME') or d.getVar('DISTRO')} Extensible SDK"
+     SDK_TITLE ??= "${@d.getVar('DISTRO_NAME') or d.getVar('DISTRO')} SDK"
+        </literallayout>
+    </para>
+
+    <para>
+        While several ways exist to change this variable, an efficient method
+        is to set the variable in your distribution's configuration file.
+        Doing so creates an SDK installer title that applies across your
+        distribution.
+        As an example, assume you have your own layer for your distribution
+        named "meta-mydistro" and you are using the same type of file
+        hierarchy as does the default "poky" distribution.
+        If so, you could update the <filename>SDK_TITLE</filename> variable
+        in the
+        <filename>~/meta-mydistro/conf/distro/mydistro.conf</filename> file
+        using the following form:
+        <literallayout class='monospaced'>
+     SDK_TITLE = "<replaceable>your_title</replaceable>"
         </literallayout>
     </para>
 </section>
@@ -265,6 +288,51 @@
     </para>
 </section>
 
+<section id='sdk-changing-the-default-sdk-installation-directory'>
+    <title>Changing the Default SDK Installation Directory</title>
+
+    <para>
+        When you build the installer for the Extensible SDK, the default
+        installation directory for the SDK is based on the
+        <ulink url='&YOCTO_DOCS_REF_URL;#var-DISTRO'><filename>DISTRO</filename></ulink>
+        and
+        <ulink url='&YOCTO_DOCS_REF_URL;#var-SDKEXTPATH'><filename>SDKEXTPATH</filename></ulink>
+        variables from within the
+        <ulink url='&YOCTO_DOCS_REF_URL;#ref-classes-populate-sdk-*'><filename>populate_sdk_base</filename></ulink>
+        class as follows:
+        <literallayout class='monospaced'>
+     SDKEXTPATH ??= "~/${@d.getVar('DISTRO')}_sdk"
+        </literallayout>
+        You can change this default installation directory by specifically
+        setting the <filename>SDKEXTPATH</filename> variable.
+    </para>
+
+    <para>
+        While a number of ways exist through which you can set this variable,
+        the method that makes the most sense is to set the variable in your
+        distribution's configuration file.
+        Doing so creates an SDK installer default directory that applies
+        across your distribution.
+        As an example, assume you have your own layer for your distribution
+        named "meta-mydistro" and you are using the same type of file
+        hierarchy as does the default "poky" distribution.
+        If so, you could update the <filename>SDKEXTPATH</filename> variable
+        in the
+        <filename>~/meta-mydistro/conf/distro/mydistro.conf</filename> file
+        using the following form:
+        <literallayout class='monospaced'>
+     SDKEXTPATH = "<replaceable>some_path_for_your_installed_sdk</replaceable>"
+        </literallayout>
+    </para>
+
+    <para>
+        After building your installer, running it prompts the user for
+        acceptance of the
+        <replaceable>some_path_for_your_installed_sdk</replaceable> directory
+        as the default location to install the Extensible SDK.
+    </para>
+</section>
+
 <section id='sdk-providing-additional-installable-extensible-sdk-content'>
     <title>Providing Additional Installable Extensible SDK Content</title>
 
diff --git a/poky/documentation/sdk-manual/sdk-appendix-obtain.xml b/poky/documentation/sdk-manual/sdk-appendix-obtain.xml
index c608e6f..2cadcc1 100644
--- a/poky/documentation/sdk-manual/sdk-appendix-obtain.xml
+++ b/poky/documentation/sdk-manual/sdk-appendix-obtain.xml
@@ -106,7 +106,7 @@
                 <emphasis>Set Up the Build Environment:</emphasis>
                 Be sure you are set up to use BitBake in a shell.
                 See the
-                "<ulink url='&YOCTO_DOCS_DEV_URL;#setting-up-the-development-host-to-use-the-yocto-project'>Preparing the Build Host</ulink>"
+                "<ulink url='&YOCTO_DOCS_DEV_URL;#dev-preparing-the-build-host'>Preparing the Build Host</ulink>"
                 section in the Yocto Project Development Tasks Manual for
                 information on how to get a build host ready that is either a
                 native Linux machine or a machine that uses CROPS.
diff --git a/poky/documentation/sdk-manual/sdk-eclipse-project.xml b/poky/documentation/sdk-manual/sdk-eclipse-project.xml
index f8a586f..15a9ae7 100644
--- a/poky/documentation/sdk-manual/sdk-eclipse-project.xml
+++ b/poky/documentation/sdk-manual/sdk-eclipse-project.xml
@@ -57,12 +57,12 @@
                     <ulink url='&YOCTO_DOCS_REF_URL;#hardware-build-system-term'>build host</ulink>
                     can use the Yocto Project.
                     See the
-                    "<ulink url='&YOCTO_DOCS_DEV_URL;#setting-up-the-development-host-to-use-the-yocto-project'>Preparing a Build Host</ulink>"
+                    "<ulink url='&YOCTO_DOCS_DEV_URL;#dev-preparing-the-build-host'>Preparing the Build Host</ulink>"
                     section in the Yocto Project Development Tasks Manual for
                     information on how to set up your build host.
                     <note>
                         Be sure you install the "xterm" package, which is a
-                        <ulink url='&YOCTO_DOCS_REF_URL;#required-packages-for-the-host-development-system'>graphical and Eclipse plug-in extra</ulink>
+                        <ulink url='&YOCTO_DOCS_REF_URL;#required-packages-for-the-build-host'>graphical and Eclipse plug-in extra</ulink>
                         needed by Eclipse.
                     </note>
                     </para></listitem>
diff --git a/poky/documentation/sdk-manual/sdk-manual.xml b/poky/documentation/sdk-manual/sdk-manual.xml
index 2dabdb7..7f93d5f 100644
--- a/poky/documentation/sdk-manual/sdk-manual.xml
+++ b/poky/documentation/sdk-manual/sdk-manual.xml
@@ -57,14 +57,14 @@
                 <revremark>Released with the Yocto Project 2.5 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.1</revnumber>
-                <date>September 2018</date>
-                <revremark>The initial document released with the Yocto Project 2.5.1 Release.</revremark>
+                <revnumber>2.6</revnumber>
+                <date>November 2018</date>
+                <revremark>Released with the Yocto Project 2.6 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.2</revnumber>
+                <revnumber>2.6.1</revnumber>
                 <date>&REL_MONTH_YEAR;</date>
-                <revremark>The initial document released with the Yocto Project 2.5.2 Release.</revremark>
+                <revremark>Released with the Yocto Project 2.6.1 Release.</revremark>
             </revision>
        </revhistory>
 
diff --git a/poky/documentation/toaster-manual/toaster-manual-start.xml b/poky/documentation/toaster-manual/toaster-manual-start.xml
index 45f6046..fc187ec 100644
--- a/poky/documentation/toaster-manual/toaster-manual-start.xml
+++ b/poky/documentation/toaster-manual/toaster-manual-start.xml
@@ -18,7 +18,7 @@
             Before you can use Toaster, you need to first set up your
             build system to run the Yocto Project.
             To do this, follow the instructions in the
-            "<ulink url='&YOCTO_DOCS_DEV_URL;#setting-up-the-development-host-to-use-the-yocto-project'>Preparing the Build Host</ulink>"
+            "<ulink url='&YOCTO_DOCS_DEV_URL;#dev-preparing-the-build-host'>Preparing the Build Host</ulink>"
             section of the Yocto Project Development Tasks
             Manual.
  	    For Ubuntu/Debian, you might also need to do an additional install
diff --git a/poky/documentation/toaster-manual/toaster-manual.xml b/poky/documentation/toaster-manual/toaster-manual.xml
index 8e25e43..dcc2990 100644
--- a/poky/documentation/toaster-manual/toaster-manual.xml
+++ b/poky/documentation/toaster-manual/toaster-manual.xml
@@ -67,14 +67,14 @@
                 <revremark>Released with the Yocto Project 2.5 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.1</revnumber>
-                <date>September 2018</date>
-                <revremark>The initial document released with the Yocto Project 2.5.1 Release.</revremark>
+                <revnumber>2.6</revnumber>
+                <date>November 2018</date>
+                <revremark>Released with the Yocto Project 2.6 Release.</revremark>
             </revision>
             <revision>
-                <revnumber>2.5.2</revnumber>
+                <revnumber>2.6.1</revnumber>
                 <date>&REL_MONTH_YEAR;</date>
-                <revremark>The initial document released with the Yocto Project 2.5.2 Release.</revremark>
+                <revremark>Released with the Yocto Project 2.6.1 Release.</revremark>
             </revision>
        </revhistory>
 
diff --git a/poky/documentation/tools/mega-manual.sed b/poky/documentation/tools/mega-manual.sed
index b174fad..f6e205f 100644
--- a/poky/documentation/tools/mega-manual.sed
+++ b/poky/documentation/tools/mega-manual.sed
@@ -2,39 +2,39 @@
 # This style is for manual folders like "yocto-project-qs" and "poky-ref-manual".
 # This is the old way that did it.  Can't do that now that we have "bitbake-user-manual" strings
 # in the mega-manual.
-# s@"ulink" href="http://www.yoctoproject.org/docs/2.5.2/[a-z]*-[a-z]*-[a-z]*/[a-z]*-[a-z]*-[a-z]*.html#@"link" href="#@g
-s@"ulink" href="http://www.yoctoproject.org/docs/2.5.2/yocto-project-qs/yocto-project-qs.html#@"link" href="#@g
-s@"ulink" href="http://www.yoctoproject.org/docs/2.5.2/poky-ref-manual/poky-ref-manual.html#@"link" href="#@g
+# s@"ulink" href="http://www.yoctoproject.org/docs/2.6.1/[a-z]*-[a-z]*-[a-z]*/[a-z]*-[a-z]*-[a-z]*.html#@"link" href="#@g
+s@"ulink" href="http://www.yoctoproject.org/docs/2.6.1/yocto-project-qs/yocto-project-qs.html#@"link" href="#@g
+s@"ulink" href="http://www.yoctoproject.org/docs/2.6.1/poky-ref-manual/poky-ref-manual.html#@"link" href="#@g
 
 # Processes all other manuals (<word>-<word> style) except for the BitBake User Manual because
 # it is not included in the mega-manual.
 # This style is for manual folders that use two word, which is the standard now (e.g. "ref-manual").
 # This was the one-liner that worked before we introduced the BitBake User Manual, which is
 # not in the mega-manual.
-# s@"ulink" href="http://www.yoctoproject.org/docs/2.5.2/[a-z]*-[a-z]*/[a-z]*-[a-z]*.html#@"link" href="#@g
+# s@"ulink" href="http://www.yoctoproject.org/docs/2.6.1/[a-z]*-[a-z]*/[a-z]*-[a-z]*.html#@"link" href="#@g
 
-s@"ulink" href="http://www.yoctoproject.org/docs/2.5.2/sdk-manual/sdk-manual.html#@"link" href="#@g
-s@"ulink" href="http://www.yoctoproject.org/docs/2.5.2/bsp-guide/bsp-guide.html#@"link" href="#@g
-s@"ulink" href="http://www.yoctoproject.org/docs/2.5.2/dev-manual/dev-manual.html#@"link" href="#@g
-s@"ulink" href="http://www.yoctoproject.org/docs/2.5.2/overview-manual/overview-manual.html#@"link" href="#@g
-s@"ulink" href="http://www.yoctoproject.org/docs/2.5.2/brief-yoctoprojectqs/brief-yoctoprojectqs.html#@"link" href="#@g
-s@"ulink" href="http://www.yoctoproject.org/docs/2.5.2/kernel-dev/kernel-dev.html#@"link" href="#@g
-s@"ulink" href="http://www.yoctoproject.org/docs/2.5.2/profile-manual/profile-manual.html#@"link" href="#@g
-s@"ulink" href="http://www.yoctoproject.org/docs/2.5.2/ref-manual/ref-manual.html#@"link" href="#@g
-s@"ulink" href="http://www.yoctoproject.org/docs/2.5.2/toaster-manual/toaster-manual.html#@"link" href="#@g
+s@"ulink" href="http://www.yoctoproject.org/docs/2.6.1/sdk-manual/sdk-manual.html#@"link" href="#@g
+s@"ulink" href="http://www.yoctoproject.org/docs/2.6.1/bsp-guide/bsp-guide.html#@"link" href="#@g
+s@"ulink" href="http://www.yoctoproject.org/docs/2.6.1/dev-manual/dev-manual.html#@"link" href="#@g
+s@"ulink" href="http://www.yoctoproject.org/docs/2.6.1/overview-manual/overview-manual.html#@"link" href="#@g
+s@"ulink" href="http://www.yoctoproject.org/docs/2.6.1/brief-yoctoprojectqs/brief-yoctoprojectqs.html#@"link" href="#@g
+s@"ulink" href="http://www.yoctoproject.org/docs/2.6.1/kernel-dev/kernel-dev.html#@"link" href="#@g
+s@"ulink" href="http://www.yoctoproject.org/docs/2.6.1/profile-manual/profile-manual.html#@"link" href="#@g
+s@"ulink" href="http://www.yoctoproject.org/docs/2.6.1/ref-manual/ref-manual.html#@"link" href="#@g
+s@"ulink" href="http://www.yoctoproject.org/docs/2.6.1/toaster-manual/toaster-manual.html#@"link" href="#@g
 
 # Process cases where just an external manual is referenced without an id anchor
-s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.5.2/brief-yoctoprojectqs/brief-yoctoprojectqs.html" target="_top">Yocto Project Quick Build</a>@Yocto Project Quick Build@g
-s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.5.2/yocto-project-qs/yocto-project-qs.html" target="_top">Yocto Project Quick Start</a>@Yocto Project Quick Start@g
-s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.5.2/dev-manual/dev-manual.html" target="_top">Yocto Project Development Tasks Manual</a>@Yocto Project Development Tasks Manual@g
-s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.5.2/overview-manual/overview-manual.html" target="_top">Yocto Project Overview and Concepts Manual</a>@Yocto project Overview and Concepts Manual@g
-s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.5.2/sdk-manual/sdk-manual.html" target="_top">Yocto Project Application Development and the Extensible Software Development Kit (eSDK)</a>@Yocto Project Application Development and the Extensible Software Development Kit (eSDK)@g
-s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.5.2/bsp-guide/bsp-guide.html" target="_top">Yocto Project Board Support Package (BSP) Developer's Guide</a>@Yocto Project Board Support Package (BSP) Developer's Guide@g
-s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.5.2/profile-manual/profile-manual.html" target="_top">Yocto Project Profiling and Tracing Manual</a>@Yocto Project Profiling and Tracing Manual@g
-s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.5.2/kernel-dev/kernel-dev.html" target="_top">Yocto Project Linux Kernel Development Manual</a>@Yocto Project Linux Kernel Development Manual@g
-s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.5.2/ref-manual/ref-manual.html" target="_top">Yocto Project Reference Manual</a>@Yocto Project Reference Manual@g
-s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.5.2/toaster-manual/toaster-manual.html" target="_top">Toaster User Manual</a>@Toaster User Manual@g
+s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.6.1/brief-yoctoprojectqs/brief-yoctoprojectqs.html" target="_top">Yocto Project Quick Build</a>@Yocto Project Quick Build@g
+s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.6.1/yocto-project-qs/yocto-project-qs.html" target="_top">Yocto Project Quick Start</a>@Yocto Project Quick Start@g
+s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.6.1/dev-manual/dev-manual.html" target="_top">Yocto Project Development Tasks Manual</a>@Yocto Project Development Tasks Manual@g
+s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.6.1/overview-manual/overview-manual.html" target="_top">Yocto Project Overview and Concepts Manual</a>@Yocto project Overview and Concepts Manual@g
+s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.6.1/sdk-manual/sdk-manual.html" target="_top">Yocto Project Application Development and the Extensible Software Development Kit (eSDK)</a>@Yocto Project Application Development and the Extensible Software Development Kit (eSDK)@g
+s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.6.1/bsp-guide/bsp-guide.html" target="_top">Yocto Project Board Support Package (BSP) Developer's Guide</a>@Yocto Project Board Support Package (BSP) Developer's Guide@g
+s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.6.1/profile-manual/profile-manual.html" target="_top">Yocto Project Profiling and Tracing Manual</a>@Yocto Project Profiling and Tracing Manual@g
+s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.6.1/kernel-dev/kernel-dev.html" target="_top">Yocto Project Linux Kernel Development Manual</a>@Yocto Project Linux Kernel Development Manual@g
+s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.6.1/ref-manual/ref-manual.html" target="_top">Yocto Project Reference Manual</a>@Yocto Project Reference Manual@g
+s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.6.1/toaster-manual/toaster-manual.html" target="_top">Toaster User Manual</a>@Toaster User Manual@g
 
 # Process a single, rouge occurrence of a linked reference to the Mega-Manual.
-s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.5.2/mega-manual/mega-manual.html" target="_top">Yocto Project Mega-Manual</a>@Yocto Project Mega-Manual@g
+s@<a class="ulink" href="http://www.yoctoproject.org/docs/2.6.1/mega-manual/mega-manual.html" target="_top">Yocto Project Mega-Manual</a>@Yocto Project Mega-Manual@g
 
diff --git a/poky/meta-poky/conf/distro/poky-lsb.conf b/poky/meta-poky/conf/distro/poky-lsb.conf
index ecfe5d2..1c426ba 100644
--- a/poky/meta-poky/conf/distro/poky-lsb.conf
+++ b/poky/meta-poky/conf/distro/poky-lsb.conf
@@ -1,6 +1,5 @@
 
 require conf/distro/poky.conf
-require conf/distro/include/security_flags.inc
 
 DISTRO = "poky-lsb"
 DISTROOVERRIDES = "poky:linuxstdbase"
diff --git a/poky/meta-poky/conf/distro/poky-tiny.conf b/poky/meta-poky/conf/distro/poky-tiny.conf
index 7b22a13..690cb0d5 100644
--- a/poky/meta-poky/conf/distro/poky-tiny.conf
+++ b/poky/meta-poky/conf/distro/poky-tiny.conf
@@ -38,7 +38,7 @@
 # Distro config is evaluated after the machine config, so we have to explicitly
 # set the kernel provider to override a machine config.
 PREFERRED_PROVIDER_virtual/kernel = "linux-yocto-tiny"
-PREFERRED_VERSION_linux-yocto-tiny ?= "4.14%"
+PREFERRED_VERSION_linux-yocto-tiny ?= "4.18%"
 
 # We can use packagegroup-core-boot, but in the future we may need a new packagegroup-core-tiny
 #POKY_DEFAULT_EXTRA_RDEPENDS += "packagegroup-core-boot"
diff --git a/poky/meta-poky/conf/distro/poky.conf b/poky/meta-poky/conf/distro/poky.conf
index fb9e783..7e6fe13 100644
--- a/poky/meta-poky/conf/distro/poky.conf
+++ b/poky/meta-poky/conf/distro/poky.conf
@@ -1,7 +1,7 @@
 DISTRO = "poky"
 DISTRO_NAME = "Poky (Yocto Project Reference Distro)"
-DISTRO_VERSION = "2.5.2"
-DISTRO_CODENAME = "sumo"
+DISTRO_VERSION = "2.6"
+DISTRO_CODENAME = "thud"
 SDK_VENDOR = "-pokysdk"
 SDK_VERSION := "${@'${DISTRO_VERSION}'.replace('snapshot-${DATE}','snapshot')}"
 
@@ -21,7 +21,7 @@
 
 DISTRO_FEATURES ?= "${DISTRO_FEATURES_DEFAULT} ${DISTRO_FEATURES_LIBC} ${POKY_DEFAULT_DISTRO_FEATURES}"
 
-PREFERRED_VERSION_linux-yocto ?= "4.14%"
+PREFERRED_VERSION_linux-yocto ?= "4.18%"
 
 SDK_NAME = "${DISTRO}-${TCLIBC}-${SDK_ARCH}-${IMAGE_BASENAME}-${TUNE_PKGARCH}"
 SDKPATH = "/opt/${DISTRO}/${SDK_VERSION}"
@@ -64,16 +64,17 @@
 CONNECTIVITY_CHECK_URIS ?= "https://www.example.com/"
 
 SANITY_TESTED_DISTROS ?= " \
-            poky-2.4 \n \
             poky-2.5 \n \
-            ubuntu-15.04 \n \
+            poky-2.6 \n \
             ubuntu-16.04 \n \
-            ubuntu-18.04 \n \
-            fedora-28 \n \
+            ubuntu-16.10 \n \
+            ubuntu-17.04 \n \
+            fedora-26 \n \
             centos-7 \n \
             debian-8 \n \
             debian-9 \n \
-            opensuse-42.3 \n \
+            opensuse-42.1 \n \
+            opensuse-42.2 \n \
             "
 #
 # OELAYOUT_ABI allows us to notify users when the format of TMPDIR changes in
@@ -89,11 +90,12 @@
 # QA check settings - a little stricter than the OE-Core defaults
 WARN_TO_ERROR_QA = "already-stripped compile-host-path install-host-path \
                     installed-vs-shipped ldflags pn-overrides rpaths staticdev \
-                    useless-rpaths"
+                    unknown-configure-option useless-rpaths"
 WARN_QA_remove = "${WARN_TO_ERROR_QA}"
 ERROR_QA_append = " ${WARN_TO_ERROR_QA}"
 
 require conf/distro/include/poky-world-exclude.inc
 require conf/distro/include/no-static-libs.inc
 require conf/distro/include/yocto-uninative.inc
+require conf/distro/include/security_flags.inc
 INHERIT += "uninative"
diff --git a/poky/meta-poky/conf/layer.conf b/poky/meta-poky/conf/layer.conf
index 3761f87..b9b2637 100644
--- a/poky/meta-poky/conf/layer.conf
+++ b/poky/meta-poky/conf/layer.conf
@@ -9,7 +9,7 @@
 BBFILE_PATTERN_yocto = "^${LAYERDIR}/"
 BBFILE_PRIORITY_yocto = "5"
 
-LAYERSERIES_COMPAT_yocto = "sumo"
+LAYERSERIES_COMPAT_yocto = "thud"
 
 # This should only be incremented on significant changes that will
 # cause compatibility issues with other layers
diff --git a/poky/meta-poky/conf/local.conf.sample b/poky/meta-poky/conf/local.conf.sample
index aa8df40..d28bf58 100644
--- a/poky/meta-poky/conf/local.conf.sample
+++ b/poky/meta-poky/conf/local.conf.sample
@@ -234,12 +234,12 @@
 # Qemu configuration
 #
 # By default qemu will build with a builtin VNC server where graphical output can be
-# seen. The two lines below enable the SDL backend too. By default libsdl-native will
+# seen. The two lines below enable the SDL backend too. By default libsdl2-native will
 # be built, if you want to use your host's libSDL instead of the minimal libsdl built
-# by libsdl-native then uncomment the ASSUME_PROVIDED line below.
+# by libsdl2-native then uncomment the ASSUME_PROVIDED line below.
 PACKAGECONFIG_append_pn-qemu-native = " sdl"
 PACKAGECONFIG_append_pn-nativesdk-qemu = " sdl"
-#ASSUME_PROVIDED += "libsdl-native"
+#ASSUME_PROVIDED += "libsdl2-native"
 
 # CONF_VERSION is increased each time build/conf/ changes incompatibly and is used to
 # track the version of this file when it was generated. This can safely be ignored if
diff --git a/poky/meta-poky/conf/local.conf.sample.extended b/poky/meta-poky/conf/local.conf.sample.extended
index 0560de8..3ba99f4 100644
--- a/poky/meta-poky/conf/local.conf.sample.extended
+++ b/poky/meta-poky/conf/local.conf.sample.extended
@@ -32,7 +32,7 @@
 #DISTRO_FEATURES_LIBC = "ipv6 libc-backtrace libc-big-macros libc-bsd libc-cxx-tests libc-catgets libc-charsets libc-crypt \
 #               libc-crypt-ufc libc-db-aliases libc-envz libc-fcvt libc-fmtmsg libc-fstab libc-ftraverse \
 #               libc-getlogin libc-idn libc-inet libc-inet-anl libc-libm libc-locales libc-locale-code \
-#               libc-memusage libc-nis libc-nsswitch libc-rcmd libc-rtld-debug libc-spawn libc-streams libc-sunrpc \
+#               libc-memusage libc-nsswitch libc-rcmd libc-rtld-debug libc-spawn libc-streams \
 #               libc-utmp libc-utmpx libc-wordexp libc-posix-clang-wchar libc-posix-regexp libc-posix-regexp-glibc \
 #               libc-posix-wchar-io"
 
@@ -59,6 +59,11 @@
 # NOTE: If removing en_US.UTF-8 you will also need to uncomment, and set
 # appropriate value for IMAGE_LINGUAS.
 # WARNING: this may break localisation!
+# WARNING: some recipes expect certain localizations to be enabled, e.g.
+# bash-ptest: fr-fr, de-de
+# glib-2.0-ptest: tr-tr, lt-lt, ja-jp.euc-jp, fa-ir, ru-ru, de-de, hr-hr, el-gr, fr-fr, es-es, en-gb
+# if you remove some of these and enable ptest, you'll get QA warning like:
+# ERROR: glib-2.0-1_2.58.0-r0 do_package_qa: QA Issue: glib-2.0-ptest rdepends on locale-base-de-de, but it isn't a build dependency? [build-deps]
 #GLIBC_GENERATE_LOCALES = "en_GB.UTF-8 en_US.UTF-8"
 #IMAGE_LINGUAS ?= "en-gb"
 
diff --git a/poky/meta-poky/conf/site.conf.sample b/poky/meta-poky/conf/site.conf.sample
index 6cfefc5..a4c2f9f 100644
--- a/poky/meta-poky/conf/site.conf.sample
+++ b/poky/meta-poky/conf/site.conf.sample
@@ -24,7 +24,9 @@
 #or
 #ALL_PROXY ?= "https://proxy.example.com:8080"
 # If you wish to use certain hosts without the proxy, specify them in NO_PROXY.
-# See the script for details on syntax.
+# See the script for details on syntax. The script oe-git-proxy uses some tools
+# that may not be included on HOSTTOOLS, thus  add them manually through
+# HOSTTOOLS += "getent seq"
 
 # Uncomment this to use a shared download directory
 #DL_DIR = "/some/shared/download/directory/"
diff --git a/poky/meta-selftest/conf/layer.conf b/poky/meta-selftest/conf/layer.conf
index f574a50..0626b2a 100644
--- a/poky/meta-selftest/conf/layer.conf
+++ b/poky/meta-selftest/conf/layer.conf
@@ -9,4 +9,4 @@
 BBFILE_PATTERN_selftest = "^${LAYERDIR}/"
 BBFILE_PRIORITY_selftest = "5"
 
-LAYERSERIES_COMPAT_selftest = "sumo"
+LAYERSERIES_COMPAT_selftest = "thud"
diff --git a/poky/meta-selftest/lib/oeqa/runtime/cases/dnf_runtime.py b/poky/meta-selftest/lib/oeqa/runtime/cases/dnf_runtime.py
index 1aa7274..64a3502 100644
--- a/poky/meta-selftest/lib/oeqa/runtime/cases/dnf_runtime.py
+++ b/poky/meta-selftest/lib/oeqa/runtime/cases/dnf_runtime.py
@@ -27,7 +27,7 @@
         Expected: 1. Feeds were correctly set for dnf
                   2. Update recovers packages from host's repo
         Author: Humberto Ibarra <humberto.ibarra.lopez@intel.com>
-        Author: Alexander Kanavin <alexander.kanavin@intel.com>
+        Author: Alexander Kanavin <alex.kanavin@gmail.com>
         """
         # When we created an image, we had to supply fake ip and port
         # for the feeds. Now we can patch the real ones into the config file.
diff --git a/poky/meta-selftest/recipes-test/aspell/aspell_0.0.0.1.bb b/poky/meta-selftest/recipes-test/aspell/aspell_0.0.0.1.bb
index 073cf56..922518b 100644
--- a/poky/meta-selftest/recipes-test/aspell/aspell_0.0.0.1.bb
+++ b/poky/meta-selftest/recipes-test/aspell/aspell_0.0.0.1.bb
@@ -28,5 +28,8 @@
 FILES_libpspell = "${libdir}/libpspell.so.*"
 FILES_libpspell-dev = "${libdir}/libpspell* ${bindir}/pspell-config ${includedir}/pspell"
 
-ARM_INSTRUCTION_SET = "arm"
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
+ARM_INSTRUCTION_SET_armv6 = "arm"
+
 inherit autotools gettext
diff --git a/poky/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink.bb b/poky/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink.bb
new file mode 100644
index 0000000..842a977
--- /dev/null
+++ b/poky/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink.bb
@@ -0,0 +1,30 @@
+LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"
+
+LICENSE = "MIT"
+
+SRC_URI = "file://hello.c \
+           file://gdb.sh \
+"
+
+S = "${WORKDIR}"
+
+do_compile () {
+	${CC} hello.c -o hello1 ${CFLAGS} ${LDFLAGS}
+}
+
+do_install () {
+	install -d ${D}${bindir}
+	install -m 755 ${WORKDIR}/gdb.sh ${D}${bindir}/
+	install -m 755 hello1 ${D}${bindir}/hello1
+	ln ${D}${bindir}/hello1 ${D}${bindir}/hello2
+
+	install -d ${D}${libexecdir}
+	ln ${D}${bindir}/hello1 ${D}${libexecdir}/hello3
+	ln ${D}${bindir}/hello1 ${D}${libexecdir}/hello4
+
+	dd if=/dev/zero of=${D}${bindir}/sparsetest bs=1 count=0 seek=1M
+}
+
+RDEPENDS_${PN}-gdb += "gdb"
+PACKAGES =+ "${PN}-gdb"
+FILES_${PN}-gdb = "${bindir}/gdb.sh"
diff --git a/poky/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink/gdb.sh b/poky/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink/gdb.sh
new file mode 100755
index 0000000..f6417d5
--- /dev/null
+++ b/poky/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink/gdb.sh
@@ -0,0 +1,8 @@
+#!/bin/sh
+gdb -q $1  <<'EOF'
+b main
+r
+c
+q
+EOF
+echo ""
diff --git a/poky/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink/hello.c b/poky/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink/hello.c
new file mode 100644
index 0000000..5c45dc6
--- /dev/null
+++ b/poky/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink/hello.c
@@ -0,0 +1,5 @@
+#include <stdio.h>
+
+int main() {
+	printf("Hello World!\n");
+}
\ No newline at end of file
diff --git a/poky/meta-skeleton/conf/layer.conf b/poky/meta-skeleton/conf/layer.conf
index 4e8692e..13bda7b 100644
--- a/poky/meta-skeleton/conf/layer.conf
+++ b/poky/meta-skeleton/conf/layer.conf
@@ -14,4 +14,4 @@
 
 LAYERDEPENDS_skeleton = "core"
 
-LAYERSERIES_COMPAT_skeleton = "sumo"
+LAYERSERIES_COMPAT_skeleton = "thud"
diff --git a/poky/meta-yocto-bsp/conf/layer.conf b/poky/meta-yocto-bsp/conf/layer.conf
index 6472238..53e8722 100644
--- a/poky/meta-yocto-bsp/conf/layer.conf
+++ b/poky/meta-yocto-bsp/conf/layer.conf
@@ -9,4 +9,4 @@
 BBFILE_PATTERN_yoctobsp = "^${LAYERDIR}/"
 BBFILE_PRIORITY_yoctobsp = "5"
 LAYERVERSION_yoctobsp = "4"
-LAYERSERIES_COMPAT_yoctobsp = "sumo"
+LAYERSERIES_COMPAT_yoctobsp = "thud"
diff --git a/poky/meta-yocto-bsp/conf/machine/beaglebone-yocto.conf b/poky/meta-yocto-bsp/conf/machine/beaglebone-yocto.conf
index ae682a4..e911e75 100644
--- a/poky/meta-yocto-bsp/conf/machine/beaglebone-yocto.conf
+++ b/poky/meta-yocto-bsp/conf/machine/beaglebone-yocto.conf
@@ -20,10 +20,10 @@
 IMAGE_INSTALL_append = " kernel-devicetree kernel-image-zimage"
 do_image_wic[depends] += "mtools-native:do_populate_sysroot dosfstools-native:do_populate_sysroot"
 
-SERIAL_CONSOLE = "115200 ttyO0"
+SERIAL_CONSOLES = "115200;ttyO0"
 
 PREFERRED_PROVIDER_virtual/kernel ?= "linux-yocto"
-PREFERRED_VERSION_linux-yocto ?= "4.15%"
+PREFERRED_VERSION_linux-yocto ?= "4.18%"
 
 KERNEL_IMAGETYPE = "zImage"
 KERNEL_DEVICETREE = "am335x-bone.dtb am335x-boneblack.dtb am335x-bonegreen.dtb"
@@ -37,4 +37,4 @@
 
 MACHINE_FEATURES = "usbgadget usbhost vfat alsa"
 
-IMAGE_BOOT_FILES ?= "u-boot.${UBOOT_SUFFIX} MLO"
+IMAGE_BOOT_FILES ?= "u-boot.${UBOOT_SUFFIX} MLO zImage am335x-bone.dtb am335x-boneblack.dtb am335x-bonegreen.dtb"
diff --git a/poky/meta-yocto-bsp/conf/machine/edgerouter.conf b/poky/meta-yocto-bsp/conf/machine/edgerouter.conf
index 61f2145..b7a94e9 100644
--- a/poky/meta-yocto-bsp/conf/machine/edgerouter.conf
+++ b/poky/meta-yocto-bsp/conf/machine/edgerouter.conf
@@ -11,9 +11,9 @@
 KERNEL_IMAGE_STRIP_EXTRA_SECTIONS  = ".comment"
 
 PREFERRED_PROVIDER_virtual/kernel ?= "linux-yocto"
-PREFERRED_VERSION_linux-yocto ?= "4.15%"
+PREFERRED_VERSION_linux-yocto ?= "4.18%"
 
-SERIAL_CONSOLE = "115200 ttyS0"
+SERIAL_CONSOLES = "115200;ttyS0"
 USE_VT ?= "0"
 
 MACHINE_EXTRA_RRECOMMENDS = "kernel-modules"
diff --git a/poky/meta-yocto-bsp/conf/machine/include/genericx86-common.inc b/poky/meta-yocto-bsp/conf/machine/include/genericx86-common.inc
index e35685c..f83ce5c 100644
--- a/poky/meta-yocto-bsp/conf/machine/include/genericx86-common.inc
+++ b/poky/meta-yocto-bsp/conf/machine/include/genericx86-common.inc
@@ -13,7 +13,7 @@
             ${XSERVER_X86_MODESETTING} \
            "
 
-MACHINE_EXTRA_RRECOMMENDS += "linux-firmware eee-acpi-scripts"
+MACHINE_EXTRA_RRECOMMENDS += "kernel-modules linux-firmware"
 
 GLIBC_ADDONS = "nptl"
 
diff --git a/poky/meta-yocto-bsp/conf/machine/mpc8315e-rdb.conf b/poky/meta-yocto-bsp/conf/machine/mpc8315e-rdb.conf
index 34f1230..6f5b985 100644
--- a/poky/meta-yocto-bsp/conf/machine/mpc8315e-rdb.conf
+++ b/poky/meta-yocto-bsp/conf/machine/mpc8315e-rdb.conf
@@ -1,5 +1,5 @@
 #@TYPE: Machine
-#@DESCRIPTION: Machine configuration for running 
+#@DESCRIPTION: Machine configuration for running
 
 TARGET_FPU = ""
 
@@ -10,12 +10,12 @@
 EXTRA_IMAGEDEPENDS += "u-boot"
 UBOOT_MACHINE = "MPC8315ERDB_config"
 
-SERIAL_CONSOLE = "115200 ttyS0"
+SERIAL_CONSOLES = "115200;ttyS0"
 
 MACHINE_FEATURES = "keyboard pci ext2 ext3 serial"
 
-PREFERRED_VERSION_linux-yocto ?= "4.15%"
-PREFERRED_PROVIDER_virtual/kernel = "linux-yocto"
+PREFERRED_VERSION_linux-yocto ?= "4.18%"
+PREFERRED_PROVIDER_virtual/kernel ?= "linux-yocto"
 
 PREFERRED_PROVIDER_virtual/xserver ?= "xserver-xorg"
 XSERVER ?= "xserver-xorg \
@@ -32,4 +32,4 @@
 
 IMAGE_FSTYPES += "wic wic.bmap"
 WKS_FILE ?= 'mpc8315e-rdb.wks'
-IMAGE_BOOT_FILES ?= "u-boot.bin uImage uImage-mpc8315erdb.dtb;dtb"
+IMAGE_BOOT_FILES ?= "u-boot.bin uImage mpc8315erdb.dtb;dtb"
diff --git a/poky/meta-yocto-bsp/lib/oeqa/selftest/cases/systemd_boot.py b/poky/meta-yocto-bsp/lib/oeqa/selftest/cases/systemd_boot.py
index 26c775c..dfd739a 100644
--- a/poky/meta-yocto-bsp/lib/oeqa/selftest/cases/systemd_boot.py
+++ b/poky/meta-yocto-bsp/lib/oeqa/selftest/cases/systemd_boot.py
@@ -6,26 +6,9 @@
 from oeqa.utils.commands import runCmd, bitbake, get_bb_var, runqemu
 
 class Systemdboot(OESelftestTestCase):
-    def _common_setup(self):
-        """
-        Common setup for test cases: 1445, 1528
-        """
-
-        # Set EFI_PROVIDER = "systemdboot" and MACHINE = "genericx86-64" in conf/local.conf
-        features = 'EFI_PROVIDER = "systemd-boot"\n'
-        features += 'MACHINE = "genericx86-64"'
-        self.append_config(features)
-
-    def _common_build(self):
-        """
-        Common build for test cases: 1445 , 1528
-        """
-
-        # Build a genericx86-64/efi systemdboot image
-        bitbake('mtools-native core-image-minimal')
-
 
     @OETestID(1445)
+    @OETestID(1528)
     def test_efi_systemdboot_images_can_be_built(self):
         """
         Summary:     Check if systemd-boot images can be built correctly
@@ -36,26 +19,25 @@
         AutomatedBy: Jose Perez Carranza <jose.perez.carranza@intel.com>
         """
 
-        # We'd use DEPLOY_DIR_IMAGE here, except that we need its value for
-        # MACHINE="genericx86-64 which is probably not the one configured
-        systemdbootfile = os.path.join(get_bb_var('DEPLOY_DIR'), 'images', 'genericx86-64', 'systemd-bootx64.efi')
+        # Set EFI_PROVIDER = "systemdboot" and MACHINE = "genericx86-64" in conf/local.conf
+        features = 'EFI_PROVIDER = "systemd-boot"\n'
+        features += 'MACHINE = "genericx86-64"'
+        self.append_config(features)
 
-        self._common_setup()
+        deploydir = get_bb_var('DEPLOY_DIR_IMAGE', "core-image-minimal")
+        systemdbootfile = os.path.join(deploydir, 'systemd-bootx64.efi')
 
         # Ensure we're actually testing that this gets built and not that
         # it was around from an earlier build
         bitbake('-c clean systemd-boot')
         runCmd('rm -f %s' % systemdbootfile)
 
-        self._common_build()
+        # Build a genericx86-64/efi systemdboot image
+        bitbake('mtools-native core-image-minimal')
 
         found = os.path.isfile(systemdbootfile)
         self.assertTrue(found, 'Systemd-Boot file %s not found' % systemdbootfile)
 
-    @OETestID(1528)
-    @OETestDepends(['systemd_boot.Systemdboot.test_efi_systemdboot_images_can_be_built'])
-    def test_image_efi_file(self):
-
         """
         Summary:      Check if EFI bootloader for systemd is correctly build
         Dependencies: Image was built correctly on testcase 1445
@@ -71,28 +53,21 @@
         AutomatedBy:  Jose Perez Carranza <jose.perez.carranza at linux-intel.com>
         """
 
-        systemdbootfile = os.path.join(get_bb_var('DEPLOY_DIR'), 'images', 'genericx86-64',
-                                           'systemd-bootx64.efi')
-        systemdbootimage = os.path.join(get_bb_var('DEPLOY_DIR'), 'images', 'genericx86-64',
-                                                'core-image-minimal-genericx86-64.hddimg')
-        imagebootfile = os.path.join(get_bb_var('DEPLOY_DIR'), 'images', 'genericx86-64',
-                                                            'bootx64.efi')
-        mcopynative = os.path.join(get_bb_var('STAGING_BINDIR_NATIVE'), 'mcopy')
+        systemdbootimage = os.path.join(deploydir, 'core-image-minimal-genericx86-64.hddimg')
+        imagebootfile = os.path.join(deploydir, 'bootx64.efi')
+        mcopynative = os.path.join(get_bb_var('STAGING_BINDIR_NATIVE', "core-image-minimal"), 'mcopy')
 
-        #Clean environment before start the test
+        # Clean environment before start the test
         if os.path.isfile(imagebootfile):
             runCmd('rm -f %s' % imagebootfile)
 
-            #Step 1
-            runCmd('%s -i %s ::EFI/BOOT/bootx64.efi %s' % (mcopynative ,systemdbootimage,
+        runCmd('%s -i %s ::EFI/BOOT/bootx64.efi %s' % (mcopynative ,systemdbootimage,
                                                            imagebootfile))
 
-            #Step 2
-            found = os.path.isfile(imagebootfile)
-            self.assertTrue(found, 'bootx64.efi file %s was not copied from image'
+        found = os.path.isfile(imagebootfile)
+        self.assertTrue(found, 'bootx64.efi file %s was not copied from image'
                             % imagebootfile)
 
-            #Step 3
-            result = runCmd('md5sum %s %s' % (systemdbootfile, imagebootfile))
-            self.assertEqual(result.output.split()[0], result.output.split()[2],
+        result = runCmd('md5sum %s %s' % (systemdbootfile, imagebootfile))
+        self.assertEqual(result.output.split()[0], result.output.split()[2],
                              '%s was not correclty generated' % imagebootfile)
diff --git a/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto-dev.bbappend b/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto-dev.bbappend
new file mode 100644
index 0000000..f044daf
--- /dev/null
+++ b/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto-dev.bbappend
@@ -0,0 +1,15 @@
+KBRANCH_genericx86  = "standard/base"
+KBRANCH_genericx86-64  = "standard/base"
+KBRANCH_edgerouter = "standard/edgerouter"
+KBRANCH_beaglebone-yocto = "standard/beaglebone"
+KBRANCH_mpc8315e-rdb = "standard/fsl-mpc8315e-rdb"
+
+KMACHINE_genericx86 ?= "common-pc"
+KMACHINE_genericx86-64 ?= "common-pc-64"
+KMACHINE_beaglebone-yocto ?= "beaglebone"
+
+COMPATIBLE_MACHINE_genericx86 = "genericx86"
+COMPATIBLE_MACHINE_genericx86-64 = "genericx86-64"
+COMPATIBLE_MACHINE_edgerouter = "edgerouter"
+COMPATIBLE_MACHINE_beaglebone-yocto = "beaglebone-yocto"
+COMPATIBLE_MACHINE_mpc8315e-rdb = "mpc8315e-rdb"
diff --git a/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.12.bbappend b/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.12.bbappend
deleted file mode 100644
index 642809a..0000000
--- a/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.12.bbappend
+++ /dev/null
@@ -1,28 +0,0 @@
-KBRANCH_genericx86  = "standard/base"
-KBRANCH_genericx86-64  = "standard/base"
-
-KMACHINE_genericx86 ?= "common-pc"
-KMACHINE_genericx86-64 ?= "common-pc-64"
-KBRANCH_edgerouter = "standard/edgerouter"
-KBRANCH_beaglebone-yocto = "standard/beaglebone"
-KMACHINE_beaglebone-yocto = "beaglebone"
-KBRANCH_mpc8315e-rdb = "standard/fsl-mpc8315e-rdb"
-
-SRCREV_machine_genericx86    ?= "7e7ac3f0fda9707e94b3311a4510ae080cd86238"
-SRCREV_machine_genericx86-64 ?= "7e7ac3f0fda9707e94b3311a4510ae080cd86238"
-SRCREV_machine_edgerouter ?= "89e003746eee54e86bc78e1170e7029d6597b583"
-SRCREV_machine_beaglebone-yocto ?= "89e003746eee54e86bc78e1170e7029d6597b583"
-SRCREV_machine_mpc8315e-rdb ?= "7080a5fe6af338576207fff999ea2ca35e689997"
-
-
-COMPATIBLE_MACHINE_genericx86 = "genericx86"
-COMPATIBLE_MACHINE_genericx86-64 = "genericx86-64"
-COMPATIBLE_MACHINE_edgerouter = "edgerouter"
-COMPATIBLE_MACHINE_beaglebone-yocto = "beaglebone-yocto"
-COMPATIBLE_MACHINE_mpc8315e-rdb = "mpc8315e-rdb"
-
-LINUX_VERSION_genericx86 = "4.12.24"
-LINUX_VERSION_genericx86-64 = "4.12.24"
-LINUX_VERSION_edgerouter = "4.12.24"
-LINUX_VERSION_beaglebone-yocto = "4.12.24"
-LINUX_VERSION_mpc8315e-rdb = "4.12.24"
diff --git a/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.14.bbappend b/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.14.bbappend
index feb8d2e..502485a 100644
--- a/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.14.bbappend
+++ b/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.14.bbappend
@@ -8,11 +8,11 @@
 KMACHINE_genericx86-64 ?= "common-pc-64"
 KMACHINE_beaglebone-yocto ?= "beaglebone"
 
-SRCREV_machine_genericx86    ?= "084af9624d268ddf4fd65b2f9e8e50ca2f22e62b"
-SRCREV_machine_genericx86-64 ?= "084af9624d268ddf4fd65b2f9e8e50ca2f22e62b"
-SRCREV_machine_edgerouter ?= "65d1c849534179bbfa494f77947f8be615e9871a"
-SRCREV_machine_beaglebone-yocto ?= "d62ddfa26a59c83f6128790b7aa2baadc04d2960"
-SRCREV_machine_mpc8315e-rdb ?= "80a106ecf737b69864e07b955eccb62f809cf120"
+SRCREV_machine_genericx86    ?= "2c5caa7e84311f2a0097974a697ac1f59030530e"
+SRCREV_machine_genericx86-64 ?= "2c5caa7e84311f2a0097974a697ac1f59030530e"
+SRCREV_machine_edgerouter ?= "e06bfa18c727bd0e6e10cf26d9f161e4c791f52b"
+SRCREV_machine_beaglebone-yocto ?= "b8805de77dcf8f59d8368fee4921c146c1300a6a"
+SRCREV_machine_mpc8315e-rdb ?= "f88e87360b10f8fbd853a7d412982e6620f3f96d"
 
 COMPATIBLE_MACHINE_genericx86 = "genericx86"
 COMPATIBLE_MACHINE_genericx86-64 = "genericx86-64"
@@ -20,8 +20,8 @@
 COMPATIBLE_MACHINE_beaglebone-yocto = "beaglebone-yocto"
 COMPATIBLE_MACHINE_mpc8315e-rdb = "mpc8315e-rdb"
 
-LINUX_VERSION_genericx86 = "4.14.67"
-LINUX_VERSION_genericx86-64 = "4.14.67"
-LINUX_VERSION_edgerouter = "4.14.48"
-LINUX_VERSION_beaglebone-yocto = "4.14.48"
-LINUX_VERSION_mpc8315e-rdb = "4.14.48"
+LINUX_VERSION_genericx86 = "4.14.76"
+LINUX_VERSION_genericx86-64 = "4.14.76"
+LINUX_VERSION_edgerouter = "4.14.71"
+LINUX_VERSION_beaglebone-yocto = "4.14.71"
+LINUX_VERSION_mpc8315e-rdb = "4.14.71"
diff --git a/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.15.bbappend b/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.15.bbappend
deleted file mode 100644
index 461daa0..0000000
--- a/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.15.bbappend
+++ /dev/null
@@ -1,27 +0,0 @@
-KBRANCH_genericx86  = "v4.15/standard/base"
-KBRANCH_genericx86-64  = "v4.15/standard/base"
-KBRANCH_edgerouter = "v4.15/standard/edgerouter"
-KBRANCH_beaglebone-yocto = "v4.15/standard/beaglebone"
-KBRANCH_mpc8315e-rdb = "v4.15/standard/fsl-mpc8315e-rdb"
-
-KMACHINE_genericx86 ?= "common-pc"
-KMACHINE_genericx86-64 ?= "common-pc-64"
-KMACHINE_beaglebone-yocto ?= "beaglebone"
-
-SRCREV_machine_genericx86    ?= "51273ff79f4ad930f4a788257f58e1266cb236e3"
-SRCREV_machine_genericx86-64 ?= "51273ff79f4ad930f4a788257f58e1266cb236e3"
-SRCREV_machine_edgerouter ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_machine_beaglebone-yocto ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_machine_mpc8315e-rdb ?= "0b32edc46dfe7c40bf5451e9b7533c823bb2c6c4"
-
-COMPATIBLE_MACHINE_genericx86 = "genericx86"
-COMPATIBLE_MACHINE_genericx86-64 = "genericx86-64"
-COMPATIBLE_MACHINE_edgerouter = "edgerouter"
-COMPATIBLE_MACHINE_beaglebone-yocto = "beaglebone-yocto"
-COMPATIBLE_MACHINE_mpc8315e-rdb = "mpc8315e-rdb"
-
-LINUX_VERSION_genericx86 = "4.15.18"
-LINUX_VERSION_genericx86-64 = "4.15.18"
-LINUX_VERSION_edgerouter = "4.15.18"
-LINUX_VERSION_beaglebone-yocto = "4.15.18"
-LINUX_VERSION_mpc8315e-rdb = "4.15.18"
diff --git a/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.18.bbappend b/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.18.bbappend
new file mode 100644
index 0000000..bb599d8
--- /dev/null
+++ b/poky/meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.18.bbappend
@@ -0,0 +1,27 @@
+KBRANCH_genericx86  = "v4.18/standard/base"
+KBRANCH_genericx86-64  = "v4.18/standard/base"
+KBRANCH_edgerouter = "v4.18/standard/edgerouter"
+KBRANCH_beaglebone-yocto = "v4.18/standard/beaglebone"
+KBRANCH_mpc8315e-rdb = "v4.18/standard/fsl-mpc8315e-rdb"
+
+KMACHINE_genericx86 ?= "common-pc"
+KMACHINE_genericx86-64 ?= "common-pc-64"
+KMACHINE_beaglebone-yocto ?= "beaglebone"
+
+SRCREV_machine_genericx86    ?= "33859b3077c83d8a024946ba06a59990546fcbc7"
+SRCREV_machine_genericx86-64 ?= "33859b3077c83d8a024946ba06a59990546fcbc7"
+SRCREV_machine_edgerouter ?= "0cdc8564c61958a39704d97e008120bd7c762f60"
+SRCREV_machine_beaglebone-yocto ?= "0cdc8564c61958a39704d97e008120bd7c762f60"
+SRCREV_machine_mpc8315e-rdb ?= "20be2231bb047b02248d7f965c1c3af0c6be3a5e"
+
+COMPATIBLE_MACHINE_genericx86 = "genericx86"
+COMPATIBLE_MACHINE_genericx86-64 = "genericx86-64"
+COMPATIBLE_MACHINE_edgerouter = "edgerouter"
+COMPATIBLE_MACHINE_beaglebone-yocto = "beaglebone-yocto"
+COMPATIBLE_MACHINE_mpc8315e-rdb = "mpc8315e-rdb"
+
+LINUX_VERSION_genericx86 = "4.18.14"
+LINUX_VERSION_genericx86-64 = "4.18.14"
+LINUX_VERSION_edgerouter = "4.18.9"
+LINUX_VERSION_beaglebone-yocto = "4.18.9"
+LINUX_VERSION_mpc8315e-rdb = "4.18.9"
diff --git a/poky/meta-yocto-bsp/wic/beaglebone-yocto.wks b/poky/meta-yocto-bsp/wic/beaglebone-yocto.wks
index 967cad7..b75f238 100644
--- a/poky/meta-yocto-bsp/wic/beaglebone-yocto.wks
+++ b/poky/meta-yocto-bsp/wic/beaglebone-yocto.wks
@@ -2,5 +2,5 @@
 # long-description: Creates a partitioned SD card image for Beaglebone.
 # Boot files are located in the first vfat partition.
 
-part /boot --source bootimg-partition --ondisk mmcblk0 --fstype=vfat --label boot --active --align 4 --size 16
-part / --source rootfs --ondisk mmcblk --fstype=ext4 --label root --align 4
+part /boot --source bootimg-partition --ondisk mmcblk0 --fstype=vfat --label boot --active --align 4 --size 16 --sourceparams="loader=u-boot" --use-uuid
+part / --source rootfs --ondisk mmcblk --fstype=ext4 --label root --align 4 --use-uuid
diff --git a/poky/meta/classes/allarch.bbclass b/poky/meta/classes/allarch.bbclass
index 51ba509..5bd5c44 100644
--- a/poky/meta/classes/allarch.bbclass
+++ b/poky/meta/classes/allarch.bbclass
@@ -2,7 +2,18 @@
 # This class is used for architecture independent recipes/data files (usually scripts)
 #
 
-PACKAGE_ARCH = "all"
+python allarch_package_arch_handler () {
+    if bb.data.inherits_class("native", d) or bb.data.inherits_class("nativesdk", d) \
+        or bb.data.inherits_class("crosssdk", d):
+        return
+
+    variants = d.getVar("MULTILIB_VARIANTS")
+    if not variants:
+        d.setVar("PACKAGE_ARCH", "all" )
+}
+
+addhandler allarch_package_arch_handler
+allarch_package_arch_handler[eventmask] = "bb.event.RecipePreFinalise"
 
 python () {
     # Allow this class to be included but overridden - only set
@@ -45,6 +56,7 @@
         # These multilib values shouldn't change allarch packages so exclude them
         d.appendVarFlag("emit_pkgdata", "vardepsexclude", " MULTILIB_VARIANTS")
         d.appendVarFlag("write_specfile", "vardepsexclude", " MULTILIBS")
+        d.appendVarFlag("do_package", "vardepsexclude", " package_do_shlibs")
     elif bb.data.inherits_class('packagegroup', d) and not bb.data.inherits_class('nativesdk', d):
         bb.error("Please ensure recipe %s sets PACKAGE_ARCH before inherit packagegroup" % d.getVar("FILE"))
 }
diff --git a/poky/meta/classes/archiver.bbclass b/poky/meta/classes/archiver.bbclass
index d68add9..0a9fe4f 100644
--- a/poky/meta/classes/archiver.bbclass
+++ b/poky/meta/classes/archiver.bbclass
@@ -98,9 +98,12 @@
 
         # There is a corner case with "gcc-source-${PV}" recipes, they don't have
         # the "do_configure" task, so we need to use "do_preconfigure"
-        if pn.startswith("gcc-source-"):
+        def hasTask(task):
+            return bool(d.getVarFlag(task, "task", False)) and not bool(d.getVarFlag(task, "noexec", False))
+
+        if hasTask("do_preconfigure"):
             d.appendVarFlag('do_ar_configured', 'depends', ' %s:do_preconfigure' % pn)
-        else:
+        elif hasTask("do_configure"):
             d.appendVarFlag('do_ar_configured', 'depends', ' %s:do_configure' % pn)
         d.appendVarFlag('do_deploy_archives', 'depends', ' %s:do_ar_configured' % pn)
 
@@ -243,21 +246,26 @@
         # do_configure, we archive the already configured ${S} to
         # instead of.
         elif pn != 'libtool-native':
+            def runTask(task):
+                prefuncs = d.getVarFlag(task, 'prefuncs') or ''
+                for func in prefuncs.split():
+                    if func != "sysroot_cleansstate":
+                        bb.build.exec_func(func, d)
+                bb.build.exec_func(task, d)
+                postfuncs = d.getVarFlag(task, 'postfuncs') or ''
+                for func in postfuncs.split():
+                    if func != 'do_qa_configure':
+                        bb.build.exec_func(func, d)
+
             # Change the WORKDIR to make do_configure run in another dir.
             d.setVar('WORKDIR', d.getVar('ARCHIVER_WORKDIR'))
-            if bb.data.inherits_class('kernel-yocto', d):
-                bb.build.exec_func('do_kernel_configme', d)
-            if bb.data.inherits_class('cmake', d):
-                bb.build.exec_func('do_generate_toolchain_file', d)
-            prefuncs = d.getVarFlag('do_configure', 'prefuncs')
-            for func in (prefuncs or '').split():
-                if func != "sysroot_cleansstate":
-                    bb.build.exec_func(func, d)
-            bb.build.exec_func('do_configure', d)
-            postfuncs = d.getVarFlag('do_configure', 'postfuncs')
-            for func in (postfuncs or '').split():
-                if func != "do_qa_configure":
-                    bb.build.exec_func(func, d)
+
+            preceeds = bb.build.preceedtask('do_configure', False, d)
+            for task in preceeds:
+                if task != 'do_patch' and task != 'do_prepare_recipe_sysroot':
+                    runTask(task)
+            runTask('do_configure')
+
         srcdir = d.getVar('S')
         builddir = d.getVar('B')
         if srcdir != builddir:
diff --git a/poky/meta/classes/autotools.bbclass b/poky/meta/classes/autotools.bbclass
index cc857ac..8768a6a 100644
--- a/poky/meta/classes/autotools.bbclass
+++ b/poky/meta/classes/autotools.bbclass
@@ -225,7 +225,7 @@
 			find ${S} -ignore_readdir_race -name $i -delete
 		done
 
-		bbnote Executing ACLOCAL=\"$ACLOCAL\" autoreconf --verbose --install --force ${EXTRA_AUTORECONF} $acpaths
+		bbnote Executing ACLOCAL=\"$ACLOCAL\" autoreconf -Wcross --verbose --install --force ${EXTRA_AUTORECONF} $acpaths
 		ACLOCAL="$ACLOCAL" autoreconf -Wcross --verbose --install --force ${EXTRA_AUTORECONF} $acpaths || die "autoreconf execution failed."
 		cd $olddir
 	fi
@@ -237,7 +237,7 @@
 }
 
 autotools_do_compile() {
-    oe_runmake
+	oe_runmake
 }
 
 autotools_do_install() {
diff --git a/poky/meta/classes/base.bbclass b/poky/meta/classes/base.bbclass
index 2a6a6cb..bc9b236 100644
--- a/poky/meta/classes/base.bbclass
+++ b/poky/meta/classes/base.bbclass
@@ -128,6 +128,12 @@
                 os.symlink(srctool, desttool)
             else:
                 notfound.append(tool)
+    # Force "python" -> "python2"
+    desttool = os.path.join(dest, "python")
+    if not os.path.exists(desttool):
+        srctool = "python2"
+        os.symlink(srctool, desttool)
+
     if notfound and fatal:
         bb.fatal("The following required tools (as specified by HOSTTOOLS) appear to be unavailable in PATH, please install them in order to proceed:\n  %s" % " ".join(notfound))
 
@@ -152,7 +158,7 @@
 addtask unpack after do_fetch
 do_unpack[dirs] = "${WORKDIR}"
 
-do_unpack[cleandirs] = "${@d.getVar('S') if d.getVar('S') != d.getVar('WORKDIR') else os.path.join('${S}', 'patches')}"
+do_unpack[cleandirs] = "${@d.getVar('S') if os.path.normpath(d.getVar('S')) != os.path.normpath(d.getVar('WORKDIR')) else os.path.join('${S}', 'patches')}"
 
 python base_do_unpack() {
     src_uri = (d.getVar('SRC_URI') or "").split()
@@ -522,19 +528,18 @@
             incompatwl = []
             for lic in bad_licenses:
                 spdx_license = return_spdx(d, lic)
-                for w in ["LGPLv2_WHITELIST_", "WHITELIST_"]:
-                    whitelist.extend((d.getVar(w + lic) or "").split())
-                    if spdx_license:
-                        whitelist.extend((d.getVar(w + spdx_license) or "").split())
-                    '''
-                    We need to track what we are whitelisting and why. If pn is
-                    incompatible we need to be able to note that the image that
-                    is created may infact contain incompatible licenses despite
-                    INCOMPATIBLE_LICENSE being set.
-                    '''
-                    incompatwl.extend((d.getVar(w + lic) or "").split())
-                    if spdx_license:
-                        incompatwl.extend((d.getVar(w + spdx_license) or "").split())
+                whitelist.extend((d.getVar("WHITELIST_" + lic) or "").split())
+                if spdx_license:
+                    whitelist.extend((d.getVar("WHITELIST_" + spdx_license) or "").split())
+                '''
+                We need to track what we are whitelisting and why. If pn is
+                incompatible we need to be able to note that the image that
+                is created may infact contain incompatible licenses despite
+                INCOMPATIBLE_LICENSE being set.
+                '''
+                incompatwl.extend((d.getVar("WHITELIST_" + lic) or "").split())
+                if spdx_license:
+                    incompatwl.extend((d.getVar("WHITELIST_" + spdx_license) or "").split())
 
             if not pn in whitelist:
                 pkgs = d.getVar('PACKAGES').split()
@@ -624,7 +629,7 @@
         elif path.endswith('.zip') or path.endswith('.jar'):
             d.appendVarFlag('do_unpack', 'depends', ' unzip-native:do_populate_sysroot')
 
-        # file is needed by rpm2cpio.sh
+        # Some rpm files may be compressed internally using xz (for example, rpms from Fedora)
         elif path.endswith('.rpm'):
             d.appendVarFlag('do_unpack', 'depends', ' xz-native:do_populate_sysroot')
 
diff --git a/poky/meta/classes/buildhistory.bbclass b/poky/meta/classes/buildhistory.bbclass
index 63980f7..40b292b 100644
--- a/poky/meta/classes/buildhistory.bbclass
+++ b/poky/meta/classes/buildhistory.bbclass
@@ -77,6 +77,7 @@
 
     import re
     import json
+    import shlex
     import errno
 
     pkghistdir = d.getVar('BUILDHISTORY_DIR_PACKAGE')
@@ -244,7 +245,7 @@
                 key = item[0]
                 if key.endswith('_' + pkg):
                     key = key[:-len(pkg)-1]
-                pkgdata[key] = item[1]
+                pkgdata[key] = item[1].encode('latin-1').decode('unicode_escape')
 
         pkge = pkgdata.get('PKGE', '0')
         pkgv = pkgdata['PKGV']
@@ -287,7 +288,7 @@
         dictval = json.loads(val)
         filelist = list(dictval.keys())
         filelist.sort()
-        pkginfo.filelist = " ".join(filelist)
+        pkginfo.filelist = " ".join([shlex.quote(x) for x in filelist])
 
         pkginfo.size = int(pkgdata['PKGSIZE'])
 
diff --git a/poky/meta/classes/clutter.bbclass b/poky/meta/classes/clutter.bbclass
index f5cd04f..8550363 100644
--- a/poky/meta/classes/clutter.bbclass
+++ b/poky/meta/classes/clutter.bbclass
@@ -1,4 +1,3 @@
-
 def get_minor_dir(v):
     import re
     m = re.match("^([0-9]+)\.([0-9]+)", v)
@@ -12,11 +11,7 @@
 VERMINOR = "${@get_minor_dir("${PV}")}"
 REALNAME = "${@get_real_name("${BPN}")}"
 
-CLUTTER_SRC_FTP = "${GNOME_MIRROR}/${REALNAME}/${VERMINOR}/${REALNAME}-${PV}.tar.xz;name=archive"
-
-CLUTTER_SRC_GIT = "git://gitlab.gnome.org/GNOME/${REALNAME};protocol=https"
-
-SRC_URI = "${CLUTTER_SRC_FTP}"
+SRC_URI = "${GNOME_MIRROR}/${REALNAME}/${VERMINOR}/${REALNAME}-${PV}.tar.xz;name=archive"
 S = "${WORKDIR}/${REALNAME}-${PV}"
 
 inherit autotools pkgconfig gtk-doc gettext
diff --git a/poky/meta/classes/cmake.bbclass b/poky/meta/classes/cmake.bbclass
index fcfd5dd..fd40a98 100644
--- a/poky/meta/classes/cmake.bbclass
+++ b/poky/meta/classes/cmake.bbclass
@@ -54,8 +54,6 @@
 OECMAKE_TARGET_COMPILE ?= "all"
 OECMAKE_TARGET_INSTALL ?= "install"
 
-FILES_${PN}-dev += "${libdir}/cmake ${datadir}/cmake"
-
 # CMake expects target architectures in the format of uname(2),
 # which do not always match TARGET_ARCH, so all the necessary
 # conversions should happen here.
diff --git a/poky/meta/classes/compress_doc.bbclass b/poky/meta/classes/compress_doc.bbclass
index 069d534..45bb8ff 100644
--- a/poky/meta/classes/compress_doc.bbclass
+++ b/poky/meta/classes/compress_doc.bbclass
@@ -79,6 +79,7 @@
     return hardlink_dict
 
 def _process_hardlink(hardlink_dict, compress_mode, shell_cmds, decompress=False):
+    import subprocess
     for target in hardlink_dict:
         if decompress:
             compress_format = _get_compress_format(target, shell_cmds.keys())
@@ -87,7 +88,7 @@
         else:
             cmd = "%s -f %s" % (shell_cmds[compress_mode], target)
             bb.note('compress hardlink %s' % target)
-        (retval, output) = oe.utils.getstatusoutput(cmd)
+        (retval, output) = subprocess.getstatusoutput(cmd)
         if retval:
             bb.warn("de/compress file failed %s (cmd was %s)%s" % (retval, cmd, ":\n%s" % output if output else ""))
             return
@@ -176,7 +177,7 @@
                 # Normal file
                 elif os.path.isfile(file):
                     cmd = "%s %s" % (compress_cmds[compress_mode], file)
-                    (retval, output) = oe.utils.getstatusoutput(cmd)
+                    (retval, output) = subprocess.getstatusoutput(cmd)
                     if retval:
                         bb.warn("compress failed %s (cmd was %s)%s" % (retval, cmd, ":\n%s" % output if output else ""))
                         continue
@@ -206,7 +207,7 @@
                 # Normal file
                 elif os.path.isfile(file):
                     cmd = "%s %s" % (decompress_cmds[compress_format], file)
-                    (retval, output) = oe.utils.getstatusoutput(cmd)
+                    (retval, output) = subprocess.getstatusoutput(cmd)
                     if retval:
                         bb.warn("decompress failed %s (cmd was %s)%s" % (retval, cmd, ":\n%s" % output if output else ""))
                         continue
diff --git a/poky/meta/classes/cpan.bbclass b/poky/meta/classes/cpan.bbclass
index 8e079e0..a5bc301 100644
--- a/poky/meta/classes/cpan.bbclass
+++ b/poky/meta/classes/cpan.bbclass
@@ -16,8 +16,7 @@
 export PERLHOSTLIB = "${STAGING_LIBDIR_NATIVE}/perl-native/perl/${@get_perl_version(d)}/"
 
 cpan_do_configure () {
-	export PERL5LIB="${PERL_ARCHLIB}"
-	yes '' | perl ${EXTRA_PERLFLAGS} Makefile.PL INSTALLDIRS=vendor ${EXTRA_CPANFLAGS}
+	yes '' | perl ${EXTRA_PERLFLAGS} Makefile.PL INSTALLDIRS=vendor NO_PERLLOCAL=1 NO_PACKLIST=1 ${EXTRA_CPANFLAGS}
 
 	# Makefile.PLs can exit with success without generating a
 	# Makefile, e.g. in cases of missing configure time
@@ -41,6 +40,16 @@
 	fi
 }
 
+do_configure_append_class-target() {
+       find . -name Makefile | xargs sed -E -i \
+           -e 's:LD_RUN_PATH ?= ?"?[^"]*"?::g'
+}
+
+do_configure_append_class-nativesdk() {
+       find . -name Makefile | xargs sed -E -i \
+           -e 's:LD_RUN_PATH ?= ?"?[^"]*"?::g'
+}
+
 cpan_do_compile () {
 	oe_runmake PASTHRU_INC="${CFLAGS}" LD="${CCLD}"
 }
diff --git a/poky/meta/classes/cpan_build.bbclass b/poky/meta/classes/cpan_build.bbclass
index fac074d..9a2ad89 100644
--- a/poky/meta/classes/cpan_build.bbclass
+++ b/poky/meta/classes/cpan_build.bbclass
@@ -30,7 +30,7 @@
 }
 
 cpan_build_do_compile () {
-        perl Build verbose=1
+        perl Build --perl "${bindir}/perl" verbose=1
 }
 
 cpan_build_do_install () {
diff --git a/poky/meta/classes/cross-canadian.bbclass b/poky/meta/classes/cross-canadian.bbclass
index ee8aa61..acde331 100644
--- a/poky/meta/classes/cross-canadian.bbclass
+++ b/poky/meta/classes/cross-canadian.bbclass
@@ -30,7 +30,7 @@
     if d.getVar("MODIFYTOS") != "1":
         return
 
-    if d.getVar("TCLIBC") == "baremetal":
+    if d.getVar("TCLIBC") in [ 'baremetal', 'newlib' ]:
         return
 
     tos = d.getVar("TARGET_OS")
diff --git a/poky/meta/classes/cross.bbclass b/poky/meta/classes/cross.bbclass
index 4e85cab..34d7951 100644
--- a/poky/meta/classes/cross.bbclass
+++ b/poky/meta/classes/cross.bbclass
@@ -37,7 +37,6 @@
 CFLAGS = "${BUILD_CFLAGS}"
 CXXFLAGS = "${BUILD_CFLAGS}"
 LDFLAGS = "${BUILD_LDFLAGS}"
-LDFLAGS_build-darwin = "-L${STAGING_LIBDIR_NATIVE}"
 
 TOOLCHAIN_OPTIONS = ""
 
diff --git a/poky/meta/classes/devicetree.bbclass b/poky/meta/classes/devicetree.bbclass
new file mode 100644
index 0000000..8fe5a5e
--- /dev/null
+++ b/poky/meta/classes/devicetree.bbclass
@@ -0,0 +1,143 @@
+# This bbclass implements device tree compliation for user provided device tree
+# sources. The compilation of the device tree sources is the same as the kernel
+# device tree compilation process, this includes being able to include sources
+# from the kernel such as soc dtsi files or header files such as gpio.h. In
+# addition to device trees this bbclass also handles compilation of device tree
+# overlays.
+#
+# The output of this class behaves similar to how kernel-devicetree.bbclass
+# operates in that the output files are installed into /boot/devicetree.
+# However this class on purpose separates the deployed device trees into the
+# 'devicetree' subdirectory. This prevents clashes with the kernel-devicetree
+# output. Additionally the device trees are populated into the sysroot for
+# access via the sysroot from within other recipes.
+
+SECTION ?= "bsp"
+
+# The default inclusion of kernel device tree includes and headers means that
+# device trees built with them are at least GPLv2 (and in some cases dual
+# licensed). Default to GPLv2 if the recipe does not specify a license.
+LICENSE ?= "GPLv2"
+LIC_FILES_CHKSUM ?= "file://${COMMON_LICENSE_DIR}/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6"
+
+INHIBIT_DEFAULT_DEPS = "1"
+DEPENDS += "dtc-native"
+
+inherit deploy kernel-arch
+
+COMPATIBLE_MACHINE ?= "^$"
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+SYSROOT_DIRS += "/boot/devicetree"
+FILES_${PN} = "/boot/devicetree/*.dtb /boot/devicetree/*.dtbo"
+
+S = "${WORKDIR}"
+B = "${WORKDIR}/build"
+
+# Default kernel includes, these represent what are normally used for in-kernel
+# sources.
+KERNEL_INCLUDE ??= " \
+        ${STAGING_KERNEL_DIR}/arch/${ARCH}/boot/dts \
+        ${STAGING_KERNEL_DIR}/arch/${ARCH}/boot/dts/* \
+        ${STAGING_KERNEL_DIR}/scripts/dtc/include-prefixes \
+        "
+
+DT_INCLUDE[doc] = "Search paths to be made available to both the device tree compiler and preprocessor for inclusion."
+DT_INCLUDE ?= "${DT_FILES_PATH} ${KERNEL_INCLUDE}"
+DT_FILES_PATH[doc] = "Defaults to source directory, can be used to select dts files that are not in source (e.g. generated)."
+DT_FILES_PATH ?= "${S}"
+
+DT_PADDING_SIZE[doc] = "Size of padding on the device tree blob, used as extra space typically for additional properties during boot."
+DT_PADDING_SIZE ??= "0x3000"
+DT_RESERVED_MAP[doc] = "Number of reserved map entires."
+DT_RESERVED_MAP ??= "8"
+DT_BOOT_CPU[doc] = "The boot cpu, defaults to 0"
+DT_BOOT_CPU ??= "0"
+
+DTC_FLAGS ?= "-R ${DT_RESERVED_MAP} -b ${DT_BOOT_CPU}"
+DTC_PPFLAGS ?= "-nostdinc -undef -D__DTS__ -x assembler-with-cpp"
+DTC_BFLAGS ?= "-p ${DT_PADDING_SIZE}"
+DTC_OFLAGS ?= "-p 0 -@ -H epapr"
+
+python () {
+    if d.getVar("KERNEL_INCLUDE"):
+        # auto add dependency on kernel tree, but only if kernel include paths
+        # are specified.
+        d.appendVarFlag("do_compile", "depends", " virtual/kernel:do_configure")
+}
+
+def expand_includes(varname, d):
+    import glob
+    includes = set()
+    # expand all includes with glob
+    for i in (d.getVar(varname) or "").split():
+        for g in glob.glob(i):
+            if os.path.isdir(g): # only add directories to include path
+                includes.add(g)
+    return includes
+
+def devicetree_source_is_overlay(path):
+    # determine if a dts file is an overlay by checking if it uses "/plugin/;"
+    with open(path, "r") as f:
+        for i in f:
+            if i.startswith("/plugin/;"):
+                return True
+    return False
+
+def devicetree_compile(dtspath, includes, d):
+    import subprocess
+    dts = os.path.basename(dtspath)
+    dtname = os.path.splitext(dts)[0]
+    bb.note("Processing {0} [{1}]".format(dtname, dts))
+
+    # preprocess
+    ppargs = d.getVar("BUILD_CPP").split()
+    ppargs += (d.getVar("DTC_PPFLAGS") or "").split()
+    for i in includes:
+        ppargs.append("-I{0}".format(i))
+    ppargs += ["-o", "{0}.pp".format(dts), dtspath]
+    bb.note("Running {0}".format(" ".join(ppargs)))
+    subprocess.run(ppargs, check = True)
+
+    # determine if the file is an overlay or not (using the preprocessed file)
+    isoverlay = devicetree_source_is_overlay("{0}.pp".format(dts))
+
+    # compile
+    dtcargs = ["dtc"] + (d.getVar("DTC_FLAGS") or "").split()
+    if isoverlay:
+        dtcargs += (d.getVar("DTC_OFLAGS") or "").split()
+    else:
+        dtcargs += (d.getVar("DTC_BFLAGS") or "").split()
+    for i in includes:
+        dtcargs += ["-i", i]
+    dtcargs += ["-o", "{0}.{1}".format(dtname, "dtbo" if isoverlay else "dtb")]
+    dtcargs += ["-I", "dts", "-O", "dtb", "{0}.pp".format(dts)]
+    bb.note("Running {0}".format(" ".join(dtcargs)))
+    subprocess.run(dtcargs, check = True)
+
+python devicetree_do_compile() {
+    includes = expand_includes("DT_INCLUDE", d)
+    listpath = d.getVar("DT_FILES_PATH")
+    for dts in os.listdir(listpath):
+        if not dts.endswith(".dts"):
+            continue # skip non-.dts files
+        dtspath = os.path.join(listpath, dts)
+        devicetree_compile(dtspath, includes, d)
+}
+
+devicetree_do_install() {
+    for DTB_FILE in `ls *.dtb *.dtbo`; do
+        install -Dm 0644 ${B}/${DTB_FILE} ${D}/boot/devicetree/${DTB_FILE}
+    done
+}
+
+devicetree_do_deploy() {
+    for DTB_FILE in `ls *.dtb *.dtbo`; do
+        install -Dm 0644 ${B}/${DTB_FILE} ${DEPLOYDIR}/devicetree/${DTB_FILE}
+    done
+}
+addtask deploy before do_build after do_install
+
+EXPORT_FUNCTIONS do_compile do_install do_deploy
+
diff --git a/poky/meta/classes/devtool-source.bbclass b/poky/meta/classes/devtool-source.bbclass
index 56882a4..1372e32 100644
--- a/poky/meta/classes/devtool-source.bbclass
+++ b/poky/meta/classes/devtool-source.bbclass
@@ -90,11 +90,23 @@
                         fname in files])
         return ret
 
+    is_kernel_yocto = bb.data.inherits_class('kernel-yocto', d)
     # Move local source files into separate subdir
     recipe_patches = [os.path.basename(patch) for patch in
                         oe.recipeutils.get_recipe_patches(d)]
     local_files = oe.recipeutils.get_recipe_local_files(d)
 
+    if is_kernel_yocto:
+        for key in local_files.copy():
+            if key.endswith('scc'):
+                sccfile = open(local_files[key], 'r')
+                for l in sccfile:
+                    line = l.split()
+                    if line and line[0] in ('kconf', 'patch'):
+                        local_files[line[-1]] = os.path.join(os.path.dirname(local_files[key]), line[-1])
+                        shutil.copy2(os.path.join(os.path.dirname(local_files[key]), line[-1]), workdir)
+                sccfile.close()
+
     # Ignore local files with subdir={BP}
     srcabspath = os.path.abspath(srcsubdir)
     local_files = [fname for fname in local_files if
@@ -171,14 +183,14 @@
 
     extra_overrides = d.getVar('DEVTOOL_EXTRA_OVERRIDES')
     if extra_overrides:
-        extra_override_list = extra_overrides.split(':')
+        extra_overrides = set(extra_overrides.split(':'))
         devbranch = d.getVar('DEVTOOL_DEVBRANCH')
         default_overrides = d.getVar('OVERRIDES').split(':')
         no_overrides = []
         # First, we may have some overrides that are referred to in the recipe set in
         # our configuration, so we need to make a branch that excludes those
         for override in default_overrides:
-            if override not in extra_override_list:
+            if override not in extra_overrides:
                 no_overrides.append(override)
         if default_overrides != no_overrides:
             # Some overrides are active in the current configuration, so
@@ -196,7 +208,7 @@
         else:
             bb.process.run('git checkout %s -b devtool-no-overrides' % devbranch, cwd=srcsubdir)
 
-        for override in extra_override_list:
+        for override in extra_overrides:
             localdata = bb.data.createCopy(d)
             if override in default_overrides:
                 bb.process.run('git branch devtool-override-%s %s' % (override, devbranch), cwd=srcsubdir)
diff --git a/poky/meta/classes/distutils-common-base.bbclass b/poky/meta/classes/distutils-common-base.bbclass
index 824a1b6..94b5fd4 100644
--- a/poky/meta/classes/distutils-common-base.bbclass
+++ b/poky/meta/classes/distutils-common-base.bbclass
@@ -1,6 +1,18 @@
 export STAGING_INCDIR
 export STAGING_LIBDIR
 
+# LDSHARED is the ld *command* used to create shared library
+export LDSHARED  = "${CCLD} -shared"
+# LDXXSHARED is the ld *command* used to create shared library of C++
+# objects
+export LDCXXSHARED  = "${CXX} -shared"
+# CCSHARED are the C *flags* used to create objects to go into a shared
+# library (module)
+export CCSHARED  = "-fPIC -DPIC"
+# LINKFORSHARED are the flags passed to the $(CC) command that links
+# the python executable
+export LINKFORSHARED = "{SECURITY_CFLAGS} -Xlinker -export-dynamic"
+
 FILES_${PN} += "${libdir}/* ${libdir}/${PYTHON_DIR}/*"
 
 FILES_${PN}-staticdev += "\
diff --git a/poky/meta/classes/distutils.bbclass b/poky/meta/classes/distutils.bbclass
index 1930c35..9862731 100644
--- a/poky/meta/classes/distutils.bbclass
+++ b/poky/meta/classes/distutils.bbclass
@@ -4,20 +4,30 @@
 DISTUTILS_STAGE_HEADERS_ARGS ?= "--install-dir=${STAGING_INCDIR}/${PYTHON_DIR}"
 DISTUTILS_STAGE_ALL_ARGS ?= "--prefix=${STAGING_DIR_HOST}${prefix} \
     --install-data=${STAGING_DATADIR}"
-DISTUTILS_INSTALL_ARGS ?= "--prefix=${D}/${prefix} \
-    --install-data=${D}/${datadir}"
+DISTUTILS_INSTALL_ARGS ?= "--root=${D} \
+    --prefix=${prefix} \
+    --install-lib=${PYTHON_SITEPACKAGES_DIR} \
+    --install-data=${datadir}"
+
+distutils_do_configure() {
+        if [ "${CLEANBROKEN}" != "1" ] ; then
+                NO_FETCH_BUILD=1 \
+                ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py clean ${DISTUTILS_BUILD_ARGS}
+        fi
+}
 
 distutils_do_compile() {
+         NO_FETCH_BUILD=1 \
          STAGING_INCDIR=${STAGING_INCDIR} \
          STAGING_LIBDIR=${STAGING_LIBDIR} \
          ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py build ${DISTUTILS_BUILD_ARGS} || \
-         bbfatal_log "${PYTHON_PN} setup.py build execution failed."
+         bbfatal_log "'${PYTHON_PN} setup.py build ${DISTUTILS_BUILD_ARGS}' execution failed."
 }
 
 distutils_stage_headers() {
         install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
         ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install_headers ${DISTUTILS_STAGE_HEADERS_ARGS} || \
-        bbfatal_log "${PYTHON_PN} setup.py install_headers execution failed."
+        bbfatal_log "'${PYTHON_PN} setup.py install_headers ${DISTUTILS_STAGE_HEADERS_ARGS}' execution for stage_headers failed."
 }
 
 distutils_stage_all() {
@@ -26,7 +36,7 @@
         install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
         PYTHONPATH=${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR} \
         ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install ${DISTUTILS_STAGE_ALL_ARGS} || \
-        bbfatal_log "${PYTHON_PN} setup.py install (stage) execution failed."
+        bbfatal_log "'${PYTHON_PN} setup.py install ${DISTUTILS_STAGE_ALL_ARGS}' execution for stage_all failed."
 }
 
 distutils_do_install() {
@@ -34,8 +44,8 @@
         STAGING_INCDIR=${STAGING_INCDIR} \
         STAGING_LIBDIR=${STAGING_LIBDIR} \
         PYTHONPATH=${D}${PYTHON_SITEPACKAGES_DIR} \
-        ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install --install-lib=${D}/${PYTHON_SITEPACKAGES_DIR} ${DISTUTILS_INSTALL_ARGS} || \
-        bbfatal_log "${PYTHON_PN} setup.py install execution failed."
+        ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install ${DISTUTILS_INSTALL_ARGS} || \
+        bbfatal_log "'${PYTHON_PN} setup.py install ${DISTUTILS_INSTALL_ARGS}' execution failed."
 
         # support filenames with *spaces*
         # only modify file if it contains path  and recompile it
@@ -77,6 +87,6 @@
 	fi
 }
 
-EXPORT_FUNCTIONS do_compile do_install
+EXPORT_FUNCTIONS do_configure do_compile do_install
 
 export LDSHARED="${CCLD} -shared"
diff --git a/poky/meta/classes/distutils3.bbclass b/poky/meta/classes/distutils3.bbclass
index 6c30306..834e322 100644
--- a/poky/meta/classes/distutils3.bbclass
+++ b/poky/meta/classes/distutils3.bbclass
@@ -5,22 +5,32 @@
 DISTUTILS_STAGE_HEADERS_ARGS ?= "--install-dir=${STAGING_INCDIR}/${PYTHON_DIR}"
 DISTUTILS_STAGE_ALL_ARGS ?= "--prefix=${STAGING_DIR_HOST}${prefix} \
     --install-data=${STAGING_DATADIR}"
-DISTUTILS_INSTALL_ARGS ?= "--prefix=${D}/${prefix} \
-    --install-data=${D}/${datadir}"
+DISTUTILS_INSTALL_ARGS ?= "--root=${D} \
+    --prefix=${prefix} \
+    --install-lib=${PYTHON_SITEPACKAGES_DIR} \
+    --install-data=${datadir}"
+
+distutils3_do_configure() {
+	if [ "${CLEANBROKEN}" != "1" ] ; then
+		NO_FETCH_BUILD=1 \
+		${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py clean ${DISTUTILS_BUILD_ARGS}
+	fi
+}
 
 distutils3_do_compile() {
+        NO_FETCH_BUILD=1 \
         STAGING_INCDIR=${STAGING_INCDIR} \
         STAGING_LIBDIR=${STAGING_LIBDIR} \
         ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py \
         build ${DISTUTILS_BUILD_ARGS} || \
-        bbfatal_log "${PYTHON_PN} setup.py build_ext execution failed."
+        bbfatal_log "'${PYTHON_PN} setup.py build ${DISTUTILS_BUILD_ARGS}' execution failed."
 }
 distutils3_do_compile[vardepsexclude] = "MACHINE"
 
 distutils3_stage_headers() {
         install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
         ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install_headers ${DISTUTILS_STAGE_HEADERS_ARGS} || \
-        bbfatal_log "${PYTHON_PN} setup.py install_headers execution failed."
+        bbfatal_log "'${PYTHON_PN} setup.py install_headers ${DISTUTILS_STAGE_HEADERS_ARGS}' execution for stage_headers failed."
 }
 distutils3_stage_headers[vardepsexclude] = "MACHINE"
 
@@ -30,7 +40,7 @@
         install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
         PYTHONPATH=${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR} \
         ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install ${DISTUTILS_STAGE_ALL_ARGS} || \
-        bbfatal_log "${PYTHON_PN} setup.py install (stage) execution failed."
+        bbfatal_log "'${PYTHON_PN} setup.py install ${DISTUTILS_STAGE_ALL_ARGS}' execution for stage_all failed."
 }
 distutils3_stage_all[vardepsexclude] = "MACHINE"
 
@@ -39,8 +49,8 @@
         STAGING_INCDIR=${STAGING_INCDIR} \
         STAGING_LIBDIR=${STAGING_LIBDIR} \
         PYTHONPATH=${D}${PYTHON_SITEPACKAGES_DIR} \
-        ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install --install-lib=${D}/${PYTHON_SITEPACKAGES_DIR} ${DISTUTILS_INSTALL_ARGS} || \
-        bbfatal_log "${PYTHON_PN} setup.py install execution failed."
+        ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install ${DISTUTILS_INSTALL_ARGS} || \
+        bbfatal_log "'${PYTHON_PN} setup.py install ${DISTUTILS_INSTALL_ARGS}' execution failed."
 
         # support filenames with *spaces*
         find ${D} -name "*.py" -exec grep -q ${D} {} \; -exec sed -i -e s:${D}::g {} \;
@@ -71,6 +81,6 @@
 }
 distutils3_do_install[vardepsexclude] = "MACHINE"
 
-EXPORT_FUNCTIONS do_compile do_install
+EXPORT_FUNCTIONS do_configure do_compile do_install
 
 export LDSHARED="${CCLD} -shared"
diff --git a/poky/meta/classes/dos2unix.bbclass b/poky/meta/classes/dos2unix.bbclass
new file mode 100644
index 0000000..3fc17e2
--- /dev/null
+++ b/poky/meta/classes/dos2unix.bbclass
@@ -0,0 +1,14 @@
+# Class for use to convert all CRLF line terminators to LF
+# provided that some projects are being developed/maintained
+# on Windows so they have different line terminators(CRLF) vs
+# on Linux(LF), which can cause annoying patching errors during
+# git push/checkout processes.
+
+do_convert_crlf_to_lf[depends] += "dos2unix-native:do_populate_sysroot"
+
+# Convert CRLF line terminators to LF
+do_convert_crlf_to_lf () {
+	find ${S} -type f -exec dos2unix {} \;
+}
+
+addtask convert_crlf_to_lf after do_unpack before do_patch
diff --git a/poky/meta/classes/externalsrc.bbclass b/poky/meta/classes/externalsrc.bbclass
index 78a08c8..3618b99 100644
--- a/poky/meta/classes/externalsrc.bbclass
+++ b/poky/meta/classes/externalsrc.bbclass
@@ -77,6 +77,9 @@
             # Dummy value because the default function can't be called with blank SRC_URI
             d.setVar('SRCPV', '999')
 
+        if d.getVar('CONFIGUREOPT_DEPTRACK') == '--disable-dependency-tracking':
+            d.setVar('CONFIGUREOPT_DEPTRACK', '')
+
         tasks = filter(lambda k: d.getVarFlag(k, "task"), d.keys())
 
         for task in tasks:
diff --git a/poky/meta/classes/fontcache.bbclass b/poky/meta/classes/fontcache.bbclass
index e763311..f71a754 100644
--- a/poky/meta/classes/fontcache.bbclass
+++ b/poky/meta/classes/fontcache.bbclass
@@ -17,7 +17,7 @@
 FONTCONFIG_CACHE_ENV ?= "FC_DEBUG=1"
 fontcache_common() {
 if [ -n "$D" ] ; then
-	$INTERCEPT_DIR/postinst_intercept update_font_cache ${PKG} mlprefix=${MLPREFIX} \
+	$INTERCEPT_DIR/postinst_intercept update_font_cache ${PKG} mlprefix=${MLPREFIX} binprefix=${MLPREFIX} \
 		'bindir="${bindir}"' \
 		'libdir="${libdir}"' \
 		'base_libdir="${base_libdir}"' \
diff --git a/poky/meta/classes/gio-module-cache.bbclass b/poky/meta/classes/gio-module-cache.bbclass
index 0520c22..e429bd3 100644
--- a/poky/meta/classes/gio-module-cache.bbclass
+++ b/poky/meta/classes/gio-module-cache.bbclass
@@ -2,7 +2,6 @@
 inherit qemu
 
 GIO_MODULE_PACKAGES ??= "${PN}"
-GIO_MODULE_PACKAGES_class-nativesdk = ""
 
 gio_module_cache_common() {
 if [ "x$D" != "x" ]; then
diff --git a/poky/meta/classes/go.bbclass b/poky/meta/classes/go.bbclass
index d33d83e..af331f8 100644
--- a/poky/meta/classes/go.bbclass
+++ b/poky/meta/classes/go.bbclass
@@ -8,7 +8,7 @@
 export GOROOT
 export GOROOT_FINAL = "${libdir}/go"
 
-DEPENDS_GOLANG_class-target = "virtual/${TARGET_PREFIX}go virtual/${TARGET_PREFIX}go-runtime"
+DEPENDS_GOLANG_class-target = "virtual/${TUNE_PKGARCH}-go virtual/${TARGET_PREFIX}go-runtime"
 DEPENDS_GOLANG_class-native = "go-native"
 DEPENDS_GOLANG_class-nativesdk = "virtual/${TARGET_PREFIX}go-crosssdk virtual/${TARGET_PREFIX}go-runtime"
 
@@ -179,3 +179,13 @@
 
 INSANE_SKIP_${PN} += "ldflags"
 INSANE_SKIP_${PN}-ptest += "ldflags"
+
+# Add -buildmode=pie to GOBUILDFLAGS to satisfy "textrel" QA checking, but mips
+# doesn't support -buildmode=pie, so skip the QA checking for mips and its
+# variants.
+python() {
+    if 'mips' in d.getVar('TARGET_ARCH'):
+        d.appendVar('INSANE_SKIP_%s' % d.getVar('PN'), " textrel")
+    else:
+        d.appendVar('GOBUILDFLAGS', ' -buildmode=pie')
+}
diff --git a/poky/meta/classes/goarch.bbclass b/poky/meta/classes/goarch.bbclass
index f54c516..b2c94fa 100644
--- a/poky/meta/classes/goarch.bbclass
+++ b/poky/meta/classes/goarch.bbclass
@@ -33,9 +33,13 @@
 COMPATIBLE_HOST_powerpc = "null"
 COMPATIBLE_HOST_powerpc64 = "null"
 COMPATIBLE_HOST_mipsarchn32 = "null"
-ARM_INSTRUCTION_SET = "arm"
+
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
+ARM_INSTRUCTION_SET_armv6 = "arm"
+
 TUNE_CCARGS_remove = "-march=mips32r2"
-SECURITY_CFLAGS_mips = "${SECURITY_NOPIE_CFLAGS}"
+SECURITY_CFLAGS_mipsarch = "${SECURITY_NOPIE_CFLAGS}"
 SECURITY_NOPIE_CFLAGS ??= ""
 
 def go_map_arch(a, d):
diff --git a/poky/meta/classes/gobject-introspection.bbclass b/poky/meta/classes/gobject-introspection.bbclass
index b6160b8..a323c1f 100644
--- a/poky/meta/classes/gobject-introspection.bbclass
+++ b/poky/meta/classes/gobject-introspection.bbclass
@@ -40,4 +40,4 @@
     
 # .gir files go to dev package, as they're needed for developing (but not for
 # running) things that depends on introspection.
-FILES_${PN}-dev_append = " ${datadir}/gir-*/*.gir"
+FILES_${PN}-dev_append = " ${datadir}/gir-*/*.gir ${libdir}/gir-*/*.gir"
diff --git a/poky/meta/classes/gtk-immodules-cache.bbclass b/poky/meta/classes/gtk-immodules-cache.bbclass
index 3d82dbe..9bb0af8 100644
--- a/poky/meta/classes/gtk-immodules-cache.bbclass
+++ b/poky/meta/classes/gtk-immodules-cache.bbclass
@@ -10,53 +10,39 @@
 
 gtk_immodule_cache_postinst() {
 if [ "x$D" != "x" ]; then
-        if [ -x $D${bindir}/gtk-query-immodules-2.0 ]; then
-            IMFILES=$(ls $D${libdir}/gtk-2.0/*/immodules/*.so)
-            ${@qemu_run_binary(d, '$D', '${bindir}/gtk-query-immodules-2.0')} \
-                $IMFILES > $D${libdir}/gtk-2.0/2.10.0/immodules.cache 2>/dev/null &&
-                sed -i -e "s:$D::" $D${libdir}/gtk-2.0/2.10.0/immodules.cache
-        fi
-        if [ -x $D${bindir}/gtk-query-immodules-3.0 ]; then
-            IMFILES=$(ls $D${libdir}/gtk-3.0/*/immodules/*.so)
-            ${@qemu_run_binary(d, '$D', '${bindir}/gtk-query-immodules-3.0')} \
-                $IMFILES > $D${libdir}/gtk-3.0/3.0.0/immodules.cache 2>/dev/null &&
-                sed -i -e "s:$D::" $D${libdir}/gtk-3.0/3.0.0/immodules.cache
-        fi
-
-    [ $? -ne 0 ] && exit 1
-    exit 0
-fi
-if [ ! -z `which gtk-query-immodules-2.0` ]; then
-    gtk-query-immodules-2.0 > ${libdir}/gtk-2.0/2.10.0/immodules.cache
-fi
-if [ ! -z `which gtk-query-immodules-3.0` ]; then
-    gtk-query-immodules-3.0 > ${libdir}/gtk-3.0/3.0.0/immodules.cache
+    $INTERCEPT_DIR/postinst_intercept update_gtk_immodules_cache ${PKG} \
+            mlprefix=${MLPREFIX} \
+            binprefix=${MLPREFIX} \
+            libdir=${libdir} \
+            libexecdir=${libexecdir} \
+            base_libdir=${base_libdir} \
+            bindir=${bindir}
+else
+    if [ ! -z `which gtk-query-immodules-2.0` ]; then
+        gtk-query-immodules-2.0 > ${libdir}/gtk-2.0/2.10.0/immodules.cache
+    fi
+    if [ ! -z `which gtk-query-immodules-3.0` ]; then
+        gtk-query-immodules-3.0 > ${libdir}/gtk-3.0/3.0.0/immodules.cache
+    fi
 fi
 }
 
 gtk_immodule_cache_postrm() {
 if [ "x$D" != "x" ]; then
-        if [ -x $D${bindir}/gtk-query-immodules-2.0 ]; then
-            IMFILES=$(ls $D${libdir}/gtk-2.0/*/immodules/*.so)
-            ${@qemu_run_binary(d, '$D', '${bindir}/gtk-query-immodules-2.0')} \
-                $IMFILES > $D${libdir}/gtk-2.0/2.10.0/immodules.cache 2>/dev/null &&
-                sed -i -e "s:$D::" $D${libdir}/gtk-2.0/2.10.0/immodules.cache
-        fi
-        if [ -x $D${bindir}/gtk-query-immodules-3.0 ]; then
-            IMFILES=$(ls $D${libdir}/gtk-3.0/*/immodules/*.so)
-            ${@qemu_run_binary(d, '$D', '${bindir}/gtk-query-immodules-3.0')} \
-                $IMFILES > $D${libdir}/gtk-3.0/3.0.0/immodules.cache 2>/dev/null &&
-                sed -i -e "s:$D::" $D${libdir}/gtk-3.0/3.0.0/immodules.cache
-        fi
-
-    [ $? -ne 0 ] && exit 1
-    exit 0
-fi
-if [ ! -z `which gtk-query-immodules-2.0` ]; then
-    gtk-query-immodules-2.0 > ${libdir}/gtk-2.0/2.10.0/immodules.cache
-fi
-if [ ! -z `which gtk-query-immodules-3.0` ]; then
-    gtk-query-immodules-3.0 > ${libdir}/gtk-3.0/3.0.0/immodules.cache
+    $INTERCEPT_DIR/postinst_intercept update_gtk_immodules_cache ${PKG} \
+            mlprefix=${MLPREFIX} \
+            binprefix=${MLPREFIX} \
+            libdir=${libdir} \
+            libexecdir=${libexecdir} \
+            base_libdir=${base_libdir} \
+            bindir=${bindir}
+else
+    if [ ! -z `which gtk-query-immodules-2.0` ]; then
+        gtk-query-immodules-2.0 > ${libdir}/gtk-2.0/2.10.0/immodules.cache
+    fi
+    if [ ! -z `which gtk-query-immodules-3.0` ]; then
+        gtk-query-immodules-3.0 > ${libdir}/gtk-3.0/3.0.0/immodules.cache
+    fi
 fi
 }
 
diff --git a/poky/meta/classes/icecc.bbclass b/poky/meta/classes/icecc.bbclass
index 0ca8de8..b5a8457 100644
--- a/poky/meta/classes/icecc.bbclass
+++ b/poky/meta/classes/icecc.bbclass
@@ -171,7 +171,7 @@
     return "yes"
 
 def icecc_is_allarch(bb, d):
-    return d.getVar("PACKAGE_ARCH") == "all" or bb.data.inherits_class('allarch', d)
+    return d.getVar("PACKAGE_ARCH") == "all"
 
 def icecc_is_kernel(bb, d):
     return \
diff --git a/poky/meta/classes/image-live.bbclass b/poky/meta/classes/image-live.bbclass
index 966277c..af71be5 100644
--- a/poky/meta/classes/image-live.bbclass
+++ b/poky/meta/classes/image-live.bbclass
@@ -19,8 +19,6 @@
 
 # External variables (also used by syslinux.bbclass)
 # ${INITRD} - indicates a list of filesystem images to concatenate and use as an initrd (optional)
-# ${NOISO}  - skip building the ISO image if set to 1
-# ${NOHDD}  - skip building the HDD image if set to 1
 # ${HDDIMG_ID} - FAT image volume-id
 # ${ROOTFS} - indicates a filesystem image to include as the root filesystem (optional)
 
@@ -80,8 +78,8 @@
 }
 
 build_iso() {
-	# Only create an ISO if we have an INITRD and NOISO was not set
-	if [ -z "${INITRD}" ] || [ "${NOISO}" = "1" ]; then
+	# Only create an ISO if we have an INITRD and the live or iso image type was selected
+	if [ -z "${INITRD}" ] || [ "${@bb.utils.contains_any('IMAGE_FSTYPES', 'live iso', '1', '0', d)}" != "1" ]; then
 		bbnote "ISO image will not be created."
 		return
 	fi
@@ -217,7 +215,7 @@
 
 build_hddimg() {
 	# Create an HDD image
-	if [ "${NOHDD}" != "1" ] ; then
+	if [ "${@bb.utils.contains_any('IMAGE_FSTYPES', 'live hddimg', '1', '0', d)}" = "1" ] ; then
 		populate_live ${HDDDIR}
 
 		if [ "${PCBIOS}" = "1" ]; then
@@ -232,11 +230,11 @@
 		if [ -f ${HDDDIR}/rootfs.img ]; then
 			rootfs_img_size=`stat -c '%s' ${HDDDIR}/rootfs.img`
 			max_size=`expr 4 \* 1024 \* 1024 \* 1024`
-			if [ $rootfs_img_size -gt $max_size ]; then
-				bberror "${HDDDIR}/rootfs.img execeeds 4GB,"
-				bberror "this doesn't work on FAT filesystem, you can try either of:"
-				bberror "1) Reduce the size of rootfs.img"
-				bbfatal "2) Use iso, vmdk or vdi to instead of hddimg\n"
+			if [ $rootfs_img_size -ge $max_size ]; then
+				bberror "${HDDDIR}/rootfs.img rootfs size is greather than or equal to 4GB,"
+				bberror "and this doesn't work on a FAT filesystem. You can either:"
+				bberror "1) Reduce the size of rootfs.img, or,"
+				bbfatal "2) Use wic, vmdk or vdi instead of hddimg\n"
 			fi
 		fi
 
diff --git a/poky/meta/classes/image-mklibs.bbclass b/poky/meta/classes/image-mklibs.bbclass
index 5f6df1b..68e11d4 100644
--- a/poky/meta/classes/image-mklibs.bbclass
+++ b/poky/meta/classes/image-mklibs.bbclass
@@ -19,7 +19,7 @@
 		echo $i
 	done > ${WORKDIR}/mklibs/executables.list
 
-	dynamic_loader=$(linuxloader)
+	dynamic_loader=${@get_linuxloader(d)}
 
 	mklibs -v \
 		--ldlib ${dynamic_loader} \
diff --git a/poky/meta/classes/image-postinst-intercepts.bbclass b/poky/meta/classes/image-postinst-intercepts.bbclass
new file mode 100644
index 0000000..ed30bbd
--- /dev/null
+++ b/poky/meta/classes/image-postinst-intercepts.bbclass
@@ -0,0 +1,23 @@
+# Gather existing and candidate postinst intercepts from BBPATH
+POSTINST_INTERCEPTS_DIR ?= "${COREBASE}/scripts/postinst-intercepts"
+POSTINST_INTERCEPTS_PATHS ?= "${@':'.join('%s/postinst-intercepts' % p for p in '${BBPATH}'.split(':'))}:${POSTINST_INTERCEPTS_DIR}"
+
+python find_intercepts() {
+    intercepts = {}
+    search_paths = []
+    paths = d.getVar('POSTINST_INTERCEPTS_PATHS').split(':')
+    overrides = (':' + d.getVar('FILESOVERRIDES')).split(':') + ['']
+    search_paths = [os.path.join(p, op) for p in paths for op in overrides]
+    searched = oe.path.which_wild('*', ':'.join(search_paths), candidates=True)
+    files, chksums = [], []
+    for pathname, candidates in searched:
+        if os.path.isfile(pathname):
+            files.append(pathname)
+            chksums.append('%s:True' % pathname)
+            chksums.extend('%s:False' % c for c in candidates[:-1])
+
+    d.setVar('POSTINST_INTERCEPT_CHECKSUMS', ' '.join(chksums))
+    d.setVar('POSTINST_INTERCEPTS', ' '.join(files))
+}
+find_intercepts[eventmask] += "bb.event.RecipePreFinalise"
+addhandler find_intercepts
diff --git a/poky/meta/classes/image-prelink.bbclass b/poky/meta/classes/image-prelink.bbclass
index 6a8afa8..04dd57c 100644
--- a/poky/meta/classes/image-prelink.bbclass
+++ b/poky/meta/classes/image-prelink.bbclass
@@ -33,7 +33,7 @@
 	fi
 	cat ${STAGING_DIR_TARGET}${sysconfdir}/ld.so.conf >> $ldsoconf
 
-	dynamic_loader=$(linuxloader)
+	dynamic_loader=${@get_linuxloader(d)}
 
 	# prelink!
 	if [ "${BUILD_REPRODUCIBLE_BINARIES}" = "1" ]; then
diff --git a/poky/meta/classes/image.bbclass b/poky/meta/classes/image.bbclass
index 2247b30..452b1ad 100644
--- a/poky/meta/classes/image.bbclass
+++ b/poky/meta/classes/image.bbclass
@@ -1,9 +1,21 @@
-inherit rootfs_${IMAGE_PKGTYPE}
 
+IMAGE_CLASSES ??= ""
+
+# rootfs bootstrap install
+# warning -  image-container resets this
+ROOTFS_BOOTSTRAP_INSTALL = "run-postinsts"
+
+# Handle inherits of any of the image classes we need
+IMGCLASSES = "rootfs_${IMAGE_PKGTYPE} image_types ${IMAGE_CLASSES}"
 # Only Linux SDKs support populate_sdk_ext, fall back to populate_sdk_base
 # in the non-Linux SDK_OS case, such as mingw32
-SDKEXTCLASS ?= "${@['populate_sdk_base', 'populate_sdk_ext']['linux' in d.getVar("SDK_OS")]}"
-inherit ${SDKEXTCLASS}
+IMGCLASSES += "${@['populate_sdk_base', 'populate_sdk_ext']['linux' in d.getVar("SDK_OS")]}"
+IMGCLASSES += "${@bb.utils.contains_any('IMAGE_FSTYPES', 'live iso hddimg', 'image-live', '', d)}"
+IMGCLASSES += "${@bb.utils.contains('IMAGE_FSTYPES', 'container', 'image-container', '', d)}"
+IMGCLASSES += "image_types_wic"
+IMGCLASSES += "rootfs-postcommands"
+IMGCLASSES += "image-postinst-intercepts"
+inherit ${IMGCLASSES}
 
 TOOLCHAIN_TARGET_TASK += "${PACKAGE_INSTALL}"
 TOOLCHAIN_TARGET_TASK_ATTEMPTONLY += "${PACKAGE_INSTALL_ATTEMPTONLY}"
@@ -11,25 +23,23 @@
 
 LICENSE ?= "MIT"
 PACKAGES = ""
-DEPENDS += "${MLPREFIX}qemuwrapper-cross depmodwrapper-cross"
+DEPENDS += "${@' '.join(["%s-qemuwrapper-cross" % m for m in d.getVar("MULTILIB_VARIANTS").split()])} qemuwrapper-cross depmodwrapper-cross cross-localedef-native"
 RDEPENDS += "${PACKAGE_INSTALL} ${LINGUAS_INSTALL}"
 RRECOMMENDS += "${PACKAGE_INSTALL_ATTEMPTONLY}"
+PATH_prepend = "${@":".join(all_multilib_tune_values(d, 'STAGING_BINDIR_CROSS').split())}:"
 
 INHIBIT_DEFAULT_DEPS = "1"
 
-TESTIMAGECLASS = "${@oe.utils.conditional('TEST_IMAGE', '1', 'testimage-auto', '', d)}"
-inherit ${TESTIMAGECLASS}
-
 # IMAGE_FEATURES may contain any available package group
 IMAGE_FEATURES ?= ""
 IMAGE_FEATURES[type] = "list"
-IMAGE_FEATURES[validitems] += "debug-tweaks read-only-rootfs empty-root-password allow-empty-password post-install-logging"
+IMAGE_FEATURES[validitems] += "debug-tweaks read-only-rootfs empty-root-password allow-empty-password allow-root-login post-install-logging"
 
 # Generate companion debugfs?
 IMAGE_GEN_DEBUGFS ?= "0"
 
-# rootfs bootstrap install
-ROOTFS_BOOTSTRAP_INSTALL = "run-postinsts"
+# These pacackages will be installed as additional into debug rootfs
+IMAGE_INSTALL_DEBUGFS ?= ""
 
 # These packages will be removed from a read-only rootfs after all other
 # packages have been installed
@@ -117,7 +127,7 @@
                  'IMAGE_ROOTFS_MAXSIZE','IMAGE_NAME','IMAGE_LINK_NAME','IMAGE_MANIFEST','DEPLOY_DIR_IMAGE','IMAGE_FSTYPES','IMAGE_INSTALL_COMPLEMENTARY','IMAGE_LINGUAS',
                  'MULTILIBRE_ALLOW_REP','MULTILIB_TEMP_ROOTFS','MULTILIB_VARIANTS','MULTILIBS','ALL_MULTILIB_PACKAGE_ARCHS','MULTILIB_GLOBAL_VARIANTS','BAD_RECOMMENDATIONS','NO_RECOMMENDATIONS',
                  'PACKAGE_ARCHS','PACKAGE_CLASSES','TARGET_VENDOR','TARGET_ARCH','TARGET_OS','OVERRIDES','BBEXTENDVARIANT','FEED_DEPLOYDIR_BASE_URI','INTERCEPT_DIR','USE_DEVFS',
-                 'CONVERSIONTYPES', 'IMAGE_GEN_DEBUGFS', 'ROOTFS_RO_UNNEEDED', 'IMGDEPLOYDIR', 'PACKAGE_EXCLUDE_COMPLEMENTARY', 'REPRODUCIBLE_TIMESTAMP_ROOTFS']
+                 'CONVERSIONTYPES', 'IMAGE_GEN_DEBUGFS', 'ROOTFS_RO_UNNEEDED', 'IMGDEPLOYDIR', 'PACKAGE_EXCLUDE_COMPLEMENTARY', 'REPRODUCIBLE_TIMESTAMP_ROOTFS', 'IMAGE_INSTALL_DEBUGFS']
     variables.extend(rootfs_command_variables(d))
     variables.extend(variable_depends(d))
     return " ".join(variables)
@@ -126,23 +136,6 @@
 
 do_build[depends] += "virtual/kernel:do_deploy"
 
-def build_live(d):
-    if bb.utils.contains("IMAGE_FSTYPES", "live", "live", "0", d) == "0": # live is not set but hob might set iso or hddimg
-        d.setVar('NOISO', bb.utils.contains('IMAGE_FSTYPES', "iso", "0", "1", d))
-        d.setVar('NOHDD', bb.utils.contains('IMAGE_FSTYPES', "hddimg", "0", "1", d))
-        if d.getVar('NOISO') == "0" or d.getVar('NOHDD') == "0":
-            return "image-live"
-        return ""
-    return "image-live"
-
-IMAGE_TYPE_live = "${@build_live(d)}"
-inherit ${IMAGE_TYPE_live}
-
-IMAGE_TYPE_container = '${@bb.utils.contains("IMAGE_FSTYPES", "container", "image-container", "", d)}'
-inherit ${IMAGE_TYPE_container}
-
-IMAGE_TYPE_wic = "image_types_wic"
-inherit ${IMAGE_TYPE_wic}
 
 python () {
     def extraimage_getdepends(task):
@@ -151,7 +144,6 @@
             deps += " %s:%s" % (dep, task)
         return deps
 
-    d.appendVarFlag('do_image', 'depends', extraimage_getdepends('do_populate_lic'))
     d.appendVarFlag('do_image_complete', 'depends', extraimage_getdepends('do_populate_sysroot'))
 
     deps = " " + imagetypes_getdepends(d)
@@ -177,9 +169,6 @@
     check_image_features(d)
 }
 
-IMAGE_CLASSES += "image_types"
-inherit ${IMAGE_CLASSES}
-
 IMAGE_POSTPROCESS_COMMAND ?= ""
 
 # some default locales
@@ -191,8 +180,6 @@
 # aren't yet available.
 PSEUDO_PASSWD = "${IMAGE_ROOTFS}:${STAGING_DIR_NATIVE}"
 
-inherit rootfs-postcommands
-
 PACKAGE_EXCLUDE ??= ""
 PACKAGE_EXCLUDE[type] = "list"
 
@@ -262,6 +249,7 @@
 do_rootfs[dirs] = "${TOPDIR}"
 do_rootfs[cleandirs] += "${S} ${IMGDEPLOYDIR}"
 do_rootfs[umask] = "022"
+do_rootfs[file-checksums] += "${POSTINST_INTERCEPT_CHECKSUMS}"
 addtask rootfs after do_prepare_recipe_sysroot
 
 fakeroot python do_image () {
@@ -666,7 +654,10 @@
 reproducible_final_image_task () {
     if [ "${BUILD_REPRODUCIBLE_BINARIES}" = "1" ]; then
         if [ "$REPRODUCIBLE_TIMESTAMP_ROOTFS" = "" ]; then
-            REPRODUCIBLE_TIMESTAMP_ROOTFS=`git log -1 --pretty=%ct`
+            REPRODUCIBLE_TIMESTAMP_ROOTFS=`git -C "${COREBASE}" log -1 --pretty=%ct 2>/dev/null` || true
+            if [ "${REPRODUCIBLE_TIMESTAMP_ROOTFS}" = "" ]; then
+                REPRODUCIBLE_TIMESTAMP_ROOTFS=`stat -c%Y ${@bb.utils.which(d.getVar("BBPATH"), "conf/bitbake.conf")}`
+            fi
         fi
         # Set mtime of all files to a reproducible value
         bbnote "reproducible_final_image_task: mtime set to $REPRODUCIBLE_TIMESTAMP_ROOTFS"
diff --git a/poky/meta/classes/image_types.bbclass b/poky/meta/classes/image_types.bbclass
index 00a00d3..05e5b0a 100644
--- a/poky/meta/classes/image_types.bbclass
+++ b/poky/meta/classes/image_types.bbclass
@@ -154,7 +154,7 @@
 	local ubinize_args="$2"
     
         # Added prompt error message for ubi and ubifs image creation.
-        if [ -z "$mkubifs_args"] || [ -z "$ubinize_args" ]; then
+        if [ -z "$mkubifs_args" ] || [ -z "$ubinize_args" ]; then
             bbfatal "MKUBIFS_ARGS and UBINIZE_ARGS have to be set, see http://www.linux-mtd.infradead.org/faq/ubifs.html for details"
         fi
     
diff --git a/poky/meta/classes/insane.bbclass b/poky/meta/classes/insane.bbclass
index eb2d967..4644221 100644
--- a/poky/meta/classes/insane.bbclass
+++ b/poky/meta/classes/insane.bbclass
@@ -46,139 +46,6 @@
 
 UNKNOWN_CONFIGURE_WHITELIST ?= "--enable-nls --disable-nls --disable-silent-rules --disable-dependency-tracking --with-libtool-sysroot --disable-static"
 
-#
-# dictionary for elf headers
-#
-# feel free to add and correct.
-#
-#           TARGET_OS  TARGET_ARCH   MACHINE, OSABI, ABIVERSION, Little Endian, 32bit?
-def package_qa_get_machine_dict(d):
-    machdata = {
-            "darwin9" : { 
-                        "arm" :       (40,     0,    0,          True,          32),
-                      },
-            "eabi" : {
-                        "arm" :       (40,     0,    0,          True,          32),
-                      },
-            "elf" : {
-                        "aarch64" :   (183,    0,    0,          True,          64),
-                        "aarch64_be" :(183,    0,    0,          False,         64),
-                        "i586" :      (3,      0,    0,          True,          32),
-                        "x86_64":     (62,     0,    0,          True,          64),
-                        "epiphany":   (4643,   0,    0,          True,          32),
-                        "mips":       ( 8,     0,    0,          False,         32),
-                        "mipsel":     ( 8,     0,    0,          True,          32),
-                        "microblaze":  (189,   0,    0,          False,         32),
-                        "microblazeeb":(189,   0,    0,          False,         32),
-                        "microblazeel":(189,   0,    0,          True,          32),
-                        "riscv32":    (243,    0,    0,          True,          32),
-                        "riscv64":    (243,    0,    0,          True,          64),
-                      },
-            "linux" : { 
-                        "aarch64" :   (183,    0,    0,          True,          64),
-                        "aarch64_be" :(183,    0,    0,          False,         64),
-                        "arm" :       (40,    97,    0,          True,          32),
-                        "armeb":      (40,    97,    0,          False,         32),
-                        "powerpc":    (20,     0,    0,          False,         32),
-                        "powerpc64":  (21,     0,    0,          False,         64),
-                        "i386":       ( 3,     0,    0,          True,          32),
-                        "i486":       ( 3,     0,    0,          True,          32),
-                        "i586":       ( 3,     0,    0,          True,          32),
-                        "i686":       ( 3,     0,    0,          True,          32),
-                        "x86_64":     (62,     0,    0,          True,          64),
-                        "ia64":       (50,     0,    0,          True,          64),
-                        "alpha":      (36902,  0,    0,          True,          64),
-                        "hppa":       (15,     3,    0,          False,         32),
-                        "m68k":       ( 4,     0,    0,          False,         32),
-                        "mips":       ( 8,     0,    0,          False,         32),
-                        "mipsel":     ( 8,     0,    0,          True,          32),
-                        "mips64":     ( 8,     0,    0,          False,         64),
-                        "mips64el":   ( 8,     0,    0,          True,          64),
-                        "mipsisa32r6":   ( 8,  0,    0,          False,         32),
-                        "mipsisa32r6el": ( 8,  0,    0,          True,          32),
-                        "mipsisa64r6":   ( 8,  0,    0,          False,         64),
-                        "mipsisa64r6el": ( 8,  0,    0,          True,          64),
-                        "nios2":      (113,    0,    0,          True,          32),
-                        "riscv32":    (243,    0,    0,          True,          32),
-                        "riscv64":    (243,    0,    0,          True,          64),
-                        "s390":       (22,     0,    0,          False,         32),
-                        "sh4":        (42,     0,    0,          True,          32),
-                        "sparc":      ( 2,     0,    0,          False,         32),
-                        "microblaze":  (189,   0,    0,          False,         32),
-                        "microblazeeb":(189,   0,    0,          False,         32),
-                        "microblazeel":(189,   0,    0,          True,          32),
-                      },
-            "linux-musl" : { 
-                        "aarch64" :   (183,    0,    0,            True,          64),
-                        "aarch64_be" :(183,    0,    0,            False,         64),
-                        "arm" :       (  40,    97,    0,          True,          32),
-                        "armeb":      (  40,    97,    0,          False,         32),
-                        "powerpc":    (  20,     0,    0,          False,         32),
-                        "i386":       (   3,     0,    0,          True,          32),
-                        "i486":       (   3,     0,    0,          True,          32),
-                        "i586":       (   3,     0,    0,          True,          32),
-                        "i686":       (   3,     0,    0,          True,          32),
-                        "x86_64":     (  62,     0,    0,          True,          64),
-                        "mips":       (   8,     0,    0,          False,         32),
-                        "mipsel":     (   8,     0,    0,          True,          32),
-                        "mips64":     (   8,     0,    0,          False,         64),
-                        "mips64el":   (   8,     0,    0,          True,          64),
-                        "microblaze":  (189,     0,    0,          False,         32),
-                        "microblazeeb":(189,     0,    0,          False,         32),
-                        "microblazeel":(189,     0,    0,          True,          32),
-                        "riscv32":    (243,      0,    0,          True,          32),
-                        "riscv64":    (243,      0,    0,          True,          64),
-                        "sh4":        (  42,     0,    0,          True,          32),
-                      },
-            "uclinux-uclibc" : {
-                        "bfin":       ( 106,     0,    0,          True,         32),
-                      }, 
-            "linux-gnueabi" : {
-                        "arm" :       (40,     0,    0,          True,          32),
-                        "armeb" :     (40,     0,    0,          False,         32),
-                      },
-            "linux-musleabi" : {
-                        "arm" :       (40,     0,    0,          True,          32),
-                        "armeb" :     (40,     0,    0,          False,         32),
-                      },
-            "linux-gnuspe" : {
-                        "powerpc":    (20,     0,    0,          False,         32),
-                      },
-            "linux-muslspe" : {
-                        "powerpc":    (20,     0,    0,          False,         32),
-                      },
-            "linux-gnu" :       {
-                        "powerpc":    (20,     0,    0,          False,         32),
-                        "sh4":        (42,     0,    0,          True,          32),
-                      },
-            "linux-gnu_ilp32" :     {
-                        "aarch64" :   (183,    0,    0,          True,          32),
-                      },
-            "linux-gnux32" :       {
-                        "x86_64":     (62,     0,    0,          True,          32),
-                      },
-            "linux-muslx32" :       {
-                        "x86_64":     (62,     0,    0,          True,          32),
-                      },
-            "linux-gnun32" :       {
-                        "mips64":       ( 8,     0,    0,          False,         32),
-                        "mips64el":     ( 8,     0,    0,          True,          32),
-                        "mipsisa64r6":  ( 8,     0,    0,          False,         32),
-                        "mipsisa64r6el":( 8,     0,    0,          True,          32),
-                      },
-        }
-
-    # Add in any extra user supplied data which may come from a BSP layer, removing the
-    # need to always change this class directly
-    extra_machdata = (d.getVar("PACKAGEQA_EXTRA_MACHDEFFUNCS") or "").split()
-    for m in extra_machdata:
-        call = m + "(machdata, d)"
-        locs = { "machdata" : machdata, "d" : d}
-        machdata = bb.utils.better_eval(call, locs)
-
-    return machdata
-
-
 def package_qa_clean_path(path, d, pkg=None):
     """
     Remove redundant paths from the path for display.  If pkg isn't set then
@@ -403,7 +270,7 @@
     """
     Check if archs are compatible
     """
-    import re
+    import re, oe.elf
 
     if not elf:
         return
@@ -430,12 +297,14 @@
 
     #if this will throw an exception, then fix the dict above
     (machine, osabi, abiversion, littleendian, bits) \
-        = package_qa_get_machine_dict(d)[target_os][target_arch]
+        = oe.elf.machine_dict(d)[target_os][target_arch]
 
     # Check the architecture and endiannes of the binary
     is_32 = (("virtual/kernel" in provides) or bb.data.inherits_class("module", d)) and \
-            (target_os == "linux-gnux32" or target_os == "linux-muslx32" or target_os == "linux-gnu_ilp32" or re.match('mips64.*32', d.getVar('DEFAULTTUNE')))
-    if not ((machine == elf.machine()) or is_32):
+            (target_os == "linux-gnux32" or target_os == "linux-muslx32" or \
+            target_os == "linux-gnu_ilp32" or re.match('mips64.*32', d.getVar('DEFAULTTUNE')))
+    is_bpf = (oe.qa.elf_machine_to_string(elf.machine()) == "BPF")
+    if not ((machine == elf.machine()) or is_32 or is_bpf):
         package_qa_add_message(messages, "arch", "Architecture did not match (%s, expected %s) on %s" % \
                  (oe.qa.elf_machine_to_string(elf.machine()), oe.qa.elf_machine_to_string(machine), package_qa_clean_path(path,d)))
     elif not ((bits == elf.abiSize()) or is_32):
@@ -599,7 +468,7 @@
         return
 
     if not lic_files and d.getVar('SRC_URI'):
-        sane = package_qa_handle_error("license-checksum", pn + ": Recipe file fetches files and does not have license file information (LIC_FILES_CHKSUM)", d)
+        sane &= package_qa_handle_error("license-checksum", pn + ": Recipe file fetches files and does not have license file information (LIC_FILES_CHKSUM)", d)
 
     srcdir = d.getVar('S')
     corebase_licensefile = d.getVar('COREBASE') + "/LICENSE"
@@ -607,11 +476,11 @@
         try:
             (type, host, path, user, pswd, parm) = bb.fetch.decodeurl(url)
         except bb.fetch.MalformedUrl:
-            sane = package_qa_handle_error("license-checksum", pn + ": LIC_FILES_CHKSUM contains an invalid URL: " + url, d)
+            sane &= package_qa_handle_error("license-checksum", pn + ": LIC_FILES_CHKSUM contains an invalid URL: " + url, d)
             continue
         srclicfile = os.path.join(srcdir, path)
         if not os.path.isfile(srclicfile):
-            package_qa_handle_error("license-checksum", pn + ": LIC_FILES_CHKSUM points to an invalid file: " + srclicfile, d)
+            sane &= package_qa_handle_error("license-checksum", pn + ": LIC_FILES_CHKSUM points to an invalid file: " + srclicfile, d)
             continue
 
         if (srclicfile == corebase_licensefile):
@@ -695,7 +564,7 @@
             else:
                 msg = pn + ": LIC_FILES_CHKSUM is not specified for " +  url
                 msg = msg + "\n" + pn + ": The md5 checksum is " + md5chksum
-            sane = package_qa_handle_error("license-checksum", msg, d)
+            sane &= package_qa_handle_error("license-checksum", msg, d)
 
     if not sane:
         bb.fatal("Fatal QA errors found, failing task.")
@@ -732,14 +601,14 @@
                     file_content = file_content.replace(recipesysroot, "")
                     if workdir in file_content:
                         error_msg = "%s failed sanity test (workdir) in path %s" % (file,root)
-                        sane = package_qa_handle_error("la", error_msg, d)
+                        sane &= package_qa_handle_error("la", error_msg, d)
             elif file.endswith(".pc"):
                 with open(path) as f:
                     file_content = f.read()
                     file_content = file_content.replace(recipesysroot, "")
                     if pkgconfigcheck in file_content:
                         error_msg = "%s failed sanity test (tmpdir) in path %s" % (file,root)
-                        sane = package_qa_handle_error("pkgconfig", error_msg, d)
+                        sane &= package_qa_handle_error("pkgconfig", error_msg, d)
 
     return sane
 
diff --git a/poky/meta/classes/kernel-arch.bbclass b/poky/meta/classes/kernel-arch.bbclass
index 09793fc..07ec242 100644
--- a/poky/meta/classes/kernel-arch.bbclass
+++ b/poky/meta/classes/kernel-arch.bbclass
@@ -22,12 +22,14 @@
     valid_archs = d.getVar('valid_archs').split()
 
     if   re.match('(i.86|athlon|x86.64)$', a):  return 'x86'
+    elif re.match('arceb$', a):                 return 'arc'
     elif re.match('armeb$', a):                 return 'arm'
     elif re.match('aarch64$', a):               return 'arm64'
     elif re.match('aarch64_be$', a):            return 'arm64'
     elif re.match('aarch64_ilp32$', a):         return 'arm64'
     elif re.match('aarch64_be_ilp32$', a):      return 'arm64'
     elif re.match('mips(isa|)(32|64|)(r6|)(el|)$', a):      return 'mips'
+    elif re.match('mcf', a):                    return 'm68k'
     elif re.match('riscv(32|64|)(eb|)$', a):    return 'riscv'
     elif re.match('p(pc|owerpc)(|64)', a):      return 'powerpc'
     elif re.match('sh(3|4)$', a):               return 'sh'
diff --git a/poky/meta/classes/kernel-artifact-names.bbclass b/poky/meta/classes/kernel-artifact-names.bbclass
new file mode 100644
index 0000000..bbeecba
--- /dev/null
+++ b/poky/meta/classes/kernel-artifact-names.bbclass
@@ -0,0 +1,18 @@
+KERNEL_ARTIFACT_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}${IMAGE_VERSION_SUFFIX}"
+KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}"
+
+KERNEL_IMAGE_NAME ?= "${KERNEL_ARTIFACT_NAME}"
+KERNEL_IMAGE_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}"
+
+KERNEL_DTB_NAME ?= "${KERNEL_ARTIFACT_NAME}"
+KERNEL_DTB_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}"
+
+KERNEL_FIT_NAME ?= "${KERNEL_ARTIFACT_NAME}"
+KERNEL_FIT_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}"
+
+MODULE_TARBALL_NAME ?= "${KERNEL_ARTIFACT_NAME}"
+MODULE_TARBALL_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}"
+MODULE_TARBALL_DEPLOY ?= "1"
+
+INITRAMFS_NAME ?= "initramfs-${KERNEL_ARTIFACT_NAME}"
+INITRAMFS_LINK_NAME ?= "initramfs-${KERNEL_ARTIFACT_LINK_NAME}"
diff --git a/poky/meta/classes/kernel-devicetree.bbclass b/poky/meta/classes/kernel-devicetree.bbclass
index 4f80cc6..867b776 100644
--- a/poky/meta/classes/kernel-devicetree.bbclass
+++ b/poky/meta/classes/kernel-devicetree.bbclass
@@ -10,21 +10,21 @@
 KERNEL_DEVICETREE_BUNDLE ?= "0"
 
 normalize_dtb () {
-	DTB="$1"
-	if echo ${DTB} | grep -q '/dts/'; then
-		bbwarn "${DTB} contains the full path to the the dts file, but only the dtb name should be used."
-		DTB=`basename ${DTB} | sed 's,\.dts$,.dtb,g'`
+	dtb="$1"
+	if echo $dtb | grep -q '/dts/'; then
+		bbwarn "$dtb contains the full path to the the dts file, but only the dtb name should be used."
+		dtb=`basename $dtb | sed 's,\.dts$,.dtb,g'`
 	fi
-	echo "${DTB}"
+	echo "$dtb"
 }
 
 get_real_dtb_path_in_kernel () {
-	DTB="$1"
-	DTB_PATH="${B}/arch/${ARCH}/boot/dts/${DTB}"
-	if [ ! -e "${DTB_PATH}" ]; then
-		DTB_PATH="${B}/arch/${ARCH}/boot/${DTB}"
+	dtb="$1"
+	dtb_path="${B}/arch/${ARCH}/boot/dts/$dtb"
+	if [ ! -e "$dtb_path" ]; then
+		dtb_path="${B}/arch/${ARCH}/boot/$dtb"
 	fi
-	echo "${DTB_PATH}"
+	echo "$dtb_path"
 }
 
 do_configure_append() {
@@ -50,61 +50,44 @@
 }
 
 do_compile_append() {
-	for DTB in ${KERNEL_DEVICETREE}; do
-		DTB=`normalize_dtb "${DTB}"`
-		oe_runmake ${DTB}
+	for dtbf in ${KERNEL_DEVICETREE}; do
+		dtb=`normalize_dtb "$dtbf"`
+		oe_runmake $dtb
 	done
 }
 
 do_install_append() {
-	for DTB in ${KERNEL_DEVICETREE}; do
-		DTB=`normalize_dtb "${DTB}"`
-		DTB_EXT=${DTB##*.}
-		DTB_PATH=`get_real_dtb_path_in_kernel "${DTB}"`
-		DTB_BASE_NAME=`basename ${DTB} ."${DTB_EXT}"`
-		install -m 0644 ${DTB_PATH} ${D}/${KERNEL_IMAGEDEST}/${DTB_BASE_NAME}.${DTB_EXT}
-		for type in ${KERNEL_IMAGETYPE_FOR_MAKE}; do
-			symlink_name=${type}"-"${KERNEL_IMAGE_SYMLINK_NAME}
-			DTB_SYMLINK_NAME=`echo ${symlink_name} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"`
-			ln -sf ${DTB_BASE_NAME}.${DTB_EXT} ${D}/${KERNEL_IMAGEDEST}/devicetree-${DTB_SYMLINK_NAME}.${DTB_EXT}
-
-			if [ "$type" = "zImage" ] && [ "${KERNEL_DEVICETREE_BUNDLE}" = "1" ]; then
-				cat ${D}/${KERNEL_IMAGEDEST}/$type \
-					${D}/${KERNEL_IMAGEDEST}/${DTB_BASE_NAME}.${DTB_EXT} \
-					> ${D}/${KERNEL_IMAGEDEST}/$type-${DTB_BASE_NAME}.${DTB_EXT}.bin
-			fi
-		done
+	for dtbf in ${KERNEL_DEVICETREE}; do
+		dtb=`normalize_dtb "$dtbf"`
+		dtb_ext=${dtb##*.}
+		dtb_base_name=`basename $dtb .$dtb_ext`
+		dtb_path=`get_real_dtb_path_in_kernel "$dtb"`
+		install -m 0644 $dtb_path ${D}/${KERNEL_IMAGEDEST}/$dtb_base_name.$dtb_ext
 	done
 }
 
 do_deploy_append() {
-	for DTB in ${KERNEL_DEVICETREE}; do
-		DTB=`normalize_dtb "${DTB}"`
-		DTB_EXT=${DTB##*.}
-		DTB_BASE_NAME=`basename ${DTB} ."${DTB_EXT}"`
+	for dtbf in ${KERNEL_DEVICETREE}; do
+		dtb=`normalize_dtb "$dtbf"`
+		dtb_ext=${dtb##*.}
+		dtb_base_name=`basename $dtb .$dtb_ext`
+		install -d ${DEPLOYDIR}
+		install -m 0644 ${D}/${KERNEL_IMAGEDEST}/$dtb_base_name.$dtb_ext ${DEPLOYDIR}/$dtb_base_name-${KERNEL_DTB_NAME}.$dtb_ext
+		ln -sf $dtb_base_name-${KERNEL_DTB_NAME}.$dtb_ext ${DEPLOYDIR}/$dtb_base_name.$dtb_ext
+		ln -sf $dtb_base_name-${KERNEL_DTB_NAME}.$dtb_ext ${DEPLOYDIR}/$dtb_base_name-${KERNEL_DTB_LINK_NAME}.$dtb_ext
 		for type in ${KERNEL_IMAGETYPE_FOR_MAKE}; do
-			base_name=${type}"-"${KERNEL_IMAGE_BASE_NAME}
-			symlink_name=${type}"-"${KERNEL_IMAGE_SYMLINK_NAME}
-			DTB_NAME=`echo ${base_name} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"`
-			DTB_SYMLINK_NAME=`echo ${symlink_name} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"`
-			DTB_PATH=`get_real_dtb_path_in_kernel "${DTB}"`
-			install -d ${DEPLOYDIR}
-			install -m 0644 ${DTB_PATH} ${DEPLOYDIR}/${DTB_NAME}.${DTB_EXT}
-			ln -sf ${DTB_NAME}.${DTB_EXT} ${DEPLOYDIR}/${DTB_SYMLINK_NAME}.${DTB_EXT}
-			ln -sf ${DTB_NAME}.${DTB_EXT} ${DEPLOYDIR}/${DTB_BASE_NAME}.${DTB_EXT}
-
 			if [ "$type" = "zImage" ] && [ "${KERNEL_DEVICETREE_BUNDLE}" = "1" ]; then
-				cat ${DEPLOYDIR}/$type \
-					${DEPLOYDIR}/${DTB_NAME}.${DTB_EXT} \
-					> ${DEPLOYDIR}/${DTB_NAME}.${DTB_EXT}.bin
-				ln -sf ${DTB_NAME}.${DTB_EXT}.bin ${DEPLOYDIR}/$type-${DTB_BASE_NAME}.${DTB_EXT}.bin
-
+				cat ${D}/${KERNEL_IMAGEDEST}/$type \
+					${DEPLOYDIR}/$dtb_base_name-${KERNEL_DTB_NAME}.$dtb_ext \
+					> ${DEPLOYDIR}/$type-$dtb_base_name-${KERNEL_DTB_NAME}.$dtb_ext.bin
+				ln -sf $type-$dtb_base_name-${KERNEL_DTB_NAME}.$dtb_ext.bin \
+					${DEPLOYDIR}/$type-$dtb_base_name-${KERNEL_DTB_LINK_NAME}.$dtb_ext.bin
 				if [ -e "${KERNEL_OUTPUT_DIR}/${type}.initramfs" ]; then
 					cat ${KERNEL_OUTPUT_DIR}/${type}.initramfs \
-						${DEPLOYDIR}/${DTB_NAME}.${DTB_EXT} \
-						> ${DEPLOYDIR}/${type}-${INITRAMFS_BASE_NAME}-${DTB_BASE_NAME}.${DTB_EXT}.bin
-					ln -sf ${type}-${INITRAMFS_BASE_NAME}-${DTB_BASE_NAME}.${DTB_EXT}.bin \
-					       ${DEPLOYDIR}/${type}-initramfs-${DTB_BASE_NAME}.${DTB_EXT}-${MACHINE}.bin
+						${DEPLOYDIR}/$dtb_base_name-${KERNEL_DTB_NAME}.$dtb_ext
+						>  ${DEPLOYDIR}/${type}-${INITRAMFS_NAME}-$dtb_base_name-${KERNEL_DTB_NAME}.$dtb_ext.bin
+					ln -sf ${type}-${INITRAMFS_NAME}-$dtb_base_name-${KERNEL_DTB_NAME}.$dtb_ext.bin \
+						${DEPLOYDIR}/${type}-${INITRAMFS_NAME}-$dtb_base_name-${KERNEL_DTB_LINK_NAME}.$dtb_ext.bin
 				fi
 			fi
 		done
diff --git a/poky/meta/classes/kernel-fitimage.bbclass b/poky/meta/classes/kernel-fitimage.bbclass
index 50a91e1..4c4fd99 100644
--- a/poky/meta/classes/kernel-fitimage.bbclass
+++ b/poky/meta/classes/kernel-fitimage.bbclass
@@ -1,4 +1,4 @@
-inherit kernel-uboot uboot-sign
+inherit kernel-uboot kernel-artifact-names uboot-sign
 
 python __anonymous () {
     kerneltypes = d.getVar('KERNEL_IMAGETYPES') or ""
@@ -135,6 +135,15 @@
 
 	dtb_csum="sha1"
 
+	dtb_loadline=""
+	dtb_ext=${DTB##*.}
+	if [ "${dtb_ext}" = "dtbo" ]; then
+		if [ -n "${UBOOT_DTBO_LOADADDRESS}" ]; then
+			dtb_loadline="load = <${UBOOT_DTBO_LOADADDRESS}>;"
+		fi
+	elif [ -n "${UBOOT_DTB_LOADADDRESS}" ]; then
+		dtb_loadline="load = <${UBOOT_DTB_LOADADDRESS}>;"
+	fi
 	cat << EOF >> ${1}
                 fdt@${2} {
                         description = "Flattened Device Tree blob";
@@ -142,6 +151,7 @@
                         type = "flat_dt";
                         arch = "${UBOOT_ARCH}";
                         compression = "none";
+                        ${dtb_loadline}
                         hash@1 {
                                 algo = "${dtb_csum}";
                         };
@@ -248,25 +258,34 @@
 	fi
 
 	# Test if we have any DTBs at all
-	conf_desc="Linux kernel"
-	kernel_line="kernel = \"kernel@${2}\";"
+	sep=""
+	conf_desc=""
+	kernel_line=""
 	fdt_line=""
 	ramdisk_line=""
 	setup_line=""
 	default_line=""
 
+	if [ -n "${2}" ]; then
+		conf_desc="Linux kernel"
+		sep=", "
+		kernel_line="kernel = \"kernel@${2}\";"
+	fi
+
 	if [ -n "${3}" ]; then
-		conf_desc="${conf_desc}, FDT blob"
+		conf_desc="${conf_desc}${sep}FDT blob"
+		sep=", "
 		fdt_line="fdt = \"fdt@${3}\";"
 	fi
 
 	if [ -n "${4}" ]; then
-		conf_desc="${conf_desc}, ramdisk"
+		conf_desc="${conf_desc}${sep}ramdisk"
+		sep=", "
 		ramdisk_line="ramdisk = \"ramdisk@${4}\";"
 	fi
 
 	if [ -n "${5}" ]; then
-		conf_desc="${conf_desc}, setup"
+		conf_desc="${conf_desc}${sep}setup"
 		setup_line="setup = \"setup@${5}\";"
 	fi
 
@@ -289,18 +308,26 @@
 
 	if [ ! -z "${conf_sign_keyname}" ] ; then
 
-		sign_line="sign-images = \"kernel\""
+		sign_line="sign-images = "
+		sep=""
+
+		if [ -n "${2}" ]; then
+			sign_line="${sign_line}${sep}\"kernel\""
+			sep=", "
+		fi
 
 		if [ -n "${3}" ]; then
-			sign_line="${sign_line}, \"fdt\""
+			sign_line="${sign_line}${sep}\"fdt\""
+			sep=", "
 		fi
 
 		if [ -n "${4}" ]; then
-			sign_line="${sign_line}, \"ramdisk\""
+			sign_line="${sign_line}${sep}\"ramdisk\""
+			sep=", "
 		fi
 
 		if [ -n "${5}" ]; then
-			sign_line="${sign_line}, \"setup\""
+			sign_line="${sign_line}${sep}\"setup\""
 		fi
 
 		sign_line="${sign_line};"
@@ -377,7 +404,7 @@
 	#
 	if [ "x${ramdiskcount}" = "x1" ] ; then
 		# Find and use the first initramfs image archive type we find
-		for img in cpio.lz4 cpio.lzo cpio.lzma cpio.xz cpio.gz cpio; do
+		for img in cpio.lz4 cpio.lzo cpio.lzma cpio.xz cpio.gz ext2.gz cpio; do
 			initramfs_path="${DEPLOY_DIR_IMAGE}/${INITRAMFS_IMAGE_NAME}.${img}"
 			echo "Using $initramfs_path"
 			if [ -e "${initramfs_path}" ]; then
@@ -403,7 +430,12 @@
 	if [ -n "${DTBS}" ]; then
 		i=1
 		for DTB in ${DTBS}; do
-			fitimage_emit_section_config ${1} "${kernelcount}" "${DTB}" "${ramdiskcount}" "${setupcount}" "`expr ${i} = ${dtbcount}`"
+			dtb_ext=${DTB##*.}
+			if [ "${dtb_ext}" = "dtbo" ]; then
+				fitimage_emit_section_config ${1} "" "${DTB}" "" "" "`expr ${i} = ${dtbcount}`"
+			else
+				fitimage_emit_section_config ${1} "${kernelcount}" "${DTB}" "${ramdiskcount}" "${setupcount}" "`expr ${i} = ${dtbcount}`"
+			fi
 			i=`expr ${i} + 1`
 		done
 	fi
@@ -427,7 +459,7 @@
 		uboot-mkimage \
 			${@'-D "${UBOOT_MKIMAGE_DTCOPTS}"' if len('${UBOOT_MKIMAGE_DTCOPTS}') else ''} \
 			-F -k "${UBOOT_SIGN_KEYDIR}" \
-			-K "${DEPLOY_DIR_IMAGE}/${UBOOT_DTB_BINARY}" \
+			${@'-K "${DEPLOY_DIR_IMAGE}/${UBOOT_DTB_BINARY}"' if len('${UBOOT_DTB_BINARY}') else ''} \
 			-r arch/${ARCH}/boot/${2}
 	fi
 }
@@ -456,32 +488,22 @@
 kernel_do_deploy_append() {
 	# Update deploy directory
 	if echo ${KERNEL_IMAGETYPES} | grep -wq "fitImage"; then
-		cd ${B}
 		echo "Copying fit-image.its source file..."
-		its_base_name="fitImage-its-${PV}-${PR}-${MACHINE}-${DATETIME}"
-		its_symlink_name=fitImage-its-${MACHINE}
-		install -m 0644 fit-image.its ${DEPLOYDIR}/${its_base_name}.its
-		linux_bin_base_name="fitImage-linux.bin-${PV}-${PR}-${MACHINE}-${DATETIME}"
-		linux_bin_symlink_name=fitImage-linux.bin-${MACHINE}
-		install -m 0644 linux.bin ${DEPLOYDIR}/${linux_bin_base_name}.bin
+		install -m 0644 ${B}/fit-image.its ${DEPLOYDIR}/fitImage-its-${KERNEL_FIT_NAME}.its
+		ln -snf fitImage-its-${KERNEL_FIT_NAME}.its ${DEPLOYDIR}/fitImage-its-${KERNEL_FIT_LINK_NAME}
+
+		echo "Copying linux.bin file..."
+		install -m 0644 ${B}/linux.bin ${DEPLOYDIR}/fitImage-linux.bin-${KERNEL_FIT_NAME}.bin
+		ln -snf fitImage-linux.bin-${KERNEL_FIT_NAME}.bin ${DEPLOYDIR}/fitImage-linux.bin-${KERNEL_FIT_LINK_NAME}
 
 		if [ -n "${INITRAMFS_IMAGE}" ]; then
 			echo "Copying fit-image-${INITRAMFS_IMAGE}.its source file..."
-			its_initramfs_base_name="fitImage-its-${INITRAMFS_IMAGE_NAME}-${PV}-${PR}-${DATETIME}"
-			its_initramfs_symlink_name=fitImage-its-${INITRAMFS_IMAGE_NAME}
-			install -m 0644 fit-image-${INITRAMFS_IMAGE}.its ${DEPLOYDIR}/${its_initramfs_base_name}.its
-			fit_initramfs_base_name="fitImage-${INITRAMFS_IMAGE_NAME}-${PV}-${PR}-${DATETIME}"
-			fit_initramfs_symlink_name=fitImage-${INITRAMFS_IMAGE_NAME}
-			install -m 0644 arch/${ARCH}/boot/fitImage-${INITRAMFS_IMAGE} ${DEPLOYDIR}/${fit_initramfs_base_name}.bin
-		fi
+			install -m 0644 ${B}/fit-image-${INITRAMFS_IMAGE}.its ${DEPLOYDIR}/fitImage-its-${INITRAMFS_IMAGE_NAME}-${KERNEL_FIT_NAME}.its
+			ln -snf fitImage-its-${INITRAMFS_IMAGE_NAME}-${KERNEL_FIT_NAME}.its ${DEPLOYDIR}/fitImage-its-${INITRAMFS_IMAGE_NAME}-${KERNEL_FIT_LINK_NAME}
 
-		cd ${DEPLOYDIR}
-		ln -sf ${its_base_name}.its ${its_symlink_name}.its
-		ln -sf ${linux_bin_base_name}.bin ${linux_bin_symlink_name}.bin
-
-		if [ -n "${INITRAMFS_IMAGE}" ]; then
-			ln -sf ${its_initramfs_base_name}.its ${its_initramfs_symlink_name}.its
-			ln -sf ${fit_initramfs_base_name}.bin ${fit_initramfs_symlink_name}.bin
+			echo "Copying fitImage-${INITRAMFS_IMAGE} file..."
+			install -m 0644 ${B}/arch/${ARCH}/boot/fitImage-${INITRAMFS_IMAGE} ${DEPLOYDIR}/fitImage-${INITRAMFS_IMAGE_NAME}-${KERNEL_FIT_NAME}.bin
+			ln -snf fitImage-${INITRAMFS_IMAGE_NAME}-${KERNEL_FIT_NAME}.bin ${DEPLOYDIR}/fitImage-${INITRAMFS_IMAGE_NAME}-${KERNEL_FIT_LINK_NAME}
 		fi
 	fi
 }
diff --git a/poky/meta/classes/kernel-uimage.bbclass b/poky/meta/classes/kernel-uimage.bbclass
index 1d8656e..c2de6bb 100644
--- a/poky/meta/classes/kernel-uimage.bbclass
+++ b/poky/meta/classes/kernel-uimage.bbclass
@@ -1,7 +1,7 @@
 inherit kernel-uboot
 
 python __anonymous () {
-    if "uImage" in (d.getVar('KERNEL_IMAGETYPES') or "").split():
+    if "uImage" in d.getVar('KERNEL_IMAGETYPES'):
         depends = d.getVar("DEPENDS")
         depends = "%s u-boot-mkimage-native" % depends
         d.setVar("DEPENDS", depends)
diff --git a/poky/meta/classes/kernel-yocto.bbclass b/poky/meta/classes/kernel-yocto.bbclass
index 82d8074..496c8a7 100644
--- a/poky/meta/classes/kernel-yocto.bbclass
+++ b/poky/meta/classes/kernel-yocto.bbclass
@@ -140,6 +140,8 @@
 			includes="$includes -I${WORKDIR}/$f/kernel-meta"
 	        elif [ -d "${WORKDIR}/$f" ]; then
 			includes="$includes -I${WORKDIR}/$f"
+		elif [ -d "${WORKDIR}/../oe-local-files/$f" ]; then
+			includes="$includes -I${WORKDIR}/../oe-local-files/$f"
 		fi
 	done
 	for s in ${sccs} ${patches}; do
@@ -319,7 +321,7 @@
 addtask kernel_configme before do_configure after do_patch
 
 python do_kernel_configcheck() {
-    import re, string, sys
+    import re, string, sys, subprocess
 
     # if KMETA isn't set globally by a recipe using this routine, we need to
     # set the default to 'meta'. Otherwise, kconf_check is not passed a valid
@@ -328,13 +330,24 @@
     if not os.path.exists(kmeta):
         kmeta = "." + kmeta
 
-    pathprefix = "export PATH=%s:%s; " % (d.getVar('PATH'), "${S}/scripts/util/")
+    s = d.getVar('S')
 
-    cmd = d.expand("scc --configs -o ${S}/.kernel-meta")
-    ret, configs = oe.utils.getstatusoutput("%s%s" % (pathprefix, cmd))
+    env = os.environ.copy()
+    env['PATH'] = "%s:%s%s" % (d.getVar('PATH'), s, "/scripts/util/")
 
-    cmd = d.expand("cd ${S}; kconf_check --report -o ${S}/%s/cfg/ ${B}/.config ${S} %s" % (kmeta,configs))
-    ret, result = oe.utils.getstatusoutput("%s%s" % (pathprefix, cmd))
+    try:
+        configs = subprocess.check_output(['scc', '--configs', '-o', s + '/.kernel-meta'], env=env).decode('utf-8')
+    except subprocess.CalledProcessError as e:
+        bb.fatal( "Cannot gather config fragments for audit: %s" % e.output.decode("utf-8") )
+
+    try:
+        subprocess.check_call(['kconf_check', '--report', '-o',
+                '%s/%s/cfg' % (s, kmeta), d.getVar('B') + '/.config', s, configs], cwd=s, env=env)
+    except subprocess.CalledProcessError:
+        # The configuration gathering can return different exit codes, but
+        # we interpret them based on the KCONF_AUDIT_LEVEL variable, so we catch
+        # everything here, and let the run continue.
+        pass
 
     config_check_visibility = int(d.getVar("KCONF_AUDIT_LEVEL") or 0)
     bsp_check_visibility = int(d.getVar("KCONF_BSP_AUDIT_LEVEL") or 0)
@@ -346,6 +359,27 @@
             with open (mismatch_file, "r") as myfile:
                 results = myfile.read()
                 bb.warn( "[kernel config]: specified values did not make it into the kernel's final configuration:\n\n%s" % results)
+
+    if bsp_check_visibility:
+        invalid_file = d.expand("${S}/%s/cfg/invalid.cfg" % kmeta)
+        if os.path.exists(invalid_file) and os.stat(invalid_file).st_size > 0:
+            with open (invalid_file, "r") as myfile:
+                results = myfile.read()
+                bb.warn( "[kernel config]: This BSP sets config options that are not offered anywhere within this kernel:\n\n%s" % results)
+        errors_file = d.expand("${S}/%s/cfg/fragment_errors.txt" % kmeta)
+        if os.path.exists(errors_file) and os.stat(errors_file).st_size > 0:
+            with open (errors_file, "r") as myfile:
+               results = myfile.read()
+               bb.warn( "[kernel config]: This BSP contains fragments with errors:\n\n%s" % results)
+
+    # if the audit level is greater than two, we report if a fragment has overriden
+    # a value from a base fragment. This is really only used for new kernel introduction
+    if bsp_check_visibility > 2:
+        redefinition_file = d.expand("${S}/%s/cfg/redefinition.txt" % kmeta)
+        if os.path.exists(redefinition_file) and os.stat(redefinition_file).st_size > 0:
+            with open (redefinition_file, "r") as myfile:
+                results = myfile.read()
+                bb.warn( "[kernel config]: This BSP has configuration options defined in more than one config, with differing values:\n\n%s" % results)
 }
 
 # Ensure that the branches (BSP and meta) are on the locations specified by
diff --git a/poky/meta/classes/kernel.bbclass b/poky/meta/classes/kernel.bbclass
index 7278514..e04d2fe 100644
--- a/poky/meta/classes/kernel.bbclass
+++ b/poky/meta/classes/kernel.bbclass
@@ -62,31 +62,36 @@
     type = d.getVar('KERNEL_IMAGETYPE') or ""
     alttype = d.getVar('KERNEL_ALT_IMAGETYPE') or ""
     types = d.getVar('KERNEL_IMAGETYPES') or ""
-    kname = d.getVar('KERNEL_PACKAGE_NAME') or "kernel"
     if type not in types.split():
         types = (type + ' ' + types).strip()
     if alttype not in types.split():
         types = (alttype + ' ' + types).strip()
     d.setVar('KERNEL_IMAGETYPES', types)
 
-    # some commonly used kernel images aren't generated by the kernel build system, such as vmlinux.gz
-    # typeformake lists only valid kernel make targets, and post processing can be done after the kernel
-    # is built (such as using gzip to compress vmlinux)
-    typeformake = types.replace('vmlinux.gz', 'vmlinux')
-    d.setVar('KERNEL_IMAGETYPE_FOR_MAKE', typeformake)
+    # KERNEL_IMAGETYPES may contain a mixture of image types supported directly
+    # by the kernel build system and types which are created by post-processing
+    # the output of the kernel build system (e.g. compressing vmlinux ->
+    # vmlinux.gz in kernel_do_compile()).
+    # KERNEL_IMAGETYPE_FOR_MAKE should contain only image types supported
+    # directly by the kernel build system.
+    if not d.getVar('KERNEL_IMAGETYPE_FOR_MAKE'):
+        typeformake = set()
+        for type in types.split():
+            if type == 'vmlinux.gz':
+                type = 'vmlinux'
+            typeformake.add(type)
+
+        d.setVar('KERNEL_IMAGETYPE_FOR_MAKE', ' '.join(sorted(typeformake)))
+
+    kname = d.getVar('KERNEL_PACKAGE_NAME') or "kernel"
+    imagedest = d.getVar('KERNEL_IMAGEDEST')
 
     for type in types.split():
         typelower = type.lower()
-        imagedest = d.getVar('KERNEL_IMAGEDEST')
-
         d.appendVar('PACKAGES', ' %s-image-%s' % (kname, typelower))
-
         d.setVar('FILES_' + kname + '-image-' + typelower, '/' + imagedest + '/' + type + '-${KERNEL_VERSION_NAME}' + ' /' + imagedest + '/' + type)
-
         d.appendVar('RDEPENDS_%s-image' % kname, ' %s-image-%s' % (kname, typelower))
-
         d.setVar('PKG_%s-image-%s' % (kname,typelower), '%s-image-%s-${KERNEL_VERSION_PKG_NAME}' % (kname, typelower))
-
         d.setVar('ALLOW_EMPTY_%s-image-%s' % (kname, typelower), '1')
 
     image = d.getVar('INITRAMFS_IMAGE')
@@ -159,7 +164,7 @@
 
 # The directory where built kernel lies in the kernel tree
 KERNEL_OUTPUT_DIR ?= "arch/${ARCH}/boot"
-KERNEL_IMAGEDEST = "boot"
+KERNEL_IMAGEDEST ?= "boot"
 
 #
 # configuration
@@ -224,39 +229,37 @@
 	echo "Finished copy of initramfs into ./usr"
 }
 
-INITRAMFS_BASE_NAME ?= "initramfs-${PV}-${PR}-${MACHINE}-${DATETIME}"
-INITRAMFS_BASE_NAME[vardepsexclude] = "DATETIME"
 do_bundle_initramfs () {
 	if [ ! -z "${INITRAMFS_IMAGE}" -a x"${INITRAMFS_IMAGE_BUNDLE}" = x1 ]; then
 		echo "Creating a kernel image with a bundled initramfs..."
 		copy_initramfs
 		# Backing up kernel image relies on its type(regular file or symbolic link)
 		tmp_path=""
-		for type in ${KERNEL_IMAGETYPE_FOR_MAKE} ; do
-			if [ -h ${KERNEL_OUTPUT_DIR}/$type ] ; then
-				linkpath=`readlink -n ${KERNEL_OUTPUT_DIR}/$type`
-				realpath=`readlink -fn ${KERNEL_OUTPUT_DIR}/$type`
+		for imageType in ${KERNEL_IMAGETYPE_FOR_MAKE} ; do
+			if [ -h ${KERNEL_OUTPUT_DIR}/$imageType ] ; then
+				linkpath=`readlink -n ${KERNEL_OUTPUT_DIR}/$imageType`
+				realpath=`readlink -fn ${KERNEL_OUTPUT_DIR}/$imageType`
 				mv -f $realpath $realpath.bak
-				tmp_path=$tmp_path" "$type"#"$linkpath"#"$realpath
-			elif [ -f ${KERNEL_OUTPUT_DIR}/$type ]; then
-				mv -f ${KERNEL_OUTPUT_DIR}/$type ${KERNEL_OUTPUT_DIR}/$type.bak
-				tmp_path=$tmp_path" "$type"##"
+				tmp_path=$tmp_path" "$imageType"#"$linkpath"#"$realpath
+			elif [ -f ${KERNEL_OUTPUT_DIR}/$imageType ]; then
+				mv -f ${KERNEL_OUTPUT_DIR}/$imageType ${KERNEL_OUTPUT_DIR}/$imageType.bak
+				tmp_path=$tmp_path" "$imageType"##"
 			fi
 		done
 		use_alternate_initrd=CONFIG_INITRAMFS_SOURCE=${B}/usr/${INITRAMFS_IMAGE_NAME}.cpio
 		kernel_do_compile
 		# Restoring kernel image
 		for tp in $tmp_path ; do
-			type=`echo $tp|cut -d "#" -f 1`
+			imageType=`echo $tp|cut -d "#" -f 1`
 			linkpath=`echo $tp|cut -d "#" -f 2`
 			realpath=`echo $tp|cut -d "#" -f 3`
 			if [ -n "$realpath" ]; then
 				mv -f $realpath $realpath.initramfs
 				mv -f $realpath.bak $realpath
-				ln -sf $linkpath.initramfs ${B}/${KERNEL_OUTPUT_DIR}/$type.initramfs
+				ln -sf $linkpath.initramfs ${B}/${KERNEL_OUTPUT_DIR}/$imageType.initramfs
 			else
-				mv -f ${KERNEL_OUTPUT_DIR}/$type ${KERNEL_OUTPUT_DIR}/$type.initramfs
-				mv -f ${KERNEL_OUTPUT_DIR}/$type.bak ${KERNEL_OUTPUT_DIR}/$type
+				mv -f ${KERNEL_OUTPUT_DIR}/$imageType ${KERNEL_OUTPUT_DIR}/$imageType.initramfs
+				mv -f ${KERNEL_OUTPUT_DIR}/$imageType.bak ${KERNEL_OUTPUT_DIR}/$imageType
 			fi
 		done
 	fi
@@ -283,7 +286,7 @@
 	if [ "${BUILD_REPRODUCIBLE_BINARIES}" = "1" ]; then
 		# kernel sources do not use do_unpack, so SOURCE_DATE_EPOCH may not
 		# be set....
-		if [ "$SOURCE_DATE_EPOCH" = "0" ]; then
+		if [ "${SOURCE_DATE_EPOCH}" = "" -o "${SOURCE_DATE_EPOCH}" = "0" ]; then
 			olddir=`pwd`
 			cd ${S}
 			SOURCE_DATE_EPOCH=`git log  -1 --pretty=%ct`
@@ -362,10 +365,10 @@
 	#
 	install -d ${D}/${KERNEL_IMAGEDEST}
 	install -d ${D}/boot
-	for type in ${KERNEL_IMAGETYPES} ; do
-		install -m 0644 ${KERNEL_OUTPUT_DIR}/${type} ${D}/${KERNEL_IMAGEDEST}/${type}-${KERNEL_VERSION}
+	for imageType in ${KERNEL_IMAGETYPES} ; do
+		install -m 0644 ${KERNEL_OUTPUT_DIR}/${imageType} ${D}/${KERNEL_IMAGEDEST}/${imageType}-${KERNEL_VERSION}
 		if [ "${KERNEL_PACKAGE_NAME}" = "kernel" ]; then
-			ln -sf ${type}-${KERNEL_VERSION} ${D}/${KERNEL_IMAGEDEST}/${type}
+			ln -sf ${imageType}-${KERNEL_VERSION} ${D}/${KERNEL_IMAGEDEST}/${imageType}
 		fi
 	done
 	install -m 0644 System.map ${D}/boot/System.map-${KERNEL_VERSION}
@@ -637,10 +640,10 @@
 			die "Invalid KERNEL_IMAGE_MAXSIZE: ${KERNEL_IMAGE_MAXSIZE}, should be an integer (The unit is Kbytes)"
 		fi
 		at_least_one_fits=
-		for type in ${KERNEL_IMAGETYPES} ; do
-			size=`du -ks ${B}/${KERNEL_OUTPUT_DIR}/$type | awk '{print $1}'`
+		for imageType in ${KERNEL_IMAGETYPES} ; do
+			size=`du -ks ${B}/${KERNEL_OUTPUT_DIR}/$imageType | awk '{print $1}'`
 			if [ $size -ge ${KERNEL_IMAGE_MAXSIZE} ]; then
-				bbwarn "This kernel $type (size=$size(K) > ${KERNEL_IMAGE_MAXSIZE}(K)) is too big for your device."
+				bbwarn "This kernel $imageType (size=$size(K) > ${KERNEL_IMAGE_MAXSIZE}(K)) is too big for your device."
 			else
 				at_least_one_fits=y
 			fi
@@ -654,16 +657,7 @@
 
 addtask sizecheck before do_install after do_strip
 
-KERNEL_IMAGE_BASE_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}-${DATETIME}"
-# Don't include the DATETIME variable in the sstate package signatures
-KERNEL_IMAGE_BASE_NAME[vardepsexclude] = "DATETIME"
-KERNEL_IMAGE_SYMLINK_NAME ?= "${MACHINE}"
-MODULE_IMAGE_BASE_NAME ?= "modules-${PKGE}-${PKGV}-${PKGR}-${MACHINE}-${DATETIME}"
-MODULE_IMAGE_BASE_NAME[vardepsexclude] = "DATETIME"
-MODULE_TARBALL_BASE_NAME ?= "${MODULE_IMAGE_BASE_NAME}.tgz"
-# Don't include the DATETIME variable in the sstate package signatures
-MODULE_TARBALL_SYMLINK_NAME ?= "modules-${MACHINE}.tgz"
-MODULE_TARBALL_DEPLOY ?= "1"
+inherit kernel-artifact-names
 
 kernel_do_deploy() {
 	deployDir="${DEPLOYDIR}"
@@ -672,34 +666,28 @@
 		mkdir "$deployDir"
 	fi
 
-	for type in ${KERNEL_IMAGETYPES} ; do
-		base_name=${type}-${KERNEL_IMAGE_BASE_NAME}
-		install -m 0644 ${KERNEL_OUTPUT_DIR}/${type} $deployDir/${base_name}.bin
+	for imageType in ${KERNEL_IMAGETYPES} ; do
+		base_name=${imageType}-${KERNEL_IMAGE_NAME}
+		install -m 0644 ${KERNEL_OUTPUT_DIR}/${imageType} $deployDir/${base_name}.bin
+		symlink_name=${imageType}-${KERNEL_IMAGE_LINK_NAME}
+		ln -sf ${base_name}.bin $deployDir/${symlink_name}.bin
+		ln -sf ${base_name}.bin $deployDir/${imageType}
 	done
+
 	if [ ${MODULE_TARBALL_DEPLOY} = "1" ] && (grep -q -i -e '^CONFIG_MODULES=y$' .config); then
-		mkdir -p ${D}/lib
-		tar -cvzf $deployDir/${MODULE_TARBALL_BASE_NAME} -C ${D} lib
-		ln -sf ${MODULE_TARBALL_BASE_NAME} $deployDir/${MODULE_TARBALL_SYMLINK_NAME}
+		mkdir -p ${D}${root_prefix}/lib
+		tar -cvzf $deployDir/modules-${MODULE_TARBALL_NAME}.tgz -C ${D}${root_prefix} lib
+		ln -sf modules-${MODULE_TARBALL_NAME}.tgz $deployDir/modules-${MODULE_TARBALL_LINK_NAME}.tgz
 	fi
 
-	for type in ${KERNEL_IMAGETYPES} ; do
-		base_name=${type}-${KERNEL_IMAGE_BASE_NAME}
-		symlink_name=${type}-${KERNEL_IMAGE_SYMLINK_NAME}
-		ln -sf ${base_name}.bin $deployDir/${symlink_name}.bin
-		ln -sf ${base_name}.bin $deployDir/${type}
-	done
-
-	cd ${B}
-	# Update deploy directory
-	for type in ${KERNEL_IMAGETYPES} ; do
-		if [ -e "${KERNEL_OUTPUT_DIR}/${type}.initramfs" ]; then
-			echo "Copying deploy ${type} kernel-initramfs image and setting up links..."
-			initramfs_base_name=${type}-${INITRAMFS_BASE_NAME}
-			initramfs_symlink_name=${type}-initramfs-${MACHINE}
-			install -m 0644 ${KERNEL_OUTPUT_DIR}/${type}.initramfs $deployDir/${initramfs_base_name}.bin
+	if [ ! -z "${INITRAMFS_IMAGE}" -a x"${INITRAMFS_IMAGE_BUNDLE}" = x1 ]; then
+		for imageType in ${KERNEL_IMAGETYPES} ; do
+			initramfs_base_name=${imageType}-${INITRAMFS_NAME}
+			initramfs_symlink_name=${imageType}-${INITRAMFS_LINK_NAME}
+			install -m 0644 ${KERNEL_OUTPUT_DIR}/${imageType}.initramfs $deployDir/${initramfs_base_name}.bin
 			ln -sf ${initramfs_base_name}.bin $deployDir/${initramfs_symlink_name}.bin
-		fi
-	done
+		done
+	fi
 }
 do_deploy[cleandirs] = "${DEPLOYDIR}"
 do_deploy[dirs] = "${DEPLOYDIR} ${B}"
diff --git a/poky/meta/classes/libc-common.bbclass b/poky/meta/classes/libc-common.bbclass
index 9ea2c03..0e351b6 100644
--- a/poky/meta/classes/libc-common.bbclass
+++ b/poky/meta/classes/libc-common.bbclass
@@ -1,9 +1,5 @@
 do_install() {
 	oe_runmake install_root=${D} install
-	for r in ${rpcsvc}; do
-		h=`echo $r|sed -e's,\.x$,.h,'`
-		install -m 0644 ${S}/sunrpc/rpcsvc/$h ${D}/${includedir}/rpcsvc/
-	done
 	install -Dm 0644 ${WORKDIR}/etc/ld.so.conf ${D}/${sysconfdir}/ld.so.conf
 	install -d ${D}${localedir}
 	make -f ${WORKDIR}/generate-supported.mk IN="${S}/localedata/SUPPORTED" OUT="${WORKDIR}/SUPPORTED"
diff --git a/poky/meta/classes/libc-package.bbclass b/poky/meta/classes/libc-package.bbclass
index 2e7cd25..9d09c7b 100644
--- a/poky/meta/classes/libc-package.bbclass
+++ b/poky/meta/classes/libc-package.bbclass
@@ -257,6 +257,8 @@
                 "mipsisa32r6el":  " --uint32-align=4 --little-endian ", \
                 "mips64el":" --uint32-align=4 --little-endian ", \
                 "mipsisa64r6el":" --uint32-align=4 --little-endian ", \
+                "riscv64": " --uint32-align=4 --little-endian ", \
+                "riscv32": " --uint32-align=4 --little-endian ", \
                 "i586":    " --uint32-align=4 --little-endian ", \
                 "i686":    " --uint32-align=4 --little-endian ", \
                 "x86_64":  " --uint32-align=4 --little-endian "  }
diff --git a/poky/meta/classes/license.bbclass b/poky/meta/classes/license.bbclass
index 5103ed8..4cf7f07 100644
--- a/poky/meta/classes/license.bbclass
+++ b/poky/meta/classes/license.bbclass
@@ -16,284 +16,6 @@
 do_populate_lic[dirs] = "${LICSSTATEDIR}/${PN}"
 do_populate_lic[cleandirs] = "${LICSSTATEDIR}"
 
-python write_package_manifest() {
-    # Get list of installed packages
-    license_image_dir = d.expand('${LICENSE_DIRECTORY}/${IMAGE_NAME}')
-    bb.utils.mkdirhier(license_image_dir)
-    from oe.rootfs import image_list_installed_packages
-    from oe.utils import format_pkg_list
-
-    pkgs = image_list_installed_packages(d)
-    output = format_pkg_list(pkgs)
-    open(os.path.join(license_image_dir, 'package.manifest'),
-        'w+').write(output)
-}
-
-python write_deploy_manifest() {
-    license_deployed_manifest(d)
-}
-
-python license_create_manifest() {
-    import oe.packagedata
-    from oe.rootfs import image_list_installed_packages
-
-    build_images_from_feeds = d.getVar('BUILD_IMAGES_FROM_FEEDS')
-    if build_images_from_feeds == "1":
-        return 0
-
-    pkg_dic = {}
-    for pkg in sorted(image_list_installed_packages(d)):
-        pkg_info = os.path.join(d.getVar('PKGDATA_DIR'),
-                                'runtime-reverse', pkg)
-        pkg_name = os.path.basename(os.readlink(pkg_info))
-
-        pkg_dic[pkg_name] = oe.packagedata.read_pkgdatafile(pkg_info)
-        if not "LICENSE" in pkg_dic[pkg_name].keys():
-            pkg_lic_name = "LICENSE_" + pkg_name
-            pkg_dic[pkg_name]["LICENSE"] = pkg_dic[pkg_name][pkg_lic_name]
-
-    rootfs_license_manifest = os.path.join(d.getVar('LICENSE_DIRECTORY'),
-                        d.getVar('IMAGE_NAME'), 'license.manifest')
-    write_license_files(d, rootfs_license_manifest, pkg_dic)
-}
-
-def write_license_files(d, license_manifest, pkg_dic):
-    import re
-
-    bad_licenses = (d.getVar("INCOMPATIBLE_LICENSE") or "").split()
-    bad_licenses = map(lambda l: canonical_license(d, l), bad_licenses)
-    bad_licenses = expand_wildcard_licenses(d, bad_licenses)
-
-    with open(license_manifest, "w") as license_file:
-        for pkg in sorted(pkg_dic):
-            if bad_licenses:
-                try:
-                    (pkg_dic[pkg]["LICENSE"], pkg_dic[pkg]["LICENSES"]) = \
-                        oe.license.manifest_licenses(pkg_dic[pkg]["LICENSE"],
-                        bad_licenses, canonical_license, d)
-                except oe.license.LicenseError as exc:
-                    bb.fatal('%s: %s' % (d.getVar('P'), exc))
-            else:
-                pkg_dic[pkg]["LICENSES"] = re.sub('[|&()*]', ' ', pkg_dic[pkg]["LICENSE"])
-                pkg_dic[pkg]["LICENSES"] = re.sub('  *', ' ', pkg_dic[pkg]["LICENSES"])
-                pkg_dic[pkg]["LICENSES"] = pkg_dic[pkg]["LICENSES"].split()
-
-            if not "IMAGE_MANIFEST" in pkg_dic[pkg]:
-                # Rootfs manifest
-                license_file.write("PACKAGE NAME: %s\n" % pkg)
-                license_file.write("PACKAGE VERSION: %s\n" % pkg_dic[pkg]["PV"])
-                license_file.write("RECIPE NAME: %s\n" % pkg_dic[pkg]["PN"])
-                license_file.write("LICENSE: %s\n\n" % pkg_dic[pkg]["LICENSE"])
-
-                # If the package doesn't contain any file, that is, its size is 0, the license
-                # isn't relevant as far as the final image is concerned. So doing license check
-                # doesn't make much sense, skip it.
-                if pkg_dic[pkg]["PKGSIZE_%s" % pkg] == "0":
-                    continue
-            else:
-                # Image manifest
-                license_file.write("RECIPE NAME: %s\n" % pkg_dic[pkg]["PN"])
-                license_file.write("VERSION: %s\n" % pkg_dic[pkg]["PV"])
-                license_file.write("LICENSE: %s\n" % pkg_dic[pkg]["LICENSE"])
-                license_file.write("FILES: %s\n\n" % pkg_dic[pkg]["FILES"])
-
-            for lic in pkg_dic[pkg]["LICENSES"]:
-                lic_file = os.path.join(d.getVar('LICENSE_DIRECTORY'),
-                                        pkg_dic[pkg]["PN"], "generic_%s" % 
-                                        re.sub('\+', '', lic))
-                # add explicity avoid of CLOSED license because isn't generic
-                if lic == "CLOSED":
-                   continue
-
-                if not os.path.exists(lic_file):
-                   bb.warn("The license listed %s was not in the "\ 
-                            "licenses collected for recipe %s" 
-                            % (lic, pkg_dic[pkg]["PN"]))
-
-    # Two options here:
-    # - Just copy the manifest
-    # - Copy the manifest and the license directories
-    # With both options set we see a .5 M increase in core-image-minimal
-    copy_lic_manifest = d.getVar('COPY_LIC_MANIFEST')
-    copy_lic_dirs = d.getVar('COPY_LIC_DIRS')
-    if copy_lic_manifest == "1":
-        rootfs_license_dir = os.path.join(d.getVar('IMAGE_ROOTFS'), 
-                                'usr', 'share', 'common-licenses')
-        bb.utils.mkdirhier(rootfs_license_dir)
-        rootfs_license_manifest = os.path.join(rootfs_license_dir,
-                os.path.split(license_manifest)[1])
-        if not os.path.exists(rootfs_license_manifest):
-            os.link(license_manifest, rootfs_license_manifest)
-
-        if copy_lic_dirs == "1":
-            for pkg in sorted(pkg_dic):
-                pkg_rootfs_license_dir = os.path.join(rootfs_license_dir, pkg)
-                bb.utils.mkdirhier(pkg_rootfs_license_dir)
-                pkg_license_dir = os.path.join(d.getVar('LICENSE_DIRECTORY'),
-                                            pkg_dic[pkg]["PN"]) 
-
-                pkg_manifest_licenses = [canonical_license(d, lic) \
-                        for lic in pkg_dic[pkg]["LICENSES"]]
-
-                licenses = os.listdir(pkg_license_dir)
-                for lic in licenses:
-                    rootfs_license = os.path.join(rootfs_license_dir, lic)
-                    pkg_license = os.path.join(pkg_license_dir, lic)
-                    pkg_rootfs_license = os.path.join(pkg_rootfs_license_dir, lic)
-
-                    if re.match("^generic_.*$", lic):
-                        generic_lic = canonical_license(d,
-                                re.search("^generic_(.*)$", lic).group(1))
-
-                        # Do not copy generic license into package if isn't
-                        # declared into LICENSES of the package.
-                        if not re.sub('\+$', '', generic_lic) in \
-                                [re.sub('\+', '', lic) for lic in \
-                                 pkg_manifest_licenses]:
-                            continue
-
-                        if oe.license.license_ok(generic_lic,
-                                bad_licenses) == False:
-                            continue
-
-                        if not os.path.exists(rootfs_license):
-                            os.link(pkg_license, rootfs_license)
-
-                        if not os.path.exists(pkg_rootfs_license):
-                            os.symlink(os.path.join('..', lic), pkg_rootfs_license)
-                    else:
-                        if (oe.license.license_ok(canonical_license(d,
-                                lic), bad_licenses) == False or
-                                os.path.exists(pkg_rootfs_license)):
-                            continue
-
-                        os.link(pkg_license, pkg_rootfs_license)
-
-
-def license_deployed_manifest(d):
-    """
-    Write the license manifest for the deployed recipes.
-    The deployed recipes usually includes the bootloader
-    and extra files to boot the target.
-    """
-
-    dep_dic = {}
-    man_dic = {}
-    lic_dir = d.getVar("LICENSE_DIRECTORY")
-
-    dep_dic = get_deployed_dependencies(d)
-    for dep in dep_dic.keys():
-        man_dic[dep] = {}
-        # It is necessary to mark this will be used for image manifest
-        man_dic[dep]["IMAGE_MANIFEST"] = True
-        man_dic[dep]["PN"] = dep
-        man_dic[dep]["FILES"] = \
-            " ".join(get_deployed_files(dep_dic[dep]))
-        with open(os.path.join(lic_dir, dep, "recipeinfo"), "r") as f:
-            for line in f.readlines():
-                key,val = line.split(": ", 1)
-                man_dic[dep][key] = val[:-1]
-
-    lic_manifest_dir = os.path.join(d.getVar('LICENSE_DIRECTORY'),
-                                    d.getVar('IMAGE_NAME'))
-    bb.utils.mkdirhier(lic_manifest_dir)
-    image_license_manifest = os.path.join(lic_manifest_dir, 'image_license.manifest')
-    write_license_files(d, image_license_manifest, man_dic)
-
-def get_deployed_dependencies(d):
-    """
-    Get all the deployed dependencies of an image
-    """
-
-    deploy = {}
-    # Get all the dependencies for the current task (rootfs).
-    # Also get EXTRA_IMAGEDEPENDS because the bootloader is
-    # usually in this var and not listed in rootfs.
-    # At last, get the dependencies from boot classes because
-    # it might contain the bootloader.
-    taskdata = d.getVar("BB_TASKDEPDATA", False)
-    depends = list(set([dep[0] for dep
-                    in list(taskdata.values())
-                    if not dep[0].endswith("-native")]))
-    extra_depends = d.getVar("EXTRA_IMAGEDEPENDS")
-    boot_depends = get_boot_dependencies(d)
-    depends.extend(extra_depends.split())
-    depends.extend(boot_depends)
-    depends = list(set(depends))
-
-    # To verify what was deployed it checks the rootfs dependencies against
-    # the SSTATE_MANIFESTS for "deploy" task.
-    # The manifest file name contains the arch. Because we are not running
-    # in the recipe context it is necessary to check every arch used.
-    sstate_manifest_dir = d.getVar("SSTATE_MANIFESTS")
-    archs = list(set(d.getVar("SSTATE_ARCHS").split()))
-    for dep in depends:
-        # Some recipes have an arch on their own, so we try that first.
-        special_arch = d.getVar("PACKAGE_ARCH_pn-%s" % dep)
-        if special_arch:
-            sstate_manifest_file = os.path.join(sstate_manifest_dir,
-                    "manifest-%s-%s.deploy" % (special_arch, dep))
-            if os.path.exists(sstate_manifest_file):
-                deploy[dep] = sstate_manifest_file
-                continue
-
-        for arch in archs:
-            sstate_manifest_file = os.path.join(sstate_manifest_dir,
-                    "manifest-%s-%s.deploy" % (arch, dep))
-            if os.path.exists(sstate_manifest_file):
-                deploy[dep] = sstate_manifest_file
-                break
-
-    return deploy
-get_deployed_dependencies[vardepsexclude] = "BB_TASKDEPDATA"
-
-def get_boot_dependencies(d):
-    """
-    Return the dependencies from boot tasks
-    """
-
-    depends = []
-    taskdepdata = d.getVar("BB_TASKDEPDATA", False)
-    # Only bootimg includes the depends flag
-    boot_depends_string = d.getVarFlag("do_bootimg", "depends") or ""
-    boot_depends = [dep.split(":")[0] for dep
-                in boot_depends_string.split()
-                if not dep.split(":")[0].endswith("-native")]
-    for dep in boot_depends:
-        info_file = os.path.join(d.getVar("LICENSE_DIRECTORY"),
-                dep, "recipeinfo")
-        # If the recipe and dependency name is the same
-        if os.path.exists(info_file):
-            depends.append(dep)
-        # We need to search for the provider of the dependency
-        else:
-            for taskdep in taskdepdata.values():
-                # The fifth field contains what the task provides
-                if dep in taskdep[4]:
-                    info_file = os.path.join(
-                            d.getVar("LICENSE_DIRECTORY"),
-                            taskdep[0], "recipeinfo")
-                    if os.path.exists(info_file):
-                        depends.append(taskdep[0])
-                        break
-    return depends
-get_boot_dependencies[vardepsexclude] = "BB_TASKDEPDATA"
-
-def get_deployed_files(man_file):
-    """
-    Get the files deployed from the sstate manifest
-    """
-
-    dep_files = []
-    excluded_files = []
-    with open(man_file, "r") as manifest:
-        all_files = manifest.read()
-    for f in all_files.splitlines():
-        if ((not (os.path.islink(f) or os.path.isdir(f))) and
-                not os.path.basename(f) in excluded_files):
-            dep_files.append(os.path.basename(f))
-    return dep_files
-
 python do_populate_lic() {
     """
     Populate LICENSE_DIRECTORY with licenses.
@@ -340,6 +62,9 @@
         # first in PACKAGES to be sure that nothing else gets LICENSE_FILES_DIRECTORY
         d.setVar('PACKAGES', "%s %s" % (pn_lic, packages))
         d.setVar('FILES_' + pn_lic, files)
+    for pn in packages.split():
+        if pn == pn_lic:
+            continue
         rrecommends_pn = d.getVar('RRECOMMENDS_' + pn)
         if rrecommends_pn:
             d.setVar('RRECOMMENDS_' + pn, "%s %s" % (pn_lic, rrecommends_pn))
@@ -674,11 +399,7 @@
 do_populate_lic[sstate-inputdirs] = "${LICSSTATEDIR}"
 do_populate_lic[sstate-outputdirs] = "${LICENSE_DIRECTORY}/"
 
-ROOTFS_POSTPROCESS_COMMAND_prepend = "write_package_manifest; license_create_manifest; "
-do_rootfs[recrdeptask] += "do_populate_lic"
-
-IMAGE_POSTPROCESS_COMMAND_prepend = "write_deploy_manifest; "
-do_image[recrdeptask] += "do_populate_lic"
+IMAGE_CLASSES_append = " license_image"
 
 python do_populate_lic_setscene () {
     sstate_setscene(d)
diff --git a/poky/meta/classes/license_image.bbclass b/poky/meta/classes/license_image.bbclass
new file mode 100644
index 0000000..f0fbb76
--- /dev/null
+++ b/poky/meta/classes/license_image.bbclass
@@ -0,0 +1,238 @@
+python write_package_manifest() {
+    # Get list of installed packages
+    license_image_dir = d.expand('${LICENSE_DIRECTORY}/${IMAGE_NAME}')
+    bb.utils.mkdirhier(license_image_dir)
+    from oe.rootfs import image_list_installed_packages
+    from oe.utils import format_pkg_list
+
+    pkgs = image_list_installed_packages(d)
+    output = format_pkg_list(pkgs)
+    open(os.path.join(license_image_dir, 'package.manifest'),
+        'w+').write(output)
+}
+
+python license_create_manifest() {
+    import oe.packagedata
+    from oe.rootfs import image_list_installed_packages
+
+    build_images_from_feeds = d.getVar('BUILD_IMAGES_FROM_FEEDS')
+    if build_images_from_feeds == "1":
+        return 0
+
+    pkg_dic = {}
+    for pkg in sorted(image_list_installed_packages(d)):
+        pkg_info = os.path.join(d.getVar('PKGDATA_DIR'),
+                                'runtime-reverse', pkg)
+        pkg_name = os.path.basename(os.readlink(pkg_info))
+
+        pkg_dic[pkg_name] = oe.packagedata.read_pkgdatafile(pkg_info)
+        if not "LICENSE" in pkg_dic[pkg_name].keys():
+            pkg_lic_name = "LICENSE_" + pkg_name
+            pkg_dic[pkg_name]["LICENSE"] = pkg_dic[pkg_name][pkg_lic_name]
+
+    rootfs_license_manifest = os.path.join(d.getVar('LICENSE_DIRECTORY'),
+                        d.getVar('IMAGE_NAME'), 'license.manifest')
+    write_license_files(d, rootfs_license_manifest, pkg_dic)
+}
+
+def write_license_files(d, license_manifest, pkg_dic):
+    import re
+
+    bad_licenses = (d.getVar("INCOMPATIBLE_LICENSE") or "").split()
+    bad_licenses = map(lambda l: canonical_license(d, l), bad_licenses)
+    bad_licenses = expand_wildcard_licenses(d, bad_licenses)
+
+    with open(license_manifest, "w") as license_file:
+        for pkg in sorted(pkg_dic):
+            if bad_licenses:
+                try:
+                    (pkg_dic[pkg]["LICENSE"], pkg_dic[pkg]["LICENSES"]) = \
+                        oe.license.manifest_licenses(pkg_dic[pkg]["LICENSE"],
+                        bad_licenses, canonical_license, d)
+                except oe.license.LicenseError as exc:
+                    bb.fatal('%s: %s' % (d.getVar('P'), exc))
+            else:
+                pkg_dic[pkg]["LICENSES"] = re.sub('[|&()*]', ' ', pkg_dic[pkg]["LICENSE"])
+                pkg_dic[pkg]["LICENSES"] = re.sub('  *', ' ', pkg_dic[pkg]["LICENSES"])
+                pkg_dic[pkg]["LICENSES"] = pkg_dic[pkg]["LICENSES"].split()
+
+            if not "IMAGE_MANIFEST" in pkg_dic[pkg]:
+                # Rootfs manifest
+                license_file.write("PACKAGE NAME: %s\n" % pkg)
+                license_file.write("PACKAGE VERSION: %s\n" % pkg_dic[pkg]["PV"])
+                license_file.write("RECIPE NAME: %s\n" % pkg_dic[pkg]["PN"])
+                license_file.write("LICENSE: %s\n\n" % pkg_dic[pkg]["LICENSE"])
+
+                # If the package doesn't contain any file, that is, its size is 0, the license
+                # isn't relevant as far as the final image is concerned. So doing license check
+                # doesn't make much sense, skip it.
+                if pkg_dic[pkg]["PKGSIZE_%s" % pkg] == "0":
+                    continue
+            else:
+                # Image manifest
+                license_file.write("RECIPE NAME: %s\n" % pkg_dic[pkg]["PN"])
+                license_file.write("VERSION: %s\n" % pkg_dic[pkg]["PV"])
+                license_file.write("LICENSE: %s\n" % pkg_dic[pkg]["LICENSE"])
+                license_file.write("FILES: %s\n\n" % pkg_dic[pkg]["FILES"])
+
+            for lic in pkg_dic[pkg]["LICENSES"]:
+                lic_file = os.path.join(d.getVar('LICENSE_DIRECTORY'),
+                                        pkg_dic[pkg]["PN"], "generic_%s" % 
+                                        re.sub('\+', '', lic))
+                # add explicity avoid of CLOSED license because isn't generic
+                if lic == "CLOSED":
+                   continue
+
+                if not os.path.exists(lic_file):
+                   bb.warn("The license listed %s was not in the "\ 
+                            "licenses collected for recipe %s" 
+                            % (lic, pkg_dic[pkg]["PN"]))
+
+    # Two options here:
+    # - Just copy the manifest
+    # - Copy the manifest and the license directories
+    # With both options set we see a .5 M increase in core-image-minimal
+    copy_lic_manifest = d.getVar('COPY_LIC_MANIFEST')
+    copy_lic_dirs = d.getVar('COPY_LIC_DIRS')
+    if copy_lic_manifest == "1":
+        rootfs_license_dir = os.path.join(d.getVar('IMAGE_ROOTFS'), 
+                                'usr', 'share', 'common-licenses')
+        bb.utils.mkdirhier(rootfs_license_dir)
+        rootfs_license_manifest = os.path.join(rootfs_license_dir,
+                os.path.split(license_manifest)[1])
+        if not os.path.exists(rootfs_license_manifest):
+            os.link(license_manifest, rootfs_license_manifest)
+
+        if copy_lic_dirs == "1":
+            for pkg in sorted(pkg_dic):
+                pkg_rootfs_license_dir = os.path.join(rootfs_license_dir, pkg)
+                bb.utils.mkdirhier(pkg_rootfs_license_dir)
+                pkg_license_dir = os.path.join(d.getVar('LICENSE_DIRECTORY'),
+                                            pkg_dic[pkg]["PN"]) 
+
+                pkg_manifest_licenses = [canonical_license(d, lic) \
+                        for lic in pkg_dic[pkg]["LICENSES"]]
+
+                licenses = os.listdir(pkg_license_dir)
+                for lic in licenses:
+                    rootfs_license = os.path.join(rootfs_license_dir, lic)
+                    pkg_license = os.path.join(pkg_license_dir, lic)
+                    pkg_rootfs_license = os.path.join(pkg_rootfs_license_dir, lic)
+
+                    if re.match("^generic_.*$", lic):
+                        generic_lic = canonical_license(d,
+                                re.search("^generic_(.*)$", lic).group(1))
+
+                        # Do not copy generic license into package if isn't
+                        # declared into LICENSES of the package.
+                        if not re.sub('\+$', '', generic_lic) in \
+                                [re.sub('\+', '', lic) for lic in \
+                                 pkg_manifest_licenses]:
+                            continue
+
+                        if oe.license.license_ok(generic_lic,
+                                bad_licenses) == False:
+                            continue
+
+                        if not os.path.exists(rootfs_license):
+                            os.link(pkg_license, rootfs_license)
+
+                        if not os.path.exists(pkg_rootfs_license):
+                            os.symlink(os.path.join('..', lic), pkg_rootfs_license)
+                    else:
+                        if (oe.license.license_ok(canonical_license(d,
+                                lic), bad_licenses) == False or
+                                os.path.exists(pkg_rootfs_license)):
+                            continue
+
+                        os.link(pkg_license, pkg_rootfs_license)
+
+
+def license_deployed_manifest(d):
+    """
+    Write the license manifest for the deployed recipes.
+    The deployed recipes usually includes the bootloader
+    and extra files to boot the target.
+    """
+
+    dep_dic = {}
+    man_dic = {}
+    lic_dir = d.getVar("LICENSE_DIRECTORY")
+
+    dep_dic = get_deployed_dependencies(d)
+    for dep in dep_dic.keys():
+        man_dic[dep] = {}
+        # It is necessary to mark this will be used for image manifest
+        man_dic[dep]["IMAGE_MANIFEST"] = True
+        man_dic[dep]["PN"] = dep
+        man_dic[dep]["FILES"] = \
+            " ".join(get_deployed_files(dep_dic[dep]))
+        with open(os.path.join(lic_dir, dep, "recipeinfo"), "r") as f:
+            for line in f.readlines():
+                key,val = line.split(": ", 1)
+                man_dic[dep][key] = val[:-1]
+
+    lic_manifest_dir = os.path.join(d.getVar('LICENSE_DIRECTORY'),
+                                    d.getVar('IMAGE_NAME'))
+    bb.utils.mkdirhier(lic_manifest_dir)
+    image_license_manifest = os.path.join(lic_manifest_dir, 'image_license.manifest')
+    write_license_files(d, image_license_manifest, man_dic)
+
+def get_deployed_dependencies(d):
+    """
+    Get all the deployed dependencies of an image
+    """
+
+    deploy = {}
+    # Get all the dependencies for the current task (rootfs).
+    # Also get EXTRA_IMAGEDEPENDS because the bootloader is
+    # usually in this var and not listed in rootfs.
+    # At last, get the dependencies from boot classes because
+    # it might contain the bootloader.
+    taskdata = d.getVar("BB_TASKDEPDATA", False)
+    depends = list(set([dep[0] for dep
+                    in list(taskdata.values())
+                    if not dep[0].endswith("-native")]))
+
+    # To verify what was deployed it checks the rootfs dependencies against
+    # the SSTATE_MANIFESTS for "deploy" task.
+    # The manifest file name contains the arch. Because we are not running
+    # in the recipe context it is necessary to check every arch used.
+    sstate_manifest_dir = d.getVar("SSTATE_MANIFESTS")
+    archs = list(set(d.getVar("SSTATE_ARCHS").split()))
+    for dep in depends:
+        for arch in archs:
+            sstate_manifest_file = os.path.join(sstate_manifest_dir,
+                    "manifest-%s-%s.deploy" % (arch, dep))
+            if os.path.exists(sstate_manifest_file):
+                deploy[dep] = sstate_manifest_file
+                break
+
+    return deploy
+get_deployed_dependencies[vardepsexclude] = "BB_TASKDEPDATA"
+
+def get_deployed_files(man_file):
+    """
+    Get the files deployed from the sstate manifest
+    """
+
+    dep_files = []
+    excluded_files = []
+    with open(man_file, "r") as manifest:
+        all_files = manifest.read()
+    for f in all_files.splitlines():
+        if ((not (os.path.islink(f) or os.path.isdir(f))) and
+                not os.path.basename(f) in excluded_files):
+            dep_files.append(os.path.basename(f))
+    return dep_files
+
+ROOTFS_POSTPROCESS_COMMAND_prepend = "write_package_manifest; license_create_manifest; "
+do_rootfs[recrdeptask] += "do_populate_lic"
+
+python do_populate_lic_deploy() {
+    license_deployed_manifest(d)
+}
+
+addtask populate_lic_deploy before do_build after do_image_complete
+do_populate_lic_deploy[recrdeptask] += "do_populate_lic do_deploy"
+
diff --git a/poky/meta/classes/linuxloader.bbclass b/poky/meta/classes/linuxloader.bbclass
index 8f30eb3..b4c4134 100644
--- a/poky/meta/classes/linuxloader.bbclass
+++ b/poky/meta/classes/linuxloader.bbclass
@@ -1,70 +1,61 @@
-LDSO_TCLIBC = "glibc"
-LDSO_TCLIBC_libc-musl = "musl"
-LDSO_TCLIBC_libc-baremetal = "musl"
+def get_musl_loader(d):
+    import re
+    dynamic_loader = None
 
-linuxloader_glibc () {
-	case ${TARGET_ARCH} in
-		powerpc | microblaze )
-			dynamic_loader="${base_libdir}/ld.so.1"
-			;;
-		mipsisa32r6el | mipsisa32r6 | mipsisa64r6el | mipsisa64r6)
-			dynamic_loader="${base_libdir}/ld-linux-mipsn8.so.1"
-			;;
-		mips* )
-			dynamic_loader="${base_libdir}/ld.so.1"
-			;;
-		powerpc64)
-			dynamic_loader="${base_libdir}/ld64.so.1"
-			;;
-		x86_64)
-			dynamic_loader="${base_libdir}/ld-linux-x86-64.so.2"
-			;;
-		i*86 )
-			dynamic_loader="${base_libdir}/ld-linux.so.2"
-			;;
-		arm )
-			dynamic_loader="${base_libdir}/ld-linux.so.3"
-			;;
-		* )
-			dynamic_loader="/unknown_dynamic_linker"
-			;;
-	esac
-	echo $dynamic_loader
-}
+    targetarch = d.getVar("TARGET_ARCH")
+    if targetarch.startswith("microblaze"):
+        dynamic_loader = "${base_libdir}/ld-musl-microblaze${@bb.utils.contains('TUNE_FEATURES', 'bigendian', '', 'el' ,d)}.so.1"
+    elif targetarch.startswith("mips"):
+        dynamic_loader = "${base_libdir}/ld-musl-mips${ABIEXTENSION}${MIPSPKGSFX_BYTE}${MIPSPKGSFX_R6}${MIPSPKGSFX_ENDIAN}${@['', '-sf'][d.getVar('TARGET_FPU') == 'soft']}.so.1"
+    elif targetarch == "powerpc":
+        dynamic_loader = "${base_libdir}/ld-musl-powerpc${@['', '-sf'][d.getVar('TARGET_FPU') == 'soft']}.so.1"
+    elif targetarch == "powerpc64":
+        dynamic_loader = "${base_libdir}/ld-musl-powerpc64.so.1"
+    elif targetarch == "x86_64":
+        dynamic_loader = "${base_libdir}/ld-musl-x86_64.so.1"
+    elif re.search("i.86", targetarch):
+        dynamic_loader = "${base_libdir}/ld-musl-i386.so.1"
+    elif targetarch.startswith("arm"):
+        dynamic_loader = "${base_libdir}/ld-musl-arm${ARMPKGSFX_ENDIAN}${ARMPKGSFX_EABI}.so.1"
+    elif targetarch.startswith("aarch64"):
+        dynamic_loader = "${base_libdir}/ld-musl-aarch64${ARMPKGSFX_ENDIAN_64}.so.1"
+    return dynamic_loader
 
-linuxloader_musl () {
-	case ${TARGET_ARCH} in
-		microblaze* )
-			dynamic_loader="${base_libdir}/ld-musl-microblaze${@bb.utils.contains('TUNE_FEATURES', 'bigendian', '', 'el' ,d)}.so.1"
-			;;
-		mips* )
-			dynamic_loader="${base_libdir}/ld-musl-mips${ABIEXTENSION}${MIPSPKGSFX_BYTE}${MIPSPKGSFX_R6}${MIPSPKGSFX_ENDIAN}${@['', '-sf'][d.getVar('TARGET_FPU') == 'soft']}.so.1"
-			;;
-		powerpc )
-			dynamic_loader="${base_libdir}/ld-musl-powerpc${@['', '-sf'][d.getVar('TARGET_FPU') == 'soft']}.so.1"
-			;;
-		powerpc64 )
-			dynamic_loader="${base_libdir}/ld-musl-powerpc64.so.1"
-			;;
-		x86_64 )
-			dynamic_loader="${base_libdir}/ld-musl-x86_64.so.1"
-			;;
-		i*86 )
-			dynamic_loader="${base_libdir}/ld-musl-i386.so.1"
-			;;
-		arm* )
-			dynamic_loader="${base_libdir}/ld-musl-arm${ARMPKGSFX_ENDIAN}${ARMPKGSFX_EABI}.so.1"
-			;;
-		aarch64* )
-			dynamic_loader="${base_libdir}/ld-musl-aarch64${ARMPKGSFX_ENDIAN_64}.so.1"
-			;;
-		* )
-			dynamic_loader="/unknown_dynamic_linker"
-			;;
-	esac
-	echo $dynamic_loader
-}
+def get_glibc_loader(d):
+    import re
 
-linuxloader () {
-	linuxloader_${LDSO_TCLIBC}
-}
+    dynamic_loader = None
+    targetarch = d.getVar("TARGET_ARCH")
+    if targetarch in ["powerpc", "microblaze"]:
+        dynamic_loader = "${base_libdir}/ld.so.1"
+    elif targetarch in ["mipsisa32r6el", "mipsisa32r6", "mipsisa64r6el", "mipsisa64r6"]:
+        dynamic_loader = "${base_libdir}/ld-linux-mipsn8.so.1"
+    elif targetarch.startswith("mips"):
+        dynamic_loader = "${base_libdir}/ld.so.1"
+    elif targetarch == "powerpc64":
+        dynamic_loader = "${base_libdir}/ld64.so.1"
+    elif targetarch == "x86_64":
+        dynamic_loader = "${base_libdir}/ld-linux-x86-64.so.2"
+    elif re.search("i.86", targetarch):
+        dynamic_loader = "${base_libdir}/ld-linux.so.2"
+    elif targetarch == "arm":
+        dynamic_loader = "${base_libdir}/ld-linux.so.3"
+    elif targetarch.startswith("aarch64"):
+        dynamic_loader = "${base_libdir}/ld-linux-aarch64${ARMPKGSFX_ENDIAN_64}.so.1"
+    return dynamic_loader
+
+def get_linuxloader(d):
+    overrides = d.getVar("OVERRIDES").split(":")
+
+    if "libc-baremetal" in overrides:
+        return None
+
+    if "libc-musl" in overrides:
+        dynamic_loader = get_musl_loader(d)
+    else:
+        dynamic_loader = get_glibc_loader(d)
+    return dynamic_loader
+
+get_linuxloader[vardepvalue] = "${@get_linuxloader(d)}"
+get_musl_loader[vardepvalue] = "${@get_musl_loader(d)}"
+get_glibc_loader[vardepvalue] = "${@get_glibc_loader(d)}"
diff --git a/poky/meta/classes/manpages.bbclass b/poky/meta/classes/manpages.bbclass
index d16237b..50c2547 100644
--- a/poky/meta/classes/manpages.bbclass
+++ b/poky/meta/classes/manpages.bbclass
@@ -3,3 +3,35 @@
 # tends to pull in the entire XML stack and other tools, so it's not enabled
 # by default.
 PACKAGECONFIG_append_class-target = " ${@bb.utils.contains('DISTRO_FEATURES', 'api-documentation', 'manpages', '', d)}"
+
+inherit qemu
+
+# usually manual files are packaged to ${PN}-doc except man-pages
+MAN_PKG ?= "${PN}-doc"
+
+# only add man-db to RDEPENDS when manual files are built and installed
+RDEPENDS_${MAN_PKG} += "${@bb.utils.contains('PACKAGECONFIG', 'manpages', 'man-db', '', d)}"
+
+pkg_postinst_append_${MAN_PKG} () {
+	# only update manual page index caches when manual files are built and installed
+	if ${@bb.utils.contains('PACKAGECONFIG', 'manpages', 'true', 'false', d)}; then
+		if test -n "$D"; then
+			if ${@bb.utils.contains('MACHINE_FEATURES', 'qemu-usermode', 'true','false', d)}; then
+				sed "s:\(\s\)/:\1$D/:g" $D${sysconfdir}/man_db.conf | ${@qemu_run_binary(d, '$D', '${bindir}/mandb')} -C - -u -q $D${mandir}
+				mkdir -p $D${localstatedir}/cache/man
+				mv $D${mandir}/index.db $D${localstatedir}/cache/man
+			else
+				$INTERCEPT_DIR/postinst_intercept delay_to_first_boot ${PKG} mlprefix=${MLPREFIX}
+			fi
+		else
+			mandb -q
+		fi
+	fi
+}
+
+pkg_postrm_append_${MAN_PKG} () {
+	# only update manual page index caches when manual files are built and installed
+	if ${@bb.utils.contains('PACKAGECONFIG', 'manpages', 'true', 'false', d)}; then
+		mandb -q
+	fi
+}
diff --git a/poky/meta/classes/meson.bbclass b/poky/meta/classes/meson.bbclass
index 2d7ee4f..3cbdcf1 100644
--- a/poky/meta/classes/meson.bbclass
+++ b/poky/meta/classes/meson.bbclass
@@ -1,4 +1,4 @@
-inherit python3native
+inherit siteinfo python3native
 
 DEPENDS_append = " meson-native ninja-native"
 
@@ -24,25 +24,52 @@
               --infodir ${@noprefix('infodir', d)} \
               --sysconfdir ${sysconfdir} \
               --localstatedir ${localstatedir} \
-              --sharedstatedir ${sharedstatedir}"
+              --sharedstatedir ${sharedstatedir} \
+              -Dc_args='${BUILD_CPPFLAGS} ${BUILD_CFLAGS}' \
+              -Dc_link_args='${BUILD_LDFLAGS}' \
+              -Dcpp_args='${BUILD_CPPFLAGS} ${BUILD_CXXFLAGS}' \
+              -Dcpp_link_args='${BUILD_LDFLAGS}'"
 
 MESON_TOOLCHAIN_ARGS = "${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}"
 MESON_C_ARGS = "${MESON_TOOLCHAIN_ARGS} ${CFLAGS}"
 MESON_CPP_ARGS = "${MESON_TOOLCHAIN_ARGS} ${CXXFLAGS}"
 MESON_LINK_ARGS = "${MESON_TOOLCHAIN_ARGS} ${LDFLAGS}"
 
-# both are required but not used by meson
-MESON_HOST_ENDIAN = "bogus-endian"
-MESON_TARGET_ENDIAN = "bogus-endian"
-
-EXTRA_OEMESON += "${PACKAGECONFIG_CONFARGS}"
+EXTRA_OEMESON_append = " ${PACKAGECONFIG_CONFARGS}"
 
 MESON_CROSS_FILE = ""
 MESON_CROSS_FILE_class-target = "--cross-file ${WORKDIR}/meson.cross"
 MESON_CROSS_FILE_class-nativesdk = "--cross-file ${WORKDIR}/meson.cross"
 
 def meson_array(var, d):
-    return "', '".join(d.getVar(var).split()).join(("'", "'"))
+    items = d.getVar(var).split()
+    return repr(items[0] if len(items) == 1 else items)
+
+# Map our ARCH values to what Meson expects:
+# http://mesonbuild.com/Reference-tables.html#cpu-families
+def meson_cpu_family(var, d):
+    import re
+    arch = d.getVar(var)
+    if arch == 'powerpc':
+        return 'ppc'
+    elif arch == 'powerpc64':
+        return 'ppc64'
+    elif arch == 'mipsel':
+        return 'mips'
+    elif re.match(r"i[3-6]86", arch):
+        return "x86"
+    else:
+        return arch
+
+def meson_endian(prefix, d):
+    arch, os = d.getVar(prefix + "_ARCH"), d.getVar(prefix + "_OS")
+    sitedata = siteinfo_data_for_machine(arch, os, d)
+    if "endian-little" in sitedata:
+        return "little"
+    elif "endian-big" in sitedata:
+        return "big"
+    else:
+        bb.fatal("Cannot determine endianism for %s-%s" % (arch, os))
 
 addtask write_config before do_configure
 do_write_config[vardeps] += "MESON_C_ARGS MESON_CPP_ARGS MESON_LINK_ARGS CC CXX LD AR NM STRIP READELF"
@@ -50,68 +77,69 @@
     # This needs to be Py to split the args into single-element lists
     cat >${WORKDIR}/meson.cross <<EOF
 [binaries]
-c = [${@meson_array('CC', d)}]
-cpp = [${@meson_array('CXX', d)}]
-ar = [${@meson_array('AR', d)}]
-nm = [${@meson_array('NM', d)}]
-ld = [${@meson_array('LD', d)}]
-strip = [${@meson_array('STRIP', d)}]
-readelf = [${@meson_array('READELF', d)}]
+c = ${@meson_array('CC', d)}
+cpp = ${@meson_array('CXX', d)}
+ar = ${@meson_array('AR', d)}
+nm = ${@meson_array('NM', d)}
+ld = ${@meson_array('LD', d)}
+strip = ${@meson_array('STRIP', d)}
+readelf = ${@meson_array('READELF', d)}
 pkgconfig = 'pkg-config'
 
 [properties]
 needs_exe_wrapper = true
-c_args = [${@meson_array('MESON_C_ARGS', d)}]
-c_link_args = [${@meson_array('MESON_LINK_ARGS', d)}]
-cpp_args = [${@meson_array('MESON_CPP_ARGS', d)}]
-cpp_link_args = [${@meson_array('MESON_LINK_ARGS', d)}]
+c_args = ${@meson_array('MESON_C_ARGS', d)}
+c_link_args = ${@meson_array('MESON_LINK_ARGS', d)}
+cpp_args = ${@meson_array('MESON_CPP_ARGS', d)}
+cpp_link_args = ${@meson_array('MESON_LINK_ARGS', d)}
 gtkdoc_exe_wrapper = '${B}/gtkdoc-qemuwrapper'
 
 [host_machine]
 system = '${HOST_OS}'
-cpu_family = '${HOST_ARCH}'
+cpu_family = '${@meson_cpu_family('HOST_ARCH', d)}'
 cpu = '${HOST_ARCH}'
-endian = '${MESON_HOST_ENDIAN}'
+endian = '${@meson_endian('HOST', d)}'
 
 [target_machine]
 system = '${TARGET_OS}'
-cpu_family = '${TARGET_ARCH}'
+cpu_family = '${@meson_cpu_family('TARGET_ARCH', d)}'
 cpu = '${TARGET_ARCH}'
-endian = '${MESON_TARGET_ENDIAN}'
+endian = '${@meson_endian('TARGET', d)}'
 EOF
 }
 
 CONFIGURE_FILES = "meson.build"
 
 meson_do_configure() {
+    # Work around "Meson fails if /tmp is mounted with noexec #2972"
+    mkdir -p "${B}/meson-private/tmp"
+    export TMPDIR="${B}/meson-private/tmp"
+    bbnote Executing meson ${EXTRA_OEMESON}...
     if ! meson ${MESONOPTS} "${MESON_SOURCEPATH}" "${B}" ${MESON_CROSS_FILE} ${EXTRA_OEMESON}; then
-        cat ${B}/meson-logs/meson-log.txt
         bbfatal_log meson failed
     fi
 }
 
-meson_do_configure_prepend_class-target() {
+override_native_tools() {
     # Set these so that meson uses the native tools for its build sanity tests,
     # which require executables to be runnable. The cross file will still
-    # override these for the target build. Note that we do *not* set CFLAGS,
-    # LDFLAGS, etc. as they will be slurped in by meson and applied to the
-    # target build, causing errors.
+    # override these for the target build.
     export CC="${BUILD_CC}"
     export CXX="${BUILD_CXX}"
     export LD="${BUILD_LD}"
     export AR="${BUILD_AR}"
+    # These contain *target* flags but will be used as *native* flags.  The
+    # correct native flags will be passed via -Dc_args and so on, unset them so
+    # they don't interfere with tools invoked by Meson (such as g-ir-scanner)
+    unset CPPFLAGS CFLAGS CXXFLAGS LDFLAGS
+}
+
+meson_do_configure_prepend_class-target() {
+    override_native_tools
 }
 
 meson_do_configure_prepend_class-nativesdk() {
-    # Set these so that meson uses the native tools for its build sanity tests,
-    # which require executables to be runnable. The cross file will still
-    # override these for the nativesdk build. Note that we do *not* set CFLAGS,
-    # LDFLAGS, etc. as they will be slurped in by meson and applied to the
-    # nativesdk build, causing errors.
-    export CC="${BUILD_CC}"
-    export CXX="${BUILD_CXX}"
-    export LD="${BUILD_LD}"
-    export AR="${BUILD_AR}"
+    override_native_tools
 }
 
 meson_do_configure_prepend_class-native() {
@@ -120,11 +148,11 @@
 
 do_compile[progress] = "outof:^\[(\d+)/(\d+)\]\s+"
 meson_do_compile() {
-    ninja ${PARALLEL_MAKE}
+    ninja -v ${PARALLEL_MAKE}
 }
 
 meson_do_install() {
-    DESTDIR='${D}' ninja ${PARALLEL_MAKEINST} install
+    DESTDIR='${D}' ninja -v ${PARALLEL_MAKEINST} install
 }
 
 EXPORT_FUNCTIONS do_configure do_compile do_install
diff --git a/poky/meta/classes/mime.bbclass b/poky/meta/classes/mime.bbclass
index 0df1583..6c7b868 100644
--- a/poky/meta/classes/mime.bbclass
+++ b/poky/meta/classes/mime.bbclass
@@ -53,5 +53,5 @@
             postrm += d.getVar('mime_postrm')
             d.setVar('pkg_postrm_%s' % pkg, postrm)
             bb.note("adding shared-mime-info-data dependency to %s" % pkg)
-            d.appendVar('RDEPENDS_' + pkg, " shared-mime-info-data")
+            d.appendVar('RDEPENDS_' + pkg, " " + d.getVar('MLPREFIX')+"shared-mime-info-data")
 }
diff --git a/poky/meta/classes/multilib.bbclass b/poky/meta/classes/multilib.bbclass
index 519c1a5..6c6499a 100644
--- a/poky/meta/classes/multilib.bbclass
+++ b/poky/meta/classes/multilib.bbclass
@@ -11,8 +11,12 @@
     # There should only be one kernel in multilib configs
     # We also skip multilib setup for module packages.
     provides = (e.data.getVar("PROVIDES") or "").split()
-    if "virtual/kernel" in provides or bb.data.inherits_class('module-base', e.data) or "make-mod-scripts" in e.data.getVar("PN"):
-        raise bb.parse.SkipRecipe("We shouldn't have multilib variants for the kernel")
+    non_ml_recipes = d.getVar('NON_MULTILIB_RECIPES').split()
+    bpn = e.data.getVar("BPN")
+    if "virtual/kernel" in provides or \
+            bb.data.inherits_class('module-base', e.data) or \
+            bpn in non_ml_recipes:
+        raise bb.parse.SkipRecipe("We shouldn't have multilib variants for %s" % bpn)
 
     save_var_name=e.data.getVar("MULTILIB_SAVE_VARNAME") or ""
     for name in save_var_name.split():
@@ -35,6 +39,10 @@
         return
 
     if bb.data.inherits_class('cross-canadian', e.data):
+        # Multilib cross-candian should use the same nativesdk sysroot without MLPREFIX
+        e.data.setVar("RECIPE_SYSROOT", "${WORKDIR}/recipe-sysroot")
+        e.data.setVar("STAGING_DIR_TARGET", "${WORKDIR}/recipe-sysroot")
+        e.data.setVar("STAGING_DIR_HOST", "${WORKDIR}/recipe-sysroot")
         e.data.setVar("MLPREFIX", variant + "-")
         override = ":virtclass-multilib-" + variant
         e.data.setVar("OVERRIDES", e.data.getVar("OVERRIDES", False) + override)
@@ -46,10 +54,10 @@
     if bb.data.inherits_class('nativesdk', e.data) or bb.data.inherits_class('crosssdk', e.data):
         raise bb.parse.SkipRecipe("We can't extend nativesdk recipes")
 
-    if bb.data.inherits_class('allarch', e.data) and not bb.data.inherits_class('packagegroup', e.data):
+    if bb.data.inherits_class('allarch', e.data) and not d.getVar('MULTILIB_VARIANTS') \
+        and not bb.data.inherits_class('packagegroup', e.data):
         raise bb.parse.SkipRecipe("Don't extend allarch recipes which are not packagegroups")
 
-
     # Expand this since this won't work correctly once we set a multilib into place
     e.data.setVar("ALL_MULTILIB_PACKAGE_ARCHS", e.data.getVar("ALL_MULTILIB_PACKAGE_ARCHS"))
  
@@ -65,12 +73,11 @@
     e.data.setVar("PN", variant + "-" + e.data.getVar("PN", False))
     e.data.setVar("OVERRIDES", e.data.getVar("OVERRIDES", False) + override)
 
-    # Expand the WHITELISTs with multilib prefix
-    for whitelist in ["WHITELIST_GPL-3.0", "LGPLv2_WHITELIST_GPL-3.0"]:
-        pkgs = e.data.getVar(whitelist)
-        for pkg in pkgs.split():
-            pkgs += " " + variant + "-" + pkg
-        e.data.setVar(whitelist, pkgs)
+    # Expand WHITELIST_GPL-3.0 with multilib prefix
+    pkgs = e.data.getVar("WHITELIST_GPL-3.0")
+    for pkg in pkgs.split():
+        pkgs += " " + variant + "-" + pkg
+    e.data.setVar("WHITELIST_GPL-3.0", pkgs)
 
     # DEFAULTTUNE can change TARGET_ARCH override so expand this now before update_data
     newtune = e.data.getVar("DEFAULTTUNE_" + "virtclass-multilib-" + variant, False)
@@ -117,6 +124,7 @@
     clsextend.map_variable("INITSCRIPT_PACKAGES")
     clsextend.map_variable("USERADD_PACKAGES")
     clsextend.map_variable("SYSTEMD_PACKAGES")
+    clsextend.map_variable("UPDATERCPN")
 }
 
 PACKAGEFUNCS_append = " do_package_qa_multilib"
@@ -131,7 +139,8 @@
                 i = i[len('virtual/'):]
             if (not i.startswith('kernel-module')) and (not i.startswith(mlprefix)) and \
                 (not 'cross-canadian' in i) and (not i.startswith("nativesdk-")) and \
-                (not i.startswith("rtld")) and (not i.startswith('kernel-vmlinux')):
+                (not i.startswith("rtld")) and (not i.startswith('kernel-vmlinux')) \
+                and (not i.startswith("kernel-image")):
                 candidates.append(i)
         if len(candidates) > 0:
             msg = "%s package %s - suspicious values '%s' in %s" \
@@ -142,6 +151,10 @@
     if not ml:
         return
 
+    # exception for ${MLPREFIX}target-sdk-provides-dummy
+    if 'target-sdk-provides-dummy' in d.getVar('PN'):
+        return
+
     packages = d.getVar('PACKAGES')
     for pkg in packages.split():
         check_mlprefix(pkg, 'RDEPENDS', ml)
diff --git a/poky/meta/classes/multilib_global.bbclass b/poky/meta/classes/multilib_global.bbclass
index d2ec1ad..649cc09 100644
--- a/poky/meta/classes/multilib_global.bbclass
+++ b/poky/meta/classes/multilib_global.bbclass
@@ -164,10 +164,11 @@
     if variant:
         return
 
+    non_ml_recipes = d.getVar('NON_MULTILIB_RECIPES').split()
+
     if bb.data.inherits_class('kernel', e.data) or \
             bb.data.inherits_class('module-base', e.data) or \
-            (bb.data.inherits_class('allarch', e.data) and\
-             not bb.data.inherits_class('packagegroup', e.data)):
+            d.getVar('BPN') in non_ml_recipes:
             variants = (e.data.getVar("MULTILIB_VARIANTS") or "").split()
 
             import oe.classextend
diff --git a/poky/meta/classes/multilib_script.bbclass b/poky/meta/classes/multilib_script.bbclass
new file mode 100644
index 0000000..51c9fcc
--- /dev/null
+++ b/poky/meta/classes/multilib_script.bbclass
@@ -0,0 +1,32 @@
+#
+# Recipe needs to set MULTILIB_SCRIPTS in the form <pkgname>:<scriptname>, e.g.
+# MULTILIB_SCRIPTS = "${PN}-dev:${bindir}/file1 ${PN}:${base_bindir}/file2"
+# to indicate which script files to process from which packages.
+#
+
+inherit update-alternatives
+
+MULTILIB_SUFFIX = "${@d.getVar('base_libdir',1).split('/')[-1]}"
+
+PACKAGE_PREPROCESS_FUNCS += "multilibscript_rename"
+
+multilibscript_rename() {
+	:
+}
+
+python () {
+    # Do nothing if multilib isn't being used
+    if not d.getVar("MULTILIB_VARIANTS"):
+       return
+    # Do nothing for native/cross
+    if bb.data.inherits_class('native', d) or bb.data.inherits_class('cross', d):
+       return
+
+    for entry in (d.getVar("MULTILIB_SCRIPTS", False) or "").split():
+       pkg, script = entry.split(":")
+       scriptname = os.path.basename(script)
+       d.appendVar("ALTERNATIVE_" + pkg, scriptname + " ")
+       d.setVarFlag("ALTERNATIVE_LINK_NAME", scriptname, script)
+       d.setVarFlag("ALTERNATIVE_TARGET", scriptname, script + "-${MULTILIB_SUFFIX}")
+       d.appendVar("multilibscript_rename",  "\n	mv ${PKGD}" + script + " ${PKGD}" + script + "-${MULTILIB_SUFFIX}")
+}
diff --git a/poky/meta/classes/native.bbclass b/poky/meta/classes/native.bbclass
index a911f2a..ddccfe2 100644
--- a/poky/meta/classes/native.bbclass
+++ b/poky/meta/classes/native.bbclass
@@ -44,7 +44,6 @@
 CFLAGS = "${BUILD_CFLAGS}"
 CXXFLAGS = "${BUILD_CXXFLAGS}"
 LDFLAGS = "${BUILD_LDFLAGS}"
-LDFLAGS_build-darwin = "-L${STAGING_LIBDIR_NATIVE} "
 
 STAGING_BINDIR = "${STAGING_BINDIR_NATIVE}"
 STAGING_BINDIR_CROSS = "${STAGING_BINDIR_NATIVE}"
@@ -78,6 +77,7 @@
 
 bindir = "${STAGING_BINDIR_NATIVE}"
 sbindir = "${STAGING_SBINDIR_NATIVE}"
+base_libdir = "${STAGING_LIBDIR_NATIVE}"
 libdir = "${STAGING_LIBDIR_NATIVE}"
 includedir = "${STAGING_INCDIR_NATIVE}"
 sysconfdir = "${STAGING_ETCDIR_NATIVE}"
@@ -89,6 +89,7 @@
 
 NATIVE_PACKAGE_PATH_SUFFIX ?= ""
 bindir .= "${NATIVE_PACKAGE_PATH_SUFFIX}"
+base_libdir .= "${NATIVE_PACKAGE_PATH_SUFFIX}"
 libdir .= "${NATIVE_PACKAGE_PATH_SUFFIX}"
 libexecdir .= "${NATIVE_PACKAGE_PATH_SUFFIX}"
 
@@ -152,8 +153,6 @@
                 newdeps.append(dep)
         d.setVar(varname, " ".join(newdeps))
 
-    e.data.setVar("OVERRIDES", e.data.getVar("OVERRIDES", False) + ":virtclass-native")
-
     map_dependencies("DEPENDS", e.data)
     for pkg in [e.data.getVar("PN"), "", "${PN}"]:
         map_dependencies("RDEPENDS", e.data, pkg)
diff --git a/poky/meta/classes/nativesdk.bbclass b/poky/meta/classes/nativesdk.bbclass
index 69fb45c..f25b0c3 100644
--- a/poky/meta/classes/nativesdk.bbclass
+++ b/poky/meta/classes/nativesdk.bbclass
@@ -12,6 +12,11 @@
 
 MULTILIBS = ""
 
+# we need consistent staging dir whether or not multilib is enabled
+STAGING_DIR_HOST = "${WORKDIR}/recipe-sysroot"
+STAGING_DIR_TARGET = "${WORKDIR}/recipe-sysroot"
+RECIPE_SYSROOT = "${WORKDIR}/recipe-sysroot"
+
 #
 # Update PACKAGE_ARCH and PACKAGE_ARCHS
 #
@@ -78,7 +83,6 @@
 
     e.data.setVar("MLPREFIX", "nativesdk-")
     e.data.setVar("PN", "nativesdk-" + e.data.getVar("PN").replace("-nativesdk", "").replace("nativesdk-", ""))
-    e.data.setVar("OVERRIDES", e.data.getVar("OVERRIDES", False) + ":virtclass-nativesdk")
 }
 
 python () {
diff --git a/poky/meta/classes/npm.bbclass b/poky/meta/classes/npm.bbclass
index c351ff0..6dbae6b 100644
--- a/poky/meta/classes/npm.bbclass
+++ b/poky/meta/classes/npm.bbclass
@@ -10,7 +10,7 @@
 
 NPMPN ?= "${@node_pkgname(d)}"
 
-NPM_INSTALLDIR = "${D}${libdir}/node_modules/${NPMPN}"
+NPM_INSTALLDIR = "${libdir}/node/${NPMPN}"
 
 # function maps arch names to npm arch names
 def npm_oe_arch_map(target_arch, d):
@@ -22,7 +22,7 @@
     return target_arch
 
 NPM_ARCH ?= "${@npm_oe_arch_map(d.getVar('TARGET_ARCH'), d)}"
-NPM_INSTALL_DEV = "0"
+NPM_INSTALL_DEV ?= "0"
 
 npm_do_compile() {
 	# Copy in any additionally fetched modules
@@ -52,9 +52,10 @@
 	# changing the home directory to the working directory, the .npmrc will
 	# be created in this directory
 	export HOME=${WORKDIR}
-	mkdir -p ${NPM_INSTALLDIR}/
+	mkdir -p ${D}${libdir}/node_modules
 	npm pack .
 	npm install --prefix ${D}${prefix} -g --arch=${NPM_ARCH} --target_arch=${NPM_ARCH} --production --no-registry ${NPMPN}-${PV}.tgz
+	mv ${D}${libdir}/node_modules ${D}${libdir}/node
 	if [ -d ${D}${prefix}/etc ] ; then
 		# This will be empty
 		rmdir ${D}${prefix}/etc
@@ -62,13 +63,13 @@
 }
 
 python populate_packages_prepend () {
-    instdir = d.expand('${D}${libdir}/node_modules/${NPMPN}')
+    instdir = d.expand('${D}${NPM_INSTALLDIR}')
     extrapackages = oe.package.npm_split_package_dirs(instdir)
     pkgnames = extrapackages.keys()
     d.prependVar('PACKAGES', '%s ' % ' '.join(pkgnames))
     for pkgname in pkgnames:
         pkgrelpath, pdata = extrapackages[pkgname]
-        pkgpath = '${libdir}/node_modules/${NPMPN}/' + pkgrelpath
+        pkgpath = '${NPM_INSTALLDIR}/' + pkgrelpath
         # package names can't have underscores but npm packages sometimes use them
         oe_pkg_name = pkgname.replace('_', '-')
         expanded_pkgname = d.expand(oe_pkg_name)
@@ -84,7 +85,7 @@
 }
 
 FILES_${PN} += " \
-    ${libdir}/node_modules/${NPMPN} \
+    ${NPM_INSTALLDIR} \
 "
 
 EXPORT_FUNCTIONS do_compile do_install
diff --git a/poky/meta/classes/package.bbclass b/poky/meta/classes/package.bbclass
index edeffa9..d1e9138 100644
--- a/poky/meta/classes/package.bbclass
+++ b/poky/meta/classes/package.bbclass
@@ -58,7 +58,7 @@
 
 # If your postinstall can execute at rootfs creation time rather than on
 # target but depends on a native/cross tool in order to execute, you need to
-# list that tool in PACKAGE_WRITE_DEPENDS. Target package dependencies belong
+# list that tool in PACKAGE_WRITE_DEPS. Target package dependencies belong
 # in the package dependencies as normal, this is just for native/cross support
 # tools at rootfs build time.
 PACKAGE_WRITE_DEPS ??= ""
@@ -345,8 +345,16 @@
     return debugfiles.keys()
 
 def append_source_info(file, sourcefile, d, fatal=True):
-    cmd = "'dwarfsrcfiles' '%s'" % (file)
-    (retval, output) = oe.utils.getstatusoutput(cmd)
+    import subprocess
+
+    cmd = ["dwarfsrcfiles", file]
+    try:
+        output = subprocess.check_output(cmd, universal_newlines=True, stderr=subprocess.STDOUT)
+        retval = 0
+    except subprocess.CalledProcessError as exc:
+        output = exc.output
+        retval = exc.returncode
+
     # 255 means a specific file wasn't fully parsed to get the debug file list, which is not a fatal failure
     if retval != 0 and retval != 255:
         msg = "dwarfsrcfiles failed with exit code %s (cmd was %s)%s" % (retval, cmd, ":\n%s" % output if output else "")
@@ -359,10 +367,12 @@
     # of rpm's debugedit, which was writing them out that way, and the code elsewhere
     # is still assuming that.
     debuglistoutput = '\0'.join(debugsources) + '\0'
+    lf = bb.utils.lockfile(sourcefile + ".lock")
     open(sourcefile, 'a').write(debuglistoutput)
+    bb.utils.unlockfile(lf)
 
 
-def splitdebuginfo(file, debugfile, debugsrcdir, sourcefile, d):
+def splitdebuginfo(file, dvar, debugdir, debuglibdir, debugappend, debugsrcdir, sourcefile, d):
     # Function to split a single file into two components, one is the stripped
     # target system binary, the other contains any debugging information. The
     # two files are linked to reference each other.
@@ -370,6 +380,16 @@
     # sourcefile is also generated containing a list of debugsources
 
     import stat
+    import subprocess
+
+    src = file[len(dvar):]
+    dest = debuglibdir + os.path.dirname(src) + debugdir + "/" + os.path.basename(src) + debugappend
+    debugfile = dvar + dest
+
+    # Split the file...
+    bb.utils.mkdirhier(os.path.dirname(debugfile))
+    #bb.note("Split %s -> %s" % (file, debugfile))
+    # Only store off the hard link reference if we successfully split!
 
     dvar = d.getVar('PKGD')
     objcopy = d.getVar("OBJCOPY")
@@ -390,16 +410,10 @@
 
     bb.utils.mkdirhier(os.path.dirname(debugfile))
 
-    cmd = "'%s' --only-keep-debug '%s' '%s'" % (objcopy, file, debugfile)
-    (retval, output) = oe.utils.getstatusoutput(cmd)
-    if retval:
-        bb.fatal("objcopy failed with exit code %s (cmd was %s)%s" % (retval, cmd, ":\n%s" % output if output else ""))
+    subprocess.check_output([objcopy, '--only-keep-debug', file, debugfile], stderr=subprocess.STDOUT)
 
     # Set the debuglink to have the view of the file path on the target
-    cmd = "'%s' --add-gnu-debuglink='%s' '%s'" % (objcopy, debugfile, file)
-    (retval, output) = oe.utils.getstatusoutput(cmd)
-    if retval:
-        bb.fatal("objcopy failed with exit code %s (cmd was %s)%s" % (retval, cmd, ":\n%s" % output if output else ""))
+    subprocess.check_output([objcopy, '--add-gnu-debuglink', debugfile, file], stderr=subprocess.STDOUT)
 
     if newmode:
         os.chmod(file, origmode)
@@ -411,6 +425,7 @@
     # and copied to the destination here.
 
     import stat
+    import subprocess
 
     sourcefile = d.expand("${WORKDIR}/debugsources.list")
     if debugsrcdir and os.path.isfile(sourcefile):
@@ -447,23 +462,20 @@
         processdebugsrc += "(cd '%s' ; cpio -pd0mlL --no-preserve-owner '%s%s' 2>/dev/null)"
 
         cmd = processdebugsrc % (sourcefile, workbasedir, localsrc_prefix, workparentdir, dvar, debugsrcdir)
-        (retval, output) = oe.utils.getstatusoutput(cmd)
-        # Can "fail" if internal headers/transient sources are attempted
-        #if retval:
-        #    bb.fatal("debug source copy failed with exit code %s (cmd was %s)" % (retval, cmd))
+        try:
+            subprocess.check_output(cmd, shell=True, stderr=subprocess.STDOUT)
+        except subprocess.CalledProcessError:
+            # Can "fail" if internal headers/transient sources are attempted
+            pass
 
         # cpio seems to have a bug with -lL together and symbolic links are just copied, not dereferenced.
         # Work around this by manually finding and copying any symbolic links that made it through.
         cmd = "find %s%s -type l -print0 -delete | sed s#%s%s/##g | (cd '%s' ; cpio -pd0mL --no-preserve-owner '%s%s' 2>/dev/null)" % (dvar, debugsrcdir, dvar, debugsrcdir, workparentdir, dvar, debugsrcdir)
-        (retval, output) = oe.utils.getstatusoutput(cmd)
-        if retval:
-            bb.fatal("debugsrc symlink fixup failed with exit code %s (cmd was %s)" % (retval, cmd))
+        subprocess.check_output(cmd, shell=True, stderr=subprocess.STDOUT)
 
         # The copy by cpio may have resulted in some empty directories!  Remove these
         cmd = "find %s%s -empty -type d -delete" % (dvar, debugsrcdir)
-        (retval, output) = oe.utils.getstatusoutput(cmd)
-        if retval:
-            bb.fatal("empty directory removal failed with exit code %s (cmd was %s)%s" % (retval, cmd, ":\n%s" % output if output else ""))
+        subprocess.check_output(cmd, shell=True, stderr=subprocess.STDOUT)
 
         # Also remove debugsrcdir if its empty
         for p in nosuchdir[::-1]:
@@ -482,7 +494,8 @@
 
     if key in data:
         # Have to avoid undoing the write_extra_pkgs(global_variants...)
-        if bb.data.inherits_class('allarch', d) and data[key] == basepkg:
+        if bb.data.inherits_class('allarch', d) and not d.getVar('MULTILIB_VARIANTS') \
+            and data[key] == basepkg:
             return pkg
         return data[key]
 
@@ -624,16 +637,16 @@
 }
 
 python perform_packagecopy () {
+    import subprocess
+
     dest = d.getVar('D')
     dvar = d.getVar('PKGD')
 
     # Start by package population by taking a copy of the installed
     # files to operate on
     # Preserve sparse files and hard links
-    cmd = 'tar -cf - -C %s -p . | tar -xf - -C %s' % (dest, dvar)
-    (retval, output) = oe.utils.getstatusoutput(cmd)
-    if retval:
-        bb.fatal("file copy failed with exit code %s (cmd was %s)%s" % (retval, cmd, ":\n%s" % output if output else ""))
+    cmd = 'tar -cf - -C %s -p -S . | tar -xf - -C %s' % (dest, dvar)
+    subprocess.check_output(cmd, shell=True, stderr=subprocess.STDOUT)
 
     # replace RPATHs for the nativesdk binaries, to make them relocatable
     if bb.data.inherits_class('nativesdk', d) or bb.data.inherits_class('cross-canadian', d):
@@ -762,7 +775,11 @@
         bbpath = d.getVar('BBPATH')
         fs_perms_tables = d.getVar('FILESYSTEM_PERMS_TABLES') or ""
         for conf_file in fs_perms_tables.split():
-            str += " %s" % bb.utils.which(bbpath, conf_file)
+            confpath = bb.utils.which(bbpath, conf_file)
+            if confpath:
+                str += " %s" % bb.utils.which(bbpath, conf_file)
+            else:
+                bb.warn("cannot find %s specified in FILESYSTEM_PERMS_TABLES" % conf_file)
         return str
 
 
@@ -880,6 +897,7 @@
 
 python split_and_strip_files () {
     import stat, errno
+    import subprocess
 
     dvar = d.getVar('PKGD')
     pn = d.getVar('PN')
@@ -916,43 +934,6 @@
     sourcefile = d.expand("${WORKDIR}/debugsources.list")
     bb.utils.remove(sourcefile)
 
-    # Return type (bits):
-    # 0 - not elf
-    # 1 - ELF
-    # 2 - stripped
-    # 4 - executable
-    # 8 - shared library
-    # 16 - kernel module
-    def isELF(path):
-        type = 0
-        ret, result = oe.utils.getstatusoutput("file -b '%s'" % path)
-
-        if ret:
-            msg = "split_and_strip_files: 'file %s' failed" % path
-            package_qa_handle_error("split-strip", msg, d)
-            return type
-
-        # Not stripped
-        if "ELF" in result:
-            type |= 1
-            if "not stripped" not in result:
-                type |= 2
-            if "executable" in result:
-                type |= 4
-            if "shared" in result:
-                type |= 8
-        return type
-
-    def isStaticLib(path):
-        if path.endswith('.a') and not os.path.islink(path):
-            with open(path, 'rb') as fh:
-                # The magic must include the first slash to avoid
-                # matching golang static libraries
-                magic = b'!<arch>\x0a/'
-                start = fh.read(len(magic))
-                return start == magic
-        return False
-
     #
     # First lets figure out all of the files we may have to process ... do this only once!
     #
@@ -966,13 +947,15 @@
     skipfiles = (d.getVar("INHIBIT_PACKAGE_STRIP_FILES") or "").split()
     if (d.getVar('INHIBIT_PACKAGE_STRIP') != '1' or \
             d.getVar('INHIBIT_PACKAGE_DEBUG_SPLIT') != '1'):
+        checkelf = {}
+        checkelflinks = {}
         for root, dirs, files in cpath.walk(dvar):
             for f in files:
                 file = os.path.join(root, f)
                 if file.endswith(".ko") and file.find("/lib/modules/") != -1:
                     kernmods.append(file)
                     continue
-                if isStaticLib(file):
+                if oe.package.is_static_lib(file):
                     staticlibs.append(file)
                     continue
 
@@ -999,59 +982,63 @@
                 # Check its an executable
                 if (s[stat.ST_MODE] & stat.S_IXUSR) or (s[stat.ST_MODE] & stat.S_IXGRP) or (s[stat.ST_MODE] & stat.S_IXOTH) \
                         or ((file.startswith(libdir) or file.startswith(baselibdir)) and (".so" in f or ".node" in f)):
-                    # If it's a symlink, and points to an ELF file, we capture the readlink target
+
                     if cpath.islink(file):
-                        target = os.readlink(file)
-                        if isELF(ltarget):
-                            #bb.note("Sym: %s (%d)" % (ltarget, isELF(ltarget)))
-                            symlinks[file] = target
+                        checkelflinks[file] = ltarget
                         continue
+                    # Use a reference of device ID and inode number to identify files
+                    file_reference = "%d_%d" % (s.st_dev, s.st_ino)
+                    checkelf[file] = (file, file_reference)
 
-                    # It's a file (or hardlink), not a link
-                    # ...but is it ELF, and is it already stripped?
-                    elf_file = isELF(file)
-                    if elf_file & 1:
-                        if elf_file & 2:
-                            if 'already-stripped' in (d.getVar('INSANE_SKIP_' + pn) or "").split():
-                                bb.note("Skipping file %s from %s for already-stripped QA test" % (file[len(dvar):], pn))
-                            else:
-                                msg = "File '%s' from %s was already stripped, this will prevent future debugging!" % (file[len(dvar):], pn)
-                                package_qa_handle_error("already-stripped", msg, d)
-                            continue
+        results = oe.utils.multiprocess_launch(oe.package.is_elf, checkelflinks.values(), d)
+        results_map = {}
+        for (ltarget, elf_file) in results:
+            results_map[ltarget] = elf_file
+        for file in checkelflinks:
+            ltarget = checkelflinks[file]
+            # If it's a symlink, and points to an ELF file, we capture the readlink target
+            if results_map[ltarget]:
+                target = os.readlink(file)
+                #bb.note("Sym: %s (%d)" % (ltarget, results_map[ltarget]))
+                symlinks[file] = target
 
-                        # At this point we have an unstripped elf file. We need to:
-                        #  a) Make sure any file we strip is not hardlinked to anything else outside this tree
-                        #  b) Only strip any hardlinked file once (no races)
-                        #  c) Track any hardlinks between files so that we can reconstruct matching debug file hardlinks
+        results = oe.utils.multiprocess_launch(oe.package.is_elf, checkelf.keys(), d)
+        for (file, elf_file) in results:
+            # It's a file (or hardlink), not a link
+            # ...but is it ELF, and is it already stripped?
+            if elf_file & 1:
+                if elf_file & 2:
+                    if 'already-stripped' in (d.getVar('INSANE_SKIP_' + pn) or "").split():
+                        bb.note("Skipping file %s from %s for already-stripped QA test" % (file[len(dvar):], pn))
+                    else:
+                        msg = "File '%s' from %s was already stripped, this will prevent future debugging!" % (file[len(dvar):], pn)
+                        package_qa_handle_error("already-stripped", msg, d)
+                    continue
 
-                        # Use a reference of device ID and inode number to identify files
-                        file_reference = "%d_%d" % (s.st_dev, s.st_ino)
-                        if file_reference in inodes:
-                            os.unlink(file)
-                            os.link(inodes[file_reference][0], file)
-                            inodes[file_reference].append(file)
-                        else:
-                            inodes[file_reference] = [file]
-                            # break hardlink
-                            bb.utils.copyfile(file, file)
-                            elffiles[file] = elf_file
-                        # Modified the file so clear the cache
-                        cpath.updatecache(file)
+                # At this point we have an unstripped elf file. We need to:
+                #  a) Make sure any file we strip is not hardlinked to anything else outside this tree
+                #  b) Only strip any hardlinked file once (no races)
+                #  c) Track any hardlinks between files so that we can reconstruct matching debug file hardlinks
+
+                # Use a reference of device ID and inode number to identify files
+                file_reference = checkelf[file][1]
+                if file_reference in inodes:
+                    os.unlink(file)
+                    os.link(inodes[file_reference][0], file)
+                    inodes[file_reference].append(file)
+                else:
+                    inodes[file_reference] = [file]
+                    # break hardlink
+                    bb.utils.break_hardlinks(file)
+                    elffiles[file] = elf_file
+                # Modified the file so clear the cache
+                cpath.updatecache(file)
 
     #
     # First lets process debug splitting
     #
     if (d.getVar('INHIBIT_PACKAGE_DEBUG_SPLIT') != '1'):
-        for file in elffiles:
-            src = file[len(dvar):]
-            dest = debuglibdir + os.path.dirname(src) + debugdir + "/" + os.path.basename(src) + debugappend
-            fpath = dvar + dest
-
-            # Split the file...
-            bb.utils.mkdirhier(os.path.dirname(fpath))
-            #bb.note("Split %s -> %s" % (file, fpath))
-            # Only store off the hard link reference if we successfully split!
-            splitdebuginfo(file, fpath, debugsrcdir, sourcefile, d)
+        oe.utils.multiprocess_launch(splitdebuginfo, list(elffiles), d, extraargs=(dvar, debugdir, debuglibdir, debugappend, debugsrcdir, sourcefile, d))
 
         if debugsrcdir and not targetos.startswith("mingw"):
             for file in staticlibs:
@@ -1061,15 +1048,18 @@
         for ref in inodes:
             if len(inodes[ref]) == 1:
                 continue
+
+            target = inodes[ref][0][len(dvar):]
             for file in inodes[ref][1:]:
                 src = file[len(dvar):]
-                dest = debuglibdir + os.path.dirname(src) + debugdir + "/" + os.path.basename(src) + debugappend
+                dest = debuglibdir + os.path.dirname(src) + debugdir + "/" + os.path.basename(target) + debugappend
                 fpath = dvar + dest
-                target = inodes[ref][0][len(dvar):]
                 ftarget = dvar + debuglibdir + os.path.dirname(target) + debugdir + "/" + os.path.basename(target) + debugappend
                 bb.utils.mkdirhier(os.path.dirname(fpath))
-                #bb.note("Link %s -> %s" % (fpath, ftarget))
-                os.link(ftarget, fpath)
+                # Only one hardlink of separated debug info file in each directory
+                if not os.access(fpath, os.R_OK):
+                    #bb.note("Link %s -> %s" % (fpath, ftarget))
+                    os.link(ftarget, fpath)
 
         # Create symlinks for all cases we were able to split symbols
         for file in symlinks:
@@ -1118,7 +1108,7 @@
         for f in kernmods:
             sfiles.append((f, 16, strip))
 
-        oe.utils.multiprocess_exec(sfiles, oe.package.runstrip)
+        oe.utils.multiprocess_launch(oe.package.runstrip, sfiles, d)
 
     #
     # End of strip
@@ -1151,21 +1141,22 @@
 
     # Sanity check PACKAGES for duplicates
     # Sanity should be moved to sanity.bbclass once we have the infrastructure
-    package_list = []
+    package_dict = {}
 
-    for pkg in packages.split():
-        if pkg in package_list:
+    for i, pkg in enumerate(packages.split()):
+        if pkg in package_dict:
             msg = "%s is listed in PACKAGES multiple times, this leads to packaging errors." % pkg
             package_qa_handle_error("packages-list", msg, d)
         # If debug-with-srcpkg mode is enabled then the src package will have
         # priority over dbg package when assigning the files.
         # This allows src package to include source files and remove them from dbg.
         elif split_source_package and pkg.endswith("-src"):
-            package_list.insert(0, pkg)
-        elif autodebug and pkg.endswith("-dbg") and not split_source_package:
-            package_list.insert(0, pkg)
+            package_dict[pkg] = (10, i)
+        elif autodebug and pkg.endswith("-dbg"):
+            package_dict[pkg] = (30, i)
         else:
-            package_list.append(pkg)
+            package_dict[pkg] = (50, i)
+    package_list = sorted(package_dict.keys(), key=package_dict.get)
     d.setVar('PACKAGES', ' '.join(package_list))
     pkgdest = d.getVar('PKGDEST')
 
@@ -1411,9 +1402,6 @@
     pkgdest = d.getVar('PKGDEST')
     pkgdatadir = d.getVar('PKGDESTWORK')
 
-    # Take shared lock since we're only reading, not writing
-    lf = bb.utils.lockfile(d.expand("${PACKAGELOCK}"), True)
-
     data_file = pkgdatadir + d.expand("/${PN}" )
     f = open(data_file, 'w')
     f.write("PACKAGES: %s\n" % packages)
@@ -1426,7 +1414,8 @@
     if bb.data.inherits_class('kernel', d) or bb.data.inherits_class('module-base', d):
         write_extra_pkgs(variants, pn, packages, pkgdatadir)
 
-    if (bb.data.inherits_class('allarch', d) and not bb.data.inherits_class('packagegroup', d)):
+    if bb.data.inherits_class('allarch', d) and not variants \
+        and not bb.data.inherits_class('packagegroup', d):
         write_extra_pkgs(global_variants, pn, packages, pkgdatadir)
 
     workdir = d.getVar('WORKDIR')
@@ -1515,10 +1504,10 @@
     if bb.data.inherits_class('kernel', d) or bb.data.inherits_class('module-base', d):
         write_extra_runtime_pkgs(variants, packages, pkgdatadir)
 
-    if bb.data.inherits_class('allarch', d) and not bb.data.inherits_class('packagegroup', d):
+    if bb.data.inherits_class('allarch', d) and not variants \
+        and not bb.data.inherits_class('packagegroup', d):
         write_extra_runtime_pkgs(global_variants, packages, pkgdatadir)
 
-    bb.utils.unlockfile(lf)
 }
 emit_pkgdata[dirs] = "${PKGDESTWORK}/runtime ${PKGDESTWORK}/runtime-reverse ${PKGDESTWORK}/runtime-rprovides"
 
@@ -1558,7 +1547,7 @@
         for files in chunks(pkgfiles[pkg], 100):
             pkglist.append((pkg, files, rpmdeps, pkgdest))
 
-    processed = oe.utils.multiprocess_exec( pkglist, oe.package.filedeprunner)
+    processed = oe.utils.multiprocess_launch(oe.package.filedeprunner, pkglist, d)
 
     provides_files = {}
     requires_files = {}
@@ -1574,12 +1563,12 @@
         for file in provides:
             provides_files[pkg].append(file)
             key = "FILERPROVIDES_" + file + "_" + pkg
-            d.setVar(key, " ".join(provides[file]))
+            d.appendVar(key, " " + " ".join(provides[file]))
 
         for file in requires:
             requires_files[pkg].append(file)
             key = "FILERDEPENDS_" + file + "_" + pkg
-            d.setVar(key, " ".join(requires[file]))
+            d.appendVar(key, " " + " ".join(requires[file]))
 
     for pkg in requires_files:
         d.setVar("FILERDEPENDSFLIST_" + pkg, " ".join(requires_files[pkg]))
@@ -1592,7 +1581,7 @@
 
 python package_do_shlibs() {
     import re, pipes
-    import subprocess as sub
+    import subprocess
 
     exclude_shlibs = d.getVar('EXCLUDE_FROM_SHLIBS', False)
     if exclude_shlibs:
@@ -1603,6 +1592,18 @@
     libdir_re = re.compile(".*/%s$" % d.getVar('baselib'))
 
     packages = d.getVar('PACKAGES')
+
+    shlib_pkgs = []
+    exclusion_list = d.getVar("EXCLUDE_PACKAGES_FROM_SHLIBS")
+    if exclusion_list:
+        for pkg in packages.split():
+            if pkg not in exclusion_list.split():
+                shlib_pkgs.append(pkg)
+            else:
+                bb.note("not generating shlibs for %s" % pkg)
+    else:
+        shlib_pkgs = packages.split()
+
     targetos = d.getVar('TARGET_OS')
 
     workdir = d.getVar('WORKDIR')
@@ -1617,28 +1618,28 @@
 
     shlibswork_dir = d.getVar('SHLIBSWORKDIR')
 
-    # Take shared lock since we're only reading, not writing
-    lf = bb.utils.lockfile(d.expand("${PACKAGELOCK}"), True)
-
-    def linux_so(file, needed, sonames, renames, pkgver):
+    def linux_so(file, pkg, pkgver, d):
         needs_ldconfig = False
+        needed = set()
+        sonames = set()
+        renames = []
         ldir = os.path.dirname(file).replace(pkgdest + "/" + pkg, '')
         cmd = d.getVar('OBJDUMP') + " -p " + pipes.quote(file) + " 2>/dev/null"
         fd = os.popen(cmd)
         lines = fd.readlines()
         fd.close()
-        rpath = []
+        rpath = tuple()
         for l in lines:
             m = re.match("\s+RPATH\s+([^\s]*)", l)
             if m:
                 rpaths = m.group(1).replace("$ORIGIN", ldir).split(":")
-                rpath = list(map(os.path.normpath, rpaths))
+                rpath = tuple(map(os.path.normpath, rpaths))
         for l in lines:
             m = re.match("\s+NEEDED\s+([^\s]*)", l)
             if m:
                 dep = m.group(1)
-                if dep not in needed[pkg]:
-                    needed[pkg].append((dep, file, rpath))
+                if dep not in needed:
+                    needed.add((dep, file, rpath))
             m = re.match("\s+SONAME\s+([^\s]*)", l)
             if m:
                 this_soname = m.group(1)
@@ -1646,12 +1647,12 @@
                 if not prov in sonames:
                     # if library is private (only used by package) then do not build shlib for it
                     if not private_libs or this_soname not in private_libs:
-                        sonames.append(prov)
+                        sonames.add(prov)
                 if libdir_re.match(os.path.dirname(file)):
                     needs_ldconfig = True
                 if snap_symlinks and (os.path.basename(file) != this_soname):
                     renames.append((file, os.path.join(os.path.dirname(file), this_soname)))
-        return needs_ldconfig
+        return (needs_ldconfig, needed, sonames, renames)
 
     def darwin_so(file, needed, sonames, renames, pkgver):
         if not os.path.exists(file):
@@ -1679,10 +1680,10 @@
             for combo in combos:
                 if not combo in sonames:
                     prov = (combo, ldir, pkgver)
-                    sonames.append(prov)
+                    sonames.add(prov)
         if file.endswith('.dylib') or file.endswith('.so'):
             rpath = []
-            p = sub.Popen([d.expand("${HOST_PREFIX}otool"), '-l', file],stdout=sub.PIPE,stderr=sub.PIPE)
+            p = subprocess.Popen([d.expand("${HOST_PREFIX}otool"), '-l', file], stdout=subprocess.PIPE, stderr=subprocess.PIPE)
             out, err = p.communicate()
             # If returned successfully, process stdout for results
             if p.returncode == 0:
@@ -1691,7 +1692,7 @@
                     if l.startswith('path '):
                         rpath.append(l.split()[1])
 
-        p = sub.Popen([d.expand("${HOST_PREFIX}otool"), '-L', file],stdout=sub.PIPE,stderr=sub.PIPE)
+        p = subprocess.Popen([d.expand("${HOST_PREFIX}otool"), '-L', file], stdout=subprocess.PIPE, stderr=subprocess.PIPE)
         out, err = p.communicate()
         # If returned successfully, process stdout for results
         if p.returncode == 0:
@@ -1703,7 +1704,7 @@
                     continue
                 name = os.path.basename(l.split()[0]).rsplit(".", 1)[0]
                 if name and name not in needed[pkg]:
-                     needed[pkg].append((name, file, []))
+                     needed[pkg].add((name, file, tuple()))
 
     def mingw_dll(file, needed, sonames, renames, pkgver):
         if not os.path.exists(file):
@@ -1711,18 +1712,18 @@
 
         if file.endswith(".dll"):
             # assume all dlls are shared objects provided by the package
-            sonames.append((os.path.basename(file), os.path.dirname(file).replace(pkgdest + "/" + pkg, ''), pkgver))
+            sonames.add((os.path.basename(file), os.path.dirname(file).replace(pkgdest + "/" + pkg, ''), pkgver))
 
         if (file.endswith(".dll") or file.endswith(".exe")):
             # use objdump to search for "DLL Name: .*\.dll"
-            p = sub.Popen([d.expand("${HOST_PREFIX}objdump"), "-p", file], stdout = sub.PIPE, stderr= sub.PIPE)
+            p = subprocess.Popen([d.expand("${HOST_PREFIX}objdump"), "-p", file], stdout=subprocess.PIPE, stderr=subprocess.PIPE)
             out, err = p.communicate()
             # process the output, grabbing all .dll names
             if p.returncode == 0:
                 for m in re.finditer("DLL Name: (.*?\.dll)$", out.decode(), re.MULTILINE | re.IGNORECASE):
                     dllname = m.group(1)
                     if dllname:
-                        needed[pkg].append((dllname, file, []))
+                        needed[pkg].add((dllname, file, tuple()))
 
     if d.getVar('PACKAGE_SNAP_LIB_SYMLINKS') == "1":
         snap_symlinks = True
@@ -1732,9 +1733,13 @@
     use_ldconfig = bb.utils.contains('DISTRO_FEATURES', 'ldconfig', True, False, d)
 
     needed = {}
-    shlib_provider = oe.package.read_shlib_providers(d)
 
-    for pkg in packages.split():
+    # Take shared lock since we're only reading, not writing
+    lf = bb.utils.lockfile(d.expand("${PACKAGELOCK}"), True)
+    shlib_provider = oe.package.read_shlib_providers(d)
+    bb.utils.unlockfile(lf)
+
+    for pkg in shlib_pkgs:
         private_libs = d.getVar('PRIVATE_LIBS_' + pkg) or d.getVar('PRIVATE_LIBS') or ""
         private_libs = private_libs.split()
         needs_ldconfig = False
@@ -1746,9 +1751,10 @@
         if not pkgver:
             pkgver = ver
 
-        needed[pkg] = []
-        sonames = list()
-        renames = list()
+        needed[pkg] = set()
+        sonames = set()
+        renames = []
+        linuxlist = []
         for file in pkgfiles[pkg]:
                 soname = None
                 if cpath.islink(file):
@@ -1758,8 +1764,17 @@
                 elif targetos.startswith("mingw"):
                     mingw_dll(file, needed, sonames, renames, pkgver)
                 elif os.access(file, os.X_OK) or lib_re.match(file):
-                    ldconfig = linux_so(file, needed, sonames, renames, pkgver)
-                    needs_ldconfig = needs_ldconfig or ldconfig
+                    linuxlist.append(file)
+
+        if linuxlist:
+            results = oe.utils.multiprocess_launch(linux_so, linuxlist, d, extraargs=(pkg, pkgver, d))
+            for r in results:
+                ldconfig = r[0]
+                needed[pkg] |= r[1]
+                sonames |= r[2]
+                renames.extend(r[3])
+                needs_ldconfig = needs_ldconfig or ldconfig
+
         for (old, new) in renames:
             bb.note("Renaming %s to %s" % (old, new))
             os.rename(old, new)
@@ -1788,8 +1803,6 @@
             d.setVar('pkg_postinst_%s' % pkg, postinst)
         bb.debug(1, 'LIBNAMES: pkg %s sonames %s' % (pkg, sonames))
 
-    bb.utils.unlockfile(lf)
-
     assumed_libs = d.getVar('ASSUME_SHLIBS')
     if assumed_libs:
         libdir = d.getVar("libdir")
@@ -1806,7 +1819,7 @@
 
     libsearchpath = [d.getVar('libdir'), d.getVar('base_libdir')]
 
-    for pkg in packages.split():
+    for pkg in shlib_pkgs:
         bb.debug(2, "calculating shlib requirements for %s" % pkg)
 
         private_libs = d.getVar('PRIVATE_LIBS_' + pkg) or d.getVar('PRIVATE_LIBS') or ""
@@ -1827,7 +1840,7 @@
                 for k in shlib_provider[n[0]].keys():
                     shlib_provider_path.append(k)
                 match = None
-                for p in n[2] + shlib_provider_path + libsearchpath:
+                for p in list(n[2]) + shlib_provider_path + libsearchpath:
                     if p in shlib_provider[n[0]]:
                         match = p
                         break
@@ -1902,9 +1915,6 @@
                             if hdr == 'Requires':
                                 pkgconfig_needed[pkg] += exp.replace(',', ' ').split()
 
-    # Take shared lock since we're only reading, not writing
-    lf = bb.utils.lockfile(d.expand("${PACKAGELOCK}"), True)
-
     for pkg in packages.split():
         pkgs_file = os.path.join(shlibswork_dir, pkg + ".pclist")
         if pkgconfig_provided[pkg] != []:
@@ -1913,6 +1923,9 @@
                 f.write('%s\n' % p)
             f.close()
 
+    # Take shared lock since we're only reading, not writing
+    lf = bb.utils.lockfile(d.expand("${PACKAGELOCK}"), True)
+
     # Go from least to most specific since the last one found wins
     for dir in reversed(shlibs_dirs):
         if not os.path.exists(dir):
@@ -1928,6 +1941,8 @@
                 for l in lines:
                     pkgconfig_provided[pkg].append(l.rstrip())
 
+    bb.utils.unlockfile(lf)
+
     for pkg in packages.split():
         deps = []
         for n in pkgconfig_needed[pkg]:
@@ -1945,8 +1960,6 @@
             for dep in deps:
                 fd.write(dep + '\n')
             fd.close()
-
-    bb.utils.unlockfile(lf)
 }
 
 def read_libdep_files(d):
diff --git a/poky/meta/classes/package_deb.bbclass b/poky/meta/classes/package_deb.bbclass
index 2e8d17d..6f81591 100644
--- a/poky/meta/classes/package_deb.bbclass
+++ b/poky/meta/classes/package_deb.bbclass
@@ -41,32 +41,6 @@
     return arch
 
 python do_package_deb () {
-
-    import multiprocessing
-    import traceback
-
-    class DebianWritePkgProcess(multiprocessing.Process):
-        def __init__(self, *args, **kwargs):
-            multiprocessing.Process.__init__(self, *args, **kwargs)
-            self._pconn, self._cconn = multiprocessing.Pipe()
-            self._exception = None
-
-        def run(self):
-            try:
-                multiprocessing.Process.run(self)
-                self._cconn.send(None)
-            except Exception as e:
-                tb = traceback.format_exc()
-                self._cconn.send((e, tb))
-
-        @property
-        def exception(self):
-            if self._pconn.poll():
-                self._exception = self._pconn.recv()
-            return self._exception
-
-    oldcwd = os.getcwd()
-
     packages = d.getVar('PACKAGES')
     if not packages:
         bb.debug(1, "PACKAGES not defined, nothing to package")
@@ -76,30 +50,7 @@
     if os.access(os.path.join(tmpdir, "stamps", "DEB_PACKAGE_INDEX_CLEAN"),os.R_OK):
         os.unlink(os.path.join(tmpdir, "stamps", "DEB_PACKAGE_INDEX_CLEAN"))
 
-    max_process = int(d.getVar("BB_NUMBER_THREADS") or os.cpu_count() or 1)
-    launched = []
-    error = None
-    pkgs = packages.split()
-    while not error and pkgs:
-        if len(launched) < max_process:
-            p = DebianWritePkgProcess(target=deb_write_pkg, args=(pkgs.pop(), d))
-            p.start()
-            launched.append(p)
-        for q in launched:
-            # The finished processes are joined when calling is_alive()
-            if not q.is_alive():
-                launched.remove(q)
-            if q.exception:
-                error, traceback = q.exception
-                break
-
-    for p in launched:
-        p.join()
-
-    os.chdir(oldcwd)
-
-    if error:
-        raise error
+    oe.utils.multiprocess_launch(deb_write_pkg, packages.split(), d, extraargs=(d,))
 }
 do_package_deb[vardeps] += "deb_write_pkg"
 do_package_deb[vardepsexclude] = "BB_NUMBER_THREADS"
diff --git a/poky/meta/classes/package_ipk.bbclass b/poky/meta/classes/package_ipk.bbclass
index a0b34fa..5eb910c 100644
--- a/poky/meta/classes/package_ipk.bbclass
+++ b/poky/meta/classes/package_ipk.bbclass
@@ -17,32 +17,6 @@
 OPKGLIBDIR = "${localstatedir}/lib"
 
 python do_package_ipk () {
-    import multiprocessing
-    import traceback
-
-    class IPKWritePkgProcess(multiprocessing.Process):
-        def __init__(self, *args, **kwargs):
-            multiprocessing.Process.__init__(self, *args, **kwargs)
-            self._pconn, self._cconn = multiprocessing.Pipe()
-            self._exception = None
-
-        def run(self):
-            try:
-                multiprocessing.Process.run(self)
-                self._cconn.send(None)
-            except Exception as e:
-                tb = traceback.format_exc()
-                self._cconn.send((e, tb))
-
-        @property
-        def exception(self):
-            if self._pconn.poll():
-                self._exception = self._pconn.recv()
-            return self._exception
-
-
-    oldcwd = os.getcwd()
-
     workdir = d.getVar('WORKDIR')
     outdir = d.getVar('PKGWRITEDIRIPK')
     tmpdir = d.getVar('TMPDIR')
@@ -61,30 +35,7 @@
     if os.access(os.path.join(tmpdir, "stamps", "IPK_PACKAGE_INDEX_CLEAN"), os.R_OK):
         os.unlink(os.path.join(tmpdir, "stamps", "IPK_PACKAGE_INDEX_CLEAN"))
 
-    max_process = int(d.getVar("BB_NUMBER_THREADS") or os.cpu_count() or 1)
-    launched = []
-    error = None
-    pkgs = packages.split()
-    while not error and pkgs:
-        if len(launched) < max_process:
-            p = IPKWritePkgProcess(target=ipk_write_pkg, args=(pkgs.pop(), d))
-            p.start()
-            launched.append(p)
-        for q in launched:
-            # The finished processes are joined when calling is_alive()
-            if not q.is_alive():
-                launched.remove(q)
-            if q.exception:
-                error, traceback = q.exception
-                break
-
-    for p in launched:
-        p.join()
-
-    os.chdir(oldcwd)
-
-    if error:
-        raise error
+    oe.utils.multiprocess_launch(ipk_write_pkg, packages.split(), d, extraargs=(d,))
 }
 do_package_ipk[vardeps] += "ipk_write_pkg"
 do_package_ipk[vardepsexclude] = "BB_NUMBER_THREADS"
diff --git a/poky/meta/classes/patch.bbclass b/poky/meta/classes/patch.bbclass
index 2fc6925..3e0a181 100644
--- a/poky/meta/classes/patch.bbclass
+++ b/poky/meta/classes/patch.bbclass
@@ -33,7 +33,7 @@
     if (testsrcdir + os.sep).startswith(workdir + os.sep):
         # Double-check that either workdir or S or some directory in-between is a git repository
         found = False
-        while testsrcdir != '/':
+        while testsrcdir != workdir:
             if os.path.exists(os.path.join(testsrcdir, '.git')):
                 found = True
                 break
diff --git a/poky/meta/classes/pixbufcache.bbclass b/poky/meta/classes/pixbufcache.bbclass
index b3e507f..3378ff2 100644
--- a/poky/meta/classes/pixbufcache.bbclass
+++ b/poky/meta/classes/pixbufcache.bbclass
@@ -12,7 +12,7 @@
 
 pixbufcache_common() {
 if [ "x$D" != "x" ]; then
-	$INTERCEPT_DIR/postinst_intercept update_pixbuf_cache ${PKG} mlprefix=${MLPREFIX} libdir=${libdir} \
+	$INTERCEPT_DIR/postinst_intercept update_pixbuf_cache ${PKG} mlprefix=${MLPREFIX} binprefix=${MLPREFIX} libdir=${libdir} \
 		bindir=${bindir} base_libdir=${base_libdir}
 else
 
diff --git a/poky/meta/classes/populate_sdk_base.bbclass b/poky/meta/classes/populate_sdk_base.bbclass
index 3da3507..677ba3c 100644
--- a/poky/meta/classes/populate_sdk_base.bbclass
+++ b/poky/meta/classes/populate_sdk_base.bbclass
@@ -1,4 +1,4 @@
-inherit meta
+inherit meta image-postinst-intercepts
 
 # Wildcards specifying complementary packages to install for every package that has been explicitly
 # installed into the rootfs
@@ -40,13 +40,13 @@
 
 TOOLCHAIN_HOST_TASK ?= "nativesdk-packagegroup-sdk-host packagegroup-cross-canadian-${MACHINE}"
 TOOLCHAIN_HOST_TASK_ATTEMPTONLY ?= ""
-TOOLCHAIN_TARGET_TASK ?= "${@multilib_pkg_extend(d, 'packagegroup-core-standalone-sdk-target')} \
-                          ${@multilib_pkg_extend(d, 'target-sdk-provides-dummy')}"
+TOOLCHAIN_TARGET_TASK ?= "${@multilib_pkg_extend(d, 'packagegroup-core-standalone-sdk-target')} target-sdk-provides-dummy"
 TOOLCHAIN_TARGET_TASK_ATTEMPTONLY ?= ""
 TOOLCHAIN_OUTPUTNAME ?= "${SDK_NAME}-toolchain-${SDK_VERSION}"
 
 SDK_RDEPENDS = "${TOOLCHAIN_TARGET_TASK} ${TOOLCHAIN_HOST_TASK}"
-SDK_DEPENDS = "virtual/fakeroot-native xz-native cross-localedef-native ${MLPREFIX}qemuwrapper-cross"
+SDK_DEPENDS = "virtual/fakeroot-native xz-native cross-localedef-native nativesdk-qemuwrapper-cross ${@' '.join(["%s-qemuwrapper-cross" % m for m in d.getVar("MULTILIB_VARIANTS").split()])} qemuwrapper-cross"
+PATH_prepend = "${STAGING_DIR_HOST}${SDKPATHNATIVE}${bindir}/crossscripts:${@":".join(all_multilib_tune_values(d, 'STAGING_BINDIR_CROSS').split())}:"
 SDK_DEPENDS_append_libc-glibc = " nativesdk-glibc-locale"
 
 # We want the MULTIARCH_TARGET_SYS to point to the TUNE_PKGARCH, not PACKAGE_ARCH as it
@@ -62,8 +62,8 @@
 SDK_POST_INSTALL_COMMAND ?= ""
 SDK_RELOCATE_AFTER_INSTALL ?= "1"
 
-SDKEXTPATH ?= "~/${@d.getVar('DISTRO')}_sdk"
-SDK_TITLE ?= "${@d.getVar('DISTRO_NAME') or d.getVar('DISTRO')} SDK"
+SDKEXTPATH ??= "~/${@d.getVar('DISTRO')}_sdk"
+SDK_TITLE ??= "${@d.getVar('DISTRO_NAME') or d.getVar('DISTRO')} SDK"
 
 SDK_TARGET_MANIFEST = "${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.target.manifest"
 SDK_HOST_MANIFEST = "${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.host.manifest"
@@ -228,14 +228,17 @@
 	tar ${SDKTAROPTS} -cf - . | xz -T 0 > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz
 }
 
+TOOLCHAIN_SHAR_EXT_TMPL ?= "${COREBASE}/meta/files/toolchain-shar-extract.sh"
+TOOLCHAIN_SHAR_REL_TMPL ?= "${COREBASE}/meta/files/toolchain-shar-relocate.sh"
+
 fakeroot create_shar() {
 	# copy in the template shar extractor script
-	cp ${COREBASE}/meta/files/toolchain-shar-extract.sh ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.sh
+	cp ${TOOLCHAIN_SHAR_EXT_TMPL} ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.sh
 
 	rm -f ${T}/pre_install_command ${T}/post_install_command
 
 	if [ ${SDK_RELOCATE_AFTER_INSTALL} -eq 1 ] ; then
-		cp ${COREBASE}/meta/files/toolchain-shar-relocate.sh ${T}/post_install_command
+		cp ${TOOLCHAIN_SHAR_REL_TMPL} ${T}/post_install_command
 	fi
 	cat << "EOF" >> ${T}/pre_install_command
 ${SDK_PRE_INSTALL_COMMAND}
@@ -258,7 +261,7 @@
 		-e 's#@SDK_VERSION@#${SDK_VERSION}#g' \
 		-e '/@SDK_PRE_INSTALL_COMMAND@/d' \
 		-e '/@SDK_POST_INSTALL_COMMAND@/d' \
-		-e 's#@SDK_GCC_VER@#${@oe.utils.host_gcc_version(d)}#g' \
+		-e 's#@SDK_GCC_VER@#${@oe.utils.host_gcc_version(d, taskcontextonly=True)}#g' \
 		${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.sh
 
 	# add execution permission
@@ -293,17 +296,18 @@
 def sdk_variables(d):
     variables = ['BUILD_IMAGES_FROM_FEEDS','SDK_OS','SDK_OUTPUT','SDKPATHNATIVE','SDKTARGETSYSROOT','SDK_DIR','SDK_VENDOR','SDKIMAGE_INSTALL_COMPLEMENTARY','SDK_PACKAGE_ARCHS','SDK_OUTPUT',
                  'SDKTARGETSYSROOT','MULTILIB_VARIANTS','MULTILIBS','ALL_MULTILIB_PACKAGE_ARCHS','MULTILIB_GLOBAL_VARIANTS','BAD_RECOMMENDATIONS','NO_RECOMMENDATIONS','PACKAGE_ARCHS',
-                 'PACKAGE_CLASSES','TARGET_VENDOR','TARGET_VENDOR','TARGET_ARCH','TARGET_OS','BBEXTENDVARIANT','FEED_DEPLOYDIR_BASE_URI', 'PACKAGE_EXCLUDE_COMPLEMENTARY']
+                 'PACKAGE_CLASSES','TARGET_VENDOR','TARGET_VENDOR','TARGET_ARCH','TARGET_OS','BBEXTENDVARIANT','FEED_DEPLOYDIR_BASE_URI', 'PACKAGE_EXCLUDE_COMPLEMENTARY', 'IMAGE_INSTALL_DEBUGFS']
     variables.extend(sdk_command_variables(d))
     return " ".join(variables)
 
 do_populate_sdk[vardeps] += "${@sdk_variables(d)}"
 
-do_populate_sdk[file-checksums] += "${COREBASE}/meta/files/toolchain-shar-relocate.sh:True \
-                                    ${COREBASE}/meta/files/toolchain-shar-extract.sh:True"
+do_populate_sdk[file-checksums] += "${TOOLCHAIN_SHAR_REL_TMPL}:True \
+                                    ${TOOLCHAIN_SHAR_EXT_TMPL}:True"
 
 do_populate_sdk[dirs] = "${PKGDATA_DIR} ${TOPDIR}"
 do_populate_sdk[depends] += "${@' '.join([x + ':do_populate_sysroot' for x in d.getVar('SDK_DEPENDS').split()])}  ${@d.getVarFlag('do_rootfs', 'depends', False)}"
 do_populate_sdk[rdepends] = "${@' '.join([x + ':do_package_write_${IMAGE_PKGTYPE} ' + x + ':do_packagedata' for x in d.getVar('SDK_RDEPENDS').split()])}"
 do_populate_sdk[recrdeptask] += "do_packagedata do_package_write_rpm do_package_write_ipk do_package_write_deb"
+do_populate_sdk[file-checksums] += "${POSTINST_INTERCEPT_CHECKSUMS}"
 addtask populate_sdk
diff --git a/poky/meta/classes/populate_sdk_ext.bbclass b/poky/meta/classes/populate_sdk_ext.bbclass
index e1bba49..e30c492 100644
--- a/poky/meta/classes/populate_sdk_ext.bbclass
+++ b/poky/meta/classes/populate_sdk_ext.bbclass
@@ -200,15 +200,9 @@
         workspace_name = 'orig-workspace'
     else:
         workspace_name = None
-    layers_copied = buildsystem.copy_bitbake_and_layers(baseoutpath + '/layers', workspace_name)
 
-    sdkbblayers = []
-    corebase = os.path.basename(d.getVar('COREBASE'))
-    for layer in layers_copied:
-        if corebase == os.path.basename(layer):
-            conf_bbpath = os.path.join('layers', layer, 'bitbake')
-        else:
-            sdkbblayers.append(layer)
+    corebase, sdkbblayers = buildsystem.copy_bitbake_and_layers(baseoutpath + '/layers', workspace_name)
+    conf_bbpath = os.path.join('layers', corebase, 'bitbake')
 
     for path in os.listdir(baseoutpath + '/layers'):
         relpath = os.path.join('layers', path, oe_init_env_script)
@@ -325,8 +319,9 @@
             f.write('TCLIBCAPPEND = ""\n')
             f.write('DL_DIR = "${TOPDIR}/downloads"\n')
 
-            f.write('INHERIT += "%s"\n' % 'uninative')
-            f.write('UNINATIVE_CHECKSUM[%s] = "%s"\n\n' % (d.getVar('BUILD_ARCH'), uninative_checksum))
+            if bb.data.inherits_class('uninative', d):
+               f.write('INHERIT += "%s"\n' % 'uninative')
+               f.write('UNINATIVE_CHECKSUM[%s] = "%s"\n\n' % (d.getVar('BUILD_ARCH'), uninative_checksum))
             f.write('CONF_VERSION = "%s"\n\n' % d.getVar('CONF_VERSION', False))
 
             # Some classes are not suitable for SDK, remove them from INHERIT
@@ -536,7 +531,8 @@
 	scripts="devtool recipetool oe-find-native-sysroot runqemu* wic"
 	for script in $scripts; do
 		for scriptfn in `find ${SDK_OUTPUT}/${SDKPATH}/${scriptrelpath} -maxdepth 1 -executable -name "$script"`; do
-			lnr ${scriptfn} ${SDK_OUTPUT}/${SDKPATHNATIVE}${bindir_nativesdk}/`basename $scriptfn`
+			targetscriptfn="${SDK_OUTPUT}/${SDKPATHNATIVE}${bindir_nativesdk}/$(basename $scriptfn)"
+			test -e ${targetscriptfn} || lnr ${scriptfn} ${targetscriptfn}
 		done
 	done
 	# We can't use the same method as above because files in the sysroot won't exist at this point
diff --git a/poky/meta/classes/python3native.bbclass b/poky/meta/classes/python3native.bbclass
index 89665ef..da12a71 100644
--- a/poky/meta/classes/python3native.bbclass
+++ b/poky/meta/classes/python3native.bbclass
@@ -1,8 +1,8 @@
 inherit python3-dir
 
-PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}"
-EXTRANATIVEPATH += "${PYTHON_PN}-native"
-DEPENDS_append = " ${PYTHON_PN}-native "
+PYTHON="${STAGING_BINDIR_NATIVE}/python3-native/python3"
+EXTRANATIVEPATH += "python3-native"
+DEPENDS_append = " python3-native "
 
 # python-config and other scripts are using distutils modules
 # which we patch to access these variables
diff --git a/poky/meta/classes/pythonnative.bbclass b/poky/meta/classes/pythonnative.bbclass
index 4cc8b27..ae6600c 100644
--- a/poky/meta/classes/pythonnative.bbclass
+++ b/poky/meta/classes/pythonnative.bbclass
@@ -1,11 +1,11 @@
 
 inherit python-dir
 
-PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}"
+PYTHON="${STAGING_BINDIR_NATIVE}/python-native/python"
 # PYTHON_EXECUTABLE is used by cmake
 PYTHON_EXECUTABLE="${PYTHON}"
-EXTRANATIVEPATH += "${PYTHON_PN}-native"
-DEPENDS_append = " ${PYTHON_PN}-native "
+EXTRANATIVEPATH += "python-native"
+DEPENDS_append = " python-native "
 
 # python-config and other scripts are using distutils modules
 # which we patch to access these variables
diff --git a/poky/meta/classes/reproducible_build.bbclass b/poky/meta/classes/reproducible_build.bbclass
index 2df8053..0eb696a 100644
--- a/poky/meta/classes/reproducible_build.bbclass
+++ b/poky/meta/classes/reproducible_build.bbclass
@@ -1,33 +1,35 @@
-#
 # reproducible_build.bbclass
 #
-# This bbclass is mainly responsible to determine SOURCE_DATE_EPOCH on a per recipe base.
-# We need to set a recipe specific SOURCE_DATE_EPOCH in each recipe environment for various tasks.
-# One way would be to modify all recipes one-by-one to specify SOURCE_DATE_EPOCH explicitly, 
-# but that is not realistic as there are hundreds (probably thousands) of recipes in various meta-layers.
-# Therefore we do it this class. 
-# After sources are unpacked but before they are patched, we try to determine the value for SOURCE_DATE_EPOCH.
+# Sets SOURCE_DATE_EPOCH in each component's build environment.
+# Upstream components (generally) respect this environment variable,
+# using it in place of the "current" date and time.
+# See https://reproducible-builds.org/specs/source-date-epoch/
 #
-# There are 4 ways to determine SOURCE_DATE_EPOCH:
+# After sources are unpacked but before they are patched, we set a reproducible value for SOURCE_DATE_EPOCH.
+# This value should be reproducible for anyone who builds the same revision from the same sources.
 #
-# 1. Use value from __source_date_epoch.txt file if this file exists. 
-#    This file was most likely created in the previous build by one of the following methods 2,3,4. 
-#    In principle, it could actually provided by a recipe via SRC_URI
+# There are 4 ways we determine SOURCE_DATE_EPOCH:
 #
-# If the file does not exist, first try to determine the value for SOURCE_DATE_EPOCH:
+# 1. Use the value from __source_date_epoch.txt file if this file exists.
+#    This file was most likely created in the previous build by one of the following methods 2,3,4.
+#    Alternatively, it can be provided by a recipe via SRC_URI.
 #
-# 2. If we detected a folder .git, use .git last commit date timestamp, as git does not allow checking out
-#    files and preserving their timestamps.
+# If the file does not exist:
+#
+# 2. If there is a git checkout, use the last git commit timestamp.
+#    Git does not preserve file timestamps on checkout.
 #
 # 3. Use the mtime of "known" files such as NEWS, CHANGLELOG, ...
-#    This will work fine for any well kept repository distributed via tarballs.
+#    This works for well-kept repositories distributed via tarball.
 #
-# 4. If the above steps fail, we need to check all package source files and use the youngest file of the source tree.
+# 4. If the above steps fail, use the modification time of the youngest file in the source tree.
 #
-# Once the value of SOURCE_DATE_EPOCH is determined, it is stored in the recipe ${WORKDIR}/source_date_epoch folder
-# in a text file "__source_date_epoch.txt'. If this file is found by other recipe task, the value is exported in
-# the SOURCE_DATE_EPOCH variable in the task environment. This is done in an anonymous python function, 
-# so SOURCE_DATE_EPOCH is guaranteed to exist for all tasks the may use it (do_configure, do_compile, do_package, ...)
+# Once the value of SOURCE_DATE_EPOCH is determined, it is stored in the recipe's SDE_FILE.
+# If none of these mechanisms are suitable, replace the do_deploy_source_date_epoch task
+# with recipe-specific functionality to write the appropriate SOURCE_DATE_EPOCH into the SDE_FILE.
+#
+# If this file is found by other tasks, the value is exported in the SOURCE_DATE_EPOCH variable.
+# SOURCE_DATE_EPOCH is set for all tasks that might use it (do_configure, do_compile, do_package, ...)
 
 BUILD_REPRODUCIBLE_BINARIES ??= '1'
 inherit ${@oe.utils.ifelse(d.getVar('BUILD_REPRODUCIBLE_BINARIES') == '1', 'reproducible_build_simple', '')}
@@ -50,86 +52,100 @@
 addtask do_deploy_source_date_epoch_setscene
 addtask do_deploy_source_date_epoch before do_configure after do_patch
 
-def get_source_date_epoch_known_files(d, path):
-    source_date_epoch = 0
+def get_source_date_epoch_from_known_files(d, sourcedir):
+    source_date_epoch = None
+    newest_file = None
     known_files = set(["NEWS", "ChangeLog", "Changelog", "CHANGES"])
     for file in known_files:
-        filepath = os.path.join(path,file)
+        filepath = os.path.join(sourcedir, file)
         if os.path.isfile(filepath):
-            mtime = int(os.path.getmtime(filepath))
+            mtime = int(os.lstat(filepath).st_mtime)
             # There may be more than one "known_file" present, if so, use the youngest one
-            if mtime > source_date_epoch:
+            if not source_date_epoch or mtime > source_date_epoch:
                 source_date_epoch = mtime
+                newest_file = filepath
+    if newest_file:
+        bb.debug(1, "SOURCE_DATE_EPOCH taken from: %s" % newest_file)
     return source_date_epoch
 
-def find_git_folder(path):
-    exclude = set(["temp", "license-destdir", "patches", "recipe-sysroot-native", "recipe-sysroot", "pseudo", "build", "image", "sysroot-destdir"])
-    for root, dirs, files in os.walk(path, topdown=True):
+def find_git_folder(d, sourcedir):
+    # First guess: WORKDIR/git
+    # This is the default git fetcher unpack path
+    workdir = d.getVar('WORKDIR')
+    gitpath = os.path.join(workdir, "git/.git")
+    if os.path.isdir(gitpath):
+        return gitpath
+
+    # Second guess: ${S}
+    gitpath = os.path.join(sourcedir, ".git")
+    if os.path.isdir(gitpath):
+        return gitpath
+
+    # Perhaps there was a subpath or destsuffix specified.
+    # Go looking in the WORKDIR
+    exclude = set(["build", "image", "license-destdir", "patches", "pseudo",
+                   "recipe-sysroot", "recipe-sysroot-native", "sysroot-destdir", "temp"])
+    for root, dirs, files in os.walk(workdir, topdown=True):
         dirs[:] = [d for d in dirs if d not in exclude]
         if '.git' in dirs:
-            #bb.warn("found root:%s" % (str(root)))
             return root
-     
-def get_source_date_epoch_git(d, path):
-    source_date_epoch = 0
-    if "git://" in d.getVar('SRC_URI'):
-        gitpath = find_git_folder(d.getVar('WORKDIR'))
-        if gitpath != None:
-            import subprocess
-            if os.path.isdir(os.path.join(gitpath,".git")):
-                try:
-                    source_date_epoch = int(subprocess.check_output(['git','log','-1','--pretty=%ct'], cwd=path))
-                    #bb.warn("JB *** gitpath:%s sde: %d" % (gitpath,source_date_epoch))
-                    bb.debug(1, "git repo path:%s sde: %d" % (gitpath,source_date_epoch))
-                except subprocess.CalledProcessError as grepexc:
-                    #bb.warn( "Expected git repository not found, (path: %s) error:%d" % (gitpath, grepexc.returncode))
-                    bb.debug(1, "Expected git repository not found, (path: %s) error:%d" % (gitpath, grepexc.returncode))
-        else:
-            bb.warn("Failed to find a git repository for path:%s" % (path))
-    return source_date_epoch
-            
-python do_create_source_date_epoch_stamp() {
-    path = d.getVar('S')
-    if not os.path.isdir(path):
-        bb.warn("Unable to determine source_date_epoch! path:%s" % path)
-        return
 
+    bb.warn("Failed to find a git repository in WORKDIR: %s" % workdir)
+    return None
+
+def get_source_date_epoch_from_git(d, sourcedir):
+    source_date_epoch = None
+    if "git://" in d.getVar('SRC_URI'):
+        gitpath = find_git_folder(d, sourcedir)
+        if gitpath:
+            import subprocess
+            source_date_epoch = int(subprocess.check_output(['git','log','-1','--pretty=%ct'], cwd=gitpath))
+            bb.debug(1, "git repository: %s" % gitpath)
+    return source_date_epoch
+
+def get_source_date_epoch_from_youngest_file(d, sourcedir):
+    # Do it the hard way: check all files and find the youngest one...
+    source_date_epoch = None
+    newest_file = None
+    # Just in case S = WORKDIR
+    exclude = set(["build", "image", "license-destdir", "patches", "pseudo",
+                   "recipe-sysroot", "recipe-sysroot-native", "sysroot-destdir", "temp"])
+    for root, dirs, files in os.walk(sourcedir, topdown=True):
+        files = [f for f in files if not f[0] == '.']
+        dirs[:] = [d for d in dirs if d not in exclude]
+
+        for fname in files:
+            filename = os.path.join(root, fname)
+            try:
+                mtime = int(os.lstat(filename).st_mtime)
+            except ValueError:
+                mtime = 0
+            if not source_date_epoch or mtime > source_date_epoch:
+                source_date_epoch = mtime
+                newest_file = filename
+
+    if newest_file:
+        bb.debug(1, "Newest file found: %s" % newest_file)
+    return source_date_epoch
+
+python do_create_source_date_epoch_stamp() {
     epochfile = d.getVar('SDE_FILE')
     if os.path.isfile(epochfile):
-        bb.debug(1, " path: %s reusing __source_date_epoch.txt" % epochfile)
+        bb.debug(1, "Reusing SOURCE_DATE_EPOCH from: %s" % epochfile)
         return
- 
-    # Try to detect/find a git repository
-    source_date_epoch = get_source_date_epoch_git(d, path)
+
+    sourcedir = d.getVar('S')
+    source_date_epoch = (
+        get_source_date_epoch_from_git(d, sourcedir) or
+        get_source_date_epoch_from_known_files(d, sourcedir) or
+        get_source_date_epoch_from_youngest_file(d, sourcedir) or
+        0       # Last resort
+    )
     if source_date_epoch == 0:
-        source_date_epoch = get_source_date_epoch_known_files(d, path)
-    if source_date_epoch == 0:
-        # Do it the hard way: check all files and find the youngest one...
-        filename_dbg = None
-        exclude = set(["temp", "license-destdir", "patches", "recipe-sysroot-native", "recipe-sysroot", "pseudo", "build", "image", "sysroot-destdir"])
-        for root, dirs, files in os.walk(path, topdown=True):
-            files = [f for f in files if not f[0] == '.']
-            dirs[:] = [d for d in dirs if d not in exclude]
+        # empty folder, not a single file ...
+        bb.debug(1, "No files found to determine SOURCE_DATE_EPOCH")
 
-            for fname in files:
-                filename = os.path.join(root, fname)
-                try:
-                    mtime = int(os.path.getmtime(filename))
-                except ValueError:
-                    mtime = 0
-                if mtime > source_date_epoch:
-                    source_date_epoch = mtime
-                    filename_dbg = filename
-
-        if filename_dbg != None:
-            bb.debug(1," SOURCE_DATE_EPOCH %d derived from: %s" % (source_date_epoch, filename_dbg))
-
-        if source_date_epoch == 0:
-            # empty folder, not a single file ...
-            # kernel source do_unpack is special cased
-            if not bb.data.inherits_class('kernel', d):
-                bb.debug(1, "Unable to determine source_date_epoch! path:%s" % path)
-
+    bb.debug(1, "SOURCE_DATE_EPOCH: %d" % source_date_epoch)
     bb.utils.mkdirhier(d.getVar('SDE_DIR'))
     with open(epochfile, 'w') as f:
         f.write(str(source_date_epoch))
@@ -145,6 +161,6 @@
         if os.path.isfile(epochfile):
             with open(epochfile, 'r') as f:
                 source_date_epoch = f.read()
-            bb.debug(1, "source_date_epoch stamp found ---> stamp %s" % source_date_epoch)
+            bb.debug(1, "SOURCE_DATE_EPOCH: %s" % source_date_epoch)
         d.setVar('SOURCE_DATE_EPOCH', source_date_epoch)
 }
diff --git a/poky/meta/classes/rm_work.bbclass b/poky/meta/classes/rm_work.bbclass
index 31d99e4..10e134b 100644
--- a/poky/meta/classes/rm_work.bbclass
+++ b/poky/meta/classes/rm_work.bbclass
@@ -47,59 +47,60 @@
     cd `dirname ${STAMP}`
     for i in `basename ${STAMP}`*
     do
-        for j in ${SSTATETASKS} do_shared_workdir
-        do
-            case $i in
-            *do_setscene*)
-                break
-                ;;
-            *sigdata*|*sigbasedata*)
-                i=dummy
-                break
-                ;;
-            *do_package_write*)
-                i=dummy
-                break
-                ;;
-            *do_image_complete*)
-                mv $i `echo $i | sed -e "s#do_image_complete#do_image_complete_setscene#"`
-                i=dummy
-                break
-                ;;
-            *do_rootfs*|*do_image*|*do_bootimg*|*do_write_qemuboot_conf*)
-                i=dummy
-                break
-                ;;
-            *do_build*)
-                i=dummy
-                break
-                ;;
-            *do_addto_recipe_sysroot*)
-                # Preserve recipe-sysroot-native if do_addto_recipe_sysroot has been used
-                excludes="$excludes recipe-sysroot-native"
-                i=dummy
-                break
-                ;;
+        # By default we'll delete the stamp, unless $i is changed by the inner loop
+        # (i=dummy does this)
+
+        case $i in
+        *sigdata*|*sigbasedata*)
+            # Save/skip anything that looks like a signature data file.
+            i=dummy
+            ;;
+        *do_image_complete_setscene*)
+            # Ensure we don't 'stack' setscene extensions to this stamp with the section below
+            i=dummy
+            ;;
+        *do_image_complete*)
+            # Promote do_image_complete stamps to setscene versions (ahead of *do_image* below)
+            mv $i `echo $i | sed -e "s#do_image_complete#do_image_complete_setscene#"`
+            i=dummy
+            ;;
+        *do_package_write*|*do_rootfs*|*do_image*|*do_bootimg*|*do_write_qemuboot_conf*|*do_build*)
+            i=dummy
+            ;;
+        *do_addto_recipe_sysroot*)
+            # Preserve recipe-sysroot-native if do_addto_recipe_sysroot has been used
+            excludes="$excludes recipe-sysroot-native"
+            i=dummy
+            ;;
+        *do_package|*do_package.*|*do_package_setscene.*)
             # We remove do_package entirely, including any
             # sstate version since otherwise we'd need to leave 'plaindirs' around
             # such as 'packages' and 'packages-split' and these can be large. No end
             # of chain tasks depend directly on do_package anymore.
-            *do_package|*do_package.*|*do_package_setscene.*)
-                rm -f $i;
-                i=dummy
-                break
-                ;;
-            *_setscene*)
-                i=dummy
+            rm -f $i;
+            i=dummy
+            ;;
+        *_setscene*)
+            # Skip stamps which are already setscene versions
+            i=dummy
+            ;;
+        esac
+
+        for j in ${SSTATETASKS} do_shared_workdir
+        do
+            case $i in
+            dummy)
                 break
                 ;;
             *$j|*$j.*)
+                # Promote the stamp to a setscene version
                 mv $i `echo $i | sed -e "s#${j}#${j}_setscene#"`
                 i=dummy
                 break
-            ;;
+                ;;
             esac
         done
+
         rm -f $i
     done
 
diff --git a/poky/meta/classes/rootfs-postcommands.bbclass b/poky/meta/classes/rootfs-postcommands.bbclass
index 221869e..bde58ad 100644
--- a/poky/meta/classes/rootfs-postcommands.bbclass
+++ b/poky/meta/classes/rootfs-postcommands.bbclass
@@ -2,9 +2,12 @@
 # Zap the root password if debug-tweaks feature is not enabled
 ROOTFS_POSTPROCESS_COMMAND += '${@bb.utils.contains_any("IMAGE_FEATURES", [ 'debug-tweaks', 'empty-root-password' ], "", "zap_empty_root_password ; ",d)}'
 
-# Allow dropbear/openssh to accept logins from accounts with an empty password string if debug-tweaks is enabled
+# Allow dropbear/openssh to accept logins from accounts with an empty password string if debug-tweaks or allow-empty-password is enabled
 ROOTFS_POSTPROCESS_COMMAND += '${@bb.utils.contains_any("IMAGE_FEATURES", [ 'debug-tweaks', 'allow-empty-password' ], "ssh_allow_empty_password; ", "",d)}'
 
+# Allow dropbear/openssh to accept root logins if debug-tweaks or allow-root-login is enabled
+ROOTFS_POSTPROCESS_COMMAND += '${@bb.utils.contains_any("IMAGE_FEATURES", [ 'debug-tweaks', 'allow-root-login' ], "ssh_allow_root_login; ", "",d)}'
+
 # Enable postinst logging if debug-tweaks is enabled
 ROOTFS_POSTPROCESS_COMMAND += '${@bb.utils.contains_any("IMAGE_FEATURES", [ 'debug-tweaks', 'post-install-logging' ], "postinst_enable_logging; ", "",d)}'
 
@@ -36,11 +39,6 @@
 
 ROOTFS_POSTPROCESS_COMMAND += 'empty_var_volatile;'
 
-# Disable DNS lookups, the SSH_DISABLE_DNS_LOOKUP can be overridden to allow
-# distros to choose not to take this change
-SSH_DISABLE_DNS_LOOKUP ?= " ssh_disable_dns_lookup ; "
-ROOTFS_POSTPROCESS_COMMAND_append_qemuall = "${SSH_DISABLE_DNS_LOOKUP}"
-
 # Sort the user and group entries in /etc by ID in order to make the content
 # deterministic. Package installs are not deterministic, causing the ordering
 # of entries to change between builds. In case that this isn't desired,
@@ -143,12 +141,11 @@
 }
 
 #
-# allow dropbear/openssh to accept root logins and logins from accounts with an empty password string
+# allow dropbear/openssh to accept logins from accounts with an empty password string
 #
 ssh_allow_empty_password () {
 	for config in sshd_config sshd_config_readonly; do
 		if [ -e ${IMAGE_ROOTFS}${sysconfdir}/ssh/$config ]; then
-			sed -i 's/^[#[:space:]]*PermitRootLogin.*/PermitRootLogin yes/' ${IMAGE_ROOTFS}${sysconfdir}/ssh/$config
 			sed -i 's/^[#[:space:]]*PermitEmptyPasswords.*/PermitEmptyPasswords yes/' ${IMAGE_ROOTFS}${sysconfdir}/ssh/$config
 		fi
 	done
@@ -171,9 +168,20 @@
 	fi
 }
 
-ssh_disable_dns_lookup () {
-	if [ -e ${IMAGE_ROOTFS}${sysconfdir}/ssh/sshd_config ]; then
-		sed -i -e 's:#UseDNS yes:UseDNS no:' ${IMAGE_ROOTFS}${sysconfdir}/ssh/sshd_config
+#
+# allow dropbear/openssh to accept root logins
+#
+ssh_allow_root_login () {
+	for config in sshd_config sshd_config_readonly; do
+		if [ -e ${IMAGE_ROOTFS}${sysconfdir}/ssh/$config ]; then
+			sed -i 's/^[#[:space:]]*PermitRootLogin.*/PermitRootLogin yes/' ${IMAGE_ROOTFS}${sysconfdir}/ssh/$config
+		fi
+	done
+
+	if [ -e ${IMAGE_ROOTFS}${sbindir}/dropbear ] ; then
+		if grep -q DROPBEAR_EXTRA_ARGS ${IMAGE_ROOTFS}${sysconfdir}/default/dropbear 2>/dev/null ; then
+			sed -i '/^DROPBEAR_EXTRA_ARGS=/ s/-w//' ${IMAGE_ROOTFS}${sysconfdir}/default/dropbear
+		fi
 	fi
 }
 
@@ -245,7 +253,6 @@
     pkgs = image_list_installed_packages(d)
     with open(manifest_name, 'w+') as image_manifest:
         image_manifest.write(format_pkg_list(pkgs, "ver"))
-        image_manifest.write("\n")
 
     if os.path.exists(manifest_name):
         manifest_link = deploy_dir + "/" + link_name + ".manifest"
@@ -308,17 +315,18 @@
 python write_image_test_data() {
     from oe.data import export2json
 
-    testdata = "%s/%s.testdata.json" % (d.getVar('DEPLOY_DIR_IMAGE'), d.getVar('IMAGE_NAME'))
-    testdata_link = "%s/%s.testdata.json" % (d.getVar('DEPLOY_DIR_IMAGE'), d.getVar('IMAGE_LINK_NAME'))
+    deploy_dir = d.getVar('IMGDEPLOYDIR')
+    link_name = d.getVar('IMAGE_LINK_NAME')
+    testdata_name = os.path.join(deploy_dir, "%s.testdata.json" % d.getVar('IMAGE_NAME'))
 
-    bb.utils.mkdirhier(os.path.dirname(testdata))
     searchString = "%s/"%(d.getVar("TOPDIR")).replace("//","/")
-    export2json(d, testdata,searchString=searchString,replaceString="")
+    export2json(d, testdata_name, searchString=searchString, replaceString="")
 
-    if testdata_link != testdata:
+    if os.path.exists(testdata_name):
+        testdata_link = os.path.join(deploy_dir, "%s.testdata.json" % link_name)
         if os.path.lexists(testdata_link):
-           os.remove(testdata_link)
-        os.symlink(os.path.basename(testdata), testdata_link)
+            os.remove(testdata_link)
+        os.symlink(os.path.basename(testdata_name), testdata_link)
 }
 write_image_test_data[vardepsexclude] += "TOPDIR"
 
diff --git a/poky/meta/classes/rootfs_deb.bbclass b/poky/meta/classes/rootfs_deb.bbclass
index 9ee1dfc..2b93796 100644
--- a/poky/meta/classes/rootfs_deb.bbclass
+++ b/poky/meta/classes/rootfs_deb.bbclass
@@ -6,7 +6,7 @@
 
 do_rootfs[depends] += "dpkg-native:do_populate_sysroot apt-native:do_populate_sysroot"
 do_populate_sdk[depends] += "dpkg-native:do_populate_sysroot apt-native:do_populate_sysroot bzip2-native:do_populate_sysroot"
-do_rootfs[recrdeptask] += "do_package_write_deb"
+do_rootfs[recrdeptask] += "do_package_write_deb do_package_qa"
 do_rootfs[vardeps] += "PACKAGE_FEED_URIS"
 
 do_rootfs[lockfiles] += "${DEPLOY_DIR_DEB}/deb.lock"
diff --git a/poky/meta/classes/rootfs_ipk.bbclass b/poky/meta/classes/rootfs_ipk.bbclass
index 52b468d..aabc370 100644
--- a/poky/meta/classes/rootfs_ipk.bbclass
+++ b/poky/meta/classes/rootfs_ipk.bbclass
@@ -10,7 +10,7 @@
 
 do_rootfs[depends] += "opkg-native:do_populate_sysroot opkg-utils-native:do_populate_sysroot"
 do_populate_sdk[depends] += "opkg-native:do_populate_sysroot opkg-utils-native:do_populate_sysroot"
-do_rootfs[recrdeptask] += "do_package_write_ipk"
+do_rootfs[recrdeptask] += "do_package_write_ipk do_package_qa"
 do_rootfs[vardeps] += "PACKAGE_FEED_URIS"
 
 do_rootfs[lockfiles] += "${WORKDIR}/ipk.lock"
diff --git a/poky/meta/classes/rootfs_rpm.bbclass b/poky/meta/classes/rootfs_rpm.bbclass
index 7f305f5..51f89ea 100644
--- a/poky/meta/classes/rootfs_rpm.bbclass
+++ b/poky/meta/classes/rootfs_rpm.bbclass
@@ -23,7 +23,7 @@
 do_rootfs[depends] += "${RPMROOTFSDEPENDS}"
 do_populate_sdk[depends] += "${RPMROOTFSDEPENDS}"
 
-do_rootfs[recrdeptask] += "do_package_write_rpm"
+do_rootfs[recrdeptask] += "do_package_write_rpm do_package_qa"
 do_rootfs[vardeps] += "PACKAGE_FEED_URIS"
 
 python () {
diff --git a/poky/meta/classes/setuptools.bbclass b/poky/meta/classes/setuptools.bbclass
index 56343b1..a923ea3 100644
--- a/poky/meta/classes/setuptools.bbclass
+++ b/poky/meta/classes/setuptools.bbclass
@@ -1,8 +1,3 @@
 inherit distutils
 
-DEPENDS += "python-distribute-native"
-
-DISTUTILS_INSTALL_ARGS = "--root=${D} \
-    --prefix=${prefix} \
-    --install-lib=${PYTHON_SITEPACKAGES_DIR} \
-    --install-data=${datadir}"
+DEPENDS += "python-setuptools-native"
diff --git a/poky/meta/classes/setuptools3.bbclass b/poky/meta/classes/setuptools3.bbclass
index de6dd94..8ca66ee 100644
--- a/poky/meta/classes/setuptools3.bbclass
+++ b/poky/meta/classes/setuptools3.bbclass
@@ -2,7 +2,3 @@
 
 DEPENDS += "python3-setuptools-native"
 
-DISTUTILS_INSTALL_ARGS = "--root=${D} \
-    --prefix=${prefix} \
-    --install-lib=${PYTHON_SITEPACKAGES_DIR} \
-    --install-data=${datadir}"
diff --git a/poky/meta/classes/siteinfo.bbclass b/poky/meta/classes/siteinfo.bbclass
index 86bb853..411e704 100644
--- a/poky/meta/classes/siteinfo.bbclass
+++ b/poky/meta/classes/siteinfo.bbclass
@@ -15,11 +15,13 @@
 # It is an error for the target not to exist.
 # If 'what' doesn't exist then an empty value is returned
 #
-def siteinfo_data(d):
+def siteinfo_data_for_machine(arch, os, d):
     archinfo = {
         "allarch": "endian-little bit-32", # bogus, but better than special-casing the checks below for allarch
         "aarch64": "endian-little bit-64 arm-common arm-64",
         "aarch64_be": "endian-big bit-64 arm-common arm-64",
+        "arc": "endian-little bit-32 arc-common",
+        "arceb": "endian-big bit-32 arc-common",
         "arm": "endian-little bit-32 arm-common arm-32",
         "armeb": "endian-big bit-32 arm-common arm-32",
         "avr32": "endian-big bit-32 avr32-common",
@@ -30,6 +32,8 @@
         "i586": "endian-little bit-32 ix86-common",
         "i686": "endian-little bit-32 ix86-common",
         "ia64": "endian-little bit-64",
+        "lm32": "endian-big bit-32",
+        "m68k": "endian-big bit-32",
         "microblaze": "endian-big bit-32 microblaze-common",
         "microblazeeb": "endian-big bit-32 microblaze-common",
         "microblazeel": "endian-little bit-32 microblaze-common",
@@ -128,15 +132,13 @@
         locs = { "archinfo" : archinfo, "osinfo" : osinfo, "targetinfo" : targetinfo, "d" : d}
         archinfo, osinfo, targetinfo = bb.utils.better_eval(call, locs)
 
-    hostarch = d.getVar("HOST_ARCH")
-    hostos = d.getVar("HOST_OS")
-    target = "%s-%s" % (hostarch, hostos)
+    target = "%s-%s" % (arch, os)
 
     sitedata = []
-    if hostarch in archinfo:
-        sitedata.extend(archinfo[hostarch].split())
-    if hostos in osinfo:
-        sitedata.extend(osinfo[hostos].split())
+    if arch in archinfo:
+        sitedata.extend(archinfo[arch].split())
+    if os in osinfo:
+        sitedata.extend(osinfo[os].split())
     if target in targetinfo:
         sitedata.extend(targetinfo[target].split())
     sitedata.append(target)
@@ -145,6 +147,9 @@
     bb.debug(1, "SITE files %s" % sitedata);
     return sitedata
 
+def siteinfo_data(d):
+    return siteinfo_data_for_machine(d.getVar("HOST_ARCH"), d.getVar("HOST_OS"), d)
+
 python () {
     sitedata = set(siteinfo_data(d))
     if "endian-little" in sitedata:
diff --git a/poky/meta/classes/spdx.bbclass b/poky/meta/classes/spdx.bbclass
index c5f544d..fb78e27 100644
--- a/poky/meta/classes/spdx.bbclass
+++ b/poky/meta/classes/spdx.bbclass
@@ -202,18 +202,13 @@
     return
 
 def hash_file(file_name):
-    try:
-        with open(file_name, 'rb') as f:
-            data_string = f.read()
-            sha1 = hash_string(data_string)
-            return sha1
-    except:
-        return None
+    from bb.utils import sha1_file
+    return sha1_file(file_name)
 
 def hash_string(data):
     import hashlib
     sha1 = hashlib.sha1()
-    sha1.update(data)
+    sha1.update(data.encode('utf-8'))
     return sha1.hexdigest()
 
 def run_fossology(foss_command, full_spdx):
@@ -226,7 +221,7 @@
     except subprocess.CalledProcessError as e:
         return None
 
-    foss_output = string.replace(foss_output, '\r', '')
+    foss_output = foss_output.replace('\r', '')
 
     # Package info
     package_info = {}
@@ -289,7 +284,8 @@
 def get_ver_code(dirname):
     chksums = []
     for f_dir, f in list_files(dirname):
-        hash = hash_file(os.path.join(dirname, f_dir, f))
+        path = os.path.join(dirname, f_dir, f)
+        hash = hash_file(path)
         if not hash is None:
             chksums.append(hash)
         else:
diff --git a/poky/meta/classes/sstate.bbclass b/poky/meta/classes/sstate.bbclass
index 0b28850..efb0096 100644
--- a/poky/meta/classes/sstate.bbclass
+++ b/poky/meta/classes/sstate.bbclass
@@ -25,14 +25,21 @@
 SSTATE_EXTRAPATH[vardepvalue] = ""
 
 # For multilib rpm the allarch packagegroup files can overwrite (in theory they're identical)
-SSTATE_DUPWHITELIST = "${DEPLOY_DIR_IMAGE}/ ${DEPLOY_DIR}/licenses/ ${DEPLOY_DIR_RPM}/noarch/"
+SSTATE_DUPWHITELIST = "${DEPLOY_DIR}/licenses/"
 # Avoid docbook/sgml catalog warnings for now
 SSTATE_DUPWHITELIST += "${STAGING_ETCDIR_NATIVE}/sgml ${STAGING_DATADIR_NATIVE}/sgml"
 # sdk-provides-dummy-nativesdk and nativesdk-buildtools-perl-dummy overlap for different SDKMACHINE
 SSTATE_DUPWHITELIST += "${DEPLOY_DIR_RPM}/sdk_provides_dummy_nativesdk/ ${DEPLOY_DIR_IPK}/sdk-provides-dummy-nativesdk/"
 SSTATE_DUPWHITELIST += "${DEPLOY_DIR_RPM}/buildtools_dummy_nativesdk/ ${DEPLOY_DIR_IPK}/buildtools-dummy-nativesdk/"
+# target-sdk-provides-dummy overlaps that allarch is disabled when multilib is used
+SSTATE_DUPWHITELIST += "${COMPONENTS_DIR}/sdk-provides-dummy-target/ ${DEPLOY_DIR_RPM}/sdk_provides_dummy_target/ ${DEPLOY_DIR_IPK}/sdk-provides-dummy-target/"
 # Archive the sources for many architectures in one deploy folder
 SSTATE_DUPWHITELIST += "${DEPLOY_DIR_SRC}"
+# ovmf/grub-efi/systemd-boot/intel-microcode multilib recipes can generate identical overlapping files
+SSTATE_DUPWHITELIST += "${DEPLOY_DIR_IMAGE}/ovmf"
+SSTATE_DUPWHITELIST += "${DEPLOY_DIR_IMAGE}/grub-efi"
+SSTATE_DUPWHITELIST += "${DEPLOY_DIR_IMAGE}/systemd-boot"
+SSTATE_DUPWHITELIST += "${DEPLOY_DIR_IMAGE}/microcode"
 
 SSTATE_SCAN_FILES ?= "*.la *-config *_config postinst-*"
 SSTATE_SCAN_CMD ??= 'find ${SSTATE_BUILDDIR} \( -name "${@"\" -o -name \"".join(d.getVar("SSTATE_SCAN_FILES").split())}" \) -type f'
@@ -59,7 +66,6 @@
 SSTATEPOSTUNPACKFUNCS = "sstate_hardcode_path_unpack"
 SSTATEPOSTINSTFUNCS = ""
 EXTRA_STAGING_FIXMES ?= "HOSTTOOLS_DIR"
-SSTATECLEANFUNCS = ""
 
 # Check whether sstate exists for tasks that support sstate and are in the
 # locked signatures file.
@@ -301,7 +307,7 @@
     sstatepkg = d.getVar('SSTATE_PKG') + '_' + ss['task'] + ".tgz"
 
     if not os.path.exists(sstatepkg):
-        pstaging_fetch(sstatefetch, sstatepkg, d)
+        pstaging_fetch(sstatefetch, d)
 
     if not os.path.isfile(sstatepkg):
         bb.note("Staging package %s does not exist" % sstatepkg)
@@ -408,7 +414,7 @@
         bb.note("Replacing fixme paths in sstate package: %s" % (sstate_hardcode_cmd))
         subprocess.check_call(sstate_hardcode_cmd, shell=True)
 
-        # Need to remove this or we'd copy it into the target directory and may 
+        # Need to remove this or we'd copy it into the target directory and may
         # conflict with another writer
         os.remove(fixmefn)
 }
@@ -507,10 +513,6 @@
                 stfile.endswith(rm_nohash):
             oe.path.remove(stfile)
 
-    # Removes the users/groups created by the package
-    for cleanfunc in (d.getVar('SSTATECLEANFUNCS') or '').split():
-        bb.build.exec_func(cleanfunc, d)
-
 sstate_clean[vardepsexclude] = "SSTATE_MANFILEPREFIX"
 
 CLEANFUNCS += "sstate_cleanall"
@@ -640,7 +642,7 @@
 
     return
 
-def pstaging_fetch(sstatefetch, sstatepkg, d):
+def pstaging_fetch(sstatefetch, d):
     import bb.fetch2
 
     # Only try and fetch if the user has configured a mirror
@@ -720,17 +722,24 @@
 #
 sstate_create_package () {
 	TFILE=`mktemp ${SSTATE_PKG}.XXXXXXXX`
+
+        # Use pigz if available
+        OPT="-czS"
+        if [ -x "$(command -v pigz)" ]; then
+            OPT="-I pigz -cS"
+        fi
+
 	# Need to handle empty directories
 	if [ "$(ls -A)" ]; then
 		set +e
-		tar -czf $TFILE *
+		tar $OPT -f $TFILE *
 		ret=$?
 		if [ $ret -ne 0 ] && [ $ret -ne 1 ]; then
 			exit 1
 		fi
 		set -e
 	else
-		tar -cz --file=$TFILE --files-from=/dev/null
+		tar $OPT --file=$TFILE --files-from=/dev/null
 	fi
 	chmod 0664 $TFILE
 	mv -f $TFILE ${SSTATE_PKG}
@@ -890,6 +899,18 @@
             evdata['found'].append( (sq_fn[task], sq_task[task], sq_hash[task], sstatefile ) )
         bb.event.fire(bb.event.MetadataEvent("MissedSstate", evdata), d)
 
+    # Print some summary statistics about the current task completion and how much sstate
+    # reuse there was. Avoid divide by zero errors.
+    total = len(sq_fn)
+    currentcount = d.getVar("BB_SETSCENE_STAMPCURRENT_COUNT") or 0
+    complete = 0
+    if currentcount:
+        complete = (len(ret) + currentcount) / (total + currentcount) * 100
+    match = 0
+    if total:
+        match = len(ret) / total * 100
+    bb.plain("Sstate summary: Wanted %d Found %d Missed %d Current %d (%d%% match, %d%% complete)" % (total, len(ret), len(missed), currentcount, match, complete))
+
     if hasattr(bb.parse.siggen, "checkhashes"):
         bb.parse.siggen.checkhashes(missed, ret, sq_fn, sq_task, sq_hash, sq_hashfn, d)
 
@@ -902,6 +923,7 @@
     # task is included in taskdependees too
     # Return - False - We need this dependency
     #        - True - We can skip this dependency
+    import re
 
     def logit(msg, log):
         if log is not None:
@@ -956,11 +978,24 @@
 
         # Consider sysroot depending on sysroot tasks
         if taskdependees[task][1] == 'do_populate_sysroot' and taskdependees[dep][1] == 'do_populate_sysroot':
-            # base-passwd/shadow-sysroot don't need their dependencies
-            if taskdependees[dep][0].endswith(("base-passwd", "shadow-sysroot")):
-                continue
-            # Nothing need depend on libc-initial/gcc-cross-initial
-            if "-initial" in taskdependees[task][0]:
+            # Allow excluding certain recursive dependencies. If a recipe needs it should add a
+            # specific dependency itself, rather than relying on one of its dependees to pull
+            # them in.
+            # See also http://lists.openembedded.org/pipermail/openembedded-core/2018-January/146324.html
+            not_needed = False
+            excludedeps = d.getVar('_SSTATE_EXCLUDEDEPS_SYSROOT')
+            if excludedeps is None:
+                # Cache the regular expressions for speed
+                excludedeps = []
+                for excl in (d.getVar('SSTATE_EXCLUDEDEPS_SYSROOT') or "").split():
+                    excludedeps.append((re.compile(excl.split('->', 1)[0]), re.compile(excl.split('->', 1)[1])))
+                d.setVar('_SSTATE_EXCLUDEDEPS_SYSROOT', excludedeps)
+            for excl in excludedeps:
+                if excl[0].match(taskdependees[dep][0]):
+                    if excl[1].match(taskdependees[task][0]):
+                        not_needed = True
+                        break
+            if not_needed:
                 continue
             # For meta-extsdk-toolchain we want all sysroot dependencies
             if taskdependees[dep][0] == 'meta-extsdk-toolchain':
@@ -1007,7 +1042,7 @@
         bb.siggen.dump_this_task(sstatepkg + '_' + taskname + ".tgz" ".siginfo", d)
 }
 
-SSTATE_PRUNE_OBSOLETEWORKDIR = "1"
+SSTATE_PRUNE_OBSOLETEWORKDIR ?= "1"
 
 # Event handler which removes manifests and stamps file for
 # recipes which are no longer reachable in a build where they
@@ -1027,6 +1062,16 @@
         with open(preservestampfile, 'r') as f:
             preservestamps = f.readlines()
     seen = []
+
+    # The machine index contains all the stamps this machine has ever seen in this build directory.
+    # We should only remove things which this machine once accessed but no longer does.
+    machineindex = set()
+    bb.utils.mkdirhier(d.expand("${SSTATE_MANIFESTS}"))
+    mi = d.expand("${SSTATE_MANIFESTS}/index-machine-${MACHINE}")
+    if os.path.exists(mi):
+        with open(mi, "r") as f:
+            machineindex = set(line.strip() for line in f.readlines())
+
     for a in sorted(list(set(d.getVar("SSTATE_ARCHS").split()))):
         toremove = []
         i = d.expand("${SSTATE_MANIFESTS}/index-" + a)
@@ -1036,7 +1081,7 @@
             lines = f.readlines()
             for l in lines:
                 (stamp, manifest, workdir) = l.split()
-                if stamp not in stamps and stamp not in preservestamps:
+                if stamp not in stamps and stamp not in preservestamps and stamp in machineindex:
                     toremove.append(l)
                     if stamp not in seen:
                         bb.debug(2, "Stamp %s is not reachable, removing related manifests" % stamp)
@@ -1065,6 +1110,11 @@
         with open(i, "w") as f:
             for l in lines:
                 f.write(l)
+    machineindex |= set(stamps)
+    with open(mi, "w") as f:
+        for l in machineindex:
+            f.write(l + "\n")
+
     if preservestamps:
         os.remove(preservestampfile)
 }
diff --git a/poky/meta/classes/staging.bbclass b/poky/meta/classes/staging.bbclass
index 939042e..84e13ba 100644
--- a/poky/meta/classes/staging.bbclass
+++ b/poky/meta/classes/staging.bbclass
@@ -70,7 +70,7 @@
 python sysroot_strip () {
     inhibit_sysroot = d.getVar('INHIBIT_SYSROOT_STRIP')
     if inhibit_sysroot and oe.types.boolean(inhibit_sysroot):
-        return 0
+        return
 
     dstdir = d.getVar('SYSROOT_DESTDIR')
     pn = d.getVar('PN')
@@ -79,7 +79,7 @@
     qa_already_stripped = 'already-stripped' in (d.getVar('INSANE_SKIP_' + pn) or "").split()
     strip_cmd = d.getVar("STRIP")
 
-    oe.package.strip_execs(pn, dstdir, strip_cmd, libdir, base_libdir,
+    oe.package.strip_execs(pn, dstdir, strip_cmd, libdir, base_libdir, d,
                            qa_already_stripped=qa_already_stripped)
 }
 
@@ -256,7 +256,7 @@
     workdir = d.getVar("WORKDIR")
     #bb.warn(str(taskdepdata))
     pn = d.getVar("PN")
-
+    mc = d.getVar("BB_CURRENT_MC")
     stagingdir = d.getVar("STAGING_DIR")
     sharedmanifests = d.getVar("COMPONENTS_DIR") + "/manifests"
     recipesysroot = d.getVar("RECIPE_SYSROOT")
@@ -294,12 +294,14 @@
     start = set([start])
 
     sstatetasks = d.getVar("SSTATETASKS").split()
+    # Add recipe specific tasks referenced by setscene_depvalid()
+    sstatetasks.append("do_stash_locale")
 
     def print_dep_tree(deptree):
         data = ""
         for dep in deptree:
             deps = "    " + "\n    ".join(deptree[dep][3]) + "\n"
-            data = "%s:\n  %s\n  %s\n%s  %s\n  %s\n" % (deptree[dep][0], deptree[dep][1], deptree[dep][2], deps, deptree[dep][4], deptree[dep][5])
+            data = data + "%s:\n  %s\n  %s\n%s  %s\n  %s\n" % (deptree[dep][0], deptree[dep][1], deptree[dep][2], deps, deptree[dep][4], deptree[dep][5])
         return data
 
     #bb.note("Full dep tree is:\n%s" % print_dep_tree(taskdepdata))
@@ -443,7 +445,13 @@
 
     msg_exists = []
     msg_adding = []
+
     for dep in configuredeps:
+        if mc != 'default':
+            # We should not care about other multiconfigs
+            depmc = dep.split(':')[1]
+            if depmc != mc:
+                continue
         c = setscenedeps[dep][0]
         if c not in installed:
             continue
diff --git a/poky/meta/classes/systemd.bbclass b/poky/meta/classes/systemd.bbclass
index 1b13432..c7b784d 100644
--- a/poky/meta/classes/systemd.bbclass
+++ b/poky/meta/classes/systemd.bbclass
@@ -34,10 +34,10 @@
 		systemctl daemon-reload
 	fi
 
-	systemctl $OPTS ${SYSTEMD_AUTO_ENABLE} ${SYSTEMD_SERVICE}
+	systemctl $OPTS ${SYSTEMD_AUTO_ENABLE} ${SYSTEMD_SERVICE_ESCAPED}
 
 	if [ -z "$D" -a "${SYSTEMD_AUTO_ENABLE}" = "enable" ]; then
-		systemctl --no-block restart ${SYSTEMD_SERVICE}
+		systemctl --no-block restart ${SYSTEMD_SERVICE_ESCAPED}
 	fi
 fi
 }
@@ -51,10 +51,10 @@
 
 if type systemctl >/dev/null 2>/dev/null; then
 	if [ -z "$D" ]; then
-		systemctl stop ${SYSTEMD_SERVICE}
+		systemctl stop ${SYSTEMD_SERVICE_ESCAPED}
 	fi
 
-	systemctl $OPTS disable ${SYSTEMD_SERVICE}
+	systemctl $OPTS disable ${SYSTEMD_SERVICE_ESCAPED}
 fi
 }
 
@@ -65,6 +65,7 @@
 
 python systemd_populate_packages() {
     import re
+    import shlex
 
     if not bb.utils.contains('DISTRO_FEATURES', 'systemd', True, False, d):
         return
@@ -85,6 +86,9 @@
     def systemd_generate_package_scripts(pkg):
         bb.debug(1, 'adding systemd calls to postinst/postrm for %s' % pkg)
 
+        paths_escaped = ' '.join(shlex.quote(s) for s in d.getVar('SYSTEMD_SERVICE_' + pkg, True).split())
+        d.setVar('SYSTEMD_SERVICE_ESCAPED_' + pkg, paths_escaped)
+
         # Add pkg to the overrides so that it finds the SYSTEMD_SERVICE_pkg
         # variable.
         localdata = d.createCopy()
@@ -130,7 +134,7 @@
                 systemd_add_files_and_parse(pkg_systemd, path, service_base + '@.service', keys)
             for key in keys.split():
                 # recurse all dependencies found in keys ('Also';'Conflicts';..) and add to files
-                cmd = "grep %s %s | sed 's,%s=,,g' | tr ',' '\\n'" % (key, fullpath, key)
+                cmd = "grep %s %s | sed 's,%s=,,g' | tr ',' '\\n'" % (key, shlex.quote(fullpath), key)
                 pipe = os.popen(cmd, 'r')
                 line = pipe.readline()
                 while line:
diff --git a/poky/meta/classes/terminal.bbclass b/poky/meta/classes/terminal.bbclass
index a27e10c..73e765d 100644
--- a/poky/meta/classes/terminal.bbclass
+++ b/poky/meta/classes/terminal.bbclass
@@ -25,7 +25,8 @@
     bb.utils.mkdirhier(os.path.dirname(runfile))
 
     with open(runfile, 'w') as script:
-        script.write('#!/bin/sh -e\n')
+        script.write('#!/usr/bin/env %s\n' % d.getVar('SHELL'))
+        script.write('set -e\n')
         bb.data.emit_func(cmd_func, script, envdata)
         script.write(cmd_func)
         script.write("\n")
diff --git a/poky/meta/classes/testexport.bbclass b/poky/meta/classes/testexport.bbclass
index d070f07..59cbaef 100644
--- a/poky/meta/classes/testexport.bbclass
+++ b/poky/meta/classes/testexport.bbclass
@@ -131,6 +131,11 @@
     shutil.copy2(image_manifest, os.path.join(test_data_path, 'manifest'))
     shutil.copy2(tdname, os.path.join(test_data_path, 'testdata.json'))
 
+    for subdir, dirs, files in os.walk(export_path):
+        for dir in dirs:
+            if dir == '__pycache__':
+                shutil.rmtree(os.path.join(subdir, dir))
+
     # Create tar file for common parts of testexport
     create_tarball(d, "testexport.tar.gz", d.getVar("TEST_EXPORT_DIR"))
 
diff --git a/poky/meta/classes/testimage-auto.bbclass b/poky/meta/classes/testimage-auto.bbclass
deleted file mode 100644
index e0a22b7..0000000
--- a/poky/meta/classes/testimage-auto.bbclass
+++ /dev/null
@@ -1,23 +0,0 @@
-# Copyright (C) 2013 Intel Corporation
-#
-# Released under the MIT license (see COPYING.MIT)
-
-
-# Run tests automatically on an image after the image is constructed
-# (as opposed to testimage.bbclass alone where tests must be called
-# manually using bitbake -c testimage <image>).
-#
-# NOTE: to use this class, simply set TEST_IMAGE = "1" - no need to
-# inherit it since that will be done in image.bbclass when this variable
-# has been set.
-#
-# See testimage.bbclass for the test implementation.
-
-inherit testimage
-
-python do_testimage_auto() {
-    testimage_main(d)
-}
-addtask testimage_auto before do_build after do_image_complete
-do_testimage_auto[depends] += "${TESTIMAGEDEPENDS}"
-do_testimage_auto[lockfiles] += "${TESTIMAGELOCK}"
diff --git a/poky/meta/classes/testimage.bbclass b/poky/meta/classes/testimage.bbclass
index a9e8b49..f2ff91d 100644
--- a/poky/meta/classes/testimage.bbclass
+++ b/poky/meta/classes/testimage.bbclass
@@ -10,6 +10,11 @@
 # - first add IMAGE_CLASSES += "testimage" in local.conf
 # - build a qemu core-image-sato
 # - then bitbake core-image-sato -c testimage. That will run a standard suite of tests.
+#
+# The tests can be run automatically each time an image is built if you set
+# TESTIMAGE_AUTO = "1"
+
+TESTIMAGE_AUTO ??= "0"
 
 # You can set (or append to) TEST_SUITES in local.conf to select the tests
 # which you want to run for your target.
@@ -35,25 +40,30 @@
 TEST_EXTRACTED_DIR ?= "${TEST_NEEDED_PACKAGES_DIR}/extracted"
 TEST_PACKAGED_DIR ?= "${TEST_NEEDED_PACKAGES_DIR}/packaged"
 
-RPMTESTSUITE = "${@bb.utils.contains('IMAGE_PKGTYPE', 'rpm', 'dnf rpm', '', d)}"
+PKGMANTESTSUITE = "\
+    ${@bb.utils.contains('IMAGE_PKGTYPE', 'rpm', 'dnf rpm', '', d)} \
+    ${@bb.utils.contains('IMAGE_PKGTYPE', 'ipk', 'opkg', '', d)} \
+    ${@bb.utils.contains('IMAGE_PKGTYPE', 'deb', 'apt', '', d)} \
+    "
 SYSTEMDSUITE = "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
 MINTESTSUITE = "ping"
 NETTESTSUITE = "${MINTESTSUITE} ssh df date scp oe_syslog ${SYSTEMDSUITE}"
 DEVTESTSUITE = "gcc kernelmodule ldd"
+PTESTTESTSUITE = "${MINTESTSUITE} ssh scp ptest"
 
 DEFAULT_TEST_SUITES = "${MINTESTSUITE} auto"
 DEFAULT_TEST_SUITES_pn-core-image-minimal = "${MINTESTSUITE}"
 DEFAULT_TEST_SUITES_pn-core-image-minimal-dev = "${MINTESTSUITE}"
 DEFAULT_TEST_SUITES_pn-core-image-full-cmdline = "${NETTESTSUITE} perl python logrotate ptest"
 DEFAULT_TEST_SUITES_pn-core-image-x11 = "${MINTESTSUITE}"
-DEFAULT_TEST_SUITES_pn-core-image-lsb = "${NETTESTSUITE} pam parselogs ${RPMTESTSUITE} ptest"
-DEFAULT_TEST_SUITES_pn-core-image-sato = "${NETTESTSUITE} connman xorg parselogs ${RPMTESTSUITE} \
+DEFAULT_TEST_SUITES_pn-core-image-lsb = "${NETTESTSUITE} pam parselogs ${PKGMANTESTSUITE} ptest"
+DEFAULT_TEST_SUITES_pn-core-image-sato = "${NETTESTSUITE} connman xorg parselogs ${PKGMANTESTSUITE} \
     ${@bb.utils.contains('IMAGE_PKGTYPE', 'rpm', 'python', '', d)} ptest gi"
 DEFAULT_TEST_SUITES_pn-core-image-sato-sdk = "${NETTESTSUITE} buildcpio buildlzip buildgalculator \
-    connman ${DEVTESTSUITE} logrotate perl parselogs python ${RPMTESTSUITE} xorg ptest gi stap"
-DEFAULT_TEST_SUITES_pn-core-image-lsb-dev = "${NETTESTSUITE} pam perl python parselogs ${RPMTESTSUITE} ptest gi"
+    connman ${DEVTESTSUITE} logrotate perl parselogs python ${PKGMANTESTSUITE} xorg ptest gi stap"
+DEFAULT_TEST_SUITES_pn-core-image-lsb-dev = "${NETTESTSUITE} pam perl python parselogs ${PKGMANTESTSUITE} ptest gi"
 DEFAULT_TEST_SUITES_pn-core-image-lsb-sdk = "${NETTESTSUITE} buildcpio buildlzip buildgalculator \
-    connman ${DEVTESTSUITE} logrotate pam parselogs perl python ${RPMTESTSUITE} ptest gi stap"
+    connman ${DEVTESTSUITE} logrotate pam parselogs perl python ${PKGMANTESTSUITE} ptest gi stap"
 DEFAULT_TEST_SUITES_pn-meta-toolchain = "auto"
 
 # aarch64 has no graphics
@@ -73,13 +83,13 @@
 TEST_TARGET ?= "qemu"
 
 TESTIMAGEDEPENDS = ""
-TESTIMAGEDEPENDS_qemuall = "qemu-native:do_populate_sysroot qemu-helper-native:do_populate_sysroot qemu-helper-native:do_addto_recipe_sysroot"
+TESTIMAGEDEPENDS_append_qemuall = " qemu-native:do_populate_sysroot qemu-helper-native:do_populate_sysroot qemu-helper-native:do_addto_recipe_sysroot"
 TESTIMAGEDEPENDS += "${@bb.utils.contains('IMAGE_PKGTYPE', 'rpm', 'cpio-native:do_populate_sysroot', '', d)}"
-TESTIMAGEDEPENDS_qemuall += "${@bb.utils.contains('IMAGE_PKGTYPE', 'rpm', 'cpio-native:do_populate_sysroot', '', d)}"
-TESTIMAGEDEPENDS_qemuall += "${@bb.utils.contains('IMAGE_PKGTYPE', 'rpm', 'createrepo-c-native:do_populate_sysroot', '', d)}"
+TESTIMAGEDEPENDS_append_qemuall = " ${@bb.utils.contains('IMAGE_PKGTYPE', 'rpm', 'cpio-native:do_populate_sysroot', '', d)}"
+TESTIMAGEDEPENDS_append_qemuall = " ${@bb.utils.contains('IMAGE_PKGTYPE', 'rpm', 'createrepo-c-native:do_populate_sysroot', '', d)}"
 TESTIMAGEDEPENDS += "${@bb.utils.contains('IMAGE_PKGTYPE', 'rpm', 'dnf-native:do_populate_sysroot', '', d)}"
-TESTIMAGEDEPENDS += "${@bb.utils.contains('IMAGE_PKGTYPE', 'ipk', 'opkg-utils-native:do_populate_sysroot', '', d)}"
-TESTIMAGEDEPENDS += "${@bb.utils.contains('IMAGE_PKGTYPE', 'deb', 'apt-native:do_populate_sysroot', '', d)}"
+TESTIMAGEDEPENDS += "${@bb.utils.contains('IMAGE_PKGTYPE', 'ipk', 'opkg-utils-native:do_populate_sysroot package-index:do_package_index', '', d)}"
+TESTIMAGEDEPENDS += "${@bb.utils.contains('IMAGE_PKGTYPE', 'deb', 'apt-native:do_populate_sysroot  package-index:do_package_index', '', d)}"
 TESTIMAGEDEPENDS += "${@bb.utils.contains('IMAGE_PKGTYPE', 'rpm', 'createrepo-c-native:do_populate_sysroot', '', d)}"
 
 TESTIMAGELOCK = "${TMPDIR}/testimage.lock"
@@ -141,7 +151,7 @@
                     'IMAGE_BASENAME': d.getVar("IMAGE_BASENAME"),
                     'IMAGE_PKGTYPE': d.getVar("IMAGE_PKGTYPE"),
                     'STARTTIME': d.getVar("DATETIME"),
-                    'HOST_DISTRO': ('-'.join(platform.linux_distribution())).replace(' ', '-'),
+                    'HOST_DISTRO': oe.lsb.distro_identifier().replace(' ', '-'),
                     'LAYERS': get_layers(d.getVar("BBLAYERS"))}
     return configuration
 get_testimage_configuration[vardepsexclude] = "DATETIME"
@@ -240,8 +250,8 @@
     # Get use_kvm
     qemu_use_kvm = d.getVar("QEMU_USE_KVM")
     if qemu_use_kvm and \
-       (oe.types.boolean(qemu_use_kvm) and 'x86' in machine or \
-        d.getVar('MACHINE') in qemu_use_kvm.split()):
+       (d.getVar('MACHINE') in qemu_use_kvm.split() or \
+        oe.types.boolean(qemu_use_kvm) and 'x86' in machine):
         kvm = True
     else:
         kvm = False
@@ -363,6 +373,7 @@
     return None
 
 def create_rpm_index(d):
+    import glob
     # Index RPMs
     rpm_createrepo = bb.utils.which(os.getenv('PATH'), "createrepo_c")
     index_cmds = []
@@ -379,9 +390,13 @@
         lf = bb.utils.lockfile(lockfilename, False)
         oe.path.copyhardlinktree(rpm_dir, idx_path)
         # Full indexes overload a 256MB image so reduce the number of rpms
-        # in the feed. Filter to r* since we use the run-postinst packages and
-        # this leaves some allarch and machine arch packages too.
-        bb.utils.remove(idx_path + "*/[a-qs-z]*.rpm")
+        # in the feed by filtering to specific packages needed by the tests.
+        package_list = glob.glob(idx_path + "*/*.rpm")
+
+        for pkg in package_list:
+            if not os.path.basename(pkg).startswith(("rpm", "run-postinsts", "busybox", "bash", "update-alternatives", "libc6", "curl", "musl")):
+                bb.utils.remove(pkg)
+
         bb.utils.unlockfile(lf)
         cmd = '%s --update -q %s' % (rpm_createrepo, idx_path)
 
@@ -404,4 +419,9 @@
 
 testimage_main[vardepsexclude] += "BB_ORIGENV DATETIME"
 
+python () {
+    if oe.types.boolean(d.getVar("TESTIMAGE_AUTO") or "False"):
+        bb.build.addtask("testimage", "do_build", "do_image_complete", d)
+}
+
 inherit testsdk
diff --git a/poky/meta/classes/testsdk.bbclass b/poky/meta/classes/testsdk.bbclass
index 6981d40..458c3f4 100644
--- a/poky/meta/classes/testsdk.bbclass
+++ b/poky/meta/classes/testsdk.bbclass
@@ -23,7 +23,7 @@
                     'IMAGE_BASENAME': d.getVar("IMAGE_BASENAME"),
                     'IMAGE_PKGTYPE': d.getVar("IMAGE_PKGTYPE"),
                     'STARTTIME': d.getVar("DATETIME"),
-                    'HOST_DISTRO': ('-'.join(platform.linux_distribution())).replace(' ', '-'),
+                    'HOST_DISTRO': oe.lsb.distro_identifier().replace(' ', '-'),
                     'LAYERS': get_layers(d.getVar("BBLAYERS"))}
     return configuration
 get_sdk_configuration[vardepsexclude] = "DATETIME"
@@ -66,6 +66,14 @@
     host_pkg_manifest = OESDKTestContextExecutor._load_manifest(
         d.expand("${SDK_DEPLOY}/${TOOLCHAIN_OUTPUTNAME}.host.manifest"))
 
+    processes = d.getVar("TESTIMAGE_NUMBER_THREADS") or d.getVar("BB_NUMBER_THREADS")
+    if processes:
+        try:
+            import testtools, subunit
+        except ImportError:
+            bb.warn("Failed to import testtools or subunit, the testcases will run serially")
+            processes = None
+
     sdk_dir = d.expand("${WORKDIR}/testimage-sdk/")
     bb.utils.remove(sdk_dir, True)
     bb.utils.mkdirhier(sdk_dir)
@@ -89,7 +97,10 @@
             import traceback
             bb.fatal("Loading tests failed:\n%s" % traceback.format_exc())
 
-        result = tc.runTests()
+        if processes:
+            result = tc.runTests(processes=int(processes))
+        else:
+            result = tc.runTests()
 
         component = "%s %s" % (pn, OESDKTestContextExecutor.name)
         context_msg = "%s:%s" % (os.path.basename(tcname), os.path.basename(sdk_env))
@@ -179,6 +190,7 @@
             f.write('SSTATE_MIRRORS += " \\n file://.* file://%s/PATH"\n' % test_data.get('SSTATE_DIR'))
             f.write('SOURCE_MIRROR_URL = "file://%s"\n' % test_data.get('DL_DIR'))
             f.write('INHERIT += "own-mirrors"\n')
+            f.write('PREMIRRORS_prepend = " git://git.yoctoproject.org/.* git://%s/git2/git.yoctoproject.org.BASENAME \\n "\n' % test_data.get('DL_DIR'))
 
         # We need to do this in case we have a minimal SDK
         subprocess.check_output(". %s > /dev/null; devtool sdk-install meta-extsdk-toolchain" % \
@@ -218,3 +230,8 @@
 addtask testsdkext
 do_testsdkext[nostamp] = "1"
 
+python () {
+    if oe.types.boolean(d.getVar("TESTIMAGE_AUTO") or "False"):
+        bb.build.addtask("testsdk", None, "do_populate_sdk", d)
+        bb.build.addtask("testsdkext", None, "do_populate_sdk_ext", d)
+}
diff --git a/poky/meta/classes/toolchain-scripts.bbclass b/poky/meta/classes/toolchain-scripts.bbclass
index 71da5e5..6d1ba69 100644
--- a/poky/meta/classes/toolchain-scripts.bbclass
+++ b/poky/meta/classes/toolchain-scripts.bbclass
@@ -51,6 +51,10 @@
 	echo "export OECORE_NATIVE_SYSROOT=\"$sdkpathnative\"" >> $script
 	echo 'export OECORE_TARGET_SYSROOT="$SDKTARGETSYSROOT"' >> $script
 	echo "export OECORE_ACLOCAL_OPTS=\"-I $sdkpathnative/usr/share/aclocal\"" >> $script
+	echo 'export OECORE_BASELIB="${baselib}"' >> $script
+	echo 'export OECORE_TARGET_ARCH="${TARGET_ARCH}"' >>$script
+	echo 'export OECORE_TARGET_OS="${TARGET_OS}"' >>$script
+
 	echo 'unset command_not_found_handle' >> $script
 
 	toolchain_shared_env_script
@@ -118,14 +122,34 @@
 }
 
 toolchain_create_post_relocate_script() {
-	script=$1
-	rm -f $script
-	touch $script
+	relocate_script=$1
+	env_dir=$2
+	rm -f $relocate_script
+	touch $relocate_script
 
-    cat >> $script <<EOF
+	cat >> $relocate_script <<EOF
+# Source top-level SDK env scripts in case they are needed for the relocate
+# scripts.
+for env_setup_script in ${env_dir}/environment-setup-*; do
+    . \$env_setup_script
+    status=\$?
+    if [ \$status != 0 ]; then
+        echo "\$0: Failed to source \$env_setup_script with status \$status"
+        exit \$status
+    fi
+done
+
 if [ -d "${SDKPATHNATIVE}/post-relocate-setup.d/" ]; then
-    for s in ${SDKPATHNATIVE}/post-relocate-setup.d/*.sh; do
+    for s in ${SDKPATHNATIVE}/post-relocate-setup.d/*; do
+        if [ ! -x \$s ]; then
+            continue
+        fi
         \$s "\$1"
+        status=\$?
+        if [ \$status != 0 ]; then
+            echo "post-relocate command \"\$s \$1\" failed with status \$status" >&2
+            exit \$status
+        fi
     done
     rm -rf "${SDKPATHNATIVE}/post-relocate-setup.d"
 fi
diff --git a/poky/meta/classes/uboot-extlinux-config.bbclass b/poky/meta/classes/uboot-extlinux-config.bbclass
index 61dff14..c65c421 100644
--- a/poky/meta/classes/uboot-extlinux-config.bbclass
+++ b/poky/meta/classes/uboot-extlinux-config.bbclass
@@ -58,7 +58,7 @@
 #
 # The kernel has an internal default console, which you can override with
 # a console=...some_tty...
-UBOOT_EXTLINUX_CONSOLE ??= "console=${console}"
+UBOOT_EXTLINUX_CONSOLE ??= "console=${console},${baudrate}"
 UBOOT_EXTLINUX_LABELS ??= "linux"
 UBOOT_EXTLINUX_FDT ??= ""
 UBOOT_EXTLINUX_FDTDIR ??= "../"
diff --git a/poky/meta/classes/uninative.bbclass b/poky/meta/classes/uninative.bbclass
index de2221a..ba99fb6 100644
--- a/poky/meta/classes/uninative.bbclass
+++ b/poky/meta/classes/uninative.bbclass
@@ -1,10 +1,11 @@
-UNINATIVE_LOADER ?= "${UNINATIVE_STAGING_DIR}-uninative/${BUILD_ARCH}-linux/lib/${@bb.utils.contains('BUILD_ARCH', 'x86_64', 'ld-linux-x86-64.so.2', 'ld-linux.so.2', d)}"
+UNINATIVE_LOADER ?= "${UNINATIVE_STAGING_DIR}-uninative/${BUILD_ARCH}-linux/lib/${@bb.utils.contains('BUILD_ARCH', 'x86_64', 'ld-linux-x86-64.so.2', '', d)}${@bb.utils.contains('BUILD_ARCH', 'i686', 'ld-linux.so.2', '', d)}${@bb.utils.contains('BUILD_ARCH', 'aarch64', 'ld-linux-aarch64.so.1', '', d)}"
 UNINATIVE_STAGING_DIR ?= "${STAGING_DIR}"
 
 UNINATIVE_URL ?= "unset"
 UNINATIVE_TARBALL ?= "${BUILD_ARCH}-nativesdk-libc.tar.bz2"
 # Example checksums
-#UNINATIVE_CHECKSUM[i586] = "dead"
+#UNINATIVE_CHECKSUM[aarch64] = "dead"
+#UNINATIVE_CHECKSUM[i686] = "dead"
 #UNINATIVE_CHECKSUM[x86_64] = "dead"
 UNINATIVE_DLDIR ?= "${DL_DIR}/uninative/"
 
diff --git a/poky/meta/classes/update-rc.d.bbclass b/poky/meta/classes/update-rc.d.bbclass
index 06e3b21..265c4be 100644
--- a/poky/meta/classes/update-rc.d.bbclass
+++ b/poky/meta/classes/update-rc.d.bbclass
@@ -39,9 +39,9 @@
 updatercd_postinst() {
 if ${@use_updatercd(d)} && type update-rc.d >/dev/null 2>/dev/null; then
 	if [ -n "$D" ]; then
-		OPT="-r $D"
+		OPT="-f -r $D"
 	else
-		OPT="-s"
+		OPT="-f -s"
 	fi
 	update-rc.d $OPT ${INITSCRIPT_NAME} ${INITSCRIPT_PARAMS}
 fi
diff --git a/poky/meta/classes/useradd_base.bbclass b/poky/meta/classes/useradd_base.bbclass
index 551c82c..0d0bdb8 100644
--- a/poky/meta/classes/useradd_base.bbclass
+++ b/poky/meta/classes/useradd_base.bbclass
@@ -51,10 +51,10 @@
 	local groupname=`echo "$opts" | awk '{ for (i = 1; i < NF; i++) if ($i == "-g" || $i == "--group") print $(i+1) }'`
 	local username=`echo "$opts" | awk '{ for (i = 1; i < NF; i++) if ($i == "-a" || $i == "--add") print $(i+1) }'`
 	bbnote "${PN}: Running groupmems command with group $groupname and user $username"
-	local mem_exists="`grep "^$groupname:[^:]*:[^:]*:\([^,]*,\)*$username\(,[^,]*\)*" $rootdir/etc/group || true`"
+	local mem_exists="`grep "^$groupname:[^:]*:[^:]*:\([^,]*,\)*$username\(,[^,]*\)*$" $rootdir/etc/group || true`"
 	if test "x$mem_exists" = "x"; then
 		eval flock -x $rootdir${sysconfdir} -c \"$PSEUDO groupmems \$opts\" || true
-		mem_exists="`grep "^$groupname:[^:]*:[^:]*:\([^,]*,\)*$username\(,[^,]*\)*" $rootdir/etc/group || true`"
+		mem_exists="`grep "^$groupname:[^:]*:[^:]*:\([^,]*,\)*$username\(,[^,]*\)*$" $rootdir/etc/group || true`"
 		if test "x$mem_exists" = "x"; then
 			bbfatal "${PN}: groupmems command did not succeed."
 		fi
diff --git a/poky/meta/classes/utils.bbclass b/poky/meta/classes/utils.bbclass
index 3f4f51b..0016e5c 100644
--- a/poky/meta/classes/utils.bbclass
+++ b/poky/meta/classes/utils.bbclass
@@ -328,15 +328,8 @@
 def all_multilib_tune_values(d, var, unique = True, need_split = True, delim = ' '):
     """Return a string of all ${var} in all multilib tune configuration"""
     values = []
-    value = d.getVar(var) or ""
-    if value != "":
-        if need_split:
-            for item in value.split(delim):
-                values.append(item)
-        else:
-            values.append(value)
-    variants = d.getVar("MULTILIB_VARIANTS") or ""
-    for item in variants.split():
+    variants = (d.getVar("MULTILIB_VARIANTS") or "").split() + ['']
+    for item in variants:
         localdata = get_multilib_datastore(item, d)
         # We need WORKDIR to be consistent with the original datastore
         localdata.setVar("WORKDIR", d.getVar("WORKDIR"))
@@ -367,23 +360,10 @@
     values = {}
     for v in vars:
         values[v] = []
-
-    localdata = bb.data.createCopy(d)
-    overrides = localdata.getVar("OVERRIDES", False).split(":")
-    newoverrides = []
-    for o in overrides:
-        if not o.startswith("virtclass-multilib-"):
-            newoverrides.append(o)
-    localdata.setVar("OVERRIDES", ":".join(newoverrides))
-    localdata.setVar("MLPREFIX", "")
-    origdefault = localdata.getVar("DEFAULTTUNE_MULTILIB_ORIGINAL")
-    if origdefault:
-        localdata.setVar("DEFAULTTUNE", origdefault)
     values['ml'] = ['']
-    for v in vars:
-        values[v].append(localdata.getVar(v))
-    variants = d.getVar("MULTILIB_VARIANTS") or ""
-    for item in variants.split():
+
+    variants = (d.getVar("MULTILIB_VARIANTS") or "").split() + ['']
+    for item in variants:
         localdata = get_multilib_datastore(item, d)
         values[v].append(localdata.getVar(v))
         values['ml'].append(item)
diff --git a/poky/meta/conf/bitbake.conf b/poky/meta/conf/bitbake.conf
index ac403b1..dcf2007 100644
--- a/poky/meta/conf/bitbake.conf
+++ b/poky/meta/conf/bitbake.conf
@@ -93,7 +93,7 @@
 # Architecture-dependent build variables.
 ##################################################################
 
-# Immediate expansion since there is no point in reapeatedly calling
+# Immediate expansion since there is no point in repeatedly calling
 # os.uname() throughout parsing
 BUILD_ARCH := "${@os.uname()[4]}"
 BUILD_OS := "${@os.uname()[0].lower()}"
@@ -308,7 +308,8 @@
 FILES_${PN}-dev = "${includedir} ${FILES_SOLIBSDEV} ${libdir}/*.la \
                 ${libdir}/*.o ${libdir}/pkgconfig ${datadir}/pkgconfig \
                 ${datadir}/aclocal ${base_libdir}/*.o \
-                ${libdir}/${BPN}/*.la ${base_libdir}/*.la"
+                ${libdir}/${BPN}/*.la ${base_libdir}/*.la \
+                ${libdir}/cmake ${datadir}/cmake"
 SECTION_${PN}-dev = "devel"
 ALLOW_EMPTY_${PN}-dev = "1"
 RDEPENDS_${PN}-dev = "${PN} (= ${EXTENDPKGV})"
@@ -318,7 +319,6 @@
 RDEPENDS_${PN}-staticdev = "${PN}-dev (= ${EXTENDPKGV})"
 
 FILES_${PN}-dbg = "/usr/lib/debug /usr/src/debug"
-
 SECTION_${PN}-dbg = "devel"
 ALLOW_EMPTY_${PN}-dbg = "1"
 
@@ -445,8 +445,9 @@
 
 IMAGE_ROOTFS = "${WORKDIR}/rootfs"
 IMAGE_BASENAME = "${PN}"
-IMAGE_NAME = "${IMAGE_BASENAME}-${MACHINE}-${DATETIME}"
-IMAGE_NAME[vardepsexclude] += "DATETIME"
+IMAGE_VERSION_SUFFIX = "-${DATETIME}"
+IMAGE_VERSION_SUFFIX[vardepsexclude] += "DATETIME"
+IMAGE_NAME = "${IMAGE_BASENAME}-${MACHINE}${IMAGE_VERSION_SUFFIX}"
 IMAGE_LINK_NAME = "${IMAGE_BASENAME}-${MACHINE}"
 
 # This option allows for a percentage overage of the actual image size rather than a
@@ -475,22 +476,23 @@
 HOSTTOOLS_DIR = "${TMPDIR}/hosttools"
 
 # Tools needed to run builds with OE-Core
+# python is special cased to point at python2
 HOSTTOOLS += " \
     [ ar as awk basename bash bzip2 cat chgrp chmod chown chrpath cmp comm cp cpio \
     cpp cut date dd diff diffstat dirname du echo egrep env expand expr false \
     fgrep file find flock g++ gawk gcc getconf getopt git grep gunzip gzip \
     head hostname id install ld ldd ln ls make makeinfo md5sum mkdir mknod \
-    mktemp mv nm objcopy objdump od patch perl pod2man pr printf pwd python python2 \
+    mktemp mv nm objcopy objdump od patch perl pod2man pr printf pwd python2 \
     python2.7 python3 ranlib readelf readlink rm rmdir rpcgen sed sh sha256sum \
     sleep sort split stat strings strip tail tar tee test touch tr true uname \
     uniq wc wget which xargs \
 "
 
 # Tools needed to run testimage runtime image testing
-HOSTTOOLS += "${@'ip ping ps scp ssh stty' if (bb.data.inherits_class('testimage', d) or d.getVar('TEST_IMAGE') == '1') else ''}"
+HOSTTOOLS += "${@'ip ping ps scp ssh stty' if (bb.utils.contains_any('IMAGE_CLASSES', 'testimage testsdk', True, False, d) or any(x in (d.getVar("BBINCLUDED") or "") for x in ["testimage.bbclass", "testsdk.bbclass"])) else ''}"
 
 # Link to these if present
-HOSTTOOLS_NONFATAL += "aws ccache gcc-ar gpg ld.bfd ld.gold nc sftp socat ssh sudo"
+HOSTTOOLS_NONFATAL += "aws ccache gcc-ar gpg ld.bfd ld.gold nc pigz sftp socat ssh sudo"
 
 # Temporary add few more detected in bitbake world
 HOSTTOOLS_NONFATAL += "join nl size yes zcat"
@@ -585,8 +587,10 @@
 
 TARGET_LINK_HASH_STYLE ?= "${@['-Wl,--hash-style=gnu',''][d.getVar('LINKER_HASH_STYLE') != 'gnu']}"
 
+ASNEEDED ?= "-Wl,--as-needed"
+
 export LDFLAGS = "${TARGET_LDFLAGS}"
-export TARGET_LDFLAGS = "-Wl,-O1 ${TARGET_LINK_HASH_STYLE}"
+export TARGET_LDFLAGS = "-Wl,-O1 ${TARGET_LINK_HASH_STYLE} ${ASNEEDED}"
 
 # Pass parallel make options to the compile task
 EXTRA_OEMAKE_prepend_task-compile = "${PARALLEL_MAKE} "
@@ -607,9 +611,9 @@
 # Disabled until the option works properly -feliminate-dwarf2-dups
 FULL_OPTIMIZATION = "-O2 -pipe ${DEBUG_FLAGS}"
 DEBUG_OPTIMIZATION = "-O -fno-omit-frame-pointer ${DEBUG_FLAGS} -pipe"
-SELECTED_OPTIMIZATION = "${@d.getVar(['FULL_OPTIMIZATION', 'DEBUG_OPTIMIZATION'][d.getVar('DEBUG_BUILD') == '1'])}"
+SELECTED_OPTIMIZATION = "${@d.getVar(oe.utils.vartrue('DEBUG_BUILD', 'DEBUG_OPTIMIZATION', 'FULL_OPTIMIZATION', d))}"
 SELECTED_OPTIMIZATION[vardeps] += "FULL_OPTIMIZATION DEBUG_OPTIMIZATION"
-BUILD_OPTIMIZATION = "-O2 -pipe"
+BUILD_OPTIMIZATION = "${@oe.utils.vartrue('DEBUG_BUILD', '-O -g -feliminate-unused-debug-types -fno-omit-frame-pointer', '-O2', d)} -pipe"
 
 ##################################################################
 # Settings used by bitbake-layers.
@@ -719,20 +723,18 @@
 # is a bad idea. Setting a dummy value is better than a ton of anonymous python.
 DISTRO ??= "nodistro"
 DISTRO_NAME ??= "OpenEmbedded"
+
 # Overrides are processed left to right, so the ones that are named later take precedence.
-# You generally want them to go from least to most specific.
-#
-# This means that an envionment variable named '<foo>_arm' overrides an
-# environment variable '<foo>' (when ${TARGET_ARCH} is arm).
-# An environment variable '<foo>_qemuarm' overrides '<foo>' and overrides
-# '<foo>_arm' when ${MACHINE} is 'qemuarm'.
+# You generally want them to go from least to most specific. This means that:
+# A variable '<foo>_arm' overrides a variable '<foo>' when ${TARGET_ARCH} is arm.
+# A variable '<foo>_qemuarm' overrides '<foo>' and overrides '<foo>_arm' when ${MACHINE} is 'qemuarm'.
 # If you use combination ie '<foo>_qemuarm_arm', then '<foo>_qemuarm_arm' will override
 # '<foo>_qemuarm' and then '<foo>' will be overriden with that value from '<foo>_qemuarm'.
 # And finally '<foo>_forcevariable' overrides any standard variable, with the highest priority.
+# This works for functions as well, they are really just variables.
 #
-# This works for  functions as well, they are really just environment variables.
-# Default OVERRIDES to make compilation fail fast in case of build system misconfiguration.
-OVERRIDES = "${TARGET_OS}:${TRANSLATED_TARGET_ARCH}:build-${BUILD_OS}:pn-${PN}:${MACHINEOVERRIDES}:${DISTROOVERRIDES}:${CLASSOVERRIDE}:forcevariable"
+OVERRIDES = "${TARGET_OS}:${TRANSLATED_TARGET_ARCH}:pn-${PN}:${MACHINEOVERRIDES}:${DISTROOVERRIDES}:${CLASSOVERRIDE}${LIBCOVERRIDE}:forcevariable"
+LIBCOVERRIDE ?= ""
 CLASSOVERRIDE ?= "class-target"
 DISTROOVERRIDES ?= "${@d.getVar('DISTRO') or ''}"
 MACHINEOVERRIDES ?= "${MACHINE}"
@@ -877,7 +879,7 @@
     file-checksums python func task export unexport noexec nostamp dirs cleandirs \
     sstate-lockfile-shared prefuncs postfuncs export_func deptask rdeptask \
     recrdeptask nodeprrecs stamp-extra-info sstate-outputdirs filename lineno \
-    progress"
+    progress mcdepends"
 
 MLPREFIX ??= ""
 MULTILIB_VARIANTS ??= ""
diff --git a/poky/meta/conf/distro/include/as-needed.inc b/poky/meta/conf/distro/include/as-needed.inc
deleted file mode 100644
index 6a8ad9d..0000000
--- a/poky/meta/conf/distro/include/as-needed.inc
+++ /dev/null
@@ -1,13 +0,0 @@
-
-ASNEEDED = "-Wl,--as-needed"
-
-ASNEEDED_pn-babeltrace = ""
-ASNEEDED_pn-console-tools = ""
-ASNEEDED_pn-distcc = ""
-ASNEEDED_pn-openobex = ""
-ASNEEDED_pn-icu = ""
-ASNEEDED_pn-pciutils = ""
-ASNEEDED_pn-puzzles = ""
-ASNEEDED_pn-rpm = ""
-
-TARGET_LDFLAGS += "${ASNEEDED}"
diff --git a/poky/meta/conf/distro/include/default-distrovars.inc b/poky/meta/conf/distro/include/default-distrovars.inc
index 9620ad4..f5ec6ce 100644
--- a/poky/meta/conf/distro/include/default-distrovars.inc
+++ b/poky/meta/conf/distro/include/default-distrovars.inc
@@ -14,7 +14,7 @@
 DISTRO_FEATURES_LIBC_DEFAULT ?= "ipv4 ipv6 libc-backtrace libc-big-macros libc-bsd libc-cxx-tests libc-catgets libc-charsets libc-crypt \
 					libc-crypt-ufc libc-db-aliases libc-envz libc-fcvt libc-fmtmsg libc-fstab libc-ftraverse \
 					libc-getlogin libc-idn libc-inet-anl libc-libm libc-locales libc-locale-code \
-					libc-memusage libc-nis libc-nsswitch libc-rcmd libc-rtld-debug libc-spawn libc-streams libc-sunrpc \
+					libc-memusage libc-nsswitch libc-rcmd libc-rtld-debug libc-spawn libc-streams \
 					libc-utmp libc-utmpx libc-wordexp libc-posix-clang-wchar libc-posix-regexp libc-posix-regexp-glibc \
 					libc-posix-wchar-io"
 DISTRO_FEATURES_LIBC ?= "${DISTRO_FEATURES_LIBC_DEFAULT}"
@@ -24,7 +24,6 @@
 IMAGE_FEATURES ?= ""
 
 WHITELIST_GPL-3.0 ?= ""
-LGPLv2_WHITELIST_GPL-3.0 ?= ""
 
 COMMERCIAL_AUDIO_PLUGINS ?= ""
 # COMMERCIAL_AUDIO_PLUGINS ?= "gst-plugins-ugly-mad gst-plugins-ugly-mpegaudioparse"
diff --git a/poky/meta/conf/distro/include/default-providers.inc b/poky/meta/conf/distro/include/default-providers.inc
index e65c1ed..019ceeb 100644
--- a/poky/meta/conf/distro/include/default-providers.inc
+++ b/poky/meta/conf/distro/include/default-providers.inc
@@ -23,9 +23,9 @@
 VIRTUAL-RUNTIME_apm ?= "apm"
 VIRTUAL-RUNTIME_alsa-state ?= "alsa-state"
 VIRTUAL-RUNTIME_getopt ?= "util-linux-getopt"
-VIRTUAL-RUNTIME_wireless-tools ?= "iw wireless-tools"
 VIRTUAL-RUNTIME_base-utils ?= "busybox"
 VIRTUAL-RUNTIME_base-utils-hwclock ?= "busybox-hwclock"
+VIRTUAL-RUNTIME_base-utils-syslog ?= "busybox-syslog"
 
 #
 # Default recipe providers
diff --git a/poky/meta/conf/distro/include/default-versions.inc b/poky/meta/conf/distro/include/default-versions.inc
index 3d88e8f..a6f3313 100644
--- a/poky/meta/conf/distro/include/default-versions.inc
+++ b/poky/meta/conf/distro/include/default-versions.inc
@@ -2,6 +2,3 @@
 # Default preferred versions
 #
 
-PREFERRED_VERSION_openssl ?= "1.0.%"
-PREFERRED_VERSION_openssl-native ?= "1.0.%"
-PREFERRED_VERSION_nativesdk-openssl ?= "1.0.%"
diff --git a/poky/meta/conf/distro/include/distro_alias.inc b/poky/meta/conf/distro/include/distro_alias.inc
index 13c7e65..7502542 100644
--- a/poky/meta/conf/distro/include/distro_alias.inc
+++ b/poky/meta/conf/distro/include/distro_alias.inc
@@ -15,7 +15,6 @@
 DISTRO_PN_ALIAS_pn-atk = "Fedora=atk OpenSuSE=atk"
 DISTRO_PN_ALIAS_pn-avahi-ui = "Ubuntu=avahi-discover Debian=avahi-discover"
 DISTRO_PN_ALIAS_pn-babeltrace = "OSPDT"
-DISTRO_PN_ALIAS_pn-bigreqsproto = "Meego=xorg-x11-proto-bigreqsproto"
 DISTRO_PN_ALIAS_pn-bjam = "OpenSuSE=boost-jam Debina=bjam"
 DISTRO_PN_ALIAS_pn-blktool = "Debian=blktool Mandriva=blktool"
 DISTRO_PN_ALIAS_pn-bluez5 = "Fedora=bluez  Opensuse=bluez"
@@ -25,7 +24,6 @@
 DISTRO_PN_ALIAS_pn-build-compare = "Opensuse=build-compare Fedora=build-compare"
 DISTRO_PN_ALIAS_pn-builder = "OE-Core"
 DISTRO_PN_ALIAS_pn-buildtools-tarball = "OE-Core"
-DISTRO_PN_ALIAS_pn-calibrateproto = "OSPDT upstream=http://cgit.freedesktop.org/xorg/proto/calibrateproto"
 DISTRO_PN_ALIAS_pn-cdrtools = "OpenSUSE=cdrtools OSPDT"
 DISTRO_PN_ALIAS_pn-chkconfig-alternatives = "Mandriva=chkconfig Debian=chkconfig"
 DISTRO_PN_ALIAS_pn-clutter = "Fedora=clutter OpenSuse=clutter Ubuntu=clutter-1.0 Mandriva=clutter Debian=clutter"
@@ -37,7 +35,6 @@
 DISTRO_PN_ALIAS_pn-clutter-gtk-1.8 = "Fedora=clutter-gtk OpenSuSE=clutter-gtk Ubuntu=clutter-gtk-0.10 Mandriva=clutter-gtk Debian=clutter-gtk"
 DISTRO_PN_ALIAS_pn-cogl-1.0 = "Debian=cogl Ubuntu=cogl Fedora=cogl"
 DISTRO_PN_ALIAS_pn-cogl = "Fedora=cogl OpenSuse=cogl Ubuntu=cogl Mandriva=cogl Debian=cogl"
-DISTRO_PN_ALIAS_pn-compositeproto = "Meego=xorg-x11-proto-compositeproto"
 DISTRO_PN_ALIAS_pn-connman = "Meego=connman"
 DISTRO_PN_ALIAS_pn-connman-conf = "OE-Core"
 DISTRO_PN_ALIAS_pn-connman-gnome = "Intel"
@@ -68,14 +65,12 @@
 DISTRO_PN_ALIAS_pn-cryptodev-module = "OE-Core"
 DISTRO_PN_ALIAS_pn-cryptodev-tests = "OE-Core"
 DISTRO_PN_ALIAS_pn-cwautomacros = "OSPDT upstream=http://cwautomacros.berlios.de/"
-DISTRO_PN_ALIAS_pn-damageproto = "Meego=xorg-x11-proto-damageproto"
 DISTRO_PN_ALIAS_pn-db = "Debian=db5.1 Ubuntu=db5.1"
 DISTRO_PN_ALIAS_pn-dbus-test = "Fedora=dbus Ubuntu=dbus"
 DISTRO_PN_ALIAS_pn-dbus-wait = "OpenedHand"
 DISTRO_PN_ALIAS_pn-depmodwrapper-cross = "OE-Core"
 DISTRO_PN_ALIAS_pn-distcc = "Debian=distcc Fedora=distcc"
 DISTRO_PN_ALIAS_pn-distcc-config = "OpenedHand"
-DISTRO_PN_ALIAS_pn-dmxproto = "Meego=xorg-x11-proto-dmxproto Ubuntu=x11proto-dmx Debian=x11proto-dmx"
 DISTRO_PN_ALIAS_pn-docbook-dsssl-stylesheets = "Fedora=docbook-style-dsssl Ubuntu=docbook-dsssl"
 DISTRO_PN_ALIAS_pn-docbook-sgml-dtd-3.1 = "Fedora=docbook-dtds Mandriva=docbook-dtd31-sgml"
 DISTRO_PN_ALIAS_pn-docbook-sgml-dtd-4.1 = "Fedora=docbook-dtds Mandriva=docbook-dtd41-sgml"
@@ -83,21 +78,14 @@
 DISTRO_PN_ALIAS_pn-docbook-xml-dtd4 = "Ubuntu=docbook-xml Fedora=docbook-dtds"
 DISTRO_PN_ALIAS_pn-docbook-xml-dtd4-native = "Ubuntu=docbook-xml Fedora=docbook-dtds"
 DISTRO_PN_ALIAS_pn-docbook-xsl-stylesheets = "Fedora=docbook-xsl-stylesheets Opensuse=docbook-xsl-stylesheets"
-DISTRO_PN_ALIAS_pn-dri2proto = "Meego=xorg-x11-proto-dri2proto"
-DISTRO_PN_ALIAS_pn-dri3proto = "Fedora=dri3proto Opensuse=dri3proto-devel"
 DISTRO_PN_ALIAS_pn-dropbear = "Debian=dropbear Ubuntu=dropbear"
 DISTRO_PN_ALIAS_pn-dtc = "Fedora=dtc Ubuntu=dtc"
-DISTRO_PN_ALIAS_pn-eee-acpi-scripts = "Debian=eeepc-acpi-scripts Ubuntu=eeepc-acpi-scripts"
 DISTRO_PN_ALIAS_pn-eglinfo-fb = "OE-Core"
 DISTRO_PN_ALIAS_pn-eglinfo-x11 = "OE-Core"
 DISTRO_PN_ALIAS_pn-encodings = "Ubuntu=xfonts-encodings Mandriva=x11-font-encodings Debian=xfonts-encodings"
-DISTRO_PN_ALIAS_pn-fixesproto = "Meego=xorg-x11-proto-fixesproto"
 DISTRO_PN_ALIAS_pn-font-alias = "Fedora=xorg-x11-fonts-base Mandriva=x11-font-alias Meego=xorg-x11-fonts"
-DISTRO_PN_ALIAS_pn-fontcacheproto = "Meego=xorg-x11-proto-fontcacheproto"
-DISTRO_PN_ALIAS_pn-fontsproto = "Meego=xorg-x11-proto-fontsproto"
 DISTRO_PN_ALIAS_pn-font-util = "Meego=xorg-x11-font-utils Fedora=xorg-x11-font-utils Ubuntu=xfonts-utils Mandriva=x11-font-util Debian=xfonts-utils"
 DISTRO_PN_ALIAS_pn-formfactor = "OE-Core"
-DISTRO_PN_ALIAS_pn-fstests = "OpenedHand"
 DISTRO_PN_ALIAS_pn-gcc-cross-initial = "OE-Core"
 DISTRO_PN_ALIAS_pn-gcc-cross-initial-i586 = "OE-Core"
 DISTRO_PN_ALIAS_pn-gcc-crosssdk-initial = "OE-Core"
@@ -114,7 +102,6 @@
 DISTRO_PN_ALIAS_pn-glibc-locale = "OpenSuSE=glibc-locale Fedora=glibc-devel"
 DISTRO_PN_ALIAS_pn-glibc-mtrace = "Fedora=glibc-utils Ubuntu=libc-dev-bin"
 DISTRO_PN_ALIAS_pn-glibc-scripts = "Fedora=glibc Ubuntu=libc-bin"
-DISTRO_PN_ALIAS_pn-glproto = "Meego=xorg-x11-proto-glproto"
 DISTRO_PN_ALIAS_pn-gnome-desktop-testing = "Debian=gnome-desktop-testing Fedora=gnome-desktop-testing"
 DISTRO_PN_ALIAS_pn-gnu-config = "OpenedHand"
 DISTRO_PN_ALIAS_pn-gptfdisk = "Fedora=gdisk Ubuntu=gdisk"
@@ -149,12 +136,9 @@
 DISTRO_PN_ALIAS_pn-initramfs-live-install-efi-testfs = "OE-Core"
 DISTRO_PN_ALIAS_pn-initramfs-live-install-testfs = "OE-Core"
 DISTRO_PN_ALIAS_pn-initscripts = "Fedora=initscripts Mandravia=initscripts"
-DISTRO_PN_ALIAS_pn-inputproto = "Meego=xorg-x11-proto-inputproto"
 DISTRO_PN_ALIAS_pn-iproute2 = "OSPDT"
 DISTRO_PN_ALIAS_pn-jpeg = "OpenSuSE=libjpeg Ubuntu=libjpeg62"
-DISTRO_PN_ALIAS_pn-kbproto = "Meego=xorg-x11-proto-kbproto Ubuntu=x11proto-kb-dev Debian=x11proto-kb-dev"
 DISTRO_PN_ALIAS_pn-kernel-devsrc = "Debian=linux-base Ubuntu=linux"
-DISTRO_PN_ALIAS_pn-kernelshark = "Mandriva=kernelshark Ubuntu=kernelshark"
 DISTRO_PN_ALIAS_pn-kern-tools-native = "Windriver"
 DISTRO_PN_ALIAS_pn-keymaps = "OE-Core"
 DISTRO_PN_ALIAS_pn-kf = "OSPDT"
@@ -205,7 +189,6 @@
 DISTRO_PN_ALIAS_pn-libtimedate-perl = "Debian=libtimedate-perl Ubuntu=libtimedate-perl"
 DISTRO_PN_ALIAS_pn-liburcu = "Fedora=userspace-rcu Ubuntu=liburcu0"
 DISTRO_PN_ALIAS_pn-libusb1 = "Debian=libusb-1.0-0 Fedora=libusb1"
-DISTRO_PN_ALIAS_pn-libusb-compat = "OSPDT"
 DISTRO_PN_ALIAS_pn-libx11 = "Debian=libx11-6 Fedora=libX11 Ubuntu=libx11-6 OpenSuSE=xorg-x11-libX11"
 DISTRO_PN_ALIAS_pn-libxcalibrate = "OSPDT upstream=http://cgit.freedesktop.org/xorg/lib/libXCalibrate/"
 DISTRO_PN_ALIAS_pn-libxfont2 = "Fedora=libXfont2 Clear=libXfont2"
@@ -257,7 +240,6 @@
 DISTRO_PN_ALIAS_pn-mkelfimage = "Ubuntu=mkelfimage Fedora=mkelfimage"
 DISTRO_PN_ALIAS_pn-mkfontdir = "Mandriva=mkfontdir Ubuntu=xfonts-utils Fedora=xorg-x11-font-utils"
 DISTRO_PN_ALIAS_pn-mkfontscale = "Mandriva=mkfontscale Ubuntu=xfonts-utils Fedora=xorg-x11-font-utils"
-DISTRO_PN_ALIAS_pn-mktemp = "Mandriva=mktemp Fedora=mktemp"
 DISTRO_PN_ALIAS_pn-mmc-utils = "OE-Core"
 DISTRO_PN_ALIAS_pn-modutils-initscripts = "OE-Core"
 DISTRO_PN_ALIAS_pn-mtd-utils = "Debian=mtd-utils Ubuntu=mtd-utils"
@@ -315,21 +297,18 @@
 DISTRO_PN_ALIAS_pn-portmap = "Debian=rpcbind Fedora=rpcbind"
 DISTRO_PN_ALIAS_pn-powertop = "Meego=powertop Fedora=powertop Debian=powertop OpenSuSE=powertop Mandriva=powertop"
 DISTRO_PN_ALIAS_pn-ppp-dialin = "OE-Core"
-DISTRO_PN_ALIAS_pn-presentproto = "Debian=x11proto-present-dev Fedora=xorg-x11-proto-devel"
 DISTRO_PN_ALIAS_pn-pseudo = "Windriver"
 DISTRO_PN_ALIAS_pn-psplash = "OpenedHand"
 DISTRO_PN_ALIAS_pn-ptest-runner = "OE-Core"
 DISTRO_PN_ALIAS_pn-pulseaudio-client-conf-sato = "OE-Core"
 DISTRO_PN_ALIAS_pn-puzzles = "Debian=sgt-puzzles Fedora=puzzles"
 DISTRO_PN_ALIAS_pn-python3 = "Fedora=python3 Debian=python3.2"
-DISTRO_PN_ALIAS_pn-python3-distribute = "Debian=python3-setuptools Fedora=python3-setuptools"
 DISTRO_PN_ALIAS_pn-python3-iniparse = "Fedora=python-iniparse Debian=python-iniparse"
 DISTRO_PN_ALIAS_pn-python3-pip = "OpenSuSE=python3-pip Debian=python3-pip"
 DISTRO_PN_ALIAS_pn-python3-pycurl = "Fedora=python-pycurl Debian=pycurl"
 DISTRO_PN_ALIAS_pn-python3-pygpgme = "Fedora=python-pygpgme Debian=pygpgme"
 DISTRO_PN_ALIAS_pn-python3-setuptools = "OpenSuSE=python3-setuptools Debian=python3-setuptools"
 DISTRO_PN_ALIAS_pn-python-dbus = "Ubuntu=python-dbus Debian=python-dbus Mandriva=python-dbus"
-DISTRO_PN_ALIAS_pn-python-distribute = "Opensuse=python-setuptools Fedora=python-setuptools"
 DISTRO_PN_ALIAS_pn-python-git = "Debian=python-git Fedora=GitPython"
 DISTRO_PN_ALIAS_pn-python-mako = "Fedora=python-mako Opensuse=python-Mako"
 DISTRO_PN_ALIAS_pn-python-pycairo = "Meego=pycairo Fedora=pycairo Ubuntu=pycairo Debian=pycairo"
@@ -341,12 +320,8 @@
 DISTRO_PN_ALIAS_pn-qemugl = "OpenedHand"
 DISTRO_PN_ALIAS_pn-qemu-helper = "OpenedHand"
 DISTRO_PN_ALIAS_pn-qemuwrapper-cross = "OE-Core"
-DISTRO_PN_ALIAS_pn-randrproto = "Meego=xorg-x11-proto-randrproto"
 DISTRO_PN_ALIAS_pn-readline = "Fedora=readline Debian=readline-common"
-DISTRO_PN_ALIAS_pn-recordproto = "Meego=xorg-x11-proto-recordproto"
 DISTRO_PN_ALIAS_pn-remake = "Mandriva=remake Debian=remake"
-DISTRO_PN_ALIAS_pn-renderproto = "Meego=xorg-x11-proto-renderproto"
-DISTRO_PN_ALIAS_pn-resourceproto = "Meego=xorg-x11-proto-resourceproto"
 DISTRO_PN_ALIAS_pn-rgb = "Fedora=xorg-X11-server-utils Debian=x11-xserver-utils"
 DISTRO_PN_ALIAS_pn-rpmresolve = "OSPDT"
 DISTRO_PN_ALIAS_pn-rt-tests = "Debian=rt-tests Ubuntu=rt-tests"
@@ -355,7 +330,6 @@
 DISTRO_PN_ALIAS_pn-sato-screenshot = "OpenedHand"
 DISTRO_PN_ALIAS_pn-sbc = "Fedora=sbc Debian=libsbc1"
 DISTRO_PN_ALIAS_pn-screenshot = "OpenedHand"
-DISTRO_PN_ALIAS_pn-scrnsaverproto = "Meego=xorg-x11-proto-scrnsaverproto Ubuntu=x11proto-scrnsaver-dev Debian=x11proto-scrnsaver-dev"
 DISTRO_PN_ALIAS_pn-settings-daemon = "OpenedHand"
 DISTRO_PN_ALIAS_pn-sgml-common = "OpenSuSE=sgml-common Fedora=sgml-common"
 DISTRO_PN_ALIAS_pn-sgmlspl = "Debian=sgmlspl Ubuntu=sgmlspl"
@@ -376,7 +350,6 @@
 DISTRO_PN_ALIAS_pn-tcf-agent = "Windriver upstream=http://www.eclipse.org/dsdp/tm/"
 DISTRO_PN_ALIAS_pn-texinfo-dummy-native = "OE-Core"
 DISTRO_PN_ALIAS_pn-tiny-init = "OSPDT"
-DISTRO_PN_ALIAS_pn-trace-cmd = "Mandriva=trace-cmd Ubuntu=trace-cmd"
 DISTRO_PN_ALIAS_pn-tremor = "OSPDT upstream=http://www.xiph.org/vorbis/"
 DISTRO_PN_ALIAS_pn-ttf-bitstream-vera = "Debian=ttf-bitstream-vera Ubuntu=ttf-bitstream-vera"
 DISTRO_PN_ALIAS_pn-tzcode = "OSPDT"
@@ -392,7 +365,6 @@
 DISTRO_PN_ALIAS_pn-usbinit = "OE-Core"
 DISTRO_PN_ALIAS_pn-util-macros = "Meego=xorg-x11-util-macros Fedora=xorg-x11-util-macros Mandriva=x11-util-macros"
 DISTRO_PN_ALIAS_pn-v86d = "Debian=v86d Ubuntu=v86d"
-DISTRO_PN_ALIAS_pn-videoproto = "Meego=xorg-x11-proto-videoproto"
 DISTRO_PN_ALIAS_pn-waffle = "OE-Core"
 DISTRO_PN_ALIAS_pn-watchdog = "Debian=watchdog Ubuntu=watchdog Mandriva=watchdog"
 DISTRO_PN_ALIAS_pn-webkitgtk = "Fedora=webkitgtk Ubuntu=libwebkit"
@@ -404,21 +376,15 @@
 DISTRO_PN_ALIAS_pn-xcb-util-image = "Debian=xcb-util Fedora=xcb-util"
 DISTRO_PN_ALIAS_pn-xcb-util-keysyms = "Debian=xcb-util Fedora=xcb-util"
 DISTRO_PN_ALIAS_pn-xcb-util-wm = "Debian=xcb-util Fedora=xcb-util"
-DISTRO_PN_ALIAS_pn-xcmiscproto = "Meego=xorg-x11-proto-xcmiscproto"
 DISTRO_PN_ALIAS_pn-xcursor-transparent-theme = "OpenedHand"
 DISTRO_PN_ALIAS_pn-xdpyinfo = "Fedora=xorg-x11-utils Ubuntu=x11-utils"
 DISTRO_PN_ALIAS_pn-xev = "Fedora=xorg-x11-utils Ubuntu=x11-utils"
-DISTRO_PN_ALIAS_pn-xextproto = "Meego=xorg-x11-proto-xextproto"
 DISTRO_PN_ALIAS_pn-xeyes = "Ubuntu=x11-apps Fedora=xorg-x11-apps"
-DISTRO_PN_ALIAS_pn-xf86bigfontproto = "Meego=xorg-x11-proto-xf86bigfontproto"
-DISTRO_PN_ALIAS_pn-xf86dgaproto = "Meego=xorg-x11-proto-xf86dgaproto"
-DISTRO_PN_ALIAS_pn-xf86driproto = "Meego=xorg-x11-proto-xf86driproto"
 DISTRO_PN_ALIAS_pn-xf86-input-evdev = "Ubuntu=xserver-xorg-input-evdev Mandriva=x11-driver-input-evdev Debian=xserver-xorg-input-evdev Fedora=xorg-x11-drv-evdev Meego=xorg-x11-drv-evdev"
 DISTRO_PN_ALIAS_pn-xf86-input-keyboard = "Meego=xorg-x11-drv-keyboard Fedora=xorg-x11-drv-keyboard Mandriva=x11-driver-input-keyboard Debian=xserver-xorg-input-keyboard"
 DISTRO_PN_ALIAS_pn-xf86-input-mouse = "Ubuntu=xserver-xorg-input-mouse Mandriva=x11-driver-input-mouse Debian=xserver-xorg-input-mouse"
 DISTRO_PN_ALIAS_pn-xf86-input-synaptics = "Meego=xorg-x11-drv-synaptics Fedora=xorg-x11-drv-synaptics Ubuntu=xserver-xorg-input-synaptics Mandriva=x11-driver-input-synaptics Debian=xfree86-driver-synaptics"
 DISTRO_PN_ALIAS_pn-xf86-input-vmmouse = "Fedora=xorg-x11-drv-vmmouse Ubuntu=xserver-xorg-input-vmmouse Mandriva=x11-driver-input-vmmouse Debian=xserver-xorg-input-vmmouse"
-DISTRO_PN_ALIAS_pn-xf86miscproto = "Meego=xorg-x11-proto-xf86miscproto"
 DISTRO_PN_ALIAS_pn-xf86-video-cirrus = "Opensuse=xf86-video-cirrus Debian=xserver-xorg-video-cirrus"
 DISTRO_PN_ALIAS_pn-xf86-video-fbdev = "Ubuntu=xserver-xorg-video-fbdev Debian=xserver-xorg-video-fbdev"
 DISTRO_PN_ALIAS_pn-xf86-video-intel = "Debian=xserver-xorg-video-intel Fedora=xorg-x11-drv-intel Mandriva=x11-driver-video-intel Meego=xorg-x11-drv-intel Ubuntu=xserver-xorg-video-intel"
@@ -427,15 +393,13 @@
 DISTRO_PN_ALIAS_pn-xf86-video-omapfb = "OSPDT"
 DISTRO_PN_ALIAS_pn-xf86-video-vesa = "Debian=xserver-xorg-video-vesa Fedora=xorg-x11-drv-vesa Mandriva=x11-driver-video-vesa Ubuntu=xserver-xorg-video-vesa"
 DISTRO_PN_ALIAS_pn-xf86-video-vmware = "Debian=xserver-xorg-video-vmware Fedora=xorg-x11-drv-vmware Mandriva=x11-driver-video-vmware Ubuntu=xserver-xorg-video-vmware"
-DISTRO_PN_ALIAS_pn-xf86vidmodeproto = "Meego=xorg-x11-proto-xf86vidmodeproto Ubuntu=x11proto-xf86vidmode Debian=x11proto-xf86vidmode"
 DISTRO_PN_ALIAS_pn-xhost = "Ubuntu=x11-xserver-utils Fedora=xorg-x11-server-utils"
-DISTRO_PN_ALIAS_pn-xineramaproto = "Meego=xorg-x11-proto-xineramaproto Ubuntu=x11proto-xinerama Debian=x11proto-xinerama"
 DISTRO_PN_ALIAS_pn-xinput-calibrator = "Fedora=xinput-calibrator Mandravia=xinput-calibrator Ubuntu=xinput-calibrator"
 DISTRO_PN_ALIAS_pn-xkbcomp = "Ubuntu=x11-xkb-utils Fedora=xorg-x11-xkb-utils"
 DISTRO_PN_ALIAS_pn-xmodmap = "Meego=xorg-x11-utils-xmodmap Fedora=xorg-x11-server-utils Ubuntu=x11-xserver-utils"
 DISTRO_PN_ALIAS_pn-xorg-minimal-fonts = "Ubuntu=xfonts-base Fedora=xorg-x11-fonts-base"
+DISTRO_PN_ALIAS_pn-xorgproto = "OSPDT upstream=http://cgit.freedesktop.org/xorg/proto/xorgproto"
 DISTRO_PN_ALIAS_pn-xprop = "Meego=xorg-x11-utils-xprop Fedora=xorg-x11-utils Ubuntu=x11-utils"
-DISTRO_PN_ALIAS_pn-xproto = "Meego=xorg-x11-proto-xproto Fedora=xorg-x11-proto-devel Ubuntu=x11proto-core-dev Debian=x11proto-core-dev Opensuse=xorg-x11-proto-devel Mandriva=x11-proto-devel"
 DISTRO_PN_ALIAS_pn-xproxymanagementprotocol = "Meego=xorg-x11-proto-xproxymanagementprotocol"
 DISTRO_PN_ALIAS_pn-xrandr = "Ubuntu=x11-xserver-utils Fedora=xorg-x11-server-utils"
 DISTRO_PN_ALIAS_pn-xrdb = "Ubuntu=x11-xserver-utils Fedora=xorg-x11-server-utils"
diff --git a/poky/meta/conf/distro/include/maintainers.inc b/poky/meta/conf/distro/include/maintainers.inc
index 48aff95..1278593 100644
--- a/poky/meta/conf/distro/include/maintainers.inc
+++ b/poky/meta/conf/distro/include/maintainers.inc
@@ -29,102 +29,94 @@
 #
 RECIPE_MAINTAINER_pn-acl = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-acpica = "Fathi Boudra <fathi.boudra@linaro.org>"
-RECIPE_MAINTAINER_pn-acpid = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-acpitests = "Fathi Boudra <fathi.boudra@linaro.org>"
-RECIPE_MAINTAINER_pn-adwaita-icon-theme = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-acpid = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-adwaita-icon-theme = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-alsa-lib = "Tanu Kaskinen <tanuk@iki.fi>"
 RECIPE_MAINTAINER_pn-alsa-plugins = "Tanu Kaskinen <tanuk@iki.fi>"
 RECIPE_MAINTAINER_pn-alsa-state = "Tanu Kaskinen <tanuk@iki.fi>"
 RECIPE_MAINTAINER_pn-alsa-tools = "Tanu Kaskinen <tanuk@iki.fi>"
 RECIPE_MAINTAINER_pn-alsa-utils = "Tanu Kaskinen <tanuk@iki.fi>"
 RECIPE_MAINTAINER_pn-alsa-utils-scripts = "Tanu Kaskinen <tanuk@iki.fi>"
-RECIPE_MAINTAINER_pn-apmd = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-apmd = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-apr = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-apr-util = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-apt = "Aníbal Limón <limon.anibal@gmail.com>"
 RECIPE_MAINTAINER_pn-apt-native = "Aníbal Limón <limon.anibal@gmail.com>"
 RECIPE_MAINTAINER_pn-argp-standalone = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-asciidoc = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-aspell = "Jose Lamego <jose.a.lamego@linux.intel.com>"
-RECIPE_MAINTAINER_pn-assimp = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-aspell = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-assimp = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-at = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-at-spi2-atk = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-at-spi2-core = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-atk = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-at-spi2-atk = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-at-spi2-core = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-atk = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-attr = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-autoconf = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-autoconf-archive = "Robert Yang <liezhi.yang@windriver.com>"
-RECIPE_MAINTAINER_pn-autogen-native = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-automake = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-avahi = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-avahi-ui = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-babeltrace = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-base-files = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
-RECIPE_MAINTAINER_pn-base-passwd = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
+RECIPE_MAINTAINER_pn-babeltrace = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-base-files = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-base-passwd = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-bash = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-bash-completion = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-bc = "Jose Lamego <jose.a.lamego@linux.intel.com>"
-RECIPE_MAINTAINER_pn-bdwgc = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-beecrypt = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-bigreqsproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-bind = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-bash-completion = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-bc = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-bind = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-binutils = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-binutils-cross = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-binutils-cross-canadian = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-binutils-crosssdk = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-bison = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-bjam-native = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-bjam-native = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-blktool = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-blktrace = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-bluez5 = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-bmap-tools = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
-RECIPE_MAINTAINER_pn-boost = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-bootchart2 = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-blktrace = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-bluez5 = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-bmap-tools = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-boost = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-bootchart2 = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-bsd-headers = "Khem Raj <raj.khem@gmail.com>"
-RECIPE_MAINTAINER_pn-btrfs-tools = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-build-appliance-image = "Cristian Iorga <cristian.iorga@intel.com>"
-RECIPE_MAINTAINER_pn-build-compare = "Randy Witt <randy.e.witt@linux.intel.com>"
+RECIPE_MAINTAINER_pn-btrfs-tools = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-build-appliance-image = "Richard Purdie <richard.purdie@linuxfoundation.org>"
+RECIPE_MAINTAINER_pn-build-compare = "Paul Eggleton <paul.eggleton@linux.intel.com>"
 RECIPE_MAINTAINER_pn-build-sysroots = "Richard Purdie <richard.purdie@linuxfoundation.org>"
-RECIPE_MAINTAINER_pn-builder = "Cristian Iorga <cristian.iorga@intel.com>"
-RECIPE_MAINTAINER_pn-buildtools-tarball = "Cristian Iorga <cristian.iorga@intel.com>"
-RECIPE_MAINTAINER_pn-busybox = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-builder = "Richard Purdie <richard.purdie@linuxfoundation.org>"
+RECIPE_MAINTAINER_pn-buildtools-tarball = "Richard Purdie <richard.purdie@linuxfoundation.org>"
+RECIPE_MAINTAINER_pn-busybox = "Andrej Valek <andrej.valek@siemens.com>"
 RECIPE_MAINTAINER_pn-busybox-inittab = "Denys Dmytriyenko <denys@ti.com>"
 RECIPE_MAINTAINER_pn-bzip2 = "Denys Dmytriyenko <denys@ti.com>"
-RECIPE_MAINTAINER_pn-ca-certificates = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-cairo = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-calibrateproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-cantarell-fonts = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-ca-certificates = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-cairo = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-cantarell-fonts = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-ccache = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-cdrtools-native = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-chkconfig = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-chkconfig-alternatives-native = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-chrpath = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-clutter-1.0 = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-clutter-gst-3.0 = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-clutter-gtk-1.0 = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-cmake = "Otavio Salvador <otavio.salvador@ossystems.com.br>"
-RECIPE_MAINTAINER_pn-cmake-native = "Otavio Salvador <otavio.salvador@ossystems.com.br>"
-RECIPE_MAINTAINER_pn-cogl-1.0 = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-compositeproto = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-clutter-1.0 = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-clutter-gst-3.0 = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-clutter-gtk-1.0 = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-cmake = "Pascal Bach <pascal.bach@siemens.com>"
+RECIPE_MAINTAINER_pn-cmake-native = "Pascal Bach <pascal.bach@siemens.com>"
+RECIPE_MAINTAINER_pn-cogl-1.0 = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-connman = "Changhyeok Bae <changhyeok.bae@lge.com>"
-RECIPE_MAINTAINER_pn-connman-conf = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-connman-gnome = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-connman-conf = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-connman-gnome = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-console-tools = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-consolekit = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-coreutils = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-cpio = "Denys Dmytriyenko <denys@ti.com>"
-RECIPE_MAINTAINER_pn-cracklib = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-createrepo-c = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-cronie = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-cracklib = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-createrepo-c = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-cronie = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-cross-localedef-native = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-cryptodev-linux = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-cryptodev-module = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-cryptodev-tests = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-cups = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-curl = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-curl = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-cve-check-tool = "Ross Burton <ross.burton@intel.com>"
-RECIPE_MAINTAINER_pn-cwautomacros = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-damageproto = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-cwautomacros = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-db = "Mark Hatle <mark.hatle@windriver.com>"
 RECIPE_MAINTAINER_pn-dbus = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-dbus-glib = "Chen Qi <Qi.Chen@windriver.com>"
@@ -132,55 +124,46 @@
 RECIPE_MAINTAINER_pn-dbus-wait = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-debianutils = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-depmodwrapper-cross = "Mark Hatle <mark.hatle@windriver.com>"
-RECIPE_MAINTAINER_pn-desktop-file-utils-native = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-desktop-file-utils = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-dhcp = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-diffstat = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-diffutils = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-directfb = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-directfb-examples = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-distcc = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-distcc-config = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-dmidecode = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-dmxproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-dnf = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-dmidecode = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-dnf = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-docbook-xml-dtd4 = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-docbook-xsl-stylesheets = "Yi Zhao <yi.zhao@windriver.com>"
+RECIPE_MAINTAINER_pn-dos2unix = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-dosfstools = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-dpkg = "Aníbal Limón <limon.anibal@gmail.com>"
-RECIPE_MAINTAINER_pn-dri2proto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-dri3proto = "Armin Kuster <akuster@mvista.com>"
 RECIPE_MAINTAINER_pn-dropbear = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-dtc = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-dwarfsrcfiles = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-dtc = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-dwarfsrcfiles = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-e2fsprogs = "Robert Yang <liezhi.yang@windriver.com>"
-RECIPE_MAINTAINER_pn-ed = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-eee-acpi-scripts = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-efilinux = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-eglinfo-fb = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-eglinfo-x11 = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-efilinux = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-ed = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-eglinfo-fb = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-eglinfo-x11 = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-elfutils = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-enchant = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-encodings = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-epiphany = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-enchant = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-encodings = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-epiphany = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-ethtool = "Changhyeok Bae <changhyeok.bae@lge.com>"
-RECIPE_MAINTAINER_pn-eudev = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
+RECIPE_MAINTAINER_pn-eudev = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-expat = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-expect = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-ffmpeg = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-expect = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-ffmpeg = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-file = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-findutils = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-fixesproto = "Armin Kuster <akuster@mvista.com>"
 RECIPE_MAINTAINER_pn-flac = "Tanu Kaskinen <tanuk@iki.fi>"
 RECIPE_MAINTAINER_pn-flex = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-font-alias = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-font-util = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-fontconfig = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-fontsproto = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-font-alias = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-font-util = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-fontconfig = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-foomatic-filters = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-formfactor = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-freetype = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-fstests = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-formfactor = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-freetype = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-fribidi = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-fts = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-gawk = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-gcc = "Khem Raj <raj.khem@gmail.com>"
@@ -193,52 +176,48 @@
 RECIPE_MAINTAINER_pn-gcc-sanitizers = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-gcc-source = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-gccmakedep = "Khem Raj <raj.khem@gmail.com>"
-RECIPE_MAINTAINER_pn-gconf = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-gcr = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-gconf = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-gcr = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-gdb = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-gdb-cross = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-gdb-cross-canadian = "Khem Raj <raj.khem@gmail.com>"
-RECIPE_MAINTAINER_pn-gdbm = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-gdk-pixbuf = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-gdbm = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-gdk-pixbuf = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-gettext = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-gettext-minimal-native = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-ghostscript = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-git = "Robert Yang <liezhi.yang@windriver.com>"
-RECIPE_MAINTAINER_pn-glew = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-glib-2.0 = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-glib-networking = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-glew = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-glib-2.0 = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-glib-networking = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-glibc = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-glibc-initial = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-glibc-locale = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-glibc-mtrace = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-glibc-scripts = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-glide = "Otavio Salvador <otavio.salvador@ossystems.com.br>"
-RECIPE_MAINTAINER_pn-glproto = "Armin Kuster <akuster@mvista.com>"
 RECIPE_MAINTAINER_pn-gmp = "Khem Raj <raj.khem@gmail.com>"
-RECIPE_MAINTAINER_pn-gnome-common = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-gnome-desktop-testing = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-gnome-desktop3 = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-gnome-doc-utils = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-gnome-themes-standard = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-gnome-desktop-testing = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-gnome-themes-standard = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-gnu-config = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-gnu-efi = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-gnupg = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-gnutls = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-gnutls = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-go = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-go-cross = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-go-dep = "Otavio Salvador <otavio.salvador@ossystems.com.br>"
 RECIPE_MAINTAINER_pn-go-helloworld = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-go-native = "Khem Raj <raj.khem@gmail.com>"
-RECIPE_MAINTAINER_pn-gobject-introspection = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-gperf = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-gobject-introspection = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-gperf = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-gpgme = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-gptfdisk = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-gptfdisk = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-grep = "Denys Dmytriyenko <denys@ti.com>"
 RECIPE_MAINTAINER_pn-groff = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-grub = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-grub-bootconf = "California Sullivan <california.l.sullivan@intel.com>"
-RECIPE_MAINTAINER_pn-grub-efi = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-gsettings-desktop-schemas = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-grub = "Anuj Mittal <anuj.mittal@intel.com>"
+RECIPE_MAINTAINER_pn-grub-bootconf = "Anuj Mittal <anuj.mittal@intel.com>"
+RECIPE_MAINTAINER_pn-grub-efi = "Anuj Mittal <anuj.mittal@intel.com>"
+RECIPE_MAINTAINER_pn-gsettings-desktop-schemas = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-gst-examples = "Anuj Mittal <anuj.mittal@intel.com>"
 RECIPE_MAINTAINER_pn-gst-validate = "Anuj Mittal <anuj.mittal@intel.com>"
 RECIPE_MAINTAINER_pn-gstreamer1.0 = "Anuj Mittal <anuj.mittal@intel.com>"
@@ -252,177 +231,162 @@
 RECIPE_MAINTAINER_pn-gstreamer1.0-python = "Anuj Mittal <anuj.mittal@intel.com>"
 RECIPE_MAINTAINER_pn-gstreamer1.0-rtsp-server = "Anuj Mittal <anuj.mittal@intel.com>"
 RECIPE_MAINTAINER_pn-gstreamer1.0-vaapi = "Anuj Mittal <anuj.mittal@intel.com>"
-RECIPE_MAINTAINER_pn-gtk+ = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-gtk+3 = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-gtk-doc = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-gtk-engines = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-gtk-icon-utils-native = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-gtk-sato-engine = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-guilt-native = "Bruce Ashfield <bruce.ashfield@windriver.com>"
-RECIPE_MAINTAINER_pn-gummiboot = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-gtk+ = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-gtk+3 = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-gtk-doc = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-gtk-icon-utils-native = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-gzip = "Denys Dmytriyenko <denys@ti.com>"
-RECIPE_MAINTAINER_pn-harfbuzz = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-harfbuzz = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-hdparm = "Denys Dmytriyenko <denys@ti.com>"
 RECIPE_MAINTAINER_pn-help2man-native = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-hicolor-icon-theme = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-hwlatdetect = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-i2c-tools = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-hicolor-icon-theme = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-hwlatdetect = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-i2c-tools = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-icecc-create-env = "Joshua Watt <JPEWhacker@gmail.com>"
-RECIPE_MAINTAINER_pn-icon-naming-utils = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-icu = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-ifupdown = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-init-ifupdown = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-icu = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-ifupdown = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-init-ifupdown = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-initramfs-boot = "Otavio Salvador <otavio.salvador@ossystems.com.br>"
 RECIPE_MAINTAINER_pn-initramfs-framework = "Otavio Salvador <otavio.salvador@ossystems.com.br>"
-RECIPE_MAINTAINER_pn-initramfs-live-boot = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
-RECIPE_MAINTAINER_pn-initramfs-live-boot-tiny = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
-RECIPE_MAINTAINER_pn-initramfs-live-install = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
-RECIPE_MAINTAINER_pn-initramfs-live-install-efi = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
-RECIPE_MAINTAINER_pn-initramfs-live-install-efi-testfs = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
-RECIPE_MAINTAINER_pn-initramfs-live-install-testfs = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
-RECIPE_MAINTAINER_pn-initscripts = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
-RECIPE_MAINTAINER_pn-inputproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-intltool = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-initramfs-live-boot = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-initramfs-live-boot-tiny = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-initramfs-live-install = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-initramfs-live-install-efi = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-initramfs-live-install-efi-testfs = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-initramfs-live-install-testfs = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-initscripts = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-intltool = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-iproute2 = "Changhyeok Bae <changhyeok.bae@lge.com>"
 RECIPE_MAINTAINER_pn-iptables = "Changhyeok Bae <changhyeok.bae@lge.com>"
 RECIPE_MAINTAINER_pn-iputils = "Changhyeok Bae <changhyeok.bae@lge.com>"
 RECIPE_MAINTAINER_pn-irda-utils = "Changhyeok Bae <changhyeok.bae@lge.com>"
-RECIPE_MAINTAINER_pn-iso-codes = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-iso-codes = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-iw = "Changhyeok Bae <changhyeok.bae@lge.com>"
-RECIPE_MAINTAINER_pn-libjpeg-turbo = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-libjpeg-turbo = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-json-c = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-json-glib = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-kbd = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-kbproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-kconfig-frontends = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-kbd = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-kern-tools-native = "Bruce Ashfield <bruce.ashfield@windriver.com>"
-RECIPE_MAINTAINER_pn-kernelshark = "Alexander Kanavin <alexander.kanavin@intel.com>"
 RECIPE_MAINTAINER_pn-kernel-devsrc = "Bruce Ashfield <bruce.ashfield@windriver.com>"
-RECIPE_MAINTAINER_pn-kexec-tools = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-keymaps = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-kexec-tools = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-keymaps = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-kmod = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-kmod-native = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-kmscube = "Carlos Rafael Giani <dv@pseudoterminal.org>"
-RECIPE_MAINTAINER_pn-l3afpad = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-l3afpad = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-lame = "Tanu Kaskinen <tanuk@iki.fi>"
 RECIPE_MAINTAINER_pn-ldconfig-native = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-less = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-liba52 = "Tanu Kaskinen <tanuk@iki.fi>"
-RECIPE_MAINTAINER_pn-libacpi = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libaio = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-libacpi = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libaio = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-libarchive = "Otavio Salvador <otavio.salvador@ossystems.com.br>"
-RECIPE_MAINTAINER_pn-libart-lgpl = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libassuan = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libatomic-ops = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-libart-lgpl = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libassuan = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libatomic-ops = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-libbsd = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-libcap = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-libcap-ng = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-libcgroup = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-libcgroup = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-libcheck = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-libcomps = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libconvert-asn1-perl = "Tim Orling <timothy.t.orling@intel.com>"
-RECIPE_MAINTAINER_pn-libcroco = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libdaemon = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libdmx = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libdnf = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-libcomps = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-libconvert-asn1-perl = "Tim Orling <timothy.t.orling@linux.intel.com>"
+RECIPE_MAINTAINER_pn-libcroco = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libdaemon = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-libdmx = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libdnf = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-libdrm = "Otavio Salvador <otavio.salvador@ossystems.com.br>"
-RECIPE_MAINTAINER_pn-libepoxy = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-liberation-fonts = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-libepoxy = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-liberation-fonts = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-liberror-perl = "Tim Orling <timothy.t.orling@linux.intel.com>"
-RECIPE_MAINTAINER_pn-libevdev = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libevent = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libexif = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libfakekey = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libffi = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libfm = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libfm-extra = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libfontenc = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-libevdev = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libevent = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libexif = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-libfakekey = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-libffi = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-libfm = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-libfm-extra = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-libfontenc = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-libgcc = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-libgcc-initial = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-libgcrypt = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-libgfortran = "Khem Raj <raj.khem@gmail.com>"
-RECIPE_MAINTAINER_pn-libglu = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-libgloss = "Alejandro Hernandez <aehs29@gmail.com>"
+RECIPE_MAINTAINER_pn-libglu = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-libgpg-error = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-libgudev = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libical = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libice = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libiconv = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-libgudev = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libical = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libice = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-libid3tag = "Tanu Kaskinen <tanuk@iki.fi>"
-RECIPE_MAINTAINER_pn-libidn = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libinput = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libjson = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libksba = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libmatchbox = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-libidn = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-libidn2 = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libinput = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libksba = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-libmatchbox = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-libmnl = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-libmpc = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-libnewt = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-libnewt-python = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-libnfsidmap = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libnl = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libnotify = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-libnl = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-libnotify = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-libnsl2 = "Khem Raj <raj.khem@gmail.com>"
-RECIPE_MAINTAINER_pn-libnss-mdns = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libogg = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libomxil = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libowl = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libpam = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libpcap = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libpciaccess = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-libnss-mdns = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-libnss-nis = "Khem Raj <raj.khem@gmail.com>"
+RECIPE_MAINTAINER_pn-libogg = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libomxil = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libpam = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libpcap = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libpciaccess = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-libpcre = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-libpcre2 = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libpfm4 = "Matthew McClintock <msm@freescale.com>"
-RECIPE_MAINTAINER_pn-libpipeline = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libpng = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libpng12 = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libproxy = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libpthread-stubs = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-librepo = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-librsvg = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-libpcre2 = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libpipeline = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-libpng = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libproxy = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libpthread-stubs = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-librepo = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-librsvg = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-libsamplerate0 = "Tanu Kaskinen <tanuk@iki.fi>"
 RECIPE_MAINTAINER_pn-libsdl = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-libsdl2 = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-libsecret = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libsm = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-libsecret = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-libsm = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-libsndfile1 = "Tanu Kaskinen <tanuk@iki.fi>"
-RECIPE_MAINTAINER_pn-libsolv = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libsoup-2.4 = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libtasn1 = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-libsolv = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libsoup-2.4 = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-libtasn1 = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-libtest-needs-perl = "Tim Orling <timothy.t.orling@linux.intel.com>"
-RECIPE_MAINTAINER_pn-libtheora = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-libtheora = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-libtimedate-perl = "Tim Orling <timothy.t.orling@linux.intel.com>"
-RECIPE_MAINTAINER_pn-libtirpc = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-libtirpc = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-libtool = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-libtool-cross = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-libtool-native = "Robert Yang <liezhi.yang@windriver.com>"
-RECIPE_MAINTAINER_pn-libunistring = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-libunistring = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-libunwind = "Bruce Ashfield <bruce.ashfield@windriver.com>"
-RECIPE_MAINTAINER_pn-liburcu = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-liburcu = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-liburi-perl = "Tim Orling <timothy.t.orling@linux.intel.com>"
-RECIPE_MAINTAINER_pn-libusb-compat = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libusb1 = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libuser = "Robert Yang <liezhi.yang@windriver.com>"
+RECIPE_MAINTAINER_pn-libusb1 = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-libva = "Anuj Mittal <anuj.mittal@intel.com>"
 RECIPE_MAINTAINER_pn-libva-utils = "Anuj Mittal <anuj.mittal@intel.com>"
 RECIPE_MAINTAINER_pn-libvorbis = "Tanu Kaskinen <tanuk@iki.fi>"
-RECIPE_MAINTAINER_pn-libwebp = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libx11 = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libx11-diet = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxau = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxcalibrate = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxcb = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxcomposite = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxcursor = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxdamage = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxdmcp = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxext = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxfixes = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxfont = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxfont2 = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxft = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxi = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxinerama = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxkbcommon = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxkbfile = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-libwebp = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-libx11 = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libx11-diet = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxau = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxcb = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxcomposite = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxcursor = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxdamage = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxdmcp = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxext = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxfixes = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxfont = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxfont2 = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxft = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxi = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxinerama = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxkbcommon = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxkbfile = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-libxml-namespacesupport-perl = "Tim Orling <timothy.t.orling@linux.intel.com>"
 RECIPE_MAINTAINER_pn-libxml-parser-perl = "Tim Orling <timothy.t.orling@linux.intel.com>"
 RECIPE_MAINTAINER_pn-libxml-perl = "Tim Orling <timothy.t.orling@linux.intel.com>"
@@ -430,25 +394,24 @@
 RECIPE_MAINTAINER_pn-libxml-sax-perl = "Tim Orling <timothy.t.orling@linux.intel.com>"
 RECIPE_MAINTAINER_pn-libxml-simple-perl = "Tim Orling <timothy.t.orling@linux.intel.com>"
 RECIPE_MAINTAINER_pn-libxml2 = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-libxmu = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxpm = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxrandr = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxrender = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxres = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxscrnsaver = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxsettings-client = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-libxshmfence = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxslt = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-libxt = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxtst = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxv = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxvmc = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxxf86dga = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxxf86misc = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libxxf86vm = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-libyaml = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-lighttpd = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-linux-dummy = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-libxmu = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxpm = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxrandr = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxrender = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxres = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxscrnsaver = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxshmfence = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxslt = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-libxt = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxtst = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxv = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxvmc = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxxf86dga = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxxf86misc = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libxxf86vm = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-libyaml = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-lighttpd = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-linux-dummy = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-linux-firmware = "Otavio Salvador <otavio.salvador@ossystems.com.br>"
 RECIPE_MAINTAINER_pn-linux-libc-headers = "Bruce Ashfield <bruce.ashfield@windriver.com>"
 RECIPE_MAINTAINER_pn-linux-yocto = "Bruce Ashfield <bruce.ashfield@windriver.com>"
@@ -457,11 +420,11 @@
 RECIPE_MAINTAINER_pn-linux-yocto-tiny = "Bruce Ashfield <bruce.ashfield@windriver.com>"
 RECIPE_MAINTAINER_pn-llvm = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-logrotate = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-lrzsz = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-lrzsz = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-lsb = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-lsbinitscripts = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
+RECIPE_MAINTAINER_pn-lsbinitscripts = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-lsbtest = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-lsof = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-lsof = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-ltp = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-lttng-modules = "Richard Purdie <richard.purdie@linuxfoundation.org>"
 RECIPE_MAINTAINER_pn-lttng-tools = "Richard Purdie <richard.purdie@linuxfoundation.org>"
@@ -478,120 +441,111 @@
 RECIPE_MAINTAINER_pn-make-mod-scripts = "Bruce Ashfield <bruce.ashfield@windriver.com>"
 RECIPE_MAINTAINER_pn-man-db = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-man-pages = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-matchbox-config-gtk = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-matchbox-desktop = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-matchbox-desktop-sato = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-matchbox-keyboard = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-matchbox-panel-2 = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-matchbox-session = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-matchbox-session-sato = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-matchbox-terminal = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-matchbox-theme-sato = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-matchbox-wm = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-mc = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-mdadm = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-menu-cache = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-matchbox-config-gtk = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-matchbox-desktop = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-matchbox-keyboard = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-matchbox-panel-2 = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-matchbox-session = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-matchbox-session-sato = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-matchbox-terminal = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-matchbox-theme-sato = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-matchbox-wm = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-mc = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-mdadm = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-menu-cache = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-mesa = "Otavio Salvador <otavio.salvador@ossystems.com.br>"
 RECIPE_MAINTAINER_pn-mesa-demos = "Otavio Salvador <otavio.salvador@ossystems.com.br>"
 RECIPE_MAINTAINER_pn-mesa-gl = "Otavio Salvador <otavio.salvador@ossystems.com.br>"
-RECIPE_MAINTAINER_pn-meson = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-meson = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-meta-environment = "Richard Purdie <richard.purdie@linuxfoundation.org>"
 RECIPE_MAINTAINER_pn-meta-environment-extsdk = "Richard Purdie <richard.purdie@linuxfoundation.org>"
 RECIPE_MAINTAINER_pn-meta-extsdk-toolchain = "Richard Purdie <richard.purdie@linuxfoundation.org>"
-RECIPE_MAINTAINER_pn-meta-ide-support = "Cristian Iorga <cristian.iorga@intel.com>"
-RECIPE_MAINTAINER_pn-meta-toolchain = "Cristian Iorga <cristian.iorga@intel.com>"
+RECIPE_MAINTAINER_pn-meta-ide-support = "Richard Purdie <richard.purdie@linuxfoundation.org>"
+RECIPE_MAINTAINER_pn-meta-toolchain = "Richard Purdie <richard.purdie@linuxfoundation.org>"
 RECIPE_MAINTAINER_pn-meta-world-pkgdata = "Richard Purdie <richard.purdie@linuxfoundation.org>"
 RECIPE_MAINTAINER_pn-mingetty = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-mini-x-session = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-minicom = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-mkelfimage = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-mkfontdir = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-mkfontscale = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-mini-x-session = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-minicom = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-mkfontdir = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-mkfontscale = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-mklibs-native = "Robert Yang <liezhi.yang@windriver.com>"
-RECIPE_MAINTAINER_pn-mktemp = "Robert Yang <liezhi.yang@windriver.com>"
-RECIPE_MAINTAINER_pn-mmc-utils = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-mobile-broadband-provider-info = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-mmc-utils = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-mobile-broadband-provider-info = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-modutils-initscripts = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-mpeg2dec = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-mpeg2dec = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-mpfr = "Khem Raj <raj.khem@gmail.com>"
-RECIPE_MAINTAINER_pn-mpg123 = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-msmtp = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-mpg123 = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-msmtp = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-mtd-utils = "Denys Dmytriyenko <denys@ti.com>"
-RECIPE_MAINTAINER_pn-mtdev = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-mtools = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-mtdev = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-mtools = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-musl = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-musl-utils = "Khem Raj <raj.khem@gmail.com>"
-RECIPE_MAINTAINER_pn-mx-1.0 = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-mx-1.0 = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-nasm = "Richard Purdie <richard.purdie@linuxfoundation.org>"
 RECIPE_MAINTAINER_pn-nativesdk-buildtools-perl-dummy = "Richard Purdie <richard.purdie@linuxfoundation.org>"
 RECIPE_MAINTAINER_pn-nativesdk-libtool = "Richard Purdie <richard.purdie@linuxfoundation.org>"
 RECIPE_MAINTAINER_pn-nativesdk-packagegroup-sdk-host = "Ross Burton <ross.burton@intel.com>"
-RECIPE_MAINTAINER_pn-nativesdk-qemu-helper = "Juro Bystricky <juro.bystricky@intel.com>"
+RECIPE_MAINTAINER_pn-nativesdk-qemu-helper = "Richard Purdie <richard.purdie@linuxfoundation.org>"
+RECIPE_MAINTAINER_pn-newlib = "Alejandro Hernandez <aehs29@gmail.com>"
 RECIPE_MAINTAINER_pn-ncurses = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-neard = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-neon = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-net-tools = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-netbase = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-neard = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-net-tools = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-netbase = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-nettle = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-nfs-export-root = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-nfs-utils = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-ninja = "Khem Raj <raj.khem@gmail.com>"
-RECIPE_MAINTAINER_pn-npth = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-nspr = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-nss = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-nss-myhostname = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-ofono = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-oh-puzzles = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-openssh = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-openssl = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-npth = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-nspr = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-nss = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-nss-myhostname = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-ofono = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-openssh = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-openssl = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-openssl10 = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-opkg = "Alejandro del Castillo <alejandro.delcastillo@ni.com>"
 RECIPE_MAINTAINER_pn-opkg-arch-config = "Alejandro del Castillo <alejandro.delcastillo@ni.com>"
 RECIPE_MAINTAINER_pn-opkg-keyrings = "Alejandro del Castillo <alejandro.delcastillo@ni.com>"
 RECIPE_MAINTAINER_pn-opkg-utils = "Alejandro del Castillo <alejandro.delcastillo@ni.com>"
-RECIPE_MAINTAINER_pn-oprofile = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-orc = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-orc = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-os-release = "Ross Burton <ross.burton@intel.com>"
-RECIPE_MAINTAINER_pn-ossp-uuid = "Alexander Kanavin <alexander.kanavin@intel.com>"
 RECIPE_MAINTAINER_pn-ovmf = "Ricardo Neri <ricardo.neri-calderon@linux.intel.com>"
 RECIPE_MAINTAINER_pn-ovmf-shell-image = "Ricardo Neri <ricardo.neri-calderon@linux.intel.com>"
-RECIPE_MAINTAINER_pn-p11-kit = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-p11-kit = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-package-index = "Ross Burton <ross.burton@intel.com>"
-RECIPE_MAINTAINER_pn-pango = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-pango = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-parted = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-patch = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-patchelf = "Richard Purdie <richard.purdie@linuxfoundation.org>"
-RECIPE_MAINTAINER_pn-pax-utils = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-pbzip2 = "Denys Dmytriyenko <denys@ti.com>"
 RECIPE_MAINTAINER_pn-pciutils = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-pcmanfm = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-pcmciautils = "Robert Yang <liezhi.yang@windriver.com>"
+RECIPE_MAINTAINER_pn-pcmanfm = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-perf = "Bruce Ashfield <bruce.ashfield@windriver.com>"
-RECIPE_MAINTAINER_pn-perl = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-perl-native = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-piglit = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-perl = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-perl-native = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-piglit = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-pigz = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-pinentry = "Armin Kuster <akuster808@gmail.com>"
-RECIPE_MAINTAINER_pn-pixman = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-pixz = "Denys Dmytriyenko <denys@ti.com>"
-RECIPE_MAINTAINER_pn-pkgconf = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-pkgconfig = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-pm-utils = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-pointercal-xinput = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-pong-clock = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-pixman = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-pkgconf = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-pkgconfig = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-pm-utils = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-pointercal-xinput = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-pong-clock = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-popt = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-powertop = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-powertop = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-ppp = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-ppp-dialin = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-prelink = "Mark Hatle <mark.hatle@windriver.com>"
-RECIPE_MAINTAINER_pn-presentproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-procps = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-procps = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-pseudo = "Mark Hatle <mark.hatle@windriver.com>"
-RECIPE_MAINTAINER_pn-psmisc = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-psmisc = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-psplash = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-ptest-runner = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-ptest-runner = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-pulseaudio = "Tanu Kaskinen <tanuk@iki.fi>"
 RECIPE_MAINTAINER_pn-pulseaudio-client-conf-sato = "Tanu Kaskinen <tanuk@iki.fi>"
-RECIPE_MAINTAINER_pn-puzzles = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-puzzles = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-python = "Derek Straka <derek@asterius.io>"
 RECIPE_MAINTAINER_pn-python-native = "Derek Straka <derek@asterius.io>"
 RECIPE_MAINTAINER_pn-python-nose = "Derek Straka <derek@asterius.io>"
@@ -603,6 +557,8 @@
 RECIPE_MAINTAINER_pn-python3-async = "Derek Straka <derek@asterius.io>"
 RECIPE_MAINTAINER_pn-python3-dbus = "Derek Straka <derek@asterius.io>"
 RECIPE_MAINTAINER_pn-python3-docutils = "Derek Straka <derek@asterius.io>"
+RECIPE_MAINTAINER_pn-python3-extras = "Derek Straka <derek@asterius.io>"
+RECIPE_MAINTAINER_pn-python3-file-utils = "Derek Straka <derek@asterius.io>"
 RECIPE_MAINTAINER_pn-python3-git = "Derek Straka <derek@asterius.io>"
 RECIPE_MAINTAINER_pn-python3-gitdb = "Derek Straka <derek@asterius.io>"
 RECIPE_MAINTAINER_pn-python3-iniparse = "Derek Straka <derek@asterius.io>"
@@ -610,190 +566,172 @@
 RECIPE_MAINTAINER_pn-python3-native = "Derek Straka <derek@asterius.io>"
 RECIPE_MAINTAINER_pn-python3-nose = "Derek Straka <derek@asterius.io>"
 RECIPE_MAINTAINER_pn-python3-numpy = "Derek Straka <derek@asterius.io>"
+RECIPE_MAINTAINER_pn-python3-pbr = "Derek Straka <derek@asterius.io>"
 RECIPE_MAINTAINER_pn-python3-pip = "Derek Straka <derek@asterius.io>"
 RECIPE_MAINTAINER_pn-python3-pycairo = "Derek Straka <derek@asterius.io>"
 RECIPE_MAINTAINER_pn-python3-pygobject = "Derek Straka <derek@asterius.io>"
 RECIPE_MAINTAINER_pn-python3-setuptools = "Derek Straka <derek@asterius.io>"
 RECIPE_MAINTAINER_pn-python3-six = "Derek Straka <derek@asterius.io>"
 RECIPE_MAINTAINER_pn-python3-smmap = "Derek Straka <derek@asterius.io>"
-RECIPE_MAINTAINER_pn-qemu = "Juro Bystricky <juro.bystricky@intel.com>"
-RECIPE_MAINTAINER_pn-qemu-helper-native = "Juro Bystricky <juro.bystricky@intel.com>"
-RECIPE_MAINTAINER_pn-qemuwrapper-cross = "Juro Bystricky <juro.bystricky@intel.com>"
+RECIPE_MAINTAINER_pn-python3-subunit = "Derek Straka <derek@asterius.io>"
+RECIPE_MAINTAINER_pn-python3-testtools = "Derek Straka <derek@asterius.io>"
+RECIPE_MAINTAINER_pn-qemu = "Richard Purdie <richard.purdie@linuxfoundation.org>"
+RECIPE_MAINTAINER_pn-qemu-helper-native = "Richard Purdie <richard.purdie@linuxfoundation.org>"
+RECIPE_MAINTAINER_pn-qemuwrapper-cross = "Richard Purdie <richard.purdie@linuxfoundation.org>"
 RECIPE_MAINTAINER_pn-quilt = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-quilt-native = "Robert Yang <liezhi.yang@windriver.com>"
-RECIPE_MAINTAINER_pn-quota = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-randrproto = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-quota = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-re2c = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-readline = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-recordproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-remake = "Robert Yang <liezhi.yang@windriver.com>"
-RECIPE_MAINTAINER_pn-renderproto = "Armin Kuster <akuster@mvista.com>"
 RECIPE_MAINTAINER_pn-resolvconf = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-resourceproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-rgb = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-rgb = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-rpcbind = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-rng-tools = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-rng-tools = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-rpcsvc-proto = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-rpm = "Mark Hatle <mark.hatle@windriver.com>"
-RECIPE_MAINTAINER_pn-rpmresolve = "Mark Hatle <mark.hatle@windriver.com>"
 RECIPE_MAINTAINER_pn-rsync = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-rt-tests = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-ruby = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-run-postinsts = "Cristian Iorga <cristian.iorga@intel.com>"
-RECIPE_MAINTAINER_pn-rxvt-unicode = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-sato-screenshot = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-rt-tests = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-ruby = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-run-postinsts = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-rxvt-unicode = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-sato-screenshot = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-sbc = "Tanu Kaskinen <tanuk@iki.fi>"
-RECIPE_MAINTAINER_pn-screen = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-scrnsaverproto = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-screen = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-sed = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-serf = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-serf = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-setserial = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-settings-daemon = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-settings-daemon = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-shadow = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-shadow-securetty = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-shadow-sysroot = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-shared-mime-info = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-shutdown-desktop = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-shared-mime-info = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-shutdown-desktop = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-signing-keys = "Richard Purdie <richard.purdie@linuxfoundation.org>"
 RECIPE_MAINTAINER_pn-slang = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-socat = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-source-highlight = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-source-highlight = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-speex = "Tanu Kaskinen <tanuk@iki.fi>"
 RECIPE_MAINTAINER_pn-speexdsp = "Tanu Kaskinen <tanuk@iki.fi>"
-RECIPE_MAINTAINER_pn-sqlite3 = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-sqlite3 = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-squashfs-tools = "Robert Yang <liezhi.yang@windriver.com>"
-RECIPE_MAINTAINER_pn-startup-notification = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-startup-notification = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-strace = "Robert Yang <liezhi.yang@windriver.com>"
-RECIPE_MAINTAINER_pn-stress = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-stress = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-subversion = "Richard Purdie <richard.purdie@linuxfoundation.org>"
 RECIPE_MAINTAINER_pn-sudo = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-swabber-native = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-swig = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-swig = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-sysfsutils = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-sysklogd = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-syslinux = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-sysprof = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-syslinux = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-sysprof = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-sysstat = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-systemd = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-systemd-boot = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-systemd-bootchart = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-systemd-bootconf = "California Sullivan <california.l.sullivan@intel.com>"
+RECIPE_MAINTAINER_pn-systemd-bootconf = "Chen Qi <Qi.Chen@windriver.com>"
+RECIPE_MAINTAINER_pn-systemd-conf = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-systemd-compat-units = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-systemd-serialgetty = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-systemd-systemctl-native = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-systemtap = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-systemtap-uprobes = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-sysvinit = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
-RECIPE_MAINTAINER_pn-sysvinit-inittab = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
-RECIPE_MAINTAINER_pn-taglib = "Maxin B. John <maxin.john@intel.com>"
+RECIPE_MAINTAINER_pn-systemtap = "Victor Kamensky <kamensky@cisco.com>"
+RECIPE_MAINTAINER_pn-systemtap-uprobes = "Victor Kamensky <kamensky@cisco.com>"
+RECIPE_MAINTAINER_pn-sysvinit = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-sysvinit-inittab = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-taglib = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-tar = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-tcf-agent = "Randy Witt <randy.e.witt@linux.intel.com>"
+RECIPE_MAINTAINER_pn-tcf-agent = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-tcl = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-tcp-wrappers = "Robert Yang <liezhi.yang@windriver.com>"
 RECIPE_MAINTAINER_pn-testexport-tarball = "Richard Purdie <richard.purdie@linuxfoundation.org>"
 RECIPE_MAINTAINER_pn-texi2html = "Robert Yang <liezhi.yang@windriver.com>"
-RECIPE_MAINTAINER_pn-texinfo = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-texinfo-dummy-native = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-tiff = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-texinfo = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-texinfo-dummy-native = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-tiff = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-time = "Robert Yang <liezhi.yang@windriver.com>"
-RECIPE_MAINTAINER_pn-tiny-init = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-trace-cmd = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-ttf-bitstream-vera = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-tzcode-native = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-tzdata = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-ttf-bitstream-vera = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-tzcode-native = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-tzdata = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-u-boot = "Marek Vasut <marek.vasut@gmail.com>"
 RECIPE_MAINTAINER_pn-u-boot-fw-utils = "Marek Vasut <marek.vasut@gmail.com>"
 RECIPE_MAINTAINER_pn-u-boot-mkimage = "Marek Vasut <marek.vasut@gmail.com>"
-RECIPE_MAINTAINER_pn-ubootchart = "Ross Burton <ross.burton@intel.com>"
-RECIPE_MAINTAINER_pn-udev-extraconf = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-unfs3 = "Randy Witt <randy.e.witt@linux.intel.com>"
+RECIPE_MAINTAINER_pn-udev-extraconf = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-unfs3 = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-unifdef = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-uninative-tarball = "Richard Purdie <richard.purdie@linuxfoundation.org>"
 RECIPE_MAINTAINER_pn-unzip = "Denys Dmytriyenko <denys@ti.com>"
-RECIPE_MAINTAINER_pn-update-rc.d = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
-RECIPE_MAINTAINER_pn-usbinit = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-usbutils = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-update-rc.d = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-usbinit = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-usbutils = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-util-linux = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-util-macros = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-v86d = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-vala = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-valgrind = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-videoproto = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-util-macros = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-v86d = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-vala = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-valgrind = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-volatile-binds = "Chen Qi <Qi.Chen@windriver.com>"
-RECIPE_MAINTAINER_pn-vte = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-vulkan = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-vulkan-demos = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-waffle = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-watchdog = "Alexander Kanavin <alexander.kanavin@intel.com>"
-RECIPE_MAINTAINER_pn-watchdog-config = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-vte = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-vulkan = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-vulkan-demos = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-waffle = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-watchdog = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-watchdog-config = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-wayland = "Denys Dmytriyenko <denys@ti.com>"
 RECIPE_MAINTAINER_pn-wayland-protocols = "Denys Dmytriyenko <denys@ti.com>"
-RECIPE_MAINTAINER_pn-webkitgtk = "Alexander Kanavin <alexander.kanavin@intel.com>"
+RECIPE_MAINTAINER_pn-webkitgtk = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-weston = "Denys Dmytriyenko <denys@ti.com>"
+RECIPE_MAINTAINER_pn-weston-conf = "Denys Dmytriyenko <denys@ti.com>"
 RECIPE_MAINTAINER_pn-weston-init = "Denys Dmytriyenko <denys@ti.com>"
 RECIPE_MAINTAINER_pn-wget = "Yi Zhao <yi.zhao@windriver.com>"
-RECIPE_MAINTAINER_pn-which = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-wic-tools = "Chang Rebecca Swee Fun <rebecca.swee.fun.chang@intel.com>"
-RECIPE_MAINTAINER_pn-wireless-tools = "Changhyeok Bae <changhyeok.bae@lge.com>"
+RECIPE_MAINTAINER_pn-which = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-wic-tools = "Ross Burton <ross.burton@intel.com>"
 RECIPE_MAINTAINER_pn-wpa-supplicant = "Changhyeok Bae <changhyeok.bae@lge.com>"
-RECIPE_MAINTAINER_pn-x11-common = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-x11perf = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-x11perf = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-x264 = "Anuj Mittal <anuj.mittal@intel.com>"
-RECIPE_MAINTAINER_pn-xauth = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xcb-proto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xcb-util = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xcb-util-image = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xcb-util-keysyms = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xcb-util-renderutil = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xcb-util-wm = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xcmiscproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xcursor-transparent-theme = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xdg-utils = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-xdpyinfo = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xev = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xextproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xeyes = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86-input-evdev = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86-input-keyboard = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86-input-libinput = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86-input-mouse = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86-input-synaptics = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86-input-vmmouse = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86-video-cirrus = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86-video-fbdev = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86-video-intel = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86-video-omap = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86-video-omapfb = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86-video-vesa = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86-video-vmware = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86dgaproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86driproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86miscproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xf86vidmodeproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xhost = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xineramaproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xinetd = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-xinit = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xinput = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xinput-calibrator = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xkbcomp = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xkeyboard-config = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-xauth = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xcb-proto = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xcb-util = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xcb-util-image = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xcb-util-keysyms = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xcb-util-renderutil = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xcb-util-wm = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xcursor-transparent-theme = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xdg-utils = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-xdpyinfo = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xev = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xeyes = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xf86-input-evdev = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xf86-input-keyboard = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xf86-input-libinput = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xf86-input-mouse = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xf86-input-synaptics = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xf86-input-vmmouse = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xf86-video-cirrus = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xf86-video-fbdev = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xf86-video-intel = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xf86-video-vesa = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xf86-video-vmware = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xhost = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xinetd = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-xinit = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xinput = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xinput-calibrator = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xkbcomp = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xkeyboard-config = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-xmlto = "Hongxu Jia <hongxu.jia@windriver.com>"
-RECIPE_MAINTAINER_pn-xmodmap = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xorg-minimal-fonts = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xprop = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xproto = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xrandr = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xrestop = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xserver-nodm-init = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xserver-xf86-config = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xserver-xorg = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xset = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xtrans = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xuser-account = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xvideo-tests = "Maxin B. John <maxin.john@intel.com>"
-RECIPE_MAINTAINER_pn-xvinfo = "Armin Kuster <akuster@mvista.com>"
-RECIPE_MAINTAINER_pn-xwininfo = "Armin Kuster <akuster@mvista.com>"
+RECIPE_MAINTAINER_pn-xmodmap = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xorg-minimal-fonts = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xorgproto = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xprop = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xrandr = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xrestop = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xserver-nodm-init = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xserver-xf86-config = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xserver-xorg = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xset = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xtrans = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xuser-account = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xvideo-tests = "Ross Burton <ross.burton@intel.com>"
+RECIPE_MAINTAINER_pn-xvinfo = "Armin Kuster <akuster808@gmail.com>"
+RECIPE_MAINTAINER_pn-xwininfo = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-xz = "Denys Dmytriyenko <denys@ti.com>"
-RECIPE_MAINTAINER_pn-yasm = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-zip = "Denys Dmytriyenko <denys@ti.com>"
 RECIPE_MAINTAINER_pn-zlib = "Denys Dmytriyenko <denys@ti.com>"
diff --git a/poky/meta/conf/distro/include/no-static-libs.inc b/poky/meta/conf/distro/include/no-static-libs.inc
index 7c165c7..cdc5391 100644
--- a/poky/meta/conf/distro/include/no-static-libs.inc
+++ b/poky/meta/conf/distro/include/no-static-libs.inc
@@ -1,4 +1,4 @@
-DISABLE_STATIC = " --disable-static"
+DISABLE_STATIC ?= " --disable-static"
 
 # qemu aborts on unrecognised option
 DISABLE_STATIC_pn-qemu = ""
@@ -36,6 +36,7 @@
 EXTRA_OECONF_append = "${DISABLE_STATIC}"
 
 EXTRA_OECMAKE_append_pn-libical = " -DSHARED_ONLY=True"
+EXTRA_OECMAKE_append_pn-libjpeg-turbo = " -DENABLE_STATIC=False"
 
 EXCONFIG_ARGS_append_pn-ncurses = " --without-normal"
 EXCONFIG_ARGS_append_pn-ncurses-native = " --without-normal"
diff --git a/poky/meta/conf/distro/include/security_flags.inc b/poky/meta/conf/distro/include/security_flags.inc
index aaeca69..620978a 100644
--- a/poky/meta/conf/distro/include/security_flags.inc
+++ b/poky/meta/conf/distro/include/security_flags.inc
@@ -3,14 +3,14 @@
 # or both so a blacklist is maintained here. The idea would be over
 # time to reduce this list to nothing.
 # From a Yocto Project perspective, this file is included and tested
-# in the DISTRO="poky-lsb" configuration.
+# in the DISTRO="poky" configuration.
 
 GCCPIE ?= "--enable-default-pie"
 # If static PIE is known to work well, GLIBCPIE="--enable-static-pie" can be set
 
 # _FORTIFY_SOURCE requires -O1 or higher, so disable in debug builds as they use
 # -O0 which then results in a compiler warning.
-lcl_maybe_fortify = "${@oe.utils.conditional('DEBUG_BUILD','1','','-D_FORTIFY_SOURCE=2',d)}"
+lcl_maybe_fortify ?= "${@oe.utils.conditional('DEBUG_BUILD','1','','-D_FORTIFY_SOURCE=2',d)}"
 
 # Error on use of format strings that represent possible security problems
 SECURITY_STRINGFORMAT ?= "-Wformat -Wformat-security -Werror=format-security"
@@ -21,19 +21,20 @@
 
 SECURITY_NOPIE_CFLAGS ?= "-no-pie -fno-PIE"
 
-SECURITY_CFLAGS ?= "-fstack-protector-strong ${SECURITY_PIE_CFLAGS} ${lcl_maybe_fortify} ${SECURITY_STRINGFORMAT}"
-SECURITY_NO_PIE_CFLAGS ?= "-fstack-protector-strong ${lcl_maybe_fortify} ${SECURITY_STRINGFORMAT}"
+SECURITY_STACK_PROTECTOR ?= "-fstack-protector-strong"
 
-SECURITY_LDFLAGS ?= "-fstack-protector-strong -Wl,-z,relro,-z,now"
-SECURITY_X_LDFLAGS ?= "-fstack-protector-strong -Wl,-z,relro"
+SECURITY_CFLAGS ?= "${SECURITY_STACK_PROTECTOR} ${SECURITY_PIE_CFLAGS} ${lcl_maybe_fortify} ${SECURITY_STRINGFORMAT}"
+SECURITY_NO_PIE_CFLAGS ?= "${SECURITY_STACK_PROTECTOR} ${lcl_maybe_fortify} ${SECURITY_STRINGFORMAT}"
+
+SECURITY_LDFLAGS ?= "${SECURITY_STACK_PROTECTOR} -Wl,-z,relro,-z,now"
+SECURITY_X_LDFLAGS ?= "${SECURITY_STACK_PROTECTOR} -Wl,-z,relro"
 
 # powerpc does not get on with pie for reasons not looked into as yet
-SECURITY_CFLAGS_powerpc = "-fstack-protector-strong ${lcl_maybe_fortify} ${SECURITY_NOPIE_CFLAGS}"
-SECURITY_CFLAGS_pn-libgcc_powerpc = ""
 GCCPIE_powerpc = ""
 GLIBCPIE_powerpc = ""
+SECURITY_CFLAGS_remove_powerpc = "${SECURITY_PIE_CFLAGS}"
+SECURITY_CFLAGS_pn-libgcc_powerpc = ""
 
-# arm specific security flag issues
 SECURITY_CFLAGS_pn-glibc = ""
 SECURITY_CFLAGS_pn-glibc-initial = ""
 SECURITY_CFLAGS_pn-gcc-runtime = ""
@@ -43,7 +44,6 @@
 SECURITY_CFLAGS_pn-grub-efi-x86-native = ""
 SECURITY_CFLAGS_pn-grub-efi-i586-native = ""
 SECURITY_CFLAGS_pn-grub-efi-x86-64-native = ""
-
 SECURITY_CFLAGS_pn-mkelfimage_x86 = ""
 
 SECURITY_CFLAGS_pn-valgrind = "${SECURITY_NOPIE_CFLAGS}"
@@ -58,9 +58,9 @@
 TARGET_CC_ARCH_append_class-target = " ${SECURITY_CFLAGS}"
 TARGET_LDFLAGS_append_class-target = " ${SECURITY_LDFLAGS}"
 
-SECURITY_LDFLAGS_remove_pn-gcc-runtime = "-fstack-protector-strong"
-SECURITY_LDFLAGS_remove_pn-glibc = "-fstack-protector-strong"
-SECURITY_LDFLAGS_remove_pn-glibc-initial = "-fstack-protector-strong"
+SECURITY_STACK_PROTECTOR_pn-gcc-runtime = ""
+SECURITY_STACK_PROTECTOR_pn-glibc = ""
+SECURITY_STACK_PROTECTOR_pn-glibc-initial = ""
 # All xorg module drivers need to be linked this way as well and are
 # handled in recipes-graphics/xorg-driver/xorg-driver-common.inc
 SECURITY_LDFLAGS_pn-xserver-xorg = "${SECURITY_X_LDFLAGS}"
diff --git a/poky/meta/conf/distro/include/tclibc-baremetal.inc b/poky/meta/conf/distro/include/tclibc-baremetal.inc
index a8ce6d3..e04f8c8 100644
--- a/poky/meta/conf/distro/include/tclibc-baremetal.inc
+++ b/poky/meta/conf/distro/include/tclibc-baremetal.inc
@@ -4,11 +4,9 @@
 
 LIBCEXTENSION = ""
 
-# Add baremetal libc overrides to the overrides.
 LIBCOVERRIDE = ":libc-baremetal"
-OVERRIDES .= "${LIBCOVERRIDE}"
 
-ASSUME_PROVIDED += "virtual/libc virtual/libiconv"
+ASSUME_PROVIDED += "virtual/libc virtual/libiconv virtual/crypt"
 
 PREFERRED_PROVIDER_virtual/libc ?= "musl"
 PREFERRED_PROVIDER_virtual/libiconv ?= "musl"
@@ -23,6 +21,9 @@
 EXTRA_OECONF_pn-gcc-cross-${TARGET_ARCH}_append = " --without-headers"
 DEPENDS_remove_pn-meta-toolchain = "virtual/libc virtual/${TARGET_PREFIX}compilerlibs"
 
+# certain compiler libs cannot be used without libc, avoid the dependence on compilerlibs
+BASEDEPENDS_remove_class-target = "virtual/${TARGET_PREFIX}compilerlibs"
+
 TARGET_OS = "elf"
 TARGET_OS_arm = "eabi"
 
@@ -30,3 +31,9 @@
 TOOLCHAIN_HOST_TASK_ATTEMPTONLY ?= ""
 TOOLCHAIN_TARGET_TASK ?= "libgcc-dev"
 TOOLCHAIN_NEED_CONFIGSITE_CACHE_remove = "virtual/${MLPREFIX}libc zlib ncurses"
+
+# disable stack protector by default (no-libc, no protector implementation)
+SECURITY_STACK_PROTECTOR_libc-baremetal = ""
+# disable pie security flags by default
+SECURITY_CFLAGS_libc-baremetal = "${SECURITY_NOPIE_CFLAGS}"
+SECURITY_LDFLAGS_libc-baremetal = ""
diff --git a/poky/meta/conf/distro/include/tclibc-glibc.inc b/poky/meta/conf/distro/include/tclibc-glibc.inc
index ad8000f..8d10764 100644
--- a/poky/meta/conf/distro/include/tclibc-glibc.inc
+++ b/poky/meta/conf/distro/include/tclibc-glibc.inc
@@ -4,9 +4,7 @@
 
 LIBCEXTENSION = "${@['', '-gnu'][(d.getVar('ABIEXTENSION') or '') != '']}"
 
-# Add glibc overrides to the overrides for glibc.
 LIBCOVERRIDE = ":libc-glibc"
-OVERRIDES .= "${LIBCOVERRIDE}"
 
 PREFERRED_PROVIDER_virtual/libiconv ?= "glibc"
 PREFERRED_PROVIDER_virtual/nativesdk-libiconv ?= "nativesdk-glibc"
diff --git a/poky/meta/conf/distro/include/tclibc-musl.inc b/poky/meta/conf/distro/include/tclibc-musl.inc
index 54e1acf..8badbbb 100644
--- a/poky/meta/conf/distro/include/tclibc-musl.inc
+++ b/poky/meta/conf/distro/include/tclibc-musl.inc
@@ -4,13 +4,12 @@
 
 LIBCEXTENSION = "-musl"
 
-# Add musl libc overrides to the overrides.
 LIBCOVERRIDE = ":libc-musl"
-OVERRIDES .= "${LIBCOVERRIDE}"
 
 PREFERRED_PROVIDER_virtual/libc ?= "musl"
 PREFERRED_PROVIDER_virtual/libiconv ?= "musl"
 PREFERRED_PROVIDER_virtual/libintl ?= "musl"
+PREFERRED_PROVIDER_virtual/crypt ?= "musl"
 PREFERRED_PROVIDER_virtual/nativesdk-libintl ?= "nativesdk-glibc"
 PREFERRED_PROVIDER_virtual/nativesdk-libiconv ?= "nativesdk-glibc"
 
diff --git a/poky/meta/conf/distro/include/tclibc-newlib.inc b/poky/meta/conf/distro/include/tclibc-newlib.inc
new file mode 100644
index 0000000..896c0b1
--- /dev/null
+++ b/poky/meta/conf/distro/include/tclibc-newlib.inc
@@ -0,0 +1,48 @@
+#
+# Newlib configuration
+#
+
+LIBCEXTENSION = "-newlib"
+LIBCOVERRIDE = ":libc-newlib"
+
+PREFERRED_PROVIDER_virtual/libc ?= "newlib"
+PREFERRED_PROVIDER_virtual/libiconv ?= "newlib"
+PREFERRED_PROVIDER_virtual/libintl ?= "newlib"
+PREFERRED_PROVIDER_virtual/nativesdk-libintl ?= "nativesdk-glibc"
+PREFERRED_PROVIDER_virtual/nativesdk-libiconv ?= "nativesdk-glibc"
+
+DISTRO_FEATURES_BACKFILL_CONSIDERED += "ldconfig"
+
+#USE_NLS ?= "no"
+
+IMAGE_LINGUAS = ""
+
+LIBC_DEPENDENCIES = "\
+    newlib-dbg \
+    newlib-dev \
+    libgloss \
+    libgloss-dev \
+    libgloss-dbg \
+    libgcc-dev \
+    libgcc-dbg \
+    "
+
+# compilerlibs defaults to gcc-runtime, but we get runtime from libgloss
+# we set ASSUME_PROVIDED because we cant set PREFERRED_PROVIDER
+# for compilerlibs since its overridden by tcmode-default
+ASSUME_PROVIDED += "virtual/${TARGET_PREFIX}compilerlibs virtual/crypt"
+
+# Its useful to be able to extend newlib, but we dont provide a native variant of libgloss
+NEWLIB_EXTENDED ?=  "libgloss libgcc"
+BASE_DEFAULT_DEPS_append_class-target = " ${NEWLIB_EXTENDED}"
+
+TARGET_OS = "elf"
+TARGET_OS_arm = "eabi"
+
+TOOLCHAIN_HOST_TASK ?= "packagegroup-cross-canadian-${MACHINE}"
+TOOLCHAIN_TARGET_TASK ?= "${LIBC_DEPENDENCIES}"
+TOOLCHAIN_NEED_CONFIGSITE_CACHE_remove = "zlib ncurses"
+
+# disable pie security flags by default
+SECURITY_CFLAGS_libc-newlib = "${SECURITY_NOPIE_CFLAGS}"
+SECURITY_LDFLAGS_libc-newlib = ""
diff --git a/poky/meta/conf/distro/include/tcmode-default.inc b/poky/meta/conf/distro/include/tcmode-default.inc
index 00399ae..f8da651 100644
--- a/poky/meta/conf/distro/include/tcmode-default.inc
+++ b/poky/meta/conf/distro/include/tcmode-default.inc
@@ -22,13 +22,14 @@
 PREFERRED_PROVIDER_virtual/nativesdk-${SDK_PREFIX}libc-initial ?= "nativesdk-glibc-initial"
 PREFERRED_PROVIDER_virtual/gettext ??= "gettext"
 
-GCCVERSION ?= "7.%"
+GCCVERSION ?= "8.%"
 SDKGCCVERSION ?= "${GCCVERSION}"
-BINUVERSION ?= "2.30%"
-GDBVERSION ?= "8.0%"
-GLIBCVERSION ?= "2.27%"
-LINUXLIBCVERSION ?= "4.15%"
-QEMUVERSION ?= "2.11%"
+BINUVERSION ?= "2.31%"
+GDBVERSION ?= "8.2%"
+GLIBCVERSION ?= "2.28%"
+LINUXLIBCVERSION ?= "4.18%"
+QEMUVERSION ?= "3.0%"
+GOVERSION ?= "1.11%"
 
 PREFERRED_VERSION_gcc ?= "${GCCVERSION}"
 PREFERRED_VERSION_gcc-cross-${TARGET_ARCH} ?= "${GCCVERSION}"
@@ -65,14 +66,10 @@
 PREFERRED_VERSION_nativesdk-glibc-initial  ?= "${GLIBCVERSION}"
 PREFERRED_VERSION_cross-localedef-native   ?= "${GLIBCVERSION}"
 
-
 PREFERRED_VERSION_qemu ?= "${QEMUVERSION}"
 PREFERRED_VERSION_qemu-native ?= "${QEMUVERSION}"
 PREFERRED_VERSION_nativesdk-qemu ?= "${QEMUVERSION}"
-# Setup suitable toolchain flags
-require conf/distro/include/as-needed.inc
 
-GOVERSION ?= "1.9%"
 PREFERRED_VERSION_virtual/${TARGET_PREFIX}go ?= "${GOVERSION}"
 PREFERRED_VERSION_go-cross-${TARGET_ARCH} ?= "${GOVERSION}"
 PREFERRED_VERSION_go-crosssdk-${SDK_ARCH} ?= "${GOVERSION}"
diff --git a/poky/meta/conf/distro/include/yocto-uninative.inc b/poky/meta/conf/distro/include/yocto-uninative.inc
index c5b0556..c9d502b 100644
--- a/poky/meta/conf/distro/include/yocto-uninative.inc
+++ b/poky/meta/conf/distro/include/yocto-uninative.inc
@@ -9,6 +9,7 @@
 UNINATIVE_MAXGLIBCVERSION = "2.28"
 
 UNINATIVE_URL ?= "http://downloads.yoctoproject.org/releases/uninative/2.3/"
+UNINATIVE_CHECKSUM[aarch64] ?= "b7fbbaad1ec86d76eca84d83098f50525b8a4124cc8685eaed"
 UNINATIVE_CHECKSUM[i686] ?= "44253cddbf629082568cea4fff59419106871a0cf81b4845b5d34e7014887b20"
 UNINATIVE_CHECKSUM[x86_64] ?= "c6954563dad3c95608117c6fc328099036c832bbd924ebf5fdccb622fc0a8684"
 
diff --git a/poky/meta/conf/documentation.conf b/poky/meta/conf/documentation.conf
index 254f8f1..fc6d008 100644
--- a/poky/meta/conf/documentation.conf
+++ b/poky/meta/conf/documentation.conf
@@ -288,8 +288,6 @@
 
 NATIVELSBSTRING[doc] = "A string identifying the host distribution."
 NO_RECOMMENDATIONS[doc] = "When set to '1', no recommended packages will be installed. Realize that some recommended packages might be required for certain system functionality, such as kernel-modules. It is up to the user to add packages to IMAGE_INSTALL as needed."
-NOHDD[doc] = "Causes the OpenEmbedded build system to skip building the .hddimg image."
-NOISO[doc] = "Causes the OpenEmbedded build system to skip building the ISO image."
 
 #O
 
@@ -417,7 +415,7 @@
 TARGET_SYS[doc] = "The target system is comprised of TARGET_ARCH,TARGET_VENDOR and TARGET_OS."
 TCLIBC[doc] = "Specifies C library (libc) variant to use during the build process. You can select 'baremetal', 'glibc' or 'musl'."
 TCMODE[doc] = "Enables an external toolchain (where provided by an additional layer) if set to a value other than 'default'."
-TEST_IMAGE[doc] = "Enables test booting of virtual machine images under the QEMU emulator after any root filesystems are created and runs tests against those images."
+TESTIMAGE_AUTO[doc] = "Enables test booting of virtual machine images under the QEMU emulator after any root filesystems are created and runs tests against those images each time an image is built."
 TEST_QEMUBOOT_TIMEOUT[doc] = "The time in seconds allowed for an image to boot before automated runtime tests begin to run against an image."
 TEST_SUITES[doc] = "An ordered list of tests (modules) to run against an image when performing automated runtime testing."
 TEST_POWERCONTROL_CMD[doc] = "For automated hardware testing, specifies the command to use to control the power of the target machine under test"
diff --git a/poky/meta/conf/layer.conf b/poky/meta/conf/layer.conf
index 315fb93..c67dec4 100644
--- a/poky/meta/conf/layer.conf
+++ b/poky/meta/conf/layer.conf
@@ -7,12 +7,12 @@
 BBFILE_PATTERN_core = "^${LAYERDIR}/"
 BBFILE_PRIORITY_core = "5"
 
-LAYERSERIES_CORENAMES = "sumo"
+LAYERSERIES_CORENAMES = "thud"
 
 # This should only be incremented on significant changes that will
 # cause compatibility issues with other layers
 LAYERVERSION_core = "11"
-LAYERSERIES_COMPAT_core = "sumo"
+LAYERSERIES_COMPAT_core = "thud"
 
 BBLAYERS_LAYERINDEX_NAME_core = "openembedded-core"
 
@@ -74,9 +74,27 @@
   gnome-icon-theme->librsvg \
   font-alias->font-util \
   systemd-boot->systemd-bootconf \
+  systemd->systemd-conf \
+  weston->weston-conf \
   weston-init->weston \
   weston-init->kbd \
 "
 
+# Avoid adding bison-native to the sysroot without a specific
+# dependency in the recipe. This means indirect dependencies
+# (e.g. X -> Y -> binutils-cross -> bison-native) no longer meet the
+# dependency incidentally. This improves determinism and avoids build
+# failures when people switch to external toolchains.
+SSTATE_EXCLUDEDEPS_SYSROOT += ".*->bison-native"
+# Nothing needs to depend on libc-initial/gcc-cross-initial
+# base-passwd/shadow-sysroot don't need their dependencies
+SSTATE_EXCLUDEDEPS_SYSROOT += "\
+    .*->.*-initial.* \
+    .*(base-passwd|shadow-sysroot)->.* \
+"
+# Avoid adding autoconf-archive-native to sysroot without a specific
+# dependency in the recipe.
+SSTATE_EXCLUDEDEPS_SYSROOT += ".*->autoconf-archive-native"
+
 # We need to keep bitbake tools in PATH
 PATH := "${@os.path.dirname(bb.utils.which(d.getVar('PATH'),'bitbake'))}:${HOSTTOOLS_DIR}"
diff --git a/poky/meta/conf/machine-sdk/aarch64.conf b/poky/meta/conf/machine-sdk/aarch64.conf
new file mode 100644
index 0000000..98d8380
--- /dev/null
+++ b/poky/meta/conf/machine-sdk/aarch64.conf
@@ -0,0 +1,2 @@
+SDK_ARCH = "aarch64"
+ABIEXTENSION_class-nativesdk = ""
diff --git a/poky/meta/conf/machine/include/arm/arch-armv7a.inc b/poky/meta/conf/machine/include/arm/arch-armv7a.inc
index bad1c27..a2663d8 100644
--- a/poky/meta/conf/machine/include/arm/arch-armv7a.inc
+++ b/poky/meta/conf/machine/include/arm/arch-armv7a.inc
@@ -1,4 +1,5 @@
 DEFAULTTUNE ?= "armv7athf"
+ARM_INSTRUCTION_SET ?= "thumb"
 
 TUNEVALID[armv7a] = "Enable instructions for ARMv7-a"
 TUNECONFLICTS[armv7a] = "armv4 armv5 armv6 armv7"
diff --git a/poky/meta/conf/machine/include/m68k/arch-m68k.inc b/poky/meta/conf/machine/include/m68k/arch-m68k.inc
new file mode 100644
index 0000000..3ff8a3a
--- /dev/null
+++ b/poky/meta/conf/machine/include/m68k/arch-m68k.inc
@@ -0,0 +1,8 @@
+# m68k Architecture definitions
+
+DEFAULTTUNE ?= "m68k"
+
+# Architecture name
+TUNE_ARCH = "m68k"
+
+TUNE_PKGARCH = "${TUNE_PKGARCH_tune-${DEFAULTTUNE}}"
diff --git a/poky/meta/conf/machine/include/mips/tune-mips-74k.inc b/poky/meta/conf/machine/include/mips/tune-mips-74k.inc
new file mode 100644
index 0000000..94afee3
--- /dev/null
+++ b/poky/meta/conf/machine/include/mips/tune-mips-74k.inc
@@ -0,0 +1,37 @@
+DEFAULTTUNE ?= "mips32r2-74kc"
+
+MIPSPKGSFX_MIPS16E ??= ""
+
+require conf/machine/include/tune-mips32r2.inc
+require conf/machine/include/mips/feature-mips-mips16e.inc
+
+
+TUNEVALID[74kc] = "Enable MIPS 74K with DSPr2 processor optimizations"
+TUNE_CCARGS .= "${@bb.utils.contains("TUNE_FEATURES", "74kc", " -mtune=74kc", "", d)}"
+
+AVAILTUNES += "mips32r2-74kc mips32r2-74kc-m16"
+AVAILTUNES += "mips32r2el-74kc mips32r2el-74kc-m16"
+
+# big endian: kc+dsp2=kc, kc+dsp2+mips16e=kc-m16
+TUNE_FEATURES_tune-mips32r2-74kc = "${TUNE_FEATURES_tune-mips32r2-nf} 74kc"
+TUNE_FEATURES_tune-mips32r2-74kc-m16 = "${TUNE_FEATURES_tune-mips32r2-74kc} mips16e"
+
+MIPSPKGSFX_VARIANT_tune-mips32r2-74kc = "mips32r2-74kc"
+PACKAGE_EXTRA_ARCHS_tune-mips32r2-74kc = "${PACKAGE_EXTRA_ARCHS_tune-mips32r2-nf} mips32r2-74kc-nf"
+QEMU_EXTRAOPTIONS_mips32r2-74kc-nf = " -cpu 24Kc"
+
+MIPSPKGSFX_VARIANT_tune-mips32r2-74kc-m16 = "mips32r2-74kc${MIPSPKGSFX_MIPS16E}"
+PACKAGE_EXTRA_ARCHS_tune-mips32r2-74kc-m16 = "${PACKAGE_EXTRA_ARCHS_tune-mips32r2-74kc} mips32r2-74kc-m16-nf"
+QEMU_EXTRAOPTIONS_mips32r2-74kc-m16-nf = " -cpu 24KEc"
+
+# little endian: kc+dsp2=kc, kc+dsp2+mips16e=kc-m16
+TUNE_FEATURES_tune-mips32r2el-74kc = "${TUNE_FEATURES_tune-mips32r2el-nf} 74kc"
+TUNE_FEATURES_tune-mips32r2el-74kc-m16 = "${TUNE_FEATURES_tune-mips32r2el-74kc} mips16e"
+
+MIPSPKGSFX_VARIANT_tune-mips32r2el-74kc = "mips32r2el-74kc"
+PACKAGE_EXTRA_ARCHS_tune-mips32r2el-74kc = "${PACKAGE_EXTRA_ARCHS_tune-mips32r2el-nf} mips32r2el-74kc-nf"
+QEMU_EXTRAOPTIONS_mips32r2el-74kc-nf = " -cpu 24Kc"
+
+MIPSPKGSFX_VARIANT_tune-mips32r2el-74kc-m16 = "mips32r2el-74kc${MIPSPKGSFX_MIPS16E}"
+PACKAGE_EXTRA_ARCHS_tune-mips32r2el-74kc-m16 = "${PACKAGE_EXTRA_ARCHS_tune-mips32r2el-74kc} mips32r2el-74kc-m16-nf"
+QEMU_EXTRAOPTIONS_mips32r2el-74kc-m16-nf = " -cpu 24KEc"
diff --git a/poky/meta/conf/machine/include/qemu.inc b/poky/meta/conf/machine/include/qemu.inc
index aa332fe..5050e41 100644
--- a/poky/meta/conf/machine/include/qemu.inc
+++ b/poky/meta/conf/machine/include/qemu.inc
@@ -19,7 +19,7 @@
 RDEPENDS_${KERNEL_PACKAGE_NAME}-base = ""
 
 # Use a common kernel recipe for all QEMU machines
-PREFERRED_PROVIDER_virtual/kernel ?= "linux-yocto"
+PREFERRED_PROVIDER_virtual/kernel ??= "linux-yocto"
 
 EXTRA_IMAGEDEPENDS += "qemu-native qemu-helper-native"
 
diff --git a/poky/meta/conf/machine/include/tune-core2.inc b/poky/meta/conf/machine/include/tune-core2.inc
index c686bb4..ddde719 100644
--- a/poky/meta/conf/machine/include/tune-core2.inc
+++ b/poky/meta/conf/machine/include/tune-core2.inc
@@ -21,7 +21,7 @@
 BASE_LIB_tune-core2-32 = "lib"
 TUNE_PKGARCH_tune-core2-32 = "core2-32"
 PACKAGE_EXTRA_ARCHS_tune-core2-32 = "${PACKAGE_EXTRA_ARCHS_tune-i686} core2-32"
-QEMU_EXTRAOPTIONS_core2-32 = " -cpu core2duo"
+QEMU_EXTRAOPTIONS_core2-32 = " -cpu n270"
 
 AVAILTUNES += "core2-64"
 TUNE_FEATURES_tune-core2-64 = "${TUNE_FEATURES_tune-x86-64} core2"
diff --git a/poky/meta/conf/machine/include/tune-corei7.inc b/poky/meta/conf/machine/include/tune-corei7.inc
index 6edfb68..d06af47 100644
--- a/poky/meta/conf/machine/include/tune-corei7.inc
+++ b/poky/meta/conf/machine/include/tune-corei7.inc
@@ -1,20 +1,19 @@
-# Settings for the GCC(1) cpu-type "corei7":
+# Settings for the GCC(1) cpu-type "nehalem":
 #
-#     Intel Core i7 CPU with 64-bit extensions, MMX, SSE, SSE2, SSE3, SSSE3, SSE4.1
-#     and SSE4.2 instruction set support.
+#     Intel Nehalem CPU with 64-bit extensions, MMX, SSE, SSE2, SSE3, SSSE3, SSE4.1,
+#     SSE4.2 and POPCNT instruction set support.
 #
 # This tune is recommended for Intel Nehalem and Silvermont (e.g. Bay Trail) CPUs
 # (and beyond).
 #
 DEFAULTTUNE ?= "corei7-64"
 
-# Pull in the previous tune in to pull in PACKAGE_EXTRA_ARCHS
+# Include the previous tune to pull in PACKAGE_EXTRA_ARCHS
 require conf/machine/include/tune-core2.inc
 
-
 # Extra tune features
 TUNEVALID[corei7] = "Enable corei7 specific processor optimizations"
-TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'corei7', ' -march=corei7 -mtune=corei7 -mfpmath=sse -msse4.2', '', d)}"
+TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'corei7', ' -march=nehalem -mtune=generic -mfpmath=sse -msse4.2', '', d)}"
 
 # Extra tune selections
 AVAILTUNES += "corei7-32"
diff --git a/poky/meta/conf/machine/include/tune-mcf5441x.inc b/poky/meta/conf/machine/include/tune-mcf5441x.inc
new file mode 100644
index 0000000..11a41a7
--- /dev/null
+++ b/poky/meta/conf/machine/include/tune-mcf5441x.inc
@@ -0,0 +1,13 @@
+DEFAULTTUNE ?= "mcf5441x"
+
+require conf/machine/include/m68k/arch-m68k.inc
+
+TUNEVALID[mcf5441x] = "Enable coldfire specific processor optimizations"
+TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'mcf5441x', ' -mcpu=54418', '', d)}"
+
+AVAILTUNES += "mcf5441x"
+TUNE_FEATURES_tune-mcf5441x = "mcf5441x"
+TUNE_ARCH_tune-mcf5441x = "mcf5441x"
+TUNE_PKGARCH_tune-mcf5441x = "mcf5441x"
+PACKAGE_EXTRA_ARCHS_tune-mcf5441x = "m68k mcf5441x"
+
diff --git a/poky/meta/conf/machine/include/x86-base.inc b/poky/meta/conf/machine/include/x86-base.inc
index f8aacea..c292792 100644
--- a/poky/meta/conf/machine/include/x86-base.inc
+++ b/poky/meta/conf/machine/include/x86-base.inc
@@ -8,20 +8,17 @@
 MACHINE_FEATURES += "screen keyboard pci usbhost ext2 ext3 x86 \
                      acpi serial usbgadget alsa"
 
-MACHINE_EXTRA_RRECOMMENDS += "kernel-modules"
-
-IMAGE_FSTYPES ?= "live"
-NOISO ?= "1"
+IMAGE_FSTYPES ?= "hddimg"
 
 KERNEL_IMAGETYPE ?= "bzImage"
 
-SERIAL_CONSOLE ?= "115200 ttyS0"
+SERIAL_CONSOLES ?= "115200;ttyS0"
 
 #
 # kernel-related variables
 #
 PREFERRED_PROVIDER_virtual/kernel ??= "linux-yocto"
-PREFERRED_VERSION_linux-yocto ??= "4.15%"
+PREFERRED_VERSION_linux-yocto ??= "4.18%"
 
 #
 # XSERVER subcomponents, used to build the XSERVER variable
diff --git a/poky/meta/conf/machine/qemuarm.conf b/poky/meta/conf/machine/qemuarm.conf
index 9403b1e..d2f2c85 100644
--- a/poky/meta/conf/machine/qemuarm.conf
+++ b/poky/meta/conf/machine/qemuarm.conf
@@ -16,5 +16,5 @@
 QB_KERNEL_CMDLINE_APPEND = "console=ttyAMA0,115200 console=tty"
 # Add the 'virtio-rng-pci' device otherwise the guest may run out of entropy
 QB_OPT_APPEND = "-show-cursor -usb -device usb-tablet -device virtio-rng-pci"
-PREFERRED_VERSION_linux-yocto ??= "4.15%"
+PREFERRED_VERSION_linux-yocto ??= "4.18%"
 QB_DTB = "${@oe.utils.version_less_or_equal('PREFERRED_VERSION_linux-yocto', '4.7', '', 'zImage-versatile-pb.dtb', d)}"
diff --git a/poky/meta/conf/machine/qemumips.conf b/poky/meta/conf/machine/qemumips.conf
index 986315a..a60f67a 100644
--- a/poky/meta/conf/machine/qemumips.conf
+++ b/poky/meta/conf/machine/qemumips.conf
@@ -10,5 +10,3 @@
 KERNEL_ALT_IMAGETYPE = "vmlinux.bin"
 
 SERIAL_CONSOLES ?= "115200;ttyS0 115200;ttyS1"
-
-MACHINE_EXTRA_RRECOMMENDS = " kernel-modules"
diff --git a/poky/meta/conf/machine/qemumips64.conf b/poky/meta/conf/machine/qemumips64.conf
index 3f91cbe..a166a10 100644
--- a/poky/meta/conf/machine/qemumips64.conf
+++ b/poky/meta/conf/machine/qemumips64.conf
@@ -10,5 +10,3 @@
 KERNEL_ALT_IMAGETYPE = "vmlinux.bin"
 
 SERIAL_CONSOLES ?= "115200;ttyS0 115200;ttyS1"
-
-MACHINE_EXTRA_RRECOMMENDS = " kernel-modules"
diff --git a/poky/meta/conf/machine/qemux86-64.conf b/poky/meta/conf/machine/qemux86-64.conf
index 2330c7d..9966d1a 100644
--- a/poky/meta/conf/machine/qemux86-64.conf
+++ b/poky/meta/conf/machine/qemux86-64.conf
@@ -12,6 +12,8 @@
 require conf/machine/include/tune-core2.inc
 require conf/machine/include/qemuboot-x86.inc
 
+UBOOT_MACHINE ?= "qemu-x86_64_defconfig"
+
 KERNEL_IMAGETYPE = "bzImage"
 
 SERIAL_CONSOLES ?= "115200;ttyS0 115200;ttyS1"
@@ -29,6 +31,8 @@
 
 MACHINE_ESSENTIAL_EXTRA_RDEPENDS += "v86d"
 
+MACHINE_EXTRA_RRECOMMENDS = "kernel-module-snd-ens1370 kernel-module-snd-rawmidi"
+
 KERNEL_MODULE_AUTOLOAD += "uvesafb"
 KERNEL_MODULE_PROBECONF += "uvesafb"
 module_conf_uvesafb = "options uvesafb mode_option=${UVESA_MODE}"
diff --git a/poky/meta/conf/machine/qemux86.conf b/poky/meta/conf/machine/qemux86.conf
index 811e3ef..e78fb6e 100644
--- a/poky/meta/conf/machine/qemux86.conf
+++ b/poky/meta/conf/machine/qemux86.conf
@@ -11,6 +11,8 @@
 require conf/machine/include/tune-i586.inc
 require conf/machine/include/qemuboot-x86.inc
 
+UBOOT_MACHINE ?= "qemu-x86_defconfig"
+
 KERNEL_IMAGETYPE = "bzImage"
 
 SERIAL_CONSOLES ?= "115200;ttyS0 115200;ttyS1"
@@ -28,6 +30,8 @@
 
 MACHINE_ESSENTIAL_EXTRA_RDEPENDS += "v86d"
 
+MACHINE_EXTRA_RRECOMMENDS = "kernel-module-snd-ens1370 kernel-module-snd-rawmidi"
+
 KERNEL_MODULE_AUTOLOAD += "uvesafb"
 KERNEL_MODULE_PROBECONF += "uvesafb"
 module_conf_uvesafb = "options uvesafb mode_option=${UVESA_MODE}"
diff --git a/poky/meta/conf/multilib.conf b/poky/meta/conf/multilib.conf
index e74dec8..65a28dd 100644
--- a/poky/meta/conf/multilib.conf
+++ b/poky/meta/conf/multilib.conf
@@ -26,3 +26,7 @@
 PKG_CONFIG_PATH .= ":${WORKDIR}/recipe-sysroot/${datadir}/pkgconfig"
 PKG_CONFIG_PATH[vardepsexclude] = "datadir WORKDIR"
 PKG_CONFIG_PATH[vardepvalueexclude] = ":${WORKDIR}/recipe-sysroot/${datadir}/pkgconfig"
+
+# These recipes don't need multilib variants, the ${BPN} PROVDES/RPROVDES
+# ${MLPREFIX}${BPN}
+NON_MULTILIB_RECIPES = "grub grub-efi make-mod-scripts"
diff --git a/poky/meta/conf/sanity.conf b/poky/meta/conf/sanity.conf
index 390d342..45e6752 100644
--- a/poky/meta/conf/sanity.conf
+++ b/poky/meta/conf/sanity.conf
@@ -3,7 +3,7 @@
 # See sanity.bbclass
 #
 # Expert users can confirm their sanity with "touch conf/sanity.conf"
-BB_MIN_VERSION = "1.35.0"
+BB_MIN_VERSION = "1.39.1"
 
 SANITY_ABIFILE = "${TMPDIR}/abi_version"
 
diff --git a/poky/meta/files/toolchain-shar-extract.sh b/poky/meta/files/toolchain-shar-extract.sh
index f7ab430..9eabd62 100644
--- a/poky/meta/files/toolchain-shar-extract.sh
+++ b/poky/meta/files/toolchain-shar-extract.sh
@@ -3,6 +3,7 @@
 [ -z "$ENVCLEANED" ] && exec /usr/bin/env -i ENVCLEANED=1 HOME="$HOME" \
 	LC_ALL=en_US.UTF-8 \
 	TERM=$TERM \
+	ICECC_PATH="$ICECC_PATH" \
 	http_proxy="$http_proxy" https_proxy="$https_proxy" ftp_proxy="$ftp_proxy" \
 	no_proxy="$no_proxy" all_proxy="$all_proxy" GIT_PROXY_COMMAND="$GIT_PROXY_COMMAND" "$0" "$@"
 [ -f /etc/environment ] && . /etc/environment
diff --git a/poky/meta/lib/bblayers/create.py b/poky/meta/lib/bblayers/create.py
index c192316..2ebf151 100644
--- a/poky/meta/lib/bblayers/create.py
+++ b/poky/meta/lib/bblayers/create.py
@@ -30,8 +30,10 @@
         conf = os.path.join(layerdir, 'conf')
         bb.utils.mkdirhier(conf)
 
+        layername = os.path.basename(os.path.normpath(args.layerdir))
+
         # Create the README from templates/README
-        readme_template =  read_template('README') % (args.layerdir, args.layerdir, args.layerdir, args.layerdir, args.layerdir, args.layerdir)
+        readme_template =  read_template('README').format(layername=layername)
         readme = os.path.join(layerdir, 'README')
         with open(readme, 'w') as fd:
             fd.write(readme_template)
@@ -43,8 +45,12 @@
         license_dst = os.path.join(layerdir, copying)
         shutil.copy(license_src, license_dst)
 
+        # Get the compat value for core layer.
+        compat = self.tinfoil.config_data.getVar('LAYERSERIES_COMPAT_core') or ""
+
         # Create the layer.conf from templates/layer.conf
-        layerconf_template = read_template('layer.conf') % (args.layerdir, args.layerdir, args.layerdir, args.priority)
+        layerconf_template = read_template('layer.conf').format(
+                layername=layername, priority=args.priority, compat=compat)
         layerconf = os.path.join(conf, 'layer.conf')
         with open(layerconf, 'w') as fd:
             fd.write(layerconf_template)
diff --git a/poky/meta/lib/bblayers/templates/README b/poky/meta/lib/bblayers/templates/README
index 5a77f8d..fb2d28e 100644
--- a/poky/meta/lib/bblayers/templates/README
+++ b/poky/meta/lib/bblayers/templates/README
@@ -1,4 +1,4 @@
-This README file contains information on the contents of the %s layer.
+This README file contains information on the contents of the {layername} layer.
 
 Please see the corresponding sections below for details.
 
@@ -18,7 +18,7 @@
 Patches
 =======
 
-Please submit any patches against the %s layer to the xxxx mailing list (xxxx@zzzz.org)
+Please submit any patches against the {layername} layer to the xxxx mailing list (xxxx@zzzz.org)
 and cc: the maintainer:
 
 Maintainer: XXX YYYYYY <xxx.yyyyyy@zzzzz.com>
@@ -26,16 +26,16 @@
 Table of Contents
 =================
 
-  I. Adding the %s layer to your build
+  I. Adding the {layername} layer to your build
  II. Misc
 
 
-I. Adding the %s layer to your build
+I. Adding the {layername} layer to your build
 =================================================
 
-Run 'bitbake-layers add-layer %s'
+Run 'bitbake-layers add-layer {layername}'
 
 II. Misc
 ========
 
---- replace with specific information about the %s layer ---
+--- replace with specific information about the {layername} layer ---
diff --git a/poky/meta/lib/bblayers/templates/layer.conf b/poky/meta/lib/bblayers/templates/layer.conf
index 3c03002..e2eaff4 100644
--- a/poky/meta/lib/bblayers/templates/layer.conf
+++ b/poky/meta/lib/bblayers/templates/layer.conf
@@ -1,10 +1,13 @@
 # We have a conf and classes directory, add to BBPATH
-BBPATH .= ":${LAYERDIR}"
+BBPATH .= ":${{LAYERDIR}}"
 
 # We have recipes-* directories, add to BBFILES
-BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \
-            ${LAYERDIR}/recipes-*/*/*.bbappend"
+BBFILES += "${{LAYERDIR}}/recipes-*/*/*.bb \
+            ${{LAYERDIR}}/recipes-*/*/*.bbappend"
 
-BBFILE_COLLECTIONS += "%s"
-BBFILE_PATTERN_%s = "^${LAYERDIR}/"
-BBFILE_PRIORITY_%s = "%s"
+BBFILE_COLLECTIONS += "{layername}"
+BBFILE_PATTERN_{layername} = "^${{LAYERDIR}}/"
+BBFILE_PRIORITY_{layername} = "{priority}"
+
+LAYERDEPENDS_{layername} = "core"
+LAYERSERIES_COMPAT_{layername} = "{compat}"
diff --git a/poky/meta/lib/oe/buildhistory_analysis.py b/poky/meta/lib/oe/buildhistory_analysis.py
index b0365ab..ad7fceb 100644
--- a/poky/meta/lib/oe/buildhistory_analysis.py
+++ b/poky/meta/lib/oe/buildhistory_analysis.py
@@ -13,6 +13,7 @@
 import difflib
 import git
 import re
+import shlex
 import hashlib
 import collections
 import bb.utils
@@ -31,13 +32,6 @@
 monitor_numeric_threshold = 10
 # Image files to monitor (note that image-info.txt is handled separately)
 img_monitor_files = ['installed-package-names.txt', 'files-in-image.txt']
-# Related context fields for reporting (note: PE, PV & PR are always reported for monitored package fields)
-related_fields = {}
-related_fields['RDEPENDS'] = ['DEPENDS']
-related_fields['RRECOMMENDS'] = ['DEPENDS']
-related_fields['FILELIST'] = ['FILES']
-related_fields['files-in-image.txt'] = ['installed-package-names.txt', 'USER_CLASSES', 'IMAGE_CLASSES', 'ROOTFS_POSTPROCESS_COMMAND', 'IMAGE_POSTPROCESS_COMMAND']
-related_fields['installed-package-names.txt'] = ['IMAGE_FEATURES', 'IMAGE_LINGUAS', 'IMAGE_INSTALL', 'BAD_RECOMMENDATIONS', 'NO_RECOMMENDATIONS', 'PACKAGE_EXCLUDE']
 
 colours = {
     'colour_default': '',
@@ -67,7 +61,6 @@
         self.oldvalue = oldvalue
         self.newvalue = newvalue
         self.monitored = monitored
-        self.related = []
         self.filechanges = None
 
     def __str__(self):
@@ -123,10 +116,13 @@
                 aitems = pkglist_combine(depvera)
                 bitems = pkglist_combine(depverb)
             else:
-                aitems = self.oldvalue.split()
-                bitems = self.newvalue.split()
                 if self.fieldname == 'FILELIST':
+                    aitems = shlex.split(self.oldvalue)
+                    bitems = shlex.split(self.newvalue)
                     renamed_dirs, aitems, bitems = detect_renamed_dirs(aitems, bitems)
+                else:
+                    aitems = self.oldvalue.split()
+                    bitems = self.newvalue.split()
 
             removed = list(set(aitems) - set(bitems))
             added = list(set(bitems) - set(aitems))
@@ -206,13 +202,6 @@
         else:
             out = '{} changed from "{colour_remove}{}{colour_default}" to "{colour_add}{}{colour_default}"'.format(self.fieldname, self.oldvalue, self.newvalue, **colours)
 
-        if self.related:
-            for chg in self.related:
-                if not outer and chg.fieldname in ['PE', 'PV', 'PR']:
-                    continue
-                for line in chg._str_internal(False).splitlines():
-                    out += '\n  * %s' % line
-
         return '%s%s' % (prefix, out) if out else ''
 
 class FileChange:
@@ -424,9 +413,13 @@
                     (depvera, depverb) = compare_pkg_lists(astr, bstr)
                     if depvera == depverb:
                         continue
-                alist = astr.split()
+                if key == 'FILELIST':
+                    alist = shlex.split(astr)
+                    blist = shlex.split(bstr)
+                else:
+                    alist = astr.split()
+                    blist = bstr.split()
                 alist.sort()
-                blist = bstr.split()
                 blist.sort()
                 # We don't care about the removal of self-dependencies
                 if pkgname in alist and not pkgname in blist:
@@ -635,17 +628,6 @@
                 chg = ChangeRecord(path, filename[7:], d.a_blob.data_stream.read().decode('utf-8'), '', True)
                 changes.append(chg)
 
-    # Link related changes
-    for chg in changes:
-        if chg.monitored:
-            for chg2 in changes:
-                # (Check dirname in the case of fields from recipe info files)
-                if chg.path == chg2.path or os.path.dirname(chg.path) == chg2.path:
-                    if chg2.fieldname in related_fields.get(chg.fieldname, []):
-                        chg.related.append(chg2)
-                    elif chg.path == chg2.path and chg.path.startswith('packages/') and chg2.fieldname in ['PE', 'PV', 'PR']:
-                        chg.related.append(chg2)
-
     # filter out unwanted paths
     if exclude_path:
         for chg in changes:
diff --git a/poky/meta/lib/oe/copy_buildsystem.py b/poky/meta/lib/oe/copy_buildsystem.py
index 4b94806..7cb784c 100644
--- a/poky/meta/lib/oe/copy_buildsystem.py
+++ b/poky/meta/lib/oe/copy_buildsystem.py
@@ -1,5 +1,12 @@
 # This class should provide easy access to the different aspects of the
 # buildsystem such as layers, bitbake location, etc.
+#
+# SDK_LAYERS_EXCLUDE: Layers which will be excluded from SDK layers.
+# SDK_LAYERS_EXCLUDE_PATTERN: The simiar to SDK_LAYERS_EXCLUDE, this supports
+#                             python regular expression, use space as separator,
+#                              e.g.: ".*-downloads closed-.*"
+#
+
 import stat
 import shutil
 
@@ -23,9 +30,12 @@
         self.context = context
         self.layerdirs = [os.path.abspath(pth) for pth in d.getVar('BBLAYERS').split()]
         self.layers_exclude = (d.getVar('SDK_LAYERS_EXCLUDE') or "").split()
+        self.layers_exclude_pattern = d.getVar('SDK_LAYERS_EXCLUDE_PATTERN')
 
     def copy_bitbake_and_layers(self, destdir, workspace_name=None):
+        import re
         # Copy in all metadata layers + bitbake (as repositories)
+        copied_corebase = None
         layers_copied = []
         bb.utils.mkdirhier(destdir)
         layers = list(self.layerdirs)
@@ -40,8 +50,17 @@
         # Exclude layers
         for layer_exclude in self.layers_exclude:
             if layer_exclude in layers:
+                bb.note('Excluded %s from sdk layers since it is in SDK_LAYERS_EXCLUDE' % layer_exclude)
                 layers.remove(layer_exclude)
 
+        if self.layers_exclude_pattern:
+            layers_cp = layers[:]
+            for pattern in self.layers_exclude_pattern.split():
+                for layer in layers_cp:
+                    if re.match(pattern, layer):
+                        bb.note('Excluded %s from sdk layers since matched SDK_LAYERS_EXCLUDE_PATTERN' % layer)
+                        layers.remove(layer)
+
         workspace_newname = workspace_name
         if workspace_newname:
             layernames = [os.path.basename(layer) for layer in layers]
@@ -84,17 +103,18 @@
 
             layer_relative = os.path.relpath(layerdestpath,
                                              destdir)
-            layers_copied.append(layer_relative)
-
             # Treat corebase as special since it typically will contain
             # build directories or other custom items.
             if corebase == layer:
+                copied_corebase = layer_relative
                 bb.utils.mkdirhier(layerdestpath)
                 for f in corebase_files:
                     f_basename = os.path.basename(f)
                     destname = os.path.join(layerdestpath, f_basename)
                     _smart_copy(f, destname)
             else:
+                layers_copied.append(layer_relative)
+
                 if os.path.exists(os.path.join(layerdestpath, 'conf/layer.conf')):
                     bb.note("Skipping layer %s, already handled" % layer)
                 else:
@@ -140,7 +160,7 @@
                 layers_copied.remove(layer)
                 break
 
-        return layers_copied
+        return copied_corebase, layers_copied
 
 def generate_locked_sigs(sigfile, d):
     bb.utils.mkdirhier(os.path.dirname(sigfile))
diff --git a/poky/meta/lib/oe/elf.py b/poky/meta/lib/oe/elf.py
new file mode 100644
index 0000000..0ed59ae
--- /dev/null
+++ b/poky/meta/lib/oe/elf.py
@@ -0,0 +1,128 @@
+def machine_dict(d):
+#           TARGET_OS  TARGET_ARCH   MACHINE, OSABI, ABIVERSION, Little Endian, 32bit?
+    machdata = {
+            "darwin9" : { 
+                        "arm" :       (40,     0,    0,          True,          32),
+                      },
+            "eabi" : {
+                        "arm" :       (40,     0,    0,          True,          32),
+                      },
+            "elf" : {
+                        "aarch64" :   (183,    0,    0,          True,          64),
+                        "aarch64_be" :(183,    0,    0,          False,         64),
+                        "i586" :      (3,      0,    0,          True,          32),
+                        "x86_64":     (62,     0,    0,          True,          64),
+                        "epiphany":   (4643,   0,    0,          True,          32),
+                        "lm32":       (138,    0,    0,          False,         32),
+                        "mips":       ( 8,     0,    0,          False,         32),
+                        "mipsel":     ( 8,     0,    0,          True,          32),
+                        "microblaze":  (189,   0,    0,          False,         32),
+                        "microblazeeb":(189,   0,    0,          False,         32),
+                        "microblazeel":(189,   0,    0,          True,          32),
+                        "powerpc":    (20,     0,    0,          False,         32),
+                        "riscv32":    (243,    0,    0,          True,          32),
+                        "riscv64":    (243,    0,    0,          True,          64),
+                      },
+            "linux" : { 
+                        "aarch64" :   (183,    0,    0,          True,          64),
+                        "aarch64_be" :(183,    0,    0,          False,         64),
+                        "arm" :       (40,    97,    0,          True,          32),
+                        "armeb":      (40,    97,    0,          False,         32),
+                        "powerpc":    (20,     0,    0,          False,         32),
+                        "powerpc64":  (21,     0,    0,          False,         64),
+                        "i386":       ( 3,     0,    0,          True,          32),
+                        "i486":       ( 3,     0,    0,          True,          32),
+                        "i586":       ( 3,     0,    0,          True,          32),
+                        "i686":       ( 3,     0,    0,          True,          32),
+                        "x86_64":     (62,     0,    0,          True,          64),
+                        "ia64":       (50,     0,    0,          True,          64),
+                        "alpha":      (36902,  0,    0,          True,          64),
+                        "hppa":       (15,     3,    0,          False,         32),
+                        "m68k":       ( 4,     0,    0,          False,         32),
+                        "mips":       ( 8,     0,    0,          False,         32),
+                        "mipsel":     ( 8,     0,    0,          True,          32),
+                        "mips64":     ( 8,     0,    0,          False,         64),
+                        "mips64el":   ( 8,     0,    0,          True,          64),
+                        "mipsisa32r6":   ( 8,  0,    0,          False,         32),
+                        "mipsisa32r6el": ( 8,  0,    0,          True,          32),
+                        "mipsisa64r6":   ( 8,  0,    0,          False,         64),
+                        "mipsisa64r6el": ( 8,  0,    0,          True,          64),
+                        "nios2":      (113,    0,    0,          True,          32),
+                        "riscv32":    (243,    0,    0,          True,          32),
+                        "riscv64":    (243,    0,    0,          True,          64),
+                        "s390":       (22,     0,    0,          False,         32),
+                        "sh4":        (42,     0,    0,          True,          32),
+                        "sparc":      ( 2,     0,    0,          False,         32),
+                        "microblaze":  (189,   0,    0,          False,         32),
+                        "microblazeeb":(189,   0,    0,          False,         32),
+                        "microblazeel":(189,   0,    0,          True,          32),
+                      },
+            "linux-musl" : { 
+                        "aarch64" :   (183,    0,    0,            True,          64),
+                        "aarch64_be" :(183,    0,    0,            False,         64),
+                        "arm" :       (  40,    97,    0,          True,          32),
+                        "armeb":      (  40,    97,    0,          False,         32),
+                        "powerpc":    (  20,     0,    0,          False,         32),
+                        "i386":       (   3,     0,    0,          True,          32),
+                        "i486":       (   3,     0,    0,          True,          32),
+                        "i586":       (   3,     0,    0,          True,          32),
+                        "i686":       (   3,     0,    0,          True,          32),
+                        "x86_64":     (  62,     0,    0,          True,          64),
+                        "mips":       (   8,     0,    0,          False,         32),
+                        "mipsel":     (   8,     0,    0,          True,          32),
+                        "mips64":     (   8,     0,    0,          False,         64),
+                        "mips64el":   (   8,     0,    0,          True,          64),
+                        "microblaze":  (189,     0,    0,          False,         32),
+                        "microblazeeb":(189,     0,    0,          False,         32),
+                        "microblazeel":(189,     0,    0,          True,          32),
+                        "riscv32":    (243,      0,    0,          True,          32),
+                        "riscv64":    (243,      0,    0,          True,          64),
+                        "sh4":        (  42,     0,    0,          True,          32),
+                      },
+            "uclinux-uclibc" : {
+                        "bfin":       ( 106,     0,    0,          True,         32),
+                      }, 
+            "linux-gnueabi" : {
+                        "arm" :       (40,     0,    0,          True,          32),
+                        "armeb" :     (40,     0,    0,          False,         32),
+                      },
+            "linux-musleabi" : {
+                        "arm" :       (40,     0,    0,          True,          32),
+                        "armeb" :     (40,     0,    0,          False,         32),
+                      },
+            "linux-gnuspe" : {
+                        "powerpc":    (20,     0,    0,          False,         32),
+                      },
+            "linux-muslspe" : {
+                        "powerpc":    (20,     0,    0,          False,         32),
+                      },
+            "linux-gnu" :       {
+                        "powerpc":    (20,     0,    0,          False,         32),
+                        "sh4":        (42,     0,    0,          True,          32),
+                      },
+            "linux-gnu_ilp32" :     {
+                        "aarch64" :   (183,    0,    0,          True,          32),
+                      },
+            "linux-gnux32" :       {
+                        "x86_64":     (62,     0,    0,          True,          32),
+                      },
+            "linux-muslx32" :       {
+                        "x86_64":     (62,     0,    0,          True,          32),
+                      },
+            "linux-gnun32" :       {
+                        "mips64":       ( 8,     0,    0,          False,         32),
+                        "mips64el":     ( 8,     0,    0,          True,          32),
+                        "mipsisa64r6":  ( 8,     0,    0,          False,         32),
+                        "mipsisa64r6el":( 8,     0,    0,          True,          32),
+                      },
+        }
+
+    # Add in any extra user supplied data which may come from a BSP layer, removing the
+    # need to always change this class directly
+    extra_machdata = (d and d.getVar("PACKAGEQA_EXTRA_MACHDEFFUNCS" or None) or "").split()
+    for m in extra_machdata:
+        call = m + "(machdata, d)"
+        locs = { "machdata" : machdata, "d" : d}
+        machdata = bb.utils.better_eval(call, locs)
+
+    return machdata
diff --git a/poky/meta/lib/oe/gpg_sign.py b/poky/meta/lib/oe/gpg_sign.py
index b172729..ccd5aee 100644
--- a/poky/meta/lib/oe/gpg_sign.py
+++ b/poky/meta/lib/oe/gpg_sign.py
@@ -3,6 +3,8 @@
 
 import bb
 import oe.utils
+import subprocess
+import shlex
 
 class LocalSigner(object):
     """Class for handling local (on the build host) signing"""
@@ -23,10 +25,7 @@
         if armor:
             cmd += "--armor "
         cmd += keyid
-        status, output = oe.utils.getstatusoutput(cmd)
-        if status:
-            raise bb.build.FuncFailed('Failed to export gpg public key (%s): %s' %
-                                      (keyid, output))
+        subprocess.check_output(shlex.split(cmd), stderr=subprocess.STDOUT)
 
     def sign_rpms(self, files, keyid, passphrase, digest, sign_chunk, fsk=None, fsk_password=None):
         """Sign RPM files"""
@@ -48,13 +47,10 @@
 
         # Sign in chunks
         for i in range(0, len(files), sign_chunk):
-            status, output = oe.utils.getstatusoutput(cmd + ' '.join(files[i:i+sign_chunk]))
-            if status:
-                raise bb.build.FuncFailed("Failed to sign RPM packages: %s" % output)
+            subprocess.check_output(shlex.split(cmd + ' '.join(files[i:i+sign_chunk])), stderr=subprocess.STDOUT)
 
     def detach_sign(self, input_file, keyid, passphrase_file, passphrase=None, armor=True):
         """Create a detached signature of a file"""
-        import subprocess
 
         if passphrase_file and passphrase:
             raise Exception("You should use either passphrase_file of passphrase, not both")
@@ -100,7 +96,6 @@
 
     def get_gpg_version(self):
         """Return the gpg version as a tuple of ints"""
-        import subprocess
         try:
             ver_str = subprocess.check_output((self.gpg_bin, "--version", "--no-permission-warning")).split()[2].decode("utf-8")
             return tuple([int(i) for i in ver_str.split("-")[0].split('.')])
@@ -114,7 +109,7 @@
         if self.gpg_path:
             cmd += "--homedir %s " % self.gpg_path
         cmd += sig_file
-        status, _ = oe.utils.getstatusoutput(cmd)
+        status = subprocess.call(shlex.split(cmd))
         ret = False if status else True
         return ret
 
diff --git a/poky/meta/lib/oe/maketype.py b/poky/meta/lib/oe/maketype.py
index f88981d..c36e7b5 100644
--- a/poky/meta/lib/oe/maketype.py
+++ b/poky/meta/lib/oe/maketype.py
@@ -7,7 +7,12 @@
 
 import inspect
 import oe.types as types
-import collections
+try:
+    # Python 3.7+
+    from collections.abc import Callable
+except ImportError:
+    # Python < 3.7
+    from collections import Callable
 
 available_types = {}
 
@@ -96,7 +101,7 @@
         continue
 
     obj = getattr(types, name)
-    if not isinstance(obj, collections.Callable):
+    if not isinstance(obj, Callable):
         continue
 
     register(name, obj)
diff --git a/poky/meta/lib/oe/package.py b/poky/meta/lib/oe/package.py
index 4f3e21a..efd36b3 100644
--- a/poky/meta/lib/oe/package.py
+++ b/poky/meta/lib/oe/package.py
@@ -1,15 +1,17 @@
+import stat
+import mmap
+import subprocess
+
 def runstrip(arg):
     # Function to strip a single file, called from split_and_strip_files below
     # A working 'file' (one which works on the target architecture)
     #
-    # The elftype is a bit pattern (explained in split_and_strip_files) to tell
+    # The elftype is a bit pattern (explained in is_elf below) to tell
     # us what type of file we're processing...
     # 4 - executable
     # 8 - shared library
     # 16 - kernel module
 
-    import stat, subprocess
-
     (file, elftype, strip) = arg
 
     newmode = None
@@ -19,11 +21,15 @@
         os.chmod(file, newmode)
 
     stripcmd = [strip]
-
+    skip_strip = False
     # kernel module    
     if elftype & 16:
-        stripcmd.extend(["--strip-debug", "--remove-section=.comment",
-            "--remove-section=.note", "--preserve-dates"])
+        if is_kernel_module_signed(file):
+            bb.debug(1, "Skip strip on signed module %s" % file)
+            skip_strip = True
+        else:
+            stripcmd.extend(["--strip-debug", "--remove-section=.comment",
+                "--remove-section=.note", "--preserve-dates"])
     # .so and shared library
     elif ".so" in file and elftype & 8:
         stripcmd.extend(["--remove-section=.comment", "--remove-section=.note", "--strip-unneeded"])
@@ -34,18 +40,59 @@
     stripcmd.append(file)
     bb.debug(1, "runstrip: %s" % stripcmd)
 
-    try:
+    if not skip_strip:
         output = subprocess.check_output(stripcmd, stderr=subprocess.STDOUT)
-    except subprocess.CalledProcessError as e:
-        bb.error("runstrip: '%s' strip command failed with %s (%s)" % (stripcmd, e.returncode, e.output))
 
     if newmode:
         os.chmod(file, origmode)
 
-    return
+# Detect .ko module by searching for "vermagic=" string
+def is_kernel_module(path):
+    with open(path) as f:
+        return mmap.mmap(f.fileno(), 0, prot=mmap.PROT_READ).find(b"vermagic=") >= 0
 
+# Detect if .ko module is signed
+def is_kernel_module_signed(path):
+    with open(path, "rb") as f:
+        f.seek(-28, 2)
+        module_tail = f.read()
+        return "Module signature appended" in "".join(chr(c) for c in bytearray(module_tail))
 
-def strip_execs(pn, dstdir, strip_cmd, libdir, base_libdir, qa_already_stripped=False):
+# Return type (bits):
+# 0 - not elf
+# 1 - ELF
+# 2 - stripped
+# 4 - executable
+# 8 - shared library
+# 16 - kernel module
+def is_elf(path):
+    exec_type = 0
+    result = subprocess.check_output(["file", "-b", path], stderr=subprocess.STDOUT).decode("utf-8")
+
+    if "ELF" in result:
+        exec_type |= 1
+        if "not stripped" not in result:
+            exec_type |= 2
+        if "executable" in result:
+            exec_type |= 4
+        if "shared" in result:
+            exec_type |= 8
+        if "relocatable" in result:
+            if path.endswith(".ko") and path.find("/lib/modules/") != -1 and is_kernel_module(path):
+                exec_type |= 16
+    return (path, exec_type)
+
+def is_static_lib(path):
+    if path.endswith('.a') and not os.path.islink(path):
+        with open(path, 'rb') as fh:
+            # The magic must include the first slash to avoid
+            # matching golang static libraries
+            magic = b'!<arch>\x0a/'
+            start = fh.read(len(magic))
+            return start == magic
+    return False
+
+def strip_execs(pn, dstdir, strip_cmd, libdir, base_libdir, d, qa_already_stripped=False):
     """
     Strip executable code (like executables, shared libraries) _in_place_
     - Based on sysroot_strip in staging.bbclass
@@ -56,39 +103,7 @@
     :param qa_already_stripped: Set to True if already-stripped' in ${INSANE_SKIP}
     This is for proper logging and messages only.
     """
-    import stat, errno, oe.path, oe.utils, mmap
-
-    # Detect .ko module by searching for "vermagic=" string
-    def is_kernel_module(path):
-        with open(path) as f:
-            return mmap.mmap(f.fileno(), 0, prot=mmap.PROT_READ).find(b"vermagic=") >= 0
-
-    # Return type (bits):
-    # 0 - not elf
-    # 1 - ELF
-    # 2 - stripped
-    # 4 - executable
-    # 8 - shared library
-    # 16 - kernel module
-    def is_elf(path):
-        exec_type = 0
-        ret, result = oe.utils.getstatusoutput("file -b '%s'" % path)
-
-        if ret:
-            bb.error("split_and_strip_files: 'file %s' failed" % path)
-            return exec_type
-
-        if "ELF" in result:
-            exec_type |= 1
-            if "not stripped" not in result:
-                exec_type |= 2
-            if "executable" in result:
-                exec_type |= 4
-            if "shared" in result:
-                exec_type |= 8
-            if "relocatable" in result and is_kernel_module(path):
-                exec_type |= 16
-        return exec_type
+    import stat, errno, oe.path, oe.utils
 
     elffiles = {}
     inodes = {}
@@ -98,6 +113,8 @@
     #
     # First lets figure out all of the files we may have to process
     #
+    checkelf = []
+    inodecache = {}
     for root, dirs, files in os.walk(dstdir):
         for f in files:
             file = os.path.join(root, f)
@@ -123,7 +140,11 @@
 
                 # It's a file (or hardlink), not a link
                 # ...but is it ELF, and is it already stripped?
-                elf_file = is_elf(file)
+                checkelf.append(file)
+                inodecache[file] = s.st_ino
+    results = oe.utils.multiprocess_launch(is_elf, checkelf, d)
+    for (file, elf_file) in results:
+                #elf_file = is_elf(file)
                 if elf_file & 1:
                     if elf_file & 2:
                         if qa_already_stripped:
@@ -132,13 +153,13 @@
                             bb.warn("File '%s' from %s was already stripped, this will prevent future debugging!" % (file[len(dstdir):], pn))
                         continue
 
-                    if s.st_ino in inodes:
+                    if inodecache[file] in inodes:
                         os.unlink(file)
-                        os.link(inodes[s.st_ino], file)
+                        os.link(inodes[inodecache[file]], file)
                     else:
                         # break hardlinks so that we do not strip the original.
-                        inodes[s.st_ino] = file
-                        bb.utils.copyfile(file, file)
+                        inodes[inodecache[file]] = file
+                        bb.utils.break_hardlinks(file)
                         elffiles[file] = elf_file
 
     #
@@ -149,8 +170,7 @@
         elf_file = int(elffiles[file])
         sfiles.append((file, elf_file, strip_cmd))
 
-    oe.utils.multiprocess_exec(sfiles, runstrip)
-
+    oe.utils.multiprocess_launch(runstrip, sfiles, d)
 
 
 def file_translate(file):
diff --git a/poky/meta/lib/oe/package_manager.py b/poky/meta/lib/oe/package_manager.py
index 2d8aeba..882e7c4 100644
--- a/poky/meta/lib/oe/package_manager.py
+++ b/poky/meta/lib/oe/package_manager.py
@@ -3,7 +3,6 @@
 import glob
 import subprocess
 import shutil
-import multiprocessing
 import re
 import collections
 import bb
@@ -13,6 +12,7 @@
 import string
 from oe.gpg_sign import get_signer
 import hashlib
+import fnmatch
 
 # this can be used by all PM backends to create the index files in parallel
 def create_index(arg):
@@ -84,12 +84,55 @@
 
     return output
 
-# Note: this should be bb.fatal in the future.
-def failed_postinsts_warn(pkgs, log_path):
-    bb.warn("""Intentionally failing postinstall scriptlets of %s to defer them to first boot is deprecated. Please place them into pkg_postinst_ontarget_${PN} ().
-If deferring to first boot wasn't the intent, then scriptlet failure may mean an issue in the recipe, or a regression elsewhere.
+def failed_postinsts_abort(pkgs, log_path):
+    bb.fatal("""Postinstall scriptlets of %s have failed. If the intention is to defer them to first boot,
+then please place them into pkg_postinst_ontarget_${PN} ().
+Deferring to first boot via 'exit 1' is no longer supported.
 Details of the failure are in %s.""" %(pkgs, log_path))
 
+def generate_locale_archive(d, rootfs, target_arch, localedir):
+    # Pretty sure we don't need this for locale archive generation but
+    # keeping it to be safe...
+    locale_arch_options = { \
+        "arm": ["--uint32-align=4", "--little-endian"],
+        "armeb": ["--uint32-align=4", "--big-endian"],
+        "aarch64": ["--uint32-align=4", "--little-endian"],
+        "aarch64_be": ["--uint32-align=4", "--big-endian"],
+        "sh4": ["--uint32-align=4", "--big-endian"],
+        "powerpc": ["--uint32-align=4", "--big-endian"],
+        "powerpc64": ["--uint32-align=4", "--big-endian"],
+        "mips": ["--uint32-align=4", "--big-endian"],
+        "mipsisa32r6": ["--uint32-align=4", "--big-endian"],
+        "mips64": ["--uint32-align=4", "--big-endian"],
+        "mipsisa64r6": ["--uint32-align=4", "--big-endian"],
+        "mipsel": ["--uint32-align=4", "--little-endian"],
+        "mipsisa32r6el": ["--uint32-align=4", "--little-endian"],
+        "mips64el": ["--uint32-align=4", "--little-endian"],
+        "mipsisa64r6el": ["--uint32-align=4", "--little-endian"],
+        "riscv64": ["--uint32-align=4", "--little-endian"],
+        "riscv32": ["--uint32-align=4", "--little-endian"],
+        "i586": ["--uint32-align=4", "--little-endian"],
+        "i686": ["--uint32-align=4", "--little-endian"],
+        "x86_64": ["--uint32-align=4", "--little-endian"]
+    }
+    if target_arch in locale_arch_options:
+        arch_options = locale_arch_options[target_arch]
+    else:
+        bb.error("locale_arch_options not found for target_arch=" + target_arch)
+        bb.fatal("unknown arch:" + target_arch + " for locale_arch_options")
+
+    # Need to set this so cross-localedef knows where the archive is
+    env = dict(os.environ)
+    env["LOCALEARCHIVE"] = oe.path.join(localedir, "locale-archive")
+
+    for name in os.listdir(localedir):
+        path = os.path.join(localedir, name)
+        if os.path.isdir(path):
+            cmd = ["cross-localedef", "--verbose"]
+            cmd += arch_options
+            cmd += ["--add-to-archive", path]
+            subprocess.check_output(cmd, env=env, stderr=subprocess.STDOUT)
+
 class Indexer(object, metaclass=ABCMeta):
     def __init__(self, d, deploy_dir):
         self.d = d
@@ -177,7 +220,7 @@
             bb.note("There are no packages in %s!" % self.deploy_dir)
             return
 
-        oe.utils.multiprocess_exec(index_cmds, create_index)
+        oe.utils.multiprocess_launch(create_index, index_cmds, self.d)
 
         if signer:
             feed_sig_type = self.d.getVar('PACKAGE_FEED_GPG_SIGNATURE_TYPE')
@@ -258,7 +301,7 @@
             bb.note("There are no packages in %s" % self.deploy_dir)
             return
 
-        oe.utils.multiprocess_exec(index_cmds, create_index)
+        oe.utils.multiprocess_launch(create_index, index_cmds, self.d)
         if self.d.getVar('PACKAGE_FEED_SIGN') == '1':
             raise NotImplementedError('Package feed signing not implementd for dpkg')
 
@@ -336,17 +379,24 @@
 
     def _initialize_intercepts(self):
         bb.note("Initializing intercept dir for %s" % self.target_rootfs)
-        postinst_intercepts_dir = self.d.getVar("POSTINST_INTERCEPTS_DIR")
-        if not postinst_intercepts_dir:
-            postinst_intercepts_dir = self.d.expand("${COREBASE}/scripts/postinst-intercepts")
         # As there might be more than one instance of PackageManager operating at the same time
         # we need to isolate the intercept_scripts directories from each other,
         # hence the ugly hash digest in dir name.
-        self.intercepts_dir = os.path.join(self.d.getVar('WORKDIR'),
-                                      "intercept_scripts-%s" %(hashlib.sha256(self.target_rootfs.encode()).hexdigest()) )
+        self.intercepts_dir = os.path.join(self.d.getVar('WORKDIR'), "intercept_scripts-%s" %
+                                           (hashlib.sha256(self.target_rootfs.encode()).hexdigest()))
 
+        postinst_intercepts = (self.d.getVar("POSTINST_INTERCEPTS") or "").split()
+        if not postinst_intercepts:
+            postinst_intercepts_path = self.d.getVar("POSTINST_INTERCEPTS_PATH")
+            if not postinst_intercepts_path:
+                postinst_intercepts_path = self.d.getVar("POSTINST_INTERCEPTS_DIR") or self.d.expand("${COREBASE}/scripts/postinst-intercepts")
+            postinst_intercepts = oe.path.which_wild('*', postinst_intercepts_path)
+
+        bb.debug(1, 'Collected intercepts:\n%s' % ''.join('  %s\n' % i for i in postinst_intercepts))
         bb.utils.remove(self.intercepts_dir, True)
-        shutil.copytree(postinst_intercepts_dir, self.intercepts_dir)
+        bb.utils.mkdirhier(self.intercepts_dir)
+        for intercept in postinst_intercepts:
+            bb.utils.copyfile(intercept, os.path.join(self.intercepts_dir, os.path.basename(intercept)))
 
     @abstractmethod
     def _handle_intercept_failure(self, failed_script):
@@ -370,7 +420,7 @@
                 self._handle_intercept_failure(registered_pkgs)
 
 
-    def run_intercepts(self):
+    def run_intercepts(self, populate_sdk=None):
         intercepts_dir = self.intercepts_dir
 
         bb.note("Running intercept scripts:")
@@ -382,7 +432,8 @@
             if script == "postinst_intercept" or not os.access(script_full, os.X_OK):
                 continue
 
-            if script == "delay_to_first_boot":
+            # we do not want to run any multilib variant of this
+            if script.startswith("delay_to_first_boot"):
                 self._postpone_to_first_boot(script_full)
                 continue
 
@@ -392,9 +443,22 @@
                 output = subprocess.check_output(script_full, stderr=subprocess.STDOUT)
                 if output: bb.note(output.decode("utf-8"))
             except subprocess.CalledProcessError as e:
-                bb.warn("The postinstall intercept hook '%s' failed, details in %s/log.do_%s" % (script, self.d.getVar('T'), self.d.getVar('BB_CURRENTTASK')))
                 bb.note("Exit code %d. Output:\n%s" % (e.returncode, e.output.decode("utf-8")))
-                self._postpone_to_first_boot(script_full)
+                if populate_sdk == 'host':
+                    bb.warn("The postinstall intercept hook '%s' failed, details in %s/log.do_%s" % (script, self.d.getVar('T'), self.d.getVar('BB_CURRENTTASK')))
+                elif populate_sdk == 'target':
+                    if "qemuwrapper: qemu usermode is not supported" in e.output.decode("utf-8"):
+                        bb.warn("The postinstall intercept hook '%s' could not be executed due to missing qemu usermode support, details in %s/log.do_%s"
+                                % (script, self.d.getVar('T'), self.d.getVar('BB_CURRENTTASK')))
+                    else:
+                        bb.fatal("The postinstall intercept hook '%s' failed, details in %s/log.do_%s" % (script, self.d.getVar('T'), self.d.getVar('BB_CURRENTTASK')))
+                else:
+                    if "qemuwrapper: qemu usermode is not supported" in e.output.decode("utf-8"):
+                        bb.note("The postinstall intercept hook '%s' could not be executed due to missing qemu usermode support, details in %s/log.do_%s"
+                                % (script, self.d.getVar('T'), self.d.getVar('BB_CURRENTTASK')))
+                        self._postpone_to_first_boot(script_full)
+                    else:
+                        bb.fatal("The postinstall intercept hook '%s' failed, details in %s/log.do_%s" % (script, self.d.getVar('T'), self.d.getVar('BB_CURRENTTASK')))
 
     @abstractmethod
     def update(self):
@@ -523,6 +587,13 @@
                          "'%s' returned %d:\n%s" %
                          (' '.join(cmd), e.returncode, e.output.decode("utf-8")))
 
+        target_arch = self.d.getVar('TARGET_ARCH')
+        localedir = oe.path.join(self.target_rootfs, self.d.getVar("libdir"), "locale")
+        if os.path.exists(localedir) and os.listdir(localedir):
+            generate_locale_archive(self.d, self.target_rootfs, target_arch, localedir)
+            # And now delete the binary locales
+            self.remove(fnmatch.filter(self.list_installed(), "glibc-binary-localedata-*"), False)
+
     def deploy_dir_lock(self):
         if self.deploy_dir is None:
             raise RuntimeError("deploy_dir is not set!")
@@ -559,7 +630,7 @@
             return res
         return _append(uris, base_paths)
 
-def create_packages_dir(d, rpm_repo_dir, deploydir, taskname, filterbydependencies):
+def create_packages_dir(d, subrepo_dir, deploydir, taskname, filterbydependencies):
     """
     Go through our do_package_write_X dependencies and hardlink the packages we depend
     upon into the repo directory. This prevents us seeing other packages that may
@@ -574,15 +645,13 @@
     seendirs = set()
     multilibs = {}
    
-    rpm_subrepo_dir = oe.path.join(rpm_repo_dir, "rpm")
-
-    bb.utils.remove(rpm_subrepo_dir, recurse=True)
-    bb.utils.mkdirhier(rpm_subrepo_dir)
+    bb.utils.remove(subrepo_dir, recurse=True)
+    bb.utils.mkdirhier(subrepo_dir)
 
     # Detect bitbake -b usage
     nodeps = d.getVar("BB_LIMITEDDEPS") or False
     if nodeps or not filterbydependencies:
-        oe.path.symlink(deploydir, rpm_subrepo_dir, True)
+        oe.path.symlink(deploydir, subrepo_dir, True)
         return
 
     start = None
@@ -593,24 +662,24 @@
             break
     if start is None:
         bb.fatal("Couldn't find ourself in BB_TASKDEPDATA?")
-    rpmdeps = set()
+    pkgdeps = set()
     start = [start]
     seen = set(start)
-    # Support direct dependencies (do_rootfs -> rpms)
-    # or indirect dependencies within PN (do_populate_sdk_ext -> do_rootfs -> rpms)
+    # Support direct dependencies (do_rootfs -> do_package_write_X)
+    # or indirect dependencies within PN (do_populate_sdk_ext -> do_rootfs -> do_package_write_X)
     while start:
         next = []
         for dep2 in start:
             for dep in taskdepdata[dep2][3]:
                 if taskdepdata[dep][0] != pn:
                     if "do_" + taskname in dep:
-                        rpmdeps.add(dep)
+                        pkgdeps.add(dep)
                 elif dep not in seen:
                     next.append(dep)
                     seen.add(dep)
         start = next
 
-    for dep in rpmdeps:
+    for dep in pkgdeps:
         c = taskdepdata[dep][0]
         manifest, d2 = oe.sstatesig.find_sstate_manifest(c, taskdepdata[dep][2], taskname, d, multilibs)
         if not manifest:
@@ -620,8 +689,12 @@
         with open(manifest, "r") as f:
             for l in f:
                 l = l.strip()
-                dest = l.replace(deploydir, "")
-                dest = rpm_subrepo_dir + dest
+                deploydir = os.path.normpath(deploydir)
+                if bb.data.inherits_class('packagefeed-stability', d):
+                    dest = l.replace(deploydir + "-prediff", "")
+                else:
+                    dest = l.replace(deploydir, "")
+                dest = subrepo_dir + dest
                 if l.endswith("/"):
                     if dest not in seendirs:
                         bb.utils.mkdirhier(dest)
@@ -663,12 +736,12 @@
             self.primary_arch = self.d.getVar('MACHINE_ARCH')
 
         self.rpm_repo_dir = oe.path.join(self.d.getVar('WORKDIR'), rpm_repo_workdir)
-        create_packages_dir(self.d, self.rpm_repo_dir, d.getVar("DEPLOY_DIR_RPM"), "package_write_rpm", filterbydependencies)
+        create_packages_dir(self.d, oe.path.join(self.rpm_repo_dir, "rpm"), d.getVar("DEPLOY_DIR_RPM"), "package_write_rpm", filterbydependencies)
 
         self.saved_packaging_data = self.d.expand('${T}/saved_packaging_data/%s' % self.task_name)
         if not os.path.exists(self.d.expand('${T}/saved_packaging_data')):
             bb.utils.mkdirhier(self.d.expand('${T}/saved_packaging_data'))
-        self.packaging_data_dirs = ['var/lib/rpm', 'var/lib/dnf', 'var/cache/dnf']
+        self.packaging_data_dirs = ['etc/rpm', 'etc/rpmrc', 'etc/dnf', 'var/lib/rpm', 'var/lib/dnf', 'var/cache/dnf']
         self.solution_manifest = self.d.expand('${T}/saved/%s_solution' %
                                                self.task_name)
         if not os.path.exists(self.d.expand('${T}/saved')):
@@ -697,7 +770,9 @@
         rpmrcconfdir = "%s/%s" %(self.target_rootfs, "etc/")
         bb.utils.mkdirhier(platformconfdir)
         open(platformconfdir + "platform", 'w').write("%s-pc-linux" % self.primary_arch)
-        open(rpmrcconfdir + "rpmrc", 'w').write("arch_compat: %s: %s\n" % (self.primary_arch, self.archs if len(self.archs) > 0 else self.primary_arch))
+        with open(rpmrcconfdir + "rpmrc", 'w') as f:
+            f.write("arch_compat: %s: %s\n" % (self.primary_arch, self.archs if len(self.archs) > 0 else self.primary_arch))
+            f.write("buildarch_compat: %s: noarch\n" % self.primary_arch)
 
         open(platformconfdir + "macros", 'w').write("%_transaction_color 7\n")
         if self.d.getVar('RPM_PREFER_ELF_ARCH'):
@@ -789,13 +864,12 @@
                 failed_scriptlets_pkgnames[line.split()[-1]] = True
 
         if len(failed_scriptlets_pkgnames) > 0:
-            failed_postinsts_warn(list(failed_scriptlets_pkgnames.keys()), self.d.expand("${T}/log.do_${BB_CURRENTTASK}"))
-        for pkg in failed_scriptlets_pkgnames.keys():
-            self.save_rpmpostinst(pkg)
+            failed_postinsts_abort(list(failed_scriptlets_pkgnames.keys()), self.d.expand("${T}/log.do_${BB_CURRENTTASK}"))
 
     def remove(self, pkgs, with_dependencies = True):
-        if len(pkgs) == 0:
+        if not pkgs:
             return
+
         self._prepare_pkg_transaction()
 
         if with_dependencies:
@@ -832,7 +906,10 @@
         for i in self.packaging_data_dirs:
             source_dir = oe.path.join(self.target_rootfs, i)
             target_dir = oe.path.join(self.saved_packaging_data, i)
-            shutil.copytree(source_dir, target_dir, symlinks=True)
+            if os.path.isdir(source_dir):
+                shutil.copytree(source_dir, target_dir, symlinks=True)
+            elif os.path.isfile(source_dir):
+                shutil.copy2(source_dir, target_dir)
 
     def recovery_packaging_data(self):
         # Move the rpmlib back
@@ -842,9 +919,10 @@
                 if os.path.exists(target_dir):
                     bb.utils.remove(target_dir, True)
                 source_dir = oe.path.join(self.saved_packaging_data, i)
-                shutil.copytree(source_dir,
-                            target_dir,
-                            symlinks=True)
+                if os.path.isdir(source_dir):
+                    shutil.copytree(source_dir, target_dir, symlinks=True)
+                elif os.path.isfile(source_dir):
+                    shutil.copy2(source_dir, target_dir)
 
     def list_installed(self):
         output = self._invoke_dnf(["repoquery", "--installed", "--queryformat", "Package: %{name} %{arch} %{version} %{name}-%{version}-%{release}.%{arch}.rpm\nDependencies:\n%{requires}\nRecommendations:\n%{recommends}\nDependenciesEndHere:\n"],
@@ -884,7 +962,7 @@
         os.environ['RPM_ETCCONFIGDIR'] = self.target_rootfs
 
         dnf_cmd = bb.utils.which(os.getenv('PATH'), "dnf")
-        standard_dnf_args = (["-v", "--rpmverbosity=debug"] if self.d.getVar('ROOTFS_RPM_DEBUG') else []) + ["-y",
+        standard_dnf_args = ["-v", "--rpmverbosity=debug", "-y",
                              "-c", oe.path.join(self.target_rootfs, "etc/dnf/dnf.conf"),
                              "--setopt=reposdir=%s" %(oe.path.join(self.target_rootfs, "etc/yum.repos.d")),
                              "--repofrompath=oe-repo,%s" % (self.rpm_repo_dir),
@@ -896,7 +974,7 @@
         try:
             output = subprocess.check_output(cmd,stderr=subprocess.STDOUT).decode("utf-8")
             if print_output:
-                bb.note(output)
+                bb.debug(1, output)
             return output
         except subprocess.CalledProcessError as e:
             if print_output:
@@ -1060,19 +1138,22 @@
         self.mark_packages("unpacked", registered_pkgs.split())
 
 class OpkgPM(OpkgDpkgPM):
-    def __init__(self, d, target_rootfs, config_file, archs, task_name='target'):
+    def __init__(self, d, target_rootfs, config_file, archs, task_name='target', ipk_repo_workdir="oe-rootfs-repo", filterbydependencies=True, prepare_index=True):
         super(OpkgPM, self).__init__(d, target_rootfs)
 
         self.config_file = config_file
         self.pkg_archs = archs
         self.task_name = task_name
 
-        self.deploy_dir = self.d.getVar("DEPLOY_DIR_IPK")
+        self.deploy_dir = oe.path.join(self.d.getVar('WORKDIR'), ipk_repo_workdir)
         self.deploy_lock_file = os.path.join(self.deploy_dir, "deploy.lock")
         self.opkg_cmd = bb.utils.which(os.getenv('PATH'), "opkg")
         self.opkg_args = "--volatile-cache -f %s -t %s -o %s " % (self.config_file, self.d.expand('${T}/ipktemp/') ,target_rootfs)
         self.opkg_args += self.d.getVar("OPKG_ARGS")
 
+        if prepare_index:
+            create_packages_dir(self.d, self.deploy_dir, d.getVar("DEPLOY_DIR_IPK"), "package_write_ipk", filterbydependencies)
+
         opkg_lib_dir = self.d.getVar('OPKGLIBDIR')
         if opkg_lib_dir[0] == "/":
             opkg_lib_dir = opkg_lib_dir[1:]
@@ -1245,7 +1326,11 @@
         if not pkgs:
             return
 
-        cmd = "%s %s install %s" % (self.opkg_cmd, self.opkg_args, ' '.join(pkgs))
+        cmd = "%s %s" % (self.opkg_cmd, self.opkg_args)
+        for exclude in (self.d.getVar("PACKAGE_EXCLUDE") or "").split():
+            cmd += " --add-exclude %s" % exclude
+        cmd += " install "
+        cmd += " ".join(pkgs)
 
         os.environ['D'] = self.target_rootfs
         os.environ['OFFLINE_ROOT'] = self.target_rootfs
@@ -1265,13 +1350,16 @@
                     bb.warn(line)
                     failed_pkgs.append(line.split(".")[0])
             if failed_pkgs:
-                failed_postinsts_warn(failed_pkgs, self.d.expand("${T}/log.do_${BB_CURRENTTASK}"))
+                failed_postinsts_abort(failed_pkgs, self.d.expand("${T}/log.do_${BB_CURRENTTASK}"))
         except subprocess.CalledProcessError as e:
             (bb.fatal, bb.warn)[attempt_only]("Unable to install packages. "
                                               "Command '%s' returned %d:\n%s" %
                                               (cmd, e.returncode, e.output.decode("utf-8")))
 
     def remove(self, pkgs, with_dependencies=True):
+        if not pkgs:
+            return
+
         if with_dependencies:
             cmd = "%s %s --force-remove --force-removal-of-dependent-packages remove %s" % \
                 (self.opkg_cmd, self.opkg_args, ' '.join(pkgs))
@@ -1437,9 +1525,12 @@
         return tmp_dir
 
 class DpkgPM(OpkgDpkgPM):
-    def __init__(self, d, target_rootfs, archs, base_archs, apt_conf_dir=None):
+    def __init__(self, d, target_rootfs, archs, base_archs, apt_conf_dir=None, deb_repo_workdir="oe-rootfs-repo", filterbydependencies=True):
         super(DpkgPM, self).__init__(d, target_rootfs)
-        self.deploy_dir = self.d.getVar('DEPLOY_DIR_DEB')
+        self.deploy_dir = oe.path.join(self.d.getVar('WORKDIR'), deb_repo_workdir)
+
+        create_packages_dir(self.d, self.deploy_dir, d.getVar("DEPLOY_DIR_DEB"), "package_write_deb", filterbydependencies)
+
         if apt_conf_dir is None:
             self.apt_conf_dir = self.d.expand("${APTCONF_TARGET}/apt")
         else:
@@ -1515,7 +1606,6 @@
         os.environ['INTERCEPT_DIR'] = self.intercepts_dir
         os.environ['NATIVE_ROOT'] = self.d.getVar('STAGING_DIR_NATIVE')
 
-        failed_pkgs = []
         for pkg_name in installed_pkgs:
             for control_script in control_scripts:
                 p_full = os.path.join(info_dir, pkg_name + control_script.suffix)
@@ -1530,12 +1620,7 @@
                         bb.warn("%s for package %s failed with %d:\n%s" %
                                 (control_script.name, pkg_name, e.returncode,
                                     e.output.decode("utf-8")))
-                        failed_postinsts_warn([pkg_name], self.d.expand("${T}/log.do_${BB_CURRENTTASK}"))
-                        failed_pkgs.append(pkg_name)
-                        break
-
-        if len(failed_pkgs):
-            self.mark_packages("unpacked", failed_pkgs)
+                        failed_postinsts_abort([pkg_name], self.d.expand("${T}/log.do_${BB_CURRENTTASK}"))
 
     def update(self):
         os.environ['APT_CONFIG'] = self.apt_conf_file
@@ -1585,6 +1670,9 @@
 
 
     def remove(self, pkgs, with_dependencies=True):
+        if not pkgs:
+            return
+
         if with_dependencies:
             os.environ['APT_CONFIG'] = self.apt_conf_file
             cmd = "%s purge %s" % (self.apt_get_cmd, ' '.join(pkgs))
diff --git a/poky/meta/lib/oe/patch.py b/poky/meta/lib/oe/patch.py
index af7aa52..e0f0604 100644
--- a/poky/meta/lib/oe/patch.py
+++ b/poky/meta/lib/oe/patch.py
@@ -21,6 +21,7 @@
 
 def runcmd(args, dir = None):
     import pipes
+    import subprocess
 
     if dir:
         olddir = os.path.abspath(os.curdir)
@@ -33,7 +34,7 @@
         args = [ pipes.quote(str(arg)) for arg in args ]
         cmd = " ".join(args)
         # print("cmd: %s" % cmd)
-        (exitstatus, output) = oe.utils.getstatusoutput(cmd)
+        (exitstatus, output) = subprocess.getstatusoutput(cmd)
         if exitstatus != 0:
             raise CmdError(cmd, exitstatus >> 8, output)
         if " fuzz " in output:
diff --git a/poky/meta/lib/oe/path.py b/poky/meta/lib/oe/path.py
index 76c58fa..1e24d05 100644
--- a/poky/meta/lib/oe/path.py
+++ b/poky/meta/lib/oe/path.py
@@ -86,7 +86,7 @@
     # This way we also preserve hardlinks between files in the tree.
 
     bb.utils.mkdirhier(dst)
-    cmd = "tar --xattrs --xattrs-include='*' -cf - -C %s -p . | tar --xattrs --xattrs-include='*' -xf - -C %s" % (src, dst)
+    cmd = "tar --xattrs --xattrs-include='*' -cf - -S -C %s -p . | tar --xattrs --xattrs-include='*' -xf - -C %s" % (src, dst)
     subprocess.check_output(cmd, shell=True, stderr=subprocess.STDOUT)
 
 def copyhardlinktree(src, dst):
@@ -98,7 +98,7 @@
     if (os.stat(src).st_dev ==  os.stat(dst).st_dev):
         # Need to copy directories only with tar first since cp will error if two 
         # writers try and create a directory at the same time
-        cmd = "cd %s; find . -type d -print | tar --xattrs --xattrs-include='*' -cf - -C %s -p --no-recursion --files-from - | tar --xattrs --xattrs-include='*' -xhf - -C %s" % (src, src, dst)
+        cmd = "cd %s; find . -type d -print | tar --xattrs --xattrs-include='*' -cf - -S -C %s -p --no-recursion --files-from - | tar --xattrs --xattrs-include='*' -xhf - -C %s" % (src, src, dst)
         subprocess.check_output(cmd, shell=True, stderr=subprocess.STDOUT)
         source = ''
         if os.path.isdir(src):
@@ -259,3 +259,37 @@
         if not path_abs.startswith(possible_parent_abs):
             return False
     return True
+
+def which_wild(pathname, path=None, mode=os.F_OK, *, reverse=False, candidates=False):
+    """Search a search path for pathname, supporting wildcards.
+
+    Return all paths in the specific search path matching the wildcard pattern
+    in pathname, returning only the first encountered for each file. If
+    candidates is True, information on all potential candidate paths are
+    included.
+    """
+    paths = (path or os.environ.get('PATH', os.defpath)).split(':')
+    if reverse:
+        paths.reverse()
+
+    seen, files = set(), []
+    for index, element in enumerate(paths):
+        if not os.path.isabs(element):
+            element = os.path.abspath(element)
+
+        candidate = os.path.join(element, pathname)
+        globbed = glob.glob(candidate)
+        if globbed:
+            for found_path in sorted(globbed):
+                if not os.access(found_path, mode):
+                    continue
+                rel = os.path.relpath(found_path, element)
+                if rel not in seen:
+                    seen.add(rel)
+                    if candidates:
+                        files.append((found_path, [os.path.join(p, rel) for p in paths[:index+1]]))
+                    else:
+                        files.append(found_path)
+
+    return files
+
diff --git a/poky/meta/lib/oe/qa.py b/poky/meta/lib/oe/qa.py
index 3231e60..59c72ce 100644
--- a/poky/meta/lib/oe/qa.py
+++ b/poky/meta/lib/oe/qa.py
@@ -158,7 +158,8 @@
             0x2A: "SuperH",
             0x32: "IA-64",
             0x3E: "x86-64",
-            0xB7: "AArch64"
+            0xB7: "AArch64",
+            0xF7: "BPF"
         }[machine]
     except:
         return "Unknown (%s)" % repr(machine)
diff --git a/poky/meta/lib/oe/rootfs.py b/poky/meta/lib/oe/rootfs.py
index c156607..e5512d0 100644
--- a/poky/meta/lib/oe/rootfs.py
+++ b/poky/meta/lib/oe/rootfs.py
@@ -144,6 +144,20 @@
         bb.note("  Install complementary '*-dbg' packages...")
         self.pm.install_complementary('*-dbg')
 
+        if self.d.getVar('PACKAGE_DEBUG_SPLIT_STYLE') == 'debug-with-srcpkg':
+            bb.note("  Install complementary '*-src' packages...")
+            self.pm.install_complementary('*-src')
+
+        """
+        Install additional debug packages. Possibility to install additional packages,
+        which are not automatically installed as complementary package of
+        standard one, e.g. debug package of static libraries.
+        """
+        extra_debug_pkgs = self.d.getVar('IMAGE_INSTALL_DEBUGFS')
+        if extra_debug_pkgs:
+            bb.note("  Install extra debug packages...")
+            self.pm.install(extra_debug_pkgs.split(), True)
+
         bb.note("  Rename debug rootfs...")
         try:
             shutil.rmtree(self.image_rootfs + '-dbg')
@@ -472,7 +486,8 @@
         self._log_check_error()
 
     def _cleanup(self):
-        self.pm._invoke_dnf(["clean", "all"])
+        if bb.utils.contains("IMAGE_FEATURES", "package-management", True, False, self.d):
+            self.pm._invoke_dnf(["clean", "all"])
 
 
 class DpkgOpkgRootfs(Rootfs):
@@ -560,6 +575,9 @@
         return pkg_list
 
     def _save_postinsts_common(self, dst_postinst_dir, src_postinst_dir):
+        if bb.utils.contains("IMAGE_FEATURES", "package-management",
+                         True, False, self.d):
+            return
         num = 0
         for p in self._get_delayed_postinsts():
             bb.utils.mkdirhier(dst_postinst_dir)
@@ -782,7 +800,7 @@
             ml_opkg_conf = os.path.join(ml_temp,
                                         variant + "-" + os.path.basename(self.opkg_conf))
 
-            ml_pm = OpkgPM(self.d, ml_target_rootfs, ml_opkg_conf, self.pkg_archs)
+            ml_pm = OpkgPM(self.d, ml_target_rootfs, ml_opkg_conf, self.pkg_archs, prepare_index=False)
 
             ml_pm.update()
             ml_pm.install(pkgs)
diff --git a/poky/meta/lib/oe/sdk.py b/poky/meta/lib/oe/sdk.py
index d6a5033..153b07d 100644
--- a/poky/meta/lib/oe/sdk.py
+++ b/poky/meta/lib/oe/sdk.py
@@ -7,52 +7,6 @@
 import glob
 import traceback
 
-def generate_locale_archive(d, rootfs):
-    # Pretty sure we don't need this for SDK archive generation but
-    # keeping it to be safe...
-    target_arch = d.getVar('SDK_ARCH')
-    locale_arch_options = { \
-        "arm": ["--uint32-align=4", "--little-endian"],
-        "armeb": ["--uint32-align=4", "--big-endian"],
-        "aarch64": ["--uint32-align=4", "--little-endian"],
-        "aarch64_be": ["--uint32-align=4", "--big-endian"],
-        "sh4": ["--uint32-align=4", "--big-endian"],
-        "powerpc": ["--uint32-align=4", "--big-endian"],
-        "powerpc64": ["--uint32-align=4", "--big-endian"],
-        "mips": ["--uint32-align=4", "--big-endian"],
-        "mipsisa32r6": ["--uint32-align=4", "--big-endian"],
-        "mips64": ["--uint32-align=4", "--big-endian"],
-        "mipsisa64r6": ["--uint32-align=4", "--big-endian"],
-        "mipsel": ["--uint32-align=4", "--little-endian"],
-        "mipsisa32r6el": ["--uint32-align=4", "--little-endian"],
-        "mips64el": ["--uint32-align=4", "--little-endian"],
-        "mipsisa64r6el": ["--uint32-align=4", "--little-endian"],
-        "i586": ["--uint32-align=4", "--little-endian"],
-        "i686": ["--uint32-align=4", "--little-endian"],
-        "x86_64": ["--uint32-align=4", "--little-endian"]
-    }
-    if target_arch in locale_arch_options:
-        arch_options = locale_arch_options[target_arch]
-    else:
-        bb.error("locale_arch_options not found for target_arch=" + target_arch)
-        bb.fatal("unknown arch:" + target_arch + " for locale_arch_options")
-
-    localedir = oe.path.join(rootfs, d.getVar("libdir_nativesdk"), "locale")
-    # Need to set this so cross-localedef knows where the archive is
-    env = dict(os.environ)
-    env["LOCALEARCHIVE"] = oe.path.join(localedir, "locale-archive")
-
-    for name in os.listdir(localedir):
-        path = os.path.join(localedir, name)
-        if os.path.isdir(path):
-            try:
-                cmd = ["cross-localedef", "--verbose"]
-                cmd += arch_options
-                cmd += ["--add-to-archive", path]
-                subprocess.check_output(cmd, env=env, stderr=subprocess.STDOUT)
-            except Exception as e:
-                bb.fatal("Cannot create locale archive: %s" % e.output)
-
 class Sdk(object, metaclass=ABCMeta):
     def __init__(self, d, manifest_dir):
         self.d = d
@@ -144,7 +98,10 @@
                 for lang in linguas.split():
                     pm.install("nativesdk-glibc-binary-localedata-%s.utf-8" % lang)
             # Generate a locale archive of them
-            generate_locale_archive(self.d, oe.path.join(self.sdk_host_sysroot, self.sdk_native_path))
+            target_arch = self.d.getVar('SDK_ARCH')
+            rootfs = oe.path.join(self.sdk_host_sysroot, self.sdk_native_path)
+            localedir = oe.path.join(rootfs, self.d.getVar("libdir_nativesdk"), "locale")
+            generate_locale_archive(self.d, rootfs, target_arch, localedir)
             # And now delete the binary locales
             pkgs = fnmatch.filter(pm.list_installed(), "nativesdk-glibc-binary-localedata-*.utf-8")
             pm.remove(pkgs)
@@ -209,7 +166,7 @@
 
         self.target_pm.install_complementary(self.d.getVar('SDKIMAGE_INSTALL_COMPLEMENTARY'))
 
-        self.target_pm.run_intercepts()
+        self.target_pm.run_intercepts(populate_sdk='target')
 
         execute_pre_post_process(self.d, self.d.getVar("POPULATE_SDK_POST_TARGET_COMMAND"))
 
@@ -220,7 +177,7 @@
         self._populate_sysroot(self.host_pm, self.host_manifest)
         self.install_locales(self.host_pm)
 
-        self.host_pm.run_intercepts()
+        self.host_pm.run_intercepts(populate_sdk='host')
 
         execute_pre_post_process(self.d, self.d.getVar("POPULATE_SDK_POST_HOST_COMMAND"))
 
@@ -270,11 +227,17 @@
         self.host_manifest = OpkgManifest(d, self.manifest_dir,
                                           Manifest.MANIFEST_TYPE_SDK_HOST)
 
+        ipk_repo_workdir = "oe-sdk-repo"
+        if "sdk_ext" in d.getVar("BB_RUNTASK"):
+            ipk_repo_workdir = "oe-sdk-ext-repo"
+
         self.target_pm = OpkgPM(d, self.sdk_target_sysroot, self.target_conf,
-                                self.d.getVar("ALL_MULTILIB_PACKAGE_ARCHS"))
+                                self.d.getVar("ALL_MULTILIB_PACKAGE_ARCHS"), 
+                                ipk_repo_workdir=ipk_repo_workdir)
 
         self.host_pm = OpkgPM(d, self.sdk_host_sysroot, self.host_conf,
-                              self.d.getVar("SDK_PACKAGE_ARCHS"))
+                              self.d.getVar("SDK_PACKAGE_ARCHS"),
+                                ipk_repo_workdir=ipk_repo_workdir)
 
     def _populate_sysroot(self, pm, manifest):
         pkgs_to_install = manifest.parse_initial_manifest()
@@ -297,7 +260,7 @@
 
         self.target_pm.install_complementary(self.d.getVar('SDKIMAGE_INSTALL_COMPLEMENTARY'))
 
-        self.target_pm.run_intercepts()
+        self.target_pm.run_intercepts(populate_sdk='target')
 
         execute_pre_post_process(self.d, self.d.getVar("POPULATE_SDK_POST_TARGET_COMMAND"))
 
@@ -308,7 +271,7 @@
         self._populate_sysroot(self.host_pm, self.host_manifest)
         self.install_locales(self.host_pm)
 
-        self.host_pm.run_intercepts()
+        self.host_pm.run_intercepts(populate_sdk='host')
 
         execute_pre_post_process(self.d, self.d.getVar("POPULATE_SDK_POST_HOST_COMMAND"))
 
@@ -350,15 +313,21 @@
         self.host_manifest = DpkgManifest(d, self.manifest_dir,
                                           Manifest.MANIFEST_TYPE_SDK_HOST)
 
+        deb_repo_workdir = "oe-sdk-repo"
+        if "sdk_ext" in d.getVar("BB_RUNTASK"):
+            deb_repo_workdir = "oe-sdk-ext-repo"
+
         self.target_pm = DpkgPM(d, self.sdk_target_sysroot,
                                 self.d.getVar("PACKAGE_ARCHS"),
                                 self.d.getVar("DPKG_ARCH"),
-                                self.target_conf_dir)
+                                self.target_conf_dir,
+                                deb_repo_workdir=deb_repo_workdir)
 
         self.host_pm = DpkgPM(d, self.sdk_host_sysroot,
                               self.d.getVar("SDK_PACKAGE_ARCHS"),
                               self.d.getVar("DEB_SDK_ARCH"),
-                              self.host_conf_dir)
+                              self.host_conf_dir,
+                              deb_repo_workdir=deb_repo_workdir)
 
     def _copy_apt_dir_to(self, dst_dir):
         staging_etcdir_native = self.d.getVar("STAGING_ETCDIR_NATIVE")
@@ -386,7 +355,7 @@
 
         self.target_pm.install_complementary(self.d.getVar('SDKIMAGE_INSTALL_COMPLEMENTARY'))
 
-        self.target_pm.run_intercepts()
+        self.target_pm.run_intercepts(populate_sdk='target')
 
         execute_pre_post_process(self.d, self.d.getVar("POPULATE_SDK_POST_TARGET_COMMAND"))
 
@@ -399,7 +368,7 @@
         self._populate_sysroot(self.host_pm, self.host_manifest)
         self.install_locales(self.host_pm)
 
-        self.host_pm.run_intercepts()
+        self.host_pm.run_intercepts(populate_sdk='host')
 
         execute_pre_post_process(self.d, self.d.getVar("POPULATE_SDK_POST_HOST_COMMAND"))
 
diff --git a/poky/meta/lib/oe/sstatesig.py b/poky/meta/lib/oe/sstatesig.py
index b82e0f4..18c5a35 100644
--- a/poky/meta/lib/oe/sstatesig.py
+++ b/poky/meta/lib/oe/sstatesig.py
@@ -45,7 +45,7 @@
 
     # allarch packagegroups are assumed to have well behaved names which don't change between architecures/tunes
     if isPackageGroup(fn) and isAllArch(fn) and not isNative(depname):
-        return False  
+        return False
 
     # Exclude well defined machine specific configurations which don't change ABI
     if depname in siggen.abisaferecipes and not isImage(fn):
@@ -150,16 +150,23 @@
         if recipename in self.unlockedrecipes:
             unlocked = True
         else:
+            def get_mc(tid):
+                tid = tid.rsplit('.', 1)[0]
+                if tid.startswith('multiconfig:'):
+                    elems = tid.split(':')
+                    return elems[1]
             def recipename_from_dep(dep):
                 # The dep entry will look something like
                 # /path/path/recipename.bb.task, virtual:native:/p/foo.bb.task,
                 # ...
+
                 fn = dep.rsplit('.', 1)[0]
                 return dataCache.pkg_fn[fn]
 
+            mc = get_mc(fn)
             # If any unlocked recipe is in the direct dependencies then the
             # current recipe should be unlocked as well.
-            depnames = [ recipename_from_dep(x) for x in deps ]
+            depnames = [ recipename_from_dep(x) for x in deps if mc == get_mc(x)]
             if any(x in y for y in depnames for x in self.unlockedrecipes):
                 self.unlockedrecipes[recipename] = ''
                 unlocked = True
@@ -372,8 +379,14 @@
 def find_sstate_manifest(taskdata, taskdata2, taskname, d, multilibcache):
     d2 = d
     variant = ''
+    curr_variant = ''
+    if d.getVar("BBEXTENDCURR") == "multilib":
+        curr_variant = d.getVar("BBEXTENDVARIANT")
+        if "virtclass-multilib" not in d.getVar("OVERRIDES"):
+            curr_variant = "invalid"
     if taskdata2.startswith("virtual:multilib"):
         variant = taskdata2.split(":")[2]
+    if curr_variant != variant:
         if variant not in multilibcache:
             multilibcache[variant] = oe.utils.get_multilib_datastore(variant, d)
         d2 = multilibcache[variant]
diff --git a/poky/meta/lib/oe/terminal.py b/poky/meta/lib/oe/terminal.py
index 94afe39..caeb5e3 100644
--- a/poky/meta/lib/oe/terminal.py
+++ b/poky/meta/lib/oe/terminal.py
@@ -112,7 +112,7 @@
             bb.event.fire(bb.event.LogExecTTY(msg, "screen -r %s" % s_id,
                                               0.5, 10), d)
         else:
-            logger.warn(msg)
+            logger.warning(msg)
 
 class TmuxRunning(Terminal):
     """Open a new pane in the current running tmux window"""
@@ -168,7 +168,7 @@
         if d:
             bb.event.fire(bb.event.LogExecTTY(msg, attach_cmd, 0.5, 10), d)
         else:
-            logger.warn(msg)
+            logger.warning(msg)
 
 class Custom(Terminal):
     command = 'false' # This is a placeholder
@@ -180,7 +180,7 @@
             if not '{command}' in self.command:
                 self.command += ' {command}'
             Terminal.__init__(self, sh_cmd, title, env, d)
-            logger.warn('Custom terminal was started.')
+            logger.warning('Custom terminal was started.')
         else:
             logger.debug(1, 'No custom terminal (OE_TERMINAL_CUSTOMCMD) set')
             raise UnsupportedTerminal('OE_TERMINAL_CUSTOMCMD not set')
diff --git a/poky/meta/lib/oe/types.py b/poky/meta/lib/oe/types.py
index 4ae58ac..f401713 100644
--- a/poky/meta/lib/oe/types.py
+++ b/poky/meta/lib/oe/types.py
@@ -103,8 +103,13 @@
     """OpenEmbedded 'boolean' type
 
     Valid values for true: 'yes', 'y', 'true', 't', '1'
-    Valid values for false: 'no', 'n', 'false', 'f', '0'
+    Valid values for false: 'no', 'n', 'false', 'f', '0', None
     """
+    if value is None:
+        return False
+
+    if isinstance(value, bool):
+        return value
 
     if not isinstance(value, str):
         raise TypeError("boolean accepts a string, not '%s'" % type(value))
diff --git a/poky/meta/lib/oe/utils.py b/poky/meta/lib/oe/utils.py
index 80f0442..8a584d6 100644
--- a/poky/meta/lib/oe/utils.py
+++ b/poky/meta/lib/oe/utils.py
@@ -1,4 +1,6 @@
 import subprocess
+import multiprocessing
+import traceback
 
 def read_file(filename):
     try:
@@ -23,6 +25,13 @@
     else:
         return falsevalue
 
+def vartrue(var, iftrue, iffalse, d):
+    import oe.types
+    if oe.types.boolean(d.getVar(var)):
+        return iftrue
+    else:
+        return iffalse
+
 def less_or_equal(variable, checkvalue, truevalue, falsevalue, d):
     if float(d.getVar(variable)) <= float(checkvalue):
         return truevalue
@@ -246,38 +255,73 @@
             bb.note("Executing %s ..." % cmd)
             bb.build.exec_func(cmd, d)
 
-def multiprocess_exec(commands, function):
-    import signal
-    import multiprocessing
+# For each item in items, call the function 'target' with item as the first 
+# argument, extraargs as the other arguments and handle any exceptions in the
+# parent thread
+def multiprocess_launch(target, items, d, extraargs=None):
 
-    if not commands:
-        return []
+    class ProcessLaunch(multiprocessing.Process):
+        def __init__(self, *args, **kwargs):
+            multiprocessing.Process.__init__(self, *args, **kwargs)
+            self._pconn, self._cconn = multiprocessing.Pipe()
+            self._exception = None
+            self._result = None
 
-    def init_worker():
-        signal.signal(signal.SIGINT, signal.SIG_IGN)
+        def run(self):
+            try:
+                ret = self._target(*self._args, **self._kwargs)
+                self._cconn.send((None, ret))
+            except Exception as e:
+                tb = traceback.format_exc()
+                self._cconn.send((e, tb))
 
-    fails = []
+        def update(self):
+            if self._pconn.poll():
+                (e, tb) = self._pconn.recv()
+                if e is not None:
+                    self._exception = (e, tb)
+                else:
+                    self._result = tb
 
-    def failures(res):
-        fails.append(res)
+        @property
+        def exception(self):
+            self.update()
+            return self._exception
 
-    nproc = min(multiprocessing.cpu_count(), len(commands))
-    pool = bb.utils.multiprocessingpool(nproc, init_worker)
+        @property
+        def result(self):
+            self.update()
+            return self._result
 
-    try:
-        mapresult = pool.map_async(function, commands, error_callback=failures)
-
-        pool.close()
-        pool.join()
-        results = mapresult.get()
-    except KeyboardInterrupt:
-        pool.terminate()
-        pool.join()
-        raise
-
-    if fails:
-        raise fails[0]
-
+    max_process = int(d.getVar("BB_NUMBER_THREADS") or os.cpu_count() or 1)
+    launched = []
+    errors = []
+    results = []
+    items = list(items)
+    while (items and not errors) or launched:
+        if not errors and items and len(launched) < max_process:
+            args = (items.pop(),)
+            if extraargs is not None:
+                args = args + extraargs
+            p = ProcessLaunch(target=target, args=args)
+            p.start()
+            launched.append(p)
+        for q in launched:
+            # The finished processes are joined when calling is_alive()
+            if not q.is_alive():
+                if q.exception:
+                    errors.append(q.exception)
+                if q.result:
+                    results.append(q.result)
+                launched.remove(q)
+    # Paranoia doesn't hurt
+    for p in launched:
+        p.join()
+    if errors:
+        msg = ""
+        for (e, tb) in errors:
+            msg = msg + str(e) + ": " + str(tb) + "\n"
+        bb.fatal("Fatal errors occurred in subprocesses:\n%s" % msg)
     return results
 
 def squashspaces(string):
@@ -304,11 +348,20 @@
         for pkg in sorted(pkg_dict):
             output.append(pkg)
 
-    return '\n'.join(output)
+    output_str = '\n'.join(output)
 
-def host_gcc_version(d):
+    if output_str:
+        # make sure last line is newline terminated
+        output_str += '\n'
+
+    return output_str
+
+def host_gcc_version(d, taskcontextonly=False):
     import re, subprocess
 
+    if taskcontextonly and d.getVar('BB_WORKERCONTEXT') != '1':
+        return
+
     compiler = d.getVar("BUILD_CC")
     try:
         env = os.environ.copy()
@@ -327,9 +380,18 @@
 
 def get_multilib_datastore(variant, d):
     localdata = bb.data.createCopy(d)
-    overrides = localdata.getVar("OVERRIDES", False) + ":virtclass-multilib-" + variant
-    localdata.setVar("OVERRIDES", overrides)
-    localdata.setVar("MLPREFIX", variant + "-")
+    if variant:
+        overrides = localdata.getVar("OVERRIDES", False) + ":virtclass-multilib-" + variant
+        localdata.setVar("OVERRIDES", overrides)
+        localdata.setVar("MLPREFIX", variant + "-")
+    else:
+        origdefault = localdata.getVar("DEFAULTTUNE_MULTILIB_ORIGINAL")
+        if origdefault:
+            localdata.setVar("DEFAULTTUNE", origdefault)
+        overrides = localdata.getVar("OVERRIDES", False).split(":")
+        overrides = ":".join([x for x in overrides if not x.startswith("virtclass-multilib-")])
+        localdata.setVar("OVERRIDES", overrides)
+        localdata.setVar("MLPREFIX", "")
     return localdata
 
 #
@@ -419,3 +481,4 @@
             msg = msg + ' (%s)' % self.description
 
         return msg
+
diff --git a/poky/meta/lib/oeqa/core/context.py b/poky/meta/lib/oeqa/core/context.py
index ef00845..821aec8 100644
--- a/poky/meta/lib/oeqa/core/context.py
+++ b/poky/meta/lib/oeqa/core/context.py
@@ -57,14 +57,21 @@
                 modules_required, filters)
         self.suites = self.loader.discover()
 
-    def runTests(self, skips=[]):
+    def runTests(self, processes=None, skips=[]):
         self.runner = self.runnerClass(self, descriptions=False, verbosity=2)
 
         # Dinamically skip those tests specified though arguments
         self.skipTests(skips)
 
         self._run_start_time = time.time()
-        result = self.runner.run(self.suites)
+        if processes:
+            from oeqa.core.utils.concurrencytest import ConcurrentTestSuite
+
+            concurrent_suite = ConcurrentTestSuite(self.suites, processes)
+            result = self.runner.run(concurrent_suite)
+        else:
+            self.runner.buffer = True
+            result = self.runner.run(self.suites)
         self._run_end_time = time.time()
 
         return result
diff --git a/poky/meta/lib/oeqa/core/decorator/data.py b/poky/meta/lib/oeqa/core/decorator/data.py
index 31c6dd6..f0f65ab 100644
--- a/poky/meta/lib/oeqa/core/decorator/data.py
+++ b/poky/meta/lib/oeqa/core/decorator/data.py
@@ -54,6 +54,20 @@
             self.case.skipTest(self.msg)
 
 @registerDecorator
+class skipIfInDataVar(OETestDecorator):
+    """
+        Skip test if value is in data store's variable.
+    """
+
+    attrs = ('var', 'value', 'msg')
+    def setUpDecorator(self):
+        msg = ('Checking if %r value contains %r to skip '
+              'the test' % (self.var, self.value))
+        self.logger.debug(msg)
+        if self.value in (self.case.td.get(self.var)):
+            self.case.skipTest(self.msg)
+
+@registerDecorator
 class skipIfNotInDataVar(OETestDecorator):
     """
         Skip test if value is not in data store's variable.
diff --git a/poky/meta/lib/oeqa/core/decorator/depends.py b/poky/meta/lib/oeqa/core/decorator/depends.py
index 69c604d..950dbaa 100644
--- a/poky/meta/lib/oeqa/core/decorator/depends.py
+++ b/poky/meta/lib/oeqa/core/decorator/depends.py
@@ -63,13 +63,15 @@
     return [cases[case_id] for case_id in cases_ordered]
 
 def _skipTestDependency(case, depends):
-    skipReasons = ['errors', 'failures', 'skipped']
-
-    for reason in skipReasons:
-        for test, _ in getattr(case.tc.results, reason):
-            if test.id() in depends:
-                raise SkipTest("Test case %s depends on %s and was in %s." \
-                        % (case.id(), test.id(), reason))
+    for dep in depends:
+        found = False
+        for test, _ in case.tc.results.successes:
+            if test.id() == dep:
+                found = True
+                break
+        if not found:
+            raise SkipTest("Test case %s depends on %s but it didn't pass/run." \
+                        % (case.id(), dep))
 
 @registerDecorator
 class OETestDepends(OETestDiscover):
diff --git a/poky/meta/lib/oeqa/core/loader.py b/poky/meta/lib/oeqa/core/loader.py
index 2255cf1..e66de32 100644
--- a/poky/meta/lib/oeqa/core/loader.py
+++ b/poky/meta/lib/oeqa/core/loader.py
@@ -44,6 +44,8 @@
         # Assumption: package and module names do not contain upper case
         # characters, whereas class names do
         m = re.match(r'^(\w+)(?:\.(\w[^.]*)(?:\.([^.]+))?)?$', module, flags=re.ASCII)
+        if not m:
+            continue
 
         module_name, class_name, test_name = m.groups()
 
diff --git a/poky/meta/lib/oeqa/core/runner.py b/poky/meta/lib/oeqa/core/runner.py
index f8bb23f..df88b85 100644
--- a/poky/meta/lib/oeqa/core/runner.py
+++ b/poky/meta/lib/oeqa/core/runner.py
@@ -36,6 +36,9 @@
         super(OETestResult, self).__init__(*args, **kwargs)
 
         self.successes = []
+        self.starttime = {}
+        self.endtime = {}
+        self.progressinfo = {}
 
         # Inject into tc so that TestDepends decorator can see results
         tc.results = self
@@ -43,13 +46,25 @@
         self.tc = tc
 
     def startTest(self, test):
-        # Allow us to trigger the testcase buffer mode on a per test basis
-        # so stdout/stderr are only printed upon failure. Enables debugging
-        # but clean output
-        if hasattr(test, "buffer"):
-            self.buffer = test.buffer
+        # May have been set by concurrencytest
+        if test.id() not in self.starttime:
+            self.starttime[test.id()] = time.time()
         super(OETestResult, self).startTest(test)
 
+    def stopTest(self, test):
+        self.endtime[test.id()] = time.time()
+        super(OETestResult, self).stopTest(test)
+        if test.id() in self.progressinfo:
+            self.tc.logger.info(self.progressinfo[test.id()])
+
+        # Print the errors/failures early to aid/speed debugging, its a pain
+        # to wait until selftest finishes to see them.
+        for t in ['failures', 'errors', 'skipped', 'expectedFailures']:
+            for (scase, msg) in getattr(self, t):
+                if test.id() == scase.id():
+                    self.tc.logger.info(str(msg))
+                    break
+
     def logSummary(self, component, context_msg=''):
         elapsed_time = self.tc._run_end_time - self.tc._run_start_time
         self.tc.logger.info("SUMMARY:")
@@ -78,13 +93,13 @@
 
                 # When fails at module or class level the class name is passed as string
                 # so figure out to see if match
-                m = re.search("^setUpModule \((?P<module_name>.*)\)$", scase_str)
+                m = re.search(r"^setUpModule \((?P<module_name>.*)\)$", scase_str)
                 if m:
                     if case.__class__.__module__ == m.group('module_name'):
                         found = True
                         break
 
-                m = re.search("^setUpClass \((?P<class_name>.*)\)$", scase_str)
+                m = re.search(r"^setUpClass \((?P<class_name>.*)\)$", scase_str)
                 if m:
                     class_name = "%s.%s" % (case.__class__.__module__,
                                             case.__class__.__name__)
@@ -122,9 +137,13 @@
                     if hasattr(d, 'oeid'):
                         oeid = d.oeid
 
+            t = ""
+            if case.id() in self.starttime and case.id() in self.endtime:
+                t = " (" + "{0:.2f}".format(self.endtime[case.id()] - self.starttime[case.id()]) + "s)"
+
             if status not in logs:
                 logs[status] = []
-            logs[status].append("RESULTS - %s - Testcase %s: %s" % (case.id(), oeid, status))
+            logs[status].append("RESULTS - %s - Testcase %s: %s%s" % (case.id(), oeid, status, t))
             if log:
                 result[case.id()] = {'status': status, 'log': log}
             else:
diff --git a/poky/meta/lib/oeqa/core/utils/concurrencytest.py b/poky/meta/lib/oeqa/core/utils/concurrencytest.py
new file mode 100644
index 0000000..f050289
--- /dev/null
+++ b/poky/meta/lib/oeqa/core/utils/concurrencytest.py
@@ -0,0 +1,259 @@
+#!/usr/bin/env python3
+#
+# Modified for use in OE by Richard Purdie, 2018
+#
+# Modified by: Corey Goldberg, 2013
+#   License: GPLv2+
+#
+# Original code from:
+#   Bazaar (bzrlib.tests.__init__.py, v2.6, copied Jun 01 2013)
+#   Copyright (C) 2005-2011 Canonical Ltd
+#   License: GPLv2+
+
+import os
+import sys
+import traceback
+import unittest
+import subprocess
+import testtools
+import threading
+import time
+import io
+
+from queue import Queue
+from itertools import cycle
+from subunit import ProtocolTestCase, TestProtocolClient
+from subunit.test_results import AutoTimingTestResultDecorator
+from testtools import ThreadsafeForwardingResult, iterate_tests
+
+import bb.utils
+import oe.path
+
+_all__ = [
+    'ConcurrentTestSuite',
+    'fork_for_tests',
+    'partition_tests',
+]
+
+#
+# Patch the version from testtools to allow access to _test_start and allow
+# computation of timing information and threading progress
+#
+class BBThreadsafeForwardingResult(ThreadsafeForwardingResult):
+
+    def __init__(self, target, semaphore, threadnum, totalinprocess, totaltests):
+        super(BBThreadsafeForwardingResult, self).__init__(target, semaphore)
+        self.threadnum = threadnum
+        self.totalinprocess = totalinprocess
+        self.totaltests = totaltests
+
+    def _add_result_with_semaphore(self, method, test, *args, **kwargs):
+        self.semaphore.acquire()
+        try:
+            self.result.starttime[test.id()] = self._test_start.timestamp()
+            self.result.threadprogress[self.threadnum].append(test.id())
+            totalprogress = sum(len(x) for x in self.result.threadprogress.values())
+            self.result.progressinfo[test.id()] = "%s: %s/%s %s/%s (%ss) (%s)" % (
+                    self.threadnum,
+                    len(self.result.threadprogress[self.threadnum]),
+                    self.totalinprocess,
+                    totalprogress,
+                    self.totaltests,
+                    "{0:.2f}".format(time.time()-self._test_start.timestamp()),
+                    test.id())
+        finally:
+            self.semaphore.release()
+        super(BBThreadsafeForwardingResult, self)._add_result_with_semaphore(method, test, *args, **kwargs)
+
+#
+# A dummy structure to add to io.StringIO so that the .buffer object
+# is available and accepts writes. This allows unittest with buffer=True
+# to interact ok with subunit which wants to access sys.stdout.buffer.
+#
+class dummybuf(object):
+   def __init__(self, parent):
+       self.p = parent
+   def write(self, data):
+       self.p.write(data.decode("utf-8"))
+
+#
+# Taken from testtools.ConncurrencyTestSuite but modified for OE use
+#
+class ConcurrentTestSuite(unittest.TestSuite):
+
+    def __init__(self, suite, processes):
+        super(ConcurrentTestSuite, self).__init__([suite])
+        self.processes = processes
+
+    def run(self, result):
+        tests, totaltests = fork_for_tests(self.processes, self)
+        try:
+            threads = {}
+            queue = Queue()
+            semaphore = threading.Semaphore(1)
+            result.threadprogress = {}
+            for i, (test, testnum) in enumerate(tests):
+                result.threadprogress[i] = []
+                process_result = BBThreadsafeForwardingResult(result, semaphore, i, testnum, totaltests)
+                # Force buffering of stdout/stderr so the console doesn't get corrupted by test output
+                # as per default in parent code
+                process_result.buffer = True
+                # We have to add a buffer object to stdout to keep subunit happy
+                process_result._stderr_buffer = io.StringIO()
+                process_result._stderr_buffer.buffer = dummybuf(process_result._stderr_buffer)
+                process_result._stdout_buffer = io.StringIO()
+                process_result._stdout_buffer.buffer = dummybuf(process_result._stdout_buffer)
+                reader_thread = threading.Thread(
+                    target=self._run_test, args=(test, process_result, queue))
+                threads[test] = reader_thread, process_result
+                reader_thread.start()
+            while threads:
+                finished_test = queue.get()
+                threads[finished_test][0].join()
+                del threads[finished_test]
+        except:
+            for thread, process_result in threads.values():
+                process_result.stop()
+            raise
+        finally:
+            for test in tests:
+                test[0]._stream.close()
+
+    def _run_test(self, test, process_result, queue):
+        try:
+            try:
+                test.run(process_result)
+            except Exception:
+                # The run logic itself failed
+                case = testtools.ErrorHolder(
+                    "broken-runner",
+                    error=sys.exc_info())
+                case.run(process_result)
+        finally:
+            queue.put(test)
+
+def removebuilddir(d):
+    delay = 5
+    while delay and os.path.exists(d + "/bitbake.lock"):
+        time.sleep(1)
+        delay = delay - 1
+    bb.utils.prunedir(d)
+
+def fork_for_tests(concurrency_num, suite):
+    result = []
+    test_blocks = partition_tests(suite, concurrency_num)
+    # Clear the tests from the original suite so it doesn't keep them alive
+    suite._tests[:] = []
+    totaltests = sum(len(x) for x in test_blocks)
+    for process_tests in test_blocks:
+        numtests = len(process_tests)
+        process_suite = unittest.TestSuite(process_tests)
+        # Also clear each split list so new suite has only reference
+        process_tests[:] = []
+        c2pread, c2pwrite = os.pipe()
+        # Clear buffers before fork to avoid duplicate output
+        sys.stdout.flush()
+        sys.stderr.flush()
+        pid = os.fork()
+        if pid == 0:
+            ourpid = os.getpid()
+            try:
+                newbuilddir = None
+                stream = os.fdopen(c2pwrite, 'wb', 1)
+                os.close(c2pread)
+
+                # Create a new separate BUILDDIR for each group of tests
+                if 'BUILDDIR' in os.environ:
+                    builddir = os.environ['BUILDDIR']
+                    newbuilddir = builddir + "-st-" + str(ourpid)
+                    selftestdir = os.path.abspath(builddir + "/../meta-selftest")
+                    newselftestdir = newbuilddir + "/meta-selftest"
+
+                    bb.utils.mkdirhier(newbuilddir)
+                    oe.path.copytree(builddir + "/conf", newbuilddir + "/conf")
+                    oe.path.copytree(builddir + "/cache", newbuilddir + "/cache")
+                    oe.path.copytree(selftestdir, newselftestdir)
+
+                    for e in os.environ:
+                        if builddir in os.environ[e]:
+                            os.environ[e] = os.environ[e].replace(builddir, newbuilddir)
+
+                    subprocess.check_output("git init; git add *; git commit -a -m 'initial'", cwd=newselftestdir, shell=True)
+
+                    # Tried to used bitbake-layers add/remove but it requires recipe parsing and hence is too slow
+                    subprocess.check_output("sed %s/conf/bblayers.conf -i -e 's#%s#%s#g'" % (newbuilddir, selftestdir, newselftestdir), cwd=newbuilddir, shell=True)
+
+                    os.chdir(newbuilddir)
+
+                    for t in process_suite:
+                        if not hasattr(t, "tc"):
+                            continue
+                        cp = t.tc.config_paths
+                        for p in cp:
+                            if selftestdir in cp[p] and newselftestdir not in cp[p]:
+                                cp[p] = cp[p].replace(selftestdir, newselftestdir)
+                            if builddir in cp[p] and newbuilddir not in cp[p]:
+                                cp[p] = cp[p].replace(builddir, newbuilddir)
+
+                # Leave stderr and stdout open so we can see test noise
+                # Close stdin so that the child goes away if it decides to
+                # read from stdin (otherwise its a roulette to see what
+                # child actually gets keystrokes for pdb etc).
+                newsi = os.open(os.devnull, os.O_RDWR)
+                os.dup2(newsi, sys.stdin.fileno())
+
+                subunit_client = TestProtocolClient(stream)
+                # Force buffering of stdout/stderr so the console doesn't get corrupted by test output
+                # as per default in parent code
+                subunit_client.buffer = True
+                subunit_result = AutoTimingTestResultDecorator(subunit_client)
+                process_suite.run(subunit_result)
+                if ourpid != os.getpid():
+                    os._exit(0)
+                if newbuilddir:
+                    removebuilddir(newbuilddir)
+            except:
+                # Don't do anything with process children
+                if ourpid != os.getpid():
+                    os._exit(1)
+                # Try and report traceback on stream, but exit with error
+                # even if stream couldn't be created or something else
+                # goes wrong.  The traceback is formatted to a string and
+                # written in one go to avoid interleaving lines from
+                # multiple failing children.
+                try:
+                    stream.write(traceback.format_exc().encode('utf-8'))
+                except:
+                    sys.stderr.write(traceback.format_exc())
+                finally:
+                    if newbuilddir:
+                        removebuilddir(newbuilddir)
+                    stream.flush()
+                    os._exit(1)
+            stream.flush()
+            os._exit(0)
+        else:
+            os.close(c2pwrite)
+            stream = os.fdopen(c2pread, 'rb', 1)
+            test = ProtocolTestCase(stream)
+            result.append((test, numtests))
+    return result, totaltests
+
+def partition_tests(suite, count):
+    # Keep tests from the same class together but allow tests from modules
+    # to go to different processes to aid parallelisation.
+    modules = {}
+    for test in iterate_tests(suite):
+        m = test.__module__ + "." + test.__class__.__name__
+        if m not in modules:
+            modules[m] = []
+        modules[m].append(test)
+
+    # Simply divide the test blocks between the available processes
+    partitions = [list() for _ in range(count)]
+    for partition, m in zip(cycle(partitions), modules):
+        partition.extend(modules[m])
+
+    # No point in empty threads so drop them
+    return [p for p in partitions if p]
+
diff --git a/poky/meta/lib/oeqa/files/test.pl b/poky/meta/lib/oeqa/files/test.pl
deleted file mode 100644
index 689c8f1..0000000
--- a/poky/meta/lib/oeqa/files/test.pl
+++ /dev/null
@@ -1,2 +0,0 @@
-$a = 9.01e+21 - 9.01e+21 + 0.01;
-print ("the value of a is ", $a, "\n");
diff --git a/poky/meta/lib/oeqa/files/test.py b/poky/meta/lib/oeqa/files/test.py
deleted file mode 100644
index f389225..0000000
--- a/poky/meta/lib/oeqa/files/test.py
+++ /dev/null
@@ -1,6 +0,0 @@
-import os
-
-os.system('touch /tmp/testfile.python')
-
-a = 9.01e+21 - 9.01e+21 + 0.01
-print("the value of a is %s" % a)
diff --git a/poky/meta/lib/oeqa/manual/abat.patch b/poky/meta/lib/oeqa/manual/abat.patch
new file mode 100644
index 0000000..1541ac8
--- /dev/null
+++ b/poky/meta/lib/oeqa/manual/abat.patch
@@ -0,0 +1,64 @@
+########
+diff --git a/glxgears_check.sh b/glxgears_check.sh
+index 17622b8..c4d3b97 100755
+--- a/glxgears_check.sh
++++ b/glxgears_check.sh
+@@ -31,7 +31,7 @@ else
+ 
+     sleep 6
+ 
+-    XPID=$( ps ax | awk '{print $1, $5}' | grep glxgears | awk '{print $1}')
++    XPID=$( ps | awk '{print $1, $5}' | grep glxgears | awk '{print $1}')
+     if [ ! -z "$XPID" ]; then
+         kill -9 $XPID >/dev/null 2>&1
+         echo "glxgears can run, PASS!"
+diff --git a/x_close.sh b/x_close.sh
+index e287be1..3429f1a 100755
+--- a/x_close.sh
++++ b/x_close.sh
+@@ -22,7 +22,7 @@
+ #
+ function close_proc(){
+ echo "kill process Xorg"
+-XPID=$(  ps ax | awk '{print $1, $5}' | egrep "X$|Xorg$" | awk '{print $1}')
++XPID=$(  ps | awk '{print $1, $6}' | egrep "X$|Xorg$" | awk '{print $1}')
+ if [ ! -z "$XPID" ]; then
+     kill $XPID
+     sleep 4
+diff --git a/x_start.sh b/x_start.sh
+index 9cf6eab..2305796 100755
+--- a/x_start.sh
++++ b/x_start.sh
+@@ -24,7 +24,7 @@
+ X_ERROR=0
+ 
+ #test whether X has started
+-PXID=$(ps ax |awk '{print $1,$5}' |egrep "Xorg$|X$" |grep -v grep | awk '{print $1}')
++PXID=$(ps |awk '{print $1,$6}' |egrep "Xorg$|X$" |grep -v grep | awk '{print $1}')
+ if [ ! -z "$PXID" ]; then
+     echo "[WARNING] Xorg has started!"
+     XORG_STATUS="started"
+@@ -35,9 +35,11 @@ else
+     #start up the x server
+     echo "Start up the X server for test in display $DISPLAY................"
+ 
+-    $XORG_DIR/bin/X >/dev/null 2>&1 &
++    #$XORG_DIR/bin/X >/dev/null 2>&1 &
++    #sleep 8
++    #xterm &
++    /etc/init.d/xserver-nodm start &
+     sleep 8
+-    xterm &
+ fi
+     XLOG_FILE=/var/log/Xorg.0.log
+     [ -f $XORG_DIR/var/log/Xorg.0.log ] && XLOG_FILE=$XORG_DIR/var/log/Xorg.0.log
+@@ -54,7 +56,7 @@ fi
+         X_ERROR=1
+     fi
+ 
+-    XPID=$( ps ax | awk '{print $1, $5}' | egrep "X$|Xorg$" |grep -v grep| awk '{print $1}')
++    XPID=$( ps | awk '{print $1, $6}' | egrep "X$|Xorg$" |grep -v grep| awk '{print $1}')
+     if [ -z "$XPID" ]; then
+         echo "Start up X server FAIL!"
+  echo
+########
\ No newline at end of file
diff --git a/poky/meta/lib/oeqa/manual/bsp-hw.json b/poky/meta/lib/oeqa/manual/bsp-hw.json
new file mode 100644
index 0000000..a2b1d3e
--- /dev/null
+++ b/poky/meta/lib/oeqa/manual/bsp-hw.json
@@ -0,0 +1,1200 @@
+[
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-tools.rpm_-__install_dependency_package",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Get a not previously installed RPM package or build one on local machine, which should have run-time dependency.For example, \"mc\" (Midnight Commander, which is a visual file manager) should depend on \"ncurses-terminfo\".   \n\n$ bitbake mc  \n\n\n",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Copy the package into a system folder (for example /home/root/rpm_packages).  \n\n\n",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Run \"rpm -ivh package_name\" and check the output, for example \"rpm -ivh mc.rpm*\" should report the dependency on \"ncurses-terminfo\".\n\n\n\n",
+                    "expected_results": "3 . rpm command should report message when some RPM installation depends on other packages."
+                }
+            },
+            "summary": "rpm_-__install_dependency_package"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.boot_and_install_from_USB",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "plugin usb which contains live image burned",
+                    "expected_results": "User can choose install system from usb stick onto harddisk from boot menu or command line option \n"
+                },
+                "2": {
+                    "action": "configure device BIOS to firstly boot from USB if necessary",
+                    "expected_results": "Installed system can boot up"
+                },
+                "3": {
+                    "action": "boot the device and select option \"Install\" from boot menu",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "proceed through default install process",
+                    "expected_results": ""
+                },
+                "5": {
+                    "action": "Remove USB, and reboot into new installed system. \nNote:   If installation was successfully completed and received this message \"\"(sdx): Volume was not properly unmounted...Please run fsck.\"\" ignore it because this was whitelisted according to bug 9652.",
+                    "expected_results": ""
+                }
+            },
+            "summary": "boot_and_install_from_USB"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.live_boot_from_USB",
+            "author": [
+                {
+                    "email": "juan.fernandox.ramos.frayle@intel.com",
+                    "name": "juan.fernandox.ramos.frayle@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Plugin usb which contains live image burned.",
+                    "expected_results": "User can choose boot from live image on usb stick from boot menu or command line option"
+                },
+                "2": {
+                    "action": "Configure device BIOS to firstly boot from USB if necessary.",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Reboot the device and boot from USB stick.",
+                    "expected_results": "Live image can boot up with usb stick"
+                }				
+            },
+            "summary": "live_boot_from_USB"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.boot_from_runlevel_3",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Boot into system and edit /etc/inittab to make sure that system enter at the run level 3 by default, this is done by changing the line   \n\n\nid:5:initdefault  \n\nto  \n\nid:3:initdefault  \n\n",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Reboot system, and press \"Tab\" to enter \"grub\"",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Get into the \"kernel\" line with the edit option  \"e\" and add \"psplash=false text\" at the end line.",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "Press \"F10\" or \"ctrl+x\" to boot system",
+                    "expected_results": ""
+                },
+                "5": {
+                    "action": "If system ask you for a login type \"root\"",
+                    "expected_results": "System should boot to run level 3, showing the command prompt."
+                }
+            },
+            "summary": "boot_from_runlevel_3"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.boot_from_runlevel_5",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Boot into system and edit /etc/inittab to make sure that system enter at the run level 5 by default, this is done by changing the line   \n\nid:3:initdefault  \n\nto  \n\nid:5:initdefault  \n\n",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Reboot system, and press \"Tab\" to enter \"grub\"",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Get into the \"kernel\" line with the edit option  \"e\" and add \"psplash=false text\" at the end line.",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "Press \"F10\" or \"ctrl+x\" to boot system \nNote: The test is only for sato image.",
+                    "expected_results": "System should boot to runlevel 5 ."
+                }
+            },
+            "summary": "boot_from_runlevel_5"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.shutdown_system",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "boot system",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "launch terminal and run \"shutdown -h now\" or \"poweroff\"",
+                    "expected_results": "System can be shutdown successfully . "
+                }
+            },
+            "summary": "shutdown_system"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.reboot_system",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "boot system",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "launch terminal and run \"reboot\"",
+                    "expected_results": "System can reboot successfully . "
+                }
+            },
+            "summary": "reboot_system"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.switch_among_multi_applications_and_desktop",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "launch several applications(like contacts, file manager, notes, etc)",
+                    "expected_results": "user could switch among multi applications and desktop"
+                },
+                "2": {
+                    "action": "launch terminal",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "switch among multi applications and desktop",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "close applications \nNote: The case is for sato image only. ",
+                    "expected_results": ""
+                }
+            },
+            "summary": "switch_among_multi_applications_and_desktop"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.USB_-_mount",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Boot system \n\n",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Plug USB stick, it should be mount in  /run/media/sd(x) If X-window system does not start and show USB device, then use the terminal to mount it, following the next steps: \na. Locate the usb stick (usually it is on /dev/sdb) \nb. Create a directory with \"mkdir stick\"  (so you will have such a path as: /home/root/stick). \nc. Run the command  \"mount  /dev/sdb  /home/root/stick\" to mount  USB device on it. \n\n",
+                    "expected_results": "USB device should be mounted in  /run/media/sd(x)  \nor in  /home/root/stick  \n\n"
+                },
+                "3": {
+                    "action": "Then you can access USB stick (/home/root/stick) via Terminal or GUI  and try various commands and actions like \"cp\", \"mv\", \"touch\" and \"rm\".  Type \"dmesg\" command and check for recent mounted devices.",
+                    "expected_results": "Basic commands work properly. The system sends a notification in \"dmesg\" command, showing that the USB stick is accessible and the device is mounted ."
+                }
+            },
+            "summary": "USB_-_mount"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.USB_-_read_files",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "boot system",
+                    "expected_results": "view/copy successfully"
+                },
+                "2": {
+                    "action": "plug usb stick",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "view files in usb by file browser",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "copy some files from usb to local hardware",
+                    "expected_results": ""
+                }
+            },
+            "summary": "USB_-_read_files"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.USB_-_umount",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "boot system",
+                    "expected_results": "usb directory in file browser automatically missed"
+                },
+                "2": {
+                    "action": "plug usb stick",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "view files in usb by file browser \n4.unplug usb",
+                    "expected_results": ""
+                }
+            },
+            "summary": "USB_-_umount"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.USB_-_write_files",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "boot system",
+                    "expected_results": "create/copy successfully"
+                },
+                "2": {
+                    "action": "plug usb stick",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "create files in usb \n4.copy some files from local hardware to usb",
+                    "expected_results": ""
+                }
+            },
+            "summary": "USB_-_write_files"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.ethernet_static_ip_set_in_connman",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Boot the system and check internet connection is on . ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Launch connmand-properties (up-right corner on desktop)",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Choose  Ethernet device and set a valid static ip address for it. \nFor example, in our internal network, we can set as following: \nip address: 10.239.48.xxx \nMask: 255.255.255.0 \nGateway (Broadcast): 10.239.48.255",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "Check the Network configuration with \"ifconfig\"",
+                    "expected_results": "Static IP was set successfully  \n"
+                },
+                "5": {
+                    "action": "ping to another IP adress",
+                    "expected_results": "Ping works correclty\n"
+                }
+            },
+            "summary": "ethernet_static_ip_set_in_connman"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.ethernet_get_IP_in_connman_via_DHCP",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Launch connmand-properties (up-right corner on your desktop). ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Check if Ethernet device can work properly with static IP, doing \"ping XXX.XXX.XXX.XXX\", once this is set.",
+                    "expected_results": "Ping executed successfully .  \n\n"
+                },
+                "3": {
+                    "action": "Then choose DHCP method for Ethernet device in connmand-properties.",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "Check with 'ifconfig\" and \"ping\" if Ethernet device get IP address via DHCP.",
+                    "expected_results": "Ethernet device can get dynamic IP address via DHCP in connmand ."
+                }
+            },
+            "summary": "ethernet_get_IP_in_connman_via_DHCP"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-tools.connman_offline_mode_in_connman-gnome",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Launch connman-properties after system booting \n\n",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "choose \"offline mode\" and check the connection of all network interfaces ",
+                    "expected_results": "All connection should be off after clicking \"offline mode\" . "
+                }
+            },
+            "summary": "connman_offline_mode_in_connman-gnome"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.X_server_can_start_up_with_runlevel_5_boot",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "boot up system with default runlevel  \n\n",
+                    "expected_results": "X server can start up well and desktop display has no problem .  \n\n"
+                },
+                "2": {
+                    "action": "type runlevel at command prompt",
+                    "expected_results": "Output:N 5"
+                }
+            },
+            "summary": "X_server_can_start_up_with_runlevel_5_boot"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.standby",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "boot system and launch terminal; check output of \"date\" and launch script \"continue.sh\"",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "echo \"mem\" > /sys/power/state",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "After system go into S3 mode, move mouse or press any key to make it resume (on NUC press power button)",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "Check \"date\" and script \"continue.sh\"",
+                    "expected_results": ""
+                },
+                "5": {
+                    "action": "Check if application can work as normal \ncontinue.sh as below: \n \n#!/bin/sh \n \ni=1 \nwhile [ 0 ] \ndo \n echo $i \n sleep 1 \n i=$((i+1)) \ndone ",
+                    "expected_results": "Screen should resume back and script can run continuously incrementing the i's value from where it was before going to standby state. Date should be the same with the corresponding time increment."
+                }
+            },
+            "summary": "standby"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.check_CPU_utilization_after_standby",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Start up system",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "run \"top\" command and check if there is any process eating CPU time",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "make system into standby and resume it",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "run \"top\" command and check if there is any difference with the data before standby",
+                    "expected_results": "There should be no big difference before/after standby with \"top\" . "
+                }
+            },
+            "summary": "check_CPU_utilization_after_standby"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.Test_if_LAN_device_works_well_after_resume_from_suspend_state",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "boot system and launch terminal",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "echo \"mem\" > /sys/power/state",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "After system go into S3 mode, move mouse or press any key to make it resume",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "check ping status  \n\nNote: This TC apply only for core-image-full-cmd and core-image-lsb .",
+                    "expected_results": "ping should always work before/after standby"
+                }
+            },
+            "summary": "Test_if_LAN_device_works_well_after_resume_from_suspend_state"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.Test_if_usb_hid_device_works_well_after_resume_from_suspend_state",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "boot system and launch terminal",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "echo \"mem\" > /sys/power/state",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "After system go into S3 mode, resume the device by pressing the power button or using HID devices",
+                    "expected_results": "Devices resumes "
+                },
+                "4": {
+                    "action": "check usb mouse and keyboard",
+                    "expected_results": "Usb mouse and keyboard should work"
+                }
+            },
+            "summary": "Test_if_usb_hid_device_works_well_after_resume_from_suspend_state"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-tools.click_terminal_icon_on_X_desktop",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "After system launch and X start up, click terminal icon on desktop",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Check if only one terminal window launched and no other problem met",
+                    "expected_results": "There should be no problem after launching terminal . "
+                }
+            },
+            "summary": "click_terminal_icon_on_X_desktop"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-tools.Add_multiple_files_in_media_player",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Launch media player",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Add multiple files(5 files) in media player at same time (ogg or wav)",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Verify the sound.",
+                    "expected_results": "Media player should be OK with this action, it reproduce files correctly."
+                }
+            },
+            "summary": "Add_multiple_files_in_media_player"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.check_bash_in_image",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "After system is up, check if bash command exists with command \"which bash\"",
+                    "expected_results": "bash command should exist in image giving something as below  \"/bin/bash\""
+                }
+            },
+            "summary": "check_bash_in_image"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.MicroSD_-__mount",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "boot system",
+                    "expected_results": "system notify that MicroSDis accessible"
+                },
+                "2": {
+                    "action": "plug MicroSD card",
+                    "expected_results": ""
+                }
+            },
+            "summary": "MicroSD_-__mount"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.MicroSD_-__read_files",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "boot system",
+                    "expected_results": "view/copy successfully"
+                },
+                "2": {
+                    "action": "plug MicroSD card",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "view files inMicroSD by file browser",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "copy some files fromMicroSD to local hardware",
+                    "expected_results": ""
+                }
+            },
+            "summary": "MicroSD_-__read_files"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.MicroSD_-__umount",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "boot system",
+                    "expected_results": "MicroSD in file browser automatically missed . "
+                },
+                "2": {
+                    "action": "plug MicroSD card",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "view files in MicroSDby file browser",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "unplug MicroSD",
+                    "expected_results": ""
+                }				
+            },
+            "summary": "MicroSD_-__umount"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.MicroSD_-__write_files",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "boot system",
+                    "expected_results": "create/copy successfully"
+                },
+                "2": {
+                    "action": "plug MicroSD card",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "create files in MicroSD",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "copy some files from local hardware to MicroSD",
+                    "expected_results": ""
+                }
+            },
+            "summary": "MicroSD_-__write_files"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-tools.video_-_libva_check_(ogg_video_play)",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "check if libva is installed on system (or libogg)",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "copy sample ogg file to system",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "launch media player can play the ogg file",
+                    "expected_results": "ogg file can be played without problem when libva is used (or libogg) "
+                }
+            },
+            "summary": "video_-_libva_check_(ogg_video_play)"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-tools.media_player_-_unable_to_play_MPEG-1_without_\"commercial\"_flag",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Copy sample MPEG-1 file to a system without the \"commercial\" flag.",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Launch media player and make sure it cannot play the MPEG-1 file.",
+                    "expected_results": "MPEG-1 file can not be played on images without the \"commercial\" flag. "
+                }
+            },
+            "summary": "media_player_-_unable_to_play_MPEG-1_without_\"commercial\"_flag"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-tools.media_player_-_play_video_(ogv)",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "copy sample ogv file to system",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "launch media player and make sure it can play the ogv file",
+                    "expected_results": "ogv file can be played without problem"
+                }
+            },
+            "summary": "media_player_-_play_video_(ogv)"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-tools.media_player_-_stop/play_button_(ogv)",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "copy sample ogv file to system",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "launch media player can play the ogv file",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "click \"stop\" button to stop playing",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "click \"start\" button to resume playing",
+                    "expected_results": "ogv file can be start/stop without problem"
+                }
+            },
+            "summary": "media_player_-_stop/play_button_(ogv)"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-tools.audio_-_play_(ogg)_with_HDMI",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "copy sample ogg file to system",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "connect system with a monitor with HDMI",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "launch media player and play the ogg file",
+                    "expected_results": "ogg file can be played without problem with HDMI"
+                }
+            },
+            "summary": "audio_-_play_(ogg)_with_HDMI"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-tools.audio_-_play_(wav)_with_HDMI",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "copy sample wav file to system",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "connect system with a monitor with HDMI",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "launch media player and play the wav file",
+                    "expected_results": "wav file can be played without problem, with HDMI"
+                }
+            },
+            "summary": "audio_-_play_(wav)_with_HDMI"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-tools.Graphics_-_ABAT",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Download ABAT test suite from internal git repository, git clone git://tinderbox.sh.intel.com/git/abat",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Apply following patch to make it work on yocto environment",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Run \"./abat.sh\" to run ABAT test refer to abat.patch",
+                    "expected_results": "All ABAT test should pass. \nNote : If below 3 fails appears ignore them. \n- start up X server fail.. due is already up \n- module [intel_agp] \n- module [i915]"
+                }
+            },
+            "summary": "Graphics_-_ABAT"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-tools.Graphics_-_x11perf_-_2D",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Run \"x11perf -aa10text\" and \"x11perf -rgb10text\"",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Get the FPS result and compare it with upstream graphics data on Sandybridge",
+                    "expected_results": "There should not be big regression between Yocto and upstream linux . "
+                }
+            },
+            "summary": "Graphics_-_x11perf_-_2D"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-oe-core.Test_Run_Integrity_-_Check_that_image_is_buildable",
+            "author": [
+                {
+                    "email": "corneliux.stoicescu@intel.com",
+                    "name": "corneliux.stoicescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Check that image can be built using either of the following methods:  \n\n",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Check that image is built by autobuilder \nPlease check at: https://autobuilder.yocto.io/pub/releases/ \nChoose the target release that you are validating.  \n\n",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Build image yourself \nPreferred to build an core-image-sato-dev to ease the process of the dependent test cases in this run. \nNote: Please set MACHINE in conf/local.conf ",
+                    "expected_results": "If either method fails, this test case will be failed and dependent test cases will be blocked. "
+                }
+            },
+            "summary": "Test_Run_Integrity_-_Check_that_image_is_buildable"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.Check_if_SATA_disk_can_work_correctly",
+            "author": [
+                {
+                    "email": "yi.zhao@windriver.com",
+                    "name": "yi.zhao@windriver.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Run fdisk command to create partition on SATA disk. ",
+                    "expected_results": "The SATA device can mount, umount, read and write. "
+                },
+                "2": {
+                    "action": "Mount/Umount \n  mke2fs /dev/sda1 \n  mount -t ext2 /dev/sda1 /mnt/disk  \n  umount /mnt/disk",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Read/Write (filesystem) \n  touch /mnt/disk/test.txt \n  echo abcd > /mnt/disk/test.txt \n  cat /mnt/disk/test.txt",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "Read/Write (raw) \n  dd if=/dev/sda1 of=/tmp/test bs=1k count=1k  \n  This command will read 1MB from /dev/sda1 to /tmp/test",
+                    "expected_results": ""
+                }
+            },
+            "summary": "Check_if_SATA_disk_can_work_correctly"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.Install_and_boot_from_USB-drive_to_HDD-drive",
+            "author": [
+                {
+                    "email": "david.israelx.rodriguez.castellanos@intel.com",
+                    "name": "david.israelx.rodriguez.castellanos@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Get a HDD drive.",
+                    "expected_results": "User can choose install system from USB stick on HDD drive from boot menu or command line option \n"
+                },
+                "2": {
+                    "action": "Plugin USB which contains live image burned (USB1).",
+                    "expected_results": "Installed system can boot up."
+                },
+                "3": {
+                    "action": "Configure device BIOS to firstly boot from USB if necessary",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "Boot the device and select option \"Install\"  from boot menu.",
+                    "expected_results": ""
+                },
+                "5": {
+                    "action": "Make sure that the divice in which image is going to be installed is the HDD drive.",
+                    "expected_results": ""
+                },
+                "6": {
+                    "action": "Proceed through default install process.",
+                    "expected_results": ""
+                },
+                "7": {
+                    "action": "Remove USB1, and reboot into new installed system.",
+                    "expected_results": ""
+                }
+            },
+            "summary": "Install_and_boot_from_USB-drive_to_HDD-drive"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.Install_and_boot_from_USB-drive_to_SD-drive",
+            "author": [
+                {
+                    "email": "david.israelx.rodriguez.castellanos@intel.com",
+                    "name": "david.israelx.rodriguez.castellanos@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Get a SD-drive with enough free space to install an image.",
+                    "expected_results": "User can choose install system from USB stick on SD-drive from boot menu or command line option. \n"
+                },
+                "2": {
+                    "action": "Plugin USB which contains live image burned (USB1).",
+                    "expected_results": "Installed system can boot up."
+                },
+                "3": {
+                    "action": "Configure device BIOS to firstly boot from USB if necessary",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "Boot the device and select option \"Install\"  from boot menu.",
+                    "expected_results": ""
+                },
+                "5": {
+                    "action": "Make sure that the device in which image is going to be installed is the SD-drive.",
+                    "expected_results": ""
+                },
+                "6": {
+                    "action": "Proceed through default install process.",
+                    "expected_results": ""
+                },
+                "7": {
+                    "action": "Remove USB1, and reboot into new installed system.",
+                    "expected_results": ""
+                }
+            },
+            "summary": "Install_and_boot_from_USB-drive_to_SD-drive"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.Test_boot_on_serial_communication_SD",
+            "author": [
+                {
+                    "email": "juan.fernandox.ramos.frayle@intel.com",
+                    "name": "juan.fernandox.ramos.frayle@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "1.- Create a yocto project image in a SD card \nexample \n2 - Configure a connection like shown in the link avobe: \nhttps://wiki.yoctoproject.org/wiki/MinnowMax_board_Serial_video_connection_guide \n3 - Verify the Minow Max board is connected to the host \n4 - Boot the system to desktop \n5 - Open a Terminal and check the IP  \nIn Terminal type $ifconfig\"",
+                    "expected_results": "Verify you can create a live image  \n"
+                }
+            },
+            "summary": "Test_boot_on_serial_communication_SD"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.Test_boot_on_serial_communication_HDD",
+            "author": [
+                {
+                    "email": "juan.fernandox.ramos.frayle@intel.com",
+                    "name": "juan.fernandox.ramos.frayle@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "1 - Create a yocto project image in a HDD \nexample \n2 - Configure a connection like shown in the link avobe: \nhttps://wiki.yoctoproject.org/wiki/MinnowMax_board_Serial_video_connection_guide \n3 - Verify the Minow Max board is connected to the host \n4 - Boot the system to desktop \n5 - Open a Terminal and check the IP  \nIn Terminal type $ifconfig\"> ",
+                    "expected_results": "Verify you can create a live image  \n"
+                }
+            },
+            "summary": "Test_boot_on_serial_communication_HDD"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.Test_boot_on_serial_communication_USB",
+            "author": [
+                {
+                    "email": "juan.fernandox.ramos.frayle@intel.com",
+                    "name": "juan.fernandox.ramos.frayle@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "1.- Create a yocto project image in a USB \nexample <dd if= core-image-sato-sdk.hddimg of =/dev/sdb>",
+                    "expected_results": "Verify you can create a live image  \n"
+                },
+                "2": {
+                    "action": "Configure a connection like shown in the link avobe: \nhttps://wiki.yoctoproject.org/wiki/MinnowMax_board_Serial_video_connection_guide\n\n",
+                    "expected_results": "Video signal is present and not delayed \n"
+                },
+                "3": {
+                    "action": " Verify the Minow Max board is connected to the host",
+                    "expected_results": "Verify the system boot ok and no errors are present \n"
+                },
+                "4": {
+                    "action": " Boot the system to desktop",
+                    "expected_results": " Check that a valid IP is retrieved"
+                },
+                "5": {
+                    "action": " Open a Terminal and check the IP  \nIn Terminal type $ifconfig\" ",
+                    "expected_results": ""
+                }
+            },
+            "summary": "Test_boot_on_serial_communication_USB"
+        }
+    },
+    {
+        "test": {
+            "@alias": "bsps-hw.bsps-runtime.Test_Seek_bar_and_volume_control",
+            "author": [
+                {
+                    "email": "juan.fernandox.ramos.frayle@intel.com",
+                    "name": "juan.fernandox.ramos.frayle@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Run media player and load a media file ",
+                    "expected_results": "Media player correctly open audio/video file \n"
+                },
+                "2": {
+                    "action": "Verify that seek and volume control are present ",
+                    "expected_results": "Seek bar and volume control are present \n"
+                },
+                "3": {
+                    "action": "Verify that selecting the speaker icon opens the volume control",
+                    "expected_results": "Volume control bar must appear \n"
+                },
+                "4": {
+                    "action": "Verify you can increase and decrease volume level with the volume control",
+                    "expected_results": "Volume level must be increased and decreased \n"
+                },
+                "5": {
+                    "action": "Observe that slider on the seek bar moves along with the video/audio play",
+                    "expected_results": "Video/audio file can be played and slider moves along with the video/audio play \n"
+                },
+                "6": {
+                    "action": "Verify you can navigate the video with the slider back and forward",
+                    "expected_results": "The slider can move back and forward in the seek bar \n"
+                },
+                "7": {
+                    "action": "Verify that seek and volume control are functional in full screen mode",
+                    "expected_results": "Press the full screen mode icon, seek bar and volume control must work fine \n"
+                },
+                "8": {
+                    "action": "Verify that pressing << or >> while playing a file makes the slide goes slow/backwards or faster",
+                    "expected_results": "Verify << and >> works correctly"
+                }
+            },
+            "summary": "Test_Seek_bar_and_volume_control"
+        }
+    }
+]
\ No newline at end of file
diff --git a/poky/meta/lib/oeqa/manual/bsp-qemu.json b/poky/meta/lib/oeqa/manual/bsp-qemu.json
new file mode 100644
index 0000000..1260af4
--- /dev/null
+++ b/poky/meta/lib/oeqa/manual/bsp-qemu.json
@@ -0,0 +1,222 @@
+[
+  {
+    "test": {
+      "@alias": "bsps-qemu.bsps-tools.qemu_can_be_started_with_KVM_enabled",
+      "author": [
+        {
+          "email": "alexandru.c.georgescu@intel.com",
+          "name": "alexandru.c.georgescu@intel.com"
+        }
+      ],
+      "execution": {
+        "1": {
+          "action": "Build a kernel with KVM enabled  \n\nIn Local.conf add  \n\nQEMU_USE_KVM = \"${@ 'intel-corei7-64 intel-core2-32 qemux86 qemux86-64' if os.access('/dev/kvm', os.R_OK|os.W_OK) else '' }\"  \n\n ",
+          "expected_results": ""
+        },
+        "2": {
+          "action": "Start qemu with option \"kvm\" with runqemu \n    a. If you start qemu with kvm failed, maybe it is because host not install kvm and vhost_net module. Follow below link to install them. \n    b. vhost_test refer:  https://wiki.yoctoproject.org/wiki/Running_an_x86_Yocto_Linux_image_under_QEMU_KVM \n    c. kvm refer: https://wiki.yoctoproject.org/wiki/How_to_enable_KVM_for_Poky_qemu",
+          "expected_results": ""
+        },
+        "3": {
+          "action": "Check if qemu starts up and if kvm_intel module is used",
+          "expected_results": ""
+        },
+        "4": {
+          "action": "If kvm_intel module is not used when starting qemu, it will show 0 in \"Used by\" column when you run \"lsmod | grep kvm_intel\" ",
+          "expected_results": "KVM enabled with qemu \nExecute \"lsmod | grep kvm_intel\" from your host twice, before and after you \nstart the qemu with kvm option. Before start, the number should be 0, \nafter start, the number should bigger than 0."
+        }
+      },
+      "summary": "qemu_can_be_started_with_KVM_enabled"
+    }
+  },
+  {
+    "test": {
+      "@alias": "bsps-qemu.bsps-tools.Post-installation_logging",
+      "author": [
+        {
+          "email": "yi.zhao@windriver.com",
+          "name": "yi.zhao@windriver.com"
+        }
+      ],
+      "execution": {
+        "1": {
+          "action": "Download the poky source and set environment \n",
+          "expected_results": "The /var/log/postinstall.log should exist in the first boot. The content of this log is like below:  \n\nRunning postinst /etc/rpm-postinsts/man... \nList directory to check the output log \nbin \nboot \ndev \netc \nhome \nlib \nlost+found \nmedia \nmnt \nproc \nrun \nsbin \nsys \ntmp \nusr \nvar \nList nonexist directory to check the stderr redirection log \nls: /nonexist: No such file or directory "
+        },
+        "2": {
+          "action": "Add the following lines to a .bb file. For expample, meta/recipes-connectivity/openssh/openssh_6.2p2.bb:   \n\npkg_postinst_ontarget_${PN} () {  \n       #!/bin/sh -e  \n       if [ x\"$D\" = \"x\" ]; then  \n       echo \"List directory to check the output log\"  \n       ls /  \n       echo \"List nonexist directory to check the stderr redirection log\"  \n       ls /nonexist  \n       else  \n       exit 1  \n       fi  \n}  \n\nMake sure the feature \"debug-tweaks\" is added in conf/local.conf \n",
+          "expected_results": ""
+        },
+        "3": {
+          "action": "Add ssh-server-openssh to EXTRA_IMAGE_FEATURES in local.conf \n",
+          "expected_results": ""
+        },
+        "4": {
+          "action": "Build core-image-minimal \n",
+          "expected_results": ""
+        },
+        "5": {
+          "action": "Boot up the image and check the /var/log/postinstall.log  ",
+          "expected_results": ""
+        }
+      },
+      "summary": "Post-installation_logging"
+    }
+  },
+  {
+    "test": {
+      "@alias": "bsps-qemu.bsps-tools.Add_user_with_cleartext_type_password_during_filesystem_construction",
+      "author": [
+        {
+          "email": "ke.zou@windriver.com",
+          "name": "ke.zou@windriver.com"
+        }
+      ],
+      "execution": {
+        "1": {
+          "action": "Download the poky source and set the environment  \n\n",
+          "expected_results": "No error during image building procedure. \n"
+        },
+        "2": {
+          "action": "Add the following lines in conf/local.conf  \n\nINHERIT += \"extrausers\"  \n\nEXTRA_USERS_PARAMS = \"\\ \nuseradd -s /bin/sh -P 'tester3' tester3;\\ \n\"  \n\nThe above settings do the following things: \na. Add a user tester3 with cleartext password 'tester3' ",
+          "expected_results": "Image can boot up \n"
+        },
+        "3": {
+          "action": "Build the image\n ",
+          "expected_results": "Login with user name \"tester3\" and password \"tester3\" "
+        }
+      },
+      "summary": "Add_user_with_cleartext_type_password_during_filesystem_construction"
+    }
+  },
+  {
+    "test": {
+      "@alias": "bsps-qemu.bsps-tools.rpm_-__install_dependency_package",
+      "author": [
+        {
+          "email": "alexandru.c.georgescu@intel.com",
+          "name": "alexandru.c.georgescu@intel.com"
+        }
+      ],
+      "execution": {
+        "1": {
+          "action": "Get a not previously installed RPM package or build one on local machine, which should have run-time dependency.For example, \"mc\" (Midnight Commander, which is a visual file manager) should depend on \"ncurses-terminfo\".   \n\n$ bitbake mc  \n\n\n",
+          "expected_results": ""
+        },
+        "2": {
+          "action": "Copy the package into a system folder (for example /home/root/rpm_packages).  \n\n\n",
+          "expected_results": ""
+        },
+        "3": {
+          "action": "Run \"rpm -ivh package_name\" and check the output, for example \"rpm -ivh mc.rpm*\" should report the dependency on \"ncurses-terminfo\".\n\n\n\n",
+          "expected_results": "3 . rpm command should report message when some RPM installation depends on other packages."
+        }
+      },
+      "summary": "rpm_-__install_dependency_package"
+    }
+  },
+  {
+    "test": {
+      "@alias": "bsps-qemu.bsps-tools.Check_rpm_install/removal_log_file_size(auto)",
+      "author": [
+        {
+          "email": "alexandru.c.georgescu@intel.com",
+          "name": "alexandru.c.georgescu@intel.com"
+        }
+      ],
+      "execution": {
+        "1": {
+          "action": "Get some rpm or other kind of installation packages.  \n\n",
+          "expected_results": "Steps 1- 4 (more than 2.3) \nEach file will occupy around 10MB, and there should be some method to keep rpm log in a small size. (the size of the db of RPMs must not be taking so much space)  \nStep 5 (less than or equal to 2.3)\nThe size on /var/lib/rpm/ must keep around 30MB"
+        },
+        "2": {
+          "action": "After system is up, check the size of log file named as \"log.xxxxxx\" on  /var/lib/rpm/log  \n\n",
+          "expected_results": ""
+        },
+        "3": {
+          "action": "After several install/removal of packages, with either of the install/removal commands   (rpm/smart/zypper/dnf install/removal), check again the size of log file.  \n\n",
+          "expected_results": ""
+        },
+        "4": {
+          "action": "For packages installation, there will be some database files under /var/lib/rpm/, named as \"__db.xxx\" and there will be some log files   \nunder /var/lib/rpm/log, named as \"\"log.xxxxxx\"\".   \n\nNote: You will only see the log.xxxx on /var/lib/rpm/log mentioned above if the poky version is minor than 2.3.For poky 2.3 or major versions this has been modified and the package RPM4 does not show the logs.xxxx. if major, follow the next step.  \n\n",
+          "expected_results": ""
+        },
+        "5": {
+          "action": "Repeat steps (1 and 3)  and check the size of /var/lib/rpm/  \n\nMore info: https://bugzilla.yoctoproject.org/show_bug.cgi?id=9259",
+          "expected_results": ""
+        }
+      },
+      "summary": "Check_rpm_install/removal_log_file_size"
+    }
+  },
+  {
+    "test": {
+      "@alias": "bsps-qemu.bsps-runtime.only_one_connmand_in_background(auto)",
+      "author": [
+        {
+          "email": "alexandru.c.georgescu@intel.com",
+          "name": "alexandru.c.georgescu@intel.com"
+        }
+      ],
+      "execution": {
+        "1": {
+          "action": "Boot system",
+          "expected_results": ""
+        },
+        "2": {
+          "action": "Run \"ps aux |grep connmand\" or \"ps -ef | grep connmand\" or \"ps | grep connmand\"",
+          "expected_results": "Connmand (connection manager, used to manage internet connections)  should be shown as an active process \n\n"
+        },
+        "3": {
+          "action": "Run command \"connmand\" to try to launch to a second connmand process",
+          "expected_results": ""
+        },
+        "4": {
+          "action": "Check, with \"ps\" connmand  if a second connmand can be generated ",
+          "expected_results": "There should be only one connmand process instance in background ."
+        }
+      },
+      "summary": "only_one_connmand_in_background"
+    }
+  },
+  {
+    "test": {
+      "@alias": "bsps-qemu.bsps-runtime.X_server_can_start_up_with_runlevel_5_boot",
+      "author": [
+        {
+          "email": "alexandru.c.georgescu@intel.com",
+          "name": "alexandru.c.georgescu@intel.com"
+        }
+      ],
+      "execution": {
+        "1": {
+          "action": "boot up system with default runlevel  \n\n",
+          "expected_results": "X server can start up well and desktop display has no problem .  \n\n"
+        },
+        "2": {
+          "action": "type runlevel at command prompt",
+          "expected_results": "Output:N 5"
+        }
+      },
+      "summary": "X_server_can_start_up_with_runlevel_5_boot"
+    }
+  },
+  {
+    "test": {
+      "@alias": "bsps-qemu.bsps-runtime.check_bash_in_image",
+      "author": [
+        {
+          "email": "alexandru.c.georgescu@intel.com",
+          "name": "alexandru.c.georgescu@intel.com"
+        }
+      ],
+      "execution": {
+        "1": {
+          "action": "After system is up, check if bash command exists with command \"which bash\"",
+          "expected_results": "bash command should exist in image giving something as below  \"/bin/bash\""
+        }
+      },
+      "summary": "check_bash_in_image"
+    }
+  }
+]
\ No newline at end of file
diff --git a/poky/meta/lib/oeqa/manual/build-appliance.json b/poky/meta/lib/oeqa/manual/build-appliance.json
new file mode 100644
index 0000000..b8f8927
--- /dev/null
+++ b/poky/meta/lib/oeqa/manual/build-appliance.json
@@ -0,0 +1,122 @@
+[
+    {
+        "test": {
+            "@alias": "build-appliance.build-appliance.Bitbake_build-appliance-image",
+            "author": [
+                {
+                    "email": "alexandru.c.georgescu@intel.com",
+                    "name": "alexandru.c.georgescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Get poky source code and prepare the build environment",
+                    "expected_results": "bitbake build-appliance-image is successful  "
+                },
+                "2": {
+                    "action": "Set MACHINE to qemux86 and add the following line to conf/local.conf :  SRCREV_pn-build-appliance-image = \"${AUTOREV}\"",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Run \"bitbake build-appliance-image\" \n \n",
+                    "expected_results": ""
+                }
+            },
+            "summary": "Bitbake_build-appliance-image"
+        }
+    },
+    {
+        "test": {
+            "@alias": "build-appliance.build-appliance.Build_core-image-minimal_with_build-appliance-image",
+            "author": [
+                {
+                    "email": "corneliux.stoicescu@intel.com",
+                    "name": "corneliux.stoicescu@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Build with AUTOREV or download from Autobuilder an image for Yocto Build Appliance.  ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Boot the image under VMWare Player.  ",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Build qemux86 core-image-minimal using bitbake command line in the build-appliance-image  ",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "Launch the image just built using runqemu.  ",
+                    "expected_results": "core-image-minimal should build and boot. "
+                }
+            },
+            "summary": "Build_core-image-minimal_with_build-appliance-image"
+        }
+    },
+    {
+        "test": {
+            "@alias": "build-appliance.build-appliance.Build_a_image_without_error_(added_recipe)",
+            "author": [
+                {
+                    "email": "sstncr@gmail.com",
+                    "name": "sstncr@gmail.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Launch Build Appliance",
+                    "expected_results": "User could build a image without error and the added package is in the image"
+                },
+                "2": {
+                    "action": "Set \"Machine\" in conf/local.conf, for example, qemuarm",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Install a new package to the image, for example, acpid. Set the following line in conf/local.conf: IMAGE_INSTALL_append = \" acpid\"",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "Build a image using bitbake command line, for example, bitbake core-image-minimal",
+                    "expected_results": ""
+                },
+                "5": {
+                    "action": "After build finished, launch the image and check if the added package built into image",
+                    "expected_results": ""
+                }
+            },
+            "summary": "Build_a_image_without_error_(added_recipe)."
+        }
+    },
+    {
+        "test": {
+            "@alias": "build-appliance.build-appliance.Create_core-image-sato-sdk_using_build_appliance",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Build with AUTOREV or download from Autobuilder an image for Yocto Build Appliance.  ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Boot the image under VMWare Player.  ",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Build qemux86 core-image-sato-sdk using bitbake command line in the build-appliance-image  ",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "Launch the image just built using runqemu. ",
+                    "expected_results": ""
+                }
+            },
+            "summary": "Create_core-image-sato-sdk_using_build_appliance"
+        }
+    }
+]
\ No newline at end of file
diff --git a/poky/meta/lib/oeqa/manual/crops.json b/poky/meta/lib/oeqa/manual/crops.json
new file mode 100644
index 0000000..1cf3c8f
--- /dev/null
+++ b/poky/meta/lib/oeqa/manual/crops.json
@@ -0,0 +1,294 @@
+[
+    {
+        "test": {
+            "@alias": "crops-default.crops-default.sdkext_eSDK_devtool_build_make",
+            "author": [
+                {
+                    "email": "francisco.j.pedraza.gonzalez@intel.com",
+                    "name": "francisco.j.pedraza.gonzalez@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "IMPORTANT NOTE: The firsts 5 steps refer to configuration of the environment to run the rest of the steps. These only apply for CROPS-eSDK.    \n\n\n\n",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": " Initiate your Crops-esdk environment as it says in wiki https://github.com/crops/docker-win-mac-docs/wiki   \n\n",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Create the following tree of files  <crops-esdk-workdir-workspace>/sdkext/files/myapp <crops-esdk-workdir-workspace>/sdkext/files/myapp_cmake   \n\n\n",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": " Create the following files withing the myapp directory  myapp.c and the Makefile. Write the following inside of each file: \n---------------------------------------- \nMakefile should contain  \n\nall: myapp  \n\nmyapp: myapp.o \n\t$(CC) $(LDFLAGS) $< -o $@  \n\nmyapp.o: myapp.c  \n\t$(CC) $(CFLAGS) -c $< -o $@ \n\nclean: \n\trm -rf myapp.o myapp  \n\n-----------------------------  \nmyapp.c  shold contain  \n\n\n#include <stdio.h>    \n\nint \nmain(int argc, char *argv[]) \n{ \n\tprintf(\"Hello world\\n\"); \n \n\treturn 0; \n} \n------------------------------------  \n\n",
+                    "expected_results": "be sure that the indentations on the makefile are tabs not spaces.  \n\n"
+                },
+                "5": {
+                    "action": " Create the following files within the myapp_cmake directory CMakeLists.txt and myapp.c. Write the following inside each file:  \n\n------------------------------------ \nCMakeLists.txt should contain:  \n\ncmake_minimum_required (VERSION 2.6) \nproject (myapp) \n# The version number. \nset (myapp_VERSION_MAJOR 1) \nset (myapp_VERSION_MINOR 0)  \n\n# add the executable \nadd_executable (myapp myapp.c)  \n\ninstall(TARGETS myapp \nRUNTIME DESTINATION bin)  \n\n------------------------------------------ \nmyapp.c should contain:  \n\n#include <stdio.h>     \n\nint  \nmain(int argc, char *argv[])  \n{ \n\tprintf(\"Hello world\\n\");  \n\n\treturn 0; \n} \n-------------------------------------------------  \n\n",
+                    "expected_results": "Be sure that the indentations on CMakeLists.txt is tabs not spaces."
+                },
+                "6": {
+                    "action": " source environment-setup-i586-poky-linux  \n\n",
+                    "expected_results": "This should output a message that says SDK environment now set up; additionally you may now run devtool to perform development tasks etc etc ...   \n\n"
+                },
+                "7": {
+                    "action": " run command which devtool  \n\n",
+                    "expected_results": "this should output the directory of the devtool script and it should be within the sdk workdir you are working in.  \n\n  "
+                },
+                "8": {
+                    "action": "devtool add myapp <directory>(this is myapp dir)    \n\n\n",
+                    "expected_results": "The directory you should input is the myapp directory. This should automatically create the recipe myapp.bb under <crops-esdk-workdir-workspace>/recipes/myapp/myapp.bb"
+                },
+                "9": {
+                    "action": " devtool build myapp  \n\n",
+                    "expected_results": "This should compile an image"
+                },
+                "10": {
+                    "action": " devtool reset myapp  ",
+                    "expected_results": "This cleans sysroot of the myapp recipe, but it leaves the source tree intact. meaning it does not erase."
+                }
+            },
+            "summary": "sdkext_eSDK_devtool_build_make"
+        }
+    },
+    {
+        "test": {
+            "@alias": "crops-default.crops-default.sdkext_devtool_build_esdk_package",
+            "author": [
+                {
+                    "email": "francisco.j.pedraza.gonzalez@intel.com",
+                    "name": "francisco.j.pedraza.gonzalez@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "IMPORTANT NOTE: The firsts 5 steps refer to configuration of the environment to run the rest of the steps. These only apply for CROPS-eSDK.    \n\n\n\n",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": " Initiate your Crops-esdk environment as it says in wiki https://github.com/crops/docker-win-mac-docs/wiki   \n\n",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": " Create the following tree of files    <crops-esdk-workdir-workspace>/sdkext/files/myapp/ \n <crops-esdk-workdir-workspace>/sdkext/files/myapp_cmake  \n\n",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": " Create the following files withing the myapp directory  myapp.c and the Makefile. Write the following inside of each file: \n---------------------------------------- \nMakefile should contain  \n\nall: myapp  \n\nmyapp: myapp.o \n\t$(CC) $(LDFLAGS) $< -o $@ \n\nmyapp.o: myapp.c  \n\t$(CC) $(CFLAGS) -c $< -o $@ \n\nclean: \n\trm -rf myapp.o myapp  \n\n-----------------------------  \nmyapp.c  shold contain  \n\n#include <stdio.h>   \n\nint \nmain(int argc, char *argv[]) \n{ \n\tprintf(\"Hello world\\n\"); \n \n\treturn 0; \n} \n------------------------------------  \n\n",
+                    "expected_results": "be sure that the indentations on the makefile are tabs not spaces.  \n\n"
+                },
+                "5": {
+                    "action": " Create the following files within the myapp_cmake directory CMakeLists.txt and myapp.c. Write the following inside each file:  \n\n------------------------------------ \nCMakeLists.txt should contain:  \n\ncmake_minimum_required (VERSION 2.6) \nproject (myapp) \n# The version number. \nset (myapp_VERSION_MAJOR 1) \nset (myapp_VERSION_MINOR 0)  \n\n# add the executable \nadd_executable (myapp myapp.c)  \n\ninstall(TARGETS myapp \nRUNTIME DESTINATION bin)  \n\n------------------------------------------ \nmyapp.c should contain:  \n\n#include<stdio.h>     \n\nint  \nmain(int argc, char *argv[])  \n{ \n\tprintf(\"Hello world\\n\");  \n\n\treturn 0; \n} \n-------------------------------------------------  \n\n",
+                    "expected_results": "Be sure that the indentations on CMakeLists.txt is tabs not spaces.  \n\n"
+                },
+                "6": {
+                    "action": " source environment-setup-i586-poky-linux  \n\n",
+                    "expected_results": "This should output a message that says SDK environment now set up; additionally you may now run devtool to perform development tasks etc etc ...  \n\n"
+                },
+                "7": {
+                    "action": " run command which devtool  \n\n",
+                    "expected_results": " this should output the directory of the devtool script and it should be within the sdk workdir you are working in.  \n\n"
+                },
+                "8": {
+                    "action": " devtool add myapp <directory>  (this is myapp dir)  \n\n",
+                    "expected_results": " The directory you should input is the myapp directory. This should automatically create the recipe myapp.bb under <crops-esdk-workdir-workspace>/recipes/myapp/myapp.bb  \n\n"
+                },
+                "9": {
+                    "action": " devtool package myapp  \n\n",
+                    "expected_results": " you should expect a package creation of myapp and it should be under the  /tmp/deploy/  \n\n"
+                },
+                "10": {
+                    "action": " devtool reset myapp  ",
+                    "expected_results": "This cleans sysroot of the myapp recipe, but it leaves the source tree intact. meaning it does not erase.\n</package_format>"
+                }
+            },
+            "summary": "sdkext_devtool_build_esdk_package"
+        }
+    },
+    {
+        "test": {
+            "@alias": "crops-default.crops-default.sdkext_devtool_build_cmake",
+            "author": [
+                {
+                    "email": "francisco.j.pedraza.gonzalez@intel.com",
+                    "name": "francisco.j.pedraza.gonzalez@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "IMPORTANT NOTE: The firsts 5 steps refer to configuration of the environment to run the rest of the steps. These only apply for CROPS-eSDK.    \n\n\n\n",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": " Initiate your Crops-esdk environment as it says in wiki https://github.com/crops/docker-win-mac-docs/wiki   \n\n",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": " Create the following tree of files    <crops-esdk-workdir-workspace>/sdkext/files/myapp \n <crops-esdk-workdir-workspace>/sdkext/files/myapp_cmake  \n\n",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": " Create the following files withing the myapp directory  myapp.c and the Makefile. Write the following inside of each file: \n---------------------------------------- \nMakefile should contain  \n\nall: myapp  \n\nmyapp: myapp.o \n\t$(CC) $(LDFLAGS) $< -o $@ \n\nmyapp.o: myapp.c  \n\t$(CC) $(CFLAGS) -c $< -o $@ \n\nclean: \n\trm -rf myapp.o myapp  \n\n-----------------------------  \nmyapp.c  shold contain  \n\n#include <stdio.h>   \n\nint \nmain(int argc, char *argv[]) \n{ \n\tprintf(\"Hello world\\n\"); \n \n\treturn 0; \n} \n------------------------------------  \n\n",
+                    "expected_results": "be sure that the indentations on the makefile are tabs not spaces.   \n\n"
+                },
+                "5": {
+                    "action": " Create the following files within the myapp_cmake directory CMakeLists.txt and myapp.c. Write the following inside each file:  \n\n------------------------------------ \nCMakeLists.txt should contain:  \n\ncmake_minimum_required (VERSION 2.6) \nproject (myapp) \n# The version number. \nset (myapp_VERSION_MAJOR 1) \nset (myapp_VERSION_MINOR 0)  \n\n# add the executable \nadd_executable (myapp myapp.c)  \n\ninstall(TARGETS myapp \nRUNTIME DESTINATION bin)  \n\n------------------------------------------ \nmyapp.c should contain:  \n\n#include    \n\nint  \nmain(int argc, char *argv[])  \n{ \n\tprintf(\"Hello world\\n\");  \n\n\treturn 0; \n} \n-------------------------------------------------  \n\n",
+                    "expected_results": "Be sure that the indentations on CMakeLists.txt is tabs not spaces.  \n\n"
+                },
+                "6": {
+                    "action": " source environment-setup-i586-poky-linux  \n\n",
+                    "expected_results": "This should output a message that says SDK environment now set up; additionally you may now run devtool to perform development tasks etc etc ...  \n\n"
+                },
+                "7": {
+                    "action": " run command which devtool  \n\n",
+                    "expected_results": "this should output the directory of the devtool script and it should be within the sdk workdir you are working in.  \n\n"
+                },
+                "8": {
+                    "action": " devtool add myapp <directory>   (this is myapp_cmake dir)  \n\n",
+                    "expected_results": "The directory you should input is the myapp_cmake directory. This should automatically create the recipe myapp.bb under <crops-esdk-workdir-workspace>/recipes/myapp/myapp.bb  \n\n"
+                },
+                "9": {
+                    "action": " devtool build myapp  \n\n",
+                    "expected_results": "This should compile an image  \n\n"
+                },
+                "10": {
+                    "action": " devtool reset myapp  ",
+                    "expected_results": "This cleans sysroot of the myapp recipe, but it leaves the source tree intact. meaning it does not erase.  "
+                }
+            },
+            "summary": "sdkext_devtool_build_cmake"
+        }
+    },
+    {
+        "test": {
+            "@alias": "crops-default.crops-default.sdkext_extend_autotools_recipe_creation",
+            "author": [
+                {
+                    "email": "francisco.j.pedraza.gonzalez@intel.com",
+                    "name": "francisco.j.pedraza.gonzalez@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "IMPORTANT NOTE: The firsts 2 steps refer to configuration of the environment to run the rest of the steps. These only apply for CROPS-eSDK.    \n\n\n\n",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Initiate your Crops-esdk environment as it says in wiki https://github.com/crops/docker-win-mac-docs/wiki   \n\n",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": " source environment-setup-i586-poky-linux  \n\n",
+                    "expected_results": " This should output a message that says SDK environment now set up; additionally you may now run devtool to perform development tasks etc etc ...   \n\n"
+                },
+                "4": {
+                    "action": "run command which devtool  \n\n",
+                    "expected_results": "this should output the directory of the devtool script and it should be within the sdk workdir you are working in.   \n\n"
+                },
+                "5": {
+                    "action": "devtool sdk-install -s libxml2  \n\n",
+                    "expected_results": "this should install libxml2   \n\n"
+                },
+                "6": {
+                    "action": "devtool add librdfa  https://github.com/rdfa/librdfa  \n\n",
+                    "expected_results": "This should automatically create the recipe librdfa.bb under /recipes/librdfa/librdfa.bb   \n\n"
+                },
+                "7": {
+                    "action": "devtool build librdfa  \n\n",
+                    "expected_results": "This should compile   \n\n"
+                },
+                "8": {
+                    "action": "devtool reset librdfa  ",
+                    "expected_results": "This cleans sysroot of the librdfa recipe, but it leaves the source tree intact. meaning it does not erase."
+                }
+            },
+            "summary": "sdkext_extend_autotools_recipe_creation"
+        }
+    },
+    {
+        "test": {
+            "@alias": "crops-default.crops-default.sdkext_devtool_kernelmodule",
+            "author": [
+                {
+                    "email": "francisco.j.pedraza.gonzalez@intel.com",
+                    "name": "francisco.j.pedraza.gonzalez@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "IMPORTANT NOTE: The firsts 2 steps refer to configuration of the environment to run the rest of the steps. These only apply for CROPS-eSDK.    \n\n\n",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": " Initiate your Crops-esdk environment as it says in wiki https://github.com/crops/docker-win-mac-docs/wiki   \n\n",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "source environment-setup-i586-poky-linux   \n\n",
+                    "expected_results": "This should output a message that says SDK environment now set up; additionally you may now run devtool to perform development tasks etc etc ...   \n \n"
+                },
+                "4": {
+                    "action": "run command which devtool  \n\n",
+                    "expected_results": "this should output the directory of the devtool script and it should be within the sdk workdir you are working in.   \n\n"
+                },
+                "5": {
+                    "action": "devtool add v4l2loopback-driver  https://github.com/umlaeute/v4l2loopback.git   \n\n",
+                    "expected_results": "This should automatically create the recipe v4l2loopback-driver.bb under <crops-esdk-workdir-workspace>/recipes/v4l2loopback-driver/v4l2loopback-driver.bb "
+                },
+                "6": {
+                    "action": "devtool build v4l2loopback-driver   \n\n",
+                    "expected_results": "This should compile an image   \n\n"
+                },
+                "7": {
+                    "action": "devtool reset v4l2loopback-driver   ",
+                    "expected_results": "This cleans sysroot of the v4l2loopback-driver recipe, but it leaves the source tree intact. meaning it does not erase."
+                }
+            },
+            "summary": "sdkext_devtool_kernelmodule"
+        }
+    },
+    {
+        "test": {
+            "@alias": "crops-default.crops-default.sdkext_recipes_for_nodejs",
+            "author": [
+                {
+                    "email": "francisco.j.pedraza.gonzalez@intel.com",
+                    "name": "francisco.j.pedraza.gonzalez@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "IMPORTANT NOTE: The firsts 2 steps refer to configuration of the environment to run the rest of the steps. These only apply for CROPS-eSDK.    \n\n\nlets say variable npm = npm://registry.npmjs.org;name=winston;version=2.2.0   \n\n",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Initiate your Crops-esdk environment as it says in wiki https://github.com/crops/docker-win-mac-docs/wiki   \n\n",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "source environment-setup-i586-poky-linux   \n\n",
+                    "expected_results": "This should output a message that says SDK environment now set up; additionally you may now run devtool to perform development tasks etc etc ...   \n\n"
+                },
+                "4": {
+                    "action": "run command which devtool   \n\n",
+                    "expected_results": "this should output the directory of the devtool script and it should be within the sdk workdir you are working in.  \n\n"
+                },
+                "5": {
+                    "action": " 4a) git clone git://git.openembedded.org/meta-openembedded in  layers/build  directory   \n \n4b) Add meta-openembedded/meta-oe in bblayer.conf as mentioned below: ${SDKBASEMETAPATH}/layers/build/meta-openembedded/meta-oe \\   \n\n4c) devtool add \"npm://registry.npmjs.org;name=npm;version=2.2.0\"   \n\n",
+                    "expected_results": " This should automatically create the recipe npm.bb under /recipes/npm/npm.bb  \n\n"
+                },
+                "6": {
+                    "action": "devtool build npm   \n\n",
+                    "expected_results": "This should compile an image  \n\n"
+                },
+                "7": {
+                    "action": " devtool reset npm",
+                    "expected_results": "This cleans sysroot of the npm recipe, but it leaves the source tree intact. meaning it does not erase."
+                }
+            },
+            "summary": "sdkext_recipes_for_nodejs"
+        }
+    }
+]
\ No newline at end of file
diff --git a/poky/meta/lib/oeqa/manual/eclipse-plugin.json b/poky/meta/lib/oeqa/manual/eclipse-plugin.json
new file mode 100644
index 0000000..9869150
--- /dev/null
+++ b/poky/meta/lib/oeqa/manual/eclipse-plugin.json
@@ -0,0 +1,322 @@
+[
+    {
+        "test": {
+            "@alias": "eclipse-plugin.eclipse-plugin.support_SSH_connection_to_Target",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "In Eclipse, swich to Remote System Explorer to create a connention baseed on SSH, input the remote target IP address as the Host name, make sure disable the proxy in Window->Preferences->General->Network Connection, set Direct as Active Provider field.  ",
+                    "expected_results": "the connection based on SSH could be set up."
+                },
+                "2": {
+                    "action": "Configure connection from Eclipse: Run->Run Configurations->C/C++ Remote Application\\ ->New Connection->General->SSH Only  ",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Then right click to connect, input the user ID and password.  ",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "expand the connection, it will show the Sftp Files etc.   \nNOTE. Might need to change dropbear to openssh and add the packagegroup-core-eclipse-debug recipe",
+                    "expected_results": ""
+                }
+            },
+            "summary": "support_SSH_connection_to_Target"
+        }
+    },
+    {
+        "test": {
+            "@alias": "eclipse-plugin.eclipse-plugin.Launch_QEMU_from_Eclipse",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Set the Yocto ADT's toolchain root location, sysroot location and kernel, in the menu Window -> Preferences -> Yocto ADT.   \n \n",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "wget  autobuilder.yoctoproject.org/pub/releases//machines/qemu/qemux86/qemu (ex:core-image-sato-sdk-qemux86-date-rootfs-tar-bz2) \nsource /opt/poky/version/environment-setup-i585-poky-linux  \n\nExtract qemu with runqemu-extract-sdk /home/user/file(ex.core-image-sato-sdk-qemux86.bz2) \n/home/user/qemux86-sato-sdk  \n\n",
+                    "expected_results": " Qemu can be lauched normally."
+                },
+                "3": {
+                    "action": "(a)Point to the Toolchain:  \n \nIf you are using a stand-alone pre-built toolchain, you should be pointing to the /opt/poky/{test-version} directory as Toolchain Root Location. This is the default location for toolchains installed by the ADT Installer or by hand. If ADT is installed in other location, use that location as Toolchain location.\nIf you are using a system-derived toolchain, the path you provide for the Toolchain Root Location field is the Yocto Project's build directory.  \n \n           E.g:/home/user/yocto/poky/build \n",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "(b)Specify the Sysroot Location: \nSysroot Location is the location where the root filesystem for the target hardware is created on the development system by the ADT Installer (SYSROOT in step 2 of the case ADT installer Installation).  \n   \n         Local :     e.g: /home/user/qemux86-sato-sdk \nUsing ADT : e.g :/home/user/test-yocto/qemux86  \n\n",
+                    "expected_results": ""
+                },
+                "5": {
+                    "action": "(c)Select the Target Architecture:  \n \nThe target architecture is the type of hardware you are going to use or emulate. Use the pull-down Target Architecture menu to make your selection.  \n \n\n",
+                    "expected_results": ""
+                },
+                "6": {
+                    "action": "(d) QEMU: \nSelect this option if you will be using the QEMU emulator. Specify the Kernel matching the QEMU architecture you are using. \n      wget  autobuilder.yoctoproject.org/pub/releases//machines/qemu/qemux86/bzImage-qemux86.bin \n      e.g: /home/$USER/yocto/adt-installer/download_image/bzImage-qemux86.bin  \n\n",
+                    "expected_results": ""
+                },	
+                "7": {
+                    "action": "(e) select OK to save the settings.  \n\n\n1: In the Eclipse toolbar, expose the Run -> External Tools menu. Your image should appear as a selectable menu item.  \n2: Select your image in the navigation pane to launch the emulator in a new window. \n3: If needed, enter your host root password in the shell window at the prompt. This sets up a Tap 0 connection needed for running in user-space NFS mode. \n",
+                    "expected_results": ""
+                }				
+            },
+            "summary": "Launch_QEMU_from_Eclipse"
+        }
+    },
+    {
+        "test": {
+            "@alias": "eclipse-plugin.eclipse-plugin.Relocatable_SDK_-_C_-_Build_Hello_World_ANSI_C_Autotools_Project",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Launch a QEMU of target enviroment.(Reference to case \"ADT - Launch qemu by eclipse\") ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Select File -> New -> Project.",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Double click C/C++.",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "Click C or C++ Project to create the project.",
+                    "expected_results": ""
+                },
+                "5": {
+                    "action": "Expand Yocto ADT Project.",
+                    "expected_results": ""
+                },
+                "6": {
+                    "action": "Select Hello World ANSI C Autotools Project.",
+                    "expected_results": ""
+                },
+                "7": {
+                    "action": "Put a name in the Project name. Do not use hyphens as part of the name. \n \n",
+                    "expected_results": ""
+                },
+                "8": {
+                    "action": "Click Next.",
+                    "expected_results": ""
+                },
+                "9": {
+                    "action": "Add information in the Author and Copyright notice fields. \n1",
+                    "expected_results": ""
+                },
+                "10": {
+                    "action": "Click Finish. \n1",
+                    "expected_results": ""
+                },
+                "11": {
+                    "action": "If the \"open perspective\" prompt appears, click \"Yes\" so that you open the C/C++ perspective. \n1",
+                    "expected_results": ""
+                },
+                "12": {
+                    "action": "In the Project Explorer window, right click the project -> Reconfigure project. \n1",
+                    "expected_results": ""
+                },
+                "13": {
+                    "action": "In the Project Explorer window, right click the project -> Build project. \n1",
+                    "expected_results": "Under the Project files, a new folder appears called Binaries. This indicates that the compilation have been successful and the project binary have been created. \n"
+                },
+                "14": {
+                    "action": "Right click it again and Run as -> Run Configurations.  \n\t\t\tUnder Run Configurations expand \"C/C++ Remote Application\". A configuration for the current project should appear. Clicking it will display the configuration settings. \n\t\t\tin \"C/C++ Application\" field input Remote Absolute File path for C/C++ Application. e.g.: /home/root/myapplication \n\t\t\tIn \"Connection\" drop-down list make sure a TCF connection is set up for your target. If not, create a new one by clicking the New button. \n1",
+                    "expected_results": "step 14 to step 16 -> Build succeed and the console outputs Hello world, you can also check the output on target."
+                },
+                "15": {
+                    "action": "After all settings are done, select the Run button on the bottom right corner \n\n1",
+                    "expected_results": ""
+                },
+                "16": {
+                    "action": "Repeat the steps 14-15, but instead of using Run Configurations use Debug Configurations: \nRight click it again and Debug as -> Debug Configurations \nUnder Debug Configurations expand \"C/C++ Remote Application\". A configuration for the current project should appear. Clicking it will display the configuration settings. \nin \"C/C++ Application\" field input Remote Absolute File path for C/C++ Application.\ne.g.: /home/root/myapplication \nIn \"Connection\" drop-down list make sure a TCF connection is set up for your target. If not, create a new one by clicking the New button \n1",
+                    "expected_results": ""
+                },
+                "17": {
+                    "action": "After all settings are done, select the Debug button on the bottom right corner",
+                    "expected_results": ""
+                }
+            },
+            "summary": "Relocatable_SDK_-_C_-_Build_Hello_World_ANSI_C_Autotools_Project"
+        }
+    },
+    {
+        "test": {
+            "@alias": "eclipse-plugin.eclipse-plugin.Relocatable_SDK_-_C++_-_Build_Hello_World_C++_Autotools_project",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Launch a QEMU of target enviroment.(Reference to case \"ADT - Launch qemu by eclipse\") ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Select File -> New -> Project. ",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Double click C/C++. ",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "Click C or C++ Project to create the project. ",
+                    "expected_results": ""
+                },
+                "5": {
+                    "action": "Expand Yocto ADT Project. ",
+                    "expected_results": ""
+                },
+                "6": {
+                    "action": "Select Hello World ANSI C++ Autotools Project. ",
+                    "expected_results": ""
+                },
+                "7": {
+                    "action": "Put a name in the Project name. Do not use hyphens as part of the name.  \n \n",
+                    "expected_results": ""
+                },
+                "8": {
+                    "action": "Click Next.",
+                    "expected_results": ""
+                },
+                "9": {
+                    "action": "Add information in the Author and Copyright notice fields.",
+                    "expected_results": ""
+                },
+                "10": {
+                    "action": "Click Finish. \n1",
+                    "expected_results": ""
+                },
+                "11": {
+                    "action": "If the \"open perspective\" prompt appears, click \"Yes\" so that you open the C/C++ perspective. \n1",
+                    "expected_results": ""
+                },
+                "12": {
+                    "action": "In the Project Explorer window, right click the project -> Reconfigure project. \n1",
+                    "expected_results": ""
+                },
+                "13": {
+                    "action": "In the Project Explorer window, right click the project -> Build project. \n\n1",
+                    "expected_results": "under the Project files, a new folder appears called Binaries. This indicates that the compilation have been successful and the project binary have been created.  \n"
+                },
+                "14": {
+                    "action": "Right click it again and Run as -> Run Configurations. \n\t\t\tUnder Run Configurations expand \"C/C++ Remote Application\". A configuration for the current project should appear. Clicking it will display the configuration settings. \n\t\t\tin \"C/C++ Application\" field input Remote Absolute File path for C/C++ Application. e.g.: /home/root/myapplication \n\t\t\tIn \"Connection\" drop-down list make sure a TCF connection is set up for your target. If not, create a new one by clicking the New button. \n1",
+                    "expected_results": "step 14 to step 16 -> Build succeed and the console outputs Hello world, you can also check the output on target."
+                },
+                "15": {
+                    "action": "After all settings are done, select the Run button on the bottom right corner \n\n1",
+                    "expected_results": ""
+                },
+                "16": {
+                    "action": "Repeat the steps 14-15, but instead of using Run Configurations use Debug Configurations: \n\t\tRight click it again and Debug as -> Debug Configurations \n\t\tUnder Debug Configurations expand \"C/C++ Remote Application\". A configuration for the current project should appear. Clicking it will display the configuration settings. \n\t\tin \"C/C++ Application\" field input Remote Absolute File path for C/C++ Application. \n\t\te.g.: /home/root/myapplication \n\t\tIn \"Connection\" drop-down list make sure a TCF connection is set up for your target. If not, create a new one by clicking the New button \n1",
+                    "expected_results": ""
+                },
+                "17": {
+                    "action": "After all settings are done, select the Debug button on the bottom right corner",
+                    "expected_results": ""
+                }
+            },
+            "summary": "Relocatable_SDK_-_C++_-_Build_Hello_World_C++_Autotools_project"
+        }
+    },
+    {
+        "test": {
+            "@alias": "eclipse-plugin.eclipse-plugin.Build_Eclipse_Plugin_from_source",
+            "author": [
+                {
+                    "email": "laurentiu.serban@intel.com",
+                    "name": "laurentiu.serban@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Clone eclipse-poky source.   \n    \n    - git clone git://git.yoctoproject.org/eclipse-poky  \n\n",
+                    "expected_results": "Eclipse plugin is successfully installed  \n\nDocumentation is there. For example if you have release yocto-2.0.1 you will found on   http://autobuilder.yoctoproject.org/pub/releases/yocto-2.0.1/eclipse-plugin/mars/  archive with documentation like org.yocto.doc-development-$date.zip  \n  \n"
+                },
+                "2": {
+                    "action": "Checkout correct tag.  \n\n    - git checkout <eclipse-version>/<yocto-version> \n\n",
+                    "expected_results": "After plugin is build you must have  4 archive in foder scripts from eclipse-poky:  \n     - org.yocto.bc - mars-master-$date.zip  \n     - org.yocto.doc - mars-master-$date.zip    --> documentation  \n     - org.yocto.sdk - mars-master-$date.zip       \n     - org.yocto.sdk - mars-master-$date.-archive.zip  --> plugin  "
+                },
+                "3": {
+                    "action": "Move to scripts/ folder.  \n\n",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": "Run ./setup.sh  \n\n",
+                    "expected_results": ""
+                },
+                "5": {
+                    "action": "When the script finishes, it prompts a command to issue to build the plugin. It should look similar to the following:  \n\n$ ECLIPSE_HOME=/eclipse-poky/scripts/eclipse ./build.sh /&1 | tee -a build.log  \n\nHere, the three arguments to the build script are tag name, branch for documentation and release name.  \n\n",
+                    "expected_results": ""
+                },
+                "6": {
+                    "action": "On an eclipse without the Yocto Plugin, select \"Install New Software\" from Help pull-down menu  \n\n",
+                    "expected_results": ""
+                },
+                "7": {
+                    "action": "Select Add and from the dialog choose Archive...  Look for the *archive.zip file that was built previously with the build.sh script. Click OK.  \n\n",
+                    "expected_results": ""
+                },
+                "8": {
+                    "action": "Select all components and proceed with Installation of plugin. Restarting eclipse might be required.\n",
+                    "expected_results": ""
+                }
+            },
+            "summary": "Build_Eclipse_Plugin_from_source"
+        }
+    },
+    {
+        "test": {
+            "@alias": "eclipse-plugin.eclipse-plugin.Eclipse_Poky_installation_and_setup",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Install SDK  \n\ta)Download https://autobuilder.yocto.io/pub/releases//toolchain/x86_64/poky-glibc-x86_64-core-\timage-sato-i586-toolchain-.sh  \n\tb)Run the SDK installer and accept the default installation directory ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Install \"Eclipse IDE for C/C++ Developers\" Oxygen release (4.7.0)  \n\ta) Go to https://www.eclipse.org/downloads/packages/all, click \"Oxygen R\"  \n\tb) Click to download the build for your OS  \n\tc) Click \"Download\" button to download from a mirror  \n\td) Run \"tar xf\" to extract the downloaded archive  ",
+                    "expected_result": ""
+                },
+                "3": {
+                    "action": "Install \"Eclipse IDE for C/C++ Developers\" Oxygen release (4.7.0) (Continue)  \n\te) Run \"eclipse/eclipse\" to start Eclipse  \n\tf) Optional step for host machine within Intel network: In Eclipse workbench window, go to \"Window\" menu -> \"Preferences...\".  \n\tg) In \"Preferences\" dialog, go to \"General\" -> \"Network Connections\", set \"Active Provider\" to \"Manual\". In \"Proxy \tentries\" table, select HTTP and click \"Edit\" and enter host \"proxy-chain.intel.com\" port 911, click OK. Repeat for HTTPS with port 912 \nClick OK to close \"Preferences\" dialog.  \n\th) Go to \"File\" menu -> \"Restart\" to restart Eclipse for proxy settings to take effect. ",
+                    "expected_result": ""
+                },
+                "4": {
+                    "action": "Install Eclipse Poky plugins  \n\ta) Download https://autobuilder.yocto.io/pub/releases/<yocto-version>/eclipse-plugin/<eclipse-version>/org.yocto.sdk-development-<date>-archive.zip   \n\tb) In Eclipse workbench window, go to \"Help\" menu -> \"Install New Software...\"  \n\tc) In \"Install\" dialog, click \"Add...\" button  \n\td) In \"Add Repository\" dialog, enter \"Eclipse Poky\" for (repository) Name, click \"Archive...\"  ",
+                    "expected_results": ""
+                },
+                "5": {
+                    "action": "Install Eclipse Poky plugins (continue)  \n\te) In \"Repository archive\" browse dialog, select the downloaded Eclipse Poky repository archive  \n\tf) Back in \"Add Repository\" dialog, click \"OK\"  \n\tg) Back in \"Install\" dialog, make sure \"Work with:\" is set to \"Eclipse Poky\" repository, tick \"Yocto Project \tDocumentation Plug-in\" and \"Yocto Project SDK Plug-in\", click \"Next >\" and verify plugins/features name/version, \tclick \"Next >\" and accept license agreement, click \"Finish\"  \n\th) If \"Security Warning\" dialog appears, click \"OK\" to install unsigned content.  \n\ti) In \"Software Updates\" dialog, click \"Yes\" to restart Eclipse to complete Eclipse Poky plugins installation. ",
+                    "expected_results": ""
+                },
+                "6": {
+                    "action": "Setup Eclipse Poky to use SDK  \n\ta) In Eclipse workbench window, go to \"Window\" menu -> \"Preferences\".  \n\tb) In \"Preferences\" window, go to \"Yocto Project SDK\", in \"Cross Compiler Options\" frame, select \"Standalone pre-\tbuilt toolchain\".  ",
+                    "expected_results": "Eclipse Poky plugins installed and running successfully, e.g. observe that \"Yocto Project Tools\" menu is available on Eclipse workbench window."
+                }
+            },
+            "summary": "Eclipse_Poky_installation_and_setup"
+        }
+    }
+]
\ No newline at end of file
diff --git a/poky/meta/lib/oeqa/manual/kernel-dev.json b/poky/meta/lib/oeqa/manual/kernel-dev.json
new file mode 100644
index 0000000..c93b4dd
--- /dev/null
+++ b/poky/meta/lib/oeqa/manual/kernel-dev.json
@@ -0,0 +1,200 @@
+[
+    {
+        "test": {
+            "@alias": "kernel-configuration.kernel-configuration.TCTEMP_2.3_MANUAL_Kernel_dev_defconfig",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Follow the Set Up procedure to complete the common and specific prerequisites for this test case. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Setup https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Prerequisites_7  ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Execute the test case steps asdocumented on the \"Kernel Development Test Cases\" wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Steps_7",
+                    "expected_results": "Review expected results on thethe \"Kernel Development Test Cases\"wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Expected_Results_7"
+                }
+            },
+            "summary": "TCTEMP_2.3_MANUAL_Kernel_dev_defconfig"
+        }
+    },
+    {
+        "test": {
+            "@alias": "kernel-configuration.kernel-configuration.TCTEMP_2.3_MANUAL_Kernel_dev_defconfig+fragments",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Follow the Set Up procedure to complete the common and specific prerequisites for this test case. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Setup https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Prerequisites_8  ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Execute the test case steps asdocumented on the \"Kernel Development Test Cases\" wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Steps_8",
+                    "expected_results": "Review expected results on thethe \"Kernel Development Test Cases\"wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Expected_Results_8"
+                }
+            },
+            "summary": "TCTEMP_2.3_MANUAL_Kernel_dev_defconfig+fragments"
+        }
+    },
+    {
+        "test": {
+            "@alias": "kernel-configuration.kernel-configuration.TCTEMP_2.3_MANUAL_Kernel_dev_Applying_patches",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Follow the Set Up procedure to complete the common and specific prerequisites for this test case. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Setup https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Prerequisites  ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Execute the test case steps asdocumented on the \"Kernel Development Test Cases\" wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Steps",
+                    "expected_results": "Review expected results on thethe \"Kernel Development Test Cases\"wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Expected_Results"
+                }
+            },
+            "summary": "TCTEMP_2.3_MANUAL_Kernel_dev_Applying_patches"
+        }
+    },
+    {
+        "test": {
+            "@alias": "kernel-configuration.kernel-configuration.TCTEMP_2.3_MANUAL_Kernel_dev_linux-yocto-local-source",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Follow the Set Up procedure to complete the common and specific prerequisites for this test case. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Setup https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Prerequisites_2  ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Execute the test case steps asdocumented on the \"Kernel Development Test Cases\" wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Steps_2",
+                    "expected_results": "Review expected results on thethe \"Kernel Development Test Cases\"wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Expected_Results_2"
+                }
+            },
+            "summary": "TCTEMP_2.3_MANUAL_Kernel_dev_linux-yocto-local-source"
+        }
+    },
+    {
+        "test": {
+            "@alias": "kernel-configuration.kernel-configuration.TCTEMP_2.3_MANUAL_Kernel_dev_linux-yocto-custom-local-source",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Follow the Set Up procedure to complete the common and specific prerequisites for this test case. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Setup https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Prerequisites_3  ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Execute the test case steps asdocumented on the \"Kernel Development Test Cases\" wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Steps_3",
+                    "expected_results": "Review expected results on thethe \"Kernel Development Test Cases\"wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Expected_Results_3"
+                }
+            },
+            "summary": "TCTEMP_2.3_MANUAL_Kernel_dev_linux-yocto-custom-local-source"
+        }
+    },
+    {
+        "test": {
+            "@alias": "kernel-configuration.kernel-configuration.TCTEMP_2.3_MANUAL_Kernel_dev_recipe-space_meta",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Follow the Set Up procedure to complete the common and specific prerequisites for this test case. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Setup https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Prerequisites_5  ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Execute the test case steps asdocumented on the \"Kernel Development Test Cases\" wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Steps_5",
+                    "expected_results": "Review expected results on thethe \"Kernel Development Test Cases\"wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Expected_Results_5"
+                }
+            },
+            "summary": "TCTEMP_2.3_MANUAL_Kernel_dev_recipe-space_meta"
+        }
+    },
+    {
+        "test": {
+            "@alias": "kernel-configuration.kernel-configuration.TCTEMP_2.3_MANUAL_Kernel_dev_External_source",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Follow the Set Up procedure to complete the common and specific prerequisites for this test case. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Setup https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Prerequisites_6  ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Execute the test case steps asdocumented on the \"Kernel Development Test Cases\" wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Steps_6",
+                    "expected_results": "Review expected results on thethe \"Kernel Development Test Cases\"wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Expected_Results_6"
+                }
+            },
+            "summary": "TCTEMP_2.3_MANUAL_Kernel_dev_External_source"
+        }
+    },
+    {
+        "test": {
+            "@alias": "kernel-configuration.kernel-configuration.TCTEMP_2.3_MANUAL_Kernel_dev_building_external_modules(hello-mod)",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Follow the Set Up procedure to complete the common and specific prerequisites for this test case. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Setup https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Prerequisites_10  ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Execute the test case steps asdocumented on the \"Kernel Development Test Cases\" wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Setup_10",
+                    "expected_results": "Review expected results on thethe \"Kernel Development Test Cases\"wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Expected_Results_10"
+                }
+            },
+            "summary": "TCTEMP_2.3_MANUAL_Kernel_dev_building_external_modules(hello-mod)"
+        }
+    },
+    {
+        "test": {
+            "@alias": "kernel-configuration.kernel-configuration.TCTEMP_2.3_MANUAL_Kernel_dev_local_parallel_meta",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Follow the Set Up procedure to complete the common and specific prerequisites for this test case. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Setup https://wikioproject.org/wiki/Kernel_Development_Test_Cases#Prerequisites_4  ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Execute the test case steps asdocumented on the \"Kernel Development Test Cases\" wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Steps_4",
+                    "expected_results": "Review expected results on thethe \"Kernel Development Test Cases\"wiki. https://wiki.yoctoproject.org/wiki/Kernel_Development_Test_Cases#Expected_Results_4"
+                }
+            },
+            "summary": "TCTEMP_2.3_MANUAL_Kernel_dev_local_parallel_meta"
+        }
+    }
+]
\ No newline at end of file
diff --git a/poky/meta/lib/oeqa/manual/oe-core.json b/poky/meta/lib/oeqa/manual/oe-core.json
new file mode 100644
index 0000000..d893d84
--- /dev/null
+++ b/poky/meta/lib/oeqa/manual/oe-core.json
@@ -0,0 +1,260 @@
+[
+  {
+    "test": {
+      "@alias": "oe-core.scripts.Use_scripts/pybootchartgui/pybootchartgui.py_to_generate_build_profiles",
+      "author": [
+        {
+          "email": "alexandru.c.georgescu@intel.com",
+          "name": "alexandru.c.georgescu@intel.com"
+        }
+      ],
+      "execution": {
+        "1": {
+          "action": "Run a build for a recipe (e.g. core-image-minimal)",
+          "expected_results": ""
+        },
+        "2": {
+          "action": "Run the profiling script, ../scripts/pybootchartgui/pybootchartgui.py  tmp/buildstats/    \n\n",
+          "expected_results": ""
+        },
+        "3": {
+          "action": "Verify the results ",
+          "expected_results": "The scripts generates svg files with the profiling results . "
+        }
+      },
+      "summary": "Use_scripts/pybootchartgui/pybootchartgui.py_to_generate_build_profiles"
+    }
+  },
+  {
+    "test": {
+      "@alias": "oe-core.scripts.Crosstap_script_check",
+      "author": [
+        {
+          "email": "alexandru.c.georgescu@intel.com",
+          "name": "alexandru.c.georgescu@intel.com"
+        }
+      ],
+      "execution": {
+        "1": {
+          "action": "Create the trace_open.stp script as follows in the host machine:  \n\n\nprobe syscall.open     \n\n{  \n\n\n        printf (\"%s(%d) open (%s)\\n\", execname(), pid(), argstr)  \n\n}  \n\n\n\nif the above failed, then create the below instead.  \n\nprobe syscall.open \n{ \n  printf (\"%s(%d) open\\n\", execname(), pid()) \n\n}  \n \n",
+          "expected_results": ""
+        },
+        "2": {
+          "action": "Add 'tools-profile' and 'ssh-server-openssh' to EXTRA_IMAGE_FEATURES in local.conf \n\n\n",
+          "expected_results": ""
+        },
+        "3": {
+          "action": "Build a core-image-minimal image, build systemtap-native. Start the image under qemu. \n\n",
+          "expected_results": ""
+        },
+        "4": {
+          "action": "Make sure that the ssh service is started on the Qemu machine. \n\n",
+          "expected_results": ""
+        },
+        "5": {
+          "action": "From the host machine poky build_dir, run \"crosstap root@192.168.7.2 trace_open.stp\".",
+          "expected_results": ""
+        },
+        "6": {
+          "action": "In QEMU, try to open some applications, such as open a terminal, input some command,  \n\n",
+          "expected_results": ""
+        },
+        "7": {
+          "action": "Check the host machine, \"crosstap\" has related output. \n\n\n\nNOTE:  Do not build the kernel from shared state(sstate-cache) for this to work.",
+          "expected_results": "The script should successfully connect to the qemu machine and there \nshould be presented a list of services(pid, process name) which run on \nthe qemu machine. "
+        }
+      },
+      "summary": "Crosstap_script_check"
+    }
+  },
+  {
+    "test": {
+      "@alias": "oe-core.scripts.List_all_the_PACKAGECONFIG's_flags",
+      "author": [
+        {
+          "email": "yi.zhao@windriver.com",
+          "name": "yi.zhao@windriver.com"
+        }
+      ],
+      "execution": {
+        "1": {
+          "action": " Download the poky source and setup the environment. ",
+          "expected_results": ""
+        },
+        "2": {
+          "action": "Run \"../scripts/contrib/list-packageconfig-flags.py\" ",
+          "expected_results": "In step 2, will list available pkgs which have PACKAGECONFIG flags:  \nPACKAGE NAME (or RECIPE NAME)           PACKAGECONFIG FLAGS  \n==============================================================  \nalsa-tools-1.0.26.1                                         defaultval gtk+  \navahi-ui-0.6.31                                                defaultval python  \nbluez4-4.101                                                alsa defaultval pie  \n"
+        },
+        "3": {
+          "action": "Run \"../scripts/contrib/list-packageconfig-flags.py -f\" ",
+          "expected_results": "In step 3, will list available PACKAGECONFIG flags and all affected pkgs  \nPACKAGECONFIG FLAG       PACKAGE NAMES (or RECIPE NAMES)  \n====================================  \n3g                             connman-1.16  \n        \navahi                        cups-1.6.3  pulseaudio-4.0  \nbeecrypt                   rpm-5.4.9  rpm-native-5.4.9  \n"
+        },
+        "4": {
+          "action": "Run \"../scripts/contrib/list-packageconfig-flags.py -a\" ",
+          "expected_results": "In step 4, will list all pkgs and PACKAGECONFIG information:  \n==================================================  \ngtk+-2.24.18  \n/home/jiahongxu/yocto/poky/meta/recipes-gnome/gtk+/gtk+_2.24.18.bb  \nPACKAGECONFIG x11  \nPACKAGECONFIG[x11] --with-x=yes --with-gdktarget=x11,--with-x=no,${X11DEPENDS}  \nxf86-video-intel-2.21.9  \n/home/jiahongxu/yocto/poky/meta/recipes-graphics/xorg-driver/xf86-video-intel_2.21.9.bb  \nPACKAGECONFIG None  \nPACKAGECONFIG[xvmc] --enable-xvmc,--disable-xvmc,libxvmc  \nPACKAGECONFIG[sna] --enable-sna,--disable-sna  \n"
+        },
+        "5": {
+          "action": "Run \"../scripts/contrib/list-packageconfig-flags.py -p\"   ",
+          "expected_results": "In step 5, will list pkgs with preferred version:  \nPACKAGE NAME (or RECIPE NAME)              PACKAGECONFIG FLAGS  \n===================================================  \nalsa-tools-1.0.26.1                                           defaultval gtk+  \navahi-ui-0.6.31                                                   defaultval python  \nbluez4-4.101                                                       alsa defaultval pie  \nbluez5-5.7                                                            alsa defaultval obex-profiles  \n\n\n\n "
+        }
+      },
+      "summary": "List_all_the_PACKAGECONFIG's_flags"
+    }
+  },
+  {
+    "test": {
+      "@alias": "oe-core.bitbake.Test_bitbake_menuconfig",
+      "author": [
+        {
+          "email": "jose.perez.carranza@intel.com",
+          "name": "jose.perez.carranza@intel.com"
+        }
+      ],
+      "execution": {
+        "1": {
+          "action": "clone poky  \n \n",
+          "expected_results": ""
+        },
+        "2": {
+          "action": "cd poky   \n\n",
+          "expected_results": ""
+        },
+        "3": {
+          "action": "source oe-init-build-env && cd build    \n\n",
+          "expected_results": ""
+        },
+        "4": {
+          "action": "set below in local.conf   \n\n  \tMACHINE = \"qemux86\"  \n\n",
+          "expected_results": ""
+        },
+        "5": {
+          "action": "bitbake linux-yocto -c kernel_configme -f   \n\n",
+          "expected_results": ""
+        },
+        "6": {
+          "action": "bitbake linux-yocto -c menuconfig   \n\n",
+          "expected_results": ""
+        },
+        "7": {
+          "action": "Once menuconfig launches, use the interface to navigate through the selections and \n   enable option \"64-bit kernel\"  \n\n",
+          "expected_results": ""
+        },
+        "8": {
+          "action": "Save changes and set name of the file as \"test.config\"  ",
+          "expected_results": "Open file:  \n \npoky/build//tmp/work/qemux86-poky-linux/linux-yocto/4.X.X+*/linux-qemux86-standard-build/test.config   \n  \n \n\nand verify that changes are present in the file as follows:   \n \nCONFIG_64BIT=y  \n \nCONFIG_X86_64=y"
+        }
+      },
+      "summary": "Test_bitbake_menuconfig"
+    }
+  },
+  {
+    "test": {
+      "@alias": "oe-core.bitbake.test_bitbake_devshell",
+      "author": [
+        {
+          "email": "jose.perez.carranza@intel.com",
+          "name": "jose.perez.carranza@intel.com"
+        }
+      ],
+      "execution": {
+        "1": {
+          "action": "clone poky ",
+          "expected_results": ""
+        },
+        "2": {
+          "action": "cd poky  ",
+          "expected_results": ""
+        },
+        "3": {
+          "action": "source oe-init-build-env && cd build ",
+          "expected_results": ""
+        },
+        "4": {
+          "action": "bitbake matchbox-desktop ",
+          "expected_results": "Package was build correctly "
+        },
+        "5": {
+          "action": "bitbake matchbox-desktop -c devshell ",
+          "expected_results": "A terminal with a shell prompt within the OpenEmbedded build environment is opened "
+        },
+        "6": {
+          "action": "Verify that \"matchbox-desktop\" binary file is not created under\"src\" directory ",
+          "expected_results": ""
+        },
+        "7": {
+          "action": "Run command:./configure && make ",
+          "expected_results": "Verify that \"matchbox-desktop\" binary file was created successfully under \"src/\" directory "
+        },
+        "8": {
+          "action": "Exit fromthe devshell terminal,exit ",
+          "expected_results": "Terminal back to the build directory"
+        }
+      },
+      "summary": "test_bitbake_devshell"
+    }
+  },
+  {
+    "test": {
+      "@alias": "oe-core.bitbake.test_dependency_explorer_is_launched",
+      "author": [
+        {
+          "email": "jose.perez.carranza@intel.com",
+          "name": "jose.perez.carranza@intel.com"
+        }
+      ],
+      "execution": {
+        "1": {
+          "action": "clone poky ",
+          "expected_results": ""
+        },
+        "2": {
+          "action": "cd poky ",
+          "expected_results": ""
+        },
+        "3": {
+          "action": "source oe-init-build-env ",
+          "expected_results": ""
+        },
+        "4": {
+          "action": "bitbake -u taskexp -g core-image-full-cmdline    \n\nNOTE: To execute the last command of this test, it's necessary that the machine is executing an X11 server, or if that's not the case (for example, if running the test on a headless server), it is required to enable ssh X11 forwarding on both, the server and the client, and have the X11 server running on the client.    \n\nThe instructions to enable X11 forwarding vary between distributions. But for example, these are the steps to enable it between a server running openSUSE Leap 42.1 and a client with Fedora 24:  \nA. On the server, make sure /home//.ssh/config contains the line:  \n     ForwardX11 yes  \nB. On the server, make sure xauth is installed by running:  \n      which xauth  \nC. On the client, connect to the server, enabling X11 forwarding, for example by using:  \n      ssh -X user@server    \nNOTE 2: depexp was renamed to taskexp on 2.3 M4",
+          "expected_results": "Verify that a \"dependency explorer\" is opened and file \n   dependencies are listed  "
+        }
+      },
+      "summary": "test_dependency_explorer_is_launched"
+    }
+  },
+  {
+    "test": {
+      "@alias": "oe-core.bitbake.test_bitbake_sane_error_for_invalid_layer",
+      "author": [
+        {
+          "email": "jose.perez.carranza@intel.com",
+          "name": "jose.perez.carranza@intel.com"
+        }
+      ],
+      "execution": {
+        "1": {
+          "action": "clone poky  \n",
+          "expected_results": ""
+        },
+        "2": {
+          "action": "cd poky  \n \n",
+          "expected_results": ""
+        },
+        "3": {
+          "action": "source oe-init-build-env && cd build  \n \n",
+          "expected_results": ""
+        },
+        "4": {
+          "action": "Add a invalid layer to conf/bblayers.conf  \"<poky dir>/my-invalid-layer\" \n\t\n",
+          "expected_results": ""
+        },
+        "5": {
+          "action": "bitbake core-image-minimal",
+          "expected_results": "Below error should be displayed:\n\"ERROR: Layer directory  does not exist! Please check BBLAYERS in <poky dir>/<build dir>/conf/bblayers.conf\""
+        }
+      },
+      "summary": "test_bitbake_sane_error_for_invalid_layer"
+    }
+  }
+]
\ No newline at end of file
diff --git a/poky/meta/lib/oeqa/manual/sdk.json b/poky/meta/lib/oeqa/manual/sdk.json
new file mode 100644
index 0000000..6475586
--- /dev/null
+++ b/poky/meta/lib/oeqa/manual/sdk.json
@@ -0,0 +1,32 @@
+[
+    {
+        "test": {
+            "@alias": "sdk.sdk_runqemu.test_sdk_toolchain_can_run_multiple_QEMU_machines_under_UNFS",
+            "author": [
+                {
+                    "email": "ee.peng.yeoh@intel.com",
+                    "name": "ee.peng.yeoh@intel.com"
+                }
+            ],
+            "execution": {
+                "1": {
+                    "action": "Prepare kernel, rootfs tar.bz2 image, and qemu configuration  \n    \ta. Download kernel, rootfs tar.bz2 image and qemu configuration from public autobuilder webpage  \n    \tb. Goto https://autobuilder.yocto.io/pub/releases/<target_release>/machines/qemu/qemux86/ \n    \tc. Download  \n    \t  \ti. rootfs tar.bz2: core-image-sato-sdk-qemux86.tar.bz2 \n      \t\tii. kernel: bzImage-qemux86.bin \n      \t\tiii. qemu configuration: core-image-sato-sdk-qemux86.qemuboot.conf ",
+                    "expected_results": ""
+                },
+                "2": {
+                    "action": "Download & install sdk toolchain from public autobuilder \n    \ta. Goto https://autobuilder.yocto.io/pub/releases/<target_release>/toolchain/x86_64/ \n    \tb. Download poky-glibc-x86_64-core-image-sato-sdk-<type-arch>-toolchain-<release-version>.sh \n    \tc. Run command: poky-glibc-x86_64-core-image-sato-sdk-<type-arch>-toolchain-<release-version>.sh",
+                    "expected_results": ""
+                },
+                "3": {
+                    "action": "Extract rootfs twice into two images \n    \ta. Run 2 commands below:  \n                  runqemu-extract-sdk core-image-sato-sdk-qemux86.tar.bz2 qemux86_rootfs_image1  \n                  runqemu-extract-sdk core-image-sato-sdk-qemux86.tar.bz2 qemux86_rootfs_image2",
+                    "expected_results": ""
+                },
+                "4": {
+                    "action": " From the 2 terminals, start qemu to boot up both two images \n    \ta. Run 2 commands below:  \n                  runqemu core-image-sato-sdk-qemux86.qemuboot.conf qemux86_rootfs_image1  \n                  runqemu core-image-sato-sdk-qemux86.qemuboot.conf qemux86_rootfs_image2 ",
+                    "expected_results": "Expect both qemu to boot up successfully."
+                }
+            },
+            "summary": "test_sdk_toolchain_can_run_multiple_QEMU_machines_under_UNFS"
+        }
+    }
+]
\ No newline at end of file
diff --git a/poky/meta/lib/oeqa/runtime/cases/apt.py b/poky/meta/lib/oeqa/runtime/cases/apt.py
index 8d4dd35..793143f 100644
--- a/poky/meta/lib/oeqa/runtime/cases/apt.py
+++ b/poky/meta/lib/oeqa/runtime/cases/apt.py
@@ -18,7 +18,7 @@
     @classmethod
     def setUpClass(cls):
         service_repo = os.path.join(cls.tc.td['DEPLOY_DIR_DEB'], 'all')
-        cls.repo_server = HTTPService(service_repo, cls.tc.target.server_ip)
+        cls.repo_server = HTTPService(service_repo, cls.tc.target.server_ip, logger=cls.tc.logger)
         cls.repo_server.start()
 
     @classmethod
diff --git a/poky/meta/lib/oeqa/runtime/cases/dnf.py b/poky/meta/lib/oeqa/runtime/cases/dnf.py
index 2f87296..c1ed39d 100644
--- a/poky/meta/lib/oeqa/runtime/cases/dnf.py
+++ b/poky/meta/lib/oeqa/runtime/cases/dnf.py
@@ -55,7 +55,7 @@
     @classmethod
     def setUpClass(cls):
         cls.repo_server = HTTPService(os.path.join(cls.tc.td['WORKDIR'], 'oe-testimage-repo'),
-                                      cls.tc.target.server_ip)
+                                      cls.tc.target.server_ip, logger=cls.tc.logger)
         cls.repo_server.start()
 
     @classmethod
@@ -67,7 +67,8 @@
         deploy_url = 'http://%s:%s/' %(self.target.server_ip, self.repo_server.port)
         cmdlinerepoopts = ["--repofrompath=oe-testimage-repo-%s,%s%s" %(arch, deploy_url, arch) for arch in pkgarchs]
 
-        self.dnf(" ".join(cmdlinerepoopts) + " --nogpgcheck " + command)
+        output = self.dnf(" ".join(cmdlinerepoopts) + " --nogpgcheck " + command)
+        return output
 
     @OETestDepends(['dnf.DnfBasicTest.test_dnf_help'])
     @OETestID(1744)
@@ -88,6 +89,9 @@
     @OETestDepends(['dnf.DnfRepoTest.test_dnf_makecache'])
     @OETestID(1740)
     def test_dnf_install(self):
+        output = self.dnf_with_repo('list run-postinsts-dev')
+        if 'Installed Packages' in output:
+            self.dnf_with_repo('remove -y run-postinsts-dev')
         self.dnf_with_repo('install -y run-postinsts-dev')
 
     @OETestDepends(['dnf.DnfRepoTest.test_dnf_install'])
@@ -120,4 +124,44 @@
     def test_dnf_reinstall(self):
         self.dnf_with_repo('reinstall -y run-postinsts-dev')
 
+    @OETestDepends(['dnf.DnfRepoTest.test_dnf_makecache'])
+    @OETestID(1771)
+    def test_dnf_installroot(self):
+        rootpath = '/home/root/chroot/test'
+        #Copy necessary files to avoid errors with not yet installed tools on
+        #installroot directory.
+        self.target.run('mkdir -p %s/etc' % rootpath, 1500)
+        self.target.run('mkdir -p %s/bin %s/sbin %s/usr/bin %s/usr/sbin' % (rootpath, rootpath, rootpath, rootpath), 1500)
+        self.target.run('mkdir -p %s/dev' % rootpath, 1500)
+        #Handle different architectures lib dirs
+        self.target.run('mkdir -p %s/lib' % rootpath, 1500)
+        self.target.run('mkdir -p %s/libx32' % rootpath, 1500)
+        self.target.run('mkdir -p %s/lib64' % rootpath, 1500)
+        self.target.run('cp /lib/libtinfo.so.5 %s/lib' % rootpath, 1500)
+        self.target.run('cp /libx32/libtinfo.so.5 %s/libx32' % rootpath, 1500)
+        self.target.run('cp /lib64/libtinfo.so.5 %s/lib64' % rootpath, 1500)
+        self.target.run('cp -r /etc/rpm %s/etc' % rootpath, 1500)
+        self.target.run('cp -r /etc/dnf %s/etc' % rootpath, 1500)
+        self.target.run('cp /bin/sh %s/bin' % rootpath, 1500)
+        self.target.run('mount -o bind /dev %s/dev/' % rootpath, 1500)
+        self.dnf_with_repo('install --installroot=%s -v -y --rpmverbosity=debug busybox run-postinsts' % rootpath)
+        status, output = self.target.run('test -e %s/var/cache/dnf' % rootpath, 1500)
+        self.assertEqual(0, status, output)
+        status, output = self.target.run('test -e %s/bin/busybox' % rootpath, 1500)
+        self.assertEqual(0, status, output)
 
+    @OETestDepends(['dnf.DnfRepoTest.test_dnf_makecache'])
+    @OETestID(1772)
+    def test_dnf_exclude(self):
+        excludepkg = 'curl-dev'
+        self.dnf_with_repo('install -y curl*')
+        self.dnf('list %s' % excludepkg, 0)
+        #Avoid remove dependencies to skip some errors on different archs and images
+        self.dnf_with_repo('remove --setopt=clean_requirements_on_remove=0 -y curl*')
+        #check curl-dev is not installed adter removing all curl occurrences
+        status, output = self.target.run('dnf list --installed | grep %s'% excludepkg, 1500)
+        self.assertEqual(1, status, "%s was not removed,  is listed as installed"%excludepkg)
+        self.dnf_with_repo('install -y --exclude=%s --exclude=curl-staticdev curl*' % excludepkg)
+        #check curl-dev is not installed after being excluded
+        status, output = self.target.run('dnf list --installed | grep %s'% excludepkg , 1500)
+        self.assertEqual(1, status, "%s was not excluded, is listed as installed"%excludepkg)
diff --git a/poky/meta/lib/oeqa/runtime/cases/ksample.py b/poky/meta/lib/oeqa/runtime/cases/ksample.py
new file mode 100644
index 0000000..354cc97
--- /dev/null
+++ b/poky/meta/lib/oeqa/runtime/cases/ksample.py
@@ -0,0 +1,221 @@
+import os
+import time
+
+from oeqa.runtime.case import OERuntimeTestCase
+from oeqa.core.decorator.depends import OETestDepends
+from oeqa.core.decorator.oeid import OETestID
+from oeqa.core.decorator.data import skipIfNotFeature
+
+# need some kernel fragments
+# echo "KERNEL_FEATURES_append += \" features\/kernel\-sample\/kernel\-sample.scc\"" >> local.conf
+class KSample(OERuntimeTestCase):
+    def cmd_and_check(self, cmd='', match_string=''):
+        status, output = self.target.run(cmd)
+        if not match_string:
+            # send cmd
+            msg = '%s failed, %s' % (cmd, output)
+            self.assertEqual(status, 0, msg=msg)
+        else:
+            # check result
+            result = ("%s" % match_string) in output
+            msg = output
+            self.assertTrue(result, msg)
+            self.assertEqual(status, 0, cmd)
+
+    def check_config(self, config_opt=''):
+        cmd = "zcat /proc/config.gz | grep %s" % config_opt
+        status, output = self.target.run(cmd)
+        result = ("%s=y" % config_opt) in output
+        if not result:
+            self.skipTest("%s is not set" % config_opt)
+
+    def check_module_exist(self, path='', module_name=''):
+        status, output = self.target.run("uname -r")
+        cmd = "ls " + "/lib/modules/" + output + "/kernel/samples/" + path + module_name
+        status, output = self.target.run(cmd)
+        if status != 0:
+            error_info = module_name + " doesn't exist"
+            self.skipTest(error_info)
+
+    def kfifo_func(self, name=''):
+        module_prename = name + "-example"
+        module_name = name + "-example.ko"
+        sysmbol_name = name + "_example"
+
+        # make sure if module exists
+        self.check_module_exist("kfifo/", module_name)
+        # modprobe
+        self.cmd_and_check("modprobe %s" % module_prename)
+        # lsmod
+        self.cmd_and_check("lsmod | grep %s | cut -d\' \' -f1" % sysmbol_name, sysmbol_name)
+        # check result
+        self.cmd_and_check("dmesg | grep \"test passed\" ", "test passed")
+        # rmmod
+        self.cmd_and_check("rmmod %s" %  module_prename)
+
+    def kprobe_func(self, name=''):
+        # check config
+        self.check_config("CONFIG_KPROBES")
+
+        module_prename = name + "_example"
+        module_name = name + "_example.ko"
+        sysmbol_name = module_prename
+
+        # make sure if module exists
+        self.check_module_exist("kprobes/", module_name)
+        # modprobe
+        self.cmd_and_check("modprobe %s" % module_prename)
+        # lsmod
+        self.cmd_and_check("lsmod | grep %s | cut -d\' \' -f1" % sysmbol_name, sysmbol_name)
+        # check result
+        self.cmd_and_check("dmesg | grep Planted | head -n10", "Planted")
+        # rmmod
+        self.cmd_and_check("rmmod %s" % module_prename)
+
+    def kobject_func(self, name=''):
+        module_prename = name + "_example"
+        module_name = name + "-example.ko"
+        sysmbol_name = module_prename
+
+        # make sure if module exists
+        self.check_module_exist("kobject/", module_name)
+        # modprobe
+        self.cmd_and_check("modprobe %s" % module_prename)
+        # lsmod
+        self.cmd_and_check("lsmod | grep %s | cut -d\' \' -f1" % sysmbol_name, sysmbol_name)
+        # check result
+        self.cmd_and_check("ls /sys/kernel/%s/" % sysmbol_name, "bar")
+        # rmmod
+        self.cmd_and_check("rmmod %s" % module_prename)
+
+class KSampleTest(KSample):
+    # kfifo
+    @OETestDepends(['ssh.SSHTest.test_ssh'])
+    def test_kfifo_test(self):
+        index = ["dma", "bytestream", "inttype", "record"]
+        for i in index:
+            self.kfifo_func(i)
+
+    # kprobe
+    @OETestDepends(['ssh.SSHTest.test_ssh'])
+    def test_kprobe_test(self):
+        index = ["kprobe", "kretprobe"]
+        for i in index:
+            self.kprobe_func(i)
+
+    # kobject
+    @OETestDepends(['ssh.SSHTest.test_ssh'])
+    def test_kobject_test(self):
+        index = ["kobject", "kset"]
+        for i in index:
+            self.kobject_func(i)
+
+    #trace
+    @OETestDepends(['ssh.SSHTest.test_ssh'])
+    def test_trace_events(self):
+        # check config
+        self.check_config("CONFIG_TRACING_SUPPORT")
+        # make sure if module exists
+        self.check_module_exist("trace_events/", "trace-events-sample.ko")
+        # modprobe
+        self.cmd_and_check("modprobe trace-events-sample")
+        # lsmod
+        self.cmd_and_check("lsmod | grep trace_events_sample | cut -d\' \' -f1", "trace_events_sample")
+        # check dir
+        self.cmd_and_check("ls /sys/kernel/debug/tracing/events/ | grep sample-trace", "sample-trace")
+        # enable trace
+        self.cmd_and_check("echo 1 > /sys/kernel/debug/tracing/events/sample-trace/enable")
+        self.cmd_and_check("cat /sys/kernel/debug/tracing/events/sample-trace/enable")
+        # check result
+        status = 1
+        count = 0
+        while status != 0:
+            time.sleep(1)
+            status, output = self.target.run('cat /sys/kernel/debug/tracing/trace | grep hello | head -n1 | cut -d\':\' -f2')
+            if " foo_bar" in output:
+                break
+            count = count + 1
+            if count > 5:
+                self.assertTrue(False, "Time out when check result")
+        # disable trace
+        self.cmd_and_check("echo 0 > /sys/kernel/debug/tracing/events/sample-trace/enable")
+        # clean up trace
+        self.cmd_and_check("echo > /sys/kernel/debug/tracing/trace")
+        # rmmod
+        self.cmd_and_check("rmmod trace-events-sample")
+
+    @OETestDepends(['ssh.SSHTest.test_ssh'])
+    def test_trace_printk(self):
+        # check config
+        self.check_config("CONFIG_TRACING_SUPPORT")
+        # make sure if module exists
+        self.check_module_exist("trace_printk/", "trace-printk.ko")
+        # modprobe
+        self.cmd_and_check("modprobe trace-printk")
+        # lsmod
+        self.cmd_and_check("lsmod | grep trace_printk | cut -d\' \' -f1", "trace_printk")
+        # check result
+        self.cmd_and_check("cat /sys/kernel/debug/tracing/trace | grep trace_printk_irq_work | head -n1 | cut -d\':\' -f2", " trace_printk_irq_work")
+        # clean up trace
+        self.cmd_and_check("echo > /sys/kernel/debug/tracing/trace")
+        # rmmod
+        self.cmd_and_check("rmmod trace-printk")
+
+    # hw breakpoint
+    @OETestDepends(['ssh.SSHTest.test_ssh'])
+    def test_hw_breakpoint_example(self):
+        # check arch
+        status, output = self.target.run("uname -m")
+        result = ("x86" in output) or ("aarch64" in output)
+        if not result:
+            self.skipTest("the arch doesn't support hw breakpoint" % output)
+        # check config
+        self.check_config("CONFIG_KALLSYMS_ALL")
+        # make sure if module exists
+        self.check_module_exist("hw_breakpoint/", "data_breakpoint.ko")
+        # modprobe
+        self.cmd_and_check("modprobe data_breakpoint")
+        # lsmod
+        self.cmd_and_check("lsmod | grep data_breakpoint | cut -d\' \' -f1", "data_breakpoint")
+        # check result
+        self.cmd_and_check("cat /var/log/messages | grep sample_hbp_handler", "sample_hbp_handler")
+        # rmmod
+        self.cmd_and_check("rmmod data_breakpoint")
+
+    @OETestDepends(['ssh.SSHTest.test_ssh'])
+    def test_configfs_sample(self):
+        # check config
+        status, ret = self.target.run('zcat /proc/config.gz | grep CONFIG_CONFIGFS_FS')
+        if not ["CONFIG_CONFIGFS_FS=m" in ret or "CONFIG_CONFIGFS_FS=y" in ret]:
+            self.skipTest("CONFIG error")
+        # make sure if module exists
+        self.check_module_exist("configfs/", "configfs_sample.ko")
+        # modprobe
+        self.cmd_and_check("modprobe configfs_sample")
+        # lsmod
+        self.cmd_and_check("lsmod | grep configfs_sample | cut -d\' \' -f1 | head -n1", "configfs_sample")
+
+        status = 1
+        count = 0
+        while status != 0:
+            time.sleep(1)
+            status, ret = self.target.run('cat /sys/kernel/config/01-childless/description')
+            count = count + 1
+            if count > 200:
+                self.skipTest("Time out for check dir")
+
+        # rmmod
+        self.cmd_and_check("rmmod configfs_sample")
+
+    @OETestDepends(['ssh.SSHTest.test_ssh'])
+    def test_cn_test(self):
+        # make sure if module exists
+        self.check_module_exist("connector/", "cn_test.ko")
+        # modprobe
+        self.cmd_and_check("modprobe cn_test")
+        # lsmod
+        self.cmd_and_check("lsmod | grep cn_test | cut -d\' \' -f1", "cn_test")
+        # check result
+        self.cmd_and_check("cat /proc/net/connector | grep cn_test | head -n1 | cut -d\' \' -f1", "cn_test")
+        # rmmod
+        self.cmd_and_check("rmmod cn_test")
diff --git a/poky/meta/lib/oeqa/runtime/cases/ldd.py b/poky/meta/lib/oeqa/runtime/cases/ldd.py
index c6d92fd..5bde184 100644
--- a/poky/meta/lib/oeqa/runtime/cases/ldd.py
+++ b/poky/meta/lib/oeqa/runtime/cases/ldd.py
@@ -2,24 +2,23 @@
 from oeqa.core.decorator.depends import OETestDepends
 from oeqa.core.decorator.oeid import OETestID
 from oeqa.core.decorator.data import skipIfNotFeature
+from oeqa.runtime.decorator.package import OEHasPackage
 
 class LddTest(OERuntimeTestCase):
 
     @OETestID(962)
-    @skipIfNotFeature('tools-sdk',
-                      'Test requires tools-sdk to be in IMAGE_FEATURES')
+    @OEHasPackage(["ldd"])
     @OETestDepends(['ssh.SSHTest.test_ssh'])
-    def test_ldd_exists(self):
+    def test_ldd(self):
         status, output = self.target.run('which ldd')
         msg = 'ldd does not exist in PATH: which ldd: %s' % output
         self.assertEqual(status, 0, msg=msg)
 
-    @OETestID(239)
-    @OETestDepends(['ldd.LddTest.test_ldd_exists'])
-    def test_ldd_rtldlist_check(self):
         cmd = ('for i in $(which ldd | xargs cat | grep "^RTLDLIST"| '
               'cut -d\'=\' -f2|tr -d \'"\'); '
               'do test -f $i && echo $i && break; done')
         status, output = self.target.run(cmd)
-        msg = "ldd path not correct or RTLDLIST files don't exist."
-        self.assertEqual(status, 0, msg=msg)
+        self.assertEqual(status, 0, msg="ldd path not correct or RTLDLIST files don't exist.")
+
+        status, output = self.target.run("ldd /bin/true")
+        self.assertEqual(status, 0, msg="ldd failed to execute: %s" % output)
diff --git a/poky/meta/lib/oeqa/runtime/cases/logrotate.py b/poky/meta/lib/oeqa/runtime/cases/logrotate.py
index 992fef2..db6e695 100644
--- a/poky/meta/lib/oeqa/runtime/cases/logrotate.py
+++ b/poky/meta/lib/oeqa/runtime/cases/logrotate.py
@@ -21,9 +21,9 @@
         self.assertEqual(status, 0, msg = msg)
 
         cmd = ('sed -i "s#wtmp {#wtmp {\\n    olddir $HOME/logrotate_dir#"'
-               ' /etc/logrotate.conf')
+               ' /etc/logrotate.d/wtmp')
         status, output = self.target.run(cmd)
-        msg = ('Could not write to logrotate.conf file. Status and output: '
+        msg = ('Could not write to logrotate.d/wtmp file. Status and output: '
                ' %s and %s' % (status, output))
         self.assertEqual(status, 0, msg = msg)
 
diff --git a/poky/meta/lib/oeqa/runtime/cases/oe_syslog.py b/poky/meta/lib/oeqa/runtime/cases/oe_syslog.py
index 005b697..a92a1f2 100644
--- a/poky/meta/lib/oeqa/runtime/cases/oe_syslog.py
+++ b/poky/meta/lib/oeqa/runtime/cases/oe_syslog.py
@@ -8,12 +8,14 @@
 
     @OETestID(201)
     @OETestDepends(['ssh.SSHTest.test_ssh'])
-    @OEHasPackage(["busybox-syslog", "sysklogd"])
+    @OEHasPackage(["busybox-syslog", "sysklogd", "rsyslog", "syslog-ng"])
     def test_syslog_running(self):
-        cmd = '%s  | grep -i [s]yslogd' % self.tc.target_cmds['ps']
-        status, output = self.target.run(cmd)
-        msg = "No syslogd process; ps output: %s" % output
+        status, output = self.target.run(self.tc.target_cmds['ps'])
+        msg = "Failed to execute %s" % self.tc.target_cmds['ps']
         self.assertEqual(status, 0, msg=msg)
+        msg = "No syslog daemon process; %s output:\n%s" % (self.tc.target_cmds['ps'], output)
+        hasdaemon = "syslogd" in output or "syslog-ng" in output
+        self.assertTrue(hasdaemon, msg=msg)
 
 class SyslogTestConfig(OERuntimeTestCase):
 
@@ -45,7 +47,7 @@
 
     @OETestID(202)
     @OETestDepends(['oe_syslog.SyslogTestConfig.test_syslog_logger'])
-    @OEHasPackage(["!sysklogd", "busybox"])
+    @OEHasPackage(["busybox-syslog"])
     @skipIfDataVar('VIRTUAL-RUNTIME_init_manager', 'systemd',
                    'Not appropiate for systemd image')
     def test_syslog_startup_config(self):
diff --git a/poky/meta/lib/oeqa/runtime/cases/opkg.py b/poky/meta/lib/oeqa/runtime/cases/opkg.py
index 671ee06..29e9902 100644
--- a/poky/meta/lib/oeqa/runtime/cases/opkg.py
+++ b/poky/meta/lib/oeqa/runtime/cases/opkg.py
@@ -17,8 +17,11 @@
 
     @classmethod
     def setUpClass(cls):
-        service_repo = os.path.join(cls.tc.td['DEPLOY_DIR_IPK'], 'all')
-        cls.repo_server = HTTPService(service_repo, cls.tc.target.server_ip)
+        allarchfeed = 'all'
+        if cls.tc.td["MULTILIB_VARIANTS"]:
+            allarchfeed = cls.tc.td["TUNE_PKGARCH"]
+        service_repo = os.path.join(cls.tc.td['DEPLOY_DIR_IPK'], allarchfeed)
+        cls.repo_server = HTTPService(service_repo, cls.tc.target.server_ip, logger=cls.tc.logger)
         cls.repo_server.start()
 
     @classmethod
diff --git a/poky/meta/lib/oeqa/runtime/cases/parselogs.py b/poky/meta/lib/oeqa/runtime/cases/parselogs.py
index 1f36c61..f6e9820 100644
--- a/poky/meta/lib/oeqa/runtime/cases/parselogs.py
+++ b/poky/meta/lib/oeqa/runtime/cases/parselogs.py
@@ -49,6 +49,10 @@
     "error: couldn\'t mount because of unsupported optional features",
     "GPT: Use GNU Parted to correct GPT errors",
     "Cannot set xattr user.Librepo.DownloadInProgress",
+    "Failed to read /var/lib/nfs/statd/state: Success",
+    "error retry time-out =",
+    "logind: cannot setup systemd-logind helper (-61), using legacy fallback",
+    "Error changing net interface name 'eth0' to "
     ]
 
 video_related = [
@@ -120,15 +124,6 @@
         'dmi: Firmware registration failed.',
         'irq: type mismatch, failed to map hwirq-27 for /intc',
         ] + common_errors,
-    'emenlow' : [
-        '[Firmware Bug]: ACPI: No _BQC method, cannot determine initial brightness',
-        '(EE) Failed to load module "psb"',
-        '(EE) Failed to load module psb',
-        '(EE) Failed to load module "psbdrv"',
-        '(EE) Failed to load module psbdrv',
-        '(EE) open /dev/fb0: No such file or directory',
-        '(EE) AIGLX: reverting to software rendering',
-        ] + x86_common,
     'intel-core2-32' : [
         'ACPI: No _BQC method, cannot determine initial brightness',
         '[Firmware Bug]: ACPI: No _BQC method, cannot determine initial brightness',
@@ -156,7 +151,6 @@
         'Bluetooth: hci0: Failed to send firmware data (-38)',
         'atkbd serio0: Failed to enable keyboard on isa0060/serio0',
         ] + x86_common,
-    'crownbay' : x86_common,
     'genericx86' : x86_common,
     'genericx86-64' : [
         'Direct firmware load for i915',
@@ -169,10 +163,6 @@
     'edgerouter' : [
         'Fatal server error:',
         ] + common_errors,
-    'jasperforest' : [
-        'Activated service \'org.bluez\' failed:',
-        'Unable to find NFC netlink family',
-        ] + common_errors,
 }
 
 log_locations = ["/var/log/","/var/log/dmesg", "/tmp/dmesg_output.log"]
@@ -323,7 +313,7 @@
                 pass
 
             if result is not None:
-                results[log.replace('target_logs/','')] = {}
+                results[log] = {}
                 rez = result.splitlines()
 
                 for xrez in rez:
@@ -333,7 +323,7 @@
                         grep_output = check_output(cmd).decode('utf-8')
                     except:
                         pass
-                    results[log.replace('target_logs/','')][xrez]=grep_output
+                    results[log][xrez]=grep_output
 
         return results
 
diff --git a/poky/meta/lib/oeqa/runtime/cases/perl.py b/poky/meta/lib/oeqa/runtime/cases/perl.py
index d0b7e8e..afeeb18 100644
--- a/poky/meta/lib/oeqa/runtime/cases/perl.py
+++ b/poky/meta/lib/oeqa/runtime/cases/perl.py
@@ -1,37 +1,13 @@
 import os
 
 from oeqa.runtime.case import OERuntimeTestCase
-from oeqa.core.decorator.depends import OETestDepends
 from oeqa.core.decorator.oeid import OETestID
 from oeqa.runtime.decorator.package import OEHasPackage
 
 class PerlTest(OERuntimeTestCase):
-
-    @classmethod
-    def setUpClass(cls):
-        src = os.path.join(cls.tc.files_dir, 'test.pl')
-        dst = '/tmp/test.pl'
-        cls.tc.target.copyTo(src, dst)
-
-    @classmethod
-    def tearDownClass(cls):
-        dst = '/tmp/test.pl'
-        cls.tc.target.run('rm %s' % dst)
-
-    @OETestID(1141)
-    @OETestDepends(['ssh.SSHTest.test_ssh'])
-    @OEHasPackage(['perl'])
-    def test_perl_exists(self):
-        status, output = self.target.run('which perl')
-        msg = 'Perl binary not in PATH or not on target.'
-        self.assertEqual(status, 0, msg=msg)
-
     @OETestID(208)
-    @OETestDepends(['perl.PerlTest.test_perl_exists'])
+    @OEHasPackage(['perl'])
     def test_perl_works(self):
-        status, output = self.target.run('perl /tmp/test.pl')
-        msg = 'Exit status was not 0. Output: %s' % output
-        self.assertEqual(status, 0, msg=msg)
-
-        msg = 'Incorrect output: %s' % output
-        self.assertEqual(output, "the value of a is 0.01", msg=msg)
+        status, output = self.target.run("perl -e '$_=\"Uryyb, jbeyq\"; tr/a-zA-Z/n-za-mN-ZA-M/;print'")
+        self.assertEqual(status, 0)
+        self.assertEqual(output, "Hello, world")
diff --git a/poky/meta/lib/oeqa/runtime/cases/python.py b/poky/meta/lib/oeqa/runtime/cases/python.py
index bf3e179..4419a9f 100644
--- a/poky/meta/lib/oeqa/runtime/cases/python.py
+++ b/poky/meta/lib/oeqa/runtime/cases/python.py
@@ -1,43 +1,21 @@
-import os
-
 from oeqa.runtime.case import OERuntimeTestCase
 from oeqa.core.decorator.depends import OETestDepends
 from oeqa.core.decorator.oeid import OETestID
-from oeqa.runtime.decorator.package import OEHasPackage
 
 class PythonTest(OERuntimeTestCase):
-
     @classmethod
     def setUpClass(cls):
-        src = os.path.join(cls.tc.files_dir, 'test.py')
-        dst = '/tmp/test.py'
-        cls.tc.target.copyTo(src, dst)
-
-    @classmethod
-    def tearDownClass(cls):
-        dst = '/tmp/test.py'
-        cls.tc.target.run('rm %s' % dst)
-
-    @OETestID(1145)
-    @OETestDepends(['ssh.SSHTest.test_ssh'])
-    @OEHasPackage(['python-core'])
-    def test_python_exists(self):
-        status, output = self.target.run('which python')
-        msg = 'Python binary not in PATH or not on target.'
-        self.assertEqual(status, 0, msg=msg)
+        import unittest
+        if "python3-core" not in cls.tc.image_packages:
+            raise unittest.SkipTest("Python3 not on target")
 
     @OETestID(965)
-    @OETestDepends(['python.PythonTest.test_python_exists'])
-    def test_python_stdout(self):
-        status, output = self.target.run('python /tmp/test.py')
+    @OETestDepends(['ssh.SSHTest.test_ssh'])
+    def test_python3(self):
+        cmd = "python3 -c \"import codecs; print(codecs.encode('Uryyb, jbeyq', 'rot13'))\""
+        status, output = self.target.run(cmd)
         msg = 'Exit status was not 0. Output: %s' % output
         self.assertEqual(status, 0, msg=msg)
 
         msg = 'Incorrect output: %s' % output
-        self.assertEqual(output, "the value of a is 0.01", msg=msg)
-
-    @OETestID(1146)
-    @OETestDepends(['python.PythonTest.test_python_stdout'])
-    def test_python_testfile(self):
-        status, output = self.target.run('ls /tmp/testfile.python')
-        self.assertEqual(status, 0, msg='Python test file generate failed.')
+        self.assertEqual(output, "Hello, world", msg=msg)
diff --git a/poky/meta/lib/oeqa/runtime/cases/rpm.py b/poky/meta/lib/oeqa/runtime/cases/rpm.py
index 84c59a6..1e5e463 100644
--- a/poky/meta/lib/oeqa/runtime/cases/rpm.py
+++ b/poky/meta/lib/oeqa/runtime/cases/rpm.py
@@ -39,31 +39,31 @@
 
         pkgarch = cls.td['TUNE_PKGARCH'].replace('-', '_')
         rpmdir = os.path.join(cls.tc.td['DEPLOY_DIR'], 'rpm', pkgarch)
-        # Pick rpm-doc as a test file to get installed, because it's small
+        # Pick base-passwd-doc as a test file to get installed, because it's small
         # and it will always be built for standard targets
-        rpm_doc = 'rpm-doc-*.%s.rpm' % pkgarch
+        rpm_doc = 'base-passwd-doc-*.%s.rpm' % pkgarch
         for f in fnmatch.filter(os.listdir(rpmdir), rpm_doc):
             test_file = os.path.join(rpmdir, f)
-        dst = '/tmp/rpm-doc.rpm'
+        dst = '/tmp/base-passwd-doc.rpm'
         cls.tc.target.copyTo(test_file, dst)
 
     @classmethod
     def tearDownClass(cls):
-        dst = '/tmp/rpm-doc.rpm'
+        dst = '/tmp/base-passwd-doc.rpm'
         cls.tc.target.run('rm -f %s' % dst)
 
     @OETestID(192)
     @OETestDepends(['rpm.RpmBasicTest.test_rpm_help'])
     def test_rpm_install(self):
-        status, output = self.target.run('rpm -ivh /tmp/rpm-doc.rpm')
-        msg = 'Failed to install rpm-doc package: %s' % output
+        status, output = self.target.run('rpm -ivh /tmp/base-passwd-doc.rpm')
+        msg = 'Failed to install base-passwd-doc package: %s' % output
         self.assertEqual(status, 0, msg=msg)
 
     @OETestID(194)
     @OETestDepends(['rpm.RpmInstallRemoveTest.test_rpm_install'])
     def test_rpm_remove(self):
-        status,output = self.target.run('rpm -e rpm-doc')
-        msg = 'Failed to remove rpm-doc package: %s' % output
+        status,output = self.target.run('rpm -e base-passwd-doc')
+        msg = 'Failed to remove base-passwd-doc package: %s' % output
         self.assertEqual(status, 0, msg=msg)
 
     @OETestID(1096)
@@ -107,7 +107,7 @@
         Expected:    There should be some RPM prefixed entries in the above file.
         Product:     BSPs
         Author:      Alexandru Georgescu <alexandru.c.georgescu@intel.com>
-        Author:      Alexander Kanavin <alexander.kanavin@intel.com>
+        Author:      Alexander Kanavin <alex.kanavin@gmail.com>
         AutomatedBy: Daniel Istrate <daniel.alexandrux.istrate@intel.com>
         """
         db_files_cmd = 'ls /var/lib/rpm/__db.*'
@@ -119,16 +119,16 @@
         self.assertEqual(0, status, msg=msg)
 
         # Remove the package just in case
-        self.target.run('rpm -e rpm-doc')
+        self.target.run('rpm -e base-passwd-doc')
 
         # Install/Remove a package 10 times
         for i in range(10):
-            status, output = self.target.run('rpm -ivh /tmp/rpm-doc.rpm')
-            msg = 'Failed to install rpm-doc package. Reason: {}'.format(output)
+            status, output = self.target.run('rpm -ivh /tmp/base-passwd-doc.rpm')
+            msg = 'Failed to install base-passwd-doc package. Reason: {}'.format(output)
             self.assertEqual(0, status, msg=msg)
 
-            status, output = self.target.run('rpm -e rpm-doc')
-            msg = 'Failed to remove rpm-doc package. Reason: {}'.format(output)
+            status, output = self.target.run('rpm -e base-passwd-doc')
+            msg = 'Failed to remove base-passwd-doc package. Reason: {}'.format(output)
             self.assertEqual(0, status, msg=msg)
 
         # if using systemd this should ensure all entries are flushed to /var
diff --git a/poky/meta/lib/oeqa/runtime/cases/scanelf.py b/poky/meta/lib/oeqa/runtime/cases/scanelf.py
deleted file mode 100644
index 3ba1f78..0000000
--- a/poky/meta/lib/oeqa/runtime/cases/scanelf.py
+++ /dev/null
@@ -1,26 +0,0 @@
-from oeqa.runtime.case import OERuntimeTestCase
-from oeqa.core.decorator.depends import OETestDepends
-from oeqa.core.decorator.oeid import OETestID
-from oeqa.runtime.decorator.package import OEHasPackage
-
-class ScanelfTest(OERuntimeTestCase):
-    scancmd = 'scanelf --quiet --recursive --mount --ldpath --path'
-
-    @OETestID(966)
-    @OETestDepends(['ssh.SSHTest.test_ssh'])
-    @OEHasPackage(['pax-utils'])
-    def test_scanelf_textrel(self):
-        # print TEXTREL information
-        cmd = '%s --textrel' % self.scancmd
-        status, output = self.target.run(cmd)
-        msg = '\n'.join([cmd, output])
-        self.assertEqual(output.strip(), '', msg=msg)
-
-    @OETestID(967)
-    @OETestDepends(['scanelf.ScanelfTest.test_scanelf_textrel'])
-    def test_scanelf_rpath(self):
-        # print RPATH information
-        cmd = '%s --textrel --rpath' % self.scancmd
-        status, output = self.target.run(cmd)
-        msg = '\n'.join([cmd, output])
-        self.assertEqual(output.strip(), '', msg=msg)
diff --git a/poky/meta/lib/oeqa/runtime/cases/stap.py b/poky/meta/lib/oeqa/runtime/cases/stap.py
index fc728bf..96e197a 100644
--- a/poky/meta/lib/oeqa/runtime/cases/stap.py
+++ b/poky/meta/lib/oeqa/runtime/cases/stap.py
@@ -25,7 +25,7 @@
     def test_stap(self):
         cmds = [
             'cd /usr/src/kernel && make scripts prepare',
-            'cd /lib/modules/`uname -r` && (if [ ! -L build ]; then ln -s /usr/src/kernel build; fi)',
+            'cd /lib/modules/`uname -r` && (if [ ! -e build ]; then ln -s /usr/src/kernel build; fi)',
             'stap --disable-cache -DSTP_NO_VERREL_CHECK /tmp/hello.stp'
             ]
         for cmd in cmds:
diff --git a/poky/meta/lib/oeqa/runtime/cases/systemd.py b/poky/meta/lib/oeqa/runtime/cases/systemd.py
index db69384..460b8fc 100644
--- a/poky/meta/lib/oeqa/runtime/cases/systemd.py
+++ b/poky/meta/lib/oeqa/runtime/cases/systemd.py
@@ -11,11 +11,11 @@
 class SystemdTest(OERuntimeTestCase):
 
     def systemctl(self, action='', target='', expected=0, verbose=False):
-        command = 'systemctl %s %s' % (action, target)
+        command = 'SYSTEMD_BUS_TIMEOUT=240s systemctl %s %s' % (action, target)
         status, output = self.target.run(command)
         message = '\n'.join([command, output])
         if status != expected and verbose:
-            cmd = 'systemctl status --full %s' % target
+            cmd = 'SYSTEMD_BUS_TIMEOUT=240s systemctl status --full %s' % target
             message += self.target.run(cmd)[1]
         self.assertEqual(status, expected, message)
         return output
@@ -63,7 +63,7 @@
         """
         endtime = time.time() + (60 * 2)
         while True:
-            status, output = self.target.run('systemctl --state=activating')
+            status, output = self.target.run('SYSTEMD_BUS_TIMEOUT=240s systemctl --state=activating')
             if "0 loaded units listed" in output:
                 return (True, '')
             if time.time() >= endtime:
diff --git a/poky/meta/lib/oeqa/runtime/context.py b/poky/meta/lib/oeqa/runtime/context.py
index 0294003..a7f3823 100644
--- a/poky/meta/lib/oeqa/runtime/context.py
+++ b/poky/meta/lib/oeqa/runtime/context.py
@@ -112,12 +112,9 @@
             # XXX: Don't base your targets on this code it will be refactored
             # in the near future.
             # Custom target module loading
-            try:
-                target_modules_path = kwargs.get('target_modules_path', '')
-                controller = OERuntimeTestContextExecutor.getControllerModule(target_type, target_modules_path)
-                target = controller(logger, target_ip, server_ip, **kwargs)
-            except ImportError as e:
-                raise TypeError("Failed to import %s from available controller modules" % target_type)
+            target_modules_path = kwargs.get('target_modules_path', '')
+            controller = OERuntimeTestContextExecutor.getControllerModule(target_type, target_modules_path)
+            target = controller(logger, target_ip, server_ip, **kwargs)
 
         return target
 
@@ -173,10 +170,7 @@
     def _loadControllerFromModule(target, modulename):
         obj = None
         # import module, allowing it to raise import exception
-        try:
-            module = __import__(modulename, globals(), locals(), [target])
-        except Exception as e:
-            return obj
+        module = __import__(modulename, globals(), locals(), [target])
         # look for target class in the module, catching any exceptions as it
         # is valid that a module may not have the target class.
         try:
diff --git a/poky/meta/lib/oeqa/sdk/cases/assimp.py b/poky/meta/lib/oeqa/sdk/cases/assimp.py
new file mode 100644
index 0000000..26c1df0
--- /dev/null
+++ b/poky/meta/lib/oeqa/sdk/cases/assimp.py
@@ -0,0 +1,63 @@
+import os, subprocess, unittest
+import bb
+from oeqa.sdk.case import OESDKTestCase
+
+from oeqa.utils.subprocesstweak import errors_have_output
+errors_have_output()
+
+class BuildAssimp(OESDKTestCase):
+    """
+    Test case to build a project using cmake.
+    """
+
+    td_vars = ['DATETIME', 'TARGET_OS', 'TARGET_ARCH']
+
+    @classmethod
+    def setUpClass(self):
+        if not (self.tc.hasHostPackage("nativesdk-cmake") or
+                self.tc.hasHostPackage("cmake-native")):
+            raise unittest.SkipTest("Needs cmake")
+
+    def fetch(self, workdir, dl_dir, url, archive=None):
+        if not archive:
+            from urllib.parse import urlparse
+            archive = os.path.basename(urlparse(url).path)
+
+        if dl_dir:
+            tarball = os.path.join(dl_dir, archive)
+            if os.path.exists(tarball):
+                return tarball
+
+        tarball = os.path.join(workdir, archive)
+        subprocess.check_output(["wget", "-O", tarball, url])
+        return tarball
+
+    def test_assimp(self):
+        import tempfile
+        import oe.qa, oe.elf
+
+        with tempfile.TemporaryDirectory(prefix="assimp", dir=self.tc.sdk_dir) as testdir:
+            dl_dir = self.td.get('DL_DIR', None)
+            tarball = self.fetch(testdir, dl_dir, "https://github.com/assimp/assimp/archive/v4.1.0.tar.gz")
+            subprocess.check_output(["tar", "xf", tarball, "-C", testdir])
+
+            sourcedir = os.path.join(testdir, "assimp-4.1.0") 
+            builddir = os.path.join(testdir, "build")
+            installdir = os.path.join(testdir, "install")
+            bb.utils.mkdirhier(builddir)
+
+            self._run("cd %s && cmake -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON %s " % (builddir, sourcedir))
+            self._run("cmake --build %s -- -j" % builddir)
+            self._run("cmake --build %s --target install -- DESTDIR=%s" % (builddir, installdir))
+
+            elf = oe.qa.ELFFile(os.path.join(installdir, "usr", "local", "lib", "libassimp.so.4.1.0"))
+            elf.open()
+
+            output = self._run("echo $OECORE_TARGET_OS:$OECORE_TARGET_ARCH")
+            target_os, target_arch = output.strip().split(":")
+            machine_data = oe.elf.machine_dict(None)[target_os][target_arch]
+            (machine, osabi, abiversion, endian, bits) = machine_data
+
+            self.assertEqual(machine, elf.machine())
+            self.assertEqual(bits, elf.abiSize())
+            self.assertEqual(endian, elf.isLittleEndian())
diff --git a/poky/meta/lib/oeqa/sdk/cases/buildgalculator.py b/poky/meta/lib/oeqa/sdk/cases/buildgalculator.py
index 780afcc..050d1b3 100644
--- a/poky/meta/lib/oeqa/sdk/cases/buildgalculator.py
+++ b/poky/meta/lib/oeqa/sdk/cases/buildgalculator.py
@@ -8,9 +8,11 @@
 
     @classmethod
     def setUpClass(self):
-        if not (self.tc.hasTargetPackage("gtk\+3") or\
-                self.tc.hasTargetPackage("libgtk-3.0")):
+        if not (self.tc.hasTargetPackage("gtk+3", multilib=True) or \
+                self.tc.hasTargetPackage("libgtk-3.0", multilib=True)):
             raise unittest.SkipTest("GalculatorTest class: SDK don't support gtk+3")
+        if not (self.tc.hasHostPackage("nativesdk-gettext-dev")):
+            raise unittest.SkipTest("GalculatorTest class: SDK doesn't contain gettext")
 
     def test_galculator(self):
         dl_dir = self.td.get('DL_DIR', None)
diff --git a/poky/meta/lib/oeqa/sdk/cases/buildlzip.py b/poky/meta/lib/oeqa/sdk/cases/buildlzip.py
index 3a89ce8..b28cc3a 100644
--- a/poky/meta/lib/oeqa/sdk/cases/buildlzip.py
+++ b/poky/meta/lib/oeqa/sdk/cases/buildlzip.py
@@ -17,8 +17,8 @@
 
         machine = self.td.get("MACHINE")
 
-        if not (self.tc.hasTargetPackage("packagegroup-cross-canadian-%s" % machine) or
-                self.tc.hasTargetPackage("gcc")):
+        if not (self.tc.hasHostPackage("packagegroup-cross-canadian-%s" % machine) or
+                self.tc.hasHostPackage("^gcc-", regex=True)):
             raise unittest.SkipTest("SDK doesn't contain a cross-canadian toolchain")
 
     def test_lzip(self):
diff --git a/poky/meta/lib/oeqa/sdk/cases/gcc.py b/poky/meta/lib/oeqa/sdk/cases/gcc.py
index d11f4b6..b32b01f 100644
--- a/poky/meta/lib/oeqa/sdk/cases/gcc.py
+++ b/poky/meta/lib/oeqa/sdk/cases/gcc.py
@@ -18,8 +18,8 @@
 
     def setUp(self):
         machine = self.td.get("MACHINE")
-        if not (self.tc.hasTargetPackage("packagegroup-cross-canadian-%s" % machine) or
-                self.tc.hasTargetPackage("gcc")):
+        if not (self.tc.hasHostPackage("packagegroup-cross-canadian-%s" % machine) or
+                self.tc.hasHostPackage("^gcc-", regex=True)):
             raise unittest.SkipTest("GccCompileTest class: SDK doesn't contain a cross-canadian toolchain")
 
     def test_gcc_compile(self):
diff --git a/poky/meta/lib/oeqa/sdk/cases/perl.py b/poky/meta/lib/oeqa/sdk/cases/perl.py
index 8085678..ff50b46 100644
--- a/poky/meta/lib/oeqa/sdk/cases/perl.py
+++ b/poky/meta/lib/oeqa/sdk/cases/perl.py
@@ -1,8 +1,4 @@
-import os
-import shutil
 import unittest
-
-from oeqa.core.utils.path import remove_safe
 from oeqa.sdk.case import OESDKTestCase
 
 class PerlTest(OESDKTestCase):
@@ -12,17 +8,10 @@
                 self.tc.hasHostPackage("perl-native")):
             raise unittest.SkipTest("No perl package in the SDK")
 
-        for f in ['test.pl']:
-            shutil.copyfile(os.path.join(self.tc.files_dir, f),
-                    os.path.join(self.tc.sdk_dir, f))
-        self.testfile = os.path.join(self.tc.sdk_dir, "test.pl")
-
-    def test_perl_exists(self):
-        self._run('which perl')
-
-    def test_perl_works(self):
-        self._run('perl %s' % self.testfile)
-
-    @classmethod
-    def tearDownClass(self):
-        remove_safe(self.testfile)
+    def test_perl(self):
+        try:
+            cmd = "perl -e '$_=\"Uryyb, jbeyq\"; tr/a-zA-Z/n-za-mN-ZA-M/;print'"
+            output = self._run(cmd)
+            self.assertEqual(output, "Hello, world")
+        except subprocess.CalledProcessError as e:
+            self.fail("Unexpected exit %d (output %s)" % (e.returncode, e.output))
diff --git a/poky/meta/lib/oeqa/sdk/cases/python.py b/poky/meta/lib/oeqa/sdk/cases/python.py
index 72dfcc7..bd5f1f6 100644
--- a/poky/meta/lib/oeqa/sdk/cases/python.py
+++ b/poky/meta/lib/oeqa/sdk/cases/python.py
@@ -1,32 +1,17 @@
-import os
-import shutil
-import unittest
-
-from oeqa.core.utils.path import remove_safe
+import subprocess, unittest
 from oeqa.sdk.case import OESDKTestCase
 
 class PythonTest(OESDKTestCase):
     @classmethod
     def setUpClass(self):
-        if not (self.tc.hasHostPackage("nativesdk-python") or
-                self.tc.hasHostPackage("python-native")):
+        if not (self.tc.hasHostPackage("nativesdk-python3") or
+                self.tc.hasHostPackage("python3-native")):
             raise unittest.SkipTest("No python package in the SDK")
 
-        for f in ['test.py']:
-            shutil.copyfile(os.path.join(self.tc.files_dir, f),
-                   os.path.join(self.tc.sdk_dir, f))
-
-    def test_python_exists(self):
-        self._run('which python')
-
-    def test_python_stdout(self):
-        output = self._run('python %s/test.py' % self.tc.sdk_dir)
-        self.assertEqual(output.strip(), "the value of a is 0.01", msg="Incorrect output: %s" % output)
-
-    def test_python_testfile(self):
-        self._run('ls /tmp/testfile.python')
-
-    @classmethod
-    def tearDownClass(self):
-        remove_safe("%s/test.py" % self.tc.sdk_dir)
-        remove_safe("/tmp/testfile.python")
+    def test_python3(self):
+        try:
+            cmd = "python3 -c \"import codecs; print(codecs.encode('Uryyb, jbeyq', 'rot13'))\""
+            output = self._run(cmd)
+            self.assertEqual(output, "Hello, world\n")
+        except subprocess.CalledProcessError as e:
+            self.fail("Unexpected exit %d (output %s)" % (e.returncode, e.output))
diff --git a/poky/meta/lib/oeqa/sdk/context.py b/poky/meta/lib/oeqa/sdk/context.py
index 82e4c19b..adc4166 100644
--- a/poky/meta/lib/oeqa/sdk/context.py
+++ b/poky/meta/lib/oeqa/sdk/context.py
@@ -20,17 +20,30 @@
         self.target_pkg_manifest = target_pkg_manifest
         self.host_pkg_manifest = host_pkg_manifest
 
-    def _hasPackage(self, manifest, pkg):
-        for host_pkg in manifest.keys():
-            if re.search(pkg, host_pkg):
+    def _hasPackage(self, manifest, pkg, regex=False):
+        if regex:
+            # do regex match
+            pat = re.compile(pkg)
+            for p in manifest.keys():
+                if pat.search(p):
+                    return True
+        else:
+            # do exact match
+            if pkg in manifest.keys():
                 return True
         return False
 
-    def hasHostPackage(self, pkg):
-        return self._hasPackage(self.host_pkg_manifest, pkg)
+    def hasHostPackage(self, pkg, regex=False):
+        return self._hasPackage(self.host_pkg_manifest, pkg, regex=regex)
 
-    def hasTargetPackage(self, pkg):
-        return self._hasPackage(self.target_pkg_manifest, pkg)
+    def hasTargetPackage(self, pkg, multilib=False, regex=False):
+        if multilib:
+            # match multilib according to sdk_env
+            mls = self.td.get('MULTILIB_VARIANTS', '').split()
+            for ml in mls:
+                if ('ml'+ml) in self.sdk_env:
+                    pkg = ml + '-' + pkg
+        return self._hasPackage(self.target_pkg_manifest, pkg, regex=regex)
 
 class OESDKTestContextExecutor(OETestContextExecutor):
     _context_class = OESDKTestContext
@@ -65,6 +78,9 @@
         sdk_rgroup.add_argument('--sdk-dir', required=False, action='store', 
             help='sdk installed directory')
 
+        self.parser.add_argument('-j', '--num-processes', dest='processes', action='store',
+                type=int, help="number of processes to execute in parallel with")
+
     @staticmethod
     def _load_manifest(manifest):
         pkg_manifest = {}
@@ -85,6 +101,7 @@
                 OESDKTestContextExecutor._load_manifest(args.target_manifest)
         self.tc_kwargs['init']['host_pkg_manifest'] = \
                 OESDKTestContextExecutor._load_manifest(args.host_manifest)
+        self.tc_kwargs['run']['processes'] = args.processes
 
     @staticmethod
     def _get_sdk_environs(sdk_dir):
diff --git a/poky/meta/lib/oeqa/sdk/utils/sdkbuildproject.py b/poky/meta/lib/oeqa/sdk/utils/sdkbuildproject.py
index 4e25114..6fed73e 100644
--- a/poky/meta/lib/oeqa/sdk/utils/sdkbuildproject.py
+++ b/poky/meta/lib/oeqa/sdk/utils/sdkbuildproject.py
@@ -20,10 +20,9 @@
         BuildProject.__init__(self, uri, foldername, tmpdir=testpath, dl_dir=dl_dir)
 
     def download_archive(self):
-
         self._download_archive()
 
-        cmd = 'tar xf %s%s -C %s' % (self.targetdir, self.archive, self.targetdir)
+        cmd = 'tar xf %s -C %s' % (os.path.join(self.targetdir, self.archive), self.targetdir)
         subprocess.check_output(cmd, shell=True)
 
         #Change targetdir to project folder
@@ -42,4 +41,9 @@
 
     def _run(self, cmd):
         self.log("Running . %s; " % self.sdkenv + cmd)
-        return subprocess.call(". %s; " % self.sdkenv + cmd, shell=True)
+        try:
+            output = subprocess.check_output(". %s; " % self.sdkenv + cmd, shell=True, stderr=subprocess.STDOUT)
+        except subprocess.CalledProcessError as exc:
+            print(exc.output.decode('utf-8'))
+            return exc.returncode
+        return 0
diff --git a/poky/meta/lib/oeqa/sdkext/cases/devtool.py b/poky/meta/lib/oeqa/sdkext/cases/devtool.py
index ea90517..0860e8d 100644
--- a/poky/meta/lib/oeqa/sdkext/cases/devtool.py
+++ b/poky/meta/lib/oeqa/sdkext/cases/devtool.py
@@ -6,7 +6,6 @@
 import subprocess
 
 from oeqa.sdkext.case import OESDKExtTestCase
-from oeqa.core.decorator.depends import OETestDepends
 from oeqa.core.decorator.oeid import OETestID
 from oeqa.utils.httpserver import HTTPService
 
@@ -45,28 +44,23 @@
         self.assertEqual(output.startswith(self.tc.sdk_dir), True, \
             msg="Seems that devtool isn't the eSDK one: %s" % output)
 
-    @OETestDepends(['test_devtool_location'])
     def test_devtool_add_reset(self):
         self._run('devtool add myapp %s' % self.myapp_dst)
         self._run('devtool reset myapp')
 
     @OETestID(1605)
-    @OETestDepends(['test_devtool_location'])
     def test_devtool_build_make(self):
         self._test_devtool_build(self.myapp_dst)
 
     @OETestID(1606)
-    @OETestDepends(['test_devtool_location'])
     def test_devtool_build_esdk_package(self):
         self._test_devtool_build_package(self.myapp_dst)
 
     @OETestID(1607)
-    @OETestDepends(['test_devtool_location'])
     def test_devtool_build_cmake(self):
         self._test_devtool_build(self.myapp_cmake_dst)
 
     @OETestID(1608)
-    @OETestDepends(['test_devtool_location'])
     def test_extend_autotools_recipe_creation(self):
         req = 'https://github.com/rdfa/librdfa'
         recipe = "librdfa"
@@ -78,7 +72,6 @@
             self._run('devtool reset %s' % recipe)
 
     @OETestID(1609)
-    @OETestDepends(['test_devtool_location'])
     def test_devtool_kernelmodule(self):
         docfile = 'https://github.com/umlaeute/v4l2loopback.git'
         recipe = 'v4l2loopback-driver'
@@ -89,7 +82,6 @@
             self._run('devtool reset %s' % recipe)
 
     @OETestID(1610)
-    @OETestDepends(['test_devtool_location'])
     def test_recipes_for_nodejs(self):
         package_nodejs = "npm://registry.npmjs.org;name=winston;version=2.2.0"
         self._run('devtool add %s ' % package_nodejs)
diff --git a/poky/meta/lib/oeqa/selftest/case.py b/poky/meta/lib/oeqa/selftest/case.py
index 2e446b0..9c08d59 100644
--- a/poky/meta/lib/oeqa/selftest/case.py
+++ b/poky/meta/lib/oeqa/selftest/case.py
@@ -215,31 +215,31 @@
         ftools.remove_from_file(self.testinc_path, data)
 
     def recipeinc(self, recipe):
-        """Return absolute path of meta-sefltest/recipes-test/<recipe>/test_recipe.inc"""
+        """Return absolute path of meta-selftest/recipes-test/<recipe>/test_recipe.inc"""
         return os.path.join(self.testlayer_path, 'recipes-test', recipe, 'test_recipe.inc')
 
     def write_recipeinc(self, recipe, data):
-        """Write to meta-sefltest/recipes-test/<recipe>/test_recipe.inc"""
+        """Write to meta-selftest/recipes-test/<recipe>/test_recipe.inc"""
         inc_file = self.recipeinc(recipe)
         self.logger.debug("Writing to: %s\n%s\n" % (inc_file, data))
         ftools.write_file(inc_file, data)
         return inc_file
 
     def append_recipeinc(self, recipe, data):
-        """Append data to meta-sefltest/recipes-test/<recipe>/test_recipe.inc"""
+        """Append data to meta-selftest/recipes-test/<recipe>/test_recipe.inc"""
         inc_file = self.recipeinc(recipe)
         self.logger.debug("Appending to: %s\n%s\n" % (inc_file, data))
         ftools.append_file(inc_file, data)
         return inc_file
 
     def remove_recipeinc(self, recipe, data):
-        """Remove data from meta-sefltest/recipes-test/<recipe>/test_recipe.inc"""
+        """Remove data from meta-selftest/recipes-test/<recipe>/test_recipe.inc"""
         inc_file = self.recipeinc(recipe)
         self.logger.debug("Removing from: %s\n%s\n" % (inc_file, data))
         ftools.remove_from_file(inc_file, data)
 
     def delete_recipeinc(self, recipe):
-        """Delete meta-sefltest/recipes-test/<recipe>/test_recipe.inc file"""
+        """Delete meta-selftest/recipes-test/<recipe>/test_recipe.inc file"""
         inc_file = self.recipeinc(recipe)
         self.logger.debug("Deleting file: %s" % inc_file)
         try:
diff --git a/poky/meta/lib/oeqa/selftest/cases/bblayers.py b/poky/meta/lib/oeqa/selftest/cases/bblayers.py
index 90a2249..447c54b 100644
--- a/poky/meta/lib/oeqa/selftest/cases/bblayers.py
+++ b/poky/meta/lib/oeqa/selftest/cases/bblayers.py
@@ -2,7 +2,7 @@
 import re
 
 import oeqa.utils.ftools as ftools
-from oeqa.utils.commands import runCmd, get_bb_var
+from oeqa.utils.commands import runCmd, get_bb_var, get_bb_vars
 
 from oeqa.selftest.case import OESelftestTestCase
 from oeqa.core.decorator.oeid import OETestID
@@ -85,6 +85,31 @@
         self.assertNotEqual(result.status, 0, 'bitbake-layers show-recipes -i nonexistentclass should have failed')
         self.assertIn('ERROR:', result.output)
 
+    def test_bitbakelayers_createlayer(self):
+        priority = 10
+        layername = 'test-bitbakelayer-layercreate'
+        layerpath = os.path.join(self.builddir, layername)
+        self.assertFalse(os.path.exists(layerpath), '%s should not exist at this point in time' % layerpath)
+        result = runCmd('bitbake-layers create-layer --priority=%d %s' % (priority, layerpath))
+        self.track_for_cleanup(layerpath)
+        result = runCmd('bitbake-layers add-layer %s' % layerpath)
+        self.add_command_to_tearDown('bitbake-layers remove-layer %s' % layerpath)
+        result = runCmd('bitbake-layers show-layers')
+        find_in_contents = re.search(re.escape(layername) + r'\s+' + re.escape(layerpath) + r'\s+' + re.escape(str(priority)), result.output)
+        self.assertTrue(find_in_contents, "%s not found in layers\n%s" % (layername, result.output))
+
+        layervars = ['BBFILE_PRIORITY', 'BBFILE_PATTERN', 'LAYERDEPENDS', 'LAYERSERIES_COMPAT']
+        bb_vars = get_bb_vars(['BBFILE_COLLECTIONS'] + ['%s_%s' % (v, layername) for v in layervars])
+
+        for v in layervars:
+            varname = '%s_%s' % (v, layername)
+            self.assertIsNotNone(bb_vars[varname], "%s not found" % varname)
+
+        find_in_contents = re.search(r'(^|\s)' + re.escape(layername) + r'($|\s)', bb_vars['BBFILE_COLLECTIONS'])
+        self.assertTrue(find_in_contents, "%s not in BBFILE_COLLECTIONS" % layername)
+
+        self.assertEqual(bb_vars['BBFILE_PRIORITY_%s' % layername], str(priority), 'BBFILE_PRIORITY_%s != %d' % (layername, priority))
+
     def get_recipe_basename(self, recipe):
         recipe_file = ""
         result = runCmd("bitbake-layers show-recipes -f %s" % recipe)
diff --git a/poky/meta/lib/oeqa/selftest/cases/bbtests.py b/poky/meta/lib/oeqa/selftest/cases/bbtests.py
index 3506149..005fdd0 100644
--- a/poky/meta/lib/oeqa/selftest/cases/bbtests.py
+++ b/poky/meta/lib/oeqa/selftest/cases/bbtests.py
@@ -15,16 +15,26 @@
                 return l
 
     @OETestID(789)
+    # Test bitbake can run from the <builddir>/conf directory
     def test_run_bitbake_from_dir_1(self):
         os.chdir(os.path.join(self.builddir, 'conf'))
         self.assertEqual(bitbake('-e').status, 0, msg = "bitbake couldn't run from \"conf\" dir")
 
     @OETestID(790)
+    # Test bitbake can run from the <builddir>'s parent directory
     def test_run_bitbake_from_dir_2(self):
         my_env = os.environ.copy()
         my_env['BBPATH'] = my_env['BUILDDIR']
         os.chdir(os.path.dirname(os.environ['BUILDDIR']))
-        self.assertEqual(bitbake('-e', env=my_env).status, 0, msg = "bitbake couldn't run from builddir")
+        self.assertEqual(bitbake('-e', env=my_env).status, 0, msg = "bitbake couldn't run from builddir's parent directory")
+
+    # Test bitbake can run from some other random system location (we use /tmp/)
+    def test_run_bitbake_from_dir_3(self):
+        my_env = os.environ.copy()
+        my_env['BBPATH'] = my_env['BUILDDIR']
+        os.chdir("/tmp/")
+        self.assertEqual(bitbake('-e', env=my_env).status, 0, msg = "bitbake couldn't run from /tmp/")
+
 
     @OETestID(806)
     def test_event_handler(self):
diff --git a/poky/meta/lib/oeqa/selftest/cases/buildoptions.py b/poky/meta/lib/oeqa/selftest/cases/buildoptions.py
index 24597ac..f234bac 100644
--- a/poky/meta/lib/oeqa/selftest/cases/buildoptions.py
+++ b/poky/meta/lib/oeqa/selftest/cases/buildoptions.py
@@ -180,3 +180,26 @@
 
         bitbake('gcc-runtime libgfortran')
 
+class SourceMirroring(OESelftestTestCase):
+    # Can we download everything from the Yocto Sources Mirror over http only
+    def test_yocto_source_mirror(self):
+        self.write_config("""
+BB_ALLOWED_NETWORKS = "downloads.yoctoproject.org"
+MIRRORS = ""
+DL_DIR = "${TMPDIR}/test_downloads"
+PREMIRRORS = "\\
+    bzr://.*/.*   http://downloads.yoctoproject.org/mirror/sources/ \\n \\
+    cvs://.*/.*   http://downloads.yoctoproject.org/mirror/sources/ \\n \\
+    git://.*/.*   http://downloads.yoctoproject.org/mirror/sources/ \\n \\
+    gitsm://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \\n \\
+    hg://.*/.*    http://downloads.yoctoproject.org/mirror/sources/ \\n \\
+    osc://.*/.*   http://downloads.yoctoproject.org/mirror/sources/ \\n \\
+    p4://.*/.*    http://downloads.yoctoproject.org/mirror/sources/ \\n \\
+    svn://.*/.*   http://downloads.yoctoproject.org/mirror/sources/ \\n \\
+    ftp://.*/.*      http://downloads.yoctoproject.org/mirror/sources/ \\n \\
+    http://.*/.*     http://downloads.yoctoproject.org/mirror/sources/ \\n \\
+    https://.*/.*    http://downloads.yoctoproject.org/mirror/sources/ \\n"
+""")
+
+        bitbake("world --runall fetch")
+
diff --git a/poky/meta/lib/oeqa/selftest/cases/devtool.py b/poky/meta/lib/oeqa/selftest/cases/devtool.py
index d5b6a46..9eb9bad 100644
--- a/poky/meta/lib/oeqa/selftest/cases/devtool.py
+++ b/poky/meta/lib/oeqa/selftest/cases/devtool.py
@@ -11,9 +11,124 @@
 from oeqa.utils.commands import get_bb_vars, runqemu, get_test_layer
 from oeqa.core.decorator.oeid import OETestID
 
+oldmetapath = None
+
+def setUpModule():
+    import bb.utils
+
+    global templayerdir
+    templayerdir = tempfile.mkdtemp(prefix='devtoolqa')
+    corecopydir = os.path.join(templayerdir, 'core-copy')
+    bblayers_conf = os.path.join(os.environ['BUILDDIR'], 'conf', 'bblayers.conf')
+    edited_layers = []
+
+    # We need to take a copy of the meta layer so we can modify it and not
+    # have any races against other tests that might be running in parallel
+    # however things like COREBASE mean that you can't just copy meta, you
+    # need the whole repository.
+    def bblayers_edit_cb(layerpath, canonical_layerpath):
+        global oldmetapath
+        if not canonical_layerpath.endswith('/'):
+            # This helps us match exactly when we're using this path later
+            canonical_layerpath += '/'
+        if not edited_layers and canonical_layerpath.endswith('/meta/'):
+            canonical_layerpath = os.path.realpath(canonical_layerpath) + '/'
+            edited_layers.append(layerpath)
+            oldmetapath = os.path.realpath(layerpath)
+            result = runCmd('git rev-parse --show-toplevel', cwd=canonical_layerpath)
+            oldreporoot = result.output.rstrip()
+            newmetapath = os.path.join(corecopydir, os.path.relpath(oldmetapath, oldreporoot))
+            runCmd('git clone %s %s' % (oldreporoot, corecopydir), cwd=templayerdir)
+            # Now we need to copy any modified files
+            # You might ask "why not just copy the entire tree instead of
+            # cloning and doing this?" - well, the problem with that is
+            # TMPDIR or an equally large subdirectory might exist
+            # under COREBASE and we don't want to copy that, so we have
+            # to be selective.
+            result = runCmd('git status --porcelain', cwd=oldreporoot)
+            for line in result.output.splitlines():
+                if line.startswith(' M ') or line.startswith('?? '):
+                    relpth = line.split()[1]
+                    pth = os.path.join(oldreporoot, relpth)
+                    if pth.startswith(canonical_layerpath):
+                        if relpth.endswith('/'):
+                            destdir = os.path.join(corecopydir, relpth)
+                            shutil.copytree(pth, destdir)
+                        else:
+                            destdir = os.path.join(corecopydir, os.path.dirname(relpth))
+                            bb.utils.mkdirhier(destdir)
+                            shutil.copy2(pth, destdir)
+            return newmetapath
+        else:
+            return layerpath
+    bb.utils.edit_bblayers_conf(bblayers_conf, None, None, bblayers_edit_cb)
+
+def tearDownModule():
+    if oldmetapath:
+        edited_layers = []
+        def bblayers_edit_cb(layerpath, canonical_layerpath):
+            if not edited_layers and canonical_layerpath.endswith('/meta'):
+                edited_layers.append(layerpath)
+                return oldmetapath
+            else:
+                return layerpath
+        bblayers_conf = os.path.join(os.environ['BUILDDIR'], 'conf', 'bblayers.conf')
+        bb.utils.edit_bblayers_conf(bblayers_conf, None, None, bblayers_edit_cb)
+    shutil.rmtree(templayerdir)
+
 class DevtoolBase(OESelftestTestCase):
 
-    buffer = True
+    @classmethod
+    def setUpClass(cls):
+        super(DevtoolBase, cls).setUpClass()
+        bb_vars = get_bb_vars(['TOPDIR', 'SSTATE_DIR'])
+        cls.original_sstate = bb_vars['SSTATE_DIR']
+        cls.devtool_sstate = os.path.join(bb_vars['TOPDIR'], 'sstate_devtool')
+        cls.sstate_conf  = 'SSTATE_DIR = "%s"\n' % cls.devtool_sstate
+        cls.sstate_conf += ('SSTATE_MIRRORS += "file://.* file:///%s/PATH"\n'
+                            % cls.original_sstate)
+
+    @classmethod
+    def tearDownClass(cls):
+        cls.logger.debug('Deleting devtool sstate cache on %s' % cls.devtool_sstate)
+        runCmd('rm -rf %s' % cls.devtool_sstate)
+        super(DevtoolBase, cls).tearDownClass()
+
+    def setUp(self):
+        """Test case setup function"""
+        super(DevtoolBase, self).setUp()
+        self.workspacedir = os.path.join(self.builddir, 'workspace')
+        self.assertTrue(not os.path.exists(self.workspacedir),
+                        'This test cannot be run with a workspace directory '
+                        'under the build directory')
+        self.append_config(self.sstate_conf)
+
+    def _check_src_repo(self, repo_dir):
+        """Check srctree git repository"""
+        self.assertTrue(os.path.isdir(os.path.join(repo_dir, '.git')),
+                        'git repository for external source tree not found')
+        result = runCmd('git status --porcelain', cwd=repo_dir)
+        self.assertEqual(result.output.strip(), "",
+                         'Created git repo is not clean')
+        result = runCmd('git symbolic-ref HEAD', cwd=repo_dir)
+        self.assertEqual(result.output.strip(), "refs/heads/devtool",
+                         'Wrong branch in git repo')
+
+    def _check_repo_status(self, repo_dir, expected_status):
+        """Check the worktree status of a repository"""
+        result = runCmd('git status . --porcelain',
+                        cwd=repo_dir)
+        for line in result.output.splitlines():
+            for ind, (f_status, fn_re) in enumerate(expected_status):
+                if re.match(fn_re, line[3:]):
+                    if f_status != line[:2]:
+                        self.fail('Unexpected status in line: %s' % line)
+                    expected_status.pop(ind)
+                    break
+            else:
+                self.fail('Unexpected modified file in line: %s' % line)
+        if expected_status:
+            self.fail('Missing file changes: %s' % expected_status)
 
     def _test_recipe_contents(self, recipefile, checkvars, checkinherits):
         with open(recipefile, 'r') as f:
@@ -118,58 +233,6 @@
 
 class DevtoolTests(DevtoolBase):
 
-    @classmethod
-    def setUpClass(cls):
-        super(DevtoolTests, cls).setUpClass()
-        bb_vars = get_bb_vars(['TOPDIR', 'SSTATE_DIR'])
-        cls.original_sstate = bb_vars['SSTATE_DIR']
-        cls.devtool_sstate = os.path.join(bb_vars['TOPDIR'], 'sstate_devtool')
-        cls.sstate_conf  = 'SSTATE_DIR = "%s"\n' % cls.devtool_sstate
-        cls.sstate_conf += ('SSTATE_MIRRORS += "file://.* file:///%s/PATH"\n'
-                            % cls.original_sstate)
-
-    @classmethod
-    def tearDownClass(cls):
-        cls.logger.debug('Deleting devtool sstate cache on %s' % cls.devtool_sstate)
-        runCmd('rm -rf %s' % cls.devtool_sstate)
-        super(DevtoolTests, cls).tearDownClass()
-
-    def setUp(self):
-        """Test case setup function"""
-        super(DevtoolTests, self).setUp()
-        self.workspacedir = os.path.join(self.builddir, 'workspace')
-        self.assertTrue(not os.path.exists(self.workspacedir),
-                        'This test cannot be run with a workspace directory '
-                        'under the build directory')
-        self.append_config(self.sstate_conf)
-
-    def _check_src_repo(self, repo_dir):
-        """Check srctree git repository"""
-        self.assertTrue(os.path.isdir(os.path.join(repo_dir, '.git')),
-                        'git repository for external source tree not found')
-        result = runCmd('git status --porcelain', cwd=repo_dir)
-        self.assertEqual(result.output.strip(), "",
-                         'Created git repo is not clean')
-        result = runCmd('git symbolic-ref HEAD', cwd=repo_dir)
-        self.assertEqual(result.output.strip(), "refs/heads/devtool",
-                         'Wrong branch in git repo')
-
-    def _check_repo_status(self, repo_dir, expected_status):
-        """Check the worktree status of a repository"""
-        result = runCmd('git status . --porcelain',
-                        cwd=repo_dir)
-        for line in result.output.splitlines():
-            for ind, (f_status, fn_re) in enumerate(expected_status):
-                if re.match(fn_re, line[3:]):
-                    if f_status != line[:2]:
-                        self.fail('Unexpected status in line: %s' % line)
-                    expected_status.pop(ind)
-                    break
-            else:
-                self.fail('Unexpected modified file in line: %s' % line)
-        if expected_status:
-            self.fail('Missing file changes: %s' % expected_status)
-
     @OETestID(1158)
     def test_create_workspace(self):
         # Check preconditions
@@ -191,6 +254,8 @@
         self.assertNotIn(tempdir, result.output)
         self.assertIn(self.workspacedir, result.output)
 
+class DevtoolAddTests(DevtoolBase):
+
     @OETestID(1159)
     def test_devtool_add(self):
         # Fetch source
@@ -235,6 +300,8 @@
 
     @OETestID(1423)
     def test_devtool_add_git_local(self):
+        # We need dbus built so that DEPENDS recognition works
+        bitbake('dbus')
         # Fetch source from a remote URL, but do it outside of devtool
         tempdir = tempfile.mkdtemp(prefix='devtoolqa')
         self.track_for_cleanup(tempdir)
@@ -444,6 +511,8 @@
         checkvars['SRC_URI'] = url.replace(testver, '${PV}')
         self._test_recipe_contents(recipefile, checkvars, [])
 
+class DevtoolModifyTests(DevtoolBase):
+
     @OETestID(1164)
     def test_devtool_modify(self):
         import oe.path
@@ -689,6 +758,7 @@
         self._check_src_repo(tempdir)
         # This is probably sufficient
 
+class DevtoolUpdateTests(DevtoolBase):
 
     @OETestID(1169)
     def test_devtool_update_recipe(self):
@@ -1105,6 +1175,8 @@
         expected_status = []
         self._check_repo_status(os.path.dirname(recipefile), expected_status)
 
+class DevtoolExtractTests(DevtoolBase):
+
     @OETestID(1163)
     def test_devtool_extract(self):
         tempdir = tempfile.mkdtemp(prefix='devtoolqa')
@@ -1274,6 +1346,8 @@
         if reqpkgs:
             self.fail('The following packages were not present in the image as expected: %s' % ', '.join(reqpkgs))
 
+class DevtoolUpgradeTests(DevtoolBase):
+
     @OETestID(1367)
     def test_devtool_upgrade(self):
         # Check preconditions
diff --git a/poky/meta/lib/oeqa/selftest/cases/distrodata.py b/poky/meta/lib/oeqa/selftest/cases/distrodata.py
index 7b28004..e7b5e34 100644
--- a/poky/meta/lib/oeqa/selftest/cases/distrodata.py
+++ b/poky/meta/lib/oeqa/selftest/cases/distrodata.py
@@ -21,7 +21,7 @@
         Summary:     Test that upstream version checks do not regress
         Expected:    Upstream version checks should succeed except for the recipes listed in the exception list.
         Product:     oe-core
-        Author:      Alexander Kanavin <alexander.kanavin@intel.com>
+        Author:      Alexander Kanavin <alex.kanavin@gmail.com>
         """
         checkpkg_result = open(os.path.join(get_bb_var("LOG_DIR"), "checkpkg.csv")).readlines()[1:]
         regressed_failures = [pkg_data[0] for pkg_data in [pkg_line.split('\t') for pkg_line in checkpkg_result] if pkg_data[11] == 'UNKNOWN_BROKEN']
@@ -46,7 +46,7 @@
         Summary:     Test that oe-core recipes have a maintainer
         Expected:    All oe-core recipes (except a few special static/testing ones) should have a maintainer listed in maintainers.inc file.
         Product:     oe-core
-        Author:      Alexander Kanavin <alexander.kanavin@intel.com>
+        Author:      Alexander Kanavin <alex.kanavin@gmail.com>
         """
         def is_exception(pkg):
             exceptions = ["packagegroup-", "initramfs-", "systemd-machine-units", "target-sdk-provides-dummy"]
diff --git a/poky/meta/lib/oeqa/selftest/cases/efibootpartition.py b/poky/meta/lib/oeqa/selftest/cases/efibootpartition.py
index 0c83256..c6f39d5 100644
--- a/poky/meta/lib/oeqa/selftest/cases/efibootpartition.py
+++ b/poky/meta/lib/oeqa/selftest/cases/efibootpartition.py
@@ -11,7 +11,6 @@
 class GenericEFITest(OESelftestTestCase):
     """EFI booting test class"""
 
-    buffer = True
     cmd_common = "runqemu nographic serial wic ovmf"
     efi_provider = "systemd-boot"
     image = "core-image-minimal"
diff --git a/poky/meta/lib/oeqa/selftest/cases/fetch.py b/poky/meta/lib/oeqa/selftest/cases/fetch.py
new file mode 100644
index 0000000..4acc8cd
--- /dev/null
+++ b/poky/meta/lib/oeqa/selftest/cases/fetch.py
@@ -0,0 +1,49 @@
+import oe.path
+from oeqa.selftest.case import OESelftestTestCase
+from oeqa.utils.commands import bitbake
+from oeqa.core.decorator.oeid import OETestID
+
+class Fetch(OESelftestTestCase):
+    @OETestID(1058)
+    def test_git_mirrors(self):
+        """
+        Verify that the git fetcher will fall back to the HTTP mirrors. The
+        recipe needs to be one that we have on the Yocto Project source mirror
+        and is hosted in git.
+        """
+
+        # TODO: mktempd instead of hardcoding
+        dldir = os.path.join(self.builddir, "download-git-mirrors")
+        self.track_for_cleanup(dldir)
+
+        # No mirrors, should use git to fetch successfully
+        features = """
+DL_DIR = "%s"
+MIRRORS_forcevariable = ""
+PREMIRRORS_forcevariable = ""
+""" % dldir
+        self.write_config(features)
+        oe.path.remove(dldir, recurse=True)
+        bitbake("dbus-wait -c fetch -f")
+
+        # No mirrors and broken git, should fail
+        features = """
+DL_DIR = "%s"
+GIT_PROXY_COMMAND = "false"
+MIRRORS_forcevariable = ""
+PREMIRRORS_forcevariable = ""
+""" % dldir
+        self.write_config(features)
+        oe.path.remove(dldir, recurse=True)
+        with self.assertRaises(AssertionError):
+            bitbake("dbus-wait -c fetch -f")
+
+        # Broken git but a specific mirror
+        features = """
+DL_DIR = "%s"
+GIT_PROXY_COMMAND = "false"
+MIRRORS_forcevariable = "git://.*/.* http://downloads.yoctoproject.org/mirror/sources/"
+""" % dldir
+        self.write_config(features)
+        oe.path.remove(dldir, recurse=True)
+        bitbake("dbus-wait -c fetch -f")
diff --git a/poky/meta/lib/oeqa/selftest/cases/image_typedep.py b/poky/meta/lib/oeqa/selftest/cases/image_typedep.py
index e678885..932c7f8 100644
--- a/poky/meta/lib/oeqa/selftest/cases/image_typedep.py
+++ b/poky/meta/lib/oeqa/selftest/cases/image_typedep.py
@@ -29,11 +29,14 @@
         # like CONVERSION_DEPENDS_bz2="somedep"
         result = bitbake('-e emptytest')
 
+        dep = None
         for line in result.output.split('\n'):
             if line.startswith('CONVERSION_DEPENDS_bz2'):
                 dep = line.split('=')[1].strip('"')
                 break
 
+        self.assertIsNotNone(dep, "CONVERSION_DEPENDS_bz2 dependency not found in bitbake -e output")
+
         # Now get the dependency task list and check for the expected task
         # dependency
         bitbake('-g emptytest')
diff --git a/poky/meta/lib/oeqa/selftest/cases/imagefeatures.py b/poky/meta/lib/oeqa/selftest/cases/imagefeatures.py
index 09e0b20..8c95432 100644
--- a/poky/meta/lib/oeqa/selftest/cases/imagefeatures.py
+++ b/poky/meta/lib/oeqa/selftest/cases/imagefeatures.py
@@ -10,8 +10,6 @@
     test_user = 'tester'
     root_user = 'root'
 
-    buffer = True
-
     @OETestID(1107)
     def test_non_root_user_can_connect_via_ssh_without_password(self):
         """
@@ -23,7 +21,7 @@
         AutomatedBy: Daniel Istrate <daniel.alexandrux.istrate@intel.com>
         """
 
-        features = 'EXTRA_IMAGE_FEATURES = "ssh-server-openssh empty-root-password allow-empty-password"\n'
+        features = 'EXTRA_IMAGE_FEATURES = "ssh-server-openssh empty-root-password allow-empty-password allow-root-login"\n'
         features += 'INHERIT += "extrausers"\n'
         features += 'EXTRA_USERS_PARAMS = "useradd -p \'\' {}; usermod -s /bin/sh {};"'.format(self.test_user, self.test_user)
         self.write_config(features)
@@ -49,7 +47,7 @@
         AutomatedBy: Daniel Istrate <daniel.alexandrux.istrate@intel.com>
         """
 
-        features = 'EXTRA_IMAGE_FEATURES = "ssh-server-openssh allow-empty-password"\n'
+        features = 'EXTRA_IMAGE_FEATURES = "ssh-server-openssh allow-empty-password allow-root-login"\n'
         features += 'INHERIT += "extrausers"\n'
         features += 'EXTRA_USERS_PARAMS = "useradd -p \'\' {}; usermod -s /bin/sh {};"'.format(self.test_user, self.test_user)
         self.write_config(features)
diff --git a/poky/meta/lib/oeqa/selftest/cases/lic_checksum.py b/poky/meta/lib/oeqa/selftest/cases/lic_checksum.py
index 3740715..f992b37 100644
--- a/poky/meta/lib/oeqa/selftest/cases/lic_checksum.py
+++ b/poky/meta/lib/oeqa/selftest/cases/lic_checksum.py
@@ -19,6 +19,8 @@
         os.close(lic_file)
         self.track_for_cleanup(lic_path)
 
+        self.write_config("INHERIT_remove = \"report-error\"")
+
         self.write_recipeinc('emptytest', """
 INHIBIT_DEFAULT_DEPS = "1"
 LIC_FILES_CHKSUM = "file://%s;md5=d41d8cd98f00b204e9800998ecf8427e"
@@ -29,7 +31,6 @@
         with open(lic_path, "w") as f:
             f.write("data")
 
-        self.write_config("INHERIT_remove = \"report-error\"")
         result = bitbake(bitbake_cmd, ignore_status=True)
         if error_msg not in result.output:
             raise AssertionError(result.output)
diff --git a/poky/meta/lib/oeqa/selftest/cases/oelib/elf.py b/poky/meta/lib/oeqa/selftest/cases/oelib/elf.py
index 74ee6a1..15c03f4 100644
--- a/poky/meta/lib/oeqa/selftest/cases/oelib/elf.py
+++ b/poky/meta/lib/oeqa/selftest/cases/oelib/elf.py
@@ -15,6 +15,7 @@
         self.assertEqual(oe.qa.elf_machine_to_string(0x32), "IA-64")
         self.assertEqual(oe.qa.elf_machine_to_string(0x3E), "x86-64")
         self.assertEqual(oe.qa.elf_machine_to_string(0xB7), "AArch64")
+        self.assertEqual(oe.qa.elf_machine_to_string(0xF7), "BPF")
 
         self.assertEqual(oe.qa.elf_machine_to_string(0x00), "Unknown (0)")
         self.assertEqual(oe.qa.elf_machine_to_string(0xDEADBEEF), "Unknown (3735928559)")
diff --git a/poky/meta/lib/oeqa/selftest/cases/oelib/utils.py b/poky/meta/lib/oeqa/selftest/cases/oelib/utils.py
index 9fb6c15..789c6f7 100644
--- a/poky/meta/lib/oeqa/selftest/cases/oelib/utils.py
+++ b/poky/meta/lib/oeqa/selftest/cases/oelib/utils.py
@@ -1,5 +1,8 @@
+import sys
 from unittest.case import TestCase
-from oe.utils import packages_filter_out_system, trim_version
+from contextlib import contextmanager
+from io import StringIO
+from oe.utils import packages_filter_out_system, trim_version, multiprocess_launch
 
 class TestPackagesFilterOutSystem(TestCase):
     def test_filter(self):
@@ -49,3 +52,48 @@
         self.assertEqual(trim_version("1.2.3", 2), "1.2")
         self.assertEqual(trim_version("1.2.3", 3), "1.2.3")
         self.assertEqual(trim_version("1.2.3", 4), "1.2.3")
+
+
+class TestMultiprocessLaunch(TestCase):
+
+    def test_multiprocesslaunch(self):
+        import bb
+
+        def testfunction(item, d):
+            if item == "2" or item == "1":
+                raise KeyError("Invalid number %s" % item)
+            return "Found %s" % item
+
+        def dummyerror(msg):
+            print("ERROR: %s" % msg)
+        def dummyfatal(msg):
+            print("ERROR: %s" % msg)
+            raise bb.BBHandledException()
+
+        @contextmanager
+        def captured_output():
+            new_out, new_err = StringIO(), StringIO()
+            old_out, old_err = sys.stdout, sys.stderr
+            try:
+                sys.stdout, sys.stderr = new_out, new_err
+                yield sys.stdout, sys.stderr
+            finally:
+                sys.stdout, sys.stderr = old_out, old_err
+
+        d = bb.data_smart.DataSmart()
+        bb.error = dummyerror
+        bb.fatal = dummyfatal
+
+        # Assert the function returns the right results
+        result = multiprocess_launch(testfunction, ["3", "4", "5", "6"], d, extraargs=(d,))
+        self.assertIn("Found 3", result)
+        self.assertIn("Found 4", result)
+        self.assertIn("Found 5", result)
+        self.assertIn("Found 6", result)
+        self.assertEqual(len(result), 4)
+
+        # Assert the function prints exceptions
+        with captured_output() as (out, err):
+            self.assertRaises(bb.BBHandledException, multiprocess_launch, testfunction, ["1", "2", "3", "4", "5", "6"], d, extraargs=(d,))
+        self.assertIn("KeyError: 'Invalid number 1'", out.getvalue())
+        self.assertIn("KeyError: 'Invalid number 2'", out.getvalue())
diff --git a/poky/meta/lib/oeqa/selftest/cases/oescripts.py b/poky/meta/lib/oeqa/selftest/cases/oescripts.py
index 1ee7537..bcdc2d5 100644
--- a/poky/meta/lib/oeqa/selftest/cases/oescripts.py
+++ b/poky/meta/lib/oeqa/selftest/cases/oescripts.py
@@ -10,6 +10,19 @@
         target = 'xcursor-transparent-theme'
         self.run_buildhistory_operation(target, target_config="PR = \"r1\"", change_bh_location=True)
         self.run_buildhistory_operation(target, target_config="PR = \"r0\"", change_bh_location=False, expect_error=True)
+        result = runCmd("oe-pkgdata-util read-value PKGV %s" % target)
+        pkgv = result.output.rstrip()
         result = runCmd("buildhistory-diff -p %s" % get_bb_var('BUILDHISTORY_DIR'))
-        expected_output = 'PR changed from "r1" to "r0"'
-        self.assertTrue(expected_output in result.output, msg="Did not find expected output: %s" % result.output)
+        expected_endlines = [
+            "xcursor-transparent-theme-dev: RDEPENDS: removed \"xcursor-transparent-theme (['= %s-r1'])\", added \"xcursor-transparent-theme (['= %s-r0'])\"" % (pkgv, pkgv),
+            "xcursor-transparent-theme-staticdev: RDEPENDS: removed \"xcursor-transparent-theme-dev (['= %s-r1'])\", added \"xcursor-transparent-theme-dev (['= %s-r0'])\"" % (pkgv, pkgv)
+        ]
+        for line in result.output.splitlines():
+            for el in expected_endlines:
+                if line.endswith(el):
+                    expected_endlines.remove(el)
+                    break
+            else:
+                self.fail('Unexpected line:\n%s\nExpected line endings:\n  %s' % (line, '\n  '.join(expected_endlines)))
+        if expected_endlines:
+            self.fail('Missing expected line endings:\n  %s' % '\n  '.join(expected_endlines))
diff --git a/poky/meta/lib/oeqa/selftest/cases/package.py b/poky/meta/lib/oeqa/selftest/cases/package.py
index 169698f..0a88dc2 100644
--- a/poky/meta/lib/oeqa/selftest/cases/package.py
+++ b/poky/meta/lib/oeqa/selftest/cases/package.py
@@ -1,6 +1,7 @@
 from oeqa.selftest.case import OESelftestTestCase
 from oeqa.core.decorator.oeid import OETestID
-from oeqa.utils.commands import bitbake, get_bb_vars
+from oeqa.utils.commands import bitbake, get_bb_vars, get_bb_var, runqemu
+import stat
 import subprocess, os
 import oe.path
 
@@ -29,7 +30,7 @@
         cls.bindir = oe.path.join(cls.staging, vars["bindir_native"])
         cls.libdir = oe.path.join(cls.staging, vars["libdir_native"])
 
-    def setUp(self):
+    def setUpLocal(self):
         # Just for convenience
         self.staging = type(self).staging
         self.bindir = type(self).bindir
@@ -84,3 +85,65 @@
             status = subprocess.call(command, env=env)
             self.assertIn(status, (99, 100, 101))
             self.assertEqual(status - 100, sort, "%s %s (%d) failed" % (ver1, ver2, sort))
+
+class PackageTests(OESelftestTestCase):
+    # Verify that a recipe which sets up hardlink files has those preserved into split packages
+    # Also test file sparseness is preserved
+    def test_preserve_sparse_hardlinks(self):
+        bitbake("selftest-hardlink -c package")
+
+        dest = get_bb_var('PKGDEST', 'selftest-hardlink')
+        bindir = get_bb_var('bindir', 'selftest-hardlink')
+
+        def checkfiles():
+            # Recipe creates 4 hardlinked files, there is a copy in package/ and a copy in packages-split/
+            # so expect 8 in total.
+            self.assertEqual(os.stat(dest + "/selftest-hardlink" + bindir + "/hello1").st_nlink, 8)
+
+            # Test a sparse file remains sparse
+            sparsestat = os.stat(dest + "/selftest-hardlink" + bindir + "/sparsetest")
+            self.assertEqual(sparsestat.st_blocks, 0)
+            self.assertEqual(sparsestat.st_size, 1048576)
+
+        checkfiles()
+
+        # Clean and reinstall so its now definitely from sstate, then retest.
+        bitbake("selftest-hardlink -c clean")
+        bitbake("selftest-hardlink -c package")
+
+        checkfiles()
+
+    # Verify gdb to read symbols from separated debug hardlink file correctly
+    def test_gdb_hardlink_debug(self):
+        features = 'IMAGE_INSTALL_append = " selftest-hardlink"\n'
+        features += 'IMAGE_INSTALL_append = " selftest-hardlink-dbg"\n'
+        features += 'IMAGE_INSTALL_append = " selftest-hardlink-gdb"\n'
+        self.write_config(features)
+        bitbake("core-image-minimal")
+
+        def gdbtest(qemu, binary):
+            """
+            Check that gdb ``binary`` to read symbols from separated debug file
+            """
+            self.logger.info("gdbtest %s" % binary)
+            status, output = qemu.run_serial('/usr/bin/gdb.sh %s' % binary, timeout=60)
+            for l in output.split('\n'):
+                # Check debugging symbols exists
+                if '(no debugging symbols found)' in l:
+                    self.logger.error("No debugging symbols found. GDB result:\n%s" % output)
+                    return False
+
+                # Check debugging symbols works correctly
+                elif "Breakpoint 1, main () at hello.c:4" in l:
+                    return True
+
+            self.logger.error("GDB result:\n%s: %s" % output)
+            return False
+
+        with runqemu('core-image-minimal') as qemu:
+            for binary in ['/usr/bin/hello1',
+                           '/usr/bin/hello2',
+                           '/usr/libexec/hello3',
+                           '/usr/libexec/hello4']:
+                if not gdbtest(qemu, binary):
+                    self.fail('GDB %s failed' % binary)
diff --git a/poky/meta/lib/oeqa/selftest/cases/recipetool.py b/poky/meta/lib/oeqa/selftest/cases/recipetool.py
index 437eb2a..06f980e 100644
--- a/poky/meta/lib/oeqa/selftest/cases/recipetool.py
+++ b/poky/meta/lib/oeqa/selftest/cases/recipetool.py
@@ -427,6 +427,8 @@
 
     @OETestID(1418)
     def test_recipetool_create_cmake(self):
+        bitbake('-c packagedata gtk+')
+
         # Try adding a recipe
         temprecipe = os.path.join(self.tempdir, 'recipe')
         os.makedirs(temprecipe)
@@ -439,7 +441,7 @@
         checkvars['SRC_URI'] = 'http://downloads.yoctoproject.org/mirror/sources/navit-${PV}.tar.gz'
         checkvars['SRC_URI[md5sum]'] = '242f398e979a6b8c0f3c802b63435b68'
         checkvars['SRC_URI[sha256sum]'] = '13353481d7fc01a4f64e385dda460b51496366bba0fd2cc85a89a0747910e94d'
-        checkvars['DEPENDS'] = set(['freetype', 'zlib', 'openssl', 'glib-2.0', 'virtual/libgl', 'virtual/egl', 'gtk+', 'libpng', 'libsdl', 'freeglut', 'dbus-glib'])
+        checkvars['DEPENDS'] = set(['freetype', 'zlib', 'openssl', 'glib-2.0', 'virtual/libgl', 'virtual/egl', 'gtk+', 'libpng', 'libsdl', 'freeglut', 'dbus-glib', 'fribidi'])
         inherits = ['cmake', 'python-dir', 'gettext', 'pkgconfig']
         self._test_recipe_contents(recipefile, checkvars, inherits)
 
diff --git a/poky/meta/lib/oeqa/selftest/cases/runqemu.py b/poky/meta/lib/oeqa/selftest/cases/runqemu.py
index a758aaf..4e35bb9 100644
--- a/poky/meta/lib/oeqa/selftest/cases/runqemu.py
+++ b/poky/meta/lib/oeqa/selftest/cases/runqemu.py
@@ -14,8 +14,6 @@
 
     image_is_ready = False
     deploy_dir_image = ''
-    # We only want to print runqemu stdout/stderr if there is a test case failure
-    buffer = True
 
     def setUpLocal(self):
         super(RunqemuTests, self).setUpLocal()
@@ -176,14 +174,17 @@
         # when qemu was shutdown by the above shutdown command
         qemu.runner.stop_thread()
         time_track = 0
-        while True:
-            is_alive = qemu.check()
-            if not is_alive:
-                return True
-            if time_track > timeout:
-                return False
-            time.sleep(1)
-            time_track += 1
+        try:
+            while True:
+                is_alive = qemu.check()
+                if not is_alive:
+                    return True
+                if time_track > timeout:
+                    return False
+                time.sleep(1)
+                time_track += 1
+        except SystemExit:
+            return True
 
     def test_qemu_can_shutdown(self):
         self.assertExists(self.qemuboot_conf)
diff --git a/poky/meta/lib/oeqa/selftest/cases/runtime_test.py b/poky/meta/lib/oeqa/selftest/cases/runtime_test.py
index 146daf8..906e460 100644
--- a/poky/meta/lib/oeqa/selftest/cases/runtime_test.py
+++ b/poky/meta/lib/oeqa/selftest/cases/runtime_test.py
@@ -122,6 +122,7 @@
             self.skipTest('core-image-full-cmdline not buildable for poky-tiny')
 
         features = 'INHERIT += "testimage"\n'
+        features += 'IMAGE_INSTALL_append = " libssl"\n'
         features += 'TEST_SUITES = "ping ssh selftest"\n'
         self.write_config(features)
 
@@ -135,7 +136,7 @@
         Summary: Check package feeds functionality for dnf
         Expected: 1. Check that remote package feeds can be accessed
         Product: oe-core
-        Author: Alexander Kanavin <alexander.kanavin@intel.com>
+        Author: Alexander Kanavin <alex.kanavin@gmail.com>
         """
         if get_bb_var('DISTRO') == 'poky-tiny':
             self.skipTest('core-image-full-cmdline not buildable for poky-tiny')
@@ -233,7 +234,7 @@
         Expected:       The scriptlet failure is properly reported.
                         The file that is created after the error in the scriptlet is not present.
         Product: oe-core
-        Author: Alexander Kanavin <alexander.kanavin@intel.com>
+        Author: Alexander Kanavin <alex.kanavin@gmail.com>
         """
 
         import oe.path
@@ -251,8 +252,8 @@
                 features = 'CORE_IMAGE_EXTRA_INSTALL = "postinst-rootfs-failing"\n'
                 features += 'PACKAGE_CLASSES = "%s"\n' % classes
                 self.write_config(features)
-                bb_result = bitbake('core-image-minimal')
-                self.assertGreaterEqual(bb_result.output.find("Intentionally failing postinstall scriptlets of ['postinst-rootfs-failing'] to defer them to first boot is deprecated."), 0,
+                bb_result = bitbake('core-image-minimal', ignore_status=True)
+                self.assertGreaterEqual(bb_result.output.find("Postinstall scriptlets of ['postinst-rootfs-failing'] have failed."), 0,
                     "Warning about a failed scriptlet not found in bitbake output: %s" %(bb_result.output))
 
                 self.assertTrue(os.path.isfile(os.path.join(hosttestdir, "rootfs-before-failure")),
diff --git a/poky/meta/lib/oeqa/selftest/cases/signing.py b/poky/meta/lib/oeqa/selftest/cases/signing.py
index 0edaf40..4fa99ac 100644
--- a/poky/meta/lib/oeqa/selftest/cases/signing.py
+++ b/poky/meta/lib/oeqa/selftest/cases/signing.py
@@ -59,7 +59,7 @@
         Expected:    Images can be created from signed packages
         Product:     oe-core
         Author:      Daniel Istrate <daniel.alexandrux.istrate@intel.com>
-        Author:      Alexander Kanavin <alexander.kanavin@intel.com>
+        Author:      Alexander Kanavin <alex.kanavin@gmail.com>
         AutomatedBy: Daniel Istrate <daniel.alexandrux.istrate@intel.com>
         """
         import oe.packagedata
diff --git a/poky/meta/lib/oeqa/selftest/cases/sstatetests.py b/poky/meta/lib/oeqa/selftest/cases/sstatetests.py
index 7b008e4..077d6e5 100644
--- a/poky/meta/lib/oeqa/selftest/cases/sstatetests.py
+++ b/poky/meta/lib/oeqa/selftest/cases/sstatetests.py
@@ -262,6 +262,7 @@
         self.write_config("""
 MACHINE = "qemux86"
 TMPDIR = "${TOPDIR}/tmp-sstatesamehash"
+TCLIBCAPPEND = ""
 BUILD_ARCH = "x86_64"
 BUILD_OS = "linux"
 SDKMACHINE = "x86_64"
@@ -272,6 +273,7 @@
         self.write_config("""
 MACHINE = "qemux86"
 TMPDIR = "${TOPDIR}/tmp-sstatesamehash2"
+TCLIBCAPPEND = ""
 BUILD_ARCH = "i686"
 BUILD_OS = "linux"
 SDKMACHINE = "i686"
@@ -307,12 +309,14 @@
 
         self.write_config("""
 TMPDIR = \"${TOPDIR}/tmp-sstatesamehash\"
+TCLIBCAPPEND = \"\"
 NATIVELSBSTRING = \"DistroA\"
 """)
         self.track_for_cleanup(self.topdir + "/tmp-sstatesamehash")
         bitbake("core-image-sato -S none")
         self.write_config("""
 TMPDIR = \"${TOPDIR}/tmp-sstatesamehash2\"
+TCLIBCAPPEND = \"\"
 NATIVELSBSTRING = \"DistroB\"
 """)
         self.track_for_cleanup(self.topdir + "/tmp-sstatesamehash2")
@@ -340,25 +344,25 @@
 
         configA = """
 TMPDIR = \"${TOPDIR}/tmp-sstatesamehash\"
+TCLIBCAPPEND = \"\"
 MACHINE = \"qemux86-64\"
 """
         configB = """
 TMPDIR = \"${TOPDIR}/tmp-sstatesamehash2\"
+TCLIBCAPPEND = \"\"
 MACHINE = \"qemuarm\"
 """
         self.sstate_allarch_samesigs(configA, configB)
 
     @OETestID(1645)
-    def test_sstate_allarch_samesigs_multilib(self):
+    def test_sstate_nativesdk_samesigs_multilib(self):
         """
-        The sstate checksums of allarch multilib packages should be independent of whichever
-        MACHINE is set. Check this using bitbake -S.
-        Also, rather than duplicate the test, check nativesdk stamps are the same between
-        the two MACHINE values.
+        check nativesdk stamps are the same between the two MACHINE values.
         """
 
         configA = """
 TMPDIR = \"${TOPDIR}/tmp-sstatesamehash\"
+TCLIBCAPPEND = \"\"
 MACHINE = \"qemux86-64\"
 require conf/multilib.conf
 MULTILIBS = \"multilib:lib32\"
@@ -366,6 +370,7 @@
 """
         configB = """
 TMPDIR = \"${TOPDIR}/tmp-sstatesamehash2\"
+TCLIBCAPPEND = \"\"
 MACHINE = \"qemuarm\"
 require conf/multilib.conf
 MULTILIBS = \"\"
@@ -392,10 +397,6 @@
                         (_, task, _, shash) = name.rsplit(".", 3)
                         f[os.path.join(os.path.basename(root), task)] = shash
             return f
-        files1 = get_files(self.topdir + "/tmp-sstatesamehash/stamps/all" + self.target_vendor + "-" + self.target_os)
-        files2 = get_files(self.topdir + "/tmp-sstatesamehash2/stamps/all" + self.target_vendor + "-" + self.target_os)
-        self.maxDiff = None
-        self.assertEqual(files1, files2)
 
         nativesdkdir = os.path.basename(glob.glob(self.topdir + "/tmp-sstatesamehash/stamps/*-nativesdk*-linux")[0])
 
@@ -414,6 +415,7 @@
 
         self.write_config("""
 TMPDIR = \"${TOPDIR}/tmp-sstatesamehash\"
+TCLIBCAPPEND = \"\"
 MACHINE = \"qemux86\"
 require conf/multilib.conf
 MULTILIBS = "multilib:lib32"
@@ -423,6 +425,7 @@
         bitbake("world meta-toolchain -S none")
         self.write_config("""
 TMPDIR = \"${TOPDIR}/tmp-sstatesamehash2\"
+TCLIBCAPPEND = \"\"
 MACHINE = \"qemux86copy\"
 require conf/multilib.conf
 MULTILIBS = "multilib:lib32"
@@ -458,6 +461,7 @@
 
         self.write_config("""
 TMPDIR = "${TOPDIR}/tmp-sstatesamehash"
+TCLIBCAPPEND = ""
 BB_NUMBER_THREADS = "${@oe.utils.cpu_count()}"
 PARALLEL_MAKE = "-j 1"
 DL_DIR = "${TOPDIR}/download1"
@@ -471,6 +475,7 @@
         bitbake("world meta-toolchain -S none")
         self.write_config("""
 TMPDIR = "${TOPDIR}/tmp-sstatesamehash2"
+TCLIBCAPPEND = ""
 BB_NUMBER_THREADS = "${@oe.utils.cpu_count()+1}"
 PARALLEL_MAKE = "-j 2"
 DL_DIR = "${TOPDIR}/download2"
diff --git a/poky/meta/lib/oeqa/selftest/cases/wic.py b/poky/meta/lib/oeqa/selftest/cases/wic.py
index baf3af6..36ee5e5 100644
--- a/poky/meta/lib/oeqa/selftest/cases/wic.py
+++ b/poky/meta/lib/oeqa/selftest/cases/wic.py
@@ -61,94 +61,103 @@
     return wrapper
 
 
-class Wic(OESelftestTestCase):
+class WicTestCase(OESelftestTestCase):
     """Wic test class."""
 
     image_is_ready = False
-    native_sysroot = None
     wicenv_cache = {}
 
     def setUpLocal(self):
         """This code is executed before each test method."""
         self.resultdir = self.builddir + "/wic-tmp/"
-        super(Wic, self).setUpLocal()
-        if not self.native_sysroot:
-            Wic.native_sysroot = get_bb_var('STAGING_DIR_NATIVE', 'wic-tools')
+        super(WicTestCase, self).setUpLocal()
 
         # Do this here instead of in setUpClass as the base setUp does some
         # clean up which can result in the native tools built earlier in
         # setUpClass being unavailable.
-        if not Wic.image_is_ready:
+        if not WicTestCase.image_is_ready:
             if get_bb_var('USE_NLS') == 'yes':
                 bitbake('wic-tools')
             else:
                 self.skipTest('wic-tools cannot be built due its (intltool|gettext)-native dependency and NLS disable')
 
             bitbake('core-image-minimal')
-            Wic.image_is_ready = True
+            WicTestCase.image_is_ready = True
 
         rmtree(self.resultdir, ignore_errors=True)
 
     def tearDownLocal(self):
         """Remove resultdir as it may contain images."""
         rmtree(self.resultdir, ignore_errors=True)
-        super(Wic, self).tearDownLocal()
+        super(WicTestCase, self).tearDownLocal()
+
+    def _get_image_env_path(self, image):
+        """Generate and obtain the path to <image>.env"""
+        if image not in WicTestCase.wicenv_cache:
+            self.assertEqual(0, bitbake('%s -c do_rootfs_wicenv' % image).status)
+            bb_vars = get_bb_vars(['STAGING_DIR', 'MACHINE'], image)
+            stdir = bb_vars['STAGING_DIR']
+            machine = bb_vars['MACHINE']
+            WicTestCase.wicenv_cache[image] = os.path.join(stdir, machine, 'imgdata')
+        return WicTestCase.wicenv_cache[image]
+
+class Wic(WicTestCase):
 
     @OETestID(1552)
     def test_version(self):
         """Test wic --version"""
-        self.assertEqual(0, runCmd('wic --version').status)
+        runCmd('wic --version')
 
     @OETestID(1208)
     def test_help(self):
         """Test wic --help and wic -h"""
-        self.assertEqual(0, runCmd('wic --help').status)
-        self.assertEqual(0, runCmd('wic -h').status)
+        runCmd('wic --help')
+        runCmd('wic -h')
 
     @OETestID(1209)
     def test_createhelp(self):
         """Test wic create --help"""
-        self.assertEqual(0, runCmd('wic create --help').status)
+        runCmd('wic create --help')
 
     @OETestID(1210)
     def test_listhelp(self):
         """Test wic list --help"""
-        self.assertEqual(0, runCmd('wic list --help').status)
+        runCmd('wic list --help')
 
     @OETestID(1553)
     def test_help_create(self):
         """Test wic help create"""
-        self.assertEqual(0, runCmd('wic help create').status)
+        runCmd('wic help create')
 
     @OETestID(1554)
     def test_help_list(self):
         """Test wic help list"""
-        self.assertEqual(0, runCmd('wic help list').status)
+        runCmd('wic help list')
 
     @OETestID(1215)
     def test_help_overview(self):
         """Test wic help overview"""
-        self.assertEqual(0, runCmd('wic help overview').status)
+        runCmd('wic help overview')
 
     @OETestID(1216)
     def test_help_plugins(self):
         """Test wic help plugins"""
-        self.assertEqual(0, runCmd('wic help plugins').status)
+        runCmd('wic help plugins')
 
     @OETestID(1217)
     def test_help_kickstart(self):
         """Test wic help kickstart"""
-        self.assertEqual(0, runCmd('wic help kickstart').status)
+        runCmd('wic help kickstart')
 
     @OETestID(1555)
     def test_list_images(self):
         """Test wic list images"""
-        self.assertEqual(0, runCmd('wic list images').status)
+        runCmd('wic list images')
 
     @OETestID(1556)
     def test_list_source_plugins(self):
         """Test wic list source-plugins"""
-        self.assertEqual(0, runCmd('wic list source-plugins').status)
+        runCmd('wic list source-plugins')
 
     @OETestID(1557)
     def test_listed_images_help(self):
@@ -156,7 +165,7 @@
         output = runCmd('wic list images').output
         imagelist = [line.split()[0] for line in output.splitlines()]
         for image in imagelist:
-            self.assertEqual(0, runCmd('wic list %s help' % image).status)
+            runCmd('wic list %s help' % image)
 
     @OETestID(1213)
     def test_unsupported_subcommand(self):
@@ -172,7 +181,7 @@
     def test_build_image_name(self):
         """Test wic create wictestdisk --image-name=core-image-minimal"""
         cmd = "wic create wictestdisk --image-name=core-image-minimal -o %s" % self.resultdir
-        self.assertEqual(0, runCmd(cmd).status)
+        runCmd(cmd)
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*.direct")))
 
     @OETestID(1157)
@@ -180,7 +189,7 @@
     def test_gpt_image(self):
         """Test creation of core-image-minimal with gpt table and UUID boot"""
         cmd = "wic create directdisk-gpt --image-name core-image-minimal -o %s" % self.resultdir
-        self.assertEqual(0, runCmd(cmd).status)
+        runCmd(cmd)
         self.assertEqual(1, len(glob(self.resultdir + "directdisk-*.direct")))
 
     @OETestID(1346)
@@ -194,7 +203,7 @@
         bitbake('core-image-minimal core-image-minimal-initramfs')
         self.remove_config(config)
         cmd = "wic create mkhybridiso --image-name core-image-minimal -o %s" % self.resultdir
-        self.assertEqual(0, runCmd(cmd).status)
+        runCmd(cmd)
         self.assertEqual(1, len(glob(self.resultdir + "HYBRID_ISO_IMG-*.direct")))
         self.assertEqual(1, len(glob(self.resultdir + "HYBRID_ISO_IMG-*.iso")))
 
@@ -203,7 +212,7 @@
     def test_qemux86_directdisk(self):
         """Test creation of qemux-86-directdisk image"""
         cmd = "wic create qemux86-directdisk -e core-image-minimal -o %s" % self.resultdir
-        self.assertEqual(0, runCmd(cmd).status)
+        runCmd(cmd)
         self.assertEqual(1, len(glob(self.resultdir + "qemux86-directdisk-*direct")))
 
     @OETestID(1350)
@@ -211,7 +220,7 @@
     def test_mkefidisk(self):
         """Test creation of mkefidisk image"""
         cmd = "wic create mkefidisk -e core-image-minimal -o %s" % self.resultdir
-        self.assertEqual(0, runCmd(cmd).status)
+        runCmd(cmd)
         self.assertEqual(1, len(glob(self.resultdir + "mkefidisk-*direct")))
 
     @OETestID(1385)
@@ -223,7 +232,7 @@
         bitbake('core-image-minimal')
         self.remove_config(config)
         cmd = "wic create directdisk-bootloader-config -e core-image-minimal -o %s" % self.resultdir
-        self.assertEqual(0, runCmd(cmd).status)
+        runCmd(cmd)
         self.assertEqual(1, len(glob(self.resultdir + "directdisk-bootloader-config-*direct")))
 
     @OETestID(1560)
@@ -235,7 +244,7 @@
         bitbake('core-image-minimal')
         self.remove_config(config)
         cmd = "wic create systemd-bootdisk -e core-image-minimal -o %s" % self.resultdir
-        self.assertEqual(0, runCmd(cmd).status)
+        runCmd(cmd)
         self.assertEqual(1, len(glob(self.resultdir + "systemd-bootdisk-*direct")))
 
     @OETestID(1561)
@@ -244,7 +253,7 @@
         cmd = "wic create sdimage-bootpart -e core-image-minimal -o %s" % self.resultdir
         kimgtype = get_bb_var('KERNEL_IMAGETYPE', 'core-image-minimal')
         self.write_config('IMAGE_BOOT_FILES = "%s"\n' % kimgtype)
-        self.assertEqual(0, runCmd(cmd).status)
+        runCmd(cmd)
         self.assertEqual(1, len(glob(self.resultdir + "sdimage-bootpart-*direct")))
 
     @OETestID(1562)
@@ -258,7 +267,7 @@
         bitbake('core-image-minimal')
         self.remove_config(config)
         cmd = "wic create directdisk -e core-image-minimal"
-        self.assertEqual(0, runCmd(cmd).status)
+        runCmd(cmd)
         self.assertEqual(1, len(glob("directdisk-*.direct")))
 
     @OETestID(1212)
@@ -271,37 +280,36 @@
                                    'core-image-minimal'))
         bbvars = {key.lower(): value for key, value in bb_vars.items()}
         bbvars['resultdir'] = self.resultdir
-        status = runCmd("wic create directdisk "
+        runCmd("wic create directdisk "
                         "-b %(staging_datadir)s "
                         "-k %(deploy_dir_image)s "
                         "-n %(recipe_sysroot_native)s "
                         "-r %(image_rootfs)s "
-                        "-o %(resultdir)s" % bbvars).status
-        self.assertEqual(0, status)
+                        "-o %(resultdir)s" % bbvars)
         self.assertEqual(1, len(glob(self.resultdir + "directdisk-*.direct")))
 
     @OETestID(1264)
     def test_compress_gzip(self):
         """Test compressing an image with gzip"""
-        self.assertEqual(0, runCmd("wic create wictestdisk "
+        runCmd("wic create wictestdisk "
                                    "--image-name core-image-minimal "
-                                   "-c gzip -o %s" % self.resultdir).status)
+                                   "-c gzip -o %s" % self.resultdir)
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*.direct.gz")))
 
     @OETestID(1265)
     def test_compress_bzip2(self):
         """Test compressing an image with bzip2"""
-        self.assertEqual(0, runCmd("wic create wictestdisk "
+        runCmd("wic create wictestdisk "
                                    "--image-name=core-image-minimal "
-                                   "-c bzip2 -o %s" % self.resultdir).status)
+                                   "-c bzip2 -o %s" % self.resultdir)
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*.direct.bz2")))
 
     @OETestID(1266)
     def test_compress_xz(self):
         """Test compressing an image with xz"""
-        self.assertEqual(0, runCmd("wic create wictestdisk "
+        runCmd("wic create wictestdisk "
                                    "--image-name=core-image-minimal "
-                                   "--compress-with=xz -o %s" % self.resultdir).status)
+                                   "--compress-with=xz -o %s" % self.resultdir)
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*.direct.xz")))
 
     @OETestID(1267)
@@ -315,63 +323,62 @@
     @OETestID(1558)
     def test_debug_short(self):
         """Test -D option"""
-        self.assertEqual(0, runCmd("wic create wictestdisk "
+        runCmd("wic create wictestdisk "
                                    "--image-name=core-image-minimal "
-                                   "-D -o %s" % self.resultdir).status)
+                                   "-D -o %s" % self.resultdir)
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*.direct")))
 
     @OETestID(1658)
     def test_debug_long(self):
         """Test --debug option"""
-        self.assertEqual(0, runCmd("wic create wictestdisk "
+        runCmd("wic create wictestdisk "
                                    "--image-name=core-image-minimal "
-                                   "--debug -o %s" % self.resultdir).status)
+                                   "--debug -o %s" % self.resultdir)
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*.direct")))
 
     @OETestID(1563)
     def test_skip_build_check_short(self):
         """Test -s option"""
-        self.assertEqual(0, runCmd("wic create wictestdisk "
+        runCmd("wic create wictestdisk "
                                    "--image-name=core-image-minimal "
-                                   "-s -o %s" % self.resultdir).status)
+                                   "-s -o %s" % self.resultdir)
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*.direct")))
 
     @OETestID(1671)
     def test_skip_build_check_long(self):
         """Test --skip-build-check option"""
-        self.assertEqual(0, runCmd("wic create wictestdisk "
+        runCmd("wic create wictestdisk "
                                    "--image-name=core-image-minimal "
                                    "--skip-build-check "
-                                   "--outdir %s" % self.resultdir).status)
+                                   "--outdir %s" % self.resultdir)
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*.direct")))
 
     @OETestID(1564)
     def test_build_rootfs_short(self):
         """Test -f option"""
-        self.assertEqual(0, runCmd("wic create wictestdisk "
+        runCmd("wic create wictestdisk "
                                    "--image-name=core-image-minimal "
-                                   "-f -o %s" % self.resultdir).status)
+                                   "-f -o %s" % self.resultdir)
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*.direct")))
 
     @OETestID(1656)
     def test_build_rootfs_long(self):
         """Test --build-rootfs option"""
-        self.assertEqual(0, runCmd("wic create wictestdisk "
+        runCmd("wic create wictestdisk "
                                    "--image-name=core-image-minimal "
                                    "--build-rootfs "
-                                   "--outdir %s" % self.resultdir).status)
+                                   "--outdir %s" % self.resultdir)
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*.direct")))
 
     @OETestID(1268)
     @only_for_arch(['i586', 'i686', 'x86_64'])
     def test_rootfs_indirect_recipes(self):
         """Test usage of rootfs plugin with rootfs recipes"""
-        status = runCmd("wic create directdisk-multi-rootfs "
+        runCmd("wic create directdisk-multi-rootfs "
                         "--image-name=core-image-minimal "
                         "--rootfs rootfs1=core-image-minimal "
                         "--rootfs rootfs2=core-image-minimal "
-                        "--outdir %s" % self.resultdir).status
-        self.assertEqual(0, status)
+                        "--outdir %s" % self.resultdir)
         self.assertEqual(1, len(glob(self.resultdir + "directdisk-multi-rootfs*.direct")))
 
     @OETestID(1269)
@@ -385,14 +392,13 @@
         bbvars = {key.lower(): value for key, value in bb_vars.items()}
         bbvars['wks'] = "directdisk-multi-rootfs"
         bbvars['resultdir'] = self.resultdir
-        status = runCmd("wic create %(wks)s "
+        runCmd("wic create %(wks)s "
                         "--bootimg-dir=%(staging_datadir)s "
                         "--kernel-dir=%(deploy_dir_image)s "
                         "--native-sysroot=%(recipe_sysroot_native)s "
                         "--rootfs-dir rootfs1=%(image_rootfs)s "
                         "--rootfs-dir rootfs2=%(image_rootfs)s "
-                        "--outdir %(resultdir)s" % bbvars).status
-        self.assertEqual(0, status)
+                        "--outdir %(resultdir)s" % bbvars)
         self.assertEqual(1, len(glob(self.resultdir + "%(wks)s-*.direct" % bbvars)))
 
     @OETestID(1661)
@@ -411,8 +417,8 @@
 part /usr --source rootfs --ondisk mmcblk0 --fstype=ext4 --rootfs-dir %s/usr
 part /etc --source rootfs --ondisk mmcblk0 --fstype=ext4 --exclude-path bin/ --rootfs-dir %s/usr"""
                           % (rootfs_dir, rootfs_dir))
-            self.assertEqual(0, runCmd("wic create %s -e core-image-minimal -o %s" \
-                                       % (wks_file, self.resultdir)).status)
+            runCmd("wic create %s -e core-image-minimal -o %s" \
+                                       % (wks_file, self.resultdir))
 
             os.remove(wks_file)
             wicout = glob(self.resultdir + "%s-*direct" % 'temp')
@@ -422,7 +428,6 @@
 
             # verify partition size with wic
             res = runCmd("parted -m %s unit b p 2>/dev/null" % wicimg)
-            self.assertEqual(0, res.status)
 
             # parse parted output which looks like this:
             # BYT;\n
@@ -438,8 +443,8 @@
                 self.assertEqual(7, len(partln))
                 start = int(partln[1].rstrip("B")) / 512
                 length = int(partln[3].rstrip("B")) / 512
-                self.assertEqual(0, runCmd("dd if=%s of=%s skip=%d count=%d" %
-                                           (wicimg, part_file, start, length)).status)
+                runCmd("dd if=%s of=%s skip=%d count=%d" %
+                                           (wicimg, part_file, start, length))
 
             def extract_files(debugfs_output):
                 """
@@ -463,7 +468,6 @@
             # /usr.
             res = runCmd("debugfs -R 'ls -p' %s 2>/dev/null" % \
                              os.path.join(self.resultdir, "selftest_img.part1"))
-            self.assertEqual(0, res.status)
             files = extract_files(res.output)
             self.assertIn("etc", files)
             self.assertNotIn("usr", files)
@@ -472,7 +476,6 @@
             # directories.
             res = runCmd("debugfs -R 'ls -p' %s 2>/dev/null" % \
                              os.path.join(self.resultdir, "selftest_img.part2"))
-            self.assertEqual(0, res.status)
             files = extract_files(res.output)
             self.assertNotIn("etc", files)
             self.assertNotIn("usr", files)
@@ -482,7 +485,6 @@
             # directory, but not the files inside it.
             res = runCmd("debugfs -R 'ls -p' %s 2>/dev/null" % \
                              os.path.join(self.resultdir, "selftest_img.part3"))
-            self.assertEqual(0, res.status)
             files = extract_files(res.output)
             self.assertNotIn("etc", files)
             self.assertNotIn("usr", files)
@@ -490,7 +492,6 @@
             self.assertIn("bin", files)
             res = runCmd("debugfs -R 'ls -p bin' %s 2>/dev/null" % \
                              os.path.join(self.resultdir, "selftest_img.part3"))
-            self.assertEqual(0, res.status)
             files = extract_files(res.output)
             self.assertIn(".", files)
             self.assertIn("..", files)
@@ -522,12 +523,13 @@
                                       % (wks_file, self.resultdir), ignore_status=True).status)
         os.remove(wks_file)
 
+class Wic2(WicTestCase):
+
     @OETestID(1496)
     def test_bmap_short(self):
         """Test generation of .bmap file -m option"""
         cmd = "wic create wictestdisk -e core-image-minimal -m -o %s" % self.resultdir
-        status = runCmd(cmd).status
-        self.assertEqual(0, status)
+        runCmd(cmd)
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*direct")))
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*direct.bmap")))
 
@@ -535,21 +537,10 @@
     def test_bmap_long(self):
         """Test generation of .bmap file --bmap option"""
         cmd = "wic create wictestdisk -e core-image-minimal --bmap -o %s" % self.resultdir
-        status = runCmd(cmd).status
-        self.assertEqual(0, status)
+        runCmd(cmd)
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*direct")))
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*direct.bmap")))
 
-    def _get_image_env_path(self, image):
-        """Generate and obtain the path to <image>.env"""
-        if image not in self.wicenv_cache:
-            self.assertEqual(0, bitbake('%s -c do_rootfs_wicenv' % image).status)
-            bb_vars = get_bb_vars(['STAGING_DIR', 'MACHINE'], image)
-            stdir = bb_vars['STAGING_DIR']
-            machine = bb_vars['MACHINE']
-            self.wicenv_cache[image] = os.path.join(stdir, machine, 'imgdata')
-        return self.wicenv_cache[image]
-
     @OETestID(1347)
     def test_image_env(self):
         """Test generation of <image>.env files."""
@@ -580,10 +571,10 @@
         imgenvdir = self._get_image_env_path(image)
         native_sysroot = get_bb_var("RECIPE_SYSROOT_NATIVE", "wic-tools")
 
-        self.assertEqual(0, runCmd("wic create wictestdisk "
+        runCmd("wic create wictestdisk "
                                    "--image-name=%s -v %s -n %s -o %s"
                                    % (image, imgenvdir, native_sysroot,
-                                      self.resultdir)).status)
+                                      self.resultdir))
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*direct")))
 
     @OETestID(1665)
@@ -593,13 +584,13 @@
         imgenvdir = self._get_image_env_path(image)
         native_sysroot = get_bb_var("RECIPE_SYSROOT_NATIVE", "wic-tools")
 
-        self.assertEqual(0, runCmd("wic create wictestdisk "
+        runCmd("wic create wictestdisk "
                                    "--image-name=%s "
                                    "--vars %s "
                                    "--native-sysroot %s "
                                    "--outdir %s"
                                    % (image, imgenvdir, native_sysroot,
-                                      self.resultdir)).status)
+                                      self.resultdir))
         self.assertEqual(1, len(glob(self.resultdir + "wictestdisk-*direct")))
 
     @OETestID(1351)
@@ -679,19 +670,21 @@
         Test creation of a simple image with partition size controlled through
         --fixed-size flag
         """
-        wkspath, wksname = Wic._make_fixed_size_wks(200)
+        wkspath, wksname = Wic2._make_fixed_size_wks(200)
 
-        self.assertEqual(0, runCmd("wic create %s -e core-image-minimal -o %s" \
-                                   % (wkspath, self.resultdir)).status)
+        runCmd("wic create %s -e core-image-minimal -o %s" \
+                                   % (wkspath, self.resultdir))
         os.remove(wkspath)
         wicout = glob(self.resultdir + "%s-*direct" % wksname)
         self.assertEqual(1, len(wicout))
 
         wicimg = wicout[0]
 
+        native_sysroot = get_bb_var("RECIPE_SYSROOT_NATIVE", "wic-tools")
+
         # verify partition size with wic
         res = runCmd("parted -m %s unit mib p 2>/dev/null" % wicimg,
-                     native_sysroot=self.native_sysroot)
+                     native_sysroot=native_sysroot)
 
         # parse parted output which looks like this:
         # BYT;\n
@@ -709,7 +702,7 @@
         --fixed-size flag. The size of partition is intentionally set to 1MiB
         in order to trigger an error in wic.
         """
-        wkspath, wksname = Wic._make_fixed_size_wks(1)
+        wkspath, wksname = Wic2._make_fixed_size_wks(1)
 
         self.assertEqual(1, runCmd("wic create %s -e core-image-minimal -o %s" \
                                    % (wkspath, self.resultdir), ignore_status=True).status)
@@ -746,7 +739,7 @@
                             'bootloader --timeout=0 --append="console=ttyS0,115200n8"\n'])
             wks.flush()
             cmd = "wic create %s -e %s -o %s" % (wks.name, img, self.resultdir)
-            self.assertEqual(0, runCmd(cmd).status)
+            runCmd(cmd)
             wksname = os.path.splitext(os.path.basename(wks.name))[0]
             out = glob(self.resultdir + "%s-*direct" % wksname)
             self.assertEqual(1, len(out))
@@ -763,10 +756,10 @@
                             'part emptyvfat   --fstype vfat   --size 1M\n',
                             'part emptymsdos  --fstype msdos  --size 1M\n',
                             'part emptyext2   --fstype ext2   --size 1M\n',
-                            'part emptybtrfs  --fstype btrfs  --size 100M\n'])
+                            'part emptybtrfs  --fstype btrfs  --size 150M\n'])
             wks.flush()
             cmd = "wic create %s -e %s -o %s" % (wks.name, img, self.resultdir)
-            self.assertEqual(0, runCmd(cmd).status)
+            runCmd(cmd)
             wksname = os.path.splitext(os.path.basename(wks.name))[0]
             out = glob(self.resultdir + "%s-*direct" % wksname)
             self.assertEqual(1, len(out))
@@ -779,7 +772,7 @@
                             '--overhead-factor 1.2 --size 100k\n'])
             wks.flush()
             cmd = "wic create %s -e core-image-minimal -o %s" % (wks.name, self.resultdir)
-            self.assertEqual(0, runCmd(cmd).status)
+            runCmd(cmd)
             wksname = os.path.splitext(os.path.basename(wks.name))[0]
             out = glob(self.resultdir + "%s-*direct" % wksname)
             self.assertEqual(1, len(out))
@@ -791,7 +784,7 @@
         cmd = "wic create sdimage-bootpart -e %s -o %s" % (img, self.resultdir)
         config = 'IMAGE_BOOT_FILES = "%s*"' % get_bb_var('KERNEL_IMAGETYPE', img)
         self.append_config(config)
-        self.assertEqual(0, runCmd(cmd).status)
+        runCmd(cmd)
         self.remove_config(config)
         self.assertEqual(1, len(glob(self.resultdir + "sdimage-bootpart-*direct")))
 
@@ -827,9 +820,9 @@
     @OETestID(1857)
     def test_wic_ls(self):
         """Test listing image content using 'wic ls'"""
-        self.assertEqual(0, runCmd("wic create wictestdisk "
+        runCmd("wic create wictestdisk "
                                    "--image-name=core-image-minimal "
-                                   "-D -o %s" % self.resultdir).status)
+                                   "-D -o %s" % self.resultdir)
         images = glob(self.resultdir + "wictestdisk-*.direct")
         self.assertEqual(1, len(images))
 
@@ -837,20 +830,18 @@
 
         # list partitions
         result = runCmd("wic ls %s -n %s" % (images[0], sysroot))
-        self.assertEqual(0, result.status)
         self.assertEqual(3, len(result.output.split('\n')))
 
         # list directory content of the first partition
         result = runCmd("wic ls %s:1/ -n %s" % (images[0], sysroot))
-        self.assertEqual(0, result.status)
         self.assertEqual(6, len(result.output.split('\n')))
 
     @OETestID(1856)
     def test_wic_cp(self):
         """Test copy files and directories to the the wic image."""
-        self.assertEqual(0, runCmd("wic create wictestdisk "
+        runCmd("wic create wictestdisk "
                                    "--image-name=core-image-minimal "
-                                   "-D -o %s" % self.resultdir).status)
+                                   "-D -o %s" % self.resultdir)
         images = glob(self.resultdir + "wictestdisk-*.direct")
         self.assertEqual(1, len(images))
 
@@ -858,19 +849,16 @@
 
         # list directory content of the first partition
         result = runCmd("wic ls %s:1/ -n %s" % (images[0], sysroot))
-        self.assertEqual(0, result.status)
         self.assertEqual(6, len(result.output.split('\n')))
 
         with NamedTemporaryFile("w", suffix=".wic-cp") as testfile:
             testfile.write("test")
 
             # copy file to the partition
-            result = runCmd("wic cp %s %s:1/ -n %s" % (testfile.name, images[0], sysroot))
-            self.assertEqual(0, result.status)
+            runCmd("wic cp %s %s:1/ -n %s" % (testfile.name, images[0], sysroot))
 
             # check if file is there
             result = runCmd("wic ls %s:1/ -n %s" % (images[0], sysroot))
-            self.assertEqual(0, result.status)
             self.assertEqual(7, len(result.output.split('\n')))
             self.assertTrue(os.path.basename(testfile.name) in result.output)
 
@@ -881,21 +869,19 @@
             copy(testfile.name, testdir)
 
             # copy directory to the partition
-            result = runCmd("wic cp %s %s:1/ -n %s" % (testdir, images[0], sysroot))
-            self.assertEqual(0, result.status)
+            runCmd("wic cp %s %s:1/ -n %s" % (testdir, images[0], sysroot))
 
             # check if directory is there
             result = runCmd("wic ls %s:1/ -n %s" % (images[0], sysroot))
-            self.assertEqual(0, result.status)
             self.assertEqual(8, len(result.output.split('\n')))
             self.assertTrue(os.path.basename(testdir) in result.output)
 
     @OETestID(1858)
     def test_wic_rm(self):
         """Test removing files and directories from the the wic image."""
-        self.assertEqual(0, runCmd("wic create mkefidisk "
+        runCmd("wic create mkefidisk "
                                    "--image-name=core-image-minimal "
-                                   "-D -o %s" % self.resultdir).status)
+                                   "-D -o %s" % self.resultdir)
         images = glob(self.resultdir + "mkefidisk-*.direct")
         self.assertEqual(1, len(images))
 
@@ -903,21 +889,17 @@
 
         # list directory content of the first partition
         result = runCmd("wic ls %s:1 -n %s" % (images[0], sysroot))
-        self.assertEqual(0, result.status)
         self.assertIn('\nBZIMAGE        ', result.output)
         self.assertIn('\nEFI          <DIR>     ', result.output)
 
         # remove file
-        result = runCmd("wic rm %s:1/bzimage -n %s" % (images[0], sysroot))
-        self.assertEqual(0, result.status)
+        runCmd("wic rm %s:1/bzimage -n %s" % (images[0], sysroot))
 
         # remove directory
-        result = runCmd("wic rm %s:1/efi -n %s" % (images[0], sysroot))
-        self.assertEqual(0, result.status)
+        runCmd("wic rm %s:1/efi -n %s" % (images[0], sysroot))
 
         # check if they're removed
         result = runCmd("wic ls %s:1 -n %s" % (images[0], sysroot))
-        self.assertEqual(0, result.status)
         self.assertNotIn('\nBZIMAGE        ', result.output)
         self.assertNotIn('\nEFI          <DIR>     ', result.output)
 
@@ -936,7 +918,7 @@
                  'part emptybtrfs  --fstype btrfs  --size 100M --mkfs-extraopts "--mixed -K"\n'])
             wks.flush()
             cmd = "wic create %s -e %s -o %s" % (wks.name, img, self.resultdir)
-            self.assertEqual(0, runCmd(cmd).status)
+            runCmd(cmd)
             wksname = os.path.splitext(os.path.basename(wks.name))[0]
             out = glob(self.resultdir + "%s-*direct" % wksname)
             self.assertEqual(1, len(out))
@@ -966,7 +948,7 @@
 
             sysroot = get_bb_var('RECIPE_SYSROOT_NATIVE', 'wic-tools')
             cmd = "wic write -n %s --expand 1:0 %s %s" % (sysroot, image_path, new_image_path)
-            self.assertEqual(0, runCmd(cmd).status)
+            runCmd(cmd)
 
             # check if partitions are expanded
             orig = runCmd("wic ls %s -n %s" % (image_path, sysroot))
@@ -996,9 +978,9 @@
 
     def test_wic_ls_ext(self):
         """Test listing content of the ext partition using 'wic ls'"""
-        self.assertEqual(0, runCmd("wic create wictestdisk "
+        runCmd("wic create wictestdisk "
                                    "--image-name=core-image-minimal "
-                                   "-D -o %s" % self.resultdir).status)
+                                   "-D -o %s" % self.resultdir)
         images = glob(self.resultdir + "wictestdisk-*.direct")
         self.assertEqual(1, len(images))
 
@@ -1006,15 +988,14 @@
 
         # list directory content of the second ext4 partition
         result = runCmd("wic ls %s:2/ -n %s" % (images[0], sysroot))
-        self.assertEqual(0, result.status)
         self.assertTrue(set(['bin', 'home', 'proc', 'usr', 'var', 'dev', 'lib', 'sbin']).issubset(
                             set(line.split()[-1] for line in result.output.split('\n') if line)))
 
     def test_wic_cp_ext(self):
         """Test copy files and directories to the ext partition."""
-        self.assertEqual(0, runCmd("wic create wictestdisk "
+        runCmd("wic create wictestdisk "
                                    "--image-name=core-image-minimal "
-                                   "-D -o %s" % self.resultdir).status)
+                                   "-D -o %s" % self.resultdir)
         images = glob(self.resultdir + "wictestdisk-*.direct")
         self.assertEqual(1, len(images))
 
@@ -1022,7 +1003,6 @@
 
         # list directory content of the ext4 partition
         result = runCmd("wic ls %s:2/ -n %s" % (images[0], sysroot))
-        self.assertEqual(0, result.status)
         dirs = set(line.split()[-1] for line in result.output.split('\n') if line)
         self.assertTrue(set(['bin', 'home', 'proc', 'usr', 'var', 'dev', 'lib', 'sbin']).issubset(dirs))
 
@@ -1030,20 +1010,18 @@
             testfile.write("test")
 
             # copy file to the partition
-            result = runCmd("wic cp %s %s:2/ -n %s" % (testfile.name, images[0], sysroot))
-            self.assertEqual(0, result.status)
+            runCmd("wic cp %s %s:2/ -n %s" % (testfile.name, images[0], sysroot))
 
             # check if file is there
             result = runCmd("wic ls %s:2/ -n %s" % (images[0], sysroot))
-            self.assertEqual(0, result.status)
             newdirs = set(line.split()[-1] for line in result.output.split('\n') if line)
             self.assertEqual(newdirs.difference(dirs), set([os.path.basename(testfile.name)]))
 
     def test_wic_rm_ext(self):
         """Test removing files from the ext partition."""
-        self.assertEqual(0, runCmd("wic create mkefidisk "
+        runCmd("wic create mkefidisk "
                                    "--image-name=core-image-minimal "
-                                   "-D -o %s" % self.resultdir).status)
+                                   "-D -o %s" % self.resultdir)
         images = glob(self.resultdir + "mkefidisk-*.direct")
         self.assertEqual(1, len(images))
 
@@ -1051,14 +1029,11 @@
 
         # list directory content of the /etc directory on ext4 partition
         result = runCmd("wic ls %s:2/etc/ -n %s" % (images[0], sysroot))
-        self.assertEqual(0, result.status)
         self.assertTrue('fstab' in [line.split()[-1] for line in result.output.split('\n') if line])
 
         # remove file
-        result = runCmd("wic rm %s:2/etc/fstab -n %s" % (images[0], sysroot))
-        self.assertEqual(0, result.status)
+        runCmd("wic rm %s:2/etc/fstab -n %s" % (images[0], sysroot))
 
         # check if it's removed
         result = runCmd("wic ls %s:2/etc/ -n %s" % (images[0], sysroot))
-        self.assertEqual(0, result.status)
         self.assertTrue('fstab' not in [line.split()[-1] for line in result.output.split('\n') if line])
diff --git a/poky/meta/lib/oeqa/selftest/context.py b/poky/meta/lib/oeqa/selftest/context.py
index 9a56888..c521290 100644
--- a/poky/meta/lib/oeqa/selftest/context.py
+++ b/poky/meta/lib/oeqa/selftest/context.py
@@ -11,6 +11,7 @@
 from random import choice
 
 import oeqa
+import oe
 
 from oeqa.core.context import OETestContext, OETestContextExecutor
 from oeqa.core.exception import OEQAPreRun, OEQATestNotFound
@@ -25,14 +26,14 @@
         self.custommachine = None
         self.config_paths = config_paths
 
-    def runTests(self, machine=None, skips=[]):
+    def runTests(self, processes=None, machine=None, skips=[]):
         if machine:
             self.custommachine = machine
             if machine == 'random':
                 self.custommachine = choice(self.machines)
             self.logger.info('Run tests with custom MACHINE set to: %s' % \
                     self.custommachine)
-        return super(OESelftestTestContext, self).runTests(skips)
+        return super(OESelftestTestContext, self).runTests(processes, skips)
 
     def listTests(self, display_type, machine=None):
         return super(OESelftestTestContext, self).listTests(display_type)
@@ -68,6 +69,9 @@
                 action="store_true", default=False,
                 help='List all available tests.')
 
+        parser.add_argument('-j', '--num-processes', dest='processes', action='store',
+                type=int, help="number of processes to execute in parallel with")
+
         parser.add_argument('--machine', required=False, choices=['random', 'all'],
                             help='Run tests on different machines (random/all).')
         
@@ -96,7 +100,6 @@
         return cases_paths
 
     def _process_args(self, logger, args):
-
         args.test_start_time = time.strftime("%Y%m%d%H%M%S")
         args.test_data_file = None
         args.CASES_PATHS = None
@@ -143,6 +146,7 @@
                 self.tc_kwargs['init']['config_paths']['bblayers_backup'])
 
         self.tc_kwargs['run']['skips'] = args.skips
+        self.tc_kwargs['run']['processes'] = args.processes
 
     def _pre_run(self):
         def _check_required_env_variables(vars):
@@ -158,7 +162,7 @@
                 os.chdir(builddir)
 
             if not "meta-selftest" in self.tc.td["BBLAYERS"]:
-                self.tc.logger.warn("meta-selftest layer not found in BBLAYERS, adding it")
+                self.tc.logger.warning("meta-selftest layer not found in BBLAYERS, adding it")
                 meta_selftestdir = os.path.join(
                     self.tc.td["BBLAYERS_FETCH_DIR"], 'meta-selftest')
                 if os.path.isdir(meta_selftestdir):
@@ -189,6 +193,10 @@
             self.tc.logger.error("You have buildhistory enabled already and this isn't recommended for selftest, please disable it first.")
             raise OEQAPreRun
 
+        if "rm_work.bbclass" in self.tc.td["BBINCLUDED"]:
+            self.tc.logger.error("You have rm_work enabled which isn't recommended while running oe-selftest. Please disable it before continuing.")
+            raise OEQAPreRun
+
         if "PRSERV_HOST" in self.tc.td:
             self.tc.logger.error("Please unset PRSERV_HOST in order to run oe-selftest")
             raise OEQAPreRun
@@ -199,8 +207,8 @@
 
         _add_layer_libs()
 
-        self.tc.logger.info("Running bitbake -p")
-        runCmd("bitbake -p")
+        self.tc.logger.info("Running bitbake -e to test the configuration is valid/parsable")
+        runCmd("bitbake -e")
 
     def get_json_result_dir(self, args):
         json_result_dir = os.path.join(self.tc.td["LOG_DIR"], 'oeqa')
@@ -216,7 +224,7 @@
         configuration = {'TEST_TYPE': 'oeselftest',
                         'STARTTIME': args.test_start_time,
                         'MACHINE': self.tc.td["MACHINE"],
-                        'HOST_DISTRO': ('-'.join(platform.linux_distribution())).replace(' ', '-'),
+                        'HOST_DISTRO': oe.lsb.distro_identifier().replace(' ', '-'),
                         'HOST_NAME': metadata['hostname'],
                         'LAYERS': metadata['layers']}
         return configuration
diff --git a/poky/meta/lib/oeqa/utils/httpserver.py b/poky/meta/lib/oeqa/utils/httpserver.py
index 7d12331..a48d499 100644
--- a/poky/meta/lib/oeqa/utils/httpserver.py
+++ b/poky/meta/lib/oeqa/utils/httpserver.py
@@ -1,13 +1,13 @@
 import http.server
 import multiprocessing
 import os
+import traceback
+import signal
 from socketserver import ThreadingMixIn
 
 class HTTPServer(ThreadingMixIn, http.server.HTTPServer):
 
-    def server_start(self, root_dir):
-        import signal
-        signal.signal(signal.SIGTERM, signal.SIG_DFL)
+    def server_start(self, root_dir, logger):
         os.chdir(root_dir)
         self.serve_forever()
 
@@ -18,19 +18,40 @@
 
 class HTTPService(object):
 
-    def __init__(self, root_dir, host=''):
+    def __init__(self, root_dir, host='', logger=None):
         self.root_dir = root_dir
         self.host = host
         self.port = 0
+        self.logger = logger
 
     def start(self):
+        if not os.path.exists(self.root_dir):
+            self.logger.info("Not starting HTTPService for directory %s which doesn't exist" % (self.root_dir))
+            return
+
         self.server = HTTPServer((self.host, self.port), HTTPRequestHandler)
         if self.port == 0:
             self.port = self.server.server_port
-        self.process = multiprocessing.Process(target=self.server.server_start, args=[self.root_dir])
+        self.process = multiprocessing.Process(target=self.server.server_start, args=[self.root_dir, self.logger])
+
+        # The signal handler from testimage.bbclass can cause deadlocks here
+        # if the HTTPServer is terminated before it can restore the standard 
+        #signal behaviour
+        orig = signal.getsignal(signal.SIGTERM)
+        signal.signal(signal.SIGTERM, signal.SIG_DFL)
         self.process.start()
+        signal.signal(signal.SIGTERM, orig)
+
+        if self.logger:
+            self.logger.info("Started HTTPService on %s:%s" % (self.host, self.port))
+
 
     def stop(self):
-        self.server.server_close()
-        self.process.terminate()
-        self.process.join()
+        if hasattr(self, "server"):
+            self.server.server_close()
+        if hasattr(self, "process"):
+            self.process.terminate()
+            self.process.join()
+        if self.logger:
+            self.logger.info("Stopped HTTPService on %s:%s" % (self.host, self.port))
+
diff --git a/poky/meta/lib/oeqa/utils/package_manager.py b/poky/meta/lib/oeqa/utils/package_manager.py
index afd5b8e..1495f87 100644
--- a/poky/meta/lib/oeqa/utils/package_manager.py
+++ b/poky/meta/lib/oeqa/utils/package_manager.py
@@ -22,13 +22,15 @@
         pm = OpkgPM(d,
                     root_path,
                     d.getVar("IPKGCONF_TARGET"),
-                    d.getVar("ALL_MULTILIB_PACKAGE_ARCHS"))
+                    d.getVar("ALL_MULTILIB_PACKAGE_ARCHS"),
+                    filterbydependencies=False)
 
     elif pkg_class == "deb":
         pm = DpkgPM(d,
                     root_path,
                     d.getVar('PACKAGE_ARCHS'),
-                    d.getVar('DPKG_ARCH'))
+                    d.getVar('DPKG_ARCH'),
+                    filterbydependencies=False)
 
     pm.write_index()
     pm.update()
diff --git a/poky/meta/lib/oeqa/utils/qemurunner.py b/poky/meta/lib/oeqa/utils/qemurunner.py
index b87d776..c7442a2 100644
--- a/poky/meta/lib/oeqa/utils/qemurunner.py
+++ b/poky/meta/lib/oeqa/utils/qemurunner.py
@@ -350,10 +350,10 @@
         return True
 
     def stop(self):
-        self.stop_thread()
-        self.stop_qemu_system()
         if hasattr(self, "origchldhandler"):
             signal.signal(signal.SIGCHLD, self.origchldhandler)
+        self.stop_thread()
+        self.stop_qemu_system()
         if self.runqemu:
             if hasattr(self, "monitorpid"):
                 os.kill(self.monitorpid, signal.SIGKILL)
@@ -392,7 +392,7 @@
                 # qemu-system behaves well and a SIGTERM is enough
                 os.kill(self.qemupid, signal.SIGTERM)
             except ProcessLookupError as e:
-                self.logger.warn('qemu-system ended unexpectedly')
+                self.logger.warning('qemu-system ended unexpectedly')
 
     def stop_thread(self):
         if self.thread and self.thread.is_alive():
@@ -408,7 +408,7 @@
         return False
 
     def is_alive(self):
-        if not self.runqemu:
+        if not self.runqemu or self.runqemu.poll() is not None:
             return False
         if os.path.isfile(self.qemu_pidfile):
             f = open(self.qemu_pidfile, 'r')
@@ -469,7 +469,7 @@
 
     def _dump_host(self):
         self.host_dumper.create_dir("qemu")
-        self.logger.warn("Qemu ended unexpectedly, dump data from host"
+        self.logger.warning("Qemu ended unexpectedly, dump data from host"
                 " is in %s" % self.host_dumper.dump_dir)
         self.host_dumper.dump_host()
 
diff --git a/poky/meta/recipes-bsp/acpid/acpid_2.0.28.bb b/poky/meta/recipes-bsp/acpid/acpid_2.0.28.bb
deleted file mode 100644
index 686526f..0000000
--- a/poky/meta/recipes-bsp/acpid/acpid_2.0.28.bb
+++ /dev/null
@@ -1,7 +0,0 @@
-require acpid.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=8ca43cbc842c2336e835926c2166c28b \
-                    file://acpid.h;endline=24;md5=324a9cf225ae69ddaad1bf9d942115b5"
-
-SRC_URI[md5sum] = "0432407b5ff75ae8e08afb43052fde2b"
-SRC_URI[sha256sum] = "980c3a54b0d3f2fd49fd845a0584c5c2abeaab9e9ac09fcbb68686bbb57a7110"
diff --git a/poky/meta/recipes-bsp/acpid/acpid_2.0.30.bb b/poky/meta/recipes-bsp/acpid/acpid_2.0.30.bb
new file mode 100644
index 0000000..aa19d28
--- /dev/null
+++ b/poky/meta/recipes-bsp/acpid/acpid_2.0.30.bb
@@ -0,0 +1,7 @@
+require acpid.inc
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=8ca43cbc842c2336e835926c2166c28b \
+                    file://acpid.h;endline=24;md5=324a9cf225ae69ddaad1bf9d942115b5"
+
+SRC_URI[md5sum] = "1528040b5d34f8c24ebabd97befbf913"
+SRC_URI[sha256sum] = "28b77b62d3f64ebd1c2a3d16bccc6d4333b4e24a86aeacebec255fad223cf4cb"
diff --git a/poky/meta/recipes-bsp/apmd/apmd/legacy.patch b/poky/meta/recipes-bsp/apmd/apmd/legacy.patch
index 5db895e..8871311 100644
--- a/poky/meta/recipes-bsp/apmd/apmd/legacy.patch
+++ b/poky/meta/recipes-bsp/apmd/apmd/legacy.patch
@@ -7,7 +7,7 @@
 ftp://ftp.debian.org/debian/pool/main/a/apmd/apmd_3.2.2-15.debian.tar.xz
 
 Upstream-Status: Inappropriate [upstream is dead]
-Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
 
 ---
  Makefile |  2 +-
diff --git a/poky/meta/recipes-bsp/eee-acpi-scripts/eee-acpi-scripts_git.bb b/poky/meta/recipes-bsp/eee-acpi-scripts/eee-acpi-scripts_git.bb
deleted file mode 100644
index c2a02aa..0000000
--- a/poky/meta/recipes-bsp/eee-acpi-scripts/eee-acpi-scripts_git.bb
+++ /dev/null
@@ -1,39 +0,0 @@
-SUMMARY = "eeePC specific ACPI scripts"
-HOMEPAGE = "http://alioth.debian.org/projects/debian-eeepc/"
-SECTION = "base"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://debian/copyright;md5=77ef83ab5f4af938a93edb61f7b74f2c"
-
-SRCREV = "9d4cdedca25b396405f8587f9c4fbf8229e041c2"
-PV = "1.1.12+git${SRCPV}"
-
-SRC_URI = "git://git.debian.org/git/debian-eeepc/eeepc-acpi-scripts.git \
-	   file://remove-doc-check.patch \
-	   file://powerbtn.patch \
-	   file://policy-funcs "
-
-S = "${WORKDIR}/git"
-
-FILES_${PN} = "${datadir}/acpi-support/ \
-               ${datadir}/eeepc-acpi-scripts \
-               ${sysconfdir}/default/ \
-               ${sysconfdir}/acpi/"
-
-do_install () {
-	install -d ${D}${sysconfdir}/default/
-	install -d ${D}${sysconfdir}/acpi/actions/
-	install -d ${D}${sysconfdir}/acpi/events/
-	install -d ${D}${sysconfdir}/acpi/lib/udev/rules.d
-	install -d ${D}${datadir}/eeepc-acpi-scripts/
-	install -d ${D}${datadir}/acpi-support/
-	install -m 644 ${S}/events/* ${D}${sysconfdir}/acpi/events/
-	install -m 644 ${S}/lib/udev/rules.d/* ${D}${sysconfdir}/acpi/lib/udev/rules.d/
-	install ${S}/actions/* ${D}${sysconfdir}/acpi/actions/
-	install -m 0644 ${S}/acpilib/functions.sh ${D}${datadir}/eeepc-acpi-scripts/
-	install -m 0644 ${WORKDIR}/policy-funcs ${D}${datadir}/acpi-support/
-	install -m 0644 ${S}/debian/eeepc-acpi-scripts.default* ${D}${sysconfdir}/default/
-}
-
-RDEPENDS_${PN} = "pm-utils"
-
diff --git a/poky/meta/recipes-bsp/eee-acpi-scripts/files/policy-funcs b/poky/meta/recipes-bsp/eee-acpi-scripts/files/policy-funcs
deleted file mode 100644
index fd099df..0000000
--- a/poky/meta/recipes-bsp/eee-acpi-scripts/files/policy-funcs
+++ /dev/null
@@ -1,8 +0,0 @@
-CheckPolicy() {
-	if pidof gnome-power-manager kpowersave > /dev/null ||
-	   (pidof dcopserver > /dev/null && test -x /usr/bin/dcop && /usr/bin/dcop kded kded loadedModules | grep -q klaptopdaemon) ; then
-		echo 0;
-	else
-		echo 1;
-	fi
-}
diff --git a/poky/meta/recipes-bsp/eee-acpi-scripts/files/powerbtn.patch b/poky/meta/recipes-bsp/eee-acpi-scripts/files/powerbtn.patch
deleted file mode 100644
index 403e556..0000000
--- a/poky/meta/recipes-bsp/eee-acpi-scripts/files/powerbtn.patch
+++ /dev/null
@@ -1,22 +0,0 @@
----
- actions/power.sh |    3 +++
- events/powerbtn  |    2 ++
- 2 files changed, 5 insertions(+)
-
-Upstream-Status: Inappropriate [enable feature]
-
-Index: git/events/powerbtn
-===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ git/events/powerbtn	2008-10-08 17:43:35.000000000 +0200
-@@ -0,0 +1,2 @@
-+event=button/power PWRF
-+action=/etc/acpi/actions/power.sh
-Index: git/actions/power.sh
-===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ git/actions/power.sh	2008-10-08 17:45:26.000000000 +0200
-@@ -0,0 +1,3 @@
-+#!/bin/sh
-+
-+/sbin/shutdown -h now "Power button pressed"
diff --git a/poky/meta/recipes-bsp/eee-acpi-scripts/files/remove-doc-check.patch b/poky/meta/recipes-bsp/eee-acpi-scripts/files/remove-doc-check.patch
deleted file mode 100644
index efb3dca..0000000
--- a/poky/meta/recipes-bsp/eee-acpi-scripts/files/remove-doc-check.patch
+++ /dev/null
@@ -1,60 +0,0 @@
----
- actions/hotkey.sh     |    3 ---
- actions/suspend.sh    |    3 ---
- actions/vga-toggle.sh |    3 ---
- actions/volume.sh     |    3 ---
- 4 files changed, 12 deletions(-)
-
-Upstream-Status: Inappropriate [configuration]
-
-Index: git/eeepc-acpi-scripts/volume.sh
-===================================================================
---- git.orig/eeepc-acpi-scripts/volume.sh	2011-11-29 19:21:55.000000000 +0800
-+++ git/eeepc-acpi-scripts/volume.sh	2011-11-29 19:41:36.000000000 +0800
-@@ -3,12 +3,10 @@
- [ -d /sys/devices/platform/eeepc ] || [ -d /sys/devices/platform/eeepc-wmi ] || exit 0
- # Volume controls
- 
--# do nothing if package is removed
- PKG=eeepc-acpi-scripts
- PKG_DIR=/usr/share/acpi-support/$PKG
- FUNC_LIB=$PKG_DIR/lib/functions.sh
- DEFAULT=/etc/default/$PKG
--[ -e "$FUNC_LIB" ] || exit 0
- 
- . $FUNC_LIB
- . $PKG_DIR/lib/sound.sh
-Index: git/eeepc-acpi-scripts/hotkey.sh
-===================================================================
---- git.orig/eeepc-acpi-scripts/hotkey.sh	2011-11-29 19:21:55.000000000 +0800
-+++ git/eeepc-acpi-scripts/hotkey.sh	2011-11-29 19:39:51.000000000 +0800
-@@ -1,12 +1,10 @@
- #!/bin/sh
- 
- [ -d /sys/devices/platform/eeepc ] || [ -d /sys/devices/platform/eeepc-wmi ] || exit 0
--# do nothing if package is removed
- PKG=eeepc-acpi-scripts
- PKG_DIR=/usr/share/acpi-support/$PKG
- FUNC_LIB=$PKG_DIR/lib/functions.sh
- DEFAULT=/etc/default/$PKG
--[ -e "$FUNC_LIB" ] || exit 0
- 
- case $(runlevel) in
-     *0|*6)
-Index: git/eeepc-acpi-scripts/vga-toggle.sh
-===================================================================
---- git.orig/eeepc-acpi-scripts/vga-toggle.sh	2011-11-29 19:21:55.000000000 +0800
-+++ git/eeepc-acpi-scripts/vga-toggle.sh	2011-11-29 19:40:24.000000000 +0800
-@@ -1,12 +1,10 @@
- #!/bin/sh
- 
- [ -d /sys/devices/platform/eeepc ] || [ -d /sys/devices/platform/eeepc-wmi ] || exit 0
--# do nothing if package is removed
- PKG=eeepc-acpi-scripts
- PKG_DIR=/usr/share/acpi-support/$PKG
- FUNC_LIB=$PKG_DIR/lib/functions.sh
- DEFAULT=/etc/default/$PKG
--[ -e "$FUNC_LIB" ] || exit 0
- 
- if [ -e "$DEFAULT" ]; then . "$DEFAULT"; fi
- . $FUNC_LIB
diff --git a/poky/meta/recipes-bsp/gnu-efi/gnu-efi/lib-Makefile-fix-parallel-issue.patch b/poky/meta/recipes-bsp/gnu-efi/gnu-efi/lib-Makefile-fix-parallel-issue.patch
index 1b2ae1e..dc00b8f 100644
--- a/poky/meta/recipes-bsp/gnu-efi/gnu-efi/lib-Makefile-fix-parallel-issue.patch
+++ b/poky/meta/recipes-bsp/gnu-efi/gnu-efi/lib-Makefile-fix-parallel-issue.patch
@@ -1,7 +1,7 @@
-From 0daa354a16aa3cade56ed423d0f8a04cf1c22f9d Mon Sep 17 00:00:00 2001
+From 3ec8c2a70304eabd5760937a4ec3fbc4068a77ed Mon Sep 17 00:00:00 2001
 From: Robert Yang <liezhi.yang@windriver.com>
 Date: Thu, 23 Apr 2015 01:49:31 -0700
-Subject: [PATCH] lib/Makefile: fix parallel issue
+Subject: [PATCH 2/3] lib/Makefile: fix parallel issue
 
 Fixed:
 Assembler messages:
@@ -17,22 +17,22 @@
 
 Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
 ---
- lib/Makefile |    2 ++
+ lib/Makefile | 2 ++
  1 file changed, 2 insertions(+)
 
 diff --git a/lib/Makefile b/lib/Makefile
-index dc4b94a..f64d1ed 100644
+index 048751a..ed39bbb 100644
 --- a/lib/Makefile
 +++ b/lib/Makefile
-@@ -73,6 +73,8 @@ all: libsubdirs libefi.a
+@@ -74,6 +74,8 @@ all: libsubdirs libefi.a
  libsubdirs:
  	for sdir in $(SUBDIRS); do mkdir -p $$sdir; done
  
 +$(OBJS): libsubdirs
 +
  libefi.a: $(OBJS)
- 	$(AR) rv $@ $(OBJS)
+ 	$(AR) $(ARFLAGS) $@ $(OBJS)
  
 -- 
-1.7.9.5
+2.7.4
 
diff --git a/poky/meta/recipes-bsp/gnu-efi/gnu-efi/parallel-make-archives.patch b/poky/meta/recipes-bsp/gnu-efi/gnu-efi/parallel-make-archives.patch
index 0110260..a9806cf 100644
--- a/poky/meta/recipes-bsp/gnu-efi/gnu-efi/parallel-make-archives.patch
+++ b/poky/meta/recipes-bsp/gnu-efi/gnu-efi/parallel-make-archives.patch
@@ -1,4 +1,4 @@
-From 16865de66db33ca70872199e70d93efccecc8575 Mon Sep 17 00:00:00 2001
+From 48b2cdbcd761105e8ebad412fcbf23db1ac4ef7c Mon Sep 17 00:00:00 2001
 From: Saul Wold <sgw@linux.intel.com>
 Date: Sun, 9 Mar 2014 15:22:15 +0200
 Subject: [PATCH 1/3] Fix parallel make failure for archives
@@ -17,13 +17,15 @@
 Signed-off-by: Darren Hart <dvhart@linux.intel.com>
 [Rebased for 3.0.6]
 Signed-off-by: California Sullivan <california.l.sullivan@intel.com>
+[Rebased for 3.0.8]
+Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
 ---
  gnuefi/Makefile | 3 ++-
  lib/Makefile    | 2 +-
  2 files changed, 3 insertions(+), 2 deletions(-)
 
 diff --git a/gnuefi/Makefile b/gnuefi/Makefile
-index 2a61699..148106e 100644
+index 2a61699..89b560a 100644
 --- a/gnuefi/Makefile
 +++ b/gnuefi/Makefile
 @@ -54,7 +54,8 @@ TARGETS	= crt0-efi-$(ARCH).o libgnuefi.a
@@ -32,23 +34,23 @@
  
 -libgnuefi.a: $(patsubst %,libgnuefi.a(%),$(OBJS))
 +libgnuefi.a: $(OBJS)
-+	$(AR) rv $@ $(OBJS)
++	$(AR) $(ARFLAGS) $@ $(OBJS)
  
  clean:
  	rm -f $(TARGETS) *~ *.o $(OBJS)
 diff --git a/lib/Makefile b/lib/Makefile
-index b8d1ce7..6ef8107 100644
+index 0e6410d..048751a 100644
 --- a/lib/Makefile
 +++ b/lib/Makefile
 @@ -75,7 +75,7 @@ libsubdirs:
  	for sdir in $(SUBDIRS); do mkdir -p $$sdir; done
  
  libefi.a: $(OBJS)
--	$(AR) rv -U $@ $^
-+	$(AR) rv $@ $(OBJS)
+-	$(AR) $(ARFLAGS) $@ $^
++	$(AR) $(ARFLAGS) $@ $(OBJS)
  
  clean:
  	rm -f libefi.a *~ $(OBJS) */*.o
 -- 
-2.9.4
+2.7.4
 
diff --git a/poky/meta/recipes-bsp/gnu-efi/gnu-efi_3.0.6.bb b/poky/meta/recipes-bsp/gnu-efi/gnu-efi_3.0.6.bb
deleted file mode 100644
index 2a60717..0000000
--- a/poky/meta/recipes-bsp/gnu-efi/gnu-efi_3.0.6.bb
+++ /dev/null
@@ -1,71 +0,0 @@
-SUMMARY = "Libraries for producing EFI binaries"
-HOMEPAGE = "http://sourceforge.net/projects/gnu-efi/"
-SECTION = "devel"
-LICENSE = "GPLv2+ | BSD-2-Clause"
-LIC_FILES_CHKSUM = "file://gnuefi/crt0-efi-arm.S;beginline=4;endline=16;md5=e582764a4776e60c95bf9ab617343d36 \
-                    file://gnuefi/crt0-efi-aarch64.S;beginline=4;endline=16;md5=e582764a4776e60c95bf9ab617343d36 \
-                    file://inc/efishellintf.h;beginline=13;endline=20;md5=202766b79d708eff3cc70fce15fb80c7 \
-                    file://inc/efishellparm.h;beginline=4;endline=11;md5=468b1231b05bbc84bae3a0d5774e3bb5 \
-                    file://lib/arm/math.c;beginline=2;endline=15;md5=8ed772501da77b2b3345aa6df8744c9e \
-                    file://lib/arm/initplat.c;beginline=2;endline=15;md5=8ed772501da77b2b3345aa6df8744c9e \
-                    file://lib/aarch64/math.c;beginline=2;endline=15;md5=8ed772501da77b2b3345aa6df8744c9e \
-                    file://lib/aarch64/initplat.c;beginline=2;endline=15;md5=8ed772501da77b2b3345aa6df8744c9e \
-                   "
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BP}.tar.bz2 \
-           file://parallel-make-archives.patch \
-           file://lib-Makefile-fix-parallel-issue.patch \
-           file://gcc46-compatibility.patch \
-           "
-
-SRC_URI[md5sum] = "46f633758a8a37db9fd6909fe270c26b"
-SRC_URI[sha256sum] = "21515902d80fbea23328a61d70d3d51a47204abd1507ebfa27550a7b9bf22c91"
-
-COMPATIBLE_HOST = "(x86_64.*|i.86.*|aarch64.*|arm.*)-linux"
-COMPATIBLE_HOST_armv4 = 'null'
-
-do_configure_linux-gnux32_prepend() {
-	cp ${STAGING_INCDIR}/gnu/stubs-x32.h ${STAGING_INCDIR}/gnu/stubs-64.h
-	cp ${STAGING_INCDIR}/bits/long-double-32.h ${STAGING_INCDIR}/bits/long-double-64.h
-}
-
-def gnu_efi_arch(d):
-    import re
-    tarch = d.getVar("TARGET_ARCH")
-    if re.match("i[3456789]86", tarch):
-        return "ia32"
-    return tarch
-
-EXTRA_OEMAKE = "'ARCH=${@gnu_efi_arch(d)}' 'CC=${CC}' 'AS=${AS}' 'LD=${LD}' 'AR=${AR}' \
-                'RANLIB=${RANLIB}' 'OBJCOPY=${OBJCOPY}' 'PREFIX=${prefix}' 'LIBDIR=${libdir}' \
-                "
-
-# gnu-efi's Makefile treats prefix as toolchain prefix, so don't
-# export it.
-prefix[unexport] = "1"
-
-do_install() {
-        oe_runmake install INSTALLROOT="${D}"
-}
-
-FILES_${PN} += "${libdir}/*.lds"
-
-# 64-bit binaries are expected for EFI when targeting X32
-INSANE_SKIP_${PN}-dev_append_linux-gnux32 = " arch"
-INSANE_SKIP_${PN}-dev_append_linux-muslx32 = " arch"
-
-BBCLASSEXTEND = "native"
-
-# It doesn't support sse, its make.defaults sets:
-# CFLAGS += -mno-mmx -mno-sse
-# So also remove -mfpmath=sse from TUNE_CCARGS
-TUNE_CCARGS_remove = "-mfpmath=sse"
-
-python () {
-    ccargs = d.getVar('TUNE_CCARGS').split()
-    if '-mx32' in ccargs:
-        # use x86_64 EFI ABI
-        ccargs.remove('-mx32')
-        ccargs.append('-m64')
-        d.setVar('TUNE_CCARGS', ' '.join(ccargs))
-}
diff --git a/poky/meta/recipes-bsp/gnu-efi/gnu-efi_3.0.8.bb b/poky/meta/recipes-bsp/gnu-efi/gnu-efi_3.0.8.bb
new file mode 100644
index 0000000..dba4733
--- /dev/null
+++ b/poky/meta/recipes-bsp/gnu-efi/gnu-efi_3.0.8.bb
@@ -0,0 +1,71 @@
+SUMMARY = "Libraries for producing EFI binaries"
+HOMEPAGE = "http://sourceforge.net/projects/gnu-efi/"
+SECTION = "devel"
+LICENSE = "GPLv2+ | BSD-2-Clause"
+LIC_FILES_CHKSUM = "file://gnuefi/crt0-efi-arm.S;beginline=4;endline=16;md5=e582764a4776e60c95bf9ab617343d36 \
+                    file://gnuefi/crt0-efi-aarch64.S;beginline=4;endline=16;md5=e582764a4776e60c95bf9ab617343d36 \
+                    file://inc/efishellintf.h;beginline=13;endline=20;md5=202766b79d708eff3cc70fce15fb80c7 \
+                    file://inc/efishellparm.h;beginline=4;endline=11;md5=468b1231b05bbc84bae3a0d5774e3bb5 \
+                    file://lib/arm/math.c;beginline=2;endline=15;md5=8ed772501da77b2b3345aa6df8744c9e \
+                    file://lib/arm/initplat.c;beginline=2;endline=15;md5=8ed772501da77b2b3345aa6df8744c9e \
+                    file://lib/aarch64/math.c;beginline=2;endline=15;md5=8ed772501da77b2b3345aa6df8744c9e \
+                    file://lib/aarch64/initplat.c;beginline=2;endline=15;md5=8ed772501da77b2b3345aa6df8744c9e \
+                   "
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BP}.tar.bz2 \
+           file://parallel-make-archives.patch \
+           file://lib-Makefile-fix-parallel-issue.patch \
+           file://gcc46-compatibility.patch \
+           "
+
+SRC_URI[md5sum] = "ae32011cfe6b1c40c0f244b9a49ba181"
+SRC_URI[sha256sum] = "76006d8ea8d67bcf72f35d09d43e9ef6a69400d6d5d4bf64baf1ab7434e2b722"
+
+COMPATIBLE_HOST = "(x86_64.*|i.86.*|aarch64.*|arm.*)-linux"
+COMPATIBLE_HOST_armv4 = 'null'
+
+do_configure_linux-gnux32_prepend() {
+	cp ${STAGING_INCDIR}/gnu/stubs-x32.h ${STAGING_INCDIR}/gnu/stubs-64.h
+	cp ${STAGING_INCDIR}/bits/long-double-32.h ${STAGING_INCDIR}/bits/long-double-64.h
+}
+
+def gnu_efi_arch(d):
+    import re
+    tarch = d.getVar("TARGET_ARCH")
+    if re.match("i[3456789]86", tarch):
+        return "ia32"
+    return tarch
+
+EXTRA_OEMAKE = "'ARCH=${@gnu_efi_arch(d)}' 'CC=${CC}' 'AS=${AS}' 'LD=${LD}' 'AR=${AR}' \
+                'RANLIB=${RANLIB}' 'OBJCOPY=${OBJCOPY}' 'PREFIX=${prefix}' 'LIBDIR=${libdir}' \
+                "
+
+# gnu-efi's Makefile treats prefix as toolchain prefix, so don't
+# export it.
+prefix[unexport] = "1"
+
+do_install() {
+        oe_runmake install INSTALLROOT="${D}"
+}
+
+FILES_${PN} += "${libdir}/*.lds"
+
+# 64-bit binaries are expected for EFI when targeting X32
+INSANE_SKIP_${PN}-dev_append_linux-gnux32 = " arch"
+INSANE_SKIP_${PN}-dev_append_linux-muslx32 = " arch"
+
+BBCLASSEXTEND = "native"
+
+# It doesn't support sse, its make.defaults sets:
+# CFLAGS += -mno-mmx -mno-sse
+# So also remove -mfpmath=sse from TUNE_CCARGS
+TUNE_CCARGS_remove = "-mfpmath=sse"
+
+python () {
+    ccargs = d.getVar('TUNE_CCARGS').split()
+    if '-mx32' in ccargs:
+        # use x86_64 EFI ABI
+        ccargs.remove('-mx32')
+        ccargs.append('-m64')
+        d.setVar('TUNE_CCARGS', ' '.join(ccargs))
+}
diff --git a/poky/meta/recipes-bsp/grub/files/0001-x86-64-Treat-R_X86_64_PLT32-as-R_X86_64_PC32.patch b/poky/meta/recipes-bsp/grub/files/0001-x86-64-Treat-R_X86_64_PLT32-as-R_X86_64_PC32.patch
new file mode 100644
index 0000000..61d58c4
--- /dev/null
+++ b/poky/meta/recipes-bsp/grub/files/0001-x86-64-Treat-R_X86_64_PLT32-as-R_X86_64_PC32.patch
@@ -0,0 +1,76 @@
+Upstream-Status: Backport
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+From 842c390469e2c2e10b5aa36700324cd3bde25875 Mon Sep 17 00:00:00 2001
+From: "H.J. Lu" <hjl.tools@gmail.com>
+Date: Sat, 17 Feb 2018 06:47:28 -0800
+Subject: [PATCH] x86-64: Treat R_X86_64_PLT32 as R_X86_64_PC32
+
+Starting from binutils commit bd7ab16b4537788ad53521c45469a1bdae84ad4a:
+
+https://sourceware.org/git/?p=binutils-gdb.git;a=commit;h=bd7ab16b4537788ad53521c45469a1bdae84ad4a
+
+x86-64 assembler generates R_X86_64_PLT32, instead of R_X86_64_PC32, for
+32-bit PC-relative branches.  Grub2 should treat R_X86_64_PLT32 as
+R_X86_64_PC32.
+
+Signed-off-by: H.J. Lu <hjl.tools@gmail.com>
+Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
+---
+ grub-core/efiemu/i386/loadcore64.c | 1 +
+ grub-core/kern/x86_64/dl.c         | 1 +
+ util/grub-mkimagexx.c              | 1 +
+ util/grub-module-verifier.c        | 1 +
+ 4 files changed, 4 insertions(+)
+
+diff --git a/grub-core/efiemu/i386/loadcore64.c b/grub-core/efiemu/i386/loadcore64.c
+index e49d0b6ff..18facf47f 100644
+--- a/grub-core/efiemu/i386/loadcore64.c
++++ b/grub-core/efiemu/i386/loadcore64.c
+@@ -98,6 +98,7 @@ grub_arch_efiemu_relocate_symbols64 (grub_efiemu_segment_t segs,
+ 		    break;
+ 
+ 		  case R_X86_64_PC32:
++		  case R_X86_64_PLT32:
+ 		    err = grub_efiemu_write_value (addr,
+ 						   *addr32 + rel->r_addend
+ 						   + sym.off
+diff --git a/grub-core/kern/x86_64/dl.c b/grub-core/kern/x86_64/dl.c
+index 440690673..3a73e6e6c 100644
+--- a/grub-core/kern/x86_64/dl.c
++++ b/grub-core/kern/x86_64/dl.c
+@@ -70,6 +70,7 @@ grub_arch_dl_relocate_symbols (grub_dl_t mod, void *ehdr,
+ 	  break;
+ 
+ 	case R_X86_64_PC32:
++	case R_X86_64_PLT32:
+ 	  {
+ 	    grub_int64_t value;
+ 	    value = ((grub_int32_t) *addr32) + rel->r_addend + sym->st_value -
+diff --git a/util/grub-mkimagexx.c b/util/grub-mkimagexx.c
+index a2bb05439..39d7efb91 100644
+--- a/util/grub-mkimagexx.c
++++ b/util/grub-mkimagexx.c
+@@ -841,6 +841,7 @@ SUFFIX (relocate_addresses) (Elf_Ehdr *e, Elf_Shdr *sections,
+ 		  break;
+ 
+ 		case R_X86_64_PC32:
++		case R_X86_64_PLT32:
+ 		  {
+ 		    grub_uint32_t *t32 = (grub_uint32_t *) target;
+ 		    *t32 = grub_host_to_target64 (grub_target_to_host32 (*t32)
+diff --git a/util/grub-module-verifier.c b/util/grub-module-verifier.c
+index 9179285a5..a79271f66 100644
+--- a/util/grub-module-verifier.c
++++ b/util/grub-module-verifier.c
+@@ -19,6 +19,7 @@ struct grub_module_verifier_arch archs[] = {
+       -1
+     }, (int[]){
+       R_X86_64_PC32,
++      R_X86_64_PLT32,
+       -1
+     }
+   },
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-bsp/grub/grub-efi_2.02.bb b/poky/meta/recipes-bsp/grub/grub-efi_2.02.bb
index 7bfc8ee..14fce97 100644
--- a/poky/meta/recipes-bsp/grub/grub-efi_2.02.bb
+++ b/poky/meta/recipes-bsp/grub/grub-efi_2.02.bb
@@ -25,6 +25,9 @@
     elif re.match('aarch64', target):
         grubtarget = 'arm64'
         grubimage = prefix + "bootaa64.efi"
+    elif re.match('arm', target):
+        grubtarget = 'arm'
+        grubimage = prefix + "bootarm.efi"
     else:
         raise bb.parse.SkipRecipe("grub-efi is incompatible with target %s" % target)
     d.setVar("GRUB_TARGET", grubtarget)
diff --git a/poky/meta/recipes-bsp/grub/grub2.inc b/poky/meta/recipes-bsp/grub/grub2.inc
index a8f335e..325eca2 100644
--- a/poky/meta/recipes-bsp/grub/grub2.inc
+++ b/poky/meta/recipes-bsp/grub/grub2.inc
@@ -17,8 +17,9 @@
            file://autogen.sh-exclude-pc.patch \
            file://grub-module-explicitly-keeps-symbole-.module_license.patch \
            file://0001-grub.d-10_linux.in-add-oe-s-kernel-name.patch \
-	   file://fix.build.with.gcc-7.patch \
+           file://fix.build.with.gcc-7.patch \
            file://gcc8.patch \
+           file://0001-x86-64-Treat-R_X86_64_PLT32-as-R_X86_64_PC32.patch \
 "
 SRC_URI[md5sum] = "1116d1f60c840e6dbd67abbc99acb45d"
 SRC_URI[sha256sum] = "660ee136fbcee08858516ed4de2ad87068bfe1b6b8b37896ce3529ff054a726d"
@@ -32,7 +33,7 @@
 # configure.ac has code to set this automagically from the target tuple
 # but the OE freeform one (core2-foo-bar-linux) don't work with that.
 
-GRUBPLATFORM_arm = "uboot"
+GRUBPLATFORM_arm = "efi"
 GRUBPLATFORM_aarch64 = "efi"
 GRUBPLATFORM ??= "pc"
 
diff --git a/poky/meta/recipes-bsp/pciutils/pciutils_3.5.6.bb b/poky/meta/recipes-bsp/pciutils/pciutils_3.5.6.bb
deleted file mode 100644
index b18b7da..0000000
--- a/poky/meta/recipes-bsp/pciutils/pciutils_3.5.6.bb
+++ /dev/null
@@ -1,58 +0,0 @@
-SUMMARY = "PCI utilities"
-DESCRIPTION = 'The PCI Utilities package contains a library for portable access \
-to PCI bus configuration space and several utilities based on this library.'
-HOMEPAGE = "http://atrey.karlin.mff.cuni.cz/~mj/pciutils.shtml"
-SECTION = "console/utils"
-
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
-DEPENDS = "zlib kmod"
-
-SRC_URI = "${KERNELORG_MIRROR}/software/utils/pciutils/pciutils-${PV}.tar.xz \
-           file://configure.patch"
-
-SRC_URI[md5sum] = "8e52278399b7b35fcfc031bc05da80a8"
-SRC_URI[sha256sum] = "f346eeb90cce0910c05b877fe49eadc760fa084c0455fd313e39d4b2c2d4bb21"
-
-inherit multilib_header pkgconfig
-
-PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'hwdb', '', d)}"
-PACKAGECONFIG[hwdb] = "HWDB=yes,HWDB=no,udev"
-
-PCI_CONF_FLAG = "ZLIB=yes DNS=yes SHARED=yes STRIP= LIBDIR=${libdir}"
-
-# see configure.patch
-do_configure () {
-	(
-	  cd lib && \
-	  # PACKAGECONFIG_CONFARGS for this recipe could only possibly contain 'HWDB=yes/no',
-	  # so we put it before ./configure
-	  ${PCI_CONF_FLAG} ${PACKAGECONFIG_CONFARGS} ./configure ${PV} ${datadir} ${TARGET_OS} ${TARGET_ARCH}
-	)
-}
-
-export PREFIX = "${prefix}"
-export SBINDIR = "${sbindir}"
-export SHAREDIR = "${datadir}"
-export MANDIR = "${mandir}"
-
-EXTRA_OEMAKE = "-e MAKEFLAGS= ${PCI_CONF_FLAG}"
-
-# The configure script breaks if the HOST variable is set
-HOST[unexport] = "1"
-
-do_install () {
-	oe_runmake DESTDIR=${D} install install-lib
-
-	install -d ${D}${bindir}
-	ln -s ../sbin/lspci ${D}${bindir}/lspci
-
-	oe_multilib_header pci/config.h
-}
-
-PACKAGES =+ "${PN}-ids libpci"
-FILES_${PN}-ids = "${datadir}/pci.ids*"
-FILES_libpci = "${libdir}/libpci.so.*"
-SUMMARY_${PN}-ids = "PCI utilities - device ID database"
-DESCRIPTION_${PN}-ids = "Package providing the PCI device ID database for pciutils."
-RDEPENDS_${PN} += "${PN}-ids"
diff --git a/poky/meta/recipes-bsp/pciutils/pciutils_3.6.2.bb b/poky/meta/recipes-bsp/pciutils/pciutils_3.6.2.bb
new file mode 100644
index 0000000..413421c
--- /dev/null
+++ b/poky/meta/recipes-bsp/pciutils/pciutils_3.6.2.bb
@@ -0,0 +1,60 @@
+SUMMARY = "PCI utilities"
+DESCRIPTION = 'The PCI Utilities package contains a library for portable access \
+to PCI bus configuration space and several utilities based on this library.'
+HOMEPAGE = "http://atrey.karlin.mff.cuni.cz/~mj/pciutils.shtml"
+SECTION = "console/utils"
+
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
+DEPENDS = "zlib kmod"
+
+SRC_URI = "${KERNELORG_MIRROR}/software/utils/pciutils/pciutils-${PV}.tar.xz \
+           file://configure.patch"
+
+SRC_URI[md5sum] = "77963796d1be4f451b83e6da28ba4f82"
+SRC_URI[sha256sum] = "db452ec986edefd88af0d222d22f6102f8030a8633fdfe846c3ae4bde9bb93f3"
+
+inherit multilib_header pkgconfig
+
+PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'hwdb', '', d)}"
+PACKAGECONFIG[hwdb] = "HWDB=yes,HWDB=no,udev"
+
+PCI_CONF_FLAG = "ZLIB=yes DNS=yes SHARED=yes STRIP= LIBDIR=${libdir}"
+
+# see configure.patch
+do_configure () {
+	(
+	  cd lib && \
+	  # PACKAGECONFIG_CONFARGS for this recipe could only possibly contain 'HWDB=yes/no',
+	  # so we put it before ./configure
+	  ${PCI_CONF_FLAG} ${PACKAGECONFIG_CONFARGS} ./configure ${PV} ${datadir} ${TARGET_OS} ${TARGET_ARCH}
+	)
+}
+
+export PREFIX = "${prefix}"
+export SBINDIR = "${sbindir}"
+export SHAREDIR = "${datadir}"
+export MANDIR = "${mandir}"
+
+EXTRA_OEMAKE = "-e MAKEFLAGS= ${PCI_CONF_FLAG}"
+
+ASNEEDED = ""
+
+# The configure script breaks if the HOST variable is set
+HOST[unexport] = "1"
+
+do_install () {
+	oe_runmake DESTDIR=${D} install install-lib
+
+	install -d ${D}${bindir}
+	ln -s ../sbin/lspci ${D}${bindir}/lspci
+
+	oe_multilib_header pci/config.h
+}
+
+PACKAGES =+ "${PN}-ids libpci"
+FILES_${PN}-ids = "${datadir}/pci.ids*"
+FILES_libpci = "${libdir}/libpci.so.*"
+SUMMARY_${PN}-ids = "PCI utilities - device ID database"
+DESCRIPTION_${PN}-ids = "Package providing the PCI device ID database for pciutils."
+RDEPENDS_${PN} += "${PN}-ids"
diff --git a/poky/meta/recipes-bsp/pcmciautils/pcmciautils.inc b/poky/meta/recipes-bsp/pcmciautils/pcmciautils.inc
deleted file mode 100644
index 26c6d75..0000000
--- a/poky/meta/recipes-bsp/pcmciautils/pcmciautils.inc
+++ /dev/null
@@ -1,34 +0,0 @@
-SUMMARY = "Linux kernel userland utilities for the PCMCIA subsystem"
-HOMEPAGE = "https://www.kernel.org/pub/linux/utils/kernel/pcmcia/"
-SECTION = "kernel/userland"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
-
-DEPENDS = "udev sysfsutils flex-native bison-native"
-RDEPENDS_${PN} = "udev module-init-tools"
-
-SRC_URI = "${KERNELORG_MIRROR}/linux/utils/kernel/pcmcia/${BP}.tar.xz"
-
-S = "${WORKDIR}/pcmciautils-${PV}"
-
-inherit pkgconfig
-
-export HOSTCC = "${BUILD_CC}"
-export etcdir = "${sysconfdir}"
-export sbindir = "${base_sbindir}"
-export pcmciaconfdir = "${sysconfdir}/pcmcia"
-export udevdir = "`pkg-config --variable=udevdir udev`"
-export udevrulesdir = "`pkg-config --variable=udevdir udev`/rules.d"
-export UDEV = "1"
-LD = "${CC}"
-CFLAGS =+ "-I${S}/src"
-CFLAGS =+ "-DPCMCIAUTILS_VERSION=\\"${PV}\\""
-
-EXTRA_OEMAKE = "-e 'STRIP=echo' 'LIB_OBJS=-lc -lsysfs' 'LEX=flex'"
-
-do_install () {
-	oe_runmake 'DESTDIR=${D}' install
-}
-
-CONFFILES_${PN} += "${sysconfdir}/pcmcia/config.opts"
diff --git a/poky/meta/recipes-bsp/pcmciautils/pcmciautils_018.bb b/poky/meta/recipes-bsp/pcmciautils/pcmciautils_018.bb
deleted file mode 100644
index bf0f58a..0000000
--- a/poky/meta/recipes-bsp/pcmciautils/pcmciautils_018.bb
+++ /dev/null
@@ -1,11 +0,0 @@
-require pcmciautils.inc
-
-SRC_URI += "file://makefile_fix.patch \
-            file://makefile_race.patch \
-            file://lex_sys_types.patch \
-"
-
-SRC_URI[md5sum] = "885431c3cefb76ffdad8cb985134e996"
-SRC_URI[sha256sum] = "57c27be8f04ef4d535bcfa988567316cc57659fe69068327486dab53791e6558"
-
-PR = "r1"
diff --git a/poky/meta/recipes-bsp/u-boot/files/0001-efi_loader-avoid-make-race-condition.patch b/poky/meta/recipes-bsp/u-boot/files/0001-efi_loader-avoid-make-race-condition.patch
deleted file mode 100644
index da7e27c..0000000
--- a/poky/meta/recipes-bsp/u-boot/files/0001-efi_loader-avoid-make-race-condition.patch
+++ /dev/null
@@ -1,51 +0,0 @@
-From 5c2e24a9ed54dfee77d1844a080e998b4affe916 Mon Sep 17 00:00:00 2001
-From: Heinrich Schuchardt <xypron.glpk@gmx.de>
-Date: Sat, 2 Jun 2018 19:00:41 +0200
-Subject: [PATCH] efi_loader: avoid make race condition
-
-When U-Boot is built with 'make -j' there is not guarantee that targets in
-directory arch/ are built before targets in directory lib/. The current
-build instruction for EFI binaries in lib/ rely on dependencies in arch/.
-If $(EFI_CRT0) or $(EFI_RELOC) is not yet built before trying to build
-%.efi an error
-    *** No rule to make target '%.efi'
-occurs.
-
-With the patch separate copies of $(EFI_CRT0) and $(EFI_RELOC) named
-efi_crt0.o and efi_reloc.o are built in lib/efi_loader and
-lib/efi_selftest.
-
-Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
-Signed-off-by: Alexander Graf <agraf@suse.de>
-
-Upstream-Status: Backport from 2018.07
-
-Signed-off-by: Joshua Watt <JPEWhacker@gmail.com>
----
- scripts/Makefile.lib | 10 ++++++++--
- 1 file changed, 8 insertions(+), 2 deletions(-)
-
-diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
-index 8f19b2db56..f2f398c935 100644
---- a/scripts/Makefile.lib
-+++ b/scripts/Makefile.lib
-@@ -404,8 +404,14 @@ cmd_efi_ld = $(LD) -nostdlib -znocombreloc -T $(EFI_LDS_PATH) -shared \
- 
- EFI_LDS_PATH = $(srctree)/arch/$(ARCH)/lib/$(EFI_LDS)
- 
--$(obj)/%_efi.so: $(obj)/%.o arch/$(ARCH)/lib/$(EFI_CRT0) \
--		arch/$(ARCH)/lib/$(EFI_RELOC)
-+$(obj)/efi_crt0.o: $(srctree)/arch/$(ARCH)/lib/$(EFI_CRT0:.o=.S)
-+	$(call if_changed_dep,as_o_S)
-+
-+$(obj)/efi_reloc.o: $(srctree)/arch/$(ARCH)/lib/$(EFI_RELOC:.o=.c) $(recordmcount_source) FORCE
-+	$(call cmd,force_checksrc)
-+	$(call if_changed_rule,cc_o_c)
-+
-+$(obj)/%_efi.so: $(obj)/%.o $(obj)/efi_crt0.o $(obj)/efi_reloc.o
- 	$(call cmd,efi_ld)
- 
- # ACPI
--- 
-2.17.1
-
diff --git a/poky/meta/recipes-bsp/u-boot/files/CVE-2018-1000205-1.patch b/poky/meta/recipes-bsp/u-boot/files/CVE-2018-1000205-1.patch
new file mode 100644
index 0000000..fed3c3d
--- /dev/null
+++ b/poky/meta/recipes-bsp/u-boot/files/CVE-2018-1000205-1.patch
@@ -0,0 +1,59 @@
+From 7346c1e192d63cd35f99c7e845e53c5d4d0bdc24 Mon Sep 17 00:00:00 2001
+From: Teddy Reed <teddy.reed@gmail.com>
+Date: Sat, 9 Jun 2018 11:45:20 -0400
+Subject: [PATCH] vboot: Do not use hashed-strings offset
+
+The hashed-strings signature property includes two uint32_t values.
+The first is unneeded as there should never be a start offset into the
+strings region. The second, the size, is needed because the added
+signature node appends to this region.
+
+See tools/image-host.c, where a static 0 value is used for the offset.
+
+Signed-off-by: Teddy Reed <teddy.reed@gmail.com>
+Reviewed-by: Simon Glass <sjg@chromium.org>
+
+Upstream-Status: Backport[http://git.denx.de/?p=u-boot.git;a=commit;
+                 h=7346c1e192d63cd35f99c7e845e53c5d4d0bdc24]
+
+CVE: CVE-2018-1000205
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ common/image-sig.c | 7 +++++--
+ tools/image-host.c | 1 +
+ 2 files changed, 6 insertions(+), 2 deletions(-)
+
+diff --git a/common/image-sig.c b/common/image-sig.c
+index 8d2fd10..5a269d3 100644
+--- a/common/image-sig.c
++++ b/common/image-sig.c
+@@ -377,8 +377,11 @@ int fit_config_check_sig(const void *fit, int noffset, int required_keynode,
+ 	/* Add the strings */
+ 	strings = fdt_getprop(fit, noffset, "hashed-strings", NULL);
+ 	if (strings) {
+-		fdt_regions[count].offset = fdt_off_dt_strings(fit) +
+-				fdt32_to_cpu(strings[0]);
++		/*
++		 * The strings region offset must be a static 0x0.
++		 * This is set in tool/image-host.c
++		 */
++		fdt_regions[count].offset = fdt_off_dt_strings(fit);
+ 		fdt_regions[count].size = fdt32_to_cpu(strings[1]);
+ 		count++;
+ 	}
+diff --git a/tools/image-host.c b/tools/image-host.c
+index 8e43671..be2d59b 100644
+--- a/tools/image-host.c
++++ b/tools/image-host.c
+@@ -135,6 +135,7 @@ static int fit_image_write_sig(void *fit, int noffset, uint8_t *value,
+ 
+ 		ret = fdt_setprop(fit, noffset, "hashed-nodes",
+ 				   region_prop, region_proplen);
++		/* This is a legacy offset, it is unused, and must remain 0. */
+ 		strdata[0] = 0;
+ 		strdata[1] = cpu_to_fdt32(string_size);
+ 		if (!ret) {
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-bsp/u-boot/files/CVE-2018-1000205-2.patch b/poky/meta/recipes-bsp/u-boot/files/CVE-2018-1000205-2.patch
new file mode 100644
index 0000000..bb79af1
--- /dev/null
+++ b/poky/meta/recipes-bsp/u-boot/files/CVE-2018-1000205-2.patch
@@ -0,0 +1,143 @@
+From 72239fc85f3eda078547956608c063ab965e90e9 Mon Sep 17 00:00:00 2001
+From: Teddy Reed <teddy.reed@gmail.com>
+Date: Sat, 9 Jun 2018 11:38:05 -0400
+Subject: [PATCH] vboot: Add FIT_SIGNATURE_MAX_SIZE protection
+
+This adds a new config value FIT_SIGNATURE_MAX_SIZE, which controls the
+max size of a FIT header's totalsize field. The field is checked before
+signature checks are applied to protect from reading past the intended
+FIT regions.
+
+This field is not part of the vboot signature so it should be sanity
+checked. If the field is corrupted then the structure or string region
+reads may have unintended behavior, such as reading from device memory.
+A default value of 256MB is set and intended to support most max storage
+sizes.
+
+Suggested-by: Simon Glass <sjg@chromium.org>
+Signed-off-by: Teddy Reed <teddy.reed@gmail.com>
+Reviewed-by: Simon Glass <sjg@chromium.org>
+
+Upstream-Status: Backport[http://git.denx.de/?p=u-boot.git;a=commit;
+                 h=72239fc85f3eda078547956608c063ab965e90e9]
+
+CVE: CVE-2018-1000205
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ Kconfig                     | 10 ++++++++++
+ common/image-sig.c          |  5 +++++
+ test/py/tests/test_vboot.py | 33 +++++++++++++++++++++++++++++++++
+ tools/Makefile              |  1 +
+ 4 files changed, 49 insertions(+)
+
+diff --git a/Kconfig b/Kconfig
+index 5a82c95..c8b86cd 100644
+--- a/Kconfig
++++ b/Kconfig
+@@ -267,6 +267,16 @@ config FIT_SIGNATURE
+ 	  format support in this case, enable it using
+ 	  CONFIG_IMAGE_FORMAT_LEGACY.
+ 
++config FIT_SIGNATURE_MAX_SIZE
++	hex "Max size of signed FIT structures"
++	depends on FIT_SIGNATURE
++	default 0x10000000
++	help
++	  This option sets a max size in bytes for verified FIT uImages.
++	  A sane value of 256MB protects corrupted DTB structures from overlapping
++	  device memory. Assure this size does not extend past expected storage
++	  space.
++
+ config FIT_VERBOSE
+ 	bool "Show verbose messages when FIT images fail"
+ 	help
+diff --git a/common/image-sig.c b/common/image-sig.c
+index f65d883..8d2fd10 100644
+--- a/common/image-sig.c
++++ b/common/image-sig.c
+@@ -156,6 +156,11 @@ static int fit_image_setup_verify(struct image_sign_info *info,
+ {
+ 	char *algo_name;
+ 
++	if (fdt_totalsize(fit) > CONFIG_FIT_SIGNATURE_MAX_SIZE) {
++		*err_msgp = "Total size too large";
++		return 1;
++	}
++
+ 	if (fit_image_hash_get_algo(fit, noffset, &algo_name)) {
+ 		*err_msgp = "Can't get hash algo property";
+ 		return -1;
+diff --git a/test/py/tests/test_vboot.py b/test/py/tests/test_vboot.py
+index ee939f2..3d25ec3 100644
+--- a/test/py/tests/test_vboot.py
++++ b/test/py/tests/test_vboot.py
+@@ -26,6 +26,7 @@ Tests run with both SHA1 and SHA256 hashing.
+ 
+ import pytest
+ import sys
++import struct
+ import u_boot_utils as util
+ 
+ @pytest.mark.boardspec('sandbox')
+@@ -105,6 +106,26 @@ def test_vboot(u_boot_console):
+         util.run_and_log(cons, [mkimage, '-F', '-k', tmpdir, '-K', dtb,
+                                 '-r', fit])
+ 
++    def replace_fit_totalsize(size):
++        """Replace FIT header's totalsize with something greater.
++
++        The totalsize must be less than or equal to FIT_SIGNATURE_MAX_SIZE.
++        If the size is greater, the signature verification should return false.
++
++        Args:
++            size: The new totalsize of the header
++
++        Returns:
++            prev_size: The previous totalsize read from the header
++        """
++        total_size = 0
++        with open(fit, 'r+b') as handle:
++            handle.seek(4)
++            total_size = handle.read(4)
++            handle.seek(4)
++            handle.write(struct.pack(">I", size))
++        return struct.unpack(">I", total_size)[0]
++
+     def test_with_algo(sha_algo):
+         """Test verified boot with the given hash algorithm.
+ 
+@@ -146,6 +167,18 @@ def test_vboot(u_boot_console):
+         util.run_and_log(cons, [fit_check_sign, '-f', fit, '-k', tmpdir,
+                                 '-k', dtb])
+ 
++        # Replace header bytes
++        bcfg = u_boot_console.config.buildconfig
++        max_size = int(bcfg.get('config_fit_signature_max_size', 0x10000000), 0)
++        existing_size = replace_fit_totalsize(max_size + 1)
++        run_bootm(sha_algo, 'Signed config with bad hash', 'Bad Data Hash', False)
++        cons.log.action('%s: Check overflowed FIT header totalsize' % sha_algo)
++
++        # Replace with existing header bytes
++        replace_fit_totalsize(existing_size)
++        run_bootm(sha_algo, 'signed config', 'dev+', True)
++        cons.log.action('%s: Check default FIT header totalsize' % sha_algo)
++
+         # Increment the first byte of the signature, which should cause failure
+         sig = util.run_and_log(cons, 'fdtget -t bx %s %s value' %
+                                (fit, sig_node))
+diff --git a/tools/Makefile b/tools/Makefile
+index 5dd33ed..0c3341e 100644
+--- a/tools/Makefile
++++ b/tools/Makefile
+@@ -133,6 +133,7 @@ ifdef CONFIG_FIT_SIGNATURE
+ # This affects include/image.h, but including the board config file
+ # is tricky, so manually define this options here.
+ HOST_EXTRACFLAGS	+= -DCONFIG_FIT_SIGNATURE
++HOST_EXTRACFLAGS	+= -DCONFIG_FIT_SIGNATURE_MAX_SIZE=$(CONFIG_FIT_SIGNATURE_MAX_SIZE)
+ endif
+ 
+ ifdef CONFIG_SYS_U_BOOT_OFFS
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-bsp/u-boot/files/MPC8315ERDB-enable-DHCP.patch b/poky/meta/recipes-bsp/u-boot/files/MPC8315ERDB-enable-DHCP.patch
deleted file mode 100644
index ecaa179..0000000
--- a/poky/meta/recipes-bsp/u-boot/files/MPC8315ERDB-enable-DHCP.patch
+++ /dev/null
@@ -1,19 +0,0 @@
-Enabled dhcp client functionality for Yocto reference
-hardware MPC8315E-RDB.
-
-Upstream-Status: Pending
-
-Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com>
-
-Index: git/configs/MPC8315ERDB_defconfig
-===================================================================
---- git.orig/configs/MPC8315ERDB_defconfig
-+++ git/configs/MPC8315ERDB_defconfig
-@@ -12,6 +12,7 @@ CONFIG_CMD_PCI=y
- CONFIG_CMD_SATA=y
- CONFIG_CMD_USB=y
- # CONFIG_CMD_SETEXPR is not set
-+CONFIG_CMD_DHCP=y
- CONFIG_CMD_MII=y
- CONFIG_CMD_PING=y
- CONFIG_CMD_DATE=y
diff --git a/poky/meta/recipes-bsp/u-boot/u-boot-common_2018.01.inc b/poky/meta/recipes-bsp/u-boot/u-boot-common_2018.01.inc
deleted file mode 100644
index 11b82b7..0000000
--- a/poky/meta/recipes-bsp/u-boot/u-boot-common_2018.01.inc
+++ /dev/null
@@ -1,17 +0,0 @@
-HOMEPAGE = "http://www.denx.de/wiki/U-Boot/WebHome"
-SECTION = "bootloaders"
-
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://Licenses/README;md5=a2c678cfd4a4d97135585cad908541c6"
-PE = "1"
-
-# We use the revision in order to avoid having to fetch it from the
-# repo during parse
-SRCREV = "f3dd87e0b98999a78e500e8c6d2b063ebadf535a"
-
-SRC_URI = "git://git.denx.de/u-boot.git \
-    file://MPC8315ERDB-enable-DHCP.patch \
-    file://0001-efi_loader-avoid-make-race-condition.patch \
-"
-
-S = "${WORKDIR}/git"
diff --git a/poky/meta/recipes-bsp/u-boot/u-boot-common_2018.07.inc b/poky/meta/recipes-bsp/u-boot/u-boot-common_2018.07.inc
new file mode 100644
index 0000000..22b44dc
--- /dev/null
+++ b/poky/meta/recipes-bsp/u-boot/u-boot-common_2018.07.inc
@@ -0,0 +1,18 @@
+HOMEPAGE = "http://www.denx.de/wiki/U-Boot/WebHome"
+SECTION = "bootloaders"
+DEPENDS += "flex-native bison-native"
+
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://Licenses/README;md5=30503fd321432fc713238f582193b78e"
+PE = "1"
+
+# We use the revision in order to avoid having to fetch it from the
+# repo during parse
+SRCREV = "8c5d4fd0ec222701598a27b26ab7265d4cee45a3"
+
+SRC_URI = "git://git.denx.de/u-boot.git \
+           file://CVE-2018-1000205-1.patch \
+           file://CVE-2018-1000205-2.patch \
+"
+
+S = "${WORKDIR}/git"
diff --git a/poky/meta/recipes-bsp/u-boot/u-boot-fw-utils_2018.01.bb b/poky/meta/recipes-bsp/u-boot/u-boot-fw-utils_2018.01.bb
deleted file mode 100644
index 02887a1..0000000
--- a/poky/meta/recipes-bsp/u-boot/u-boot-fw-utils_2018.01.bb
+++ /dev/null
@@ -1,34 +0,0 @@
-require u-boot-common_${PV}.inc
-
-SUMMARY = "U-Boot bootloader fw_printenv/setenv utilities"
-DEPENDS = "mtd-utils"
-
-INSANE_SKIP_${PN} = "already-stripped"
-EXTRA_OEMAKE_class-target = 'CROSS_COMPILE=${TARGET_PREFIX} CC="${CC} ${CFLAGS} ${LDFLAGS}" HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" V=1'
-EXTRA_OEMAKE_class-cross = 'HOSTCC="${CC} ${CFLAGS} ${LDFLAGS}" V=1'
-
-inherit uboot-config
-
-do_compile () {
-	oe_runmake ${UBOOT_MACHINE}
-	oe_runmake envtools
-}
-
-do_install () {
-	install -d ${D}${base_sbindir}
-	install -d ${D}${sysconfdir}
-	install -m 755 ${S}/tools/env/fw_printenv ${D}${base_sbindir}/fw_printenv
-	install -m 755 ${S}/tools/env/fw_printenv ${D}${base_sbindir}/fw_setenv
-	install -m 0644 ${S}/tools/env/fw_env.config ${D}${sysconfdir}/fw_env.config
-}
-
-do_install_class-cross () {
-	install -d ${D}${bindir_cross}
-	install -m 755 ${S}/tools/env/fw_printenv ${D}${bindir_cross}/fw_printenv
-	install -m 755 ${S}/tools/env/fw_printenv ${D}${bindir_cross}/fw_setenv
-}
-
-SYSROOT_DIRS_append_class-cross = " ${bindir_cross}"
-
-PACKAGE_ARCH = "${MACHINE_ARCH}"
-BBCLASSEXTEND = "cross"
diff --git a/poky/meta/recipes-bsp/u-boot/u-boot-fw-utils_2018.07.bb b/poky/meta/recipes-bsp/u-boot/u-boot-fw-utils_2018.07.bb
new file mode 100644
index 0000000..52c13e7
--- /dev/null
+++ b/poky/meta/recipes-bsp/u-boot/u-boot-fw-utils_2018.07.bb
@@ -0,0 +1,34 @@
+require u-boot-common_${PV}.inc
+
+SUMMARY = "U-Boot bootloader fw_printenv/setenv utilities"
+DEPENDS += "mtd-utils"
+
+INSANE_SKIP_${PN} = "already-stripped"
+EXTRA_OEMAKE_class-target = 'CROSS_COMPILE=${TARGET_PREFIX} CC="${CC} ${CFLAGS} ${LDFLAGS}" HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" V=1'
+EXTRA_OEMAKE_class-cross = 'HOSTCC="${CC} ${CFLAGS} ${LDFLAGS}" V=1'
+
+inherit uboot-config
+
+do_compile () {
+	oe_runmake ${UBOOT_MACHINE}
+	oe_runmake envtools
+}
+
+do_install () {
+	install -d ${D}${base_sbindir}
+	install -d ${D}${sysconfdir}
+	install -m 755 ${S}/tools/env/fw_printenv ${D}${base_sbindir}/fw_printenv
+	install -m 755 ${S}/tools/env/fw_printenv ${D}${base_sbindir}/fw_setenv
+	install -m 0644 ${S}/tools/env/fw_env.config ${D}${sysconfdir}/fw_env.config
+}
+
+do_install_class-cross () {
+	install -d ${D}${bindir_cross}
+	install -m 755 ${S}/tools/env/fw_printenv ${D}${bindir_cross}/fw_printenv
+	install -m 755 ${S}/tools/env/fw_printenv ${D}${bindir_cross}/fw_setenv
+}
+
+SYSROOT_DIRS_append_class-cross = " ${bindir_cross}"
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+BBCLASSEXTEND = "cross"
diff --git a/poky/meta/recipes-bsp/u-boot/u-boot-mkimage_2018.01.bb b/poky/meta/recipes-bsp/u-boot/u-boot-mkimage_2018.01.bb
deleted file mode 100644
index 1c008be..0000000
--- a/poky/meta/recipes-bsp/u-boot/u-boot-mkimage_2018.01.bb
+++ /dev/null
@@ -1,29 +0,0 @@
-require u-boot-common_${PV}.inc
-
-SUMMARY = "U-Boot bootloader image creation tool"
-DEPENDS = "openssl"
-
-EXTRA_OEMAKE_class-target = 'CROSS_COMPILE="${TARGET_PREFIX}" CC="${CC} ${CFLAGS} ${LDFLAGS}" HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" STRIP=true V=1'
-EXTRA_OEMAKE_class-native = 'CC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" STRIP=true V=1'
-EXTRA_OEMAKE_class-nativesdk = 'CROSS_COMPILE="${HOST_PREFIX}" CC="${CC} ${CFLAGS} ${LDFLAGS}" HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" STRIP=true V=1'
-
-do_compile () {
-	oe_runmake sandbox_defconfig
-
-	# Disable CONFIG_CMD_LICENSE, license.h is not used by tools and
-	# generating it requires bin2header tool, which for target build
-	# is built with target tools and thus cannot be executed on host.
-	sed -i "s/CONFIG_CMD_LICENSE=.*/# CONFIG_CMD_LICENSE is not set/" .config
-
-	oe_runmake cross_tools NO_SDL=1
-}
-
-do_install () {
-	install -d ${D}${bindir}
-	install -m 0755 tools/mkimage ${D}${bindir}/uboot-mkimage
-	ln -sf uboot-mkimage ${D}${bindir}/mkimage
-}
-
-RDEPENDS_${PN} += "dtc"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-bsp/u-boot/u-boot-mkimage_2018.07.bb b/poky/meta/recipes-bsp/u-boot/u-boot-mkimage_2018.07.bb
new file mode 100644
index 0000000..08bff1d
--- /dev/null
+++ b/poky/meta/recipes-bsp/u-boot/u-boot-mkimage_2018.07.bb
@@ -0,0 +1,29 @@
+require u-boot-common_${PV}.inc
+
+SUMMARY = "U-Boot bootloader image creation tool"
+DEPENDS += "openssl"
+
+EXTRA_OEMAKE_class-target = 'CROSS_COMPILE="${TARGET_PREFIX}" CC="${CC} ${CFLAGS} ${LDFLAGS}" HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" STRIP=true V=1'
+EXTRA_OEMAKE_class-native = 'CC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" STRIP=true V=1'
+EXTRA_OEMAKE_class-nativesdk = 'CROSS_COMPILE="${HOST_PREFIX}" CC="${CC} ${CFLAGS} ${LDFLAGS}" HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" STRIP=true V=1'
+
+do_compile () {
+	oe_runmake sandbox_defconfig
+
+	# Disable CONFIG_CMD_LICENSE, license.h is not used by tools and
+	# generating it requires bin2header tool, which for target build
+	# is built with target tools and thus cannot be executed on host.
+	sed -i "s/CONFIG_CMD_LICENSE=.*/# CONFIG_CMD_LICENSE is not set/" .config
+
+	oe_runmake cross_tools NO_SDL=1
+}
+
+do_install () {
+	install -d ${D}${bindir}
+	install -m 0755 tools/mkimage ${D}${bindir}/uboot-mkimage
+	ln -sf uboot-mkimage ${D}${bindir}/mkimage
+}
+
+RDEPENDS_${PN} += "dtc"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-bsp/u-boot/u-boot.inc b/poky/meta/recipes-bsp/u-boot/u-boot.inc
index 95c2f4d..48fbc57 100644
--- a/poky/meta/recipes-bsp/u-boot/u-boot.inc
+++ b/poky/meta/recipes-bsp/u-boot/u-boot.inc
@@ -231,7 +231,7 @@
         rm -f ${UBOOT_BINARY} ${UBOOT_SYMLINK}
         ln -sf ${UBOOT_IMAGE} ${UBOOT_SYMLINK}
         ln -sf ${UBOOT_IMAGE} ${UBOOT_BINARY}
-   fi
+    fi
 
     if [ -n "${UBOOT_ELF}" ]
     then
@@ -263,32 +263,32 @@
 
      if [ -n "${SPL_BINARY}" ]
      then
-         if [ -n "${UBOOT_CONFIG}" ]
-         then
-             for config in ${UBOOT_MACHINE}; do
-                 i=$(expr $i + 1);
-                 for type in ${UBOOT_CONFIG}; do
-                     j=$(expr $j + 1);
-                     if [ $j -eq $i ]
-                     then
-                         install -m 644 ${B}/${config}/${SPL_BINARY} ${DEPLOYDIR}/${SPL_IMAGE}-${type}-${PV}-${PR}
-                         rm -f ${DEPLOYDIR}/${SPL_BINARYNAME} ${DEPLOYDIR}/${SPL_SYMLINK}-${type}
-                         ln -sf ${SPL_IMAGE}-${type}-${PV}-${PR} ${DEPLOYDIR}/${SPL_BINARYNAME}-${type}
-                         ln -sf ${SPL_IMAGE}-${type}-${PV}-${PR} ${DEPLOYDIR}/${SPL_BINARYNAME}
-                         ln -sf ${SPL_IMAGE}-${type}-${PV}-${PR} ${DEPLOYDIR}/${SPL_SYMLINK}-${type}
-                         ln -sf ${SPL_IMAGE}-${type}-${PV}-${PR} ${DEPLOYDIR}/${SPL_SYMLINK}
-                     fi
-                 done
-                 unset  j
-             done
-             unset  i
-         else
-             install -m 644 ${B}/${SPL_BINARY} ${DEPLOYDIR}/${SPL_IMAGE}
-             rm -f ${DEPLOYDIR}/${SPL_BINARYNAME} ${DEPLOYDIR}/${SPL_SYMLINK}
-             ln -sf ${SPL_IMAGE} ${DEPLOYDIR}/${SPL_BINARYNAME}
-             ln -sf ${SPL_IMAGE} ${DEPLOYDIR}/${SPL_SYMLINK}
-         fi
-     fi
+        if [ -n "${UBOOT_CONFIG}" ]
+        then
+            for config in ${UBOOT_MACHINE}; do
+                i=$(expr $i + 1);
+                for type in ${UBOOT_CONFIG}; do
+                    j=$(expr $j + 1);
+                    if [ $j -eq $i ]
+                    then
+                        install -m 644 ${B}/${config}/${SPL_BINARY} ${DEPLOYDIR}/${SPL_IMAGE}-${type}-${PV}-${PR}
+                        rm -f ${DEPLOYDIR}/${SPL_BINARYNAME} ${DEPLOYDIR}/${SPL_SYMLINK}-${type}
+                        ln -sf ${SPL_IMAGE}-${type}-${PV}-${PR} ${DEPLOYDIR}/${SPL_BINARYNAME}-${type}
+                        ln -sf ${SPL_IMAGE}-${type}-${PV}-${PR} ${DEPLOYDIR}/${SPL_BINARYNAME}
+                        ln -sf ${SPL_IMAGE}-${type}-${PV}-${PR} ${DEPLOYDIR}/${SPL_SYMLINK}-${type}
+                        ln -sf ${SPL_IMAGE}-${type}-${PV}-${PR} ${DEPLOYDIR}/${SPL_SYMLINK}
+                    fi
+                done
+                unset  j
+            done
+            unset  i
+        else
+            install -m 644 ${B}/${SPL_BINARY} ${DEPLOYDIR}/${SPL_IMAGE}
+            rm -f ${DEPLOYDIR}/${SPL_BINARYNAME} ${DEPLOYDIR}/${SPL_SYMLINK}
+            ln -sf ${SPL_IMAGE} ${DEPLOYDIR}/${SPL_BINARYNAME}
+            ln -sf ${SPL_IMAGE} ${DEPLOYDIR}/${SPL_SYMLINK}
+        fi
+    fi
 
 
     if [ -n "${UBOOT_ENV}" ]
diff --git a/poky/meta/recipes-bsp/u-boot/u-boot_2018.01.bb b/poky/meta/recipes-bsp/u-boot/u-boot_2018.07.bb
similarity index 100%
rename from poky/meta/recipes-bsp/u-boot/u-boot_2018.01.bb
rename to poky/meta/recipes-bsp/u-boot/u-boot_2018.07.bb
diff --git a/poky/meta/recipes-bsp/usbutils/usbutils/usb-devices-avoid-dependency-on-bash.patch b/poky/meta/recipes-bsp/usbutils/usbutils/usb-devices-avoid-dependency-on-bash.patch
index a6b241f..7edff26 100644
--- a/poky/meta/recipes-bsp/usbutils/usbutils/usb-devices-avoid-dependency-on-bash.patch
+++ b/poky/meta/recipes-bsp/usbutils/usbutils/usb-devices-avoid-dependency-on-bash.patch
@@ -1,30 +1,30 @@
-From 333d5fbbc03481f1aa222bd68c2609db168ae3e0 Mon Sep 17 00:00:00 2001
-From: Paul Eggleton <paul.eggleton@linux.intel.com>
-Date: Thu, 26 Jul 2012 10:37:32 +0100
-Subject: [PATCH] usb-devices: avoid dependency on bash
+Upstream-Status: Backport (https://github.com/gregkh/usbutils/commit/508d1acf42e1bfd470c6bf1a188574c69c20aeed)
+Signed-off-by: Ross Burton <ross.burton@intel.com>
 
-By virtue of having #!/bin/bash this script declared that it requires
-bash, however manual examination, checkbashisms and tests with dash
-and busybox show that it doesn't contain any bashisms, so change the
-header to avoid the dependency.
+From 1c9162a5b30550aec8fa163906067bc179291b57 Mon Sep 17 00:00:00 2001
+From: Ross Burton <ross.burton@intel.com>
+Date: Fri, 27 Jul 2018 15:28:34 +0100
+Subject: [PATCH] usb-devices: use /bin/sh
 
-Upstream-Status: Pending
+This script doesn't use any bashisms, so change the hashbang to /bin/sh.
 
-Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
+Fixes #73.
+
+Signed-off-by: Ross Burton <ross.burton@intel.com>
 ---
- usb-devices |    2 +-
+ usb-devices | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/usb-devices b/usb-devices
-index b2052e2..14a5358 100755
+index afb4217..89d1b7d 100755
 --- a/usb-devices
 +++ b/usb-devices
 @@ -1,4 +1,4 @@
 -#!/bin/bash
 +#!/bin/sh
- 
- # Copyright: 2009 Greg Kroah-Hartman <greg@kroah.com>
- #            2009 Randy Dunlap <rdunlap@xenotime.net>
+ # SPDX-License-Identifier: GPL-2.0+
+ #
+ # Copyright (c) 2009 Greg Kroah-Hartman <greg@kroah.com>
 -- 
-1.7.9.5
+2.11.0
 
diff --git a/poky/meta/recipes-bsp/usbutils/usbutils_009.bb b/poky/meta/recipes-bsp/usbutils/usbutils_009.bb
deleted file mode 100644
index 3ffc0dd..0000000
--- a/poky/meta/recipes-bsp/usbutils/usbutils_009.bb
+++ /dev/null
@@ -1,34 +0,0 @@
-SUMMARY = "Host side USB console utilities"
-DESCRIPTION = "Contains the lsusb utility for inspecting the devices connected to the USB bus."
-HOMEPAGE = "http://www.linux-usb.org"
-SECTION = "base"
-
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-
-DEPENDS = "libusb zlib virtual/libiconv udev"
-
-SRC_URI = "${KERNELORG_MIRROR}/linux/utils/usb/usbutils/usbutils-${PV}.tar.gz \
-           file://usb-devices-avoid-dependency-on-bash.patch \
-          "
-
-SRC_URI[md5sum] = "b5dbc498b2eb5058f7a57fc6532d0aad"
-SRC_URI[sha256sum] = "e73543293a17c7803994eac97a49e58b377e08e6299ba11aad09794b91340e8b"
-
-inherit autotools pkgconfig distro_features_check update-alternatives
-
-ALTERNATIVE_${PN} = "lsusb"
-ALTERNATIVE_PRIORITY = "100"
-
-FILES_${PN}-dev += "${datadir}/pkgconfig"
-
-RRECOMMENDS_${PN} = "udev-hwdb"
-RDEPENDS_${PN}-ptest = "libboost-system libboost-thread"
-
-PACKAGE_BEFORE_PN =+ "${PN}-python"
-FILES_${PN}-python += "${bindir}/lsusb.py"
-RDEPENDS_${PN}-python = "python3-core"
-
-do_install_append() {
-    sed -i -E '1s,#!.+python,#!${bindir}/python3,' ${D}${bindir}/lsusb.py
-}
diff --git a/poky/meta/recipes-bsp/usbutils/usbutils_010.bb b/poky/meta/recipes-bsp/usbutils/usbutils_010.bb
new file mode 100644
index 0000000..e6d05b8
--- /dev/null
+++ b/poky/meta/recipes-bsp/usbutils/usbutils_010.bb
@@ -0,0 +1,32 @@
+SUMMARY = "Host side USB console utilities"
+DESCRIPTION = "Contains the lsusb utility for inspecting the devices connected to the USB bus."
+HOMEPAGE = "http://www.linux-usb.org"
+SECTION = "base"
+
+LICENSE = "GPLv2+ & (GPLv2 | GPLv3)"
+# License files went missing in 010, when 011 is released add LICENSES/* back
+LIC_FILES_CHKSUM = "file://lsusb.c;endline=1;md5=7d4861d978ff5ba7cb2b319ed1d4afe3 \
+                    file://lsusb.py.in;beginline=2;endline=2;md5=194d6a0226bf90f4f683e8968878b6cd"
+
+DEPENDS = "libusb1 virtual/libiconv udev"
+
+SRC_URI = "${KERNELORG_MIRROR}/linux/utils/usb/usbutils/usbutils-${PV}.tar.gz \
+           file://usb-devices-avoid-dependency-on-bash.patch \
+          "
+SRC_URI[md5sum] = "5eb2d2d68f9ed6dc3e9659a5988f7ed6"
+SRC_URI[sha256sum] = "881ba47fb2df10c3ba54a4cd6755a90377180890788e476f99d480ea9bc8bb58"
+
+inherit autotools pkgconfig distro_features_check update-alternatives
+
+ALTERNATIVE_${PN} = "lsusb"
+ALTERNATIVE_PRIORITY = "100"
+
+# The binaries are mostly GPLv2+ apart from lsusb.py which is GPLv2 or v3.
+LICENSE_${PN} = "GPLv2+"
+LICENSE_${PN}-python = "GPLv2 | GPLv3"
+
+RRECOMMENDS_${PN} = "udev-hwdb"
+
+PACKAGE_BEFORE_PN =+ "${PN}-python"
+FILES_${PN}-python += "${bindir}/lsusb.py"
+RDEPENDS_${PN}-python = "python3-core"
diff --git a/poky/meta/recipes-bsp/v86d/v86d/Support-for-cross-compilation.patch b/poky/meta/recipes-bsp/v86d/v86d/Support-for-cross-compilation.patch
new file mode 100644
index 0000000..15f70a5
--- /dev/null
+++ b/poky/meta/recipes-bsp/v86d/v86d/Support-for-cross-compilation.patch
@@ -0,0 +1,34 @@
+From 8eda59654fd31416164c78f6068715b01767ed4e Mon Sep 17 00:00:00 2001
+From: Serhey Popovych <serhe.popovych@gmail.com>
+Date: Wed, 31 Oct 2018 07:31:47 -0400
+Subject: v86d: Support for cross compilation
+
+It is common to build on one system for another (e.g. on IBM Power
+machine for Intel x86) where HOST_ARCH (uname -m) != TARGET_ARCH.
+
+Take TARGET_ARCH from environment if it is given, otherwise fall back
+to `uname -m`.
+
+Upstream-Status: Pending
+Signed-off-by: Serhey Popovych <serhe.popovych@gmail.com>
+---
+ configure | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/configure b/configure
+index cbbd6b3..046aa99 100755
+--- a/configure
++++ b/configure
+@@ -23,7 +23,8 @@ copt_x86emu_type="bool"
+ copt_x86emu_def=auto
+ copt_x86emu_test()
+ {
+-	local m=`uname -m`
++	local m="${TARGET_ARCH:-$(uname -m)}"
++
+ 	if [ "$m" = "i686" -o "$m" = "i586" -o "$m" = "i486" -o "$m" = "i386" ]; then
+ 		echo "n";
+ 	elif [ "$m" = "x86_64" ]; then
+-- 
+1.8.3.1
+
diff --git a/poky/meta/recipes-bsp/v86d/v86d/aarch64-host.patch b/poky/meta/recipes-bsp/v86d/v86d/aarch64-host.patch
deleted file mode 100644
index 701fed7..0000000
--- a/poky/meta/recipes-bsp/v86d/v86d/aarch64-host.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-Accept aarch64 as valid build host
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Index: v86d-0.1.10/configure
-===================================================================
---- v86d-0.1.10.orig/configure
-+++ v86d-0.1.10/configure
-@@ -26,7 +26,7 @@ copt_x86emu_test()
- 	local m=`uname -m`
- 	if [ "$m" = "i686" -o "$m" = "i586" -o "$m" = "i486" -o "$m" = "i386" ]; then
- 		echo "n";
--	elif [ "$m" = "x86_64" ]; then
-+	elif [ "$m" = "x86_64" -o "$m" = "aarch64" ]; then
- 		echo "y";
- 	else
- 		echo "It looks like your architecture '$m' isn't supported by this version of v86d." >&2
diff --git a/poky/meta/recipes-bsp/v86d/v86d_0.1.10.bb b/poky/meta/recipes-bsp/v86d/v86d_0.1.10.bb
index f97b80d..84e27d2 100644
--- a/poky/meta/recipes-bsp/v86d/v86d_0.1.10.bb
+++ b/poky/meta/recipes-bsp/v86d/v86d_0.1.10.bb
@@ -12,7 +12,7 @@
 SRC_URI = "http://snapshot.debian.org/archive/debian/20110427T035506Z/pool/main/v/${BPN}/${BPN}_${PV}.orig.tar.gz \
            file://Update-x86emu-from-X.org.patch \
            file://ar-from-env.patch \
-           file://aarch64-host.patch \
+           file://Support-for-cross-compilation.patch \
 "
 
 SRC_URI[md5sum] = "889686ec8424468fe0d205742e77a4c2"
@@ -22,7 +22,7 @@
 COMPATIBLE_HOST = '(i.86|x86_64).*-linux'
 
 do_configure () {
-	./configure --with-x86emu
+	TARGET_ARCH="${TARGET_ARCH}" ./configure --with-x86emu
 }
 
 do_compile () {
diff --git a/poky/meta/recipes-connectivity/avahi/avahi-ui_0.7.bb b/poky/meta/recipes-connectivity/avahi/avahi-ui_0.7.bb
index 5648e38..a77653b 100644
--- a/poky/meta/recipes-connectivity/avahi/avahi-ui_0.7.bb
+++ b/poky/meta/recipes-connectivity/avahi/avahi-ui_0.7.bb
@@ -1,31 +1,18 @@
-LIC_FILES_CHKSUM = "file://LICENSE;md5=2d5025d4aa3495befef8f17206a5b0a1 \
-                    file://avahi-common/address.h;endline=25;md5=b1d1d2cda1c07eb848ea7d6215712d9d \
-                    file://avahi-core/dns.h;endline=23;md5=6fe82590b81aa0ddea5095b548e2fdcb \
-                    file://avahi-daemon/main.c;endline=21;md5=9ee77368c5407af77caaef1b07285969 \
-                    file://avahi-client/client.h;endline=23;md5=f4ac741a25c4f434039ba3e18c8674cf"
-
 require avahi.inc
 
 inherit distro_features_check
 ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
 
-SRC_URI[md5sum] = "d76c59d0882ac6c256d70a2a585362a6"
-SRC_URI[sha256sum] = "57a99b5dfe7fdae794e3d1ee7a62973a368e91e414bd0dfa5d84434de5b14804"
-
 DEPENDS += "avahi"
 
 AVAHI_GTK = "gtk3"
 
 S = "${WORKDIR}/avahi-${PV}"
 
-PACKAGES = "${PN} ${PN}-utils ${PN}-dbg ${PN}-dev ${PN}-staticdev ${PN}-doc avahi-discover"
+PACKAGES += "${PN}-utils avahi-discover"
 
 FILES_${PN} = "${libdir}/libavahi-ui*.so.*"
-FILES_${PN}-dev += "${libdir}/libavahi-ui${SOLIBSDEV}"
-FILES_${PN}-staticdev += "${libdir}/libavahi-ui.a"
-
 FILES_${PN}-utils = "${bindir}/b* ${datadir}/applications/b*"
-
 FILES_avahi-discover = "${datadir}/applications/avahi-discover.desktop \
                         ${datadir}/avahi/interfaces/avahi-discover.ui \
                         ${bindir}/avahi-discover-standalone \
@@ -59,4 +46,3 @@
         rm ${D}${libdir}/girepository-1.0/ -rf
         rm ${D}${datadir}/gir-1.0/ -rf
 }
-
diff --git a/poky/meta/recipes-connectivity/avahi/avahi.inc b/poky/meta/recipes-connectivity/avahi/avahi.inc
index ec368de..1184684 100644
--- a/poky/meta/recipes-connectivity/avahi/avahi.inc
+++ b/poky/meta/recipes-connectivity/avahi/avahi.inc
@@ -13,16 +13,20 @@
 # major part is under LGPLv2.1+, but several .dtd, .xsl, initscripts and
 # python scripts are under GPLv2+
 LICENSE = "GPLv2+ & LGPLv2.1+"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=2d5025d4aa3495befef8f17206a5b0a1 \
+                    file://avahi-common/address.h;endline=25;md5=b1d1d2cda1c07eb848ea7d6215712d9d \
+                    file://avahi-core/dns.h;endline=23;md5=6fe82590b81aa0ddea5095b548e2fdcb \
+                    file://avahi-daemon/main.c;endline=21;md5=9ee77368c5407af77caaef1b07285969 \
+                    file://avahi-client/client.h;endline=23;md5=f4ac741a25c4f434039ba3e18c8674cf"
+
+SRC_URI = "https://github.com/lathiat/avahi/releases/download/v${PV}/avahi-${PV}.tar.gz"
+
+UPSTREAM_CHECK_URI = "https://github.com/lathiat/avahi/releases/"
+SRC_URI[md5sum] = "d76c59d0882ac6c256d70a2a585362a6"
+SRC_URI[sha256sum] = "57a99b5dfe7fdae794e3d1ee7a62973a368e91e414bd0dfa5d84434de5b14804"
 
 DEPENDS = "expat libcap libdaemon glib-2.0 intltool-native"
 
-SRC_URI = "https://github.com/lathiat/avahi/releases/download/v${PV}/avahi-${PV}.tar.gz \
-          file://00avahi-autoipd \
-          file://99avahi-autoipd \
-          file://initscript.patch \
-          "
-UPSTREAM_CHECK_URI = "https://github.com/lathiat/avahi/releases/"
-
 # For gtk related PACKAGECONFIGs: gtk, gtk3
 AVAHI_GTK ?= ""
 
@@ -31,18 +35,7 @@
 PACKAGECONFIG[gtk] = "--enable-gtk,--disable-gtk,gtk+"
 PACKAGECONFIG[gtk3] = "--enable-gtk3,--disable-gtk3,gtk+3"
 
-USERADD_PACKAGES = "avahi-daemon avahi-autoipd"
-USERADD_PARAM_avahi-daemon = "--system --home /run/avahi-daemon \
-                              --no-create-home --shell /bin/false \
-                              --user-group avahi"
-
-USERADD_PARAM_avahi-autoipd = "--system --home /run/avahi-autoipd \
-                              --no-create-home --shell /bin/false \
-                              --user-group \
-                              -c \"Avahi autoip daemon\" \
-                              avahi-autoipd"
-
-inherit autotools pkgconfig update-rc.d gettext useradd gobject-introspection
+inherit autotools pkgconfig gettext gobject-introspection
 
 EXTRA_OECONF = "--with-avahi-priv-access-group=adm \
              --disable-stack-protector \
@@ -73,67 +66,12 @@
     export GIR_EXTRA_LIBS_PATH="${B}/avahi-gobject/.libs:${B}/avahi-common/.libs:${B}/avahi-client/.libs:${B}/avahi-glib/.libs"
 }
 
-PACKAGES =+ "avahi-daemon libavahi-common libavahi-core libavahi-client avahi-dnsconfd libavahi-glib libavahi-ui avahi-autoipd avahi-utils"
-
-# As avahi doesn't put any files into PN, clear the files list to avoid problems
-# if extra libraries appear.
-FILES_${PN} = ""
-FILES_avahi-autoipd = "${sbindir}/avahi-autoipd \
-                       ${sysconfdir}/avahi/avahi-autoipd.action \
-                       ${sysconfdir}/dhcp/*/avahi-autoipd \
-                       ${sysconfdir}/udhcpc.d/00avahi-autoipd \
-                       ${sysconfdir}/udhcpc.d/99avahi-autoipd"
-FILES_libavahi-common = "${libdir}/libavahi-common.so.*"
-FILES_libavahi-core = "${libdir}/libavahi-core.so.* ${libdir}/girepository-1.0/AvahiCore*.typelib"
-FILES_avahi-daemon = "${sbindir}/avahi-daemon \
-                      ${sysconfdir}/avahi/avahi-daemon.conf \
-                      ${sysconfdir}/avahi/hosts \
-                      ${sysconfdir}/avahi/services \
-                      ${sysconfdir}/dbus-1 \
-                      ${sysconfdir}/init.d/avahi-daemon \
-                      ${datadir}/avahi/introspection/*.introspect \
-                      ${datadir}/avahi/avahi-service.dtd \
-                      ${datadir}/avahi/service-types \
-                      ${datadir}/dbus-1/system-services"
-FILES_libavahi-client = "${libdir}/libavahi-client.so.*"
-FILES_libavahi-ui = "${libdir}/libavahi-ui.so.*"
-FILES_avahi-dnsconfd = "${sbindir}/avahi-dnsconfd \
-                        ${sysconfdir}/avahi/avahi-dnsconfd.action \
-                        ${sysconfdir}/init.d/avahi-dnsconfd"
-FILES_libavahi-glib = "${libdir}/libavahi-glib.so.*"
-FILES_libavahi-gobject = "${libdir}/libavahi-gobject.so.*  ${libdir}/girepository-1.0/Avahi*.typelib"
-FILES_avahi-utils = "${bindir}/avahi-*"
-
-RDEPENDS_${PN}-dev = "avahi-daemon (= ${EXTENDPKGV}) libavahi-core (= ${EXTENDPKGV}) libavahi-client (= ${EXTENDPKGV})"
-
-RRECOMMENDS_avahi-daemon_append_libc-glibc = " libnss-mdns"
 RRECOMMENDS_${PN}_append_libc-glibc = " libnss-mdns"
 
-CONFFILES_avahi-daemon = "${sysconfdir}/avahi/avahi-daemon.conf"
-
-INITSCRIPT_PACKAGES = "avahi-daemon avahi-dnsconfd"
-INITSCRIPT_NAME_avahi-daemon = "avahi-daemon"
-INITSCRIPT_PARAMS_avahi-daemon = "defaults 21 19"
-INITSCRIPT_NAME_avahi-dnsconfd = "avahi-dnsconfd"
-INITSCRIPT_PARAMS_avahi-dnsconfd = "defaults 22 19"
-
 do_install() {
 	autotools_do_install
 	rm -rf ${D}/run
 	rm -rf ${D}${datadir}/dbus-1/interfaces
 	test -d ${D}${datadir}/dbus-1 && rmdir --ignore-fail-on-non-empty ${D}${datadir}/dbus-1
 	rm -rf ${D}${libdir}/avahi
-
-	install -d ${D}${sysconfdir}/udhcpc.d
-	install ${WORKDIR}/00avahi-autoipd ${D}${sysconfdir}/udhcpc.d
-	install ${WORKDIR}/99avahi-autoipd ${D}${sysconfdir}/udhcpc.d
-}
-
-# At the time the postinst runs, dbus might not be setup so only restart if running 
-# Don't exit early, because update-rc.d needs to run subsequently.
-
-pkg_postinst_avahi-daemon () {
-if [ -z "$D" ]; then
-	killall -q -HUP dbus-daemon || true
-fi
 }
diff --git a/poky/meta/recipes-connectivity/avahi/avahi_0.7.bb b/poky/meta/recipes-connectivity/avahi/avahi_0.7.bb
index 7c91f10..3d5f334 100644
--- a/poky/meta/recipes-connectivity/avahi/avahi_0.7.bb
+++ b/poky/meta/recipes-connectivity/avahi/avahi_0.7.bb
@@ -1,20 +1,80 @@
 require avahi.inc
 
-inherit systemd
+SRC_URI += "file://00avahi-autoipd \
+           file://99avahi-autoipd \
+           file://initscript.patch \
+           file://0001-Fix-opening-etc-resolv.conf-error.patch \
+           "
+
+inherit update-rc.d systemd useradd
+
+PACKAGES =+ "libavahi-gobject avahi-daemon libavahi-common libavahi-core libavahi-client avahi-dnsconfd libavahi-glib avahi-autoipd avahi-utils"
+
+# As avahi doesn't put any files into PN, clear the files list to avoid problems
+# if extra libraries appear.
+FILES_${PN} = ""
+FILES_avahi-autoipd = "${sbindir}/avahi-autoipd \
+                       ${sysconfdir}/avahi/avahi-autoipd.action \
+                       ${sysconfdir}/dhcp/*/avahi-autoipd \
+                       ${sysconfdir}/udhcpc.d/00avahi-autoipd \
+                       ${sysconfdir}/udhcpc.d/99avahi-autoipd"
+FILES_libavahi-common = "${libdir}/libavahi-common.so.*"
+FILES_libavahi-core = "${libdir}/libavahi-core.so.* ${libdir}/girepository-1.0/AvahiCore*.typelib"
+FILES_avahi-daemon = "${sbindir}/avahi-daemon \
+                      ${sysconfdir}/avahi/avahi-daemon.conf \
+                      ${sysconfdir}/avahi/hosts \
+                      ${sysconfdir}/avahi/services \
+                      ${sysconfdir}/dbus-1 \
+                      ${sysconfdir}/init.d/avahi-daemon \
+                      ${datadir}/avahi/introspection/*.introspect \
+                      ${datadir}/avahi/avahi-service.dtd \
+                      ${datadir}/avahi/service-types \
+                      ${datadir}/dbus-1/system-services"
+FILES_libavahi-client = "${libdir}/libavahi-client.so.*"
+FILES_avahi-dnsconfd = "${sbindir}/avahi-dnsconfd \
+                        ${sysconfdir}/avahi/avahi-dnsconfd.action \
+                        ${sysconfdir}/init.d/avahi-dnsconfd"
+FILES_libavahi-glib = "${libdir}/libavahi-glib.so.*"
+FILES_libavahi-gobject = "${libdir}/libavahi-gobject.so.*  ${libdir}/girepository-1.0/Avahi*.typelib"
+FILES_avahi-utils = "${bindir}/avahi-*"
+
+RDEPENDS_${PN}-dev = "avahi-daemon (= ${EXTENDPKGV}) libavahi-core (= ${EXTENDPKGV}) libavahi-client (= ${EXTENDPKGV})"
+
+RRECOMMENDS_avahi-daemon_append_libc-glibc = " libnss-mdns"
+
+CONFFILES_avahi-daemon = "${sysconfdir}/avahi/avahi-daemon.conf"
+
+USERADD_PACKAGES = "avahi-daemon avahi-autoipd"
+USERADD_PARAM_avahi-daemon = "--system --home /run/avahi-daemon \
+                              --no-create-home --shell /bin/false \
+                              --user-group avahi"
+
+USERADD_PARAM_avahi-autoipd = "--system --home /run/avahi-autoipd \
+                              --no-create-home --shell /bin/false \
+                              --user-group \
+                              -c \"Avahi autoip daemon\" \
+                              avahi-autoipd"
+
+INITSCRIPT_PACKAGES = "avahi-daemon avahi-dnsconfd"
+INITSCRIPT_NAME_avahi-daemon = "avahi-daemon"
+INITSCRIPT_PARAMS_avahi-daemon = "defaults 21 19"
+INITSCRIPT_NAME_avahi-dnsconfd = "avahi-dnsconfd"
+INITSCRIPT_PARAMS_avahi-dnsconfd = "defaults 22 19"
 
 SYSTEMD_PACKAGES = "${PN}-daemon ${PN}-dnsconfd"
 SYSTEMD_SERVICE_${PN}-daemon = "avahi-daemon.service"
 SYSTEMD_SERVICE_${PN}-dnsconfd = "avahi-dnsconfd.service"
 
-LIC_FILES_CHKSUM = "file://LICENSE;md5=2d5025d4aa3495befef8f17206a5b0a1 \
-                    file://avahi-common/address.h;endline=25;md5=b1d1d2cda1c07eb848ea7d6215712d9d \
-                    file://avahi-core/dns.h;endline=23;md5=6fe82590b81aa0ddea5095b548e2fdcb \
-                    file://avahi-daemon/main.c;endline=21;md5=9ee77368c5407af77caaef1b07285969 \
-                    file://avahi-client/client.h;endline=23;md5=f4ac741a25c4f434039ba3e18c8674cf"
+do_install_append() {
+	install -d ${D}${sysconfdir}/udhcpc.d
+	install ${WORKDIR}/00avahi-autoipd ${D}${sysconfdir}/udhcpc.d
+	install ${WORKDIR}/99avahi-autoipd ${D}${sysconfdir}/udhcpc.d
+}
 
-SRC_URI[md5sum] = "d76c59d0882ac6c256d70a2a585362a6"
-SRC_URI[sha256sum] = "57a99b5dfe7fdae794e3d1ee7a62973a368e91e414bd0dfa5d84434de5b14804"
-
-DEPENDS += "intltool-native"
-
-PACKAGES =+ "libavahi-gobject"
+# At the time the postinst runs, dbus might not be setup so only restart if running 
+# Don't exit early, because update-rc.d needs to run subsequently.
+pkg_postinst_avahi-daemon () {
+if [ -z "$D" ]; then
+	killall -q -HUP dbus-daemon || true
+fi
+}
diff --git a/poky/meta/recipes-connectivity/avahi/files/0001-Fix-opening-etc-resolv.conf-error.patch b/poky/meta/recipes-connectivity/avahi/files/0001-Fix-opening-etc-resolv.conf-error.patch
new file mode 100644
index 0000000..11e7e8a
--- /dev/null
+++ b/poky/meta/recipes-connectivity/avahi/files/0001-Fix-opening-etc-resolv.conf-error.patch
@@ -0,0 +1,40 @@
+From 78967814f5c37ed67f4cf64d70c9f76a03ee89bc Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Wed, 20 Jun 2018 13:57:35 +0800
+Subject: [PATCH] Fix opening /etc/resolv.conf error
+
+Fix to start avahi-daemon after systemd-resolved.service. This is because
+/etc/resolv.conf is a link to /etc/resolv-conf.systemd which in turn is
+a symlink to /run/systemd/resolve/resolv.conf. And /run/systemd/resolve/resolv.conf
+is created by systemd-resolved.service by default in current OE's systemd
+based systems.
+
+This fixes errro like below.
+
+  Failed to open /etc/resolv.conf: Invalid argument
+
+In fact, handling of /etc/resolv.conf is quite distro specific. So this patch
+is marked as OE specific.
+
+Upstream-Status: Inappropriate [OE Specific]
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ avahi-daemon/avahi-daemon.service.in | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/avahi-daemon/avahi-daemon.service.in b/avahi-daemon/avahi-daemon.service.in
+index 548c834..63e28e4 100644
+--- a/avahi-daemon/avahi-daemon.service.in
++++ b/avahi-daemon/avahi-daemon.service.in
+@@ -18,6 +18,7 @@
+ [Unit]
+ Description=Avahi mDNS/DNS-SD Stack
+ Requires=avahi-daemon.socket
++After=systemd-resolved.service
+ 
+ [Service]
+ Type=dbus
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-connectivity/bind/bind/0001-avoid-start-failure-with-bind-user.patch b/poky/meta/recipes-connectivity/bind/bind/0001-avoid-start-failure-with-bind-user.patch
new file mode 100644
index 0000000..8db96ec
--- /dev/null
+++ b/poky/meta/recipes-connectivity/bind/bind/0001-avoid-start-failure-with-bind-user.patch
@@ -0,0 +1,27 @@
+From 31dde3562f287429eea94b77250d184818b49063 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Mon, 15 Oct 2018 16:55:09 +0800
+Subject: [PATCH] avoid start failure with bind user
+
+Upstream-Status: Pending
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ init.d | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/init.d b/init.d
+index b2eec60..6e03936 100644
+--- a/init.d
++++ b/init.d
+@@ -57,6 +57,7 @@ case "$1" in
+ 	modprobe capability >/dev/null 2>&1 || true
+ 	if [ ! -f /etc/bind/rndc.key ]; then
+ 	    /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
++	    chown root:bind /etc/bind/rndc.key >/dev/null 2>&1 || true
+ 	    chmod 0640 /etc/bind/rndc.key
+ 	fi
+ 	if [ -f /var/run/named/named.pid ]; then
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-connectivity/bind/bind/0001-configure.in-remove-useless-L-use_openssl-lib.patch b/poky/meta/recipes-connectivity/bind/bind/0001-configure.in-remove-useless-L-use_openssl-lib.patch
new file mode 100644
index 0000000..871bb2a
--- /dev/null
+++ b/poky/meta/recipes-connectivity/bind/bind/0001-configure.in-remove-useless-L-use_openssl-lib.patch
@@ -0,0 +1,32 @@
+From 950867d9fd3f690e271c8c807b6eed144b2935b2 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Mon, 27 Aug 2018 15:00:51 +0800
+Subject: [PATCH] configure.in: remove useless `-L$use_openssl/lib'
+
+Since `--with-openssl=${STAGING_DIR_HOST}${prefix}' is used in bind recipe,
+the `-L$use_openssl/lib' has a hardcoded suffix, removing it is harmless
+and helpful for clean up host build path in isc-config.sh
+
+Upstream-Status: Inappropriate [oe-core specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ configure.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.in b/configure.in
+index 54efc55..76ac0eb 100644
+--- a/configure.in
++++ b/configure.in
+@@ -1691,7 +1691,7 @@ If you don't want OpenSSL, use --without-openssl])
+ 				fi
+ 				;;
+ 			*)
+-				DST_OPENSSL_LIBS="-L$use_openssl/lib -lcrypto"
++				DST_OPENSSL_LIBS="-lcrypto"
+ 				;;
+ 			esac
+ 		fi
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-connectivity/bind/bind/0001-gen.c-extend-DIRNAMESIZE-from-256-to-512.patch b/poky/meta/recipes-connectivity/bind/bind/0001-gen.c-extend-DIRNAMESIZE-from-256-to-512.patch
index 1215093..a8d601d 100644
--- a/poky/meta/recipes-connectivity/bind/bind/0001-gen.c-extend-DIRNAMESIZE-from-256-to-512.patch
+++ b/poky/meta/recipes-connectivity/bind/bind/0001-gen.c-extend-DIRNAMESIZE-from-256-to-512.patch
@@ -7,11 +7,11 @@
  lib/dns/gen.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-diff --git a/lib/dns/gen.c b/lib/dns/gen.c
-index 7a7dafb..51a0435 100644
---- a/lib/dns/gen.c
-+++ b/lib/dns/gen.c
-@@ -148,7 +148,7 @@ static const char copyright[] =
+Index: bind-9.11.3/lib/dns/gen.c
+===================================================================
+--- bind-9.11.3.orig/lib/dns/gen.c
++++ bind-9.11.3/lib/dns/gen.c
+@@ -130,7 +130,7 @@ static const char copyright[] =
  #define TYPECLASSBUF (TYPECLASSLEN + 1)
  #define TYPECLASSFMT "%" STR(TYPECLASSLEN) "[-0-9a-z]_%d"
  #define ATTRIBUTESIZE 256
@@ -20,6 +20,3 @@
  
  static struct cc {
  	struct cc *next;
--- 
-1.9.1
-
diff --git a/poky/meta/recipes-connectivity/bind/bind/0001-lib-dns-gen.c-fix-too-long-error.patch b/poky/meta/recipes-connectivity/bind/bind/0001-lib-dns-gen.c-fix-too-long-error.patch
index 1ed858c..01874a4 100644
--- a/poky/meta/recipes-connectivity/bind/bind/0001-lib-dns-gen.c-fix-too-long-error.patch
+++ b/poky/meta/recipes-connectivity/bind/bind/0001-lib-dns-gen.c-fix-too-long-error.patch
@@ -13,11 +13,11 @@
  lib/dns/gen.c |    4 ++++
  1 file changed, 4 insertions(+)
 
-diff --git a/lib/dns/gen.c b/lib/dns/gen.c
-index 51a0435..3d7214f 100644
---- a/lib/dns/gen.c
-+++ b/lib/dns/gen.c
-@@ -148,7 +148,11 @@ static const char copyright[] =
+Index: bind-9.11.3/lib/dns/gen.c
+===================================================================
+--- bind-9.11.3.orig/lib/dns/gen.c
++++ bind-9.11.3/lib/dns/gen.c
+@@ -130,7 +130,11 @@ static const char copyright[] =
  #define TYPECLASSBUF (TYPECLASSLEN + 1)
  #define TYPECLASSFMT "%" STR(TYPECLASSLEN) "[-0-9a-z]_%d"
  #define ATTRIBUTESIZE 256
@@ -29,6 +29,3 @@
  
  static struct cc {
  	struct cc *next;
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-connectivity/bind/bind/0001-named-lwresd-V-and-start-log-hide-build-options.patch b/poky/meta/recipes-connectivity/bind/bind/0001-named-lwresd-V-and-start-log-hide-build-options.patch
new file mode 100644
index 0000000..75908aa
--- /dev/null
+++ b/poky/meta/recipes-connectivity/bind/bind/0001-named-lwresd-V-and-start-log-hide-build-options.patch
@@ -0,0 +1,34 @@
+From a3af4a405baf5ff582e82aaba392dd9667d94bdc Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Mon, 27 Aug 2018 21:24:20 +0800
+Subject: [PATCH] `named/lwresd -V' and start log hide build options
+
+The build options expose build path directories, so hide them.
+[snip]
+$ named -V
+|built by make with *** (options are hidden)
+[snip]
+
+Upstream-Status: Inappropriate [oe-core specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ bin/named/include/named/globals.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/bin/named/include/named/globals.h b/bin/named/include/named/globals.h
+index ba3457e..7741da7 100644
+--- a/bin/named/include/named/globals.h
++++ b/bin/named/include/named/globals.h
+@@ -68,7 +68,7 @@ EXTERN const char *		ns_g_version		INIT(VERSION);
+ EXTERN const char *		ns_g_product		INIT(PRODUCT);
+ EXTERN const char *		ns_g_description	INIT(DESCRIPTION);
+ EXTERN const char *		ns_g_srcid		INIT(SRCID);
+-EXTERN const char *		ns_g_configargs		INIT(CONFIGARGS);
++EXTERN const char *		ns_g_configargs		INIT("*** (options are hidden)");
+ EXTERN const char *		ns_g_builder		INIT(BUILDER);
+ EXTERN in_port_t		ns_g_port		INIT(0);
+ EXTERN isc_dscp_t		ns_g_dscp		INIT(-1);
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-connectivity/bind/bind/CVE-2018-5740.patch b/poky/meta/recipes-connectivity/bind/bind/CVE-2018-5740.patch
new file mode 100644
index 0000000..7a2ba7e
--- /dev/null
+++ b/poky/meta/recipes-connectivity/bind/bind/CVE-2018-5740.patch
@@ -0,0 +1,72 @@
+Upstream-Status: Backport [https://ftp.isc.org/isc/bind9/9.11.4-P1/patches/CVE-2018-5740]
+
+CVE: CVE-2018-5740
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+
+diff --git a/CHANGES b/CHANGES
+index 750b600..3d8d655 100644
+--- a/CHANGES
++++ b/CHANGES
+@@ -1,3 +1,9 @@
++	--- 9.11.4-P1 released ---
++
++4997.	[security]	named could crash during recursive processing
++			of DNAME records when "deny-answer-aliases" was
++			in use. (CVE-2018-5740) [GL #387]
++
+ 	--- 9.11.4 released ---
+ 
+ 	--- 9.11.4rc2 released ---
+diff --git a/lib/dns/resolver.c b/lib/dns/resolver.c
+index 8f674a2..41d1385 100644
+--- a/lib/dns/resolver.c
++++ b/lib/dns/resolver.c
+@@ -6318,6 +6318,7 @@ is_answertarget_allowed(fetchctx_t *fctx, dns_name_t *qname, dns_name_t *rname,
+ 	unsigned int nlabels;
+ 	dns_fixedname_t fixed;
+ 	dns_name_t prefix;
++	int order;
+ 
+ 	REQUIRE(rdataset != NULL);
+ 	REQUIRE(rdataset->type == dns_rdatatype_cname ||
+@@ -6340,17 +6341,25 @@ is_answertarget_allowed(fetchctx_t *fctx, dns_name_t *qname, dns_name_t *rname,
+ 		tname = &cname.cname;
+ 		break;
+ 	case dns_rdatatype_dname:
++		if (dns_name_fullcompare(qname, rname, &order, &nlabels) !=
++		    dns_namereln_subdomain)
++		{
++			return (ISC_TRUE);
++		}
+ 		result = dns_rdata_tostruct(&rdata, &dname, NULL);
+ 		RUNTIME_CHECK(result == ISC_R_SUCCESS);
+ 		dns_name_init(&prefix, NULL);
+ 		tname = dns_fixedname_initname(&fixed);
+-		nlabels = dns_name_countlabels(qname) -
+-			  dns_name_countlabels(rname);
++		nlabels = dns_name_countlabels(rname);
+ 		dns_name_split(qname, nlabels, &prefix, NULL);
+ 		result = dns_name_concatenate(&prefix, &dname.dname, tname,
+ 					      NULL);
+-		if (result == DNS_R_NAMETOOLONG)
++		if (result == DNS_R_NAMETOOLONG) {
++			if (chainingp != NULL) {
++				*chainingp = ISC_TRUE;
++			}
+ 			return (ISC_TRUE);
++		}
+ 		RUNTIME_CHECK(result == ISC_R_SUCCESS);
+ 		break;
+ 	default:
+@@ -7071,7 +7080,9 @@ answer_response(fetchctx_t *fctx) {
+ 		}
+ 		if ((ardataset->type == dns_rdatatype_cname ||
+ 		     ardataset->type == dns_rdatatype_dname) &&
+-		     !is_answertarget_allowed(fctx, qname, aname, ardataset,
++		    type != ardataset->type &&
++		    type != dns_rdatatype_any &&
++		    !is_answertarget_allowed(fctx, qname, aname, ardataset,
+ 					      NULL))
+ 		{
+ 			return (DNS_R_SERVFAIL);
diff --git a/poky/meta/recipes-connectivity/bind/bind/bind-confgen-build-unix.o-once.patch b/poky/meta/recipes-connectivity/bind/bind/bind-confgen-build-unix.o-once.patch
deleted file mode 100644
index 8bc4ea3..0000000
--- a/poky/meta/recipes-connectivity/bind/bind/bind-confgen-build-unix.o-once.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-From 9b40619ff6fddfef2758ba797789f8487f412df3 Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Mon, 16 Feb 2015 00:50:01 -0800
-Subject: [PATCH] confgen: don't build unix.o twice
-
-Fixed:
-unix/os.o: file not recognized: File truncated
-collect2: error: ld returned 1 exit status
-
-This is because os.o was built twice:
-* The implicity rule (depends on unix/os.o)
-* The "make all" in unix subdir (depends on unix/os.o)
-
-Depend on subdirs which is unix only rather than unix/os.o will fix the
-problem.
-
-Upstream-Status: Pending
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-
-Update context(trailing whitespace) for version 9.10.5-P3.
-
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
----
- bin/confgen/Makefile.in |    4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/bin/confgen/Makefile.in b/bin/confgen/Makefile.in
-index dca272f..02becce 100644
---- a/bin/confgen/Makefile.in
-+++ b/bin/confgen/Makefile.in
-@@ -74,11 +74,11 @@ rndc-confgen.@O@: rndc-confgen.c
- ddns-confgen.@O@: ddns-confgen.c
- 	${LIBTOOL_MODE_COMPILE} ${CC} ${ALL_CFLAGS} -c ${srcdir}/ddns-confgen.c
- 
--rndc-confgen@EXEEXT@: rndc-confgen.@O@ util.@O@ keygen.@O@ ${UOBJS} ${CONFDEPLIBS}
-+rndc-confgen@EXEEXT@: rndc-confgen.@O@ util.@O@ keygen.@O@ ${CONFDEPLIBS} $(SUBDIRS)
- 	export BASEOBJS="rndc-confgen.@O@ util.@O@ keygen.@O@ ${UOBJS}"; \
- 	${FINALBUILDCMD}
- 
--ddns-confgen@EXEEXT@: ddns-confgen.@O@ util.@O@ keygen.@O@ ${UOBJS} ${CONFDEPLIBS}
-+ddns-confgen@EXEEXT@: ddns-confgen.@O@ util.@O@ keygen.@O@ ${CONFDEPLIBS} $(SUBDIRS)
- 	export BASEOBJS="ddns-confgen.@O@ util.@O@ keygen.@O@ ${UOBJS}"; \
- 	${FINALBUILDCMD}
- 
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-connectivity/bind/bind/bind-ensure-searching-for-json-headers-searches-sysr.patch b/poky/meta/recipes-connectivity/bind/bind/bind-ensure-searching-for-json-headers-searches-sysr.patch
index 13df3bb..37e210e 100644
--- a/poky/meta/recipes-connectivity/bind/bind/bind-ensure-searching-for-json-headers-searches-sysr.patch
+++ b/poky/meta/recipes-connectivity/bind/bind/bind-ensure-searching-for-json-headers-searches-sysr.patch
@@ -31,11 +31,11 @@
  configure.in | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-diff --git a/configure.in b/configure.in
-index c9ef3a601343..17a1f613e9ac 100644
---- a/configure.in
-+++ b/configure.in
-@@ -2139,7 +2139,7 @@ case "$use_libjson" in
+Index: bind-9.11.3/configure.in
+===================================================================
+--- bind-9.11.3.orig/configure.in
++++ bind-9.11.3/configure.in
+@@ -2574,7 +2574,7 @@ case "$use_libjson" in
  		libjson_libs=""
  		;;
  	auto|yes)
@@ -44,6 +44,3 @@
  		do
  			if test -f "${d}/include/json/json.h"
  			then
--- 
-2.4.2
-
diff --git a/poky/meta/recipes-connectivity/bind/bind/dont-test-on-host.patch b/poky/meta/recipes-connectivity/bind/bind/dont-test-on-host.patch
deleted file mode 100644
index b02ecb1..0000000
--- a/poky/meta/recipes-connectivity/bind/bind/dont-test-on-host.patch
+++ /dev/null
@@ -1,17 +0,0 @@
-Upstream-Status: Pending
-
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
-
-Index: bind-9.9.5/bin/Makefile.in
-===================================================================
---- bind-9.9.5.orig/bin/Makefile.in
-+++ bind-9.9.5/bin/Makefile.in
-@@ -19,7 +19,7 @@ srcdir =	@srcdir@
- VPATH =		@srcdir@
- top_srcdir =	@top_srcdir@
- 
--SUBDIRS =	named rndc dig delv dnssec tools tests nsupdate \
-+SUBDIRS =	named rndc dig delv dnssec tools nsupdate \
- 		check confgen @PYTHON_TOOLS@ @PKCS11_TOOLS@
- TARGETS =
- 
diff --git a/poky/meta/recipes-connectivity/bind/bind/use-python3-and-fix-install-lib-path.patch b/poky/meta/recipes-connectivity/bind/bind/use-python3-and-fix-install-lib-path.patch
deleted file mode 100644
index 9829f15..0000000
--- a/poky/meta/recipes-connectivity/bind/bind/use-python3-and-fix-install-lib-path.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-Use python3 rather default python which maybe links to python2 for oe. And add
-option for setup.py to install files to right directory.
-
-Upstream-Status: Inappropriate [OE specific]
-
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
----
-diff --git a/bin/python/Makefile.in b/bin/python/Makefile.in
-index a43a3c1..2e727f2 100644
---- a/bin/python/Makefile.in
-+++ b/bin/python/Makefile.in
-@@ -55,9 +55,9 @@ install:: ${TARGETS} installdirs
- 	${INSTALL_DATA} ${srcdir}/dnssec-coverage.8 ${DESTDIR}${mandir}/man8
- 	if test -n "${PYTHON}" ; then \
- 		if test -n "${DESTDIR}" ; then \
--			${PYTHON} ${srcdir}/setup.py install --root=${DESTDIR} --prefix=${prefix} ; \
-+			${PYTHON} ${srcdir}/setup.py install --root=${DESTDIR} --prefix=${prefix} --install-lib=${PYTHON_SITEPACKAGES_DIR} ; \
- 		else \
--			${PYTHON} ${srcdir}/setup.py install --prefix=${prefix} ; \
-+			${PYTHON} ${srcdir}/setup.py install --prefix=${prefix} --install-lib=${PYTHON_SITEPACKAGES_DIR} ; \
- 		fi \
- 	fi
- 
-diff --git a/configure.in b/configure.in
-index 314bb90..867923e 100644
---- a/configure.in
-+++ b/configure.in
-@@ -227,7 +227,7 @@ AC_ARG_WITH(python,
- [  --with-python=PATH      specify path to python interpreter],
-     use_python="$withval", use_python="unspec")
- 
--python="python python3 python3.5 python3.4 python3.3 python3.2 python2 python2.7"
-+python="python3 python3.5 python3.4 python3.3 python3.2 python2 python2.7"
- 
- testargparse='try: import argparse
- except: exit(1)'
diff --git a/poky/meta/recipes-connectivity/bind/bind_9.10.6.bb b/poky/meta/recipes-connectivity/bind/bind_9.10.6.bb
deleted file mode 100644
index 8b8835b..0000000
--- a/poky/meta/recipes-connectivity/bind/bind_9.10.6.bb
+++ /dev/null
@@ -1,123 +0,0 @@
-SUMMARY = "ISC Internet Domain Name Server"
-HOMEPAGE = "http://www.isc.org/sw/bind/"
-SECTION = "console/network"
-
-LICENSE = "ISC & BSD"
-LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=dba46507446198119bcde32a4feaab43"
-
-DEPENDS = "openssl libcap"
-
-SRC_URI = "https://ftp.isc.org/isc/bind9/${PV}/${BPN}-${PV}.tar.gz \
-           file://conf.patch \
-           file://make-etc-initd-bind-stop-work.patch \
-           file://dont-test-on-host.patch \
-           file://generate-rndc-key.sh \
-           file://named.service \
-           file://bind9 \
-           file://init.d-add-support-for-read-only-rootfs.patch \
-           file://bind-confgen-build-unix.o-once.patch \
-           file://0001-build-use-pkg-config-to-find-libxml2.patch \
-           file://bind-ensure-searching-for-json-headers-searches-sysr.patch \
-           file://0001-gen.c-extend-DIRNAMESIZE-from-256-to-512.patch \
-           file://0001-lib-dns-gen.c-fix-too-long-error.patch \
-           file://use-python3-and-fix-install-lib-path.patch \
-           "
-
-SRC_URI[md5sum] = "84e663284b17aee0df1ce6f248b137d7"
-SRC_URI[sha256sum] = "17bbcd2bd7b1d32f5ba4b30d5dbe8a39bce200079048073d1e0d050fdf47e69d"
-
-UPSTREAM_CHECK_URI = "https://ftp.isc.org/isc/bind9/"
-UPSTREAM_CHECK_REGEX = "(?P<pver>9(\.\d+)+(-P\d+)*)/"
-
-
-ENABLE_IPV6 = "--enable-ipv6=${@bb.utils.contains('DISTRO_FEATURES', 'ipv6', 'yes', 'no', d)}"
-EXTRA_OECONF = " ${ENABLE_IPV6} --with-libtool --enable-threads \
-                 --disable-devpoll --enable-epoll --with-gost=no \
-                 --with-gssapi=no --with-ecdsa=yes \
-                 --sysconfdir=${sysconfdir}/bind \
-                 --with-openssl=${STAGING_LIBDIR}/.. \
-               "
-
-inherit autotools update-rc.d systemd useradd pkgconfig python3-dir
-
-export PYTHON_SITEPACKAGES_DIR
-
-# PACKAGECONFIGs readline and libedit should NOT be set at same time
-PACKAGECONFIG ?= "readline"
-PACKAGECONFIG[httpstats] = "--with-libxml2,--without-libxml2,libxml2"
-PACKAGECONFIG[readline] = "--with-readline=-lreadline,,readline"
-PACKAGECONFIG[libedit] = "--with-readline=-ledit,,libedit"
-PACKAGECONFIG[urandom] = "--with-randomdev=/dev/urandom,--with-randomdev=/dev/random,,"
-
-USERADD_PACKAGES = "${PN}"
-USERADD_PARAM_${PN} = "--system --home ${localstatedir}/cache/bind --no-create-home \
-                       --user-group bind"
-
-INITSCRIPT_NAME = "bind"
-INITSCRIPT_PARAMS = "defaults"
-
-SYSTEMD_SERVICE_${PN} = "named.service"
-
-PARALLEL_MAKE = ""
-
-RDEPENDS_${PN} = "python3-core"
-RDEPENDS_${PN}-dev = ""
-
-PACKAGE_BEFORE_PN += "${PN}-utils"
-FILES_${PN}-utils = "${bindir}/host ${bindir}/dig"
-FILES_${PN}-dev += "${bindir}/isc-config.h"
-FILES_${PN} += "${sbindir}/generate-rndc-key.sh ${PYTHON_SITEPACKAGES_DIR}"
-
-PACKAGE_BEFORE_PN += "${PN}-libs"
-FILES_${PN}-libs = "${libdir}/*.so*"
-
-do_install_prepend() {
-	# clean host path in isc-config.sh before the hardlink created
-	# by "make install":
-	#   bind9-config -> isc-config.sh
-	sed -i -e "s,${STAGING_LIBDIR},${libdir}," ${B}/isc-config.sh
-}
-
-do_install_append() {
-	rm "${D}${bindir}/nslookup"
-	rm "${D}${mandir}/man1/nslookup.1"
-	rmdir "${D}${localstatedir}/run"
-	rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
-	install -d -o bind "${D}${localstatedir}/cache/bind"
-	install -d "${D}${sysconfdir}/bind"
-	install -d "${D}${sysconfdir}/init.d"
-	install -m 644 ${S}/conf/* "${D}${sysconfdir}/bind/"
-	install -m 755 "${S}/init.d" "${D}${sysconfdir}/init.d/bind"
-	sed -i -e '1s,#!.*python3,#! /usr/bin/python3,' ${D}${sbindir}/dnssec-coverage ${D}${sbindir}/dnssec-checkds
-
-	# Install systemd related files
-	install -d ${D}${sbindir}
-	install -m 755 ${WORKDIR}/generate-rndc-key.sh ${D}${sbindir}
-	install -d ${D}${systemd_unitdir}/system
-	install -m 0644 ${WORKDIR}/named.service ${D}${systemd_unitdir}/system
-	sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
-	       -e 's,@SBINDIR@,${sbindir},g' \
-	       ${D}${systemd_unitdir}/system/named.service
-
-	install -d ${D}${sysconfdir}/default
-	install -m 0644 ${WORKDIR}/bind9 ${D}${sysconfdir}/default
-
-	if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-		install -d ${D}${sysconfdir}/tmpfiles.d
-		echo "d /run/named 0755 bind bind - -" > ${D}${sysconfdir}/tmpfiles.d/bind.conf
-	fi
-
-    rm -f ${D}${PYTHON_SITEPACKAGES_DIR}/isc/*.pyc
-}
-
-CONFFILES_${PN} = " \
-	${sysconfdir}/bind/named.conf \
-	${sysconfdir}/bind/named.conf.local \
-	${sysconfdir}/bind/named.conf.options \
-	${sysconfdir}/bind/db.0 \
-	${sysconfdir}/bind/db.127 \
-	${sysconfdir}/bind/db.empty \
-	${sysconfdir}/bind/db.local \
-	${sysconfdir}/bind/db.root \
-	"
-
diff --git a/poky/meta/recipes-connectivity/bind/bind_9.11.4.bb b/poky/meta/recipes-connectivity/bind/bind_9.11.4.bb
new file mode 100644
index 0000000..cb4a21a
--- /dev/null
+++ b/poky/meta/recipes-connectivity/bind/bind_9.11.4.bb
@@ -0,0 +1,137 @@
+SUMMARY = "ISC Internet Domain Name Server"
+HOMEPAGE = "http://www.isc.org/sw/bind/"
+SECTION = "console/network"
+
+LICENSE = "ISC & BSD"
+LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=6ba7c9fe0c888a943c79c93e6de744fb"
+
+DEPENDS = "openssl libcap zlib"
+
+SRC_URI = "https://ftp.isc.org/isc/bind9/${PV}/${BPN}-${PV}.tar.gz \
+           file://conf.patch \
+           file://named.service \
+           file://bind9 \
+           file://generate-rndc-key.sh \
+           file://make-etc-initd-bind-stop-work.patch \
+           file://init.d-add-support-for-read-only-rootfs.patch \
+           file://bind-ensure-searching-for-json-headers-searches-sysr.patch \
+           file://0001-gen.c-extend-DIRNAMESIZE-from-256-to-512.patch \
+           file://0001-lib-dns-gen.c-fix-too-long-error.patch \
+           file://0001-configure.in-remove-useless-L-use_openssl-lib.patch \
+           file://0001-named-lwresd-V-and-start-log-hide-build-options.patch \
+           file://0001-avoid-start-failure-with-bind-user.patch \
+           file://CVE-2018-5740.patch \
+"
+
+SRC_URI[md5sum] = "9b4834d78f30cdb796ce437262272a36"
+SRC_URI[sha256sum] = "595070b031f869f8939656b5a5d11b121211967f15f6afeafa895df745279617"
+
+UPSTREAM_CHECK_URI = "https://ftp.isc.org/isc/bind9/"
+UPSTREAM_CHECK_REGEX = "(?P<pver>9(\.\d+)+(-P\d+)*)/"
+
+inherit autotools update-rc.d systemd useradd pkgconfig multilib_script
+
+MULTILIB_SCRIPTS = "${PN}:${bindir}/bind9-config ${PN}:${bindir}/isc-config.sh"
+
+# PACKAGECONFIGs readline and libedit should NOT be set at same time
+PACKAGECONFIG ?= "readline"
+PACKAGECONFIG[httpstats] = "--with-libxml2=${STAGING_DIR_HOST}${prefix},--without-libxml2,libxml2"
+PACKAGECONFIG[readline] = "--with-readline=-lreadline,,readline"
+PACKAGECONFIG[libedit] = "--with-readline=-ledit,,libedit"
+PACKAGECONFIG[urandom] = "--with-randomdev=/dev/urandom,--with-randomdev=/dev/random,,"
+PACKAGECONFIG[python3] = "--with-python=${PYTHON} --with-python-install-dir=${D}/${PYTHON_SITEPACKAGES_DIR} , --without-python, python3-ply-native,"
+
+ENABLE_IPV6 = "--enable-ipv6=${@bb.utils.contains('DISTRO_FEATURES', 'ipv6', 'yes', 'no', d)}"
+EXTRA_OECONF = " ${ENABLE_IPV6} --with-libtool --enable-threads \
+                 --disable-devpoll --enable-epoll --with-gost=no \
+                 --with-gssapi=no --with-ecdsa=yes --with-eddsa=no \
+                 --with-lmdb=no \
+                 --sysconfdir=${sysconfdir}/bind \
+                 --with-openssl=${STAGING_DIR_HOST}${prefix} \
+               "
+
+inherit ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3native distutils3-base', '', d)}
+
+# dhcp needs .la so keep them
+REMOVE_LIBTOOL_LA = "0"
+
+USERADD_PACKAGES = "${PN}"
+USERADD_PARAM_${PN} = "--system --home ${localstatedir}/cache/bind --no-create-home \
+                       --user-group bind"
+
+INITSCRIPT_NAME = "bind"
+INITSCRIPT_PARAMS = "defaults"
+
+SYSTEMD_SERVICE_${PN} = "named.service"
+
+do_install_prepend() {
+	# clean host path in isc-config.sh before the hardlink created
+	# by "make install":
+	#   bind9-config -> isc-config.sh
+	sed -i -e "s,${STAGING_LIBDIR},${libdir}," ${B}/isc-config.sh
+}
+
+do_install_append() {
+
+	rm "${D}${bindir}/nslookup"
+	rm "${D}${mandir}/man1/nslookup.1"
+	rmdir "${D}${localstatedir}/run"
+	rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
+	install -d -o bind "${D}${localstatedir}/cache/bind"
+	install -d "${D}${sysconfdir}/bind"
+	install -d "${D}${sysconfdir}/init.d"
+	install -m 644 ${S}/conf/* "${D}${sysconfdir}/bind/"
+	install -m 755 "${S}/init.d" "${D}${sysconfdir}/init.d/bind"
+        if ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'true', 'false', d)}; then
+		sed -i -e '1s,#!.*python3,#! /usr/bin/python3,' \
+		${D}${sbindir}/dnssec-coverage \
+		${D}${sbindir}/dnssec-checkds \
+		${D}${sbindir}/dnssec-keymgr
+	fi
+
+	# Install systemd related files
+	install -d ${D}${sbindir}
+	install -m 755 ${WORKDIR}/generate-rndc-key.sh ${D}${sbindir}
+	install -d ${D}${systemd_unitdir}/system
+	install -m 0644 ${WORKDIR}/named.service ${D}${systemd_unitdir}/system
+	sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
+	       -e 's,@SBINDIR@,${sbindir},g' \
+	       ${D}${systemd_unitdir}/system/named.service
+
+	install -d ${D}${sysconfdir}/default
+	install -m 0644 ${WORKDIR}/bind9 ${D}${sysconfdir}/default
+
+	if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+		install -d ${D}${sysconfdir}/tmpfiles.d
+		echo "d /run/named 0755 bind bind - -" > ${D}${sysconfdir}/tmpfiles.d/bind.conf
+	fi
+}
+
+CONFFILES_${PN} = " \
+	${sysconfdir}/bind/named.conf \
+	${sysconfdir}/bind/named.conf.local \
+	${sysconfdir}/bind/named.conf.options \
+	${sysconfdir}/bind/db.0 \
+	${sysconfdir}/bind/db.127 \
+	${sysconfdir}/bind/db.empty \
+	${sysconfdir}/bind/db.local \
+	${sysconfdir}/bind/db.root \
+	"
+
+PACKAGE_BEFORE_PN += "${PN}-utils"
+FILES_${PN}-utils = "${bindir}/host ${bindir}/dig ${bindir}/mdig"
+FILES_${PN}-dev += "${bindir}/isc-config.h"
+FILES_${PN} += "${sbindir}/generate-rndc-key.sh"
+
+PACKAGE_BEFORE_PN += "${PN}-libs"
+FILES_${PN}-libs = "${libdir}/*.so*"
+FILES_${PN}-staticdev += "${libdir}/*.la"
+
+PACKAGE_BEFORE_PN += "${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3-bind', '', d)}"
+FILES_python3-bind = "${sbindir}/dnssec-coverage ${sbindir}/dnssec-checkds \
+                ${sbindir}/dnssec-keymgr ${PYTHON_SITEPACKAGES_DIR}"
+
+RDEPENDS_${PN} = "bash"
+RDEPENDS_${PN}-utils = "bash"
+RDEPENDS_${PN}-dev = ""
+RDEPENDS_python3-bind = "python3-core python3-ply"
diff --git a/poky/meta/recipes-connectivity/bluez5/bluez5.inc b/poky/meta/recipes-connectivity/bluez5/bluez5.inc
index ae2a833..9d9739e 100644
--- a/poky/meta/recipes-connectivity/bluez5/bluez5.inc
+++ b/poky/meta/recipes-connectivity/bluez5/bluez5.inc
@@ -42,6 +42,7 @@
 PACKAGECONFIG[threads] = "--enable-threads,--disable-threads"
 PACKAGECONFIG[deprecated] = "--enable-deprecated,--disable-deprecated"
 PACKAGECONFIG[mesh] = "--enable-mesh,--disable-mesh, json-c"
+PACKAGECONFIG[btpclient] = "--enable-btpclient,--disable-btpclient, ell"
 
 SRC_URI = "\
     ${KERNELORG_MIRROR}/linux/bluetooth/bluez-${PV}.tar.xz \
@@ -50,6 +51,7 @@
     file://run-ptest \
     ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '', 'file://0001-Allow-using-obexd-without-systemd-in-the-user-sessio.patch', d)} \
     file://0001-tests-add-a-target-for-building-tests-without-runnin.patch \
+    file://0001-test-gatt-Fix-hung-issue.patch \
 "
 S = "${WORKDIR}/bluez-${PV}"
 
diff --git a/poky/meta/recipes-connectivity/bluez5/bluez5/0001-Allow-using-obexd-without-systemd-in-the-user-sessio.patch b/poky/meta/recipes-connectivity/bluez5/bluez5/0001-Allow-using-obexd-without-systemd-in-the-user-sessio.patch
index 2fde7bc..da71409 100644
--- a/poky/meta/recipes-connectivity/bluez5/bluez5/0001-Allow-using-obexd-without-systemd-in-the-user-sessio.patch
+++ b/poky/meta/recipes-connectivity/bluez5/bluez5/0001-Allow-using-obexd-without-systemd-in-the-user-sessio.patch
@@ -1,3 +1,4 @@
+From 99ccdbe155028c4c789803a429072675b87d0c3a Mon Sep 17 00:00:00 2001
 From: Giovanni Campagna <gcampagna-cNUdlRotFMnNLxjTenLetw@public.gmane.org>
 Date: Sat, 12 Oct 2013 17:45:25 +0200
 Subject: [PATCH] Allow using obexd without systemd in the user session
@@ -14,19 +15,18 @@
 http://thread.gmane.org/gmane.linux.bluez.kernel/38725/focus=38843
 
 Signed-off-by: Javier Viguera <javier.viguera@digi.com>
+
 ---
- Makefile.obexd                      | 4 ++--
- obexd/src/org.bluez.obex.service    | 4 ----
- obexd/src/org.bluez.obex.service.in | 4 ++++
- 3 files changed, 6 insertions(+), 6 deletions(-)
- delete mode 100644 obexd/src/org.bluez.obex.service
- create mode 100644 obexd/src/org.bluez.obex.service.in
+ Makefile.obexd                                                  | 4 ++--
+ obexd/src/{org.bluez.obex.service => org.bluez.obex.service.in} | 2 +-
+ 2 files changed, 3 insertions(+), 3 deletions(-)
+ rename obexd/src/{org.bluez.obex.service => org.bluez.obex.service.in} (76%)
 
 diff --git a/Makefile.obexd b/Makefile.obexd
-index 2e33cbc72f2b..d5d858c857b4 100644
+index c462692..0325f66 100644
 --- a/Makefile.obexd
 +++ b/Makefile.obexd
-@@ -2,12 +2,12 @@
+@@ -1,12 +1,12 @@
  if SYSTEMD
  systemduserunitdir = @SYSTEMD_USERUNITDIR@
  systemduserunit_DATA = obexd/src/obex.service
@@ -39,25 +39,18 @@
 -EXTRA_DIST += obexd/src/obex.service.in obexd/src/org.bluez.obex.service
 +EXTRA_DIST += obexd/src/obex.service.in obexd/src/org.bluez.obex.service.in
  
- obex_plugindir = $(libdir)/obex/plugins
+ if OBEX
  
-diff --git a/obexd/src/org.bluez.obex.service b/obexd/src/org.bluez.obex.service
-deleted file mode 100644
-index a53808884554..000000000000
+diff --git a/obexd/src/org.bluez.obex.service b/obexd/src/org.bluez.obex.service.in
+similarity index 76%
+rename from obexd/src/org.bluez.obex.service
+rename to obexd/src/org.bluez.obex.service.in
+index a538088..9c815f2 100644
 --- a/obexd/src/org.bluez.obex.service
-+++ /dev/null
-@@ -1,4 +0,0 @@
--[D-BUS Service]
--Name=org.bluez.obex
--Exec=/bin/false
--SystemdService=dbus-org.bluez.obex.service
-diff --git a/obexd/src/org.bluez.obex.service.in b/obexd/src/org.bluez.obex.service.in
-new file mode 100644
-index 000000000000..9c815f246b77
---- /dev/null
 +++ b/obexd/src/org.bluez.obex.service.in
-@@ -0,0 +1,4 @@
-+[D-BUS Service]
-+Name=org.bluez.obex
+@@ -1,4 +1,4 @@
+ [D-BUS Service]
+ Name=org.bluez.obex
+-Exec=/bin/false
 +Exec=@libexecdir@/obexd
-+SystemdService=dbus-org.bluez.obex.service
+ SystemdService=dbus-org.bluez.obex.service
diff --git a/poky/meta/recipes-connectivity/bluez5/bluez5/0001-test-gatt-Fix-hung-issue.patch b/poky/meta/recipes-connectivity/bluez5/bluez5/0001-test-gatt-Fix-hung-issue.patch
new file mode 100644
index 0000000..e90b6a5
--- /dev/null
+++ b/poky/meta/recipes-connectivity/bluez5/bluez5/0001-test-gatt-Fix-hung-issue.patch
@@ -0,0 +1,43 @@
+From 61e741654cc2eb167bca212a3bb2ba8f3ba280c1 Mon Sep 17 00:00:00 2001
+From: Mingli Yu <Mingli.Yu@windriver.com>
+Date: Fri, 24 Aug 2018 12:04:03 +0800
+Subject: [PATCH] test-gatt: Fix hung issue
+
+The below test hangs infinitely
+$ unit/test-gatt -p  /robustness/unkown-request -d
+/robustness/unkown-request - init
+/robustness/unkown-request - setup
+/robustness/unkown-request - setup complete
+/robustness/unkown-request - run
+  GATT: < 02 17 00                                         ...
+  bt_gatt_server:MTU exchange complete, with MTU: 23
+  GATT: > 03 00 02                                         ...
+  PDU: = 03 00 02                                         ...
+  GATT: < bf 00
+
+Actually, the /robustness/unkown-request test does
+no action.
+
+Upstream-Status: Submitted [https://marc.info/?l=linux-bluetooth&m=153508881804635&w=2]
+
+Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
+---
+ unit/test-gatt.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/unit/test-gatt.c b/unit/test-gatt.c
+index c7e28f8..b57373b 100644
+--- a/unit/test-gatt.c
++++ b/unit/test-gatt.c
+@@ -4463,7 +4463,7 @@ int main(int argc, char *argv[])
+ 			test_server, service_db_1, NULL,
+ 			raw_pdu(0x03, 0x00, 0x02),
+ 			raw_pdu(0xbf, 0x00),
+-			raw_pdu(0x01, 0xbf, 0x00, 0x00, 0x06));
++			raw_pdu());
+ 
+ 	define_test_server("/robustness/unkown-command",
+ 			test_server, service_db_1, NULL,
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-connectivity/bluez5/bluez5_5.48.bb b/poky/meta/recipes-connectivity/bluez5/bluez5_5.48.bb
deleted file mode 100644
index 84a6cd2..0000000
--- a/poky/meta/recipes-connectivity/bluez5/bluez5_5.48.bb
+++ /dev/null
@@ -1,69 +0,0 @@
-require bluez5.inc
-
-REQUIRED_DISTRO_FEATURES = "bluez5"
-
-SRC_URI[md5sum] = "c9c853f3c90564cabec75ab35106c355"
-SRC_URI[sha256sum] = "b9a8723072ef66bae7ec301c774902ebcb444c9c5b149b5a199e60a1ba970e90"
-
-# noinst programs in Makefile.tools that are conditional on READLINE
-# support
-NOINST_TOOLS_READLINE ?= " \
-    ${@bb.utils.contains('PACKAGECONFIG', 'deprecated', 'attrib/gatttool', '', d)} \
-    tools/obex-client-tool \
-    tools/obex-server-tool \
-    tools/bluetooth-player \
-    tools/obexctl \
-    tools/btmgmt \
-"
-
-# noinst programs in Makefile.tools that are conditional on TESTING
-# support
-NOINST_TOOLS_TESTING ?= " \
-    emulator/btvirt \
-    emulator/b1ee \
-    emulator/hfp \
-    peripheral/btsensor \
-    tools/3dsp \
-    tools/mgmt-tester \
-    tools/gap-tester \
-    tools/l2cap-tester \
-    tools/sco-tester \
-    tools/smp-tester \
-    tools/hci-tester \
-    tools/rfcomm-tester \
-    tools/bnep-tester \
-    tools/userchan-tester \
-"
-
-# noinst programs in Makefile.tools that are conditional on TOOLS
-# support
-NOINST_TOOLS_BT ?= " \
-    tools/bdaddr \
-    tools/avinfo \
-    tools/avtest \
-    tools/scotest \
-    tools/amptest \
-    tools/hwdb \
-    tools/hcieventmask \
-    tools/hcisecfilter \
-    tools/btinfo \
-    tools/btsnoop \
-    tools/btproxy \
-    tools/btiotest \
-    tools/bneptest \
-    tools/mcaptest \
-    tools/cltest \
-    tools/oobtest \
-    tools/advtest \
-    tools/seq2bseq \
-    tools/nokfw \
-    tools/create-image \
-    tools/eddystone \
-    tools/ibeacon \
-    tools/btgatt-client \
-    tools/btgatt-server \
-    tools/test-runner \
-    tools/check-selftest \
-    tools/gatt-service \
-    profiles/iap/iapd \
-"
diff --git a/poky/meta/recipes-connectivity/bluez5/bluez5_5.50.bb b/poky/meta/recipes-connectivity/bluez5/bluez5_5.50.bb
new file mode 100644
index 0000000..6627143
--- /dev/null
+++ b/poky/meta/recipes-connectivity/bluez5/bluez5_5.50.bb
@@ -0,0 +1,70 @@
+require bluez5.inc
+
+REQUIRED_DISTRO_FEATURES = "bluez5"
+
+SRC_URI[md5sum] = "8e35c67c81a55d3ad4c9f22280dae178"
+SRC_URI[sha256sum] = "5ffcaae18bbb6155f1591be8c24898dc12f062075a40b538b745bfd477481911"
+
+# noinst programs in Makefile.tools that are conditional on READLINE
+# support
+NOINST_TOOLS_READLINE ?= " \
+    ${@bb.utils.contains('PACKAGECONFIG', 'deprecated', 'attrib/gatttool', '', d)} \
+    tools/obex-client-tool \
+    tools/obex-server-tool \
+    tools/bluetooth-player \
+    tools/obexctl \
+    tools/btmgmt \
+"
+
+# noinst programs in Makefile.tools that are conditional on TESTING
+# support
+NOINST_TOOLS_TESTING ?= " \
+    emulator/btvirt \
+    emulator/b1ee \
+    emulator/hfp \
+    peripheral/btsensor \
+    tools/3dsp \
+    tools/mgmt-tester \
+    tools/gap-tester \
+    tools/l2cap-tester \
+    tools/sco-tester \
+    tools/smp-tester \
+    tools/hci-tester \
+    tools/rfcomm-tester \
+    tools/bnep-tester \
+    tools/userchan-tester \
+"
+
+# noinst programs in Makefile.tools that are conditional on TOOLS
+# support
+NOINST_TOOLS_BT ?= " \
+    tools/bdaddr \
+    tools/avinfo \
+    tools/avtest \
+    tools/scotest \
+    tools/amptest \
+    tools/hwdb \
+    tools/hcieventmask \
+    tools/hcisecfilter \
+    tools/btinfo \
+    tools/btsnoop \
+    tools/btproxy \
+    tools/btiotest \
+    tools/bneptest \
+    tools/mcaptest \
+    tools/cltest \
+    tools/oobtest \
+    tools/advtest \
+    tools/seq2bseq \
+    tools/nokfw \
+    tools/create-image \
+    tools/eddystone \
+    tools/ibeacon \
+    tools/btgatt-client \
+    tools/btgatt-server \
+    tools/test-runner \
+    tools/check-selftest \
+    tools/gatt-service \
+    profiles/iap/iapd \
+    ${@bb.utils.contains('PACKAGECONFIG', 'btpclient', 'tools/btpclient', '', d)} \
+"
diff --git a/poky/meta/recipes-connectivity/connman/connman/0002-resolve-musl-does-not-implement-res_ninit.patch b/poky/meta/recipes-connectivity/connman/connman/0002-resolve-musl-does-not-implement-res_ninit.patch
index 0593427..639ccfa 100644
--- a/poky/meta/recipes-connectivity/connman/connman/0002-resolve-musl-does-not-implement-res_ninit.patch
+++ b/poky/meta/recipes-connectivity/connman/connman/0002-resolve-musl-does-not-implement-res_ninit.patch
@@ -17,6 +17,14 @@
 index 5cf7a9a..3ad8e70 100644
 --- a/gweb/gresolv.c
 +++ b/gweb/gresolv.c
+@@ -36,6 +36,7 @@
+ #include <arpa/inet.h>
+ #include <arpa/nameser.h>
+ #include <net/if.h>
++#include <ctype.h>
+ 
+ #include "gresolv.h"
+ 
 @@ -875,8 +875,6 @@ GResolv *g_resolv_new(int index)
  	resolv->index = index;
  	resolv->nameserver_list = NULL;
diff --git a/poky/meta/recipes-connectivity/connman/connman/includes.patch b/poky/meta/recipes-connectivity/connman/connman/includes.patch
index 55cb187..9f7395c 100644
--- a/poky/meta/recipes-connectivity/connman/connman/includes.patch
+++ b/poky/meta/recipes-connectivity/connman/connman/includes.patch
@@ -1,6 +1,6 @@
 Fix various issues which cause problems under musl.
 
-Upstream-Status: Submitted
+Upstream-Status: Backport [bd1326ba7d68df38c5ccaafd2403a5fb30bd452b]
 Signed-off-by: Ross Burton <ross.burton@intel.com>
 
 From 630516bcc0233b047f65665c003201ba6e77453d Mon Sep 17 00:00:00 2001
@@ -300,20 +300,14 @@
 index 8a51a9f..d55027c 100644
 --- a/gweb/gresolv.c
 +++ b/gweb/gresolv.c
-@@ -23,11 +23,13 @@
- #include <config.h>
- #endif
- 
-+#include <ctype.h>
- #include <errno.h>
- #include <unistd.h>
- #include <stdarg.h>
+@@ -29,6 +29,7 @@
  #include <string.h>
  #include <stdlib.h>
-+#include <stdio.h>
  #include <resolv.h>
++#include <stdio.h>
  #include <sys/types.h>
  #include <sys/socket.h>
+ #include <netdb.h>
 diff --git a/plugins/wifi.c b/plugins/wifi.c
 index 9d56671..148131d 100644
 --- a/plugins/wifi.c
diff --git a/poky/meta/recipes-connectivity/dhcp/dhcp.inc b/poky/meta/recipes-connectivity/dhcp/dhcp.inc
index 44e946c..3e65e5c 100644
--- a/poky/meta/recipes-connectivity/dhcp/dhcp.inc
+++ b/poky/meta/recipes-connectivity/dhcp/dhcp.inc
@@ -8,9 +8,9 @@
 HOMEPAGE = "http://www.isc.org/"
 
 LICENSE = "ISC"
-LIC_FILES_CHKSUM = "file://LICENSE;beginline=4;md5=c5c64d696107f84b56fe337d14da1753"
+LIC_FILES_CHKSUM = "file://LICENSE;beginline=4;md5=004a4db50a1e20972e924a8618747c01"
 
-DEPENDS = "openssl"
+DEPENDS = "openssl bind"
 
 SRC_URI = "http://ftp.isc.org/isc/dhcp/${PV}/dhcp-${PV}.tar.gz \
            file://init-relay file://default-relay \
@@ -24,7 +24,7 @@
 UPSTREAM_CHECK_URI = "ftp://ftp.isc.org/isc/dhcp/"
 UPSTREAM_CHECK_REGEX = "(?P<pver>\d+\.\d+\.(\d+?))/"
 
-inherit autotools systemd useradd update-rc.d
+inherit autotools-brokensep systemd useradd update-rc.d
 
 USERADD_PACKAGES = "${PN}-server"
 USERADD_PARAM_${PN}-server = "--system --no-create-home --home-dir /var/run/${BPN} --shell /bin/false --user-group ${BPN}"
@@ -50,8 +50,15 @@
                 --with-cli6-lease-file=${localstatedir}/lib/dhcp/dhclient6.leases \
                 --enable-paranoia --disable-static \
                 --with-randomdev=/dev/random \
+                --with-libbind=${STAGING_DIR_HOST} \
+		--enable-libtool \
                "
 
+#Enable shared libs per dhcp README
+do_configure_prepend () {
+	cp configure.ac+lt configure.ac
+}
+
 do_install_append () {
 	install -d ${D}${sysconfdir}/init.d
 	install -d ${D}${sysconfdir}/default
@@ -95,8 +102,7 @@
 PACKAGES_remove = "${PN}"
 RDEPENDS_${PN}-dev = ""
 RDEPENDS_${PN}-staticdev = ""
-
-FILES_${PN}-libs = "${libdir}/libdhcpctl.so.0* ${libdir}/libomapi.so.0*"
+FILES_${PN}-libs = "${libdir}/libdhcpctl.so.0* ${libdir}/libomapi.so.0* ${libdir}/libdhcp.so.0*"
 
 FILES_${PN}-server = "${sbindir}/dhcpd ${sysconfdir}/init.d/dhcp-server"
 RRECOMMENDS_${PN}-server = "dhcp-server-config"
diff --git a/poky/meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch b/poky/meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch
index e5b3cf9..d1b57f0 100644
--- a/poky/meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch
+++ b/poky/meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch
@@ -11,11 +11,11 @@
  includes/site.h | 3 ++-
  1 file changed, 2 insertions(+), 1 deletion(-)
 
-diff --git a/includes/site.h b/includes/site.h
-index b2f7fd7..280fbb9 100644
---- a/includes/site.h
-+++ b/includes/site.h
-@@ -149,7 +149,8 @@
+Index: dhcp-4.4.1/includes/site.h
+===================================================================
+--- dhcp-4.4.1.orig/includes/site.h
++++ dhcp-4.4.1/includes/site.h
+@@ -148,7 +148,8 @@
  /* Define this if you want the dhcpd.conf file to go somewhere other than
     the default location.   By default, it goes in /etc/dhcpd.conf. */
  
@@ -25,6 +25,3 @@
  
  /* Network API definitions.   You do not need to choose one of these - if
     you don't choose, one will be chosen for you in your system's config
--- 
-1.8.3.1
-
diff --git a/poky/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch b/poky/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch
index 810c7b6..5b35933 100644
--- a/poky/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch
+++ b/poky/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch
@@ -18,11 +18,11 @@
  configure.ac | 4 ++++
  1 file changed, 4 insertions(+)
 
-diff --git a/configure.ac b/configure.ac
-index cdfa352..44fb57e 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -591,6 +591,10 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[void foo() __attribute__((noreturn));
+Index: dhcp-4.4.1/configure.ac
+===================================================================
+--- dhcp-4.4.1.orig/configure.ac
++++ dhcp-4.4.1/configure.ac
+@@ -612,6 +612,10 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]],
  # Look for optional headers.
  AC_CHECK_HEADERS(sys/socket.h net/if_dl.h net/if6.h regex.h)
  
@@ -33,6 +33,3 @@
  # Solaris needs some libraries for functions
  AC_SEARCH_LIBS(socket, [socket])
  AC_SEARCH_LIBS(inet_ntoa, [nsl])
--- 
-1.8.3.1
-
diff --git a/poky/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch b/poky/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch
index 7d1d867..b71c93d 100644
--- a/poky/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch
+++ b/poky/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch
@@ -19,82 +19,75 @@
  server/Makefile.am  | 2 +-
  6 files changed, 9 insertions(+), 5 deletions(-)
 
-diff --git a/client/Makefile.am b/client/Makefile.am
-index 2cb83d8..4730bb3 100644
---- a/client/Makefile.am
-+++ b/client/Makefile.am
-@@ -7,11 +7,11 @@ SUBDIRS = . tests
- BINDLIBDIR = @BINDDIR@/lib
- 
- AM_CPPFLAGS = -DCLIENT_PATH='"PATH=$(sbindir):/sbin:/bin:/usr/sbin:/usr/bin"' \
--	      -DLOCALSTATEDIR='"$(localstatedir)"'
-+	      -DLOCALSTATEDIR='"$(localstatedir)"' -I$(top_srcdir)/includes
- 
- dist_sysconf_DATA = dhclient.conf.example
- sbin_PROGRAMS = dhclient
--dhclient_SOURCES = clparse.c dhclient.c dhc6.c \
-+dhclient_SOURCES = $(srcdir)/clparse.c $(srcdir)/dhclient.c $(srcdir)/dhc6.c \
- 		   scripts/bsdos scripts/freebsd scripts/linux scripts/macos \
- 		   scripts/netbsd scripts/nextstep scripts/openbsd \
- 		   scripts/solaris scripts/openwrt
-diff --git a/common/Makefile.am b/common/Makefile.am
-index 113aee8..0f24fbb 100644
---- a/common/Makefile.am
-+++ b/common/Makefile.am
+Index: dhcp-4.4.1/common/Makefile.am
+===================================================================
+--- dhcp-4.4.1.orig/common/Makefile.am
++++ dhcp-4.4.1/common/Makefile.am
 @@ -1,4 +1,5 @@
 -AM_CPPFLAGS = -I$(top_srcdir) -DLOCALSTATEDIR='"@localstatedir@"'
 +AM_CPPFLAGS = -I$(top_srcdir)/includes -I$(top_srcdir) -DLOCALSTATEDIR='"@localstatedir@"'
 +
  AM_CFLAGS = $(LDAP_CFLAGS)
  
- noinst_LIBRARIES = libdhcp.a
-diff --git a/dhcpctl/Makefile.am b/dhcpctl/Makefile.am
-index ceb0de1..ba8dd8b 100644
---- a/dhcpctl/Makefile.am
-+++ b/dhcpctl/Makefile.am
-@@ -1,5 +1,7 @@
- BINDLIBDIR = @BINDDIR@/lib
+ lib_LIBRARIES = libdhcp.a
+Index: dhcp-4.4.1/dhcpctl/Makefile.am
+===================================================================
+--- dhcp-4.4.1.orig/dhcpctl/Makefile.am
++++ dhcp-4.4.1/dhcpctl/Makefile.am
+@@ -3,6 +3,8 @@ BINDLIBDNSDIR=@BINDLIBDNSDIR@
+ BINDLIBISCCFGDIR=@BINDLIBISCCFGDIR@
+ BINDLIBISCDIR=@BINDLIBISCDIR@
  
 +AM_CPPFLAGS = -I$(top_srcdir)/includes -I$(top_srcdir)
 +
  bin_PROGRAMS = omshell
  lib_LIBRARIES = libdhcpctl.a
  noinst_PROGRAMS = cltest
-diff --git a/omapip/Makefile.am b/omapip/Makefile.am
-index 446a594..dd1afa0 100644
---- a/omapip/Makefile.am
-+++ b/omapip/Makefile.am
-@@ -1,4 +1,5 @@
- BINDLIBDIR = @BINDDIR@/lib
-+AM_CPPFLAGS = -I$(top_srcdir)/includes
- 
- lib_LIBRARIES = libomapi.a
- noinst_PROGRAMS = svtest
-diff --git a/relay/Makefile.am b/relay/Makefile.am
-index 3060eca..6d652f6 100644
---- a/relay/Makefile.am
-+++ b/relay/Makefile.am
-@@ -1,6 +1,6 @@
- BINDLIBDIR = @BINDDIR@/lib
- 
--AM_CPPFLAGS = -DLOCALSTATEDIR='"@localstatedir@"'
-+AM_CPPFLAGS = -DLOCALSTATEDIR='"@localstatedir@"' -I$(top_srcdir)/includes
- 
- sbin_PROGRAMS = dhcrelay
- dhcrelay_SOURCES = dhcrelay.c
-diff --git a/server/Makefile.am b/server/Makefile.am
-index 54feedf..3990b9c 100644
---- a/server/Makefile.am
-+++ b/server/Makefile.am
-@@ -6,7 +6,7 @@ SUBDIRS = . tests
- 
- BINDLIBDIR = @BINDDIR@/lib
+Index: dhcp-4.4.1/server/Makefile.am
+===================================================================
+--- dhcp-4.4.1.orig/server/Makefile.am
++++ dhcp-4.4.1/server/Makefile.am
+@@ -4,7 +4,7 @@
+ # production code. Sadly, we are not there yet.
+ SUBDIRS = . tests
  
 -AM_CPPFLAGS = -I.. -DLOCALSTATEDIR='"@localstatedir@"'
 +AM_CPPFLAGS = -I$(top_srcdir) -DLOCALSTATEDIR='"@localstatedir@"' -I$(top_srcdir)/includes
  
  dist_sysconf_DATA = dhcpd.conf.example
  sbin_PROGRAMS = dhcpd
--- 
-1.8.3.1
-
+Index: dhcp-4.4.1/client/Makefile.am
+===================================================================
+--- dhcp-4.4.1.orig/client/Makefile.am
++++ dhcp-4.4.1/client/Makefile.am
+@@ -5,7 +5,7 @@
+ SUBDIRS = . tests
+ 
+ AM_CPPFLAGS = -DCLIENT_PATH='"PATH=$(sbindir):/sbin:/bin:/usr/sbin:/usr/bin"'
+-AM_CPPFLAGS += -DLOCALSTATEDIR='"$(localstatedir)"'
++AM_CPPFLAGS += -DLOCALSTATEDIR='"$(localstatedir)"' -I$(top_srcdir)/includes
+ 
+ dist_sysconf_DATA = dhclient.conf.example
+ sbin_PROGRAMS = dhclient
+Index: dhcp-4.4.1/omapip/Makefile.am
+===================================================================
+--- dhcp-4.4.1.orig/omapip/Makefile.am
++++ dhcp-4.4.1/omapip/Makefile.am
+@@ -2,6 +2,7 @@ BINDLIBIRSDIR=@BINDLIBIRSDIR@
+ BINDLIBDNSDIR=@BINDLIBDNSDIR@
+ BINDLIBISCCFGDIR=@BINDLIBISCCFGDIR@
+ BINDLIBISCDIR=@BINDLIBISCDIR@
++AM_CPPFLAGS = -I$(top_srcdir)/includes
+ 
+ lib_LIBRARIES = libomapi.a
+ noinst_PROGRAMS = svtest
+Index: dhcp-4.4.1/relay/Makefile.am
+===================================================================
+--- dhcp-4.4.1.orig/relay/Makefile.am
++++ dhcp-4.4.1/relay/Makefile.am
+@@ -1,4 +1,4 @@
+-AM_CPPFLAGS = -DLOCALSTATEDIR='"@localstatedir@"'
++AM_CPPFLAGS = -DLOCALSTATEDIR='"@localstatedir@"' -I$(top_srcdir)/includes
+ 
+ sbin_PROGRAMS = dhcrelay
+ dhcrelay_SOURCES = dhcrelay.c
diff --git a/poky/meta/recipes-connectivity/dhcp/dhcp/0006-site.h-enable-gentle-shutdown.patch b/poky/meta/recipes-connectivity/dhcp/dhcp/0006-site.h-enable-gentle-shutdown.patch
index c62b283..6ef70cc 100644
--- a/poky/meta/recipes-connectivity/dhcp/dhcp/0006-site.h-enable-gentle-shutdown.patch
+++ b/poky/meta/recipes-connectivity/dhcp/dhcp/0006-site.h-enable-gentle-shutdown.patch
@@ -12,11 +12,11 @@
  includes/site.h | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-diff --git a/includes/site.h b/includes/site.h
-index 280fbb9..e6c2972 100644
---- a/includes/site.h
-+++ b/includes/site.h
-@@ -296,7 +296,7 @@
+Index: dhcp-4.4.1/includes/site.h
+===================================================================
+--- dhcp-4.4.1.orig/includes/site.h
++++ dhcp-4.4.1/includes/site.h
+@@ -295,7 +295,7 @@
     situations.  We plan to revisit this feature and may
     make non-backwards compatible changes including the
     removal of this define.  Use at your own risk.  */
@@ -25,6 +25,3 @@
  
  /* Include old error codes.  This is provided in case you
     are building an external program similar to omshell for
--- 
-1.8.3.1
-
diff --git a/poky/meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch b/poky/meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch
index 43c26ea..feb0754 100644
--- a/poky/meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch
+++ b/poky/meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch
@@ -15,13 +15,13 @@
  configure.ac | 11 +++++++++++
  1 file changed, 11 insertions(+)
 
-diff --git a/configure.ac b/configure.ac
-index 44fb57e..8e9f509 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -611,6 +611,17 @@ AC_CHECK_FUNCS(strlcat)
- # For HP/UX we need -lipv6 for if_nametoindex, perhaps others.
- AC_SEARCH_LIBS(if_nametoindex, [ipv6])
+Index: dhcp-4.4.1/configure.ac
+===================================================================
+--- dhcp-4.4.1.orig/configure.ac
++++ dhcp-4.4.1/configure.ac
+@@ -642,6 +642,17 @@ if test "$have_nanosleep" = "rt"; then
+ 	LIBS="-lrt $LIBS"
+ fi
  
 +AC_ARG_WITH(libxml2,
 +	AS_HELP_STRING([--with-libxml2], [link against libxml2. this is needed if bind was built with xml2 support enabled]),
@@ -37,6 +37,26 @@
  # check for /dev/random (declares HAVE_DEV_RANDOM)
  AC_MSG_CHECKING(for random device)
  AC_ARG_WITH(randomdev,
--- 
-1.8.3.1
-
+Index: dhcp-4.4.1/configure.ac+lt
+===================================================================
+--- dhcp-4.4.1.orig/configure.ac+lt
++++ dhcp-4.4.1/configure.ac+lt
+@@ -909,6 +909,18 @@ elif test "$want_libtool" = "yes" -a "$u
+ fi
+ AM_CONDITIONAL(INSTALL_BIND, test "$want_install_bind" = "yes")
+ 
++AC_ARG_WITH(libxml2,
++	AS_HELP_STRING([--with-libxml2], [link against libxml2. this is needed if bind was built with xml2 support enabled]),
++	with_libxml2="$withval", with_libxml2="no")
++
++if test x$with_libxml2 != xno; then
++	AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],,
++		[if test x$with_libxml2 != xauto; then
++			AC_MSG_FAILURE([*** Cannot find xmlTextWriterStartElement with -lxml2 and libxml2 was requested])
++		fi])
++fi
++
++
+ # OpenLDAP support.
+ AC_ARG_WITH(ldap,
+     AS_HELP_STRING([--with-ldap],[enable OpenLDAP support in dhcpd (default is no)]),
diff --git a/poky/meta/recipes-connectivity/dhcp/dhcp/0008-tweak-to-support-external-bind.patch b/poky/meta/recipes-connectivity/dhcp/dhcp/0008-tweak-to-support-external-bind.patch
index a20b5f9..006d18a 100644
--- a/poky/meta/recipes-connectivity/dhcp/dhcp/0008-tweak-to-support-external-bind.patch
+++ b/poky/meta/recipes-connectivity/dhcp/dhcp/0008-tweak-to-support-external-bind.patch
@@ -20,10 +20,10 @@
  server/tests/Makefile.am | 2 +-
  8 files changed, 8 insertions(+), 8 deletions(-)
 
-Index: dhcp-4.3.6/client/Makefile.am
-===================================================================
---- dhcp-4.3.6.orig/client/Makefile.am
-+++ dhcp-4.3.6/client/Makefile.am
+diff --git a/client/Makefile.am b/client/Makefile.am
+index 4730bb3..84d8131 100644
+--- a/client/Makefile.am
++++ b/client/Makefile.am
 @@ -4,7 +4,7 @@
  # production code. Sadly, we are not there yet.
  SUBDIRS = . tests
@@ -33,10 +33,10 @@
  
  AM_CPPFLAGS = -DCLIENT_PATH='"PATH=$(sbindir):/sbin:/bin:/usr/sbin:/usr/bin"' \
  	      -DLOCALSTATEDIR='"$(localstatedir)"' -I$(top_srcdir)/includes
-Index: dhcp-4.3.6/client/tests/Makefile.am
-===================================================================
---- dhcp-4.3.6.orig/client/tests/Makefile.am
-+++ dhcp-4.3.6/client/tests/Makefile.am
+diff --git a/client/tests/Makefile.am b/client/tests/Makefile.am
+index 5031d0c..a8dfd26 100644
+--- a/client/tests/Makefile.am
++++ b/client/tests/Makefile.am
 @@ -1,6 +1,6 @@
  SUBDIRS = .
  
@@ -45,10 +45,10 @@
  
  AM_CPPFLAGS = $(ATF_CFLAGS) -DUNIT_TEST -I$(top_srcdir)/includes
  AM_CPPFLAGS += -I@BINDDIR@/include -I$(top_srcdir)
-Index: dhcp-4.3.6/common/tests/Makefile.am
-===================================================================
---- dhcp-4.3.6.orig/common/tests/Makefile.am
-+++ dhcp-4.3.6/common/tests/Makefile.am
+diff --git a/common/tests/Makefile.am b/common/tests/Makefile.am
+index f6a43e4..2f98d22 100644
+--- a/common/tests/Makefile.am
++++ b/common/tests/Makefile.am
 @@ -1,6 +1,6 @@
  SUBDIRS = .
  
@@ -57,40 +57,40 @@
  
  AM_CPPFLAGS = $(ATF_CFLAGS) -I$(top_srcdir)/includes
  
-Index: dhcp-4.3.6/dhcpctl/Makefile.am
-===================================================================
---- dhcp-4.3.6.orig/dhcpctl/Makefile.am
-+++ dhcp-4.3.6/dhcpctl/Makefile.am
+diff --git a/dhcpctl/Makefile.am b/dhcpctl/Makefile.am
+index ba8dd8b..9b2486e 100644
+--- a/dhcpctl/Makefile.am
++++ b/dhcpctl/Makefile.am
 @@ -1,4 +1,4 @@
 -BINDLIBDIR = @BINDDIR@/lib
 +BINDLIBDIR = @BINDDIR@
  
  AM_CPPFLAGS = -I$(top_srcdir)/includes -I$(top_srcdir)
  
-Index: dhcp-4.3.6/omapip/Makefile.am
-===================================================================
---- dhcp-4.3.6.orig/omapip/Makefile.am
-+++ dhcp-4.3.6/omapip/Makefile.am
+diff --git a/omapip/Makefile.am b/omapip/Makefile.am
+index dd1afa0..e4a8599 100644
+--- a/omapip/Makefile.am
++++ b/omapip/Makefile.am
 @@ -1,4 +1,4 @@
 -BINDLIBDIR = @BINDDIR@/lib
 +BINDLIBDIR = @BINDDIR@
  AM_CPPFLAGS = -I$(top_srcdir)/includes
  
- lib_LTLIBRARIES = libomapi.la
-Index: dhcp-4.3.6/relay/Makefile.am
-===================================================================
---- dhcp-4.3.6.orig/relay/Makefile.am
-+++ dhcp-4.3.6/relay/Makefile.am
+ lib_LIBRARIES = libomapi.a
+diff --git a/relay/Makefile.am b/relay/Makefile.am
+index 6d652f6..b3bf578 100644
+--- a/relay/Makefile.am
++++ b/relay/Makefile.am
 @@ -1,4 +1,4 @@
 -BINDLIBDIR = @BINDDIR@/lib
 +BINDLIBDIR = @BINDDIR@
  
  AM_CPPFLAGS = -DLOCALSTATEDIR='"@localstatedir@"' -I$(top_srcdir)/includes
  
-Index: dhcp-4.3.6/server/Makefile.am
-===================================================================
---- dhcp-4.3.6.orig/server/Makefile.am
-+++ dhcp-4.3.6/server/Makefile.am
+diff --git a/server/Makefile.am b/server/Makefile.am
+index 3990b9c..b5d8c2d 100644
+--- a/server/Makefile.am
++++ b/server/Makefile.am
 @@ -4,7 +4,7 @@
  # production code. Sadly, we are not there yet.
  SUBDIRS = . tests
@@ -100,10 +100,10 @@
  
  AM_CPPFLAGS = -I$(top_srcdir) -DLOCALSTATEDIR='"@localstatedir@"' -I$(top_srcdir)/includes
  
-Index: dhcp-4.3.6/server/tests/Makefile.am
-===================================================================
---- dhcp-4.3.6.orig/server/tests/Makefile.am
-+++ dhcp-4.3.6/server/tests/Makefile.am
+diff --git a/server/tests/Makefile.am b/server/tests/Makefile.am
+index a87c5e7..9821081 100644
+--- a/server/tests/Makefile.am
++++ b/server/tests/Makefile.am
 @@ -1,6 +1,6 @@
  SUBDIRS = .
  
@@ -112,3 +112,6 @@
  
  AM_CPPFLAGS = $(ATF_CFLAGS) -DUNIT_TEST -I$(top_srcdir)/includes
  AM_CPPFLAGS += -I@BINDDIR@/include -I$(top_srcdir)
+-- 
+1.8.3.1
+
diff --git a/poky/meta/recipes-connectivity/dhcp/dhcp/0010-build-shared-libs.patch b/poky/meta/recipes-connectivity/dhcp/dhcp/0010-build-shared-libs.patch
deleted file mode 100644
index 898b1fc..0000000
--- a/poky/meta/recipes-connectivity/dhcp/dhcp/0010-build-shared-libs.patch
+++ /dev/null
@@ -1,205 +0,0 @@
-From 76c370a929e5ab5dbc81c2fbcf4e50f4fbc08ce9 Mon Sep 17 00:00:00 2001
-From: Kai Kang <kai.kang@windriver.com>
-Date: Tue, 15 Aug 2017 15:53:37 +0800
-Subject: [PATCH 10/11] build shared libs
-
-Upstream-Status: Pending
-
-Port patches from Fedora to build shared libs rather than static libs.
-
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
-
-Rebase to 4.3.6
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- client/Makefile.am       |  4 ++--
- common/tests/Makefile.am | 13 +++++--------
- configure.ac             | 12 ++----------
- dhcpctl/Makefile.am      | 14 ++++++--------
- omapip/Makefile.am       |  7 +++----
- relay/Makefile.am        |  5 ++---
- server/Makefile.am       |  7 +++----
- server/tests/Makefile.am |  7 +++----
- 8 files changed, 26 insertions(+), 43 deletions(-)
-
-Index: dhcp-4.3.6/client/Makefile.am
-===================================================================
---- dhcp-4.3.6.orig/client/Makefile.am
-+++ dhcp-4.3.6/client/Makefile.am
-@@ -15,7 +15,7 @@ dhclient_SOURCES = $(srcdir)/clparse.c $
- 		   scripts/bsdos scripts/freebsd scripts/linux scripts/macos \
- 		   scripts/netbsd scripts/nextstep scripts/openbsd \
- 		   scripts/solaris scripts/openwrt
--dhclient_LDADD = ../common/libdhcp.a ../omapip/libomapi.a $(BINDLIBDIR)/libirs.a \
--		 $(BINDLIBDIR)/libdns.a $(BINDLIBDIR)/libisccfg.a $(BINDLIBDIR)/libisc.a
-+dhclient_LDADD = ../common/libdhcp.a ../omapip/libomapi.la \
-+		  -L$(BINDLIBDIR) -lirs -ldns -lisccfg -lisc
- man_MANS = dhclient.8 dhclient-script.8 dhclient.conf.5 dhclient.leases.5
- EXTRA_DIST = $(man_MANS)
-Index: dhcp-4.3.6/common/tests/Makefile.am
-===================================================================
---- dhcp-4.3.6.orig/common/tests/Makefile.am
-+++ dhcp-4.3.6/common/tests/Makefile.am
-@@ -15,26 +15,23 @@ ATF_TESTS += alloc_unittest dns_unittest
- alloc_unittest_SOURCES = test_alloc.c $(top_srcdir)/tests/t_api_dhcp.c
- alloc_unittest_LDADD = $(ATF_LDFLAGS)
- alloc_unittest_LDADD += ../libdhcp.a  \
--	../../omapip/libomapi.a $(BINDLIBDIR)/libirs.a \
--	$(BINDLIBDIR)/libdns.a $(BINDLIBDIR)/libisccfg.a  $(BINDLIBDIR)/libisc.a
-+	../../omapip/libomapi.la -L$(BINDLIBDIR) -ldns -lisccfg -lisc
- 
- dns_unittest_SOURCES = dns_unittest.c $(top_srcdir)/tests/t_api_dhcp.c
- dns_unittest_LDADD = $(ATF_LDFLAGS)
- dns_unittest_LDADD += ../libdhcp.a  \
--	../../omapip/libomapi.a $(BINDLIBDIR)/libirs.a \
--	$(BINDLIBDIR)/libdns.a $(BINDLIBDIR)/libisccfg.a  $(BINDLIBDIR)/libisc.a
-+	../../omapip/libomapi.la -L$(BINDLIBDIR) -ldns -lisccfg -lisc
- 
- misc_unittest_SOURCES = misc_unittest.c $(top_srcdir)/tests/t_api_dhcp.c
- misc_unittest_LDADD = $(ATF_LDFLAGS)
- misc_unittest_LDADD += ../libdhcp.a  \
--	../../omapip/libomapi.a $(BINDLIBDIR)/libirs.a \
--	$(BINDLIBDIR)/libdns.a $(BINDLIBDIR)/libisccfg.a  $(BINDLIBDIR)/libisc.a
-+	../../omapip/libomapi.la -L$(BINDLIBDIR) -ldns -lisccfg -lisc
- 
- ns_name_unittest_SOURCES = ns_name_test.c $(top_srcdir)/tests/t_api_dhcp.c
- ns_name_unittest_LDADD = $(ATF_LDFLAGS)
- ns_name_unittest_LDADD += ../libdhcp.a  \
--	../../omapip/libomapi.a $(BINDLIBDIR)/libirs.a \
--	$(BINDLIBDIR)/libdns.a $(BINDLIBDIR)/libisccfg.a  $(BINDLIBDIR)/libisc.a
-+	../../omapip/libomapi.a -L$(BINDLIBDIR) \
-+	-ldns -lisccfg -lisc
- 
- check: $(ATF_TESTS)
- 	@if test $(top_srcdir) != ${top_builddir}; then \
-Index: dhcp-4.3.6/configure.ac
-===================================================================
---- dhcp-4.3.6.orig/configure.ac
-+++ dhcp-4.3.6/configure.ac
-@@ -47,16 +47,8 @@ AM_CONDITIONAL(CROSS_COMPILING, test "$c
- # Use this to define _GNU_SOURCE to pull in the IPv6 Advanced Socket API.
- AC_USE_SYSTEM_EXTENSIONS
- 
--AC_PROG_RANLIB
--
--AC_PATH_PROG(AR, ar)
--AC_SUBST(AR)
--
--if test "X$AR" = "X"; then
--	AC_MSG_ERROR([
--ar program not found.  Please fix your PATH to include the directory in
--which ar resides, or set AR in the environment with the full path to ar.])
--fi
-+# Use libtool to simplify building of shared libraries
-+AC_PROG_LIBTOOL
- 
- AC_CONFIG_HEADERS([includes/config.h])
- 
-Index: dhcp-4.3.6/dhcpctl/Makefile.am
-===================================================================
---- dhcp-4.3.6.orig/dhcpctl/Makefile.am
-+++ dhcp-4.3.6/dhcpctl/Makefile.am
-@@ -3,19 +3,17 @@ BINDLIBDIR = @BINDDIR@/lib
- AM_CPPFLAGS = -I$(top_srcdir)/includes -I$(top_srcdir)
- 
- bin_PROGRAMS = omshell
--lib_LIBRARIES = libdhcpctl.a
-+lib_LTLIBRARIES = libdhcpctl.la
- noinst_PROGRAMS = cltest
- man_MANS = omshell.1 dhcpctl.3
- EXTRA_DIST = $(man_MANS)
- 
- omshell_SOURCES = omshell.c
--omshell_LDADD = libdhcpctl.a ../common/libdhcp.a ../omapip/libomapi.a \
--	        $(BINDLIBDIR)/libirs.a $(BINDLIBDIR)/libdns.a \
--	        $(BINDLIBDIR)/libisccfg.a $(BINDLIBDIR)/libisc.a
-+omshell_LDADD = libdhcpctl.la ../common/libdhcp.a ../omapip/libomapi.la \
-+	        -L$(BINDLIBDIR) -lirs -ldns -lisccfg -lisc
- 
--libdhcpctl_a_SOURCES = dhcpctl.c callback.c remote.c
-+libdhcpctl_la_SOURCES = dhcpctl.c callback.c remote.c
- 
- cltest_SOURCES = cltest.c
--cltest_LDADD = libdhcpctl.a ../common/libdhcp.a ../omapip/libomapi.a \
--	       $(BINDLIBDIR)/libirs.a $(BINDLIBDIR)/libdns.a \
--               $(BINDLIBDIR)/libisccfg.a $(BINDLIBDIR)/libisc.a
-+cltest_LDADD = libdhcpctl.la ../common/libdhcp.a ../omapip/libomapi.la \
-+	       -L$(BINDLIBDIR) -lirs -ldns -lisccfg -lisc
-Index: dhcp-4.3.6/omapip/Makefile.am
-===================================================================
---- dhcp-4.3.6.orig/omapip/Makefile.am
-+++ dhcp-4.3.6/omapip/Makefile.am
-@@ -1,10 +1,10 @@
- BINDLIBDIR = @BINDDIR@/lib
- AM_CPPFLAGS = -I$(top_srcdir)/includes
- 
--lib_LIBRARIES = libomapi.a
-+lib_LTLIBRARIES = libomapi.la
- noinst_PROGRAMS = svtest
- 
--libomapi_a_SOURCES = protocol.c buffer.c alloc.c result.c connection.c \
-+libomapi_la_SOURCES = protocol.c buffer.c alloc.c result.c connection.c \
- 		     errwarn.c listener.c dispatch.c generic.c support.c \
- 		     handle.c message.c convert.c hash.c auth.c inet_addr.c \
- 		     array.c trace.c toisc.c iscprint.c isclib.c
-@@ -13,6 +13,5 @@ man_MANS = omapi.3
- EXTRA_DIST = $(man_MANS)
- 
- svtest_SOURCES = test.c
--svtest_LDADD = libomapi.a $(BINDLIBDIR)/libirs.a $(BINDLIBDIR)/libdns.a \
--		$(BINDLIBDIR)/libisccfg.a $(BINDLIBDIR)/libisc.a
-+svtest_LDADD = libomapi.la -L$(BINDLIBDIR) -lirs -ldns -lisccfg -lisc
- 
-Index: dhcp-4.3.6/relay/Makefile.am
-===================================================================
---- dhcp-4.3.6.orig/relay/Makefile.am
-+++ dhcp-4.3.6/relay/Makefile.am
-@@ -4,9 +4,8 @@ AM_CPPFLAGS = -DLOCALSTATEDIR='"@localst
- 
- sbin_PROGRAMS = dhcrelay
- dhcrelay_SOURCES = dhcrelay.c
--dhcrelay_LDADD = ../common/libdhcp.a ../omapip/libomapi.a \
--		 $(BINDLIBDIR)/libirs.a $(BINDLIBDIR)/libdns.a \
--		 $(BINDLIBDIR)/libisccfg.a $(BINDLIBDIR)/libisc.a
-+dhcrelay_LDADD = ../common/libdhcp.a ../omapip/libomapi.la \
-+		 -L$(BINDLIBDIR) -lirs -ldns -lisccfg -lisc
- man_MANS = dhcrelay.8
- EXTRA_DIST = $(man_MANS)
- 
-Index: dhcp-4.3.6/server/Makefile.am
-===================================================================
---- dhcp-4.3.6.orig/server/Makefile.am
-+++ dhcp-4.3.6/server/Makefile.am
-@@ -15,10 +15,9 @@ dhcpd_SOURCES = dhcpd.c dhcp.c bootp.c c
- 		dhcpv6.c mdb6.c ldap.c ldap_casa.c leasechain.c ldap_krb_helper.c
- 
- dhcpd_CFLAGS = $(LDAP_CFLAGS)
--dhcpd_LDADD = ../common/libdhcp.a ../omapip/libomapi.a \
--	      ../dhcpctl/libdhcpctl.a $(BINDLIBDIR)/libirs.a \
--	      $(BINDLIBDIR)/libdns.a $(BINDLIBDIR)/libisccfg.a \
--	      $(BINDLIBDIR)/libisc.a $(LDAP_LIBS)
-+dhcpd_LDADD = ../common/libdhcp.a ../omapip/libomapi.la \
-+	      ../dhcpctl/libdhcpctl.la -L$(BINDLIBDIR) \
-+	      -lirs -ldns -lisccfg -lisc $(LDAP_LIBS)
- 
- man_MANS = dhcpd.8 dhcpd.conf.5 dhcpd.leases.5
- EXTRA_DIST = $(man_MANS)
-Index: dhcp-4.3.6/server/tests/Makefile.am
-===================================================================
---- dhcp-4.3.6.orig/server/tests/Makefile.am
-+++ dhcp-4.3.6/server/tests/Makefile.am
-@@ -19,10 +19,9 @@ DHCPSRC = ../dhcp.c ../bootp.c ../confpa
-           ../ddns.c ../dhcpleasequery.c ../dhcpv6.c ../mdb6.c        \
-           ../ldap.c ../ldap_casa.c ../dhcpd.c ../leasechain.c
- 
--DHCPLIBS = $(top_builddir)/common/libdhcp.a $(top_builddir)/omapip/libomapi.a \
--          $(top_builddir)/dhcpctl/libdhcpctl.a $(BINDLIBDIR)/libirs.a \
--	  $(BINDLIBDIR)/libdns.a $(BINDLIBDIR)/libisccfg.a \
--	  $(BINDLIBDIR)/libisc.a
-+DHCPLIBS = $(top_builddir)/common/libdhcp.a $(top_builddir)/omapip/libomapi.la \
-+          $(top_builddir)/dhcpctl/libdhcpctl.la \
-+          -L$(BINDLIBDIR) -lirs -ldns -lisccfg -lisc
- 
- ATF_TESTS =
- if HAVE_ATF
diff --git a/poky/meta/recipes-connectivity/dhcp/dhcp/0011-Moved-the-call-to-isc_app_ctxstart-to-not-get-signal.patch b/poky/meta/recipes-connectivity/dhcp/dhcp/0011-Moved-the-call-to-isc_app_ctxstart-to-not-get-signal.patch
deleted file mode 100644
index 67bb463..0000000
--- a/poky/meta/recipes-connectivity/dhcp/dhcp/0011-Moved-the-call-to-isc_app_ctxstart-to-not-get-signal.patch
+++ /dev/null
@@ -1,81 +0,0 @@
-From 37725f3e22edb50e0ca2d1fff971321a5a4d5112 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Wed, 12 Jul 2017 03:05:13 -0400
-Subject: [PATCH 11/11] Moved the call to isc_app_ctxstart() to not get signal
- block by all threads
-
-Signed-off-by: Francis Dupont <fdupont@isc.org>
-
-In https://source.isc.org/git/bind9.git, since the following
-commit applied:
-...
-commit b99bfa184bc9375421b5df915eea7dfac6a68a99
-Author: Evan Hunt <each@isc.org>
-Date:   Wed Apr 10 13:49:57 2013 -0700
-
-    [master] unify internal and export libraries
-
-    3550.       [func]          Unified the internal and export versions of the
-                        BIND libraries, allowing external clients to use
-                        the same libraries as BIND. [RT #33131]
-...
-(git show b99bfa184bc9375421b5df915eea7dfac6a68a99 -- ./lib/isc/unix/app.c)
-
-In this commit, if bind9 enable threads(ISC_PLATFORM_USETHREADS),
-it blocks signal SIGHUP, SIGINT and SIGTERM in isc__app_ctxstart.
-Which caused dhclient/dhcpd could not be stopped by SIGTERM.
-
-It caused systemd's reboot hung which send SIGTERM by default.
-
-Upstream-Status: Backport [https://source.isc.org/git/dhcp.git]
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- omapip/isclib.c | 25 +++++++++++++++----------
- 1 file changed, 15 insertions(+), 10 deletions(-)
-
-diff --git a/omapip/isclib.c b/omapip/isclib.c
-index ce86490..6a04345 100644
---- a/omapip/isclib.c
-+++ b/omapip/isclib.c
-@@ -185,16 +185,6 @@ dhcp_context_create(int flags,
- 		if (result != ISC_R_SUCCESS)
- 			goto cleanup;
- 
--		result = isc_app_ctxstart(dhcp_gbl_ctx.actx);
--		if (result != ISC_R_SUCCESS)
--			return (result);
--		dhcp_gbl_ctx.actx_started = ISC_TRUE;
--
--		/* Not all OSs support suppressing SIGPIPE through socket
--		 * options, so set the sigal action to be ignore.  This allows
--		 * broken connections to fail gracefully with EPIPE on writes */
--		handle_signal(SIGPIPE, SIG_IGN);
--
- 		result = isc_taskmgr_createinctx(dhcp_gbl_ctx.mctx,
- 						 dhcp_gbl_ctx.actx,
- 						 1, 0,
-@@ -217,6 +207,21 @@ dhcp_context_create(int flags,
- 		result = isc_task_create(dhcp_gbl_ctx.taskmgr, 0, &dhcp_gbl_ctx.task);
- 		if (result != ISC_R_SUCCESS)
- 			goto cleanup;
-+
-+		result = isc_app_ctxstart(dhcp_gbl_ctx.actx);
-+		if (result != ISC_R_SUCCESS)
-+			return (result);
-+		dhcp_gbl_ctx.actx_started = ISC_TRUE;
-+
-+		/* Not all OSs support suppressing SIGPIPE through socket
-+		 * options, so set the sigal action to be ignore.  This allows
-+		 * broken connections to fail gracefully with EPIPE on writes */
-+		handle_signal(SIGPIPE, SIG_IGN);
-+
-+		/* Reset handlers installed by isc_app_ctxstart()
-+		 * to default for control-c and kill */
-+		handle_signal(SIGINT, SIG_DFL);
-+		handle_signal(SIGTERM, SIG_DFL);
- 	}
- 
- #if defined (NSUPDATE)
--- 
-1.8.3.1
-
diff --git a/poky/meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch b/poky/meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch
index 2d3af9d..39ba65f 100644
--- a/poky/meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch
+++ b/poky/meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch
@@ -19,11 +19,11 @@
  configure.ac | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-diff --git a/configure.ac b/configure.ac
-index bfe988a..f0459e6 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -608,7 +608,7 @@ AC_ARG_WITH(libxml2,
+Index: dhcp-4.4.1/configure.ac
+===================================================================
+--- dhcp-4.4.1.orig/configure.ac
++++ dhcp-4.4.1/configure.ac
+@@ -647,7 +647,7 @@ AC_ARG_WITH(libxml2,
  	with_libxml2="$withval", with_libxml2="no")
  
  if test x$with_libxml2 != xno; then
@@ -32,6 +32,3 @@
  		[if test x$with_libxml2 != xauto; then
  			AC_MSG_FAILURE([*** Cannot find xmlTextWriterStartElement with -lxml2 and libxml2 was requested])
  		fi])
--- 
-2.11.1
-
diff --git a/poky/meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch b/poky/meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch
new file mode 100644
index 0000000..fcec010
--- /dev/null
+++ b/poky/meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch
@@ -0,0 +1,64 @@
+lib and include path is hardcoded for use_libbind 
+
+use libdir and includedir vars
+
+Upstream-Status: Pending
+Signed-off-by: Armin Kuster <akuster808@gmail.com>
+
+Index: dhcp-4.4.1/configure.ac+lt
+===================================================================
+--- dhcp-4.4.1.orig/configure.ac+lt
++++ dhcp-4.4.1/configure.ac+lt
+@@ -801,22 +801,22 @@ no)
+ 	if test ! -d "$use_libbind"; then
+ 		AC_MSG_ERROR([Cannot find bind directory at $use_libbind])
+ 	fi
+-	if test ! -d "$use_libbind/include" -o \
+-	        ! -f "$use_libbind/include/isc/buffer.h"
++	if test ! -d "$use_libbind/$includedir" -o \
++	        ! -f "$use_libbind/$includedir/isc/buffer.h"
+ 	then
+-		AC_MSG_ERROR([Cannot find bind includes at $use_libbind/include])
++		AC_MSG_ERROR([Cannot find bind includes at $use_libbind/$includedir])
+ 	fi
+-	if test	! -d "$use_libbind/lib" -o \
+-	        \( ! -f "$use_libbind/lib/libisc.a" -a \
+-		   ! -f	"$use_libbind/lib/libisc.la" \)
++	if test	! -d "$use_libbind/$libdir" -o \
++	        \( ! -f "$use_libbind/$libdir/libisc.a" -a \
++		   ! -f	"$use_libbind/$libdir/libisc.la" \)
+ 	then
+-		AC_MSG_ERROR([Cannot find bind libraries at $use_libbind/lib])
++		AC_MSG_ERROR([Cannot find bind libraries at $use_libbind/$libdir])
+ 	fi
+ 	BINDDIR="$use_libbind"
+-	BINDLIBIRSDIR="$BINDDIR/lib"
+-	BINDLIBDNSDIR="$BINDDIR/lib"
+-	BINDLIBISCCFGDIR="$BINDDIR/lib"
+-	BINDLIBISCDIR="$BINDDIR/lib"	
++	BINDLIBIRSDIR="$BINDDIR/$libdir"
++	BINDLIBDNSDIR="$BINDDIR/$libdir"
++	BINDLIBISCCFGDIR="$BINDDIR/$libdir"
++	BINDLIBISCDIR="$BINDDIR/$libdir"
+ 	DISTCHECK_LIBBIND_CONFIGURE_FLAG="--with-libbind=$use_libbind"
+ 	;;
+ esac
+@@ -856,14 +856,14 @@ AC_ARG_ENABLE(libtool,
+ 
+ if test "$use_libbind" != "no"; then
+ 	if test "$want_libtool" = "yes" -a \
+-	        ! -f "$use_libbind/lib/libisc.la"
++	        ! -f "$use_libbind/$libdir/libisc.la"
+ 	then
+-		AC_MSG_ERROR([Cannot find dynamic libraries at $use_libbind/lib])
++		AC_MSG_ERROR([Cannot find dynamic libraries at $use_libbind/$libdir])
+ 	fi
+ 	if test "$want_libtool" = "no" -a \
+-	        ! -f "$use_libbind/lib/libisc.a"
++	        ! -f "$use_libbind/$libdir/libisc.a"
+ 	then
+-		AC_MSG_ERROR([Cannot find static libraries at $use_libbind/lib])
++		AC_MSG_ERROR([Cannot find static libraries at $use_libbind/$libdir])
+ 	fi
+ fi
+ 
diff --git a/poky/meta/recipes-connectivity/dhcp/dhcp/CVE-2017-3144.patch b/poky/meta/recipes-connectivity/dhcp/dhcp/CVE-2017-3144.patch
deleted file mode 100644
index 2b2688c..0000000
--- a/poky/meta/recipes-connectivity/dhcp/dhcp/CVE-2017-3144.patch
+++ /dev/null
@@ -1,74 +0,0 @@
-From 8cfdedee369c26d2869b6ec4a64460b5f5a30934 Mon Sep 17 00:00:00 2001
-From: Thomas Markwalder <tmark@isc.org>
-Date: Thu, 7 Dec 2017 11:39:30 -0500
-Subject: [PATCH] [v4_3] Plugs a socket descriptor leak in OMAPI
-
-        Merges in rt46767.
-
-Upstream-Status: Backport
-[https://source.isc.org/cgi-bin/gitweb.cgi?p=dhcp.git;a=commitdiff;h=5097bc0559f592683faac1f67bf350e1bddf6ed4]
-
-CVE: CVE-2017-3144
-
-Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
-Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
----
- RELNOTES         | 7 +++++++
- omapip/buffer.c  | 9 +++++++++
- omapip/message.c | 2 +-
- 3 files changed, 17 insertions(+), 1 deletion(-)
-
-diff --git a/RELNOTES b/RELNOTES
-index dd40aaf..3741b80 100644
---- a/RELNOTES
-+++ b/RELNOTES
-@@ -66,6 +66,13 @@ We welcome comments from DHCP users, about this or anything else we do.
- Email Vicky Risk, Product Manager at vicky@isc.org or discuss on 
- dhcp-users@lists.isc.org.
- 
-+- Plugged a socket descriptor leak in OMAPI, that can occur when there is
-+  data pending to be written to an OMAPI connection, when the connection
-+  is closed by the reader.  Thanks to Pavel Zhukov at RedHat for bringing
-+  this issue to our attention and whose patch helped guide us in the right
-+  direction.
-+  [ISc-Bugs #46767]
-+
- 			Changes since 4.3.6b1
- 
- - None
-diff --git a/omapip/buffer.c b/omapip/buffer.c
-index f7fdc32..809034d 100644
---- a/omapip/buffer.c
-+++ b/omapip/buffer.c
-@@ -566,6 +566,15 @@ isc_result_t omapi_connection_writer (omapi_object_t *h)
- 			omapi_buffer_dereference (&buffer, MDL);
- 		}
- 	}
-+
-+	/* If we had data left to write when we're told to disconnect,
-+	* we need recall disconnect, now that we're done writing.
-+	* See rt46767. */
-+	if (c->out_bytes == 0 && c->state == omapi_connection_disconnecting) {
-+		omapi_disconnect (h, 1);
-+		return ISC_R_SHUTTINGDOWN;
-+	}
-+
- 	return ISC_R_SUCCESS;
- }
- 
-diff --git a/omapip/message.c b/omapip/message.c
-index 59ccdc2..21bcfc3 100644
---- a/omapip/message.c
-+++ b/omapip/message.c
-@@ -339,7 +339,7 @@ isc_result_t omapi_message_unregister (omapi_object_t *mo)
- }
- 
- #ifdef DEBUG_PROTOCOL
--static const char *omapi_message_op_name(int op) {
-+const char *omapi_message_op_name(int op) {
- 	switch (op) {
- 	case OMAPI_OP_OPEN:    return "OMAPI_OP_OPEN";
- 	case OMAPI_OP_REFRESH: return "OMAPI_OP_REFRESH";
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-connectivity/dhcp/dhcp_4.3.6.bb b/poky/meta/recipes-connectivity/dhcp/dhcp_4.3.6.bb
deleted file mode 100644
index 8b30579..0000000
--- a/poky/meta/recipes-connectivity/dhcp/dhcp_4.3.6.bb
+++ /dev/null
@@ -1,35 +0,0 @@
-require dhcp.inc
-
-SRC_URI += "file://0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch \
-            file://0002-dhclient-dbus.patch \
-            file://0003-link-with-lcrypto.patch \
-            file://0004-Fix-out-of-tree-builds.patch \
-            file://0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch \
-            file://0006-site.h-enable-gentle-shutdown.patch \
-            file://0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch \
-            file://0009-remove-dhclient-script-bash-dependency.patch \
-            file://0010-build-shared-libs.patch \
-            file://0011-Moved-the-call-to-isc_app_ctxstart-to-not-get-signal.patch \
-            file://0012-dhcp-correct-the-intention-for-xml2-lib-search.patch \
-            file://CVE-2017-3144.patch \
-           "
-
-# use internal libisc libraries which are based on bind 9.9.11 - there
-# is a bug in bind 9.10.x (normally supplied by OE) that prevents
-# dhcpd/dhclient from shutting down cleanly on sigterm and from running
-# in the background
-#
-# [https://bugzilla.yoctoproject.org/show_bug.cgi?id=12744]
-#
-# remove "ext-bind" and
-# also set PARALLEL_MAKE = "" 
-# [ Yocto 12744 ]
-#
-SRC_URI += "${@bb.utils.contains('PACKAGECONFIG', 'ext-bind', 'file://0008-tweak-to-support-external-bind.patch', '', d)}"
-
-SRC_URI[md5sum] = "afa6e9b3eb7539ea048421a82c668adc"
-SRC_URI[sha256sum] = "a41eaf6364f1377fe065d35671d9cf82bbbc8f21207819b2b9f33f652aec6f1b"
-
-PACKAGECONFIG ?= "ext-bind"
-PACKAGECONFIG[bind-httpstats] = "--with-libxml2,--without-libxml2,libxml2"
-PACKAGECONFIG[ext-bind] = "--with-libbind=${STAGING_LIBDIR}, --without-libbind, bind"
diff --git a/poky/meta/recipes-connectivity/dhcp/dhcp_4.4.1.bb b/poky/meta/recipes-connectivity/dhcp/dhcp_4.4.1.bb
new file mode 100644
index 0000000..159abbc
--- /dev/null
+++ b/poky/meta/recipes-connectivity/dhcp/dhcp_4.4.1.bb
@@ -0,0 +1,21 @@
+require dhcp.inc
+
+SRC_URI += "file://0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch \
+            file://0002-dhclient-dbus.patch \
+            file://0003-link-with-lcrypto.patch \
+            file://0004-Fix-out-of-tree-builds.patch \
+            file://0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch \
+            file://0006-site.h-enable-gentle-shutdown.patch \
+            file://0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch \
+            file://0009-remove-dhclient-script-bash-dependency.patch \
+            file://0012-dhcp-correct-the-intention-for-xml2-lib-search.patch \
+            file://0013-fixup_use_libbind.patch \
+"
+
+SRC_URI[md5sum] = "18c7f4dcbb0a63df25098216d47b1ede"
+SRC_URI[sha256sum] = "2a22508922ab367b4af4664a0472dc220cc9603482cf3c16d9aff14f3a76b608"
+
+LDFLAGS_append = " -pthread"
+
+PACKAGECONFIG ?= ""
+PACKAGECONFIG[bind-httpstats] = "--with-libxml2,--without-libxml2,libxml2"
diff --git a/poky/meta/recipes-connectivity/dhcp/files/dhcpd6.service b/poky/meta/recipes-connectivity/dhcp/files/dhcpd6.service
index ca96abb..52a6224 100644
--- a/poky/meta/recipes-connectivity/dhcp/files/dhcpd6.service
+++ b/poky/meta/recipes-connectivity/dhcp/files/dhcpd6.service
@@ -9,7 +9,7 @@
 EnvironmentFile=@SYSCONFDIR@/default/dhcp-server
 EnvironmentFile=-@SYSCONFDIR@/sysconfig/dhcpd6
 ExecStartPre=@base_bindir@/touch @localstatedir@/lib/dhcp/dhcpd6.leases
-ExecStart=@SBINDIR@/dhcpd -f -6 -cf @SYSCONFDIR@/dhcp/dhcpd.conf -pf @localstatedir@/run/dhcpd6.pid $DHCPDARGS -q $INTERFACES
+ExecStart=@SBINDIR@/dhcpd -f -6 -cf @SYSCONFDIR@/dhcp/dhcpd6.conf -pf @localstatedir@/run/dhcpd6.pid $DHCPDARGS -q $INTERFACES
 
 [Install]
 WantedBy=multi-user.target
diff --git a/poky/meta/recipes-connectivity/iproute2/iproute2.inc b/poky/meta/recipes-connectivity/iproute2/iproute2.inc
index 4fbfec6..b283589 100644
--- a/poky/meta/recipes-connectivity/iproute2/iproute2.inc
+++ b/poky/meta/recipes-connectivity/iproute2/iproute2.inc
@@ -9,7 +9,7 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=eb723b61539feef013de476e68b5c50a \
                     file://ip/ip.c;beginline=3;endline=8;md5=689d691d0410a4b64d3899f8d6e31817"
 
-DEPENDS = "flex-native bison-native iptables elfutils"
+DEPENDS = "flex-native bison-native iptables elfutils libcap"
 
 inherit update-alternatives bash-completion pkgconfig
 
diff --git a/poky/meta/recipes-connectivity/iproute2/iproute2/0001-iproute2-de-bash-scripts.patch b/poky/meta/recipes-connectivity/iproute2/iproute2/0001-iproute2-de-bash-scripts.patch
deleted file mode 100644
index c3d3fea..0000000
--- a/poky/meta/recipes-connectivity/iproute2/iproute2/0001-iproute2-de-bash-scripts.patch
+++ /dev/null
@@ -1,63 +0,0 @@
-Subject: [PATCH] iproute2: de-bash scripts
-
-de-bash these two scripts to make iproute2 not depend on bash.
-
-Upstream-Status: Pending
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- ip/ifcfg | 15 ++++++++-------
- ip/rtpr  |  2 +-
- 2 files changed, 9 insertions(+), 8 deletions(-)
-
-diff --git a/ip/ifcfg b/ip/ifcfg
-index 30a2dc4..8677b2e 100644
---- a/ip/ifcfg
-+++ b/ip/ifcfg
-@@ -1,12 +1,13 @@
--#! /bin/bash
-+#! /bin/sh
- 
- CheckForwarding () {
--  local sbase fwd
-+  local sbase fwd forwarding
-   sbase=/proc/sys/net/ipv4/conf
-   fwd=0
-   if [ -d $sbase ]; then
-     for dir in $sbase/*/forwarding; do
--      fwd=$[$fwd + `cat $dir`]
-+      forwarding=`cat $dir`
-+      fwd=$(($fwd+$forwarding))
-     done
-   else
-     fwd=2
-@@ -127,12 +128,12 @@ fi
- arping -q -A -c 1 -I $dev $ipaddr
- noarp=$?
- ( sleep 2 ;
--  arping -q -U -c 1 -I $dev $ipaddr ) >& /dev/null </dev/null &
-+  arping -q -U -c 1 -I $dev $ipaddr ) > /dev/null 2>&1 </dev/null &
- 
--ip route add unreachable 224.0.0.0/24 >& /dev/null
--ip route add unreachable 255.255.255.255 >& /dev/null
-+ip route add unreachable 224.0.0.0/24 > /dev/null 2>&1
-+ip route add unreachable 255.255.255.255 > /dev/null 2>&1
- if [ "`ip link ls $dev | grep -c MULTICAST`" -ge 1 ]; then
--  ip route add 224.0.0.0/4 dev $dev scope global >& /dev/null
-+  ip route add 224.0.0.0/4 dev $dev scope global > /dev/null 2>&1
- fi
- 
- if [ $fwd -eq 0 ]; then
-diff --git a/ip/rtpr b/ip/rtpr
-index c3629fd..674198d 100644
---- a/ip/rtpr
-+++ b/ip/rtpr
-@@ -1,4 +1,4 @@
--#! /bin/bash
-+#! /bin/sh
- 
- exec tr "[\\\\]" "[
- ]"
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-connectivity/iproute2/iproute2_4.14.1.bb b/poky/meta/recipes-connectivity/iproute2/iproute2_4.14.1.bb
deleted file mode 100644
index 81e2e4a..0000000
--- a/poky/meta/recipes-connectivity/iproute2/iproute2_4.14.1.bb
+++ /dev/null
@@ -1,15 +0,0 @@
-require iproute2.inc
-
-SRC_URI = "${KERNELORG_MIRROR}/linux/utils/net/${BPN}/${BP}.tar.xz \
-           file://configure-cross.patch \
-           file://0001-iproute2-de-bash-scripts.patch \
-           file://0001-libc-compat.h-add-musl-workaround.patch \
-           file://0001-ip-Remove-unneed-header.patch \
-          "
-
-SRC_URI[md5sum] = "1075423d7029e02a8f23ed4f42b7e372"
-SRC_URI[sha256sum] = "d43ac068afcc350a448f4581b6e292331ef7e4e7aa746e34981582d5fdb10067"
-
-# CFLAGS are computed in Makefile and reference CCOPTS
-#
-EXTRA_OEMAKE_append = " CCOPTS='${CFLAGS}'"
diff --git a/poky/meta/recipes-connectivity/iproute2/iproute2_4.18.0.bb b/poky/meta/recipes-connectivity/iproute2/iproute2_4.18.0.bb
new file mode 100644
index 0000000..8eed377
--- /dev/null
+++ b/poky/meta/recipes-connectivity/iproute2/iproute2_4.18.0.bb
@@ -0,0 +1,14 @@
+require iproute2.inc
+
+SRC_URI = "${KERNELORG_MIRROR}/linux/utils/net/${BPN}/${BP}.tar.xz \
+           file://configure-cross.patch \
+           file://0001-libc-compat.h-add-musl-workaround.patch \
+           file://0001-ip-Remove-unneed-header.patch \
+          "
+
+SRC_URI[md5sum] = "8b8680e91390c57cab788fbf8e929479"
+SRC_URI[sha256sum] = "a9e6c70c95f513871c5e1f4e452c04fcb3c4d8a05be651bd794cd994a52daa45"
+
+# CFLAGS are computed in Makefile and reference CCOPTS
+#
+EXTRA_OEMAKE_append = " CCOPTS='${CFLAGS}'"
diff --git a/poky/meta/recipes-connectivity/libnss-mdns/libnss-mdns_0.10.bb b/poky/meta/recipes-connectivity/libnss-mdns/libnss-mdns_0.10.bb
index 8d2feec..d0eb276 100644
--- a/poky/meta/recipes-connectivity/libnss-mdns/libnss-mdns_0.10.bb
+++ b/poky/meta/recipes-connectivity/libnss-mdns/libnss-mdns_0.10.bb
@@ -17,6 +17,8 @@
 
 S = "${WORKDIR}/nss-mdns-${PV}"
 
+localstatedir = "/"
+
 inherit autotools
 
 EXTRA_OECONF = "--libdir=${base_libdir} --disable-lynx --enable-avahi"
@@ -28,13 +30,16 @@
 RDEPENDS_${PN} = "avahi-daemon"
 
 pkg_postinst_${PN} () {
-	sed -e '/^hosts:/s/\s*\<mdns\>//' \
-		-e 's/\(^hosts:.*\)\(\<files\>\)\(.*\)\(\<dns\>\)\(.*\)/\1\2 mdns4_minimal [NOTFOUND=return]\3\4 mdns\5/' \
-		-i $D${sysconfdir}/nsswitch.conf
+	sed '
+		/^hosts:/ !b
+		/\<mdns\(4\|6\)\?\(_minimal\)\?\>/ b
+		s/\([[:blank:]]\+\)dns\>/\1mdns4_minimal [NOTFOUND=return] dns/g
+		' -i $D${sysconfdir}/nsswitch.conf
 }
 
 pkg_prerm_${PN} () {
-	sed -e '/^hosts:/s/\s*\<mdns\>//' \
-		-e '/^hosts:/s/\s*mdns4_minimal\s\+\[NOTFOUND=return\]//' \
-		-i $D${sysconfdir}/nsswitch.conf
+	sed '
+		/^hosts:/ !b
+		s/[[:blank:]]\+mdns\(4\|6\)\?\(_minimal\( \[NOTFOUND=return\]\)\?\)\?//g
+		' -i $D${sysconfdir}/nsswitch.conf
 }
diff --git a/poky/meta/recipes-connectivity/mobile-broadband-provider-info/mobile-broadband-provider-info/multilibfix.patch b/poky/meta/recipes-connectivity/mobile-broadband-provider-info/mobile-broadband-provider-info/multilibfix.patch
new file mode 100644
index 0000000..7e97e8e
--- /dev/null
+++ b/poky/meta/recipes-connectivity/mobile-broadband-provider-info/mobile-broadband-provider-info/multilibfix.patch
@@ -0,0 +1,18 @@
+The mobile-broadband-provider-info.pc file is installed into a non-arch directory
+yet contains libdir which can vary depending on which multilib is configured.
+The .pc file does not require libdir so remove this to fix multilib builds.
+
+Upstream-Status: Backport [8109fcd3c7299fae859fb891ff416927581a9955]
+Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
+
+Index: git/mobile-broadband-provider-info.pc.in
+===================================================================
+--- git.orig/mobile-broadband-provider-info.pc.in	2018-08-07 13:09:31.811364063 +0800
++++ git/mobile-broadband-provider-info.pc.in	2018-08-10 17:49:25.645288320 +0800
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ datarootdir = @datarootdir@
+ pkgdatadir=${datarootdir}/@PACKAGE@
+ includedir=@includedir@
diff --git a/poky/meta/recipes-connectivity/mobile-broadband-provider-info/mobile-broadband-provider-info_git.bb b/poky/meta/recipes-connectivity/mobile-broadband-provider-info/mobile-broadband-provider-info_git.bb
index 57f521a..7f1dd78 100644
--- a/poky/meta/recipes-connectivity/mobile-broadband-provider-info/mobile-broadband-provider-info_git.bb
+++ b/poky/meta/recipes-connectivity/mobile-broadband-provider-info/mobile-broadband-provider-info_git.bb
@@ -7,8 +7,9 @@
 PV = "20170310"
 PE = "1"
 
-SRC_URI = "git://gitlab.gnome.org/GNOME/mobile-broadband-provider-info;protocol=https"
-
+SRC_URI = "git://gitlab.gnome.org/GNOME/mobile-broadband-provider-info.git;protocol=https \
+           file://multilibfix.patch \
+"
 S = "${WORKDIR}/git"
 
 inherit autotools
diff --git a/poky/meta/recipes-connectivity/nfs-utils/libnfsidmap/0001-include-sys-types.h-for-getting-u_-typedefs.patch b/poky/meta/recipes-connectivity/nfs-utils/libnfsidmap/0001-include-sys-types.h-for-getting-u_-typedefs.patch
deleted file mode 100644
index 4ac5290..0000000
--- a/poky/meta/recipes-connectivity/nfs-utils/libnfsidmap/0001-include-sys-types.h-for-getting-u_-typedefs.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From a5e95a42e7bceddc9ecad06694c1a0588f4bafc8 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 14 Apr 2015 07:22:47 -0700
-Subject: [PATCH] include sys/types.h for getting u_* typedefs
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- cfg.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/cfg.h b/cfg.h
-index d4d4cab..fe49e8f 100644
---- a/cfg.h
-+++ b/cfg.h
-@@ -33,6 +33,7 @@
- #ifndef _CONF_H_
- #define _CONF_H_
- 
-+#include <sys/types.h>
- #include "queue.h"
- 
- struct conf_list_node {
--- 
-2.1.4
-
diff --git a/poky/meta/recipes-connectivity/nfs-utils/libnfsidmap/Set_nobody_user_group.patch b/poky/meta/recipes-connectivity/nfs-utils/libnfsidmap/Set_nobody_user_group.patch
deleted file mode 100644
index 4633da9..0000000
--- a/poky/meta/recipes-connectivity/nfs-utils/libnfsidmap/Set_nobody_user_group.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-Set nobody user and group
-
-Upstream-Status: Inappropriate [configuration]
-
-Signed-off-by: Roy.Li <rongqing.li@windriver.com>
---- a/idmapd.conf
-+++ b/idmapd.conf
-@@ -17,8 +17,8 @@
- 
- [Mapping]
- 
--#Nobody-User = nobody
--#Nobody-Group = nobody
-+Nobody-User = nobody
-+Nobody-Group = nogroup
- 
- [Translation]
- 
diff --git a/poky/meta/recipes-connectivity/nfs-utils/libnfsidmap/fix-ac-prereq.patch b/poky/meta/recipes-connectivity/nfs-utils/libnfsidmap/fix-ac-prereq.patch
deleted file mode 100644
index d81c7c5..0000000
--- a/poky/meta/recipes-connectivity/nfs-utils/libnfsidmap/fix-ac-prereq.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-Upstream-Status: Inappropriate [configuration]
-
---- a/configure.in
-+++ b/configure.in
-@@ -1,7 +1,7 @@
- #                                               -*- Autoconf -*-
- # Process this file with autoconf to produce a configure script.
- 
--AC_PREREQ([2.68])
-+AC_PREREQ([2.65])
- AC_INIT([libnfsidmap],[0.25],[linux-nfs@vger.kernel.org])
- AC_CONFIG_SRCDIR([nfsidmap.h])
- AC_CONFIG_MACRO_DIR([m4])
diff --git a/poky/meta/recipes-connectivity/nfs-utils/libnfsidmap_0.25.bb b/poky/meta/recipes-connectivity/nfs-utils/libnfsidmap_0.25.bb
deleted file mode 100644
index 2565771..0000000
--- a/poky/meta/recipes-connectivity/nfs-utils/libnfsidmap_0.25.bb
+++ /dev/null
@@ -1,27 +0,0 @@
-SUMMARY = "NFS id mapping library"
-HOMEPAGE = "http://www.citi.umich.edu/projects/nfsv4/linux/"
-SECTION = "libs"
-
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d9c6a2a0ca6017fda7cd905ed2739b37"
-
-SRC_URI = "http://www.citi.umich.edu/projects/nfsv4/linux/libnfsidmap/${BPN}-${PV}.tar.gz \
-           file://fix-ac-prereq.patch \
-           file://Set_nobody_user_group.patch \
-           file://0001-include-sys-types.h-for-getting-u_-typedefs.patch \
-          "
-
-SRC_URI[md5sum] = "2ac4893c92716add1a1447ae01df77ab"
-SRC_URI[sha256sum] = "656d245d84400e1030f8f40a5a27da76370690c4a932baf249110f047fe7efcf"
-
-UPSTREAM_CHECK_URI = "http://www.citi.umich.edu/projects/nfsv4/linux/libnfsidmap/"
-
-inherit autotools
-
-EXTRA_OECONF = "--disable-ldap"
-
-do_install_append () {
-	install -d ${D}${sysconfdir}/
-	install -m 0644 ${WORKDIR}/${BPN}-${PV}/idmapd.conf ${D}${sysconfdir}/idmapd.conf
-}
-
diff --git a/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/0001-configure-Allow-to-explicitly-disable-nfsidmap.patch b/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/0001-configure-Allow-to-explicitly-disable-nfsidmap.patch
deleted file mode 100644
index 26b558c..0000000
--- a/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/0001-configure-Allow-to-explicitly-disable-nfsidmap.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From 9b84cff305866abd150cf1a4c6e7e5ebf8a7eb3a Mon Sep 17 00:00:00 2001
-From: Martin Jansa <Martin.Jansa@gmail.com>
-Date: Fri, 15 Nov 2013 23:21:35 +0100
-Subject: [PATCH] configure: Allow to explicitly disable nfsidmap
-
-* keyutils availability is autodetected and builds aren't reproducible
-
-Upstream-Status: Pending
-
-Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
----
- configure.ac | 10 +++++++++-
- 1 file changed, 9 insertions(+), 1 deletion(-)
-
-Index: nfs-utils-2.1.1/configure.ac
-===================================================================
---- nfs-utils-2.1.1.orig/configure.ac
-+++ nfs-utils-2.1.1/configure.ac
-@@ -92,6 +92,12 @@ AC_ARG_ENABLE(nfsv4,
- 	AC_SUBST(enable_nfsv4)
- 	AM_CONDITIONAL(CONFIG_NFSV4, [test "$enable_nfsv4" = "yes"])
- 
-+AC_ARG_ENABLE(nfsidmap,
-+        [AC_HELP_STRING([--enable-nfsidmap],
-+                        [enable support for NFSv4 idmapper @<:@default=yes@:>@])],
-+        enable_nfsidmap=$enableval,
-+        enable_nfsidmap=yes)
-+
- AC_ARG_ENABLE(nfsv41,
- 	[AC_HELP_STRING([--disable-nfsv41],
-                         [disable support for NFSv41 @<:@default=no@:>@])],
-@@ -339,7 +345,7 @@ fi
- 
- dnl enable nfsidmap when its support by libnfsidmap
- AM_CONDITIONAL(CONFIG_NFSDCLTRACK, [test "$enable_nfsdcltrack" = "yes" ])
--AM_CONDITIONAL(CONFIG_NFSIDMAP, [test "$ac_cv_header_keyutils_h$ac_cv_lib_nfsidmap_nfs4_owner_to_uid" = "yesyes"])
-+AM_CONDITIONAL(CONFIG_NFSIDMAP, [test "$enable_nfsidmap$ac_cv_header_keyutils_h$ac_cv_lib_nfsidmap_nfs4_owner_to_uid" = "yesyesyes"])
- 
- 
- if test "$knfsd_cv_glibc2" = no; then
diff --git a/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/0001-include-stdint.h-for-UINT16_MAX-definition.patch b/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/0001-include-stdint.h-for-UINT16_MAX-definition.patch
deleted file mode 100644
index 235a2c7..0000000
--- a/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/0001-include-stdint.h-for-UINT16_MAX-definition.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 36b48057bce76dced335d67a2894a420967811c9 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 20 May 2017 14:07:53 -0700
-Subject: [PATCH] include stdint.h for UINT16_MAX definition
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Pending
-
- support/nsm/rpc.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/support/nsm/rpc.c b/support/nsm/rpc.c
-index 4e5f40e..d91c6ea 100644
---- a/support/nsm/rpc.c
-+++ b/support/nsm/rpc.c
-@@ -40,6 +40,7 @@
- 
- #include <time.h>
- #include <stdbool.h>
-+#include <stdint.h>
- #include <string.h>
- #include <unistd.h>
- #include <fcntl.h>
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-connectivity/nfs-utils/files/bugfix-adjust-statd-service-name.patch b/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/bugfix-adjust-statd-service-name.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/nfs-utils/files/bugfix-adjust-statd-service-name.patch
rename to poky/meta/recipes-connectivity/nfs-utils/nfs-utils/bugfix-adjust-statd-service-name.patch
diff --git a/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-1.2.3-sm-notify-res_init.patch b/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-1.2.3-sm-notify-res_init.patch
deleted file mode 100644
index 89a8a57..0000000
--- a/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-1.2.3-sm-notify-res_init.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-Fixes errors like
-sm-notify[1070]: DNS resolution of a.b.c.d..com failed; retrying later
-This error will occur anytime sm-notify is run before the network if fully up,
-which is happening more and more with parallel startup systems.
-The res_init() call is simple, safe, quick, and a patch to use it should be
-able to go upstream.  Presumably the whole reason sm-notify tries several
-times is to wait for possible changes to the network configuration, but without
-calling res_init() it will never be aware of those changes
-
-Backported drom Fedora
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-
-Index: nfs-utils-2.1.1/utils/statd/sm-notify.c
-===================================================================
---- nfs-utils-2.1.1.orig/utils/statd/sm-notify.c
-+++ nfs-utils-2.1.1/utils/statd/sm-notify.c
-@@ -28,6 +28,9 @@
- #include <netdb.h>
- #include <errno.h>
- #include <grp.h>
-+#include <netinet/in.h>
-+#include <arpa/nameser.h>
-+#include <resolv.h>
- 
- #include "conffile.h"
- #include "sockaddr.h"
-@@ -89,6 +92,7 @@ smn_lookup(const char *name)
- 	};
- 	int error;
- 
-+	res_init();
- 	error = getaddrinfo(name, NULL, &hint, &ai);
- 	if (error != 0) {
- 		xlog(D_GENERAL, "getaddrinfo(3): %s", gai_strerror(error));
diff --git a/poky/meta/recipes-connectivity/nfs-utils/files/nfs-utils-debianize-start-statd.patch b/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-debianize-start-statd.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/nfs-utils/files/nfs-utils-debianize-start-statd.patch
rename to poky/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-debianize-start-statd.patch
diff --git a/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-musl-limits.patch b/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-musl-limits.patch
new file mode 100644
index 0000000..25ca415
--- /dev/null
+++ b/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-musl-limits.patch
@@ -0,0 +1,133 @@
+Fixed:
+| file.c: In function 'generic_make_pathname':
+| file.c:48:13: error: 'PATH_MAX' undeclared (first use in this function); did you mean 'RAND_MAX'?
+|   if (size > PATH_MAX)
+|              ^~~~~~~~
+[snip]
+
+Upstream-Status: Pending [https://git.alpinelinux.org/cgit/aports/tree/main/nfs-utils/limits.patch?id=f6734a77d3caee73325f8cc1f77d1b5117a75096]
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ support/export/export.c          | 1 +
+ support/export/xtab.c            | 1 +
+ support/misc/file.c              | 1 +
+ support/nfs/xcommon.c            | 1 +
+ support/nsm/file.c               | 1 +
+ utils/blkmapd/device-discovery.c | 1 +
+ utils/gssd/krb5_util.c           | 1 +
+ utils/mountd/cache.c             | 1 +
+ utils/mountd/mountd.c            | 1 +
+ utils/mountd/rmtab.c             | 1 +
+ 10 files changed, 10 insertions(+)
+
+diff --git a/support/export/export.c b/support/export/export.c
+--- a/support/export/export.c
++++ b/support/export/export.c
+@@ -17,6 +17,7 @@
+ #include <stdlib.h>
+ #include <dirent.h>
+ #include <errno.h>
++#include <limits.h>
+ #include "xmalloc.h"
+ #include "nfslib.h"
+ #include "exportfs.h"
+diff --git a/support/export/xtab.c b/support/export/xtab.c
+--- a/support/export/xtab.c
++++ b/support/export/xtab.c
+@@ -18,6 +18,7 @@
+ #include <sys/stat.h>
+ #include <errno.h>
+ #include <libgen.h>
++#include <limits.h>
+ 
+ #include "nfslib.h"
+ #include "exportfs.h"
+diff --git a/support/misc/file.c b/support/misc/file.c
+--- a/support/misc/file.c
++++ b/support/misc/file.c
+@@ -27,6 +27,7 @@
+ #include <dirent.h>
+ #include <stdlib.h>
+ #include <stdbool.h>
++#include <limits.h>
+ 
+ #include "xlog.h"
+ #include "misc.h"
+diff --git a/support/nfs/xcommon.c b/support/nfs/xcommon.c
+--- a/support/nfs/xcommon.c
++++ b/support/nfs/xcommon.c
+@@ -16,6 +16,7 @@
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>
++#include <limits.h>
+ 
+ #include "xcommon.h"
+ #include "nls.h"	/* _() */
+diff --git a/support/nsm/file.c b/support/nsm/file.c
+--- a/support/nsm/file.c
++++ b/support/nsm/file.c
+@@ -85,6 +85,7 @@
+ #include <fcntl.h>
+ #include <dirent.h>
+ #include <grp.h>
++#include <limits.h>
+ 
+ #include "xlog.h"
+ #include "nsm.h"
+diff --git a/utils/blkmapd/device-discovery.c b/utils/blkmapd/device-discovery.c
+--- a/utils/blkmapd/device-discovery.c
++++ b/utils/blkmapd/device-discovery.c
+@@ -49,6 +49,7 @@
+ #include <unistd.h>
+ #include <libgen.h>
+ #include <errno.h>
++#include <limits.h>
+ #include <libdevmapper.h>
+ 
+ #ifdef HAVE_CONFIG_H
+diff --git a/utils/gssd/krb5_util.c b/utils/gssd/krb5_util.c
+--- a/utils/gssd/krb5_util.c
++++ b/utils/gssd/krb5_util.c
+@@ -120,6 +120,7 @@
+ #endif
+ #include <krb5.h>
+ #include <rpc/auth_gss.h>
++#include <limits.h>
+ 
+ #include "gssd.h"
+ #include "err_util.h"
+diff --git a/utils/mountd/cache.c b/utils/mountd/cache.c
+--- a/utils/mountd/cache.c
++++ b/utils/mountd/cache.c
+@@ -26,6 +26,7 @@
+ #include <pwd.h>
+ #include <grp.h>
+ #include <mntent.h>
++#include <limits.h>
+ #include "misc.h"
+ #include "nfslib.h"
+ #include "exportfs.h"
+diff --git a/utils/mountd/mountd.c b/utils/mountd/mountd.c
+--- a/utils/mountd/mountd.c
++++ b/utils/mountd/mountd.c
+@@ -22,6 +22,7 @@
+ #include <fcntl.h>
+ #include <sys/resource.h>
+ #include <sys/wait.h>
++#include <limits.h>
+ 
+ #include "conffile.h"
+ #include "xmalloc.h"
+diff --git a/utils/mountd/rmtab.c b/utils/mountd/rmtab.c
+--- a/utils/mountd/rmtab.c
++++ b/utils/mountd/rmtab.c
+@@ -16,6 +16,7 @@
+ #include <netinet/in.h>
+ #include <arpa/inet.h>
+ #include <netdb.h>
++#include <limits.h>
+ 
+ #include "misc.h"
+ #include "exportfs.h"
diff --git a/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-musl-res_querydomain.patch b/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-musl-res_querydomain.patch
new file mode 100644
index 0000000..a169e6a
--- /dev/null
+++ b/poky/meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-utils-musl-res_querydomain.patch
@@ -0,0 +1,22 @@
+Fixed:
+configure: error: res_querydomain needed
+
+Upstream-Status: Pending [https://git.alpinelinux.org/cgit/aports/tree/main/nfs-utils/musl-res_querydomain.patch?id=f6734a77d3caee73325f8cc1f77d1b5117a75096]
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+--- a/configure.ac
++++ b/configure.ac
+@@ -401,7 +401,7 @@ if test "$enable_gss" = yes; then
+ fi
+ 
+ dnl libdnsidmap specific checks
+-AC_CHECK_LIB([resolv], [__res_querydomain], , AC_MSG_ERROR(res_querydomain needed))
++AC_CHECK_LIB([resolv], [res_querydomain], , AC_MSG_ERROR(res_querydomain needed))
+ 
+ AC_ARG_ENABLE([ldap],
+ 	[AS_HELP_STRING([--disable-ldap],[Disable support for LDAP @<:default=detect@:>@])])
diff --git a/poky/meta/recipes-connectivity/nfs-utils/nfs-utils_2.1.1.bb b/poky/meta/recipes-connectivity/nfs-utils/nfs-utils_2.1.1.bb
deleted file mode 100644
index 79453ad..0000000
--- a/poky/meta/recipes-connectivity/nfs-utils/nfs-utils_2.1.1.bb
+++ /dev/null
@@ -1,150 +0,0 @@
-SUMMARY = "userspace utilities for kernel nfs"
-DESCRIPTION = "The nfs-utils package provides a daemon for the kernel \
-NFS server and related tools."
-HOMEPAGE = "http://nfs.sourceforge.net/"
-SECTION = "console/network"
-
-LICENSE = "MIT & GPLv2+ & BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=95f3a93a5c3c7888de623b46ea085a84"
-
-# util-linux for libblkid
-DEPENDS = "libcap libnfsidmap libevent util-linux sqlite3 libtirpc"
-RDEPENDS_${PN} = "${PN}-client bash"
-RRECOMMENDS_${PN} = "kernel-module-nfsd"
-
-inherit useradd
-
-USERADD_PACKAGES = "${PN}-client"
-USERADD_PARAM_${PN}-client = "--system  --home-dir /var/lib/nfs \
-			      --shell /bin/false --user-group rpcuser"
-
-SRC_URI = "${KERNELORG_MIRROR}/linux/utils/nfs-utils/${PV}/nfs-utils-${PV}.tar.xz \
-           file://0001-configure-Allow-to-explicitly-disable-nfsidmap.patch \
-           file://nfs-utils-1.2.3-sm-notify-res_init.patch \
-           file://nfsserver \
-           file://nfscommon \
-           file://nfs-utils.conf \
-           file://nfs-server.service \
-           file://nfs-mountd.service \
-           file://nfs-statd.service \
-           file://proc-fs-nfsd.mount \
-           file://nfs-utils-Do-not-pass-CFLAGS-to-gcc-while-building.patch \
-           file://nfs-utils-debianize-start-statd.patch \
-           file://bugfix-adjust-statd-service-name.patch \
-           file://0001-include-stdint.h-for-UINT16_MAX-definition.patch \
-"
-
-SRC_URI[md5sum] = "59dfcb2e6254b129f901f40c86086b13"
-SRC_URI[sha256sum] = "0faeb54c70b84e6bd3b9b6901544b1f6add8d246f35c1683e402daf4e0c719ef"
-
-# Only kernel-module-nfsd is required here (but can be built-in)  - the nfsd module will
-# pull in the remainder of the dependencies.
-
-INITSCRIPT_PACKAGES = "${PN} ${PN}-client"
-INITSCRIPT_NAME = "nfsserver"
-INITSCRIPT_PARAMS = "defaults"
-INITSCRIPT_NAME_${PN}-client = "nfscommon"
-INITSCRIPT_PARAMS_${PN}-client = "defaults 19 21"
-
-inherit autotools-brokensep update-rc.d systemd pkgconfig
-
-SYSTEMD_PACKAGES = "${PN} ${PN}-client"
-SYSTEMD_SERVICE_${PN} = "nfs-server.service nfs-mountd.service"
-SYSTEMD_SERVICE_${PN}-client = "nfs-statd.service"
-
-# --enable-uuid is need for cross-compiling
-EXTRA_OECONF = "--with-statduser=rpcuser \
-                --enable-mountconfig \
-                --enable-libmount-mount \
-                --enable-uuid \
-                --disable-gss \
-                --disable-nfsdcltrack \
-                --with-statdpath=/var/lib/nfs/statd \
-               "
-
-PACKAGECONFIG ??= "tcp-wrappers \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} \
-"
-PACKAGECONFIG_remove_libc-musl = "tcp-wrappers"
-PACKAGECONFIG[tcp-wrappers] = "--with-tcp-wrappers,--without-tcp-wrappers,tcp-wrappers"
-PACKAGECONFIG[nfsidmap] = "--enable-nfsidmap,--disable-nfsidmap,keyutils"
-PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
-# libdevmapper is available in meta-oe
-PACKAGECONFIG[nfsv41] = "--enable-nfsv41,--disable-nfsv41,libdevmapper"
-
-PACKAGES =+ "${PN}-client ${PN}-mount ${PN}-stats"
-
-CONFFILES_${PN}-client += "${localstatedir}/lib/nfs/etab \
-			   ${localstatedir}/lib/nfs/rmtab \
-			   ${localstatedir}/lib/nfs/xtab \
-			   ${localstatedir}/lib/nfs/statd/state \
-			   ${sysconfdir}/nfsmount.conf"
-
-FILES_${PN}-client = "${sbindir}/*statd \
-		      ${sbindir}/rpc.idmapd ${sbindir}/sm-notify \
-		      ${sbindir}/showmount ${sbindir}/nfsstat \
-		      ${localstatedir}/lib/nfs \
-		      ${sysconfdir}/nfs-utils.conf \
-		      ${sysconfdir}/nfsmount.conf \
-		      ${sysconfdir}/init.d/nfscommon \
-		      ${systemd_unitdir}/system/nfs-statd.service"
-RDEPENDS_${PN}-client = "${PN}-mount rpcbind"
-
-FILES_${PN}-mount = "${base_sbindir}/*mount.nfs*"
-
-FILES_${PN}-stats = "${sbindir}/mountstats ${sbindir}/nfsiostat"
-RDEPENDS_${PN}-stats = "python3-core"
-
-FILES_${PN} += "${systemd_unitdir}"
-
-do_configure_prepend() {
-        sed -i -e 's,sbindir = /sbin,sbindir = ${base_sbindir},g' \
-            ${S}/utils/mount/Makefile.am
-
-        sed -i -e 's,sbindir = /sbin,sbindir = ${base_sbindir},g' \
-            ${S}/utils/osd_login/Makefile.am
-}
-
-# Make clean needed because the package comes with
-# precompiled 64-bit objects that break the build
-do_compile_prepend() {
-	make clean
-}
-
-do_install_append () {
-	install -d ${D}${sysconfdir}/init.d
-	install -m 0755 ${WORKDIR}/nfsserver ${D}${sysconfdir}/init.d/nfsserver
-	install -m 0755 ${WORKDIR}/nfscommon ${D}${sysconfdir}/init.d/nfscommon
-
-	install -m 0755 ${WORKDIR}/nfs-utils.conf ${D}${sysconfdir}
-	install -m 0755 ${S}/utils/mount/nfsmount.conf ${D}${sysconfdir}
-
-	install -d ${D}${systemd_unitdir}/system
-	install -m 0644 ${WORKDIR}/nfs-server.service ${D}${systemd_unitdir}/system/
-	install -m 0644 ${WORKDIR}/nfs-mountd.service ${D}${systemd_unitdir}/system/
-	install -m 0644 ${WORKDIR}/nfs-statd.service ${D}${systemd_unitdir}/system/
-	sed -i -e 's,@SBINDIR@,${sbindir},g' \
-		-e 's,@SYSCONFDIR@,${sysconfdir},g' \
-		${D}${systemd_unitdir}/system/*.service
-	if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
-	    install -m 0644 ${WORKDIR}/proc-fs-nfsd.mount ${D}${systemd_unitdir}/system/
-	    install -d ${D}${systemd_unitdir}/system/sysinit.target.wants/
-	    ln -sf ../proc-fs-nfsd.mount ${D}${systemd_unitdir}/system/sysinit.target.wants/proc-fs-nfsd.mount
-	fi
-
-	# kernel code as of 3.8 hard-codes this path as a default
-	install -d ${D}/var/lib/nfs/v4recovery
-
-	# chown the directories and files
-	chown -R rpcuser:rpcuser ${D}${localstatedir}/lib/nfs/statd
-	chmod 0644 ${D}${localstatedir}/lib/nfs/statd/state
-
-	# the following are built by CC_FOR_BUILD
-	rm -f ${D}${sbindir}/rpcdebug
-	rm -f ${D}${sbindir}/rpcgen
-	rm -f ${D}${sbindir}/locktest
-
-        # Make python tools use python 3
-        sed -i -e '1s,#!.*python.*,#!${bindir}/python3,' ${D}${sbindir}/mountstats ${D}${sbindir}/nfsiostat
-
-}
diff --git a/poky/meta/recipes-connectivity/nfs-utils/nfs-utils_2.3.1.bb b/poky/meta/recipes-connectivity/nfs-utils/nfs-utils_2.3.1.bb
new file mode 100644
index 0000000..6d450c7
--- /dev/null
+++ b/poky/meta/recipes-connectivity/nfs-utils/nfs-utils_2.3.1.bb
@@ -0,0 +1,151 @@
+SUMMARY = "userspace utilities for kernel nfs"
+DESCRIPTION = "The nfs-utils package provides a daemon for the kernel \
+NFS server and related tools."
+HOMEPAGE = "http://nfs.sourceforge.net/"
+SECTION = "console/network"
+
+LICENSE = "MIT & GPLv2+ & BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=95f3a93a5c3c7888de623b46ea085a84"
+
+# util-linux for libblkid
+DEPENDS = "libcap libevent util-linux sqlite3 libtirpc"
+RDEPENDS_${PN} = "${PN}-client bash"
+RRECOMMENDS_${PN} = "kernel-module-nfsd"
+
+inherit useradd
+
+USERADD_PACKAGES = "${PN}-client"
+USERADD_PARAM_${PN}-client = "--system  --home-dir /var/lib/nfs \
+			      --shell /bin/false --user-group rpcuser"
+
+SRC_URI = "${KERNELORG_MIRROR}/linux/utils/nfs-utils/${PV}/nfs-utils-${PV}.tar.xz \
+           file://nfsserver \
+           file://nfscommon \
+           file://nfs-utils.conf \
+           file://nfs-server.service \
+           file://nfs-mountd.service \
+           file://nfs-statd.service \
+           file://proc-fs-nfsd.mount \
+           file://nfs-utils-Do-not-pass-CFLAGS-to-gcc-while-building.patch \
+           file://nfs-utils-debianize-start-statd.patch \
+           file://bugfix-adjust-statd-service-name.patch \
+           file://nfs-utils-musl-limits.patch \
+"
+
+SRC_URI_append_libc-musl = " file://nfs-utils-musl-res_querydomain.patch"
+
+SRC_URI[md5sum] = "d77b182a9ee396aa6221ac2401ad7046"
+SRC_URI[sha256sum] = "96d06b5a86b185815760d8f04c34fdface8fa8b9949ff256ac05c3ebc08335a5"
+
+# Only kernel-module-nfsd is required here (but can be built-in)  - the nfsd module will
+# pull in the remainder of the dependencies.
+
+INITSCRIPT_PACKAGES = "${PN} ${PN}-client"
+INITSCRIPT_NAME = "nfsserver"
+INITSCRIPT_PARAMS = "defaults"
+INITSCRIPT_NAME_${PN}-client = "nfscommon"
+INITSCRIPT_PARAMS_${PN}-client = "defaults 19 21"
+
+inherit autotools-brokensep update-rc.d systemd pkgconfig
+
+SYSTEMD_PACKAGES = "${PN} ${PN}-client"
+SYSTEMD_SERVICE_${PN} = "nfs-server.service nfs-mountd.service"
+SYSTEMD_SERVICE_${PN}-client = "nfs-statd.service"
+
+# --enable-uuid is need for cross-compiling
+EXTRA_OECONF = "--with-statduser=rpcuser \
+                --enable-mountconfig \
+                --enable-libmount-mount \
+                --enable-uuid \
+                --disable-gss \
+                --disable-nfsdcltrack \
+                --with-statdpath=/var/lib/nfs/statd \
+               "
+
+PACKAGECONFIG ??= "tcp-wrappers \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} \
+"
+PACKAGECONFIG_remove_libc-musl = "tcp-wrappers"
+PACKAGECONFIG[tcp-wrappers] = "--with-tcp-wrappers,--without-tcp-wrappers,tcp-wrappers"
+PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
+# libdevmapper is available in meta-oe
+PACKAGECONFIG[nfsv41] = "--enable-nfsv41,--disable-nfsv41,libdevmapper"
+# keyutils is available in meta-security
+PACKAGECONFIG[nfsv4] = "--enable-nfsv4,--disable-nfsv4,keyutils"
+
+PACKAGES =+ "${PN}-client ${PN}-mount ${PN}-stats"
+
+CONFFILES_${PN}-client += "${localstatedir}/lib/nfs/etab \
+			   ${localstatedir}/lib/nfs/rmtab \
+			   ${localstatedir}/lib/nfs/xtab \
+			   ${localstatedir}/lib/nfs/statd/state \
+			   ${sysconfdir}/nfsmount.conf"
+
+FILES_${PN}-client = "${sbindir}/*statd \
+		      ${sbindir}/rpc.idmapd ${sbindir}/sm-notify \
+		      ${sbindir}/showmount ${sbindir}/nfsstat \
+		      ${localstatedir}/lib/nfs \
+		      ${sysconfdir}/nfs-utils.conf \
+		      ${sysconfdir}/nfsmount.conf \
+		      ${sysconfdir}/init.d/nfscommon \
+		      ${systemd_unitdir}/system/nfs-statd.service"
+RDEPENDS_${PN}-client = "${PN}-mount rpcbind"
+
+FILES_${PN}-mount = "${base_sbindir}/*mount.nfs*"
+
+FILES_${PN}-stats = "${sbindir}/mountstats ${sbindir}/nfsiostat"
+RDEPENDS_${PN}-stats = "python3-core"
+
+FILES_${PN} += "${systemd_unitdir}"
+
+do_configure_prepend() {
+        sed -i -e 's,sbindir = /sbin,sbindir = ${base_sbindir},g' \
+            ${S}/utils/mount/Makefile.am
+
+        sed -i -e 's,sbindir = /sbin,sbindir = ${base_sbindir},g' \
+            ${S}/utils/osd_login/Makefile.am
+}
+
+# Make clean needed because the package comes with
+# precompiled 64-bit objects that break the build
+do_compile_prepend() {
+	make clean
+}
+
+do_install_append () {
+	install -d ${D}${sysconfdir}/init.d
+	install -m 0755 ${WORKDIR}/nfsserver ${D}${sysconfdir}/init.d/nfsserver
+	install -m 0755 ${WORKDIR}/nfscommon ${D}${sysconfdir}/init.d/nfscommon
+
+	install -m 0755 ${WORKDIR}/nfs-utils.conf ${D}${sysconfdir}
+	install -m 0755 ${S}/utils/mount/nfsmount.conf ${D}${sysconfdir}
+
+	install -d ${D}${systemd_unitdir}/system
+	install -m 0644 ${WORKDIR}/nfs-server.service ${D}${systemd_unitdir}/system/
+	install -m 0644 ${WORKDIR}/nfs-mountd.service ${D}${systemd_unitdir}/system/
+	install -m 0644 ${WORKDIR}/nfs-statd.service ${D}${systemd_unitdir}/system/
+	sed -i -e 's,@SBINDIR@,${sbindir},g' \
+		-e 's,@SYSCONFDIR@,${sysconfdir},g' \
+		${D}${systemd_unitdir}/system/*.service
+	if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
+	    install -m 0644 ${WORKDIR}/proc-fs-nfsd.mount ${D}${systemd_unitdir}/system/
+	    install -d ${D}${systemd_unitdir}/system/sysinit.target.wants/
+	    ln -sf ../proc-fs-nfsd.mount ${D}${systemd_unitdir}/system/sysinit.target.wants/proc-fs-nfsd.mount
+	fi
+
+	# kernel code as of 3.8 hard-codes this path as a default
+	install -d ${D}/var/lib/nfs/v4recovery
+
+	# chown the directories and files
+	chown -R rpcuser:rpcuser ${D}${localstatedir}/lib/nfs/statd
+	chmod 0644 ${D}${localstatedir}/lib/nfs/statd/state
+
+	# the following are built by CC_FOR_BUILD
+	rm -f ${D}${sbindir}/rpcdebug
+	rm -f ${D}${sbindir}/rpcgen
+	rm -f ${D}${sbindir}/locktest
+
+        # Make python tools use python 3
+        sed -i -e '1s,#!.*python.*,#!${bindir}/python3,' ${D}${sbindir}/mountstats ${D}${sbindir}/nfsiostat
+
+}
diff --git a/poky/meta/recipes-connectivity/ofono/ofono_1.22.bb b/poky/meta/recipes-connectivity/ofono/ofono_1.22.bb
deleted file mode 100644
index e57eaa7..0000000
--- a/poky/meta/recipes-connectivity/ofono/ofono_1.22.bb
+++ /dev/null
@@ -1,9 +0,0 @@
-require ofono.inc
-
-SRC_URI  = "\
-  ${KERNELORG_MIRROR}/linux/network/${BPN}/${BP}.tar.xz \
-  file://ofono \
-  file://use-python3.patch \
-"
-SRC_URI[md5sum] = "2a683ab8e98448ad8bc5dc9868d2893e"
-SRC_URI[sha256sum] = "8e34a6696c300c9841b55e8dff640bd3096e49f5dbe55bbebaa69a71676f687e"
diff --git a/poky/meta/recipes-connectivity/ofono/ofono_1.24.bb b/poky/meta/recipes-connectivity/ofono/ofono_1.24.bb
new file mode 100644
index 0000000..be7d9ea
--- /dev/null
+++ b/poky/meta/recipes-connectivity/ofono/ofono_1.24.bb
@@ -0,0 +1,9 @@
+require ofono.inc
+
+SRC_URI  = "\
+  ${KERNELORG_MIRROR}/linux/network/${BPN}/${BP}.tar.xz \
+  file://ofono \
+  file://use-python3.patch \
+"
+SRC_URI[md5sum] = "be24e80f6551f46fea0c5b5879964d6c"
+SRC_URI[sha256sum] = "9c8e351b7658f4b43f9a4380b731c47d2d7544a89987c48c3f227e73636c87ae"
diff --git a/poky/meta/recipes-connectivity/openssh/openssh/disable-ciphers-not-supported-by-OpenSSL-DES.patch b/poky/meta/recipes-connectivity/openssh/openssh/disable-ciphers-not-supported-by-OpenSSL-DES.patch
deleted file mode 100644
index 8a2d1a0..0000000
--- a/poky/meta/recipes-connectivity/openssh/openssh/disable-ciphers-not-supported-by-OpenSSL-DES.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From 265eaab8b39d8d8721224a48eefed5bf1696d353 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Wed, 18 Apr 2018 21:58:32 +0800
-Subject: [PATCH] disable ciphers not supported by OpenSSL DES
-
-While compiling openssl with option `no-des', it caused the openssh
-build failure
-...
-cipher.c:85:41: error: 'EVP_des_ede3_cbc' undeclared here (not in a function);
-...
-
-OpenSSL configured that way defines OPENSSL_NO_DES to disable des
-
-Suggested by dtucker@
-
-Upstream-Status: Submitted [openssh-unix-dev@mindrot.org]
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- cipher.c | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/cipher.c b/cipher.c
-index c3cd5dc..86558e1 100644
---- a/cipher.c
-+++ b/cipher.c
-@@ -82,7 +82,9 @@ struct sshcipher {
- 
- static const struct sshcipher ciphers[] = {
- #ifdef WITH_OPENSSL
-+#ifndef OPENSSL_NO_DES
- 	{ "3des-cbc",		8, 24, 0, 0, CFLAG_CBC, EVP_des_ede3_cbc },
-+#endif
- 	{ "aes128-cbc",		16, 16, 0, 0, CFLAG_CBC, EVP_aes_128_cbc },
- 	{ "aes192-cbc",		16, 24, 0, 0, CFLAG_CBC, EVP_aes_192_cbc },
- 	{ "aes256-cbc",		16, 32, 0, 0, CFLAG_CBC, EVP_aes_256_cbc },
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-connectivity/openssh/openssh/init b/poky/meta/recipes-connectivity/openssh/openssh/init
index 34ba0f8..8887e3a 100644
--- a/poky/meta/recipes-connectivity/openssh/openssh/init
+++ b/poky/meta/recipes-connectivity/openssh/openssh/init
@@ -36,7 +36,7 @@
 }
 
 check_config() {
-	/usr/sbin/sshd -t $SSHD_OPTS || exit 1
+    /usr/sbin/sshd $SSHD_OPTS -t || exit 1
 }
 
 export PATH="${PATH:+$PATH:}/usr/sbin:/sbin"
@@ -48,19 +48,19 @@
 	@LIBEXECDIR@/sshd_check_keys
 	check_privsep_dir
 	start-stop-daemon -S -p $PIDFILE -x /usr/sbin/sshd -- $SSHD_OPTS
-        echo "done."
+	echo "done."
 	;;
   stop)
-        echo -n "Stopping OpenBSD Secure Shell server: sshd"
+	echo -n "Stopping OpenBSD Secure Shell server: sshd"
 	start-stop-daemon -K -p $PIDFILE -x /usr/sbin/sshd
-        echo "."
+	echo "."
 	;;
 
   reload|force-reload)
 	check_for_no_start
 	@LIBEXECDIR@/sshd_check_keys
 	check_config
-        echo -n "Reloading OpenBSD Secure Shell server's configuration"
+	echo -n "Reloading OpenBSD Secure Shell server's configuration"
 	start-stop-daemon -K -p $PIDFILE -s 1 -x /usr/sbin/sshd
 	echo "."
 	;;
@@ -68,7 +68,7 @@
   restart)
 	@LIBEXECDIR@/sshd_check_keys
 	check_config
-        echo -n "Restarting OpenBSD Secure Shell server: sshd"
+	echo -n "Restarting OpenBSD Secure Shell server: sshd"
 	start-stop-daemon -K -p $PIDFILE --oknodo -x /usr/sbin/sshd
 	check_for_no_start
 	check_privsep_dir
diff --git a/poky/meta/recipes-connectivity/openssh/openssh/ssh_config b/poky/meta/recipes-connectivity/openssh/openssh/ssh_config
index 9e91915..e0d0238 100644
--- a/poky/meta/recipes-connectivity/openssh/openssh/ssh_config
+++ b/poky/meta/recipes-connectivity/openssh/openssh/ssh_config
@@ -1,4 +1,4 @@
-#	$OpenBSD: ssh_config,v 1.28 2013/09/16 11:35:43 sthen Exp $
+#	$OpenBSD: ssh_config,v 1.33 2017/05/07 23:12:57 djm Exp $
 
 # This is the ssh client system-wide configuration file.  See
 # ssh_config(5) for more information.  This file provides defaults for
@@ -31,14 +31,14 @@
 #   AddressFamily any
 #   ConnectTimeout 0
 #   StrictHostKeyChecking ask
-#   IdentityFile ~/.ssh/identity
 #   IdentityFile ~/.ssh/id_rsa
 #   IdentityFile ~/.ssh/id_dsa
+#   IdentityFile ~/.ssh/id_ecdsa
+#   IdentityFile ~/.ssh/id_ed25519
 #   Port 22
-#   Protocol 2,1
-#   Cipher 3des
-#   Ciphers aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,aes128-cbc,3des-cbc
-#   MACs hmac-md5,hmac-sha1,umac-64@openssh.com,hmac-ripemd160
+#   Protocol 2
+#   Ciphers aes128-ctr,aes192-ctr,aes256-ctr,aes128-cbc,3des-cbc
+#   MACs hmac-md5,hmac-sha1,umac-64@openssh.com
 #   EscapeChar ~
 #   Tunnel no
 #   TunnelDevice any:any
diff --git a/poky/meta/recipes-connectivity/openssh/openssh/sshd_check_keys b/poky/meta/recipes-connectivity/openssh/openssh/sshd_check_keys
index 5463b1a..1931dc7 100644
--- a/poky/meta/recipes-connectivity/openssh/openssh/sshd_check_keys
+++ b/poky/meta/recipes-connectivity/openssh/openssh/sshd_check_keys
@@ -56,35 +56,23 @@
     esac
 done
 
-# parse location of keys
-HOST_KEY_RSA=$(grep ^HostKey "${sshd_config}" | grep _rsa_ | tail -1 | awk ' { print $2 } ')
-[ -z "${HOST_KEY_RSA}" ] && HOST_KEY_RSA=$(grep HostKey "${sshd_config}" | grep _rsa_ | tail -1 | awk ' { print $2 } ')
-[ -z "${HOST_KEY_RSA}" ] && HOST_KEY_RSA=$SYSCONFDIR/ssh_host_rsa_key
-HOST_KEY_DSA=$(grep ^HostKey "${sshd_config}" | grep _dsa_ | tail -1 | awk ' { print $2 } ')
-[ -z "${HOST_KEY_DSA}" ] && HOST_KEY_DSA=$(grep HostKey "${sshd_config}" | grep _dsa_ | tail -1 | awk ' { print $2 } ')
-[ -z "${HOST_KEY_DSA}" ] && HOST_KEY_DSA=$SYSCONFDIR/ssh_host_dsa_key
-HOST_KEY_ECDSA=$(grep ^HostKey "${sshd_config}" | grep _ecdsa_ | tail -1 | awk ' { print $2 } ')
-[ -z "${HOST_KEY_ECDSA}" ] && HOST_KEY_ECDSA=$(grep HostKey "${sshd_config}" | grep _ecdsa_ | tail -1 | awk ' { print $2 } ')
-[ -z "${HOST_KEY_ECDSA}" ] && HOST_KEY_ECDSA=$SYSCONFDIR/ssh_host_ecdsa_key
-HOST_KEY_ED25519=$(grep ^HostKey "${sshd_config}" | grep _ed25519_ | tail -1 | awk ' { print $2 } ')
-[ -z "${HOST_KEY_ED25519}" ] && HOST_KEY_ED25519=$(grep HostKey "${sshd_config}" | grep _ed25519_ | tail -1 | awk ' { print $2 } ')
-[ -z "${HOST_KEY_ED25519}" ] && HOST_KEY_ED25519=$SYSCONFDIR/ssh_host_ed25519_key
+HOST_KEYS=$(sed -n 's/^[ \t]*HostKey[ \t]\+\(.*\)/\1/p' "${sshd_config}")
+[ -z "${HOST_KEYS}" ] && HOST_KEYS="$SYSCONFDIR/ssh_host_rsa_key $SYSCONFDIR/ssh_host_ecdsa_key $SYSCONFDIR/ssh_host_ed25519_key"
 
-# create keys if necessary
-if [ ! -f $HOST_KEY_RSA ]; then
-    echo "  generating ssh RSA key..."
-    generate_key $HOST_KEY_RSA rsa
-fi
-if [ ! -f $HOST_KEY_ECDSA ]; then
-    echo "  generating ssh ECDSA key..."
-    generate_key $HOST_KEY_ECDSA ecdsa
-fi
-if [ ! -f $HOST_KEY_DSA ]; then
-    echo "  generating ssh DSA key..."
-    generate_key $HOST_KEY_DSA dsa
-fi
-if [ ! -f $HOST_KEY_ED25519 ]; then
-    echo "  generating ssh ED25519 key..."
-    generate_key $HOST_KEY_ED25519 ed25519
-fi
-
+for key in ${HOST_KEYS} ; do
+    [ -f $key ] && continue
+    case $key in
+    *_rsa_key)
+        echo "  generating ssh RSA host key..."
+        generate_key $key rsa
+        ;;
+    *_ecdsa_key)
+        echo "  generating ssh ECDSA host key..."
+        generate_key $key ecdsa
+        ;;
+    *_ed25519_key)
+        echo "  generating ssh ED25519 host key..."
+        generate_key $key ed25519
+        ;;
+    esac
+done
diff --git a/poky/meta/recipes-connectivity/openssh/openssh/sshd_config b/poky/meta/recipes-connectivity/openssh/openssh/sshd_config
index 31fe5d9..15f061b 100644
--- a/poky/meta/recipes-connectivity/openssh/openssh/sshd_config
+++ b/poky/meta/recipes-connectivity/openssh/openssh/sshd_config
@@ -1,4 +1,4 @@
-#	$OpenBSD: sshd_config,v 1.80 2008/07/02 02:24:18 djm Exp $
+#	$OpenBSD: sshd_config,v 1.102 2018/02/16 02:32:40 djm Exp $
 
 # This is the sshd server system-wide configuration file.  See
 # sshd_config(5) for more information.
@@ -7,7 +7,7 @@
 
 # The strategy used for options in the default sshd_config shipped with
 # OpenSSH is to specify options with their default value where
-# possible, but leave them commented.  Uncommented options change a
+# possible, but leave them commented.  Uncommented options override the
 # default value.
 
 #Port 22
@@ -15,43 +15,30 @@
 #ListenAddress 0.0.0.0
 #ListenAddress ::
 
-# The default requires explicit activation of protocol 1
-Protocol 2
-
-# HostKey for protocol version 1
-#HostKey /etc/ssh/ssh_host_key
-# HostKeys for protocol version 2
 #HostKey /etc/ssh/ssh_host_rsa_key
-#HostKey /etc/ssh/ssh_host_dsa_key
 #HostKey /etc/ssh/ssh_host_ecdsa_key
 #HostKey /etc/ssh/ssh_host_ed25519_key
 
-# Lifetime and size of ephemeral version 1 server key
-#KeyRegenerationInterval 1h
-#ServerKeyBits 1024
-
 # Ciphers and keying
 #RekeyLimit default none
 
 # Logging
-# obsoletes QuietMode and FascistLogging
 #SyslogFacility AUTH
 #LogLevel INFO
 
 # Authentication:
 
 #LoginGraceTime 2m
-#PermitRootLogin yes
+#PermitRootLogin prohibit-password
 #StrictModes yes
 #MaxAuthTries 6
 #MaxSessions 10
 
-#RSAAuthentication yes
 #PubkeyAuthentication yes
 
 # The default is to check both .ssh/authorized_keys and .ssh/authorized_keys2
 # but this is overridden so installations will only check .ssh/authorized_keys
-AuthorizedKeysFile .ssh/authorized_keys
+AuthorizedKeysFile	.ssh/authorized_keys
 
 #AuthorizedPrincipalsFile none
 
@@ -59,11 +46,9 @@
 #AuthorizedKeysCommandUser nobody
 
 # For this to work you will also need host keys in /etc/ssh/ssh_known_hosts
-#RhostsRSAAuthentication no
-# similar for protocol version 2
 #HostbasedAuthentication no
 # Change to yes if you don't trust ~/.ssh/known_hosts for
-# RhostsRSAAuthentication and HostbasedAuthentication
+# HostbasedAuthentication
 #IgnoreUserKnownHosts no
 # Don't read the user's ~/.rhosts and ~/.shosts files
 #IgnoreRhosts yes
@@ -72,7 +57,8 @@
 #PasswordAuthentication yes
 #PermitEmptyPasswords no
 
-# Change to no to disable s/key passwords
+# Change to yes to enable challenge-response passwords (beware issues with
+# some PAM modules and threads)
 ChallengeResponseAuthentication no
 
 # Kerberos options
@@ -111,7 +97,7 @@
 Compression no
 ClientAliveInterval 15
 ClientAliveCountMax 4
-#UseDNS yes
+#UseDNS no
 #PidFile /var/run/sshd.pid
 #MaxStartups 10:30:100
 #PermitTunnel no
diff --git a/poky/meta/recipes-connectivity/openssh/openssh_7.6p1.bb b/poky/meta/recipes-connectivity/openssh/openssh_7.6p1.bb
deleted file mode 100644
index e11e8d7..0000000
--- a/poky/meta/recipes-connectivity/openssh/openssh_7.6p1.bb
+++ /dev/null
@@ -1,167 +0,0 @@
-SUMMARY = "A suite of security-related network utilities based on \
-the SSH protocol including the ssh client and sshd server"
-DESCRIPTION = "Secure rlogin/rsh/rcp/telnet replacement (OpenSSH) \
-Ssh (Secure Shell) is a program for logging into a remote machine \
-and for executing commands on a remote machine."
-HOMEPAGE = "http://www.openssh.com/"
-SECTION = "console/network"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://LICENCE;md5=429658c6612f3a9b1293782366ab29d8"
-
-# openssl 1.1 patches are proposed at https://github.com/openssh/openssh-portable/pull/48
-DEPENDS = "zlib openssl10"
-DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)}"
-
-SRC_URI = "http://ftp.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-${PV}.tar.gz \
-           file://sshd_config \
-           file://ssh_config \
-           file://init \
-           ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${PAM_SRC_URI}', '', d)} \
-           file://sshd.socket \
-           file://sshd@.service \
-           file://sshdgenkeys.service \
-           file://volatiles.99_sshd \
-           file://run-ptest \
-           file://fix-potential-signed-overflow-in-pointer-arithmatic.patch \
-           file://sshd_check_keys \
-           file://add-test-support-for-busybox.patch \
-           file://disable-ciphers-not-supported-by-OpenSSL-DES.patch \
-           "
-
-PAM_SRC_URI = "file://sshd"
-
-SRC_URI[md5sum] = "06a88699018e5fef13d4655abfed1f63"
-SRC_URI[sha256sum] = "a323caeeddfe145baaa0db16e98d784b1fbc7dd436a6bf1f479dfd5cd1d21723"
-
-inherit useradd update-rc.d update-alternatives systemd
-
-USERADD_PACKAGES = "${PN}-sshd"
-USERADD_PARAM_${PN}-sshd = "--system --no-create-home --home-dir /var/run/sshd --shell /bin/false --user-group sshd"
-INITSCRIPT_PACKAGES = "${PN}-sshd"
-INITSCRIPT_NAME_${PN}-sshd = "sshd"
-INITSCRIPT_PARAMS_${PN}-sshd = "defaults 9"
-
-SYSTEMD_PACKAGES = "${PN}-sshd"
-SYSTEMD_SERVICE_${PN}-sshd = "sshd.socket"
-
-inherit autotools-brokensep ptest
-
-# LFS support:
-CFLAGS += "-D__FILE_OFFSET_BITS=64"
-
-EXTRA_AUTORECONF += "--exclude=aclocal"
-
-# login path is hardcoded in sshd
-EXTRA_OECONF = "'LOGIN_PROGRAM=${base_bindir}/login' \
-                ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '--with-pam', '--without-pam', d)} \
-                --without-zlib-version-check \
-                --with-privsep-path=/var/run/sshd \
-                --sysconfdir=${sysconfdir}/ssh \
-                --with-xauth=/usr/bin/xauth \
-                --disable-strip \
-                "
-
-# musl doesn't implement wtmp/utmp
-EXTRA_OECONF_append_libc-musl = " --disable-wtmp"
-
-# Since we do not depend on libbsd, we do not want configure to use it
-# just because it finds libutil.h.  But, specifying --disable-libutil
-# causes compile errors, so...
-CACHED_CONFIGUREVARS += "ac_cv_header_bsd_libutil_h=no ac_cv_header_libutil_h=no"
-
-# passwd path is hardcoded in sshd
-CACHED_CONFIGUREVARS += "ac_cv_path_PATH_PASSWD_PROG=${bindir}/passwd"
-
-# We don't want to depend on libblockfile
-CACHED_CONFIGUREVARS += "ac_cv_header_maillock_h=no"
-
-do_configure_prepend () {
-	export LD="${CC}"
-	install -m 0644 ${WORKDIR}/sshd_config ${B}/
-	install -m 0644 ${WORKDIR}/ssh_config ${B}/
-}
-
-do_compile_ptest() {
-        # skip regress/unittests/ binaries: this will silently skip
-        # unittests in run-ptests which is good because they are so slow.
-        oe_runmake regress/modpipe regress/setuid-allowed regress/netcat
-}
-
-do_install_append () {
-	if [ "${@bb.utils.filter('DISTRO_FEATURES', 'pam', d)}" ]; then
-		install -D -m 0644 ${WORKDIR}/sshd ${D}${sysconfdir}/pam.d/sshd
-		sed -i -e 's:#UsePAM no:UsePAM yes:' ${D}${sysconfdir}/ssh/sshd_config
-	fi
-
-	if [ "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}" ]; then
-		sed -i -e 's:#X11Forwarding no:X11Forwarding yes:' ${D}${sysconfdir}/ssh/sshd_config
-	fi
-
-	install -d ${D}${sysconfdir}/init.d
-	install -m 0755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/sshd
-	rm -f ${D}${bindir}/slogin ${D}${datadir}/Ssh.bin
-	rmdir ${D}${localstatedir}/run/sshd ${D}${localstatedir}/run ${D}${localstatedir}
-	install -d ${D}/${sysconfdir}/default/volatiles
-	install -m 644 ${WORKDIR}/volatiles.99_sshd ${D}/${sysconfdir}/default/volatiles/99_sshd
-	install -m 0755 ${S}/contrib/ssh-copy-id ${D}${bindir}
-
-	# Create config files for read-only rootfs
-	install -d ${D}${sysconfdir}/ssh
-	install -m 644 ${D}${sysconfdir}/ssh/sshd_config ${D}${sysconfdir}/ssh/sshd_config_readonly
-	sed -i '/HostKey/d' ${D}${sysconfdir}/ssh/sshd_config_readonly
-	echo "HostKey /var/run/ssh/ssh_host_rsa_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly
-	echo "HostKey /var/run/ssh/ssh_host_dsa_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly
-	echo "HostKey /var/run/ssh/ssh_host_ecdsa_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly
-	echo "HostKey /var/run/ssh/ssh_host_ed25519_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly
-
-	install -d ${D}${systemd_unitdir}/system
-	install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_unitdir}/system
-	install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_unitdir}/system
-	install -c -m 0644 ${WORKDIR}/sshdgenkeys.service ${D}${systemd_unitdir}/system
-	sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
-		-e 's,@SBINDIR@,${sbindir},g' \
-		-e 's,@BINDIR@,${bindir},g' \
-		-e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \
-		${D}${systemd_unitdir}/system/sshd.socket ${D}${systemd_unitdir}/system/*.service
-
-	sed -i -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \
-		${D}${sysconfdir}/init.d/sshd
-
-	install -D -m 0755 ${WORKDIR}/sshd_check_keys ${D}${libexecdir}/${BPN}/sshd_check_keys
-}
-
-do_install_ptest () {
-	sed -i -e "s|^SFTPSERVER=.*|SFTPSERVER=${libexecdir}/sftp-server|" regress/test-exec.sh
-	cp -r regress ${D}${PTEST_PATH}
-}
-
-ALLOW_EMPTY_${PN} = "1"
-
-PACKAGES =+ "${PN}-keygen ${PN}-scp ${PN}-ssh ${PN}-sshd ${PN}-sftp ${PN}-misc ${PN}-sftp-server"
-FILES_${PN}-scp = "${bindir}/scp.${BPN}"
-FILES_${PN}-ssh = "${bindir}/ssh.${BPN} ${sysconfdir}/ssh/ssh_config"
-FILES_${PN}-sshd = "${sbindir}/sshd ${sysconfdir}/init.d/sshd ${systemd_unitdir}/system"
-FILES_${PN}-sshd += "${sysconfdir}/ssh/moduli ${sysconfdir}/ssh/sshd_config ${sysconfdir}/ssh/sshd_config_readonly ${sysconfdir}/default/volatiles/99_sshd ${sysconfdir}/pam.d/sshd"
-FILES_${PN}-sshd += "${libexecdir}/${BPN}/sshd_check_keys"
-FILES_${PN}-sftp = "${bindir}/sftp"
-FILES_${PN}-sftp-server = "${libexecdir}/sftp-server"
-FILES_${PN}-misc = "${bindir}/ssh* ${libexecdir}/ssh*"
-FILES_${PN}-keygen = "${bindir}/ssh-keygen"
-
-RDEPENDS_${PN} += "${PN}-scp ${PN}-ssh ${PN}-sshd ${PN}-keygen"
-RDEPENDS_${PN}-sshd += "${PN}-keygen ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'pam-plugin-keyinit pam-plugin-loginuid', '', d)}"
-RDEPENDS_${PN}-ptest += "${PN}-sftp ${PN}-misc ${PN}-sftp-server make"
-
-RPROVIDES_${PN}-ssh = "ssh"
-RPROVIDES_${PN}-sshd = "sshd"
-
-RCONFLICTS_${PN} = "dropbear"
-RCONFLICTS_${PN}-sshd = "dropbear"
-RCONFLICTS_${PN}-keygen = "ssh-keygen"
-
-CONFFILES_${PN}-sshd = "${sysconfdir}/ssh/sshd_config"
-CONFFILES_${PN}-ssh = "${sysconfdir}/ssh/ssh_config"
-
-ALTERNATIVE_PRIORITY = "90"
-ALTERNATIVE_${PN}-scp = "scp"
-ALTERNATIVE_${PN}-ssh = "ssh"
diff --git a/poky/meta/recipes-connectivity/openssh/openssh_7.8p1+git.bb b/poky/meta/recipes-connectivity/openssh/openssh_7.8p1+git.bb
new file mode 100644
index 0000000..f54dfb5
--- /dev/null
+++ b/poky/meta/recipes-connectivity/openssh/openssh_7.8p1+git.bb
@@ -0,0 +1,164 @@
+SUMMARY = "A suite of security-related network utilities based on \
+the SSH protocol including the ssh client and sshd server"
+DESCRIPTION = "Secure rlogin/rsh/rcp/telnet replacement (OpenSSH) \
+Ssh (Secure Shell) is a program for logging into a remote machine \
+and for executing commands on a remote machine."
+HOMEPAGE = "http://www.openssh.com/"
+SECTION = "console/network"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://LICENCE;md5=429658c6612f3a9b1293782366ab29d8"
+
+DEPENDS = "zlib openssl"
+DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)}"
+
+SRC_URI = "git://github.com/openssh/openssh-portable;branch=master \
+           file://sshd_config \
+           file://ssh_config \
+           file://init \
+           ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${PAM_SRC_URI}', '', d)} \
+           file://sshd.socket \
+           file://sshd@.service \
+           file://sshdgenkeys.service \
+           file://volatiles.99_sshd \
+           file://run-ptest \
+           file://fix-potential-signed-overflow-in-pointer-arithmatic.patch \
+           file://sshd_check_keys \
+           file://add-test-support-for-busybox.patch \
+           "
+
+PAM_SRC_URI = "file://sshd"
+
+SRCREV = "cce8cbe0ed7d1ba3a575310e0b63c193326ae616"
+
+S = "${WORKDIR}/git"
+
+inherit useradd update-rc.d update-alternatives systemd
+
+USERADD_PACKAGES = "${PN}-sshd"
+USERADD_PARAM_${PN}-sshd = "--system --no-create-home --home-dir /var/run/sshd --shell /bin/false --user-group sshd"
+INITSCRIPT_PACKAGES = "${PN}-sshd"
+INITSCRIPT_NAME_${PN}-sshd = "sshd"
+INITSCRIPT_PARAMS_${PN}-sshd = "defaults 9"
+
+SYSTEMD_PACKAGES = "${PN}-sshd"
+SYSTEMD_SERVICE_${PN}-sshd = "sshd.socket"
+
+inherit autotools-brokensep ptest
+
+EXTRA_AUTORECONF += "--exclude=aclocal"
+
+# login path is hardcoded in sshd
+EXTRA_OECONF = "'LOGIN_PROGRAM=${base_bindir}/login' \
+                ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '--with-pam', '--without-pam', d)} \
+                --without-zlib-version-check \
+                --with-privsep-path=${localstatedir}/run/sshd \
+                --sysconfdir=${sysconfdir}/ssh \
+                --with-xauth=${bindir}/xauth \
+                --disable-strip \
+                "
+
+# musl doesn't implement wtmp/utmp
+EXTRA_OECONF_append_libc-musl = " --disable-wtmp"
+
+# Since we do not depend on libbsd, we do not want configure to use it
+# just because it finds libutil.h.  But, specifying --disable-libutil
+# causes compile errors, so...
+CACHED_CONFIGUREVARS += "ac_cv_header_bsd_libutil_h=no ac_cv_header_libutil_h=no"
+
+# passwd path is hardcoded in sshd
+CACHED_CONFIGUREVARS += "ac_cv_path_PATH_PASSWD_PROG=${bindir}/passwd"
+
+# We don't want to depend on libblockfile
+CACHED_CONFIGUREVARS += "ac_cv_header_maillock_h=no"
+
+do_configure_prepend () {
+	export LD="${CC}"
+	install -m 0644 ${WORKDIR}/sshd_config ${B}/
+	install -m 0644 ${WORKDIR}/ssh_config ${B}/
+}
+
+do_compile_ptest() {
+        # skip regress/unittests/ binaries: this will silently skip
+        # unittests in run-ptests which is good because they are so slow.
+        oe_runmake regress/modpipe regress/setuid-allowed regress/netcat \
+                   regress/check-perm regress/mkdtemp
+}
+
+do_install_append () {
+	if [ "${@bb.utils.filter('DISTRO_FEATURES', 'pam', d)}" ]; then
+		install -D -m 0644 ${WORKDIR}/sshd ${D}${sysconfdir}/pam.d/sshd
+		sed -i -e 's:#UsePAM no:UsePAM yes:' ${D}${sysconfdir}/ssh/sshd_config
+	fi
+
+	if [ "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}" ]; then
+		sed -i -e 's:#X11Forwarding no:X11Forwarding yes:' ${D}${sysconfdir}/ssh/sshd_config
+	fi
+
+	install -d ${D}${sysconfdir}/init.d
+	install -m 0755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/sshd
+	rm -f ${D}${bindir}/slogin ${D}${datadir}/Ssh.bin
+	rmdir ${D}${localstatedir}/run/sshd ${D}${localstatedir}/run ${D}${localstatedir}
+	install -d ${D}/${sysconfdir}/default/volatiles
+	install -m 644 ${WORKDIR}/volatiles.99_sshd ${D}/${sysconfdir}/default/volatiles/99_sshd
+	install -m 0755 ${S}/contrib/ssh-copy-id ${D}${bindir}
+
+	# Create config files for read-only rootfs
+	install -d ${D}${sysconfdir}/ssh
+	install -m 644 ${D}${sysconfdir}/ssh/sshd_config ${D}${sysconfdir}/ssh/sshd_config_readonly
+	sed -i '/HostKey/d' ${D}${sysconfdir}/ssh/sshd_config_readonly
+	echo "HostKey /var/run/ssh/ssh_host_rsa_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly
+	echo "HostKey /var/run/ssh/ssh_host_ecdsa_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly
+	echo "HostKey /var/run/ssh/ssh_host_ed25519_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly
+
+	install -d ${D}${systemd_unitdir}/system
+	install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_unitdir}/system
+	install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_unitdir}/system
+	install -c -m 0644 ${WORKDIR}/sshdgenkeys.service ${D}${systemd_unitdir}/system
+	sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
+		-e 's,@SBINDIR@,${sbindir},g' \
+		-e 's,@BINDIR@,${bindir},g' \
+		-e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \
+		${D}${systemd_unitdir}/system/sshd.socket ${D}${systemd_unitdir}/system/*.service
+
+	sed -i -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \
+		${D}${sysconfdir}/init.d/sshd
+
+	install -D -m 0755 ${WORKDIR}/sshd_check_keys ${D}${libexecdir}/${BPN}/sshd_check_keys
+}
+
+do_install_ptest () {
+	sed -i -e "s|^SFTPSERVER=.*|SFTPSERVER=${libexecdir}/sftp-server|" regress/test-exec.sh
+	cp -r regress ${D}${PTEST_PATH}
+}
+
+ALLOW_EMPTY_${PN} = "1"
+
+PACKAGES =+ "${PN}-keygen ${PN}-scp ${PN}-ssh ${PN}-sshd ${PN}-sftp ${PN}-misc ${PN}-sftp-server"
+FILES_${PN}-scp = "${bindir}/scp.${BPN}"
+FILES_${PN}-ssh = "${bindir}/ssh.${BPN} ${sysconfdir}/ssh/ssh_config"
+FILES_${PN}-sshd = "${sbindir}/sshd ${sysconfdir}/init.d/sshd ${systemd_unitdir}/system"
+FILES_${PN}-sshd += "${sysconfdir}/ssh/moduli ${sysconfdir}/ssh/sshd_config ${sysconfdir}/ssh/sshd_config_readonly ${sysconfdir}/default/volatiles/99_sshd ${sysconfdir}/pam.d/sshd"
+FILES_${PN}-sshd += "${libexecdir}/${BPN}/sshd_check_keys"
+FILES_${PN}-sftp = "${bindir}/sftp"
+FILES_${PN}-sftp-server = "${libexecdir}/sftp-server"
+FILES_${PN}-misc = "${bindir}/ssh* ${libexecdir}/ssh*"
+FILES_${PN}-keygen = "${bindir}/ssh-keygen"
+
+RDEPENDS_${PN} += "${PN}-scp ${PN}-ssh ${PN}-sshd ${PN}-keygen"
+RDEPENDS_${PN}-sshd += "${PN}-keygen ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'pam-plugin-keyinit pam-plugin-loginuid', '', d)}"
+RDEPENDS_${PN}-ptest += "${PN}-sftp ${PN}-misc ${PN}-sftp-server make"
+
+RPROVIDES_${PN}-ssh = "ssh"
+RPROVIDES_${PN}-sshd = "sshd"
+
+RCONFLICTS_${PN} = "dropbear"
+RCONFLICTS_${PN}-sshd = "dropbear"
+
+CONFFILES_${PN}-sshd = "${sysconfdir}/ssh/sshd_config"
+CONFFILES_${PN}-ssh = "${sysconfdir}/ssh/ssh_config"
+
+ALTERNATIVE_PRIORITY = "90"
+ALTERNATIVE_${PN}-scp = "scp"
+ALTERNATIVE_${PN}-ssh = "ssh"
+
+BBCLASSEXTEND += "nativesdk"
diff --git a/poky/meta/recipes-connectivity/openssl/openssl/environment.d-openssl.sh b/poky/meta/recipes-connectivity/openssl/files/environment.d-openssl.sh
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl/environment.d-openssl.sh
rename to poky/meta/recipes-connectivity/openssl/files/environment.d-openssl.sh
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian/debian-targets.patch b/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian/debian-targets.patch
deleted file mode 100644
index 35d92be..0000000
--- a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian/debian-targets.patch
+++ /dev/null
@@ -1,73 +0,0 @@
-Upstream-Status: Backport [debian]
-
-Index: openssl-1.0.2n/Configure
-===================================================================
---- openssl-1.0.2n.orig/Configure
-+++ openssl-1.0.2n/Configure
-@@ -133,6 +133,10 @@ my $clang_devteam_warn = "-Wno-unused-pa
- # Warn that "make depend" should be run?
- my $warn_make_depend = 0;
- 
-+# There are no separate CFLAGS/CPPFLAGS/LDFLAGS, set everything in CFLAGS
-+my $debian_cflags = `dpkg-buildflags --get CFLAGS` . `dpkg-buildflags --get CPPFLAGS` . `dpkg-buildflags --get LDFLAGS` . "-Wa,--noexecstack -Wall";
-+$debian_cflags =~ s/\n/ /g;
-+
- my $strict_warnings = 0;
- 
- my $x86_gcc_des="DES_PTR DES_RISC1 DES_UNROLL";
-@@ -369,6 +373,55 @@ my %table=(
- "osf1-alpha-cc",  "cc:-std1 -tune host -O4 -readonly_strings::(unknown):::SIXTY_FOUR_BIT_LONG RC4_CHUNK:${alpha_asm}:dlfcn:alpha-osf1-shared:::.so",
- "tru64-alpha-cc", "cc:-std1 -tune host -fast -readonly_strings::-pthread:::SIXTY_FOUR_BIT_LONG RC4_CHUNK:${alpha_asm}:dlfcn:alpha-osf1-shared::-msym:.so",
- 
-+# Debian GNU/* (various architectures)
-+"debian-alpha","gcc:-DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_RISC1 DES_UNROLL:${alpha_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-alpha-ev4","gcc:-DTERMIO ${debian_cflags} -mcpu=ev4::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_RISC1 DES_UNROLL:${alpha_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-alpha-ev5","gcc:-DTERMIO ${debian_cflags} -mcpu=ev5::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_RISC1 DES_UNROLL:${alpha_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-arm64","gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL BF_PTR:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-armel","gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL BF_PTR:${armv4_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-armhf","gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL BF_PTR:${armv4_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-amd64", "gcc:-m64 -DL_ENDIAN -DTERMIO ${debian_cflags} -DMD32_REG_T=int::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::",
-+"debian-avr32", "gcc:-DB_ENDIAN -DTERMIO ${debian_cflags} -fomit-frame-pointer::-D_REENTRANT::-ldl:BN_LLONG_BF_PTR:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-kfreebsd-amd64","gcc:-m64 -DL_ENDIAN -DTERMIOS ${debian_cflags} -DMD32_REG_T=int::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-kfreebsd-i386","gcc:-DL_ENDIAN -DTERMIOS ${debian_cflags} -march=i486::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-hppa","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG MD2_CHAR RC4_INDEX:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-hurd-i386","gcc:-DL_ENDIAN -DTERMIOS -O3 -Wa,--noexecstack -g -mtune=i486 -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-ia64","gcc:-DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_UNROLL DES_INT:${ia64_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-i386","gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-i386-i486","gcc:-DL_ENDIAN -DTERMIO ${debian_cflags} -march=i486::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-i386-i586","gcc:-DL_ENDIAN -DTERMIO ${debian_cflags} -march=i586::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-i386-i686/cmov","gcc:-DL_ENDIAN -DTERMIO ${debian_cflags} -march=i686::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-m68k","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG MD2_CHAR RC4_INDEX:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-mips",   "gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-mipsel",   "gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-mipsn32",   "mips64-linux-gnuabin32-gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-mipsn32el",   "mips64el-linux-gnuabin32-gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-mips64",   "mips64-linux-gnuabi64-gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-mips64el",   "mips64el-linux-gnuabi64-gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-netbsd-i386",	"gcc:-DL_ENDIAN -DTERMIOS ${debian_cflags} -m486::(unknown):::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${no_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-netbsd-m68k",	"gcc:-DB_ENDIAN -DTERMIOS ${debian_cflags}::(unknown):::BN_LLONG MD2_CHAR RC4_INDEX DES_UNROLL:${no_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-netbsd-sparc",	"gcc:-DB_ENDIAN -DTERMIOS ${debian_cflags} -mv8::(unknown):::BN_LLONG MD2_CHAR RC4_INDEX DES_UNROLL:${no_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-openbsd-alpha","gcc:-DTERMIOS ${debian_cflags}::(unknown):::SIXTY_FOUR_BIT_LONG DES_INT DES_PTR DES_RISC2:${no_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-openbsd-i386",  "gcc:-DL_ENDIAN -DTERMIOS ${debian_cflags} -m486::(unknown):::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_asm}:a.out:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-openbsd-mips","gcc:-DL_ENDIAN ${debian_cflags}::(unknown)::BN_LLONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC2 DES_PTR BF_PTR:${no_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-or1k", "gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG DES_RISC1:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-powerpc","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_RISC1 DES_UNROLL:${ppc32_asm}:linux32:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-powerpcspe","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_RISC1 DES_UNROLL:${ppc32_asm}:linux32:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-ppc64","gcc:-m64 -DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_RISC1 DES_UNROLL:${ppc64_asm}:linux64:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-ppc64el","gcc:-m64 -DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_RISC1 DES_UNROLL:${ppc64_asm}:linux64le:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-s390","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)", 
-+"debian-s390x","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-sh3",   "gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-sh4",   "gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-sh3eb",   "gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-sh4eb",   "gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-m32r","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-sparc","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${sparcv9_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-sparc-v8","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags} -mcpu=v8 -DBN_DIV2W::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${sparcv8_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-sparc-v9","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags} -mcpu=v9 -Wa,-Av8plus -DULTRASPARC -DBN_DIV2W::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${sparcv9_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-sparc64","gcc:-m64 -DB_ENDIAN -DTERMIO ${debian_cflags} -DULTRASPARC -DBN_DIV2W::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_INT DES_PTR DES_RISC1 DES_UNROLL BF_PTR:${sparcv9_asm}:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
-+"debian-x32","gcc:-mx32 -DL_ENDIAN -DTERMIO ${debian_cflags} -DMD32_REG_T=int::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:linux-shared:-fPIC:-mx32:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::x32",
-+
- ####
- #### Variety of LINUX:-)
- ####
diff --git a/poky/meta/recipes-connectivity/openssl/openssl/0001-Take-linking-flags-from-LDFLAGS-env-var.patch b/poky/meta/recipes-connectivity/openssl/openssl/0001-Take-linking-flags-from-LDFLAGS-env-var.patch
deleted file mode 100644
index 6ce4e47..0000000
--- a/poky/meta/recipes-connectivity/openssl/openssl/0001-Take-linking-flags-from-LDFLAGS-env-var.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 08face4353d80111973aba9c1304c92158cfad0e Mon Sep 17 00:00:00 2001
-From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Tue, 28 Mar 2017 16:40:12 +0300
-Subject: [PATCH] Take linking flags from LDFLAGS env var
-
-This fixes "No GNU_HASH in the elf binary" issues.
-
-Upstream-Status: Inappropriate [oe-core specific]
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
----
- Configurations/unix-Makefile.tmpl | 2 +-
- Configure                         | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/Configurations/unix-Makefile.tmpl b/Configurations/unix-Makefile.tmpl
-index c029817..43b769b 100644
---- a/Configurations/unix-Makefile.tmpl
-+++ b/Configurations/unix-Makefile.tmpl
-@@ -173,7 +173,7 @@ CROSS_COMPILE= {- $config{cross_compile_prefix} -}
- CC= $(CROSS_COMPILE){- $target{cc} -}
- CFLAGS={- our $cflags2 = join(" ",(map { "-D".$_} @{$target{defines}}, @{$config{defines}}),"-DOPENSSLDIR=\"\\\"\$(OPENSSLDIR)\\\"\"","-DENGINESDIR=\"\\\"\$(ENGINESDIR)\\\"\"") -} {- $target{cflags} -} {- $config{cflags} -}
- CFLAGS_Q={- $cflags2 =~ s|([\\"])|\\$1|g; $cflags2 -} {- $config{cflags} -}
--LDFLAGS= {- $target{lflags} -}
-+LDFLAGS= {- $target{lflags}." ".$ENV{'LDFLAGS'} -}
- PLIB_LDFLAGS= {- $target{plib_lflags} -}
- EX_LIBS= {- $target{ex_libs} -} {- $config{ex_libs} -}
- LIB_CFLAGS={- $target{shared_cflag} || "" -}
-diff --git a/Configure b/Configure
-index aee7cc3..274d236 100755
---- a/Configure
-+++ b/Configure
-@@ -979,7 +979,7 @@ $config{build_file} = $target{build_file};
- $config{defines} = [];
- $config{cflags} = "";
- $config{ex_libs} = "";
--$config{shared_ldflag} = "";
-+$config{shared_ldflag} = $ENV{'LDFLAGS'};
- 
- # Make sure build_scheme is consistent.
- $target{build_scheme} = [ $target{build_scheme} ]
--- 
-2.11.0
-
diff --git a/poky/meta/recipes-connectivity/openssl/openssl/0001-buildinfo-strip-sysroot-and-debug-prefix-map-from-co.patch b/poky/meta/recipes-connectivity/openssl/openssl/0001-buildinfo-strip-sysroot-and-debug-prefix-map-from-co.patch
new file mode 100644
index 0000000..80b62ab
--- /dev/null
+++ b/poky/meta/recipes-connectivity/openssl/openssl/0001-buildinfo-strip-sysroot-and-debug-prefix-map-from-co.patch
@@ -0,0 +1,70 @@
+From 3e1d00481093e10775eaf69d619c45b32a4aa7dc Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Martin=20Hundeb=C3=B8ll?= <martin@geanix.com>
+Date: Tue, 6 Nov 2018 14:50:47 +0100
+Subject: [PATCH] buildinfo: strip sysroot and debug-prefix-map from compiler
+ info
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+The openssl build system generates buildinf.h containing the full
+compiler command line used to compile objects. This breaks
+reproducibility, as the compile command is baked into libcrypto, where
+it is used when running `openssl version -f`.
+
+Add stripped build variables for the compiler and cflags lines, and use
+those when generating buildinfo.h.
+
+This is based on a similar patch for older openssl versions:
+https://patchwork.openembedded.org/patch/147229/
+
+Upstream-Status: Inappropriate [OE specific]
+Signed-off-by: Martin Hundebøll <martin@geanix.com>
+---
+ Configurations/unix-Makefile.tmpl | 10 +++++++++-
+ crypto/build.info                 |  2 +-
+ 2 files changed, 10 insertions(+), 2 deletions(-)
+
+diff --git a/Configurations/unix-Makefile.tmpl b/Configurations/unix-Makefile.tmpl
+index 16af4d2087..54c162784c 100644
+--- a/Configurations/unix-Makefile.tmpl
++++ b/Configurations/unix-Makefile.tmpl
+@@ -317,13 +317,21 @@ BIN_LDFLAGS={- join(' ', $target{bin_lflags} || (),
+                          '$(CNF_LDFLAGS)', '$(LDFLAGS)') -}
+ BIN_EX_LIBS=$(CNF_EX_LIBS) $(EX_LIBS)
+ 
+-# CPPFLAGS_Q is used for one thing only: to build up buildinf.h
++# *_Q variables are used for one thing only: to build up buildinf.h
+ CPPFLAGS_Q={- $cppflags1 =~ s|([\\"])|\\$1|g;
+               $cppflags2 =~ s|([\\"])|\\$1|g;
+               $lib_cppflags =~ s|([\\"])|\\$1|g;
+               join(' ', $lib_cppflags || (), $cppflags2 || (),
+                         $cppflags1 || ()) -}
+ 
++CFLAGS_Q={- for (@{$config{CFLAGS}}) {
++              s|-fdebug-prefix-map=[^ ]+|-fdebug-prefix-map=|g;
++            }
++            join(' ', @{$config{CFLAGS}}) -}
++
++CC_Q={- $config{CC} =~ s|--sysroot=[^ ]+|--sysroot=recipe-sysroot|g;
++        join(' ', $config{CC}) -}
++
+ PERLASM_SCHEME= {- $target{perlasm_scheme} -}
+ 
+ # For x86 assembler: Set PROCESSOR to 386 if you want to support
+diff --git a/crypto/build.info b/crypto/build.info
+index b515b7318e..8c9cee2a09 100644
+--- a/crypto/build.info
++++ b/crypto/build.info
+@@ -10,7 +10,7 @@ EXTRA=  ../ms/uplink-x86.pl ../ms/uplink.c ../ms/applink.c \
+         ppccpuid.pl pariscid.pl alphacpuid.pl arm64cpuid.pl armv4cpuid.pl
+ 
+ DEPEND[cversion.o]=buildinf.h
+-GENERATE[buildinf.h]=../util/mkbuildinf.pl "$(CC) $(LIB_CFLAGS) $(CPPFLAGS_Q)" "$(PLATFORM)"
++GENERATE[buildinf.h]=../util/mkbuildinf.pl "$(CC_Q) $(CFLAGS_Q) $(CPPFLAGS_Q)" "$(PLATFORM)"
+ DEPEND[buildinf.h]=../configdata.pm
+ 
+ GENERATE[uplink-x86.s]=../ms/uplink-x86.pl $(PERLASM_SCHEME)
+-- 
+2.19.1
+
diff --git a/poky/meta/recipes-connectivity/openssl/openssl/0001-skip-test_symbol_presence.patch b/poky/meta/recipes-connectivity/openssl/openssl/0001-skip-test_symbol_presence.patch
new file mode 100644
index 0000000..d8d9651
--- /dev/null
+++ b/poky/meta/recipes-connectivity/openssl/openssl/0001-skip-test_symbol_presence.patch
@@ -0,0 +1,46 @@
+From a9401b2289656c5a36dd1b0ecebf0d23e291ce70 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Tue, 2 Oct 2018 23:58:24 +0800
+Subject: [PATCH] skip test_symbol_presence
+
+We cannot skip `01-test_symbol_presence.t' by configuring option `no-shared'
+as INSTALL told us the shared libraries will not be built.
+
+[INSTALL snip]
+ Notes on shared libraries
+ -------------------------
+
+ For most systems the OpenSSL Configure script knows what is needed to
+ build shared libraries for libcrypto and libssl. On these systems
+ the shared libraries will be created by default. This can be suppressed and
+ only static libraries created by using the "no-shared" option. On systems
+ where OpenSSL does not know how to build shared libraries the "no-shared"
+ option will be forced and only static libraries will be created.
+[INSTALL snip]
+
+Hence directly modification the case to skip it.
+
+Upstream-Status: Inappropriate [OE Specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ test/recipes/01-test_symbol_presence.t | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+diff --git a/test/recipes/01-test_symbol_presence.t b/test/recipes/01-test_symbol_presence.t
+index 7f2a2d7..0b93745 100644
+--- a/test/recipes/01-test_symbol_presence.t
++++ b/test/recipes/01-test_symbol_presence.t
+@@ -14,8 +14,7 @@ use OpenSSL::Test::Utils;
+ 
+ setup("test_symbol_presence");
+ 
+-plan skip_all => "Only useful when building shared libraries"
+-    if disabled("shared");
++plan skip_all => "The case needs debug symbols then we just disable it";
+ 
+ my @libnames = ("crypto", "ssl");
+ my $testcount = scalar @libnames;
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-connectivity/openssl/openssl/0002-fix-CVE-2018-0734.patch b/poky/meta/recipes-connectivity/openssl/openssl/0002-fix-CVE-2018-0734.patch
new file mode 100644
index 0000000..2a3e03f
--- /dev/null
+++ b/poky/meta/recipes-connectivity/openssl/openssl/0002-fix-CVE-2018-0734.patch
@@ -0,0 +1,108 @@
+Backport patch to fix CVE-2018-0734. Remove a section which only remove a
+space. It can't be applied because the context is different.
+
+CVE: CVE-2018-0734
+Upstream-Status: Backport
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+
+From 8abfe72e8c1de1b95f50aa0d9134803b4d00070f Mon Sep 17 00:00:00 2001
+From: Pauli <paul.dale@oracle.com>
+Date: Wed, 24 Oct 2018 07:42:46 +1000
+Subject: [PATCH] Timing vulnerability in DSA signature generation
+ (CVE-2018-0734).
+
+Avoid a timing attack that leaks information via a side channel that
+triggers when a BN is resized.  Increasing the size of the BNs
+prior to doing anything with them suppresses the attack.
+
+Thanks due to Samuel Weiser for finding and locating this.
+
+Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de>
+(Merged from https://github.com/openssl/openssl/pull/7486)
+
+(cherry picked from commit a9cfb8c2aa7254a4aa6a1716909e3f8cb78049b6)
+---
+ crypto/dsa/dsa_ossl.c | 28 +++++++++++++++-------------
+ 1 file changed, 15 insertions(+), 13 deletions(-)
+
+diff --git a/crypto/dsa/dsa_ossl.c b/crypto/dsa/dsa_ossl.c
+index ca20811200..2dd2d7489a 100644
+--- a/crypto/dsa/dsa_ossl.c
++++ b/crypto/dsa/dsa_ossl.c
+@@ -9,6 +9,7 @@
+ 
+ #include <stdio.h>
+ #include "internal/cryptlib.h"
++#include "internal/bn_int.h"
+ #include <openssl/bn.h>
+ #include <openssl/sha.h>
+ #include "dsa_locl.h"
+@@ -180,9 +181,9 @@ static int dsa_sign_setup(DSA *dsa, BN_CTX *ctx_in,
+ {
+     BN_CTX *ctx = NULL;
+     BIGNUM *k, *kinv = NULL, *r = *rp;
+-    BIGNUM *l, *m;
++    BIGNUM *l;
+     int ret = 0;
+-    int q_bits;
++    int q_bits, q_words;
+ 
+     if (!dsa->p || !dsa->q || !dsa->g) {
+         DSAerr(DSA_F_DSA_SIGN_SETUP, DSA_R_MISSING_PARAMETERS);
+@@ -191,8 +192,7 @@ static int dsa_sign_setup(DSA *dsa, BN_CTX *ctx_in,
+ 
+     k = BN_new();
+     l = BN_new();
+-    m = BN_new();
+-    if (k == NULL || l == NULL || m == NULL)
++    if (k == NULL || l == NULL)
+         goto err;
+ 
+     if (ctx_in == NULL) {
+@@ -203,9 +203,9 @@ static int dsa_sign_setup(DSA *dsa, BN_CTX *ctx_in,
+ 
+     /* Preallocate space */
+     q_bits = BN_num_bits(dsa->q);
+-    if (!BN_set_bit(k, q_bits)
+-        || !BN_set_bit(l, q_bits)
+-        || !BN_set_bit(m, q_bits))
++    q_words = bn_get_top(dsa->q);
++    if (!bn_wexpand(k, q_words + 2)
++        || !bn_wexpand(l, q_words + 2))
+         goto err;
+ 
+     /* Get random k */
+@@ -240,14 +240,17 @@ static int dsa_sign_setup(DSA *dsa, BN_CTX *ctx_in,
+      * small timing information leakage.  We then choose the sum that is
+      * one bit longer than the modulus.
+      *
+-     * TODO: revisit the BN_copy aiming for a memory access agnostic
+-     * conditional copy.
++     * There are some concerns about the efficacy of doing this.  More
++     * specificly refer to the discussion starting with:
++     *     https://github.com/openssl/openssl/pull/7486#discussion_r228323705
++     * The fix is to rework BN so these gymnastics aren't required.
+      */
+     if (!BN_add(l, k, dsa->q)
+-        || !BN_add(m, l, dsa->q)
+-        || !BN_copy(k, BN_num_bits(l) > q_bits ? l : m))
++        || !BN_add(k, l, dsa->q))
+         goto err;
+ 
++    BN_consttime_swap(BN_is_bit_set(l, q_bits), k, l, q_words + 2);
++
+     if ((dsa)->meth->bn_mod_exp != NULL) {
+             if (!dsa->meth->bn_mod_exp(dsa, r, dsa->g, k, dsa->p, ctx,
+                                        dsa->method_mont_p))
+@@ -275,7 +278,6 @@ static int dsa_sign_setup(DSA *dsa, BN_CTX *ctx_in,
+         BN_CTX_free(ctx);
+     BN_clear_free(k);
+     BN_clear_free(l);
+-    BN_clear_free(m);
+     return ret;
+ }
+ 
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-connectivity/openssl/openssl/0003-fix-CVE-2018-0735.patch b/poky/meta/recipes-connectivity/openssl/openssl/0003-fix-CVE-2018-0735.patch
new file mode 100644
index 0000000..736323f
--- /dev/null
+++ b/poky/meta/recipes-connectivity/openssl/openssl/0003-fix-CVE-2018-0735.patch
@@ -0,0 +1,50 @@
+CVE: CVE-2018-0735
+
+Upstream-Status: Backport
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+
+From b1d6d55ece1c26fa2829e2b819b038d7b6d692b4 Mon Sep 17 00:00:00 2001
+From: Pauli <paul.dale@oracle.com>
+Date: Fri, 26 Oct 2018 10:54:58 +1000
+Subject: [PATCH] Timing vulnerability in ECDSA signature generation
+ (CVE-2018-0735)
+
+Preallocate an extra limb for some of the big numbers to avoid a reallocation
+that can potentially provide a side channel.
+
+Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de>
+(Merged from https://github.com/openssl/openssl/pull/7486)
+
+(cherry picked from commit 99540ec79491f59ed8b46b4edf130e17dc907f52)
+---
+ crypto/ec/ec_mult.c | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/crypto/ec/ec_mult.c b/crypto/ec/ec_mult.c
+index 7e1b3650e7..0e0a5e1394 100644
+--- a/crypto/ec/ec_mult.c
++++ b/crypto/ec/ec_mult.c
+@@ -206,8 +206,8 @@ int ec_scalar_mul_ladder(const EC_GROUP *group, EC_POINT *r,
+      */
+     cardinality_bits = BN_num_bits(cardinality);
+     group_top = bn_get_top(cardinality);
+-    if ((bn_wexpand(k, group_top + 1) == NULL)
+-        || (bn_wexpand(lambda, group_top + 1) == NULL)) {
++    if ((bn_wexpand(k, group_top + 2) == NULL)
++        || (bn_wexpand(lambda, group_top + 2) == NULL)) {
+         ECerr(EC_F_EC_SCALAR_MUL_LADDER, ERR_R_BN_LIB);
+         goto err;
+     }
+@@ -244,7 +244,7 @@ int ec_scalar_mul_ladder(const EC_GROUP *group, EC_POINT *r,
+      * k := scalar + 2*cardinality
+      */
+     kbit = BN_is_bit_set(lambda, cardinality_bits);
+-    BN_consttime_swap(kbit, k, lambda, group_top + 1);
++    BN_consttime_swap(kbit, k, lambda, group_top + 2);
+ 
+     group_top = bn_get_top(group->field);
+     if ((bn_wexpand(s->X, group_top) == NULL)
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-connectivity/openssl/openssl/run-ptest b/poky/meta/recipes-connectivity/openssl/openssl/run-ptest
index 65c6cc7..0a620de 100644
--- a/poky/meta/recipes-connectivity/openssl/openssl/run-ptest
+++ b/poky/meta/recipes-connectivity/openssl/openssl/run-ptest
@@ -1,4 +1,12 @@
 #!/bin/sh
-cd test
-OPENSSL_ENGINES=../engines BLDTOP=.. SRCTOP=.. perl run_tests.pl
-cd ..
+
+set -e
+
+# Optional arguments are 'list' to lists all tests, or the test name (base name
+# ie test_evp, not 03_test_evp.t).
+
+export TOP=.
+# OPENSSL_ENGINES is relative from the test binaries
+export OPENSSL_ENGINES=../engines
+
+perl ./test/run_tests.pl $*
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/0001-Fix-build-with-clang-using-external-assembler.patch b/poky/meta/recipes-connectivity/openssl/openssl10/0001-Fix-build-with-clang-using-external-assembler.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/0001-Fix-build-with-clang-using-external-assembler.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/0001-Fix-build-with-clang-using-external-assembler.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/0001-allow-manpages-to-be-disabled.patch b/poky/meta/recipes-connectivity/openssl/openssl10/0001-allow-manpages-to-be-disabled.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/0001-allow-manpages-to-be-disabled.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/0001-allow-manpages-to-be-disabled.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl10/0001-fix-CVE-2018-0734.patch b/poky/meta/recipes-connectivity/openssl/openssl10/0001-fix-CVE-2018-0734.patch
new file mode 100644
index 0000000..b9865a6
--- /dev/null
+++ b/poky/meta/recipes-connectivity/openssl/openssl10/0001-fix-CVE-2018-0734.patch
@@ -0,0 +1,33 @@
+CVE: CVE-2018-0734
+
+Upstream-Status: Backport
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+
+From 43e6a58d4991a451daf4891ff05a48735df871ac Mon Sep 17 00:00:00 2001
+From: Pauli <paul.dale@oracle.com>
+Date: Mon, 29 Oct 2018 08:24:22 +1000
+Subject: [PATCH] Merge DSA reallocation timing fix CVE-2018-0734.
+
+Reviewed-by: Richard Levitte <levitte@openssl.org>
+(Merged from https://github.com/openssl/openssl/pull/7513)
+---
+ crypto/dsa/dsa_ossl.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/crypto/dsa/dsa_ossl.c b/crypto/dsa/dsa_ossl.c
+index 2dcfedeeee..100e269268 100644
+--- a/crypto/dsa/dsa_ossl.c
++++ b/crypto/dsa/dsa_ossl.c
+@@ -279,7 +279,7 @@ static int dsa_sign_setup(DSA *dsa, BN_CTX *ctx_in, BIGNUM **kinvp,
+         goto err;
+ 
+     /* Preallocate space */
+-    q_bits = BN_num_bits(dsa->q);
++    q_bits = BN_num_bits(dsa->q) + sizeof(dsa->q->d[0]) * 16;
+     if (!BN_set_bit(&k, q_bits)
+         || !BN_set_bit(&l, q_bits)
+         || !BN_set_bit(&m, q_bits))
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/0001-openssl-force-soft-link-to-avoid-rare-race.patch b/poky/meta/recipes-connectivity/openssl/openssl10/0001-openssl-force-soft-link-to-avoid-rare-race.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/0001-openssl-force-soft-link-to-avoid-rare-race.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/0001-openssl-force-soft-link-to-avoid-rare-race.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/Makefiles-ptest.patch b/poky/meta/recipes-connectivity/openssl/openssl10/Makefiles-ptest.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/Makefiles-ptest.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/Makefiles-ptest.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/Use-SHA256-not-MD5-as-default-digest.patch b/poky/meta/recipes-connectivity/openssl/openssl10/Use-SHA256-not-MD5-as-default-digest.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/Use-SHA256-not-MD5-as-default-digest.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/Use-SHA256-not-MD5-as-default-digest.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/configure-musl-target.patch b/poky/meta/recipes-connectivity/openssl/openssl10/configure-musl-target.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/configure-musl-target.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/configure-musl-target.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/configure-targets.patch b/poky/meta/recipes-connectivity/openssl/openssl10/configure-targets.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/configure-targets.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/configure-targets.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian/c_rehash-compat.patch b/poky/meta/recipes-connectivity/openssl/openssl10/debian/c_rehash-compat.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian/c_rehash-compat.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/debian/c_rehash-compat.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl10/debian/debian-targets.patch b/poky/meta/recipes-connectivity/openssl/openssl10/debian/debian-targets.patch
new file mode 100644
index 0000000..24709f4
--- /dev/null
+++ b/poky/meta/recipes-connectivity/openssl/openssl10/debian/debian-targets.patch
@@ -0,0 +1,73 @@
+Upstream-Status: Backport [debian]
+
+Index: openssl-1.0.2n/Configure
+===================================================================
+--- openssl-1.0.2n.orig/Configure
++++ openssl-1.0.2n/Configure
+@@ -133,6 +133,10 @@ my $clang_devteam_warn = "-Wno-unused-pa
+ # Warn that "make depend" should be run?
+ my $warn_make_depend = 0;
+ 
++# There are no separate CFLAGS/CPPFLAGS/LDFLAGS, set everything in CFLAGS
++my $debian_cflags = `dpkg-buildflags --get CFLAGS` . `dpkg-buildflags --get CPPFLAGS` . `dpkg-buildflags --get LDFLAGS` . "-Wa,--noexecstack -Wall";
++$debian_cflags =~ s/\n/ /g;
++
+ my $strict_warnings = 0;
+ 
+ my $x86_gcc_des="DES_PTR DES_RISC1 DES_UNROLL";
+@@ -369,6 +373,55 @@ my %table=(
+ "osf1-alpha-cc",  "cc:-std1 -tune host -O4 -readonly_strings::(unknown):::SIXTY_FOUR_BIT_LONG RC4_CHUNK:${alpha_asm}:dlfcn:alpha-osf1-shared:::.so",
+ "tru64-alpha-cc", "cc:-std1 -tune host -fast -readonly_strings::-pthread:::SIXTY_FOUR_BIT_LONG RC4_CHUNK:${alpha_asm}:dlfcn:alpha-osf1-shared::-msym:.so",
+ 
++# Debian GNU/* (various architectures)
++"debian-alpha","gcc:-DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_RISC1 DES_UNROLL:${alpha_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-alpha-ev4","gcc:-DTERMIO ${debian_cflags} -mcpu=ev4::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_RISC1 DES_UNROLL:${alpha_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-alpha-ev5","gcc:-DTERMIO ${debian_cflags} -mcpu=ev5::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_RISC1 DES_UNROLL:${alpha_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-arm64","gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL BF_PTR:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-armel","gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL BF_PTR:${armv4_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-armhf","gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL BF_PTR:${armv4_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-amd64", "gcc:-m64 -DL_ENDIAN -DTERMIO ${debian_cflags} -DMD32_REG_T=int::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::",
++"debian-avr32", "gcc:-DB_ENDIAN -DTERMIO ${debian_cflags} -fomit-frame-pointer::-D_REENTRANT::-ldl:BN_LLONG_BF_PTR:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-kfreebsd-amd64","gcc:-m64 -DL_ENDIAN -DTERMIOS ${debian_cflags} -DMD32_REG_T=int::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-kfreebsd-i386","gcc:-DL_ENDIAN -DTERMIOS ${debian_cflags} -march=i486::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-hppa","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG MD2_CHAR RC4_INDEX:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-hurd-i386","gcc:-DL_ENDIAN -DTERMIOS -O3 -Wa,--noexecstack -g -mtune=i486 -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-ia64","gcc:-DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_UNROLL DES_INT:${ia64_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-i386","gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-i386-i486","gcc:-DL_ENDIAN -DTERMIO ${debian_cflags} -march=i486::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-i386-i586","gcc:-DL_ENDIAN -DTERMIO ${debian_cflags} -march=i586::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-i386-i686/cmov","gcc:-DL_ENDIAN -DTERMIO ${debian_cflags} -march=i686::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-m68k","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG MD2_CHAR RC4_INDEX:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-mips",   "gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-mipsel",   "gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-mipsn32",   "mips64-linux-gnuabin32-gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-mipsn32el",   "mips64el-linux-gnuabin32-gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-mips64",   "mips64-linux-gnuabi64-gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-mips64el",   "mips64el-linux-gnuabi64-gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-netbsd-i386",	"gcc:-DL_ENDIAN -DTERMIOS ${debian_cflags} -m486::(unknown):::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${no_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-netbsd-m68k",	"gcc:-DB_ENDIAN -DTERMIOS ${debian_cflags}::(unknown):::BN_LLONG MD2_CHAR RC4_INDEX DES_UNROLL:${no_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-netbsd-sparc",	"gcc:-DB_ENDIAN -DTERMIOS ${debian_cflags} -mv8::(unknown):::BN_LLONG MD2_CHAR RC4_INDEX DES_UNROLL:${no_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-openbsd-alpha","gcc:-DTERMIOS ${debian_cflags}::(unknown):::SIXTY_FOUR_BIT_LONG DES_INT DES_PTR DES_RISC2:${no_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-openbsd-i386",  "gcc:-DL_ENDIAN -DTERMIOS ${debian_cflags} -m486::(unknown):::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_asm}:a.out:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-openbsd-mips","gcc:-DL_ENDIAN ${debian_cflags}::(unknown)::BN_LLONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC2 DES_PTR BF_PTR:${no_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-or1k", "gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG DES_RISC1:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-powerpc","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_RISC1 DES_UNROLL:${ppc32_asm}:linux32:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-powerpcspe","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_RISC1 DES_UNROLL:${ppc32_asm}:linux32:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-ppc64","gcc:-m64 -DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_RISC1 DES_UNROLL:${ppc64_asm}:linux64:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-ppc64el","gcc:-m64 -DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_RISC1 DES_UNROLL:${ppc64_asm}:linux64le:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-s390","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)", 
++"debian-s390x","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-sh3",   "gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-sh4",   "gcc:-DL_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-sh3eb",   "gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-sh4eb",   "gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-m32r","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-sparc","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags}::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${sparcv9_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-sparc-v8","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags} -mcpu=v8 -DBN_DIV2W::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${sparcv8_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-sparc-v9","gcc:-DB_ENDIAN -DTERMIO ${debian_cflags} -mcpu=v9 -Wa,-Av8plus -DULTRASPARC -DBN_DIV2W::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${sparcv9_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-sparc64","gcc:-m64 -DB_ENDIAN -DTERMIO ${debian_cflags} -DULTRASPARC -DBN_DIV2W::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_INT DES_PTR DES_RISC1 DES_UNROLL BF_PTR:${sparcv9_asm}:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
++"debian-x32","gcc:-mx32 -DL_ENDIAN -DTERMIO ${debian_cflags} -DMD32_REG_T=int::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:linux-shared:-fPIC:-mx32:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::x32",
++
+ ####
+ #### Variety of LINUX:-)
+ ####
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian/man-dir.patch b/poky/meta/recipes-connectivity/openssl/openssl10/debian/man-dir.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian/man-dir.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/debian/man-dir.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian/man-section.patch b/poky/meta/recipes-connectivity/openssl/openssl10/debian/man-section.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian/man-section.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/debian/man-section.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian/no-rpath.patch b/poky/meta/recipes-connectivity/openssl/openssl10/debian/no-rpath.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian/no-rpath.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/debian/no-rpath.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian/no-symbolic.patch b/poky/meta/recipes-connectivity/openssl/openssl10/debian/no-symbolic.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian/no-symbolic.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/debian/no-symbolic.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian/pic.patch b/poky/meta/recipes-connectivity/openssl/openssl10/debian/pic.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian/pic.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/debian/pic.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian1.0.2/block_digicert_malaysia.patch b/poky/meta/recipes-connectivity/openssl/openssl10/debian1.0.2/block_digicert_malaysia.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian1.0.2/block_digicert_malaysia.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/debian1.0.2/block_digicert_malaysia.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian1.0.2/block_diginotar.patch b/poky/meta/recipes-connectivity/openssl/openssl10/debian1.0.2/block_diginotar.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian1.0.2/block_diginotar.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/debian1.0.2/block_diginotar.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian1.0.2/soname.patch b/poky/meta/recipes-connectivity/openssl/openssl10/debian1.0.2/soname.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian1.0.2/soname.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/debian1.0.2/soname.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian1.0.2/version-script.patch b/poky/meta/recipes-connectivity/openssl/openssl10/debian1.0.2/version-script.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/debian1.0.2/version-script.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/debian1.0.2/version-script.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/engines-install-in-libdir-ssl.patch b/poky/meta/recipes-connectivity/openssl/openssl10/engines-install-in-libdir-ssl.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/engines-install-in-libdir-ssl.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/engines-install-in-libdir-ssl.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/oe-ldflags.patch b/poky/meta/recipes-connectivity/openssl/openssl10/oe-ldflags.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/oe-ldflags.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/oe-ldflags.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/openssl-c_rehash.sh b/poky/meta/recipes-connectivity/openssl/openssl10/openssl-c_rehash.sh
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/openssl-c_rehash.sh
rename to poky/meta/recipes-connectivity/openssl/openssl10/openssl-c_rehash.sh
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/openssl-fix-des.pod-error.patch b/poky/meta/recipes-connectivity/openssl/openssl10/openssl-fix-des.pod-error.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/openssl-fix-des.pod-error.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/openssl-fix-des.pod-error.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/openssl_fix_for_x32.patch b/poky/meta/recipes-connectivity/openssl/openssl10/openssl_fix_for_x32.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/openssl_fix_for_x32.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/openssl_fix_for_x32.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/parallel.patch b/poky/meta/recipes-connectivity/openssl/openssl10/parallel.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/parallel.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/parallel.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/ptest-deps.patch b/poky/meta/recipes-connectivity/openssl/openssl10/ptest-deps.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/ptest-deps.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/ptest-deps.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/ptest_makefile_deps.patch b/poky/meta/recipes-connectivity/openssl/openssl10/ptest_makefile_deps.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/ptest_makefile_deps.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/ptest_makefile_deps.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/reproducible-cflags.patch b/poky/meta/recipes-connectivity/openssl/openssl10/reproducible-cflags.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/reproducible-cflags.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/reproducible-cflags.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/reproducible-mkbuildinf.patch b/poky/meta/recipes-connectivity/openssl/openssl10/reproducible-mkbuildinf.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/reproducible-mkbuildinf.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/reproducible-mkbuildinf.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/run-ptest b/poky/meta/recipes-connectivity/openssl/openssl10/run-ptest
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/run-ptest
rename to poky/meta/recipes-connectivity/openssl/openssl10/run-ptest
diff --git a/poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/shared-libs.patch b/poky/meta/recipes-connectivity/openssl/openssl10/shared-libs.patch
similarity index 100%
rename from poky/meta/recipes-connectivity/openssl/openssl-1.0.2p/shared-libs.patch
rename to poky/meta/recipes-connectivity/openssl/openssl10/shared-libs.patch
diff --git a/poky/meta/recipes-connectivity/openssl/openssl10_1.0.2p.bb b/poky/meta/recipes-connectivity/openssl/openssl10_1.0.2p.bb
new file mode 100644
index 0000000..4325940
--- /dev/null
+++ b/poky/meta/recipes-connectivity/openssl/openssl10_1.0.2p.bb
@@ -0,0 +1,361 @@
+SUMMARY = "Secure Socket Layer"
+DESCRIPTION = "Secure Socket Layer (SSL) binary and related cryptographic tools."
+HOMEPAGE = "http://www.openssl.org/"
+BUGTRACKER = "http://www.openssl.org/news/vulnerabilities.html"
+SECTION = "libs/network"
+
+# "openssl | SSLeay" dual license
+LICENSE = "openssl"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=f475368924827d06d4b416111c8bdb77"
+
+DEPENDS = "hostperl-runtime-native"
+DEPENDS_append_class-target = " openssl-native"
+
+SRC_URI = "http://www.openssl.org/source/openssl-${PV}.tar.gz \
+           file://run-ptest \
+           file://openssl-c_rehash.sh \
+           file://configure-targets.patch \
+           file://shared-libs.patch \
+           file://oe-ldflags.patch \
+           file://engines-install-in-libdir-ssl.patch \
+           file://debian1.0.2/block_diginotar.patch \
+           file://debian1.0.2/block_digicert_malaysia.patch \
+           file://debian/c_rehash-compat.patch \
+           file://debian/debian-targets.patch \
+           file://debian/man-dir.patch \
+           file://debian/man-section.patch \
+           file://debian/no-rpath.patch \
+           file://debian/no-symbolic.patch \
+           file://debian/pic.patch \
+           file://debian1.0.2/version-script.patch \
+           file://debian1.0.2/soname.patch \
+           file://openssl_fix_for_x32.patch \
+           file://openssl-fix-des.pod-error.patch \
+           file://Makefiles-ptest.patch \
+           file://ptest-deps.patch \
+           file://ptest_makefile_deps.patch \
+           file://configure-musl-target.patch \
+           file://parallel.patch \
+           file://Use-SHA256-not-MD5-as-default-digest.patch \
+           file://0001-Fix-build-with-clang-using-external-assembler.patch \
+           file://0001-openssl-force-soft-link-to-avoid-rare-race.patch \
+           file://0001-allow-manpages-to-be-disabled.patch \
+           file://0001-fix-CVE-2018-0734.patch \
+           "
+
+SRC_URI_append_class-target = " \
+           file://reproducible-cflags.patch \
+           file://reproducible-mkbuildinf.patch \
+           "
+
+SRC_URI_append_class-nativesdk = " \
+           file://environment.d-openssl.sh \
+           "
+
+SRC_URI[md5sum] = "ac5eb30bf5798aa14b1ae6d0e7da58df"
+SRC_URI[sha256sum] = "50a98e07b1a89eb8f6a99477f262df71c6fa7bef77df4dc83025a2845c827d00"
+
+S = "${WORKDIR}/openssl-${PV}"
+
+UPSTREAM_CHECK_REGEX = "openssl-(?P<pver>1\.0.+)\.tar"
+
+inherit pkgconfig siteinfo multilib_header ptest manpages
+
+PACKAGECONFIG ?= "cryptodev-linux"
+PACKAGECONFIG_class-native = ""
+PACKAGECONFIG_class-nativesdk = ""
+
+PACKAGECONFIG[cryptodev-linux] = "-DHAVE_CRYPTODEV -DUSE_CRYPTODEV_DIGESTS,,cryptodev-linux"
+PACKAGECONFIG[manpages] = ",,,"
+PACKAGECONFIG[perl] = ",,,"
+
+# Remove this to enable SSLv3. SSLv3 is defaulted to disabled due to the POODLE
+# vulnerability
+EXTRA_OECONF = "no-ssl3"
+
+EXTRA_OEMAKE = "${@bb.utils.contains('PACKAGECONFIG', 'manpages', '', 'OE_DISABLE_MANPAGES=1', d)}"
+
+export OE_LDFLAGS = "${LDFLAGS}"
+
+# openssl fails with ccache: https://bugzilla.yoctoproject.org/show_bug.cgi?id=12810
+CCACHE = ""
+
+TERMIO ?= "-DTERMIO"
+TERMIO_libc-musl = "-DTERMIOS"
+
+CFLAG = "${@oe.utils.conditional('SITEINFO_ENDIANNESS', 'le', '-DL_ENDIAN', '-DB_ENDIAN', d)} \
+         ${TERMIO} ${CFLAGS} -Wall"
+
+# Avoid binaries being marked as requiring an executable stack since they don't
+# (and it causes issues with SELinux)
+CFLAG += "-Wa,--noexecstack"
+
+CFLAG_append_class-native = " -fPIC"
+
+do_configure () {
+	# The crypto_use_bigint patch means that perl's bignum module needs to be
+	# installed, but some distributions (for example Fedora 23) don't ship it by
+	# default.  As the resulting error is very misleading check for bignum before
+	# building.
+	if ! perl -Mbigint -e true; then
+		bbfatal "The perl module 'bignum' was not found but this is required to build openssl.  Please install this module (often packaged as perl-bignum) and re-run bitbake."
+	fi
+
+	ln -sf apps/openssl.pod crypto/crypto.pod ssl/ssl.pod doc/
+
+	os=${HOST_OS}
+	case $os in
+	linux-gnueabi |\
+	linux-gnuspe |\
+	linux-musleabi |\
+	linux-muslspe |\
+	linux-musl )
+		os=linux
+		;;
+	*)
+		;;
+	esac
+	target="$os-${HOST_ARCH}"
+	case $target in
+	linux-arm)
+		target=linux-armv4
+		;;
+	linux-armeb)
+		target=linux-elf-armeb
+		;;
+	linux-aarch64*)
+		target=linux-aarch64
+		;;
+	linux-sh3)
+		target=debian-sh3
+		;;
+	linux-sh4)
+		target=debian-sh4
+		;;
+	linux-i486)
+		target=debian-i386-i486
+		;;
+	linux-i586 | linux-viac3)
+		target=debian-i386-i586
+		;;
+	linux-i686)
+		target=debian-i386-i686/cmov
+		;;
+	linux-gnux32-x86_64 | linux-muslx32-x86_64 )
+		target=linux-x32
+		;;
+	linux-gnu64-x86_64)
+		target=linux-x86_64
+		;;
+	linux-gnun32-mips*el)
+		target=debian-mipsn32el
+		;;
+	linux-gnun32-mips*)
+		target=debian-mipsn32
+		;;
+	linux-mips*64*el)
+		target=debian-mips64el
+		;;
+	linux-mips*64*)
+		target=debian-mips64
+		;;
+	linux-mips*el)
+		target=debian-mipsel
+		;;
+	linux-mips*)
+		target=debian-mips
+		;;
+	linux-microblaze* | linux-nios2* | linux-gnu*ilp32** | linux-arc*)
+		target=linux-generic32
+		;;
+	linux-powerpc)
+		target=linux-ppc
+		;;
+	linux-powerpc64)
+		target=linux-ppc64
+		;;
+	linux-riscv32)
+		target=linux-generic32
+		;;
+	linux-riscv64)
+		target=linux-generic64
+		;;
+	linux-sparc | linux-supersparc)
+		target=linux-sparcv8
+		;;
+	esac
+
+	# inject machine-specific flags
+	sed -i -e "s|^\(\"$target\",\s*\"[^:]\+\):\([^:]\+\)|\1:${CFLAG}|g" Configure
+
+	useprefix=${prefix}
+	if [ "x$useprefix" = "x" ]; then
+		useprefix=/
+	fi
+	libdirleaf="$( echo "${libdir}" | sed "s:^$useprefix/*::" )"
+	perl ./Configure ${EXTRA_OECONF} ${PACKAGECONFIG_CONFARGS} shared --prefix=$useprefix --openssldir=${libdir}/ssl --libdir=$libdirleaf $target
+}
+
+do_compile () {
+	oe_runmake depend
+	oe_runmake
+}
+
+do_compile_class-target () {
+	sed -i 's/\((OPENSSL=\)".*"/\1"openssl"/' Makefile
+	oe_runmake depend
+	cc_sanitized=$(echo "${CC} ${CFLAG}" | sed -e 's,--sysroot=${STAGING_DIR_TARGET},,g' -e 's|${DEBUG_PREFIX_MAP}||g' -e 's/[ \t]\+/ /g')
+	oe_runmake CC_INFO="$cc_sanitized"
+}
+
+do_compile_ptest () {
+	oe_runmake buildtest
+}
+
+do_install () {
+	# Create ${D}/${prefix} to fix parallel issues
+	mkdir -p ${D}/${prefix}/
+
+	oe_runmake INSTALL_PREFIX="${D}" MANDIR="${mandir}" install
+
+	oe_libinstall -so libcrypto ${D}${libdir}
+	oe_libinstall -so libssl ${D}${libdir}
+
+	install -d ${D}${includedir}
+	cp --dereference -R include/openssl ${D}${includedir}
+
+	oe_multilib_header openssl/opensslconf.h
+
+	install -Dm 0755 ${WORKDIR}/openssl-c_rehash.sh ${D}${bindir}/c_rehash
+	sed -i -e 's,/etc/openssl,${sysconfdir}/ssl,g' ${D}${bindir}/c_rehash
+
+	if [ "${@bb.utils.filter('PACKAGECONFIG', 'perl', d)}" ]; then
+		sed -i -e '1s,.*,#!${bindir}/env perl,' ${D}${libdir}/ssl/misc/CA.pl
+		sed -i -e '1s,.*,#!${bindir}/env perl,' ${D}${libdir}/ssl/misc/tsget
+	else
+		rm -f ${D}${libdir}/ssl/misc/CA.pl ${D}${libdir}/ssl/misc/tsget
+	fi
+
+	# Create SSL structure for packages such as ca-certificates which
+	# contain hard-coded paths to /etc/ssl. Debian does the same.
+	install -d ${D}${sysconfdir}/ssl
+	mv ${D}${libdir}/ssl/certs \
+	   ${D}${libdir}/ssl/private \
+	   ${D}${libdir}/ssl/openssl.cnf \
+	   ${D}${sysconfdir}/ssl/
+
+	# Although absolute symlinks would be OK for the target, they become
+	# invalid if native or nativesdk are relocated from sstate.
+	ln -sf ${@oe.path.relative('${libdir}/ssl', '${sysconfdir}/ssl/certs')} ${D}${libdir}/ssl/certs
+	ln -sf ${@oe.path.relative('${libdir}/ssl', '${sysconfdir}/ssl/private')} ${D}${libdir}/ssl/private
+	ln -sf ${@oe.path.relative('${libdir}/ssl', '${sysconfdir}/ssl/openssl.cnf')} ${D}${libdir}/ssl/openssl.cnf
+
+	# Rename man pages to prefix openssl10-*
+	for f in `find ${D}${mandir} -type f`; do
+	    mv $f $(dirname $f)/openssl10-$(basename $f)
+	done
+	for f in `find ${D}${mandir} -type l`; do
+	    ln_f=`readlink $f`
+	    rm -f $f
+	    ln -s openssl10-$ln_f $(dirname $f)/openssl10-$(basename $f)
+	done
+}
+
+do_install_append_class-native () {
+	create_wrapper ${D}${bindir}/openssl \
+	    OPENSSL_CONF=${libdir}/ssl/openssl.cnf \
+	    SSL_CERT_DIR=${libdir}/ssl/certs \
+	    SSL_CERT_FILE=${libdir}/ssl/cert.pem \
+	    OPENSSL_ENGINES=${libdir}/ssl/engines
+}
+
+do_install_append_class-nativesdk () {
+	mkdir -p ${D}${SDKPATHNATIVE}/environment-setup.d
+	install -m 644 ${WORKDIR}/environment.d-openssl.sh ${D}${SDKPATHNATIVE}/environment-setup.d/openssl.sh
+}
+
+do_install_ptest () {
+	cp -r -L Makefile.org Makefile test ${D}${PTEST_PATH}
+
+	# Replace the path to native perl with the path to target perl
+	sed -i 's,^PERL=.*,PERL=${bindir}/perl,' ${D}${PTEST_PATH}/Makefile
+
+	cp Configure config e_os.h ${D}${PTEST_PATH}
+	cp -r -L include ${D}${PTEST_PATH}
+	ln -sf ${libdir}/libcrypto.a ${D}${PTEST_PATH}
+	ln -sf ${libdir}/libssl.a ${D}${PTEST_PATH}
+	mkdir -p ${D}${PTEST_PATH}/crypto
+	cp crypto/constant_time_locl.h ${D}${PTEST_PATH}/crypto
+	cp -r certs ${D}${PTEST_PATH}
+	mkdir -p ${D}${PTEST_PATH}/apps
+	ln -sf ${libdir}/ssl/misc/CA.sh  ${D}${PTEST_PATH}/apps
+	ln -sf ${sysconfdir}/ssl/openssl.cnf ${D}${PTEST_PATH}/apps
+	ln -sf ${bindir}/openssl         ${D}${PTEST_PATH}/apps
+	cp apps/server.pem              ${D}${PTEST_PATH}/apps
+	cp apps/server2.pem             ${D}${PTEST_PATH}/apps
+	mkdir -p ${D}${PTEST_PATH}/util
+	install util/opensslwrap.sh    ${D}${PTEST_PATH}/util
+	install util/shlib_wrap.sh     ${D}${PTEST_PATH}/util
+	# Time stamps are relevant for "make alltests", otherwise
+	# make may try to recompile binaries. Not only must the
+	# binary files be newer than the sources, they also must
+	# be more recent than the header files in /usr/include.
+	#
+	# Using "cp -a" is not sufficient, because do_install
+	# does not preserve the original time stamps.
+	#
+	# So instead of using the original file stamps, we set
+	# the current time for all files. Binaries will get
+	# modified again later when stripping them, but that's okay.
+	touch ${D}${PTEST_PATH}
+	find ${D}${PTEST_PATH} -type f -print0 | xargs --verbose -0 touch -r ${D}${PTEST_PATH}
+
+	# exclude binary files or the package won't install
+	for d in ssltest_old v3ext x509aux; do
+		rm -rf ${D}${libdir}/${BPN}/ptest/test/$d
+	done
+
+	# Remove build host references
+	sed -i \
+	-e 's,--sysroot=${STAGING_DIR_TARGET},,g' \
+	-e 's|${DEBUG_PREFIX_MAP}||g' \
+	${D}${PTEST_PATH}/Makefile ${D}${PTEST_PATH}/Configure
+}
+
+# Add the openssl.cnf file to the openssl-conf package. Make the libcrypto
+# package RRECOMMENDS on this package. This will enable the configuration
+# file to be installed for both the base openssl package and the libcrypto
+# package since the base openssl package depends on the libcrypto package.
+
+PACKAGES =+ "libcrypto10 libssl10 openssl10-conf ${PN}-engines ${PN}-misc"
+
+FILES_libcrypto10 = "${libdir}/libcrypto${SOLIBS}"
+FILES_libssl10 = "${libdir}/libssl${SOLIBS}"
+FILES_openssl10-conf = "${sysconfdir}/ssl/openssl.cnf"
+FILES_${PN}-engines = "${libdir}/ssl/engines/*.so ${libdir}/engines"
+FILES_${PN}-misc = "${libdir}/ssl/misc"
+FILES_${PN} =+ "${libdir}/ssl/*"
+FILES_${PN}_append_class-nativesdk = " ${SDKPATHNATIVE}/environment-setup.d/openssl.sh"
+
+CONFFILES_openssl10-conf = "${sysconfdir}/ssl/openssl.cnf"
+
+RRECOMMENDS_libcrypto10 += "openssl10-conf"
+RDEPENDS_${PN}-misc = "${@bb.utils.filter('PACKAGECONFIG', 'perl', d)}"
+RDEPENDS_${PN}-ptest += "${PN}-misc make perl perl-module-filehandle bc"
+
+BBCLASSEXTEND = "native nativesdk"
+PACKAGE_PREPROCESS_FUNCS += "openssl_package_preprocess"
+
+# openssl 1.0 development files and executable binaries clash with openssl 1.1
+# files when installed into target rootfs. So we don't put them into
+# packages, but they continue to be provided via target sysroot for
+# cross-compilation on the host, if some software still depends on openssl 1.0.
+openssl_package_preprocess () {
+        for file in `find ${PKGD} -name *.h -o -name *.pc -o -name *.so`; do
+                rm $file
+        done
+        rm ${PKGD}/usr/bin/openssl
+        rm ${PKGD}/usr/bin/c_rehash
+        rmdir ${PKGD}/usr/bin
+
+}
diff --git a/poky/meta/recipes-connectivity/openssl/openssl_1.0.2p.bb b/poky/meta/recipes-connectivity/openssl/openssl_1.0.2p.bb
deleted file mode 100644
index 5d41977..0000000
--- a/poky/meta/recipes-connectivity/openssl/openssl_1.0.2p.bb
+++ /dev/null
@@ -1,344 +0,0 @@
-SUMMARY = "Secure Socket Layer"
-DESCRIPTION = "Secure Socket Layer (SSL) binary and related cryptographic tools."
-HOMEPAGE = "http://www.openssl.org/"
-BUGTRACKER = "http://www.openssl.org/news/vulnerabilities.html"
-SECTION = "libs/network"
-
-# "openssl | SSLeay" dual license
-LICENSE = "openssl"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=f475368924827d06d4b416111c8bdb77"
-
-DEPENDS = "hostperl-runtime-native"
-DEPENDS_append_class-target = " openssl-native"
-
-PROVIDES += "openssl10"
-
-SRC_URI = "http://www.openssl.org/source/openssl-${PV}.tar.gz \
-           file://run-ptest \
-           file://openssl-c_rehash.sh \
-           file://configure-targets.patch \
-           file://shared-libs.patch \
-           file://oe-ldflags.patch \
-           file://engines-install-in-libdir-ssl.patch \
-           file://debian1.0.2/block_diginotar.patch \
-           file://debian1.0.2/block_digicert_malaysia.patch \
-           file://debian/c_rehash-compat.patch \
-           file://debian/debian-targets.patch \
-           file://debian/man-dir.patch \
-           file://debian/man-section.patch \
-           file://debian/no-rpath.patch \
-           file://debian/no-symbolic.patch \
-           file://debian/pic.patch \
-           file://debian1.0.2/version-script.patch \
-           file://debian1.0.2/soname.patch \
-           file://openssl_fix_for_x32.patch \
-           file://openssl-fix-des.pod-error.patch \
-           file://Makefiles-ptest.patch \
-           file://ptest-deps.patch \
-           file://ptest_makefile_deps.patch \
-           file://configure-musl-target.patch \
-           file://parallel.patch \
-           file://Use-SHA256-not-MD5-as-default-digest.patch \
-           file://0001-Fix-build-with-clang-using-external-assembler.patch \
-           file://0001-openssl-force-soft-link-to-avoid-rare-race.patch \
-           file://0001-allow-manpages-to-be-disabled.patch \
-           "
-
-SRC_URI_append_class-target = " \
-           file://reproducible-cflags.patch \
-           file://reproducible-mkbuildinf.patch \
-           "
-
-SRC_URI_append_class-nativesdk = " \
-           file://environment.d-openssl.sh \
-           "
-
-SRC_URI[md5sum] = "ac5eb30bf5798aa14b1ae6d0e7da58df"
-SRC_URI[sha256sum] = "50a98e07b1a89eb8f6a99477f262df71c6fa7bef77df4dc83025a2845c827d00"
-
-UPSTREAM_CHECK_REGEX = "openssl-(?P<pver>1\.0.+)\.tar"
-
-inherit pkgconfig siteinfo multilib_header ptest relative_symlinks manpages
-
-PACKAGECONFIG ?= "cryptodev-linux"
-PACKAGECONFIG_class-native = ""
-PACKAGECONFIG_class-nativesdk = ""
-
-PACKAGECONFIG[cryptodev-linux] = "-DHAVE_CRYPTODEV -DUSE_CRYPTODEV_DIGESTS,,cryptodev-linux"
-PACKAGECONFIG[manpages] = ",,,"
-PACKAGECONFIG[perl] = ",,,"
-
-# Remove this to enable SSLv3. SSLv3 is defaulted to disabled due to the POODLE
-# vulnerability
-EXTRA_OECONF = "no-ssl3"
-
-EXTRA_OEMAKE = "${@bb.utils.contains('PACKAGECONFIG', 'manpages', '', 'OE_DISABLE_MANPAGES=1', d)}"
-
-export OE_LDFLAGS = "${LDFLAGS}"
-
-# openssl fails with ccache: https://bugzilla.yoctoproject.org/show_bug.cgi?id=12810
-CCACHE = ""
-
-TERMIO ?= "-DTERMIO"
-TERMIO_libc-musl = "-DTERMIOS"
-
-CFLAG = "${@oe.utils.conditional('SITEINFO_ENDIANNESS', 'le', '-DL_ENDIAN', '-DB_ENDIAN', d)} \
-         ${TERMIO} ${CFLAGS} -Wall"
-
-# Avoid binaries being marked as requiring an executable stack since they don't
-# (and it causes issues with SELinux)
-CFLAG += "-Wa,--noexecstack"
-
-CFLAG_append_class-native = " -fPIC"
-
-do_configure () {
-	# The crypto_use_bigint patch means that perl's bignum module needs to be
-	# installed, but some distributions (for example Fedora 23) don't ship it by
-	# default.  As the resulting error is very misleading check for bignum before
-	# building.
-	if ! perl -Mbigint -e true; then
-		bbfatal "The perl module 'bignum' was not found but this is required to build openssl.  Please install this module (often packaged as perl-bignum) and re-run bitbake."
-	fi
-
-	ln -sf apps/openssl.pod crypto/crypto.pod ssl/ssl.pod doc/
-
-	os=${HOST_OS}
-	case $os in
-	linux-gnueabi |\
-	linux-gnuspe |\
-	linux-musleabi |\
-	linux-muslspe |\
-	linux-musl )
-		os=linux
-		;;
-	*)
-		;;
-	esac
-	target="$os-${HOST_ARCH}"
-	case $target in
-	linux-arm)
-		target=linux-armv4
-		;;
-	linux-armeb)
-		target=linux-elf-armeb
-		;;
-	linux-aarch64*)
-		target=linux-aarch64
-		;;
-	linux-sh3)
-		target=debian-sh3
-		;;
-	linux-sh4)
-		target=debian-sh4
-		;;
-	linux-i486)
-		target=debian-i386-i486
-		;;
-	linux-i586 | linux-viac3)
-		target=debian-i386-i586
-		;;
-	linux-i686)
-		target=debian-i386-i686/cmov
-		;;
-	linux-gnux32-x86_64 | linux-muslx32-x86_64 )
-		target=linux-x32
-		;;
-	linux-gnu64-x86_64)
-		target=linux-x86_64
-		;;
-	linux-gnun32-mips*el)
-		target=debian-mipsn32el
-		;;
-	linux-gnun32-mips*)
-		target=debian-mipsn32
-		;;
-	linux-mips*64*el)
-		target=debian-mips64el
-		;;
-	linux-mips*64*)
-		target=debian-mips64
-		;;
-	linux-mips*el)
-		target=debian-mipsel
-		;;
-	linux-mips*)
-		target=debian-mips
-		;;
-	linux-microblaze*|linux-nios2*|linux-gnu*ilp32**)
-		target=linux-generic32
-		;;
-	linux-powerpc)
-		target=linux-ppc
-		;;
-	linux-powerpc64)
-		target=linux-ppc64
-		;;
-	linux-riscv32)
-		target=linux-generic32
-		;;
-	linux-riscv64)
-		target=linux-generic64
-		;;
-	linux-supersparc)
-		target=linux-sparcv8
-		;;
-	linux-sparc)
-		target=linux-sparcv8
-		;;
-	esac
-
-	# inject machine-specific flags
-	sed -i -e "s|^\(\"$target\",\s*\"[^:]\+\):\([^:]\+\)|\1:${CFLAG}|g" Configure
-
-	useprefix=${prefix}
-	if [ "x$useprefix" = "x" ]; then
-		useprefix=/
-	fi
-	libdirleaf="$(echo ${libdir} | sed s:$useprefix::)"
-	perl ./Configure ${EXTRA_OECONF} ${PACKAGECONFIG_CONFARGS} shared --prefix=$useprefix --openssldir=${libdir}/ssl --libdir=$libdirleaf $target
-}
-
-do_compile () {
-	oe_runmake depend
-	oe_runmake
-}
-
-do_compile_class-target () {
-	sed -i 's/\((OPENSSL=\)".*"/\1"openssl"/' Makefile
-	oe_runmake depend
-	cc_sanitized=$(echo "${CC} ${CFLAG}" | sed -e 's,--sysroot=${STAGING_DIR_TARGET},,g' -e 's|${DEBUG_PREFIX_MAP}||g' -e 's/[ \t]\+/ /g')
-	oe_runmake CC_INFO="$cc_sanitized"
-}
-
-do_compile_ptest () {
-	oe_runmake buildtest
-}
-
-do_install () {
-	# Create ${D}/${prefix} to fix parallel issues
-	mkdir -p ${D}/${prefix}/
-
-	oe_runmake INSTALL_PREFIX="${D}" MANDIR="${mandir}" install
-
-	oe_libinstall -so libcrypto ${D}${libdir}
-	oe_libinstall -so libssl ${D}${libdir}
-
-	install -d ${D}${includedir}
-	cp --dereference -R include/openssl ${D}${includedir}
-
-	install -Dm 0755 ${WORKDIR}/openssl-c_rehash.sh ${D}${bindir}/c_rehash
-	sed -i -e 's,/etc/openssl,${sysconfdir}/ssl,g' ${D}${bindir}/c_rehash
-
-	oe_multilib_header openssl/opensslconf.h
-	if [ "${@bb.utils.filter('PACKAGECONFIG', 'perl', d)}" ]; then
-		sed -i -e '1s,.*,#!${bindir}/env perl,' ${D}${libdir}/ssl/misc/CA.pl
-		sed -i -e '1s,.*,#!${bindir}/env perl,' ${D}${libdir}/ssl/misc/tsget
-	else
-		rm -f ${D}${libdir}/ssl/misc/CA.pl ${D}${libdir}/ssl/misc/tsget
-	fi
-
-	# Create SSL structure
-	install -d ${D}${sysconfdir}/ssl/
-	mv ${D}${libdir}/ssl/openssl.cnf \
-	   ${D}${libdir}/ssl/certs \
-	   ${D}${libdir}/ssl/private \
-	   \
-	   ${D}${sysconfdir}/ssl/
-	ln -sf ${sysconfdir}/ssl/certs ${D}${libdir}/ssl/certs
-	ln -sf ${sysconfdir}/ssl/private ${D}${libdir}/ssl/private
-	ln -sf ${sysconfdir}/ssl/openssl.cnf ${D}${libdir}/ssl/openssl.cnf
-
-	# Rename man pages to prefix openssl10-*
-	for f in `find ${D}${mandir} -type f`; do
-	    mv $f $(dirname $f)/openssl10-$(basename $f)
-	done
-	for f in `find ${D}${mandir} -type l`; do
-	    ln_f=`readlink $f`
-	    rm -f $f
-	    ln -s openssl10-$ln_f $(dirname $f)/openssl10-$(basename $f)
-	done
-}
-
-do_install_ptest () {
-	cp -r -L Makefile.org Makefile test ${D}${PTEST_PATH}
-
-	# Replace the path to native perl with the path to target perl
-	sed -i 's,^PERL=.*,PERL=${bindir}/perl,' ${D}${PTEST_PATH}/Makefile
-
-	cp Configure config e_os.h ${D}${PTEST_PATH}
-	cp -r -L include ${D}${PTEST_PATH}
-	ln -sf ${libdir}/libcrypto.a ${D}${PTEST_PATH}
-	ln -sf ${libdir}/libssl.a ${D}${PTEST_PATH}
-	mkdir -p ${D}${PTEST_PATH}/crypto
-	cp crypto/constant_time_locl.h ${D}${PTEST_PATH}/crypto
-	cp -r certs ${D}${PTEST_PATH}
-	mkdir -p ${D}${PTEST_PATH}/apps
-	ln -sf ${libdir}/ssl/misc/CA.sh  ${D}${PTEST_PATH}/apps
-	ln -sf ${sysconfdir}/ssl/openssl.cnf ${D}${PTEST_PATH}/apps
-	ln -sf ${bindir}/openssl         ${D}${PTEST_PATH}/apps
-	cp apps/server.pem              ${D}${PTEST_PATH}/apps
-	cp apps/server2.pem             ${D}${PTEST_PATH}/apps
-	mkdir -p ${D}${PTEST_PATH}/util
-	install util/opensslwrap.sh    ${D}${PTEST_PATH}/util
-	install util/shlib_wrap.sh     ${D}${PTEST_PATH}/util
-	# Time stamps are relevant for "make alltests", otherwise
-	# make may try to recompile binaries. Not only must the
-	# binary files be newer than the sources, they also must
-	# be more recent than the header files in /usr/include.
-	#
-	# Using "cp -a" is not sufficient, because do_install
-	# does not preserve the original time stamps.
-	#
-	# So instead of using the original file stamps, we set
-	# the current time for all files. Binaries will get
-	# modified again later when stripping them, but that's okay.
-	touch ${D}${PTEST_PATH}
-	find ${D}${PTEST_PATH} -type f -print0 | xargs --verbose -0 touch -r ${D}${PTEST_PATH}
-
-	# exclude binary files or the package won't install
-	for d in ssltest_old v3ext x509aux; do
-		rm -rf ${D}${libdir}/${BPN}/ptest/test/$d
-	done
-
-	# Remove build host references
-	sed -i \
-	-e 's,--sysroot=${STAGING_DIR_TARGET},,g' \
-	-e 's|${DEBUG_PREFIX_MAP}||g' \
-	${D}${PTEST_PATH}/Makefile ${D}${PTEST_PATH}/Configure
-}
-
-do_install_append_class-native() {
-	create_wrapper ${D}${bindir}/openssl \
-	    OPENSSL_CONF=${libdir}/ssl/openssl.cnf \
-	    SSL_CERT_DIR=${libdir}/ssl/certs \
-	    SSL_CERT_FILE=${libdir}/ssl/cert.pem \
-	    OPENSSL_ENGINES=${libdir}/ssl/engines
-}
-
-do_install_append_class-nativesdk() {
-	mkdir -p ${D}${SDKPATHNATIVE}/environment-setup.d
-	install -m 644 ${WORKDIR}/environment.d-openssl.sh ${D}${SDKPATHNATIVE}/environment-setup.d/openssl.sh
-}
-
-# Add the openssl.cnf file to the openssl-conf package.  Make the libcrypto
-# package RRECOMMENDS on this package.  This will enable the configuration
-# file to be installed for both the base openssl package and the libcrypto
-# package since the base openssl package depends on the libcrypto package.
-
-PACKAGES =+ "libcrypto libssl openssl-conf ${PN}-engines ${PN}-misc"
-
-FILES_libcrypto = "${libdir}/libcrypto${SOLIBS}"
-FILES_libssl = "${libdir}/libssl${SOLIBS}"
-FILES_openssl-conf = "${sysconfdir}/ssl/openssl.cnf"
-FILES_${PN}-engines = "${libdir}/ssl/engines/*.so ${libdir}/engines"
-FILES_${PN}-misc = "${libdir}/ssl/misc"
-FILES_${PN} =+ "${libdir}/ssl/*"
-FILES_${PN}_append_class-nativesdk = " ${SDKPATHNATIVE}/environment-setup.d/openssl.sh"
-
-CONFFILES_openssl-conf = "${sysconfdir}/ssl/openssl.cnf"
-
-RRECOMMENDS_libcrypto += "openssl-conf"
-RDEPENDS_${PN}-misc = "${@bb.utils.filter('PACKAGECONFIG', 'perl', d)}"
-RDEPENDS_${PN}-ptest += "${PN}-misc make perl perl-module-filehandle bc"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-connectivity/openssl/openssl_1.1.0i.bb b/poky/meta/recipes-connectivity/openssl/openssl_1.1.0i.bb
deleted file mode 100644
index e700626..0000000
--- a/poky/meta/recipes-connectivity/openssl/openssl_1.1.0i.bb
+++ /dev/null
@@ -1,170 +0,0 @@
-SUMMARY = "Secure Socket Layer"
-DESCRIPTION = "Secure Socket Layer (SSL) binary and related cryptographic tools."
-HOMEPAGE = "http://www.openssl.org/"
-BUGTRACKER = "http://www.openssl.org/news/vulnerabilities.html"
-SECTION = "libs/network"
-
-# "openssl | SSLeay" dual license
-LICENSE = "openssl"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=d57d511030c9d66ef5f5966bee5a7eff"
-
-DEPENDS = "hostperl-runtime-native"
-
-SRC_URI = "http://www.openssl.org/source/openssl-${PV}.tar.gz \
-           file://run-ptest \
-           file://openssl-c_rehash.sh \
-           file://0001-Take-linking-flags-from-LDFLAGS-env-var.patch \
-           "
-
-SRC_URI_append_class-nativesdk = " \
-           file://environment.d-openssl.sh \
-           "
-
-SRC_URI[md5sum] = "9495126aafd2659d357ea66a969c3fe1"
-SRC_URI[sha256sum] = "ebbfc844a8c8cc0ea5dc10b86c9ce97f401837f3fa08c17b2cdadc118253cf99"
-
-inherit lib_package multilib_header ptest
-
-#| engines/afalg/e_afalg.c: In function 'eventfd':
-#| engines/afalg/e_afalg.c:110:20: error: '__NR_eventfd' undeclared (first use in this function)
-#|      return syscall(__NR_eventfd, n);
-#|                     ^~~~~~~~~~~~
-EXTRA_OECONF_append_aarch64 = " no-afalgeng"
-
-#| ./libcrypto.so: undefined reference to `getcontext'
-#| ./libcrypto.so: undefined reference to `setcontext'
-#| ./libcrypto.so: undefined reference to `makecontext'
-EXTRA_OECONF_append_libc-musl = " -DOPENSSL_NO_ASYNC"
-
-do_configure () {
-	os=${HOST_OS}
-	case $os in
-	linux-gnueabi |\
-	linux-gnuspe |\
-	linux-musleabi |\
-	linux-muslspe |\
-	linux-musl )
-		os=linux
-		;;
-	*)
-		;;
-	esac
-	target="$os-${HOST_ARCH}"
-	case $target in
-	linux-arm)
-		target=linux-armv4
-		;;
-	linux-armeb)
-		target=linux-armv4
-		;;
-	linux-aarch64*)
-		target=linux-aarch64
-		;;
-	linux-sh3)
-		target=linux-generic32
-		;;
-	linux-sh4)
-		target=linux-generic32
-		;;
-	linux-i486)
-		target=linux-elf
-		;;
-	linux-i586 | linux-viac3)
-		target=linux-elf
-		;;
-	linux-i686)
-		target=linux-elf
-		;;
-	linux-gnux32-x86_64 | linux-muslx32-x86_64 )
-		target=linux-x32
-		;;
-	linux-gnu64-x86_64)
-		target=linux-x86_64
-		;;
-	linux-mips)
-		# specifying TARGET_CC_ARCH prevents openssl from (incorrectly) adding target architecture flags
-		target="linux-mips32 ${TARGET_CC_ARCH}"
-		;;
-	linux-mipsel)
-		target="linux-mips32 ${TARGET_CC_ARCH}"
-		;;
-	linux-gnun32-mips*)
-		target=linux-mips64
-		;;
-	linux-*-mips64 | linux-mips64)
-		target=linux64-mips64
-		;;
-	linux-*-mips64el | linux-mips64el)
-		target=linux64-mips64
-		;;
-	linux-microblaze*|linux-nios2*)
-		target=linux-generic32
-		;;
-	linux-powerpc)
-		target=linux-ppc
-		;;
-	linux-powerpc64)
-		target=linux-ppc64
-		;;
-	linux-riscv32)
-		target=linux-generic32
-		;;
-	linux-riscv64)
-		target=linux-generic64
-		;;
-	linux-supersparc)
-		target=linux-sparcv9
-		;;
-	linux-sparc)
-		target=linux-sparcv9
-		;;
-	darwin-i386)
-		target=darwin-i386-cc
-		;;
-	esac
-
-	useprefix=${prefix}
-	if [ "x$useprefix" = "x" ]; then
-		useprefix=/
-	fi
-	libdirleaf="$(echo ${libdir} | sed s:$useprefix::)"
-	perl ./Configure ${EXTRA_OECONF} ${PACKAGECONFIG_CONFARGS} --prefix=$useprefix --openssldir=${libdir}/ssl-1.1 --libdir=$libdirleaf $target
-}
-
-do_install () {
-	oe_runmake DESTDIR="${D}" MANDIR="${mandir}" MANSUFFIX=ssl install
-	oe_multilib_header openssl/opensslconf.h
-}
-
-do_install_append_class-native () {
-	# Install a custom version of c_rehash that can handle sysroots properly.
-	# This version is used for example when installing ca-certificates during
-	# image creation.
-	install -Dm 0755 ${WORKDIR}/openssl-c_rehash.sh ${D}${bindir}/c_rehash
-	sed -i -e 's,/etc/openssl,${sysconfdir}/ssl,g' ${D}${bindir}/c_rehash
-}
-
-do_install_append_class-nativesdk () {
-	mkdir -p ${D}${SDKPATHNATIVE}/environment-setup.d
-	install -m 644 ${WORKDIR}/environment.d-openssl.sh ${D}${SDKPATHNATIVE}/environment-setup.d/openssl.sh
-}
-
-do_install_ptest() {
-	cp -r * ${D}${PTEST_PATH}
-
-	# Putting .so files in ptest package will mess up the dependencies of the main openssl package
-	# so we rename them to .so.ptest and patch the test accordingly
-	mv ${D}${PTEST_PATH}/libcrypto.so ${D}${PTEST_PATH}/libcrypto.so.ptest
-	mv ${D}${PTEST_PATH}/libssl.so ${D}${PTEST_PATH}/libssl.so.ptest
-	sed -i 's/$target{shared_extension_simple}/".so.ptest"/' ${D}${PTEST_PATH}/test/recipes/90-test_shlibload.t
-}
-
-PACKAGES =+ "${PN}-engines"
-
-FILES_${PN} =+ "${libdir}/ssl-1.1/*"
-FILES_${PN}_append_class-nativesdk = " ${SDKPATHNATIVE}/environment-setup.d/openssl.sh"
-FILES_${PN}-engines = "${libdir}/engines-1.1"
-
-RDEPENDS_${PN}-ptest += "perl-module-file-spec-functions bash python"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-connectivity/openssl/openssl_1.1.1.bb b/poky/meta/recipes-connectivity/openssl/openssl_1.1.1.bb
new file mode 100644
index 0000000..1234b64
--- /dev/null
+++ b/poky/meta/recipes-connectivity/openssl/openssl_1.1.1.bb
@@ -0,0 +1,205 @@
+SUMMARY = "Secure Socket Layer"
+DESCRIPTION = "Secure Socket Layer (SSL) binary and related cryptographic tools."
+HOMEPAGE = "http://www.openssl.org/"
+BUGTRACKER = "http://www.openssl.org/news/vulnerabilities.html"
+SECTION = "libs/network"
+
+# "openssl" here actually means both OpenSSL and SSLeay licenses apply
+# (see meta/files/common-licenses/OpenSSL to which "openssl" is SPDXLICENSEMAPped)
+LICENSE = "openssl"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=d57d511030c9d66ef5f5966bee5a7eff"
+
+DEPENDS = "hostperl-runtime-native"
+
+SRC_URI = "http://www.openssl.org/source/openssl-${PV}.tar.gz \
+           file://run-ptest \
+           file://openssl-c_rehash.sh \
+           file://0001-skip-test_symbol_presence.patch \
+           file://0002-fix-CVE-2018-0734.patch \
+           file://0003-fix-CVE-2018-0735.patch \
+           file://0001-buildinfo-strip-sysroot-and-debug-prefix-map-from-co.patch \
+           "
+
+SRC_URI_append_class-nativesdk = " \
+           file://environment.d-openssl.sh \
+           "
+
+SRC_URI[md5sum] = "7079eb017429e0ffb9efb42bf80ccb21"
+SRC_URI[sha256sum] = "2836875a0f89c03d0fdf483941512613a50cfb421d6fd94b9f41d7279d586a3d"
+
+inherit lib_package multilib_header ptest
+
+B = "${WORKDIR}/build"
+do_configure[cleandirs] = "${B}"
+
+#| ./libcrypto.so: undefined reference to `getcontext'
+#| ./libcrypto.so: undefined reference to `setcontext'
+#| ./libcrypto.so: undefined reference to `makecontext'
+EXTRA_OECONF_append_libc-musl = " no-async"
+
+# This prevents openssl from using getrandom() which is not available on older glibc versions
+# (native versions can be built with newer glibc, but then relocated onto a system with older glibc)
+EXTRA_OECONF_class-native = "--with-rand-seed=devrandom"
+EXTRA_OECONF_class-nativesdk = "--with-rand-seed=devrandom"
+
+# Relying on hardcoded built-in paths causes openssl-native to not be relocateable from sstate.
+CFLAGS_append_class-native = " -DOPENSSLDIR=/not/builtin -DENGINESDIR=/not/builtin"
+CFLAGS_append_class-nativesdk = " -DOPENSSLDIR=/not/builtin -DENGINESDIR=/not/builtin"
+
+do_configure () {
+	os=${HOST_OS}
+	case $os in
+	linux-gnueabi |\
+	linux-gnuspe |\
+	linux-musleabi |\
+	linux-muslspe |\
+	linux-musl )
+		os=linux
+		;;
+	*)
+		;;
+	esac
+	target="$os-${HOST_ARCH}"
+	case $target in
+	linux-arm*)
+		target=linux-armv4
+		;;
+	linux-aarch64*)
+		target=linux-aarch64
+		;;
+	linux-i?86 | linux-viac3)
+		target=linux-x86
+		;;
+	linux-gnux32-x86_64 | linux-muslx32-x86_64 )
+		target=linux-x32
+		;;
+	linux-gnu64-x86_64)
+		target=linux-x86_64
+		;;
+	linux-mips | linux-mipsel)
+		# specifying TARGET_CC_ARCH prevents openssl from (incorrectly) adding target architecture flags
+		target="linux-mips32 ${TARGET_CC_ARCH}"
+		;;
+	linux-gnun32-mips*)
+		target=linux-mips64
+		;;
+	linux-*-mips64 | linux-mips64 | linux-*-mips64el | linux-mips64el)
+		target=linux64-mips64
+		;;
+	linux-microblaze* | linux-nios2* | linux-sh3 | linux-sh4 | linux-arc*)
+		target=linux-generic32
+		;;
+	linux-powerpc)
+		target=linux-ppc
+		;;
+	linux-powerpc64)
+		target=linux-ppc64
+		;;
+	linux-riscv32)
+		target=linux-generic32
+		;;
+	linux-riscv64)
+		target=linux-generic64
+		;;
+	linux-sparc | linux-supersparc)
+		target=linux-sparcv9
+		;;
+	esac
+
+	useprefix=${prefix}
+	if [ "x$useprefix" = "x" ]; then
+		useprefix=/
+	fi
+	# WARNING: do not set compiler/linker flags (-I/-D etc.) in EXTRA_OECONF, as they will fully replace the
+	# environment variables set by bitbake. Adjust the environment variables instead.
+	PERL5LIB="${S}/external/perl/Text-Template-1.46/lib/" \
+	perl ${S}/Configure ${EXTRA_OECONF} ${PACKAGECONFIG_CONFARGS} --prefix=$useprefix --openssldir=${libdir}/ssl-1.1 --libdir=${libdir} $target
+}
+
+do_install () {
+	oe_runmake DESTDIR="${D}" MANDIR="${mandir}" MANSUFFIX=ssl install
+
+	oe_multilib_header openssl/opensslconf.h
+
+	# Create SSL structure for packages such as ca-certificates which
+	# contain hard-coded paths to /etc/ssl. Debian does the same.
+	install -d ${D}${sysconfdir}/ssl
+	mv ${D}${libdir}/ssl-1.1/certs \
+	   ${D}${libdir}/ssl-1.1/private \
+	   ${D}${libdir}/ssl-1.1/openssl.cnf \
+	   ${D}${sysconfdir}/ssl/
+
+	# Although absolute symlinks would be OK for the target, they become
+	# invalid if native or nativesdk are relocated from sstate.
+	ln -sf ${@oe.path.relative('${libdir}/ssl-1.1', '${sysconfdir}/ssl/certs')} ${D}${libdir}/ssl-1.1/certs
+	ln -sf ${@oe.path.relative('${libdir}/ssl-1.1', '${sysconfdir}/ssl/private')} ${D}${libdir}/ssl-1.1/private
+	ln -sf ${@oe.path.relative('${libdir}/ssl-1.1', '${sysconfdir}/ssl/openssl.cnf')} ${D}${libdir}/ssl-1.1/openssl.cnf
+}
+
+do_install_append_class-native () {
+	create_wrapper ${D}${bindir}/openssl \
+	    OPENSSL_CONF=${libdir}/ssl-1.1/openssl.cnf \
+	    SSL_CERT_DIR=${libdir}/ssl-1.1/certs \
+	    SSL_CERT_FILE=${libdir}/ssl-1.1/cert.pem \
+	    OPENSSL_ENGINES=${libdir}/ssl-1.1/engines
+
+	# Install a custom version of c_rehash that can handle sysroots properly.
+	# This version is used for example when installing ca-certificates during
+	# image creation.
+	install -Dm 0755 ${WORKDIR}/openssl-c_rehash.sh ${D}${bindir}/c_rehash
+	sed -i -e 's,/etc/openssl,${sysconfdir}/ssl,g' ${D}${bindir}/c_rehash
+}
+
+do_install_append_class-nativesdk () {
+	mkdir -p ${D}${SDKPATHNATIVE}/environment-setup.d
+	install -m 644 ${WORKDIR}/environment.d-openssl.sh ${D}${SDKPATHNATIVE}/environment-setup.d/openssl.sh
+	sed 's|/usr/lib/ssl/|/usr/lib/ssl-1.1/|g' -i ${D}${SDKPATHNATIVE}/environment-setup.d/openssl.sh
+}
+
+do_install_ptest () {
+	# Prune the build tree
+	rm -f ${B}/fuzz/*.* ${B}/test/*.*
+
+	cp ${S}/Configure ${B}/configdata.pm ${D}${PTEST_PATH}
+	cp -r ${S}/external ${B}/test ${S}/test ${B}/fuzz ${S}/util ${B}/util ${D}${PTEST_PATH}
+
+	# For test_shlibload
+	ln -s ${libdir}/libcrypto.so.1.1 ${D}${PTEST_PATH}/libcrypto.so
+	ln -s ${libdir}/libssl.so.1.1 ${D}${PTEST_PATH}/libssl.so
+
+	install -d ${D}${PTEST_PATH}/apps
+	ln -s ${bindir}/openssl ${D}${PTEST_PATH}/apps
+	install -m644 ${S}/apps/*.pem ${S}/apps/*.srl ${S}/apps/openssl.cnf ${D}${PTEST_PATH}/apps
+	install -m755 ${B}/apps/CA.pl ${D}${PTEST_PATH}/apps
+
+	install -d ${D}${PTEST_PATH}/engines
+	install -m755 ${B}/engines/ossltest.so ${D}${PTEST_PATH}/engines
+}
+
+# Add the openssl.cnf file to the openssl-conf package. Make the libcrypto
+# package RRECOMMENDS on this package. This will enable the configuration
+# file to be installed for both the openssl-bin package and the libcrypto
+# package since the openssl-bin package depends on the libcrypto package.
+
+PACKAGES =+ "libcrypto libssl openssl-conf ${PN}-engines ${PN}-misc"
+
+FILES_libcrypto = "${libdir}/libcrypto${SOLIBS}"
+FILES_libssl = "${libdir}/libssl${SOLIBS}"
+FILES_openssl-conf = "${sysconfdir}/ssl/openssl.cnf"
+FILES_${PN}-engines = "${libdir}/engines-1.1"
+FILES_${PN}-misc = "${libdir}/ssl-1.1/misc"
+FILES_${PN} =+ "${libdir}/ssl-1.1/*"
+FILES_${PN}_append_class-nativesdk = " ${SDKPATHNATIVE}/environment-setup.d/openssl.sh"
+
+CONFFILES_openssl-conf = "${sysconfdir}/ssl/openssl.cnf"
+
+RRECOMMENDS_libcrypto += "openssl-conf"
+RDEPENDS_${PN}-bin = "perl"
+RDEPENDS_${PN}-misc = "perl"
+RDEPENDS_${PN}-ptest += "openssl-bin perl perl-modules bash python"
+
+RPROVIDES_openssl-conf = "openssl10-conf"
+RREPLACES_openssl-conf = "openssl10-conf"
+RCONFLICTS_openssl-conf = "openssl10-conf"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-connectivity/ppp/ppp/ppp-2.4.7-DES-openssl.patch b/poky/meta/recipes-connectivity/ppp/ppp/ppp-2.4.7-DES-openssl.patch
new file mode 100644
index 0000000..e53f240
--- /dev/null
+++ b/poky/meta/recipes-connectivity/ppp/ppp/ppp-2.4.7-DES-openssl.patch
@@ -0,0 +1,84 @@
+Used openssl for the DES instead of the libcrypt / glibc
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Index: ppp-2.4.7/pppd/Makefile.linux
+===================================================================
+--- ppp-2.4.7.orig/pppd/Makefile.linux
++++ ppp-2.4.7/pppd/Makefile.linux
+@@ -38,7 +38,7 @@ LIBS =
+ # Uncomment the next 2 lines to include support for Microsoft's
+ # MS-CHAP authentication protocol.  Also, edit plugins/radius/Makefile.linux.
+ CHAPMS=y
+-USE_CRYPT=y
++#USE_CRYPT=y
+ # Don't use MSLANMAN unless you really know what you're doing.
+ #MSLANMAN=y
+ # Uncomment the next line to include support for MPPE.  CHAPMS (above) must
+@@ -132,7 +132,7 @@ endif
+ 
+ ifdef NEEDDES
+ ifndef USE_CRYPT
+-LIBS     += -ldes $(LIBS)
++LIBS     += -lcrypto
+ else
+ CFLAGS   += -DUSE_CRYPT=1
+ endif
+Index: ppp-2.4.7/pppd/pppcrypt.c
+===================================================================
+--- ppp-2.4.7.orig/pppd/pppcrypt.c
++++ ppp-2.4.7/pppd/pppcrypt.c
+@@ -64,7 +64,7 @@ u_char *des_key;	/* OUT 64 bit DES key w
+ 	des_key[7] = Get7Bits(key, 49);
+ 
+ #ifndef USE_CRYPT
+-	des_set_odd_parity((des_cblock *)des_key);
++	DES_set_odd_parity((DES_cblock *)des_key);
+ #endif
+ }
+ 
+@@ -158,25 +158,25 @@ u_char *clear;	/* OUT 8 octets */
+ }
+ 
+ #else /* USE_CRYPT */
+-static des_key_schedule	key_schedule;
++static DES_key_schedule	key_schedule;
+ 
+ bool
+ DesSetkey(key)
+ u_char *key;
+ {
+-	des_cblock des_key;
++	DES_cblock des_key;
+ 	MakeKey(key, des_key);
+-	des_set_key(&des_key, key_schedule);
++	DES_set_key(&des_key, &key_schedule);
+ 	return (1);
+ }
+ 
+ bool
+-DesEncrypt(clear, key, cipher)
++DesEncrypt(clear, cipher)
+ u_char *clear;	/* IN  8 octets */
+ u_char *cipher;	/* OUT 8 octets */
+ {
+-	des_ecb_encrypt((des_cblock *)clear, (des_cblock *)cipher,
+-	    key_schedule, 1);
++	DES_ecb_encrypt((DES_cblock *)clear, (DES_cblock *)cipher,
++	    &key_schedule, 1);
+ 	return (1);
+ }
+ 
+@@ -185,8 +185,8 @@ DesDecrypt(cipher, clear)
+ u_char *cipher;	/* IN  8 octets */
+ u_char *clear;	/* OUT 8 octets */
+ {
+-	des_ecb_encrypt((des_cblock *)cipher, (des_cblock *)clear,
+-	    key_schedule, 0);
++	DES_ecb_encrypt((DES_cblock *)cipher, (DES_cblock *)clear,
++	    &key_schedule, 0);
+ 	return (1);
+ }
+ 
diff --git a/poky/meta/recipes-connectivity/ppp/ppp_2.4.7.bb b/poky/meta/recipes-connectivity/ppp/ppp_2.4.7.bb
index a5f764f..644cde4 100644
--- a/poky/meta/recipes-connectivity/ppp/ppp_2.4.7.bb
+++ b/poky/meta/recipes-connectivity/ppp/ppp_2.4.7.bb
@@ -4,7 +4,7 @@
 SECTION = "console/network"
 HOMEPAGE = "http://samba.org/ppp/"
 BUGTRACKER = "http://ppp.samba.org/cgi-bin/ppp-bugs"
-DEPENDS = "libpcap"
+DEPENDS = "libpcap openssl virtual/crypt"
 LICENSE = "BSD & GPLv2+ & LGPLv2+ & PD"
 LIC_FILES_CHKSUM = "file://pppd/ccp.c;beginline=1;endline=29;md5=e2c43fe6e81ff77d87dc9c290a424dea \
                     file://pppd/plugins/passprompt.c;beginline=1;endline=10;md5=3bcbcdbf0e369c9a3e0b8c8275b065d8 \
@@ -32,6 +32,7 @@
            file://fix-CVE-2015-3310.patch \
            file://0001-pppoe-include-netinet-in.h-before-linux-in.h.patch \
            file://0001-ppp-Remove-unneeded-include.patch \
+           file://ppp-2.4.7-DES-openssl.patch \
 "
 
 SRC_URI_append_libc-musl = "\
@@ -49,7 +50,7 @@
 # Package Makefile computes CFLAGS, referencing COPTS.
 # Typically hard-coded to '-O2 -g' in the Makefile's.
 #
-EXTRA_OEMAKE += ' COPTS="${CFLAGS} -I${S}/include"'
+EXTRA_OEMAKE += ' COPTS="${CFLAGS} -I${STAGING_INCDIR}/openssl -I${S}/include"'
 
 do_configure () {
 	oe_runconf
@@ -80,6 +81,10 @@
 	chmod u+s ${D}${sbindir}/pppd
 }
 
+do_install_append_libc-musl () {
+	install -Dm 0644 ${S}/include/net/ppp_defs.h ${D}${includedir}/net/ppp_defs.h
+}
+
 CONFFILES_${PN} = "${sysconfdir}/ppp/pap-secrets ${sysconfdir}/ppp/chap-secrets ${sysconfdir}/ppp/options"
 PACKAGES =+ "${PN}-oa ${PN}-oe ${PN}-radius ${PN}-winbind ${PN}-minconn ${PN}-password ${PN}-l2tp ${PN}-tools"
 FILES_${PN}        = "${sysconfdir} ${bindir} ${sbindir}/chat ${sbindir}/pppd ${systemd_unitdir}/system/ppp@.service"
diff --git a/poky/meta/recipes-connectivity/socat/socat_1.7.3.2.bb b/poky/meta/recipes-connectivity/socat/socat_1.7.3.2.bb
index 6373dd4..927df74 100644
--- a/poky/meta/recipes-connectivity/socat/socat_1.7.3.2.bb
+++ b/poky/meta/recipes-connectivity/socat/socat_1.7.3.2.bb
@@ -7,11 +7,10 @@
 
 DEPENDS = "openssl readline"
 
-LICENSE = "GPL-2.0-with-OpenSSL-exception"
+LICENSE = "GPL-2.0+-with-OpenSSL-exception"
 LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
                     file://README;beginline=257;endline=287;md5=338c05eadd013872abb1d6e198e10a3f"
 
-
 SRC_URI = "http://www.dest-unreach.org/socat/download/socat-${PV}.tar.bz2 \
            file://Makefile.in-fix-for-parallel-build.patch \
            file://0001-define-NETDB_INTERNAL-to-1-if-not-available.patch \
@@ -26,9 +25,23 @@
 EXTRA_AUTORECONF += "--exclude=autoheader"
 
 EXTRA_OECONF += "ac_cv_have_z_modifier=yes \
-        ac_cv_header_bsd_libutil_h=no \
+                 ac_cv_header_bsd_libutil_h=no \
+                 sc_cv_termios_ispeed=no \
+                 ${TERMBITS_SHIFTS} \
 "
 
+TERMBITS_SHIFTS ?= "sc_cv_sys_crdly_shift=9 \
+                    sc_cv_sys_tabdly_shift=11 \
+                    sc_cv_sys_csize_shift=4"
+
+TERMBITS_SHIFTS_powerpc = "sc_cv_sys_crdly_shift=12 \
+                           sc_cv_sys_tabdly_shift=10 \
+                           sc_cv_sys_csize_shift=8"
+
+TERMBITS_SHIFTS_powerpc64 = "sc_cv_sys_crdly_shift=12 \
+                             sc_cv_sys_tabdly_shift=10 \
+                             sc_cv_sys_csize_shift=8"
+
 PACKAGECONFIG_class-target ??= "tcp-wrappers"
 PACKAGECONFIG ??= ""
 PACKAGECONFIG[tcp-wrappers] = "--enable-libwrap,--disable-libwrap,tcp-wrappers"
diff --git a/poky/meta/recipes-connectivity/wireless-tools/wireless-tools/avoid_strip.patch b/poky/meta/recipes-connectivity/wireless-tools/wireless-tools/avoid_strip.patch
deleted file mode 100644
index f34e243..0000000
--- a/poky/meta/recipes-connectivity/wireless-tools/wireless-tools/avoid_strip.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-wireless_tools: Avoid stripping iwmulticall
-
-Upstream-Status: Inappropriate [other]
-  The removed code was from upstream.
-
-Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
-
-diff -ur wireless_tools.29.orig/Makefile wireless_tools.29/Makefile
---- wireless_tools.29.orig/Makefile	2011-06-18 11:35:12.183907453 -0500
-+++ wireless_tools.29/Makefile	2011-06-18 11:38:09.995907985 -0500
-@@ -135,9 +135,8 @@
- 
- macaddr: macaddr.o $(IWLIB)
- 
--# Always do symbol stripping here
- iwmulticall: iwmulticall.o
--	$(CC) $(LDFLAGS) -Wl,-s $(XCFLAGS) -o $@ $^ $(LIBS)
-+	$(CC) $(LDFLAGS) $(STRIPFLAGS) $(XCFLAGS) -o $@ $^ $(LIBS)
- 
- # It's a kind of magic...
- wireless.h:
diff --git a/poky/meta/recipes-connectivity/wireless-tools/wireless-tools/ldflags.patch b/poky/meta/recipes-connectivity/wireless-tools/wireless-tools/ldflags.patch
deleted file mode 100644
index 6c0d8cb..0000000
--- a/poky/meta/recipes-connectivity/wireless-tools/wireless-tools/ldflags.patch
+++ /dev/null
@@ -1,22 +0,0 @@
-wireless-tools: Remove QA warning: No GNU_HASH in the elf binary
-
-Upstream-Status: Inappropriate [other]
-  Useful within bitbake environment only.
-
-Signed-off-by: Muhammad Shakeel <muhammad_shakeel@mentor.com>
-
----
- Makefile |    2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
---- wireless_tools.29.orig/Makefile
-+++ wireless_tools.29/Makefile
-@@ -144,7 +144,7 @@ wireless.h:
- 
- # Compilation of the dynamic library
- $(DYNAMIC): $(OBJS:.o=.so)
--	$(CC) -shared -o $@ -Wl,-soname,$@ $(STRIPFLAGS) $(LIBS) -lc $^
-+	$(CC) -shared -o $@ -Wl,-soname,$@ $(LDFLAGS) $(STRIPFLAGS) $(LIBS) -lc $^
- 
- # Compilation of the static library
- $(STATIC): $(OBJS:.o=.so)
diff --git a/poky/meta/recipes-connectivity/wireless-tools/wireless-tools/man.patch b/poky/meta/recipes-connectivity/wireless-tools/wireless-tools/man.patch
deleted file mode 100644
index 6a757da..0000000
--- a/poky/meta/recipes-connectivity/wireless-tools/wireless-tools/man.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-Upstream-Status: Inappropriate [configuration]
-
-Index: wireless_tools.30/Makefile
-===================================================================
---- wireless_tools.30.orig/Makefile	2014-02-01 00:21:04.148463382 -0800
-+++ wireless_tools.30/Makefile	2014-02-01 00:23:35.448072279 -0800
-@@ -76,7 +76,7 @@
- INSTALL_DIR= $(PREFIX)/sbin
- INSTALL_LIB= $(PREFIX)/lib
- INSTALL_INC= $(PREFIX)/include
--INSTALL_MAN= $(PREFIX)/man
-+INSTALL_MAN= $(PREFIX)/share/man
- 
- # Various commands
- RM = rm -f
diff --git a/poky/meta/recipes-connectivity/wireless-tools/wireless-tools/remove.ldconfig.call.patch b/poky/meta/recipes-connectivity/wireless-tools/wireless-tools/remove.ldconfig.call.patch
deleted file mode 100644
index 3a22c3f..0000000
--- a/poky/meta/recipes-connectivity/wireless-tools/wireless-tools/remove.ldconfig.call.patch
+++ /dev/null
@@ -1,19 +0,0 @@
-When /etc/ld.so.cache is writeable by user running bitbake then it creates invalid cache 
-(in my case libstdc++.so cannot be found after building zlib(-native) and I have to call 
-touch */libstdc++.so && /sbin/ldconfig to fix it.
-
-So remove ldconfig call from make install-libs
-
-Upstream-Status: Inappropriate [disable feature]
-
-diff -uNr wireless_tools.29.orig/Makefile wireless_tools.29/Makefile
---- wireless_tools.29.orig/Makefile	2007-09-18 01:56:46.000000000 +0200
-+++ wireless_tools.29/Makefile	2012-02-15 20:46:41.780763514 +0100
-@@ -163,7 +163,6 @@
- 	install -m 755 $(DYNAMIC) $(INSTALL_LIB)
- 	ln -sfn $(DYNAMIC) $(INSTALL_LIB)/$(DYNAMIC_LINK)
- 	@echo "*** Don't forget to add $(INSTALL_LIB) to /etc/ld.so.conf, and run ldconfig as root. ***"
--	@$(LDCONFIG) || echo "*** Could not run ldconfig ! ***"
- 
- # Install the static library
- install-static:: $(STATIC)
diff --git a/poky/meta/recipes-connectivity/wireless-tools/wireless-tools_30.pre9.bb b/poky/meta/recipes-connectivity/wireless-tools/wireless-tools_30.pre9.bb
deleted file mode 100644
index 0a34207..0000000
--- a/poky/meta/recipes-connectivity/wireless-tools/wireless-tools_30.pre9.bb
+++ /dev/null
@@ -1,50 +0,0 @@
-SUMMARY = "Tools for the Linux Standard Wireless Extension Subsystem"
-HOMEPAGE = "https://hewlettpackard.github.io/wireless-tools/Tools.html"
-LICENSE = "GPLv2 & (LGPLv2.1 | MPL-1.1 | BSD)"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
-			file://iwconfig.c;beginline=1;endline=12;md5=cf710eb1795c376eb10ea4ff04649caf \
-			file://iwevent.c;beginline=59;endline=72;md5=d66a10026d4394f0a5b1c5587bce4537 \
-			file://sample_enc.c;beginline=1;endline=4;md5=838372be07874260b566bae2f6ed33b6"
-SECTION = "base"
-PE = "1"
-
-SRC_URI = "https://hewlettpackard.github.io/wireless-tools/wireless_tools.${PV}.tar.gz \
-           file://remove.ldconfig.call.patch \
-           file://man.patch \
-           file://avoid_strip.patch \
-           file://ldflags.patch \
-          "
-SRC_URI[md5sum] = "ca91ba7c7eff9bfff6926b1a34a4697d"
-SRC_URI[sha256sum] = "abd9c5c98abf1fdd11892ac2f8a56737544fe101e1be27c6241a564948f34c63"
-
-UPSTREAM_CHECK_URI = "https://hewlettpackard.github.io/wireless-tools/Tools.html"
-UPSTREAM_CHECK_REGEX = "wireless_tools\.(?P<pver>(\d+)(\..*|))\.tar\.gz"
-
-S = "${WORKDIR}/wireless_tools.30"
-
-CFLAGS =+ "-I${S}"
-EXTRA_OEMAKE = "-e 'BUILD_SHARED=y' \
-		'INSTALL_DIR=${D}${base_sbindir}' \
-		'INSTALL_LIB=${D}${libdir}' \
-		'INSTALL_INC=${D}${includedir}' \
-		'INSTALL_MAN=${D}${mandir}'"
-
-do_compile() {
-	oe_runmake all libiw.a
-}
-
-do_install() {
-	oe_runmake PREFIX=${D} install-iwmulticall install-dynamic install-man install-hdr
-	install -d ${D}${sbindir}
-	install -m 0755 ifrename ${D}${sbindir}/ifrename
-}
-
-PACKAGES = "libiw libiw-dev libiw-doc ifrename-doc ifrename ${PN} ${PN}-doc ${PN}-dbg"
-
-FILES_libiw = "${libdir}/*.so.*"
-FILES_libiw-dev = "${libdir}/*.a ${libdir}/*.so ${includedir}"
-FILES_libiw-doc = "${mandir}/man7"
-FILES_ifrename = "${sbindir}/ifrename"
-FILES_ifrename-doc = "${mandir}/man8/ifrename.8 ${mandir}/man5/iftab.5"
-FILES_${PN} = "${bindir} ${sbindir}/iw* ${base_sbindir} ${base_bindir} ${sysconfdir}/network"
-FILES_${PN}-doc = "${mandir}"
diff --git a/poky/meta/recipes-core/base-files/base-files/profile b/poky/meta/recipes-core/base-files/base-files/profile
index a062028..9e4283e 100644
--- a/poky/meta/recipes-core/base-files/base-files/profile
+++ b/poky/meta/recipes-core/base-files/base-files/profile
@@ -20,14 +20,12 @@
 	unset i
 fi
 
-if command -v resize >/dev/null && command -v tty >/dev/null; then
-	# Make sure we are on a serial console (i.e. the device used starts with
-	# /dev/tty[A-z]), otherwise we confuse e.g. the eclipse launcher which
-	# tries do use ssh
-	case $(tty) in
-		/dev/tty[A-z]*) resize >/dev/null;;
-	esac
-fi
+# Make sure we are on a serial console (i.e. the device used starts with
+# /dev/tty[A-z]), otherwise we confuse e.g. the eclipse launcher which tries do
+# use ssh
+case $(tty 2>/dev/null) in
+	/dev/tty[A-z]*) [ -x @BINDIR@/resize ] && @BINDIR@/resize >/dev/null;;
+esac
 
 export PATH PS1 OPIEDIR QPEDIR QTDIR EDITOR TERM
 
diff --git a/poky/meta/recipes-core/base-files/base-files_3.0.14.bb b/poky/meta/recipes-core/base-files/base-files_3.0.14.bb
index a6963ba..6e75652 100644
--- a/poky/meta/recipes-core/base-files/base-files_3.0.14.bb
+++ b/poky/meta/recipes-core/base-files/base-files_3.0.14.bb
@@ -125,6 +125,7 @@
 	install -m 0644 ${WORKDIR}/usbd ${D}${sysconfdir}/default/usbd
 	install -m 0644 ${WORKDIR}/profile ${D}${sysconfdir}/profile
 	sed -i 's#ROOTHOME#${ROOT_HOME}#' ${D}${sysconfdir}/profile
+        sed -i 's#@BINDIR@#${bindir}#g' ${D}${sysconfdir}/profile
 	install -m 0644 ${WORKDIR}/shells ${D}${sysconfdir}/shells
 	install -m 0755 ${WORKDIR}/share/dot.profile ${D}${sysconfdir}/skel/.profile
 	install -m 0755 ${WORKDIR}/share/dot.bashrc ${D}${sysconfdir}/skel/.bashrc
diff --git a/poky/meta/recipes-core/busybox/busybox-inittab_1.27.2.bb b/poky/meta/recipes-core/busybox/busybox-inittab_1.29.2.bb
similarity index 100%
rename from poky/meta/recipes-core/busybox/busybox-inittab_1.27.2.bb
rename to poky/meta/recipes-core/busybox/busybox-inittab_1.29.2.bb
diff --git a/poky/meta/recipes-core/busybox/busybox.inc b/poky/meta/recipes-core/busybox/busybox.inc
index f1b09d9..09433dd 100644
--- a/poky/meta/recipes-core/busybox/busybox.inc
+++ b/poky/meta/recipes-core/busybox/busybox.inc
@@ -3,7 +3,7 @@
 HOMEPAGE = "http://www.busybox.net"
 BUGTRACKER = "https://bugs.busybox.net/"
 
-DEPENDS += "kern-tools-native"
+DEPENDS += "kern-tools-native virtual/crypt"
 
 # bzip2 applet in busybox is based on lightly-modified bzip2 source
 # the GPL is version 2 only
@@ -41,12 +41,13 @@
 SYSTEMD_PACKAGES = "${PN}-syslog"
 SYSTEMD_SERVICE_${PN}-syslog = "${@bb.utils.contains('SRC_URI', 'file://syslog.cfg', 'busybox-syslog.service', '', d)}"
 
+RDEPENDS_${PN}-syslog = "busybox"
 CONFFILES_${PN}-syslog = "${sysconfdir}/syslog-startup.conf"
 RCONFLICTS_${PN}-syslog = "rsyslog sysklogd syslog-ng"
 
 CONFFILES_${PN}-mdev = "${sysconfdir}/mdev.conf"
 
-RRECOMMENDS_${PN} = "${PN}-syslog ${PN}-udhcpc"
+RRECOMMENDS_${PN} = "${PN}-udhcpc"
 
 RDEPENDS_${PN} = "${@["", "busybox-inittab"][(d.getVar('VIRTUAL-RUNTIME_init_manager') == 'busybox')]}"
 
@@ -116,13 +117,13 @@
 		${S}/.config
 	sed -i -e '${configmangle}' ${S}/.config
 	if test ${DO_IPv4} -eq 0 && test ${DO_IPv6} -eq 0; then
-	  # disable networking applets
-	  mv ${S}/.config ${S}/.config.oe-tmp
-	  awk 'BEGIN{net=0}
-	  /^# Networking Utilities/{net=1}
-	  /^#$/{if(net){net=net+1}}
-	  {if(net==2&&$0 !~ /^#/&&$1){print("# "$1" is not set")}else{print}}' \
-		  ${S}/.config.oe-tmp > ${S}/.config
+		# disable networking applets
+		mv ${S}/.config ${S}/.config.oe-tmp
+		awk 'BEGIN{net=0}
+		/^# Networking Utilities/{net=1}
+		/^#$/{if(net){net=net+1}}
+		{if(net==2&&$0 !~ /^#/&&$1){print("# "$1" is not set")}else{print}}' \
+		${S}/.config.oe-tmp > ${S}/.config
 	fi
 	sed -i 's/CONFIG_IFUPDOWN_UDHCPC_CMD_OPTIONS="-R -n"/CONFIG_IFUPDOWN_UDHCPC_CMD_OPTIONS="-R -b"/' ${S}/.config
 	sed -i 's|${DEBUG_PREFIX_MAP}||g' ${S}/.config
@@ -150,7 +151,7 @@
 		export KCONFIG_NOTIMESTAMP=1
 	fi
 	if [ "${BUSYBOX_SPLIT_SUID}" = "1" -a x`grep "CONFIG_FEATURE_INDIVIDUAL=y" .config` = x ]; then
-	# split the .config into two parts, and make two busybox binaries
+		# split the .config into two parts, and make two busybox binaries
 		if [ -e .config.orig ]; then
 			# Need to guard again an interrupted do_compile - restore any backup
 			cp .config.orig .config
@@ -209,6 +210,10 @@
 	sed -i "s:^/usr/bin/:BINDIR/:" busybox.links*
 	sed -i "s:^/usr/sbin/:SBINDIR/:" busybox.links*
 
+	# Move arch/link to BINDIR to match coreutils
+	sed -i "s:^BASE_BINDIR/arch:BINDIR/arch:" busybox.links*
+	sed -i "s:^BASE_BINDIR/link:BINDIR/link:" busybox.links*
+
 	sed -i "s:^BASE_BINDIR/:${base_bindir}/:" busybox.links*
 	sed -i "s:^BASE_SBINDIR/:${base_sbindir}/:" busybox.links*
 	sed -i "s:^BINDIR/:${bindir}/:" busybox.links*
@@ -250,8 +255,7 @@
 			ln -sf busybox ${D}${base_bindir}/busybox.nosuid
 		fi
 	else
-		install -d ${D}${base_bindir} ${D}${base_sbindir}
-		install -d ${D}${libdir} ${D}${bindir} ${D}${sbindir}
+		install -d ${D}${base_bindir} ${D}${bindir} ${D}${libdir}
 		cat busybox.links | while read FILE; do
 			NAME=`basename "$FILE"`
 			install -m 0755 "0_lib/$NAME" "${D}$FILE.${BPN}"
@@ -275,77 +279,76 @@
 		install -m 644 ${WORKDIR}/syslog-startup.conf ${D}${sysconfdir}/syslog-startup.conf
 		install -m 644 ${WORKDIR}/syslog.conf ${D}${sysconfdir}/syslog.conf
 	fi
-	if grep "CONFIG_CROND=y" ${B}/.config; then
+	if grep -q "CONFIG_CROND=y" ${B}/.config; then
 		install -m 0755 ${WORKDIR}/busybox-cron ${D}${sysconfdir}/init.d/
 	fi
-	if grep "CONFIG_HTTPD=y" ${B}/.config; then
+	if grep -q "CONFIG_HTTPD=y" ${B}/.config; then
 		install -m 0755 ${WORKDIR}/busybox-httpd ${D}${sysconfdir}/init.d/
 		install -d ${D}/srv/www
 	fi
-	if grep "CONFIG_UDHCPD=y" ${B}/.config; then
+	if grep -q "CONFIG_UDHCPD=y" ${B}/.config; then
 		install -m 0755 ${WORKDIR}/busybox-udhcpd ${D}${sysconfdir}/init.d/
 	fi
-	if grep "CONFIG_HWCLOCK=y" ${B}/.config; then
+	if grep -q "CONFIG_HWCLOCK=y" ${B}/.config; then
 		install -m 0755 ${WORKDIR}/hwclock.sh ${D}${sysconfdir}/init.d/
 	fi
-	if grep "CONFIG_UDHCPC=y" ${B}/.config; then
+	if grep -q "CONFIG_UDHCPC=y" ${B}/.config; then
 		install -d ${D}${sysconfdir}/udhcpc.d
 		install -d ${D}${datadir}/udhcpc
 		install -m 0755 ${WORKDIR}/simple.script ${D}${sysconfdir}/udhcpc.d/50default
 		sed -i "s:/SBIN_DIR/:${base_sbindir}/:" ${D}${sysconfdir}/udhcpc.d/50default
 		install -m 0755 ${WORKDIR}/default.script ${D}${datadir}/udhcpc/default.script
 	fi
-	if grep "CONFIG_INETD=y" ${B}/.config; then
+	if grep -q "CONFIG_INETD=y" ${B}/.config; then
 		install -m 0755 ${WORKDIR}/inetd ${D}${sysconfdir}/init.d/inetd.${BPN}
 		sed -i "s:/usr/sbin/:${sbindir}/:" ${D}${sysconfdir}/init.d/inetd.${BPN}
 		install -m 0644 ${WORKDIR}/inetd.conf ${D}${sysconfdir}/
 	fi
-        if grep "CONFIG_MDEV=y" ${B}/.config; then
-               install -m 0755 ${WORKDIR}/mdev ${D}${sysconfdir}/init.d/mdev
-               if grep "CONFIG_FEATURE_MDEV_CONF=y" ${B}/.config; then
-                       install -m 644 ${WORKDIR}/mdev.conf ${D}${sysconfdir}/mdev.conf
-                       install -d ${D}${sysconfdir}/mdev
-                       install -m 0755 ${WORKDIR}/find-touchscreen.sh ${D}${sysconfdir}/mdev
-                       install -m 0755 ${WORKDIR}/mdev-mount.sh ${D}${sysconfdir}/mdev
-               fi
+	if grep -q "CONFIG_MDEV=y" ${B}/.config; then
+		install -m 0755 ${WORKDIR}/mdev ${D}${sysconfdir}/init.d/mdev
+		if grep "CONFIG_FEATURE_MDEV_CONF=y" ${B}/.config; then
+			install -m 644 ${WORKDIR}/mdev.conf ${D}${sysconfdir}/mdev.conf
+			install -d ${D}${sysconfdir}/mdev
+			install -m 0755 ${WORKDIR}/find-touchscreen.sh ${D}${sysconfdir}/mdev
+			install -m 0755 ${WORKDIR}/mdev-mount.sh ${D}${sysconfdir}/mdev
+		fi
 	fi
-        if grep "CONFIG_INIT=y" ${B}/.config; then
-                install -D -m 0777 ${WORKDIR}/rcS ${D}${sysconfdir}/init.d/rcS
-                install -D -m 0777 ${WORKDIR}/rcK ${D}${sysconfdir}/init.d/rcK
-                install -D -m 0755 ${WORKDIR}/runlevel ${D}${base_sbindir}/runlevel
-        fi
+	if grep -q "CONFIG_INIT=y" ${B}/.config; then
+		install -D -m 0777 ${WORKDIR}/rcS ${D}${sysconfdir}/init.d/rcS
+		install -D -m 0777 ${WORKDIR}/rcK ${D}${sysconfdir}/init.d/rcK
+	fi
 
-    if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
-        if grep -q "CONFIG_KLOGD=y" ${B}/.config; then
-            install -d ${D}${systemd_unitdir}/system
-            sed 's,@base_sbindir@,${base_sbindir},g' < ${WORKDIR}/busybox-klogd.service.in \
-            > ${D}${systemd_unitdir}/system/busybox-klogd.service
-        fi
+	if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
+		if grep -q "CONFIG_KLOGD=y" ${B}/.config; then
+			install -d ${D}${systemd_unitdir}/system
+			sed 's,@base_sbindir@,${base_sbindir},g' < ${WORKDIR}/busybox-klogd.service.in \
+			> ${D}${systemd_unitdir}/system/busybox-klogd.service
+		fi
 
-        if grep -q "CONFIG_SYSLOGD=y" ${B}/.config; then
-            install -d ${D}${systemd_unitdir}/system
-            sed 's,@base_sbindir@,${base_sbindir},g' < ${WORKDIR}/busybox-syslog.service.in \
-		> ${D}${systemd_unitdir}/system/busybox-syslog.service
-            if  [ ! -e ${D}${systemd_unitdir}/system/busybox-klogd.service ] ; then
-                sed -i '/klog/d' ${D}${systemd_unitdir}/system/busybox-syslog.service
-            fi
-            if [ -f ${WORKDIR}/busybox-syslog.default ] ; then
-		install -d ${D}${sysconfdir}/default
-		install -m 0644 ${WORKDIR}/busybox-syslog.default ${D}${sysconfdir}/default/busybox-syslog
-            fi
-        fi
-    fi
+		if grep -q "CONFIG_SYSLOGD=y" ${B}/.config; then
+			install -d ${D}${systemd_unitdir}/system
+			sed 's,@base_sbindir@,${base_sbindir},g' < ${WORKDIR}/busybox-syslog.service.in \
+			> ${D}${systemd_unitdir}/system/busybox-syslog.service
+			if  [ ! -e ${D}${systemd_unitdir}/system/busybox-klogd.service ] ; then
+				sed -i '/klog/d' ${D}${systemd_unitdir}/system/busybox-syslog.service
+			fi
+			if [ -f ${WORKDIR}/busybox-syslog.default ] ; then
+				install -d ${D}${sysconfdir}/default
+				install -m 0644 ${WORKDIR}/busybox-syslog.default ${D}${sysconfdir}/default/busybox-syslog
+			fi
+		fi
+	fi
 
-    # Remove the sysvinit specific configuration file for systemd systems to avoid confusion
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'false', 'true', d)}; then
-	rm -f ${D}${sysconfdir}/syslog-startup.conf
-    fi
+	# Remove the sysvinit specific configuration file for systemd systems to avoid confusion
+	if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'false', 'true', d)}; then
+		rm -f ${D}${sysconfdir}/syslog-startup.conf
+	fi
 }
 
 do_install_ptest () {
-        cp -r ${B}/testsuite ${D}${PTEST_PATH}/
-        cp ${B}/.config      ${D}${PTEST_PATH}/
-        ln -s /bin/busybox   ${D}${PTEST_PATH}/busybox
+	cp -r ${B}/testsuite ${D}${PTEST_PATH}/
+	cp ${B}/.config      ${D}${PTEST_PATH}/
+	ln -s /bin/busybox   ${D}${PTEST_PATH}/busybox
 }
 
 inherit update-alternatives
@@ -368,7 +371,10 @@
             # Match coreutils
             if alt_name == '[':
                 alt_name = 'lbracket'
-            d.appendVar('ALTERNATIVE_%s' % (pn), ' ' + alt_name)
+            if alt_name == 'klogd' or alt_name == 'syslogd':
+                d.appendVar('ALTERNATIVE_%s-syslog' % (pn), ' ' + alt_name)
+            else:
+                d.appendVar('ALTERNATIVE_%s' % (pn), ' ' + alt_name)
             d.setVarFlag('ALTERNATIVE_LINK_NAME', alt_name, alt_link_name)
             if os.path.exists('%s%s' % (dvar, target)):
                 d.setVarFlag('ALTERNATIVE_TARGET', alt_name, target)
diff --git a/poky/meta/recipes-core/busybox/busybox/CVE-2011-5325.patch b/poky/meta/recipes-core/busybox/busybox/CVE-2011-5325.patch
deleted file mode 100755
index 0926107..0000000
--- a/poky/meta/recipes-core/busybox/busybox/CVE-2011-5325.patch
+++ /dev/null
@@ -1,481 +0,0 @@
-busybox-1.27.2: Fix CVE-2011-5325
-
-[No upstream tracking] -- https://bugs.busybox.net/show_bug.cgi?id=8411
-
-libarchive: do not extract unsafe symlinks
-
-Prevent unsafe links extracting unless env variable $EXTRACT_UNSAFE_SYMLINKS=1
-is not set. Untarring file with -C DESTDIR parameter could be extracted with
-unwanted symlinks. This doesn't feel right, and IIRC GNU tar doesn't do that.
-Include necessary changes from previous commits.
-
-Upstream-Status: Backport [https://git.busybox.net/busybox/commit/?id=bc9bbeb2b81001e8731cd2ae501c8fccc8d87cc7]
-CVE: CVE-2011-5325
-bug: 8411
-Signed-off-by: Radovan Scasny <radovan.scasny@siemens.com>
-Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
-
-diff --git a/archival/libarchive/Kbuild.src b/archival/libarchive/Kbuild.src
-index 942e755..e1a8a75 100644
---- a/archival/libarchive/Kbuild.src
-+++ b/archival/libarchive/Kbuild.src
-@@ -12,6 +12,8 @@ COMMON_FILES:= \
- 	data_extract_all.o \
- 	data_extract_to_stdout.o \
- \
-+	unsafe_symlink_target.o \
-+\
- 	filter_accept_all.o \
- 	filter_accept_list.o \
- 	filter_accept_reject_list.o \
-diff --git a/archival/libarchive/data_extract_all.c b/archival/libarchive/data_extract_all.c
-index 1830ffb..b828b65 100644
---- a/archival/libarchive/data_extract_all.c
-+++ b/archival/libarchive/data_extract_all.c
-@@ -128,10 +128,9 @@ void FAST_FUNC data_extract_all(archive_handle_t *archive_handle)
- 		res = link(hard_link, dst_name);
- 		if (res != 0 && !(archive_handle->ah_flags & ARCHIVE_EXTRACT_QUIET)) {
- 			/* shared message */
--			bb_perror_msg("can't create %slink "
--					"%s to %s", "hard",
--					dst_name,
--					hard_link);
-+			bb_perror_msg("can't create %slink '%s' to '%s'",
-+					 "hard", dst_name, hard_link
-+			);
- 		}
- 		/* Hardlinks have no separate mode/ownership, skip chown/chmod */
- 		goto ret;
-@@ -178,15 +177,17 @@ void FAST_FUNC data_extract_all(archive_handle_t *archive_handle)
- 	case S_IFLNK:
- 		/* Symlink */
- //TODO: what if file_header->link_target == NULL (say, corrupted tarball?)
--		res = symlink(file_header->link_target, dst_name);
--		if (res != 0
--		 && !(archive_handle->ah_flags & ARCHIVE_EXTRACT_QUIET)
--		) {
--			/* shared message */
--			bb_perror_msg("can't create %slink "
--				"%s to %s", "sym",
--				dst_name,
--				file_header->link_target);
-+		if (!unsafe_symlink_target(file_header->link_target)) {
-+			res = symlink(file_header->link_target, dst_name);
-+			if (res != 0
-+				&& !(archive_handle->ah_flags & ARCHIVE_EXTRACT_QUIET)
-+			) {
-+						/* shared message */
-+						bb_perror_msg("can't create %slink '%s' to '%s'",
-+							"sym",
-+							dst_name, file_header->link_target
-+						);
-+			}
- 		}
- 		break;
- 	case S_IFSOCK:
-diff --git a/archival/libarchive/unsafe_symlink_target.c b/archival/libarchive/unsafe_symlink_target.c
-new file mode 100644
-index 0000000..ee46e28
---- /dev/null
-+++ b/archival/libarchive/unsafe_symlink_target.c
-@@ -0,0 +1,48 @@
-+/* vi: set sw=4 ts=4: */
-+/*
-+ * Licensed under GPLv2 or later, see file LICENSE in this source tree.
-+ */
-+#include "libbb.h"
-+#include "bb_archive.h"
-+
-+int FAST_FUNC unsafe_symlink_target(const char *target)
-+{
-+	const char *dot;
-+
-+	if (target[0] == '/') {
-+		const char *var;
-+unsafe:
-+		var = getenv("EXTRACT_UNSAFE_SYMLINKS");
-+		if (var) {
-+			if (LONE_CHAR(var, '1'))
-+				return 0; /* pretend it's safe */
-+			return 1; /* "UNSAFE!" */
-+		}
-+		bb_error_msg("skipping unsafe symlink to '%s' in archive,"
-+			" set %s=1 to extract",
-+			target,
-+			"EXTRACT_UNSAFE_SYMLINKS"
-+		);
-+		/* Prevent further messages */
-+		setenv("EXTRACT_UNSAFE_SYMLINKS", "0", 0);
-+		return 1; /* "UNSAFE!" */
-+	}
-+
-+	dot = target;
-+	for (;;) {
-+		dot = strchr(dot, '.');
-+			if (!dot)
-+				return 0; /* safe target */
-+
-+			/* Is it a path component starting with ".."? */
-+			if ((dot[1] == '.')
-+				&& (dot == target || dot[-1] == '/')
-+					/* Is it exactly ".."? */
-+				&& (dot[2] == '/' || dot[2] == '\0')
-+			) {
-+				goto unsafe;
-+			}
-+			/* NB: it can even be trailing ".", should only add 1 */
-+			dot += 1;
-+	}
-+}
-\ No newline at end of file
-diff --git a/archival/unzip.c b/archival/unzip.c
-index 9037262..270e261 100644
---- a/archival/unzip.c
-+++ b/archival/unzip.c
-@@ -335,6 +335,44 @@ static void unzip_create_leading_dirs(const char *fn)
- 	free(name);
- }
- 
-+static void unzip_extract_symlink(zip_header_t *zip, const char *dst_fn)
-+{
-+	char *target;
-+
-+	if (zip->fmt.ucmpsize > 0xfff) /* no funny business please */
-+		bb_error_msg_and_die("bad archive");
-+
-+	if (zip->fmt.method == 0) {
-+		/* Method 0 - stored (not compressed) */
-+		target = xzalloc(zip->fmt.ucmpsize + 1);
-+		xread(zip_fd, target, zip->fmt.ucmpsize);
-+	} else {
-+#if 1
-+		bb_error_msg_and_die("compressed symlink is not supported");
-+#else
-+		transformer_state_t xstate;
-+		init_transformer_state(&xstate);
-+		xstate.mem_output_size_max = zip->fmt.ucmpsize;
-+		/* ...unpack... */
-+		if (!xstate.mem_output_buf)
-+			WTF();
-+		target = xstate.mem_output_buf;
-+		target = xrealloc(target, xstate.mem_output_size + 1);
-+		target[xstate.mem_output_size] = '\0';
-+#endif
-+	}
-+	if (!unsafe_symlink_target(target)) {
-+//TODO: libbb candidate
-+		if (symlink(target, dst_fn)) {
-+			/* shared message */
-+			bb_perror_msg_and_die("can't create %slink '%s' to '%s'",
-+				"sym", dst_fn, target
-+			);
-+		}
-+	}
-+	free(target);
-+}
-+
- static void unzip_extract(zip_header_t *zip, int dst_fd)
- {
- 	transformer_state_t xstate;
-@@ -813,7 +851,7 @@ int unzip_main(int argc, char **argv)
- 		}
-  check_file:
- 		/* Extract file */
--		if (stat(dst_fn, &stat_buf) == -1) {
-+		if (lstat(dst_fn, &stat_buf) == -1) {
- 			/* File does not exist */
- 			if (errno != ENOENT) {
- 				bb_perror_msg_and_die("can't stat '%s'", dst_fn);
-@@ -834,6 +872,7 @@ int unzip_main(int argc, char **argv)
- 			goto do_open_and_extract;
- 		printf("replace %s? [y]es, [n]o, [A]ll, [N]one, [r]ename: ", dst_fn);
- 		my_fgets80(key_buf);
-+//TODO: redo lstat + ISREG check! user input could have taken a long time!
- 
- 		switch (key_buf[0]) {
- 		case 'A':
-@@ -842,7 +881,8 @@ int unzip_main(int argc, char **argv)
-  do_open_and_extract:
- 			unzip_create_leading_dirs(dst_fn);
- #if ENABLE_FEATURE_UNZIP_CDF
--			dst_fd = xopen3(dst_fn, O_WRONLY | O_CREAT | O_TRUNC, file_mode);
-+			if (!S_ISLNK(file_mode))
-+				dst_fd = xopen3(dst_fn, O_WRONLY | O_CREAT | O_TRUNC, file_mode);
- #else
- 			dst_fd = xopen(dst_fn, O_WRONLY | O_CREAT | O_TRUNC);
- #endif
-@@ -852,10 +892,18 @@ int unzip_main(int argc, char **argv)
- 					? " extracting: %s\n"
- 					: */ "  inflating: %s\n", dst_fn);
- 			}
--			unzip_extract(&zip, dst_fd);
--			if (dst_fd != STDOUT_FILENO) {
--				/* closing STDOUT is potentially bad for future business */
--				close(dst_fd);
-+#if ENABLE_FEATURE_UNZIP_CDF
-+			if (S_ISLNK(file_mode)) {
-+				if (dst_fd != STDOUT_FILENO) /* no -p */
-+					unzip_extract_symlink(&zip, dst_fn);
-+			} else
-+#endif
-+			{
-+				unzip_extract(&zip, dst_fd);
-+				if (dst_fd != STDOUT_FILENO) {
-+					/* closing STDOUT is potentially bad for future business */
-+					close(dst_fd);
-+				};
- 			}
- 			break;
- 
-diff --git a/coreutils/link.c b/coreutils/link.c
-index ac3ef85..aab249d 100644
---- a/coreutils/link.c
-+++ b/coreutils/link.c
-@@ -32,9 +32,8 @@ int link_main(int argc UNUSED_PARAM, char **argv)
- 	argv += optind;
- 	if (link(argv[0], argv[1]) != 0) {
- 		/* shared message */
--		bb_perror_msg_and_die("can't create %slink "
--					"%s to %s", "hard",
--					argv[1], argv[0]
-+		bb_perror_msg_and_die("can't create %slink '%s' to '%s'",
-+					"hard",	argv[1], argv[0]
- 		);
- 	}
- 	return EXIT_SUCCESS;
-diff --git a/include/bb_archive.h b/include/bb_archive.h
-index 2b9c5f0..1e4da3c 100644
---- a/include/bb_archive.h
-+++ b/include/bb_archive.h
-@@ -196,6 +196,7 @@ void seek_by_jump(int fd, off_t amount) FAST_FUNC;
- void seek_by_read(int fd, off_t amount) FAST_FUNC;
- 
- const char *strip_unsafe_prefix(const char *str) FAST_FUNC;
-+int unsafe_symlink_target(const char *target) FAST_FUNC;
- 
- void data_align(archive_handle_t *archive_handle, unsigned boundary) FAST_FUNC;
- const llist_t *find_list_entry(const llist_t *list, const char *filename) FAST_FUNC;
-diff --git a/libbb/copy_file.c b/libbb/copy_file.c
-index 23c0f83..be90066 100644
---- a/libbb/copy_file.c
-+++ b/libbb/copy_file.c
-@@ -371,7 +371,10 @@ int FAST_FUNC copy_file(const char *source, const char *dest, int flags)
- 			int r = symlink(lpath, dest);
- 			free(lpath);
- 			if (r < 0) {
--				bb_perror_msg("can't create symlink '%s'", dest);
-+				/* shared message */
-+				bb_perror_msg("can't create %slink '%s' to '%s'",
-+					"sym", dest, lpath
-+				);
- 				return -1;
- 			}
- 			if (flags & FILEUTILS_PRESERVE_STATUS)
-diff --git a/testsuite/tar.tests b/testsuite/tar.tests
-index 9f7ce15..b7cd74c 100755
---- a/testsuite/tar.tests
-+++ b/testsuite/tar.tests
-@@ -10,9 +10,6 @@ unset LC_COLLATE
- unset LC_ALL
- umask 022
- 
--rm -rf tar.tempdir 2>/dev/null
--mkdir tar.tempdir && cd tar.tempdir || exit 1
--
- # testing "test name" "script" "expected result" "file input" "stdin"
- 
- testing "Empty file is not a tarball" '\
-@@ -53,6 +50,7 @@ dd if=/dev/zero bs=512 count=20 2>/dev/null | tar xvf - 2>&1; echo $?
- "" ""
- SKIP=
- 
-+mkdir tar.tempdir && cd tar.tempdir || exit 1
- # "tar cf test.tar input input_dir/ input_hard1 input_hard2 input_hard1 input_dir/ input":
- # GNU tar 1.26 records as hardlinks:
- #  input_hard2 -> input_hard1
-@@ -64,7 +62,6 @@ SKIP=
- # We also don't use "hrw-r--r--" notation for hardlinks in "tar tv" listing.
- optional FEATURE_TAR_CREATE FEATURE_LS_SORTFILES
- testing "tar hardlinks and repeated files" '\
--rm -rf input_* test.tar 2>/dev/null
- >input_hard1
- ln input_hard1 input_hard2
- mkdir input_dir
-@@ -95,10 +92,11 @@ drwxr-xr-x input_dir
- " \
- "" ""
- SKIP=
-+cd .. || exit 1; rm -rf tar.tempdir 2>/dev/null
- 
-+mkdir tar.tempdir && cd tar.tempdir || exit 1
- optional FEATURE_TAR_CREATE FEATURE_LS_SORTFILES
- testing "tar hardlinks mode" '\
--rm -rf input_* test.tar 2>/dev/null
- >input_hard1
- chmod 741 input_hard1
- ln input_hard1 input_hard2
-@@ -128,10 +126,11 @@ Ok: 0
- " \
- "" ""
- SKIP=
-+cd .. || exit 1; rm -rf tar.tempdir 2>/dev/null
- 
-+mkdir tar.tempdir && cd tar.tempdir || exit 1
- optional FEATURE_TAR_CREATE FEATURE_LS_SORTFILES
- testing "tar symlinks mode" '\
--rm -rf input_* test.tar 2>/dev/null
- >input_file
- chmod 741 input_file
- ln -s input_file input_soft
-@@ -159,10 +158,11 @@ lrwxrwxrwx input_file
- " \
- "" ""
- SKIP=
-+cd .. || exit 1; rm -rf tar.tempdir 2>/dev/null
- 
-+mkdir tar.tempdir && cd tar.tempdir || exit 1
- optional FEATURE_TAR_CREATE FEATURE_TAR_LONG_OPTIONS
- testing "tar --overwrite" "\
--rm -rf input_* test.tar 2>/dev/null
- ln input input_hard
- tar cf test.tar input_hard
- echo WRONG >input
-@@ -174,12 +174,13 @@ Ok
- " \
- "Ok\n" ""
- SKIP=
-+cd .. || exit 1; rm -rf tar.tempdir 2>/dev/null
- 
-+mkdir tar.tempdir && cd tar.tempdir || exit 1
- test x"$SKIP_KNOWN_BUGS" = x"" && {
- # Needs to be run under non-root for meaningful test
- optional FEATURE_TAR_CREATE
- testing "tar writing into read-only dir" '\
--rm -rf input_* test.tar 2>/dev/null
- mkdir input_dir
- >input_dir/input_file
- chmod 550 input_dir
-@@ -201,7 +202,9 @@ dr-xr-x--- input_dir
- "" ""
- SKIP=
- }
-+cd .. || exit 1; rm -rf tar.tempdir 2>/dev/null
- 
-+mkdir tar.tempdir && cd tar.tempdir || exit 1
- # Had a bug where on extract autodetect first "switched off" -z
- # and then failed to recognize .tgz extension
- optional FEATURE_TAR_CREATE FEATURE_SEAMLESS_GZ GUNZIP
-@@ -217,7 +220,9 @@ Ok
- " \
- "" ""
- SKIP=
-+cd .. || exit 1; rm -rf tar.tempdir 2>/dev/null
- 
-+mkdir tar.tempdir && cd tar.tempdir || exit 1
- # Do we detect XZ-compressed data (even w/o .tar.xz or txz extension)?
- # (the uuencoded hello_world.txz contains one empty file named "hello_world")
- optional UUDECODE FEATURE_TAR_AUTODETECT FEATURE_SEAMLESS_XZ
-@@ -236,7 +241,9 @@ AAAEWVo=
- ====
- "
- SKIP=
-+cd .. || exit 1; rm -rf tar.tempdir 2>/dev/null
- 
-+mkdir tar.tempdir && cd tar.tempdir || exit 1
- # On extract, everything up to and including last ".." component is stripped
- optional FEATURE_TAR_CREATE
- testing "tar strips /../ on extract" "\
-@@ -255,7 +262,9 @@ Ok
- " \
- "" ""
- SKIP=
-+cd .. || exit 1; rm -rf tar.tempdir 2>/dev/null
- 
-+mkdir tar.tempdir && cd tar.tempdir || exit 1
- # attack.tar.bz2 has symlink pointing to a system file
- # followed by a regular file with the same name
- # containing "root::0:0::/root:/bin/sh":
-@@ -270,6 +279,7 @@ optional UUDECODE FEATURE_TAR_AUTODETECT FEATURE_SEAMLESS_BZ2
- testing "tar does not extract into symlinks" "\
- >>/tmp/passwd && uudecode -o input && tar xf input 2>&1 && rm passwd; cat /tmp/passwd; echo \$?
- " "\
-+tar: skipping unsafe symlink to '/tmp/passwd' in archive, set EXTRACT_UNSAFE_SYMLINKS=1 to extract
- 0
- " \
- "" "\
-@@ -281,12 +291,15 @@ l4/V8LDoe90yiWJhOJvIypgEfxdyRThQkBVn/bI=
- ====
- "
- SKIP=
-+cd .. || exit 1; rm -rf tar.tempdir 2>/dev/null
-+
-+mkdir tar.tempdir && cd tar.tempdir || exit 1
- # And same with -k
- optional UUDECODE FEATURE_TAR_AUTODETECT FEATURE_SEAMLESS_BZ2
- testing "tar -k does not extract into symlinks" "\
- >>/tmp/passwd && uudecode -o input && tar xf input -k 2>&1 && rm passwd; cat /tmp/passwd; echo \$?
- " "\
--tar: can't open 'passwd': File exists
-+tar: skipping unsafe symlink to '/tmp/passwd' in archive, set EXTRACT_UNSAFE_SYMLINKS=1 to extract
- 0
- " \
- "" "\
-@@ -298,7 +311,9 @@ l4/V8LDoe90yiWJhOJvIypgEfxdyRThQkBVn/bI=
- ====
- "
- SKIP=
-+cd .. || exit 1; rm -rf tar.tempdir 2>/dev/null
- 
-+mkdir tar.tempdir && cd tar.tempdir || exit 1
- optional UNICODE_SUPPORT FEATURE_TAR_GNU_EXTENSIONS FEATURE_SEAMLESS_BZ2 FEATURE_TAR_AUTODETECT
- testing "Pax-encoded UTF8 names and symlinks" '\
- tar xvf ../tar.utf8.tar.bz2 2>&1; echo $?
-@@ -309,17 +324,45 @@ rm -rf etc usr
- ' "\
- etc/ssl/certs/3b2716e5.0
- etc/ssl/certs/EBG_Elektronik_Sertifika_Hizmet_Sağlayıcısı.pem
-+tar: skipping unsafe symlink to '/usr/share/ca-certificates/mozilla/EBG_Elektronik_Sertifika_Hizmet_Sağlayıcısı.crt' in archive, set EXTRACT_UNSAFE_SYMLINKS=1 to extract
- etc/ssl/certs/f80cc7f6.0
- usr/share/ca-certificates/mozilla/EBG_Elektronik_Sertifika_Hizmet_Sağlayıcısı.crt
- 0
- etc/ssl/certs/3b2716e5.0 -> EBG_Elektronik_Sertifika_Hizmet_Sağlayıcısı.pem
--etc/ssl/certs/EBG_Elektronik_Sertifika_Hizmet_Sağlayıcısı.pem -> /usr/share/ca-certificates/mozilla/EBG_Elektronik_Sertifika_Hizmet_Sağlayıcısı.crt
- etc/ssl/certs/f80cc7f6.0 -> EBG_Elektronik_Sertifika_Hizmet_Sağlayıcısı.pem
- " \
- "" ""
- SKIP=
-+cd .. || exit 1; rm -rf tar.tempdir 2>/dev/null
- 
--
--cd .. && rm -rf tar.tempdir || exit 1
-+mkdir tar.tempdir && cd tar.tempdir || exit 1
-+optional UUDECODE FEATURE_SEAMLESS_BZ2 FEATURE_TAR_AUTODETECT
-+testing "Symlink attack: create symlink and then write through it" '\
-+exec 2>&1
-+uudecode -o input && tar xvf input; echo $?
-+ls /tmp/bb_test_evilfile
-+ls bb_test_evilfile
-+ls symlink/bb_test_evilfile
-+' "\
-+anything.txt
-+symlink
-+tar: skipping unsafe symlink to '/tmp' in archive, set EXTRACT_UNSAFE_SYMLINKS=1 to extract
-+symlink/bb_test_evilfile
-+0
-+ls: /tmp/bb_test_evilfile: No such file or directory
-+ls: bb_test_evilfile: No such file or directory
-+symlink/bb_test_evilfile
-+" \
-+"" "\
-+begin-base64 644 tar_symlink_attack.tar.bz2
-+QlpoOTFBWSZTWZgs7bQAALT/hMmQAFBAAf+AEMAGJPPv32AAAIAIMAC5thlR
-+omAjAmCMADQT1BqNE0AEwAAjAEwElTKeo9NTR6h6gaeoA0DQNLVdwZZ5iNTk
-+AQwCAV6S00QFJYhrlfFkVCEDEGtgNVqYrI0uK3ggnt30gqk4e1TTQm5QIAKa
-+SJqzRGSFLMmOloHSAcvLiFxxRiQtQZF+qPxbo173ZDISOAoNoPN4PQPhBhKS
-+n8fYaKlioCTzL2oXYczyUUIP4u5IpwoSEwWdtoA=
-+====
-+"
-+SKIP=
-+cd .. || exit 1; rm -rf tar.tempdir 2>/dev/null
- 
- exit $FAILCOUNT
diff --git a/poky/meta/recipes-core/busybox/busybox/CVE-2017-15873.patch b/poky/meta/recipes-core/busybox/busybox/CVE-2017-15873.patch
deleted file mode 100644
index 5a027c9..0000000
--- a/poky/meta/recipes-core/busybox/busybox/CVE-2017-15873.patch
+++ /dev/null
@@ -1,95 +0,0 @@
-busybox-1.27.2: Fix CVE-2017-15873
-
-[No upstream tracking] -- https://bugs.busybox.net/show_bug.cgi?id=10431
-
-bunzip2: fix runCnt overflow
-
-The get_next_block function in archival/libarchive/decompress_bunzip2.c
-in BusyBox 1.27.2 has an Integer Overflow that may lead to a write 
-access violation.
-
-Upstream-Status: Backport [https://git.busybox.net/busybox/commit/?id=0402cb32df015d9372578e3db27db47b33d5c7b0]
-CVE: CVE-2017-15873
-bug: 10431
-Signed-off-by: Radovan Scasny <radovan.scasny@siemens.com>
-
-diff --git a/archival/libarchive/decompress_bunzip2.c b/archival/libarchive/decompress_bunzip2.c
-index 7cd18f5..bec89ed 100644
---- a/archival/libarchive/decompress_bunzip2.c
-+++ b/archival/libarchive/decompress_bunzip2.c
-@@ -156,15 +156,15 @@ static unsigned get_bits(bunzip_data *bd, int bits_wanted)
- static int get_next_block(bunzip_data *bd)
- {
- 	struct group_data *hufGroup;
--	int dbufCount, dbufSize, groupCount, *base, *limit, selector,
--		i, j, runPos, symCount, symTotal, nSelectors, byteCount[256];
--	int runCnt = runCnt; /* for compiler */
-+	int groupCount, *base, *limit, selector,
-+		i, j, symCount, symTotal, nSelectors, byteCount[256];
- 	uint8_t uc, symToByte[256], mtfSymbol[256], *selectors;
- 	uint32_t *dbuf;
- 	unsigned origPtr, t;
-+	unsigned dbufCount, runPos;
-+	unsigned runCnt = runCnt; /* for compiler */
- 
- 	dbuf = bd->dbuf;
--	dbufSize = bd->dbufSize;
- 	selectors = bd->selectors;
- 
- /* In bbox, we are ok with aborting through setjmp which is set up in start_bunzip */
-@@ -187,7 +187,7 @@ static int get_next_block(bunzip_data *bd)
- 	   it didn't actually work. */
- 	if (get_bits(bd, 1)) return RETVAL_OBSOLETE_INPUT;
- 	origPtr = get_bits(bd, 24);
--	if ((int)origPtr > dbufSize) return RETVAL_DATA_ERROR;
-+	if (origPtr > bd->dbufSize) return RETVAL_DATA_ERROR;
- 
- 	/* mapping table: if some byte values are never used (encoding things
- 	   like ascii text), the compression code removes the gaps to have fewer
-@@ -435,7 +435,14 @@ static int get_next_block(bunzip_data *bd)
- 			   symbols, but a run of length 0 doesn't mean anything in this
- 			   context).  Thus space is saved. */
- 			runCnt += (runPos << nextSym); /* +runPos if RUNA; +2*runPos if RUNB */
--			if (runPos < dbufSize) runPos <<= 1;
-+//The 32-bit overflow of runCnt wasn't yet seen, but probably can happen.
-+//This would be the fix (catches too large count way before it can overflow):
-+//			if (runCnt > bd->dbufSize) {
-+//				dbg("runCnt:%u > dbufSize:%u RETVAL_DATA_ERROR",
-+//						runCnt, bd->dbufSize);
-+//				return RETVAL_DATA_ERROR;
-+//			}
-+			if (runPos < bd->dbufSize) runPos <<= 1;
- 			goto end_of_huffman_loop;
- 		}
- 
-@@ -445,14 +452,15 @@ static int get_next_block(bunzip_data *bd)
- 		   literal used is the one at the head of the mtfSymbol array.) */
- 		if (runPos != 0) {
- 			uint8_t tmp_byte;
--			if (dbufCount + runCnt > dbufSize) {
--				dbg("dbufCount:%d+runCnt:%d %d > dbufSize:%d RETVAL_DATA_ERROR",
--						dbufCount, runCnt, dbufCount + runCnt, dbufSize);
-+			if (dbufCount + runCnt > bd->dbufSize) {
-+				dbg("dbufCount:%u+runCnt:%u %u > dbufSize:%u RETVAL_DATA_ERROR",
-+						dbufCount, runCnt, dbufCount + runCnt, bd->dbufSize);
- 				return RETVAL_DATA_ERROR;
- 			}
- 			tmp_byte = symToByte[mtfSymbol[0]];
- 			byteCount[tmp_byte] += runCnt;
--			while (--runCnt >= 0) dbuf[dbufCount++] = (uint32_t)tmp_byte;
-+			while ((int)--runCnt >= 0)
-+				dbuf[dbufCount++] = (uint32_t)tmp_byte;
- 			runPos = 0;
- 		}
- 
-@@ -466,7 +474,7 @@ static int get_next_block(bunzip_data *bd)
- 		   first symbol in the mtf array, position 0, would have been handled
- 		   as part of a run above.  Therefore 1 unused mtf position minus
- 		   2 non-literal nextSym values equals -1.) */
--		if (dbufCount >= dbufSize) return RETVAL_DATA_ERROR;
-+		if (dbufCount >= bd->dbufSize) return RETVAL_DATA_ERROR;
- 		i = nextSym - 1;
- 		uc = mtfSymbol[i];
- 
--- 
-cgit v0.12
diff --git a/poky/meta/recipes-core/busybox/busybox/CVE-2017-15874.patch b/poky/meta/recipes-core/busybox/busybox/CVE-2017-15874.patch
deleted file mode 100644
index 67b4ed7..0000000
--- a/poky/meta/recipes-core/busybox/busybox/CVE-2017-15874.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From e75c01bb3249df16201b482b79bb24bec3b58188 Mon Sep 17 00:00:00 2001
-From: Denys Vlasenko <vda.linux@googlemail.com>
-Date: Fri, 27 Oct 2017 15:37:03 +0200
-Subject: [PATCH] unlzma: fix SEGV, closes 10436
-
-Upstream-Status: Backport [ https://git.busybox.net/busybox/commit/?id=9ac42c500586fa5f10a1f6d22c3f797df11b1f6b]
-Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-Signed-off-by: Sinan Kaya <okaya@kernel.org>
----
- archival/libarchive/decompress_unlzma.c | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/archival/libarchive/decompress_unlzma.c b/archival/libarchive/decompress_unlzma.c
-index 29eee2a..41e492f 100644
---- a/archival/libarchive/decompress_unlzma.c
-+++ b/archival/libarchive/decompress_unlzma.c
-@@ -353,6 +353,10 @@ unpack_lzma_stream(transformer_state_t *xstate)
- 						pos = buffer_pos - rep0;
- 						if ((int32_t)pos < 0) {
- 							pos += header.dict_size;
-+							/* bug 10436 has an example file where this triggers: */
-+							if ((int32_t)pos < 0)
-+								goto bad;
-+
- 							/* see unzip_bad_lzma_2.zip: */
- 							if (pos >= buffer_size)
- 								goto bad;
--- 
-2.19.0
-
diff --git a/poky/meta/recipes-core/busybox/busybox/busybox-CVE-2017-16544.patch b/poky/meta/recipes-core/busybox/busybox/busybox-CVE-2017-16544.patch
deleted file mode 100644
index fc19ee3..0000000
--- a/poky/meta/recipes-core/busybox/busybox/busybox-CVE-2017-16544.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From c3797d40a1c57352192c6106cc0f435e7d9c11e8 Mon Sep 17 00:00:00 2001
-From: Denys Vlasenko <vda.linux@googlemail.com>
-Date: Tue, 7 Nov 2017 18:09:29 +0100
-Subject: lineedit: do not tab-complete any strings which have control
- characters
-
-function                                             old     new   delta
-add_match                                             41      68     +27
-
-CVE: CVE-2017-16544
-Upstream-Status: Backport
-
-Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
----
- libbb/lineedit.c | 12 ++++++++++++
- 1 file changed, 12 insertions(+)
-
-diff --git a/libbb/lineedit.c b/libbb/lineedit.c
-index c0e35bb..56e8140 100644
---- a/libbb/lineedit.c
-+++ b/libbb/lineedit.c
-@@ -645,6 +645,18 @@ static void free_tab_completion_data(void)
- 
- static void add_match(char *matched)
- {
-+	unsigned char *p = (unsigned char*)matched;
-+	while (*p) {
-+		/* ESC attack fix: drop any string with control chars */
-+		if (*p < ' '
-+		 || (!ENABLE_UNICODE_SUPPORT && *p >= 0x7f)
-+		 || (ENABLE_UNICODE_SUPPORT && *p == 0x7f)
-+		) {
-+			free(matched);
-+			return;
-+		}
-+		p++;
-+	}
- 	matches = xrealloc_vector(matches, 4, num_matches);
- 	matches[num_matches] = matched;
- 	num_matches++;
--- 
-cgit v0.12
diff --git a/poky/meta/recipes-core/busybox/busybox/busybox-fix-lzma-segfaults.patch b/poky/meta/recipes-core/busybox/busybox/busybox-fix-lzma-segfaults.patch
deleted file mode 100644
index da6dfa8..0000000
--- a/poky/meta/recipes-core/busybox/busybox/busybox-fix-lzma-segfaults.patch
+++ /dev/null
@@ -1,106 +0,0 @@
-busybox-1.27.2: Fix lzma segfaults
-
-[No upstream tracking] -- https://bugs.busybox.net/show_bug.cgi?id=10871
-
-libarchive: check buffer index in lzma_decompress
-
-With specific defconfig busybox fails to check zip fileheader magic
-(archival/unzip.c) and uses (archival/libarchive/decompress_unlzma.c)
-for decompression which leads to segmentation fault. It prevents accessing into
-buffer, which is smaller than pos index. Patch includes multiple segmentation
-fault fixes.
-
-Upstream-Status: Backport [https://git.busybox.net/busybox/commit/?id=a36986bb80289c1cd8d15a557e49207c9a42946b]
-bug: 10436 10871
-Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
-
-diff --git a/archival/libarchive/decompress_unlzma.c b/archival/libarchive/decompress_unlzma.c
-index a904087..29eee2a 100644
---- a/archival/libarchive/decompress_unlzma.c
-+++ b/archival/libarchive/decompress_unlzma.c
-@@ -11,6 +11,14 @@
- #include "libbb.h"
- #include "bb_archive.h"
- 
-+
-+#if 0
-+# define dbg(...) bb_error_msg(__VA_ARGS__)
-+#else
-+# define dbg(...) ((void)0)
-+#endif
-+
-+
- #if ENABLE_FEATURE_LZMA_FAST
- #  define speed_inline ALWAYS_INLINE
- #  define size_inline
-@@ -217,6 +225,7 @@ unpack_lzma_stream(transformer_state_t *xstate)
- 	rc_t *rc;
- 	int i;
- 	uint8_t *buffer;
-+	uint32_t buffer_size;
- 	uint8_t previous_byte = 0;
- 	size_t buffer_pos = 0, global_pos = 0;
- 	int len = 0;
-@@ -246,7 +255,8 @@ unpack_lzma_stream(transformer_state_t *xstate)
- 	if (header.dict_size == 0)
- 		header.dict_size++;
- 
--	buffer = xmalloc(MIN(header.dst_size, header.dict_size));
-+	buffer_size = MIN(header.dst_size, header.dict_size);
-+	buffer = xmalloc(buffer_size);
- 
- 	{
- 		int num_probs;
-@@ -341,8 +351,12 @@ unpack_lzma_stream(transformer_state_t *xstate)
- 						state = state < LZMA_NUM_LIT_STATES ? 9 : 11;
- 
- 						pos = buffer_pos - rep0;
--						if ((int32_t)pos < 0)
-+						if ((int32_t)pos < 0) {
- 							pos += header.dict_size;
-+							/* see unzip_bad_lzma_2.zip: */
-+							if (pos >= buffer_size)
-+								goto bad;
-+						}
- 						previous_byte = buffer[pos];
- 						goto one_byte1;
- #else
-@@ -417,6 +431,10 @@ unpack_lzma_stream(transformer_state_t *xstate)
- 						for (; num_bits2 != LZMA_NUM_ALIGN_BITS; num_bits2--)
- 							rep0 = (rep0 << 1) | rc_direct_bit(rc);
- 						rep0 <<= LZMA_NUM_ALIGN_BITS;
-+						if ((int32_t)rep0 < 0) {
-+							dbg("%d rep0:%d", __LINE__, rep0);
-+							goto bad;
-+						}
- 						prob3 = p + LZMA_ALIGN;
- 					}
- 					i2 = 1;
-@@ -450,8 +468,12 @@ unpack_lzma_stream(transformer_state_t *xstate)
-  IF_NOT_FEATURE_LZMA_FAST(string:)
- 			do {
- 				uint32_t pos = buffer_pos - rep0;
--				if ((int32_t)pos < 0)
-+				if ((int32_t)pos < 0) {
- 					pos += header.dict_size;
-+					/* more stringent test (see unzip_bad_lzma_1.zip): */
-+					if (pos >= buffer_size)
-+						goto bad;
-+				}
- 				previous_byte = buffer[pos];
-  IF_NOT_FEATURE_LZMA_FAST(one_byte2:)
- 				buffer[buffer_pos++] = previous_byte;
-@@ -478,6 +500,12 @@ unpack_lzma_stream(transformer_state_t *xstate)
- 		IF_DESKTOP(total_written += buffer_pos;)
- 		if (transformer_write(xstate, buffer, buffer_pos) != (ssize_t)buffer_pos) {
-  bad:
-+			/* One of our users, bbunpack(), expects _us_ to emit
-+			 * the error message (since it's the best place to give
-+			 * potentially more detailed information).
-+			 * Do not fail silently.
-+			 */
-+			bb_error_msg("corrupted data");
- 			total_written = -1; /* failure */
- 		}
- 		rc_free(rc);
- 
diff --git a/poky/meta/recipes-core/busybox/busybox/busybox-udhcpc-no_deconfig.patch b/poky/meta/recipes-core/busybox/busybox/busybox-udhcpc-no_deconfig.patch
index 582a258..76daaf1 100644
--- a/poky/meta/recipes-core/busybox/busybox/busybox-udhcpc-no_deconfig.patch
+++ b/poky/meta/recipes-core/busybox/busybox/busybox-udhcpc-no_deconfig.patch
@@ -31,11 +31,11 @@
  networking/udhcp/dhcpc.c                       | 29 ++++++++++++++++------
  1 file changed, 21 insertions(+), 8 deletions(-)
 
-Index: busybox-1.27.2/networking/udhcp/dhcpc.c
+Index: busybox-1.29.1/networking/udhcp/dhcpc.c
 ===================================================================
---- busybox-1.27.2.orig/networking/udhcp/dhcpc.c
-+++ busybox-1.27.2/networking/udhcp/dhcpc.c
-@@ -49,6 +49,8 @@ struct tpacket_auxdata {
+--- busybox-1.29.1.orig/networking/udhcp/dhcpc.c
++++ busybox-1.29.1/networking/udhcp/dhcpc.c
+@@ -48,6 +48,8 @@
  };
  #endif
  
@@ -44,7 +44,7 @@
  
  /* "struct client_config_t client_config" is in bb_common_bufsiz1 */
  
-@@ -104,8 +106,9 @@ enum {
+@@ -103,8 +105,9 @@
  	OPT_x = 1 << 18,
  	OPT_f = 1 << 19,
  	OPT_B = 1 << 20,
@@ -55,7 +55,7 @@
  	USE_FOR_MMU(             OPTBIT_b,)
  	IF_FEATURE_UDHCPC_ARPING(OPTBIT_a,)
  	IF_FEATURE_UDHCP_PORT(   OPTBIT_P,)
-@@ -1110,7 +1113,8 @@ static void perform_renew(void)
+@@ -1116,7 +1119,8 @@
  		state = RENEW_REQUESTED;
  		break;
  	case RENEW_REQUESTED: /* impatient are we? fine, square 1 */
@@ -65,7 +65,7 @@
  	case REQUESTING:
  	case RELEASED:
  		change_listen_mode(LISTEN_RAW);
-@@ -1146,7 +1150,8 @@ static void perform_release(uint32_t server_addr, uint32_t requested_ip)
+@@ -1152,7 +1156,8 @@
   * Users requested to be notified in all cases, even if not in one
   * of the states above.
   */
@@ -75,16 +75,16 @@
  
  	change_listen_mode(LISTEN_NONE);
  	state = RELEASED;
-@@ -1298,7 +1303,7 @@ int udhcpc_main(int argc UNUSED_PARAM, char **argv)
- 	/* O,x: list; -T,-t,-A take numeric param */
- 	IF_UDHCP_VERBOSE(opt_complementary = "vv";)
- 	IF_LONG_OPTS(applet_long_options = udhcpc_longopts;)
--	opt = getopt32(argv, "CV:H:h:F:i:np:qRr:s:T:+t:+SA:+O:*ox:*fB"
-+	opt = getopt32(argv, "CV:H:h:F:i:np:qRr:s:T:+t:+SA:+O:*ox:*fBD"
+@@ -1265,7 +1270,7 @@
+ 	/* Parse command line */
+ 	opt = getopt32long(argv, "^"
+ 		/* O,x: list; -T,-t,-A take numeric param */
+-		"CV:H:h:F:i:np:qRr:s:T:+t:+SA:+O:*ox:*fB"
++		"CV:H:h:F:i:np:qRr:s:T:+t:+SA:+O:*ox:*fBD"
  		USE_FOR_MMU("b")
  		IF_FEATURE_UDHCPC_ARPING("a::")
  		IF_FEATURE_UDHCP_PORT("P:")
-@@ -1409,6 +1414,10 @@ int udhcpc_main(int argc UNUSED_PARAM, char **argv)
+@@ -1376,6 +1381,10 @@
  		logmode |= LOGMODE_SYSLOG;
  	}
  
@@ -94,8 +94,8 @@
 +
  	/* Make sure fd 0,1,2 are open */
  	bb_sanitize_stdio();
- 	/* Equivalent of doing a fflush after every \n */
-@@ -1423,7 +1432,8 @@ int udhcpc_main(int argc UNUSED_PARAM, char **argv)
+ 	/* Create pidfile */
+@@ -1388,7 +1397,8 @@
  	srand(monotonic_us());
  
  	state = INIT_SELECTING;
@@ -105,7 +105,7 @@
  	change_listen_mode(LISTEN_RAW);
  	packet_num = 0;
  	timeout = 0;
-@@ -1577,7 +1587,8 @@ int udhcpc_main(int argc UNUSED_PARAM, char **argv)
+@@ -1555,7 +1565,8 @@
  				}
  				/* Timed out, enter init state */
  				bb_error_msg("lease lost, entering init state");
@@ -115,23 +115,29 @@
  				state = INIT_SELECTING;
  				client_config.first_secs = 0; /* make secs field count from 0 */
  				/*timeout = 0; - already is */
-@@ -1770,7 +1781,8 @@ int udhcpc_main(int argc UNUSED_PARAM, char **argv)
+@@ -1748,8 +1759,10 @@
+ 							"(got ARP reply), declining");
  						send_decline(/*xid,*/ server_addr, packet.yiaddr);
  
- 						if (state != REQUESTING)
+-						if (state != REQUESTING)
 -							udhcp_run_script(NULL, "deconfig");
++						if (state != REQUESTING) {
 +							if (allow_deconfig)
 +								udhcp_run_script(NULL, "deconfig");
++						}
  						change_listen_mode(LISTEN_RAW);
  						state = INIT_SELECTING;
  						client_config.first_secs = 0; /* make secs field count from 0 */
-@@ -1840,7 +1852,8 @@ int udhcpc_main(int argc UNUSED_PARAM, char **argv)
+@@ -1818,8 +1831,10 @@
+ 				/* return to init state */
  				bb_error_msg("received %s", "DHCP NAK");
  				udhcp_run_script(&packet, "nak");
- 				if (state != REQUESTING)
+-				if (state != REQUESTING)
 -					udhcp_run_script(NULL, "deconfig");
++				if (state != REQUESTING) {
 +					if (allow_deconfig)
 +						udhcp_run_script(NULL, "deconfig");
++				}
  				change_listen_mode(LISTEN_RAW);
  				sleep(3); /* avoid excessive network traffic */
  				state = INIT_SELECTING;
diff --git a/poky/meta/recipes-core/busybox/busybox/defconfig b/poky/meta/recipes-core/busybox/busybox/defconfig
index 59d93c7..32213c0 100644
--- a/poky/meta/recipes-core/busybox/busybox/defconfig
+++ b/poky/meta/recipes-core/busybox/busybox/defconfig
@@ -1,12 +1,12 @@
 #
 # Automatically generated make config: don't edit
-# Busybox version: 1.27.2
-# Wed Sep 27 08:56:13 2017
+# Busybox version: 1.29.1
+# Thu Jul 19 11:09:46 2018
 #
 CONFIG_HAVE_DOT_CONFIG=y
 
 #
-# Busybox Settings
+# Settings
 #
 # CONFIG_DESKTOP is not set
 # CONFIG_EXTRA_COMPAT is not set
@@ -78,7 +78,7 @@
 # CONFIG_EFENCE is not set
 
 #
-# Busybox Library Tuning
+# Library Tuning
 #
 # CONFIG_FEATURE_USE_BSS_TAIL is not set
 CONFIG_FEATURE_RTMINMAX=y
@@ -90,6 +90,7 @@
 CONFIG_SHA3_SMALL=1
 CONFIG_FEATURE_FAST_TOP=y
 # CONFIG_FEATURE_ETC_NETWORKS is not set
+# CONFIG_FEATURE_ETC_SERVICES is not set
 CONFIG_FEATURE_EDITING=y
 CONFIG_FEATURE_EDITING_MAX_LEN=1024
 # CONFIG_FEATURE_EDITING_VI is not set
@@ -321,6 +322,7 @@
 CONFIG_TTY=y
 CONFIG_UNAME=y
 CONFIG_UNAME_OSNAME="GNU/Linux"
+# CONFIG_BB_ARCH is not set
 CONFIG_UNIQ=y
 CONFIG_UNLINK=y
 CONFIG_USLEEP=y
@@ -393,6 +395,14 @@
 CONFIG_WHICH=y
 
 #
+# klibc-utils
+#
+# CONFIG_MINIPS is not set
+# CONFIG_NUKE is not set
+# CONFIG_RESUME is not set
+# CONFIG_RUN_INIT is not set
+
+#
 # Editors
 #
 CONFIG_AWK=y
@@ -470,7 +480,7 @@
 # CONFIG_FEATURE_BOOTCHARTD_CONFIG_FILE is not set
 # CONFIG_HALT is not set
 # CONFIG_POWEROFF is not set
-# CONFIG_REBOOT is not set
+CONFIG_REBOOT=y
 # CONFIG_FEATURE_CALL_TELINIT is not set
 # CONFIG_TELINIT_PATH is not set
 # CONFIG_INIT is not set
@@ -678,6 +688,10 @@
 CONFIG_FEATURE_MOUNT_LOOP_CREATE=y
 # CONFIG_FEATURE_MTAB_SUPPORT is not set
 # CONFIG_VOLUMEID is not set
+
+#
+# Filesystem/Volume identification
+#
 # CONFIG_FEATURE_VOLUMEID_BCACHE is not set
 # CONFIG_FEATURE_VOLUMEID_BTRFS is not set
 # CONFIG_FEATURE_VOLUMEID_CRAMFS is not set
@@ -725,6 +739,7 @@
 # CONFIG_FEATURE_HDPARM_HDIO_DRIVE_RESET is not set
 # CONFIG_FEATURE_HDPARM_HDIO_TRISTATE_HWIF is not set
 # CONFIG_FEATURE_HDPARM_HDIO_GETSET_DMA is not set
+# CONFIG_HEXEDIT is not set
 # CONFIG_I2CGET is not set
 # CONFIG_I2CSET is not set
 # CONFIG_I2CDUMP is not set
@@ -807,6 +822,7 @@
 # CONFIG_RUNLEVEL is not set
 # CONFIG_RX is not set
 # CONFIG_SETSID is not set
+# CONFIG_SETFATTR is not set
 CONFIG_STRINGS=y
 CONFIG_TIME=y
 # CONFIG_TIMEOUT is not set
@@ -912,6 +928,8 @@
 CONFIG_ROUTE=y
 # CONFIG_SLATTACH is not set
 # CONFIG_SSL_CLIENT is not set
+# CONFIG_TC is not set
+# CONFIG_FEATURE_TC_INGRESS is not set
 # CONFIG_TCPSVD is not set
 # CONFIG_UDPSVD is not set
 CONFIG_TELNET=y
@@ -949,13 +967,9 @@
 # CONFIG_FEATURE_WGET_OPENSSL is not set
 # CONFIG_WHOIS is not set
 # CONFIG_ZCIP is not set
-# CONFIG_UDHCPC6 is not set
-# CONFIG_FEATURE_UDHCPC6_RFC3646 is not set
-# CONFIG_FEATURE_UDHCPC6_RFC4704 is not set
-# CONFIG_FEATURE_UDHCPC6_RFC4833 is not set
 CONFIG_UDHCPD=y
-# CONFIG_FEATURE_UDHCPD_WRITE_LEASES_EARLY is not set
 # CONFIG_FEATURE_UDHCPD_BASE_IP_ON_MAC is not set
+# CONFIG_FEATURE_UDHCPD_WRITE_LEASES_EARLY is not set
 CONFIG_DHCPD_LEASES_FILE="/var/lib/misc/udhcpd.leases"
 CONFIG_DUMPLEASES=y
 # CONFIG_DHCPRELAY is not set
@@ -963,6 +977,15 @@
 CONFIG_FEATURE_UDHCPC_ARPING=y
 CONFIG_FEATURE_UDHCPC_SANITIZEOPT=y
 CONFIG_UDHCPC_DEFAULT_SCRIPT="/usr/share/udhcpc/default.script"
+# CONFIG_UDHCPC6 is not set
+# CONFIG_FEATURE_UDHCPC6_RFC3646 is not set
+# CONFIG_FEATURE_UDHCPC6_RFC4704 is not set
+# CONFIG_FEATURE_UDHCPC6_RFC4833 is not set
+# CONFIG_FEATURE_UDHCPC6_RFC5970 is not set
+
+#
+# Common options for DHCP applets
+#
 # CONFIG_FEATURE_UDHCP_PORT is not set
 CONFIG_UDHCP_DEBUG=0
 # CONFIG_FEATURE_UDHCP_RFC3397 is not set
@@ -1045,6 +1068,7 @@
 # CONFIG_SV is not set
 CONFIG_SV_DEFAULT_SERVICE_DIR=""
 # CONFIG_SVC is not set
+# CONFIG_SVOK is not set
 # CONFIG_SVLOGD is not set
 # CONFIG_CHCON is not set
 # CONFIG_FEATURE_CHCON_LONG_OPTIONS is not set
@@ -1134,6 +1158,10 @@
 # System Logging Utilities
 #
 CONFIG_KLOGD=y
+
+#
+# klogd should not be used together with syslog to kernel printk buffer
+#
 CONFIG_FEATURE_KLOGD_KLOGCTL=y
 CONFIG_LOGGER=y
 # CONFIG_LOGREAD is not set
diff --git a/poky/meta/recipes-core/busybox/busybox/init.cfg b/poky/meta/recipes-core/busybox/busybox/init.cfg
index 3c1fdd4..e967006 100644
--- a/poky/meta/recipes-core/busybox/busybox/init.cfg
+++ b/poky/meta/recipes-core/busybox/busybox/init.cfg
@@ -1,8 +1,8 @@
 CONFIG_INIT=y
+CONFIG_RUNLEVEL=y
 CONFIG_FEATURE_USE_INITTAB=y
 CONFIG_HALT=y
 CONFIG_POWEROFF=y
-CONFIG_REBOOT=y
 CONFIG_FEATURE_KILL_DELAY=0
 CONFIG_TELINIT_PATH=""
 CONFIG_INIT_TERMINAL_TYPE=""
diff --git a/poky/meta/recipes-core/busybox/busybox/umount-ignore-c.patch b/poky/meta/recipes-core/busybox/busybox/umount-ignore-c.patch
deleted file mode 100644
index 9fe7998..0000000
--- a/poky/meta/recipes-core/busybox/busybox/umount-ignore-c.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br>
-Upstream-Status: Backport [https://git.busybox.net/busybox/commit/?id=426134128112738c97a665170b21153ef0764b7d]
-
-From 95ea12791c8623bf825bc711ac7790306e7e1adb Mon Sep 17 00:00:00 2001
-From: Shawn Landden <slandden@gmail.com>
-Date: Mon, 8 Jan 2018 13:31:58 +0100
-Subject: [PATCH] umount: ignore -c
-Organization: O.S. Systems Software LTDA.
-
-"-c, --no-canonicalize: Do not canonicalize paths."
-
-As busybox doesn't canonicalize paths in the first place it is safe to ignore
-this option.
-
-See https://github.com/systemd/systemd/issues/7786
-
-Signed-off-by: Shawn Landden <slandden@gmail.com>
-Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
----
- util-linux/umount.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/util-linux/umount.c b/util-linux/umount.c
-index 0c50dc9ee..0425c5b76 100644
---- a/util-linux/umount.c
-+++ b/util-linux/umount.c
-@@ -68,8 +68,8 @@ static struct mntent *getmntent_r(FILE* stream, struct mntent* result,
- }
- #endif
- 
--/* ignored: -v -t -i */
--#define OPTION_STRING           "fldnra" "vt:i"
-+/* ignored: -c -v -t -i */
-+#define OPTION_STRING           "fldnra" "cvt:i"
- #define OPT_FORCE               (1 << 0) // Same as MNT_FORCE
- #define OPT_LAZY                (1 << 1) // Same as MNT_DETACH
- #define OPT_FREELOOP            (1 << 2)
--- 
-2.18.0
-
diff --git a/poky/meta/recipes-core/busybox/busybox_1.27.2.bb b/poky/meta/recipes-core/busybox/busybox_1.27.2.bb
deleted file mode 100644
index bab2972..0000000
--- a/poky/meta/recipes-core/busybox/busybox_1.27.2.bb
+++ /dev/null
@@ -1,55 +0,0 @@
-require busybox.inc
-
-SRC_URI = "http://www.busybox.net/downloads/busybox-${PV}.tar.bz2;name=tarball \
-           file://busybox-udhcpc-no_deconfig.patch \
-           file://find-touchscreen.sh \
-           file://busybox-cron \
-           file://busybox-httpd \
-           file://busybox-udhcpd \
-           file://default.script \
-           file://simple.script \
-           file://hwclock.sh \
-           file://mount.busybox \
-           file://syslog \
-           file://syslog-startup.conf \
-           file://syslog.conf \
-           file://busybox-syslog.default \
-           file://mdev \
-           file://mdev.conf \
-           file://mdev-mount.sh \
-           file://umount.busybox \
-           file://defconfig \
-           file://busybox-syslog.service.in \
-           file://busybox-klogd.service.in \
-           file://fail_on_no_media.patch \
-           file://run-ptest \
-           file://inetd.conf \
-           file://inetd \
-           file://login-utilities.cfg \
-           file://recognize_connmand.patch \
-           file://busybox-cross-menuconfig.patch \
-           file://0001-Use-CC-when-linking-instead-of-LD-and-use-CFLAGS-and.patch \
-           file://mount-via-label.cfg \
-           file://sha1sum.cfg \
-           file://sha256sum.cfg \
-           file://getopts.cfg \
-           file://resize.cfg \
-           ${@["", "file://init.cfg"][(d.getVar('VIRTUAL-RUNTIME_init_manager') == 'busybox')]} \
-           ${@["", "file://mdev.cfg"][(d.getVar('VIRTUAL-RUNTIME_dev_manager') == 'busybox-mdev')]} \
-           file://syslog.cfg \
-           file://inittab \
-           file://rcS \
-           file://rcK \
-           file://runlevel \
-           file://makefile-libbb-race.patch \
-           file://CVE-2011-5325.patch \
-           file://CVE-2017-15873.patch \
-           file://busybox-CVE-2017-16544.patch \
-           file://busybox-fix-lzma-segfaults.patch \
-           file://umount-ignore-c.patch \
-           file://CVE-2017-15874.patch \
-"
-SRC_URI_append_libc-musl = " file://musl.cfg "
-
-SRC_URI[tarball.md5sum] = "476186f4bab81781dab2369bfd42734e"
-SRC_URI[tarball.sha256sum] = "9d4be516b61e6480f156b11eb42577a13529f75d3383850bb75c50c285de63df"
diff --git a/poky/meta/recipes-core/busybox/busybox_1.29.2.bb b/poky/meta/recipes-core/busybox/busybox_1.29.2.bb
new file mode 100644
index 0000000..df3ea59
--- /dev/null
+++ b/poky/meta/recipes-core/busybox/busybox_1.29.2.bb
@@ -0,0 +1,48 @@
+require busybox.inc
+
+SRC_URI = "http://www.busybox.net/downloads/busybox-${PV}.tar.bz2;name=tarball \
+           file://busybox-udhcpc-no_deconfig.patch \
+           file://find-touchscreen.sh \
+           file://busybox-cron \
+           file://busybox-httpd \
+           file://busybox-udhcpd \
+           file://default.script \
+           file://simple.script \
+           file://hwclock.sh \
+           file://mount.busybox \
+           file://syslog \
+           file://syslog-startup.conf \
+           file://syslog.conf \
+           file://busybox-syslog.default \
+           file://mdev \
+           file://mdev.conf \
+           file://mdev-mount.sh \
+           file://umount.busybox \
+           file://defconfig \
+           file://busybox-syslog.service.in \
+           file://busybox-klogd.service.in \
+           file://fail_on_no_media.patch \
+           file://run-ptest \
+           file://inetd.conf \
+           file://inetd \
+           file://login-utilities.cfg \
+           file://recognize_connmand.patch \
+           file://busybox-cross-menuconfig.patch \
+           file://0001-Use-CC-when-linking-instead-of-LD-and-use-CFLAGS-and.patch \
+           file://mount-via-label.cfg \
+           file://sha1sum.cfg \
+           file://sha256sum.cfg \
+           file://getopts.cfg \
+           file://resize.cfg \
+           ${@["", "file://init.cfg"][(d.getVar('VIRTUAL-RUNTIME_init_manager') == 'busybox')]} \
+           ${@["", "file://mdev.cfg"][(d.getVar('VIRTUAL-RUNTIME_dev_manager') == 'busybox-mdev')]} \
+           file://syslog.cfg \
+           file://inittab \
+           file://rcS \
+           file://rcK \
+           file://makefile-libbb-race.patch \
+"
+SRC_URI_append_libc-musl = " file://musl.cfg "
+
+SRC_URI[tarball.md5sum] = "46617af37a39579711d8b36f189cdf1e"
+SRC_URI[tarball.sha256sum] = "67d2fa6e147a45875fe972de62d907ef866fe784c495c363bf34756c444a5d61"
diff --git a/poky/meta/recipes-core/busybox/files/runlevel b/poky/meta/recipes-core/busybox/files/runlevel
deleted file mode 100644
index 866f3b5..0000000
--- a/poky/meta/recipes-core/busybox/files/runlevel
+++ /dev/null
@@ -1,11 +0,0 @@
-#!/bin/sh
-# busybox init does not have LSB ( sysvinit ) like initlevels
-# so lets fake it to 5 which is what we default anyway
-# this helps with opkg post installs where it tries to invoke
-# update-rc.d ad post install step.
-# for package upgrades
-# See code in update-rc.d around line 190 where it calls runlevel
-# program
-#
-echo "5"
-
diff --git a/poky/meta/recipes-core/console-tools/console-tools_0.3.2.bb b/poky/meta/recipes-core/console-tools/console-tools_0.3.2.bb
index 286c2a4..ba44fbe 100644
--- a/poky/meta/recipes-core/console-tools/console-tools_0.3.2.bb
+++ b/poky/meta/recipes-core/console-tools/console-tools_0.3.2.bb
@@ -1,8 +1,9 @@
+SUMMARY = "Allows you to set-up and manipulate the Linux console"
+DESCRIPTION = "Provides tools that enable the set-up and manipulation of the linux console and console-font files."
 SECTION = "base"
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING.kbd;md5=9b2d91511d3d80d4d20ac6e6b0137fe9"
-SUMMARY = "Allows you to set-up and manipulate the Linux console"
-DESCRIPTION = "Provides tools that enable the set-up and manipulation of the linux console and console-font files."
+DEPENDS = "flex-native bison-native"
 PR = "r8"
 
 SRC_URI = "${SOURCEFORGE_MIRROR}/lct/console-tools-${PV}.tar.gz \
@@ -26,8 +27,12 @@
 UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/lct/files/console-tools-devel/"
 UPSTREAM_CHECK_REGEX = "/console-tools-devel/(?P<pver>(\d\d?\.)+\d\d?)/"
 
+inherit autotools gettext update-alternatives
+
 CFLAGS_append_aarch64 = " -D_USE_TERMIOS "
 
+ASNEEDED = ""
+
 do_configure_prepend () {
 	mkdir -p ${S}/m4
 	cp ${WORKDIR}/lcmessage.m4 ${S}/m4/
@@ -35,8 +40,6 @@
 	cp ${WORKDIR}/Makevars ${S}/po/
 }
 
-inherit autotools gettext update-alternatives
-
 ALTERNATIVE_PRIORITY = "30"
 
 bindir_progs = "chvt deallocvt fgconsole openvt"
diff --git a/poky/meta/recipes-core/coreutils/coreutils/0001-Unset-need_charset_alias-when-building-for-musl.patch b/poky/meta/recipes-core/coreutils/coreutils/0001-Unset-need_charset_alias-when-building-for-musl.patch
deleted file mode 100644
index ba1a4ba..0000000
--- a/poky/meta/recipes-core/coreutils/coreutils/0001-Unset-need_charset_alias-when-building-for-musl.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From b9565dc2fe0c4f7daaec91b7e83bc7313dee2f4a Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 13 Apr 2015 17:02:13 -0700
-Subject: [PATCH] Unset need_charset_alias when building for musl
-
-localcharset uses ac_cv_gnu_library_2_1 from glibc21.m4
-which actually shoudl be fixed in gnulib and then all downstream
-projects will get it eventually. For now we apply the fix to
-coreutils
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- lib/gnulib.mk | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/lib/gnulib.mk b/lib/gnulib.mk
-index e1d74db..c0e92dd 100644
---- a/lib/gnulib.mk
-+++ b/lib/gnulib.mk
-@@ -1882,7 +1882,7 @@ install-exec-localcharset: all-local
- 	  case '$(host_os)' in \
- 	    darwin[56]*) \
- 	      need_charset_alias=true ;; \
--	    darwin* | cygwin* | mingw* | pw32* | cegcc*) \
-+	    darwin* | cygwin* | mingw* | pw32* | cegcc* | linux-musl*) \
- 	      need_charset_alias=false ;; \
- 	    *) \
- 	      need_charset_alias=true ;; \
--- 
-2.1.4
-
diff --git a/poky/meta/recipes-core/coreutils/coreutils/CVE-2017-18018-1.patch b/poky/meta/recipes-core/coreutils/coreutils/CVE-2017-18018-1.patch
deleted file mode 100644
index 6f31eba..0000000
--- a/poky/meta/recipes-core/coreutils/coreutils/CVE-2017-18018-1.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From 7597cfa482e42a00a69fb9577ee523762980a9a2 Mon Sep 17 00:00:00 2001
-From: Michael Orlitzky <michael@orlitzky.com>
-Date: Thu, 28 Dec 2017 15:52:42 -0500
-Subject: doc: clarify chown/chgrp --dereference defaults
-
-* doc/coreutils.texi: the documentation for the --dereference
-  flag of chown/chgrp states that it is the default mode of
-  operation. Document that this is only the case when operating
-  non-recursively.
-
-CVE: CVE-2017-18018
-Upstream-Status: Backport from v8.30
-
-Signed-off-by: Michael Orlitzky <michael@orlitzky.com>
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- doc/coreutils.texi | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff -Naurp coreutils-8.27_org/doc/coreutils.texi coreutils-8.27/doc/coreutils.texi
---- coreutils-8.27_org/doc/coreutils.texi	2018-07-22 21:09:50.128736692 -0700
-+++ coreutils-8.27/doc/coreutils.texi	2018-07-22 21:12:59.972219770 -0700
-@@ -10952,7 +10952,7 @@ chown -h -R --from=OLDUSER NEWUSER /
- @cindex symbolic links, changing owner
- @findex lchown
- Do not act on symbolic links themselves but rather on what they point to.
--This is the default.
-+This is the default when not operating recursively.
- 
- @item -h
- @itemx --no-dereference
-@@ -11082,7 +11082,7 @@ changed.
- @cindex symbolic links, changing owner
- @findex lchown
- Do not act on symbolic links themselves but rather on what they point to.
--This is the default.
-+This is the default when not operating recursively.
- 
- @item -h
- @itemx --no-dereference
diff --git a/poky/meta/recipes-core/coreutils/coreutils/CVE-2017-18018-2.patch b/poky/meta/recipes-core/coreutils/coreutils/CVE-2017-18018-2.patch
deleted file mode 100644
index c8f5f54..0000000
--- a/poky/meta/recipes-core/coreutils/coreutils/CVE-2017-18018-2.patch
+++ /dev/null
@@ -1,83 +0,0 @@
-From bc2fd9796403e03bb757b064d44c22fab92e6842 Mon Sep 17 00:00:00 2001
-From: Michael Orlitzky <michael@orlitzky.com>
-Date: Thu, 4 Jan 2018 11:38:21 -0500
-Subject: doc: warn about following symlinks recursively in chown/chgrp
-
-In both chown and chgrp (which shares its code with chown), operating
-on symlinks recursively has a window of vulnerability where the
-destination user or group can change the target of the operation.
-Warn about combining the --dereference, --recursive, and -L flags.
-
-* doc/coreutils.texi (warnOptDerefWithRec): Add macro.
-(node chown invocation): Add it to --dereference and -L.
-(node chgrp invocation): Likewise.
-
-See also: CVE-2017-18018
-CVE: CVE-2017-18018
-Upstream-Status: Backport from v8.30
-
-Signed-off-by: Michael Orlitzky <michael@orlitzky.com>
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- doc/coreutils.texi | 17 +++++++++++++++++
- 1 file changed, 17 insertions(+)
-
-diff --git a/doc/coreutils.texi b/doc/coreutils.texi
-index 6bb9f09..9f5f95b 100644
---- a/doc/coreutils.texi
-+++ b/doc/coreutils.texi
-@@ -1428,6 +1428,19 @@ a command line argument is a symbolic link to a directory, traverse it.
- In a recursive traversal, traverse every symbolic link to a directory
- that is encountered.
- @end macro
-+
-+@c Append the following warning to -L where appropriate (e.g. chown).
-+@macro warnOptDerefWithRec
-+
-+Combining this dereferencing option with the @option{--recursive} option
-+may create a security risk:
-+During the traversal of the directory tree, an attacker may be able to
-+introduce a symlink to an arbitrary target; when the tool reaches that,
-+the operation will be performed on the target of that symlink,
-+possibly allowing the attacker to escalate privileges.
-+
-+@end macro
-+
- @choptL
- 
- @macro choptP
-@@ -10995,6 +11008,7 @@ chown -h -R --from=OLDUSER NEWUSER /
- @findex lchown
- Do not act on symbolic links themselves but rather on what they point to.
- This is the default when not operating recursively.
-+@warnOptDerefWithRec
- 
- @item -h
- @itemx --no-dereference
-@@ -11051,6 +11065,7 @@ Recursively change ownership of directories and their contents.
- @xref{Traversing symlinks}.
- 
- @choptL
-+@warnOptDerefWithRec
- @xref{Traversing symlinks}.
- 
- @choptP
-@@ -11125,6 +11140,7 @@ changed.
- @findex lchown
- Do not act on symbolic links themselves but rather on what they point to.
- This is the default when not operating recursively.
-+@warnOptDerefWithRec
- 
- @item -h
- @itemx --no-dereference
-@@ -11180,6 +11196,7 @@ Recursively change the group ownership of directories and their contents.
- @xref{Traversing symlinks}.
- 
- @choptL
-+@warnOptDerefWithRec
- @xref{Traversing symlinks}.
- 
- @choptP
--- 
-cgit v1.0-41-gc330
-
diff --git a/poky/meta/recipes-core/coreutils/coreutils_8.29.bb b/poky/meta/recipes-core/coreutils/coreutils_8.29.bb
deleted file mode 100644
index b0572af..0000000
--- a/poky/meta/recipes-core/coreutils/coreutils_8.29.bb
+++ /dev/null
@@ -1,135 +0,0 @@
-SUMMARY = "The basic file, shell and text manipulation utilities"
-DESCRIPTION = "The GNU Core Utilities provide the basic file, shell and text \
-manipulation utilities. These are the core utilities which are expected to exist on \
-every system."
-HOMEPAGE = "http://www.gnu.org/software/coreutils/"
-BUGTRACKER = "http://debbugs.gnu.org/coreutils"
-LICENSE = "GPLv3+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504\
-                    file://src/ls.c;beginline=1;endline=15;md5=1c3f9411e1842a062ce5ce9210beee0e"
-DEPENDS = "gmp libcap"
-DEPENDS_class-native = ""
-
-inherit autotools gettext texinfo
-
-SRC_URI = "${GNU_MIRROR}/coreutils/${BP}.tar.xz \
-           file://remove-usr-local-lib-from-m4.patch \
-           file://fix-selinux-flask.patch \
-           file://0001-Unset-need_charset_alias-when-building-for-musl.patch \
-           file://0001-uname-report-processor-and-hardware-correctly.patch \
-           file://disable-ls-output-quoting.patch \
-           file://0001-local.mk-fix-cross-compiling-problem.patch \
-           file://CVE-2017-18018-1.patch \
-           file://CVE-2017-18018-2.patch \
-          "
-
-SRC_URI[md5sum] = "960cfe75a42c9907c71439f8eb436303"
-SRC_URI[sha256sum] = "92d0fa1c311cacefa89853bdb53c62f4110cdfda3820346b59cbd098f40f955e"
-
-EXTRA_OECONF_class-native = "--without-gmp"
-EXTRA_OECONF_class-target = "--enable-install-program=arch,hostname --libexecdir=${libdir}"
-EXTRA_OECONF_class-nativesdk = "--enable-install-program=arch,hostname"
-
-# acl and xattr are not default features
-#
-PACKAGECONFIG_class-target ??= "\
-    ${@bb.utils.filter('DISTRO_FEATURES', 'acl xattr', d)} \
-"
-
-# The lib/oe/path.py requires xattr
-PACKAGECONFIG_class-native ??= "xattr"
-
-# with, without, depends, rdepends
-#
-PACKAGECONFIG[acl] = "--enable-acl,--disable-acl,acl,"
-PACKAGECONFIG[xattr] = "--enable-xattr,--disable-xattr,attr,"
-PACKAGECONFIG[single-binary] = "--enable-single-binary,--disable-single-binary,,"
-
-# [ df mktemp base64 gets a special treatment and is not included in this
-bindir_progs = "arch basename chcon cksum comm csplit cut dir dircolors dirname du \
-                env expand expr factor fmt fold groups head hostid id install \
-                join link logname md5sum mkfifo nice nl nohup nproc od paste pathchk \
-                pinky pr printenv printf ptx readlink realpath runcon seq sha1sum sha224sum sha256sum \
-                sha384sum sha512sum shred shuf sort split stdbuf sum tac tail tee test timeout\
-                tr truncate tsort tty unexpand uniq unlink uptime users vdir wc who whoami yes"
-
-# hostname gets a special treatment and is not included in this
-base_bindir_progs = "cat chgrp chmod chown cp date dd echo false hostname kill ln ls mkdir \
-                     mknod mv pwd rm rmdir sleep stty sync touch true uname stat"
-
-sbindir_progs= "chroot"
-
-# Let aclocal use the relative path for the m4 file rather than the
-# absolute since coreutils has a lot of m4 files, otherwise there might
-# be an "Argument list too long" error when it is built in a long/deep
-# directory.
-acpaths = "-I ./m4"
-
-# Deal with a separate builddir failure if src doesn't exist when creating version.c/version.h
-do_compile_prepend () {
-	mkdir -p ${B}/src
-}
-
-do_install_class-native() {
-	autotools_do_install
-	# remove groups to fix conflict with shadow-native
-	rm -f ${D}${STAGING_BINDIR_NATIVE}/groups
-	# The return is a must since native doesn't need the
-	# do_install_append() in the below.
-	return
-}
-
-do_install_append() {
-	for i in df mktemp base64; do mv ${D}${bindir}/$i ${D}${bindir}/$i.${BPN}; done
-
-	install -d ${D}${base_bindir}
-	[ "${base_bindir}" != "${bindir}" ] && for i in ${base_bindir_progs}; do mv ${D}${bindir}/$i ${D}${base_bindir}/$i.${BPN}; done
-
-	install -d ${D}${sbindir}
-	[ "${sbindir}" != "${bindir}" ] && for i in ${sbindir_progs}; do mv ${D}${bindir}/$i ${D}${sbindir}/$i.${BPN}; done
-
-	# [ requires special handling because [.coreutils will cause the sed stuff
-	# in update-alternatives to fail, therefore use lbracket - the name used
-	# for the actual source file.
-	mv ${D}${bindir}/[ ${D}${bindir}/lbracket.${BPN}
-}
-
-inherit update-alternatives
-
-ALTERNATIVE_PRIORITY = "100"
-# Make hostname's priority higher than busybox but lower than net-tools
-ALTERNATIVE_PRIORITY[hostname] = "90"
-ALTERNATIVE_${PN} = "lbracket ${bindir_progs} ${base_bindir_progs} ${sbindir_progs} base64 mktemp df"
-ALTERNATIVE_${PN}-doc = "base64.1 mktemp.1 df.1 groups.1 kill.1 uptime.1 stat.1  hostname.1"
-
-ALTERNATIVE_LINK_NAME[hostname.1] = "${mandir}/man1/hostname.1"
-
-ALTERNATIVE_LINK_NAME[base64] = "${base_bindir}/base64"
-ALTERNATIVE_TARGET[base64] = "${bindir}/base64.${BPN}"
-ALTERNATIVE_LINK_NAME[base64.1] = "${mandir}/man1/base64.1"
-
-ALTERNATIVE_LINK_NAME[mktemp] = "${base_bindir}/mktemp"
-ALTERNATIVE_TARGET[mktemp] = "${bindir}/mktemp.${BPN}"
-ALTERNATIVE_LINK_NAME[mktemp.1] = "${mandir}/man1/mktemp.1"
-
-ALTERNATIVE_LINK_NAME[df] = "${base_bindir}/df"
-ALTERNATIVE_TARGET[df] = "${bindir}/df.${BPN}"
-ALTERNATIVE_LINK_NAME[df.1] = "${mandir}/man1/df.1"
-
-ALTERNATIVE_LINK_NAME[lbracket] = "${bindir}/["
-ALTERNATIVE_TARGET[lbracket] = "${bindir}/lbracket.${BPN}"
-
-ALTERNATIVE_LINK_NAME[groups.1] = "${mandir}/man1/groups.1"
-ALTERNATIVE_LINK_NAME[uptime.1] = "${mandir}/man1/uptime.1"
-ALTERNATIVE_LINK_NAME[kill.1] = "${mandir}/man1/kill.1"
-ALTERNATIVE_LINK_NAME[stat.1] = "${mandir}/man1/stat.1"
-
-python __anonymous() {
-	for prog in d.getVar('base_bindir_progs').split():
-		d.setVarFlag('ALTERNATIVE_LINK_NAME', prog, '%s/%s' % (d.getVar('base_bindir'), prog))
-
-	for prog in d.getVar('sbindir_progs').split():
-		d.setVarFlag('ALTERNATIVE_LINK_NAME', prog, '%s/%s' % (d.getVar('sbindir'), prog))
-}
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-core/coreutils/coreutils_8.30.bb b/poky/meta/recipes-core/coreutils/coreutils_8.30.bb
new file mode 100644
index 0000000..205ba4a
--- /dev/null
+++ b/poky/meta/recipes-core/coreutils/coreutils_8.30.bb
@@ -0,0 +1,139 @@
+SUMMARY = "The basic file, shell and text manipulation utilities"
+DESCRIPTION = "The GNU Core Utilities provide the basic file, shell and text \
+manipulation utilities. These are the core utilities which are expected to exist on \
+every system."
+HOMEPAGE = "http://www.gnu.org/software/coreutils/"
+BUGTRACKER = "http://debbugs.gnu.org/coreutils"
+LICENSE = "GPLv3+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504\
+                    file://src/ls.c;beginline=1;endline=15;md5=dbe356a88b09c29232b083d1ff8ac82a"
+DEPENDS = "gmp libcap"
+DEPENDS_class-native = ""
+
+inherit autotools gettext texinfo
+
+SRC_URI = "${GNU_MIRROR}/coreutils/${BP}.tar.xz \
+           file://remove-usr-local-lib-from-m4.patch \
+           file://fix-selinux-flask.patch \
+           file://0001-uname-report-processor-and-hardware-correctly.patch \
+           file://disable-ls-output-quoting.patch \
+           file://0001-local.mk-fix-cross-compiling-problem.patch \
+          "
+
+SRC_URI[md5sum] = "ab06d68949758971fe744db66b572816"
+SRC_URI[sha256sum] = "e831b3a86091496cdba720411f9748de81507798f6130adeaef872d206e1b057"
+
+EXTRA_OECONF_class-native = "--without-gmp"
+EXTRA_OECONF_class-target = "--enable-install-program=arch,hostname --libexecdir=${libdir}"
+EXTRA_OECONF_class-nativesdk = "--enable-install-program=arch,hostname"
+
+# acl and xattr are not default features
+#
+PACKAGECONFIG_class-target ??= "\
+    ${@bb.utils.filter('DISTRO_FEATURES', 'acl xattr', d)} \
+"
+
+# The lib/oe/path.py requires xattr
+PACKAGECONFIG_class-native ??= "xattr"
+
+# with, without, depends, rdepends
+#
+PACKAGECONFIG[acl] = "--enable-acl,--disable-acl,acl,"
+PACKAGECONFIG[xattr] = "--enable-xattr,--disable-xattr,attr,"
+PACKAGECONFIG[single-binary] = "--enable-single-binary,--disable-single-binary,,"
+
+# [ df mktemp nice printenv base64 gets a special treatment and is not included in this
+bindir_progs = "arch basename chcon cksum comm csplit cut dir dircolors dirname du \
+                env expand expr factor fmt fold groups head hostid id install \
+                join link logname md5sum mkfifo nl nohup nproc od paste pathchk \
+                pinky pr printf ptx readlink realpath runcon seq sha1sum sha224sum sha256sum \
+                sha384sum sha512sum shred shuf sort split stdbuf sum tac tail tee test timeout \
+                tr truncate tsort tty unexpand uniq unlink uptime users vdir wc who whoami yes"
+
+# hostname gets a special treatment and is not included in this
+base_bindir_progs = "cat chgrp chmod chown cp date dd echo false hostname kill ln ls mkdir \
+                     mknod mv pwd rm rmdir sleep stty sync touch true uname stat"
+
+sbindir_progs= "chroot"
+
+# Let aclocal use the relative path for the m4 file rather than the
+# absolute since coreutils has a lot of m4 files, otherwise there might
+# be an "Argument list too long" error when it is built in a long/deep
+# directory.
+acpaths = "-I ./m4"
+
+# Deal with a separate builddir failure if src doesn't exist when creating version.c/version.h
+do_compile_prepend () {
+	mkdir -p ${B}/src
+}
+
+do_install_class-native() {
+	autotools_do_install
+	# remove groups to fix conflict with shadow-native
+	rm -f ${D}${STAGING_BINDIR_NATIVE}/groups
+	# The return is a must since native doesn't need the
+	# do_install_append() in the below.
+	return
+}
+
+do_install_append() {
+	for i in df mktemp nice printenv base64; do mv ${D}${bindir}/$i ${D}${bindir}/$i.${BPN}; done
+
+	install -d ${D}${base_bindir}
+	[ "${base_bindir}" != "${bindir}" ] && for i in ${base_bindir_progs}; do mv ${D}${bindir}/$i ${D}${base_bindir}/$i.${BPN}; done
+
+	install -d ${D}${sbindir}
+	[ "${sbindir}" != "${bindir}" ] && for i in ${sbindir_progs}; do mv ${D}${bindir}/$i ${D}${sbindir}/$i.${BPN}; done
+
+	# [ requires special handling because [.coreutils will cause the sed stuff
+	# in update-alternatives to fail, therefore use lbracket - the name used
+	# for the actual source file.
+	mv ${D}${bindir}/[ ${D}${bindir}/lbracket.${BPN}
+}
+
+inherit update-alternatives
+
+ALTERNATIVE_PRIORITY = "100"
+# Make hostname's priority higher than busybox but lower than net-tools
+ALTERNATIVE_PRIORITY[hostname] = "90"
+ALTERNATIVE_${PN} = "lbracket ${bindir_progs} ${base_bindir_progs} ${sbindir_progs} base64 nice printenv mktemp df"
+ALTERNATIVE_${PN}-doc = "base64.1 nice.1 mktemp.1 df.1 groups.1 kill.1 uptime.1 stat.1 hostname.1"
+
+ALTERNATIVE_LINK_NAME[hostname.1] = "${mandir}/man1/hostname.1"
+
+ALTERNATIVE_LINK_NAME[base64] = "${base_bindir}/base64"
+ALTERNATIVE_TARGET[base64] = "${bindir}/base64.${BPN}"
+ALTERNATIVE_LINK_NAME[base64.1] = "${mandir}/man1/base64.1"
+
+ALTERNATIVE_LINK_NAME[mktemp] = "${base_bindir}/mktemp"
+ALTERNATIVE_TARGET[mktemp] = "${bindir}/mktemp.${BPN}"
+ALTERNATIVE_LINK_NAME[mktemp.1] = "${mandir}/man1/mktemp.1"
+
+ALTERNATIVE_LINK_NAME[df] = "${base_bindir}/df"
+ALTERNATIVE_TARGET[df] = "${bindir}/df.${BPN}"
+ALTERNATIVE_LINK_NAME[df.1] = "${mandir}/man1/df.1"
+
+ALTERNATIVE_LINK_NAME[nice] = "${base_bindir}/nice"
+ALTERNATIVE_TARGET[nice] = "${bindir}/nice.${BPN}"
+ALTERNATIVE_LINK_NAME[nice.1] = "${mandir}/man1/nice.1"
+
+ALTERNATIVE_LINK_NAME[printenv] = "${base_bindir}/printenv"
+ALTERNATIVE_TARGET[printenv] = "${bindir}/printenv.${BPN}"
+
+ALTERNATIVE_LINK_NAME[lbracket] = "${bindir}/["
+ALTERNATIVE_TARGET[lbracket] = "${bindir}/lbracket.${BPN}"
+
+ALTERNATIVE_LINK_NAME[groups.1] = "${mandir}/man1/groups.1"
+ALTERNATIVE_LINK_NAME[uptime.1] = "${mandir}/man1/uptime.1"
+ALTERNATIVE_LINK_NAME[kill.1] = "${mandir}/man1/kill.1"
+ALTERNATIVE_LINK_NAME[stat.1] = "${mandir}/man1/stat.1"
+
+python __anonymous() {
+	for prog in d.getVar('base_bindir_progs').split():
+		d.setVarFlag('ALTERNATIVE_LINK_NAME', prog, '%s/%s' % (d.getVar('base_bindir'), prog))
+
+	for prog in d.getVar('sbindir_progs').split():
+		d.setVarFlag('ALTERNATIVE_LINK_NAME', prog, '%s/%s' % (d.getVar('sbindir'), prog))
+}
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-core/dbus/dbus-glib.inc b/poky/meta/recipes-core/dbus/dbus-glib.inc
deleted file mode 100644
index 55f710f..0000000
--- a/poky/meta/recipes-core/dbus/dbus-glib.inc
+++ /dev/null
@@ -1,39 +0,0 @@
-SUMMARY = "High level language (GLib) binding for D-Bus"
-DESCRIPTION = "GLib bindings for the D-Bus message bus that integrate \
-the D-Bus library with the GLib thread abstraction and main loop."
-HOMEPAGE = "http://www.freedesktop.org/Software/dbus"
-LICENSE = "AFL-2 | GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=cf5b3a2f7083750d504333114e738656 \
-                    file://dbus/dbus-glib.h;beginline=7;endline=21;md5=7755c9d7abccd5dbd25a6a974538bb3c"
-SECTION = "base"
-
-DEPENDS = "expat glib-2.0 virtual/libintl dbus-glib-native dbus"
-DEPENDS_class-native = "glib-2.0-native dbus-native"
-
-SRC_URI = "http://dbus.freedesktop.org/releases/dbus-glib/dbus-glib-${PV}.tar.gz \
-           file://no-examples.patch \
-           file://test-install-makefile.patch \
-"
-
-inherit autotools pkgconfig gettext bash-completion gtk-doc
-
-#default disable regression tests, some unit test code in non testing code
-#PACKAGECONFIG_pn-${PN} = "tests" enable regression tests local.conf
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[tests] = "--enable-tests,,,"
-
-EXTRA_OECONF = "--with-introspect-xml=${STAGING_DATADIR_NATIVE}/dbus/dbus-bus-introspect.xml \
-                --with-dbus-binding-tool=${STAGING_BINDIR_NATIVE}/dbus-binding-tool"
-EXTRA_OECONF_class-native = "--with-introspect-xml=${STAGING_DATADIR_NATIVE}/dbus/dbus-bus-introspect.xml"
-
-PACKAGES += "${PN}-tests"
-
-FILES_${PN} = "${libdir}/lib*${SOLIBS}"
-FILES_${PN}-bash-completion += "${libexecdir}/dbus-bash-completion-helper"
-FILES_${PN}-dev += "${libdir}/dbus-1.0/include ${bindir}/dbus-glib-tool"
-FILES_${PN}-dev += "${bindir}/dbus-binding-tool"
-
-RDEPENDS_${PN}-tests += "dbus-x11"
-FILES_${PN}-tests = "${datadir}/${BPN}/tests"
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-core/dbus/dbus-glib_0.108.bb b/poky/meta/recipes-core/dbus/dbus-glib_0.108.bb
deleted file mode 100644
index 7a9a69e..0000000
--- a/poky/meta/recipes-core/dbus/dbus-glib_0.108.bb
+++ /dev/null
@@ -1,4 +0,0 @@
-require dbus-glib.inc
-
-SRC_URI[md5sum] = "a66a613705870752ca9786e0359aea97"
-SRC_URI[sha256sum] = "9f340c7e2352e9cdf113893ca77ca9075d9f8d5e81476bf2bf361099383c602c"
diff --git a/poky/meta/recipes-core/dbus/dbus-glib_0.110.bb b/poky/meta/recipes-core/dbus/dbus-glib_0.110.bb
new file mode 100644
index 0000000..b7383bd
--- /dev/null
+++ b/poky/meta/recipes-core/dbus/dbus-glib_0.110.bb
@@ -0,0 +1,39 @@
+SUMMARY = "High level language (GLib) binding for D-Bus"
+DESCRIPTION = "GLib bindings for the D-Bus message bus that integrate \
+the D-Bus library with the GLib thread abstraction and main loop."
+HOMEPAGE = "http://www.freedesktop.org/Software/dbus"
+LICENSE = "AFL-2 | GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=cf5b3a2f7083750d504333114e738656 \
+                    file://dbus/dbus-glib.h;beginline=7;endline=21;md5=7755c9d7abccd5dbd25a6a974538bb3c"
+SECTION = "base"
+
+DEPENDS = "expat glib-2.0 virtual/libintl dbus-glib-native dbus"
+DEPENDS_class-native = "glib-2.0-native dbus-native"
+
+SRC_URI = "http://dbus.freedesktop.org/releases/dbus-glib/dbus-glib-${PV}.tar.gz \
+           file://no-examples.patch \
+           file://test-install-makefile.patch \
+"
+SRC_URI[md5sum] = "d7cebf1d69445cbd28b4983392145192"
+SRC_URI[sha256sum] = "7ce4760cf66c69148f6bd6c92feaabb8812dee30846b24cd0f7395c436d7e825"
+
+inherit autotools pkgconfig gettext bash-completion gtk-doc
+
+#default disable regression tests, some unit test code in non testing code
+#PACKAGECONFIG_pn-${PN} = "tests" enable regression tests local.conf
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[tests] = "--enable-tests,,,"
+
+EXTRA_OECONF_class-target = "--with-dbus-binding-tool=${STAGING_BINDIR_NATIVE}/dbus-binding-tool"
+
+PACKAGES += "${PN}-tests"
+
+FILES_${PN} = "${libdir}/lib*${SOLIBS}"
+FILES_${PN}-bash-completion += "${libexecdir}/dbus-bash-completion-helper"
+FILES_${PN}-dev += "${libdir}/dbus-1.0/include ${bindir}/dbus-glib-tool"
+FILES_${PN}-dev += "${bindir}/dbus-binding-tool"
+
+RDEPENDS_${PN}-tests += "dbus-x11"
+FILES_${PN}-tests = "${datadir}/${BPN}/tests"
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-core/dbus/dbus-test_1.12.10.bb b/poky/meta/recipes-core/dbus/dbus-test_1.12.10.bb
new file mode 100644
index 0000000..25b9395
--- /dev/null
+++ b/poky/meta/recipes-core/dbus/dbus-test_1.12.10.bb
@@ -0,0 +1,83 @@
+SUMMARY = "D-Bus test package (for D-bus functionality testing only)"
+HOMEPAGE = "http://dbus.freedesktop.org"
+SECTION = "base"
+LICENSE = "AFL-2 | GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=10dded3b58148f3f1fd804b26354af3e \
+                    file://dbus/dbus.h;beginline=6;endline=20;md5=7755c9d7abccd5dbd25a6a974538bb3c"
+
+DEPENDS = "dbus glib-2.0"
+
+RDEPENDS_${PN} += "make"
+RDEPENDS_${PN}-dev = ""
+
+SRC_URI = "http://dbus.freedesktop.org/releases/dbus/dbus-${PV}.tar.gz \
+           file://tmpdir.patch \
+           file://run-ptest \
+           file://python-config.patch \
+           file://clear-guid_from_server-if-send_negotiate_unix_f.patch \
+           "
+
+SRC_URI[md5sum] = "c3e12b4206e2a7da39d7cc42567790ef"
+SRC_URI[sha256sum] = "4b693d24976258c3f2fa9cc33ad9288c5fbfa7a16481dbd9a8a429f7aa8cdcf7"
+
+S="${WORKDIR}/dbus-${PV}"
+FILESEXTRAPATHS =. "${FILE_DIRNAME}/dbus:"
+
+inherit autotools pkgconfig gettext ptest upstream-version-is-even
+
+EXTRA_OECONF_X = "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '--with-x', '--without-x', d)}"
+EXTRA_OECONF_X_class-native = "--without-x"
+
+EXTRA_OECONF = "--enable-tests \
+                --enable-modular-tests \
+                --enable-installed-tests \
+                --enable-checks \
+                --enable-asserts \
+                --enable-verbose-mode \
+                --enable-largefile \
+                --disable-xml-docs \
+                --disable-doxygen-docs \
+                --disable-libaudit \
+                --with-dbus-test-dir=${PTEST_PATH} \
+                ${EXTRA_OECONF_X}"
+
+EXTRA_OECONF_append_class-target = " SYSTEMCTL=${base_bindir}/systemctl"
+
+PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd x11', d)}"
+PACKAGECONFIG_class-native = ""
+PACKAGECONFIG_class-nativesdk = ""
+
+PACKAGECONFIG[systemd] = "--enable-systemd --with-systemdsystemunitdir=${systemd_system_unitdir},--disable-systemd --without-systemdsystemunitdir,systemd"
+PACKAGECONFIG[x11] = "--with-x --enable-x11-autolaunch,--without-x --disable-x11-autolaunch, virtual/libx11 libsm"
+PACKAGECONFIG[user-session] = "--enable-user-session --with-systemduserunitdir=${systemd_user_unitdir},--disable-user-session"
+
+do_install() {
+    :
+}
+
+do_install_ptest() {
+	install -d ${D}${PTEST_PATH}/test
+	l="shell printf refs syslog marshal syntax corrupt dbus-daemon dbus-daemon-eavesdrop loopback relay \
+	   variant uid-permissions syntax spawn sd-activation names monitor message fdpass "
+	for i in $l; do install ${B}/test/.libs/test-$i ${D}${PTEST_PATH}/test; done
+
+	l="bus bus-system bus-launch-helper"
+	for i in $l; do install ${B}/bus/.libs/test-$i ${D}${PTEST_PATH}/test; done
+
+	cp -r ${B}/test/data ${D}${PTEST_PATH}/test
+	install ${B}/dbus/.libs/test-dbus ${D}${PTEST_PATH}/test
+
+	install -d ${D}${PTEST_PATH}/test/.libs
+	cp -a ${B}/dbus/.libs/*.so* ${D}${PTEST_PATH}/test/.libs
+
+	# Remove build host references...
+	find "${D}${PTEST_PATH}/test/data" \( -name *.service -o -name *.conf -o -name "*.aaprofile" \) -type f -exec \
+		sed -i \
+		 -e 's:${B}:${PTEST_PATH}:g' \
+		 {} +
+        sed -i -e 's;@PTEST_PATH@;${PTEST_PATH};g'  ${D}${PTEST_PATH}/run-ptest
+}
+
+RDEPENDS_${PN}-ptest += "bash"
+
+PRIVATE_LIBS_${PN}-ptest = "libdbus-1.so.3"
diff --git a/poky/meta/recipes-core/dbus/dbus-test_1.12.2.bb b/poky/meta/recipes-core/dbus/dbus-test_1.12.2.bb
deleted file mode 100644
index dce047a..0000000
--- a/poky/meta/recipes-core/dbus/dbus-test_1.12.2.bb
+++ /dev/null
@@ -1,82 +0,0 @@
-SUMMARY = "D-Bus test package (for D-bus functionality testing only)"
-HOMEPAGE = "http://dbus.freedesktop.org"
-SECTION = "base"
-LICENSE = "AFL-2 | GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=10dded3b58148f3f1fd804b26354af3e \
-                    file://dbus/dbus.h;beginline=6;endline=20;md5=7755c9d7abccd5dbd25a6a974538bb3c"
-
-DEPENDS = "dbus glib-2.0"
-
-RDEPENDS_${PN} += "make"
-RDEPENDS_${PN}-dev = ""
-
-SRC_URI = "http://dbus.freedesktop.org/releases/dbus/dbus-${PV}.tar.gz \
-           file://tmpdir.patch \
-           file://run-ptest \
-           file://python-config.patch \
-           file://clear-guid_from_server-if-send_negotiate_unix_f.patch \
-           "
-
-SRC_URI[md5sum] = "3361456cadb99aa6601bed5b48964254"
-SRC_URI[sha256sum] = "272bb5091770b047c8188b926d5e6038fa4fe6745488b2add96b23e2d9a83d88"
-
-S="${WORKDIR}/dbus-${PV}"
-FILESEXTRAPATHS =. "${FILE_DIRNAME}/dbus:"
-
-inherit autotools pkgconfig gettext ptest upstream-version-is-even
-
-EXTRA_OECONF_X = "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '--with-x', '--without-x', d)}"
-EXTRA_OECONF_X_class-native = "--without-x"
-
-EXTRA_OECONF = "--enable-tests \
-                --enable-modular-tests \
-                --enable-installed-tests \
-                --enable-checks \
-                --enable-asserts \
-                --enable-verbose-mode \
-                --enable-largefile \
-                --disable-xml-docs \
-                --disable-doxygen-docs \
-                --disable-libaudit \
-                --with-dbus-test-dir=${PTEST_PATH} \
-                ${EXTRA_OECONF_X}"
-
-EXTRA_OECONF_append_class-target = " SYSTEMCTL=${base_bindir}/systemctl"
-
-PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd x11', d)}"
-PACKAGECONFIG_class-native = ""
-PACKAGECONFIG_class-nativesdk = ""
-
-PACKAGECONFIG[systemd] = "--enable-systemd --with-systemdsystemunitdir=${systemd_system_unitdir},--disable-systemd --without-systemdsystemunitdir,systemd"
-PACKAGECONFIG[x11] = "--with-x --enable-x11-autolaunch,--without-x --disable-x11-autolaunch, virtual/libx11 libsm"
-PACKAGECONFIG[user-session] = "--enable-user-session --with-systemduserunitdir=${systemd_user_unitdir},--disable-user-session"
-
-do_install() {
-    :
-}
-
-do_install_ptest() {
-	install -d ${D}${PTEST_PATH}/test
-	l="shell printf refs syslog marshal syntax corrupt dbus-daemon dbus-daemon-eavesdrop loopback relay \
-	   variant uid-permissions syntax spawn sd-activation names monitor message fdpass "
-	for i in $l; do install ${B}/test/.libs/test-$i ${D}${PTEST_PATH}/test; done
-
-	l="bus bus-system bus-launch-helper"
-	for i in $l; do install ${B}/bus/.libs/test-$i ${D}${PTEST_PATH}/test; done
-
-	cp -r ${B}/test/data ${D}${PTEST_PATH}/test
-	install ${B}/dbus/.libs/test-dbus ${D}${PTEST_PATH}/test
-
-	install -d ${D}${PTEST_PATH}/test/.libs
-	cp -a ${B}/dbus/.libs/*.so* ${D}${PTEST_PATH}/test/.libs
-
-	# Remove build host references...
-	find "${D}${PTEST_PATH}/test/data" \( -name *.service -o -name *.conf -o -name "*.aaprofile" \) -type f -exec \
-		sed -i \
-		 -e 's:${B}:${PTEST_PATH}:g' \
-		 {} +
-}
-
-RDEPENDS_${PN}-ptest += "bash"
-
-PRIVATE_LIBS_${PN}-ptest = "libdbus-1.so.3"
diff --git a/poky/meta/recipes-core/dbus/dbus/run-ptest b/poky/meta/recipes-core/dbus/dbus/run-ptest
index 8a8970e..353ba1e 100755
--- a/poky/meta/recipes-core/dbus/dbus/run-ptest
+++ b/poky/meta/recipes-core/dbus/dbus/run-ptest
@@ -12,7 +12,7 @@
 
 export DBUS_TEST_HOMEDIR=./test
 export XDG_RUNTIME_DIR=./test
-export LD_LIBRARY_PATH=/usr/lib/dbus-test/ptest/test/.libs
+export LD_LIBRARY_PATH=@PTEST_PATH@/test/.libs
 
 files=`ls test/test-*`
 
diff --git a/poky/meta/recipes-core/dbus/dbus_1.12.10.bb b/poky/meta/recipes-core/dbus/dbus_1.12.10.bb
new file mode 100644
index 0000000..d71f7f7
--- /dev/null
+++ b/poky/meta/recipes-core/dbus/dbus_1.12.10.bb
@@ -0,0 +1,176 @@
+SUMMARY = "D-Bus message bus"
+DESCRIPTION = "D-Bus is a message bus system, a simple way for applications to talk to one another. In addition to interprocess communication, D-Bus helps coordinate process lifecycle; it makes it simple and reliable to code a \"single instance\" application or daemon, and to launch applications and daemons on demand when their services are needed."
+HOMEPAGE = "http://dbus.freedesktop.org"
+SECTION = "base"
+LICENSE = "AFL-2 | GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=10dded3b58148f3f1fd804b26354af3e \
+                    file://dbus/dbus.h;beginline=6;endline=20;md5=7755c9d7abccd5dbd25a6a974538bb3c"
+DEPENDS = "expat virtual/libintl autoconf-archive"
+RDEPENDS_dbus_class-native = ""
+RDEPENDS_dbus_class-nativesdk = ""
+PACKAGES += "${@bb.utils.contains('DISTRO_FEATURES', 'ptest', '${PN}-ptest', '', d)}"
+ALLOW_EMPTY_dbus-ptest = "1"
+RDEPENDS_dbus-ptest_class-target = "dbus-test-ptest"
+
+SRC_URI = "http://dbus.freedesktop.org/releases/dbus/dbus-${PV}.tar.gz \
+           file://tmpdir.patch \
+           file://dbus-1.init \
+           file://clear-guid_from_server-if-send_negotiate_unix_f.patch \
+"
+
+SRC_URI[md5sum] = "c3e12b4206e2a7da39d7cc42567790ef"
+SRC_URI[sha256sum] = "4b693d24976258c3f2fa9cc33ad9288c5fbfa7a16481dbd9a8a429f7aa8cdcf7"
+
+inherit useradd autotools pkgconfig gettext update-rc.d upstream-version-is-even
+
+INITSCRIPT_NAME = "dbus-1"
+INITSCRIPT_PARAMS = "start 02 5 3 2 . stop 20 0 1 6 ."
+
+python __anonymous() {
+    if not bb.utils.contains('DISTRO_FEATURES', 'sysvinit', True, False, d):
+        d.setVar("INHIBIT_UPDATERCD_BBCLASS", "1")
+}
+
+USERADD_PACKAGES = "${PN}"
+GROUPADD_PARAM_${PN} = "-r netdev"
+USERADD_PARAM_${PN} = "--system --home ${localstatedir}/lib/dbus \
+                       --no-create-home --shell /bin/false \
+                       --user-group messagebus"
+
+CONFFILES_${PN} = "${sysconfdir}/dbus-1/system.conf ${sysconfdir}/dbus-1/session.conf"
+
+DEBIANNAME_${PN} = "dbus-1"
+
+PACKAGES =+ "${PN}-lib"
+
+OLDPKGNAME = "dbus-x11"
+OLDPKGNAME_class-nativesdk = ""
+
+# for compatibility
+RPROVIDES_${PN} = "${OLDPKGNAME}"
+RREPLACES_${PN} += "${OLDPKGNAME}"
+
+FILES_${PN} = "${bindir}/dbus-daemon* \
+               ${bindir}/dbus-uuidgen \
+               ${bindir}/dbus-cleanup-sockets \
+               ${bindir}/dbus-send \
+               ${bindir}/dbus-monitor \
+               ${bindir}/dbus-launch \
+               ${bindir}/dbus-run-session \
+               ${bindir}/dbus-update-activation-environment \
+               ${libexecdir}/dbus* \
+               ${sysconfdir} \
+               ${localstatedir} \
+               ${datadir}/dbus-1/services \
+               ${datadir}/dbus-1/system-services \
+               ${datadir}/dbus-1/session.d \
+               ${datadir}/dbus-1/session.conf \
+               ${datadir}/dbus-1/system.d \
+               ${datadir}/dbus-1/system.conf \
+               ${datadir}/xml/dbus-1 \
+               ${systemd_system_unitdir} \
+               ${systemd_user_unitdir} \
+               ${nonarch_libdir}/sysusers.d/dbus.conf \
+               ${nonarch_libdir}/tmpfiles.d/dbus.conf \
+"
+FILES_${PN}-lib = "${libdir}/lib*.so.*"
+RRECOMMENDS_${PN}-lib = "${PN}"
+FILES_${PN}-dev += "${libdir}/dbus-1.0/include ${libdir}/cmake/DBus1 ${bindir}/dbus-test-tool"
+
+PACKAGE_WRITE_DEPS += "${@bb.utils.contains('DISTRO_FEATURES','systemd sysvinit','systemd-systemctl-native','',d)}"
+pkg_postinst_dbus() {
+	# If both systemd and sysvinit are enabled, mask the dbus-1 init script
+        if ${@bb.utils.contains('DISTRO_FEATURES','systemd sysvinit','true','false',d)}; then
+		if [ -n "$D" ]; then
+			OPTS="--root=$D"
+		fi
+		systemctl $OPTS mask dbus-1.service
+	fi
+
+	if [ -z "$D" ] && [ -e /etc/init.d/populate-volatile.sh ] ; then
+		/etc/init.d/populate-volatile.sh update
+	fi
+}
+
+EXTRA_OECONF = "--disable-tests \
+                --disable-xml-docs \
+                --disable-doxygen-docs \
+                --disable-libaudit \
+                --enable-largefile \
+                "
+
+EXTRA_OECONF_append_class-target = " SYSTEMCTL=${base_bindir}/systemctl"
+EXTRA_OECONF_append_class-native = " --disable-selinux"
+
+PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd x11', d)} \
+                   user-session \
+                  "
+
+PACKAGECONFIG_class-native = ""
+PACKAGECONFIG_class-nativesdk = ""
+
+PACKAGECONFIG[systemd] = "--enable-systemd --with-systemdsystemunitdir=${systemd_system_unitdir},--disable-systemd --without-systemdsystemunitdir,systemd"
+PACKAGECONFIG[x11] = "--with-x --enable-x11-autolaunch,--without-x --disable-x11-autolaunch, virtual/libx11 libsm"
+PACKAGECONFIG[user-session] = "--enable-user-session --with-systemduserunitdir=${systemd_user_unitdir},--disable-user-session"
+
+do_install() {
+	autotools_do_install
+
+	if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
+		install -d ${D}${sysconfdir}/init.d
+		sed 's:@bindir@:${bindir}:' < ${WORKDIR}/dbus-1.init >${WORKDIR}/dbus-1.init.sh
+		install -m 0755 ${WORKDIR}/dbus-1.init.sh ${D}${sysconfdir}/init.d/dbus-1
+	fi
+
+	if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+		for i in dbus.target.wants sockets.target.wants multi-user.target.wants; do \
+			install -d ${D}${systemd_system_unitdir}/$i; done
+		install -m 0644 ${B}/bus/dbus.service ${B}/bus/dbus.socket ${D}${systemd_system_unitdir}/
+		ln -fs ../dbus.socket ${D}${systemd_system_unitdir}/dbus.target.wants/dbus.socket
+		ln -fs ../dbus.socket ${D}${systemd_system_unitdir}/sockets.target.wants/dbus.socket
+		ln -fs ../dbus.service ${D}${systemd_system_unitdir}/multi-user.target.wants/dbus.service
+	fi
+
+	install -d ${D}${sysconfdir}/default/volatiles
+	echo "d messagebus messagebus 0755 ${localstatedir}/run/dbus none" \
+	     > ${D}${sysconfdir}/default/volatiles/99_dbus
+
+
+	mkdir -p ${D}${localstatedir}/lib/dbus
+
+	chown messagebus:messagebus ${D}${localstatedir}/lib/dbus
+
+	chown root:messagebus ${D}${libexecdir}/dbus-daemon-launch-helper
+	chmod 4755 ${D}${libexecdir}/dbus-daemon-launch-helper
+
+	# Remove Red Hat initscript
+	rm -rf ${D}${sysconfdir}/rc.d
+
+	# Remove empty testexec directory as we don't build tests
+	rm -rf ${D}${libdir}/dbus-1.0/test
+
+	# Remove /var/run as it is created on startup
+	rm -rf ${D}${localstatedir}/run
+}
+
+do_install_class-native() {
+	autotools_do_install
+
+	# dbus-launch has no X support so lets not install it in case the host
+	# has a more featured and useful version
+	rm -f ${D}${bindir}/dbus-launch
+}
+
+do_install_class-nativesdk() {
+	autotools_do_install
+
+	# dbus-launch has no X support so lets not install it in case the host
+	# has a more featured and useful version
+	rm -f ${D}${bindir}/dbus-launch
+
+	# Remove /var/run to avoid QA error
+	rm -rf ${D}${localstatedir}/run
+}
+BBCLASSEXTEND = "native nativesdk"
+
+INSANE_SKIP_${PN}-ptest += "build-deps"
diff --git a/poky/meta/recipes-core/dbus/dbus_1.12.2.bb b/poky/meta/recipes-core/dbus/dbus_1.12.2.bb
deleted file mode 100644
index fb5b69a..0000000
--- a/poky/meta/recipes-core/dbus/dbus_1.12.2.bb
+++ /dev/null
@@ -1,181 +0,0 @@
-SUMMARY = "D-Bus message bus"
-DESCRIPTION = "D-Bus is a message bus system, a simple way for applications to talk to one another. In addition to interprocess communication, D-Bus helps coordinate process lifecycle; it makes it simple and reliable to code a \"single instance\" application or daemon, and to launch applications and daemons on demand when their services are needed."
-HOMEPAGE = "http://dbus.freedesktop.org"
-SECTION = "base"
-LICENSE = "AFL-2 | GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=10dded3b58148f3f1fd804b26354af3e \
-                    file://dbus/dbus.h;beginline=6;endline=20;md5=7755c9d7abccd5dbd25a6a974538bb3c"
-DEPENDS = "expat virtual/libintl autoconf-archive"
-RDEPENDS_dbus_class-native = ""
-RDEPENDS_dbus_class-nativesdk = ""
-PACKAGES += "${@bb.utils.contains('DISTRO_FEATURES', 'ptest', '${PN}-ptest', '', d)}"
-ALLOW_EMPTY_dbus-ptest = "1"
-RDEPENDS_dbus-ptest_class-target = "dbus-test-ptest"
-
-SRC_URI = "http://dbus.freedesktop.org/releases/dbus/dbus-${PV}.tar.gz \
-           file://tmpdir.patch \
-           file://dbus-1.init \
-           file://clear-guid_from_server-if-send_negotiate_unix_f.patch \
-"
-
-SRC_URI[md5sum] = "3361456cadb99aa6601bed5b48964254"
-SRC_URI[sha256sum] = "272bb5091770b047c8188b926d5e6038fa4fe6745488b2add96b23e2d9a83d88"
-
-inherit useradd autotools pkgconfig gettext update-rc.d upstream-version-is-even
-
-INITSCRIPT_NAME = "dbus-1"
-INITSCRIPT_PARAMS = "start 02 5 3 2 . stop 20 0 1 6 ."
-
-python __anonymous() {
-    if not bb.utils.contains('DISTRO_FEATURES', 'sysvinit', True, False, d):
-        d.setVar("INHIBIT_UPDATERCD_BBCLASS", "1")
-}
-
-USERADD_PACKAGES = "${PN}"
-GROUPADD_PARAM_${PN} = "-r netdev"
-USERADD_PARAM_${PN} = "--system --home ${localstatedir}/lib/dbus \
-                       --no-create-home --shell /bin/false \
-                       --user-group messagebus"
-
-CONFFILES_${PN} = "${sysconfdir}/dbus-1/system.conf ${sysconfdir}/dbus-1/session.conf"
-
-DEBIANNAME_${PN} = "dbus-1"
-
-PACKAGES =+ "${PN}-lib"
-
-OLDPKGNAME = "dbus-x11"
-OLDPKGNAME_class-nativesdk = ""
-
-# for compatibility
-RPROVIDES_${PN} = "${OLDPKGNAME}"
-RREPLACES_${PN} += "${OLDPKGNAME}"
-
-FILES_${PN} = "${bindir}/dbus-daemon* \
-               ${bindir}/dbus-uuidgen \
-               ${bindir}/dbus-cleanup-sockets \
-               ${bindir}/dbus-send \
-               ${bindir}/dbus-monitor \
-               ${bindir}/dbus-launch \
-               ${bindir}/dbus-run-session \
-               ${bindir}/dbus-update-activation-environment \
-               ${libexecdir}/dbus* \
-               ${sysconfdir} \
-               ${localstatedir} \
-               ${datadir}/dbus-1/services \
-               ${datadir}/dbus-1/system-services \
-               ${datadir}/dbus-1/session.d \
-               ${datadir}/dbus-1/session.conf \
-               ${datadir}/dbus-1/system.d \
-               ${datadir}/dbus-1/system.conf \
-               ${datadir}/xml/dbus-1 \
-               ${systemd_system_unitdir} \
-               ${systemd_user_unitdir} \
-               ${nonarch_libdir}/sysusers.d/dbus.conf \
-               ${nonarch_libdir}/tmpfiles.d/dbus.conf \
-"
-FILES_${PN}-lib = "${libdir}/lib*.so.*"
-RRECOMMENDS_${PN}-lib = "${PN}"
-FILES_${PN}-dev += "${libdir}/dbus-1.0/include ${libdir}/cmake/DBus1 ${bindir}/dbus-test-tool"
-
-PACKAGE_WRITE_DEPS += "${@bb.utils.contains('DISTRO_FEATURES','systemd sysvinit','systemd-systemctl-native','',d)}"
-pkg_postinst_dbus() {
-	# If both systemd and sysvinit are enabled, mask the dbus-1 init script
-        if ${@bb.utils.contains('DISTRO_FEATURES','systemd sysvinit','true','false',d)}; then
-		if [ -n "$D" ]; then
-			OPTS="--root=$D"
-		fi
-		systemctl $OPTS mask dbus-1.service
-	fi
-
-	if [ -z "$D" ] && [ -e /etc/init.d/populate-volatile.sh ] ; then
-		/etc/init.d/populate-volatile.sh update
-	fi
-}
-
-EXTRA_OECONF = "--disable-tests \
-                --disable-xml-docs \
-                --disable-doxygen-docs \
-                --disable-libaudit \
-                --enable-largefile \
-                "
-
-EXTRA_OECONF_append_class-target = " SYSTEMCTL=${base_bindir}/systemctl"
-EXTRA_OECONF_append_class-native = " --disable-selinux"
-
-PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd x11', d)}"
-PACKAGECONFIG_class-native = ""
-PACKAGECONFIG_class-nativesdk = ""
-
-PACKAGECONFIG[systemd] = "--enable-systemd --with-systemdsystemunitdir=${systemd_system_unitdir},--disable-systemd --without-systemdsystemunitdir,systemd"
-PACKAGECONFIG[x11] = "--with-x --enable-x11-autolaunch,--without-x --disable-x11-autolaunch, virtual/libx11 libsm"
-PACKAGECONFIG[user-session] = "--enable-user-session --with-systemduserunitdir=${systemd_user_unitdir},--disable-user-session"
-
-do_install() {
-	autotools_do_install
-
-	if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
-		install -d ${D}${sysconfdir}/init.d
-		sed 's:@bindir@:${bindir}:' < ${WORKDIR}/dbus-1.init >${WORKDIR}/dbus-1.init.sh
-		install -m 0755 ${WORKDIR}/dbus-1.init.sh ${D}${sysconfdir}/init.d/dbus-1
-	fi
-
-	if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-		for i in dbus.target.wants sockets.target.wants multi-user.target.wants; do \
-			install -d ${D}${systemd_system_unitdir}/$i; done
-		install -m 0644 ${B}/bus/dbus.service ${B}/bus/dbus.socket ${D}${systemd_system_unitdir}/
-		ln -fs ../dbus.socket ${D}${systemd_system_unitdir}/dbus.target.wants/dbus.socket
-		ln -fs ../dbus.socket ${D}${systemd_system_unitdir}/sockets.target.wants/dbus.socket
-		ln -fs ../dbus.service ${D}${systemd_system_unitdir}/multi-user.target.wants/dbus.service
-	fi
-
-	install -d ${D}${sysconfdir}/default/volatiles
-	echo "d messagebus messagebus 0755 ${localstatedir}/run/dbus none" \
-	     > ${D}${sysconfdir}/default/volatiles/99_dbus
-
-
-	mkdir -p ${D}${localstatedir}/lib/dbus
-
-	chown messagebus:messagebus ${D}${localstatedir}/lib/dbus
-
-	chown root:messagebus ${D}${libexecdir}/dbus-daemon-launch-helper
-	chmod 4755 ${D}${libexecdir}/dbus-daemon-launch-helper
-
-	# Remove Red Hat initscript
-	rm -rf ${D}${sysconfdir}/rc.d
-
-	# Remove empty testexec directory as we don't build tests
-	rm -rf ${D}${libdir}/dbus-1.0/test
-
-	# Remove /var/run as it is created on startup
-	rm -rf ${D}${localstatedir}/run
-}
-
-do_install_class-native() {
-	autotools_do_install
-
-	# for dbus-glib-native introspection generation
-	install -d ${D}${STAGING_DATADIR_NATIVE}/dbus/
-	# N.B. is below install actually required?
-	install -m 0644 bus/session.conf ${D}${STAGING_DATADIR_NATIVE}/dbus/session.conf
-
-	# dbus-glib-native and dbus-glib need this xml file
-	./bus/dbus-daemon --introspect > ${D}${STAGING_DATADIR_NATIVE}/dbus/dbus-bus-introspect.xml
-	
-	# dbus-launch has no X support so lets not install it in case the host
-	# has a more featured and useful version
-	rm -f ${D}${bindir}/dbus-launch
-}
-
-do_install_class-nativesdk() {
-	autotools_do_install
-
-	# dbus-launch has no X support so lets not install it in case the host
-	# has a more featured and useful version
-	rm -f ${D}${bindir}/dbus-launch
-
-	# Remove /var/run to avoid QA error
-	rm -rf ${D}${localstatedir}/run
-}
-BBCLASSEXTEND = "native nativesdk"
-
-INSANE_SKIP_${PN}-ptest += "build-deps"
diff --git a/poky/meta/recipes-core/dropbear/dropbear.inc b/poky/meta/recipes-core/dropbear/dropbear.inc
index b6b436c..d92a2f3 100644
--- a/poky/meta/recipes-core/dropbear/dropbear.inc
+++ b/poky/meta/recipes-core/dropbear/dropbear.inc
@@ -7,21 +7,19 @@
 LICENSE = "MIT & BSD-3-Clause & BSD-2-Clause & PD"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=a5ec40cafba26fc4396d0b550f824e01"
 
-DEPENDS = "zlib"
+DEPENDS = "zlib virtual/crypt"
 RPROVIDES_${PN} = "ssh sshd"
 
 DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)}"
 
 SRC_URI = "http://matt.ucc.asn.au/dropbear/releases/dropbear-${PV}.tar.bz2 \
+           file://CVE-2018-15599.patch \
            file://0001-urandom-xauth-changes-to-options.h.patch \
-           file://0003-configure.patch \
-           file://0004-fix-2kb-keys.patch \
-           file://0007-dropbear-fix-for-x32-abi.patch \
-           file://fix-libtomcrypt-libtommath-ordering.patch \
            file://init \
            file://dropbearkey.service \
            file://dropbear@.service \
            file://dropbear.socket \
+           file://dropbear.default \
            ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${PAM_SRC_URI}', '', d)} "
 
 PAM_SRC_URI = "file://0005-dropbear-enable-pam.patch \
@@ -52,6 +50,10 @@
 EXTRA_OECONF += "\
  ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '--enable-pam', '--disable-pam', d)}"
 
+# This option appends to CFLAGS and LDFLAGS from OE
+# This is causing [textrel] QA warning
+EXTRA_OECONF += "--disable-harden"
+
 do_install() {
 	install -d ${D}${sysconfdir} \
 		${D}${sysconfdir}/init.d \
@@ -61,6 +63,8 @@
 		${D}${sbindir} \
 		${D}${localstatedir}
 
+	install -m 0644 ${WORKDIR}/dropbear.default ${D}${sysconfdir}/default/dropbear
+
 	install -m 0755 dropbearmulti ${D}${sbindir}/
 	ln -s ${sbindir}/dropbearmulti ${D}${bindir}/dbclient
 
diff --git a/poky/meta/recipes-core/dropbear/dropbear/0001-urandom-xauth-changes-to-options.h.patch b/poky/meta/recipes-core/dropbear/dropbear/0001-urandom-xauth-changes-to-options.h.patch
index dc9d578..684641d 100644
--- a/poky/meta/recipes-core/dropbear/dropbear/0001-urandom-xauth-changes-to-options.h.patch
+++ b/poky/meta/recipes-core/dropbear/dropbear/0001-urandom-xauth-changes-to-options.h.patch
@@ -2,20 +2,20 @@
 
 Upstream-Status: Inappropriate [configuration]
 ---
- options.h | 2 +-
+ default_options.h | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-diff --git a/options.h b/options.h
-index 7d06322..71a21c2 100644
---- a/options.h
-+++ b/options.h
-@@ -247,7 +247,7 @@ much traffic. */
+diff --git a/default_options.h b/default_options.h
+index 3b75eb8..1fd8082 100644
+--- a/default_options.h
++++ b/default_options.h
+@@ -243,7 +243,7 @@ Homedir is prepended unless path begins with / */
+ 
  /* The command to invoke for xauth when using X11 forwarding.
   * "-q" for quiet */
- #ifndef XAUTH_COMMAND
 -#define XAUTH_COMMAND "/usr/bin/xauth -q"
 +#define XAUTH_COMMAND "xauth -q"
- #endif
+ 
  
  /* if you want to enable running an sftp server (such as the one included with
 -- 
diff --git a/poky/meta/recipes-core/dropbear/dropbear/0003-configure.patch b/poky/meta/recipes-core/dropbear/dropbear/0003-configure.patch
deleted file mode 100644
index 8469a50..0000000
--- a/poky/meta/recipes-core/dropbear/dropbear/0003-configure.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 58dd24a80ca0f400d0761afd9ce2b7f684fc9125 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Eric=20B=C3=A9nard?= <eric@eukrea.com>
-Date: Thu, 25 Apr 2013 00:27:25 +0200
-Subject: [PATCH] configure: add a variable to allow openpty check to be cached
-
-Upstream-Status: Submitted [ https://github.com/mkj/dropbear/pull/48 ]
-
-Signed-off-by: Dengke Du <dengke.du@windriver.com>
----
- configure.ac | 11 ++++++++---
- 1 file changed, 8 insertions(+), 3 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index 893b904..245408d 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -177,15 +177,20 @@ AC_ARG_ENABLE(openpty,
- 			AC_MSG_NOTICE(Not using openpty)
- 		else
- 			AC_MSG_NOTICE(Using openpty if available)
--			AC_SEARCH_LIBS(openpty, util, [AC_DEFINE(HAVE_OPENPTY,,Have openpty() function)])
-+			AC_SEARCH_LIBS(openpty, util, [dropbear_cv_func_have_openpty=yes])
- 		fi
- 	],
- 	[
- 		AC_MSG_NOTICE(Using openpty if available)
--		AC_SEARCH_LIBS(openpty, util, [AC_DEFINE(HAVE_OPENPTY)])
-+		AC_SEARCH_LIBS(openpty, util, [dropbear_cv_func_have_openpty=yes])
- 	]
- )
--		
-+
-+if test "x$dropbear_cv_func_have_openpty" = "xyes"; then
-+	AC_DEFINE(HAVE_OPENPTY,,Have openpty() function)
-+	no_ptc_check=yes
-+	no_ptmx_check=yes
-+fi
- 
- AC_ARG_ENABLE(syslog,
- 	[  --disable-syslog        Don't include syslog support],
--- 
-2.8.1
-
diff --git a/poky/meta/recipes-core/dropbear/dropbear/0004-fix-2kb-keys.patch b/poky/meta/recipes-core/dropbear/dropbear/0004-fix-2kb-keys.patch
deleted file mode 100644
index 60c6a29..0000000
--- a/poky/meta/recipes-core/dropbear/dropbear/0004-fix-2kb-keys.patch
+++ /dev/null
@@ -1,19 +0,0 @@
-Subject: [PATCH 4/6] fix 2kb keys
-
-Upstream-Status: Inappropriate [configuration]
----
- kex.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-Index: dropbear-2017.75/kex.h
-===================================================================
---- dropbear-2017.75.orig/kex.h
-+++ dropbear-2017.75/kex.h
-@@ -106,6 +106,6 @@ int curve25519_donna(unsigned char *out,
- #endif
- 
- 
--#define MAX_KEXHASHBUF 2000
-+#define MAX_KEXHASHBUF 3000
- 
- #endif /* DROPBEAR_KEX_H_ */
diff --git a/poky/meta/recipes-core/dropbear/dropbear/0005-dropbear-enable-pam.patch b/poky/meta/recipes-core/dropbear/dropbear/0005-dropbear-enable-pam.patch
index 539cb12..8576815 100644
--- a/poky/meta/recipes-core/dropbear/dropbear/0005-dropbear-enable-pam.patch
+++ b/poky/meta/recipes-core/dropbear/dropbear/0005-dropbear-enable-pam.patch
@@ -3,7 +3,7 @@
 Date: Wed, 2 Dec 2015 11:36:02 +0200
 Subject: Enable pam
 
-We need modify file option.h besides enabling pam in
+We need modify file default_options.h besides enabling pam in
 configure if we want dropbear to support pam.
 
 Upstream-Status: Pending
@@ -11,26 +11,32 @@
 Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
 Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
 ---
- options.h | 4 ++--
+ default_options.h | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
 
-diff --git a/options.h b/options.h
-index 94261f6..90bfe2f 100644
---- a/options.h
-+++ b/options.h
-@@ -208,10 +208,10 @@ If you test it please contact the Dropbear author */
+diff --git a/default_options.h b/default_options.h
+index 3b75eb8..8617cd0 100644
+--- a/default_options.h
++++ b/default_options.h
+@@ -179,7 +179,7 @@ group1 in Dropbear server too */
  
- /* This requires crypt() */
- #ifdef HAVE_CRYPT
--#define ENABLE_SVR_PASSWORD_AUTH
-+/*#define ENABLE_SVR_PASSWORD_AUTH*/
- #endif
- /* PAM requires ./configure --enable-pam */
--/*#define ENABLE_SVR_PAM_AUTH */
-+#define ENABLE_SVR_PAM_AUTH
- #define ENABLE_SVR_PUBKEY_AUTH
+ /* Authentication Types - at least one required.
+    RFC Draft requires pubkey auth, and recommends password */
+-#define DROPBEAR_SVR_PASSWORD_AUTH 1
++#define DROPBEAR_SVR_PASSWORD_AUTH 0
  
- /* Whether to take public key options in 
+ /* Note: PAM auth is quite simple and only works for PAM modules which just do
+  * a simple "Login: " "Password: " (you can edit the strings in svr-authpam.c).
+@@ -187,7 +187,7 @@ group1 in Dropbear server too */
+  * but there's an interface via a PAM module. It won't work for more complex
+  * PAM challenge/response.
+  * You can't enable both PASSWORD and PAM. */
+-#define DROPBEAR_SVR_PAM_AUTH 0
++#define DROPBEAR_SVR_PAM_AUTH 1
+ 
+ /* ~/.ssh/authorized_keys authentication */
+ #define DROPBEAR_SVR_PUBKEY_AUTH 1
+ 
 -- 
 2.1.4
 
diff --git a/poky/meta/recipes-core/dropbear/dropbear/0006-dropbear-configuration-file.patch b/poky/meta/recipes-core/dropbear/dropbear/0006-dropbear-configuration-file.patch
index fa4c8d0..deed78f 100644
--- a/poky/meta/recipes-core/dropbear/dropbear/0006-dropbear-configuration-file.patch
+++ b/poky/meta/recipes-core/dropbear/dropbear/0006-dropbear-configuration-file.patch
@@ -1,4 +1,7 @@
-Subject: [PATCH 6/6] dropbear configuration file
+From e3a5db1b6d3f6382a15b2266458c26c645a10f18 Mon Sep 17 00:00:00 2001
+From: Mingli Yu <Mingli.Yu@windriver.com>
+Date: Thu, 6 Sep 2018 15:54:00 +0800
+Subject: [PATCH] dropbear configuration file
 
 dropbear: Change the path ("/etc/pam.d/sshd" as default) to find a pam configuration file \
 to "/etc/pam.d/dropbear for dropbear when enabling pam supporting"
@@ -7,12 +10,17 @@
 
 Signed-off-by: Maxin B. John <maxin.john@enea.com>
 Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
+Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
 ---
-diff -Naur dropbear-2013.60-orig/svr-authpam.c dropbear-2013.60/svr-authpam.c
---- dropbear-2013.60-orig/svr-authpam.c	2013-10-16 16:34:53.000000000 +0200
-+++ dropbear-2013.60/svr-authpam.c	2013-10-21 17:04:04.969416055 +0200
-@@ -211,7 +211,7 @@
- 	userData.passwd = password;
+ svr-authpam.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/svr-authpam.c b/svr-authpam.c
+index d201bc9..165ec5c 100644
+--- a/svr-authpam.c
++++ b/svr-authpam.c
+@@ -223,7 +223,7 @@ void svr_auth_pam(int valid_user) {
+ 	}
  
  	/* Init pam */
 -	if ((rc = pam_start("sshd", NULL, &pamConv, &pamHandlep)) != PAM_SUCCESS) {
@@ -20,3 +28,6 @@
  		dropbear_log(LOG_WARNING, "pam_start() failed, rc=%d, %s", 
  				rc, pam_strerror(pamHandlep, rc));
  		goto cleanup;
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-core/dropbear/dropbear/0007-dropbear-fix-for-x32-abi.patch b/poky/meta/recipes-core/dropbear/dropbear/0007-dropbear-fix-for-x32-abi.patch
deleted file mode 100644
index 60b302b..0000000
--- a/poky/meta/recipes-core/dropbear/dropbear/0007-dropbear-fix-for-x32-abi.patch
+++ /dev/null
@@ -1,140 +0,0 @@
-Upstream-Status: Pending
-
-The dropbearkey utility built in x32 abi format, when generating ssh
-keys, was getting lost in the infinite loop.
-
-This patch fixes the issue by fixing types of variables and
-parameters of functions used in the code, which were getting
-undesired size, when compiled with the x32 abi toolchain.
-
-2013/05/23
-Received this fix from H J Lu.
-
-Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
-
-# HG changeset patch
-# User H.J. Lu <hjl.tools@gmail.com>
-# Date 1369344079 25200
-# Node ID a10a1c46b857cc8a3923c3bb6d1504aa25b6052f
-# Parent  e76614145aea67f66e4a4257685c771efba21aa1
-Typdef mp_digit to unsigned long long for MP_64BIT
-
-When GCC is used with MP_64BIT, we should typedef mp_digit to unsigned
-long long instead of unsigned long since for x32, unsigned long is
-32-bit and unsigned long long is 64-bit and it is safe to use unsigned
-long long for 64-bit integer with GCC.
-
-diff -r e76614145aea -r a10a1c46b857 libtommath/tommath.h
---- a/libtommath/tommath.h	Thu Apr 18 22:57:47 2013 +0800
-+++ b/libtommath/tommath.h	Thu May 23 14:21:19 2013 -0700
-@@ -73,7 +73,7 @@
-    typedef signed long long   long64;
- #endif
-
--   typedef unsigned long      mp_digit;
-+   typedef unsigned long long mp_digit;
-    typedef unsigned long      mp_word __attribute__ ((mode(TI)));
-
-    #define DIGIT_BIT          60
-# HG changeset patch
-# User H.J. Lu <hjl.tools@gmail.com>
-# Date 1369344241 25200
-# Node ID c7555a4cb7ded3a88409ba85f4027baa7af5f536
-# Parent  a10a1c46b857cc8a3923c3bb6d1504aa25b6052f
-Cast to mp_digit when updating *rho
-
-There is
-
-int
-mp_montgomery_setup (mp_int * n, mp_digit * rho)
-
-We should cast to mp_digit instead of unsigned long when updating
-*rho since mp_digit may be unsigned long long and unsigned long long
-may be different from unsigned long, like in x32.
-
-diff -r a10a1c46b857 -r c7555a4cb7de libtommath/bn_mp_montgomery_setup.c
---- a/libtommath/bn_mp_montgomery_setup.c	Thu May 23 14:21:19 2013 -0700
-+++ b/libtommath/bn_mp_montgomery_setup.c	Thu May 23 14:24:01 2013 -0700
-@@ -48,7 +48,7 @@
- #endif
-
-   /* rho = -1/m mod b */
--  *rho = (unsigned long)(((mp_word)1 << ((mp_word) DIGIT_BIT)) - x) & MP_MASK;
-+  *rho = (mp_digit)(((mp_word)1 << ((mp_word) DIGIT_BIT)) - x) & MP_MASK;
-
-   return MP_OKAY;
- }
-# HG changeset patch
-# User H.J. Lu <hjl.tools@gmail.com>
-# Date 1369344541 25200
-# Node ID 7c656e7071a6412688b2f30a529a9afac6c7bf5a
-# Parent  c7555a4cb7ded3a88409ba85f4027baa7af5f536
-Define LTC_FAST_TYPE to unsigned long long for __x86_64__
-
-We should define LTC_FAST_TYPE to unsigned long long instead of unsigned
-long if __x86_64__ to support x32 where unsigned long long is 64-bit
-and unsigned long is 32-bit.
-
-diff -r c7555a4cb7de -r 7c656e7071a6 libtomcrypt/src/headers/tomcrypt_cfg.h
---- a/libtomcrypt/src/headers/tomcrypt_cfg.h	Thu May 23 14:24:01 2013 -0700
-+++ b/libtomcrypt/src/headers/tomcrypt_cfg.h	Thu May 23 14:29:01 2013 -0700
-@@ -74,7 +74,7 @@
-    #define ENDIAN_LITTLE
-    #define ENDIAN_64BITWORD
-    #define LTC_FAST
--   #define LTC_FAST_TYPE    unsigned long
-+   #define LTC_FAST_TYPE    unsigned long long
- #endif
-
- /* detect PPC32 */
-# HG changeset patch
-# User H.J. Lu <hjl.tools@gmail.com>
-# Date 1369344730 25200
-# Node ID a7d4690158fae4ede2c4e5b56233e83730bf38ee
-# Parent  7c656e7071a6412688b2f30a529a9afac6c7bf5a
-Use unsigned long long aas unsigned 64-bit integer for x86-64 GCC
-
-We should use unsigned long long instead of unsigned long as unsigned
-64-bit integer for x86-64 GCC to support x32 where unsigned long is
-32-bit.
-
-diff -r 7c656e7071a6 -r a7d4690158fa libtomcrypt/src/headers/tomcrypt_macros.h
---- a/libtomcrypt/src/headers/tomcrypt_macros.h	Thu May 23 14:29:01 2013 -0700
-+++ b/libtomcrypt/src/headers/tomcrypt_macros.h	Thu May 23 14:32:10 2013 -0700
-@@ -343,7 +343,7 @@
- /* 64-bit Rotates */
- #if !defined(__STRICT_ANSI__) && defined(__GNUC__) && defined(__x86_64__) && !defined(LTC_NO_ASM)
-
--static inline unsigned long ROL64(unsigned long word, int i)
-+static inline unsigned long long ROL64(unsigned long long word, int i)
- {
-    asm("rolq %%cl,%0"
-       :"=r" (word)
-@@ -351,7 +351,7 @@
-    return word;
- }
-
--static inline unsigned long ROR64(unsigned long word, int i)
-+static inline unsigned long long ROR64(unsigned long long word, int i)
- {
-    asm("rorq %%cl,%0"
-       :"=r" (word)
-@@ -361,7 +361,7 @@
-
- #ifndef LTC_NO_ROLC
-
--static inline unsigned long ROL64c(unsigned long word, const int i)
-+static inline unsigned long long ROL64c(unsigned long long word, const int i)
- {
-    asm("rolq %2,%0"
-       :"=r" (word)
-@@ -369,7 +369,7 @@
-    return word;
- }
-
--static inline unsigned long ROR64c(unsigned long word, const int i)
-+static inline unsigned long long ROR64c(unsigned long long word, const int i)
- {
-    asm("rorq %2,%0"
-       :"=r" (word)
-
diff --git a/poky/meta/recipes-core/dropbear/dropbear/CVE-2018-15599.patch b/poky/meta/recipes-core/dropbear/dropbear/CVE-2018-15599.patch
new file mode 100644
index 0000000..912545c
--- /dev/null
+++ b/poky/meta/recipes-core/dropbear/dropbear/CVE-2018-15599.patch
@@ -0,0 +1,236 @@
+From 256e2abb8150f9fea33cd026597dbe70f0379296 Mon Sep 17 00:00:00 2001
+From: Matt Johnston <matt@ucc.asn.au>
+Date: Thu, 23 Aug 2018 23:43:12 +0800
+Subject: [PATCH] Wait to fail invalid usernames
+
+Wait to fail invalid usernames
+
+Upstream-Status: Backport [https://secure.ucc.asn.au/hg/dropbear/rev/5d2d1021ca00]
+CVE: CVE-2018-15599
+Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
+---
+ auth.h           |  6 +++---
+ svr-auth.c       | 19 +++++--------------
+ svr-authpam.c    | 26 ++++++++++++++++++++++----
+ svr-authpasswd.c | 27 ++++++++++++++-------------
+ svr-authpubkey.c | 11 ++++++++++-
+ 5 files changed, 54 insertions(+), 35 deletions(-)
+
+diff --git a/auth.h b/auth.h
+index da498f5..98f5468 100644
+--- a/auth.h
++++ b/auth.h
+@@ -37,9 +37,9 @@ void recv_msg_userauth_request(void);
+ void send_msg_userauth_failure(int partial, int incrfail);
+ void send_msg_userauth_success(void);
+ void send_msg_userauth_banner(const buffer *msg);
+-void svr_auth_password(void);
+-void svr_auth_pubkey(void);
+-void svr_auth_pam(void);
++void svr_auth_password(int valid_user);
++void svr_auth_pubkey(int valid_user);
++void svr_auth_pam(int valid_user);
+ 
+ #if DROPBEAR_SVR_PUBKEY_OPTIONS_BUILT
+ int svr_pubkey_allows_agentfwd(void);
+diff --git a/svr-auth.c b/svr-auth.c
+index 64d97aa..1f364ca 100644
+--- a/svr-auth.c
++++ b/svr-auth.c
+@@ -149,10 +149,8 @@ void recv_msg_userauth_request() {
+ 		if (methodlen == AUTH_METHOD_PASSWORD_LEN &&
+ 				strncmp(methodname, AUTH_METHOD_PASSWORD,
+ 					AUTH_METHOD_PASSWORD_LEN) == 0) {
+-			if (valid_user) {
+-				svr_auth_password();
+-				goto out;
+-			}
++			svr_auth_password(valid_user);
++			goto out;
+ 		}
+ 	}
+ #endif
+@@ -164,10 +162,8 @@ void recv_msg_userauth_request() {
+ 		if (methodlen == AUTH_METHOD_PASSWORD_LEN &&
+ 				strncmp(methodname, AUTH_METHOD_PASSWORD,
+ 					AUTH_METHOD_PASSWORD_LEN) == 0) {
+-			if (valid_user) {
+-				svr_auth_pam();
+-				goto out;
+-			}
++			svr_auth_pam(valid_user);
++			goto out;
+ 		}
+ 	}
+ #endif
+@@ -177,12 +173,7 @@ void recv_msg_userauth_request() {
+ 	if (methodlen == AUTH_METHOD_PUBKEY_LEN &&
+ 			strncmp(methodname, AUTH_METHOD_PUBKEY,
+ 				AUTH_METHOD_PUBKEY_LEN) == 0) {
+-		if (valid_user) {
+-			svr_auth_pubkey();
+-		} else {
+-			/* pubkey has no failure delay */
+-			send_msg_userauth_failure(0, 0);
+-		}
++		svr_auth_pubkey(valid_user);
+ 		goto out;
+ 	}
+ #endif
+diff --git a/svr-authpam.c b/svr-authpam.c
+index 05e4f3e..d201bc9 100644
+--- a/svr-authpam.c
++++ b/svr-authpam.c
+@@ -178,13 +178,14 @@ pamConvFunc(int num_msg,
+  * Keyboard interactive would be a lot nicer, but since PAM is synchronous, it
+  * gets very messy trying to send the interactive challenges, and read the
+  * interactive responses, over the network. */
+-void svr_auth_pam() {
++void svr_auth_pam(int valid_user) {
+ 
+ 	struct UserDataS userData = {NULL, NULL};
+ 	struct pam_conv pamConv = {
+ 		pamConvFunc,
+ 		&userData /* submitted to pamvConvFunc as appdata_ptr */ 
+ 	};
++	const char* printable_user = NULL;
+ 
+ 	pam_handle_t* pamHandlep = NULL;
+ 
+@@ -204,12 +205,23 @@ void svr_auth_pam() {
+ 
+ 	password = buf_getstring(ses.payload, &passwordlen);
+ 
++	/* We run the PAM conversation regardless of whether the username is valid
++	in case the conversation function has an inherent delay.
++	Use ses.authstate.username rather than ses.authstate.pw_name.
++	After PAM succeeds we then check the valid_user flag too */
++
+ 	/* used to pass data to the PAM conversation function - don't bother with
+ 	 * strdup() etc since these are touched only by our own conversation
+ 	 * function (above) which takes care of it */
+-	userData.user = ses.authstate.pw_name;
++	userData.user = ses.authstate.username;
+ 	userData.passwd = password;
+ 
++	if (ses.authstate.pw_name) {
++		printable_user = ses.authstate.pw_name;
++	} else {
++		printable_user = "<invalid username>";
++	}
++
+ 	/* Init pam */
+ 	if ((rc = pam_start("sshd", NULL, &pamConv, &pamHandlep)) != PAM_SUCCESS) {
+ 		dropbear_log(LOG_WARNING, "pam_start() failed, rc=%d, %s", 
+@@ -242,7 +254,7 @@ void svr_auth_pam() {
+ 				rc, pam_strerror(pamHandlep, rc));
+ 		dropbear_log(LOG_WARNING,
+ 				"Bad PAM password attempt for '%s' from %s",
+-				ses.authstate.pw_name,
++				printable_user,
+ 				svr_ses.addrstring);
+ 		send_msg_userauth_failure(0, 1);
+ 		goto cleanup;
+@@ -253,12 +265,18 @@ void svr_auth_pam() {
+ 				rc, pam_strerror(pamHandlep, rc));
+ 		dropbear_log(LOG_WARNING,
+ 				"Bad PAM password attempt for '%s' from %s",
+-				ses.authstate.pw_name,
++				printable_user,
+ 				svr_ses.addrstring);
+ 		send_msg_userauth_failure(0, 1);
+ 		goto cleanup;
+ 	}
+ 
++	if (!valid_user) {
++		/* PAM auth succeeded but the username isn't allowed in for another reason
++		(checkusername() failed) */
++		send_msg_userauth_failure(0, 1);
++	}
++
+ 	/* successful authentication */
+ 	dropbear_log(LOG_NOTICE, "PAM password auth succeeded for '%s' from %s",
+ 			ses.authstate.pw_name,
+diff --git a/svr-authpasswd.c b/svr-authpasswd.c
+index bdee2aa..69c7d8a 100644
+--- a/svr-authpasswd.c
++++ b/svr-authpasswd.c
+@@ -48,22 +48,14 @@ static int constant_time_strcmp(const char* a, const char* b) {
+ 
+ /* Process a password auth request, sending success or failure messages as
+  * appropriate */
+-void svr_auth_password() {
++void svr_auth_password(int valid_user) {
+ 	
+ 	char * passwdcrypt = NULL; /* the crypt from /etc/passwd or /etc/shadow */
+ 	char * testcrypt = NULL; /* crypt generated from the user's password sent */
+-	char * password;
++	char * password = NULL;
+ 	unsigned int passwordlen;
+-
+ 	unsigned int changepw;
+ 
+-	passwdcrypt = ses.authstate.pw_passwd;
+-
+-#ifdef DEBUG_HACKCRYPT
+-	/* debugging crypt for non-root testing with shadows */
+-	passwdcrypt = DEBUG_HACKCRYPT;
+-#endif
+-
+ 	/* check if client wants to change password */
+ 	changepw = buf_getbool(ses.payload);
+ 	if (changepw) {
+@@ -73,12 +65,21 @@ void svr_auth_password() {
+ 	}
+ 
+ 	password = buf_getstring(ses.payload, &passwordlen);
+-
+-	/* the first bytes of passwdcrypt are the salt */
+-	testcrypt = crypt(password, passwdcrypt);
++	if (valid_user) {
++		/* the first bytes of passwdcrypt are the salt */
++		passwdcrypt = ses.authstate.pw_passwd;
++		testcrypt = crypt(password, passwdcrypt);
++	}
+ 	m_burn(password, passwordlen);
+ 	m_free(password);
+ 
++	/* After we have got the payload contents we can exit if the username
++	is invalid. Invalid users have already been logged. */
++	if (!valid_user) {
++		send_msg_userauth_failure(0, 1);
++		return;
++	}
++
+ 	if (testcrypt == NULL) {
+ 		/* crypt() with an invalid salt like "!!" */
+ 		dropbear_log(LOG_WARNING, "User account '%s' is locked",
+diff --git a/svr-authpubkey.c b/svr-authpubkey.c
+index aa6087c..ff481c8 100644
+--- a/svr-authpubkey.c
++++ b/svr-authpubkey.c
+@@ -79,7 +79,7 @@ static int checkfileperm(char * filename);
+ 
+ /* process a pubkey auth request, sending success or failure message as
+  * appropriate */
+-void svr_auth_pubkey() {
++void svr_auth_pubkey(int valid_user) {
+ 
+ 	unsigned char testkey; /* whether we're just checking if a key is usable */
+ 	char* algo = NULL; /* pubkey algo */
+@@ -102,6 +102,15 @@ void svr_auth_pubkey() {
+ 	keybloblen = buf_getint(ses.payload);
+ 	keyblob = buf_getptr(ses.payload, keybloblen);
+ 
++	if (!valid_user) {
++		/* Return failure once we have read the contents of the packet
++		required to validate a public key. 
++		Avoids blind user enumeration though it isn't possible to prevent
++		testing for user existence if the public key is known */
++		send_msg_userauth_failure(0, 0);
++		goto out;
++	}
++
+ 	/* check if the key is valid */
+ 	if (checkpubkey(algo, algolen, keyblob, keybloblen) == DROPBEAR_FAILURE) {
+ 		send_msg_userauth_failure(0, 0);
diff --git a/poky/meta/recipes-core/dropbear/dropbear/dropbear.default b/poky/meta/recipes-core/dropbear/dropbear/dropbear.default
new file mode 100644
index 0000000..522453a
--- /dev/null
+++ b/poky/meta/recipes-core/dropbear/dropbear/dropbear.default
@@ -0,0 +1,2 @@
+# Disallow root logins by default
+DROPBEAR_EXTRA_ARGS="-w"
diff --git a/poky/meta/recipes-core/dropbear/dropbear/fix-libtomcrypt-libtommath-ordering.patch b/poky/meta/recipes-core/dropbear/dropbear/fix-libtomcrypt-libtommath-ordering.patch
deleted file mode 100644
index 2b05e18..0000000
--- a/poky/meta/recipes-core/dropbear/dropbear/fix-libtomcrypt-libtommath-ordering.patch
+++ /dev/null
@@ -1,49 +0,0 @@
-From f37fa9a41f248fa41dd74a41c66cb41a291c03d2 Mon Sep 17 00:00:00 2001
-From: Andre McCurdy <armccurdy@gmail.com>
-Date: Fri, 16 Sep 2016 12:18:23 -0700
-Subject: [PATCH] fix libtomcrypt/libtommath ordering
-
-To prevent build failures when using system libtom libraries and
-linking with --as-needed, LIBTOM_LIBS should be in the order
--ltomcrypt -ltommath, not the other way around, ie libs should be
-prepended to LIBTOM_LIBS as they are found, not appended.
-
-Note that LIBTOM_LIBS is not used when linking with the bundled
-libtom libs.
-
-Upstream-Status: Backport [ https://github.com/mkj/dropbear/commit/f9e6bc2aecab0f4b5b529e07a92cc63c8a66cd4b ]
-
-Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
-Signed-off-by: Dengke Du <dengke.du@windriver.com>
----
- configure.ac | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index 245408d..d624853 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -393,16 +393,16 @@ AC_ARG_ENABLE(bundled-libtom,
- 			AC_MSG_NOTICE(Forcing bundled libtom*)
- 		else
- 			BUNDLED_LIBTOM=0
--			AC_CHECK_LIB(tommath, mp_exptmod, LIBTOM_LIBS="$LIBTOM_LIBS -ltommath", 
-+			AC_CHECK_LIB(tommath, mp_exptmod, LIBTOM_LIBS="-ltommath $LIBTOM_LIBS",
- 				[AC_MSG_ERROR([Missing system libtommath and --disable-bundled-libtom was specified])] )
--			AC_CHECK_LIB(tomcrypt, register_cipher, LIBTOM_LIBS="$LIBTOM_LIBS -ltomcrypt", 
-+			AC_CHECK_LIB(tomcrypt, register_cipher, LIBTOM_LIBS="-ltomcrypt $LIBTOM_LIBS",
- 				[AC_MSG_ERROR([Missing system libtomcrypt and --disable-bundled-libtom was specified])] )
- 		fi
- 	],
- 	[
- 		BUNDLED_LIBTOM=0
--		AC_CHECK_LIB(tommath, mp_exptmod, LIBTOM_LIBS="$LIBTOM_LIBS -ltommath", BUNDLED_LIBTOM=1)
--		AC_CHECK_LIB(tomcrypt, register_cipher, LIBTOM_LIBS="$LIBTOM_LIBS -ltomcrypt", BUNDLED_LIBTOM=1)
-+		AC_CHECK_LIB(tommath, mp_exptmod, LIBTOM_LIBS="-ltommath $LIBTOM_LIBS", BUNDLED_LIBTOM=1)
-+		AC_CHECK_LIB(tomcrypt, register_cipher, LIBTOM_LIBS="-ltomcrypt $LIBTOM_LIBS", BUNDLED_LIBTOM=1)
- 	]
- )
- 
--- 
-2.8.1
-
diff --git a/poky/meta/recipes-core/dropbear/dropbear_2017.75.bb b/poky/meta/recipes-core/dropbear/dropbear_2017.75.bb
deleted file mode 100644
index cfb0d19..0000000
--- a/poky/meta/recipes-core/dropbear/dropbear_2017.75.bb
+++ /dev/null
@@ -1,5 +0,0 @@
-require dropbear.inc
-
-SRC_URI[md5sum] = "e57e9b9d25705dcb073ba15c416424fd"
-SRC_URI[sha256sum] = "6cbc1dcb1c9709d226dff669e5604172a18cf5dbf9a201474d5618ae4465098c"
-
diff --git a/poky/meta/recipes-core/dropbear/dropbear_2018.76.bb b/poky/meta/recipes-core/dropbear/dropbear_2018.76.bb
new file mode 100644
index 0000000..36a58d5
--- /dev/null
+++ b/poky/meta/recipes-core/dropbear/dropbear_2018.76.bb
@@ -0,0 +1,5 @@
+require dropbear.inc
+
+SRC_URI[md5sum] = "c3912f7fcdcc57c99937e4a79480d2c2"
+SRC_URI[sha256sum] = "f2fb9167eca8cf93456a5fc1d4faf709902a3ab70dd44e352f3acbc3ffdaea65"
+
diff --git a/poky/meta/recipes-core/expat/expat_2.2.5.bb b/poky/meta/recipes-core/expat/expat_2.2.5.bb
deleted file mode 100644
index c68a2ef..0000000
--- a/poky/meta/recipes-core/expat/expat_2.2.5.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-SUMMARY = "A stream-oriented XML parser library"
-DESCRIPTION = "Expat is an XML parser library written in C. It is a stream-oriented parser in which an application registers handlers for things the parser might find in the XML document (like start tags)"
-HOMEPAGE = "http://expat.sourceforge.net/"
-SECTION = "libs"
-LICENSE = "MIT"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=5b8620d98e49772d95fc1d291c26aa79"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/expat/expat-${PV}.tar.bz2 \
-           file://autotools.patch \
-           file://libtool-tag.patch \
-	  "
-
-SRC_URI[md5sum] = "789e297f547980fc9ecc036f9a070d49"
-SRC_URI[sha256sum] = "d9dc32efba7e74f788fcc4f212a43216fc37cf5f23f4c2339664d473353aedf6"
-
-inherit autotools lib_package
-
-do_configure_prepend () {
-	rm -f ${S}/conftools/libtool.m4
-}
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-core/expat/expat_2.2.6.bb b/poky/meta/recipes-core/expat/expat_2.2.6.bb
new file mode 100644
index 0000000..c9e6081
--- /dev/null
+++ b/poky/meta/recipes-core/expat/expat_2.2.6.bb
@@ -0,0 +1,23 @@
+SUMMARY = "A stream-oriented XML parser library"
+DESCRIPTION = "Expat is an XML parser library written in C. It is a stream-oriented parser in which an application registers handlers for things the parser might find in the XML document (like start tags)"
+HOMEPAGE = "http://expat.sourceforge.net/"
+SECTION = "libs"
+LICENSE = "MIT"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=5b8620d98e49772d95fc1d291c26aa79"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/expat/expat-${PV}.tar.bz2 \
+           file://autotools.patch \
+           file://libtool-tag.patch \
+	  "
+
+SRC_URI[md5sum] = "ca047ae951b40020ac831c28859161b2"
+SRC_URI[sha256sum] = "17b43c2716d521369f82fc2dc70f359860e90fa440bea65b3b85f0b246ea81f2"
+
+inherit autotools lib_package
+
+do_configure_prepend () {
+	rm -f ${S}/conftools/libtool.m4
+}
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-core/glib-2.0/glib-2.0/0001-Do-not-ignore-return-value-of-write.patch b/poky/meta/recipes-core/glib-2.0/glib-2.0/0001-Do-not-ignore-return-value-of-write.patch
index aee96aa..0ebf138 100644
--- a/poky/meta/recipes-core/glib-2.0/glib-2.0/0001-Do-not-ignore-return-value-of-write.patch
+++ b/poky/meta/recipes-core/glib-2.0/glib-2.0/0001-Do-not-ignore-return-value-of-write.patch
@@ -1,30 +1,30 @@
-From d6501b107940e9f548c89236d773c6d33c15a5c9 Mon Sep 17 00:00:00 2001
+From d250652782b65b071b7cc8f01f2db833df104e0e Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sat, 16 Apr 2016 13:28:59 -0700
-Subject: [PATCH 1/2] Do not ignore return value of write()
+Subject: [PATCH] Do not ignore return value of write()
 
 gcc warns about ignoring return value when compiling
 with fortify turned on.
 
 assert when write() fails
 
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
 Upstream-Status: Submitted
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
+---
  glib/tests/unix.c | 5 +++--
  1 file changed, 3 insertions(+), 2 deletions(-)
 
 diff --git a/glib/tests/unix.c b/glib/tests/unix.c
-index 3543458..4e7ed85 100644
+index 9d55a6c..a07f945 100644
 --- a/glib/tests/unix.c
 +++ b/glib/tests/unix.c
 @@ -32,14 +32,15 @@ test_pipe (void)
    GError *error = NULL;
    int pipefd[2];
    char buf[1024];
--  ssize_t bytes_read;
-+  ssize_t bytes_read, bytes_written;
+-  gssize bytes_read;
++  gssize bytes_read, bytes_written;
    gboolean res;
  
    res = g_unix_open_pipe (pipefd, FD_CLOEXEC, &error);
@@ -37,6 +37,3 @@
    memset (buf, 0, sizeof (buf));
    bytes_read = read (pipefd[0], buf, sizeof(buf) - 1);
    g_assert_cmpint (bytes_read, >, 0);
--- 
-2.8.0
-
diff --git a/poky/meta/recipes-core/glib-2.0/glib-2.0/0001-Install-gio-querymodules-as-libexec_PROGRAM.patch b/poky/meta/recipes-core/glib-2.0/glib-2.0/0001-Install-gio-querymodules-as-libexec_PROGRAM.patch
index 561d100..97d0aff 100644
--- a/poky/meta/recipes-core/glib-2.0/glib-2.0/0001-Install-gio-querymodules-as-libexec_PROGRAM.patch
+++ b/poky/meta/recipes-core/glib-2.0/glib-2.0/0001-Install-gio-querymodules-as-libexec_PROGRAM.patch
@@ -1,4 +1,4 @@
-From 80682c171ccb27d01343d4cfcfb4dd49b7863ccc Mon Sep 17 00:00:00 2001
+From 856045927b9ab391165c0ebabf401835f8439eab Mon Sep 17 00:00:00 2001
 From: Jussi Kukkonen <jussi.kukkonen@intel.com>
 Date: Tue, 22 Mar 2016 15:14:58 +0200
 Subject: [PATCH] Install gio-querymodules as libexec_PROGRAM
@@ -8,24 +8,22 @@
 
 Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
 Upstream-Status: Inappropriate [OE specific]
+
 ---
  gio/Makefile.am | 3 ++-
  1 file changed, 2 insertions(+), 1 deletion(-)
 
 diff --git a/gio/Makefile.am b/gio/Makefile.am
-index b7f91cc..4d81cc0 100644
+index e14cad2..bf2bcc7 100644
 --- a/gio/Makefile.am
 +++ b/gio/Makefile.am
-@@ -702,7 +702,8 @@ gio.def: libgio-2.0.la
+@@ -835,7 +835,8 @@ gio.def: libgio-2.0.la
  gio-2.0.lib: libgio-2.0.la gio.def
  	$(AM_V_GEN) lib.exe -machine:@LIB_EXE_MACHINE_FLAG@ -name:libgio-2.0-$(LT_CURRENT_MINUS_AGE).dll -def:$(builddir)/gio.def -out:$@
  
--bin_PROGRAMS = gio-querymodules glib-compile-schemas glib-compile-resources gsettings
-+bin_PROGRAMS = glib-compile-schemas glib-compile-resources gsettings
+-bin_PROGRAMS = gio-querymodules glib-compile-schemas glib-compile-resources gsettings gio-launch-desktop
++bin_PROGRAMS = glib-compile-schemas glib-compile-resources gsettings gio-launch-desktop
 +libexec_PROGRAMS = gio-querymodules
  
  glib_compile_resources_LDADD = libgio-2.0.la 		\
  	$(top_builddir)/gobject/libgobject-2.0.la	\
--- 
-2.1.4
-
diff --git a/poky/meta/recipes-core/glib-2.0/glib-2.0/0001-Test-for-pthread_getname_np-before-using-it.patch b/poky/meta/recipes-core/glib-2.0/glib-2.0/0001-Test-for-pthread_getname_np-before-using-it.patch
deleted file mode 100644
index c6e4966..0000000
--- a/poky/meta/recipes-core/glib-2.0/glib-2.0/0001-Test-for-pthread_getname_np-before-using-it.patch
+++ /dev/null
@@ -1,70 +0,0 @@
-From f627fe16099a2b08d8b4e9023ae6b4f352451967 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 6 Nov 2016 08:59:08 -0800
-Subject: [PATCH] Test for pthread_getname_np before using it
-
-Its a GNU extention and not all libc implement it
-musl e.g. implements the setname API but not getname
-in any case, it seems to be safer to check for the
-function before using it.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Submitted
-
- config.h.in         |  3 +++
- configure.ac        | 10 ++++++++++
- glib/tests/thread.c |  2 +-
- 3 files changed, 14 insertions(+), 1 deletion(-)
-
-diff --git a/config.h.in b/config.h.in
-index 2c35ff1..da7ac30 100644
---- a/config.h.in
-+++ b/config.h.in
-@@ -326,6 +326,9 @@
- #undef HAVE_PTHREAD_COND_TIMEDWAIT_RELATIVE_NP
- 
- /* Have function pthread_setname_np(const char*) */
-+#undef HAVE_PTHREAD_GETNAME_NP
-+
-+/* Have function pthread_setname_np(const char*) */
- #undef HAVE_PTHREAD_SETNAME_NP_WITHOUT_TID
- 
- /* Have function pthread_setname_np(pthread_t, const char*) */
-diff --git a/configure.ac b/configure.ac
-index 4309671..209770a 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -2121,6 +2121,16 @@ AS_IF([ test x"$have_threads" = xposix], [
-              AC_DEFINE(HAVE_PTHREAD_COND_TIMEDWAIT_RELATIVE_NP,1,
-                 [Have function pthread_cond_timedwait_relative_np])],
-             [AC_MSG_RESULT(no)])
-+        dnl gets thread names
-+        AC_MSG_CHECKING(for pthread_getname_np(pthread_t, char*, size_t))
-+        AC_LINK_IFELSE(
-+            [AC_LANG_PROGRAM(
-+                [#include <pthread.h>],
-+                [pthread_getname_np(pthread_self(),"example",0)])],
-+            [AC_MSG_RESULT(yes)
-+             AC_DEFINE(HAVE_PTHREAD_GETNAME_NP,1,
-+                [Have function pthread_setname_np(const char*)])],
-+            [AC_MSG_RESULT(no)])
-         dnl Sets thread names on OS X 10.6, iOS 3.2 (and higher)
-         AC_MSG_CHECKING(for pthread_setname_np(const char*))
-         AC_LINK_IFELSE(
-diff --git a/glib/tests/thread.c b/glib/tests/thread.c
-index 5447836..2f248a6 100644
---- a/glib/tests/thread.c
-+++ b/glib/tests/thread.c
-@@ -174,7 +174,7 @@ test_thread5 (void)
- static gpointer
- thread6_func (gpointer data)
- {
--#ifdef HAVE_PTHREAD_SETNAME_NP_WITH_TID
-+#if defined(HAVE_PTHREAD_SETNAME_NP_WITH_TID) && defined(HAVE_PTHREAD_GETNAME_NP)
-   char name[16];
- 
-   pthread_getname_np (pthread_self(), name, 16);
--- 
-2.10.2
-
diff --git a/poky/meta/recipes-core/glib-2.0/glib-2.0/Enable-more-tests-while-cross-compiling.patch b/poky/meta/recipes-core/glib-2.0/glib-2.0/Enable-more-tests-while-cross-compiling.patch
index b98f933..50781e7 100644
--- a/poky/meta/recipes-core/glib-2.0/glib-2.0/Enable-more-tests-while-cross-compiling.patch
+++ b/poky/meta/recipes-core/glib-2.0/glib-2.0/Enable-more-tests-while-cross-compiling.patch
@@ -1,7 +1,7 @@
-From d762907d33b81cf7469b5696c87f2188d2050afb Mon Sep 17 00:00:00 2001
+From 4b1a6d247c78125096a6ea5ab3cab8a1f000dc23 Mon Sep 17 00:00:00 2001
 From: Jussi Kukkonen <jussi.kukkonen@intel.com>
 Date: Mon, 9 Nov 2015 11:07:27 +0200
-Subject: [PATCH 06/10] Enable more tests while cross-compiling
+Subject: [PATCH] Enable more tests while cross-compiling
 
 Upstream disables a few tests while cross-compiling because their build requires
 running other built binaries. This usually makes sense but in the cross-compile
@@ -16,10 +16,10 @@
  2 files changed, 11 insertions(+), 7 deletions(-)
 
 diff --git a/gio/tests/Makefile.am b/gio/tests/Makefile.am
-index acc1da4..9176640 100644
+index 1f0bed7..8295deb 100644
 --- a/gio/tests/Makefile.am
 +++ b/gio/tests/Makefile.am
-@@ -516,10 +516,9 @@ test_programs += \
+@@ -550,10 +550,9 @@ test_programs += \
  endif
  
  # -----------------------------------------------------------------------------
@@ -32,7 +32,7 @@
  test_programs += resources
  resources_SOURCES = resources.c
  nodist_resources_SOURCES = test_resources.c test_resources2.c test_resources2.h
-@@ -543,7 +542,11 @@ if !ENABLE_INSTALLED_TESTS
+@@ -578,7 +577,11 @@ if !ENABLE_INSTALLED_TESTS
  libresourceplugin_la_LDFLAGS += -rpath /
  endif
  
@@ -44,7 +44,7 @@
  
  test-generated.txt: test1.txt
  	$(AM_V_GEN) echo "Generated" > $@ && \
-@@ -564,7 +567,6 @@ test.gresource: test.gresource.xml Makefile $(shell $(glib_compile_resources) --
+@@ -599,7 +602,6 @@ test.gresource: test.gresource.xml Makefile $(shell $(glib_compile_resources) --
  
  EXTRA_DIST += test.gresource.xml test1.txt test2.gresource.xml test2.txt test3.gresource.xml test3.txt test4.gresource.xml
  CLEANFILES += test-generated.txt test_resources.c test_resources2.[ch] plugin_resources.c test.gresource
@@ -53,10 +53,10 @@
  BUILT_SOURCES += giotypefuncs.inc
  
 diff --git a/tests/gobject/Makefile.am b/tests/gobject/Makefile.am
-index 656941d..68555ff 100644
+index 0e60987..927d13a 100644
 --- a/tests/gobject/Makefile.am
 +++ b/tests/gobject/Makefile.am
-@@ -48,10 +48,13 @@ if ENABLE_TIMELOOP
+@@ -51,10 +51,13 @@ if ENABLE_TIMELOOP
  installed_test_programs += timeloop-closure
  endif
  
@@ -72,14 +72,9 @@
  
  testmarshal.h: stamp-testmarshal.h
  	@true
-@@ -69,7 +72,6 @@ BUILT_SOURCES += testmarshal.h testmarshal.c
- CLEANFILES += stamp-testmarshal.h
+@@ -71,4 +74,3 @@ testmarshal.c: testmarshal.h testmarshal.list $(glib_genmarshal)
+ BUILT_SOURCES += testmarshal.h testmarshal.c
+ CLEANFILES += stamp-testmarshal.h testmarshal.h testmarshal.c
  EXTRA_DIST += testcommon.h testmarshal.list
- BUILT_EXTRA_DIST += testmarshal.h testmarshal.c
 -endif # !CROSS_COMPILING
- 
- dist-hook: $(BUILT_EXTRA_DIST)
- 	files='$(BUILT_EXTRA_DIST)';				\
--- 
-2.14.1
-
+\ No newline at end of file
diff --git a/poky/meta/recipes-core/glib-2.0/glib-2.0/allow-run-media-sdX-drive-mount-if-username-root.patch b/poky/meta/recipes-core/glib-2.0/glib-2.0/allow-run-media-sdX-drive-mount-if-username-root.patch
deleted file mode 100644
index 3d0c008..0000000
--- a/poky/meta/recipes-core/glib-2.0/glib-2.0/allow-run-media-sdX-drive-mount-if-username-root.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From c53e94a520b573aa0dcf12903e9563fe8badc34c Mon Sep 17 00:00:00 2001
-From: Marius Avram <marius.avram@intel.com>
-Date: Wed, 27 Aug 2014 12:10:41 +0300
-Subject: [PATCH] Allow /run/media/sdX drive mount if username root
-
-In case that the username logged in the system is root
-the drives are directly mounted in /run/media/sdX and
-not /run/media/<username>/sdX as the function
-g_unix_mount_guess_should_display() expects.
-
-Without this change USB stick mounts are not accesible from
-graphical applications such as the File Manager (pcmanfm).
-
-Upstream-Status: Inappropriate
-
-Signed-off-by: Marius Avram <marius.avram@intel.com>
----
- gio/gunixmounts.c |    5 +++++
- 1 file changed, 5 insertions(+)
-
-diff --git a/gio/gunixmounts.c b/gio/gunixmounts.c
-index 4999354..f6c1472 100644
---- a/gio/gunixmounts.c
-+++ b/gio/gunixmounts.c
-@@ -2136,6 +2136,11 @@ g_unix_mount_guess_should_display (GUnixMountEntry *mount_entry)
-           mount_path[sizeof ("/run/media/") - 1 + user_name_len] == '/')
-         is_in_runtime_dir = TRUE;
- 
-+      /* Allow no username in path in /run/media if current user is root */
-+      if (strcmp(user_name, "root") == 0 &&
-+          strncmp (mount_path, "/run/media/", sizeof("run/media")) == 0)
-+        is_in_runtime_dir = TRUE;
-+
-       if (is_in_runtime_dir || g_str_has_prefix (mount_path, "/media/"))
-         {
-           char *path;
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-core/glib-2.0/glib-2.0/date-lt.patch b/poky/meta/recipes-core/glib-2.0/glib-2.0/date-lt.patch
new file mode 100644
index 0000000..dd0aff7
--- /dev/null
+++ b/poky/meta/recipes-core/glib-2.0/glib-2.0/date-lt.patch
@@ -0,0 +1,20 @@
+Update Lithuanian month names in the test suite as glibc changed the translations.
+
+Upstream-Status: Submitted [https://gitlab.gnome.org/GNOME/glib/merge_requests/373]
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+diff --git a/glib/tests/date.c b/glib/tests/date.c
+index b801ca704..6646c227c 100644
+--- a/glib/tests/date.c
++++ b/glib/tests/date.c
+@@ -365,8 +365,8 @@ test_month_names (void)
+       TEST_DATE ( 1,  4, 2018,      "%Y m. %OB",      "2018 m. balandis");
+       TEST_DATE ( 1,  5, 2018,      "%Y m. %OB",        "2018 m. gegužė");
+       TEST_DATE ( 1,  6, 2018,      "%Y m. %OB",      "2018 m. birželis");
+-      TEST_DATE (17,  7, 2018, "%Y m. %b %e d.",     "2018 m. Lie 17 d.");
+-      TEST_DATE ( 1,  8, 2018,      "%Y m. %Ob",           "2018 m. Rgp");
++      TEST_DATE (17,  7, 2018, "%Y m. %b %e d.",   "2018 m. Liep. 17 d.");
++      TEST_DATE ( 1,  8, 2018,      "%Y m. %Ob",         "2018 m. rugp.");
+     }
+   else
+     g_test_skip ("locale lt_LT not available, skipping Lithuanian month names test");
diff --git a/poky/meta/recipes-core/glib-2.0/glib-2.0/ptest-paths.patch b/poky/meta/recipes-core/glib-2.0/glib-2.0/ptest-paths.patch
deleted file mode 100644
index f3be027..0000000
--- a/poky/meta/recipes-core/glib-2.0/glib-2.0/ptest-paths.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-Instead of writing the temporary mapping files in the mappedfile test to the
-user runtime directory, write them to $TMP.  The runtime directory may not
-currently exist if the test is executed on a non-desktop system and the test
-doesn't attempt to create the directory structure.
-
-Upstream-Status: Pending
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
-diff --git a/glib/tests/mappedfile.c b/glib/tests/mappedfile.c
-index 40e0e60..27a24be 100644
---- a/glib/tests/mappedfile.c
-+++ b/glib/tests/mappedfile.c
-@@ -81,7 +81,7 @@ test_writable (void)
-   const gchar *new = "abcdefghijklmnopqrstuvxyz";
-   gchar *tmp_copy_path;
- 
--  tmp_copy_path = g_build_filename (g_get_user_runtime_dir (), "glib-test-4096-random-bytes", NULL);
-+  tmp_copy_path = g_build_filename (g_get_tmp_dir (), "glib-test-4096-random-bytes", NULL);
- 
-   g_file_get_contents (g_test_get_filename (G_TEST_DIST, "4096-random-bytes", NULL), &contents, &len, &error);
-   g_assert_no_error (error);
-@@ -125,7 +125,7 @@ test_writable_fd (void)
-   int fd;
-   gchar *tmp_copy_path;
- 
--  tmp_copy_path = g_build_filename (g_get_user_runtime_dir (), "glib-test-4096-random-bytes", NULL);
-+  tmp_copy_path = g_build_filename (g_get_tmp_dir (), "glib-test-4096-random-bytes", NULL);
- 
-   g_file_get_contents (g_test_get_filename (G_TEST_DIST, "4096-random-bytes", NULL), &contents, &len, &error);
-   g_assert_no_error (error);
diff --git a/poky/meta/recipes-core/glib-2.0/glib-2.0/relocate-modules.patch b/poky/meta/recipes-core/glib-2.0/glib-2.0/relocate-modules.patch
index 65d5b43..f9794d3 100644
--- a/poky/meta/recipes-core/glib-2.0/glib-2.0/relocate-modules.patch
+++ b/poky/meta/recipes-core/glib-2.0/glib-2.0/relocate-modules.patch
@@ -1,3 +1,8 @@
+From 8326961841f4d16c7239e747de11e3817c35cfd2 Mon Sep 17 00:00:00 2001
+From: Ross Burton <ross.burton@intel.com>
+Date: Fri, 11 Mar 2016 15:35:55 +0000
+Subject: [PATCH] glib-2.0: relocate the GIO module directory for native builds
+
 Instead of hard-coding GIO_MODULE_PATH when glib is built, use dladdr() to
 determine where libglib.so is and use that path to calculate GIO_MODULES_DIR.
 
@@ -8,12 +13,13 @@
 
 Port patch to 2.48
 Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
+
 ---
  gio/giomodule.c | 12 +++++++++++-
  1 file changed, 11 insertions(+), 1 deletion(-)
 
 diff --git a/gio/giomodule.c b/gio/giomodule.c
-index da7c167..cc0bc7c 100644
+index 36c0cef..912e490 100644
 --- a/gio/giomodule.c
 +++ b/gio/giomodule.c
 @@ -40,6 +40,8 @@
@@ -25,7 +31,7 @@
  #endif
  #include <glib/gstdio.h>
  
-@@ -1036,7 +1038,15 @@ get_gio_module_dir (void)
+@@ -1099,7 +1101,15 @@ get_gio_module_dir (void)
  #endif
        g_free (install_dir);
  #else
@@ -42,6 +48,3 @@
  #endif
      }
  
--- 
-2.1.4
-
diff --git a/poky/meta/recipes-core/glib-2.0/glib-2.0_2.54.3.bb b/poky/meta/recipes-core/glib-2.0/glib-2.0_2.54.3.bb
deleted file mode 100644
index faf5945..0000000
--- a/poky/meta/recipes-core/glib-2.0/glib-2.0_2.54.3.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-require glib.inc
-
-PE = "1"
-
-SHRT_VER = "${@oe.utils.trim_version("${PV}", 2)}"
-
-SRC_URI = "${GNOME_MIRROR}/glib/${SHRT_VER}/glib-${PV}.tar.xz \
-           file://configure-libtool.patch \
-           file://run-ptest \
-           file://ptest-paths.patch \
-           file://uclibc_musl_translation.patch \
-           file://allow-run-media-sdX-drive-mount-if-username-root.patch \
-           file://0001-Remove-the-warning-about-deprecated-paths-in-schemas.patch \
-           file://Enable-more-tests-while-cross-compiling.patch \
-           file://0001-Install-gio-querymodules-as-libexec_PROGRAM.patch \
-           file://0001-Do-not-ignore-return-value-of-write.patch \
-           file://0001-Test-for-pthread_getname_np-before-using-it.patch \
-           file://0010-Do-not-hardcode-python-path-into-various-tools.patch \
-           "
-
-SRC_URI_append_class-native = " file://relocate-modules.patch"
-
-SRC_URI[md5sum] = "16e886ad677bf07b7d48eb8188bcf759"
-SRC_URI[sha256sum] = "963fdc6685dc3da8e5381dfb9f15ca4b5709b28be84d9d05a9bb8e446abac0a8"
diff --git a/poky/meta/recipes-core/glib-2.0/glib-2.0_2.58.0.bb b/poky/meta/recipes-core/glib-2.0/glib-2.0_2.58.0.bb
new file mode 100644
index 0000000..1271a7c
--- /dev/null
+++ b/poky/meta/recipes-core/glib-2.0/glib-2.0_2.58.0.bb
@@ -0,0 +1,22 @@
+require glib.inc
+
+PE = "1"
+
+SHRT_VER = "${@oe.utils.trim_version("${PV}", 2)}"
+
+SRC_URI = "${GNOME_MIRROR}/glib/${SHRT_VER}/glib-${PV}.tar.xz \
+           file://configure-libtool.patch \
+           file://run-ptest \
+           file://uclibc_musl_translation.patch \
+           file://0001-Remove-the-warning-about-deprecated-paths-in-schemas.patch \
+           file://Enable-more-tests-while-cross-compiling.patch \
+           file://0001-Install-gio-querymodules-as-libexec_PROGRAM.patch \
+           file://0001-Do-not-ignore-return-value-of-write.patch \
+           file://0010-Do-not-hardcode-python-path-into-various-tools.patch \
+           file://date-lt.patch \
+           "
+
+SRC_URI_append_class-native = " file://relocate-modules.patch"
+
+SRC_URI[md5sum] = "9b5d21c802f55bf37171c4fbfe7d32d1"
+SRC_URI[sha256sum] = "c0f4ce0730b4f95c47b711613b5406a887c2ee13ea6d25930d72a4fa7fdb77f6"
diff --git a/poky/meta/recipes-core/glib-2.0/glib.inc b/poky/meta/recipes-core/glib-2.0/glib.inc
index f645ed6..e8215da 100644
--- a/poky/meta/recipes-core/glib-2.0/glib.inc
+++ b/poky/meta/recipes-core/glib-2.0/glib.inc
@@ -9,8 +9,7 @@
                     file://glib/glib.h;beginline=4;endline=17;md5=b88abb7f3ad09607e71cb9d530155906 \
                     file://gmodule/COPYING;md5=4fbd65380cdd255951079008b364516c \
                     file://gmodule/gmodule.h;beginline=4;endline=17;md5=b88abb7f3ad09607e71cb9d530155906 \
-                    file://glib/pcre/COPYING;md5=266ebc3ff74ee9ce6fad65577667c0f4 \
-                    file://glib/pcre/pcre.h;beginline=11;endline=35;md5=de27f2bf633d20a2b7af0b1983423283 \
+                    file://glib/pcre/pcre.h;beginline=8;endline=36;md5=3e2977dae4ad05217f58c446237298fc \
                     file://docs/reference/COPYING;md5=f51a5100c17af6bae00735cd791e1fcc"
 BUGTRACKER = "http://bugzilla.gnome.org"
 SECTION = "libs"
@@ -39,8 +38,9 @@
 PACKAGECONFIG[system-pcre] = "--with-pcre=system,--with-pcre=internal,libpcre"
 PACKAGECONFIG[libmount] = "--enable-libmount,--disable-libmount,util-linux"
 PACKAGECONFIG[manpages] = "--enable-man --with-xml-catalog=${STAGING_ETCDIR_NATIVE}/xml/catalog.xml, --disable-man, libxslt-native xmlto-native"
+PACKAGECONFIG[libelf] = "--enable-libelf,--disable-libelf,elfutils"
 
-CORECONF = "--disable-dtrace --disable-fam --disable-libelf --disable-systemtap"
+CORECONF = "--disable-dtrace --disable-fam --disable-systemtap"
 
 PRINTF = "--enable-included-printf=no"
 PRINTF_darwin = "--enable-included-printf=yes"
@@ -86,10 +86,10 @@
 CPPFLAGS_append_class-target_mips16e = " -DNVALGRIND=1"
 
 # GLib generally requires gettext to be present so for USE_NLS to yes.  For
-# native builds as i18n is disabled globally we can tell it to use a fake msgfmt.
+# native builds as i18n is disabled globally we have to add a gettext-native dependency.
 USE_NLS_class-target = "yes"
 USE_NLS_class-nativesdk = "yes"
-CACHED_CONFIGUREVARS_append_class-native = " ac_cv_path_MSGFMT=/bin/false"
+DEPENDS_append_class-native = " gettext-native"
 
 EXEEXT = ""
 EXEEXT_mingw32 = ".exe"
@@ -116,7 +116,7 @@
 
 do_install_append_class-target () {
 	# Tests are only installed on targets, not native builds.  Separating this out
-	# keeps glib-2.0-native from depending on ${DISTRO_FEATURES}
+	# keeps glib-2.0-native from depending on DISTRO_FEATURES
 	if [ -f ${D}${datadir}/installed-tests/glib/gdbus-serialization.test ]; then
 		if ${@bb.utils.contains("DISTRO_FEATURES", "x11", "false", "true", d)}; then
 			rm ${D}${datadir}/installed-tests/glib/gdbus-serialization.test
@@ -140,6 +140,8 @@
             shared-mime-info \
            "
 
+# When https://gitlab.gnome.org/GNOME/glib/issues/1343 is
+# fixed add locale-base-pl-pl
 RDEPENDS_${PN}-ptest_append_libc-glibc = "\
             glibc-gconv-utf-16 \
             glibc-charmap-utf-8 \
@@ -152,6 +154,17 @@
             glibc-gconv-iso8859-15 \
             glibc-charmap-invariant \
             glibc-localedata-translit-cjk-variants \
+            locale-base-tr-tr \
+            locale-base-lt-lt \
+            locale-base-ja-jp.euc-jp \
+            locale-base-fa-ir \
+            locale-base-ru-ru \
+            locale-base-de-de \
+            locale-base-hr-hr \
+            locale-base-el-gr \
+            locale-base-fr-fr \
+            locale-base-es-es \
+            locale-base-en-gb \
            "
 
 INSANE_SKIP_${PN}-ptest += "libdir"
diff --git a/poky/meta/recipes-core/glibc/cross-localedef-native_2.27.bb b/poky/meta/recipes-core/glibc/cross-localedef-native_2.27.bb
deleted file mode 100644
index 5e92eb7..0000000
--- a/poky/meta/recipes-core/glibc/cross-localedef-native_2.27.bb
+++ /dev/null
@@ -1,52 +0,0 @@
-SUMMARY = "Cross locale generation tool for glibc"
-HOMEPAGE = "http://www.gnu.org/software/libc/libc.html"
-SECTION = "libs"
-LICENSE = "LGPL-2.1"
-
-LIC_FILES_CHKSUM = "file://LICENSES;md5=e9a558e243b36d3209f380deb394b213 \
-      file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-      file://posix/rxspencer/COPYRIGHT;md5=dc5485bb394a13b2332ec1c785f5d83a \
-      file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c"
-
-# Tell autotools that we're working in the localedef directory
-#
-AUTOTOOLS_SCRIPT_PATH = "${S}/localedef"
-
-inherit native
-inherit autotools
-
-FILESEXTRAPATHS =. "${FILE_DIRNAME}/${PN}:${FILE_DIRNAME}/glibc:"
-
-SRCBRANCH ?= "release/${PV}/master"
-GLIBC_GIT_URI ?= "git://sourceware.org/git/glibc.git"
-UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+\.\d+(\.(?!90)\d+)*)"
-
-SRCREV_glibc ?= "df3ff4e49d4ee3cbbdaeb0b1cb5dc2344c08be98"
-SRCREV_localedef ?= "de5bdbd5e76b5403a4151b9b9f958b6cca36b3e7"
-
-SRC_URI = "${GLIBC_GIT_URI};branch=${SRCBRANCH};name=glibc \
-           git://github.com/kraj/localedef;branch=master;name=localedef;destsuffix=git/localedef \
-           file://0015-timezone-re-written-tzselect-as-posix-sh.patch \
-           file://0016-Remove-bash-dependency-for-nscd-init-script.patch \
-           file://0017-eglibc-Cross-building-and-testing-instructions.patch \
-           file://0018-eglibc-Help-bootstrap-cross-toolchain.patch \
-           file://0019-eglibc-Clear-cache-lines-on-ppc8xx.patch \
-           file://0020-eglibc-Resolve-__fpscr_values-on-SH4.patch \
-           file://0021-eglibc-Install-PIC-archives.patch \
-           file://0022-eglibc-Forward-port-cross-locale-generation-support.patch \
-           file://0023-Define-DUMMY_LOCALE_T-if-not-defined.patch \
-           file://archive-path.patch \
-"
-# Makes for a rather long rev (22 characters), but...
-#
-SRCREV_FORMAT = "glibc_localedef"
-
-S = "${WORKDIR}/git"
-
-EXTRA_OECONF = "--with-glibc=${S}"
-CFLAGS += "-fgnu89-inline -std=gnu99 -DIS_IN\(x\)='0'"
-
-do_install() {
-	install -d ${D}${bindir}
-	install -m 0755 ${B}/localedef ${D}${bindir}/cross-localedef
-}
diff --git a/poky/meta/recipes-core/glibc/cross-localedef-native_2.28.bb b/poky/meta/recipes-core/glibc/cross-localedef-native_2.28.bb
new file mode 100644
index 0000000..a05b94e
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/cross-localedef-native_2.28.bb
@@ -0,0 +1,51 @@
+SUMMARY = "Cross locale generation tool for glibc"
+HOMEPAGE = "http://www.gnu.org/software/libc/libc.html"
+SECTION = "libs"
+LICENSE = "LGPL-2.1"
+
+LIC_FILES_CHKSUM = "file://LICENSES;md5=cfc0ed77a9f62fa62eded042ebe31d72 \
+      file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+      file://posix/rxspencer/COPYRIGHT;md5=dc5485bb394a13b2332ec1c785f5d83a \
+      file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c"
+
+# Tell autotools that we're working in the localedef directory
+#
+AUTOTOOLS_SCRIPT_PATH = "${S}/localedef"
+
+inherit native
+inherit autotools
+
+FILESEXTRAPATHS =. "${FILE_DIRNAME}/${PN}:${FILE_DIRNAME}/glibc:"
+
+SRCBRANCH ?= "release/${PV}/master"
+GLIBC_GIT_URI ?= "git://sourceware.org/git/glibc.git"
+UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+\.\d+(\.(?!90)\d+)*)"
+
+SRCREV_glibc ?= "3c03baca37fdcb52c3881e653ca392bba7a99c2b"
+SRCREV_localedef ?= "c328777219ccc480be3112cf807217ca6b570b64"
+
+SRC_URI = "${GLIBC_GIT_URI};branch=${SRCBRANCH};name=glibc \
+           git://github.com/kraj/localedef;branch=master;name=localedef;destsuffix=git/localedef \
+           file://0016-timezone-re-written-tzselect-as-posix-sh.patch \
+           file://0017-Remove-bash-dependency-for-nscd-init-script.patch \
+           file://0018-eglibc-Cross-building-and-testing-instructions.patch \
+           file://0019-eglibc-Help-bootstrap-cross-toolchain.patch \
+           file://0020-eglibc-Clear-cache-lines-on-ppc8xx.patch \
+           file://0021-eglibc-Resolve-__fpscr_values-on-SH4.patch \
+           file://0022-eglibc-Forward-port-cross-locale-generation-support.patch \
+           file://0023-Define-DUMMY_LOCALE_T-if-not-defined.patch \
+           file://0029-localedef-add-to-archive-uses-a-hard-coded-locale-pa.patch \
+"
+# Makes for a rather long rev (22 characters), but...
+#
+SRCREV_FORMAT = "glibc_localedef"
+
+S = "${WORKDIR}/git"
+
+EXTRA_OECONF = "--with-glibc=${S}"
+CFLAGS += "-fgnu89-inline -std=gnu99 -DIS_IN\(x\)='0'"
+
+do_install() {
+	install -d ${D}${bindir}
+	install -m 0755 ${B}/localedef ${D}${bindir}/cross-localedef
+}
diff --git a/poky/meta/recipes-core/glibc/glibc-collateral.inc b/poky/meta/recipes-core/glibc/glibc-collateral.inc
index aa871ac..536edfb 100644
--- a/poky/meta/recipes-core/glibc/glibc-collateral.inc
+++ b/poky/meta/recipes-core/glibc/glibc-collateral.inc
@@ -9,6 +9,7 @@
 # http://lists.openembedded.org/pipermail/openembedded-core/2015-January/100679.html
 ARM_INSTRUCTION_SET_armv4 = "arm"
 ARM_INSTRUCTION_SET_armv5 = "arm"
+ARM_INSTRUCTION_SET_armv6 = "arm"
 
 deltask do_fetch
 deltask do_unpack
diff --git a/poky/meta/recipes-core/glibc/glibc-initial.inc b/poky/meta/recipes-core/glibc/glibc-initial.inc
index b86e2fb..acd0d6b 100644
--- a/poky/meta/recipes-core/glibc/glibc-initial.inc
+++ b/poky/meta/recipes-core/glibc/glibc-initial.inc
@@ -1,4 +1,4 @@
-DEPENDS = "linux-libc-headers virtual/${TARGET_PREFIX}gcc-initial libgcc-initial"
+DEPENDS = "linux-libc-headers virtual/${TARGET_PREFIX}gcc-initial libgcc-initial make-native bison-native"
 PROVIDES = "virtual/${TARGET_PREFIX}libc-initial"
 
 PACKAGES = ""
@@ -13,9 +13,9 @@
 	cfgscript=`python3 -c "import os; print(os.path.relpath('${S}', '.'))"`/configure
 	$cfgscript --host=${TARGET_SYS} --build=${BUILD_SYS} \
 		--prefix=/usr \
-		--without-cvs --disable-sanity-checks \
+		--disable-sanity-checks \
 		--with-headers=${STAGING_DIR_TARGET}${includedir} \
-		--enable-hacker-mode --enable-addons
+		--enable-hacker-mode
 }
 
 do_compile () {
diff --git a/poky/meta/recipes-core/glibc/glibc-initial_2.27.bb b/poky/meta/recipes-core/glibc/glibc-initial_2.28.bb
similarity index 100%
rename from poky/meta/recipes-core/glibc/glibc-initial_2.27.bb
rename to poky/meta/recipes-core/glibc/glibc-initial_2.28.bb
diff --git a/poky/meta/recipes-core/glibc/glibc-ld.inc b/poky/meta/recipes-core/glibc/glibc-ld.inc
index c1d635d..bb167b3 100644
--- a/poky/meta/recipes-core/glibc/glibc-ld.inc
+++ b/poky/meta/recipes-core/glibc/glibc-ld.inc
@@ -1,43 +1,15 @@
-def ld_append_if_tune_exists(d, infos, dict):
-    tune = d.getVar("DEFAULTTUNE") or ""
-    libdir = d.getVar("base_libdir") or ""
-    if tune in dict:
-        infos['ldconfig'].add('{"' + libdir + '/' + dict[tune][0] + '",' + dict[tune][1] + ' }')
-        infos['lddrewrite'].add(libdir+'/'+dict[tune][0])
+inherit linuxloader
+
+GLIBC_GETLOADER = "${@get_linuxloader(d)}"
 
 def glibc_dl_info(d):
-    ld_info_all = {
-        "mipsarch": ["ld.so.1", "FLAG_ELF_LIBC6"],
-        "mipsarchr6": ["ld-linux-mipsn8.so.1", "FLAG_ELF_LIBC6"],
-        "powerpc": ["ld.so.1", "FLAG_ELF_LIBC6"],
-        "powerpc-nf": ["ld.so.1", "FLAG_ELF_LIBC6"],
-        "powerpc64": ["ld64.so.1", "FLAG_ELF_LIBC6"],
-        "powerpc64-nf": ["ld64.so.1", "FLAG_ELF_LIBC6"],
-        "core2-32": ["ld-linux.so.2", "FLAG_ELF_LIBC6"],
-        "core2-64": ["ld-linux-x86-64.so.2", "FLAG_ELF_LIBC6"],
-        "x86": ["ld-linux.so.2", "FLAG_ELF_LIBC6"],
-        "x86-64": ["ld-linux-x86-64.so.2", "FLAG_ELF_LIBC6"],
-        "i586": ["ld-linux.so.2", "FLAG_ELF_LIBC6"],
-        "corei7-32": ["ld-linux.so.2", "FLAG_ELF_LIBC6"],
-        "corei7-64": ["ld-linux-x86-64.so.2", "FLAG_ELF_LIBC6"],
-    }
-
     infos = {'ldconfig':set(), 'lddrewrite':set()}
-    ld_append_if_tune_exists(d, infos, ld_info_all)
 
-    #DEFAULTTUNE_MULTILIB_ORIGINAL
-    original_tune=d.getVar("DEFAULTTUNE_MULTILIB_ORIGINAL")
-    if original_tune:
-        localdata = bb.data.createCopy(d)
-        localdata.setVar("DEFAULTTUNE", original_tune)
-        ld_append_if_tune_exists(localdata, infos, ld_info_all)
+    loaders = all_multilib_tune_values(d, "GLIBC_GETLOADER").split()
+    for loader in loaders:
+        infos['ldconfig'].add('{"' + loader + '",' + "FLAG_ELF_LIBC6" + ' }')
+        infos['lddrewrite'].add(loader)
 
-    variants = d.getVar("MULTILIB_VARIANTS") or ""
-    for item in variants.split():
-        localdata = bb.data.createCopy(d)
-        overrides = localdata.getVar("OVERRIDES", False) + ":virtclass-multilib-" + item
-        localdata.setVar("OVERRIDES", overrides)
-        ld_append_if_tune_exists(localdata, infos, ld_info_all)
     infos['ldconfig'] = ','.join(infos['ldconfig'])
     infos['lddrewrite'] = ' '.join(infos['lddrewrite'])
     return infos
diff --git a/poky/meta/recipes-core/glibc/glibc-locale.inc b/poky/meta/recipes-core/glibc/glibc-locale.inc
index e50e5cf..1b676dc 100644
--- a/poky/meta/recipes-core/glibc/glibc-locale.inc
+++ b/poky/meta/recipes-core/glibc/glibc-locale.inc
@@ -21,13 +21,13 @@
 # to decrease initial boot time and avoid localedef being killed by the OOM
 # killer which used to effectively break i18n on machines with < 128MB RAM.
 
-# default to disabled 
+# default to disabled
 ENABLE_BINARY_LOCALE_GENERATION ?= "0"
 ENABLE_BINARY_LOCALE_GENERATION_pn-nativesdk-glibc-locale = "1"
 
 #enable locale generation on these arches
 # BINARY_LOCALE_ARCHES is a space separated list of regular expressions
-BINARY_LOCALE_ARCHES ?= "arm.* aarch64 i[3-6]86 x86_64 powerpc mips mips64"
+BINARY_LOCALE_ARCHES ?= "arm.* aarch64 i[3-6]86 x86_64 powerpc mips mips64 riscv32 riscv64"
 
 # set "1" to use cross-localedef for locale generation
 # set "0" for qemu emulation of native localedef for locale generation
diff --git a/poky/meta/recipes-core/glibc/glibc-locale_2.27.bb b/poky/meta/recipes-core/glibc/glibc-locale_2.28.bb
similarity index 100%
rename from poky/meta/recipes-core/glibc/glibc-locale_2.27.bb
rename to poky/meta/recipes-core/glibc/glibc-locale_2.28.bb
diff --git a/poky/meta/recipes-core/glibc/glibc-mtrace_2.27.bb b/poky/meta/recipes-core/glibc/glibc-mtrace_2.28.bb
similarity index 100%
rename from poky/meta/recipes-core/glibc/glibc-mtrace_2.27.bb
rename to poky/meta/recipes-core/glibc/glibc-mtrace_2.28.bb
diff --git a/poky/meta/recipes-core/glibc/glibc-package.inc b/poky/meta/recipes-core/glibc/glibc-package.inc
index c1d186a..a98ae1a 100644
--- a/poky/meta/recipes-core/glibc/glibc-package.inc
+++ b/poky/meta/recipes-core/glibc/glibc-package.inc
@@ -1,6 +1,6 @@
 INHIBIT_SYSROOT_STRIP = "1"
 
-PACKAGES = "${PN}-dbg catchsegv sln nscd ldd tzcode glibc-thread-db ${PN}-pic libcidn libmemusage libsegfault ${PN}-pcprofile libsotruss ${PN} ${PN}-utils glibc-extra-nss ${PN}-dev ${PN}-staticdev ${PN}-doc"
+PACKAGES = "${PN}-dbg catchsegv sln nscd ldd tzcode glibc-thread-db ${PN}-pic libcidn libmemusage libnss-db libsegfault ${PN}-pcprofile libsotruss ${PN} ${PN}-utils glibc-extra-nss ${PN}-dev ${PN}-staticdev ${PN}-doc"
 
 # The ld.so in this glibc supports the GNU_HASH
 RPROVIDES_${PN} = "eglibc rtld(GNU_HASH)"
@@ -14,7 +14,7 @@
 RPROVIDES_glibc-thread-db = "eglibc-thread-db"
 RPROVIDES_${PN}-pcprofile = "eglibc-pcprofile"
 RPROVIDES_${PN}-dbg = "eglibc-dbg"
-libc_baselibs = "${base_libdir}/libcrypt*.so.* ${base_libdir}/libcrypt-*.so ${base_libdir}/libc.so.* ${base_libdir}/libc-*.so ${base_libdir}/libm*.so.* ${base_libdir}/libm-*.so ${base_libdir}/libmvec-*.so ${base_libdir}/ld*.so.* ${base_libdir}/ld-*.so ${base_libdir}/libpthread*.so.* ${base_libdir}/libpthread-*.so ${base_libdir}/libresolv*.so.* ${base_libdir}/libresolv-*.so ${base_libdir}/librt*.so.* ${base_libdir}/librt-*.so ${base_libdir}/libutil*.so.* ${base_libdir}/libutil-*.so ${base_libdir}/libnsl*.so.* ${base_libdir}/libnsl-*.so ${base_libdir}/libnss_files*.so.* ${base_libdir}/libnss_files-*.so ${base_libdir}/libnss_compat*.so.* ${base_libdir}/libnss_compat-*.so ${base_libdir}/libnss_dns*.so.* ${base_libdir}/libnss_dns-*.so ${base_libdir}/libdl*.so.* ${base_libdir}/libdl-*.so ${base_libdir}/libanl*.so.* ${base_libdir}/libanl-*.so ${base_libdir}/libBrokenLocale*.so.* ${base_libdir}/libBrokenLocale-*.so"
+libc_baselibs = "${base_libdir}/libc.so.* ${base_libdir}/libc-*.so ${base_libdir}/libm*.so.* ${base_libdir}/libm-*.so ${base_libdir}/libmvec-*.so ${base_libdir}/ld*.so.* ${base_libdir}/ld-*.so ${base_libdir}/libpthread*.so.* ${base_libdir}/libpthread-*.so ${base_libdir}/libresolv*.so.* ${base_libdir}/libresolv-*.so ${base_libdir}/librt*.so.* ${base_libdir}/librt-*.so ${base_libdir}/libutil*.so.* ${base_libdir}/libutil-*.so ${base_libdir}/libnsl*.so.* ${base_libdir}/libnsl-*.so ${base_libdir}/libnss_files*.so.* ${base_libdir}/libnss_files-*.so ${base_libdir}/libnss_compat*.so.* ${base_libdir}/libnss_compat-*.so ${base_libdir}/libnss_dns*.so.* ${base_libdir}/libnss_dns-*.so ${base_libdir}/libdl*.so.* ${base_libdir}/libdl-*.so ${base_libdir}/libanl*.so.* ${base_libdir}/libanl-*.so ${base_libdir}/libBrokenLocale*.so.* ${base_libdir}/libBrokenLocale-*.so"
 libc_baselibs_append_aarch64 = " /lib/ld-linux-aarch64*.so.1"
 INSANE_SKIP_${PN}_append_aarch64 = " libdir"
 
@@ -23,12 +23,14 @@
 FILES_libsegfault = "${base_libdir}/libSegFault*"
 FILES_libcidn = "${base_libdir}/libcidn-*.so ${base_libdir}/libcidn.so.*"
 FILES_libmemusage = "${base_libdir}/libmemusage.so"
+FILES_libnss-db = "${base_libdir}/libnss_db.so.* ${base_libdir}/libnss_db-*.so ${localstatedir}/db/Makefile ${localstatedir}/db/makedbs.sh"
+RDEPENDS_libnss-db = "${PN}-utils"
 FILES_glibc-extra-nss = "${base_libdir}/libnss_*-*.so ${base_libdir}/libnss_*.so.*"
 FILES_sln = "${base_sbindir}/sln"
 FILES_${PN}-pic = "${libdir}/*_pic.a ${libdir}/*_pic.map ${libdir}/libc_pic/*.o"
 FILES_libsotruss = "${libdir}/audit/sotruss-lib.so"
 FILES_SOLIBSDEV = "${libdir}/lib*${SOLIBSDEV}"
-FILES_${PN}-dev += "${bindir}/rpcgen ${libdir}/*_nonshared.a ${base_libdir}/*_nonshared.a ${base_libdir}/*.o ${datadir}/aclocal"
+FILES_${PN}-dev += "${libdir}/*_nonshared.a ${base_libdir}/*_nonshared.a ${base_libdir}/*.o ${datadir}/aclocal"
 FILES_${PN}-staticdev += "${libdir}/*.a ${base_libdir}/*.a"
 FILES_nscd = "${sbindir}/nscd* ${sysconfdir}/init.d/nscd ${systemd_unitdir}/system/nscd* ${sysconfdir}/tmpfiles.d/nscd.conf \
               ${sysconfdir}/nscd.conf ${sysconfdir}/default/volatiles/98_nscd ${localstatedir}/db/nscd"
@@ -51,7 +53,7 @@
 SUMMARY_ldd = "print shared library dependencies"
 DESCRIPTION_ldd = "${bindir}/ldd prints shared library dependencies for each program or shared library specified on the command line."
 SUMMARY_${PN}-utils = "Miscellaneous utilities provided by glibc"
-DESCRIPTION_${PN}-utils = "Miscellaneous utilities including getconf, iconv, locale, gencat, rpcgen, ..."
+DESCRIPTION_${PN}-utils = "Miscellaneous utilities including getconf, iconv, locale, gencat, ..."
 DESCRIPTION_libsotruss = "Library to support sotruss which traces calls through PLTs"
 DESCRIPTION_tzcode = "tzcode, timezone zoneinfo utils -- zic, zdump, tzselect"
 
@@ -59,7 +61,6 @@
 
 do_install_append () {
 	rm -f ${D}${sysconfdir}/localtime
-	rm -rf ${D}${localstatedir}
 
 	# remove empty glibc dir
 	if [ -d ${D}${libexecdir} ]; then
@@ -71,7 +72,6 @@
 	if [ -f ${D}${bindir}/mtrace ]; then
 		sed -i -e '1s,#!.*perl,#! ${USRBINPATH}/env perl,' -e '2s,exec.*perl,exec ${USRBINPATH}/env perl,' ${D}${bindir}/mtrace
 	fi
-	rm -rf ${D}${includedir}/rpcsvc/rquota*
 	# Info dir listing isn't interesting at this point so remove it if it exists.
 	if [ -e "${D}${infodir}/dir" ]; then
 		rm -f ${D}${infodir}/dir
@@ -96,6 +96,7 @@
 	install -d ${D}${localstatedir}/db/nscd
 	install -m 0755 ${S}/nscd/nscd.init ${D}${sysconfdir}/init.d/nscd
 	install -m 0755 ${S}/nscd/nscd.conf ${D}${sysconfdir}/nscd.conf
+	install -m 0755 ${WORKDIR}/makedbs.sh ${D}${localstatedir}/db
 	sed -i "s%daemon%start-stop-daemon --start --exec%g" ${D}${sysconfdir}/init.d/nscd
 	sed -i "s|\(enable-cache\t\+netgroup\t\+\)yes|\1no|" ${D}${sysconfdir}/nscd.conf
 
@@ -206,10 +207,11 @@
 	rm -rf ${D}/${localedir}
 	rm -rf ${D}${datadir}/locale
 	if [ "${libdir}" != "${exec_prefix}/lib" ]; then
-		if [ -d ${D}${exec_prefix}/lib/locale ] ; then
-			rm -rf ${D}${exec_prefix}/lib/locale
+		if [ -d ${D}${exec_prefix}/lib ]; then
 			# error out if directory isn't empty
-			rm -f ${D}${exec_prefix}/lib
+			# this dir should only contain locale dir
+			# which has been deleted in the previous step
+			rmdir ${D}${exec_prefix}/lib
 		fi
 	fi
 }
diff --git a/poky/meta/recipes-core/glibc/glibc-scripts_2.27.bb b/poky/meta/recipes-core/glibc/glibc-scripts_2.28.bb
similarity index 100%
rename from poky/meta/recipes-core/glibc/glibc-scripts_2.27.bb
rename to poky/meta/recipes-core/glibc/glibc-scripts_2.28.bb
diff --git a/poky/meta/recipes-core/glibc/glibc.inc b/poky/meta/recipes-core/glibc/glibc.inc
index ce1222b..99c92ce 100644
--- a/poky/meta/recipes-core/glibc/glibc.inc
+++ b/poky/meta/recipes-core/glibc/glibc.inc
@@ -13,9 +13,6 @@
             opt_effective = opt
     if opt_effective == "-O0":
         bb.fatal("%s can't be built with %s, try -O1 instead" % (d.getVar('PN'), opt_effective))
-    if opt_effective in ("-O", "-O1", "-Os"):
-        bb.note("%s doesn't build cleanly with %s, adding -Wno-error to SELECTED_OPTIMIZATION" % (d.getVar('PN'), opt_effective))
-        d.appendVar("SELECTED_OPTIMIZATION", " -Wno-error")
 }
 
 # siteconfig.bbclass runs configure which needs a working compiler
@@ -33,12 +30,8 @@
 
 # nptl needs unwind support in gcc, which can't be built without glibc.
 DEPENDS = "virtual/${TARGET_PREFIX}gcc-initial libgcc-initial linux-libc-headers virtual/${TARGET_PREFIX}libc-initial"
-# nptl needs libgcc but dlopens it, so our shlibs code doesn't detect this
-#RDEPENDS_${PN} += "${@['','libgcc']['nptl' in '${GLIBC_ADDONS}']}"
 
-CRYPTPROVIDES = "virtual/crypt"
-CRYPTPROVIDES_class-nativesdk = ""
-PROVIDES = "virtual/libc virtual/${TARGET_PREFIX}libc-for-gcc ${CRYPTPROVIDES}"
+PROVIDES = "virtual/libc virtual/${TARGET_PREFIX}libc-for-gcc"
 PROVIDES += "virtual/libintl virtual/libiconv"
 inherit autotools texinfo distro_features_check systemd
 
@@ -63,6 +56,7 @@
 # http://lists.openembedded.org/pipermail/openembedded-core/2015-January/100679.html
 ARM_INSTRUCTION_SET_armv4 = "arm"
 ARM_INSTRUCTION_SET_armv5 = "arm"
+ARM_INSTRUCTION_SET_armv6 = "arm"
 
 # glibc uses PARALLELMFLAGS variable to pass parallel build info so transfer
 # PARALLEL_MAKE into PARALLELMFLAGS and empty out PARALLEL_MAKE
@@ -80,8 +74,6 @@
 	sed -e "s#@BASH@#/bin/sh#" -i ${S}/elf/ldd.bash.in
 }
 
-GLIBC_ADDONS ?= "nptl,libidn"
-
 # Enable backtrace from abort()
 do_configure_append_arm () {
 	echo "CFLAGS-abort.c = -fasynchronous-unwind-tables" >> ${B}/configparms
diff --git a/poky/meta/recipes-core/glibc/glibc/0001-nativesdk-glibc-Look-for-host-system-ld.so.cache-as-.patch b/poky/meta/recipes-core/glibc/glibc/0001-nativesdk-glibc-Look-for-host-system-ld.so.cache-as-.patch
index 86234c9..5df26a8 100644
--- a/poky/meta/recipes-core/glibc/glibc/0001-nativesdk-glibc-Look-for-host-system-ld.so.cache-as-.patch
+++ b/poky/meta/recipes-core/glibc/glibc/0001-nativesdk-glibc-Look-for-host-system-ld.so.cache-as-.patch
@@ -1,8 +1,7 @@
-From bd91b60ce6ff01f49b173b6b45e23ce94911b2a6 Mon Sep 17 00:00:00 2001
+From bd51b3add89a5cb2d8f44029a1027c780b2afff5 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Wed, 18 Mar 2015 01:48:24 +0000
-Subject: [PATCH 01/27] nativesdk-glibc: Look for host system ld.so.cache as
- well
+Subject: [PATCH] nativesdk-glibc: Look for host system ld.so.cache as well
 
 Upstream-Status: Inappropriate [embedded specific]
 
@@ -31,10 +30,10 @@
  1 file changed, 8 insertions(+), 8 deletions(-)
 
 diff --git a/elf/dl-load.c b/elf/dl-load.c
-index 7554a99b5a..a73d11a62f 100644
+index c51e4b3718..44bbb69dc4 100644
 --- a/elf/dl-load.c
 +++ b/elf/dl-load.c
-@@ -2007,6 +2007,14 @@ _dl_map_object (struct link_map *loader, const char *name,
+@@ -2085,6 +2085,14 @@ _dl_map_object (struct link_map *loader, const char *name,
              }
          }
  
@@ -49,7 +48,7 @@
  #ifdef USE_LDCONFIG
        if (fd == -1
  	  && (__glibc_likely ((mode & __RTLD_SECURE) == 0)
-@@ -2065,14 +2073,6 @@ _dl_map_object (struct link_map *loader, const char *name,
+@@ -2143,14 +2151,6 @@ _dl_map_object (struct link_map *loader, const char *name,
  	}
  #endif
  
@@ -64,6 +63,3 @@
        /* Add another newline when we are tracing the library loading.  */
        if (__glibc_unlikely (GLRO(dl_debug_mask) & DL_DEBUG_LIBS))
  	_dl_debug_printf ("\n");
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0002-nativesdk-glibc-Fix-buffer-overrun-with-a-relocated-.patch b/poky/meta/recipes-core/glibc/glibc/0002-nativesdk-glibc-Fix-buffer-overrun-with-a-relocated-.patch
index 899481f..daadec7 100644
--- a/poky/meta/recipes-core/glibc/glibc/0002-nativesdk-glibc-Fix-buffer-overrun-with-a-relocated-.patch
+++ b/poky/meta/recipes-core/glibc/glibc/0002-nativesdk-glibc-Fix-buffer-overrun-with-a-relocated-.patch
@@ -1,8 +1,7 @@
-From 50736f7fc1fdc9e1f7c05f1fec75c977d9be9228 Mon Sep 17 00:00:00 2001
+From fdc8a33ac2c81a0237b8a6d8b1aac7f1cdbb46af Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Wed, 18 Mar 2015 01:50:00 +0000
-Subject: [PATCH 02/27] nativesdk-glibc: Fix buffer overrun with a relocated
- SDK
+Subject: [PATCH] nativesdk-glibc: Fix buffer overrun with a relocated SDK
 
 When ld-linux-*.so.2 is relocated to a path that is longer than the
 original fixed location, the dynamic loader will crash in open_path
@@ -22,10 +21,10 @@
  1 file changed, 12 insertions(+)
 
 diff --git a/elf/dl-load.c b/elf/dl-load.c
-index a73d11a62f..62e3eee478 100644
+index 44bbb69dc4..74e2e5e962 100644
 --- a/elf/dl-load.c
 +++ b/elf/dl-load.c
-@@ -1707,7 +1707,19 @@ open_path (const char *name, size_t namelen, int mode,
+@@ -1785,7 +1785,19 @@ open_path (const char *name, size_t namelen, int mode,
         given on the command line when rtld is run directly.  */
      return -1;
  
@@ -45,6 +44,3 @@
    do
      {
        struct r_search_path_elem *this_dir = *dirs;
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0003-nativesdk-glibc-Raise-the-size-of-arrays-containing-.patch b/poky/meta/recipes-core/glibc/glibc/0003-nativesdk-glibc-Raise-the-size-of-arrays-containing-.patch
index 03f9991..e082540 100644
--- a/poky/meta/recipes-core/glibc/glibc/0003-nativesdk-glibc-Raise-the-size-of-arrays-containing-.patch
+++ b/poky/meta/recipes-core/glibc/glibc/0003-nativesdk-glibc-Raise-the-size-of-arrays-containing-.patch
@@ -1,8 +1,7 @@
-From 695e1cbff6ee6db3435c33e55311c67adf44476d Mon Sep 17 00:00:00 2001
+From 055dd46b793168fb08e44913153010b088011ba2 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Wed, 18 Mar 2015 01:51:38 +0000
-Subject: [PATCH 03/27] nativesdk-glibc: Raise the size of arrays containing dl
- paths
+Subject: [PATCH] nativesdk-glibc: Raise the size of arrays containing dl paths
 
 This patch puts the dynamic loader path in the binaries, SYSTEM_DIRS strings
 and lengths as well as ld.so.cache path in the dynamic loader to specific
@@ -41,10 +40,10 @@
  _dl_cache_libcmp (const char *p1, const char *p2)
  {
 diff --git a/elf/dl-load.c b/elf/dl-load.c
-index 62e3eee478..6ddba73650 100644
+index 74e2e5e962..8f19186e1c 100644
 --- a/elf/dl-load.c
 +++ b/elf/dl-load.c
-@@ -109,8 +109,8 @@ static size_t max_capstrlen attribute_relro;
+@@ -110,8 +110,8 @@ static size_t max_capstrlen attribute_relro;
     gen-trusted-dirs.awk.  */
  #include "trusted-dirs.h"
  
@@ -81,10 +80,10 @@
     a platform.  */
  static int
 diff --git a/elf/rtld.c b/elf/rtld.c
-index 453f56eb15..08e0c4c94b 100644
+index 1b0c74739f..a70a62d31e 100644
 --- a/elf/rtld.c
 +++ b/elf/rtld.c
-@@ -128,6 +128,7 @@ dso_name_valid_for_suid (const char *p)
+@@ -130,6 +130,7 @@ dso_name_valid_for_suid (const char *p)
      }
    return *p != '\0';
  }
@@ -92,7 +91,7 @@
  
  /* LD_AUDIT variable contents.  Must be processed before the
     audit_list below.  */
-@@ -1000,12 +1001,12 @@ of this helper program; chances are you did not intend to run this program.\n\
+@@ -1001,12 +1002,12 @@ of this helper program; chances are you did not intend to run this program.\n\
    --list                list all dependencies and how they are resolved\n\
    --verify              verify that given object really is a dynamically linked\n\
  			object we can handle\n\
@@ -108,7 +107,7 @@
        ++_dl_skip_args;
        --_dl_argc;
 diff --git a/iconv/gconv_conf.c b/iconv/gconv_conf.c
-index d6cf9d2a3e..9fcf970144 100644
+index f173cde71b..5c3205026f 100644
 --- a/iconv/gconv_conf.c
 +++ b/iconv/gconv_conf.c
 @@ -36,7 +36,7 @@
@@ -135,6 +134,3 @@
  #ifndef add_system_dir
  # define add_system_dir(dir) add_dir (dir)
  #endif
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0004-nativesdk-glibc-Allow-64-bit-atomics-for-x86.patch b/poky/meta/recipes-core/glibc/glibc/0004-nativesdk-glibc-Allow-64-bit-atomics-for-x86.patch
index f9d70c2..1ae2e33 100644
--- a/poky/meta/recipes-core/glibc/glibc/0004-nativesdk-glibc-Allow-64-bit-atomics-for-x86.patch
+++ b/poky/meta/recipes-core/glibc/glibc/0004-nativesdk-glibc-Allow-64-bit-atomics-for-x86.patch
@@ -1,7 +1,7 @@
-From 2bafdbd7067794c6a24e5e85608c0ec4638c5667 Mon Sep 17 00:00:00 2001
+From a237553ccd15276462be2023057a017fa8ee5d7c Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Thu, 31 Dec 2015 14:35:35 -0800
-Subject: [PATCH 04/27] nativesdk-glibc: Allow 64 bit atomics for x86
+Subject: [PATCH] nativesdk-glibc: Allow 64 bit atomics for x86
 
 The fix consist of allowing 64bit atomic ops for x86.
 This should be safe for i586 and newer CPUs.
@@ -29,6 +29,3 @@
  #define USE_ATOMIC_COMPILER_BUILTINS 0
  #define ATOMIC_EXCHANGE_USES_CAS 0
  
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0005-fsl-e500-e5500-e6500-603e-fsqrt-implementation.patch b/poky/meta/recipes-core/glibc/glibc/0005-fsl-e500-e5500-e6500-603e-fsqrt-implementation.patch
deleted file mode 100644
index ad9106e..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0005-fsl-e500-e5500-e6500-603e-fsqrt-implementation.patch
+++ /dev/null
@@ -1,1584 +0,0 @@
-From 661adfe9c220d10617bf6bb283827471c3956b01 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 18 Mar 2015 00:01:50 +0000
-Subject: [PATCH 05/27] fsl e500/e5500/e6500/603e fsqrt implementation
-
-Upstream-Status: Pending
-Signed-off-by: Edmar Wienskoski <edmar@freescale.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c        | 134 +++++++++++++++++++++
- sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c       | 101 ++++++++++++++++
- sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c      | 134 +++++++++++++++++++++
- sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c     | 101 ++++++++++++++++
- sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c       | 134 +++++++++++++++++++++
- sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c      | 101 ++++++++++++++++
- sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c       | 134 +++++++++++++++++++++
- sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c      | 101 ++++++++++++++++
- sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c       | 134 +++++++++++++++++++++
- sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c      | 101 ++++++++++++++++
- sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c       | 134 +++++++++++++++++++++
- sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c      | 101 ++++++++++++++++
- .../sysv/linux/powerpc/powerpc32/603e/fpu/Implies  |   1 +
- .../linux/powerpc/powerpc32/e300c3/fpu/Implies     |   2 +
- .../linux/powerpc/powerpc32/e500mc/fpu/Implies     |   1 +
- .../sysv/linux/powerpc/powerpc32/e5500/fpu/Implies |   1 +
- .../sysv/linux/powerpc/powerpc32/e6500/fpu/Implies |   1 +
- .../sysv/linux/powerpc/powerpc64/e5500/fpu/Implies |   1 +
- .../sysv/linux/powerpc/powerpc64/e6500/fpu/Implies |   1 +
- 19 files changed, 1418 insertions(+)
- create mode 100644 sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
- create mode 100644 sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
- create mode 100644 sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
- create mode 100644 sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
- create mode 100644 sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
- create mode 100644 sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
- create mode 100644 sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
- create mode 100644 sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
- create mode 100644 sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
- create mode 100644 sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
- create mode 100644 sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
- create mode 100644 sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
- create mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc32/603e/fpu/Implies
- create mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc32/e300c3/fpu/Implies
- create mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc32/e500mc/fpu/Implies
- create mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc32/e5500/fpu/Implies
- create mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc32/e6500/fpu/Implies
- create mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc64/e5500/fpu/Implies
- create mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc64/e6500/fpu/Implies
-
-diff --git a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
-new file mode 100644
-index 0000000000..71e516d1c8
---- /dev/null
-+++ b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
-@@ -0,0 +1,134 @@
-+/* Double-precision floating point square root.
-+   Copyright (C) 2010 Free Software Foundation, Inc.
-+   This file is part of the GNU C Library.
-+
-+   The GNU C Library is free software; you can redistribute it and/or
-+   modify it under the terms of the GNU Lesser General Public
-+   License as published by the Free Software Foundation; either
-+   version 2.1 of the License, or (at your option) any later version.
-+
-+   The GNU C Library is distributed in the hope that it will be useful,
-+   but WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   Lesser General Public License for more details.
-+
-+   You should have received a copy of the GNU Lesser General Public
-+   License along with the GNU C Library; if not, write to the Free
-+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-+   02111-1307 USA.  */
-+
-+#include <math.h>
-+#include <math_private.h>
-+#include <fenv_libc.h>
-+#include <inttypes.h>
-+
-+#include <sysdep.h>
-+#include <ldsodefs.h>
-+
-+static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
-+static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
-+static const float two108 = 3.245185536584267269e+32;
-+static const float twom54 = 5.551115123125782702e-17;
-+static const float half = 0.5;
-+
-+/* The method is based on the descriptions in:
-+
-+   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
-+   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
-+
-+   We find the actual square root and half of its reciprocal
-+   simultaneously.  */
-+
-+#ifdef __STDC__
-+double
-+__ieee754_sqrt (double b)
-+#else
-+double
-+__ieee754_sqrt (b)
-+     double b;
-+#endif
-+{
-+  if (__builtin_expect (b > 0, 1))
-+    {
-+      double y, g, h, d, r;
-+      ieee_double_shape_type u;
-+
-+      if (__builtin_expect (b != a_inf.value, 1))
-+        {
-+          fenv_t fe;
-+
-+          fe = fegetenv_register ();
-+
-+          u.value = b;
-+
-+          relax_fenv_state ();
-+
-+          __asm__ ("frsqrte %[estimate], %[x]\n"
-+                   : [estimate] "=f" (y) : [x] "f" (b));
-+
-+          /* Following Muller et al, page 168, equation 5.20.
-+
-+             h goes to 1/(2*sqrt(b))
-+             g goes to sqrt(b).
-+
-+             We need three iterations to get within 1ulp.  */
-+
-+          /* Indicate that these can be performed prior to the branch.  GCC
-+             insists on sinking them below the branch, however; it seems like
-+             they'd be better before the branch so that we can cover any latency
-+             from storing the argument and loading its high word.  Oh well.  */
-+
-+          g = b * y;
-+          h = 0.5 * y;
-+
-+          /* Handle small numbers by scaling.  */
-+          if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
-+            return __ieee754_sqrt (b * two108) * twom54;
-+
-+#define FMADD(a_, c_, b_)                                               \
-+          ({ double __r;                                                \
-+          __asm__ ("fmadd %[r], %[a], %[c], %[b]\n"                     \
-+                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+          __r;})
-+#define FNMSUB(a_, c_, b_)                                          \
-+          ({ double __r;                                                \
-+          __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                     \
-+                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+          __r;})
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          /* g is now +/- 1ulp, or exactly equal to, the square root of b.  */
-+
-+          /* Final refinement.  */
-+          d = FNMSUB (g, g, b);
-+
-+          fesetenv_register (fe);
-+          return FMADD (d, h, g);
-+        }
-+    }
-+  else if (b < 0)
-+    {
-+      /* For some reason, some PowerPC32 processors don't implement
-+         FE_INVALID_SQRT.  */
-+#ifdef FE_INVALID_SQRT
-+      feraiseexcept (FE_INVALID_SQRT);
-+
-+      fenv_union_t u = { .fenv = fegetenv_register () };
-+      if ((u.l & FE_INVALID) == 0)
-+#endif
-+	feraiseexcept (FE_INVALID);
-+      b = a_nan.value;
-+    }
-+  return f_wash (b);
-+}
-diff --git a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
-new file mode 100644
-index 0000000000..26fa067abf
---- /dev/null
-+++ b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
-@@ -0,0 +1,101 @@
-+/* Single-precision floating point square root.
-+   Copyright (C) 2010 Free Software Foundation, Inc.
-+   This file is part of the GNU C Library.
-+
-+   The GNU C Library is free software; you can redistribute it and/or
-+   modify it under the terms of the GNU Lesser General Public
-+   License as published by the Free Software Foundation; either
-+   version 2.1 of the License, or (at your option) any later version.
-+
-+   The GNU C Library is distributed in the hope that it will be useful,
-+   but WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   Lesser General Public License for more details.
-+
-+   You should have received a copy of the GNU Lesser General Public
-+   License along with the GNU C Library; if not, write to the Free
-+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-+   02111-1307 USA.  */
-+
-+#include <math.h>
-+#include <math_private.h>
-+#include <fenv_libc.h>
-+#include <inttypes.h>
-+
-+#include <sysdep.h>
-+#include <ldsodefs.h>
-+
-+static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
-+static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
-+static const float threehalf = 1.5;
-+
-+/* The method is based on the descriptions in:
-+
-+   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
-+   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
-+
-+   We find the reciprocal square root and use that to compute the actual
-+   square root.  */
-+
-+#ifdef __STDC__
-+float
-+__ieee754_sqrtf (float b)
-+#else
-+float
-+__ieee754_sqrtf (b)
-+     float b;
-+#endif
-+{
-+  if (__builtin_expect (b > 0, 1))
-+    {
-+#define FMSUB(a_, c_, b_)                                               \
-+      ({ double __r;                                                    \
-+        __asm__ ("fmsub %[r], %[a], %[c], %[b]\n"                       \
-+                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+        __r;})
-+#define FNMSUB(a_, c_, b_)                                              \
-+      ({ double __r;                                                    \
-+        __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                      \
-+                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+        __r;})
-+
-+      if (__builtin_expect (b != a_inf.value, 1))
-+        {
-+          double y, x;
-+          fenv_t fe;
-+
-+          fe = fegetenv_register ();
-+
-+          relax_fenv_state ();
-+
-+          /* Compute y = 1.5 * b - b.  Uses fewer constants than y = 0.5 * b.  */
-+          y = FMSUB (threehalf, b, b);
-+
-+          /* Initial estimate.  */
-+          __asm__ ("frsqrte %[x], %[b]\n" : [x] "=f" (x) : [b] "f" (b));
-+
-+          /* Iterate.  x_{n+1} = x_n * (1.5 - y * (x_n * x_n)).  */
-+          x = x * FNMSUB (y, x * x, threehalf);
-+          x = x * FNMSUB (y, x * x, threehalf);
-+          x = x * FNMSUB (y, x * x, threehalf);
-+
-+          /* All done.  */
-+          fesetenv_register (fe);
-+          return x * b;
-+        }
-+    }
-+  else if (b < 0)
-+    {
-+      /* For some reason, some PowerPC32 processors don't implement
-+         FE_INVALID_SQRT.  */
-+#ifdef FE_INVALID_SQRT
-+      feraiseexcept (FE_INVALID_SQRT);
-+
-+      fenv_union_t u = { .fenv = fegetenv_register () };
-+      if ((u.l & FE_INVALID) == 0)
-+#endif
-+	feraiseexcept (FE_INVALID);
-+      b = a_nan.value;
-+    }
-+  return f_washf (b);
-+}
-diff --git a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
-new file mode 100644
-index 0000000000..71e516d1c8
---- /dev/null
-+++ b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
-@@ -0,0 +1,134 @@
-+/* Double-precision floating point square root.
-+   Copyright (C) 2010 Free Software Foundation, Inc.
-+   This file is part of the GNU C Library.
-+
-+   The GNU C Library is free software; you can redistribute it and/or
-+   modify it under the terms of the GNU Lesser General Public
-+   License as published by the Free Software Foundation; either
-+   version 2.1 of the License, or (at your option) any later version.
-+
-+   The GNU C Library is distributed in the hope that it will be useful,
-+   but WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   Lesser General Public License for more details.
-+
-+   You should have received a copy of the GNU Lesser General Public
-+   License along with the GNU C Library; if not, write to the Free
-+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-+   02111-1307 USA.  */
-+
-+#include <math.h>
-+#include <math_private.h>
-+#include <fenv_libc.h>
-+#include <inttypes.h>
-+
-+#include <sysdep.h>
-+#include <ldsodefs.h>
-+
-+static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
-+static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
-+static const float two108 = 3.245185536584267269e+32;
-+static const float twom54 = 5.551115123125782702e-17;
-+static const float half = 0.5;
-+
-+/* The method is based on the descriptions in:
-+
-+   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
-+   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
-+
-+   We find the actual square root and half of its reciprocal
-+   simultaneously.  */
-+
-+#ifdef __STDC__
-+double
-+__ieee754_sqrt (double b)
-+#else
-+double
-+__ieee754_sqrt (b)
-+     double b;
-+#endif
-+{
-+  if (__builtin_expect (b > 0, 1))
-+    {
-+      double y, g, h, d, r;
-+      ieee_double_shape_type u;
-+
-+      if (__builtin_expect (b != a_inf.value, 1))
-+        {
-+          fenv_t fe;
-+
-+          fe = fegetenv_register ();
-+
-+          u.value = b;
-+
-+          relax_fenv_state ();
-+
-+          __asm__ ("frsqrte %[estimate], %[x]\n"
-+                   : [estimate] "=f" (y) : [x] "f" (b));
-+
-+          /* Following Muller et al, page 168, equation 5.20.
-+
-+             h goes to 1/(2*sqrt(b))
-+             g goes to sqrt(b).
-+
-+             We need three iterations to get within 1ulp.  */
-+
-+          /* Indicate that these can be performed prior to the branch.  GCC
-+             insists on sinking them below the branch, however; it seems like
-+             they'd be better before the branch so that we can cover any latency
-+             from storing the argument and loading its high word.  Oh well.  */
-+
-+          g = b * y;
-+          h = 0.5 * y;
-+
-+          /* Handle small numbers by scaling.  */
-+          if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
-+            return __ieee754_sqrt (b * two108) * twom54;
-+
-+#define FMADD(a_, c_, b_)                                               \
-+          ({ double __r;                                                \
-+          __asm__ ("fmadd %[r], %[a], %[c], %[b]\n"                     \
-+                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+          __r;})
-+#define FNMSUB(a_, c_, b_)                                          \
-+          ({ double __r;                                                \
-+          __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                     \
-+                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+          __r;})
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          /* g is now +/- 1ulp, or exactly equal to, the square root of b.  */
-+
-+          /* Final refinement.  */
-+          d = FNMSUB (g, g, b);
-+
-+          fesetenv_register (fe);
-+          return FMADD (d, h, g);
-+        }
-+    }
-+  else if (b < 0)
-+    {
-+      /* For some reason, some PowerPC32 processors don't implement
-+         FE_INVALID_SQRT.  */
-+#ifdef FE_INVALID_SQRT
-+      feraiseexcept (FE_INVALID_SQRT);
-+
-+      fenv_union_t u = { .fenv = fegetenv_register () };
-+      if ((u.l & FE_INVALID) == 0)
-+#endif
-+	feraiseexcept (FE_INVALID);
-+      b = a_nan.value;
-+    }
-+  return f_wash (b);
-+}
-diff --git a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
-new file mode 100644
-index 0000000000..26fa067abf
---- /dev/null
-+++ b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
-@@ -0,0 +1,101 @@
-+/* Single-precision floating point square root.
-+   Copyright (C) 2010 Free Software Foundation, Inc.
-+   This file is part of the GNU C Library.
-+
-+   The GNU C Library is free software; you can redistribute it and/or
-+   modify it under the terms of the GNU Lesser General Public
-+   License as published by the Free Software Foundation; either
-+   version 2.1 of the License, or (at your option) any later version.
-+
-+   The GNU C Library is distributed in the hope that it will be useful,
-+   but WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   Lesser General Public License for more details.
-+
-+   You should have received a copy of the GNU Lesser General Public
-+   License along with the GNU C Library; if not, write to the Free
-+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-+   02111-1307 USA.  */
-+
-+#include <math.h>
-+#include <math_private.h>
-+#include <fenv_libc.h>
-+#include <inttypes.h>
-+
-+#include <sysdep.h>
-+#include <ldsodefs.h>
-+
-+static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
-+static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
-+static const float threehalf = 1.5;
-+
-+/* The method is based on the descriptions in:
-+
-+   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
-+   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
-+
-+   We find the reciprocal square root and use that to compute the actual
-+   square root.  */
-+
-+#ifdef __STDC__
-+float
-+__ieee754_sqrtf (float b)
-+#else
-+float
-+__ieee754_sqrtf (b)
-+     float b;
-+#endif
-+{
-+  if (__builtin_expect (b > 0, 1))
-+    {
-+#define FMSUB(a_, c_, b_)                                               \
-+      ({ double __r;                                                    \
-+        __asm__ ("fmsub %[r], %[a], %[c], %[b]\n"                       \
-+                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+        __r;})
-+#define FNMSUB(a_, c_, b_)                                              \
-+      ({ double __r;                                                    \
-+        __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                      \
-+                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+        __r;})
-+
-+      if (__builtin_expect (b != a_inf.value, 1))
-+        {
-+          double y, x;
-+          fenv_t fe;
-+
-+          fe = fegetenv_register ();
-+
-+          relax_fenv_state ();
-+
-+          /* Compute y = 1.5 * b - b.  Uses fewer constants than y = 0.5 * b.  */
-+          y = FMSUB (threehalf, b, b);
-+
-+          /* Initial estimate.  */
-+          __asm__ ("frsqrte %[x], %[b]\n" : [x] "=f" (x) : [b] "f" (b));
-+
-+          /* Iterate.  x_{n+1} = x_n * (1.5 - y * (x_n * x_n)).  */
-+          x = x * FNMSUB (y, x * x, threehalf);
-+          x = x * FNMSUB (y, x * x, threehalf);
-+          x = x * FNMSUB (y, x * x, threehalf);
-+
-+          /* All done.  */
-+          fesetenv_register (fe);
-+          return x * b;
-+        }
-+    }
-+  else if (b < 0)
-+    {
-+      /* For some reason, some PowerPC32 processors don't implement
-+         FE_INVALID_SQRT.  */
-+#ifdef FE_INVALID_SQRT
-+      feraiseexcept (FE_INVALID_SQRT);
-+
-+      fenv_union_t u = { .fenv = fegetenv_register () };
-+      if ((u.l & FE_INVALID) == 0)
-+#endif
-+	feraiseexcept (FE_INVALID);
-+      b = a_nan.value;
-+    }
-+  return f_washf (b);
-+}
-diff --git a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
-new file mode 100644
-index 0000000000..71e516d1c8
---- /dev/null
-+++ b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
-@@ -0,0 +1,134 @@
-+/* Double-precision floating point square root.
-+   Copyright (C) 2010 Free Software Foundation, Inc.
-+   This file is part of the GNU C Library.
-+
-+   The GNU C Library is free software; you can redistribute it and/or
-+   modify it under the terms of the GNU Lesser General Public
-+   License as published by the Free Software Foundation; either
-+   version 2.1 of the License, or (at your option) any later version.
-+
-+   The GNU C Library is distributed in the hope that it will be useful,
-+   but WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   Lesser General Public License for more details.
-+
-+   You should have received a copy of the GNU Lesser General Public
-+   License along with the GNU C Library; if not, write to the Free
-+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-+   02111-1307 USA.  */
-+
-+#include <math.h>
-+#include <math_private.h>
-+#include <fenv_libc.h>
-+#include <inttypes.h>
-+
-+#include <sysdep.h>
-+#include <ldsodefs.h>
-+
-+static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
-+static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
-+static const float two108 = 3.245185536584267269e+32;
-+static const float twom54 = 5.551115123125782702e-17;
-+static const float half = 0.5;
-+
-+/* The method is based on the descriptions in:
-+
-+   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
-+   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
-+
-+   We find the actual square root and half of its reciprocal
-+   simultaneously.  */
-+
-+#ifdef __STDC__
-+double
-+__ieee754_sqrt (double b)
-+#else
-+double
-+__ieee754_sqrt (b)
-+     double b;
-+#endif
-+{
-+  if (__builtin_expect (b > 0, 1))
-+    {
-+      double y, g, h, d, r;
-+      ieee_double_shape_type u;
-+
-+      if (__builtin_expect (b != a_inf.value, 1))
-+        {
-+          fenv_t fe;
-+
-+          fe = fegetenv_register ();
-+
-+          u.value = b;
-+
-+          relax_fenv_state ();
-+
-+          __asm__ ("frsqrte %[estimate], %[x]\n"
-+                   : [estimate] "=f" (y) : [x] "f" (b));
-+
-+          /* Following Muller et al, page 168, equation 5.20.
-+
-+             h goes to 1/(2*sqrt(b))
-+             g goes to sqrt(b).
-+
-+             We need three iterations to get within 1ulp.  */
-+
-+          /* Indicate that these can be performed prior to the branch.  GCC
-+             insists on sinking them below the branch, however; it seems like
-+             they'd be better before the branch so that we can cover any latency
-+             from storing the argument and loading its high word.  Oh well.  */
-+
-+          g = b * y;
-+          h = 0.5 * y;
-+
-+          /* Handle small numbers by scaling.  */
-+          if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
-+            return __ieee754_sqrt (b * two108) * twom54;
-+
-+#define FMADD(a_, c_, b_)                                               \
-+          ({ double __r;                                                \
-+          __asm__ ("fmadd %[r], %[a], %[c], %[b]\n"                     \
-+                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+          __r;})
-+#define FNMSUB(a_, c_, b_)                                          \
-+          ({ double __r;                                                \
-+          __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                     \
-+                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+          __r;})
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          /* g is now +/- 1ulp, or exactly equal to, the square root of b.  */
-+
-+          /* Final refinement.  */
-+          d = FNMSUB (g, g, b);
-+
-+          fesetenv_register (fe);
-+          return FMADD (d, h, g);
-+        }
-+    }
-+  else if (b < 0)
-+    {
-+      /* For some reason, some PowerPC32 processors don't implement
-+         FE_INVALID_SQRT.  */
-+#ifdef FE_INVALID_SQRT
-+      feraiseexcept (FE_INVALID_SQRT);
-+
-+      fenv_union_t u = { .fenv = fegetenv_register () };
-+      if ((u.l & FE_INVALID) == 0)
-+#endif
-+	feraiseexcept (FE_INVALID);
-+      b = a_nan.value;
-+    }
-+  return f_wash (b);
-+}
-diff --git a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
-new file mode 100644
-index 0000000000..26fa067abf
---- /dev/null
-+++ b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
-@@ -0,0 +1,101 @@
-+/* Single-precision floating point square root.
-+   Copyright (C) 2010 Free Software Foundation, Inc.
-+   This file is part of the GNU C Library.
-+
-+   The GNU C Library is free software; you can redistribute it and/or
-+   modify it under the terms of the GNU Lesser General Public
-+   License as published by the Free Software Foundation; either
-+   version 2.1 of the License, or (at your option) any later version.
-+
-+   The GNU C Library is distributed in the hope that it will be useful,
-+   but WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   Lesser General Public License for more details.
-+
-+   You should have received a copy of the GNU Lesser General Public
-+   License along with the GNU C Library; if not, write to the Free
-+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-+   02111-1307 USA.  */
-+
-+#include <math.h>
-+#include <math_private.h>
-+#include <fenv_libc.h>
-+#include <inttypes.h>
-+
-+#include <sysdep.h>
-+#include <ldsodefs.h>
-+
-+static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
-+static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
-+static const float threehalf = 1.5;
-+
-+/* The method is based on the descriptions in:
-+
-+   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
-+   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
-+
-+   We find the reciprocal square root and use that to compute the actual
-+   square root.  */
-+
-+#ifdef __STDC__
-+float
-+__ieee754_sqrtf (float b)
-+#else
-+float
-+__ieee754_sqrtf (b)
-+     float b;
-+#endif
-+{
-+  if (__builtin_expect (b > 0, 1))
-+    {
-+#define FMSUB(a_, c_, b_)                                               \
-+      ({ double __r;                                                    \
-+        __asm__ ("fmsub %[r], %[a], %[c], %[b]\n"                       \
-+                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+        __r;})
-+#define FNMSUB(a_, c_, b_)                                              \
-+      ({ double __r;                                                    \
-+        __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                      \
-+                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+        __r;})
-+
-+      if (__builtin_expect (b != a_inf.value, 1))
-+        {
-+          double y, x;
-+          fenv_t fe;
-+
-+          fe = fegetenv_register ();
-+
-+          relax_fenv_state ();
-+
-+          /* Compute y = 1.5 * b - b.  Uses fewer constants than y = 0.5 * b.  */
-+          y = FMSUB (threehalf, b, b);
-+
-+          /* Initial estimate.  */
-+          __asm__ ("frsqrte %[x], %[b]\n" : [x] "=f" (x) : [b] "f" (b));
-+
-+          /* Iterate.  x_{n+1} = x_n * (1.5 - y * (x_n * x_n)).  */
-+          x = x * FNMSUB (y, x * x, threehalf);
-+          x = x * FNMSUB (y, x * x, threehalf);
-+          x = x * FNMSUB (y, x * x, threehalf);
-+
-+          /* All done.  */
-+          fesetenv_register (fe);
-+          return x * b;
-+        }
-+    }
-+  else if (b < 0)
-+    {
-+      /* For some reason, some PowerPC32 processors don't implement
-+         FE_INVALID_SQRT.  */
-+#ifdef FE_INVALID_SQRT
-+      feraiseexcept (FE_INVALID_SQRT);
-+
-+      fenv_union_t u = { .fenv = fegetenv_register () };
-+      if ((u.l & FE_INVALID) == 0)
-+#endif
-+	feraiseexcept (FE_INVALID);
-+      b = a_nan.value;
-+    }
-+  return f_washf (b);
-+}
-diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
-new file mode 100644
-index 0000000000..71e516d1c8
---- /dev/null
-+++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
-@@ -0,0 +1,134 @@
-+/* Double-precision floating point square root.
-+   Copyright (C) 2010 Free Software Foundation, Inc.
-+   This file is part of the GNU C Library.
-+
-+   The GNU C Library is free software; you can redistribute it and/or
-+   modify it under the terms of the GNU Lesser General Public
-+   License as published by the Free Software Foundation; either
-+   version 2.1 of the License, or (at your option) any later version.
-+
-+   The GNU C Library is distributed in the hope that it will be useful,
-+   but WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   Lesser General Public License for more details.
-+
-+   You should have received a copy of the GNU Lesser General Public
-+   License along with the GNU C Library; if not, write to the Free
-+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-+   02111-1307 USA.  */
-+
-+#include <math.h>
-+#include <math_private.h>
-+#include <fenv_libc.h>
-+#include <inttypes.h>
-+
-+#include <sysdep.h>
-+#include <ldsodefs.h>
-+
-+static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
-+static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
-+static const float two108 = 3.245185536584267269e+32;
-+static const float twom54 = 5.551115123125782702e-17;
-+static const float half = 0.5;
-+
-+/* The method is based on the descriptions in:
-+
-+   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
-+   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
-+
-+   We find the actual square root and half of its reciprocal
-+   simultaneously.  */
-+
-+#ifdef __STDC__
-+double
-+__ieee754_sqrt (double b)
-+#else
-+double
-+__ieee754_sqrt (b)
-+     double b;
-+#endif
-+{
-+  if (__builtin_expect (b > 0, 1))
-+    {
-+      double y, g, h, d, r;
-+      ieee_double_shape_type u;
-+
-+      if (__builtin_expect (b != a_inf.value, 1))
-+        {
-+          fenv_t fe;
-+
-+          fe = fegetenv_register ();
-+
-+          u.value = b;
-+
-+          relax_fenv_state ();
-+
-+          __asm__ ("frsqrte %[estimate], %[x]\n"
-+                   : [estimate] "=f" (y) : [x] "f" (b));
-+
-+          /* Following Muller et al, page 168, equation 5.20.
-+
-+             h goes to 1/(2*sqrt(b))
-+             g goes to sqrt(b).
-+
-+             We need three iterations to get within 1ulp.  */
-+
-+          /* Indicate that these can be performed prior to the branch.  GCC
-+             insists on sinking them below the branch, however; it seems like
-+             they'd be better before the branch so that we can cover any latency
-+             from storing the argument and loading its high word.  Oh well.  */
-+
-+          g = b * y;
-+          h = 0.5 * y;
-+
-+          /* Handle small numbers by scaling.  */
-+          if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
-+            return __ieee754_sqrt (b * two108) * twom54;
-+
-+#define FMADD(a_, c_, b_)                                               \
-+          ({ double __r;                                                \
-+          __asm__ ("fmadd %[r], %[a], %[c], %[b]\n"                     \
-+                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+          __r;})
-+#define FNMSUB(a_, c_, b_)                                          \
-+          ({ double __r;                                                \
-+          __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                     \
-+                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+          __r;})
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          /* g is now +/- 1ulp, or exactly equal to, the square root of b.  */
-+
-+          /* Final refinement.  */
-+          d = FNMSUB (g, g, b);
-+
-+          fesetenv_register (fe);
-+          return FMADD (d, h, g);
-+        }
-+    }
-+  else if (b < 0)
-+    {
-+      /* For some reason, some PowerPC32 processors don't implement
-+         FE_INVALID_SQRT.  */
-+#ifdef FE_INVALID_SQRT
-+      feraiseexcept (FE_INVALID_SQRT);
-+
-+      fenv_union_t u = { .fenv = fegetenv_register () };
-+      if ((u.l & FE_INVALID) == 0)
-+#endif
-+	feraiseexcept (FE_INVALID);
-+      b = a_nan.value;
-+    }
-+  return f_wash (b);
-+}
-diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
-new file mode 100644
-index 0000000000..26fa067abf
---- /dev/null
-+++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
-@@ -0,0 +1,101 @@
-+/* Single-precision floating point square root.
-+   Copyright (C) 2010 Free Software Foundation, Inc.
-+   This file is part of the GNU C Library.
-+
-+   The GNU C Library is free software; you can redistribute it and/or
-+   modify it under the terms of the GNU Lesser General Public
-+   License as published by the Free Software Foundation; either
-+   version 2.1 of the License, or (at your option) any later version.
-+
-+   The GNU C Library is distributed in the hope that it will be useful,
-+   but WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   Lesser General Public License for more details.
-+
-+   You should have received a copy of the GNU Lesser General Public
-+   License along with the GNU C Library; if not, write to the Free
-+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-+   02111-1307 USA.  */
-+
-+#include <math.h>
-+#include <math_private.h>
-+#include <fenv_libc.h>
-+#include <inttypes.h>
-+
-+#include <sysdep.h>
-+#include <ldsodefs.h>
-+
-+static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
-+static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
-+static const float threehalf = 1.5;
-+
-+/* The method is based on the descriptions in:
-+
-+   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
-+   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
-+
-+   We find the reciprocal square root and use that to compute the actual
-+   square root.  */
-+
-+#ifdef __STDC__
-+float
-+__ieee754_sqrtf (float b)
-+#else
-+float
-+__ieee754_sqrtf (b)
-+     float b;
-+#endif
-+{
-+  if (__builtin_expect (b > 0, 1))
-+    {
-+#define FMSUB(a_, c_, b_)                                               \
-+      ({ double __r;                                                    \
-+        __asm__ ("fmsub %[r], %[a], %[c], %[b]\n"                       \
-+                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+        __r;})
-+#define FNMSUB(a_, c_, b_)                                              \
-+      ({ double __r;                                                    \
-+        __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                      \
-+                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+        __r;})
-+
-+      if (__builtin_expect (b != a_inf.value, 1))
-+        {
-+          double y, x;
-+          fenv_t fe;
-+
-+          fe = fegetenv_register ();
-+
-+          relax_fenv_state ();
-+
-+          /* Compute y = 1.5 * b - b.  Uses fewer constants than y = 0.5 * b.  */
-+          y = FMSUB (threehalf, b, b);
-+
-+          /* Initial estimate.  */
-+          __asm__ ("frsqrte %[x], %[b]\n" : [x] "=f" (x) : [b] "f" (b));
-+
-+          /* Iterate.  x_{n+1} = x_n * (1.5 - y * (x_n * x_n)).  */
-+          x = x * FNMSUB (y, x * x, threehalf);
-+          x = x * FNMSUB (y, x * x, threehalf);
-+          x = x * FNMSUB (y, x * x, threehalf);
-+
-+          /* All done.  */
-+          fesetenv_register (fe);
-+          return x * b;
-+        }
-+    }
-+  else if (b < 0)
-+    {
-+      /* For some reason, some PowerPC32 processors don't implement
-+         FE_INVALID_SQRT.  */
-+#ifdef FE_INVALID_SQRT
-+      feraiseexcept (FE_INVALID_SQRT);
-+
-+      fenv_union_t u = { .fenv = fegetenv_register () };
-+      if ((u.l & FE_INVALID) == 0)
-+#endif
-+	feraiseexcept (FE_INVALID);
-+      b = a_nan.value;
-+    }
-+  return f_washf (b);
-+}
-diff --git a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
-new file mode 100644
-index 0000000000..71e516d1c8
---- /dev/null
-+++ b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
-@@ -0,0 +1,134 @@
-+/* Double-precision floating point square root.
-+   Copyright (C) 2010 Free Software Foundation, Inc.
-+   This file is part of the GNU C Library.
-+
-+   The GNU C Library is free software; you can redistribute it and/or
-+   modify it under the terms of the GNU Lesser General Public
-+   License as published by the Free Software Foundation; either
-+   version 2.1 of the License, or (at your option) any later version.
-+
-+   The GNU C Library is distributed in the hope that it will be useful,
-+   but WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   Lesser General Public License for more details.
-+
-+   You should have received a copy of the GNU Lesser General Public
-+   License along with the GNU C Library; if not, write to the Free
-+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-+   02111-1307 USA.  */
-+
-+#include <math.h>
-+#include <math_private.h>
-+#include <fenv_libc.h>
-+#include <inttypes.h>
-+
-+#include <sysdep.h>
-+#include <ldsodefs.h>
-+
-+static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
-+static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
-+static const float two108 = 3.245185536584267269e+32;
-+static const float twom54 = 5.551115123125782702e-17;
-+static const float half = 0.5;
-+
-+/* The method is based on the descriptions in:
-+
-+   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
-+   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
-+
-+   We find the actual square root and half of its reciprocal
-+   simultaneously.  */
-+
-+#ifdef __STDC__
-+double
-+__ieee754_sqrt (double b)
-+#else
-+double
-+__ieee754_sqrt (b)
-+     double b;
-+#endif
-+{
-+  if (__builtin_expect (b > 0, 1))
-+    {
-+      double y, g, h, d, r;
-+      ieee_double_shape_type u;
-+
-+      if (__builtin_expect (b != a_inf.value, 1))
-+        {
-+          fenv_t fe;
-+
-+          fe = fegetenv_register ();
-+
-+          u.value = b;
-+
-+          relax_fenv_state ();
-+
-+          __asm__ ("frsqrte %[estimate], %[x]\n"
-+                   : [estimate] "=f" (y) : [x] "f" (b));
-+
-+          /* Following Muller et al, page 168, equation 5.20.
-+
-+             h goes to 1/(2*sqrt(b))
-+             g goes to sqrt(b).
-+
-+             We need three iterations to get within 1ulp.  */
-+
-+          /* Indicate that these can be performed prior to the branch.  GCC
-+             insists on sinking them below the branch, however; it seems like
-+             they'd be better before the branch so that we can cover any latency
-+             from storing the argument and loading its high word.  Oh well.  */
-+
-+          g = b * y;
-+          h = 0.5 * y;
-+
-+          /* Handle small numbers by scaling.  */
-+          if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
-+            return __ieee754_sqrt (b * two108) * twom54;
-+
-+#define FMADD(a_, c_, b_)                                               \
-+          ({ double __r;                                                \
-+          __asm__ ("fmadd %[r], %[a], %[c], %[b]\n"                     \
-+                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+          __r;})
-+#define FNMSUB(a_, c_, b_)                                          \
-+          ({ double __r;                                                \
-+          __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                     \
-+                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+          __r;})
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          /* g is now +/- 1ulp, or exactly equal to, the square root of b.  */
-+
-+          /* Final refinement.  */
-+          d = FNMSUB (g, g, b);
-+
-+          fesetenv_register (fe);
-+          return FMADD (d, h, g);
-+        }
-+    }
-+  else if (b < 0)
-+    {
-+      /* For some reason, some PowerPC32 processors don't implement
-+         FE_INVALID_SQRT.  */
-+#ifdef FE_INVALID_SQRT
-+      feraiseexcept (FE_INVALID_SQRT);
-+
-+      fenv_union_t u = { .fenv = fegetenv_register () };
-+      if ((u.l & FE_INVALID) == 0)
-+#endif
-+	feraiseexcept (FE_INVALID);
-+      b = a_nan.value;
-+    }
-+  return f_wash (b);
-+}
-diff --git a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
-new file mode 100644
-index 0000000000..26fa067abf
---- /dev/null
-+++ b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
-@@ -0,0 +1,101 @@
-+/* Single-precision floating point square root.
-+   Copyright (C) 2010 Free Software Foundation, Inc.
-+   This file is part of the GNU C Library.
-+
-+   The GNU C Library is free software; you can redistribute it and/or
-+   modify it under the terms of the GNU Lesser General Public
-+   License as published by the Free Software Foundation; either
-+   version 2.1 of the License, or (at your option) any later version.
-+
-+   The GNU C Library is distributed in the hope that it will be useful,
-+   but WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   Lesser General Public License for more details.
-+
-+   You should have received a copy of the GNU Lesser General Public
-+   License along with the GNU C Library; if not, write to the Free
-+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-+   02111-1307 USA.  */
-+
-+#include <math.h>
-+#include <math_private.h>
-+#include <fenv_libc.h>
-+#include <inttypes.h>
-+
-+#include <sysdep.h>
-+#include <ldsodefs.h>
-+
-+static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
-+static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
-+static const float threehalf = 1.5;
-+
-+/* The method is based on the descriptions in:
-+
-+   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
-+   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
-+
-+   We find the reciprocal square root and use that to compute the actual
-+   square root.  */
-+
-+#ifdef __STDC__
-+float
-+__ieee754_sqrtf (float b)
-+#else
-+float
-+__ieee754_sqrtf (b)
-+     float b;
-+#endif
-+{
-+  if (__builtin_expect (b > 0, 1))
-+    {
-+#define FMSUB(a_, c_, b_)                                               \
-+      ({ double __r;                                                    \
-+        __asm__ ("fmsub %[r], %[a], %[c], %[b]\n"                       \
-+                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+        __r;})
-+#define FNMSUB(a_, c_, b_)                                              \
-+      ({ double __r;                                                    \
-+        __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                      \
-+                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+        __r;})
-+
-+      if (__builtin_expect (b != a_inf.value, 1))
-+        {
-+          double y, x;
-+          fenv_t fe;
-+
-+          fe = fegetenv_register ();
-+
-+          relax_fenv_state ();
-+
-+          /* Compute y = 1.5 * b - b.  Uses fewer constants than y = 0.5 * b.  */
-+          y = FMSUB (threehalf, b, b);
-+
-+          /* Initial estimate.  */
-+          __asm__ ("frsqrte %[x], %[b]\n" : [x] "=f" (x) : [b] "f" (b));
-+
-+          /* Iterate.  x_{n+1} = x_n * (1.5 - y * (x_n * x_n)).  */
-+          x = x * FNMSUB (y, x * x, threehalf);
-+          x = x * FNMSUB (y, x * x, threehalf);
-+          x = x * FNMSUB (y, x * x, threehalf);
-+
-+          /* All done.  */
-+          fesetenv_register (fe);
-+          return x * b;
-+        }
-+    }
-+  else if (b < 0)
-+    {
-+      /* For some reason, some PowerPC32 processors don't implement
-+         FE_INVALID_SQRT.  */
-+#ifdef FE_INVALID_SQRT
-+      feraiseexcept (FE_INVALID_SQRT);
-+
-+      fenv_union_t u = { .fenv = fegetenv_register () };
-+      if ((u.l & FE_INVALID) == 0)
-+#endif
-+	feraiseexcept (FE_INVALID);
-+      b = a_nan.value;
-+    }
-+  return f_washf (b);
-+}
-diff --git a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
-new file mode 100644
-index 0000000000..71e516d1c8
---- /dev/null
-+++ b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
-@@ -0,0 +1,134 @@
-+/* Double-precision floating point square root.
-+   Copyright (C) 2010 Free Software Foundation, Inc.
-+   This file is part of the GNU C Library.
-+
-+   The GNU C Library is free software; you can redistribute it and/or
-+   modify it under the terms of the GNU Lesser General Public
-+   License as published by the Free Software Foundation; either
-+   version 2.1 of the License, or (at your option) any later version.
-+
-+   The GNU C Library is distributed in the hope that it will be useful,
-+   but WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   Lesser General Public License for more details.
-+
-+   You should have received a copy of the GNU Lesser General Public
-+   License along with the GNU C Library; if not, write to the Free
-+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-+   02111-1307 USA.  */
-+
-+#include <math.h>
-+#include <math_private.h>
-+#include <fenv_libc.h>
-+#include <inttypes.h>
-+
-+#include <sysdep.h>
-+#include <ldsodefs.h>
-+
-+static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
-+static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
-+static const float two108 = 3.245185536584267269e+32;
-+static const float twom54 = 5.551115123125782702e-17;
-+static const float half = 0.5;
-+
-+/* The method is based on the descriptions in:
-+
-+   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
-+   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
-+
-+   We find the actual square root and half of its reciprocal
-+   simultaneously.  */
-+
-+#ifdef __STDC__
-+double
-+__ieee754_sqrt (double b)
-+#else
-+double
-+__ieee754_sqrt (b)
-+     double b;
-+#endif
-+{
-+  if (__builtin_expect (b > 0, 1))
-+    {
-+      double y, g, h, d, r;
-+      ieee_double_shape_type u;
-+
-+      if (__builtin_expect (b != a_inf.value, 1))
-+        {
-+          fenv_t fe;
-+
-+          fe = fegetenv_register ();
-+
-+          u.value = b;
-+
-+          relax_fenv_state ();
-+
-+          __asm__ ("frsqrte %[estimate], %[x]\n"
-+                   : [estimate] "=f" (y) : [x] "f" (b));
-+
-+          /* Following Muller et al, page 168, equation 5.20.
-+
-+             h goes to 1/(2*sqrt(b))
-+             g goes to sqrt(b).
-+
-+             We need three iterations to get within 1ulp.  */
-+
-+          /* Indicate that these can be performed prior to the branch.  GCC
-+             insists on sinking them below the branch, however; it seems like
-+             they'd be better before the branch so that we can cover any latency
-+             from storing the argument and loading its high word.  Oh well.  */
-+
-+          g = b * y;
-+          h = 0.5 * y;
-+
-+          /* Handle small numbers by scaling.  */
-+          if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
-+            return __ieee754_sqrt (b * two108) * twom54;
-+
-+#define FMADD(a_, c_, b_)                                               \
-+          ({ double __r;                                                \
-+          __asm__ ("fmadd %[r], %[a], %[c], %[b]\n"                     \
-+                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+          __r;})
-+#define FNMSUB(a_, c_, b_)                                          \
-+          ({ double __r;                                                \
-+          __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                     \
-+                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+          __r;})
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          r = FNMSUB (g, h, half);
-+          g = FMADD (g, r, g);
-+          h = FMADD (h, r, h);
-+
-+          /* g is now +/- 1ulp, or exactly equal to, the square root of b.  */
-+
-+          /* Final refinement.  */
-+          d = FNMSUB (g, g, b);
-+
-+          fesetenv_register (fe);
-+          return FMADD (d, h, g);
-+        }
-+    }
-+  else if (b < 0)
-+    {
-+      /* For some reason, some PowerPC32 processors don't implement
-+         FE_INVALID_SQRT.  */
-+#ifdef FE_INVALID_SQRT
-+      feraiseexcept (FE_INVALID_SQRT);
-+
-+      fenv_union_t u = { .fenv = fegetenv_register () };
-+      if ((u.l & FE_INVALID) == 0)
-+#endif
-+	feraiseexcept (FE_INVALID);
-+      b = a_nan.value;
-+    }
-+  return f_wash (b);
-+}
-diff --git a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
-new file mode 100644
-index 0000000000..26fa067abf
---- /dev/null
-+++ b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
-@@ -0,0 +1,101 @@
-+/* Single-precision floating point square root.
-+   Copyright (C) 2010 Free Software Foundation, Inc.
-+   This file is part of the GNU C Library.
-+
-+   The GNU C Library is free software; you can redistribute it and/or
-+   modify it under the terms of the GNU Lesser General Public
-+   License as published by the Free Software Foundation; either
-+   version 2.1 of the License, or (at your option) any later version.
-+
-+   The GNU C Library is distributed in the hope that it will be useful,
-+   but WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   Lesser General Public License for more details.
-+
-+   You should have received a copy of the GNU Lesser General Public
-+   License along with the GNU C Library; if not, write to the Free
-+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-+   02111-1307 USA.  */
-+
-+#include <math.h>
-+#include <math_private.h>
-+#include <fenv_libc.h>
-+#include <inttypes.h>
-+
-+#include <sysdep.h>
-+#include <ldsodefs.h>
-+
-+static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
-+static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
-+static const float threehalf = 1.5;
-+
-+/* The method is based on the descriptions in:
-+
-+   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
-+   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
-+
-+   We find the reciprocal square root and use that to compute the actual
-+   square root.  */
-+
-+#ifdef __STDC__
-+float
-+__ieee754_sqrtf (float b)
-+#else
-+float
-+__ieee754_sqrtf (b)
-+     float b;
-+#endif
-+{
-+  if (__builtin_expect (b > 0, 1))
-+    {
-+#define FMSUB(a_, c_, b_)                                               \
-+      ({ double __r;                                                    \
-+        __asm__ ("fmsub %[r], %[a], %[c], %[b]\n"                       \
-+                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+        __r;})
-+#define FNMSUB(a_, c_, b_)                                              \
-+      ({ double __r;                                                    \
-+        __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                      \
-+                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
-+        __r;})
-+
-+      if (__builtin_expect (b != a_inf.value, 1))
-+        {
-+          double y, x;
-+          fenv_t fe;
-+
-+          fe = fegetenv_register ();
-+
-+          relax_fenv_state ();
-+
-+          /* Compute y = 1.5 * b - b.  Uses fewer constants than y = 0.5 * b.  */
-+          y = FMSUB (threehalf, b, b);
-+
-+          /* Initial estimate.  */
-+          __asm__ ("frsqrte %[x], %[b]\n" : [x] "=f" (x) : [b] "f" (b));
-+
-+          /* Iterate.  x_{n+1} = x_n * (1.5 - y * (x_n * x_n)).  */
-+          x = x * FNMSUB (y, x * x, threehalf);
-+          x = x * FNMSUB (y, x * x, threehalf);
-+          x = x * FNMSUB (y, x * x, threehalf);
-+
-+          /* All done.  */
-+          fesetenv_register (fe);
-+          return x * b;
-+        }
-+    }
-+  else if (b < 0)
-+    {
-+      /* For some reason, some PowerPC32 processors don't implement
-+         FE_INVALID_SQRT.  */
-+#ifdef FE_INVALID_SQRT
-+      feraiseexcept (FE_INVALID_SQRT);
-+
-+      fenv_union_t u = { .fenv = fegetenv_register () };
-+      if ((u.l & FE_INVALID) == 0)
-+#endif
-+	feraiseexcept (FE_INVALID);
-+      b = a_nan.value;
-+    }
-+  return f_washf (b);
-+}
-diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/603e/fpu/Implies b/sysdeps/unix/sysv/linux/powerpc/powerpc32/603e/fpu/Implies
-new file mode 100644
-index 0000000000..b103b4dea5
---- /dev/null
-+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/603e/fpu/Implies
-@@ -0,0 +1 @@
-+powerpc/powerpc32/603e/fpu
-diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/e300c3/fpu/Implies b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e300c3/fpu/Implies
-new file mode 100644
-index 0000000000..64db17fada
---- /dev/null
-+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e300c3/fpu/Implies
-@@ -0,0 +1,2 @@
-+# e300c3 is a variant of 603e so use the same optimizations for sqrt
-+powerpc/powerpc32/603e/fpu
-diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500mc/fpu/Implies b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500mc/fpu/Implies
-new file mode 100644
-index 0000000000..7eac5fcf02
---- /dev/null
-+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500mc/fpu/Implies
-@@ -0,0 +1 @@
-+powerpc/powerpc32/e500mc/fpu
-diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/e5500/fpu/Implies b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e5500/fpu/Implies
-new file mode 100644
-index 0000000000..264b2a7700
---- /dev/null
-+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e5500/fpu/Implies
-@@ -0,0 +1 @@
-+powerpc/powerpc32/e5500/fpu
-diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/e6500/fpu/Implies b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e6500/fpu/Implies
-new file mode 100644
-index 0000000000..a25934467b
---- /dev/null
-+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e6500/fpu/Implies
-@@ -0,0 +1 @@
-+powerpc/powerpc32/e6500/fpu
-diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/e5500/fpu/Implies b/sysdeps/unix/sysv/linux/powerpc/powerpc64/e5500/fpu/Implies
-new file mode 100644
-index 0000000000..a7bc854be8
---- /dev/null
-+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/e5500/fpu/Implies
-@@ -0,0 +1 @@
-+powerpc/powerpc64/e5500/fpu
-diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/e6500/fpu/Implies b/sysdeps/unix/sysv/linux/powerpc/powerpc64/e6500/fpu/Implies
-new file mode 100644
-index 0000000000..04ff8cc181
---- /dev/null
-+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/e6500/fpu/Implies
-@@ -0,0 +1 @@
-+powerpc/powerpc64/e6500/fpu
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0005-nativesdk-glibc-Make-relocatable-install-for-locales.patch b/poky/meta/recipes-core/glibc/glibc/0005-nativesdk-glibc-Make-relocatable-install-for-locales.patch
new file mode 100644
index 0000000..b53f2ef
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0005-nativesdk-glibc-Make-relocatable-install-for-locales.patch
@@ -0,0 +1,67 @@
+From e1dc85af1800afa4fbf4eb5a59cc41025495af57 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 3 Aug 2018 09:55:12 -0700
+Subject: [PATCH] nativesdk-glibc: Make relocatable install for locales
+
+The glibc locale path is hard-coded to the install prefix, but in SDKs we need
+to be able to relocate the binaries.  Expand the strings to 4K and put them in a
+magic segment that we can relocate at install time.
+
+Upstream-Status: Inappropriate (OE-specific)
+
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ locale/findlocale.c  | 4 ++--
+ locale/loadarchive.c | 2 +-
+ locale/localeinfo.h  | 2 +-
+ 3 files changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/locale/findlocale.c b/locale/findlocale.c
+index 872cadb5b9..dd651e07f5 100644
+--- a/locale/findlocale.c
++++ b/locale/findlocale.c
+@@ -56,7 +56,7 @@ struct __locale_data *const _nl_C[] attribute_hidden =
+    which are somehow addressed.  */
+ struct loaded_l10nfile *_nl_locale_file_list[__LC_LAST];
+ 
+-const char _nl_default_locale_path[] attribute_hidden = COMPLOCALEDIR;
++char _nl_default_locale_path[4096] attribute_hidden __attribute__ ((section (".gccrelocprefix"))) = COMPLOCALEDIR;
+ 
+ /* Checks if the name is actually present, that is, not NULL and not
+    empty.  */
+@@ -167,7 +167,7 @@ _nl_find_locale (const char *locale_path, size_t locale_path_len,
+ 
+       /* Nothing in the archive.  Set the default path to search below.  */
+       locale_path = _nl_default_locale_path;
+-      locale_path_len = sizeof _nl_default_locale_path;
++      locale_path_len = strlen(locale_path) + 1;
+     }
+   else
+     /* We really have to load some data.  First see whether the name is
+diff --git a/locale/loadarchive.c b/locale/loadarchive.c
+index 516d30d8d1..9bfbe1a5dd 100644
+--- a/locale/loadarchive.c
++++ b/locale/loadarchive.c
+@@ -42,7 +42,7 @@
+ 
+ 
+ /* Name of the locale archive file.  */
+-static const char archfname[] = COMPLOCALEDIR "/locale-archive";
++static const char archfname[4096] __attribute__ ((section (".gccrelocprefix"))) = COMPLOCALEDIR "/locale-archive";
+ 
+ /* Size of initial mapping window, optimal if large enough to
+    cover the header plus the initial locale.  */
+diff --git a/locale/localeinfo.h b/locale/localeinfo.h
+index 68822a6319..537bc35149 100644
+--- a/locale/localeinfo.h
++++ b/locale/localeinfo.h
+@@ -325,7 +325,7 @@ _nl_lookup_word (locale_t l, int category, int item)
+ }
+ 
+ /* Default search path if no LOCPATH environment variable.  */
+-extern const char _nl_default_locale_path[] attribute_hidden;
++extern char _nl_default_locale_path[4096] attribute_hidden;
+ 
+ /* Load the locale data for CATEGORY from the file specified by *NAME.
+    If *NAME is "", use environment variables as specified by POSIX, and
diff --git a/poky/meta/recipes-core/glibc/glibc/0006-fsl-e500-e5500-e6500-603e-fsqrt-implementation.patch b/poky/meta/recipes-core/glibc/glibc/0006-fsl-e500-e5500-e6500-603e-fsqrt-implementation.patch
new file mode 100644
index 0000000..971700a
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0006-fsl-e500-e5500-e6500-603e-fsqrt-implementation.patch
@@ -0,0 +1,1581 @@
+From d23c577b0b70b34335971abaf3f50e617dda615e Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 18 Mar 2015 00:01:50 +0000
+Subject: [PATCH] fsl e500/e5500/e6500/603e fsqrt implementation
+
+Upstream-Status: Pending
+Signed-off-by: Edmar Wienskoski <edmar@freescale.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c   | 134 ++++++++++++++++++
+ sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c  | 101 +++++++++++++
+ sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c | 134 ++++++++++++++++++
+ .../powerpc/powerpc32/e500mc/fpu/e_sqrtf.c    | 101 +++++++++++++
+ sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c  | 134 ++++++++++++++++++
+ sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c | 101 +++++++++++++
+ sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c  | 134 ++++++++++++++++++
+ sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c | 101 +++++++++++++
+ sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c  | 134 ++++++++++++++++++
+ sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c | 101 +++++++++++++
+ sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c  | 134 ++++++++++++++++++
+ sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c | 101 +++++++++++++
+ .../linux/powerpc/powerpc32/603e/fpu/Implies  |   1 +
+ .../powerpc/powerpc32/e300c3/fpu/Implies      |   2 +
+ .../powerpc/powerpc32/e500mc/fpu/Implies      |   1 +
+ .../linux/powerpc/powerpc32/e5500/fpu/Implies |   1 +
+ .../linux/powerpc/powerpc32/e6500/fpu/Implies |   1 +
+ .../linux/powerpc/powerpc64/e5500/fpu/Implies |   1 +
+ .../linux/powerpc/powerpc64/e6500/fpu/Implies |   1 +
+ 19 files changed, 1418 insertions(+)
+ create mode 100644 sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
+ create mode 100644 sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
+ create mode 100644 sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
+ create mode 100644 sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
+ create mode 100644 sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
+ create mode 100644 sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
+ create mode 100644 sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
+ create mode 100644 sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
+ create mode 100644 sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
+ create mode 100644 sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
+ create mode 100644 sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
+ create mode 100644 sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
+ create mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc32/603e/fpu/Implies
+ create mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc32/e300c3/fpu/Implies
+ create mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc32/e500mc/fpu/Implies
+ create mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc32/e5500/fpu/Implies
+ create mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc32/e6500/fpu/Implies
+ create mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc64/e5500/fpu/Implies
+ create mode 100644 sysdeps/unix/sysv/linux/powerpc/powerpc64/e6500/fpu/Implies
+
+diff --git a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
+new file mode 100644
+index 0000000000..71e516d1c8
+--- /dev/null
++++ b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
+@@ -0,0 +1,134 @@
++/* Double-precision floating point square root.
++   Copyright (C) 2010 Free Software Foundation, Inc.
++   This file is part of the GNU C Library.
++
++   The GNU C Library is free software; you can redistribute it and/or
++   modify it under the terms of the GNU Lesser General Public
++   License as published by the Free Software Foundation; either
++   version 2.1 of the License, or (at your option) any later version.
++
++   The GNU C Library is distributed in the hope that it will be useful,
++   but WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   Lesser General Public License for more details.
++
++   You should have received a copy of the GNU Lesser General Public
++   License along with the GNU C Library; if not, write to the Free
++   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
++   02111-1307 USA.  */
++
++#include <math.h>
++#include <math_private.h>
++#include <fenv_libc.h>
++#include <inttypes.h>
++
++#include <sysdep.h>
++#include <ldsodefs.h>
++
++static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
++static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
++static const float two108 = 3.245185536584267269e+32;
++static const float twom54 = 5.551115123125782702e-17;
++static const float half = 0.5;
++
++/* The method is based on the descriptions in:
++
++   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
++   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
++
++   We find the actual square root and half of its reciprocal
++   simultaneously.  */
++
++#ifdef __STDC__
++double
++__ieee754_sqrt (double b)
++#else
++double
++__ieee754_sqrt (b)
++     double b;
++#endif
++{
++  if (__builtin_expect (b > 0, 1))
++    {
++      double y, g, h, d, r;
++      ieee_double_shape_type u;
++
++      if (__builtin_expect (b != a_inf.value, 1))
++        {
++          fenv_t fe;
++
++          fe = fegetenv_register ();
++
++          u.value = b;
++
++          relax_fenv_state ();
++
++          __asm__ ("frsqrte %[estimate], %[x]\n"
++                   : [estimate] "=f" (y) : [x] "f" (b));
++
++          /* Following Muller et al, page 168, equation 5.20.
++
++             h goes to 1/(2*sqrt(b))
++             g goes to sqrt(b).
++
++             We need three iterations to get within 1ulp.  */
++
++          /* Indicate that these can be performed prior to the branch.  GCC
++             insists on sinking them below the branch, however; it seems like
++             they'd be better before the branch so that we can cover any latency
++             from storing the argument and loading its high word.  Oh well.  */
++
++          g = b * y;
++          h = 0.5 * y;
++
++          /* Handle small numbers by scaling.  */
++          if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
++            return __ieee754_sqrt (b * two108) * twom54;
++
++#define FMADD(a_, c_, b_)                                               \
++          ({ double __r;                                                \
++          __asm__ ("fmadd %[r], %[a], %[c], %[b]\n"                     \
++                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++          __r;})
++#define FNMSUB(a_, c_, b_)                                          \
++          ({ double __r;                                                \
++          __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                     \
++                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++          __r;})
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          /* g is now +/- 1ulp, or exactly equal to, the square root of b.  */
++
++          /* Final refinement.  */
++          d = FNMSUB (g, g, b);
++
++          fesetenv_register (fe);
++          return FMADD (d, h, g);
++        }
++    }
++  else if (b < 0)
++    {
++      /* For some reason, some PowerPC32 processors don't implement
++         FE_INVALID_SQRT.  */
++#ifdef FE_INVALID_SQRT
++      feraiseexcept (FE_INVALID_SQRT);
++
++      fenv_union_t u = { .fenv = fegetenv_register () };
++      if ((u.l & FE_INVALID) == 0)
++#endif
++	feraiseexcept (FE_INVALID);
++      b = a_nan.value;
++    }
++  return f_wash (b);
++}
+diff --git a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
+new file mode 100644
+index 0000000000..26fa067abf
+--- /dev/null
++++ b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
+@@ -0,0 +1,101 @@
++/* Single-precision floating point square root.
++   Copyright (C) 2010 Free Software Foundation, Inc.
++   This file is part of the GNU C Library.
++
++   The GNU C Library is free software; you can redistribute it and/or
++   modify it under the terms of the GNU Lesser General Public
++   License as published by the Free Software Foundation; either
++   version 2.1 of the License, or (at your option) any later version.
++
++   The GNU C Library is distributed in the hope that it will be useful,
++   but WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   Lesser General Public License for more details.
++
++   You should have received a copy of the GNU Lesser General Public
++   License along with the GNU C Library; if not, write to the Free
++   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
++   02111-1307 USA.  */
++
++#include <math.h>
++#include <math_private.h>
++#include <fenv_libc.h>
++#include <inttypes.h>
++
++#include <sysdep.h>
++#include <ldsodefs.h>
++
++static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
++static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
++static const float threehalf = 1.5;
++
++/* The method is based on the descriptions in:
++
++   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
++   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
++
++   We find the reciprocal square root and use that to compute the actual
++   square root.  */
++
++#ifdef __STDC__
++float
++__ieee754_sqrtf (float b)
++#else
++float
++__ieee754_sqrtf (b)
++     float b;
++#endif
++{
++  if (__builtin_expect (b > 0, 1))
++    {
++#define FMSUB(a_, c_, b_)                                               \
++      ({ double __r;                                                    \
++        __asm__ ("fmsub %[r], %[a], %[c], %[b]\n"                       \
++                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++        __r;})
++#define FNMSUB(a_, c_, b_)                                              \
++      ({ double __r;                                                    \
++        __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                      \
++                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++        __r;})
++
++      if (__builtin_expect (b != a_inf.value, 1))
++        {
++          double y, x;
++          fenv_t fe;
++
++          fe = fegetenv_register ();
++
++          relax_fenv_state ();
++
++          /* Compute y = 1.5 * b - b.  Uses fewer constants than y = 0.5 * b.  */
++          y = FMSUB (threehalf, b, b);
++
++          /* Initial estimate.  */
++          __asm__ ("frsqrte %[x], %[b]\n" : [x] "=f" (x) : [b] "f" (b));
++
++          /* Iterate.  x_{n+1} = x_n * (1.5 - y * (x_n * x_n)).  */
++          x = x * FNMSUB (y, x * x, threehalf);
++          x = x * FNMSUB (y, x * x, threehalf);
++          x = x * FNMSUB (y, x * x, threehalf);
++
++          /* All done.  */
++          fesetenv_register (fe);
++          return x * b;
++        }
++    }
++  else if (b < 0)
++    {
++      /* For some reason, some PowerPC32 processors don't implement
++         FE_INVALID_SQRT.  */
++#ifdef FE_INVALID_SQRT
++      feraiseexcept (FE_INVALID_SQRT);
++
++      fenv_union_t u = { .fenv = fegetenv_register () };
++      if ((u.l & FE_INVALID) == 0)
++#endif
++	feraiseexcept (FE_INVALID);
++      b = a_nan.value;
++    }
++  return f_washf (b);
++}
+diff --git a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
+new file mode 100644
+index 0000000000..71e516d1c8
+--- /dev/null
++++ b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
+@@ -0,0 +1,134 @@
++/* Double-precision floating point square root.
++   Copyright (C) 2010 Free Software Foundation, Inc.
++   This file is part of the GNU C Library.
++
++   The GNU C Library is free software; you can redistribute it and/or
++   modify it under the terms of the GNU Lesser General Public
++   License as published by the Free Software Foundation; either
++   version 2.1 of the License, or (at your option) any later version.
++
++   The GNU C Library is distributed in the hope that it will be useful,
++   but WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   Lesser General Public License for more details.
++
++   You should have received a copy of the GNU Lesser General Public
++   License along with the GNU C Library; if not, write to the Free
++   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
++   02111-1307 USA.  */
++
++#include <math.h>
++#include <math_private.h>
++#include <fenv_libc.h>
++#include <inttypes.h>
++
++#include <sysdep.h>
++#include <ldsodefs.h>
++
++static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
++static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
++static const float two108 = 3.245185536584267269e+32;
++static const float twom54 = 5.551115123125782702e-17;
++static const float half = 0.5;
++
++/* The method is based on the descriptions in:
++
++   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
++   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
++
++   We find the actual square root and half of its reciprocal
++   simultaneously.  */
++
++#ifdef __STDC__
++double
++__ieee754_sqrt (double b)
++#else
++double
++__ieee754_sqrt (b)
++     double b;
++#endif
++{
++  if (__builtin_expect (b > 0, 1))
++    {
++      double y, g, h, d, r;
++      ieee_double_shape_type u;
++
++      if (__builtin_expect (b != a_inf.value, 1))
++        {
++          fenv_t fe;
++
++          fe = fegetenv_register ();
++
++          u.value = b;
++
++          relax_fenv_state ();
++
++          __asm__ ("frsqrte %[estimate], %[x]\n"
++                   : [estimate] "=f" (y) : [x] "f" (b));
++
++          /* Following Muller et al, page 168, equation 5.20.
++
++             h goes to 1/(2*sqrt(b))
++             g goes to sqrt(b).
++
++             We need three iterations to get within 1ulp.  */
++
++          /* Indicate that these can be performed prior to the branch.  GCC
++             insists on sinking them below the branch, however; it seems like
++             they'd be better before the branch so that we can cover any latency
++             from storing the argument and loading its high word.  Oh well.  */
++
++          g = b * y;
++          h = 0.5 * y;
++
++          /* Handle small numbers by scaling.  */
++          if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
++            return __ieee754_sqrt (b * two108) * twom54;
++
++#define FMADD(a_, c_, b_)                                               \
++          ({ double __r;                                                \
++          __asm__ ("fmadd %[r], %[a], %[c], %[b]\n"                     \
++                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++          __r;})
++#define FNMSUB(a_, c_, b_)                                          \
++          ({ double __r;                                                \
++          __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                     \
++                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++          __r;})
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          /* g is now +/- 1ulp, or exactly equal to, the square root of b.  */
++
++          /* Final refinement.  */
++          d = FNMSUB (g, g, b);
++
++          fesetenv_register (fe);
++          return FMADD (d, h, g);
++        }
++    }
++  else if (b < 0)
++    {
++      /* For some reason, some PowerPC32 processors don't implement
++         FE_INVALID_SQRT.  */
++#ifdef FE_INVALID_SQRT
++      feraiseexcept (FE_INVALID_SQRT);
++
++      fenv_union_t u = { .fenv = fegetenv_register () };
++      if ((u.l & FE_INVALID) == 0)
++#endif
++	feraiseexcept (FE_INVALID);
++      b = a_nan.value;
++    }
++  return f_wash (b);
++}
+diff --git a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
+new file mode 100644
+index 0000000000..26fa067abf
+--- /dev/null
++++ b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
+@@ -0,0 +1,101 @@
++/* Single-precision floating point square root.
++   Copyright (C) 2010 Free Software Foundation, Inc.
++   This file is part of the GNU C Library.
++
++   The GNU C Library is free software; you can redistribute it and/or
++   modify it under the terms of the GNU Lesser General Public
++   License as published by the Free Software Foundation; either
++   version 2.1 of the License, or (at your option) any later version.
++
++   The GNU C Library is distributed in the hope that it will be useful,
++   but WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   Lesser General Public License for more details.
++
++   You should have received a copy of the GNU Lesser General Public
++   License along with the GNU C Library; if not, write to the Free
++   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
++   02111-1307 USA.  */
++
++#include <math.h>
++#include <math_private.h>
++#include <fenv_libc.h>
++#include <inttypes.h>
++
++#include <sysdep.h>
++#include <ldsodefs.h>
++
++static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
++static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
++static const float threehalf = 1.5;
++
++/* The method is based on the descriptions in:
++
++   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
++   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
++
++   We find the reciprocal square root and use that to compute the actual
++   square root.  */
++
++#ifdef __STDC__
++float
++__ieee754_sqrtf (float b)
++#else
++float
++__ieee754_sqrtf (b)
++     float b;
++#endif
++{
++  if (__builtin_expect (b > 0, 1))
++    {
++#define FMSUB(a_, c_, b_)                                               \
++      ({ double __r;                                                    \
++        __asm__ ("fmsub %[r], %[a], %[c], %[b]\n"                       \
++                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++        __r;})
++#define FNMSUB(a_, c_, b_)                                              \
++      ({ double __r;                                                    \
++        __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                      \
++                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++        __r;})
++
++      if (__builtin_expect (b != a_inf.value, 1))
++        {
++          double y, x;
++          fenv_t fe;
++
++          fe = fegetenv_register ();
++
++          relax_fenv_state ();
++
++          /* Compute y = 1.5 * b - b.  Uses fewer constants than y = 0.5 * b.  */
++          y = FMSUB (threehalf, b, b);
++
++          /* Initial estimate.  */
++          __asm__ ("frsqrte %[x], %[b]\n" : [x] "=f" (x) : [b] "f" (b));
++
++          /* Iterate.  x_{n+1} = x_n * (1.5 - y * (x_n * x_n)).  */
++          x = x * FNMSUB (y, x * x, threehalf);
++          x = x * FNMSUB (y, x * x, threehalf);
++          x = x * FNMSUB (y, x * x, threehalf);
++
++          /* All done.  */
++          fesetenv_register (fe);
++          return x * b;
++        }
++    }
++  else if (b < 0)
++    {
++      /* For some reason, some PowerPC32 processors don't implement
++         FE_INVALID_SQRT.  */
++#ifdef FE_INVALID_SQRT
++      feraiseexcept (FE_INVALID_SQRT);
++
++      fenv_union_t u = { .fenv = fegetenv_register () };
++      if ((u.l & FE_INVALID) == 0)
++#endif
++	feraiseexcept (FE_INVALID);
++      b = a_nan.value;
++    }
++  return f_washf (b);
++}
+diff --git a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
+new file mode 100644
+index 0000000000..71e516d1c8
+--- /dev/null
++++ b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
+@@ -0,0 +1,134 @@
++/* Double-precision floating point square root.
++   Copyright (C) 2010 Free Software Foundation, Inc.
++   This file is part of the GNU C Library.
++
++   The GNU C Library is free software; you can redistribute it and/or
++   modify it under the terms of the GNU Lesser General Public
++   License as published by the Free Software Foundation; either
++   version 2.1 of the License, or (at your option) any later version.
++
++   The GNU C Library is distributed in the hope that it will be useful,
++   but WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   Lesser General Public License for more details.
++
++   You should have received a copy of the GNU Lesser General Public
++   License along with the GNU C Library; if not, write to the Free
++   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
++   02111-1307 USA.  */
++
++#include <math.h>
++#include <math_private.h>
++#include <fenv_libc.h>
++#include <inttypes.h>
++
++#include <sysdep.h>
++#include <ldsodefs.h>
++
++static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
++static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
++static const float two108 = 3.245185536584267269e+32;
++static const float twom54 = 5.551115123125782702e-17;
++static const float half = 0.5;
++
++/* The method is based on the descriptions in:
++
++   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
++   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
++
++   We find the actual square root and half of its reciprocal
++   simultaneously.  */
++
++#ifdef __STDC__
++double
++__ieee754_sqrt (double b)
++#else
++double
++__ieee754_sqrt (b)
++     double b;
++#endif
++{
++  if (__builtin_expect (b > 0, 1))
++    {
++      double y, g, h, d, r;
++      ieee_double_shape_type u;
++
++      if (__builtin_expect (b != a_inf.value, 1))
++        {
++          fenv_t fe;
++
++          fe = fegetenv_register ();
++
++          u.value = b;
++
++          relax_fenv_state ();
++
++          __asm__ ("frsqrte %[estimate], %[x]\n"
++                   : [estimate] "=f" (y) : [x] "f" (b));
++
++          /* Following Muller et al, page 168, equation 5.20.
++
++             h goes to 1/(2*sqrt(b))
++             g goes to sqrt(b).
++
++             We need three iterations to get within 1ulp.  */
++
++          /* Indicate that these can be performed prior to the branch.  GCC
++             insists on sinking them below the branch, however; it seems like
++             they'd be better before the branch so that we can cover any latency
++             from storing the argument and loading its high word.  Oh well.  */
++
++          g = b * y;
++          h = 0.5 * y;
++
++          /* Handle small numbers by scaling.  */
++          if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
++            return __ieee754_sqrt (b * two108) * twom54;
++
++#define FMADD(a_, c_, b_)                                               \
++          ({ double __r;                                                \
++          __asm__ ("fmadd %[r], %[a], %[c], %[b]\n"                     \
++                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++          __r;})
++#define FNMSUB(a_, c_, b_)                                          \
++          ({ double __r;                                                \
++          __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                     \
++                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++          __r;})
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          /* g is now +/- 1ulp, or exactly equal to, the square root of b.  */
++
++          /* Final refinement.  */
++          d = FNMSUB (g, g, b);
++
++          fesetenv_register (fe);
++          return FMADD (d, h, g);
++        }
++    }
++  else if (b < 0)
++    {
++      /* For some reason, some PowerPC32 processors don't implement
++         FE_INVALID_SQRT.  */
++#ifdef FE_INVALID_SQRT
++      feraiseexcept (FE_INVALID_SQRT);
++
++      fenv_union_t u = { .fenv = fegetenv_register () };
++      if ((u.l & FE_INVALID) == 0)
++#endif
++	feraiseexcept (FE_INVALID);
++      b = a_nan.value;
++    }
++  return f_wash (b);
++}
+diff --git a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
+new file mode 100644
+index 0000000000..26fa067abf
+--- /dev/null
++++ b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
+@@ -0,0 +1,101 @@
++/* Single-precision floating point square root.
++   Copyright (C) 2010 Free Software Foundation, Inc.
++   This file is part of the GNU C Library.
++
++   The GNU C Library is free software; you can redistribute it and/or
++   modify it under the terms of the GNU Lesser General Public
++   License as published by the Free Software Foundation; either
++   version 2.1 of the License, or (at your option) any later version.
++
++   The GNU C Library is distributed in the hope that it will be useful,
++   but WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   Lesser General Public License for more details.
++
++   You should have received a copy of the GNU Lesser General Public
++   License along with the GNU C Library; if not, write to the Free
++   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
++   02111-1307 USA.  */
++
++#include <math.h>
++#include <math_private.h>
++#include <fenv_libc.h>
++#include <inttypes.h>
++
++#include <sysdep.h>
++#include <ldsodefs.h>
++
++static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
++static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
++static const float threehalf = 1.5;
++
++/* The method is based on the descriptions in:
++
++   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
++   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
++
++   We find the reciprocal square root and use that to compute the actual
++   square root.  */
++
++#ifdef __STDC__
++float
++__ieee754_sqrtf (float b)
++#else
++float
++__ieee754_sqrtf (b)
++     float b;
++#endif
++{
++  if (__builtin_expect (b > 0, 1))
++    {
++#define FMSUB(a_, c_, b_)                                               \
++      ({ double __r;                                                    \
++        __asm__ ("fmsub %[r], %[a], %[c], %[b]\n"                       \
++                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++        __r;})
++#define FNMSUB(a_, c_, b_)                                              \
++      ({ double __r;                                                    \
++        __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                      \
++                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++        __r;})
++
++      if (__builtin_expect (b != a_inf.value, 1))
++        {
++          double y, x;
++          fenv_t fe;
++
++          fe = fegetenv_register ();
++
++          relax_fenv_state ();
++
++          /* Compute y = 1.5 * b - b.  Uses fewer constants than y = 0.5 * b.  */
++          y = FMSUB (threehalf, b, b);
++
++          /* Initial estimate.  */
++          __asm__ ("frsqrte %[x], %[b]\n" : [x] "=f" (x) : [b] "f" (b));
++
++          /* Iterate.  x_{n+1} = x_n * (1.5 - y * (x_n * x_n)).  */
++          x = x * FNMSUB (y, x * x, threehalf);
++          x = x * FNMSUB (y, x * x, threehalf);
++          x = x * FNMSUB (y, x * x, threehalf);
++
++          /* All done.  */
++          fesetenv_register (fe);
++          return x * b;
++        }
++    }
++  else if (b < 0)
++    {
++      /* For some reason, some PowerPC32 processors don't implement
++         FE_INVALID_SQRT.  */
++#ifdef FE_INVALID_SQRT
++      feraiseexcept (FE_INVALID_SQRT);
++
++      fenv_union_t u = { .fenv = fegetenv_register () };
++      if ((u.l & FE_INVALID) == 0)
++#endif
++	feraiseexcept (FE_INVALID);
++      b = a_nan.value;
++    }
++  return f_washf (b);
++}
+diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
+new file mode 100644
+index 0000000000..71e516d1c8
+--- /dev/null
++++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
+@@ -0,0 +1,134 @@
++/* Double-precision floating point square root.
++   Copyright (C) 2010 Free Software Foundation, Inc.
++   This file is part of the GNU C Library.
++
++   The GNU C Library is free software; you can redistribute it and/or
++   modify it under the terms of the GNU Lesser General Public
++   License as published by the Free Software Foundation; either
++   version 2.1 of the License, or (at your option) any later version.
++
++   The GNU C Library is distributed in the hope that it will be useful,
++   but WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   Lesser General Public License for more details.
++
++   You should have received a copy of the GNU Lesser General Public
++   License along with the GNU C Library; if not, write to the Free
++   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
++   02111-1307 USA.  */
++
++#include <math.h>
++#include <math_private.h>
++#include <fenv_libc.h>
++#include <inttypes.h>
++
++#include <sysdep.h>
++#include <ldsodefs.h>
++
++static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
++static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
++static const float two108 = 3.245185536584267269e+32;
++static const float twom54 = 5.551115123125782702e-17;
++static const float half = 0.5;
++
++/* The method is based on the descriptions in:
++
++   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
++   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
++
++   We find the actual square root and half of its reciprocal
++   simultaneously.  */
++
++#ifdef __STDC__
++double
++__ieee754_sqrt (double b)
++#else
++double
++__ieee754_sqrt (b)
++     double b;
++#endif
++{
++  if (__builtin_expect (b > 0, 1))
++    {
++      double y, g, h, d, r;
++      ieee_double_shape_type u;
++
++      if (__builtin_expect (b != a_inf.value, 1))
++        {
++          fenv_t fe;
++
++          fe = fegetenv_register ();
++
++          u.value = b;
++
++          relax_fenv_state ();
++
++          __asm__ ("frsqrte %[estimate], %[x]\n"
++                   : [estimate] "=f" (y) : [x] "f" (b));
++
++          /* Following Muller et al, page 168, equation 5.20.
++
++             h goes to 1/(2*sqrt(b))
++             g goes to sqrt(b).
++
++             We need three iterations to get within 1ulp.  */
++
++          /* Indicate that these can be performed prior to the branch.  GCC
++             insists on sinking them below the branch, however; it seems like
++             they'd be better before the branch so that we can cover any latency
++             from storing the argument and loading its high word.  Oh well.  */
++
++          g = b * y;
++          h = 0.5 * y;
++
++          /* Handle small numbers by scaling.  */
++          if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
++            return __ieee754_sqrt (b * two108) * twom54;
++
++#define FMADD(a_, c_, b_)                                               \
++          ({ double __r;                                                \
++          __asm__ ("fmadd %[r], %[a], %[c], %[b]\n"                     \
++                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++          __r;})
++#define FNMSUB(a_, c_, b_)                                          \
++          ({ double __r;                                                \
++          __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                     \
++                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++          __r;})
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          /* g is now +/- 1ulp, or exactly equal to, the square root of b.  */
++
++          /* Final refinement.  */
++          d = FNMSUB (g, g, b);
++
++          fesetenv_register (fe);
++          return FMADD (d, h, g);
++        }
++    }
++  else if (b < 0)
++    {
++      /* For some reason, some PowerPC32 processors don't implement
++         FE_INVALID_SQRT.  */
++#ifdef FE_INVALID_SQRT
++      feraiseexcept (FE_INVALID_SQRT);
++
++      fenv_union_t u = { .fenv = fegetenv_register () };
++      if ((u.l & FE_INVALID) == 0)
++#endif
++	feraiseexcept (FE_INVALID);
++      b = a_nan.value;
++    }
++  return f_wash (b);
++}
+diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
+new file mode 100644
+index 0000000000..26fa067abf
+--- /dev/null
++++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
+@@ -0,0 +1,101 @@
++/* Single-precision floating point square root.
++   Copyright (C) 2010 Free Software Foundation, Inc.
++   This file is part of the GNU C Library.
++
++   The GNU C Library is free software; you can redistribute it and/or
++   modify it under the terms of the GNU Lesser General Public
++   License as published by the Free Software Foundation; either
++   version 2.1 of the License, or (at your option) any later version.
++
++   The GNU C Library is distributed in the hope that it will be useful,
++   but WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   Lesser General Public License for more details.
++
++   You should have received a copy of the GNU Lesser General Public
++   License along with the GNU C Library; if not, write to the Free
++   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
++   02111-1307 USA.  */
++
++#include <math.h>
++#include <math_private.h>
++#include <fenv_libc.h>
++#include <inttypes.h>
++
++#include <sysdep.h>
++#include <ldsodefs.h>
++
++static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
++static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
++static const float threehalf = 1.5;
++
++/* The method is based on the descriptions in:
++
++   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
++   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
++
++   We find the reciprocal square root and use that to compute the actual
++   square root.  */
++
++#ifdef __STDC__
++float
++__ieee754_sqrtf (float b)
++#else
++float
++__ieee754_sqrtf (b)
++     float b;
++#endif
++{
++  if (__builtin_expect (b > 0, 1))
++    {
++#define FMSUB(a_, c_, b_)                                               \
++      ({ double __r;                                                    \
++        __asm__ ("fmsub %[r], %[a], %[c], %[b]\n"                       \
++                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++        __r;})
++#define FNMSUB(a_, c_, b_)                                              \
++      ({ double __r;                                                    \
++        __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                      \
++                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++        __r;})
++
++      if (__builtin_expect (b != a_inf.value, 1))
++        {
++          double y, x;
++          fenv_t fe;
++
++          fe = fegetenv_register ();
++
++          relax_fenv_state ();
++
++          /* Compute y = 1.5 * b - b.  Uses fewer constants than y = 0.5 * b.  */
++          y = FMSUB (threehalf, b, b);
++
++          /* Initial estimate.  */
++          __asm__ ("frsqrte %[x], %[b]\n" : [x] "=f" (x) : [b] "f" (b));
++
++          /* Iterate.  x_{n+1} = x_n * (1.5 - y * (x_n * x_n)).  */
++          x = x * FNMSUB (y, x * x, threehalf);
++          x = x * FNMSUB (y, x * x, threehalf);
++          x = x * FNMSUB (y, x * x, threehalf);
++
++          /* All done.  */
++          fesetenv_register (fe);
++          return x * b;
++        }
++    }
++  else if (b < 0)
++    {
++      /* For some reason, some PowerPC32 processors don't implement
++         FE_INVALID_SQRT.  */
++#ifdef FE_INVALID_SQRT
++      feraiseexcept (FE_INVALID_SQRT);
++
++      fenv_union_t u = { .fenv = fegetenv_register () };
++      if ((u.l & FE_INVALID) == 0)
++#endif
++	feraiseexcept (FE_INVALID);
++      b = a_nan.value;
++    }
++  return f_washf (b);
++}
+diff --git a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
+new file mode 100644
+index 0000000000..71e516d1c8
+--- /dev/null
++++ b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
+@@ -0,0 +1,134 @@
++/* Double-precision floating point square root.
++   Copyright (C) 2010 Free Software Foundation, Inc.
++   This file is part of the GNU C Library.
++
++   The GNU C Library is free software; you can redistribute it and/or
++   modify it under the terms of the GNU Lesser General Public
++   License as published by the Free Software Foundation; either
++   version 2.1 of the License, or (at your option) any later version.
++
++   The GNU C Library is distributed in the hope that it will be useful,
++   but WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   Lesser General Public License for more details.
++
++   You should have received a copy of the GNU Lesser General Public
++   License along with the GNU C Library; if not, write to the Free
++   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
++   02111-1307 USA.  */
++
++#include <math.h>
++#include <math_private.h>
++#include <fenv_libc.h>
++#include <inttypes.h>
++
++#include <sysdep.h>
++#include <ldsodefs.h>
++
++static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
++static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
++static const float two108 = 3.245185536584267269e+32;
++static const float twom54 = 5.551115123125782702e-17;
++static const float half = 0.5;
++
++/* The method is based on the descriptions in:
++
++   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
++   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
++
++   We find the actual square root and half of its reciprocal
++   simultaneously.  */
++
++#ifdef __STDC__
++double
++__ieee754_sqrt (double b)
++#else
++double
++__ieee754_sqrt (b)
++     double b;
++#endif
++{
++  if (__builtin_expect (b > 0, 1))
++    {
++      double y, g, h, d, r;
++      ieee_double_shape_type u;
++
++      if (__builtin_expect (b != a_inf.value, 1))
++        {
++          fenv_t fe;
++
++          fe = fegetenv_register ();
++
++          u.value = b;
++
++          relax_fenv_state ();
++
++          __asm__ ("frsqrte %[estimate], %[x]\n"
++                   : [estimate] "=f" (y) : [x] "f" (b));
++
++          /* Following Muller et al, page 168, equation 5.20.
++
++             h goes to 1/(2*sqrt(b))
++             g goes to sqrt(b).
++
++             We need three iterations to get within 1ulp.  */
++
++          /* Indicate that these can be performed prior to the branch.  GCC
++             insists on sinking them below the branch, however; it seems like
++             they'd be better before the branch so that we can cover any latency
++             from storing the argument and loading its high word.  Oh well.  */
++
++          g = b * y;
++          h = 0.5 * y;
++
++          /* Handle small numbers by scaling.  */
++          if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
++            return __ieee754_sqrt (b * two108) * twom54;
++
++#define FMADD(a_, c_, b_)                                               \
++          ({ double __r;                                                \
++          __asm__ ("fmadd %[r], %[a], %[c], %[b]\n"                     \
++                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++          __r;})
++#define FNMSUB(a_, c_, b_)                                          \
++          ({ double __r;                                                \
++          __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                     \
++                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++          __r;})
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          /* g is now +/- 1ulp, or exactly equal to, the square root of b.  */
++
++          /* Final refinement.  */
++          d = FNMSUB (g, g, b);
++
++          fesetenv_register (fe);
++          return FMADD (d, h, g);
++        }
++    }
++  else if (b < 0)
++    {
++      /* For some reason, some PowerPC32 processors don't implement
++         FE_INVALID_SQRT.  */
++#ifdef FE_INVALID_SQRT
++      feraiseexcept (FE_INVALID_SQRT);
++
++      fenv_union_t u = { .fenv = fegetenv_register () };
++      if ((u.l & FE_INVALID) == 0)
++#endif
++	feraiseexcept (FE_INVALID);
++      b = a_nan.value;
++    }
++  return f_wash (b);
++}
+diff --git a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
+new file mode 100644
+index 0000000000..26fa067abf
+--- /dev/null
++++ b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
+@@ -0,0 +1,101 @@
++/* Single-precision floating point square root.
++   Copyright (C) 2010 Free Software Foundation, Inc.
++   This file is part of the GNU C Library.
++
++   The GNU C Library is free software; you can redistribute it and/or
++   modify it under the terms of the GNU Lesser General Public
++   License as published by the Free Software Foundation; either
++   version 2.1 of the License, or (at your option) any later version.
++
++   The GNU C Library is distributed in the hope that it will be useful,
++   but WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   Lesser General Public License for more details.
++
++   You should have received a copy of the GNU Lesser General Public
++   License along with the GNU C Library; if not, write to the Free
++   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
++   02111-1307 USA.  */
++
++#include <math.h>
++#include <math_private.h>
++#include <fenv_libc.h>
++#include <inttypes.h>
++
++#include <sysdep.h>
++#include <ldsodefs.h>
++
++static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
++static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
++static const float threehalf = 1.5;
++
++/* The method is based on the descriptions in:
++
++   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
++   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
++
++   We find the reciprocal square root and use that to compute the actual
++   square root.  */
++
++#ifdef __STDC__
++float
++__ieee754_sqrtf (float b)
++#else
++float
++__ieee754_sqrtf (b)
++     float b;
++#endif
++{
++  if (__builtin_expect (b > 0, 1))
++    {
++#define FMSUB(a_, c_, b_)                                               \
++      ({ double __r;                                                    \
++        __asm__ ("fmsub %[r], %[a], %[c], %[b]\n"                       \
++                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++        __r;})
++#define FNMSUB(a_, c_, b_)                                              \
++      ({ double __r;                                                    \
++        __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                      \
++                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++        __r;})
++
++      if (__builtin_expect (b != a_inf.value, 1))
++        {
++          double y, x;
++          fenv_t fe;
++
++          fe = fegetenv_register ();
++
++          relax_fenv_state ();
++
++          /* Compute y = 1.5 * b - b.  Uses fewer constants than y = 0.5 * b.  */
++          y = FMSUB (threehalf, b, b);
++
++          /* Initial estimate.  */
++          __asm__ ("frsqrte %[x], %[b]\n" : [x] "=f" (x) : [b] "f" (b));
++
++          /* Iterate.  x_{n+1} = x_n * (1.5 - y * (x_n * x_n)).  */
++          x = x * FNMSUB (y, x * x, threehalf);
++          x = x * FNMSUB (y, x * x, threehalf);
++          x = x * FNMSUB (y, x * x, threehalf);
++
++          /* All done.  */
++          fesetenv_register (fe);
++          return x * b;
++        }
++    }
++  else if (b < 0)
++    {
++      /* For some reason, some PowerPC32 processors don't implement
++         FE_INVALID_SQRT.  */
++#ifdef FE_INVALID_SQRT
++      feraiseexcept (FE_INVALID_SQRT);
++
++      fenv_union_t u = { .fenv = fegetenv_register () };
++      if ((u.l & FE_INVALID) == 0)
++#endif
++	feraiseexcept (FE_INVALID);
++      b = a_nan.value;
++    }
++  return f_washf (b);
++}
+diff --git a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
+new file mode 100644
+index 0000000000..71e516d1c8
+--- /dev/null
++++ b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
+@@ -0,0 +1,134 @@
++/* Double-precision floating point square root.
++   Copyright (C) 2010 Free Software Foundation, Inc.
++   This file is part of the GNU C Library.
++
++   The GNU C Library is free software; you can redistribute it and/or
++   modify it under the terms of the GNU Lesser General Public
++   License as published by the Free Software Foundation; either
++   version 2.1 of the License, or (at your option) any later version.
++
++   The GNU C Library is distributed in the hope that it will be useful,
++   but WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   Lesser General Public License for more details.
++
++   You should have received a copy of the GNU Lesser General Public
++   License along with the GNU C Library; if not, write to the Free
++   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
++   02111-1307 USA.  */
++
++#include <math.h>
++#include <math_private.h>
++#include <fenv_libc.h>
++#include <inttypes.h>
++
++#include <sysdep.h>
++#include <ldsodefs.h>
++
++static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
++static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
++static const float two108 = 3.245185536584267269e+32;
++static const float twom54 = 5.551115123125782702e-17;
++static const float half = 0.5;
++
++/* The method is based on the descriptions in:
++
++   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
++   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
++
++   We find the actual square root and half of its reciprocal
++   simultaneously.  */
++
++#ifdef __STDC__
++double
++__ieee754_sqrt (double b)
++#else
++double
++__ieee754_sqrt (b)
++     double b;
++#endif
++{
++  if (__builtin_expect (b > 0, 1))
++    {
++      double y, g, h, d, r;
++      ieee_double_shape_type u;
++
++      if (__builtin_expect (b != a_inf.value, 1))
++        {
++          fenv_t fe;
++
++          fe = fegetenv_register ();
++
++          u.value = b;
++
++          relax_fenv_state ();
++
++          __asm__ ("frsqrte %[estimate], %[x]\n"
++                   : [estimate] "=f" (y) : [x] "f" (b));
++
++          /* Following Muller et al, page 168, equation 5.20.
++
++             h goes to 1/(2*sqrt(b))
++             g goes to sqrt(b).
++
++             We need three iterations to get within 1ulp.  */
++
++          /* Indicate that these can be performed prior to the branch.  GCC
++             insists on sinking them below the branch, however; it seems like
++             they'd be better before the branch so that we can cover any latency
++             from storing the argument and loading its high word.  Oh well.  */
++
++          g = b * y;
++          h = 0.5 * y;
++
++          /* Handle small numbers by scaling.  */
++          if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
++            return __ieee754_sqrt (b * two108) * twom54;
++
++#define FMADD(a_, c_, b_)                                               \
++          ({ double __r;                                                \
++          __asm__ ("fmadd %[r], %[a], %[c], %[b]\n"                     \
++                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++          __r;})
++#define FNMSUB(a_, c_, b_)                                          \
++          ({ double __r;                                                \
++          __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                     \
++                   : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++          __r;})
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          r = FNMSUB (g, h, half);
++          g = FMADD (g, r, g);
++          h = FMADD (h, r, h);
++
++          /* g is now +/- 1ulp, or exactly equal to, the square root of b.  */
++
++          /* Final refinement.  */
++          d = FNMSUB (g, g, b);
++
++          fesetenv_register (fe);
++          return FMADD (d, h, g);
++        }
++    }
++  else if (b < 0)
++    {
++      /* For some reason, some PowerPC32 processors don't implement
++         FE_INVALID_SQRT.  */
++#ifdef FE_INVALID_SQRT
++      feraiseexcept (FE_INVALID_SQRT);
++
++      fenv_union_t u = { .fenv = fegetenv_register () };
++      if ((u.l & FE_INVALID) == 0)
++#endif
++	feraiseexcept (FE_INVALID);
++      b = a_nan.value;
++    }
++  return f_wash (b);
++}
+diff --git a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
+new file mode 100644
+index 0000000000..26fa067abf
+--- /dev/null
++++ b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
+@@ -0,0 +1,101 @@
++/* Single-precision floating point square root.
++   Copyright (C) 2010 Free Software Foundation, Inc.
++   This file is part of the GNU C Library.
++
++   The GNU C Library is free software; you can redistribute it and/or
++   modify it under the terms of the GNU Lesser General Public
++   License as published by the Free Software Foundation; either
++   version 2.1 of the License, or (at your option) any later version.
++
++   The GNU C Library is distributed in the hope that it will be useful,
++   but WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   Lesser General Public License for more details.
++
++   You should have received a copy of the GNU Lesser General Public
++   License along with the GNU C Library; if not, write to the Free
++   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
++   02111-1307 USA.  */
++
++#include <math.h>
++#include <math_private.h>
++#include <fenv_libc.h>
++#include <inttypes.h>
++
++#include <sysdep.h>
++#include <ldsodefs.h>
++
++static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
++static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
++static const float threehalf = 1.5;
++
++/* The method is based on the descriptions in:
++
++   _The Handbook of Floating-Pointer Arithmetic_ by Muller et al., chapter 5;
++   _IA-64 and Elementary Functions: Speed and Precision_ by Markstein, chapter 9
++
++   We find the reciprocal square root and use that to compute the actual
++   square root.  */
++
++#ifdef __STDC__
++float
++__ieee754_sqrtf (float b)
++#else
++float
++__ieee754_sqrtf (b)
++     float b;
++#endif
++{
++  if (__builtin_expect (b > 0, 1))
++    {
++#define FMSUB(a_, c_, b_)                                               \
++      ({ double __r;                                                    \
++        __asm__ ("fmsub %[r], %[a], %[c], %[b]\n"                       \
++                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++        __r;})
++#define FNMSUB(a_, c_, b_)                                              \
++      ({ double __r;                                                    \
++        __asm__ ("fnmsub %[r], %[a], %[c], %[b]\n"                      \
++                 : [r] "=f" (__r) : [a] "f" (a_), [c] "f" (c_), [b] "f" (b_)); \
++        __r;})
++
++      if (__builtin_expect (b != a_inf.value, 1))
++        {
++          double y, x;
++          fenv_t fe;
++
++          fe = fegetenv_register ();
++
++          relax_fenv_state ();
++
++          /* Compute y = 1.5 * b - b.  Uses fewer constants than y = 0.5 * b.  */
++          y = FMSUB (threehalf, b, b);
++
++          /* Initial estimate.  */
++          __asm__ ("frsqrte %[x], %[b]\n" : [x] "=f" (x) : [b] "f" (b));
++
++          /* Iterate.  x_{n+1} = x_n * (1.5 - y * (x_n * x_n)).  */
++          x = x * FNMSUB (y, x * x, threehalf);
++          x = x * FNMSUB (y, x * x, threehalf);
++          x = x * FNMSUB (y, x * x, threehalf);
++
++          /* All done.  */
++          fesetenv_register (fe);
++          return x * b;
++        }
++    }
++  else if (b < 0)
++    {
++      /* For some reason, some PowerPC32 processors don't implement
++         FE_INVALID_SQRT.  */
++#ifdef FE_INVALID_SQRT
++      feraiseexcept (FE_INVALID_SQRT);
++
++      fenv_union_t u = { .fenv = fegetenv_register () };
++      if ((u.l & FE_INVALID) == 0)
++#endif
++	feraiseexcept (FE_INVALID);
++      b = a_nan.value;
++    }
++  return f_washf (b);
++}
+diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/603e/fpu/Implies b/sysdeps/unix/sysv/linux/powerpc/powerpc32/603e/fpu/Implies
+new file mode 100644
+index 0000000000..b103b4dea5
+--- /dev/null
++++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/603e/fpu/Implies
+@@ -0,0 +1 @@
++powerpc/powerpc32/603e/fpu
+diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/e300c3/fpu/Implies b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e300c3/fpu/Implies
+new file mode 100644
+index 0000000000..64db17fada
+--- /dev/null
++++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e300c3/fpu/Implies
+@@ -0,0 +1,2 @@
++# e300c3 is a variant of 603e so use the same optimizations for sqrt
++powerpc/powerpc32/603e/fpu
+diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500mc/fpu/Implies b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500mc/fpu/Implies
+new file mode 100644
+index 0000000000..7eac5fcf02
+--- /dev/null
++++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500mc/fpu/Implies
+@@ -0,0 +1 @@
++powerpc/powerpc32/e500mc/fpu
+diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/e5500/fpu/Implies b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e5500/fpu/Implies
+new file mode 100644
+index 0000000000..264b2a7700
+--- /dev/null
++++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e5500/fpu/Implies
+@@ -0,0 +1 @@
++powerpc/powerpc32/e5500/fpu
+diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/e6500/fpu/Implies b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e6500/fpu/Implies
+new file mode 100644
+index 0000000000..a25934467b
+--- /dev/null
++++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/e6500/fpu/Implies
+@@ -0,0 +1 @@
++powerpc/powerpc32/e6500/fpu
+diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/e5500/fpu/Implies b/sysdeps/unix/sysv/linux/powerpc/powerpc64/e5500/fpu/Implies
+new file mode 100644
+index 0000000000..a7bc854be8
+--- /dev/null
++++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/e5500/fpu/Implies
+@@ -0,0 +1 @@
++powerpc/powerpc64/e5500/fpu
+diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/e6500/fpu/Implies b/sysdeps/unix/sysv/linux/powerpc/powerpc64/e6500/fpu/Implies
+new file mode 100644
+index 0000000000..04ff8cc181
+--- /dev/null
++++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/e6500/fpu/Implies
+@@ -0,0 +1 @@
++powerpc/powerpc64/e6500/fpu
diff --git a/poky/meta/recipes-core/glibc/glibc/0006-readlib-Add-OECORE_KNOWN_INTERPRETER_NAMES-to-known-.patch b/poky/meta/recipes-core/glibc/glibc/0006-readlib-Add-OECORE_KNOWN_INTERPRETER_NAMES-to-known-.patch
deleted file mode 100644
index a3d50fd..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0006-readlib-Add-OECORE_KNOWN_INTERPRETER_NAMES-to-known-.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 615598fcca64461a71d84f756d75374f02d914ad Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 18 Mar 2015 00:11:22 +0000
-Subject: [PATCH 06/27] readlib: Add OECORE_KNOWN_INTERPRETER_NAMES to known
- names
-
-This bolts in a hook for OE to pass its own version of interpreter
-names into glibc especially for multilib case, where it differs from any
-other distros
-
-Upstream-Status: Inappropriate [OE specific]
-
-Signed-off-by: Lianhao Lu <lianhao.lu@intel.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- elf/readlib.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/elf/readlib.c b/elf/readlib.c
-index 573c01476c..d8c7412287 100644
---- a/elf/readlib.c
-+++ b/elf/readlib.c
-@@ -51,6 +51,7 @@ static struct known_names interpreters[] =
- #ifdef SYSDEP_KNOWN_INTERPRETER_NAMES
-   SYSDEP_KNOWN_INTERPRETER_NAMES
- #endif
-+  OECORE_KNOWN_INTERPRETER_NAMES
- };
- 
- static struct known_names known_libs[] =
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0007-ppc-sqrt-Fix-undefined-reference-to-__sqrt_finite.patch b/poky/meta/recipes-core/glibc/glibc/0007-ppc-sqrt-Fix-undefined-reference-to-__sqrt_finite.patch
deleted file mode 100644
index 1234df0..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0007-ppc-sqrt-Fix-undefined-reference-to-__sqrt_finite.patch
+++ /dev/null
@@ -1,208 +0,0 @@
-From 804b73ae295bdfda29341e89f2d0c1b99492dc9a Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 18 Mar 2015 00:15:07 +0000
-Subject: [PATCH 07/27] ppc/sqrt: Fix undefined reference to `__sqrt_finite'
-
-on ppc fixes the errors like below
-| ./.libs/libpulsecore-1.1.so: undefined reference to `__sqrt_finite'
-| collect2: ld returned 1 exit status
-
-Upstream-Status: Pending
-
-ChangeLog
-
-2012-01-06  Khem Raj  <raj.khem@gmail.com>
-
-        * sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c: Add __*_finite alias.
-        Remove cruft.
-        * sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c: Ditto.
-        * sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c: Ditto.
-        * sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c: Ditto.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c    | 7 +------
- sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c   | 7 +------
- sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c  | 1 +
- sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c | 1 +
- sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c   | 1 +
- sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c  | 1 +
- sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c   | 1 +
- sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c  | 1 +
- sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c   | 7 +------
- sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c  | 7 +------
- sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c   | 1 +
- sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c  | 1 +
- 12 files changed, 12 insertions(+), 24 deletions(-)
-
-diff --git a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
-index 71e516d1c8..1795fd6c3e 100644
---- a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
-+++ b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
-@@ -39,14 +39,8 @@ static const float half = 0.5;
-    We find the actual square root and half of its reciprocal
-    simultaneously.  */
- 
--#ifdef __STDC__
- double
- __ieee754_sqrt (double b)
--#else
--double
--__ieee754_sqrt (b)
--     double b;
--#endif
- {
-   if (__builtin_expect (b > 0, 1))
-     {
-@@ -132,3 +126,4 @@ __ieee754_sqrt (b)
-     }
-   return f_wash (b);
- }
-+strong_alias (__ieee754_sqrt, __sqrt_finite)
-diff --git a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
-index 26fa067abf..a917f313ab 100644
---- a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
-+++ b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
-@@ -37,14 +37,8 @@ static const float threehalf = 1.5;
-    We find the reciprocal square root and use that to compute the actual
-    square root.  */
- 
--#ifdef __STDC__
- float
- __ieee754_sqrtf (float b)
--#else
--float
--__ieee754_sqrtf (b)
--     float b;
--#endif
- {
-   if (__builtin_expect (b > 0, 1))
-     {
-@@ -99,3 +93,4 @@ __ieee754_sqrtf (b)
-     }
-   return f_washf (b);
- }
-+strong_alias (__ieee754_sqrtf, __sqrtf_finite)
-diff --git a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
-index 71e516d1c8..fc4a74990e 100644
---- a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
-+++ b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
-@@ -132,3 +132,4 @@ __ieee754_sqrt (b)
-     }
-   return f_wash (b);
- }
-+strong_alias (__ieee754_sqrt, __sqrt_finite)
-diff --git a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
-index 26fa067abf..9d175122a8 100644
---- a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
-+++ b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
-@@ -99,3 +99,4 @@ __ieee754_sqrtf (b)
-     }
-   return f_washf (b);
- }
-+strong_alias (__ieee754_sqrtf, __sqrtf_finite)
-diff --git a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
-index 71e516d1c8..fc4a74990e 100644
---- a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
-+++ b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
-@@ -132,3 +132,4 @@ __ieee754_sqrt (b)
-     }
-   return f_wash (b);
- }
-+strong_alias (__ieee754_sqrt, __sqrt_finite)
-diff --git a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
-index 26fa067abf..9d175122a8 100644
---- a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
-+++ b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
-@@ -99,3 +99,4 @@ __ieee754_sqrtf (b)
-     }
-   return f_washf (b);
- }
-+strong_alias (__ieee754_sqrtf, __sqrtf_finite)
-diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
-index 71e516d1c8..fc4a74990e 100644
---- a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
-+++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
-@@ -132,3 +132,4 @@ __ieee754_sqrt (b)
-     }
-   return f_wash (b);
- }
-+strong_alias (__ieee754_sqrt, __sqrt_finite)
-diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
-index 26fa067abf..9d175122a8 100644
---- a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
-+++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
-@@ -99,3 +99,4 @@ __ieee754_sqrtf (b)
-     }
-   return f_washf (b);
- }
-+strong_alias (__ieee754_sqrtf, __sqrtf_finite)
-diff --git a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
-index 71e516d1c8..1795fd6c3e 100644
---- a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
-+++ b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
-@@ -39,14 +39,8 @@ static const float half = 0.5;
-    We find the actual square root and half of its reciprocal
-    simultaneously.  */
- 
--#ifdef __STDC__
- double
- __ieee754_sqrt (double b)
--#else
--double
--__ieee754_sqrt (b)
--     double b;
--#endif
- {
-   if (__builtin_expect (b > 0, 1))
-     {
-@@ -132,3 +126,4 @@ __ieee754_sqrt (b)
-     }
-   return f_wash (b);
- }
-+strong_alias (__ieee754_sqrt, __sqrt_finite)
-diff --git a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
-index 26fa067abf..a917f313ab 100644
---- a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
-+++ b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
-@@ -37,14 +37,8 @@ static const float threehalf = 1.5;
-    We find the reciprocal square root and use that to compute the actual
-    square root.  */
- 
--#ifdef __STDC__
- float
- __ieee754_sqrtf (float b)
--#else
--float
--__ieee754_sqrtf (b)
--     float b;
--#endif
- {
-   if (__builtin_expect (b > 0, 1))
-     {
-@@ -99,3 +93,4 @@ __ieee754_sqrtf (b)
-     }
-   return f_washf (b);
- }
-+strong_alias (__ieee754_sqrtf, __sqrtf_finite)
-diff --git a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
-index 71e516d1c8..fc4a74990e 100644
---- a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
-+++ b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
-@@ -132,3 +132,4 @@ __ieee754_sqrt (b)
-     }
-   return f_wash (b);
- }
-+strong_alias (__ieee754_sqrt, __sqrt_finite)
-diff --git a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
-index 26fa067abf..9d175122a8 100644
---- a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
-+++ b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
-@@ -99,3 +99,4 @@ __ieee754_sqrtf (b)
-     }
-   return f_washf (b);
- }
-+strong_alias (__ieee754_sqrtf, __sqrtf_finite)
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0007-readlib-Add-OECORE_KNOWN_INTERPRETER_NAMES-to-known-.patch b/poky/meta/recipes-core/glibc/glibc/0007-readlib-Add-OECORE_KNOWN_INTERPRETER_NAMES-to-known-.patch
new file mode 100644
index 0000000..4871346
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0007-readlib-Add-OECORE_KNOWN_INTERPRETER_NAMES-to-known-.patch
@@ -0,0 +1,29 @@
+From d65f6ee214d7d91445fceabc6a5d6bf55b0e8d4b Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 18 Mar 2015 00:11:22 +0000
+Subject: [PATCH] readlib: Add OECORE_KNOWN_INTERPRETER_NAMES to known names
+
+This bolts in a hook for OE to pass its own version of interpreter
+names into glibc especially for multilib case, where it differs from any
+other distros
+
+Upstream-Status: Inappropriate [OE specific]
+
+Signed-off-by: Lianhao Lu <lianhao.lu@intel.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ elf/readlib.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/elf/readlib.c b/elf/readlib.c
+index 573c01476c..d8c7412287 100644
+--- a/elf/readlib.c
++++ b/elf/readlib.c
+@@ -51,6 +51,7 @@ static struct known_names interpreters[] =
+ #ifdef SYSDEP_KNOWN_INTERPRETER_NAMES
+   SYSDEP_KNOWN_INTERPRETER_NAMES
+ #endif
++  OECORE_KNOWN_INTERPRETER_NAMES
+ };
+ 
+ static struct known_names known_libs[] =
diff --git a/poky/meta/recipes-core/glibc/glibc/0008-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch b/poky/meta/recipes-core/glibc/glibc/0008-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch
deleted file mode 100644
index 1b43647..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0008-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch
+++ /dev/null
@@ -1,387 +0,0 @@
-From 1a53084249d9dae1ef4281246efc899c8f9d63ed Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 18 Mar 2015 00:16:38 +0000
-Subject: [PATCH 08/27] __ieee754_sqrt{,f} are now inline functions and call
- out __slow versions
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c    | 12 ++++++++++--
- sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c   |  8 +++++++-
- sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c  | 14 +++++++++++---
- sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c | 12 ++++++++++--
- sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c   | 14 +++++++++++---
- sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c  | 12 ++++++++++--
- sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c   |  8 ++++++++
- sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c  |  8 ++++++++
- sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c   | 12 ++++++++++--
- sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c  |  9 ++++++++-
- sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c   | 14 +++++++++++---
- sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c  | 12 ++++++++++--
- 12 files changed, 114 insertions(+), 21 deletions(-)
-
-diff --git a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
-index 1795fd6c3e..daa83f3fe8 100644
---- a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
-+++ b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
-@@ -40,7 +40,7 @@ static const float half = 0.5;
-    simultaneously.  */
- 
- double
--__ieee754_sqrt (double b)
-+__slow_ieee754_sqrt (double b)
- {
-   if (__builtin_expect (b > 0, 1))
-     {
-@@ -77,7 +77,7 @@ __ieee754_sqrt (double b)
- 
-           /* Handle small numbers by scaling.  */
-           if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
--            return __ieee754_sqrt (b * two108) * twom54;
-+            return __slow_ieee754_sqrt (b * two108) * twom54;
- 
- #define FMADD(a_, c_, b_)                                               \
-           ({ double __r;                                                \
-@@ -126,4 +126,12 @@ __ieee754_sqrt (double b)
-     }
-   return f_wash (b);
- }
-+
-+#undef __ieee754_sqrt
-+double
-+__ieee754_sqrt (double x)
-+{
-+   return __slow_ieee754_sqrt (x);
-+}
-+
- strong_alias (__ieee754_sqrt, __sqrt_finite)
-diff --git a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
-index a917f313ab..b812cf1705 100644
---- a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
-+++ b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
-@@ -38,7 +38,7 @@ static const float threehalf = 1.5;
-    square root.  */
- 
- float
--__ieee754_sqrtf (float b)
-+__slow_ieee754_sqrtf (float b)
- {
-   if (__builtin_expect (b > 0, 1))
-     {
-@@ -93,4 +93,10 @@ __ieee754_sqrtf (float b)
-     }
-   return f_washf (b);
- }
-+#undef __ieee754_sqrtf
-+float
-+__ieee754_sqrtf (float x)
-+{
-+  return __slow_ieee754_sqrtf (x);
-+}
- strong_alias (__ieee754_sqrtf, __sqrtf_finite)
-diff --git a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
-index fc4a74990e..7038a70b47 100644
---- a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
-+++ b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
-@@ -41,10 +41,10 @@ static const float half = 0.5;
- 
- #ifdef __STDC__
- double
--__ieee754_sqrt (double b)
-+__slow_ieee754_sqrt (double b)
- #else
- double
--__ieee754_sqrt (b)
-+__slow_ieee754_sqrt (b)
-      double b;
- #endif
- {
-@@ -83,7 +83,7 @@ __ieee754_sqrt (b)
- 
-           /* Handle small numbers by scaling.  */
-           if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
--            return __ieee754_sqrt (b * two108) * twom54;
-+            return __slow_ieee754_sqrt (b * two108) * twom54;
- 
- #define FMADD(a_, c_, b_)                                               \
-           ({ double __r;                                                \
-@@ -132,4 +132,12 @@ __ieee754_sqrt (b)
-     }
-   return f_wash (b);
- }
-+
-+#undef __ieee754_sqrt
-+double
-+__ieee754_sqrt (double x)
-+{
-+   return __slow_ieee754_sqrt (x);
-+}
-+
- strong_alias (__ieee754_sqrt, __sqrt_finite)
-diff --git a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
-index 9d175122a8..10de1f0cc3 100644
---- a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
-+++ b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
-@@ -39,10 +39,10 @@ static const float threehalf = 1.5;
- 
- #ifdef __STDC__
- float
--__ieee754_sqrtf (float b)
-+__slow_ieee754_sqrtf (float b)
- #else
- float
--__ieee754_sqrtf (b)
-+__slow_ieee754_sqrtf (b)
-      float b;
- #endif
- {
-@@ -99,4 +99,12 @@ __ieee754_sqrtf (b)
-     }
-   return f_washf (b);
- }
-+
-+#undef __ieee754_sqrtf
-+float
-+__ieee754_sqrtf (float x)
-+{
-+  return __slow_ieee754_sqrtf (x);
-+}
-+
- strong_alias (__ieee754_sqrtf, __sqrtf_finite)
-diff --git a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
-index fc4a74990e..7038a70b47 100644
---- a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
-+++ b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
-@@ -41,10 +41,10 @@ static const float half = 0.5;
- 
- #ifdef __STDC__
- double
--__ieee754_sqrt (double b)
-+__slow_ieee754_sqrt (double b)
- #else
- double
--__ieee754_sqrt (b)
-+__slow_ieee754_sqrt (b)
-      double b;
- #endif
- {
-@@ -83,7 +83,7 @@ __ieee754_sqrt (b)
- 
-           /* Handle small numbers by scaling.  */
-           if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
--            return __ieee754_sqrt (b * two108) * twom54;
-+            return __slow_ieee754_sqrt (b * two108) * twom54;
- 
- #define FMADD(a_, c_, b_)                                               \
-           ({ double __r;                                                \
-@@ -132,4 +132,12 @@ __ieee754_sqrt (b)
-     }
-   return f_wash (b);
- }
-+
-+#undef __ieee754_sqrt
-+double
-+__ieee754_sqrt (double x)
-+{
-+   return __slow_ieee754_sqrt (x);
-+}
-+
- strong_alias (__ieee754_sqrt, __sqrt_finite)
-diff --git a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
-index 9d175122a8..10de1f0cc3 100644
---- a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
-+++ b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
-@@ -39,10 +39,10 @@ static const float threehalf = 1.5;
- 
- #ifdef __STDC__
- float
--__ieee754_sqrtf (float b)
-+__slow_ieee754_sqrtf (float b)
- #else
- float
--__ieee754_sqrtf (b)
-+__slow_ieee754_sqrtf (b)
-      float b;
- #endif
- {
-@@ -99,4 +99,12 @@ __ieee754_sqrtf (b)
-     }
-   return f_washf (b);
- }
-+
-+#undef __ieee754_sqrtf
-+float
-+__ieee754_sqrtf (float x)
-+{
-+  return __slow_ieee754_sqrtf (x);
-+}
-+
- strong_alias (__ieee754_sqrtf, __sqrtf_finite)
-diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
-index fc4a74990e..1c34244bd8 100644
---- a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
-+++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
-@@ -132,4 +132,12 @@ __ieee754_sqrt (b)
-     }
-   return f_wash (b);
- }
-+
-+#undef __ieee754_sqrt
-+double
-+__ieee754_sqrt (double x)
-+{
-+   return __slow_ieee754_sqrt (x);
-+}
-+
- strong_alias (__ieee754_sqrt, __sqrt_finite)
-diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
-index 9d175122a8..812653558f 100644
---- a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
-+++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
-@@ -99,4 +99,12 @@ __ieee754_sqrtf (b)
-     }
-   return f_washf (b);
- }
-+
-+#undef __ieee754_sqrtf
-+float
-+__ieee754_sqrtf (float x)
-+{
-+  return __slow_ieee754_sqrtf (x);
-+}
-+
- strong_alias (__ieee754_sqrtf, __sqrtf_finite)
-diff --git a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
-index 1795fd6c3e..13a81973e3 100644
---- a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
-+++ b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
-@@ -40,7 +40,7 @@ static const float half = 0.5;
-    simultaneously.  */
- 
- double
--__ieee754_sqrt (double b)
-+__slow_ieee754_sqrt (double b)
- {
-   if (__builtin_expect (b > 0, 1))
-     {
-@@ -77,7 +77,7 @@ __ieee754_sqrt (double b)
- 
-           /* Handle small numbers by scaling.  */
-           if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
--            return __ieee754_sqrt (b * two108) * twom54;
-+            return __slow_ieee754_sqrt (b * two108) * twom54;
- 
- #define FMADD(a_, c_, b_)                                               \
-           ({ double __r;                                                \
-@@ -126,4 +126,12 @@ __ieee754_sqrt (double b)
-     }
-   return f_wash (b);
- }
-+
-+#undef __ieee754_sqrt
-+double
-+__ieee754_sqrt (double x)
-+{
-+  return __slow_ieee754_sqrt (x);
-+}
-+
- strong_alias (__ieee754_sqrt, __sqrt_finite)
-diff --git a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
-index a917f313ab..fae2d81210 100644
---- a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
-+++ b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
-@@ -38,7 +38,7 @@ static const float threehalf = 1.5;
-    square root.  */
- 
- float
--__ieee754_sqrtf (float b)
-+__slow_ieee754_sqrtf (float b)
- {
-   if (__builtin_expect (b > 0, 1))
-     {
-@@ -93,4 +93,11 @@ __ieee754_sqrtf (float b)
-     }
-   return f_washf (b);
- }
-+#undef __ieee754_sqrtf
-+float
-+__ieee754_sqrtf (float x)
-+{
-+  return __slow_ieee754_sqrtf (x);
-+}
-+
- strong_alias (__ieee754_sqrtf, __sqrtf_finite)
-diff --git a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
-index fc4a74990e..7038a70b47 100644
---- a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
-+++ b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
-@@ -41,10 +41,10 @@ static const float half = 0.5;
- 
- #ifdef __STDC__
- double
--__ieee754_sqrt (double b)
-+__slow_ieee754_sqrt (double b)
- #else
- double
--__ieee754_sqrt (b)
-+__slow_ieee754_sqrt (b)
-      double b;
- #endif
- {
-@@ -83,7 +83,7 @@ __ieee754_sqrt (b)
- 
-           /* Handle small numbers by scaling.  */
-           if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
--            return __ieee754_sqrt (b * two108) * twom54;
-+            return __slow_ieee754_sqrt (b * two108) * twom54;
- 
- #define FMADD(a_, c_, b_)                                               \
-           ({ double __r;                                                \
-@@ -132,4 +132,12 @@ __ieee754_sqrt (b)
-     }
-   return f_wash (b);
- }
-+
-+#undef __ieee754_sqrt
-+double
-+__ieee754_sqrt (double x)
-+{
-+   return __slow_ieee754_sqrt (x);
-+}
-+
- strong_alias (__ieee754_sqrt, __sqrt_finite)
-diff --git a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
-index 9d175122a8..10de1f0cc3 100644
---- a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
-+++ b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
-@@ -39,10 +39,10 @@ static const float threehalf = 1.5;
- 
- #ifdef __STDC__
- float
--__ieee754_sqrtf (float b)
-+__slow_ieee754_sqrtf (float b)
- #else
- float
--__ieee754_sqrtf (b)
-+__slow_ieee754_sqrtf (b)
-      float b;
- #endif
- {
-@@ -99,4 +99,12 @@ __ieee754_sqrtf (b)
-     }
-   return f_washf (b);
- }
-+
-+#undef __ieee754_sqrtf
-+float
-+__ieee754_sqrtf (float x)
-+{
-+  return __slow_ieee754_sqrtf (x);
-+}
-+
- strong_alias (__ieee754_sqrtf, __sqrtf_finite)
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0008-ppc-sqrt-Fix-undefined-reference-to-__sqrt_finite.patch b/poky/meta/recipes-core/glibc/glibc/0008-ppc-sqrt-Fix-undefined-reference-to-__sqrt_finite.patch
new file mode 100644
index 0000000..c0d96eb
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0008-ppc-sqrt-Fix-undefined-reference-to-__sqrt_finite.patch
@@ -0,0 +1,205 @@
+From ee3aa1464f40c916c62cf326bf4c18f8b71a229b Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 18 Mar 2015 00:15:07 +0000
+Subject: [PATCH] ppc/sqrt: Fix undefined reference to `__sqrt_finite'
+
+on ppc fixes the errors like below
+| ./.libs/libpulsecore-1.1.so: undefined reference to `__sqrt_finite'
+| collect2: ld returned 1 exit status
+
+Upstream-Status: Pending
+
+ChangeLog
+
+2012-01-06  Khem Raj  <raj.khem@gmail.com>
+
+        * sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c: Add __*_finite alias.
+        Remove cruft.
+        * sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c: Ditto.
+        * sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c: Ditto.
+        * sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c: Ditto.
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c    | 7 +------
+ sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c   | 7 +------
+ sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c  | 1 +
+ sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c | 1 +
+ sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c   | 1 +
+ sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c  | 1 +
+ sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c   | 1 +
+ sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c  | 1 +
+ sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c   | 7 +------
+ sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c  | 7 +------
+ sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c   | 1 +
+ sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c  | 1 +
+ 12 files changed, 12 insertions(+), 24 deletions(-)
+
+diff --git a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
+index 71e516d1c8..1795fd6c3e 100644
+--- a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
++++ b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
+@@ -39,14 +39,8 @@ static const float half = 0.5;
+    We find the actual square root and half of its reciprocal
+    simultaneously.  */
+ 
+-#ifdef __STDC__
+ double
+ __ieee754_sqrt (double b)
+-#else
+-double
+-__ieee754_sqrt (b)
+-     double b;
+-#endif
+ {
+   if (__builtin_expect (b > 0, 1))
+     {
+@@ -132,3 +126,4 @@ __ieee754_sqrt (b)
+     }
+   return f_wash (b);
+ }
++strong_alias (__ieee754_sqrt, __sqrt_finite)
+diff --git a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
+index 26fa067abf..a917f313ab 100644
+--- a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
++++ b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
+@@ -37,14 +37,8 @@ static const float threehalf = 1.5;
+    We find the reciprocal square root and use that to compute the actual
+    square root.  */
+ 
+-#ifdef __STDC__
+ float
+ __ieee754_sqrtf (float b)
+-#else
+-float
+-__ieee754_sqrtf (b)
+-     float b;
+-#endif
+ {
+   if (__builtin_expect (b > 0, 1))
+     {
+@@ -99,3 +93,4 @@ __ieee754_sqrtf (b)
+     }
+   return f_washf (b);
+ }
++strong_alias (__ieee754_sqrtf, __sqrtf_finite)
+diff --git a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
+index 71e516d1c8..fc4a74990e 100644
+--- a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
++++ b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
+@@ -132,3 +132,4 @@ __ieee754_sqrt (b)
+     }
+   return f_wash (b);
+ }
++strong_alias (__ieee754_sqrt, __sqrt_finite)
+diff --git a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
+index 26fa067abf..9d175122a8 100644
+--- a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
++++ b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
+@@ -99,3 +99,4 @@ __ieee754_sqrtf (b)
+     }
+   return f_washf (b);
+ }
++strong_alias (__ieee754_sqrtf, __sqrtf_finite)
+diff --git a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
+index 71e516d1c8..fc4a74990e 100644
+--- a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
++++ b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
+@@ -132,3 +132,4 @@ __ieee754_sqrt (b)
+     }
+   return f_wash (b);
+ }
++strong_alias (__ieee754_sqrt, __sqrt_finite)
+diff --git a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
+index 26fa067abf..9d175122a8 100644
+--- a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
++++ b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
+@@ -99,3 +99,4 @@ __ieee754_sqrtf (b)
+     }
+   return f_washf (b);
+ }
++strong_alias (__ieee754_sqrtf, __sqrtf_finite)
+diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
+index 71e516d1c8..fc4a74990e 100644
+--- a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
++++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
+@@ -132,3 +132,4 @@ __ieee754_sqrt (b)
+     }
+   return f_wash (b);
+ }
++strong_alias (__ieee754_sqrt, __sqrt_finite)
+diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
+index 26fa067abf..9d175122a8 100644
+--- a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
++++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
+@@ -99,3 +99,4 @@ __ieee754_sqrtf (b)
+     }
+   return f_washf (b);
+ }
++strong_alias (__ieee754_sqrtf, __sqrtf_finite)
+diff --git a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
+index 71e516d1c8..1795fd6c3e 100644
+--- a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
++++ b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
+@@ -39,14 +39,8 @@ static const float half = 0.5;
+    We find the actual square root and half of its reciprocal
+    simultaneously.  */
+ 
+-#ifdef __STDC__
+ double
+ __ieee754_sqrt (double b)
+-#else
+-double
+-__ieee754_sqrt (b)
+-     double b;
+-#endif
+ {
+   if (__builtin_expect (b > 0, 1))
+     {
+@@ -132,3 +126,4 @@ __ieee754_sqrt (b)
+     }
+   return f_wash (b);
+ }
++strong_alias (__ieee754_sqrt, __sqrt_finite)
+diff --git a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
+index 26fa067abf..a917f313ab 100644
+--- a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
++++ b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
+@@ -37,14 +37,8 @@ static const float threehalf = 1.5;
+    We find the reciprocal square root and use that to compute the actual
+    square root.  */
+ 
+-#ifdef __STDC__
+ float
+ __ieee754_sqrtf (float b)
+-#else
+-float
+-__ieee754_sqrtf (b)
+-     float b;
+-#endif
+ {
+   if (__builtin_expect (b > 0, 1))
+     {
+@@ -99,3 +93,4 @@ __ieee754_sqrtf (b)
+     }
+   return f_washf (b);
+ }
++strong_alias (__ieee754_sqrtf, __sqrtf_finite)
+diff --git a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
+index 71e516d1c8..fc4a74990e 100644
+--- a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
++++ b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
+@@ -132,3 +132,4 @@ __ieee754_sqrt (b)
+     }
+   return f_wash (b);
+ }
++strong_alias (__ieee754_sqrt, __sqrt_finite)
+diff --git a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
+index 26fa067abf..9d175122a8 100644
+--- a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
++++ b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
+@@ -99,3 +99,4 @@ __ieee754_sqrtf (b)
+     }
+   return f_washf (b);
+ }
++strong_alias (__ieee754_sqrtf, __sqrtf_finite)
diff --git a/poky/meta/recipes-core/glibc/glibc/0009-Quote-from-bug-1443-which-explains-what-the-patch-do.patch b/poky/meta/recipes-core/glibc/glibc/0009-Quote-from-bug-1443-which-explains-what-the-patch-do.patch
deleted file mode 100644
index ea49856..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0009-Quote-from-bug-1443-which-explains-what-the-patch-do.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-From 48262b6dda935278a40374ddf0080ab6cc999582 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 18 Mar 2015 00:20:09 +0000
-Subject: [PATCH 09/27] Quote from bug 1443 which explains what the patch does
- :
-
-  We build some random program and link it with -lust.  When we run it,
-  it dies with a SIGSEGV before reaching main().
-
-  Libust.so depends on liburcu-bp.so from the usermode-rcu package.
-  Although libust.so is not prelinked, liburcu-bp.so IS prelinked; this
-  is critical.
-
-  Libust.so uses a TLS / __thread variable that is defined in liburcu-
-  bp.so.  There are special ARM-specific relocation types that allow two
-  shared libraries to share thread-specific data.  This is critical too.
-
-  One more critical issue: although liburcu-bp.so is prelinked, we can't
-  load it at its prelinked address, because we also link against
-  librt.so, and librt.so uses that address.
-
-  The dynamic linker is forced to relink liburcu-bp.so at a different
-  address.  In the course of relinking, it processes the special ARM
-  relocation record mentioned above.  The prelinker has already filled
-  in the information, which is a short offset into a table of thread-
-  specific data that is allocated per-thread for each library that uses
-  TLS.  Because the normal behavior of a relocation is to add the symbol
-  value to an addend stored at the address being relocated, we end up
-  adding the short offset to itself, doubling it.
-
-  Now we have an awkward situation.  The libust.so library doesn't know
-  about the addend, so its TLS data for this element is correct.  The
-  liburcu-bp.so library has a different offset for the element.  When we
-  go to initialize the element for the first time in liburcu-bp.so, we
-  write the address of the result at the doubled (broken) offset.
-  Later, when we refer to the address from libust.so, we check the value
-  at the correct offset, but it's NULL, so we eat hot SIGSEGV.
-
-Upstream-Status: Pending
-
-Signed-off-by: Andrei Dinu <andrei.adrianx.dinu@intel.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- sysdeps/arm/dl-machine.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/sysdeps/arm/dl-machine.h b/sysdeps/arm/dl-machine.h
-index 8a00eab5e3..623edcb1bd 100644
---- a/sysdeps/arm/dl-machine.h
-+++ b/sysdeps/arm/dl-machine.h
-@@ -510,7 +510,7 @@ elf_machine_rel (struct link_map *map, const Elf32_Rel *reloc,
- 
- 	case R_ARM_TLS_DTPOFF32:
- 	  if (sym != NULL)
--	    *reloc_addr += sym->st_value;
-+	    *reloc_addr = sym->st_value;
- 	  break;
- 
- 	case R_ARM_TLS_TPOFF32:
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0009-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch b/poky/meta/recipes-core/glibc/glibc/0009-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch
new file mode 100644
index 0000000..d0b47cd
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0009-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch
@@ -0,0 +1,384 @@
+From 17e82d594b2d8d3a6998face953382f9d14fb046 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 18 Mar 2015 00:16:38 +0000
+Subject: [PATCH] __ieee754_sqrt{,f} are now inline functions and call out
+ __slow versions
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c    | 12 ++++++++++--
+ sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c   |  8 +++++++-
+ sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c  | 14 +++++++++++---
+ sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c | 12 ++++++++++--
+ sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c   | 14 +++++++++++---
+ sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c  | 12 ++++++++++--
+ sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c   |  8 ++++++++
+ sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c  |  8 ++++++++
+ sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c   | 12 ++++++++++--
+ sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c  |  9 ++++++++-
+ sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c   | 14 +++++++++++---
+ sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c  | 12 ++++++++++--
+ 12 files changed, 114 insertions(+), 21 deletions(-)
+
+diff --git a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
+index 1795fd6c3e..daa83f3fe8 100644
+--- a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
++++ b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrt.c
+@@ -40,7 +40,7 @@ static const float half = 0.5;
+    simultaneously.  */
+ 
+ double
+-__ieee754_sqrt (double b)
++__slow_ieee754_sqrt (double b)
+ {
+   if (__builtin_expect (b > 0, 1))
+     {
+@@ -77,7 +77,7 @@ __ieee754_sqrt (double b)
+ 
+           /* Handle small numbers by scaling.  */
+           if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
+-            return __ieee754_sqrt (b * two108) * twom54;
++            return __slow_ieee754_sqrt (b * two108) * twom54;
+ 
+ #define FMADD(a_, c_, b_)                                               \
+           ({ double __r;                                                \
+@@ -126,4 +126,12 @@ __ieee754_sqrt (double b)
+     }
+   return f_wash (b);
+ }
++
++#undef __ieee754_sqrt
++double
++__ieee754_sqrt (double x)
++{
++   return __slow_ieee754_sqrt (x);
++}
++
+ strong_alias (__ieee754_sqrt, __sqrt_finite)
+diff --git a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
+index a917f313ab..b812cf1705 100644
+--- a/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
++++ b/sysdeps/powerpc/powerpc32/603e/fpu/e_sqrtf.c
+@@ -38,7 +38,7 @@ static const float threehalf = 1.5;
+    square root.  */
+ 
+ float
+-__ieee754_sqrtf (float b)
++__slow_ieee754_sqrtf (float b)
+ {
+   if (__builtin_expect (b > 0, 1))
+     {
+@@ -93,4 +93,10 @@ __ieee754_sqrtf (float b)
+     }
+   return f_washf (b);
+ }
++#undef __ieee754_sqrtf
++float
++__ieee754_sqrtf (float x)
++{
++  return __slow_ieee754_sqrtf (x);
++}
+ strong_alias (__ieee754_sqrtf, __sqrtf_finite)
+diff --git a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
+index fc4a74990e..7038a70b47 100644
+--- a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
++++ b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrt.c
+@@ -41,10 +41,10 @@ static const float half = 0.5;
+ 
+ #ifdef __STDC__
+ double
+-__ieee754_sqrt (double b)
++__slow_ieee754_sqrt (double b)
+ #else
+ double
+-__ieee754_sqrt (b)
++__slow_ieee754_sqrt (b)
+      double b;
+ #endif
+ {
+@@ -83,7 +83,7 @@ __ieee754_sqrt (b)
+ 
+           /* Handle small numbers by scaling.  */
+           if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
+-            return __ieee754_sqrt (b * two108) * twom54;
++            return __slow_ieee754_sqrt (b * two108) * twom54;
+ 
+ #define FMADD(a_, c_, b_)                                               \
+           ({ double __r;                                                \
+@@ -132,4 +132,12 @@ __ieee754_sqrt (b)
+     }
+   return f_wash (b);
+ }
++
++#undef __ieee754_sqrt
++double
++__ieee754_sqrt (double x)
++{
++   return __slow_ieee754_sqrt (x);
++}
++
+ strong_alias (__ieee754_sqrt, __sqrt_finite)
+diff --git a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
+index 9d175122a8..10de1f0cc3 100644
+--- a/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
++++ b/sysdeps/powerpc/powerpc32/e500mc/fpu/e_sqrtf.c
+@@ -39,10 +39,10 @@ static const float threehalf = 1.5;
+ 
+ #ifdef __STDC__
+ float
+-__ieee754_sqrtf (float b)
++__slow_ieee754_sqrtf (float b)
+ #else
+ float
+-__ieee754_sqrtf (b)
++__slow_ieee754_sqrtf (b)
+      float b;
+ #endif
+ {
+@@ -99,4 +99,12 @@ __ieee754_sqrtf (b)
+     }
+   return f_washf (b);
+ }
++
++#undef __ieee754_sqrtf
++float
++__ieee754_sqrtf (float x)
++{
++  return __slow_ieee754_sqrtf (x);
++}
++
+ strong_alias (__ieee754_sqrtf, __sqrtf_finite)
+diff --git a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
+index fc4a74990e..7038a70b47 100644
+--- a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
++++ b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrt.c
+@@ -41,10 +41,10 @@ static const float half = 0.5;
+ 
+ #ifdef __STDC__
+ double
+-__ieee754_sqrt (double b)
++__slow_ieee754_sqrt (double b)
+ #else
+ double
+-__ieee754_sqrt (b)
++__slow_ieee754_sqrt (b)
+      double b;
+ #endif
+ {
+@@ -83,7 +83,7 @@ __ieee754_sqrt (b)
+ 
+           /* Handle small numbers by scaling.  */
+           if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
+-            return __ieee754_sqrt (b * two108) * twom54;
++            return __slow_ieee754_sqrt (b * two108) * twom54;
+ 
+ #define FMADD(a_, c_, b_)                                               \
+           ({ double __r;                                                \
+@@ -132,4 +132,12 @@ __ieee754_sqrt (b)
+     }
+   return f_wash (b);
+ }
++
++#undef __ieee754_sqrt
++double
++__ieee754_sqrt (double x)
++{
++   return __slow_ieee754_sqrt (x);
++}
++
+ strong_alias (__ieee754_sqrt, __sqrt_finite)
+diff --git a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
+index 9d175122a8..10de1f0cc3 100644
+--- a/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
++++ b/sysdeps/powerpc/powerpc32/e5500/fpu/e_sqrtf.c
+@@ -39,10 +39,10 @@ static const float threehalf = 1.5;
+ 
+ #ifdef __STDC__
+ float
+-__ieee754_sqrtf (float b)
++__slow_ieee754_sqrtf (float b)
+ #else
+ float
+-__ieee754_sqrtf (b)
++__slow_ieee754_sqrtf (b)
+      float b;
+ #endif
+ {
+@@ -99,4 +99,12 @@ __ieee754_sqrtf (b)
+     }
+   return f_washf (b);
+ }
++
++#undef __ieee754_sqrtf
++float
++__ieee754_sqrtf (float x)
++{
++  return __slow_ieee754_sqrtf (x);
++}
++
+ strong_alias (__ieee754_sqrtf, __sqrtf_finite)
+diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
+index fc4a74990e..1c34244bd8 100644
+--- a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
++++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
+@@ -132,4 +132,12 @@ __ieee754_sqrt (b)
+     }
+   return f_wash (b);
+ }
++
++#undef __ieee754_sqrt
++double
++__ieee754_sqrt (double x)
++{
++   return __slow_ieee754_sqrt (x);
++}
++
+ strong_alias (__ieee754_sqrt, __sqrt_finite)
+diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
+index 9d175122a8..812653558f 100644
+--- a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
++++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
+@@ -99,4 +99,12 @@ __ieee754_sqrtf (b)
+     }
+   return f_washf (b);
+ }
++
++#undef __ieee754_sqrtf
++float
++__ieee754_sqrtf (float x)
++{
++  return __slow_ieee754_sqrtf (x);
++}
++
+ strong_alias (__ieee754_sqrtf, __sqrtf_finite)
+diff --git a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
+index 1795fd6c3e..13a81973e3 100644
+--- a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
++++ b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrt.c
+@@ -40,7 +40,7 @@ static const float half = 0.5;
+    simultaneously.  */
+ 
+ double
+-__ieee754_sqrt (double b)
++__slow_ieee754_sqrt (double b)
+ {
+   if (__builtin_expect (b > 0, 1))
+     {
+@@ -77,7 +77,7 @@ __ieee754_sqrt (double b)
+ 
+           /* Handle small numbers by scaling.  */
+           if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
+-            return __ieee754_sqrt (b * two108) * twom54;
++            return __slow_ieee754_sqrt (b * two108) * twom54;
+ 
+ #define FMADD(a_, c_, b_)                                               \
+           ({ double __r;                                                \
+@@ -126,4 +126,12 @@ __ieee754_sqrt (double b)
+     }
+   return f_wash (b);
+ }
++
++#undef __ieee754_sqrt
++double
++__ieee754_sqrt (double x)
++{
++  return __slow_ieee754_sqrt (x);
++}
++
+ strong_alias (__ieee754_sqrt, __sqrt_finite)
+diff --git a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
+index a917f313ab..fae2d81210 100644
+--- a/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
++++ b/sysdeps/powerpc/powerpc64/e5500/fpu/e_sqrtf.c
+@@ -38,7 +38,7 @@ static const float threehalf = 1.5;
+    square root.  */
+ 
+ float
+-__ieee754_sqrtf (float b)
++__slow_ieee754_sqrtf (float b)
+ {
+   if (__builtin_expect (b > 0, 1))
+     {
+@@ -93,4 +93,11 @@ __ieee754_sqrtf (float b)
+     }
+   return f_washf (b);
+ }
++#undef __ieee754_sqrtf
++float
++__ieee754_sqrtf (float x)
++{
++  return __slow_ieee754_sqrtf (x);
++}
++
+ strong_alias (__ieee754_sqrtf, __sqrtf_finite)
+diff --git a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
+index fc4a74990e..7038a70b47 100644
+--- a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
++++ b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrt.c
+@@ -41,10 +41,10 @@ static const float half = 0.5;
+ 
+ #ifdef __STDC__
+ double
+-__ieee754_sqrt (double b)
++__slow_ieee754_sqrt (double b)
+ #else
+ double
+-__ieee754_sqrt (b)
++__slow_ieee754_sqrt (b)
+      double b;
+ #endif
+ {
+@@ -83,7 +83,7 @@ __ieee754_sqrt (b)
+ 
+           /* Handle small numbers by scaling.  */
+           if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
+-            return __ieee754_sqrt (b * two108) * twom54;
++            return __slow_ieee754_sqrt (b * two108) * twom54;
+ 
+ #define FMADD(a_, c_, b_)                                               \
+           ({ double __r;                                                \
+@@ -132,4 +132,12 @@ __ieee754_sqrt (b)
+     }
+   return f_wash (b);
+ }
++
++#undef __ieee754_sqrt
++double
++__ieee754_sqrt (double x)
++{
++   return __slow_ieee754_sqrt (x);
++}
++
+ strong_alias (__ieee754_sqrt, __sqrt_finite)
+diff --git a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
+index 9d175122a8..10de1f0cc3 100644
+--- a/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
++++ b/sysdeps/powerpc/powerpc64/e6500/fpu/e_sqrtf.c
+@@ -39,10 +39,10 @@ static const float threehalf = 1.5;
+ 
+ #ifdef __STDC__
+ float
+-__ieee754_sqrtf (float b)
++__slow_ieee754_sqrtf (float b)
+ #else
+ float
+-__ieee754_sqrtf (b)
++__slow_ieee754_sqrtf (b)
+      float b;
+ #endif
+ {
+@@ -99,4 +99,12 @@ __ieee754_sqrtf (b)
+     }
+   return f_washf (b);
+ }
++
++#undef __ieee754_sqrtf
++float
++__ieee754_sqrtf (float x)
++{
++  return __slow_ieee754_sqrtf (x);
++}
++
+ strong_alias (__ieee754_sqrtf, __sqrtf_finite)
diff --git a/poky/meta/recipes-core/glibc/glibc/0010-Quote-from-bug-1443-which-explains-what-the-patch-do.patch b/poky/meta/recipes-core/glibc/glibc/0010-Quote-from-bug-1443-which-explains-what-the-patch-do.patch
new file mode 100644
index 0000000..86ef3a1
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0010-Quote-from-bug-1443-which-explains-what-the-patch-do.patch
@@ -0,0 +1,58 @@
+From fe8d9b76e7c881cc0a0b728ea2bd637fafca0978 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 18 Mar 2015 00:20:09 +0000
+Subject: [PATCH] Quote from bug 1443 which explains what the patch does :
+
+  We build some random program and link it with -lust.  When we run it,
+  it dies with a SIGSEGV before reaching main().
+
+  Libust.so depends on liburcu-bp.so from the usermode-rcu package.
+  Although libust.so is not prelinked, liburcu-bp.so IS prelinked; this
+  is critical.
+
+  Libust.so uses a TLS / __thread variable that is defined in liburcu-
+  bp.so.  There are special ARM-specific relocation types that allow two
+  shared libraries to share thread-specific data.  This is critical too.
+
+  One more critical issue: although liburcu-bp.so is prelinked, we can't
+  load it at its prelinked address, because we also link against
+  librt.so, and librt.so uses that address.
+
+  The dynamic linker is forced to relink liburcu-bp.so at a different
+  address.  In the course of relinking, it processes the special ARM
+  relocation record mentioned above.  The prelinker has already filled
+  in the information, which is a short offset into a table of thread-
+  specific data that is allocated per-thread for each library that uses
+  TLS.  Because the normal behavior of a relocation is to add the symbol
+  value to an addend stored at the address being relocated, we end up
+  adding the short offset to itself, doubling it.
+
+  Now we have an awkward situation.  The libust.so library doesn't know
+  about the addend, so its TLS data for this element is correct.  The
+  liburcu-bp.so library has a different offset for the element.  When we
+  go to initialize the element for the first time in liburcu-bp.so, we
+  write the address of the result at the doubled (broken) offset.
+  Later, when we refer to the address from libust.so, we check the value
+  at the correct offset, but it's NULL, so we eat hot SIGSEGV.
+
+Upstream-Status: Pending
+
+Signed-off-by: Andrei Dinu <andrei.adrianx.dinu@intel.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ sysdeps/arm/dl-machine.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/sysdeps/arm/dl-machine.h b/sysdeps/arm/dl-machine.h
+index 1a4fd3f17b..a02c47571a 100644
+--- a/sysdeps/arm/dl-machine.h
++++ b/sysdeps/arm/dl-machine.h
+@@ -510,7 +510,7 @@ elf_machine_rel (struct link_map *map, const Elf32_Rel *reloc,
+ 
+ 	case R_ARM_TLS_DTPOFF32:
+ 	  if (sym != NULL)
+-	    *reloc_addr += sym->st_value;
++	    *reloc_addr = sym->st_value;
+ 	  break;
+ 
+ 	case R_ARM_TLS_TPOFF32:
diff --git a/poky/meta/recipes-core/glibc/glibc/0010-eglibc-run-libm-err-tab.pl-with-specific-dirs-in-S.patch b/poky/meta/recipes-core/glibc/glibc/0010-eglibc-run-libm-err-tab.pl-with-specific-dirs-in-S.patch
deleted file mode 100644
index 1751318..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0010-eglibc-run-libm-err-tab.pl-with-specific-dirs-in-S.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From 72ea5410909aef6b6aee70e7f9a88d534583aa00 Mon Sep 17 00:00:00 2001
-From: Ting Liu <b28495@freescale.com>
-Date: Wed, 19 Dec 2012 04:39:57 -0600
-Subject: [PATCH 10/27] eglibc: run libm-err-tab.pl with specific dirs in ${S}
-
-libm-err-tab.pl will parse all the files named "libm-test-ulps"
-in the given dir recursively. To avoid parsing the one in
-${S}/.pc/ (it does exist after eglibc adds aarch64 support,
-${S}/.pc/aarch64-0001-glibc-fsf-v1-eaf6f205.patch/ports/sysdeps/
-aarch64/libm-test-ulps), run libm-err-tab.pl with specific dirs
-in ${S}.
-
-Upstream-Status: inappropriate [OE specific]
-
-Signed-off-by: Ting Liu <b28495@freescale.com>
----
- manual/Makefile | 3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
-diff --git a/manual/Makefile b/manual/Makefile
-index c2756640a7..1b5bb16a96 100644
---- a/manual/Makefile
-+++ b/manual/Makefile
-@@ -102,7 +102,8 @@ $(objpfx)libm-err.texi: $(objpfx)stamp-libm-err
- $(objpfx)stamp-libm-err: libm-err-tab.pl $(wildcard $(foreach dir,$(sysdirs),\
- 						     $(dir)/libm-test-ulps))
- 	pwd=`pwd`; \
--	$(PERL) $< $$pwd/.. > $(objpfx)libm-err-tmp
-+	$(PERL) $< $$pwd/../ports > $(objpfx)libm-err-tmp
-+	$(PERL) $< $$pwd/../sysdeps >> $(objpfx)libm-err-tmp
- 	$(move-if-change) $(objpfx)libm-err-tmp $(objpfx)libm-err.texi
- 	touch $@
- 
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0011-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch b/poky/meta/recipes-core/glibc/glibc/0011-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch
deleted file mode 100644
index 1e70b2a..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0011-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch
+++ /dev/null
@@ -1,61 +0,0 @@
-From 8ae998a10b24545e0c12f1f3d8be97b191178204 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 18 Mar 2015 00:24:46 +0000
-Subject: [PATCH 11/27] __ieee754_sqrt{,f} are now inline functions and call
- out __slow versions
-
-Upstream-Status: Pending
-
-Signed-off-by: chunrong guo <B40290@freescale.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c  | 6 +++---
- sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c | 4 ++--
- 2 files changed, 5 insertions(+), 5 deletions(-)
-
-diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
-index 1c34244bd8..7038a70b47 100644
---- a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
-+++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
-@@ -41,10 +41,10 @@ static const float half = 0.5;
- 
- #ifdef __STDC__
- double
--__ieee754_sqrt (double b)
-+__slow_ieee754_sqrt (double b)
- #else
- double
--__ieee754_sqrt (b)
-+__slow_ieee754_sqrt (b)
-      double b;
- #endif
- {
-@@ -83,7 +83,7 @@ __ieee754_sqrt (b)
- 
-           /* Handle small numbers by scaling.  */
-           if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
--            return __ieee754_sqrt (b * two108) * twom54;
-+            return __slow_ieee754_sqrt (b * two108) * twom54;
- 
- #define FMADD(a_, c_, b_)                                               \
-           ({ double __r;                                                \
-diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
-index 812653558f..10de1f0cc3 100644
---- a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
-+++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
-@@ -39,10 +39,10 @@ static const float threehalf = 1.5;
- 
- #ifdef __STDC__
- float
--__ieee754_sqrtf (float b)
-+__slow_ieee754_sqrtf (float b)
- #else
- float
--__ieee754_sqrtf (b)
-+__slow_ieee754_sqrtf (b)
-      float b;
- #endif
- {
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0011-eglibc-run-libm-err-tab.pl-with-specific-dirs-in-S.patch b/poky/meta/recipes-core/glibc/glibc/0011-eglibc-run-libm-err-tab.pl-with-specific-dirs-in-S.patch
new file mode 100644
index 0000000..32aae5c
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0011-eglibc-run-libm-err-tab.pl-with-specific-dirs-in-S.patch
@@ -0,0 +1,33 @@
+From 3012cb839a64e7d5c621efa79b643d169290e6e9 Mon Sep 17 00:00:00 2001
+From: Ting Liu <b28495@freescale.com>
+Date: Wed, 19 Dec 2012 04:39:57 -0600
+Subject: [PATCH] eglibc: run libm-err-tab.pl with specific dirs in ${S}
+
+libm-err-tab.pl will parse all the files named "libm-test-ulps"
+in the given dir recursively. To avoid parsing the one in
+${S}/.pc/ (it does exist after eglibc adds aarch64 support,
+${S}/.pc/aarch64-0001-glibc-fsf-v1-eaf6f205.patch/ports/sysdeps/
+aarch64/libm-test-ulps), run libm-err-tab.pl with specific dirs
+in ${S}.
+
+Upstream-Status: inappropriate [OE specific]
+
+Signed-off-by: Ting Liu <b28495@freescale.com>
+---
+ manual/Makefile | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/manual/Makefile b/manual/Makefile
+index c2756640a7..1b5bb16a96 100644
+--- a/manual/Makefile
++++ b/manual/Makefile
+@@ -102,7 +102,8 @@ $(objpfx)libm-err.texi: $(objpfx)stamp-libm-err
+ $(objpfx)stamp-libm-err: libm-err-tab.pl $(wildcard $(foreach dir,$(sysdirs),\
+ 						     $(dir)/libm-test-ulps))
+ 	pwd=`pwd`; \
+-	$(PERL) $< $$pwd/.. > $(objpfx)libm-err-tmp
++	$(PERL) $< $$pwd/../ports > $(objpfx)libm-err-tmp
++	$(PERL) $< $$pwd/../sysdeps >> $(objpfx)libm-err-tmp
+ 	$(move-if-change) $(objpfx)libm-err-tmp $(objpfx)libm-err.texi
+ 	touch $@
+ 
diff --git a/poky/meta/recipes-core/glibc/glibc/0012-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch b/poky/meta/recipes-core/glibc/glibc/0012-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch
new file mode 100644
index 0000000..93395c3
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0012-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch
@@ -0,0 +1,58 @@
+From 93ab69ae4c98303929ba9492130a021fa4a215be Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 18 Mar 2015 00:24:46 +0000
+Subject: [PATCH] __ieee754_sqrt{,f} are now inline functions and call out
+ __slow versions
+
+Upstream-Status: Pending
+
+Signed-off-by: chunrong guo <B40290@freescale.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c  | 6 +++---
+ sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c | 4 ++--
+ 2 files changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
+index 1c34244bd8..7038a70b47 100644
+--- a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
++++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrt.c
+@@ -41,10 +41,10 @@ static const float half = 0.5;
+ 
+ #ifdef __STDC__
+ double
+-__ieee754_sqrt (double b)
++__slow_ieee754_sqrt (double b)
+ #else
+ double
+-__ieee754_sqrt (b)
++__slow_ieee754_sqrt (b)
+      double b;
+ #endif
+ {
+@@ -83,7 +83,7 @@ __ieee754_sqrt (b)
+ 
+           /* Handle small numbers by scaling.  */
+           if (__builtin_expect ((u.parts.msw & 0x7ff00000) <= 0x02000000, 0))
+-            return __ieee754_sqrt (b * two108) * twom54;
++            return __slow_ieee754_sqrt (b * two108) * twom54;
+ 
+ #define FMADD(a_, c_, b_)                                               \
+           ({ double __r;                                                \
+diff --git a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
+index 812653558f..10de1f0cc3 100644
+--- a/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
++++ b/sysdeps/powerpc/powerpc32/e6500/fpu/e_sqrtf.c
+@@ -39,10 +39,10 @@ static const float threehalf = 1.5;
+ 
+ #ifdef __STDC__
+ float
+-__ieee754_sqrtf (float b)
++__slow_ieee754_sqrtf (float b)
+ #else
+ float
+-__ieee754_sqrtf (b)
++__slow_ieee754_sqrtf (b)
+      float b;
+ #endif
+ {
diff --git a/poky/meta/recipes-core/glibc/glibc/0012-sysdeps-gnu-configure.ac-handle-correctly-libc_cv_ro.patch b/poky/meta/recipes-core/glibc/glibc/0012-sysdeps-gnu-configure.ac-handle-correctly-libc_cv_ro.patch
deleted file mode 100644
index c35b759..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0012-sysdeps-gnu-configure.ac-handle-correctly-libc_cv_ro.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From 4f9f39761909e67bd6d29b970b7165863e33e565 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 18 Mar 2015 00:27:10 +0000
-Subject: [PATCH 12/27] sysdeps/gnu/configure.ac: handle correctly
- $libc_cv_rootsbindir
-
-Upstream-Status:Pending
-
-Signed-off-by: Matthieu Crapet <Matthieu.Crapet@ingenico.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- sysdeps/gnu/configure    | 2 +-
- sysdeps/gnu/configure.ac | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/sysdeps/gnu/configure b/sysdeps/gnu/configure
-index c15d1087e8..37cc983f2a 100644
---- a/sysdeps/gnu/configure
-+++ b/sysdeps/gnu/configure
-@@ -32,6 +32,6 @@ case "$prefix" in
-   else
-     libc_cv_localstatedir=$localstatedir
-    fi
--  libc_cv_rootsbindir=/sbin
-+  test -n "$libc_cv_rootsbindir" || libc_cv_rootsbindir=/sbin
-   ;;
- esac
-diff --git a/sysdeps/gnu/configure.ac b/sysdeps/gnu/configure.ac
-index 634fe4de2a..3db1697f4f 100644
---- a/sysdeps/gnu/configure.ac
-+++ b/sysdeps/gnu/configure.ac
-@@ -21,6 +21,6 @@ case "$prefix" in
-   else
-     libc_cv_localstatedir=$localstatedir
-    fi
--  libc_cv_rootsbindir=/sbin
-+  test -n "$libc_cv_rootsbindir" || libc_cv_rootsbindir=/sbin
-   ;;
- esac
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0013-Add-unused-attribute.patch b/poky/meta/recipes-core/glibc/glibc/0013-Add-unused-attribute.patch
deleted file mode 100644
index 62c6525..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0013-Add-unused-attribute.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From bba7a647b636618d5fd083e904f995f7736b9168 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 18 Mar 2015 00:28:41 +0000
-Subject: [PATCH 13/27] Add unused attribute
-
-Helps in avoiding gcc warning when header is is included in
-a source file which does not use both functions
-
-        * iconv/gconv_charset.h (strip):
-        Add unused attribute.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- iconv/gconv_charset.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/iconv/gconv_charset.h b/iconv/gconv_charset.h
-index 123e2a62ce..63cc83ec84 100644
---- a/iconv/gconv_charset.h
-+++ b/iconv/gconv_charset.h
-@@ -21,7 +21,7 @@
- #include <locale.h>
- 
- 
--static void
-+static void __attribute__ ((unused))
- strip (char *wp, const char *s)
- {
-   int slash_count = 0;
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0013-sysdeps-gnu-configure.ac-handle-correctly-libc_cv_ro.patch b/poky/meta/recipes-core/glibc/glibc/0013-sysdeps-gnu-configure.ac-handle-correctly-libc_cv_ro.patch
new file mode 100644
index 0000000..9998691
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0013-sysdeps-gnu-configure.ac-handle-correctly-libc_cv_ro.patch
@@ -0,0 +1,39 @@
+From a7bd8aa65f3f2755d6dbd0d5adbfd269c1fb0094 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 18 Mar 2015 00:27:10 +0000
+Subject: [PATCH] sysdeps/gnu/configure.ac: handle correctly
+ $libc_cv_rootsbindir
+
+Upstream-Status:Pending
+
+Signed-off-by: Matthieu Crapet <Matthieu.Crapet@ingenico.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ sysdeps/gnu/configure    | 2 +-
+ sysdeps/gnu/configure.ac | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/sysdeps/gnu/configure b/sysdeps/gnu/configure
+index c15d1087e8..37cc983f2a 100644
+--- a/sysdeps/gnu/configure
++++ b/sysdeps/gnu/configure
+@@ -32,6 +32,6 @@ case "$prefix" in
+   else
+     libc_cv_localstatedir=$localstatedir
+    fi
+-  libc_cv_rootsbindir=/sbin
++  test -n "$libc_cv_rootsbindir" || libc_cv_rootsbindir=/sbin
+   ;;
+ esac
+diff --git a/sysdeps/gnu/configure.ac b/sysdeps/gnu/configure.ac
+index 634fe4de2a..3db1697f4f 100644
+--- a/sysdeps/gnu/configure.ac
++++ b/sysdeps/gnu/configure.ac
+@@ -21,6 +21,6 @@ case "$prefix" in
+   else
+     libc_cv_localstatedir=$localstatedir
+    fi
+-  libc_cv_rootsbindir=/sbin
++  test -n "$libc_cv_rootsbindir" || libc_cv_rootsbindir=/sbin
+   ;;
+ esac
diff --git a/poky/meta/recipes-core/glibc/glibc/0014-Add-unused-attribute.patch b/poky/meta/recipes-core/glibc/glibc/0014-Add-unused-attribute.patch
new file mode 100644
index 0000000..9d6ab30
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0014-Add-unused-attribute.patch
@@ -0,0 +1,31 @@
+From 2ce5bc6da23dcb402afdeb967fa44c39eecf6d37 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 18 Mar 2015 00:28:41 +0000
+Subject: [PATCH] Add unused attribute
+
+Helps in avoiding gcc warning when header is is included in
+a source file which does not use both functions
+
+        * iconv/gconv_charset.h (strip):
+        Add unused attribute.
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Pending
+---
+ iconv/gconv_charset.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/iconv/gconv_charset.h b/iconv/gconv_charset.h
+index 123e2a62ce..63cc83ec84 100644
+--- a/iconv/gconv_charset.h
++++ b/iconv/gconv_charset.h
+@@ -21,7 +21,7 @@
+ #include <locale.h>
+ 
+ 
+-static void
++static void __attribute__ ((unused))
+ strip (char *wp, const char *s)
+ {
+   int slash_count = 0;
diff --git a/poky/meta/recipes-core/glibc/glibc/0014-yes-within-the-path-sets-wrong-config-variables.patch b/poky/meta/recipes-core/glibc/glibc/0014-yes-within-the-path-sets-wrong-config-variables.patch
deleted file mode 100644
index 6691128..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0014-yes-within-the-path-sets-wrong-config-variables.patch
+++ /dev/null
@@ -1,263 +0,0 @@
-From 62f44ce3dd01a257cf67116e355492cb1659a917 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 18 Mar 2015 00:31:06 +0000
-Subject: [PATCH 14/27] 'yes' within the path sets wrong config variables
-
-It seems that the 'AC_EGREP_CPP(yes...' example is quite popular
-but being such a short word to grep it is likely to produce
-false-positive matches with the path it is configured into.
-
-The change is to use a more elaborated string to grep for.
-
-Upstream-Status: Submitted [libc-alpha@sourceware.org]
-
-Signed-off-by: Benjamin Esquivel <benjamin.esquivel@linux.intel.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- sysdeps/aarch64/configure                              | 4 ++--
- sysdeps/aarch64/configure.ac                           | 4 ++--
- sysdeps/arm/configure                                  | 4 ++--
- sysdeps/arm/configure.ac                               | 4 ++--
- sysdeps/mips/configure                                 | 4 ++--
- sysdeps/mips/configure.ac                              | 4 ++--
- sysdeps/nios2/configure                                | 4 ++--
- sysdeps/nios2/configure.ac                             | 4 ++--
- sysdeps/unix/sysv/linux/mips/configure                 | 4 ++--
- sysdeps/unix/sysv/linux/mips/configure.ac              | 4 ++--
- sysdeps/unix/sysv/linux/powerpc/powerpc64/configure    | 8 ++++----
- sysdeps/unix/sysv/linux/powerpc/powerpc64/configure.ac | 8 ++++----
- 12 files changed, 28 insertions(+), 28 deletions(-)
-
-diff --git a/sysdeps/aarch64/configure b/sysdeps/aarch64/configure
-index 5bd355a691..3bc5537bc0 100644
---- a/sysdeps/aarch64/configure
-+++ b/sysdeps/aarch64/configure
-@@ -148,12 +148,12 @@ else
-   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h.  */
- #ifdef __AARCH64EB__
--                      yes
-+                      is_aarch64_be
-                      #endif
- 
- _ACEOF
- if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
--  $EGREP "yes" >/dev/null 2>&1; then :
-+  $EGREP "is_aarch64_be" >/dev/null 2>&1; then :
-   libc_cv_aarch64_be=yes
- else
-   libc_cv_aarch64_be=no
-diff --git a/sysdeps/aarch64/configure.ac b/sysdeps/aarch64/configure.ac
-index 7851dd4dac..6e9238171f 100644
---- a/sysdeps/aarch64/configure.ac
-+++ b/sysdeps/aarch64/configure.ac
-@@ -10,8 +10,8 @@ GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
- # the dynamic linker via %ifdef.
- AC_CACHE_CHECK([for big endian],
-   [libc_cv_aarch64_be],
--  [AC_EGREP_CPP(yes,[#ifdef __AARCH64EB__
--                      yes
-+  [AC_EGREP_CPP(is_aarch64_be,[#ifdef __AARCH64EB__
-+                      is_aarch64_be
-                      #endif
-   ], libc_cv_aarch64_be=yes, libc_cv_aarch64_be=no)])
- if test $libc_cv_aarch64_be = yes; then
-diff --git a/sysdeps/arm/configure b/sysdeps/arm/configure
-index 431e843b2b..e152461138 100644
---- a/sysdeps/arm/configure
-+++ b/sysdeps/arm/configure
-@@ -151,12 +151,12 @@ else
-   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h.  */
- #ifdef __ARM_PCS_VFP
--		      yes
-+		      use_arm_pcs_vfp
- 		     #endif
- 
- _ACEOF
- if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
--  $EGREP "yes" >/dev/null 2>&1; then :
-+  $EGREP "use_arm_pcs_vfp" >/dev/null 2>&1; then :
-   libc_cv_arm_pcs_vfp=yes
- else
-   libc_cv_arm_pcs_vfp=no
-diff --git a/sysdeps/arm/configure.ac b/sysdeps/arm/configure.ac
-index 90cdd69c75..05a262ba00 100644
---- a/sysdeps/arm/configure.ac
-+++ b/sysdeps/arm/configure.ac
-@@ -15,8 +15,8 @@ AC_DEFINE(PI_STATIC_AND_HIDDEN)
- # the dynamic linker via %ifdef.
- AC_CACHE_CHECK([whether the compiler is using the ARM hard-float ABI],
-   [libc_cv_arm_pcs_vfp],
--  [AC_EGREP_CPP(yes,[#ifdef __ARM_PCS_VFP
--		      yes
-+  [AC_EGREP_CPP(use_arm_pcs_vfp,[#ifdef __ARM_PCS_VFP
-+		      use_arm_pcs_vfp
- 		     #endif
-   ], libc_cv_arm_pcs_vfp=yes, libc_cv_arm_pcs_vfp=no)])
- if test $libc_cv_arm_pcs_vfp = yes; then
-diff --git a/sysdeps/mips/configure b/sysdeps/mips/configure
-index 4e13248c03..f14af952d0 100644
---- a/sysdeps/mips/configure
-+++ b/sysdeps/mips/configure
-@@ -143,11 +143,11 @@ else
- /* end confdefs.h.  */
- dnl
- #ifdef __mips_nan2008
--yes
-+use_mips_nan2008
- #endif
- _ACEOF
- if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
--  $EGREP "yes" >/dev/null 2>&1; then :
-+  $EGREP "use_mips_nan2008" >/dev/null 2>&1; then :
-   libc_cv_mips_nan2008=yes
- else
-   libc_cv_mips_nan2008=no
-diff --git a/sysdeps/mips/configure.ac b/sysdeps/mips/configure.ac
-index bcbdaffd9f..ad3057f4cc 100644
---- a/sysdeps/mips/configure.ac
-+++ b/sysdeps/mips/configure.ac
-@@ -6,9 +6,9 @@ dnl position independent way.
- dnl AC_DEFINE(PI_STATIC_AND_HIDDEN)
- 
- AC_CACHE_CHECK([whether the compiler is using the 2008 NaN encoding],
--  libc_cv_mips_nan2008, [AC_EGREP_CPP(yes, [dnl
-+  libc_cv_mips_nan2008, [AC_EGREP_CPP(use_mips_nan2008, [dnl
- #ifdef __mips_nan2008
--yes
-+use_mips_nan2008
- #endif], libc_cv_mips_nan2008=yes, libc_cv_mips_nan2008=no)])
- if test x$libc_cv_mips_nan2008 = xyes; then
-   AC_DEFINE(HAVE_MIPS_NAN2008)
-diff --git a/sysdeps/nios2/configure b/sysdeps/nios2/configure
-index 14c8a3a014..dde3814ef2 100644
---- a/sysdeps/nios2/configure
-+++ b/sysdeps/nios2/configure
-@@ -142,12 +142,12 @@ else
-   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h.  */
- #ifdef __nios2_big_endian__
--                      yes
-+                      is_nios2_be
-                      #endif
- 
- _ACEOF
- if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
--  $EGREP "yes" >/dev/null 2>&1; then :
-+  $EGREP "is_nios2_be" >/dev/null 2>&1; then :
-   libc_cv_nios2_be=yes
- else
-   libc_cv_nios2_be=no
-diff --git a/sysdeps/nios2/configure.ac b/sysdeps/nios2/configure.ac
-index f05f43802b..dc8639902d 100644
---- a/sysdeps/nios2/configure.ac
-+++ b/sysdeps/nios2/configure.ac
-@@ -4,8 +4,8 @@ GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
- # Nios II big endian is not yet supported.
- AC_CACHE_CHECK([for big endian],
-   [libc_cv_nios2_be],
--  [AC_EGREP_CPP(yes,[#ifdef __nios2_big_endian__
--                      yes
-+  [AC_EGREP_CPP(is_nios2_be,[#ifdef __nios2_big_endian__
-+                      is_nios2_be
-                      #endif
-   ], libc_cv_nios2_be=yes, libc_cv_nios2_be=no)])
- if test $libc_cv_nios2_be = yes; then
-diff --git a/sysdeps/unix/sysv/linux/mips/configure b/sysdeps/unix/sysv/linux/mips/configure
-index 1ee7f41a36..77e38bebde 100644
---- a/sysdeps/unix/sysv/linux/mips/configure
-+++ b/sysdeps/unix/sysv/linux/mips/configure
-@@ -414,11 +414,11 @@ else
- /* end confdefs.h.  */
- dnl
- #ifdef __mips_nan2008
--yes
-+use_mips_nan2008
- #endif
- _ACEOF
- if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
--  $EGREP "yes" >/dev/null 2>&1; then :
-+  $EGREP "use_mips_nan2008" >/dev/null 2>&1; then :
-   libc_cv_mips_nan2008=yes
- else
-   libc_cv_mips_nan2008=no
-diff --git a/sysdeps/unix/sysv/linux/mips/configure.ac b/sysdeps/unix/sysv/linux/mips/configure.ac
-index 9147aa4582..7898e24738 100644
---- a/sysdeps/unix/sysv/linux/mips/configure.ac
-+++ b/sysdeps/unix/sysv/linux/mips/configure.ac
-@@ -105,9 +105,9 @@ AC_COMPILE_IFELSE(
- LIBC_CONFIG_VAR([mips-mode-switch],[${libc_mips_mode_switch}])
- 
- AC_CACHE_CHECK([whether the compiler is using the 2008 NaN encoding],
--  libc_cv_mips_nan2008, [AC_EGREP_CPP(yes, [dnl
-+  libc_cv_mips_nan2008, [AC_EGREP_CPP(use_mips_nan2008, [dnl
- #ifdef __mips_nan2008
--yes
-+use_mips_nan2008
- #endif], libc_cv_mips_nan2008=yes, libc_cv_mips_nan2008=no)])
- 
- libc_mips_nan=
-diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure b/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure
-index ae7f254da4..874519000b 100644
---- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure
-+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure
-@@ -155,12 +155,12 @@ else
-   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h.  */
- #if _CALL_ELF == 2
--                      yes
-+                      use_ppc_elfv2_abi
-                      #endif
- 
- _ACEOF
- if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
--  $EGREP "yes" >/dev/null 2>&1; then :
-+  $EGREP "use_ppc_elfv2_abi" >/dev/null 2>&1; then :
-   libc_cv_ppc64_elfv2_abi=yes
- else
-   libc_cv_ppc64_elfv2_abi=no
-@@ -188,12 +188,12 @@ else
-   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h.  */
- #ifdef _CALL_ELF
--                         yes
-+                         is_def_call_elf
-                        #endif
- 
- _ACEOF
- if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
--  $EGREP "yes" >/dev/null 2>&1; then :
-+  $EGREP "is_def_call_elf" >/dev/null 2>&1; then :
-   libc_cv_ppc64_def_call_elf=yes
- else
-   libc_cv_ppc64_def_call_elf=no
-diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure.ac b/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure.ac
-index f9cba6e15d..b21f72f1e4 100644
---- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure.ac
-+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure.ac
-@@ -6,8 +6,8 @@ LIBC_SLIBDIR_RTLDDIR([lib64], [lib64])
- # Define default-abi according to compiler flags.
- AC_CACHE_CHECK([whether the compiler is using the PowerPC64 ELFv2 ABI],
-   [libc_cv_ppc64_elfv2_abi],
--  [AC_EGREP_CPP(yes,[#if _CALL_ELF == 2
--                      yes
-+  [AC_EGREP_CPP(use_ppc_elfv2_abi,[#if _CALL_ELF == 2
-+                      use_ppc_elfv2_abi
-                      #endif
-   ], libc_cv_ppc64_elfv2_abi=yes, libc_cv_ppc64_elfv2_abi=no)])
- if test $libc_cv_ppc64_elfv2_abi = yes; then
-@@ -19,8 +19,8 @@ else
-   # Compiler that do not support ELFv2 ABI does not define _CALL_ELF
-   AC_CACHE_CHECK([whether the compiler defines _CALL_ELF],
-     [libc_cv_ppc64_def_call_elf],
--    [AC_EGREP_CPP(yes,[#ifdef _CALL_ELF
--                         yes
-+    [AC_EGREP_CPP(is_def_call_elf,[#ifdef _CALL_ELF
-+                         is_def_call_elf
-                        #endif
-     ], libc_cv_ppc64_def_call_elf=yes, libc_cv_ppc64_def_call_elf=no)])
-   if test $libc_cv_ppc64_def_call_elf = no; then
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0015-timezone-re-written-tzselect-as-posix-sh.patch b/poky/meta/recipes-core/glibc/glibc/0015-timezone-re-written-tzselect-as-posix-sh.patch
deleted file mode 100644
index 66bf4fd..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0015-timezone-re-written-tzselect-as-posix-sh.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-From ac240fb01f6470ac207968adfbe20ccc93b16f8b Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 18 Mar 2015 00:33:03 +0000
-Subject: [PATCH 15/27] timezone: re-written tzselect as posix sh
-
-To avoid the bash dependency.
-
-Upstream-Status: Pending
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- timezone/Makefile     | 2 +-
- timezone/tzselect.ksh | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/timezone/Makefile b/timezone/Makefile
-index 0194aba4a1..58e5405a05 100644
---- a/timezone/Makefile
-+++ b/timezone/Makefile
-@@ -122,7 +122,7 @@ $(testdata)/XT%: testdata/XT%
- 	cp $< $@
- 
- $(objpfx)tzselect: tzselect.ksh $(common-objpfx)config.make
--	sed -e 's|/bin/bash|$(BASH)|' \
-+	sed -e 's|/bin/bash|/bin/sh|' \
- 	    -e 's|TZDIR=[^}]*|TZDIR=$(zonedir)|' \
- 	    -e '/TZVERSION=/s|see_Makefile|"$(version)"|' \
- 	    -e '/PKGVERSION=/s|=.*|="$(PKGVERSION)"|' \
-diff --git a/timezone/tzselect.ksh b/timezone/tzselect.ksh
-index d2c3a6d1dd..089679f306 100755
---- a/timezone/tzselect.ksh
-+++ b/timezone/tzselect.ksh
-@@ -35,7 +35,7 @@ REPORT_BUGS_TO=tz@iana.org
- 
- # Specify default values for environment variables if they are unset.
- : ${AWK=awk}
--: ${TZDIR=`pwd`}
-+: ${TZDIR=$(pwd)}
- 
- # Output one argument as-is to standard output.
- # Safer than 'echo', which can mishandle '\' or leading '-'.
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0015-yes-within-the-path-sets-wrong-config-variables.patch b/poky/meta/recipes-core/glibc/glibc/0015-yes-within-the-path-sets-wrong-config-variables.patch
new file mode 100644
index 0000000..0267e7a
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0015-yes-within-the-path-sets-wrong-config-variables.patch
@@ -0,0 +1,260 @@
+From b382138c41ccf6079b44592f1e74f183ca8281bb Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 18 Mar 2015 00:31:06 +0000
+Subject: [PATCH] 'yes' within the path sets wrong config variables
+
+It seems that the 'AC_EGREP_CPP(yes...' example is quite popular
+but being such a short word to grep it is likely to produce
+false-positive matches with the path it is configured into.
+
+The change is to use a more elaborated string to grep for.
+
+Upstream-Status: Submitted [libc-alpha@sourceware.org]
+
+Signed-off-by: Benjamin Esquivel <benjamin.esquivel@linux.intel.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ sysdeps/aarch64/configure                              | 4 ++--
+ sysdeps/aarch64/configure.ac                           | 4 ++--
+ sysdeps/arm/configure                                  | 4 ++--
+ sysdeps/arm/configure.ac                               | 4 ++--
+ sysdeps/mips/configure                                 | 4 ++--
+ sysdeps/mips/configure.ac                              | 4 ++--
+ sysdeps/nios2/configure                                | 4 ++--
+ sysdeps/nios2/configure.ac                             | 4 ++--
+ sysdeps/unix/sysv/linux/mips/configure                 | 4 ++--
+ sysdeps/unix/sysv/linux/mips/configure.ac              | 4 ++--
+ sysdeps/unix/sysv/linux/powerpc/powerpc64/configure    | 8 ++++----
+ sysdeps/unix/sysv/linux/powerpc/powerpc64/configure.ac | 8 ++++----
+ 12 files changed, 28 insertions(+), 28 deletions(-)
+
+diff --git a/sysdeps/aarch64/configure b/sysdeps/aarch64/configure
+index 5bd355a691..3bc5537bc0 100644
+--- a/sysdeps/aarch64/configure
++++ b/sysdeps/aarch64/configure
+@@ -148,12 +148,12 @@ else
+   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h.  */
+ #ifdef __AARCH64EB__
+-                      yes
++                      is_aarch64_be
+                      #endif
+ 
+ _ACEOF
+ if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+-  $EGREP "yes" >/dev/null 2>&1; then :
++  $EGREP "is_aarch64_be" >/dev/null 2>&1; then :
+   libc_cv_aarch64_be=yes
+ else
+   libc_cv_aarch64_be=no
+diff --git a/sysdeps/aarch64/configure.ac b/sysdeps/aarch64/configure.ac
+index 7851dd4dac..6e9238171f 100644
+--- a/sysdeps/aarch64/configure.ac
++++ b/sysdeps/aarch64/configure.ac
+@@ -10,8 +10,8 @@ GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
+ # the dynamic linker via %ifdef.
+ AC_CACHE_CHECK([for big endian],
+   [libc_cv_aarch64_be],
+-  [AC_EGREP_CPP(yes,[#ifdef __AARCH64EB__
+-                      yes
++  [AC_EGREP_CPP(is_aarch64_be,[#ifdef __AARCH64EB__
++                      is_aarch64_be
+                      #endif
+   ], libc_cv_aarch64_be=yes, libc_cv_aarch64_be=no)])
+ if test $libc_cv_aarch64_be = yes; then
+diff --git a/sysdeps/arm/configure b/sysdeps/arm/configure
+index 431e843b2b..e152461138 100644
+--- a/sysdeps/arm/configure
++++ b/sysdeps/arm/configure
+@@ -151,12 +151,12 @@ else
+   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h.  */
+ #ifdef __ARM_PCS_VFP
+-		      yes
++		      use_arm_pcs_vfp
+ 		     #endif
+ 
+ _ACEOF
+ if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+-  $EGREP "yes" >/dev/null 2>&1; then :
++  $EGREP "use_arm_pcs_vfp" >/dev/null 2>&1; then :
+   libc_cv_arm_pcs_vfp=yes
+ else
+   libc_cv_arm_pcs_vfp=no
+diff --git a/sysdeps/arm/configure.ac b/sysdeps/arm/configure.ac
+index 90cdd69c75..05a262ba00 100644
+--- a/sysdeps/arm/configure.ac
++++ b/sysdeps/arm/configure.ac
+@@ -15,8 +15,8 @@ AC_DEFINE(PI_STATIC_AND_HIDDEN)
+ # the dynamic linker via %ifdef.
+ AC_CACHE_CHECK([whether the compiler is using the ARM hard-float ABI],
+   [libc_cv_arm_pcs_vfp],
+-  [AC_EGREP_CPP(yes,[#ifdef __ARM_PCS_VFP
+-		      yes
++  [AC_EGREP_CPP(use_arm_pcs_vfp,[#ifdef __ARM_PCS_VFP
++		      use_arm_pcs_vfp
+ 		     #endif
+   ], libc_cv_arm_pcs_vfp=yes, libc_cv_arm_pcs_vfp=no)])
+ if test $libc_cv_arm_pcs_vfp = yes; then
+diff --git a/sysdeps/mips/configure b/sysdeps/mips/configure
+index 4e13248c03..f14af952d0 100644
+--- a/sysdeps/mips/configure
++++ b/sysdeps/mips/configure
+@@ -143,11 +143,11 @@ else
+ /* end confdefs.h.  */
+ dnl
+ #ifdef __mips_nan2008
+-yes
++use_mips_nan2008
+ #endif
+ _ACEOF
+ if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+-  $EGREP "yes" >/dev/null 2>&1; then :
++  $EGREP "use_mips_nan2008" >/dev/null 2>&1; then :
+   libc_cv_mips_nan2008=yes
+ else
+   libc_cv_mips_nan2008=no
+diff --git a/sysdeps/mips/configure.ac b/sysdeps/mips/configure.ac
+index bcbdaffd9f..ad3057f4cc 100644
+--- a/sysdeps/mips/configure.ac
++++ b/sysdeps/mips/configure.ac
+@@ -6,9 +6,9 @@ dnl position independent way.
+ dnl AC_DEFINE(PI_STATIC_AND_HIDDEN)
+ 
+ AC_CACHE_CHECK([whether the compiler is using the 2008 NaN encoding],
+-  libc_cv_mips_nan2008, [AC_EGREP_CPP(yes, [dnl
++  libc_cv_mips_nan2008, [AC_EGREP_CPP(use_mips_nan2008, [dnl
+ #ifdef __mips_nan2008
+-yes
++use_mips_nan2008
+ #endif], libc_cv_mips_nan2008=yes, libc_cv_mips_nan2008=no)])
+ if test x$libc_cv_mips_nan2008 = xyes; then
+   AC_DEFINE(HAVE_MIPS_NAN2008)
+diff --git a/sysdeps/nios2/configure b/sysdeps/nios2/configure
+index 14c8a3a014..dde3814ef2 100644
+--- a/sysdeps/nios2/configure
++++ b/sysdeps/nios2/configure
+@@ -142,12 +142,12 @@ else
+   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h.  */
+ #ifdef __nios2_big_endian__
+-                      yes
++                      is_nios2_be
+                      #endif
+ 
+ _ACEOF
+ if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+-  $EGREP "yes" >/dev/null 2>&1; then :
++  $EGREP "is_nios2_be" >/dev/null 2>&1; then :
+   libc_cv_nios2_be=yes
+ else
+   libc_cv_nios2_be=no
+diff --git a/sysdeps/nios2/configure.ac b/sysdeps/nios2/configure.ac
+index f05f43802b..dc8639902d 100644
+--- a/sysdeps/nios2/configure.ac
++++ b/sysdeps/nios2/configure.ac
+@@ -4,8 +4,8 @@ GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
+ # Nios II big endian is not yet supported.
+ AC_CACHE_CHECK([for big endian],
+   [libc_cv_nios2_be],
+-  [AC_EGREP_CPP(yes,[#ifdef __nios2_big_endian__
+-                      yes
++  [AC_EGREP_CPP(is_nios2_be,[#ifdef __nios2_big_endian__
++                      is_nios2_be
+                      #endif
+   ], libc_cv_nios2_be=yes, libc_cv_nios2_be=no)])
+ if test $libc_cv_nios2_be = yes; then
+diff --git a/sysdeps/unix/sysv/linux/mips/configure b/sysdeps/unix/sysv/linux/mips/configure
+index 1ee7f41a36..77e38bebde 100644
+--- a/sysdeps/unix/sysv/linux/mips/configure
++++ b/sysdeps/unix/sysv/linux/mips/configure
+@@ -414,11 +414,11 @@ else
+ /* end confdefs.h.  */
+ dnl
+ #ifdef __mips_nan2008
+-yes
++use_mips_nan2008
+ #endif
+ _ACEOF
+ if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+-  $EGREP "yes" >/dev/null 2>&1; then :
++  $EGREP "use_mips_nan2008" >/dev/null 2>&1; then :
+   libc_cv_mips_nan2008=yes
+ else
+   libc_cv_mips_nan2008=no
+diff --git a/sysdeps/unix/sysv/linux/mips/configure.ac b/sysdeps/unix/sysv/linux/mips/configure.ac
+index 9147aa4582..7898e24738 100644
+--- a/sysdeps/unix/sysv/linux/mips/configure.ac
++++ b/sysdeps/unix/sysv/linux/mips/configure.ac
+@@ -105,9 +105,9 @@ AC_COMPILE_IFELSE(
+ LIBC_CONFIG_VAR([mips-mode-switch],[${libc_mips_mode_switch}])
+ 
+ AC_CACHE_CHECK([whether the compiler is using the 2008 NaN encoding],
+-  libc_cv_mips_nan2008, [AC_EGREP_CPP(yes, [dnl
++  libc_cv_mips_nan2008, [AC_EGREP_CPP(use_mips_nan2008, [dnl
+ #ifdef __mips_nan2008
+-yes
++use_mips_nan2008
+ #endif], libc_cv_mips_nan2008=yes, libc_cv_mips_nan2008=no)])
+ 
+ libc_mips_nan=
+diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure b/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure
+index ae7f254da4..874519000b 100644
+--- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure
++++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure
+@@ -155,12 +155,12 @@ else
+   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h.  */
+ #if _CALL_ELF == 2
+-                      yes
++                      use_ppc_elfv2_abi
+                      #endif
+ 
+ _ACEOF
+ if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+-  $EGREP "yes" >/dev/null 2>&1; then :
++  $EGREP "use_ppc_elfv2_abi" >/dev/null 2>&1; then :
+   libc_cv_ppc64_elfv2_abi=yes
+ else
+   libc_cv_ppc64_elfv2_abi=no
+@@ -188,12 +188,12 @@ else
+   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h.  */
+ #ifdef _CALL_ELF
+-                         yes
++                         is_def_call_elf
+                        #endif
+ 
+ _ACEOF
+ if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+-  $EGREP "yes" >/dev/null 2>&1; then :
++  $EGREP "is_def_call_elf" >/dev/null 2>&1; then :
+   libc_cv_ppc64_def_call_elf=yes
+ else
+   libc_cv_ppc64_def_call_elf=no
+diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure.ac b/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure.ac
+index f9cba6e15d..b21f72f1e4 100644
+--- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure.ac
++++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/configure.ac
+@@ -6,8 +6,8 @@ LIBC_SLIBDIR_RTLDDIR([lib64], [lib64])
+ # Define default-abi according to compiler flags.
+ AC_CACHE_CHECK([whether the compiler is using the PowerPC64 ELFv2 ABI],
+   [libc_cv_ppc64_elfv2_abi],
+-  [AC_EGREP_CPP(yes,[#if _CALL_ELF == 2
+-                      yes
++  [AC_EGREP_CPP(use_ppc_elfv2_abi,[#if _CALL_ELF == 2
++                      use_ppc_elfv2_abi
+                      #endif
+   ], libc_cv_ppc64_elfv2_abi=yes, libc_cv_ppc64_elfv2_abi=no)])
+ if test $libc_cv_ppc64_elfv2_abi = yes; then
+@@ -19,8 +19,8 @@ else
+   # Compiler that do not support ELFv2 ABI does not define _CALL_ELF
+   AC_CACHE_CHECK([whether the compiler defines _CALL_ELF],
+     [libc_cv_ppc64_def_call_elf],
+-    [AC_EGREP_CPP(yes,[#ifdef _CALL_ELF
+-                         yes
++    [AC_EGREP_CPP(is_def_call_elf,[#ifdef _CALL_ELF
++                         is_def_call_elf
+                        #endif
+     ], libc_cv_ppc64_def_call_elf=yes, libc_cv_ppc64_def_call_elf=no)])
+   if test $libc_cv_ppc64_def_call_elf = no; then
diff --git a/poky/meta/recipes-core/glibc/glibc/0016-Remove-bash-dependency-for-nscd-init-script.patch b/poky/meta/recipes-core/glibc/glibc/0016-Remove-bash-dependency-for-nscd-init-script.patch
deleted file mode 100644
index 0b1ee96..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0016-Remove-bash-dependency-for-nscd-init-script.patch
+++ /dev/null
@@ -1,75 +0,0 @@
-From 790b133ff2bc5b77ed8533b8999abc65ed0da02b Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 31 Dec 2015 14:33:02 -0800
-Subject: [PATCH 16/27] Remove bash dependency for nscd init script
-
-The nscd init script uses #! /bin/bash but only really uses one bashism
-(translated strings), so remove them and switch the shell to #!/bin/sh.
-
-Upstream-Status: Pending
-
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- nscd/nscd.init | 14 +++++++-------
- 1 file changed, 7 insertions(+), 7 deletions(-)
-
-diff --git a/nscd/nscd.init b/nscd/nscd.init
-index a882da7d8b..b02986ec15 100644
---- a/nscd/nscd.init
-+++ b/nscd/nscd.init
-@@ -1,4 +1,4 @@
--#!/bin/bash
-+#!/bin/sh
- #
- # nscd:		Starts the Name Switch Cache Daemon
- #
-@@ -49,7 +49,7 @@ prog=nscd
- start () {
-     [ -d /var/run/nscd ] || mkdir /var/run/nscd
-     [ -d /var/db/nscd ] || mkdir /var/db/nscd
--    echo -n $"Starting $prog: "
-+    echo -n "Starting $prog: "
-     daemon /usr/sbin/nscd
-     RETVAL=$?
-     echo
-@@ -58,7 +58,7 @@ start () {
- }
- 
- stop () {
--    echo -n $"Stopping $prog: "
-+    echo -n "Stopping $prog: "
-     /usr/sbin/nscd -K
-     RETVAL=$?
-     if [ $RETVAL -eq 0 ]; then
-@@ -67,9 +67,9 @@ stop () {
- 	# a non-privileged user
- 	rm -f /var/run/nscd/nscd.pid
- 	rm -f /var/run/nscd/socket
--       	success $"$prog shutdown"
-+	success "$prog shutdown"
-     else
--       	failure $"$prog shutdown"
-+	failure "$prog shutdown"
-     fi
-     echo
-     return $RETVAL
-@@ -103,13 +103,13 @@ case "$1" in
- 	RETVAL=$?
- 	;;
-     force-reload | reload)
--    	echo -n $"Reloading $prog: "
-+	echo -n "Reloading $prog: "
- 	killproc /usr/sbin/nscd -HUP
- 	RETVAL=$?
- 	echo
- 	;;
-     *)
--	echo $"Usage: $0 {start|stop|status|restart|reload|condrestart}"
-+	echo "Usage: $0 {start|stop|status|restart|reload|condrestart}"
- 	RETVAL=1
- 	;;
- esac
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0016-timezone-re-written-tzselect-as-posix-sh.patch b/poky/meta/recipes-core/glibc/glibc/0016-timezone-re-written-tzselect-as-posix-sh.patch
new file mode 100644
index 0000000..15453ec
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0016-timezone-re-written-tzselect-as-posix-sh.patch
@@ -0,0 +1,42 @@
+From 04fb7b93dc40c1f96ebc05d29a2f02f9e4f0d572 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 18 Mar 2015 00:33:03 +0000
+Subject: [PATCH] timezone: re-written tzselect as posix sh
+
+To avoid the bash dependency.
+
+Upstream-Status: Pending
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ timezone/Makefile     | 2 +-
+ timezone/tzselect.ksh | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/timezone/Makefile b/timezone/Makefile
+index 0194aba4a1..58e5405a05 100644
+--- a/timezone/Makefile
++++ b/timezone/Makefile
+@@ -122,7 +122,7 @@ $(testdata)/XT%: testdata/XT%
+ 	cp $< $@
+ 
+ $(objpfx)tzselect: tzselect.ksh $(common-objpfx)config.make
+-	sed -e 's|/bin/bash|$(BASH)|' \
++	sed -e 's|/bin/bash|/bin/sh|' \
+ 	    -e 's|TZDIR=[^}]*|TZDIR=$(zonedir)|' \
+ 	    -e '/TZVERSION=/s|see_Makefile|"$(version)"|' \
+ 	    -e '/PKGVERSION=/s|=.*|="$(PKGVERSION)"|' \
+diff --git a/timezone/tzselect.ksh b/timezone/tzselect.ksh
+index d2c3a6d1dd..089679f306 100755
+--- a/timezone/tzselect.ksh
++++ b/timezone/tzselect.ksh
+@@ -35,7 +35,7 @@ REPORT_BUGS_TO=tz@iana.org
+ 
+ # Specify default values for environment variables if they are unset.
+ : ${AWK=awk}
+-: ${TZDIR=`pwd`}
++: ${TZDIR=$(pwd)}
+ 
+ # Output one argument as-is to standard output.
+ # Safer than 'echo', which can mishandle '\' or leading '-'.
diff --git a/poky/meta/recipes-core/glibc/glibc/0017-Remove-bash-dependency-for-nscd-init-script.patch b/poky/meta/recipes-core/glibc/glibc/0017-Remove-bash-dependency-for-nscd-init-script.patch
new file mode 100644
index 0000000..06d2cd1
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0017-Remove-bash-dependency-for-nscd-init-script.patch
@@ -0,0 +1,72 @@
+From 7a2f244c0980a54ed74f9544ab44a7269ef12bce Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 31 Dec 2015 14:33:02 -0800
+Subject: [PATCH] Remove bash dependency for nscd init script
+
+The nscd init script uses #! /bin/bash but only really uses one bashism
+(translated strings), so remove them and switch the shell to #!/bin/sh.
+
+Upstream-Status: Pending
+
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ nscd/nscd.init | 14 +++++++-------
+ 1 file changed, 7 insertions(+), 7 deletions(-)
+
+diff --git a/nscd/nscd.init b/nscd/nscd.init
+index a882da7d8b..b02986ec15 100644
+--- a/nscd/nscd.init
++++ b/nscd/nscd.init
+@@ -1,4 +1,4 @@
+-#!/bin/bash
++#!/bin/sh
+ #
+ # nscd:		Starts the Name Switch Cache Daemon
+ #
+@@ -49,7 +49,7 @@ prog=nscd
+ start () {
+     [ -d /var/run/nscd ] || mkdir /var/run/nscd
+     [ -d /var/db/nscd ] || mkdir /var/db/nscd
+-    echo -n $"Starting $prog: "
++    echo -n "Starting $prog: "
+     daemon /usr/sbin/nscd
+     RETVAL=$?
+     echo
+@@ -58,7 +58,7 @@ start () {
+ }
+ 
+ stop () {
+-    echo -n $"Stopping $prog: "
++    echo -n "Stopping $prog: "
+     /usr/sbin/nscd -K
+     RETVAL=$?
+     if [ $RETVAL -eq 0 ]; then
+@@ -67,9 +67,9 @@ stop () {
+ 	# a non-privileged user
+ 	rm -f /var/run/nscd/nscd.pid
+ 	rm -f /var/run/nscd/socket
+-       	success $"$prog shutdown"
++	success "$prog shutdown"
+     else
+-       	failure $"$prog shutdown"
++	failure "$prog shutdown"
+     fi
+     echo
+     return $RETVAL
+@@ -103,13 +103,13 @@ case "$1" in
+ 	RETVAL=$?
+ 	;;
+     force-reload | reload)
+-    	echo -n $"Reloading $prog: "
++	echo -n "Reloading $prog: "
+ 	killproc /usr/sbin/nscd -HUP
+ 	RETVAL=$?
+ 	echo
+ 	;;
+     *)
+-	echo $"Usage: $0 {start|stop|status|restart|reload|condrestart}"
++	echo "Usage: $0 {start|stop|status|restart|reload|condrestart}"
+ 	RETVAL=1
+ 	;;
+ esac
diff --git a/poky/meta/recipes-core/glibc/glibc/0017-eglibc-Cross-building-and-testing-instructions.patch b/poky/meta/recipes-core/glibc/glibc/0017-eglibc-Cross-building-and-testing-instructions.patch
deleted file mode 100644
index fd82132..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0017-eglibc-Cross-building-and-testing-instructions.patch
+++ /dev/null
@@ -1,619 +0,0 @@
-From 897430bbb65a0f22284d7957206b5fd4efd6607f Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 18 Mar 2015 00:42:58 +0000
-Subject: [PATCH 17/27] eglibc: Cross building and testing instructions
-
-Ported from eglibc
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- GLIBC.cross-building | 383 +++++++++++++++++++++++++++++++++++++++++++++++++++
- GLIBC.cross-testing  | 205 +++++++++++++++++++++++++++
- 2 files changed, 588 insertions(+)
- create mode 100644 GLIBC.cross-building
- create mode 100644 GLIBC.cross-testing
-
-diff --git a/GLIBC.cross-building b/GLIBC.cross-building
-new file mode 100644
-index 0000000000..e6e0da1aaf
---- /dev/null
-+++ b/GLIBC.cross-building
-@@ -0,0 +1,383 @@
-+                                                        -*- mode: text -*-
-+
-+                        Cross-Compiling GLIBC
-+                  Jim Blandy <jimb@codesourcery.com>
-+
-+
-+Introduction
-+
-+Most GNU tools have a simple build procedure: you run their
-+'configure' script, and then you run 'make'.  Unfortunately, the
-+process of cross-compiling the GNU C library is quite a bit more
-+involved:
-+
-+1) Build a cross-compiler, with certain facilities disabled.
-+
-+2) Configure the C library using the compiler you built in step 1).
-+   Build a few of the C run-time object files, but not the rest of the
-+   library.  Install the library's header files and the run-time
-+   object files, and create a dummy libc.so.
-+
-+3) Build a second cross-compiler, using the header files and object
-+   files you installed in step 2.
-+
-+4) Configure, build, and install a fresh C library, using the compiler
-+   built in step 3.
-+
-+5) Build a third cross-compiler, based on the C library built in step 4.
-+
-+The reason for this complexity is that, although GCC and the GNU C
-+library are distributed separately, they are not actually independent
-+of each other: GCC requires the C library's headers and some object
-+files to compile its own libraries, while the C library depends on
-+GCC's libraries.  GLIBC includes features and bug fixes to the stock
-+GNU C library that simplify this process, but the fundamental
-+interdependency stands.
-+
-+In this document, we explain how to cross-compile an GLIBC/GCC pair
-+from source.  Our intended audience is developers who are already
-+familiar with the GNU toolchain and comfortable working with
-+cross-development tools.  While we do present a worked example to
-+accompany the explanation, for clarity's sake we do not cover many of
-+the options available to cross-toolchain users.
-+
-+
-+Preparation
-+
-+GLIBC requires recent versions of the GNU binutils, GCC, and the
-+Linux kernel.  The web page <http://www.eglibc.org/prerequisites>
-+documents the current requirements, and lists patches needed for
-+certain target architectures.  As of this writing, these build
-+instructions have been tested with binutils 2.22.51, GCC 4.6.2,
-+and Linux 3.1.
-+
-+First, let's set some variables, to simplify later commands.  We'll
-+build GLIBC and GCC for an ARM target, known to the Linux kernel
-+as 'arm', and we'll do the build on an Intel x86_64 Linux box:
-+
-+    $ build=x86_64-pc-linux-gnu
-+    $ host=$build
-+    $ target=arm-none-linux-gnueabi
-+    $ linux_arch=arm
-+
-+We're using the aforementioned versions of Binutils, GCC, and Linux:
-+
-+    $ binutilsv=binutils-2.22.51
-+    $ gccv=gcc-4.6.2
-+    $ linuxv=linux-3.1
-+
-+We're carrying out the entire process under '~/cross-build', which
-+contains unpacked source trees for binutils, gcc, and linux kernel,
-+along with GLIBC svn trunk (which can be checked-out with
-+'svn co http://www.eglibc.org/svn/trunk eglibc'):
-+
-+    $ top=$HOME/cross-build/$target
-+    $ src=$HOME/cross-build/src
-+    $ ls $src
-+    binutils-2.22.51  glibc  gcc-4.6.2  linux-3.1
-+
-+We're going to place our build directories in a subdirectory 'obj',
-+we'll install the cross-development toolchain in 'tools', and we'll
-+place our sysroot (containing files to be installed on the target
-+system) in 'sysroot':
-+
-+    $ obj=$top/obj
-+    $ tools=$top/tools
-+    $ sysroot=$top/sysroot
-+
-+
-+Binutils
-+
-+Configuring and building binutils for the target is straightforward:
-+
-+    $ mkdir -p $obj/binutils
-+    $ cd $obj/binutils
-+    $ $src/$binutilsv/configure \
-+    >     --target=$target \
-+    >     --prefix=$tools \
-+    >     --with-sysroot=$sysroot
-+    $ make
-+    $ make install
-+
-+
-+The First GCC
-+
-+For our work, we need a cross-compiler targeting an ARM Linux
-+system.  However, that configuration includes the shared library
-+'libgcc_s.so', which is compiled against the GLIBC headers (which we
-+haven't installed yet) and linked against 'libc.so' (which we haven't
-+built yet).
-+
-+Fortunately, there are configuration options for GCC which tell it not
-+to build 'libgcc_s.so'.  The '--without-headers' option is supposed to
-+take care of this, but its implementation is incomplete, so you must
-+also configure with the '--with-newlib' option.  While '--with-newlib'
-+appears to mean "Use the Newlib C library", its effect is to tell the
-+GCC build machinery, "Don't assume there is a C library available."
-+
-+We also need to disable some of the libraries that would normally be
-+built along with GCC, and specify that only the compiler for the C
-+language is needed.
-+
-+So, we create a build directory, configure, make, and install.
-+
-+    $ mkdir -p $obj/gcc1
-+    $ cd $obj/gcc1
-+    $ $src/$gccv/configure \
-+    >     --target=$target \
-+    >     --prefix=$tools \
-+    >     --without-headers --with-newlib \
-+    >     --disable-shared --disable-threads --disable-libssp \
-+    >     --disable-libgomp --disable-libmudflap --disable-libquadmath \
-+    >     --disable-decimal-float --disable-libffi \
-+    >     --enable-languages=c
-+    $ PATH=$tools/bin:$PATH make
-+    $ PATH=$tools/bin:$PATH make install
-+
-+
-+Linux Kernel Headers
-+
-+To configure GLIBC, we also need Linux kernel headers in place.
-+Fortunately, the Linux makefiles have a target that installs them for
-+us.  Since the process does modify the source tree a bit, we make a
-+copy first:
-+
-+    $ cp -r $src/$linuxv $obj/linux
-+    $ cd $obj/linux
-+
-+Now we're ready to install the headers into the sysroot:
-+
-+    $ PATH=$tools/bin:$PATH \
-+    > make headers_install \
-+    >      ARCH=$linux_arch CROSS_COMPILE=$target- \
-+    >      INSTALL_HDR_PATH=$sysroot/usr
-+
-+
-+GLIBC Headers and Preliminary Objects
-+
-+Using the cross-compiler we've just built, we can now configure GLIBC
-+well enough to install the headers and build the object files that the
-+full cross-compiler will need:
-+
-+    $ mkdir -p $obj/glibc-headers
-+    $ cd $obj/glibc-headers
-+    $ BUILD_CC=gcc \
-+    > CC=$tools/bin/$target-gcc \
-+    > CXX=$tools/bin/$target-g++ \
-+    > AR=$tools/bin/$target-ar \
-+    > RANLIB=$tools/bin/$target-ranlib \
-+    > $src/glibc/libc/configure \
-+    >     --prefix=/usr \
-+    >     --with-headers=$sysroot/usr/include \
-+    >     --build=$build \
-+    >     --host=$target \
-+    >     --disable-profile --without-gd --without-cvs \
-+    >     --enable-add-ons=nptl,libidn,../ports
-+
-+The option '--prefix=/usr' may look strange, but you should never
-+configure GLIBC with a prefix other than '/usr': in various places,
-+GLIBC's build system checks whether the prefix is '/usr', and does
-+special handling only if that is the case.  Unless you use this
-+prefix, you will get a sysroot that does not use the standard Linux
-+directory layouts and cannot be used as a basis for the root
-+filesystem on your target system compatibly with normal GLIBC
-+installations.
-+
-+The '--with-headers' option tells GLIBC where the Linux headers have
-+been installed.
-+
-+The '--enable-add-ons=nptl,libidn,../ports' option tells GLIBC to look
-+for the listed glibc add-ons. Most notably the ports add-on (located
-+just above the libc sources in the GLIBC svn tree) is required to
-+support ARM targets.
-+
-+We can now use the 'install-headers' makefile target to install the
-+headers:
-+
-+    $ make install-headers install_root=$sysroot \
-+    >                      install-bootstrap-headers=yes
-+
-+The 'install_root' variable indicates where the files should actually
-+be installed; its value is treated as the parent of the '--prefix'
-+directory we passed to the configure script, so the headers will go in
-+'$sysroot/usr/include'.  The 'install-bootstrap-headers' variable
-+requests special handling for certain tricky header files.
-+
-+Next, there are a few object files needed to link shared libraries,
-+which we build and install by hand:
-+
-+    $ mkdir -p $sysroot/usr/lib
-+    $ make csu/subdir_lib
-+    $ cp csu/crt1.o csu/crti.o csu/crtn.o $sysroot/usr/lib
-+
-+Finally, 'libgcc_s.so' requires a 'libc.so' to link against.  However,
-+since we will never actually execute its code, it doesn't matter what
-+it contains.  So, treating '/dev/null' as a C source file, we produce
-+a dummy 'libc.so' in one step:
-+
-+    $ $tools/bin/$target-gcc -nostdlib -nostartfiles -shared -x c /dev/null \
-+    >                        -o $sysroot/usr/lib/libc.so
-+
-+
-+The Second GCC
-+
-+With the GLIBC headers and selected object files installed, we can
-+now build a GCC that is capable of compiling GLIBC.  We configure,
-+build, and install the second GCC, again building only the C compiler,
-+and avoiding libraries we won't use:
-+
-+    $ mkdir -p $obj/gcc2
-+    $ cd $obj/gcc2
-+    $ $src/$gccv/configure \
-+    >     --target=$target \
-+    >     --prefix=$tools \
-+    >     --with-sysroot=$sysroot \
-+    >     --disable-libssp --disable-libgomp --disable-libmudflap \
-+    >     --disable-libffi --disable-libquadmath \
-+    >     --enable-languages=c
-+    $ PATH=$tools/bin:$PATH make
-+    $ PATH=$tools/bin:$PATH make install
-+
-+
-+GLIBC, Complete
-+
-+With the second compiler built and installed, we're now ready for the
-+full GLIBC build:
-+
-+    $ mkdir -p $obj/glibc
-+    $ cd $obj/glibc
-+    $ BUILD_CC=gcc \
-+    > CC=$tools/bin/$target-gcc \
-+    > CXX=$tools/bin/$target-g++ \
-+    > AR=$tools/bin/$target-ar \
-+    > RANLIB=$tools/bin/$target-ranlib \
-+    > $src/glibc/libc/configure \
-+    >     --prefix=/usr \
-+    >     --with-headers=$sysroot/usr/include \
-+    >     --with-kconfig=$obj/linux/scripts/kconfig \
-+    >     --build=$build \
-+    >     --host=$target \
-+    >     --disable-profile --without-gd --without-cvs \
-+    >     --enable-add-ons=nptl,libidn,../ports
-+
-+Note the additional '--with-kconfig' option. This tells GLIBC where to
-+find the host config tools used by the kernel 'make config' and 'make
-+menuconfig'.  These tools can be re-used by GLIBC for its own 'make
-+*config' support, which will create 'option-groups.config' for you.
-+But first make sure those tools have been built by running some
-+dummy 'make *config' calls in the kernel directory:
-+
-+    $ cd $obj/linux
-+    $ PATH=$tools/bin:$PATH make config \
-+    >      ARCH=$linux_arch CROSS_COMPILE=$target- \
-+    $ PATH=$tools/bin:$PATH make menuconfig \
-+    >      ARCH=$linux_arch CROSS_COMPILE=$target- \
-+
-+Now we can configure and build the full GLIBC:
-+
-+    $ cd $obj/glibc
-+    $ PATH=$tools/bin:$PATH make defconfig
-+    $ PATH=$tools/bin:$PATH make menuconfig
-+    $ PATH=$tools/bin:$PATH make
-+    $ PATH=$tools/bin:$PATH make install install_root=$sysroot
-+
-+At this point, we have a complete GLIBC installation in '$sysroot',
-+with header files, library files, and most of the C runtime startup
-+files in place.
-+
-+
-+The Third GCC
-+
-+Finally, we recompile GCC against this full installation, enabling
-+whatever languages and libraries we would like to use:
-+
-+    $ mkdir -p $obj/gcc3
-+    $ cd $obj/gcc3
-+    $ $src/$gccv/configure \
-+    >     --target=$target \
-+    >     --prefix=$tools \
-+    >     --with-sysroot=$sysroot \
-+    >     --enable-__cxa_atexit \
-+    >     --disable-libssp --disable-libgomp --disable-libmudflap \
-+    >     --enable-languages=c,c++
-+    $ PATH=$tools/bin:$PATH make
-+    $ PATH=$tools/bin:$PATH make install
-+
-+The '--enable-__cxa_atexit' option tells GCC what sort of C++
-+destructor support to expect from the C library; it's required with
-+GLIBC.
-+
-+And since GCC's installation process isn't designed to help construct
-+sysroot trees, we must manually copy certain libraries into place in
-+the sysroot.
-+
-+    $ cp -d $tools/$target/lib/libgcc_s.so* $sysroot/lib
-+    $ cp -d $tools/$target/lib/libstdc++.so* $sysroot/usr/lib
-+
-+
-+Trying Things Out
-+
-+At this point, '$tools' contains a cross toolchain ready to use
-+the GLIBC installation in '$sysroot':
-+
-+    $ cat > hello.c <<EOF
-+    > #include <stdio.h>
-+    > int
-+    > main (int argc, char **argv)
-+    > {
-+    >   puts ("Hello, world!");
-+    >   return 0;
-+    > }
-+    > EOF
-+    $ $tools/bin/$target-gcc -Wall hello.c -o hello
-+    $ cat > c++-hello.cc <<EOF
-+    > #include <iostream>
-+    > int
-+    > main (int argc, char **argv)
-+    > {
-+    >   std::cout << "Hello, C++ world!" << std::endl;
-+    >   return 0;
-+    > }
-+    > EOF
-+    $ $tools/bin/$target-g++ -Wall c++-hello.cc -o c++-hello
-+
-+
-+We can use 'readelf' to verify that these are indeed executables for
-+our target, using our dynamic linker:
-+
-+    $ $tools/bin/$target-readelf -hl hello
-+    ELF Header:
-+    ...
-+      Type:                              EXEC (Executable file)
-+      Machine:                           ARM
-+
-+    ...
-+    Program Headers:
-+      Type           Offset   VirtAddr   PhysAddr   FileSiz MemSiz  Flg Align
-+      PHDR           0x000034 0x10000034 0x10000034 0x00100 0x00100 R E 0x4
-+      INTERP         0x000134 0x00008134 0x00008134 0x00013 0x00013 R   0x1
-+          [Requesting program interpreter: /lib/ld-linux.so.3]
-+      LOAD           0x000000 0x00008000 0x00008000 0x0042c 0x0042c R E 0x8000
-+    ...
-+
-+Looking at the dynamic section of the installed 'libgcc_s.so', we see
-+that the 'NEEDED' entry for the C library does include the '.6'
-+suffix, indicating that was linked against our fully build GLIBC, and
-+not our dummy 'libc.so':
-+
-+    $ $tools/bin/$target-readelf -d $sysroot/lib/libgcc_s.so.1
-+    Dynamic section at offset 0x1083c contains 24 entries:
-+      Tag        Type                         Name/Value
-+     0x00000001 (NEEDED)                     Shared library: [libc.so.6]
-+     0x0000000e (SONAME)                     Library soname: [libgcc_s.so.1]
-+    ...
-+
-+
-+And on the target machine, we can run our programs:
-+
-+    $ $sysroot/lib/ld.so.1 --library-path $sysroot/lib:$sysroot/usr/lib \
-+    > ./hello
-+    Hello, world!
-+    $ $sysroot/lib/ld.so.1 --library-path $sysroot/lib:$sysroot/usr/lib \
-+    > ./c++-hello
-+    Hello, C++ world!
-diff --git a/GLIBC.cross-testing b/GLIBC.cross-testing
-new file mode 100644
-index 0000000000..b67b468466
---- /dev/null
-+++ b/GLIBC.cross-testing
-@@ -0,0 +1,205 @@
-+                                                        -*- mode: text -*-
-+
-+                      Cross-Testing With GLIBC
-+                  Jim Blandy <jimb@codesourcery.com>
-+
-+
-+Introduction
-+
-+Developers writing software for embedded systems often use a desktop
-+or other similarly capable computer for development, but need to run
-+tests on the embedded system, or perhaps on a simulator.  When
-+configured for cross-compilation, the stock GNU C library simply
-+disables running tests altogether: the command 'make tests' builds
-+test programs, but does not run them.  GLIBC, however, provides
-+facilities for compiling tests and generating data files on the build
-+system, but running the test programs themselves on a remote system or
-+simulator.
-+
-+
-+Test environment requirements
-+
-+The test environment must meet certain conditions for GLIBC's
-+cross-testing facilities to work:
-+
-+- Shared filesystems.  The 'build' system, on which you configure and
-+  compile GLIBC, and the 'host' system, on which you intend to run
-+  GLIBC, must share a filesystem containing the GLIBC build and
-+  source trees.  Files must appear at the same paths on both systems.
-+
-+- Remote-shell like invocation.  There must be a way to run a program
-+  on the host system from the build system, passing it properly quoted
-+  command-line arguments, setting environment variables, and
-+  inheriting the caller's standard input and output.
-+
-+
-+Usage
-+
-+To use GLIBC's cross-testing support, provide values for the
-+following Make variables when you invoke 'make':
-+
-+- cross-test-wrapper
-+
-+  This should be the name of the cross-testing wrapper command, along
-+  with any arguments.
-+
-+- cross-localedef
-+
-+  This should be the name of a cross-capable localedef program, like
-+  that included in the GLIBC 'localedef' module, along with any
-+  arguments needed.
-+
-+These are each explained in detail below.
-+
-+
-+The Cross-Testing Wrapper
-+
-+To run test programs reliably, the stock GNU C library takes care to
-+ensure that test programs use the newly compiled dynamic linker and
-+shared libraries, and never the host system's installed libraries.  To
-+accomplish this, it runs the tests by explicitly invoking the dynamic
-+linker from the build tree, passing it a list of build tree
-+directories to search for shared libraries, followed by the name of
-+the executable to run and its arguments.
-+
-+For example, where one might normally run a test program like this:
-+
-+    $ ./tst-foo arg1 arg2
-+
-+the GNU C library might run that program like this:
-+
-+    $ $objdir/elf/ld-linux.so.3 --library-path $objdir \
-+      ./tst-foo arg1 arg2
-+
-+(where $objdir is the path to the top of the build tree, and the
-+trailing backslash indicates a continuation of the command).  In other
-+words, each test program invocation is 'wrapped up' inside an explicit
-+invocation of the dynamic linker, which must itself execute the test
-+program, having loaded shared libraries from the appropriate
-+directories.
-+
-+To support cross-testing, GLIBC allows the developer to optionally
-+set the 'cross-test-wrapper' Make variable to another wrapper command,
-+to which it passes the entire dynamic linker invocation shown above as
-+arguments.  For example, if the developer supplies a wrapper of
-+'my-wrapper hostname', then GLIBC would run the test above as
-+follows:
-+
-+    $ my-wrapper hostname \
-+      $objdir/elf/ld-linux.so.3 --library-path $objdir \
-+      ./tst-foo arg1 arg2
-+
-+The 'my-wrapper' command is responsible for executing the command
-+given on the host system.
-+
-+Since tests are run in varying directories, the wrapper should either
-+be in your command search path, or 'cross-test-wrapper' should give an
-+absolute path for the wrapper.
-+
-+The wrapper must meet several requirements:
-+
-+- It must preserve the current directory.  As explained above, the
-+  build directory tree must be visible on both the build and host
-+  systems, at the same path.  The test wrapper must ensure that the
-+  current directory it inherits is also inherited by the dynamic
-+  linker (and thus the test program itself).
-+
-+- It must preserve environment variables' values.  Many GLIBC tests
-+  set environment variables for test runs; in native testing, it
-+  invokes programs like this:
-+
-+    $ GCONV_PATH=$objdir/iconvdata \
-+      $objdir/elf/ld-linux.so.3 --library-path $objdir \
-+      ./tst-foo arg1 arg2
-+
-+  With the cross-testing wrapper, that invocation becomes:
-+
-+    $ GCONV_PATH=$objdir/iconvdata \
-+      my-wrapper hostname \
-+      $objdir/elf/ld-linux.so.3 --library-path $objdir \
-+      ./tst-foo arg1 arg2
-+
-+  Here, 'my-wrapper' must ensure that the value it sees for
-+  'GCONV_PATH' will be seen by the dynamic linker, and thus 'tst-foo'
-+  itself.  (The wrapper supplied with GLIBC simply preserves the
-+  values of *all* enviroment variables, with a fixed set of
-+  exceptions.)
-+
-+  If your wrapper is a shell script, take care to correctly propagate
-+  environment variables whose values contain spaces and shell
-+  metacharacters.
-+
-+- It must pass the command's arguments, unmodified.  The arguments
-+  seen by the test program should be exactly those seen by the wrapper
-+  (after whatever arguments are given to the wrapper itself).  The
-+  GLIBC test framework performs all needed shell word splitting and
-+  expansion (wildcard expansion, parameter substitution, and so on)
-+  before invoking the wrapper; further expansion may break the tests.
-+
-+
-+The 'cross-test-ssh.sh' script
-+
-+If you want to use 'ssh' (or something sufficiently similar) to run
-+test programs on your host system, GLIBC includes a shell script,
-+'scripts/cross-test-ssh.sh', which you can use as your wrapper
-+command.  This script takes care of setting the test command's current
-+directory, propagating environment variable values, and carrying
-+command-line arguments, all across an 'ssh' connection.  You may even
-+supply an alternative to 'ssh' on the command line, if needed.
-+
-+For more details, pass 'cross-test-ssh.sh' the '--help' option.
-+
-+
-+The Cross-Compiling Locale Definition Command
-+
-+Some GLIBC tests rely on locales generated especially for the test
-+process.  In a native configuration, these tests simply run the
-+'localedef' command built by the normal GLIBC build process,
-+'locale/localedef', to process and install their locales.  However, in
-+a cross-compiling configuration, this 'localedef' is built for the
-+host system, not the build system, and since it requires quite a bit
-+of memory to run (we have seen it fail on systems with 64MiB of
-+memory), it may not be practical to run it on the host system.
-+
-+If set, GLIBC uses the 'cross-localedef' Make variable as the command
-+to run on the build system to process and install locales.  The
-+localedef program built from the GLIBC 'localedef' module is
-+suitable.
-+
-+The value of 'cross-localedef' may also include command-line arguments
-+to be passed to the program; if you are using GLIBC's 'localedef',
-+you may include endianness and 'uint32_t' alignment arguments here.
-+
-+
-+Example
-+
-+In developing GLIBC's cross-testing facility, we invoked 'make' with
-+the following script:
-+
-+    #!/bin/sh
-+
-+    srcdir=...
-+    test_hostname=...
-+    localedefdir=...
-+    cross_gxx=...-g++
-+
-+    wrapper="$srcdir/scripts/cross-test-ssh.sh $test_hostname"
-+    localedef="$localedefdir/localedef --little-endian --uint32-align=4"
-+
-+    make cross-test-wrapper="$wrapper" \
-+         cross-localedef="$localedef" \
-+         CXX="$cross_gxx" \
-+         "$@"
-+
-+
-+Other Cross-Testing Concerns
-+
-+Here are notes on some other issues which you may encounter in running
-+the GLIBC tests in a cross-compiling environment:
-+
-+- Some tests require a C++ cross-compiler; you should set the 'CXX'
-+  Make variable to the name of an appropriate cross-compiler.
-+
-+- Some tests require access to libstdc++.so.6 and libgcc_s.so.1; we
-+  simply place copies of these libraries in the top GLIBC build
-+  directory.
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0018-eglibc-Cross-building-and-testing-instructions.patch b/poky/meta/recipes-core/glibc/glibc/0018-eglibc-Cross-building-and-testing-instructions.patch
new file mode 100644
index 0000000..29109a2
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0018-eglibc-Cross-building-and-testing-instructions.patch
@@ -0,0 +1,616 @@
+From 44a5c79efea09f5b990e524ec42abdeef444056a Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 18 Mar 2015 00:42:58 +0000
+Subject: [PATCH] eglibc: Cross building and testing instructions
+
+Ported from eglibc
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ GLIBC.cross-building | 383 +++++++++++++++++++++++++++++++++++++++++++
+ GLIBC.cross-testing  | 205 +++++++++++++++++++++++
+ 2 files changed, 588 insertions(+)
+ create mode 100644 GLIBC.cross-building
+ create mode 100644 GLIBC.cross-testing
+
+diff --git a/GLIBC.cross-building b/GLIBC.cross-building
+new file mode 100644
+index 0000000000..e6e0da1aaf
+--- /dev/null
++++ b/GLIBC.cross-building
+@@ -0,0 +1,383 @@
++                                                        -*- mode: text -*-
++
++                        Cross-Compiling GLIBC
++                  Jim Blandy <jimb@codesourcery.com>
++
++
++Introduction
++
++Most GNU tools have a simple build procedure: you run their
++'configure' script, and then you run 'make'.  Unfortunately, the
++process of cross-compiling the GNU C library is quite a bit more
++involved:
++
++1) Build a cross-compiler, with certain facilities disabled.
++
++2) Configure the C library using the compiler you built in step 1).
++   Build a few of the C run-time object files, but not the rest of the
++   library.  Install the library's header files and the run-time
++   object files, and create a dummy libc.so.
++
++3) Build a second cross-compiler, using the header files and object
++   files you installed in step 2.
++
++4) Configure, build, and install a fresh C library, using the compiler
++   built in step 3.
++
++5) Build a third cross-compiler, based on the C library built in step 4.
++
++The reason for this complexity is that, although GCC and the GNU C
++library are distributed separately, they are not actually independent
++of each other: GCC requires the C library's headers and some object
++files to compile its own libraries, while the C library depends on
++GCC's libraries.  GLIBC includes features and bug fixes to the stock
++GNU C library that simplify this process, but the fundamental
++interdependency stands.
++
++In this document, we explain how to cross-compile an GLIBC/GCC pair
++from source.  Our intended audience is developers who are already
++familiar with the GNU toolchain and comfortable working with
++cross-development tools.  While we do present a worked example to
++accompany the explanation, for clarity's sake we do not cover many of
++the options available to cross-toolchain users.
++
++
++Preparation
++
++GLIBC requires recent versions of the GNU binutils, GCC, and the
++Linux kernel.  The web page <http://www.eglibc.org/prerequisites>
++documents the current requirements, and lists patches needed for
++certain target architectures.  As of this writing, these build
++instructions have been tested with binutils 2.22.51, GCC 4.6.2,
++and Linux 3.1.
++
++First, let's set some variables, to simplify later commands.  We'll
++build GLIBC and GCC for an ARM target, known to the Linux kernel
++as 'arm', and we'll do the build on an Intel x86_64 Linux box:
++
++    $ build=x86_64-pc-linux-gnu
++    $ host=$build
++    $ target=arm-none-linux-gnueabi
++    $ linux_arch=arm
++
++We're using the aforementioned versions of Binutils, GCC, and Linux:
++
++    $ binutilsv=binutils-2.22.51
++    $ gccv=gcc-4.6.2
++    $ linuxv=linux-3.1
++
++We're carrying out the entire process under '~/cross-build', which
++contains unpacked source trees for binutils, gcc, and linux kernel,
++along with GLIBC svn trunk (which can be checked-out with
++'svn co http://www.eglibc.org/svn/trunk eglibc'):
++
++    $ top=$HOME/cross-build/$target
++    $ src=$HOME/cross-build/src
++    $ ls $src
++    binutils-2.22.51  glibc  gcc-4.6.2  linux-3.1
++
++We're going to place our build directories in a subdirectory 'obj',
++we'll install the cross-development toolchain in 'tools', and we'll
++place our sysroot (containing files to be installed on the target
++system) in 'sysroot':
++
++    $ obj=$top/obj
++    $ tools=$top/tools
++    $ sysroot=$top/sysroot
++
++
++Binutils
++
++Configuring and building binutils for the target is straightforward:
++
++    $ mkdir -p $obj/binutils
++    $ cd $obj/binutils
++    $ $src/$binutilsv/configure \
++    >     --target=$target \
++    >     --prefix=$tools \
++    >     --with-sysroot=$sysroot
++    $ make
++    $ make install
++
++
++The First GCC
++
++For our work, we need a cross-compiler targeting an ARM Linux
++system.  However, that configuration includes the shared library
++'libgcc_s.so', which is compiled against the GLIBC headers (which we
++haven't installed yet) and linked against 'libc.so' (which we haven't
++built yet).
++
++Fortunately, there are configuration options for GCC which tell it not
++to build 'libgcc_s.so'.  The '--without-headers' option is supposed to
++take care of this, but its implementation is incomplete, so you must
++also configure with the '--with-newlib' option.  While '--with-newlib'
++appears to mean "Use the Newlib C library", its effect is to tell the
++GCC build machinery, "Don't assume there is a C library available."
++
++We also need to disable some of the libraries that would normally be
++built along with GCC, and specify that only the compiler for the C
++language is needed.
++
++So, we create a build directory, configure, make, and install.
++
++    $ mkdir -p $obj/gcc1
++    $ cd $obj/gcc1
++    $ $src/$gccv/configure \
++    >     --target=$target \
++    >     --prefix=$tools \
++    >     --without-headers --with-newlib \
++    >     --disable-shared --disable-threads --disable-libssp \
++    >     --disable-libgomp --disable-libmudflap --disable-libquadmath \
++    >     --disable-decimal-float --disable-libffi \
++    >     --enable-languages=c
++    $ PATH=$tools/bin:$PATH make
++    $ PATH=$tools/bin:$PATH make install
++
++
++Linux Kernel Headers
++
++To configure GLIBC, we also need Linux kernel headers in place.
++Fortunately, the Linux makefiles have a target that installs them for
++us.  Since the process does modify the source tree a bit, we make a
++copy first:
++
++    $ cp -r $src/$linuxv $obj/linux
++    $ cd $obj/linux
++
++Now we're ready to install the headers into the sysroot:
++
++    $ PATH=$tools/bin:$PATH \
++    > make headers_install \
++    >      ARCH=$linux_arch CROSS_COMPILE=$target- \
++    >      INSTALL_HDR_PATH=$sysroot/usr
++
++
++GLIBC Headers and Preliminary Objects
++
++Using the cross-compiler we've just built, we can now configure GLIBC
++well enough to install the headers and build the object files that the
++full cross-compiler will need:
++
++    $ mkdir -p $obj/glibc-headers
++    $ cd $obj/glibc-headers
++    $ BUILD_CC=gcc \
++    > CC=$tools/bin/$target-gcc \
++    > CXX=$tools/bin/$target-g++ \
++    > AR=$tools/bin/$target-ar \
++    > RANLIB=$tools/bin/$target-ranlib \
++    > $src/glibc/libc/configure \
++    >     --prefix=/usr \
++    >     --with-headers=$sysroot/usr/include \
++    >     --build=$build \
++    >     --host=$target \
++    >     --disable-profile --without-gd --without-cvs \
++    >     --enable-add-ons=nptl,libidn,../ports
++
++The option '--prefix=/usr' may look strange, but you should never
++configure GLIBC with a prefix other than '/usr': in various places,
++GLIBC's build system checks whether the prefix is '/usr', and does
++special handling only if that is the case.  Unless you use this
++prefix, you will get a sysroot that does not use the standard Linux
++directory layouts and cannot be used as a basis for the root
++filesystem on your target system compatibly with normal GLIBC
++installations.
++
++The '--with-headers' option tells GLIBC where the Linux headers have
++been installed.
++
++The '--enable-add-ons=nptl,libidn,../ports' option tells GLIBC to look
++for the listed glibc add-ons. Most notably the ports add-on (located
++just above the libc sources in the GLIBC svn tree) is required to
++support ARM targets.
++
++We can now use the 'install-headers' makefile target to install the
++headers:
++
++    $ make install-headers install_root=$sysroot \
++    >                      install-bootstrap-headers=yes
++
++The 'install_root' variable indicates where the files should actually
++be installed; its value is treated as the parent of the '--prefix'
++directory we passed to the configure script, so the headers will go in
++'$sysroot/usr/include'.  The 'install-bootstrap-headers' variable
++requests special handling for certain tricky header files.
++
++Next, there are a few object files needed to link shared libraries,
++which we build and install by hand:
++
++    $ mkdir -p $sysroot/usr/lib
++    $ make csu/subdir_lib
++    $ cp csu/crt1.o csu/crti.o csu/crtn.o $sysroot/usr/lib
++
++Finally, 'libgcc_s.so' requires a 'libc.so' to link against.  However,
++since we will never actually execute its code, it doesn't matter what
++it contains.  So, treating '/dev/null' as a C source file, we produce
++a dummy 'libc.so' in one step:
++
++    $ $tools/bin/$target-gcc -nostdlib -nostartfiles -shared -x c /dev/null \
++    >                        -o $sysroot/usr/lib/libc.so
++
++
++The Second GCC
++
++With the GLIBC headers and selected object files installed, we can
++now build a GCC that is capable of compiling GLIBC.  We configure,
++build, and install the second GCC, again building only the C compiler,
++and avoiding libraries we won't use:
++
++    $ mkdir -p $obj/gcc2
++    $ cd $obj/gcc2
++    $ $src/$gccv/configure \
++    >     --target=$target \
++    >     --prefix=$tools \
++    >     --with-sysroot=$sysroot \
++    >     --disable-libssp --disable-libgomp --disable-libmudflap \
++    >     --disable-libffi --disable-libquadmath \
++    >     --enable-languages=c
++    $ PATH=$tools/bin:$PATH make
++    $ PATH=$tools/bin:$PATH make install
++
++
++GLIBC, Complete
++
++With the second compiler built and installed, we're now ready for the
++full GLIBC build:
++
++    $ mkdir -p $obj/glibc
++    $ cd $obj/glibc
++    $ BUILD_CC=gcc \
++    > CC=$tools/bin/$target-gcc \
++    > CXX=$tools/bin/$target-g++ \
++    > AR=$tools/bin/$target-ar \
++    > RANLIB=$tools/bin/$target-ranlib \
++    > $src/glibc/libc/configure \
++    >     --prefix=/usr \
++    >     --with-headers=$sysroot/usr/include \
++    >     --with-kconfig=$obj/linux/scripts/kconfig \
++    >     --build=$build \
++    >     --host=$target \
++    >     --disable-profile --without-gd --without-cvs \
++    >     --enable-add-ons=nptl,libidn,../ports
++
++Note the additional '--with-kconfig' option. This tells GLIBC where to
++find the host config tools used by the kernel 'make config' and 'make
++menuconfig'.  These tools can be re-used by GLIBC for its own 'make
++*config' support, which will create 'option-groups.config' for you.
++But first make sure those tools have been built by running some
++dummy 'make *config' calls in the kernel directory:
++
++    $ cd $obj/linux
++    $ PATH=$tools/bin:$PATH make config \
++    >      ARCH=$linux_arch CROSS_COMPILE=$target- \
++    $ PATH=$tools/bin:$PATH make menuconfig \
++    >      ARCH=$linux_arch CROSS_COMPILE=$target- \
++
++Now we can configure and build the full GLIBC:
++
++    $ cd $obj/glibc
++    $ PATH=$tools/bin:$PATH make defconfig
++    $ PATH=$tools/bin:$PATH make menuconfig
++    $ PATH=$tools/bin:$PATH make
++    $ PATH=$tools/bin:$PATH make install install_root=$sysroot
++
++At this point, we have a complete GLIBC installation in '$sysroot',
++with header files, library files, and most of the C runtime startup
++files in place.
++
++
++The Third GCC
++
++Finally, we recompile GCC against this full installation, enabling
++whatever languages and libraries we would like to use:
++
++    $ mkdir -p $obj/gcc3
++    $ cd $obj/gcc3
++    $ $src/$gccv/configure \
++    >     --target=$target \
++    >     --prefix=$tools \
++    >     --with-sysroot=$sysroot \
++    >     --enable-__cxa_atexit \
++    >     --disable-libssp --disable-libgomp --disable-libmudflap \
++    >     --enable-languages=c,c++
++    $ PATH=$tools/bin:$PATH make
++    $ PATH=$tools/bin:$PATH make install
++
++The '--enable-__cxa_atexit' option tells GCC what sort of C++
++destructor support to expect from the C library; it's required with
++GLIBC.
++
++And since GCC's installation process isn't designed to help construct
++sysroot trees, we must manually copy certain libraries into place in
++the sysroot.
++
++    $ cp -d $tools/$target/lib/libgcc_s.so* $sysroot/lib
++    $ cp -d $tools/$target/lib/libstdc++.so* $sysroot/usr/lib
++
++
++Trying Things Out
++
++At this point, '$tools' contains a cross toolchain ready to use
++the GLIBC installation in '$sysroot':
++
++    $ cat > hello.c <<EOF
++    > #include <stdio.h>
++    > int
++    > main (int argc, char **argv)
++    > {
++    >   puts ("Hello, world!");
++    >   return 0;
++    > }
++    > EOF
++    $ $tools/bin/$target-gcc -Wall hello.c -o hello
++    $ cat > c++-hello.cc <<EOF
++    > #include <iostream>
++    > int
++    > main (int argc, char **argv)
++    > {
++    >   std::cout << "Hello, C++ world!" << std::endl;
++    >   return 0;
++    > }
++    > EOF
++    $ $tools/bin/$target-g++ -Wall c++-hello.cc -o c++-hello
++
++
++We can use 'readelf' to verify that these are indeed executables for
++our target, using our dynamic linker:
++
++    $ $tools/bin/$target-readelf -hl hello
++    ELF Header:
++    ...
++      Type:                              EXEC (Executable file)
++      Machine:                           ARM
++
++    ...
++    Program Headers:
++      Type           Offset   VirtAddr   PhysAddr   FileSiz MemSiz  Flg Align
++      PHDR           0x000034 0x10000034 0x10000034 0x00100 0x00100 R E 0x4
++      INTERP         0x000134 0x00008134 0x00008134 0x00013 0x00013 R   0x1
++          [Requesting program interpreter: /lib/ld-linux.so.3]
++      LOAD           0x000000 0x00008000 0x00008000 0x0042c 0x0042c R E 0x8000
++    ...
++
++Looking at the dynamic section of the installed 'libgcc_s.so', we see
++that the 'NEEDED' entry for the C library does include the '.6'
++suffix, indicating that was linked against our fully build GLIBC, and
++not our dummy 'libc.so':
++
++    $ $tools/bin/$target-readelf -d $sysroot/lib/libgcc_s.so.1
++    Dynamic section at offset 0x1083c contains 24 entries:
++      Tag        Type                         Name/Value
++     0x00000001 (NEEDED)                     Shared library: [libc.so.6]
++     0x0000000e (SONAME)                     Library soname: [libgcc_s.so.1]
++    ...
++
++
++And on the target machine, we can run our programs:
++
++    $ $sysroot/lib/ld.so.1 --library-path $sysroot/lib:$sysroot/usr/lib \
++    > ./hello
++    Hello, world!
++    $ $sysroot/lib/ld.so.1 --library-path $sysroot/lib:$sysroot/usr/lib \
++    > ./c++-hello
++    Hello, C++ world!
+diff --git a/GLIBC.cross-testing b/GLIBC.cross-testing
+new file mode 100644
+index 0000000000..b67b468466
+--- /dev/null
++++ b/GLIBC.cross-testing
+@@ -0,0 +1,205 @@
++                                                        -*- mode: text -*-
++
++                      Cross-Testing With GLIBC
++                  Jim Blandy <jimb@codesourcery.com>
++
++
++Introduction
++
++Developers writing software for embedded systems often use a desktop
++or other similarly capable computer for development, but need to run
++tests on the embedded system, or perhaps on a simulator.  When
++configured for cross-compilation, the stock GNU C library simply
++disables running tests altogether: the command 'make tests' builds
++test programs, but does not run them.  GLIBC, however, provides
++facilities for compiling tests and generating data files on the build
++system, but running the test programs themselves on a remote system or
++simulator.
++
++
++Test environment requirements
++
++The test environment must meet certain conditions for GLIBC's
++cross-testing facilities to work:
++
++- Shared filesystems.  The 'build' system, on which you configure and
++  compile GLIBC, and the 'host' system, on which you intend to run
++  GLIBC, must share a filesystem containing the GLIBC build and
++  source trees.  Files must appear at the same paths on both systems.
++
++- Remote-shell like invocation.  There must be a way to run a program
++  on the host system from the build system, passing it properly quoted
++  command-line arguments, setting environment variables, and
++  inheriting the caller's standard input and output.
++
++
++Usage
++
++To use GLIBC's cross-testing support, provide values for the
++following Make variables when you invoke 'make':
++
++- cross-test-wrapper
++
++  This should be the name of the cross-testing wrapper command, along
++  with any arguments.
++
++- cross-localedef
++
++  This should be the name of a cross-capable localedef program, like
++  that included in the GLIBC 'localedef' module, along with any
++  arguments needed.
++
++These are each explained in detail below.
++
++
++The Cross-Testing Wrapper
++
++To run test programs reliably, the stock GNU C library takes care to
++ensure that test programs use the newly compiled dynamic linker and
++shared libraries, and never the host system's installed libraries.  To
++accomplish this, it runs the tests by explicitly invoking the dynamic
++linker from the build tree, passing it a list of build tree
++directories to search for shared libraries, followed by the name of
++the executable to run and its arguments.
++
++For example, where one might normally run a test program like this:
++
++    $ ./tst-foo arg1 arg2
++
++the GNU C library might run that program like this:
++
++    $ $objdir/elf/ld-linux.so.3 --library-path $objdir \
++      ./tst-foo arg1 arg2
++
++(where $objdir is the path to the top of the build tree, and the
++trailing backslash indicates a continuation of the command).  In other
++words, each test program invocation is 'wrapped up' inside an explicit
++invocation of the dynamic linker, which must itself execute the test
++program, having loaded shared libraries from the appropriate
++directories.
++
++To support cross-testing, GLIBC allows the developer to optionally
++set the 'cross-test-wrapper' Make variable to another wrapper command,
++to which it passes the entire dynamic linker invocation shown above as
++arguments.  For example, if the developer supplies a wrapper of
++'my-wrapper hostname', then GLIBC would run the test above as
++follows:
++
++    $ my-wrapper hostname \
++      $objdir/elf/ld-linux.so.3 --library-path $objdir \
++      ./tst-foo arg1 arg2
++
++The 'my-wrapper' command is responsible for executing the command
++given on the host system.
++
++Since tests are run in varying directories, the wrapper should either
++be in your command search path, or 'cross-test-wrapper' should give an
++absolute path for the wrapper.
++
++The wrapper must meet several requirements:
++
++- It must preserve the current directory.  As explained above, the
++  build directory tree must be visible on both the build and host
++  systems, at the same path.  The test wrapper must ensure that the
++  current directory it inherits is also inherited by the dynamic
++  linker (and thus the test program itself).
++
++- It must preserve environment variables' values.  Many GLIBC tests
++  set environment variables for test runs; in native testing, it
++  invokes programs like this:
++
++    $ GCONV_PATH=$objdir/iconvdata \
++      $objdir/elf/ld-linux.so.3 --library-path $objdir \
++      ./tst-foo arg1 arg2
++
++  With the cross-testing wrapper, that invocation becomes:
++
++    $ GCONV_PATH=$objdir/iconvdata \
++      my-wrapper hostname \
++      $objdir/elf/ld-linux.so.3 --library-path $objdir \
++      ./tst-foo arg1 arg2
++
++  Here, 'my-wrapper' must ensure that the value it sees for
++  'GCONV_PATH' will be seen by the dynamic linker, and thus 'tst-foo'
++  itself.  (The wrapper supplied with GLIBC simply preserves the
++  values of *all* enviroment variables, with a fixed set of
++  exceptions.)
++
++  If your wrapper is a shell script, take care to correctly propagate
++  environment variables whose values contain spaces and shell
++  metacharacters.
++
++- It must pass the command's arguments, unmodified.  The arguments
++  seen by the test program should be exactly those seen by the wrapper
++  (after whatever arguments are given to the wrapper itself).  The
++  GLIBC test framework performs all needed shell word splitting and
++  expansion (wildcard expansion, parameter substitution, and so on)
++  before invoking the wrapper; further expansion may break the tests.
++
++
++The 'cross-test-ssh.sh' script
++
++If you want to use 'ssh' (or something sufficiently similar) to run
++test programs on your host system, GLIBC includes a shell script,
++'scripts/cross-test-ssh.sh', which you can use as your wrapper
++command.  This script takes care of setting the test command's current
++directory, propagating environment variable values, and carrying
++command-line arguments, all across an 'ssh' connection.  You may even
++supply an alternative to 'ssh' on the command line, if needed.
++
++For more details, pass 'cross-test-ssh.sh' the '--help' option.
++
++
++The Cross-Compiling Locale Definition Command
++
++Some GLIBC tests rely on locales generated especially for the test
++process.  In a native configuration, these tests simply run the
++'localedef' command built by the normal GLIBC build process,
++'locale/localedef', to process and install their locales.  However, in
++a cross-compiling configuration, this 'localedef' is built for the
++host system, not the build system, and since it requires quite a bit
++of memory to run (we have seen it fail on systems with 64MiB of
++memory), it may not be practical to run it on the host system.
++
++If set, GLIBC uses the 'cross-localedef' Make variable as the command
++to run on the build system to process and install locales.  The
++localedef program built from the GLIBC 'localedef' module is
++suitable.
++
++The value of 'cross-localedef' may also include command-line arguments
++to be passed to the program; if you are using GLIBC's 'localedef',
++you may include endianness and 'uint32_t' alignment arguments here.
++
++
++Example
++
++In developing GLIBC's cross-testing facility, we invoked 'make' with
++the following script:
++
++    #!/bin/sh
++
++    srcdir=...
++    test_hostname=...
++    localedefdir=...
++    cross_gxx=...-g++
++
++    wrapper="$srcdir/scripts/cross-test-ssh.sh $test_hostname"
++    localedef="$localedefdir/localedef --little-endian --uint32-align=4"
++
++    make cross-test-wrapper="$wrapper" \
++         cross-localedef="$localedef" \
++         CXX="$cross_gxx" \
++         "$@"
++
++
++Other Cross-Testing Concerns
++
++Here are notes on some other issues which you may encounter in running
++the GLIBC tests in a cross-compiling environment:
++
++- Some tests require a C++ cross-compiler; you should set the 'CXX'
++  Make variable to the name of an appropriate cross-compiler.
++
++- Some tests require access to libstdc++.so.6 and libgcc_s.so.1; we
++  simply place copies of these libraries in the top GLIBC build
++  directory.
diff --git a/poky/meta/recipes-core/glibc/glibc/0018-eglibc-Help-bootstrap-cross-toolchain.patch b/poky/meta/recipes-core/glibc/glibc/0018-eglibc-Help-bootstrap-cross-toolchain.patch
deleted file mode 100644
index 80d547c..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0018-eglibc-Help-bootstrap-cross-toolchain.patch
+++ /dev/null
@@ -1,100 +0,0 @@
-From fcfa19b69e8749477022161a808a201807ef72ec Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 18 Mar 2015 00:49:28 +0000
-Subject: [PATCH 18/27] eglibc: Help bootstrap cross toolchain
-
-Taken from EGLIBC, r1484 + r1525
-
-        2007-02-20  Jim Blandy  <jimb@codesourcery.com>
-
-                * Makefile (install-headers): Preserve old behavior: depend on
-                $(inst_includedir)/gnu/stubs.h only if install-bootstrap-headers
-                is set; otherwise, place gnu/stubs.h on the 'install-others' list.
-
-        2007-02-16  Jim Blandy  <jimb@codesourcery.com>
-
-                * Makefile: Amend make install-headers to install everything
-                necessary for building a cross-compiler.  Install gnu/stubs.h as
-                part of 'install-headers', not 'install-others'.
-                If install-bootstrap-headers is 'yes', install a dummy copy of
-                gnu/stubs.h, instead of computing the real thing.
-                * include/stubs-bootstrap.h: New file.
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- Makefile                  | 22 +++++++++++++++++++++-
- include/stubs-bootstrap.h | 12 ++++++++++++
- 2 files changed, 33 insertions(+), 1 deletion(-)
- create mode 100644 include/stubs-bootstrap.h
-
-diff --git a/Makefile b/Makefile
-index bea4e27f8d..8c83cfadc6 100644
---- a/Makefile
-+++ b/Makefile
-@@ -70,9 +70,18 @@ subdir-dirs = include
- vpath %.h $(subdir-dirs)
- 
- # What to install.
--install-others = $(inst_includedir)/gnu/stubs.h
- install-bin-script =
- 
-+# If we're bootstrapping, install a dummy gnu/stubs.h along with the
-+# other headers, so 'make install-headers' produces a useable include
-+# tree.  Otherwise, install gnu/stubs.h later, after the rest of the
-+# build is done.
-+ifeq ($(install-bootstrap-headers),yes)
-+install-headers: $(inst_includedir)/gnu/stubs.h
-+else
-+install-others = $(inst_includedir)/gnu/stubs.h
-+endif
-+
- ifeq (yes,$(build-shared))
- headers += gnu/lib-names.h
- endif
-@@ -152,6 +161,16 @@ others: $(common-objpfx)testrun.sh
- 
- subdir-stubs := $(foreach dir,$(subdirs),$(common-objpfx)$(dir)/stubs)
- 
-+# gnu/stubs.h depends (via the subdir 'stubs' targets) on all the .o
-+# files in EGLIBC.  For bootstrapping a GCC/EGLIBC pair, an empty
-+# gnu/stubs.h is good enough.
-+ifeq ($(install-bootstrap-headers),yes)
-+$(inst_includedir)/gnu/stubs.h: include/stubs-bootstrap.h $(+force)
-+	$(make-target-directory)
-+	$(INSTALL_DATA) $< $@
-+
-+installed-stubs =
-+else
- ifndef abi-variants
- installed-stubs = $(inst_includedir)/gnu/stubs.h
- else
-@@ -178,6 +197,7 @@ $(inst_includedir)/gnu/stubs.h: $(+force)
- 
- install-others-nosubdir: $(installed-stubs)
- endif
-+endif
- 
- 
- # Since stubs.h is never needed when building the library, we simplify the
-diff --git a/include/stubs-bootstrap.h b/include/stubs-bootstrap.h
-new file mode 100644
-index 0000000000..1d2b669aff
---- /dev/null
-+++ b/include/stubs-bootstrap.h
-@@ -0,0 +1,12 @@
-+/* Placeholder stubs.h file for bootstrapping.
-+
-+   When bootstrapping a GCC/EGLIBC pair, GCC requires that the EGLIBC
-+   headers be installed, but we can't fully build EGLIBC without that
-+   GCC.  So we run the command:
-+
-+      make install-headers install-bootstrap-headers=yes
-+
-+   to install the headers GCC needs, but avoid building certain
-+   difficult headers.  The <gnu/stubs.h> header depends, via the
-+   EGLIBC subdir 'stubs' make targets, on every .o file in EGLIBC, but
-+   an empty stubs.h like this will do fine for GCC.  */
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0019-eglibc-Clear-cache-lines-on-ppc8xx.patch b/poky/meta/recipes-core/glibc/glibc/0019-eglibc-Clear-cache-lines-on-ppc8xx.patch
deleted file mode 100644
index 17bfe4f..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0019-eglibc-Clear-cache-lines-on-ppc8xx.patch
+++ /dev/null
@@ -1,83 +0,0 @@
-From c6f2db0d7c5c65bfa19766a0e1ce8210111f9c7d Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 31 Dec 2015 15:15:09 -0800
-Subject: [PATCH 19/27] eglibc: Clear cache lines on ppc8xx
-
-2007-06-13  Nathan Sidwell  <nathan@codesourcery.com>
-            Mark Shinwell  <shinwell@codesourcery.com>
-
-        * sysdeps/unix/sysv/linux/powerpc/libc-start.c
-        (__libc_start_main): Detect 8xx parts and clear
-        __cache_line_size if detected.
-        * sysdeps/unix/sysv/linux/powerpc/dl-sysdep.c
-        (DL_PLATFORM_AUXV): Likewise.
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- sysdeps/unix/sysv/linux/powerpc/dl-sysdep.c  | 14 +++++++++++++-
- sysdeps/unix/sysv/linux/powerpc/libc-start.c | 16 +++++++++++++++-
- 2 files changed, 28 insertions(+), 2 deletions(-)
-
-diff --git a/sysdeps/unix/sysv/linux/powerpc/dl-sysdep.c b/sysdeps/unix/sysv/linux/powerpc/dl-sysdep.c
-index 78051bc7bc..e24f442320 100644
---- a/sysdeps/unix/sysv/linux/powerpc/dl-sysdep.c
-+++ b/sysdeps/unix/sysv/linux/powerpc/dl-sysdep.c
-@@ -24,9 +24,21 @@ int __cache_line_size attribute_hidden;
- /* Scan the Aux Vector for the "Data Cache Block Size" entry.  If found
-    verify that the static extern __cache_line_size is defined by checking
-    for not NULL.  If it is defined then assign the cache block size
--   value to __cache_line_size.  */
-+   value to __cache_line_size.  This is used by memset to
-+   optimize setting to zero.  We have to detect 8xx processors, which
-+   have buggy dcbz implementations that cannot report page faults
-+   correctly.  That requires reading SPR, which is a privileged
-+   operation.  Fortunately 2.2.18 and later emulates PowerPC mfspr
-+   reads from the PVR register.   */
- #define DL_PLATFORM_AUXV						      \
-       case AT_DCACHEBSIZE:						      \
-+	if (__LINUX_KERNEL_VERSION >= 0x020218)				      \
-+	  {								      \
-+	    unsigned pvr = 0;						      \
-+	    asm ("mfspr %0, 287" : "=r" (pvr));				      \
-+	    if ((pvr & 0xffff0000) == 0x00500000)			      \
-+	      break;							      \
-+	  }								      \
- 	__cache_line_size = av->a_un.a_val;				      \
- 	break;
- 
-diff --git a/sysdeps/unix/sysv/linux/powerpc/libc-start.c b/sysdeps/unix/sysv/linux/powerpc/libc-start.c
-index f2ad0c355d..3e6773795e 100644
---- a/sysdeps/unix/sysv/linux/powerpc/libc-start.c
-+++ b/sysdeps/unix/sysv/linux/powerpc/libc-start.c
-@@ -73,11 +73,25 @@ __libc_start_main (int argc, char **argv,
- 
-   /* Initialize the __cache_line_size variable from the aux vector.  For the
-      static case, we also need _dl_hwcap, _dl_hwcap2 and _dl_platform, so we
--     can call __tcb_parse_hwcap_and_convert_at_platform ().  */
-+     can call __tcb_parse_hwcap_and_convert_at_platform ().
-+
-+     This is used by memset to optimize setting to zero.  We have to
-+     detect 8xx processors, which have buggy dcbz implementations that
-+     cannot report page faults correctly.  That requires reading SPR,
-+     which is a privileged operation.  Fortunately 2.2.18 and later
-+     emulates PowerPC mfspr reads from the PVR register.  */
-   for (ElfW (auxv_t) * av = auxvec; av->a_type != AT_NULL; ++av)
-     switch (av->a_type)
-       {
-       case AT_DCACHEBSIZE:
-+	if (__LINUX_KERNEL_VERSION >= 0x020218)
-+	  {
-+	    unsigned pvr = 0;
-+
-+	    asm ("mfspr %0, 287" : "=r" (pvr) :);
-+	    if ((pvr & 0xffff0000) == 0x00500000)
-+	      break;
-+	  }
- 	__cache_line_size = av->a_un.a_val;
- 	break;
- #ifndef SHARED
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0019-eglibc-Help-bootstrap-cross-toolchain.patch b/poky/meta/recipes-core/glibc/glibc/0019-eglibc-Help-bootstrap-cross-toolchain.patch
new file mode 100644
index 0000000..71c2ab9
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0019-eglibc-Help-bootstrap-cross-toolchain.patch
@@ -0,0 +1,97 @@
+From f4ec5527d562d38523abb8587a6c7532e9d21f8a Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 18 Mar 2015 00:49:28 +0000
+Subject: [PATCH] eglibc: Help bootstrap cross toolchain
+
+Taken from EGLIBC, r1484 + r1525
+
+        2007-02-20  Jim Blandy  <jimb@codesourcery.com>
+
+                * Makefile (install-headers): Preserve old behavior: depend on
+                $(inst_includedir)/gnu/stubs.h only if install-bootstrap-headers
+                is set; otherwise, place gnu/stubs.h on the 'install-others' list.
+
+        2007-02-16  Jim Blandy  <jimb@codesourcery.com>
+
+                * Makefile: Amend make install-headers to install everything
+                necessary for building a cross-compiler.  Install gnu/stubs.h as
+                part of 'install-headers', not 'install-others'.
+                If install-bootstrap-headers is 'yes', install a dummy copy of
+                gnu/stubs.h, instead of computing the real thing.
+                * include/stubs-bootstrap.h: New file.
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ Makefile                  | 22 +++++++++++++++++++++-
+ include/stubs-bootstrap.h | 12 ++++++++++++
+ 2 files changed, 33 insertions(+), 1 deletion(-)
+ create mode 100644 include/stubs-bootstrap.h
+
+diff --git a/Makefile b/Makefile
+index d3f25a525a..ab383867e2 100644
+--- a/Makefile
++++ b/Makefile
+@@ -70,9 +70,18 @@ subdir-dirs = include
+ vpath %.h $(subdir-dirs)
+ 
+ # What to install.
+-install-others = $(inst_includedir)/gnu/stubs.h
+ install-bin-script =
+ 
++# If we're bootstrapping, install a dummy gnu/stubs.h along with the
++# other headers, so 'make install-headers' produces a useable include
++# tree.  Otherwise, install gnu/stubs.h later, after the rest of the
++# build is done.
++ifeq ($(install-bootstrap-headers),yes)
++install-headers: $(inst_includedir)/gnu/stubs.h
++else
++install-others = $(inst_includedir)/gnu/stubs.h
++endif
++
+ ifeq (yes,$(build-shared))
+ headers += gnu/lib-names.h
+ endif
+@@ -195,6 +204,16 @@ others: $(common-objpfx)testrun.sh
+ 
+ subdir-stubs := $(foreach dir,$(subdirs),$(common-objpfx)$(dir)/stubs)
+ 
++# gnu/stubs.h depends (via the subdir 'stubs' targets) on all the .o
++# files in EGLIBC.  For bootstrapping a GCC/EGLIBC pair, an empty
++# gnu/stubs.h is good enough.
++ifeq ($(install-bootstrap-headers),yes)
++$(inst_includedir)/gnu/stubs.h: include/stubs-bootstrap.h $(+force)
++	$(make-target-directory)
++	$(INSTALL_DATA) $< $@
++
++installed-stubs =
++else
+ ifndef abi-variants
+ installed-stubs = $(inst_includedir)/gnu/stubs.h
+ else
+@@ -221,6 +240,7 @@ $(inst_includedir)/gnu/stubs.h: $(+force)
+ 
+ install-others-nosubdir: $(installed-stubs)
+ endif
++endif
+ 
+ 
+ # Since stubs.h is never needed when building the library, we simplify the
+diff --git a/include/stubs-bootstrap.h b/include/stubs-bootstrap.h
+new file mode 100644
+index 0000000000..1d2b669aff
+--- /dev/null
++++ b/include/stubs-bootstrap.h
+@@ -0,0 +1,12 @@
++/* Placeholder stubs.h file for bootstrapping.
++
++   When bootstrapping a GCC/EGLIBC pair, GCC requires that the EGLIBC
++   headers be installed, but we can't fully build EGLIBC without that
++   GCC.  So we run the command:
++
++      make install-headers install-bootstrap-headers=yes
++
++   to install the headers GCC needs, but avoid building certain
++   difficult headers.  The <gnu/stubs.h> header depends, via the
++   EGLIBC subdir 'stubs' make targets, on every .o file in EGLIBC, but
++   an empty stubs.h like this will do fine for GCC.  */
diff --git a/poky/meta/recipes-core/glibc/glibc/0020-eglibc-Clear-cache-lines-on-ppc8xx.patch b/poky/meta/recipes-core/glibc/glibc/0020-eglibc-Clear-cache-lines-on-ppc8xx.patch
new file mode 100644
index 0000000..6e475a7
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0020-eglibc-Clear-cache-lines-on-ppc8xx.patch
@@ -0,0 +1,80 @@
+From 6c23660d035e71de0e20b40460ad3050bd057665 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 31 Dec 2015 15:15:09 -0800
+Subject: [PATCH] eglibc: Clear cache lines on ppc8xx
+
+2007-06-13  Nathan Sidwell  <nathan@codesourcery.com>
+            Mark Shinwell  <shinwell@codesourcery.com>
+
+        * sysdeps/unix/sysv/linux/powerpc/libc-start.c
+        (__libc_start_main): Detect 8xx parts and clear
+        __cache_line_size if detected.
+        * sysdeps/unix/sysv/linux/powerpc/dl-sysdep.c
+        (DL_PLATFORM_AUXV): Likewise.
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ sysdeps/unix/sysv/linux/powerpc/dl-sysdep.c  | 14 +++++++++++++-
+ sysdeps/unix/sysv/linux/powerpc/libc-start.c | 16 +++++++++++++++-
+ 2 files changed, 28 insertions(+), 2 deletions(-)
+
+diff --git a/sysdeps/unix/sysv/linux/powerpc/dl-sysdep.c b/sysdeps/unix/sysv/linux/powerpc/dl-sysdep.c
+index 78051bc7bc..e24f442320 100644
+--- a/sysdeps/unix/sysv/linux/powerpc/dl-sysdep.c
++++ b/sysdeps/unix/sysv/linux/powerpc/dl-sysdep.c
+@@ -24,9 +24,21 @@ int __cache_line_size attribute_hidden;
+ /* Scan the Aux Vector for the "Data Cache Block Size" entry.  If found
+    verify that the static extern __cache_line_size is defined by checking
+    for not NULL.  If it is defined then assign the cache block size
+-   value to __cache_line_size.  */
++   value to __cache_line_size.  This is used by memset to
++   optimize setting to zero.  We have to detect 8xx processors, which
++   have buggy dcbz implementations that cannot report page faults
++   correctly.  That requires reading SPR, which is a privileged
++   operation.  Fortunately 2.2.18 and later emulates PowerPC mfspr
++   reads from the PVR register.   */
+ #define DL_PLATFORM_AUXV						      \
+       case AT_DCACHEBSIZE:						      \
++	if (__LINUX_KERNEL_VERSION >= 0x020218)				      \
++	  {								      \
++	    unsigned pvr = 0;						      \
++	    asm ("mfspr %0, 287" : "=r" (pvr));				      \
++	    if ((pvr & 0xffff0000) == 0x00500000)			      \
++	      break;							      \
++	  }								      \
+ 	__cache_line_size = av->a_un.a_val;				      \
+ 	break;
+ 
+diff --git a/sysdeps/unix/sysv/linux/powerpc/libc-start.c b/sysdeps/unix/sysv/linux/powerpc/libc-start.c
+index f2ad0c355d..3e6773795e 100644
+--- a/sysdeps/unix/sysv/linux/powerpc/libc-start.c
++++ b/sysdeps/unix/sysv/linux/powerpc/libc-start.c
+@@ -73,11 +73,25 @@ __libc_start_main (int argc, char **argv,
+ 
+   /* Initialize the __cache_line_size variable from the aux vector.  For the
+      static case, we also need _dl_hwcap, _dl_hwcap2 and _dl_platform, so we
+-     can call __tcb_parse_hwcap_and_convert_at_platform ().  */
++     can call __tcb_parse_hwcap_and_convert_at_platform ().
++
++     This is used by memset to optimize setting to zero.  We have to
++     detect 8xx processors, which have buggy dcbz implementations that
++     cannot report page faults correctly.  That requires reading SPR,
++     which is a privileged operation.  Fortunately 2.2.18 and later
++     emulates PowerPC mfspr reads from the PVR register.  */
+   for (ElfW (auxv_t) * av = auxvec; av->a_type != AT_NULL; ++av)
+     switch (av->a_type)
+       {
+       case AT_DCACHEBSIZE:
++	if (__LINUX_KERNEL_VERSION >= 0x020218)
++	  {
++	    unsigned pvr = 0;
++
++	    asm ("mfspr %0, 287" : "=r" (pvr) :);
++	    if ((pvr & 0xffff0000) == 0x00500000)
++	      break;
++	  }
+ 	__cache_line_size = av->a_un.a_val;
+ 	break;
+ #ifndef SHARED
diff --git a/poky/meta/recipes-core/glibc/glibc/0020-eglibc-Resolve-__fpscr_values-on-SH4.patch b/poky/meta/recipes-core/glibc/glibc/0020-eglibc-Resolve-__fpscr_values-on-SH4.patch
deleted file mode 100644
index 09f7670..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0020-eglibc-Resolve-__fpscr_values-on-SH4.patch
+++ /dev/null
@@ -1,56 +0,0 @@
-From 577085016bb926a687abec145557fe8cb8f5af0e Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 18 Mar 2015 00:55:53 +0000
-Subject: [PATCH 20/27] eglibc: Resolve __fpscr_values on SH4
-
-2010-09-29  Nobuhiro Iwamatsu  <iwamatsu@nigauri.org>
-            Andrew Stubbs  <ams@codesourcery.com>
-
-        Resolve SH's __fpscr_values to symbol in libc.so.
-
-        * sysdeps/sh/sh4/fpu/fpu_control.h: Add C++ __set_fpscr prototype.
-        * sysdeps/unix/sysv/linux/sh/Versions (GLIBC_2.2): Add __fpscr_values.
-        * sysdeps/unix/sysv/linux/sh/sysdep.S (___fpscr_values): New constant.
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- sysdeps/unix/sysv/linux/sh/Versions |  1 +
- sysdeps/unix/sysv/linux/sh/sysdep.S | 11 +++++++++++
- 2 files changed, 12 insertions(+)
-
-diff --git a/sysdeps/unix/sysv/linux/sh/Versions b/sysdeps/unix/sysv/linux/sh/Versions
-index e0938c4165..ca1d7da339 100644
---- a/sysdeps/unix/sysv/linux/sh/Versions
-+++ b/sysdeps/unix/sysv/linux/sh/Versions
-@@ -2,6 +2,7 @@ libc {
-   GLIBC_2.2 {
-     # functions used in other libraries
-     __xstat64; __fxstat64; __lxstat64;
-+    __fpscr_values;
- 
-     # a*
-     alphasort64;
-diff --git a/sysdeps/unix/sysv/linux/sh/sysdep.S b/sysdeps/unix/sysv/linux/sh/sysdep.S
-index c4e28ffb98..648bae03d5 100644
---- a/sysdeps/unix/sysv/linux/sh/sysdep.S
-+++ b/sysdeps/unix/sysv/linux/sh/sysdep.S
-@@ -30,3 +30,14 @@ ENTRY (__syscall_error)
- 
- #define __syscall_error __syscall_error_1
- #include <sysdeps/unix/sh/sysdep.S>
-+
-+       .data
-+       .align 3
-+       .globl ___fpscr_values
-+       .type ___fpscr_values, @object
-+       .size ___fpscr_values, 8
-+___fpscr_values:
-+       .long 0
-+       .long 0x80000
-+weak_alias (___fpscr_values, __fpscr_values)
-+
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0021-eglibc-Install-PIC-archives.patch b/poky/meta/recipes-core/glibc/glibc/0021-eglibc-Install-PIC-archives.patch
deleted file mode 100644
index 530f4e1..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0021-eglibc-Install-PIC-archives.patch
+++ /dev/null
@@ -1,123 +0,0 @@
-From c1beab8a11985f96f5eb644e7103d343b705afc6 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 18 Mar 2015 01:57:01 +0000
-Subject: [PATCH 21/27] eglibc: Install PIC archives
-
-Forward port from eglibc
-
-2008-02-07  Joseph Myers  <joseph@codesourcery.com>
-
-        * Makerules (install-extras, install-map): New variables.
-        (installed-libcs): Add libc_pic.a.
-        (install-lib): Include _pic.a files for versioned shared
-        libraries.
-        (install-map-nosubdir, install-extras-nosubdir): Add rules for
-        installing extra files.
-        (install-no-libc.a-nosubdir): Depend on install-map-nosubdir and
-        install-extras-nosubdir.
-
-2008-04-01  Maxim Kuvyrkov  <maxim@codesourcery.com>
-
-        * Makerules (install-lib): Don't install libpthread_pic.a.
-        (install-map): Don't install libpthread_pic.map.
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- Makerules | 42 ++++++++++++++++++++++++++++++++++++++++--
- 1 file changed, 40 insertions(+), 2 deletions(-)
-
-diff --git a/Makerules b/Makerules
-index ef6abeac6d..eeaa667f49 100644
---- a/Makerules
-+++ b/Makerules
-@@ -778,6 +778,9 @@ ifeq ($(build-shared),yes)
- $(common-objpfx)libc.so: $(common-objpfx)libc.map
- endif
- common-generated += libc.so libc_pic.os
-+ifndef subdir
-+install-extras := soinit.o sofini.o
-+endif
- ifdef libc.so-version
- $(common-objpfx)libc.so$(libc.so-version): $(common-objpfx)libc.so
- 	$(make-link)
-@@ -1029,6 +1032,7 @@ endif
- 
- install: check-install-supported
- 
-+installed-libcs := $(installed-libcs) $(inst_libdir)/libc_pic.a
- install: $(installed-libcs)
- $(installed-libcs): $(inst_libdir)/lib$(libprefix)%: lib $(+force)
- 	$(make-target-directory)
-@@ -1057,6 +1061,22 @@ versioned := $(strip $(foreach so,$(install-lib.so),\
- install-lib.so-versioned := $(filter $(versioned), $(install-lib.so))
- install-lib.so-unversioned := $(filter-out $(versioned), $(install-lib.so))
- 
-+# Install the _pic.a files for versioned libraries, and corresponding
-+# .map files.
-+# libpthread_pic.a breaks mklibs, so don't install it and its map.
-+install-lib := $(install-lib) $(install-lib.so-versioned:%.so=%_pic.a)
-+install-lib := $(filter-out libpthread_pic.a,$(install-lib))
-+# Despite having a soname libhurduser and libmachuser do not use symbol
-+# versioning, so don't install the corresponding .map files.
-+ifeq ($(build-shared),yes)
-+install-map := $(patsubst %.so,%.map,\
-+			$(foreach L,$(install-lib.so-versioned),$(notdir $L)))
-+install-map := $(filter-out libhurduser.map libmachuser.map libpthread.map,$(install-map))
-+ifndef subdir
-+install-map := $(install-map) libc.map
-+endif
-+endif
-+
- # For versioned libraries, we install three files:
- #	$(inst_libdir)/libfoo.so	-- for linking, symlink or ld script
- #	$(inst_slibdir)/libfoo.so.NN	-- for loading by SONAME, symlink
-@@ -1311,9 +1331,22 @@ $(addprefix $(inst_includedir)/,$(headers-nonh)): $(inst_includedir)/%: \
- endif	# headers-nonh
- endif	# headers
- 
-+ifdef install-map
-+$(addprefix $(inst_libdir)/,$(patsubst lib%.map,lib%_pic.map,$(install-map))): \
-+  $(inst_libdir)/lib%_pic.map: $(common-objpfx)lib%.map $(+force)
-+	$(do-install)
-+endif
-+
-+ifdef install-extras
-+$(addprefix $(inst_libdir)/libc_pic/,$(install-extras)): \
-+  $(inst_libdir)/libc_pic/%.o: $(elf-objpfx)%.os $(+force)
-+	$(do-install)
-+endif
-+
- .PHONY: install-bin-nosubdir install-bin-script-nosubdir \
- 	install-rootsbin-nosubdir install-sbin-nosubdir install-lib-nosubdir \
--	install-data-nosubdir install-headers-nosubdir
-+	install-data-nosubdir install-headers-nosubdir install-map-nosubdir \
-+	install-extras-nosubdir
- install-bin-nosubdir: $(addprefix $(inst_bindir)/,$(install-bin))
- install-bin-script-nosubdir: $(addprefix $(inst_bindir)/,$(install-bin-script))
- install-rootsbin-nosubdir: \
-@@ -1326,6 +1359,10 @@ install-data-nosubdir: $(addprefix $(inst_datadir)/,$(install-data))
- install-headers-nosubdir: $(addprefix $(inst_includedir)/,$(headers))
- install-others-nosubdir: $(install-others)
- install-others-programs-nosubdir: $(install-others-programs)
-+install-map-nosubdir: $(addprefix $(inst_libdir)/,\
-+		       $(patsubst lib%.map,lib%_pic.map,$(install-map)))
-+install-extras-nosubdir: $(addprefix $(inst_libdir)/libc_pic/,\
-+		       $(install-extras))
- 
- # We need all the `-nosubdir' targets so that `install' in the parent
- # doesn't depend on several things which each iterate over the subdirs.
-@@ -1335,7 +1372,8 @@ install-%:: install-%-nosubdir ;
- 
- .PHONY: install install-no-libc.a-nosubdir
- install-no-libc.a-nosubdir: install-headers-nosubdir install-data-nosubdir \
--			    install-lib-nosubdir install-others-nosubdir
-+			    install-lib-nosubdir install-others-nosubdir \
-+			    install-map-nosubdir install-extras-nosubdir
- ifeq ($(build-programs),yes)
- install-no-libc.a-nosubdir: install-bin-nosubdir install-bin-script-nosubdir \
- 			    install-rootsbin-nosubdir install-sbin-nosubdir \
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0021-eglibc-Resolve-__fpscr_values-on-SH4.patch b/poky/meta/recipes-core/glibc/glibc/0021-eglibc-Resolve-__fpscr_values-on-SH4.patch
new file mode 100644
index 0000000..8aecf26
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0021-eglibc-Resolve-__fpscr_values-on-SH4.patch
@@ -0,0 +1,53 @@
+From 55531ef57d04006c5a1e3b32a8e0410372f86007 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 18 Mar 2015 00:55:53 +0000
+Subject: [PATCH] eglibc: Resolve __fpscr_values on SH4
+
+2010-09-29  Nobuhiro Iwamatsu  <iwamatsu@nigauri.org>
+            Andrew Stubbs  <ams@codesourcery.com>
+
+        Resolve SH's __fpscr_values to symbol in libc.so.
+
+        * sysdeps/sh/sh4/fpu/fpu_control.h: Add C++ __set_fpscr prototype.
+        * sysdeps/unix/sysv/linux/sh/Versions (GLIBC_2.2): Add __fpscr_values.
+        * sysdeps/unix/sysv/linux/sh/sysdep.S (___fpscr_values): New constant.
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ sysdeps/unix/sysv/linux/sh/Versions |  1 +
+ sysdeps/unix/sysv/linux/sh/sysdep.S | 11 +++++++++++
+ 2 files changed, 12 insertions(+)
+
+diff --git a/sysdeps/unix/sysv/linux/sh/Versions b/sysdeps/unix/sysv/linux/sh/Versions
+index e0938c4165..ca1d7da339 100644
+--- a/sysdeps/unix/sysv/linux/sh/Versions
++++ b/sysdeps/unix/sysv/linux/sh/Versions
+@@ -2,6 +2,7 @@ libc {
+   GLIBC_2.2 {
+     # functions used in other libraries
+     __xstat64; __fxstat64; __lxstat64;
++    __fpscr_values;
+ 
+     # a*
+     alphasort64;
+diff --git a/sysdeps/unix/sysv/linux/sh/sysdep.S b/sysdeps/unix/sysv/linux/sh/sysdep.S
+index c4e28ffb98..648bae03d5 100644
+--- a/sysdeps/unix/sysv/linux/sh/sysdep.S
++++ b/sysdeps/unix/sysv/linux/sh/sysdep.S
+@@ -30,3 +30,14 @@ ENTRY (__syscall_error)
+ 
+ #define __syscall_error __syscall_error_1
+ #include <sysdeps/unix/sh/sysdep.S>
++
++       .data
++       .align 3
++       .globl ___fpscr_values
++       .type ___fpscr_values, @object
++       .size ___fpscr_values, 8
++___fpscr_values:
++       .long 0
++       .long 0x80000
++weak_alias (___fpscr_values, __fpscr_values)
++
diff --git a/poky/meta/recipes-core/glibc/glibc/0022-eglibc-Forward-port-cross-locale-generation-support.patch b/poky/meta/recipes-core/glibc/glibc/0022-eglibc-Forward-port-cross-locale-generation-support.patch
index a629ce1..aa62c63 100644
--- a/poky/meta/recipes-core/glibc/glibc/0022-eglibc-Forward-port-cross-locale-generation-support.patch
+++ b/poky/meta/recipes-core/glibc/glibc/0022-eglibc-Forward-port-cross-locale-generation-support.patch
@@ -1,24 +1,24 @@
-From e019fe6a2b410db6043e21803f497b5cbdd90a83 Mon Sep 17 00:00:00 2001
+From 4bb23fbb07984b93fd14f353fd9325d927b0cd98 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Wed, 18 Mar 2015 01:33:49 +0000
-Subject: [PATCH 22/27] eglibc: Forward port cross locale generation support
+Subject: [PATCH] eglibc: Forward port cross locale generation support
 
 Upstream-Status: Pending
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 ---
- locale/Makefile               |  3 ++-
- locale/catnames.c             | 48 +++++++++++++++++++++++++++++++++++
+ locale/Makefile               |  3 +-
+ locale/catnames.c             | 48 ++++++++++++++++++++++++++++
  locale/localeinfo.h           |  2 +-
- locale/programs/charmap-dir.c |  6 +++++
- locale/programs/ld-collate.c  | 17 ++++++-------
- locale/programs/ld-ctype.c    | 27 ++++++++++----------
- locale/programs/ld-time.c     | 31 +++++++++++++++--------
+ locale/programs/charmap-dir.c |  6 ++++
+ locale/programs/ld-collate.c  | 17 +++++-----
+ locale/programs/ld-ctype.c    | 27 ++++++++--------
+ locale/programs/ld-time.c     | 31 ++++++++++++------
  locale/programs/linereader.c  |  2 +-
- locale/programs/localedef.c   |  8 ++++++
- locale/programs/locfile.c     |  5 +++-
- locale/programs/locfile.h     | 59 +++++++++++++++++++++++++++++++++++++++++--
- locale/setlocale.c            | 30 ----------------------
+ locale/programs/localedef.c   |  8 +++++
+ locale/programs/locfile.c     |  5 ++-
+ locale/programs/locfile.h     | 59 +++++++++++++++++++++++++++++++++--
+ locale/setlocale.c            | 30 ------------------
  12 files changed, 169 insertions(+), 69 deletions(-)
  create mode 100644 locale/catnames.c
 
@@ -91,7 +91,7 @@
 +    [LC_ALL] = sizeof ("LC_ALL") - 1
 +  };
 diff --git a/locale/localeinfo.h b/locale/localeinfo.h
-index 68822a6319..fa36123776 100644
+index 537bc35149..73ba20d695 100644
 --- a/locale/localeinfo.h
 +++ b/locale/localeinfo.h
 @@ -224,7 +224,7 @@ __libc_tsd_define (extern, locale_t, LOCALE)
@@ -561,6 +561,3 @@
  #ifdef NL_CURRENT_INDIRECT
  # define WEAK_POSTLOAD(postload) weak_extern (postload)
  #else
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0023-Define-DUMMY_LOCALE_T-if-not-defined.patch b/poky/meta/recipes-core/glibc/glibc/0023-Define-DUMMY_LOCALE_T-if-not-defined.patch
index ae708ef..68fad96 100644
--- a/poky/meta/recipes-core/glibc/glibc/0023-Define-DUMMY_LOCALE_T-if-not-defined.patch
+++ b/poky/meta/recipes-core/glibc/glibc/0023-Define-DUMMY_LOCALE_T-if-not-defined.patch
@@ -1,7 +1,7 @@
-From 9d71526be21abe68dd8ca3a5a219445851bbc2f4 Mon Sep 17 00:00:00 2001
+From 1b2ceb6c2414e3c98c7bcd029583287ced9f3159 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Wed, 20 Apr 2016 21:11:00 -0700
-Subject: [PATCH 23/27] Define DUMMY_LOCALE_T if not defined
+Subject: [PATCH] Define DUMMY_LOCALE_T if not defined
 
 This is a hack to fix building the locale bits on an older
 CentOs 5.X machine
@@ -27,6 +27,3 @@
  /* Use the internal textdomain used for libc messages.  */
  #define PACKAGE _libc_intl_domainname
  #ifndef VERSION
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0024-elf-dl-deps.c-Make-_dl_build_local_scope-breadth-fir.patch b/poky/meta/recipes-core/glibc/glibc/0024-elf-dl-deps.c-Make-_dl_build_local_scope-breadth-fir.patch
index 42ff667..28cff2b 100644
--- a/poky/meta/recipes-core/glibc/glibc/0024-elf-dl-deps.c-Make-_dl_build_local_scope-breadth-fir.patch
+++ b/poky/meta/recipes-core/glibc/glibc/0024-elf-dl-deps.c-Make-_dl_build_local_scope-breadth-fir.patch
@@ -1,7 +1,7 @@
-From 03873af286f1dab1062f598d6deb774ce513421d Mon Sep 17 00:00:00 2001
+From a6159c9486745664a5f116ee9cc45837021b7624 Mon Sep 17 00:00:00 2001
 From: Mark Hatle <mark.hatle@windriver.com>
 Date: Thu, 18 Aug 2016 14:07:58 -0500
-Subject: [PATCH 24/27] elf/dl-deps.c: Make _dl_build_local_scope breadth first
+Subject: [PATCH] elf/dl-deps.c: Make _dl_build_local_scope breadth first
 
 According to the ELF specification:
 
@@ -24,10 +24,10 @@
  1 file changed, 10 insertions(+), 4 deletions(-)
 
 diff --git a/elf/dl-deps.c b/elf/dl-deps.c
-index c975fcffd7..6ee58c74e0 100644
+index 9d9b1ba7f2..8414028c58 100644
 --- a/elf/dl-deps.c
 +++ b/elf/dl-deps.c
-@@ -72,13 +72,19 @@ _dl_build_local_scope (struct link_map **list, struct link_map *map)
+@@ -73,13 +73,19 @@ _dl_build_local_scope (struct link_map **list, struct link_map *map)
  {
    struct link_map **p = list;
    struct link_map **q;
@@ -51,6 +51,3 @@
    return p - list;
  }
  
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0025-locale-fix-hard-coded-reference-to-gcc-E.patch b/poky/meta/recipes-core/glibc/glibc/0025-locale-fix-hard-coded-reference-to-gcc-E.patch
index 7f5d142..4a7919f 100644
--- a/poky/meta/recipes-core/glibc/glibc/0025-locale-fix-hard-coded-reference-to-gcc-E.patch
+++ b/poky/meta/recipes-core/glibc/glibc/0025-locale-fix-hard-coded-reference-to-gcc-E.patch
@@ -1,7 +1,7 @@
-From 56dab024751941c07eb479f47ef6682e2168c86a Mon Sep 17 00:00:00 2001
+From 6c6aecba19b3e7947100623532a41b6f16734ace Mon Sep 17 00:00:00 2001
 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Rosen?= <jeremy.rosen@smile.fr>
 Date: Mon, 22 Aug 2016 16:09:25 +0200
-Subject: [PATCH 25/27] locale: fix hard-coded reference to gcc -E
+Subject: [PATCH] locale: fix hard-coded reference to gcc -E
 
 When new version of compilers are published, they may not be compatible with
 older versions of software. This is particularly common when software is built
@@ -33,6 +33,3 @@
  
  
  sub cstrlen {
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0026-reset-dl_load_write_lock-after-forking.patch b/poky/meta/recipes-core/glibc/glibc/0026-reset-dl_load_write_lock-after-forking.patch
index eca1193..71ddc12 100644
--- a/poky/meta/recipes-core/glibc/glibc/0026-reset-dl_load_write_lock-after-forking.patch
+++ b/poky/meta/recipes-core/glibc/glibc/0026-reset-dl_load_write_lock-after-forking.patch
@@ -1,7 +1,7 @@
-From 847d37d5a34e4bf294de4ba98de3668950e28bc7 Mon Sep 17 00:00:00 2001
+From efb0fca7db742f4195e1771d8ba4c7fba4938819 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sat, 27 Jan 2018 10:05:07 -0800
-Subject: [PATCH 26/27] reset dl_load_write_lock after forking
+Subject: [PATCH] reset dl_load_write_lock after forking
 
 The patch in this Bugzilla entry was requested by a customer:
 
@@ -20,10 +20,10 @@
  1 file changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/sysdeps/nptl/fork.c b/sysdeps/nptl/fork.c
-index 846fa49ef2..f87506f398 100644
+index ec56a827eb..0f48933ff1 100644
 --- a/sysdeps/nptl/fork.c
 +++ b/sysdeps/nptl/fork.c
-@@ -194,9 +194,9 @@ __libc_fork (void)
+@@ -130,9 +130,9 @@ __libc_fork (void)
  	  _IO_list_resetlock ();
  	}
  
@@ -33,8 +33,5 @@
 -
 +      __rtld_lock_initialize (GL(dl_load_write_lock));
        /* Run the handlers registered for the child.  */
-       while (allp != NULL)
- 	{
--- 
-2.16.1
-
+       __run_fork_handlers (atfork_run_child);
+     }
diff --git a/poky/meta/recipes-core/glibc/glibc/0027-Acquire-ld.so-lock-before-switching-to-malloc_atfork.patch b/poky/meta/recipes-core/glibc/glibc/0027-Acquire-ld.so-lock-before-switching-to-malloc_atfork.patch
index 9ec234b..dd37f2c 100644
--- a/poky/meta/recipes-core/glibc/glibc/0027-Acquire-ld.so-lock-before-switching-to-malloc_atfork.patch
+++ b/poky/meta/recipes-core/glibc/glibc/0027-Acquire-ld.so-lock-before-switching-to-malloc_atfork.patch
@@ -1,7 +1,7 @@
-From 94225ab4bcc1613531558a632270b5edce779bc9 Mon Sep 17 00:00:00 2001
+From 6ea962e0946da7564a774b08dd3eda28d64e9e56 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sat, 27 Jan 2018 10:08:04 -0800
-Subject: [PATCH 27/27] Acquire ld.so lock before switching to malloc_atfork
+Subject: [PATCH] Acquire ld.so lock before switching to malloc_atfork
 
 The patch is from
   https://sourceware.org/bugzilla/show_bug.cgi?id=4578
@@ -28,11 +28,11 @@
 Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 ---
- sysdeps/nptl/fork.c | 9 +++++++++
- 1 file changed, 9 insertions(+)
+ sysdeps/nptl/fork.c | 7 +++++++
+ 1 file changed, 7 insertions(+)
 
 diff --git a/sysdeps/nptl/fork.c b/sysdeps/nptl/fork.c
-index f87506f398..225e7b51f8 100644
+index 0f48933ff1..eef3f9669b 100644
 --- a/sysdeps/nptl/fork.c
 +++ b/sysdeps/nptl/fork.c
 @@ -25,6 +25,7 @@
@@ -43,28 +43,23 @@
  #include <stdio-lock.h>
  #include <atomic.h>
  #include <nptl/pthreadP.h>
-@@ -60,6 +61,10 @@ __libc_fork (void)
-      but our current fork implementation is not.  */
+@@ -56,6 +57,9 @@ __libc_fork (void)
    bool multiple_threads = THREAD_GETMEM (THREAD_SELF, header.multiple_threads);
  
+   __run_fork_handlers (atfork_run_prepare);
 +  /* grab ld.so lock BEFORE switching to malloc_atfork */
 +  __rtld_lock_lock_recursive (GL(dl_load_lock));
 +  __rtld_lock_lock_recursive (GL(dl_load_write_lock));
-+
-   /* Run all the registered preparation handlers.  In reverse order.
-      While doing this we build up a list of all the entries.  */
-   struct fork_handler *runp;
-@@ -246,6 +251,10 @@ __libc_fork (void)
  
- 	  allp = allp->next;
- 	}
-+
+   /* If we are not running multiple threads, we do not have to
+      preserve lock state.  If fork runs from a signal handler, only
+@@ -150,6 +154,9 @@ __libc_fork (void)
+ 
+       /* Run the handlers registered for the parent.  */
+       __run_fork_handlers (atfork_run_parent);
 +      /* unlock ld.so last, because we locked it first */
 +      __rtld_lock_unlock_recursive (GL(dl_load_write_lock));
 +      __rtld_lock_unlock_recursive (GL(dl_load_lock));
      }
  
    return pid;
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0028-bits-siginfo-consts.h-enum-definition-for-TRAP_HWBKP.patch b/poky/meta/recipes-core/glibc/glibc/0028-bits-siginfo-consts.h-enum-definition-for-TRAP_HWBKP.patch
index 436c847..fae8d00 100644
--- a/poky/meta/recipes-core/glibc/glibc/0028-bits-siginfo-consts.h-enum-definition-for-TRAP_HWBKP.patch
+++ b/poky/meta/recipes-core/glibc/glibc/0028-bits-siginfo-consts.h-enum-definition-for-TRAP_HWBKP.patch
@@ -1,8 +1,8 @@
-From af3054b3856379d353a779801678f330e1b58c9a Mon Sep 17 00:00:00 2001
-Message-Id: <af3054b3856379d353a779801678f330e1b58c9a.1490183611.git.panand@redhat.com>
+From 38fad3e5ab3b45c56810abd35fa11a72fa10b8f1 Mon Sep 17 00:00:00 2001
 From: Pratyush Anand <panand@redhat.com>
 Date: Wed, 22 Mar 2017 17:02:38 +0530
-Subject: [PATCH] bits/siginfo-consts.h: enum definition for TRAP_HWBKPT is missing
+Subject: [PATCH] bits/siginfo-consts.h: enum definition for TRAP_HWBKPT is
+ missing
 MIME-Version: 1.0
 Content-Type: text/plain; charset=UTF-8
 Content-Transfer-Encoding: 8bit
@@ -29,7 +29,7 @@
  2 files changed, 10 insertions(+), 2 deletions(-)
 
 diff --git a/bits/siginfo-consts.h b/bits/siginfo-consts.h
-index a58ac4b..8448fac 100644
+index 7464c1882b..298314527a 100644
 --- a/bits/siginfo-consts.h
 +++ b/bits/siginfo-consts.h
 @@ -106,8 +106,12 @@ enum
@@ -47,10 +47,10 @@
  # endif
  
 diff --git a/sysdeps/unix/sysv/linux/bits/siginfo-consts.h b/sysdeps/unix/sysv/linux/bits/siginfo-consts.h
-index 525840c..57a9edb 100644
+index 193bd9c471..3fe852bc5f 100644
 --- a/sysdeps/unix/sysv/linux/bits/siginfo-consts.h
 +++ b/sysdeps/unix/sysv/linux/bits/siginfo-consts.h
-@@ -137,8 +137,12 @@ enum
+@@ -141,8 +141,12 @@ enum
  {
    TRAP_BRKPT = 1,		/* Process breakpoint.  */
  #  define TRAP_BRKPT	TRAP_BRKPT
@@ -64,6 +64,3 @@
  };
  # endif
  
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0029-Replace-strncpy-with-memccpy-to-fix-Wstringop-trunca.patch b/poky/meta/recipes-core/glibc/glibc/0029-Replace-strncpy-with-memccpy-to-fix-Wstringop-trunca.patch
deleted file mode 100644
index fa29f41..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0029-Replace-strncpy-with-memccpy-to-fix-Wstringop-trunca.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From 113e0516fbd3ce18253f0423762416d4c4b38fb0 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 22 Mar 2018 17:57:37 -0700
-Subject: [PATCH 29/29] Replace strncpy with memccpy to fix
- -Wstringop-truncation.
-
-	* nis/nss_nisplus/nisplus-parser.c: Replace strncpy with memcpy to
-	avoid -Wstringop-truncation.
----
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Upstream-Status: Submitted [https://sourceware.org/ml/libc-alpha/2018-03/msg00531.html]
-
- nis/nss_nisplus/nisplus-parser.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/nis/nss_nisplus/nisplus-parser.c b/nis/nss_nisplus/nisplus-parser.c
-index 8dc021e73d..b53284f889 100644
---- a/nis/nss_nisplus/nisplus-parser.c
-+++ b/nis/nss_nisplus/nisplus-parser.c
-@@ -87,7 +87,7 @@ _nss_nisplus_parse_pwent (nis_result *result, struct passwd *pw,
-       if (len >= room_left)
- 	goto no_more_room;
- 
--      strncpy (first_unused, numstr, len);
-+      memcpy (first_unused, numstr, len);
-       first_unused[len] = '\0';
-       numstr = first_unused;
-     }
-@@ -103,7 +103,7 @@ _nss_nisplus_parse_pwent (nis_result *result, struct passwd *pw,
-       if (len >= room_left)
- 	goto no_more_room;
- 
--      strncpy (first_unused, numstr, len);
-+      memcpy (first_unused, numstr, len);
-       first_unused[len] = '\0';
-       numstr = first_unused;
-     }
--- 
-2.16.2
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0029-localedef-add-to-archive-uses-a-hard-coded-locale-pa.patch b/poky/meta/recipes-core/glibc/glibc/0029-localedef-add-to-archive-uses-a-hard-coded-locale-pa.patch
new file mode 100644
index 0000000..e17f6aa
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0029-localedef-add-to-archive-uses-a-hard-coded-locale-pa.patch
@@ -0,0 +1,89 @@
+From 865651d2496a90f7ae8e7cc19a2e54b6f17a8ad5 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 3 Aug 2018 09:42:06 -0700
+Subject: [PATCH] localedef --add-to-archive uses a hard-coded locale path
+
+it doesn't exist in normal use, and there's no way to pass an
+alternative filename.
+
+Add a fallback of $LOCALEARCHIVE from the environment, and allow
+creation of new locale archives that are not the system archive.
+
+Upstream-Status: Inappropriate (OE-specific)
+
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ locale/programs/locarchive.c | 37 ++++++++++++++++++++++++++----------
+ 1 file changed, 27 insertions(+), 10 deletions(-)
+
+diff --git a/locale/programs/locarchive.c b/locale/programs/locarchive.c
+index ca332a345f..91f62da662 100644
+--- a/locale/programs/locarchive.c
++++ b/locale/programs/locarchive.c
+@@ -340,12 +340,24 @@ enlarge_archive (struct locarhandle *ah, const struct locarhead *head)
+   struct namehashent *oldnamehashtab;
+   struct locarhandle new_ah;
+   size_t prefix_len = output_prefix ? strlen (output_prefix) : 0;
+-  char archivefname[prefix_len + sizeof (ARCHIVE_NAME)];
+-  char fname[prefix_len + sizeof (ARCHIVE_NAME) + sizeof (".XXXXXX") - 1];
++  char *archivefname;
++  char *fname;
++  char *envarchive = getenv("LOCALEARCHIVE");
+ 
+-  if (output_prefix)
+-    memcpy (archivefname, output_prefix, prefix_len);
+-  strcpy (archivefname + prefix_len, ARCHIVE_NAME);
++  if (envarchive != NULL) 
++    {
++      archivefname = xmalloc(strlen(envarchive) + 1);
++      fname = xmalloc(strlen(envarchive) + sizeof (".XXXXXX"));
++      strcpy (archivefname, envarchive);
++    }
++  else
++    {
++      archivefname = xmalloc(prefix_len + sizeof (ARCHIVE_NAME));
++      fname = xmalloc(prefix_len + sizeof (ARCHIVE_NAME) + sizeof (".XXXXXX") - 1);
++      if (output_prefix)
++        memcpy (archivefname, output_prefix, prefix_len);
++      strcpy (archivefname + prefix_len, ARCHIVE_NAME);
++    }
+   strcpy (stpcpy (fname, archivefname), ".XXXXXX");
+ 
+   /* Not all of the old file has to be mapped.  Change this now this
+@@ -551,6 +563,8 @@ enlarge_archive (struct locarhandle *ah, const struct locarhead *head)
+ 
+   /* Add the information for the new one.  */
+   *ah = new_ah;
++  free(archivefname);
++  free(fname);
+ }
+ 
+ 
+@@ -569,10 +583,13 @@ open_archive (struct locarhandle *ah, bool readonly)
+   /* If ah has a non-NULL fname open that otherwise open the default.  */
+   if (archivefname == NULL)
+     {
+-      archivefname = default_fname;
+-      if (output_prefix)
+-        memcpy (default_fname, output_prefix, prefix_len);
+-      strcpy (default_fname + prefix_len, ARCHIVE_NAME);
++      archivefname = getenv("LOCALEARCHIVE");
++      if (archivefname == NULL) {
++              archivefname = default_fname;
++              if (output_prefix)
++                memcpy (default_fname, output_prefix, prefix_len);
++              strcpy (default_fname + prefix_len, ARCHIVE_NAME);
++      }
+     }
+ 
+   while (1)
+@@ -585,7 +602,7 @@ open_archive (struct locarhandle *ah, bool readonly)
+ 	     the default locale archive we ignore the failure and
+ 	     list an empty archive, otherwise we print an error
+ 	     and exit.  */
+-	  if (errno == ENOENT && archivefname == default_fname)
++	  if (errno == ENOENT)
+ 	    {
+ 	      if (readonly)
+ 		{
diff --git a/poky/meta/recipes-core/glibc/glibc/0030-intl-Emit-no-lines-in-bison-generated-files.patch b/poky/meta/recipes-core/glibc/glibc/0030-intl-Emit-no-lines-in-bison-generated-files.patch
new file mode 100644
index 0000000..db97d91
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0030-intl-Emit-no-lines-in-bison-generated-files.patch
@@ -0,0 +1,31 @@
+From a54c15d0567d547137066f41b1b22eba4875c27b Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 3 Aug 2018 09:44:00 -0700
+Subject: [PATCH] intl: Emit no lines in bison generated files
+
+Improve reproducibility:
+Do not put any #line preprocessor commands in bison generated files.
+These lines contain absolute paths containing file locations on
+the host build machine.
+
+Upstream-Status: Pending
+
+Signed-off-by: Juro Bystricky <juro.bystricky@intel.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ intl/Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/intl/Makefile b/intl/Makefile
+index 672edf1b38..d31888d013 100644
+--- a/intl/Makefile
++++ b/intl/Makefile
+@@ -155,7 +155,7 @@ $(objpfx)tst-gettext6.out: $(objpfx)tst-gettext.out
+ 
+ CPPFLAGS += -D'LOCALEDIR="$(localedir)"' \
+ 	    -D'LOCALE_ALIAS_PATH="$(localedir)"'
+-BISONFLAGS = --yacc --name-prefix=__gettext --output
++BISONFLAGS = --yacc --no-lines --name-prefix=__gettext --output
+ 
+ $(inst_localedir)/locale.alias: locale.alias $(+force)
+ 	$(do-install)
diff --git a/poky/meta/recipes-core/glibc/glibc/0030-plural_c_no_preprocessor_lines.patch b/poky/meta/recipes-core/glibc/glibc/0030-plural_c_no_preprocessor_lines.patch
deleted file mode 100644
index 6f03e1c..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0030-plural_c_no_preprocessor_lines.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-Improve reproducibility:
-Do not put any #line preprocessor commands in bison generated files.
-These lines contain absolute paths containing file locations on
-the host build machine.
-
-Upstream-Status: Pending
-Signed-off-by: Juro Bystricky <juro.bystricky@intel.com>
-
-diff --git a/intl/Makefile b/intl/Makefile
-index 2219717..a203780 100644
---- a/intl/Makefile
-+++ b/intl/Makefile
-@@ -151,7 +151,7 @@ $(objpfx)tst-gettext6.out: $(objpfx)tst-gettext.out
- 
- CPPFLAGS += -D'LOCALEDIR="$(localedir)"' \
- 	    -D'LOCALE_ALIAS_PATH="$(localedir)"'
--BISONFLAGS = --yacc --name-prefix=__gettext --output
-+BISONFLAGS = --yacc --no-lines --name-prefix=__gettext --output
- 
- $(inst_localedir)/locale.alias: locale.alias $(+force)
- 	$(do-install)
diff --git a/poky/meta/recipes-core/glibc/glibc/0031-nativesdk-deprecate-libcrypt.patch b/poky/meta/recipes-core/glibc/glibc/0031-nativesdk-deprecate-libcrypt.patch
deleted file mode 100644
index a9132ed..0000000
--- a/poky/meta/recipes-core/glibc/glibc/0031-nativesdk-deprecate-libcrypt.patch
+++ /dev/null
@@ -1,419 +0,0 @@
-Background information:
-
-https://sourceware.org/ml/libc-alpha/2017-08/msg01257.html
-https://fedoraproject.org/wiki/Changes/Replace_glibc_libcrypt_with_libxcrypt
-
-Upstream-Status: Submitted [libc-alpha@sourceware.org]
-Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-
-From: Zack Weinberg <zackw@panix.com>
-Subject: [PATCH] Deprecate libcrypt and don't build it by default
-
-Back in June, Björn Esser proposed to add OpenBSD-compatible bcrypt
-support to our implementation of crypt(3), and Zack Weinberg replied
-that it might actually make more sense to _remove_ libcrypt from
-glibc, freeing up libcrypt.so.1 and crypt.h to be provided by a
-separate project that could move faster.  (For instance, libxcrypt:
-https://github.com/besser82/libxcrypt)
-
-This patch disables build and installation of libcrypt by default.  It
-can be re-enabled with --enable-obsolete-crypt to configure.  Unlike
-libnsl, we do *not* install a runtime shared library; that's left to
-the replacement.  (Unlike the SunRPC situation, I think we can
-probably drop this code altogether in a release or two.)
-
-The function prototypes for crypt and encrypt are removed from
-unistd.h, and the function prototype for setkey is removed from
-stdlib.h; they do *not* come back with --enable-obsolete-crypt.  This
-means glibc no longer provides the POSIX CRYPT option, and the macro
-_XOPEN_CRYPT is also removed from unistd.h to indicate that.
-(_SC_XOPEN_CRYPT is still defined, but sysconf(_SC_XOPEN_CRYPT) will
-return -1 at runtime.)  These functions are also unconditionally
-removed from conform/data/{stdlib,unistd}.h-data.
-
-	* posix/unistd.h (_XOPEN_CRYPT, crypt, encrypt): Don't declare.
-	* stdlib/stdlib.h (setkey): Don't declare.
-
-	* configure.ac (--enable-obsolete-crypt): New configure option.
-	* configure: Regenerate.
-	* config.make.in (build-obsolete-crypt): New makefile variable.
-	* crypt/Banner: Delete file.
-	* crypt/Makefile: Don't build anything unless
-	$(build-obsolete-crypt) is 'yes'.
-	* sysdeps/sparc/sparc32/sparcv9/multiarch/Makefile: Only add things
-	to libcrypt-sysdep_routines when $(build-obsolete-crypt) is 'yes'.
-	* sysdeps/sparc/sparc64/multiarch/Makefile: Likewise.
-	* sysdeps/unix/sysv/linux/arm/Makefile: Likewise.
-
-	* conform/Makefile: Only include libcrypt.a in linknamespace tests
-	when $(build-obsolete-crypt) is 'yes'.
-	* conform/data/stdlib.h-data (setkey): Don't expect.
-	* conform/data/unistd.h-data (crypt, encrypt): Don't expect.
-	* elf/Makefile: Only perform various tests of libcrypt.so/libcrypt.a
-	when $(build-obsolete-crypt) is 'yes'.
-	* elf/tst-linkall-static.c: Don't include crypt.h when USE_CRYPT
-	is false.
----
- NEWS                                             | 18 ++++++++++++++++++
- config.make.in                                   |  1 +
- configure                                        | 13 +++++++++++++
- configure.ac                                     |  8 ++++++++
- conform/Makefile                                 | 14 ++++++++++----
- conform/data/stdlib.h-data                       |  3 ---
- conform/data/unistd.h-data                       |  6 ------
- crypt/Makefile                                   |  5 +++++
- elf/Makefile                                     | 16 ++++++++++++----
- elf/tst-linkall-static.c                         |  2 ++
- posix/unistd.h                                   | 16 ----------------
- stdlib/stdlib.h                                  |  6 ------
- sysdeps/sparc/sparc32/sparcv9/multiarch/Makefile |  2 ++
- sysdeps/sparc/sparc64/multiarch/Makefile         |  2 ++
- sysdeps/unix/sysv/linux/arm/Makefile             |  2 ++
- 15 files changed, 75 insertions(+), 39 deletions(-)
-
-diff --git a/config.make.in b/config.make.in
-index 9e5e24b2c6..8fe610d04d 100644
---- a/config.make.in
-+++ b/config.make.in
-@@ -82,6 +82,7 @@ mach-interface-list = @mach_interface_list@
- 
- experimental-malloc = @experimental_malloc@
- 
-+build-obsolete-crypt = @build_obsolete_crypt@
- nss-crypt = @libc_cv_nss_crypt@
- static-nss-crypt = @libc_cv_static_nss_crypt@
- 
-diff --git a/configure b/configure
-index 7a8bd3f817..46f6bd7f86 100755
---- a/configure
-+++ b/configure
-@@ -672,6 +672,7 @@ base_machine
- have_tunables
- build_pt_chown
- build_nscd
-+build_obsolete_crypt
- build_obsolete_nsl
- link_obsolete_rpc
- libc_cv_static_nss_crypt
-@@ -782,6 +783,7 @@ enable_experimental_malloc
- enable_nss_crypt
- enable_obsolete_rpc
- enable_obsolete_nsl
-+enable_obsolete_crypt
- enable_systemtap
- enable_build_nscd
- enable_nscd
-@@ -1453,6 +1455,7 @@ Optional Features:
-                           link-time usage
-   --enable-obsolete-nsl   build and install the obsolete libnsl library and
-                           depending NSS modules
-+  --enable-obsolete-crypt build and install the obsolete libcrypt library
-   --enable-systemtap      enable systemtap static probe points [default=no]
-   --disable-build-nscd    disable building and installing the nscd daemon
-   --disable-nscd          library functions will not contact the nscd daemon
-@@ -3632,6 +3635,16 @@ if test "$build_obsolete_nsl" = yes; then
- 
- fi
- 
-+# Check whether --enable-obsolete-crypt was given.
-+if test "${enable_obsolete_crypt+set}" = set; then :
-+  enableval=$enable_obsolete_crypt; build_obsolete_crypt=$enableval
-+else
-+  build_obsolete_crypt=no
-+fi
-+
-+
-+
-+
- # Check whether --enable-systemtap was given.
- if test "${enable_systemtap+set}" = set; then :
-   enableval=$enable_systemtap; systemtap=$enableval
-diff --git a/configure.ac b/configure.ac
-index ca1282a6b3..0142353740 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -378,6 +378,14 @@ if test "$build_obsolete_nsl" = yes; then
-   AC_DEFINE(LINK_OBSOLETE_NSL)
- fi
- 
-+AC_ARG_ENABLE([obsolete-crypt],
-+              AC_HELP_STRING([--enable-obsolete-crypt],
-+                             [build and install the obsolete libcrypt library]),
-+              [build_obsolete_crypt=$enableval],
-+              [build_obsolete_crypt=no])
-+AC_SUBST(build_obsolete_crypt)
-+
-+
- AC_ARG_ENABLE([systemtap],
-               [AS_HELP_STRING([--enable-systemtap],
- 	       [enable systemtap static probe points @<:@default=no@:>@])],
-diff --git a/conform/Makefile b/conform/Makefile
-index 864fdeca21..5ef474fb24 100644
---- a/conform/Makefile
-+++ b/conform/Makefile
-@@ -193,22 +193,28 @@ linknamespace-libs-thr = $(linknamespace-libs-isoc) \
- 			 $(common-objpfx)rt/librt.a $(static-thread-library)
- linknamespace-libs-posix = $(linknamespace-libs-thr) \
- 			   $(common-objpfx)dlfcn/libdl.a
--linknamespace-libs-xsi = $(linknamespace-libs-posix) \
--			 $(common-objpfx)crypt/libcrypt.a
-+linknamespace-libs-xsi = $(linknamespace-libs-posix)
- linknamespace-libs-ISO = $(linknamespace-libs-isoc)
- linknamespace-libs-ISO99 = $(linknamespace-libs-isoc)
- linknamespace-libs-ISO11 = $(linknamespace-libs-isoc)
--linknamespace-libs-XPG4 = $(linknamespace-libs-isoc) \
--			  $(common-objpfx)crypt/libcrypt.a
-+linknamespace-libs-XPG4 = $(linknamespace-libs-isoc)
- linknamespace-libs-XPG42 = $(linknamespace-libs-XPG4)
- linknamespace-libs-POSIX = $(linknamespace-libs-thr)
- linknamespace-libs-UNIX98 = $(linknamespace-libs-xsi)
- linknamespace-libs-XOPEN2K = $(linknamespace-libs-xsi)
- linknamespace-libs-POSIX2008 = $(linknamespace-libs-posix)
- linknamespace-libs-XOPEN2K8 = $(linknamespace-libs-xsi)
-+
-+ifeq ($(build-obsolete-crypt),yes)
-+linknamespace-libs-xsi += $(common-objpfx)crypt/libcrypt.a
-+linknamespace-libs-XPG4 += $(common-objpfx)crypt/libcrypt.a
-+endif
-+
- linknamespace-libs = $(foreach std,$(conformtest-standards),\
- 				   $(linknamespace-libs-$(std)))
- 
-+
-+
- $(linknamespace-symlist-stdlibs-tests): $(objpfx)symlist-stdlibs-%: \
- 					$(linknamespace-libs)
- 	LC_ALL=C $(READELF) -W -s $(linknamespace-libs-$*) > $@; \
-diff --git a/conform/data/stdlib.h-data b/conform/data/stdlib.h-data
-index d8fcccc2fb..6913828196 100644
---- a/conform/data/stdlib.h-data
-+++ b/conform/data/stdlib.h-data
-@@ -149,9 +149,6 @@ function {unsigned short int*} seed48 (unsigned short int[3])
- #if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined XPG4 && !defined XPG42 && !defined UNIX98
- function int setenv (const char*, const char*, int)
- #endif
--#if !defined ISO && !defined ISO99 && !defined ISO11 && !defined POSIX && !defined POSIX2008
--function void setkey (const char*)
--#endif
- #if !defined ISO && !defined ISO99 && !defined ISO11 && !defined XPG4 && !defined POSIX && !defined POSIX2008
- function {char*} setstate (char*)
- #endif
-diff --git a/conform/data/unistd.h-data b/conform/data/unistd.h-data
-index ddf4f25132..aa070528e8 100644
---- a/conform/data/unistd.h-data
-+++ b/conform/data/unistd.h-data
-@@ -437,9 +437,6 @@ function int chroot (const char*)
- function int chown (const char*, uid_t, gid_t)
- function int close (int)
- function size_t confstr (int, char*, size_t)
--#if !defined POSIX && !defined POSIX2008
--function {char*} crypt (const char*, const char*)
--#endif
- #if defined XPG4 || defined XPG42 || defined UNIX98
- function {char*} ctermid (char*)
- function {char*} cuserid (char*)
-@@ -449,9 +446,6 @@ allow cuserid
- #endif
- function int dup (int)
- function int dup2 (int, int)
--#if !defined POSIX && !defined POSIX2008
--function void encrypt (char[64], int)
--#endif
- function int execl (const char*, const char*, ...)
- function int execle (const char*, const char*, ...)
- function int execlp (const char*, const char*, ...)
-diff --git a/crypt/Makefile b/crypt/Makefile
-index 303800df73..024ec2c6ab 100644
---- a/crypt/Makefile
-+++ b/crypt/Makefile
-@@ -22,6 +22,8 @@ subdir	:= crypt
- 
- include ../Makeconfig
- 
-+ifeq ($(build-obsolete-crypt),yes)
-+
- headers := crypt.h
- 
- extra-libs := libcrypt
-@@ -52,9 +54,11 @@ tests += md5test sha256test sha512test
- # machine over a minute.
- xtests = md5test-giant
- endif
-+endif
- 
- include ../Rules
- 
-+ifeq ($(build-obsolete-crypt),yes)
- ifneq ($(nss-crypt),yes)
- md5-routines := md5 $(filter md5%,$(libcrypt-sysdep_routines))
- sha256-routines := sha256 $(filter sha256%,$(libcrypt-sysdep_routines))
-@@ -71,3 +75,4 @@ $(addprefix $(objpfx),$(tests)): $(objpfx)libcrypt.so
- else
- $(addprefix $(objpfx),$(tests)): $(objpfx)libcrypt.a
- endif
-+endif
-diff --git a/elf/Makefile b/elf/Makefile
-index 2a432d8bee..366f7b80ec 100644
---- a/elf/Makefile
-+++ b/elf/Makefile
-@@ -385,15 +385,19 @@ $(objpfx)tst-_dl_addr_inside_object: $(objpfx)dl-addr-obj.os
- CFLAGS-tst-_dl_addr_inside_object.c += $(PIE-ccflag)
- endif
- 
--# By default tst-linkall-static should try to use crypt routines to test
--# static libcrypt use.
--CFLAGS-tst-linkall-static.c += -DUSE_CRYPT=1
-+ifeq ($(build-obsolete-crypt),yes)
-+# If the libcrypt library is being built, tst-linkall-static should
-+# try to use crypt routines to test static libcrypt use.
-+CFLAGS-tst-linkall-static.c = -DUSE_CRYPT=1
- # However, if we are using NSS crypto and we don't have a static
- # library, then we exclude the use of crypt functions in the test.
- # We similarly exclude libcrypt.a from the static link (see below).
- ifeq (yesno,$(nss-crypt)$(static-nss-crypt))
- CFLAGS-tst-linkall-static.c += -UUSE_CRYPT -DUSE_CRYPT=0
- endif
-+else
-+CFLAGS-tst-linkall-static.c = -DUSE_CRYPT=0
-+endif
- 
- include ../Rules
- 
-@@ -1113,8 +1117,10 @@ localplt-built-dso := $(addprefix $(common-objpfx),\
- 				  rt/librt.so \
- 				  dlfcn/libdl.so \
- 				  resolv/libresolv.so \
--				  crypt/libcrypt.so \
- 		       )
-+ifeq ($(build-obsolete-crypt),yes)
-+localplt-built-dso += $(addprefix $(common-objpfx), crypt/libcrypt.so)
-+endif
- ifeq ($(build-mathvec),yes)
- localplt-built-dso += $(addprefix $(common-objpfx), mathvec/libmvec.so)
- endif
-@@ -1395,6 +1401,7 @@ $(objpfx)tst-linkall-static: \
-   $(common-objpfx)resolv/libanl.a \
-   $(static-thread-library)
- 
-+ifeq ($(build-obsolete-crypt),yes)
- # If we are using NSS crypto and we have the ability to link statically
- # then we include libcrypt.a, otherwise we leave out libcrypt.a and
- # link as much as we can into the tst-linkall-static test.  This assumes
-@@ -1410,6 +1417,7 @@ ifeq (no,$(nss-crypt))
- $(objpfx)tst-linkall-static: \
-   $(common-objpfx)crypt/libcrypt.a
- endif
-+endif
- 
- # The application depends on the DSO, and the DSO loads the plugin.
- # The plugin also depends on the DSO. This creates the circular
-diff --git a/elf/tst-linkall-static.c b/elf/tst-linkall-static.c
-index e8df38f74e..0ffae7c723 100644
---- a/elf/tst-linkall-static.c
-+++ b/elf/tst-linkall-static.c
-@@ -18,7 +18,9 @@
- 
- #include <math.h>
- #include <pthread.h>
-+#if USE_CRYPT
- #include <crypt.h>
-+#endif
- #include <resolv.h>
- #include <dlfcn.h>
- #include <utmp.h>
-diff --git a/posix/unistd.h b/posix/unistd.h
-index 4d149f9945..e75ce4d4ec 100644
---- a/posix/unistd.h
-+++ b/posix/unistd.h
-@@ -107,9 +107,6 @@ __BEGIN_DECLS
- /* The X/Open Unix extensions are available.  */
- #define _XOPEN_UNIX	1
- 
--/* Encryption is present.  */
--#define	_XOPEN_CRYPT	1
--
- /* The enhanced internationalization capabilities according to XPG4.2
-    are present.  */
- #define	_XOPEN_ENH_I18N	1
-@@ -1118,20 +1115,7 @@ ssize_t copy_file_range (int __infd, __off64_t *__pinoff,
- extern int fdatasync (int __fildes);
- #endif /* Use POSIX199309 */
- 
--
--/* XPG4.2 specifies that prototypes for the encryption functions must
--   be defined here.  */
- #ifdef	__USE_XOPEN
--/* Encrypt at most 8 characters from KEY using salt to perturb DES.  */
--extern char *crypt (const char *__key, const char *__salt)
--     __THROW __nonnull ((1, 2));
--
--/* Encrypt data in BLOCK in place if EDFLAG is zero; otherwise decrypt
--   block in place.  */
--extern void encrypt (char *__glibc_block, int __edflag)
--     __THROW __nonnull ((1));
--
--
- /* Swab pairs bytes in the first N bytes of the area pointed to by
-    FROM and copy the result to TO.  The value of TO must not be in the
-    range [FROM - N + 1, FROM - 1].  If N is odd the first byte in FROM
-diff --git a/stdlib/stdlib.h b/stdlib/stdlib.h
-index 6b1ead31e0..8e23e93557 100644
---- a/stdlib/stdlib.h
-+++ b/stdlib/stdlib.h
-@@ -958,12 +958,6 @@ extern int getsubopt (char **__restrict __optionp,
- #endif
- 
- 
--#ifdef __USE_XOPEN
--/* Setup DES tables according KEY.  */
--extern void setkey (const char *__key) __THROW __nonnull ((1));
--#endif
--
--
- /* X/Open pseudo terminal handling.  */
- 
- #ifdef __USE_XOPEN2KXSI
-diff --git a/sysdeps/sparc/sparc32/sparcv9/multiarch/Makefile b/sysdeps/sparc/sparc32/sparcv9/multiarch/Makefile
-index a6d08f3a00..d8b8297fb0 100644
---- a/sysdeps/sparc/sparc32/sparcv9/multiarch/Makefile
-+++ b/sysdeps/sparc/sparc32/sparcv9/multiarch/Makefile
-@@ -1,6 +1,8 @@
- ifeq ($(subdir),crypt)
-+ifeq ($(build-obsolete-crypt),yes)
- libcrypt-sysdep_routines += md5-crop sha256-crop sha512-crop
- endif
-+endif
- 
- ifeq ($(subdir),locale)
- localedef-aux += md5-crop
-diff --git a/sysdeps/sparc/sparc64/multiarch/Makefile b/sysdeps/sparc/sparc64/multiarch/Makefile
-index eaf758e7aa..0198f9886f 100644
---- a/sysdeps/sparc/sparc64/multiarch/Makefile
-+++ b/sysdeps/sparc/sparc64/multiarch/Makefile
-@@ -1,6 +1,8 @@
- ifeq ($(subdir),crypt)
-+ifeq ($(build-obsolete-crypt),yes)
- libcrypt-sysdep_routines += md5-crop sha256-crop sha512-crop
- endif
-+endif
- 
- ifeq ($(subdir),locale)
- localedef-aux += md5-crop
-diff --git a/sysdeps/unix/sysv/linux/arm/Makefile b/sysdeps/unix/sysv/linux/arm/Makefile
-index 4adc35de04..6cab4f3a31 100644
---- a/sysdeps/unix/sysv/linux/arm/Makefile
-+++ b/sysdeps/unix/sysv/linux/arm/Makefile
-@@ -19,8 +19,10 @@ endif
- # Add a syscall function to each library that needs one.
- 
- ifeq ($(subdir),crypt)
-+ifeq ($(build-obsolete-crypt),yes)
- libcrypt-sysdep_routines += libc-do-syscall
- endif
-+endif
- 
- ifeq ($(subdir),rt)
- librt-sysdep_routines += libc-do-syscall
--- 
-2.16.0
-
diff --git a/poky/meta/recipes-core/glibc/glibc/0031-sysdeps-ieee754-prevent-maybe-uninitialized-errors-w.patch b/poky/meta/recipes-core/glibc/glibc/0031-sysdeps-ieee754-prevent-maybe-uninitialized-errors-w.patch
new file mode 100644
index 0000000..61f55d4
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0031-sysdeps-ieee754-prevent-maybe-uninitialized-errors-w.patch
@@ -0,0 +1,258 @@
+From 546b46c309a52ed74dc906114b1e984bb9703d74 Mon Sep 17 00:00:00 2001
+From: Martin Jansa <Martin.Jansa@gmail.com>
+Date: Fri, 14 Sep 2018 23:23:03 +0000
+Subject: [PATCH] sysdeps/ieee754: prevent maybe-uninitialized errors with -O
+ [BZ #19444]
+
+With -O included in CFLAGS it fails to build with:
+
+../sysdeps/ieee754/ldbl-96/e_jnl.c: In function '__ieee754_jnl':
+../sysdeps/ieee754/ldbl-96/e_jnl.c:146:20: error: 'temp' may be used uninitialized in this function [-Werror=maybe-uninitialized]
+      b = invsqrtpi * temp / sqrtl (x);
+          ~~~~~~~~~~^~~~~~
+../sysdeps/ieee754/ldbl-96/e_jnl.c: In function '__ieee754_ynl':
+../sysdeps/ieee754/ldbl-96/e_jnl.c:375:16: error: 'temp' may be used uninitialized in this function [-Werror=maybe-uninitialized]
+  b = invsqrtpi * temp / sqrtl (x);
+      ~~~~~~~~~~^~~~~~
+../sysdeps/ieee754/dbl-64/e_jn.c: In function '__ieee754_jn':
+../sysdeps/ieee754/dbl-64/e_jn.c:113:20: error: 'temp' may be used uninitialized in this function [-Werror=maybe-uninitialized]
+      b = invsqrtpi * temp / sqrt (x);
+          ~~~~~~~~~~^~~~~~
+../sysdeps/ieee754/dbl-64/e_jn.c: In function '__ieee754_yn':
+../sysdeps/ieee754/dbl-64/e_jn.c:320:16: error: 'temp' may be used uninitialized in this function [-Werror=maybe-uninitialized]
+  b = invsqrtpi * temp / sqrt (x);
+      ~~~~~~~~~~^~~~~~
+
+Build tested with Yocto for ARM, AARCH64, X86, X86_64, PPC, MIPS, MIPS64
+with -O, -O1, -Os.
+For soft-fp ARM it needs one more fix for -O1:
+https://sourceware.org/ml/libc-alpha/2018-09/msg00300.html
+For AARCH64 it needs one more fix in locale for -Os.
+
+        [BZ #23716]
+        * sysdeps/ieee754/dbl-96/e_jnl.c: Fix build with -O
+        * sysdeps/ieee754/ldbl-96/e_jnl.c: Likewise.
+        * sysdeps/ieee754/ldbl-128/e_jnl.c: Likewise.
+        * sysdeps/ieee754/ldbl-128ibm/e_jnl.c: Likewise.
+
+Work around the issue instead of removing -O like we do with
+SELECTED_OPTIMIZATION
+
+Upstream-Status: Submitted [https://www.sourceware.org/ml/libc-alpha/2018-09/msg00299.html]
+
+Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
+---
+ ChangeLog                           |  7 +++++++
+ sysdeps/ieee754/dbl-64/e_jn.c       | 21 +++++++++++++++++++++
+ sysdeps/ieee754/ldbl-128/e_jnl.c    | 21 +++++++++++++++++++++
+ sysdeps/ieee754/ldbl-128ibm/e_jnl.c | 21 +++++++++++++++++++++
+ sysdeps/ieee754/ldbl-96/e_jnl.c     | 21 +++++++++++++++++++++
+ 5 files changed, 91 insertions(+)
+
+diff --git a/ChangeLog b/ChangeLog
+index 11a9b8d98e..922e916f2c 100644
+--- a/ChangeLog
++++ b/ChangeLog
+@@ -1,3 +1,10 @@
++2018-09-29  Martin Jansa  <Martin.Jansa@gmail.com>
++	Partial fix for [BZ #23716]
++	* sysdeps/ieee754/dbl-96/e_jnl.c: Fix build with -O
++	* sysdeps/ieee754/ldbl-96/e_jnl.c: Likewise.
++	* sysdeps/ieee754/ldbl-128/e_jnl.c: Likewise.
++	* sysdeps/ieee754/ldbl-128ibm/e_jnl.c: Likewise.
++
+ 2018-09-28  Adhemerval Zanella  <adhemerval.zanella@linaro.org>
+ 
+ 	[BZ #23579]
+diff --git a/sysdeps/ieee754/dbl-64/e_jn.c b/sysdeps/ieee754/dbl-64/e_jn.c
+index 9181b22bb8..9ff52c737f 100644
+--- a/sysdeps/ieee754/dbl-64/e_jn.c
++++ b/sysdeps/ieee754/dbl-64/e_jn.c
+@@ -42,6 +42,7 @@
+ #include <math-narrow-eval.h>
+ #include <math_private.h>
+ #include <math-underflow.h>
++#include <libc-diag.h>
+ 
+ static const double
+   invsqrtpi = 5.64189583547756279280e-01, /* 0x3FE20DD7, 0x50429B6D */
+@@ -109,7 +110,17 @@ __ieee754_jn (int n, double x)
+ 	      case 2: temp = -c - s; break;
+ 	      case 3: temp = c - s; break;
+ 	      }
++	    /* With GCC 8 (and older) when compiling with -O the compiler
++	       warns that the variable 'temp', may be used uninitialized.
++	       The switch above covers all possible values of n & 3
++	       but GCC without VRP enabled isn't able to figure out the
++	       range of possible values is [0,3] as explained in:
++	       https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69230
++	       so it's false possitive with -O1 and lower. */
++	    DIAG_PUSH_NEEDS_COMMENT;
++	    DIAG_IGNORE_NEEDS_COMMENT (8, "-Wmaybe-uninitialized");
+ 	    b = invsqrtpi * temp / sqrt (x);
++	    DIAG_POP_NEEDS_COMMENT;
+ 	  }
+ 	else
+ 	  {
+@@ -316,7 +327,17 @@ __ieee754_yn (int n, double x)
+ 	  case 2: temp = -s + c; break;
+ 	  case 3: temp = s + c; break;
+ 	  }
++	/* With GCC 8 (and older) when compiling with -O the compiler
++	   warns that the variable 'temp', may be used uninitialized.
++	   The switch above covers all possible values of n & 3
++	   but GCC without VRP enabled isn't able to figure out the
++	   range of possible values is [0,3] as explained in:
++	   https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69230
++	   so it's false possitive with -O1 and lower. */
++	DIAG_PUSH_NEEDS_COMMENT;
++	DIAG_IGNORE_NEEDS_COMMENT (8, "-Wmaybe-uninitialized");
+ 	b = invsqrtpi * temp / sqrt (x);
++	DIAG_POP_NEEDS_COMMENT;
+       }
+     else
+       {
+diff --git a/sysdeps/ieee754/ldbl-128/e_jnl.c b/sysdeps/ieee754/ldbl-128/e_jnl.c
+index 7739eec291..8706a11575 100644
+--- a/sysdeps/ieee754/ldbl-128/e_jnl.c
++++ b/sysdeps/ieee754/ldbl-128/e_jnl.c
+@@ -61,6 +61,7 @@
+ #include <math.h>
+ #include <math_private.h>
+ #include <math-underflow.h>
++#include <libc-diag.h>
+ 
+ static const _Float128
+   invsqrtpi = L(5.6418958354775628694807945156077258584405E-1),
+@@ -150,7 +151,17 @@ __ieee754_jnl (int n, _Float128 x)
+ 		temp = c - s;
+ 		break;
+ 	      }
++	    /* With GCC 8 (and older) when compiling with -O the compiler
++	       warns that the variable 'temp', may be used uninitialized.
++	       The switch above covers all possible values of n & 3
++	       but GCC without VRP enabled isn't able to figure out the
++	       range of possible values is [0,3] as explained in:
++	       https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69230
++	       so it's false possitive with -O1 and lower. */
++	    DIAG_PUSH_NEEDS_COMMENT;
++	    DIAG_IGNORE_NEEDS_COMMENT (8, "-Wmaybe-uninitialized");
+ 	    b = invsqrtpi * temp / sqrtl (x);
++	    DIAG_POP_NEEDS_COMMENT;
+ 	  }
+ 	else
+ 	  {
+@@ -386,7 +397,17 @@ __ieee754_ynl (int n, _Float128 x)
+ 	    temp = s + c;
+ 	    break;
+ 	  }
++	/* With GCC 8 (and older) when compiling with -O the compiler
++	   warns that the variable 'temp', may be used uninitialized.
++	   The switch above covers all possible values of n & 3
++	   but GCC without VRP enabled isn't able to figure out the
++	   range of possible values is [0,3] as explained in:
++	   https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69230
++	   so it's false possitive with -O1 and lower. */
++	DIAG_PUSH_NEEDS_COMMENT;
++	DIAG_IGNORE_NEEDS_COMMENT (8, "-Wmaybe-uninitialized");
+ 	b = invsqrtpi * temp / sqrtl (x);
++	DIAG_POP_NEEDS_COMMENT;
+       }
+     else
+       {
+diff --git a/sysdeps/ieee754/ldbl-128ibm/e_jnl.c b/sysdeps/ieee754/ldbl-128ibm/e_jnl.c
+index 71b3addfba..3226d02309 100644
+--- a/sysdeps/ieee754/ldbl-128ibm/e_jnl.c
++++ b/sysdeps/ieee754/ldbl-128ibm/e_jnl.c
+@@ -61,6 +61,7 @@
+ #include <math.h>
+ #include <math_private.h>
+ #include <math-underflow.h>
++#include <libc-diag.h>
+ 
+ static const long double
+   invsqrtpi = 5.6418958354775628694807945156077258584405E-1L,
+@@ -150,7 +151,17 @@ __ieee754_jnl (int n, long double x)
+ 		temp = c - s;
+ 		break;
+ 	      }
++	    /* With GCC 8 (and older) when compiling with -O the compiler
++	       warns that the variable 'temp', may be used uninitialized.
++	       The switch above covers all possible values of n & 3
++	       but GCC without VRP enabled isn't able to figure out the
++	       range of possible values is [0,3] as explained in:
++	       https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69230
++	       so it's false possitive with -O1 and lower. */
++	    DIAG_PUSH_NEEDS_COMMENT;
++	    DIAG_IGNORE_NEEDS_COMMENT (8, "-Wmaybe-uninitialized");
+ 	    b = invsqrtpi * temp / sqrtl (x);
++	    DIAG_POP_NEEDS_COMMENT;
+ 	  }
+ 	else
+ 	  {
+@@ -386,7 +397,17 @@ __ieee754_ynl (int n, long double x)
+ 	    temp = s + c;
+ 	    break;
+ 	  }
++	/* With GCC 8 (and older) when compiling with -O the compiler
++	   warns that the variable 'temp', may be used uninitialized.
++	   The switch above covers all possible values of n & 3
++	   but GCC without VRP enabled isn't able to figure out the
++	   range of possible values is [0,3] as explained in:
++	   https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69230
++	   so it's false possitive with -O1 and lower. */
++	DIAG_PUSH_NEEDS_COMMENT;
++	DIAG_IGNORE_NEEDS_COMMENT (8, "-Wmaybe-uninitialized");
+ 	b = invsqrtpi * temp / sqrtl (x);
++	DIAG_POP_NEEDS_COMMENT;
+       }
+     else
+       {
+diff --git a/sysdeps/ieee754/ldbl-96/e_jnl.c b/sysdeps/ieee754/ldbl-96/e_jnl.c
+index 394921f564..da5c2cc93e 100644
+--- a/sysdeps/ieee754/ldbl-96/e_jnl.c
++++ b/sysdeps/ieee754/ldbl-96/e_jnl.c
+@@ -61,6 +61,7 @@
+ #include <math.h>
+ #include <math_private.h>
+ #include <math-underflow.h>
++#include <libc-diag.h>
+ 
+ static const long double
+   invsqrtpi = 5.64189583547756286948079e-1L, two = 2.0e0L, one = 1.0e0L;
+@@ -143,7 +144,17 @@ __ieee754_jnl (int n, long double x)
+ 		temp = c - s;
+ 		break;
+ 	      }
++	    /* With GCC 8 (and older) when compiling with -O the compiler
++	       warns that the variable 'temp', may be used uninitialized.
++	       The switch above covers all possible values of n & 3
++	       but GCC without VRP enabled isn't able to figure out the
++	       range of possible values is [0,3] as explained in:
++	       https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69230
++	       so it's false possitive with -O1 and lower. */
++	    DIAG_PUSH_NEEDS_COMMENT;
++	    DIAG_IGNORE_NEEDS_COMMENT (8, "-Wmaybe-uninitialized");
+ 	    b = invsqrtpi * temp / sqrtl (x);
++	    DIAG_POP_NEEDS_COMMENT;
+ 	  }
+ 	else
+ 	  {
+@@ -372,7 +383,17 @@ __ieee754_ynl (int n, long double x)
+ 	    temp = s + c;
+ 	    break;
+ 	  }
++	/* With GCC 8 (and older) when compiling with -O the compiler
++	   warns that the variable 'temp', may be used uninitialized.
++	   The switch above covers all possible values of n & 3
++	   but GCC without VRP enabled isn't able to figure out the
++	   range of possible values is [0,3] as explained in:
++	   https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69230
++	   so it's false possitive with -O1 and lower. */
++	DIAG_PUSH_NEEDS_COMMENT;
++	DIAG_IGNORE_NEEDS_COMMENT (8, "-Wmaybe-uninitialized");
+ 	b = invsqrtpi * temp / sqrtl (x);
++	DIAG_POP_NEEDS_COMMENT;
+       }
+     else
+       {
diff --git a/poky/meta/recipes-core/glibc/glibc/0032-sysdeps-ieee754-soft-fp-ignore-maybe-uninitialized-w.patch b/poky/meta/recipes-core/glibc/glibc/0032-sysdeps-ieee754-soft-fp-ignore-maybe-uninitialized-w.patch
new file mode 100644
index 0000000..99cd250
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0032-sysdeps-ieee754-soft-fp-ignore-maybe-uninitialized-w.patch
@@ -0,0 +1,100 @@
+From 618668540e263c09b0eb28131dde7b4500158fd4 Mon Sep 17 00:00:00 2001
+From: Martin Jansa <Martin.Jansa@gmail.com>
+Date: Sun, 16 Sep 2018 12:39:22 +0000
+Subject: [PATCH] sysdeps/ieee754/soft-fp: ignore maybe-uninitialized with -O
+ [BZ #19444]
+
+* with -O, -O1, -Os it fails with:
+
+In file included from ../soft-fp/soft-fp.h:318,
+                 from ../sysdeps/ieee754/soft-fp/s_fdiv.c:28:
+../sysdeps/ieee754/soft-fp/s_fdiv.c: In function '__fdiv':
+../soft-fp/op-2.h:98:25: error: 'R_f1' may be used uninitialized in this function [-Werror=maybe-uninitialized]
+        X##_f0 = (X##_f1 << (_FP_W_TYPE_SIZE - (N)) | X##_f0 >> (N) \
+                         ^~
+../sysdeps/ieee754/soft-fp/s_fdiv.c:38:14: note: 'R_f1' was declared here
+   FP_DECL_D (R);
+              ^
+../soft-fp/op-2.h:37:36: note: in definition of macro '_FP_FRAC_DECL_2'
+   _FP_W_TYPE X##_f0 _FP_ZERO_INIT, X##_f1 _FP_ZERO_INIT
+                                    ^
+../soft-fp/double.h:95:24: note: in expansion of macro '_FP_DECL'
+ # define FP_DECL_D(X)  _FP_DECL (2, X)
+                        ^~~~~~~~
+../sysdeps/ieee754/soft-fp/s_fdiv.c:38:3: note: in expansion of macro 'FP_DECL_D'
+   FP_DECL_D (R);
+   ^~~~~~~~~
+../soft-fp/op-2.h:101:17: error: 'R_f0' may be used uninitialized in this function [-Werror=maybe-uninitialized]
+       : (X##_f0 << (_FP_W_TYPE_SIZE - (N))) != 0)); \
+                 ^~
+../sysdeps/ieee754/soft-fp/s_fdiv.c:38:14: note: 'R_f0' was declared here
+   FP_DECL_D (R);
+              ^
+../soft-fp/op-2.h:37:14: note: in definition of macro '_FP_FRAC_DECL_2'
+   _FP_W_TYPE X##_f0 _FP_ZERO_INIT, X##_f1 _FP_ZERO_INIT
+              ^
+../soft-fp/double.h:95:24: note: in expansion of macro '_FP_DECL'
+ # define FP_DECL_D(X)  _FP_DECL (2, X)
+                        ^~~~~~~~
+../sysdeps/ieee754/soft-fp/s_fdiv.c:38:3: note: in expansion of macro 'FP_DECL_D'
+   FP_DECL_D (R);
+   ^~~~~~~~~
+
+Build tested with Yocto for ARM, AARCH64, X86, X86_64, PPC, MIPS, MIPS64
+with -O, -O1, -Os.
+For AARCH64 it needs one more fix in locale for -Os.
+
+	Partial fix for [BZ #23716]
+	* sysdeps/ieee754/soft-fp/s_fdiv.c: Fix build with -O
+
+Work around the issue instead of removing -O like we do with
+SELECTED_OPTIMIZATION
+
+Upstream-Status: Submitted [https://www.sourceware.org/ml/libc-alpha/2018-09/msg00300.html]
+
+Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
+---
+ ChangeLog                        |  4 ++++
+ sysdeps/ieee754/soft-fp/s_fdiv.c | 12 ++++++++++++
+ 2 files changed, 16 insertions(+)
+
+diff --git a/ChangeLog b/ChangeLog
+index 922e916f2c..216336edc9 100644
+--- a/ChangeLog
++++ b/ChangeLog
+@@ -1,3 +1,7 @@
++2018-09-30  Martin Jansa  <Martin.Jansa@gmail.com>
++	Partial fix for [BZ #23716]
++	* sysdeps/ieee754/soft-fp/s_fdiv.c: Fix build with -O.
++
+ 2018-09-29  Martin Jansa  <Martin.Jansa@gmail.com>
+ 	Partial fix for [BZ #23716]
+ 	* sysdeps/ieee754/dbl-96/e_jnl.c: Fix build with -O
+diff --git a/sysdeps/ieee754/soft-fp/s_fdiv.c b/sysdeps/ieee754/soft-fp/s_fdiv.c
+index 341339f5ed..14655b77da 100644
+--- a/sysdeps/ieee754/soft-fp/s_fdiv.c
++++ b/sysdeps/ieee754/soft-fp/s_fdiv.c
+@@ -25,6 +25,16 @@
+ #undef fdivl
+ 
+ #include <math-narrow.h>
++
++#include <libc-diag.h>
++/* R_f[01] are not set in cases where it is not used in packing, but the
++   compiler does not see that it is set in all cases where it is
++   used, resulting in warnings that it may be used uninitialized.
++   The location of the warning differs in different versions of GCC,
++   it may be where R is defined using a macro or it may be where the
++   macro is defined.  */
++DIAG_PUSH_NEEDS_COMMENT;
++DIAG_IGNORE_NEEDS_COMMENT (8, "-Wmaybe-uninitialized");
+ #include <soft-fp.h>
+ #include <single.h>
+ #include <double.h>
+@@ -53,4 +63,6 @@ __fdiv (double x, double y)
+   CHECK_NARROW_DIV (ret, x, y);
+   return ret;
+ }
++DIAG_POP_NEEDS_COMMENT;
++
+ libm_alias_float_double (div)
diff --git a/poky/meta/recipes-core/glibc/glibc/0033-locale-prevent-maybe-uninitialized-errors-with-Os-BZ.patch b/poky/meta/recipes-core/glibc/glibc/0033-locale-prevent-maybe-uninitialized-errors-with-Os-BZ.patch
new file mode 100644
index 0000000..31058ca
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0033-locale-prevent-maybe-uninitialized-errors-with-Os-BZ.patch
@@ -0,0 +1,68 @@
+From cbada1a1b218c1ef61d0eb4363fad7598e6509d6 Mon Sep 17 00:00:00 2001
+From: Martin Jansa <Martin.Jansa@gmail.com>
+Date: Sun, 30 Sep 2018 09:16:48 +0000
+Subject: [PATCH] locale: prevent maybe-uninitialized errors with -Os [BZ
+ #19444]
+
+Fixes following error when building for aarch64 with -Os:
+| In file included from strcoll_l.c:43:
+| strcoll_l.c: In function '__strcoll_l':
+| ../locale/weight.h:31:26: error: 'seq2.back_us' may be used uninitialized in this function [-Werror=maybe-uninitialized]
+|    int_fast32_t i = table[*(*cpp)++];
+|                           ^~~~~~~~~
+| strcoll_l.c:304:18: note: 'seq2.back_us' was declared here
+|    coll_seq seq1, seq2;
+|                   ^~~~
+| In file included from strcoll_l.c:43:
+| ../locale/weight.h:31:26: error: 'seq1.back_us' may be used uninitialized in this function [-Werror=maybe-uninitialized]
+|    int_fast32_t i = table[*(*cpp)++];
+|                           ^~~~~~~~~
+| strcoll_l.c:304:12: note: 'seq1.back_us' was declared here
+|    coll_seq seq1, seq2;
+|             ^~~~
+
+        Partial fix for [BZ #23716]
+        * locale/weight.h: Fix build with -Os.
+
+Work around the issue instead of removing -O like we do with
+SELECTED_OPTIMIZATION
+
+Upstream-Status: Submitted [https://www.sourceware.org/ml/libc-alpha/2018-09/msg00539.html]
+
+Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
+---
+ ChangeLog       | 4 ++++
+ locale/weight.h | 7 +++++++
+ 2 files changed, 11 insertions(+)
+
+diff --git a/ChangeLog b/ChangeLog
+index 216336edc9..84fbbf47ed 100644
+--- a/ChangeLog
++++ b/ChangeLog
+@@ -1,3 +1,7 @@
++2018-09-30  Martin Jansa  <Martin.Jansa@gmail.com>
++	Partial fix for [BZ #23716]
++	* locale/weight.h: Fix build with -Os.
++
+ 2018-09-30  Martin Jansa  <Martin.Jansa@gmail.com>
+ 	Partial fix for [BZ #23716]
+ 	* sysdeps/ieee754/soft-fp/s_fdiv.c: Fix build with -O.
+diff --git a/locale/weight.h b/locale/weight.h
+index 6028d3595e..10bcea25e5 100644
+--- a/locale/weight.h
++++ b/locale/weight.h
+@@ -28,7 +28,14 @@ findidx (const int32_t *table,
+ 	 const unsigned char *extra,
+ 	 const unsigned char **cpp, size_t len)
+ {
++  /* With GCC 8 when compiling with -Os the compiler warns that
++     seq1.back_us and seq2.back_us might be used uninitialized.
++     This uninitialized use is impossible for the same reason
++     as described in comments in locale/weightwc.h.  */
++  DIAG_PUSH_NEEDS_COMMENT;
++  DIAG_IGNORE_Os_NEEDS_COMMENT (8, "-Wmaybe-uninitialized");
+   int_fast32_t i = table[*(*cpp)++];
++  DIAG_POP_NEEDS_COMMENT;
+   const unsigned char *cp;
+   const unsigned char *usrc;
+ 
diff --git a/poky/meta/recipes-core/glibc/glibc/0034-inject-file-assembly-directives.patch b/poky/meta/recipes-core/glibc/glibc/0034-inject-file-assembly-directives.patch
new file mode 100644
index 0000000..55eba2d
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/0034-inject-file-assembly-directives.patch
@@ -0,0 +1,272 @@
+Currently, non-IA builds are not reproducibile since build paths are 
+being injected into the debug symbols. These are coming from the use of
+.S assembler files during the glibc build. No STT_FILE section is added
+during the assembly but when linking, ld decides to add one to aid 
+debugging and ensure references between the different object files its
+linking remain clear.
+
+We can avoid this by injecting a file header into the assembler files
+ahead of time, choosing a filename which does not contain build system
+paths.
+
+This is a bit of a workaround/hack but does significantly reduce the
+build system references in target binaries for the non-IA architectures
+which use .S files.
+
+RP
+2018/10/3
+
+Upstream-Status: Pending
+
+diff --git a/csu/abi-note.S b/csu/abi-note.S
+index 5d0ca7803d..8ce41581b1 100644
+--- a/csu/abi-note.S
++++ b/csu/abi-note.S
+@@ -56,6 +56,8 @@ offset	length	contents
+ #include <config.h>
+ #include <abi-tag.h>		/* OS-specific ABI tag value */
+ 
++	.file "abi-note.S"
++
+ /* The linker (GNU ld 2.8 and later) recognizes an allocated section whose
+    name begins with `.note' and creates a PT_NOTE program header entry
+    pointing at it. */
+diff --git a/sysdeps/aarch64/crti.S b/sysdeps/aarch64/crti.S
+index 2b213758b2..736f33e314 100644
+--- a/sysdeps/aarch64/crti.S
++++ b/sysdeps/aarch64/crti.S
+@@ -50,6 +50,8 @@
+ # define PREINIT_FUNCTION_WEAK 1
+ #endif
+ 
++    .file "crti.S"
++
+ #if PREINIT_FUNCTION_WEAK
+ 	weak_extern (PREINIT_FUNCTION)
+ #else
+diff --git a/sysdeps/aarch64/crtn.S b/sysdeps/aarch64/crtn.S
+index d72300af80..cb249bf3ca 100644
+--- a/sysdeps/aarch64/crtn.S
++++ b/sysdeps/aarch64/crtn.S
+@@ -37,6 +37,8 @@
+ /* crtn.S puts function epilogues in the .init and .fini sections
+    corresponding to the prologues in crti.S. */
+ 
++	.file "crtn.S"
++
+ 	.section .init,"ax",%progbits
+ 	ldp	x29, x30, [sp], 16
+ 	RET
+diff --git a/sysdeps/aarch64/start.S b/sysdeps/aarch64/start.S
+index bad000f555..5957c028cd 100644
+--- a/sysdeps/aarch64/start.S
++++ b/sysdeps/aarch64/start.S
+@@ -18,6 +18,8 @@
+ 
+ #include <sysdep.h>
+ 
++	.file "start.S"
++
+ /* This is the canonical entry point, usually the first thing in the text
+    segment.
+ 
+diff --git a/sysdeps/unix/sysv/linux/aarch64/__read_tp.S b/sysdeps/unix/sysv/linux/aarch64/__read_tp.S
+index 92fc0191a5..715bfcb9e4 100644
+--- a/sysdeps/unix/sysv/linux/aarch64/__read_tp.S
++++ b/sysdeps/unix/sysv/linux/aarch64/__read_tp.S
+@@ -18,6 +18,8 @@
+ 
+ #include <sysdep.h>
+ 
++	.file "__read_tp.S"
++
+ 	.hidden __read_tp
+ ENTRY (__read_tp)
+ 	mrs	x0, tpidr_el0
+diff --git a/sysdeps/aarch64/dl-tlsdesc.S b/sysdeps/aarch64/dl-tlsdesc.S
+index 43a62ef307..42f85cdde9 100644
+--- a/sysdeps/aarch64/dl-tlsdesc.S
++++ b/sysdeps/aarch64/dl-tlsdesc.S
+@@ -22,6 +22,8 @@
+ #include <tls.h>
+ #include "tlsdesc.h"
+ 
++	.file "dl-tlsdesc.S"
++
+ #define NSAVEDQREGPAIRS	16
+ #define SAVE_Q_REGISTERS				\
+ 	stp	q0, q1,	[sp, #-32*NSAVEDQREGPAIRS]!;	\
+diff --git a/sysdeps/aarch64/dl-trampoline.S b/sysdeps/aarch64/dl-trampoline.S
+index a86d0722d4..92edab1d01 100644
+--- a/sysdeps/aarch64/dl-trampoline.S
++++ b/sysdeps/aarch64/dl-trampoline.S
+@@ -21,6 +21,8 @@
+ 
+ #include "dl-link.h"
+ 
++	.file "dl-trampoline.S"
++
+ #define ip0 x16
+ #define ip0l PTR_REG (16)
+ #define ip1 x17
+diff --git a/sysdeps/arm/abi-note.S b/sysdeps/arm/abi-note.S
+index 07bd4c4619..7213b16f27 100644
+--- a/sysdeps/arm/abi-note.S
++++ b/sysdeps/arm/abi-note.S
+@@ -1,3 +1,5 @@
++	.file "abi-note.S"
++
+ /* Tag_ABI_align8_preserved: This code preserves 8-byte
+    alignment in any callee.  */
+ 	.eabi_attribute 25, 1
+diff --git a/sysdeps/arm/crti.S b/sysdeps/arm/crti.S
+index a1424d0333..bca1dab256 100644
+--- a/sysdeps/arm/crti.S
++++ b/sysdeps/arm/crti.S
+@@ -57,6 +57,8 @@
+ 	.hidden PREINIT_FUNCTION
+ #endif
+ 
++    .file "crti.S"
++
+ #if PREINIT_FUNCTION_WEAK
+ 	.p2align 2
+ 	.type call_weak_fn, %function
+diff --git a/sysdeps/arm/crtn.S b/sysdeps/arm/crtn.S
+index 26027693ce..65a0502826 100644
+--- a/sysdeps/arm/crtn.S
++++ b/sysdeps/arm/crtn.S
+@@ -37,6 +37,8 @@
+ #define NO_THUMB
+ #include <sysdep.h>
+ 
++    .file "crtn.S"
++
+ /* crtn.S puts function epilogues in the .init and .fini sections
+    corresponding to the prologues in crti.S. */
+ 
+diff --git a/sysdeps/arm/dl-tlsdesc.S b/sysdeps/arm/dl-tlsdesc.S
+index 056e17d52d..a98c68dfb9 100644
+--- a/sysdeps/arm/dl-tlsdesc.S
++++ b/sysdeps/arm/dl-tlsdesc.S
+@@ -21,6 +21,8 @@
+ #include <tls.h>
+ #include "tlsdesc.h"
+ 
++	.file "dl-tlsdesc.S"
++
+ 	.text
+ 	@ emit debug information with cfi
+ 	@ use arm-specific pseudos for unwinding itself
+diff --git a/sysdeps/arm/dl-trampoline.S b/sysdeps/arm/dl-trampoline.S
+index c731b01286..4b37b25344 100644
+--- a/sysdeps/arm/dl-trampoline.S
++++ b/sysdeps/arm/dl-trampoline.S
+@@ -21,6 +21,8 @@
+ #include <sysdep.h>
+ #include <libc-symbols.h>
+ 
++	.file "dl-trampoline.S"
++
+ 	.text
+ 	.globl _dl_runtime_resolve
+ 	.type _dl_runtime_resolve, #function
+diff --git a/sysdeps/arm/start.S b/sysdeps/arm/start.S
+index adef090717..d22e4128e0 100644
+--- a/sysdeps/arm/start.S
++++ b/sysdeps/arm/start.S
+@@ -57,6 +57,8 @@
+ 					NULL
+ */
+ 
++	.file "start.S"
++
+ /* Tag_ABI_align8_preserved: This code preserves 8-byte
+    alignment in any callee.  */
+ 	.eabi_attribute 25, 1
+diff --git a/sysdeps/unix/sysv/linux/arm/aeabi_read_tp.S b/sysdeps/unix/sysv/linux/arm/aeabi_read_tp.S
+index 871702317a..20a942dbac 100644
+--- a/sysdeps/unix/sysv/linux/arm/aeabi_read_tp.S
++++ b/sysdeps/unix/sysv/linux/arm/aeabi_read_tp.S
+@@ -39,6 +39,8 @@
+    a normal function call) in a high page of memory; tail call to the
+    helper.  */
+ 
++	.file "aeabi_read_tp.S"
++
+ 	.hidden __aeabi_read_tp
+ ENTRY (__aeabi_read_tp)
+ #ifdef ARCH_HAS_HARD_TP
+diff --git a/sysdeps/mips/start.S b/sysdeps/mips/start.S
+index a4c4ef0fae..d00fff31a8 100644
+--- a/sysdeps/mips/start.S
++++ b/sysdeps/mips/start.S
+@@ -38,6 +38,8 @@
+ #include <sgidefs.h>
+ #include <sys/asm.h>
+ 
++	.file "start.S"
++
+ #ifndef ENTRY_POINT
+ #error ENTRY_POINT needs to be defined for start.S on MIPS/ELF.
+ #endif
+diff --git a/sysdeps/unix/sysv/linux/powerpc/dl-brk.S b/sysdeps/unix/sysv/linux/powerpc/dl-brk.S
+index eeb96544e3..da182b28f8 100644
+--- a/sysdeps/unix/sysv/linux/powerpc/dl-brk.S
++++ b/sysdeps/unix/sysv/linux/powerpc/dl-brk.S
+@@ -1 +1,3 @@
++	.file "dl-brk.S"
++
+ #include <brk.S>
+diff --git a/sysdeps/powerpc/powerpc32/start.S b/sysdeps/powerpc/powerpc32/start.S
+index 5c10a22f8a..2b52627f27 100644
+--- a/sysdeps/powerpc/powerpc32/start.S
++++ b/sysdeps/powerpc/powerpc32/start.S
+@@ -35,6 +35,8 @@
+ 
+ #include <sysdep.h>
+ 
++	.file "start.S"
++
+ /* We do not want .eh_frame info for crt1.o since crt1.o is linked
+    before crtbegin.o, the file defining __EH_FRAME_BEGIN__.  */
+ #undef cfi_startproc
+diff --git a/sysdeps/powerpc/powerpc64/start.S b/sysdeps/powerpc/powerpc64/start.S
+index bd7189310c..2e22b8472d 100644
+--- a/sysdeps/powerpc/powerpc64/start.S
++++ b/sysdeps/powerpc/powerpc64/start.S
+@@ -35,6 +35,8 @@
+ 
+ #include <sysdep.h>
+ 
++	.file "start.S"
++
+ /* We do not want .eh_frame info for crt1.o since crt1.o is linked
+    before crtbegin.o, the file defining __EH_FRAME_BEGIN__.  */
+ #undef cfi_startproc
+diff --git a/sysdeps/powerpc/powerpc32/dl-start.S b/sysdeps/powerpc/powerpc32/dl-start.S
+index 244d87fb6d..14d3e2ce14 100644
+--- a/sysdeps/powerpc/powerpc32/dl-start.S
++++ b/sysdeps/powerpc/powerpc32/dl-start.S
+@@ -18,6 +18,8 @@
+ 
+ #include <sysdep.h>
+ 
++	.file "dl-start.S"
++
+ /* Initial entry point code for the dynamic linker.
+    The C function `_dl_start' is the real entry point;
+    its return value is the user program's entry point.	*/
+diff --git a/sysdeps/unix/sysv/linux/arm/libc-do-syscall.S b/sysdeps/unix/sysv/linux/arm/libc-do-syscall.S
+index d26ad1f8d3..a0de10bf81 100644
+--- a/sysdeps/unix/sysv/linux/arm/libc-do-syscall.S
++++ b/sysdeps/unix/sysv/linux/arm/libc-do-syscall.S
+@@ -27,6 +27,8 @@
+    ARM unwind tables for register to register moves, the actual opcodes
+    are not defined.  */
+ 
++      .file "libc-do-syscall.S"
++
+ #if defined(__thumb__)
+ 	.thumb
+ 	.syntax unified
diff --git a/poky/meta/recipes-core/glibc/glibc/CVE-2017-18269.patch b/poky/meta/recipes-core/glibc/glibc/CVE-2017-18269.patch
deleted file mode 100644
index d873c51..0000000
--- a/poky/meta/recipes-core/glibc/glibc/CVE-2017-18269.patch
+++ /dev/null
@@ -1,178 +0,0 @@
-From cd66c0e584c6d692bc8347b5e72723d02b8a8ada Mon Sep 17 00:00:00 2001
-From: Andrew Senkevich <andrew.n.senkevich@gmail.com>
-Date: Fri, 23 Mar 2018 16:19:45 +0100
-Subject: [PATCH] Fix i386 memmove issue (bug 22644).
-
-	[BZ #22644]
-	* sysdeps/i386/i686/multiarch/memcpy-sse2-unaligned.S: Fixed
-	branch conditions.
-	* string/test-memmove.c (do_test2): New testcase.
-
-Upstream-Status: Backport
-CVE: CVE-2017-18269
-Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
----
- ChangeLog                                          |  8 +++
- string/test-memmove.c                              | 58 ++++++++++++++++++++++
- .../i386/i686/multiarch/memcpy-sse2-unaligned.S    | 12 ++---
- 3 files changed, 72 insertions(+), 6 deletions(-)
-
-diff --git a/ChangeLog b/ChangeLog
-index 18ed09e..afdb766 100644
---- a/ChangeLog
-+++ b/ChangeLog
-@@ -1,3 +1,11 @@
-+2018-03-23  Andrew Senkevich  <andrew.senkevich@intel.com>
-+	    Max Horn  <max@quendi.de>
-+
-+	[BZ #22644]
-+	* sysdeps/i386/i686/multiarch/memcpy-sse2-unaligned.S: Fixed
-+	branch conditions.
-+	* string/test-memmove.c (do_test2): New testcase.
-+
- 2018-02-22  Andrew Waterman <andrew@sifive.com>
- 
- 	[BZ # 22884]
-diff --git a/string/test-memmove.c b/string/test-memmove.c
-index edc7a4c..64e3651 100644
---- a/string/test-memmove.c
-+++ b/string/test-memmove.c
-@@ -24,6 +24,7 @@
- # define TEST_NAME "memmove"
- #endif
- #include "test-string.h"
-+#include <support/test-driver.h>
- 
- char *simple_memmove (char *, const char *, size_t);
- 
-@@ -245,6 +246,60 @@ do_random_tests (void)
-     }
- }
- 
-+static void
-+do_test2 (void)
-+{
-+  size_t size = 0x20000000;
-+  uint32_t * large_buf;
-+
-+  large_buf = mmap ((void*) 0x70000000, size, PROT_READ | PROT_WRITE,
-+		    MAP_PRIVATE | MAP_ANON, -1, 0);
-+
-+  if (large_buf == MAP_FAILED)
-+    error (EXIT_UNSUPPORTED, errno, "Large mmap failed");
-+
-+  if ((uintptr_t) large_buf > 0x80000000 - 128
-+      || 0x80000000 - (uintptr_t) large_buf > 0x20000000)
-+    {
-+      error (0, 0, "Large mmap allocated improperly");
-+      ret = EXIT_UNSUPPORTED;
-+      munmap ((void *) large_buf, size);
-+      return;
-+    }
-+
-+  size_t bytes_move = 0x80000000 - (uintptr_t) large_buf;
-+  size_t arr_size = bytes_move / sizeof (uint32_t);
-+  size_t i;
-+
-+  FOR_EACH_IMPL (impl, 0)
-+    {
-+      for (i = 0; i < arr_size; i++)
-+        large_buf[i] = (uint32_t) i;
-+
-+      uint32_t * dst = &large_buf[33];
-+
-+#ifdef TEST_BCOPY
-+      CALL (impl, (char *) large_buf, (char *) dst, bytes_move);
-+#else
-+      CALL (impl, (char *) dst, (char *) large_buf, bytes_move);
-+#endif
-+
-+      for (i = 0; i < arr_size; i++)
-+	{
-+	  if (dst[i] != (uint32_t) i)
-+	    {
-+	      error (0, 0,
-+		     "Wrong result in function %s dst \"%p\" src \"%p\" offset \"%zd\"",
-+		     impl->name, dst, large_buf, i);
-+	      ret = 1;
-+	      break;
-+	    }
-+	}
-+    }
-+
-+  munmap ((void *) large_buf, size);
-+}
-+
- int
- test_main (void)
- {
-@@ -284,6 +339,9 @@ test_main (void)
-     }
- 
-   do_random_tests ();
-+
-+  do_test2 ();
-+
-   return ret;
- }
- 
-diff --git a/sysdeps/i386/i686/multiarch/memcpy-sse2-unaligned.S b/sysdeps/i386/i686/multiarch/memcpy-sse2-unaligned.S
-index 9c3bbe7..9aa17de 100644
---- a/sysdeps/i386/i686/multiarch/memcpy-sse2-unaligned.S
-+++ b/sysdeps/i386/i686/multiarch/memcpy-sse2-unaligned.S
-@@ -72,7 +72,7 @@ ENTRY (MEMCPY)
- 	cmp	%edx, %eax
- 
- # ifdef USE_AS_MEMMOVE
--	jg	L(check_forward)
-+	ja	L(check_forward)
- 
- L(mm_len_0_or_more_backward):
- /* Now do checks for lengths. We do [0..16], [16..32], [32..64], [64..128]
-@@ -81,7 +81,7 @@ L(mm_len_0_or_more_backward):
- 	jbe	L(mm_len_0_16_bytes_backward)
- 
- 	cmpl	$32, %ecx
--	jg	L(mm_len_32_or_more_backward)
-+	ja	L(mm_len_32_or_more_backward)
- 
- /* Copy [0..32] and return.  */
- 	movdqu	(%eax), %xmm0
-@@ -92,7 +92,7 @@ L(mm_len_0_or_more_backward):
- 
- L(mm_len_32_or_more_backward):
- 	cmpl	$64, %ecx
--	jg	L(mm_len_64_or_more_backward)
-+	ja	L(mm_len_64_or_more_backward)
- 
- /* Copy [0..64] and return.  */
- 	movdqu	(%eax), %xmm0
-@@ -107,7 +107,7 @@ L(mm_len_32_or_more_backward):
- 
- L(mm_len_64_or_more_backward):
- 	cmpl	$128, %ecx
--	jg	L(mm_len_128_or_more_backward)
-+	ja	L(mm_len_128_or_more_backward)
- 
- /* Copy [0..128] and return.  */
- 	movdqu	(%eax), %xmm0
-@@ -132,7 +132,7 @@ L(mm_len_128_or_more_backward):
- 	add	%ecx, %eax
- 	cmp	%edx, %eax
- 	movl	SRC(%esp), %eax
--	jle	L(forward)
-+	jbe	L(forward)
- 	PUSH (%esi)
- 	PUSH (%edi)
- 	PUSH (%ebx)
-@@ -269,7 +269,7 @@ L(check_forward):
- 	add	%edx, %ecx
- 	cmp	%eax, %ecx
- 	movl	LEN(%esp), %ecx
--	jle	L(forward)
-+	jbe	L(forward)
- 
- /* Now do checks for lengths. We do [0..16], [0..32], [0..64], [0..128]
- 	separately.  */
--- 
-2.9.3
diff --git a/poky/meta/recipes-core/glibc/glibc/CVE-2018-11236.patch b/poky/meta/recipes-core/glibc/glibc/CVE-2018-11236.patch
deleted file mode 100644
index e2bb40b..0000000
--- a/poky/meta/recipes-core/glibc/glibc/CVE-2018-11236.patch
+++ /dev/null
@@ -1,164 +0,0 @@
-From 5460617d1567657621107d895ee2dd83bc1f88f2 Mon Sep 17 00:00:00 2001
-From: Paul Pluzhnikov <ppluzhnikov@google.com>
-Date: Tue, 8 May 2018 18:12:41 -0700
-Subject: [PATCH] Fix BZ 22786: integer addition overflow may cause stack
- buffer overflow when realpath() input length is close to SSIZE_MAX.
-
-2018-05-09  Paul Pluzhnikov  <ppluzhnikov@google.com>
-
-	[BZ #22786]
-	* stdlib/canonicalize.c (__realpath): Fix overflow in path length
-	computation.
-	* stdlib/Makefile (test-bz22786): New test.
-	* stdlib/test-bz22786.c: New test.
-
-CVE: CVE-2018-11236
-Upstream-Status: Backport
-Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
----
- ChangeLog             |  8 +++++
- stdlib/Makefile       |  2 +-
- stdlib/canonicalize.c |  2 +-
- stdlib/test-bz22786.c | 90 +++++++++++++++++++++++++++++++++++++++++++++++++++
- 4 files changed, 100 insertions(+), 2 deletions(-)
- create mode 100644 stdlib/test-bz22786.c
-
-diff --git a/ChangeLog b/ChangeLog
---- a/ChangeLog
-+++ b/ChangeLog
-@@ -1,3 +1,11 @@
-+2018-05-09  Paul Pluzhnikov  <ppluzhnikov@google.com>
-+
-+	[BZ #22786]
-+	* stdlib/canonicalize.c (__realpath): Fix overflow in path length
-+	computation.
-+	* stdlib/Makefile (test-bz22786): New test.
-+	* stdlib/test-bz22786.c: New test.
-+
- 2018-03-23  Andrew Senkevich  <andrew.senkevich@intel.com>
- 	    Max Horn  <max@quendi.de>
- 
-diff --git a/stdlib/Makefile b/stdlib/Makefile
-index af1643c..1ddb1f9 100644
---- a/stdlib/Makefile
-+++ b/stdlib/Makefile
-@@ -84,7 +84,7 @@ tests		:= tst-strtol tst-strtod testmb testrand testsort testdiv   \
- 		   tst-cxa_atexit tst-on_exit test-atexit-race 		    \
- 		   test-at_quick_exit-race test-cxa_atexit-race             \
- 		   test-on_exit-race test-dlclose-exit-race 		    \
--		   tst-makecontext-align
-+		   tst-makecontext-align test-bz22786
- 
- tests-internal	:= tst-strtod1i tst-strtod3 tst-strtod4 tst-strtod5i \
- 		   tst-tls-atexit tst-tls-atexit-nodelete
-diff --git a/stdlib/canonicalize.c b/stdlib/canonicalize.c
-index 4135f3f..390fb43 100644
---- a/stdlib/canonicalize.c
-+++ b/stdlib/canonicalize.c
-@@ -181,7 +181,7 @@ __realpath (const char *name, char *resolved)
- 		extra_buf = __alloca (path_max);
- 
- 	      len = strlen (end);
--	      if ((long int) (n + len) >= path_max)
-+	      if (path_max - n <= len)
- 		{
- 		  __set_errno (ENAMETOOLONG);
- 		  goto error;
-diff --git a/stdlib/test-bz22786.c b/stdlib/test-bz22786.c
-new file mode 100644
-index 0000000..e7837f9
---- /dev/null
-+++ b/stdlib/test-bz22786.c
-@@ -0,0 +1,90 @@
-+/* Bug 22786: test for buffer overflow in realpath.
-+   Copyright (C) 2018 Free Software Foundation, Inc.
-+   This file is part of the GNU C Library.
-+
-+   The GNU C Library is free software; you can redistribute it and/or
-+   modify it under the terms of the GNU Lesser General Public
-+   License as published by the Free Software Foundation; either
-+   version 2.1 of the License, or (at your option) any later version.
-+
-+   The GNU C Library is distributed in the hope that it will be useful,
-+   but WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   Lesser General Public License for more details.
-+
-+   You should have received a copy of the GNU Lesser General Public
-+   License along with the GNU C Library; if not, see
-+   <http://www.gnu.org/licenses/>.  */
-+
-+/* This file must be run from within a directory called "stdlib".  */
-+
-+#include <errno.h>
-+#include <limits.h>
-+#include <stdio.h>
-+#include <stdlib.h>
-+#include <string.h>
-+#include <unistd.h>
-+#include <sys/stat.h>
-+#include <sys/types.h>
-+#include <support/test-driver.h>
-+#include <libc-diag.h>
-+
-+static int
-+do_test (void)
-+{
-+  const char dir[] = "bz22786";
-+  const char lnk[] = "bz22786/symlink";
-+
-+  rmdir (dir);
-+  if (mkdir (dir, 0755) != 0 && errno != EEXIST)
-+    {
-+      printf ("mkdir %s: %m\n", dir);
-+      return EXIT_FAILURE;
-+    }
-+  if (symlink (".", lnk) != 0 && errno != EEXIST)
-+    {
-+      printf ("symlink (%s, %s): %m\n", dir, lnk);
-+      return EXIT_FAILURE;
-+    }
-+
-+  const size_t path_len = (size_t) INT_MAX + 1;
-+
-+  DIAG_PUSH_NEEDS_COMMENT;
-+#if __GNUC_PREREQ (7, 0)
-+  /* GCC 7 warns about too-large allocations; here we need such
-+     allocation to succeed for the test to work.  */
-+  DIAG_IGNORE_NEEDS_COMMENT (7, "-Walloc-size-larger-than=");
-+#endif
-+  char *path = malloc (path_len);
-+  DIAG_POP_NEEDS_COMMENT;
-+
-+  if (path == NULL)
-+    {
-+      printf ("malloc (%zu): %m\n", path_len);
-+      return EXIT_UNSUPPORTED;
-+    }
-+
-+  /* Construct very long path = "bz22786/symlink/aaaa....."  */
-+  char *p = mempcpy (path, lnk, sizeof (lnk) - 1);
-+  *(p++) = '/';
-+  memset (p, 'a', path_len - (path - p) - 2);
-+  p[path_len - (path - p) - 1] = '\0';
-+
-+  /* This call crashes before the fix for bz22786 on 32-bit platforms.  */
-+  p = realpath (path, NULL);
-+
-+  if (p != NULL || errno != ENAMETOOLONG)
-+    {
-+      printf ("realpath: %s (%m)", p);
-+      return EXIT_FAILURE;
-+    }
-+
-+  /* Cleanup.  */
-+  unlink (lnk);
-+  rmdir (dir);
-+
-+  return 0;
-+}
-+
-+#define TEST_FUNCTION do_test
-+#include <support/test-driver.c>
--- 
-2.9.3
diff --git a/poky/meta/recipes-core/glibc/glibc/CVE-2018-11237.patch b/poky/meta/recipes-core/glibc/glibc/CVE-2018-11237.patch
deleted file mode 100644
index 632aa56..0000000
--- a/poky/meta/recipes-core/glibc/glibc/CVE-2018-11237.patch
+++ /dev/null
@@ -1,82 +0,0 @@
-From 9aaaab7c6e4176e61c59b0a63c6ba906d875dc0e Mon Sep 17 00:00:00 2001
-From: Andreas Schwab <schwab@suse.de>
-Date: Tue, 22 May 2018 10:37:59 +0200
-Subject: [PATCH] Don't write beyond destination in
- __mempcpy_avx512_no_vzeroupper (bug 23196)
-
-When compiled as mempcpy, the return value is the end of the destination
-buffer, thus it cannot be used to refer to the start of it.
-
-2018-05-23  Andreas Schwab  <schwab@suse.de>
-
-       [BZ #23196]
-       CVE-2018-11237
-       * sysdeps/x86_64/multiarch/memmove-avx512-no-vzeroupper.S
-       (L(preloop_large)): Save initial destination pointer in %r11 and
-       use it instead of %rax after the loop.
-       * string/test-mempcpy.c (MIN_PAGE_SIZE): Define.
-
-CVE: CVE-2018-11237
-Upstream-Status: Backport
-Signed-off-by: Zheng Ruoqin <zhengrq.fnst@cn.fujitsu.com>
----
- ChangeLog                                               | 9 +++++++++
- string/test-mempcpy.c                                   | 1 +
- sysdeps/x86_64/multiarch/memmove-avx512-no-vzeroupper.S | 5 +++--
- 3 files changed, 13 insertions(+), 2 deletions(-)
-
-diff --git a/ChangeLog b/ChangeLog
-index fa0a07c..bc09dec 100644
---- a/ChangeLog
-+++ b/ChangeLog
-@@ -1,3 +1,12 @@
-+2018-05-23  Andreas Schwab  <schwab@suse.de>
-+
-+	[BZ #23196]
-+	CVE-2018-11237
-+	* sysdeps/x86_64/multiarch/memmove-avx512-no-vzeroupper.S
-+	(L(preloop_large)): Save initial destination pointer in %r11 and
-+	use it instead of %rax after the loop.
-+	* string/test-mempcpy.c (MIN_PAGE_SIZE): Define.
-+
- 2018-05-09  Paul Pluzhnikov  <ppluzhnikov@google.com>
- 
- 	[BZ #22786]
-diff --git a/string/test-mempcpy.c b/string/test-mempcpy.c
-index c08fba8..d98ecdd 100644
---- a/string/test-mempcpy.c
-+++ b/string/test-mempcpy.c
-@@ -18,6 +18,7 @@
-    <http://www.gnu.org/licenses/>.  */
- 
- #define MEMCPY_RESULT(dst, len) (dst) + (len)
-+#define MIN_PAGE_SIZE 131072
- #define TEST_MAIN
- #define TEST_NAME "mempcpy"
- #include "test-string.h"
-diff --git a/sysdeps/x86_64/multiarch/memmove-avx512-no-vzeroupper.S b/sysdeps/x86_64/multiarch/memmove-avx512-no-vzeroupper.S
-index 23c0f7a..a55cf6f 100644
---- a/sysdeps/x86_64/multiarch/memmove-avx512-no-vzeroupper.S
-+++ b/sysdeps/x86_64/multiarch/memmove-avx512-no-vzeroupper.S
-@@ -335,6 +335,7 @@ L(preloop_large):
- 	ja	L(preloop_large_bkw)
- 	vmovups	(%rsi), %zmm4
- 	vmovups	0x40(%rsi), %zmm5
-+	mov     %rdi, %r11
- 
- /* Align destination for access with non-temporal stores in the loop.  */
- 	mov	%rdi, %r8
-@@ -366,8 +367,8 @@ L(gobble_256bytes_nt_loop):
- 	cmp	$256, %rdx
- 	ja	L(gobble_256bytes_nt_loop)
- 	sfence
--	vmovups	%zmm4, (%rax)
--	vmovups	%zmm5, 0x40(%rax)
-+	vmovups %zmm4, (%r11)
-+	vmovups %zmm5, 0x40(%r11)
- 	jmp	L(check)
- 
- L(preloop_large_bkw):
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-core/glibc/glibc/archive-path.patch b/poky/meta/recipes-core/glibc/glibc/archive-path.patch
deleted file mode 100644
index b0d3158..0000000
--- a/poky/meta/recipes-core/glibc/glibc/archive-path.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-localedef --add-to-archive uses a hard-coded locale path which doesn't exist in
-normal use, and there's no way to pass an alternative filename.
-
-Add a fallback of $LOCALEARCHIVE from the environment, and allow creation of new locale archives that are not the system archive.
-
-Upstream-Status: Inappropriate (OE-specific)
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
-diff --git a/locale/programs/locarchive.c b/locale/programs/locarchive.c
-index ca332a34..6b7ba9b2 100644
---- a/locale/programs/locarchive.c
-+++ b/locale/programs/locarchive.c
-@@ -569,10 +569,13 @@ open_archive (struct locarhandle *ah, bool readonly)
-   /* If ah has a non-NULL fname open that otherwise open the default.  */
-   if (archivefname == NULL)
-     {
--      archivefname = default_fname;
--      if (output_prefix)
--        memcpy (default_fname, output_prefix, prefix_len);
--      strcpy (default_fname + prefix_len, ARCHIVE_NAME);
-+      archivefname = getenv("LOCALEARCHIVE");
-+      if (archivefname == NULL) {
-+              archivefname = default_fname;
-+              if (output_prefix)
-+                memcpy (default_fname, output_prefix, prefix_len);
-+              strcpy (default_fname + prefix_len, ARCHIVE_NAME);
-+      }
-     }
- 
-   while (1)
-@@ -585,7 +588,7 @@ open_archive (struct locarhandle *ah, bool readonly)
- 	     the default locale archive we ignore the failure and
- 	     list an empty archive, otherwise we print an error
- 	     and exit.  */
--	  if (errno == ENOENT && archivefname == default_fname)
-+	  if (errno == ENOENT)
- 	    {
- 	      if (readonly)
- 		{
diff --git a/poky/meta/recipes-core/glibc/glibc/etc/ld.so.conf b/poky/meta/recipes-core/glibc/glibc/etc/ld.so.conf
index e69de29..83327c0 100644
--- a/poky/meta/recipes-core/glibc/glibc/etc/ld.so.conf
+++ b/poky/meta/recipes-core/glibc/glibc/etc/ld.so.conf
@@ -0,0 +1 @@
+include /etc/ld.so.conf.d/*.conf
diff --git a/poky/meta/recipes-core/glibc/glibc/makedbs.sh b/poky/meta/recipes-core/glibc/glibc/makedbs.sh
new file mode 100755
index 0000000..7d51a67
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc/makedbs.sh
@@ -0,0 +1,177 @@
+#!/bin/sh
+
+#
+# Make passwd.db, group.db, etc.
+#
+
+VAR_DB=/var/db
+
+# Use make if available
+if [ -x /usr/bin/make -o -x /bin/make ]; then
+	make -C $VAR_DB
+	exit 0
+fi
+
+# No make available, do it in hard way
+
+# passwd.db
+if [ -e /etc/passwd ]; then
+target=$VAR_DB/passwd.db
+echo -n "passwd... "
+awk 'BEGIN { FS=":"; OFS=":" } \
+ /^[ \t]*$$/ { next } \
+ /^[ \t]*#/ { next } \
+ /^[^#]/ { printf ".%s ", $$1; print; \
+	   printf "=%s ", $$3; print }' /etc/passwd | \
+makedb --quiet -o $target -
+echo "done."
+fi
+
+# group.db
+if [ -e /etc/group ]; then
+target=$VAR_DB/group.db
+echo -n "group... "
+awk 'BEGIN { FS=":"; OFS=":" } \
+ /^[ \t]*$$/ { next } \
+ /^[ \t]*#/ { next } \
+ /^[^#]/ { printf ".%s ", $$1; print; \
+	   printf "=%s ", $$3; print; \
+	   if ($$4 != "") { \
+	     split($$4, grmems, ","); \
+	     for (memidx in grmems) { \
+	       mem=grmems[memidx]; \
+	       if (members[mem] == "") \
+		 members[mem]=$$3; \
+	       else \
+		 members[mem]=members[mem] "," $$3; \
+	     } \
+	     delete grmems; } } \
+ END { for (mem in members) \
+	 printf ":%s %s %s\n", mem, mem, members[mem]; }' /etc/group | \
+makedb --quiet -o $target -
+echo "done."
+fi
+
+# ethers.db
+if [ -e /etc/ethers ]; then
+target=$VAR_DB/ethers.db
+echo -n "ethers... "
+awk '/^[ \t]*$$/ { next } \
+ /^[ \t]*#/ { next } \
+ /^[^#]/ { printf ".%s ", $$1; print; \
+	   printf "=%s ", $$2; print }' /etc/ethers | \
+makedb --quiet -o $target -
+echo "done."
+fi
+
+# protocols.db
+if [ -e /etc/protocols ]; then
+target=$VAR_DB/protocols.db
+echo -n "protocols... "
+awk '/^[ \t]*$$/ { next } \
+ /^[ \t]*#/ { next } \
+ /^[^#]/ { printf ".%s ", $$1; print; \
+	   printf "=%s ", $$2; print; \
+	   for (i = 3; i <= NF && !($$i ~ /^#/); ++i) \
+	     { printf ".%s ", $$i; print } }' /etc/protocols | \
+makedb --quiet -o $target -
+echo "done."
+fi
+
+# rpc.db
+if [ -e /etc/rpc ]; then
+target=$VAR_DB/rpc.db
+echo -n "rpc... "
+awk '/^[ \t]*$$/ { next } \
+ /^[ \t]*#/ { next } \
+ /^[^#]/ { printf ".%s ", $$1; print; \
+	   printf "=%s ", $$2; print; \
+	   for (i = 3; i <= NF && !($$i ~ /^#/); ++i) \
+	     { printf ".%s ", $$i; print } }' /etc/rpc | \
+makedb --quiet -o $target -
+echo "done."
+fi
+
+# services.db
+if [ -e /etc/services ]; then
+target=$VAR_DB/services.db
+echo -n "services... "
+awk 'BEGIN { FS="[ \t/]+" } \
+ /^[ \t]*$$/ { next } \
+ /^[ \t]*#/ { next } \
+ /^[^#]/ { sub(/[ \t]*#.*$$/, "");\
+	   printf ":%s/%s ", $$1, $$3; print; \
+	   printf ":%s/ ", $$1; print; \
+	   printf "=%s/%s ", $$2, $$3; print; \
+	   printf "=%s/ ", $$2; print; \
+	   for (i = 4; i <= NF && !($$i ~ /^#/); ++i) \
+	     { printf ":%s/%s ", $$i, $$3; print; \
+	       printf ":%s/ ", $$i; print } }' /etc/services | \
+makedb --quiet -o $target -
+echo "done."
+fi
+
+# shadow.db
+if [ -e /etc/shadow ]; then
+target=$VAR_DB/shadow.db
+echo -n "shadow... "
+awk 'BEGIN { FS=":"; OFS=":" } \
+ /^[ \t]*$$/ { next } \
+ /^[ \t]*#/ { next } \
+ /^[^#]/ { printf ".%s ", $$1; print }' /etc/shadow | \
+(umask 077 && makedb --quiet -o $target -)
+echo "done."
+if chgrp shadow $target 2>/dev/null; then
+	chmod g+r $target
+else
+	chown 0 $target; chgrp 0 $target; chmod 600 $target;
+	echo
+	echo "Warning: The shadow password database $target"
+	echo "has been set to be readable only by root.  You may want"
+	echo "to make it readable by the \`shadow' group depending"
+	echo "on your configuration."
+	echo
+fi
+fi
+
+# gshadow.db
+if [ -e /etc/gshadow ]; then
+target=$VAR_DB/gshadow.db
+echo -n "gshadow... "
+awk 'BEGIN { FS=":"; OFS=":" } \
+ /^[ \t]*$$/ { next } \
+ /^[ \t]*#/ { next } \
+ /^[^#]/ { printf ".%s ", $$1; print }' /etc/gshadow | \
+(umask 077 && makedb --quiet -o $target -)
+echo "done."
+if chgrp shadow $target 2>/dev/null; then
+	chmod g+r $target
+else
+	chown 0 $target; chgrp 0 $target; chmod 600 $target
+	echo
+	echo "Warning: The shadow group database $target"
+	echo "has been set to be readable only by root.  You may want"
+	echo "to make it readable by the \`shadow' group depending"
+	echo "on your configuration."
+	echo
+fi
+fi
+
+# netgroup.db
+if [ -e /etc/netgroup ]; then
+target=$VAR_DB/netgroup.db
+echo -n "netgroup... "
+awk 'BEGIN { ini=1 } \
+ /^[ \t]*$$/ { next } \
+ /^[ \t]*#/ { next } \
+ /^[^#]/ { if (sub(/[ \t]*\\$$/, " ") == 0) end="\n"; \
+	   else end=""; \
+	   gsub(/[ \t]+/, " "); \
+	   sub(/^[ \t]*/, ""); \
+	   if (ini == 0) printf "%s%s", $$0, end; \
+	   else printf ".%s %s%s", $$1, $$0, end; \
+	   ini=end == "" ? 0 : 1; } \
+ END { if (ini==0) printf "\n" }' /etc/netgroup | \
+makedb --quiet -o $target
+echo "done."
+fi
diff --git a/poky/meta/recipes-core/glibc/glibc/relocate-locales.patch b/poky/meta/recipes-core/glibc/glibc/relocate-locales.patch
deleted file mode 100644
index 2aea37f..0000000
--- a/poky/meta/recipes-core/glibc/glibc/relocate-locales.patch
+++ /dev/null
@@ -1,55 +0,0 @@
-The glibc locale path is hard-coded to the install prefix, but in SDKs we need
-to be able to relocate the binaries.  Expand the strings to 4K and put them in a
-magic segment that we can relocate at install time.
-
-Upstream-Status: Inappropriate (OE-specific)
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
-diff --git a/locale/findlocale.c b/locale/findlocale.c
-index 872cadb5..da14fa39 100644
---- a/locale/findlocale.c
-+++ b/locale/findlocale.c
-@@ -56,7 +56,7 @@ struct __locale_data *const _nl_C[] attribute_hidden =
-    which are somehow addressed.  */
- struct loaded_l10nfile *_nl_locale_file_list[__LC_LAST];
- 
--const char _nl_default_locale_path[] attribute_hidden = COMPLOCALEDIR;
-+char _nl_default_locale_path[4096] attribute_hidden __attribute__ ((section (".gccrelocprefix"))) = COMPLOCALEDIR;
- 
- /* Checks if the name is actually present, that is, not NULL and not
-    empty.  */
-@@ -167,7 +167,7 @@ _nl_find_locale (const char *locale_path, size_t locale_path_len,
- 
-       /* Nothing in the archive.  Set the default path to search below.  */
-       locale_path = _nl_default_locale_path;
--      locale_path_len = sizeof _nl_default_locale_path;
-+      locale_path_len = strlen(locale_path) + 1;
-     }
-   else
-     /* We really have to load some data.  First see whether the name is
-diff --git a/locale/localeinfo.h b/locale/localeinfo.h
-index 68822a63..537bc351 100644
---- a/locale/localeinfo.h
-+++ b/locale/localeinfo.h
-@@ -325,7 +325,7 @@ _nl_lookup_word (locale_t l, int category, int item)
- }
- 
- /* Default search path if no LOCPATH environment variable.  */
--extern const char _nl_default_locale_path[] attribute_hidden;
-+extern char _nl_default_locale_path[4096] attribute_hidden;
- 
- /* Load the locale data for CATEGORY from the file specified by *NAME.
-    If *NAME is "", use environment variables as specified by POSIX, and
-diff --git a/locale/loadarchive.c b/locale/loadarchive.c
-index 516d30d8..792b37fb 100644
---- a/locale/loadarchive.c
-+++ b/locale/loadarchive.c
-@@ -42,7 +43,7 @@
- 
- 
- /* Name of the locale archive file.  */
--static const char archfname[] = COMPLOCALEDIR "/locale-archive";
-+static const char archfname[4096] __attribute__ ((section (".gccrelocprefix"))) = COMPLOCALEDIR "/locale-archive";
- 
- /* Size of initial mapping window, optimal if large enough to
-    cover the header plus the initial locale.  */
diff --git a/poky/meta/recipes-core/glibc/glibc_2.27.bb b/poky/meta/recipes-core/glibc/glibc_2.27.bb
deleted file mode 100644
index adee494..0000000
--- a/poky/meta/recipes-core/glibc/glibc_2.27.bb
+++ /dev/null
@@ -1,149 +0,0 @@
-require glibc.inc
-
-LIC_FILES_CHKSUM = "file://LICENSES;md5=e9a558e243b36d3209f380deb394b213 \
-      file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-      file://posix/rxspencer/COPYRIGHT;md5=dc5485bb394a13b2332ec1c785f5d83a \
-      file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c"
-
-DEPENDS += "gperf-native bison-native"
-
-SRCREV ?= "df3ff4e49d4ee3cbbdaeb0b1cb5dc2344c08be98"
-
-SRCBRANCH ?= "release/${PV}/master"
-
-GLIBC_GIT_URI ?= "git://sourceware.org/git/glibc.git"
-UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+\.\d+(\.(?!90)\d+)*)"
-
-SRC_URI = "${GLIBC_GIT_URI};branch=${SRCBRANCH};name=glibc \
-           file://etc/ld.so.conf \
-           file://generate-supported.mk \
-           \
-           ${NATIVESDKFIXES} \
-           file://0005-fsl-e500-e5500-e6500-603e-fsqrt-implementation.patch \
-           file://0006-readlib-Add-OECORE_KNOWN_INTERPRETER_NAMES-to-known-.patch \
-           file://0007-ppc-sqrt-Fix-undefined-reference-to-__sqrt_finite.patch \
-           file://0008-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch \
-           file://0009-Quote-from-bug-1443-which-explains-what-the-patch-do.patch \
-           file://0010-eglibc-run-libm-err-tab.pl-with-specific-dirs-in-S.patch \
-           file://0011-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch \
-           file://0012-sysdeps-gnu-configure.ac-handle-correctly-libc_cv_ro.patch \
-           file://0013-Add-unused-attribute.patch \
-           file://0014-yes-within-the-path-sets-wrong-config-variables.patch \
-           file://0015-timezone-re-written-tzselect-as-posix-sh.patch \
-           file://0016-Remove-bash-dependency-for-nscd-init-script.patch \
-           file://0017-eglibc-Cross-building-and-testing-instructions.patch \
-           file://0018-eglibc-Help-bootstrap-cross-toolchain.patch \
-           file://0019-eglibc-Clear-cache-lines-on-ppc8xx.patch \
-           file://0020-eglibc-Resolve-__fpscr_values-on-SH4.patch \
-           file://0021-eglibc-Install-PIC-archives.patch \
-           file://0022-eglibc-Forward-port-cross-locale-generation-support.patch \
-           file://0023-Define-DUMMY_LOCALE_T-if-not-defined.patch \
-           file://0024-elf-dl-deps.c-Make-_dl_build_local_scope-breadth-fir.patch \
-           file://0025-locale-fix-hard-coded-reference-to-gcc-E.patch \
-           file://0026-reset-dl_load_write_lock-after-forking.patch \
-           file://0027-Acquire-ld.so-lock-before-switching-to-malloc_atfork.patch \
-           file://0028-bits-siginfo-consts.h-enum-definition-for-TRAP_HWBKP.patch \
-           file://0029-Replace-strncpy-with-memccpy-to-fix-Wstringop-trunca.patch \
-           file://0030-plural_c_no_preprocessor_lines.patch \
-           file://CVE-2017-18269.patch \
-           file://CVE-2018-11236.patch \
-           file://CVE-2018-11237.patch \
-"
-
-NATIVESDKFIXES ?= ""
-NATIVESDKFIXES_class-nativesdk = "\
-           file://0001-nativesdk-glibc-Look-for-host-system-ld.so.cache-as-.patch \
-           file://0002-nativesdk-glibc-Fix-buffer-overrun-with-a-relocated-.patch \
-           file://0003-nativesdk-glibc-Raise-the-size-of-arrays-containing-.patch \
-           file://0004-nativesdk-glibc-Allow-64-bit-atomics-for-x86.patch \
-           file://relocate-locales.patch \
-           file://0031-nativesdk-deprecate-libcrypt.patch \
-"
-
-S = "${WORKDIR}/git"
-B = "${WORKDIR}/build-${TARGET_SYS}"
-
-PACKAGES_DYNAMIC = ""
-
-# the -isystem in bitbake.conf screws up glibc do_stage
-BUILD_CPPFLAGS = "-I${STAGING_INCDIR_NATIVE}"
-TARGET_CPPFLAGS = "-I${STAGING_DIR_TARGET}${includedir}"
-
-GLIBC_BROKEN_LOCALES = ""
-#
-# We will skip parsing glibc when target system C library selection is not glibc
-# this helps in easing out parsing for non-glibc system libraries
-#
-COMPATIBLE_HOST_libc-musl_class-target = "null"
-
-GLIBCPIE ??= ""
-
-EXTRA_OECONF = "--enable-kernel=${OLDEST_KERNEL} \
-                --without-cvs --disable-profile \
-                --disable-debug --without-gd \
-                --enable-clocale=gnu \
-                --enable-add-ons=libidn \
-                --with-headers=${STAGING_INCDIR} \
-                --without-selinux \
-                --enable-obsolete-rpc \
-                --enable-obsolete-nsl \
-                --enable-tunables \
-                --enable-bind-now \
-                --enable-stack-protector=strong \
-                --enable-stackguard-randomization \
-                ${GLIBCPIE} \
-                ${GLIBC_EXTRA_OECONF}"
-
-EXTRA_OECONF += "${@get_libc_fpu_setting(bb, d)}"
-EXTRA_OECONF += "${@bb.utils.contains('DISTRO_FEATURES', 'libc-inet-anl', '--enable-nscd', '--disable-nscd', d)}"
-
-
-do_patch_append() {
-    bb.build.exec_func('do_fix_readlib_c', d)
-}
-
-do_fix_readlib_c () {
-	sed -i -e 's#OECORE_KNOWN_INTERPRETER_NAMES#${EGLIBC_KNOWN_INTERPRETER_NAMES}#' ${S}/elf/readlib.c
-}
-
-do_configure () {
-# override this function to avoid the autoconf/automake/aclocal/autoheader
-# calls for now
-# don't pass CPPFLAGS into configure, since it upsets the kernel-headers
-# version check and doesn't really help with anything
-        (cd ${S} && gnu-configize) || die "failure in running gnu-configize"
-        find ${S} -name "configure" | xargs touch
-        CPPFLAGS="" oe_runconf
-}
-
-rpcsvc = "bootparam_prot.x nlm_prot.x rstat.x \
-	  yppasswd.x klm_prot.x rex.x sm_inter.x mount.x \
-	  rusers.x spray.x nfs_prot.x rquota.x key_prot.x"
-
-do_compile () {
-	# -Wl,-rpath-link <staging>/lib in LDFLAGS can cause breakage if another glibc is in staging
-	unset LDFLAGS
-	base_do_compile
-	(
-		cd ${S}/sunrpc/rpcsvc
-		for r in ${rpcsvc}; do
-			h=`echo $r|sed -e's,\.x$,.h,'`
-			rm -f $h
-			${B}/sunrpc/cross-rpcgen -h $r -o $h || bbwarn "${PN}: unable to generate header for $r"
-		done
-	)
-	echo "Adjust ldd script"
-	if [ -n "${RTLDLIST}" ]
-	then
-		prevrtld=`cat ${B}/elf/ldd | grep "^RTLDLIST=" | sed 's#^RTLDLIST="\?\([^"]*\)"\?$#\1#'`
-		if [ "${prevrtld}" != "${RTLDLIST}" ]
-		then
-			sed -i ${B}/elf/ldd -e "s#^RTLDLIST=.*\$#RTLDLIST=\"${prevrtld} ${RTLDLIST}\"#"
-		fi
-	fi
-
-}
-
-require glibc-package.inc
-
-BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-core/glibc/glibc_2.28.bb b/poky/meta/recipes-core/glibc/glibc_2.28.bb
new file mode 100644
index 0000000..d072939
--- /dev/null
+++ b/poky/meta/recipes-core/glibc/glibc_2.28.bb
@@ -0,0 +1,135 @@
+require glibc.inc
+
+LIC_FILES_CHKSUM = "file://LICENSES;md5=cfc0ed77a9f62fa62eded042ebe31d72 \
+      file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+      file://posix/rxspencer/COPYRIGHT;md5=dc5485bb394a13b2332ec1c785f5d83a \
+      file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c"
+
+DEPENDS += "gperf-native bison-native make-native"
+
+SRCREV ?= "044c96f0d5595aeb0bb4e79355081c5a7f4faca5"
+
+SRCBRANCH ?= "release/${PV}/master"
+
+GLIBC_GIT_URI ?= "git://sourceware.org/git/glibc.git"
+UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+\.\d+(\.(?!90)\d+)*)"
+
+SRC_URI = "${GLIBC_GIT_URI};branch=${SRCBRANCH};name=glibc \
+           file://etc/ld.so.conf \
+           file://generate-supported.mk \
+           file://makedbs.sh \
+           \
+           ${NATIVESDKFIXES} \
+           file://0006-fsl-e500-e5500-e6500-603e-fsqrt-implementation.patch \
+           file://0007-readlib-Add-OECORE_KNOWN_INTERPRETER_NAMES-to-known-.patch \
+           file://0008-ppc-sqrt-Fix-undefined-reference-to-__sqrt_finite.patch \
+           file://0009-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch \
+           file://0010-Quote-from-bug-1443-which-explains-what-the-patch-do.patch \
+           file://0011-eglibc-run-libm-err-tab.pl-with-specific-dirs-in-S.patch \
+           file://0012-__ieee754_sqrt-f-are-now-inline-functions-and-call-o.patch \
+           file://0013-sysdeps-gnu-configure.ac-handle-correctly-libc_cv_ro.patch \
+           file://0014-Add-unused-attribute.patch \
+           file://0015-yes-within-the-path-sets-wrong-config-variables.patch \
+           file://0016-timezone-re-written-tzselect-as-posix-sh.patch \
+           file://0017-Remove-bash-dependency-for-nscd-init-script.patch \
+           file://0018-eglibc-Cross-building-and-testing-instructions.patch \
+           file://0019-eglibc-Help-bootstrap-cross-toolchain.patch \
+           file://0020-eglibc-Clear-cache-lines-on-ppc8xx.patch \
+           file://0021-eglibc-Resolve-__fpscr_values-on-SH4.patch \
+           file://0022-eglibc-Forward-port-cross-locale-generation-support.patch \
+           file://0023-Define-DUMMY_LOCALE_T-if-not-defined.patch \
+           file://0024-elf-dl-deps.c-Make-_dl_build_local_scope-breadth-fir.patch \
+           file://0025-locale-fix-hard-coded-reference-to-gcc-E.patch \
+           file://0026-reset-dl_load_write_lock-after-forking.patch \
+           file://0027-Acquire-ld.so-lock-before-switching-to-malloc_atfork.patch \
+           file://0028-bits-siginfo-consts.h-enum-definition-for-TRAP_HWBKP.patch \
+           file://0029-localedef-add-to-archive-uses-a-hard-coded-locale-pa.patch \
+           file://0030-intl-Emit-no-lines-in-bison-generated-files.patch \
+           file://0031-sysdeps-ieee754-prevent-maybe-uninitialized-errors-w.patch \
+           file://0032-sysdeps-ieee754-soft-fp-ignore-maybe-uninitialized-w.patch \
+           file://0033-locale-prevent-maybe-uninitialized-errors-with-Os-BZ.patch \
+           file://0034-inject-file-assembly-directives.patch \
+"
+
+NATIVESDKFIXES ?= ""
+NATIVESDKFIXES_class-nativesdk = "\
+           file://0001-nativesdk-glibc-Look-for-host-system-ld.so.cache-as-.patch \
+           file://0002-nativesdk-glibc-Fix-buffer-overrun-with-a-relocated-.patch \
+           file://0003-nativesdk-glibc-Raise-the-size-of-arrays-containing-.patch \
+           file://0004-nativesdk-glibc-Allow-64-bit-atomics-for-x86.patch \
+           file://0005-nativesdk-glibc-Make-relocatable-install-for-locales.patch \
+"
+
+S = "${WORKDIR}/git"
+B = "${WORKDIR}/build-${TARGET_SYS}"
+
+PACKAGES_DYNAMIC = ""
+
+# the -isystem in bitbake.conf screws up glibc do_stage
+BUILD_CPPFLAGS = "-I${STAGING_INCDIR_NATIVE}"
+TARGET_CPPFLAGS = "-I${STAGING_DIR_TARGET}${includedir}"
+
+GLIBC_BROKEN_LOCALES = ""
+#
+# We will skip parsing glibc when target system C library selection is not glibc
+# this helps in easing out parsing for non-glibc system libraries
+#
+COMPATIBLE_HOST_libc-musl_class-target = "null"
+
+GLIBCPIE ??= ""
+
+EXTRA_OECONF = "--enable-kernel=${OLDEST_KERNEL} \
+                --disable-profile \
+                --disable-debug --without-gd \
+                --enable-clocale=gnu \
+                --with-headers=${STAGING_INCDIR} \
+                --without-selinux \
+                --enable-tunables \
+                --enable-bind-now \
+                --enable-stack-protector=strong \
+                --enable-stackguard-randomization \
+                --disable-crypt \
+                ${GLIBCPIE} \
+                ${GLIBC_EXTRA_OECONF}"
+
+EXTRA_OECONF += "${@get_libc_fpu_setting(bb, d)}"
+EXTRA_OECONF += "${@bb.utils.contains('DISTRO_FEATURES', 'libc-inet-anl', '--enable-nscd', '--disable-nscd', d)}"
+
+
+do_patch_append() {
+    bb.build.exec_func('do_fix_readlib_c', d)
+}
+
+do_fix_readlib_c () {
+	sed -i -e 's#OECORE_KNOWN_INTERPRETER_NAMES#${EGLIBC_KNOWN_INTERPRETER_NAMES}#' ${S}/elf/readlib.c
+}
+
+do_configure () {
+# override this function to avoid the autoconf/automake/aclocal/autoheader
+# calls for now
+# don't pass CPPFLAGS into configure, since it upsets the kernel-headers
+# version check and doesn't really help with anything
+        (cd ${S} && gnu-configize) || die "failure in running gnu-configize"
+        find ${S} -name "configure" | xargs touch
+        CPPFLAGS="" oe_runconf
+}
+
+do_compile () {
+	# -Wl,-rpath-link <staging>/lib in LDFLAGS can cause breakage if another glibc is in staging
+	unset LDFLAGS
+	base_do_compile
+	echo "Adjust ldd script"
+	if [ -n "${RTLDLIST}" ]
+	then
+		prevrtld=`cat ${B}/elf/ldd | grep "^RTLDLIST=" | sed 's#^RTLDLIST="\?\([^"]*\)"\?$#\1#'`
+		if [ "${prevrtld}" != "${RTLDLIST}" ]
+		then
+			sed -i ${B}/elf/ldd -e "s#^RTLDLIST=.*\$#RTLDLIST=\"${prevrtld} ${RTLDLIST}\"#"
+		fi
+	fi
+
+}
+
+require glibc-package.inc
+
+BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-core/ifupdown/files/inet-6-.defn-fix-inverted-checks-for-loopback.patch b/poky/meta/recipes-core/ifupdown/files/inet-6-.defn-fix-inverted-checks-for-loopback.patch
index 2013933..37a61c9 100644
--- a/poky/meta/recipes-core/ifupdown/files/inet-6-.defn-fix-inverted-checks-for-loopback.patch
+++ b/poky/meta/recipes-core/ifupdown/files/inet-6-.defn-fix-inverted-checks-for-loopback.patch
@@ -1,4 +1,4 @@
-From d88af5aa0312ea18aac791d66661da79b7bcd032 Mon Sep 17 00:00:00 2001
+From 7efe4676747e4e4a056b9bfb4e9424c8354e9996 Mon Sep 17 00:00:00 2001
 From: "Maxin B. John" <maxin.john@intel.com>
 Date: Wed, 21 Dec 2016 15:32:07 +0200
 Subject: [PATCH] inet[6].defn: fix inverted checks for loopback
@@ -35,12 +35,13 @@
 
 Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
 Signed-off-by: Maxin B. John <maxin.john@intel.com>
+Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
 ---
- inet.defn | 148 +++++++++++++++++++++++++++++++-------------------------------
- 1 file changed, 74 insertions(+), 74 deletions(-)
+ inet.defn | 140 +++++++++++++++++++++++++++++++-------------------------------
+ 1 file changed, 70 insertions(+), 70 deletions(-)
 
 diff --git a/inet.defn b/inet.defn
-index 75e6744..b5f5da2 100644
+index 75e6744..23c7756 100644
 --- a/inet.defn
 +++ b/inet.defn
 @@ -6,10 +6,10 @@ method loopback
@@ -48,11 +49,11 @@
  
    up
 -    /bin/ip link set dev %iface% up if (!iface_is_lo())
-+    ip link set dev %iface% up if (iface_is_lo())
++    ip link set dev %iface% up if (!iface_is_lo())
  
    down
 -    /bin/ip link set dev %iface% down if (!iface_is_lo())
-+    ip link set dev %iface% down if (iface_is_lo())
++    ip link set dev %iface% down if (!iface_is_lo())
  
  method static
    description
@@ -211,23 +212,20 @@
  
  architecture kfreebsd
  
-@@ -211,12 +211,12 @@ method loopback
+@@ -211,11 +211,11 @@ method loopback
      This method may be used to define the IPv4 loopback interface.
  
    up
 -    /sbin/ifconfig %iface% 127.0.0.1 up \
--	if (!iface_is_lo())
 +    ifconfig %iface% 127.0.0.1 up \
-+	if (iface_is_lo())
+ 	if (!iface_is_lo())
  
    down
 -    /sbin/ifconfig %iface% down \
--	if (!iface_is_lo())
 +    ifconfig %iface% down \
-+	if (iface_is_lo())
+ 	if (!iface_is_lo())
  
  method static
-   description
 @@ -238,15 +238,15 @@ method static
      hwaddress cleanup_hwaddress
  
@@ -339,20 +337,6 @@
  architecture hurd
  
  method loopback
-@@ -367,11 +367,11 @@ method loopback
- 
-   up
-     inetutils-ifconfig --interface %iface% --address 127.0.0.1 --up \
--	if (!iface_is_lo())
-+	if (iface_is_lo())
- 
-   down
-     inetutils-ifconfig --interface %iface% --down \
--	if (!iface_is_lo())
-+	if (iface_is_lo())
- 
- method static
-   description
 @@ -432,23 +432,23 @@ method dhcp
  
    up
@@ -418,5 +402,5 @@
 -    /usr/sbin/avahi-autoipd --kill %iface%
 +    avahi-autoipd --kill %iface%
 -- 
-2.4.0
+2.7.4
 
diff --git a/poky/meta/recipes-core/images/build-appliance-image_15.0.0.bb b/poky/meta/recipes-core/images/build-appliance-image_15.0.0.bb
index 8ab59a9..f03ef96 100644
--- a/poky/meta/recipes-core/images/build-appliance-image_15.0.0.bb
+++ b/poky/meta/recipes-core/images/build-appliance-image_15.0.0.bb
@@ -22,8 +22,8 @@
 
 inherit core-image module-base setuptools3
 
-SRCREV ?= "1566ecdb01216ece73864c15c781fdefe9af5e37"
-SRC_URI = "git://git.yoctoproject.org/poky;branch=sumo \
+SRCREV ?= "53332c9f1bd270f34a290fea68fde1d3ff41f86e"
+SRC_URI = "git://git.yoctoproject.org/poky;branch=thud \
            file://Yocto_Build_Appliance.vmx \
            file://Yocto_Build_Appliance.vmxf \
            file://README_VirtualBox_Guest_Additions.txt \
@@ -59,8 +59,10 @@
 	cp ${WORKDIR}/README_VirtualBox_Toaster.txt ${IMAGE_ROOTFS}/home/builder/
 
 	# Create a symlink, needed for out-of-tree kernel modules build
-	rm -f  ${IMAGE_ROOTFS}/lib/modules/${KERNEL_VERSION}/build
-	lnr ${IMAGE_ROOTFS}${KERNEL_SRC_PATH} ${IMAGE_ROOTFS}/lib/modules/${KERNEL_VERSION}/build
+	if [ ! -e ${IMAGE_ROOTFS}/lib/modules/${KERNEL_VERSION}/build ]; then
+		rm -f  ${IMAGE_ROOTFS}/lib/modules/${KERNEL_VERSION}/build
+		lnr ${IMAGE_ROOTFS}${KERNEL_SRC_PATH} ${IMAGE_ROOTFS}/lib/modules/${KERNEL_VERSION}/build
+	fi
 
 	echo "INHERIT += \"rm_work\"" >> ${IMAGE_ROOTFS}/home/builder/poky/build/conf/auto.conf
 	echo "export LC_ALL=en_US.utf8" >> ${IMAGE_ROOTFS}/home/builder/.bashrc
diff --git a/poky/meta/recipes-core/images/core-image-minimal-initramfs.bb b/poky/meta/recipes-core/images/core-image-minimal-initramfs.bb
index 6de860e..7df8ab1 100644
--- a/poky/meta/recipes-core/images/core-image-minimal-initramfs.bb
+++ b/poky/meta/recipes-core/images/core-image-minimal-initramfs.bb
@@ -27,7 +27,5 @@
 IMAGE_ROOTFS_SIZE = "8192"
 IMAGE_ROOTFS_EXTRA_SPACE = "0"
 
-BAD_RECOMMENDATIONS += "busybox-syslog"
-
 # Use the same restriction as initramfs-live-install
 COMPATIBLE_HOST = "(i.86|x86_64).*-linux"
diff --git a/poky/meta/recipes-core/images/core-image-tiny-initramfs.bb b/poky/meta/recipes-core/images/core-image-tiny-initramfs.bb
index 51d08a0..0eca6d9 100644
--- a/poky/meta/recipes-core/images/core-image-tiny-initramfs.bb
+++ b/poky/meta/recipes-core/images/core-image-tiny-initramfs.bb
@@ -5,6 +5,8 @@
 actually generate an image but rather generates boot and rootfs artifacts \
 that can subsequently be picked up by external image generation tools such as wic."
 
+VIRTUAL-RUNTIME_dev_manager ?= "busybox-mdev"
+
 PACKAGE_INSTALL = "initramfs-live-boot-tiny packagegroup-core-boot dropbear ${VIRTUAL-RUNTIME_base-utils} ${VIRTUAL-RUNTIME_dev_manager} base-passwd ${ROOTFS_BOOTSTRAP_INSTALL}"
 
 # Do not pollute the initrd image with rootfs features
@@ -23,8 +25,6 @@
 IMAGE_ROOTFS_SIZE = "8192"
 IMAGE_ROOTFS_EXTRA_SPACE = "0"
 
-BAD_RECOMMENDATIONS += "busybox-syslog"
-
 # Use the same restriction as initramfs-live-install
 COMPATIBLE_HOST = "(i.86|x86_64).*-linux"
 
diff --git a/poky/meta/recipes-core/initrdscripts/files/init-install-efi.sh b/poky/meta/recipes-core/initrdscripts/files/init-install-efi.sh
index 82b0aa8..b6855b5 100644
--- a/poky/meta/recipes-core/initrdscripts/files/init-install-efi.sh
+++ b/poky/meta/recipes-core/initrdscripts/files/init-install-efi.sh
@@ -291,7 +291,7 @@
 
 sync
 
-echo "Remove your installation media, and press ENTER"
+echo "Installation successful. Remove your installation media and press ENTER to reboot."
 
 read enter
 
diff --git a/poky/meta/recipes-core/initrdscripts/files/init-live.sh b/poky/meta/recipes-core/initrdscripts/files/init-live.sh
index 46cab6c..65183d7 100644
--- a/poky/meta/recipes-core/initrdscripts/files/init-live.sh
+++ b/poky/meta/recipes-core/initrdscripts/files/init-live.sh
@@ -95,8 +95,11 @@
     # Move the mount points of some filesystems over to
     # the corresponding directories under the real root filesystem.
     for dir in `awk '/\/dev.* \/run\/media/{print $2}' /proc/mounts`; do
-        mkdir -p  ${ROOT_MOUNT}/media/${dir##*/}
-        mount -n --move $dir ${ROOT_MOUNT}/media/${dir##*/}
+        # Parse any OCT or HEX encoded chars such as spaces
+        # in the mount points to actual ASCII chars
+        dir=`printf $dir`
+        mkdir -p "${ROOT_MOUNT}/media/${dir##*/}"
+        mount -n --move "$dir" "${ROOT_MOUNT}/media/${dir##*/}"
     done
     mount -n --move /proc ${ROOT_MOUNT}/proc
     mount -n --move /sys ${ROOT_MOUNT}/sys
diff --git a/poky/meta/recipes-core/initrdscripts/initramfs-framework/init b/poky/meta/recipes-core/initrdscripts/initramfs-framework/init
index 37527a8..3c7e094 100755
--- a/poky/meta/recipes-core/initrdscripts/initramfs-framework/init
+++ b/poky/meta/recipes-core/initrdscripts/initramfs-framework/init
@@ -84,7 +84,7 @@
 # populate bootparam environment
 for p in `cat /proc/cmdline`; do
 	opt=`echo $p | cut -d'=' -f1`
-	opt=`echo $opt | tr '.-' '__'`
+	opt=`echo $opt | sed -e 'y/.-/__/'`
 	if [ "`echo $p | cut -d'=' -f1`" = "$p" ]; then
 		eval "bootparam_${opt}=true"
 	else
diff --git a/poky/meta/recipes-core/initrdscripts/initramfs-framework/nfsrootfs b/poky/meta/recipes-core/initrdscripts/initramfs-framework/nfsrootfs
new file mode 100644
index 0000000..e67ee4c
--- /dev/null
+++ b/poky/meta/recipes-core/initrdscripts/initramfs-framework/nfsrootfs
@@ -0,0 +1,48 @@
+#!/bin/sh
+
+nfsrootfs_enabled() {
+	if [ ${bootparam_root} != "/dev/nfs" ] || [ -z ${bootparam_nfsroot} ]; then
+		return 1
+	fi
+	return 0
+}
+
+nfsrootfs_run() {
+	local nfs_opts
+	local location
+	local flags
+	local server_ip
+
+	nfs_opts=""
+	if [ "${bootparam_nfsroot#*,}" != "${bootparam_nfsroot}" ]; then
+		nfs_opts="-o ${bootparam_nfsroot#*,}"
+	fi
+
+	location="${bootparam_nfsroot%%,*}"
+	if [ "${location#*:}" = "${location}" ]; then
+		# server-ip not given. Get server ip from ip option
+		server_ip=""
+		if [ "${bootparam_ip#*:}" != "${bootparam_ip}" ]; then
+			server_ip=$(echo "$bootparam_ip" | cut -d: -f2)
+		fi
+
+		if [ -z "$server_ip" ]; then
+			fatal "Server IP is not set. Update ip or nfsroot options."
+		fi
+		location=${server_ip}:${location}
+	fi
+
+	flags="-o nolock"
+	if [ -n "$bootparam_ro" ] && ! echo "$bootparam_rootflags" | grep -w -q "ro"; then
+		if [  -n "$bootparam_rootflags" ]; then
+			bootparam_rootflags="$bootparam_rootflags,"
+		fi
+		bootparam_rootflags="${bootparam_rootflags}ro"
+	fi
+	if [ -n "$bootparam_rootflags" ]; then
+		flags="$flags -o $bootparam_rootflags"
+	fi
+
+	mount -t nfs ${flags} ${nfs_opts} ${location} ${ROOTFS_DIR}
+}
+
diff --git a/poky/meta/recipes-core/initrdscripts/initramfs-framework_1.0.bb b/poky/meta/recipes-core/initrdscripts/initramfs-framework_1.0.bb
index 75d965f..660343e 100644
--- a/poky/meta/recipes-core/initrdscripts/initramfs-framework_1.0.bb
+++ b/poky/meta/recipes-core/initrdscripts/initramfs-framework_1.0.bb
@@ -2,6 +2,7 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
 RDEPENDS_${PN} += "${VIRTUAL-RUNTIME_base-utils}"
+RRECOMMENDS_${PN} = "${VIRTUAL-RUNTIME_base-utils-syslog}"
 
 PR = "r4"
 
@@ -9,6 +10,7 @@
 
 SRC_URI = "file://init \
            file://exec \
+           file://nfsrootfs \
            file://rootfs \
            file://finish \
            file://mdev \
@@ -24,6 +26,7 @@
 
     # base
     install -m 0755 ${WORKDIR}/init ${D}/init
+    install -m 0755 ${WORKDIR}/nfsrootfs ${D}/init.d/85-nfsrootfs
     install -m 0755 ${WORKDIR}/rootfs ${D}/init.d/90-rootfs
     install -m 0755 ${WORKDIR}/finish ${D}/init.d/99-finish
 
@@ -53,6 +56,7 @@
             initramfs-module-mdev \
             initramfs-module-udev \
             initramfs-module-e2fs \
+            initramfs-module-nfsrootfs \
             initramfs-module-rootfs \
             initramfs-module-debug \
            "
@@ -83,6 +87,10 @@
 RDEPENDS_initramfs-module-e2fs = "${PN}-base"
 FILES_initramfs-module-e2fs = "/init.d/10-e2fs"
 
+SUMMARY_initramfs-module-nfsrootfs = "initramfs support for locating and mounting the root partition via nfs"
+RDEPENDS_initramfs-module-nfsrootfs = "${PN}-base"
+FILES_initramfs-module-nfsrootfs = "/init.d/85-nfsrootfs"
+
 SUMMARY_initramfs-module-rootfs = "initramfs support for locating and mounting the root partition"
 RDEPENDS_initramfs-module-rootfs = "${PN}-base"
 FILES_initramfs-module-rootfs = "/init.d/90-rootfs"
diff --git a/poky/meta/recipes-core/initrdscripts/initramfs-live-install-efi_1.0.bb b/poky/meta/recipes-core/initrdscripts/initramfs-live-install-efi_1.0.bb
index f588a10..cc842ae 100644
--- a/poky/meta/recipes-core/initrdscripts/initramfs-live-install-efi_1.0.bb
+++ b/poky/meta/recipes-core/initrdscripts/initramfs-live-install-efi_1.0.bb
@@ -6,6 +6,7 @@
 PR = "r1"
 
 RDEPENDS_${PN} = "parted e2fsprogs-mke2fs dosfstools util-linux-blkid ${VIRTUAL-RUNTIME_base-utils}"
+RRECOMMENDS_${PN} = "${VIRTUAL-RUNTIME_base-utils-syslog}"
 
 S = "${WORKDIR}"
 
diff --git a/poky/meta/recipes-core/initrdscripts/initramfs-live-install_1.0.bb b/poky/meta/recipes-core/initrdscripts/initramfs-live-install_1.0.bb
index 9222d57..48fc0c4 100644
--- a/poky/meta/recipes-core/initrdscripts/initramfs-live-install_1.0.bb
+++ b/poky/meta/recipes-core/initrdscripts/initramfs-live-install_1.0.bb
@@ -8,6 +8,7 @@
 S = "${WORKDIR}"
 
 RDEPENDS_${PN} = "grub parted e2fsprogs-mke2fs util-linux-blkid ${VIRTUAL-RUNTIME_base-utils}"
+RRECOMMENDS_${PN} = "${VIRTUAL-RUNTIME_base-utils-syslog}"
 
 do_install() {
         install -m 0755 ${WORKDIR}/init-install.sh ${D}/install.sh
diff --git a/poky/meta/recipes-core/initrdscripts/initramfs-module-install-efi_1.0.bb b/poky/meta/recipes-core/initrdscripts/initramfs-module-install-efi_1.0.bb
index 78a61cd..523138c 100644
--- a/poky/meta/recipes-core/initrdscripts/initramfs-module-install-efi_1.0.bb
+++ b/poky/meta/recipes-core/initrdscripts/initramfs-module-install-efi_1.0.bb
@@ -2,6 +2,7 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
 RDEPENDS_${PN} = "initramfs-framework-base parted e2fsprogs-mke2fs dosfstools util-linux-blkid ${VIRTUAL-RUNTIME_base-utils}"
+RRECOMMENDS_${PN} = "${VIRTUAL-RUNTIME_base-utils-syslog}"
 
 PR = "r4"
 
diff --git a/poky/meta/recipes-core/initrdscripts/initramfs-module-install_1.0.bb b/poky/meta/recipes-core/initrdscripts/initramfs-module-install_1.0.bb
index 04e90cd..56898e8 100644
--- a/poky/meta/recipes-core/initrdscripts/initramfs-module-install_1.0.bb
+++ b/poky/meta/recipes-core/initrdscripts/initramfs-module-install_1.0.bb
@@ -2,6 +2,7 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
 RDEPENDS_${PN} = "initramfs-framework-base grub parted e2fsprogs-mke2fs util-linux-blkid ${VIRTUAL-RUNTIME_base-utils}"
+RRECOMMENDS_${PN} = "${VIRTUAL-RUNTIME_base-utils-syslog}"
 
 # The same restriction as grub
 COMPATIBLE_HOST = '(x86_64.*|i.86.*|arm.*|aarch64.*)-(linux.*|freebsd.*)'
diff --git a/poky/meta/recipes-core/initscripts/initscripts-1.0/populate-volatile.sh b/poky/meta/recipes-core/initscripts/initscripts-1.0/populate-volatile.sh
index 3cf3243..6f965a6 100755
--- a/poky/meta/recipes-core/initscripts/initscripts-1.0/populate-volatile.sh
+++ b/poky/meta/recipes-core/initscripts/initscripts-1.0/populate-volatile.sh
@@ -112,7 +112,6 @@
 	}
 
 	CFGFILE="$1"
-	[ `basename "${CFGFILE}"` = "${COREDEF}" ] && return 0
 
 	TMP_INTERMED="${TMPROOT}/tmp.$$"
 	TMP_DEFINED="${TMPROOT}/tmpdefined.$$"
@@ -154,8 +153,11 @@
 
 apply_cfgfile() {
 	CFGFILE="$1"
+	SKIP_REQUIREMENTS="$2"
 
-	check_requirements "${CFGFILE}" || {
+	[ "${VERBOSE}" != "no" ] && echo "Applying ${CFGFILE}"
+
+	[ "${SKIP_REQUIREMENTS}" == "yes" ] || check_requirements "${CFGFILE}" || {
 		echo "Skipping ${CFGFILE}"
 		return 1
 	}
@@ -231,10 +233,37 @@
 	sh ${ROOT_DIR}/etc/volatile.cache
 else
 	rm -f ${ROOT_DIR}/etc/volatile.cache ${ROOT_DIR}/etc/volatile.cache.build
-	for file in `ls -1 "${CFGDIR}" | sort`; do
-		apply_cfgfile "${CFGDIR}/${file}"
+
+	# Apply the core file with out checking requirements. ${TMPROOT} is
+	# needed by check_requirements but is setup by this file, so it must be
+	# processed first and without being checked.
+	[ -e "${CFGDIR}/${COREDEF}" ] && apply_cfgfile "${CFGDIR}/${COREDEF}" "yes"
+
+	# Fast path: check_requirements is slow and most of the time doesn't
+	# find any problems. If there are a lot of config files, it is much
+	# faster to to concatenate them all together and process them once to
+	# avoid the overhead of calling check_requirements repeatedly
+	TMP_FILE="${TMPROOT}/tmp_volatile.$$"
+	rm -f "$TMP_FILE"
+
+	CFGFILES="`ls -1 "${CFGDIR}" | grep -v "^${COREDEF}\$" | sort`"
+	for file in ${CFGFILES}; do
+		cat "${CFGDIR}/${file}" >> "$TMP_FILE"
 	done
 
+	if check_requirements "$TMP_FILE"
+	then
+		apply_cfgfile "$TMP_FILE" "yes"
+	else
+		# Slow path: One or more config files failed requirements.
+		# Process each one individually so the offending one can be
+		# skipped
+		for file in ${CFGFILES}; do
+			apply_cfgfile "${CFGDIR}/${file}"
+		done
+	fi
+	rm "$TMP_FILE"
+
 	[ -e ${ROOT_DIR}/etc/volatile.cache.build ] && sync && mv ${ROOT_DIR}/etc/volatile.cache.build ${ROOT_DIR}/etc/volatile.cache
 fi
 
diff --git a/poky/meta/recipes-core/initscripts/initscripts-1.0/read-only-rootfs-hook.sh b/poky/meta/recipes-core/initscripts/initscripts-1.0/read-only-rootfs-hook.sh
index 1a0328d..bd445dd 100644
--- a/poky/meta/recipes-core/initscripts/initscripts-1.0/read-only-rootfs-hook.sh
+++ b/poky/meta/recipes-core/initscripts/initscripts-1.0/read-only-rootfs-hook.sh
@@ -31,8 +31,13 @@
 	if [ `is_on_read_only_partition /var/lib` = "yes" ]; then
 		grep -q "tmpfs /var/volatile" /proc/mounts || mount /var/volatile
 		mkdir -p /var/volatile/lib
-		cp -a /var/lib/* /var/volatile/lib
-		mount --bind /var/volatile/lib /var/lib
+		mkdir -p /var/volatile/.lib-work
+		# Try to mount using overlay, which is much faster than copying
+		# files. If that fails, fallback to the slower copy
+		if ! mount -t overlay overlay -olowerdir=/var/lib,upperdir=/var/volatile/lib,workdir=/var/volatile/.lib-work /var/lib > /dev/null 2>&1; then
+			cp -a /var/lib/* /var/volatile/lib
+			mount --bind /var/volatile/lib /var/lib
+		fi
 	fi
 fi
 
diff --git a/poky/meta/recipes-core/libxcrypt/libxcrypt_4.0.1.bb b/poky/meta/recipes-core/libxcrypt/libxcrypt_4.0.1.bb
deleted file mode 100644
index 6ed67a6..0000000
--- a/poky/meta/recipes-core/libxcrypt/libxcrypt_4.0.1.bb
+++ /dev/null
@@ -1,32 +0,0 @@
-SUMMARY = "Extended cryptographic library (from glibc)"
-DESCRIPTION = "Forked code from glibc libary to extract only crypto part."
-HOMEPAGE = "https://github.com/besser82/libxcrypt"
-SECTION = "libs"
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM ?= "file://LICENSING;md5=d1cc18f512ded3bd6000f3729f31be08 \
-      file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c \
-"
-
-inherit autotools
-
-SRCREV ?= "089479bb24acd168613757a6f12d63caa95416b4"
-SRCBRANCH ?= "master"
-
-SRC_URI = "git://github.com/besser82/libxcrypt.git;branch=${SRCBRANCH} \
-           "
-
-PROVIDES = "virtual/crypt"
-
-FILES_${PN} = "${libdir}/libcrypt*.so.* ${libdir}/libcrypt-*.so ${libdir}/libowcrypt*.so.* ${libdir}/libowcrypt-*.so"
-
-S = "${WORKDIR}/git"
-
-BUILD_CPPFLAGS = "-I${STAGING_INCDIR_NATIVE} -std=gnu99"
-TARGET_CPPFLAGS = "-I${STAGING_DIR_TARGET}${includedir}"
-
-python () {
-    if not bb.data.inherits_class('nativesdk', d):
-        raise bb.parse.SkipRecipe("Recipe only applies in nativesdk case for now")
-}
-
-BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-core/libxcrypt/libxcrypt_4.1.1.bb b/poky/meta/recipes-core/libxcrypt/libxcrypt_4.1.1.bb
new file mode 100644
index 0000000..465aa96
--- /dev/null
+++ b/poky/meta/recipes-core/libxcrypt/libxcrypt_4.1.1.bb
@@ -0,0 +1,27 @@
+SUMMARY = "Extended cryptographic library (from glibc)"
+DESCRIPTION = "Forked code from glibc libary to extract only crypto part."
+HOMEPAGE = "https://github.com/besser82/libxcrypt"
+SECTION = "libs"
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM ?= "file://LICENSING;md5=cb3ca4cabd2447a37bf186fad6f79852 \
+      file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c \
+"
+
+inherit autotools pkgconfig
+
+SRCREV ?= "21b455b68baad279e6a3936faced16c5e5634376"
+SRCBRANCH ?= "develop"
+
+SRC_URI = "git://github.com/besser82/libxcrypt.git;branch=${SRCBRANCH} \
+           "
+
+PROVIDES = "virtual/crypt"
+
+FILES_${PN} = "${libdir}/libcrypt*.so.* ${libdir}/libcrypt-*.so ${libdir}/libowcrypt*.so.* ${libdir}/libowcrypt-*.so"
+
+S = "${WORKDIR}/git"
+
+BUILD_CPPFLAGS = "-I${STAGING_INCDIR_NATIVE} -std=gnu99"
+TARGET_CPPFLAGS = "-I${STAGING_DIR_TARGET}${includedir}"
+
+BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-core/libxml/libxml2/0001-Fix-infinite-loop-in-LZMA-decompression.patch b/poky/meta/recipes-core/libxml/libxml2/0001-Fix-infinite-loop-in-LZMA-decompression.patch
new file mode 100644
index 0000000..16c2295
--- /dev/null
+++ b/poky/meta/recipes-core/libxml/libxml2/0001-Fix-infinite-loop-in-LZMA-decompression.patch
@@ -0,0 +1,55 @@
+From 28a9dc642ffd759df1e48be247a114f440a6c16e Mon Sep 17 00:00:00 2001
+From: Nick Wellnhofer <wellnhofer@aevum.de>
+Date: Mon, 30 Jul 2018 13:14:11 +0200
+Subject: [PATCH] Fix infinite loop in LZMA decompression
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Check the liblzma error code more thoroughly to avoid infinite loops.
+
+Closes: https://gitlab.gnome.org/GNOME/libxml2/issues/13
+Closes: https://bugzilla.gnome.org/show_bug.cgi?id=794914
+
+This is CVE-2018-9251 and CVE-2018-14567.
+
+Thanks to Dongliang Mu and Simon Wörner for the reports.
+
+CVE: CVE-2018-9251
+CVE: CVE-2018-14567
+Upstream-Status: Backport [https://gitlab.gnome.org/GNOME/libxml2/commit/2240fbf5912054af025fb6e01e26375100275e74]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ xzlib.c | 9 +++++++++
+ 1 file changed, 9 insertions(+)
+
+diff --git a/xzlib.c b/xzlib.c
+index a839169..0ba88cf 100644
+--- a/xzlib.c
++++ b/xzlib.c
+@@ -562,6 +562,10 @@ xz_decomp(xz_statep state)
+                          "internal error: inflate stream corrupt");
+                 return -1;
+             }
++            /*
++             * FIXME: Remapping a couple of error codes and falling through
++             * to the LZMA error handling looks fragile.
++             */
+             if (ret == Z_MEM_ERROR)
+                 ret = LZMA_MEM_ERROR;
+             if (ret == Z_DATA_ERROR)
+@@ -587,6 +591,11 @@ xz_decomp(xz_statep state)
+             xz_error(state, LZMA_PROG_ERROR, "compression error");
+             return -1;
+         }
++        if ((state->how != GZIP) &&
++            (ret != LZMA_OK) && (ret != LZMA_STREAM_END)) {
++            xz_error(state, ret, "lzma error");
++            return -1;
++        }
+     } while (strm->avail_out && ret != LZMA_STREAM_END);
+ 
+     /* update available output and crc check value */
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-core/libxml/libxml2/CVE-2018-14404.patch b/poky/meta/recipes-core/libxml/libxml2/CVE-2018-14404.patch
deleted file mode 100644
index af3e7b2..0000000
--- a/poky/meta/recipes-core/libxml/libxml2/CVE-2018-14404.patch
+++ /dev/null
@@ -1,58 +0,0 @@
-From 29115868c92c81a4119b05ea95b3c91608a0b6e8 Mon Sep 17 00:00:00 2001
-From: Nick Wellnhofer <wellnhofer@aevum.de>
-Date: Mon, 30 Jul 2018 12:54:38 +0200
-Subject: [PATCH] Fix nullptr deref with XPath logic ops
-
-If the XPath stack is corrupted, for example by a misbehaving extension
-function, the "and" and "or" XPath operators could dereference NULL
-pointers. Check that the XPath stack isn't empty and optimize the
-logic operators slightly.
-
-Closes: https://gitlab.gnome.org/GNOME/libxml2/issues/5
-
-Also see
-https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=901817
-https://bugzilla.redhat.com/show_bug.cgi?id=1595985
-
-This is CVE-2018-14404.
-
-Thanks to Guy Inbar for the report.
-
-CVE: CVE-2018-14404
-Upstream-Status: Backport [https://gitlab.gnome.org/GNOME/libxml2/commit/a436374994c47b12d5de1b8b1d191a098fa23594]
-Signed-off-by: Sinan Kaya <okaya@kernel.org>
----
- xpath.c | 10 ++++------
- 1 file changed, 4 insertions(+), 6 deletions(-)
-
-diff --git a/xpath.c b/xpath.c
-index 35274731..3fcdc9e1 100644
---- a/xpath.c
-+++ b/xpath.c
-@@ -13337,9 +13337,8 @@ xmlXPathCompOpEval(xmlXPathParserContextPtr ctxt, xmlXPathStepOpPtr op)
- 		return(0);
- 	    }
-             xmlXPathBooleanFunction(ctxt, 1);
--            arg1 = valuePop(ctxt);
--            arg1->boolval &= arg2->boolval;
--            valuePush(ctxt, arg1);
-+            if (ctxt->value != NULL)
-+                ctxt->value->boolval &= arg2->boolval;
- 	    xmlXPathReleaseObject(ctxt->context, arg2);
-             return (total);
-         case XPATH_OP_OR:
-@@ -13363,9 +13362,8 @@ xmlXPathCompOpEval(xmlXPathParserContextPtr ctxt, xmlXPathStepOpPtr op)
- 		return(0);
- 	    }
-             xmlXPathBooleanFunction(ctxt, 1);
--            arg1 = valuePop(ctxt);
--            arg1->boolval |= arg2->boolval;
--            valuePush(ctxt, arg1);
-+            if (ctxt->value != NULL)
-+                ctxt->value->boolval |= arg2->boolval;
- 	    xmlXPathReleaseObject(ctxt->context, arg2);
-             return (total);
-         case XPATH_OP_EQUAL:
--- 
-2.19.0
-
diff --git a/poky/meta/recipes-core/libxml/libxml2/ansidecl.patch b/poky/meta/recipes-core/libxml/libxml2/ansidecl.patch
deleted file mode 100644
index 1085c68..0000000
--- a/poky/meta/recipes-core/libxml/libxml2/ansidecl.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-Sadly cmake is broken. If it sees this reference and ansidecl is present, it will add a 
-dependency upon it, even if HAVE_ANSIDEC_H is never set.
-
-The easiest solution is to remove these lines, otherwise recipes like libzypp can have a 
-dependency on the ansidecl.h header via cmake. This can lead to odd results if the 
-header is removed (clean binutils) and then the code is recompiled.
-
-RP 2012/7/10
-
-Upstream-Status: Inappropriate [its really a cmake bug]
-
-diff --git a/configure.ac b/configure.ac
-index 0260281..fdb58e9 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -484 +483,0 @@ AC_CHECK_HEADERS([time.h])
--AC_CHECK_HEADERS([ansidecl.h])
-diff --git a/include/libxml/xmlversion.h.in b/include/libxml/xmlversion.h.in
-index b173be9..d10f975 100644
---- a/include/libxml/xmlversion.h.in
-+++ b/include/libxml/xmlversion.h.in
-@@ -413,3 +412,0 @@ XMLPUBFUN void XMLCALL xmlCheckVersion(int version);
--#ifdef HAVE_ANSIDECL_H
--#include <ansidecl.h>
--#endif
diff --git a/poky/meta/recipes-core/libxml/libxml2/fix-CVE-2017-8872.patch b/poky/meta/recipes-core/libxml/libxml2/fix-CVE-2017-8872.patch
new file mode 100644
index 0000000..42a4b0e
--- /dev/null
+++ b/poky/meta/recipes-core/libxml/libxml2/fix-CVE-2017-8872.patch
@@ -0,0 +1,65 @@
+Upstream-Status: Backport
+CVE: CVE-2017-8872
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+From 123234f2cfcd9e9b9f83047eee1dc17b4c3f4407 Mon Sep 17 00:00:00 2001
+From: Nick Wellnhofer <wellnhofer@aevum.de>
+Date: Tue, 11 Sep 2018 14:52:07 +0200
+Subject: [PATCH] Free input buffer in xmlHaltParser
+
+This avoids miscalculation of available bytes.
+
+Thanks to Yunho Kim for the report.
+
+Closes: #26
+---
+ parser.c                     |  5 +++++
+ result/errors/759573.xml.err | 17 +++++++----------
+ 2 files changed, 12 insertions(+), 10 deletions(-)
+
+diff --git a/parser.c b/parser.c
+index ca9fde2c..5813a664 100644
+--- a/parser.c
++++ b/parser.c
+@@ -12462,7 +12462,12 @@ xmlHaltParser(xmlParserCtxtPtr ctxt) {
+ 	    ctxt->input->free((xmlChar *) ctxt->input->base);
+ 	    ctxt->input->free = NULL;
+ 	}
++        if (ctxt->input->buf != NULL) {
++            xmlFreeParserInputBuffer(ctxt->input->buf);
++            ctxt->input->buf = NULL;
++        }
+ 	ctxt->input->cur = BAD_CAST"";
++        ctxt->input->length = 0;
+ 	ctxt->input->base = ctxt->input->cur;
+         ctxt->input->end = ctxt->input->cur;
+     }
+diff --git a/result/errors/759573.xml.err b/result/errors/759573.xml.err
+index 554039f6..38ef5c40 100644
+--- a/result/errors/759573.xml.err
++++ b/result/errors/759573.xml.err
+@@ -21,14 +21,11 @@ Entity: line 1:
+             ^
+ ./test/errors/759573.xml:1: parser error : internal error: xmlParseInternalSubset: error detected in Markup declaration
+ 
+-<?h?><!DOCTYPEt[<!ELEMENT t (A)><!ENTITY % xx '&#37;<![INCLUDE[000&#37;&#3000;00
+-     ^
++
++^
+ ./test/errors/759573.xml:1: parser error : DOCTYPE improperly terminated
+-<?h?><!DOCTYPEt[<!ELEMENT t (A)><!ENTITY % xx '&#37;<![INCLUDE[000&#37;&#3000;00
+-     ^
+-./test/errors/759573.xml:1: parser error : StartTag: invalid element name
+-<?h?><!DOCTYPEt[<!ELEMENT t (A)><!ENTITY % xx '&#37;<![INCLUDE[000&#37;&#3000;00
+-      ^
+-./test/errors/759573.xml:1: parser error : Extra content at the end of the document
+-<?h?><!DOCTYPEt[<!ELEMENT t (A)><!ENTITY % xx '&#37;<![INCLUDE[000&#37;&#3000;00
+-      ^
++
++^
++./test/errors/759573.xml:1: parser error : Start tag expected, '<' not found
++
++^
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/libxml/libxml2/fix-CVE-2018-14404.patch b/poky/meta/recipes-core/libxml/libxml2/fix-CVE-2018-14404.patch
new file mode 100644
index 0000000..21668e2
--- /dev/null
+++ b/poky/meta/recipes-core/libxml/libxml2/fix-CVE-2018-14404.patch
@@ -0,0 +1,45 @@
+libxml2-2.9.8: Fix CVE-2018-14404
+
+[No upstream tracking] -- https://gitlab.gnome.org/GNOME/libxml2/issues/5
+ -- https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=901817
+ -- https://bugzilla.redhat.com/show_bug.cgi?id=1595985
+
+xpath: Fix nullptr deref with XPath logic ops
+
+If the XPath stack is corrupted, for example by a misbehaving extension
+function, the "and" and "or" XPath operators could dereference NULL
+pointers. Check that the XPath stack isn't empty and optimize the
+logic operators slightly.
+
+Upstream-Status: Backport [https://gitlab.gnome.org/GNOME/libxml2/commit/a436374994c47b12d5de1b8b1d191a098fa23594]
+CVE: CVE-2018-14404
+Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
+
+diff --git a/xpath.c b/xpath.c
+index f440696..75cac5c 100644
+--- a/xpath.c
++++ b/xpath.c
+@@ -13297,9 +13297,8 @@ xmlXPathCompOpEval(xmlXPathParserContextPtr ctxt, xmlXPathStepOpPtr op)
+ 		return(0);
+ 	    }
+             xmlXPathBooleanFunction(ctxt, 1);
+-            arg1 = valuePop(ctxt);
+-            arg1->boolval &= arg2->boolval;
+-            valuePush(ctxt, arg1);
++	    if (ctxt->value != NULL)
++		ctxt->value->boolval &= arg2->boolval;
+ 	    xmlXPathReleaseObject(ctxt->context, arg2);
+             return (total);
+         case XPATH_OP_OR:
+@@ -13323,9 +13322,8 @@ xmlXPathCompOpEval(xmlXPathParserContextPtr ctxt, xmlXPathStepOpPtr op)
+ 		return(0);
+ 	    }
+             xmlXPathBooleanFunction(ctxt, 1);
+-            arg1 = valuePop(ctxt);
+-            arg1->boolval |= arg2->boolval;
+-            valuePush(ctxt, arg1);
++	    if (ctxt->value != NULL)
++		ctxt->value->boolval |= arg2->boolval;
+ 	    xmlXPathReleaseObject(ctxt->context, arg2);
+             return (total);
+         case XPATH_OP_EQUAL:
diff --git a/poky/meta/recipes-core/libxml/libxml2/runtest.patch b/poky/meta/recipes-core/libxml/libxml2/runtest.patch
index cb171d5..544dc05 100644
--- a/poky/meta/recipes-core/libxml/libxml2/runtest.patch
+++ b/poky/meta/recipes-core/libxml/libxml2/runtest.patch
@@ -6,8 +6,8 @@
 Upstream-Status: Backport
 
 diff -uNr a/Makefile.am b/Makefile.am
---- a/Makefile.am	2017-08-28 15:01:14.000000000 +0200
-+++ b/Makefile.am	2017-09-05 08:06:05.752287323 +0200
+--- a/Makefile.am	2017-12-02 09:58:10.000000000 +0100
++++ b/Makefile.am	2018-03-20 08:27:34.360505864 +0100
 @@ -202,6 +202,15 @@
  #testOOM_DEPENDENCIES = $(DEPS)
  #testOOM_LDADD= $(LDADDS)
@@ -24,10 +24,9 @@
  runtests: runtest$(EXEEXT) testrecurse$(EXEEXT) testapi$(EXEEXT) \
            testchar$(EXEEXT) testdict$(EXEEXT) runxmlconf$(EXEEXT)
  	[ -d test   ] || $(LN_S) $(srcdir)/test   .
-
 diff -uNr a/runsuite.c b/runsuite.c
---- a/runsuite.c	2013-04-12 16:17:11.462823238 +0200
-+++ b/runsuite.c	2013-04-17 14:07:24.352693211 +0200
+--- a/runsuite.c	2016-06-07 12:04:14.000000000 +0200
++++ b/runsuite.c	2018-03-20 08:27:57.478817247 +0100
 @@ -1162,6 +1162,7 @@
  
      if (logfile != NULL)
@@ -37,17 +36,19 @@
  }
  #else /* !SCHEMAS */
 diff -uNr a/runtest.c b/runtest.c
---- a/runtest.c	2013-04-16 13:19:15.087997290 +0200
-+++ b/runtest.c	2013-04-17 14:08:29.529949655 +0200
-@@ -4386,6 +4386,7 @@
- 	    err++;
- 	}
+--- a/runtest.c	2017-11-13 22:00:17.000000000 +0100
++++ b/runtest.c	2018-03-20 08:28:50.859047551 +0100
+@@ -4496,7 +4496,8 @@
      }
+ 
+     xmlCharEncCloseFunc(ebcdicHandler);
+-
++    
 +    printf("%s: %s\n", (err == 0) ? "PASS" : "FAIL", tst->desc);
      return(err);
  }
  
-@@ -4455,6 +4456,7 @@
+@@ -4573,6 +4574,7 @@
      xmlCleanupParser();
      xmlMemoryDump();
  
@@ -56,8 +57,8 @@
  }
  
 diff -uNr a/runxmlconf.c b/runxmlconf.c
---- a/runxmlconf.c	2013-04-16 12:53:49.900982990 +0200
-+++ b/runxmlconf.c	2013-04-17 14:09:21.111778104 +0200
+--- a/runxmlconf.c	2016-06-07 12:04:14.000000000 +0200
++++ b/runxmlconf.c	2018-03-20 08:29:17.944862893 +0100
 @@ -595,6 +595,7 @@
  
      if (logfile != NULL)
@@ -67,9 +68,9 @@
  }
  
 diff -uNr a/testapi.c b/testapi.c
---- a/testapi.c	2013-04-12 16:16:57.763417659 +0200
-+++ b/testapi.c	2013-04-17 14:10:28.876924881 +0200
-@@ -1245,49 +1245,91 @@
+--- a/testapi.c	2018-01-25 07:39:15.000000000 +0100
++++ b/testapi.c	2018-03-20 09:08:35.323980145 +0100
+@@ -1246,49 +1246,91 @@
  testlibxml2(void)
  {
      int test_ret = 0;
@@ -200,9 +201,19 @@
      return(test_ret);
  }
  
+diff -uNr a/testdict.c b/testdict.c
+--- a/testdict.c	2016-06-07 12:04:14.000000000 +0200
++++ b/testdict.c	2018-03-20 08:59:16.864275812 +0100
+@@ -440,5 +440,6 @@
+     clean_strings();
+     xmlCleanupParser();
+     xmlMemoryDump();
++    printf("%s: testdict\n\n", (ret == 0) ? "PASS" : "FAIL");
+     return(ret);
+ }
 diff -uNr a/testchar.c b/testchar.c
---- a/testchar.c	2013-04-17 10:50:30.250147418 +0200
-+++ b/testchar.c	2013-04-18 16:11:28.455733800 +0200
+--- a/testchar.c	2016-06-07 12:04:14.000000000 +0200
++++ b/testchar.c	2018-03-20 09:11:20.383573912 +0100
 @@ -23,7 +23,7 @@
  char document1[100] = "<doc>XXXX</doc>";
  char document2[100] = "<doc foo='XXXX'/>";
@@ -222,7 +233,7 @@
  		    "Failed to detect invalid char for Byte 0x%02X: %c\n",
  		        i, i);
 +		return(1);
-+		}
++	    }
  	}
  
  	else if ((i == '<') || (i == '&')) {
@@ -230,8 +241,8 @@
 +	    if ((lastError == 0) || (res != NULL)) {
  	        fprintf(stderr,
  		    "Failed to detect illegal char %c for Byte 0x%02X\n", i, i);
-+			return(1);
-+		}
++		return(1);
++	    }
  	}
  	else if (((i < 0x20) || (i >= 0x80)) &&
  	    (i != 0x9) && (i != 0xA) && (i != 0xD)) {
@@ -239,8 +250,8 @@
 +	    if ((lastError != XML_ERR_INVALID_CHAR) && (res != NULL)) {
  	        fprintf(stderr,
  		    "Failed to detect invalid char for Byte 0x%02X\n", i);
-+			return(1);
-+		}
++		return(1);
++	    }
  	}
  	else if (res == NULL) {
  	    fprintf(stderr,
@@ -250,7 +261,7 @@
  	if (res != NULL)
  	    xmlFreeDoc(res);
      }
-+	return(0);
++    return(0);
  }
  
 -static void testDocumentRangeByte2(xmlParserCtxtPtr ctxt, char *document,
@@ -268,7 +279,7 @@
  		"Failed to detect invalid char for Bytes 0x%02X 0x%02X\n",
  			i, j);
 +		return(1);
-+		}
++	    }
  	}
  
  	/*
@@ -282,7 +293,7 @@
  	    "Failed to detect invalid char for Bytes 0x%02X 0x%02X\n",
  			i, j);
 +		return(1);
-+		}
++	    }
  	}
  
  	/*
@@ -296,7 +307,7 @@
  	    "Failed to detect invalid char for Bytes 0x%02X 0x%02X\n",
  			i, j);
 +		return(1);
-+		}
++	    }
  	}
  
  	/*
@@ -310,7 +321,7 @@
  	    "Failed to detect invalid char for Bytes 0x%02X 0x%02X 0x00\n",
  			i, j);
 +		return(1);
-+		}
++	    }
  	}
  
  	/*
@@ -318,13 +329,13 @@
  	else if ((lastError != 0) || (res == NULL)) {
  	    fprintf(stderr,
  		"Failed to parse document for Bytes 0x%02X 0x%02X\n", i, j);
-+		return(1);
++	    return(1);
  	}
  	if (res != NULL)
  	    xmlFreeDoc(res);
      }
      }
-+	return(0);
++    return(0);
  }
  
  /**
@@ -438,20 +449,20 @@
 +	    if (lastError != XML_ERR_INVALID_CHAR) {
  	        fprintf(stderr,
  		    "Failed to detect invalid char for Byte 0x%02X\n", i);
-+			return(1);
-+		}
++		return(1);
++	    }
  	} else if (i == 0xD) {
 -	    if ((c != 0xA) || (len != 1))
 +	    if ((c != 0xA) || (len != 1)) {
  		fprintf(stderr, "Failed to convert char for Byte 0x%02X\n", i);
 +		return(1);
-+		}
++	    }
  	} else if ((c != i) || (len != 1)) {
  	    fprintf(stderr, "Failed to parse char for Byte 0x%02X\n", i);
-+		return(1);
++	    return(1);
  	}
      }
-+	return(0);
++    return(0);
  }
  
 -static void testCharRangeByte2(xmlParserCtxtPtr ctxt, char *data) {
@@ -468,8 +479,8 @@
  		    fprintf(stderr,
  		    "Failed to detect invalid char for Bytes 0x%02X 0x%02X\n",
  		            i, j);
-+			return(1);
-+			}
++		    return(1);
++		}
  	    }
  
  	    /*
@@ -482,8 +493,8 @@
  		    fprintf(stderr,
  		"Failed to detect invalid char for Bytes 0x%02X 0x%02X: %d\n",
  		            i, j, c);
-+			return(1);
-+			}
++		    return(1);
++		}
  	    }
  
  	    /*
@@ -496,8 +507,8 @@
  		    fprintf(stderr,
  		"Failed to detect invalid char for Bytes 0x%02X 0x%02X: %d\n",
  		            i, j, c);
-+			return(1);
-+			}
++		    return(1);
++		}
  	    }
  
  	    /*
@@ -510,8 +521,8 @@
  		    fprintf(stderr,
  		"Failed to detect invalid char for Bytes 0x%02X 0x%02X 0x00\n",
  		            i, j);
-+			return(1);
-+			}
++		    return(1);
++		}
  	    }
  
              /*
@@ -531,7 +542,7 @@
  	    }
          }
      }
-+	return(0);
++    return(0);
  }
  
 -static void testCharRangeByte3(xmlParserCtxtPtr ctxt, char *data) {
@@ -549,7 +560,7 @@
  	"Failed to detect invalid char for Bytes 0x%02X 0x%02X 0x%02X 0x%02X\n",
  			i, j, K, data[3]);
 +		return(1);
-+		}
++	    }
  	}
  
          /*
@@ -562,7 +573,7 @@
  	"Failed to detect invalid char for Bytes 0x%02X 0x%02X 0x%02X\n",
  			i, j, K);
 +		return(1);
-+		}
++	    }
  	}
  
  	/*
@@ -576,7 +587,7 @@
  	    "Failed to detect invalid char for Bytes 0x%02X 0x%02X 0x%02X\n",
  			i, j, K);
 +		return(1);
-+		}
++	    }
  	}
  
          /*
@@ -590,7 +601,7 @@
  	"Failed to detect invalid char 0x%04X for Bytes 0x%02X 0x%02X 0x%02X\n",
  			value, i, j, K);
 +		return(1);
-+		}
++	    }
  	}
  
  	/*
@@ -598,7 +609,7 @@
  	    fprintf(stderr,
  		"Failed to parse char for Bytes 0x%02X 0x%02X 0x%02X\n",
  		    i, j, K);
-+		return(1);
++	    return(1);
  	}
  
  	/*
@@ -606,12 +617,12 @@
  	    fprintf(stderr,
      "Failed to parse char for Bytes 0x%02X 0x%02X 0x%02X: expect %d got %d\n",
  		i, j, data[2], value, c);
-+		return(1);
++	    return(1);
  	}
      }
      }
      }
-+	return(0);
++    return(0);
  }
  
 -static void testCharRangeByte4(xmlParserCtxtPtr ctxt, char *data) {
@@ -629,7 +640,7 @@
    "Failed to detect invalid char for Bytes 0x%02X 0x%02X 0x%02X 0x%02X\n",
  			i, j, K, data[3]);
 +		return(1);
-+		}
++	    }
  	}
  
          /*
@@ -643,7 +654,7 @@
  	"Failed to detect invalid char for Bytes 0x%02X 0x%02X 0x%02X 0x%02X\n",
  			i, j, K, L);
 +		return(1);
-+		}
++	    }
  	}
  
  	/*
@@ -657,7 +668,7 @@
  	"Failed to detect invalid char for Bytes 0x%02X 0x%02X 0x%02X 0x%02X\n",
  			i, j, K, L);
 +		return(1);
-+		}
++	    }
  	}
  
          /*
@@ -671,7 +682,7 @@
  "Failed to detect invalid char 0x%04X for Bytes 0x%02X 0x%02X 0x%02X 0x%02X\n",
  			value, i, j, K, L);
 +		return(1);
-+		}
++	    }
  	}
  
  	/*
@@ -679,7 +690,7 @@
  	    fprintf(stderr,
  		"Failed to parse char for Bytes 0x%02X 0x%02X 0x%02X\n",
  		    i, j, K);
-+		return(1);
++	    return(1);
  	}
  
  	/*
@@ -687,13 +698,13 @@
  	    fprintf(stderr,
      "Failed to parse char for Bytes 0x%02X 0x%02X 0x%02X: expect %d got %d\n",
  		i, j, data[2], value, c);
-+		return(1);
++	    return(1);
  	}
      }
      }
      }
      }
-+	return(0);
++    return(0);
  }
  
  /**
@@ -722,13 +733,13 @@
                                             XML_CHAR_ENCODING_NONE);
      if (buf == NULL) {
          fprintf(stderr, "Failed to allocate input buffer\n");
-+        test_ret = 1;
++	test_ret = 1;
  	goto error;
      }
      input = xmlNewInputStream(ctxt);
      if (input == NULL) {
          xmlFreeParserInputBuffer(buf);
-+        test_ret = 1;
++	test_ret = 1;
  	goto error;
      }
      input->filename = NULL;
@@ -777,20 +788,10 @@
  
      /*
       * Cleanup function for the XML library.
-diff -uNr a/testdict.c b/testdict.c
---- a/testdict.c	2013-04-16 15:08:42.971177193 +0200
-+++ b/testdict.c	2013-04-18 15:59:00.699482439 +0200
-@@ -440,5 +440,6 @@
-     clean_strings();
-     xmlCleanupParser();
-     xmlMemoryDump();
-+    printf("%s: testdict\n\n", (ret == 0) ? "PASS" : "FAIL");
-     return(ret);
- }
 diff -uNr a/testlimits.c b/testlimits.c
---- a/testlimits.c	2013-04-12 16:16:36.180354177 +0200
-+++ b/testlimits.c	2013-04-17 14:03:17.203092987 +0200
-@@ -1630,5 +1630,6 @@
+--- a/testlimits.c	2016-11-07 09:41:40.000000000 +0100
++++ b/testlimits.c	2018-03-20 08:59:38.965581280 +0100
+@@ -1634,5 +1634,6 @@
      xmlCleanupParser();
      xmlMemoryDump();
  
@@ -798,8 +799,8 @@
      return(ret);
  }
 diff -uNr a/testrecurse.c b/testrecurse.c
---- a/testrecurse.c	2013-04-16 13:19:49.366536295 +0200
-+++ b/testrecurse.c	2013-04-17 14:06:27.367091622 +0200
+--- a/testrecurse.c	2017-10-26 09:54:40.000000000 +0200
++++ b/testrecurse.c	2018-03-20 09:00:46.781628749 +0100
 @@ -892,6 +892,7 @@
  	    err++;
  	}
diff --git a/poky/meta/recipes-core/libxml/libxml2_2.9.7.bb b/poky/meta/recipes-core/libxml/libxml2_2.9.7.bb
deleted file mode 100644
index c749a81..0000000
--- a/poky/meta/recipes-core/libxml/libxml2_2.9.7.bb
+++ /dev/null
@@ -1,111 +0,0 @@
-SUMMARY = "XML C Parser Library and Toolkit"
-DESCRIPTION = "The XML Parser Library allows for manipulation of XML files.  Libxml2 exports Push and Pull type parser interfaces for both XML and HTML.  It can do DTD validation at parse time, on a parsed document instance or with an arbitrary DTD.  Libxml2 includes complete XPath, XPointer and Xinclude implementations.  It also has a SAX like interface, which is designed to be compatible with Expat."
-HOMEPAGE = "http://www.xmlsoft.org/"
-BUGTRACKER = "http://bugzilla.gnome.org/buglist.cgi?product=libxml2"
-SECTION = "libs"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://Copyright;md5=2044417e2e5006b65a8b9067b683fcf1 \
-                    file://hash.c;beginline=6;endline=15;md5=96f7296605eae807670fb08947829969 \
-                    file://list.c;beginline=4;endline=13;md5=cdbfa3dee51c099edb04e39f762ee907 \
-                    file://trio.c;beginline=5;endline=14;md5=6c025753c86d958722ec76e94cae932e"
-
-DEPENDS = "zlib virtual/libiconv"
-
-SRC_URI = "http://www.xmlsoft.org/sources/libxml2-${PV}.tar.gz;name=libtar \
-           http://www.w3.org/XML/Test/xmlts20080827.tar.gz;name=testtar \
-           file://libxml-64bit.patch \
-           file://ansidecl.patch \
-           file://runtest.patch \
-           file://run-ptest \
-           file://python-sitepackages-dir.patch \
-           file://libxml-m4-use-pkgconfig.patch \
-           file://0001-Make-ptest-run-the-python-tests-if-python-is-enabled.patch \
-           file://fix-execution-of-ptests.patch \
-           file://CVE-2018-14404.patch \
-           "
-
-SRC_URI[libtar.md5sum] = "896608641a08b465098a40ddf51cefba"
-SRC_URI[libtar.sha256sum] = "f63c5e7d30362ed28b38bfa1ac6313f9a80230720b7fb6c80575eeab3ff5900c"
-SRC_URI[testtar.md5sum] = "ae3d1ebe000a3972afa104ca7f0e1b4a"
-SRC_URI[testtar.sha256sum] = "96151685cec997e1f9f3387e3626d61e6284d4d6e66e0e440c209286c03e9cc7"
-
-BINCONFIG = "${bindir}/xml2-config"
-
-PACKAGECONFIG ??= "python \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} \
-"
-PACKAGECONFIG[python] = "--with-python=${PYTHON},--without-python,python3"
-PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
-
-inherit autotools pkgconfig binconfig-disabled ptest
-
-inherit ${@bb.utils.contains('PACKAGECONFIG', 'python', 'python3native', '', d)}
-
-RDEPENDS_${PN}-ptest += "make ${@bb.utils.contains('PACKAGECONFIG', 'python', 'libgcc python3-core python3-logging python3-shell  python3-stringold python3-threading python3-unittest ${PN}-python', '', d)}"
-
-RDEPENDS_${PN}-python += "${@bb.utils.contains('PACKAGECONFIG', 'python', 'python3-core', '', d)}"
-
-RDEPENDS_${PN}-ptest_append_libc-glibc = " glibc-gconv-ebcdic-us \
-                                           glibc-gconv-ibm1141 \
-                                           glibc-gconv-iso8859-5 \
-                                           glibc-gconv-euc-jp \
-                                           locale-base-en-us \
-                                         "
-
-export PYTHON_SITE_PACKAGES="${PYTHON_SITEPACKAGES_DIR}"
-
-# WARNING: zlib is required for RPM use
-EXTRA_OECONF = "--without-debug --without-legacy --with-catalog --without-docbook --with-c14n --without-lzma --with-fexceptions"
-EXTRA_OECONF_class-native = "--without-legacy --without-docbook --with-c14n --without-lzma --with-zlib"
-EXTRA_OECONF_class-nativesdk = "--without-legacy --without-docbook --with-c14n --without-lzma --with-zlib"
-EXTRA_OECONF_linuxstdbase = "--with-debug --with-legacy --with-docbook --with-c14n --without-lzma --with-zlib"
-
-python populate_packages_prepend () {
-    # autonamer would call this libxml2-2, but we don't want that
-    if d.getVar('DEBIAN_NAMES'):
-        d.setVar('PKG_libxml2', '${MLPREFIX}libxml2')
-}
-
-PACKAGES += "${PN}-utils ${PN}-python"
-
-FILES_${PN}-staticdev += "${PYTHON_SITEPACKAGES_DIR}/*.a"
-FILES_${PN}-dev += "${libdir}/xml2Conf.sh ${libdir}/cmake/*"
-FILES_${PN}-utils += "${bindir}/*"
-FILES_${PN}-python += "${PYTHON_SITEPACKAGES_DIR}"
-
-do_configure_prepend () {
-	# executables take longer to package: these should not be executable
-	find ${WORKDIR}/xmlconf/ -type f -exec chmod -x {} \+
-}
-
-do_compile_ptest() {
-	oe_runmake check-am
-}
-
-do_install_ptest () {
-	cp -r ${WORKDIR}/xmlconf ${D}${PTEST_PATH}
-	if [ "${@bb.utils.filter('PACKAGECONFIG', 'python', d)}" ]; then
-		sed -i -e 's|^\(PYTHON = \).*|\1${USRBINPATH}/${PYTHON_PN}|' \
-		    ${D}${PTEST_PATH}/python/tests/Makefile
-		grep -lrZ '#!/usr/bin/python' ${D}${PTEST_PATH}/python |
-			xargs -0 sed -i -e 's|/usr/bin/python|${USRBINPATH}/${PYTHON_PN}|'
-	fi
-	#Remove build host references from various Makefiles
-	find "${D}${PTEST_PATH}" -name Makefile -type f -exec \
-	    sed -i \
-	    -e 's,--sysroot=${STAGING_DIR_TARGET},,g' \
-	    -e 's|${DEBUG_PREFIX_MAP}||g' \
-	    -e 's:${HOSTTOOLS_DIR}/::g' \
-	    -e 's:${RECIPE_SYSROOT_NATIVE}::g' \
-	    -e 's:${RECIPE_SYSROOT}::g' \
-	    -e 's:${BASE_WORKDIR}/${MULTIMACH_TARGET_SYS}::g' \
-	    -e '/^RELDATE/d' \
-	    {} +
-}
-
-do_install_append_class-native () {
-	# Docs are not needed in the native case
-	rm ${D}${datadir}/gtk-doc -rf
-}
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-core/libxml/libxml2_2.9.8.bb b/poky/meta/recipes-core/libxml/libxml2_2.9.8.bb
new file mode 100644
index 0000000..740bf56
--- /dev/null
+++ b/poky/meta/recipes-core/libxml/libxml2_2.9.8.bb
@@ -0,0 +1,113 @@
+SUMMARY = "XML C Parser Library and Toolkit"
+DESCRIPTION = "The XML Parser Library allows for manipulation of XML files.  Libxml2 exports Push and Pull type parser interfaces for both XML and HTML.  It can do DTD validation at parse time, on a parsed document instance or with an arbitrary DTD.  Libxml2 includes complete XPath, XPointer and Xinclude implementations.  It also has a SAX like interface, which is designed to be compatible with Expat."
+HOMEPAGE = "http://www.xmlsoft.org/"
+BUGTRACKER = "http://bugzilla.gnome.org/buglist.cgi?product=libxml2"
+SECTION = "libs"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://Copyright;md5=2044417e2e5006b65a8b9067b683fcf1 \
+                    file://hash.c;beginline=6;endline=15;md5=96f7296605eae807670fb08947829969 \
+                    file://list.c;beginline=4;endline=13;md5=cdbfa3dee51c099edb04e39f762ee907 \
+                    file://trio.c;beginline=5;endline=14;md5=6c025753c86d958722ec76e94cae932e"
+
+DEPENDS = "zlib virtual/libiconv"
+
+SRC_URI = "http://www.xmlsoft.org/sources/libxml2-${PV}.tar.gz;name=libtar \
+           http://www.w3.org/XML/Test/xmlts20080827.tar.gz;subdir=${BP};name=testtar \
+           file://libxml-64bit.patch \
+           file://runtest.patch \
+           file://run-ptest \
+           file://python-sitepackages-dir.patch \
+           file://libxml-m4-use-pkgconfig.patch \
+           file://0001-Make-ptest-run-the-python-tests-if-python-is-enabled.patch \
+           file://fix-execution-of-ptests.patch \
+           file://fix-CVE-2017-8872.patch \
+           file://fix-CVE-2018-14404.patch \
+           file://0001-Fix-infinite-loop-in-LZMA-decompression.patch \
+           "
+
+SRC_URI[libtar.md5sum] = "b786e353e2aa1b872d70d5d1ca0c740d"
+SRC_URI[libtar.sha256sum] = "0b74e51595654f958148759cfef0993114ddccccbb6f31aee018f3558e8e2732"
+SRC_URI[testtar.md5sum] = "ae3d1ebe000a3972afa104ca7f0e1b4a"
+SRC_URI[testtar.sha256sum] = "96151685cec997e1f9f3387e3626d61e6284d4d6e66e0e440c209286c03e9cc7"
+
+BINCONFIG = "${bindir}/xml2-config"
+
+PACKAGECONFIG ??= "python \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} \
+"
+PACKAGECONFIG[python] = "--with-python=${PYTHON},--without-python,python3"
+PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
+
+inherit autotools pkgconfig binconfig-disabled ptest
+
+inherit ${@bb.utils.contains('PACKAGECONFIG', 'python', 'python3native', '', d)}
+
+RDEPENDS_${PN}-ptest += "make ${@bb.utils.contains('PACKAGECONFIG', 'python', 'libgcc python3-core python3-logging python3-shell  python3-stringold python3-threading python3-unittest ${PN}-python', '', d)}"
+
+RDEPENDS_${PN}-python += "${@bb.utils.contains('PACKAGECONFIG', 'python', 'python3-core', '', d)}"
+
+RDEPENDS_${PN}-ptest_append_libc-glibc = " glibc-gconv-ebcdic-us \
+                                           glibc-gconv-ibm1141 \
+                                           glibc-gconv-iso8859-5 \
+                                           glibc-gconv-euc-jp \
+                                           locale-base-en-us \
+                                         "
+
+export PYTHON_SITE_PACKAGES="${PYTHON_SITEPACKAGES_DIR}"
+
+# WARNING: zlib is required for RPM use
+EXTRA_OECONF = "--without-debug --without-legacy --with-catalog --without-docbook --with-c14n --without-lzma --with-fexceptions"
+EXTRA_OECONF_class-native = "--without-legacy --without-docbook --with-c14n --without-lzma --with-zlib"
+EXTRA_OECONF_class-nativesdk = "--without-legacy --without-docbook --with-c14n --without-lzma --with-zlib"
+EXTRA_OECONF_linuxstdbase = "--with-debug --with-legacy --with-docbook --with-c14n --without-lzma --with-zlib"
+
+python populate_packages_prepend () {
+    # autonamer would call this libxml2-2, but we don't want that
+    if d.getVar('DEBIAN_NAMES'):
+        d.setVar('PKG_libxml2', '${MLPREFIX}libxml2')
+}
+
+PACKAGE_BEFORE_PN += "${PN}-utils"
+PACKAGES += "${PN}-python"
+
+FILES_${PN}-staticdev += "${PYTHON_SITEPACKAGES_DIR}/*.a"
+FILES_${PN}-dev += "${libdir}/xml2Conf.sh ${libdir}/cmake/*"
+FILES_${PN}-utils = "${bindir}/*"
+FILES_${PN}-python = "${PYTHON_SITEPACKAGES_DIR}"
+
+do_configure_prepend () {
+	# executables take longer to package: these should not be executable
+	find ${S}/xmlconf/ -type f -exec chmod -x {} \+
+}
+
+do_compile_ptest() {
+	oe_runmake check-am
+}
+
+do_install_ptest () {
+	cp -r ${S}/xmlconf ${D}${PTEST_PATH}
+	if [ "${@bb.utils.filter('PACKAGECONFIG', 'python', d)}" ]; then
+		sed -i -e 's|^\(PYTHON = \).*|\1${USRBINPATH}/${PYTHON_PN}|' \
+		    ${D}${PTEST_PATH}/python/tests/Makefile
+		grep -lrZ '#!/usr/bin/python' ${D}${PTEST_PATH}/python |
+			xargs -0 sed -i -e 's|/usr/bin/python|${USRBINPATH}/${PYTHON_PN}|'
+	fi
+	#Remove build host references from various Makefiles
+	find "${D}${PTEST_PATH}" -name Makefile -type f -exec \
+	    sed -i \
+	    -e 's,--sysroot=${STAGING_DIR_TARGET},,g' \
+	    -e 's|${DEBUG_PREFIX_MAP}||g' \
+	    -e 's:${HOSTTOOLS_DIR}/::g' \
+	    -e 's:${RECIPE_SYSROOT_NATIVE}::g' \
+	    -e 's:${RECIPE_SYSROOT}::g' \
+	    -e 's:${BASE_WORKDIR}/${MULTIMACH_TARGET_SYS}::g' \
+	    -e '/^RELDATE/d' \
+	    {} +
+}
+
+do_install_append_class-native () {
+	# Docs are not needed in the native case
+	rm ${D}${datadir}/gtk-doc -rf
+}
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-core/meta/buildtools-tarball.bb b/poky/meta/recipes-core/meta/buildtools-tarball.bb
index d98a9c9..91df6f1 100644
--- a/poky/meta/recipes-core/meta/buildtools-tarball.bb
+++ b/poky/meta/recipes-core/meta/buildtools-tarball.bb
@@ -10,6 +10,8 @@
     nativesdk-python3-modules \
     nativesdk-python3-misc \
     nativesdk-python3-git \
+    nativesdk-python3-testtools \
+    nativesdk-python3-subunit \
     nativesdk-ncurses-terminfo-base \
     nativesdk-chrpath \
     nativesdk-tar \
@@ -21,6 +23,8 @@
     nativesdk-wget \
     nativesdk-ca-certificates \
     nativesdk-texinfo \
+    nativesdk-libnss-nis \
+    nativesdk-rpcsvc-proto \
     "
 
 MULTIMACH_TARGET_SYS = "${SDK_ARCH}-nativesdk${SDK_VENDOR}-${SDK_OS}"
diff --git a/poky/meta/recipes-core/meta/dummy-sdk-package.inc b/poky/meta/recipes-core/meta/dummy-sdk-package.inc
index ed83dd7..eafcb82 100644
--- a/poky/meta/recipes-core/meta/dummy-sdk-package.inc
+++ b/poky/meta/recipes-core/meta/dummy-sdk-package.inc
@@ -1,6 +1,8 @@
 SUMMARY = "Dummy packages which handle excluding packages from the sdk, e.g. ensuring perl is excluded from buildtools"
 LICENSE = "MIT"
 
+PACKAGE_ARCH = "all"
+
 inherit allarch
 
 python() {
diff --git a/poky/meta/recipes-core/meta/meta-environment.bb b/poky/meta/recipes-core/meta/meta-environment.bb
index 09f757a..da1230b 100644
--- a/poky/meta/recipes-core/meta/meta-environment.bb
+++ b/poky/meta/recipes-core/meta/meta-environment.bb
@@ -56,7 +56,7 @@
 	# Add version information
 	toolchain_create_sdk_version ${SDK_OUTPUT}/${SDKPATH}/version-${REAL_MULTIMACH_TARGET_SYS}
 
-	toolchain_create_post_relocate_script ${SDK_OUTPUT}/${SDKPATH}/post-relocate-setup.sh
+	toolchain_create_post_relocate_script ${SDK_OUTPUT}/${SDKPATH}/post-relocate-setup.sh ${SDKPATH}
 }
 
 do_install() {
diff --git a/poky/meta/recipes-core/meta/meta-ide-support.bb b/poky/meta/recipes-core/meta/meta-ide-support.bb
index 0692ec8..768f6f4 100644
--- a/poky/meta/recipes-core/meta/meta-ide-support.bb
+++ b/poky/meta/recipes-core/meta/meta-ide-support.bb
@@ -2,7 +2,7 @@
 DESCRIPTION = "Meta package for ensuring the build directory contains all appropriate toolchain packages for using an IDE"
 LICENSE = "MIT"
 
-DEPENDS = "virtual/libc gdb-cross-${TARGET_ARCH} qemu-native qemu-helper-native unfs3-native"
+DEPENDS = "virtual/libc gdb-cross-${TARGET_ARCH} qemu-native qemu-helper-native unfs3-native cmake-native"
 PR = "r3"
 RM_WORK_EXCLUDE += "${PN}"
 
diff --git a/poky/meta/recipes-core/meta/uninative-tarball.bb b/poky/meta/recipes-core/meta/uninative-tarball.bb
index 38c3a31..e0cb9ff 100644
--- a/poky/meta/recipes-core/meta/uninative-tarball.bb
+++ b/poky/meta/recipes-core/meta/uninative-tarball.bb
@@ -12,8 +12,11 @@
     nativesdk-glibc-gconv-iso8859-1 \
     nativesdk-glibc-gconv-utf-16 \
     nativesdk-glibc-gconv-cp1252 \
+    nativesdk-glibc-gconv-euc-jp \
+    nativesdk-glibc-gconv-libjis \
     nativesdk-patchelf \
     nativesdk-libxcrypt \
+    nativesdk-libnss-nis \
     "
 
 INHIBIT_DEFAULT_DEPS = "1"
diff --git a/poky/meta/recipes-core/musl/libssp-nonshared.bb b/poky/meta/recipes-core/musl/libssp-nonshared.bb
new file mode 100644
index 0000000..458eafe
--- /dev/null
+++ b/poky/meta/recipes-core/musl/libssp-nonshared.bb
@@ -0,0 +1,39 @@
+# Copyright (C) 2018 Khem Raj <raj.khem@gmail.com>
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+SUMMARY = "Minimal libssp_nonshared.a must needed for ssp to work with gcc on musl"
+LICENSE = "GPL-3.0-with-GCC-exception"
+LIC_FILES_CHKSUM = "file://ssp-local.c;beginline=1;endline=32;md5=c06d391208c0cfcbc541a6728ed65cc4"
+SECTION = "libs"
+
+SRC_URI = "file://ssp-local.c"
+
+PATH_prepend = "${STAGING_BINDIR_TOOLCHAIN}.${STAGINGCC}:"
+
+INHIBIT_DEFAULT_DEPS = "1"
+
+STAGINGCC = "gcc-cross-initial-${TARGET_ARCH}"
+STAGINGCC_class-nativesdk = "gcc-crosssdk-initial-${SDK_SYS}"
+
+DEPENDS = "virtual/${TARGET_PREFIX}binutils \
+           virtual/${TARGET_PREFIX}gcc-initial \
+"
+
+do_configure[noexec] = "1"
+
+S = "${WORKDIR}"
+
+do_compile() {
+	${CC} ${CPPFLAGS} ${CFLAGS} -fPIE -c ssp-local.c -o ssp-local.o
+	${AR} r libssp_nonshared.a ssp-local.o
+}
+do_install() {
+	install -Dm 0644 ${B}/libssp_nonshared.a ${D}${base_libdir}/libssp_nonshared.a
+}
+#
+# We will skip parsing for non-musl systems
+#
+COMPATIBLE_HOST = ".*-musl.*"
+RDEPENDS_${PN}-staticdev = ""
+RDEPENDS_${PN}-dev = ""
+RRECOMMENDS_${PN}-dbg = "${PN}-staticdev (= ${EXTENDPKGV})"
diff --git a/poky/meta/recipes-core/musl/libssp-nonshared/ssp-local.c b/poky/meta/recipes-core/musl/libssp-nonshared/ssp-local.c
new file mode 100644
index 0000000..8f51afa
--- /dev/null
+++ b/poky/meta/recipes-core/musl/libssp-nonshared/ssp-local.c
@@ -0,0 +1,45 @@
+/* Stack protector support.
+   Copyright (C) 2005-2018 Free Software Foundation, Inc.
+
+This file is part of GCC.
+
+GCC is free software; you can redistribute it and/or modify it under
+the terms of the GNU General Public License as published by the Free
+Software Foundation; either version 3, or (at your option) any later
+version.
+
+In addition to the permissions in the GNU General Public License, the
+Free Software Foundation gives you unlimited permission to link the
+compiled version of this file into combinations with other programs,
+and to distribute those combinations without any restriction coming
+from the use of this file.  (The General Public License restrictions
+do apply in other respects; for example, they cover modification of
+the file, and distribution when not linked into a combine
+executable.)
+
+GCC is distributed in the hope that it will be useful, but WITHOUT ANY
+WARRANTY; without even the implied warranty of MERCHANTABILITY or
+FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+for more details.
+
+Under Section 7 of GPL version 3, you are granted additional
+permissions described in the GCC Runtime Library Exception, version
+3.1, as published by the Free Software Foundation.
+
+You should have received a copy of the GNU General Public License and
+a copy of the GCC Runtime Library Exception along with this program;
+see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
+<http://www.gnu.org/licenses/>.  */
+
+extern void __stack_chk_fail (void);
+
+/* Some targets can avoid loading a GP for calls to hidden functions.
+   Using this entry point may avoid the load of a GP entirely for the
+   function, making the overall code smaller.  */
+
+void
+__attribute__((visibility ("hidden")))
+__stack_chk_fail_local (void)
+{
+  __stack_chk_fail ();
+}
diff --git a/poky/meta/recipes-core/musl/musl-utils.bb b/poky/meta/recipes-core/musl/musl-utils.bb
index 74b846d..dd0ce33 100644
--- a/poky/meta/recipes-core/musl/musl-utils.bb
+++ b/poky/meta/recipes-core/musl/musl-utils.bb
@@ -13,6 +13,8 @@
 SRCREV = "fb5630138ccabbbc14a19d372096a04e42573c7d"
 SRC_URI = "git://github.com/boltlinux/musl-utils"
 
+UPSTREAM_CHECK_COMMITS = "1"
+
 inherit autotools
 
 S = "${WORKDIR}/git"
diff --git a/poky/meta/recipes-core/musl/musl.inc b/poky/meta/recipes-core/musl/musl.inc
index ba9b1a0..319709b 100644
--- a/poky/meta/recipes-core/musl/musl.inc
+++ b/poky/meta/recipes-core/musl/musl.inc
@@ -9,7 +9,7 @@
 HOMEPAGE = "http://www.musl-libc.org/"
 LICENSE = "MIT"
 SECTION = "libs"
-LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=2b9032093c4765e49ae85ddeba29afff"
+LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=8a4bb28f771c817fe57d3a7c4240e3aa"
 
 PATH_prepend = "${STAGING_BINDIR_TOOLCHAIN}.${STAGINGCC}:"
 
diff --git a/poky/meta/recipes-core/musl/musl_git.bb b/poky/meta/recipes-core/musl/musl_git.bb
index 9f8c512..0d8f8eb 100644
--- a/poky/meta/recipes-core/musl/musl_git.bb
+++ b/poky/meta/recipes-core/musl/musl_git.bb
@@ -2,10 +2,11 @@
 # Released under the MIT license (see COPYING.MIT for the terms)
 
 require musl.inc
+inherit linuxloader
 
-SRCREV = "55df09bfccbfe21fc9dd7d8f94550c0ff25ace04"
+SRCREV = "c50985d5c8e316c5c464f352e79eeebfed1121a9"
 
-PV = "1.1.19+git${SRCPV}"
+PV = "1.1.20+git${SRCPV}"
 
 # mirror is at git://github.com/kraj/musl.git
 
@@ -22,7 +23,9 @@
            libgcc-initial \
            linux-libc-headers \
            bsd-headers \
+           libssp-nonshared \
           "
+GLIBC_LDSO = "${@get_glibc_loader(d)}"
 
 export CROSS_COMPILE="${TARGET_PREFIX}"
 
@@ -59,13 +62,27 @@
 	install -d ${D}${bindir}
 	rm -f ${D}${bindir}/ldd
 	lnr ${D}${libdir}/libc.so ${D}${bindir}/ldd
+	lnr ${D}${libdir}/libc.so ${D}${GLIBC_LDSO}
 	for l in crypt dl m pthread resolv rt util xnet
 	do
 		ln -sf libc.so ${D}${libdir}/lib$l.so
 	done
+	for i in libc.so.6 libcrypt.so.1 libdl.so.2 libm.so.6 libpthread.so.0 libresolv.so.2 librt.so.1 libutil.so.1; do
+		ln -sf libc.so ${D}${libdir}/$i
+	done
 }
 
-RDEPENDS_${PN}-dev += "linux-libc-headers-dev bsd-headers-dev"
+PACKAGES =+ "${PN}-glibc-compat"
+
+FILES_${PN}-glibc-compat += "\
+                ${libdir}/libc.so.6 ${libdir}/libcrypt.so.1 \
+                ${libdir}/libdl.so.2 ${libdir}/libm.so.6 \
+                ${libdir}/libpthread.so.0 ${libdir}/libresolv.so.2 \
+                ${libdir}/librt.so.1 ${libdir}/libutil.so.1 \
+                ${GLIBC_LDSO} \
+                "
+
+RDEPENDS_${PN}-dev += "linux-libc-headers-dev bsd-headers-dev libssp-nonshared-staticdev"
 RPROVIDES_${PN}-dev += "libc-dev virtual-libc-dev"
 RPROVIDES_${PN} += "ldd libsegfault rtld(GNU_HASH)"
 
diff --git a/poky/meta/recipes-core/ncurses/files/0001-tic-hang.patch b/poky/meta/recipes-core/ncurses/files/0001-tic-hang.patch
index 4a97056..f98a943 100644
--- a/poky/meta/recipes-core/ncurses/files/0001-tic-hang.patch
+++ b/poky/meta/recipes-core/ncurses/files/0001-tic-hang.patch
@@ -1,6 +1,6 @@
-From a95590f676209832fe0b27226e6de3cb50e2b97c Mon Sep 17 00:00:00 2001
+From 168ba7a681be73ac024438e33e14fde1d5aea97d Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Wed, 16 Aug 2017 14:31:51 +0800
+Date: Fri, 30 Mar 2018 10:02:24 +0800
 Subject: [PATCH 1/2] tic hang
 
 Upstream-Status: Inappropriate [configuration]
@@ -10,34 +10,34 @@
 
 Signed-off-by: anonymous
 
-Rebase to 6.0+20170715
+Rebase to 6.1
 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
  misc/terminfo.src | 11 +++++------
  1 file changed, 5 insertions(+), 6 deletions(-)
 
 diff --git a/misc/terminfo.src b/misc/terminfo.src
-index ee3fab3..176d593 100644
+index 84f4810..6b385ec 100644
 --- a/misc/terminfo.src
 +++ b/misc/terminfo.src
-@@ -5177,12 +5177,11 @@ konsole-xf3x|KDE console window with keyboard for XFree86 3.x xterm,
- # The value for kbs reflects local customization rather than the settings used
- # for XFree86 xterm.
+@@ -5562,12 +5562,11 @@ konsole-xf3x|KDE console window with keyboard for XFree86 3.x xterm,
+ # The value for kbs (see konsole-vt100) reflects local customization rather
+ # than the settings used for XFree86 xterm.
  konsole-xf4x|KDE console window with keyboard for XFree86 4.x xterm,
 -	kend=\EOF, khome=\EOH, use=konsole+pcfkeys,
 -	use=konsole-vt100,
--# Konsole does not implement shifted cursor-keys.
+-
 -konsole+pcfkeys|konsole subset of xterm+pcfkeys,
--	kLFT@, kRIT@, kcbt=\E[Z, kind@, kri@, kDN@, kUP@, use=xterm+pcc2,
--	use=xterm+pcf0,
+-	kcbt=\E[Z, use=xterm+pcc2, use=xterm+pcf0,
+-	use=xterm+pce2,
 +	kend=\EOF, kf1=\EOP, kf13=\EO2P, kf14=\EO2Q, kf15=\EO2R,
 +	kf16=\EO2S, kf17=\E[15;2~, kf18=\E[17;2~, kf19=\E[18;2~,
 +	kf2=\EOQ, kf20=\E[19;2~, kf21=\E[20;2~, kf22=\E[21;2~,
 +	kf23=\E[23;2~, kf24=\E[24;2~, kf3=\EOR, kf4=\EOS,
 +	khome=\EOH, use=konsole-vt100,
+ 
+ # Obsolete: vt100.keymap
  # KDE's "vt100" keyboard has no relationship to any terminal that DEC made, but
- # it is still useful for deriving the other entries.
- konsole-vt100|KDE console window with vt100 (sic) keyboard,
 -- 
 1.8.3.1
 
diff --git a/poky/meta/recipes-core/ncurses/files/0002-configure-reproducible.patch b/poky/meta/recipes-core/ncurses/files/0002-configure-reproducible.patch
index c47ce6a..5721956 100644
--- a/poky/meta/recipes-core/ncurses/files/0002-configure-reproducible.patch
+++ b/poky/meta/recipes-core/ncurses/files/0002-configure-reproducible.patch
@@ -1,4 +1,4 @@
-From 939c994f3756c2d6d3cab2e6a04d05fa7c2b1d56 Mon Sep 17 00:00:00 2001
+From 2a53c03ffa90f0050a949fc5920f0df3e668ff42 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Wed, 16 Aug 2017 14:45:27 +0800
 Subject: [PATCH 2/2] configure: reproducible
@@ -10,7 +10,7 @@
 Upstream-Status: Pending
 Signed-off-by: Juro Bystricky <juro.bystricky@intel.com>
 
-Rebase to Rebase to 6.0+20170715
+Rebase to 6.1
 
 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
@@ -18,10 +18,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/configure b/configure
-index 7d7d2c1..f444354 100755
+index adead92..fa4fdb7 100755
 --- a/configure
 +++ b/configure
-@@ -4458,7 +4458,7 @@ if test "${cf_cv_ar_flags+set}" = set; then
+@@ -4503,7 +4503,7 @@ if test "${cf_cv_ar_flags+set}" = set; then
  else
  
  	cf_cv_ar_flags=unknown
diff --git a/poky/meta/recipes-core/ncurses/ncurses.inc b/poky/meta/recipes-core/ncurses/ncurses.inc
index 01e41d5..99fc478 100644
--- a/poky/meta/recipes-core/ncurses/ncurses.inc
+++ b/poky/meta/recipes-core/ncurses/ncurses.inc
@@ -87,6 +87,7 @@
 	        --disable-rpath-hack \
 		${EXCONFIG_ARGS} \
 	        --with-manpage-format=normal \
+	        --disable-stripping \
 	        "$@" || return 1
 	cd ..
 }
diff --git a/poky/meta/recipes-core/ncurses/ncurses_6.0+20171125.bb b/poky/meta/recipes-core/ncurses/ncurses_6.0+20171125.bb
deleted file mode 100644
index 6c4b96f..0000000
--- a/poky/meta/recipes-core/ncurses/ncurses_6.0+20171125.bb
+++ /dev/null
@@ -1,11 +0,0 @@
-require ncurses.inc
-
-SRC_URI += "file://0001-tic-hang.patch \
-            file://0002-configure-reproducible.patch \
-            file://config.cache \
-"
-# commit id corresponds to the revision in package version
-SRCREV = "5d849e836052459901cfe0b85a0b2939ff8d2b2a"
-S = "${WORKDIR}/git"
-EXTRA_OECONF += "--with-abi-version=5"
-UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+(\.\d+)+(\+\d+)*)"
diff --git a/poky/meta/recipes-core/ncurses/ncurses_6.1+20180630.bb b/poky/meta/recipes-core/ncurses/ncurses_6.1+20180630.bb
new file mode 100644
index 0000000..38faf7a
--- /dev/null
+++ b/poky/meta/recipes-core/ncurses/ncurses_6.1+20180630.bb
@@ -0,0 +1,11 @@
+require ncurses.inc
+
+SRC_URI += "file://0001-tic-hang.patch \
+            file://0002-configure-reproducible.patch \
+            file://config.cache \
+"
+# commit id corresponds to the revision in package version
+SRCREV = "d3b29180ae4360d7ab7a41a15e963299fdb72e33"
+S = "${WORKDIR}/git"
+EXTRA_OECONF += "--with-abi-version=5"
+UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+(\.\d+)+(\+\d+)*)"
diff --git a/poky/meta/recipes-core/newlib/libgloss/fix-rs6000-crt0.patch b/poky/meta/recipes-core/newlib/libgloss/fix-rs6000-crt0.patch
new file mode 100644
index 0000000..c220fb8
--- /dev/null
+++ b/poky/meta/recipes-core/newlib/libgloss/fix-rs6000-crt0.patch
@@ -0,0 +1,41 @@
+Upstream-Status: Inappropriate  [OE-Specific]
+
+Make install tries to perform install for all variants, but some of them use the same
+name for crt0 in specific, so performing all of them results in an error during
+do_install, we simply modify the name of the objects so the installation can proceed
+and leave it to the user to select which object files to use.
+
+Signed-off-by: Alejandro Enedino Hernandez Samaniego <alejandr@xilinx.com>
+
+Index: newlib-3.0.0/libgloss/rs6000/Makefile.in
+===================================================================
+--- newlib-3.0.0.orig/libgloss/rs6000/Makefile.in
++++ newlib-3.0.0/libgloss/rs6000/Makefile.in
+@@ -358,7 +358,7 @@ install-sim:
+ 	set -e; for x in ${SIM_CRT0} ${SIM_BSP} ${SIM_SCRIPTS}; do ${INSTALL_DATA} $$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/$$x; done
+ 
+ install-mvme:
+-	set -e; for x in ${MVME_CRT0} ${MVME_BSP} ${MVME_SCRIPTS}; do ${INSTALL_DATA} $$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/$$x; done
++	set -e; for x in ${MVME_CRT0} ${MVME_BSP} ${MVME_SCRIPTS}; do ${INSTALL_DATA} $$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/mvme-$$x; done
+ 
+ install-solaris:
+ 	set -e; for x in ${SOLARIS_CRT0} ${SOLARIS_BSP} ${SOLARIS_SCRIPTS}; do ${INSTALL_DATA} $$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/$$x; done
+@@ -367,15 +367,15 @@ install-linux:
+ 	set -e; for x in ${LINUX_CRT0} ${LINUX_BSP} ${LINUX_SCRIPTS}; do ${INSTALL_DATA} $$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/$$x; done
+ 
+ install-yellowknife:
+-	set -e; for x in ${YELLOWKNIFE_CRT0} ${YELLOWKNIFE_BSP}; do ${INSTALL_DATA} $$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/$$x; done
++	set -e; for x in ${YELLOWKNIFE_CRT0} ${YELLOWKNIFE_BSP}; do ${INSTALL_DATA} $$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/yellowknife-$$x; done
+ 	set -e; for x in ${YELLOWKNIFE_SCRIPTS}; do ${INSTALL_DATA} $(srcdir)/$$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/$$x; done
+ 
+ install-ads:
+-	set -e; for x in ${ADS_CRT0} ${ADS_BSP}; do ${INSTALL_DATA} $$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/$$x; done
++	set -e; for x in ${ADS_CRT0} ${ADS_BSP}; do ${INSTALL_DATA} $$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/ads-$$x; done
+ 	set -e; for x in ${ADS_SCRIPTS}; do ${INSTALL_DATA} $(srcdir)/$$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/$$x; done
+ 
+ install-mbx:
+-	set -e; for x in ${MBX_CRT0} ${MBX_BSP}; do ${INSTALL_DATA} $$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/$$x; done
++	set -e; for x in ${MBX_CRT0} ${MBX_BSP}; do ${INSTALL_DATA} $$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/mbx-$$x; done
+ 	set -e; for x in ${MBX_SCRIPTS} ${MBX_SPECS}; do ${INSTALL_DATA} $(srcdir)/$$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/$$x; done
+ 
+ install-xil:
diff --git a/poky/meta/recipes-core/newlib/libgloss/fix_makefile_include_arm_h.patch b/poky/meta/recipes-core/newlib/libgloss/fix_makefile_include_arm_h.patch
new file mode 100644
index 0000000..7645be7
--- /dev/null
+++ b/poky/meta/recipes-core/newlib/libgloss/fix_makefile_include_arm_h.patch
@@ -0,0 +1,30 @@
+Upstream-Status: Inappropriate  [OE-Specific]
+
+When trying to build libgloss for an arm target, the build system
+complains about missing some include files:
+
+| fatal error: acle-compiat.h: No such file or directory
+|  #include "acle-compat.h"
+|           ^~~~~~~~~~~~~~~
+| compilation terminated.
+
+These include files come from the newlib source, but since we
+are building libgloss separately from newlib, libgloss is unaware
+of where they are, this patch fixes the INCLUDES so the build system
+can find such files.
+
+Signed-off-by: Alejandro Enedino Hernandez Samaniego <alejandr@xilinx.com>
+
+Index: newlib-3.0.0/libgloss/config/default.mh
+===================================================================
+--- newlib-3.0.0.orig/libgloss/config/default.mh
++++ newlib-3.0.0/libgloss/config/default.mh
+@@ -1,7 +1,7 @@
+ NEWLIB_CFLAGS = `if [ -d ${objroot}/newlib ]; then echo -I${objroot}/newlib/targ-include -I${srcroot}/newlib/libc/include; fi`
+ NEWLIB_LDFLAGS = `if [ -d ${objroot}/newlib ]; then echo -B${objroot}/newlib/ -L${objroot}/newlib/; fi`
+ 
+-INCLUDES = -I. -I$(srcdir)/..
++INCLUDES = -I. -I$(srcdir)/.. -I$(srcdir)/../newlib/libc/machine/arm
+ # Note that when building the library, ${MULTILIB} is not the way multilib
+ # options are passed; they're passed in $(CFLAGS).
+ CFLAGS_FOR_TARGET = -O2 -g ${MULTILIB} ${INCLUDES} ${NEWLIB_CFLAGS}
diff --git a/poky/meta/recipes-core/newlib/libgloss_3.0.0.bb b/poky/meta/recipes-core/newlib/libgloss_3.0.0.bb
new file mode 100644
index 0000000..c9ed30d
--- /dev/null
+++ b/poky/meta/recipes-core/newlib/libgloss_3.0.0.bb
@@ -0,0 +1,33 @@
+require newlib.inc
+
+DEPENDS += "newlib"
+
+FILESEXTRAPATHS_prepend := "${THISDIR}/libgloss:"
+
+SRC_URI_append_powerpc = " file://fix-rs6000-crt0.patch"
+SRC_URI_append_arm = " file://fix_makefile_include_arm_h.patch"
+
+do_configure() {
+	${S}/libgloss/configure ${EXTRA_OECONF}
+}
+
+do_install_prepend() {
+	# install doesn't create this itself, avoid install error
+	install -d ${D}${prefix}/${TARGET_SYS}/lib
+}
+
+do_install_append() {
+	# Move libs to default directories so they can be picked up later
+	install -d ${D}${libdir}
+	mv -v ${D}${prefix}/${TARGET_SYS}/lib/* ${D}${libdir}
+
+	# Remove original directory
+	rmdir -p --ignore-fail-on-non-empty ${D}${prefix}/${TARGET_SYS}/lib
+}
+
+# Split packages correctly
+FILES_${PN} += "${libdir}/*.ld ${libdir}/*.specs"
+FILES_${PN}-dev += "${libdir}/cpu-init/*"
+
+INHIBIT_PACKAGE_STRIP = "1"
+INHIBIT_PACKAGE_DEBUG_SPLIT = "1"
diff --git a/poky/meta/recipes-core/newlib/newlib.inc b/poky/meta/recipes-core/newlib/newlib.inc
new file mode 100644
index 0000000..c97c7c2
--- /dev/null
+++ b/poky/meta/recipes-core/newlib/newlib.inc
@@ -0,0 +1,58 @@
+SUMMARY = "Newlib is a C library intended for use on embedded systems"
+HOMEPAGE = "https://sourceware.org/newlib/"
+DESCRIPTION = "C library intended for use on embedded systems. It is a conglomeration of several library parts, all under free software licenses that make them easily usable on embedded products."
+SECTION = "libs"
+
+LICENSE = "GPLv2 & LGPLv3 & GPLv3 & LGPLv2"
+LIC_FILES_CHKSUM = " \
+		file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
+		file://COPYING3.LIB;md5=6a6a8e020838b23406c81b19c1d46df6 \
+		file://COPYING3;md5=d32239bcb673463ab874e80d47fae504 \
+		file://COPYING.LIBGLOSS;md5=73f5c98779aea7dba4a6c94a74ab0ae2 \
+		file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1 \
+		file://COPYING.NEWLIB;md5=956a4b1487f7677cdcceeee8f05a21f0 \
+		file://newlib/libc/posix/COPYRIGHT;md5=103468ff1982be840fdf4ee9f8b51bbf \
+		file://newlib/libc/sys/linux/linuxthreads/LICENSE;md5=73640207fbc79b198c7ffd4ad4d97aa0 \
+		"
+
+SRC_URI = "ftp://sourceware.org/pub/newlib/newlib-${PV}.tar.gz"
+SRC_URI[md5sum] = "81ec873108b8593c586f91ca65963952"
+SRC_URI[sha256sum] = "c8566335ee74e5fcaeb8595b4ebd0400c4b043d6acb3263ecb1314f8f5501332"
+
+INHIBIT_DEFAULT_DEPS = "1"
+DEPENDS = "virtual/${TARGET_PREFIX}gcc-initial"
+
+PATH_prepend = "${STAGING_BINDIR_TOOLCHAIN}.${STAGINGCC}:"
+STAGINGCC = "gcc-cross-initial-${TARGET_ARCH}"
+STAGINGCC_class-nativesdk = "gcc-crosssdk-initial-${SDK_SYS}"
+
+S = "${WORKDIR}/newlib-${PV}"
+B = "${WORKDIR}/build"
+
+## disable stdlib
+TARGET_CC_ARCH_append = " -nostdlib"
+
+EXTRA_OECONF = " \
+                --build=${BUILD_SYS}  \
+                --target=${TARGET_SYS} \
+		--host=${HOST_SYS} \
+                --prefix=${prefix}  \
+                --exec-prefix=${exec_prefix} \
+                --bindir=${bindir} \
+                --libdir=${libdir} \
+                --includedir=${includedir} \
+		--enable-languages=c \
+		--with-newlib \
+		--with-gnu-as \
+		--with-gnu-ld \
+		--disable-multilib \
+		"
+
+do_configure[cleandirs] = "${B}"
+
+do_install() {
+	oe_runmake install DESTDIR='${D}'
+}
+
+COMPATIBLE_HOST_libc-musl_class-target = "null"
+COMPATIBLE_HOST_libc-glibc_class-target = "null"
diff --git a/poky/meta/recipes-core/newlib/newlib_3.0.0.bb b/poky/meta/recipes-core/newlib/newlib_3.0.0.bb
new file mode 100644
index 0000000..09238fe
--- /dev/null
+++ b/poky/meta/recipes-core/newlib/newlib_3.0.0.bb
@@ -0,0 +1,19 @@
+require newlib.inc
+
+PROVIDES += "virtual/libc virtual/${TARGET_PREFIX}libc-for-gcc virtual/libiconv virtual/libintl"
+
+do_configure() {
+	${S}/configure ${EXTRA_OECONF}
+}
+
+do_install_append() {
+	# Move include files and libs to default directories so they can be picked up later
+	mv -v ${D}${prefix}/${TARGET_SYS}/lib ${D}${libdir}
+	mv -v ${D}${prefix}/${TARGET_SYS}/include ${D}${includedir}
+
+	# Remove original directory
+	rmdir ${D}${prefix}/${TARGET_SYS}
+}
+
+# No rpm package is actually created but -dev depends on it, avoid dnf error
+RDEPENDS_${PN}-dev_libc-newlib = ""
diff --git a/poky/meta/recipes-core/ovmf/ovmf_git.bb b/poky/meta/recipes-core/ovmf/ovmf_git.bb
index e57fa09..d2ecb61 100644
--- a/poky/meta/recipes-core/ovmf/ovmf_git.bb
+++ b/poky/meta/recipes-core/ovmf/ovmf_git.bb
@@ -43,7 +43,7 @@
 
 S = "${WORKDIR}/git"
 
-DEPENDS_class-native="util-linux-native iasl-native ossp-uuid-native qemu-native"
+DEPENDS_class-native="util-linux-native iasl-native qemu-native"
 
 DEPENDS_class-target="ovmf-native"
 
diff --git a/poky/meta/recipes-core/packagegroups/nativesdk-packagegroup-sdk-host.bb b/poky/meta/recipes-core/packagegroups/nativesdk-packagegroup-sdk-host.bb
index e2f6169..4bf0ac0 100644
--- a/poky/meta/recipes-core/packagegroups/nativesdk-packagegroup-sdk-host.bb
+++ b/poky/meta/recipes-core/packagegroups/nativesdk-packagegroup-sdk-host.bb
@@ -21,10 +21,11 @@
     nativesdk-automake \
     nativesdk-shadow \
     nativesdk-makedevs \
-    nativesdk-dnf \
     nativesdk-cmake \
     ${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'nativesdk-wayland', '', d)} \
     nativesdk-sdk-provides-dummy \
+    nativesdk-bison \
+    nativesdk-flex \
     "
 
 RDEPENDS_${PN}_darwin = "\
diff --git a/poky/meta/recipes-core/packagegroups/packagegroup-base.bb b/poky/meta/recipes-core/packagegroups/packagegroup-base.bb
index bb192ae..442201c 100644
--- a/poky/meta/recipes-core/packagegroups/packagegroup-base.bb
+++ b/poky/meta/recipes-core/packagegroups/packagegroup-base.bb
@@ -289,7 +289,7 @@
 #
 SUMMARY_packagegroup-base-wifi = "WiFi support"
 RDEPENDS_packagegroup-base-wifi = "\
-    ${VIRTUAL-RUNTIME_wireless-tools} \
+    iw \
     wpa-supplicant"
 
 RRECOMMENDS_packagegroup-base-wifi = "\
diff --git a/poky/meta/recipes-core/packagegroups/packagegroup-core-boot.bb b/poky/meta/recipes-core/packagegroups/packagegroup-core-boot.bb
index 76cd7fc..8dc445d 100644
--- a/poky/meta/recipes-core/packagegroups/packagegroup-core-boot.bb
+++ b/poky/meta/recipes-core/packagegroups/packagegroup-core-boot.bb
@@ -46,4 +46,5 @@
     ${MACHINE_ESSENTIAL_EXTRA_RDEPENDS}"
 
 RRECOMMENDS_${PN} = "\
+    ${VIRTUAL-RUNTIME_base-utils-syslog} \
     ${MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS}"
diff --git a/poky/meta/recipes-core/packagegroups/packagegroup-core-standalone-sdk-target.bb b/poky/meta/recipes-core/packagegroups/packagegroup-core-standalone-sdk-target.bb
index 43fc599..f5b2d69 100644
--- a/poky/meta/recipes-core/packagegroups/packagegroup-core-standalone-sdk-target.bb
+++ b/poky/meta/recipes-core/packagegroups/packagegroup-core-standalone-sdk-target.bb
@@ -13,7 +13,7 @@
     ${LIBC_DEPENDENCIES} \
     "
 
-RRECOMMENDS_${PN} = "\
+RRECOMMENDS_${PN}_mingw32 = "\
     libssp \
     libssp-dev \
     "
diff --git a/poky/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb b/poky/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb
index fa0e363..33d9c09 100644
--- a/poky/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb
+++ b/poky/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb
@@ -18,7 +18,6 @@
 
 RRECOMMENDS_${PN} = "\
     ${PERF} \
-    trace-cmd \
     blktrace \
     ${PROFILE_TOOLS_X} \
     ${PROFILE_TOOLS_SYSTEMD} \
@@ -34,6 +33,7 @@
 SYSTEMTAP = "systemtap"
 SYSTEMTAP_libc-musl = ""
 SYSTEMTAP_nios2 = ""
+SYSTEMTAP_riscv64 = ""
 
 # lttng-ust uses sched_getcpu() which is not there on for some platforms.
 LTTNGUST = "lttng-ust"
@@ -45,6 +45,7 @@
 LTTNGTOOLS_riscv64 = ""
 
 LTTNGMODULES = "lttng-modules"
+LTTNGMODULES_riscv64 = ""
 
 BABELTRACE = "babeltrace"
 
@@ -54,12 +55,15 @@
 VALGRIND_libc-musl = ""
 VALGRIND_mipsarch = ""
 VALGRIND_nios2 = ""
+VALGRIND_arc = ""
 VALGRIND_armv4 = ""
 VALGRIND_armv5 = ""
 VALGRIND_armv6 = ""
 VALGRIND_armeb = ""
 VALGRIND_aarch64 = ""
+VALGRIND_riscv64 = ""
 VALGRIND_linux-gnux32 = ""
+VALGRIND_linux-gnun32 = ""
 
 RDEPENDS_${PN} = "\
     ${PROFILETOOLS} \
diff --git a/poky/meta/recipes-core/packagegroups/packagegroup-core-tools-testapps.bb b/poky/meta/recipes-core/packagegroups/packagegroup-core-tools-testapps.bb
index b8e5070..6432198 100644
--- a/poky/meta/recipes-core/packagegroups/packagegroup-core-tools-testapps.bb
+++ b/poky/meta/recipes-core/packagegroups/packagegroup-core-tools-testapps.bb
@@ -15,6 +15,10 @@
 KEXECTOOLS_e5500-64b ?= ""
 KEXECTOOLS_microblaze ?= ""
 KEXECTOOLS_nios2 ?= ""
+KEXECTOOLS_riscv64 ?= ""
+
+GSTEXAMPLES ?= "gst-examples"
+GSTEXAMPLES_riscv64 = ""
 
 X11GLTOOLS = "\
     mesa-demos \
@@ -25,8 +29,7 @@
     "
 
 X11TOOLS = "\
-    fstests \
-    gst-examples \
+    ${GSTEXAMPLES} \
     x11perf \
     xrestop \
     xwininfo \
diff --git a/poky/meta/recipes-core/packagegroups/packagegroup-go-sdk-target.bb b/poky/meta/recipes-core/packagegroups/packagegroup-go-sdk-target.bb
index 7d2ccbd..5afb490 100644
--- a/poky/meta/recipes-core/packagegroups/packagegroup-go-sdk-target.bb
+++ b/poky/meta/recipes-core/packagegroups/packagegroup-go-sdk-target.bb
@@ -7,3 +7,5 @@
     go-runtime-dev \
     go-runtime-staticdev \
 "
+
+COMPATIBLE_HOST = "^(?!riscv64).*"
diff --git a/poky/meta/recipes-core/packagegroups/packagegroup-self-hosted.bb b/poky/meta/recipes-core/packagegroups/packagegroup-self-hosted.bb
index adb0c56..9a6721c 100644
--- a/poky/meta/recipes-core/packagegroups/packagegroup-self-hosted.bb
+++ b/poky/meta/recipes-core/packagegroups/packagegroup-self-hosted.bb
@@ -76,24 +76,26 @@
     intltool \
     ldd \
     less \
-    libssp \
-    libssp-dev \
-    libssp-staticdev \
     libstdc++ \
     libstdc++-dev \
     libtool \
     make \
-    mktemp \
     perl-module-re \
     perl-module-text-wrap \
     pkgconfig \
     quilt \
     sed \
     "
-# glibc-utils: for rpcgen
+RDEPENDS_packagegroup-self-hosted-sdk_append_mingw32 = "\
+    libssp \
+    libssp-dev \
+    libssp-staticdev \
+    "
+# rpcsvc-proto: for rpcgen
 RDEPENDS_packagegroup-self-hosted-sdk_append_libc-glibc = "\
     glibc-gconv-ibm850 \
     glibc-utils \
+    rpcsvc-proto \
     "
 RDEPENDS_packagegroup-self-hosted-debug = " \
     gdb \
@@ -185,8 +187,6 @@
     libgl-dev \
     libglu \
     libglu-dev \
-    libsdl \
-    libsdl-dev \
     libx11-dev \
     adwaita-icon-theme \
     xdg-utils \
diff --git a/poky/meta/recipes-core/psplash/psplash_git.bb b/poky/meta/recipes-core/psplash/psplash_git.bb
index aab2c03..3ad1ef4 100644
--- a/poky/meta/recipes-core/psplash/psplash_git.bb
+++ b/poky/meta/recipes-core/psplash/psplash_git.bb
@@ -73,6 +73,8 @@
 
 python do_compile () {
     import shutil
+    import subprocess
+    import shlex
 
     # Build a separate executable for each splash image
     workdir = d.getVar('WORKDIR')
@@ -82,8 +84,7 @@
     outputfiles = d.getVar('SPLASH_INSTALL').split()
     for localfile, outputfile in zip(localfiles, outputfiles):
         if localfile.endswith(".png"):
-            outp = oe.utils.getstatusoutput('%s %s POKY' % (convertscript, os.path.join(workdir, localfile)))
-            print(outp[1])
+            subprocess.call(shlex.split('%s %s POKY' % (convertscript, os.path.join(workdir, localfile))))
             fbase = os.path.splitext(localfile)[0]
             shutil.copyfile("%s-img.h" % fbase, destfile)
         else:
diff --git a/poky/meta/recipes-core/systemd/systemd-boot_237.bb b/poky/meta/recipes-core/systemd/systemd-boot_237.bb
deleted file mode 100644
index afd3848..0000000
--- a/poky/meta/recipes-core/systemd/systemd-boot_237.bb
+++ /dev/null
@@ -1,70 +0,0 @@
-require systemd.inc
-FILESEXTRAPATHS =. "${FILE_DIRNAME}/systemd:"
-
-DEPENDS = "intltool-native libcap util-linux gnu-efi gperf-native"
-
-SRC_URI += "file://0003-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch \
-            file://0027-remove-nobody-user-group-checking.patch \
-            file://0001-Also-check-i386-i586-and-i686-for-ia32.patch \
-            file://0001-Fix-to-run-efi_cc-and-efi_ld-correctly-when-cross-co.patch \
-            "
-
-inherit meson pkgconfig gettext
-inherit deploy
-
-EFI_CC ?= "${CC}"
-EXTRA_OEMESON += "-Defi=true \
-                  -Dgnu-efi=true \
-                  -Defi-includedir=${STAGING_INCDIR}/efi \
-                  -Defi-ldsdir=${STAGING_LIBDIR} \
-                  -Defi-libdir=${STAGING_LIBDIR} \
-                  -Dman=false \
-                  -Defi-cc='${EFI_CC}' \
-                  -Defi-ld='${LD}' \
-                  "
-
-# install to the image as boot*.efi if its the EFI_PROVIDER,
-# otherwise install as the full name.
-# This allows multiple bootloaders to coexist in a single image.
-python __anonymous () {
-    import re
-    target = d.getVar('TARGET_ARCH')
-    prefix = "" if d.getVar('EFI_PROVIDER', True) == "systemd-boot" else "systemd-"
-    if target == "x86_64":
-        systemdimage = prefix + "bootx64.efi"
-    else:
-        systemdimage = prefix + "bootia32.efi"
-    d.setVar("SYSTEMD_BOOT_IMAGE", systemdimage)
-    prefix = "systemd-" if prefix == "" else ""
-    d.setVar("SYSTEMD_BOOT_IMAGE_PREFIX", prefix)
-}
-
-FILES_${PN} = "/boot/EFI/BOOT/${SYSTEMD_BOOT_IMAGE}"
-
-RDEPENDS_${PN} += "virtual/systemd-bootconf"
-
-# Imported from the old gummiboot recipe
-TUNE_CCARGS_remove = "-mfpmath=sse"
-COMPATIBLE_HOST = "(x86_64.*|i.86.*)-linux"
-COMPATIBLE_HOST_x86-x32 = "null"
-
-do_compile() {
-	SYSTEMD_BOOT_EFI_ARCH="ia32"
-	if [ "${TARGET_ARCH}" = "x86_64" ]; then
-		SYSTEMD_BOOT_EFI_ARCH="x64"
-	fi
-
-	ninja src/boot/efi/${SYSTEMD_BOOT_IMAGE_PREFIX}${SYSTEMD_BOOT_IMAGE}
-}
-
-do_install() {
-	install -d ${D}/boot
-	install -d ${D}/boot/EFI
-	install -d ${D}/boot/EFI/BOOT
-	install ${B}/src/boot/efi/systemd-boot*.efi ${D}/boot/EFI/BOOT/${SYSTEMD_BOOT_IMAGE}
-}
-
-do_deploy () {
-	install ${B}/src/boot/efi/systemd-boot*.efi ${DEPLOYDIR}
-}
-addtask deploy before do_build after do_compile
diff --git a/poky/meta/recipes-core/systemd/systemd-boot_239.bb b/poky/meta/recipes-core/systemd/systemd-boot_239.bb
new file mode 100644
index 0000000..7fe420c
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd-boot_239.bb
@@ -0,0 +1,69 @@
+require systemd.inc
+FILESEXTRAPATHS =. "${FILE_DIRNAME}/systemd:"
+
+DEPENDS = "intltool-native libcap util-linux gnu-efi gperf-native"
+
+SRC_URI += "file://0002-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch \
+            file://0006-remove-nobody-user-group-checking.patch \
+            file://0001-Fix-to-run-efi_cc-and-efi_ld-correctly-when-cross-co.patch \
+            "
+
+inherit meson pkgconfig gettext
+inherit deploy
+
+EFI_CC ?= "${CC}"
+EXTRA_OEMESON += "-Defi=true \
+                  -Dgnu-efi=true \
+                  -Defi-includedir=${STAGING_INCDIR}/efi \
+                  -Defi-ldsdir=${STAGING_LIBDIR} \
+                  -Defi-libdir=${STAGING_LIBDIR} \
+                  -Dman=false \
+                  -Defi-cc='${EFI_CC}' \
+                  -Defi-ld='${LD}' \
+                  "
+
+# install to the image as boot*.efi if its the EFI_PROVIDER,
+# otherwise install as the full name.
+# This allows multiple bootloaders to coexist in a single image.
+python __anonymous () {
+    import re
+    target = d.getVar('TARGET_ARCH')
+    prefix = "" if d.getVar('EFI_PROVIDER', True) == "systemd-boot" else "systemd-"
+    if target == "x86_64":
+        systemdimage = prefix + "bootx64.efi"
+    else:
+        systemdimage = prefix + "bootia32.efi"
+    d.setVar("SYSTEMD_BOOT_IMAGE", systemdimage)
+    prefix = "systemd-" if prefix == "" else ""
+    d.setVar("SYSTEMD_BOOT_IMAGE_PREFIX", prefix)
+}
+
+FILES_${PN} = "/boot/EFI/BOOT/${SYSTEMD_BOOT_IMAGE}"
+
+RDEPENDS_${PN} += "virtual/systemd-bootconf"
+
+# Imported from the old gummiboot recipe
+TUNE_CCARGS_remove = "-mfpmath=sse"
+COMPATIBLE_HOST = "(x86_64.*|i.86.*)-linux"
+COMPATIBLE_HOST_x86-x32 = "null"
+
+do_compile() {
+	SYSTEMD_BOOT_EFI_ARCH="ia32"
+	if [ "${TARGET_ARCH}" = "x86_64" ]; then
+		SYSTEMD_BOOT_EFI_ARCH="x64"
+	fi
+
+	ninja src/boot/efi/${SYSTEMD_BOOT_IMAGE_PREFIX}${SYSTEMD_BOOT_IMAGE}
+}
+
+do_install() {
+	install -d ${D}/boot
+	install -d ${D}/boot/EFI
+	install -d ${D}/boot/EFI/BOOT
+	install ${B}/src/boot/efi/systemd-boot*.efi ${D}/boot/EFI/BOOT/${SYSTEMD_BOOT_IMAGE}
+}
+
+do_deploy () {
+	install ${B}/src/boot/efi/systemd-boot*.efi ${DEPLOYDIR}
+}
+addtask deploy before do_build after do_compile
diff --git a/poky/meta/recipes-core/systemd/systemd-conf.bb b/poky/meta/recipes-core/systemd/systemd-conf.bb
new file mode 100644
index 0000000..9bb27fd
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd-conf.bb
@@ -0,0 +1,53 @@
+require systemd.inc
+
+SUMMARY = "Systemd system configuration"
+DESCRIPTION = "Systemd may require slightly different configuration for \
+different machines.  For example, qemu machines require a longer \
+DefaultTimeoutStartSec setting."
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+CONFFILES_${PN} = "${sysconfdir}/machine-id \
+${sysconfdir}/systemd/coredump.conf \
+${sysconfdir}/systemd/journald.conf \
+${sysconfdir}/systemd/logind.conf \
+${sysconfdir}/systemd/system.conf \
+${sysconfdir}/systemd/user.conf"
+
+FILES_${PN} = "${sysconfdir}/machine-id ${sysconfdir}/systemd"
+
+do_configure[noexec] = '1'
+do_compile[noexec] = '1'
+
+do_install() {
+	rm -rf ${D}/${sysconfdir}/systemd
+	install -d ${D}/${sysconfdir}/systemd
+
+	# Create machine-id
+	# 20:12 < mezcalero> koen: you have three options: a) run systemd-machine-id-setup at install time, b) have / read-only and an empty file there (for stateless) and c) boot with / writable
+	touch ${D}${sysconfdir}/machine-id
+
+	install -m 0644 ${S}/src/coredump/coredump.conf ${D}${sysconfdir}/systemd/coredump.conf
+
+	install -m 0644 ${S}/src/journal/journald.conf ${D}${sysconfdir}/systemd/journald.conf
+	# Enable journal to forward message to syslog daemon
+	sed -i -e 's/.*ForwardToSyslog.*/ForwardToSyslog=yes/' ${D}${sysconfdir}/systemd/journald.conf
+	# Set the maximium size of runtime journal to 64M as default
+	sed -i -e 's/.*RuntimeMaxUse.*/RuntimeMaxUse=64M/' ${D}${sysconfdir}/systemd/journald.conf
+
+	install -m 0644 ${S}/src/login/logind.conf.in ${D}${sysconfdir}/systemd/logind.conf
+	# Set KILL_USER_PROCESSES to yes
+	sed -i -e 's/@KILL_USER_PROCESSES@/yes/' ${D}${sysconfdir}/systemd/logind.conf
+
+	install -m 0644 ${S}/src/core/system.conf.in ${D}${sysconfdir}/systemd/system.conf
+	# Set MEMORY_ACCOUNTING_DEFAULT to yes
+	sed -i -e 's/@MEMORY_ACCOUNTING_DEFAULT@/yes/' ${D}${sysconfdir}/systemd/system.conf
+
+	install -m 0644 ${S}/src/core/user.conf ${D}${sysconfdir}/systemd/user.conf
+}
+
+# Based on change from YP bug 8141, OE commit 5196d7bacaef1076c361adaa2867be31759c1b52
+do_install_append_qemuall() {
+	# Change DefaultTimeoutStartSec from 90s to 240s
+	echo "DefaultTimeoutStartSec = 240s" >> ${D}${sysconfdir}/systemd/system.conf
+}
diff --git a/poky/meta/recipes-core/systemd/systemd-serialgetty.bb b/poky/meta/recipes-core/systemd/systemd-serialgetty.bb
index d67a3c9..65a931f 100644
--- a/poky/meta/recipes-core/systemd/systemd-serialgetty.bb
+++ b/poky/meta/recipes-core/systemd/systemd-serialgetty.bb
@@ -5,7 +5,7 @@
 
 PR = "r5"
 
-SERIAL_CONSOLE ?= "115200 ttyS0"
+SERIAL_CONSOLES ?= "115200;ttyS0"
 
 SRC_URI = "file://serial-getty@.service"
 
diff --git a/poky/meta/recipes-core/systemd/systemd.inc b/poky/meta/recipes-core/systemd/systemd.inc
index 5fa48e7..736e0a0 100644
--- a/poky/meta/recipes-core/systemd/systemd.inc
+++ b/poky/meta/recipes-core/systemd/systemd.inc
@@ -14,7 +14,7 @@
 LIC_FILES_CHKSUM = "file://LICENSE.GPL2;md5=751419260aa954499f7abaabaa882bbe \
                     file://LICENSE.LGPL2.1;md5=4fbd65380cdd255951079008b364516c"
 
-SRCREV = "46659f7deb962f55c728e70597e37c2a3ab6326d"
+SRCREV = "de7436b02badc82200dc127ff190b8155769b8e7"
 
 SRC_URI = "git://github.com/systemd/systemd.git;protocol=git"
 
diff --git a/poky/meta/recipes-core/systemd/systemd/0001-Also-check-i386-i586-and-i686-for-ia32.patch b/poky/meta/recipes-core/systemd/systemd/0001-Also-check-i386-i586-and-i686-for-ia32.patch
deleted file mode 100644
index 877bb1c..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0001-Also-check-i386-i586-and-i686-for-ia32.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From 3e8c19bb1bbc4493c591f75c00c1fefe3b1c8a69 Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Tue, 27 Feb 2018 20:42:41 -0800
-Subject: [PATCH] Also check i386, i586 and i686 for ia32
-
-Upstream-Status: Pending
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- meson.build | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/meson.build b/meson.build
-index 28cb8b60e..489531a43 100644
---- a/meson.build
-+++ b/meson.build
-@@ -1217,7 +1217,7 @@ conf.set10('SYSTEMD_SLOW_TESTS_DEFAULT', slow_tests)
- if get_option('efi')
-         efi_arch = host_machine.cpu_family()
- 
--        if efi_arch == 'x86'
-+        if efi_arch == 'x86' or efi_arch == 'i386' or efi_arch == 'i586' or efi_arch == 'i686'
-                 EFI_MACHINE_TYPE_NAME = 'ia32'
-                 gnu_efi_arch = 'ia32'
-         elif efi_arch == 'x86_64'
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0001-Hide-__start_BUS_ERROR_MAP-and-__stop_BUS_ERROR_MAP.patch b/poky/meta/recipes-core/systemd/systemd/0001-Hide-__start_BUS_ERROR_MAP-and-__stop_BUS_ERROR_MAP.patch
deleted file mode 100644
index 2cffc42..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0001-Hide-__start_BUS_ERROR_MAP-and-__stop_BUS_ERROR_MAP.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From 687a5af8dc5d38f918a6ce08fed5297234bf8346 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 2 Mar 2018 18:00:17 -0800
-Subject: [PATCH] Hide __start_BUS_ERROR_MAP and __stop_BUS_ERROR_MAP
-
-for currently unknown reasons they get exported to the shared libries
-even without being listed in the sym file
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-
-Upstream-Status: Pending [ Conditional on master needing this, 234 does need it ]
-
- src/libsystemd/sd-bus/bus-error.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/libsystemd/sd-bus/bus-error.c b/src/libsystemd/sd-bus/bus-error.c
-index 378f7a377..49d797abd 100644
---- a/src/libsystemd/sd-bus/bus-error.c
-+++ b/src/libsystemd/sd-bus/bus-error.c
-@@ -71,8 +71,8 @@ BUS_ERROR_MAP_ELF_REGISTER const sd_bus_error_map bus_standard_errors[] = {
- };
- 
- /* GCC maps this magically to the beginning and end of the BUS_ERROR_MAP section */
--extern const sd_bus_error_map __start_BUS_ERROR_MAP[];
--extern const sd_bus_error_map __stop_BUS_ERROR_MAP[];
-+extern const sd_bus_error_map __start_BUS_ERROR_MAP[] _hidden_;
-+extern const sd_bus_error_map __stop_BUS_ERROR_MAP[] _hidden_;
- 
- /* Additional maps registered with sd_bus_error_add_map() are in this
-  * NULL terminated array */
--- 
-2.16.2
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0001-Remove-fstack-protector-flags-to-workaround-musl-bui.patch b/poky/meta/recipes-core/systemd/systemd/0001-Remove-fstack-protector-flags-to-workaround-musl-bui.patch
index e913e3f..d745800 100644
--- a/poky/meta/recipes-core/systemd/systemd/0001-Remove-fstack-protector-flags-to-workaround-musl-bui.patch
+++ b/poky/meta/recipes-core/systemd/systemd/0001-Remove-fstack-protector-flags-to-workaround-musl-bui.patch
@@ -1,6 +1,6 @@
-From e361f6b4aefae57efff7e457df8db4d1067bec23 Mon Sep 17 00:00:00 2001
+From 9e3816bcaa36e1a11647ca0cf4f8044449c77fe0 Mon Sep 17 00:00:00 2001
 From: Chen Qi <Qi.Chen@windriver.com>
-Date: Wed, 28 Feb 2018 21:50:23 -0800
+Date: Mon, 2 Jul 2018 15:28:22 +0800
 Subject: [PATCH] Remove fstack-protector flags to workaround musl build
 
 Remove fstack-protector and fstack-protector-strong flags to fix
@@ -8,7 +8,7 @@
 
   undefined reference to `__stack_chk_fail_local'
 
-Upstream-Status: Inappropriate [OE Specific]
+Upstream-Status: Inappropriate [musl Specific]
 
 Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
 ---
@@ -16,18 +16,18 @@
  1 file changed, 2 deletions(-)
 
 diff --git a/meson.build b/meson.build
-index 7610ab12b..591b9cbab 100644
+index f432ea072..a734a295c 100644
 --- a/meson.build
 +++ b/meson.build
-@@ -329,8 +329,6 @@ foreach arg : ['-Wextra',
-                '-fdiagnostics-show-option',
-                '-fno-strict-aliasing',
-                '-fvisibility=hidden',
--               '-fstack-protector',
--               '-fstack-protector-strong',
-                '--param=ssp-buffer-size=4',
-               ]
-         if cc.has_argument(arg)
+@@ -333,8 +333,6 @@ possible_cc_flags = [
+         '-fdiagnostics-show-option',
+         '-fno-strict-aliasing',
+         '-fvisibility=hidden',
+-        '-fstack-protector',
+-        '-fstack-protector-strong',
+         '--param=ssp-buffer-size=4',
+ ]
+ 
 -- 
-2.13.0
+2.11.0
 
diff --git a/poky/meta/recipes-core/systemd/systemd/0001-Use-getenv-when-secure-versions-are-not-available.patch b/poky/meta/recipes-core/systemd/systemd/0001-Use-getenv-when-secure-versions-are-not-available.patch
index f4c15e1..03f6ead 100644
--- a/poky/meta/recipes-core/systemd/systemd/0001-Use-getenv-when-secure-versions-are-not-available.patch
+++ b/poky/meta/recipes-core/systemd/systemd/0001-Use-getenv-when-secure-versions-are-not-available.patch
@@ -1,7 +1,7 @@
-From b1192a6e171413291d9d64fafc04773c6bbc9cab Mon Sep 17 00:00:00 2001
+From 6dd136512896979feb6883a16226d640a7e5ca74 Mon Sep 17 00:00:00 2001
 From: Chen Qi <Qi.Chen@windriver.com>
 Date: Fri, 23 Feb 2018 10:04:48 +0800
-Subject: [PATCH 01/31] Use getenv when secure versions are not available
+Subject: [PATCH 01/19] Use getenv when secure versions are not available
 
 musl doesnt implement secure version, so we default
 to it if configure does not detect a secure implementation
@@ -16,10 +16,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/src/basic/missing.h b/src/basic/missing.h
-index 1280e6c41..39c1fb700 100644
+index 71a07d057..0e33abb9f 100644
 --- a/src/basic/missing.h
 +++ b/src/basic/missing.h
-@@ -605,7 +605,7 @@ struct btrfs_ioctl_quota_ctl_args {
+@@ -592,7 +592,7 @@ struct btrfs_ioctl_quota_ctl_args {
  #  if HAVE___SECURE_GETENV
  #    define secure_getenv __secure_getenv
  #  else
@@ -29,5 +29,5 @@
  #endif
  
 -- 
-2.13.0
+2.11.0
 
diff --git a/poky/meta/recipes-core/systemd/systemd/0001-binfmt-Don-t-install-dependency-links-at-install-tim.patch b/poky/meta/recipes-core/systemd/systemd/0001-binfmt-Don-t-install-dependency-links-at-install-tim.patch
new file mode 100644
index 0000000..e24e7f8
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0001-binfmt-Don-t-install-dependency-links-at-install-tim.patch
@@ -0,0 +1,81 @@
+From 87dd61be2e28e78ce4f9f173794812e6c2d904d1 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Wed, 27 Jun 2018 16:01:22 +0800
+Subject: [PATCH 1/9] binfmt: Don't install dependency links at install time 
+ for the binfmt services
+
+use [Install] blocks so that they get created when the service is enabled
+like a traditional service.
+
+The [Install] blocks were rejected upstream as they don't have a way to
+"enable" it on install without static symlinks which can't be disabled,
+only masked. We however can do that in a postinst.
+
+Upstream-Status: Denied
+
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ units/meson.build                       | 6 ++----
+ units/proc-sys-fs-binfmt_misc.automount | 3 +++
+ units/systemd-binfmt.service.in         | 4 ++++
+ 3 files changed, 9 insertions(+), 4 deletions(-)
+
+diff --git a/units/meson.build b/units/meson.build
+index e4ac6ced6..698734e44 100644
+--- a/units/meson.build
++++ b/units/meson.build
+@@ -46,8 +46,7 @@ units = [
+         ['poweroff.target',                     '',
+          'runlevel0.target'],
+         ['printer.target',                      ''],
+-        ['proc-sys-fs-binfmt_misc.automount',   'ENABLE_BINFMT',
+-         'sysinit.target.wants/'],
++        ['proc-sys-fs-binfmt_misc.automount',   'ENABLE_BINFMT'],
+         ['proc-sys-fs-binfmt_misc.mount',       'ENABLE_BINFMT'],
+         ['reboot.target',                       '',
+          'runlevel6.target ctrl-alt-del.target'],
+@@ -130,8 +129,7 @@ in_units = [
+         ['systemd-ask-password-console.service', ''],
+         ['systemd-ask-password-wall.service',    ''],
+         ['systemd-backlight@.service',           'ENABLE_BACKLIGHT'],
+-        ['systemd-binfmt.service',               'ENABLE_BINFMT',
+-         'sysinit.target.wants/'],
++        ['systemd-binfmt.service',               'ENABLE_BINFMT'],
+         ['systemd-coredump@.service',            'ENABLE_COREDUMP'],
+         ['systemd-exit.service',                 ''],
+         ['systemd-firstboot.service',            'ENABLE_FIRSTBOOT',
+diff --git a/units/proc-sys-fs-binfmt_misc.automount b/units/proc-sys-fs-binfmt_misc.automount
+index 30a6bc991..4231f3b70 100644
+--- a/units/proc-sys-fs-binfmt_misc.automount
++++ b/units/proc-sys-fs-binfmt_misc.automount
+@@ -18,3 +18,6 @@ ConditionPathIsReadWrite=/proc/sys/
+ 
+ [Automount]
+ Where=/proc/sys/fs/binfmt_misc
++
++[Install]
++WantedBy=sysinit.target
+diff --git a/units/systemd-binfmt.service.in b/units/systemd-binfmt.service.in
+index e940c7c9a..6be7f5cc9 100644
+--- a/units/systemd-binfmt.service.in
++++ b/units/systemd-binfmt.service.in
+@@ -14,6 +14,7 @@ Documentation=https://www.kernel.org/doc/html/latest/admin-guide/binfmt-misc.htm
+ Documentation=https://www.freedesktop.org/wiki/Software/systemd/APIFileSystems
+ DefaultDependencies=no
+ Conflicts=shutdown.target
++Wants=proc-sys-fs-binfmt_misc.automount
+ After=proc-sys-fs-binfmt_misc.automount
+ Before=sysinit.target shutdown.target
+ ConditionPathIsReadWrite=/proc/sys/
+@@ -28,3 +29,6 @@ Type=oneshot
+ RemainAfterExit=yes
+ ExecStart=@rootlibexecdir@/systemd-binfmt
+ TimeoutSec=90s
++
++[Install]
++WantedBy=sysinit.target
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0001-chown-recursive-let-s-rework-the-recursive-logic-to-.patch b/poky/meta/recipes-core/systemd/systemd/0001-chown-recursive-let-s-rework-the-recursive-logic-to-.patch
new file mode 100644
index 0000000..9d350eb
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0001-chown-recursive-let-s-rework-the-recursive-logic-to-.patch
@@ -0,0 +1,219 @@
+From 2da8ba3f507345d0401ea9d7191fa16ffa560ebc Mon Sep 17 00:00:00 2001
+From: Lennart Poettering <lennart@poettering.net>
+Date: Fri, 19 Oct 2018 11:26:59 +0200
+Subject: [PATCH] chown-recursive: let's rework the recursive logic to use
+ O_PATH
+
+That way we can pin a specific inode and analyze it and manipulate it
+without it being swapped out beneath our hands.
+
+Fixes a vulnerability originally found by Jann Horn from Google.
+
+CVE-2018-15687
+LP: #1796692
+https://bugzilla.redhat.com/show_bug.cgi?id=1639076
+
+(cherry picked from commit 5de6cce58b3e8b79239b6e83653459d91af6e57c)
+
+CVE: CVE-2018-15687
+Upstream-Status: Backport
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/core/chown-recursive.c | 146 ++++++++++++++++++++++-----------------------
+ 1 file changed, 70 insertions(+), 76 deletions(-)
+
+diff --git a/src/core/chown-recursive.c b/src/core/chown-recursive.c
+index c479450..27c6448 100644
+--- a/src/core/chown-recursive.c
++++ b/src/core/chown-recursive.c
+@@ -1,17 +1,19 @@
+ /* SPDX-License-Identifier: LGPL-2.1+ */
+ 
+-#include <sys/types.h>
+-#include <sys/stat.h>
+ #include <fcntl.h>
++#include <sys/stat.h>
++#include <sys/types.h>
+ 
+-#include "user-util.h"
+-#include "macro.h"
+-#include "fd-util.h"
+-#include "dirent-util.h"
+ #include "chown-recursive.h"
++#include "dirent-util.h"
++#include "fd-util.h"
++#include "macro.h"
++#include "stdio-util.h"
++#include "strv.h"
++#include "user-util.h"
+ 
+-static int chown_one(int fd, const char *name, const struct stat *st, uid_t uid, gid_t gid) {
+-        int r;
++static int chown_one(int fd, const struct stat *st, uid_t uid, gid_t gid) {
++        char procfs_path[STRLEN("/proc/self/fd/") + DECIMAL_STR_MAX(int) + 1];
+ 
+         assert(fd >= 0);
+         assert(st);
+@@ -20,90 +22,82 @@ static int chown_one(int fd, const char *name, const struct stat *st, uid_t uid,
+             (!gid_is_valid(gid) || st->st_gid == gid))
+                 return 0;
+ 
+-        if (name)
+-                r = fchownat(fd, name, uid, gid, AT_SYMLINK_NOFOLLOW);
+-        else
+-                r = fchown(fd, uid, gid);
+-        if (r < 0)
+-                return -errno;
++        /* We change ownership through the /proc/self/fd/%i path, so that we have a stable reference that works with
++         * O_PATH. (Note: fchown() and fchmod() do not work with O_PATH, the kernel refuses that. */
++        xsprintf(procfs_path, "/proc/self/fd/%i", fd);
+ 
+-        /* The linux kernel alters the mode in some cases of chown(). Let's undo this. */
+-        if (name) {
+-                if (!S_ISLNK(st->st_mode))
+-                        r = fchmodat(fd, name, st->st_mode, 0);
+-                else /* There's currently no AT_SYMLINK_NOFOLLOW for fchmodat() */
+-                        r = 0;
+-        } else
+-                r = fchmod(fd, st->st_mode);
+-        if (r < 0)
++        if (chown(procfs_path, uid, gid) < 0)
+                 return -errno;
+ 
++        /* The linux kernel alters the mode in some cases of chown(). Let's undo this. We do this only for non-symlinks
++         * however. That's because for symlinks the access mode is ignored anyway and because on some kernels/file
++         * systems trying to change the access mode will succeed but has no effect while on others it actively
++         * fails. */
++        if (!S_ISLNK(st->st_mode))
++                if (chmod(procfs_path, st->st_mode & 07777) < 0)
++                        return -errno;
++
+         return 1;
+ }
+ 
+ static int chown_recursive_internal(int fd, const struct stat *st, uid_t uid, gid_t gid) {
++        _cleanup_closedir_ DIR *d = NULL;
+         bool changed = false;
++        struct dirent *de;
+         int r;
+ 
+         assert(fd >= 0);
+         assert(st);
+ 
+-        if (S_ISDIR(st->st_mode)) {
+-                _cleanup_closedir_ DIR *d = NULL;
+-                struct dirent *de;
+-
+-                d = fdopendir(fd);
+-                if (!d) {
+-                        r = -errno;
+-                        goto finish;
+-                }
+-                fd = -1;
+-
+-                FOREACH_DIRENT_ALL(de, d, r = -errno; goto finish) {
+-                        struct stat fst;
+-
+-                        if (dot_or_dot_dot(de->d_name))
+-                                continue;
+-
+-                        if (fstatat(dirfd(d), de->d_name, &fst, AT_SYMLINK_NOFOLLOW) < 0) {
+-                                r = -errno;
+-                                goto finish;
+-                        }
+-
+-                        if (S_ISDIR(fst.st_mode)) {
+-                                int subdir_fd;
+-
+-                                subdir_fd = openat(dirfd(d), de->d_name, O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC|O_NOFOLLOW|O_NOATIME);
+-                                if (subdir_fd < 0) {
+-                                        r = -errno;
+-                                        goto finish;
+-                                }
+-
+-                                r = chown_recursive_internal(subdir_fd, &fst, uid, gid);
+-                                if (r < 0)
+-                                        goto finish;
+-                                if (r > 0)
+-                                        changed = true;
+-                        } else {
+-                                r = chown_one(dirfd(d), de->d_name, &fst, uid, gid);
+-                                if (r < 0)
+-                                        goto finish;
+-                                if (r > 0)
+-                                        changed = true;
+-                        }
++        d = fdopendir(fd);
++        if (!d) {
++                safe_close(fd);
++                return -errno;
++        }
++
++        FOREACH_DIRENT_ALL(de, d, return -errno) {
++                _cleanup_close_ int path_fd = -1;
++                struct stat fst;
++
++                if (dot_or_dot_dot(de->d_name))
++                        continue;
++
++                /* Let's pin the child inode we want to fix now with an O_PATH fd, so that it cannot be swapped out
++                 * while we manipulate it. */
++                path_fd = openat(dirfd(d), de->d_name, O_PATH|O_CLOEXEC|O_NOFOLLOW);
++                if (path_fd < 0)
++                        return -errno;
++
++                if (fstat(path_fd, &fst) < 0)
++                        return -errno;
++
++                if (S_ISDIR(fst.st_mode)) {
++                        int subdir_fd;
++
++                        /* Convert it to a "real" (i.e. non-O_PATH) fd now */
++                        subdir_fd = fd_reopen(path_fd, O_RDONLY|O_CLOEXEC|O_NOATIME);
++                        if (subdir_fd < 0)
++                                return subdir_fd;
++
++                        r = chown_recursive_internal(subdir_fd, &fst, uid, gid); /* takes possession of subdir_fd even on failure */
++                        if (r < 0)
++                                return r;
++                        if (r > 0)
++                                changed = true;
++                } else {
++                        r = chown_one(path_fd, &fst, uid, gid);
++                        if (r < 0)
++                                return r;
++                        if (r > 0)
++                                changed = true;
+                 }
++        }
+ 
+-                r = chown_one(dirfd(d), NULL, st, uid, gid);
+-        } else
+-                r = chown_one(fd, NULL, st, uid, gid);
++        r = chown_one(dirfd(d), st, uid, gid);
+         if (r < 0)
+-                goto finish;
++                return r;
+ 
+-        r = r > 0 || changed;
+-
+-finish:
+-        safe_close(fd);
+-        return r;
++        return r > 0 || changed;
+ }
+ 
+ int path_chown_recursive(const char *path, uid_t uid, gid_t gid) {
+@@ -111,7 +105,7 @@ int path_chown_recursive(const char *path, uid_t uid, gid_t gid) {
+         struct stat st;
+         int r;
+ 
+-        fd = open(path, O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC|O_NOFOLLOW|O_NOATIME);
++        fd = open(path, O_RDONLY|O_DIRECTORY|O_CLOEXEC|O_NOFOLLOW|O_NOATIME);
+         if (fd < 0)
+                 return -errno;
+ 
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0001-core-device.c-Change-the-default-device-timeout-to-2.patch b/poky/meta/recipes-core/systemd/systemd/0001-core-device.c-Change-the-default-device-timeout-to-2.patch
deleted file mode 100644
index 98c8362..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0001-core-device.c-Change-the-default-device-timeout-to-2.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 7844e070745611a52e355b73e7890f360dd540d0 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 14 Dec 2015 04:09:19 +0000
-Subject: [PATCH] core/device.c: Change the default device timeout to 240 sec.
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Upstream-Status: Inappropriate [Specific case QEMU/AB]
-
-Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
----
- src/core/device.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/core/device.c b/src/core/device.c
-index a43664d3b..4b16a8aec 100644
---- a/src/core/device.c
-+++ b/src/core/device.c
-@@ -113,7 +113,7 @@ static void device_init(Unit *u) {
-          * indefinitely for plugged in devices, something which cannot
-          * happen for the other units since their operations time out
-          * anyway. */
--        u->job_running_timeout = u->manager->default_timeout_start_usec;
-+        u->job_running_timeout = (240 * USEC_PER_SEC);
- 
-         u->ignore_on_isolate = true;
- }
diff --git a/poky/meta/recipes-core/systemd/systemd/0001-core-when-deserializing-state-always-use-read_line-L.patch b/poky/meta/recipes-core/systemd/systemd/0001-core-when-deserializing-state-always-use-read_line-L.patch
new file mode 100644
index 0000000..215d680
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0001-core-when-deserializing-state-always-use-read_line-L.patch
@@ -0,0 +1,250 @@
+From 1a05ff4948d778280ec155a9abe69d3360bfddd9 Mon Sep 17 00:00:00 2001
+From: Lennart Poettering <lennart@poettering.net>
+Date: Wed, 17 Oct 2018 18:36:24 +0200
+Subject: [PATCH] =?UTF-8?q?core:=20when=20deserializing=20state=20always?=
+ =?UTF-8?q?=20use=20read=5Fline(=E2=80=A6,=20LONG=5FLINE=5FMAX,=20?=
+ =?UTF-8?q?=E2=80=A6)?=
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+This should be much better than fgets(), as we can read substantially
+longer lines and overly long lines result in proper errors.
+
+Fixes a vulnerability discovered by Jann Horn at Google.
+
+CVE-2018-15686
+LP: #1796402
+https://bugzilla.redhat.com/show_bug.cgi?id=1639071
+
+(cherry picked from commit 8948b3415d762245ebf5e19d80b97d4d8cc208c1)
+
+CVE: CVE-2018-15686
+Upstream-Status: Backport
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/core/job.c     | 19 +++++++++++--------
+ src/core/manager.c | 44 ++++++++++++++++++++------------------------
+ src/core/unit.c    | 34 ++++++++++++++++++----------------
+ src/core/unit.h    |  2 +-
+ 4 files changed, 50 insertions(+), 49 deletions(-)
+
+diff --git a/src/core/job.c b/src/core/job.c
+index 734756b..8552ffb 100644
+--- a/src/core/job.c
++++ b/src/core/job.c
+@@ -10,6 +10,7 @@
+ #include "dbus-job.h"
+ #include "dbus.h"
+ #include "escape.h"
++#include "fileio.h"
+ #include "job.h"
+ #include "log.h"
+ #include "macro.h"
+@@ -1091,24 +1092,26 @@ int job_serialize(Job *j, FILE *f) {
+ }
+ 
+ int job_deserialize(Job *j, FILE *f) {
++        int r;
++
+         assert(j);
+         assert(f);
+ 
+         for (;;) {
+-                char line[LINE_MAX], *l, *v;
++                _cleanup_free_ char *line = NULL;
++                char *l, *v;
+                 size_t k;
+ 
+-                if (!fgets(line, sizeof(line), f)) {
+-                        if (feof(f))
+-                                return 0;
+-                        return -errno;
+-                }
++                r = read_line(f, LONG_LINE_MAX, &line);
++                if (r < 0)
++                        return log_error_errno(r, "Failed to read serialization line: %m");
++                if (r == 0)
++                        return 0;
+ 
+-                char_array_0(line);
+                 l = strstrip(line);
+ 
+                 /* End marker */
+-                if (l[0] == 0)
++                if (isempty(l))
+                         return 0;
+ 
+                 k = strcspn(l, "=");
+diff --git a/src/core/manager.c b/src/core/manager.c
+index 3a7f0c4..a5780c9 100644
+--- a/src/core/manager.c
++++ b/src/core/manager.c
+@@ -3171,22 +3171,19 @@ int manager_deserialize(Manager *m, FILE *f, FDSet *fds) {
+         m->n_reloading++;
+ 
+         for (;;) {
+-                char line[LINE_MAX];
++                _cleanup_free_ char *line = NULL;
+                 const char *val, *l;
+ 
+-                if (!fgets(line, sizeof(line), f)) {
+-                        if (feof(f))
+-                                r = 0;
+-                        else
+-                                r = -errno;
+-
++                r = read_line(f, LONG_LINE_MAX, &line);
++                if (r < 0) {
++                        log_error_errno(r, "Failed to read serialization line: %m");
+                         goto finish;
+                 }
++                if (r == 0)
++                        break;
+ 
+-                char_array_0(line);
+                 l = strstrip(line);
+-
+-                if (l[0] == 0)
++                if (isempty(l)) /* end marker */
+                         break;
+ 
+                 if ((val = startswith(l, "current-job-id="))) {
+@@ -3353,29 +3350,31 @@ int manager_deserialize(Manager *m, FILE *f, FDSet *fds) {
+         }
+ 
+         for (;;) {
+-                Unit *u;
+-                char name[UNIT_NAME_MAX+2];
++                _cleanup_free_ char *line = NULL;
+                 const char* unit_name;
++                Unit *u;
+ 
+                 /* Start marker */
+-                if (!fgets(name, sizeof(name), f)) {
+-                        if (feof(f))
+-                                r = 0;
+-                        else
+-                                r = -errno;
+-
++                r = read_line(f, LONG_LINE_MAX, &line);
++                if (r < 0) {
++                        log_error_errno(r, "Failed to read serialization line: %m");
+                         goto finish;
+                 }
++                if (r == 0)
++                        break;
+ 
+-                char_array_0(name);
+-                unit_name = strstrip(name);
++                unit_name = strstrip(line);
+ 
+                 r = manager_load_unit(m, unit_name, NULL, NULL, &u);
+                 if (r < 0) {
+                         log_notice_errno(r, "Failed to load unit \"%s\", skipping deserialization: %m", unit_name);
+                         if (r == -ENOMEM)
+                                 goto finish;
+-                        unit_deserialize_skip(f);
++
++                        r = unit_deserialize_skip(f);
++                        if (r < 0)
++                                goto finish;
++
+                         continue;
+                 }
+ 
+@@ -3388,9 +3387,6 @@ int manager_deserialize(Manager *m, FILE *f, FDSet *fds) {
+         }
+ 
+ finish:
+-        if (ferror(f))
+-                r = -EIO;
+-
+         assert(m->n_reloading > 0);
+         m->n_reloading--;
+ 
+diff --git a/src/core/unit.c b/src/core/unit.c
+index 7da963a..e98c9c4 100644
+--- a/src/core/unit.c
++++ b/src/core/unit.c
+@@ -3380,21 +3380,19 @@ int unit_deserialize(Unit *u, FILE *f, FDSet *fds) {
+         assert(fds);
+ 
+         for (;;) {
+-                char line[LINE_MAX], *l, *v;
++                _cleanup_free_ char *line = NULL;
+                 CGroupIPAccountingMetric m;
++                char *l, *v;
+                 size_t k;
+ 
+-                if (!fgets(line, sizeof(line), f)) {
+-                        if (feof(f))
+-                                return 0;
+-                        return -errno;
+-                }
++                r = read_line(f, LONG_LINE_MAX, &line);
++                if (r < 0)
++                        return log_error_errno(r, "Failed to read serialization line: %m");
++                if (r == 0) /* eof */
++                        break;
+ 
+-                char_array_0(line);
+                 l = strstrip(line);
+-
+-                /* End marker */
+-                if (isempty(l))
++                if (isempty(l)) /* End marker */
+                         break;
+ 
+                 k = strcspn(l, "=");
+@@ -3671,23 +3669,27 @@ int unit_deserialize(Unit *u, FILE *f, FDSet *fds) {
+         return 0;
+ }
+ 
+-void unit_deserialize_skip(FILE *f) {
++int unit_deserialize_skip(FILE *f) {
++        int r;
+         assert(f);
+ 
+         /* Skip serialized data for this unit. We don't know what it is. */
+ 
+         for (;;) {
+-                char line[LINE_MAX], *l;
++                _cleanup_free_ char *line = NULL;
++                char *l;
+ 
+-                if (!fgets(line, sizeof line, f))
+-                        return;
++                r = read_line(f, LONG_LINE_MAX, &line);
++                if (r < 0)
++                        return log_error_errno(r, "Failed to read serialization line: %m");
++                if (r == 0)
++                        return 0;
+ 
+-                char_array_0(line);
+                 l = strstrip(line);
+ 
+                 /* End marker */
+                 if (isempty(l))
+-                        return;
++                        return 1;
+         }
+ }
+ 
+diff --git a/src/core/unit.h b/src/core/unit.h
+index 06321bb..51c7aaa 100644
+--- a/src/core/unit.h
++++ b/src/core/unit.h
+@@ -684,7 +684,7 @@ bool unit_can_serialize(Unit *u) _pure_;
+ 
+ int unit_serialize(Unit *u, FILE *f, FDSet *fds, bool serialize_jobs);
+ int unit_deserialize(Unit *u, FILE *f, FDSet *fds);
+-void unit_deserialize_skip(FILE *f);
++int unit_deserialize_skip(FILE *f);
+ 
+ int unit_serialize_item(Unit *u, FILE *f, const char *key, const char *value);
+ int unit_serialize_item_escaped(Unit *u, FILE *f, const char *key, const char *value);
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0001-dhcp6-make-sure-we-have-enough-space-for-the-DHCP6-o.patch b/poky/meta/recipes-core/systemd/systemd/0001-dhcp6-make-sure-we-have-enough-space-for-the-DHCP6-o.patch
new file mode 100644
index 0000000..0c912f2
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0001-dhcp6-make-sure-we-have-enough-space-for-the-DHCP6-o.patch
@@ -0,0 +1,39 @@
+From a2622b8398ba026faf481f5eddeb53231d9de4a7 Mon Sep 17 00:00:00 2001
+From: Lennart Poettering <lennart@poettering.net>
+Date: Fri, 19 Oct 2018 12:12:33 +0200
+Subject: [PATCH] dhcp6: make sure we have enough space for the DHCP6 option
+ header
+
+Fixes a vulnerability originally discovered by Felix Wilhelm from
+Google.
+
+CVE-2018-15688
+LP: #1795921
+https://bugzilla.redhat.com/show_bug.cgi?id=1639067
+
+(cherry picked from commit 4dac5eaba4e419b29c97da38a8b1f82336c2c892)
+
+CVE: CVE-2018-15688
+Upstream-Status: Backport
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/libsystemd-network/dhcp6-option.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/libsystemd-network/dhcp6-option.c b/src/libsystemd-network/dhcp6-option.c
+index c4b402b..dcbaad0 100644
+--- a/src/libsystemd-network/dhcp6-option.c
++++ b/src/libsystemd-network/dhcp6-option.c
+@@ -103,7 +103,7 @@ int dhcp6_option_append_ia(uint8_t **buf, size_t *buflen, DHCP6IA *ia) {
+                 return -EINVAL;
+         }
+ 
+-        if (*buflen < len)
++        if (*buflen < offsetof(DHCP6Option, data) + len)
+                 return -ENOBUFS;
+ 
+         ia_hdr = *buf;
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0001-login-use-parse_uid-when-unmounting-user-runtime-dir.patch b/poky/meta/recipes-core/systemd/systemd/0001-login-use-parse_uid-when-unmounting-user-runtime-dir.patch
new file mode 100644
index 0000000..ba08e34
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0001-login-use-parse_uid-when-unmounting-user-runtime-dir.patch
@@ -0,0 +1,110 @@
+From 86d18f3b09ec984ef3732567af992adb2dc77a8a Mon Sep 17 00:00:00 2001
+From: Yu Watanabe <watanabe.yu+github@gmail.com>
+Date: Mon, 9 Jul 2018 14:05:20 +0900
+Subject: [PATCH] login: use parse_uid() when unmounting user runtime directory
+
+When unmounting user runtime directory, only UID is necessary,
+and the corresponding user may not exist anymore.
+This makes first try to parse the input by parse_uid(), and only if it
+fails, prase the input by get_user_creds().
+
+Fixes #9541.
+
+Upstream-Status: Backport
+---
+ src/login/user-runtime-dir.c | 57 ++++++++++++++++++++++++++++----------------
+ 1 file changed, 36 insertions(+), 21 deletions(-)
+
+diff --git a/src/login/user-runtime-dir.c b/src/login/user-runtime-dir.c
+index 1bb26c99e..de4061c75 100644
+--- a/src/login/user-runtime-dir.c
++++ b/src/login/user-runtime-dir.c
+@@ -111,8 +111,22 @@ static int user_remove_runtime_path(const char *runtime_path) {
+         return r;
+ }
+ 
+-static int do_mount(const char *runtime_path, uid_t uid, gid_t gid) {
++static int do_mount(const char *user) {
++        char runtime_path[sizeof("/run/user") + DECIMAL_STR_MAX(uid_t)];
+         size_t runtime_dir_size;
++        uid_t uid;
++        gid_t gid;
++        int r;
++
++        r = get_user_creds(&user, &uid, &gid, NULL, NULL);
++        if (r < 0)
++                return log_error_errno(r,
++                                       r == -ESRCH ? "No such user \"%s\"" :
++                                       r == -ENOMSG ? "UID \"%s\" is invalid or has an invalid main group"
++                                                    : "Failed to look up user \"%s\": %m",
++                                       user);
++
++        xsprintf(runtime_path, "/run/user/" UID_FMT, uid);
+ 
+         assert_se(gather_configuration(&runtime_dir_size) == 0);
+ 
+@@ -120,16 +134,30 @@ static int do_mount(const char *runtime_path, uid_t uid, gid_t gid) {
+         return user_mkdir_runtime_path(runtime_path, uid, gid, runtime_dir_size);
+ }
+ 
+-static int do_umount(const char *runtime_path) {
++static int do_umount(const char *user) {
++        char runtime_path[sizeof("/run/user") + DECIMAL_STR_MAX(uid_t)];
++        uid_t uid;
++        int r;
++
++        /* The user may be already removed. So, first try to parse the string by parse_uid(),
++         * and if it fails, fallback to get_user_creds().*/
++        if (parse_uid(user, &uid) < 0) {
++                r = get_user_creds(&user, &uid, NULL, NULL, NULL);
++                if (r < 0)
++                        return log_error_errno(r,
++                                               r == -ESRCH ? "No such user \"%s\"" :
++                                               r == -ENOMSG ? "UID \"%s\" is invalid or has an invalid main group"
++                                                            : "Failed to look up user \"%s\": %m",
++                                               user);
++        }
++
++        xsprintf(runtime_path, "/run/user/" UID_FMT, uid);
++
+         log_debug("Will remove %s", runtime_path);
+         return user_remove_runtime_path(runtime_path);
+ }
+ 
+ int main(int argc, char *argv[]) {
+-        const char *user;
+-        uid_t uid;
+-        gid_t gid;
+-        char runtime_path[sizeof("/run/user") + DECIMAL_STR_MAX(uid_t)];
+         int r;
+ 
+         log_parse_environment();
+@@ -146,23 +174,10 @@ int main(int argc, char *argv[]) {
+ 
+         umask(0022);
+ 
+-        user = argv[2];
+-        r = get_user_creds(&user, &uid, &gid, NULL, NULL);
+-        if (r < 0) {
+-                log_error_errno(r,
+-                                r == -ESRCH ? "No such user \"%s\"" :
+-                                r == -ENOMSG ? "UID \"%s\" is invalid or has an invalid main group"
+-                                             : "Failed to look up user \"%s\": %m",
+-                                user);
+-                return EXIT_FAILURE;
+-        }
+-
+-        xsprintf(runtime_path, "/run/user/" UID_FMT, uid);
+-
+         if (streq(argv[1], "start"))
+-                r = do_mount(runtime_path, uid, gid);
++                r = do_mount(argv[2]);
+         else if (streq(argv[1], "stop"))
+-                r = do_umount(runtime_path);
++                r = do_umount(argv[2]);
+         else
+                 assert_not_reached("Unknown verb!");
+ 
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0001-sd-bus-make-BUS_DEFAULT_TIMEOUT-configurable.patch b/poky/meta/recipes-core/systemd/systemd/0001-sd-bus-make-BUS_DEFAULT_TIMEOUT-configurable.patch
new file mode 100644
index 0000000..45c9b5b
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0001-sd-bus-make-BUS_DEFAULT_TIMEOUT-configurable.patch
@@ -0,0 +1,175 @@
+From 5b75a72ee968c9666b5f2ea313720b6c383cb4c2 Mon Sep 17 00:00:00 2001
+From: Yu Watanabe <watanabe.yu+github@gmail.com>
+Date: Fri, 13 Jul 2018 17:38:47 +0900
+Subject: [PATCH] sd-bus: make BUS_DEFAULT_TIMEOUT configurable
+
+This adds sd_bus_{get,set}_method_call_timeout().
+If the timeout is not set or set to 0, then the timeout value is
+parsed from $SYSTEMD_BUS_TIMEOUT= environment variable. If the
+environment variable is not set, then built-in timeout is used.
+---
+ doc/ENVIRONMENT.md                   |  5 +++++
+ src/libsystemd/libsystemd.sym        |  5 +++++
+ src/libsystemd/sd-bus/bus-internal.h |  9 ++++----
+ src/libsystemd/sd-bus/bus-message.c  |  7 +++++--
+ src/libsystemd/sd-bus/sd-bus.c       | 40 ++++++++++++++++++++++++++++++++++--
+ src/systemd/sd-bus.h                 |  3 +++
+ 6 files changed, 61 insertions(+), 8 deletions(-)
+
+Upstream-Status: Backport
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+
+diff --git a/doc/ENVIRONMENT.md b/doc/ENVIRONMENT.md
+index 85d26fe28c..641a03d5d7 100644
+--- a/doc/ENVIRONMENT.md
++++ b/doc/ENVIRONMENT.md
+@@ -37,6 +37,11 @@ All tools:
+   useful for debugging, in order to test generators and other code against
+   specific kernel command lines.
+ 
++* `$SYSTEMD_BUS_TIMEOUT=SECS` — specifies the maximum time to wait for method call
++  completion. If no time unit is specified, assumes seconds. The usual other units
++  are understood, too (us, ms, s, min, h, d, w, month, y). If it is not set or set
++  to 0, then the built-in default is used.
++
+ systemctl:
+ 
+ * `$SYSTEMCTL_FORCE_BUS=1` — if set, do not connect to PID1's private D-Bus
+diff --git a/src/libsystemd/libsystemd.sym b/src/libsystemd/libsystemd.sym
+index 1eec17db50..006dbc9c3f 100644
+--- a/src/libsystemd/libsystemd.sym
++++ b/src/libsystemd/libsystemd.sym
+@@ -570,3 +570,8 @@ global:
+         sd_event_source_set_destroy_callback;
+         sd_event_source_get_destroy_callback;
+ } LIBSYSTEMD_238;
++
++LIBSYSTEMD_240 {
++        sd_bus_set_method_call_timeout;
++        sd_bus_get_method_call_timeout;
++} LIBSYSTEMD_239;
+diff --git a/src/libsystemd/sd-bus/bus-internal.h b/src/libsystemd/sd-bus/bus-internal.h
+index 2087ef8eeb..4864b1e911 100644
+--- a/src/libsystemd/sd-bus/bus-internal.h
++++ b/src/libsystemd/sd-bus/bus-internal.h
+@@ -319,6 +319,9 @@ struct sd_bus {
+ 
+         int *inotify_watches;
+         size_t n_inotify_watches;
++
++        /* zero means use value specified by $SYSTEMD_BUS_TIMEOUT= environment variable or built-in default */
++        usec_t method_call_timeout;
+ };
+ 
+ /* For method calls we time-out at 25s, like in the D-Bus reference implementation */
+@@ -336,8 +339,7 @@ struct sd_bus {
+ 
+ #define BUS_CONTAINER_DEPTH 128
+ 
+-/* Defined by the specification as maximum size of an array in
+- * bytes */
++/* Defined by the specification as maximum size of an array in bytes */
+ #define BUS_ARRAY_MAX_SIZE 67108864
+ 
+ #define BUS_FDS_MAX 1024
+@@ -388,8 +390,7 @@ void bus_close_io_fds(sd_bus *b);
+              _slash = streq((prefix), "/") ? NULL : strrchr((prefix), '/'))
+ 
+ /* If we are invoking callbacks of a bus object, ensure unreffing the
+- * bus from the callback doesn't destroy the object we are working
+- * on */
++ * bus from the callback doesn't destroy the object we are working on */
+ #define BUS_DONT_DESTROY(bus) \
+         _cleanup_(sd_bus_unrefp) _unused_ sd_bus *_dont_destroy_##bus = sd_bus_ref(bus)
+ 
+diff --git a/src/libsystemd/sd-bus/bus-message.c b/src/libsystemd/sd-bus/bus-message.c
+index 8d92bc2002..dffe70a665 100644
+--- a/src/libsystemd/sd-bus/bus-message.c
++++ b/src/libsystemd/sd-bus/bus-message.c
+@@ -5809,8 +5809,11 @@ int bus_message_remarshal(sd_bus *bus, sd_bus_message **m) {
+                 return r;
+ 
+         timeout = (*m)->timeout;
+-        if (timeout == 0 && !((*m)->header->flags & BUS_MESSAGE_NO_REPLY_EXPECTED))
+-                timeout = BUS_DEFAULT_TIMEOUT;
++        if (timeout == 0 && !((*m)->header->flags & BUS_MESSAGE_NO_REPLY_EXPECTED)) {
++                r = sd_bus_get_method_call_timeout(bus, &timeout);
++                if (r < 0)
++                        return r;
++        }
+ 
+         r = sd_bus_message_seal(n, BUS_MESSAGE_COOKIE(*m), timeout);
+         if (r < 0)
+diff --git a/src/libsystemd/sd-bus/sd-bus.c b/src/libsystemd/sd-bus/sd-bus.c
+index 089b51a6d9..945490ebf7 100644
+--- a/src/libsystemd/sd-bus/sd-bus.c
++++ b/src/libsystemd/sd-bus/sd-bus.c
+@@ -1611,8 +1611,11 @@ static int bus_seal_message(sd_bus *b, sd_bus_message *m, usec_t timeout) {
+                 return 0;
+         }
+ 
+-        if (timeout == 0)
+-                timeout = BUS_DEFAULT_TIMEOUT;
++        if (timeout == 0) {
++                r = sd_bus_get_method_call_timeout(b, &timeout);
++                if (r < 0)
++                        return r;
++        }
+ 
+         if (!m->sender && b->patch_sender) {
+                 r = sd_bus_message_set_sender(m, b->patch_sender);
+@@ -4075,3 +4078,36 @@ _public_ int sd_bus_get_n_queued_write(sd_bus *bus, uint64_t *ret) {
+         *ret = bus->wqueue_size;
+         return 0;
+ }
++
++_public_ int sd_bus_set_method_call_timeout(sd_bus *bus, uint64_t usec) {
++        assert_return(bus, -EINVAL);
++        assert_return(bus = bus_resolve(bus), -ENOPKG);
++
++        bus->method_call_timeout = usec;
++        return 0;
++}
++
++_public_ int sd_bus_get_method_call_timeout(sd_bus *bus, uint64_t *ret) {
++        const char *e;
++        usec_t usec;
++
++        assert_return(bus, -EINVAL);
++        assert_return(bus = bus_resolve(bus), -ENOPKG);
++        assert_return(ret, -EINVAL);
++
++        if (bus->method_call_timeout != 0) {
++                *ret = bus->method_call_timeout;
++                return 0;
++        }
++
++        e = secure_getenv("SYSTEMD_BUS_TIMEOUT");
++        if (e && parse_sec(e, &usec) >= 0 && usec != 0) {
++                /* Save the parsed value to avoid multiple parsing. To change the timeout value,
++                 * use sd_bus_set_method_call_timeout() instead of setenv(). */
++                *ret = bus->method_call_timeout = usec;
++                return 0;
++        }
++
++        *ret = bus->method_call_timeout = BUS_DEFAULT_TIMEOUT;
++        return 0;
++}
+diff --git a/src/systemd/sd-bus.h b/src/systemd/sd-bus.h
+index 54c4b1ca83..c9fd254834 100644
+--- a/src/systemd/sd-bus.h
++++ b/src/systemd/sd-bus.h
+@@ -206,6 +206,9 @@ sd_event *sd_bus_get_event(sd_bus *bus);
+ int sd_bus_get_n_queued_read(sd_bus *bus, uint64_t *ret);
+ int sd_bus_get_n_queued_write(sd_bus *bus, uint64_t *ret);
+ 
++int sd_bus_set_method_call_timeout(sd_bus *bus, uint64_t usec);
++int sd_bus_get_method_call_timeout(sd_bus *bus, uint64_t *ret);
++
+ int sd_bus_add_filter(sd_bus *bus, sd_bus_slot **slot, sd_bus_message_handler_t callback, void *userdata);
+ int sd_bus_add_match(sd_bus *bus, sd_bus_slot **slot, const char *match, sd_bus_message_handler_t callback, void *userdata);
+ int sd_bus_add_match_async(sd_bus *bus, sd_bus_slot **slot, const char *match, sd_bus_message_handler_t callback, sd_bus_message_handler_t install_callback, void *userdata);
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0002-binfmt-Don-t-install-dependency-links-at-install-tim.patch b/poky/meta/recipes-core/systemd/systemd/0002-binfmt-Don-t-install-dependency-links-at-install-tim.patch
deleted file mode 100644
index c3f4b39..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0002-binfmt-Don-t-install-dependency-links-at-install-tim.patch
+++ /dev/null
@@ -1,81 +0,0 @@
-From c93eb6cdec03f5e243e59e95dc49273fcb90e7c1 Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Fri, 23 Feb 2018 10:23:40 +0800
-Subject: [PATCH 02/31] binfmt: Don't install dependency links at install time
- for the binfmt services
-
-use [Install] blocks so that they get created when the service is enabled
-like a traditional service.
-
-The [Install] blocks were rejected upstream as they don't have a way to
-"enable" it on install without static symlinks which can't be disabled,
-only masked. We however can do that in a postinst.
-
-Upstream-Status: Denied
-
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- units/meson.build                       | 6 ++----
- units/proc-sys-fs-binfmt_misc.automount | 3 +++
- units/systemd-binfmt.service.in         | 4 ++++
- 3 files changed, 9 insertions(+), 4 deletions(-)
-
-diff --git a/units/meson.build b/units/meson.build
-index 814ee7885..49ace0d0f 100644
---- a/units/meson.build
-+++ b/units/meson.build
-@@ -60,8 +60,7 @@ units = [
-         ['poweroff.target',                     '',
-          'runlevel0.target'],
-         ['printer.target',                      ''],
--        ['proc-sys-fs-binfmt_misc.automount',   'ENABLE_BINFMT',
--         'sysinit.target.wants/'],
-+        ['proc-sys-fs-binfmt_misc.automount',   'ENABLE_BINFMT'],
-         ['proc-sys-fs-binfmt_misc.mount',       'ENABLE_BINFMT'],
-         ['reboot.target',                       '',
-          'runlevel6.target ctrl-alt-del.target'],
-@@ -144,8 +143,7 @@ in_units = [
-         ['systemd-ask-password-console.service', ''],
-         ['systemd-ask-password-wall.service',    ''],
-         ['systemd-backlight@.service',           'ENABLE_BACKLIGHT'],
--        ['systemd-binfmt.service',               'ENABLE_BINFMT',
--         'sysinit.target.wants/'],
-+        ['systemd-binfmt.service',               'ENABLE_BINFMT'],
-         ['systemd-coredump@.service',            'ENABLE_COREDUMP'],
-         ['systemd-exit.service',                 ''],
-         ['systemd-firstboot.service',            'ENABLE_FIRSTBOOT',
-diff --git a/units/proc-sys-fs-binfmt_misc.automount b/units/proc-sys-fs-binfmt_misc.automount
-index 30a6bc991..4231f3b70 100644
---- a/units/proc-sys-fs-binfmt_misc.automount
-+++ b/units/proc-sys-fs-binfmt_misc.automount
-@@ -18,3 +18,6 @@ ConditionPathIsReadWrite=/proc/sys/
- 
- [Automount]
- Where=/proc/sys/fs/binfmt_misc
-+
-+[Install]
-+WantedBy=sysinit.target
-diff --git a/units/systemd-binfmt.service.in b/units/systemd-binfmt.service.in
-index df9396d89..0687f4648 100644
---- a/units/systemd-binfmt.service.in
-+++ b/units/systemd-binfmt.service.in
-@@ -13,6 +13,7 @@ Documentation=man:systemd-binfmt.service(8) man:binfmt.d(5)
- Documentation=https://www.kernel.org/doc/Documentation/binfmt_misc.txt
- DefaultDependencies=no
- Conflicts=shutdown.target
-+Wants=proc-sys-fs-binfmt_misc.automount
- After=proc-sys-fs-binfmt_misc.automount
- Before=sysinit.target shutdown.target
- ConditionPathIsReadWrite=/proc/sys/
-@@ -27,3 +28,6 @@ Type=oneshot
- RemainAfterExit=yes
- ExecStart=@rootlibexecdir@/systemd-binfmt
- TimeoutSec=90s
-+
-+[Install]
-+WantedBy=sysinit.target
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0002-don-t-use-glibc-specific-qsort_r.patch b/poky/meta/recipes-core/systemd/systemd/0002-don-t-use-glibc-specific-qsort_r.patch
new file mode 100644
index 0000000..8e0d669
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0002-don-t-use-glibc-specific-qsort_r.patch
@@ -0,0 +1,183 @@
+From d74a4de6daea5a511c2b5636bbb552c15b3a4ad9 Mon Sep 17 00:00:00 2001
+From: Emil Renner Berthing <systemd@esmil.dk>
+Date: Thu, 18 Sep 2014 15:24:56 +0200
+Subject: [PATCH] don't use glibc-specific qsort_r
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/basic/format-table.c | 27 ++++++++++++++++-----------
+ src/basic/util.h         |  7 -------
+ src/hwdb/hwdb.c          | 18 +++++++++++-------
+ src/udev/udevadm-hwdb.c  | 16 ++++++++++------
+ 4 files changed, 37 insertions(+), 31 deletions(-)
+
+diff --git a/src/basic/format-table.c b/src/basic/format-table.c
+index 94e796d1ca..9b3f35c29a 100644
+--- a/src/basic/format-table.c
++++ b/src/basic/format-table.c
+@@ -745,29 +745,29 @@ static int cell_data_compare(TableData *a, size_t index_a, TableData *b, size_t
+         return 0;
+ }
+ 
+-static int table_data_compare(const void *x, const void *y, void *userdata) {
++static Table *user_table;
++static int table_data_compare(const void *x, const void *y) {
+         const size_t *a = x, *b = y;
+-        Table *t = userdata;
+         size_t i;
+         int r;
+ 
+-        assert(t);
+-        assert(t->sort_map);
++        assert(user_table);
++        assert(user_table->sort_map);
+ 
+         /* Make sure the header stays at the beginning */
+-        if (*a < t->n_columns && *b < t->n_columns)
++        if (*a < user_table->n_columns && *b < user_table->n_columns)
+                 return 0;
+-        if (*a < t->n_columns)
++        if (*a < user_table->n_columns)
+                 return -1;
+-        if (*b < t->n_columns)
++        if (*b < user_table->n_columns)
+                 return 1;
+ 
+         /* Order other lines by the sorting map */
+-        for (i = 0; i < t->n_sort_map; i++) {
++        for (i = 0; i < user_table->n_sort_map; i++) {
+                 TableData *d, *dd;
+ 
+-                d = t->data[*a + t->sort_map[i]];
+-                dd = t->data[*b + t->sort_map[i]];
++                d = user_table->data[*a + user_table->sort_map[i]];
++                dd = user_table->data[*b + user_table->sort_map[i]];
+ 
+                 r = cell_data_compare(d, *a, dd, *b);
+                 if (r != 0)
+@@ -960,7 +960,12 @@ int table_print(Table *t, FILE *f) {
+                 for (i = 0; i < n_rows; i++)
+                         sorted[i] = i * t->n_columns;
+ 
+-                qsort_r_safe(sorted, n_rows, sizeof(size_t), table_data_compare, t);
++                if (n_rows <= 1)
++                        return 0;
++                assert(sorted);
++                user_table = t;
++                qsort(sorted, n_rows, sizeof(size_t), table_data_compare);
++                user_table = NULL;
+         }
+ 
+         if (t->display_map)
+diff --git a/src/basic/util.h b/src/basic/util.h
+index 9699d228f9..40eaf518cb 100644
+--- a/src/basic/util.h
++++ b/src/basic/util.h
+@@ -105,13 +105,6 @@ static inline void qsort_safe(void *base, size_t nmemb, size_t size, comparison_
+                 qsort_safe((p), (n), sizeof((p)[0]), (__compar_fn_t) _func_); \
+         })
+ 
+-static inline void qsort_r_safe(void *base, size_t nmemb, size_t size, int (*compar)(const void*, const void*, void*), void *userdata) {
+-        if (nmemb <= 1)
+-                return;
+-
+-        assert(base);
+-        qsort_r(base, nmemb, size, compar, userdata);
+-}
+ 
+ /**
+  * Normal memcpy requires src to be nonnull. We do nothing if n is 0.
+diff --git a/src/hwdb/hwdb.c b/src/hwdb/hwdb.c
+index 317cad8a67..701d59a1eb 100644
+--- a/src/hwdb/hwdb.c
++++ b/src/hwdb/hwdb.c
+@@ -135,13 +135,12 @@ static void trie_free(struct trie *trie) {
+ 
+ DEFINE_TRIVIAL_CLEANUP_FUNC(struct trie*, trie_free);
+ 
+-static int trie_values_cmp(const void *v1, const void *v2, void *arg) {
++static struct trie *trie_node_add_value_trie;
++static int trie_values_cmp(const void *v1, const void *v2) {
+         const struct trie_value_entry *val1 = v1;
+         const struct trie_value_entry *val2 = v2;
+-        struct trie *trie = arg;
+-
+-        return strcmp(trie->strings->buf + val1->key_off,
+-                      trie->strings->buf + val2->key_off);
++        return strcmp(trie_node_add_value_trie->strings->buf + val1->key_off,
++                      trie_node_add_value_trie->strings->buf + val2->key_off);
+ }
+ 
+ static int trie_node_add_value(struct trie *trie, struct trie_node *node,
+@@ -166,7 +165,10 @@ static int trie_node_add_value(struct trie *trie, struct trie_node *node,
+                         .value_off = v,
+                 };
+ 
+-                val = xbsearch_r(&search, node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp, trie);
++                trie_node_add_value_trie = trie;
++                val = bsearch(&search, node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp);
++                trie_node_add_value_trie = NULL;
++
+                 if (val) {
+                         /* At this point we have 2 identical properties on the same match-string.
+                          * Since we process files in order, we just replace the previous value.
+@@ -191,7 +193,9 @@ static int trie_node_add_value(struct trie *trie, struct trie_node *node,
+         node->values[node->values_count].file_priority = file_priority;
+         node->values[node->values_count].line_number = line_number;
+         node->values_count++;
+-        qsort_r(node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp, trie);
++        trie_node_add_value_trie = trie;
++        qsort(node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp);
++        trie_node_add_value_trie = NULL;
+         return 0;
+ }
+ 
+diff --git a/src/udev/udevadm-hwdb.c b/src/udev/udevadm-hwdb.c
+index 02408a4285..491d367d12 100644
+--- a/src/udev/udevadm-hwdb.c
++++ b/src/udev/udevadm-hwdb.c
+@@ -114,13 +114,13 @@ static void trie_node_cleanup(struct trie_node *node) {
+         free(node);
+ }
+ 
+-static int trie_values_cmp(const void *v1, const void *v2, void *arg) {
++static struct trie *trie_node_add_value_trie;
++static int trie_values_cmp(const void *v1, const void *v2) {
+         const struct trie_value_entry *val1 = v1;
+         const struct trie_value_entry *val2 = v2;
+-        struct trie *trie = arg;
+ 
+-        return strcmp(trie->strings->buf + val1->key_off,
+-                      trie->strings->buf + val2->key_off);
++        return strcmp(trie_node_add_value_trie->strings->buf + val1->key_off,
++                      trie_node_add_value_trie->strings->buf + val2->key_off);
+ }
+ 
+ static int trie_node_add_value(struct trie *trie, struct trie_node *node,
+@@ -141,7 +141,9 @@ static int trie_node_add_value(struct trie *trie, struct trie_node *node,
+                         .value_off = v,
+                 };
+ 
+-                val = xbsearch_r(&search, node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp, trie);
++                trie_node_add_value_trie = trie;
++                val = bsearch(&search, node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp);
++                trie_node_add_value_trie = NULL;
+                 if (val) {
+                         /* replace existing earlier key with new value */
+                         val->value_off = v;
+@@ -158,7 +160,9 @@ static int trie_node_add_value(struct trie *trie, struct trie_node *node,
+         node->values[node->values_count].key_off = k;
+         node->values[node->values_count].value_off = v;
+         node->values_count++;
+-        qsort_r(node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp, trie);
++        trie_node_add_value_trie = trie;
++        qsort(node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp);
++        trie_node_add_value_trie = NULL;
+         return 0;
+ }
+ 
+-- 
+2.18.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0002-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch b/poky/meta/recipes-core/systemd/systemd/0002-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch
new file mode 100644
index 0000000..1d7f523
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0002-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch
@@ -0,0 +1,64 @@
+From 6e62be87a2722fbe531310a1b052c1301bdf06fb Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Wed, 27 Jun 2018 16:09:24 +0800
+Subject: [PATCH 2/9] use lnr wrapper instead of looking for --relative option
+ for ln
+
+Remove file manually to avoid the 'File Exists' error when creating
+symlink. This is because the original 'ln' command uses '-f' option.
+
+Upstream-Status: Inappropriate [OE-Specific]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ meson.build                 | 4 ----
+ tools/meson-make-symlink.sh | 3 ++-
+ units/meson-add-wants.sh    | 7 ++++++-
+ 3 files changed, 8 insertions(+), 6 deletions(-)
+
+diff --git a/meson.build b/meson.build
+index 04331dd41..6d5edcb4e 100644
+--- a/meson.build
++++ b/meson.build
+@@ -558,10 +558,6 @@ endforeach
+ 
+ conf.set_quoted('TELINIT', get_option('telinit-path'))
+ 
+-if run_command('ln', '--relative', '--help').returncode() != 0
+-        error('ln does not support --relative (added in coreutils 8.16)')
+-endif
+-
+ ############################################################
+ 
+ gperf = find_program('gperf')
+diff --git a/tools/meson-make-symlink.sh b/tools/meson-make-symlink.sh
+index 501cd43d4..f4e4ac9ac 100755
+--- a/tools/meson-make-symlink.sh
++++ b/tools/meson-make-symlink.sh
+@@ -8,5 +8,6 @@ mkdir -vp "$(dirname "${DESTDIR:-}$2")"
+ if [ "$(dirname $1)" = . ]; then
+         ln -vfs -T "$1" "${DESTDIR:-}$2"
+ else
+-        ln -vfs -T --relative "${DESTDIR:-}$1" "${DESTDIR:-}$2"
++        rm -f "${DESTDIR:-}$2"
++        lnr "${DESTDIR:-}$1" "${DESTDIR:-}$2"
+ fi
+diff --git a/units/meson-add-wants.sh b/units/meson-add-wants.sh
+index 70f7172ae..a42666aac 100755
+--- a/units/meson-add-wants.sh
++++ b/units/meson-add-wants.sh
+@@ -25,4 +25,9 @@ case "$target" in
+                 ;;
+ esac
+ 
+-ln -vfs --relative "$unitpath" "$dir"
++if [ -d "$dir" ]; then
++        rm -f "$dir/$unit"
++        lnr "$unitpath" "$dir/$unit"
++else
++        lnr "$unitpath" "$dir"
++fi
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0003-comparison_fn_t-is-glibc-specific-use-raw-signature-.patch b/poky/meta/recipes-core/systemd/systemd/0003-comparison_fn_t-is-glibc-specific-use-raw-signature-.patch
new file mode 100644
index 0000000..115fb33
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0003-comparison_fn_t-is-glibc-specific-use-raw-signature-.patch
@@ -0,0 +1,40 @@
+From e965e748c7030df0709e63128db2f023540a06ba Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 12 Sep 2015 18:53:31 +0000
+Subject: [PATCH 03/19] comparison_fn_t is glibc specific, use raw signature in
+ function pointer
+
+make it work with musl where comparison_fn_t is not provided
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/basic/util.h | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/basic/util.h b/src/basic/util.h
+index 40eaf518c..c58392397 100644
+--- a/src/basic/util.h
++++ b/src/basic/util.h
+@@ -77,7 +77,7 @@ void *xbsearch_r(const void *key, const void *base, size_t nmemb, size_t size,
+  * that only if nmemb > 0.
+  */
+ static inline void* bsearch_safe(const void *key, const void *base,
+-                                 size_t nmemb, size_t size, comparison_fn_t compar) {
++                                 size_t nmemb, size_t size, int (*compar)(const void *, const void *)) {
+         if (nmemb <= 0)
+                 return NULL;
+ 
+@@ -89,7 +89,7 @@ static inline void* bsearch_safe(const void *key, const void *base,
+  * Normal qsort requires base to be nonnull. Here were require
+  * that only if nmemb > 0.
+  */
+-static inline void qsort_safe(void *base, size_t nmemb, size_t size, comparison_fn_t compar) {
++static inline void qsort_safe(void *base, size_t nmemb, size_t size, int (*compar)(const void *, const void *)) {
+         if (nmemb <= 1)
+                 return;
+ 
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0003-implment-systemd-sysv-install-for-OE.patch b/poky/meta/recipes-core/systemd/systemd/0003-implment-systemd-sysv-install-for-OE.patch
new file mode 100644
index 0000000..6c595ae
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0003-implment-systemd-sysv-install-for-OE.patch
@@ -0,0 +1,43 @@
+From 0fcb6e646401205e17cc6c129441a49023c62cef Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 5 Sep 2015 06:31:47 +0000
+Subject: [PATCH 3/9] implment systemd-sysv-install for OE
+
+Use update-rc.d for enabling/disabling and status command
+to check the status of the sysv service
+
+Upstream-Status: Inappropriate [OE-Specific]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/systemctl/systemd-sysv-install.SKELETON | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/src/systemctl/systemd-sysv-install.SKELETON b/src/systemctl/systemd-sysv-install.SKELETON
+index 8c16cf999..9f078a121 100755
+--- a/src/systemctl/systemd-sysv-install.SKELETON
++++ b/src/systemctl/systemd-sysv-install.SKELETON
+@@ -32,17 +32,17 @@ case "$1" in
+     enable)
+         # call the command to enable SysV init script $NAME here
+         # (consider optional $ROOT)
+-        echo "IMPLEMENT ME: enabling SysV init.d script $NAME"
++        update-rc.d -f $NAME defaults
+         ;;
+     disable)
+         # call the command to disable SysV init script $NAME here
+         # (consider optional $ROOT)
+-        echo "IMPLEMENT ME: disabling SysV init.d script $NAME"
++        update-rc.d -f $NAME remove
+         ;;
+     is-enabled)
+         # exit with 0 if $NAME is enabled, non-zero if it is disabled
+         # (consider optional $ROOT)
+-        echo "IMPLEMENT ME: checking SysV init.d script $NAME"
++        /etc/init.d/$NAME status
+         ;;
+     *)
+         usage ;;
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0003-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch b/poky/meta/recipes-core/systemd/systemd/0003-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch
deleted file mode 100644
index 28f1b21..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0003-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch
+++ /dev/null
@@ -1,64 +0,0 @@
-From 8b9d194e956848e0d1fb35ef2fba714b2691ebe6 Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Wed, 28 Feb 2018 20:47:49 -0800
-Subject: [PATCH 03/31] use lnr wrapper instead of looking for --relative
- option for ln
-
-Remove file manually to avoid the 'File Exists' error when creating
-symlink. This is because the original 'ln' command uses '-f' option.
-
-Upstream-Status: Inappropriate [OE-Specific]
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- meson.build                 | 4 ----
- tools/meson-make-symlink.sh | 3 ++-
- units/meson-add-wants.sh    | 7 ++++++-
- 3 files changed, 8 insertions(+), 6 deletions(-)
-
-diff --git a/meson.build b/meson.build
-index 36a62d280..7347ea880 100644
---- a/meson.build
-+++ b/meson.build
-@@ -570,10 +570,6 @@ endforeach
- 
- conf.set_quoted('TELINIT', get_option('telinit-path'))
- 
--if run_command('ln', '--relative', '--help').returncode() != 0
--        error('ln does not support --relative')
--endif
--
- ############################################################
- 
- gperf = find_program('gperf')
-diff --git a/tools/meson-make-symlink.sh b/tools/meson-make-symlink.sh
-index 501cd43d4..f4e4ac9ac 100755
---- a/tools/meson-make-symlink.sh
-+++ b/tools/meson-make-symlink.sh
-@@ -8,5 +8,6 @@ mkdir -vp "$(dirname "${DESTDIR:-}$2")"
- if [ "$(dirname $1)" = . ]; then
-         ln -vfs -T "$1" "${DESTDIR:-}$2"
- else
--        ln -vfs -T --relative "${DESTDIR:-}$1" "${DESTDIR:-}$2"
-+        rm -f "${DESTDIR:-}$2"
-+        lnr "${DESTDIR:-}$1" "${DESTDIR:-}$2"
- fi
-diff --git a/units/meson-add-wants.sh b/units/meson-add-wants.sh
-index 70f7172ae..a42666aac 100755
---- a/units/meson-add-wants.sh
-+++ b/units/meson-add-wants.sh
-@@ -25,4 +25,9 @@ case "$target" in
-                 ;;
- esac
- 
--ln -vfs --relative "$unitpath" "$dir"
-+if [ -d "$dir" ]; then
-+        rm -f "$dir/$unit"
-+        lnr "$unitpath" "$dir/$unit"
-+else
-+        lnr "$unitpath" "$dir"
-+fi
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0004-add-fallback-parse_printf_format-implementation.patch b/poky/meta/recipes-core/systemd/systemd/0004-add-fallback-parse_printf_format-implementation.patch
new file mode 100644
index 0000000..7652a2d
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0004-add-fallback-parse_printf_format-implementation.patch
@@ -0,0 +1,432 @@
+From 582af7ec13131dfcc620ed81de7b211914c4cb03 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Fri, 29 Jun 2018 13:43:49 +0800
+Subject: [PATCH 04/19] add fallback parse_printf_format implementation
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Emil Renner Berthing <systemd@esmil.dk>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ meson.build                     |   1 +
+ src/basic/meson.build           |   5 +
+ src/basic/parse-printf-format.c | 273 ++++++++++++++++++++++++++++++++++++++++
+ src/basic/parse-printf-format.h |  57 +++++++++
+ src/basic/stdio-util.h          |   2 +-
+ src/journal/journal-send.c      |   2 +-
+ 6 files changed, 338 insertions(+), 2 deletions(-)
+ create mode 100644 src/basic/parse-printf-format.c
+ create mode 100644 src/basic/parse-printf-format.h
+
+diff --git a/meson.build b/meson.build
+index e045b9224..8c16bc979 100644
+--- a/meson.build
++++ b/meson.build
+@@ -598,6 +598,7 @@ foreach header : ['crypt.h',
+                   'linux/btrfs.h',
+                   'linux/memfd.h',
+                   'linux/vm_sockets.h',
++                  'printf.h',
+                   'sys/auxv.h',
+                   'valgrind/memcheck.h',
+                   'valgrind/valgrind.h',
+diff --git a/src/basic/meson.build b/src/basic/meson.build
+index 31625b178..0c27528e7 100644
+--- a/src/basic/meson.build
++++ b/src/basic/meson.build
+@@ -302,6 +302,11 @@ foreach item : [['af',     af_list_txt,     'af',         ''],
+ endforeach
+ 
+ basic_sources += [missing_h] + generated_gperf_headers
++
++if conf.get('HAVE_PRINTF_H') != 1
++        basic_sources += [files('parse-printf-format.c')]
++endif
++
+ basic_gcrypt_sources = files(
+         'gcrypt-util.c',
+         'gcrypt-util.h')
+diff --git a/src/basic/parse-printf-format.c b/src/basic/parse-printf-format.c
+new file mode 100644
+index 000000000..49437e544
+--- /dev/null
++++ b/src/basic/parse-printf-format.c
+@@ -0,0 +1,273 @@
++/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
++
++/***
++  This file is part of systemd.
++
++  Copyright 2014 Emil Renner Berthing <systemd@esmil.dk>
++
++  With parts from the musl C library
++  Copyright 2005-2014 Rich Felker, et al.
++
++  systemd is free software; you can redistribute it and/or modify it
++  under the terms of the GNU Lesser General Public License as published by
++  the Free Software Foundation; either version 2.1 of the License, or
++  (at your option) any later version.
++
++  systemd is distributed in the hope that it will be useful, but
++  WITHOUT ANY WARRANTY; without even the implied warranty of
++  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++  Lesser General Public License for more details.
++
++  You should have received a copy of the GNU Lesser General Public License
++  along with systemd; If not, see <http://www.gnu.org/licenses/>.
++***/
++
++#include <stddef.h>
++#include <string.h>
++
++#include "parse-printf-format.h"
++
++static const char *consume_nonarg(const char *fmt)
++{
++        do {
++                if (*fmt == '\0')
++                        return fmt;
++        } while (*fmt++ != '%');
++        return fmt;
++}
++
++static const char *consume_num(const char *fmt)
++{
++        for (;*fmt >= '0' && *fmt <= '9'; fmt++)
++                /* do nothing */;
++        return fmt;
++}
++
++static const char *consume_argn(const char *fmt, size_t *arg)
++{
++        const char *p = fmt;
++        size_t val = 0;
++
++        if (*p < '1' || *p > '9')
++                return fmt;
++        do {
++                val = 10*val + (*p++ - '0');
++        } while (*p >= '0' && *p <= '9');
++
++        if (*p != '$')
++                return fmt;
++        *arg = val;
++        return p+1;
++}
++
++static const char *consume_flags(const char *fmt)
++{
++        while (1) {
++                switch (*fmt) {
++                case '#':
++                case '0':
++                case '-':
++                case ' ':
++                case '+':
++                case '\'':
++                case 'I':
++                        fmt++;
++                        continue;
++                }
++                return fmt;
++        }
++}
++
++enum state {
++        BARE,
++        LPRE,
++        LLPRE,
++        HPRE,
++        HHPRE,
++        BIGLPRE,
++        ZTPRE,
++        JPRE,
++        STOP
++};
++
++enum type {
++        NONE,
++        PTR,
++        INT,
++        UINT,
++        ULLONG,
++        LONG,
++        ULONG,
++        SHORT,
++        USHORT,
++        CHAR,
++        UCHAR,
++        LLONG,
++        SIZET,
++        IMAX,
++        UMAX,
++        PDIFF,
++        UIPTR,
++        DBL,
++        LDBL,
++        MAXTYPE
++};
++
++static const short pa_types[MAXTYPE] = {
++        [NONE]   = PA_INT,
++        [PTR]    = PA_POINTER,
++        [INT]    = PA_INT,
++        [UINT]   = PA_INT,
++        [ULLONG] = PA_INT | PA_FLAG_LONG_LONG,
++        [LONG]   = PA_INT | PA_FLAG_LONG,
++        [ULONG]  = PA_INT | PA_FLAG_LONG,
++        [SHORT]  = PA_INT | PA_FLAG_SHORT,
++        [USHORT] = PA_INT | PA_FLAG_SHORT,
++        [CHAR]   = PA_CHAR,
++        [UCHAR]  = PA_CHAR,
++        [LLONG]  = PA_INT | PA_FLAG_LONG_LONG,
++        [SIZET]  = PA_INT | PA_FLAG_LONG,
++        [IMAX]   = PA_INT | PA_FLAG_LONG_LONG,
++        [UMAX]   = PA_INT | PA_FLAG_LONG_LONG,
++        [PDIFF]  = PA_INT | PA_FLAG_LONG_LONG,
++        [UIPTR]  = PA_INT | PA_FLAG_LONG,
++        [DBL]    = PA_DOUBLE,
++        [LDBL]   = PA_DOUBLE | PA_FLAG_LONG_DOUBLE
++};
++
++#define S(x) [(x)-'A']
++#define E(x) (STOP + (x))
++
++static const unsigned char states[]['z'-'A'+1] = {
++        { /* 0: bare types */
++                S('d') = E(INT), S('i') = E(INT),
++                S('o') = E(UINT),S('u') = E(UINT),S('x') = E(UINT), S('X') = E(UINT),
++                S('e') = E(DBL), S('f') = E(DBL), S('g') = E(DBL),  S('a') = E(DBL),
++                S('E') = E(DBL), S('F') = E(DBL), S('G') = E(DBL),  S('A') = E(DBL),
++                S('c') = E(CHAR),S('C') = E(INT),
++                S('s') = E(PTR), S('S') = E(PTR), S('p') = E(UIPTR),S('n') = E(PTR),
++                S('m') = E(NONE),
++                S('l') = LPRE,   S('h') = HPRE, S('L') = BIGLPRE,
++                S('z') = ZTPRE,  S('j') = JPRE, S('t') = ZTPRE
++        }, { /* 1: l-prefixed */
++                S('d') = E(LONG), S('i') = E(LONG),
++                S('o') = E(ULONG),S('u') = E(ULONG),S('x') = E(ULONG),S('X') = E(ULONG),
++                S('e') = E(DBL),  S('f') = E(DBL),  S('g') = E(DBL),  S('a') = E(DBL),
++                S('E') = E(DBL),  S('F') = E(DBL),  S('G') = E(DBL),  S('A') = E(DBL),
++                S('c') = E(INT),  S('s') = E(PTR),  S('n') = E(PTR),
++                S('l') = LLPRE
++        }, { /* 2: ll-prefixed */
++                S('d') = E(LLONG), S('i') = E(LLONG),
++                S('o') = E(ULLONG),S('u') = E(ULLONG),
++                S('x') = E(ULLONG),S('X') = E(ULLONG),
++                S('n') = E(PTR)
++        }, { /* 3: h-prefixed */
++                S('d') = E(SHORT), S('i') = E(SHORT),
++                S('o') = E(USHORT),S('u') = E(USHORT),
++                S('x') = E(USHORT),S('X') = E(USHORT),
++                S('n') = E(PTR),
++                S('h') = HHPRE
++        }, { /* 4: hh-prefixed */
++                S('d') = E(CHAR), S('i') = E(CHAR),
++                S('o') = E(UCHAR),S('u') = E(UCHAR),
++                S('x') = E(UCHAR),S('X') = E(UCHAR),
++                S('n') = E(PTR)
++        }, { /* 5: L-prefixed */
++                S('e') = E(LDBL),S('f') = E(LDBL),S('g') = E(LDBL), S('a') = E(LDBL),
++                S('E') = E(LDBL),S('F') = E(LDBL),S('G') = E(LDBL), S('A') = E(LDBL),
++                S('n') = E(PTR)
++        }, { /* 6: z- or t-prefixed (assumed to be same size) */
++                S('d') = E(PDIFF),S('i') = E(PDIFF),
++                S('o') = E(SIZET),S('u') = E(SIZET),
++                S('x') = E(SIZET),S('X') = E(SIZET),
++                S('n') = E(PTR)
++        }, { /* 7: j-prefixed */
++                S('d') = E(IMAX), S('i') = E(IMAX),
++                S('o') = E(UMAX), S('u') = E(UMAX),
++                S('x') = E(UMAX), S('X') = E(UMAX),
++                S('n') = E(PTR)
++        }
++};
++
++size_t parse_printf_format(const char *fmt, size_t n, int *types)
++{
++        size_t i = 0;
++        size_t last = 0;
++
++        memset(types, 0, n);
++
++        while (1) {
++                size_t arg;
++                unsigned int state;
++
++                fmt = consume_nonarg(fmt);
++                if (*fmt == '\0')
++                        break;
++                if (*fmt == '%') {
++                        fmt++;
++                        continue;
++                }
++                arg = 0;
++                fmt = consume_argn(fmt, &arg);
++                /* flags */
++                fmt = consume_flags(fmt);
++                /* width */
++                if (*fmt == '*') {
++                        size_t warg = 0;
++                        fmt = consume_argn(fmt+1, &warg);
++                        if (warg == 0)
++                                warg = ++i;
++                        if (warg > last)
++                                last = warg;
++                        if (warg <= n && types[warg-1] == NONE)
++                                types[warg-1] = INT;
++                } else
++                        fmt = consume_num(fmt);
++                /* precision */
++                if (*fmt == '.') {
++                        fmt++;
++                        if (*fmt == '*') {
++                                size_t parg = 0;
++                                fmt = consume_argn(fmt+1, &parg);
++                                if (parg == 0)
++                                        parg = ++i;
++                                if (parg > last)
++                                        last = parg;
++                                if (parg <= n && types[parg-1] == NONE)
++                                        types[parg-1] = INT;
++                        } else {
++                                if (*fmt == '-')
++                                        fmt++;
++                                fmt = consume_num(fmt);
++                        }
++                }
++                /* length modifier and conversion specifier */
++                state = BARE;
++                do {
++                        unsigned char c = *fmt++;
++
++                        if (c < 'A' || c > 'z')
++                                continue;
++                        state = states[state]S(c);
++                        if (state == 0)
++                                continue;
++                } while (state < STOP);
++
++                if (state == E(NONE))
++                        continue;
++
++                if (arg == 0)
++                        arg = ++i;
++                if (arg > last)
++                        last = arg;
++                if (arg <= n)
++                        types[arg-1] = state - STOP;
++        }
++
++        if (last > n)
++                last = n;
++        for (i = 0; i < last; i++)
++                types[i] = pa_types[types[i]];
++
++        return last;
++}
+diff --git a/src/basic/parse-printf-format.h b/src/basic/parse-printf-format.h
+new file mode 100644
+index 000000000..47be7522d
+--- /dev/null
++++ b/src/basic/parse-printf-format.h
+@@ -0,0 +1,57 @@
++/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
++
++/***
++  This file is part of systemd.
++
++  Copyright 2014 Emil Renner Berthing <systemd@esmil.dk>
++
++  With parts from the GNU C Library
++  Copyright 1991-2014 Free Software Foundation, Inc.
++
++  systemd is free software; you can redistribute it and/or modify it
++  under the terms of the GNU Lesser General Public License as published by
++  the Free Software Foundation; either version 2.1 of the License, or
++  (at your option) any later version.
++
++  systemd is distributed in the hope that it will be useful, but
++  WITHOUT ANY WARRANTY; without even the implied warranty of
++  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++  Lesser General Public License for more details.
++
++  You should have received a copy of the GNU Lesser General Public License
++  along with systemd; If not, see <http://www.gnu.org/licenses/>.
++***/
++
++#pragma once
++
++#include "config.h"
++
++#if HAVE_PRINTF_H
++#include <printf.h>
++#else
++
++#include <stddef.h>
++
++enum {				/* C type: */
++  PA_INT,			/* int */
++  PA_CHAR,			/* int, cast to char */
++  PA_WCHAR,			/* wide char */
++  PA_STRING,			/* const char *, a '\0'-terminated string */
++  PA_WSTRING,			/* const wchar_t *, wide character string */
++  PA_POINTER,			/* void * */
++  PA_FLOAT,			/* float */
++  PA_DOUBLE,			/* double */
++  PA_LAST
++};
++
++/* Flag bits that can be set in a type returned by `parse_printf_format'.  */
++#define	PA_FLAG_MASK		0xff00
++#define	PA_FLAG_LONG_LONG	(1 << 8)
++#define	PA_FLAG_LONG_DOUBLE	PA_FLAG_LONG_LONG
++#define	PA_FLAG_LONG		(1 << 9)
++#define	PA_FLAG_SHORT		(1 << 10)
++#define	PA_FLAG_PTR		(1 << 11)
++
++size_t parse_printf_format(const char *fmt, size_t n, int *types);
++
++#endif /* HAVE_PRINTF_H */
+diff --git a/src/basic/stdio-util.h b/src/basic/stdio-util.h
+index 73c03274c..30192cd71 100644
+--- a/src/basic/stdio-util.h
++++ b/src/basic/stdio-util.h
+@@ -1,12 +1,12 @@
+ /* SPDX-License-Identifier: LGPL-2.1+ */
+ #pragma once
+ 
+-#include <printf.h>
+ #include <stdarg.h>
+ #include <stdio.h>
+ #include <sys/types.h>
+ 
+ #include "macro.h"
++#include "parse-printf-format.h"
+ 
+ #define snprintf_ok(buf, len, fmt, ...) \
+         ((size_t) snprintf(buf, len, fmt, __VA_ARGS__) < (len))
+diff --git a/src/journal/journal-send.c b/src/journal/journal-send.c
+index a0621524a..65bcbcd2e 100644
+--- a/src/journal/journal-send.c
++++ b/src/journal/journal-send.c
+@@ -2,7 +2,6 @@
+ 
+ #include <errno.h>
+ #include <fcntl.h>
+-#include <printf.h>
+ #include <stddef.h>
+ #include <sys/socket.h>
+ #include <sys/un.h>
+@@ -21,6 +20,7 @@
+ #include "stdio-util.h"
+ #include "string-util.h"
+ #include "util.h"
++#include "parse-printf-format.h"
+ 
+ #define SNDBUF_SIZE (8*1024*1024)
+ 
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0004-implment-systemd-sysv-install-for-OE.patch b/poky/meta/recipes-core/systemd/systemd/0004-implment-systemd-sysv-install-for-OE.patch
deleted file mode 100644
index 83fdb53..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0004-implment-systemd-sysv-install-for-OE.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 70d456fb21de2a80697fa364f08475339d6396c1 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 5 Sep 2015 06:31:47 +0000
-Subject: [PATCH 04/31] implment systemd-sysv-install for OE
-
-Use update-rc.d for enabling/disabling and status command
-to check the status of the sysv service
-
-Upstream-Status: Inappropriate [OE-Specific]
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/systemctl/systemd-sysv-install.SKELETON | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/src/systemctl/systemd-sysv-install.SKELETON b/src/systemctl/systemd-sysv-install.SKELETON
-index a53a3e622..5d877b06e 100755
---- a/src/systemctl/systemd-sysv-install.SKELETON
-+++ b/src/systemctl/systemd-sysv-install.SKELETON
-@@ -30,17 +30,17 @@ case "$1" in
-     enable)
-         # call the command to enable SysV init script $NAME here
-         # (consider optional $ROOT)
--        echo "IMPLEMENT ME: enabling SysV init.d script $NAME"
-+        update-rc.d -f $NAME defaults
-         ;;
-     disable)
-         # call the command to disable SysV init script $NAME here
-         # (consider optional $ROOT)
--        echo "IMPLEMENT ME: disabling SysV init.d script $NAME"
-+        update-rc.d -f $NAME remove
-         ;;
-     is-enabled)
-         # exit with 0 if $NAME is enabled, non-zero if it is disabled
-         # (consider optional $ROOT)
--        echo "IMPLEMENT ME: checking SysV init.d script $NAME"
-+        /etc/init.d/$NAME status
-         ;;
-     *)
-         usage ;;
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0004-rules-whitelist-hd-devices.patch b/poky/meta/recipes-core/systemd/systemd/0004-rules-whitelist-hd-devices.patch
new file mode 100644
index 0000000..7e37cbc
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0004-rules-whitelist-hd-devices.patch
@@ -0,0 +1,33 @@
+From 5d8128f3832fd11fd046d1d1ad86c4ee7bc1dff0 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 9 Nov 2016 19:41:13 -0800
+Subject: [PATCH 4/9] rules: whitelist hd* devices
+
+qemu by default emulates IDE and the linux-yocto kernel(s) use
+CONFIG_IDE instead of the more modern libsata, so disks appear as
+/dev/hd*. Patch rejected upstream because CONFIG_IDE is deprecated.
+
+Upstream-Status: Denied [https://github.com/systemd/systemd/pull/1276]
+
+Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ rules/60-persistent-storage.rules | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/rules/60-persistent-storage.rules b/rules/60-persistent-storage.rules
+index 8ddb7577c..811e948ad 100644
+--- a/rules/60-persistent-storage.rules
++++ b/rules/60-persistent-storage.rules
+@@ -7,7 +7,7 @@ ACTION=="remove", GOTO="persistent_storage_end"
+ ENV{UDEV_DISABLE_PERSISTENT_STORAGE_RULES_FLAG}=="1", GOTO="persistent_storage_end"
+ 
+ SUBSYSTEM!="block", GOTO="persistent_storage_end"
+-KERNEL!="loop*|mmcblk*[0-9]|msblk*[0-9]|mspblk*[0-9]|nvme*|sd*|sr*|vd*|xvd*|bcache*|cciss*|dasd*|ubd*|scm*|pmem*|nbd*", GOTO="persistent_storage_end"
++KERNEL!="loop*|mmcblk*[0-9]|msblk*[0-9]|mspblk*[0-9]|nvme*|sd*|sr*|vd*|xvd*|bcache*|cciss*|dasd*|ubd*|scm*|pmem*|nbd*|hd*", GOTO="persistent_storage_end"
+ 
+ # ignore partitions that span the entire disk
+ TEST=="whole_disk", GOTO="persistent_storage_end"
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0005-Make-root-s-home-directory-configurable.patch b/poky/meta/recipes-core/systemd/systemd/0005-Make-root-s-home-directory-configurable.patch
new file mode 100644
index 0000000..c137087
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0005-Make-root-s-home-directory-configurable.patch
@@ -0,0 +1,70 @@
+From 8b82663aeeedf9ca58e3b97116b4c4da5229e0f5 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Wed, 27 Jun 2018 16:46:45 +0800
+Subject: [PATCH 5/9] Make root's home directory configurable
+
+OpenEmbedded has a configurable home directory for root. Allow
+systemd to be built using its idea of what root's home directory
+should be.
+
+Upstream-Status: Denied
+Upstream wants to have a unified hierarchy where everyone is
+using the same root folder.
+https://github.com/systemd/systemd/issues/541
+
+Signed-off-by: Dan McGregor <dan.mcgregor@usask.ca>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ meson.build       | 7 +++++++
+ meson_options.txt | 2 ++
+ 2 files changed, 9 insertions(+)
+
+diff --git a/meson.build b/meson.build
+index 6d5edcb4e..323146fe1 100644
+--- a/meson.build
++++ b/meson.build
+@@ -89,6 +89,11 @@ if rootlibdir == ''
+         rootlibdir = join_paths(rootprefixdir, libdir.split('/')[-1])
+ endif
+ 
++roothomedir = get_option('roothomedir')
++if roothomedir == ''
++        roothomedir = '/root'
++endif
++
+ # Dirs of external packages
+ pkgconfigdatadir = join_paths(datadir, 'pkgconfig')
+ pkgconfiglibdir = join_paths(libdir, 'pkgconfig')
+@@ -210,6 +215,7 @@ conf.set_quoted('UDEVLIBEXECDIR',                             udevlibexecdir)
+ conf.set_quoted('POLKIT_AGENT_BINARY_PATH',                   join_paths(bindir, 'pkttyagent'))
+ conf.set_quoted('LIBDIR',                                     libdir)
+ conf.set_quoted('ROOTLIBDIR',                                 rootlibdir)
++conf.set_quoted('ROOTHOMEDIR',                                roothomedir)
+ conf.set_quoted('ROOTLIBEXECDIR',                             rootlibexecdir)
+ conf.set_quoted('BOOTLIBDIR',                                 bootlibdir)
+ conf.set_quoted('SYSTEMD_PULL_PATH',                          join_paths(rootlibexecdir, 'systemd-pull'))
+@@ -228,6 +234,7 @@ substs.set('prefix',                                          prefixdir)
+ substs.set('exec_prefix',                                     prefixdir)
+ substs.set('libdir',                                          libdir)
+ substs.set('rootlibdir',                                      rootlibdir)
++substs.set('roothomedir',                                     roothomedir)
+ substs.set('includedir',                                      includedir)
+ substs.set('pkgsysconfdir',                                   pkgsysconfdir)
+ substs.set('bindir',                                          bindir)
+diff --git a/meson_options.txt b/meson_options.txt
+index 16c1f2b2f..aa9a33368 100644
+--- a/meson_options.txt
++++ b/meson_options.txt
+@@ -9,6 +9,8 @@ option('rootlibdir', type : 'string',
+        description : '''[/usr]/lib/x86_64-linux-gnu or such''')
+ option('rootprefix', type : 'string',
+        description : '''override the root prefix''')
++option('roothomedir', type : 'string',
++       description : '''override the root home directory''')
+ option('link-udev-shared', type : 'boolean',
+        description : 'link systemd-udev and its helpers to libsystemd-shared.so')
+ option('link-systemctl-shared', type: 'boolean',
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0005-include-gshadow-only-if-ENABLE_GSHADOW-is-1.patch b/poky/meta/recipes-core/systemd/systemd/0005-include-gshadow-only-if-ENABLE_GSHADOW-is-1.patch
new file mode 100644
index 0000000..6d5faf5
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0005-include-gshadow-only-if-ENABLE_GSHADOW-is-1.patch
@@ -0,0 +1,29 @@
+From a2c4d46944892174930135672508389a04e191f0 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Fri, 29 Jun 2018 13:53:29 +0800
+Subject: [PATCH 05/19] include gshadow only if ENABLE_GSHADOW is 1
+
+Upstream-Status: Inappropriate [musl]
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/basic/user-util.h | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/src/basic/user-util.h b/src/basic/user-util.h
+index b74f16885..f9c1e29c4 100644
+--- a/src/basic/user-util.h
++++ b/src/basic/user-util.h
+@@ -2,7 +2,9 @@
+ #pragma once
+ 
+ #include <grp.h>
++#if ENABLE_GSHADOW
+ #include <gshadow.h>
++#endif
+ #include <pwd.h>
+ #include <shadow.h>
+ #include <stdbool.h>
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0005-rules-whitelist-hd-devices.patch b/poky/meta/recipes-core/systemd/systemd/0005-rules-whitelist-hd-devices.patch
deleted file mode 100644
index e4421c8..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0005-rules-whitelist-hd-devices.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 7b5b34993002b4418ba8a3c2ae661a7337fd8ed0 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 9 Nov 2016 19:41:13 -0800
-Subject: [PATCH 05/31] rules: whitelist hd* devices
-
-qemu by default emulates IDE and the linux-yocto kernel(s) use
-CONFIG_IDE instead of the more modern libsata, so disks appear as
-/dev/hd*. Patch rejected upstream because CONFIG_IDE is deprecated.
-
-Upstream-Status: Denied [https://github.com/systemd/systemd/pull/1276]
-
-Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- rules/60-persistent-storage.rules | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/rules/60-persistent-storage.rules b/rules/60-persistent-storage.rules
-index 0de8cf3a1..d3f58f153 100644
---- a/rules/60-persistent-storage.rules
-+++ b/rules/60-persistent-storage.rules
-@@ -7,7 +7,7 @@ ACTION=="remove", GOTO="persistent_storage_end"
- ENV{UDEV_DISABLE_PERSISTENT_STORAGE_RULES_FLAG}=="1", GOTO="persistent_storage_end"
- 
- SUBSYSTEM!="block", GOTO="persistent_storage_end"
--KERNEL!="loop*|mmcblk*[0-9]|msblk*[0-9]|mspblk*[0-9]|nvme*|sd*|sr*|vd*|xvd*|bcache*|cciss*|dasd*|ubd*|scm*|pmem*|nbd*", GOTO="persistent_storage_end"
-+KERNEL!="loop*|mmcblk*[0-9]|msblk*[0-9]|mspblk*[0-9]|nvme*|sd*|sr*|vd*|xvd*|bcache*|cciss*|dasd*|ubd*|scm*|pmem*|nbd*|hd*", GOTO="persistent_storage_end"
- 
- # ignore partitions that span the entire disk
- TEST=="whole_disk", GOTO="persistent_storage_end"
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0006-Make-root-s-home-directory-configurable.patch b/poky/meta/recipes-core/systemd/systemd/0006-Make-root-s-home-directory-configurable.patch
deleted file mode 100644
index 5ba9661..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0006-Make-root-s-home-directory-configurable.patch
+++ /dev/null
@@ -1,78 +0,0 @@
-From 9d63227420f0c4f093c1c2066eafe2b6152070cf Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Fri, 23 Feb 2018 13:47:37 +0800
-Subject: [PATCH 06/31] Make root's home directory configurable
-
-OpenEmbedded has a configurable home directory for root. Allow
-systemd to be built using its idea of what root's home directory
-should be.
-
-Upstream-Status: Denied
-Upstream wants to have a unified hierarchy where everyone is
-using the same root folder.
-https://github.com/systemd/systemd/issues/541
-
-Signed-off-by: Dan McGregor <dan.mcgregor@usask.ca>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- meson.build       | 8 ++++++++
- meson_options.txt | 2 ++
- 2 files changed, 10 insertions(+)
-
-diff --git a/meson.build b/meson.build
-index 7347ea880..918101d6b 100644
---- a/meson.build
-+++ b/meson.build
-@@ -94,6 +94,11 @@ if rootlibdir == ''
-         rootlibdir = join_paths(rootprefixdir, libdir.split('/')[-1])
- endif
- 
-+roothomedir = get_option('roothomedir')
-+if roothomedir == ''
-+        roothomedir = '/root'
-+endif
-+
- # Dirs of external packages
- pkgconfigdatadir = join_paths(datadir, 'pkgconfig')
- pkgconfiglibdir = join_paths(libdir, 'pkgconfig')
-@@ -205,6 +210,7 @@ conf.set_quoted('UDEVLIBEXECDIR',                             udevlibexecdir)
- conf.set_quoted('POLKIT_AGENT_BINARY_PATH',                   join_paths(bindir, 'pkttyagent'))
- conf.set_quoted('LIBDIR',                                     libdir)
- conf.set_quoted('ROOTLIBDIR',                                 rootlibdir)
-+conf.set_quoted('ROOTHOMEDIR',                                roothomedir)
- conf.set_quoted('ROOTLIBEXECDIR',                             rootlibexecdir)
- conf.set_quoted('BOOTLIBDIR',                                 bootlibdir)
- conf.set_quoted('SYSTEMD_PULL_PATH',                          join_paths(rootlibexecdir, 'systemd-pull'))
-@@ -221,6 +227,7 @@ substs.set('prefix',                                          prefixdir)
- substs.set('exec_prefix',                                     prefixdir)
- substs.set('libdir',                                          libdir)
- substs.set('rootlibdir',                                      rootlibdir)
-+substs.set('roothomedir',                                     roothomedir)
- substs.set('includedir',                                      includedir)
- substs.set('pkgsysconfdir',                                   pkgsysconfdir)
- substs.set('bindir',                                          bindir)
-@@ -2705,6 +2712,7 @@ status = [
-         'include directory:                 @0@'.format(includedir),
-         'lib directory:                     @0@'.format(libdir),
-         'rootlib directory:                 @0@'.format(rootlibdir),
-+        'roothome directory:                @0@'.format(roothomedir),
-         'SysV init scripts:                 @0@'.format(sysvinit_path),
-         'SysV rc?.d directories:            @0@'.format(sysvrcnd_path),
-         'PAM modules directory:             @0@'.format(pamlibdir),
-diff --git a/meson_options.txt b/meson_options.txt
-index 39822d6cd..0b24f0e0f 100644
---- a/meson_options.txt
-+++ b/meson_options.txt
-@@ -22,6 +22,8 @@ option('rootlibdir', type : 'string',
-        description : '''[/usr]/lib/x86_64-linux-gnu or such''')
- option('rootprefix', type : 'string',
-        description : '''override the root prefix''')
-+option('roothomedir', type : 'string',
-+       description : '''override the root home directory''')
- option('link-udev-shared', type : 'boolean',
-        description : 'link systemd-udev and its helpers to libsystemd-shared.so')
- 
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0006-remove-nobody-user-group-checking.patch b/poky/meta/recipes-core/systemd/systemd/0006-remove-nobody-user-group-checking.patch
new file mode 100644
index 0000000..eb6eb8b
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0006-remove-nobody-user-group-checking.patch
@@ -0,0 +1,63 @@
+From 5199ae5dec9b8a9c9e20477d5090f1732735fbe2 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Thu, 28 Jun 2018 09:38:12 +0800
+Subject: [PATCH 6/9] remove nobody user/group checking
+
+Upstream-Status: Inappropriate [OE Specific]
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ meson.build | 37 -------------------------------------
+ 1 file changed, 37 deletions(-)
+
+diff --git a/meson.build b/meson.build
+index 323146fe1..3bb087fef 100644
+--- a/meson.build
++++ b/meson.build
+@@ -681,43 +681,6 @@ substs.set('containeruidbasemax', container_uid_base_max)
+ nobody_user = get_option('nobody-user')
+ nobody_group = get_option('nobody-group')
+ 
+-getent_result = run_command('getent', 'passwd', '65534')
+-if getent_result.returncode() == 0
+-        name = getent_result.stdout().split(':')[0]
+-        if name != nobody_user
+-                warning('\n' +
+-                        'The local user with the UID 65534 does not match the configured user name "@0@" of the nobody user (its name is @1@).\n'.format(nobody_user, name) +
+-                        'Your build will result in an user table setup that is incompatible with the local system.')
+-        endif
+-endif
+-id_result = run_command('id', '-u', nobody_user)
+-if id_result.returncode() == 0
+-        id = id_result.stdout().to_int()
+-        if id != 65534
+-                warning('\n' +
+-                        'The local user with the configured user name "@0@" of the nobody user does not have UID 65534 (it has @1@).\n'.format(nobody_user, id) +
+-                        'Your build will result in an user table setup that is incompatible with the local system.')
+-        endif
+-endif
+-
+-getent_result = run_command('getent', 'group', '65534')
+-if getent_result.returncode() == 0
+-        name = getent_result.stdout().split(':')[0]
+-        if name != nobody_group
+-                warning('\n' +
+-                        'The local group with the GID 65534 does not match the configured group name "@0@" of the nobody group (its name is @1@).\n'.format(nobody_group, name) +
+-                        'Your build will result in an group table setup that is incompatible with the local system.')
+-        endif
+-endif
+-id_result = run_command('id', '-g', nobody_group)
+-if id_result.returncode() == 0
+-        id = id_result.stdout().to_int()
+-        if id != 65534
+-                warning('\n' +
+-                        'The local group with the configured group name "@0@" of the nobody group does not have UID 65534 (it has @1@).\n'.format(nobody_group, id) +
+-                        'Your build will result in an group table setup that is incompatible with the local system.')
+-        endif
+-endif
+ if nobody_user != nobody_group and not (nobody_user == 'nobody' and nobody_group == 'nogroup')
+         warning('\n' +
+                 'The configured user name "@0@" and group name "@0@" of the nobody user/group are not equivalent.\n'.format(nobody_user, nobody_group) +
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0006-src-basic-missing.h-check-for-missing-strndupa.patch b/poky/meta/recipes-core/systemd/systemd/0006-src-basic-missing.h-check-for-missing-strndupa.patch
new file mode 100644
index 0000000..107a794
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0006-src-basic-missing.h-check-for-missing-strndupa.patch
@@ -0,0 +1,118 @@
+From 03fd19fc87573276e0d359260c8fe591f5f0216a Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Fri, 29 Jun 2018 16:34:50 +0800
+Subject: [PATCH 06/19] src/basic/missing.h: check for missing strndupa
+
+include missing.h  for definition of strndupa
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ meson.build             |  1 +
+ src/basic/missing.h     | 11 +++++++++++
+ src/basic/mkdir.c       |  1 +
+ src/basic/pager.c       |  1 +
+ src/basic/parse-util.c  |  1 +
+ src/basic/procfs-util.c |  1 +
+ src/shared/uid-range.c  |  1 +
+ 7 files changed, 17 insertions(+)
+
+diff --git a/meson.build b/meson.build
+index 8c16bc979..a734a295c 100644
+--- a/meson.build
++++ b/meson.build
+@@ -503,6 +503,7 @@ foreach ident : [
+                                  #include <unistd.h>'''],
+         ['explicit_bzero' ,   '''#include <string.h>'''],
+         ['reallocarray',      '''#include <malloc.h>'''],
++        ['strndupa' ,         '''#include <string.h>'''],
+ ]
+ 
+         have = cc.has_function(ident[0], prefix : ident[1], args : '-D_GNU_SOURCE')
+diff --git a/src/basic/missing.h b/src/basic/missing.h
+index 0e33abb9f..02397f1b6 100644
+--- a/src/basic/missing.h
++++ b/src/basic/missing.h
+@@ -1184,6 +1184,17 @@ struct input_mask {
+ typedef int32_t key_serial_t;
+ #endif
+ 
++#if ! HAVE_STRNDUPA
++#define strndupa(s, n) \
++  ({ \
++    const char *__old = (s); \
++    size_t __len = strnlen(__old, (n)); \
++    char *__new = (char *)alloca(__len + 1); \
++    __new[__len] = '\0'; \
++    (char *)memcpy(__new, __old, __len); \
++  })
++#endif
++
+ #ifndef KEYCTL_JOIN_SESSION_KEYRING
+ #define KEYCTL_JOIN_SESSION_KEYRING 1
+ #endif
+diff --git a/src/basic/mkdir.c b/src/basic/mkdir.c
+index 6ab1b4422..77c3e0863 100644
+--- a/src/basic/mkdir.c
++++ b/src/basic/mkdir.c
+@@ -13,6 +13,7 @@
+ #include "stat-util.h"
+ #include "stdio-util.h"
+ #include "user-util.h"
++#include "missing.h"
+ 
+ int mkdir_safe_internal(const char *path, mode_t mode, uid_t uid, gid_t gid, MkdirFlags flags, mkdir_func_t _mkdir) {
+         struct stat st;
+diff --git a/src/basic/pager.c b/src/basic/pager.c
+index f24126111..8223bff02 100644
+--- a/src/basic/pager.c
++++ b/src/basic/pager.c
+@@ -21,6 +21,7 @@
+ #include "string-util.h"
+ #include "strv.h"
+ #include "terminal-util.h"
++#include "missing.h"
+ 
+ static pid_t pager_pid = 0;
+ 
+diff --git a/src/basic/parse-util.c b/src/basic/parse-util.c
+index 6becf8587..52576f536 100644
+--- a/src/basic/parse-util.c
++++ b/src/basic/parse-util.c
+@@ -17,6 +17,7 @@
+ #include "parse-util.h"
+ #include "process-util.h"
+ #include "string-util.h"
++#include "missing.h"
+ 
+ int parse_boolean(const char *v) {
+         assert(v);
+diff --git a/src/basic/procfs-util.c b/src/basic/procfs-util.c
+index a159e344b..ebc427d6b 100644
+--- a/src/basic/procfs-util.c
++++ b/src/basic/procfs-util.c
+@@ -11,6 +11,7 @@
+ #include "procfs-util.h"
+ #include "stdio-util.h"
+ #include "string-util.h"
++#include "missing.h"
+ 
+ int procfs_tasks_get_limit(uint64_t *ret) {
+         _cleanup_free_ char *value = NULL;
+diff --git a/src/shared/uid-range.c b/src/shared/uid-range.c
+index 434ce6ff4..37093ab7b 100644
+--- a/src/shared/uid-range.c
++++ b/src/shared/uid-range.c
+@@ -8,6 +8,7 @@
+ #include "macro.h"
+ #include "uid-range.h"
+ #include "user-util.h"
++#include "missing.h"
+ 
+ static bool uid_range_intersect(UidRange *range, uid_t start, uid_t nr) {
+         assert(range);
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0007-Include-netinet-if_ether.h.patch b/poky/meta/recipes-core/systemd/systemd/0007-Include-netinet-if_ether.h.patch
new file mode 100644
index 0000000..2df8cf9
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0007-Include-netinet-if_ether.h.patch
@@ -0,0 +1,96 @@
+From aab90d0dfa934d33879eaec1a878e93b201d33f1 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Fri, 29 Jun 2018 16:44:43 +0800
+Subject: [PATCH 07/19] Include netinet/if_ether.h
+
+Fixes
+/path/to/systemd/recipe-sysroot/usr/include/netinet/if_ether.h:101:8: error: redefinition of 'struct ethhdr'
+ struct ethhdr {
+        ^~~~~~
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/libsystemd/sd-netlink/netlink-types.c | 1 +
+ src/network/netdev/tuntap.c               | 1 +
+ src/network/networkd-brvlan.c             | 1 +
+ src/udev/net/ethtool-util.c               | 1 +
+ src/udev/net/ethtool-util.h               | 1 +
+ src/udev/udev-builtin-net_setup_link.c    | 1 +
+ 6 files changed, 6 insertions(+)
+
+diff --git a/src/libsystemd/sd-netlink/netlink-types.c b/src/libsystemd/sd-netlink/netlink-types.c
+index c93fe9cb4..2013d06e1 100644
+--- a/src/libsystemd/sd-netlink/netlink-types.c
++++ b/src/libsystemd/sd-netlink/netlink-types.c
+@@ -3,6 +3,7 @@
+ #include <netinet/in.h>
+ #include <stdint.h>
+ #include <sys/socket.h>
++#include <netinet/if_ether.h>
+ #include <linux/netlink.h>
+ #include <linux/rtnetlink.h>
+ #include <linux/genetlink.h>
+diff --git a/src/network/netdev/tuntap.c b/src/network/netdev/tuntap.c
+index 21fb7ab06..0afe5170c 100644
+--- a/src/network/netdev/tuntap.c
++++ b/src/network/netdev/tuntap.c
+@@ -2,6 +2,7 @@
+ 
+ #include <errno.h>
+ #include <fcntl.h>
++#include <netinet/if_ether.h>
+ #include <linux/if_tun.h>
+ #include <net/if.h>
+ #include <netinet/if_ether.h>
+diff --git a/src/network/networkd-brvlan.c b/src/network/networkd-brvlan.c
+index 8e8a618e2..52d523a67 100644
+--- a/src/network/networkd-brvlan.c
++++ b/src/network/networkd-brvlan.c
+@@ -4,6 +4,7 @@
+ ***/
+ 
+ #include <netinet/in.h>
++#include <netinet/if_ether.h>
+ #include <linux/if_bridge.h>
+ #include <stdbool.h>
+ 
+diff --git a/src/udev/net/ethtool-util.c b/src/udev/net/ethtool-util.c
+index 4bb4216ac..5f7383483 100644
+--- a/src/udev/net/ethtool-util.c
++++ b/src/udev/net/ethtool-util.c
+@@ -1,5 +1,6 @@
+ /* SPDX-License-Identifier: LGPL-2.1+ */
+ 
++#include <netinet/if_ether.h>
+ #include <net/if.h>
+ #include <sys/ioctl.h>
+ #include <linux/ethtool.h>
+diff --git a/src/udev/net/ethtool-util.h b/src/udev/net/ethtool-util.h
+index 064bf4d2b..ee0d4fb2a 100644
+--- a/src/udev/net/ethtool-util.h
++++ b/src/udev/net/ethtool-util.h
+@@ -3,6 +3,7 @@
+ 
+ 
+ #include <macro.h>
++#include <netinet/if_ether.h>
+ #include <linux/ethtool.h>
+ 
+ #include "missing.h"
+diff --git a/src/udev/udev-builtin-net_setup_link.c b/src/udev/udev-builtin-net_setup_link.c
+index 8bed6399a..a3a96959b 100644
+--- a/src/udev/udev-builtin-net_setup_link.c
++++ b/src/udev/udev-builtin-net_setup_link.c
+@@ -1,5 +1,6 @@
+ /* SPDX-License-Identifier: LGPL-2.1+ */
+ 
++#include <netinet/if_ether.h>
+ #include "alloc-util.h"
+ #include "link-config.h"
+ #include "log.h"
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0007-Revert-rules-remove-firmware-loading-rules.patch b/poky/meta/recipes-core/systemd/systemd/0007-Revert-rules-remove-firmware-loading-rules.patch
deleted file mode 100644
index bb12d30..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0007-Revert-rules-remove-firmware-loading-rules.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From 35d6d384e83ac38077603611bb791969ef95fe68 Mon Sep 17 00:00:00 2001
-From: Jonathan Liu <net147@gmail.com>
-Date: Thu, 19 Mar 2015 15:01:29 +1100
-Subject: [PATCH 07/31] Revert "rules: remove firmware loading rules"
-
-This reverts commit 70e7d754ddb356fb1a2942b262f8cee9650e2a19.
-Userspace firmware loading support is needed for Linux < 3.7.
-
-Upstream-Status: Inappropriate [OE specific]
-
-Signed-off-by: Jonathan Liu <net147@gmail.com>
----
- rules/50-firmware.rules | 3 +++
- 1 file changed, 3 insertions(+)
- create mode 100644 rules/50-firmware.rules
-
-diff --git a/rules/50-firmware.rules b/rules/50-firmware.rules
-new file mode 100644
-index 000000000..f0ae68451
---- /dev/null
-+++ b/rules/50-firmware.rules
-@@ -0,0 +1,3 @@
-+# do not edit this file, it will be overwritten on update
-+
-+SUBSYSTEM=="firmware", ACTION=="add", RUN{builtin}="firmware"
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0007-rules-watch-metadata-changes-in-ide-devices.patch b/poky/meta/recipes-core/systemd/systemd/0007-rules-watch-metadata-changes-in-ide-devices.patch
new file mode 100644
index 0000000..a5f65e6
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0007-rules-watch-metadata-changes-in-ide-devices.patch
@@ -0,0 +1,43 @@
+From 9302b72e5e69512aaa7106197b00c55baeb35b3c Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Fri, 17 Nov 2017 09:46:00 +0800
+Subject: [PATCH 7/9] rules: watch metadata changes in ide devices
+
+Formatting IDE storage does not trigger "change" uevents. As a result
+clients using udev API don't get any updates afterwards and get outdated
+information about the device.
+...
+root@qemux86-64:~# mkfs.ext4 -F /dev/hda1
+Creating filesystem with 262144 4k blocks and 65536 inodes
+Filesystem UUID: 98791eb2-2bf3-47ad-b4d8-4cf7e914eee2
+
+root@qemux86-64:~# ls /dev/disk/by-uuid/98791eb2-2bf3-47ad-b4d8-4cf7e914eee2
+ls: cannot access '/dev/disk/by-uuid/98791eb2-2bf3-47ad-b4d8-4cf7e914eee2': No such file or directory
+...
+Include hd* in a match for watch option assignment.
+
+Upstream-Status: Denied
+
+qemu by default emulates IDE and the linux-yocto kernel(s) use
+CONFIG_IDE instead of the more modern libsata, so disks appear as
+/dev/hd*. A similar patch rejected by upstream because CONFIG_IDE
+is deprecated.
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ rules/60-block.rules | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/rules/60-block.rules b/rules/60-block.rules
+index 343fc06f8..b5237dac4 100644
+--- a/rules/60-block.rules
++++ b/rules/60-block.rules
+@@ -8,4 +8,4 @@ ACTION=="add", SUBSYSTEM=="module", KERNEL=="block", ATTR{parameters/events_dfl_
+ ACTION=="change", SUBSYSTEM=="scsi", ENV{DEVTYPE}=="scsi_device", TEST=="block", ATTR{block/*/uevent}="change"
+ 
+ # watch metadata changes, caused by tools closing the device node which was opened for writing
+-ACTION!="remove", SUBSYSTEM=="block", KERNEL=="loop*|nvme*|sd*|vd*|xvd*|pmem*|mmcblk*", OPTIONS+="watch"
++ACTION!="remove", SUBSYSTEM=="block", KERNEL=="loop*|nvme*|sd*|vd*|xvd*|pmem*|mmcblk*|hd*", OPTIONS+="watch"
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0008-Do-not-enable-nss-tests-if-nss-systemd-is-not-enable.patch b/poky/meta/recipes-core/systemd/systemd/0008-Do-not-enable-nss-tests-if-nss-systemd-is-not-enable.patch
new file mode 100644
index 0000000..abecdc7
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0008-Do-not-enable-nss-tests-if-nss-systemd-is-not-enable.patch
@@ -0,0 +1,29 @@
+From b6ba596fd1313a162cdc2eb88161dcf24d19ede7 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Thu, 28 Jun 2018 10:10:02 +0800
+Subject: [PATCH 8/9] Do not enable nss tests if nss-systemd is not enabled
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/test/meson.build | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/test/meson.build b/src/test/meson.build
+index 7da7e3a22..7b7c257ff 100644
+--- a/src/test/meson.build
++++ b/src/test/meson.build
+@@ -645,7 +645,7 @@ tests += [
+         [['src/test/test-nss.c'],
+          [],
+          [libdl],
+-         '', 'manual'],
++         'ENABLE_NSS_SYSTEMD', 'manual'],
+ 
+         [['src/test/test-umount.c',
+           'src/core/mount-setup.c',
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0008-Revert-udev-remove-userspace-firmware-loading-suppor.patch b/poky/meta/recipes-core/systemd/systemd/0008-Revert-udev-remove-userspace-firmware-loading-suppor.patch
deleted file mode 100644
index 15d7e02..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0008-Revert-udev-remove-userspace-firmware-loading-suppor.patch
+++ /dev/null
@@ -1,377 +0,0 @@
-From 5cce7626f33e92f624ac06b613125813fb47d445 Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Wed, 28 Feb 2018 21:05:39 -0800
-Subject: [PATCH 08/31] Revert "udev: remove userspace firmware loading
- support"
-
-This reverts commit be2ea723b1d023b3d385d3b791ee4607cbfb20ca.
-Userspace firmware loading support is needed for Linux < 3.7.
-
-Upstream-Status: Inappropriate [OE specific]
-
-Signed-off-by: Jonathan Liu <net147@gmail.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- README                           |   4 +-
- TODO                             |   1 +
- meson.build                      |   9 +++
- meson_options.txt                |   2 +
- rules/meson.build                |   4 +
- src/udev/meson.build             |   4 +
- src/udev/udev-builtin-firmware.c | 154 +++++++++++++++++++++++++++++++++++++++
- src/udev/udev-builtin.c          |   3 +
- src/udev/udev.h                  |   6 ++
- src/udev/udevd.c                 |  12 +++
- 10 files changed, 197 insertions(+), 2 deletions(-)
- create mode 100644 src/udev/udev-builtin-firmware.c
-
-diff --git a/README b/README
-index 8807e5cfe..bfd7a35de 100644
---- a/README
-+++ b/README
-@@ -58,8 +58,8 @@ REQUIREMENTS:
-         Legacy hotplug slows down the system and confuses udev:
-           CONFIG_UEVENT_HELPER_PATH=""
- 
--        Userspace firmware loading is not supported and should
--        be disabled in the kernel:
-+        Userspace firmware loading is deprecated, will go away, and
-+        sometimes causes problems:
-           CONFIG_FW_LOADER_USER_HELPER=n
- 
-         Some udev rules and virtualization detection relies on it:
-diff --git a/TODO b/TODO
-index a77028c7b..39e72d7ec 100644
---- a/TODO
-+++ b/TODO
-@@ -783,6 +783,7 @@ Features:
- * initialize the hostname from the fs label of /, if /etc/hostname does not exist?
- 
- * udev:
-+  - remove src/udev/udev-builtin-firmware.c (CONFIG_FW_LOADER_USER_HELPER=n)
-   - move to LGPL
-   - kill scsi_id
-   - add trigger --subsystem-match=usb/usb_device device
-diff --git a/meson.build b/meson.build
-index 918101d6b..9c25022a4 100644
---- a/meson.build
-+++ b/meson.build
-@@ -72,6 +72,12 @@ conf.set10('HAVE_SYSV_COMPAT', have,
-            description : 'SysV init scripts and rcN.d links are supported')
- m4_defines += have ? ['-DHAVE_SYSV_COMPAT'] : []
- 
-+firmware_path = get_option('firmware-path')
-+have = firmware_path != ''
-+conf.set10('HAVE_FIRMWARE', have,
-+           description : 'Userspace firmware loading is supported')
-+m4_defines += have ? ['-DHAVE_FIRMWARE'] : []
-+
- # join_paths ignore the preceding arguments if an absolute component is
- # encountered, so this should canonicalize various paths when they are
- # absolute or relative.
-@@ -178,6 +184,7 @@ conf.set_quoted('SYSTEM_CONFIG_UNIT_PATH',                    join_paths(pkgsysc
- conf.set_quoted('SYSTEM_DATA_UNIT_PATH',                      systemunitdir)
- conf.set_quoted('SYSTEM_SYSVINIT_PATH',                       sysvinit_path)
- conf.set_quoted('SYSTEM_SYSVRCND_PATH',                       sysvrcnd_path)
-+conf.set_quoted('FIRMWARE_PATH',                              firmware_path)
- conf.set_quoted('RC_LOCAL_SCRIPT_PATH_START',                 get_option('rc-local'))
- conf.set_quoted('RC_LOCAL_SCRIPT_PATH_STOP',                  get_option('halt-local'))
- conf.set_quoted('USER_CONFIG_UNIT_PATH',                      join_paths(pkgsysconfdir, 'user'))
-@@ -258,6 +265,7 @@ substs.set('SYSTEMCTL',                                       join_paths(rootbin
- substs.set('RANDOM_SEED',                                     join_paths(randomseeddir, 'random-seed'))
- substs.set('SYSTEM_SYSVINIT_PATH',                            sysvinit_path)
- substs.set('SYSTEM_SYSVRCND_PATH',                            sysvrcnd_path)
-+substs.set('FIRMWARE_PATH',                                   firmware_path)
- substs.set('RC_LOCAL_SCRIPT_PATH_START',                      get_option('rc-local'))
- substs.set('RC_LOCAL_SCRIPT_PATH_STOP',                       get_option('halt-local'))
- 
-@@ -2715,6 +2723,7 @@ status = [
-         'roothome directory:                @0@'.format(roothomedir),
-         'SysV init scripts:                 @0@'.format(sysvinit_path),
-         'SysV rc?.d directories:            @0@'.format(sysvrcnd_path),
-+        'firmware path:                     @0@'.format(firmware_path),
-         'PAM modules directory:             @0@'.format(pamlibdir),
-         'PAM configuration directory:       @0@'.format(pamconfdir),
-         'RPM macros directory:              @0@'.format(rpmmacrosdir),
-diff --git a/meson_options.txt b/meson_options.txt
-index 0b24f0e0f..92d25fa35 100644
---- a/meson_options.txt
-+++ b/meson_options.txt
-@@ -108,6 +108,8 @@ option('tmpfiles', type : 'boolean',
-        description : 'support for tmpfiles.d')
- option('importd', type : 'combo', choices : ['auto', 'true', 'false'],
-        description : 'install the systemd-importd daemon')
-+option('firmware-path', type : 'string', value : '',
-+       description : 'Firmware search path')
- option('hwdb', type : 'boolean',
-        description : 'support for the hardware database')
- option('rfkill', type : 'boolean',
-diff --git a/rules/meson.build b/rules/meson.build
-index e253b9f59..5eee5fbca 100644
---- a/rules/meson.build
-+++ b/rules/meson.build
-@@ -41,6 +41,10 @@ rules = files('''
- install_data(rules,
-              install_dir : udevrulesdir)
- 
-+if conf.get('HAVE_FIRMWARE') == 1
-+        install_data('50-firmware.rules', install_dir : udevrulesdir)
-+endif
-+
- all_rules = rules
- 
- rules_in = '''
-diff --git a/src/udev/meson.build b/src/udev/meson.build
-index de2fd2d9c..b6b0ca006 100644
---- a/src/udev/meson.build
-+++ b/src/udev/meson.build
-@@ -67,6 +67,10 @@ if conf.get('HAVE_ACL') == 1
-                                  sd_login_c]
- endif
- 
-+if conf.get('HAVE_FIRMWARE') == 1
-+        libudev_core_sources += ['udev-builtin-firmware.c']
-+endif
-+
- ############################################################
- 
- generate_keyboard_keys_list = find_program('generate-keyboard-keys-list.sh')
-diff --git a/src/udev/udev-builtin-firmware.c b/src/udev/udev-builtin-firmware.c
-new file mode 100644
-index 000000000..bd8c2fb96
---- /dev/null
-+++ b/src/udev/udev-builtin-firmware.c
-@@ -0,0 +1,154 @@
-+/*
-+ * firmware - Kernel firmware loader
-+ *
-+ * Copyright (C) 2009 Piter Punk <piterpunk@slackware.com>
-+ * Copyright (C) 2009-2011 Kay Sievers <kay@vrfy.org>
-+ *
-+ * This program is free software; you can redistribute it and/or
-+ * modify it under the terms of the GNU General Public License as
-+ * published by the Free Software Foundation; either version 2 of the
-+ * License, or (at your option) any later version.
-+ *
-+ * This program is distributed in the hope that it will be useful, but
-+ * WITHOUT ANY WARRANTY; without even the implied warranty of
-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+ * General Public License for more details:*
-+ */
-+
-+#include <unistd.h>
-+#include <stdlib.h>
-+#include <string.h>
-+#include <stdio.h>
-+#include <getopt.h>
-+#include <errno.h>
-+#include <stdbool.h>
-+#include <sys/utsname.h>
-+#include <sys/stat.h>
-+
-+#include "udev.h"
-+
-+static bool set_loading(struct udev *udev, char *loadpath, const char *state) {
-+        FILE *ldfile;
-+
-+        ldfile = fopen(loadpath, "we");
-+        if (ldfile == NULL) {
-+                log_error("error: can not open '%s'", loadpath);
-+                return false;
-+        };
-+        fprintf(ldfile, "%s\n", state);
-+        fclose(ldfile);
-+        return true;
-+}
-+
-+static bool copy_firmware(struct udev *udev, const char *source, const char *target, size_t size) {
-+        char *buf;
-+        FILE *fsource = NULL, *ftarget = NULL;
-+        bool ret = false;
-+
-+        buf = malloc(size);
-+        if (buf == NULL) {
-+                log_error("No memory available to load firmware file");
-+                return false;
-+        }
-+
-+        log_debug("writing '%s' (%zi) to '%s'", source, size, target);
-+
-+        fsource = fopen(source, "re");
-+        if (fsource == NULL)
-+                goto exit;
-+        ftarget = fopen(target, "we");
-+        if (ftarget == NULL)
-+                goto exit;
-+        if (fread(buf, size, 1, fsource) != 1)
-+                goto exit;
-+        if (fwrite(buf, size, 1, ftarget) == 1)
-+                ret = true;
-+exit:
-+        if (ftarget != NULL)
-+                fclose(ftarget);
-+        if (fsource != NULL)
-+                fclose(fsource);
-+        free(buf);
-+        return ret;
-+}
-+
-+static int builtin_firmware(struct udev_device *dev, int argc, char *argv[], bool test) {
-+        struct udev *udev = udev_device_get_udev(dev);
-+        static const char *searchpath[] = { FIRMWARE_PATH };
-+        char loadpath[UTIL_PATH_SIZE];
-+        char datapath[UTIL_PATH_SIZE];
-+        char fwpath[UTIL_PATH_SIZE];
-+        const char *firmware;
-+        FILE *fwfile = NULL;
-+        struct utsname kernel;
-+        struct stat statbuf;
-+        unsigned int i;
-+        int rc = EXIT_SUCCESS;
-+
-+        firmware = udev_device_get_property_value(dev, "FIRMWARE");
-+        if (firmware == NULL) {
-+                log_error("firmware parameter missing");
-+                rc = EXIT_FAILURE;
-+                goto exit;
-+        }
-+
-+        /* lookup firmware file */
-+        uname(&kernel);
-+        for (i = 0; i < ELEMENTSOF(searchpath); i++) {
-+                strscpyl(fwpath, sizeof(fwpath), searchpath[i], kernel.release, "/", firmware, NULL);
-+                fwfile = fopen(fwpath, "re");
-+                if (fwfile != NULL)
-+                        break;
-+
-+                strscpyl(fwpath, sizeof(fwpath), searchpath[i], firmware, NULL);
-+                fwfile = fopen(fwpath, "re");
-+                if (fwfile != NULL)
-+                        break;
-+        }
-+
-+        strscpyl(loadpath, sizeof(loadpath), udev_device_get_syspath(dev), "/loading", NULL);
-+
-+        if (fwfile == NULL) {
-+                log_debug("did not find firmware file '%s'", firmware);
-+                rc = EXIT_FAILURE;
-+                /*
-+                 * Do not cancel the request in the initrd, the real root might have
-+                 * the firmware file and the 'coldplug' run in the real root will find
-+                 * this pending request and fulfill or cancel it.
-+                 * */
-+                if (!in_initrd())
-+                        set_loading(udev, loadpath, "-1");
-+                goto exit;
-+        }
-+
-+        if (stat(fwpath, &statbuf) < 0 || statbuf.st_size == 0) {
-+                if (!in_initrd())
-+                        set_loading(udev, loadpath, "-1");
-+                rc = EXIT_FAILURE;
-+                goto exit;
-+        }
-+
-+        if (!set_loading(udev, loadpath, "1"))
-+                goto exit;
-+
-+        strscpyl(datapath, sizeof(datapath), udev_device_get_syspath(dev), "/data", NULL);
-+        if (!copy_firmware(udev, fwpath, datapath, statbuf.st_size)) {
-+                log_error("error sending firmware '%s' to device", firmware);
-+                set_loading(udev, loadpath, "-1");
-+                rc = EXIT_FAILURE;
-+                goto exit;
-+        };
-+
-+        set_loading(udev, loadpath, "0");
-+exit:
-+        if (fwfile)
-+                fclose(fwfile);
-+        return rc;
-+}
-+
-+const struct udev_builtin udev_builtin_firmware = {
-+        .name = "firmware",
-+        .cmd = builtin_firmware,
-+        .help = "kernel firmware loader",
-+        .run_once = true,
-+};
-diff --git a/src/udev/udev-builtin.c b/src/udev/udev-builtin.c
-index db2b6874f..ccd88638c 100644
---- a/src/udev/udev-builtin.c
-+++ b/src/udev/udev-builtin.c
-@@ -32,6 +32,9 @@ static const struct udev_builtin *builtins[] = {
-         [UDEV_BUILTIN_BLKID] = &udev_builtin_blkid,
- #endif
-         [UDEV_BUILTIN_BTRFS] = &udev_builtin_btrfs,
-+#if HAVE_FIRMWARE
-+        [UDEV_BUILTIN_FIRMWARE] = &udev_builtin_firmware,
-+#endif
-         [UDEV_BUILTIN_HWDB] = &udev_builtin_hwdb,
-         [UDEV_BUILTIN_INPUT_ID] = &udev_builtin_input_id,
-         [UDEV_BUILTIN_KEYBOARD] = &udev_builtin_keyboard,
-diff --git a/src/udev/udev.h b/src/udev/udev.h
-index ea11c2d29..c47dd3d88 100644
---- a/src/udev/udev.h
-+++ b/src/udev/udev.h
-@@ -151,6 +151,9 @@ enum udev_builtin_cmd {
-         UDEV_BUILTIN_BLKID,
- #endif
-         UDEV_BUILTIN_BTRFS,
-+#if HAVE_FIRMWARE
-+        UDEV_BUILTIN_FIRMWARE,
-+#endif
-         UDEV_BUILTIN_HWDB,
-         UDEV_BUILTIN_INPUT_ID,
-         UDEV_BUILTIN_KEYBOARD,
-@@ -179,6 +182,9 @@ struct udev_builtin {
- extern const struct udev_builtin udev_builtin_blkid;
- #endif
- extern const struct udev_builtin udev_builtin_btrfs;
-+#if HAVE_FIRMWARE
-+extern const struct udev_builtin udev_builtin_firmware;
-+#endif
- extern const struct udev_builtin udev_builtin_hwdb;
- extern const struct udev_builtin udev_builtin_input_id;
- extern const struct udev_builtin udev_builtin_keyboard;
-diff --git a/src/udev/udevd.c b/src/udev/udevd.c
-index 5c757d513..2f3313007 100644
---- a/src/udev/udevd.c
-+++ b/src/udev/udevd.c
-@@ -127,6 +127,9 @@ struct event {
-         bool is_block;
-         sd_event_source *timeout_warning;
-         sd_event_source *timeout;
-+#if HAVE_FIRMWARE
-+        bool nodelay;
-+#endif
- };
- 
- static void event_queue_cleanup(Manager *manager, enum event_state type);
-@@ -609,6 +612,10 @@ static int event_queue_insert(Manager *manager, struct udev_device *dev) {
-         event->devnum = udev_device_get_devnum(dev);
-         event->is_block = streq("block", udev_device_get_subsystem(dev));
-         event->ifindex = udev_device_get_ifindex(dev);
-+#if HAVE_FIRMWARE
-+        if (streq(udev_device_get_subsystem(dev), "firmware"))
-+                event->nodelay = true;
-+#endif
- 
-         log_debug("seq %llu queued, '%s' '%s'", udev_device_get_seqnum(dev),
-              udev_device_get_action(dev), udev_device_get_subsystem(dev));
-@@ -692,6 +699,11 @@ static bool is_devpath_busy(Manager *manager, struct event *event) {
-                         return true;
-                 }
- 
-+#if HAVE_FIRMWARE
-+                /* allow to bypass the dependency tracking */
-+                if (event->nodelay)
-+                        continue;
-+#endif
-                 /* parent device event found */
-                 if (event->devpath[common] == '/') {
-                         event->delaying_seqnum = loop_event->seqnum;
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0008-don-t-fail-if-GLOB_BRACE-and-GLOB_ALTDIRFUNC-is-not-.patch b/poky/meta/recipes-core/systemd/systemd/0008-don-t-fail-if-GLOB_BRACE-and-GLOB_ALTDIRFUNC-is-not-.patch
new file mode 100644
index 0000000..bee5fb6
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0008-don-t-fail-if-GLOB_BRACE-and-GLOB_ALTDIRFUNC-is-not-.patch
@@ -0,0 +1,153 @@
+From 848e711d719a6d987bc7d14183e1c7b1f1c91c56 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Fri, 29 Jun 2018 17:10:29 +0800
+Subject: [PATCH 08/19] don't fail if GLOB_BRACE and GLOB_ALTDIRFUNC is not
+ defined
+
+If the standard library doesn't provide brace
+expansion users just won't get it.
+
+Dont use GNU GLOB extentions on non-glibc systems
+
+Conditionalize use of GLOB_ALTDIRFUNC
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/basic/glob-util.c     | 13 +++++++++++--
+ src/test/test-glob-util.c | 15 +++++++++++++++
+ src/tmpfiles/tmpfiles.c   | 10 ++++++++++
+ 3 files changed, 36 insertions(+), 2 deletions(-)
+
+diff --git a/src/basic/glob-util.c b/src/basic/glob-util.c
+index 9fac676f2..8adb9559e 100644
+--- a/src/basic/glob-util.c
++++ b/src/basic/glob-util.c
+@@ -10,6 +10,11 @@
+ #include "macro.h"
+ #include "path-util.h"
+ #include "strv.h"
++/* Don't fail if the standard library
++ * doesn't provide brace expansion */
++#ifndef GLOB_BRACE
++#define GLOB_BRACE 0
++#endif
+ 
+ static void closedir_wrapper(void* v) {
+         (void) closedir(v);
+@@ -18,6 +23,7 @@ static void closedir_wrapper(void* v) {
+ int safe_glob(const char *path, int flags, glob_t *pglob) {
+         int k;
+ 
++#ifdef GLOB_ALTDIRFUNC
+         /* We want to set GLOB_ALTDIRFUNC ourselves, don't allow it to be set. */
+         assert(!(flags & GLOB_ALTDIRFUNC));
+ 
+@@ -31,10 +37,13 @@ int safe_glob(const char *path, int flags, glob_t *pglob) {
+                 pglob->gl_lstat = lstat;
+         if (!pglob->gl_stat)
+                 pglob->gl_stat = stat;
+-
++#endif
+         errno = 0;
++#ifdef GLOB_ALTDIRFUNC
+         k = glob(path, flags | GLOB_ALTDIRFUNC, NULL, pglob);
+-
++#else
++        k = glob(path, flags, NULL, pglob);
++#endif
+         if (k == GLOB_NOMATCH)
+                 return -ENOENT;
+         if (k == GLOB_NOSPACE)
+diff --git a/src/test/test-glob-util.c b/src/test/test-glob-util.c
+index d78d6223c..f5943b26d 100644
+--- a/src/test/test-glob-util.c
++++ b/src/test/test-glob-util.c
+@@ -12,6 +12,11 @@
+ #include "glob-util.h"
+ #include "macro.h"
+ #include "rm-rf.h"
++/* Don't fail if the standard library
++ * doesn't provide brace expansion */
++#ifndef GLOB_BRACE
++#define GLOB_BRACE 0
++#endif
+ 
+ static void test_glob_exists(void) {
+         char name[] = "/tmp/test-glob_exists.XXXXXX";
+@@ -40,11 +45,13 @@ static void test_glob_no_dot(void) {
+         const char *fn;
+ 
+         _cleanup_globfree_ glob_t g = {
++#ifdef GLOB_ALTDIRFUNC
+                 .gl_closedir = closedir_wrapper,
+                 .gl_readdir = (struct dirent *(*)(void *)) readdir_no_dot,
+                 .gl_opendir = (void *(*)(const char *)) opendir,
+                 .gl_lstat = lstat,
+                 .gl_stat = stat,
++#endif
+         };
+ 
+         int r;
+@@ -52,11 +59,19 @@ static void test_glob_no_dot(void) {
+         assert_se(mkdtemp(template));
+ 
+         fn = strjoina(template, "/*");
++#ifdef GLOB_ALTDIRFUNC
+         r = glob(fn, GLOB_NOSORT|GLOB_BRACE|GLOB_ALTDIRFUNC, NULL, &g);
++#else
++        r = glob(fn, GLOB_NOSORT|GLOB_BRACE, NULL, &g);
++#endif
+         assert_se(r == GLOB_NOMATCH);
+ 
+         fn = strjoina(template, "/.*");
++#ifdef GLOB_ALTDIRFUNC
+         r = glob(fn, GLOB_NOSORT|GLOB_BRACE|GLOB_ALTDIRFUNC, NULL, &g);
++#else
++        r = glob(fn, GLOB_NOSORT|GLOB_BRACE, NULL, &g);
++#endif
+         assert_se(r == GLOB_NOMATCH);
+ 
+         (void) rm_rf(template, REMOVE_ROOT|REMOVE_PHYSICAL);
+diff --git a/src/tmpfiles/tmpfiles.c b/src/tmpfiles/tmpfiles.c
+index 927de35f3..5f0283da5 100644
+--- a/src/tmpfiles/tmpfiles.c
++++ b/src/tmpfiles/tmpfiles.c
+@@ -60,6 +60,12 @@
+ #include "user-util.h"
+ #include "util.h"
+ 
++/* Don't fail if the standard library
++ * doesn't provide brace expansion */
++#ifndef GLOB_BRACE
++#define GLOB_BRACE 0
++#endif
++
+ /* This reads all files listed in /etc/tmpfiles.d/?*.conf and creates
+  * them in the file system. This is intended to be used to create
+  * properly owned directories beneath /tmp, /var/tmp, /run, which are
+@@ -1345,7 +1351,9 @@ finish:
+ 
+ static int glob_item(Item *i, action_t action) {
+         _cleanup_globfree_ glob_t g = {
++#ifdef GLOB_ALTDIRFUNC
+                 .gl_opendir = (void *(*)(const char *)) opendir_nomod,
++#endif
+         };
+         int r = 0, k;
+         char **fn;
+@@ -1365,7 +1373,9 @@ static int glob_item(Item *i, action_t action) {
+ 
+ static int glob_item_recursively(Item *i, fdaction_t action) {
+         _cleanup_globfree_ glob_t g = {
++#ifdef GLOB_ALTDIRFUNC
+                 .gl_opendir = (void *(*)(const char *)) opendir_nomod,
++#endif
+         };
+         int r = 0, k;
+         char **fn;
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0009-add-missing-FTW_-macros-for-musl.patch b/poky/meta/recipes-core/systemd/systemd/0009-add-missing-FTW_-macros-for-musl.patch
new file mode 100644
index 0000000..95287cce
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0009-add-missing-FTW_-macros-for-musl.patch
@@ -0,0 +1,50 @@
+From acc2c08082795802011e3c5f8626d63210021489 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Wed, 28 Feb 2018 21:36:32 -0800
+Subject: [PATCH 09/19] add missing FTW_ macros for musl
+
+This is to avoid build failures like below for musl.
+
+  locale-util.c:296:24: error: 'FTW_STOP' undeclared
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/basic/missing.h | 20 ++++++++++++++++++++
+ 1 file changed, 20 insertions(+)
+
+diff --git a/src/basic/missing.h b/src/basic/missing.h
+index 02397f1b6..6dc750eba 100644
+--- a/src/basic/missing.h
++++ b/src/basic/missing.h
+@@ -189,6 +189,26 @@ struct sockaddr_vm {
+ #define BTRFS_QGROUP_LEVEL_SHIFT 48
+ #endif
+ 
++#ifndef FTW_ACTIONRETVAL
++#define FTW_ACTIONRETVAL 16
++#endif
++
++#ifndef FTW_CONTINUE
++#define FTW_CONTINUE 0
++#endif
++
++#ifndef FTW_STOP
++#define FTW_STOP 1
++#endif
++
++#ifndef FTW_SKIP_SUBTREE
++#define FTW_SKIP_SUBTREE 2
++#endif
++
++#ifndef FTW_SKIP_SIBLINGS
++#define FTW_SKIP_SIBLINGS 3
++#endif
++
+ #if ! HAVE_LINUX_BTRFS_H
+ #define BTRFS_IOC_QGROUP_ASSIGN _IOW(BTRFS_IOCTL_MAGIC, 41, \
+                                struct btrfs_ioctl_qgroup_assign_args)
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0009-nss-mymachines-Build-conditionally-when-ENABLE_MYHOS.patch b/poky/meta/recipes-core/systemd/systemd/0009-nss-mymachines-Build-conditionally-when-ENABLE_MYHOS.patch
new file mode 100644
index 0000000..a635fa9
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0009-nss-mymachines-Build-conditionally-when-ENABLE_MYHOS.patch
@@ -0,0 +1,43 @@
+From f9625b5f3fd5dac3f3591dbeeb24dc9d6fda790d Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Tue, 27 Feb 2018 12:56:21 +0800
+Subject: [PATCH 9/9] nss-mymachines: Build conditionally when
+ ENABLE_MYHOSTNAME is set
+
+Fixes build failures when building with --disable-myhostname
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ meson.build | 11 +++++++----
+ 1 file changed, 7 insertions(+), 4 deletions(-)
+
+diff --git a/meson.build b/meson.build
+index 3bb087fef..73bd70b0b 100644
+--- a/meson.build
++++ b/meson.build
+@@ -1371,12 +1371,15 @@ test_dlopen = executable(
+         link_with : [libbasic],
+         dependencies : [libdl])
+ 
+-foreach tuple : [['myhostname', 'ENABLE_MYHOSTNAME'],
+-                 ['systemd',    'ENABLE_NSS_SYSTEMD'],
+-                 ['mymachines', 'ENABLE_MACHINED'],
+-                 ['resolve',    'ENABLE_RESOLVE']]
++foreach tuple : [['myhostname', 'ENABLE_MYHOSTNAME',  ''],
++                 ['systemd',    'ENABLE_NSS_SYSTEMD', ''],
++                 ['mymachines', 'ENABLE_MACHINED',    'ENABLE_MYHOSTNAME'],
++                 ['resolve',    'ENABLE_RESOLVE',     '']]
+ 
+         condition = tuple[1] == '' or conf.get(tuple[1]) == 1
++        if tuple[2] != '' and condition
++                condition = conf.get(tuple[2]) == 1
++        endif
+         if condition
+                 module = tuple[0]
+ 
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0009-remove-duplicate-include-uchar.h.patch b/poky/meta/recipes-core/systemd/systemd/0009-remove-duplicate-include-uchar.h.patch
deleted file mode 100644
index 1b14369..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0009-remove-duplicate-include-uchar.h.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From ffdf9cb6ba0d932b81933d824f23a878c313a8d4 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 22 Feb 2016 05:59:01 +0000
-Subject: [PATCH 09/31] remove duplicate include uchar.h
-
-missing.h already includes it
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Upstream-Status: Pending
----
- src/basic/escape.h | 1 -
- src/basic/utf8.h   | 1 -
- 2 files changed, 2 deletions(-)
-
-diff --git a/src/basic/escape.h b/src/basic/escape.h
-index de89f43a8..9921ccbbd 100644
---- a/src/basic/escape.h
-+++ b/src/basic/escape.h
-@@ -24,7 +24,6 @@
- #include <stddef.h>
- #include <stdint.h>
- #include <sys/types.h>
--#include <uchar.h>
- 
- #include "string-util.h"
- #include "missing.h"
-diff --git a/src/basic/utf8.h b/src/basic/utf8.h
-index b0a7485ae..fa06d2906 100644
---- a/src/basic/utf8.h
-+++ b/src/basic/utf8.h
-@@ -23,7 +23,6 @@
- #include <stdbool.h>
- #include <stddef.h>
- #include <stdint.h>
--#include <uchar.h>
- 
- #include "macro.h"
- #include "missing.h"
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0010-check-for-uchar.h-in-meson.build.patch b/poky/meta/recipes-core/systemd/systemd/0010-check-for-uchar.h-in-meson.build.patch
deleted file mode 100644
index 9a44b54..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0010-check-for-uchar.h-in-meson.build.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-From ea4caaa1c6a6dc682bb04548ab05c5c73d0b45d6 Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Mon, 26 Feb 2018 15:34:52 +0800
-Subject: [PATCH 10/31] check for uchar.h in meson.build
-
-Use #if HAVE_UCHAR_H to include uchar.h conditionally.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Upstream-Status: Pending
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- meson.build         | 1 +
- src/basic/missing.h | 2 ++
- 2 files changed, 3 insertions(+)
-
-diff --git a/meson.build b/meson.build
-index 9c25022a4..94a16712b 100644
---- a/meson.build
-+++ b/meson.build
-@@ -623,6 +623,7 @@ foreach header : ['crypt.h',
-                   'sys/auxv.h',
-                   'valgrind/memcheck.h',
-                   'valgrind/valgrind.h',
-+                  'uchar.h',
-                  ]
- 
-         conf.set10('HAVE_' + header.underscorify().to_upper(),
-diff --git a/src/basic/missing.h b/src/basic/missing.h
-index 39c1fb700..84d6d9167 100644
---- a/src/basic/missing.h
-+++ b/src/basic/missing.h
-@@ -38,7 +38,9 @@
- #include <sys/resource.h>
- #include <sys/socket.h>
- #include <sys/syscall.h>
-+#if HAVE_UCHAR_H
- #include <uchar.h>
-+#endif
- #include <unistd.h>
- 
- #if HAVE_AUDIT
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0010-socket-util-don-t-fail-if-libc-doesn-t-support-IDN.patch b/poky/meta/recipes-core/systemd/systemd/0010-socket-util-don-t-fail-if-libc-doesn-t-support-IDN.patch
new file mode 100644
index 0000000..1654798
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0010-socket-util-don-t-fail-if-libc-doesn-t-support-IDN.patch
@@ -0,0 +1,38 @@
+From a0bd587300744dbb8e9cfbb043233670ce781c98 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Mon, 2 Jul 2018 13:22:41 +0800
+Subject: [PATCH 10/19] socket-util: don't fail if libc doesn't support IDN
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Emil Renner Berthing <systemd@esmil.dk>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/basic/socket-util.c | 10 ++++++++++
+ 1 file changed, 10 insertions(+)
+
+diff --git a/src/basic/socket-util.c b/src/basic/socket-util.c
+index a913102e1..0d0154805 100644
+--- a/src/basic/socket-util.c
++++ b/src/basic/socket-util.c
+@@ -32,6 +32,16 @@
+ #include "utf8.h"
+ #include "util.h"
+ 
++/* Don't fail if the standard library
++ * doesn't support IDN */
++#ifndef NI_IDN
++#define NI_IDN 0
++#endif
++
++#ifndef NI_IDN_USE_STD3_ASCII_RULES
++#define NI_IDN_USE_STD3_ASCII_RULES 0
++#endif
++
+ #if ENABLE_IDN
+ #  define IDN_FLAGS NI_IDN
+ #else
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0011-socket-util-don-t-fail-if-libc-doesn-t-support-IDN.patch b/poky/meta/recipes-core/systemd/systemd/0011-socket-util-don-t-fail-if-libc-doesn-t-support-IDN.patch
deleted file mode 100644
index b0923d1..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0011-socket-util-don-t-fail-if-libc-doesn-t-support-IDN.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From 60dd411e9756fc2b14c0e061ad803782b4aee874 Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Mon, 26 Feb 2018 15:46:05 +0800
-Subject: [PATCH 11/31] socket-util: don't fail if libc doesn't support IDN
-
-Upstream-Status: Pending
-
-Signed-off-by: Emil Renner Berthing <systemd@esmil.dk>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- src/basic/socket-util.c | 10 ++++++++++
- 1 file changed, 10 insertions(+)
-
-diff --git a/src/basic/socket-util.c b/src/basic/socket-util.c
-index 2c70cade1..67aedadd4 100644
---- a/src/basic/socket-util.c
-+++ b/src/basic/socket-util.c
-@@ -50,6 +50,16 @@
- #include "utf8.h"
- #include "util.h"
- 
-+/* Don't fail if the standard library
-+ * doesn't support IDN */
-+#ifndef NI_IDN
-+#define NI_IDN 0
-+#endif
-+
-+#ifndef NI_IDN_USE_STD3_ASCII_RULES
-+#define NI_IDN_USE_STD3_ASCII_RULES 0
-+#endif
-+
- #if ENABLE_IDN
- #  define IDN_FLAGS (NI_IDN|NI_IDN_USE_STD3_ASCII_RULES)
- #else
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0011-src-basic-missing.h-check-for-missing-__compar_fn_t-.patch b/poky/meta/recipes-core/systemd/systemd/0011-src-basic-missing.h-check-for-missing-__compar_fn_t-.patch
new file mode 100644
index 0000000..1a22ffd
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0011-src-basic-missing.h-check-for-missing-__compar_fn_t-.patch
@@ -0,0 +1,48 @@
+From 045f205fd21e5e380edf813de04fcfbf5a487219 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Mon, 2 Jul 2018 13:28:25 +0800
+Subject: [PATCH 11/19] src/basic/missing.h: check for missing __compar_fn_t
+ typedef
+
+include missing.h for missing __compar_fn_t
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/basic/missing.h | 5 +++++
+ src/basic/strbuf.c  | 1 +
+ 2 files changed, 6 insertions(+)
+
+diff --git a/src/basic/missing.h b/src/basic/missing.h
+index 6dc750eba..cd1cc109f 100644
+--- a/src/basic/missing.h
++++ b/src/basic/missing.h
+@@ -1179,6 +1179,11 @@ struct input_mask {
+ #define RENAME_NOREPLACE (1 << 0)
+ #endif
+ 
++#ifndef __COMPAR_FN_T
++#define __COMPAR_FN_T
++typedef int (*__compar_fn_t)(const void *, const void *);
++#endif
++
+ #ifndef KCMP_FILE
+ #define KCMP_FILE 0
+ #endif
+diff --git a/src/basic/strbuf.c b/src/basic/strbuf.c
+index e2ed776a0..4d3ebec4c 100644
+--- a/src/basic/strbuf.c
++++ b/src/basic/strbuf.c
+@@ -7,6 +7,7 @@
+ #include "alloc-util.h"
+ #include "strbuf.h"
+ #include "util.h"
++#include "missing.h"
+ 
+ /*
+  * Strbuf stores given strings in a single continuous allocated memory
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0012-fix-missing-of-__register_atfork-for-non-glibc-build.patch b/poky/meta/recipes-core/systemd/systemd/0012-fix-missing-of-__register_atfork-for-non-glibc-build.patch
new file mode 100644
index 0000000..d41bc4a
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0012-fix-missing-of-__register_atfork-for-non-glibc-build.patch
@@ -0,0 +1,45 @@
+From 1fadf805cb391e3bcbd9a0286a9e4b7adb9e7427 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Mon, 2 Jul 2018 13:34:09 +0800
+Subject: [PATCH 12/19] fix missing of __register_atfork for non-glibc builds
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/basic/process-util.c | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git a/src/basic/process-util.c b/src/basic/process-util.c
+index 0a4f917cb..3543bc045 100644
+--- a/src/basic/process-util.c
++++ b/src/basic/process-util.c
+@@ -22,6 +22,9 @@
+ #if HAVE_VALGRIND_VALGRIND_H
+ #include <valgrind/valgrind.h>
+ #endif
++#ifndef __GLIBC__
++#include <pthread.h>
++#endif
+ 
+ #include "alloc-util.h"
+ #include "architecture.h"
+@@ -1150,11 +1153,15 @@ void reset_cached_pid(void) {
+         cached_pid = CACHED_PID_UNSET;
+ }
+ 
++#ifdef __GLIBC__
+ /* We use glibc __register_atfork() + __dso_handle directly here, as they are not included in the glibc
+  * headers. __register_atfork() is mostly equivalent to pthread_atfork(), but doesn't require us to link against
+  * libpthread, as it is part of glibc anyway. */
+ extern int __register_atfork(void (*prepare) (void), void (*parent) (void), void (*child) (void), void * __dso_handle);
+ extern void* __dso_handle __attribute__ ((__weak__));
++#else
++#define __register_atfork(prepare,parent,child,dso) pthread_atfork(prepare,parent,child)
++#endif
+ 
+ pid_t getpid_cached(void) {
+         static bool installed = false;
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0012-rules-watch-metadata-changes-in-ide-devices.patch b/poky/meta/recipes-core/systemd/systemd/0012-rules-watch-metadata-changes-in-ide-devices.patch
deleted file mode 100644
index 7207863..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0012-rules-watch-metadata-changes-in-ide-devices.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 406a4c8692316e8c7e14c78f9a802689be304a95 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Fri, 17 Nov 2017 09:46:00 +0800
-Subject: [PATCH 12/31] rules: watch metadata changes in ide devices
-
-Formatting IDE storage does not trigger "change" uevents. As a result
-clients using udev API don't get any updates afterwards and get outdated
-information about the device.
-...
-root@qemux86-64:~# mkfs.ext4 -F /dev/hda1
-Creating filesystem with 262144 4k blocks and 65536 inodes
-Filesystem UUID: 98791eb2-2bf3-47ad-b4d8-4cf7e914eee2
-
-root@qemux86-64:~# ls /dev/disk/by-uuid/98791eb2-2bf3-47ad-b4d8-4cf7e914eee2
-ls: cannot access '/dev/disk/by-uuid/98791eb2-2bf3-47ad-b4d8-4cf7e914eee2': No such file or directory
-...
-Include hd* in a match for watch option assignment.
-
-Upstream-Status: Denied
-
-qemu by default emulates IDE and the linux-yocto kernel(s) use
-CONFIG_IDE instead of the more modern libsata, so disks appear as
-/dev/hd*. A similar patch rejected by upstream because CONFIG_IDE
-is deprecated.
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- rules/60-block.rules | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/rules/60-block.rules b/rules/60-block.rules
-index 343fc06f8..b5237dac4 100644
---- a/rules/60-block.rules
-+++ b/rules/60-block.rules
-@@ -8,4 +8,4 @@ ACTION=="add", SUBSYSTEM=="module", KERNEL=="block", ATTR{parameters/events_dfl_
- ACTION=="change", SUBSYSTEM=="scsi", ENV{DEVTYPE}=="scsi_device", TEST=="block", ATTR{block/*/uevent}="change"
- 
- # watch metadata changes, caused by tools closing the device node which was opened for writing
--ACTION!="remove", SUBSYSTEM=="block", KERNEL=="loop*|nvme*|sd*|vd*|xvd*|pmem*|mmcblk*", OPTIONS+="watch"
-+ACTION!="remove", SUBSYSTEM=="block", KERNEL=="loop*|nvme*|sd*|vd*|xvd*|pmem*|mmcblk*|hd*", OPTIONS+="watch"
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0013-Use-uintmax_t-for-handling-rlim_t.patch b/poky/meta/recipes-core/systemd/systemd/0013-Use-uintmax_t-for-handling-rlim_t.patch
new file mode 100644
index 0000000..69b3c15
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0013-Use-uintmax_t-for-handling-rlim_t.patch
@@ -0,0 +1,90 @@
+From a0ac0cfd90af6431c64d1b276f422a2092d569b3 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Mon, 2 Jul 2018 13:44:21 +0800
+Subject: [PATCH 13/19] Use uintmax_t for handling rlim_t
+
+PRIu{32,64} is not right format to represent rlim_t type
+therefore use %ju and typecast the rlim_t variables to
+uintmax_t.
+
+Fixes portablility errors like
+
+execute.c:3446:36: error: format '%lu' expects argument of type 'long unsigned int', but argument 5 has type 'rlim_t {aka long long unsigned int}' [-Werror=format=]
+|                          fprintf(f, "%s%s: " RLIM_FMT "\n",
+|                                     ^~~~~~~~
+|                                  prefix, rlimit_to_string(i), c->rlimit[i]->rlim_max);
+|                                                               ~~~~~~~~~~~~~~~~~~~~~~
+
+Upstream-Status: Denied [https://github.com/systemd/systemd/pull/7199]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/basic/format-util.h | 8 --------
+ src/basic/rlimit-util.c | 8 ++++----
+ src/core/execute.c      | 8 ++++----
+ 3 files changed, 8 insertions(+), 16 deletions(-)
+
+diff --git a/src/basic/format-util.h b/src/basic/format-util.h
+index 160550cd6..61245d1e3 100644
+--- a/src/basic/format-util.h
++++ b/src/basic/format-util.h
+@@ -43,14 +43,6 @@
+ #  define PRI_TIMEX "li"
+ #endif
+ 
+-#if SIZEOF_RLIM_T == 8
+-#  define RLIM_FMT "%" PRIu64
+-#elif SIZEOF_RLIM_T == 4
+-#  define RLIM_FMT "%" PRIu32
+-#else
+-#  error Unknown rlim_t size
+-#endif
+-
+ #if SIZEOF_DEV_T == 8
+ #  define DEV_FMT "%" PRIu64
+ #elif SIZEOF_DEV_T == 4
+diff --git a/src/basic/rlimit-util.c b/src/basic/rlimit-util.c
+index be1ba615e..e328ce499 100644
+--- a/src/basic/rlimit-util.c
++++ b/src/basic/rlimit-util.c
+@@ -299,13 +299,13 @@ int rlimit_format(const struct rlimit *rl, char **ret) {
+         if (rl->rlim_cur >= RLIM_INFINITY && rl->rlim_max >= RLIM_INFINITY)
+                 s = strdup("infinity");
+         else if (rl->rlim_cur >= RLIM_INFINITY)
+-                (void) asprintf(&s, "infinity:" RLIM_FMT, rl->rlim_max);
++                (void) asprintf(&s, "infinity:%ju", (uintmax_t)rl->rlim_max);
+         else if (rl->rlim_max >= RLIM_INFINITY)
+-                (void) asprintf(&s, RLIM_FMT ":infinity", rl->rlim_cur);
++                (void) asprintf(&s, "%ju:infinity", (uintmax_t)rl->rlim_cur);
+         else if (rl->rlim_cur == rl->rlim_max)
+-                (void) asprintf(&s, RLIM_FMT, rl->rlim_cur);
++                (void) asprintf(&s, "%ju", (uintmax_t)rl->rlim_cur);
+         else
+-                (void) asprintf(&s, RLIM_FMT ":" RLIM_FMT, rl->rlim_cur, rl->rlim_max);
++                (void) asprintf(&s, "%ju:%ju", (uintmax_t)rl->rlim_cur, (uintmax_t)rl->rlim_max);
+ 
+         if (!s)
+                 return -ENOMEM;
+diff --git a/src/core/execute.c b/src/core/execute.c
+index 8ac69d1a0..efedf3842 100644
+--- a/src/core/execute.c
++++ b/src/core/execute.c
+@@ -3976,10 +3976,10 @@ void exec_context_dump(const ExecContext *c, FILE* f, const char *prefix) {
+ 
+         for (i = 0; i < RLIM_NLIMITS; i++)
+                 if (c->rlimit[i]) {
+-                        fprintf(f, "Limit%s%s: " RLIM_FMT "\n",
+-                                prefix, rlimit_to_string(i), c->rlimit[i]->rlim_max);
+-                        fprintf(f, "Limit%s%sSoft: " RLIM_FMT "\n",
+-                                prefix, rlimit_to_string(i), c->rlimit[i]->rlim_cur);
++                        fprintf(f, "Limit%s%s: %ju\n",
++                                prefix, rlimit_to_string(i), (uintmax_t)c->rlimit[i]->rlim_max);
++                        fprintf(f, "Limit%s%sSoft: %ju\n",
++                                prefix, rlimit_to_string(i), (uintmax_t)c->rlimit[i]->rlim_cur);
+                 }
+ 
+         if (c->ioprio_set) {
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0013-add-fallback-parse_printf_format-implementation.patch b/poky/meta/recipes-core/systemd/systemd/0013-add-fallback-parse_printf_format-implementation.patch
deleted file mode 100644
index 9c9278d..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0013-add-fallback-parse_printf_format-implementation.patch
+++ /dev/null
@@ -1,431 +0,0 @@
-From 580d23cf0b32e36a8fb96710336ffef432b3c7ce Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Wed, 28 Feb 2018 21:10:58 -0800
-Subject: [PATCH] add fallback parse_printf_format implementation
-
-Upstream-Status: Pending
-
-Signed-off-by: Emil Renner Berthing <systemd@esmil.dk>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- meson.build                     |   1 +
- src/basic/meson.build           |   4 +
- src/basic/parse-printf-format.c | 273 ++++++++++++++++++++++++++++++++++++++++
- src/basic/parse-printf-format.h |  57 +++++++++
- src/basic/stdio-util.h          |   2 +-
- src/journal/journal-send.c      |   2 +-
- 6 files changed, 337 insertions(+), 2 deletions(-)
- create mode 100644 src/basic/parse-printf-format.c
- create mode 100644 src/basic/parse-printf-format.h
-
-diff --git a/meson.build b/meson.build
-index 94a16712b..4eabaafe8 100644
---- a/meson.build
-+++ b/meson.build
-@@ -620,6 +620,7 @@ foreach header : ['crypt.h',
-                   'linux/btrfs.h',
-                   'linux/memfd.h',
-                   'linux/vm_sockets.h',
-+                  'printf.h',
-                   'sys/auxv.h',
-                   'valgrind/memcheck.h',
-                   'valgrind/valgrind.h',
-diff --git a/src/basic/meson.build b/src/basic/meson.build
-index 44cd31ecb..435c6ee02 100644
---- a/src/basic/meson.build
-+++ b/src/basic/meson.build
-@@ -310,6 +310,10 @@ endforeach
- 
- basic_sources += [missing_h] + generated_gperf_headers
- 
-+if conf.get('HAVE_PRINTF_H') != 1
-+        basic_sources += [files('parse-printf-format.c')]
-+endif
-+
- libbasic = static_library(
-         'basic',
-         basic_sources,
-diff --git a/src/basic/parse-printf-format.c b/src/basic/parse-printf-format.c
-new file mode 100644
-index 000000000..49437e544
---- /dev/null
-+++ b/src/basic/parse-printf-format.c
-@@ -0,0 +1,273 @@
-+/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
-+
-+/***
-+  This file is part of systemd.
-+
-+  Copyright 2014 Emil Renner Berthing <systemd@esmil.dk>
-+
-+  With parts from the musl C library
-+  Copyright 2005-2014 Rich Felker, et al.
-+
-+  systemd is free software; you can redistribute it and/or modify it
-+  under the terms of the GNU Lesser General Public License as published by
-+  the Free Software Foundation; either version 2.1 of the License, or
-+  (at your option) any later version.
-+
-+  systemd is distributed in the hope that it will be useful, but
-+  WITHOUT ANY WARRANTY; without even the implied warranty of
-+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-+  Lesser General Public License for more details.
-+
-+  You should have received a copy of the GNU Lesser General Public License
-+  along with systemd; If not, see <http://www.gnu.org/licenses/>.
-+***/
-+
-+#include <stddef.h>
-+#include <string.h>
-+
-+#include "parse-printf-format.h"
-+
-+static const char *consume_nonarg(const char *fmt)
-+{
-+        do {
-+                if (*fmt == '\0')
-+                        return fmt;
-+        } while (*fmt++ != '%');
-+        return fmt;
-+}
-+
-+static const char *consume_num(const char *fmt)
-+{
-+        for (;*fmt >= '0' && *fmt <= '9'; fmt++)
-+                /* do nothing */;
-+        return fmt;
-+}
-+
-+static const char *consume_argn(const char *fmt, size_t *arg)
-+{
-+        const char *p = fmt;
-+        size_t val = 0;
-+
-+        if (*p < '1' || *p > '9')
-+                return fmt;
-+        do {
-+                val = 10*val + (*p++ - '0');
-+        } while (*p >= '0' && *p <= '9');
-+
-+        if (*p != '$')
-+                return fmt;
-+        *arg = val;
-+        return p+1;
-+}
-+
-+static const char *consume_flags(const char *fmt)
-+{
-+        while (1) {
-+                switch (*fmt) {
-+                case '#':
-+                case '0':
-+                case '-':
-+                case ' ':
-+                case '+':
-+                case '\'':
-+                case 'I':
-+                        fmt++;
-+                        continue;
-+                }
-+                return fmt;
-+        }
-+}
-+
-+enum state {
-+        BARE,
-+        LPRE,
-+        LLPRE,
-+        HPRE,
-+        HHPRE,
-+        BIGLPRE,
-+        ZTPRE,
-+        JPRE,
-+        STOP
-+};
-+
-+enum type {
-+        NONE,
-+        PTR,
-+        INT,
-+        UINT,
-+        ULLONG,
-+        LONG,
-+        ULONG,
-+        SHORT,
-+        USHORT,
-+        CHAR,
-+        UCHAR,
-+        LLONG,
-+        SIZET,
-+        IMAX,
-+        UMAX,
-+        PDIFF,
-+        UIPTR,
-+        DBL,
-+        LDBL,
-+        MAXTYPE
-+};
-+
-+static const short pa_types[MAXTYPE] = {
-+        [NONE]   = PA_INT,
-+        [PTR]    = PA_POINTER,
-+        [INT]    = PA_INT,
-+        [UINT]   = PA_INT,
-+        [ULLONG] = PA_INT | PA_FLAG_LONG_LONG,
-+        [LONG]   = PA_INT | PA_FLAG_LONG,
-+        [ULONG]  = PA_INT | PA_FLAG_LONG,
-+        [SHORT]  = PA_INT | PA_FLAG_SHORT,
-+        [USHORT] = PA_INT | PA_FLAG_SHORT,
-+        [CHAR]   = PA_CHAR,
-+        [UCHAR]  = PA_CHAR,
-+        [LLONG]  = PA_INT | PA_FLAG_LONG_LONG,
-+        [SIZET]  = PA_INT | PA_FLAG_LONG,
-+        [IMAX]   = PA_INT | PA_FLAG_LONG_LONG,
-+        [UMAX]   = PA_INT | PA_FLAG_LONG_LONG,
-+        [PDIFF]  = PA_INT | PA_FLAG_LONG_LONG,
-+        [UIPTR]  = PA_INT | PA_FLAG_LONG,
-+        [DBL]    = PA_DOUBLE,
-+        [LDBL]   = PA_DOUBLE | PA_FLAG_LONG_DOUBLE
-+};
-+
-+#define S(x) [(x)-'A']
-+#define E(x) (STOP + (x))
-+
-+static const unsigned char states[]['z'-'A'+1] = {
-+        { /* 0: bare types */
-+                S('d') = E(INT), S('i') = E(INT),
-+                S('o') = E(UINT),S('u') = E(UINT),S('x') = E(UINT), S('X') = E(UINT),
-+                S('e') = E(DBL), S('f') = E(DBL), S('g') = E(DBL),  S('a') = E(DBL),
-+                S('E') = E(DBL), S('F') = E(DBL), S('G') = E(DBL),  S('A') = E(DBL),
-+                S('c') = E(CHAR),S('C') = E(INT),
-+                S('s') = E(PTR), S('S') = E(PTR), S('p') = E(UIPTR),S('n') = E(PTR),
-+                S('m') = E(NONE),
-+                S('l') = LPRE,   S('h') = HPRE, S('L') = BIGLPRE,
-+                S('z') = ZTPRE,  S('j') = JPRE, S('t') = ZTPRE
-+        }, { /* 1: l-prefixed */
-+                S('d') = E(LONG), S('i') = E(LONG),
-+                S('o') = E(ULONG),S('u') = E(ULONG),S('x') = E(ULONG),S('X') = E(ULONG),
-+                S('e') = E(DBL),  S('f') = E(DBL),  S('g') = E(DBL),  S('a') = E(DBL),
-+                S('E') = E(DBL),  S('F') = E(DBL),  S('G') = E(DBL),  S('A') = E(DBL),
-+                S('c') = E(INT),  S('s') = E(PTR),  S('n') = E(PTR),
-+                S('l') = LLPRE
-+        }, { /* 2: ll-prefixed */
-+                S('d') = E(LLONG), S('i') = E(LLONG),
-+                S('o') = E(ULLONG),S('u') = E(ULLONG),
-+                S('x') = E(ULLONG),S('X') = E(ULLONG),
-+                S('n') = E(PTR)
-+        }, { /* 3: h-prefixed */
-+                S('d') = E(SHORT), S('i') = E(SHORT),
-+                S('o') = E(USHORT),S('u') = E(USHORT),
-+                S('x') = E(USHORT),S('X') = E(USHORT),
-+                S('n') = E(PTR),
-+                S('h') = HHPRE
-+        }, { /* 4: hh-prefixed */
-+                S('d') = E(CHAR), S('i') = E(CHAR),
-+                S('o') = E(UCHAR),S('u') = E(UCHAR),
-+                S('x') = E(UCHAR),S('X') = E(UCHAR),
-+                S('n') = E(PTR)
-+        }, { /* 5: L-prefixed */
-+                S('e') = E(LDBL),S('f') = E(LDBL),S('g') = E(LDBL), S('a') = E(LDBL),
-+                S('E') = E(LDBL),S('F') = E(LDBL),S('G') = E(LDBL), S('A') = E(LDBL),
-+                S('n') = E(PTR)
-+        }, { /* 6: z- or t-prefixed (assumed to be same size) */
-+                S('d') = E(PDIFF),S('i') = E(PDIFF),
-+                S('o') = E(SIZET),S('u') = E(SIZET),
-+                S('x') = E(SIZET),S('X') = E(SIZET),
-+                S('n') = E(PTR)
-+        }, { /* 7: j-prefixed */
-+                S('d') = E(IMAX), S('i') = E(IMAX),
-+                S('o') = E(UMAX), S('u') = E(UMAX),
-+                S('x') = E(UMAX), S('X') = E(UMAX),
-+                S('n') = E(PTR)
-+        }
-+};
-+
-+size_t parse_printf_format(const char *fmt, size_t n, int *types)
-+{
-+        size_t i = 0;
-+        size_t last = 0;
-+
-+        memset(types, 0, n);
-+
-+        while (1) {
-+                size_t arg;
-+                unsigned int state;
-+
-+                fmt = consume_nonarg(fmt);
-+                if (*fmt == '\0')
-+                        break;
-+                if (*fmt == '%') {
-+                        fmt++;
-+                        continue;
-+                }
-+                arg = 0;
-+                fmt = consume_argn(fmt, &arg);
-+                /* flags */
-+                fmt = consume_flags(fmt);
-+                /* width */
-+                if (*fmt == '*') {
-+                        size_t warg = 0;
-+                        fmt = consume_argn(fmt+1, &warg);
-+                        if (warg == 0)
-+                                warg = ++i;
-+                        if (warg > last)
-+                                last = warg;
-+                        if (warg <= n && types[warg-1] == NONE)
-+                                types[warg-1] = INT;
-+                } else
-+                        fmt = consume_num(fmt);
-+                /* precision */
-+                if (*fmt == '.') {
-+                        fmt++;
-+                        if (*fmt == '*') {
-+                                size_t parg = 0;
-+                                fmt = consume_argn(fmt+1, &parg);
-+                                if (parg == 0)
-+                                        parg = ++i;
-+                                if (parg > last)
-+                                        last = parg;
-+                                if (parg <= n && types[parg-1] == NONE)
-+                                        types[parg-1] = INT;
-+                        } else {
-+                                if (*fmt == '-')
-+                                        fmt++;
-+                                fmt = consume_num(fmt);
-+                        }
-+                }
-+                /* length modifier and conversion specifier */
-+                state = BARE;
-+                do {
-+                        unsigned char c = *fmt++;
-+
-+                        if (c < 'A' || c > 'z')
-+                                continue;
-+                        state = states[state]S(c);
-+                        if (state == 0)
-+                                continue;
-+                } while (state < STOP);
-+
-+                if (state == E(NONE))
-+                        continue;
-+
-+                if (arg == 0)
-+                        arg = ++i;
-+                if (arg > last)
-+                        last = arg;
-+                if (arg <= n)
-+                        types[arg-1] = state - STOP;
-+        }
-+
-+        if (last > n)
-+                last = n;
-+        for (i = 0; i < last; i++)
-+                types[i] = pa_types[types[i]];
-+
-+        return last;
-+}
-diff --git a/src/basic/parse-printf-format.h b/src/basic/parse-printf-format.h
-new file mode 100644
-index 000000000..47be7522d
---- /dev/null
-+++ b/src/basic/parse-printf-format.h
-@@ -0,0 +1,57 @@
-+/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
-+
-+/***
-+  This file is part of systemd.
-+
-+  Copyright 2014 Emil Renner Berthing <systemd@esmil.dk>
-+
-+  With parts from the GNU C Library
-+  Copyright 1991-2014 Free Software Foundation, Inc.
-+
-+  systemd is free software; you can redistribute it and/or modify it
-+  under the terms of the GNU Lesser General Public License as published by
-+  the Free Software Foundation; either version 2.1 of the License, or
-+  (at your option) any later version.
-+
-+  systemd is distributed in the hope that it will be useful, but
-+  WITHOUT ANY WARRANTY; without even the implied warranty of
-+  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-+  Lesser General Public License for more details.
-+
-+  You should have received a copy of the GNU Lesser General Public License
-+  along with systemd; If not, see <http://www.gnu.org/licenses/>.
-+***/
-+
-+#pragma once
-+
-+#include "config.h"
-+
-+#if HAVE_PRINTF_H
-+#include <printf.h>
-+#else
-+
-+#include <stddef.h>
-+
-+enum {				/* C type: */
-+  PA_INT,			/* int */
-+  PA_CHAR,			/* int, cast to char */
-+  PA_WCHAR,			/* wide char */
-+  PA_STRING,			/* const char *, a '\0'-terminated string */
-+  PA_WSTRING,			/* const wchar_t *, wide character string */
-+  PA_POINTER,			/* void * */
-+  PA_FLOAT,			/* float */
-+  PA_DOUBLE,			/* double */
-+  PA_LAST
-+};
-+
-+/* Flag bits that can be set in a type returned by `parse_printf_format'.  */
-+#define	PA_FLAG_MASK		0xff00
-+#define	PA_FLAG_LONG_LONG	(1 << 8)
-+#define	PA_FLAG_LONG_DOUBLE	PA_FLAG_LONG_LONG
-+#define	PA_FLAG_LONG		(1 << 9)
-+#define	PA_FLAG_SHORT		(1 << 10)
-+#define	PA_FLAG_PTR		(1 << 11)
-+
-+size_t parse_printf_format(const char *fmt, size_t n, int *types);
-+
-+#endif /* HAVE_PRINTF_H */
-diff --git a/src/basic/stdio-util.h b/src/basic/stdio-util.h
-index dbfafba26..8038380d6 100644
---- a/src/basic/stdio-util.h
-+++ b/src/basic/stdio-util.h
-@@ -20,12 +20,12 @@
-   along with systemd; If not, see <http://www.gnu.org/licenses/>.
- ***/
- 
--#include <printf.h>
- #include <stdarg.h>
- #include <stdio.h>
- #include <sys/types.h>
- 
- #include "macro.h"
-+#include "parse-printf-format.h"
- 
- #define xsprintf(buf, fmt, ...) \
-         assert_message_se((size_t) snprintf(buf, ELEMENTSOF(buf), fmt, __VA_ARGS__) < ELEMENTSOF(buf), "xsprintf: " #buf "[] must be big enough")
-diff --git a/src/journal/journal-send.c b/src/journal/journal-send.c
-index 73329ba02..70bb9e0e8 100644
---- a/src/journal/journal-send.c
-+++ b/src/journal/journal-send.c
-@@ -20,7 +20,6 @@
- 
- #include <errno.h>
- #include <fcntl.h>
--#include <printf.h>
- #include <stddef.h>
- #include <sys/socket.h>
- #include <sys/un.h>
-@@ -39,6 +38,7 @@
- #include "stdio-util.h"
- #include "string-util.h"
- #include "util.h"
-+#include "parse-printf-format.h"
- 
- #define SNDBUF_SIZE (8*1024*1024)
- 
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0014-fix-missing-ULONG_LONG_MAX-definition-in-case-of-mus.patch b/poky/meta/recipes-core/systemd/systemd/0014-fix-missing-ULONG_LONG_MAX-definition-in-case-of-mus.patch
new file mode 100644
index 0000000..258a631
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0014-fix-missing-ULONG_LONG_MAX-definition-in-case-of-mus.patch
@@ -0,0 +1,30 @@
+From cb59b3af54fb3bbd4d8264fef919810af8d08d16 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Tue, 27 Feb 2018 14:01:30 +0800
+Subject: [PATCH 14/19] fix missing ULONG_LONG_MAX definition in case of musl
+
+Upstream-Status: Inappropriate [musl]
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/basic/missing.h | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/src/basic/missing.h b/src/basic/missing.h
+index cd1cc109f..144058a1a 100644
+--- a/src/basic/missing.h
++++ b/src/basic/missing.h
+@@ -54,6 +54,10 @@ struct sockaddr_vm {
+ };
+ #endif /* !HAVE_LINUX_VM_SOCKETS_H */
+ 
++#ifndef ULONG_LONG_MAX
++#define ULONG_LONG_MAX ULLONG_MAX
++#endif
++
+ #ifndef RLIMIT_RTTIME
+ #define RLIMIT_RTTIME 15
+ #endif
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0014-src-basic-missing.h-check-for-missing-strndupa.patch b/poky/meta/recipes-core/systemd/systemd/0014-src-basic-missing.h-check-for-missing-strndupa.patch
deleted file mode 100644
index 9f62cbb..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0014-src-basic-missing.h-check-for-missing-strndupa.patch
+++ /dev/null
@@ -1,118 +0,0 @@
-From 33be9052315cc4ec8e929fa238e1f0cc0161ad07 Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Wed, 28 Feb 2018 21:15:28 -0800
-Subject: [PATCH] src/basic/missing.h: check for missing strndupa
-
-include missing.h  for definition of strndupa
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- meson.build             |  1 +
- src/basic/missing.h     | 11 +++++++++++
- src/basic/mkdir.c       |  1 +
- src/basic/parse-util.c  |  1 +
- src/basic/procfs-util.c |  1 +
- src/shared/pager.c      |  1 +
- src/shared/uid-range.c  |  1 +
- 7 files changed, 17 insertions(+)
-
-diff --git a/meson.build b/meson.build
-index 4eabaafe8..12811b3f3 100644
---- a/meson.build
-+++ b/meson.build
-@@ -525,6 +525,7 @@ foreach ident : [
-         ['bpf',               '''#include <sys/syscall.h>
-                                  #include <unistd.h>'''],
-         ['explicit_bzero' ,   '''#include <string.h>'''],
-+        ['strndupa' ,         '''#include <string.h>'''],
- ]
- 
-         have = cc.has_function(ident[0], prefix : ident[1], args : '-D_GNU_SOURCE')
-diff --git a/src/basic/missing.h b/src/basic/missing.h
-index 84d6d9167..07a8c8364 100644
---- a/src/basic/missing.h
-+++ b/src/basic/missing.h
-@@ -1187,6 +1187,17 @@ struct input_mask {
- typedef int32_t key_serial_t;
- #endif
- 
-+#if ! HAVE_STRNDUPA
-+#define strndupa(s, n) \
-+  ({ \
-+    const char *__old = (s); \
-+    size_t __len = strnlen(__old, (n)); \
-+    char *__new = (char *)alloca(__len + 1); \
-+    __new[__len] = '\0'; \
-+    (char *)memcpy(__new, __old, __len); \
-+  })
-+#endif
-+
- #ifndef KEYCTL_JOIN_SESSION_KEYRING
- #define KEYCTL_JOIN_SESSION_KEYRING 1
- #endif
-diff --git a/src/basic/mkdir.c b/src/basic/mkdir.c
-index de4746c86..d51518a5a 100644
---- a/src/basic/mkdir.c
-+++ b/src/basic/mkdir.c
-@@ -30,6 +30,7 @@
- #include "path-util.h"
- #include "stat-util.h"
- #include "user-util.h"
-+#include "missing.h"
- 
- int mkdir_safe_internal(const char *path, mode_t mode, uid_t uid, gid_t gid, bool follow_symlink, mkdir_func_t _mkdir) {
-         struct stat st;
-diff --git a/src/basic/parse-util.c b/src/basic/parse-util.c
-index 2c22753de..97533721d 100644
---- a/src/basic/parse-util.c
-+++ b/src/basic/parse-util.c
-@@ -33,6 +33,7 @@
- #include "parse-util.h"
- #include "process-util.h"
- #include "string-util.h"
-+#include "missing.h"
- 
- int parse_boolean(const char *v) {
-         assert(v);
-diff --git a/src/basic/procfs-util.c b/src/basic/procfs-util.c
-index 9bb42cc7b..23bbd9e67 100644
---- a/src/basic/procfs-util.c
-+++ b/src/basic/procfs-util.c
-@@ -9,6 +9,7 @@
- #include "procfs-util.h"
- #include "stdio-util.h"
- #include "string-util.h"
-+#include "missing.h"
- 
- int procfs_tasks_get_limit(uint64_t *ret) {
-         _cleanup_free_ char *value = NULL;
-diff --git a/src/shared/pager.c b/src/shared/pager.c
-index 75db3c985..84f06bf7d 100644
---- a/src/shared/pager.c
-+++ b/src/shared/pager.c
-@@ -39,6 +39,7 @@
- #include "string-util.h"
- #include "strv.h"
- #include "terminal-util.h"
-+#include "missing.h"
- 
- static pid_t pager_pid = 0;
- 
-diff --git a/src/shared/uid-range.c b/src/shared/uid-range.c
-index c38b7cc98..8ec6bf08d 100644
---- a/src/shared/uid-range.c
-+++ b/src/shared/uid-range.c
-@@ -25,6 +25,7 @@
- #include "macro.h"
- #include "uid-range.h"
- #include "user-util.h"
-+#include "missing.h"
- 
- static bool uid_range_intersect(UidRange *range, uid_t start, uid_t nr) {
-         assert(range);
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0015-don-t-fail-if-GLOB_BRACE-and-GLOB_ALTDIRFUNC-is-not-.patch b/poky/meta/recipes-core/systemd/systemd/0015-don-t-fail-if-GLOB_BRACE-and-GLOB_ALTDIRFUNC-is-not-.patch
deleted file mode 100644
index 4509476..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0015-don-t-fail-if-GLOB_BRACE-and-GLOB_ALTDIRFUNC-is-not-.patch
+++ /dev/null
@@ -1,157 +0,0 @@
-From b45cf4923c7e1f1165925e9b4d7db2108faf2eae Mon Sep 17 00:00:00 2001
-From: Emil Renner Berthing <systemd@esmil.dk>
-Date: Mon, 23 Oct 2017 10:50:14 -0700
-Subject: [PATCH 15/31] don't fail if GLOB_BRACE and GLOB_ALTDIRFUNC is not
- defined
-
-If the standard library doesn't provide brace
-expansion users just won't get it.
-
-Dont use GNU GLOB extentions on non-glibc systems
-
-Conditionalize use of GLOB_ALTDIRFUNC
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/basic/glob-util.c     | 20 +++++++++++++++++---
- src/test/test-glob-util.c | 17 +++++++++++++++--
- src/tmpfiles/tmpfiles.c   |  8 ++++++++
- 3 files changed, 40 insertions(+), 5 deletions(-)
-
-diff --git a/src/basic/glob-util.c b/src/basic/glob-util.c
-index 6e80a1e23..312bb3fd1 100644
---- a/src/basic/glob-util.c
-+++ b/src/basic/glob-util.c
-@@ -28,13 +28,18 @@
- #include "macro.h"
- #include "path-util.h"
- #include "strv.h"
-+/* Don't fail if the standard library
-+ * doesn't provide brace expansion */
-+#ifndef GLOB_BRACE
-+#define GLOB_BRACE 0
-+#endif
- 
- int safe_glob(const char *path, int flags, glob_t *pglob) {
-         int k;
- 
-+#ifdef GLOB_ALTDIRFUNC
-         /* We want to set GLOB_ALTDIRFUNC ourselves, don't allow it to be set. */
-         assert(!(flags & GLOB_ALTDIRFUNC));
--
-         if (!pglob->gl_closedir)
-                 pglob->gl_closedir = (void (*)(void *)) closedir;
-         if (!pglob->gl_readdir)
-@@ -45,10 +50,13 @@ int safe_glob(const char *path, int flags, glob_t *pglob) {
-                 pglob->gl_lstat = lstat;
-         if (!pglob->gl_stat)
-                 pglob->gl_stat = stat;
--
-+#endif
-         errno = 0;
-+#ifdef GLOB_ALTDIRFUNC
-         k = glob(path, flags | GLOB_ALTDIRFUNC, NULL, pglob);
--
-+#else
-+        k = glob(path, flags, NULL, pglob);
-+#endif
-         if (k == GLOB_NOMATCH)
-                 return -ENOENT;
-         if (k == GLOB_NOSPACE)
-@@ -61,6 +69,12 @@ int safe_glob(const char *path, int flags, glob_t *pglob) {
-         return 0;
- }
- 
-+/* Don't fail if the standard library
-+ * doesn't provide brace expansion */
-+#ifndef GLOB_BRACE
-+#define GLOB_BRACE 0
-+#endif
-+
- int glob_exists(const char *path) {
-         _cleanup_globfree_ glob_t g = {};
-         int k;
-diff --git a/src/test/test-glob-util.c b/src/test/test-glob-util.c
-index bd2f8fcfd..a10c77427 100644
---- a/src/test/test-glob-util.c
-+++ b/src/test/test-glob-util.c
-@@ -30,6 +30,11 @@
- #include "glob-util.h"
- #include "macro.h"
- #include "rm-rf.h"
-+/* Don't fail if the standard library
-+ * doesn't provide brace expansion */
-+#ifndef GLOB_BRACE
-+#define GLOB_BRACE 0
-+#endif
- 
- static void test_glob_exists(void) {
-         char name[] = "/tmp/test-glob_exists.XXXXXX";
-@@ -52,25 +57,33 @@ static void test_glob_exists(void) {
- static void test_glob_no_dot(void) {
-         char template[] = "/tmp/test-glob-util.XXXXXXX";
-         const char *fn;
--
-         _cleanup_globfree_ glob_t g = {
-+#ifdef GLOB_ALTDIRFUNC
-                 .gl_closedir = (void (*)(void *)) closedir,
-                 .gl_readdir = (struct dirent *(*)(void *)) readdir_no_dot,
-                 .gl_opendir = (void *(*)(const char *)) opendir,
-                 .gl_lstat = lstat,
-                 .gl_stat = stat,
-+#endif
-         };
--
-         int r;
- 
-         assert_se(mkdtemp(template));
- 
-         fn = strjoina(template, "/*");
-+#ifdef GLOB_ALTDIRFUNC
-         r = glob(fn, GLOB_NOSORT|GLOB_BRACE|GLOB_ALTDIRFUNC, NULL, &g);
-+#else
-+        r = glob(fn, GLOB_NOSORT|GLOB_BRACE, NULL, &g);
-+#endif
-         assert_se(r == GLOB_NOMATCH);
- 
-         fn = strjoina(template, "/.*");
-+#ifdef GLOB_ALTDIRFUNC
-         r = glob(fn, GLOB_NOSORT|GLOB_BRACE|GLOB_ALTDIRFUNC, NULL, &g);
-+#else
-+        r = glob(fn, GLOB_NOSORT|GLOB_BRACE, NULL, &g);
-+#endif
-         assert_se(r == GLOB_NOMATCH);
- 
-         (void) rm_rf(template, REMOVE_ROOT|REMOVE_PHYSICAL);
-diff --git a/src/tmpfiles/tmpfiles.c b/src/tmpfiles/tmpfiles.c
-index 38cbb739c..88cc543f0 100644
---- a/src/tmpfiles/tmpfiles.c
-+++ b/src/tmpfiles/tmpfiles.c
-@@ -76,6 +76,12 @@
- #include "umask-util.h"
- #include "user-util.h"
- #include "util.h"
-+/* Don't fail if the standard library
-+ * doesn't provide brace expansion */
-+#ifndef GLOB_BRACE
-+#define GLOB_BRACE 0
-+#endif
-+
- 
- /* This reads all files listed in /etc/tmpfiles.d/?*.conf and creates
-  * them in the file system. This is intended to be used to create
-@@ -1288,7 +1294,9 @@ static int item_do_children(Item *i, const char *path, action_t action) {
- 
- static int glob_item(Item *i, action_t action, bool recursive) {
-         _cleanup_globfree_ glob_t g = {
-+#ifdef GLOB_ALTDIRFUNC
-                 .gl_opendir = (void *(*)(const char *)) opendir_nomod,
-+#endif
-         };
-         int r = 0, k;
-         char **fn;
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0015-test-hexdecoct.c-Include-missing.h-for-strndupa.patch b/poky/meta/recipes-core/systemd/systemd/0015-test-hexdecoct.c-Include-missing.h-for-strndupa.patch
new file mode 100644
index 0000000..c7ca9cd
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0015-test-hexdecoct.c-Include-missing.h-for-strndupa.patch
@@ -0,0 +1,28 @@
+From b11109ecc41110c518a98b6ac39611ff86477021 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 23 Oct 2017 12:33:22 -0700
+Subject: [PATCH 15/19] test-hexdecoct.c: Include missing.h for strndupa
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/test/test-hexdecoct.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/test/test-hexdecoct.c b/src/test/test-hexdecoct.c
+index da9f3008b..7ff2dfe0c 100644
+--- a/src/test/test-hexdecoct.c
++++ b/src/test/test-hexdecoct.c
+@@ -6,6 +6,7 @@
+ #include "hexdecoct.h"
+ #include "macro.h"
+ #include "string-util.h"
++#include "missing.h"
+ 
+ static void test_hexchar(void) {
+         assert_se(hexchar(0xa) == 'a');
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0016-src-basic-missing.h-check-for-missing-__compar_fn_t-.patch b/poky/meta/recipes-core/systemd/systemd/0016-src-basic-missing.h-check-for-missing-__compar_fn_t-.patch
deleted file mode 100644
index 53037ea..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0016-src-basic-missing.h-check-for-missing-__compar_fn_t-.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From efc57856f961c1f3bf016c511c53d990db8abdff Mon Sep 17 00:00:00 2001
-From: Emil Renner Berthing <systemd@esmil.dk>
-Date: Mon, 23 Oct 2017 11:31:03 -0700
-Subject: [PATCH 16/31] src/basic/missing.h: check for missing __compar_fn_t
- typedef
-
-include missing.h for missing __compar_fn_t
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/basic/missing.h | 5 +++++
- src/basic/strbuf.c  | 1 +
- 2 files changed, 6 insertions(+)
-
-diff --git a/src/basic/missing.h b/src/basic/missing.h
-index 07a8c8364..1aee3346a 100644
---- a/src/basic/missing.h
-+++ b/src/basic/missing.h
-@@ -1162,6 +1162,11 @@ struct input_mask {
- #define RENAME_NOREPLACE (1 << 0)
- #endif
- 
-+#ifndef __COMPAR_FN_T
-+#define __COMPAR_FN_T
-+typedef int (*__compar_fn_t)(const void *, const void *);
-+#endif
-+
- #ifndef KCMP_FILE
- #define KCMP_FILE 0
- #endif
-diff --git a/src/basic/strbuf.c b/src/basic/strbuf.c
-index 8befffa66..bcb860f95 100644
---- a/src/basic/strbuf.c
-+++ b/src/basic/strbuf.c
-@@ -24,6 +24,7 @@
- 
- #include "alloc-util.h"
- #include "strbuf.h"
-+#include "missing.h"
- 
- /*
-  * Strbuf stores given strings in a single continuous allocated memory
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0016-test-sizeof.c-Disable-tests-for-missing-typedefs-in-.patch b/poky/meta/recipes-core/systemd/systemd/0016-test-sizeof.c-Disable-tests-for-missing-typedefs-in-.patch
new file mode 100644
index 0000000..c06a370
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0016-test-sizeof.c-Disable-tests-for-missing-typedefs-in-.patch
@@ -0,0 +1,42 @@
+From c4bbf3efefffe0a4efadbf4e3f0adb54d76fe0e7 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Wed, 28 Feb 2018 21:25:22 -0800
+Subject: [PATCH 16/19] test-sizeof.c: Disable tests for missing typedefs in
+ musl
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/test/test-sizeof.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/src/test/test-sizeof.c b/src/test/test-sizeof.c
+index 7a1e496ed..386b314d5 100644
+--- a/src/test/test-sizeof.c
++++ b/src/test/test-sizeof.c
+@@ -40,8 +40,10 @@ int main(void) {
+         info(unsigned);
+         info(long unsigned);
+         info(long long unsigned);
++#ifdef __GLIBC__
+         info(__syscall_ulong_t);
+         info(__syscall_slong_t);
++#endif
+ 
+         info(float);
+         info(double);
+@@ -59,7 +61,9 @@ int main(void) {
+         info(ssize_t);
+         info(time_t);
+         info(usec_t);
++#ifdef __GLIBC__
+         info(__time_t);
++#endif
+         info(pid_t);
+         info(uid_t);
+         info(gid_t);
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0017-Include-netinet-if_ether.h.patch b/poky/meta/recipes-core/systemd/systemd/0017-Include-netinet-if_ether.h.patch
deleted file mode 100644
index a09cfdd..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0017-Include-netinet-if_ether.h.patch
+++ /dev/null
@@ -1,85 +0,0 @@
-From f2b0173cd9807864db1ef3b102abaa76ef37e506 Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Wed, 28 Feb 2018 21:19:12 -0800
-Subject: [PATCH 17/31] Include netinet/if_ether.h
-
-Fixes
-/path/to/systemd/recipe-sysroot/usr/include/netinet/if_ether.h:101:8: error: redefinition of 'struct ethhdr'
- struct ethhdr {
-        ^~~~~~
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- src/libsystemd/sd-netlink/netlink-types.c | 1 +
- src/network/netdev/tuntap.c               | 1 +
- src/network/networkd-brvlan.c             | 1 +
- src/udev/net/ethtool-util.c               | 1 +
- src/udev/udev-builtin-net_setup_link.c    | 1 +
- 5 files changed, 5 insertions(+)
-
-diff --git a/src/libsystemd/sd-netlink/netlink-types.c b/src/libsystemd/sd-netlink/netlink-types.c
-index 0ee7d6f0d..ef75893a6 100644
---- a/src/libsystemd/sd-netlink/netlink-types.c
-+++ b/src/libsystemd/sd-netlink/netlink-types.c
-@@ -21,6 +21,7 @@
- #include <netinet/in.h>
- #include <stdint.h>
- #include <sys/socket.h>
-+#include <netinet/if_ether.h>
- #include <linux/netlink.h>
- #include <linux/rtnetlink.h>
- #include <linux/genetlink.h>
-diff --git a/src/network/netdev/tuntap.c b/src/network/netdev/tuntap.c
-index 4fc9b610a..628c61c57 100644
---- a/src/network/netdev/tuntap.c
-+++ b/src/network/netdev/tuntap.c
-@@ -20,6 +20,7 @@
- 
- #include <errno.h>
- #include <fcntl.h>
-+#include <netinet/if_ether.h>
- #include <linux/if_tun.h>
- #include <net/if.h>
- #include <netinet/if_ether.h>
-diff --git a/src/network/networkd-brvlan.c b/src/network/networkd-brvlan.c
-index 99dd41629..90407c9d8 100644
---- a/src/network/networkd-brvlan.c
-+++ b/src/network/networkd-brvlan.c
-@@ -19,6 +19,7 @@
- ***/
- 
- #include <netinet/in.h>
-+#include <netinet/if_ether.h>
- #include <linux/if_bridge.h>
- #include <stdbool.h>
- 
-diff --git a/src/udev/net/ethtool-util.c b/src/udev/net/ethtool-util.c
-index 9bdaef8d9..948f89cf8 100644
---- a/src/udev/net/ethtool-util.c
-+++ b/src/udev/net/ethtool-util.c
-@@ -18,6 +18,7 @@
-   along with systemd; If not, see <http://www.gnu.org/licenses/>.
- ***/
- 
-+#include <netinet/if_ether.h>
- #include <net/if.h>
- #include <sys/ioctl.h>
- #include <linux/ethtool.h>
-diff --git a/src/udev/udev-builtin-net_setup_link.c b/src/udev/udev-builtin-net_setup_link.c
-index 40158e0af..b24b3fce8 100644
---- a/src/udev/udev-builtin-net_setup_link.c
-+++ b/src/udev/udev-builtin-net_setup_link.c
-@@ -18,6 +18,7 @@
-   along with systemd; If not, see <http://www.gnu.org/licenses/>.
- ***/
- 
-+#include <netinet/if_ether.h>
- #include "alloc-util.h"
- #include "link-config.h"
- #include "log.h"
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0017-don-t-pass-AT_SYMLINK_NOFOLLOW-flag-to-faccessat.patch b/poky/meta/recipes-core/systemd/systemd/0017-don-t-pass-AT_SYMLINK_NOFOLLOW-flag-to-faccessat.patch
new file mode 100644
index 0000000..8e47c6f
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0017-don-t-pass-AT_SYMLINK_NOFOLLOW-flag-to-faccessat.patch
@@ -0,0 +1,99 @@
+From 91bb4f5c9c11464468e8d3fa4746d98d59997264 Mon Sep 17 00:00:00 2001
+From: Andre McCurdy <armccurdy@gmail.com>
+Date: Tue, 10 Oct 2017 14:33:30 -0700
+Subject: [PATCH 17/19] don't pass AT_SYMLINK_NOFOLLOW flag to faccessat()
+
+Avoid using AT_SYMLINK_NOFOLLOW flag. It doesn't seem like the right
+thing to do and it's not portable (not supported by musl). See:
+
+  http://lists.landley.net/pipermail/toybox-landley.net/2014-September/003610.html
+  http://www.openwall.com/lists/musl/2015/02/05/2
+
+Note that laccess() is never passing AT_EACCESS so a lot of the
+discussion in the links above doesn't apply. Note also that
+(currently) all systemd callers of laccess() pass mode as F_OK, so
+only check for existence of a file, not access permissions.
+Therefore, in this case, the only distiction between faccessat()
+with (flag == 0) and (flag == AT_SYMLINK_NOFOLLOW) is the behaviour
+for broken symlinks; laccess() on a broken symlink will succeed with
+(flag == AT_SYMLINK_NOFOLLOW) and fail (flag == 0).
+
+The laccess() macros was added to systemd some time ago and it's not
+clear if or why it needs to return success for broken symlinks. Maybe
+just historical and not actually necessary or desired behaviour?
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
+---
+ src/basic/fs-util.h          | 22 +++++++++++++++++++++-
+ src/shared/base-filesystem.c |  6 +++---
+ 2 files changed, 24 insertions(+), 4 deletions(-)
+
+diff --git a/src/basic/fs-util.h b/src/basic/fs-util.h
+index 28566773c..14b864cc5 100644
+--- a/src/basic/fs-util.h
++++ b/src/basic/fs-util.h
+@@ -32,7 +32,27 @@ int fchmod_opath(int fd, mode_t m);
+ 
+ int fd_warn_permissions(const char *path, int fd);
+ 
+-#define laccess(path, mode) faccessat(AT_FDCWD, (path), (mode), AT_SYMLINK_NOFOLLOW)
++/*
++   Avoid using AT_SYMLINK_NOFOLLOW flag. It doesn't seem like the right thing to
++   do and it's not portable (not supported by musl). See:
++
++     http://lists.landley.net/pipermail/toybox-landley.net/2014-September/003610.html
++     http://www.openwall.com/lists/musl/2015/02/05/2
++
++   Note that laccess() is never passing AT_EACCESS so a lot of the discussion in
++   the links above doesn't apply. Note also that (currently) all systemd callers
++   of laccess() pass mode as F_OK, so only check for existence of a file, not
++   access permissions. Therefore, in this case, the only distiction between
++   faccessat() with (flag == 0) and (flag == AT_SYMLINK_NOFOLLOW) is the
++   behaviour for broken symlinks; laccess() on a broken symlink will succeed
++   with (flag == AT_SYMLINK_NOFOLLOW) and fail (flag == 0).
++
++   The laccess() macros was added to systemd some time ago and it's not clear if
++   or why it needs to return success for broken symlinks. Maybe just historical
++   and not actually necessary or desired behaviour?
++*/
++
++#define laccess(path, mode) faccessat(AT_FDCWD, (path), (mode), 0)
+ 
+ int touch_file(const char *path, bool parents, usec_t stamp, uid_t uid, gid_t gid, mode_t mode);
+ int touch(const char *path);
+diff --git a/src/shared/base-filesystem.c b/src/shared/base-filesystem.c
+index 89d7a7d59..34b4ad53a 100644
+--- a/src/shared/base-filesystem.c
++++ b/src/shared/base-filesystem.c
+@@ -53,7 +53,7 @@ int base_filesystem_create(const char *root, uid_t uid, gid_t gid) {
+                 return log_error_errno(errno, "Failed to open root file system: %m");
+ 
+         for (i = 0; i < ELEMENTSOF(table); i ++) {
+-                if (faccessat(fd, table[i].dir, F_OK, AT_SYMLINK_NOFOLLOW) >= 0)
++                if (faccessat(fd, table[i].dir, F_OK, 0) >= 0)
+                         continue;
+ 
+                 if (table[i].target) {
+@@ -61,7 +61,7 @@ int base_filesystem_create(const char *root, uid_t uid, gid_t gid) {
+ 
+                         /* check if one of the targets exists */
+                         NULSTR_FOREACH(s, table[i].target) {
+-                                if (faccessat(fd, s, F_OK, AT_SYMLINK_NOFOLLOW) < 0)
++                                if (faccessat(fd, s, F_OK, 0) < 0)
+                                         continue;
+ 
+                                 /* check if a specific file exists at the target path */
+@@ -72,7 +72,7 @@ int base_filesystem_create(const char *root, uid_t uid, gid_t gid) {
+                                         if (!p)
+                                                 return log_oom();
+ 
+-                                        if (faccessat(fd, p, F_OK, AT_SYMLINK_NOFOLLOW) < 0)
++                                        if (faccessat(fd, p, F_OK, 0) < 0)
+                                                 continue;
+                                 }
+ 
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0018-Define-glibc-compatible-basename-for-non-glibc-syste.patch b/poky/meta/recipes-core/systemd/systemd/0018-Define-glibc-compatible-basename-for-non-glibc-syste.patch
new file mode 100644
index 0000000..1bd0d60
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0018-Define-glibc-compatible-basename-for-non-glibc-syste.patch
@@ -0,0 +1,34 @@
+From 97fed07132533a1b2bce9c60e305a5d09aee2e9b Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 27 May 2018 08:36:44 -0700
+Subject: [PATCH 18/19] Define glibc compatible basename() for non-glibc
+ systems
+
+Fixes builds with musl, even though systemd is adamant about
+using non-posix basename implementation, we have a way out
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/machine/machine-dbus.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/src/machine/machine-dbus.c b/src/machine/machine-dbus.c
+index 7f41465cc..cee8a5d43 100644
+--- a/src/machine/machine-dbus.c
++++ b/src/machine/machine-dbus.c
+@@ -11,6 +11,10 @@
+ #include <libgen.h>
+ #undef basename
+ 
++#if !defined(__GLIBC__)
++#define basename(src) (strrchr(src,'/') ? strrchr(src,'/')+1 : src)
++#endif
++
+ #include "alloc-util.h"
+ #include "bus-common-errors.h"
+ #include "bus-internal.h"
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0018-check-for-missing-canonicalize_file_name.patch b/poky/meta/recipes-core/systemd/systemd/0018-check-for-missing-canonicalize_file_name.patch
deleted file mode 100644
index ab7edf5..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0018-check-for-missing-canonicalize_file_name.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From 690eeef9590c7ef1d9d2c31d8c1d5d8071da8c4c Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Mon, 26 Feb 2018 17:21:11 +0800
-Subject: [PATCH 18/31] check for missing canonicalize_file_name
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- meson.build                 | 2 ++
- src/basic/missing_syscall.h | 6 ++++++
- 2 files changed, 8 insertions(+)
-
-diff --git a/meson.build b/meson.build
-index 12811b3f3..f6515e97c 100644
---- a/meson.build
-+++ b/meson.build
-@@ -520,6 +520,8 @@ foreach ident : [
-         ['kcmp',              '''#include <linux/kcmp.h>'''],
-         ['keyctl',            '''#include <sys/types.h>
-                                  #include <keyutils.h>'''],
-+        ['canonicalize_file_name', '''#define _GNU_SOURCE
-+                                      #include <stdlib.h>'''],
-         ['copy_file_range',   '''#include <sys/syscall.h>
-                                  #include <unistd.h>'''],
-         ['bpf',               '''#include <sys/syscall.h>
-diff --git a/src/basic/missing_syscall.h b/src/basic/missing_syscall.h
-index c938d0d97..308b9472b 100644
---- a/src/basic/missing_syscall.h
-+++ b/src/basic/missing_syscall.h
-@@ -31,6 +31,12 @@ static inline int pivot_root(const char *new_root, const char *put_old) {
- }
- #endif
- 
-+#if !HAVE_CANONICALIZE_FILE_NAME
-+static inline char *canonicalize_file_name(const char *path) {
-+        return realpath(path, NULL);
-+}
-+#endif
-+
- /* ======================================================================= */
- 
- #if !HAVE_MEMFD_CREATE
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0019-Do-not-disable-buffering-when-writing-to-oom_score_a.patch b/poky/meta/recipes-core/systemd/systemd/0019-Do-not-disable-buffering-when-writing-to-oom_score_a.patch
new file mode 100644
index 0000000..942f4c0
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0019-Do-not-disable-buffering-when-writing-to-oom_score_a.patch
@@ -0,0 +1,39 @@
+From 8440348bcac34249cdf6ac2dcae9ac66d3c727db Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Wed, 4 Jul 2018 15:00:44 +0800
+Subject: [PATCH 19/19] Do not disable buffering when writing to oom_score_adj
+
+On musl, disabling buffering when writing to oom_score_adj will
+cause the following error.
+
+  Failed to adjust OOM setting: Invalid argument
+
+This error appears for systemd-udevd.service and dbus.service.
+This is because kernel receives '-' instead of the whole '-900'
+if buffering is disabled.
+
+This is libc implementation specific, as glibc does not have this issue.
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/basic/process-util.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/basic/process-util.c b/src/basic/process-util.c
+index 3543bc045..d0572e034 100644
+--- a/src/basic/process-util.c
++++ b/src/basic/process-util.c
+@@ -1473,7 +1473,7 @@ int set_oom_score_adjust(int value) {
+         sprintf(t, "%i", value);
+ 
+         return write_string_file("/proc/self/oom_score_adj", t,
+-                                 WRITE_STRING_FILE_VERIFY_ON_FAILURE|WRITE_STRING_FILE_DISABLE_BUFFER);
++                                 WRITE_STRING_FILE_VERIFY_ON_FAILURE);
+ }
+ 
+ static const char *const ioprio_class_table[] = {
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0019-Do-not-enable-nss-tests-if-nss-systemd-is-not-enable.patch b/poky/meta/recipes-core/systemd/systemd/0019-Do-not-enable-nss-tests-if-nss-systemd-is-not-enable.patch
deleted file mode 100644
index 16b21a0..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0019-Do-not-enable-nss-tests-if-nss-systemd-is-not-enable.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From f5f313915d78bc43eb96e2aafb8ce3cda304c277 Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Mon, 26 Feb 2018 17:27:56 +0800
-Subject: [PATCH 19/31] Do not enable nss tests if nss-systemd is not enabled
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- src/test/meson.build | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/test/meson.build b/src/test/meson.build
-index 1db8aa107..df3a1f5c5 100644
---- a/src/test/meson.build
-+++ b/src/test/meson.build
-@@ -646,7 +646,7 @@ tests += [
-         [['src/test/test-nss.c'],
-          [],
-          [libdl],
--         '', 'manual'],
-+         'ENABLE_NSS_SYSTEMD', 'manual'],
- ]
- 
- ############################################################
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0020-distinguish-XSI-compliant-strerror_r-from-GNU-specif.patch b/poky/meta/recipes-core/systemd/systemd/0020-distinguish-XSI-compliant-strerror_r-from-GNU-specif.patch
new file mode 100644
index 0000000..5c78cab
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0020-distinguish-XSI-compliant-strerror_r-from-GNU-specif.patch
@@ -0,0 +1,62 @@
+From dd53dc9b9542cbd2c39a39096941dfed70d06506 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Tue, 10 Jul 2018 15:40:17 +0800
+Subject: [PATCH 20/20] distinguish XSI-compliant strerror_r from GNU-specifi
+ strerror_r
+
+XSI-compliant strerror_r and GNU-specifi strerror_r are different.
+
+       int strerror_r(int errnum, char *buf, size_t buflen);
+                   /* XSI-compliant */
+
+       char *strerror_r(int errnum, char *buf, size_t buflen);
+                   /* GNU-specific */
+
+We need to distinguish between them. Otherwise, we'll get an int value
+assigned to (char *) variable, resulting in segment fault.
+
+Upstream-Status: Inappropriate [musl specific]
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ src/journal/journal-send.c        | 5 +++++
+ src/libsystemd/sd-bus/bus-error.c | 5 +++++
+ 2 files changed, 10 insertions(+)
+
+diff --git a/src/journal/journal-send.c b/src/journal/journal-send.c
+index 65bcbcd2e..aef80dd8f 100644
+--- a/src/journal/journal-send.c
++++ b/src/journal/journal-send.c
+@@ -337,7 +337,12 @@ static int fill_iovec_perror_and_send(const char *message, int skip, struct iove
+                 char* j;
+ 
+                 errno = 0;
++#ifndef __GLIBC__
++                strerror_r(_saved_errno_, buffer + 8 + k, n - 8 - k);
++                j = buffer + 8 + k;
++#else
+                 j = strerror_r(_saved_errno_, buffer + 8 + k, n - 8 - k);
++#endif
+                 if (errno == 0) {
+                         char error[STRLEN("ERRNO=") + DECIMAL_STR_MAX(int) + 1];
+ 
+diff --git a/src/libsystemd/sd-bus/bus-error.c b/src/libsystemd/sd-bus/bus-error.c
+index ec359ac13..d2aa86cea 100644
+--- a/src/libsystemd/sd-bus/bus-error.c
++++ b/src/libsystemd/sd-bus/bus-error.c
+@@ -362,7 +362,12 @@ static void bus_error_strerror(sd_bus_error *e, int error) {
+                         return;
+ 
+                 errno = 0;
++#ifndef __GLIBC__
++                strerror_r(error, m, k);
++                x = m;
++#else
+                 x = strerror_r(error, m, k);
++#endif
+                 if (errno == ERANGE || strlen(x) >= k - 1) {
+                         free(m);
+                         k *= 2;
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0020-test-hexdecoct.c-Include-missing.h-for-strndupa.patch b/poky/meta/recipes-core/systemd/systemd/0020-test-hexdecoct.c-Include-missing.h-for-strndupa.patch
deleted file mode 100644
index ad49cfe..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0020-test-hexdecoct.c-Include-missing.h-for-strndupa.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From d63d2fedcd80e58ee53655aeaf2836d4b0a14652 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 23 Oct 2017 12:33:22 -0700
-Subject: [PATCH 20/31] test-hexdecoct.c: Include missing.h for strndupa
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- src/test/test-hexdecoct.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/src/test/test-hexdecoct.c b/src/test/test-hexdecoct.c
-index 3e25a0bac..ab3e508f1 100644
---- a/src/test/test-hexdecoct.c
-+++ b/src/test/test-hexdecoct.c
-@@ -24,6 +24,7 @@
- #include "hexdecoct.h"
- #include "macro.h"
- #include "string-util.h"
-+#include "missing.h"
- 
- static void test_hexchar(void) {
-         assert_se(hexchar(0xa) == 'a');
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0021-Hide-__start_BUS_ERROR_MAP-and-__stop_BUS_ERROR_MAP.patch b/poky/meta/recipes-core/systemd/systemd/0021-Hide-__start_BUS_ERROR_MAP-and-__stop_BUS_ERROR_MAP.patch
new file mode 100644
index 0000000..668f273
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0021-Hide-__start_BUS_ERROR_MAP-and-__stop_BUS_ERROR_MAP.patch
@@ -0,0 +1,34 @@
+From 687a5af8dc5d38f918a6ce08fed5297234bf8346 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 2 Mar 2018 18:00:17 -0800
+Subject: [PATCH] Hide __start_BUS_ERROR_MAP and __stop_BUS_ERROR_MAP
+
+for currently unknown reasons they get exported to the shared libries
+even without being listed in the sym file
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+
+Upstream-Status: Pending [ Conditional on master needing this, 239 does need it ]
+
+ src/libsystemd/sd-bus/bus-error.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/libsystemd/sd-bus/bus-error.c b/src/libsystemd/sd-bus/bus-error.c
+index 378f7a377..49d797abd 100644
+--- a/src/libsystemd/sd-bus/bus-error.c
++++ b/src/libsystemd/sd-bus/bus-error.c
+@@ -71,8 +71,8 @@ BUS_ERROR_MAP_ELF_REGISTER const sd_bus_error_map bus_standard_errors[] = {
+ };
+ 
+ /* GCC maps this magically to the beginning and end of the BUS_ERROR_MAP section */
+-extern const sd_bus_error_map __start_BUS_ERROR_MAP[];
+-extern const sd_bus_error_map __stop_BUS_ERROR_MAP[];
++extern const sd_bus_error_map __start_BUS_ERROR_MAP[] _hidden_;
++extern const sd_bus_error_map __stop_BUS_ERROR_MAP[] _hidden_;
+ 
+ /* Additional maps registered with sd_bus_error_add_map() are in this
+  * NULL terminated array */
+-- 
+2.16.2
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0021-test-sizeof.c-Disable-tests-for-missing-typedefs-in-.patch b/poky/meta/recipes-core/systemd/systemd/0021-test-sizeof.c-Disable-tests-for-missing-typedefs-in-.patch
deleted file mode 100644
index 9c8aeca..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0021-test-sizeof.c-Disable-tests-for-missing-typedefs-in-.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From dfea4b98844795a0cd14fdaf40c67df389dbd27e Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Wed, 28 Feb 2018 21:25:22 -0800
-Subject: [PATCH 21/31] test-sizeof.c: Disable tests for missing typedefs in
- musl
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- src/test/test-sizeof.c | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/src/test/test-sizeof.c b/src/test/test-sizeof.c
-index aed6db842..0de6fa63c 100644
---- a/src/test/test-sizeof.c
-+++ b/src/test/test-sizeof.c
-@@ -50,8 +50,10 @@ int main(void) {
-         info(unsigned);
-         info(long unsigned);
-         info(long long unsigned);
-+#ifdef __GLIBC__
-         info(__syscall_ulong_t);
-         info(__syscall_slong_t);
-+#endif
- 
-         info(float);
-         info(double);
-@@ -61,7 +63,9 @@ int main(void) {
-         info(ssize_t);
-         info(time_t);
-         info(usec_t);
-+#ifdef __GLIBC__
-         info(__time_t);
-+#endif
-         info(pid_t);
-         info(uid_t);
-         info(gid_t);
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0022-build-sys-Detect-whether-struct-statx-is-defined-in-.patch b/poky/meta/recipes-core/systemd/systemd/0022-build-sys-Detect-whether-struct-statx-is-defined-in-.patch
new file mode 100644
index 0000000..962463f
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0022-build-sys-Detect-whether-struct-statx-is-defined-in-.patch
@@ -0,0 +1,109 @@
+From 75720bff62a84896e9a0654afc7cf9408cf89a38 Mon Sep 17 00:00:00 2001
+From: Filipe Brandenburger <filbranden@google.com>
+Date: Sun, 15 Jul 2018 22:43:35 -0700
+Subject: [PATCH] build-sys: Detect whether struct statx is defined in
+ sys/stat.h
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Starting with glibc 2.27.9000-36.fc29, include file sys/stat.h will have a
+definition for struct statx, in which case include file linux/stat.h should be
+avoided, in order to prevent a duplicate definition.
+
+    In file included from ../src/basic/missing.h:18,
+		     from ../src/basic/util.h:28,
+		     from ../src/basic/hashmap.h:10,
+		     from ../src/shared/bus-util.h:12,
+		     from ../src/libsystemd/sd-bus/bus-creds.c:11:
+    /usr/include/linux/stat.h:99:8: error: redefinition of ‘struct statx’
+     struct statx {
+	    ^~~~~
+    In file included from /usr/include/sys/stat.h:446,
+		     from ../src/basic/util.h:19,
+		     from ../src/basic/hashmap.h:10,
+		     from ../src/shared/bus-util.h:12,
+		     from ../src/libsystemd/sd-bus/bus-creds.c:11:
+    /usr/include/bits/statx.h:36:8: note: originally defined here
+     struct statx
+	    ^~~~~
+
+Extend our meson.build to look for struct statx when only sys/stat.h is
+included and, in that case, do not include linux/stat.h anymore.
+
+Tested that systemd builds correctly when using a glibc version that includes a
+definition for struct statx.
+
+glibc Fedora RPM update:
+https://src.fedoraproject.org/rpms/glibc/c/28cb5d31fc1e5887912283c889689c47076278ae
+
+glibc upstream commit:
+https://sourceware.org/git/?p=glibc.git;a=commitdiff;h=fd70af45528d59a00eb3190ef6706cb299488fcd
+---
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+ meson.build            | 5 +++++
+ src/basic/missing.h    | 5 ++++-
+ src/basic/xattr-util.c | 1 -
+ 3 files changed, 9 insertions(+), 2 deletions(-)
+
+Index: git/meson.build
+===================================================================
+--- git.orig/meson.build
++++ git/meson.build
+@@ -432,6 +432,7 @@ decl_headers = '''
+ #include <sys/stat.h>
+ '''
+ # FIXME: key_serial_t is only defined in keyutils.h, this is bound to fail
++# FIXME: these should use -D_GNU_SOURCE, since that is defined at build time
+ 
+ foreach decl : ['char16_t',
+                 'char32_t',
+@@ -446,6 +447,10 @@ foreach decl : ['char16_t',
+         conf.set10('HAVE_' + decl.underscorify().to_upper(), have)
+ endforeach
+ 
++conf.set10('HAVE_STRUCT_STATX_IN_SYS_STAT_H', cc.sizeof('struct statx', prefix : '''
++#include <sys/stat.h>
++''', args : '-D_GNU_SOURCE') > 0)
++
+ foreach decl : [['IFLA_INET6_ADDR_GEN_MODE',         'linux/if_link.h'],
+                 ['IN6_ADDR_GEN_MODE_STABLE_PRIVACY', 'linux/if_link.h'],
+                 ['IFLA_VRF_TABLE',                   'linux/if_link.h'],
+Index: git/src/basic/missing.h
+===================================================================
+--- git.orig/src/basic/missing.h
++++ git/src/basic/missing.h
+@@ -15,7 +15,6 @@
+ #include <linux/neighbour.h>
+ #include <linux/oom.h>
+ #include <linux/rtnetlink.h>
+-#include <linux/stat.h>
+ #include <net/ethernet.h>
+ #include <stdlib.h>
+ #include <sys/resource.h>
+@@ -25,6 +24,10 @@
+ #include <uchar.h>
+ #include <unistd.h>
+ 
++#if !HAVE_STRUCT_STATX_IN_SYS_STAT_H
++#include <linux/stat.h>
++#endif
++
+ #if HAVE_AUDIT
+ #include <libaudit.h>
+ #endif
+Index: git/src/basic/xattr-util.c
+===================================================================
+--- git.orig/src/basic/xattr-util.c
++++ git/src/basic/xattr-util.c
+@@ -2,7 +2,6 @@
+ 
+ #include <errno.h>
+ #include <fcntl.h>
+-#include <linux/stat.h>
+ #include <stdint.h>
+ #include <stdlib.h>
+ #include <string.h>
diff --git a/poky/meta/recipes-core/systemd/systemd/0022-don-t-use-glibc-specific-qsort_r.patch b/poky/meta/recipes-core/systemd/systemd/0022-don-t-use-glibc-specific-qsort_r.patch
deleted file mode 100644
index a5f7442..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0022-don-t-use-glibc-specific-qsort_r.patch
+++ /dev/null
@@ -1,105 +0,0 @@
-From d343757d629402c70ca8e5eaa551deaf175c96f3 Mon Sep 17 00:00:00 2001
-From: Emil Renner Berthing <systemd@esmil.dk>
-Date: Thu, 18 Sep 2014 15:24:56 +0200
-Subject: [PATCH 22/31] don't use glibc-specific qsort_r
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/hwdb/hwdb.c         | 18 +++++++++++-------
- src/udev/udevadm-hwdb.c | 16 ++++++++++------
- 2 files changed, 21 insertions(+), 13 deletions(-)
-
-diff --git a/src/hwdb/hwdb.c b/src/hwdb/hwdb.c
-index 4540260f9..81aca7a9b 100644
---- a/src/hwdb/hwdb.c
-+++ b/src/hwdb/hwdb.c
-@@ -152,13 +152,12 @@ static void trie_free(struct trie *trie) {
- 
- DEFINE_TRIVIAL_CLEANUP_FUNC(struct trie*, trie_free);
- 
--static int trie_values_cmp(const void *v1, const void *v2, void *arg) {
-+static struct trie *trie_node_add_value_trie;
-+static int trie_values_cmp(const void *v1, const void *v2) {
-         const struct trie_value_entry *val1 = v1;
-         const struct trie_value_entry *val2 = v2;
--        struct trie *trie = arg;
--
--        return strcmp(trie->strings->buf + val1->key_off,
--                      trie->strings->buf + val2->key_off);
-+        return strcmp(trie_node_add_value_trie->strings->buf + val1->key_off,
-+                      trie_node_add_value_trie->strings->buf + val2->key_off);
- }
- 
- static int trie_node_add_value(struct trie *trie, struct trie_node *node,
-@@ -183,7 +182,10 @@ static int trie_node_add_value(struct trie *trie, struct trie_node *node,
-                         .value_off = v,
-                 };
- 
--                val = xbsearch_r(&search, node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp, trie);
-+                trie_node_add_value_trie = trie;
-+                val = bsearch(&search, node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp);
-+                trie_node_add_value_trie = NULL;
-+
-                 if (val) {
-                         /* At this point we have 2 identical properties on the same match-string.
-                          * Since we process files in order, we just replace the previous value.
-@@ -208,7 +210,9 @@ static int trie_node_add_value(struct trie *trie, struct trie_node *node,
-         node->values[node->values_count].file_priority = file_priority;
-         node->values[node->values_count].line_number = line_number;
-         node->values_count++;
--        qsort_r(node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp, trie);
-+        trie_node_add_value_trie = trie;
-+        qsort(node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp);
-+        trie_node_add_value_trie = NULL;
-         return 0;
- }
- 
-diff --git a/src/udev/udevadm-hwdb.c b/src/udev/udevadm-hwdb.c
-index ab5dc7ab6..c777e30ab 100644
---- a/src/udev/udevadm-hwdb.c
-+++ b/src/udev/udevadm-hwdb.c
-@@ -130,13 +130,13 @@ static void trie_node_cleanup(struct trie_node *node) {
-         free(node);
- }
- 
--static int trie_values_cmp(const void *v1, const void *v2, void *arg) {
-+static struct trie *trie_node_add_value_trie;
-+static int trie_values_cmp(const void *v1, const void *v2) {
-         const struct trie_value_entry *val1 = v1;
-         const struct trie_value_entry *val2 = v2;
--        struct trie *trie = arg;
- 
--        return strcmp(trie->strings->buf + val1->key_off,
--                      trie->strings->buf + val2->key_off);
-+        return strcmp(trie_node_add_value_trie->strings->buf + val1->key_off,
-+                      trie_node_add_value_trie->strings->buf + val2->key_off);
- }
- 
- static int trie_node_add_value(struct trie *trie, struct trie_node *node,
-@@ -157,7 +157,9 @@ static int trie_node_add_value(struct trie *trie, struct trie_node *node,
-                         .value_off = v,
-                 };
- 
--                val = xbsearch_r(&search, node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp, trie);
-+                trie_node_add_value_trie = trie;
-+                val = bsearch(&search, node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp);
-+                trie_node_add_value_trie = NULL;
-                 if (val) {
-                         /* replace existing earlier key with new value */
-                         val->value_off = v;
-@@ -174,7 +176,9 @@ static int trie_node_add_value(struct trie *trie, struct trie_node *node,
-         node->values[node->values_count].key_off = k;
-         node->values[node->values_count].value_off = v;
-         node->values_count++;
--        qsort_r(node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp, trie);
-+        trie_node_add_value_trie = trie;
-+        qsort(node->values, node->values_count, sizeof(struct trie_value_entry), trie_values_cmp);
-+        trie_node_add_value_trie = NULL;
-         return 0;
- }
- 
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0023-don-t-pass-AT_SYMLINK_NOFOLLOW-flag-to-faccessat.patch b/poky/meta/recipes-core/systemd/systemd/0023-don-t-pass-AT_SYMLINK_NOFOLLOW-flag-to-faccessat.patch
deleted file mode 100644
index 09c2b5c..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0023-don-t-pass-AT_SYMLINK_NOFOLLOW-flag-to-faccessat.patch
+++ /dev/null
@@ -1,99 +0,0 @@
-From 7b802ada1207ed00ed3867b9804dd0f316641b9b Mon Sep 17 00:00:00 2001
-From: Andre McCurdy <armccurdy@gmail.com>
-Date: Tue, 10 Oct 2017 14:33:30 -0700
-Subject: [PATCH 23/31] don't pass AT_SYMLINK_NOFOLLOW flag to faccessat()
-
-Avoid using AT_SYMLINK_NOFOLLOW flag. It doesn't seem like the right
-thing to do and it's not portable (not supported by musl). See:
-
-  http://lists.landley.net/pipermail/toybox-landley.net/2014-September/003610.html
-  http://www.openwall.com/lists/musl/2015/02/05/2
-
-Note that laccess() is never passing AT_EACCESS so a lot of the
-discussion in the links above doesn't apply. Note also that
-(currently) all systemd callers of laccess() pass mode as F_OK, so
-only check for existence of a file, not access permissions.
-Therefore, in this case, the only distiction between faccessat()
-with (flag == 0) and (flag == AT_SYMLINK_NOFOLLOW) is the behaviour
-for broken symlinks; laccess() on a broken symlink will succeed with
-(flag == AT_SYMLINK_NOFOLLOW) and fail (flag == 0).
-
-The laccess() macros was added to systemd some time ago and it's not
-clear if or why it needs to return success for broken symlinks. Maybe
-just historical and not actually necessary or desired behaviour?
-
-Upstream-Status: Pending
-
-Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
----
- src/basic/fs-util.h          | 22 +++++++++++++++++++++-
- src/shared/base-filesystem.c |  6 +++---
- 2 files changed, 24 insertions(+), 4 deletions(-)
-
-diff --git a/src/basic/fs-util.h b/src/basic/fs-util.h
-index 4dba1ea56..9c4b02ecc 100644
---- a/src/basic/fs-util.h
-+++ b/src/basic/fs-util.h
-@@ -50,7 +50,27 @@ int fchmod_umask(int fd, mode_t mode);
- 
- int fd_warn_permissions(const char *path, int fd);
- 
--#define laccess(path, mode) faccessat(AT_FDCWD, (path), (mode), AT_SYMLINK_NOFOLLOW)
-+/*
-+   Avoid using AT_SYMLINK_NOFOLLOW flag. It doesn't seem like the right thing to
-+   do and it's not portable (not supported by musl). See:
-+
-+     http://lists.landley.net/pipermail/toybox-landley.net/2014-September/003610.html
-+     http://www.openwall.com/lists/musl/2015/02/05/2
-+
-+   Note that laccess() is never passing AT_EACCESS so a lot of the discussion in
-+   the links above doesn't apply. Note also that (currently) all systemd callers
-+   of laccess() pass mode as F_OK, so only check for existence of a file, not
-+   access permissions. Therefore, in this case, the only distiction between
-+   faccessat() with (flag == 0) and (flag == AT_SYMLINK_NOFOLLOW) is the
-+   behaviour for broken symlinks; laccess() on a broken symlink will succeed
-+   with (flag == AT_SYMLINK_NOFOLLOW) and fail (flag == 0).
-+
-+   The laccess() macros was added to systemd some time ago and it's not clear if
-+   or why it needs to return success for broken symlinks. Maybe just historical
-+   and not actually necessary or desired behaviour?
-+*/
-+
-+#define laccess(path, mode) faccessat(AT_FDCWD, (path), (mode), 0)
- 
- int touch_file(const char *path, bool parents, usec_t stamp, uid_t uid, gid_t gid, mode_t mode);
- int touch(const char *path);
-diff --git a/src/shared/base-filesystem.c b/src/shared/base-filesystem.c
-index 3c25aa534..574ca71c7 100644
---- a/src/shared/base-filesystem.c
-+++ b/src/shared/base-filesystem.c
-@@ -71,7 +71,7 @@ int base_filesystem_create(const char *root, uid_t uid, gid_t gid) {
-                 return log_error_errno(errno, "Failed to open root file system: %m");
- 
-         for (i = 0; i < ELEMENTSOF(table); i ++) {
--                if (faccessat(fd, table[i].dir, F_OK, AT_SYMLINK_NOFOLLOW) >= 0)
-+                if (faccessat(fd, table[i].dir, F_OK, 0) >= 0)
-                         continue;
- 
-                 if (table[i].target) {
-@@ -79,7 +79,7 @@ int base_filesystem_create(const char *root, uid_t uid, gid_t gid) {
- 
-                         /* check if one of the targets exists */
-                         NULSTR_FOREACH(s, table[i].target) {
--                                if (faccessat(fd, s, F_OK, AT_SYMLINK_NOFOLLOW) < 0)
-+                                if (faccessat(fd, s, F_OK, 0) < 0)
-                                         continue;
- 
-                                 /* check if a specific file exists at the target path */
-@@ -90,7 +90,7 @@ int base_filesystem_create(const char *root, uid_t uid, gid_t gid) {
-                                         if (!p)
-                                                 return log_oom();
- 
--                                        if (faccessat(fd, p, F_OK, AT_SYMLINK_NOFOLLOW) < 0)
-+                                        if (faccessat(fd, p, F_OK, 0) < 0)
-                                                 continue;
-                                 }
- 
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0023-resolvconf-fixes-for-the-compatibility-interface.patch b/poky/meta/recipes-core/systemd/systemd/0023-resolvconf-fixes-for-the-compatibility-interface.patch
new file mode 100644
index 0000000..2f3e776
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd/0023-resolvconf-fixes-for-the-compatibility-interface.patch
@@ -0,0 +1,58 @@
+systemd-239: fixes for the compatibility interface
+
+[No upstream tracking] -- https://github.com/systemd/systemd/issues/9423
+
+resolvconf-compat: use compat_main() when called as `resolvconf`,
+since the interface is closer to that of `systemd-resolve`.
+
+Use a heap allocated string to set arg_ifname, since a stack allocated
+one would be lost after the function returns. (This last one broke the
+case where an interface name was suffixed with a dot, such as in
+`resolvconf -a tap0.dhcp`.)
+
+Tested:
+  $ build/resolvconf -a nonexistent.abc </etc/resolv.conf
+  Unknown interface 'nonexistent': No such device
+
+Upstream-Status: Backport [https://github.com/systemd/systemd/commit/5a01b3f35d7b6182c78b6973db8d99bdabd4f9c3]
+bug: 9423
+Signed-off-by: Simon Ausserlechner <simon.ausserlechner@siemens.com>
+
+diff --git a/src/resolve/resolvconf-compat.c b/src/resolve/resolvconf-compat.c
+index d7e68003e..072345894 100644
+--- a/src/resolve/resolvconf-compat.c
++++ b/src/resolve/resolvconf-compat.c
+@@ -53,6 +53,8 @@ static int parse_nameserver(const char *string) {
+ 
+                 if (strv_push(&arg_set_dns, word) < 0)
+                         return log_oom();
++
++                word = NULL;
+         }
+ 
+         return 0;
+@@ -202,7 +204,7 @@ int resolvconf_parse_argv(int argc, char *argv[]) {
+ 
+         dot = strchr(argv[optind], '.');
+         if (dot) {
+-                iface = strndupa(argv[optind], dot - argv[optind]);
++                iface = strndup(argv[optind], dot - argv[optind]);
+                 log_debug("Ignoring protocol specifier '%s'.", dot + 1);
+         } else
+                 iface = argv[optind];
+diff --git a/src/resolve/resolvectl.c b/src/resolve/resolvectl.c
+index e96c13fea..e9e395e3e 100644
+--- a/src/resolve/resolvectl.c
++++ b/src/resolve/resolvectl.c
+@@ -3092,7 +3092,7 @@ int main(int argc, char **argv) {
+                 goto finish;
+         }
+ 
+-        if (streq(program_invocation_short_name, "systemd-resolve"))
++        if (STR_IN_SET(program_invocation_short_name, "systemd-resolve", "resolvconf"))
+                 r = compat_main(argc, argv, bus);
+         else
+                 r = native_main(argc, argv, bus);
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-core/systemd/systemd/0024-comparison_fn_t-is-glibc-specific-use-raw-signature-.patch b/poky/meta/recipes-core/systemd/systemd/0024-comparison_fn_t-is-glibc-specific-use-raw-signature-.patch
deleted file mode 100644
index fe7e623..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0024-comparison_fn_t-is-glibc-specific-use-raw-signature-.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 76c71aa889155f29be1d5d2b74a2c4faa5909c8c Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 12 Sep 2015 18:53:31 +0000
-Subject: [PATCH 24/31] comparison_fn_t is glibc specific, use raw signature in
- function pointer
-
-make it work with musl where comparison_fn_t is not provided
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/basic/util.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/basic/util.h b/src/basic/util.h
-index 9d1b10756..12db53a93 100644
---- a/src/basic/util.h
-+++ b/src/basic/util.h
-@@ -95,7 +95,7 @@ void *xbsearch_r(const void *key, const void *base, size_t nmemb, size_t size,
-  * Normal qsort requires base to be nonnull. Here were require
-  * that only if nmemb > 0.
-  */
--static inline void qsort_safe(void *base, size_t nmemb, size_t size, comparison_fn_t compar) {
-+static inline void qsort_safe(void *base, size_t nmemb, size_t size, int (*compar)(const void *, const void *)) {
-         if (nmemb <= 1)
-                 return;
- 
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0025-Define-_PATH_WTMPX-and-_PATH_UTMPX-if-not-defined.patch b/poky/meta/recipes-core/systemd/systemd/0025-Define-_PATH_WTMPX-and-_PATH_UTMPX-if-not-defined.patch
deleted file mode 100644
index 9376a8f..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0025-Define-_PATH_WTMPX-and-_PATH_UTMPX-if-not-defined.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From a0b1496322f4d7ce83f4fbfd2a90b91d0721f643 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 24 Oct 2017 23:08:24 -0700
-Subject: [PATCH 25/31] Define _PATH_WTMPX and _PATH_UTMPX if not defined
-
-Musl needs these defines
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/shared/utmp-wtmp.c | 8 ++++++++
- 1 file changed, 8 insertions(+)
-
-diff --git a/src/shared/utmp-wtmp.c b/src/shared/utmp-wtmp.c
-index cab1cd6a2..f5eedac18 100644
---- a/src/shared/utmp-wtmp.c
-+++ b/src/shared/utmp-wtmp.c
-@@ -28,6 +28,7 @@
- #include <sys/time.h>
- #include <sys/utsname.h>
- #include <unistd.h>
-+#include <utmp.h>
- #include <utmpx.h>
- 
- #include "alloc-util.h"
-@@ -42,6 +43,13 @@
- #include "util.h"
- #include "utmp-wtmp.h"
- 
-+#if defined _PATH_UTMP && !defined _PATH_UTMPX
-+# define _PATH_UTMPX _PATH_UTMP
-+#endif
-+#if defined _PATH_WTMP && !defined _PATH_WTMPX
-+# define _PATH_WTMPX _PATH_WTMP
-+#endif
-+
- int utmp_get_runlevel(int *runlevel, int *previous) {
-         struct utmpx *found, lookup = { .ut_type = RUN_LVL };
-         int r;
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0026-Use-uintmax_t-for-handling-rlim_t.patch b/poky/meta/recipes-core/systemd/systemd/0026-Use-uintmax_t-for-handling-rlim_t.patch
deleted file mode 100644
index 46d75ad..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0026-Use-uintmax_t-for-handling-rlim_t.patch
+++ /dev/null
@@ -1,89 +0,0 @@
-From 88c48ea84db6fda19dfaeb64545fccf8fa0525ec Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 27 Oct 2017 13:00:41 -0700
-Subject: [PATCH 26/31] Use uintmax_t for handling rlim_t
-
-PRIu{32,64} is not right format to represent rlim_t type
-therefore use %ju and typecast the rlim_t variables to
-uintmax_t.
-
-Fixes portablility errors like
-
-execute.c:3446:36: error: format '%lu' expects argument of type 'long unsigned int', but argument 5 has type 'rlim_t {aka long long unsigned int}' [-Werror=format=]
-|                          fprintf(f, "%s%s: " RLIM_FMT "\n",
-|                                     ^~~~~~~~
-|                                  prefix, rlimit_to_string(i), c->rlimit[i]->rlim_max);
-|                                                               ~~~~~~~~~~~~~~~~~~~~~~
-
-Upstream-Status: Submitted [https://github.com/systemd/systemd/pull/7199]
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/basic/format-util.h | 8 --------
- src/basic/rlimit-util.c | 8 ++++----
- src/core/execute.c      | 8 ++++----
- 3 files changed, 8 insertions(+), 16 deletions(-)
-
-diff --git a/src/basic/format-util.h b/src/basic/format-util.h
-index d9a78f781..9a1bc21d7 100644
---- a/src/basic/format-util.h
-+++ b/src/basic/format-util.h
-@@ -61,14 +61,6 @@
- #  define PRI_TIMEX "li"
- #endif
- 
--#if SIZEOF_RLIM_T == 8
--#  define RLIM_FMT "%" PRIu64
--#elif SIZEOF_RLIM_T == 4
--#  define RLIM_FMT "%" PRIu32
--#else
--#  error Unknown rlim_t size
--#endif
--
- #if SIZEOF_DEV_T == 8
- #  define DEV_FMT "%" PRIu64
- #elif SIZEOF_DEV_T == 4
-diff --git a/src/basic/rlimit-util.c b/src/basic/rlimit-util.c
-index 00648211d..df3d9ecc1 100644
---- a/src/basic/rlimit-util.c
-+++ b/src/basic/rlimit-util.c
-@@ -286,13 +286,13 @@ int rlimit_format(const struct rlimit *rl, char **ret) {
-         if (rl->rlim_cur >= RLIM_INFINITY && rl->rlim_max >= RLIM_INFINITY)
-                 s = strdup("infinity");
-         else if (rl->rlim_cur >= RLIM_INFINITY)
--                (void) asprintf(&s, "infinity:" RLIM_FMT, rl->rlim_max);
-+                (void) asprintf(&s, "infinity:%ju", (uintmax_t)rl->rlim_max);
-         else if (rl->rlim_max >= RLIM_INFINITY)
--                (void) asprintf(&s, RLIM_FMT ":infinity", rl->rlim_cur);
-+                (void) asprintf(&s, "%ju:infinity", (uintmax_t)rl->rlim_cur);
-         else if (rl->rlim_cur == rl->rlim_max)
--                (void) asprintf(&s, RLIM_FMT, rl->rlim_cur);
-+                (void) asprintf(&s, "%ju", (uintmax_t)rl->rlim_cur);
-         else
--                (void) asprintf(&s, RLIM_FMT ":" RLIM_FMT, rl->rlim_cur, rl->rlim_max);
-+                (void) asprintf(&s, "%ju:%ju", (uintmax_t)rl->rlim_cur, (uintmax_t)rl->rlim_max);
- 
-         if (!s)
-                 return -ENOMEM;
-diff --git a/src/core/execute.c b/src/core/execute.c
-index 0df3971df..aabdddb68 100644
---- a/src/core/execute.c
-+++ b/src/core/execute.c
-@@ -3991,10 +3991,10 @@ void exec_context_dump(ExecContext *c, FILE* f, const char *prefix) {
- 
-         for (i = 0; i < RLIM_NLIMITS; i++)
-                 if (c->rlimit[i]) {
--                        fprintf(f, "%s%s: " RLIM_FMT "\n",
--                                prefix, rlimit_to_string(i), c->rlimit[i]->rlim_max);
--                        fprintf(f, "%s%sSoft: " RLIM_FMT "\n",
--                                prefix, rlimit_to_string(i), c->rlimit[i]->rlim_cur);
-+                        fprintf(f, "%s%s: %ju\n",
-+                                prefix, rlimit_to_string(i), (uintmax_t)c->rlimit[i]->rlim_max);
-+                        fprintf(f, "%s%sSoft: %ju\n",
-+                                prefix, rlimit_to_string(i), (uintmax_t)c->rlimit[i]->rlim_cur);
-                 }
- 
-         if (c->ioprio_set) {
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0027-remove-nobody-user-group-checking.patch b/poky/meta/recipes-core/systemd/systemd/0027-remove-nobody-user-group-checking.patch
deleted file mode 100644
index 42f59b0..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0027-remove-nobody-user-group-checking.patch
+++ /dev/null
@@ -1,63 +0,0 @@
-From 5354eb767d1eba2ec41eb273f6b657f4a630ca8a Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Tue, 9 Jan 2018 14:45:46 +0800
-Subject: [PATCH 27/31] remove nobody user/group checking
-
-Upstream-Status: Inappropriate [OE Specific]
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- meson.build | 37 -------------------------------------
- 1 file changed, 37 deletions(-)
-
-diff --git a/meson.build b/meson.build
-index f6515e97c..1b947adac 100644
---- a/meson.build
-+++ b/meson.build
-@@ -700,43 +700,6 @@ substs.set('containeruidbasemax', container_uid_base_max)
- nobody_user = get_option('nobody-user')
- nobody_group = get_option('nobody-group')
- 
--getent_result = run_command('getent', 'passwd', '65534')
--if getent_result.returncode() == 0
--        name = getent_result.stdout().split(':')[0]
--        if name != nobody_user
--                message('WARNING:\n' +
--                        '        The local user with the UID 65534 does not match the configured user name "@0@" of the nobody user (its name is @1@).\n'.format(nobody_user, name) +
--                        '        Your build will result in an user table setup that is incompatible with the local system.')
--        endif
--endif
--id_result = run_command('id', '-u', nobody_user)
--if id_result.returncode() == 0
--        id = id_result.stdout().to_int()
--        if id != 65534
--                message('WARNING:\n' +
--                        '        The local user with the configured user name "@0@" of the nobody user does not have UID 65534 (it has @1@).\n'.format(nobody_user, id) +
--                        '        Your build will result in an user table setup that is incompatible with the local system.')
--        endif
--endif
--
--getent_result = run_command('getent', 'group', '65534')
--if getent_result.returncode() == 0
--        name = getent_result.stdout().split(':')[0]
--        if name != nobody_group
--                message('WARNING:\n' +
--                        '        The local group with the GID 65534 does not match the configured group name "@0@" of the nobody group (its name is @1@).\n'.format(nobody_group, name) +
--                        '        Your build will result in an group table setup that is incompatible with the local system.')
--        endif
--endif
--id_result = run_command('id', '-g', nobody_group)
--if id_result.returncode() == 0
--        id = id_result.stdout().to_int()
--        if id != 65534
--                message('WARNING:\n' +
--                        '        The local group with the configured group name "@0@" of the nobody group does not have UID 65534 (it has @1@).\n'.format(nobody_group, id) +
--                        '        Your build will result in an group table setup that is incompatible with the local system.')
--        endif
--endif
- if nobody_user != nobody_group and not (nobody_user == 'nobody' and nobody_group == 'nogroup')
-         message('WARNING:\n' +
-                 '        The configured user name "@0@" and group name "@0@" of the nobody user/group are not equivalent.\n'.format(nobody_user, nobody_group) +
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0028-add-missing-FTW_-macros-for-musl.patch b/poky/meta/recipes-core/systemd/systemd/0028-add-missing-FTW_-macros-for-musl.patch
deleted file mode 100644
index 9ec3137..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0028-add-missing-FTW_-macros-for-musl.patch
+++ /dev/null
@@ -1,50 +0,0 @@
-From 03cdd33be62db4c72a7fcf21b61d0d056c23c6a9 Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Wed, 28 Feb 2018 21:36:32 -0800
-Subject: [PATCH 28/31] add missing FTW_ macros for musl
-
-This is to avoid build failures like below for musl.
-
-  locale-util.c:296:24: error: 'FTW_STOP' undeclared
-
-Upstream-Status: Pending
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- src/basic/missing.h | 20 ++++++++++++++++++++
- 1 file changed, 20 insertions(+)
-
-diff --git a/src/basic/missing.h b/src/basic/missing.h
-index 1aee3346a..5b9fde692 100644
---- a/src/basic/missing.h
-+++ b/src/basic/missing.h
-@@ -207,6 +207,26 @@ struct sockaddr_vm {
- #define BTRFS_QGROUP_LEVEL_SHIFT 48
- #endif
- 
-+#ifndef FTW_ACTIONRETVAL
-+#define FTW_ACTIONRETVAL 16
-+#endif
-+
-+#ifndef FTW_CONTINUE
-+#define FTW_CONTINUE 0
-+#endif
-+
-+#ifndef FTW_STOP
-+#define FTW_STOP 1
-+#endif
-+
-+#ifndef FTW_SKIP_SUBTREE
-+#define FTW_SKIP_SUBTREE 2
-+#endif
-+
-+#ifndef FTW_SKIP_SIBLINGS
-+#define FTW_SKIP_SIBLINGS 3
-+#endif
-+
- #if ! HAVE_LINUX_BTRFS_H
- #define BTRFS_IOC_QGROUP_ASSIGN _IOW(BTRFS_IOCTL_MAGIC, 41, \
-                                struct btrfs_ioctl_qgroup_assign_args)
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0029-nss-mymachines-Build-conditionally-when-ENABLE_MYHOS.patch b/poky/meta/recipes-core/systemd/systemd/0029-nss-mymachines-Build-conditionally-when-ENABLE_MYHOS.patch
deleted file mode 100644
index 517249f..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0029-nss-mymachines-Build-conditionally-when-ENABLE_MYHOS.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 5845c82d1016a3e3f2696180d5ac91b46950540a Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Tue, 27 Feb 2018 12:56:21 +0800
-Subject: [PATCH 29/31] nss-mymachines: Build conditionally when
- ENABLE_MYHOSTNAME is set
-
-Fixes build failures when building with --disable-myhostname
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- meson.build | 11 +++++++----
- 1 file changed, 7 insertions(+), 4 deletions(-)
-
-diff --git a/meson.build b/meson.build
-index 1b947adac..1ed4dde72 100644
---- a/meson.build
-+++ b/meson.build
-@@ -1351,12 +1351,15 @@ test_dlopen = executable(
-         link_with : [libbasic],
-         dependencies : [libdl])
- 
--foreach tuple : [['myhostname', 'ENABLE_MYHOSTNAME'],
--                 ['systemd',    'ENABLE_NSS_SYSTEMD'],
--                 ['mymachines', 'ENABLE_MACHINED'],
--                 ['resolve',    'ENABLE_RESOLVE']]
-+foreach tuple : [['myhostname', 'ENABLE_MYHOSTNAME',  ''],
-+                 ['systemd',    'ENABLE_NSS_SYSTEMD', ''],
-+                 ['mymachines', 'ENABLE_MACHINED',    'ENABLE_MYHOSTNAME'],
-+                 ['resolve',    'ENABLE_RESOLVE',     '']]
- 
-         condition = tuple[1] == '' or conf.get(tuple[1]) == 1
-+        if tuple[2] != '' and condition
-+                condition = conf.get(tuple[2]) == 1
-+        endif
-         if condition
-                 module = tuple[0]
- 
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0030-fix-missing-of-__register_atfork-for-non-glibc-build.patch b/poky/meta/recipes-core/systemd/systemd/0030-fix-missing-of-__register_atfork-for-non-glibc-build.patch
deleted file mode 100644
index 7f0b4bf..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0030-fix-missing-of-__register_atfork-for-non-glibc-build.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-From b7eacdf0388f930fc5271bdecfa46612c71dd65c Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Tue, 27 Feb 2018 13:27:47 +0800
-Subject: [PATCH 30/31] fix missing of __register_atfork for non-glibc builds
-
-Upstream-Status: Pending
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- src/basic/process-util.c | 7 +++++++
- 1 file changed, 7 insertions(+)
-
-diff --git a/src/basic/process-util.c b/src/basic/process-util.c
-index dc7c9ef9e..85ce8a0cc 100644
---- a/src/basic/process-util.c
-+++ b/src/basic/process-util.c
-@@ -39,6 +39,9 @@
- #if HAVE_VALGRIND_VALGRIND_H
- #include <valgrind/valgrind.h>
- #endif
-+#ifndef __GLIBC__
-+#include <pthread.h>
-+#endif
- 
- #include "alloc-util.h"
- #include "architecture.h"
-@@ -1112,11 +1115,15 @@ void reset_cached_pid(void) {
-         cached_pid = CACHED_PID_UNSET;
- }
- 
-+#ifdef __GLIBC__
- /* We use glibc __register_atfork() + __dso_handle directly here, as they are not included in the glibc
-  * headers. __register_atfork() is mostly equivalent to pthread_atfork(), but doesn't require us to link against
-  * libpthread, as it is part of glibc anyway. */
- extern int __register_atfork(void (*prepare) (void), void (*parent) (void), void (*child) (void), void * __dso_handle);
- extern void* __dso_handle __attribute__ ((__weak__));
-+#else
-+#define __register_atfork(prepare,parent,child,dso) pthread_atfork(prepare,parent,child)
-+#endif
- 
- pid_t getpid_cached(void) {
-         pid_t current_value;
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0031-fix-missing-ULONG_LONG_MAX-definition-in-case-of-mus.patch b/poky/meta/recipes-core/systemd/systemd/0031-fix-missing-ULONG_LONG_MAX-definition-in-case-of-mus.patch
deleted file mode 100644
index 319c4b6..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0031-fix-missing-ULONG_LONG_MAX-definition-in-case-of-mus.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From adcd7e426fcd80e754274a730221d1a1f49dbc21 Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Tue, 27 Feb 2018 14:01:30 +0800
-Subject: [PATCH 31/31] fix missing ULONG_LONG_MAX definition in case of musl
-
-Upstream-Status: Pending
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- src/basic/missing.h | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/src/basic/missing.h b/src/basic/missing.h
-index 5b9fde692..a922f1346 100644
---- a/src/basic/missing.h
-+++ b/src/basic/missing.h
-@@ -72,6 +72,10 @@ struct sockaddr_vm {
- };
- #endif /* !HAVE_LINUX_VM_SOCKETS_H */
- 
-+#ifndef ULONG_LONG_MAX
-+#define ULONG_LONG_MAX ULLONG_MAX
-+#endif
-+
- #ifndef RLIMIT_RTTIME
- #define RLIMIT_RTTIME 15
- #endif
--- 
-2.13.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0032-memfd.patch b/poky/meta/recipes-core/systemd/systemd/0032-memfd.patch
deleted file mode 100644
index f7cfd60..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0032-memfd.patch
+++ /dev/null
@@ -1,272 +0,0 @@
-missing_syscall: when adding syscall replacements, use different names (
-
-#8229)
-
-In meson.build we check that functions are available using:
-    meson.get_compiler('c').has_function('foo')
-which checks the following:
-- if __stub_foo or __stub___foo are defined, return false
-- if foo is declared (a pointer to the function can be taken), return true
-- otherwise check for __builtin_memfd_create
-
-_stub is documented by glibc as
-   It defines a symbol '__stub_FUNCTION' for each function
-   in the C library which is a stub, meaning it will fail
-   every time called, usually setting errno to ENOSYS.
-
-So if __stub is defined, we know we don't want to use the glibc version, but
-this doesn't tell us if the name itself is defined or not. If it _is_ defined,
-and we define our replacement as an inline static function, we get an error:
-
-In file included from ../src/basic/missing.h:1358:0,
-                 from ../src/basic/util.h:47,
-                 from ../src/basic/calendarspec.h:29,
-                 from ../src/basic/calendarspec.c:34:
-../src/basic/missing_syscall.h:65:19: error: static declaration of 'memfd_create' follows non-static declaration
- static inline int memfd_create(const char *name, unsigned int flags) {
-                   ^~~~~~~~~~~~
-.../usr/include/bits/mman-shared.h:46:5: note: previous declaration of 'memfd_create' was here
- int memfd_create (const char *__name, unsigned int __flags) __THROW;
-     ^~~~~~~~~~~~
-
-To avoid this problem, call our inline functions different than glibc,
-and use a #define to map the official name to our replacement.
-
-Fixes #8099.
-
-v2:
-- use "missing_" as the prefix instead of "_"
-
-v3:
-- rebase and update for statx()
-
-  Unfortunately "statx" is also present in "struct statx", so the define
-  causes issues. Work around this by using a typedef.
-
-I checked that systemd compiles with current glibc
-(glibc-devel-2.26-24.fc27.x86_64) if HAVE_MEMFD_CREATE, HAVE_GETTID,
-HAVE_PIVOT_ROOT, HAVE_SETNS, HAVE_RENAMEAT2, HAVE_KCMP, HAVE_KEYCTL,
-HAVE_COPY_FILE_RANGE, HAVE_BPF, HAVE_STATX are forced to 0.
-
-Setting HAVE_NAME_TO_HANDLE_AT to 0 causes an issue, but it's not because of
-the define, but because of struct file_handle.
-
-
-backport https://github.com/systemd/systemd/commit/5187dd2c403caf92d09f3491e41f1ceb3f10491f
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Upstream-Status: Backport [https://github.com/systemd/systemd/issues/8099]
-Index: git/src/basic/missing_syscall.h
-===================================================================
---- git.orig/src/basic/missing_syscall.h
-+++ git/src/basic/missing_syscall.h
-@@ -26,9 +26,11 @@
- #include <sys/types.h>
- 
- #if !HAVE_PIVOT_ROOT
--static inline int pivot_root(const char *new_root, const char *put_old) {
-+static inline int missing_pivot_root(const char *new_root, const char *put_old) {
-         return syscall(SYS_pivot_root, new_root, put_old);
- }
-+
-+#  define pivot_root missing_pivot_root
- #endif
- 
- #if !HAVE_CANONICALIZE_FILE_NAME
-@@ -68,7 +70,7 @@ static inline char *canonicalize_file_na
- #    endif
- #  endif
- 
--static inline int memfd_create(const char *name, unsigned int flags) {
-+static inline int missing_memfd_create(const char *name, unsigned int flags) {
- #  ifdef __NR_memfd_create
-         return syscall(__NR_memfd_create, name, flags);
- #  else
-@@ -76,6 +78,8 @@ static inline int memfd_create(const cha
-         return -1;
- #  endif
- }
-+
-+#  define memfd_create missing_memfd_create
- #endif
- 
- /* ======================================================================= */
-@@ -115,7 +119,7 @@ static inline int memfd_create(const cha
- #    endif
- #  endif
- 
--static inline int getrandom(void *buffer, size_t count, unsigned flags) {
-+static inline int missing_getrandom(void *buffer, size_t count, unsigned flags) {
- #  ifdef __NR_getrandom
-         return syscall(__NR_getrandom, buffer, count, flags);
- #  else
-@@ -123,14 +127,18 @@ static inline int getrandom(void *buffer
-         return -1;
- #  endif
- }
-+
-+#  define getrandom missing_getrandom
- #endif
- 
- /* ======================================================================= */
- 
- #if !HAVE_GETTID
--static inline pid_t gettid(void) {
-+static inline pid_t missing_gettid(void) {
-         return (pid_t) syscall(SYS_gettid);
- }
-+
-+#  define gettid missing_gettid
- #endif
- 
- /* ======================================================================= */
-@@ -158,7 +166,7 @@ struct file_handle {
-         unsigned char f_handle[0];
- };
- 
--static inline int name_to_handle_at(int fd, const char *name, struct file_handle *handle, int *mnt_id, int flags) {
-+static inline int missing_name_to_handle_at(int fd, const char *name, struct file_handle *handle, int *mnt_id, int flags) {
- #  ifdef __NR_name_to_handle_at
-         return syscall(__NR_name_to_handle_at, fd, name, handle, mnt_id, flags);
- #  else
-@@ -166,6 +174,8 @@ static inline int name_to_handle_at(int
-         return -1;
- #  endif
- }
-+
-+#  define name_to_handle_at missing_name_to_handle_at
- #endif
- 
- /* ======================================================================= */
-@@ -183,7 +193,7 @@ static inline int name_to_handle_at(int
- #    endif
- #  endif
- 
--static inline int setns(int fd, int nstype) {
-+static inline int missing_setns(int fd, int nstype) {
- #  ifdef __NR_setns
-         return syscall(__NR_setns, fd, nstype);
- #  else
-@@ -191,6 +201,8 @@ static inline int setns(int fd, int nsty
-         return -1;
- #  endif
- }
-+
-+#  define setns missing_setns
- #endif
- 
- /* ======================================================================= */
-@@ -236,7 +248,7 @@ static inline pid_t raw_getpid(void) {
- #    endif
- #  endif
- 
--static inline int renameat2(int oldfd, const char *oldname, int newfd, const char *newname, unsigned flags) {
-+static inline int missing_renameat2(int oldfd, const char *oldname, int newfd, const char *newname, unsigned flags) {
- #  ifdef __NR_renameat2
-         return syscall(__NR_renameat2, oldfd, oldname, newfd, newname, flags);
- #  else
-@@ -244,12 +256,14 @@ static inline int renameat2(int oldfd, c
-         return -1;
- #  endif
- }
-+
-+#  define renameat2 missing_renameat2
- #endif
- 
- /* ======================================================================= */
- 
- #if !HAVE_KCMP
--static inline int kcmp(pid_t pid1, pid_t pid2, int type, unsigned long idx1, unsigned long idx2) {
-+static inline int missing_kcmp(pid_t pid1, pid_t pid2, int type, unsigned long idx1, unsigned long idx2) {
- #  ifdef __NR_kcmp
-         return syscall(__NR_kcmp, pid1, pid2, type, idx1, idx2);
- #  else
-@@ -257,36 +271,44 @@ static inline int kcmp(pid_t pid1, pid_t
-         return -1;
- #  endif
- }
-+
-+#  define kcmp missing_kcmp
- #endif
- 
- /* ======================================================================= */
- 
- #if !HAVE_KEYCTL
--static inline long keyctl(int cmd, unsigned long arg2, unsigned long arg3, unsigned long arg4,unsigned long arg5) {
-+static inline long missing_keyctl(int cmd, unsigned long arg2, unsigned long arg3, unsigned long arg4,unsigned long arg5) {
- #  ifdef __NR_keyctl
-         return syscall(__NR_keyctl, cmd, arg2, arg3, arg4, arg5);
- #  else
-         errno = ENOSYS;
-         return -1;
- #  endif
-+
-+#  define keyctl missing_keyctl
- }
- 
--static inline key_serial_t add_key(const char *type, const char *description, const void *payload, size_t plen, key_serial_t ringid) {
-+static inline key_serial_t missing_add_key(const char *type, const char *description, const void *payload, size_t plen, key_serial_t ringid) {
- #  ifdef __NR_add_key
-         return syscall(__NR_add_key, type, description, payload, plen, ringid);
- #  else
-         errno = ENOSYS;
-         return -1;
- #  endif
-+
-+#  define add_key missing_add_key
- }
- 
--static inline key_serial_t request_key(const char *type, const char *description, const char * callout_info, key_serial_t destringid) {
-+static inline key_serial_t missing_request_key(const char *type, const char *description, const char * callout_info, key_serial_t destringid) {
- #  ifdef __NR_request_key
-         return syscall(__NR_request_key, type, description, callout_info, destringid);
- #  else
-         errno = ENOSYS;
-         return -1;
- #  endif
-+
-+#  define request_key missing_request_key
- }
- #endif
- 
-@@ -313,10 +335,10 @@ static inline key_serial_t request_key(c
- #    endif
- #  endif
- 
--static inline ssize_t copy_file_range(int fd_in, loff_t *off_in,
--                                      int fd_out, loff_t *off_out,
--                                      size_t len,
--                                      unsigned int flags) {
-+static inline ssize_t missing_copy_file_range(int fd_in, loff_t *off_in,
-+                                              int fd_out, loff_t *off_out,
-+                                              size_t len,
-+                                              unsigned int flags) {
- #  ifdef __NR_copy_file_range
-         return syscall(__NR_copy_file_range, fd_in, off_in, fd_out, off_out, len, flags);
- #  else
-@@ -324,6 +346,8 @@ static inline ssize_t copy_file_range(in
-         return -1;
- #  endif
- }
-+
-+#  define copy_file_range missing_copy_file_range
- #endif
- 
- /* ======================================================================= */
-@@ -351,7 +375,7 @@ static inline ssize_t copy_file_range(in
- 
- union bpf_attr;
- 
--static inline int bpf(int cmd, union bpf_attr *attr, size_t size) {
-+static inline int missing_bpf(int cmd, union bpf_attr *attr, size_t size) {
- #ifdef __NR_bpf
-         return (int) syscall(__NR_bpf, cmd, attr, size);
- #else
-@@ -360,6 +384,7 @@ static inline int bpf(int cmd, union bpf
- #endif
- }
- 
-+#  define bpf missing_bpf
- #endif
- 
- /* ======================================================================= */
diff --git a/poky/meta/recipes-core/systemd/systemd/0033-basic-macros-rename-noreturn-into-_noreturn_-8456.patch b/poky/meta/recipes-core/systemd/systemd/0033-basic-macros-rename-noreturn-into-_noreturn_-8456.patch
deleted file mode 100644
index 59647b2..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0033-basic-macros-rename-noreturn-into-_noreturn_-8456.patch
+++ /dev/null
@@ -1,203 +0,0 @@
-From 848e863acc51ecfb0f3955c498874588201d9130 Mon Sep 17 00:00:00 2001
-From: Franck Bui <fbui@suse.com>
-Date: Thu, 15 Mar 2018 06:23:46 +0100
-Subject: [PATCH] basic/macros: rename noreturn into _noreturn_ (#8456)
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-"noreturn" is reserved and can be used in other header files we include:
-
-  [   16s] In file included from /usr/include/gcrypt.h:30:0,
-  [   16s]                  from ../src/journal/journal-file.h:26,
-  [   16s]                  from ../src/journal/journal-vacuum.c:31:
-  [   16s] /usr/include/gpg-error.h:1544:46: error: expected ‘,’ or ‘;’ before ‘)’ token
-  [   16s]  void gpgrt_log_bug (const char *fmt, ...)    GPGRT_ATTR_NR_PRINTF(1,2);
-
-Here we include grcrypt.h (which in turns include gpg-error.h) *after* we
-"noreturn" was defined in macro.h.
----
- src/basic/log.c                         |  4 ++--
- src/basic/log.h                         |  4 ++--
- src/basic/macro.h                       | 19 +++++++++----------
- src/basic/process-util.c                |  2 +-
- src/basic/process-util.h                |  2 +-
- src/core/main.c                         |  4 ++--
- src/journal/test-journal-interleaving.c |  2 +-
- src/shared/pager.c                      |  2 +-
- src/udev/collect/collect.c              |  2 +-
- 9 files changed, 20 insertions(+), 21 deletions(-)
-
-Upstream-Status: Backport [https://github.com/systemd/systemd/pull/8456]
-
-diff --git a/src/basic/log.c b/src/basic/log.c
-index 7a7f2cbec..16a2431c5 100644
---- a/src/basic/log.c
-+++ b/src/basic/log.c
-@@ -814,7 +814,7 @@ static void log_assert(
-         log_dispatch_internal(level, 0, file, line, func, NULL, NULL, NULL, NULL, buffer);
- }
- 
--noreturn void log_assert_failed_realm(
-+_noreturn_ void log_assert_failed_realm(
-                 LogRealm realm,
-                 const char *text,
-                 const char *file,
-@@ -826,7 +826,7 @@ noreturn void log_assert_failed_realm(
-         abort();
- }
- 
--noreturn void log_assert_failed_unreachable_realm(
-+_noreturn_ void log_assert_failed_unreachable_realm(
-                 LogRealm realm,
-                 const char *text,
-                 const char *file,
-diff --git a/src/basic/log.h b/src/basic/log.h
-index efcf0f1bf..314be128a 100644
---- a/src/basic/log.h
-+++ b/src/basic/log.h
-@@ -186,7 +186,7 @@ int log_dump_internal(
-                 char *buffer);
- 
- /* Logging for various assertions */
--noreturn void log_assert_failed_realm(
-+_noreturn_ void log_assert_failed_realm(
-                 LogRealm realm,
-                 const char *text,
-                 const char *file,
-@@ -195,7 +195,7 @@ noreturn void log_assert_failed_realm(
- #define log_assert_failed(text, ...) \
-         log_assert_failed_realm(LOG_REALM, (text), __VA_ARGS__)
- 
--noreturn void log_assert_failed_unreachable_realm(
-+_noreturn_ void log_assert_failed_unreachable_realm(
-                 LogRealm realm,
-                 const char *text,
-                 const char *file,
-diff --git a/src/basic/macro.h b/src/basic/macro.h
-index 95be63a20..8911edfc4 100644
---- a/src/basic/macro.h
-+++ b/src/basic/macro.h
-@@ -53,6 +53,15 @@
- #else
- #define _fallthrough_
- #endif
-+/* Define C11 noreturn without <stdnoreturn.h> and even on older gcc
-+ * compiler versions */
-+#ifndef _noreturn_
-+#if __STDC_VERSION__ >= 201112L
-+#define _noreturn_ _Noreturn
-+#else
-+#define _noreturn_ __attribute__((noreturn))
-+#endif
-+#endif
- 
- /* Temporarily disable some warnings */
- #define DISABLE_WARNING_DECLARATION_AFTER_STATEMENT                     \
-@@ -414,16 +423,6 @@ static inline unsigned long ALIGN_POWER2(unsigned long u) {
- #endif
- #endif
- 
--/* Define C11 noreturn without <stdnoreturn.h> and even on older gcc
-- * compiler versions */
--#ifndef noreturn
--#if __STDC_VERSION__ >= 201112L
--#define noreturn _Noreturn
--#else
--#define noreturn __attribute__((noreturn))
--#endif
--#endif
--
- #define DEFINE_TRIVIAL_CLEANUP_FUNC(type, func)                 \
-         static inline void func##p(type *p) {                   \
-                 if (*p)                                         \
-diff --git a/src/basic/process-util.c b/src/basic/process-util.c
-index aa9846db5..e6120af5b 100644
---- a/src/basic/process-util.c
-+++ b/src/basic/process-util.c
-@@ -987,7 +987,7 @@ bool is_main_thread(void) {
-         return cached > 0;
- }
- 
--noreturn void freeze(void) {
-+_noreturn_ void freeze(void) {
- 
-         log_close();
- 
-diff --git a/src/basic/process-util.h b/src/basic/process-util.h
-index 93029e36e..5170adec7 100644
---- a/src/basic/process-util.h
-+++ b/src/basic/process-util.h
-@@ -91,7 +91,7 @@ int pid_from_same_root_fs(pid_t pid);
- 
- bool is_main_thread(void);
- 
--noreturn void freeze(void);
-+_noreturn_ void freeze(void);
- 
- bool oom_score_adjust_is_valid(int oa);
- 
-diff --git a/src/core/main.c b/src/core/main.c
-index 076846a41..4b2d14923 100644
---- a/src/core/main.c
-+++ b/src/core/main.c
-@@ -141,7 +141,7 @@ static uint64_t arg_default_tasks_max = UINT64_MAX;
- static sd_id128_t arg_machine_id = {};
- static EmergencyAction arg_cad_burst_action = EMERGENCY_ACTION_REBOOT_FORCE;
- 
--noreturn static void freeze_or_reboot(void) {
-+_noreturn_ static void freeze_or_reboot(void) {
- 
-         if (arg_crash_reboot) {
-                 log_notice("Rebooting in 10s...");
-@@ -156,7 +156,7 @@ noreturn static void freeze_or_reboot(void) {
-         freeze();
- }
- 
--noreturn static void crash(int sig) {
-+_noreturn_ static void crash(int sig) {
-         struct sigaction sa;
-         pid_t pid;
- 
-diff --git a/src/journal/test-journal-interleaving.c b/src/journal/test-journal-interleaving.c
-index 5a88b2774..d87bdbdd3 100644
---- a/src/journal/test-journal-interleaving.c
-+++ b/src/journal/test-journal-interleaving.c
-@@ -37,7 +37,7 @@
- 
- static bool arg_keep = false;
- 
--noreturn static void log_assert_errno(const char *text, int error, const char *file, int line, const char *func) {
-+_noreturn_ static void log_assert_errno(const char *text, int error, const char *file, int line, const char *func) {
-         log_internal(LOG_CRIT, error, file, line, func,
-                      "'%s' failed at %s:%u (%s): %m", text, file, line, func);
-         abort();
-diff --git a/src/shared/pager.c b/src/shared/pager.c
-index 75db3c985..681af9c40 100644
---- a/src/shared/pager.c
-+++ b/src/shared/pager.c
-@@ -47,7 +47,7 @@ static int stored_stderr = -1;
- static bool stdout_redirected = false;
- static bool stderr_redirected = false;
- 
--noreturn static void pager_fallback(void) {
-+_noreturn_ static void pager_fallback(void) {
-         int r;
- 
-         r = copy_bytes(STDIN_FILENO, STDOUT_FILENO, (uint64_t) -1, 0);
-diff --git a/src/udev/collect/collect.c b/src/udev/collect/collect.c
-index 2821640e9..c8fa47b3d 100644
---- a/src/udev/collect/collect.c
-+++ b/src/udev/collect/collect.c
-@@ -58,7 +58,7 @@ static inline struct _mate *node_to_mate(struct udev_list_node *node)
-         return container_of(node, struct _mate, node);
- }
- 
--noreturn static void sig_alrm(int signo)
-+_noreturn_ static void sig_alrm(int signo)
- {
-         exit(4);
- }
--- 
-2.17.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0034-Fix-format-truncation-compile-failure-by-typecasting.patch b/poky/meta/recipes-core/systemd/systemd/0034-Fix-format-truncation-compile-failure-by-typecasting.patch
deleted file mode 100644
index e56061f..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0034-Fix-format-truncation-compile-failure-by-typecasting.patch
+++ /dev/null
@@ -1,173 +0,0 @@
-From c2b3ebe112ebfd9f9e82fb1531ee225c3152ca83 Mon Sep 17 00:00:00 2001
-From: Patrick Uiterwijk <patrick@puiterwijk.org>
-Date: Thu, 22 Feb 2018 19:41:30 +0100
-Subject: [PATCH] Fix format-truncation compile failure by typecasting USB IDs
- (#8250)
-
-This patch adds safe_atoux16 for parsing an unsigned hexadecimal 16bit int, and
-uses that for parsing USB device and vendor IDs.
-
-This fixes a compile error with gcc-8 because while we know that USB IDs are 2 bytes,
-the compiler does not know that.
-
-../src/udev/udev-builtin-hwdb.c:80:38: error: '%04X' directive output may be
-truncated writing between 4 and 8 bytes into a region of size between 2 and 6
-[-Werror=format-truncation=]
-
-Upstream-Status: Backport [https://github.com/systemd/systemd/commit/5547c12503a683290eaed47954ffcfb2d1bc03cd]
-
-Signed-off-by: Adam Williamson <awilliam@redhat.com>
-Signed-off-by: Patrick Uiterwijk <puiterwijk@redhat.com>
----
- src/basic/parse-util.c       | 24 ++++++++++++++++++++++
- src/basic/parse-util.h       |  2 ++
- src/test/test-parse-util.c   | 39 ++++++++++++++++++++++++++++++++++++
- src/udev/udev-builtin-hwdb.c | 13 ++++++------
- 4 files changed, 71 insertions(+), 7 deletions(-)
-
-diff --git a/src/basic/parse-util.c b/src/basic/parse-util.c
-index 97533721d..ff3fc298a 100644
---- a/src/basic/parse-util.c
-+++ b/src/basic/parse-util.c
-@@ -532,6 +532,30 @@ int safe_atoi16(const char *s, int16_t *ret) {
-         return 0;
- }
- 
-+int safe_atoux16(const char *s, uint16_t *ret) {
-+        char *x = NULL;
-+        unsigned long l;
-+
-+        assert(s);
-+        assert(ret);
-+
-+        s += strspn(s, WHITESPACE);
-+
-+        errno = 0;
-+        l = strtoul(s, &x, 16);
-+        if (errno > 0)
-+                return -errno;
-+        if (!x || x == s || *x != 0)
-+                return -EINVAL;
-+        if (s[0] == '-')
-+                return -ERANGE;
-+        if ((unsigned long) (uint16_t) l != l)
-+                return -ERANGE;
-+
-+        *ret = (uint16_t) l;
-+        return 0;
-+}
-+
- int safe_atod(const char *s, double *ret_d) {
-         _cleanup_(freelocalep) locale_t loc = (locale_t) 0;
-         char *x = NULL;
-diff --git a/src/basic/parse-util.h b/src/basic/parse-util.h
-index 1eda1d7f9..727422056 100644
---- a/src/basic/parse-util.h
-+++ b/src/basic/parse-util.h
-@@ -54,6 +54,8 @@ int safe_atou8(const char *s, uint8_t *ret);
- int safe_atou16(const char *s, uint16_t *ret);
- int safe_atoi16(const char *s, int16_t *ret);
- 
-+int safe_atoux16(const char *s, uint16_t *ret);
-+
- static inline int safe_atou32(const char *s, uint32_t *ret_u) {
-         assert_cc(sizeof(uint32_t) == sizeof(unsigned));
-         return safe_atou(s, (unsigned*) ret_u);
-diff --git a/src/test/test-parse-util.c b/src/test/test-parse-util.c
-index 937500213..a99cea5a1 100644
---- a/src/test/test-parse-util.c
-+++ b/src/test/test-parse-util.c
-@@ -468,6 +468,44 @@ static void test_safe_atoi16(void) {
-         assert_se(r == -EINVAL);
- }
- 
-+static void test_safe_atoux16(void) {
-+        int r;
-+        uint16_t l;
-+
-+        r = safe_atoux16("1234", &l);
-+        assert_se(r == 0);
-+        assert_se(l == 0x1234);
-+
-+        r = safe_atoux16("abcd", &l);
-+        assert_se(r == 0);
-+        assert_se(l == 0xabcd);
-+
-+        r = safe_atoux16("  1234", &l);
-+        assert_se(r == 0);
-+        assert_se(l == 0x1234);
-+
-+        r = safe_atoux16("12345", &l);
-+        assert_se(r == -ERANGE);
-+
-+        r = safe_atoux16("-1", &l);
-+        assert_se(r == -ERANGE);
-+
-+        r = safe_atoux16("  -1", &l);
-+        assert_se(r == -ERANGE);
-+
-+        r = safe_atoux16("junk", &l);
-+        assert_se(r == -EINVAL);
-+
-+        r = safe_atoux16("123x", &l);
-+        assert_se(r == -EINVAL);
-+
-+        r = safe_atoux16("12.3", &l);
-+        assert_se(r == -EINVAL);
-+
-+        r = safe_atoux16("", &l);
-+        assert_se(r == -EINVAL);
-+}
-+
- static void test_safe_atou64(void) {
-         int r;
-         uint64_t l;
-@@ -745,6 +783,7 @@ int main(int argc, char *argv[]) {
-         test_safe_atolli();
-         test_safe_atou16();
-         test_safe_atoi16();
-+        test_safe_atoux16();
-         test_safe_atou64();
-         test_safe_atoi64();
-         test_safe_atod();
-diff --git a/src/udev/udev-builtin-hwdb.c b/src/udev/udev-builtin-hwdb.c
-index ca7f7c230..dbfe02429 100644
---- a/src/udev/udev-builtin-hwdb.c
-+++ b/src/udev/udev-builtin-hwdb.c
-@@ -27,6 +27,7 @@
- 
- #include "alloc-util.h"
- #include "hwdb-util.h"
-+#include "parse-util.h"
- #include "string-util.h"
- #include "udev-util.h"
- #include "udev.h"
-@@ -63,7 +64,7 @@ int udev_builtin_hwdb_lookup(struct udev_device *dev,
- 
- static const char *modalias_usb(struct udev_device *dev, char *s, size_t size) {
-         const char *v, *p;
--        int vn, pn;
-+        uint16_t vn, pn;
- 
-         v = udev_device_get_sysattr_value(dev, "idVendor");
-         if (!v)
-@@ -71,12 +72,10 @@ static const char *modalias_usb(struct udev_device *dev, char *s, size_t size) {
-         p = udev_device_get_sysattr_value(dev, "idProduct");
-         if (!p)
-                 return NULL;
--        vn = strtol(v, NULL, 16);
--        if (vn <= 0)
--                return NULL;
--        pn = strtol(p, NULL, 16);
--        if (pn <= 0)
--                return NULL;
-+        if (safe_atoux16(v, &vn) < 0)
-+		return NULL;
-+        if (safe_atoux16(p, &pn) < 0)
-+		return NULL;
-         snprintf(s, size, "usb:v%04Xp%04X*", vn, pn);
-         return s;
- }
--- 
-2.17.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/0035-Define-glibc-compatible-basename-for-non-glibc-syste.patch b/poky/meta/recipes-core/systemd/systemd/0035-Define-glibc-compatible-basename-for-non-glibc-syste.patch
deleted file mode 100644
index 736d525..0000000
--- a/poky/meta/recipes-core/systemd/systemd/0035-Define-glibc-compatible-basename-for-non-glibc-syste.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 5f1f064c81ea30acf93cfa0fb466b38f094f488c Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 27 May 2018 08:36:44 -0700
-Subject: [PATCH] Define glibc compatible basename() for non-glibc systems
-
-Fixes builds with musl, even though systemd is adamant about
-using non-posix basename implementation, we have a way out
-
-Upstream-Status: Inappropriate [musl specific]
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/machine/machine-dbus.c | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/src/machine/machine-dbus.c b/src/machine/machine-dbus.c
-index 2d7806491b..9a3bdb1d76 100644
---- a/src/machine/machine-dbus.c
-+++ b/src/machine/machine-dbus.c
-@@ -29,6 +29,10 @@
- #include <libgen.h>
- #undef basename
- 
-+#if !defined(__GLIBC__)
-+#define basename(src) (strrchr(src,'/') ? strrchr(src,'/')+1 : src)
-+#endif
-+
- #include "alloc-util.h"
- #include "bus-common-errors.h"
- #include "bus-internal.h"
--- 
-2.17.0
-
diff --git a/poky/meta/recipes-core/systemd/systemd/libmount.patch b/poky/meta/recipes-core/systemd/systemd/libmount.patch
deleted file mode 100644
index b59d5b7..0000000
--- a/poky/meta/recipes-core/systemd/systemd/libmount.patch
+++ /dev/null
@@ -1,75 +0,0 @@
-Upstream-Status: Backport
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
-From 227b8a762fea1458547be2cdf0e6e4aac0079730 Mon Sep 17 00:00:00 2001
-From: Michael Olbrich <m.olbrich@pengutronix.de>
-Date: Mon, 26 Mar 2018 17:34:53 +0200
-Subject: [PATCH] core: don't include libmount.h in a header file (#8580)
-
-linux/fs.h sys/mount.h, libmount.h and missing.h all include MS_*
-definitions.
-
-To avoid problems, only one of linux/fs.h, sys/mount.h and libmount.h
-should be included. And missing.h must be included last.
-
-Without this, building systemd may fail with:
-
-In file included from [...]/libmount/libmount.h:31:0,
-                 from ../systemd-238/src/core/manager.h:23,
-                 from ../systemd-238/src/core/emergency-action.h:37,
-                 from ../systemd-238/src/core/unit.h:34,
-                 from ../systemd-238/src/core/dbus-timer.h:25,
-                 from ../systemd-238/src/core/timer.c:26:
-[...]/sys/mount.h:57:2: error: expected identifier before numeric constant
----
- src/core/dbus-execute.c | 1 +
- src/core/manager.h      | 3 ++-
- src/core/mount.c        | 2 ++
- 3 files changed, 5 insertions(+), 1 deletion(-)
-
-diff --git a/src/core/dbus-execute.c b/src/core/dbus-execute.c
-index 7344623ebf6..c342093bca4 100644
---- a/src/core/dbus-execute.c
-+++ b/src/core/dbus-execute.c
-@@ -18,6 +18,7 @@
-   along with systemd; If not, see <http://www.gnu.org/licenses/>.
- ***/
- 
-+#include <sys/mount.h>
- #include <sys/prctl.h>
- #include <stdio_ext.h>
- 
-diff --git a/src/core/manager.h b/src/core/manager.h
-index 28c5da225b1..e09e0cdf5e9 100644
---- a/src/core/manager.h
-+++ b/src/core/manager.h
-@@ -20,7 +20,6 @@
-   along with systemd; If not, see <http://www.gnu.org/licenses/>.
- ***/
- 
--#include <libmount.h>
- #include <stdbool.h>
- #include <stdio.h>
- 
-@@ -34,6 +33,8 @@
- #include "list.h"
- #include "ratelimit.h"
- 
-+struct libmnt_monitor;
-+
- /* Enforce upper limit how many names we allow */
- #define MANAGER_MAX_NAMES 131072 /* 128K */
- 
-diff --git a/src/core/mount.c b/src/core/mount.c
-index 0e755da5c02..0154ebda5d6 100644
---- a/src/core/mount.c
-+++ b/src/core/mount.c
-@@ -23,6 +23,8 @@
- #include <stdio.h>
- #include <sys/epoll.h>
- 
-+#include <libmount.h>
-+
- #include "sd-messages.h"
- 
- #include "alloc-util.h"
diff --git a/poky/meta/recipes-core/systemd/systemd_237.bb b/poky/meta/recipes-core/systemd/systemd_237.bb
deleted file mode 100644
index a409b18..0000000
--- a/poky/meta/recipes-core/systemd/systemd_237.bb
+++ /dev/null
@@ -1,595 +0,0 @@
-require systemd.inc
-
-PROVIDES = "udev"
-
-PE = "1"
-
-DEPENDS = "kmod intltool-native gperf-native acl readline libcap libcgroup util-linux"
-
-SECTION = "base/shell"
-
-inherit useradd pkgconfig meson perlnative update-rc.d update-alternatives qemu systemd gettext bash-completion manpages distro_features_check
-
-# As this recipe builds udev, respect systemd being in DISTRO_FEATURES so
-# that we don't build both udev and systemd in world builds.
-REQUIRED_DISTRO_FEATURES = "systemd"
-
-SRC_URI += "file://touchscreen.rules \
-           file://00-create-volatile.conf \
-           file://init \
-           file://0001-Hide-__start_BUS_ERROR_MAP-and-__stop_BUS_ERROR_MAP.patch \
-           file://0001-Use-getenv-when-secure-versions-are-not-available.patch \
-           file://0002-binfmt-Don-t-install-dependency-links-at-install-tim.patch \
-           file://0003-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch \
-           file://0004-implment-systemd-sysv-install-for-OE.patch \
-           file://0005-rules-whitelist-hd-devices.patch \
-           file://0006-Make-root-s-home-directory-configurable.patch \
-           file://0007-Revert-rules-remove-firmware-loading-rules.patch \
-           file://0008-Revert-udev-remove-userspace-firmware-loading-suppor.patch \
-           file://0009-remove-duplicate-include-uchar.h.patch \
-           file://0010-check-for-uchar.h-in-meson.build.patch \
-           file://0011-socket-util-don-t-fail-if-libc-doesn-t-support-IDN.patch \
-           file://0012-rules-watch-metadata-changes-in-ide-devices.patch \
-           file://0013-add-fallback-parse_printf_format-implementation.patch \
-           file://0014-src-basic-missing.h-check-for-missing-strndupa.patch \
-           file://0015-don-t-fail-if-GLOB_BRACE-and-GLOB_ALTDIRFUNC-is-not-.patch \
-           file://0016-src-basic-missing.h-check-for-missing-__compar_fn_t-.patch \
-           file://0017-Include-netinet-if_ether.h.patch \
-           file://0018-check-for-missing-canonicalize_file_name.patch \
-           file://0019-Do-not-enable-nss-tests-if-nss-systemd-is-not-enable.patch \
-           file://0020-test-hexdecoct.c-Include-missing.h-for-strndupa.patch \
-           file://0021-test-sizeof.c-Disable-tests-for-missing-typedefs-in-.patch \
-           file://0022-don-t-use-glibc-specific-qsort_r.patch \
-           file://0023-don-t-pass-AT_SYMLINK_NOFOLLOW-flag-to-faccessat.patch \
-           file://0024-comparison_fn_t-is-glibc-specific-use-raw-signature-.patch \
-           file://0025-Define-_PATH_WTMPX-and-_PATH_UTMPX-if-not-defined.patch \
-           file://0026-Use-uintmax_t-for-handling-rlim_t.patch \
-           file://0027-remove-nobody-user-group-checking.patch \
-           file://0028-add-missing-FTW_-macros-for-musl.patch \
-           file://0029-nss-mymachines-Build-conditionally-when-ENABLE_MYHOS.patch \
-           file://0030-fix-missing-of-__register_atfork-for-non-glibc-build.patch \
-           file://0031-fix-missing-ULONG_LONG_MAX-definition-in-case-of-mus.patch \
-           file://0032-memfd.patch \
-           file://0033-basic-macros-rename-noreturn-into-_noreturn_-8456.patch \
-           file://libmount.patch \
-           file://0034-Fix-format-truncation-compile-failure-by-typecasting.patch \
-           file://0035-Define-glibc-compatible-basename-for-non-glibc-syste.patch \
-           "
-SRC_URI_append_qemuall = " file://0001-core-device.c-Change-the-default-device-timeout-to-2.patch"
-
-# Workaround undefined reference to `__stack_chk_fail_local' on qemux86 and qemuppc for musl
-SRC_URI_append_libc-musl_qemux86 = " file://0001-Remove-fstack-protector-flags-to-workaround-musl-bui.patch"
-SRC_URI_append_libc-musl_qemuppc = " file://0001-Remove-fstack-protector-flags-to-workaround-musl-bui.patch"
-
-PAM_PLUGINS = " \
-    pam-plugin-unix \
-    pam-plugin-loginuid \
-    pam-plugin-keyinit \
-"
-
-PACKAGECONFIG ??= " \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'efi ldconfig pam selinux usrmerge', d)} \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'wifi', 'rfkill', '', d)} \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'xkbcommon', '', d)} \
-    backlight \
-    binfmt \
-    firstboot \
-    hibernate \
-    hostnamed \
-    ima \
-    localed \
-    logind \
-    machined \
-    myhostname \
-    networkd \
-    nss \
-    polkit \
-    quotacheck \
-    randomseed \
-    resolved \
-    smack \
-    sysusers \
-    timedated \
-    timesyncd \
-    utmp \
-    vconsole \
-    xz \
-"
-
-PACKAGECONFIG_remove_libc-musl = " \
-    localed \
-    myhostname \
-    nss \
-    resolved \
-    selinux \
-    smack \
-    sysusers \
-    utmp \
-"
-
-# Use the upstream systemd serial-getty@.service and rely on
-# systemd-getty-generator instead of using the OE-core specific
-# systemd-serialgetty.bb - not enabled by default.
-PACKAGECONFIG[serial-getty-generator] = ""
-
-PACKAGECONFIG[audit] = "-Daudit=true,-Daudit=false,audit"
-PACKAGECONFIG[backlight] = "-Dbacklight=true,-Dbacklight=false"
-PACKAGECONFIG[binfmt] = "-Dbinfmt=true,-Dbinfmt=false"
-PACKAGECONFIG[bzip2] = "-Dbzip2=true,-Dbzip2=false,bzip2"
-PACKAGECONFIG[coredump] = "-Dcoredump=true,-Dcoredump=false"
-PACKAGECONFIG[cryptsetup] = "-Dlibcryptsetup=true,-Dlibcryptsetup=false,cryptsetup"
-PACKAGECONFIG[dbus] = "-Ddbus=true,-Ddbus=false,dbus"
-PACKAGECONFIG[efi] = "-Defi=true,-Defi=false"
-PACKAGECONFIG[elfutils] = "-Delfutils=true,-Delfutils=false,elfutils"
-PACKAGECONFIG[firstboot] = "-Dfirstboot=true,-Dfirstboot=false"
-# Sign the journal for anti-tampering
-PACKAGECONFIG[gcrypt] = "-Dgcrypt=true,-Dgcrypt=false,libgcrypt"
-PACKAGECONFIG[hibernate] = "-Dhibernate=true,-Dhibernate=false"
-PACKAGECONFIG[hostnamed] = "-Dhostnamed=true,-Dhostnamed=false"
-PACKAGECONFIG[ima] = "-Dima=true,-Dima=false"
-# importd requires curl/xz/zlib/bzip2/gcrypt
-PACKAGECONFIG[importd] = "-Dimportd=true,-Dimportd=false"
-# Update NAT firewall rules
-PACKAGECONFIG[iptc] = "-Dlibiptc=true,-Dlibiptc=false,iptables"
-PACKAGECONFIG[journal-upload] = "-Dlibcurl=true,-Dlibcurl=false,curl"
-PACKAGECONFIG[ldconfig] = "-Dldconfig=true,-Dldconfig=false"
-PACKAGECONFIG[libidn] = "-Dlibidn=true,-Dlibidn=false,libidn"
-PACKAGECONFIG[localed] = "-Dlocaled=true,-Dlocaled=false"
-PACKAGECONFIG[logind] = "-Dlogind=true,-Dlogind=false"
-PACKAGECONFIG[lz4] = "-Dlz4=true,-Dlz4=false,lz4"
-PACKAGECONFIG[machined] = "-Dmachined=true,-Dmachined=false"
-PACKAGECONFIG[manpages] = "-Dman=true,-Dman=false,libxslt-native xmlto-native docbook-xml-dtd4-native docbook-xsl-stylesheets-native"
-PACKAGECONFIG[microhttpd] = "-Dmicrohttpd=true,-Dmicrohttpd=false,libmicrohttpd"
-PACKAGECONFIG[myhostname] = "-Dmyhostname=true,-Dmyhostname=false"
-PACKAGECONFIG[networkd] = "-Dnetworkd=true,-Dnetworkd=false"
-PACKAGECONFIG[nss] = "-Dnss-systemd=true,-Dnss-systemd=false"
-PACKAGECONFIG[pam] = "-Dpam=true,-Dpam=false,libpam,${PAM_PLUGINS}"
-PACKAGECONFIG[polkit] = "-Dpolkit=true,-Dpolkit=false"
-PACKAGECONFIG[qrencode] = "-Dqrencode=true,-Dqrencode=false,qrencode"
-PACKAGECONFIG[quotacheck] = "-Dquotacheck=true,-Dquotacheck=false"
-PACKAGECONFIG[randomseed] = "-Drandomseed=true,-Drandomseed=false"
-PACKAGECONFIG[resolved] = "-Dresolve=true,-Dresolve=false"
-PACKAGECONFIG[rfkill] = "-Drfkill=true,-Drfkill=false"
-# libseccomp is found in meta-security
-PACKAGECONFIG[seccomp] = "-Dseccomp=true,-Dseccomp=false,libseccomp"
-PACKAGECONFIG[selinux] = "-Dselinux=true,-Dselinux=false,libselinux,initscripts-sushell"
-PACKAGECONFIG[smack] = "-Dsmack=true,-Dsmack=false"
-PACKAGECONFIG[sysusers] = "-Dsysusers=true,-Dsysusers=false"
-PACKAGECONFIG[timedated] = "-Dtimedated=true,-Dtimedated=false"
-PACKAGECONFIG[timesyncd] = "-Dtimesyncd=true,-Dtimesyncd=false"
-PACKAGECONFIG[usrmerge] = "-Dsplit-usr=false,-Dsplit-usr=true"
-PACKAGECONFIG[utmp] = "-Dutmp=true,-Dutmp=false"
-PACKAGECONFIG[valgrind] = "-DVALGRIND=1,,valgrind"
-PACKAGECONFIG[vconsole] = "-Dvconsole=true,-Dvconsole=false,,${PN}-vconsole-setup"
-# Verify keymaps on locale change
-PACKAGECONFIG[xkbcommon] = "-Dxkbcommon=true,-Dxkbcommon=false,libxkbcommon"
-PACKAGECONFIG[xz] = "-Dxz=true,-Dxz=false,xz"
-PACKAGECONFIG[zlib] = "-Dzlib=true,-Dzlib=false,zlib"
-
-# Helper variables to clarify locations.  This mirrors the logic in systemd's
-# build system.
-rootprefix ?= "${root_prefix}"
-rootlibdir ?= "${base_libdir}"
-rootlibexecdir = "${rootprefix}/lib"
-
-# This links udev statically with systemd helper library.
-# Otherwise udev package would depend on systemd package (which has the needed shared library),
-# and always pull it into images.
-EXTRA_OEMESON += "-Dlink-udev-shared=false"
-
-EXTRA_OEMESON += "-Dnobody-user=nobody \
-                  -Dnobody-group=nobody \
-                  -Droothomedir=${ROOTHOME} \
-                  -Drootlibdir=${rootlibdir} \
-                  -Drootprefix=${rootprefix} \
-                  -Dsysvrcnd-path=${sysconfdir} \
-                  -Dfirmware-path=${nonarch_base_libdir}/firmware \
-                  "
-
-# Hardcode target binary paths to avoid using paths from sysroot
-EXTRA_OEMESON += "-Dkexec-path=${sbindir}/kexec \
-                  -Dkill-path=${base_bindir}/kill \
-                  -Dkmod-path=${base_bindir}/kmod \
-                  -Dmount-path=${base_bindir}/mount \
-                  -Dquotacheck-path=${sbindir}/quotacheck \
-                  -Dquotaon-path=${sbindir}/quotaon \
-                  -Dsulogin-path=${base_sbindir}/sulogin \
-                  -Dumount-path=${base_bindir}/umount"
-
-do_install() {
-	meson_do_install
-	install -d ${D}/${base_sbindir}
-	if ${@bb.utils.contains('PACKAGECONFIG', 'serial-getty-generator', 'false', 'true', d)}; then
-		# Provided by a separate recipe
-		rm ${D}${systemd_unitdir}/system/serial-getty* -f
-	fi
-
-	# Provide support for initramfs
-	[ ! -e ${D}/init ] && ln -s ${rootlibexecdir}/systemd/systemd ${D}/init
-	[ ! -e ${D}/${base_sbindir}/udevd ] && ln -s ${rootlibexecdir}/systemd/systemd-udevd ${D}/${base_sbindir}/udevd
-
-	# Create machine-id
-	# 20:12 < mezcalero> koen: you have three options: a) run systemd-machine-id-setup at install time, b) have / read-only and an empty file there (for stateless) and c) boot with / writable
-	touch ${D}${sysconfdir}/machine-id
-
-	install -d ${D}${sysconfdir}/udev/rules.d/
-	install -d ${D}${sysconfdir}/tmpfiles.d
-	install -m 0644 ${WORKDIR}/*.rules ${D}${sysconfdir}/udev/rules.d/
-	install -d ${D}${libdir}/pkgconfig
-	install -m 0644 ${B}/src/udev/udev.pc ${D}${libdir}/pkgconfig/
-
-	install -m 0644 ${WORKDIR}/00-create-volatile.conf ${D}${sysconfdir}/tmpfiles.d/
-
-	if ${@bb.utils.contains('DISTRO_FEATURES','sysvinit','true','false',d)}; then
-		install -d ${D}${sysconfdir}/init.d
-		install -m 0755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/systemd-udevd
-		sed -i s%@UDEVD@%${rootlibexecdir}/systemd/systemd-udevd% ${D}${sysconfdir}/init.d/systemd-udevd
-	fi
-
-	chown root:systemd-journal ${D}/${localstatedir}/log/journal
-
-	# Delete journal README, as log can be symlinked inside volatile.
-	rm -f ${D}/${localstatedir}/log/README
-
-	install -d ${D}${systemd_unitdir}/system/graphical.target.wants
-	install -d ${D}${systemd_unitdir}/system/multi-user.target.wants
-	install -d ${D}${systemd_unitdir}/system/poweroff.target.wants
-	install -d ${D}${systemd_unitdir}/system/reboot.target.wants
-	install -d ${D}${systemd_unitdir}/system/rescue.target.wants
-
-	# Create symlinks for systemd-update-utmp-runlevel.service
-	if ${@bb.utils.contains('PACKAGECONFIG', 'utmp', 'true', 'false', d)}; then
-		ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_unitdir}/system/graphical.target.wants/systemd-update-utmp-runlevel.service
-		ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_unitdir}/system/multi-user.target.wants/systemd-update-utmp-runlevel.service
-		ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_unitdir}/system/poweroff.target.wants/systemd-update-utmp-runlevel.service
-		ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_unitdir}/system/reboot.target.wants/systemd-update-utmp-runlevel.service
-		ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_unitdir}/system/rescue.target.wants/systemd-update-utmp-runlevel.service
-	fi
-
-	# Enable journal to forward message to syslog daemon
-	sed -i -e 's/.*ForwardToSyslog.*/ForwardToSyslog=yes/' ${D}${sysconfdir}/systemd/journald.conf
-	# Set the maximium size of runtime journal to 64M as default
-	sed -i -e 's/.*RuntimeMaxUse.*/RuntimeMaxUse=64M/' ${D}${sysconfdir}/systemd/journald.conf
-
-	# this file is needed to exist if networkd is disabled but timesyncd is still in use since timesyncd checks it
-	# for existence else it fails
-	if [ -s ${D}${exec_prefix}/lib/tmpfiles.d/systemd.conf ]; then
-		${@bb.utils.contains('PACKAGECONFIG', 'networkd', ':', 'sed -i -e "\$ad /run/systemd/netif/links 0755 root root -" ${D}${exec_prefix}/lib/tmpfiles.d/systemd.conf', d)}
-	fi
-	if ! ${@bb.utils.contains('PACKAGECONFIG', 'resolved', 'true', 'false', d)}; then
-		echo 'L! ${sysconfdir}/resolv.conf - - - - ../run/systemd/resolve/resolv.conf' >>${D}${exec_prefix}/lib/tmpfiles.d/etc.conf
-		echo 'd /run/systemd/resolve 0755 root root -' >>${D}${exec_prefix}/lib/tmpfiles.d/systemd.conf
-		echo 'f /run/systemd/resolve/resolv.conf 0644 root root' >>${D}${exec_prefix}/lib/tmpfiles.d/systemd.conf
-		ln -s ../run/systemd/resolve/resolv.conf ${D}${sysconfdir}/resolv-conf.systemd
-	else
-		sed -i -e "s%^L! /etc/resolv.conf.*$%L! /etc/resolv.conf - - - - ../run/systemd/resolve/resolv.conf%g" ${D}${exec_prefix}/lib/tmpfiles.d/etc.conf
-		ln -s ../run/systemd/resolve/resolv.conf ${D}${sysconfdir}/resolv-conf.systemd
-	fi
-	install -Dm 0755 ${S}/src/systemctl/systemd-sysv-install.SKELETON ${D}${systemd_unitdir}/systemd-sysv-install
-
-	# If polkit is setup fixup permissions and ownership
-	if ${@bb.utils.contains('PACKAGECONFIG', 'polkit', 'true', 'false', d)}; then
-		if [ -d ${D}${datadir}/polkit-1/rules.d ]; then
-			chmod 700 ${D}${datadir}/polkit-1/rules.d
-			chown polkitd:root ${D}${datadir}/polkit-1/rules.d
-		fi
-	fi
-}
-
-
-python populate_packages_prepend (){
-    systemdlibdir = d.getVar("rootlibdir")
-    do_split_packages(d, systemdlibdir, '^lib(.*)\.so\.*', 'lib%s', 'Systemd %s library', extra_depends='', allow_links=True)
-}
-PACKAGES_DYNAMIC += "^lib(udev|systemd|nss).*"
-
-PACKAGES =+ "\
-    ${PN}-gui \
-    ${PN}-vconsole-setup \
-    ${PN}-initramfs \
-    ${PN}-analyze \
-    ${PN}-kernel-install \
-    ${PN}-rpm-macros \
-    ${PN}-binfmt \
-    ${PN}-zsh-completion \
-    ${PN}-xorg-xinitrc \
-    ${PN}-container \
-    ${PN}-extra-utils \
-"
-
-SUMMARY_${PN}-container = "Tools for containers and VMs"
-DESCRIPTION_${PN}-container = "Systemd tools to spawn and manage containers and virtual machines."
-
-SYSTEMD_PACKAGES = "${@bb.utils.contains('PACKAGECONFIG', 'binfmt', '${PN}-binfmt', '', d)}"
-SYSTEMD_SERVICE_${PN}-binfmt = "systemd-binfmt.service"
-
-USERADD_PACKAGES = "${PN} ${PN}-extra-utils"
-USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'microhttpd', '--system -d / -M --shell /bin/nologin systemd-journal-gateway;', '', d)}"
-USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'microhttpd', '--system -d / -M --shell /bin/nologin systemd-journal-remote;', '', d)}"
-USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'journal-upload', '--system -d / -M --shell /bin/nologin systemd-journal-upload;', '', d)}"
-USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'timesyncd', '--system -d / -M --shell /bin/nologin systemd-timesync;', '', d)}"
-USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'networkd', '--system -d / -M --shell /bin/nologin systemd-network;', '', d)}"
-USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'coredump', '--system -d / -M --shell /bin/nologin systemd-coredump;', '', d)}"
-USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'resolved', '--system -d / -M --shell /bin/nologin systemd-resolve;', '', d)}"
-USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'polkit', '--system --no-create-home --user-group --home-dir ${sysconfdir}/polkit-1 polkitd;', '', d)}"
-GROUPADD_PARAM_${PN} = "-r systemd-journal"
-USERADD_PARAM_${PN}-extra-utils += "--system -d / -M --shell /bin/nologin systemd-bus-proxy;"
-
-FILES_${PN}-analyze = "${bindir}/systemd-analyze"
-
-FILES_${PN}-initramfs = "/init"
-RDEPENDS_${PN}-initramfs = "${PN}"
-
-FILES_${PN}-gui = "${bindir}/systemadm"
-
-FILES_${PN}-vconsole-setup = "${rootlibexecdir}/systemd/systemd-vconsole-setup \
-                              ${systemd_unitdir}/system/systemd-vconsole-setup.service \
-                              ${systemd_unitdir}/system/sysinit.target.wants/systemd-vconsole-setup.service"
-
-RDEPENDS_${PN}-kernel-install += "bash"
-FILES_${PN}-kernel-install = "${bindir}/kernel-install \
-                              ${sysconfdir}/kernel/ \
-                              ${exec_prefix}/lib/kernel \
-                             "
-FILES_${PN}-rpm-macros = "${exec_prefix}/lib/rpm \
-                         "
-
-FILES_${PN}-xorg-xinitrc = "${sysconfdir}/X11/xinit/xinitrc.d/*"
-
-FILES_${PN}-zsh-completion = "${datadir}/zsh/site-functions"
-
-FILES_${PN}-binfmt = "${sysconfdir}/binfmt.d/ \
-                      ${exec_prefix}/lib/binfmt.d \
-                      ${rootlibexecdir}/systemd/systemd-binfmt \
-                      ${systemd_unitdir}/system/proc-sys-fs-binfmt_misc.* \
-                      ${systemd_unitdir}/system/systemd-binfmt.service"
-RRECOMMENDS_${PN}-binfmt = "kernel-module-binfmt-misc"
-
-RRECOMMENDS_${PN}-vconsole-setup = "kbd kbd-consolefonts kbd-keymaps"
-
-FILES_${PN}-container = "${sysconfdir}/dbus-1/system.d/org.freedesktop.import1.conf \
-                         ${sysconfdir}/dbus-1/system.d/org.freedesktop.machine1.conf \
-                         ${base_bindir}/machinectl \
-                         ${bindir}/systemd-nspawn \
-                         ${nonarch_libdir}/systemd/import-pubring.gpg \
-                         ${systemd_system_unitdir}/busnames.target.wants/org.freedesktop.import1.busname \
-                         ${systemd_system_unitdir}/busnames.target.wants/org.freedesktop.machine1.busname \
-                         ${systemd_system_unitdir}/local-fs.target.wants/var-lib-machines.mount \
-                         ${systemd_system_unitdir}/machine.slice \
-                         ${systemd_system_unitdir}/machines.target \
-                         ${systemd_system_unitdir}/org.freedesktop.import1.busname \
-                         ${systemd_system_unitdir}/org.freedesktop.machine1.busname \
-                         ${systemd_system_unitdir}/systemd-importd.service \
-                         ${systemd_system_unitdir}/systemd-machined.service \
-                         ${systemd_system_unitdir}/dbus-org.freedesktop.machine1.service \
-                         ${systemd_system_unitdir}/var-lib-machines.mount \
-                         ${rootlibexecdir}/systemd/systemd-import \
-                         ${rootlibexecdir}/systemd/systemd-importd \
-                         ${rootlibexecdir}/systemd/systemd-journal-gatewayd \
-                         ${rootlibexecdir}/systemd/systemd-journal-remote \
-                         ${rootlibexecdir}/systemd/systemd-journal-upload \
-                         ${rootlibexecdir}/systemd/systemd-machined \
-                         ${rootlibexecdir}/systemd/systemd-pull \
-                         ${exec_prefix}/lib/tmpfiles.d/systemd-nspawn.conf \
-                         ${systemd_system_unitdir}/systemd-nspawn@.service \
-                         ${libdir}/libnss_mymachines.so.2 \
-                         ${datadir}/dbus-1/system-services/org.freedesktop.import1.service \
-                         ${datadir}/dbus-1/system-services/org.freedesktop.machine1.service \
-                         ${datadir}/dbus-1/system.d/org.freedesktop.machine1.conf \
-                         ${datadir}/polkit-1/actions/org.freedesktop.import1.policy \
-                         ${datadir}/polkit-1/actions/org.freedesktop.machine1.policy \
-                        "
-
-FILES_${PN}-extra-utils = "\
-                        ${base_bindir}/systemd-escape \
-                        ${base_bindir}/systemd-inhibit \
-                        ${bindir}/systemd-detect-virt \
-                        ${bindir}/systemd-path \
-                        ${bindir}/systemd-run \
-                        ${bindir}/systemd-cat \
-                        ${bindir}/systemd-delta \
-                        ${bindir}/systemd-cgls \
-                        ${bindir}/systemd-cgtop \
-                        ${bindir}/systemd-stdio-bridge \
-                        ${base_bindir}/systemd-ask-password \
-                        ${base_bindir}/systemd-tty-ask-password-agent \
-                        ${systemd_unitdir}/system/systemd-ask-password-console.path \
-                        ${systemd_unitdir}/system/systemd-ask-password-console.service \
-                        ${systemd_unitdir}/system/systemd-ask-password-wall.path \
-                        ${systemd_unitdir}/system/systemd-ask-password-wall.service \
-                        ${systemd_unitdir}/system/sysinit.target.wants/systemd-ask-password-console.path \
-                        ${systemd_unitdir}/system/sysinit.target.wants/systemd-ask-password-wall.path \
-                        ${systemd_unitdir}/system/multi-user.target.wants/systemd-ask-password-wall.path \
-                        ${rootlibexecdir}/systemd/systemd-resolve-host \
-                        ${rootlibexecdir}/systemd/systemd-ac-power \
-                        ${rootlibexecdir}/systemd/systemd-activate \
-                        ${rootlibexecdir}/systemd/systemd-bus-proxyd \
-                        ${systemd_unitdir}/system/systemd-bus-proxyd.service \
-                        ${systemd_unitdir}/system/systemd-bus-proxyd.socket \
-                        ${rootlibexecdir}/systemd/systemd-socket-proxyd \
-                        ${rootlibexecdir}/systemd/systemd-reply-password \
-                        ${rootlibexecdir}/systemd/systemd-sleep \
-                        ${rootlibexecdir}/systemd/system-sleep \
-                        ${systemd_unitdir}/system/systemd-hibernate.service \
-                        ${systemd_unitdir}/system/systemd-hybrid-sleep.service \
-                        ${systemd_unitdir}/system/systemd-suspend.service \
-                        ${systemd_unitdir}/system/sleep.target \
-                        ${rootlibexecdir}/systemd/systemd-initctl \
-                        ${systemd_unitdir}/system/systemd-initctl.service \
-                        ${systemd_unitdir}/system/systemd-initctl.socket \
-                        ${systemd_unitdir}/system/sockets.target.wants/systemd-initctl.socket \
-                        ${rootlibexecdir}/systemd/system-generators/systemd-gpt-auto-generator \
-                        ${rootlibexecdir}/systemd/systemd-cgroups-agent \
-"
-
-CONFFILES_${PN} = "${sysconfdir}/machine-id \
-                ${sysconfdir}/systemd/coredump.conf \
-                ${sysconfdir}/systemd/journald.conf \
-                ${sysconfdir}/systemd/logind.conf \
-                ${sysconfdir}/systemd/system.conf \
-                ${sysconfdir}/systemd/user.conf"
-
-FILES_${PN} = " ${base_bindir}/* \
-                ${datadir}/dbus-1/services \
-                ${datadir}/dbus-1/system-services \
-                ${datadir}/polkit-1 \
-                ${datadir}/${BPN} \
-                ${datadir}/factory \
-                ${sysconfdir}/dbus-1/ \
-                ${sysconfdir}/machine-id \
-                ${sysconfdir}/modules-load.d/ \
-                ${sysconfdir}/pam.d/ \
-                ${sysconfdir}/sysctl.d/ \
-                ${sysconfdir}/systemd/ \
-                ${sysconfdir}/tmpfiles.d/ \
-                ${sysconfdir}/xdg/ \
-                ${sysconfdir}/init.d/README \
-                ${sysconfdir}/resolv-conf.systemd \
-                ${rootlibexecdir}/systemd/* \
-                ${systemd_unitdir}/* \
-                ${base_libdir}/security/*.so \
-                /cgroup \
-                ${bindir}/systemd* \
-                ${bindir}/busctl \
-                ${bindir}/coredumpctl \
-                ${bindir}/localectl \
-                ${bindir}/hostnamectl \
-                ${bindir}/timedatectl \
-                ${bindir}/bootctl \
-                ${bindir}/kernel-install \
-                ${exec_prefix}/lib/tmpfiles.d/*.conf \
-                ${exec_prefix}/lib/systemd \
-                ${exec_prefix}/lib/modules-load.d \
-                ${exec_prefix}/lib/sysctl.d \
-                ${exec_prefix}/lib/sysusers.d \
-                ${exec_prefix}/lib/environment.d \
-                ${localstatedir} \
-                ${nonarch_base_libdir}/udev/rules.d/70-uaccess.rules \
-                ${nonarch_base_libdir}/udev/rules.d/71-seat.rules \
-                ${nonarch_base_libdir}/udev/rules.d/73-seat-late.rules \
-                ${nonarch_base_libdir}/udev/rules.d/99-systemd.rules \
-                ${nonarch_base_libdir}/modprobe.d/systemd.conf \
-                ${datadir}/dbus-1/system.d/org.freedesktop.timedate1.conf \
-                ${datadir}/dbus-1/system.d/org.freedesktop.locale1.conf \
-                ${datadir}/dbus-1/system.d/org.freedesktop.network1.conf \
-                ${datadir}/dbus-1/system.d/org.freedesktop.resolve1.conf \
-                ${datadir}/dbus-1/system.d/org.freedesktop.systemd1.conf \
-                ${datadir}/dbus-1/system.d/org.freedesktop.hostname1.conf \
-                ${datadir}/dbus-1/system.d/org.freedesktop.login1.conf \
-               "
-
-FILES_${PN}-dev += "${base_libdir}/security/*.la ${datadir}/dbus-1/interfaces/ ${sysconfdir}/rpm/macros.systemd"
-
-RDEPENDS_${PN} += "kmod dbus util-linux-mount udev (= ${EXTENDPKGV}) util-linux-agetty"
-RDEPENDS_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'serial-getty-generator', '', 'systemd-serialgetty', d)}"
-RDEPENDS_${PN} += "volatile-binds update-rc.d"
-
-RRECOMMENDS_${PN} += "systemd-extra-utils \
-                      systemd-compat-units udev-hwdb \
-                      util-linux-fsck e2fsprogs-e2fsck \
-                      kernel-module-autofs4 kernel-module-unix kernel-module-ipv6 \
-                      os-release \
-"
-
-INSANE_SKIP_${PN} += "dev-so libdir"
-INSANE_SKIP_${PN}-dbg += "libdir"
-INSANE_SKIP_${PN}-doc += " libdir"
-
-PACKAGES =+ "udev udev-hwdb"
-
-RPROVIDES_udev = "hotplug"
-
-RDEPENDS_udev-hwdb += "udev"
-
-FILES_udev += "${base_sbindir}/udevd \
-               ${rootlibexecdir}/systemd/systemd-udevd \
-               ${rootlibexecdir}/udev/accelerometer \
-               ${rootlibexecdir}/udev/ata_id \
-               ${rootlibexecdir}/udev/cdrom_id \
-               ${rootlibexecdir}/udev/collect \
-               ${rootlibexecdir}/udev/findkeyboards \
-               ${rootlibexecdir}/udev/keyboard-force-release.sh \
-               ${rootlibexecdir}/udev/keymap \
-               ${rootlibexecdir}/udev/mtd_probe \
-               ${rootlibexecdir}/udev/scsi_id \
-               ${rootlibexecdir}/udev/v4l_id \
-               ${rootlibexecdir}/udev/keymaps \
-               ${rootlibexecdir}/udev/rules.d/*.rules \
-               ${sysconfdir}/udev \
-               ${sysconfdir}/init.d/systemd-udevd \
-               ${systemd_unitdir}/system/*udev* \
-               ${systemd_unitdir}/system/*.wants/*udev* \
-               ${base_bindir}/udevadm \
-               ${datadir}/bash-completion/completions/udevadm \
-              "
-
-FILES_udev-hwdb = "${rootlibexecdir}/udev/hwdb.d"
-
-INITSCRIPT_PACKAGES = "udev"
-INITSCRIPT_NAME_udev = "systemd-udevd"
-INITSCRIPT_PARAMS_udev = "start 03 S ."
-
-python __anonymous() {
-    if not bb.utils.contains('DISTRO_FEATURES', 'sysvinit', True, False, d):
-        d.setVar("INHIBIT_UPDATERCD_BBCLASS", "1")
-}
-
-# TODO:
-# u-a for runlevel and telinit
-
-ALTERNATIVE_${PN} = "init halt reboot shutdown poweroff runlevel resolv-conf"
-
-ALTERNATIVE_TARGET[init] = "${rootlibexecdir}/systemd/systemd"
-ALTERNATIVE_LINK_NAME[init] = "${base_sbindir}/init"
-ALTERNATIVE_PRIORITY[init] ?= "300"
-
-ALTERNATIVE_TARGET[halt] = "${base_bindir}/systemctl"
-ALTERNATIVE_LINK_NAME[halt] = "${base_sbindir}/halt"
-ALTERNATIVE_PRIORITY[halt] ?= "300"
-
-ALTERNATIVE_TARGET[reboot] = "${base_bindir}/systemctl"
-ALTERNATIVE_LINK_NAME[reboot] = "${base_sbindir}/reboot"
-ALTERNATIVE_PRIORITY[reboot] ?= "300"
-
-ALTERNATIVE_TARGET[shutdown] = "${base_bindir}/systemctl"
-ALTERNATIVE_LINK_NAME[shutdown] = "${base_sbindir}/shutdown"
-ALTERNATIVE_PRIORITY[shutdown] ?= "300"
-
-ALTERNATIVE_TARGET[poweroff] = "${base_bindir}/systemctl"
-ALTERNATIVE_LINK_NAME[poweroff] = "${base_sbindir}/poweroff"
-ALTERNATIVE_PRIORITY[poweroff] ?= "300"
-
-ALTERNATIVE_TARGET[runlevel] = "${base_bindir}/systemctl"
-ALTERNATIVE_LINK_NAME[runlevel] = "${base_sbindir}/runlevel"
-ALTERNATIVE_PRIORITY[runlevel] ?= "300"
-
-ALTERNATIVE_TARGET[resolv-conf] = "${sysconfdir}/resolv-conf.systemd"
-ALTERNATIVE_LINK_NAME[resolv-conf] = "${sysconfdir}/resolv.conf"
-ALTERNATIVE_PRIORITY[resolv-conf] ?= "50"
-
-pkg_postinst_${PN} () {
-	sed -e '/^hosts:/s/\s*\<myhostname\>//' \
-		-e 's/\(^hosts:.*\)\(\<files\>\)\(.*\)\(\<dns\>\)\(.*\)/\1\2 myhostname \3\4\5/' \
-		-i $D${sysconfdir}/nsswitch.conf
-}
-
-pkg_prerm_${PN} () {
-	sed -e '/^hosts:/s/\s*\<myhostname\>//' \
-		-e '/^hosts:/s/\s*myhostname//' \
-		-i $D${sysconfdir}/nsswitch.conf
-}
-
-PACKAGE_WRITE_DEPS += "qemu-native"
-pkg_postinst_udev-hwdb () {
-	if test -n "$D"; then
-		${@qemu_run_binary(d, '$D', '${base_bindir}/udevadm')} hwdb --update \
-			--root $D
-		chown root:root $D${sysconfdir}/udev/hwdb.bin
-	else
-		udevadm hwdb --update
-	fi
-}
-
-pkg_prerm_udev-hwdb () {
-	rm -f $D${sysconfdir}/udev/hwdb.bin
-}
diff --git a/poky/meta/recipes-core/systemd/systemd_239.bb b/poky/meta/recipes-core/systemd/systemd_239.bb
new file mode 100644
index 0000000..3dbeaac
--- /dev/null
+++ b/poky/meta/recipes-core/systemd/systemd_239.bb
@@ -0,0 +1,606 @@
+require systemd.inc
+
+PROVIDES = "udev"
+
+PE = "1"
+
+DEPENDS = "intltool-native gperf-native libcap util-linux"
+
+SECTION = "base/shell"
+
+inherit useradd pkgconfig meson perlnative update-rc.d update-alternatives qemu systemd gettext bash-completion manpages distro_features_check
+
+# As this recipe builds udev, respect systemd being in DISTRO_FEATURES so
+# that we don't build both udev and systemd in world builds.
+REQUIRED_DISTRO_FEATURES = "systemd"
+
+SRC_URI += "file://touchscreen.rules \
+           file://00-create-volatile.conf \
+           file://init \
+           file://0001-binfmt-Don-t-install-dependency-links-at-install-tim.patch \
+           file://0002-use-lnr-wrapper-instead-of-looking-for-relative-opti.patch \
+           file://0003-implment-systemd-sysv-install-for-OE.patch \
+           file://0004-rules-whitelist-hd-devices.patch \
+           file://0005-Make-root-s-home-directory-configurable.patch \
+           file://0006-remove-nobody-user-group-checking.patch \
+           file://0007-rules-watch-metadata-changes-in-ide-devices.patch \
+           file://0008-Do-not-enable-nss-tests-if-nss-systemd-is-not-enable.patch \
+           file://0009-nss-mymachines-Build-conditionally-when-ENABLE_MYHOS.patch \
+           file://0001-login-use-parse_uid-when-unmounting-user-runtime-dir.patch \
+           file://0001-sd-bus-make-BUS_DEFAULT_TIMEOUT-configurable.patch \
+           file://0022-build-sys-Detect-whether-struct-statx-is-defined-in-.patch \
+           file://0023-resolvconf-fixes-for-the-compatibility-interface.patch \
+           file://0001-core-when-deserializing-state-always-use-read_line-L.patch \
+           file://0001-chown-recursive-let-s-rework-the-recursive-logic-to-.patch \
+           file://0001-dhcp6-make-sure-we-have-enough-space-for-the-DHCP6-o.patch \
+           "
+
+# patches made for musl are only applied on TCLIBC is musl
+SRC_URI += "${SRC_URI_MUSL}"
+SRC_URI_MUSL = "file://0001-Use-getenv-when-secure-versions-are-not-available.patch \
+               file://0002-don-t-use-glibc-specific-qsort_r.patch \
+               file://0003-comparison_fn_t-is-glibc-specific-use-raw-signature-.patch \
+               file://0004-add-fallback-parse_printf_format-implementation.patch \
+               file://0005-include-gshadow-only-if-ENABLE_GSHADOW-is-1.patch \
+               file://0006-src-basic-missing.h-check-for-missing-strndupa.patch \
+               file://0007-Include-netinet-if_ether.h.patch \
+               file://0008-don-t-fail-if-GLOB_BRACE-and-GLOB_ALTDIRFUNC-is-not-.patch \
+               file://0009-add-missing-FTW_-macros-for-musl.patch \
+               file://0010-socket-util-don-t-fail-if-libc-doesn-t-support-IDN.patch \
+               file://0011-src-basic-missing.h-check-for-missing-__compar_fn_t-.patch \
+               file://0012-fix-missing-of-__register_atfork-for-non-glibc-build.patch \
+               file://0013-Use-uintmax_t-for-handling-rlim_t.patch \
+               file://0014-fix-missing-ULONG_LONG_MAX-definition-in-case-of-mus.patch \
+               file://0015-test-hexdecoct.c-Include-missing.h-for-strndupa.patch \
+               file://0016-test-sizeof.c-Disable-tests-for-missing-typedefs-in-.patch \
+               file://0017-don-t-pass-AT_SYMLINK_NOFOLLOW-flag-to-faccessat.patch \
+               file://0018-Define-glibc-compatible-basename-for-non-glibc-syste.patch \
+               file://0019-Do-not-disable-buffering-when-writing-to-oom_score_a.patch \
+               file://0020-distinguish-XSI-compliant-strerror_r-from-GNU-specif.patch \
+               file://0021-Hide-__start_BUS_ERROR_MAP-and-__stop_BUS_ERROR_MAP.patch \
+               "
+
+# Workaround undefined reference to `__stack_chk_fail_local' on qemux86 and qemuppc for musl
+SRC_URI_append_libc-musl_qemux86 = " file://0001-Remove-fstack-protector-flags-to-workaround-musl-bui.patch"
+SRC_URI_append_libc-musl_qemuppc = " file://0001-Remove-fstack-protector-flags-to-workaround-musl-bui.patch"
+
+PAM_PLUGINS = " \
+    pam-plugin-unix \
+    pam-plugin-loginuid \
+    pam-plugin-keyinit \
+"
+
+PACKAGECONFIG ??= " \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'efi ldconfig pam selinux usrmerge', d)} \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'wifi', 'rfkill', '', d)} \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'xkbcommon', '', d)} \
+    acl \
+    backlight \
+    binfmt \
+    firstboot \
+    gshadow \
+    hibernate \
+    hostnamed \
+    ima \
+    kmod \
+    localed \
+    logind \
+    machined \
+    myhostname \
+    networkd \
+    nss \
+    polkit \
+    quotacheck \
+    randomseed \
+    resolved \
+    smack \
+    sysusers \
+    timedated \
+    timesyncd \
+    utmp \
+    vconsole \
+    xz \
+"
+
+PACKAGECONFIG_remove_libc-musl = " \
+    gshadow \
+    localed \
+    myhostname \
+    nss \
+    resolved \
+    selinux \
+    smack \
+    sysusers \
+    utmp \
+"
+
+# Use the upstream systemd serial-getty@.service and rely on
+# systemd-getty-generator instead of using the OE-core specific
+# systemd-serialgetty.bb - not enabled by default.
+PACKAGECONFIG[serial-getty-generator] = ""
+
+PACKAGECONFIG[acl] = "-Dacl=true,-Dacl=false,acl"
+PACKAGECONFIG[audit] = "-Daudit=true,-Daudit=false,audit"
+PACKAGECONFIG[backlight] = "-Dbacklight=true,-Dbacklight=false"
+PACKAGECONFIG[binfmt] = "-Dbinfmt=true,-Dbinfmt=false"
+PACKAGECONFIG[bzip2] = "-Dbzip2=true,-Dbzip2=false,bzip2"
+PACKAGECONFIG[coredump] = "-Dcoredump=true,-Dcoredump=false"
+PACKAGECONFIG[cryptsetup] = "-Dlibcryptsetup=true,-Dlibcryptsetup=false,cryptsetup"
+PACKAGECONFIG[dbus] = "-Ddbus=true,-Ddbus=false,dbus"
+PACKAGECONFIG[efi] = "-Defi=true,-Defi=false"
+PACKAGECONFIG[elfutils] = "-Delfutils=true,-Delfutils=false,elfutils"
+PACKAGECONFIG[firstboot] = "-Dfirstboot=true,-Dfirstboot=false"
+# Sign the journal for anti-tampering
+PACKAGECONFIG[gcrypt] = "-Dgcrypt=true,-Dgcrypt=false,libgcrypt"
+PACKAGECONFIG[gshadow] = "-Dgshadow=true,-Dgshadow=false"
+PACKAGECONFIG[hibernate] = "-Dhibernate=true,-Dhibernate=false"
+PACKAGECONFIG[hostnamed] = "-Dhostnamed=true,-Dhostnamed=false"
+PACKAGECONFIG[ima] = "-Dima=true,-Dima=false"
+# importd requires curl/xz/zlib/bzip2/gcrypt
+PACKAGECONFIG[importd] = "-Dimportd=true,-Dimportd=false"
+# Update NAT firewall rules
+PACKAGECONFIG[iptc] = "-Dlibiptc=true,-Dlibiptc=false,iptables"
+PACKAGECONFIG[journal-upload] = "-Dlibcurl=true,-Dlibcurl=false,curl"
+PACKAGECONFIG[kmod] = "-Dkmod=true,-Dkmod=false,kmod"
+PACKAGECONFIG[ldconfig] = "-Dldconfig=true,-Dldconfig=false"
+PACKAGECONFIG[libidn] = "-Dlibidn=true,-Dlibidn=false,libidn"
+PACKAGECONFIG[localed] = "-Dlocaled=true,-Dlocaled=false"
+PACKAGECONFIG[logind] = "-Dlogind=true,-Dlogind=false"
+PACKAGECONFIG[lz4] = "-Dlz4=true,-Dlz4=false,lz4"
+PACKAGECONFIG[machined] = "-Dmachined=true,-Dmachined=false"
+PACKAGECONFIG[manpages] = "-Dman=true,-Dman=false,libxslt-native xmlto-native docbook-xml-dtd4-native docbook-xsl-stylesheets-native"
+PACKAGECONFIG[microhttpd] = "-Dmicrohttpd=true,-Dmicrohttpd=false,libmicrohttpd"
+PACKAGECONFIG[myhostname] = "-Dmyhostname=true,-Dmyhostname=false"
+PACKAGECONFIG[networkd] = "-Dnetworkd=true,-Dnetworkd=false"
+PACKAGECONFIG[nss] = "-Dnss-systemd=true,-Dnss-systemd=false"
+PACKAGECONFIG[pam] = "-Dpam=true,-Dpam=false,libpam,${PAM_PLUGINS}"
+PACKAGECONFIG[polkit] = "-Dpolkit=true,-Dpolkit=false"
+PACKAGECONFIG[portabled] = "-Dportabled=true,-Dportabled=false"
+PACKAGECONFIG[qrencode] = "-Dqrencode=true,-Dqrencode=false,qrencode"
+PACKAGECONFIG[quotacheck] = "-Dquotacheck=true,-Dquotacheck=false"
+PACKAGECONFIG[randomseed] = "-Drandomseed=true,-Drandomseed=false"
+PACKAGECONFIG[resolved] = "-Dresolve=true,-Dresolve=false"
+PACKAGECONFIG[rfkill] = "-Drfkill=true,-Drfkill=false"
+# libseccomp is found in meta-security
+PACKAGECONFIG[seccomp] = "-Dseccomp=true,-Dseccomp=false,libseccomp"
+PACKAGECONFIG[selinux] = "-Dselinux=true,-Dselinux=false,libselinux,initscripts-sushell"
+PACKAGECONFIG[smack] = "-Dsmack=true,-Dsmack=false"
+PACKAGECONFIG[sysusers] = "-Dsysusers=true,-Dsysusers=false"
+PACKAGECONFIG[time-epoch] = "-Dtime-epoch=0,,"
+PACKAGECONFIG[timedated] = "-Dtimedated=true,-Dtimedated=false"
+PACKAGECONFIG[timesyncd] = "-Dtimesyncd=true,-Dtimesyncd=false"
+PACKAGECONFIG[usrmerge] = "-Dsplit-usr=false,-Dsplit-usr=true"
+PACKAGECONFIG[sbinmerge] = "-Dsplit-bin=false,-Dsplit-bin=true"
+PACKAGECONFIG[utmp] = "-Dutmp=true,-Dutmp=false"
+PACKAGECONFIG[valgrind] = "-DVALGRIND=1,,valgrind"
+PACKAGECONFIG[vconsole] = "-Dvconsole=true,-Dvconsole=false,,${PN}-vconsole-setup"
+# Verify keymaps on locale change
+PACKAGECONFIG[xkbcommon] = "-Dxkbcommon=true,-Dxkbcommon=false,libxkbcommon"
+PACKAGECONFIG[xz] = "-Dxz=true,-Dxz=false,xz"
+PACKAGECONFIG[zlib] = "-Dzlib=true,-Dzlib=false,zlib"
+
+# Helper variables to clarify locations.  This mirrors the logic in systemd's
+# build system.
+rootprefix ?= "${root_prefix}"
+rootlibdir ?= "${base_libdir}"
+rootlibexecdir = "${rootprefix}/lib"
+
+# This links udev statically with systemd helper library.
+# Otherwise udev package would depend on systemd package (which has the needed shared library),
+# and always pull it into images.
+EXTRA_OEMESON += "-Dlink-udev-shared=false"
+
+EXTRA_OEMESON += "-Dnobody-user=nobody \
+                  -Dnobody-group=nobody \
+                  -Droothomedir=${ROOT_HOME} \
+                  -Drootlibdir=${rootlibdir} \
+                  -Drootprefix=${rootprefix} \
+                  -Dsysvrcnd-path=${sysconfdir} \
+                  "
+
+# Hardcode target binary paths to avoid using paths from sysroot
+EXTRA_OEMESON += "-Dkexec-path=${sbindir}/kexec \
+                  -Dkill-path=${base_bindir}/kill \
+                  -Dkmod-path=${base_bindir}/kmod \
+                  -Dmount-path=${base_bindir}/mount \
+                  -Dquotacheck-path=${sbindir}/quotacheck \
+                  -Dquotaon-path=${sbindir}/quotaon \
+                  -Dsulogin-path=${base_sbindir}/sulogin \
+                  -Dumount-path=${base_bindir}/umount"
+
+do_install() {
+	meson_do_install
+	install -d ${D}/${base_sbindir}
+	if ${@bb.utils.contains('PACKAGECONFIG', 'serial-getty-generator', 'false', 'true', d)}; then
+		# Provided by a separate recipe
+		rm ${D}${systemd_unitdir}/system/serial-getty* -f
+	fi
+
+	# Provide support for initramfs
+	[ ! -e ${D}/init ] && ln -s ${rootlibexecdir}/systemd/systemd ${D}/init
+	[ ! -e ${D}/${base_sbindir}/udevd ] && ln -s ${rootlibexecdir}/systemd/systemd-udevd ${D}/${base_sbindir}/udevd
+
+	install -d ${D}${sysconfdir}/udev/rules.d/
+	install -d ${D}${sysconfdir}/tmpfiles.d
+	install -m 0644 ${WORKDIR}/*.rules ${D}${sysconfdir}/udev/rules.d/
+	install -d ${D}${libdir}/pkgconfig
+	install -m 0644 ${B}/src/udev/udev.pc ${D}${libdir}/pkgconfig/
+
+	install -m 0644 ${WORKDIR}/00-create-volatile.conf ${D}${sysconfdir}/tmpfiles.d/
+
+	if ${@bb.utils.contains('DISTRO_FEATURES','sysvinit','true','false',d)}; then
+		install -d ${D}${sysconfdir}/init.d
+		install -m 0755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/systemd-udevd
+		sed -i s%@UDEVD@%${rootlibexecdir}/systemd/systemd-udevd% ${D}${sysconfdir}/init.d/systemd-udevd
+	fi
+
+	chown root:systemd-journal ${D}/${localstatedir}/log/journal
+
+	# Delete journal README, as log can be symlinked inside volatile.
+	rm -f ${D}/${localstatedir}/log/README
+
+	install -d ${D}${systemd_unitdir}/system/graphical.target.wants
+	install -d ${D}${systemd_unitdir}/system/multi-user.target.wants
+	install -d ${D}${systemd_unitdir}/system/poweroff.target.wants
+	install -d ${D}${systemd_unitdir}/system/reboot.target.wants
+	install -d ${D}${systemd_unitdir}/system/rescue.target.wants
+
+	# Create symlinks for systemd-update-utmp-runlevel.service
+	if ${@bb.utils.contains('PACKAGECONFIG', 'utmp', 'true', 'false', d)}; then
+		ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_unitdir}/system/graphical.target.wants/systemd-update-utmp-runlevel.service
+		ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_unitdir}/system/multi-user.target.wants/systemd-update-utmp-runlevel.service
+		ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_unitdir}/system/poweroff.target.wants/systemd-update-utmp-runlevel.service
+		ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_unitdir}/system/reboot.target.wants/systemd-update-utmp-runlevel.service
+		ln -sf ../systemd-update-utmp-runlevel.service ${D}${systemd_unitdir}/system/rescue.target.wants/systemd-update-utmp-runlevel.service
+	fi
+
+	# this file is needed to exist if networkd is disabled but timesyncd is still in use since timesyncd checks it
+	# for existence else it fails
+	if [ -s ${D}${exec_prefix}/lib/tmpfiles.d/systemd.conf ]; then
+		${@bb.utils.contains('PACKAGECONFIG', 'networkd', ':', 'sed -i -e "\$ad /run/systemd/netif/links 0755 root root -" ${D}${exec_prefix}/lib/tmpfiles.d/systemd.conf', d)}
+	fi
+	if ! ${@bb.utils.contains('PACKAGECONFIG', 'resolved', 'true', 'false', d)}; then
+		echo 'L! ${sysconfdir}/resolv.conf - - - - ../run/systemd/resolve/resolv.conf' >>${D}${exec_prefix}/lib/tmpfiles.d/etc.conf
+		echo 'd /run/systemd/resolve 0755 root root -' >>${D}${exec_prefix}/lib/tmpfiles.d/systemd.conf
+		echo 'f /run/systemd/resolve/resolv.conf 0644 root root' >>${D}${exec_prefix}/lib/tmpfiles.d/systemd.conf
+		ln -s ../run/systemd/resolve/resolv.conf ${D}${sysconfdir}/resolv-conf.systemd
+	else
+		sed -i -e "s%^L! /etc/resolv.conf.*$%L! /etc/resolv.conf - - - - ../run/systemd/resolve/resolv.conf%g" ${D}${exec_prefix}/lib/tmpfiles.d/etc.conf
+		ln -s ../run/systemd/resolve/resolv.conf ${D}${sysconfdir}/resolv-conf.systemd
+	fi
+	install -Dm 0755 ${S}/src/systemctl/systemd-sysv-install.SKELETON ${D}${systemd_unitdir}/systemd-sysv-install
+
+	# If polkit is setup fixup permissions and ownership
+	if ${@bb.utils.contains('PACKAGECONFIG', 'polkit', 'true', 'false', d)}; then
+		if [ -d ${D}${datadir}/polkit-1/rules.d ]; then
+			chmod 700 ${D}${datadir}/polkit-1/rules.d
+			chown polkitd:root ${D}${datadir}/polkit-1/rules.d
+		fi
+	fi
+
+	# conf files are handled by systemd-conf
+	rm -f ${D}${sysconfdir}/machine-id
+	rm -f ${D}${sysconfdir}/systemd/coredump.conf
+	rm -f ${D}${sysconfdir}/systemd/journald.conf
+	rm -f ${D}${sysconfdir}/systemd/logind.conf
+	rm -f ${D}${sysconfdir}/systemd/system.conf
+	rm -f ${D}${sysconfdir}/systemd/user.conf
+
+	# duplicate udevadm for postinst script
+	install -d ${D}${libexecdir}
+	ln ${D}${base_bindir}/udevadm ${D}${libexecdir}/${MLPREFIX}udevadm
+}
+
+
+python populate_packages_prepend (){
+    systemdlibdir = d.getVar("rootlibdir")
+    do_split_packages(d, systemdlibdir, '^lib(.*)\.so\.*', 'lib%s', 'Systemd %s library', extra_depends='', allow_links=True)
+}
+PACKAGES_DYNAMIC += "^lib(udev|systemd|nss).*"
+
+PACKAGES =+ "\
+    ${PN}-gui \
+    ${PN}-vconsole-setup \
+    ${PN}-initramfs \
+    ${PN}-analyze \
+    ${PN}-kernel-install \
+    ${PN}-rpm-macros \
+    ${PN}-binfmt \
+    ${PN}-zsh-completion \
+    ${PN}-xorg-xinitrc \
+    ${PN}-container \
+    ${PN}-extra-utils \
+"
+
+SUMMARY_${PN}-container = "Tools for containers and VMs"
+DESCRIPTION_${PN}-container = "Systemd tools to spawn and manage containers and virtual machines."
+
+SYSTEMD_PACKAGES = "${@bb.utils.contains('PACKAGECONFIG', 'binfmt', '${PN}-binfmt', '', d)}"
+SYSTEMD_SERVICE_${PN}-binfmt = "systemd-binfmt.service"
+
+USERADD_PACKAGES = "${PN} ${PN}-extra-utils"
+USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'microhttpd', '--system -d / -M --shell /bin/nologin systemd-journal-gateway;', '', d)}"
+USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'microhttpd', '--system -d / -M --shell /bin/nologin systemd-journal-remote;', '', d)}"
+USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'journal-upload', '--system -d / -M --shell /bin/nologin systemd-journal-upload;', '', d)}"
+USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'timesyncd', '--system -d / -M --shell /bin/nologin systemd-timesync;', '', d)}"
+USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'networkd', '--system -d / -M --shell /bin/nologin systemd-network;', '', d)}"
+USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'coredump', '--system -d / -M --shell /bin/nologin systemd-coredump;', '', d)}"
+USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'resolved', '--system -d / -M --shell /bin/nologin systemd-resolve;', '', d)}"
+USERADD_PARAM_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'polkit', '--system --no-create-home --user-group --home-dir ${sysconfdir}/polkit-1 polkitd;', '', d)}"
+GROUPADD_PARAM_${PN} = "-r systemd-journal"
+USERADD_PARAM_${PN}-extra-utils += "--system -d / -M --shell /bin/nologin systemd-bus-proxy;"
+
+FILES_${PN}-analyze = "${bindir}/systemd-analyze"
+
+FILES_${PN}-initramfs = "/init"
+RDEPENDS_${PN}-initramfs = "${PN}"
+
+FILES_${PN}-gui = "${bindir}/systemadm"
+
+FILES_${PN}-vconsole-setup = "${rootlibexecdir}/systemd/systemd-vconsole-setup \
+                              ${systemd_unitdir}/system/systemd-vconsole-setup.service \
+                              ${systemd_unitdir}/system/sysinit.target.wants/systemd-vconsole-setup.service"
+
+RDEPENDS_${PN}-kernel-install += "bash"
+FILES_${PN}-kernel-install = "${bindir}/kernel-install \
+                              ${sysconfdir}/kernel/ \
+                              ${exec_prefix}/lib/kernel \
+                             "
+FILES_${PN}-rpm-macros = "${exec_prefix}/lib/rpm \
+                         "
+
+FILES_${PN}-xorg-xinitrc = "${sysconfdir}/X11/xinit/xinitrc.d/*"
+
+FILES_${PN}-zsh-completion = "${datadir}/zsh/site-functions"
+
+FILES_${PN}-binfmt = "${sysconfdir}/binfmt.d/ \
+                      ${exec_prefix}/lib/binfmt.d \
+                      ${rootlibexecdir}/systemd/systemd-binfmt \
+                      ${systemd_unitdir}/system/proc-sys-fs-binfmt_misc.* \
+                      ${systemd_unitdir}/system/systemd-binfmt.service"
+RRECOMMENDS_${PN}-binfmt = "kernel-module-binfmt-misc"
+
+RRECOMMENDS_${PN}-vconsole-setup = "kbd kbd-consolefonts kbd-keymaps"
+
+FILES_${PN}-container = "${sysconfdir}/dbus-1/system.d/org.freedesktop.import1.conf \
+                         ${sysconfdir}/dbus-1/system.d/org.freedesktop.machine1.conf \
+                         ${base_bindir}/machinectl \
+                         ${bindir}/systemd-nspawn \
+                         ${nonarch_libdir}/systemd/import-pubring.gpg \
+                         ${systemd_system_unitdir}/busnames.target.wants/org.freedesktop.import1.busname \
+                         ${systemd_system_unitdir}/busnames.target.wants/org.freedesktop.machine1.busname \
+                         ${systemd_system_unitdir}/local-fs.target.wants/var-lib-machines.mount \
+                         ${systemd_system_unitdir}/machine.slice \
+                         ${systemd_system_unitdir}/machines.target \
+                         ${systemd_system_unitdir}/org.freedesktop.import1.busname \
+                         ${systemd_system_unitdir}/org.freedesktop.machine1.busname \
+                         ${systemd_system_unitdir}/systemd-importd.service \
+                         ${systemd_system_unitdir}/systemd-machined.service \
+                         ${systemd_system_unitdir}/dbus-org.freedesktop.machine1.service \
+                         ${systemd_system_unitdir}/var-lib-machines.mount \
+                         ${rootlibexecdir}/systemd/systemd-import \
+                         ${rootlibexecdir}/systemd/systemd-importd \
+                         ${rootlibexecdir}/systemd/systemd-journal-gatewayd \
+                         ${rootlibexecdir}/systemd/systemd-journal-remote \
+                         ${rootlibexecdir}/systemd/systemd-journal-upload \
+                         ${rootlibexecdir}/systemd/systemd-machined \
+                         ${rootlibexecdir}/systemd/systemd-pull \
+                         ${exec_prefix}/lib/tmpfiles.d/systemd-nspawn.conf \
+                         ${systemd_system_unitdir}/systemd-nspawn@.service \
+                         ${libdir}/libnss_mymachines.so.2 \
+                         ${datadir}/dbus-1/system-services/org.freedesktop.import1.service \
+                         ${datadir}/dbus-1/system-services/org.freedesktop.machine1.service \
+                         ${datadir}/dbus-1/system.d/org.freedesktop.import1.conf \
+                         ${datadir}/dbus-1/system.d/org.freedesktop.machine1.conf \
+                         ${datadir}/polkit-1/actions/org.freedesktop.import1.policy \
+                         ${datadir}/polkit-1/actions/org.freedesktop.machine1.policy \
+                        "
+
+FILES_${PN}-extra-utils = "\
+                        ${base_bindir}/systemd-escape \
+                        ${base_bindir}/systemd-inhibit \
+                        ${bindir}/systemd-detect-virt \
+                        ${bindir}/systemd-path \
+                        ${bindir}/systemd-run \
+                        ${bindir}/systemd-cat \
+                        ${bindir}/systemd-delta \
+                        ${bindir}/systemd-cgls \
+                        ${bindir}/systemd-cgtop \
+                        ${bindir}/systemd-stdio-bridge \
+                        ${base_bindir}/systemd-ask-password \
+                        ${base_bindir}/systemd-tty-ask-password-agent \
+                        ${systemd_unitdir}/system/systemd-ask-password-console.path \
+                        ${systemd_unitdir}/system/systemd-ask-password-console.service \
+                        ${systemd_unitdir}/system/systemd-ask-password-wall.path \
+                        ${systemd_unitdir}/system/systemd-ask-password-wall.service \
+                        ${systemd_unitdir}/system/sysinit.target.wants/systemd-ask-password-console.path \
+                        ${systemd_unitdir}/system/sysinit.target.wants/systemd-ask-password-wall.path \
+                        ${systemd_unitdir}/system/multi-user.target.wants/systemd-ask-password-wall.path \
+                        ${rootlibexecdir}/systemd/systemd-resolve-host \
+                        ${rootlibexecdir}/systemd/systemd-ac-power \
+                        ${rootlibexecdir}/systemd/systemd-activate \
+                        ${rootlibexecdir}/systemd/systemd-bus-proxyd \
+                        ${systemd_unitdir}/system/systemd-bus-proxyd.service \
+                        ${systemd_unitdir}/system/systemd-bus-proxyd.socket \
+                        ${rootlibexecdir}/systemd/systemd-socket-proxyd \
+                        ${rootlibexecdir}/systemd/systemd-reply-password \
+                        ${rootlibexecdir}/systemd/systemd-sleep \
+                        ${rootlibexecdir}/systemd/system-sleep \
+                        ${systemd_unitdir}/system/systemd-hibernate.service \
+                        ${systemd_unitdir}/system/systemd-hybrid-sleep.service \
+                        ${systemd_unitdir}/system/systemd-suspend.service \
+                        ${systemd_unitdir}/system/sleep.target \
+                        ${rootlibexecdir}/systemd/systemd-initctl \
+                        ${systemd_unitdir}/system/systemd-initctl.service \
+                        ${systemd_unitdir}/system/systemd-initctl.socket \
+                        ${systemd_unitdir}/system/sockets.target.wants/systemd-initctl.socket \
+                        ${rootlibexecdir}/systemd/system-generators/systemd-gpt-auto-generator \
+                        ${rootlibexecdir}/systemd/systemd-cgroups-agent \
+"
+
+FILES_${PN} = " ${base_bindir}/* \
+                ${base_sbindir}/shutdown \
+                ${base_sbindir}/halt \
+                ${base_sbindir}/poweroff \
+                ${base_sbindir}/runlevel \
+                ${base_sbindir}/telinit \
+                ${base_sbindir}/resolvconf \
+                ${base_sbindir}/reboot \
+                ${base_sbindir}/init \
+                ${datadir}/dbus-1/services \
+                ${datadir}/dbus-1/system-services \
+                ${datadir}/polkit-1 \
+                ${datadir}/${BPN} \
+                ${datadir}/factory \
+                ${sysconfdir}/dbus-1/ \
+                ${sysconfdir}/modules-load.d/ \
+                ${sysconfdir}/pam.d/ \
+                ${sysconfdir}/sysctl.d/ \
+                ${sysconfdir}/systemd/ \
+                ${sysconfdir}/tmpfiles.d/ \
+                ${sysconfdir}/xdg/ \
+                ${sysconfdir}/init.d/README \
+                ${sysconfdir}/resolv-conf.systemd \
+                ${rootlibexecdir}/systemd/* \
+                ${systemd_unitdir}/* \
+                ${base_libdir}/security/*.so \
+                /cgroup \
+                ${bindir}/systemd* \
+                ${bindir}/busctl \
+                ${bindir}/coredumpctl \
+                ${bindir}/localectl \
+                ${bindir}/hostnamectl \
+                ${bindir}/resolvectl \
+                ${bindir}/timedatectl \
+                ${bindir}/bootctl \
+                ${bindir}/kernel-install \
+                ${exec_prefix}/lib/tmpfiles.d/*.conf \
+                ${exec_prefix}/lib/systemd \
+                ${exec_prefix}/lib/modules-load.d \
+                ${exec_prefix}/lib/sysctl.d \
+                ${exec_prefix}/lib/sysusers.d \
+                ${exec_prefix}/lib/environment.d \
+                ${localstatedir} \
+                ${nonarch_base_libdir}/udev/rules.d/70-uaccess.rules \
+                ${nonarch_base_libdir}/udev/rules.d/71-seat.rules \
+                ${nonarch_base_libdir}/udev/rules.d/73-seat-late.rules \
+                ${nonarch_base_libdir}/udev/rules.d/99-systemd.rules \
+                ${nonarch_base_libdir}/modprobe.d/systemd.conf \
+                ${datadir}/dbus-1/system.d/org.freedesktop.timedate1.conf \
+                ${datadir}/dbus-1/system.d/org.freedesktop.locale1.conf \
+                ${datadir}/dbus-1/system.d/org.freedesktop.network1.conf \
+                ${datadir}/dbus-1/system.d/org.freedesktop.resolve1.conf \
+                ${datadir}/dbus-1/system.d/org.freedesktop.systemd1.conf \
+                ${datadir}/dbus-1/system.d/org.freedesktop.hostname1.conf \
+                ${datadir}/dbus-1/system.d/org.freedesktop.login1.conf \
+                ${datadir}/dbus-1/system.d/org.freedesktop.timesync1.conf \
+                ${datadir}/dbus-1/system.d/org.freedesktop.portable1.conf \
+               "
+
+FILES_${PN}-dev += "${base_libdir}/security/*.la ${datadir}/dbus-1/interfaces/ ${sysconfdir}/rpm/macros.systemd"
+
+RDEPENDS_${PN} += "kmod dbus util-linux-mount udev (= ${EXTENDPKGV}) util-linux-agetty util-linux-fsck"
+RDEPENDS_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'serial-getty-generator', '', 'systemd-serialgetty', d)}"
+RDEPENDS_${PN} += "volatile-binds update-rc.d systemd-conf"
+
+RRECOMMENDS_${PN} += "systemd-extra-utils \
+                      systemd-compat-units udev-hwdb \
+                      e2fsprogs-e2fsck \
+                      kernel-module-autofs4 kernel-module-unix kernel-module-ipv6 \
+                      os-release \
+"
+
+INSANE_SKIP_${PN} += "dev-so libdir"
+INSANE_SKIP_${PN}-dbg += "libdir"
+INSANE_SKIP_${PN}-doc += " libdir"
+
+PACKAGES =+ "udev udev-hwdb"
+
+RPROVIDES_udev = "hotplug"
+
+RDEPENDS_udev-hwdb += "udev"
+
+FILES_udev += "${base_sbindir}/udevd \
+               ${rootlibexecdir}/systemd/systemd-udevd \
+               ${rootlibexecdir}/udev/accelerometer \
+               ${rootlibexecdir}/udev/ata_id \
+               ${rootlibexecdir}/udev/cdrom_id \
+               ${rootlibexecdir}/udev/collect \
+               ${rootlibexecdir}/udev/findkeyboards \
+               ${rootlibexecdir}/udev/keyboard-force-release.sh \
+               ${rootlibexecdir}/udev/keymap \
+               ${rootlibexecdir}/udev/mtd_probe \
+               ${rootlibexecdir}/udev/scsi_id \
+               ${rootlibexecdir}/udev/v4l_id \
+               ${rootlibexecdir}/udev/keymaps \
+               ${rootlibexecdir}/udev/rules.d/*.rules \
+               ${sysconfdir}/udev \
+               ${sysconfdir}/init.d/systemd-udevd \
+               ${systemd_unitdir}/system/*udev* \
+               ${systemd_unitdir}/system/*.wants/*udev* \
+               ${base_bindir}/udevadm \
+               ${libexecdir}/${MLPREFIX}udevadm \
+               ${datadir}/bash-completion/completions/udevadm \
+              "
+
+FILES_udev-hwdb = "${rootlibexecdir}/udev/hwdb.d"
+
+INITSCRIPT_PACKAGES = "udev"
+INITSCRIPT_NAME_udev = "systemd-udevd"
+INITSCRIPT_PARAMS_udev = "start 03 S ."
+
+python __anonymous() {
+    if not bb.utils.contains('DISTRO_FEATURES', 'sysvinit', True, False, d):
+        d.setVar("INHIBIT_UPDATERCD_BBCLASS", "1")
+}
+
+ALTERNATIVE_${PN} = "halt reboot shutdown poweroff runlevel resolv-conf"
+
+ALTERNATIVE_TARGET[resolv-conf] = "${sysconfdir}/resolv-conf.systemd"
+ALTERNATIVE_LINK_NAME[resolv-conf] = "${sysconfdir}/resolv.conf"
+ALTERNATIVE_PRIORITY[resolv-conf] ?= "50"
+
+ALTERNATIVE_TARGET[halt] = "${base_bindir}/systemctl"
+ALTERNATIVE_LINK_NAME[halt] = "${base_sbindir}/halt"
+ALTERNATIVE_PRIORITY[halt] ?= "300"
+
+ALTERNATIVE_TARGET[reboot] = "${base_bindir}/systemctl"
+ALTERNATIVE_LINK_NAME[reboot] = "${base_sbindir}/reboot"
+ALTERNATIVE_PRIORITY[reboot] ?= "300"
+
+ALTERNATIVE_TARGET[shutdown] = "${base_bindir}/systemctl"
+ALTERNATIVE_LINK_NAME[shutdown] = "${base_sbindir}/shutdown"
+ALTERNATIVE_PRIORITY[shutdown] ?= "300"
+
+ALTERNATIVE_TARGET[poweroff] = "${base_bindir}/systemctl"
+ALTERNATIVE_LINK_NAME[poweroff] = "${base_sbindir}/poweroff"
+ALTERNATIVE_PRIORITY[poweroff] ?= "300"
+
+ALTERNATIVE_TARGET[runlevel] = "${base_bindir}/systemctl"
+ALTERNATIVE_LINK_NAME[runlevel] = "${base_sbindir}/runlevel"
+ALTERNATIVE_PRIORITY[runlevel] ?= "300"
+
+pkg_postinst_${PN} () {
+	sed -e '/^hosts:/s/\s*\<myhostname\>//' \
+		-e 's/\(^hosts:.*\)\(\<files\>\)\(.*\)\(\<dns\>\)\(.*\)/\1\2 myhostname \3\4\5/' \
+		-i $D${sysconfdir}/nsswitch.conf
+}
+
+pkg_prerm_${PN} () {
+	sed -e '/^hosts:/s/\s*\<myhostname\>//' \
+		-e '/^hosts:/s/\s*myhostname//' \
+		-i $D${sysconfdir}/nsswitch.conf
+}
+
+PACKAGE_WRITE_DEPS += "qemu-native"
+pkg_postinst_udev-hwdb () {
+	if test -n "$D"; then
+		$INTERCEPT_DIR/postinst_intercept update_udev_hwdb ${PKG} mlprefix=${MLPREFIX} binprefix=${MLPREFIX}
+	else
+		udevadm hwdb --update
+	fi
+}
+
+pkg_prerm_udev-hwdb () {
+	rm -f $D${sysconfdir}/udev/hwdb.bin
+}
diff --git a/poky/meta/recipes-core/sysvinit/sysvinit-2.88dsf/0001-include-sys-sysmacros.h-for-major-minor-defines-in-g.patch b/poky/meta/recipes-core/sysvinit/sysvinit-2.88dsf/0001-include-sys-sysmacros.h-for-major-minor-defines-in-g.patch
new file mode 100644
index 0000000..2575b59
--- /dev/null
+++ b/poky/meta/recipes-core/sysvinit/sysvinit-2.88dsf/0001-include-sys-sysmacros.h-for-major-minor-defines-in-g.patch
@@ -0,0 +1,71 @@
+From 29c7a529d3bb0c1e20239f885e74c5036f1a908c Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 6 Aug 2018 15:38:58 -0700
+Subject: [PATCH] include sys/sysmacros.h for major/minor defines in glibc
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Pending
+---
+ src/bootlogd.c |   3 +++
+ src/bootlogd.o | Bin 58448 -> 60376 bytes
+ src/dowall.c   |   3 +++
+ src/shutdown.c |   4 +++-
+ 4 files changed, 9 insertions(+), 1 deletion(-)
+
+Index: sysvinit-2.88dsf/src/bootlogd.c
+===================================================================
+--- sysvinit-2.88dsf.orig/src/bootlogd.c
++++ sysvinit-2.88dsf/src/bootlogd.c
+@@ -53,6 +53,9 @@
+ #ifdef __linux__
+ #include <sys/mount.h>
+ #endif
++#ifdef __GLIBC__
++#include <sys/sysmacros.h>
++#endif
+ 
+ char *Version = "@(#) bootlogd 2.86 03-Jun-2004 miquels@cistron.nl";
+ 
+Index: sysvinit-2.88dsf/src/dowall.c
+===================================================================
+--- sysvinit-2.88dsf.orig/src/dowall.c
++++ sysvinit-2.88dsf/src/dowall.c
+@@ -37,6 +37,9 @@
+ #include <signal.h>
+ #include <setjmp.h>
+ #include <paths.h>
++#ifdef __GLIBC__
++#include <sys/sysmacros.h>
++#endif
+ 
+ #ifndef _PATH_DEV
+ # define _PATH_DEV	"/dev/"
+Index: sysvinit-2.88dsf/src/shutdown.c
+===================================================================
+--- sysvinit-2.88dsf.orig/src/shutdown.c
++++ sysvinit-2.88dsf/src/shutdown.c
+@@ -57,7 +57,9 @@
+ #include "reboot.h"
+ #include "initreq.h"
+ #include "init.h"
+-
++#ifdef __GLIBC__
++#include <sys/sysmacros.h>
++#endif
+ 
+ char *Version = "@(#) shutdown 2.86-1 31-Jul-2004 miquels@cistron.nl";
+ 
+Index: sysvinit-2.88dsf/src/mountpoint.c
+===================================================================
+--- sysvinit-2.88dsf.orig/src/mountpoint.c
++++ sysvinit-2.88dsf/src/mountpoint.c
+@@ -32,6 +32,9 @@
+ #include <stdarg.h>
+ #include <getopt.h>
+ #include <stdio.h>
++#ifdef __GLIBC__
++#include <sys/sysmacros.h>
++#endif
+ 
+ int dostat(char *path, struct stat *st, int do_lstat, int quiet)
+ {
diff --git a/poky/meta/recipes-core/sysvinit/sysvinit_2.88dsf.bb b/poky/meta/recipes-core/sysvinit/sysvinit_2.88dsf.bb
index 89b1b69..bfc1283 100644
--- a/poky/meta/recipes-core/sysvinit/sysvinit_2.88dsf.bb
+++ b/poky/meta/recipes-core/sysvinit/sysvinit_2.88dsf.bb
@@ -15,6 +15,7 @@
            file://pidof-add-m-option.patch \
            file://0001-This-fixes-an-issue-that-clang-reports-about-mutlipl.patch \
            file://realpath.patch \
+           file://0001-include-sys-sysmacros.h-for-major-minor-defines-in-g.patch \
            file://rcS-default \
            file://rc \
            file://rcS \
@@ -29,7 +30,7 @@
 B = "${S}/src"
 
 inherit update-alternatives distro_features_check
-DEPENDS_append = " update-rc.d-native base-passwd"
+DEPENDS_append = " update-rc.d-native base-passwd virtual/crypt"
 
 REQUIRED_DISTRO_FEATURES = "sysvinit"
 
diff --git a/poky/meta/recipes-core/udev/eudev_3.2.5.bb b/poky/meta/recipes-core/udev/eudev_3.2.5.bb
index 88ad8f1..592dd8f 100644
--- a/poky/meta/recipes-core/udev/eudev_3.2.5.bb
+++ b/poky/meta/recipes-core/udev/eudev_3.2.5.bb
@@ -30,6 +30,7 @@
 EXTRA_OECONF = " \
     --sbindir=${base_sbindir} \
     --with-rootlibdir=${base_libdir} \
+    --with-rootlibexecdir=${nonarch_base_libdir}/udev \
     --with-rootprefix= \
 "
 
@@ -49,6 +50,10 @@
 
 	# hid2hci has moved to bluez4. removed in udev as of version 169
 	rm -f ${D}${base_libdir}/udev/hid2hci
+
+	# duplicate udevadm for postinst script
+	install -d ${D}${libexecdir}
+	ln ${D}${bindir}/udevadm ${D}${libexecdir}/${MLPREFIX}udevadm
 }
 
 do_install_prepend_class-target () {
@@ -64,7 +69,7 @@
 PACKAGES =+ "eudev-hwdb"
 
 
-FILES_${PN} += "${libexecdir} ${base_libdir}/udev ${bindir}/udevadm"
+FILES_${PN} += "${libexecdir} ${nonarch_base_libdir}/udev ${bindir}/udevadm"
 FILES_${PN}-dev = "${datadir}/pkgconfig/udev.pc \
                    ${includedir}/libudev.h ${libdir}/libudev.so \
                    ${includedir}/udev.h ${libdir}/libudev.la \
@@ -80,8 +85,7 @@
 PACKAGE_WRITE_DEPS += "qemu-native"
 pkg_postinst_eudev-hwdb () {
     if test -n "$D"; then
-        ${@qemu_run_binary(d, '$D', '${bindir}/udevadm')} hwdb --update --root $D
-        chown root:root $D${sysconfdir}/udev/hwdb.bin
+        $INTERCEPT_DIR/postinst_intercept update_udev_hwdb ${PKG} mlprefix=${MLPREFIX} binprefix=${MLPREFIX}
     else
         udevadm hwdb --update
     fi
diff --git a/poky/meta/recipes-core/udev/udev-extraconf/mount.sh b/poky/meta/recipes-core/udev/udev-extraconf/mount.sh
index d760328..3ee67b1 100644
--- a/poky/meta/recipes-core/udev/udev-extraconf/mount.sh
+++ b/poky/meta/recipes-core/udev/udev-extraconf/mount.sh
@@ -4,10 +4,28 @@
 #
 # Attempt to mount any added block devices and umount any removed devices
 
+BASE_INIT="`readlink -f "@base_sbindir@/init"`"
+INIT_SYSTEMD="@systemd_unitdir@/systemd"
 
-MOUNT="/bin/mount"
+if [ "x$BASE_INIT" = "x$INIT_SYSTEMD" ];then
+    # systemd as init uses systemd-mount to mount block devices
+    MOUNT="/usr/bin/systemd-mount"
+    UMOUNT="/usr/bin/systemd-umount"
+
+    if [ -x $MOUNT ] && [ -x $UMOUNT ];
+    then
+        logger "Using systemd-mount to finish mount"
+    else
+        logger "Linux init is using systemd, so please install systemd-mount to finish mount"
+        exit 1
+    fi
+else
+    MOUNT="/bin/mount"
+    UMOUNT="/bin/umount"
+fi
+
 PMOUNT="/usr/bin/pmount"
-UMOUNT="/bin/umount"
+
 for line in `grep -h -v ^# /etc/udev/mount.blacklist /etc/udev/mount.blacklist.d/*`
 do
 	if [ ` expr match "$DEVNAME" "$line" ` -gt 0 ];
@@ -17,16 +35,63 @@
 	fi
 done
 
-automount() {	
+automount_systemd() {
+    name="`basename "$DEVNAME"`"
+
+    # Skip the partition which are already in /etc/fstab
+    grep "^[[:space:]]*$DEVNAME" /etc/fstab && return
+    for n in LABEL PARTLABEL UUID PARTUUID; do
+        tmp="$(lsblk -o $n $DEVNAME | sed -e '1d')"
+        test -z "$tmp" && continue
+        tmp="$n=$tmp"
+        grep "^[[:space:]]*$tmp" /etc/fstab && return
+    done
+
+    [ -d "/run/media/$name" ] || mkdir -p "/run/media/$name"
+
+    MOUNT="$MOUNT -o silent"
+
+    # If filesystemtype is vfat, change the ownership group to 'disk', and
+    # grant it with  w/r/x permissions.
+    case $ID_FS_TYPE in
+    vfat|fat)
+        MOUNT="$MOUNT -o umask=007,gid=`awk -F':' '/^disk/{print $3}' /etc/group`"
+        ;;
+    # TODO
+    *)
+        ;;
+    esac
+
+    if ! $MOUNT --no-block -t auto $DEVNAME "/run/media/$name"
+    then
+        #logger "mount.sh/automount" "$MOUNT -t auto $DEVNAME \"/run/media/$name\" failed!"
+        rm_dir "/run/media/$name"
+    else
+        logger "mount.sh/automount" "Auto-mount of [/run/media/$name] successful"
+        touch "/tmp/.automount-$name"
+    fi
+}
+
+automount() {
 	name="`basename "$DEVNAME"`"
 
+	if [ -x "$PMOUNT" ]; then
+		$PMOUNT $DEVNAME 2> /dev/null
+	elif [ -x $MOUNT ]; then
+		$MOUNT $DEVNAME 2> /dev/null
+	fi
+
+	# If the device isn't mounted at this point, it isn't
+	# configured in fstab
+	grep -q "^$DEVNAME " /proc/mounts && return
+
 	! test -d "/run/media/$name" && mkdir -p "/run/media/$name"
 	# Silent util-linux's version of mounting auto
 	if [ "x`readlink $MOUNT`" = "x/bin/mount.util-linux" ] ;
 	then
 		MOUNT="$MOUNT -o silent"
 	fi
-	
+
 	# If filesystem type is vfat, change the ownership group to 'disk', and
 	# grant it with  w/r/x permissions.
 	case $ID_FS_TYPE in
@@ -63,28 +128,24 @@
 [ -e /sys/block/$name/device/media ] && media_type=`cat /sys/block/$name/device/media`
 
 if [ "$ACTION" = "add" ] && [ -n "$DEVNAME" ] && [ -n "$ID_FS_TYPE" -o "$media_type" = "cdrom" ]; then
-	if [ -x "$PMOUNT" ]; then
-		$PMOUNT $DEVNAME 2> /dev/null
-	elif [ -x $MOUNT ]; then
-    		$MOUNT $DEVNAME 2> /dev/null
-	fi
-	
-	# If the device isn't mounted at this point, it isn't
-	# configured in fstab (note the root filesystem can show up as
-	# /dev/root in /proc/mounts, so check the device number too)
-	if expr $MAJOR "*" 256 + $MINOR != `stat -c %d /`; then
-		grep -q "^$DEVNAME " /proc/mounts || automount
-	fi
+    # Note the root filesystem can show up as /dev/root in /proc/mounts,
+    # so check the device number too
+    if expr $MAJOR "*" 256 + $MINOR != `stat -c %d /`; then
+        if [ "`basename $MOUNT`" = "systemd-mount" ];then
+            automount_systemd
+        else
+            automount
+        fi
+    fi
 fi
 
-
 if [ "$ACTION" = "remove" ] || [ "$ACTION" = "change" ] && [ -x "$UMOUNT" ] && [ -n "$DEVNAME" ]; then
-	for mnt in `cat /proc/mounts | grep "$DEVNAME" | cut -f 2 -d " " `
-	do
-		$UMOUNT $mnt
-	done
-	
-	# Remove empty directories from auto-mounter
-	name="`basename "$DEVNAME"`"
-	test -e "/tmp/.automount-$name" && rm_dir "/run/media/$name"
+    for mnt in `cat /proc/mounts | grep "$DEVNAME" | cut -f 2 -d " " `
+    do
+        $UMOUNT $mnt
+    done
+
+    # Remove empty directories from auto-mounter
+    name="`basename "$DEVNAME"`"
+    test -e "/tmp/.automount-$name" && rm_dir "/run/media/$name"
 fi
diff --git a/poky/meta/recipes-core/udev/udev-extraconf_1.1.bb b/poky/meta/recipes-core/udev/udev-extraconf_1.1.bb
index 43a1cff..90f933d 100644
--- a/poky/meta/recipes-core/udev/udev-extraconf_1.1.bb
+++ b/poky/meta/recipes-core/udev/udev-extraconf_1.1.bb
@@ -29,6 +29,9 @@
     install -d ${D}${sysconfdir}/udev/scripts/
 
     install -m 0755 ${WORKDIR}/mount.sh ${D}${sysconfdir}/udev/scripts/mount.sh
+    sed -i 's|@systemd_unitdir@|${systemd_unitdir}|g' ${D}${sysconfdir}/udev/scripts/mount.sh
+    sed -i 's|@base_sbindir@|${base_sbindir}|g' ${D}${sysconfdir}/udev/scripts/mount.sh
+
     install -m 0755 ${WORKDIR}/network.sh ${D}${sysconfdir}/udev/scripts
 }
 
diff --git a/poky/meta/recipes-core/update-rc.d/update-rc.d/add-verbose.patch b/poky/meta/recipes-core/update-rc.d/update-rc.d/add-verbose.patch
deleted file mode 100644
index fb443ff..0000000
--- a/poky/meta/recipes-core/update-rc.d/update-rc.d/add-verbose.patch
+++ /dev/null
@@ -1,49 +0,0 @@
-Upstream-Status: Pending
-
---- update-rc.d/update-rc.d.org	2005-01-03 00:30:47.000000000 +0200
-+++ update-rc.d/update-rc.d	2007-12-01 19:41:08.000000000 +0200
-@@ -19,6 +19,7 @@
- notreally=0
- force=0
- dostart=0
-+verbose=0
- 
- usage()
- {
-@@ -28,6 +29,7 @@
-        update-rc.d [-n] [-r <root>] [-s] <basename> start|stop NN runlvl [runlvl] [...] .
- 		-n: not really
- 		-f: force
-+		-v: verbose
- 		-r: alternate root path (default is /)
- 		-s: invoke start methods if appropriate to current runlevel
- EOF
-@@ -69,7 +71,7 @@
- 	lev=`echo $2 | cut -d/ -f1`
- 	nn=`echo $2 | cut -d/ -f2`
- 	fn="${etcd}${lev}.d/${startstop}${nn}${bn}"
--	echo "  $fn -> ../init.d/$bn"
-+	[ $verbose -eq 1 ] && echo "  $fn -> ../init.d/$bn"
- 	if [ $notreally -eq 0 ]; then
- 		mkdir -p `dirname $fn`
-  		ln -s ../init.d/$bn $fn
-@@ -89,7 +91,7 @@
- 		exit 0
- 	fi
- 
--	echo " Adding system startup for $initd/$bn ..."
-+	echo " Adding system startup for $initd/$bn."
- 
- 	for i in $startlinks; do
- 		dolink S $i
-@@ -105,6 +107,10 @@
- 			shift
- 			continue
- 			;;
-+		-v)	verbose=1
-+			shift
-+			continue
-+			;;
- 		-f)	force=1
- 			shift
- 			continue
diff --git a/poky/meta/recipes-core/update-rc.d/update-rc.d/check-if-symlinks-are-valid.patch b/poky/meta/recipes-core/update-rc.d/update-rc.d/check-if-symlinks-are-valid.patch
deleted file mode 100644
index 075171a..0000000
--- a/poky/meta/recipes-core/update-rc.d/update-rc.d/check-if-symlinks-are-valid.patch
+++ /dev/null
@@ -1,59 +0,0 @@
-Check if symlinks are valid
-
-When using root option and $initd/$bn is a symlink, the script would fail because
-the symlink points to a path on target. For example:
-
-/path/to/target/rootfs/etc/init.d/syslog -> /etc/init.d/syslog.busybox
-
-Hence, [ -f /path/to/target/rootfs/etc/init.d/syslog ] condition would return
-false.
-
-This patch adds the posibility to check whether the file the symlink points to
-actually exists in rootfs path and then continue.
-
-Upstream-Status: Pending
-
-Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com> 
-Signed-off-by: Christopher Larson <chris_larson@mentor.com>
-
-Index: git/update-rc.d
-===================================================================
---- git.orig/update-rc.d
-+++ git/update-rc.d
-@@ -147,13 +147,34 @@ fi
- bn=$1
- shift
- 
-+sn=$initd/$bn
-+if [ -L "$sn" -a -n "$root" ]; then
-+	if which readlink >/dev/null; then
-+		while true; do
-+			linksn="$(readlink "$sn")"
-+			if [ -z "$linksn" ]; then
-+				break
-+			fi
-+
-+			sn="$linksn"
-+			case "$sn" in
-+				/*) sn="$root$sn" ;;
-+				*)  sn="$initd/$sn" ;;
-+			esac
-+		done
-+	else
-+		echo "update-rc.d: readlink tool not present, cannot check whether \
-+				$sn symlink points to a valid file." >&2
-+	fi
-+fi
-+
- if [ $1 != "remove" ]; then
--	if [ ! -f "$initd/$bn" ]; then
-+	if [ ! -f "$sn" ]; then
- 		echo "update-rc.d: $initd/$bn: file does not exist" >&2
- 		exit 1
- 	fi
- else
--	if [ -f "$initd/$bn" ]; then
-+	if [ -f "$sn" ]; then
- 		if [ $force -eq 1 ]; then
- 			echo "update-rc.d: $initd/$bn exists during rc.d purge (continuing)" >&2
- 		else
diff --git a/poky/meta/recipes-core/update-rc.d/update-rc.d/fix-to-handle-priority-numbers-correctly.patch b/poky/meta/recipes-core/update-rc.d/update-rc.d/fix-to-handle-priority-numbers-correctly.patch
deleted file mode 100644
index 85bc234..0000000
--- a/poky/meta/recipes-core/update-rc.d/update-rc.d/fix-to-handle-priority-numbers-correctly.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-Upstream-Status: Pending
-
-Fix to handle priority numbers correctly.
-Previously, if the priority number is '08' or '09', for example,
-the script cannot handle them correctly as these numbers are treated
-as octal numbers.
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- update-rc.d |    2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/update-rc.d b/update-rc.d
-index ec50d15..c70b859 100644
---- a/update-rc.d
-+++ b/update-rc.d
-@@ -205,7 +205,7 @@ case $1 in
- 				exit 1
- 			fi
- 			shift
--			NN=`printf %02d $1`
-+			NN=`printf %02d $(expr $1 + 0)`
- 			shift
- 			while [ "x$1" != "x." ]; do
- 				if [ $# -eq 0 ]; then
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-core/update-rc.d/update-rc.d_0.7.bb b/poky/meta/recipes-core/update-rc.d/update-rc.d_0.7.bb
deleted file mode 100644
index 76d4312..0000000
--- a/poky/meta/recipes-core/update-rc.d/update-rc.d_0.7.bb
+++ /dev/null
@@ -1,33 +0,0 @@
-SUMMARY = "manage symlinks in /etc/rcN.d"
-HOMEPAGE = "http://github.com/philb/update-rc.d/"
-DESCRIPTION = "update-rc.d is a utility that allows the management of symlinks to the initscripts in the /etc/rcN.d directory structure."
-SECTION = "base"
-
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://update-rc.d;beginline=5;endline=15;md5=148a48321b10eb37c1fa3ee02b940a75"
-
-PR = "r5"
-
-# Revision corresponding to tag update-rc.d_0.7
-SRCREV = "eca680ddf28d024954895f59a241a622dd575c11"
-
-SRC_URI = "git://github.com/philb/update-rc.d.git \
-           file://add-verbose.patch \
-           file://check-if-symlinks-are-valid.patch \
-           file://fix-to-handle-priority-numbers-correctly.patch \
-          "
-UPSTREAM_CHECK_COMMITS = "1"
-
-S = "${WORKDIR}/git"
-
-inherit allarch
-
-do_compile() {
-}
-
-do_install() {
-	install -d ${D}${sbindir}
-	install -m 0755 ${S}/update-rc.d ${D}${sbindir}/update-rc.d
-}
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-core/update-rc.d/update-rc.d_0.8.bb b/poky/meta/recipes-core/update-rc.d/update-rc.d_0.8.bb
new file mode 100644
index 0000000..baa21ae
--- /dev/null
+++ b/poky/meta/recipes-core/update-rc.d/update-rc.d_0.8.bb
@@ -0,0 +1,26 @@
+SUMMARY = "manage symlinks in /etc/rcN.d"
+HOMEPAGE = "http://github.com/philb/update-rc.d/"
+DESCRIPTION = "update-rc.d is a utility that allows the management of symlinks to the initscripts in the /etc/rcN.d directory structure."
+SECTION = "base"
+
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://update-rc.d;beginline=5;endline=15;md5=148a48321b10eb37c1fa3ee02b940a75"
+
+SRC_URI = "git://git.yoctoproject.org/update-rc.d"
+SRCREV = "22e0692898c3e7ceedc8eb5ff4ec8e0b9c340b2d"
+
+UPSTREAM_CHECK_COMMITS = "1"
+
+S = "${WORKDIR}/git"
+
+inherit allarch
+
+do_compile() {
+}
+
+do_install() {
+	install -d ${D}${sbindir}
+	install -m 0755 ${S}/update-rc.d ${D}${sbindir}/update-rc.d
+}
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-core/util-linux/util-linux.inc b/poky/meta/recipes-core/util-linux/util-linux.inc
index 0b7db52..a05c1ca 100644
--- a/poky/meta/recipes-core/util-linux/util-linux.inc
+++ b/poky/meta/recipes-core/util-linux/util-linux.inc
@@ -35,7 +35,7 @@
              util-linux-lsblk util-linux-mkfs.cramfs util-linux-fstrim \
              util-linux-partx util-linux-hwclock util-linux-mountpoint \
              util-linux-findfs util-linux-getopt util-linux-sulogin util-linux-prlimit \
-             util-linux-ionice util-linux-switch-root"
+             util-linux-ionice util-linux-switch-root util-linux-unshare"
 PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'pylibmount', 'util-linux-pylibmount', '', d)}"
 PACKAGES =+ "${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'util-linux-runuser util-linux-su', '', d)}"
 
@@ -46,7 +46,7 @@
                        --enable-kill --enable-last --enable-mesg --enable-partx \
                        --enable-raw --enable-rfkill --disable-login \
                        --disable-vipw --disable-newgrp --disable-chfn-chsh \
-                       --enable-write --enable-mount \
+                       --enable-write --enable-mount --enable-unshare \
                        --enable-libuuid --enable-libblkid --enable-fsck \
                        --disable-minix --disable-bfs --without-udev \
                        usrsbin_execdir='${sbindir}' \
@@ -75,7 +75,7 @@
 
 FILES_util-linux-agetty = "${base_sbindir}/agetty"
 FILES_util-linux-fdisk = "${base_sbindir}/fdisk.${BPN}"
-FILES_util-linux-fstrim = "${base_sbindir}/fstrim"
+FILES_util-linux-fstrim = "${base_sbindir}/fstrim.${BPN}"
 FILES_util-linux-cfdisk = "${base_sbindir}/cfdisk"
 FILES_util-linux-sfdisk = "${sbindir}/sfdisk"
 FILES_util-linux-swaponoff = "${base_sbindir}/swapon.${BPN} ${base_sbindir}/swapoff.${BPN}"
@@ -93,7 +93,7 @@
 FILES_util-linux-getopt = "${base_bindir}/getopt.${BPN}"
 FILES_util-linux-runuser = "${sbindir}/runuser"
 FILES_util-linux-prlimit = "${bindir}/prlimit"
-FILES_util-linux-ionice = "${bindir}/ionice"
+FILES_util-linux-ionice = "${bindir}/ionice.${BPN}"
 FILES_util-linux-su = "${bindir}/su.util-linux ${sysconfdir}/pam.d/su-l"
 CONFFILES_util-linux-su = "${sysconfdir}/pam.d/su-l"
 
@@ -113,6 +113,7 @@
 FILES_util-linux-mountpoint = "${base_bindir}/mountpoint.${BPN}"
 
 FILES_util-linux-switch-root = "${base_sbindir}/switch_root.${BPN}"
+FILES_util-linux-unshare = "${bindir}/unshare.${BPN}"
 
 # Util-linux' blkid replaces the e2fsprogs one
 FILES_util-linux-blkid = "${base_sbindir}/blkid*"
@@ -204,9 +205,12 @@
 
 ALTERNATIVE_PRIORITY = "80"
 
-ALTERNATIVE_${PN}  = "dmesg kill more mkswap blockdev pivot_root switch_root"
-ALTERNATIVE_${PN} += "hexdump last lastb logger mesg renice wall"
-ALTERNATIVE_${PN} += "setsid chrt flock utmpdump eject nologin taskset"
+ALTERNATIVE_${PN}  = " \
+    dmesg kill more mkswap blockdev pivot_root \
+    hexdump last lastb logger mesg renice wall \
+    setsid chrt flock utmpdump eject nologin taskset fallocate \
+    fsfreeze nsenter cal rev \
+"
 
 ALTERNATIVE_LINK_NAME[dmesg] = "${base_bindir}/dmesg"
 ALTERNATIVE_LINK_NAME[kill] = "${base_bindir}/kill"
@@ -214,8 +218,11 @@
 ALTERNATIVE_LINK_NAME[mkswap] = "${base_sbindir}/mkswap"
 ALTERNATIVE_LINK_NAME[blockdev] = "${base_sbindir}/blockdev"
 ALTERNATIVE_LINK_NAME[pivot_root] = "${base_sbindir}/pivot_root"
-ALTERNATIVE_LINK_NAME[switch_root] = "${base_sbindir}/switch_root"
+ALTERNATIVE_LINK_NAME[cal] = "${bindir}/cal"
 ALTERNATIVE_LINK_NAME[eject] = "${bindir}/eject"
+ALTERNATIVE_LINK_NAME[fallocate] = "${bindir}/fallocate"
+ALTERNATIVE_LINK_NAME[rev] = "${bindir}/rev"
+ALTERNATIVE_LINK_NAME[fsfreeze] = "${sbindir}/fsfreeze"
 ALTERNATIVE_LINK_NAME[nologin] = "${base_sbindir}/nologin"
 
 ALTERNATIVE_${PN}-doc = "mountpoint.1 last.1 lastb.1 mesg.1 wall.1 nologin.8 sulogin.8 utmpdump.1 rfkill.8 kill.1 libblkid.3 blkid.8 findfs.8 fsck.8 uuid.3 eject.1 logger.1"
@@ -244,6 +251,9 @@
 ALTERNATIVE_util-linux-fdisk = "fdisk"
 ALTERNATIVE_LINK_NAME[fdisk] = "${base_sbindir}/fdisk"
 
+ALTERNATIVE_util-linux-fstrim = "fstrim"
+ALTERNATIVE_LINK_NAME[fstrim] = "${base_sbindir}/fstrim"
+
 ALTERNATIVE_util-linux-agetty = "getty"
 ALTERNATIVE_LINK_NAME[getty] = "${base_sbindir}/getty"
 ALTERNATIVE_TARGET[getty] = "${base_sbindir}/agetty"
@@ -282,6 +292,15 @@
 ALTERNATIVE_util-linux-mountpoint = "mountpoint"
 ALTERNATIVE_LINK_NAME[mountpoint] = "${base_bindir}/mountpoint"
 
+ALTERNATIVE_util-linux-unshare = "unshare"
+ALTERNATIVE_LINK_NAME[unshare] = "${bindir}/unshare"
+
+ALTERNATIVE_util-linux-ionice = "ionice"
+ALTERNATIVE_LINK_NAME[ionice] = "${bindir}/ionice"
+
+ALTERNATIVE_util-linux-switch-root = "switch_root"
+ALTERNATIVE_LINK_NAME[switch_root] = "${base_sbindir}/switch_root"
+
 BBCLASSEXTEND = "native nativesdk"
 
 python do_package_prepend () {
diff --git a/poky/meta/recipes-core/util-linux/util-linux_2.32.1.bb b/poky/meta/recipes-core/util-linux/util-linux_2.32.1.bb
index 455b937..a616d85 100644
--- a/poky/meta/recipes-core/util-linux/util-linux_2.32.1.bb
+++ b/poky/meta/recipes-core/util-linux/util-linux_2.32.1.bb
@@ -21,10 +21,8 @@
 CACHED_CONFIGUREVARS += "scanf_cv_alloc_modifier=ms"
 
 EXTRA_OECONF_class-native = "${SHARED_EXTRA_OECONF} \
-                             --disable-fallocate \
 			     --disable-use-tty-group \
 "
 EXTRA_OECONF_class-nativesdk = "${SHARED_EXTRA_OECONF} \
-                                --disable-fallocate \
 				--disable-use-tty-group \
 "
diff --git a/poky/meta/recipes-core/volatile-binds/files/mount-copybind b/poky/meta/recipes-core/volatile-binds/files/mount-copybind
index 2aeaf84..fddf520 100755
--- a/poky/meta/recipes-core/volatile-binds/files/mount-copybind
+++ b/poky/meta/recipes-core/volatile-binds/files/mount-copybind
@@ -8,7 +8,10 @@
     exit 1
 fi
 
+# e.g. /var/volatile/lib
 spec=$1
+
+# e.g. /var/lib
 mountpoint=$2
 
 if [ $# -gt 2 ]; then
@@ -20,15 +23,34 @@
 [ -n "$options" ] && options=",$options"
 
 mkdir -p "${spec%/*}"
+
 if [ -d "$mountpoint" ]; then
-    if [ ! -d "$spec" ]; then
+
+    if [ -d "$spec" ]; then
+        specdir_existed=yes
+    else
+        specdir_existed=no
         mkdir "$spec"
-        cp -pPR "$mountpoint"/. "$spec/"
+    fi
+
+    # Fast version of calculating `dirname ${spec}`/.`basename ${spec}`-work
+    overlay_workdir="${spec%/*}/.${spec##*/}-work"
+    mkdir "${overlay_workdir}"
+
+    # Try to mount using overlay, which is must faster than copying files.
+    # If that fails, fall back to slower copy.
+    if ! mount -t overlay overlay -olowerdir="$mountpoint",upperdir="$spec",workdir="$overlay_workdir" "$mountpoint" > /dev/null 2>&1; then
+
+        if [ "$specdir_existed" != "yes" ]; then
+            cp -pPR "$mountpoint"/. "$spec/"
+        fi
+
+        mount -o "bind$options" "$spec" "$mountpoint"
     fi
 elif [ -f "$mountpoint" ]; then
     if [ ! -f "$spec" ]; then
         cp -pP "$mountpoint" "$spec"
     fi
-fi
 
-mount -o "bind$options" "$spec" "$mountpoint"
+    mount -o "bind$options" "$spec" "$mountpoint"
+fi
diff --git a/poky/meta/recipes-devtools/autoconf/autoconf.inc b/poky/meta/recipes-devtools/autoconf/autoconf.inc
index df81bc6..b82af5a 100644
--- a/poky/meta/recipes-devtools/autoconf/autoconf.inc
+++ b/poky/meta/recipes-devtools/autoconf/autoconf.inc
@@ -10,24 +10,49 @@
 DEPENDS_class-nativesdk = "nativesdk-m4 nativesdk-gnu-config"
 RDEPENDS_${PN} = "m4 gnu-config \
 		  perl \
+		  perl-module-bytes \
 		  perl-module-carp \
 		  perl-module-constant \
+		  perl-module-data-dumper \
 		  perl-module-errno \
 		  perl-module-exporter \
 		  perl-module-file-basename \
 		  perl-module-file-compare \
 		  perl-module-file-copy \
+		  perl-module-file-find \
 		  perl-module-file-glob \
 		  perl-module-file-path \
 		  perl-module-file-stat \
-		  perl-module-file-find \
 		  perl-module-getopt-long \
 		  perl-module-io-file \
 		  perl-module-posix \
-		  perl-module-data-dumper \
+		  perl-module-thread-queue \
+		  perl-module-threads \
 		 "
 RDEPENDS_${PN}_class-native = "m4-native gnu-config-native"
-RDEPENDS_${PN}_class-nativesdk = "nativesdk-m4 nativesdk-gnu-config"
+RDEPENDS_${PN}_class-nativesdk = "\
+		  nativesdk-gnu-config \
+		  nativesdk-m4 \
+		  nativesdk-perl \
+		  nativesdk-perl-module-bytes \
+		  nativesdk-perl-module-carp \
+		  nativesdk-perl-module-constant \
+		  nativesdk-perl-module-data-dumper \
+		  nativesdk-perl-module-errno \
+		  nativesdk-perl-module-exporter \
+		  nativesdk-perl-module-file-basename \
+		  nativesdk-perl-module-file-compare \
+		  nativesdk-perl-module-file-copy \
+		  nativesdk-perl-module-file-find \
+		  nativesdk-perl-module-file-glob \
+		  nativesdk-perl-module-file-path \
+		  nativesdk-perl-module-file-stat \
+		  nativesdk-perl-module-getopt-long \
+		  nativesdk-perl-module-io-file \
+		  nativesdk-perl-module-posix \
+		  nativesdk-perl-module-thread-queue \
+		  nativesdk-perl-module-threads \
+                  "
 
 SRC_URI = "${GNU_MIRROR}/autoconf/autoconf-${PV}.tar.gz \
 	   file://program_prefix.patch"
diff --git a/poky/meta/recipes-devtools/automake/automake/0001-automake-Add-default-libtool_tag-to-cppasm.patch b/poky/meta/recipes-devtools/automake/automake/0001-automake-Add-default-libtool_tag-to-cppasm.patch
index 1221f13..deb1d03 100644
--- a/poky/meta/recipes-devtools/automake/automake/0001-automake-Add-default-libtool_tag-to-cppasm.patch
+++ b/poky/meta/recipes-devtools/automake/automake/0001-automake-Add-default-libtool_tag-to-cppasm.patch
@@ -1,4 +1,4 @@
-From 25a8ac30486798d23f516722d73eb622e6264f28 Mon Sep 17 00:00:00 2001
+From b3c6e1971786cd93a2e3017c92bfbfe96baaf2f7 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Wed, 26 Jul 2017 11:19:56 -0700
 Subject: [PATCH] automake: Add default libtool_tag to cppasm.
@@ -6,19 +6,19 @@
     * bin/automake.in (register_language): Define default libtool tag to be CC
     since CPPASCOMPILE is using CC to call assembler
 
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
 Upstream-Status: Submitted
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
+---
  bin/automake.in | 1 +
  1 file changed, 1 insertion(+)
 
-Index: automake-1.15.1/bin/automake.in
-===================================================================
---- automake-1.15.1.orig/bin/automake.in
-+++ automake-1.15.1/bin/automake.in
-@@ -831,6 +831,7 @@ register_language ('name' => 'cppasm',
- 		   'compiler' => 'CPPASCOMPILE',
+diff --git a/bin/automake.in b/bin/automake.in
+index 3a66965..08ba09a 100644
+--- a/bin/automake.in
++++ b/bin/automake.in
+@@ -898,6 +898,7 @@ register_language ('name' => 'cppasm',
+                    'libtool_tag' => 'CC',
  		   'compile_flag' => '-c',
  		   'output_flag' => '-o',
 +		   'libtool_tag' => 'CC',
diff --git a/poky/meta/recipes-devtools/automake/automake/0001-build-fix-race-in-parallel-builds.patch b/poky/meta/recipes-devtools/automake/automake/0001-build-fix-race-in-parallel-builds.patch
new file mode 100644
index 0000000..591fce1
--- /dev/null
+++ b/poky/meta/recipes-devtools/automake/automake/0001-build-fix-race-in-parallel-builds.patch
@@ -0,0 +1,65 @@
+From 592eb55b248a765abfc796fccb68baa3d53745ac Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 26 Jul 2018 00:58:12 -0700
+Subject: [PATCH] build: fix race in parallel builds
+
+The automake-$(APIVERSION) is a hardlink of automake, if it is
+created later than update_mans executing, there is a failure
+[snip]
+|: && mkdir -p doc && ./pre-inst-env /usr/bin/env perl
+../automake-1.16.1/doc/help2man --output=doc/aclocal-1.16.1
+aclocal-1.16
+|help2man: can't get `--help' info from aclocal-1.16
+|Try `--no-discard-stderr' if option outputs to stderr
+Makefile:3693: recipe for target 'doc/aclocal-1.16.1' failed
+[snip]
+
+The automake_script is required by update_mans and update_mans
+invokes automake-$(APIVERSION) rather than automake to generate
+doc, so we should assign `automake-$(APIVERSION)' to automake_script.
+
+The same reason to tweak aclocal_script.
+
+* bin/local.mk: correct automake_script/aclocal_script
+
+Upstream-Status: Submitted [automake-patches@gnu.org]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ Makefile.in  | 4 ++--
+ bin/local.mk | 4 ++--
+ 2 files changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index c3e934c..7cddb8d 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -691,8 +691,8 @@ bin_SCRIPTS = bin/automake bin/aclocal
+ # Used by maintainer checks and such.
+ automake_in = $(srcdir)/bin/automake.in
+ aclocal_in = $(srcdir)/bin/aclocal.in
+-automake_script = bin/automake
+-aclocal_script = bin/aclocal
++automake_script = bin/automake-$(APIVERSION)
++aclocal_script  = bin/aclocal-$(APIVERSION)
+ AUTOMAKESOURCES = $(automake_in) $(aclocal_in)
+ info_TEXINFOS = doc/automake.texi doc/automake-history.texi
+ doc_automake_TEXINFOS = doc/fdl.texi
+diff --git a/bin/local.mk b/bin/local.mk
+index 97b38db..058ca99 100644
+--- a/bin/local.mk
++++ b/bin/local.mk
+@@ -31,8 +31,8 @@ CLEANFILES += \
+ # Used by maintainer checks and such.
+ automake_in = $(srcdir)/%D%/automake.in
+ aclocal_in  = $(srcdir)/%D%/aclocal.in
+-automake_script = %D%/automake
+-aclocal_script  = %D%/aclocal
++automake_script = %D%/automake-$(APIVERSION)
++aclocal_script  = %D%/aclocal-$(APIVERSION)
+ 
+ AUTOMAKESOURCES = $(automake_in) $(aclocal_in)
+ TAGS_FILES += $(AUTOMAKESOURCES)
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/automake/automake/automake-replace-w-option-in-shebangs-with-modern-use-warnings.patch b/poky/meta/recipes-devtools/automake/automake/automake-replace-w-option-in-shebangs-with-modern-use-warnings.patch
index 96b5a3d..1592c02 100644
--- a/poky/meta/recipes-devtools/automake/automake/automake-replace-w-option-in-shebangs-with-modern-use-warnings.patch
+++ b/poky/meta/recipes-devtools/automake/automake/automake-replace-w-option-in-shebangs-with-modern-use-warnings.patch
@@ -1,4 +1,4 @@
-From 41e06b7a354774913dcd2e32a35440e407843357 Mon Sep 17 00:00:00 2001
+From 081385f4d4bba367afad3bff1fa034f5263305e6 Mon Sep 17 00:00:00 2001
 From: Serhii Popovych <spopovyc@cisco.com>
 Date: Wed, 10 Feb 2016 17:07:32 +0000
 Subject: [PATCH] perl: Replace -w option in shebangs with modern "use
@@ -15,24 +15,24 @@
 
 Upstream-Status: Pending
 Signed-off-by: Serhii Popovych <spopovyc@cisco.com>
----
- bin/aclocal.in     | 3 ++-
- bin/automake.in    | 3 ++-
- t/wrap/aclocal.in  | 3 ++-
- t/wrap/automake.in | 3 ++-
- 4 files changed, 8 insertions(+), 4 deletions(-)
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
 
-Index: automake-1.15.1/bin/aclocal.in
-===================================================================
---- automake-1.15.1.orig/bin/aclocal.in
-+++ automake-1.15.1/bin/aclocal.in
+---
+ bin/aclocal.in  | 3 ++-
+ bin/automake.in | 3 ++-
+ 2 files changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/bin/aclocal.in b/bin/aclocal.in
+index b3715d9..461d453 100644
+--- a/bin/aclocal.in
++++ b/bin/aclocal.in
 @@ -1,4 +1,4 @@
 -#!@PERL@ -w
 +#!@PERL@
  # -*- perl -*-
  # @configure_input@
  
-@@ -33,6 +33,7 @@ BEGIN
+@@ -32,6 +32,7 @@ BEGIN
  }
  
  use strict;
@@ -40,17 +40,17 @@
  
  use Automake::Config;
  use Automake::General;
-Index: automake-1.15.1/bin/automake.in
-===================================================================
---- automake-1.15.1.orig/bin/automake.in
-+++ automake-1.15.1/bin/automake.in
+diff --git a/bin/automake.in b/bin/automake.in
+index 8377d20..3a66965 100644
+--- a/bin/automake.in
++++ b/bin/automake.in
 @@ -1,4 +1,4 @@
 -#!@PERL@ -w
 +#!@PERL@
  # -*- perl -*-
  # @configure_input@
  
-@@ -28,6 +28,7 @@ eval 'case $# in 0) exec @PERL@ -S "$0";
+@@ -28,6 +28,7 @@ eval 'case $# in 0) exec @PERL@ -S "$0";; *) exec @PERL@ -S "$0" "$@";; esac'
  package Automake;
  
  use strict;
@@ -58,39 +58,3 @@
  
  BEGIN
  {
-Index: automake-1.15.1/t/wrap/aclocal.in
-===================================================================
---- automake-1.15.1.orig/t/wrap/aclocal.in
-+++ automake-1.15.1/t/wrap/aclocal.in
-@@ -1,4 +1,4 @@
--#!@PERL@ -w
-+#!@PERL@
- # @configure_input@
- 
- # Copyright (C) 2012-2017 Free Software Foundation, Inc.
-@@ -19,6 +19,7 @@
- BEGIN
- {
-   use strict;
-+  use warnings;
-   @Aclocal::perl_libdirs = ('@abs_top_srcdir@/lib');
-   unshift @Aclocal::perl_libdirs, '@abs_top_builddir@/lib'
-     if '@srcdir@' ne '.';
-Index: automake-1.15.1/t/wrap/automake.in
-===================================================================
---- automake-1.15.1.orig/t/wrap/automake.in
-+++ automake-1.15.1/t/wrap/automake.in
-@@ -1,4 +1,4 @@
--#!@PERL@ -w
-+#!@PERL@
- # @configure_input@
- 
- # Copyright (C) 2012-2017 Free Software Foundation, Inc.
-@@ -19,6 +19,7 @@
- BEGIN
- {
-   use strict;
-+  use warnings;
-   @Automake::perl_libdirs = ('@abs_top_srcdir@/lib');
-   unshift @Automake::perl_libdirs, '@abs_top_builddir@/lib'
-     if '@srcdir@' ne '.';
diff --git a/poky/meta/recipes-devtools/automake/automake/buildtest.patch b/poky/meta/recipes-devtools/automake/automake/buildtest.patch
index c32cd1f..b88b9e8 100644
--- a/poky/meta/recipes-devtools/automake/automake/buildtest.patch
+++ b/poky/meta/recipes-devtools/automake/automake/buildtest.patch
@@ -1,13 +1,25 @@
+From a860b28069785aa5bf2fa9b671287de9af5004ff Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Bj=C3=B6rn=20Stenberg?= <bjst@enea.com>
+Date: Wed, 19 Dec 2012 17:18:27 +0100
+Subject: [PATCH] Add a new distro feature "ptest".
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
 Split "check-TESTS" into a buildtest and runtest target, so that they can
 be run separately.
 
 Signed-off-by: Björn Stenberg <bjst@enea.com>
 Upstream-Status: Pending
 
-Index: automake-1.15.1/lib/am/check.am
-===================================================================
---- automake-1.15.1.orig/lib/am/check.am
-+++ automake-1.15.1/lib/am/check.am
+---
+ lib/am/check.am | 11 +++++++++--
+ 1 file changed, 9 insertions(+), 2 deletions(-)
+
+diff --git a/lib/am/check.am b/lib/am/check.am
+index e0db651..de137fa 100644
+--- a/lib/am/check.am
++++ b/lib/am/check.am
 @@ -41,7 +41,7 @@ am__tty_colors = { \
    fi; \
  }
diff --git a/poky/meta/recipes-devtools/automake/automake/new_rt_path_for_test-driver.patch b/poky/meta/recipes-devtools/automake/automake/new_rt_path_for_test-driver.patch
index 2c6594f..1f71722 100644
--- a/poky/meta/recipes-devtools/automake/automake/new_rt_path_for_test-driver.patch
+++ b/poky/meta/recipes-devtools/automake/automake/new_rt_path_for_test-driver.patch
@@ -1,22 +1,32 @@
-Set relative to top_builddir path in Makefile to access test-driver
+From f78dfa39139d528c94d72f27994f337f2fd3b6bd Mon Sep 17 00:00:00 2001
+From: Adrian Calianu <adrian.calianu@enea.com>
+Date: Thu, 25 Feb 2016 16:08:04 +0100
+Subject: [PATCH] Set relative to top_builddir path in Makefile to access
+ test-driver
 
 Signed-off-by: Adrian Calianu <adrian.calianu@enea.com>
 Upstream-Status: Pending
 Bug-Report: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=19042
 
+---
+ bin/automake.in | 9 ++++++++-
+ 1 file changed, 8 insertions(+), 1 deletion(-)
+
+diff --git a/bin/automake.in b/bin/automake.in
+index a52a489..8377d20 100644
 --- a/bin/automake.in
 +++ b/bin/automake.in
-@@ -272,6 +272,9 @@
+@@ -324,6 +324,9 @@ my $config_aux_dir_set_in_configure_ac = 0;
  # $AM_CONFIG_AUX_DIR is prefixed with $(top_srcdir), so it can be used
  # in Makefiles.
  my $am_config_aux_dir = '';
 +# Directory used at runtime like running test-driver that should not
 +# depend on $(top_srcdir)
 +my $am_config_rt_aux_dir = '';
-
+ 
  # Directory to search for AC_LIBSOURCE files, as set by AC_CONFIG_LIBOBJ_DIR
  # in configure.ac.
-@@ -4700,7 +4703,7 @@
+@@ -4854,7 +4857,7 @@ sub handle_per_suffix_test
      {
        require_conf_file ("parallel-tests", FOREIGN, 'test-driver');
        define_variable ("${pfx}LOG_DRIVER",
@@ -25,7 +35,7 @@
                         INTERNAL);
      }
    my $driver = '$(' . $pfx . 'LOG_DRIVER)';
-@@ -7284,6 +7287,10 @@
+@@ -7440,6 +7443,10 @@ sub locate_aux_dir ()
    $am_config_aux_dir =
      '$(top_srcdir)' . ($config_aux_dir eq '.' ? "" : "/$config_aux_dir");
    $am_config_aux_dir =~ s,/*$,,;
@@ -34,3 +44,5 @@
 +    '$(top_builddir)' . ($config_aux_dir eq '.' ? "" : "/$config_aux_dir");
 +  $am_config_rt_aux_dir =~ s,/*$,,;
  }
+ 
+ 
diff --git a/poky/meta/recipes-devtools/automake/automake/performance.patch b/poky/meta/recipes-devtools/automake/automake/performance.patch
index 3e6d569..a8ba659 100644
--- a/poky/meta/recipes-devtools/automake/automake/performance.patch
+++ b/poky/meta/recipes-devtools/automake/automake/performance.patch
@@ -1,15 +1,24 @@
+From cd47c328cb53546891bb3dc7c9b2c54ed01cc6d1 Mon Sep 17 00:00:00 2001
+From: Richard Purdie <richard.purdie@linuxfoundation.org>
+Date: Mon, 7 Dec 2015 18:28:05 +0000
+Subject: [PATCH] automake: Remove delays in configure scripts using automake
+
 By default automake puts "sleep 1" into the start of configure scripts
-which adds pointless delays to them. Rather than do this, lets just assume 
+which adds pointless delays to them. Rather than do this, lets just assume
 our systems are sane.
 
 RP
 2015/12/7
 Upstream-Status: Inappropriate
 
-Index: automake-1.15/m4/sanity.m4
-===================================================================
---- automake-1.15.orig/m4/sanity.m4
-+++ automake-1.15/m4/sanity.m4
+---
+ m4/sanity.m4 | 55 -------------------------------------------------------
+ 1 file changed, 55 deletions(-)
+
+diff --git a/m4/sanity.m4 b/m4/sanity.m4
+index eaac218..bfdfe88 100644
+--- a/m4/sanity.m4
++++ b/m4/sanity.m4
 @@ -23,60 +23,5 @@ case $srcdir in
      AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);;
  esac
diff --git a/poky/meta/recipes-devtools/automake/automake/python-libdir.patch b/poky/meta/recipes-devtools/automake/automake/python-libdir.patch
index 2a48b13..ee1f725 100644
--- a/poky/meta/recipes-devtools/automake/automake/python-libdir.patch
+++ b/poky/meta/recipes-devtools/automake/automake/python-libdir.patch
@@ -1,7 +1,7 @@
-From 472a3d36c97ef7535f05d6c185edcbc22b0074c4 Mon Sep 17 00:00:00 2001
+From a80dacd5124d0713cf2c986b28d736e78dc6b0ca Mon Sep 17 00:00:00 2001
 From: Kumar Gala <galak@kernel.crashing.org>
 Date: Thu, 11 Aug 2011 01:26:33 -0500
-Subject: [PATCH 1/4] automake: Update for python.m4 to respect libdir
+Subject: [PATCH] automake: Update for python.m4 to respect libdir
 
 Upstream-Status: Inappropriate [embedded specific]
 
@@ -17,10 +17,10 @@
  1 file changed, 7 insertions(+), 20 deletions(-)
 
 diff --git a/m4/python.m4 b/m4/python.m4
-index 5b2c695..ed19261 100644
+index 63c0a0e..7bbd2d2 100644
 --- a/m4/python.m4
 +++ b/m4/python.m4
-@@ -91,12 +91,13 @@ AC_DEFUN([AM_PATH_PYTHON],
+@@ -94,12 +94,13 @@ AC_DEFUN([AM_PATH_PYTHON],
      [am_cv_python_version=`$PYTHON -c "import sys; sys.stdout.write(sys.version[[:3]])"`])
    AC_SUBST([PYTHON_VERSION], [$am_cv_python_version])
  
@@ -36,7 +36,7 @@
    AC_SUBST([PYTHON_EXEC_PREFIX], ['${exec_prefix}'])
  
    dnl At times (like when building shared libraries) you may want
-@@ -141,14 +142,7 @@ except ImportError:
+@@ -144,14 +145,7 @@ except ImportError:
       else
         am_py_prefix=$prefix
       fi
@@ -52,7 +52,7 @@
       case $am_cv_python_pythondir in
       $am_py_prefix*)
         am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'`
-@@ -158,7 +152,7 @@ sys.stdout.write(sitedir)"`
+@@ -161,7 +155,7 @@ sys.stdout.write(sitedir)"`
         case $am_py_prefix in
           /usr|/System*) ;;
           *)
@@ -61,7 +61,7 @@
  	  ;;
         esac
         ;;
-@@ -183,14 +177,7 @@ sys.stdout.write(sitedir)"`
+@@ -186,14 +180,7 @@ sys.stdout.write(sitedir)"`
       else
         am_py_exec_prefix=$exec_prefix
       fi
@@ -77,7 +77,7 @@
       case $am_cv_python_pyexecdir in
       $am_py_exec_prefix*)
         am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'`
-@@ -200,7 +187,7 @@ sys.stdout.write(sitedir)"`
+@@ -203,7 +190,7 @@ sys.stdout.write(sitedir)"`
         case $am_py_exec_prefix in
           /usr|/System*) ;;
           *)
@@ -86,6 +86,3 @@
  	   ;;
         esac
         ;;
--- 
-2.8.1
-
diff --git a/poky/meta/recipes-devtools/automake/automake_1.15.1.bb b/poky/meta/recipes-devtools/automake/automake_1.15.1.bb
deleted file mode 100644
index 4f9b616..0000000
--- a/poky/meta/recipes-devtools/automake/automake_1.15.1.bb
+++ /dev/null
@@ -1,43 +0,0 @@
-require automake.inc
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
-DEPENDS_class-native = "autoconf-native"
-
-NAMEVER = "${@oe.utils.trim_version("${PV}", 2)}"
-
-RDEPENDS_${PN} += "\
-    autoconf \
-    perl \
-    perl-module-bytes \
-    perl-module-data-dumper \
-    perl-module-strict \
-    perl-module-text-parsewords \
-    perl-module-thread-queue \
-    perl-module-threads \
-    perl-module-vars "
-
-RDEPENDS_${PN}_class-native = "autoconf-native hostperl-runtime-native"
-RDEPENDS_${PN}_class-nativesdk = "nativesdk-autoconf"
-
-SRC_URI += "file://python-libdir.patch \
-            file://buildtest.patch \
-            file://performance.patch \
-            file://new_rt_path_for_test-driver.patch \
-            file://automake-replace-w-option-in-shebangs-with-modern-use-warnings.patch \
-            file://0001-automake-Add-default-libtool_tag-to-cppasm.patch \
-            "
-
-SRC_URI[md5sum] = "95df3f2d6eb8f81e70b8cb63a93c8853"
-SRC_URI[sha256sum] = "988e32527abe052307d21c8ca000aa238b914df363a617e38f4fb89f5abf6260"
-
-PERL = "${USRBINPATH}/perl"
-PERL_class-native = "${USRBINPATH}/env perl"
-PERL_class-nativesdk = "${USRBINPATH}/env perl"
-
-CACHED_CONFIGUREVARS += "ac_cv_path_PERL='${PERL}'"
-
-do_install_append () {
-    install -d ${D}${datadir}
-}
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-devtools/automake/automake_1.16.1.bb b/poky/meta/recipes-devtools/automake/automake_1.16.1.bb
new file mode 100644
index 0000000..d82eed3
--- /dev/null
+++ b/poky/meta/recipes-devtools/automake/automake_1.16.1.bb
@@ -0,0 +1,44 @@
+require automake.inc
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
+DEPENDS_class-native = "autoconf-native"
+
+NAMEVER = "${@oe.utils.trim_version("${PV}", 2)}"
+
+RDEPENDS_${PN} += "\
+    autoconf \
+    perl \
+    perl-module-bytes \
+    perl-module-data-dumper \
+    perl-module-strict \
+    perl-module-text-parsewords \
+    perl-module-thread-queue \
+    perl-module-threads \
+    perl-module-vars "
+
+RDEPENDS_${PN}_class-native = "autoconf-native hostperl-runtime-native"
+RDEPENDS_${PN}_class-nativesdk = "nativesdk-autoconf"
+
+SRC_URI += "file://python-libdir.patch \
+            file://buildtest.patch \
+            file://performance.patch \
+            file://new_rt_path_for_test-driver.patch \
+            file://automake-replace-w-option-in-shebangs-with-modern-use-warnings.patch \
+            file://0001-automake-Add-default-libtool_tag-to-cppasm.patch \
+            file://0001-build-fix-race-in-parallel-builds.patch \
+            "
+
+SRC_URI[md5sum] = "83cc2463a4080efd46a72ba2c9f6b8f5"
+SRC_URI[sha256sum] = "608a97523f97db32f1f5d5615c98ca69326ced2054c9f82e65bade7fc4c9dea8"
+
+PERL = "${USRBINPATH}/perl"
+PERL_class-native = "${USRBINPATH}/env perl"
+PERL_class-nativesdk = "${USRBINPATH}/env perl"
+
+CACHED_CONFIGUREVARS += "ac_cv_path_PERL='${PERL}'"
+
+do_install_append () {
+    install -d ${D}${datadir}
+}
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-devtools/binutils/binutils-2.30.inc b/poky/meta/recipes-devtools/binutils/binutils-2.30.inc
deleted file mode 100644
index 35d7d9b..0000000
--- a/poky/meta/recipes-devtools/binutils/binutils-2.30.inc
+++ /dev/null
@@ -1,56 +0,0 @@
-LIC_FILES_CHKSUM="\
-    file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552\
-    file://COPYING.LIB;md5=9f604d8a4f8e74f4f5140845a21b6674\
-    file://COPYING3;md5=d32239bcb673463ab874e80d47fae504\
-    file://COPYING3.LIB;md5=6a6a8e020838b23406c81b19c1d46df6\
-    file://gas/COPYING;md5=d32239bcb673463ab874e80d47fae504\
-    file://include/COPYING;md5=59530bdf33659b29e73d4adb9f9f6552\
-    file://include/COPYING3;md5=d32239bcb673463ab874e80d47fae504\
-    file://libiberty/COPYING.LIB;md5=a916467b91076e631dd8edb7424769c7\
-    file://bfd/COPYING;md5=d32239bcb673463ab874e80d47fae504\
-    "
-
-def binutils_branch_version(d):
-    pvsplit = d.getVar('PV').split('.')
-    return pvsplit[0] + "_" + pvsplit[1]
-
-BINUPV = "${@binutils_branch_version(d)}"
-
-UPSTREAM_CHECK_GITTAGREGEX = "binutils-(?P<pver>\d+_(\d_?)*)"
-
-SRCREV ?= "caa839fba66600a6c36d3639906ed9110b79c307"
-BINUTILS_GIT_URI ?= "git://sourceware.org/git/binutils-gdb.git;branch=binutils-${BINUPV}-branch;protocol=git"
-SRC_URI = "\
-     ${BINUTILS_GIT_URI} \
-     file://0003-configure-widen-the-regexp-for-SH-architectures.patch \
-     file://0004-Point-scripts-location-to-libdir.patch \
-     file://0005-Only-generate-an-RPATH-entry-if-LD_RUN_PATH-is-not-e.patch \
-     file://0006-Use-libtool-2.4.patch \
-     file://0007-Add-the-armv5e-architecture-to-binutils.patch \
-     file://0008-don-t-let-the-distro-compiler-point-to-the-wrong-ins.patch \
-     file://0009-warn-for-uses-of-system-directories-when-cross-linki.patch \
-     file://0010-Fix-rpath-in-libtool-when-sysroot-is-enabled.patch \
-     file://0011-Change-default-emulation-for-mips64-linux.patch \
-     file://0012-Add-support-for-Netlogic-XLP.patch \
-     file://0013-fix-the-incorrect-assembling-for-ppc-wait-mnemonic.patch \
-     file://0014-Detect-64-bit-MIPS-targets.patch \
-     file://0015-sync-with-OE-libtool-changes.patch \
-     file://CVE-2018-8945.patch \
-     file://CVE-2018-7643.patch \
-     file://CVE-2018-6872.patch \ 
-     file://CVE-2018-6759.patch \
-     file://CVE-2018-7642.patch \
-     file://CVE-2018-7208.patch \
-     file://CVE-2018-7569.patch \
-     file://CVE-2018-7568.patch \
-     file://CVE-2018-10373.patch \
-     file://CVE-2018-10372.patch \
-     file://CVE-2018-10535.patch \
-     file://CVE-2018-10534.patch \
-     file://0001-Change-the-ARM-assembler-s-ADR-and-ADRl-pseudo-ops-s.patch \
-"
-S  = "${WORKDIR}/git"
-
-do_configure_prepend () {
-        rm -rf ${S}/gdb ${S}/libdecnumber ${S}/readline ${S}/sim
-}
diff --git a/poky/meta/recipes-devtools/binutils/binutils-2.31.inc b/poky/meta/recipes-devtools/binutils/binutils-2.31.inc
new file mode 100644
index 0000000..0c9d4ce
--- /dev/null
+++ b/poky/meta/recipes-devtools/binutils/binutils-2.31.inc
@@ -0,0 +1,55 @@
+LIC_FILES_CHKSUM="\
+    file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552\
+    file://COPYING.LIB;md5=9f604d8a4f8e74f4f5140845a21b6674\
+    file://COPYING3;md5=d32239bcb673463ab874e80d47fae504\
+    file://COPYING3.LIB;md5=6a6a8e020838b23406c81b19c1d46df6\
+    file://gas/COPYING;md5=d32239bcb673463ab874e80d47fae504\
+    file://include/COPYING;md5=59530bdf33659b29e73d4adb9f9f6552\
+    file://include/COPYING3;md5=d32239bcb673463ab874e80d47fae504\
+    file://libiberty/COPYING.LIB;md5=a916467b91076e631dd8edb7424769c7\
+    file://bfd/COPYING;md5=d32239bcb673463ab874e80d47fae504\
+    "
+
+def binutils_branch_version(d):
+    pvsplit = d.getVar('PV').split('.')
+    return pvsplit[0] + "_" + pvsplit[1]
+
+BINUPV = "${@binutils_branch_version(d)}"
+
+UPSTREAM_CHECK_GITTAGREGEX = "binutils-(?P<pver>\d+_(\d_?)*)"
+
+SRCREV ?= "4568e49ff799192fea4f66063fe13e2b871ec75a"
+BINUTILS_GIT_URI ?= "git://sourceware.org/git/binutils-gdb.git;branch=binutils-${BINUPV}-branch;protocol=git"
+SRC_URI = "\
+     ${BINUTILS_GIT_URI} \
+     file://0003-configure-widen-the-regexp-for-SH-architectures.patch \
+     file://0004-Point-scripts-location-to-libdir.patch \
+     file://0005-Only-generate-an-RPATH-entry-if-LD_RUN_PATH-is-not-e.patch \
+     file://0006-Use-libtool-2.4.patch \
+     file://0007-Add-the-armv5e-architecture-to-binutils.patch \
+     file://0008-don-t-let-the-distro-compiler-point-to-the-wrong-ins.patch \
+     file://0009-warn-for-uses-of-system-directories-when-cross-linki.patch \
+     file://0010-Fix-rpath-in-libtool-when-sysroot-is-enabled.patch \
+     file://0011-Change-default-emulation-for-mips64-linux.patch \
+     file://0012-Add-support-for-Netlogic-XLP.patch \
+     file://0013-fix-the-incorrect-assembling-for-ppc-wait-mnemonic.patch \
+     file://0014-Detect-64-bit-MIPS-targets.patch \
+     file://0015-sync-with-OE-libtool-changes.patch \
+     file://0016-add-i386pep-emulation-for-x86_64.patch \
+     file://0017-improve-check-for-input-file-matching-output-file.patch \
+     file://0018-Refactored-location-where-GOT-information-is-collect.patch \
+     file://0019-Improved-robustness.-Return-FALSE-in-case-of-NULL-po.patch \
+     file://0020-Make-sure-global-symbol-is-not-an-indirect-or-warnin.patch \
+     file://0021-PLT-information-was-still-being-generated-when-symbo.patch \
+     file://CVE-2018-17358.patch \
+     file://CVE-2018-17360.patch \
+     file://CVE-2018-18309.patch \
+     file://CVE-2018-18605.patch \
+     file://CVE-2018-18606.patch \
+     file://CVE-2018-18607.patch \
+"
+S  = "${WORKDIR}/git"
+
+do_configure_prepend () {
+        rm -rf ${S}/gdb ${S}/libdecnumber ${S}/readline ${S}/sim
+}
diff --git a/poky/meta/recipes-devtools/binutils/binutils-cross-canadian_2.30.bb b/poky/meta/recipes-devtools/binutils/binutils-cross-canadian_2.31.bb
similarity index 100%
rename from poky/meta/recipes-devtools/binutils/binutils-cross-canadian_2.30.bb
rename to poky/meta/recipes-devtools/binutils/binutils-cross-canadian_2.31.bb
diff --git a/poky/meta/recipes-devtools/binutils/binutils-cross_2.30.bb b/poky/meta/recipes-devtools/binutils/binutils-cross_2.31.bb
similarity index 100%
rename from poky/meta/recipes-devtools/binutils/binutils-cross_2.30.bb
rename to poky/meta/recipes-devtools/binutils/binutils-cross_2.31.bb
diff --git a/poky/meta/recipes-devtools/binutils/binutils-crosssdk_2.30.bb b/poky/meta/recipes-devtools/binutils/binutils-crosssdk_2.31.bb
similarity index 100%
rename from poky/meta/recipes-devtools/binutils/binutils-crosssdk_2.30.bb
rename to poky/meta/recipes-devtools/binutils/binutils-crosssdk_2.31.bb
diff --git a/poky/meta/recipes-devtools/binutils/binutils.inc b/poky/meta/recipes-devtools/binutils/binutils.inc
index 37813dd..0fb6cae 100644
--- a/poky/meta/recipes-devtools/binutils/binutils.inc
+++ b/poky/meta/recipes-devtools/binutils/binutils.inc
@@ -38,6 +38,9 @@
 # Rather than duplicating multiple entries for these, make one
 # list and reuse it.
 
+LDGOLD_ALTS ?= "ld.gold dwp"
+LDGOLD_ALTS_riscv64 = ""
+
 USE_ALTERNATIVES_FOR = " \
 	addr2line \
 	ar \
@@ -47,7 +50,7 @@
 	gprof \
 	ld \
 	ld.bfd \
-	ld.gold dwp \
+	${LDGOLD_ALTS} \
 	nm \
 	objcopy \
 	objdump \
@@ -128,12 +131,12 @@
 	# We don't really need these, so we'll remove them...
 	rm -rf ${D}${libdir}/ldscripts
 
+	bindir_rel=${@os.path.relpath('${bindir}', '${prefix}/${TARGET_SYS}/bin')}
+
 	# Fix the /usr/${TARGET_SYS}/bin/* links
 	for l in ${D}${prefix}/${TARGET_SYS}/bin/*; do
 		rm -f $l
-		ln -sf `echo ${prefix}/${TARGET_SYS}/bin \
-			| tr -s / \
-			| sed -e 's,^/,,' -e 's,[^/]*,..,g'`${bindir}/${TARGET_PREFIX}`basename $l` $l
+		ln -sf $bindir_rel/${TARGET_PREFIX}`basename $l` $l
 	done
 
 	# Install the libiberty header
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0001-Change-the-ARM-assembler-s-ADR-and-ADRl-pseudo-ops-s.patch b/poky/meta/recipes-devtools/binutils/binutils/0001-Change-the-ARM-assembler-s-ADR-and-ADRl-pseudo-ops-s.patch
deleted file mode 100644
index 8604e67..0000000
--- a/poky/meta/recipes-devtools/binutils/binutils/0001-Change-the-ARM-assembler-s-ADR-and-ADRl-pseudo-ops-s.patch
+++ /dev/null
@@ -1,176 +0,0 @@
-From fc6141f097056f830a412afebed8d81a9d72b696 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Wed, 20 Jun 2018 12:38:10 +0100
-Subject: [PATCH] Change the ARM assembler's ADR and ADRl pseudo-ops so that
- they will only set the bottom bit of imported thumb function symbols if the
- -mthumb-interwork option is active.
-
-For more information see the email thread starting here:
-https://www.sourceware.org/ml/binutils/2018-05/msg00348.html
-
-	PR 21458
-	* tc-arm.c (do_adr): Only set the bottom bit of an imported thumb
-	function symbol address if -mthumb-interwork is active.
-	(do_adrl): Likewise.
-	* doc/c-arm.texi: Update descriptions of the -mthumb-interwork
-	option and the ADR and ADRL pseudo-ops.
-	* NEWS: Mention the new behaviour of the ADR and ADRL pseudo-ops.
-	* testsuite/gas/arm/pr21458.d: Add -mthumb-interwork option to
-	assembler command line.
-	* testsuite/gas/arm/adr.d: Likewise.
-	* testsuite/gas/arm/adrl.d: Likewise.
----
- gas/ChangeLog                   | 14 ++++++++++++++
- gas/NEWS                        |  4 ++++
- gas/config/tc-arm.c             | 10 ++++++----
- gas/doc/c-arm.texi              | 17 ++++++++++++++++-
- gas/testsuite/gas/arm/adr.d     |  1 +
- gas/testsuite/gas/arm/adrl.d    |  1 +
- gas/testsuite/gas/arm/pr21458.d |  3 ++-
- 7 files changed, 44 insertions(+), 6 deletions(-)
-
-Index: git/gas/config/tc-arm.c
-===================================================================
---- git.orig/gas/config/tc-arm.c
-+++ git/gas/config/tc-arm.c
-@@ -8410,11 +8410,12 @@ do_adr (void)
-   inst.reloc.pc_rel = 1;
-   inst.reloc.exp.X_add_number -= 8;
- 
--  if (inst.reloc.exp.X_op == O_symbol
-+  if (support_interwork
-+      && inst.reloc.exp.X_op == O_symbol
-       && inst.reloc.exp.X_add_symbol != NULL
-       && S_IS_DEFINED (inst.reloc.exp.X_add_symbol)
-       && THUMB_IS_FUNC (inst.reloc.exp.X_add_symbol))
--    inst.reloc.exp.X_add_number += 1;
-+    inst.reloc.exp.X_add_number |= 1;
- }
- 
- /* This is a pseudo-op of the form "adrl rd, label" to be converted
-@@ -8434,11 +8435,12 @@ do_adrl (void)
-   inst.size		       = INSN_SIZE * 2;
-   inst.reloc.exp.X_add_number -= 8;
- 
--  if (inst.reloc.exp.X_op == O_symbol
-+  if (support_interwork
-+      && inst.reloc.exp.X_op == O_symbol
-       && inst.reloc.exp.X_add_symbol != NULL
-       && S_IS_DEFINED (inst.reloc.exp.X_add_symbol)
-       && THUMB_IS_FUNC (inst.reloc.exp.X_add_symbol))
--    inst.reloc.exp.X_add_number += 1;
-+    inst.reloc.exp.X_add_number |= 1;
- }
- 
- static void
-Index: git/gas/doc/c-arm.texi
-===================================================================
---- git.orig/gas/doc/c-arm.texi
-+++ git/gas/doc/c-arm.texi
-@@ -317,7 +317,8 @@ instructions; that is, it should behave
- @cindex @code{-mthumb-interwork} command line option, ARM
- @item -mthumb-interwork
- This option specifies that the output generated by the assembler should
--be marked as supporting interworking.
-+be marked as supporting interworking.  It also affects the behaviour
-+of the @code{ADR} and @code{ADRL} pseudo opcodes.
- 
- @cindex @code{-mimplicit-it} command line option, ARM
- @item -mimplicit-it=never
-@@ -1060,6 +1061,16 @@ out of range, or if it is not defined in
- the ADR instruction, then an error will be generated.  This instruction
- will not make use of the literal pool.
- 
-+If @var{label} is a thumb function symbol, and thumb interworking has
-+been enabled via the @option{-mthumb-interwork} option then the bottom
-+bit of the value stored into @var{register} will be set.  This allows
-+the following sequence to work as expected:
-+
-+@smallexample
-+  adr     r0, thumb_function
-+  blx     r0
-+@end smallexample
-+
- @cindex @code{ADRL reg,<label>} pseudo op, ARM
- @item ADRL
- @smallexample
-@@ -1076,6 +1087,10 @@ If the label is out of range, or if it i
- (and section) as the ADRL instruction, then an error will be generated.
- This instruction will not make use of the literal pool.
- 
-+If @var{label} is a thumb function symbol, and thumb interworking has
-+been enabled via the @option{-mthumb-interwork} option then the bottom
-+bit of the value stored into @var{register} will be set.
-+
- @end table
- 
- For information on the ARM or Thumb instruction sets, see @cite{ARM
-Index: git/gas/testsuite/gas/arm/adr.d
-===================================================================
---- git.orig/gas/testsuite/gas/arm/adr.d
-+++ git/gas/testsuite/gas/arm/adr.d
-@@ -1,3 +1,4 @@
-+#as: -mthumb-interwork
- #objdump: -dr --prefix-addresses --show-raw-insn
- #name: ADR
- 
-Index: git/gas/testsuite/gas/arm/adrl.d
-===================================================================
---- git.orig/gas/testsuite/gas/arm/adrl.d
-+++ git/gas/testsuite/gas/arm/adrl.d
-@@ -1,3 +1,4 @@
-+#as: -mthumb-interwork
- #objdump: -dr --prefix-addresses --show-raw-insn
- #name: ADRL
- 
-Index: git/gas/ChangeLog
-===================================================================
---- git.orig/gas/ChangeLog
-+++ git/gas/ChangeLog
-@@ -1,3 +1,17 @@
-+2018-06-20  Nick Clifton  <nickc@redhat.com>
-+
-+       PR 21458
-+       * tc-arm.c (do_adr): Only set the bottom bit of an imported thumb
-+       function symbol address if -mthumb-interwork is active.
-+       (do_adrl): Likewise.
-+       * doc/c-arm.texi: Update descriptions of the -mthumb-interwork
-+       option and the ADR and ADRL pseudo-ops.
-+       * NEWS: Mention the new behaviour of the ADR and ADRL pseudo-ops.
-+       * testsuite/gas/arm/pr21458.d: Add -mthumb-interwork option to
-+       assembler command line.
-+       * testsuite/gas/arm/adr.d: Likewise.
-+       * testsuite/gas/arm/adrl.d: Likewise.
-+
- 2018-02-05  Nick Clifton  <nickc@redhat.com>
- 
- 	* po/ru.po: Updated Russian translation.
-Index: git/gas/NEWS
-===================================================================
---- git.orig/gas/NEWS
-+++ git/gas/NEWS
-@@ -1,5 +1,9 @@
- -*- text -*-
- 
-+* The ADR and ADRL pseudo-instructions supported by the ARM assembler
-+  now only set the bottom bit of the address of thumb function symbols
-+  if the -mthumb-interwork command line option is active.
-+
- Changes in 2.30:
- 
- * Add support for loaction views in DWARF debug line information.
-Index: git/gas/testsuite/gas/arm/pr21458.d
-===================================================================
---- git.orig/gas/testsuite/gas/arm/pr21458.d
-+++ git/gas/testsuite/gas/arm/pr21458.d
-@@ -1,8 +1,9 @@
-+#as: -mthumb-interwork
- #objdump: -d --prefix-addresses --show-raw-insn
- #name: ADR(L) for Thumb functions
- #skip: *-*-pe *-wince-* *-*-coff *-*-vxworks
- 
--# Test that using ADR(L) on thumb function symbols sets the T bit.
-+# Test that using ADR(L) on thumb function symbols sets the T bit when -mthumb-interwork is active.
- 
- .*: +file format .*arm.*
- 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0001-binutils-crosssdk-Generate-relocatable-SDKs.patch b/poky/meta/recipes-devtools/binutils/binutils/0001-binutils-crosssdk-Generate-relocatable-SDKs.patch
index 2df8360..6bdb407 100644
--- a/poky/meta/recipes-devtools/binutils/binutils/0001-binutils-crosssdk-Generate-relocatable-SDKs.patch
+++ b/poky/meta/recipes-devtools/binutils/binutils/0001-binutils-crosssdk-Generate-relocatable-SDKs.patch
@@ -1,4 +1,4 @@
-From 2e1b5e24a6759de7f73aa6060a574848d9131b5a Mon Sep 17 00:00:00 2001
+From 4a99f058030c86794bb96b582a7dbd631f963b06 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:58:54 +0000
 Subject: [PATCH 01/15] binutils-crosssdk: Generate relocatable SDKs
@@ -18,10 +18,10 @@
  2 files changed, 5 insertions(+), 2 deletions(-)
 
 diff --git a/ld/genscripts.sh b/ld/genscripts.sh
-index 8732422b3a..1f257e99ca 100755
+index 370b22269d..a5c367aa8f 100755
 --- a/ld/genscripts.sh
 +++ b/ld/genscripts.sh
-@@ -277,6 +277,7 @@ DATA_ALIGNMENT_u="${DATA_ALIGNMENT_u-${DATA_ALIGNMENT_r}}"
+@@ -279,6 +279,7 @@ DATA_ALIGNMENT_u="${DATA_ALIGNMENT_u-${DATA_ALIGNMENT_r}}"
  LD_FLAG=r
  DATA_ALIGNMENT=${DATA_ALIGNMENT_r}
  DEFAULT_DATA_ALIGNMENT="ALIGN(${SEGMENT_SIZE})"
@@ -29,7 +29,7 @@
  ( echo "/* Script for ld -r: link without relocation */"
    . ${CUSTOMIZER_SCRIPT}
    . ${srcdir}/scripttempl/${SCRIPT_NAME}.sc
-@@ -285,10 +286,12 @@ DEFAULT_DATA_ALIGNMENT="ALIGN(${SEGMENT_SIZE})"
+@@ -287,10 +288,12 @@ DEFAULT_DATA_ALIGNMENT="ALIGN(${SEGMENT_SIZE})"
  LD_FLAG=u
  DATA_ALIGNMENT=${DATA_ALIGNMENT_u}
  CONSTRUCTING=" "
@@ -43,7 +43,7 @@
  DATA_ALIGNMENT=${DATA_ALIGNMENT_}
  RELOCATING=" "
 diff --git a/ld/scripttempl/elf.sc b/ld/scripttempl/elf.sc
-index 9787ab5dac..0c8a93c2c8 100644
+index 444aef2942..afa99f736d 100644
 --- a/ld/scripttempl/elf.sc
 +++ b/ld/scripttempl/elf.sc
 @@ -139,8 +139,8 @@ if test -z "$DATA_SEGMENT_ALIGN"; then
@@ -58,5 +58,5 @@
  if test -z "$PLT"; then
    IPLT=".iplt         ${RELOCATING-0} : { *(.iplt) }"
 -- 
-2.16.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0002-binutils-cross-Do-not-generate-linker-script-directo.patch b/poky/meta/recipes-devtools/binutils/binutils/0002-binutils-cross-Do-not-generate-linker-script-directo.patch
index bac7fb2..0208213 100644
--- a/poky/meta/recipes-devtools/binutils/binutils/0002-binutils-cross-Do-not-generate-linker-script-directo.patch
+++ b/poky/meta/recipes-devtools/binutils/binutils/0002-binutils-cross-Do-not-generate-linker-script-directo.patch
@@ -1,4 +1,4 @@
-From 58ddf38fa53abb48b69dd76e398c73451ad1a5eb Mon Sep 17 00:00:00 2001
+From 6e78b1c88c040a742b7af82542ac7eb92eddda3d Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 6 Mar 2017 23:37:05 -0800
 Subject: [PATCH 02/15] binutils-cross: Do not generate linker script
@@ -19,14 +19,14 @@
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 ---
- ld/genscripts.sh | 23 -----------------------
- 1 file changed, 23 deletions(-)
+ ld/genscripts.sh | 25 -------------------------
+ 1 file changed, 25 deletions(-)
 
 diff --git a/ld/genscripts.sh b/ld/genscripts.sh
-index 1f257e99ca..1583b73a2b 100755
+index a5c367aa8f..6cc9eed976 100755
 --- a/ld/genscripts.sh
 +++ b/ld/genscripts.sh
-@@ -189,29 +189,6 @@ append_to_lib_path()
+@@ -189,31 +189,6 @@ append_to_lib_path()
    fi
  }
  
@@ -44,10 +44,12 @@
 -    # because 64bit libraries may be in both places, depending on
 -    # cross-development setup method (e.g.: /usr/s390x-linux/lib64
 -    # vs. /usr/s390-linux/lib64)
--    case "${NATIVE}:${LIBPATH_SUFFIX}:${TOOL_LIB}" in
--      :* | *::* | *:*:*${LIBPATH_SUFFIX}) ;;
--      *) libs="${exec_prefix}/${target_alias}/lib${LIBPATH_SUFFIX}" ;;
--    esac
+-    for libpath_suffix in ${LIBPATH_SUFFIX}; do
+-      case "${NATIVE}:${libpath_suffix}:${TOOL_LIB}" in
+-	:* | *::* | *:*:*${libpath_suffix}) ;;
+-	*) libs="${exec_prefix}/${target_alias}/lib${libpath_suffix}" ;;
+-      esac
+-    done
 -    libs="${exec_prefix}/${TOOL_LIB}/lib ${libs}"
 -  fi
 -  append_to_lib_path ${libs}
@@ -57,5 +59,5 @@
    libs=${NATIVE_LIB_DIRS}
    if [ "x${NATIVE}" = "xyes" ] ; then
 -- 
-2.16.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0003-configure-widen-the-regexp-for-SH-architectures.patch b/poky/meta/recipes-devtools/binutils/binutils/0003-configure-widen-the-regexp-for-SH-architectures.patch
index 306afe7..15193c1 100644
--- a/poky/meta/recipes-devtools/binutils/binutils/0003-configure-widen-the-regexp-for-SH-architectures.patch
+++ b/poky/meta/recipes-devtools/binutils/binutils/0003-configure-widen-the-regexp-for-SH-architectures.patch
@@ -1,4 +1,4 @@
-From 5089be88f670bcadf7db0e778894f900b2c05d7b Mon Sep 17 00:00:00 2001
+From 4c6fd8f5eb9bc7c0d02f1a98ad86e395d4d2ab3b Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:07:33 +0000
 Subject: [PATCH 03/15] configure: widen the regexp for SH architectures
@@ -14,10 +14,10 @@
  2 files changed, 6 insertions(+), 1 deletion(-)
 
 diff --git a/configure b/configure
-index 2d615a9996..c4ad45c06c 100755
+index 08dd35c3ea..815e74ddb7 100755
 --- a/configure
 +++ b/configure
-@@ -3835,7 +3835,7 @@ case "${target}" in
+@@ -3855,7 +3855,7 @@ case "${target}" in
    nvptx*-*-*)
      noconfigdirs="$noconfigdirs target-libssp target-libstdc++-v3 target-libobjc"
      ;;
@@ -27,10 +27,10 @@
        sh*-*-elf)
           ;;
 diff --git a/gprof/configure b/gprof/configure
-index 1e25102976..6b43bf2b18 100755
+index 447cea7884..a730e20509 100755
 --- a/gprof/configure
 +++ b/gprof/configure
-@@ -5874,6 +5874,11 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu)
+@@ -6162,6 +6162,11 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu)
    lt_cv_deplibs_check_method=pass_all
    ;;
  
@@ -43,5 +43,5 @@
    if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
      lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
 -- 
-2.16.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0004-Point-scripts-location-to-libdir.patch b/poky/meta/recipes-devtools/binutils/binutils/0004-Point-scripts-location-to-libdir.patch
index 3e29c58..bf1c1be 100644
--- a/poky/meta/recipes-devtools/binutils/binutils/0004-Point-scripts-location-to-libdir.patch
+++ b/poky/meta/recipes-devtools/binutils/binutils/0004-Point-scripts-location-to-libdir.patch
@@ -1,4 +1,4 @@
-From a0e893ea094c48fa803046ffa89e31907aee0597 Mon Sep 17 00:00:00 2001
+From 48ad5292b10408d4e5d5739022753a7183a1cbb3 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:09:58 +0000
 Subject: [PATCH 04/15] Point scripts location to libdir
@@ -12,7 +12,7 @@
  2 files changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/ld/Makefile.am b/ld/Makefile.am
-index 6243c12528..3c5d6c8202 100644
+index d86ad0940c..c95b0ef025 100644
 --- a/ld/Makefile.am
 +++ b/ld/Makefile.am
 @@ -57,7 +57,7 @@ endif
@@ -25,10 +25,10 @@
  EMUL = @EMUL@
  EMULATION_OFILES = @EMULATION_OFILES@
 diff --git a/ld/Makefile.in b/ld/Makefile.in
-index 760c037f9d..6dea692869 100644
+index 4792b2b013..789df2d01b 100644
 --- a/ld/Makefile.in
 +++ b/ld/Makefile.in
-@@ -446,7 +446,7 @@ AM_CFLAGS = $(WARN_CFLAGS) $(ELF_CLFAGS)
+@@ -563,7 +563,7 @@ AM_CFLAGS = $(WARN_CFLAGS) $(ELF_CLFAGS)
  # We put the scripts in the directory $(scriptdir)/ldscripts.
  # We can't put the scripts in $(datadir) because the SEARCH_DIR
  # directives need to be different for native and cross linkers.
@@ -38,5 +38,5 @@
  BFDDIR = $(BASEDIR)/bfd
  INCDIR = $(BASEDIR)/include
 -- 
-2.16.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0005-Only-generate-an-RPATH-entry-if-LD_RUN_PATH-is-not-e.patch b/poky/meta/recipes-devtools/binutils/binutils/0005-Only-generate-an-RPATH-entry-if-LD_RUN_PATH-is-not-e.patch
index 2f49969..1f58971 100644
--- a/poky/meta/recipes-devtools/binutils/binutils/0005-Only-generate-an-RPATH-entry-if-LD_RUN_PATH-is-not-e.patch
+++ b/poky/meta/recipes-devtools/binutils/binutils/0005-Only-generate-an-RPATH-entry-if-LD_RUN_PATH-is-not-e.patch
@@ -1,4 +1,4 @@
-From 518abb195d0eb47d8eef581d7fd0a5fd9fa73f7d Mon Sep 17 00:00:00 2001
+From 79e53510b1f9e16a21db312698fb1c1c442481e7 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:27:17 +0000
 Subject: [PATCH 05/15] Only generate an RPATH entry if LD_RUN_PATH is not
@@ -15,10 +15,10 @@
  1 file changed, 4 insertions(+)
 
 diff --git a/ld/emultempl/elf32.em b/ld/emultempl/elf32.em
-index c0925fc9b9..7d7670a89f 100644
+index 1ad9d6b6fa..6a025a45b4 100644
 --- a/ld/emultempl/elf32.em
 +++ b/ld/emultempl/elf32.em
-@@ -1470,6 +1470,8 @@ fragment <<EOF
+@@ -1471,6 +1471,8 @@ fragment <<EOF
  	      && command_line.rpath == NULL)
  	    {
  	      path = (const char *) getenv ("LD_RUN_PATH");
@@ -27,7 +27,7 @@
  	      if (path
  		  && gld${EMULATION_NAME}_search_needed (path, &n, force))
  		break;
-@@ -1750,6 +1752,8 @@ gld${EMULATION_NAME}_before_allocation (void)
+@@ -1751,6 +1753,8 @@ gld${EMULATION_NAME}_before_allocation (void)
    rpath = command_line.rpath;
    if (rpath == NULL)
      rpath = (const char *) getenv ("LD_RUN_PATH");
@@ -37,5 +37,5 @@
    for (abfd = link_info.input_bfds; abfd; abfd = abfd->link.next)
      if (bfd_get_flavour (abfd) == bfd_target_elf_flavour)
 -- 
-2.16.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0006-Use-libtool-2.4.patch b/poky/meta/recipes-devtools/binutils/binutils/0006-Use-libtool-2.4.patch
index 333e2ee..8550df0 100644
--- a/poky/meta/recipes-devtools/binutils/binutils/0006-Use-libtool-2.4.patch
+++ b/poky/meta/recipes-devtools/binutils/binutils/0006-Use-libtool-2.4.patch
@@ -1,4 +1,4 @@
-From fad053cc59baa6277182b0fc90415a214060ba99 Mon Sep 17 00:00:00 2001
+From 11f6d2889725ad592ab789534ca9b858073df4d1 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sun, 14 Feb 2016 17:04:07 +0000
 Subject: [PATCH 06/15] Use libtool 2.4
@@ -9,27 +9,27 @@
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 ---
- bfd/configure        | 1318 +++++++++++++++++------
+ bfd/configure        | 1322 ++++++++++++++-----
  bfd/configure.ac     |    2 +-
- binutils/configure   | 1316 +++++++++++++++++------
- gas/configure        | 1314 +++++++++++++++++------
- gprof/configure      | 1321 +++++++++++++++++------
- ld/configure         | 1691 +++++++++++++++++++++--------
- libtool.m4           | 1080 +++++++++++++------
- ltmain.sh            | 2925 +++++++++++++++++++++++++++++++++-----------------
+ binutils/configure   | 1320 ++++++++++++++-----
+ gas/configure        | 1320 ++++++++++++++-----
+ gprof/configure      | 1327 ++++++++++++++-----
+ ld/configure         | 1695 ++++++++++++++++++------
+ libtool.m4           | 1080 +++++++++++-----
+ ltmain.sh            | 2925 ++++++++++++++++++++++++++++--------------
  ltoptions.m4         |    2 +-
  ltversion.m4         |   12 +-
  lt~obsolete.m4       |    2 +-
- opcodes/configure    | 1318 +++++++++++++++++------
+ opcodes/configure    | 1322 ++++++++++++++-----
  opcodes/configure.ac |    2 +-
- zlib/configure       | 1316 +++++++++++++++++------
- 14 files changed, 9926 insertions(+), 3693 deletions(-)
+ zlib/configure       | 1320 ++++++++++++++-----
+ 14 files changed, 9948 insertions(+), 3703 deletions(-)
 
-diff --git a/bfd/configure b/bfd/configure
-index 6c2b24ebe3..5fdd723b7f 100755
---- a/bfd/configure
-+++ b/bfd/configure
-@@ -672,6 +672,9 @@ OTOOL
+Index: git/bfd/configure
+===================================================================
+--- git.orig/bfd/configure
++++ git/bfd/configure
+@@ -704,6 +704,9 @@ OTOOL
  LIPO
  NMEDIT
  DSYMUTIL
@@ -39,7 +39,7 @@
  OBJDUMP
  LN_S
  NM
-@@ -785,6 +788,7 @@ enable_static
+@@ -822,6 +825,7 @@ enable_static
  with_pic
  enable_fast_install
  with_gnu_ld
@@ -47,7 +47,7 @@
  enable_libtool_lock
  enable_plugins
  enable_largefile
-@@ -1461,6 +1465,8 @@ Optional Packages:
+@@ -1504,6 +1508,8 @@ Optional Packages:
    --with-pic              try to use only PIC/non-PIC objects [default=use
                            both]
    --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
@@ -56,7 +56,7 @@
    --with-mmap             try using mmap for BFD input files if available
    --with-separate-debug-dir=DIR
                            Look for global separate debug info in DIR
-@@ -5393,8 +5399,8 @@ esac
+@@ -5693,8 +5699,8 @@ esac
  
  
  
@@ -67,7 +67,7 @@
  
  
  
-@@ -5434,7 +5440,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
+@@ -5734,7 +5740,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
  $as_echo_n "checking how to print strings... " >&6; }
  # Test print first, because it will be a builtin if present.
@@ -76,7 +76,7 @@
     test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
    ECHO='print -r --'
  elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
-@@ -6120,8 +6126,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
+@@ -6420,8 +6426,8 @@ $as_echo_n "checking whether the shell u
  # Try some XSI features
  xsi_shell=no
  ( _lt_dummy="a/b/c"
@@ -87,13 +87,13 @@
      && eval 'test $(( 1 + 1 )) -eq 2 \
      && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
    && xsi_shell=yes
-@@ -6170,6 +6176,80 @@ esac
+@@ -6470,6 +6476,80 @@ esac
  
  
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
 +$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
-+if test "${lt_cv_to_host_file_cmd+set}" = set; then :
++if ${lt_cv_to_host_file_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  case $host in
@@ -140,7 +140,7 @@
 +
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
 +$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
-+if test "${lt_cv_to_tool_file_cmd+set}" = set; then :
++if ${lt_cv_to_tool_file_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  #assume ordinary cross tools, or native build.
@@ -167,8 +167,8 @@
 +
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
  $as_echo_n "checking for $LD option to reload object files... " >&6; }
- if test "${lt_cv_ld_reload_flag+set}" = set; then :
-@@ -6186,6 +6266,11 @@ case $reload_flag in
+ if ${lt_cv_ld_reload_flag+:} false; then :
+@@ -6486,6 +6566,11 @@ case $reload_flag in
  esac
  reload_cmds='$LD$reload_flag -o $output$reload_objs'
  case $host_os in
@@ -180,7 +180,7 @@
    darwin*)
      if test "$GCC" = yes; then
        reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
-@@ -6354,7 +6439,8 @@ mingw* | pw32*)
+@@ -6654,7 +6739,8 @@ mingw* | pw32*)
      lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
      lt_cv_file_magic_cmd='func_win32_libid'
    else
@@ -190,7 +190,7 @@
      lt_cv_file_magic_cmd='$OBJDUMP -f'
    fi
    ;;
-@@ -6508,6 +6594,21 @@ esac
+@@ -6808,6 +6894,21 @@ esac
  fi
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
  $as_echo "$lt_cv_deplibs_check_method" >&6; }
@@ -212,7 +212,7 @@
  file_magic_cmd=$lt_cv_file_magic_cmd
  deplibs_check_method=$lt_cv_deplibs_check_method
  test -z "$deplibs_check_method" && deplibs_check_method=unknown
-@@ -6521,11 +6622,164 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
+@@ -6823,9 +6924,162 @@ test -z "$deplibs_check_method" && depli
  
  
  
@@ -226,8 +226,6 @@
 +
 +
 +
- 
- 
  if test -n "$ac_tool_prefix"; then
 -  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
 -set dummy ${ac_tool_prefix}ar; ac_word=$2
@@ -235,7 +233,7 @@
 +set dummy ${ac_tool_prefix}dlltool; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
++if ${ac_cv_prog_DLLTOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$DLLTOOL"; then
@@ -247,7 +245,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -275,7 +273,7 @@
 +set dummy dlltool; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
++if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$ac_ct_DLLTOOL"; then
@@ -287,7 +285,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_ac_ct_DLLTOOL="dlltool"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -335,7 +333,7 @@
 +
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
 +$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
-+if test "${lt_cv_sharedlib_from_linklib_cmd+set}" = set; then :
++if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_sharedlib_from_linklib_cmd='unknown'
@@ -378,17 +376,17 @@
 +set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
- if test "${ac_cv_prog_AR+set}" = set; then :
-@@ -6541,7 +6795,7 @@ do
+ if ${ac_cv_prog_AR+:} false; then :
+@@ -6841,7 +7095,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
-   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 -    ac_cv_prog_AR="${ac_tool_prefix}ar"
 +    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6561,11 +6815,15 @@ $as_echo "no" >&6; }
+@@ -6861,11 +7115,15 @@ $as_echo "no" >&6; }
  fi
  
  
@@ -406,17 +404,17 @@
 +set dummy $ac_prog; ac_word=$2
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
- if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
-@@ -6581,7 +6839,7 @@ do
+ if ${ac_cv_prog_ac_ct_AR+:} false; then :
+@@ -6881,7 +7139,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
-   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 -    ac_cv_prog_ac_ct_AR="ar"
 +    ac_cv_prog_ac_ct_AR="$ac_prog"
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6600,6 +6858,10 @@ else
+@@ -6900,6 +7158,10 @@ else
  $as_echo "no" >&6; }
  fi
  
@@ -427,7 +425,7 @@
    if test "x$ac_ct_AR" = x; then
      AR="false"
    else
-@@ -6611,16 +6873,72 @@ ac_tool_warned=yes ;;
+@@ -6911,16 +7173,72 @@ ac_tool_warned=yes ;;
  esac
      AR=$ac_ct_AR
    fi
@@ -449,16 +447,16 @@
 +
 +
 +
-+
+ 
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
 +$as_echo_n "checking for archiver @FILE support... " >&6; }
-+if test "${lt_cv_ar_at_file+set}" = set; then :
++if ${lt_cv_ar_at_file+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_ar_at_file=no
 +   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 +/* end confdefs.h.  */
-+
+ 
 +int
 +main ()
 +{
@@ -491,11 +489,11 @@
  
 +fi
 +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- 
++
 +fi
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
 +$as_echo "$lt_cv_ar_at_file" >&6; }
- 
++
 +if test "x$lt_cv_ar_at_file" = xno; then
 +  archiver_list_spec=
 +else
@@ -504,7 +502,7 @@
  
  
  
-@@ -6962,8 +7280,8 @@ esac
+@@ -7262,8 +7580,8 @@ esac
  lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
  
  # Transform an extracted symbol line into symbol name and symbol address
@@ -515,7 +513,7 @@
  
  # Handle CRLF in mingw tool chain
  opt_cr=
-@@ -6999,6 +7317,7 @@ for ac_symprfx in "" "_"; do
+@@ -7299,6 +7617,7 @@ for ac_symprfx in "" "_"; do
    else
      lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[	 ]\($symcode$symcode*\)[	 ][	 ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
    fi
@@ -523,7 +521,7 @@
  
    # Check to see that the pipe works correctly.
    pipe_works=no
-@@ -7040,6 +7359,18 @@ _LT_EOF
+@@ -7340,6 +7659,18 @@ _LT_EOF
        if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
  	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
  	  cat <<_LT_EOF > conftest.$ac_ext
@@ -542,7 +540,7 @@
  #ifdef __cplusplus
  extern "C" {
  #endif
-@@ -7051,7 +7382,7 @@ _LT_EOF
+@@ -7351,7 +7682,7 @@ _LT_EOF
  	  cat <<_LT_EOF >> conftest.$ac_ext
  
  /* The mapping between symbol names and symbols.  */
@@ -551,7 +549,7 @@
    const char *name;
    void       *address;
  }
-@@ -7077,8 +7408,8 @@ static const void *lt_preloaded_setup() {
+@@ -7377,8 +7708,8 @@ static const void *lt_preloaded_setup()
  _LT_EOF
  	  # Now try linking the two files.
  	  mv conftest.$ac_objext conftstm.$ac_objext
@@ -562,7 +560,7 @@
  	  LIBS="conftstm.$ac_objext"
  	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
  	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
-@@ -7088,8 +7419,8 @@ _LT_EOF
+@@ -7388,8 +7719,8 @@ _LT_EOF
    test $ac_status = 0; } && test -s conftest${ac_exeext}; then
  	    pipe_works=yes
  	  fi
@@ -573,7 +571,7 @@
  	else
  	  echo "cannot find nm_test_func in $nlist" >&5
  	fi
-@@ -7126,6 +7457,16 @@ else
+@@ -7426,6 +7757,20 @@ else
  $as_echo "ok" >&6; }
  fi
  
@@ -587,20 +585,17 @@
 +
 +
 +
++
++
++
++
  
  
  
-@@ -7142,6 +7483,45 @@ fi
+@@ -7445,6 +7790,41 @@ fi
  
  
  
-+
-+
-+
-+
-+
-+
-+
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
 +$as_echo_n "checking for sysroot... " >&6; }
 +
@@ -627,16 +622,19 @@
 + *)
 +   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libtool_sysroot}" >&5
 +$as_echo "${with_libtool_sysroot}" >&6; }
-+   as_fn_error "The sysroot must be an absolute path." "$LINENO" 5
++   as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
 +   ;;
 +esac
 +
 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
 +$as_echo "${lt_sysroot:-no}" >&6; }
++
++
++
  
  
- 
-@@ -7353,6 +7733,123 @@ esac
+ # Check whether --enable-libtool-lock was given.
+@@ -7653,6 +8033,123 @@ esac
  
  need_locks="$enable_libtool_lock"
  
@@ -645,7 +643,7 @@
 +set dummy ${ac_tool_prefix}mt; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_MANIFEST_TOOL+set}" = set; then :
++if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$MANIFEST_TOOL"; then
@@ -657,7 +655,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -685,7 +683,7 @@
 +set dummy mt; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_ac_ct_MANIFEST_TOOL+set}" = set; then :
++if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$ac_ct_MANIFEST_TOOL"; then
@@ -697,7 +695,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -735,7 +733,7 @@
 +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
 +$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
-+if test "${lt_cv_path_mainfest_tool+set}" = set; then :
++if ${lt_cv_path_mainfest_tool+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_path_mainfest_tool=no
@@ -760,7 +758,7 @@
  
    case $host_os in
      rhapsody* | darwin*)
-@@ -7916,6 +8413,8 @@ _LT_EOF
+@@ -8216,6 +8713,8 @@ _LT_EOF
        $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
        echo "$AR cru libconftest.a conftest.o" >&5
        $AR cru libconftest.a conftest.o 2>&5
@@ -769,7 +767,7 @@
        cat > conftest.c << _LT_EOF
  int main() { return 0;}
  _LT_EOF
-@@ -8080,7 +8579,8 @@ fi
+@@ -8380,7 +8879,8 @@ fi
  LIBTOOL_DEPS="$ltmain"
  
  # Always use our own libtool.
@@ -779,7 +777,7 @@
  
  
  
-@@ -8169,7 +8669,7 @@ aix3*)
+@@ -8469,7 +8969,7 @@ aix3*)
  esac
  
  # Global variables:
@@ -788,7 +786,7 @@
  can_build_shared=yes
  
  # All known linkers require a `.a' archive for static linking (except MSVC,
-@@ -8467,8 +8967,6 @@ fi
+@@ -8767,8 +9267,6 @@ fi
  lt_prog_compiler_pic=
  lt_prog_compiler_static=
  
@@ -797,7 +795,7 @@
  
    if test "$GCC" = yes; then
      lt_prog_compiler_wl='-Wl,'
-@@ -8634,6 +9132,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8934,6 +9432,12 @@ $as_echo_n "checking for $compiler optio
  	lt_prog_compiler_pic='--shared'
  	lt_prog_compiler_static='--static'
  	;;
@@ -810,7 +808,7 @@
        pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
          # Portland Group compilers (*not* the Pentium gcc compiler,
  	# which looks to be a dead project)
-@@ -8696,7 +9200,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8996,7 +9500,7 @@ $as_echo_n "checking for $compiler optio
        lt_prog_compiler_pic='-KPIC'
        lt_prog_compiler_static='-Bstatic'
        case $cc_basename in
@@ -819,7 +817,7 @@
  	lt_prog_compiler_wl='-Qoption ld ';;
        *)
  	lt_prog_compiler_wl='-Wl,';;
-@@ -8753,13 +9257,17 @@ case $host_os in
+@@ -9053,13 +9557,17 @@ case $host_os in
      lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
      ;;
  esac
@@ -832,7 +830,7 @@
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-+if test "${lt_cv_prog_compiler_pic+set}" = set; then :
++if ${lt_cv_prog_compiler_pic+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
@@ -843,7 +841,7 @@
  
  #
  # Check to make sure the PIC flag actually works.
-@@ -8820,6 +9328,11 @@ fi
+@@ -9120,6 +9628,11 @@ fi
  
  
  
@@ -855,7 +853,7 @@
  #
  # Check to make sure the static flag actually works.
  #
-@@ -9170,7 +9683,8 @@ _LT_EOF
+@@ -9470,7 +9983,8 @@ _LT_EOF
        allow_undefined_flag=unsupported
        always_export_symbols=no
        enable_shared_with_static_runtimes=yes
@@ -865,7 +863,7 @@
  
        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
          archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-@@ -9269,12 +9783,12 @@ _LT_EOF
+@@ -9569,12 +10083,12 @@ _LT_EOF
  	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
  	  hardcode_libdir_flag_spec=
  	  hardcode_libdir_flag_spec_ld='-rpath $libdir'
@@ -880,7 +878,7 @@
  	  fi
  	  ;;
  	esac
-@@ -9288,8 +9802,8 @@ _LT_EOF
+@@ -9588,8 +10102,8 @@ _LT_EOF
  	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
  	wlarc=
        else
@@ -891,7 +889,7 @@
        fi
        ;;
  
-@@ -9307,8 +9821,8 @@ _LT_EOF
+@@ -9607,8 +10121,8 @@ _LT_EOF
  
  _LT_EOF
        elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -902,7 +900,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9354,8 +9868,8 @@ _LT_EOF
+@@ -9654,8 +10168,8 @@ _LT_EOF
  
      *)
        if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -913,7 +911,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9485,7 +9999,13 @@ _LT_EOF
+@@ -9785,7 +10299,13 @@ _LT_EOF
  	allow_undefined_flag='-berok'
          # Determine the default libpath from the value encoded in an
          # empty executable.
@@ -921,14 +919,14 @@
 +        if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  if ${lt_cv_aix_libpath_+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  /* end confdefs.h.  */
  
  int
-@@ -9498,22 +10018,29 @@ main ()
+@@ -9798,22 +10318,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -971,7 +969,7 @@
  
          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
          archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
-@@ -9525,7 +10052,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9825,7 +10352,13 @@ if test -z "$aix_libpath"; then aix_libp
  	else
  	 # Determine the default libpath from the value encoded in an
  	 # empty executable.
@@ -979,14 +977,14 @@
 +	 if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  if ${lt_cv_aix_libpath_+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  /* end confdefs.h.  */
  
  int
-@@ -9538,22 +10071,29 @@ main ()
+@@ -9838,22 +10371,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -1029,7 +1027,7 @@
  
  	 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
  	  # Warning - without using the other run time loading flags,
-@@ -9598,20 +10138,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9898,20 +10438,63 @@ if test -z "$aix_libpath"; then aix_libp
        # Microsoft Visual C++.
        # hardcode_libdir_flag_spec is actually meaningless, as there is
        # no search path for DLLs.
@@ -1107,7 +1105,7 @@
        ;;
  
      darwin* | rhapsody*)
-@@ -9672,7 +10255,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9972,7 +10555,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
      freebsd* | dragonfly*)
@@ -1116,7 +1114,7 @@
        hardcode_libdir_flag_spec='-R$libdir'
        hardcode_direct=yes
        hardcode_shlibpath_var=no
-@@ -9680,7 +10263,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9980,7 +10563,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      hpux9*)
        if test "$GCC" = yes; then
@@ -1125,7 +1123,7 @@
        else
  	archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
        fi
-@@ -9696,7 +10279,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9996,7 +10579,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      hpux10*)
        if test "$GCC" = yes && test "$with_gnu_ld" = no; then
@@ -1134,7 +1132,7 @@
        else
  	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
        fi
-@@ -9720,10 +10303,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -10020,10 +10603,10 @@ if test -z "$aix_libpath"; then aix_libp
  	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  	  ;;
  	ia64*)
@@ -1147,7 +1145,7 @@
  	  ;;
  	esac
        else
-@@ -9802,23 +10385,36 @@ fi
+@@ -10102,23 +10685,36 @@ fi
  
      irix5* | irix6* | nonstopux*)
        if test "$GCC" = yes; then
@@ -1162,7 +1160,7 @@
 +	# This should be the same for all languages, so no per-tag cache variable.
 +	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
 +$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
-+if test "${lt_cv_irix_exported_symbol+set}" = set; then :
++if ${lt_cv_irix_exported_symbol+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  save_LDFLAGS="$LDFLAGS"
@@ -1192,7 +1190,7 @@
        else
  	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
  	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
-@@ -9903,7 +10499,7 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -10203,7 +10799,7 @@ rm -f core conftest.err conftest.$ac_obj
      osf4* | osf5*)	# as osf3* with the addition of -msym flag
        if test "$GCC" = yes; then
  	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
@@ -1201,7 +1199,7 @@
  	hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
        else
  	allow_undefined_flag=' -expect_unresolved \*'
-@@ -9922,9 +10518,9 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -10222,9 +10818,9 @@ rm -f core conftest.err conftest.$ac_obj
        no_undefined_flag=' -z defs'
        if test "$GCC" = yes; then
  	wlarc='${wl}'
@@ -1213,7 +1211,7 @@
        else
  	case `$CC -V 2>&1` in
  	*"Compilers 5.0"*)
-@@ -10500,8 +11096,9 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10800,8 +11396,9 @@ cygwin* | mingw* | pw32* | cegcc*)
    need_version=no
    need_lib_prefix=no
  
@@ -1225,7 +1223,7 @@
      library_names_spec='$libname.dll.a'
      # DLL is installed to $(libdir)/../bin by postinstall_cmds
      postinstall_cmds='base_file=`basename \${file}`~
-@@ -10534,13 +11131,71 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10834,13 +11431,71 @@ cygwin* | mingw* | pw32* | cegcc*)
        library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
        ;;
      esac
@@ -1298,7 +1296,7 @@
    # FIXME: first we should search . and the directory the executable is in
    shlibpath_var=PATH
    ;;
-@@ -10632,7 +11287,7 @@ haiku*)
+@@ -10932,7 +11587,7 @@ haiku*)
    soname_spec='${libname}${release}${shared_ext}$major'
    shlibpath_var=LIBRARY_PATH
    shlibpath_overrides_runpath=yes
@@ -1307,7 +1305,16 @@
    hardcode_into_libs=yes
    ;;
  
-@@ -11472,10 +12127,10 @@ else
+@@ -11728,7 +12383,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11731 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11772,10 +12427,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -1320,7 +1327,16 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -11578,10 +12233,10 @@ else
+@@ -11834,7 +12489,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11837 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11878,10 +12533,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -1333,7 +1349,7 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -14172,7 +14827,7 @@ SHARED_LDFLAGS=
+@@ -14525,7 +15180,7 @@ SHARED_LDFLAGS=
  if test "$enable_shared" = "yes"; then
    x=`sed -n -e 's/^[ 	]*PICFLAG[ 	]*=[ 	]*//p' < ../libiberty/Makefile | sed -n '$p'`
    if test -n "$x"; then
@@ -1342,7 +1358,7 @@
    fi
  
  # More hacks to build DLLs on Windows.
-@@ -16879,13 +17534,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
+@@ -17139,13 +17794,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_
  lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
  lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
  lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
@@ -1363,7 +1379,7 @@
  STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
  RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
  old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-@@ -16900,14 +17562,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
+@@ -17160,14 +17822,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$l
  lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
@@ -1382,7 +1398,7 @@
  DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
  NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
  LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-@@ -16940,12 +17605,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
+@@ -17200,12 +17865,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcod
  hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
  inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
  link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
@@ -1396,7 +1412,7 @@
  file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
  variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
  need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-@@ -17000,8 +17665,13 @@ reload_flag \
+@@ -17260,8 +17925,13 @@ reload_flag \
  OBJDUMP \
  deplibs_check_method \
  file_magic_cmd \
@@ -1410,7 +1426,7 @@
  STRIP \
  RANLIB \
  CC \
-@@ -17011,12 +17681,14 @@ lt_cv_sys_global_symbol_pipe \
+@@ -17271,12 +17941,14 @@ lt_cv_sys_global_symbol_pipe \
  lt_cv_sys_global_symbol_to_cdecl \
  lt_cv_sys_global_symbol_to_c_name_address \
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
@@ -1426,7 +1442,7 @@
  DSYMUTIL \
  NMEDIT \
  LIPO \
-@@ -17032,7 +17704,6 @@ no_undefined_flag \
+@@ -17292,7 +17964,6 @@ no_undefined_flag \
  hardcode_libdir_flag_spec \
  hardcode_libdir_flag_spec_ld \
  hardcode_libdir_separator \
@@ -1434,7 +1450,7 @@
  exclude_expsyms \
  include_expsyms \
  file_list_spec \
-@@ -17068,6 +17739,7 @@ module_cmds \
+@@ -17328,6 +17999,7 @@ module_cmds \
  module_expsym_cmds \
  export_symbols_cmds \
  prelink_cmds \
@@ -1442,7 +1458,7 @@
  postinstall_cmds \
  postuninstall_cmds \
  finish_cmds \
-@@ -17847,7 +18519,8 @@ $as_echo X"$file" |
+@@ -18116,7 +18788,8 @@ $as_echo X"$file" |
  # NOTE: Changes made to this file will be lost: look at ltmain.sh.
  #
  #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
@@ -1452,7 +1468,7 @@
  #   Written by Gordon Matzigkeit, 1996
  #
  #   This file is part of GNU Libtool.
-@@ -17950,19 +18623,42 @@ SP2NL=$lt_lt_SP2NL
+@@ -18219,19 +18892,42 @@ SP2NL=$lt_lt_SP2NL
  # turn newlines into spaces.
  NL2SP=$lt_lt_NL2SP
  
@@ -1496,7 +1512,7 @@
  # A symbol stripping program.
  STRIP=$lt_STRIP
  
-@@ -17992,6 +18688,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
+@@ -18261,6 +18957,12 @@ global_symbol_to_c_name_address=$lt_lt_c
  # Transform the output of nm in a C name address pair when lib prefix is needed.
  global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
  
@@ -1509,7 +1525,7 @@
  # The name of the directory that contains temporary libtool files.
  objdir=$objdir
  
-@@ -18001,6 +18703,9 @@ MAGIC_CMD=$MAGIC_CMD
+@@ -18270,6 +18972,9 @@ MAGIC_CMD=$MAGIC_CMD
  # Must we lock files when doing compilation?
  need_locks=$lt_need_locks
  
@@ -1519,7 +1535,7 @@
  # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
  DSYMUTIL=$lt_DSYMUTIL
  
-@@ -18115,12 +18820,12 @@ with_gcc=$GCC
+@@ -18384,12 +19089,12 @@ with_gcc=$GCC
  # Compiler flag to turn off builtin functions.
  no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
  
@@ -1535,7 +1551,7 @@
  # Compiler flag to prevent dynamic linking.
  link_static_flag=$lt_lt_prog_compiler_static
  
-@@ -18207,9 +18912,6 @@ inherit_rpath=$inherit_rpath
+@@ -18476,9 +19181,6 @@ inherit_rpath=$inherit_rpath
  # Whether libtool must link a program against all its dependency libraries.
  link_all_deplibs=$link_all_deplibs
  
@@ -1545,7 +1561,7 @@
  # Set to "yes" if exported symbols are required.
  always_export_symbols=$always_export_symbols
  
-@@ -18225,6 +18927,9 @@ include_expsyms=$lt_include_expsyms
+@@ -18494,6 +19196,9 @@ include_expsyms=$lt_include_expsyms
  # Commands necessary for linking programs (against libraries) with templates.
  prelink_cmds=$lt_prelink_cmds
  
@@ -1555,7 +1571,7 @@
  # Specify filename containing input files.
  file_list_spec=$lt_file_list_spec
  
-@@ -18257,210 +18962,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
+@@ -18526,210 +19231,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
    # if finds mixed CR/LF and LF-only lines.  Since sed operates in
    # text mode, it properly converts lines to CR/LF.  This bash problem
    # is reportedly fixed, but why not run on old versions too?
@@ -1757,15 +1773,9 @@
 -_LT_EOF
 -    ;;
 -  esac
--
--
--  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
--    || (rm -f "$cfgfile"; exit 1)
--
--  mv -f "$cfgfile" "$ofile" ||
 +  sed '$q' "$ltmain" >> "$cfgfile" \
 +     || (rm -f "$cfgfile"; exit 1)
-+
+ 
 +  if test x"$xsi_shell" = xyes; then
 +  sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
 +func_dirname ()\
@@ -1923,17 +1933,20 @@
 +  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
 +$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
 +fi
-+
-+
+ 
+-  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
+-    || (rm -f "$cfgfile"; exit 1)
+ 
+-  mv -f "$cfgfile" "$ofile" ||
 +   mv -f "$cfgfile" "$ofile" ||
      (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
    chmod +x "$ofile"
  
-diff --git a/bfd/configure.ac b/bfd/configure.ac
-index 2342f3faea..a6451fccda 100644
---- a/bfd/configure.ac
-+++ b/bfd/configure.ac
-@@ -254,7 +254,7 @@ changequote(,)dnl
+Index: git/bfd/configure.ac
+===================================================================
+--- git.orig/bfd/configure.ac
++++ git/bfd/configure.ac
+@@ -293,7 +293,7 @@ changequote(,)dnl
    x=`sed -n -e 's/^[ 	]*PICFLAG[ 	]*=[ 	]*//p' < ../libiberty/Makefile | sed -n '$p'`
  changequote([,])dnl
    if test -n "$x"; then
@@ -1942,11 +1955,11 @@
    fi
  
  # More hacks to build DLLs on Windows.
-diff --git a/binutils/configure b/binutils/configure
-index 5d9c9105a7..a65b2b4518 100755
---- a/binutils/configure
-+++ b/binutils/configure
-@@ -659,8 +659,11 @@ OTOOL
+Index: git/binutils/configure
+===================================================================
+--- git.orig/binutils/configure
++++ git/binutils/configure
+@@ -688,8 +688,11 @@ OTOOL
  LIPO
  NMEDIT
  DSYMUTIL
@@ -1958,7 +1971,7 @@
  OBJDUMP
  LN_S
  NM
-@@ -772,6 +775,7 @@ enable_static
+@@ -806,6 +809,7 @@ enable_static
  with_pic
  enable_fast_install
  with_gnu_ld
@@ -1966,7 +1979,7 @@
  enable_libtool_lock
  enable_plugins
  enable_largefile
-@@ -1444,6 +1448,8 @@ Optional Packages:
+@@ -1482,6 +1486,8 @@ Optional Packages:
    --with-pic              try to use only PIC/non-PIC objects [default=use
                            both]
    --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
@@ -1975,7 +1988,7 @@
    --with-system-zlib      use installed libz
    --with-gnu-ld           assume the C compiler uses GNU ld default=no
    --with-libiconv-prefix[=DIR]  search for libiconv in DIR/include and DIR/lib
-@@ -5160,8 +5166,8 @@ esac
+@@ -5453,8 +5459,8 @@ esac
  
  
  
@@ -1986,7 +1999,7 @@
  
  
  
-@@ -5201,7 +5207,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
+@@ -5494,7 +5500,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
  $as_echo_n "checking how to print strings... " >&6; }
  # Test print first, because it will be a builtin if present.
@@ -1995,7 +2008,7 @@
     test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
    ECHO='print -r --'
  elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
-@@ -5887,8 +5893,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
+@@ -6180,8 +6186,8 @@ $as_echo_n "checking whether the shell u
  # Try some XSI features
  xsi_shell=no
  ( _lt_dummy="a/b/c"
@@ -2006,13 +2019,13 @@
      && eval 'test $(( 1 + 1 )) -eq 2 \
      && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
    && xsi_shell=yes
-@@ -5937,6 +5943,80 @@ esac
+@@ -6230,6 +6236,80 @@ esac
  
  
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
 +$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
-+if test "${lt_cv_to_host_file_cmd+set}" = set; then :
++if ${lt_cv_to_host_file_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  case $host in
@@ -2059,7 +2072,7 @@
 +
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
 +$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
-+if test "${lt_cv_to_tool_file_cmd+set}" = set; then :
++if ${lt_cv_to_tool_file_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  #assume ordinary cross tools, or native build.
@@ -2086,8 +2099,8 @@
 +
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
  $as_echo_n "checking for $LD option to reload object files... " >&6; }
- if test "${lt_cv_ld_reload_flag+set}" = set; then :
-@@ -5953,6 +6033,11 @@ case $reload_flag in
+ if ${lt_cv_ld_reload_flag+:} false; then :
+@@ -6246,6 +6326,11 @@ case $reload_flag in
  esac
  reload_cmds='$LD$reload_flag -o $output$reload_objs'
  case $host_os in
@@ -2099,7 +2112,7 @@
    darwin*)
      if test "$GCC" = yes; then
        reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
-@@ -6121,7 +6206,8 @@ mingw* | pw32*)
+@@ -6414,7 +6499,8 @@ mingw* | pw32*)
      lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
      lt_cv_file_magic_cmd='func_win32_libid'
    else
@@ -2109,7 +2122,7 @@
      lt_cv_file_magic_cmd='$OBJDUMP -f'
    fi
    ;;
-@@ -6275,6 +6361,21 @@ esac
+@@ -6568,6 +6654,21 @@ esac
  fi
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
  $as_echo "$lt_cv_deplibs_check_method" >&6; }
@@ -2131,7 +2144,7 @@
  file_magic_cmd=$lt_cv_file_magic_cmd
  deplibs_check_method=$lt_cv_deplibs_check_method
  test -z "$deplibs_check_method" && deplibs_check_method=unknown
-@@ -6290,9 +6391,162 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
+@@ -6583,9 +6684,162 @@ test -z "$deplibs_check_method" && depli
  
  
  
@@ -2150,7 +2163,7 @@
 +set dummy ${ac_tool_prefix}dlltool; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
++if ${ac_cv_prog_DLLTOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$DLLTOOL"; then
@@ -2162,7 +2175,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -2190,7 +2203,7 @@
 +set dummy dlltool; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
++if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$ac_ct_DLLTOOL"; then
@@ -2202,7 +2215,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_ac_ct_DLLTOOL="dlltool"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -2250,7 +2263,7 @@
 +
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
 +$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
-+if test "${lt_cv_sharedlib_from_linklib_cmd+set}" = set; then :
++if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_sharedlib_from_linklib_cmd='unknown'
@@ -2295,17 +2308,17 @@
 +set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
- if test "${ac_cv_prog_AR+set}" = set; then :
-@@ -6308,7 +6562,7 @@ do
+ if ${ac_cv_prog_AR+:} false; then :
+@@ -6601,7 +6855,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
-   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 -    ac_cv_prog_AR="${ac_tool_prefix}ar"
 +    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6328,11 +6582,15 @@ $as_echo "no" >&6; }
+@@ -6621,11 +6875,15 @@ $as_echo "no" >&6; }
  fi
  
  
@@ -2323,17 +2336,17 @@
 +set dummy $ac_prog; ac_word=$2
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
- if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
-@@ -6348,7 +6606,7 @@ do
+ if ${ac_cv_prog_ac_ct_AR+:} false; then :
+@@ -6641,7 +6899,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
-   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 -    ac_cv_prog_ac_ct_AR="ar"
 +    ac_cv_prog_ac_ct_AR="$ac_prog"
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6367,6 +6625,10 @@ else
+@@ -6660,6 +6918,10 @@ else
  $as_echo "no" >&6; }
  fi
  
@@ -2344,7 +2357,7 @@
    if test "x$ac_ct_AR" = x; then
      AR="false"
    else
-@@ -6378,12 +6640,10 @@ ac_tool_warned=yes ;;
+@@ -6671,12 +6933,10 @@ ac_tool_warned=yes ;;
  esac
      AR=$ac_ct_AR
    fi
@@ -2359,13 +2372,13 @@
  
  
  
-@@ -6395,6 +6655,64 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
+@@ -6688,6 +6948,64 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
  
  
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
 +$as_echo_n "checking for archiver @FILE support... " >&6; }
-+if test "${lt_cv_ar_at_file+set}" = set; then :
++if ${lt_cv_ar_at_file+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_ar_at_file=no
@@ -2424,7 +2437,7 @@
  if test -n "$ac_tool_prefix"; then
    # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
  set dummy ${ac_tool_prefix}strip; ac_word=$2
-@@ -6729,8 +7047,8 @@ esac
+@@ -7022,8 +7340,8 @@ esac
  lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
  
  # Transform an extracted symbol line into symbol name and symbol address
@@ -2435,7 +2448,7 @@
  
  # Handle CRLF in mingw tool chain
  opt_cr=
-@@ -6766,6 +7084,7 @@ for ac_symprfx in "" "_"; do
+@@ -7059,6 +7377,7 @@ for ac_symprfx in "" "_"; do
    else
      lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[	 ]\($symcode$symcode*\)[	 ][	 ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
    fi
@@ -2443,7 +2456,7 @@
  
    # Check to see that the pipe works correctly.
    pipe_works=no
-@@ -6807,6 +7126,18 @@ _LT_EOF
+@@ -7100,6 +7419,18 @@ _LT_EOF
        if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
  	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
  	  cat <<_LT_EOF > conftest.$ac_ext
@@ -2462,7 +2475,7 @@
  #ifdef __cplusplus
  extern "C" {
  #endif
-@@ -6818,7 +7149,7 @@ _LT_EOF
+@@ -7111,7 +7442,7 @@ _LT_EOF
  	  cat <<_LT_EOF >> conftest.$ac_ext
  
  /* The mapping between symbol names and symbols.  */
@@ -2471,7 +2484,7 @@
    const char *name;
    void       *address;
  }
-@@ -6844,8 +7175,8 @@ static const void *lt_preloaded_setup() {
+@@ -7137,8 +7468,8 @@ static const void *lt_preloaded_setup()
  _LT_EOF
  	  # Now try linking the two files.
  	  mv conftest.$ac_objext conftstm.$ac_objext
@@ -2482,7 +2495,7 @@
  	  LIBS="conftstm.$ac_objext"
  	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
  	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
-@@ -6855,8 +7186,8 @@ _LT_EOF
+@@ -7148,8 +7479,8 @@ _LT_EOF
    test $ac_status = 0; } && test -s conftest${ac_exeext}; then
  	    pipe_works=yes
  	  fi
@@ -2493,7 +2506,7 @@
  	else
  	  echo "cannot find nm_test_func in $nlist" >&5
  	fi
-@@ -6893,6 +7224,21 @@ else
+@@ -7186,6 +7517,18 @@ else
  $as_echo "ok" >&6; }
  fi
  
@@ -2509,18 +2522,13 @@
 +
 +
 +
-+
-+
-+
  
  
  
-@@ -6908,6 +7254,40 @@ fi
+@@ -7207,6 +7550,43 @@ fi
  
  
  
-+
-+
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
 +$as_echo_n "checking for sysroot... " >&6; }
 +
@@ -2547,16 +2555,21 @@
 + *)
 +   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libtool_sysroot}" >&5
 +$as_echo "${with_libtool_sysroot}" >&6; }
-+   as_fn_error "The sysroot must be an absolute path." "$LINENO" 5
++   as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
 +   ;;
 +esac
 +
 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
 +$as_echo "${lt_sysroot:-no}" >&6; }
- 
- 
- 
-@@ -7120,6 +7500,123 @@ esac
++
++
++
++
++
+ # Check whether --enable-libtool-lock was given.
+ if test "${enable_libtool_lock+set}" = set; then :
+   enableval=$enable_libtool_lock;
+@@ -7413,6 +7793,123 @@ esac
  
  need_locks="$enable_libtool_lock"
  
@@ -2565,7 +2578,7 @@
 +set dummy ${ac_tool_prefix}mt; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_MANIFEST_TOOL+set}" = set; then :
++if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$MANIFEST_TOOL"; then
@@ -2577,7 +2590,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -2605,7 +2618,7 @@
 +set dummy mt; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_ac_ct_MANIFEST_TOOL+set}" = set; then :
++if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$ac_ct_MANIFEST_TOOL"; then
@@ -2617,7 +2630,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -2655,7 +2668,7 @@
 +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
 +$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
-+if test "${lt_cv_path_mainfest_tool+set}" = set; then :
++if ${lt_cv_path_mainfest_tool+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_path_mainfest_tool=no
@@ -2680,7 +2693,7 @@
  
    case $host_os in
      rhapsody* | darwin*)
-@@ -7683,6 +8180,8 @@ _LT_EOF
+@@ -7976,6 +8473,8 @@ _LT_EOF
        $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
        echo "$AR cru libconftest.a conftest.o" >&5
        $AR cru libconftest.a conftest.o 2>&5
@@ -2689,7 +2702,7 @@
        cat > conftest.c << _LT_EOF
  int main() { return 0;}
  _LT_EOF
-@@ -7878,7 +8377,8 @@ fi
+@@ -8171,7 +8670,8 @@ fi
  LIBTOOL_DEPS="$ltmain"
  
  # Always use our own libtool.
@@ -2699,7 +2712,7 @@
  
  
  
-@@ -7967,7 +8467,7 @@ aix3*)
+@@ -8260,7 +8760,7 @@ aix3*)
  esac
  
  # Global variables:
@@ -2708,7 +2721,7 @@
  can_build_shared=yes
  
  # All known linkers require a `.a' archive for static linking (except MSVC,
-@@ -8265,8 +8765,6 @@ fi
+@@ -8558,8 +9058,6 @@ fi
  lt_prog_compiler_pic=
  lt_prog_compiler_static=
  
@@ -2717,7 +2730,7 @@
  
    if test "$GCC" = yes; then
      lt_prog_compiler_wl='-Wl,'
-@@ -8432,6 +8930,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8725,6 +9223,12 @@ $as_echo_n "checking for $compiler optio
  	lt_prog_compiler_pic='--shared'
  	lt_prog_compiler_static='--static'
  	;;
@@ -2730,7 +2743,7 @@
        pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
          # Portland Group compilers (*not* the Pentium gcc compiler,
  	# which looks to be a dead project)
-@@ -8494,7 +8998,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8787,7 +9291,7 @@ $as_echo_n "checking for $compiler optio
        lt_prog_compiler_pic='-KPIC'
        lt_prog_compiler_static='-Bstatic'
        case $cc_basename in
@@ -2739,7 +2752,7 @@
  	lt_prog_compiler_wl='-Qoption ld ';;
        *)
  	lt_prog_compiler_wl='-Wl,';;
-@@ -8551,13 +9055,17 @@ case $host_os in
+@@ -8844,13 +9348,17 @@ case $host_os in
      lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
      ;;
  esac
@@ -2752,7 +2765,7 @@
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-+if test "${lt_cv_prog_compiler_pic+set}" = set; then :
++if ${lt_cv_prog_compiler_pic+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
@@ -2763,7 +2776,7 @@
  
  #
  # Check to make sure the PIC flag actually works.
-@@ -8618,6 +9126,11 @@ fi
+@@ -8911,6 +9419,11 @@ fi
  
  
  
@@ -2775,7 +2788,7 @@
  #
  # Check to make sure the static flag actually works.
  #
-@@ -8968,7 +9481,8 @@ _LT_EOF
+@@ -9261,7 +9774,8 @@ _LT_EOF
        allow_undefined_flag=unsupported
        always_export_symbols=no
        enable_shared_with_static_runtimes=yes
@@ -2785,7 +2798,7 @@
  
        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
          archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-@@ -9067,12 +9581,12 @@ _LT_EOF
+@@ -9360,12 +9874,12 @@ _LT_EOF
  	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
  	  hardcode_libdir_flag_spec=
  	  hardcode_libdir_flag_spec_ld='-rpath $libdir'
@@ -2800,7 +2813,7 @@
  	  fi
  	  ;;
  	esac
-@@ -9086,8 +9600,8 @@ _LT_EOF
+@@ -9379,8 +9893,8 @@ _LT_EOF
  	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
  	wlarc=
        else
@@ -2811,7 +2824,7 @@
        fi
        ;;
  
-@@ -9105,8 +9619,8 @@ _LT_EOF
+@@ -9398,8 +9912,8 @@ _LT_EOF
  
  _LT_EOF
        elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -2822,7 +2835,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9152,8 +9666,8 @@ _LT_EOF
+@@ -9445,8 +9959,8 @@ _LT_EOF
  
      *)
        if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -2833,7 +2846,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9283,7 +9797,13 @@ _LT_EOF
+@@ -9576,7 +10090,13 @@ _LT_EOF
  	allow_undefined_flag='-berok'
          # Determine the default libpath from the value encoded in an
          # empty executable.
@@ -2841,14 +2854,14 @@
 +        if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  if ${lt_cv_aix_libpath_+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  /* end confdefs.h.  */
  
  int
-@@ -9296,22 +9816,29 @@ main ()
+@@ -9589,22 +10109,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -2891,7 +2904,7 @@
  
          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
          archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
-@@ -9323,7 +9850,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9616,7 +10143,13 @@ if test -z "$aix_libpath"; then aix_libp
  	else
  	 # Determine the default libpath from the value encoded in an
  	 # empty executable.
@@ -2899,14 +2912,14 @@
 +	 if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  if ${lt_cv_aix_libpath_+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  /* end confdefs.h.  */
  
  int
-@@ -9336,22 +9869,29 @@ main ()
+@@ -9629,22 +10162,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -2949,7 +2962,7 @@
  
  	 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
  	  # Warning - without using the other run time loading flags,
-@@ -9396,20 +9936,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9689,20 +10229,63 @@ if test -z "$aix_libpath"; then aix_libp
        # Microsoft Visual C++.
        # hardcode_libdir_flag_spec is actually meaningless, as there is
        # no search path for DLLs.
@@ -3027,7 +3040,7 @@
        ;;
  
      darwin* | rhapsody*)
-@@ -9470,7 +10053,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9763,7 +10346,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
      freebsd* | dragonfly*)
@@ -3036,7 +3049,7 @@
        hardcode_libdir_flag_spec='-R$libdir'
        hardcode_direct=yes
        hardcode_shlibpath_var=no
-@@ -9478,7 +10061,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9771,7 +10354,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      hpux9*)
        if test "$GCC" = yes; then
@@ -3045,7 +3058,7 @@
        else
  	archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
        fi
-@@ -9494,7 +10077,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9787,7 +10370,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      hpux10*)
        if test "$GCC" = yes && test "$with_gnu_ld" = no; then
@@ -3054,7 +3067,7 @@
        else
  	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
        fi
-@@ -9518,10 +10101,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9811,10 +10394,10 @@ if test -z "$aix_libpath"; then aix_libp
  	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  	  ;;
  	ia64*)
@@ -3067,7 +3080,7 @@
  	  ;;
  	esac
        else
-@@ -9600,23 +10183,36 @@ fi
+@@ -9893,23 +10476,36 @@ fi
  
      irix5* | irix6* | nonstopux*)
        if test "$GCC" = yes; then
@@ -3082,7 +3095,7 @@
 +	# This should be the same for all languages, so no per-tag cache variable.
 +	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
 +$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
-+if test "${lt_cv_irix_exported_symbol+set}" = set; then :
++if ${lt_cv_irix_exported_symbol+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  save_LDFLAGS="$LDFLAGS"
@@ -3112,7 +3125,7 @@
        else
  	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
  	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
-@@ -9701,7 +10297,7 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -9994,7 +10590,7 @@ rm -f core conftest.err conftest.$ac_obj
      osf4* | osf5*)	# as osf3* with the addition of -msym flag
        if test "$GCC" = yes; then
  	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
@@ -3121,7 +3134,7 @@
  	hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
        else
  	allow_undefined_flag=' -expect_unresolved \*'
-@@ -9720,9 +10316,9 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -10013,9 +10609,9 @@ rm -f core conftest.err conftest.$ac_obj
        no_undefined_flag=' -z defs'
        if test "$GCC" = yes; then
  	wlarc='${wl}'
@@ -3133,7 +3146,7 @@
        else
  	case `$CC -V 2>&1` in
  	*"Compilers 5.0"*)
-@@ -10298,8 +10894,9 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10591,8 +11187,9 @@ cygwin* | mingw* | pw32* | cegcc*)
    need_version=no
    need_lib_prefix=no
  
@@ -3145,7 +3158,7 @@
      library_names_spec='$libname.dll.a'
      # DLL is installed to $(libdir)/../bin by postinstall_cmds
      postinstall_cmds='base_file=`basename \${file}`~
-@@ -10332,13 +10929,71 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10625,13 +11222,71 @@ cygwin* | mingw* | pw32* | cegcc*)
        library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
        ;;
      esac
@@ -3218,7 +3231,7 @@
    # FIXME: first we should search . and the directory the executable is in
    shlibpath_var=PATH
    ;;
-@@ -10430,7 +11085,7 @@ haiku*)
+@@ -10723,7 +11378,7 @@ haiku*)
    soname_spec='${libname}${release}${shared_ext}$major'
    shlibpath_var=LIBRARY_PATH
    shlibpath_overrides_runpath=yes
@@ -3227,7 +3240,16 @@
    hardcode_into_libs=yes
    ;;
  
-@@ -11270,10 +11925,10 @@ else
+@@ -11519,7 +12174,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11522 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11563,10 +12218,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -3240,7 +3262,16 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -11376,10 +12031,10 @@ else
+@@ -11625,7 +12280,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11628 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11669,10 +12324,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -3253,7 +3284,7 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -15446,13 +16101,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
+@@ -15731,13 +16386,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_
  lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
  lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
  lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
@@ -3274,7 +3305,7 @@
  STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
  RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
  old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-@@ -15467,14 +16129,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
+@@ -15752,14 +16414,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$l
  lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
@@ -3293,7 +3324,7 @@
  DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
  NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
  LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-@@ -15507,12 +16172,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
+@@ -15792,12 +16457,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcod
  hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
  inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
  link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
@@ -3307,7 +3338,7 @@
  file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
  variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
  need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-@@ -15567,8 +16232,13 @@ reload_flag \
+@@ -15852,8 +16517,13 @@ reload_flag \
  OBJDUMP \
  deplibs_check_method \
  file_magic_cmd \
@@ -3321,7 +3352,7 @@
  STRIP \
  RANLIB \
  CC \
-@@ -15578,12 +16248,14 @@ lt_cv_sys_global_symbol_pipe \
+@@ -15863,12 +16533,14 @@ lt_cv_sys_global_symbol_pipe \
  lt_cv_sys_global_symbol_to_cdecl \
  lt_cv_sys_global_symbol_to_c_name_address \
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
@@ -3337,7 +3368,7 @@
  DSYMUTIL \
  NMEDIT \
  LIPO \
-@@ -15599,7 +16271,6 @@ no_undefined_flag \
+@@ -15884,7 +16556,6 @@ no_undefined_flag \
  hardcode_libdir_flag_spec \
  hardcode_libdir_flag_spec_ld \
  hardcode_libdir_separator \
@@ -3345,7 +3376,7 @@
  exclude_expsyms \
  include_expsyms \
  file_list_spec \
-@@ -15635,6 +16306,7 @@ module_cmds \
+@@ -15920,6 +16591,7 @@ module_cmds \
  module_expsym_cmds \
  export_symbols_cmds \
  prelink_cmds \
@@ -3353,7 +3384,7 @@
  postinstall_cmds \
  postuninstall_cmds \
  finish_cmds \
-@@ -16392,7 +17064,8 @@ $as_echo X"$file" |
+@@ -16686,7 +17358,8 @@ $as_echo X"$file" |
  # NOTE: Changes made to this file will be lost: look at ltmain.sh.
  #
  #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
@@ -3363,7 +3394,7 @@
  #   Written by Gordon Matzigkeit, 1996
  #
  #   This file is part of GNU Libtool.
-@@ -16495,19 +17168,42 @@ SP2NL=$lt_lt_SP2NL
+@@ -16789,19 +17462,42 @@ SP2NL=$lt_lt_SP2NL
  # turn newlines into spaces.
  NL2SP=$lt_lt_NL2SP
  
@@ -3407,7 +3438,7 @@
  # A symbol stripping program.
  STRIP=$lt_STRIP
  
-@@ -16537,6 +17233,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
+@@ -16831,6 +17527,12 @@ global_symbol_to_c_name_address=$lt_lt_c
  # Transform the output of nm in a C name address pair when lib prefix is needed.
  global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
  
@@ -3420,7 +3451,7 @@
  # The name of the directory that contains temporary libtool files.
  objdir=$objdir
  
-@@ -16546,6 +17248,9 @@ MAGIC_CMD=$MAGIC_CMD
+@@ -16840,6 +17542,9 @@ MAGIC_CMD=$MAGIC_CMD
  # Must we lock files when doing compilation?
  need_locks=$lt_need_locks
  
@@ -3430,7 +3461,7 @@
  # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
  DSYMUTIL=$lt_DSYMUTIL
  
-@@ -16660,12 +17365,12 @@ with_gcc=$GCC
+@@ -16954,12 +17659,12 @@ with_gcc=$GCC
  # Compiler flag to turn off builtin functions.
  no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
  
@@ -3446,7 +3477,7 @@
  # Compiler flag to prevent dynamic linking.
  link_static_flag=$lt_lt_prog_compiler_static
  
-@@ -16752,9 +17457,6 @@ inherit_rpath=$inherit_rpath
+@@ -17046,9 +17751,6 @@ inherit_rpath=$inherit_rpath
  # Whether libtool must link a program against all its dependency libraries.
  link_all_deplibs=$link_all_deplibs
  
@@ -3456,7 +3487,7 @@
  # Set to "yes" if exported symbols are required.
  always_export_symbols=$always_export_symbols
  
-@@ -16770,6 +17472,9 @@ include_expsyms=$lt_include_expsyms
+@@ -17064,6 +17766,9 @@ include_expsyms=$lt_include_expsyms
  # Commands necessary for linking programs (against libraries) with templates.
  prelink_cmds=$lt_prelink_cmds
  
@@ -3466,7 +3497,7 @@
  # Specify filename containing input files.
  file_list_spec=$lt_file_list_spec
  
-@@ -16802,210 +17507,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
+@@ -17096,210 +17801,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
    # if finds mixed CR/LF and LF-only lines.  Since sed operates in
    # text mode, it properly converts lines to CR/LF.  This bash problem
    # is reportedly fixed, but why not run on old versions too?
@@ -3668,15 +3699,9 @@
 -_LT_EOF
 -    ;;
 -  esac
--
--
--  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
--    || (rm -f "$cfgfile"; exit 1)
--
--  mv -f "$cfgfile" "$ofile" ||
 +  sed '$q' "$ltmain" >> "$cfgfile" \
 +     || (rm -f "$cfgfile"; exit 1)
-+
+ 
 +  if test x"$xsi_shell" = xyes; then
 +  sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
 +func_dirname ()\
@@ -3834,17 +3859,20 @@
 +  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
 +$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
 +fi
-+
-+
+ 
+-  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
+-    || (rm -f "$cfgfile"; exit 1)
+ 
+-  mv -f "$cfgfile" "$ofile" ||
 +   mv -f "$cfgfile" "$ofile" ||
      (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
    chmod +x "$ofile"
  
-diff --git a/gas/configure b/gas/configure
-index fbac8f44d5..a40ac2144f 100755
---- a/gas/configure
-+++ b/gas/configure
-@@ -650,8 +650,11 @@ OTOOL
+Index: git/gas/configure
+===================================================================
+--- git.orig/gas/configure
++++ git/gas/configure
+@@ -681,8 +681,11 @@ OTOOL
  LIPO
  NMEDIT
  DSYMUTIL
@@ -3856,7 +3884,7 @@
  OBJDUMP
  LN_S
  NM
-@@ -763,6 +766,7 @@ enable_static
+@@ -799,6 +802,7 @@ enable_static
  with_pic
  enable_fast_install
  with_gnu_ld
@@ -3864,7 +3892,16 @@
  enable_libtool_lock
  enable_plugins
  enable_largefile
-@@ -4921,8 +4925,8 @@ esac
+@@ -1482,6 +1486,8 @@ Optional Packages:
+   --with-pic              try to use only PIC/non-PIC objects [default=use
+                           both]
+   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
++  --with-libtool-sysroot=DIR Search for dependent libraries within DIR
++                        (or the compiler's sysroot if not specified).
+   --with-cpu=CPU          default cpu variant is CPU (currently only supported
+                           on ARC)
+   --with-system-zlib      use installed libz
+@@ -5269,8 +5275,8 @@ esac
  
  
  
@@ -3875,7 +3912,7 @@
  
  
  
-@@ -4962,7 +4966,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
+@@ -5310,7 +5316,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
  $as_echo_n "checking how to print strings... " >&6; }
  # Test print first, because it will be a builtin if present.
@@ -3884,7 +3921,7 @@
     test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
    ECHO='print -r --'
  elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
-@@ -5648,8 +5652,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
+@@ -5996,8 +6002,8 @@ $as_echo_n "checking whether the shell u
  # Try some XSI features
  xsi_shell=no
  ( _lt_dummy="a/b/c"
@@ -3895,13 +3932,13 @@
      && eval 'test $(( 1 + 1 )) -eq 2 \
      && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
    && xsi_shell=yes
-@@ -5698,6 +5702,80 @@ esac
+@@ -6046,6 +6052,80 @@ esac
  
  
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
 +$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
-+if test "${lt_cv_to_host_file_cmd+set}" = set; then :
++if ${lt_cv_to_host_file_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  case $host in
@@ -3948,7 +3985,7 @@
 +
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
 +$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
-+if test "${lt_cv_to_tool_file_cmd+set}" = set; then :
++if ${lt_cv_to_tool_file_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  #assume ordinary cross tools, or native build.
@@ -3975,8 +4012,8 @@
 +
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
  $as_echo_n "checking for $LD option to reload object files... " >&6; }
- if test "${lt_cv_ld_reload_flag+set}" = set; then :
-@@ -5714,6 +5792,11 @@ case $reload_flag in
+ if ${lt_cv_ld_reload_flag+:} false; then :
+@@ -6062,6 +6142,11 @@ case $reload_flag in
  esac
  reload_cmds='$LD$reload_flag -o $output$reload_objs'
  case $host_os in
@@ -3988,7 +4025,7 @@
    darwin*)
      if test "$GCC" = yes; then
        reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
-@@ -5882,7 +5965,8 @@ mingw* | pw32*)
+@@ -6230,7 +6315,8 @@ mingw* | pw32*)
      lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
      lt_cv_file_magic_cmd='func_win32_libid'
    else
@@ -3998,7 +4035,7 @@
      lt_cv_file_magic_cmd='$OBJDUMP -f'
    fi
    ;;
-@@ -6036,6 +6120,21 @@ esac
+@@ -6384,6 +6470,21 @@ esac
  fi
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
  $as_echo "$lt_cv_deplibs_check_method" >&6; }
@@ -4020,7 +4057,7 @@
  file_magic_cmd=$lt_cv_file_magic_cmd
  deplibs_check_method=$lt_cv_deplibs_check_method
  test -z "$deplibs_check_method" && deplibs_check_method=unknown
-@@ -6051,9 +6150,162 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
+@@ -6399,9 +6500,162 @@ test -z "$deplibs_check_method" && depli
  
  
  
@@ -4034,12 +4071,14 @@
 +
 +
 +
-+if test -n "$ac_tool_prefix"; then
+ if test -n "$ac_tool_prefix"; then
+-  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
+-set dummy ${ac_tool_prefix}ar; ac_word=$2
 +  # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
 +set dummy ${ac_tool_prefix}dlltool; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
++if ${ac_cv_prog_DLLTOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$DLLTOOL"; then
@@ -4051,7 +4090,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -4079,7 +4118,7 @@
 +set dummy dlltool; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
++if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$ac_ct_DLLTOOL"; then
@@ -4091,7 +4130,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_ac_ct_DLLTOOL="dlltool"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -4139,7 +4178,7 @@
 +
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
 +$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
-+if test "${lt_cv_sharedlib_from_linklib_cmd+set}" = set; then :
++if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_sharedlib_from_linklib_cmd='unknown'
@@ -4175,26 +4214,24 @@
 +
 +
 +
- if test -n "$ac_tool_prefix"; then
--  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
--set dummy ${ac_tool_prefix}ar; ac_word=$2
++if test -n "$ac_tool_prefix"; then
 +  for ac_prog in ar
 +  do
 +    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
 +set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
- if test "${ac_cv_prog_AR+set}" = set; then :
-@@ -6069,7 +6321,7 @@ do
+ if ${ac_cv_prog_AR+:} false; then :
+@@ -6417,7 +6671,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
-   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 -    ac_cv_prog_AR="${ac_tool_prefix}ar"
 +    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6089,11 +6341,15 @@ $as_echo "no" >&6; }
+@@ -6437,11 +6691,15 @@ $as_echo "no" >&6; }
  fi
  
  
@@ -4212,17 +4249,17 @@
 +set dummy $ac_prog; ac_word=$2
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
- if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
-@@ -6109,7 +6365,7 @@ do
+ if ${ac_cv_prog_ac_ct_AR+:} false; then :
+@@ -6457,7 +6715,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
-   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 -    ac_cv_prog_ac_ct_AR="ar"
 +    ac_cv_prog_ac_ct_AR="$ac_prog"
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6128,6 +6384,10 @@ else
+@@ -6476,6 +6734,10 @@ else
  $as_echo "no" >&6; }
  fi
  
@@ -4233,7 +4270,7 @@
    if test "x$ac_ct_AR" = x; then
      AR="false"
    else
-@@ -6139,12 +6399,10 @@ ac_tool_warned=yes ;;
+@@ -6487,12 +6749,10 @@ ac_tool_warned=yes ;;
  esac
      AR=$ac_ct_AR
    fi
@@ -4248,13 +4285,13 @@
  
  
  
-@@ -6156,6 +6414,64 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
+@@ -6504,6 +6764,64 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
  
  
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
 +$as_echo_n "checking for archiver @FILE support... " >&6; }
-+if test "${lt_cv_ar_at_file+set}" = set; then :
++if ${lt_cv_ar_at_file+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_ar_at_file=no
@@ -4313,7 +4350,7 @@
  if test -n "$ac_tool_prefix"; then
    # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
  set dummy ${ac_tool_prefix}strip; ac_word=$2
-@@ -6490,8 +6806,8 @@ esac
+@@ -6838,8 +7156,8 @@ esac
  lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
  
  # Transform an extracted symbol line into symbol name and symbol address
@@ -4324,7 +4361,7 @@
  
  # Handle CRLF in mingw tool chain
  opt_cr=
-@@ -6527,6 +6843,7 @@ for ac_symprfx in "" "_"; do
+@@ -6875,6 +7193,7 @@ for ac_symprfx in "" "_"; do
    else
      lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[	 ]\($symcode$symcode*\)[	 ][	 ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
    fi
@@ -4332,7 +4369,7 @@
  
    # Check to see that the pipe works correctly.
    pipe_works=no
-@@ -6568,6 +6885,18 @@ _LT_EOF
+@@ -6916,6 +7235,18 @@ _LT_EOF
        if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
  	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
  	  cat <<_LT_EOF > conftest.$ac_ext
@@ -4351,7 +4388,7 @@
  #ifdef __cplusplus
  extern "C" {
  #endif
-@@ -6579,7 +6908,7 @@ _LT_EOF
+@@ -6927,7 +7258,7 @@ _LT_EOF
  	  cat <<_LT_EOF >> conftest.$ac_ext
  
  /* The mapping between symbol names and symbols.  */
@@ -4360,7 +4397,7 @@
    const char *name;
    void       *address;
  }
-@@ -6605,8 +6934,8 @@ static const void *lt_preloaded_setup() {
+@@ -6953,8 +7284,8 @@ static const void *lt_preloaded_setup()
  _LT_EOF
  	  # Now try linking the two files.
  	  mv conftest.$ac_objext conftstm.$ac_objext
@@ -4371,7 +4408,7 @@
  	  LIBS="conftstm.$ac_objext"
  	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
  	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
-@@ -6616,8 +6945,8 @@ _LT_EOF
+@@ -6964,8 +7295,8 @@ _LT_EOF
    test $ac_status = 0; } && test -s conftest${ac_exeext}; then
  	    pipe_works=yes
  	  fi
@@ -4382,7 +4419,7 @@
  	else
  	  echo "cannot find nm_test_func in $nlist" >&5
  	fi
-@@ -6654,6 +6983,21 @@ else
+@@ -7002,6 +7333,19 @@ else
  $as_echo "ok" >&6; }
  fi
  
@@ -4399,17 +4436,13 @@
 +
 +
 +
-+
-+
  
  
  
-@@ -6669,6 +7013,40 @@ fi
+@@ -7022,6 +7366,42 @@ fi
  
  
  
-+
-+
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
 +$as_echo_n "checking for sysroot... " >&6; }
 +
@@ -4436,16 +4469,20 @@
 + *)
 +   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libtool_sysroot}" >&5
 +$as_echo "${with_libtool_sysroot}" >&6; }
-+   as_fn_error "The sysroot must be an absolute path." "$LINENO" 5
++   as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
 +   ;;
 +esac
 +
 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
 +$as_echo "${lt_sysroot:-no}" >&6; }
++
++
++
++
  
- 
- 
-@@ -6881,6 +7259,123 @@ esac
+ # Check whether --enable-libtool-lock was given.
+ if test "${enable_libtool_lock+set}" = set; then :
+@@ -7229,6 +7609,123 @@ esac
  
  need_locks="$enable_libtool_lock"
  
@@ -4454,7 +4491,7 @@
 +set dummy ${ac_tool_prefix}mt; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_MANIFEST_TOOL+set}" = set; then :
++if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$MANIFEST_TOOL"; then
@@ -4466,7 +4503,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -4494,7 +4531,7 @@
 +set dummy mt; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_ac_ct_MANIFEST_TOOL+set}" = set; then :
++if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$ac_ct_MANIFEST_TOOL"; then
@@ -4506,7 +4543,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -4544,7 +4581,7 @@
 +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
 +$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
-+if test "${lt_cv_path_mainfest_tool+set}" = set; then :
++if ${lt_cv_path_mainfest_tool+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_path_mainfest_tool=no
@@ -4569,7 +4606,7 @@
  
    case $host_os in
      rhapsody* | darwin*)
-@@ -7444,6 +7939,8 @@ _LT_EOF
+@@ -7792,6 +8289,8 @@ _LT_EOF
        $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
        echo "$AR cru libconftest.a conftest.o" >&5
        $AR cru libconftest.a conftest.o 2>&5
@@ -4578,7 +4615,7 @@
        cat > conftest.c << _LT_EOF
  int main() { return 0;}
  _LT_EOF
-@@ -7639,7 +8136,8 @@ fi
+@@ -7987,7 +8486,8 @@ fi
  LIBTOOL_DEPS="$ltmain"
  
  # Always use our own libtool.
@@ -4588,7 +4625,7 @@
  
  
  
-@@ -7728,7 +8226,7 @@ aix3*)
+@@ -8076,7 +8576,7 @@ aix3*)
  esac
  
  # Global variables:
@@ -4597,7 +4634,7 @@
  can_build_shared=yes
  
  # All known linkers require a `.a' archive for static linking (except MSVC,
-@@ -8026,8 +8524,6 @@ fi
+@@ -8374,8 +8874,6 @@ fi
  lt_prog_compiler_pic=
  lt_prog_compiler_static=
  
@@ -4606,7 +4643,7 @@
  
    if test "$GCC" = yes; then
      lt_prog_compiler_wl='-Wl,'
-@@ -8193,6 +8689,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8541,6 +9039,12 @@ $as_echo_n "checking for $compiler optio
  	lt_prog_compiler_pic='--shared'
  	lt_prog_compiler_static='--static'
  	;;
@@ -4619,7 +4656,7 @@
        pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
          # Portland Group compilers (*not* the Pentium gcc compiler,
  	# which looks to be a dead project)
-@@ -8255,7 +8757,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8603,7 +9107,7 @@ $as_echo_n "checking for $compiler optio
        lt_prog_compiler_pic='-KPIC'
        lt_prog_compiler_static='-Bstatic'
        case $cc_basename in
@@ -4628,7 +4665,7 @@
  	lt_prog_compiler_wl='-Qoption ld ';;
        *)
  	lt_prog_compiler_wl='-Wl,';;
-@@ -8312,13 +8814,17 @@ case $host_os in
+@@ -8660,13 +9164,17 @@ case $host_os in
      lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
      ;;
  esac
@@ -4641,7 +4678,7 @@
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-+if test "${lt_cv_prog_compiler_pic+set}" = set; then :
++if ${lt_cv_prog_compiler_pic+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
@@ -4652,7 +4689,7 @@
  
  #
  # Check to make sure the PIC flag actually works.
-@@ -8379,6 +8885,11 @@ fi
+@@ -8727,6 +9235,11 @@ fi
  
  
  
@@ -4664,7 +4701,7 @@
  #
  # Check to make sure the static flag actually works.
  #
-@@ -8729,7 +9240,8 @@ _LT_EOF
+@@ -9077,7 +9590,8 @@ _LT_EOF
        allow_undefined_flag=unsupported
        always_export_symbols=no
        enable_shared_with_static_runtimes=yes
@@ -4674,7 +4711,7 @@
  
        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
          archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-@@ -8828,12 +9340,12 @@ _LT_EOF
+@@ -9176,12 +9690,12 @@ _LT_EOF
  	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
  	  hardcode_libdir_flag_spec=
  	  hardcode_libdir_flag_spec_ld='-rpath $libdir'
@@ -4689,7 +4726,7 @@
  	  fi
  	  ;;
  	esac
-@@ -8847,8 +9359,8 @@ _LT_EOF
+@@ -9195,8 +9709,8 @@ _LT_EOF
  	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
  	wlarc=
        else
@@ -4700,7 +4737,7 @@
        fi
        ;;
  
-@@ -8866,8 +9378,8 @@ _LT_EOF
+@@ -9214,8 +9728,8 @@ _LT_EOF
  
  _LT_EOF
        elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -4711,7 +4748,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -8913,8 +9425,8 @@ _LT_EOF
+@@ -9261,8 +9775,8 @@ _LT_EOF
  
      *)
        if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -4722,7 +4759,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9044,7 +9556,13 @@ _LT_EOF
+@@ -9392,7 +9906,13 @@ _LT_EOF
  	allow_undefined_flag='-berok'
          # Determine the default libpath from the value encoded in an
          # empty executable.
@@ -4730,14 +4767,14 @@
 +        if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  if ${lt_cv_aix_libpath_+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  /* end confdefs.h.  */
  
  int
-@@ -9057,22 +9575,29 @@ main ()
+@@ -9405,22 +9925,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -4780,7 +4817,7 @@
  
          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
          archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
-@@ -9084,7 +9609,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9432,7 +9959,13 @@ if test -z "$aix_libpath"; then aix_libp
  	else
  	 # Determine the default libpath from the value encoded in an
  	 # empty executable.
@@ -4788,14 +4825,14 @@
 +	 if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  if ${lt_cv_aix_libpath_+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  /* end confdefs.h.  */
  
  int
-@@ -9097,22 +9628,29 @@ main ()
+@@ -9445,22 +9978,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -4838,7 +4875,7 @@
  
  	 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
  	  # Warning - without using the other run time loading flags,
-@@ -9157,20 +9695,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9505,20 +10045,63 @@ if test -z "$aix_libpath"; then aix_libp
        # Microsoft Visual C++.
        # hardcode_libdir_flag_spec is actually meaningless, as there is
        # no search path for DLLs.
@@ -4916,7 +4953,7 @@
        ;;
  
      darwin* | rhapsody*)
-@@ -9231,7 +9812,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9579,7 +10162,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
      freebsd* | dragonfly*)
@@ -4925,7 +4962,7 @@
        hardcode_libdir_flag_spec='-R$libdir'
        hardcode_direct=yes
        hardcode_shlibpath_var=no
-@@ -9239,7 +9820,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9587,7 +10170,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      hpux9*)
        if test "$GCC" = yes; then
@@ -4934,7 +4971,7 @@
        else
  	archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
        fi
-@@ -9255,7 +9836,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9603,7 +10186,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      hpux10*)
        if test "$GCC" = yes && test "$with_gnu_ld" = no; then
@@ -4943,7 +4980,7 @@
        else
  	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
        fi
-@@ -9279,10 +9860,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9627,10 +10210,10 @@ if test -z "$aix_libpath"; then aix_libp
  	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  	  ;;
  	ia64*)
@@ -4956,7 +4993,7 @@
  	  ;;
  	esac
        else
-@@ -9361,23 +9942,36 @@ fi
+@@ -9709,23 +10292,36 @@ fi
  
      irix5* | irix6* | nonstopux*)
        if test "$GCC" = yes; then
@@ -4971,7 +5008,7 @@
 +	# This should be the same for all languages, so no per-tag cache variable.
 +	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
 +$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
-+if test "${lt_cv_irix_exported_symbol+set}" = set; then :
++if ${lt_cv_irix_exported_symbol+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  save_LDFLAGS="$LDFLAGS"
@@ -5001,7 +5038,7 @@
        else
  	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
  	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
-@@ -9462,7 +10056,7 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -9810,7 +10406,7 @@ rm -f core conftest.err conftest.$ac_obj
      osf4* | osf5*)	# as osf3* with the addition of -msym flag
        if test "$GCC" = yes; then
  	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
@@ -5010,7 +5047,7 @@
  	hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
        else
  	allow_undefined_flag=' -expect_unresolved \*'
-@@ -9481,9 +10075,9 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -9829,9 +10425,9 @@ rm -f core conftest.err conftest.$ac_obj
        no_undefined_flag=' -z defs'
        if test "$GCC" = yes; then
  	wlarc='${wl}'
@@ -5022,7 +5059,7 @@
        else
  	case `$CC -V 2>&1` in
  	*"Compilers 5.0"*)
-@@ -10059,8 +10653,9 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10407,8 +11003,9 @@ cygwin* | mingw* | pw32* | cegcc*)
    need_version=no
    need_lib_prefix=no
  
@@ -5034,7 +5071,7 @@
      library_names_spec='$libname.dll.a'
      # DLL is installed to $(libdir)/../bin by postinstall_cmds
      postinstall_cmds='base_file=`basename \${file}`~
-@@ -10093,13 +10688,71 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10441,13 +11038,71 @@ cygwin* | mingw* | pw32* | cegcc*)
        library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
        ;;
      esac
@@ -5107,7 +5144,7 @@
    # FIXME: first we should search . and the directory the executable is in
    shlibpath_var=PATH
    ;;
-@@ -10191,7 +10844,7 @@ haiku*)
+@@ -10539,7 +11194,7 @@ haiku*)
    soname_spec='${libname}${release}${shared_ext}$major'
    shlibpath_var=LIBRARY_PATH
    shlibpath_overrides_runpath=yes
@@ -5116,7 +5153,16 @@
    hardcode_into_libs=yes
    ;;
  
-@@ -11031,10 +11684,10 @@ else
+@@ -11335,7 +11990,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11338 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11379,10 +12034,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -5129,7 +5175,16 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -11137,10 +11790,10 @@ else
+@@ -11441,7 +12096,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11444 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11485,10 +12140,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -5142,7 +5197,7 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -15437,13 +16090,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
+@@ -15803,13 +16458,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_
  lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
  lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
  lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
@@ -5163,7 +5218,7 @@
  STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
  RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
  old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-@@ -15458,14 +16118,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
+@@ -15824,14 +16486,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$l
  lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
@@ -5182,7 +5237,7 @@
  DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
  NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
  LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-@@ -15498,12 +16161,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
+@@ -15864,12 +16529,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcod
  hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
  inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
  link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
@@ -5196,7 +5251,7 @@
  file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
  variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
  need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-@@ -15558,8 +16221,13 @@ reload_flag \
+@@ -15924,8 +16589,13 @@ reload_flag \
  OBJDUMP \
  deplibs_check_method \
  file_magic_cmd \
@@ -5210,7 +5265,7 @@
  STRIP \
  RANLIB \
  CC \
-@@ -15569,12 +16237,14 @@ lt_cv_sys_global_symbol_pipe \
+@@ -15935,12 +16605,14 @@ lt_cv_sys_global_symbol_pipe \
  lt_cv_sys_global_symbol_to_cdecl \
  lt_cv_sys_global_symbol_to_c_name_address \
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
@@ -5226,7 +5281,7 @@
  DSYMUTIL \
  NMEDIT \
  LIPO \
-@@ -15590,7 +16260,6 @@ no_undefined_flag \
+@@ -15956,7 +16628,6 @@ no_undefined_flag \
  hardcode_libdir_flag_spec \
  hardcode_libdir_flag_spec_ld \
  hardcode_libdir_separator \
@@ -5234,7 +5289,7 @@
  exclude_expsyms \
  include_expsyms \
  file_list_spec \
-@@ -15626,6 +16295,7 @@ module_cmds \
+@@ -15992,6 +16663,7 @@ module_cmds \
  module_expsym_cmds \
  export_symbols_cmds \
  prelink_cmds \
@@ -5242,7 +5297,7 @@
  postinstall_cmds \
  postuninstall_cmds \
  finish_cmds \
-@@ -16390,7 +17060,8 @@ $as_echo X"$file" |
+@@ -16765,7 +17437,8 @@ $as_echo X"$file" |
  # NOTE: Changes made to this file will be lost: look at ltmain.sh.
  #
  #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
@@ -5252,7 +5307,7 @@
  #   Written by Gordon Matzigkeit, 1996
  #
  #   This file is part of GNU Libtool.
-@@ -16493,19 +17164,42 @@ SP2NL=$lt_lt_SP2NL
+@@ -16868,19 +17541,42 @@ SP2NL=$lt_lt_SP2NL
  # turn newlines into spaces.
  NL2SP=$lt_lt_NL2SP
  
@@ -5296,7 +5351,7 @@
  # A symbol stripping program.
  STRIP=$lt_STRIP
  
-@@ -16535,6 +17229,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
+@@ -16910,6 +17606,12 @@ global_symbol_to_c_name_address=$lt_lt_c
  # Transform the output of nm in a C name address pair when lib prefix is needed.
  global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
  
@@ -5309,7 +5364,7 @@
  # The name of the directory that contains temporary libtool files.
  objdir=$objdir
  
-@@ -16544,6 +17244,9 @@ MAGIC_CMD=$MAGIC_CMD
+@@ -16919,6 +17621,9 @@ MAGIC_CMD=$MAGIC_CMD
  # Must we lock files when doing compilation?
  need_locks=$lt_need_locks
  
@@ -5319,7 +5374,7 @@
  # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
  DSYMUTIL=$lt_DSYMUTIL
  
-@@ -16658,12 +17361,12 @@ with_gcc=$GCC
+@@ -17033,12 +17738,12 @@ with_gcc=$GCC
  # Compiler flag to turn off builtin functions.
  no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
  
@@ -5335,7 +5390,7 @@
  # Compiler flag to prevent dynamic linking.
  link_static_flag=$lt_lt_prog_compiler_static
  
-@@ -16750,9 +17453,6 @@ inherit_rpath=$inherit_rpath
+@@ -17125,9 +17830,6 @@ inherit_rpath=$inherit_rpath
  # Whether libtool must link a program against all its dependency libraries.
  link_all_deplibs=$link_all_deplibs
  
@@ -5345,7 +5400,7 @@
  # Set to "yes" if exported symbols are required.
  always_export_symbols=$always_export_symbols
  
-@@ -16768,6 +17468,9 @@ include_expsyms=$lt_include_expsyms
+@@ -17143,6 +17845,9 @@ include_expsyms=$lt_include_expsyms
  # Commands necessary for linking programs (against libraries) with templates.
  prelink_cmds=$lt_prelink_cmds
  
@@ -5355,7 +5410,7 @@
  # Specify filename containing input files.
  file_list_spec=$lt_file_list_spec
  
-@@ -16800,210 +17503,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
+@@ -17175,210 +17880,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
    # if finds mixed CR/LF and LF-only lines.  Since sed operates in
    # text mode, it properly converts lines to CR/LF.  This bash problem
    # is reportedly fixed, but why not run on old versions too?
@@ -5557,15 +5612,9 @@
 -_LT_EOF
 -    ;;
 -  esac
--
--
--  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
--    || (rm -f "$cfgfile"; exit 1)
--
--  mv -f "$cfgfile" "$ofile" ||
 +  sed '$q' "$ltmain" >> "$cfgfile" \
 +     || (rm -f "$cfgfile"; exit 1)
-+
+ 
 +  if test x"$xsi_shell" = xyes; then
 +  sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
 +func_dirname ()\
@@ -5723,17 +5772,20 @@
 +  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
 +$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
 +fi
-+
-+
+ 
+-  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
+-    || (rm -f "$cfgfile"; exit 1)
+ 
+-  mv -f "$cfgfile" "$ofile" ||
 +   mv -f "$cfgfile" "$ofile" ||
      (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
    chmod +x "$ofile"
  
-diff --git a/gprof/configure b/gprof/configure
-index 6b43bf2b18..245ee48bc3 100755
---- a/gprof/configure
-+++ b/gprof/configure
-@@ -631,8 +631,11 @@ OTOOL
+Index: git/gprof/configure
+===================================================================
+--- git.orig/gprof/configure
++++ git/gprof/configure
+@@ -662,8 +662,11 @@ OTOOL
  LIPO
  NMEDIT
  DSYMUTIL
@@ -5745,7 +5797,7 @@
  OBJDUMP
  LN_S
  NM
-@@ -744,6 +747,7 @@ enable_static
+@@ -780,6 +783,7 @@ enable_static
  with_pic
  enable_fast_install
  with_gnu_ld
@@ -5753,7 +5805,7 @@
  enable_libtool_lock
  enable_plugins
  enable_largefile
-@@ -1402,6 +1406,8 @@ Optional Packages:
+@@ -1442,6 +1446,8 @@ Optional Packages:
    --with-pic              try to use only PIC/non-PIC objects [default=use
                            both]
    --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
@@ -5762,7 +5814,7 @@
  
  Some influential environment variables:
    CC          C compiler command
-@@ -4836,8 +4842,8 @@ esac
+@@ -5124,8 +5130,8 @@ esac
  
  
  
@@ -5773,7 +5825,7 @@
  
  
  
-@@ -4877,7 +4883,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
+@@ -5165,7 +5171,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
  $as_echo_n "checking how to print strings... " >&6; }
  # Test print first, because it will be a builtin if present.
@@ -5782,7 +5834,7 @@
     test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
    ECHO='print -r --'
  elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
-@@ -5563,8 +5569,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
+@@ -5851,8 +5857,8 @@ $as_echo_n "checking whether the shell u
  # Try some XSI features
  xsi_shell=no
  ( _lt_dummy="a/b/c"
@@ -5793,13 +5845,13 @@
      && eval 'test $(( 1 + 1 )) -eq 2 \
      && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
    && xsi_shell=yes
-@@ -5613,6 +5619,80 @@ esac
+@@ -5901,6 +5907,80 @@ esac
  
  
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
 +$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
-+if test "${lt_cv_to_host_file_cmd+set}" = set; then :
++if ${lt_cv_to_host_file_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  case $host in
@@ -5846,7 +5898,7 @@
 +
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
 +$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
-+if test "${lt_cv_to_tool_file_cmd+set}" = set; then :
++if ${lt_cv_to_tool_file_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  #assume ordinary cross tools, or native build.
@@ -5873,8 +5925,8 @@
 +
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
  $as_echo_n "checking for $LD option to reload object files... " >&6; }
- if test "${lt_cv_ld_reload_flag+set}" = set; then :
-@@ -5629,6 +5709,11 @@ case $reload_flag in
+ if ${lt_cv_ld_reload_flag+:} false; then :
+@@ -5917,6 +5997,11 @@ case $reload_flag in
  esac
  reload_cmds='$LD$reload_flag -o $output$reload_objs'
  case $host_os in
@@ -5886,7 +5938,7 @@
    darwin*)
      if test "$GCC" = yes; then
        reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
-@@ -5797,7 +5882,8 @@ mingw* | pw32*)
+@@ -6085,7 +6170,8 @@ mingw* | pw32*)
      lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
      lt_cv_file_magic_cmd='func_win32_libid'
    else
@@ -5896,7 +5948,7 @@
      lt_cv_file_magic_cmd='$OBJDUMP -f'
    fi
    ;;
-@@ -5874,11 +5960,6 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu)
+@@ -6162,11 +6248,6 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu)
    lt_cv_deplibs_check_method=pass_all
    ;;
  
@@ -5908,7 +5960,7 @@
  netbsd*)
    if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
      lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
-@@ -5956,6 +6037,21 @@ esac
+@@ -6244,6 +6325,21 @@ esac
  fi
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
  $as_echo "$lt_cv_deplibs_check_method" >&6; }
@@ -5930,7 +5982,7 @@
  file_magic_cmd=$lt_cv_file_magic_cmd
  deplibs_check_method=$lt_cv_deplibs_check_method
  test -z "$deplibs_check_method" && deplibs_check_method=unknown
-@@ -5971,9 +6067,162 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
+@@ -6259,9 +6355,162 @@ test -z "$deplibs_check_method" && depli
  
  
  
@@ -5944,12 +5996,14 @@
 +
 +
 +
-+if test -n "$ac_tool_prefix"; then
+ if test -n "$ac_tool_prefix"; then
+-  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
+-set dummy ${ac_tool_prefix}ar; ac_word=$2
 +  # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
 +set dummy ${ac_tool_prefix}dlltool; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
++if ${ac_cv_prog_DLLTOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$DLLTOOL"; then
@@ -5961,7 +6015,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -5989,7 +6043,7 @@
 +set dummy dlltool; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
++if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$ac_ct_DLLTOOL"; then
@@ -6001,7 +6055,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_ac_ct_DLLTOOL="dlltool"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -6049,7 +6103,7 @@
 +
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
 +$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
-+if test "${lt_cv_sharedlib_from_linklib_cmd+set}" = set; then :
++if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_sharedlib_from_linklib_cmd='unknown'
@@ -6085,26 +6139,24 @@
 +
 +
 +
- if test -n "$ac_tool_prefix"; then
--  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
--set dummy ${ac_tool_prefix}ar; ac_word=$2
++if test -n "$ac_tool_prefix"; then
 +  for ac_prog in ar
 +  do
 +    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
 +set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
- if test "${ac_cv_prog_AR+set}" = set; then :
-@@ -5989,7 +6238,7 @@ do
+ if ${ac_cv_prog_AR+:} false; then :
+@@ -6277,7 +6526,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
-   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 -    ac_cv_prog_AR="${ac_tool_prefix}ar"
 +    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6009,11 +6258,15 @@ $as_echo "no" >&6; }
+@@ -6297,11 +6546,15 @@ $as_echo "no" >&6; }
  fi
  
  
@@ -6122,17 +6174,17 @@
 +set dummy $ac_prog; ac_word=$2
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
- if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
-@@ -6029,7 +6282,7 @@ do
+ if ${ac_cv_prog_ac_ct_AR+:} false; then :
+@@ -6317,7 +6570,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
-   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 -    ac_cv_prog_ac_ct_AR="ar"
 +    ac_cv_prog_ac_ct_AR="$ac_prog"
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6048,6 +6301,10 @@ else
+@@ -6336,6 +6589,10 @@ else
  $as_echo "no" >&6; }
  fi
  
@@ -6143,7 +6195,7 @@
    if test "x$ac_ct_AR" = x; then
      AR="false"
    else
-@@ -6059,12 +6316,10 @@ ac_tool_warned=yes ;;
+@@ -6347,16 +6604,72 @@ ac_tool_warned=yes ;;
  esac
      AR=$ac_ct_AR
    fi
@@ -6155,16 +6207,20 @@
 -test -z "$AR_FLAGS" && AR_FLAGS=cru
 +: ${AR=ar}
 +: ${AR_FLAGS=cru}
- 
- 
- 
-@@ -6076,6 +6331,64 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
- 
- 
- 
++
++
++
++
++
++
++
++
++
++
++
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
 +$as_echo_n "checking for archiver @FILE support... " >&6; }
-+if test "${lt_cv_ar_at_file+set}" = set; then :
++if ${lt_cv_ar_at_file+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_ar_at_file=no
@@ -6174,7 +6230,7 @@
 +int
 +main ()
 +{
-+
+ 
 +  ;
 +  return 0;
 +}
@@ -6200,30 +6256,23 @@
 +        fi
 +      fi
 +      rm -f conftest.* libconftest.a
-+
+ 
 +fi
 +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-+
+ 
 +fi
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
 +$as_echo "$lt_cv_ar_at_file" >&6; }
-+
+ 
 +if test "x$lt_cv_ar_at_file" = xno; then
 +  archiver_list_spec=
 +else
 +  archiver_list_spec=$lt_cv_ar_at_file
 +fi
-+
-+
-+
-+
-+
-+
-+
- if test -n "$ac_tool_prefix"; then
-   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
- set dummy ${ac_tool_prefix}strip; ac_word=$2
-@@ -6410,8 +6723,8 @@ esac
+ 
+ 
+ 
+@@ -6698,8 +7011,8 @@ esac
  lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
  
  # Transform an extracted symbol line into symbol name and symbol address
@@ -6234,7 +6283,7 @@
  
  # Handle CRLF in mingw tool chain
  opt_cr=
-@@ -6447,6 +6760,7 @@ for ac_symprfx in "" "_"; do
+@@ -6735,6 +7048,7 @@ for ac_symprfx in "" "_"; do
    else
      lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[	 ]\($symcode$symcode*\)[	 ][	 ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
    fi
@@ -6242,7 +6291,7 @@
  
    # Check to see that the pipe works correctly.
    pipe_works=no
-@@ -6488,6 +6802,18 @@ _LT_EOF
+@@ -6776,6 +7090,18 @@ _LT_EOF
        if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
  	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
  	  cat <<_LT_EOF > conftest.$ac_ext
@@ -6261,7 +6310,7 @@
  #ifdef __cplusplus
  extern "C" {
  #endif
-@@ -6499,7 +6825,7 @@ _LT_EOF
+@@ -6787,7 +7113,7 @@ _LT_EOF
  	  cat <<_LT_EOF >> conftest.$ac_ext
  
  /* The mapping between symbol names and symbols.  */
@@ -6270,7 +6319,7 @@
    const char *name;
    void       *address;
  }
-@@ -6525,8 +6851,8 @@ static const void *lt_preloaded_setup() {
+@@ -6813,8 +7139,8 @@ static const void *lt_preloaded_setup()
  _LT_EOF
  	  # Now try linking the two files.
  	  mv conftest.$ac_objext conftstm.$ac_objext
@@ -6281,7 +6330,7 @@
  	  LIBS="conftstm.$ac_objext"
  	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
  	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
-@@ -6536,8 +6862,8 @@ _LT_EOF
+@@ -6824,8 +7150,8 @@ _LT_EOF
    test $ac_status = 0; } && test -s conftest${ac_exeext}; then
  	    pipe_works=yes
  	  fi
@@ -6292,7 +6341,7 @@
  	else
  	  echo "cannot find nm_test_func in $nlist" >&5
  	fi
-@@ -6574,6 +6900,18 @@ else
+@@ -6862,6 +7188,17 @@ else
  $as_echo "ok" >&6; }
  fi
  
@@ -6307,19 +6356,14 @@
 +
 +
 +
-+
  
  
  
-@@ -6590,6 +6928,43 @@ fi
+@@ -6883,6 +7220,44 @@ fi
  
  
  
 +
-+
-+
-+
-+
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
 +$as_echo_n "checking for sysroot... " >&6; }
 +
@@ -6346,16 +6390,21 @@
 + *)
 +   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libtool_sysroot}" >&5
 +$as_echo "${with_libtool_sysroot}" >&6; }
-+   as_fn_error "The sysroot must be an absolute path." "$LINENO" 5
++   as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
 +   ;;
 +esac
 +
 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
 +$as_echo "${lt_sysroot:-no}" >&6; }
- 
- 
- 
-@@ -6801,6 +7176,123 @@ esac
++
++
++
++
++
+ # Check whether --enable-libtool-lock was given.
+ if test "${enable_libtool_lock+set}" = set; then :
+   enableval=$enable_libtool_lock;
+@@ -7089,6 +7464,123 @@ esac
  
  need_locks="$enable_libtool_lock"
  
@@ -6364,7 +6413,7 @@
 +set dummy ${ac_tool_prefix}mt; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_MANIFEST_TOOL+set}" = set; then :
++if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$MANIFEST_TOOL"; then
@@ -6376,7 +6425,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -6404,7 +6453,7 @@
 +set dummy mt; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_ac_ct_MANIFEST_TOOL+set}" = set; then :
++if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$ac_ct_MANIFEST_TOOL"; then
@@ -6416,7 +6465,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -6454,7 +6503,7 @@
 +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
 +$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
-+if test "${lt_cv_path_mainfest_tool+set}" = set; then :
++if ${lt_cv_path_mainfest_tool+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_path_mainfest_tool=no
@@ -6479,7 +6528,7 @@
  
    case $host_os in
      rhapsody* | darwin*)
-@@ -7364,6 +7856,8 @@ _LT_EOF
+@@ -7652,6 +8144,8 @@ _LT_EOF
        $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
        echo "$AR cru libconftest.a conftest.o" >&5
        $AR cru libconftest.a conftest.o 2>&5
@@ -6488,7 +6537,7 @@
        cat > conftest.c << _LT_EOF
  int main() { return 0;}
  _LT_EOF
-@@ -7559,7 +8053,8 @@ fi
+@@ -7847,7 +8341,8 @@ fi
  LIBTOOL_DEPS="$ltmain"
  
  # Always use our own libtool.
@@ -6498,7 +6547,7 @@
  
  
  
-@@ -7648,7 +8143,7 @@ aix3*)
+@@ -7936,7 +8431,7 @@ aix3*)
  esac
  
  # Global variables:
@@ -6507,7 +6556,7 @@
  can_build_shared=yes
  
  # All known linkers require a `.a' archive for static linking (except MSVC,
-@@ -7946,8 +8441,6 @@ fi
+@@ -8234,8 +8729,6 @@ fi
  lt_prog_compiler_pic=
  lt_prog_compiler_static=
  
@@ -6516,7 +6565,7 @@
  
    if test "$GCC" = yes; then
      lt_prog_compiler_wl='-Wl,'
-@@ -8113,6 +8606,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8401,6 +8894,12 @@ $as_echo_n "checking for $compiler optio
  	lt_prog_compiler_pic='--shared'
  	lt_prog_compiler_static='--static'
  	;;
@@ -6529,7 +6578,7 @@
        pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
          # Portland Group compilers (*not* the Pentium gcc compiler,
  	# which looks to be a dead project)
-@@ -8175,7 +8674,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8463,7 +8962,7 @@ $as_echo_n "checking for $compiler optio
        lt_prog_compiler_pic='-KPIC'
        lt_prog_compiler_static='-Bstatic'
        case $cc_basename in
@@ -6538,7 +6587,7 @@
  	lt_prog_compiler_wl='-Qoption ld ';;
        *)
  	lt_prog_compiler_wl='-Wl,';;
-@@ -8232,13 +8731,17 @@ case $host_os in
+@@ -8520,13 +9019,17 @@ case $host_os in
      lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
      ;;
  esac
@@ -6551,7 +6600,7 @@
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-+if test "${lt_cv_prog_compiler_pic+set}" = set; then :
++if ${lt_cv_prog_compiler_pic+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
@@ -6562,7 +6611,7 @@
  
  #
  # Check to make sure the PIC flag actually works.
-@@ -8299,6 +8802,11 @@ fi
+@@ -8587,6 +9090,11 @@ fi
  
  
  
@@ -6574,7 +6623,7 @@
  #
  # Check to make sure the static flag actually works.
  #
-@@ -8649,7 +9157,8 @@ _LT_EOF
+@@ -8937,7 +9445,8 @@ _LT_EOF
        allow_undefined_flag=unsupported
        always_export_symbols=no
        enable_shared_with_static_runtimes=yes
@@ -6584,7 +6633,7 @@
  
        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
          archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-@@ -8748,12 +9257,12 @@ _LT_EOF
+@@ -9036,12 +9545,12 @@ _LT_EOF
  	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
  	  hardcode_libdir_flag_spec=
  	  hardcode_libdir_flag_spec_ld='-rpath $libdir'
@@ -6599,7 +6648,7 @@
  	  fi
  	  ;;
  	esac
-@@ -8767,8 +9276,8 @@ _LT_EOF
+@@ -9055,8 +9564,8 @@ _LT_EOF
  	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
  	wlarc=
        else
@@ -6610,7 +6659,7 @@
        fi
        ;;
  
-@@ -8786,8 +9295,8 @@ _LT_EOF
+@@ -9074,8 +9583,8 @@ _LT_EOF
  
  _LT_EOF
        elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -6621,7 +6670,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -8833,8 +9342,8 @@ _LT_EOF
+@@ -9121,8 +9630,8 @@ _LT_EOF
  
      *)
        if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -6632,7 +6681,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -8964,7 +9473,13 @@ _LT_EOF
+@@ -9252,7 +9761,13 @@ _LT_EOF
  	allow_undefined_flag='-berok'
          # Determine the default libpath from the value encoded in an
          # empty executable.
@@ -6640,14 +6689,14 @@
 +        if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  if ${lt_cv_aix_libpath_+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  /* end confdefs.h.  */
  
  int
-@@ -8977,22 +9492,29 @@ main ()
+@@ -9265,22 +9780,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -6690,7 +6739,7 @@
  
          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
          archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
-@@ -9004,7 +9526,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9292,7 +9814,13 @@ if test -z "$aix_libpath"; then aix_libp
  	else
  	 # Determine the default libpath from the value encoded in an
  	 # empty executable.
@@ -6698,14 +6747,14 @@
 +	 if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  if ${lt_cv_aix_libpath_+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  /* end confdefs.h.  */
  
  int
-@@ -9017,22 +9545,29 @@ main ()
+@@ -9305,22 +9833,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -6748,7 +6797,7 @@
  
  	 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
  	  # Warning - without using the other run time loading flags,
-@@ -9077,20 +9612,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9365,20 +9900,63 @@ if test -z "$aix_libpath"; then aix_libp
        # Microsoft Visual C++.
        # hardcode_libdir_flag_spec is actually meaningless, as there is
        # no search path for DLLs.
@@ -6826,7 +6875,7 @@
        ;;
  
      darwin* | rhapsody*)
-@@ -9151,7 +9729,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9439,7 +10017,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
      freebsd* | dragonfly*)
@@ -6835,7 +6884,7 @@
        hardcode_libdir_flag_spec='-R$libdir'
        hardcode_direct=yes
        hardcode_shlibpath_var=no
-@@ -9159,7 +9737,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9447,7 +10025,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      hpux9*)
        if test "$GCC" = yes; then
@@ -6844,7 +6893,7 @@
        else
  	archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
        fi
-@@ -9175,7 +9753,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9463,7 +10041,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      hpux10*)
        if test "$GCC" = yes && test "$with_gnu_ld" = no; then
@@ -6853,7 +6902,7 @@
        else
  	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
        fi
-@@ -9199,10 +9777,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9487,10 +10065,10 @@ if test -z "$aix_libpath"; then aix_libp
  	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  	  ;;
  	ia64*)
@@ -6866,7 +6915,7 @@
  	  ;;
  	esac
        else
-@@ -9281,23 +9859,36 @@ fi
+@@ -9569,23 +10147,36 @@ fi
  
      irix5* | irix6* | nonstopux*)
        if test "$GCC" = yes; then
@@ -6881,7 +6930,7 @@
 +	# This should be the same for all languages, so no per-tag cache variable.
 +	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
 +$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
-+if test "${lt_cv_irix_exported_symbol+set}" = set; then :
++if ${lt_cv_irix_exported_symbol+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  save_LDFLAGS="$LDFLAGS"
@@ -6911,7 +6960,7 @@
        else
  	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
  	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
-@@ -9382,7 +9973,7 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -9670,7 +10261,7 @@ rm -f core conftest.err conftest.$ac_obj
      osf4* | osf5*)	# as osf3* with the addition of -msym flag
        if test "$GCC" = yes; then
  	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
@@ -6920,7 +6969,7 @@
  	hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
        else
  	allow_undefined_flag=' -expect_unresolved \*'
-@@ -9401,9 +9992,9 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -9689,9 +10280,9 @@ rm -f core conftest.err conftest.$ac_obj
        no_undefined_flag=' -z defs'
        if test "$GCC" = yes; then
  	wlarc='${wl}'
@@ -6932,7 +6981,7 @@
        else
  	case `$CC -V 2>&1` in
  	*"Compilers 5.0"*)
-@@ -9979,8 +10570,9 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10267,8 +10858,9 @@ cygwin* | mingw* | pw32* | cegcc*)
    need_version=no
    need_lib_prefix=no
  
@@ -6944,7 +6993,7 @@
      library_names_spec='$libname.dll.a'
      # DLL is installed to $(libdir)/../bin by postinstall_cmds
      postinstall_cmds='base_file=`basename \${file}`~
-@@ -10013,13 +10605,71 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10301,13 +10893,71 @@ cygwin* | mingw* | pw32* | cegcc*)
        library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
        ;;
      esac
@@ -7017,7 +7066,7 @@
    # FIXME: first we should search . and the directory the executable is in
    shlibpath_var=PATH
    ;;
-@@ -10111,7 +10761,7 @@ haiku*)
+@@ -10399,7 +11049,7 @@ haiku*)
    soname_spec='${libname}${release}${shared_ext}$major'
    shlibpath_var=LIBRARY_PATH
    shlibpath_overrides_runpath=yes
@@ -7026,7 +7075,16 @@
    hardcode_into_libs=yes
    ;;
  
-@@ -10951,10 +11601,10 @@ else
+@@ -11195,7 +11845,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11193 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11239,10 +11889,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -7039,7 +7097,16 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -11057,10 +11707,10 @@ else
+@@ -11301,7 +11951,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11299 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11345,10 +11995,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -7052,7 +7119,7 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -13005,13 +13655,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
+@@ -13314,13 +13964,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_
  lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
  lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
  lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
@@ -7073,7 +7140,7 @@
  STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
  RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
  old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-@@ -13026,14 +13683,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
+@@ -13335,14 +13992,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$l
  lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
@@ -7092,7 +7159,7 @@
  DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
  NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
  LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-@@ -13066,12 +13726,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
+@@ -13375,12 +14035,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcod
  hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
  inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
  link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
@@ -7106,7 +7173,7 @@
  file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
  variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
  need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-@@ -13126,8 +13786,13 @@ reload_flag \
+@@ -13435,8 +14095,13 @@ reload_flag \
  OBJDUMP \
  deplibs_check_method \
  file_magic_cmd \
@@ -7120,7 +7187,7 @@
  STRIP \
  RANLIB \
  CC \
-@@ -13137,12 +13802,14 @@ lt_cv_sys_global_symbol_pipe \
+@@ -13446,12 +14111,14 @@ lt_cv_sys_global_symbol_pipe \
  lt_cv_sys_global_symbol_to_cdecl \
  lt_cv_sys_global_symbol_to_c_name_address \
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
@@ -7136,7 +7203,7 @@
  DSYMUTIL \
  NMEDIT \
  LIPO \
-@@ -13158,7 +13825,6 @@ no_undefined_flag \
+@@ -13467,7 +14134,6 @@ no_undefined_flag \
  hardcode_libdir_flag_spec \
  hardcode_libdir_flag_spec_ld \
  hardcode_libdir_separator \
@@ -7144,7 +7211,7 @@
  exclude_expsyms \
  include_expsyms \
  file_list_spec \
-@@ -13194,6 +13860,7 @@ module_cmds \
+@@ -13503,6 +14169,7 @@ module_cmds \
  module_expsym_cmds \
  export_symbols_cmds \
  prelink_cmds \
@@ -7152,7 +7219,7 @@
  postinstall_cmds \
  postuninstall_cmds \
  finish_cmds \
-@@ -13950,7 +14617,8 @@ $as_echo X"$file" |
+@@ -14268,7 +14935,8 @@ $as_echo X"$file" |
  # NOTE: Changes made to this file will be lost: look at ltmain.sh.
  #
  #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
@@ -7162,7 +7229,7 @@
  #   Written by Gordon Matzigkeit, 1996
  #
  #   This file is part of GNU Libtool.
-@@ -14053,19 +14721,42 @@ SP2NL=$lt_lt_SP2NL
+@@ -14371,19 +15039,42 @@ SP2NL=$lt_lt_SP2NL
  # turn newlines into spaces.
  NL2SP=$lt_lt_NL2SP
  
@@ -7206,7 +7273,7 @@
  # A symbol stripping program.
  STRIP=$lt_STRIP
  
-@@ -14095,6 +14786,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
+@@ -14413,6 +15104,12 @@ global_symbol_to_c_name_address=$lt_lt_c
  # Transform the output of nm in a C name address pair when lib prefix is needed.
  global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
  
@@ -7219,7 +7286,7 @@
  # The name of the directory that contains temporary libtool files.
  objdir=$objdir
  
-@@ -14104,6 +14801,9 @@ MAGIC_CMD=$MAGIC_CMD
+@@ -14422,6 +15119,9 @@ MAGIC_CMD=$MAGIC_CMD
  # Must we lock files when doing compilation?
  need_locks=$lt_need_locks
  
@@ -7229,7 +7296,7 @@
  # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
  DSYMUTIL=$lt_DSYMUTIL
  
-@@ -14218,12 +14918,12 @@ with_gcc=$GCC
+@@ -14536,12 +15236,12 @@ with_gcc=$GCC
  # Compiler flag to turn off builtin functions.
  no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
  
@@ -7245,7 +7312,7 @@
  # Compiler flag to prevent dynamic linking.
  link_static_flag=$lt_lt_prog_compiler_static
  
-@@ -14310,9 +15010,6 @@ inherit_rpath=$inherit_rpath
+@@ -14628,9 +15328,6 @@ inherit_rpath=$inherit_rpath
  # Whether libtool must link a program against all its dependency libraries.
  link_all_deplibs=$link_all_deplibs
  
@@ -7255,7 +7322,7 @@
  # Set to "yes" if exported symbols are required.
  always_export_symbols=$always_export_symbols
  
-@@ -14328,6 +15025,9 @@ include_expsyms=$lt_include_expsyms
+@@ -14646,6 +15343,9 @@ include_expsyms=$lt_include_expsyms
  # Commands necessary for linking programs (against libraries) with templates.
  prelink_cmds=$lt_prelink_cmds
  
@@ -7265,7 +7332,7 @@
  # Specify filename containing input files.
  file_list_spec=$lt_file_list_spec
  
-@@ -14360,210 +15060,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
+@@ -14678,210 +15378,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
    # if finds mixed CR/LF and LF-only lines.  Since sed operates in
    # text mode, it properly converts lines to CR/LF.  This bash problem
    # is reportedly fixed, but why not run on old versions too?
@@ -7467,15 +7534,9 @@
 -_LT_EOF
 -    ;;
 -  esac
--
--
--  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
--    || (rm -f "$cfgfile"; exit 1)
--
--  mv -f "$cfgfile" "$ofile" ||
 +  sed '$q' "$ltmain" >> "$cfgfile" \
 +     || (rm -f "$cfgfile"; exit 1)
-+
+ 
 +  if test x"$xsi_shell" = xyes; then
 +  sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
 +func_dirname ()\
@@ -7633,17 +7694,20 @@
 +  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
 +$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
 +fi
-+
-+
+ 
+-  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
+-    || (rm -f "$cfgfile"; exit 1)
+ 
+-  mv -f "$cfgfile" "$ofile" ||
 +   mv -f "$cfgfile" "$ofile" ||
      (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
    chmod +x "$ofile"
  
-diff --git a/ld/configure b/ld/configure
-index 0cc6e8a50f..db8b998722 100755
---- a/ld/configure
-+++ b/ld/configure
-@@ -655,8 +655,11 @@ OTOOL
+Index: git/ld/configure
+===================================================================
+--- git.orig/ld/configure
++++ git/ld/configure
+@@ -687,8 +687,11 @@ OTOOL
  LIPO
  NMEDIT
  DSYMUTIL
@@ -7655,7 +7719,7 @@
  OBJDUMP
  LN_S
  NM
-@@ -778,6 +781,7 @@ enable_static
+@@ -815,6 +818,7 @@ enable_static
  with_pic
  enable_fast_install
  with_gnu_ld
@@ -7663,7 +7727,7 @@
  enable_libtool_lock
  enable_plugins
  enable_largefile
-@@ -1464,6 +1468,8 @@ Optional Packages:
+@@ -1507,6 +1511,8 @@ Optional Packages:
    --with-pic              try to use only PIC/non-PIC objects [default=use
                            both]
    --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
@@ -7672,7 +7736,7 @@
    --with-lib-path=dir1:dir2...  set default LIB_PATH
    --with-sysroot=DIR Search for usr/lib et al within DIR.
  
-@@ -5658,8 +5664,8 @@ esac
+@@ -5959,8 +5965,8 @@ esac
  
  
  
@@ -7683,7 +7747,7 @@
  
  
  
-@@ -5699,7 +5705,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
+@@ -6000,7 +6006,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
  $as_echo_n "checking how to print strings... " >&6; }
  # Test print first, because it will be a builtin if present.
@@ -7692,7 +7756,7 @@
     test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
    ECHO='print -r --'
  elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
-@@ -6385,8 +6391,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
+@@ -6686,8 +6692,8 @@ $as_echo_n "checking whether the shell u
  # Try some XSI features
  xsi_shell=no
  ( _lt_dummy="a/b/c"
@@ -7703,13 +7767,13 @@
      && eval 'test $(( 1 + 1 )) -eq 2 \
      && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
    && xsi_shell=yes
-@@ -6435,6 +6441,80 @@ esac
+@@ -6736,6 +6742,80 @@ esac
  
  
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
 +$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
-+if test "${lt_cv_to_host_file_cmd+set}" = set; then :
++if ${lt_cv_to_host_file_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  case $host in
@@ -7756,7 +7820,7 @@
 +
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
 +$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
-+if test "${lt_cv_to_tool_file_cmd+set}" = set; then :
++if ${lt_cv_to_tool_file_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  #assume ordinary cross tools, or native build.
@@ -7783,8 +7847,8 @@
 +
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
  $as_echo_n "checking for $LD option to reload object files... " >&6; }
- if test "${lt_cv_ld_reload_flag+set}" = set; then :
-@@ -6451,6 +6531,11 @@ case $reload_flag in
+ if ${lt_cv_ld_reload_flag+:} false; then :
+@@ -6752,6 +6832,11 @@ case $reload_flag in
  esac
  reload_cmds='$LD$reload_flag -o $output$reload_objs'
  case $host_os in
@@ -7796,7 +7860,7 @@
    darwin*)
      if test "$GCC" = yes; then
        reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
-@@ -6619,7 +6704,8 @@ mingw* | pw32*)
+@@ -6920,7 +7005,8 @@ mingw* | pw32*)
      lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
      lt_cv_file_magic_cmd='func_win32_libid'
    else
@@ -7806,7 +7870,7 @@
      lt_cv_file_magic_cmd='$OBJDUMP -f'
    fi
    ;;
-@@ -6773,6 +6859,21 @@ esac
+@@ -7074,6 +7160,21 @@ esac
  fi
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
  $as_echo "$lt_cv_deplibs_check_method" >&6; }
@@ -7828,7 +7892,7 @@
  file_magic_cmd=$lt_cv_file_magic_cmd
  deplibs_check_method=$lt_cv_deplibs_check_method
  test -z "$deplibs_check_method" && deplibs_check_method=unknown
-@@ -6788,9 +6889,162 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
+@@ -7089,9 +7190,162 @@ test -z "$deplibs_check_method" && depli
  
  
  
@@ -7847,7 +7911,7 @@
 +set dummy ${ac_tool_prefix}dlltool; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
++if ${ac_cv_prog_DLLTOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$DLLTOOL"; then
@@ -7859,7 +7923,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -7887,7 +7951,7 @@
 +set dummy dlltool; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
++if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$ac_ct_DLLTOOL"; then
@@ -7899,7 +7963,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_ac_ct_DLLTOOL="dlltool"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -7947,7 +8011,7 @@
 +
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
 +$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
-+if test "${lt_cv_sharedlib_from_linklib_cmd+set}" = set; then :
++if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_sharedlib_from_linklib_cmd='unknown'
@@ -7992,17 +8056,17 @@
 +set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
- if test "${ac_cv_prog_AR+set}" = set; then :
-@@ -6806,7 +7060,7 @@ do
+ if ${ac_cv_prog_AR+:} false; then :
+@@ -7107,7 +7361,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
-   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 -    ac_cv_prog_AR="${ac_tool_prefix}ar"
 +    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6826,11 +7080,15 @@ $as_echo "no" >&6; }
+@@ -7127,11 +7381,15 @@ $as_echo "no" >&6; }
  fi
  
  
@@ -8020,17 +8084,17 @@
 +set dummy $ac_prog; ac_word=$2
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
- if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
-@@ -6846,7 +7104,7 @@ do
+ if ${ac_cv_prog_ac_ct_AR+:} false; then :
+@@ -7147,7 +7405,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
-   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 -    ac_cv_prog_ac_ct_AR="ar"
 +    ac_cv_prog_ac_ct_AR="$ac_prog"
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6865,6 +7123,10 @@ else
+@@ -7166,6 +7424,10 @@ else
  $as_echo "no" >&6; }
  fi
  
@@ -8041,7 +8105,7 @@
    if test "x$ac_ct_AR" = x; then
      AR="false"
    else
-@@ -6876,12 +7138,12 @@ ac_tool_warned=yes ;;
+@@ -7177,12 +7439,11 @@ ac_tool_warned=yes ;;
  esac
      AR=$ac_ct_AR
    fi
@@ -8054,17 +8118,16 @@
 +: ${AR=ar}
 +: ${AR_FLAGS=cru}
 +
-+
  
  
  
-@@ -6891,6 +7153,62 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
+@@ -7193,6 +7454,63 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
  
  
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
 +$as_echo_n "checking for archiver @FILE support... " >&6; }
-+if test "${lt_cv_ar_at_file+set}" = set; then :
++if ${lt_cv_ar_at_file+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_ar_at_file=no
@@ -8118,10 +8181,11 @@
 +
 +
 +
- 
++
  
  if test -n "$ac_tool_prefix"; then
-@@ -7227,8 +7545,8 @@ esac
+   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
+@@ -7528,8 +7846,8 @@ esac
  lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
  
  # Transform an extracted symbol line into symbol name and symbol address
@@ -8132,7 +8196,7 @@
  
  # Handle CRLF in mingw tool chain
  opt_cr=
-@@ -7264,6 +7582,7 @@ for ac_symprfx in "" "_"; do
+@@ -7565,6 +7883,7 @@ for ac_symprfx in "" "_"; do
    else
      lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[	 ]\($symcode$symcode*\)[	 ][	 ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
    fi
@@ -8140,7 +8204,7 @@
  
    # Check to see that the pipe works correctly.
    pipe_works=no
-@@ -7305,6 +7624,18 @@ _LT_EOF
+@@ -7606,6 +7925,18 @@ _LT_EOF
        if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
  	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
  	  cat <<_LT_EOF > conftest.$ac_ext
@@ -8159,7 +8223,7 @@
  #ifdef __cplusplus
  extern "C" {
  #endif
-@@ -7316,7 +7647,7 @@ _LT_EOF
+@@ -7617,7 +7948,7 @@ _LT_EOF
  	  cat <<_LT_EOF >> conftest.$ac_ext
  
  /* The mapping between symbol names and symbols.  */
@@ -8168,7 +8232,7 @@
    const char *name;
    void       *address;
  }
-@@ -7342,8 +7673,8 @@ static const void *lt_preloaded_setup() {
+@@ -7643,8 +7974,8 @@ static const void *lt_preloaded_setup()
  _LT_EOF
  	  # Now try linking the two files.
  	  mv conftest.$ac_objext conftstm.$ac_objext
@@ -8179,7 +8243,7 @@
  	  LIBS="conftstm.$ac_objext"
  	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
  	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
-@@ -7353,8 +7684,8 @@ _LT_EOF
+@@ -7654,8 +7985,8 @@ _LT_EOF
    test $ac_status = 0; } && test -s conftest${ac_exeext}; then
  	    pipe_works=yes
  	  fi
@@ -8190,7 +8254,7 @@
  	else
  	  echo "cannot find nm_test_func in $nlist" >&5
  	fi
-@@ -7391,6 +7722,19 @@ else
+@@ -7692,6 +8023,13 @@ else
  $as_echo "ok" >&6; }
  fi
  
@@ -8201,16 +8265,10 @@
 +  nm_file_list_spec='@'
 +fi
 +
-+
-+
-+
-+
-+
-+
  
  
  
-@@ -7404,6 +7748,42 @@ fi
+@@ -7713,6 +8051,48 @@ fi
  
  
  
@@ -8218,6 +8276,7 @@
 +
 +
 +
++
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
 +$as_echo_n "checking for sysroot... " >&6; }
 +
@@ -8244,16 +8303,21 @@
 + *)
 +   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libtool_sysroot}" >&5
 +$as_echo "${with_libtool_sysroot}" >&6; }
-+   as_fn_error "The sysroot must be an absolute path." "$LINENO" 5
++   as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
 +   ;;
 +esac
 +
 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
 +$as_echo "${lt_sysroot:-no}" >&6; }
- 
- 
- 
-@@ -7618,6 +7998,123 @@ esac
++
++
++
++
++
+ # Check whether --enable-libtool-lock was given.
+ if test "${enable_libtool_lock+set}" = set; then :
+   enableval=$enable_libtool_lock;
+@@ -7919,6 +8299,123 @@ esac
  
  need_locks="$enable_libtool_lock"
  
@@ -8262,7 +8326,7 @@
 +set dummy ${ac_tool_prefix}mt; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_MANIFEST_TOOL+set}" = set; then :
++if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$MANIFEST_TOOL"; then
@@ -8274,7 +8338,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -8302,7 +8366,7 @@
 +set dummy mt; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_ac_ct_MANIFEST_TOOL+set}" = set; then :
++if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$ac_ct_MANIFEST_TOOL"; then
@@ -8314,7 +8378,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -8352,7 +8416,7 @@
 +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
 +$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
-+if test "${lt_cv_path_mainfest_tool+set}" = set; then :
++if ${lt_cv_path_mainfest_tool+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_path_mainfest_tool=no
@@ -8377,7 +8441,7 @@
  
    case $host_os in
      rhapsody* | darwin*)
-@@ -8181,6 +8678,8 @@ _LT_EOF
+@@ -8482,6 +8979,8 @@ _LT_EOF
        $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
        echo "$AR cru libconftest.a conftest.o" >&5
        $AR cru libconftest.a conftest.o 2>&5
@@ -8386,7 +8450,7 @@
        cat > conftest.c << _LT_EOF
  int main() { return 0;}
  _LT_EOF
-@@ -8249,6 +8748,16 @@ done
+@@ -8550,6 +9049,16 @@ done
  
  
  
@@ -8403,7 +8467,7 @@
  
  
  # Set options
-@@ -8377,7 +8886,8 @@ fi
+@@ -8678,7 +9187,8 @@ fi
  LIBTOOL_DEPS="$ltmain"
  
  # Always use our own libtool.
@@ -8413,7 +8477,7 @@
  
  
  
-@@ -8466,7 +8976,7 @@ aix3*)
+@@ -8767,7 +9277,7 @@ aix3*)
  esac
  
  # Global variables:
@@ -8422,7 +8486,7 @@
  can_build_shared=yes
  
  # All known linkers require a `.a' archive for static linking (except MSVC,
-@@ -8764,8 +9274,6 @@ fi
+@@ -9065,8 +9575,6 @@ fi
  lt_prog_compiler_pic=
  lt_prog_compiler_static=
  
@@ -8431,7 +8495,7 @@
  
    if test "$GCC" = yes; then
      lt_prog_compiler_wl='-Wl,'
-@@ -8931,6 +9439,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -9232,6 +9740,12 @@ $as_echo_n "checking for $compiler optio
  	lt_prog_compiler_pic='--shared'
  	lt_prog_compiler_static='--static'
  	;;
@@ -8444,7 +8508,7 @@
        pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
          # Portland Group compilers (*not* the Pentium gcc compiler,
  	# which looks to be a dead project)
-@@ -8993,7 +9507,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -9294,7 +9808,7 @@ $as_echo_n "checking for $compiler optio
        lt_prog_compiler_pic='-KPIC'
        lt_prog_compiler_static='-Bstatic'
        case $cc_basename in
@@ -8453,7 +8517,7 @@
  	lt_prog_compiler_wl='-Qoption ld ';;
        *)
  	lt_prog_compiler_wl='-Wl,';;
-@@ -9050,13 +9564,17 @@ case $host_os in
+@@ -9351,13 +9865,17 @@ case $host_os in
      lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
      ;;
  esac
@@ -8466,7 +8530,7 @@
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-+if test "${lt_cv_prog_compiler_pic+set}" = set; then :
++if ${lt_cv_prog_compiler_pic+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
@@ -8477,7 +8541,7 @@
  
  #
  # Check to make sure the PIC flag actually works.
-@@ -9117,6 +9635,11 @@ fi
+@@ -9418,6 +9936,11 @@ fi
  
  
  
@@ -8489,7 +8553,7 @@
  #
  # Check to make sure the static flag actually works.
  #
-@@ -9467,7 +9990,8 @@ _LT_EOF
+@@ -9768,7 +10291,8 @@ _LT_EOF
        allow_undefined_flag=unsupported
        always_export_symbols=no
        enable_shared_with_static_runtimes=yes
@@ -8499,7 +8563,7 @@
  
        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
          archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-@@ -9566,12 +10090,12 @@ _LT_EOF
+@@ -9867,12 +10391,12 @@ _LT_EOF
  	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
  	  hardcode_libdir_flag_spec=
  	  hardcode_libdir_flag_spec_ld='-rpath $libdir'
@@ -8514,7 +8578,7 @@
  	  fi
  	  ;;
  	esac
-@@ -9585,8 +10109,8 @@ _LT_EOF
+@@ -9886,8 +10410,8 @@ _LT_EOF
  	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
  	wlarc=
        else
@@ -8525,7 +8589,7 @@
        fi
        ;;
  
-@@ -9604,8 +10128,8 @@ _LT_EOF
+@@ -9905,8 +10429,8 @@ _LT_EOF
  
  _LT_EOF
        elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -8536,7 +8600,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9651,8 +10175,8 @@ _LT_EOF
+@@ -9952,8 +10476,8 @@ _LT_EOF
  
      *)
        if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -8547,7 +8611,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9782,7 +10306,13 @@ _LT_EOF
+@@ -10083,7 +10607,13 @@ _LT_EOF
  	allow_undefined_flag='-berok'
          # Determine the default libpath from the value encoded in an
          # empty executable.
@@ -8555,14 +8619,14 @@
 +        if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  if ${lt_cv_aix_libpath_+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  /* end confdefs.h.  */
  
  int
-@@ -9795,22 +10325,29 @@ main ()
+@@ -10096,22 +10626,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -8605,7 +8669,7 @@
  
          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
          archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
-@@ -9822,7 +10359,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -10123,7 +10660,13 @@ if test -z "$aix_libpath"; then aix_libp
  	else
  	 # Determine the default libpath from the value encoded in an
  	 # empty executable.
@@ -8613,14 +8677,14 @@
 +	 if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  if ${lt_cv_aix_libpath_+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  /* end confdefs.h.  */
  
  int
-@@ -9835,22 +10378,29 @@ main ()
+@@ -10136,22 +10679,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -8663,11 +8727,10 @@
  
  	 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
  	  # Warning - without using the other run time loading flags,
-@@ -9894,21 +10444,64 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-       # When not using gcc, we currently assume that we are using
+@@ -10196,20 +10746,63 @@ if test -z "$aix_libpath"; then aix_libp
        # Microsoft Visual C++.
        # hardcode_libdir_flag_spec is actually meaningless, as there is
--      # no search path for DLLs.
+       # no search path for DLLs.
 -      hardcode_libdir_flag_spec=' '
 -      allow_undefined_flag=unsupported
 -      # Tell ltmain to make .lib files, not .a files.
@@ -8682,7 +8745,6 @@
 -      old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
 -      fix_srcfile_path='`cygpath -w "$srcfile"`'
 -      enable_shared_with_static_runtimes=yes
-+      # no search path for DLLs.
 +      case $cc_basename in
 +      cl*)
 +	# Native MSVC
@@ -8743,7 +8805,7 @@
        ;;
  
      darwin* | rhapsody*)
-@@ -9969,7 +10562,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -10270,7 +10863,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
      freebsd* | dragonfly*)
@@ -8752,7 +8814,7 @@
        hardcode_libdir_flag_spec='-R$libdir'
        hardcode_direct=yes
        hardcode_shlibpath_var=no
-@@ -9977,7 +10570,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -10278,7 +10871,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      hpux9*)
        if test "$GCC" = yes; then
@@ -8761,7 +8823,7 @@
        else
  	archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
        fi
-@@ -9993,7 +10586,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -10294,7 +10887,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      hpux10*)
        if test "$GCC" = yes && test "$with_gnu_ld" = no; then
@@ -8770,7 +8832,7 @@
        else
  	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
        fi
-@@ -10017,10 +10610,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -10318,10 +10911,10 @@ if test -z "$aix_libpath"; then aix_libp
  	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  	  ;;
  	ia64*)
@@ -8783,7 +8845,7 @@
  	  ;;
  	esac
        else
-@@ -10099,23 +10692,36 @@ fi
+@@ -10400,23 +10993,36 @@ fi
  
      irix5* | irix6* | nonstopux*)
        if test "$GCC" = yes; then
@@ -8798,7 +8860,7 @@
 +	# This should be the same for all languages, so no per-tag cache variable.
 +	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
 +$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
-+if test "${lt_cv_irix_exported_symbol+set}" = set; then :
++if ${lt_cv_irix_exported_symbol+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  save_LDFLAGS="$LDFLAGS"
@@ -8828,7 +8890,7 @@
        else
  	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
  	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
-@@ -10200,7 +10806,7 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -10501,7 +11107,7 @@ rm -f core conftest.err conftest.$ac_obj
      osf4* | osf5*)	# as osf3* with the addition of -msym flag
        if test "$GCC" = yes; then
  	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
@@ -8837,7 +8899,7 @@
  	hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
        else
  	allow_undefined_flag=' -expect_unresolved \*'
-@@ -10219,9 +10825,9 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -10520,9 +11126,9 @@ rm -f core conftest.err conftest.$ac_obj
        no_undefined_flag=' -z defs'
        if test "$GCC" = yes; then
  	wlarc='${wl}'
@@ -8849,7 +8911,7 @@
        else
  	case `$CC -V 2>&1` in
  	*"Compilers 5.0"*)
-@@ -10797,8 +11403,9 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -11098,8 +11704,9 @@ cygwin* | mingw* | pw32* | cegcc*)
    need_version=no
    need_lib_prefix=no
  
@@ -8861,7 +8923,7 @@
      library_names_spec='$libname.dll.a'
      # DLL is installed to $(libdir)/../bin by postinstall_cmds
      postinstall_cmds='base_file=`basename \${file}`~
-@@ -10831,13 +11438,71 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -11132,13 +11739,71 @@ cygwin* | mingw* | pw32* | cegcc*)
        library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
        ;;
      esac
@@ -8934,7 +8996,7 @@
    # FIXME: first we should search . and the directory the executable is in
    shlibpath_var=PATH
    ;;
-@@ -10929,7 +11594,7 @@ haiku*)
+@@ -11230,7 +11895,7 @@ haiku*)
    soname_spec='${libname}${release}${shared_ext}$major'
    shlibpath_var=LIBRARY_PATH
    shlibpath_overrides_runpath=yes
@@ -8943,7 +9005,16 @@
    hardcode_into_libs=yes
    ;;
  
-@@ -11769,10 +12434,10 @@ else
+@@ -12026,7 +12691,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 12029 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -12070,10 +12735,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -8956,7 +9027,16 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -11875,10 +12540,10 @@ else
+@@ -12132,7 +12797,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 12135 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -12176,10 +12841,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -8969,7 +9049,7 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -12270,6 +12935,7 @@ $RM -r conftest*
+@@ -12571,6 +13236,7 @@ $RM -r conftest*
  
    # Allow CC to be a program name with arguments.
    lt_save_CC=$CC
@@ -8977,7 +9057,7 @@
    lt_save_LD=$LD
    lt_save_GCC=$GCC
    GCC=$GXX
-@@ -12287,6 +12953,7 @@ $RM -r conftest*
+@@ -12588,6 +13254,7 @@ $RM -r conftest*
    fi
    test -z "${LDCXX+set}" || LD=$LDCXX
    CC=${CXX-"c++"}
@@ -8985,7 +9065,7 @@
    compiler=$CC
    compiler_CXX=$CC
    for cc_temp in $compiler""; do
-@@ -12569,7 +13236,13 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
+@@ -12870,7 +13537,13 @@ $as_echo_n "checking whether the $compil
            allow_undefined_flag_CXX='-berok'
            # Determine the default libpath from the value encoded in an empty
            # executable.
@@ -8993,14 +9073,14 @@
 +          if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath__CXX+set}" = set; then :
++  if ${lt_cv_aix_libpath__CXX+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  /* end confdefs.h.  */
  
  int
-@@ -12582,22 +13255,29 @@ main ()
+@@ -12883,22 +13556,29 @@ main ()
  _ACEOF
  if ac_fn_cxx_try_link "$LINENO"; then :
  
@@ -9043,7 +9123,7 @@
  
            hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
  
-@@ -12610,7 +13290,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -12911,7 +13591,13 @@ if test -z "$aix_libpath"; then aix_libp
            else
  	    # Determine the default libpath from the value encoded in an
  	    # empty executable.
@@ -9051,14 +9131,14 @@
 +	    if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath__CXX+set}" = set; then :
++  if ${lt_cv_aix_libpath__CXX+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  /* end confdefs.h.  */
  
  int
-@@ -12623,22 +13309,29 @@ main ()
+@@ -12924,22 +13610,29 @@ main ()
  _ACEOF
  if ac_fn_cxx_try_link "$LINENO"; then :
  
@@ -9101,7 +9181,7 @@
  
  	    hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
  	    # Warning - without using the other run time loading flags,
-@@ -12681,29 +13374,75 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -12982,29 +13675,75 @@ if test -z "$aix_libpath"; then aix_libp
          ;;
  
        cygwin* | mingw* | pw32* | cegcc*)
@@ -9200,7 +9280,7 @@
        darwin* | rhapsody*)
  
  
-@@ -12809,7 +13548,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -13110,7 +13849,7 @@ if test -z "$aix_libpath"; then aix_libp
              ;;
            *)
              if test "$GXX" = yes; then
@@ -9209,7 +9289,7 @@
              else
                # FIXME: insert proper C++ library support
                ld_shlibs_CXX=no
-@@ -12880,10 +13619,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -13181,10 +13920,10 @@ if test -z "$aix_libpath"; then aix_libp
  	            archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  	            ;;
  	          ia64*)
@@ -9222,7 +9302,7 @@
  	            ;;
  	        esac
  	      fi
-@@ -12924,9 +13663,9 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -13225,9 +13964,9 @@ if test -z "$aix_libpath"; then aix_libp
            *)
  	    if test "$GXX" = yes; then
  	      if test "$with_gnu_ld" = no; then
@@ -9234,7 +9314,7 @@
  	      fi
  	    fi
  	    link_all_deplibs_CXX=yes
-@@ -12996,20 +13735,20 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -13297,20 +14036,20 @@ if test -z "$aix_libpath"; then aix_libp
  	      prelink_cmds_CXX='tpldir=Template.dir~
  		rm -rf $tpldir~
  		$CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
@@ -9259,7 +9339,7 @@
  	      ;;
  	    *) # Version 6 and above use weak symbols
  	      archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
-@@ -13204,7 +13943,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -13505,7 +14244,7 @@ if test -z "$aix_libpath"; then aix_libp
  	          archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
  		  ;;
  	        *)
@@ -9268,7 +9348,7 @@
  		  ;;
  	      esac
  
-@@ -13250,7 +13989,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -13551,7 +14290,7 @@ if test -z "$aix_libpath"; then aix_libp
  
        solaris*)
          case $cc_basename in
@@ -9277,7 +9357,7 @@
  	    # Sun C++ 4.2, 5.x and Centerline C++
              archive_cmds_need_lc_CXX=yes
  	    no_undefined_flag_CXX=' -zdefs'
-@@ -13291,9 +14030,9 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -13592,9 +14331,9 @@ if test -z "$aix_libpath"; then aix_libp
  	    if test "$GXX" = yes && test "$with_gnu_ld" = no; then
  	      no_undefined_flag_CXX=' ${wl}-z ${wl}defs'
  	      if $CC --version | $GREP -v '^2\.7' > /dev/null; then
@@ -9289,7 +9369,7 @@
  
  	        # Commands to make compiler produce verbose output that lists
  	        # what "hidden" libraries, object files and flags are used when
-@@ -13428,6 +14167,13 @@ private:
+@@ -13729,6 +14468,13 @@ private:
  };
  _LT_EOF
  
@@ -9303,7 +9383,7 @@
  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
    (eval $ac_compile) 2>&5
    ac_status=$?
-@@ -13441,7 +14187,7 @@ if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
+@@ -13742,7 +14488,7 @@ if { { eval echo "\"\$as_me\":${as_linen
    pre_test_object_deps_done=no
  
    for p in `eval "$output_verbose_link_cmd"`; do
@@ -9312,7 +9392,7 @@
  
      -L* | -R* | -l*)
         # Some compilers place space between "-{L,R}" and the path.
-@@ -13450,13 +14196,22 @@ if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
+@@ -13751,13 +14497,22 @@ if { { eval echo "\"\$as_me\":${as_linen
            test $p = "-R"; then
  	 prev=$p
  	 continue
@@ -9339,7 +9419,7 @@
  	   # Internal compiler library paths should come after those
  	   # provided the user.  The postdeps already come after the
  	   # user supplied libs so there is no need to process them.
-@@ -13476,8 +14231,10 @@ if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
+@@ -13777,8 +14532,10 @@ if { { eval echo "\"\$as_me\":${as_linen
  	   postdeps_CXX="${postdeps_CXX} ${prev}${p}"
  	 fi
         fi
@@ -9350,7 +9430,7 @@
      *.$objext)
         # This assumes that the test object file only shows up
         # once in the compiler output.
-@@ -13513,6 +14270,7 @@ else
+@@ -13814,6 +14571,7 @@ else
  fi
  
  $RM -f confest.$objext
@@ -9358,7 +9438,7 @@
  
  # PORTME: override above test on systems where it is broken
  case $host_os in
-@@ -13548,7 +14306,7 @@ linux*)
+@@ -13849,7 +14607,7 @@ linux*)
  
  solaris*)
    case $cc_basename in
@@ -9367,7 +9447,7 @@
      # The more standards-conforming stlport4 library is
      # incompatible with the Cstd library. Avoid specifying
      # it if it's in CXXFLAGS. Ignore libCrun as
-@@ -13613,8 +14371,6 @@ fi
+@@ -13914,8 +14672,6 @@ fi
  lt_prog_compiler_pic_CXX=
  lt_prog_compiler_static_CXX=
  
@@ -9376,7 +9456,7 @@
  
    # C++ specific cases for pic, static, wl, etc.
    if test "$GXX" = yes; then
-@@ -13719,6 +14475,11 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -14020,6 +14776,11 @@ $as_echo_n "checking for $compiler optio
  	  ;;
  	esac
  	;;
@@ -9388,7 +9468,7 @@
        dgux*)
  	case $cc_basename in
  	  ec++*)
-@@ -13871,7 +14632,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -14172,7 +14933,7 @@ $as_echo_n "checking for $compiler optio
  	;;
        solaris*)
  	case $cc_basename in
@@ -9397,7 +9477,7 @@
  	    # Sun C++ 4.2, 5.x and Centerline C++
  	    lt_prog_compiler_pic_CXX='-KPIC'
  	    lt_prog_compiler_static_CXX='-Bstatic'
-@@ -13936,10 +14697,17 @@ case $host_os in
+@@ -14237,10 +14998,17 @@ case $host_os in
      lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC"
      ;;
  esac
@@ -9407,7 +9487,7 @@
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-+if test "${lt_cv_prog_compiler_pic_CXX+set}" = set; then :
++if ${lt_cv_prog_compiler_pic_CXX+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_prog_compiler_pic_CXX=$lt_prog_compiler_pic_CXX
@@ -9418,7 +9498,7 @@
  
  #
  # Check to make sure the PIC flag actually works.
-@@ -13997,6 +14765,8 @@ fi
+@@ -14298,6 +15066,8 @@ fi
  
  
  
@@ -9427,7 +9507,7 @@
  #
  # Check to make sure the static flag actually works.
  #
-@@ -14174,6 +14944,7 @@ fi
+@@ -14475,6 +15245,7 @@ fi
  $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
  
    export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
@@ -9435,7 +9515,7 @@
    case $host_os in
    aix[4-9]*)
      # If we're using GNU nm, then we don't want the "-C" option.
-@@ -14188,15 +14959,20 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
+@@ -14489,15 +15260,20 @@ $as_echo_n "checking whether the $compil
      ;;
    pw32*)
      export_symbols_cmds_CXX="$ltdll_cmds"
@@ -9461,7 +9541,7 @@
  
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
  $as_echo "$ld_shlibs_CXX" >&6; }
-@@ -14459,8 +15235,9 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -14760,8 +15536,9 @@ cygwin* | mingw* | pw32* | cegcc*)
    need_version=no
    need_lib_prefix=no
  
@@ -9473,7 +9553,7 @@
      library_names_spec='$libname.dll.a'
      # DLL is installed to $(libdir)/../bin by postinstall_cmds
      postinstall_cmds='base_file=`basename \${file}`~
-@@ -14492,13 +15269,71 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -14793,13 +15570,71 @@ cygwin* | mingw* | pw32* | cegcc*)
        library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
        ;;
      esac
@@ -9546,7 +9626,7 @@
    # FIXME: first we should search . and the directory the executable is in
    shlibpath_var=PATH
    ;;
-@@ -14589,7 +15424,7 @@ haiku*)
+@@ -14890,7 +15725,7 @@ haiku*)
    soname_spec='${libname}${release}${shared_ext}$major'
    shlibpath_var=LIBRARY_PATH
    shlibpath_overrides_runpath=yes
@@ -9555,7 +9635,7 @@
    hardcode_into_libs=yes
    ;;
  
-@@ -15048,6 +15883,7 @@ fi
+@@ -15349,6 +16184,7 @@ fi
    fi # test -n "$compiler"
  
    CC=$lt_save_CC
@@ -9563,7 +9643,7 @@
    LDCXX=$LD
    LD=$lt_save_LD
    GCC=$lt_save_GCC
-@@ -18083,13 +18919,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
+@@ -18444,13 +19280,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_
  lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
  lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
  lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
@@ -9584,7 +9664,7 @@
  STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
  RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
  old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-@@ -18104,14 +18947,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
+@@ -18465,14 +19308,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$l
  lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
@@ -9603,7 +9683,7 @@
  DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
  NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
  LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-@@ -18144,12 +18990,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
+@@ -18505,12 +19351,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcod
  hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
  inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
  link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
@@ -9617,7 +9697,7 @@
  file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
  variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
  need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-@@ -18188,8 +19034,8 @@ old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote
+@@ -18549,8 +19395,8 @@ old_archive_cmds_CXX='`$ECHO "$old_archi
  compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`'
  GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`'
  lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`'
@@ -9627,7 +9707,7 @@
  lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`'
  lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`'
  archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`'
-@@ -18216,12 +19062,12 @@ hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_
+@@ -18577,12 +19423,12 @@ hardcode_shlibpath_var_CXX='`$ECHO "$har
  hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`'
  inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`'
  link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`'
@@ -9641,7 +9721,7 @@
  file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`'
  hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`'
  compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`'
-@@ -18259,8 +19105,13 @@ reload_flag \
+@@ -18620,8 +19466,13 @@ reload_flag \
  OBJDUMP \
  deplibs_check_method \
  file_magic_cmd \
@@ -9655,7 +9735,7 @@
  STRIP \
  RANLIB \
  CC \
-@@ -18270,12 +19121,14 @@ lt_cv_sys_global_symbol_pipe \
+@@ -18631,12 +19482,14 @@ lt_cv_sys_global_symbol_pipe \
  lt_cv_sys_global_symbol_to_cdecl \
  lt_cv_sys_global_symbol_to_c_name_address \
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
@@ -9671,7 +9751,7 @@
  DSYMUTIL \
  NMEDIT \
  LIPO \
-@@ -18291,7 +19144,6 @@ no_undefined_flag \
+@@ -18652,7 +19505,6 @@ no_undefined_flag \
  hardcode_libdir_flag_spec \
  hardcode_libdir_flag_spec_ld \
  hardcode_libdir_separator \
@@ -9679,7 +9759,7 @@
  exclude_expsyms \
  include_expsyms \
  file_list_spec \
-@@ -18313,8 +19165,8 @@ LD_CXX \
+@@ -18674,8 +19526,8 @@ LD_CXX \
  reload_flag_CXX \
  compiler_CXX \
  lt_prog_compiler_no_builtin_flag_CXX \
@@ -9689,7 +9769,7 @@
  lt_prog_compiler_static_CXX \
  lt_cv_prog_compiler_c_o_CXX \
  export_dynamic_flag_spec_CXX \
-@@ -18326,7 +19178,6 @@ no_undefined_flag_CXX \
+@@ -18687,7 +19539,6 @@ no_undefined_flag_CXX \
  hardcode_libdir_flag_spec_CXX \
  hardcode_libdir_flag_spec_ld_CXX \
  hardcode_libdir_separator_CXX \
@@ -9697,7 +9777,7 @@
  exclude_expsyms_CXX \
  include_expsyms_CXX \
  file_list_spec_CXX \
-@@ -18360,6 +19211,7 @@ module_cmds \
+@@ -18721,6 +19572,7 @@ module_cmds \
  module_expsym_cmds \
  export_symbols_cmds \
  prelink_cmds \
@@ -9705,7 +9785,7 @@
  postinstall_cmds \
  postuninstall_cmds \
  finish_cmds \
-@@ -18374,7 +19226,8 @@ archive_expsym_cmds_CXX \
+@@ -18735,7 +19587,8 @@ archive_expsym_cmds_CXX \
  module_cmds_CXX \
  module_expsym_cmds_CXX \
  export_symbols_cmds_CXX \
@@ -9715,7 +9795,7 @@
      case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
      *[\\\\\\\`\\"\\\$]*)
        eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
-@@ -19167,7 +20020,8 @@ $as_echo X"$file" |
+@@ -19539,7 +20392,8 @@ $as_echo X"$file" |
  # NOTE: Changes made to this file will be lost: look at ltmain.sh.
  #
  #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
@@ -9725,7 +9805,7 @@
  #   Written by Gordon Matzigkeit, 1996
  #
  #   This file is part of GNU Libtool.
-@@ -19270,19 +20124,42 @@ SP2NL=$lt_lt_SP2NL
+@@ -19642,19 +20496,42 @@ SP2NL=$lt_lt_SP2NL
  # turn newlines into spaces.
  NL2SP=$lt_lt_NL2SP
  
@@ -9769,7 +9849,7 @@
  # A symbol stripping program.
  STRIP=$lt_STRIP
  
-@@ -19312,6 +20189,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
+@@ -19684,6 +20561,12 @@ global_symbol_to_c_name_address=$lt_lt_c
  # Transform the output of nm in a C name address pair when lib prefix is needed.
  global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
  
@@ -9782,7 +9862,7 @@
  # The name of the directory that contains temporary libtool files.
  objdir=$objdir
  
-@@ -19321,6 +20204,9 @@ MAGIC_CMD=$MAGIC_CMD
+@@ -19693,6 +20576,9 @@ MAGIC_CMD=$MAGIC_CMD
  # Must we lock files when doing compilation?
  need_locks=$lt_need_locks
  
@@ -9792,7 +9872,7 @@
  # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
  DSYMUTIL=$lt_DSYMUTIL
  
-@@ -19435,12 +20321,12 @@ with_gcc=$GCC
+@@ -19807,12 +20693,12 @@ with_gcc=$GCC
  # Compiler flag to turn off builtin functions.
  no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
  
@@ -9808,7 +9888,7 @@
  # Compiler flag to prevent dynamic linking.
  link_static_flag=$lt_lt_prog_compiler_static
  
-@@ -19527,9 +20413,6 @@ inherit_rpath=$inherit_rpath
+@@ -19899,9 +20785,6 @@ inherit_rpath=$inherit_rpath
  # Whether libtool must link a program against all its dependency libraries.
  link_all_deplibs=$link_all_deplibs
  
@@ -9818,7 +9898,7 @@
  # Set to "yes" if exported symbols are required.
  always_export_symbols=$always_export_symbols
  
-@@ -19545,6 +20428,9 @@ include_expsyms=$lt_include_expsyms
+@@ -19917,6 +20800,9 @@ include_expsyms=$lt_include_expsyms
  # Commands necessary for linking programs (against libraries) with templates.
  prelink_cmds=$lt_prelink_cmds
  
@@ -9828,7 +9908,7 @@
  # Specify filename containing input files.
  file_list_spec=$lt_file_list_spec
  
-@@ -19591,210 +20477,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
+@@ -19963,210 +20849,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
    # if finds mixed CR/LF and LF-only lines.  Since sed operates in
    # text mode, it properly converts lines to CR/LF.  This bash problem
    # is reportedly fixed, but why not run on old versions too?
@@ -10030,15 +10110,9 @@
 -_LT_EOF
 -    ;;
 -  esac
--
--
--  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
--    || (rm -f "$cfgfile"; exit 1)
--
--  mv -f "$cfgfile" "$ofile" ||
 +  sed '$q' "$ltmain" >> "$cfgfile" \
 +     || (rm -f "$cfgfile"; exit 1)
-+
+ 
 +  if test x"$xsi_shell" = xyes; then
 +  sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
 +func_dirname ()\
@@ -10196,13 +10270,16 @@
 +  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
 +$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
 +fi
-+
-+
+ 
+-  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
+-    || (rm -f "$cfgfile"; exit 1)
+ 
+-  mv -f "$cfgfile" "$ofile" ||
 +   mv -f "$cfgfile" "$ofile" ||
      (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
    chmod +x "$ofile"
  
-@@ -19822,12 +20667,12 @@ with_gcc=$GCC_CXX
+@@ -20194,12 +21039,12 @@ with_gcc=$GCC_CXX
  # Compiler flag to turn off builtin functions.
  no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX
  
@@ -10218,7 +10295,7 @@
  # Compiler flag to prevent dynamic linking.
  link_static_flag=$lt_lt_prog_compiler_static_CXX
  
-@@ -19914,9 +20759,6 @@ inherit_rpath=$inherit_rpath_CXX
+@@ -20286,9 +21131,6 @@ inherit_rpath=$inherit_rpath_CXX
  # Whether libtool must link a program against all its dependency libraries.
  link_all_deplibs=$link_all_deplibs_CXX
  
@@ -10228,7 +10305,7 @@
  # Set to "yes" if exported symbols are required.
  always_export_symbols=$always_export_symbols_CXX
  
-@@ -19932,6 +20774,9 @@ include_expsyms=$lt_include_expsyms_CXX
+@@ -20304,6 +21146,9 @@ include_expsyms=$lt_include_expsyms_CXX
  # Commands necessary for linking programs (against libraries) with templates.
  prelink_cmds=$lt_prelink_cmds_CXX
  
@@ -10238,10 +10315,10 @@
  # Specify filename containing input files.
  file_list_spec=$lt_file_list_spec_CXX
  
-diff --git a/libtool.m4 b/libtool.m4
-index 24d13f3440..e45fdc6998 100644
---- a/libtool.m4
-+++ b/libtool.m4
+Index: git/libtool.m4
+===================================================================
+--- git.orig/libtool.m4
++++ git/libtool.m4
 @@ -1,7 +1,8 @@
  # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
  #
@@ -10281,7 +10358,7 @@
  AC_SUBST(LIBTOOL)dnl
  
  _LT_SETUP
-@@ -166,10 +169,13 @@ _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
+@@ -166,10 +169,13 @@ _LT_DECL([], [exeext], [0], [Executable
  dnl
  m4_require([_LT_FILEUTILS_DEFAULTS])dnl
  m4_require([_LT_CHECK_SHELL_FEATURES])dnl
@@ -10304,7 +10381,7 @@
  can_build_shared=yes
  
  # All known linkers require a `.a' archive for static linking (except MSVC,
-@@ -632,7 +638,7 @@ m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
+@@ -632,7 +638,7 @@ m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_
  m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
  configured by $[0], generated by m4_PACKAGE_STRING.
  
@@ -10360,7 +10437,7 @@
 +# Allow to override them for all tags through lt_cv_aix_libpath.
  m4_defun([_LT_SYS_MODULE_PATH_AIX],
  [m4_require([_LT_DECL_SED])dnl
--AC_LINK_IFELSE(AC_LANG_PROGRAM,[
+-AC_LINK_IFELSE([AC_LANG_SOURCE([AC_LANG_PROGRAM])],[
 -lt_aix_libpath_sed='
 -    /Import File Strings/,/^$/ {
 -	/^0/ {
@@ -10409,7 +10486,7 @@
     test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
    ECHO='print -r --'
  elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
-@@ -1161,6 +1177,39 @@ _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes])
+@@ -1161,6 +1177,39 @@ _LT_DECL([], [ECHO], [1], [An echo progr
  ])# _LT_PROG_ECHO_BACKSLASH
  
  
@@ -10662,7 +10739,7 @@
  file_magic_cmd=$lt_cv_file_magic_cmd
  deplibs_check_method=$lt_cv_deplibs_check_method
  test -z "$deplibs_check_method" && deplibs_check_method=unknown
-@@ -3174,7 +3336,11 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
+@@ -3174,7 +3336,11 @@ test -z "$deplibs_check_method" && depli
  _LT_DECL([], [deplibs_check_method], [1],
      [Method to check whether dependent libraries are shared objects])
  _LT_DECL([], [file_magic_cmd], [1],
@@ -10790,7 +10867,7 @@
    const char *name;
    void       *address;
  }
-@@ -3510,15 +3750,15 @@ static const void *lt_preloaded_setup() {
+@@ -3510,15 +3750,15 @@ static const void *lt_preloaded_setup()
  _LT_EOF
  	  # Now try linking the two files.
  	  mv conftest.$ac_objext conftstm.$ac_objext
@@ -10824,7 +10901,7 @@
  _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
      [Take the output of nm and produce a listing of raw symbols and C names])
  _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
-@@ -3561,6 +3808,8 @@ _LT_DECL([global_symbol_to_c_name_address],
+@@ -3561,6 +3808,8 @@ _LT_DECL([global_symbol_to_c_name_addres
  _LT_DECL([global_symbol_to_c_name_address_lib_prefix],
      [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
      [Transform the output of nm in a C name address pair when lib prefix is needed])
@@ -10909,7 +10986,7 @@
  #
  # Check to make sure the static flag actually works.
  #
-@@ -4213,6 +4477,7 @@ _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
+@@ -4213,6 +4477,7 @@ _LT_TAGDECL([link_static_flag], [lt_prog
  m4_defun([_LT_LINKER_SHLIBS],
  [AC_REQUIRE([LT_PATH_LD])dnl
  AC_REQUIRE([LT_PATH_NM])dnl
@@ -11156,7 +11233,7 @@
  	# implicitly export all symbols.
 -        save_LDFLAGS="$LDFLAGS"
 -        LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
--        AC_LINK_IFELSE(int foo(void) {},
+-        AC_LINK_IFELSE([AC_LANG_SOURCE([int foo(void) {}])],
 -          _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
 -        )
 -        LDFLAGS="$save_LDFLAGS"
@@ -11231,7 +11308,7 @@
  if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
      ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
      (test "X$CXX" != "Xg++"))) ; then
-@@ -5487,6 +5818,7 @@ if test "$_lt_caught_CXX_error" != yes; then
+@@ -5487,6 +5818,7 @@ if test "$_lt_caught_CXX_error" != yes;
  
    # Allow CC to be a program name with arguments.
    lt_save_CC=$CC
@@ -11239,7 +11316,7 @@
    lt_save_LD=$LD
    lt_save_GCC=$GCC
    GCC=$GXX
-@@ -5504,6 +5836,7 @@ if test "$_lt_caught_CXX_error" != yes; then
+@@ -5504,6 +5836,7 @@ if test "$_lt_caught_CXX_error" != yes;
    fi
    test -z "${LDCXX+set}" || LD=$LDCXX
    CC=${CXX-"c++"}
@@ -11247,7 +11324,7 @@
    compiler=$CC
    _LT_TAGVAR(compiler, $1)=$CC
    _LT_CC_BASENAME([$compiler])
-@@ -5667,7 +6000,7 @@ if test "$_lt_caught_CXX_error" != yes; then
+@@ -5667,7 +6000,7 @@ if test "$_lt_caught_CXX_error" != yes;
            _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
            # Determine the default libpath from the value encoded in an empty
            # executable.
@@ -11256,7 +11333,7 @@
            _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
  
            _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
-@@ -5679,7 +6012,7 @@ if test "$_lt_caught_CXX_error" != yes; then
+@@ -5679,7 +6012,7 @@ if test "$_lt_caught_CXX_error" != yes;
            else
  	    # Determine the default libpath from the value encoded in an
  	    # empty executable.
@@ -11265,7 +11342,7 @@
  	    _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
  	    # Warning - without using the other run time loading flags,
  	    # -berok will link without error, but may produce a broken library.
-@@ -5721,29 +6054,75 @@ if test "$_lt_caught_CXX_error" != yes; then
+@@ -5721,29 +6054,75 @@ if test "$_lt_caught_CXX_error" != yes;
          ;;
  
        cygwin* | mingw* | pw32* | cegcc*)
@@ -11364,7 +11441,7 @@
        darwin* | rhapsody*)
          _LT_DARWIN_LINKER_FEATURES($1)
  	;;
-@@ -5818,7 +6197,7 @@ if test "$_lt_caught_CXX_error" != yes; then
+@@ -5818,7 +6197,7 @@ if test "$_lt_caught_CXX_error" != yes;
              ;;
            *)
              if test "$GXX" = yes; then
@@ -11373,7 +11450,7 @@
              else
                # FIXME: insert proper C++ library support
                _LT_TAGVAR(ld_shlibs, $1)=no
-@@ -5889,10 +6268,10 @@ if test "$_lt_caught_CXX_error" != yes; then
+@@ -5889,10 +6268,10 @@ if test "$_lt_caught_CXX_error" != yes;
  	            _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  	            ;;
  	          ia64*)
@@ -11386,7 +11463,7 @@
  	            ;;
  	        esac
  	      fi
-@@ -5933,9 +6312,9 @@ if test "$_lt_caught_CXX_error" != yes; then
+@@ -5933,9 +6312,9 @@ if test "$_lt_caught_CXX_error" != yes;
            *)
  	    if test "$GXX" = yes; then
  	      if test "$with_gnu_ld" = no; then
@@ -11398,7 +11475,7 @@
  	      fi
  	    fi
  	    _LT_TAGVAR(link_all_deplibs, $1)=yes
-@@ -6005,20 +6384,20 @@ if test "$_lt_caught_CXX_error" != yes; then
+@@ -6005,20 +6384,20 @@ if test "$_lt_caught_CXX_error" != yes;
  	      _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
  		rm -rf $tpldir~
  		$CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
@@ -11423,7 +11500,7 @@
  	      ;;
  	    *) # Version 6 and above use weak symbols
  	      _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
-@@ -6213,7 +6592,7 @@ if test "$_lt_caught_CXX_error" != yes; then
+@@ -6213,7 +6592,7 @@ if test "$_lt_caught_CXX_error" != yes;
  	          _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
  		  ;;
  	        *)
@@ -11432,7 +11509,7 @@
  		  ;;
  	      esac
  
-@@ -6259,7 +6638,7 @@ if test "$_lt_caught_CXX_error" != yes; then
+@@ -6259,7 +6638,7 @@ if test "$_lt_caught_CXX_error" != yes;
  
        solaris*)
          case $cc_basename in
@@ -11441,7 +11518,7 @@
  	    # Sun C++ 4.2, 5.x and Centerline C++
              _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
  	    _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
-@@ -6300,9 +6679,9 @@ if test "$_lt_caught_CXX_error" != yes; then
+@@ -6300,9 +6679,9 @@ if test "$_lt_caught_CXX_error" != yes;
  	    if test "$GXX" = yes && test "$with_gnu_ld" = no; then
  	      _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
  	      if $CC --version | $GREP -v '^2\.7' > /dev/null; then
@@ -11453,7 +11530,7 @@
  
  	        # Commands to make compiler produce verbose output that lists
  	        # what "hidden" libraries, object files and flags are used when
-@@ -6431,6 +6810,7 @@ if test "$_lt_caught_CXX_error" != yes; then
+@@ -6431,6 +6810,7 @@ if test "$_lt_caught_CXX_error" != yes;
    fi # test -n "$compiler"
  
    CC=$lt_save_CC
@@ -11661,7 +11738,7 @@
  ])# _LT_LANG_RC_CONFIG
  
  
-@@ -7101,6 +7536,15 @@ _LT_DECL([], [OBJDUMP], [1], [An object symbol dumper])
+@@ -7101,6 +7536,15 @@ _LT_DECL([], [OBJDUMP], [1], [An object
  AC_SUBST([OBJDUMP])
  ])
  
@@ -11688,7 +11765,7 @@
      && eval 'test $(( 1 + 1 )) -eq 2 \
      && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
    && xsi_shell=yes
-@@ -7234,206 +7678,162 @@ _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
+@@ -7234,206 +7678,162 @@ _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn
  ])# _LT_CHECK_SHELL_FEATURES
  
  
@@ -11786,6 +11863,31 @@
 -{
 -  func_len_result=${#1}
 -}
+-
+-_LT_EOF
+-    ;;
+-  *) # Bourne compatible functions.
+-    cat << \_LT_EOF >> "$cfgfile"
+-
+-# func_dirname file append nondir_replacement
+-# Compute the dirname of FILE.  If nonempty, add APPEND to the result,
+-# otherwise set result to NONDIR_REPLACEMENT.
+-func_dirname ()
+-{
+-  # Extract subdirectory from the argument.
+-  func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
+-  if test "X$func_dirname_result" = "X${1}"; then
+-    func_dirname_result="${3}"
+-  else
+-    func_dirname_result="$func_dirname_result${2}"
+-  fi
+-}
+-
+-# func_basename file
+-func_basename ()
+-{
+-  func_basename_result=`$ECHO "${1}" | $SED "$basename"`
+-}
 +# _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY)
 +# ------------------------------------------------------
 +# In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and
@@ -11802,23 +11904,22 @@
 +test 0 -eq $? || _lt_function_replace_fail=:
 +])
  
--_LT_EOF
--    ;;
--  *) # Bourne compatible functions.
--    cat << \_LT_EOF >> "$cfgfile"
+-dnl func_dirname_and_basename
+-dnl A portable version of this function is already defined in general.m4sh
+-dnl so there is no need for it here.
  
--# func_dirname file append nondir_replacement
--# Compute the dirname of FILE.  If nonempty, add APPEND to the result,
--# otherwise set result to NONDIR_REPLACEMENT.
--func_dirname ()
+-# func_stripname prefix suffix name
+-# strip PREFIX and SUFFIX off of NAME.
+-# PREFIX and SUFFIX must not contain globbing or regex special
+-# characters, hashes, percent signs, but SUFFIX may contain a leading
+-# dot (in which case that matches only a dot).
+-# func_strip_suffix prefix name
+-func_stripname ()
 -{
--  # Extract subdirectory from the argument.
--  func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
--  if test "X$func_dirname_result" = "X${1}"; then
--    func_dirname_result="${3}"
--  else
--    func_dirname_result="$func_dirname_result${2}"
--  fi
+-  case ${2} in
+-    .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
+-    *)  func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
+-  esac
 -}
 +# _LT_PROG_REPLACE_SHELLFNS
 +# -------------------------
@@ -11842,45 +11943,24 @@
 +    esac
 +    func_basename_result="${1##*/}"])
  
--# func_basename file
--func_basename ()
--{
--  func_basename_result=`$ECHO "${1}" | $SED "$basename"`
--}
+-# sed scripts:
+-my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q'
+-my_sed_long_arg='1s/^-[[^=]]*=//'
 +  _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl
 +    # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
 +    # positional parameters, so assign one to ordinary parameter first.
 +    func_stripname_result=${3}
 +    func_stripname_result=${func_stripname_result#"${1}"}
 +    func_stripname_result=${func_stripname_result%"${2}"}])
- 
--dnl func_dirname_and_basename
--dnl A portable version of this function is already defined in general.m4sh
--dnl so there is no need for it here.
++
 +  _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl
 +    func_split_long_opt_name=${1%%=*}
 +    func_split_long_opt_arg=${1#*=}])
- 
--# func_stripname prefix suffix name
--# strip PREFIX and SUFFIX off of NAME.
--# PREFIX and SUFFIX must not contain globbing or regex special
--# characters, hashes, percent signs, but SUFFIX may contain a leading
--# dot (in which case that matches only a dot).
--# func_strip_suffix prefix name
--func_stripname ()
--{
--  case ${2} in
--    .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
--    *)  func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
--  esac
--}
++
 +  _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl
 +    func_split_short_opt_arg=${1#??}
 +    func_split_short_opt_name=${1%"$func_split_short_opt_arg"}])
- 
--# sed scripts:
--my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q'
--my_sed_long_arg='1s/^-[[^=]]*=//'
++
 +  _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl
 +    case ${1} in
 +      *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
@@ -11928,9 +12008,7 @@
 +    func_quote_for_eval "${2}"
 +dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \
 +    eval "${1}+=\\\\ \\$func_quote_for_eval_result"])
- 
--_LT_EOF
--esac
++
 +  # Save a `func_append' function call where possible by direct use of '+='
 +  sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
 +    && mv -f "$cfgfile.tmp" "$cfgfile" \
@@ -11944,14 +12022,17 @@
 +  test 0 -eq $? || _lt_function_replace_fail=:
 +fi
  
--case $lt_shell_append in
--  yes)
--    cat << \_LT_EOF >> "$cfgfile"
+-_LT_EOF
+-esac
 +if test x"$_lt_function_replace_fail" = x":"; then
 +  AC_MSG_WARN([Unable to substitute extended shell functions in $ofile])
 +fi
 +])
  
+-case $lt_shell_append in
+-  yes)
+-    cat << \_LT_EOF >> "$cfgfile"
+-
 -# func_append var value
 -# Append VALUE to the end of shell variable VAR.
 -func_append ()
@@ -12037,10 +12118,10 @@
 +_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd],
 +         [0], [convert $build files to toolchain format])dnl
 +])# _LT_PATH_CONVERSION_FUNCTIONS
-diff --git a/ltmain.sh b/ltmain.sh
-index 9503ec85d7..70e856e065 100644
---- a/ltmain.sh
-+++ b/ltmain.sh
+Index: git/ltmain.sh
+===================================================================
+--- git.orig/ltmain.sh
++++ git/ltmain.sh
 @@ -1,10 +1,9 @@
 -# Generated from ltmain.m4sh.
  
@@ -12470,31 +12551,7 @@
 +$progname: of $PACKAGE $VERSION and run autoconf again.
 +_LT_EOF
 +    fi
- 
--  # Shorthand for --mode=foo, only valid as the first argument
--  case $1 in
--  clean|clea|cle|cl)
--    shift; set dummy --mode clean ${1+"$@"}; shift
--    ;;
--  compile|compil|compi|comp|com|co|c)
--    shift; set dummy --mode compile ${1+"$@"}; shift
--    ;;
--  execute|execut|execu|exec|exe|ex|e)
--    shift; set dummy --mode execute ${1+"$@"}; shift
--    ;;
--  finish|finis|fini|fin|fi|f)
--    shift; set dummy --mode finish ${1+"$@"}; shift
--    ;;
--  install|instal|insta|inst|ins|in|i)
--    shift; set dummy --mode install ${1+"$@"}; shift
--    ;;
--  link|lin|li|l)
--    shift; set dummy --mode link ${1+"$@"}; shift
--    ;;
--  uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u)
--    shift; set dummy --mode uninstall ${1+"$@"}; shift
--    ;;
--  esac
++
 +    exit $EXIT_MISMATCH
 +  fi
 +}
@@ -12524,9 +12581,7 @@
 +  shift; set dummy --mode uninstall ${1+"$@"}; shift
 +  ;;
 +esac
- 
--  # Parse non-mode specific arguments:
--  while test "$#" -gt 0; do
++
 +
 +
 +# Option defaults:
@@ -12542,8 +12597,34 @@
 +opt_verbose=:
 +opt_silent=false
 +opt_verbose=false
-+
-+
+ 
+-  # Shorthand for --mode=foo, only valid as the first argument
+-  case $1 in
+-  clean|clea|cle|cl)
+-    shift; set dummy --mode clean ${1+"$@"}; shift
+-    ;;
+-  compile|compil|compi|comp|com|co|c)
+-    shift; set dummy --mode compile ${1+"$@"}; shift
+-    ;;
+-  execute|execut|execu|exec|exe|ex|e)
+-    shift; set dummy --mode execute ${1+"$@"}; shift
+-    ;;
+-  finish|finis|fini|fin|fi|f)
+-    shift; set dummy --mode finish ${1+"$@"}; shift
+-    ;;
+-  install|instal|insta|inst|ins|in|i)
+-    shift; set dummy --mode install ${1+"$@"}; shift
+-    ;;
+-  link|lin|li|l)
+-    shift; set dummy --mode link ${1+"$@"}; shift
+-    ;;
+-  uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u)
+-    shift; set dummy --mode uninstall ${1+"$@"}; shift
+-    ;;
+-  esac
+ 
+-  # Parse non-mode specific arguments:
+-  while test "$#" -gt 0; do
 +# Parse options once, thoroughly.  This comes as soon as possible in the
 +# script to make things like `--version' happen as quickly as we can.
 +{
@@ -12787,13 +12868,13 @@
 -  fi
 -}
 -
-+    # Darwin sucks
-+    eval std_shrext=\"$shrext_cmds\"
- 
+-
 -## ----------- ##
 -##    Main.    ##
 -## ----------- ##
--
++    # Darwin sucks
++    eval std_shrext=\"$shrext_cmds\"
+ 
 -$opt_help || {
 -  # Sanity checks first:
 -  func_check_version_match
@@ -13514,7 +13595,7 @@
        "")
          # Generic help is extracted from the usage comments
          # at the start of this file.
-@@ -1659,8 +2327,8 @@ This mode accepts the following additional options:
+@@ -1659,8 +2327,8 @@ This mode accepts the following addition
  
    -o OUTPUT-FILE    set the output file name to OUTPUT-FILE
    -no-suppress      do not suppress compiler output for multiple passes
@@ -13525,7 +13606,7 @@
    -shared           do not build a \`.o' file suitable for static linking
    -static           only build a \`.o' file suitable for static linking
    -Wc,FLAG          pass FLAG directly to the compiler
-@@ -1804,7 +2472,7 @@ Otherwise, only FILE itself is deleted using RM."
+@@ -1804,7 +2472,7 @@ Otherwise, only FILE itself is deleted u
          ;;
  
        *)
@@ -13627,7 +13708,7 @@
 +    do
 +      if test -d "$opt"; then
 +	func_append libdirs " $opt"
- 
++
 +      elif test -f "$opt"; then
 +	if func_lalib_unsafe_p "$opt"; then
 +	  func_append libs " $opt"
@@ -13647,7 +13728,7 @@
 +      else
 +        sysroot_cmd=
 +      fi
-+
+ 
 +      # Remove sysroot references
 +      if $opt_dry_run; then
 +        for lib in $libs; do
@@ -14059,7 +14140,7 @@
  lt_${my_prefix}_LTX_preloaded_symbols[] =
  {\
    { \"$my_originator\", (void *) 0 },"
-@@ -2736,7 +3493,7 @@ static const void *lt_preloaded_setup() {
+@@ -2736,7 +3493,7 @@ static const void *lt_preloaded_setup()
  	for arg in $LTCFLAGS; do
  	  case $arg in
  	  -pie | -fpie | -fPIE) ;;
@@ -14588,7 +14669,7 @@
  */
  EOF
  	    cat <<"EOF"
-@@ -3462,22 +4272,13 @@ int setenv (const char *, const char *, int);
+@@ -3462,22 +4272,13 @@ int setenv (const char *, const char *,
    if (stale) { free ((void *) stale); stale = 0; } \
  } while (0)
  
@@ -14615,7 +14696,7 @@
  
  void *xmalloc (size_t num);
  char *xstrdup (const char *string);
-@@ -3487,7 +4288,10 @@ char *chase_symlinks (const char *pathspec);
+@@ -3487,7 +4288,10 @@ char *chase_symlinks (const char *pathsp
  int make_executable (const char *path);
  int check_executable (const char *path);
  char *strendzap (char *str, const char *pat);
@@ -14943,7 +15024,7 @@
    vfprintf (stderr, message, ap);
    fprintf (stderr, ".\n");
  
-@@ -3988,20 +4832,32 @@ lt_error_core (int exit_status, const char *mode,
+@@ -3988,20 +4832,32 @@ lt_error_core (int exit_status, const ch
  }
  
  void
@@ -14981,7 +15062,7 @@
    {
  #ifdef HAVE_SETENV
      /* always make a copy, for consistency with !HAVE_SETENV */
-@@ -4049,9 +4905,9 @@ lt_extend_str (const char *orig_value, const char *add, int to_end)
+@@ -4049,9 +4905,9 @@ lt_extend_str (const char *orig_value, c
  void
  lt_update_exe_path (const char *name, const char *value)
  {
@@ -14994,7 +15075,7 @@
  
    if (name && *name && value && *value)
      {
-@@ -4070,9 +4926,9 @@ lt_update_exe_path (const char *name, const char *value)
+@@ -4070,9 +4926,9 @@ lt_update_exe_path (const char *name, co
  void
  lt_update_lib_path (const char *name, const char *value)
  {
@@ -17267,10 +17348,10 @@
  
  if test -n "$exec_cmd"; then
    eval exec "$exec_cmd"
-diff --git a/ltoptions.m4 b/ltoptions.m4
-index 5ef12ced2a..17cfd51c0b 100644
---- a/ltoptions.m4
-+++ b/ltoptions.m4
+Index: git/ltoptions.m4
+===================================================================
+--- git.orig/ltoptions.m4
++++ git/ltoptions.m4
 @@ -8,7 +8,7 @@
  # unlimited permission to copy and/or distribute it, with or without
  # modifications, as long as this notice is preserved.
@@ -17280,10 +17361,10 @@
  
  # This is to help aclocal find these macros, as it can't see m4_define.
  AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
-diff --git a/ltversion.m4 b/ltversion.m4
-index bf87f77132..9c7b5d4118 100644
---- a/ltversion.m4
-+++ b/ltversion.m4
+Index: git/ltversion.m4
+===================================================================
+--- git.orig/ltversion.m4
++++ git/ltversion.m4
 @@ -7,17 +7,17 @@
  # unlimited permission to copy and/or distribute it, with or without
  # modifications, as long as this notice is preserved.
@@ -17308,10 +17389,10 @@
  _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
  _LT_DECL(, macro_revision, 0)
  ])
-diff --git a/lt~obsolete.m4 b/lt~obsolete.m4
-index bf92b5e079..c573da90c5 100644
---- a/lt~obsolete.m4
-+++ b/lt~obsolete.m4
+Index: git/lt~obsolete.m4
+===================================================================
+--- git.orig/lt~obsolete.m4
++++ git/lt~obsolete.m4
 @@ -7,7 +7,7 @@
  # unlimited permission to copy and/or distribute it, with or without
  # modifications, as long as this notice is preserved.
@@ -17321,11 +17402,11 @@
  
  # These exist entirely to fool aclocal when bootstrapping libtool.
  #
-diff --git a/opcodes/configure b/opcodes/configure
-index 4f29887098..2127d39288 100755
---- a/opcodes/configure
-+++ b/opcodes/configure
-@@ -650,6 +650,9 @@ OTOOL
+Index: git/opcodes/configure
+===================================================================
+--- git.orig/opcodes/configure
++++ git/opcodes/configure
+@@ -681,6 +681,9 @@ OTOOL
  LIPO
  NMEDIT
  DSYMUTIL
@@ -17335,7 +17416,7 @@
  OBJDUMP
  LN_S
  NM
-@@ -763,6 +766,7 @@ enable_static
+@@ -799,6 +802,7 @@ enable_static
  with_pic
  enable_fast_install
  with_gnu_ld
@@ -17343,7 +17424,7 @@
  enable_libtool_lock
  enable_targets
  enable_werror
-@@ -1423,6 +1427,8 @@ Optional Packages:
+@@ -1463,6 +1467,8 @@ Optional Packages:
    --with-pic              try to use only PIC/non-PIC objects [default=use
                            both]
    --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
@@ -17352,7 +17433,7 @@
  
  Some influential environment variables:
    CC          C compiler command
-@@ -5115,8 +5121,8 @@ esac
+@@ -5404,8 +5410,8 @@ esac
  
  
  
@@ -17363,7 +17444,7 @@
  
  
  
-@@ -5156,7 +5162,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
+@@ -5445,7 +5451,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
  $as_echo_n "checking how to print strings... " >&6; }
  # Test print first, because it will be a builtin if present.
@@ -17372,7 +17453,7 @@
     test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
    ECHO='print -r --'
  elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
-@@ -5842,8 +5848,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
+@@ -6131,8 +6137,8 @@ $as_echo_n "checking whether the shell u
  # Try some XSI features
  xsi_shell=no
  ( _lt_dummy="a/b/c"
@@ -17383,13 +17464,13 @@
      && eval 'test $(( 1 + 1 )) -eq 2 \
      && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
    && xsi_shell=yes
-@@ -5892,6 +5898,80 @@ esac
+@@ -6181,6 +6187,80 @@ esac
  
  
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
 +$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
-+if test "${lt_cv_to_host_file_cmd+set}" = set; then :
++if ${lt_cv_to_host_file_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  case $host in
@@ -17436,7 +17517,7 @@
 +
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
 +$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
-+if test "${lt_cv_to_tool_file_cmd+set}" = set; then :
++if ${lt_cv_to_tool_file_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  #assume ordinary cross tools, or native build.
@@ -17463,8 +17544,8 @@
 +
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
  $as_echo_n "checking for $LD option to reload object files... " >&6; }
- if test "${lt_cv_ld_reload_flag+set}" = set; then :
-@@ -5908,6 +5988,11 @@ case $reload_flag in
+ if ${lt_cv_ld_reload_flag+:} false; then :
+@@ -6197,6 +6277,11 @@ case $reload_flag in
  esac
  reload_cmds='$LD$reload_flag -o $output$reload_objs'
  case $host_os in
@@ -17476,7 +17557,7 @@
    darwin*)
      if test "$GCC" = yes; then
        reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
-@@ -6076,7 +6161,8 @@ mingw* | pw32*)
+@@ -6365,7 +6450,8 @@ mingw* | pw32*)
      lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
      lt_cv_file_magic_cmd='func_win32_libid'
    else
@@ -17486,7 +17567,7 @@
      lt_cv_file_magic_cmd='$OBJDUMP -f'
    fi
    ;;
-@@ -6230,6 +6316,21 @@ esac
+@@ -6519,6 +6605,21 @@ esac
  fi
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
  $as_echo "$lt_cv_deplibs_check_method" >&6; }
@@ -17508,7 +17589,7 @@
  file_magic_cmd=$lt_cv_file_magic_cmd
  deplibs_check_method=$lt_cv_deplibs_check_method
  test -z "$deplibs_check_method" && deplibs_check_method=unknown
-@@ -6243,11 +6344,164 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
+@@ -6534,9 +6635,162 @@ test -z "$deplibs_check_method" && depli
  
  
  
@@ -17522,8 +17603,6 @@
 +
 +
 +
- 
- 
  if test -n "$ac_tool_prefix"; then
 -  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
 -set dummy ${ac_tool_prefix}ar; ac_word=$2
@@ -17531,7 +17610,7 @@
 +set dummy ${ac_tool_prefix}dlltool; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
++if ${ac_cv_prog_DLLTOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$DLLTOOL"; then
@@ -17543,7 +17622,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -17571,7 +17650,7 @@
 +set dummy dlltool; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
++if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$ac_ct_DLLTOOL"; then
@@ -17583,7 +17662,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_ac_ct_DLLTOOL="dlltool"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -17631,7 +17710,7 @@
 +
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
 +$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
-+if test "${lt_cv_sharedlib_from_linklib_cmd+set}" = set; then :
++if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_sharedlib_from_linklib_cmd='unknown'
@@ -17674,17 +17753,17 @@
 +set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
- if test "${ac_cv_prog_AR+set}" = set; then :
-@@ -6263,7 +6517,7 @@ do
+ if ${ac_cv_prog_AR+:} false; then :
+@@ -6552,7 +6806,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
-   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 -    ac_cv_prog_AR="${ac_tool_prefix}ar"
 +    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6283,11 +6537,15 @@ $as_echo "no" >&6; }
+@@ -6572,11 +6826,15 @@ $as_echo "no" >&6; }
  fi
  
  
@@ -17702,17 +17781,17 @@
 +set dummy $ac_prog; ac_word=$2
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
- if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
-@@ -6303,7 +6561,7 @@ do
+ if ${ac_cv_prog_ac_ct_AR+:} false; then :
+@@ -6592,7 +6850,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
-   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 -    ac_cv_prog_ac_ct_AR="ar"
 +    ac_cv_prog_ac_ct_AR="$ac_prog"
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6322,6 +6580,10 @@ else
+@@ -6611,6 +6869,10 @@ else
  $as_echo "no" >&6; }
  fi
  
@@ -17723,7 +17802,7 @@
    if test "x$ac_ct_AR" = x; then
      AR="false"
    else
-@@ -6333,16 +6595,72 @@ ac_tool_warned=yes ;;
+@@ -6622,12 +6884,11 @@ ac_tool_warned=yes ;;
  esac
      AR=$ac_ct_AR
    fi
@@ -17736,19 +17815,16 @@
 +: ${AR=ar}
 +: ${AR_FLAGS=cru}
 +
-+
-+
-+
-+
-+
-+
-+
-+
-+
-+
+ 
+ 
+ 
+@@ -6638,6 +6899,63 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
+ 
+ 
+ 
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
 +$as_echo_n "checking for archiver @FILE support... " >&6; }
-+if test "${lt_cv_ar_at_file+set}" = set; then :
++if ${lt_cv_ar_at_file+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_ar_at_file=no
@@ -17758,7 +17834,7 @@
 +int
 +main ()
 +{
- 
++
 +  ;
 +  return 0;
 +}
@@ -17784,23 +17860,29 @@
 +        fi
 +      fi
 +      rm -f conftest.* libconftest.a
- 
++
 +fi
 +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- 
++
 +fi
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
 +$as_echo "$lt_cv_ar_at_file" >&6; }
- 
++
 +if test "x$lt_cv_ar_at_file" = xno; then
 +  archiver_list_spec=
 +else
 +  archiver_list_spec=$lt_cv_ar_at_file
 +fi
++
++
++
++
++
++
  
- 
- 
-@@ -6684,8 +7002,8 @@ esac
+ if test -n "$ac_tool_prefix"; then
+   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
+@@ -6973,8 +7291,8 @@ esac
  lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
  
  # Transform an extracted symbol line into symbol name and symbol address
@@ -17811,7 +17893,7 @@
  
  # Handle CRLF in mingw tool chain
  opt_cr=
-@@ -6721,6 +7039,7 @@ for ac_symprfx in "" "_"; do
+@@ -7010,6 +7328,7 @@ for ac_symprfx in "" "_"; do
    else
      lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[	 ]\($symcode$symcode*\)[	 ][	 ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
    fi
@@ -17819,7 +17901,7 @@
  
    # Check to see that the pipe works correctly.
    pipe_works=no
-@@ -6762,6 +7081,18 @@ _LT_EOF
+@@ -7051,6 +7370,18 @@ _LT_EOF
        if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
  	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
  	  cat <<_LT_EOF > conftest.$ac_ext
@@ -17838,7 +17920,7 @@
  #ifdef __cplusplus
  extern "C" {
  #endif
-@@ -6773,7 +7104,7 @@ _LT_EOF
+@@ -7062,7 +7393,7 @@ _LT_EOF
  	  cat <<_LT_EOF >> conftest.$ac_ext
  
  /* The mapping between symbol names and symbols.  */
@@ -17847,7 +17929,7 @@
    const char *name;
    void       *address;
  }
-@@ -6799,8 +7130,8 @@ static const void *lt_preloaded_setup() {
+@@ -7088,8 +7419,8 @@ static const void *lt_preloaded_setup()
  _LT_EOF
  	  # Now try linking the two files.
  	  mv conftest.$ac_objext conftstm.$ac_objext
@@ -17858,7 +17940,7 @@
  	  LIBS="conftstm.$ac_objext"
  	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
  	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
-@@ -6810,8 +7141,8 @@ _LT_EOF
+@@ -7099,8 +7430,8 @@ _LT_EOF
    test $ac_status = 0; } && test -s conftest${ac_exeext}; then
  	    pipe_works=yes
  	  fi
@@ -17869,7 +17951,7 @@
  	else
  	  echo "cannot find nm_test_func in $nlist" >&5
  	fi
-@@ -6848,6 +7179,16 @@ else
+@@ -7137,6 +7468,14 @@ else
  $as_echo "ok" >&6; }
  fi
  
@@ -17881,12 +17963,10 @@
 +fi
 +
 +
-+
-+
  
  
  
-@@ -6864,6 +7205,45 @@ fi
+@@ -7158,6 +7497,47 @@ fi
  
  
  
@@ -17894,9 +17974,6 @@
 +
 +
 +
-+
-+
-+
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
 +$as_echo_n "checking for sysroot... " >&6; }
 +
@@ -17923,16 +18000,21 @@
 + *)
 +   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libtool_sysroot}" >&5
 +$as_echo "${with_libtool_sysroot}" >&6; }
-+   as_fn_error "The sysroot must be an absolute path." "$LINENO" 5
++   as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
 +   ;;
 +esac
 +
 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
 +$as_echo "${lt_sysroot:-no}" >&6; }
- 
- 
- 
-@@ -7075,6 +7455,123 @@ esac
++
++
++
++
++
+ # Check whether --enable-libtool-lock was given.
+ if test "${enable_libtool_lock+set}" = set; then :
+   enableval=$enable_libtool_lock;
+@@ -7364,6 +7744,123 @@ esac
  
  need_locks="$enable_libtool_lock"
  
@@ -17941,7 +18023,7 @@
 +set dummy ${ac_tool_prefix}mt; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_MANIFEST_TOOL+set}" = set; then :
++if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$MANIFEST_TOOL"; then
@@ -17953,7 +18035,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -17981,7 +18063,7 @@
 +set dummy mt; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_ac_ct_MANIFEST_TOOL+set}" = set; then :
++if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$ac_ct_MANIFEST_TOOL"; then
@@ -17993,7 +18075,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -18031,7 +18113,7 @@
 +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
 +$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
-+if test "${lt_cv_path_mainfest_tool+set}" = set; then :
++if ${lt_cv_path_mainfest_tool+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_path_mainfest_tool=no
@@ -18056,7 +18138,7 @@
  
    case $host_os in
      rhapsody* | darwin*)
-@@ -7638,6 +8135,8 @@ _LT_EOF
+@@ -7927,6 +8424,8 @@ _LT_EOF
        $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
        echo "$AR cru libconftest.a conftest.o" >&5
        $AR cru libconftest.a conftest.o 2>&5
@@ -18065,7 +18147,7 @@
        cat > conftest.c << _LT_EOF
  int main() { return 0;}
  _LT_EOF
-@@ -7803,7 +8302,8 @@ fi
+@@ -8092,7 +8591,8 @@ fi
  LIBTOOL_DEPS="$ltmain"
  
  # Always use our own libtool.
@@ -18075,7 +18157,7 @@
  
  
  
-@@ -7892,7 +8392,7 @@ aix3*)
+@@ -8181,7 +8681,7 @@ aix3*)
  esac
  
  # Global variables:
@@ -18084,7 +18166,7 @@
  can_build_shared=yes
  
  # All known linkers require a `.a' archive for static linking (except MSVC,
-@@ -8190,8 +8690,6 @@ fi
+@@ -8479,8 +8979,6 @@ fi
  lt_prog_compiler_pic=
  lt_prog_compiler_static=
  
@@ -18093,7 +18175,7 @@
  
    if test "$GCC" = yes; then
      lt_prog_compiler_wl='-Wl,'
-@@ -8357,6 +8855,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8646,6 +9144,12 @@ $as_echo_n "checking for $compiler optio
  	lt_prog_compiler_pic='--shared'
  	lt_prog_compiler_static='--static'
  	;;
@@ -18106,7 +18188,7 @@
        pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
          # Portland Group compilers (*not* the Pentium gcc compiler,
  	# which looks to be a dead project)
-@@ -8419,7 +8923,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8708,7 +9212,7 @@ $as_echo_n "checking for $compiler optio
        lt_prog_compiler_pic='-KPIC'
        lt_prog_compiler_static='-Bstatic'
        case $cc_basename in
@@ -18115,7 +18197,7 @@
  	lt_prog_compiler_wl='-Qoption ld ';;
        *)
  	lt_prog_compiler_wl='-Wl,';;
-@@ -8476,13 +8980,17 @@ case $host_os in
+@@ -8765,13 +9269,17 @@ case $host_os in
      lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
      ;;
  esac
@@ -18128,7 +18210,7 @@
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-+if test "${lt_cv_prog_compiler_pic+set}" = set; then :
++if ${lt_cv_prog_compiler_pic+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
@@ -18139,7 +18221,7 @@
  
  #
  # Check to make sure the PIC flag actually works.
-@@ -8543,6 +9051,11 @@ fi
+@@ -8832,6 +9340,11 @@ fi
  
  
  
@@ -18151,7 +18233,7 @@
  #
  # Check to make sure the static flag actually works.
  #
-@@ -8893,7 +9406,8 @@ _LT_EOF
+@@ -9182,7 +9695,8 @@ _LT_EOF
        allow_undefined_flag=unsupported
        always_export_symbols=no
        enable_shared_with_static_runtimes=yes
@@ -18161,7 +18243,7 @@
  
        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
          archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-@@ -8992,12 +9506,12 @@ _LT_EOF
+@@ -9281,12 +9795,12 @@ _LT_EOF
  	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
  	  hardcode_libdir_flag_spec=
  	  hardcode_libdir_flag_spec_ld='-rpath $libdir'
@@ -18176,7 +18258,7 @@
  	  fi
  	  ;;
  	esac
-@@ -9011,8 +9525,8 @@ _LT_EOF
+@@ -9300,8 +9814,8 @@ _LT_EOF
  	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
  	wlarc=
        else
@@ -18187,7 +18269,7 @@
        fi
        ;;
  
-@@ -9030,8 +9544,8 @@ _LT_EOF
+@@ -9319,8 +9833,8 @@ _LT_EOF
  
  _LT_EOF
        elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -18198,7 +18280,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9077,8 +9591,8 @@ _LT_EOF
+@@ -9366,8 +9880,8 @@ _LT_EOF
  
      *)
        if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -18209,7 +18291,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9208,7 +9722,13 @@ _LT_EOF
+@@ -9497,7 +10011,13 @@ _LT_EOF
  	allow_undefined_flag='-berok'
          # Determine the default libpath from the value encoded in an
          # empty executable.
@@ -18217,14 +18299,14 @@
 +        if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  if ${lt_cv_aix_libpath_+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  /* end confdefs.h.  */
  
  int
-@@ -9221,22 +9741,29 @@ main ()
+@@ -9510,22 +10030,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -18267,7 +18349,7 @@
  
          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
          archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
-@@ -9248,7 +9775,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9537,7 +10064,13 @@ if test -z "$aix_libpath"; then aix_libp
  	else
  	 # Determine the default libpath from the value encoded in an
  	 # empty executable.
@@ -18275,14 +18357,14 @@
 +	 if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  if ${lt_cv_aix_libpath_+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  /* end confdefs.h.  */
  
  int
-@@ -9261,22 +9794,29 @@ main ()
+@@ -9550,22 +10083,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -18325,7 +18407,7 @@
  
  	 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
  	  # Warning - without using the other run time loading flags,
-@@ -9321,20 +9861,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9610,20 +10150,63 @@ if test -z "$aix_libpath"; then aix_libp
        # Microsoft Visual C++.
        # hardcode_libdir_flag_spec is actually meaningless, as there is
        # no search path for DLLs.
@@ -18403,7 +18485,7 @@
        ;;
  
      darwin* | rhapsody*)
-@@ -9395,7 +9978,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9684,7 +10267,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
      freebsd* | dragonfly*)
@@ -18412,7 +18494,7 @@
        hardcode_libdir_flag_spec='-R$libdir'
        hardcode_direct=yes
        hardcode_shlibpath_var=no
-@@ -9403,7 +9986,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9692,7 +10275,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      hpux9*)
        if test "$GCC" = yes; then
@@ -18421,7 +18503,7 @@
        else
  	archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
        fi
-@@ -9419,7 +10002,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9708,7 +10291,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      hpux10*)
        if test "$GCC" = yes && test "$with_gnu_ld" = no; then
@@ -18430,7 +18512,7 @@
        else
  	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
        fi
-@@ -9443,10 +10026,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9732,10 +10315,10 @@ if test -z "$aix_libpath"; then aix_libp
  	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  	  ;;
  	ia64*)
@@ -18443,7 +18525,7 @@
  	  ;;
  	esac
        else
-@@ -9525,23 +10108,36 @@ fi
+@@ -9814,23 +10397,36 @@ fi
  
      irix5* | irix6* | nonstopux*)
        if test "$GCC" = yes; then
@@ -18458,7 +18540,7 @@
 +	# This should be the same for all languages, so no per-tag cache variable.
 +	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
 +$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
-+if test "${lt_cv_irix_exported_symbol+set}" = set; then :
++if ${lt_cv_irix_exported_symbol+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  save_LDFLAGS="$LDFLAGS"
@@ -18488,7 +18570,7 @@
        else
  	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
  	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
-@@ -9626,7 +10222,7 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -9915,7 +10511,7 @@ rm -f core conftest.err conftest.$ac_obj
      osf4* | osf5*)	# as osf3* with the addition of -msym flag
        if test "$GCC" = yes; then
  	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
@@ -18497,7 +18579,7 @@
  	hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
        else
  	allow_undefined_flag=' -expect_unresolved \*'
-@@ -9645,9 +10241,9 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -9934,9 +10530,9 @@ rm -f core conftest.err conftest.$ac_obj
        no_undefined_flag=' -z defs'
        if test "$GCC" = yes; then
  	wlarc='${wl}'
@@ -18509,7 +18591,7 @@
        else
  	case `$CC -V 2>&1` in
  	*"Compilers 5.0"*)
-@@ -10223,8 +10819,9 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10512,8 +11108,9 @@ cygwin* | mingw* | pw32* | cegcc*)
    need_version=no
    need_lib_prefix=no
  
@@ -18521,7 +18603,7 @@
      library_names_spec='$libname.dll.a'
      # DLL is installed to $(libdir)/../bin by postinstall_cmds
      postinstall_cmds='base_file=`basename \${file}`~
-@@ -10257,13 +10854,71 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10546,13 +11143,71 @@ cygwin* | mingw* | pw32* | cegcc*)
        library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
        ;;
      esac
@@ -18594,7 +18676,7 @@
    # FIXME: first we should search . and the directory the executable is in
    shlibpath_var=PATH
    ;;
-@@ -10355,7 +11010,7 @@ haiku*)
+@@ -10644,7 +11299,7 @@ haiku*)
    soname_spec='${libname}${release}${shared_ext}$major'
    shlibpath_var=LIBRARY_PATH
    shlibpath_overrides_runpath=yes
@@ -18603,7 +18685,16 @@
    hardcode_into_libs=yes
    ;;
  
-@@ -11195,10 +11850,10 @@ else
+@@ -11440,7 +12095,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11443 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11484,10 +12139,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -18616,7 +18707,16 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -11301,10 +11956,10 @@ else
+@@ -11546,7 +12201,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11549 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11590,10 +12245,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -18629,7 +18729,7 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -12543,7 +13198,7 @@ if test "$enable_shared" = "yes"; then
+@@ -12831,7 +13486,7 @@ if test "$enable_shared" = "yes"; then
  # since libbfd may not pull in the entirety of libiberty.
    x=`sed -n -e 's/^[ 	]*PICFLAG[ 	]*=[ 	]*//p' < ../libiberty/Makefile | sed -n '$p'`
    if test -n "$x"; then
@@ -18638,7 +18738,7 @@
    fi
  
    case "${host}" in
-@@ -13520,13 +14175,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
+@@ -13807,13 +14462,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_
  lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
  lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
  lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
@@ -18659,7 +18759,7 @@
  STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
  RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
  old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-@@ -13541,14 +14203,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
+@@ -13828,14 +14490,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$l
  lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
@@ -18678,7 +18778,7 @@
  DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
  NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
  LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-@@ -13581,12 +14246,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
+@@ -13868,12 +14533,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcod
  hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
  inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
  link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
@@ -18692,7 +18792,7 @@
  file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
  variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
  need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-@@ -13641,8 +14306,13 @@ reload_flag \
+@@ -13928,8 +14593,13 @@ reload_flag \
  OBJDUMP \
  deplibs_check_method \
  file_magic_cmd \
@@ -18706,7 +18806,7 @@
  STRIP \
  RANLIB \
  CC \
-@@ -13652,12 +14322,14 @@ lt_cv_sys_global_symbol_pipe \
+@@ -13939,12 +14609,14 @@ lt_cv_sys_global_symbol_pipe \
  lt_cv_sys_global_symbol_to_cdecl \
  lt_cv_sys_global_symbol_to_c_name_address \
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
@@ -18722,7 +18822,7 @@
  DSYMUTIL \
  NMEDIT \
  LIPO \
-@@ -13673,7 +14345,6 @@ no_undefined_flag \
+@@ -13960,7 +14632,6 @@ no_undefined_flag \
  hardcode_libdir_flag_spec \
  hardcode_libdir_flag_spec_ld \
  hardcode_libdir_separator \
@@ -18730,7 +18830,7 @@
  exclude_expsyms \
  include_expsyms \
  file_list_spec \
-@@ -13709,6 +14380,7 @@ module_cmds \
+@@ -13996,6 +14667,7 @@ module_cmds \
  module_expsym_cmds \
  export_symbols_cmds \
  prelink_cmds \
@@ -18738,7 +18838,7 @@
  postinstall_cmds \
  postuninstall_cmds \
  finish_cmds \
-@@ -14465,7 +15137,8 @@ $as_echo X"$file" |
+@@ -14761,7 +15433,8 @@ $as_echo X"$file" |
  # NOTE: Changes made to this file will be lost: look at ltmain.sh.
  #
  #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
@@ -18748,7 +18848,7 @@
  #   Written by Gordon Matzigkeit, 1996
  #
  #   This file is part of GNU Libtool.
-@@ -14568,19 +15241,42 @@ SP2NL=$lt_lt_SP2NL
+@@ -14864,19 +15537,42 @@ SP2NL=$lt_lt_SP2NL
  # turn newlines into spaces.
  NL2SP=$lt_lt_NL2SP
  
@@ -18792,7 +18892,7 @@
  # A symbol stripping program.
  STRIP=$lt_STRIP
  
-@@ -14610,6 +15306,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
+@@ -14906,6 +15602,12 @@ global_symbol_to_c_name_address=$lt_lt_c
  # Transform the output of nm in a C name address pair when lib prefix is needed.
  global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
  
@@ -18805,7 +18905,7 @@
  # The name of the directory that contains temporary libtool files.
  objdir=$objdir
  
-@@ -14619,6 +15321,9 @@ MAGIC_CMD=$MAGIC_CMD
+@@ -14915,6 +15617,9 @@ MAGIC_CMD=$MAGIC_CMD
  # Must we lock files when doing compilation?
  need_locks=$lt_need_locks
  
@@ -18815,7 +18915,7 @@
  # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
  DSYMUTIL=$lt_DSYMUTIL
  
-@@ -14733,12 +15438,12 @@ with_gcc=$GCC
+@@ -15029,12 +15734,12 @@ with_gcc=$GCC
  # Compiler flag to turn off builtin functions.
  no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
  
@@ -18831,7 +18931,7 @@
  # Compiler flag to prevent dynamic linking.
  link_static_flag=$lt_lt_prog_compiler_static
  
-@@ -14825,9 +15530,6 @@ inherit_rpath=$inherit_rpath
+@@ -15121,9 +15826,6 @@ inherit_rpath=$inherit_rpath
  # Whether libtool must link a program against all its dependency libraries.
  link_all_deplibs=$link_all_deplibs
  
@@ -18841,7 +18941,7 @@
  # Set to "yes" if exported symbols are required.
  always_export_symbols=$always_export_symbols
  
-@@ -14843,6 +15545,9 @@ include_expsyms=$lt_include_expsyms
+@@ -15139,6 +15841,9 @@ include_expsyms=$lt_include_expsyms
  # Commands necessary for linking programs (against libraries) with templates.
  prelink_cmds=$lt_prelink_cmds
  
@@ -18851,7 +18951,7 @@
  # Specify filename containing input files.
  file_list_spec=$lt_file_list_spec
  
-@@ -14875,210 +15580,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
+@@ -15171,210 +15876,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
    # if finds mixed CR/LF and LF-only lines.  Since sed operates in
    # text mode, it properly converts lines to CR/LF.  This bash problem
    # is reportedly fixed, but why not run on old versions too?
@@ -19053,15 +19153,9 @@
 -_LT_EOF
 -    ;;
 -  esac
--
--
--  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
--    || (rm -f "$cfgfile"; exit 1)
--
--  mv -f "$cfgfile" "$ofile" ||
 +  sed '$q' "$ltmain" >> "$cfgfile" \
 +     || (rm -f "$cfgfile"; exit 1)
-+
+ 
 +  if test x"$xsi_shell" = xyes; then
 +  sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
 +func_dirname ()\
@@ -19219,17 +19313,20 @@
 +  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
 +$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
 +fi
-+
-+
+ 
+-  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
+-    || (rm -f "$cfgfile"; exit 1)
+ 
+-  mv -f "$cfgfile" "$ofile" ||
 +   mv -f "$cfgfile" "$ofile" ||
      (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
    chmod +x "$ofile"
  
-diff --git a/opcodes/configure.ac b/opcodes/configure.ac
-index b07f3f3629..5a32d9b1fc 100644
---- a/opcodes/configure.ac
-+++ b/opcodes/configure.ac
-@@ -167,7 +167,7 @@ changequote(,)dnl
+Index: git/opcodes/configure.ac
+===================================================================
+--- git.orig/opcodes/configure.ac
++++ git/opcodes/configure.ac
+@@ -166,7 +166,7 @@ changequote(,)dnl
    x=`sed -n -e 's/^[ 	]*PICFLAG[ 	]*=[ 	]*//p' < ../libiberty/Makefile | sed -n '$p'`
  changequote([,])dnl
    if test -n "$x"; then
@@ -19238,11 +19335,11 @@
    fi
  
    case "${host}" in
-diff --git a/zlib/configure b/zlib/configure
-index dc2d9ed383..ed9a492f5c 100755
---- a/zlib/configure
-+++ b/zlib/configure
-@@ -614,8 +614,11 @@ OTOOL
+Index: git/zlib/configure
+===================================================================
+--- git.orig/zlib/configure
++++ git/zlib/configure
+@@ -646,8 +646,11 @@ OTOOL
  LIPO
  NMEDIT
  DSYMUTIL
@@ -19254,7 +19351,7 @@
  OBJDUMP
  LN_S
  NM
-@@ -737,6 +740,7 @@ enable_static
+@@ -774,6 +777,7 @@ enable_static
  with_pic
  enable_fast_install
  with_gnu_ld
@@ -19262,7 +19359,7 @@
  enable_libtool_lock
  enable_host_shared
  '
-@@ -1385,6 +1389,8 @@ Optional Packages:
+@@ -1428,6 +1432,8 @@ Optional Packages:
    --with-pic              try to use only PIC/non-PIC objects [default=use
                            both]
    --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
@@ -19271,7 +19368,7 @@
  
  Some influential environment variables:
    CC          C compiler command
-@@ -3910,8 +3916,8 @@ esac
+@@ -4147,8 +4153,8 @@ esac
  
  
  
@@ -19282,7 +19379,7 @@
  
  
  
-@@ -3951,7 +3957,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
+@@ -4188,7 +4194,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
  $as_echo_n "checking how to print strings... " >&6; }
  # Test print first, because it will be a builtin if present.
@@ -19291,7 +19388,7 @@
     test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
    ECHO='print -r --'
  elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
-@@ -4767,8 +4773,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
+@@ -5004,8 +5010,8 @@ $as_echo_n "checking whether the shell u
  # Try some XSI features
  xsi_shell=no
  ( _lt_dummy="a/b/c"
@@ -19302,13 +19399,13 @@
      && eval 'test $(( 1 + 1 )) -eq 2 \
      && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
    && xsi_shell=yes
-@@ -4817,6 +4823,80 @@ esac
+@@ -5054,6 +5060,80 @@ esac
  
  
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
 +$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
-+if test "${lt_cv_to_host_file_cmd+set}" = set; then :
++if ${lt_cv_to_host_file_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  case $host in
@@ -19355,7 +19452,7 @@
 +
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
 +$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
-+if test "${lt_cv_to_tool_file_cmd+set}" = set; then :
++if ${lt_cv_to_tool_file_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  #assume ordinary cross tools, or native build.
@@ -19382,8 +19479,8 @@
 +
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
  $as_echo_n "checking for $LD option to reload object files... " >&6; }
- if test "${lt_cv_ld_reload_flag+set}" = set; then :
-@@ -4833,6 +4913,11 @@ case $reload_flag in
+ if ${lt_cv_ld_reload_flag+:} false; then :
+@@ -5070,6 +5150,11 @@ case $reload_flag in
  esac
  reload_cmds='$LD$reload_flag -o $output$reload_objs'
  case $host_os in
@@ -19395,7 +19492,7 @@
    darwin*)
      if test "$GCC" = yes; then
        reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
-@@ -5001,7 +5086,8 @@ mingw* | pw32*)
+@@ -5238,7 +5323,8 @@ mingw* | pw32*)
      lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
      lt_cv_file_magic_cmd='func_win32_libid'
    else
@@ -19405,7 +19502,7 @@
      lt_cv_file_magic_cmd='$OBJDUMP -f'
    fi
    ;;
-@@ -5155,6 +5241,21 @@ esac
+@@ -5392,6 +5478,21 @@ esac
  fi
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
  $as_echo "$lt_cv_deplibs_check_method" >&6; }
@@ -19427,7 +19524,7 @@
  file_magic_cmd=$lt_cv_file_magic_cmd
  deplibs_check_method=$lt_cv_deplibs_check_method
  test -z "$deplibs_check_method" && deplibs_check_method=unknown
-@@ -5168,11 +5269,165 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
+@@ -5407,9 +5508,163 @@ test -z "$deplibs_check_method" && depli
  
  
  
@@ -19441,8 +19538,6 @@
 +
 +
 +
- 
- 
  if test -n "$ac_tool_prefix"; then
 -  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
 -set dummy ${ac_tool_prefix}ar; ac_word=$2
@@ -19450,7 +19545,7 @@
 +set dummy ${ac_tool_prefix}dlltool; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
++if ${ac_cv_prog_DLLTOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$DLLTOOL"; then
@@ -19462,7 +19557,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -19490,7 +19585,7 @@
 +set dummy dlltool; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
++if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$ac_ct_DLLTOOL"; then
@@ -19502,7 +19597,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_ac_ct_DLLTOOL="dlltool"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -19550,7 +19645,7 @@
 +
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
 +$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
-+if test "${lt_cv_sharedlib_from_linklib_cmd+set}" = set; then :
++if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_sharedlib_from_linklib_cmd='unknown'
@@ -19594,17 +19689,17 @@
 +set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
- if test "${ac_cv_prog_AR+set}" = set; then :
-@@ -5188,7 +5443,7 @@ do
+ if ${ac_cv_prog_AR+:} false; then :
+@@ -5425,7 +5680,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
-   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 -    ac_cv_prog_AR="${ac_tool_prefix}ar"
 +    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -5208,11 +5463,15 @@ $as_echo "no" >&6; }
+@@ -5445,11 +5700,15 @@ $as_echo "no" >&6; }
  fi
  
  
@@ -19622,17 +19717,17 @@
 +set dummy $ac_prog; ac_word=$2
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
- if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
-@@ -5228,7 +5487,7 @@ do
+ if ${ac_cv_prog_ac_ct_AR+:} false; then :
+@@ -5465,7 +5724,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
-   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 -    ac_cv_prog_ac_ct_AR="ar"
 +    ac_cv_prog_ac_ct_AR="$ac_prog"
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -5247,6 +5506,10 @@ else
+@@ -5484,6 +5743,10 @@ else
  $as_echo "no" >&6; }
  fi
  
@@ -19643,7 +19738,7 @@
    if test "x$ac_ct_AR" = x; then
      AR="false"
    else
-@@ -5258,16 +5521,72 @@ ac_tool_warned=yes ;;
+@@ -5495,12 +5758,10 @@ ac_tool_warned=yes ;;
  esac
      AR=$ac_ct_AR
    fi
@@ -19655,20 +19750,16 @@
 -test -z "$AR_FLAGS" && AR_FLAGS=cru
 +: ${AR=ar}
 +: ${AR_FLAGS=cru}
-+
-+
-+
-+
-+
-+
-+
-+
-+
-+
-+
+ 
+ 
+ 
+@@ -5512,6 +5773,64 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
+ 
+ 
+ 
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
 +$as_echo_n "checking for archiver @FILE support... " >&6; }
-+if test "${lt_cv_ar_at_file+set}" = set; then :
++if ${lt_cv_ar_at_file+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_ar_at_file=no
@@ -19678,7 +19769,7 @@
 +int
 +main ()
 +{
- 
++
 +  ;
 +  return 0;
 +}
@@ -19704,23 +19795,30 @@
 +        fi
 +      fi
 +      rm -f conftest.* libconftest.a
- 
++
 +fi
 +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- 
++
 +fi
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
 +$as_echo "$lt_cv_ar_at_file" >&6; }
- 
++
 +if test "x$lt_cv_ar_at_file" = xno; then
 +  archiver_list_spec=
 +else
 +  archiver_list_spec=$lt_cv_ar_at_file
 +fi
- 
- 
- 
-@@ -5609,8 +5928,8 @@ esac
++
++
++
++
++
++
++
+ if test -n "$ac_tool_prefix"; then
+   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
+ set dummy ${ac_tool_prefix}strip; ac_word=$2
+@@ -5846,8 +6165,8 @@ esac
  lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
  
  # Transform an extracted symbol line into symbol name and symbol address
@@ -19731,7 +19829,7 @@
  
  # Handle CRLF in mingw tool chain
  opt_cr=
-@@ -5646,6 +5965,7 @@ for ac_symprfx in "" "_"; do
+@@ -5883,6 +6202,7 @@ for ac_symprfx in "" "_"; do
    else
      lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[	 ]\($symcode$symcode*\)[	 ][	 ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
    fi
@@ -19739,7 +19837,7 @@
  
    # Check to see that the pipe works correctly.
    pipe_works=no
-@@ -5687,6 +6007,18 @@ _LT_EOF
+@@ -5924,6 +6244,18 @@ _LT_EOF
        if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
  	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
  	  cat <<_LT_EOF > conftest.$ac_ext
@@ -19758,7 +19856,7 @@
  #ifdef __cplusplus
  extern "C" {
  #endif
-@@ -5698,7 +6030,7 @@ _LT_EOF
+@@ -5935,7 +6267,7 @@ _LT_EOF
  	  cat <<_LT_EOF >> conftest.$ac_ext
  
  /* The mapping between symbol names and symbols.  */
@@ -19767,7 +19865,7 @@
    const char *name;
    void       *address;
  }
-@@ -5724,8 +6056,8 @@ static const void *lt_preloaded_setup() {
+@@ -5961,8 +6293,8 @@ static const void *lt_preloaded_setup()
  _LT_EOF
  	  # Now try linking the two files.
  	  mv conftest.$ac_objext conftstm.$ac_objext
@@ -19778,7 +19876,7 @@
  	  LIBS="conftstm.$ac_objext"
  	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
  	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
-@@ -5735,8 +6067,8 @@ _LT_EOF
+@@ -5972,8 +6304,8 @@ _LT_EOF
    test $ac_status = 0; } && test -s conftest${ac_exeext}; then
  	    pipe_works=yes
  	  fi
@@ -19789,7 +19887,7 @@
  	else
  	  echo "cannot find nm_test_func in $nlist" >&5
  	fi
-@@ -5773,6 +6105,19 @@ else
+@@ -6010,6 +6342,18 @@ else
  $as_echo "ok" >&6; }
  fi
  
@@ -19805,17 +19903,13 @@
 +
 +
 +
-+
  
  
  
-@@ -5790,6 +6135,41 @@ fi
+@@ -6031,6 +6375,42 @@ fi
  
  
  
-+
-+
-+
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
 +$as_echo_n "checking for sysroot... " >&6; }
 +
@@ -19842,16 +19936,20 @@
 + *)
 +   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libtool_sysroot}" >&5
 +$as_echo "${with_libtool_sysroot}" >&6; }
-+   as_fn_error "The sysroot must be an absolute path." "$LINENO" 5
++   as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
 +   ;;
 +esac
 +
 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
 +$as_echo "${lt_sysroot:-no}" >&6; }
++
++
++
++
  
- 
- 
-@@ -6004,6 +6384,123 @@ esac
+ # Check whether --enable-libtool-lock was given.
+ if test "${enable_libtool_lock+set}" = set; then :
+@@ -6241,6 +6621,123 @@ esac
  
  need_locks="$enable_libtool_lock"
  
@@ -19860,7 +19958,7 @@
 +set dummy ${ac_tool_prefix}mt; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_MANIFEST_TOOL+set}" = set; then :
++if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$MANIFEST_TOOL"; then
@@ -19872,7 +19970,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -19900,7 +19998,7 @@
 +set dummy mt; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
 +$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_ac_ct_MANIFEST_TOOL+set}" = set; then :
++if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test -n "$ac_ct_MANIFEST_TOOL"; then
@@ -19912,7 +20010,7 @@
 +  IFS=$as_save_IFS
 +  test -z "$as_dir" && as_dir=.
 +    for ac_exec_ext in '' $ac_executable_extensions; do
-+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
 +    ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
 +    break 2
@@ -19950,7 +20048,7 @@
 +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
 +$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
-+if test "${lt_cv_path_mainfest_tool+set}" = set; then :
++if ${lt_cv_path_mainfest_tool+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_path_mainfest_tool=no
@@ -19975,7 +20073,7 @@
  
    case $host_os in
      rhapsody* | darwin*)
-@@ -6570,6 +7067,8 @@ _LT_EOF
+@@ -6807,6 +7304,8 @@ _LT_EOF
        $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
        echo "$AR cru libconftest.a conftest.o" >&5
        $AR cru libconftest.a conftest.o 2>&5
@@ -19984,7 +20082,7 @@
        cat > conftest.c << _LT_EOF
  int main() { return 0;}
  _LT_EOF
-@@ -7033,7 +7532,8 @@ fi
+@@ -7269,7 +7768,8 @@ fi
  LIBTOOL_DEPS="$ltmain"
  
  # Always use our own libtool.
@@ -19994,7 +20092,7 @@
  
  
  
-@@ -7122,7 +7622,7 @@ aix3*)
+@@ -7358,7 +7858,7 @@ aix3*)
  esac
  
  # Global variables:
@@ -20003,7 +20101,7 @@
  can_build_shared=yes
  
  # All known linkers require a `.a' archive for static linking (except MSVC,
-@@ -7420,8 +7920,6 @@ fi
+@@ -7656,8 +8156,6 @@ fi
  lt_prog_compiler_pic=
  lt_prog_compiler_static=
  
@@ -20012,7 +20110,7 @@
  
    if test "$GCC" = yes; then
      lt_prog_compiler_wl='-Wl,'
-@@ -7587,6 +8085,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -7823,6 +8321,12 @@ $as_echo_n "checking for $compiler optio
  	lt_prog_compiler_pic='--shared'
  	lt_prog_compiler_static='--static'
  	;;
@@ -20025,7 +20123,7 @@
        pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
          # Portland Group compilers (*not* the Pentium gcc compiler,
  	# which looks to be a dead project)
-@@ -7649,7 +8153,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -7885,7 +8389,7 @@ $as_echo_n "checking for $compiler optio
        lt_prog_compiler_pic='-KPIC'
        lt_prog_compiler_static='-Bstatic'
        case $cc_basename in
@@ -20034,7 +20132,7 @@
  	lt_prog_compiler_wl='-Qoption ld ';;
        *)
  	lt_prog_compiler_wl='-Wl,';;
-@@ -7706,13 +8210,17 @@ case $host_os in
+@@ -7942,13 +8446,17 @@ case $host_os in
      lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
      ;;
  esac
@@ -20047,7 +20145,7 @@
  
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-+if test "${lt_cv_prog_compiler_pic+set}" = set; then :
++if ${lt_cv_prog_compiler_pic+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
@@ -20058,7 +20156,7 @@
  
  #
  # Check to make sure the PIC flag actually works.
-@@ -7773,6 +8281,11 @@ fi
+@@ -8009,6 +8517,11 @@ fi
  
  
  
@@ -20070,7 +20168,7 @@
  #
  # Check to make sure the static flag actually works.
  #
-@@ -8123,7 +8636,8 @@ _LT_EOF
+@@ -8359,7 +8872,8 @@ _LT_EOF
        allow_undefined_flag=unsupported
        always_export_symbols=no
        enable_shared_with_static_runtimes=yes
@@ -20080,7 +20178,7 @@
  
        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
          archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-@@ -8222,12 +8736,12 @@ _LT_EOF
+@@ -8458,12 +8972,12 @@ _LT_EOF
  	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
  	  hardcode_libdir_flag_spec=
  	  hardcode_libdir_flag_spec_ld='-rpath $libdir'
@@ -20095,7 +20193,7 @@
  	  fi
  	  ;;
  	esac
-@@ -8241,8 +8755,8 @@ _LT_EOF
+@@ -8477,8 +8991,8 @@ _LT_EOF
  	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
  	wlarc=
        else
@@ -20106,7 +20204,7 @@
        fi
        ;;
  
-@@ -8260,8 +8774,8 @@ _LT_EOF
+@@ -8496,8 +9010,8 @@ _LT_EOF
  
  _LT_EOF
        elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -20117,7 +20215,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -8307,8 +8821,8 @@ _LT_EOF
+@@ -8543,8 +9057,8 @@ _LT_EOF
  
      *)
        if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -20128,7 +20226,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -8438,7 +8952,13 @@ _LT_EOF
+@@ -8674,7 +9188,13 @@ _LT_EOF
  	allow_undefined_flag='-berok'
          # Determine the default libpath from the value encoded in an
          # empty executable.
@@ -20136,14 +20234,14 @@
 +        if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  if ${lt_cv_aix_libpath_+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test x$gcc_no_link = xyes; then
-   as_fn_error "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
+   as_fn_error $? "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
  fi
  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-@@ -8454,22 +8974,29 @@ main ()
+@@ -8690,22 +9210,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -20186,7 +20284,7 @@
  
          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
          archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
-@@ -8481,7 +9008,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -8717,7 +9244,13 @@ if test -z "$aix_libpath"; then aix_libp
  	else
  	 # Determine the default libpath from the value encoded in an
  	 # empty executable.
@@ -20194,14 +20292,14 @@
 +	 if test "${lt_cv_aix_libpath+set}" = set; then
 +  aix_libpath=$lt_cv_aix_libpath
 +else
-+  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  if ${lt_cv_aix_libpath_+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  if test x$gcc_no_link = xyes; then
-   as_fn_error "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
+   as_fn_error $? "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
  fi
  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-@@ -8497,22 +9030,29 @@ main ()
+@@ -8733,22 +9266,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -20244,7 +20342,7 @@
  
  	 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
  	  # Warning - without using the other run time loading flags,
-@@ -8557,20 +9097,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -8793,20 +9333,63 @@ if test -z "$aix_libpath"; then aix_libp
        # Microsoft Visual C++.
        # hardcode_libdir_flag_spec is actually meaningless, as there is
        # no search path for DLLs.
@@ -20322,7 +20420,7 @@
        ;;
  
      darwin* | rhapsody*)
-@@ -8631,7 +9214,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -8867,7 +9450,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
      freebsd* | dragonfly*)
@@ -20331,7 +20429,7 @@
        hardcode_libdir_flag_spec='-R$libdir'
        hardcode_direct=yes
        hardcode_shlibpath_var=no
-@@ -8639,7 +9222,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -8875,7 +9458,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      hpux9*)
        if test "$GCC" = yes; then
@@ -20340,7 +20438,7 @@
        else
  	archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
        fi
-@@ -8655,7 +9238,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -8891,7 +9474,7 @@ if test -z "$aix_libpath"; then aix_libp
  
      hpux10*)
        if test "$GCC" = yes && test "$with_gnu_ld" = no; then
@@ -20349,7 +20447,7 @@
        else
  	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
        fi
-@@ -8679,10 +9262,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -8915,10 +9498,10 @@ if test -z "$aix_libpath"; then aix_libp
  	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  	  ;;
  	ia64*)
@@ -20362,7 +20460,7 @@
  	  ;;
  	esac
        else
-@@ -8761,26 +9344,39 @@ fi
+@@ -8997,26 +9580,39 @@ fi
  
      irix5* | irix6* | nonstopux*)
        if test "$GCC" = yes; then
@@ -20377,13 +20475,13 @@
 +	# This should be the same for all languages, so no per-tag cache variable.
 +	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
 +$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
-+if test "${lt_cv_irix_exported_symbol+set}" = set; then :
++if ${lt_cv_irix_exported_symbol+:} false; then :
 +  $as_echo_n "(cached) " >&6
 +else
 +  save_LDFLAGS="$LDFLAGS"
 +	   LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
 +	   if test x$gcc_no_link = xyes; then
-   as_fn_error "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
+   as_fn_error $? "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
  fi
  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  /* end confdefs.h.  */
@@ -20410,7 +20508,7 @@
        else
  	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
  	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
-@@ -8865,7 +9461,7 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -9101,7 +9697,7 @@ rm -f core conftest.err conftest.$ac_obj
      osf4* | osf5*)	# as osf3* with the addition of -msym flag
        if test "$GCC" = yes; then
  	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
@@ -20419,7 +20517,7 @@
  	hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
        else
  	allow_undefined_flag=' -expect_unresolved \*'
-@@ -8884,9 +9480,9 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -9120,9 +9716,9 @@ rm -f core conftest.err conftest.$ac_obj
        no_undefined_flag=' -z defs'
        if test "$GCC" = yes; then
  	wlarc='${wl}'
@@ -20431,7 +20529,7 @@
        else
  	case `$CC -V 2>&1` in
  	*"Compilers 5.0"*)
-@@ -9462,8 +10058,9 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -9698,8 +10294,9 @@ cygwin* | mingw* | pw32* | cegcc*)
    need_version=no
    need_lib_prefix=no
  
@@ -20443,7 +20541,7 @@
      library_names_spec='$libname.dll.a'
      # DLL is installed to $(libdir)/../bin by postinstall_cmds
      postinstall_cmds='base_file=`basename \${file}`~
-@@ -9496,13 +10093,71 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -9732,13 +10329,71 @@ cygwin* | mingw* | pw32* | cegcc*)
        library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
        ;;
      esac
@@ -20516,7 +20614,7 @@
    # FIXME: first we should search . and the directory the executable is in
    shlibpath_var=PATH
    ;;
-@@ -9594,7 +10249,7 @@ haiku*)
+@@ -9830,7 +10485,7 @@ haiku*)
    soname_spec='${libname}${release}${shared_ext}$major'
    shlibpath_var=LIBRARY_PATH
    shlibpath_overrides_runpath=yes
@@ -20525,7 +20623,16 @@
    hardcode_into_libs=yes
    ;;
  
-@@ -10452,10 +11107,10 @@ else
+@@ -10644,7 +11299,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 10647 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -10688,10 +11343,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -20538,7 +20645,16 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -10558,10 +11213,10 @@ else
+@@ -10750,7 +11405,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 10753 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -10794,10 +11449,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -20551,7 +20667,7 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -11992,13 +12647,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
+@@ -12266,13 +12921,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_
  lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
  lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
  lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
@@ -20572,7 +20688,7 @@
  STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
  RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
  old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-@@ -12013,14 +12675,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
+@@ -12287,14 +12949,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$l
  lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
@@ -20591,7 +20707,7 @@
  DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
  NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
  LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-@@ -12053,12 +12718,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
+@@ -12327,12 +12992,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcod
  hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
  inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
  link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
@@ -20605,7 +20721,7 @@
  file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
  variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
  need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-@@ -12113,8 +12778,13 @@ reload_flag \
+@@ -12387,8 +13052,13 @@ reload_flag \
  OBJDUMP \
  deplibs_check_method \
  file_magic_cmd \
@@ -20619,7 +20735,7 @@
  STRIP \
  RANLIB \
  CC \
-@@ -12124,12 +12794,14 @@ lt_cv_sys_global_symbol_pipe \
+@@ -12398,12 +13068,14 @@ lt_cv_sys_global_symbol_pipe \
  lt_cv_sys_global_symbol_to_cdecl \
  lt_cv_sys_global_symbol_to_c_name_address \
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
@@ -20635,7 +20751,7 @@
  DSYMUTIL \
  NMEDIT \
  LIPO \
-@@ -12145,7 +12817,6 @@ no_undefined_flag \
+@@ -12419,7 +13091,6 @@ no_undefined_flag \
  hardcode_libdir_flag_spec \
  hardcode_libdir_flag_spec_ld \
  hardcode_libdir_separator \
@@ -20643,7 +20759,7 @@
  exclude_expsyms \
  include_expsyms \
  file_list_spec \
-@@ -12181,6 +12852,7 @@ module_cmds \
+@@ -12455,6 +13126,7 @@ module_cmds \
  module_expsym_cmds \
  export_symbols_cmds \
  prelink_cmds \
@@ -20651,7 +20767,7 @@
  postinstall_cmds \
  postuninstall_cmds \
  finish_cmds \
-@@ -12770,7 +13442,8 @@ $as_echo X"$file" |
+@@ -13053,7 +13725,8 @@ $as_echo X"$file" |
  # NOTE: Changes made to this file will be lost: look at ltmain.sh.
  #
  #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
@@ -20661,7 +20777,7 @@
  #   Written by Gordon Matzigkeit, 1996
  #
  #   This file is part of GNU Libtool.
-@@ -12873,19 +13546,42 @@ SP2NL=$lt_lt_SP2NL
+@@ -13156,19 +13829,42 @@ SP2NL=$lt_lt_SP2NL
  # turn newlines into spaces.
  NL2SP=$lt_lt_NL2SP
  
@@ -20705,7 +20821,7 @@
  # A symbol stripping program.
  STRIP=$lt_STRIP
  
-@@ -12915,6 +13611,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
+@@ -13198,6 +13894,12 @@ global_symbol_to_c_name_address=$lt_lt_c
  # Transform the output of nm in a C name address pair when lib prefix is needed.
  global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
  
@@ -20718,7 +20834,7 @@
  # The name of the directory that contains temporary libtool files.
  objdir=$objdir
  
-@@ -12924,6 +13626,9 @@ MAGIC_CMD=$MAGIC_CMD
+@@ -13207,6 +13909,9 @@ MAGIC_CMD=$MAGIC_CMD
  # Must we lock files when doing compilation?
  need_locks=$lt_need_locks
  
@@ -20728,7 +20844,7 @@
  # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
  DSYMUTIL=$lt_DSYMUTIL
  
-@@ -13038,12 +13743,12 @@ with_gcc=$GCC
+@@ -13321,12 +14026,12 @@ with_gcc=$GCC
  # Compiler flag to turn off builtin functions.
  no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
  
@@ -20744,7 +20860,7 @@
  # Compiler flag to prevent dynamic linking.
  link_static_flag=$lt_lt_prog_compiler_static
  
-@@ -13130,9 +13835,6 @@ inherit_rpath=$inherit_rpath
+@@ -13413,9 +14118,6 @@ inherit_rpath=$inherit_rpath
  # Whether libtool must link a program against all its dependency libraries.
  link_all_deplibs=$link_all_deplibs
  
@@ -20754,7 +20870,7 @@
  # Set to "yes" if exported symbols are required.
  always_export_symbols=$always_export_symbols
  
-@@ -13148,6 +13850,9 @@ include_expsyms=$lt_include_expsyms
+@@ -13431,6 +14133,9 @@ include_expsyms=$lt_include_expsyms
  # Commands necessary for linking programs (against libraries) with templates.
  prelink_cmds=$lt_prelink_cmds
  
@@ -20764,7 +20880,7 @@
  # Specify filename containing input files.
  file_list_spec=$lt_file_list_spec
  
-@@ -13180,210 +13885,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
+@@ -13463,210 +14168,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
    # if finds mixed CR/LF and LF-only lines.  Since sed operates in
    # text mode, it properly converts lines to CR/LF.  This bash problem
    # is reportedly fixed, but why not run on old versions too?
@@ -20966,15 +21082,9 @@
 -_LT_EOF
 -    ;;
 -  esac
--
--
--  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
--    || (rm -f "$cfgfile"; exit 1)
--
--  mv -f "$cfgfile" "$ofile" ||
 +  sed '$q' "$ltmain" >> "$cfgfile" \
 +     || (rm -f "$cfgfile"; exit 1)
-+
+ 
 +  if test x"$xsi_shell" = xyes; then
 +  sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
 +func_dirname ()\
@@ -21132,12 +21242,12 @@
 +  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
 +$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
 +fi
-+
-+
+ 
+-  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
+-    || (rm -f "$cfgfile"; exit 1)
+ 
+-  mv -f "$cfgfile" "$ofile" ||
 +   mv -f "$cfgfile" "$ofile" ||
      (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
    chmod +x "$ofile"
  
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0007-Add-the-armv5e-architecture-to-binutils.patch b/poky/meta/recipes-devtools/binutils/binutils/0007-Add-the-armv5e-architecture-to-binutils.patch
index 4a51273..18ef6bb 100644
--- a/poky/meta/recipes-devtools/binutils/binutils/0007-Add-the-armv5e-architecture-to-binutils.patch
+++ b/poky/meta/recipes-devtools/binutils/binutils/0007-Add-the-armv5e-architecture-to-binutils.patch
@@ -1,4 +1,4 @@
-From 697903256e09533778baa8af66402c44d70219d9 Mon Sep 17 00:00:00 2001
+From ef50d848d983f81e4a86dd3eef4933e3579336f1 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:37:10 +0000
 Subject: [PATCH 07/15] Add the armv5e architecture to binutils
@@ -19,10 +19,10 @@
  1 file changed, 1 insertion(+)
 
 diff --git a/gas/config/tc-arm.c b/gas/config/tc-arm.c
-index ec50420518..a25d1721af 100644
+index 3f5384e1c7..8d5bc145af 100644
 --- a/gas/config/tc-arm.c
 +++ b/gas/config/tc-arm.c
-@@ -26195,6 +26195,7 @@ static const struct arm_arch_option_table arm_archs[] =
+@@ -26294,6 +26294,7 @@ static const struct arm_arch_option_table arm_archs[] =
    ARM_ARCH_OPT ("armv4t",	ARM_ARCH_V4T,	 FPU_ARCH_FPA),
    ARM_ARCH_OPT ("armv4txm",	ARM_ARCH_V4TxM,	 FPU_ARCH_FPA),
    ARM_ARCH_OPT ("armv5",	ARM_ARCH_V5,	 FPU_ARCH_VFP),
@@ -31,5 +31,5 @@
    ARM_ARCH_OPT ("armv5txm",	ARM_ARCH_V5TxM,	 FPU_ARCH_VFP),
    ARM_ARCH_OPT ("armv5te",	ARM_ARCH_V5TE,	 FPU_ARCH_VFP),
 -- 
-2.16.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0008-don-t-let-the-distro-compiler-point-to-the-wrong-ins.patch b/poky/meta/recipes-devtools/binutils/binutils/0008-don-t-let-the-distro-compiler-point-to-the-wrong-ins.patch
index 939be67..6999ed9 100644
--- a/poky/meta/recipes-devtools/binutils/binutils/0008-don-t-let-the-distro-compiler-point-to-the-wrong-ins.patch
+++ b/poky/meta/recipes-devtools/binutils/binutils/0008-don-t-let-the-distro-compiler-point-to-the-wrong-ins.patch
@@ -1,4 +1,4 @@
-From 622d66634eb2e509d4126f5bdcab26de367241a1 Mon Sep 17 00:00:00 2001
+From ca25d55cef8398bad508c2b2be29aea5aa3c4d26 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:39:01 +0000
 Subject: [PATCH 08/15] don't let the distro compiler point to the wrong
@@ -31,5 +31,5 @@
  	if test -n "${target_header_dir}"; then \
  		${mkinstalldirs} $(DESTDIR)$(libdir)/$(MULTIOSDIR); \
 -- 
-2.16.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0009-warn-for-uses-of-system-directories-when-cross-linki.patch b/poky/meta/recipes-devtools/binutils/binutils/0009-warn-for-uses-of-system-directories-when-cross-linki.patch
index e751047..9a9e319 100644
--- a/poky/meta/recipes-devtools/binutils/binutils/0009-warn-for-uses-of-system-directories-when-cross-linki.patch
+++ b/poky/meta/recipes-devtools/binutils/binutils/0009-warn-for-uses-of-system-directories-when-cross-linki.patch
@@ -1,4 +1,4 @@
-From 27e38ee92c24fca86b1c3f6ef156a1892dd06bfd Mon Sep 17 00:00:00 2001
+From a3667059fc0d52d890b505bed0e5050ea3d7002e Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 15 Jan 2016 06:31:09 +0000
 Subject: [PATCH 09/15] warn for uses of system directories when cross linking
@@ -55,7 +55,7 @@
  ld/configure    | 16 ++++++++++++++++
  ld/configure.ac | 10 ++++++++++
  ld/ld.h         |  8 ++++++++
- ld/ld.texinfo   | 12 ++++++++++++
+ ld/ld.texi      | 12 ++++++++++++
  ld/ldfile.c     | 17 +++++++++++++++++
  ld/ldlex.h      |  2 ++
  ld/ldmain.c     |  2 ++
@@ -63,10 +63,10 @@
  9 files changed, 86 insertions(+)
 
 diff --git a/ld/config.in b/ld/config.in
-index a846743da6..df3cd5fb60 100644
+index d93c9b0830..5da2742bea 100644
 --- a/ld/config.in
 +++ b/ld/config.in
-@@ -27,6 +27,9 @@
+@@ -31,6 +31,9 @@
     language is requested. */
  #undef ENABLE_NLS
  
@@ -77,10 +77,10 @@
  #undef EXTRA_SHLIB_EXTENSION
  
 diff --git a/ld/configure b/ld/configure
-index db8b998722..489ead5c13 100755
+index 2b291f0da8..facc386563 100755
 --- a/ld/configure
 +++ b/ld/configure
-@@ -789,6 +789,7 @@ with_lib_path
+@@ -826,6 +826,7 @@ with_lib_path
  enable_targets
  enable_64_bit_bfd
  with_sysroot
@@ -88,7 +88,7 @@
  enable_gold
  enable_got
  enable_compressed_debug_sections
-@@ -1448,6 +1449,8 @@ Optional Features:
+@@ -1490,6 +1491,8 @@ Optional Features:
    --disable-largefile     omit support for large files
    --enable-targets        alternative target configurations
    --enable-64-bit-bfd     64-bit support (on hosts with narrower word sizes)
@@ -97,7 +97,7 @@
    --enable-gold[=ARG]     build gold [ARG={default,yes,no}]
    --enable-got=<type>     GOT handling scheme (target, single, negative,
                            multigot)
-@@ -16315,6 +16318,19 @@ fi
+@@ -16618,6 +16621,19 @@ fi
  
  
  
@@ -118,10 +118,10 @@
  if test "${enable_gold+set}" = set; then :
    enableval=$enable_gold; case "${enableval}" in
 diff --git a/ld/configure.ac b/ld/configure.ac
-index bada1b50b0..d074a3820b 100644
+index d10c553650..9f1b57b120 100644
 --- a/ld/configure.ac
 +++ b/ld/configure.ac
-@@ -95,6 +95,16 @@ AC_SUBST(use_sysroot)
+@@ -94,6 +94,16 @@ AC_SUBST(use_sysroot)
  AC_SUBST(TARGET_SYSTEM_ROOT)
  AC_SUBST(TARGET_SYSTEM_ROOT_DEFINE)
  
@@ -157,11 +157,11 @@
    /* Big or little endian as set on command line.  */
    enum endian_enum endian;
  
-diff --git a/ld/ld.texinfo b/ld/ld.texinfo
-index c89915f1aa..df430837e2 100644
---- a/ld/ld.texinfo
-+++ b/ld/ld.texinfo
-@@ -2498,6 +2498,18 @@ string identifying the original linked file does not change.
+diff --git a/ld/ld.texi b/ld/ld.texi
+index b9fe2324da..43486605e0 100644
+--- a/ld/ld.texi
++++ b/ld/ld.texi
+@@ -2479,6 +2479,18 @@ string identifying the original linked file does not change.
  
  Passing @code{none} for @var{style} disables the setting from any
  @code{--build-id} options earlier on the command line.
@@ -181,7 +181,7 @@
  
  @c man end
 diff --git a/ld/ldfile.c b/ld/ldfile.c
-index 6532a57d96..f943f0b2e5 100644
+index a72ff13526..dc5148f748 100644
 --- a/ld/ldfile.c
 +++ b/ld/ldfile.c
 @@ -116,6 +116,23 @@ ldfile_add_library_path (const char *name, bfd_boolean cmdline)
@@ -209,10 +209,10 @@
  
  /* Try to open a BFD for a lang_input_statement.  */
 diff --git a/ld/ldlex.h b/ld/ldlex.h
-index 140ed1d9da..9965cbc04f 100644
+index 04d6fd5f96..d7df005bb2 100644
 --- a/ld/ldlex.h
 +++ b/ld/ldlex.h
-@@ -147,6 +147,8 @@ enum option_values
+@@ -148,6 +148,8 @@ enum option_values
    OPTION_REQUIRE_DEFINED_SYMBOL,
    OPTION_ORPHAN_HANDLING,
    OPTION_FORCE_GROUP_ALLOCATION,
@@ -222,10 +222,10 @@
  
  /* The initial parser states.  */
 diff --git a/ld/ldmain.c b/ld/ldmain.c
-index c473ed24c3..adae0b4610 100644
+index f31eeb29c3..25f8497888 100644
 --- a/ld/ldmain.c
 +++ b/ld/ldmain.c
-@@ -261,6 +261,8 @@ main (int argc, char **argv)
+@@ -268,6 +268,8 @@ main (int argc, char **argv)
    command_line.warn_mismatch = TRUE;
    command_line.warn_search_mismatch = TRUE;
    command_line.check_section_addresses = -1;
@@ -235,10 +235,10 @@
    /* We initialize DEMANGLING based on the environment variable
       COLLECT_NO_DEMANGLE.  The gcc collect2 program will demangle the
 diff --git a/ld/lexsup.c b/ld/lexsup.c
-index f2191602d4..bccb3bdeef 100644
+index 86a033a383..4a40d48020 100644
 --- a/ld/lexsup.c
 +++ b/ld/lexsup.c
-@@ -538,6 +538,14 @@ static const struct ld_option ld_options[] =
+@@ -543,6 +543,14 @@ static const struct ld_option ld_options[] =
    { {"orphan-handling", required_argument, NULL, OPTION_ORPHAN_HANDLING},
      '\0', N_("=MODE"), N_("Control how orphan sections are handled."),
      TWO_DASHES },
@@ -253,8 +253,8 @@
  };
  
  #define OPTION_COUNT ARRAY_SIZE (ld_options)
-@@ -1568,6 +1576,14 @@ parse_args (unsigned argc, char **argv)
- 	    einfo (_("%P%F: invalid argument to option"
+@@ -1577,6 +1585,14 @@ parse_args (unsigned argc, char **argv)
+ 	    einfo (_("%F%P: invalid argument to option"
  		     " \"--orphan-handling\"\n"));
  	  break;
 +
@@ -269,5 +269,5 @@
      }
  
 -- 
-2.16.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0010-Fix-rpath-in-libtool-when-sysroot-is-enabled.patch b/poky/meta/recipes-devtools/binutils/binutils/0010-Fix-rpath-in-libtool-when-sysroot-is-enabled.patch
index 33dfff9..8fc00ff 100644
--- a/poky/meta/recipes-devtools/binutils/binutils/0010-Fix-rpath-in-libtool-when-sysroot-is-enabled.patch
+++ b/poky/meta/recipes-devtools/binutils/binutils/0010-Fix-rpath-in-libtool-when-sysroot-is-enabled.patch
@@ -1,4 +1,4 @@
-From e205ae05c41a8cc8d47708f0a3b6f740e2bf2526 Mon Sep 17 00:00:00 2001
+From 9e1d8f9a657a8bd48048c2ea6407cf60b723bd68 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:42:38 +0000
 Subject: [PATCH 10/15] Fix rpath in libtool when sysroot is enabled
@@ -48,5 +48,5 @@
  	    if test -z "$hardcode_libdirs"; then
  	      hardcode_libdirs="$libdir"
 -- 
-2.16.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0011-Change-default-emulation-for-mips64-linux.patch b/poky/meta/recipes-devtools/binutils/binutils/0011-Change-default-emulation-for-mips64-linux.patch
index 80fcbc1..2e93b12 100644
--- a/poky/meta/recipes-devtools/binutils/binutils/0011-Change-default-emulation-for-mips64-linux.patch
+++ b/poky/meta/recipes-devtools/binutils/binutils/0011-Change-default-emulation-for-mips64-linux.patch
@@ -1,4 +1,4 @@
-From 7978c1299021033c35c29c94e0997235f7ede248 Mon Sep 17 00:00:00 2001
+From 2d2e2fcdd9646849716ee99d8d3e5d72ae8889bc Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:44:14 +0000
 Subject: [PATCH 11/15] Change default emulation for mips64*-*-linux
@@ -14,10 +14,10 @@
  2 files changed, 8 insertions(+), 8 deletions(-)
 
 diff --git a/bfd/config.bfd b/bfd/config.bfd
-index f04a993f06..8777f96bd2 100644
+index 6391f35684..8a11c0680a 100644
 --- a/bfd/config.bfd
 +++ b/bfd/config.bfd
-@@ -1189,12 +1189,12 @@ case "${targ}" in
+@@ -913,12 +913,12 @@ case "${targ}" in
      targ_selvecs="mips_elf32_le_vec mips_elf64_be_vec mips_elf64_le_vec mips_ecoff_be_vec mips_ecoff_le_vec"
      ;;
    mips64*el-*-linux*)
@@ -35,10 +35,10 @@
    mips*el-*-linux*)
      targ_defvec=mips_elf32_trad_le_vec
 diff --git a/ld/configure.tgt b/ld/configure.tgt
-index 6183a85b3d..1d78465590 100644
+index fad8b2e5c8..7fb2168503 100644
 --- a/ld/configure.tgt
 +++ b/ld/configure.tgt
-@@ -535,11 +535,11 @@ mips*el-*-vxworks*)	targ_emul=elf32elmipvxworks
+@@ -464,11 +464,11 @@ mips*el-*-vxworks*)	targ_emul=elf32elmipvxworks
  mips*-*-vxworks*)	targ_emul=elf32ebmipvxworks
  			targ_extra_emuls="elf32elmipvxworks" ;;
  mips*-*-windiss)	targ_emul=elf32mipswindiss ;;
@@ -55,5 +55,5 @@
  mips*el-*-linux-*)	targ_emul=elf32ltsmip
  			targ_extra_emuls="elf32btsmip elf32ltsmipn32 elf64ltsmip elf32btsmipn32 elf64btsmip"
 -- 
-2.16.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0012-Add-support-for-Netlogic-XLP.patch b/poky/meta/recipes-devtools/binutils/binutils/0012-Add-support-for-Netlogic-XLP.patch
index 1fefb68..4d64bd5 100644
--- a/poky/meta/recipes-devtools/binutils/binutils/0012-Add-support-for-Netlogic-XLP.patch
+++ b/poky/meta/recipes-devtools/binutils/binutils/0012-Add-support-for-Netlogic-XLP.patch
@@ -1,4 +1,4 @@
-From 3b40bf584615f794b85fd50d4d0a5c0a1d2ee7bf Mon Sep 17 00:00:00 2001
+From 96ff7570c29f792c466a933529fefda9b8e97994 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sun, 14 Feb 2016 17:06:19 +0000
 Subject: [PATCH 12/15] Add support for Netlogic XLP
@@ -34,10 +34,10 @@
  14 files changed, 61 insertions(+), 21 deletions(-)
 
 diff --git a/bfd/aoutx.h b/bfd/aoutx.h
-index eec9c4ad2a..3bf0a71e63 100644
+index 023843b0be..46246fec2d 100644
 --- a/bfd/aoutx.h
 +++ b/bfd/aoutx.h
-@@ -814,6 +814,7 @@ NAME (aout, machine_type) (enum bfd_architecture arch,
+@@ -798,6 +798,7 @@ NAME (aout, machine_type) (enum bfd_architecture arch,
  	case bfd_mach_mipsisa64r6:
  	case bfd_mach_mips_sb1:
  	case bfd_mach_mips_xlr:
@@ -46,10 +46,10 @@
  	  arch_flags = M_MIPS2;
  	  break;
 diff --git a/bfd/archures.c b/bfd/archures.c
-index e83c57a2f3..3016ea1bae 100644
+index 282e983086..b38b05d132 100644
 --- a/bfd/archures.c
 +++ b/bfd/archures.c
-@@ -201,6 +201,7 @@ DESCRIPTION
+@@ -183,6 +183,7 @@ DESCRIPTION
  .#define bfd_mach_mips_octeon3		6503
  .#define bfd_mach_mips_xlr		887682	 {* decimal 'XLR'.  *}
  .#define bfd_mach_mips_interaptiv_mr2	736550	 {* decimal 'IA2'.  *}
@@ -58,10 +58,10 @@
  .#define bfd_mach_mipsisa32r2		33
  .#define bfd_mach_mipsisa32r3		34
 diff --git a/bfd/bfd-in2.h b/bfd/bfd-in2.h
-index 42991e7848..27abc5d5a8 100644
+index 93745bd3fd..326e9e49ed 100644
 --- a/bfd/bfd-in2.h
 +++ b/bfd/bfd-in2.h
-@@ -2062,6 +2062,7 @@ enum bfd_architecture
+@@ -2054,6 +2054,7 @@ enum bfd_architecture
  #define bfd_mach_mips_octeon3          6503
  #define bfd_mach_mips_xlr              887682   /* decimal 'XLR'.  */
  #define bfd_mach_mips_interaptiv_mr2   736550   /* decimal 'IA2'.  */
@@ -70,10 +70,10 @@
  #define bfd_mach_mipsisa32r2           33
  #define bfd_mach_mipsisa32r3           34
 diff --git a/bfd/config.bfd b/bfd/config.bfd
-index 8777f96bd2..7b80bda8c9 100644
+index 8a11c0680a..c882421343 100644
 --- a/bfd/config.bfd
 +++ b/bfd/config.bfd
-@@ -1172,6 +1172,11 @@ case "${targ}" in
+@@ -896,6 +896,11 @@ case "${targ}" in
      targ_defvec=mips_elf32_le_vec
      targ_selvecs="mips_elf32_be_vec mips_elf64_be_vec mips_elf64_le_vec"
      ;;
@@ -110,10 +110,10 @@
  
  /* The default architecture is mips:3000, but with a machine number of
 diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c
-index 285401367d..14ebb5f175 100644
+index d91942301c..5d1bd3f0b1 100644
 --- a/bfd/elfxx-mips.c
 +++ b/bfd/elfxx-mips.c
-@@ -6806,6 +6806,9 @@ _bfd_elf_mips_mach (flagword flags)
+@@ -6805,6 +6805,9 @@ _bfd_elf_mips_mach (flagword flags)
      case E_MIPS_MACH_IAMR2:
        return bfd_mach_mips_interaptiv_mr2;
  
@@ -123,7 +123,7 @@
      default:
        switch (flags & EF_MIPS_ARCH)
  	{
-@@ -11963,6 +11966,10 @@ mips_set_isa_flags (bfd *abfd)
+@@ -12003,6 +12006,10 @@ mips_set_isa_flags (bfd *abfd)
        val = E_MIPS_ARCH_64R2 | E_MIPS_MACH_OCTEON2;
        break;
  
@@ -134,7 +134,7 @@
      case bfd_mach_mipsisa32:
        val = E_MIPS_ARCH_32;
        break;
-@@ -13936,6 +13943,7 @@ static const struct mips_mach_extension mips_mach_extensions[] =
+@@ -13992,6 +13999,7 @@ static const struct mips_mach_extension mips_mach_extensions[] =
    { bfd_mach_mips_octeonp, bfd_mach_mips_octeon },
    { bfd_mach_mips_octeon, bfd_mach_mipsisa64r2 },
    { bfd_mach_mips_loongson_3a, bfd_mach_mipsisa64r2 },
@@ -143,10 +143,10 @@
    /* MIPS64 extensions.  */
    { bfd_mach_mipsisa64r2, bfd_mach_mipsisa64 },
 diff --git a/binutils/readelf.c b/binutils/readelf.c
-index ae1cda9a7b..fed0387a94 100644
+index 2b78db219b..7a7178925f 100644
 --- a/binutils/readelf.c
 +++ b/binutils/readelf.c
-@@ -3370,6 +3370,7 @@ get_machine_flags (Filedata * filedata, unsigned e_flags, unsigned e_machine)
+@@ -3403,6 +3403,7 @@ get_machine_flags (Filedata * filedata, unsigned e_flags, unsigned e_machine)
  	    case E_MIPS_MACH_OCTEON3: strcat (buf, ", octeon3"); break;
  	    case E_MIPS_MACH_XLR:  strcat (buf, ", xlr"); break;
  	    case E_MIPS_MACH_IAMR2:  strcat (buf, ", interaptiv-mr2"); break;
@@ -155,7 +155,7 @@
  	    /* We simply ignore the field in this case to avoid confusion:
  	       MIPS ELF does not specify EF_MIPS_MACH, it is a GNU
 diff --git a/gas/config/tc-mips.c b/gas/config/tc-mips.c
-index c135131b59..d8fbda8e31 100644
+index 59df787155..48537226c0 100644
 --- a/gas/config/tc-mips.c
 +++ b/gas/config/tc-mips.c
 @@ -552,6 +552,7 @@ static int mips_32bitmode = 0;
@@ -174,7 +174,7 @@
     )
  
  /* Whether the processor uses hardware interlocks to protect reads
-@@ -19737,7 +19739,7 @@ static const struct mips_cpu_info mips_cpu_info_table[] =
+@@ -19778,7 +19780,7 @@ static const struct mips_cpu_info mips_cpu_info_table[] =
    /* Broadcom XLP.
       XLP is mostly like XLR, with the prominent exception that it is
       MIPS64R2 rather than MIPS64.  */
@@ -184,10 +184,10 @@
    /* MIPS 64 Release 6 */
    { "i6400",	      0, ASE_MSA,		ISA_MIPS64R6, CPU_MIPS64R6},
 diff --git a/gas/configure b/gas/configure
-index a40ac2144f..65a6995243 100755
+index 134278fa25..2fdca147a1 100755
 --- a/gas/configure
 +++ b/gas/configure
-@@ -12989,6 +12989,9 @@ _ACEOF
+@@ -13336,6 +13336,9 @@ _ACEOF
  	  mipsisa64r6 | mipsisa64r6el)
  	    mips_cpu=mips64r6
  	    ;;
@@ -198,7 +198,7 @@
  	    mips_cpu=r3900
  	    ;;
 diff --git a/include/elf/mips.h b/include/elf/mips.h
-index 9de0b4e175..74fc4f7e55 100644
+index 4e2cde3279..c329f38929 100644
 --- a/include/elf/mips.h
 +++ b/include/elf/mips.h
 @@ -290,6 +290,7 @@ END_RELOC_NUMBERS (R_MIPS_maxext)
@@ -210,10 +210,10 @@
  #define E_MIPS_MACH_OCTEON3	0x008e0000
  #define E_MIPS_MACH_5400	0x00910000
 diff --git a/include/opcode/mips.h b/include/opcode/mips.h
-index 5eea72f139..90f6d57e15 100644
+index 1ab1780567..74f457b579 100644
 --- a/include/opcode/mips.h
 +++ b/include/opcode/mips.h
-@@ -1259,6 +1259,8 @@ static const unsigned int mips_isa_table[] = {
+@@ -1262,6 +1262,8 @@ static const unsigned int mips_isa_table[] = {
  #define INSN_XLR                 0x00000020
  /* Imagination interAptiv MR2.  */
  #define INSN_INTERAPTIV_MR2	  0x04000000
@@ -222,7 +222,7 @@
  
  /* DSP ASE */
  #define ASE_DSP			0x00000001
-@@ -1365,6 +1367,7 @@ static const unsigned int mips_isa_table[] = {
+@@ -1373,6 +1375,7 @@ static const unsigned int mips_isa_table[] = {
  #define CPU_OCTEON3	6503
  #define CPU_XLR     	887682   	/* decimal 'XLR'   */
  #define CPU_INTERAPTIV_MR2 736550	/* decimal 'IA2'  */
@@ -230,7 +230,7 @@
  
  /* Return true if the given CPU is included in INSN_* mask MASK.  */
  
-@@ -1445,6 +1448,9 @@ cpu_is_member (int cpu, unsigned int mask)
+@@ -1453,6 +1456,9 @@ cpu_is_member (int cpu, unsigned int mask)
        return ((mask & INSN_ISA_MASK) == INSN_ISA32R6)
  	     || ((mask & INSN_ISA_MASK) == INSN_ISA64R6);
  
@@ -241,10 +241,10 @@
        return FALSE;
      }
 diff --git a/ld/configure.tgt b/ld/configure.tgt
-index 1d78465590..307e787b64 100644
+index 7fb2168503..a1db7adfe2 100644
 --- a/ld/configure.tgt
 +++ b/ld/configure.tgt
-@@ -521,6 +521,8 @@ mips*el-sde-elf* | mips*el-mti-elf* | mips*el-img-elf*)
+@@ -450,6 +450,8 @@ mips*el-sde-elf* | mips*el-mti-elf* | mips*el-img-elf*)
  mips*-sde-elf* | mips*-mti-elf* | mips*-img-elf*)
  			targ_emul=elf32btsmip
  			targ_extra_emuls="elf32ltsmip elf32btsmipn32 elf64btsmip elf32ltsmipn32 elf64ltsmip" ;;
@@ -254,10 +254,10 @@
  			targ_extra_emuls="elf32lr5900"
  			targ_extra_libpath=$targ_extra_emuls ;;
 diff --git a/opcodes/mips-dis.c b/opcodes/mips-dis.c
-index 984fcbb802..95b107d216 100644
+index bbf21328e8..38e487c16f 100644
 --- a/opcodes/mips-dis.c
 +++ b/opcodes/mips-dis.c
-@@ -655,13 +655,11 @@ const struct mips_arch_choice mips_arch_choices[] =
+@@ -656,13 +656,11 @@ const struct mips_arch_choice mips_arch_choices[] =
      mips_cp0sel_names_xlr, ARRAY_SIZE (mips_cp0sel_names_xlr),
      mips_cp1_names_mips3264, mips_hwr_names_numeric },
  
@@ -277,10 +277,10 @@
    /* This entry, mips16, is here only for ISA/processor selection; do
       not print its name.  */
 diff --git a/opcodes/mips-opc.c b/opcodes/mips-opc.c
-index 180d613c93..65b7b8cc23 100644
+index 1cbcbc6abc..e1fbdc89de 100644
 --- a/opcodes/mips-opc.c
 +++ b/opcodes/mips-opc.c
-@@ -328,6 +328,7 @@ decode_mips_operand (const char *p)
+@@ -329,6 +329,7 @@ decode_mips_operand (const char *p)
  #define IOCT3	INSN_OCTEON3
  #define XLR     INSN_XLR
  #define IAMR2	INSN_INTERAPTIV_MR2
@@ -288,7 +288,7 @@
  #define IVIRT	ASE_VIRT
  #define IVIRT64	ASE_VIRT64
  
-@@ -966,6 +967,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -974,6 +975,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
  {"clo",			"U,s",		0x70000021, 0xfc0007ff, WR_1|RD_2,		0,		I32|N55,	0,	I37 },
  {"clz",			"d,s",		0x00000050, 0xfc1f07ff, WR_1|RD_2,		0,		I37,		0,	0 },
  {"clz",			"U,s",		0x70000020, 0xfc0007ff, WR_1|RD_2,		0,		I32|N55,	0,	I37 },
@@ -296,7 +296,7 @@
  /* ctc0 is at the bottom of the table.  */
  {"ctc1",		"t,G",		0x44c00000, 0xffe007ff,	RD_1|WR_CC|CM,		0,		I1,		0,	0 },
  {"ctc1",		"t,S",		0x44c00000, 0xffe007ff,	RD_1|WR_CC|CM,		0,		I1,		0,	0 },
-@@ -998,12 +1000,13 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -1006,12 +1008,13 @@ const struct mips_opcode mips_builtin_opcodes[] =
  {"daddiu",		"t,r,j",	0x64000000, 0xfc000000, WR_1|RD_2,		0,		I3,		0,	0 },
  {"daddu",		"d,v,t",	0x0000002d, 0xfc0007ff, WR_1|RD_2|RD_3,		0,		I3,		0,	0 },
  {"daddu",		"t,r,I",	0,    (int) M_DADDU_I,	INSN_MACRO,		0,		I3,		0,	0 },
@@ -311,7 +311,7 @@
  /* dctr and dctw are used on the r5000.  */
  {"dctr",		"o(b)",	 	0xbc050000, 0xfc1f0000, RD_2,			0,		I3,		0,	0 },
  {"dctw",		"o(b)",		0xbc090000, 0xfc1f0000, RD_2,			0,		I3,		0,	0 },
-@@ -1075,6 +1078,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -1083,6 +1086,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
  {"dmfc0",		"t,G,H",	0x40200000, 0xffe007f8,	WR_1|RD_C0|LC,		0,		I64,		0,	0 },
  {"dmfgc0",		"t,G",		0x40600100, 0xffe007ff, WR_1|RD_C0|LC,		0,		0,		IVIRT64, 0 },
  {"dmfgc0",		"t,G,H",	0x40600100, 0xffe007f8, WR_1|RD_C0|LC,		0,		0,		IVIRT64, 0 },
@@ -319,7 +319,7 @@
  {"dmt",			"",		0x41600bc1, 0xffffffff, TRAP,			0,		0,		MT32,	0 },
  {"dmt",			"t",		0x41600bc1, 0xffe0ffff, WR_1|TRAP,		0,		0,		MT32,	0 },
  {"dmtc0",		"t,G",		0x40a00000, 0xffe007ff,	RD_1|WR_C0|WR_CC|CM,	0,		I3,		0,	EE },
-@@ -1090,6 +1094,8 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -1098,6 +1102,8 @@ const struct mips_opcode mips_builtin_opcodes[] =
  /* dmfc3 is at the bottom of the table.  */
  /* dmtc3 is at the bottom of the table.  */
  {"dmuh",		"d,s,t",	0x000000dc, 0xfc0007ff, WR_1|RD_2|RD_3,		0,		I69,		0,	0 },
@@ -328,7 +328,7 @@
  {"dmul",		"d,s,t",	0x0000009c, 0xfc0007ff, WR_1|RD_2|RD_3,		0,		I69,		0,	0 },
  {"dmul",		"d,v,t",	0x70000003, 0xfc0007ff, WR_1|RD_2|RD_3|WR_HILO,	0,		IOCT,		0,	0 },
  {"dmul",		"d,v,t",	0,    (int) M_DMUL,	INSN_MACRO,		0,		I3,		0,	M32|I69 },
-@@ -1243,9 +1249,9 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -1251,9 +1257,9 @@ const struct mips_opcode mips_builtin_opcodes[] =
  {"ld",			"s,-b(+R)",	0xec180000, 0xfc1c0000, WR_1,			RD_pc,		I69,		0,	0 },
  {"ld",			"t,A(b)",	0,    (int) M_LD_AB,	INSN_MACRO,		0,		I1,		0,	0 },
  {"ld",			"t,o(b)",	0xdc000000, 0xfc000000, WR_1|RD_3|LM,		0,		I3,		0,	0 },
@@ -341,7 +341,7 @@
  {"ldc1",		"T,o(b)",	0xd4000000, 0xfc000000, WR_1|RD_3|CLD|FP_D,	0,		I2,		0,	SF },
  {"ldc1",		"E,o(b)",	0xd4000000, 0xfc000000, WR_1|RD_3|CLD|FP_D,	0,		I2,		0,	SF },
  {"ldc1",		"T,A(b)",	0,    (int) M_LDC1_AB,	INSN_MACRO,		INSN2_M_FP_D,	I2,		0,	SF },
-@@ -1410,7 +1416,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -1418,7 +1424,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
  {"mflo",		"d,9",		0x00000012, 0xff9f07ff, WR_1|RD_LO,		0,		0,		D32,	0 },
  {"mflo1",		"d",		0x70000012, 0xffff07ff,	WR_1|RD_LO,		0,		EE,		0,	0 },
  {"mflhxu",		"d",		0x00000052, 0xffff07ff,	WR_1|MOD_HILO,		0,		0,		SMT,	0 },
@@ -350,7 +350,7 @@
  {"mfsa",		"d",		0x00000028, 0xffff07ff,	WR_1,			0,		EE,		0,	0 },
  {"min.ob",		"X,Y,Q",	0x78000006, 0xfc20003f,	WR_1|RD_2|RD_3|FP_D,	0,		SB1,		MX,	0 },
  {"min.ob",		"D,S,Q",	0x48000006, 0xfc20003f,	WR_1|RD_2|RD_3|FP_D,	0,		N54,		0,	0 },
-@@ -1455,10 +1461,13 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -1463,10 +1469,13 @@ const struct mips_opcode mips_builtin_opcodes[] =
  /* move is at the top of the table.  */
  {"msgn.qh",		"X,Y,Q",	0x78200000, 0xfc20003f,	WR_1|RD_2|RD_3|FP_D,	0,		0,		MX,	0 },
  {"msgsnd",		"t",		0,    (int) M_MSGSND,	INSN_MACRO,		0,		XLR,		0,	0 },
@@ -366,7 +366,7 @@
  {"msub.d",		"D,R,S,T",	0x4c000029, 0xfc00003f, WR_1|RD_2|RD_3|RD_4|FP_D, 0,		I4_33,		0,	I37 },
  {"msub.d",		"D,S,T",	0x46200019, 0xffe0003f,	WR_1|RD_2|RD_3|FP_D,	0,		IL2E,		0,	0 },
  {"msub.d",		"D,S,T",	0x72200019, 0xffe0003f,	WR_1|RD_2|RD_3|FP_D,	0,		IL2F,		0,	0 },
-@@ -1508,7 +1517,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -1516,7 +1525,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
  {"mtlo",		"s,7",		0x00000013, 0xfc1fe7ff, RD_1|WR_LO,		0,		0,		D32,	0 },
  {"mtlo1",		"s",		0x70000013, 0xfc1fffff,	RD_1|WR_LO,		0,		EE,		0,	0 },
  {"mtlhx",		"s",		0x00000053, 0xfc1fffff,	RD_1|MOD_HILO,		0,		0,		SMT,	0 },
@@ -375,7 +375,7 @@
  {"mtm0",		"s",		0x70000008, 0xfc1fffff, RD_1,			0,		IOCT,		0,	0 },
  {"mtm0",    		"s,t",		0x70000008, 0xfc00ffff, RD_1|RD_2,		0,		IOCT3,		0,	0 },
  {"mtm1",		"s",		0x7000000c, 0xfc1fffff, RD_1,			0,		IOCT,		0,	0 },
-@@ -1945,9 +1954,9 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -1953,9 +1962,9 @@ const struct mips_opcode mips_builtin_opcodes[] =
  {"suxc1",		"S,t(b)",	0x4c00000d, 0xfc0007ff, RD_1|RD_2|RD_3|SM|FP_D,	0,		I5_33|N55,	0,	I37},
  {"sw",			"t,o(b)",	0xac000000, 0xfc000000,	RD_1|RD_3|SM,		0,		I1,		0,	0 },
  {"sw",			"t,A(b)",	0,    (int) M_SW_AB,	INSN_MACRO,		0,		I1,		0,	0 },
@@ -389,5 +389,5 @@
  {"swc0",		"E,A(b)",	0,    (int) M_SWC0_AB,	INSN_MACRO,		0,		I1,		0,	IOCT|IOCTP|IOCT2|I37 },
  {"swc1",		"T,o(b)",	0xe4000000, 0xfc000000,	RD_1|RD_3|SM|FP_S,	0,		I1,		0,	0 },
 -- 
-2.16.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0013-fix-the-incorrect-assembling-for-ppc-wait-mnemonic.patch b/poky/meta/recipes-devtools/binutils/binutils/0013-fix-the-incorrect-assembling-for-ppc-wait-mnemonic.patch
index c3e1b13..c9ffdad 100644
--- a/poky/meta/recipes-devtools/binutils/binutils/0013-fix-the-incorrect-assembling-for-ppc-wait-mnemonic.patch
+++ b/poky/meta/recipes-devtools/binutils/binutils/0013-fix-the-incorrect-assembling-for-ppc-wait-mnemonic.patch
@@ -1,4 +1,4 @@
-From 27ec22ca3cd56cfdf060d2e1f414bedce269b322 Mon Sep 17 00:00:00 2001
+From d45455db35db5693c5efe0e1b384295e4c0db998 Mon Sep 17 00:00:00 2001
 From: Zhenhua Luo <zhenhua.luo@nxp.com>
 Date: Sat, 11 Jun 2016 22:08:29 -0500
 Subject: [PATCH 13/15] fix the incorrect assembling for ppc wait mnemonic
@@ -11,10 +11,10 @@
  1 file changed, 1 insertion(+), 2 deletions(-)
 
 diff --git a/opcodes/ppc-opc.c b/opcodes/ppc-opc.c
-index bb17f26c2e..dbdd762b4e 100644
+index 4a0fca5f0a..49f72fc35c 100644
 --- a/opcodes/ppc-opc.c
 +++ b/opcodes/ppc-opc.c
-@@ -5338,7 +5338,6 @@ const struct powerpc_opcode powerpc_opcodes[] = {
+@@ -5351,7 +5351,6 @@ const struct powerpc_opcode powerpc_opcodes[] = {
  {"ldepx",	X(31,29),	X_MASK,	  E500MC|PPCA2, 0,		{RT, RA0, RB}},
  
  {"waitasec",	X(31,30),      XRTRARB_MASK, POWER8,	POWER9,		{0}},
@@ -22,7 +22,7 @@
  
  {"lwepx",	X(31,31),	X_MASK,	  E500MC|PPCA2, 0,		{RT, RA0, RB}},
  
-@@ -5392,7 +5391,7 @@ const struct powerpc_opcode powerpc_opcodes[] = {
+@@ -5405,7 +5404,7 @@ const struct powerpc_opcode powerpc_opcodes[] = {
  
  {"waitrsv",	X(31,62)|(1<<21), 0xffffffff, E500MC|PPCA2, 0,		{0}},
  {"waitimpl",	X(31,62)|(2<<21), 0xffffffff, E500MC|PPCA2, 0,		{0}},
@@ -32,5 +32,5 @@
  {"dcbstep",	XRT(31,63,0),	XRT_MASK,    E500MC|PPCA2, 0,		{RA0, RB}},
  
 -- 
-2.16.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0014-Detect-64-bit-MIPS-targets.patch b/poky/meta/recipes-devtools/binutils/binutils/0014-Detect-64-bit-MIPS-targets.patch
index cf3690f..6197df6 100644
--- a/poky/meta/recipes-devtools/binutils/binutils/0014-Detect-64-bit-MIPS-targets.patch
+++ b/poky/meta/recipes-devtools/binutils/binutils/0014-Detect-64-bit-MIPS-targets.patch
@@ -1,4 +1,4 @@
-From 7dfbd6889d868a09d695dd2736104848c1a9c9c3 Mon Sep 17 00:00:00 2001
+From 9af90cfc35ff1fe78755578861473039836c467a Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 31 Mar 2017 11:42:03 -0700
 Subject: [PATCH 14/15] Detect 64-bit MIPS targets
@@ -46,5 +46,5 @@
   targ_obj=mips
   targ_machine=EM_MIPS
 -- 
-2.16.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0015-sync-with-OE-libtool-changes.patch b/poky/meta/recipes-devtools/binutils/binutils/0015-sync-with-OE-libtool-changes.patch
index 8c9fd23..7dc8ba8 100644
--- a/poky/meta/recipes-devtools/binutils/binutils/0015-sync-with-OE-libtool-changes.patch
+++ b/poky/meta/recipes-devtools/binutils/binutils/0015-sync-with-OE-libtool-changes.patch
@@ -1,4 +1,4 @@
-From 298804f430939d6cc94b09732ee93e64c5e6be18 Mon Sep 17 00:00:00 2001
+From f9e26bd29b5f017ea1307b51b5036063bff78600 Mon Sep 17 00:00:00 2001
 From: Ross Burton <ross.burton@intel.com>
 Date: Mon, 6 Mar 2017 23:33:27 -0800
 Subject: [PATCH 15/15] sync with OE libtool changes
@@ -85,5 +85,5 @@
  	elif test -n "$runpath_var"; then
  	  case "$finalize_perm_rpath " in
 -- 
-2.16.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0016-add-i386pep-emulation-for-x86_64.patch b/poky/meta/recipes-devtools/binutils/binutils/0016-add-i386pep-emulation-for-x86_64.patch
new file mode 100644
index 0000000..9f20784
--- /dev/null
+++ b/poky/meta/recipes-devtools/binutils/binutils/0016-add-i386pep-emulation-for-x86_64.patch
@@ -0,0 +1,41 @@
+binutils : enable x86_64-pep for producing EFI binaries on x86-64
+
+Add x86_64-pep emulation support to the set enabled for x86_64 targets
+to enable the linker to produce Portable Executables for EFI binaries.
+
+Enables building the x86-64 EFI variant of the Xen hypervisor for
+the OpenXT Project.
+
+Signed-off-by: Christopher Clark <christopher.clark6@baesystems.com>
+
+Upstream-Status: Inappropriate [OE configuration specific]
+---
+diff --git a/bfd/config.bfd b/bfd/config.bfd
+index c882421..dc705b6 100644
+--- a/bfd/config.bfd
++++ b/bfd/config.bfd
+@@ -688,7 +688,7 @@ case "${targ}" in
+     ;;
+   x86_64-*-linux-*)
+     targ_defvec=x86_64_elf64_vec
+-    targ_selvecs="i386_elf32_vec iamcu_elf32_vec x86_64_elf32_vec i386_pei_vec x86_64_pei_vec l1om_elf64_vec k1om_elf64_vec"
++    targ_selvecs="i386_elf32_vec iamcu_elf32_vec x86_64_elf32_vec i386_pei_vec x86_64_pei_vec l1om_elf64_vec k1om_elf64_vec x86_64_pe_vec x86_64_pe_be_vec i386_pe_vec"
+     want64=true
+     ;;
+   x86_64-*-nacl*)
+diff --git a/ld/configure.tgt b/ld/configure.tgt
+index a1db7ad..65a984a 100644
+--- a/ld/configure.tgt
++++ b/ld/configure.tgt
+@@ -253,8 +253,9 @@ x86_64-*-linux-gnux32)	targ_emul=elf32_x86_64
+ 			tdir_elf_iamcu=`echo ${targ_alias} | sed -e 's/x86_64/i386/' -e 's/-linux-gnux32/-linux-gnu/'`
+ 			tdir_elf_i386=`echo ${targ_alias} | sed -e 's/x86_64/i386/' -e 's/-linux-gnux32/-linux-gnu/'` ;;
+ x86_64-*-linux-*)	targ_emul=elf_x86_64
+-			targ_extra_emuls="elf32_x86_64 elf_i386 elf_iamcu elf_l1om elf_k1om"
+-			targ_extra_libpath="elf_i386 elf32_x86_64 elf_l1om elf_k1om"
++			targ_extra_emuls="elf32_x86_64 elf_i386 elf_iamcu elf_l1om elf_k1om i386pe i386pep"
++			targ_extra_libpath="elf_i386 elf32_x86_64 elf_l1om elf_k1om i386pep"
++			targ_extra_ofiles="deffilep.o pep-dll.o pe-dll.o"
+ 			tdir_elf_i386=`echo ${targ_alias} | sed -e 's/x86_64/i386/'` ;;
+ i[3-7]86-*-redox*)	targ_emul=elf_i386
+ 			targ_extra_emuls=elf_x86_64 ;;
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0017-improve-check-for-input-file-matching-output-file.patch b/poky/meta/recipes-devtools/binutils/binutils/0017-improve-check-for-input-file-matching-output-file.patch
new file mode 100644
index 0000000..265e526
--- /dev/null
+++ b/poky/meta/recipes-devtools/binutils/binutils/0017-improve-check-for-input-file-matching-output-file.patch
@@ -0,0 +1,59 @@
+From 2a50366ded329bfb39d387253450c9d5302c3503 Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Tue, 14 Aug 2018 12:22:35 +0100
+Subject: [PATCH] as.c: Improve check for input file matching output file.
+
+When the assembler reports that the input and output are the same, report the
+file names involved, in order to help debugging.  Also do not equate two files
+are the same if the have the same inode value but reside on different file
+systems.
+
+Upstream-Status: Backport
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ gas/as.c      | 27 ++++++++++++++++++++-------
+ 2 files changed, 20 insertions(+), 7 deletions(-)
+
+diff --git a/gas/as.c b/gas/as.c
+index b2a908a..3105d06 100644
+--- a/gas/as.c
++++ b/gas/as.c
+@@ -1259,14 +1259,27 @@ main (int argc, char ** argv)
+ 	{
+ 	  struct stat sib;
+ 
+-	  if (stat (argv[i], &sib) == 0)
++	  /* Check that the input file and output file are different.  */
++	  if (stat (argv[i], &sib) == 0
++	      && sib.st_ino == sob.st_ino
++	      /* POSIX emulating systems may support stat() but if the
++		 underlying file system does not support a file serial number
++		 of some kind then they will return 0 for the inode.  So
++		 two files with an inode of 0 may not actually be the same.
++		 On real POSIX systems no ordinary file will ever have an
++		 inode of 0.  */
++	      && sib.st_ino != 0
++	      /* Different files may have the same inode number if they
++		 reside on different devices, so check the st_dev field as
++		 well.  */
++	      && sib.st_dev == sob.st_dev)
+ 	    {
+-	      if (sib.st_ino == sob.st_ino && sib.st_ino != 0)
+-		{
+-		  /* Don't let as_fatal remove the output file!  */
+-		  out_file_name = NULL;
+-		  as_fatal (_("The input and output files must be distinct"));
+-		}
++	      const char *saved_out_file_name = out_file_name;
++
++	      /* Don't let as_fatal remove the output file!  */
++	      out_file_name = NULL;
++	      as_fatal (_("The input '%s' and output '%s' files are the same"),
++			argv[i], saved_out_file_name);
+ 	    }
+ 	}
+     }
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0018-Refactored-location-where-GOT-information-is-collect.patch b/poky/meta/recipes-devtools/binutils/binutils/0018-Refactored-location-where-GOT-information-is-collect.patch
new file mode 100644
index 0000000..d41339a
--- /dev/null
+++ b/poky/meta/recipes-devtools/binutils/binutils/0018-Refactored-location-where-GOT-information-is-collect.patch
@@ -0,0 +1,201 @@
+From d930affa2d475d1cc6792f1e6d56bef3d6c617db Mon Sep 17 00:00:00 2001
+From: Cupertino Miranda <cmiranda@synopsys.com>
+Date: Fri, 2 Mar 2018 17:16:21 +0100
+Subject: [PATCH] Refactored location where GOT information is collected.
+
+Change location where GOT information is collected for ARC target, avoiding
+posible use conflicts of the previous .got field in the symbols hash_entry.
+
+bfd/
+2018-03-01  Cupertino Miranda  <cmiranda@synopsys.com>
+
+	* arc-got.h (get_got_entry_list_for_symbol): Changed.
+	* ef32-arc.c (struct elf_arc_link_hash_entry): Moved and changed.
+	(elf_arc_link_hash_newfunc): Changed.
+	(arc_elf_link_hash_table_create): Removed old initializations.
+	(elf_arc_relocate_section, elf_arc_finish_dynamic_symbol): Changed.
+
+Signed-off-by: Cupertino Miranda <cmiranda@synopsys.com>
+Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
+[Romain: rebase on top of 2.31]
+Signed-off-by: Romain Naour <romain.naour@gmail.com>
+
+Upstream-Status: Pending
+---
+ bfd/arc-got.h   |  6 +++--
+ bfd/elf32-arc.c | 77 +++++++++++++++++++++++++++++++--------------------------
+ 2 files changed, 46 insertions(+), 37 deletions(-)
+
+diff --git a/bfd/arc-got.h b/bfd/arc-got.h
+index a86061bcb38..81ce88fe21a 100644
+--- a/bfd/arc-got.h
++++ b/bfd/arc-got.h
+@@ -156,9 +156,11 @@ get_got_entry_list_for_symbol (bfd *abfd,
+ 			       unsigned long r_symndx,
+ 			       struct elf_link_hash_entry *h)
+ {
+-  if (h != NULL)
++  struct elf_arc_link_hash_entry *h1 =
++    ((struct elf_arc_link_hash_entry *) h);
++  if (h1 != NULL)
+     {
+-      return &h->got.glist;
++      return &h1->got_ents;
+     }
+   else
+     {
+diff --git a/bfd/elf32-arc.c b/bfd/elf32-arc.c
+index a48ef0ca15f..ab84de43815 100644
+--- a/bfd/elf32-arc.c
++++ b/bfd/elf32-arc.c
+@@ -160,6 +160,18 @@ struct arc_relocation_data
+   const char *    symbol_name;
+ };
+ 
++/* ARC ELF linker hash entry.  */
++struct elf_arc_link_hash_entry
++{
++  struct elf_link_hash_entry root;
++
++  /* Track dynamic relocs copied for this symbol.  */
++  struct elf_dyn_relocs *dyn_relocs;
++
++  struct got_entry *got_ents;
++};
++
++
+ /* Should be included at this location due to static declarations
+    defined before this point.  */
+ #include "arc-got.h"
+@@ -281,15 +293,6 @@ struct arc_reloc_map
+   unsigned char		    elf_reloc_val;
+ };
+ 
+-/* ARC ELF linker hash entry.  */
+-struct elf_arc_link_hash_entry
+-{
+-  struct elf_link_hash_entry root;
+-
+-  /* Track dynamic relocs copied for this symbol.  */
+-  struct elf_dyn_relocs *dyn_relocs;
+-};
+-
+ /* ARC ELF linker hash table.  */
+ struct elf_arc_link_hash_table
+ {
+@@ -301,28 +304,28 @@ elf_arc_link_hash_newfunc (struct bfd_hash_entry *entry,
+ 			   struct bfd_hash_table *table,
+ 			   const char *string)
+ {
++  struct elf_arc_link_hash_entry * ret =
++    (struct elf_arc_link_hash_entry *) entry;
++
+   /* Allocate the structure if it has not already been allocated by a
+      subclass.  */
+-  if (entry == NULL)
+-    {
+-      entry = (struct bfd_hash_entry *)
+-	  bfd_hash_allocate (table,
+-			     sizeof (struct elf_arc_link_hash_entry));
+-      if (entry == NULL)
+-	return entry;
+-    }
++  if (ret == NULL)
++    ret = (struct elf_arc_link_hash_entry *)
++	bfd_hash_allocate (table, sizeof (struct elf_arc_link_hash_entry));
++  if (ret == NULL)
++    return (struct bfd_hash_entry *) ret;
+ 
+   /* Call the allocation method of the superclass.  */
+-  entry = _bfd_elf_link_hash_newfunc (entry, table, string);
+-  if (entry != NULL)
++  ret = ((struct elf_arc_link_hash_entry *)
++	 _bfd_elf_link_hash_newfunc ((struct bfd_hash_entry *) ret,
++				     table, string));
++  if (ret != NULL)
+     {
+-      struct elf_arc_link_hash_entry *eh;
+-
+-      eh = (struct elf_arc_link_hash_entry *) entry;
+-      eh->dyn_relocs = NULL;
++      ret->dyn_relocs = NULL;
++      ret->got_ents = NULL;
+     }
+ 
+-  return entry;
++  return (struct bfd_hash_entry *) ret;
+ }
+ 
+ /* Destroy an ARC ELF linker hash table.  */
+@@ -352,11 +355,6 @@ arc_elf_link_hash_table_create (bfd *abfd)
+       return NULL;
+     }
+ 
+-  ret->elf.init_got_refcount.refcount = 0;
+-  ret->elf.init_got_refcount.glist = NULL;
+-  ret->elf.init_got_offset.offset = 0;
+-  ret->elf.init_got_offset.glist = NULL;
+-
+   ret->elf.root.hash_table_free = elf_arc_link_hash_table_free;
+ 
+   return &ret->elf.root;
+@@ -1615,10 +1613,14 @@ elf_arc_relocate_section (bfd *			  output_bfd,
+ 	  while (h->root.type == bfd_link_hash_indirect
+ 		 || h->root.type == bfd_link_hash_warning)
+ 	  {
+-	    struct elf_link_hash_entry *h_old = h;
++	    struct elf_arc_link_hash_entry *ah_old =
++	      (struct elf_arc_link_hash_entry *) h;
+ 	    h = (struct elf_link_hash_entry *) h->root.u.i.link;
+-	    if (h->got.glist == 0 && h_old->got.glist != h->got.glist)
+-	      h->got.glist = h_old->got.glist;
++	    struct elf_arc_link_hash_entry *ah =
++	      (struct elf_arc_link_hash_entry *) h;
++
++	    if (ah->got_ents == 0 && ah_old->got_ents != ah->got_ents)
++	      ah->got_ents = ah_old->got_ents;
+ 	  }
+ 
+ 	  /* TODO: Need to validate what was the intention.  */
+@@ -1636,6 +1638,8 @@ elf_arc_relocate_section (bfd *			  output_bfd,
+ 
+ 	      if (is_reloc_for_GOT (howto) && !bfd_link_pic (info))
+ 		{
++		  struct elf_arc_link_hash_entry *ah =
++		    (struct elf_arc_link_hash_entry *) h;
+ 		  /* TODO: Change it to use arc_do_relocation with
+ 		    ARC_32 reloc.  Try to use ADD_RELA macro.  */
+ 		  bfd_vma relocation =
+@@ -1645,8 +1649,8 @@ elf_arc_relocate_section (bfd *			  output_bfd,
+ 			 + reloc_data.sym_section->output_section->vma)
+ 		      : 0);
+ 
+-		  BFD_ASSERT (h->got.glist);
+-		  bfd_vma got_offset = h->got.glist->offset;
++		  BFD_ASSERT (ah->got_ents);
++		  bfd_vma got_offset = ah->got_ents->offset;
+ 		  bfd_put_32 (output_bfd, relocation,
+ 			      htab->sgot->contents + got_offset);
+ 		}
+@@ -1958,6 +1962,7 @@ elf_arc_check_relocs (bfd *			 abfd,
+       else /* Global one.  */
+ 	h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+ 
++
+       switch (r_type)
+ 	{
+ 	  case R_ARC_32:
+@@ -2404,7 +2409,9 @@ elf_arc_finish_dynamic_symbol (bfd * output_bfd,
+      create respective dynamic relocs.  */
+   /* TODO: Make function to get list and not access the list directly.  */
+   /* TODO: Move function to relocate_section create this relocs eagerly.  */
+-  create_got_dynrelocs_for_got_info (&h->got.glist,
++  struct elf_arc_link_hash_entry *ah =
++    (struct elf_arc_link_hash_entry *) h;
++  create_got_dynrelocs_for_got_info (&ah->got_ents,
+ 				     output_bfd,
+ 				     info,
+ 				     h);
+-- 
+2.14.4
+
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0019-Improved-robustness.-Return-FALSE-in-case-of-NULL-po.patch b/poky/meta/recipes-devtools/binutils/binutils/0019-Improved-robustness.-Return-FALSE-in-case-of-NULL-po.patch
new file mode 100644
index 0000000..6a58ee0
--- /dev/null
+++ b/poky/meta/recipes-devtools/binutils/binutils/0019-Improved-robustness.-Return-FALSE-in-case-of-NULL-po.patch
@@ -0,0 +1,38 @@
+From 955176bd999fe80c5b937ab8786665079e35c387 Mon Sep 17 00:00:00 2001
+From: Cupertino Miranda <cmiranda@synopsys.com>
+Date: Fri, 2 Mar 2018 17:33:48 +0100
+Subject: [PATCH] Improved robustness. Return FALSE in case of NULL pointer.
+
+bfd/
+2018-03-01  Cupertino Miranda <cmiranda@synopsys.com>
+
+	* elf32-arc.c (elf_arc_finish_dynamic_symbol) Return FALSE in case
+	arc_htab is NULL.
+
+Signed-off-by: Cupertino Miranda <cmiranda@synopsys.com>
+Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
+[Romain: rebase on top of 2.31]
+Signed-off-by: Romain Naour <romain.naour@gmail.com>
+
+Upstream-Status: Pending
+---
+ bfd/elf32-arc.c | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/bfd/elf32-arc.c b/bfd/elf32-arc.c
+index ab84de43815..33fc72cff6e 100644
+--- a/bfd/elf32-arc.c
++++ b/bfd/elf32-arc.c
+@@ -2420,6 +2420,9 @@ elf_arc_finish_dynamic_symbol (bfd * output_bfd,
+     {
+       struct elf_arc_link_hash_table *arc_htab = elf_arc_hash_table (info);
+ 
++      if(arc_htab == NULL)
++	return FALSE;
++
+       if (h->dynindx == -1
+ 	  || (h->root.type != bfd_link_hash_defined
+ 	      && h->root.type != bfd_link_hash_defweak)
+-- 
+2.14.4
+
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0020-Make-sure-global-symbol-is-not-an-indirect-or-warnin.patch b/poky/meta/recipes-devtools/binutils/binutils/0020-Make-sure-global-symbol-is-not-an-indirect-or-warnin.patch
new file mode 100644
index 0000000..01e42c0
--- /dev/null
+++ b/poky/meta/recipes-devtools/binutils/binutils/0020-Make-sure-global-symbol-is-not-an-indirect-or-warnin.patch
@@ -0,0 +1,46 @@
+From 9d09ce14b4eef2b56f24660fd69a44acd45128b2 Mon Sep 17 00:00:00 2001
+From: Cupertino Miranda <cmiranda@synopsys.com>
+Date: Fri, 2 Mar 2018 17:38:14 +0100
+Subject: [PATCH] Make sure global symbol is not an indirect or warning.
+
+Problem identified in the context of glibc with latest upstream binutils.
+Dynamic symbol space was being reserved but, no actual information for the
+symbol was being set. Data for the symbol was kept initialized with -1.
+No easy test case was possible to be created.
+
+bfd/
+2018-03-01  Cupertino Miranda <cmiranda@synopsys.com>
+
+	* elf32-arc.c (elf_arc_check_relocs): Changed.
+
+Signed-off-by: Cupertino Miranda <cmiranda@synopsys.com>
+Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
+[Romain: rebase on top of 2.31]
+Signed-off-by: Romain Naour <romain.naour@gmail.com>
+
+Upstream-Status: Pending
+---
+ bfd/elf32-arc.c | 7 ++++++-
+ 1 file changed, 6 insertions(+), 1 deletion(-)
+
+diff --git a/bfd/elf32-arc.c b/bfd/elf32-arc.c
+index 33fc72cff6e..9b72c5b4f4f 100644
+--- a/bfd/elf32-arc.c
++++ b/bfd/elf32-arc.c
+@@ -1960,7 +1960,12 @@ elf_arc_check_relocs (bfd *			 abfd,
+       if (r_symndx < symtab_hdr->sh_info) /* Is a local symbol.  */
+ 	h = NULL;
+       else /* Global one.  */
+-	h = sym_hashes[r_symndx - symtab_hdr->sh_info];
++	{
++	  h = sym_hashes[r_symndx - symtab_hdr->sh_info];
++	  while (h->root.type == bfd_link_hash_indirect
++		 || h->root.type == bfd_link_hash_warning)
++	    h = (struct elf_link_hash_entry *) h->root.u.i.link;
++	}
+ 
+ 
+       switch (r_type)
+-- 
+2.14.4
+
diff --git a/poky/meta/recipes-devtools/binutils/binutils/0021-PLT-information-was-still-being-generated-when-symbo.patch b/poky/meta/recipes-devtools/binutils/binutils/0021-PLT-information-was-still-being-generated-when-symbo.patch
new file mode 100644
index 0000000..9e94239
--- /dev/null
+++ b/poky/meta/recipes-devtools/binutils/binutils/0021-PLT-information-was-still-being-generated-when-symbo.patch
@@ -0,0 +1,40 @@
+From e4861c68067cb2166b4c2bb9c052abeb6ad9aaa1 Mon Sep 17 00:00:00 2001
+From: Cupertino Miranda <cmiranda@synopsys.com>
+Date: Fri, 2 Mar 2018 17:44:29 +0100
+Subject: [PATCH] PLT information was still being generated when symbol was
+ forced_local.
+
+A change upstream reveiled this issue, triggering an assert when linking glibc.
+
+bfd/
+2018-03-01  Cupertino Miranda <cmiranda@synopsys.com>
+
+	* elf32-arc.c (elf_arc_check_relocs): Changed.
+
+Signed-off-by: Cupertino Miranda <cmiranda@synopsys.com>
+Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
+[Romain: rebase on top of 2.31]
+Signed-off-by: Romain Naour <romain.naour@gmail.com>
+
+Upstream-Status: Pending
+---
+ bfd/elf32-arc.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/bfd/elf32-arc.c b/bfd/elf32-arc.c
+index 9b72c5b4f4f..b40b463d34d 100644
+--- a/bfd/elf32-arc.c
++++ b/bfd/elf32-arc.c
+@@ -2041,7 +2041,8 @@ elf_arc_check_relocs (bfd *			 abfd,
+ 	  if (h == NULL)
+ 	    continue;
+ 	  else
+-	    h->needs_plt = 1;
++	    if(h->forced_local == 0)
++	      h->needs_plt = 1;
+ 	}
+ 
+       /* Add info to the symbol got_entry_list.  */
+-- 
+2.14.4
+
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-10372.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-10372.patch
deleted file mode 100644
index 053e9d8..0000000
--- a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-10372.patch
+++ /dev/null
@@ -1,58 +0,0 @@
-From 6aea08d9f3e3d6475a65454da488a0c51f5dc97d Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Tue, 17 Apr 2018 12:35:55 +0100
-Subject: [PATCH] Fix illegal memory access when parsing corrupt DWARF
- information.
-
-	PR 23064
-	* dwarf.c (process_cu_tu_index): Test for a potential buffer
-	overrun before copying signature pointer.
-
-Upstream-Status: Backport
-Affects: Binutils <= 2.30
-CVE: CVE-2018-10372
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- binutils/ChangeLog |  6 ++++++
- binutils/dwarf.c   | 13 ++++++++++++-
- 2 files changed, 18 insertions(+), 1 deletion(-)
-
-Index: git/binutils/dwarf.c
-===================================================================
---- git.orig/binutils/dwarf.c
-+++ git/binutils/dwarf.c
-@@ -9252,7 +9252,18 @@ process_cu_tu_index (struct dwarf_sectio
- 		}
- 
- 	      if (!do_display)
--		memcpy (&this_set[row - 1].signature, ph, sizeof (uint64_t));
-+		{
-+		  size_t num_copy = sizeof (uint64_t);
-+
-+		  /* PR 23064: Beware of buffer overflow.  */
-+		  if (ph + num_copy < limit)
-+		    memcpy (&this_set[row - 1].signature, ph, num_copy);
-+		  else
-+		    {
-+		      warn (_("Signature (%p) extends beyond end of space in section\n"), ph);
-+		      return 0;
-+		    }
-+		}
- 
- 	      prow = poffsets + (row - 1) * ncols * 4;
- 	      /* PR 17531: file: b8ce60a8.  */
-Index: git/binutils/ChangeLog
-===================================================================
---- git.orig/binutils/ChangeLog
-+++ git/binutils/ChangeLog
-@@ -1,3 +1,9 @@
-+2018-04-17  Nick Clifton  <nickc@redhat.com>
-+
-+       PR 23064
-+       * dwarf.c (process_cu_tu_index): Test for a potential buffer
-+       overrun before copying signature pointer.
-+
- 2018-01-27  Nick Clifton  <nickc@redhat.com>
- 
- 	Back to development.
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-10373.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-10373.patch
deleted file mode 100644
index d547cf1..0000000
--- a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-10373.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-From 6327533b1fd29fa86f6bf34e61c332c010e3c689 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Tue, 17 Apr 2018 14:30:07 +0100
-Subject: [PATCH] Add a check for a NULL table pointer before attempting to
- compute a DWARF filename.
-
-	PR 23065
-	* dwarf2.c (concat_filename): Check for a NULL table pointer.
-
-Upstream-Status: Backport
-Affects: Binutils <= 2.30
-CVE: CVE-2018-10373
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- bfd/ChangeLog | 5 +++++
- bfd/dwarf2.c  | 2 +-
- 2 files changed, 6 insertions(+), 1 deletion(-)
-
-Index: git/bfd/dwarf2.c
-===================================================================
---- git.orig/bfd/dwarf2.c
-+++ git/bfd/dwarf2.c
-@@ -1565,7 +1565,7 @@ concat_filename (struct line_info_table
- {
-   char *filename;
- 
--  if (file - 1 >= table->num_files)
-+  if (table == NULL || file - 1 >= table->num_files)
-     {
-       /* FILE == 0 means unknown.  */
-       if (file)
-Index: git/bfd/ChangeLog
-===================================================================
---- git.orig/bfd/ChangeLog
-+++ git/bfd/ChangeLog
-@@ -1,3 +1,8 @@
-+2018-04-17  Nick Clifton  <nickc@redhat.com>
-+
-+       PR 23065
-+       * dwarf2.c (concat_filename): Check for a NULL table pointer.
-+
- 2018-01-29  Alan Modra  <amodra@gmail.com>
- 
-        PR 22741
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-10534.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-10534.patch
deleted file mode 100644
index 6847020..0000000
--- a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-10534.patch
+++ /dev/null
@@ -1,3429 +0,0 @@
-From aa4a8c2a2a67545e90c877162c53cc9de42dc8b4 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Tue, 24 Apr 2018 16:31:27 +0100
-Subject: [PATCH] Fix an illegal memory access when copying a PE format file
- with corrupt debug information.
-
-	PR 23110
-	* peXXigen.c (_bfd_XX_bfd_copy_private_bfd_data_common): Check for
-	a negative PE_DEBUG_DATA size before iterating over the debug data.
-
-Upstream-Status: Backport
-Affects: Binutils <= 2.30
-CVE: CVE-2018-10534
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- bfd/ChangeLog  |    6 +
- bfd/peXXigen.c |    9 +
- bfd/po/bfd.pot | 5631 ++++++++++++++++++++++++++------------------------------
- 3 files changed, 2662 insertions(+), 2984 deletions(-)
-
-Index: git/bfd/peXXigen.c
-===================================================================
---- git.orig/bfd/peXXigen.c
-+++ git/bfd/peXXigen.c
-@@ -2991,6 +2991,15 @@ _bfd_XX_bfd_copy_private_bfd_data_common
- 				  bfd_get_section_size (section) - (addr - section->vma));
- 	      return FALSE;
- 	    }
-+	  /* PR 23110.  */
-+	  else if (ope->pe_opthdr.DataDirectory[PE_DEBUG_DATA].Size < 0)
-+	    {
-+	      /* xgettext:c-format */
-+	      _bfd_error_handler
-+		(_("%pB: Data Directory size (%#lx) is negative"),
-+		 obfd, ope->pe_opthdr.DataDirectory[PE_DEBUG_DATA].Size);
-+	      return FALSE;
-+	    }
- 
- 	  for (i = 0; i < ope->pe_opthdr.DataDirectory[PE_DEBUG_DATA].Size
- 		 / sizeof (struct external_IMAGE_DEBUG_DIRECTORY); i++)
-Index: git/bfd/po/bfd.pot
-===================================================================
---- git.orig/bfd/po/bfd.pot
-+++ git/bfd/po/bfd.pot
-@@ -18,175 +18,214 @@ msgstr ""
- "Content-Transfer-Encoding: 8bit\n"
- "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
- 
--#: aout-adobe.c:126
--#, c-format
--msgid "%B: Unknown section type in a.out.adobe file: %x\n"
--msgstr ""
--
- #: aout-cris.c:200
- #, c-format
--msgid "%B: Invalid relocation type exported: %d"
-+msgid "%pB: unsupported relocation type exported: %#x"
- msgstr ""
- 
- #: aout-cris.c:244
- #, c-format
--msgid "%B: Invalid relocation type imported: %d"
-+msgid "%pB: unsupported relocation type imported: %#x"
- msgstr ""
- 
- #: aout-cris.c:256
- #, c-format
--msgid "%B: Bad relocation record imported: %d"
-+msgid "%pB: bad relocation record imported: %d"
- msgstr ""
- 
--#: aoutx.h:1284 aoutx.h:1636 pdp11.c:1152 pdp11.c:1413
-+#: aoutx.h:1264 aoutx.h:1617 pdp11.c:1138 pdp11.c:1399
- #, c-format
--msgid "%B: can not represent section `%A' in a.out object file format"
-+msgid "%pB: can not represent section `%pA' in a.out object file format"
- msgstr ""
- 
--#: aoutx.h:1600 pdp11.c:1385
-+#: aoutx.h:1581 pdp11.c:1371
- #, c-format
- msgid ""
--"%B: can not represent section for symbol `%s' in a.out object file format"
-+"%pB: can not represent section for symbol `%s' in a.out object file format"
- msgstr ""
- 
--#: aoutx.h:1603 vms-alpha.c:7853
-+#: aoutx.h:1584 vms-alpha.c:7854
- msgid "*unknown*"
- msgstr ""
- 
--#: aoutx.h:2422 aoutx.h:2440
--msgid "%B: attempt to write out unknown reloc type"
-+#: aoutx.h:1720
-+#, c-format
-+msgid "%pB: invalid string offset %<PRIu64> >= %<PRIu64>"
- msgstr ""
- 
--#: aoutx.h:4093 aoutx.h:4414
--msgid "%P: %B: unexpected relocation type\n"
-+#: aoutx.h:2411 aoutx.h:2429
-+#, c-format
-+msgid "%pB: attempt to write out unknown reloc type"
- msgstr ""
- 
--#: aoutx.h:5440 pdp11.c:3708
-+#: aoutx.h:4084
- #, c-format
--msgid "%B: relocatable link from %s to %s not supported"
-+msgid "%pB: unsupported relocation type"
- msgstr ""
- 
--#: archive.c:2305
--msgid "Warning: writing archive was slow: rewriting timestamp\n"
-+#. Unknown relocation.
-+#: aoutx.h:4405 coff-alpha.c:601 coff-alpha.c:1514 coff-rs6000.c:2773
-+#: coff-sh.c:504 coff-tic4x.c:184 coff-tic54x.c:279 elf-hppa.h:1040
-+#: elf-hppa.h:1068 elf-m10200.c:226 elf-m10300.c:812 elf32-arc.c:519
-+#: elf32-arm.c:1852 elf32-avr.c:959 elf32-bfin.c:1061 elf32-bfin.c:4698
-+#: elf32-cr16.c:653 elf32-cr16.c:683 elf32-cr16c.c:186 elf32-cris.c:467
-+#: elf32-crx.c:429 elf32-d10v.c:234 elf32-d30v.c:522 elf32-d30v.c:544
-+#: elf32-dlx.c:548 elf32-epiphany.c:376 elf32-fr30.c:381 elf32-frv.c:2558
-+#: elf32-frv.c:6262 elf32-ft32.c:306 elf32-h8300.c:302 elf32-i386.c:401
-+#: elf32-ip2k.c:1245 elf32-iq2000.c:442 elf32-lm32.c:539 elf32-m32c.c:305
-+#: elf32-m32r.c:1286 elf32-m32r.c:1311 elf32-m32r.c:2417 elf32-m68hc11.c:390
-+#: elf32-m68hc12.c:510 elf32-m68k.c:352 elf32-mcore.c:354 elf32-mcore.c:440
-+#: elf32-mep.c:389 elf32-metag.c:878 elf32-microblaze.c:692
-+#: elf32-microblaze.c:969 elf32-mips.c:2229 elf32-moxie.c:137
-+#: elf32-msp430.c:648 elf32-msp430.c:658 elf32-mt.c:241 elf32-nds32.c:2880
-+#: elf32-nds32.c:2904 elf32-nds32.c:4423 elf32-nios2.c:3015 elf32-or1k.c:715
-+#: elf32-pj.c:325 elf32-ppc.c:2061 elf32-ppc.c:2074 elf32-pru.c:420
-+#: elf32-rl78.c:292 elf32-rx.c:314 elf32-rx.c:323 elf32-s390.c:347
-+#: elf32-sh.c:438 elf32-spu.c:160 elf32-tic6x.c:1508 elf32-tic6x.c:1518
-+#: elf32-tic6x.c:1537 elf32-tic6x.c:1547 elf32-tic6x.c:2642 elf32-tilepro.c:803
-+#: elf32-v850.c:1899 elf32-v850.c:1921 elf32-v850.c:4270 elf32-vax.c:290
-+#: elf32-visium.c:482 elf32-wasm32.c:106 elf32-xc16x.c:241 elf32-xgate.c:428
-+#: elf32-xstormy16.c:395 elf32-xtensa.c:454 elf32-xtensa.c:488
-+#: elf64-alpha.c:1112 elf64-alpha.c:4101 elf64-alpha.c:4249
-+#: elf64-ia64-vms.c:254 elf64-ia64-vms.c:3440 elf64-mips.c:3623
-+#: elf64-mips.c:3639 elf64-mmix.c:1264 elf64-ppc.c:2281 elf64-ppc.c:2555
-+#: elf64-ppc.c:2564 elf64-s390.c:328 elf64-s390.c:378 elf64-x86-64.c:285
-+#: elfn32-mips.c:3451 elfxx-ia64.c:325 elfxx-riscv.c:955 elfxx-sparc.c:589
-+#: elfxx-sparc.c:639 elfxx-sparc.c:661 elfxx-tilegx.c:912 elfxx-tilegx.c:952
-+#: /work/sources/binutils/current/bfd/elfnn-aarch64.c:2126
-+#: /work/sources/binutils/current/bfd/elfnn-aarch64.c:2224 elf32-ia64.c:211
-+#: elf32-ia64.c:3863 elf64-ia64.c:211 elf64-ia64.c:3863
-+#, c-format
-+msgid "%pB: unsupported relocation type %#x"
-+msgstr ""
-+
-+#: aoutx.h:5432 pdp11.c:3694
-+#, c-format
-+msgid "%pB: relocatable link from %s to %s not supported"
-+msgstr ""
-+
-+#: archive.c:2216
-+msgid "warning: writing archive was slow: rewriting timestamp"
- msgstr ""
- 
--#: archive.c:2421 linker.c:1410
--msgid "%B: plugin needed to handle lto object"
-+#: archive.c:2332 linker.c:1416
-+#, c-format
-+msgid "%pB: plugin needed to handle lto object"
- msgstr ""
- 
--#: archive.c:2650
-+#: archive.c:2561
- msgid "Reading archive file mod timestamp"
- msgstr ""
- 
--#: archive.c:2674
-+#: archive.c:2585
- msgid "Writing updated armap timestamp"
- msgstr ""
- 
-+#: bfd.c:448
-+msgid "no error"
-+msgstr ""
-+
-+#: bfd.c:449
-+msgid "system call error"
-+msgstr ""
-+
-+#: bfd.c:450
-+msgid "invalid bfd target"
-+msgstr ""
-+
-+#: bfd.c:451
-+msgid "file in wrong format"
-+msgstr ""
-+
-+#: bfd.c:452
-+msgid "archive object file in wrong format"
-+msgstr ""
-+
-+#: bfd.c:453
-+msgid "invalid operation"
-+msgstr ""
-+
- #: bfd.c:454
--msgid "No error"
-+msgid "memory exhausted"
- msgstr ""
- 
- #: bfd.c:455
--msgid "System call error"
-+msgid "no symbols"
- msgstr ""
- 
- #: bfd.c:456
--msgid "Invalid bfd target"
-+msgid "archive has no index; run ranlib to add one"
- msgstr ""
- 
- #: bfd.c:457
--msgid "File in wrong format"
-+msgid "no more archived files"
- msgstr ""
- 
- #: bfd.c:458
--msgid "Archive object file in wrong format"
-+msgid "malformed archive"
- msgstr ""
- 
- #: bfd.c:459
--msgid "Invalid operation"
-+msgid "DSO missing from command line"
- msgstr ""
- 
- #: bfd.c:460
--msgid "Memory exhausted"
-+msgid "file format not recognized"
- msgstr ""
- 
- #: bfd.c:461
--msgid "No symbols"
-+msgid "file format is ambiguous"
- msgstr ""
- 
- #: bfd.c:462
--msgid "Archive has no index; run ranlib to add one"
-+msgid "section has no contents"
- msgstr ""
- 
- #: bfd.c:463
--msgid "No more archived files"
-+msgid "nonrepresentable section on output"
- msgstr ""
- 
- #: bfd.c:464
--msgid "Malformed archive"
-+msgid "symbol needs debug section which does not exist"
- msgstr ""
- 
- #: bfd.c:465
--msgid "DSO missing from command line"
-+msgid "bad value"
- msgstr ""
- 
- #: bfd.c:466
--msgid "File format not recognized"
-+msgid "file truncated"
- msgstr ""
- 
- #: bfd.c:467
--msgid "File format is ambiguous"
-+msgid "file too big"
- msgstr ""
- 
- #: bfd.c:468
--msgid "Section has no contents"
--msgstr ""
--
--#: bfd.c:469
--msgid "Nonrepresentable section on output"
--msgstr ""
--
--#: bfd.c:470
--msgid "Symbol needs debug section which does not exist"
--msgstr ""
--
--#: bfd.c:471
--msgid "Bad value"
--msgstr ""
--
--#: bfd.c:472
--msgid "File truncated"
--msgstr ""
--
--#: bfd.c:473
--msgid "File too big"
--msgstr ""
--
--#: bfd.c:474
- #, c-format
--msgid "Error reading %s: %s"
-+msgid "error reading %s: %s"
- msgstr ""
- 
--#: bfd.c:475
--msgid "#<Invalid error code>"
-+#: bfd.c:469
-+msgid "#<invalid error code>"
- msgstr ""
- 
--#: bfd.c:1442
-+#: bfd.c:1416
- #, c-format
- msgid "BFD %s assertion fail %s:%d"
- msgstr ""
- 
--#: bfd.c:1455
-+#: bfd.c:1429
- #, c-format
- msgid "BFD %s internal error, aborting at %s:%d in %s\n"
- msgstr ""
- 
--#: bfd.c:1460
-+#: bfd.c:1434
- #, c-format
- msgid "BFD %s internal error, aborting at %s:%d\n"
- msgstr ""
- 
--#: bfd.c:1462
-+#: bfd.c:1436
- msgid "Please report this bug.\n"
- msgstr ""
- 
-@@ -332,7 +371,7 @@ msgstr ""
- msgid "private flags = %x:"
- msgstr ""
- 
--#: coff-arm.c:2306 elf32-arm.c:14160
-+#: coff-arm.c:2306 elf32-arm.c:14191
- #, c-format
- msgid " [floats passed in float registers]"
- msgstr ""
-@@ -342,7 +381,7 @@ msgstr ""
- msgid " [floats passed in integer registers]"
- msgstr ""
- 
--#: coff-arm.c:2311 elf32-arm.c:14163
-+#: coff-arm.c:2311 elf32-arm.c:14194
- #, c-format
- msgid " [position independent]"
- msgstr ""
-@@ -2565,224 +2604,180 @@ msgstr ""
- msgid "ip2k relaxer: switch table header corrupt."
- msgstr ""
- 
--#: elf32-ip2k.c:1245
--#, c-format
--msgid "%B: invalid IP2K reloc number: %d"
--msgstr ""
--
--#: elf32-ip2k.c:1298
--#, c-format
--msgid "ip2k linker: missing page instruction at %#Lx (dest = %#Lx)"
--msgstr ""
--
--#: elf32-ip2k.c:1315
--#, c-format
--msgid "ip2k linker: redundant page instruction at %#Lx (dest = %#Lx)"
--msgstr ""
--
--#: elf32-iq2000.c:441
-+#: elf32-ip2k.c:1302
- #, c-format
--msgid "%B: invalid IQ2000 reloc number: %d"
-+msgid "ip2k linker: missing page instruction at %#<PRIx64> (dest = %#<PRIx64>)"
- msgstr ""
- 
--#: elf32-lm32.c:539
-+#: elf32-ip2k.c:1321
- #, c-format
--msgid "%B: invalid LM32 reloc number: %d"
-+msgid ""
-+"ip2k linker: redundant page instruction at %#<PRIx64> (dest = %#<PRIx64>)"
- msgstr ""
- 
--#: elf32-lm32.c:648 elf32-nios2.c:3133
-+#: elf32-lm32.c:651 elf32-nios2.c:3141
- msgid "global pointer relative relocation when _gp not defined"
- msgstr ""
- 
--#: elf32-lm32.c:703 elf32-nios2.c:3570
-+#: elf32-lm32.c:706 elf32-nios2.c:3578
- msgid "global pointer relative address out of range"
- msgstr ""
- 
--#: elf32-lm32.c:998
--msgid "internal error: addend should be zero for R_LM32_16_GOT"
--msgstr ""
--
--#: elf32-m32c.c:306
-+#: elf32-lm32.c:1002 elf32-or1k.c:968
- #, c-format
--msgid "%B: invalid M32C reloc number: %d"
-+msgid "internal error: addend should be zero for %s"
- msgstr ""
- 
--#: elf32-m32r.c:1286
--#, c-format
--msgid "%B: invalid M32R reloc number: %d"
--msgstr ""
--
--#: elf32-m32r.c:1458
-+#: elf32-m32r.c:1471
- msgid "SDA relocation when _SDA_BASE_ not defined"
- msgstr ""
- 
--#: elf32-m32r.c:2971 elf32-microblaze.c:1064 elf32-microblaze.c:1112
-+#: elf32-m32r.c:2984 elf32-microblaze.c:1101 elf32-microblaze.c:1149
- #, c-format
--msgid "%B: The target (%s) of an %s relocation is in the wrong section (%A)"
-+msgid "%pB: the target (%s) of an %s relocation is in the wrong section (%pA)"
- msgstr ""
- 
--#: elf32-m32r.c:3473
--msgid "%B: Instruction set mismatch with previous modules"
-+#: elf32-m32r.c:3487
-+#, c-format
-+msgid "%pB: instruction set mismatch with previous modules"
- msgstr ""
- 
--#: elf32-m32r.c:3494 elf32-nds32.c:6037
-+#: elf32-m32r.c:3508 elf32-nds32.c:6010
- #, c-format
- msgid "private flags = %lx"
- msgstr ""
- 
--#: elf32-m32r.c:3499
-+#: elf32-m32r.c:3513
- #, c-format
- msgid ": m32r instructions"
- msgstr ""
- 
--#: elf32-m32r.c:3500
-+#: elf32-m32r.c:3514
- #, c-format
- msgid ": m32rx instructions"
- msgstr ""
- 
--#: elf32-m32r.c:3501
-+#: elf32-m32r.c:3515
- #, c-format
- msgid ": m32r2 instructions"
- msgstr ""
- 
--#: elf32-m68hc11.c:390
--#, c-format
--msgid "%B: invalid M68HC11 reloc number: %d"
--msgstr ""
--
--#: elf32-m68hc12.c:510
--#, c-format
--msgid "%B: invalid M68HC12 reloc number: %d"
--msgstr ""
--
--#: elf32-m68hc1x.c:1115
-+#: elf32-m68hc1x.c:1116
- #, c-format
- msgid ""
--"Reference to the far symbol `%s' using a wrong relocation may result in "
-+"reference to the far symbol `%s' using a wrong relocation may result in "
- "incorrect execution"
- msgstr ""
- 
--#: elf32-m68hc1x.c:1149
-+#: elf32-m68hc1x.c:1150
- #, c-format
- msgid ""
- "XGATE address (%lx) is not within shared RAM(0xE000-0xFFFF), therefore you "
- "must manually offset the address, and possibly manage the page, in your code."
- msgstr ""
- 
--#: elf32-m68hc1x.c:1167
-+#: elf32-m68hc1x.c:1168
- #, c-format
- msgid ""
- "banked address [%lx:%04lx] (%lx) is not in the same bank as current banked "
- "address [%lx:%04lx] (%lx)"
- msgstr ""
- 
--#: elf32-m68hc1x.c:1183
-+#: elf32-m68hc1x.c:1184
- #, c-format
- msgid ""
- "reference to a banked address [%lx:%04lx] in the normal address space at "
- "%04lx"
- msgstr ""
- 
--#: elf32-m68hc1x.c:1224
-+#: elf32-m68hc1x.c:1225
- #, c-format
- msgid ""
- "S12 address (%lx) is not within shared RAM(0x2000-0x4000), therefore you "
- "must manually offset the address in your code"
- msgstr ""
- 
--#: elf32-m68hc1x.c:1351
-+#: elf32-m68hc1x.c:1352
-+#, c-format
- msgid ""
--"%B: linking files compiled for 16-bit integers (-mshort) and others for 32-"
-+"%pB: linking files compiled for 16-bit integers (-mshort) and others for 32-"
- "bit integers"
- msgstr ""
- 
--#: elf32-m68hc1x.c:1358
-+#: elf32-m68hc1x.c:1359
-+#, c-format
- msgid ""
--"%B: linking files compiled for 32-bit double (-fshort-double) and others for "
--"64-bit double"
-+"%pB: linking files compiled for 32-bit double (-fshort-double) and others "
-+"for 64-bit double"
- msgstr ""
- 
--#: elf32-m68hc1x.c:1367
--msgid "%B: linking files compiled for HCS12 with others compiled for HC12"
-+#: elf32-m68hc1x.c:1368
-+#, c-format
-+msgid "%pB: linking files compiled for HCS12 with others compiled for HC12"
- msgstr ""
- 
--#: elf32-m68hc1x.c:1412 elf32-xgate.c:672
-+#: elf32-m68hc1x.c:1413 elf32-xgate.c:675
- #, c-format
- msgid "[abi=32-bit int, "
- msgstr ""
- 
--#: elf32-m68hc1x.c:1414 elf32-xgate.c:674
-+#: elf32-m68hc1x.c:1415 elf32-xgate.c:677
- #, c-format
- msgid "[abi=16-bit int, "
- msgstr ""
- 
--#: elf32-m68hc1x.c:1417 elf32-xgate.c:677
-+#: elf32-m68hc1x.c:1418 elf32-xgate.c:680
- #, c-format
- msgid "64-bit double, "
- msgstr ""
- 
--#: elf32-m68hc1x.c:1419 elf32-xgate.c:679
-+#: elf32-m68hc1x.c:1420 elf32-xgate.c:682
- #, c-format
- msgid "32-bit double, "
- msgstr ""
- 
--#: elf32-m68hc1x.c:1422
-+#: elf32-m68hc1x.c:1423
- #, c-format
- msgid "cpu=HC11]"
- msgstr ""
- 
--#: elf32-m68hc1x.c:1424
-+#: elf32-m68hc1x.c:1425
- #, c-format
- msgid "cpu=HCS12]"
- msgstr ""
- 
--#: elf32-m68hc1x.c:1426
-+#: elf32-m68hc1x.c:1427
- #, c-format
- msgid "cpu=HC12]"
- msgstr ""
- 
--#: elf32-m68hc1x.c:1429
-+#: elf32-m68hc1x.c:1430
- #, c-format
- msgid " [memory=bank-model]"
- msgstr ""
- 
--#: elf32-m68hc1x.c:1431
-+#: elf32-m68hc1x.c:1432
- #, c-format
- msgid " [memory=flat]"
- msgstr ""
- 
--#: elf32-m68hc1x.c:1434
-+#: elf32-m68hc1x.c:1435
- #, c-format
- msgid " [XGATE RAM offsetting]"
- msgstr ""
- 
--#: elf32-m68k.c:1214 elf32-m68k.c:1215 vms-alpha.c:7477 vms-alpha.c:7493
-+#: elf32-m68k.c:1216 elf32-m68k.c:1217 vms-alpha.c:7478 vms-alpha.c:7494
- msgid "unknown"
- msgstr ""
- 
--#: elf32-m68k.c:1658
--#, c-format
--msgid "%B: GOT overflow: Number of relocations with 8-bit offset > %d"
--msgstr ""
--
--#: elf32-m68k.c:1665
--#, c-format
--msgid "%B: GOT overflow: Number of relocations with 8- or 16-bit offset > %d"
--msgstr ""
--
--#: elf32-mcore.c:100 elf32-mcore.c:455
-+#: elf32-m68k.c:1660
- #, c-format
--msgid "%B: Relocation %s (%d) is not currently supported.\n"
-+msgid "%pB: GOT overflow: number of relocations with 8-bit offset > %d"
- msgstr ""
- 
--#: elf32-mcore.c:355
-+#: elf32-m68k.c:1667
- #, c-format
--msgid "%B: unrecognised MCore reloc number: %d"
--msgstr ""
--
--#: elf32-mcore.c:440
--#, c-format
--msgid "%B: Unknown relocation type %d\n"
-+msgid "%pB: GOT overflow: number of relocations with 8- or 16-bit offset > %d"
- msgstr ""
- 
- #. Pacify gcc -Wall.
-@@ -5936,124 +5931,128 @@ msgstr ""
- #. XXX code yet to be written.
- #: peicode.h:775
- #, c-format
--msgid "%B: Unhandled import type; %x"
-+msgid "%pB: unhandled import type; %x"
- msgstr ""
- 
- #: peicode.h:781
- #, c-format
--msgid "%B: Unrecognised import type; %x"
-+msgid "%pB: unrecognized import type; %x"
- msgstr ""
- 
- #: peicode.h:796
- #, c-format
--msgid "%B: Unrecognised import name type; %x"
-+msgid "%pB: unrecognized import name type; %x"
- msgstr ""
- 
--#: peicode.h:1217
-+#: peicode.h:1211
- #, c-format
--msgid "%B: Unrecognised machine type (0x%x) in Import Library Format archive"
-+msgid "%pB: unrecognised machine type (0x%x) in Import Library Format archive"
- msgstr ""
- 
--#: peicode.h:1230
-+#: peicode.h:1224
- #, c-format
- msgid ""
--"%B: Recognised but unhandled machine type (0x%x) in Import Library Format "
-+"%pB: recognised but unhandled machine type (0x%x) in Import Library Format "
- "archive"
- msgstr ""
- 
--#: peicode.h:1248
--msgid "%B: size field is zero in Import Library Format header"
-+#: peicode.h:1242
-+#, c-format
-+msgid "%pB: size field is zero in Import Library Format header"
- msgstr ""
- 
--#: peicode.h:1280
--msgid "%B: string not null terminated in ILF object file."
-+#: peicode.h:1274
-+#, c-format
-+msgid "%pB: string not null terminated in ILF object file"
- msgstr ""
- 
--#: peicode.h:1335
--msgid "%B: Error: Debug Data ends beyond end of debug directory."
-+#: peicode.h:1330
-+#, c-format
-+msgid "%pB: error: debug data ends beyond end of debug directory"
- msgstr ""
- 
--#: ppcboot.c:393
-+#: ppcboot.c:392
- #, c-format
- msgid ""
- "\n"
- "ppcboot header:\n"
- msgstr ""
- 
--#: ppcboot.c:394
-+#: ppcboot.c:393
- #, c-format
- msgid "Entry offset        = 0x%.8lx (%ld)\n"
- msgstr ""
- 
--#: ppcboot.c:396
-+#: ppcboot.c:395
- #, c-format
- msgid "Length              = 0x%.8lx (%ld)\n"
- msgstr ""
- 
--#: ppcboot.c:400
-+#: ppcboot.c:399
- #, c-format
- msgid "Flag field          = 0x%.2x\n"
- msgstr ""
- 
--#: ppcboot.c:406
-+#: ppcboot.c:405
- #, c-format
- msgid "Partition name      = \"%s\"\n"
- msgstr ""
- 
--#: ppcboot.c:426
-+#: ppcboot.c:425
- #, c-format
- msgid ""
- "\n"
- "Partition[%d] start  = { 0x%.2x, 0x%.2x, 0x%.2x, 0x%.2x }\n"
- msgstr ""
- 
--#: ppcboot.c:433
-+#: ppcboot.c:432
- #, c-format
- msgid "Partition[%d] end    = { 0x%.2x, 0x%.2x, 0x%.2x, 0x%.2x }\n"
- msgstr ""
- 
--#: ppcboot.c:440
-+#: ppcboot.c:439
- #, c-format
- msgid "Partition[%d] sector = 0x%.8lx (%ld)\n"
- msgstr ""
- 
--#: ppcboot.c:444
-+#: ppcboot.c:443
- #, c-format
- msgid "Partition[%d] length = 0x%.8lx (%ld)\n"
- msgstr ""
- 
--#: reloc.c:8106
--msgid "INPUT_SECTION_FLAGS are not supported.\n"
-+#: reloc.c:8125
-+msgid "INPUT_SECTION_FLAGS are not supported"
- msgstr ""
- 
--#: reloc.c:8207
-+#: reloc.c:8226
- #, c-format
--msgid "%X%P: %B(%A): error: relocation for offset %V has no value\n"
-+msgid "%X%P: %pB(%pA): error: relocation for offset %V has no value\n"
- msgstr ""
- 
--#: reloc.c:8283
-+#: reloc.c:8302
- #, c-format
--msgid "%X%P: %B(%A): relocation \"%R\" is not supported\n"
-+msgid "%X%P: %pB(%pA): relocation \"%pR\" is not supported\n"
- msgstr ""
- 
--#: reloc.c:8292
-+#: reloc.c:8311
- #, c-format
--msgid "%X%P: %B(%A): relocation \"%R\" returns an unrecognized value %x\n"
-+msgid "%X%P: %pB(%pA): relocation \"%pR\" returns an unrecognized value %x\n"
- msgstr ""
- 
--#: reloc.c:8354
-+#: reloc.c:8373
- #, c-format
--msgid "%B: unrecognized relocation (%#x) in section `%A'"
-+msgid "%pB: unrecognized relocation type %#x in section `%pA'"
- msgstr ""
- 
- #. PR 21803: Suggest the most likely cause of this error.
--#: reloc.c:8358
-+#: reloc.c:8377
- #, c-format
--msgid "Is this version of the linker - %s - out of date ?"
-+msgid "is this version of the linker - %s - out of date ?"
- msgstr ""
- 
- #: rs6000-core.c:471
--msgid "%B: warning core file truncated"
-+#, c-format
-+msgid "%pB: warning core file truncated"
- msgstr ""
- 
- #: som.c:5478
-@@ -6069,91 +6068,91 @@ msgstr ""
- 
- #: srec.c:260
- #, c-format
--msgid "%B:%d: Unexpected character `%s' in S-record file\n"
-+msgid "%pB:%d: unexpected character `%s' in S-record file"
- msgstr ""
- 
- #: srec.c:488
- #, c-format
--msgid "%B:%d: byte count %d too small\n"
-+msgid "%pB:%d: byte count %d too small"
- msgstr ""
- 
- #: srec.c:581 srec.c:615
- #, c-format
--msgid "%B:%d: Bad checksum in S-record file\n"
-+msgid "%pB:%d: bad checksum in S-record file"
- msgstr ""
- 
- #: stabs.c:279
- #, c-format
--msgid "%B(%A+%#lx): Stabs entry has invalid string index."
-+msgid "%pB(%pA+%#lx): stabs entry has invalid string index"
- msgstr ""
- 
- #: syms.c:1079
--msgid "Unsupported .stab relocation"
-+msgid "unsupported .stab relocation"
- msgstr ""
- 
- #: vms-alpha.c:479
--msgid "Corrupt EIHD record - size is too small"
-+msgid "corrupt EIHD record - size is too small"
- msgstr ""
- 
- #: vms-alpha.c:660
- #, c-format
--msgid "Unable to read EIHS record at offset %#x"
-+msgid "unable to read EIHS record at offset %#x"
- msgstr ""
- 
--#: vms-alpha.c:1172
-+#: vms-alpha.c:1173
- #, c-format
--msgid "Corrupt EGSD record: its size (%#x) is too small"
-+msgid "corrupt EGSD record: its size (%#x) is too small"
- msgstr ""
- 
--#: vms-alpha.c:1196
-+#: vms-alpha.c:1197
- #, c-format
--msgid "Corrupt EGSD record: size (%#x) is larger than remaining space (%#x)"
-+msgid "corrupt EGSD record: size (%#x) is larger than remaining space (%#x)"
- msgstr ""
- 
--#: vms-alpha.c:1204
-+#: vms-alpha.c:1205
- #, c-format
--msgid "Corrupt EGSD record: size (%#x) is too small"
-+msgid "corrupt EGSD record: size (%#x) is too small"
- msgstr ""
- 
--#: vms-alpha.c:1333 vms-alpha.c:1349 vms-alpha.c:1389
-+#: vms-alpha.c:1334 vms-alpha.c:1350 vms-alpha.c:1390
- #, c-format
--msgid "Corrupt EGSD record: its psindx field is too big (%#lx)"
-+msgid "corrupt EGSD record: its psindx field is too big (%#lx)"
- msgstr ""
- 
--#: vms-alpha.c:1418
-+#: vms-alpha.c:1419
- #, c-format
--msgid "Unknown EGSD subtype %d"
-+msgid "unknown EGSD subtype %d"
- msgstr ""
- 
--#: vms-alpha.c:1451
-+#: vms-alpha.c:1452
- #, c-format
--msgid "Stack overflow (%d) in _bfd_vms_push"
-+msgid "stack overflow (%d) in _bfd_vms_push"
- msgstr ""
- 
--#: vms-alpha.c:1464
--msgid "Stack underflow in _bfd_vms_pop"
-+#: vms-alpha.c:1465
-+msgid "stack underflow in _bfd_vms_pop"
- msgstr ""
- 
- #. These names have not yet been added to this switch statement.
--#: vms-alpha.c:1706
-+#: vms-alpha.c:1707
- #, c-format
- msgid "unknown ETIR command %d"
- msgstr ""
- 
--#: vms-alpha.c:1737
--msgid "Corrupt vms value"
-+#: vms-alpha.c:1738
-+msgid "corrupt vms value"
- msgstr ""
- 
--#: vms-alpha.c:1865
--msgid "Corrupt ETIR record encountered"
-+#: vms-alpha.c:1866
-+msgid "corrupt ETIR record encountered"
- msgstr ""
- 
--#: vms-alpha.c:1922
-+#: vms-alpha.c:1923
- #, c-format
- msgid "bad section index in %s"
- msgstr ""
- 
--#: vms-alpha.c:1935
-+#: vms-alpha.c:1936
- #, c-format
- msgid "unsupported STA cmd %s"
- msgstr ""
-@@ -6163,1961 +6162,1932 @@ msgstr ""
- #. Rotate.
- #. Redefine symbol to current location.
- #. Define a literal.
--#: vms-alpha.c:2115 vms-alpha.c:2146 vms-alpha.c:2237 vms-alpha.c:2395
-+#: vms-alpha.c:2116 vms-alpha.c:2147 vms-alpha.c:2238 vms-alpha.c:2396
- #, c-format
- msgid "%s: not supported"
- msgstr ""
- 
--#: vms-alpha.c:2121
-+#: vms-alpha.c:2122
- #, c-format
- msgid "%s: not implemented"
- msgstr ""
- 
--#: vms-alpha.c:2379
-+#: vms-alpha.c:2380
- #, c-format
- msgid "invalid use of %s with contexts"
- msgstr ""
- 
--#: vms-alpha.c:2413
-+#: vms-alpha.c:2414
- #, c-format
- msgid "reserved cmd %d"
- msgstr ""
- 
--#: vms-alpha.c:2497
--msgid "Corrupt EEOM record - size is too small"
-+#: vms-alpha.c:2498
-+msgid "corrupt EEOM record - size is too small"
- msgstr ""
- 
--#: vms-alpha.c:2506
--msgid "Object module NOT error-free !\n"
-+#: vms-alpha.c:2507
-+msgid "object module not error-free !"
- msgstr ""
- 
--#: vms-alpha.c:3830
-+#: vms-alpha.c:3831
- #, c-format
--msgid "SEC_RELOC with no relocs in section %A"
-+msgid "SEC_RELOC with no relocs in section %pA"
- msgstr ""
- 
--#: vms-alpha.c:3882 vms-alpha.c:4095
-+#: vms-alpha.c:3883 vms-alpha.c:4096
- #, c-format
--msgid "Size error in section %A"
-+msgid "size error in section %pA"
- msgstr ""
- 
--#: vms-alpha.c:4041
--msgid "Spurious ALPHA_R_BSR reloc"
-+#: vms-alpha.c:4042
-+msgid "spurious ALPHA_R_BSR reloc"
- msgstr ""
- 
--#: vms-alpha.c:4082
-+#: vms-alpha.c:4083
- #, c-format
--msgid "Unhandled relocation %s"
-+msgid "unhandled relocation %s"
- msgstr ""
- 
--#: vms-alpha.c:4375
-+#: vms-alpha.c:4376
- #, c-format
- msgid "unknown source command %d"
- msgstr ""
- 
--#: vms-alpha.c:4436
--msgid "DST__K_SET_LINUM_INCR not implemented"
--msgstr ""
--
--#: vms-alpha.c:4442
--msgid "DST__K_SET_LINUM_INCR_W not implemented"
--msgstr ""
--
--#: vms-alpha.c:4448
--msgid "DST__K_RESET_LINUM_INCR not implemented"
--msgstr ""
--
--#: vms-alpha.c:4454
--msgid "DST__K_BEG_STMT_MODE not implemented"
--msgstr ""
--
--#: vms-alpha.c:4460
--msgid "DST__K_END_STMT_MODE not implemented"
--msgstr ""
--
--#: vms-alpha.c:4487
--msgid "DST__K_SET_PC not implemented"
--msgstr ""
--
--#: vms-alpha.c:4493
--msgid "DST__K_SET_PC_W not implemented"
--msgstr ""
--
--#: vms-alpha.c:4499
--msgid "DST__K_SET_PC_L not implemented"
--msgstr ""
--
--#: vms-alpha.c:4505
--msgid "DST__K_SET_STMTNUM not implemented"
-+#: vms-alpha.c:4437 vms-alpha.c:4443 vms-alpha.c:4449 vms-alpha.c:4455
-+#: vms-alpha.c:4461 vms-alpha.c:4488 vms-alpha.c:4494 vms-alpha.c:4500
-+#: vms-alpha.c:4506
-+#, c-format
-+msgid "%s not implemented"
- msgstr ""
- 
--#: vms-alpha.c:4548
-+#: vms-alpha.c:4549
- #, c-format
- msgid "unknown line command %d"
- msgstr ""
- 
--#: vms-alpha.c:5008 vms-alpha.c:5026 vms-alpha.c:5041 vms-alpha.c:5057
--#: vms-alpha.c:5070 vms-alpha.c:5082 vms-alpha.c:5095
-+#: vms-alpha.c:5009 vms-alpha.c:5027 vms-alpha.c:5042 vms-alpha.c:5058
-+#: vms-alpha.c:5071 vms-alpha.c:5083 vms-alpha.c:5096
- #, c-format
--msgid "Unknown reloc %s + %s"
-+msgid "unknown reloc %s + %s"
- msgstr ""
- 
--#: vms-alpha.c:5150
-+#: vms-alpha.c:5151
- #, c-format
--msgid "Unknown reloc %s"
-+msgid "unknown reloc %s"
- msgstr ""
- 
--#: vms-alpha.c:5163
--msgid "Invalid section index in ETIR"
-+#: vms-alpha.c:5164
-+msgid "invalid section index in ETIR"
- msgstr ""
- 
--#: vms-alpha.c:5172
--msgid "Relocation for non-REL psect"
-+#: vms-alpha.c:5173
-+msgid "relocation for non-REL psect"
- msgstr ""
- 
--#: vms-alpha.c:5219
-+#: vms-alpha.c:5220
- #, c-format
--msgid "Unknown symbol in command %s"
-+msgid "unknown symbol in command %s"
- msgstr ""
- 
--#: vms-alpha.c:5629
-+#: vms-alpha.c:5630
- #, c-format
- msgid "reloc (%d) is *UNKNOWN*"
- msgstr ""
- 
--#: vms-alpha.c:5745
-+#: vms-alpha.c:5746
- #, c-format
- msgid "  EMH %u (len=%u): "
- msgstr ""
- 
--#: vms-alpha.c:5750
-+#: vms-alpha.c:5751
- #, c-format
- msgid "   Error: The length is less than the length of an EMH record\n"
- msgstr ""
- 
--#: vms-alpha.c:5767
-+#: vms-alpha.c:5768
- #, c-format
- msgid ""
- "   Error: The record length is less than the size of an EMH_MHD record\n"
- msgstr ""
- 
--#: vms-alpha.c:5770
-+#: vms-alpha.c:5771
- #, c-format
- msgid "Module header\n"
- msgstr ""
- 
--#: vms-alpha.c:5771
-+#: vms-alpha.c:5772
- #, c-format
- msgid "   structure level: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:5772
-+#: vms-alpha.c:5773
- #, c-format
- msgid "   max record size: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:5778
-+#: vms-alpha.c:5779
- #, c-format
- msgid "   Error: The module name is missing\n"
- msgstr ""
- 
--#: vms-alpha.c:5784
-+#: vms-alpha.c:5785
- #, c-format
- msgid "   Error: The module name is too long\n"
- msgstr ""
- 
--#: vms-alpha.c:5787
-+#: vms-alpha.c:5788
- #, c-format
- msgid "   module name    : %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:5791
-+#: vms-alpha.c:5792
- #, c-format
- msgid "   Error: The module version is missing\n"
- msgstr ""
- 
--#: vms-alpha.c:5797
-+#: vms-alpha.c:5798
- #, c-format
- msgid "   Error: The module version is too long\n"
- msgstr ""
- 
--#: vms-alpha.c:5800
-+#: vms-alpha.c:5801
- #, c-format
- msgid "   module version : %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:5803
-+#: vms-alpha.c:5804
- #, c-format
- msgid "   Error: The compile date is truncated\n"
- msgstr ""
- 
--#: vms-alpha.c:5805
-+#: vms-alpha.c:5806
- #, c-format
- msgid "   compile date   : %.17s\n"
- msgstr ""
- 
--#: vms-alpha.c:5810
-+#: vms-alpha.c:5811
- #, c-format
- msgid "Language Processor Name\n"
- msgstr ""
- 
--#: vms-alpha.c:5811
-+#: vms-alpha.c:5812
- #, c-format
- msgid "   language name: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:5815
-+#: vms-alpha.c:5816
- #, c-format
- msgid "Source Files Header\n"
- msgstr ""
- 
--#: vms-alpha.c:5816
-+#: vms-alpha.c:5817
- #, c-format
- msgid "   file: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:5820
-+#: vms-alpha.c:5821
- #, c-format
- msgid "Title Text Header\n"
- msgstr ""
- 
--#: vms-alpha.c:5821
-+#: vms-alpha.c:5822
- #, c-format
- msgid "   title: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:5825
-+#: vms-alpha.c:5826
- #, c-format
- msgid "Copyright Header\n"
- msgstr ""
- 
--#: vms-alpha.c:5826
-+#: vms-alpha.c:5827
- #, c-format
- msgid "   copyright: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:5830
-+#: vms-alpha.c:5831
- #, c-format
- msgid "unhandled emh subtype %u\n"
- msgstr ""
- 
--#: vms-alpha.c:5840
-+#: vms-alpha.c:5841
- #, c-format
- msgid "  EEOM (len=%u):\n"
- msgstr ""
- 
--#: vms-alpha.c:5845
-+#: vms-alpha.c:5846
- #, c-format
- msgid "   Error: The length is less than the length of an EEOM record\n"
- msgstr ""
- 
--#: vms-alpha.c:5849
-+#: vms-alpha.c:5850
- #, c-format
- msgid "   number of cond linkage pairs: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:5851
-+#: vms-alpha.c:5852
- #, c-format
- msgid "   completion code: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:5855
-+#: vms-alpha.c:5856
- #, c-format
- msgid "   transfer addr flags: 0x%02x\n"
- msgstr ""
- 
--#: vms-alpha.c:5856
-+#: vms-alpha.c:5857
- #, c-format
- msgid "   transfer addr psect: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:5858
-+#: vms-alpha.c:5859
- #, c-format
- msgid "   transfer address   : 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:5867
-+#: vms-alpha.c:5868
- msgid " WEAK"
- msgstr ""
- 
--#: vms-alpha.c:5869
-+#: vms-alpha.c:5870
- msgid " DEF"
- msgstr ""
- 
--#: vms-alpha.c:5871
-+#: vms-alpha.c:5872
- msgid " UNI"
- msgstr ""
- 
--#: vms-alpha.c:5873 vms-alpha.c:5894
-+#: vms-alpha.c:5874 vms-alpha.c:5895
- msgid " REL"
- msgstr ""
- 
--#: vms-alpha.c:5875
-+#: vms-alpha.c:5876
- msgid " COMM"
- msgstr ""
- 
--#: vms-alpha.c:5877
-+#: vms-alpha.c:5878
- msgid " VECEP"
- msgstr ""
- 
--#: vms-alpha.c:5879
-+#: vms-alpha.c:5880
- msgid " NORM"
- msgstr ""
- 
--#: vms-alpha.c:5881
-+#: vms-alpha.c:5882
- msgid " QVAL"
- msgstr ""
- 
--#: vms-alpha.c:5888
-+#: vms-alpha.c:5889
- msgid " PIC"
- msgstr ""
- 
--#: vms-alpha.c:5890
-+#: vms-alpha.c:5891
- msgid " LIB"
- msgstr ""
- 
--#: vms-alpha.c:5892
-+#: vms-alpha.c:5893
- msgid " OVR"
- msgstr ""
- 
--#: vms-alpha.c:5896
-+#: vms-alpha.c:5897
- msgid " GBL"
- msgstr ""
- 
--#: vms-alpha.c:5898
-+#: vms-alpha.c:5899
- msgid " SHR"
- msgstr ""
- 
--#: vms-alpha.c:5900
-+#: vms-alpha.c:5901
- msgid " EXE"
- msgstr ""
- 
--#: vms-alpha.c:5902
-+#: vms-alpha.c:5903
- msgid " RD"
- msgstr ""
- 
--#: vms-alpha.c:5904
-+#: vms-alpha.c:5905
- msgid " WRT"
- msgstr ""
- 
--#: vms-alpha.c:5906
-+#: vms-alpha.c:5907
- msgid " VEC"
- msgstr ""
- 
--#: vms-alpha.c:5908
-+#: vms-alpha.c:5909
- msgid " NOMOD"
- msgstr ""
- 
--#: vms-alpha.c:5910
-+#: vms-alpha.c:5911
- msgid " COM"
- msgstr ""
- 
--#: vms-alpha.c:5912
-+#: vms-alpha.c:5913
- msgid " 64B"
- msgstr ""
- 
--#: vms-alpha.c:5921
-+#: vms-alpha.c:5922
- #, c-format
- msgid "  EGSD (len=%u):\n"
- msgstr ""
- 
--#: vms-alpha.c:5934
-+#: vms-alpha.c:5935
- #, c-format
- msgid "  EGSD entry %2u (type: %u, len: %u): "
- msgstr ""
- 
--#: vms-alpha.c:5940 vms-alpha.c:6191
-+#: vms-alpha.c:5941 vms-alpha.c:6192
- #, c-format
- msgid "   Error: length larger than remaining space in record\n"
- msgstr ""
- 
--#: vms-alpha.c:5952
-+#: vms-alpha.c:5953
- #, c-format
- msgid "PSC - Program section definition\n"
- msgstr ""
- 
--#: vms-alpha.c:5953 vms-alpha.c:5970
-+#: vms-alpha.c:5954 vms-alpha.c:5971
- #, c-format
- msgid "   alignment  : 2**%u\n"
- msgstr ""
- 
--#: vms-alpha.c:5954 vms-alpha.c:5971
-+#: vms-alpha.c:5955 vms-alpha.c:5972
- #, c-format
- msgid "   flags      : 0x%04x"
- msgstr ""
- 
--#: vms-alpha.c:5958
-+#: vms-alpha.c:5959
- #, c-format
- msgid "   alloc (len): %u (0x%08x)\n"
- msgstr ""
- 
--#: vms-alpha.c:5959 vms-alpha.c:6016 vms-alpha.c:6065
-+#: vms-alpha.c:5960 vms-alpha.c:6017 vms-alpha.c:6066
- #, c-format
- msgid "   name       : %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:5969
-+#: vms-alpha.c:5970
- #, c-format
- msgid "SPSC - Shared Image Program section def\n"
- msgstr ""
- 
--#: vms-alpha.c:5975
-+#: vms-alpha.c:5976
- #, c-format
- msgid "   alloc (len)   : %u (0x%08x)\n"
- msgstr ""
- 
--#: vms-alpha.c:5976
-+#: vms-alpha.c:5977
- #, c-format
- msgid "   image offset  : 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:5978
-+#: vms-alpha.c:5979
- #, c-format
- msgid "   symvec offset : 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:5980
-+#: vms-alpha.c:5981
- #, c-format
- msgid "   name          : %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:5993
-+#: vms-alpha.c:5994
- #, c-format
- msgid "SYM - Global symbol definition\n"
- msgstr ""
- 
--#: vms-alpha.c:5994 vms-alpha.c:6054 vms-alpha.c:6075 vms-alpha.c:6094
-+#: vms-alpha.c:5995 vms-alpha.c:6055 vms-alpha.c:6076 vms-alpha.c:6095
- #, c-format
- msgid "   flags: 0x%04x"
- msgstr ""
- 
--#: vms-alpha.c:5997
-+#: vms-alpha.c:5998
- #, c-format
- msgid "   psect offset: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6001
-+#: vms-alpha.c:6002
- #, c-format
- msgid "   code address: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6003
-+#: vms-alpha.c:6004
- #, c-format
- msgid "   psect index for entry point : %u\n"
- msgstr ""
- 
--#: vms-alpha.c:6006 vms-alpha.c:6082 vms-alpha.c:6101
-+#: vms-alpha.c:6007 vms-alpha.c:6083 vms-alpha.c:6102
- #, c-format
- msgid "   psect index : %u\n"
- msgstr ""
- 
--#: vms-alpha.c:6008 vms-alpha.c:6084 vms-alpha.c:6103
-+#: vms-alpha.c:6009 vms-alpha.c:6085 vms-alpha.c:6104
- #, c-format
- msgid "   name        : %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:6015
-+#: vms-alpha.c:6016
- #, c-format
- msgid "SYM - Global symbol reference\n"
- msgstr ""
- 
--#: vms-alpha.c:6027
-+#: vms-alpha.c:6028
- #, c-format
- msgid "IDC - Ident Consistency check\n"
- msgstr ""
- 
--#: vms-alpha.c:6028
-+#: vms-alpha.c:6029
- #, c-format
- msgid "   flags         : 0x%08x"
- msgstr ""
- 
--#: vms-alpha.c:6032
-+#: vms-alpha.c:6033
- #, c-format
- msgid "   id match      : %x\n"
- msgstr ""
- 
--#: vms-alpha.c:6034
-+#: vms-alpha.c:6035
- #, c-format
- msgid "   error severity: %x\n"
- msgstr ""
- 
--#: vms-alpha.c:6037
-+#: vms-alpha.c:6038
- #, c-format
- msgid "   entity name   : %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:6039
-+#: vms-alpha.c:6040
- #, c-format
- msgid "   object name   : %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:6042
-+#: vms-alpha.c:6043
- #, c-format
- msgid "   binary ident  : 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6045
-+#: vms-alpha.c:6046
- #, c-format
- msgid "   ascii ident   : %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:6053
-+#: vms-alpha.c:6054
- #, c-format
- msgid "SYMG - Universal symbol definition\n"
- msgstr ""
- 
--#: vms-alpha.c:6057
-+#: vms-alpha.c:6058
- #, c-format
- msgid "   symbol vector offset: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6059
-+#: vms-alpha.c:6060
- #, c-format
- msgid "   entry point: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6061
-+#: vms-alpha.c:6062
- #, c-format
- msgid "   proc descr : 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6063
-+#: vms-alpha.c:6064
- #, c-format
- msgid "   psect index: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:6074
-+#: vms-alpha.c:6075
- #, c-format
- msgid "SYMV - Vectored symbol definition\n"
- msgstr ""
- 
--#: vms-alpha.c:6078
-+#: vms-alpha.c:6079
- #, c-format
- msgid "   vector      : 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6080 vms-alpha.c:6099
-+#: vms-alpha.c:6081 vms-alpha.c:6100
- #, c-format
- msgid "   psect offset: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:6093
-+#: vms-alpha.c:6094
- #, c-format
- msgid "SYMM - Global symbol definition with version\n"
- msgstr ""
- 
--#: vms-alpha.c:6097
-+#: vms-alpha.c:6098
- #, c-format
- msgid "   version mask: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6108
-+#: vms-alpha.c:6109
- #, c-format
- msgid "unhandled egsd entry type %u\n"
- msgstr ""
- 
--#: vms-alpha.c:6143
-+#: vms-alpha.c:6144
- #, c-format
- msgid "    linkage index: %u, replacement insn: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6147
-+#: vms-alpha.c:6148
- #, c-format
- msgid "    psect idx 1: %u, offset 1: 0x%08x %08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6152
-+#: vms-alpha.c:6153
- #, c-format
- msgid "    psect idx 2: %u, offset 2: 0x%08x %08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6158
-+#: vms-alpha.c:6159
- #, c-format
- msgid "    psect idx 3: %u, offset 3: 0x%08x %08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6163
-+#: vms-alpha.c:6164
- #, c-format
- msgid "    global name: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:6174
-+#: vms-alpha.c:6175
- #, c-format
- msgid "  %s (len=%u+%u):\n"
- msgstr ""
- 
--#: vms-alpha.c:6196
-+#: vms-alpha.c:6197
- #, c-format
- msgid "   (type: %3u, size: 4+%3u): "
- msgstr ""
- 
--#: vms-alpha.c:6200
-+#: vms-alpha.c:6201
- #, c-format
- msgid "STA_GBL (stack global) %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:6204
-+#: vms-alpha.c:6205
- #, c-format
- msgid "STA_LW (stack longword) 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6208
-+#: vms-alpha.c:6209
- #, c-format
- msgid "STA_QW (stack quadword) 0x%08x %08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6213
-+#: vms-alpha.c:6214
- #, c-format
- msgid "STA_PQ (stack psect base + offset)\n"
- msgstr ""
- 
--#: vms-alpha.c:6215
-+#: vms-alpha.c:6216
- #, c-format
- msgid "    psect: %u, offset: 0x%08x %08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6221
-+#: vms-alpha.c:6222
- #, c-format
- msgid "STA_LI (stack literal)\n"
- msgstr ""
- 
--#: vms-alpha.c:6224
-+#: vms-alpha.c:6225
- #, c-format
- msgid "STA_MOD (stack module)\n"
- msgstr ""
- 
--#: vms-alpha.c:6227
-+#: vms-alpha.c:6228
- #, c-format
- msgid "STA_CKARG (compare procedure argument)\n"
- msgstr ""
- 
--#: vms-alpha.c:6231
-+#: vms-alpha.c:6232
- #, c-format
- msgid "STO_B (store byte)\n"
- msgstr ""
- 
--#: vms-alpha.c:6234
-+#: vms-alpha.c:6235
- #, c-format
- msgid "STO_W (store word)\n"
- msgstr ""
- 
--#: vms-alpha.c:6237
-+#: vms-alpha.c:6238
- #, c-format
- msgid "STO_LW (store longword)\n"
- msgstr ""
- 
--#: vms-alpha.c:6240
-+#: vms-alpha.c:6241
- #, c-format
- msgid "STO_QW (store quadword)\n"
- msgstr ""
- 
--#: vms-alpha.c:6246
-+#: vms-alpha.c:6247
- #, c-format
- msgid "STO_IMMR (store immediate repeat) %u bytes\n"
- msgstr ""
- 
--#: vms-alpha.c:6253
-+#: vms-alpha.c:6254
- #, c-format
- msgid "STO_GBL (store global) %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:6257
-+#: vms-alpha.c:6258
- #, c-format
- msgid "STO_CA (store code address) %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:6261
-+#: vms-alpha.c:6262
- #, c-format
- msgid "STO_RB (store relative branch)\n"
- msgstr ""
- 
--#: vms-alpha.c:6264
-+#: vms-alpha.c:6265
- #, c-format
- msgid "STO_AB (store absolute branch)\n"
- msgstr ""
- 
--#: vms-alpha.c:6267
-+#: vms-alpha.c:6268
- #, c-format
- msgid "STO_OFF (store offset to psect)\n"
- msgstr ""
- 
--#: vms-alpha.c:6273
-+#: vms-alpha.c:6274
- #, c-format
- msgid "STO_IMM (store immediate) %u bytes\n"
- msgstr ""
- 
--#: vms-alpha.c:6280
-+#: vms-alpha.c:6281
- #, c-format
- msgid "STO_GBL_LW (store global longword) %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:6284
-+#: vms-alpha.c:6285
- #, c-format
- msgid "STO_OFF (store LP with procedure signature)\n"
- msgstr ""
- 
--#: vms-alpha.c:6287
-+#: vms-alpha.c:6288
- #, c-format
- msgid "STO_BR_GBL (store branch global) *todo*\n"
- msgstr ""
- 
--#: vms-alpha.c:6290
-+#: vms-alpha.c:6291
- #, c-format
- msgid "STO_BR_PS (store branch psect + offset) *todo*\n"
- msgstr ""
- 
--#: vms-alpha.c:6294
-+#: vms-alpha.c:6295
- #, c-format
- msgid "OPR_NOP (no-operation)\n"
- msgstr ""
- 
--#: vms-alpha.c:6297
-+#: vms-alpha.c:6298
- #, c-format
- msgid "OPR_ADD (add)\n"
- msgstr ""
- 
--#: vms-alpha.c:6300
-+#: vms-alpha.c:6301
- #, c-format
- msgid "OPR_SUB (subtract)\n"
- msgstr ""
- 
--#: vms-alpha.c:6303
-+#: vms-alpha.c:6304
- #, c-format
- msgid "OPR_MUL (multiply)\n"
- msgstr ""
- 
--#: vms-alpha.c:6306
-+#: vms-alpha.c:6307
- #, c-format
- msgid "OPR_DIV (divide)\n"
- msgstr ""
- 
--#: vms-alpha.c:6309
-+#: vms-alpha.c:6310
- #, c-format
- msgid "OPR_AND (logical and)\n"
- msgstr ""
- 
--#: vms-alpha.c:6312
-+#: vms-alpha.c:6313
- #, c-format
- msgid "OPR_IOR (logical inclusive or)\n"
- msgstr ""
- 
--#: vms-alpha.c:6315
-+#: vms-alpha.c:6316
- #, c-format
- msgid "OPR_EOR (logical exclusive or)\n"
- msgstr ""
- 
--#: vms-alpha.c:6318
-+#: vms-alpha.c:6319
- #, c-format
- msgid "OPR_NEG (negate)\n"
- msgstr ""
- 
--#: vms-alpha.c:6321
-+#: vms-alpha.c:6322
- #, c-format
- msgid "OPR_COM (complement)\n"
- msgstr ""
- 
--#: vms-alpha.c:6324
-+#: vms-alpha.c:6325
- #, c-format
- msgid "OPR_INSV (insert field)\n"
- msgstr ""
- 
--#: vms-alpha.c:6327
-+#: vms-alpha.c:6328
- #, c-format
- msgid "OPR_ASH (arithmetic shift)\n"
- msgstr ""
- 
--#: vms-alpha.c:6330
-+#: vms-alpha.c:6331
- #, c-format
- msgid "OPR_USH (unsigned shift)\n"
- msgstr ""
- 
--#: vms-alpha.c:6333
-+#: vms-alpha.c:6334
- #, c-format
- msgid "OPR_ROT (rotate)\n"
- msgstr ""
- 
--#: vms-alpha.c:6336
-+#: vms-alpha.c:6337
- #, c-format
- msgid "OPR_SEL (select)\n"
- msgstr ""
- 
--#: vms-alpha.c:6339
-+#: vms-alpha.c:6340
- #, c-format
- msgid "OPR_REDEF (redefine symbol to curr location)\n"
- msgstr ""
- 
--#: vms-alpha.c:6342
-+#: vms-alpha.c:6343
- #, c-format
- msgid "OPR_REDEF (define a literal)\n"
- msgstr ""
- 
--#: vms-alpha.c:6346
-+#: vms-alpha.c:6347
- #, c-format
- msgid "STC_LP (store cond linkage pair)\n"
- msgstr ""
- 
--#: vms-alpha.c:6350
-+#: vms-alpha.c:6351
- #, c-format
- msgid "STC_LP_PSB (store cond linkage pair + signature)\n"
- msgstr ""
- 
--#: vms-alpha.c:6352
-+#: vms-alpha.c:6353
- #, c-format
- msgid "   linkage index: %u, procedure: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:6355
-+#: vms-alpha.c:6356
- #, c-format
- msgid "   signature: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:6358
-+#: vms-alpha.c:6359
- #, c-format
- msgid "STC_GBL (store cond global)\n"
- msgstr ""
- 
--#: vms-alpha.c:6360
-+#: vms-alpha.c:6361
- #, c-format
- msgid "   linkage index: %u, global: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:6364
-+#: vms-alpha.c:6365
- #, c-format
- msgid "STC_GCA (store cond code address)\n"
- msgstr ""
- 
--#: vms-alpha.c:6366
-+#: vms-alpha.c:6367
- #, c-format
- msgid "   linkage index: %u, procedure name: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:6370
-+#: vms-alpha.c:6371
- #, c-format
- msgid "STC_PS (store cond psect + offset)\n"
- msgstr ""
- 
--#: vms-alpha.c:6373
-+#: vms-alpha.c:6374
- #, c-format
- msgid "   linkage index: %u, psect: %u, offset: 0x%08x %08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6380
-+#: vms-alpha.c:6381
- #, c-format
- msgid "STC_NOP_GBL (store cond NOP at global addr)\n"
- msgstr ""
- 
--#: vms-alpha.c:6384
-+#: vms-alpha.c:6385
- #, c-format
- msgid "STC_NOP_PS (store cond NOP at psect + offset)\n"
- msgstr ""
- 
--#: vms-alpha.c:6388
-+#: vms-alpha.c:6389
- #, c-format
- msgid "STC_BSR_GBL (store cond BSR at global addr)\n"
- msgstr ""
- 
--#: vms-alpha.c:6392
-+#: vms-alpha.c:6393
- #, c-format
- msgid "STC_BSR_PS (store cond BSR at psect + offset)\n"
- msgstr ""
- 
--#: vms-alpha.c:6396
-+#: vms-alpha.c:6397
- #, c-format
- msgid "STC_LDA_GBL (store cond LDA at global addr)\n"
- msgstr ""
- 
--#: vms-alpha.c:6400
-+#: vms-alpha.c:6401
- #, c-format
- msgid "STC_LDA_PS (store cond LDA at psect + offset)\n"
- msgstr ""
- 
--#: vms-alpha.c:6404
-+#: vms-alpha.c:6405
- #, c-format
- msgid "STC_BOH_GBL (store cond BOH at global addr)\n"
- msgstr ""
- 
--#: vms-alpha.c:6408
-+#: vms-alpha.c:6409
- #, c-format
- msgid "STC_BOH_PS (store cond BOH at psect + offset)\n"
- msgstr ""
- 
--#: vms-alpha.c:6413
-+#: vms-alpha.c:6414
- #, c-format
- msgid "STC_NBH_GBL (store cond or hint at global addr)\n"
- msgstr ""
- 
--#: vms-alpha.c:6417
-+#: vms-alpha.c:6418
- #, c-format
- msgid "STC_NBH_PS (store cond or hint at psect + offset)\n"
- msgstr ""
- 
--#: vms-alpha.c:6421
-+#: vms-alpha.c:6422
- #, c-format
- msgid "CTL_SETRB (set relocation base)\n"
- msgstr ""
- 
--#: vms-alpha.c:6427
-+#: vms-alpha.c:6428
- #, c-format
- msgid "CTL_AUGRB (augment relocation base) %u\n"
- msgstr ""
- 
--#: vms-alpha.c:6431
-+#: vms-alpha.c:6432
- #, c-format
- msgid "CTL_DFLOC (define location)\n"
- msgstr ""
- 
--#: vms-alpha.c:6434
-+#: vms-alpha.c:6435
- #, c-format
- msgid "CTL_STLOC (set location)\n"
- msgstr ""
- 
--#: vms-alpha.c:6437
-+#: vms-alpha.c:6438
- #, c-format
- msgid "CTL_STKDL (stack defined location)\n"
- msgstr ""
- 
--#: vms-alpha.c:6440 vms-alpha.c:6864 vms-alpha.c:6990
-+#: vms-alpha.c:6441 vms-alpha.c:6865 vms-alpha.c:6991
- #, c-format
- msgid "*unhandled*\n"
- msgstr ""
- 
--#: vms-alpha.c:6470 vms-alpha.c:6509
-+#: vms-alpha.c:6471 vms-alpha.c:6510
- #, c-format
- msgid "cannot read GST record length\n"
- msgstr ""
- 
- #. Ill-formed.
--#: vms-alpha.c:6491
-+#: vms-alpha.c:6492
- #, c-format
- msgid "cannot find EMH in first GST record\n"
- msgstr ""
- 
--#: vms-alpha.c:6517
-+#: vms-alpha.c:6518
- #, c-format
- msgid "cannot read GST record header\n"
- msgstr ""
- 
--#: vms-alpha.c:6530
-+#: vms-alpha.c:6531
- #, c-format
- msgid " corrupted GST\n"
- msgstr ""
- 
--#: vms-alpha.c:6538
-+#: vms-alpha.c:6539
- #, c-format
- msgid "cannot read GST record\n"
- msgstr ""
- 
--#: vms-alpha.c:6567
-+#: vms-alpha.c:6568
- #, c-format
- msgid " unhandled EOBJ record type %u\n"
- msgstr ""
- 
--#: vms-alpha.c:6591
-+#: vms-alpha.c:6592
- #, c-format
- msgid "  bitcount: %u, base addr: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6605
-+#: vms-alpha.c:6606
- #, c-format
- msgid "   bitmap: 0x%08x (count: %u):\n"
- msgstr ""
- 
--#: vms-alpha.c:6612
-+#: vms-alpha.c:6613
- #, c-format
- msgid " %08x"
- msgstr ""
- 
--#: vms-alpha.c:6638
-+#: vms-alpha.c:6639
- #, c-format
- msgid "  image %u (%u entries)\n"
- msgstr ""
- 
--#: vms-alpha.c:6644
-+#: vms-alpha.c:6645
- #, c-format
- msgid "   offset: 0x%08x, val: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6666
-+#: vms-alpha.c:6667
- #, c-format
- msgid "  image %u (%u entries), offsets:\n"
- msgstr ""
- 
--#: vms-alpha.c:6673
-+#: vms-alpha.c:6674
- #, c-format
- msgid " 0x%08x"
- msgstr ""
- 
- #. 64 bits.
--#: vms-alpha.c:6795
-+#: vms-alpha.c:6796
- #, c-format
- msgid "64 bits *unhandled*\n"
- msgstr ""
- 
--#: vms-alpha.c:6800
-+#: vms-alpha.c:6801
- #, c-format
- msgid "class: %u, dtype: %u, length: %u, pointer: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6811
-+#: vms-alpha.c:6812
- #, c-format
- msgid "non-contiguous array of %s\n"
- msgstr ""
- 
--#: vms-alpha.c:6816
-+#: vms-alpha.c:6817
- #, c-format
- msgid "dimct: %u, aflags: 0x%02x, digits: %u, scale: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:6821
-+#: vms-alpha.c:6822
- #, c-format
- msgid "arsize: %u, a0: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6825
-+#: vms-alpha.c:6826
- #, c-format
- msgid "Strides:\n"
- msgstr ""
- 
--#: vms-alpha.c:6835
-+#: vms-alpha.c:6836
- #, c-format
- msgid "Bounds:\n"
- msgstr ""
- 
--#: vms-alpha.c:6841
-+#: vms-alpha.c:6842
- #, c-format
- msgid "[%u]: Lower: %u, upper: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:6853
-+#: vms-alpha.c:6854
- #, c-format
- msgid "unaligned bit-string of %s\n"
- msgstr ""
- 
--#: vms-alpha.c:6858
-+#: vms-alpha.c:6859
- #, c-format
- msgid "base: %u, pos: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:6879
-+#: vms-alpha.c:6880
- #, c-format
- msgid "vflags: 0x%02x, value: 0x%08x "
- msgstr ""
- 
--#: vms-alpha.c:6885
-+#: vms-alpha.c:6886
- #, c-format
- msgid "(no value)\n"
- msgstr ""
- 
--#: vms-alpha.c:6888
-+#: vms-alpha.c:6889
- #, c-format
- msgid "(not active)\n"
- msgstr ""
- 
--#: vms-alpha.c:6891
-+#: vms-alpha.c:6892
- #, c-format
- msgid "(not allocated)\n"
- msgstr ""
- 
--#: vms-alpha.c:6894
-+#: vms-alpha.c:6895
- #, c-format
- msgid "(descriptor)\n"
- msgstr ""
- 
--#: vms-alpha.c:6898
-+#: vms-alpha.c:6899
- #, c-format
- msgid "(trailing value)\n"
- msgstr ""
- 
--#: vms-alpha.c:6901
-+#: vms-alpha.c:6902
- #, c-format
- msgid "(value spec follows)\n"
- msgstr ""
- 
--#: vms-alpha.c:6904
-+#: vms-alpha.c:6905
- #, c-format
- msgid "(at bit offset %u)\n"
- msgstr ""
- 
--#: vms-alpha.c:6908
-+#: vms-alpha.c:6909
- #, c-format
- msgid "(reg: %u, disp: %u, indir: %u, kind: "
- msgstr ""
- 
--#: vms-alpha.c:6915
-+#: vms-alpha.c:6916
- msgid "literal"
- msgstr ""
- 
--#: vms-alpha.c:6918
-+#: vms-alpha.c:6919
- msgid "address"
- msgstr ""
- 
--#: vms-alpha.c:6921
-+#: vms-alpha.c:6922
- msgid "desc"
- msgstr ""
- 
--#: vms-alpha.c:6924
-+#: vms-alpha.c:6925
- msgid "reg"
- msgstr ""
- 
--#: vms-alpha.c:6941
-+#: vms-alpha.c:6942
- #, c-format
- msgid "len: %2u, kind: %2u "
- msgstr ""
- 
--#: vms-alpha.c:6947
-+#: vms-alpha.c:6948
- #, c-format
- msgid "atomic, type=0x%02x %s\n"
- msgstr ""
- 
--#: vms-alpha.c:6951
-+#: vms-alpha.c:6952
- #, c-format
- msgid "indirect, defined at 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:6955
-+#: vms-alpha.c:6956
- #, c-format
- msgid "typed pointer\n"
- msgstr ""
- 
--#: vms-alpha.c:6959
-+#: vms-alpha.c:6960
- #, c-format
- msgid "pointer\n"
- msgstr ""
- 
--#: vms-alpha.c:6967
-+#: vms-alpha.c:6968
- #, c-format
- msgid "array, dim: %u, bitmap: "
- msgstr ""
- 
--#: vms-alpha.c:6974
-+#: vms-alpha.c:6975
- #, c-format
- msgid "array descriptor:\n"
- msgstr ""
- 
--#: vms-alpha.c:6981
-+#: vms-alpha.c:6982
- #, c-format
- msgid "type spec for element:\n"
- msgstr ""
- 
--#: vms-alpha.c:6983
-+#: vms-alpha.c:6984
- #, c-format
- msgid "type spec for subscript %u:\n"
- msgstr ""
- 
--#: vms-alpha.c:7001
-+#: vms-alpha.c:7002
- #, c-format
- msgid "Debug symbol table:\n"
- msgstr ""
- 
--#: vms-alpha.c:7012
-+#: vms-alpha.c:7013
- #, c-format
- msgid "cannot read DST header\n"
- msgstr ""
- 
--#: vms-alpha.c:7018
-+#: vms-alpha.c:7019
- #, c-format
- msgid " type: %3u, len: %3u (at 0x%08x): "
- msgstr ""
- 
--#: vms-alpha.c:7032
-+#: vms-alpha.c:7033
- #, c-format
- msgid "cannot read DST symbol\n"
- msgstr ""
- 
--#: vms-alpha.c:7075
-+#: vms-alpha.c:7076
- #, c-format
- msgid "standard data: %s\n"
- msgstr ""
- 
--#: vms-alpha.c:7078 vms-alpha.c:7166
-+#: vms-alpha.c:7079 vms-alpha.c:7167
- #, c-format
- msgid "    name: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7085
-+#: vms-alpha.c:7086
- #, c-format
- msgid "modbeg\n"
- msgstr ""
- 
--#: vms-alpha.c:7087
-+#: vms-alpha.c:7088
- #, c-format
- msgid "   flags: %d, language: %u, major: %u, minor: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7093 vms-alpha.c:7367
-+#: vms-alpha.c:7094 vms-alpha.c:7368
- #, c-format
- msgid "   module name: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7096
-+#: vms-alpha.c:7097
- #, c-format
- msgid "   compiler   : %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7101
-+#: vms-alpha.c:7102
- #, c-format
- msgid "modend\n"
- msgstr ""
- 
--#: vms-alpha.c:7108
-+#: vms-alpha.c:7109
- msgid "rtnbeg\n"
- msgstr ""
- 
--#: vms-alpha.c:7110
-+#: vms-alpha.c:7111
- #, c-format
- msgid "    flags: %u, address: 0x%08x, pd-address: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7115
-+#: vms-alpha.c:7116
- #, c-format
- msgid "    routine name: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7123
-+#: vms-alpha.c:7124
- #, c-format
- msgid "rtnend: size 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7131
-+#: vms-alpha.c:7132
- #, c-format
- msgid "prolog: bkpt address 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7140
-+#: vms-alpha.c:7141
- #, c-format
- msgid "epilog: flags: %u, count: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7150
-+#: vms-alpha.c:7151
- #, c-format
- msgid "blkbeg: address: 0x%08x, name: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7159
-+#: vms-alpha.c:7160
- #, c-format
- msgid "blkend: size: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7165
-+#: vms-alpha.c:7166
- #, c-format
- msgid "typspec (len: %u)\n"
- msgstr ""
- 
--#: vms-alpha.c:7172
-+#: vms-alpha.c:7173
- #, c-format
- msgid "septyp, name: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7181
-+#: vms-alpha.c:7182
- #, c-format
- msgid "recbeg: name: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7183
-+#: vms-alpha.c:7184
- #, c-format
- msgid "    len: %u bits\n"
- msgstr ""
- 
--#: vms-alpha.c:7188
-+#: vms-alpha.c:7189
- #, c-format
- msgid "recend\n"
- msgstr ""
- 
--#: vms-alpha.c:7192
-+#: vms-alpha.c:7193
- #, c-format
- msgid "enumbeg, len: %u, name: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7196
-+#: vms-alpha.c:7197
- #, c-format
- msgid "enumelt, name: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7200
-+#: vms-alpha.c:7201
- #, c-format
- msgid "enumend\n"
- msgstr ""
- 
--#: vms-alpha.c:7205
-+#: vms-alpha.c:7206
- #, c-format
- msgid "label, name: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7207
-+#: vms-alpha.c:7208
- #, c-format
- msgid "    address: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7217
-+#: vms-alpha.c:7218
- #, c-format
- msgid "discontiguous range (nbr: %u)\n"
- msgstr ""
- 
--#: vms-alpha.c:7220
-+#: vms-alpha.c:7221
- #, c-format
- msgid "    address: 0x%08x, size: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7230
-+#: vms-alpha.c:7231
- #, c-format
- msgid "line num  (len: %u)\n"
- msgstr ""
- 
--#: vms-alpha.c:7247
-+#: vms-alpha.c:7248
- #, c-format
- msgid "delta_pc_w %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7254
-+#: vms-alpha.c:7255
- #, c-format
- msgid "incr_linum(b): +%u\n"
- msgstr ""
- 
--#: vms-alpha.c:7260
-+#: vms-alpha.c:7261
- #, c-format
- msgid "incr_linum_w: +%u\n"
- msgstr ""
- 
--#: vms-alpha.c:7266
-+#: vms-alpha.c:7267
- #, c-format
- msgid "incr_linum_l: +%u\n"
- msgstr ""
- 
--#: vms-alpha.c:7272
-+#: vms-alpha.c:7273
- #, c-format
- msgid "set_line_num(w) %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7277
-+#: vms-alpha.c:7278
- #, c-format
- msgid "set_line_num_b %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7282
-+#: vms-alpha.c:7283
- #, c-format
- msgid "set_line_num_l %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7287
-+#: vms-alpha.c:7288
- #, c-format
- msgid "set_abs_pc: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7291
-+#: vms-alpha.c:7292
- #, c-format
- msgid "delta_pc_l: +0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7296
-+#: vms-alpha.c:7297
- #, c-format
- msgid "term(b): 0x%02x"
- msgstr ""
- 
--#: vms-alpha.c:7298
-+#: vms-alpha.c:7299
- #, c-format
- msgid "        pc: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7303
-+#: vms-alpha.c:7304
- #, c-format
- msgid "term_w: 0x%04x"
- msgstr ""
- 
--#: vms-alpha.c:7305
-+#: vms-alpha.c:7306
- #, c-format
- msgid "    pc: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7311
-+#: vms-alpha.c:7312
- #, c-format
- msgid "delta pc +%-4d"
- msgstr ""
- 
--#: vms-alpha.c:7315
-+#: vms-alpha.c:7316
- #, c-format
- msgid "    pc: 0x%08x line: %5u\n"
- msgstr ""
- 
--#: vms-alpha.c:7320
-+#: vms-alpha.c:7321
- #, c-format
- msgid "    *unhandled* cmd %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7335
-+#: vms-alpha.c:7336
- #, c-format
- msgid "source (len: %u)\n"
- msgstr ""
- 
--#: vms-alpha.c:7350
-+#: vms-alpha.c:7351
- #, c-format
- msgid "   declfile: len: %u, flags: %u, fileid: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7355
-+#: vms-alpha.c:7356
- #, c-format
- msgid "   rms: cdt: 0x%08x %08x, ebk: 0x%08x, ffb: 0x%04x, rfo: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7364
-+#: vms-alpha.c:7365
- #, c-format
- msgid "   filename   : %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7373
-+#: vms-alpha.c:7374
- #, c-format
- msgid "   setfile %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7378 vms-alpha.c:7383
-+#: vms-alpha.c:7379 vms-alpha.c:7384
- #, c-format
- msgid "   setrec %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7388 vms-alpha.c:7393
-+#: vms-alpha.c:7389 vms-alpha.c:7394
- #, c-format
- msgid "   setlnum %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7398 vms-alpha.c:7403
-+#: vms-alpha.c:7399 vms-alpha.c:7404
- #, c-format
- msgid "   deflines %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7407
-+#: vms-alpha.c:7408
- #, c-format
- msgid "   formfeed\n"
- msgstr ""
- 
--#: vms-alpha.c:7411
-+#: vms-alpha.c:7412
- #, c-format
- msgid "   *unhandled* cmd %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7423
-+#: vms-alpha.c:7424
- #, c-format
- msgid "*unhandled* dst type %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7455
-+#: vms-alpha.c:7456
- #, c-format
- msgid "cannot read EIHD\n"
- msgstr ""
- 
--#: vms-alpha.c:7459
-+#: vms-alpha.c:7460
- #, c-format
- msgid "EIHD: (size: %u, nbr blocks: %u)\n"
- msgstr ""
- 
--#: vms-alpha.c:7463
-+#: vms-alpha.c:7464
- #, c-format
- msgid " majorid: %u, minorid: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7471
-+#: vms-alpha.c:7472
- msgid "executable"
- msgstr ""
- 
--#: vms-alpha.c:7474
-+#: vms-alpha.c:7475
- msgid "linkable image"
- msgstr ""
- 
--#: vms-alpha.c:7481
-+#: vms-alpha.c:7482
- #, c-format
- msgid " image type: %u (%s)"
- msgstr ""
- 
--#: vms-alpha.c:7487
-+#: vms-alpha.c:7488
- msgid "native"
- msgstr ""
- 
--#: vms-alpha.c:7490
-+#: vms-alpha.c:7491
- msgid "CLI"
- msgstr ""
- 
--#: vms-alpha.c:7497
-+#: vms-alpha.c:7498
- #, c-format
- msgid ", subtype: %u (%s)\n"
- msgstr ""
- 
--#: vms-alpha.c:7504
-+#: vms-alpha.c:7505
- #, c-format
- msgid " offsets: isd: %u, activ: %u, symdbg: %u, imgid: %u, patch: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7508
-+#: vms-alpha.c:7509
- #, c-format
- msgid " fixup info rva: "
- msgstr ""
- 
--#: vms-alpha.c:7510
-+#: vms-alpha.c:7511
- #, c-format
- msgid ", symbol vector rva: "
- msgstr ""
- 
--#: vms-alpha.c:7513
-+#: vms-alpha.c:7514
- #, c-format
- msgid ""
- "\n"
- " version array off: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7518
-+#: vms-alpha.c:7519
- #, c-format
- msgid " img I/O count: %u, nbr channels: %u, req pri: %08x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7524
-+#: vms-alpha.c:7525
- #, c-format
- msgid " linker flags: %08x:"
- msgstr ""
- 
--#: vms-alpha.c:7555
-+#: vms-alpha.c:7556
- #, c-format
- msgid " ident: 0x%08x, sysver: 0x%08x, match ctrl: %u, symvect_size: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7561
-+#: vms-alpha.c:7562
- #, c-format
- msgid " BPAGE: %u"
- msgstr ""
- 
--#: vms-alpha.c:7568
-+#: vms-alpha.c:7569
- #, c-format
- msgid ", ext fixup offset: %u, no_opt psect off: %u"
- msgstr ""
- 
--#: vms-alpha.c:7571
-+#: vms-alpha.c:7572
- #, c-format
- msgid ", alias: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7579
-+#: vms-alpha.c:7580
- #, c-format
- msgid "system version array information:\n"
- msgstr ""
- 
--#: vms-alpha.c:7583
-+#: vms-alpha.c:7584
- #, c-format
- msgid "cannot read EIHVN header\n"
- msgstr ""
- 
--#: vms-alpha.c:7593
-+#: vms-alpha.c:7594
- #, c-format
- msgid "cannot read EIHVN version\n"
- msgstr ""
- 
--#: vms-alpha.c:7596
-+#: vms-alpha.c:7597
- #, c-format
- msgid "   %02u "
- msgstr ""
- 
--#: vms-alpha.c:7600
-+#: vms-alpha.c:7601
- msgid "BASE_IMAGE       "
- msgstr ""
- 
--#: vms-alpha.c:7603
-+#: vms-alpha.c:7604
- msgid "MEMORY_MANAGEMENT"
- msgstr ""
- 
--#: vms-alpha.c:7606
-+#: vms-alpha.c:7607
- msgid "IO               "
- msgstr ""
- 
--#: vms-alpha.c:7609
-+#: vms-alpha.c:7610
- msgid "FILES_VOLUMES    "
- msgstr ""
- 
--#: vms-alpha.c:7612
-+#: vms-alpha.c:7613
- msgid "PROCESS_SCHED    "
- msgstr ""
- 
--#: vms-alpha.c:7615
-+#: vms-alpha.c:7616
- msgid "SYSGEN           "
- msgstr ""
- 
--#: vms-alpha.c:7618
-+#: vms-alpha.c:7619
- msgid "CLUSTERS_LOCKMGR "
- msgstr ""
- 
--#: vms-alpha.c:7621
-+#: vms-alpha.c:7622
- msgid "LOGICAL_NAMES    "
- msgstr ""
- 
--#: vms-alpha.c:7624
-+#: vms-alpha.c:7625
- msgid "SECURITY         "
- msgstr ""
- 
--#: vms-alpha.c:7627
-+#: vms-alpha.c:7628
- msgid "IMAGE_ACTIVATOR  "
- msgstr ""
- 
--#: vms-alpha.c:7630
-+#: vms-alpha.c:7631
- msgid "NETWORKS         "
- msgstr ""
- 
--#: vms-alpha.c:7633
-+#: vms-alpha.c:7634
- msgid "COUNTERS         "
- msgstr ""
- 
--#: vms-alpha.c:7636
-+#: vms-alpha.c:7637
- msgid "STABLE           "
- msgstr ""
- 
--#: vms-alpha.c:7639
-+#: vms-alpha.c:7640
- msgid "MISC             "
- msgstr ""
- 
--#: vms-alpha.c:7642
-+#: vms-alpha.c:7643
- msgid "CPU              "
- msgstr ""
- 
--#: vms-alpha.c:7645
-+#: vms-alpha.c:7646
- msgid "VOLATILE         "
- msgstr ""
- 
--#: vms-alpha.c:7648
-+#: vms-alpha.c:7649
- msgid "SHELL            "
- msgstr ""
- 
--#: vms-alpha.c:7651
-+#: vms-alpha.c:7652
- msgid "POSIX            "
- msgstr ""
- 
--#: vms-alpha.c:7654
-+#: vms-alpha.c:7655
- msgid "MULTI_PROCESSING "
- msgstr ""
- 
--#: vms-alpha.c:7657
-+#: vms-alpha.c:7658
- msgid "GALAXY           "
- msgstr ""
- 
--#: vms-alpha.c:7660
-+#: vms-alpha.c:7661
- msgid "*unknown*        "
- msgstr ""
- 
--#: vms-alpha.c:7676 vms-alpha.c:7951
-+#: vms-alpha.c:7677 vms-alpha.c:7952
- #, c-format
- msgid "cannot read EIHA\n"
- msgstr ""
- 
--#: vms-alpha.c:7679
-+#: vms-alpha.c:7680
- #, c-format
- msgid "Image activation:  (size=%u)\n"
- msgstr ""
- 
--#: vms-alpha.c:7682
-+#: vms-alpha.c:7683
- #, c-format
- msgid " First address : 0x%08x 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7686
-+#: vms-alpha.c:7687
- #, c-format
- msgid " Second address: 0x%08x 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7690
-+#: vms-alpha.c:7691
- #, c-format
- msgid " Third address : 0x%08x 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7694
-+#: vms-alpha.c:7695
- #, c-format
- msgid " Fourth address: 0x%08x 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7698
-+#: vms-alpha.c:7699
- #, c-format
- msgid " Shared image  : 0x%08x 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7709
-+#: vms-alpha.c:7710
- #, c-format
- msgid "cannot read EIHI\n"
- msgstr ""
- 
--#: vms-alpha.c:7713
-+#: vms-alpha.c:7714
- #, c-format
- msgid "Image identification: (major: %u, minor: %u)\n"
- msgstr ""
- 
--#: vms-alpha.c:7716
-+#: vms-alpha.c:7717
- #, c-format
- msgid " image name       : %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7718
-+#: vms-alpha.c:7719
- #, c-format
- msgid " link time        : %s\n"
- msgstr ""
- 
--#: vms-alpha.c:7720
-+#: vms-alpha.c:7721
- #, c-format
- msgid " image ident      : %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7722
-+#: vms-alpha.c:7723
- #, c-format
- msgid " linker ident     : %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7724
-+#: vms-alpha.c:7725
- #, c-format
- msgid " image build ident: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7734
-+#: vms-alpha.c:7735
- #, c-format
- msgid "cannot read EIHS\n"
- msgstr ""
- 
--#: vms-alpha.c:7738
-+#: vms-alpha.c:7739
- #, c-format
- msgid "Image symbol & debug table: (major: %u, minor: %u)\n"
- msgstr ""
- 
--#: vms-alpha.c:7744
-+#: vms-alpha.c:7745
- #, c-format
- msgid " debug symbol table : vbn: %u, size: %u (0x%x)\n"
- msgstr ""
- 
--#: vms-alpha.c:7749
-+#: vms-alpha.c:7750
- #, c-format
- msgid " global symbol table: vbn: %u, records: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7754
-+#: vms-alpha.c:7755
- #, c-format
- msgid " debug module table : vbn: %u, size: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7767
-+#: vms-alpha.c:7768
- #, c-format
- msgid "cannot read EISD\n"
- msgstr ""
- 
--#: vms-alpha.c:7778
-+#: vms-alpha.c:7779
- #, c-format
- msgid ""
- "Image section descriptor: (major: %u, minor: %u, size: %u, offset: %u)\n"
- msgstr ""
- 
--#: vms-alpha.c:7786
-+#: vms-alpha.c:7787
- #, c-format
- msgid " section: base: 0x%08x%08x size: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7791
-+#: vms-alpha.c:7792
- #, c-format
- msgid " flags: 0x%04x"
- msgstr ""
- 
--#: vms-alpha.c:7829
-+#: vms-alpha.c:7830
- #, c-format
- msgid " vbn: %u, pfc: %u, matchctl: %u type: %u ("
- msgstr ""
- 
--#: vms-alpha.c:7835
-+#: vms-alpha.c:7836
- msgid "NORMAL"
- msgstr ""
- 
--#: vms-alpha.c:7838
-+#: vms-alpha.c:7839
- msgid "SHRFXD"
- msgstr ""
- 
--#: vms-alpha.c:7841
-+#: vms-alpha.c:7842
- msgid "PRVFXD"
- msgstr ""
- 
--#: vms-alpha.c:7844
-+#: vms-alpha.c:7845
- msgid "SHRPIC"
- msgstr ""
- 
--#: vms-alpha.c:7847
-+#: vms-alpha.c:7848
- msgid "PRVPIC"
- msgstr ""
- 
--#: vms-alpha.c:7850
-+#: vms-alpha.c:7851
- msgid "USRSTACK"
- msgstr ""
- 
--#: vms-alpha.c:7856
-+#: vms-alpha.c:7857
- msgid ")\n"
- msgstr ""
- 
--#: vms-alpha.c:7859
-+#: vms-alpha.c:7860
- #, c-format
- msgid " ident: 0x%08x, name: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:7869
-+#: vms-alpha.c:7870
- #, c-format
- msgid "cannot read DMT\n"
- msgstr ""
- 
--#: vms-alpha.c:7873
-+#: vms-alpha.c:7874
- #, c-format
- msgid "Debug module table:\n"
- msgstr ""
- 
--#: vms-alpha.c:7882
-+#: vms-alpha.c:7883
- #, c-format
- msgid "cannot read DMT header\n"
- msgstr ""
- 
--#: vms-alpha.c:7888
-+#: vms-alpha.c:7889
- #, c-format
- msgid " module offset: 0x%08x, size: 0x%08x, (%u psects)\n"
- msgstr ""
- 
--#: vms-alpha.c:7898
-+#: vms-alpha.c:7899
- #, c-format
- msgid "cannot read DMT psect\n"
- msgstr ""
- 
--#: vms-alpha.c:7902
-+#: vms-alpha.c:7903
- #, c-format
- msgid "  psect start: 0x%08x, length: %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7915
-+#: vms-alpha.c:7916
- #, c-format
- msgid "cannot read DST\n"
- msgstr ""
- 
--#: vms-alpha.c:7925
-+#: vms-alpha.c:7926
- #, c-format
- msgid "cannot read GST\n"
- msgstr ""
- 
--#: vms-alpha.c:7929
-+#: vms-alpha.c:7930
- #, c-format
- msgid "Global symbol table:\n"
- msgstr ""
- 
--#: vms-alpha.c:7958
-+#: vms-alpha.c:7959
- #, c-format
- msgid "Image activator fixup: (major: %u, minor: %u)\n"
- msgstr ""
- 
--#: vms-alpha.c:7962
-+#: vms-alpha.c:7963
- #, c-format
- msgid "  iaflink : 0x%08x %08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7966
-+#: vms-alpha.c:7967
- #, c-format
- msgid "  fixuplnk: 0x%08x %08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7969
-+#: vms-alpha.c:7970
- #, c-format
- msgid "  size : %u\n"
- msgstr ""
- 
--#: vms-alpha.c:7971
-+#: vms-alpha.c:7972
- #, c-format
- msgid "  flags: 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:7976
-+#: vms-alpha.c:7977
- #, c-format
- msgid "  qrelfixoff: %5u, lrelfixoff: %5u\n"
- msgstr ""
- 
--#: vms-alpha.c:7981
-+#: vms-alpha.c:7982
- #, c-format
- msgid "  qdotadroff: %5u, ldotadroff: %5u\n"
- msgstr ""
- 
--#: vms-alpha.c:7986
-+#: vms-alpha.c:7987
- #, c-format
- msgid "  codeadroff: %5u, lpfixoff  : %5u\n"
- msgstr ""
- 
--#: vms-alpha.c:7989
-+#: vms-alpha.c:7990
- #, c-format
- msgid "  chgprtoff : %5u\n"
- msgstr ""
- 
--#: vms-alpha.c:7993
-+#: vms-alpha.c:7994
- #, c-format
- msgid "  shlstoff  : %5u, shrimgcnt : %5u\n"
- msgstr ""
- 
--#: vms-alpha.c:7996
-+#: vms-alpha.c:7997
- #, c-format
- msgid "  shlextra  : %5u, permctx   : %5u\n"
- msgstr ""
- 
--#: vms-alpha.c:7999
-+#: vms-alpha.c:8000
- #, c-format
- msgid "  base_va : 0x%08x\n"
- msgstr ""
- 
--#: vms-alpha.c:8001
-+#: vms-alpha.c:8002
- #, c-format
- msgid "  lppsbfixoff: %5u\n"
- msgstr ""
- 
--#: vms-alpha.c:8009
-+#: vms-alpha.c:8010
- #, c-format
- msgid " Shareable images:\n"
- msgstr ""
- 
--#: vms-alpha.c:8014
-+#: vms-alpha.c:8015
- #, c-format
- msgid "  %u: size: %u, flags: 0x%02x, name: %.*s\n"
- msgstr ""
- 
--#: vms-alpha.c:8021
-+#: vms-alpha.c:8022
- #, c-format
- msgid " quad-word relocation fixups:\n"
- msgstr ""
- 
--#: vms-alpha.c:8026
-+#: vms-alpha.c:8027
- #, c-format
- msgid " long-word relocation fixups:\n"
- msgstr ""
- 
--#: vms-alpha.c:8031
-+#: vms-alpha.c:8032
- #, c-format
- msgid " quad-word .address reference fixups:\n"
- msgstr ""
- 
--#: vms-alpha.c:8036
-+#: vms-alpha.c:8037
- #, c-format
- msgid " long-word .address reference fixups:\n"
- msgstr ""
- 
--#: vms-alpha.c:8041
-+#: vms-alpha.c:8042
- #, c-format
- msgid " Code Address Reference Fixups:\n"
- msgstr ""
- 
--#: vms-alpha.c:8046
-+#: vms-alpha.c:8047
- #, c-format
- msgid " Linkage Pairs Reference Fixups:\n"
- msgstr ""
- 
--#: vms-alpha.c:8055
-+#: vms-alpha.c:8056
- #, c-format
- msgid " Change Protection (%u entries):\n"
- msgstr ""
- 
--#: vms-alpha.c:8061
-+#: vms-alpha.c:8062
- #, c-format
- msgid "  base: 0x%08x %08x, size: 0x%08x, prot: 0x%08x "
- msgstr ""
- 
- #. FIXME: we do not yet support relocatable link.  It is not obvious
- #. how to do it for debug infos.
--#: vms-alpha.c:8901
-+#: vms-alpha.c:8902
- msgid "%P: relocatable link is not supported\n"
- msgstr ""
- 
--#: vms-alpha.c:8972
-+#: vms-alpha.c:8973
- #, c-format
--msgid "%P: multiple entry points: in modules %B and %B\n"
-+msgid "%P: multiple entry points: in modules %pB and %pB\n"
- msgstr ""
- 
- #: vms-lib.c:1445
-@@ -8594,7 +8564,7 @@ msgstr ""
- #: peigen.c:1906 peigen.c:2103 pepigen.c:1906 pepigen.c:2103 pex64igen.c:1906
- #: pex64igen.c:2103
- #, c-format
--msgid "Warning, .pdata section size (%ld) is not a multiple of %d\n"
-+msgid "warning, .pdata section size (%ld) is not a multiple of %d\n"
- msgstr ""
- 
- #: peigen.c:1910 peigen.c:2107 pepigen.c:1910 pepigen.c:2107 pex64igen.c:1910
-@@ -8795,82 +8765,92 @@ msgid ""
- "Characteristics 0x%x\n"
- msgstr ""
- 
--#: peigen.c:2989 pepigen.c:2989 pex64igen.c:2989
-+#: peigen.c:2990 pepigen.c:2990 pex64igen.c:2990
- #, c-format
--msgid "%B: Data Directory size (%lx) exceeds space left in section (%Lx)"
-+msgid ""
-+"%pB: Data Directory size (%lx) exceeds space left in section (%<PRIx64>)"
- msgstr ""
- 
--#: peigen.c:3019 pepigen.c:3019 pex64igen.c:3019
--msgid "Failed to update file offsets in debug directory"
-+#: peigen.c:3021 pepigen.c:3021 pex64igen.c:3021
-+msgid "failed to update file offsets in debug directory"
- msgstr ""
- 
--#: peigen.c:3025 pepigen.c:3025 pex64igen.c:3025
--msgid "%B: Failed to read debug data section"
-+#: peigen.c:3027 pepigen.c:3027 pex64igen.c:3027
-+#, c-format
-+msgid "%pB: failed to read debug data section"
- msgstr ""
- 
--#: peigen.c:3841 pepigen.c:3841 pex64igen.c:3841
-+#: peigen.c:3843 pepigen.c:3843 pex64igen.c:3843
- #, c-format
- msgid ".rsrc merge failure: duplicate string resource: %d"
- msgstr ""
- 
--#: peigen.c:3976 pepigen.c:3976 pex64igen.c:3976
-+#: peigen.c:3978 pepigen.c:3978 pex64igen.c:3978
- msgid ".rsrc merge failure: multiple non-default manifests"
- msgstr ""
- 
--#: peigen.c:3994 pepigen.c:3994 pex64igen.c:3994
-+#: peigen.c:3996 pepigen.c:3996 pex64igen.c:3996
- msgid ".rsrc merge failure: a directory matches a leaf"
- msgstr ""
- 
--#: peigen.c:4036 pepigen.c:4036 pex64igen.c:4036
-+#: peigen.c:4038 pepigen.c:4038 pex64igen.c:4038
- msgid ".rsrc merge failure: duplicate leaf"
- msgstr ""
- 
--#: peigen.c:4038 pepigen.c:4038 pex64igen.c:4038
-+#: peigen.c:4040 pepigen.c:4040 pex64igen.c:4040
- #, c-format
- msgid ".rsrc merge failure: duplicate leaf: %s"
- msgstr ""
- 
--#: peigen.c:4104 pepigen.c:4104 pex64igen.c:4104
--msgid ".rsrc merge failure: dirs with differing characteristics\n"
-+#: peigen.c:4106 pepigen.c:4106 pex64igen.c:4106
-+msgid ".rsrc merge failure: dirs with differing characteristics"
- msgstr ""
- 
--#: peigen.c:4111 pepigen.c:4111 pex64igen.c:4111
--msgid ".rsrc merge failure: differing directory versions\n"
-+#: peigen.c:4113 pepigen.c:4113 pex64igen.c:4113
-+msgid ".rsrc merge failure: differing directory versions"
- msgstr ""
- 
- #. Corrupted .rsrc section - cannot merge.
--#: peigen.c:4228 pepigen.c:4228 pex64igen.c:4228
--msgid "%B: .rsrc merge failure: corrupt .rsrc section"
-+#: peigen.c:4230 pepigen.c:4230 pex64igen.c:4230
-+#, c-format
-+msgid "%pB: .rsrc merge failure: corrupt .rsrc section"
- msgstr ""
- 
--#: peigen.c:4236 pepigen.c:4236 pex64igen.c:4236
--msgid "%B: .rsrc merge failure: unexpected .rsrc size"
-+#: peigen.c:4238 pepigen.c:4238 pex64igen.c:4238
-+#, c-format
-+msgid "%pB: .rsrc merge failure: unexpected .rsrc size"
- msgstr ""
- 
--#: peigen.c:4375 pepigen.c:4375 pex64igen.c:4375
--msgid "%B: unable to fill in DataDictionary[1] because .idata$2 is missing"
-+#: peigen.c:4377 pepigen.c:4377 pex64igen.c:4377
-+#, c-format
-+msgid "%pB: unable to fill in DataDictionary[1] because .idata$2 is missing"
- msgstr ""
- 
--#: peigen.c:4395 pepigen.c:4395 pex64igen.c:4395
--msgid "%B: unable to fill in DataDictionary[1] because .idata$4 is missing"
-+#: peigen.c:4397 pepigen.c:4397 pex64igen.c:4397
-+#, c-format
-+msgid "%pB: unable to fill in DataDictionary[1] because .idata$4 is missing"
- msgstr ""
- 
--#: peigen.c:4416 pepigen.c:4416 pex64igen.c:4416
--msgid "%B: unable to fill in DataDictionary[12] because .idata$5 is missing"
-+#: peigen.c:4418 pepigen.c:4418 pex64igen.c:4418
-+#, c-format
-+msgid "%pB: unable to fill in DataDictionary[12] because .idata$5 is missing"
- msgstr ""
- 
--#: peigen.c:4436 pepigen.c:4436 pex64igen.c:4436
-+#: peigen.c:4438 pepigen.c:4438 pex64igen.c:4438
-+#, c-format
- msgid ""
--"%B: unable to fill in DataDictionary[PE_IMPORT_ADDRESS_TABLE (12)] because ."
-+"%pB: unable to fill in DataDictionary[PE_IMPORT_ADDRESS_TABLE (12)] because ."
- "idata$6 is missing"
- msgstr ""
- 
--#: peigen.c:4478 pepigen.c:4478 pex64igen.c:4478
-+#: peigen.c:4480 pepigen.c:4480 pex64igen.c:4480
-+#, c-format
- msgid ""
--"%B: unable to fill in DataDictionary[PE_IMPORT_ADDRESS_TABLE(12)] because ."
-+"%pB: unable to fill in DataDictionary[PE_IMPORT_ADDRESS_TABLE(12)] because ."
- "idata$6 is missing"
- msgstr ""
- 
--#: peigen.c:4503 pepigen.c:4503 pex64igen.c:4503
--msgid "%B: unable to fill in DataDictionary[9] because __tls_used is missing"
-+#: peigen.c:4505 pepigen.c:4505 pex64igen.c:4505
-+#, c-format
-+msgid "%pB: unable to fill in DataDictionary[9] because __tls_used is missing"
- msgstr ""
-Index: git/bfd/ChangeLog
-===================================================================
---- git.orig/bfd/ChangeLog
-+++ git/bfd/ChangeLog
-@@ -1,5 +1,9 @@
- 2018-04-24  Nick Clifton  <nickc@redhat.com>
- 
-+       PR 23110
-+       * peXXigen.c (_bfd_XX_bfd_copy_private_bfd_data_common): Check for
-+       a negative PE_DEBUG_DATA size before iterating over the debug data.
-+
-        PR 23113
-        * elf.c (ignore_section_sym): Check for the output_section pointer
-        being NULL before dereferencing it.
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-10535.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-10535.patch
deleted file mode 100644
index fa8fbd2..0000000
--- a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-10535.patch
+++ /dev/null
@@ -1,61 +0,0 @@
-From db0c309f4011ca94a4abc8458e27f3734dab92ac Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Tue, 24 Apr 2018 16:57:04 +0100
-Subject: [PATCH] Fix an illegal memory access when trying to copy an ELF
- binary with corrupt section symbols.
-
-	PR 23113
-	* elf.c (ignore_section_sym): Check for the output_section pointer
-	being NULL before dereferencing it.
-
-Upstream-Status: Backport
-CVE: CVE-2018-10535
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- bfd/ChangeLog | 4 ++++
- bfd/elf.c     | 9 ++++++++-
- 2 files changed, 12 insertions(+), 1 deletion(-)
-
-Index: git/bfd/elf.c
-===================================================================
---- git.orig/bfd/elf.c
-+++ git/bfd/elf.c
-@@ -4021,15 +4021,22 @@ ignore_section_sym (bfd *abfd, asymbol *
- {
-   elf_symbol_type *type_ptr;
- 
-+  if (sym == NULL)
-+    return FALSE;
-+
-   if ((sym->flags & BSF_SECTION_SYM) == 0)
-     return FALSE;
- 
-+  if (sym->section == NULL)
-+    return TRUE;
-+
-   type_ptr = elf_symbol_from (abfd, sym);
-   return ((type_ptr != NULL
- 	   && type_ptr->internal_elf_sym.st_shndx != 0
- 	   && bfd_is_abs_section (sym->section))
- 	  || !(sym->section->owner == abfd
--	       || (sym->section->output_section->owner == abfd
-+	       || (sym->section->output_section != NULL
-+		   && sym->section->output_section->owner == abfd
- 		   && sym->section->output_offset == 0)
- 	       || bfd_is_abs_section (sym->section)));
- }
-Index: git/bfd/ChangeLog
-===================================================================
---- git.orig/bfd/ChangeLog
-+++ git/bfd/ChangeLog
-@@ -1,3 +1,9 @@
-+2018-04-24  Nick Clifton  <nickc@redhat.com>
-+
-+       PR 23113
-+       * elf.c (ignore_section_sym): Check for the output_section pointer
-+       being NULL before dereferencing it.
-+
- 2018-04-17  Nick Clifton  <nickc@redhat.com>
- 
-        PR 23065
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-17358.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-17358.patch
new file mode 100644
index 0000000..8135091
--- /dev/null
+++ b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-17358.patch
@@ -0,0 +1,144 @@
+From 30838132997e6a3cfe3ec11c58b32b22f6f6b102 Mon Sep 17 00:00:00 2001
+From: Alan Modra <amodra@gmail.com>
+Date: Thu, 20 Sep 2018 15:29:17 +0930
+Subject: [PATCH] Bug 23686, two segment faults in nm
+
+Fixes the bugs exposed by the testcases in the PR, plus two more bugs
+I noticed when looking at _bfd_stab_section_find_nearest_line.
+
+	PR 23686
+	* dwarf2.c (read_section): Error when attempting to malloc
+	"(bfd_size_type) -1".
+	* syms.c (_bfd_stab_section_find_nearest_line): Bounds check
+	function_name.  Bounds check reloc address.  Formatting.  Ensure
+	.stabstr zero terminated.
+CVE: CVE-2018-17358 and CVE-2018-17359
+Upstream-Status: Backport
+Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
+---
+ bfd/ChangeLog |  9 +++++++++
+ bfd/dwarf2.c  |  9 ++++++++-
+ bfd/syms.c    | 22 ++++++++++++++++------
+ 3 files changed, 33 insertions(+), 7 deletions(-)
+
+diff --git a/bfd/ChangeLog b/bfd/ChangeLog
+index 04c0c2a..fef5479 100644
+--- a/bfd/ChangeLog
++++ b/bfd/ChangeLog
+@@ -1,3 +1,12 @@
++2018-09-20  Alan Modra  <amodra@gmail.com>
++
++	PR 23686
++	* dwarf2.c (read_section): Error when attempting to malloc
++	"(bfd_size_type) -1".
++	* syms.c (_bfd_stab_section_find_nearest_line): Bounds check
++	function_name.  Bounds check reloc address.  Formatting.  Ensure
++	.stabstr zero terminated.
++
+ 2018-08-12  H.J. Lu  <hongjiu.lu@intel.com>
+ 
+ 	PR ld/23428
+diff --git a/bfd/dwarf2.c b/bfd/dwarf2.c
+index 3b28855..77a7368 100644
+--- a/bfd/dwarf2.c
++++ b/bfd/dwarf2.c
+@@ -527,6 +527,7 @@ read_section (bfd *	      abfd,
+   asection *msec;
+   const char *section_name = sec->uncompressed_name;
+   bfd_byte *contents = *section_buffer;
++  bfd_size_type amt;
+ 
+   /* The section may have already been read.  */
+   if (contents == NULL)
+@@ -549,7 +550,13 @@ read_section (bfd *	      abfd,
+       *section_size = msec->rawsize ? msec->rawsize : msec->size;
+       /* Paranoia - alloc one extra so that we can make sure a string
+ 	 section is NUL terminated.  */
+-      contents = (bfd_byte *) bfd_malloc (*section_size + 1);
++      amt = *section_size + 1;
++      if (amt == 0)
++	{
++	  bfd_set_error (bfd_error_no_memory);
++	  return FALSE;
++	}
++      contents = (bfd_byte *) bfd_malloc (amt);
+       if (contents == NULL)
+ 	return FALSE;
+       if (syms
+diff --git a/bfd/syms.c b/bfd/syms.c
+index 187071f..e09640a 100644
+--- a/bfd/syms.c
++++ b/bfd/syms.c
+@@ -1035,6 +1035,10 @@ _bfd_stab_section_find_nearest_line (bfd *abfd,
+ 					 0, strsize))
+ 	return FALSE;
+ 
++      /* Stab strings ought to be nul terminated.  Ensure the last one
++	 is, to prevent running off the end of the buffer.  */
++      info->strs[strsize - 1] = 0;
++
+       /* If this is a relocatable object file, we have to relocate
+ 	 the entries in .stab.  This should always be simple 32 bit
+ 	 relocations against symbols defined in this object file, so
+@@ -1073,7 +1077,8 @@ _bfd_stab_section_find_nearest_line (bfd *abfd,
+ 		  || r->howto->bitsize != 32
+ 		  || r->howto->pc_relative
+ 		  || r->howto->bitpos != 0
+-		  || r->howto->dst_mask != 0xffffffff)
++		  || r->howto->dst_mask != 0xffffffff
++		  || r->address * bfd_octets_per_byte (abfd) + 4 > stabsize)
+ 		{
+ 		  _bfd_error_handler
+ 		    (_("unsupported .stab relocation"));
+@@ -1195,7 +1200,8 @@ _bfd_stab_section_find_nearest_line (bfd *abfd,
+ 		{
+ 		  nul_fun = stab;
+ 		  nul_str = str;
+-		  if (file_name >= (char *) info->strs + strsize || file_name < (char *) str)
++		  if (file_name >= (char *) info->strs + strsize
++		      || file_name < (char *) str)
+ 		    file_name = NULL;
+ 		  if (stab + STABSIZE + TYPEOFF < info->stabs + stabsize
+ 		      && *(stab + STABSIZE + TYPEOFF) == (bfd_byte) N_SO)
+@@ -1206,7 +1212,8 @@ _bfd_stab_section_find_nearest_line (bfd *abfd,
+ 		      directory_name = file_name;
+ 		      file_name = ((char *) str
+ 				   + bfd_get_32 (abfd, stab + STRDXOFF));
+-		      if (file_name >= (char *) info->strs + strsize || file_name < (char *) str)
++		      if (file_name >= (char *) info->strs + strsize
++			  || file_name < (char *) str)
+ 			file_name = NULL;
+ 		    }
+ 		}
+@@ -1217,7 +1224,8 @@ _bfd_stab_section_find_nearest_line (bfd *abfd,
+ 	      file_name = (char *) str + bfd_get_32 (abfd, stab + STRDXOFF);
+ 	      /* PR 17512: file: 0c680a1f.  */
+ 	      /* PR 17512: file: 5da8aec4.  */
+-	      if (file_name >= (char *) info->strs + strsize || file_name < (char *) str)
++	      if (file_name >= (char *) info->strs + strsize
++		  || file_name < (char *) str)
+ 		file_name = NULL;
+ 	      break;
+ 
+@@ -1226,7 +1234,8 @@ _bfd_stab_section_find_nearest_line (bfd *abfd,
+ 	      function_name = (char *) str + bfd_get_32 (abfd, stab + STRDXOFF);
+ 	      if (function_name == (char *) str)
+ 		continue;
+-	      if (function_name >= (char *) info->strs + strsize)
++	      if (function_name >= (char *) info->strs + strsize
++		  || function_name < (char *) str)
+ 		function_name = NULL;
+ 
+ 	      nul_fun = NULL;
+@@ -1335,7 +1344,8 @@ _bfd_stab_section_find_nearest_line (bfd *abfd,
+ 	  if (val <= offset)
+ 	    {
+ 	      file_name = (char *) str + bfd_get_32 (abfd, stab + STRDXOFF);
+-	      if (file_name >= (char *) info->strs + strsize || file_name < (char *) str)
++	      if (file_name >= (char *) info->strs + strsize
++		  || file_name < (char *) str)
+ 		file_name = NULL;
+ 	      *pline = 0;
+ 	    }
+-- 
+2.9.3
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-17360.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-17360.patch
new file mode 100644
index 0000000..cef10a7
--- /dev/null
+++ b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-17360.patch
@@ -0,0 +1,65 @@
+From cf93e9c2cf8f8b2566f8fc86e961592b51b5980d Mon Sep 17 00:00:00 2001
+From: Alan Modra <amodra@gmail.com>
+Date: Thu, 20 Sep 2018 18:23:17 +0930
+Subject: [PATCH] PR23685, buffer overflow
+
+	PR 23685
+	* peXXigen.c (pe_print_edata): Correct export address table
+	overflow checks.  Check dataoff against section size too.
+
+CVE: CVE-2018-17360
+Upstream-Status: Backport
+Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
+---
+ bfd/ChangeLog  |  6 ++++++
+ bfd/peXXigen.c | 11 ++++++-----
+ 2 files changed, 12 insertions(+), 5 deletions(-)
+
+diff --git a/bfd/ChangeLog b/bfd/ChangeLog
+index fef5479..81b9e56 100644
+--- a/bfd/ChangeLog
++++ b/bfd/ChangeLog
+@@ -1,5 +1,11 @@
+ 2018-09-20  Alan Modra  <amodra@gmail.com>
+ 
++	PR 23685
++	* peXXigen.c (pe_print_edata): Correct export address table
++	overflow checks.  Check dataoff against section size too.
++
++2018-09-20  Alan Modra  <amodra@gmail.com>
++
+ 	PR 23686
+ 	* dwarf2.c (read_section): Error when attempting to malloc
+ 	"(bfd_size_type) -1".
+diff --git a/bfd/peXXigen.c b/bfd/peXXigen.c
+index 598f2ca..1645ef4 100644
+--- a/bfd/peXXigen.c
++++ b/bfd/peXXigen.c
+@@ -1661,7 +1661,8 @@ pe_print_edata (bfd * abfd, void * vfile)
+ 
+       dataoff = addr - section->vma;
+       datasize = extra->DataDirectory[PE_EXPORT_TABLE].Size;
+-      if (datasize > section->size - dataoff)
++      if (dataoff > section->size
++	  || datasize > section->size - dataoff)
+ 	{
+ 	  fprintf (file,
+ 		   _("\nThere is an export table in %s, but it does not fit into that section\n"),
+@@ -1778,11 +1779,11 @@ pe_print_edata (bfd * abfd, void * vfile)
+ 	  edt.base);
+ 
+   /* PR 17512: Handle corrupt PE binaries.  */
+-  if (edt.eat_addr + (edt.num_functions * 4) - adj >= datasize
++  /* PR 17512 file: 140-165018-0.004.  */
++  if (edt.eat_addr - adj >= datasize
+       /* PR 17512: file: 092b1829 */
+-      || (edt.num_functions * 4) < edt.num_functions
+-      /* PR 17512 file: 140-165018-0.004.  */
+-      || data + edt.eat_addr - adj < data)
++      || (edt.num_functions + 1) * 4 < edt.num_functions
++      || edt.eat_addr - adj + (edt.num_functions + 1) * 4 > datasize)
+     fprintf (file, _("\tInvalid Export Address Table rva (0x%lx) or entry count (0x%lx)\n"),
+ 	     (long) edt.eat_addr,
+ 	     (long) edt.num_functions);
+-- 
+2.9.3
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-18309.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-18309.patch
new file mode 100644
index 0000000..b240a3f
--- /dev/null
+++ b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-18309.patch
@@ -0,0 +1,308 @@
+From 0930cb3021b8078b34cf216e79eb8608d017864f Mon Sep 17 00:00:00 2001
+From: Alan Modra <amodra@gmail.com>
+Date: Sat, 13 Oct 2018 22:03:02 +1030
+Subject: [PATCH] _bfd_clear_contents bounds checking
+
+This PR shows a fuzzed binary triggering a segfault via a bad
+relocation in .debug_line.  It turns out that unlike normal
+relocations applied to a section, the linker applies those with
+symbols from discarded sections via _bfd_clear_contents without
+checking that the relocation is within the section bounds.  The same
+thing now happens when reading debug sections since commit
+a4cd947aca23, the PR23425 fix.
+
+	PR 23770
+	PR 23425
+	* reloc.c (_bfd_clear_contents): Replace "location" param with
+	"buf" and "off".  Bounds check "off".  Return status.
+	* cofflink.c (_bfd_coff_generic_relocate_section): Update
+	_bfd_clear_contents call.
+	* elf-bfd.h (RELOC_AGAINST_DISCARDED_SECTION): Likewise.
+	* elf32-arc.c (elf_arc_relocate_section): Likewise.
+	* elf32-i386.c (elf_i386_relocate_section): Likewise.
+	* elf32-metag.c (metag_final_link_relocate): Likewise.
+	* elf32-nds32.c (nds32_elf_get_relocated_section_contents): Likewise.
+	* elf32-ppc.c (ppc_elf_relocate_section): Likewise.
+	* elf32-visium.c (visium_elf_relocate_section): Likewise.
+	* elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
+	* elf64-x86-64.c *(elf_x86_64_relocate_section): Likewise.
+	* libbfd-in.h (_bfd_clear_contents): Update prototype.
+	* libbfd.h: Regenerate.
+
+Upstream-Status: Backport
+CVE: CVE-2018-18605
+Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
+---
+ bfd/ChangeLog      | 20 ++++++++++++++++++++
+ bfd/cofflink.c     |  2 +-
+ bfd/elf-bfd.h      |  2 +-
+ bfd/elf32-arc.c    |  2 +-
+ bfd/elf32-i386.c   |  2 +-
+ bfd/elf32-metag.c  |  2 +-
+ bfd/elf32-nds32.c  |  8 ++++----
+ bfd/elf32-ppc.c    |  2 +-
+ bfd/elf32-visium.c |  2 +-
+ bfd/elf64-ppc.c    |  2 +-
+ bfd/elf64-x86-64.c |  2 +-
+ bfd/libbfd-in.h    |  4 ++--
+ bfd/libbfd.h       |  4 ++--
+ bfd/reloc.c        | 19 +++++++++++++------
+ 14 files changed, 50 insertions(+), 23 deletions(-)
+
+diff --git a/bfd/ChangeLog b/bfd/ChangeLog
+index 68c1ff665b..e9696ee314 100644
+--- a/bfd/ChangeLog
++++ b/bfd/ChangeLog
+@@ -1,3 +1,23 @@
++2018-10-13  Alan Modra  <amodra@gmail.com>
++
++	PR 23770
++	PR 23425
++	* reloc.c (_bfd_clear_contents): Replace "location" param with
++	"buf" and "off".  Bounds check "off".  Return status.
++	* cofflink.c (_bfd_coff_generic_relocate_section): Update
++	_bfd_clear_contents call.
++	* elf-bfd.h (RELOC_AGAINST_DISCARDED_SECTION): Likewise.
++	* elf32-arc.c (elf_arc_relocate_section): Likewise.
++	* elf32-i386.c (elf_i386_relocate_section): Likewise.
++	* elf32-metag.c (metag_final_link_relocate): Likewise.
++	* elf32-nds32.c (nds32_elf_get_relocated_section_contents): Likewise.
++	* elf32-ppc.c (ppc_elf_relocate_section): Likewise.
++	* elf32-visium.c (visium_elf_relocate_section): Likewise.
++	* elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
++	* elf64-x86-64.c *(elf_x86_64_relocate_section): Likewise.
++	* libbfd-in.h (_bfd_clear_contents): Update prototype.
++	* libbfd.h: Regenerate.
++
+ 2018-09-20  Alan Modra  <amodra@gmail.com>
+ 
+ 	PR 23685
+diff --git a/bfd/cofflink.c b/bfd/cofflink.c
+index 2f73f72e31..b7ea69b7f9 100644
+--- a/bfd/cofflink.c
++++ b/bfd/cofflink.c
+@@ -3080,7 +3080,7 @@ _bfd_coff_generic_relocate_section (bfd *output_bfd,
+       if (sec != NULL && discarded_section (sec))
+ 	{
+ 	  _bfd_clear_contents (howto, input_bfd, input_section,
+-			       contents + (rel->r_vaddr - input_section->vma));
++			       contents, rel->r_vaddr - input_section->vma);
+ 	  continue;
+ 	}
+ 
+diff --git a/bfd/elf-bfd.h b/bfd/elf-bfd.h
+index cf256f70e0..3374f411f9 100644
+--- a/bfd/elf-bfd.h
++++ b/bfd/elf-bfd.h
+@@ -2811,7 +2811,7 @@ extern asection _bfd_elf_large_com_section;
+   {									\
+     int i_;								\
+     _bfd_clear_contents (howto, input_bfd, input_section,		\
+-			 contents + rel[index].r_offset);		\
++			 contents, rel[index].r_offset);		\
+ 									\
+     if (bfd_link_relocatable (info)					\
+ 	&& (input_section->flags & SEC_DEBUGGING))			\
+diff --git a/bfd/elf32-arc.c b/bfd/elf32-arc.c
+index 7a1b3042ae..30f47a5b22 100644
+--- a/bfd/elf32-arc.c
++++ b/bfd/elf32-arc.c
+@@ -1549,7 +1549,7 @@ elf_arc_relocate_section (bfd *			  output_bfd,
+       if (sec != NULL && discarded_section (sec))
+ 	{
+ 	  _bfd_clear_contents (howto, input_bfd, input_section,
+-			       contents + rel->r_offset);
++			       contents, rel->r_offset);
+ 	  rel->r_info = 0;
+ 	  rel->r_addend = 0;
+ 
+diff --git a/bfd/elf32-i386.c b/bfd/elf32-i386.c
+index 49797dcbfa..177471777d 100644
+--- a/bfd/elf32-i386.c
++++ b/bfd/elf32-i386.c
+@@ -2197,7 +2197,7 @@ elf_i386_relocate_section (bfd *output_bfd,
+       if (sec != NULL && discarded_section (sec))
+ 	{
+ 	  _bfd_clear_contents (howto, input_bfd, input_section,
+-			       contents + rel->r_offset);
++			       contents, rel->r_offset);
+ 	  wrel->r_offset = rel->r_offset;
+ 	  wrel->r_info = 0;
+ 	  wrel->r_addend = 0;
+diff --git a/bfd/elf32-metag.c b/bfd/elf32-metag.c
+index efe95bddff..7f96246e5d 100644
+--- a/bfd/elf32-metag.c
++++ b/bfd/elf32-metag.c
+@@ -1396,7 +1396,7 @@ metag_final_link_relocate (reloc_howto_type *howto,
+ 					      rel, relend, howto, contents) \
+   {									\
+     _bfd_clear_contents (howto, input_bfd, input_section,		\
+-			 contents + rel->r_offset);			\
++			 contents, rel->r_offset);			\
+ 									\
+     if (bfd_link_relocatable (info)					\
+ 	&& (input_section->flags & SEC_DEBUGGING))			\
+diff --git a/bfd/elf32-nds32.c b/bfd/elf32-nds32.c
+index 0d86e5b865..184cf320f7 100644
+--- a/bfd/elf32-nds32.c
++++ b/bfd/elf32-nds32.c
+@@ -12582,14 +12582,14 @@ nds32_elf_get_relocated_section_contents (bfd *abfd,
+ 	  symbol = *(*parent)->sym_ptr_ptr;
+ 	  if (symbol->section && discarded_section (symbol->section))
+ 	    {
+-	      bfd_byte *p;
++	      bfd_vma off;
+ 	      static reloc_howto_type none_howto
+ 		= HOWTO (0, 0, 0, 0, FALSE, 0, complain_overflow_dont, NULL,
+ 			 "unused", FALSE, 0, 0, FALSE);
+ 
+-	      p = data + (*parent)->address * bfd_octets_per_byte (input_bfd);
+-	      _bfd_clear_contents ((*parent)->howto, input_bfd, input_section,
+-				   p);
++	      off = (*parent)->address * bfd_octets_per_byte (input_bfd);
++	      _bfd_clear_contents ((*parent)->howto, input_bfd,
++				   input_section, data, off);
+ 	      (*parent)->sym_ptr_ptr = bfd_abs_section_ptr->symbol_ptr_ptr;
+ 	      (*parent)->addend = 0;
+ 	      (*parent)->howto = &none_howto;
+diff --git a/bfd/elf32-ppc.c b/bfd/elf32-ppc.c
+index 61f70de12e..c31e26efd7 100644
+--- a/bfd/elf32-ppc.c
++++ b/bfd/elf32-ppc.c
+@@ -8232,7 +8232,7 @@ ppc_elf_relocate_section (bfd *output_bfd,
+ 	    howto = ppc_elf_howto_table[r_type];
+ 
+ 	  _bfd_clear_contents (howto, input_bfd, input_section,
+-			       contents + rel->r_offset);
++			       contents, rel->r_offset);
+ 	  wrel->r_offset = rel->r_offset;
+ 	  wrel->r_info = 0;
+ 	  wrel->r_addend = 0;
+diff --git a/bfd/elf32-visium.c b/bfd/elf32-visium.c
+index e8f1c4c9e4..961366cd87 100644
+--- a/bfd/elf32-visium.c
++++ b/bfd/elf32-visium.c
+@@ -621,7 +621,7 @@ visium_elf_relocate_section (bfd *output_bfd,
+ 	     or sections discarded by a linker script, we just want the
+ 	     section contents zeroed.  Avoid any special processing.  */
+ 	  _bfd_clear_contents (howto, input_bfd, input_section,
+-			       contents + rel->r_offset);
++			       contents, rel->r_offset);
+ 
+ 	  rel->r_info = 0;
+ 	  rel->r_addend = 0;
+diff --git a/bfd/elf64-ppc.c b/bfd/elf64-ppc.c
+index eadde17615..7c3534ac65 100644
+--- a/bfd/elf64-ppc.c
++++ b/bfd/elf64-ppc.c
+@@ -14073,7 +14073,7 @@ ppc64_elf_relocate_section (bfd *output_bfd,
+ 	{
+ 	  _bfd_clear_contents (ppc64_elf_howto_table[r_type],
+ 			       input_bfd, input_section,
+-			       contents + rel->r_offset);
++			       contents, rel->r_offset);
+ 	  wrel->r_offset = rel->r_offset;
+ 	  wrel->r_info = 0;
+ 	  wrel->r_addend = 0;
+diff --git a/bfd/elf64-x86-64.c b/bfd/elf64-x86-64.c
+index c3a6c31ed2..4dcab43478 100644
+--- a/bfd/elf64-x86-64.c
++++ b/bfd/elf64-x86-64.c
+@@ -2490,7 +2490,7 @@ elf_x86_64_relocate_section (bfd *output_bfd,
+       if (sec != NULL && discarded_section (sec))
+ 	{
+ 	  _bfd_clear_contents (howto, input_bfd, input_section,
+-			       contents + rel->r_offset);
++			       contents, rel->r_offset);
+ 	  wrel->r_offset = rel->r_offset;
+ 	  wrel->r_info = 0;
+ 	  wrel->r_addend = 0;
+diff --git a/bfd/libbfd-in.h b/bfd/libbfd-in.h
+index e53b255dad..f6d9565f03 100644
+--- a/bfd/libbfd-in.h
++++ b/bfd/libbfd-in.h
+@@ -696,8 +696,8 @@ extern bfd_reloc_status_type _bfd_relocate_contents
+   (reloc_howto_type *, bfd *, bfd_vma, bfd_byte *) ATTRIBUTE_HIDDEN;
+ 
+ /* Clear a given location using a given howto.  */
+-extern void _bfd_clear_contents
+-  (reloc_howto_type *, bfd *, asection *, bfd_byte *) ATTRIBUTE_HIDDEN;
++extern bfd_reloc_status_type _bfd_clear_contents
++  (reloc_howto_type *, bfd *, asection *, bfd_byte *, bfd_vma) ATTRIBUTE_HIDDEN;
+ 
+ /* Link stabs in sections in the first pass.  */
+ 
+diff --git a/bfd/libbfd.h b/bfd/libbfd.h
+index a8851c8026..1189e63358 100644
+--- a/bfd/libbfd.h
++++ b/bfd/libbfd.h
+@@ -701,8 +701,8 @@ extern bfd_reloc_status_type _bfd_relocate_contents
+   (reloc_howto_type *, bfd *, bfd_vma, bfd_byte *) ATTRIBUTE_HIDDEN;
+ 
+ /* Clear a given location using a given howto.  */
+-extern void _bfd_clear_contents
+-  (reloc_howto_type *, bfd *, asection *, bfd_byte *) ATTRIBUTE_HIDDEN;
++extern bfd_reloc_status_type _bfd_clear_contents
++  (reloc_howto_type *, bfd *, asection *, bfd_byte *, bfd_vma) ATTRIBUTE_HIDDEN;
+ 
+ /* Link stabs in sections in the first pass.  */
+ 
+diff --git a/bfd/reloc.c b/bfd/reloc.c
+index 8dbb8896d3..1686780669 100644
+--- a/bfd/reloc.c
++++ b/bfd/reloc.c
+@@ -1613,16 +1613,22 @@ _bfd_relocate_contents (reloc_howto_type *howto,
+    relocations against discarded symbols, to make ignorable debug or unwind
+    information more obvious.  */
+ 
+-void
++bfd_reloc_status_type
+ _bfd_clear_contents (reloc_howto_type *howto,
+ 		     bfd *input_bfd,
+ 		     asection *input_section,
+-		     bfd_byte *location)
++		     bfd_byte *buf,
++		     bfd_vma off)
+ {
+   int size;
+   bfd_vma x = 0;
++  bfd_byte *location;
++
++  if (!bfd_reloc_offset_in_range (howto, input_bfd, input_section, off))
++    return bfd_reloc_outofrange;
+ 
+   /* Get the value we are going to relocate.  */
++  location = buf + off;
+   size = bfd_get_reloc_size (howto);
+   switch (size)
+     {
+@@ -1687,6 +1693,7 @@ _bfd_clear_contents (reloc_howto_type *howto,
+ #endif
+       break;
+     }
++  return bfd_reloc_ok;
+ }
+ 
+ /*
+@@ -8275,14 +8282,14 @@ bfd_generic_get_relocated_section_contents (bfd *abfd,
+ 
+ 	  if (symbol->section && discarded_section (symbol->section))
+ 	    {
+-	      bfd_byte *p;
++	      bfd_vma off;
+ 	      static reloc_howto_type none_howto
+ 		= HOWTO (0, 0, 0, 0, FALSE, 0, complain_overflow_dont, NULL,
+ 			 "unused", FALSE, 0, 0, FALSE);
+ 
+-	      p = data + (*parent)->address * bfd_octets_per_byte (input_bfd);
+-	      _bfd_clear_contents ((*parent)->howto, input_bfd, input_section,
+-				   p);
++	      off = (*parent)->address * bfd_octets_per_byte (input_bfd);
++	      _bfd_clear_contents ((*parent)->howto, input_bfd,
++				   input_section, data, off);
+ 	      (*parent)->sym_ptr_ptr = bfd_abs_section_ptr->symbol_ptr_ptr;
+ 	      (*parent)->addend = 0;
+ 	      (*parent)->howto = &none_howto;
+-- 
+2.13.3
+
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-18605.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-18605.patch
new file mode 100644
index 0000000..d6c7067
--- /dev/null
+++ b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-18605.patch
@@ -0,0 +1,47 @@
+From ab419ddbb2cdd17ca83618990f2cacf904ce1d61 Mon Sep 17 00:00:00 2001
+From: Alan Modra <amodra@gmail.com>
+Date: Tue, 23 Oct 2018 18:29:24 +1030
+Subject: [PATCH] PR23804, buffer overflow in sec_merge_hash_lookup
+
+	PR 23804
+	* merge.c (_bfd_add_merge_section): Don't attempt to merge
+	sections where size is not a multiple of entsize.
+
+Upstream-Status: Backport
+CVE: CVE-2018-18605
+Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
+---
+ bfd/ChangeLog | 6 ++++++
+ bfd/merge.c   | 3 +++
+ 2 files changed, 9 insertions(+)
+
+diff --git a/bfd/ChangeLog b/bfd/ChangeLog
+index 31ff3d6..da423b1 100644
+--- a/bfd/ChangeLog
++++ b/bfd/ChangeLog
+@@ -1,3 +1,9 @@
++2018-10-23  Alan Modra  <amodra@gmail.com>
++
++	PR 23804
++	* merge.c (_bfd_add_merge_section): Don't attempt to merge
++	sections where size is not a multiple of entsize.
++
+ 2018-10-13  Alan Modra  <amodra@gmail.com>
+ 
+ 	PR 23770
+diff --git a/bfd/merge.c b/bfd/merge.c
+index 7904552..5e3bba0 100644
+--- a/bfd/merge.c
++++ b/bfd/merge.c
+@@ -376,6 +376,9 @@ _bfd_add_merge_section (bfd *abfd, void **psinfo, asection *sec,
+       || sec->entsize == 0)
+     return TRUE;
+ 
++  if (sec->size % sec->entsize != 0)
++    return TRUE;
++
+   if ((sec->flags & SEC_RELOC) != 0)
+     {
+       /* We aren't prepared to handle relocations in merged sections.  */
+-- 
+2.9.3
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-18606.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-18606.patch
new file mode 100644
index 0000000..35cf328
--- /dev/null
+++ b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-18606.patch
@@ -0,0 +1,70 @@
+From 45a0eaf77022963d639d6d19871dbab7b79703fc Mon Sep 17 00:00:00 2001
+From: Alan Modra <amodra@gmail.com>
+Date: Tue, 23 Oct 2018 19:02:06 +1030
+Subject: [PATCH] PR23806, NULL pointer dereference in merge_strings
+
+	PR 23806
+	* merge.c (_bfd_add_merge_section): Don't attempt to merge
+	sections with ridiculously large alignments.
+
+Upstream-Status: Backport
+CVE: CVE-2018-18606
+Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
+---
+ bfd/ChangeLog |  6 ++++++
+ bfd/merge.c   | 15 +++++++++++----
+ 2 files changed, 17 insertions(+), 4 deletions(-)
+
+diff --git a/bfd/ChangeLog b/bfd/ChangeLog
+index 1f3fc1c..c5f7ec7 100644
+--- a/bfd/ChangeLog
++++ b/bfd/ChangeLog
+@@ -1,5 +1,11 @@
+ 2018-10-23  Alan Modra  <amodra@gmail.com>
+ 
++	PR 23806
++	* merge.c (_bfd_add_merge_section): Don't attempt to merge
++	sections with ridiculously large alignments.
++
++2018-10-23  Alan Modra  <amodra@gmail.com>
++
+ 	PR 23804
+ 	* merge.c (_bfd_add_merge_section): Don't attempt to merge
+ 	sections where size is not a multiple of entsize.
+diff --git a/bfd/merge.c b/bfd/merge.c
+index 5e3bba0..7de0c88 100644
+--- a/bfd/merge.c
++++ b/bfd/merge.c
+@@ -24,6 +24,7 @@
+    as used in ELF SHF_MERGE.  */
+ 
+ #include "sysdep.h"
++#include <limits.h>
+ #include "bfd.h"
+ #include "elf-bfd.h"
+ #include "libbfd.h"
+@@ -385,12 +386,18 @@ _bfd_add_merge_section (bfd *abfd, void **psinfo, asection *sec,
+       return TRUE;
+     }
+ 
+-  align = sec->alignment_power;
+-  if ((sec->entsize < (unsigned) 1 << align
++#ifndef CHAR_BIT
++#define CHAR_BIT 8
++#endif
++  if (sec->alignment_power >= sizeof (align) * CHAR_BIT)
++    return TRUE;
++
++  align = 1u << sec->alignment_power;
++  if ((sec->entsize < align
+        && ((sec->entsize & (sec->entsize - 1))
+ 	   || !(sec->flags & SEC_STRINGS)))
+-      || (sec->entsize > (unsigned) 1 << align
+-	  && (sec->entsize & (((unsigned) 1 << align) - 1))))
++      || (sec->entsize > align
++	  && (sec->entsize & (align - 1))))
+     {
+       /* Sanity check.  If string character size is smaller than
+ 	 alignment, then we require character size to be a power
+-- 
+2.9.3
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-18607.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-18607.patch
new file mode 100644
index 0000000..38225d1
--- /dev/null
+++ b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-18607.patch
@@ -0,0 +1,77 @@
+From 102def4da826b3d9e169741421e5e67e8731909a Mon Sep 17 00:00:00 2001
+From: Alan Modra <amodra@gmail.com>
+Date: Tue, 23 Oct 2018 18:30:22 +1030
+Subject: [PATCH] PR23805, NULL pointer dereference in elf_link_input_bfd
+
+	PR 23805
+	* elflink.c (elf_link_input_bfd): Don't segfault on finding
+	STT_TLS symbols without any TLS sections.  Instead, change the
+	symbol type to STT_NOTYPE.
+
+Upstream-Status: Backport
+CVE: CVE-2018-18606
+Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
+---
+ bfd/ChangeLog |  7 +++++++
+ bfd/elflink.c | 20 ++++++++++++++------
+ 2 files changed, 21 insertions(+), 6 deletions(-)
+
+diff --git a/bfd/ChangeLog b/bfd/ChangeLog
+index da423b1..1f3fc1c 100644
+--- a/bfd/ChangeLog
++++ b/bfd/ChangeLog
+@@ -1,5 +1,12 @@
+ 2018-10-23  Alan Modra  <amodra@gmail.com>
+ 
++	PR 23805
++	* elflink.c (elf_link_input_bfd): Don't segfault on finding
++	STT_TLS symbols without any TLS sections.  Instead, change the
++	symbol type to STT_NOTYPE.
++
++2018-10-23  Alan Modra  <amodra@gmail.com>
++
+ 	PR 23806
+ 	* merge.c (_bfd_add_merge_section): Don't attempt to merge
+ 	sections with ridiculously large alignments.
+diff --git a/bfd/elflink.c b/bfd/elflink.c
+index c3876cb..87440db 100644
+--- a/bfd/elflink.c
++++ b/bfd/elflink.c
+@@ -10489,8 +10489,11 @@ elf_link_input_bfd (struct elf_final_link_info *flinfo, bfd *input_bfd)
+ 	  if (ELF_ST_TYPE (osym.st_info) == STT_TLS)
+ 	    {
+ 	      /* STT_TLS symbols are relative to PT_TLS segment base.  */
+-	      BFD_ASSERT (elf_hash_table (flinfo->info)->tls_sec != NULL);
+-	      osym.st_value -= elf_hash_table (flinfo->info)->tls_sec->vma;
++	      if (elf_hash_table (flinfo->info)->tls_sec != NULL)
++		osym.st_value -= elf_hash_table (flinfo->info)->tls_sec->vma;
++	      else
++		osym.st_info = ELF_ST_INFO (ELF_ST_BIND (osym.st_info),
++					    STT_NOTYPE);
+ 	    }
+ 	}
+ 
+@@ -11046,12 +11049,17 @@ elf_link_input_bfd (struct elf_final_link_info *flinfo, bfd *input_bfd)
+ 			      sym.st_value += osec->vma;
+ 			      if (ELF_ST_TYPE (sym.st_info) == STT_TLS)
+ 				{
++				  struct elf_link_hash_table *htab
++				    = elf_hash_table (flinfo->info);
++
+ 				  /* STT_TLS symbols are relative to PT_TLS
+ 				     segment base.  */
+-				  BFD_ASSERT (elf_hash_table (flinfo->info)
+-					      ->tls_sec != NULL);
+-				  sym.st_value -= (elf_hash_table (flinfo->info)
+-						   ->tls_sec->vma);
++				  if (htab->tls_sec != NULL)
++				    sym.st_value -= htab->tls_sec->vma;
++				  else
++				    sym.st_info
++				      = ELF_ST_INFO (ELF_ST_BIND (sym.st_info),
++						     STT_NOTYPE);
+ 				}
+ 			    }
+ 
+-- 
+2.9.3
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-6759.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-6759.patch
deleted file mode 100644
index fff4979..0000000
--- a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-6759.patch
+++ /dev/null
@@ -1,108 +0,0 @@
-From 64e234d417d5685a4aec0edc618114d9991c031b Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Tue, 6 Feb 2018 15:48:29 +0000
-Subject: [PATCH] Prevent attempts to call strncpy with a zero-length field by
- chacking the size of debuglink sections.
-
-	PR 22794
-	* opncls.c (bfd_get_debug_link_info_1): Check the size of the
-	section before attempting to read it in.
-	(bfd_get_alt_debug_link_info): Likewise.
-
-Upstream-Status: Backport
-Affects: Binutils <= 2.30
-CVE: CVE-2018-6759
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- bfd/ChangeLog |  7 +++++++
- bfd/opncls.c  | 22 +++++++++++++++++-----
- 2 files changed, 24 insertions(+), 5 deletions(-)
-
-Index: git/bfd/opncls.c
-===================================================================
---- git.orig/bfd/opncls.c
-+++ git/bfd/opncls.c
-@@ -1179,6 +1179,7 @@ bfd_get_debug_link_info_1 (bfd *abfd, vo
-   bfd_byte *contents;
-   unsigned int crc_offset;
-   char *name;
-+  bfd_size_type size;
- 
-   BFD_ASSERT (abfd);
-   BFD_ASSERT (crc32_out);
-@@ -1188,6 +1189,12 @@ bfd_get_debug_link_info_1 (bfd *abfd, vo
-   if (sect == NULL)
-     return NULL;
- 
-+  size = bfd_get_section_size (sect);
-+
-+  /* PR 22794: Make sure that the section has a reasonable size.  */
-+  if (size < 8 || size >= bfd_get_size (abfd))
-+    return NULL;
-+
-   if (!bfd_malloc_and_get_section (abfd, sect, &contents))
-     {
-       if (contents != NULL)
-@@ -1197,10 +1204,10 @@ bfd_get_debug_link_info_1 (bfd *abfd, vo
- 
-   /* CRC value is stored after the filename, aligned up to 4 bytes.  */
-   name = (char *) contents;
--  /* PR 17597: avoid reading off the end of the buffer.  */
--  crc_offset = strnlen (name, bfd_get_section_size (sect)) + 1;
-+  /* PR 17597: Avoid reading off the end of the buffer.  */
-+  crc_offset = strnlen (name, size) + 1;
-   crc_offset = (crc_offset + 3) & ~3;
--  if (crc_offset + 4 > bfd_get_section_size (sect))
-+  if (crc_offset + 4 > size)
-     return NULL;
- 
-   *crc32 = bfd_get_32 (abfd, contents + crc_offset);
-@@ -1261,6 +1268,7 @@ bfd_get_alt_debug_link_info (bfd * abfd,
-   bfd_byte *contents;
-   unsigned int buildid_offset;
-   char *name;
-+  bfd_size_type size;
- 
-   BFD_ASSERT (abfd);
-   BFD_ASSERT (buildid_len);
-@@ -1271,6 +1279,10 @@ bfd_get_alt_debug_link_info (bfd * abfd,
-   if (sect == NULL)
-     return NULL;
- 
-+  size = bfd_get_section_size (sect);
-+  if (size < 8 || size >= bfd_get_size (abfd))
-+    return NULL;
-+
-   if (!bfd_malloc_and_get_section (abfd, sect, & contents))
-     {
-       if (contents != NULL)
-@@ -1280,11 +1292,11 @@ bfd_get_alt_debug_link_info (bfd * abfd,
- 
-   /* BuildID value is stored after the filename.  */
-   name = (char *) contents;
--  buildid_offset = strnlen (name, bfd_get_section_size (sect)) + 1;
-+  buildid_offset = strnlen (name, size) + 1;
-   if (buildid_offset >= bfd_get_section_size (sect))
-     return NULL;
- 
--  *buildid_len = bfd_get_section_size (sect) - buildid_offset;
-+  *buildid_len = size - buildid_offset;
-   *buildid_out = bfd_malloc (*buildid_len);
-   memcpy (*buildid_out, contents + buildid_offset, *buildid_len);
- 
-Index: git/bfd/ChangeLog
-===================================================================
---- git.orig/bfd/ChangeLog
-+++ git/bfd/ChangeLog
-@@ -1,3 +1,10 @@
-+2018-02-06  Nick Clifton  <nickc@redhat.com>
-+
-+       PR 22794
-+       * opncls.c (bfd_get_debug_link_info_1): Check the size of the
-+       section before attempting to read it in.
-+       (bfd_get_alt_debug_link_info): Likewise.
-+
- 2018-02-09  Nick Clifton  <nickc@redhat.com>
- 
-        Import patch from mainline:
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-6872.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-6872.patch
deleted file mode 100644
index 2ef36c2..0000000
--- a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-6872.patch
+++ /dev/null
@@ -1,50 +0,0 @@
-From d895ef77ffc94e02e748856c2ab54f5bb8cc867e Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Fri, 9 Feb 2018 09:28:45 +0000
-Subject: [PATCH] Import patch from mainline to fix possible seg-fault whilst
- parsing corrupt ELF notes with extravagent alignments.
-
-	PR 22788
-	* elf.c (elf_parse_notes): Reject notes with excessuively large
-	alignments.
-
-Upstream-Status: Backport
-Affects: Binutils <= 2.30
-CVE: CVE-2018-6872
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- bfd/ChangeLog | 9 +++++++++
- bfd/elf.c     | 2 ++
- 2 files changed, 11 insertions(+)
-
-Index: git/bfd/elf.c
-===================================================================
---- git.orig/bfd/elf.c
-+++ git/bfd/elf.c
-@@ -11020,6 +11020,8 @@ elf_parse_notes (bfd *abfd, char *buf, s
-      align is less than 4, we use 4 byte alignment.   */
-   if (align < 4)
-     align = 4;
-+  if (align != 4 && align != 8)
-+    return FALSE;
- 
-   p = buf;
-   while (p < buf + size)
-Index: git/bfd/ChangeLog
-===================================================================
---- git.orig/bfd/ChangeLog
-+++ git/bfd/ChangeLog
-@@ -1,3 +1,12 @@
-+2018-02-09  Nick Clifton  <nickc@redhat.com>
-+
-+       Import patch from mainline:
-+       2018-02-08  Nick Clifton  <nickc@redhat.com>
-+
-+       PR 22788
-+       * elf.c (elf_parse_notes): Reject notes with excessuively large
-+       alignments.
-+
- 2018-03-01  Nick Clifton  <nickc@redhat.com>
- 
-        PR 22905
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-7208.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-7208.patch
deleted file mode 100644
index 8efefeb..0000000
--- a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-7208.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From eb77f6a4621795367a39cdd30957903af9dbb815 Mon Sep 17 00:00:00 2001
-From: Alan Modra <amodra@gmail.com>
-Date: Sat, 27 Jan 2018 08:19:33 +1030
-Subject: [PATCH] PR22741, objcopy segfault on fuzzed COFF object
-
-	PR 22741
-	* coffgen.c (coff_pointerize_aux): Ensure auxent tagndx is in
-	range before converting to a symbol table pointer.
-
-Upstream-Status: Backport
-Affects: Binutils <= 2.30
-CVE:  CVE-2018-7208
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- bfd/ChangeLog | 6 ++++++
- bfd/coffgen.c | 3 ++-
- 2 files changed, 8 insertions(+), 1 deletion(-)
-
-Index: git/bfd/coffgen.c
-===================================================================
---- git.orig/bfd/coffgen.c
-+++ git/bfd/coffgen.c
-@@ -1555,7 +1555,8 @@ coff_pointerize_aux (bfd *abfd,
-     }
-   /* A negative tagndx is meaningless, but the SCO 3.2v4 cc can
-      generate one, so we must be careful to ignore it.  */
--  if (auxent->u.auxent.x_sym.x_tagndx.l > 0)
-+  if ((unsigned long) auxent->u.auxent.x_sym.x_tagndx.l
-+      < obj_raw_syment_count (abfd))
-     {
-       auxent->u.auxent.x_sym.x_tagndx.p =
- 	table_base + auxent->u.auxent.x_sym.x_tagndx.l;
-Index: git/bfd/ChangeLog
-===================================================================
---- git.orig/bfd/ChangeLog
-+++ git/bfd/ChangeLog
-@@ -1,3 +1,9 @@
-+2018-01-29  Alan Modra  <amodra@gmail.com>
-+
-+       PR 22741
-+       * coffgen.c (coff_pointerize_aux): Ensure auxent tagndx is in
-+       range before converting to a symbol table pointer.
-+
- 2018-02-28  Alan Modra  <amodra@gmail.com>
- 
-        PR 22887
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-7568.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-7568.patch
deleted file mode 100644
index 815b32c..0000000
--- a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-7568.patch
+++ /dev/null
@@ -1,85 +0,0 @@
-From eef104664efb52965d85a28bc3fc7c77e52e48e2 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Wed, 28 Feb 2018 10:13:54 +0000
-Subject: [PATCH] Fix potential integer overflow when reading corrupt dwarf1
- debug information.
-
-	PR 22894
-	* dwarf1.c (parse_die): Check the length of form blocks before
-	advancing the data pointer.
-
-Upstream-Status: Backport
-Affects: Binutils <= 2.30
-CVE: CVE-2018-7568
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- bfd/ChangeLog |  6 ++++++
- bfd/dwarf1.c  | 17 +++++++++++++++--
- 2 files changed, 21 insertions(+), 2 deletions(-)
-
-Index: git/bfd/dwarf1.c
-===================================================================
---- git.orig/bfd/dwarf1.c
-+++ git/bfd/dwarf1.c
-@@ -213,6 +213,7 @@ parse_die (bfd *	     abfd,
-   /* Then the attributes.  */
-   while (xptr + 2 <= aDiePtrEnd)
-     {
-+      unsigned int   block_len;
-       unsigned short attr;
- 
-       /* Parse the attribute based on its form.  This section
-@@ -255,12 +256,24 @@ parse_die (bfd *	     abfd,
- 	  break;
- 	case FORM_BLOCK2:
- 	  if (xptr + 2 <= aDiePtrEnd)
--	    xptr += bfd_get_16 (abfd, xptr);
-+	    {
-+	      block_len = bfd_get_16 (abfd, xptr);
-+	      if (xptr + block_len > aDiePtrEnd
-+		  || xptr + block_len < xptr)
-+		return FALSE;
-+	      xptr += block_len;
-+	    }
- 	  xptr += 2;
- 	  break;
- 	case FORM_BLOCK4:
- 	  if (xptr + 4 <= aDiePtrEnd)
--	    xptr += bfd_get_32 (abfd, xptr);
-+	    {
-+	      block_len = bfd_get_32 (abfd, xptr);
-+	      if (xptr + block_len > aDiePtrEnd
-+		  || xptr + block_len < xptr)
-+		return FALSE;
-+	      xptr += block_len;
-+	    }
- 	  xptr += 4;
- 	  break;
- 	case FORM_STRING:
-Index: git/bfd/ChangeLog
-===================================================================
---- git.orig/bfd/ChangeLog
-+++ git/bfd/ChangeLog
-@@ -4,7 +4,11 @@
-        * coffgen.c (coff_pointerize_aux): Ensure auxent tagndx is in
-        range before converting to a symbol table pointer.
- 
--2018-02-28  Alan Modra  <amodra@gmail.com>
-+2018-02-28  Nick Clifton  <nickc@redhat.com>
-+
-+       PR 22894
-+       * dwarf1.c (parse_die): Check the length of form blocks before
-+       advancing the data pointer.
- 
-        PR 22895
-        PR 22893
-@@ -14,6 +18,8 @@
-        size is invalid.
-        (read_attribute_value): Adjust invocations of read_n_bytes.
- 
-+2018-02-28  Alan Modra  <amodra@gmail.com>
-+
-        PR 22887
-        * aoutx.h (swap_std_reloc_in): Correct r_index bound check.
- 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-7569.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-7569.patch
deleted file mode 100644
index 96c0fd2..0000000
--- a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-7569.patch
+++ /dev/null
@@ -1,119 +0,0 @@
-From 12c963421d045a127c413a0722062b9932c50aa9 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Wed, 28 Feb 2018 11:50:49 +0000
-Subject: [PATCH] Catch integer overflows/underflows when parsing corrupt DWARF
- FORM blocks.
-
-	PR 22895
-	PR 22893
-	* dwarf2.c (read_n_bytes): Replace size parameter with dwarf_block
-	pointer.  Drop unused abfd parameter.  Check the size of the block
-	before initialising the data field.  Return the end pointer if the
-	size is invalid.
-	(read_attribute_value): Adjust invocations of read_n_bytes.
-
-Upstream-Status: Backport
-Affects: Binutils <= 2.30
-CVE: CVE-2018-7569
-Signed-off-by: Armin Kuster <akuster@mvista.com>
----
- bfd/ChangeLog |  8 ++++++++
- bfd/dwarf2.c  | 36 +++++++++++++++++++++---------------
- 2 files changed, 29 insertions(+), 15 deletions(-)
-
-Index: git/bfd/dwarf2.c
-===================================================================
---- git.orig/bfd/dwarf2.c
-+++ git/bfd/dwarf2.c
-@@ -622,14 +622,24 @@ read_8_bytes (bfd *abfd, bfd_byte *buf,
- }
- 
- static bfd_byte *
--read_n_bytes (bfd *abfd ATTRIBUTE_UNUSED,
--	      bfd_byte *buf,
--	      bfd_byte *end,
--	      unsigned int size ATTRIBUTE_UNUSED)
--{
--  if (buf + size > end)
--    return NULL;
--  return buf;
-+read_n_bytes (bfd_byte *           buf,
-+	      bfd_byte *           end,
-+	      struct dwarf_block * block)
-+{
-+  unsigned int  size = block->size;
-+  bfd_byte *    block_end = buf + size;
-+
-+  if (block_end > end || block_end < buf)
-+    {
-+      block->data = NULL;
-+      block->size = 0;
-+      return end;
-+    }
-+  else
-+    {
-+      block->data = buf;
-+      return block_end;
-+    }
- }
- 
- /* Scans a NUL terminated string starting at BUF, returning a pointer to it.
-@@ -1127,8 +1137,7 @@ read_attribute_value (struct attribute *
- 	return NULL;
-       blk->size = read_2_bytes (abfd, info_ptr, info_ptr_end);
-       info_ptr += 2;
--      blk->data = read_n_bytes (abfd, info_ptr, info_ptr_end, blk->size);
--      info_ptr += blk->size;
-+      info_ptr = read_n_bytes (info_ptr, info_ptr_end, blk);
-       attr->u.blk = blk;
-       break;
-     case DW_FORM_block4:
-@@ -1138,8 +1147,7 @@ read_attribute_value (struct attribute *
- 	return NULL;
-       blk->size = read_4_bytes (abfd, info_ptr, info_ptr_end);
-       info_ptr += 4;
--      blk->data = read_n_bytes (abfd, info_ptr, info_ptr_end, blk->size);
--      info_ptr += blk->size;
-+      info_ptr = read_n_bytes (info_ptr, info_ptr_end, blk);
-       attr->u.blk = blk;
-       break;
-     case DW_FORM_data2:
-@@ -1179,8 +1187,7 @@ read_attribute_value (struct attribute *
-       blk->size = _bfd_safe_read_leb128 (abfd, info_ptr, &bytes_read,
- 					 FALSE, info_ptr_end);
-       info_ptr += bytes_read;
--      blk->data = read_n_bytes (abfd, info_ptr, info_ptr_end, blk->size);
--      info_ptr += blk->size;
-+      info_ptr = read_n_bytes (info_ptr, info_ptr_end, blk);
-       attr->u.blk = blk;
-       break;
-     case DW_FORM_block1:
-@@ -1190,8 +1197,7 @@ read_attribute_value (struct attribute *
- 	return NULL;
-       blk->size = read_1_byte (abfd, info_ptr, info_ptr_end);
-       info_ptr += 1;
--      blk->data = read_n_bytes (abfd, info_ptr, info_ptr_end, blk->size);
--      info_ptr += blk->size;
-+      info_ptr = read_n_bytes (info_ptr, info_ptr_end, blk);
-       attr->u.blk = blk;
-       break;
-     case DW_FORM_data1:
-Index: git/bfd/ChangeLog
-===================================================================
---- git.orig/bfd/ChangeLog
-+++ git/bfd/ChangeLog
-@@ -6,6 +6,14 @@
- 
- 2018-02-28  Alan Modra  <amodra@gmail.com>
- 
-+       PR 22895
-+       PR 22893
-+       * dwarf2.c (read_n_bytes): Replace size parameter with dwarf_block
-+       pointer.  Drop unused abfd parameter.  Check the size of the block
-+       before initialising the data field.  Return the end pointer if the
-+       size is invalid.
-+       (read_attribute_value): Adjust invocations of read_n_bytes.
-+
-        PR 22887
-        * aoutx.h (swap_std_reloc_in): Correct r_index bound check.
- 
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-7642.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-7642.patch
deleted file mode 100644
index 9def46c..0000000
--- a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-7642.patch
+++ /dev/null
@@ -1,51 +0,0 @@
-From 116acb2c268c89c89186673a7c92620d21825b25 Mon Sep 17 00:00:00 2001
-From: Alan Modra <amodra@gmail.com>
-Date: Wed, 28 Feb 2018 22:09:50 +1030
-Subject: [PATCH] PR22887, null pointer dereference in
- aout_32_swap_std_reloc_out
-
-	PR 22887
-	* aoutx.h (swap_std_reloc_in): Correct r_index bound check.
-
-Upstream-Status: Backport
-Affects: Binutils <= 2.30
-CVE: CVE-2018-7642
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- bfd/ChangeLog | 5 +++++
- bfd/aoutx.h   | 6 ++++--
- 2 files changed, 9 insertions(+), 2 deletions(-)
-
-Index: git/bfd/aoutx.h
-===================================================================
---- git.orig/bfd/aoutx.h
-+++ git/bfd/aoutx.h
-@@ -2284,10 +2284,12 @@ NAME (aout, swap_std_reloc_in) (bfd *abf
-   if (r_baserel)
-     r_extern = 1;
- 
--  if (r_extern && r_index > symcount)
-+  if (r_extern && r_index >= symcount)
-     {
-       /* We could arrange to return an error, but it might be useful
--	 to see the file even if it is bad.  */
-+	 to see the file even if it is bad.  FIXME: Of course this
-+	 means that objdump -r *doesn't* see the actual reloc, and
-+	 objcopy silently writes a different reloc.  */
-       r_extern = 0;
-       r_index = N_ABS;
-     }
-Index: git/bfd/ChangeLog
-===================================================================
---- git.orig/bfd/ChangeLog
-+++ git/bfd/ChangeLog
-@@ -1,3 +1,8 @@
-+2018-02-28  Alan Modra  <amodra@gmail.com>
-+
-+       PR 22887
-+       * aoutx.h (swap_std_reloc_in): Correct r_index bound check.
-+
- 2018-02-06  Nick Clifton  <nickc@redhat.com>
- 
-        PR 22794
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-7643.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-7643.patch
deleted file mode 100644
index 2a2dec3..0000000
--- a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-7643.patch
+++ /dev/null
@@ -1,102 +0,0 @@
-From d11ae95ea3403559f052903ab053f43ad7821e37 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Thu, 1 Mar 2018 16:14:08 +0000
-Subject: [PATCH] Prevent illegal memory accesses triggerd by intger overflow
- when parsing corrupt DWARF information on a 32-bit host.
-
-	PR 22905
-	* dwarf.c (display_debug_ranges): Check that the offset loaded
-	from the range_entry structure is valid.
-
-Upstream-Status: Backport
-Affects: Binutils <= 2.30
-CVE: CVE-2018-7643
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- binutils/ChangeLog |  6 ++++++
- binutils/dwarf.c   | 15 +++++++++++++++
- 2 files changed, 21 insertions(+)
-
-Index: git/binutils/dwarf.c
-===================================================================
---- git.orig/binutils/dwarf.c
-+++ git/binutils/dwarf.c
-@@ -387,6 +387,9 @@ read_uleb128 (unsigned char * data,
-     }								\
-   while (0)
- 
-+/* Read AMOUNT bytes from PTR and store them in VAL as an unsigned value.
-+   Checks to make sure that the read will not reach or pass END
-+   and that VAL is big enough to hold AMOUNT bytes.  */
- #define SAFE_BYTE_GET(VAL, PTR, AMOUNT, END)	\
-   do						\
-     {						\
-@@ -415,6 +418,7 @@ read_uleb128 (unsigned char * data,
-     }						\
-   while (0)
- 
-+/* Like SAFE_BYTE_GET, but also increments PTR by AMOUNT.  */
- #define SAFE_BYTE_GET_AND_INC(VAL, PTR, AMOUNT, END)	\
-   do							\
-     {							\
-@@ -423,6 +427,7 @@ read_uleb128 (unsigned char * data,
-     }							\
-   while (0)
- 
-+/* Like SAFE_BYTE_GET, but reads a signed value.  */
- #define SAFE_SIGNED_BYTE_GET(VAL, PTR, AMOUNT, END)	\
-   do							\
-     {							\
-@@ -441,6 +446,7 @@ read_uleb128 (unsigned char * data,
-     }							\
-   while (0)
- 
-+/* Like SAFE_SIGNED_BYTE_GET, but also increments PTR by AMOUNT.  */
- #define SAFE_SIGNED_BYTE_GET_AND_INC(VAL, PTR, AMOUNT, END)	\
-   do								\
-     {								\
-@@ -6543,6 +6549,7 @@ display_debug_ranges_list (unsigned char
- 	break;
-       SAFE_SIGNED_BYTE_GET_AND_INC (end, start, pointer_size, finish);
- 
-+      
-       printf ("    %8.8lx ", offset);
- 
-       if (begin == 0 && end == 0)
-@@ -6810,6 +6817,13 @@ display_debug_ranges (struct dwarf_secti
- 	  continue;
- 	}
- 
-+      if (next < section_begin || next >= finish)
-+	{
-+	  warn (_("Corrupt offset (%#8.8lx) in range entry %u\n"),
-+		(unsigned long) offset, i);
-+	  continue;
-+	}
-+
-       if (dwarf_check != 0 && i > 0)
- 	{
- 	  if (start < next)
-@@ -6825,6 +6839,7 @@ display_debug_ranges (struct dwarf_secti
- 		    (unsigned long) (next - section_begin), section->name);
- 	    }
- 	}
-+
-       start = next;
-       last_start = next;
- 
-Index: git/bfd/ChangeLog
-===================================================================
---- git.orig/bfd/ChangeLog
-+++ git/bfd/ChangeLog
-@@ -1,3 +1,9 @@
-+2018-03-01  Nick Clifton  <nickc@redhat.com>
-+
-+       PR 22905
-+       * dwarf.c (display_debug_ranges): Check that the offset loaded
-+       from the range_entry structure is valid.
-+
- 2018-05-08  Nick Clifton  <nickc@redhat.com>
- 
-        PR 22809
diff --git a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-8945.patch b/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-8945.patch
deleted file mode 100644
index 6a43168..0000000
--- a/poky/meta/recipes-devtools/binutils/binutils/CVE-2018-8945.patch
+++ /dev/null
@@ -1,70 +0,0 @@
-From 95a6d23566165208853a68d9cd3c6eedca840ec6 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Tue, 8 May 2018 12:51:06 +0100
-Subject: [PATCH] Prevent a memory exhaustion failure when running objdump on a
- fuzzed input file with corrupt string and attribute sections.
-
-	PR 22809
-	* elf.c (bfd_elf_get_str_section): Check for an excessively large
-	string section.
-	* elf-attrs.c (_bfd_elf_parse_attributes): Issue an error if the
-	attribute section is larger than the size of the file.
-
-Upsteram-Status: Backport
-Affects: Binutils <= 2.30
-CVE: CVE-2018-8945
-Signed-off-by: Armin kuster <akuster@mvista.com>
----
- bfd/ChangeLog   | 8 ++++++++
- bfd/elf-attrs.c | 9 +++++++++
- bfd/elf.c       | 1 +
- 3 files changed, 18 insertions(+)
-
-Index: git/bfd/elf-attrs.c
-===================================================================
---- git.orig/bfd/elf-attrs.c
-+++ git/bfd/elf-attrs.c
-@@ -438,6 +438,15 @@ _bfd_elf_parse_attributes (bfd *abfd, El
-   /* PR 17512: file: 2844a11d.  */
-   if (hdr->sh_size == 0)
-     return;
-+  if (hdr->sh_size > bfd_get_file_size (abfd))
-+    {
-+      /* xgettext:c-format */
-+      _bfd_error_handler (_("%pB: error: attribute section '%pA' too big: %#llx"),
-+			  abfd, hdr->bfd_section, (long long) hdr->sh_size);
-+      bfd_set_error (bfd_error_invalid_operation);
-+      return;
-+    }
-+
-   contents = (bfd_byte *) bfd_malloc (hdr->sh_size + 1);
-   if (!contents)
-     return;
-Index: git/bfd/elf.c
-===================================================================
---- git.orig/bfd/elf.c
-+++ git/bfd/elf.c
-@@ -298,6 +298,7 @@ bfd_elf_get_str_section (bfd *abfd, unsi
-       /* Allocate and clear an extra byte at the end, to prevent crashes
- 	 in case the string table is not terminated.  */
-       if (shstrtabsize + 1 <= 1
-+	  || shstrtabsize > bfd_get_file_size (abfd)
- 	  || bfd_seek (abfd, offset, SEEK_SET) != 0
- 	  || (shstrtab = (bfd_byte *) bfd_alloc (abfd, shstrtabsize + 1)) == NULL)
- 	shstrtab = NULL;
-Index: git/bfd/ChangeLog
-===================================================================
---- git.orig/bfd/ChangeLog
-+++ git/bfd/ChangeLog
-@@ -1,3 +1,11 @@
-+2018-05-08  Nick Clifton  <nickc@redhat.com>
-+
-+       PR 22809
-+       * elf.c (bfd_elf_get_str_section): Check for an excessively large
-+       string section.
-+       * elf-attrs.c (_bfd_elf_parse_attributes): Issue an error if the
-+       attribute section is larger than the size of the file.
-+
- 2018-02-07  Alan Modra  <amodra@gmail.com>
- 
- 	Revert 2018-01-17  Alan Modra  <amodra@gmail.com>
diff --git a/poky/meta/recipes-devtools/binutils/binutils_2.30.bb b/poky/meta/recipes-devtools/binutils/binutils_2.31.bb
similarity index 100%
rename from poky/meta/recipes-devtools/binutils/binutils_2.30.bb
rename to poky/meta/recipes-devtools/binutils/binutils_2.31.bb
diff --git a/poky/meta/recipes-devtools/bison/bison_3.0.4.bb b/poky/meta/recipes-devtools/bison/bison_3.0.4.bb
index cc155f0..f1b05da 100644
--- a/poky/meta/recipes-devtools/bison/bison_3.0.4.bb
+++ b/poky/meta/recipes-devtools/bison/bison_3.0.4.bb
@@ -36,4 +36,8 @@
 	create_wrapper ${D}/${bindir}/bison \
 		BISON_PKGDATADIR=${STAGING_DATADIR_NATIVE}/bison
 }
+do_install_append_class-nativesdk() {
+	create_wrapper ${D}/${bindir}/bison \
+		BISON_PKGDATADIR=${datadir}/bison
+}
 BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-devtools/bootchart2/bootchart2/0001-Fixed-Missing-default-value-for-BOOTLOG_DEST.patch b/poky/meta/recipes-devtools/bootchart2/bootchart2/0001-Fixed-Missing-default-value-for-BOOTLOG_DEST.patch
deleted file mode 100644
index 118814a..0000000
--- a/poky/meta/recipes-devtools/bootchart2/bootchart2/0001-Fixed-Missing-default-value-for-BOOTLOG_DEST.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 2225ab2038bfe50f16f972e39d89bcd0bd7767f5 Mon Sep 17 00:00:00 2001
-From: Steffen Pankratz <kratz00@gmx.de>
-Date: Tue, 9 Feb 2016 13:49:42 +0100
-Subject: [PATCH] Fixed: Missing default value for BOOTLOG_DEST
-
-Upstream-Status: Backport
-
-BUILDLOG_DEST seems to be a typo or mix-up which was introduced with 281d1df80884bf2969c509ec60ee8a6593524fe8
-
-Signed-off-by: Peter Liu <peter.x.liu@external.atlascopco.com>
----
- bootchartd.in | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/bootchartd.in b/bootchartd.in
-index f58ab9e..30af677 100755
---- a/bootchartd.in
-+++ b/bootchartd.in
-@@ -37,7 +37,7 @@ PATH="/sbin:/bin:/usr/sbin:/usr/bin:$PATH"
- 
- # Defaults, in case we can't find our configuration
- SAMPLE_HZ=50
--BUILDLOG_DEST=/var/log/bootchart.tgz
-+BOOTLOG_DEST=/var/log/bootchart.tgz
- AUTO_RENDER="no"
- AUTO_RENDER_DIR="/var/log"
- AUTO_RENDER_FORMAT="png"
--- 
-1.9.1
-
diff --git a/poky/meta/recipes-devtools/bootchart2/bootchart2_0.14.8.bb b/poky/meta/recipes-devtools/bootchart2/bootchart2_0.14.8.bb
index b3c889b..396d0ec 100644
--- a/poky/meta/recipes-devtools/bootchart2/bootchart2_0.14.8.bb
+++ b/poky/meta/recipes-devtools/bootchart2/bootchart2_0.14.8.bb
@@ -92,12 +92,12 @@
 
 SRC_URI = "git://github.com/xrmx/bootchart.git \
            file://bootchartd_stop.sh \
-           file://0001-Fixed-Missing-default-value-for-BOOTLOG_DEST.patch \
            file://0001-collector-Allocate-space-on-heap-for-chunks.patch \
           "
 
 S = "${WORKDIR}/git"
-SRCREV = "48e0071048564c6af75ab969e842d6dec808da09"
+SRCREV = "331ada031f1d65f6d934d918f896e1c708c64bf7"
+PV .= "+git${SRCPV}"
 
 inherit systemd update-rc.d python3native update-alternatives
 
diff --git a/poky/meta/recipes-devtools/btrfs-tools/btrfs-tools/0001-Add-LDFLAGS-when-building-libbtrfsutil.so.patch b/poky/meta/recipes-devtools/btrfs-tools/btrfs-tools/0001-Add-LDFLAGS-when-building-libbtrfsutil.so.patch
new file mode 100644
index 0000000..a8fcfc0
--- /dev/null
+++ b/poky/meta/recipes-devtools/btrfs-tools/btrfs-tools/0001-Add-LDFLAGS-when-building-libbtrfsutil.so.patch
@@ -0,0 +1,35 @@
+From eecc48ecad359cd4fab650ce49cfe57e99d1859d Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Thu, 17 May 2018 12:21:31 +0300
+Subject: [PATCH] Add LDFLAGS when building libbtrfsutil.so and python
+ bindings.
+
+Upstream-Status: Pending
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+---
+ Makefile | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index 10f0e3b0..1697794c 100644
+--- a/Makefile
++++ b/Makefile
+@@ -402,7 +402,7 @@ libbtrfsutil/%.o: libbtrfsutil/%.c
+ 
+ libbtrfsutil.so.$(libbtrfsutil_version): $(libbtrfsutil_objects)
+ 	@echo "    [LD]     $@"
+-	$(Q)$(CC) $(LIBBTRFSUTIL_CFLAGS) $(libbtrfsutil_objects) \
++	$(Q)$(CC) $(LIBBTRFSUTIL_CFLAGS) $(LDFLAGS) $(libbtrfsutil_objects) \
+ 		-shared -Wl,-soname,libbtrfsutil.so.$(libbtrfsutil_major) -o $@
+ 
+ libbtrfsutil.a: $(libbtrfsutil_objects)
+@@ -417,7 +417,7 @@ ifeq ($(PYTHON_BINDINGS),1)
+ libbtrfsutil_python: libbtrfsutil.so.$(libbtrfsutil_major) libbtrfsutil.so libbtrfsutil/btrfsutil.h
+ 	@echo "    [PY]     libbtrfsutil"
+ 	$(Q)cd libbtrfsutil/python; \
+-		CFLAGS= LDFLAGS= $(PYTHON) setup.py $(SETUP_PY_Q) build_ext -i build
++		CFLAGS= $(PYTHON) setup.py $(SETUP_PY_Q) build_ext -i build
+ 
+ .PHONY: libbtrfsutil_python
+ endif
diff --git a/poky/meta/recipes-devtools/btrfs-tools/btrfs-tools/0001-Add-a-possibility-to-specify-where-python-modules-ar.patch b/poky/meta/recipes-devtools/btrfs-tools/btrfs-tools/0001-Add-a-possibility-to-specify-where-python-modules-ar.patch
new file mode 100644
index 0000000..5846f04
--- /dev/null
+++ b/poky/meta/recipes-devtools/btrfs-tools/btrfs-tools/0001-Add-a-possibility-to-specify-where-python-modules-ar.patch
@@ -0,0 +1,25 @@
+From d3adfc21c9cc264bd191722f102963cbc4794259 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Wed, 23 May 2018 21:20:35 +0300
+Subject: [PATCH] Add a possibility to specify where python modules are
+ installed
+
+Upstream-Status: Inappropriate [oe-core specific to solve multilib use case]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/Makefile b/Makefile
+index 1697794c..8ab38818 100644
+--- a/Makefile
++++ b/Makefile
+@@ -651,7 +651,7 @@ endif
+ ifeq ($(PYTHON_BINDINGS),1)
+ install_python: libbtrfsutil_python
+ 	$(Q)cd libbtrfsutil/python; \
+-		$(PYTHON) setup.py install --skip-build $(if $(DESTDIR),--root $(DESTDIR)) --prefix $(prefix)
++		$(PYTHON) setup.py install --skip-build $(if $(DESTDIR),--root $(DESTDIR)) --prefix $(prefix) --install-lib=$(PYTHON_SITEPACKAGES_DIR)
+ 
+ .PHONY: install_python
+ endif
diff --git a/poky/meta/recipes-devtools/btrfs-tools/btrfs-tools/0001-Fix-build-with-musl-missing-header-include-for-dev_t.patch b/poky/meta/recipes-devtools/btrfs-tools/btrfs-tools/0001-Fix-build-with-musl-missing-header-include-for-dev_t.patch
deleted file mode 100644
index 790676b..0000000
--- a/poky/meta/recipes-devtools/btrfs-tools/btrfs-tools/0001-Fix-build-with-musl-missing-header-include-for-dev_t.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-From bc35c4caebb57cc8b96c30c25432b12ca8dc18d5 Mon Sep 17 00:00:00 2001
-From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Fri, 6 Oct 2017 15:03:49 +0300
-Subject: [PATCH] Fix build with musl (missing header include for dev_t).
-
-Upstream-Status: Pending
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
----
- convert/source-fs.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/convert/source-fs.h b/convert/source-fs.h
-index 23f3356..6fd770f 100644
---- a/convert/source-fs.h
-+++ b/convert/source-fs.h
-@@ -20,6 +20,7 @@
- #include "kerncompat.h"
- #include <linux/kdev_t.h>
- #include <pthread.h>
-+#include <sys/types.h>
- 
- #define CONV_IMAGE_SUBVOL_OBJECTID BTRFS_FIRST_FREE_OBJECTID
- 
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-devtools/btrfs-tools/btrfs-tools_4.13.3.bb b/poky/meta/recipes-devtools/btrfs-tools/btrfs-tools_4.13.3.bb
deleted file mode 100644
index bc157e2..0000000
--- a/poky/meta/recipes-devtools/btrfs-tools/btrfs-tools_4.13.3.bb
+++ /dev/null
@@ -1,39 +0,0 @@
-SUMMARY = "Checksumming Copy on Write Filesystem utilities"
-DESCRIPTION = "Btrfs is a new copy on write filesystem for Linux aimed at \
-implementing advanced features while focusing on fault tolerance, repair and \
-easy administration. \
-This package contains utilities (mkfs, fsck, btrfsctl) used to work with \
-btrfs and an utility (btrfs-convert) to make a btrfs filesystem from an ext3."
-
-HOMEPAGE = "https://btrfs.wiki.kernel.org"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=fcb02dc552a041dee27e4b85c7396067"
-SECTION = "base"
-DEPENDS = "util-linux attr e2fsprogs lzo acl"
-DEPENDS_append_class-target = " udev"
-RDEPENDS_${PN} = "libgcc"
-
-SRCREV = "a7a1ea0f4f2a1d6eeeb3d106e062c7f1034f16d4"
-SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/kdave/btrfs-progs.git \
-           file://0001-Makefile-build-mktables-using-native-gcc.patch \
-           file://0001-Fix-build-with-musl-missing-header-include-for-dev_t.patch \
-           "
-
-RECIPE_NO_UPDATE_REASON = "Waiting for resolution of https://github.com/kdave/btrfs-progs/issues/109"
-inherit autotools-brokensep pkgconfig manpages
-
-CLEANBROKEN = "1"
-
-PACKAGECONFIG[manpages] = "--enable-documentation, --disable-documentation, asciidoc-native xmlto-native"
-EXTRA_OECONF_append_libc-musl = " --disable-backtrace "
-
-do_configure_prepend() {
-	# Upstream doesn't ship this and autoreconf won't install it as automake isn't used.
-	mkdir -p ${S}/config
-	cp -f $(automake --print-libdir)/install-sh ${S}/config/
-}
-
-S = "${WORKDIR}/git"
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-devtools/btrfs-tools/btrfs-tools_4.17.1.bb b/poky/meta/recipes-devtools/btrfs-tools/btrfs-tools_4.17.1.bb
new file mode 100644
index 0000000..6b53fbc
--- /dev/null
+++ b/poky/meta/recipes-devtools/btrfs-tools/btrfs-tools_4.17.1.bb
@@ -0,0 +1,44 @@
+SUMMARY = "Checksumming Copy on Write Filesystem utilities"
+DESCRIPTION = "Btrfs is a new copy on write filesystem for Linux aimed at \
+implementing advanced features while focusing on fault tolerance, repair and \
+easy administration. \
+This package contains utilities (mkfs, fsck, btrfsctl) used to work with \
+btrfs and an utility (btrfs-convert) to make a btrfs filesystem from an ext3."
+
+HOMEPAGE = "https://btrfs.wiki.kernel.org"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=fcb02dc552a041dee27e4b85c7396067"
+SECTION = "base"
+DEPENDS = "util-linux attr e2fsprogs lzo acl python3-setuptools-native"
+DEPENDS_append_class-target = " udev"
+RDEPENDS_${PN} = "libgcc"
+
+SRCREV = "7faaca0d9f78f7162ae603231f693dd8e1af2a41"
+SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/kdave/btrfs-progs.git \
+           file://0001-Makefile-build-mktables-using-native-gcc.patch \
+           file://0001-Add-LDFLAGS-when-building-libbtrfsutil.so.patch \
+           file://0001-Add-a-possibility-to-specify-where-python-modules-ar.patch \
+           "
+
+inherit autotools-brokensep pkgconfig manpages distutils3-base
+
+CLEANBROKEN = "1"
+
+PACKAGECONFIG[manpages] = "--enable-documentation, --disable-documentation, asciidoc-native xmlto-native"
+EXTRA_OECONF = " --disable-zstd"
+EXTRA_OECONF_append_libc-musl = " --disable-backtrace "
+
+do_configure_prepend() {
+	# Upstream doesn't ship this and autoreconf won't install it as automake isn't used.
+	mkdir -p ${S}/config
+	cp -f $(automake --print-libdir)/install-sh ${S}/config/
+}
+
+S = "${WORKDIR}/git"
+
+do_install_append() {
+    oe_runmake 'DESTDIR=${D}' 'PYTHON_SITEPACKAGES_DIR=${PYTHON_SITEPACKAGES_DIR}' install_python
+}
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-devtools/ccache/ccache_3.3.5.bb b/poky/meta/recipes-devtools/ccache/ccache_3.3.5.bb
deleted file mode 100644
index 929f0f1..0000000
--- a/poky/meta/recipes-devtools/ccache/ccache_3.3.5.bb
+++ /dev/null
@@ -1,12 +0,0 @@
-require ccache.inc
-
-LICENSE = "GPLv3+"
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=dae379a85bb6e9d594773e0aa64876f6"
-
-SRC_URI[md5sum] = "eee58db7cce892febddb989308dc568f"
-SRC_URI[sha256sum] = "190576a6e938760ec8113523e6fd380141117303e90766cc4802e770422b30c6"
-
-SRC_URI += " \
-            file://0002-dev.mk.in-fix-file-name-too-long.patch \
-            file://Revert-Create-man-page-in-the-make-install-from-git-.patch \
-"
diff --git a/poky/meta/recipes-devtools/ccache/ccache_3.4.2.bb b/poky/meta/recipes-devtools/ccache/ccache_3.4.2.bb
new file mode 100644
index 0000000..7230934
--- /dev/null
+++ b/poky/meta/recipes-devtools/ccache/ccache_3.4.2.bb
@@ -0,0 +1,11 @@
+require ccache.inc
+
+LICENSE = "GPLv3+"
+LIC_FILES_CHKSUM = "file://LICENSE.adoc;md5=2722abeaf1750dbf175b9491112374e1"
+
+SRC_URI[md5sum] = "9e048f88f3897125864f9a5e1abfb72d"
+SRC_URI[sha256sum] = "18a8b14367d63d3d37fb6c33cba60e1b7fcd7a63d608df97c9771ae0d234fee2"
+
+SRC_URI += " \
+            file://0002-dev.mk.in-fix-file-name-too-long.patch \
+"
diff --git a/poky/meta/recipes-devtools/ccache/files/0002-dev.mk.in-fix-file-name-too-long.patch b/poky/meta/recipes-devtools/ccache/files/0002-dev.mk.in-fix-file-name-too-long.patch
index 3f01c69..68c2371 100644
--- a/poky/meta/recipes-devtools/ccache/files/0002-dev.mk.in-fix-file-name-too-long.patch
+++ b/poky/meta/recipes-devtools/ccache/files/0002-dev.mk.in-fix-file-name-too-long.patch
@@ -1,4 +1,4 @@
-From 71bd0082c6edcf73f054a8a4fa34bd8dd4de7cd7 Mon Sep 17 00:00:00 2001
+From 7dab2995ed8eeccd7b0acd79668bc28f3a2427d5 Mon Sep 17 00:00:00 2001
 From: Robert Yang <liezhi.yang@windriver.com>
 Date: Wed, 16 Sep 2015 19:45:40 -0700
 Subject: [PATCH] dev.mk.in: fix file name too long
@@ -10,14 +10,15 @@
 Upstream-Status: Pending
 
 Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+
 ---
- dev.mk.in |    2 +-
+ dev.mk.in | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-Index: ccache-3.3.4/dev.mk.in
-===================================================================
---- ccache-3.3.4.orig/dev.mk.in
-+++ ccache-3.3.4/dev.mk.in
+diff --git a/dev.mk.in b/dev.mk.in
+index 91b0a57..583ade0 100644
+--- a/dev.mk.in
++++ b/dev.mk.in
 @@ -1,7 +1,7 @@
  # GNU make syntax reigns in this file.
  
@@ -25,5 +26,5 @@
 -all_cppflags += -MD -MP -MF .deps/$(subst .._,,$(subst /,_,$<)).d
 +all_cppflags += -MD -MP -MF .deps/$(subst .._,,$(subst /,_,$(subst $(srcdir)/,,$<))).d
  
+ A2X = a2x
  ASCIIDOC = asciidoc
- CPPCHECK = cppcheck
diff --git a/poky/meta/recipes-devtools/ccache/files/Revert-Create-man-page-in-the-make-install-from-git-.patch b/poky/meta/recipes-devtools/ccache/files/Revert-Create-man-page-in-the-make-install-from-git-.patch
deleted file mode 100644
index f0208b9..0000000
--- a/poky/meta/recipes-devtools/ccache/files/Revert-Create-man-page-in-the-make-install-from-git-.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 94fabcdda5c7e54ccdbc1f0aeccb26ce30e61226 Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Mon, 18 Jul 2016 19:53:00 -0700
-Subject: [PATCH] Revert "Create man page in the make-install-from-git-repo
- case"
-
-This reverts commit b86784902d28defd5e475c8922de594787df4541.
-
-We dont' have asciidoc, so revert it.
-
-Upstream-Status: Inappropriate [OE-Core specific]
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
----
- Makefile.in | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/Makefile.in b/Makefile.in
-index d474f2a..c6cdc04 100644
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -76,7 +76,7 @@ ccache$(EXEEXT): $(ccache_objs) $(extra_libs)
- 	$(CC) $(all_cflags) -o $@ $(ccache_objs) $(LDFLAGS) $(extra_libs) $(LIBS)
- 
- .PHONY: install
--install: all $(srcdir)/ccache.1
-+install: all
- 	$(installcmd) -d $(DESTDIR)$(bindir)
- 	$(installcmd) -m 755 ccache$(EXEEXT) $(DESTDIR)$(bindir)
- 	$(installcmd) -d $(DESTDIR)$(mandir)/man1
--- 
-2.9.0
-
diff --git a/poky/meta/recipes-devtools/cmake/cmake-native_3.10.3.bb b/poky/meta/recipes-devtools/cmake/cmake-native_3.10.3.bb
deleted file mode 100644
index e55e8b1..0000000
--- a/poky/meta/recipes-devtools/cmake/cmake-native_3.10.3.bb
+++ /dev/null
@@ -1,38 +0,0 @@
-require cmake.inc
-inherit native
-
-DEPENDS += "bzip2-replacement-native expat-native xz-native zlib-native curl-native"
-
-SRC_URI += "\
-    file://cmlibarchive-disable-ext2fs.patch \
-"
-
-B = "${WORKDIR}/build"
-do_configure[cleandirs] = "${B}"
-
-# Disable ccmake since we don't depend on ncurses
-CMAKE_EXTRACONF = "\
-    -DCMAKE_LIBRARY_PATH=${STAGING_LIBDIR_NATIVE} \
-    -DBUILD_CursesDialog=0 \
-    -DCMAKE_USE_SYSTEM_LIBRARIES=1 \
-    -DCMAKE_USE_SYSTEM_LIBRARY_JSONCPP=0 \
-    -DCMAKE_USE_SYSTEM_LIBRARY_LIBARCHIVE=0 \
-    -DCMAKE_USE_SYSTEM_LIBRARY_LIBUV=0 \
-    -DCMAKE_USE_SYSTEM_LIBRARY_LIBRHASH=0 \
-    -DENABLE_ACL=0 -DHAVE_ACL_LIBACL_H=0 \
-    -DHAVE_SYS_ACL_H=0 \
-"
-
-do_configure () {
-	${S}/configure --verbose --prefix=${prefix} -- ${CMAKE_EXTRACONF}
-}
-
-do_compile() {
-	oe_runmake
-}
-
-do_install() {
-	oe_runmake 'DESTDIR=${D}' install
-}
-
-do_compile[progress] = "percent"
diff --git a/poky/meta/recipes-devtools/cmake/cmake-native_3.12.2.bb b/poky/meta/recipes-devtools/cmake/cmake-native_3.12.2.bb
new file mode 100644
index 0000000..9a1390f
--- /dev/null
+++ b/poky/meta/recipes-devtools/cmake/cmake-native_3.12.2.bb
@@ -0,0 +1,50 @@
+require cmake.inc
+inherit native
+
+DEPENDS += "bzip2-replacement-native expat-native xz-native zlib-native curl-native"
+
+SRC_URI += "file://OEToolchainConfig.cmake \
+            file://environment.d-cmake.sh \
+            file://0001-CMakeDetermineSystem-use-oe-environment-vars-to-load.patch \
+            file://0005-Disable-use-of-ext2fs-ext2_fs.h-by-cmake-s-internal-.patch \
+            "
+
+
+B = "${WORKDIR}/build"
+do_configure[cleandirs] = "${B}"
+
+# Disable ccmake since we don't depend on ncurses
+CMAKE_EXTRACONF = "\
+    -DCMAKE_LIBRARY_PATH=${STAGING_LIBDIR_NATIVE} \
+    -DBUILD_CursesDialog=0 \
+    -DCMAKE_USE_SYSTEM_LIBRARIES=1 \
+    -DCMAKE_USE_SYSTEM_LIBRARY_JSONCPP=0 \
+    -DCMAKE_USE_SYSTEM_LIBRARY_LIBARCHIVE=0 \
+    -DCMAKE_USE_SYSTEM_LIBRARY_LIBUV=0 \
+    -DCMAKE_USE_SYSTEM_LIBRARY_LIBRHASH=0 \
+    -DENABLE_ACL=0 -DHAVE_ACL_LIBACL_H=0 \
+    -DHAVE_SYS_ACL_H=0 \
+"
+
+do_configure () {
+	${S}/configure --verbose --prefix=${prefix} -- ${CMAKE_EXTRACONF}
+}
+
+do_compile() {
+	oe_runmake
+}
+
+do_install() {
+	oe_runmake 'DESTDIR=${D}' install
+
+	# The following codes are here because eSDK needs to provide compatibilty
+	# for SDK. That is, eSDK could also be used like traditional SDK.
+	mkdir -p ${D}${datadir}/cmake
+	install -m 644 ${WORKDIR}/OEToolchainConfig.cmake ${D}${datadir}/cmake/
+	mkdir -p ${D}${base_prefix}/environment-setup.d
+	install -m 644 ${WORKDIR}/environment.d-cmake.sh ${D}${base_prefix}/environment-setup.d/cmake.sh
+}
+
+do_compile[progress] = "percent"
+
+SYSROOT_DIRS_NATIVE += "${datadir}/cmake ${base_prefix}/environment-setup.d"
diff --git a/poky/meta/recipes-devtools/cmake/cmake.inc b/poky/meta/recipes-devtools/cmake/cmake.inc
index 394c9eb..09e28b7 100644
--- a/poky/meta/recipes-devtools/cmake/cmake.inc
+++ b/poky/meta/recipes-devtools/cmake/cmake.inc
@@ -6,23 +6,19 @@
 BUGTRACKER = "http://public.kitware.com/Bug/my_view_page.php"
 SECTION = "console/utils"
 LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://Copyright.txt;md5=79b5b78197c74d5c5f9c7ccadeee4e8c \
+LIC_FILES_CHKSUM = "file://Copyright.txt;md5=f61f5f859bc5ddba2b050eb10335e013 \
                     file://Source/cmake.h;md5=4494dee184212fc89c469c3acd555a14;beginline=1;endline=3 \
                     "
 
 CMAKE_MAJOR_VERSION = "${@'.'.join(d.getVar('PV').split('.')[0:2])}"
 
 SRC_URI = "https://cmake.org/files/v${CMAKE_MAJOR_VERSION}/cmake-${PV}.tar.gz \
-           file://support-oe-qt4-tools-names.patch \
-           file://qt4-fail-silent.patch \
-           file://cmake-Prevent-the-detection-of-Qt5.patch \
-           file://0001-FindBoost-Boost-1.66.0-dependency-and-release-update.patch \
-           file://0001-FindBoost-Fix-incorrect-alphabetisation-of-headers-l.patch \
-           file://0002-FindBoost-Implement-Architecture-and-Address-Model-t.patch \
-           file://0003-FindBoost-Search-for-upstream-packaged-libs-next-to-.patch \
-           "
+           file://0002-cmake-Prevent-the-detection-of-Qt5.patch \
+           file://0003-cmake-support-OpenEmbedded-Qt4-tool-binary-names.patch \
+           file://0004-Fail-silently-if-system-Qt-installation-is-broken.patch \
+"
 
-SRC_URI[md5sum] = "1c38c67295ca696aeafd8c059d748b38"
-SRC_URI[sha256sum] = "0c3a1dcf0be03e40cf4f341dda79c96ffb6c35ae35f2f911845b72dab3559cf8"
+SRC_URI[md5sum] = "6e7c550cfa1c2e216b35903dc70d80af"
+SRC_URI[sha256sum] = "0f97485799e51a7070cc11494f3e02349b0fc3a24cc12b082e737bf67a0581a4"
 
 UPSTREAM_CHECK_REGEX = "cmake-(?P<pver>\d+(\.\d+)+)\.tar"
diff --git a/poky/meta/recipes-devtools/cmake/cmake/0001-CMakeDetermineSystem-use-oe-environment-vars-to-load.patch b/poky/meta/recipes-devtools/cmake/cmake/0001-CMakeDetermineSystem-use-oe-environment-vars-to-load.patch
new file mode 100644
index 0000000..f690720
--- /dev/null
+++ b/poky/meta/recipes-devtools/cmake/cmake/0001-CMakeDetermineSystem-use-oe-environment-vars-to-load.patch
@@ -0,0 +1,47 @@
+From 71085723f8028b3e1c4029fc1abe1243ac49ffc6 Mon Sep 17 00:00:00 2001
+From: Cody P Schafer <dev@codyps.com>
+Date: Thu, 27 Apr 2017 11:35:05 -0400
+Subject: [PATCH 1/5] CMakeDetermineSystem: use oe environment vars to load
+ default toolchain file in sdk
+Organization: O.S. Systems Software LTDA.
+
+Passing the toolchain by:
+
+ - shell aliases does not work if cmake is called by a script
+ - unconditionally by a wrapper script causes cmake to believe it is
+   configuring things when it is not (for example, `cmake --build` breaks).
+
+The OE_CMAKE_TOOLCHAIN_FILE variable is only used as a default if no
+toolchain is explicitly specified.
+
+Setting the CMAKE_TOOLCHAIN_FILE cmake variable is marked as cached
+because '-D' options are cache entries themselves.
+
+Upstream-Status: Inappropriate [oe-core specific]
+Signed-off-by: Cody P Schafer <dev@codyps.com>
+Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
+---
+ Modules/CMakeDetermineSystem.cmake | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git a/Modules/CMakeDetermineSystem.cmake b/Modules/CMakeDetermineSystem.cmake
+index 600d5580e..32d7f1945 100644
+--- a/Modules/CMakeDetermineSystem.cmake
++++ b/Modules/CMakeDetermineSystem.cmake
+@@ -82,6 +82,13 @@ else()
+   endif()
+ endif()
+ 
++if(NOT DEFINED CMAKE_TOOLCHAIN_FILE)
++  if(DEFINED ENV{OE_CMAKE_TOOLCHAIN_FILE})
++    set(CMAKE_TOOLCHAIN_FILE "$ENV{OE_CMAKE_TOOLCHAIN_FILE}" CACHE FILEPATH "toolchain file")
++    message(STATUS "Toolchain file defaulted to '${CMAKE_TOOLCHAIN_FILE}'")
++  endif()
++endif()
++
+ # if a toolchain file is used, the user wants to cross compile.
+ # in this case read the toolchain file and keep the CMAKE_HOST_SYSTEM_*
+ # variables around so they can be used in CMakeLists.txt.
+-- 
+2.18.0
+
diff --git a/poky/meta/recipes-devtools/cmake/cmake/0001-FindBoost-Boost-1.66.0-dependency-and-release-update.patch b/poky/meta/recipes-devtools/cmake/cmake/0001-FindBoost-Boost-1.66.0-dependency-and-release-update.patch
deleted file mode 100644
index fda60e3..0000000
--- a/poky/meta/recipes-devtools/cmake/cmake/0001-FindBoost-Boost-1.66.0-dependency-and-release-update.patch
+++ /dev/null
@@ -1,52 +0,0 @@
-From 433a2d495a2481c63b82c11a30f7c642d6abe63f Mon Sep 17 00:00:00 2001
-From: "Paul \"TBBle\" Hampson" <Paul.Hampson@Pobox.com>
-Date: Fri, 29 Dec 2017 19:55:49 +1100
-Subject: [PATCH] FindBoost: Boost 1.66.0 dependency and release update
-
-Release notes: http://www.boost.org/users/history/version_1_66_0.html
-
-* All new libraries are header-only.
-* _Boost_COMPONENT_DEPENDENCIES is unchanged from 1.65.1
-* _Boost_FIBER_COMPILER_FEATURES is unchanged from 1.64.0
-
-Upstream-Status: Backport
-[Yocto 12762]
-Signed-off-by: Armin Kuster <akuster808@gmail.com>
-
----
- Modules/FindBoost.cmake | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
-Index: cmake-3.10.3/Modules/FindBoost.cmake
-===================================================================
---- cmake-3.10.3.orig/Modules/FindBoost.cmake
-+++ cmake-3.10.3/Modules/FindBoost.cmake
-@@ -797,7 +797,7 @@ function(_Boost_COMPONENT_DEPENDENCIES c
-       set(_Boost_WAVE_DEPENDENCIES filesystem system serialization thread chrono date_time atomic)
-       set(_Boost_WSERIALIZATION_DEPENDENCIES serialization)
-     endif()
--    if(NOT Boost_VERSION VERSION_LESS 106600)
-+    if(NOT Boost_VERSION VERSION_LESS 106700)
-       message(WARNING "New Boost version may have incorrect or missing dependencies and imported targets")
-       set(_Boost_IMPORTED_TARGETS FALSE)
-     endif()
-@@ -931,8 +931,8 @@ endfunction()
- # `${Boost_ROOT}/libs/fiber/build/Jamfile.v2`.
- #
- function(_Boost_COMPILER_FEATURES component _ret)
--  # Boost >= 1.62 and < 1.65
--  if(NOT Boost_VERSION VERSION_LESS 106200 AND Boost_VERSION VERSION_LESS 106500)
-+  # Boost >= 1.62 and < 1.67
-+  if(NOT Boost_VERSION VERSION_LESS 106200 AND Boost_VERSION VERSION_LESS 106700)
-     set(_Boost_FIBER_COMPILER_FEATURES
-         cxx_alias_templates
-         cxx_auto_type
-@@ -1038,7 +1038,7 @@ else()
-   # _Boost_COMPONENT_HEADERS.  See the instructions at the top of
-   # _Boost_COMPONENT_DEPENDENCIES.
-   set(_Boost_KNOWN_VERSIONS ${Boost_ADDITIONAL_VERSIONS}
--    "1.65.1" "1.65.0" "1.65"
-+    "1.66.0" "1.66" "1.65.1" "1.65.0" "1.65"
-     "1.64.0" "1.64" "1.63.0" "1.63" "1.62.0" "1.62" "1.61.0" "1.61" "1.60.0" "1.60"
-     "1.59.0" "1.59" "1.58.0" "1.58" "1.57.0" "1.57" "1.56.0" "1.56" "1.55.0" "1.55"
-     "1.54.0" "1.54" "1.53.0" "1.53" "1.52.0" "1.52" "1.51.0" "1.51"
diff --git a/poky/meta/recipes-devtools/cmake/cmake/0001-FindBoost-Fix-incorrect-alphabetisation-of-headers-l.patch b/poky/meta/recipes-devtools/cmake/cmake/0001-FindBoost-Fix-incorrect-alphabetisation-of-headers-l.patch
deleted file mode 100644
index a45eda5..0000000
--- a/poky/meta/recipes-devtools/cmake/cmake/0001-FindBoost-Fix-incorrect-alphabetisation-of-headers-l.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From b1e9f67137733bc109d355450fcd06edda4784c5 Mon Sep 17 00:00:00 2001
-From: "Paul \"TBBle\" Hampson" <Paul.Hampson@Pobox.com>
-Date: Fri, 29 Dec 2017 20:07:31 +1100
-Subject: [PATCH 1/6] FindBoost: Fix incorrect alphabetisation of headers list
-
-Affects cmake < 3.11.0
-
-Upsteam-Status: Backport
-[Yocto 12762]
-Signed-off-by: Armin Kuster <akuster808@gmail.com>
-
----
- Modules/FindBoost.cmake | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-Index: cmake-3.10.3/Modules/FindBoost.cmake
-===================================================================
---- cmake-3.10.3.orig/Modules/FindBoost.cmake
-+++ cmake-3.10.3/Modules/FindBoost.cmake
-@@ -831,8 +831,8 @@ function(_Boost_COMPONENT_HEADERS compon
-   set(_Boost_CONTAINER_HEADERS           "boost/container/container_fwd.hpp")
-   set(_Boost_CONTEXT_HEADERS             "boost/context/all.hpp")
-   set(_Boost_COROUTINE_HEADERS           "boost/coroutine/all.hpp")
--  set(_Boost_EXCEPTION_HEADERS           "boost/exception/exception.hpp")
-   set(_Boost_DATE_TIME_HEADERS           "boost/date_time/date.hpp")
-+  set(_Boost_EXCEPTION_HEADERS           "boost/exception/exception.hpp")
-   set(_Boost_FIBER_HEADERS               "boost/fiber/all.hpp")
-   set(_Boost_FILESYSTEM_HEADERS          "boost/filesystem/path.hpp")
-   set(_Boost_GRAPH_HEADERS               "boost/graph/adjacency_list.hpp")
diff --git a/poky/meta/recipes-devtools/cmake/cmake/0002-FindBoost-Implement-Architecture-and-Address-Model-t.patch b/poky/meta/recipes-devtools/cmake/cmake/0002-FindBoost-Implement-Architecture-and-Address-Model-t.patch
deleted file mode 100644
index 88301c6..0000000
--- a/poky/meta/recipes-devtools/cmake/cmake/0002-FindBoost-Implement-Architecture-and-Address-Model-t.patch
+++ /dev/null
@@ -1,132 +0,0 @@
-From b044f69a413123f15a05034c00a8e3763764a1e5 Mon Sep 17 00:00:00 2001
-From: "Paul \"TBBle\" Hampson" <Paul.Hampson@Pobox.com>
-Date: Fri, 29 Dec 2017 21:50:54 +1100
-Subject: [PATCH 2/6] FindBoost: Implement "Architecture and Address Model" tag
-
-This tag is new in Boost 1.66.0, and is present in the 'versioned'
-library file name layout.
-
-Affects cmake < 3.11.0
-
-Upsteam-Status: Backport
-[Yocto 12762]
-Signed-off-by: Armin Kuster <akuster808@gmail.com>
-
----
- Modules/FindBoost.cmake | 52 +++++++++++++++++++++++++++++++++++++++----------
- 1 file changed, 42 insertions(+), 10 deletions(-)
-
-Index: cmake-3.10.3/Modules/FindBoost.cmake
-===================================================================
---- cmake-3.10.3.orig/Modules/FindBoost.cmake
-+++ cmake-3.10.3/Modules/FindBoost.cmake
-@@ -1385,8 +1385,11 @@ if(Boost_DEBUG)
- endif()
- 
- #======================
--# Systematically build up the Boost ABI tag
--# http://boost.org/doc/libs/1_41_0/more/getting_started/windows.html#library-naming
-+# Systematically build up the Boost ABI tag for the 'tagged' and 'versioned' layouts
-+# http://boost.org/doc/libs/1_66_0/more/getting_started/windows.html#library-naming
-+# http://boost.org/doc/libs/1_66_0/boost/config/auto_link.hpp
-+# http://boost.org/doc/libs/1_66_0/tools/build/src/tools/common.jam
-+# http://boost.org/doc/libs/1_66_0/boostcpp.jam
- set( _boost_RELEASE_ABI_TAG "-")
- set( _boost_DEBUG_ABI_TAG   "-")
- # Key       Use this library when:
-@@ -1418,11 +1421,40 @@ if(Boost_USE_STLPORT)
-   string(APPEND _boost_DEBUG_ABI_TAG "p")
- endif()
- #  n        using the STLport deprecated "native iostreams" feature
-+#           removed from the documentation in 1.43.0 but still present in
-+#           boost/config/auto_link.hpp
- if(Boost_USE_STLPORT_DEPRECATED_NATIVE_IOSTREAMS)
-   string(APPEND _boost_RELEASE_ABI_TAG "n")
-   string(APPEND _boost_DEBUG_ABI_TAG "n")
- endif()
- 
-+#  -x86     Architecture and address model tag
-+#           First character is the architecture, then word-size, either 32 or 64
-+#           Only used in 'versioned' layout, added in Boost 1.66.0
-+set(_boost_ARCHITECTURE_TAG "")
-+# {CMAKE_CXX_COMPILER_ARCHITECTURE_ID} is not currently set for all compilers
-+if(NOT "x${CMAKE_CXX_COMPILER_ARCHITECTURE_ID}" STREQUAL "x" AND NOT Boost_VERSION VERSION_LESS 106600)
-+  string(APPEND _boost_ARCHITECTURE_TAG "-")
-+  # This needs to be kept in-sync with the section of CMakePlatformId.h.in
-+  # inside 'defined(_WIN32) && defined(_MSC_VER)'
-+  if(${CMAKE_CXX_COMPILER_ARCHITECTURE_ID} STREQUAL "IA64")
-+    string(APPEND _boost_ARCHITECTURE_TAG "i")
-+  elseif(${CMAKE_CXX_COMPILER_ARCHITECTURE_ID} STREQUAL "X86"
-+            OR ${CMAKE_CXX_COMPILER_ARCHITECTURE_ID} STREQUAL "x64")
-+    string(APPEND _boost_ARCHITECTURE_TAG "x")
-+  elseif(${CMAKE_CXX_COMPILER_ARCHITECTURE_ID} MATCHES "^ARM")
-+    string(APPEND _boost_ARCHITECTURE_TAG "a")
-+  elseif(${CMAKE_CXX_COMPILER_ARCHITECTURE_ID} STREQUAL "MIPS")
-+    string(APPEND _boost_ARCHITECTURE_TAG "m")
-+  endif()
-+
-+  if(CMAKE_SIZEOF_VOID_P EQUAL 8)
-+    string(APPEND _boost_ARCHITECTURE_TAG "64")
-+  else()
-+    string(APPEND _boost_ARCHITECTURE_TAG "32")
-+  endif()
-+endif()
-+
- if(Boost_DEBUG)
-   message(STATUS "[ ${CMAKE_CURRENT_LIST_FILE}:${CMAKE_CURRENT_LIST_LINE} ] "
-     "_boost_RELEASE_ABI_TAG = ${_boost_RELEASE_ABI_TAG}")
-@@ -1616,22 +1648,22 @@ foreach(COMPONENT ${Boost_FIND_COMPONENT
-   unset(_boost_RELEASE_NAMES)
-   foreach(compiler IN LISTS _boost_COMPILER)
-     list(APPEND _boost_RELEASE_NAMES
--      ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${compiler}${_boost_MULTITHREADED}${_boost_RELEASE_ABI_TAG}-${Boost_LIB_VERSION}
-+      ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${compiler}${_boost_MULTITHREADED}${_boost_RELEASE_ABI_TAG}${_boost_ARCHITECTURE_TAG}-${Boost_LIB_VERSION}
-       ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${compiler}${_boost_MULTITHREADED}${_boost_RELEASE_ABI_TAG} )
-   endforeach()
-   list(APPEND _boost_RELEASE_NAMES
--    ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${_boost_MULTITHREADED}${_boost_RELEASE_ABI_TAG}-${Boost_LIB_VERSION}
-+    ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${_boost_MULTITHREADED}${_boost_RELEASE_ABI_TAG}${_boost_ARCHITECTURE_TAG}-${Boost_LIB_VERSION}
-     ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${_boost_MULTITHREADED}${_boost_RELEASE_ABI_TAG}
-     ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT} )
-   if(_boost_STATIC_RUNTIME_WORKAROUND)
-     set(_boost_RELEASE_STATIC_ABI_TAG "-s${_boost_RELEASE_ABI_TAG}")
-     foreach(compiler IN LISTS _boost_COMPILER)
-       list(APPEND _boost_RELEASE_NAMES
--        ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${compiler}${_boost_MULTITHREADED}${_boost_RELEASE_STATIC_ABI_TAG}-${Boost_LIB_VERSION}
-+        ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${compiler}${_boost_MULTITHREADED}${_boost_RELEASE_STATIC_ABI_TAG}${_boost_ARCHITECTURE_TAG}-${Boost_LIB_VERSION}
-         ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${compiler}${_boost_MULTITHREADED}${_boost_RELEASE_STATIC_ABI_TAG} )
-     endforeach()
-     list(APPEND _boost_RELEASE_NAMES
--      ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${_boost_MULTITHREADED}${_boost_RELEASE_STATIC_ABI_TAG}-${Boost_LIB_VERSION}
-+      ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${_boost_MULTITHREADED}${_boost_RELEASE_STATIC_ABI_TAG}${_boost_ARCHITECTURE_TAG}-${Boost_LIB_VERSION}
-       ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${_boost_MULTITHREADED}${_boost_RELEASE_STATIC_ABI_TAG} )
-   endif()
-   if(Boost_THREADAPI AND ${COMPONENT} STREQUAL "thread")
-@@ -1666,11 +1698,11 @@ foreach(COMPONENT ${Boost_FIND_COMPONENT
-   unset(_boost_DEBUG_NAMES)
-   foreach(compiler IN LISTS _boost_COMPILER)
-     list(APPEND _boost_DEBUG_NAMES
--      ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${compiler}${_boost_MULTITHREADED}${_boost_DEBUG_ABI_TAG}-${Boost_LIB_VERSION}
-+      ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${compiler}${_boost_MULTITHREADED}${_boost_DEBUG_ABI_TAG}${_boost_ARCHITECTURE_TAG}-${Boost_LIB_VERSION}
-       ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${compiler}${_boost_MULTITHREADED}${_boost_DEBUG_ABI_TAG} )
-   endforeach()
-   list(APPEND _boost_DEBUG_NAMES
--    ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${_boost_MULTITHREADED}${_boost_DEBUG_ABI_TAG}-${Boost_LIB_VERSION}
-+    ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${_boost_MULTITHREADED}${_boost_DEBUG_ABI_TAG}${_boost_ARCHITECTURE_TAG}-${Boost_LIB_VERSION}
-     ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${_boost_MULTITHREADED}${_boost_DEBUG_ABI_TAG}
-     ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${_boost_MULTITHREADED}
-     ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT} )
-@@ -1678,11 +1710,11 @@ foreach(COMPONENT ${Boost_FIND_COMPONENT
-     set(_boost_DEBUG_STATIC_ABI_TAG "-s${_boost_DEBUG_ABI_TAG}")
-     foreach(compiler IN LISTS _boost_COMPILER)
-       list(APPEND _boost_DEBUG_NAMES
--        ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${compiler}${_boost_MULTITHREADED}${_boost_DEBUG_STATIC_ABI_TAG}-${Boost_LIB_VERSION}
-+        ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${compiler}${_boost_MULTITHREADED}${_boost_DEBUG_STATIC_ABI_TAG}${_boost_ARCHITECTURE_TAG}-${Boost_LIB_VERSION}
-         ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${compiler}${_boost_MULTITHREADED}${_boost_DEBUG_STATIC_ABI_TAG} )
-     endforeach()
-     list(APPEND _boost_DEBUG_NAMES
--      ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${_boost_MULTITHREADED}${_boost_DEBUG_STATIC_ABI_TAG}-${Boost_LIB_VERSION}
-+      ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${_boost_MULTITHREADED}${_boost_DEBUG_STATIC_ABI_TAG}${_boost_ARCHITECTURE_TAG}-${Boost_LIB_VERSION}
-       ${Boost_LIB_PREFIX}${Boost_NAMESPACE}_${COMPONENT}${_boost_MULTITHREADED}${_boost_DEBUG_STATIC_ABI_TAG} )
-   endif()
-   if(Boost_THREADAPI AND ${COMPONENT} STREQUAL "thread")
diff --git a/poky/meta/recipes-devtools/cmake/cmake/0002-cmake-Prevent-the-detection-of-Qt5.patch b/poky/meta/recipes-devtools/cmake/cmake/0002-cmake-Prevent-the-detection-of-Qt5.patch
new file mode 100644
index 0000000..6f788ad
--- /dev/null
+++ b/poky/meta/recipes-devtools/cmake/cmake/0002-cmake-Prevent-the-detection-of-Qt5.patch
@@ -0,0 +1,122 @@
+From 7a1f4e724f9c68498f401244c2938e784a2e6fbd Mon Sep 17 00:00:00 2001
+From: Otavio Salvador <otavio@ossystems.com.br>
+Date: Wed, 17 Jan 2018 10:02:14 -0200
+Subject: [PATCH 2/5] cmake: Prevent the detection of Qt5
+Organization: O.S. Systems Software LTDA.
+
+CMake doesn't have dependency on qt4/qt5, so these tests usually fail
+but still can cause undeterministic results or build failures (when
+OE_QMAKE_PATH_EXTERNAL_HOST_BINS is undefined or native qmake removed
+while running the test in cmake)
+
+Upstream-Status: Inappropriate [configuration]
+
+Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
+---
+ Source/QtDialog/CMakeLists.txt                     | 2 +-
+ Tests/CMakeLists.txt                               | 2 +-
+ Tests/Qt4And5Automoc/CMakeLists.txt                | 4 ++--
+ Tests/QtAutogen/AutogenTest.cmake                  | 2 +-
+ Tests/QtAutogen/MacOsFW/CMakeLists.txt             | 2 +-
+ Tests/RunCMake/CMakeLists.txt                      | 2 +-
+ Tests/RunCMake/IncompatibleQt/IncompatibleQt.cmake | 2 +-
+ 7 files changed, 8 insertions(+), 8 deletions(-)
+
+diff --git a/Source/QtDialog/CMakeLists.txt b/Source/QtDialog/CMakeLists.txt
+index 330b74729..e7709dee6 100644
+--- a/Source/QtDialog/CMakeLists.txt
++++ b/Source/QtDialog/CMakeLists.txt
+@@ -6,7 +6,7 @@ if(POLICY CMP0020)
+   cmake_policy(SET CMP0020 NEW) # Drop when CMake >= 2.8.11 required
+ endif()
+ CMake_OPTIONAL_COMPONENT(cmake-gui)
+-find_package(Qt5Widgets QUIET)
++#find_package(Qt5Widgets QUIET)
+ if (Qt5Widgets_FOUND)
+   include_directories(${Qt5Widgets_INCLUDE_DIRS})
+   add_definitions(${Qt5Widgets_DEFINITONS})
+diff --git a/Tests/CMakeLists.txt b/Tests/CMakeLists.txt
+index b8b724ed8..63f6bb6d2 100644
+--- a/Tests/CMakeLists.txt
++++ b/Tests/CMakeLists.txt
+@@ -1322,7 +1322,7 @@ ${CMake_BINARY_DIR}/bin/cmake -DDIR=dev -P ${CMake_SOURCE_DIR}/Utilities/Release
+     set(CMake_TEST_Qt5 1)
+   endif()
+   if(CMake_TEST_Qt5)
+-    find_package(Qt5Widgets QUIET NO_MODULE)
++    #find_package(Qt5Widgets QUIET NO_MODULE)
+   endif()
+   if(CMake_TEST_Qt5 AND Qt5Widgets_FOUND)
+     add_subdirectory(Qt5Autogen)
+diff --git a/Tests/Qt4And5Automoc/CMakeLists.txt b/Tests/Qt4And5Automoc/CMakeLists.txt
+index ad74961d9..a9dd74b15 100644
+--- a/Tests/Qt4And5Automoc/CMakeLists.txt
++++ b/Tests/Qt4And5Automoc/CMakeLists.txt
+@@ -3,11 +3,11 @@ cmake_minimum_required(VERSION 2.8.12)
+ project(Qt4And5Automoc)
+ 
+ if (QT_REVERSE_FIND_ORDER)
+-  find_package(Qt5Core REQUIRED)
++  #find_package(Qt5Core REQUIRED)
+   find_package(Qt4 REQUIRED)
+ else()
+   find_package(Qt4 REQUIRED)
+-  find_package(Qt5Core REQUIRED)
++  #find_package(Qt5Core REQUIRED)
+ endif()
+ 
+ set(CMAKE_AUTOMOC ON)
+diff --git a/Tests/QtAutogen/AutogenTest.cmake b/Tests/QtAutogen/AutogenTest.cmake
+index 8c0a14fca..e9923b21a 100644
+--- a/Tests/QtAutogen/AutogenTest.cmake
++++ b/Tests/QtAutogen/AutogenTest.cmake
+@@ -22,7 +22,7 @@ if (QT_TEST_VERSION STREQUAL 4)
+   endmacro()
+ 
+ elseif(QT_TEST_VERSION STREQUAL 5)
+-  find_package(Qt5Widgets REQUIRED)
++  #find_package(Qt5Widgets REQUIRED)
+ 
+   set(QT_QTCORE_TARGET Qt5::Core)
+   set(QT_QTGUI_TARGET Qt5::Widgets)
+diff --git a/Tests/QtAutogen/MacOsFW/CMakeLists.txt b/Tests/QtAutogen/MacOsFW/CMakeLists.txt
+index 26d201926..e48e1c8de 100644
+--- a/Tests/QtAutogen/MacOsFW/CMakeLists.txt
++++ b/Tests/QtAutogen/MacOsFW/CMakeLists.txt
+@@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 3.10)
+ project(MacOsFW)
+ include("../AutogenTest.cmake")
+ 
+-find_package(Qt5Test REQUIRED)
++#find_package(Qt5Test REQUIRED)
+ 
+ set(CMAKE_CXX_STANDARD 11)
+ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/output/bin)
+diff --git a/Tests/RunCMake/CMakeLists.txt b/Tests/RunCMake/CMakeLists.txt
+index 637c5c2cb..c0376effc 100644
+--- a/Tests/RunCMake/CMakeLists.txt
++++ b/Tests/RunCMake/CMakeLists.txt
+@@ -291,7 +291,7 @@ add_RunCMake_test(configure_file)
+ add_RunCMake_test(CTestTimeoutAfterMatch)
+ 
+ find_package(Qt4 QUIET)
+-find_package(Qt5Core QUIET)
++#find_package(Qt5Core QUIET)
+ if (QT4_FOUND AND Qt5Core_FOUND AND NOT Qt5Core_VERSION VERSION_LESS 5.1.0)
+   add_RunCMake_test(IncompatibleQt)
+ endif()
+diff --git a/Tests/RunCMake/IncompatibleQt/IncompatibleQt.cmake b/Tests/RunCMake/IncompatibleQt/IncompatibleQt.cmake
+index 4fccdc418..b76e1e531 100644
+--- a/Tests/RunCMake/IncompatibleQt/IncompatibleQt.cmake
++++ b/Tests/RunCMake/IncompatibleQt/IncompatibleQt.cmake
+@@ -1,6 +1,6 @@
+ 
+ find_package(Qt4 REQUIRED)
+-find_package(Qt5Core REQUIRED)
++#find_package(Qt5Core REQUIRED)
+ 
+ add_executable(mainexe main.cpp)
+ target_link_libraries(mainexe Qt4::QtCore Qt5::Core)
+-- 
+2.18.0
+
diff --git a/poky/meta/recipes-devtools/cmake/cmake/0003-FindBoost-Search-for-upstream-packaged-libs-next-to-.patch b/poky/meta/recipes-devtools/cmake/cmake/0003-FindBoost-Search-for-upstream-packaged-libs-next-to-.patch
deleted file mode 100644
index 5178f5c..0000000
--- a/poky/meta/recipes-devtools/cmake/cmake/0003-FindBoost-Search-for-upstream-packaged-libs-next-to-.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From d56deff7d127b030739bd0034609d0046121d8cd Mon Sep 17 00:00:00 2001
-From: "Paul \"TBBle\" Hampson" <Paul.Hampson@Pobox.com>
-Date: Fri, 29 Dec 2017 22:38:36 +1100
-Subject: [PATCH 3/6] FindBoost: Search for upstream-packaged libs next to
- includes
-
-Upstream packages Boost binaries for Windows with the 'boost' directory
-(the INCLUDE_DIR) next to the lib-... directory (the LIBRARY_DIR).
-
-Affects cmake < 3.11.0
-
-Upsteam-Status: Backport
-[Yocto 12762]
-Signed-off-by: Armin Kuster <akuster808@gmail.com>
-
----
- Modules/FindBoost.cmake | 1 +
- 1 file changed, 1 insertion(+)
-
-Index: cmake-3.10.3/Modules/FindBoost.cmake
-===================================================================
---- cmake-3.10.3.orig/Modules/FindBoost.cmake
-+++ cmake-3.10.3/Modules/FindBoost.cmake
-@@ -1502,6 +1502,7 @@ foreach(c DEBUG RELEASE)
-       ${Boost_INCLUDE_DIR}/stage/lib
-       )
-     _Boost_UPDATE_WINDOWS_LIBRARY_SEARCH_DIRS_WITH_PREBUILT_PATHS(_boost_LIBRARY_SEARCH_DIRS_${c} "${Boost_INCLUDE_DIR}/..")
-+    _Boost_UPDATE_WINDOWS_LIBRARY_SEARCH_DIRS_WITH_PREBUILT_PATHS(_boost_LIBRARY_SEARCH_DIRS_${c} "${Boost_INCLUDE_DIR}")
-     if( Boost_NO_SYSTEM_PATHS )
-       list(APPEND _boost_LIBRARY_SEARCH_DIRS_${c} NO_CMAKE_SYSTEM_PATH NO_SYSTEM_ENVIRONMENT_PATH)
-     else()
diff --git a/poky/meta/recipes-devtools/cmake/cmake/0003-cmake-support-OpenEmbedded-Qt4-tool-binary-names.patch b/poky/meta/recipes-devtools/cmake/cmake/0003-cmake-support-OpenEmbedded-Qt4-tool-binary-names.patch
new file mode 100644
index 0000000..55cf471
--- /dev/null
+++ b/poky/meta/recipes-devtools/cmake/cmake/0003-cmake-support-OpenEmbedded-Qt4-tool-binary-names.patch
@@ -0,0 +1,59 @@
+From c783ceeef485c23e13c3d9f0418719cb0e0b86ee Mon Sep 17 00:00:00 2001
+From: Otavio Salvador <otavio@ossystems.com.br>
+Date: Thu, 12 May 2011 15:36:03 +0000
+Subject: [PATCH 3/5] cmake: support OpenEmbedded Qt4 tool binary names
+Organization: O.S. Systems Software LTDA.
+
+The FindQt4 module looks for Qt4 binaries to be able to gather the
+paths used for compilation and also to be using during other processes
+(translation update, translation binary generating and like) however
+OpenEmbedded has renamed those to allow old QMake to be used in
+parallel with the current one. This patch adds support for the
+OpenEmbedded specific binary names.
+
+Upstream-Status: Inappropriate [embedded specific]
+
+Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
+
+The patch was slightly adapted in order to match cmake 3.2.2:
+Instead of find_program, _find_qt4_program is now used.
+
+Signed-off-by: Moritz Blume <moritz.blume@bmw-carit.de>
+Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
+---
+ Modules/FindQt4.cmake | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/Modules/FindQt4.cmake b/Modules/FindQt4.cmake
+index 847a798af..7ad981879 100644
+--- a/Modules/FindQt4.cmake
++++ b/Modules/FindQt4.cmake
+@@ -517,7 +517,7 @@ endfunction()
+ 
+ set(QT4_INSTALLED_VERSION_TOO_OLD FALSE)
+ 
+-set(_QT4_QMAKE_NAMES qmake qmake4 qmake-qt4 qmake-mac)
++set(_QT4_QMAKE_NAMES qmake qmake2 qmake4 qmake-qt4 qmake-mac)
+ _qt4_find_qmake("${_QT4_QMAKE_NAMES}" QT_QMAKE_EXECUTABLE QTVERSION)
+ 
+ if (QT_QMAKE_EXECUTABLE AND
+@@ -1135,12 +1135,12 @@ if (QT_QMAKE_EXECUTABLE AND
+   _find_qt4_program(QT_MOC_EXECUTABLE Qt4::moc moc-qt4 moc4 moc)
+   _find_qt4_program(QT_UIC_EXECUTABLE Qt4::uic uic-qt4 uic4 uic)
+   _find_qt4_program(QT_UIC3_EXECUTABLE Qt4::uic3 uic3)
+-  _find_qt4_program(QT_RCC_EXECUTABLE Qt4::rcc rcc)
+-  _find_qt4_program(QT_DBUSCPP2XML_EXECUTABLE Qt4::qdbuscpp2xml qdbuscpp2xml)
+-  _find_qt4_program(QT_DBUSXML2CPP_EXECUTABLE Qt4::qdbusxml2cpp qdbusxml2cpp)
++  _find_qt4_program(QT_RCC_EXECUTABLE Qt4::rcc rcc4 rcc)
++  _find_qt4_program(QT_DBUSCPP2XML_EXECUTABLE Qt4::qdbuscpp2xml qdbuscpp2xml4 qdbuscpp2xml)
++  _find_qt4_program(QT_DBUSXML2CPP_EXECUTABLE Qt4::qdbusxml2cpp qdbusxml2cpp4 qdbusxml2cpp)
+   _find_qt4_program(QT_LUPDATE_EXECUTABLE Qt4::lupdate lupdate-qt4 lupdate4 lupdate)
+   _find_qt4_program(QT_LRELEASE_EXECUTABLE Qt4::lrelease lrelease-qt4 lrelease4 lrelease)
+-  _find_qt4_program(QT_QCOLLECTIONGENERATOR_EXECUTABLE Qt4::qcollectiongenerator qcollectiongenerator-qt4 qcollectiongenerator)
++  _find_qt4_program(QT_QCOLLECTIONGENERATOR_EXECUTABLE Qt4::qcollectiongenerator qcollectiongenerator-qt4 qcollectiongenerator qcollectiongenerator4)
+   _find_qt4_program(QT_DESIGNER_EXECUTABLE Qt4::designer designer-qt4 designer4 designer)
+   _find_qt4_program(QT_LINGUIST_EXECUTABLE Qt4::linguist linguist-qt4 linguist4 linguist)
+ 
+-- 
+2.18.0
+
diff --git a/poky/meta/recipes-devtools/cmake/cmake/0004-Fail-silently-if-system-Qt-installation-is-broken.patch b/poky/meta/recipes-devtools/cmake/cmake/0004-Fail-silently-if-system-Qt-installation-is-broken.patch
new file mode 100644
index 0000000..a59c680
--- /dev/null
+++ b/poky/meta/recipes-devtools/cmake/cmake/0004-Fail-silently-if-system-Qt-installation-is-broken.patch
@@ -0,0 +1,82 @@
+From 9516fc4260f701c6d9db0c341bb36480362e1747 Mon Sep 17 00:00:00 2001
+From: Otavio Salvador <otavio@ossystems.com.br>
+Date: Thu, 5 Jul 2018 10:26:48 -0300
+Subject: [PATCH 4/5] Fail silently if system Qt installation is broken
+Organization: O.S. Systems Software LTDA.
+
+Fixes a regression in behaviour from 2.8.10 to 2.8.11 resulting in the
+following error if the system Qt installation is broken:
+
+CMake Error at Modules/FindQt4.cmake:1028 (set_property):
+  set_property could not find TARGET Qt4::QtCore.  Perhaps it has not yet
+  been created.
+Call Stack (most recent call first):
+  Tests/RunCMake/CMakeLists.txt:79 (find_package)
+
+Upstream-Status: Pending
+
+Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
+
+The patch was slightly adapted in order to match cmake 3.2.2:
+Another set_property was introduced which had to be included
+within the if(QT_QTCORE_FOUND) statement.
+
+Signed-off-by: Moritz Blume <moritz.blume@bmw-carit.de>
+Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
+---
+ Modules/FindQt4.cmake | 39 ++++++++++++++++++++-------------------
+ 1 file changed, 20 insertions(+), 19 deletions(-)
+
+diff --git a/Modules/FindQt4.cmake b/Modules/FindQt4.cmake
+index 7ad981879..8b6f43cda 100644
+--- a/Modules/FindQt4.cmake
++++ b/Modules/FindQt4.cmake
+@@ -987,25 +987,26 @@ if (QT_QMAKE_EXECUTABLE AND
+     endif()
+   endmacro()
+ 
+-
+-  # Set QT_xyz_LIBRARY variable and add
+-  # library include path to QT_INCLUDES
+-  _QT4_ADJUST_LIB_VARS(QtCore)
+-  set_property(TARGET Qt4::QtCore APPEND PROPERTY
+-    INTERFACE_INCLUDE_DIRECTORIES
+-      "${QT_MKSPECS_DIR}/default"
+-      ${QT_INCLUDE_DIR}
+-  )
+-  set_property(TARGET Qt4::QtCore APPEND PROPERTY
+-    INTERFACE_COMPILE_DEFINITIONS
+-      $<$<NOT:$<CONFIG:Debug>>:QT_NO_DEBUG>
+-  )
+-  set_property(TARGET Qt4::QtCore PROPERTY
+-    INTERFACE_QT_MAJOR_VERSION 4
+-  )
+-  set_property(TARGET Qt4::QtCore APPEND PROPERTY
+-    COMPATIBLE_INTERFACE_STRING QT_MAJOR_VERSION
+-  )
++  if(QT_QTCORE_FOUND)
++    # Set QT_xyz_LIBRARY variable and add
++    # library include path to QT_INCLUDES
++    _QT4_ADJUST_LIB_VARS(QtCore)
++    set_property(TARGET Qt4::QtCore APPEND PROPERTY
++      INTERFACE_INCLUDE_DIRECTORIES
++        "${QT_MKSPECS_DIR}/default"
++        ${QT_INCLUDE_DIR}
++    )
++    set_property(TARGET Qt4::QtCore APPEND PROPERTY
++      INTERFACE_COMPILE_DEFINITIONS
++        $<$<NOT:$<CONFIG:Debug>>:QT_NO_DEBUG>
++    )
++    set_property(TARGET Qt4::QtCore PROPERTY
++      INTERFACE_QT_MAJOR_VERSION 4
++    )
++    set_property(TARGET Qt4::QtCore APPEND PROPERTY
++      COMPATIBLE_INTERFACE_STRING QT_MAJOR_VERSION
++    )
++  endif()
+ 
+   foreach(QT_MODULE ${QT_MODULES})
+     _QT4_ADJUST_LIB_VARS(${QT_MODULE})
+-- 
+2.18.0
+
diff --git a/poky/meta/recipes-devtools/cmake/cmake/0005-Disable-use-of-ext2fs-ext2_fs.h-by-cmake-s-internal-.patch b/poky/meta/recipes-devtools/cmake/cmake/0005-Disable-use-of-ext2fs-ext2_fs.h-by-cmake-s-internal-.patch
new file mode 100644
index 0000000..23ce8e9
--- /dev/null
+++ b/poky/meta/recipes-devtools/cmake/cmake/0005-Disable-use-of-ext2fs-ext2_fs.h-by-cmake-s-internal-.patch
@@ -0,0 +1,40 @@
+From 0df8d46d14c371f21c327966a553c4c187a8acfe Mon Sep 17 00:00:00 2001
+From: Otavio Salvador <otavio@ossystems.com.br>
+Date: Thu, 5 Jul 2018 10:28:04 -0300
+Subject: [PATCH 5/5] Disable use of ext2fs/ext2_fs.h by cmake's internal
+ libarchive copy
+Organization: O.S. Systems Software LTDA.
+
+We don't want to add a dependency on e2fsprogs-native for cmake-native,
+and we don't use CPack so just disable this functionality.
+
+Upstream-Status: Inappropriate [config]
+
+Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
+Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
+---
+ Utilities/cmlibarchive/CMakeLists.txt | 8 ++------
+ 1 file changed, 2 insertions(+), 6 deletions(-)
+
+diff --git a/Utilities/cmlibarchive/CMakeLists.txt b/Utilities/cmlibarchive/CMakeLists.txt
+index 206f3c6a5..642fb0dd9 100644
+--- a/Utilities/cmlibarchive/CMakeLists.txt
++++ b/Utilities/cmlibarchive/CMakeLists.txt
+@@ -400,12 +400,8 @@ LA_CHECK_INCLUDE_FILE("copyfile.h" HAVE_COPYFILE_H)
+ LA_CHECK_INCLUDE_FILE("direct.h" HAVE_DIRECT_H)
+ LA_CHECK_INCLUDE_FILE("dlfcn.h" HAVE_DLFCN_H)
+ LA_CHECK_INCLUDE_FILE("errno.h" HAVE_ERRNO_H)
+-LA_CHECK_INCLUDE_FILE("ext2fs/ext2_fs.h" HAVE_EXT2FS_EXT2_FS_H)
+-
+-CHECK_C_SOURCE_COMPILES("#include <sys/ioctl.h>
+-#include <ext2fs/ext2_fs.h>
+-int main(void) { return EXT2_IOC_GETFLAGS; }" HAVE_WORKING_EXT2_IOC_GETFLAGS)
+-
++SET(HAVE_EXT2FS_EXT2_FS_H 0)
++SET(HAVE_WORKING_EXT2_IOC_GETFLAGS 0)
+ LA_CHECK_INCLUDE_FILE("fcntl.h" HAVE_FCNTL_H)
+ LA_CHECK_INCLUDE_FILE("grp.h" HAVE_GRP_H)
+ LA_CHECK_INCLUDE_FILE("inttypes.h" HAVE_INTTYPES_H)
+-- 
+2.18.0
+
diff --git a/poky/meta/recipes-devtools/cmake/cmake/OEToolchainConfig.cmake b/poky/meta/recipes-devtools/cmake/cmake/OEToolchainConfig.cmake
index dc8477e..8a0fb4c 100644
--- a/poky/meta/recipes-devtools/cmake/cmake/OEToolchainConfig.cmake
+++ b/poky/meta/recipes-devtools/cmake/cmake/OEToolchainConfig.cmake
@@ -3,6 +3,7 @@
 set( CMAKE_CXX_FLAGS $ENV{CXXFLAGS}  CACHE STRING "" FORCE )
 set( CMAKE_ASM_FLAGS ${CMAKE_C_FLAGS} CACHE STRING "" FORCE )
 set( CMAKE_LDFLAGS_FLAGS ${CMAKE_CXX_FLAGS} CACHE STRING "" FORCE )
+set( CMAKE_SYSROOT $ENV{OECORE_TARGET_SYSROOT} )
 
 set( CMAKE_FIND_ROOT_PATH $ENV{OECORE_TARGET_SYSROOT} $ENV{OECORE_NATIVE_SYSROOT} )
 set( CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER )
@@ -10,6 +11,8 @@
 set( CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY )
 set( CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY )
 
+set(CMAKE_FIND_LIBRARY_CUSTOM_LIB_SUFFIX "$ENV{OE_CMAKE_FIND_LIBRARY_CUSTOM_LIB_SUFFIX}")
+
 # Set CMAKE_SYSTEM_PROCESSOR from the sysroot name (assuming processor-distro-os).
 if ($ENV{SDKTARGETSYSROOT} MATCHES "/sysroots/([a-zA-Z0-9_-]+)-.+-.+")
   set(CMAKE_SYSTEM_PROCESSOR ${CMAKE_MATCH_1})
diff --git a/poky/meta/recipes-devtools/cmake/cmake/cmake-Prevent-the-detection-of-Qt5.patch b/poky/meta/recipes-devtools/cmake/cmake/cmake-Prevent-the-detection-of-Qt5.patch
deleted file mode 100644
index 88b7e94..0000000
--- a/poky/meta/recipes-devtools/cmake/cmake/cmake-Prevent-the-detection-of-Qt5.patch
+++ /dev/null
@@ -1,215 +0,0 @@
-From 875c11dbf87d1258ad7d3697a40d605d503e5673 Mon Sep 17 00:00:00 2001
-From: Otavio Salvador <otavio@ossystems.com.br>
-Date: Wed, 17 Jan 2018 10:02:14 -0200
-Subject: [PATCH] cmake: Prevent the detection of Qt5
-Organization: O.S. Systems Software LTDA.
-
-CMake doesn't have dependency on qt4/qt5, so these tests usually fail
-but still can cause undeterministic results or build failures (when
-OE_QMAKE_PATH_EXTERNAL_HOST_BINS is undefined or native qmake removed
-while running the test in cmake)
-
-Upstream-Status: Inappropriate [configuration]
-
-Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
----
- Source/QtDialog/CMakeLists.txt                     | 2 +-
- Tests/CMakeLists.txt                               | 2 +-
- Tests/Qt4And5Automoc/CMakeLists.txt                | 4 ++--
- Tests/QtAutoUicInterface/CMakeLists.txt            | 2 +-
- Tests/QtAutogen/CMakeLists.txt                     | 2 +-
- Tests/QtAutogen/macosFW/CMakeLists.txt             | 2 +-
- Tests/QtAutogen/mocDepends/CMakeLists.txt          | 2 +-
- Tests/QtAutogenRerun/CMakeLists.txt                | 4 ++--
- Tests/QtAutogenRerun/mocPlugin/CMakeLists.txt      | 2 +-
- Tests/QtAutogenRerun/mocRerun/CMakeLists.txt       | 2 +-
- Tests/QtAutogenRerun/rccDepends/CMakeLists.txt     | 2 +-
- Tests/RunCMake/CMakeLists.txt                      | 2 +-
- Tests/RunCMake/IncompatibleQt/IncompatibleQt.cmake | 2 +-
- 13 files changed, 15 insertions(+), 15 deletions(-)
-
-diff --git a/Source/QtDialog/CMakeLists.txt b/Source/QtDialog/CMakeLists.txt
-index b38797bca..b5fbfc5fa 100644
---- a/Source/QtDialog/CMakeLists.txt
-+++ b/Source/QtDialog/CMakeLists.txt
-@@ -6,7 +6,7 @@ if(POLICY CMP0020)
-   cmake_policy(SET CMP0020 NEW) # Drop when CMake >= 2.8.11 required
- endif()
- CMake_OPTIONAL_COMPONENT(cmake-gui)
--find_package(Qt5Widgets QUIET)
-+#find_package(Qt5Widgets QUIET)
- if (Qt5Widgets_FOUND)
-   include_directories(${Qt5Widgets_INCLUDE_DIRS})
-   add_definitions(${Qt5Widgets_DEFINITONS})
-diff --git a/Tests/CMakeLists.txt b/Tests/CMakeLists.txt
-index 533788a44..32ef03c55 100644
---- a/Tests/CMakeLists.txt
-+++ b/Tests/CMakeLists.txt
-@@ -1260,7 +1260,7 @@ ${CMake_BINARY_DIR}/bin/cmake -DDIR=dev -P ${CMake_SOURCE_DIR}/Utilities/Release
-     set(CMake_TEST_Qt5 1)
-   endif()
-   if(CMake_TEST_Qt5)
--    find_package(Qt5Widgets QUIET NO_MODULE)
-+    #find_package(Qt5Widgets QUIET NO_MODULE)
-   endif()
-   if(CMake_TEST_Qt5 AND Qt5Widgets_FOUND)
-     add_test(NAME Qt5Autogen COMMAND ${CMAKE_CTEST_COMMAND}
-diff --git a/Tests/Qt4And5Automoc/CMakeLists.txt b/Tests/Qt4And5Automoc/CMakeLists.txt
-index ad74961d9..a9dd74b15 100644
---- a/Tests/Qt4And5Automoc/CMakeLists.txt
-+++ b/Tests/Qt4And5Automoc/CMakeLists.txt
-@@ -3,11 +3,11 @@ cmake_minimum_required(VERSION 2.8.12)
- project(Qt4And5Automoc)
- 
- if (QT_REVERSE_FIND_ORDER)
--  find_package(Qt5Core REQUIRED)
-+  #find_package(Qt5Core REQUIRED)
-   find_package(Qt4 REQUIRED)
- else()
-   find_package(Qt4 REQUIRED)
--  find_package(Qt5Core REQUIRED)
-+  #find_package(Qt5Core REQUIRED)
- endif()
- 
- set(CMAKE_AUTOMOC ON)
-diff --git a/Tests/QtAutoUicInterface/CMakeLists.txt b/Tests/QtAutoUicInterface/CMakeLists.txt
-index a5c2d99b2..2d640e4a3 100644
---- a/Tests/QtAutoUicInterface/CMakeLists.txt
-+++ b/Tests/QtAutoUicInterface/CMakeLists.txt
-@@ -14,7 +14,7 @@ else()
-   if (NOT QT_TEST_VERSION STREQUAL 5)
-     message(SEND_ERROR "Invalid Qt version specified.")
-   endif()
--  find_package(Qt5Widgets REQUIRED)
-+  #find_package(Qt5Widgets REQUIRED)
- 
-   set(QT_CORE_TARGET Qt5::Core)
-   set(QT_GUI_TARGET Qt5::Widgets)
-diff --git a/Tests/QtAutogen/CMakeLists.txt b/Tests/QtAutogen/CMakeLists.txt
-index dff9d0c66..c6e8fc3f5 100644
---- a/Tests/QtAutogen/CMakeLists.txt
-+++ b/Tests/QtAutogen/CMakeLists.txt
-@@ -23,7 +23,7 @@ else()
-   if (NOT QT_TEST_VERSION STREQUAL 5)
-     message(SEND_ERROR "Invalid Qt version specified.")
-   endif()
--  find_package(Qt5Widgets REQUIRED)
-+  #find_package(Qt5Widgets REQUIRED)
- 
-   set(QT_QTCORE_TARGET Qt5::Core)
- 
-diff --git a/Tests/QtAutogen/macosFW/CMakeLists.txt b/Tests/QtAutogen/macosFW/CMakeLists.txt
-index 114d9bac0..157fe0aaa 100644
---- a/Tests/QtAutogen/macosFW/CMakeLists.txt
-+++ b/Tests/QtAutogen/macosFW/CMakeLists.txt
-@@ -1,7 +1,7 @@
- cmake_minimum_required(VERSION 3.8)
- project(macos-fw-test)
- 
--find_package(Qt5Test REQUIRED)
-+#find_package(Qt5Test REQUIRED)
- 
- set(CMAKE_CXX_STANDARD 11)
- set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/output/bin)
-diff --git a/Tests/QtAutogen/mocDepends/CMakeLists.txt b/Tests/QtAutogen/mocDepends/CMakeLists.txt
-index 8217b8dbf..86bb7bc7f 100644
---- a/Tests/QtAutogen/mocDepends/CMakeLists.txt
-+++ b/Tests/QtAutogen/mocDepends/CMakeLists.txt
-@@ -10,7 +10,7 @@ else()
-     message(SEND_ERROR "Invalid Qt version specified.")
-   endif()
- 
--  find_package(Qt5Core REQUIRED)
-+  #find_package(Qt5Core REQUIRED)
-   set(QT_CORE_TARGET Qt5::Core)
- endif()
- 
-diff --git a/Tests/QtAutogenRerun/CMakeLists.txt b/Tests/QtAutogenRerun/CMakeLists.txt
-index e72c1912e..d7e6884ce 100644
---- a/Tests/QtAutogenRerun/CMakeLists.txt
-+++ b/Tests/QtAutogenRerun/CMakeLists.txt
-@@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 3.9)
- cmake_policy(SET CMP0071 NEW)
- project(QtAutogenRerun)
- 
--# Tell find_package(Qt5) where to find Qt.
-+# Tell #find_package(Qt5) where to find Qt.
- if(QT_QMAKE_EXECUTABLE)
-   get_filename_component(Qt_BIN_DIR "${QT_QMAKE_EXECUTABLE}" PATH)
-   get_filename_component(Qt_PREFIX_DIR "${Qt_BIN_DIR}" PATH)
-@@ -23,7 +23,7 @@ else()
-   if (NOT QT_TEST_VERSION STREQUAL 5)
-     message(SEND_ERROR "Invalid Qt version specified.")
-   endif()
--  find_package(Qt5Widgets REQUIRED)
-+  #find_package(Qt5Widgets REQUIRED)
- 
-   set(QT_QTCORE_TARGET Qt5::Core)
- 
-diff --git a/Tests/QtAutogenRerun/mocPlugin/CMakeLists.txt b/Tests/QtAutogenRerun/mocPlugin/CMakeLists.txt
-index b7cc5e9ff..e1d109953 100644
---- a/Tests/QtAutogenRerun/mocPlugin/CMakeLists.txt
-+++ b/Tests/QtAutogenRerun/mocPlugin/CMakeLists.txt
-@@ -9,7 +9,7 @@ set(CMAKE_AUTOMOC_DEPEND_FILTERS
- if (NOT QT_TEST_VERSION STREQUAL 5)
-   message(SEND_ERROR "Invalid Qt version specified.")
- endif()
--find_package(Qt5Widgets REQUIRED)
-+#find_package(Qt5Widgets REQUIRED)
- 
- if(Qt5_POSITION_INDEPENDENT_CODE AND CMAKE_CXX_COMPILE_OPTIONS_PIC)
-   add_definitions(${CMAKE_CXX_COMPILE_OPTIONS_PIC})
-diff --git a/Tests/QtAutogenRerun/mocRerun/CMakeLists.txt b/Tests/QtAutogenRerun/mocRerun/CMakeLists.txt
-index bafd9cf48..43ec933d2 100644
---- a/Tests/QtAutogenRerun/mocRerun/CMakeLists.txt
-+++ b/Tests/QtAutogenRerun/mocRerun/CMakeLists.txt
-@@ -10,7 +10,7 @@ else()
-     message(SEND_ERROR "Invalid Qt version specified.")
-   endif()
- 
--  find_package(Qt5Core REQUIRED)
-+  #find_package(Qt5Core REQUIRED)
-   set(QT_CORE_TARGET Qt5::Core)
- endif()
- 
-diff --git a/Tests/QtAutogenRerun/rccDepends/CMakeLists.txt b/Tests/QtAutogenRerun/rccDepends/CMakeLists.txt
-index 291592e7d..40cd52868 100644
---- a/Tests/QtAutogenRerun/rccDepends/CMakeLists.txt
-+++ b/Tests/QtAutogenRerun/rccDepends/CMakeLists.txt
-@@ -9,7 +9,7 @@ else()
-     message(SEND_ERROR "Invalid Qt version specified.")
-   endif()
- 
--  find_package(Qt5Core REQUIRED)
-+  #find_package(Qt5Core REQUIRED)
-   set(QT_CORE_TARGET Qt5::Core)
- endif()
- 
-diff --git a/Tests/RunCMake/CMakeLists.txt b/Tests/RunCMake/CMakeLists.txt
-index 29325ff0a..d30d01e78 100644
---- a/Tests/RunCMake/CMakeLists.txt
-+++ b/Tests/RunCMake/CMakeLists.txt
-@@ -274,7 +274,7 @@ add_RunCMake_test(configure_file)
- add_RunCMake_test(CTestTimeoutAfterMatch)
- 
- find_package(Qt4 QUIET)
--find_package(Qt5Core QUIET)
-+#find_package(Qt5Core QUIET)
- if (QT4_FOUND AND Qt5Core_FOUND AND NOT Qt5Core_VERSION VERSION_LESS 5.1.0)
-   add_RunCMake_test(IncompatibleQt)
- endif()
-diff --git a/Tests/RunCMake/IncompatibleQt/IncompatibleQt.cmake b/Tests/RunCMake/IncompatibleQt/IncompatibleQt.cmake
-index 4fccdc418..b76e1e531 100644
---- a/Tests/RunCMake/IncompatibleQt/IncompatibleQt.cmake
-+++ b/Tests/RunCMake/IncompatibleQt/IncompatibleQt.cmake
-@@ -1,6 +1,6 @@
- 
- find_package(Qt4 REQUIRED)
--find_package(Qt5Core REQUIRED)
-+#find_package(Qt5Core REQUIRED)
- 
- add_executable(mainexe main.cpp)
- target_link_libraries(mainexe Qt4::QtCore Qt5::Core)
--- 
-2.15.1
-
diff --git a/poky/meta/recipes-devtools/cmake/cmake/cmlibarchive-disable-ext2fs.patch b/poky/meta/recipes-devtools/cmake/cmake/cmlibarchive-disable-ext2fs.patch
deleted file mode 100644
index bf36712..0000000
--- a/poky/meta/recipes-devtools/cmake/cmake/cmlibarchive-disable-ext2fs.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-Disable use of ext2fs/ext2_fs.h by cmake's internal libarchive copy
-
-We don't want to add a dependency on e2fsprogs-native for cmake-native,
-and we don't use CPack so just disable this functionality.
-
-Upstream-Status: Inappropriate [config]
-
-Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
-
---- a/Utilities/cmlibarchive/CMakeLists.txt
-+++ b/Utilities/cmlibarchive/CMakeLists.txt
-@@ -237,12 +237,8 @@ LA_CHECK_INCLUDE_FILE("copyfile.h" HAVE_COPYFILE_H)
- LA_CHECK_INCLUDE_FILE("direct.h" HAVE_DIRECT_H)
- LA_CHECK_INCLUDE_FILE("dlfcn.h" HAVE_DLFCN_H)
- LA_CHECK_INCLUDE_FILE("errno.h" HAVE_ERRNO_H)
--LA_CHECK_INCLUDE_FILE("ext2fs/ext2_fs.h" HAVE_EXT2FS_EXT2_FS_H)
--
--CHECK_C_SOURCE_COMPILES("#include <sys/ioctl.h>
--#include <ext2fs/ext2_fs.h>
--int main(void) { return EXT2_IOC_GETFLAGS; }" HAVE_WORKING_EXT2_IOC_GETFLAGS)
--
-+SET(HAVE_EXT2FS_EXT2_FS_H 0)
-+SET(HAVE_WORKING_EXT2_IOC_GETFLAGS 0)
- LA_CHECK_INCLUDE_FILE("fcntl.h" HAVE_FCNTL_H)
- LA_CHECK_INCLUDE_FILE("grp.h" HAVE_GRP_H)
- LA_CHECK_INCLUDE_FILE("inttypes.h" HAVE_INTTYPES_H)
diff --git a/poky/meta/recipes-devtools/cmake/cmake/environment.d-cmake.sh b/poky/meta/recipes-devtools/cmake/cmake/environment.d-cmake.sh
index 0eb56b6..7bdb19f 100644
--- a/poky/meta/recipes-devtools/cmake/cmake/environment.d-cmake.sh
+++ b/poky/meta/recipes-devtools/cmake/cmake/environment.d-cmake.sh
@@ -1 +1,2 @@
-alias cmake="cmake -DCMAKE_TOOLCHAIN_FILE=$OECORE_NATIVE_SYSROOT/usr/share/cmake/OEToolchainConfig.cmake"
+export OE_CMAKE_TOOLCHAIN_FILE="$OECORE_NATIVE_SYSROOT/usr/share/cmake/OEToolchainConfig.cmake"
+export OE_CMAKE_FIND_LIBRARY_CUSTOM_LIB_SUFFIX="`echo $OECORE_BASELIB | sed -e s/lib//`"
diff --git a/poky/meta/recipes-devtools/cmake/cmake/qt4-fail-silent.patch b/poky/meta/recipes-devtools/cmake/cmake/qt4-fail-silent.patch
deleted file mode 100644
index 80fc277..0000000
--- a/poky/meta/recipes-devtools/cmake/cmake/qt4-fail-silent.patch
+++ /dev/null
@@ -1,77 +0,0 @@
-Fail silently if system Qt installation is broken
-
-Fixes a regression in behaviour from 2.8.10 to 2.8.11 resulting in the
-following error if the system Qt installation is broken:
-
-CMake Error at Modules/FindQt4.cmake:1028 (set_property):
-  set_property could not find TARGET Qt4::QtCore.  Perhaps it has not yet
-  been created.
-Call Stack (most recent call first):
-  Tests/RunCMake/CMakeLists.txt:79 (find_package)
-
-Upstream-Status: Pending
-
-Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
-
-The patch was slightly adapted in order to match cmake 3.2.2:
-Another set_property was introduced which had to be included
-within the if(QT_QTCORE_FOUND) statement.
-
-Signed-off-by: Moritz Blume <moritz.blume@bmw-carit.de>
----
- Modules/FindQt4.cmake | 39 ++++++++++++++++++++-------------------
- 1 file changed, 20 insertions(+), 19 deletions(-)
-
-diff --git a/Modules/FindQt4.cmake b/Modules/FindQt4.cmake
-index 6704769..9048e35 100644
---- a/Modules/FindQt4.cmake
-+++ b/Modules/FindQt4.cmake
-@@ -1000,25 +1000,26 @@ if (QT_QMAKE_EXECUTABLE AND
-     endif()
-   endmacro()
- 
--
--  # Set QT_xyz_LIBRARY variable and add
--  # library include path to QT_INCLUDES
--  _QT4_ADJUST_LIB_VARS(QtCore)
--  set_property(TARGET Qt4::QtCore APPEND PROPERTY
--    INTERFACE_INCLUDE_DIRECTORIES
--      "${QT_MKSPECS_DIR}/default"
--      ${QT_INCLUDE_DIR}
--  )
--  set_property(TARGET Qt4::QtCore APPEND PROPERTY
--    INTERFACE_COMPILE_DEFINITIONS
--      $<$<NOT:$<CONFIG:Debug>>:QT_NO_DEBUG>
--  )
--  set_property(TARGET Qt4::QtCore PROPERTY
--    INTERFACE_QT_MAJOR_VERSION 4
--  )
--  set_property(TARGET Qt4::QtCore APPEND PROPERTY
--    COMPATIBLE_INTERFACE_STRING QT_MAJOR_VERSION
--  )
-+  if(QT_QTCORE_FOUND)
-+    # Set QT_xyz_LIBRARY variable and add
-+    # library include path to QT_INCLUDES
-+    _QT4_ADJUST_LIB_VARS(QtCore)
-+    set_property(TARGET Qt4::QtCore APPEND PROPERTY
-+      INTERFACE_INCLUDE_DIRECTORIES
-+        "${QT_MKSPECS_DIR}/default"
-+        ${QT_INCLUDE_DIR}
-+    )
-+    set_property(TARGET Qt4::QtCore APPEND PROPERTY
-+      INTERFACE_COMPILE_DEFINITIONS
-+        $<$<NOT:$<CONFIG:Debug>>:QT_NO_DEBUG>
-+    )
-+    set_property(TARGET Qt4::QtCore PROPERTY
-+      INTERFACE_QT_MAJOR_VERSION 4
-+    )
-+    set_property(TARGET Qt4::QtCore APPEND PROPERTY
-+      COMPATIBLE_INTERFACE_STRING QT_MAJOR_VERSION
-+    )
-+  endif()
- 
-   foreach(QT_MODULE ${QT_MODULES})
-     _QT4_ADJUST_LIB_VARS(${QT_MODULE})
--- 
-1.9.1
-
diff --git a/poky/meta/recipes-devtools/cmake/cmake/support-oe-qt4-tools-names.patch b/poky/meta/recipes-devtools/cmake/cmake/support-oe-qt4-tools-names.patch
deleted file mode 100644
index 6841554..0000000
--- a/poky/meta/recipes-devtools/cmake/cmake/support-oe-qt4-tools-names.patch
+++ /dev/null
@@ -1,58 +0,0 @@
-From 10b8b523869124d2fc8cd98d9e028c0bcffd61b1 Mon Sep 17 00:00:00 2001
-From: Otavio Salvador <otavio@ossystems.com.br>
-Date: Thu, 12 May 2011 15:36:03 +0000
-Subject: [PATCH 1/2] cmake: support OpenEmbedded Qt4 tool binary names
-
-The FindQt4 module looks for Qt4 binaries to be able to gather the
-paths used for compilation and also to be using during other processes
-(translation update, translation binary generating and like) however
-OpenEmbedded has renamed those to allow old QMake to be used in
-parallel with the current one. This patch adds support for the
-OpenEmbedded specific binary names.
-
-Upstream-Status: Inappropriate [embedded specific]
-
-Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
-
-The patch was slightly adapted in order to match cmake 3.2.2:
-Instead of find_program, _find_qt4_program is now used.
-
-Signed-off-by: Moritz Blume <moritz.blume@bmw-carit.de>
-
----
- Modules/FindQt4.cmake | 10 +++++-----
- 1 file changed, 5 insertions(+), 5 deletions(-)
-
-diff --git a/Modules/FindQt4.cmake b/Modules/FindQt4.cmake
-index c67d0be..0cf169b 100644
---- a/Modules/FindQt4.cmake
-+++ b/Modules/FindQt4.cmake
-@@ -516,7 +516,7 @@ endfunction()
- 
- set(QT4_INSTALLED_VERSION_TOO_OLD FALSE)
- 
--set(_QT4_QMAKE_NAMES qmake qmake4 qmake-qt4 qmake-mac)
-+set(_QT4_QMAKE_NAMES qmake qmake2 qmake4 qmake-qt4 qmake-mac)
- _qt4_find_qmake("${_QT4_QMAKE_NAMES}" QT_QMAKE_EXECUTABLE QTVERSION)
- 
- if (QT_QMAKE_EXECUTABLE AND
-@@ -1142,12 +1142,12 @@ if (QT_QMAKE_EXECUTABLE AND
-   _find_qt4_program(QT_MOC_EXECUTABLE Qt4::moc moc-qt4 moc4 moc)
-   _find_qt4_program(QT_UIC_EXECUTABLE Qt4::uic uic-qt4 uic4 uic)
-   _find_qt4_program(QT_UIC3_EXECUTABLE Qt4::uic3 uic3)
--  _find_qt4_program(QT_RCC_EXECUTABLE Qt4::rcc rcc)
--  _find_qt4_program(QT_DBUSCPP2XML_EXECUTABLE Qt4::qdbuscpp2xml qdbuscpp2xml)
--  _find_qt4_program(QT_DBUSXML2CPP_EXECUTABLE Qt4::qdbusxml2cpp qdbusxml2cpp)
-+  _find_qt4_program(QT_RCC_EXECUTABLE Qt4::rcc rcc4 rcc)
-+  _find_qt4_program(QT_DBUSCPP2XML_EXECUTABLE Qt4::qdbuscpp2xml qdbuscpp2xml4 qdbuscpp2xml)
-+  _find_qt4_program(QT_DBUSXML2CPP_EXECUTABLE Qt4::qdbusxml2cpp qdbusxml2cpp4 qdbusxml2cpp)
-   _find_qt4_program(QT_LUPDATE_EXECUTABLE Qt4::lupdate lupdate-qt4 lupdate4 lupdate)
-   _find_qt4_program(QT_LRELEASE_EXECUTABLE Qt4::lrelease lrelease-qt4 lrelease4 lrelease)
--  _find_qt4_program(QT_QCOLLECTIONGENERATOR_EXECUTABLE Qt4::qcollectiongenerator qcollectiongenerator-qt4 qcollectiongenerator)
-+  _find_qt4_program(QT_QCOLLECTIONGENERATOR_EXECUTABLE Qt4::qcollectiongenerator qcollectiongenerator-qt4 qcollectiongenerator qcollectiongenerator4)
-   _find_qt4_program(QT_DESIGNER_EXECUTABLE Qt4::designer designer-qt4 designer4 designer)
-   _find_qt4_program(QT_LINGUIST_EXECUTABLE Qt4::linguist linguist-qt4 linguist4 linguist)
- 
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-devtools/cmake/cmake_3.10.3.bb b/poky/meta/recipes-devtools/cmake/cmake_3.10.3.bb
deleted file mode 100644
index 7d81edc..0000000
--- a/poky/meta/recipes-devtools/cmake/cmake_3.10.3.bb
+++ /dev/null
@@ -1,51 +0,0 @@
-require cmake.inc
-
-inherit cmake
-
-DEPENDS += "curl expat zlib libarchive xz ncurses bzip2"
-
-SRC_URI_append_class-nativesdk = " \
-    file://OEToolchainConfig.cmake \
-    file://environment.d-cmake.sh"
-
-# Strip ${prefix} from ${docdir}, set result into docdir_stripped
-python () {
-    prefix=d.getVar("prefix")
-    docdir=d.getVar("docdir")
-
-    if not docdir.startswith(prefix):
-        bb.fatal('docdir must contain prefix as its prefix')
-
-    docdir_stripped = docdir[len(prefix):]
-    if len(docdir_stripped) > 0 and docdir_stripped[0] == '/':
-        docdir_stripped = docdir_stripped[1:]
-
-    d.setVar("docdir_stripped", docdir_stripped)
-}
-
-EXTRA_OECMAKE=" \
-    -DCMAKE_DOC_DIR=${docdir_stripped}/cmake-${CMAKE_MAJOR_VERSION} \
-    -DCMAKE_USE_SYSTEM_LIBRARIES=1 \
-    -DCMAKE_USE_SYSTEM_LIBRARY_JSONCPP=0 \
-    -DCMAKE_USE_SYSTEM_LIBRARY_LIBUV=0 \
-    -DCMAKE_USE_SYSTEM_LIBRARY_LIBRHASH=0 \
-    -DKWSYS_CHAR_IS_SIGNED=1 \
-    -DBUILD_CursesDialog=0 \
-    -DKWSYS_LFS_WORKS=1 \
-"
-
-do_install_append_class-nativesdk() {
-    mkdir -p ${D}${datadir}/cmake
-    install -m 644 ${WORKDIR}/OEToolchainConfig.cmake ${D}${datadir}/cmake/
-
-    mkdir -p ${D}${SDKPATHNATIVE}/environment-setup.d
-    install -m 644 ${WORKDIR}/environment.d-cmake.sh ${D}${SDKPATHNATIVE}/environment-setup.d/cmake.sh
-}
-
-FILES_${PN}_append_class-nativesdk = " ${SDKPATHNATIVE}"
-
-FILES_${PN} += "${datadir}/cmake-${CMAKE_MAJOR_VERSION} ${datadir}/cmake ${datadir}/aclocal"
-FILES_${PN}-doc += "${docdir}/cmake-${CMAKE_MAJOR_VERSION}"
-FILES_${PN}-dev = ""
-
-BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-devtools/cmake/cmake_3.12.2.bb b/poky/meta/recipes-devtools/cmake/cmake_3.12.2.bb
new file mode 100644
index 0000000..e045767
--- /dev/null
+++ b/poky/meta/recipes-devtools/cmake/cmake_3.12.2.bb
@@ -0,0 +1,53 @@
+require cmake.inc
+
+inherit cmake
+
+DEPENDS += "curl expat zlib libarchive xz ncurses bzip2"
+
+SRC_URI_append_class-nativesdk = " \
+    file://OEToolchainConfig.cmake \
+    file://environment.d-cmake.sh \
+    file://0001-CMakeDetermineSystem-use-oe-environment-vars-to-load.patch \
+"
+
+# Strip ${prefix} from ${docdir}, set result into docdir_stripped
+python () {
+    prefix=d.getVar("prefix")
+    docdir=d.getVar("docdir")
+
+    if not docdir.startswith(prefix):
+        bb.fatal('docdir must contain prefix as its prefix')
+
+    docdir_stripped = docdir[len(prefix):]
+    if len(docdir_stripped) > 0 and docdir_stripped[0] == '/':
+        docdir_stripped = docdir_stripped[1:]
+
+    d.setVar("docdir_stripped", docdir_stripped)
+}
+
+EXTRA_OECMAKE=" \
+    -DCMAKE_DOC_DIR=${docdir_stripped}/cmake-${CMAKE_MAJOR_VERSION} \
+    -DCMAKE_USE_SYSTEM_LIBRARIES=1 \
+    -DCMAKE_USE_SYSTEM_LIBRARY_JSONCPP=0 \
+    -DCMAKE_USE_SYSTEM_LIBRARY_LIBUV=0 \
+    -DCMAKE_USE_SYSTEM_LIBRARY_LIBRHASH=0 \
+    -DKWSYS_CHAR_IS_SIGNED=1 \
+    -DBUILD_CursesDialog=0 \
+    -DKWSYS_LFS_WORKS=1 \
+"
+
+do_install_append_class-nativesdk() {
+    mkdir -p ${D}${datadir}/cmake
+    install -m 644 ${WORKDIR}/OEToolchainConfig.cmake ${D}${datadir}/cmake/
+
+    mkdir -p ${D}${SDKPATHNATIVE}/environment-setup.d
+    install -m 644 ${WORKDIR}/environment.d-cmake.sh ${D}${SDKPATHNATIVE}/environment-setup.d/cmake.sh
+}
+
+FILES_${PN}_append_class-nativesdk = " ${SDKPATHNATIVE}"
+
+FILES_${PN} += "${datadir}/cmake-${CMAKE_MAJOR_VERSION} ${datadir}/cmake ${datadir}/aclocal"
+FILES_${PN}-doc += "${docdir}/cmake-${CMAKE_MAJOR_VERSION}"
+FILES_${PN}-dev = ""
+
+BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-devtools/createrepo-c/createrepo-c_git.bb b/poky/meta/recipes-devtools/createrepo-c/createrepo-c_git.bb
index 3176136..2960811 100644
--- a/poky/meta/recipes-devtools/createrepo-c/createrepo-c_git.bb
+++ b/poky/meta/recipes-devtools/createrepo-c/createrepo-c_git.bb
@@ -9,8 +9,8 @@
            file://0001-Correctly-install-the-shared-library.patch \
            "
 
-PV = "0.10.0+git${SRCPV}"
-SRCREV = "748891ff8ee524c2d37926c608cd2794f88013f3"
+PV = "0.11.1+git${SRCPV}"
+SRCREV = "434a40babdde57ab405e9a1085a30e9575ea0c92"
 
 S = "${WORKDIR}/git"
 
@@ -21,7 +21,7 @@
 
 EXTRA_OECMAKE = " -DPYTHON_INSTALL_DIR=${PYTHON_SITEPACKAGES_DIR} -DPYTHON_DESIRED=3"
 
-BBCLASSEXTEND = "native"
+BBCLASSEXTEND = "native nativesdk"
 
 # Direct createrepo to read rpm configuration from our sysroot, not the one it was compiled in
 do_install_append_class-native() {
@@ -29,3 +29,8 @@
                 RPM_CONFIGDIR=${STAGING_LIBDIR_NATIVE}/rpm
 }
 
+do_install_append_class-nativesdk() {
+        create_wrapper ${D}/${bindir}/createrepo_c \
+                RPM_CONFIGDIR=${SDKPATHNATIVE}${libdir_nativesdk}/rpm
+        rm -rf ${D}/etc
+}
diff --git a/poky/meta/recipes-devtools/desktop-file-utils/desktop-file-utils-native_0.23.bb b/poky/meta/recipes-devtools/desktop-file-utils/desktop-file-utils-native_0.23.bb
deleted file mode 100644
index 54daabe..0000000
--- a/poky/meta/recipes-devtools/desktop-file-utils/desktop-file-utils-native_0.23.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-SECTION = "console/utils"
-SUMMARY = "Command line utilities for working with *.desktop files"
-HOMEPAGE = "http://www.freedesktop.org/wiki/Software/desktop-file-utils"
-LICENSE = "GPLv2"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-DEPENDS = "glib-2.0-native"
-
-SRC_URI = "http://freedesktop.org/software/desktop-file-utils/releases/desktop-file-utils-${PV}.tar.xz"
-
-SRC_URI[md5sum] = "599133d51cc9a41bfec186414906b6f1"
-SRC_URI[sha256sum] = "6c094031bdec46c9f621708f919084e1cb5294e2c5b1e4c883b3e70cb8903385"
-
-inherit autotools native
-
-S = "${WORKDIR}/desktop-file-utils-${PV}"
-
-EXTRA_OECONF += "ac_cv_prog_EMACS=no"
diff --git a/poky/meta/recipes-devtools/desktop-file-utils/desktop-file-utils_0.23.bb b/poky/meta/recipes-devtools/desktop-file-utils/desktop-file-utils_0.23.bb
new file mode 100644
index 0000000..6446f47
--- /dev/null
+++ b/poky/meta/recipes-devtools/desktop-file-utils/desktop-file-utils_0.23.bb
@@ -0,0 +1,19 @@
+SECTION = "console/utils"
+SUMMARY = "Command line utilities for working with *.desktop files"
+HOMEPAGE = "http://www.freedesktop.org/wiki/Software/desktop-file-utils"
+LICENSE = "GPLv2+"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                    file://src/validator.c;beginline=4;endline=27;md5=281e1114ee6c486a1a0a4295986b9416"
+
+SRC_URI = "http://freedesktop.org/software/${BPN}/releases/${BP}.tar.xz"
+SRC_URI[md5sum] = "599133d51cc9a41bfec186414906b6f1"
+SRC_URI[sha256sum] = "6c094031bdec46c9f621708f919084e1cb5294e2c5b1e4c883b3e70cb8903385"
+
+DEPENDS = "glib-2.0"
+
+inherit autotools pkgconfig
+
+EXTRA_OECONF += "ac_cv_prog_EMACS=no"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-devtools/diffstat/diffstat/avoid-check-user-break-cc.patch b/poky/meta/recipes-devtools/diffstat/diffstat/avoid-check-user-break-cc.patch
new file mode 100644
index 0000000..811faa4
--- /dev/null
+++ b/poky/meta/recipes-devtools/diffstat/diffstat/avoid-check-user-break-cc.patch
@@ -0,0 +1,32 @@
+From 1046593aacb74ff888a0d68c0ff89b20c4bc9ed4 Mon Sep 17 00:00:00 2001
+From: Kai Kang <kai.kang@windriver.com>
+Date: Tue, 15 May 2018 17:17:01 +0800
+Subject: [PATCH] diffstat: fix wrong evaluation of CC
+
+Upstream-Status: Inappropriate [oe specific]
+
+m4 function CF_CC_ENV_FLAGS checks whether variable CC contains options '-I', '-U'
+and '-D'. It is not suitable for oe that option such as '-D_FORTIFY_SOURCE=2' may
+be included in CC. And then CC will be wrongly filtered.
+
+So comment out CF_CC_ENV_FLAGS from function CF_PROG_CC.
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+
+---
+ aclocal.m4 | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/aclocal.m4 b/aclocal.m4
+index 9281aa8..dd57b7a 100644
+--- a/aclocal.m4
++++ b/aclocal.m4
+@@ -1239,7 +1239,7 @@ CF_GCC_VERSION
+ CF_ACVERSION_CHECK(2.52,
+ 	[AC_PROG_CC_STDC],
+ 	[CF_ANSI_CC_REQD])
+-CF_CC_ENV_FLAGS
++dnl CF_CC_ENV_FLAGS
+ ])dnl
+ dnl ---------------------------------------------------------------------------
+ dnl CF_PROG_GROFF version: 3 updated: 2018/01/07 13:16:19
diff --git a/poky/meta/recipes-devtools/diffstat/diffstat_1.61.bb b/poky/meta/recipes-devtools/diffstat/diffstat_1.61.bb
deleted file mode 100644
index f8b7b06..0000000
--- a/poky/meta/recipes-devtools/diffstat/diffstat_1.61.bb
+++ /dev/null
@@ -1,27 +0,0 @@
-SUMMARY = "Tool to produce a statistics based on a diff"
-DESCRIPTION = "diffstat reads the output of diff and displays a histogram of \
-the insertions, deletions, and modifications per-file. It is useful for \
-reviewing large, complex patch files."
-HOMEPAGE = "http://invisible-island.net/diffstat/"
-SECTION = "devel"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://install-sh;endline=42;md5=b3549726c1022bee09c174c72a0ca4a5"
-
-SRC_URI = "http://invisible-mirror.net/archives/${BPN}/${BP}.tgz \
-           file://run-ptest \
-"
-
-SRC_URI[md5sum] = "c048a32d55d8bd6724f382baf41f325f"
-SRC_URI[sha256sum] = "25359e0c27183f997b36c9202583b5dc2df390c20e22a92606af4bf7856a55ee"
-
-S = "${WORKDIR}/diffstat-${PV}"
-
-inherit autotools gettext ptest
-
-EXTRA_AUTORECONF += "--exclude=aclocal"
-
-LDFLAGS += "${TOOLCHAIN_OPTIONS}"
-
-do_install_ptest() {
-	cp -r ${S}/testing ${D}${PTEST_PATH}
-}
diff --git a/poky/meta/recipes-devtools/diffstat/diffstat_1.62.bb b/poky/meta/recipes-devtools/diffstat/diffstat_1.62.bb
new file mode 100644
index 0000000..93d7779
--- /dev/null
+++ b/poky/meta/recipes-devtools/diffstat/diffstat_1.62.bb
@@ -0,0 +1,28 @@
+SUMMARY = "Tool to produce a statistics based on a diff"
+DESCRIPTION = "diffstat reads the output of diff and displays a histogram of \
+the insertions, deletions, and modifications per-file. It is useful for \
+reviewing large, complex patch files."
+HOMEPAGE = "http://invisible-island.net/diffstat/"
+SECTION = "devel"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://install-sh;endline=42;md5=b3549726c1022bee09c174c72a0ca4a5"
+
+SRC_URI = "http://invisible-mirror.net/archives/${BPN}/${BP}.tgz \
+           file://run-ptest \
+           file://avoid-check-user-break-cc.patch \
+"
+
+SRC_URI[md5sum] = "91e106bb34cb097750db7ddc0ba1d8fc"
+SRC_URI[sha256sum] = "7f09183644ed77a156b15346bbad4e89c93543e140add9dab18747e30522591f"
+
+S = "${WORKDIR}/diffstat-${PV}"
+
+inherit autotools gettext ptest
+
+EXTRA_AUTORECONF += "--exclude=aclocal"
+
+LDFLAGS += "${TOOLCHAIN_OPTIONS}"
+
+do_install_ptest() {
+	cp -r ${S}/testing ${D}${PTEST_PATH}
+}
diff --git a/poky/meta/recipes-devtools/distcc/distcc_3.2.bb b/poky/meta/recipes-devtools/distcc/distcc_3.2.bb
deleted file mode 100644
index 6604648..0000000
--- a/poky/meta/recipes-devtools/distcc/distcc_3.2.bb
+++ /dev/null
@@ -1,69 +0,0 @@
-SUMMARY = "A parallel build system"
-DESCRIPTION = "distcc is a parallel build system that distributes \
-compilation of C/C++/ObjC code across machines on a network."
-SECTION = "devel"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
-
-DEPENDS = "avahi binutils"
-
-PACKAGECONFIG ??= "popt"
-PACKAGECONFIG[gtk] = "--with-gtk,--without-gtk --without-gnome,gtk+"
-# use system popt by default
-PACKAGECONFIG[popt] = "--without-included-popt,--with-included-popt,popt"
-
-RRECOMMENDS_${PN} = "avahi-daemon"
-
-SRC_URI = "git://github.com/akuster/distcc.git;branch=${PV} \
-           file://separatebuilddir.patch \
-           file://0001-zeroconf-Include-fcntl.h.patch \
-           file://default \
-           file://distccmon-gnome.desktop \
-           file://distcc \
-           file://distcc.service"
-SRCREV = "d8b18df3e9dcbe4f092bed565835d3975e99432c"
-S = "${WORKDIR}/git"
-
-inherit autotools pkgconfig update-rc.d useradd systemd
-
-EXTRA_OECONF += "--disable-Werror PYTHON='' --disable-pump-mode"
-
-USERADD_PACKAGES = "${PN}"
-USERADD_PARAM_${PN} = "--system \
-                       --home /dev/null \
-                       --no-create-home \
-                       --gid nogroup \
-                       distcc"
-
-INITSCRIPT_NAME = "distcc"
-
-SYSTEMD_PACKAGES = "${PN}"
-SYSTEMD_SERVICE_${PN} = "distcc.service"
-
-do_install() {
-    # Improve reproducibility: compress w/o timestamps
-    oe_runmake 'DESTDIR=${D}'  "GZIP_BIN=gzip -n" install
-    install -d ${D}${sysconfdir}/init.d/
-    install -d ${D}${sysconfdir}/default
-    install -m 0755 ${WORKDIR}/distcc ${D}${sysconfdir}/init.d/
-    install -m 0755 ${WORKDIR}/default ${D}${sysconfdir}/default/distcc
-    install -d ${D}${systemd_unitdir}/system/
-    install -m 0644 ${WORKDIR}/distcc.service ${D}${systemd_unitdir}/system
-    sed -i -e 's,@BINDIR@,${bindir},g' ${D}${systemd_unitdir}/system/distcc.service
-    ${DESKTOPINSTALL}
-}
-DESKTOPINSTALL = ""
-DESKTOPINSTALL_libc-glibc () {
-    install -d ${D}${datadir}/distcc/
-    install -m 0644 ${WORKDIR}/distccmon-gnome.desktop ${D}${datadir}/distcc/
-}
-PACKAGES += "distcc-distmon-gnome"
-
-FILES_${PN} = " ${sysconfdir} \
-		${bindir}/distcc \
-    ${bindir}/lsdistcc \
-		${bindir}/distccd \
-		${bindir}/distccmon-text \
-		${systemd_unitdir}/system/distcc.service"
-FILES_distcc-distmon-gnome = "  ${bindir}/distccmon-gnome \
-				${datadir}/distcc"
diff --git a/poky/meta/recipes-devtools/distcc/distcc_3.3.2.bb b/poky/meta/recipes-devtools/distcc/distcc_3.3.2.bb
new file mode 100644
index 0000000..0d06963
--- /dev/null
+++ b/poky/meta/recipes-devtools/distcc/distcc_3.3.2.bb
@@ -0,0 +1,71 @@
+SUMMARY = "A parallel build system"
+DESCRIPTION = "distcc is a parallel build system that distributes \
+compilation of C/C++/ObjC code across machines on a network."
+SECTION = "devel"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+
+DEPENDS = "avahi binutils"
+
+PACKAGECONFIG ??= "popt"
+PACKAGECONFIG[gtk] = "--with-gtk,--without-gtk --without-gnome,gtk+"
+# use system popt by default
+PACKAGECONFIG[popt] = "--without-included-popt,--with-included-popt,popt"
+
+RRECOMMENDS_${PN} = "avahi-daemon"
+
+SRC_URI = "git://github.com/distcc/distcc.git \
+           file://separatebuilddir.patch \
+           file://default \
+           file://distccmon-gnome.desktop \
+           file://distcc \
+           file://distcc.service"
+SRCREV = "8600f0857dac55ea393dc11a860948692d215fc8"
+S = "${WORKDIR}/git"
+
+inherit autotools pkgconfig update-rc.d useradd systemd
+
+ASNEEDED = ""
+
+EXTRA_OECONF += "--disable-Werror PYTHON='' --disable-pump-mode"
+
+USERADD_PACKAGES = "${PN}"
+USERADD_PARAM_${PN} = "--system \
+                       --home /dev/null \
+                       --no-create-home \
+                       --gid nogroup \
+                       distcc"
+
+INITSCRIPT_NAME = "distcc"
+
+SYSTEMD_PACKAGES = "${PN}"
+SYSTEMD_SERVICE_${PN} = "distcc.service"
+
+do_install() {
+    # Improve reproducibility: compress w/o timestamps
+    oe_runmake 'DESTDIR=${D}'  "GZIP_BIN=gzip -n" install
+    install -d ${D}${sysconfdir}/init.d/
+    install -d ${D}${sysconfdir}/default
+    install -m 0755 ${WORKDIR}/distcc ${D}${sysconfdir}/init.d/
+    install -m 0755 ${WORKDIR}/default ${D}${sysconfdir}/default/distcc
+    install -d ${D}${systemd_unitdir}/system/
+    install -m 0644 ${WORKDIR}/distcc.service ${D}${systemd_unitdir}/system
+    sed -i -e 's,@BINDIR@,${bindir},g' ${D}${systemd_unitdir}/system/distcc.service
+    ${DESKTOPINSTALL}
+}
+DESKTOPINSTALL = ""
+DESKTOPINSTALL_libc-glibc () {
+    install -d ${D}${datadir}/distcc/
+    install -m 0644 ${WORKDIR}/distccmon-gnome.desktop ${D}${datadir}/distcc/
+}
+PACKAGES += "distcc-distmon-gnome"
+
+FILES_${PN} = " ${sysconfdir} \
+		${bindir}/distcc \
+		${bindir}/lsdistcc \
+		${bindir}/distccd \
+		${bindir}/distccmon-text \
+		${sbindir}/update-distcc-symlinks \
+		${systemd_unitdir}/system/distcc.service"
+FILES_distcc-distmon-gnome = "  ${bindir}/distccmon-gnome \
+				${datadir}/distcc"
diff --git a/poky/meta/recipes-devtools/distcc/files/0001-zeroconf-Include-fcntl.h.patch b/poky/meta/recipes-devtools/distcc/files/0001-zeroconf-Include-fcntl.h.patch
deleted file mode 100644
index b17ec9c..0000000
--- a/poky/meta/recipes-devtools/distcc/files/0001-zeroconf-Include-fcntl.h.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From 8331fc4759d809512f404e7a27f817ad6d616450 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 13 Apr 2015 18:00:33 -0700
-Subject: [PATCH] zeroconf: Include fcntl.h
-
-We need it for getting deinitions for O_* e.g. O_CREAT
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/zeroconf.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/src/zeroconf.c b/src/zeroconf.c
-index 414ddc4..31bd33f 100644
---- a/src/zeroconf.c
-+++ b/src/zeroconf.c
-@@ -33,6 +33,7 @@
- #include <unistd.h>
- #include <stdlib.h>
- #include <limits.h>
-+#include <fcntl.h>
- 
- #include <avahi-common/domain.h>
- #include <avahi-common/error.h>
--- 
-2.1.4
-
diff --git a/poky/meta/recipes-devtools/distcc/files/default b/poky/meta/recipes-devtools/distcc/files/default
index 63c4159..e5ca68b 100644
--- a/poky/meta/recipes-devtools/distcc/files/default
+++ b/poky/meta/recipes-devtools/distcc/files/default
@@ -16,9 +16,9 @@
 #
 # ALLOWEDNETS="127.0.0.1"
 
-ALLOWEDNETS="192.168.7.0/24"
+ALLOWEDNETS="127.0.0.1"
 
 #
 # OPTIONS is used for the systemd service file
 #
-OPTIONS="--allow 192.168.7.0/24"
+OPTIONS="--allow 127.0.0.1 --make-me-a-botnet"
diff --git a/poky/meta/recipes-devtools/dmidecode/dmidecode_3.1.bb b/poky/meta/recipes-devtools/dmidecode/dmidecode_3.1.bb
index f83281e..b423fda 100644
--- a/poky/meta/recipes-devtools/dmidecode/dmidecode_3.1.bb
+++ b/poky/meta/recipes-devtools/dmidecode/dmidecode_3.1.bb
@@ -9,6 +9,10 @@
 
 EXTRA_OEMAKE = "-e MAKEFLAGS="
 
+# The upstream buildsystem uses 'docdir' as the path where it puts AUTHORS,
+# README, etc, but we don't want those in the root of our docdir.
+docdir .= "/${BPN}"
+
 do_install() {
 	oe_runmake DESTDIR="${D}" install
 }
diff --git a/poky/meta/recipes-devtools/dnf/dnf_2.7.5.bb b/poky/meta/recipes-devtools/dnf/dnf_2.7.5.bb
index b88ddb4..df60d73 100644
--- a/poky/meta/recipes-devtools/dnf/dnf_2.7.5.bb
+++ b/poky/meta/recipes-devtools/dnf/dnf_2.7.5.bb
@@ -72,3 +72,4 @@
                          dnf-automatic-install.service dnf-automatic-install.timer \
                          dnf-automatic-notifyonly.service dnf-automatic-notifyonly.timer \
 "
+SYSTEMD_AUTO_ENABLE ?= "disable"
diff --git a/poky/meta/recipes-devtools/dwarfsrcfiles/dwarfsrcfiles.bb b/poky/meta/recipes-devtools/dwarfsrcfiles/dwarfsrcfiles.bb
index c59a006..2c843a9 100644
--- a/poky/meta/recipes-devtools/dwarfsrcfiles/dwarfsrcfiles.bb
+++ b/poky/meta/recipes-devtools/dwarfsrcfiles/dwarfsrcfiles.bb
@@ -1,4 +1,4 @@
-SUMMARY = "A small utility for printing debig source file locations embedded in binaries"
+SUMMARY = "A small utility for printing debug source file locations embedded in binaries"
 LICENSE = "GPLv2+"
 LIC_FILES_CHKSUM = "file://../dwarfsrcfiles.c;md5=31483894e453a77acbb67847565f1b5c;beginline=1;endline=8"
 
diff --git a/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc b/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc
index 81d90a1..a54a11c 100644
--- a/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc
+++ b/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc
@@ -9,7 +9,7 @@
 LICENSE_e2fsprogs-fsck = "GPLv2"
 LICENSE_e2fsprogs-tune2fs = "GPLv2"
 LICENSE_e2fsprogs-badblocks = "GPLv2"
-LIC_FILES_CHKSUM = "file://NOTICE;md5=b48f21d765b875bd10400975d12c1ca2 \
+LIC_FILES_CHKSUM = "file://NOTICE;md5=d50be0580c0b0a7fbc7a4830bbe6c12b \
                       file://lib/ext2fs/ext2fs.h;beginline=1;endline=9;md5=596a8dedcb4e731c6b21c7a46fba6bef \
                       file://lib/e2p/e2p.h;beginline=1;endline=7;md5=8a74ade8f9d65095d70ef2d4bf48e36a \
                       file://lib/uuid/uuid.h.in;beginline=1;endline=32;md5=dbb8079e114a5f841934b99e59c8820a \
diff --git a/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0001-libext2fs-fix-build-failure-in-swapfs.c-on-big-endia.patch b/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0001-libext2fs-fix-build-failure-in-swapfs.c-on-big-endia.patch
deleted file mode 100644
index ff1284e..0000000
--- a/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0001-libext2fs-fix-build-failure-in-swapfs.c-on-big-endia.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From ae6603206176b771c9ed1f82569f68fc1257f014 Mon Sep 17 00:00:00 2001
-From: Theodore Ts'o <tytso@mit.edu>
-Date: Wed, 3 Jan 2018 01:32:02 -0500
-Subject: [PATCH] libext2fs: fix build failure in swapfs.c on big-endian
- systems
-
-Addresses-Debian-Bug: #886119
-
-Reported-by: James Clarke <jrtc27@debian.org>
-Signed-off-by: Theodore Ts'o <tytso@mit.edu>
----
-Upstream-Status: Backport
-
- lib/ext2fs/swapfs.c | 3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
-diff --git a/lib/ext2fs/swapfs.c b/lib/ext2fs/swapfs.c
-index 6e5cff97..b13dc422 100644
---- a/lib/ext2fs/swapfs.c
-+++ b/lib/ext2fs/swapfs.c
-@@ -19,6 +19,7 @@
- 
- #include "ext2_fs.h"
- #include "ext2fs.h"
-+#include "ext2fsP.h"
- #include <ext2fs/ext2_ext_attr.h>
- 
- #ifdef WORDS_BIGENDIAN
-@@ -358,7 +359,7 @@ void ext2fs_swap_inode_full(ext2_filsys fs, struct ext2_inode_large *t,
- 	if (inode_includes(inode_size, i_projid))
-                 t->i_projid = ext2fs_swab16(f->i_projid);
- 	/* catch new static fields added after i_projid */
--	EXT2FS_BUILD_BUG_ON(sizeof(ext2_inode_large) != 160);
-+	EXT2FS_BUILD_BUG_ON(sizeof(struct ext2_inode_large) != 160);
- 
- 	i = sizeof(struct ext2_inode) + extra_isize + sizeof(__u32);
- 	if (bufsize < (int) i)
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/Revert-mke2fs-enable-the-metadata_csum-and-64bit-fea.patch b/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/Revert-mke2fs-enable-the-metadata_csum-and-64bit-fea.patch
index 38e1bdb..d7e09b6 100644
--- a/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/Revert-mke2fs-enable-the-metadata_csum-and-64bit-fea.patch
+++ b/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/Revert-mke2fs-enable-the-metadata_csum-and-64bit-fea.patch
@@ -19,16 +19,16 @@
  misc/mke2fs.conf.in | 3 ++-
  1 file changed, 2 insertions(+), 1 deletion(-)
 
-Index: git/misc/mke2fs.conf.in
-===================================================================
---- git.orig/misc/mke2fs.conf.in
-+++ git/misc/mke2fs.conf.in
+diff --git a/misc/mke2fs.conf.in b/misc/mke2fs.conf.in
+index 01e35cf..25105b3 100644
+--- a/misc/mke2fs.conf.in
++++ b/misc/mke2fs.conf.in
 @@ -11,8 +11,9 @@
  		features = has_journal
  	}
  	ext4 = {
--		features = has_journal,extent,huge_file,flex_bg,uninit_bg,64bit,dir_nlink,extra_isize
-+		features = has_journal,extent,huge_file,flex_bg,uninit_bg,dir_nlink,extra_isize
+-		features = has_journal,extent,huge_file,flex_bg,metadata_csum,64bit,dir_nlink,extra_isize
++		features = has_journal,extent,huge_file,flex_bg,metadata_csum,dir_nlink,extra_isize
  		inode_size = 256
 +		auto_64-bit_support = 1
  	}
diff --git a/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/ptest.patch b/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/ptest.patch
index 7c4bb39..4e6b629 100644
--- a/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/ptest.patch
+++ b/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/ptest.patch
@@ -1,10 +1,21 @@
+From b8842065ad621a03a971dfd50db862c5bffdeb49 Mon Sep 17 00:00:00 2001
+From: Dmitry Eremin-Solenikov <dmitry_eremin@mentor.com>
+Date: Sat, 18 Apr 2015 17:58:17 +0300
+Subject: [PATCH] e2fsprogs: add ptest
+
 Upstream-Status: Inappropriate
 
-Index: git/tests/Makefile.in
-===================================================================
---- git.orig/tests/Makefile.in
-+++ git/tests/Makefile.in
-@@ -18,7 +18,7 @@ test_one: $(srcdir)/test_one.in Makefile
+---
+ tests/Makefile.in    |  4 ++--
+ tests/test_config    | 32 ++++++++++++++++----------------
+ tests/test_script.in |  2 +-
+ 3 files changed, 19 insertions(+), 19 deletions(-)
+
+diff --git a/tests/Makefile.in b/tests/Makefile.in
+index 8c4d2048..e021af32 100644
+--- a/tests/Makefile.in
++++ b/tests/Makefile.in
+@@ -19,7 +19,7 @@ test_one: $(srcdir)/test_one.in Makefile mke2fs.conf
  	@echo "#!/bin/sh" > test_one
  	@echo "HTREE=y" >> test_one
  	@echo "QUOTA=y" >> test_one
@@ -13,20 +24,20 @@
  	@echo "DIFF_OPTS=@UNI_DIFF_OPTS@" >> test_one
  	@echo "SIZEOF_TIME_T=@SIZEOF_TIME_T@" >> test_one
  	@echo "DD=@DD@" >>test_one
-@@ -28,7 +28,7 @@ test_one: $(srcdir)/test_one.in Makefile
- test_script: test_one test_script.in Makefile mke2fs.conf
+@@ -30,7 +30,7 @@ test_script: test_one test_script.in Makefile mke2fs.conf
  	@echo "Creating test_script..."
+ 	@[ -f test_script ] && chmod u+w test_script || true
  	@echo "#!/bin/sh" > test_script
 -	@echo "SRCDIR=@srcdir@" >> test_script
 +	@echo "SRCDIR=${prefix}${libdir}/e2fsprogs/ptest/test" >> test_script
  	@cat $(srcdir)/test_script.in >> test_script
- 	@chmod +x test_script
+ 	@chmod +x-w test_script
  
-Index: git/tests/test_config
-===================================================================
---- git.orig/tests/test_config
-+++ git/tests/test_config
-@@ -3,24 +3,24 @@
+diff --git a/tests/test_config b/tests/test_config
+index 1f146ca2..05125f9c 100644
+--- a/tests/test_config
++++ b/tests/test_config
+@@ -3,16 +3,16 @@
  #
  
  unset LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER LC_TELEPHONE LC_TIME PAGER
@@ -40,8 +51,6 @@
 -E2IMAGE_EXE="../misc/e2image"
 -DEBUGFS="$USE_VALGRIND ../debugfs/debugfs"
 -DEBUGFS_EXE="../debugfs/debugfs"
--TEST_BITS="../debugfs/debugfs"
--RESIZE2FS_EXE="../resize/resize2fs"
 +FSCK="$USE_VALGRIND e2fsck"
 +MKE2FS="$USE_VALGRIND mke2fs"
 +DUMPE2FS="$USE_VALGRIND dumpe2fs"
@@ -52,25 +61,34 @@
 +E2IMAGE_EXE="/sbin/e2image"
 +DEBUGFS="$USE_VALGRIND debugfs"
 +DEBUGFS_EXE="/sbin/debugfs"
-+TEST_BITS="/sbin/debugfs"
+ TEST_BITS="test_data.tmp"
+ if [ ! -s $TEST_BITS ]; then
+ 	# create a non-sparse test file if possible, since debugfs may be
+@@ -21,14 +21,14 @@ if [ ! -s $TEST_BITS ]; then
+ 	dd if=/dev/urandom of=$TEST_BITS bs=128k count=1 > /dev/null 2>&1 ||
+ 		TEST_BITS="$DEFBUGFS_EXE"
+ fi
+-RESIZE2FS_EXE="../resize/resize2fs"
 +RESIZE2FS_EXE="/sbin/resize2fs"
  RESIZE2FS="$USE_VALGRIND $RESIZE2FS_EXE"
 -E2UNDO_EXE="../misc/e2undo"
 +E2UNDO_EXE="/sbin/e2undo"
  E2UNDO="$USE_VALGRIND $E2UNDO_EXE"
+-E2MMPSTATUS="$USE_VALGRIND ../misc/dumpe2fs -m"
 -TEST_REL=../tests/progs/test_rel
 -TEST_ICOUNT=../tests/progs/test_icount
 -CRCSUM=../tests/progs/crcsum
++E2MMPSTATUS="$USE_VALGRIND dumpe2fs -m"
 +TEST_REL=./progs/test_rel
 +TEST_ICOUNT=./progs/test_icount
 +CRCSUM=./progs/crcsum
  CLEAN_OUTPUT="sed -f $cmd_dir/filter.sed"
  LD_LIBRARY_PATH=../lib:../lib/ext2fs:../lib/e2p:../lib/et:../lib/ss:${LD_LIBRARY_PATH}
  DYLD_LIBRARY_PATH=../lib:../lib/ext2fs:../lib/e2p:../lib/et:../lib/ss:${DYLD_LIBRARY_PATH}
-Index: git/tests/test_script.in
-===================================================================
---- git.orig/tests/test_script.in
-+++ git/tests/test_script.in
+diff --git a/tests/test_script.in b/tests/test_script.in
+index 9959e308..442999db 100644
+--- a/tests/test_script.in
++++ b/tests/test_script.in
 @@ -39,7 +39,7 @@ for i; do
  done
  
diff --git a/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.8.bb b/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.8.bb
deleted file mode 100644
index 56abb3b..0000000
--- a/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.8.bb
+++ /dev/null
@@ -1,120 +0,0 @@
-require e2fsprogs.inc
-
-SRC_URI += "file://remove.ldconfig.call.patch \
-            file://run-ptest \
-            file://ptest.patch \
-            file://Revert-mke2fs-enable-the-metadata_csum-and-64bit-fea.patch \
-            file://mkdir_p.patch \
-            file://0001-misc-create_inode.c-set-dir-s-mode-correctly.patch \
-            file://0001-libext2fs-fix-build-failure-in-swapfs.c-on-big-endia.patch \
-            "
-
-SRC_URI_append_class-native = " file://e2fsprogs-fix-missing-check-for-permission-denied.patch \
-                                file://quiet-debugfs.patch \
-"
-
-SRCREV = "af2eac481cf426c05ae12b946396980e16c8ab19"
-UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+\.\d+(\.\d+)*)$"
-
-EXTRA_OECONF += "--libdir=${base_libdir} --sbindir=${base_sbindir} \
-                --enable-elf-shlibs --disable-libuuid --disable-uuidd \
-                --disable-libblkid --enable-verbose-makecmds"
-
-EXTRA_OECONF_darwin = "--libdir=${base_libdir} --sbindir=${base_sbindir} --enable-bsd-shlibs"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[fuse] = '--enable-fuse2fs,--disable-fuse2fs,fuse'
-
-# make locale rules sometimes fire, sometimes don't as git doesn't preserve
-# file mktime. Touch the files introducing non-determinism to the build
-do_compile_prepend (){
-	find ${S}/po -type f -name "*.po" -exec touch {} +
-}
-
-do_install () {
-	oe_runmake 'DESTDIR=${D}' install
-	oe_runmake 'DESTDIR=${D}' install-libs
-	# We use blkid from util-linux now so remove from here
-	rm -f ${D}${base_libdir}/libblkid*
-	rm -rf ${D}${includedir}/blkid
-	rm -f ${D}${base_libdir}/pkgconfig/blkid.pc
-	rm -f ${D}${base_sbindir}/blkid
-	rm -f ${D}${base_sbindir}/fsck
-	rm -f ${D}${base_sbindir}/findfs
-
-	# e2initrd_helper and the pkgconfig files belong in libdir
-	if [ ! ${D}${libdir} -ef ${D}${base_libdir} ]; then
-		install -d ${D}${libdir}
-		mv ${D}${base_libdir}/e2initrd_helper ${D}${libdir}
-		mv ${D}${base_libdir}/pkgconfig ${D}${libdir}
-	fi
-
-	oe_multilib_header ext2fs/ext2_types.h
-	install -d ${D}${base_bindir}
-	mv ${D}${bindir}/chattr ${D}${base_bindir}/chattr.e2fsprogs
-
-	install -v -m 755 ${S}/contrib/populate-extfs.sh ${D}${base_sbindir}/
-
-	# Clean host path (build directory) in compile_et, mk_cmds
-	sed -i -e "s,\(ET_DIR=.*\)${S}/lib/et\(.*\),\1${datadir}/et\2,g" ${D}${bindir}/compile_et
-	sed -i -e "s,\(SS_DIR=.*\)${S}/lib/ss\(.*\),\1${datadir}/ss\2,g" ${D}${bindir}/mk_cmds
-}
-
-# Need to find the right mke2fs.conf file
-e2fsprogs_conf_fixup () {
-	for i in mke2fs mkfs.ext2 mkfs.ext3 mkfs.ext4; do
-		create_wrapper ${D}${base_sbindir}/$i MKE2FS_CONFIG=${sysconfdir}/mke2fs.conf
-	done
-}
-
-do_install_append_class-native() {
-	e2fsprogs_conf_fixup
-}
-
-do_install_append_class-nativesdk() {
-	e2fsprogs_conf_fixup
-}
-
-RDEPENDS_e2fsprogs = "e2fsprogs-badblocks"
-RRECOMMENDS_e2fsprogs = "e2fsprogs-mke2fs e2fsprogs-e2fsck"
-
-PACKAGES =+ "e2fsprogs-e2fsck e2fsprogs-mke2fs e2fsprogs-tune2fs e2fsprogs-badblocks e2fsprogs-resize2fs"
-PACKAGES =+ "libcomerr libss libe2p libext2fs"
-
-FILES_e2fsprogs-resize2fs = "${base_sbindir}/resize2fs*"
-FILES_e2fsprogs-e2fsck = "${base_sbindir}/e2fsck ${base_sbindir}/fsck.ext*"
-FILES_e2fsprogs-mke2fs = "${base_sbindir}/mke2fs ${base_sbindir}/mkfs.ext* ${sysconfdir}/mke2fs.conf"
-FILES_e2fsprogs-tune2fs = "${base_sbindir}/tune2fs ${base_sbindir}/e2label"
-FILES_e2fsprogs-badblocks = "${base_sbindir}/badblocks"
-FILES_libcomerr = "${base_libdir}/libcom_err.so.*"
-FILES_libss = "${base_libdir}/libss.so.*"
-FILES_libe2p = "${base_libdir}/libe2p.so.*"
-FILES_libext2fs = "${libdir}/e2initrd_helper ${base_libdir}/libext2fs.so.*"
-FILES_${PN}-dev += "${datadir}/*/*.awk ${datadir}/*/*.sed ${base_libdir}/*.so ${bindir}/compile_et ${bindir}/mk_cmds"
-
-ALTERNATIVE_${PN} = "chattr"
-ALTERNATIVE_PRIORITY = "100"
-ALTERNATIVE_LINK_NAME[chattr] = "${base_bindir}/chattr"
-ALTERNATIVE_TARGET[chattr] = "${base_bindir}/chattr.e2fsprogs"
-
-ALTERNATIVE_${PN}-doc = "fsck.8"
-ALTERNATIVE_LINK_NAME[fsck.8] = "${mandir}/man8/fsck.8"
-
-RDEPENDS_${PN}-ptest += "${PN} ${PN}-tune2fs coreutils procps bash"
-
-do_compile_ptest() {
-	oe_runmake -C ${B}/tests
-}
-
-do_install_ptest() {
-	cp -R --no-dereference --preserve=mode,links -v ${B}/tests ${D}${PTEST_PATH}/test
-	cp -R --no-dereference --preserve=mode,links -v ${S}/tests/* ${D}${PTEST_PATH}/test
-	sed -e 's!../e2fsck/e2fsck!e2fsck!g' \
-	    -e 's!../misc/tune2fs!tune2fs!g' -i ${D}${PTEST_PATH}/test/*/expect*
-	sed -e 's!../e2fsck/e2fsck!${base_sbindir}/e2fsck!g' -i ${D}${PTEST_PATH}/test/*/script
-
-	# Remove various files
-	find "${D}${PTEST_PATH}" -type f \
-	    \( -name 'Makefile' -o -name 'Makefile.in' -o -name '*.o' -o -name '*.c' -o -name '*.h' \)\
-	    -exec  rm -f {} +
-}
diff --git a/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.44.3.bb b/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.44.3.bb
new file mode 100644
index 0000000..ce95dec
--- /dev/null
+++ b/poky/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.44.3.bb
@@ -0,0 +1,135 @@
+require e2fsprogs.inc
+
+SRC_URI += "file://remove.ldconfig.call.patch \
+            file://run-ptest \
+            file://ptest.patch \
+            file://Revert-mke2fs-enable-the-metadata_csum-and-64bit-fea.patch \
+            file://mkdir_p.patch \
+            file://0001-misc-create_inode.c-set-dir-s-mode-correctly.patch \
+            "
+
+SRC_URI_append_class-native = " file://e2fsprogs-fix-missing-check-for-permission-denied.patch \
+                                file://quiet-debugfs.patch \
+"
+
+SRCREV = "85e53f42f98d5334914de01e972e9ed44bccd0a5"
+UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+\.\d+(\.\d+)*)$"
+
+EXTRA_OECONF += "--libdir=${base_libdir} --sbindir=${base_sbindir} \
+                --enable-elf-shlibs --disable-libuuid --disable-uuidd \
+                --disable-libblkid --enable-verbose-makecmds"
+
+EXTRA_OECONF_darwin = "--libdir=${base_libdir} --sbindir=${base_sbindir} --enable-bsd-shlibs"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[fuse] = '--enable-fuse2fs,--disable-fuse2fs,fuse'
+
+# make locale rules sometimes fire, sometimes don't as git doesn't preserve
+# file mktime. Touch the files introducing non-determinism to the build
+do_compile_prepend (){
+	find ${S}/po -type f -name "*.po" -exec touch {} +
+}
+
+do_install () {
+	oe_runmake 'DESTDIR=${D}' install
+	oe_runmake 'DESTDIR=${D}' install-libs
+	# We use blkid from util-linux now so remove from here
+	rm -f ${D}${base_libdir}/libblkid*
+	rm -rf ${D}${includedir}/blkid
+	rm -f ${D}${base_libdir}/pkgconfig/blkid.pc
+	rm -f ${D}${base_sbindir}/blkid
+	rm -f ${D}${base_sbindir}/fsck
+	rm -f ${D}${base_sbindir}/findfs
+
+	# e2initrd_helper and the pkgconfig files belong in libdir
+	if [ ! ${D}${libdir} -ef ${D}${base_libdir} ]; then
+		install -d ${D}${libdir}
+		mv ${D}${base_libdir}/e2initrd_helper ${D}${libdir}
+		mv ${D}${base_libdir}/pkgconfig ${D}${libdir}
+	fi
+
+	oe_multilib_header ext2fs/ext2_types.h
+	install -d ${D}${base_bindir}
+	mv ${D}${bindir}/chattr ${D}${base_bindir}/chattr.e2fsprogs
+
+	install -v -m 755 ${S}/contrib/populate-extfs.sh ${D}${base_sbindir}/
+
+	# Clean host path (build directory) in compile_et, mk_cmds
+	sed -i -e "s,\(ET_DIR=.*\)${S}/lib/et\(.*\),\1${datadir}/et\2,g" ${D}${bindir}/compile_et
+	sed -i -e "s,\(SS_DIR=.*\)${S}/lib/ss\(.*\),\1${datadir}/ss\2,g" ${D}${bindir}/mk_cmds
+}
+
+# Need to find the right mke2fs.conf file
+e2fsprogs_conf_fixup () {
+	for i in mke2fs mkfs.ext2 mkfs.ext3 mkfs.ext4; do
+		create_wrapper ${D}${base_sbindir}/$i MKE2FS_CONFIG=${sysconfdir}/mke2fs.conf
+	done
+}
+
+do_install_append_class-native() {
+	e2fsprogs_conf_fixup
+}
+
+do_install_append_class-nativesdk() {
+	e2fsprogs_conf_fixup
+}
+
+do_install_append_class-target() {
+	mv ${D}${base_sbindir}/mke2fs ${D}${base_sbindir}/mke2fs.e2fsprogs
+	mv ${D}${base_sbindir}/mkfs.ext2 ${D}${base_sbindir}/mkfs.ext2.e2fsprogs
+	mv ${D}${base_sbindir}/tune2fs ${D}${base_sbindir}/tune2fs.e2fsprogs
+}
+
+RDEPENDS_e2fsprogs = "e2fsprogs-badblocks"
+RRECOMMENDS_e2fsprogs = "e2fsprogs-mke2fs e2fsprogs-e2fsck"
+
+PACKAGES =+ "e2fsprogs-e2fsck e2fsprogs-mke2fs e2fsprogs-tune2fs e2fsprogs-badblocks e2fsprogs-resize2fs"
+PACKAGES =+ "libcomerr libss libe2p libext2fs"
+
+FILES_e2fsprogs-resize2fs = "${base_sbindir}/resize2fs*"
+FILES_e2fsprogs-e2fsck = "${base_sbindir}/e2fsck ${base_sbindir}/fsck.ext*"
+FILES_e2fsprogs-mke2fs = "${base_sbindir}/mke2fs.e2fsprogs ${base_sbindir}/mkfs.ext* ${sysconfdir}/mke2fs.conf"
+FILES_e2fsprogs-tune2fs = "${base_sbindir}/tune2fs.e2fsprogs ${base_sbindir}/e2label"
+FILES_e2fsprogs-badblocks = "${base_sbindir}/badblocks"
+FILES_libcomerr = "${base_libdir}/libcom_err.so.*"
+FILES_libss = "${base_libdir}/libss.so.*"
+FILES_libe2p = "${base_libdir}/libe2p.so.*"
+FILES_libext2fs = "${libdir}/e2initrd_helper ${base_libdir}/libext2fs.so.*"
+FILES_${PN}-dev += "${datadir}/*/*.awk ${datadir}/*/*.sed ${base_libdir}/*.so ${bindir}/compile_et ${bindir}/mk_cmds"
+
+ALTERNATIVE_${PN} = "chattr"
+ALTERNATIVE_PRIORITY = "100"
+ALTERNATIVE_LINK_NAME[chattr] = "${base_bindir}/chattr"
+ALTERNATIVE_TARGET[chattr] = "${base_bindir}/chattr.e2fsprogs"
+
+ALTERNATIVE_${PN}-doc = "fsck.8"
+ALTERNATIVE_LINK_NAME[fsck.8] = "${mandir}/man8/fsck.8"
+
+ALTERNATIVE_${PN}-mke2fs = "mke2fs mkfs.ext2"
+ALTERNATIVE_LINK_NAME[mke2fs] = "${base_sbindir}/mke2fs"
+ALTERNATIVE_LINK_NAME[mkfs.ext2] = "${base_sbindir}/mkfs.ext2"
+
+ALTERNATIVE_${PN}-tune2fs = "tune2fs"
+ALTERNATIVE_LINK_NAME[tune2fs] = "${base_sbindir}/tune2fs"
+
+RDEPENDS_${PN}-ptest += "${PN} ${PN}-tune2fs coreutils procps bash bzip2 diffutils perl"
+
+do_compile_ptest() {
+	oe_runmake -C ${B}/tests
+}
+
+do_install_ptest() {
+	cp -R --no-dereference --preserve=mode,links -v ${B}/tests ${D}${PTEST_PATH}/test
+	cp -R --no-dereference --preserve=mode,links -v ${S}/tests/* ${D}${PTEST_PATH}/test
+	sed -e 's!../e2fsck/e2fsck!e2fsck!g' \
+	    -e 's!../misc/tune2fs!tune2fs!g' -i ${D}${PTEST_PATH}/test/*/expect*
+	sed -e 's!../e2fsck/e2fsck!${base_sbindir}/e2fsck!g' -i ${D}${PTEST_PATH}/test/*/script
+
+	# Remove various files
+	find "${D}${PTEST_PATH}" -type f \
+	    \( -name 'Makefile' -o -name 'Makefile.in' -o -name '*.o' -o -name '*.c' -o -name '*.h' \)\
+	    -exec  rm -f {} +
+
+        install -d ${D}${PTEST_PATH}/lib
+        install -m 0644 ${B}/lib/config.h  ${D}${PTEST_PATH}/lib/
+}
diff --git a/poky/meta/recipes-devtools/elfutils/elfutils_0.170.bb b/poky/meta/recipes-devtools/elfutils/elfutils_0.170.bb
deleted file mode 100644
index 14ac22e..0000000
--- a/poky/meta/recipes-devtools/elfutils/elfutils_0.170.bb
+++ /dev/null
@@ -1,70 +0,0 @@
-SUMMARY = "Utilities and libraries for handling compiled object files"
-HOMEPAGE = "https://sourceware.org/elfutils"
-SECTION = "base"
-LICENSE = "(GPLv3 & Elfutils-Exception)"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
-DEPENDS = "libtool bzip2 zlib virtual/libintl"
-DEPENDS_append_libc-musl = " argp-standalone fts "
-# The Debian patches below are from:
-# http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.168-0.2.debian.tar.xz
-SRC_URI = "https://sourceware.org/elfutils/ftp/${PV}/${BP}.tar.bz2 \
-           file://0001-dso-link-change.patch \
-           file://0002-Fix-elf_cvt_gunhash-if-dest-and-src-are-same.patch \
-           file://0003-fixheadercheck.patch \
-           file://0004-Disable-the-test-to-convert-euc-jp.patch \
-           file://0005-fix-a-stack-usage-warning.patch \
-           file://0006-Fix-build-on-aarch64-musl.patch \
-           file://0007-Fix-control-path-where-we-have-str-as-uninitialized-.patch \
-           file://0001-libasm-may-link-with-libbz2-if-found.patch \
-           file://debian/hppa_backend.diff \
-           file://debian/arm_backend.diff \
-           file://debian/mips_backend.patch \
-           file://debian/mips_readelf_w.patch \
-           file://debian/0001-Ignore-differences-between-mips-machine-identifiers.patch \
-           file://debian/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch \
-           file://debian/0003-Add-mips-n64-relocation-format-hack.patch \
-           file://0001-Use-fallthrough-attribute.patch \
-           file://0001-Ensure-that-packed-structs-follow-the-gcc-memory-lay.patch \
-           "
-SRC_URI_append_libc-musl = " file://0008-build-Provide-alternatives-for-glibc-assumptions-hel.patch"
-SRC_URI[md5sum] = "03599aee98c9b726c7a732a2dd0245d5"
-SRC_URI[sha256sum] = "1f844775576b79bdc9f9c717a50058d08620323c1e935458223a12f249c9e066"
-
-inherit autotools gettext
-
-EXTRA_OECONF = "--program-prefix=eu- --without-lzma"
-EXTRA_OECONF_append_class-native = " --without-bzlib"
-
-do_install_append() {
-	if [ "${TARGET_ARCH}" != "x86_64" ] && [ -z `echo "${TARGET_ARCH}"|grep 'i.86'` ];then
-		rm -f ${D}${bindir}/eu-objdump
-	fi
-}
-
-EXTRA_OEMAKE_class-native = ""
-EXTRA_OEMAKE_class-nativesdk = ""
-
-ALLOW_EMPTY_${PN}_libc-musl = "1"
-
-BBCLASSEXTEND = "native nativesdk"
-
-# Package utilities separately
-PACKAGES =+ "${PN}-binutils libelf libasm libdw"
-FILES_${PN}-binutils = "\
-    ${bindir}/eu-addr2line \
-    ${bindir}/eu-ld \
-    ${bindir}/eu-nm \
-    ${bindir}/eu-readelf \
-    ${bindir}/eu-size \
-    ${bindir}/eu-strip"
-
-FILES_libelf = "${libdir}/libelf-${PV}.so ${libdir}/libelf.so.*"
-FILES_libasm = "${libdir}/libasm-${PV}.so ${libdir}/libasm.so.*"
-FILES_libdw  = "${libdir}/libdw-${PV}.so ${libdir}/libdw.so.* ${libdir}/elfutils/lib*"
-# Some packages have the version preceeding the .so instead properly
-# versioned .so.<version>, so we need to reorder and repackage.
-#FILES_${PN} += "${libdir}/*-${PV}.so ${base_libdir}/*-${PV}.so"
-#FILES_SOLIBSDEV = "${libdir}/libasm.so ${libdir}/libdw.so ${libdir}/libelf.so"
-
-# The package contains symlinks that trip up insane
-INSANE_SKIP_${MLPREFIX}libdw = "dev-so"
diff --git a/poky/meta/recipes-devtools/elfutils/elfutils_0.174.bb b/poky/meta/recipes-devtools/elfutils/elfutils_0.174.bb
new file mode 100644
index 0000000..c30265b
--- /dev/null
+++ b/poky/meta/recipes-devtools/elfutils/elfutils_0.174.bb
@@ -0,0 +1,77 @@
+SUMMARY = "Utilities and libraries for handling compiled object files"
+HOMEPAGE = "https://sourceware.org/elfutils"
+SECTION = "base"
+LICENSE = "(GPLv3 & Elfutils-Exception)"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
+DEPENDS = "libtool bzip2 zlib virtual/libintl"
+DEPENDS_append_libc-musl = " argp-standalone fts "
+# The Debian patches below are from:
+# http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz
+SRC_URI = "https://sourceware.org/elfutils/ftp/${PV}/${BP}.tar.bz2 \
+           file://0001-dso-link-change.patch \
+           file://0002-Fix-elf_cvt_gunhash-if-dest-and-src-are-same.patch \
+           file://0003-fixheadercheck.patch \
+           file://0004-Disable-the-test-to-convert-euc-jp.patch \
+           file://0005-fix-a-stack-usage-warning.patch \
+           file://0006-Fix-build-on-aarch64-musl.patch \
+           file://0007-Fix-control-path-where-we-have-str-as-uninitialized-.patch \
+           file://0001-libasm-may-link-with-libbz2-if-found.patch \
+           file://0001-libelf-elf_end.c-check-data_list.data.d.d_buf-before.patch \
+           file://0001-libdwfl-Sanity-check-partial-core-file-data-reads.patch \
+           file://0001-size-Handle-recursive-ELF-ar-files.patch \
+           file://0001-arlib-Check-that-sh_entsize-isn-t-zero.patch \
+           file://debian/0001-hppa_backend.patch \
+           file://debian/0001-arm_backend.patch \
+           file://debian/0001-mips_backend.patch \
+           file://debian/0001-testsuite-ignore-elflint.patch \
+           file://debian/0001-mips_readelf_w.patch \
+           file://debian/0001-Ignore-differences-between-mips-machine-identifiers.patch \
+           file://debian/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch \
+           file://debian/0003-Add-mips-n64-relocation-format-hack.patch \
+           file://debian/ignore_strmerge.diff \
+           file://debian/0001-fix-gcc7-ftbfs.patch \
+           file://debian/0001-disable_werror.patch \
+           "
+SRC_URI_append_libc-musl = " file://0008-build-Provide-alternatives-for-glibc-assumptions-hel.patch"
+
+SRC_URI[md5sum] = "48bec24c0c8b2c16820326956dff9378"
+SRC_URI[sha256sum] = "cdf27e70076e10a29539d89e367101d516bc4aa11b0d7777fe52139e3fcad08a"
+
+inherit autotools gettext
+
+EXTRA_OECONF = "--program-prefix=eu- --without-lzma"
+EXTRA_OECONF_append_class-native = " --without-bzlib"
+
+do_install_append() {
+	if [ "${TARGET_ARCH}" != "x86_64" ] && [ -z `echo "${TARGET_ARCH}"|grep 'i.86'` ];then
+		rm -f ${D}${bindir}/eu-objdump
+	fi
+}
+
+EXTRA_OEMAKE_class-native = ""
+EXTRA_OEMAKE_class-nativesdk = ""
+
+ALLOW_EMPTY_${PN}_libc-musl = "1"
+
+BBCLASSEXTEND = "native nativesdk"
+
+# Package utilities separately
+PACKAGES =+ "${PN}-binutils libelf libasm libdw"
+FILES_${PN}-binutils = "\
+    ${bindir}/eu-addr2line \
+    ${bindir}/eu-ld \
+    ${bindir}/eu-nm \
+    ${bindir}/eu-readelf \
+    ${bindir}/eu-size \
+    ${bindir}/eu-strip"
+
+FILES_libelf = "${libdir}/libelf-${PV}.so ${libdir}/libelf.so.*"
+FILES_libasm = "${libdir}/libasm-${PV}.so ${libdir}/libasm.so.*"
+FILES_libdw  = "${libdir}/libdw-${PV}.so ${libdir}/libdw.so.* ${libdir}/elfutils/lib*"
+# Some packages have the version preceeding the .so instead properly
+# versioned .so.<version>, so we need to reorder and repackage.
+#FILES_${PN} += "${libdir}/*-${PV}.so ${base_libdir}/*-${PV}.so"
+#FILES_SOLIBSDEV = "${libdir}/libasm.so ${libdir}/libdw.so ${libdir}/libelf.so"
+
+# The package contains symlinks that trip up insane
+INSANE_SKIP_${MLPREFIX}libdw = "dev-so"
diff --git a/poky/meta/recipes-devtools/elfutils/files/0001-Ensure-that-packed-structs-follow-the-gcc-memory-lay.patch b/poky/meta/recipes-devtools/elfutils/files/0001-Ensure-that-packed-structs-follow-the-gcc-memory-lay.patch
deleted file mode 100644
index cf4d1df..0000000
--- a/poky/meta/recipes-devtools/elfutils/files/0001-Ensure-that-packed-structs-follow-the-gcc-memory-lay.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From 732913a8c35c7b25c0cbf6903cab1ad6b602b525 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 22 Mar 2018 22:44:03 -0700
-Subject: [PATCH] Ensure that packed structs follow the gcc memory layout
-
-Partial backport of
-https://sourceware.org/git/?p=elfutils.git;a=commit;h=17d7194d291bf91d130b78e06cbe27b290e0376d
-
-Helps fixing alignment errors e.g.
-linux-core-note.c:116:1: error: alignment 2 of 'struct m68k_prstatus
-' is less than 4 [-Werror=packed-not-aligned]
- ;
- ^
-
-Upstream-Status: Backport [https://sourceware.org/git/?p=elfutils.git;a=commit;h=17d7194d291bf91d130b78e06cbe27b290e0376d]
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- backends/linux-core-note.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/backends/linux-core-note.c b/backends/linux-core-note.c
-index 5f06c896..9faae4c3 100644
---- a/backends/linux-core-note.c
-+++ b/backends/linux-core-note.c
-@@ -111,7 +111,7 @@ struct EBLHOOK(prstatus)
-   FIELD (INT, pr_fpvalid);
- }
- #ifdef ALIGN_PRSTATUS
--  __attribute__ ((packed, aligned (ALIGN_PRSTATUS)))
-+  attribute_packed __attribute__ ((aligned (ALIGN_PRSTATUS)))
- #endif
- ;
- 
diff --git a/poky/meta/recipes-devtools/elfutils/files/0001-Use-fallthrough-attribute.patch b/poky/meta/recipes-devtools/elfutils/files/0001-Use-fallthrough-attribute.patch
deleted file mode 100644
index 5e2155b..0000000
--- a/poky/meta/recipes-devtools/elfutils/files/0001-Use-fallthrough-attribute.patch
+++ /dev/null
@@ -1,791 +0,0 @@
-From 5cb883f67d00a63531ef195c242763d36b1905ca Mon Sep 17 00:00:00 2001
-From: Joshua Watt <Joshua.Watt@garmin.com>
-Date: Fri, 9 Feb 2018 12:46:38 -0600
-Subject: [PATCH] Use fallthrough attribute
-
-Use __attribute__ ((fallthrough)) to indicate switch case fall through
-instead of a comment. This ensure that the fallthrough warning is not
-triggered even if the file is pre-processed (hence stripping the
-comments) before it is compiled.
-
-The actual fallback implementation is hidden behind a FALLBACK macro in
-case the compiler doesn't support it.
-
-Finally, the -Wimplict-fallthrough warning was upgraded to only allow
-the attribute to satisfy it; a comment alone is no longer sufficient.
-
-Signed-off-by: Joshua Watt <JPEWhacker@gmail.com>
-
-Upstream-Status: Submitted [1]
-
-[1] https://sourceware.org/ml/elfutils-devel/2018-q1/msg00027.html
----
- backends/aarch64_retval.c    | 2 +-
- backends/alpha_retval.c      | 4 ++--
- backends/arm_regs.c          | 2 +-
- backends/arm_retval.c        | 2 +-
- backends/i386_regs.c         | 2 +-
- backends/i386_retval.c       | 4 ++--
- backends/ia64_retval.c       | 2 +-
- backends/linux-core-note.c   | 2 +-
- backends/m68k_retval.c       | 4 ++--
- backends/mips_retval.c       | 4 ++--
- backends/parisc_retval.c     | 5 +++--
- backends/ppc64_retval.c      | 6 +++---
- backends/ppc_regs.c          | 2 +-
- backends/ppc_retval.c        | 4 ++--
- backends/s390_retval.c       | 4 ++--
- backends/sh_retval.c         | 2 +-
- backends/sparc_retval.c      | 2 +-
- backends/tilegx_retval.c     | 4 ++--
- backends/x86_64_regs.c       | 2 +-
- backends/x86_64_retval.c     | 2 +-
- config/eu.am                 | 4 +++-
- configure.ac                 | 6 ++++++
- lib/eu-config.h              | 7 +++++++
- libcpu/i386_disasm.c         | 2 +-
- libcpu/i386_parse.c          | 4 ++--
- libdw/cfi.c                  | 4 ++--
- libdw/dwarf_frame_register.c | 2 +-
- libdwfl/dwfl_report_elf.c    | 2 +-
- libdwfl/frame_unwind.c       | 2 +-
- libebl/eblobjnote.c          | 2 +-
- libelf/elf32_updatenull.c    | 2 +-
- libelf/elf_begin.c           | 4 ++--
- libelf/elf_cntl.c            | 2 +-
- src/addr2line.c              | 2 +-
- src/elfcompress.c            | 2 +-
- src/elflint.c                | 8 ++++----
- src/objdump.c                | 2 +-
- src/readelf.c                | 8 ++++----
- src/strings.c                | 2 +-
- tests/backtrace.c            | 2 +-
- tests/elfstrmerge.c          | 3 ++-
- 41 files changed, 75 insertions(+), 58 deletions(-)
-
-diff --git a/backends/aarch64_retval.c b/backends/aarch64_retval.c
-index 68de307..1308340 100644
---- a/backends/aarch64_retval.c
-+++ b/backends/aarch64_retval.c
-@@ -292,7 +292,7 @@ aarch64_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  assert (count > 0);
- 	  if (count <= 4)
- 	    return pass_hfa (locp, base_size, count);
--	  /* Fall through.  */
-+	  FALLTHROUGH;
- 
- 	case 1:
- 	  /* Not a HFA.  */
-diff --git a/backends/alpha_retval.c b/backends/alpha_retval.c
-index 53dbfa4..d9bae3b 100644
---- a/backends/alpha_retval.c
-+++ b/backends/alpha_retval.c
-@@ -85,7 +85,7 @@ alpha_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  typedie = dwarf_formref_die (attr, &die_mem);
- 	  tag = DWARF_TAG_OR_RETURN (typedie);
- 	}
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_base_type:
-     case DW_TAG_enumeration_type:
-@@ -131,7 +131,7 @@ alpha_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  }
-       }
- 
--      /* Else fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_structure_type:
-     case DW_TAG_class_type:
-diff --git a/backends/arm_regs.c b/backends/arm_regs.c
-index 4ee1039..418c931 100644
---- a/backends/arm_regs.c
-+++ b/backends/arm_regs.c
-@@ -81,7 +81,7 @@ arm_register_info (Ebl *ebl __attribute__ ((unused)),
-        * but gcc maps FPA registers here
-        */
-       regno += 96 - 16;
--      /* Fall through.  */
-+      FALLTHROUGH;
-     case 96 + 0 ... 96 + 7:
-       *setname = "FPA";
-       *type = DW_ATE_float;
-diff --git a/backends/arm_retval.c b/backends/arm_retval.c
-index 8687eab..313e4eb 100644
---- a/backends/arm_retval.c
-+++ b/backends/arm_retval.c
-@@ -90,7 +90,7 @@ arm_return_value_location_ (Dwarf_Die *functypedie, const Dwarf_Op **locp,
- 	  typedie = dwarf_formref_die (attr, &die_mem);
- 	  tag = DWARF_TAG_OR_RETURN (typedie);
- 	}
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_base_type:
-     case DW_TAG_enumeration_type:
-diff --git a/backends/i386_regs.c b/backends/i386_regs.c
-index fd963a6..7ec93bb 100644
---- a/backends/i386_regs.c
-+++ b/backends/i386_regs.c
-@@ -92,7 +92,7 @@ i386_register_info (Ebl *ebl __attribute__ ((unused)),
-     case 5:
-     case 8:
-       *type = DW_ATE_address;
--      /* Fallthrough */
-+      FALLTHROUGH;
-     case 0 ... 3:
-     case 6 ... 7:
-       name[0] = 'e';
-diff --git a/backends/i386_retval.c b/backends/i386_retval.c
-index 4aa646f..32fec72 100644
---- a/backends/i386_retval.c
-+++ b/backends/i386_retval.c
-@@ -85,7 +85,7 @@ i386_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  typedie = dwarf_formref_die (attr, &die_mem);
- 	  tag = DWARF_TAG_OR_RETURN (typedie);
- 	}
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_base_type:
-     case DW_TAG_enumeration_type:
-@@ -123,7 +123,7 @@ i386_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	if (size <= 8)
- 	  return nloc_intregpair;
-       }
--    /* Fallthrough */
-+    FALLTHROUGH;
- 
-     case DW_TAG_structure_type:
-     case DW_TAG_class_type:
-diff --git a/backends/ia64_retval.c b/backends/ia64_retval.c
-index dcd5f28..03ea4d8 100644
---- a/backends/ia64_retval.c
-+++ b/backends/ia64_retval.c
-@@ -260,7 +260,7 @@ ia64_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  typedie = dwarf_formref_die (attr, &die_mem);
- 	  tag = DWARF_TAG_OR_RETURN (typedie);
- 	}
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_base_type:
-     case DW_TAG_enumeration_type:
-diff --git a/backends/linux-core-note.c b/backends/linux-core-note.c
-index 67638d7..5f06c89 100644
---- a/backends/linux-core-note.c
-+++ b/backends/linux-core-note.c
-@@ -226,7 +226,7 @@ EBLHOOK(core_note) (const GElf_Nhdr *nhdr, const char *name,
-       if (memcmp (name, "CORE", nhdr->n_namesz) == 0)
- 	break;
-       /* Buggy old Linux kernels didn't terminate "LINUX".  */
--      /* Fall through. */
-+      FALLTHROUGH;
- 
-     case sizeof "LINUX":
-       if (memcmp (name, "LINUX", nhdr->n_namesz) == 0)
-diff --git a/backends/m68k_retval.c b/backends/m68k_retval.c
-index c68ed02..a653ba3 100644
---- a/backends/m68k_retval.c
-+++ b/backends/m68k_retval.c
-@@ -92,7 +92,7 @@ m68k_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  typedie = dwarf_formref_die (attr, &die_mem);
- 	  tag = DWARF_TAG_OR_RETURN (typedie);
- 	}
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_base_type:
-     case DW_TAG_enumeration_type:
-@@ -135,7 +135,7 @@ m68k_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	if (size <= 8)
- 	  return nloc_intregpair;
-       }
--      /* Fallthrough */
-+      FALLTHROUGH;
-     case DW_TAG_structure_type:
-     case DW_TAG_class_type:
-     case DW_TAG_union_type:
-diff --git a/backends/mips_retval.c b/backends/mips_retval.c
-index 57487bb..c6e1ffe 100644
---- a/backends/mips_retval.c
-+++ b/backends/mips_retval.c
-@@ -306,7 +306,7 @@ mips_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  typedie = dwarf_formref_die (attr, &die_mem);
- 	  tag = dwarf_tag (typedie);
- 	}
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_base_type:
-     case DW_TAG_enumeration_type:
-@@ -389,7 +389,7 @@ mips_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
-             }
-         }
- 
--      /* Fallthrough to handle large types */
-+      FALLTHROUGH; /* Fallthrough to handle large types */
- 
-     case DW_TAG_array_type:
-     large:
-diff --git a/backends/parisc_retval.c b/backends/parisc_retval.c
-index df7ec3a..1f1e91a 100644
---- a/backends/parisc_retval.c
-+++ b/backends/parisc_retval.c
-@@ -116,7 +116,7 @@ parisc_return_value_location_ (Dwarf_Die *functypedie, const Dwarf_Op **locp, in
- 	  typedie = dwarf_formref_die (attr, &die_mem);
- 	  tag = dwarf_tag (typedie);
- 	}
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_base_type:
-     case DW_TAG_enumeration_type:
-@@ -167,6 +167,7 @@ parisc_return_value_location_ (Dwarf_Die *functypedie, const Dwarf_Op **locp, in
- 
- 	/* Else fall through.  */
-       }
-+      FALLTHROUGH;
- 
-     case DW_TAG_structure_type:
-     case DW_TAG_class_type:
-@@ -189,7 +190,7 @@ parisc_return_value_location_ (Dwarf_Die *functypedie, const Dwarf_Op **locp, in
-         *locp = loc_aggregate;
-         return nloc_aggregate;
- #endif
--	/* fall through.  */
-+	FALLTHROUGH;
-       }
-     }
- 
-diff --git a/backends/ppc64_retval.c b/backends/ppc64_retval.c
-index a251983..eb1c11e 100644
---- a/backends/ppc64_retval.c
-+++ b/backends/ppc64_retval.c
-@@ -96,7 +96,7 @@ ppc64_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  typedie = dwarf_formref_die (attr, &die_mem);
- 	  tag = DWARF_TAG_OR_RETURN (typedie);
- 	}
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_base_type:
-     case DW_TAG_enumeration_type:
-@@ -141,7 +141,7 @@ ppc64_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  return nloc_intreg;
- 	}
- 
--      /* Else fall through.  */
-+      FALLTHROUGH;
-     case DW_TAG_structure_type:
-     case DW_TAG_class_type:
-     case DW_TAG_union_type:
-@@ -161,7 +161,7 @@ ppc64_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	    return nloc_vmxreg;
- 	  }
-       }
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_string_type:
-       if (dwarf_aggregate_size (typedie, &size) == 0 && size <= 8)
-diff --git a/backends/ppc_regs.c b/backends/ppc_regs.c
-index c2d5011..43d2534 100644
---- a/backends/ppc_regs.c
-+++ b/backends/ppc_regs.c
-@@ -140,7 +140,7 @@ ppc_register_info (Ebl *ebl __attribute__ ((unused)),
-     case 100:
-       if (*bits == 32)
- 	return stpcpy (name, "mq") + 1 - name;
--      /* Fallthrough */
-+      FALLTHROUGH;
-     case 102 ... 107:
-       name[0] = 's';
-       name[1] = 'p';
-diff --git a/backends/ppc_retval.c b/backends/ppc_retval.c
-index b14a99f..39b42da 100644
---- a/backends/ppc_retval.c
-+++ b/backends/ppc_retval.c
-@@ -108,7 +108,7 @@ ppc_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  typedie = dwarf_formref_die (attr, &die_mem);
- 	  tag = DWARF_TAG_OR_RETURN (typedie);
- 	}
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_base_type:
-     case DW_TAG_enumeration_type:
-@@ -172,7 +172,7 @@ ppc_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	      return nloc_intregquad;
- 	    }
-       }
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_structure_type:
-     case DW_TAG_class_type:
-diff --git a/backends/s390_retval.c b/backends/s390_retval.c
-index a927d46..2043f98 100644
---- a/backends/s390_retval.c
-+++ b/backends/s390_retval.c
-@@ -87,7 +87,7 @@ s390_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  typedie = dwarf_formref_die (attr, &die_mem);
- 	  tag = DWARF_TAG_OR_RETURN (typedie);
- 	}
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_base_type:
-     case DW_TAG_enumeration_type:
-@@ -127,7 +127,7 @@ s390_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	    return size <= asize ? nloc_intreg : nloc_intregpair;
- 	  }
-       }
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_structure_type:
-     case DW_TAG_class_type:
-diff --git a/backends/sh_retval.c b/backends/sh_retval.c
-index d44f260..33d7d96 100644
---- a/backends/sh_retval.c
-+++ b/backends/sh_retval.c
-@@ -84,7 +84,7 @@ sh_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  typedie = dwarf_formref_die (attr, &die_mem);
- 	  tag = DWARF_TAG_OR_RETURN (typedie);
- 	}
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_base_type:
-     case DW_TAG_enumeration_type:
-diff --git a/backends/sparc_retval.c b/backends/sparc_retval.c
-index e1b1775..fb81cdc 100644
---- a/backends/sparc_retval.c
-+++ b/backends/sparc_retval.c
-@@ -91,7 +91,7 @@ sparc_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  typedie = dwarf_formref_die (attr, &die_mem);
- 	  tag = DWARF_TAG_OR_RETURN (typedie);
- 	}
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_base_type:
-     case DW_TAG_enumeration_type:
-diff --git a/backends/tilegx_retval.c b/backends/tilegx_retval.c
-index db81a20..7f7d24b 100644
---- a/backends/tilegx_retval.c
-+++ b/backends/tilegx_retval.c
-@@ -79,7 +79,7 @@ tilegx_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  typedie = dwarf_formref_die (attr, &die_mem);
- 	  tag = DWARF_TAG_OR_RETURN (typedie);
- 	}
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_base_type:
-     case DW_TAG_enumeration_type:
-@@ -113,7 +113,7 @@ tilegx_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  return nloc_intreg;
- 	}
- 
--      /* Else fall through.  */
-+      FALLTHROUGH;
-     case DW_TAG_structure_type:
-     case DW_TAG_class_type:
-     case DW_TAG_union_type:
-diff --git a/backends/x86_64_regs.c b/backends/x86_64_regs.c
-index 8430440..ef987da 100644
---- a/backends/x86_64_regs.c
-+++ b/backends/x86_64_regs.c
-@@ -87,7 +87,7 @@ x86_64_register_info (Ebl *ebl __attribute__ ((unused)),
- 
-     case 6 ... 7:
-       *type = DW_ATE_address;
--      /* Fallthrough */
-+      FALLTHROUGH;
-     case 0 ... 5:
-       name[0] = 'r';
-       name[1] = baseregs[regno][0];
-diff --git a/backends/x86_64_retval.c b/backends/x86_64_retval.c
-index b3799ae..f9114cb 100644
---- a/backends/x86_64_retval.c
-+++ b/backends/x86_64_retval.c
-@@ -100,7 +100,7 @@ x86_64_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
- 	  typedie = dwarf_formref_die (attr, &die_mem);
- 	  tag = DWARF_TAG_OR_RETURN (typedie);
- 	}
--      /* Fall through.  */
-+      FALLTHROUGH;
- 
-     case DW_TAG_base_type:
-     case DW_TAG_enumeration_type:
-diff --git a/config/eu.am b/config/eu.am
-index 8fe1e25..b6ec581 100644
---- a/config/eu.am
-+++ b/config/eu.am
-@@ -62,7 +62,9 @@ NULL_DEREFERENCE_WARNING=
- endif
- 
- if HAVE_IMPLICIT_FALLTHROUGH_WARNING
--IMPLICIT_FALLTHROUGH_WARNING=-Wimplicit-fallthrough
-+# Use strict fallthrough. Only __attribute__((fallthrough)) will prevent the
-+# warning
-+IMPLICIT_FALLTHROUGH_WARNING=-Wimplicit-fallthrough=5
- else
- IMPLICIT_FALLTHROUGH_WARNING=
- endif
-diff --git a/configure.ac b/configure.ac
-index 1f1856d..698efbb 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -360,6 +360,12 @@ CFLAGS="$old_CFLAGS"])
- AM_CONDITIONAL(HAVE_IMPLICIT_FALLTHROUGH_WARNING,
- 	       [test "x$ac_cv_implicit_fallthrough" != "xno"])
- 
-+# Assume the fallthrough attribute is supported if -Wimplict-fallthrough is supported
-+if test "$ac_cv_implicit_fallthrough" = "yes"; then
-+	AC_DEFINE([HAVE_FALLTHROUGH], [1],
-+		  [Defined if __attribute__((fallthrough)) is supported])
-+fi
-+
- dnl Check if we have argp available from our libc
- AC_LINK_IFELSE(
- 	[AC_LANG_PROGRAM(
-diff --git a/lib/eu-config.h b/lib/eu-config.h
-index 400cdc6..e8d4ec2 100644
---- a/lib/eu-config.h
-+++ b/lib/eu-config.h
-@@ -186,5 +186,12 @@ asm (".section predict_data, \"aw\"; .previous\n"
- # define COMPAT_VERSION(name, version, prefix) error "should use #ifdef SYMBOL_VERSIONING"
- #endif
- 
-+#ifndef FALLTHROUGH
-+# ifdef HAVE_FALLTHROUGH
-+#  define FALLTHROUGH __attribute__ ((fallthrough))
-+# else
-+#  define FALLTHROUGH ((void) 0)
-+# endif
-+#endif
- 
- #endif	/* eu-config.h */
-diff --git a/libcpu/i386_disasm.c b/libcpu/i386_disasm.c
-index 60fd6d4..837a3a8 100644
---- a/libcpu/i386_disasm.c
-+++ b/libcpu/i386_disasm.c
-@@ -819,7 +819,7 @@ i386_disasm (Ebl *ebl __attribute__((unused)),
- 			      ++param_start;
- 			      break;
- 			    }
--			  /* Fallthrough */
-+			  FALLTHROUGH;
- 			default:
- 			  str = "";
- 			  assert (! "INVALID not handled");
-diff --git a/libcpu/i386_parse.c b/libcpu/i386_parse.c
-index ef1ac35..6fa7ce3 100644
---- a/libcpu/i386_parse.c
-+++ b/libcpu/i386_parse.c
-@@ -1047,7 +1047,7 @@ yytnamerr (char *yyres, const char *yystr)
-           case '\\':
-             if (*++yyp != '\\')
-               goto do_not_strip_quotes;
--            /* Fall through.  */
-+            FALLTHROUGH;
-           default:
-             if (yyres)
-               yyres[yyn] = *yyp;
-@@ -2042,7 +2042,7 @@ yyabortlab:
- yyexhaustedlab:
-   yyerror (YY_("memory exhausted"));
-   yyresult = 2;
--  /* Fall through.  */
-+  FALLTHROUGH;
- #endif
- 
- yyreturn:
-diff --git a/libdw/cfi.c b/libdw/cfi.c
-index daa845f..341e055 100644
---- a/libdw/cfi.c
-+++ b/libdw/cfi.c
-@@ -138,7 +138,7 @@ execute_cfi (Dwarf_CFI *cache,
- 
- 	case DW_CFA_advance_loc1:
- 	  operand = *program++;
--	  /* Fallthrough */
-+	  FALLTHROUGH;
- 	case DW_CFA_advance_loc + 0 ... DW_CFA_advance_loc + CFI_PRIMARY_MAX:
- 	advance_loc:
- 	  loc += operand * cie->code_alignment_factor;
-@@ -301,7 +301,7 @@ execute_cfi (Dwarf_CFI *cache,
- 
- 	case DW_CFA_restore_extended:
- 	  get_uleb128 (operand, program, end);
--	  /* Fallthrough */
-+	  FALLTHROUGH;
- 	case DW_CFA_restore + 0 ... DW_CFA_restore + CFI_PRIMARY_MAX:
- 
- 	  if (unlikely (abi_cfi) && likely (opcode == DW_CFA_restore))
-diff --git a/libdw/dwarf_frame_register.c b/libdw/dwarf_frame_register.c
-index 37e8e91..d0159fb 100644
---- a/libdw/dwarf_frame_register.c
-+++ b/libdw/dwarf_frame_register.c
-@@ -62,7 +62,7 @@ dwarf_frame_register (Dwarf_Frame *fs, int regno, Dwarf_Op *ops_mem,
-       /* Use the default rule for registers not yet mentioned in CFI.  */
-       if (fs->cache->default_same_value)
- 	goto same_value;
--      /*FALLTHROUGH*/
-+      FALLTHROUGH;
-     case reg_undefined:
-       /* The value is known to be unavailable.  */
-       break;
-diff --git a/libdwfl/dwfl_report_elf.c b/libdwfl/dwfl_report_elf.c
-index 6950a37..3fc9384 100644
---- a/libdwfl/dwfl_report_elf.c
-+++ b/libdwfl/dwfl_report_elf.c
-@@ -174,7 +174,7 @@ __libdwfl_elf_address_range (Elf *elf, GElf_Addr base, bool add_p_vaddr,
-       /* An assigned base address is meaningless for these.  */
-       base = 0;
-       add_p_vaddr = true;
--      /* Fallthrough. */
-+      FALLTHROUGH;
-     case ET_DYN:
-     default:;
-       size_t phnum;
-diff --git a/libdwfl/frame_unwind.c b/libdwfl/frame_unwind.c
-index 4dc9c43..eaea495 100644
---- a/libdwfl/frame_unwind.c
-+++ b/libdwfl/frame_unwind.c
-@@ -442,7 +442,7 @@ expr_eval (Dwfl_Frame *state, Dwarf_Frame *frame, const Dwarf_Op *ops,
- 	    }
- 	  if (val1 == 0)
- 	    break;
--	  /* FALLTHRU */
-+	  FALLTHROUGH;
- 	case DW_OP_skip:;
- 	  Dwarf_Word offset = op->offset + 1 + 2 + (int16_t) op->number;
- 	  const Dwarf_Op *found = bsearch ((void *) (uintptr_t) offset, ops, nops,
-diff --git a/libebl/eblobjnote.c b/libebl/eblobjnote.c
-index f80a1a5..ca4f155 100644
---- a/libebl/eblobjnote.c
-+++ b/libebl/eblobjnote.c
-@@ -223,7 +223,7 @@ ebl_object_note (Ebl *ebl, const char *name, uint32_t type,
- 		free (buf);
- 	      break;
- 	    }
--	  /* FALLTHROUGH */
-+	  FALLTHROUGH;
- 
- 	default:
- 	  /* Unknown type.  */
-diff --git a/libelf/elf32_updatenull.c b/libelf/elf32_updatenull.c
-index a51bf70..5351518 100644
---- a/libelf/elf32_updatenull.c
-+++ b/libelf/elf32_updatenull.c
-@@ -232,7 +232,7 @@ __elfw2(LIBELFBITS,updatenull_wrlock) (Elf *elf, int *change_bop, size_t shnum)
- 		      __libelf_seterrno (ELF_E_GROUP_NOT_REL);
- 		      return -1;
- 		    }
--		  /* FALLTHROUGH */
-+		  FALLTHROUGH;
- 		case SHT_SYMTAB_SHNDX:
- 		  sh_entsize = elf_typesize (32, ELF_T_WORD, 1);
- 		  break;
-diff --git a/libelf/elf_begin.c b/libelf/elf_begin.c
-index 6f85038..6de206a 100644
---- a/libelf/elf_begin.c
-+++ b/libelf/elf_begin.c
-@@ -582,7 +582,7 @@ read_unmmaped_file (int fildes, off_t offset, size_t maxsize, Elf_Cmd cmd,
- 			     ? sizeof (Elf32_Ehdr) : sizeof (Elf64_Ehdr)))
- 	return file_read_elf (fildes, NULL, mem.header, offset, maxsize, cmd,
- 			      parent);
--      /* FALLTHROUGH */
-+      FALLTHROUGH;
- 
-     default:
-       break;
-@@ -1097,7 +1097,7 @@ elf_begin (int fildes, Elf_Cmd cmd, Elf *ref)
- 	  retval = NULL;
- 	  break;
- 	}
--      /* FALLTHROUGH */
-+      FALLTHROUGH;
- 
-     case ELF_C_READ:
-     case ELF_C_READ_MMAP:
-diff --git a/libelf/elf_cntl.c b/libelf/elf_cntl.c
-index ab13ffb..fd68178 100644
---- a/libelf/elf_cntl.c
-+++ b/libelf/elf_cntl.c
-@@ -62,7 +62,7 @@ elf_cntl (Elf *elf, Elf_Cmd cmd)
- 	  result = -1;
- 	  break;
- 	}
--      /* FALLTHROUGH */
-+      FALLTHROUGH;
- 
-     case ELF_C_FDDONE:
-       /* Mark the file descriptor as not usable.  */
-diff --git a/src/addr2line.c b/src/addr2line.c
-index ba414a7..444ee52 100644
---- a/src/addr2line.c
-+++ b/src/addr2line.c
-@@ -618,7 +618,7 @@ handle_address (const char *string, Dwfl *dwfl)
- 	case 1:
- 	  addr = 0;
- 	  j = i;
--	  /* Fallthrough */
-+	  FALLTHROUGH;
- 	case 2:
- 	  if (string[j] != '\0')
- 	    break;
-diff --git a/src/elfcompress.c b/src/elfcompress.c
-index 8e0d5c5..25378a4 100644
---- a/src/elfcompress.c
-+++ b/src/elfcompress.c
-@@ -149,7 +149,7 @@ parse_opt (int key, char *arg __attribute__ ((unused)),
- 		    N_("Only one input file allowed together with '-o'"));
-       /* We only use this for checking the number of arguments, we don't
- 	 actually want to consume them.  */
--      /* Fallthrough */
-+      FALLTHROUGH;
-     default:
-       return ARGP_ERR_UNKNOWN;
-     }
-diff --git a/src/elflint.c b/src/elflint.c
-index 51e53c2..df1b3a0 100644
---- a/src/elflint.c
-+++ b/src/elflint.c
-@@ -1764,7 +1764,7 @@ section [%2d] '%s': entry %zu: pointer does not match address of section [%2d] '
- 	  if (dyn->d_tag < DT_ADDRRNGLO || dyn->d_tag > DT_ADDRRNGHI)
- 	    /* Value is no pointer.  */
- 	    break;
--	  /* FALLTHROUGH */
-+	  FALLTHROUGH;
- 
- 	case DT_AUXILIARY:
- 	case DT_FILTER:
-@@ -3993,7 +3993,7 @@ section [%2zu] '%s': merge flag set but entry size is zero\n"),
- 	    case SHT_NOBITS:
- 	      if (is_debuginfo)
- 		break;
--	      /* Fallthrough */
-+	      FALLTHROUGH;
- 	    default:
- 	      ERROR (gettext ("\
- section [%2zu] '%s' has unexpected type %d for an executable section\n"),
-@@ -4137,7 +4137,7 @@ section [%2zu] '%s': ELF header says this is the section header string table but
- 	    ERROR (gettext ("\
- section [%2zu] '%s': relocatable files cannot have dynamic symbol tables\n"),
- 		   cnt, section_name (ebl, cnt));
--	  /* FALLTHROUGH */
-+	  FALLTHROUGH;
- 	case SHT_SYMTAB:
- 	  check_symtab (ebl, ehdr, shdr, cnt);
- 	  break;
-@@ -4336,7 +4336,7 @@ section [%2d] '%s': unknown core file note type %" PRIu32
- 	    if (nhdr.n_namesz == sizeof "Linux"
- 		&& !memcmp (data->d_buf + name_offset, "Linux", sizeof "Linux"))
- 	      break;
--	    /* Fallthrough */
-+	    FALLTHROUGH;
- 	  default:
- 	    if (shndx == 0)
- 	      ERROR (gettext ("\
-diff --git a/src/objdump.c b/src/objdump.c
-index 860cfac..0dd9a6a 100644
---- a/src/objdump.c
-+++ b/src/objdump.c
-@@ -223,7 +223,7 @@ parse_opt (int key, char *arg,
- 	}
-       /* We only use this for checking the number of arguments, we don't
- 	 actually want to consume them.  */
--      /* Fallthrough */
-+      FALLTHROUGH;
-     default:
-       return ARGP_ERR_UNKNOWN;
-     }
-diff --git a/src/readelf.c b/src/readelf.c
-index 346eccd..6a27e7e 100644
---- a/src/readelf.c
-+++ b/src/readelf.c
-@@ -465,7 +465,7 @@ parse_opt (int key, char *arg,
- 	  print_string_sections = true;
- 	  break;
- 	}
--      /* Fall through.  */
-+      FALLTHROUGH;
-     case 'x':
-       add_dump_section (arg, false);
-       any_control_option = true;
-@@ -6029,7 +6029,7 @@ attr_callback (Dwarf_Attribute *attrp, void *arg)
- 			dwarf_form_name (form), (uintmax_t) num);
- 	      return DWARF_CB_OK;
- 	    }
--	  /* else fallthrough */
-+	  FALLTHROUGH;
- 
- 	/* These cases always take a loclistptr and no constant. */
- 	case DW_AT_location:
-@@ -6195,7 +6195,7 @@ attr_callback (Dwarf_Attribute *attrp, void *arg)
- 	      print_block (block.length, block.data);
- 	      break;
- 	    }
--	  /* Fall through.  */
-+	  FALLTHROUGH;
- 
- 	case DW_AT_location:
- 	case DW_AT_data_location:
-@@ -9227,7 +9227,7 @@ handle_auxv_note (Ebl *ebl, Elf *core, GElf_Word descsz, GElf_Off desc_pos)
- 		printf ("    %s\n", name);
- 		break;
- 	      }
--	    /* Fall through */
-+	    FALLTHROUGH;
- 	  case 'x':		/* hex */
- 	  case 'p':		/* address */
- 	  case 's':		/* address of string */
-diff --git a/src/strings.c b/src/strings.c
-index d214356..03d0f13 100644
---- a/src/strings.c
-+++ b/src/strings.c
-@@ -246,7 +246,7 @@ parse_opt (int key, char *arg,
- 	case 'b':
- 	case 'B':
- 	  big_endian = true;
--	  /* FALLTHROUGH */
-+	  FALLTHROUGH;
- 
- 	case 'l':
- 	case 'L':
-diff --git a/tests/backtrace.c b/tests/backtrace.c
-index 21abe8a..f5dd761 100644
---- a/tests/backtrace.c
-+++ b/tests/backtrace.c
-@@ -127,7 +127,7 @@ callback_verify (pid_t tid, unsigned frameno, Dwarf_Addr pc,
- 	  assert (symname2 == NULL || strcmp (symname2, "jmp") != 0);
- 	  break;
- 	}
--      /* FALLTHRU */
-+      FALLTHROUGH;
-     case 4:
-       /* Some simple frame unwinders get this wrong and think sigusr2
- 	 is calling itself again. Allow it and just pretend there is
-diff --git a/tests/elfstrmerge.c b/tests/elfstrmerge.c
-index 8d5b53c..62c549d 100644
---- a/tests/elfstrmerge.c
-+++ b/tests/elfstrmerge.c
-@@ -578,7 +578,8 @@ main (int argc, char **argv)
- 	      break;
- 
- 	    case SHT_DYNAMIC:
--	      /* Fallthrough.  There are string indexes in here, but
-+	      FALLTHROUGH;
-+	      /* There are string indexes in here, but
- 		 they (should) point to a allocated string table,
- 		 which we don't alter.  */
- 	    default:
--- 
-2.14.3
-
diff --git a/poky/meta/recipes-devtools/elfutils/files/0001-arlib-Check-that-sh_entsize-isn-t-zero.patch b/poky/meta/recipes-devtools/elfutils/files/0001-arlib-Check-that-sh_entsize-isn-t-zero.patch
new file mode 100644
index 0000000..86cf7c8
--- /dev/null
+++ b/poky/meta/recipes-devtools/elfutils/files/0001-arlib-Check-that-sh_entsize-isn-t-zero.patch
@@ -0,0 +1,36 @@
+From b518841fbc1431d7c5baa016e35f10fb647b5958 Mon Sep 17 00:00:00 2001
+From: Mark Wielaard <mark@klomp.org>
+Date: Thu, 18 Oct 2018 19:01:52 +0200
+Subject: [PATCH] arlib: Check that sh_entsize isn't zero.
+
+A bogus ELF file could have sh_entsize as zero. Don't divide by zero,
+but just assume there are no symbols in the section.
+
+https://sourceware.org/bugzilla/show_bug.cgi?id=23786
+
+Signed-off-by: Mark Wielaard <mark@klomp.org>
+
+CVE: CVE-2018-18521
+Upstream-Status: Backport [http://sourceware.org/git/elfutils.git]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ src/arlib.c | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/src/arlib.c b/src/arlib.c
+index 778e087..a6521e3 100644
+--- a/src/arlib.c
++++ b/src/arlib.c
+@@ -252,6 +252,9 @@ arlib_add_symbols (Elf *elf, const char *arfname, const char *membername,
+       if (data == NULL)
+ 	continue;
+ 
++      if (shdr->sh_entsize == 0)
++	continue;
++
+       int nsyms = shdr->sh_size / shdr->sh_entsize;
+       for (int ndx = shdr->sh_info; ndx < nsyms; ++ndx)
+ 	{
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/elfutils/files/0001-dso-link-change.patch b/poky/meta/recipes-devtools/elfutils/files/0001-dso-link-change.patch
index 28c57f2..4c62dc5 100644
--- a/poky/meta/recipes-devtools/elfutils/files/0001-dso-link-change.patch
+++ b/poky/meta/recipes-devtools/elfutils/files/0001-dso-link-change.patch
@@ -1,4 +1,4 @@
-From 0a69a26c9f7487daca900db87cd1195857a4603f Mon Sep 17 00:00:00 2001
+From c9c6d2414651dbf163dc4963c3c3d6f5cacef898 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Tue, 15 Aug 2017 17:10:57 +0800
 Subject: [PATCH 1/7] dso link change
@@ -35,10 +35,10 @@
  endif
  libebl = ../libebl/libebl.a
 diff --git a/tests/Makefile.am b/tests/Makefile.am
-index 3735084..528615d 100644
+index b45ecdc..dd256fb 100644
 --- a/tests/Makefile.am
 +++ b/tests/Makefile.am
-@@ -400,7 +400,7 @@ libdw = ../libdw/libdw.a -lz $(zip_LIBS) $(libelf) $(libebl) -ldl
+@@ -436,7 +436,7 @@ libdw = ../libdw/libdw.a -lz $(zip_LIBS) $(libelf) $(libebl) -ldl
  libelf = ../libelf/libelf.a -lz
  libasm = ../libasm/libasm.a
  else
@@ -48,5 +48,5 @@
  libasm = ../libasm/libasm.so
  endif
 -- 
-1.8.3.1
+2.7.4
 
diff --git a/poky/meta/recipes-devtools/elfutils/files/0001-libasm-may-link-with-libbz2-if-found.patch b/poky/meta/recipes-devtools/elfutils/files/0001-libasm-may-link-with-libbz2-if-found.patch
index fb0b060..c342053 100644
--- a/poky/meta/recipes-devtools/elfutils/files/0001-libasm-may-link-with-libbz2-if-found.patch
+++ b/poky/meta/recipes-devtools/elfutils/files/0001-libasm-may-link-with-libbz2-if-found.patch
@@ -1,4 +1,4 @@
-From 7672e363468271b4c63ff58770c5aac15ab8f722 Mon Sep 17 00:00:00 2001
+From 74629016e76343a4bf39915c9192b6bf26a57c2d Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Wed, 4 Oct 2017 22:30:46 -0700
 Subject: [PATCH] libasm may link with libbz2 if found
@@ -9,15 +9,14 @@
 | /mnt/a/oe/build/tmp/work/riscv64-bec-linux/elfutils/0.170-r0/recipe-sysroot/usr/lib/libbz2.so.1: error adding symbols: DSO missing from command line
 | collect2: error: ld returned 1 exit status
 
+Upstream-Status: Pending
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 ---
-Upstream-Status: Pending
-
- src/Makefile.am | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
+ src/Makefile.am | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/src/Makefile.am b/src/Makefile.am
-index e03bc32..9b7e853 100644
+index 9305b84..9b7e853 100644
 --- a/src/Makefile.am
 +++ b/src/Makefile.am
 @@ -39,11 +39,11 @@ EXTRA_DIST += make-debug-archive.in
@@ -35,5 +34,5 @@
  libelf = ../libelf/libelf.so
  endif
 -- 
-2.14.2
+2.7.4
 
diff --git a/poky/meta/recipes-devtools/elfutils/files/0001-libdwfl-Sanity-check-partial-core-file-data-reads.patch b/poky/meta/recipes-devtools/elfutils/files/0001-libdwfl-Sanity-check-partial-core-file-data-reads.patch
new file mode 100644
index 0000000..2c74a8d
--- /dev/null
+++ b/poky/meta/recipes-devtools/elfutils/files/0001-libdwfl-Sanity-check-partial-core-file-data-reads.patch
@@ -0,0 +1,60 @@
+From 8cbb2f8de89d65ca52d4242f213a6206b48d2c8d Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Fri, 2 Nov 2018 14:22:31 +0800
+Subject: [PATCH] libdwfl: Sanity check partial core file data reads.
+
+There were two issues when reading note data from a core file.
+We didn't check if the data we already had in a buffer was big
+enough. And if we did get the data, we should check if we got
+everything, or just a part of the data.
+
+https://sourceware.org/bugzilla/show_bug.cgi?id=23752
+
+Signed-off-by: Mark Wielaard <mark@klomp.org>
+
+CVE: CVE-2018-18310
+Upstream-Status: Backport [http://sourceware.org/git/elfutils.git]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ libdwfl/dwfl_segment_report_module.c | 13 +++++++++++--
+ 1 file changed, 11 insertions(+), 2 deletions(-)
+
+diff --git a/libdwfl/dwfl_segment_report_module.c b/libdwfl/dwfl_segment_report_module.c
+index 36e5c82..8749884 100644
+--- a/libdwfl/dwfl_segment_report_module.c
++++ b/libdwfl/dwfl_segment_report_module.c
+@@ -1,5 +1,5 @@
+ /* Sniff out modules from ELF headers visible in memory segments.
+-   Copyright (C) 2008-2012, 2014, 2015 Red Hat, Inc.
++   Copyright (C) 2008-2012, 2014, 2015, 2018 Red Hat, Inc.
+    This file is part of elfutils.
+ 
+    This file is free software; you can redistribute it and/or modify
+@@ -301,7 +301,10 @@ dwfl_segment_report_module (Dwfl *dwfl, int ndx, const char *name,
+   inline bool read_portion (void **data, size_t *data_size,
+ 			    GElf_Addr vaddr, size_t filesz)
+   {
+-    if (vaddr - start + filesz > buffer_available
++    /* Check whether we will have to read the segment data, or if it
++       can be returned from the existing buffer.  */
++    if (filesz > buffer_available
++	|| vaddr - start > buffer_available - filesz
+ 	/* If we're in string mode, then don't consider the buffer we have
+ 	   sufficient unless it contains the terminator of the string.  */
+ 	|| (filesz == 0 && memchr (vaddr - start + buffer, '\0',
+@@ -459,6 +462,12 @@ dwfl_segment_report_module (Dwfl *dwfl, int ndx, const char *name,
+     if (read_portion (&data, &data_size, vaddr, filesz))
+       return;
+ 
++    /* data_size will be zero if we got everything from the initial
++       buffer, otherwise it will be the size of the new buffer that
++       could be read.  */
++    if (data_size != 0)
++      filesz = data_size;
++
+     assert (sizeof (Elf32_Nhdr) == sizeof (Elf64_Nhdr));
+ 
+     void *notes;
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/elfutils/files/0001-libelf-elf_end.c-check-data_list.data.d.d_buf-before.patch b/poky/meta/recipes-devtools/elfutils/files/0001-libelf-elf_end.c-check-data_list.data.d.d_buf-before.patch
new file mode 100644
index 0000000..1bdb511
--- /dev/null
+++ b/poky/meta/recipes-devtools/elfutils/files/0001-libelf-elf_end.c-check-data_list.data.d.d_buf-before.patch
@@ -0,0 +1,46 @@
+From 3393a2e544818f0bd1887c13f28a76ad60c2df98 Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Thu, 16 Aug 2018 09:58:26 +0800
+Subject: [PATCH] libelf/elf_end.c: check data_list.data.d.d_buf before free it
+
+The one which actually saves the data is data_list.data.d.d_buf, so check it
+before free rawdata_base.
+
+This can fix a segmentation fault when prelink libqb_1.0.3:
+prelink: /usr/lib/libqb.so.0.18.2: Symbol section index outside of section numbers
+
+The segmentation fault happens when prelink call elf_end().
+
+Upstream-Status: Submitted [https://sourceware.org/ml/elfutils-devel/2018-q3/msg00085.html]
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ libelf/elf_end.c | 6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/libelf/elf_end.c b/libelf/elf_end.c
+index 160f0b8..5280a70 100644
+--- a/libelf/elf_end.c
++++ b/libelf/elf_end.c
+@@ -160,14 +160,16 @@ elf_end (Elf *elf)
+ 		   architecture doesn't require overly stringent
+ 		   alignment the raw data buffer is the same as the
+ 		   one used for presenting to the caller.  */
+-		if (scn->data_base != scn->rawdata_base)
++		if ((scn->data_base != scn->rawdata_base)
++		    && (scn->data_list.data.d.d_buf != NULL))
+ 		  free (scn->data_base);
+ 
+ 		/* The section data is allocated if we couldn't mmap
+ 		   the file.  Or if we had to decompress.  */
+-		if (elf->map_address == NULL
++		if ((elf->map_address == NULL
+ 		    || scn->rawdata_base == scn->zdata_base
+ 		    || (scn->flags & ELF_F_MALLOCED) != 0)
++		    && (scn->data_list.data.d.d_buf != NULL))
+ 		  free (scn->rawdata_base);
+ 
+ 		/* Free the list of data buffers for the section.
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/elfutils/files/0001-size-Handle-recursive-ELF-ar-files.patch b/poky/meta/recipes-devtools/elfutils/files/0001-size-Handle-recursive-ELF-ar-files.patch
new file mode 100644
index 0000000..6fed826
--- /dev/null
+++ b/poky/meta/recipes-devtools/elfutils/files/0001-size-Handle-recursive-ELF-ar-files.patch
@@ -0,0 +1,40 @@
+From 440d34d0ee37964453245895d38d7fc31bcf3d7d Mon Sep 17 00:00:00 2001
+From: Mark Wielaard <mark@klomp.org>
+Date: Thu, 18 Oct 2018 23:15:48 +0200
+Subject: [PATCH] size: Handle recursive ELF ar files.
+
+eu-size didn't handle an ELF ar file that contained an ar file itself
+correctly. handle_ar would recursively call itself but close the ELF
+file before returning. Only close the ELF file at the top-level.
+
+https://sourceware.org/bugzilla/show_bug.cgi?id=23787
+
+Signed-off-by: Mark Wielaard <mark@klomp.org>
+
+CVE: CVE-2018-18520
+Upstream-Status: Backport [http://sourceware.org/git/elfutils.git]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ src/size.c | 6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/src/size.c b/src/size.c
+index 5ff3f2a..f01fd88 100644
+--- a/src/size.c
++++ b/src/size.c
+@@ -374,8 +374,10 @@ handle_ar (int fd, Elf *elf, const char *prefix, const char *fname)
+ 	INTERNAL_ERROR (fname);
+     }
+ 
+-  if (unlikely (elf_end (elf) != 0))
+-    INTERNAL_ERROR (fname);
++  /* Only close ELF handle if this was a "top level" ar file.  */
++  if (prefix == NULL)
++    if (unlikely (elf_end (elf) != 0))
++      INTERNAL_ERROR (fname);
+ 
+   return result;
+ }
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/elfutils/files/0002-Fix-elf_cvt_gunhash-if-dest-and-src-are-same.patch b/poky/meta/recipes-devtools/elfutils/files/0002-Fix-elf_cvt_gunhash-if-dest-and-src-are-same.patch
index 2f718eb..86d26bd 100644
--- a/poky/meta/recipes-devtools/elfutils/files/0002-Fix-elf_cvt_gunhash-if-dest-and-src-are-same.patch
+++ b/poky/meta/recipes-devtools/elfutils/files/0002-Fix-elf_cvt_gunhash-if-dest-and-src-are-same.patch
@@ -1,4 +1,4 @@
-From e98670f7c7b4c73fb65534949716fd8d043960d5 Mon Sep 17 00:00:00 2001
+From 9fd4bb05d3f2b7eaf9fe441bee26d3b1878d7cc7 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Tue, 15 Aug 2017 17:13:59 +0800
 Subject: [PATCH 2/7] Fix elf_cvt_gunhash if dest and src are same.
@@ -38,5 +38,5 @@
    /* Now the 64 bit words.  */
    Elf64_Xword *dest64 = (Elf64_Xword *) &dest32[4];
 -- 
-1.8.3.1
+2.7.4
 
diff --git a/poky/meta/recipes-devtools/elfutils/files/0003-fixheadercheck.patch b/poky/meta/recipes-devtools/elfutils/files/0003-fixheadercheck.patch
index 7c49fce..d1c8e41 100644
--- a/poky/meta/recipes-devtools/elfutils/files/0003-fixheadercheck.patch
+++ b/poky/meta/recipes-devtools/elfutils/files/0003-fixheadercheck.patch
@@ -1,4 +1,4 @@
-From 565d5935abf5b58773f9c8385c00189221980d98 Mon Sep 17 00:00:00 2001
+From 04fb3f65ec186df5231dd0c21780a55dcc03c868 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Tue, 15 Aug 2017 17:17:20 +0800
 Subject: [PATCH 3/7] fixheadercheck
@@ -21,7 +21,7 @@
  1 file changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/libelf/elf32_updatenull.c b/libelf/elf32_updatenull.c
-index d83c0b3..a51bf70 100644
+index 3e9ef61..5351518 100644
 --- a/libelf/elf32_updatenull.c
 +++ b/libelf/elf32_updatenull.c
 @@ -339,8 +339,8 @@ __elfw2(LIBELFBITS,updatenull_wrlock) (Elf *elf, int *change_bop, size_t shnum)
@@ -36,5 +36,5 @@
  		      __libelf_seterrno (ELF_E_INVALID_ALIGN);
  		      return -1;
 -- 
-1.8.3.1
+2.7.4
 
diff --git a/poky/meta/recipes-devtools/elfutils/files/0004-Disable-the-test-to-convert-euc-jp.patch b/poky/meta/recipes-devtools/elfutils/files/0004-Disable-the-test-to-convert-euc-jp.patch
index d893ad6..bf3a645 100644
--- a/poky/meta/recipes-devtools/elfutils/files/0004-Disable-the-test-to-convert-euc-jp.patch
+++ b/poky/meta/recipes-devtools/elfutils/files/0004-Disable-the-test-to-convert-euc-jp.patch
@@ -1,4 +1,4 @@
-From bb7ed11950101798aae82f7fda8b3dcb05f755c5 Mon Sep 17 00:00:00 2001
+From dbc88349b9eed4268db951df2c3a8387f75a32e7 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Tue, 15 Aug 2017 17:24:06 +0800
 Subject: [PATCH 4/7] Disable the test to convert euc-jp
@@ -40,5 +40,5 @@
  }]])],
          [am_cv_func_iconv_works=yes],
 -- 
-1.8.3.1
+2.7.4
 
diff --git a/poky/meta/recipes-devtools/elfutils/files/0005-fix-a-stack-usage-warning.patch b/poky/meta/recipes-devtools/elfutils/files/0005-fix-a-stack-usage-warning.patch
index 22a01cf..e2966cb 100644
--- a/poky/meta/recipes-devtools/elfutils/files/0005-fix-a-stack-usage-warning.patch
+++ b/poky/meta/recipes-devtools/elfutils/files/0005-fix-a-stack-usage-warning.patch
@@ -1,4 +1,4 @@
-From dd6dbf6af396519380f48c0ef1ce6cf4dd77f6d7 Mon Sep 17 00:00:00 2001
+From 4d7ea681932556ad881f6841de90d0bfff56f8d7 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Tue, 15 Aug 2017 17:25:16 +0800
 Subject: [PATCH 5/7] fix a stack-usage warning
@@ -18,10 +18,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/backends/ppc_initreg.c b/backends/ppc_initreg.c
-index 69d623b..de41dec 100644
+index 3e4432f..59c2d97 100644
 --- a/backends/ppc_initreg.c
 +++ b/backends/ppc_initreg.c
-@@ -93,7 +93,7 @@ ppc_set_initial_registers_tid (pid_t tid __attribute__ ((unused)),
+@@ -94,7 +94,7 @@ ppc_set_initial_registers_tid (pid_t tid __attribute__ ((unused)),
  	return false;
      }
    const size_t gprs = sizeof (user_regs.r.gpr) / sizeof (*user_regs.r.gpr);
@@ -31,5 +31,5 @@
      dwarf_regs[gpr] = user_regs.r.gpr[gpr];
    if (! setfunc (0, gprs, dwarf_regs, arg))
 -- 
-1.8.3.1
+2.7.4
 
diff --git a/poky/meta/recipes-devtools/elfutils/files/0006-Fix-build-on-aarch64-musl.patch b/poky/meta/recipes-devtools/elfutils/files/0006-Fix-build-on-aarch64-musl.patch
index 5f29a03..40b8544 100644
--- a/poky/meta/recipes-devtools/elfutils/files/0006-Fix-build-on-aarch64-musl.patch
+++ b/poky/meta/recipes-devtools/elfutils/files/0006-Fix-build-on-aarch64-musl.patch
@@ -1,4 +1,4 @@
-From e57ad47fc8549353ca80c23b9b4f38f31fde13e5 Mon Sep 17 00:00:00 2001
+From b4ec05953f78af26bcd7de45a5bbc5f138d023da Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Tue, 15 Aug 2017 17:27:30 +0800
 Subject: [PATCH 6/7] Fix build on aarch64/musl
@@ -57,5 +57,5 @@
  # include <sys/ptrace.h>
  /* Deal with old glibc defining user_pt_regs instead of user_regs_struct.  */
 -- 
-1.8.3.1
+2.7.4
 
diff --git a/poky/meta/recipes-devtools/elfutils/files/0007-Fix-control-path-where-we-have-str-as-uninitialized-.patch b/poky/meta/recipes-devtools/elfutils/files/0007-Fix-control-path-where-we-have-str-as-uninitialized-.patch
index 2247704..bba420e 100644
--- a/poky/meta/recipes-devtools/elfutils/files/0007-Fix-control-path-where-we-have-str-as-uninitialized-.patch
+++ b/poky/meta/recipes-devtools/elfutils/files/0007-Fix-control-path-where-we-have-str-as-uninitialized-.patch
@@ -1,6 +1,6 @@
-From 1e91c1d4e37c05cf95058b4b3c3f352d72886f58 Mon Sep 17 00:00:00 2001
+From 8eb100b2e51be5d473b0748a223e2e7f61ec606c Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Tue, 15 Aug 2017 17:31:38 +0800
+Date: Fri, 29 Jun 2018 15:14:28 +0800
 Subject: [PATCH 7/7] Fix control path where we have str as uninitialized
  string
 
@@ -21,7 +21,7 @@
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 Upstream-Status: Pending
 
-Rebase to 0.170
+Rebase to 0.172
 
 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
@@ -29,17 +29,17 @@
  1 file changed, 1 insertion(+)
 
 diff --git a/libcpu/i386_disasm.c b/libcpu/i386_disasm.c
-index 831afbe..60fd6d4 100644
+index a7e03f9..837a3a8 100644
 --- a/libcpu/i386_disasm.c
 +++ b/libcpu/i386_disasm.c
 @@ -821,6 +821,7 @@ i386_disasm (Ebl *ebl __attribute__((unused)),
  			    }
- 			  /* Fallthrough */
+ 			  FALLTHROUGH;
  			default:
 +			  str = "";
  			  assert (! "INVALID not handled");
  			}
  		    }
 -- 
-1.8.3.1
+2.7.4
 
diff --git a/poky/meta/recipes-devtools/elfutils/files/0008-build-Provide-alternatives-for-glibc-assumptions-hel.patch b/poky/meta/recipes-devtools/elfutils/files/0008-build-Provide-alternatives-for-glibc-assumptions-hel.patch
index a42ce7b..0f01a32 100644
--- a/poky/meta/recipes-devtools/elfutils/files/0008-build-Provide-alternatives-for-glibc-assumptions-hel.patch
+++ b/poky/meta/recipes-devtools/elfutils/files/0008-build-Provide-alternatives-for-glibc-assumptions-hel.patch
@@ -1,90 +1,32 @@
-From ef0981744669149a00dd0439a54dac30de7b56a7 Mon Sep 17 00:00:00 2001
+From 207be05c44da5c4c31179a34660e176145ff8d4b Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 16 Aug 2017 10:06:26 +0800
+Date: Mon, 2 Jul 2018 09:52:23 +0800
 Subject: [PATCH] build: Provide alternatives for glibc assumptions helps
  compiling it on musl
 
 Upstream-Status: Pending
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
-Rebase to 0.170
+Rebase to 0.174
 
 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
-
 ---
  Makefile.am                      |  2 +-
- lib/color.c                      |  3 ++-
  lib/fixedsizehash.h              |  1 -
- lib/system.h                     | 10 ++++++++++
- lib/xmalloc.c                    |  2 +-
- libasm/asm_end.c                 |  2 +-
- libasm/asm_newscn.c              |  2 +-
- libcpu/i386_gendis.c             |  2 +-
- libcpu/i386_lex.c                |  2 +-
- libcpu/i386_parse.c              |  2 +-
+ lib/system.h                     | 12 +++++++++++-
  libdw/Makefile.am                |  3 ++-
- libdw/libdw_alloc.c              |  2 +-
- libdwfl/dwfl_build_id_find_elf.c |  3 ++-
+ libdwfl/dwfl_build_id_find_elf.c |  1 +
  libdwfl/dwfl_error.c             |  4 +++-
  libdwfl/dwfl_module_getdwarf.c   |  1 +
- libdwfl/find-debuginfo.c         |  2 +-
  libdwfl/libdwfl_crc32_file.c     |  9 +++++++++
  libdwfl/linux-kernel-modules.c   |  1 +
- libebl/eblopenbackend.c          |  2 +-
  libelf/elf.h                     |  8 ++++++--
  libelf/libelf.h                  |  1 +
  libelf/libelfP.h                 |  1 +
- src/addr2line.c                  |  2 +-
- src/ar.c                         |  2 +-
- src/arlib.c                      |  2 +-
- src/arlib2.c                     |  2 +-
- src/elfcmp.c                     |  2 +-
- src/elflint.c                    |  2 +-
- src/findtextrel.c                |  2 +-
- src/nm.c                         |  2 +-
- src/objdump.c                    |  2 +-
- src/ranlib.c                     |  2 +-
- src/readelf.c                    |  2 +-
- src/size.c                       |  2 +-
- src/stack.c                      |  2 +-
- src/strings.c                    |  2 +-
- src/strip.c                      |  2 +-
- src/unstrip.c                    |  2 +-
- tests/addrscopes.c               |  2 +-
- tests/allregs.c                  |  2 +-
- tests/backtrace-data.c           |  2 +-
- tests/backtrace-dwarf.c          |  2 +-
- tests/backtrace.c                |  2 +-
- tests/buildid.c                  |  2 +-
- tests/debugaltlink.c             |  2 +-
- tests/debuglink.c                |  2 +-
- tests/deleted.c                  |  2 +-
- tests/dwfl-addr-sect.c           |  2 +-
- tests/dwfl-bug-addr-overflow.c   |  2 +-
- tests/dwfl-bug-fd-leak.c         |  2 +-
- tests/dwfl-bug-getmodules.c      |  2 +-
- tests/dwfl-report-elf-align.c    |  2 +-
- tests/dwfllines.c                |  2 +-
- tests/dwflmodtest.c              |  2 +-
- tests/dwflsyms.c                 |  2 +-
- tests/early-offscn.c             |  2 +-
- tests/ecp.c                      |  2 +-
- tests/find-prologues.c           |  2 +-
- tests/funcretval.c               |  2 +-
- tests/funcscopes.c               |  2 +-
- tests/getsrc_die.c               |  2 +-
- tests/line2addr.c                |  2 +-
- tests/low_high_pc.c              |  2 +-
- tests/md5-sha1-test.c            |  2 +-
- tests/rdwrmmap.c                 |  2 +-
- tests/saridx.c                   |  2 +-
- tests/sectiondump.c              |  2 +-
- tests/varlocs.c                  |  2 +-
- tests/vdsosyms.c                 |  2 +-
- 69 files changed, 95 insertions(+), 64 deletions(-)
+ 12 files changed, 37 insertions(+), 7 deletions(-)
 
 diff --git a/Makefile.am b/Makefile.am
-index 2ff444e7..41f77df8 100644
+index 2ff444e..41f77df 100644
 --- a/Makefile.am
 +++ b/Makefile.am
 @@ -28,7 +28,7 @@ pkginclude_HEADERS = version.h
@@ -96,28 +38,8 @@
  
  EXTRA_DIST = elfutils.spec GPG-KEY NOTES CONTRIBUTING \
  	     COPYING COPYING-GPLV2 COPYING-LGPLV3
-diff --git a/lib/color.c b/lib/color.c
-index f62389d5..a2a84b46 100644
---- a/lib/color.c
-+++ b/lib/color.c
-@@ -32,13 +32,14 @@
- #endif
- 
- #include <argp.h>
--#include <error.h>
-+#include <err.h>
- #include <libintl.h>
- #include <stdlib.h>
- #include <string.h>
- #include <unistd.h>
- #include "libeu.h"
- #include "color.h"
-+#include "system.h"
- 
- /* Prototype for option handler.  */
- static error_t parse_opt (int key, char *arg, struct argp_state *state);
 diff --git a/lib/fixedsizehash.h b/lib/fixedsizehash.h
-index dac2a5f5..43016fc3 100644
+index dac2a5f..43016fc 100644
 --- a/lib/fixedsizehash.h
 +++ b/lib/fixedsizehash.h
 @@ -30,7 +30,6 @@
@@ -129,10 +51,19 @@
  #include <system.h>
  
 diff --git a/lib/system.h b/lib/system.h
-index 92033355..1a601319 100644
+index 292082b..308a762 100644
 --- a/lib/system.h
 +++ b/lib/system.h
-@@ -50,6 +50,16 @@
+@@ -30,7 +30,7 @@
+ #define LIB_SYSTEM_H	1
+ 
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <stddef.h>
+ #include <stdint.h>
+ #include <sys/param.h>
+@@ -51,6 +51,16 @@
  #else
  # error "Unknown byte order"
  #endif
@@ -149,89 +80,11 @@
  
  #ifndef MAX
  #define MAX(m, n) ((m) < (n) ? (n) : (m))
-diff --git a/lib/xmalloc.c b/lib/xmalloc.c
-index 0cde384f..217b0541 100644
---- a/lib/xmalloc.c
-+++ b/lib/xmalloc.c
-@@ -30,7 +30,7 @@
- # include <config.h>
- #endif
- 
--#include <error.h>
-+#include <err.h>
- #include <libintl.h>
- #include <stddef.h>
- #include <stdlib.h>
-diff --git a/libasm/asm_end.c b/libasm/asm_end.c
-index ced24f50..4ad918c4 100644
---- a/libasm/asm_end.c
-+++ b/libasm/asm_end.c
-@@ -32,7 +32,7 @@
- #endif
- 
- #include <assert.h>
--#include <error.h>
-+#include <err.h>
- #include <libintl.h>
- #include <stdio.h>
- #include <stdlib.h>
-diff --git a/libasm/asm_newscn.c b/libasm/asm_newscn.c
-index ddbb25df..74a598d9 100644
---- a/libasm/asm_newscn.c
-+++ b/libasm/asm_newscn.c
-@@ -32,7 +32,7 @@
- #endif
- 
- #include <assert.h>
--#include <error.h>
-+#include <err.h>
- #include <libintl.h>
- #include <stdlib.h>
- #include <string.h>
-diff --git a/libcpu/i386_gendis.c b/libcpu/i386_gendis.c
-index aae5eae6..6d760165 100644
---- a/libcpu/i386_gendis.c
-+++ b/libcpu/i386_gendis.c
-@@ -31,7 +31,7 @@
- # include <config.h>
- #endif
- 
--#include <error.h>
-+#include <err.h>
- #include <errno.h>
- #include <stdio.h>
- #include <stdlib.h>
-diff --git a/libcpu/i386_lex.c b/libcpu/i386_lex.c
-index ba5f4aa5..b1e41916 100644
---- a/libcpu/i386_lex.c
-+++ b/libcpu/i386_lex.c
-@@ -577,7 +577,7 @@ char *i386_text;
- #endif
- 
- #include <ctype.h>
--#include <error.h>
-+#include <err.h>
- #include <libintl.h>
- 
- #include <libeu.h>
-diff --git a/libcpu/i386_parse.c b/libcpu/i386_parse.c
-index 6fa7ce3d..bb270061 100644
---- a/libcpu/i386_parse.c
-+++ b/libcpu/i386_parse.c
-@@ -107,7 +107,7 @@
- #include <assert.h>
- #include <ctype.h>
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <inttypes.h>
- #include <libintl.h>
- #include <math.h>
 diff --git a/libdw/Makefile.am b/libdw/Makefile.am
-index ff8c291e..89e792aa 100644
+index 7a3d532..7ac1241 100644
 --- a/libdw/Makefile.am
 +++ b/libdw/Makefile.am
-@@ -105,7 +105,8 @@ am_libdw_pic_a_OBJECTS = $(libdw_a_SOURCES:.c=.os)
+@@ -108,7 +108,8 @@ am_libdw_pic_a_OBJECTS = $(libdw_a_SOURCES:.c=.os)
  libdw_so_LIBS = libdw_pic.a ../libdwelf/libdwelf_pic.a \
  	  ../libdwfl/libdwfl_pic.a ../libebl/libebl.a
  libdw_so_DEPS = ../lib/libeu.a ../libelf/libelf.so
@@ -241,21 +94,8 @@
  libdw_so_SOURCES =
  libdw.so$(EXEEXT): $(srcdir)/libdw.map $(libdw_so_LIBS) $(libdw_so_DEPS)
  # The rpath is necessary for libebl because its $ORIGIN use will
-diff --git a/libdw/libdw_alloc.c b/libdw/libdw_alloc.c
-index 28a8cf6e..29aeb3f7 100644
---- a/libdw/libdw_alloc.c
-+++ b/libdw/libdw_alloc.c
-@@ -31,7 +31,7 @@
- # include <config.h>
- #endif
- 
--#include <error.h>
-+#include <err.h>
- #include <errno.h>
- #include <stdlib.h>
- #include "libdwP.h"
 diff --git a/libdwfl/dwfl_build_id_find_elf.c b/libdwfl/dwfl_build_id_find_elf.c
-index ee0c1646..b06ab596 100644
+index cc6c3f6..b06ab59 100644
 --- a/libdwfl/dwfl_build_id_find_elf.c
 +++ b/libdwfl/dwfl_build_id_find_elf.c
 @@ -31,6 +31,7 @@
@@ -266,17 +106,8 @@
  #include <inttypes.h>
  #include <fcntl.h>
  #include <unistd.h>
-@@ -99,7 +100,7 @@ __libdwfl_open_by_build_id (Dwfl_Module *mod, bool debug, char **file_name,
- 	{
- 	  if (*file_name != NULL)
- 	    free (*file_name);
--	  *file_name = canonicalize_file_name (name);
-+	  *file_name = realpath (name, NULL);
- 	  if (*file_name == NULL)
- 	    {
- 	      *file_name = name;
 diff --git a/libdwfl/dwfl_error.c b/libdwfl/dwfl_error.c
-index 7bcf61cc..c345797a 100644
+index 7bcf61c..c345797 100644
 --- a/libdwfl/dwfl_error.c
 +++ b/libdwfl/dwfl_error.c
 @@ -140,6 +140,7 @@ __libdwfl_seterrno (Dwfl_Error error)
@@ -298,7 +129,7 @@
        return elf_errmsg (error & 0xffff);
      case OTHER_ERROR (LIBDW):
 diff --git a/libdwfl/dwfl_module_getdwarf.c b/libdwfl/dwfl_module_getdwarf.c
-index 9775aced..511c4a6a 100644
+index af6838a..c079d6a 100644
 --- a/libdwfl/dwfl_module_getdwarf.c
 +++ b/libdwfl/dwfl_module_getdwarf.c
 @@ -35,6 +35,7 @@
@@ -309,21 +140,8 @@
  #include "../libdw/libdwP.h"	/* DWARF_E_* values are here.  */
  #include "../libelf/libelfP.h"
  #include "system.h"
-diff --git a/libdwfl/find-debuginfo.c b/libdwfl/find-debuginfo.c
-index 6d5a42a6..9267788d 100644
---- a/libdwfl/find-debuginfo.c
-+++ b/libdwfl/find-debuginfo.c
-@@ -389,7 +389,7 @@ dwfl_standard_find_debuginfo (Dwfl_Module *mod,
-       /* If FILE_NAME is a symlink, the debug file might be associated
- 	 with the symlink target name instead.  */
- 
--      char *canon = canonicalize_file_name (file_name);
-+      char *canon = realpath (file_name, NULL);
-       if (canon != NULL && strcmp (file_name, canon))
- 	fd = find_debuginfo_in_path (mod, canon,
- 				     debuglink_file, debuglink_crc,
 diff --git a/libdwfl/libdwfl_crc32_file.c b/libdwfl/libdwfl_crc32_file.c
-index f849128d..6f0aca1b 100644
+index f849128..6f0aca1 100644
 --- a/libdwfl/libdwfl_crc32_file.c
 +++ b/libdwfl/libdwfl_crc32_file.c
 @@ -29,6 +29,15 @@
@@ -343,7 +161,7 @@
  #define crc32 __libdwfl_crc32
  #include <libdwflP.h>
 diff --git a/libdwfl/linux-kernel-modules.c b/libdwfl/linux-kernel-modules.c
-index 9d0fef2c..9fc09b88 100644
+index 9d0fef2..9fc09b8 100644
 --- a/libdwfl/linux-kernel-modules.c
 +++ b/libdwfl/linux-kernel-modules.c
 @@ -40,6 +40,7 @@
@@ -354,21 +172,8 @@
  #include <inttypes.h>
  #include <errno.h>
  #include <stdio.h>
-diff --git a/libebl/eblopenbackend.c b/libebl/eblopenbackend.c
-index 53713963..2e66dfdd 100644
---- a/libebl/eblopenbackend.c
-+++ b/libebl/eblopenbackend.c
-@@ -32,7 +32,7 @@
- 
- #include <assert.h>
- #include <dlfcn.h>
--#include <error.h>
-+#include <err.h>
- #include <libelfP.h>
- #include <dwarf.h>
- #include <stdlib.h>
 diff --git a/libelf/elf.h b/libelf/elf.h
-index 5cf2b934..990b3afb 100644
+index 5dc632b..14da1b7 100644
 --- a/libelf/elf.h
 +++ b/libelf/elf.h
 @@ -21,7 +21,9 @@
@@ -382,9 +187,9 @@
  
  /* Standard ELF types.  */
  
-@@ -3705,6 +3707,8 @@ enum
- #define R_BPF_NONE		0	/* No reloc */
- #define R_BPF_MAP_FD		1	/* Map fd to pointer */
+@@ -3937,6 +3939,8 @@ enum
+ #define R_METAG_TLS_LE_HI16	60
+ #define R_METAG_TLS_LE_LO16	61
  
 -__END_DECLS
 +#ifdef __cplusplus
@@ -393,7 +198,7 @@
  
  #endif	/* elf.h */
 diff --git a/libelf/libelf.h b/libelf/libelf.h
-index 547c0f50..dd78799e 100644
+index d11358c..4cf9272 100644
 --- a/libelf/libelf.h
 +++ b/libelf/libelf.h
 @@ -29,6 +29,7 @@
@@ -405,7 +210,7 @@
  #include <sys/types.h>
  
 diff --git a/libelf/libelfP.h b/libelf/libelfP.h
-index 7ee6625a..58408997 100644
+index ed216c8..415e6f6 100644
 --- a/libelf/libelfP.h
 +++ b/libelf/libelfP.h
 @@ -32,6 +32,7 @@
@@ -416,614 +221,6 @@
  
  #include <errno.h>
  #include <stdbool.h>
-diff --git a/src/addr2line.c b/src/addr2line.c
-index 444ee52c..9596fa67 100644
---- a/src/addr2line.c
-+++ b/src/addr2line.c
-@@ -23,7 +23,7 @@
- #include <argp.h>
- #include <assert.h>
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <inttypes.h>
- #include <libdwfl.h>
-diff --git a/src/ar.c b/src/ar.c
-index ec32cee5..4efd729c 100644
---- a/src/ar.c
-+++ b/src/ar.c
-@@ -22,7 +22,7 @@
- 
- #include <argp.h>
- #include <assert.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <gelf.h>
- #include <libintl.h>
-diff --git a/src/arlib.c b/src/arlib.c
-index e0839aab..1143658f 100644
---- a/src/arlib.c
-+++ b/src/arlib.c
-@@ -21,7 +21,7 @@
- #endif
- 
- #include <assert.h>
--#include <error.h>
-+#include <err.h>
- #include <gelf.h>
- #include <inttypes.h>
- #include <libintl.h>
-diff --git a/src/arlib2.c b/src/arlib2.c
-index 553fc57b..46443d0e 100644
---- a/src/arlib2.c
-+++ b/src/arlib2.c
-@@ -20,7 +20,7 @@
- # include <config.h>
- #endif
- 
--#include <error.h>
-+#include <err.h>
- #include <libintl.h>
- #include <limits.h>
- #include <string.h>
-diff --git a/src/elfcmp.c b/src/elfcmp.c
-index 50464207..cff183fa 100644
---- a/src/elfcmp.c
-+++ b/src/elfcmp.c
-@@ -23,7 +23,7 @@
- #include <argp.h>
- #include <assert.h>
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <locale.h>
- #include <libintl.h>
-diff --git a/src/elflint.c b/src/elflint.c
-index df1b3a03..67d8d134 100644
---- a/src/elflint.c
-+++ b/src/elflint.c
-@@ -24,7 +24,7 @@
- #include <assert.h>
- #include <byteswap.h>
- #include <endian.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <gelf.h>
- #include <inttypes.h>
-diff --git a/src/findtextrel.c b/src/findtextrel.c
-index 8f1e239a..71463af3 100644
---- a/src/findtextrel.c
-+++ b/src/findtextrel.c
-@@ -23,7 +23,7 @@
- #include <argp.h>
- #include <assert.h>
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <gelf.h>
- #include <libdw.h>
-diff --git a/src/nm.c b/src/nm.c
-index 969c6d35..3113c04c 100644
---- a/src/nm.c
-+++ b/src/nm.c
-@@ -26,7 +26,7 @@
- #include <ctype.h>
- #include <dwarf.h>
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <gelf.h>
- #include <inttypes.h>
-diff --git a/src/objdump.c b/src/objdump.c
-index 0dd9a6aa..9c8bf149 100644
---- a/src/objdump.c
-+++ b/src/objdump.c
-@@ -21,7 +21,7 @@
- #endif
- 
- #include <argp.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <inttypes.h>
- #include <libintl.h>
-diff --git a/src/ranlib.c b/src/ranlib.c
-index cc0ee233..ae851e40 100644
---- a/src/ranlib.c
-+++ b/src/ranlib.c
-@@ -24,7 +24,7 @@
- #include <argp.h>
- #include <assert.h>
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <gelf.h>
- #include <libintl.h>
-diff --git a/src/readelf.c b/src/readelf.c
-index 6a27e7e0..4759a965 100644
---- a/src/readelf.c
-+++ b/src/readelf.c
-@@ -25,7 +25,7 @@
- #include <ctype.h>
- #include <dwarf.h>
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <gelf.h>
- #include <inttypes.h>
-diff --git a/src/size.c b/src/size.c
-index ad8dbcbb..fd83be06 100644
---- a/src/size.c
-+++ b/src/size.c
-@@ -21,7 +21,7 @@
- #endif
- 
- #include <argp.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <gelf.h>
- #include <inttypes.h>
-diff --git a/src/stack.c b/src/stack.c
-index 6f2ff69f..6da0243d 100644
---- a/src/stack.c
-+++ b/src/stack.c
-@@ -18,7 +18,7 @@
- #include <config.h>
- #include <assert.h>
- #include <argp.h>
--#include <error.h>
-+#include <err.h>
- #include <stdlib.h>
- #include <inttypes.h>
- #include <stdio.h>
-diff --git a/src/strings.c b/src/strings.c
-index 03d0f133..5c311cbd 100644
---- a/src/strings.c
-+++ b/src/strings.c
-@@ -25,7 +25,7 @@
- #include <ctype.h>
- #include <endian.h>
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <gelf.h>
- #include <inttypes.h>
-diff --git a/src/strip.c b/src/strip.c
-index c7830ec6..0d7f148d 100644
---- a/src/strip.c
-+++ b/src/strip.c
-@@ -24,7 +24,7 @@
- #include <assert.h>
- #include <byteswap.h>
- #include <endian.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <fnmatch.h>
- #include <gelf.h>
-diff --git a/src/unstrip.c b/src/unstrip.c
-index 50749093..3d4f9525 100644
---- a/src/unstrip.c
-+++ b/src/unstrip.c
-@@ -31,7 +31,7 @@
- #include <argp.h>
- #include <assert.h>
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <fnmatch.h>
- #include <libintl.h>
-diff --git a/tests/addrscopes.c b/tests/addrscopes.c
-index 791569f5..54f4311b 100644
---- a/tests/addrscopes.c
-+++ b/tests/addrscopes.c
-@@ -25,7 +25,7 @@
- #include <stdio_ext.h>
- #include <locale.h>
- #include <stdlib.h>
--#include <error.h>
-+#include <err.h>
- #include <string.h>
- 
- 
-diff --git a/tests/allregs.c b/tests/allregs.c
-index 286f7e3c..c9de0897 100644
---- a/tests/allregs.c
-+++ b/tests/allregs.c
-@@ -21,7 +21,7 @@
- #include <stdio.h>
- #include <stdlib.h>
- #include <string.h>
--#include <error.h>
-+#include <err.h>
- #include <locale.h>
- #include <argp.h>
- #include <assert.h>
-diff --git a/tests/backtrace-data.c b/tests/backtrace-data.c
-index a387d8ff..955c27d1 100644
---- a/tests/backtrace-data.c
-+++ b/tests/backtrace-data.c
-@@ -27,7 +27,7 @@
- #include <dirent.h>
- #include <stdlib.h>
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <unistd.h>
- #include <dwarf.h>
- #if defined(__x86_64__) && defined(__linux__)
-diff --git a/tests/backtrace-dwarf.c b/tests/backtrace-dwarf.c
-index 2dc8a9a2..24ca7fb0 100644
---- a/tests/backtrace-dwarf.c
-+++ b/tests/backtrace-dwarf.c
-@@ -22,7 +22,7 @@
- #include <stdio_ext.h>
- #include <locale.h>
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <unistd.h>
- #include <sys/types.h>
- #include <sys/wait.h>
-diff --git a/tests/backtrace.c b/tests/backtrace.c
-index f5dd761f..a93a8f03 100644
---- a/tests/backtrace.c
-+++ b/tests/backtrace.c
-@@ -24,7 +24,7 @@
- #include <dirent.h>
- #include <stdlib.h>
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <unistd.h>
- #include <dwarf.h>
- #ifdef __linux__
-diff --git a/tests/buildid.c b/tests/buildid.c
-index 87c18773..2953e6bb 100644
---- a/tests/buildid.c
-+++ b/tests/buildid.c
-@@ -23,7 +23,7 @@
- #include ELFUTILS_HEADER(elf)
- #include ELFUTILS_HEADER(dwelf)
- #include <stdio.h>
--#include <error.h>
-+#include <err.h>
- #include <string.h>
- #include <stdlib.h>
- #include <sys/types.h>
-diff --git a/tests/debugaltlink.c b/tests/debugaltlink.c
-index 6d97d500..ee7e559e 100644
---- a/tests/debugaltlink.c
-+++ b/tests/debugaltlink.c
-@@ -23,7 +23,7 @@
- #include ELFUTILS_HEADER(dw)
- #include ELFUTILS_HEADER(dwelf)
- #include <stdio.h>
--#include <error.h>
-+#include <err.h>
- #include <string.h>
- #include <stdlib.h>
- #include <sys/types.h>
-diff --git a/tests/debuglink.c b/tests/debuglink.c
-index 935d1029..741cb814 100644
---- a/tests/debuglink.c
-+++ b/tests/debuglink.c
-@@ -21,7 +21,7 @@
- #include <errno.h>
- #include ELFUTILS_HEADER(dwelf)
- #include <stdio.h>
--#include <error.h>
-+#include <err.h>
- #include <string.h>
- #include <stdlib.h>
- #include <sys/types.h>
-diff --git a/tests/deleted.c b/tests/deleted.c
-index 6be35bc2..01907113 100644
---- a/tests/deleted.c
-+++ b/tests/deleted.c
-@@ -21,7 +21,7 @@
- #include <unistd.h>
- #include <assert.h>
- #include <stdio.h>
--#include <error.h>
-+#include <err.h>
- #include <errno.h>
- #ifdef __linux__
- #include <sys/prctl.h>
-diff --git a/tests/dwfl-addr-sect.c b/tests/dwfl-addr-sect.c
-index 21e470a3..1ea1e3b2 100644
---- a/tests/dwfl-addr-sect.c
-+++ b/tests/dwfl-addr-sect.c
-@@ -23,7 +23,7 @@
- #include <stdio_ext.h>
- #include <stdlib.h>
- #include <string.h>
--#include <error.h>
-+#include <err.h>
- #include <locale.h>
- #include <argp.h>
- #include ELFUTILS_HEADER(dwfl)
-diff --git a/tests/dwfl-bug-addr-overflow.c b/tests/dwfl-bug-addr-overflow.c
-index aa8030e1..02c8bef9 100644
---- a/tests/dwfl-bug-addr-overflow.c
-+++ b/tests/dwfl-bug-addr-overflow.c
-@@ -20,7 +20,7 @@
- #include <inttypes.h>
- #include <stdio.h>
- #include <stdio_ext.h>
--#include <error.h>
-+#include <err.h>
- #include <locale.h>
- #include ELFUTILS_HEADER(dwfl)
- 
-diff --git a/tests/dwfl-bug-fd-leak.c b/tests/dwfl-bug-fd-leak.c
-index 689cdd79..5973da39 100644
---- a/tests/dwfl-bug-fd-leak.c
-+++ b/tests/dwfl-bug-fd-leak.c
-@@ -24,7 +24,7 @@
- #include <dirent.h>
- #include <stdlib.h>
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <unistd.h>
- #include <dwarf.h>
- 
-diff --git a/tests/dwfl-bug-getmodules.c b/tests/dwfl-bug-getmodules.c
-index 1ee989f8..fd62e653 100644
---- a/tests/dwfl-bug-getmodules.c
-+++ b/tests/dwfl-bug-getmodules.c
-@@ -18,7 +18,7 @@
- #include <config.h>
- #include ELFUTILS_HEADER(dwfl)
- 
--#include <error.h>
-+#include <err.h>
- 
- static const Dwfl_Callbacks callbacks =
-   {
-diff --git a/tests/dwfl-report-elf-align.c b/tests/dwfl-report-elf-align.c
-index a4e97d3c..f471587c 100644
---- a/tests/dwfl-report-elf-align.c
-+++ b/tests/dwfl-report-elf-align.c
-@@ -20,7 +20,7 @@
- #include <inttypes.h>
- #include <stdio.h>
- #include <stdio_ext.h>
--#include <error.h>
-+#include <err.h>
- #include <locale.h>
- #include <string.h>
- #include <stdlib.h>
-diff --git a/tests/dwfllines.c b/tests/dwfllines.c
-index 90379dd2..cbdf6c4c 100644
---- a/tests/dwfllines.c
-+++ b/tests/dwfllines.c
-@@ -27,7 +27,7 @@
- #include <stdio.h>
- #include <stdlib.h>
- #include <string.h>
--#include <error.h>
-+#include <err.h>
- 
- int
- main (int argc, char *argv[])
-diff --git a/tests/dwflmodtest.c b/tests/dwflmodtest.c
-index 0027f96b..e68d3bca 100644
---- a/tests/dwflmodtest.c
-+++ b/tests/dwflmodtest.c
-@@ -23,7 +23,7 @@
- #include <stdio_ext.h>
- #include <stdlib.h>
- #include <string.h>
--#include <error.h>
-+#include <err.h>
- #include <locale.h>
- #include <argp.h>
- #include ELFUTILS_HEADER(dwfl)
-diff --git a/tests/dwflsyms.c b/tests/dwflsyms.c
-index 49ac3346..cf078301 100644
---- a/tests/dwflsyms.c
-+++ b/tests/dwflsyms.c
-@@ -25,7 +25,7 @@
- #include <stdio.h>
- #include <stdio_ext.h>
- #include <stdlib.h>
--#include <error.h>
-+#include <err.h>
- #include <string.h>
- 
- static const char *
-diff --git a/tests/early-offscn.c b/tests/early-offscn.c
-index 924cb9ef..6f60d5a3 100644
---- a/tests/early-offscn.c
-+++ b/tests/early-offscn.c
-@@ -19,7 +19,7 @@
- #endif
- 
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <gelf.h>
- #include <stdio.h>
-diff --git a/tests/ecp.c b/tests/ecp.c
-index 38a6859e..743cea5d 100644
---- a/tests/ecp.c
-+++ b/tests/ecp.c
-@@ -20,7 +20,7 @@
- #endif
- 
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <gelf.h>
- #include <stdlib.h>
-diff --git a/tests/find-prologues.c b/tests/find-prologues.c
-index ba8ae371..76f5f047 100644
---- a/tests/find-prologues.c
-+++ b/tests/find-prologues.c
-@@ -25,7 +25,7 @@
- #include <stdio_ext.h>
- #include <locale.h>
- #include <stdlib.h>
--#include <error.h>
-+#include <err.h>
- #include <string.h>
- #include <fnmatch.h>
- 
-diff --git a/tests/funcretval.c b/tests/funcretval.c
-index 8d19d117..c8aaa93d 100644
---- a/tests/funcretval.c
-+++ b/tests/funcretval.c
-@@ -25,7 +25,7 @@
- #include <stdio_ext.h>
- #include <locale.h>
- #include <stdlib.h>
--#include <error.h>
-+#include <err.h>
- #include <string.h>
- #include <fnmatch.h>
- 
-diff --git a/tests/funcscopes.c b/tests/funcscopes.c
-index 9c901858..dbccb89e 100644
---- a/tests/funcscopes.c
-+++ b/tests/funcscopes.c
-@@ -25,7 +25,7 @@
- #include <stdio_ext.h>
- #include <locale.h>
- #include <stdlib.h>
--#include <error.h>
-+#include <err.h>
- #include <string.h>
- #include <fnmatch.h>
- 
-diff --git a/tests/getsrc_die.c b/tests/getsrc_die.c
-index 055aede0..9c394dd0 100644
---- a/tests/getsrc_die.c
-+++ b/tests/getsrc_die.c
-@@ -19,7 +19,7 @@
- #endif
- 
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <inttypes.h>
- #include <libelf.h>
-diff --git a/tests/line2addr.c b/tests/line2addr.c
-index e0d65d3d..9bf0023b 100644
---- a/tests/line2addr.c
-+++ b/tests/line2addr.c
-@@ -26,7 +26,7 @@
- #include <locale.h>
- #include <stdlib.h>
- #include <string.h>
--#include <error.h>
-+#include <err.h>
- 
- 
- static void
-diff --git a/tests/low_high_pc.c b/tests/low_high_pc.c
-index d0f43023..8da4fbdf 100644
---- a/tests/low_high_pc.c
-+++ b/tests/low_high_pc.c
-@@ -25,7 +25,7 @@
- #include <stdio_ext.h>
- #include <locale.h>
- #include <stdlib.h>
--#include <error.h>
-+#include <err.h>
- #include <string.h>
- #include <fnmatch.h>
- 
-diff --git a/tests/md5-sha1-test.c b/tests/md5-sha1-test.c
-index d50355e9..3c41f40b 100644
---- a/tests/md5-sha1-test.c
-+++ b/tests/md5-sha1-test.c
-@@ -19,7 +19,7 @@
- #endif
- 
- #include <string.h>
--#include <error.h>
-+#include <err.h>
- 
- #include "md5.h"
- #include "sha1.h"
-diff --git a/tests/rdwrmmap.c b/tests/rdwrmmap.c
-index 6f027dfe..1ce5e6ed 100644
---- a/tests/rdwrmmap.c
-+++ b/tests/rdwrmmap.c
-@@ -19,7 +19,7 @@
- #endif
- 
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <stdio.h>
- #include <fcntl.h>
- #include <unistd.h>
-diff --git a/tests/saridx.c b/tests/saridx.c
-index 8a450d82..b3878013 100644
---- a/tests/saridx.c
-+++ b/tests/saridx.c
-@@ -17,7 +17,7 @@
- 
- #include <config.h>
- 
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <gelf.h>
- #include <stdio.h>
-diff --git a/tests/sectiondump.c b/tests/sectiondump.c
-index 3033fedc..8e888db3 100644
---- a/tests/sectiondump.c
-+++ b/tests/sectiondump.c
-@@ -18,7 +18,7 @@
- #include <config.h>
- 
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <fcntl.h>
- #include <gelf.h>
- #include <inttypes.h>
-diff --git a/tests/varlocs.c b/tests/varlocs.c
-index c3fba89e..e043ea2c 100644
---- a/tests/varlocs.c
-+++ b/tests/varlocs.c
-@@ -25,7 +25,7 @@
- #include <dwarf.h>
- #include <stdio.h>
- #include <stdlib.h>
--#include <error.h>
-+#include <err.h>
- #include <string.h>
- #include <sys/types.h>
- #include <sys/stat.h>
-diff --git a/tests/vdsosyms.c b/tests/vdsosyms.c
-index b876c10b..afb28232 100644
---- a/tests/vdsosyms.c
-+++ b/tests/vdsosyms.c
-@@ -18,7 +18,7 @@
- #include <config.h>
- #include <assert.h>
- #include <errno.h>
--#include <error.h>
-+#include <err.h>
- #include <inttypes.h>
- #include <stdio.h>
- #include <string.h>
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/elfutils/files/debian/0001-Ignore-differences-between-mips-machine-identifiers.patch b/poky/meta/recipes-devtools/elfutils/files/debian/0001-Ignore-differences-between-mips-machine-identifiers.patch
index e0291b4..8c48f4d 100644
--- a/poky/meta/recipes-devtools/elfutils/files/debian/0001-Ignore-differences-between-mips-machine-identifiers.patch
+++ b/poky/meta/recipes-devtools/elfutils/files/debian/0001-Ignore-differences-between-mips-machine-identifiers.patch
@@ -1,3 +1,6 @@
+Upstream-Status: Pending [from debian]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+
 From 77cb4a53c270d5854d3af24f19547bc3de825233 Mon Sep 17 00:00:00 2001
 From: James Cowgill <james410@cowgill.org.uk>
 Date: Mon, 5 Jan 2015 15:16:58 +0000
@@ -8,10 +11,6 @@
 kernel will not load binaries containing it).
 
 Signed-off-by: James Cowgill <james410@cowgill.org.uk>
-
-Upstream-Status: Backport [from debian]
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
-
 ---
  backends/mips_init.c | 6 +-----
  1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/poky/meta/recipes-devtools/elfutils/files/debian/0001-arm_backend.patch b/poky/meta/recipes-devtools/elfutils/files/debian/0001-arm_backend.patch
new file mode 100644
index 0000000..4ed8119
--- /dev/null
+++ b/poky/meta/recipes-devtools/elfutils/files/debian/0001-arm_backend.patch
@@ -0,0 +1,627 @@
+From a95f370bc2690c150c46f215543de278469900eb Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Fri, 29 Jun 2018 15:42:39 +0800
+Subject: [PATCH] arm_backend
+
+Upstream-Status: Pending [from debian]
+arm_backend.diff and rebase to 0.172
+
+http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ backends/arm_init.c                 |  18 ++++-
+ backends/arm_regs.c                 | 132 ++++++++++++++++++++++++++++++++++++
+ backends/arm_retval.c               |  43 +++++++++++-
+ backends/libebl_arm.h               |   9 +++
+ libelf/elf.h                        |  11 +++
+ tests/run-addrcfi.sh                |  93 ++++++++++++++++++++++++-
+ tests/run-allregs.sh                |  95 +++++++++++++++++++++++++-
+ tests/run-readelf-mixed-corenote.sh |  11 ++-
+ 8 files changed, 400 insertions(+), 12 deletions(-)
+ create mode 100644 backends/libebl_arm.h
+
+diff --git a/backends/arm_init.c b/backends/arm_init.c
+index f2b1b11..1b71f16 100644
+--- a/backends/arm_init.c
++++ b/backends/arm_init.c
+@@ -35,20 +35,31 @@
+ #define RELOC_PREFIX	R_ARM_
+ #include "libebl_CPU.h"
+ 
++#include "libebl_arm.h"
++
+ /* This defines the common reloc hooks based on arm_reloc.def.  */
+ #include "common-reloc.c"
+ 
+ 
+ const char *
+-arm_init (Elf *elf __attribute__ ((unused)),
++arm_init (Elf *elf,
+ 	  GElf_Half machine __attribute__ ((unused)),
+ 	  Ebl *eh,
+ 	  size_t ehlen)
+ {
++  int soft_float = 0;
++
+   /* Check whether the Elf_BH object has a sufficent size.  */
+   if (ehlen < sizeof (Ebl))
+     return NULL;
+ 
++  if (elf) {
++    GElf_Ehdr ehdr_mem;
++    GElf_Ehdr *ehdr = gelf_getehdr (elf, &ehdr_mem);
++    if (ehdr && (ehdr->e_flags & EF_ARM_SOFT_FLOAT))
++      soft_float = 1;
++  }
++
+   /* We handle it.  */
+   eh->name = "ARM";
+   arm_init_reloc (eh);
+@@ -60,7 +71,10 @@ arm_init (Elf *elf __attribute__ ((unused)),
+   HOOK (eh, core_note);
+   HOOK (eh, auxv_info);
+   HOOK (eh, check_object_attribute);
+-  HOOK (eh, return_value_location);
++  if (soft_float)
++    eh->return_value_location = arm_return_value_location_soft;
++  else
++    eh->return_value_location = arm_return_value_location_hard;
+   HOOK (eh, abi_cfi);
+   HOOK (eh, check_reloc_target_type);
+   HOOK (eh, symbol_type_name);
+diff --git a/backends/arm_regs.c b/backends/arm_regs.c
+index a46a4c9..418c931 100644
+--- a/backends/arm_regs.c
++++ b/backends/arm_regs.c
+@@ -31,6 +31,7 @@
+ #endif
+ 
+ #include <string.h>
++#include <stdio.h>
+ #include <dwarf.h>
+ 
+ #define BACKEND arm_
+@@ -76,6 +77,9 @@ arm_register_info (Ebl *ebl __attribute__ ((unused)),
+       break;
+ 
+     case 16 + 0 ... 16 + 7:
++      /* AADWARF says that there are no registers in that range,
++       * but gcc maps FPA registers here
++       */
+       regno += 96 - 16;
+       FALLTHROUGH;
+     case 96 + 0 ... 96 + 7:
+@@ -87,11 +91,139 @@ arm_register_info (Ebl *ebl __attribute__ ((unused)),
+       namelen = 2;
+       break;
+ 
++    case 64 + 0 ... 64 + 9:
++      *setname = "VFP";
++      *bits = 32;
++      *type = DW_ATE_float;
++      name[0] = 's';
++      name[1] = regno - 64 + '0';
++      namelen = 2;
++      break;
++
++    case 64 + 10 ... 64 + 31:
++      *setname = "VFP";
++      *bits = 32;
++      *type = DW_ATE_float;
++      name[0] = 's';
++      name[1] = (regno - 64) / 10 + '0';
++      name[2] = (regno - 64) % 10 + '0';
++      namelen = 3;
++      break;
++
++    case 104 + 0 ... 104 + 7:
++      /* XXX TODO:
++       * This can be either intel wireless MMX general purpose/control
++       * registers or xscale accumulator, which have different usage.
++       * We only have the intel wireless MMX here now.
++       * The name needs to be changed for the xscale accumulator too. */
++      *setname = "MMX";
++      *type = DW_ATE_unsigned;
++      *bits = 32;
++      memcpy(name, "wcgr", 4);
++      name[4] = regno - 104 + '0';
++      namelen = 5;
++      break;
++
++    case 112 + 0 ... 112 + 9:
++      *setname = "MMX";
++      *type = DW_ATE_unsigned;
++      *bits = 64;
++      name[0] = 'w';
++      name[1] = 'r';
++      name[2] = regno - 112 + '0';
++      namelen = 3;
++      break;
++
++    case 112 + 10 ... 112 + 15:
++      *setname = "MMX";
++      *type = DW_ATE_unsigned;
++      *bits = 64;
++      name[0] = 'w';
++      name[1] = 'r';
++      name[2] = '1';
++      name[3] = regno - 112 - 10 + '0';
++      namelen = 4;
++      break;
++
+     case 128:
++      *setname = "state";
+       *type = DW_ATE_unsigned;
+       return stpcpy (name, "spsr") + 1 - name;
+ 
++    case 129:
++      *setname = "state";
++      *type = DW_ATE_unsigned;
++      return stpcpy(name, "spsr_fiq") + 1 - name;
++
++    case 130:
++      *setname = "state";
++      *type = DW_ATE_unsigned;
++      return stpcpy(name, "spsr_irq") + 1 - name;
++
++    case 131:
++      *setname = "state";
++      *type = DW_ATE_unsigned;
++      return stpcpy(name, "spsr_abt") + 1 - name;
++
++    case 132:
++      *setname = "state";
++      *type = DW_ATE_unsigned;
++      return stpcpy(name, "spsr_und") + 1 - name;
++
++    case 133:
++      *setname = "state";
++      *type = DW_ATE_unsigned;
++      return stpcpy(name, "spsr_svc") + 1 - name;
++
++    case 144 ... 150:
++      *setname = "integer";
++      *type = DW_ATE_signed;
++      *bits = 32;
++      return sprintf(name, "r%d_usr", regno - 144 + 8) + 1;
++
++    case 151 ... 157:
++      *setname = "integer";
++      *type = DW_ATE_signed;
++      *bits = 32;
++      return sprintf(name, "r%d_fiq", regno - 151 + 8) + 1;
++
++    case 158 ... 159:
++      *setname = "integer";
++      *type = DW_ATE_signed;
++      *bits = 32;
++      return sprintf(name, "r%d_irq", regno - 158 + 13) + 1;
++
++    case 160 ... 161:
++      *setname = "integer";
++      *type = DW_ATE_signed;
++      *bits = 32;
++      return sprintf(name, "r%d_abt", regno - 160 + 13) + 1;
++
++    case 162 ... 163:
++      *setname = "integer";
++      *type = DW_ATE_signed;
++      *bits = 32;
++      return sprintf(name, "r%d_und", regno - 162 + 13) + 1;
++
++    case 164 ... 165:
++      *setname = "integer";
++      *type = DW_ATE_signed;
++      *bits = 32;
++      return sprintf(name, "r%d_svc", regno - 164 + 13) + 1;
++
++    case 192 ... 199:
++     *setname = "MMX";
++      *bits = 32;
++      *type = DW_ATE_unsigned;
++      name[0] = 'w';
++      name[1] = 'c';
++      name[2] = regno - 192 + '0';
++      namelen = 3;
++      break;
++
+     case 256 + 0 ... 256 + 9:
++      /* XXX TODO: Neon also uses those registers and can contain
++       * both float and integers */
+       *setname = "VFP";
+       *type = DW_ATE_float;
+       *bits = 64;
+diff --git a/backends/arm_retval.c b/backends/arm_retval.c
+index 1c28f01..313e4eb 100644
+--- a/backends/arm_retval.c
++++ b/backends/arm_retval.c
+@@ -48,6 +48,13 @@ static const Dwarf_Op loc_intreg[] =
+ #define nloc_intreg	1
+ #define nloc_intregs(n)	(2 * (n))
+ 
++/* f1  */ /* XXX TODO: f0 can also have number 96 if program was compiled with -mabi=aapcs */
++static const Dwarf_Op loc_fpreg[] =
++  {
++    { .atom = DW_OP_reg16 },
++  };
++#define nloc_fpreg  1
++
+ /* The return value is a structure and is actually stored in stack space
+    passed in a hidden argument by the caller.  But, the compiler
+    helpfully returns the address of that space in r0.  */
+@@ -58,8 +65,9 @@ static const Dwarf_Op loc_aggregate[] =
+ #define nloc_aggregate 1
+ 
+ 
+-int
+-arm_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
++static int
++arm_return_value_location_ (Dwarf_Die *functypedie, const Dwarf_Op **locp,
++		            int soft_float)
+ {
+   /* Start with the function's type, and get the DW_AT_type attribute,
+      which is the type of the return value.  */
+@@ -98,6 +106,21 @@ arm_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
+ 	    else
+ 	      return -1;
+ 	  }
++	if (tag == DW_TAG_base_type)
++	  {
++	    Dwarf_Word encoding;
++	    if (dwarf_formudata (dwarf_attr_integrate (typedie, DW_AT_encoding,
++				 &attr_mem), &encoding) != 0)
++	      return -1;
++
++	    if ((encoding == DW_ATE_float) && !soft_float)
++	      {
++		*locp = loc_fpreg;
++		if (size <= 8)
++		  return nloc_fpreg;
++		goto aggregate;
++	      }
++	  }
+ 	if (size <= 16)
+ 	  {
+ 	  intreg:
+@@ -106,6 +129,7 @@ arm_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
+ 	  }
+ 
+       aggregate:
++	/* XXX TODO sometimes aggregates are returned in r0 (-mabi=aapcs) */
+ 	*locp = loc_aggregate;
+ 	return nloc_aggregate;
+       }
+@@ -125,3 +149,18 @@ arm_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
+      DWARF and might be valid.  */
+   return -2;
+ }
++
++/* return location for -mabi=apcs-gnu -msoft-float */
++int
++arm_return_value_location_soft (Dwarf_Die *functypedie, const Dwarf_Op **locp)
++{
++   return arm_return_value_location_ (functypedie, locp, 1);
++}
++
++/* return location for -mabi=apcs-gnu -mhard-float (current default) */
++int
++arm_return_value_location_hard (Dwarf_Die *functypedie, const Dwarf_Op **locp)
++{
++   return arm_return_value_location_ (functypedie, locp, 0);
++}
++
+diff --git a/backends/libebl_arm.h b/backends/libebl_arm.h
+new file mode 100644
+index 0000000..c00770c
+--- /dev/null
++++ b/backends/libebl_arm.h
+@@ -0,0 +1,9 @@
++#ifndef _LIBEBL_ARM_H
++#define _LIBEBL_ARM_H 1
++
++#include <libdw.h>
++
++extern int arm_return_value_location_soft(Dwarf_Die *, const Dwarf_Op **locp);
++extern int arm_return_value_location_hard(Dwarf_Die *, const Dwarf_Op **locp);
++
++#endif
+diff --git a/libelf/elf.h b/libelf/elf.h
+index 6c9f61e..6d82fef 100644
+--- a/libelf/elf.h
++++ b/libelf/elf.h
+@@ -2692,6 +2692,9 @@ enum
+ #define EF_ARM_EABI_VER4	0x04000000
+ #define EF_ARM_EABI_VER5	0x05000000
+ 
++/* EI_OSABI values */
++#define ELFOSABI_ARM_AEABI    64      /* Contains symbol versioning. */
++
+ /* Additional symbol types for Thumb.  */
+ #define STT_ARM_TFUNC		STT_LOPROC /* A Thumb function.  */
+ #define STT_ARM_16BIT		STT_HIPROC /* A Thumb label.  */
+@@ -2709,12 +2712,19 @@ enum
+ 
+ /* Processor specific values for the Phdr p_type field.  */
+ #define PT_ARM_EXIDX		(PT_LOPROC + 1)	/* ARM unwind segment.  */
++#define PT_ARM_UNWIND		PT_ARM_EXIDX
+ 
+ /* Processor specific values for the Shdr sh_type field.  */
+ #define SHT_ARM_EXIDX		(SHT_LOPROC + 1) /* ARM unwind section.  */
+ #define SHT_ARM_PREEMPTMAP	(SHT_LOPROC + 2) /* Preemption details.  */
+ #define SHT_ARM_ATTRIBUTES	(SHT_LOPROC + 3) /* ARM attributes section.  */
+ 
++/* Processor specific values for the Dyn d_tag field.  */
++#define DT_ARM_RESERVED1	(DT_LOPROC + 0)
++#define DT_ARM_SYMTABSZ		(DT_LOPROC + 1)
++#define DT_ARM_PREEMTMAB	(DT_LOPROC + 2)
++#define DT_ARM_RESERVED2	(DT_LOPROC + 3)
++#define DT_ARM_NUM		4
+ 
+ /* AArch64 relocs.  */
+ 
+@@ -3007,6 +3017,7 @@ enum
+ 					   TLS block (LDR, STR).  */
+ #define R_ARM_TLS_IE12GP	111	/* 12 bit GOT entry relative
+ 					   to GOT origin (LDR).  */
++/* 112 - 127 private range */
+ #define R_ARM_ME_TOO		128	/* Obsolete.  */
+ #define R_ARM_THM_TLS_DESCSEQ	129
+ #define R_ARM_THM_TLS_DESCSEQ16	129
+diff --git a/tests/run-addrcfi.sh b/tests/run-addrcfi.sh
+index fd89d02..462d7c5 100755
+--- a/tests/run-addrcfi.sh
++++ b/tests/run-addrcfi.sh
+@@ -3554,6 +3554,38 @@ dwarf_cfi_addrframe (.eh_frame): no matching address range
+ 	FPA reg21 (f5): undefined
+ 	FPA reg22 (f6): undefined
+ 	FPA reg23 (f7): undefined
++	VFP reg64 (s0): undefined
++	VFP reg65 (s1): undefined
++	VFP reg66 (s2): undefined
++	VFP reg67 (s3): undefined
++	VFP reg68 (s4): undefined
++	VFP reg69 (s5): undefined
++	VFP reg70 (s6): undefined
++	VFP reg71 (s7): undefined
++	VFP reg72 (s8): undefined
++	VFP reg73 (s9): undefined
++	VFP reg74 (s10): undefined
++	VFP reg75 (s11): undefined
++	VFP reg76 (s12): undefined
++	VFP reg77 (s13): undefined
++	VFP reg78 (s14): undefined
++	VFP reg79 (s15): undefined
++	VFP reg80 (s16): undefined
++	VFP reg81 (s17): undefined
++	VFP reg82 (s18): undefined
++	VFP reg83 (s19): undefined
++	VFP reg84 (s20): undefined
++	VFP reg85 (s21): undefined
++	VFP reg86 (s22): undefined
++	VFP reg87 (s23): undefined
++	VFP reg88 (s24): undefined
++	VFP reg89 (s25): undefined
++	VFP reg90 (s26): undefined
++	VFP reg91 (s27): undefined
++	VFP reg92 (s28): undefined
++	VFP reg93 (s29): undefined
++	VFP reg94 (s30): undefined
++	VFP reg95 (s31): undefined
+ 	FPA reg96 (f0): undefined
+ 	FPA reg97 (f1): undefined
+ 	FPA reg98 (f2): undefined
+@@ -3562,7 +3594,66 @@ dwarf_cfi_addrframe (.eh_frame): no matching address range
+ 	FPA reg101 (f5): undefined
+ 	FPA reg102 (f6): undefined
+ 	FPA reg103 (f7): undefined
+-	integer reg128 (spsr): undefined
++	MMX reg104 (wcgr0): undefined
++	MMX reg105 (wcgr1): undefined
++	MMX reg106 (wcgr2): undefined
++	MMX reg107 (wcgr3): undefined
++	MMX reg108 (wcgr4): undefined
++	MMX reg109 (wcgr5): undefined
++	MMX reg110 (wcgr6): undefined
++	MMX reg111 (wcgr7): undefined
++	MMX reg112 (wr0): undefined
++	MMX reg113 (wr1): undefined
++	MMX reg114 (wr2): undefined
++	MMX reg115 (wr3): undefined
++	MMX reg116 (wr4): undefined
++	MMX reg117 (wr5): undefined
++	MMX reg118 (wr6): undefined
++	MMX reg119 (wr7): undefined
++	MMX reg120 (wr8): undefined
++	MMX reg121 (wr9): undefined
++	MMX reg122 (wr10): undefined
++	MMX reg123 (wr11): undefined
++	MMX reg124 (wr12): undefined
++	MMX reg125 (wr13): undefined
++	MMX reg126 (wr14): undefined
++	MMX reg127 (wr15): undefined
++	state reg128 (spsr): undefined
++	state reg129 (spsr_fiq): undefined
++	state reg130 (spsr_irq): undefined
++	state reg131 (spsr_abt): undefined
++	state reg132 (spsr_und): undefined
++	state reg133 (spsr_svc): undefined
++	integer reg144 (r8_usr): undefined
++	integer reg145 (r9_usr): undefined
++	integer reg146 (r10_usr): undefined
++	integer reg147 (r11_usr): undefined
++	integer reg148 (r12_usr): undefined
++	integer reg149 (r13_usr): undefined
++	integer reg150 (r14_usr): undefined
++	integer reg151 (r8_fiq): undefined
++	integer reg152 (r9_fiq): undefined
++	integer reg153 (r10_fiq): undefined
++	integer reg154 (r11_fiq): undefined
++	integer reg155 (r12_fiq): undefined
++	integer reg156 (r13_fiq): undefined
++	integer reg157 (r14_fiq): undefined
++	integer reg158 (r13_irq): undefined
++	integer reg159 (r14_irq): undefined
++	integer reg160 (r13_abt): undefined
++	integer reg161 (r14_abt): undefined
++	integer reg162 (r13_und): undefined
++	integer reg163 (r14_und): undefined
++	integer reg164 (r13_svc): undefined
++	integer reg165 (r14_svc): undefined
++	MMX reg192 (wc0): undefined
++	MMX reg193 (wc1): undefined
++	MMX reg194 (wc2): undefined
++	MMX reg195 (wc3): undefined
++	MMX reg196 (wc4): undefined
++	MMX reg197 (wc5): undefined
++	MMX reg198 (wc6): undefined
++	MMX reg199 (wc7): undefined
+ 	VFP reg256 (d0): undefined
+ 	VFP reg257 (d1): undefined
+ 	VFP reg258 (d2): undefined
+diff --git a/tests/run-allregs.sh b/tests/run-allregs.sh
+index 7ddd452..a31dba4 100755
+--- a/tests/run-allregs.sh
++++ b/tests/run-allregs.sh
+@@ -2672,7 +2672,28 @@ integer registers:
+ 	 13: sp (sp), address 32 bits
+ 	 14: lr (lr), address 32 bits
+ 	 15: pc (pc), address 32 bits
+-	128: spsr (spsr), unsigned 32 bits
++	144: r8_usr (r8_usr), signed 32 bits
++	145: r9_usr (r9_usr), signed 32 bits
++	146: r10_usr (r10_usr), signed 32 bits
++	147: r11_usr (r11_usr), signed 32 bits
++	148: r12_usr (r12_usr), signed 32 bits
++	149: r13_usr (r13_usr), signed 32 bits
++	150: r14_usr (r14_usr), signed 32 bits
++	151: r8_fiq (r8_fiq), signed 32 bits
++	152: r9_fiq (r9_fiq), signed 32 bits
++	153: r10_fiq (r10_fiq), signed 32 bits
++	154: r11_fiq (r11_fiq), signed 32 bits
++	155: r12_fiq (r12_fiq), signed 32 bits
++	156: r13_fiq (r13_fiq), signed 32 bits
++	157: r14_fiq (r14_fiq), signed 32 bits
++	158: r13_irq (r13_irq), signed 32 bits
++	159: r14_irq (r14_irq), signed 32 bits
++	160: r13_abt (r13_abt), signed 32 bits
++	161: r14_abt (r14_abt), signed 32 bits
++	162: r13_und (r13_und), signed 32 bits
++	163: r14_und (r14_und), signed 32 bits
++	164: r13_svc (r13_svc), signed 32 bits
++	165: r14_svc (r14_svc), signed 32 bits
+ FPA registers:
+ 	 16: f0 (f0), float 96 bits
+ 	 17: f1 (f1), float 96 bits
+@@ -2690,7 +2711,72 @@ FPA registers:
+ 	101: f5 (f5), float 96 bits
+ 	102: f6 (f6), float 96 bits
+ 	103: f7 (f7), float 96 bits
++MMX registers:
++	104: wcgr0 (wcgr0), unsigned 32 bits
++	105: wcgr1 (wcgr1), unsigned 32 bits
++	106: wcgr2 (wcgr2), unsigned 32 bits
++	107: wcgr3 (wcgr3), unsigned 32 bits
++	108: wcgr4 (wcgr4), unsigned 32 bits
++	109: wcgr5 (wcgr5), unsigned 32 bits
++	110: wcgr6 (wcgr6), unsigned 32 bits
++	111: wcgr7 (wcgr7), unsigned 32 bits
++	112: wr0 (wr0), unsigned 64 bits
++	113: wr1 (wr1), unsigned 64 bits
++	114: wr2 (wr2), unsigned 64 bits
++	115: wr3 (wr3), unsigned 64 bits
++	116: wr4 (wr4), unsigned 64 bits
++	117: wr5 (wr5), unsigned 64 bits
++	118: wr6 (wr6), unsigned 64 bits
++	119: wr7 (wr7), unsigned 64 bits
++	120: wr8 (wr8), unsigned 64 bits
++	121: wr9 (wr9), unsigned 64 bits
++	122: wr10 (wr10), unsigned 64 bits
++	123: wr11 (wr11), unsigned 64 bits
++	124: wr12 (wr12), unsigned 64 bits
++	125: wr13 (wr13), unsigned 64 bits
++	126: wr14 (wr14), unsigned 64 bits
++	127: wr15 (wr15), unsigned 64 bits
++	192: wc0 (wc0), unsigned 32 bits
++	193: wc1 (wc1), unsigned 32 bits
++	194: wc2 (wc2), unsigned 32 bits
++	195: wc3 (wc3), unsigned 32 bits
++	196: wc4 (wc4), unsigned 32 bits
++	197: wc5 (wc5), unsigned 32 bits
++	198: wc6 (wc6), unsigned 32 bits
++	199: wc7 (wc7), unsigned 32 bits
+ VFP registers:
++	 64: s0 (s0), float 32 bits
++	 65: s1 (s1), float 32 bits
++	 66: s2 (s2), float 32 bits
++	 67: s3 (s3), float 32 bits
++	 68: s4 (s4), float 32 bits
++	 69: s5 (s5), float 32 bits
++	 70: s6 (s6), float 32 bits
++	 71: s7 (s7), float 32 bits
++	 72: s8 (s8), float 32 bits
++	 73: s9 (s9), float 32 bits
++	 74: s10 (s10), float 32 bits
++	 75: s11 (s11), float 32 bits
++	 76: s12 (s12), float 32 bits
++	 77: s13 (s13), float 32 bits
++	 78: s14 (s14), float 32 bits
++	 79: s15 (s15), float 32 bits
++	 80: s16 (s16), float 32 bits
++	 81: s17 (s17), float 32 bits
++	 82: s18 (s18), float 32 bits
++	 83: s19 (s19), float 32 bits
++	 84: s20 (s20), float 32 bits
++	 85: s21 (s21), float 32 bits
++	 86: s22 (s22), float 32 bits
++	 87: s23 (s23), float 32 bits
++	 88: s24 (s24), float 32 bits
++	 89: s25 (s25), float 32 bits
++	 90: s26 (s26), float 32 bits
++	 91: s27 (s27), float 32 bits
++	 92: s28 (s28), float 32 bits
++	 93: s29 (s29), float 32 bits
++	 94: s30 (s30), float 32 bits
++	 95: s31 (s31), float 32 bits
+ 	256: d0 (d0), float 64 bits
+ 	257: d1 (d1), float 64 bits
+ 	258: d2 (d2), float 64 bits
+@@ -2723,6 +2809,13 @@ VFP registers:
+ 	285: d29 (d29), float 64 bits
+ 	286: d30 (d30), float 64 bits
+ 	287: d31 (d31), float 64 bits
++state registers:
++	128: spsr (spsr), unsigned 32 bits
++	129: spsr_fiq (spsr_fiq), unsigned 32 bits
++	130: spsr_irq (spsr_irq), unsigned 32 bits
++	131: spsr_abt (spsr_abt), unsigned 32 bits
++	132: spsr_und (spsr_und), unsigned 32 bits
++	133: spsr_svc (spsr_svc), unsigned 32 bits
+ EOF
+ 
+ # See run-readelf-mixed-corenote.sh for instructions to regenerate
+diff --git a/tests/run-readelf-mixed-corenote.sh b/tests/run-readelf-mixed-corenote.sh
+index 86171c4..018612f 100755
+--- a/tests/run-readelf-mixed-corenote.sh
++++ b/tests/run-readelf-mixed-corenote.sh
+@@ -31,12 +31,11 @@ Note segment of 892 bytes at offset 0x274:
+     pid: 11087, ppid: 11063, pgrp: 11087, sid: 11063
+     utime: 0.000000, stime: 0.010000, cutime: 0.000000, cstime: 0.000000
+     orig_r0: -1, fpvalid: 1
+-    r0:             1  r1:   -1091672508  r2:   -1091672500
+-    r3:             0  r4:             0  r5:             0
+-    r6:         33728  r7:             0  r8:             0
+-    r9:             0  r10:  -1225703496  r11:  -1091672844
+-    r12:            0  sp:    0xbeee64f4  lr:    0xb6dc3f48
+-    pc:    0x00008500  spsr:  0x60000010
++    r0:            1  r1:  -1091672508  r2:  -1091672500  r3:            0
++    r4:            0  r5:            0  r6:        33728  r7:            0
++    r8:            0  r9:            0  r10: -1225703496  r11: -1091672844
++    r12:           0  sp:   0xbeee64f4  lr:   0xb6dc3f48  pc:   0x00008500
++    spsr:  0x60000010
+   CORE                 124  PRPSINFO
+     state: 0, sname: R, zomb: 0, nice: 0, flag: 0x00400500
+     uid: 0, gid: 0, pid: 11087, ppid: 11063, pgrp: 11087, sid: 11063
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/elfutils/files/debian/0001-disable_werror.patch b/poky/meta/recipes-devtools/elfutils/files/debian/0001-disable_werror.patch
new file mode 100644
index 0000000..0f32b87
--- /dev/null
+++ b/poky/meta/recipes-devtools/elfutils/files/debian/0001-disable_werror.patch
@@ -0,0 +1,35 @@
+From 5d45565e71ddab3d7848077b61eb0ca73c0bcbcc Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Fri, 29 Jun 2018 16:01:14 +0800
+Subject: [PATCH] disable -Werror as it tends to break with new gcc versions
+
+Bug-Debian: https://bugs.debian.org/886004
+Last-Update: 2018-01-01
+
+Signed-off-by: Helmut Grohne <helmut@subdivi.de>
+
+Upstream-Status: Pending [from debian]
+mdisable_werror.patc and rebase to 0.172
+
+http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ config/eu.am | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/config/eu.am b/config/eu.am
+index c2cc349..99b368e 100644
+--- a/config/eu.am
++++ b/config/eu.am
+@@ -73,7 +73,6 @@ AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 \
+ 	    -Wold-style-definition -Wstrict-prototypes \
+ 	    $(LOGICAL_OP_WARNING) $(DUPLICATED_COND_WARNING) \
+ 	    $(NULL_DEREFERENCE_WARNING) $(IMPLICIT_FALLTHROUGH_WARNING) \
+-	    $(if $($(*F)_no_Werror),,-Werror) \
+ 	    $(if $($(*F)_no_Wunused),,-Wunused -Wextra) \
+ 	    $(if $($(*F)_no_Wstack_usage),,$(STACK_USAGE_WARNING)) \
+ 	    $(if $($(*F)_no_Wpacked_not_aligned),-Wno-packed-not-aligned,) \
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/elfutils/files/debian/0001-fix-gcc7-ftbfs.patch b/poky/meta/recipes-devtools/elfutils/files/debian/0001-fix-gcc7-ftbfs.patch
new file mode 100644
index 0000000..26869a3
--- /dev/null
+++ b/poky/meta/recipes-devtools/elfutils/files/debian/0001-fix-gcc7-ftbfs.patch
@@ -0,0 +1,57 @@
+From 91c0a0da2a8932f163d57db5d9d847bed6822502 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Fri, 29 Jun 2018 15:59:57 +0800
+Subject: [PATCH] fix gcc7 ftbfs
+
+Upstream-Status: Pending [from debian]
+fix-gcc7-ftbfs.diff and rebase to 0.172
+
+http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ backends/mips_retval.c   | 1 +
+ backends/parisc_retval.c | 1 +
+ src/ar.c                 | 2 +-
+ 3 files changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/backends/mips_retval.c b/backends/mips_retval.c
+index 57487bb..e7973a8 100644
+--- a/backends/mips_retval.c
++++ b/backends/mips_retval.c
+@@ -390,6 +390,7 @@ mips_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
+         }
+ 
+       /* Fallthrough to handle large types */
++      /* Fall through.  */
+ 
+     case DW_TAG_array_type:
+     large:
+diff --git a/backends/parisc_retval.c b/backends/parisc_retval.c
+index df7ec3a..988e1fe 100644
+--- a/backends/parisc_retval.c
++++ b/backends/parisc_retval.c
+@@ -167,6 +167,7 @@ parisc_return_value_location_ (Dwarf_Die *functypedie, const Dwarf_Op **locp, in
+ 
+ 	/* Else fall through.  */
+       }
++      /* Fall through.  */
+ 
+     case DW_TAG_structure_type:
+     case DW_TAG_class_type:
+diff --git a/src/ar.c b/src/ar.c
+index 818115b..c77e9f4 100644
+--- a/src/ar.c
++++ b/src/ar.c
+@@ -1073,7 +1073,7 @@ do_oper_delete (const char *arfname, char **argv, int argc,
+ static bool
+ no0print (bool ofmt, char *buf, int bufsize, long int val)
+ {
+-  char tmpbuf[bufsize + 1];
++  char tmpbuf[bufsize + 1 + 4];
+   int ret = snprintf (tmpbuf, sizeof (tmpbuf), ofmt ? "%-*lo" : "%-*ld",
+ 		      bufsize, val);
+   if (ret >= (int) sizeof (tmpbuf))
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/elfutils/files/debian/0001-hppa_backend.patch b/poky/meta/recipes-devtools/elfutils/files/debian/0001-hppa_backend.patch
new file mode 100644
index 0000000..2c5d4fa
--- /dev/null
+++ b/poky/meta/recipes-devtools/elfutils/files/debian/0001-hppa_backend.patch
@@ -0,0 +1,840 @@
+From c510c6c8523246dd79c6ea28d1646b153c23e491 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Fri, 29 Jun 2018 15:39:46 +0800
+Subject: [PATCH] hppa_backend
+
+Upstream-Status: Pending [from debian]
+hppa_backend.diff and rebase to 0.172
+
+http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ backends/Makefile.am      |   9 +-
+ backends/libebl_parisc.h  |   9 ++
+ backends/parisc_init.c    |  73 ++++++++++++++++
+ backends/parisc_regs.c    | 159 ++++++++++++++++++++++++++++++++++
+ backends/parisc_reloc.def | 128 ++++++++++++++++++++++++++++
+ backends/parisc_retval.c  | 213 ++++++++++++++++++++++++++++++++++++++++++++++
+ backends/parisc_symbol.c  | 112 ++++++++++++++++++++++++
+ libelf/elf.h              |  11 +++
+ 8 files changed, 711 insertions(+), 3 deletions(-)
+ create mode 100644 backends/libebl_parisc.h
+ create mode 100644 backends/parisc_init.c
+ create mode 100644 backends/parisc_regs.c
+ create mode 100644 backends/parisc_reloc.def
+ create mode 100644 backends/parisc_retval.c
+ create mode 100644 backends/parisc_symbol.c
+
+diff --git a/backends/Makefile.am b/backends/Makefile.am
+index 80aa00e..1e4b8e9 100644
+--- a/backends/Makefile.am
++++ b/backends/Makefile.am
+@@ -33,16 +33,16 @@ AM_CPPFLAGS += -I$(top_srcdir)/libebl -I$(top_srcdir)/libasm \
+ 
+ 
+ modules = i386 sh x86_64 ia64 alpha arm aarch64 sparc ppc ppc64 s390 \
+-	  tilegx m68k bpf riscv
++	  tilegx m68k bpf riscv parisc
+ libebl_pic = libebl_i386_pic.a libebl_sh_pic.a libebl_x86_64_pic.a    \
+ 	     libebl_ia64_pic.a libebl_alpha_pic.a libebl_arm_pic.a    \
+ 	     libebl_aarch64_pic.a libebl_sparc_pic.a libebl_ppc_pic.a \
+ 	     libebl_ppc64_pic.a libebl_s390_pic.a libebl_tilegx_pic.a \
+-	     libebl_m68k_pic.a libebl_bpf_pic.a libebl_riscv_pic.a
++	     libebl_m68k_pic.a libebl_bpf_pic.a libebl_riscv_pic.a \
++	     libebl_parisc_pic.a
+ noinst_LIBRARIES = $(libebl_pic)
+ noinst_DATA = $(libebl_pic:_pic.a=.so)
+ 
+-
+ libelf = ../libelf/libelf.so
+ libdw = ../libdw/libdw.so
+ libeu = ../lib/libeu.a
+@@ -135,6 +135,9 @@ riscv_SRCS = riscv_init.c riscv_symbol.c
+ libebl_riscv_pic_a_SOURCES = $(riscv_SRCS)
+ am_libebl_riscv_pic_a_OBJECTS = $(riscv_SRCS:.c=.os)
+ 
++parisc_SRCS = parisc_init.c parisc_symbol.c parisc_regs.c parisc_retval.c
++libebl_parisc_pic_a_SOURCES = $(parisc_SRCS)
++am_libebl_parisc_pic_a_OBJECTS = $(parisc_SRCS:.c=.os)
+ 
+ libebl_%.so libebl_%.map: libebl_%_pic.a $(libelf) $(libdw) $(libeu)
+ 	@rm -f $(@:.so=.map)
+diff --git a/backends/libebl_parisc.h b/backends/libebl_parisc.h
+new file mode 100644
+index 0000000..f473b79
+--- /dev/null
++++ b/backends/libebl_parisc.h
+@@ -0,0 +1,9 @@
++#ifndef _LIBEBL_HPPA_H
++#define _LIBEBL_HPPA_H 1
++
++#include <libdw.h>
++
++extern int parisc_return_value_location_32(Dwarf_Die *, const Dwarf_Op **locp);
++extern int parisc_return_value_location_64(Dwarf_Die *, const Dwarf_Op **locp);
++
++#endif
+diff --git a/backends/parisc_init.c b/backends/parisc_init.c
+new file mode 100644
+index 0000000..f1e401c
+--- /dev/null
++++ b/backends/parisc_init.c
+@@ -0,0 +1,73 @@
++/* Initialization of PA-RISC specific backend library.
++   Copyright (C) 2002, 2005, 2006 Red Hat, Inc.
++   This file is part of Red Hat elfutils.
++   Written by Ulrich Drepper <drepper@redhat.com>, 2002.
++
++   Red Hat elfutils is free software; you can redistribute it and/or modify
++   it under the terms of the GNU General Public License as published by the
++   Free Software Foundation; version 2 of the License.
++
++   Red Hat elfutils is distributed in the hope that it will be useful, but
++   WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   General Public License for more details.
++
++   You should have received a copy of the GNU General Public License along
++   with Red Hat elfutils; if not, write to the Free Software Foundation,
++   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
++
++   Red Hat elfutils is an included package of the Open Invention Network.
++   An included package of the Open Invention Network is a package for which
++   Open Invention Network licensees cross-license their patents.  No patent
++   license is granted, either expressly or impliedly, by designation as an
++   included package.  Should you wish to participate in the Open Invention
++   Network licensing program, please visit www.openinventionnetwork.com
++   <http://www.openinventionnetwork.com>.  */
++
++#ifdef HAVE_CONFIG_H
++# include <config.h>
++#endif
++
++#define BACKEND		parisc_
++#define RELOC_PREFIX	R_PARISC_
++#include "libebl_CPU.h"
++#include "libebl_parisc.h"
++
++/* This defines the common reloc hooks based on parisc_reloc.def.  */
++#include "common-reloc.c"
++
++
++const char *
++parisc_init (Elf *elf __attribute__ ((unused)),
++     GElf_Half machine __attribute__ ((unused)),
++     Ebl *eh,
++     size_t ehlen)
++{
++  int pa64 = 0;
++
++  /* Check whether the Elf_BH object has a sufficent size.  */
++  if (ehlen < sizeof (Ebl))
++    return NULL;
++
++  if (elf) {
++    GElf_Ehdr ehdr_mem;
++    GElf_Ehdr *ehdr = gelf_getehdr (elf, &ehdr_mem);
++    if (ehdr && (ehdr->e_flags & EF_PARISC_WIDE))
++      pa64 = 1;
++  }
++  /* We handle it.  */
++  eh->name = "PA-RISC";
++  parisc_init_reloc (eh);
++  HOOK (eh, reloc_simple_type);
++  HOOK (eh, machine_flag_check);
++  HOOK (eh, symbol_type_name);
++  HOOK (eh, segment_type_name);
++  HOOK (eh, section_type_name);
++  HOOK (eh, register_info);
++  if (pa64)
++    eh->return_value_location = parisc_return_value_location_64;
++  else
++    eh->return_value_location = parisc_return_value_location_32;
++
++  return MODVERSION;
++}
+diff --git a/backends/parisc_regs.c b/backends/parisc_regs.c
+new file mode 100644
+index 0000000..3895f8e
+--- /dev/null
++++ b/backends/parisc_regs.c
+@@ -0,0 +1,159 @@
++/* Register names and numbers for PA-RISC DWARF.
++   Copyright (C) 2005, 2006 Red Hat, Inc.
++   This file is part of Red Hat elfutils.
++
++   Red Hat elfutils is free software; you can redistribute it and/or modify
++   it under the terms of the GNU General Public License as published by the
++   Free Software Foundation; version 2 of the License.
++
++   Red Hat elfutils is distributed in the hope that it will be useful, but
++   WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   General Public License for more details.
++
++   You should have received a copy of the GNU General Public License along
++   with Red Hat elfutils; if not, write to the Free Software Foundation,
++   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
++
++   Red Hat elfutils is an included package of the Open Invention Network.
++   An included package of the Open Invention Network is a package for which
++   Open Invention Network licensees cross-license their patents.  No patent
++   license is granted, either expressly or impliedly, by designation as an
++   included package.  Should you wish to participate in the Open Invention
++   Network licensing program, please visit www.openinventionnetwork.com
++   <http://www.openinventionnetwork.com>.  */
++
++#ifdef HAVE_CONFIG_H
++# include <config.h>
++#endif
++
++#include <string.h>
++#include <dwarf.h>
++
++#define BACKEND parisc_
++#include "libebl_CPU.h"
++
++ssize_t
++parisc_register_info (Ebl *ebl, int regno, char *name, size_t namelen,
++		     const char **prefix, const char **setname,
++		     int *bits, int *type)
++{
++  int pa64 = 0;
++
++  if (ebl->elf) {
++    GElf_Ehdr ehdr_mem;
++    GElf_Ehdr *ehdr = gelf_getehdr (ebl->elf, &ehdr_mem);
++    if (ehdr->e_flags & EF_PARISC_WIDE)
++      pa64 = 1;
++  }
++
++  int nregs = pa64 ? 127 : 128;
++
++  if (name == NULL)
++    return nregs;
++
++  if (regno < 0 || regno >= nregs || namelen < 6)
++    return -1;
++
++  *prefix = "%";
++
++  if (regno < 32)
++  {
++    *setname = "integer";
++    *type = DW_ATE_signed;
++    if (pa64)
++    {
++	*bits = 64;
++    }
++    else
++    {
++    	*bits = 32;
++    }
++  }
++  else if (regno == 32)
++  {
++    *setname = "special";
++    if (pa64)
++    {
++	*bits = 6;
++    }
++    else
++    {
++    	*bits = 5;
++    }
++    *type = DW_ATE_unsigned;
++  }
++  else
++  {
++    *setname = "FPU";
++    *type = DW_ATE_float;
++    if (pa64)
++    {
++	*bits = 64;
++    }
++    else
++    {
++    	*bits = 32;
++    }
++  }
++
++  if (regno < 33) {
++    switch (regno)
++      {
++      case 0 ... 9:
++        name[0] = 'r';
++        name[1] = regno + '0';
++        namelen = 2;
++        break;
++      case 10 ... 31:
++        name[0] = 'r';
++        name[1] = regno / 10 + '0';
++        name[2] = regno % 10 + '0';
++        namelen = 3;
++        break;
++      case 32:
++	*prefix = NULL;
++	name[0] = 'S';
++	name[1] = 'A';
++	name[2] = 'R';
++	namelen = 3;
++	break;
++      }
++  }
++  else {
++    if (pa64 && ((regno - 72) % 2)) {
++      *setname = NULL;
++      return 0;
++    }
++
++    switch (regno)
++      {
++      case 72 + 0 ... 72 + 11:
++        name[0] = 'f';
++	name[1] = 'r';
++        name[2] = (regno + 8 - 72) / 2 + '0';
++        namelen = 3;
++        if ((regno + 8 - 72) % 2) {
++	  name[3] = 'R';
++	  namelen++;
++        }
++        break;
++      case 72 + 12 ... 72 + 55:
++        name[0] = 'f';
++	name[1] = 'r';
++        name[2] = (regno + 8 - 72) / 2 / 10 + '0';
++        name[3] = (regno + 8 - 72) / 2 % 10 + '0';
++        namelen = 4;
++        if ((regno + 8 - 72) % 2) {
++	  name[4] = 'R';
++	  namelen++;
++        }
++        break;
++      default:
++        *setname = NULL;
++        return 0;
++      }
++  }
++  name[namelen++] = '\0';
++  return namelen;
++}
+diff --git a/backends/parisc_reloc.def b/backends/parisc_reloc.def
+new file mode 100644
+index 0000000..1f875ba
+--- /dev/null
++++ b/backends/parisc_reloc.def
+@@ -0,0 +1,128 @@
++/* List the relocation types for PA-RISC.  -*- C -*-
++   Copyright (C) 2005 Red Hat, Inc.
++   This file is part of Red Hat elfutils.
++
++   Red Hat elfutils is free software; you can redistribute it and/or modify
++   it under the terms of the GNU General Public License as published by the
++   Free Software Foundation; version 2 of the License.
++
++   Red Hat elfutils is distributed in the hope that it will be useful, but
++   WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   General Public License for more details.
++
++   You should have received a copy of the GNU General Public License along
++   with Red Hat elfutils; if not, write to the Free Software Foundation,
++   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
++
++   Red Hat elfutils is an included package of the Open Invention Network.
++   An included package of the Open Invention Network is a package for which
++   Open Invention Network licensees cross-license their patents.  No patent
++   license is granted, either expressly or impliedly, by designation as an
++   included package.  Should you wish to participate in the Open Invention
++   Network licensing program, please visit www.openinventionnetwork.com
++   <http://www.openinventionnetwork.com>.  */
++
++/*	    NAME,		REL|EXEC|DYN	*/
++
++RELOC_TYPE (NONE,		EXEC|DYN)
++RELOC_TYPE (DIR32,		REL|EXEC|DYN)
++RELOC_TYPE (DIR21L,		REL|EXEC|DYN)
++RELOC_TYPE (DIR17R,		REL)
++RELOC_TYPE (DIR17F,		REL)
++RELOC_TYPE (DIR14R,		REL|DYN)
++RELOC_TYPE (PCREL32,		REL)
++RELOC_TYPE (PCREL21L,		REL)
++RELOC_TYPE (PCREL17R,		REL)
++RELOC_TYPE (PCREL17F,		REL)
++RELOC_TYPE (PCREL14R,		REL|EXEC)
++RELOC_TYPE (DPREL21L,		REL)
++RELOC_TYPE (DPREL14WR,		REL)
++RELOC_TYPE (DPREL14DR,          REL)
++RELOC_TYPE (DPREL14R,		REL)
++RELOC_TYPE (GPREL21L,		0)
++RELOC_TYPE (GPREL14R,		0)
++RELOC_TYPE (LTOFF21L,		REL)
++RELOC_TYPE (LTOFF14R,		REL)
++RELOC_TYPE (DLTIND14F,		0)
++RELOC_TYPE (SETBASE,		0)
++RELOC_TYPE (SECREL32,		REL)
++RELOC_TYPE (BASEREL21L,		0)
++RELOC_TYPE (BASEREL17R,		0)
++RELOC_TYPE (BASEREL14R,		0)
++RELOC_TYPE (SEGBASE,		0)
++RELOC_TYPE (SEGREL32,		REL)
++RELOC_TYPE (PLTOFF21L,		0)
++RELOC_TYPE (PLTOFF14R,		0)
++RELOC_TYPE (PLTOFF14F,		0)
++RELOC_TYPE (LTOFF_FPTR32,	0)
++RELOC_TYPE (LTOFF_FPTR21L,	0)
++RELOC_TYPE (LTOFF_FPTR14R,	0)
++RELOC_TYPE (FPTR64,		0)
++RELOC_TYPE (PLABEL32,		REL|DYN)
++RELOC_TYPE (PCREL64,		0)
++RELOC_TYPE (PCREL22C,		0)
++RELOC_TYPE (PCREL22F,		0)
++RELOC_TYPE (PCREL14WR,		0)
++RELOC_TYPE (PCREL14DR,		0)
++RELOC_TYPE (PCREL16F,		0)
++RELOC_TYPE (PCREL16WF,		0)
++RELOC_TYPE (PCREL16DF,		0)
++RELOC_TYPE (DIR64,		REL|DYN)
++RELOC_TYPE (DIR14WR,		REL)
++RELOC_TYPE (DIR14DR,		REL)
++RELOC_TYPE (DIR16F,		REL)
++RELOC_TYPE (DIR16WF,		REL)
++RELOC_TYPE (DIR16DF,		REL)
++RELOC_TYPE (GPREL64,		0)
++RELOC_TYPE (GPREL14WR,		0)
++RELOC_TYPE (GPREL14DR,		0)
++RELOC_TYPE (GPREL16F,		0)
++RELOC_TYPE (GPREL16WF,		0)
++RELOC_TYPE (GPREL16DF,		0)
++RELOC_TYPE (LTOFF64,		0)
++RELOC_TYPE (LTOFF14WR,		0)
++RELOC_TYPE (LTOFF14DR,		0)
++RELOC_TYPE (LTOFF16F,		0)
++RELOC_TYPE (LTOFF16WF,		0)
++RELOC_TYPE (LTOFF16DF,		0)
++RELOC_TYPE (SECREL64,		0)
++RELOC_TYPE (BASEREL14WR,	0)
++RELOC_TYPE (BASEREL14DR,	0)
++RELOC_TYPE (SEGREL64,		0)
++RELOC_TYPE (PLTOFF14WR,		0)
++RELOC_TYPE (PLTOFF14DR,		0)
++RELOC_TYPE (PLTOFF16F,		0)
++RELOC_TYPE (PLTOFF16WF,		0)
++RELOC_TYPE (PLTOFF16DF,		0)
++RELOC_TYPE (LTOFF_FPTR64,	0)
++RELOC_TYPE (LTOFF_FPTR14WR,	0)
++RELOC_TYPE (LTOFF_FPTR14DR,	0)
++RELOC_TYPE (LTOFF_FPTR16F,	0)
++RELOC_TYPE (LTOFF_FPTR16WF,	0)
++RELOC_TYPE (LTOFF_FPTR16DF,	0)
++RELOC_TYPE (COPY,		EXEC)
++RELOC_TYPE (IPLT,		EXEC|DYN)
++RELOC_TYPE (EPLT,		0)
++RELOC_TYPE (TPREL32,		DYN)
++RELOC_TYPE (TPREL21L,		0)
++RELOC_TYPE (TPREL14R,		0)
++RELOC_TYPE (LTOFF_TP21L,	0)
++RELOC_TYPE (LTOFF_TP14R,	0)
++RELOC_TYPE (LTOFF_TP14F,	0)
++RELOC_TYPE (TPREL64,		0)
++RELOC_TYPE (TPREL14WR,		0)
++RELOC_TYPE (TPREL14DR,		0)
++RELOC_TYPE (TPREL16F,		0)
++RELOC_TYPE (TPREL16WF,		0)
++RELOC_TYPE (TPREL16DF,		0)
++RELOC_TYPE (LTOFF_TP64,		0)
++RELOC_TYPE (LTOFF_TP14WR,	0)
++RELOC_TYPE (LTOFF_TP14DR,	0)
++RELOC_TYPE (LTOFF_TP16F,	0)
++RELOC_TYPE (LTOFF_TP16WF,	0)
++RELOC_TYPE (LTOFF_TP16DF,	0)
++RELOC_TYPE (TLS_DTPMOD32,	DYN)
++RELOC_TYPE (TLS_DTPMOD64,	DYN)
++
++#define NO_RELATIVE_RELOC       1
+diff --git a/backends/parisc_retval.c b/backends/parisc_retval.c
+new file mode 100644
+index 0000000..df7ec3a
+--- /dev/null
++++ b/backends/parisc_retval.c
+@@ -0,0 +1,213 @@
++/* Function return value location for Linux/PA-RISC ABI.
++   Copyright (C) 2005 Red Hat, Inc.
++   This file is part of Red Hat elfutils.
++
++   Red Hat elfutils is free software; you can redistribute it and/or modify
++   it under the terms of the GNU General Public License as published by the
++   Free Software Foundation; version 2 of the License.
++
++   Red Hat elfutils is distributed in the hope that it will be useful, but
++   WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   General Public License for more details.
++
++   You should have received a copy of the GNU General Public License along
++   with Red Hat elfutils; if not, write to the Free Software Foundation,
++   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
++
++   Red Hat elfutils is an included package of the Open Invention Network.
++   An included package of the Open Invention Network is a package for which
++   Open Invention Network licensees cross-license their patents.  No patent
++   license is granted, either expressly or impliedly, by designation as an
++   included package.  Should you wish to participate in the Open Invention
++   Network licensing program, please visit www.openinventionnetwork.com
++   <http://www.openinventionnetwork.com>.  */
++
++#ifdef HAVE_CONFIG_H
++# include <config.h>
++#endif
++
++#include <assert.h>
++#include <dwarf.h>
++
++#define BACKEND parisc_
++#include "libebl_CPU.h"
++#include "libebl_parisc.h"
++
++/* %r28, or pair %r28, %r29.  */
++static const Dwarf_Op loc_intreg32[] =
++  {
++    { .atom = DW_OP_reg28 }, { .atom = DW_OP_piece, .number = 4 },
++    { .atom = DW_OP_reg29 }, { .atom = DW_OP_piece, .number = 4 },
++  };
++
++static const Dwarf_Op loc_intreg[] =
++  {
++    { .atom = DW_OP_reg28 }, { .atom = DW_OP_piece, .number = 8 },
++    { .atom = DW_OP_reg29 }, { .atom = DW_OP_piece, .number = 8 },
++  };
++#define nloc_intreg	1
++#define nloc_intregpair	4
++
++/* %fr4L, or pair %fr4L, %fr4R on pa-32 */
++static const Dwarf_Op loc_fpreg32[] =
++  {
++    { .atom = DW_OP_regx, .number = 72 }, { .atom = DW_OP_piece, .number = 4 },
++    { .atom = DW_OP_regx, .number = 73 }, { .atom = DW_OP_piece, .number = 4 },
++  };
++#define nloc_fpreg32 2
++#define nloc_fpregpair32 4
++
++/* $fr4 */
++static const Dwarf_Op loc_fpreg[] =
++  {
++    { .atom = DW_OP_regx, .number = 72 },
++  };
++#define nloc_fpreg  1
++
++#if 0
++/* The return value is a structure and is actually stored in stack space
++   passed in a hidden argument by the caller. Address of the location is stored
++   in %r28 before function call, but it may be changed by function. */
++static const Dwarf_Op loc_aggregate[] =
++  {
++    { .atom = DW_OP_breg28 },
++  };
++#define nloc_aggregate 1
++#endif
++
++static int
++parisc_return_value_location_ (Dwarf_Die *functypedie, const Dwarf_Op **locp, int pa64)
++{
++  Dwarf_Word regsize = pa64 ? 8 : 4;
++
++  /* Start with the function's type, and get the DW_AT_type attribute,
++     which is the type of the return value.  */
++
++  Dwarf_Attribute attr_mem;
++  Dwarf_Attribute *attr = dwarf_attr_integrate (functypedie, DW_AT_type, &attr_mem);
++  if (attr == NULL)
++    /* The function has no return value, like a `void' function in C.  */
++    return 0;
++
++  Dwarf_Die die_mem;
++  Dwarf_Die *typedie = dwarf_formref_die (attr, &die_mem);
++  int tag = dwarf_tag (typedie);
++
++  /* Follow typedefs and qualifiers to get to the actual type.  */
++  while (tag == DW_TAG_typedef
++	 || tag == DW_TAG_const_type || tag == DW_TAG_volatile_type
++	 || tag == DW_TAG_restrict_type)
++    {
++      attr = dwarf_attr_integrate (typedie, DW_AT_type, &attr_mem);
++      typedie = dwarf_formref_die (attr, &die_mem);
++      tag = dwarf_tag (typedie);
++    }
++
++  switch (tag)
++    {
++    case -1:
++      return -1;
++
++    case DW_TAG_subrange_type:
++      if (! dwarf_hasattr_integrate (typedie, DW_AT_byte_size))
++	{
++	  attr = dwarf_attr_integrate (typedie, DW_AT_type, &attr_mem);
++	  typedie = dwarf_formref_die (attr, &die_mem);
++	  tag = dwarf_tag (typedie);
++	}
++      /* Fall through.  */
++
++    case DW_TAG_base_type:
++    case DW_TAG_enumeration_type:
++    case DW_TAG_pointer_type:
++    case DW_TAG_ptr_to_member_type:
++      {
++        Dwarf_Word size;
++	if (dwarf_formudata (dwarf_attr_integrate (typedie, DW_AT_byte_size,
++					 &attr_mem), &size) != 0)
++	  {
++	    if (tag == DW_TAG_pointer_type || tag == DW_TAG_ptr_to_member_type)
++	      size = 4;
++	    else
++	      return -1;
++	  }
++	if (tag == DW_TAG_base_type)
++	  {
++	    Dwarf_Word encoding;
++	    if (dwarf_formudata (dwarf_attr_integrate (typedie, DW_AT_encoding,
++					     &attr_mem), &encoding) != 0)
++	      return -1;
++
++	    if (encoding == DW_ATE_float)
++	      {
++		if (pa64) {
++		  *locp = loc_fpreg;
++		  if (size <= 8)
++		      return nloc_fpreg;
++		}
++		else {
++		  *locp = loc_fpreg32;
++		  if (size <= 4)
++		    return nloc_fpreg32;
++		  else if (size <= 8)
++		    return nloc_fpregpair32;
++		}
++		goto aggregate;
++	      }
++	  }
++	if (pa64)
++	  *locp = loc_intreg;
++	else
++	  *locp = loc_intreg32;
++	if (size <= regsize)
++	  return nloc_intreg;
++	if (size <= 2 * regsize)
++	  return nloc_intregpair;
++
++	/* Else fall through.  */
++      }
++
++    case DW_TAG_structure_type:
++    case DW_TAG_class_type:
++    case DW_TAG_union_type:
++    case DW_TAG_array_type:
++    aggregate: {
++        Dwarf_Word size;
++	if (dwarf_aggregate_size (typedie, &size) != 0)
++	  return -1;
++	if (pa64)
++          *locp = loc_intreg;
++	else
++	  *locp = loc_intreg32;
++        if (size <= regsize)
++	  return nloc_intreg;
++        if (size <= 2 * regsize)
++	  return nloc_intregpair;
++#if 0
++	/* there should be some way to know this location... But I do not see it. */
++        *locp = loc_aggregate;
++        return nloc_aggregate;
++#endif
++	/* fall through.  */
++      }
++    }
++
++  /* XXX We don't have a good way to return specific errors from ebl calls.
++     This value means we do not understand the type, but it is well-formed
++     DWARF and might be valid.  */
++  return -2;
++}
++
++int
++parisc_return_value_location_32 (Dwarf_Die *functypedie, const Dwarf_Op **locp)
++{
++  return parisc_return_value_location_ (functypedie, locp, 0);
++}
++
++int
++parisc_return_value_location_64 (Dwarf_Die *functypedie, const Dwarf_Op **locp)
++{
++  return parisc_return_value_location_ (functypedie, locp, 1);
++}
++
+diff --git a/backends/parisc_symbol.c b/backends/parisc_symbol.c
+new file mode 100644
+index 0000000..d111a76
+--- /dev/null
++++ b/backends/parisc_symbol.c
+@@ -0,0 +1,112 @@
++/* PA-RISC specific symbolic name handling.
++   Copyright (C) 2002, 2005 Red Hat, Inc.
++   This file is part of Red Hat elfutils.
++   Written by Ulrich Drepper <drepper@redhat.com>, 2002.
++
++   Red Hat elfutils is free software; you can redistribute it and/or modify
++   it under the terms of the GNU General Public License as published by the
++   Free Software Foundation; version 2 of the License.
++
++   Red Hat elfutils is distributed in the hope that it will be useful, but
++   WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   General Public License for more details.
++
++   You should have received a copy of the GNU General Public License along
++   with Red Hat elfutils; if not, write to the Free Software Foundation,
++   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
++
++   Red Hat elfutils is an included package of the Open Invention Network.
++   An included package of the Open Invention Network is a package for which
++   Open Invention Network licensees cross-license their patents.  No patent
++   license is granted, either expressly or impliedly, by designation as an
++   included package.  Should you wish to participate in the Open Invention
++   Network licensing program, please visit www.openinventionnetwork.com
++   <http://www.openinventionnetwork.com>.  */
++
++#ifdef HAVE_CONFIG_H
++# include <config.h>
++#endif
++
++#include <elf.h>
++#include <stddef.h>
++
++#define BACKEND		parisc_
++#include "libebl_CPU.h"
++
++const char *
++parisc_segment_type_name (int segment, char *buf __attribute__ ((unused)),
++			size_t len __attribute__ ((unused)))
++{
++  switch (segment)
++    {
++    case PT_PARISC_ARCHEXT:
++      return "PARISC_ARCHEXT";
++    case PT_PARISC_UNWIND:
++      return "PARISC_UNWIND";
++    default:
++      break;
++    }
++  return NULL;
++}
++
++/* Return symbolic representation of symbol type.  */
++const char *
++parisc_symbol_type_name(int symbol, char *buf __attribute__ ((unused)),
++    size_t len __attribute__ ((unused)))
++{
++	if (symbol == STT_PARISC_MILLICODE)
++	  return "PARISC_MILLI";
++	return NULL;
++}
++
++/* Return symbolic representation of section type.  */
++const char *
++parisc_section_type_name (int type,
++			char *buf __attribute__ ((unused)),
++			size_t len __attribute__ ((unused)))
++{
++  switch (type)
++    {
++    case SHT_PARISC_EXT:
++      return "PARISC_EXT";
++    case SHT_PARISC_UNWIND:
++      return "PARISC_UNWIND";
++    case SHT_PARISC_DOC:
++      return "PARISC_DOC";
++    }
++
++  return NULL;
++}
++
++/* Check whether machine flags are valid.  */
++bool
++parisc_machine_flag_check (GElf_Word flags)
++{
++  if (flags &~ (EF_PARISC_TRAPNIL | EF_PARISC_EXT | EF_PARISC_LSB |
++	EF_PARISC_WIDE | EF_PARISC_NO_KABP |
++	EF_PARISC_LAZYSWAP | EF_PARISC_ARCH))
++    return 0;
++
++  GElf_Word arch = flags & EF_PARISC_ARCH;
++
++  return ((arch == EFA_PARISC_1_0) || (arch == EFA_PARISC_1_1) ||
++      (arch == EFA_PARISC_2_0));
++}
++
++/* Check for the simple reloc types.  */
++Elf_Type
++parisc_reloc_simple_type (Ebl *ebl __attribute__ ((unused)), int type)
++{
++  switch (type)
++    {
++    case R_PARISC_DIR64:
++    case R_PARISC_SECREL64:
++      return ELF_T_XWORD;
++    case R_PARISC_DIR32:
++    case R_PARISC_SECREL32:
++      return ELF_T_WORD;
++    default:
++      return ELF_T_NUM;
++    }
++}
+diff --git a/libelf/elf.h b/libelf/elf.h
+index f774898..6c9f61e 100644
+--- a/libelf/elf.h
++++ b/libelf/elf.h
+@@ -2153,16 +2153,24 @@ enum
+ #define R_PARISC_PCREL17F	12	/* 17 bits of rel. address.  */
+ #define R_PARISC_PCREL14R	14	/* Right 14 bits of rel. address.  */
+ #define R_PARISC_DPREL21L	18	/* Left 21 bits of rel. address.  */
++#define R_PARISC_DPREL14WR	19
++#define R_PARISC_DPREL14DR	20
+ #define R_PARISC_DPREL14R	22	/* Right 14 bits of rel. address.  */
+ #define R_PARISC_GPREL21L	26	/* GP-relative, left 21 bits.  */
+ #define R_PARISC_GPREL14R	30	/* GP-relative, right 14 bits.  */
+ #define R_PARISC_LTOFF21L	34	/* LT-relative, left 21 bits.  */
+ #define R_PARISC_LTOFF14R	38	/* LT-relative, right 14 bits.  */
++#define R_PARISC_DLTIND14F	39
++#define R_PARISC_SETBASE	40
+ #define R_PARISC_SECREL32	41	/* 32 bits section rel. address.  */
++#define R_PARISC_BASEREL21L	42
++#define R_PARISC_BASEREL17R	43
++#define R_PARISC_BASEREL14R	46
+ #define R_PARISC_SEGBASE	48	/* No relocation, set segment base.  */
+ #define R_PARISC_SEGREL32	49	/* 32 bits segment rel. address.  */
+ #define R_PARISC_PLTOFF21L	50	/* PLT rel. address, left 21 bits.  */
+ #define R_PARISC_PLTOFF14R	54	/* PLT rel. address, right 14 bits.  */
++#define R_PARISC_PLTOFF14F	55
+ #define R_PARISC_LTOFF_FPTR32	57	/* 32 bits LT-rel. function pointer. */
+ #define R_PARISC_LTOFF_FPTR21L	58	/* LT-rel. fct ptr, left 21 bits. */
+ #define R_PARISC_LTOFF_FPTR14R	62	/* LT-rel. fct ptr, right 14 bits. */
+@@ -2171,6 +2179,7 @@ enum
+ #define R_PARISC_PLABEL21L	66	/* Left 21 bits of fdesc address.  */
+ #define R_PARISC_PLABEL14R	70	/* Right 14 bits of fdesc address.  */
+ #define R_PARISC_PCREL64	72	/* 64 bits PC-rel. address.  */
++#define R_PARISC_PCREL22C	73
+ #define R_PARISC_PCREL22F	74	/* 22 bits PC-rel. address.  */
+ #define R_PARISC_PCREL14WR	75	/* PC-rel. address, right 14 bits.  */
+ #define R_PARISC_PCREL14DR	76	/* PC rel. address, right 14 bits.  */
+@@ -2196,6 +2205,8 @@ enum
+ #define R_PARISC_LTOFF16WF	102	/* 16 bits LT-rel. address.  */
+ #define R_PARISC_LTOFF16DF	103	/* 16 bits LT-rel. address.  */
+ #define R_PARISC_SECREL64	104	/* 64 bits section rel. address.  */
++#define R_PARISC_BASEREL14WR	107
++#define R_PARISC_BASEREL14DR	108
+ #define R_PARISC_SEGREL64	112	/* 64 bits segment rel. address.  */
+ #define R_PARISC_PLTOFF14WR	115	/* PLT-rel. address, right 14 bits.  */
+ #define R_PARISC_PLTOFF14DR	116	/* PLT-rel. address, right 14 bits.  */
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/elfutils/files/debian/0001-mips_backend.patch b/poky/meta/recipes-devtools/elfutils/files/debian/0001-mips_backend.patch
new file mode 100644
index 0000000..d04da72
--- /dev/null
+++ b/poky/meta/recipes-devtools/elfutils/files/debian/0001-mips_backend.patch
@@ -0,0 +1,718 @@
+From 59ffb86bda845a68d3686afa7bc784131df678f7 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Fri, 29 Jun 2018 15:45:58 +0800
+Subject: [PATCH] mips_backend
+
+Upstream-Status: Pending [from debian]
+mips_backend.diff and rebase to 0.172
+
+http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ backends/Makefile.am    |   8 +-
+ backends/mips_init.c    |  59 +++++++++
+ backends/mips_regs.c    | 104 ++++++++++++++++
+ backends/mips_reloc.def |  79 ++++++++++++
+ backends/mips_retval.c  | 321 ++++++++++++++++++++++++++++++++++++++++++++++++
+ backends/mips_symbol.c  |  52 ++++++++
+ libebl/eblopenbackend.c |   2 +
+ 7 files changed, 623 insertions(+), 2 deletions(-)
+ create mode 100644 backends/mips_init.c
+ create mode 100644 backends/mips_regs.c
+ create mode 100644 backends/mips_reloc.def
+ create mode 100644 backends/mips_retval.c
+ create mode 100644 backends/mips_symbol.c
+
+diff --git a/backends/Makefile.am b/backends/Makefile.am
+index 1e4b8e9..e7bccf8 100644
+--- a/backends/Makefile.am
++++ b/backends/Makefile.am
+@@ -33,13 +33,13 @@ AM_CPPFLAGS += -I$(top_srcdir)/libebl -I$(top_srcdir)/libasm \
+ 
+ 
+ modules = i386 sh x86_64 ia64 alpha arm aarch64 sparc ppc ppc64 s390 \
+-	  tilegx m68k bpf riscv parisc
++	  tilegx m68k bpf riscv parisc mips
+ libebl_pic = libebl_i386_pic.a libebl_sh_pic.a libebl_x86_64_pic.a    \
+ 	     libebl_ia64_pic.a libebl_alpha_pic.a libebl_arm_pic.a    \
+ 	     libebl_aarch64_pic.a libebl_sparc_pic.a libebl_ppc_pic.a \
+ 	     libebl_ppc64_pic.a libebl_s390_pic.a libebl_tilegx_pic.a \
+ 	     libebl_m68k_pic.a libebl_bpf_pic.a libebl_riscv_pic.a \
+-	     libebl_parisc_pic.a
++	     libebl_parisc_pic.a libebl_mips_pic.a
+ noinst_LIBRARIES = $(libebl_pic)
+ noinst_DATA = $(libebl_pic:_pic.a=.so)
+ 
+@@ -139,6 +139,10 @@ parisc_SRCS = parisc_init.c parisc_symbol.c parisc_regs.c parisc_retval.c
+ libebl_parisc_pic_a_SOURCES = $(parisc_SRCS)
+ am_libebl_parisc_pic_a_OBJECTS = $(parisc_SRCS:.c=.os)
+ 
++mips_SRCS = mips_init.c mips_symbol.c mips_regs.c mips_retval.c
++libebl_mips_pic_a_SOURCES = $(mips_SRCS)
++am_libebl_mips_pic_a_OBJECTS = $(mips_SRCS:.c=.os)
++
+ libebl_%.so libebl_%.map: libebl_%_pic.a $(libelf) $(libdw) $(libeu)
+ 	@rm -f $(@:.so=.map)
+ 	$(AM_V_at)echo 'ELFUTILS_$(PACKAGE_VERSION) { global: $*_init; local: *; };' \
+diff --git a/backends/mips_init.c b/backends/mips_init.c
+new file mode 100644
+index 0000000..975c04e
+--- /dev/null
++++ b/backends/mips_init.c
+@@ -0,0 +1,59 @@
++/* Initialization of mips specific backend library.
++   Copyright (C) 2006 Red Hat, Inc.
++   This file is part of Red Hat elfutils.
++
++   Red Hat elfutils is free software; you can redistribute it and/or modify
++   it under the terms of the GNU General Public License as published by the
++   Free Software Foundation; version 2 of the License.
++
++   Red Hat elfutils is distributed in the hope that it will be useful, but
++   WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   General Public License for more details.
++
++   You should have received a copy of the GNU General Public License along
++   with Red Hat elfutils; if not, write to the Free Software Foundation,
++   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
++
++   Red Hat elfutils is an included package of the Open Invention Network.
++   An included package of the Open Invention Network is a package for which
++   Open Invention Network licensees cross-license their patents.  No patent
++   license is granted, either expressly or impliedly, by designation as an
++   included package.  Should you wish to participate in the Open Invention
++   Network licensing program, please visit www.openinventionnetwork.com
++   <http://www.openinventionnetwork.com>.  */
++
++#ifdef HAVE_CONFIG_H
++# include <config.h>
++#endif
++
++#define BACKEND		mips_
++#define RELOC_PREFIX	R_MIPS_
++#include "libebl_CPU.h"
++
++/* This defines the common reloc hooks based on mips_reloc.def.  */
++#include "common-reloc.c"
++
++const char *
++mips_init (Elf *elf __attribute__ ((unused)),
++     GElf_Half machine __attribute__ ((unused)),
++     Ebl *eh,
++     size_t ehlen)
++{
++  /* Check whether the Elf_BH object has a sufficent size.  */
++  if (ehlen < sizeof (Ebl))
++    return NULL;
++
++  /* We handle it.  */
++  if (machine == EM_MIPS)
++    eh->name = "MIPS R3000 big-endian";
++  else if (machine == EM_MIPS_RS3_LE)
++    eh->name = "MIPS R3000 little-endian";
++
++  mips_init_reloc (eh);
++  HOOK (eh, reloc_simple_type);
++  HOOK (eh, return_value_location);
++  HOOK (eh, register_info);
++
++  return MODVERSION;
++}
+diff --git a/backends/mips_regs.c b/backends/mips_regs.c
+new file mode 100644
+index 0000000..44f86cb
+--- /dev/null
++++ b/backends/mips_regs.c
+@@ -0,0 +1,104 @@
++/* Register names and numbers for MIPS DWARF.
++   Copyright (C) 2006 Red Hat, Inc.
++   This file is part of Red Hat elfutils.
++
++   Red Hat elfutils is free software; you can redistribute it and/or modify
++   it under the terms of the GNU General Public License as published by the
++   Free Software Foundation; version 2 of the License.
++
++   Red Hat elfutils is distributed in the hope that it will be useful, but
++   WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   General Public License for more details.
++
++   You should have received a copy of the GNU General Public License along
++   with Red Hat elfutils; if not, write to the Free Software Foundation,
++   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
++
++   Red Hat elfutils is an included package of the Open Invention Network.
++   An included package of the Open Invention Network is a package for which
++   Open Invention Network licensees cross-license their patents.  No patent
++   license is granted, either expressly or impliedly, by designation as an
++   included package.  Should you wish to participate in the Open Invention
++   Network licensing program, please visit www.openinventionnetwork.com
++   <http://www.openinventionnetwork.com>.  */
++
++#ifdef HAVE_CONFIG_H
++# include <config.h>
++#endif
++
++#include <string.h>
++#include <dwarf.h>
++
++#define BACKEND mips_
++#include "libebl_CPU.h"
++
++ssize_t
++mips_register_info (Ebl *ebl __attribute__((unused)),
++		    int regno, char *name, size_t namelen,
++		    const char **prefix, const char **setname,
++		    int *bits, int *type)
++{
++  if (name == NULL)
++    return 66;
++
++  if (regno < 0 || regno > 65 || namelen < 4)
++    return -1;
++
++  *prefix = "$";
++
++  if (regno < 32)
++    {
++      *setname = "integer";
++      *type = DW_ATE_signed;
++      *bits = 32;
++      if (regno < 32 + 10)
++        {
++          name[0] = regno + '0';
++          namelen = 1;
++        }
++      else
++        {
++          name[0] = (regno / 10) + '0';
++          name[1] = (regno % 10) + '0';
++          namelen = 2;
++        }
++    }
++  else if (regno < 64)
++    {
++      *setname = "FPU";
++      *type = DW_ATE_float;
++      *bits = 32;
++      name[0] = 'f';
++      if (regno < 32 + 10)
++	{
++	  name[1] = (regno - 32) + '0';
++	  namelen = 2;
++	}
++      else
++	{
++	  name[1] = (regno - 32) / 10 + '0';
++	  name[2] = (regno - 32) % 10 + '0';
++	  namelen = 3;
++	}
++    }
++  else if (regno == 64)
++    {
++      *type = DW_ATE_signed;
++      *bits = 32;
++      name[0] = 'h';
++      name[1] = 'i';
++      namelen = 2;
++    }
++  else
++    {
++      *type = DW_ATE_signed;
++      *bits = 32;
++      name[0] = 'l';
++      name[1] = 'o';
++      namelen = 2;
++    }
++
++  name[namelen++] = '\0';
++  return namelen;
++}
+diff --git a/backends/mips_reloc.def b/backends/mips_reloc.def
+new file mode 100644
+index 0000000..4579970
+--- /dev/null
++++ b/backends/mips_reloc.def
+@@ -0,0 +1,79 @@
++/* List the relocation types for mips.  -*- C -*-
++   Copyright (C) 2006 Red Hat, Inc.
++   This file is part of Red Hat elfutils.
++
++   Red Hat elfutils is free software; you can redistribute it and/or modify
++   it under the terms of the GNU General Public License as published by the
++   Free Software Foundation; version 2 of the License.
++
++   Red Hat elfutils is distributed in the hope that it will be useful, but
++   WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   General Public License for more details.
++
++   You should have received a copy of the GNU General Public License along
++   with Red Hat elfutils; if not, write to the Free Software Foundation,
++   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
++
++   Red Hat elfutils is an included package of the Open Invention Network.
++   An included package of the Open Invention Network is a package for which
++   Open Invention Network licensees cross-license their patents.  No patent
++   license is granted, either expressly or impliedly, by designation as an
++   included package.  Should you wish to participate in the Open Invention
++   Network licensing program, please visit www.openinventionnetwork.com
++   <http://www.openinventionnetwork.com>.  */
++
++/* 	    NAME,		REL|EXEC|DYN	*/
++
++RELOC_TYPE (NONE,               0)
++RELOC_TYPE (16,                 0)
++RELOC_TYPE (32,                 0)
++RELOC_TYPE (REL32,              0)
++RELOC_TYPE (26,                 0)
++RELOC_TYPE (HI16,               0)
++RELOC_TYPE (LO16,               0)
++RELOC_TYPE (GPREL16,            0)
++RELOC_TYPE (LITERAL,            0)
++RELOC_TYPE (GOT16,              0)
++RELOC_TYPE (PC16,               0)
++RELOC_TYPE (CALL16,             0)
++RELOC_TYPE (GPREL32,            0)
++
++RELOC_TYPE (SHIFT5,             0)
++RELOC_TYPE (SHIFT6,             0)
++RELOC_TYPE (64,                 0)
++RELOC_TYPE (GOT_DISP,           0)
++RELOC_TYPE (GOT_PAGE,           0)
++RELOC_TYPE (GOT_OFST,           0)
++RELOC_TYPE (GOT_HI16,           0)
++RELOC_TYPE (GOT_LO16,           0)
++RELOC_TYPE (SUB,                0)
++RELOC_TYPE (INSERT_A,           0)
++RELOC_TYPE (INSERT_B,           0)
++RELOC_TYPE (DELETE,             0)
++RELOC_TYPE (HIGHER,             0)
++RELOC_TYPE (HIGHEST,            0)
++RELOC_TYPE (CALL_HI16,          0)
++RELOC_TYPE (CALL_LO16,          0)
++RELOC_TYPE (SCN_DISP,           0)
++RELOC_TYPE (REL16,              0)
++RELOC_TYPE (ADD_IMMEDIATE,      0)
++RELOC_TYPE (PJUMP,              0)
++RELOC_TYPE (RELGOT,             0)
++RELOC_TYPE (JALR,               0)
++RELOC_TYPE (TLS_DTPMOD32,       0)
++RELOC_TYPE (TLS_DTPREL32,       0)
++RELOC_TYPE (TLS_DTPMOD64,       0)
++RELOC_TYPE (TLS_DTPREL64,       0)
++RELOC_TYPE (TLS_GD,             0)
++RELOC_TYPE (TLS_LDM,            0)
++RELOC_TYPE (TLS_DTPREL_HI16,    0)
++RELOC_TYPE (TLS_DTPREL_LO16,    0)
++RELOC_TYPE (TLS_GOTTPREL,       0)
++RELOC_TYPE (TLS_TPREL32,        0)
++RELOC_TYPE (TLS_TPREL64,        0)
++RELOC_TYPE (TLS_TPREL_HI16,     0)
++RELOC_TYPE (TLS_TPREL_LO16,     0)
++
++#define NO_COPY_RELOC 1
++#define NO_RELATIVE_RELOC 1
+diff --git a/backends/mips_retval.c b/backends/mips_retval.c
+new file mode 100644
+index 0000000..656cd1f
+--- /dev/null
++++ b/backends/mips_retval.c
+@@ -0,0 +1,321 @@
++/* Function return value location for Linux/mips ABI.
++   Copyright (C) 2005 Red Hat, Inc.
++   This file is part of Red Hat elfutils.
++
++   Red Hat elfutils is free software; you can redistribute it and/or modify
++   it under the terms of the GNU General Public License as published by the
++   Free Software Foundation; version 2 of the License.
++
++   Red Hat elfutils is distributed in the hope that it will be useful, but
++   WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   General Public License for more details.
++
++   You should have received a copy of the GNU General Public License along
++   with Red Hat elfutils; if not, write to the Free Software Foundation,
++   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
++
++   Red Hat elfutils is an included package of the Open Invention Network.
++   An included package of the Open Invention Network is a package for which
++   Open Invention Network licensees cross-license their patents.  No patent
++   license is granted, either expressly or impliedly, by designation as an
++   included package.  Should you wish to participate in the Open Invention
++   Network licensing program, please visit www.openinventionnetwork.com
++   <http://www.openinventionnetwork.com>.  */
++
++#ifdef HAVE_CONFIG_H
++# include <config.h>
++#endif
++
++#include <string.h>
++#include <assert.h>
++#include <dwarf.h>
++#include <elf.h>
++
++#include "../libebl/libeblP.h"
++#include "../libdw/libdwP.h"
++
++#define BACKEND mips_
++#include "libebl_CPU.h"
++
++/* The ABI of the file.  Also see EF_MIPS_ABI2 above. */
++#define EF_MIPS_ABI		0x0000F000
++
++/* The original o32 abi. */
++#define E_MIPS_ABI_O32          0x00001000
++
++/* O32 extended to work on 64 bit architectures */
++#define E_MIPS_ABI_O64          0x00002000
++
++/* EABI in 32 bit mode */
++#define E_MIPS_ABI_EABI32       0x00003000
++
++/* EABI in 64 bit mode */
++#define E_MIPS_ABI_EABI64       0x00004000
++
++/* All the possible MIPS ABIs. */
++enum mips_abi
++  {
++    MIPS_ABI_UNKNOWN = 0,
++    MIPS_ABI_N32,
++    MIPS_ABI_O32,
++    MIPS_ABI_N64,
++    MIPS_ABI_O64,
++    MIPS_ABI_EABI32,
++    MIPS_ABI_EABI64,
++    MIPS_ABI_LAST
++  };
++
++/* Find the mips ABI of the current file */
++enum mips_abi find_mips_abi(Elf *elf)
++{
++  GElf_Ehdr ehdr_mem;
++  GElf_Ehdr *ehdr = gelf_getehdr (elf, &ehdr_mem);
++
++  if (ehdr == NULL)
++    return MIPS_ABI_LAST;
++
++  GElf_Word elf_flags = ehdr->e_flags;
++
++  /* Check elf_flags to see if it specifies the ABI being used.  */
++  switch ((elf_flags & EF_MIPS_ABI))
++    {
++    case E_MIPS_ABI_O32:
++      return MIPS_ABI_O32;
++    case E_MIPS_ABI_O64:
++      return MIPS_ABI_O64;
++    case E_MIPS_ABI_EABI32:
++      return MIPS_ABI_EABI32;
++    case E_MIPS_ABI_EABI64:
++      return MIPS_ABI_EABI64;
++    default:
++      if ((elf_flags & EF_MIPS_ABI2))
++	return MIPS_ABI_N32;
++    }
++
++  /* GCC creates a pseudo-section whose name describes the ABI.  */
++  size_t shstrndx;
++  if (elf_getshdrstrndx (elf, &shstrndx) < 0)
++    return MIPS_ABI_LAST;
++
++  const char *name;
++  Elf_Scn *scn = NULL;
++  while ((scn = elf_nextscn (elf, scn)) != NULL)
++    {
++      GElf_Shdr shdr_mem;
++      GElf_Shdr *shdr = gelf_getshdr (scn, &shdr_mem);
++      if (shdr == NULL)
++        return MIPS_ABI_LAST;
++
++      name = elf_strptr (elf, shstrndx, shdr->sh_name) ?: "";
++      if (strncmp (name, ".mdebug.", 8) != 0)
++        continue;
++
++      if (strcmp (name, ".mdebug.abi32") == 0)
++        return MIPS_ABI_O32;
++      else if (strcmp (name, ".mdebug.abiN32") == 0)
++        return MIPS_ABI_N32;
++      else if (strcmp (name, ".mdebug.abi64") == 0)
++        return MIPS_ABI_N64;
++      else if (strcmp (name, ".mdebug.abiO64") == 0)
++        return MIPS_ABI_O64;
++      else if (strcmp (name, ".mdebug.eabi32") == 0)
++        return MIPS_ABI_EABI32;
++      else if (strcmp (name, ".mdebug.eabi64") == 0)
++        return MIPS_ABI_EABI64;
++      else
++        return MIPS_ABI_UNKNOWN;
++    }
++
++  return MIPS_ABI_UNKNOWN;
++}
++
++unsigned int
++mips_abi_regsize (enum mips_abi abi)
++{
++  switch (abi)
++    {
++    case MIPS_ABI_EABI32:
++    case MIPS_ABI_O32:
++      return 4;
++    case MIPS_ABI_N32:
++    case MIPS_ABI_N64:
++    case MIPS_ABI_O64:
++    case MIPS_ABI_EABI64:
++      return 8;
++    case MIPS_ABI_UNKNOWN:
++    case MIPS_ABI_LAST:
++    default:
++      return 0;
++    }
++}
++
++
++/* $v0 or pair $v0, $v1 */
++static const Dwarf_Op loc_intreg_o32[] =
++  {
++    { .atom = DW_OP_reg2 }, { .atom = DW_OP_piece, .number = 4 },
++    { .atom = DW_OP_reg3 }, { .atom = DW_OP_piece, .number = 4 },
++  };
++
++static const Dwarf_Op loc_intreg[] =
++  {
++    { .atom = DW_OP_reg2 }, { .atom = DW_OP_piece, .number = 8 },
++    { .atom = DW_OP_reg3 }, { .atom = DW_OP_piece, .number = 8 },
++  };
++#define nloc_intreg	1
++#define nloc_intregpair	4
++
++/* $f0 (float), or pair $f0, $f1 (double).
++ * f2/f3 are used for COMPLEX (= 2 doubles) returns in Fortran */
++static const Dwarf_Op loc_fpreg_o32[] =
++  {
++    { .atom = DW_OP_regx, .number = 32 }, { .atom = DW_OP_piece, .number = 4 },
++    { .atom = DW_OP_regx, .number = 33 }, { .atom = DW_OP_piece, .number = 4 },
++    { .atom = DW_OP_regx, .number = 34 }, { .atom = DW_OP_piece, .number = 4 },
++    { .atom = DW_OP_regx, .number = 35 }, { .atom = DW_OP_piece, .number = 4 },
++  };
++
++/* $f0, or pair $f0, $f2.  */
++static const Dwarf_Op loc_fpreg[] =
++  {
++    { .atom = DW_OP_regx, .number = 32 }, { .atom = DW_OP_piece, .number = 8 },
++    { .atom = DW_OP_regx, .number = 34 }, { .atom = DW_OP_piece, .number = 8 },
++  };
++#define nloc_fpreg  1
++#define nloc_fpregpair 4
++#define nloc_fpregquad 8
++
++/* The return value is a structure and is actually stored in stack space
++   passed in a hidden argument by the caller.  But, the compiler
++   helpfully returns the address of that space in $v0.  */
++static const Dwarf_Op loc_aggregate[] =
++  {
++    { .atom = DW_OP_breg2, .number = 0 }
++  };
++#define nloc_aggregate 1
++
++int
++mips_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
++{
++  /* First find the ABI used by the elf object */
++  enum mips_abi abi = find_mips_abi(functypedie->cu->dbg->elf);
++
++  /* Something went seriously wrong while trying to figure out the ABI */
++  if (abi == MIPS_ABI_LAST)
++    return -1;
++
++  /* We couldn't identify the ABI, but the file seems valid */
++  if (abi == MIPS_ABI_UNKNOWN)
++    return -2;
++
++  /* Can't handle EABI variants */
++  if ((abi == MIPS_ABI_EABI32) || (abi == MIPS_ABI_EABI64))
++    return -2;
++
++  unsigned int regsize = mips_abi_regsize (abi);
++  if (!regsize)
++    return -2;
++
++  /* Start with the function's type, and get the DW_AT_type attribute,
++     which is the type of the return value.  */
++
++  Dwarf_Attribute attr_mem;
++  Dwarf_Attribute *attr = dwarf_attr_integrate (functypedie, DW_AT_type, &attr_mem);
++  if (attr == NULL)
++    /* The function has no return value, like a `void' function in C.  */
++    return 0;
++
++  Dwarf_Die die_mem;
++  Dwarf_Die *typedie = dwarf_formref_die (attr, &die_mem);
++  int tag = dwarf_tag (typedie);
++
++  /* Follow typedefs and qualifiers to get to the actual type.  */
++  while (tag == DW_TAG_typedef
++	 || tag == DW_TAG_const_type || tag == DW_TAG_volatile_type
++	 || tag == DW_TAG_restrict_type)
++    {
++      attr = dwarf_attr_integrate (typedie, DW_AT_type, &attr_mem);
++      typedie = dwarf_formref_die (attr, &die_mem);
++      tag = dwarf_tag (typedie);
++    }
++
++  switch (tag)
++    {
++    case -1:
++      return -1;
++
++    case DW_TAG_subrange_type:
++      if (! dwarf_hasattr_integrate (typedie, DW_AT_byte_size))
++	{
++	  attr = dwarf_attr_integrate (typedie, DW_AT_type, &attr_mem);
++	  typedie = dwarf_formref_die (attr, &die_mem);
++	  tag = dwarf_tag (typedie);
++	}
++      /* Fall through.  */
++
++    case DW_TAG_base_type:
++    case DW_TAG_enumeration_type:
++    case DW_TAG_pointer_type:
++    case DW_TAG_ptr_to_member_type:
++      {
++        Dwarf_Word size;
++	if (dwarf_formudata (dwarf_attr_integrate (typedie, DW_AT_byte_size,
++					 &attr_mem), &size) != 0)
++	  {
++	    if (tag == DW_TAG_pointer_type || tag == DW_TAG_ptr_to_member_type)
++	      size = regsize;
++	    else
++	      return -1;
++	  }
++	if (tag == DW_TAG_base_type)
++	  {
++	    Dwarf_Word encoding;
++	    if (dwarf_formudata (dwarf_attr_integrate (typedie, DW_AT_encoding,
++					     &attr_mem), &encoding) != 0)
++	      return -1;
++
++#define ABI_LOC(loc, regsize) ((regsize) == 4 ? (loc ## _o32) : (loc))
++
++	    if (encoding == DW_ATE_float)
++	      {
++		*locp = ABI_LOC(loc_fpreg, regsize);
++		if (size <= regsize)
++		    return nloc_fpreg;
++
++		if (size <= 2*regsize)
++                  return nloc_fpregpair;
++
++		if (size <= 4*regsize && abi == MIPS_ABI_O32)
++                  return nloc_fpregquad;
++
++		goto aggregate;
++	      }
++	  }
++	*locp = ABI_LOC(loc_intreg, regsize);
++	if (size <= regsize)
++	  return nloc_intreg;
++	if (size <= 2*regsize)
++	  return nloc_intregpair;
++
++	/* Else fall through. Shouldn't happen though (at least with gcc) */
++      }
++
++    case DW_TAG_structure_type:
++    case DW_TAG_class_type:
++    case DW_TAG_union_type:
++    case DW_TAG_array_type:
++    aggregate:
++      /* XXX TODO: Can't handle structure return with other ABI's yet :-/ */
++      if ((abi != MIPS_ABI_O32) && (abi != MIPS_ABI_O64))
++        return -2;
++
++      *locp = loc_aggregate;
++      return nloc_aggregate;
++    }
++
++  /* XXX We don't have a good way to return specific errors from ebl calls.
++     This value means we do not understand the type, but it is well-formed
++     DWARF and might be valid.  */
++  return -2;
++}
+diff --git a/backends/mips_symbol.c b/backends/mips_symbol.c
+new file mode 100644
+index 0000000..ba465fe
+--- /dev/null
++++ b/backends/mips_symbol.c
+@@ -0,0 +1,52 @@
++/* MIPS specific symbolic name handling.
++   Copyright (C) 2002, 2003, 2005 Red Hat, Inc.
++   This file is part of Red Hat elfutils.
++   Written by Jakub Jelinek <jakub@redhat.com>, 2002.
++
++   Red Hat elfutils is free software; you can redistribute it and/or modify
++   it under the terms of the GNU General Public License as published by the
++   Free Software Foundation; version 2 of the License.
++
++   Red Hat elfutils is distributed in the hope that it will be useful, but
++   WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++   General Public License for more details.
++
++   You should have received a copy of the GNU General Public License along
++   with Red Hat elfutils; if not, write to the Free Software Foundation,
++   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
++
++   Red Hat elfutils is an included package of the Open Invention Network.
++   An included package of the Open Invention Network is a package for which
++   Open Invention Network licensees cross-license their patents.  No patent
++   license is granted, either expressly or impliedly, by designation as an
++   included package.  Should you wish to participate in the Open Invention
++   Network licensing program, please visit www.openinventionnetwork.com
++   <http://www.openinventionnetwork.com>.  */
++
++#ifdef HAVE_CONFIG_H
++# include <config.h>
++#endif
++
++#include <elf.h>
++#include <stddef.h>
++
++#define BACKEND		mips_
++#include "libebl_CPU.h"
++
++/* Check for the simple reloc types.  */
++Elf_Type
++mips_reloc_simple_type (Ebl *ebl __attribute__ ((unused)), int type)
++{
++  switch (type)
++    {
++    case R_MIPS_16:
++      return ELF_T_HALF;
++    case R_MIPS_32:
++      return ELF_T_WORD;
++    case R_MIPS_64:
++      return ELF_T_XWORD;
++    default:
++      return ELF_T_NUM;
++    }
++}
+diff --git a/libebl/eblopenbackend.c b/libebl/eblopenbackend.c
+index 8b063f4..5405b0c 100644
+--- a/libebl/eblopenbackend.c
++++ b/libebl/eblopenbackend.c
+@@ -72,6 +72,8 @@ static const struct
+   { "sparc", "elf_sparc", "sparc", 5, EM_SPARC, 0, 0 },
+   { "sparc", "elf_sparcv8plus", "sparc", 5, EM_SPARC32PLUS, 0, 0 },
+   { "s390", "ebl_s390", "s390", 4, EM_S390, 0, 0 },
++  { "mips", "elf_mips", "mips", 4, EM_MIPS, 0, 0 },
++  { "mips", "elf_mipsel", "mipsel", 4, EM_MIPS_RS3_LE, 0, 0 },
+ 
+   { "m32", "elf_m32", "m32", 3, EM_M32, 0, 0 },
+   { "m68k", "elf_m68k", "m68k", 4, EM_68K, ELFCLASS32, ELFDATA2MSB },
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/elfutils/files/debian/0001-mips_readelf_w.patch b/poky/meta/recipes-devtools/elfutils/files/debian/0001-mips_readelf_w.patch
new file mode 100644
index 0000000..f3ab3da
--- /dev/null
+++ b/poky/meta/recipes-devtools/elfutils/files/debian/0001-mips_readelf_w.patch
@@ -0,0 +1,39 @@
+From a188ea1ada6b990b72b91266ae02da058dcd9523 Mon Sep 17 00:00:00 2001
+From: Kurt Roeckx <kurt@roeckx.be>
+Date: Fri, 29 Jun 2018 15:49:32 +0800
+Subject: [PATCH] Make readelf -w output debug information on mips
+
+Bug-Debian: http://bugs.debian.org/662041
+Forwarded: not-needed
+
+Upstreams wants a change where this is handled by a hook that needs
+to be filled in by the backend for the arch.
+
+Signed-off-by: Kurt Roeckx <kurt@roeckx.be>
+
+Upstream-Status: Pending [from debian]
+mips_readelf_w.patch and rebase to 0.172
+
+http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.170-0.5.debian.tar.xz
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ src/readelf.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/src/readelf.c b/src/readelf.c
+index f185897..0db197c 100644
+--- a/src/readelf.c
++++ b/src/readelf.c
+@@ -10979,7 +10979,8 @@ print_debug (Dwfl_Module *dwflmod, Ebl *ebl, GElf_Ehdr *ehdr)
+       GElf_Shdr shdr_mem;
+       GElf_Shdr *shdr = gelf_getshdr (scn, &shdr_mem);
+ 
+-      if (shdr != NULL && shdr->sh_type == SHT_PROGBITS)
++      if (shdr != NULL && (
++	 (shdr->sh_type == SHT_PROGBITS) || (shdr->sh_type == SHT_MIPS_DWARF)))
+ 	{
+ 	  static const struct
+ 	  {
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/elfutils/files/debian/0001-testsuite-ignore-elflint.patch b/poky/meta/recipes-devtools/elfutils/files/debian/0001-testsuite-ignore-elflint.patch
new file mode 100644
index 0000000..f4c6f40
--- /dev/null
+++ b/poky/meta/recipes-devtools/elfutils/files/debian/0001-testsuite-ignore-elflint.patch
@@ -0,0 +1,57 @@
+From fe7613a3b9f2443cc11917826348d4521f267c96 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Fri, 29 Jun 2018 15:48:33 +0800
+Subject: [PATCH] testsuite ignore elflint
+
+On many architectures this test fails because binaries/libs produced by
+binutils don't pass elflint. However elfutils shouldn't FTBFS because of this.
+
+So we run the tests on all archs to see what breaks, but if it breaks we ignore
+the result (exitcode 77 means: this test was skipped).
+
+Upstream-Status: Pending [from debian]
+testsuite-ignore-elflint.diff and rebase to 0.172
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ tests/run-elflint-self.sh |  2 +-
+ tests/test-subr.sh        | 15 +++++++++++++++
+ 2 files changed, 16 insertions(+), 1 deletion(-)
+
+diff --git a/tests/run-elflint-self.sh b/tests/run-elflint-self.sh
+index 58fa7d0..85d21a5 100755
+--- a/tests/run-elflint-self.sh
++++ b/tests/run-elflint-self.sh
+@@ -18,5 +18,5 @@
+ 
+ . $srcdir/test-subr.sh
+ 
+-testrun_on_self ${abs_top_builddir}/src/elflint --quiet --gnu-ld
++testrun_on_self_skip ${abs_top_builddir}/src/elflint --quiet --gnu-ld
+ testrun_on_self_compressed ${abs_top_builddir}/src/elflint --quiet --gnu-ld
+diff --git a/tests/test-subr.sh b/tests/test-subr.sh
+index 09f428d..26f61f1 100644
+--- a/tests/test-subr.sh
++++ b/tests/test-subr.sh
+@@ -201,3 +201,18 @@ testrun_on_self_quiet()
+   # Only exit if something failed
+   if test $exit_status != 0; then exit $exit_status; fi
+ }
++
++# Same as testrun_on_self(), but skip on failure.
++testrun_on_self_skip()
++{
++  exit_status=0
++
++  for file in $self_test_files; do
++      testrun $* $file \
++	  || { echo "*** failure in $* $file"; exit_status=77; }
++  done
++
++  # Only exit if something failed
++  if test $exit_status != 0; then exit $exit_status; fi
++}
++
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/elfutils/files/debian/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch b/poky/meta/recipes-devtools/elfutils/files/debian/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch
index b17498f..4bdb1ff 100644
--- a/poky/meta/recipes-devtools/elfutils/files/debian/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch
+++ b/poky/meta/recipes-devtools/elfutils/files/debian/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch
@@ -1,12 +1,12 @@
+Upstream-Status: Pending [from debian]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+
 From fdaab18a65ed2529656baa64cb6169f34d7e507b Mon Sep 17 00:00:00 2001
 From: James Cowgill <james410@cowgill.org.uk>
 Date: Mon, 5 Jan 2015 15:17:01 +0000
 Subject: [PATCH 2/3] Add support for mips64 abis in mips_retval.c
 
 Signed-off-by: James Cowgill <james410@cowgill.org.uk>
-
-Upstream-Status: Backport [from debian]
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
  backends/mips_retval.c | 104 ++++++++++++++++++++++++++++++++++++++++++++-----
  1 file changed, 94 insertions(+), 10 deletions(-)
diff --git a/poky/meta/recipes-devtools/elfutils/files/debian/0003-Add-mips-n64-relocation-format-hack.patch b/poky/meta/recipes-devtools/elfutils/files/debian/0003-Add-mips-n64-relocation-format-hack.patch
index 2a5f862..d27ce6d 100644
--- a/poky/meta/recipes-devtools/elfutils/files/debian/0003-Add-mips-n64-relocation-format-hack.patch
+++ b/poky/meta/recipes-devtools/elfutils/files/debian/0003-Add-mips-n64-relocation-format-hack.patch
@@ -1,3 +1,6 @@
+Upstream-Status: Pending [from debian]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+
 From 59d4b8c48e5040af7e02b34eb26ea602ec82a38e Mon Sep 17 00:00:00 2001
 From: James Cowgill <james410@cowgill.org.uk>
 Date: Mon, 5 Jan 2015 15:17:02 +0000
@@ -12,9 +15,6 @@
 before manipulating relocations so that these changes take effect.
 
 Signed-off-by: James Cowgill <james410@cowgill.org.uk>
-
-Upstream-Status: Backport [from debian]
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
  libelf/gelf_getrel.c      | 25 +++++++++++++++++++++++--
  libelf/gelf_getrela.c     | 25 +++++++++++++++++++++++--
@@ -203,7 +203,7 @@
 ===================================================================
 --- a/src/strip.c
 +++ b/src/strip.c
-@@ -532,6 +532,23 @@ handle_elf (int fd, Elf *elf, const char
+@@ -598,6 +598,23 @@ handle_elf (int fd, Elf *elf, const char
        goto fail;
      }
  
diff --git a/poky/meta/recipes-devtools/elfutils/files/debian/arm_backend.diff b/poky/meta/recipes-devtools/elfutils/files/debian/arm_backend.diff
deleted file mode 100644
index 50f4b05..0000000
--- a/poky/meta/recipes-devtools/elfutils/files/debian/arm_backend.diff
+++ /dev/null
@@ -1,603 +0,0 @@
-Upstream-Status: Backport [from debian]
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
-
-Index: b/backends/arm_init.c
-===================================================================
---- a/backends/arm_init.c
-+++ b/backends/arm_init.c
-@@ -35,20 +35,31 @@
- #define RELOC_PREFIX	R_ARM_
- #include "libebl_CPU.h"
- 
-+#include "libebl_arm.h"
-+
- /* This defines the common reloc hooks based on arm_reloc.def.  */
- #include "common-reloc.c"
- 
- 
- const char *
--arm_init (Elf *elf __attribute__ ((unused)),
-+arm_init (Elf *elf,
- 	  GElf_Half machine __attribute__ ((unused)),
- 	  Ebl *eh,
- 	  size_t ehlen)
- {
-+  int soft_float = 0;
-+
-   /* Check whether the Elf_BH object has a sufficent size.  */
-   if (ehlen < sizeof (Ebl))
-     return NULL;
- 
-+  if (elf) {
-+    GElf_Ehdr ehdr_mem;
-+    GElf_Ehdr *ehdr = gelf_getehdr (elf, &ehdr_mem);
-+    if (ehdr && (ehdr->e_flags & EF_ARM_SOFT_FLOAT))
-+      soft_float = 1;
-+  }
-+
-   /* We handle it.  */
-   eh->name = "ARM";
-   arm_init_reloc (eh);
-@@ -60,7 +71,10 @@ arm_init (Elf *elf __attribute__ ((unuse
-   HOOK (eh, core_note);
-   HOOK (eh, auxv_info);
-   HOOK (eh, check_object_attribute);
--  HOOK (eh, return_value_location);
-+  if (soft_float)
-+    eh->return_value_location = arm_return_value_location_soft;
-+  else
-+    eh->return_value_location = arm_return_value_location_hard;
-   HOOK (eh, abi_cfi);
-   HOOK (eh, check_reloc_target_type);
-   HOOK (eh, symbol_type_name);
-Index: b/backends/arm_regs.c
-===================================================================
---- a/backends/arm_regs.c
-+++ b/backends/arm_regs.c
-@@ -31,6 +31,7 @@
- #endif
- 
- #include <string.h>
-+#include <stdio.h>
- #include <dwarf.h>
- 
- #define BACKEND arm_
-@@ -76,6 +77,9 @@ arm_register_info (Ebl *ebl __attribute_
-       break;
- 
-     case 16 + 0 ... 16 + 7:
-+      /* AADWARF says that there are no registers in that range,
-+       * but gcc maps FPA registers here
-+       */
-       regno += 96 - 16;
-       /* Fall through.  */
-     case 96 + 0 ... 96 + 7:
-@@ -87,11 +91,139 @@ arm_register_info (Ebl *ebl __attribute_
-       namelen = 2;
-       break;
- 
-+    case 64 + 0 ... 64 + 9:
-+      *setname = "VFP";
-+      *bits = 32;
-+      *type = DW_ATE_float;
-+      name[0] = 's';
-+      name[1] = regno - 64 + '0';
-+      namelen = 2;
-+      break;
-+
-+    case 64 + 10 ... 64 + 31:
-+      *setname = "VFP";
-+      *bits = 32;
-+      *type = DW_ATE_float;
-+      name[0] = 's';
-+      name[1] = (regno - 64) / 10 + '0';
-+      name[2] = (regno - 64) % 10 + '0';
-+      namelen = 3;
-+      break;
-+
-+    case 104 + 0 ... 104 + 7:
-+      /* XXX TODO:
-+       * This can be either intel wireless MMX general purpose/control
-+       * registers or xscale accumulator, which have different usage.
-+       * We only have the intel wireless MMX here now.
-+       * The name needs to be changed for the xscale accumulator too. */
-+      *setname = "MMX";
-+      *type = DW_ATE_unsigned;
-+      *bits = 32;
-+      memcpy(name, "wcgr", 4);
-+      name[4] = regno - 104 + '0';
-+      namelen = 5;
-+      break;
-+
-+    case 112 + 0 ... 112 + 9:
-+      *setname = "MMX";
-+      *type = DW_ATE_unsigned;
-+      *bits = 64;
-+      name[0] = 'w';
-+      name[1] = 'r';
-+      name[2] = regno - 112 + '0';
-+      namelen = 3;
-+      break;
-+
-+    case 112 + 10 ... 112 + 15:
-+      *setname = "MMX";
-+      *type = DW_ATE_unsigned;
-+      *bits = 64;
-+      name[0] = 'w';
-+      name[1] = 'r';
-+      name[2] = '1';
-+      name[3] = regno - 112 - 10 + '0';
-+      namelen = 4;
-+      break;
-+
-     case 128:
-+      *setname = "state";
-       *type = DW_ATE_unsigned;
-       return stpcpy (name, "spsr") + 1 - name;
- 
-+    case 129:
-+      *setname = "state";
-+      *type = DW_ATE_unsigned;
-+      return stpcpy(name, "spsr_fiq") + 1 - name;
-+
-+    case 130:
-+      *setname = "state";
-+      *type = DW_ATE_unsigned;
-+      return stpcpy(name, "spsr_irq") + 1 - name;
-+
-+    case 131:
-+      *setname = "state";
-+      *type = DW_ATE_unsigned;
-+      return stpcpy(name, "spsr_abt") + 1 - name;
-+
-+    case 132:
-+      *setname = "state";
-+      *type = DW_ATE_unsigned;
-+      return stpcpy(name, "spsr_und") + 1 - name;
-+
-+    case 133:
-+      *setname = "state";
-+      *type = DW_ATE_unsigned;
-+      return stpcpy(name, "spsr_svc") + 1 - name;
-+
-+    case 144 ... 150:
-+      *setname = "integer";
-+      *type = DW_ATE_signed;
-+      *bits = 32;
-+      return sprintf(name, "r%d_usr", regno - 144 + 8) + 1;
-+
-+    case 151 ... 157:
-+      *setname = "integer";
-+      *type = DW_ATE_signed;
-+      *bits = 32;
-+      return sprintf(name, "r%d_fiq", regno - 151 + 8) + 1;
-+
-+    case 158 ... 159:
-+      *setname = "integer";
-+      *type = DW_ATE_signed;
-+      *bits = 32;
-+      return sprintf(name, "r%d_irq", regno - 158 + 13) + 1;
-+
-+    case 160 ... 161:
-+      *setname = "integer";
-+      *type = DW_ATE_signed;
-+      *bits = 32;
-+      return sprintf(name, "r%d_abt", regno - 160 + 13) + 1;
-+
-+    case 162 ... 163:
-+      *setname = "integer";
-+      *type = DW_ATE_signed;
-+      *bits = 32;
-+      return sprintf(name, "r%d_und", regno - 162 + 13) + 1;
-+
-+    case 164 ... 165:
-+      *setname = "integer";
-+      *type = DW_ATE_signed;
-+      *bits = 32;
-+      return sprintf(name, "r%d_svc", regno - 164 + 13) + 1;
-+
-+    case 192 ... 199:
-+     *setname = "MMX";
-+      *bits = 32;
-+      *type = DW_ATE_unsigned;
-+      name[0] = 'w';
-+      name[1] = 'c';
-+      name[2] = regno - 192 + '0';
-+      namelen = 3;
-+      break;
-+
-     case 256 + 0 ... 256 + 9:
-+      /* XXX TODO: Neon also uses those registers and can contain
-+       * both float and integers */
-       *setname = "VFP";
-       *type = DW_ATE_float;
-       *bits = 64;
-Index: b/backends/arm_retval.c
-===================================================================
---- a/backends/arm_retval.c
-+++ b/backends/arm_retval.c
-@@ -48,6 +48,13 @@ static const Dwarf_Op loc_intreg[] =
- #define nloc_intreg	1
- #define nloc_intregs(n)	(2 * (n))
- 
-+/* f1  */ /* XXX TODO: f0 can also have number 96 if program was compiled with -mabi=aapcs */
-+static const Dwarf_Op loc_fpreg[] =
-+  {
-+    { .atom = DW_OP_reg16 },
-+  };
-+#define nloc_fpreg  1
-+
- /* The return value is a structure and is actually stored in stack space
-    passed in a hidden argument by the caller.  But, the compiler
-    helpfully returns the address of that space in r0.  */
-@@ -58,8 +65,9 @@ static const Dwarf_Op loc_aggregate[] =
- #define nloc_aggregate 1
- 
- 
--int
--arm_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
-+static int
-+arm_return_value_location_ (Dwarf_Die *functypedie, const Dwarf_Op **locp,
-+		            int soft_float)
- {
-   /* Start with the function's type, and get the DW_AT_type attribute,
-      which is the type of the return value.  */
-@@ -98,6 +106,21 @@ arm_return_value_location (Dwarf_Die *fu
- 	    else
- 	      return -1;
- 	  }
-+	if (tag == DW_TAG_base_type)
-+	  {
-+	    Dwarf_Word encoding;
-+	    if (dwarf_formudata (dwarf_attr_integrate (typedie, DW_AT_encoding,
-+				 &attr_mem), &encoding) != 0)
-+	      return -1;
-+
-+	    if ((encoding == DW_ATE_float) && !soft_float)
-+	      {
-+		*locp = loc_fpreg;
-+		if (size <= 8)
-+		  return nloc_fpreg;
-+		goto aggregate;
-+	      }
-+	  }
- 	if (size <= 16)
- 	  {
- 	  intreg:
-@@ -106,6 +129,7 @@ arm_return_value_location (Dwarf_Die *fu
- 	  }
- 
-       aggregate:
-+	/* XXX TODO sometimes aggregates are returned in r0 (-mabi=aapcs) */
- 	*locp = loc_aggregate;
- 	return nloc_aggregate;
-       }
-@@ -125,3 +149,18 @@ arm_return_value_location (Dwarf_Die *fu
-      DWARF and might be valid.  */
-   return -2;
- }
-+
-+/* return location for -mabi=apcs-gnu -msoft-float */
-+int
-+arm_return_value_location_soft (Dwarf_Die *functypedie, const Dwarf_Op **locp)
-+{
-+   return arm_return_value_location_ (functypedie, locp, 1);
-+}
-+
-+/* return location for -mabi=apcs-gnu -mhard-float (current default) */
-+int
-+arm_return_value_location_hard (Dwarf_Die *functypedie, const Dwarf_Op **locp)
-+{
-+   return arm_return_value_location_ (functypedie, locp, 0);
-+}
-+
-Index: b/libelf/elf.h
-===================================================================
---- a/libelf/elf.h
-+++ b/libelf/elf.h
-@@ -2593,6 +2593,9 @@ enum
- #define EF_ARM_EABI_VER4	0x04000000
- #define EF_ARM_EABI_VER5	0x05000000
- 
-+/* EI_OSABI values */
-+#define ELFOSABI_ARM_AEABI    64      /* Contains symbol versioning. */
-+
- /* Additional symbol types for Thumb.  */
- #define STT_ARM_TFUNC		STT_LOPROC /* A Thumb function.  */
- #define STT_ARM_16BIT		STT_HIPROC /* A Thumb label.  */
-@@ -2610,12 +2613,19 @@ enum
- 
- /* Processor specific values for the Phdr p_type field.  */
- #define PT_ARM_EXIDX		(PT_LOPROC + 1)	/* ARM unwind segment.  */
-+#define PT_ARM_UNWIND		PT_ARM_EXIDX
- 
- /* Processor specific values for the Shdr sh_type field.  */
- #define SHT_ARM_EXIDX		(SHT_LOPROC + 1) /* ARM unwind section.  */
- #define SHT_ARM_PREEMPTMAP	(SHT_LOPROC + 2) /* Preemption details.  */
- #define SHT_ARM_ATTRIBUTES	(SHT_LOPROC + 3) /* ARM attributes section.  */
- 
-+/* Processor specific values for the Dyn d_tag field.  */
-+#define DT_ARM_RESERVED1	(DT_LOPROC + 0)
-+#define DT_ARM_SYMTABSZ		(DT_LOPROC + 1)
-+#define DT_ARM_PREEMTMAB	(DT_LOPROC + 2)
-+#define DT_ARM_RESERVED2	(DT_LOPROC + 3)
-+#define DT_ARM_NUM		4
- 
- /* AArch64 relocs.  */
- 
-@@ -2908,6 +2918,7 @@ enum
- 					   TLS block (LDR, STR).  */
- #define R_ARM_TLS_IE12GP	111	/* 12 bit GOT entry relative
- 					   to GOT origin (LDR).  */
-+/* 112 - 127 private range */
- #define R_ARM_ME_TOO		128	/* Obsolete.  */
- #define R_ARM_THM_TLS_DESCSEQ	129
- #define R_ARM_THM_TLS_DESCSEQ16	129
-Index: b/backends/libebl_arm.h
-===================================================================
---- /dev/null
-+++ b/backends/libebl_arm.h
-@@ -0,0 +1,9 @@
-+#ifndef _LIBEBL_ARM_H
-+#define _LIBEBL_ARM_H 1
-+
-+#include <libdw.h>
-+
-+extern int arm_return_value_location_soft(Dwarf_Die *, const Dwarf_Op **locp);
-+extern int arm_return_value_location_hard(Dwarf_Die *, const Dwarf_Op **locp);
-+
-+#endif
-Index: b/tests/run-allregs.sh
-===================================================================
---- a/tests/run-allregs.sh
-+++ b/tests/run-allregs.sh
-@@ -2672,7 +2672,28 @@ integer registers:
- 	 13: sp (sp), address 32 bits
- 	 14: lr (lr), address 32 bits
- 	 15: pc (pc), address 32 bits
--	128: spsr (spsr), unsigned 32 bits
-+	144: r8_usr (r8_usr), signed 32 bits
-+	145: r9_usr (r9_usr), signed 32 bits
-+	146: r10_usr (r10_usr), signed 32 bits
-+	147: r11_usr (r11_usr), signed 32 bits
-+	148: r12_usr (r12_usr), signed 32 bits
-+	149: r13_usr (r13_usr), signed 32 bits
-+	150: r14_usr (r14_usr), signed 32 bits
-+	151: r8_fiq (r8_fiq), signed 32 bits
-+	152: r9_fiq (r9_fiq), signed 32 bits
-+	153: r10_fiq (r10_fiq), signed 32 bits
-+	154: r11_fiq (r11_fiq), signed 32 bits
-+	155: r12_fiq (r12_fiq), signed 32 bits
-+	156: r13_fiq (r13_fiq), signed 32 bits
-+	157: r14_fiq (r14_fiq), signed 32 bits
-+	158: r13_irq (r13_irq), signed 32 bits
-+	159: r14_irq (r14_irq), signed 32 bits
-+	160: r13_abt (r13_abt), signed 32 bits
-+	161: r14_abt (r14_abt), signed 32 bits
-+	162: r13_und (r13_und), signed 32 bits
-+	163: r14_und (r14_und), signed 32 bits
-+	164: r13_svc (r13_svc), signed 32 bits
-+	165: r14_svc (r14_svc), signed 32 bits
- FPA registers:
- 	 16: f0 (f0), float 96 bits
- 	 17: f1 (f1), float 96 bits
-@@ -2690,7 +2711,72 @@ FPA registers:
- 	101: f5 (f5), float 96 bits
- 	102: f6 (f6), float 96 bits
- 	103: f7 (f7), float 96 bits
-+MMX registers:
-+	104: wcgr0 (wcgr0), unsigned 32 bits
-+	105: wcgr1 (wcgr1), unsigned 32 bits
-+	106: wcgr2 (wcgr2), unsigned 32 bits
-+	107: wcgr3 (wcgr3), unsigned 32 bits
-+	108: wcgr4 (wcgr4), unsigned 32 bits
-+	109: wcgr5 (wcgr5), unsigned 32 bits
-+	110: wcgr6 (wcgr6), unsigned 32 bits
-+	111: wcgr7 (wcgr7), unsigned 32 bits
-+	112: wr0 (wr0), unsigned 64 bits
-+	113: wr1 (wr1), unsigned 64 bits
-+	114: wr2 (wr2), unsigned 64 bits
-+	115: wr3 (wr3), unsigned 64 bits
-+	116: wr4 (wr4), unsigned 64 bits
-+	117: wr5 (wr5), unsigned 64 bits
-+	118: wr6 (wr6), unsigned 64 bits
-+	119: wr7 (wr7), unsigned 64 bits
-+	120: wr8 (wr8), unsigned 64 bits
-+	121: wr9 (wr9), unsigned 64 bits
-+	122: wr10 (wr10), unsigned 64 bits
-+	123: wr11 (wr11), unsigned 64 bits
-+	124: wr12 (wr12), unsigned 64 bits
-+	125: wr13 (wr13), unsigned 64 bits
-+	126: wr14 (wr14), unsigned 64 bits
-+	127: wr15 (wr15), unsigned 64 bits
-+	192: wc0 (wc0), unsigned 32 bits
-+	193: wc1 (wc1), unsigned 32 bits
-+	194: wc2 (wc2), unsigned 32 bits
-+	195: wc3 (wc3), unsigned 32 bits
-+	196: wc4 (wc4), unsigned 32 bits
-+	197: wc5 (wc5), unsigned 32 bits
-+	198: wc6 (wc6), unsigned 32 bits
-+	199: wc7 (wc7), unsigned 32 bits
- VFP registers:
-+	 64: s0 (s0), float 32 bits
-+	 65: s1 (s1), float 32 bits
-+	 66: s2 (s2), float 32 bits
-+	 67: s3 (s3), float 32 bits
-+	 68: s4 (s4), float 32 bits
-+	 69: s5 (s5), float 32 bits
-+	 70: s6 (s6), float 32 bits
-+	 71: s7 (s7), float 32 bits
-+	 72: s8 (s8), float 32 bits
-+	 73: s9 (s9), float 32 bits
-+	 74: s10 (s10), float 32 bits
-+	 75: s11 (s11), float 32 bits
-+	 76: s12 (s12), float 32 bits
-+	 77: s13 (s13), float 32 bits
-+	 78: s14 (s14), float 32 bits
-+	 79: s15 (s15), float 32 bits
-+	 80: s16 (s16), float 32 bits
-+	 81: s17 (s17), float 32 bits
-+	 82: s18 (s18), float 32 bits
-+	 83: s19 (s19), float 32 bits
-+	 84: s20 (s20), float 32 bits
-+	 85: s21 (s21), float 32 bits
-+	 86: s22 (s22), float 32 bits
-+	 87: s23 (s23), float 32 bits
-+	 88: s24 (s24), float 32 bits
-+	 89: s25 (s25), float 32 bits
-+	 90: s26 (s26), float 32 bits
-+	 91: s27 (s27), float 32 bits
-+	 92: s28 (s28), float 32 bits
-+	 93: s29 (s29), float 32 bits
-+	 94: s30 (s30), float 32 bits
-+	 95: s31 (s31), float 32 bits
- 	256: d0 (d0), float 64 bits
- 	257: d1 (d1), float 64 bits
- 	258: d2 (d2), float 64 bits
-@@ -2723,6 +2809,13 @@ VFP registers:
- 	285: d29 (d29), float 64 bits
- 	286: d30 (d30), float 64 bits
- 	287: d31 (d31), float 64 bits
-+state registers:
-+	128: spsr (spsr), unsigned 32 bits
-+	129: spsr_fiq (spsr_fiq), unsigned 32 bits
-+	130: spsr_irq (spsr_irq), unsigned 32 bits
-+	131: spsr_abt (spsr_abt), unsigned 32 bits
-+	132: spsr_und (spsr_und), unsigned 32 bits
-+	133: spsr_svc (spsr_svc), unsigned 32 bits
- EOF
- 
- # See run-readelf-mixed-corenote.sh for instructions to regenerate
-Index: b/tests/run-readelf-mixed-corenote.sh
-===================================================================
---- a/tests/run-readelf-mixed-corenote.sh
-+++ b/tests/run-readelf-mixed-corenote.sh
-@@ -31,12 +31,11 @@ Note segment of 892 bytes at offset 0x27
-     pid: 11087, ppid: 11063, pgrp: 11087, sid: 11063
-     utime: 0.000000, stime: 0.010000, cutime: 0.000000, cstime: 0.000000
-     orig_r0: -1, fpvalid: 1
--    r0:             1  r1:   -1091672508  r2:   -1091672500
--    r3:             0  r4:             0  r5:             0
--    r6:         33728  r7:             0  r8:             0
--    r9:             0  r10:  -1225703496  r11:  -1091672844
--    r12:            0  sp:    0xbeee64f4  lr:    0xb6dc3f48
--    pc:    0x00008500  spsr:  0x60000010
-+    r0:            1  r1:  -1091672508  r2:  -1091672500  r3:            0
-+    r4:            0  r5:            0  r6:        33728  r7:            0
-+    r8:            0  r9:            0  r10: -1225703496  r11: -1091672844
-+    r12:           0  sp:   0xbeee64f4  lr:   0xb6dc3f48  pc:   0x00008500
-+    spsr:  0x60000010
-   CORE                 124  PRPSINFO
-     state: 0, sname: R, zomb: 0, nice: 0, flag: 0x00400500
-     uid: 0, gid: 0, pid: 11087, ppid: 11063, pgrp: 11087, sid: 11063
-Index: b/tests/run-addrcfi.sh
-===================================================================
---- a/tests/run-addrcfi.sh
-+++ b/tests/run-addrcfi.sh
-@@ -3554,6 +3554,38 @@ dwarf_cfi_addrframe (.eh_frame): no matc
- 	FPA reg21 (f5): undefined
- 	FPA reg22 (f6): undefined
- 	FPA reg23 (f7): undefined
-+	VFP reg64 (s0): undefined
-+	VFP reg65 (s1): undefined
-+	VFP reg66 (s2): undefined
-+	VFP reg67 (s3): undefined
-+	VFP reg68 (s4): undefined
-+	VFP reg69 (s5): undefined
-+	VFP reg70 (s6): undefined
-+	VFP reg71 (s7): undefined
-+	VFP reg72 (s8): undefined
-+	VFP reg73 (s9): undefined
-+	VFP reg74 (s10): undefined
-+	VFP reg75 (s11): undefined
-+	VFP reg76 (s12): undefined
-+	VFP reg77 (s13): undefined
-+	VFP reg78 (s14): undefined
-+	VFP reg79 (s15): undefined
-+	VFP reg80 (s16): undefined
-+	VFP reg81 (s17): undefined
-+	VFP reg82 (s18): undefined
-+	VFP reg83 (s19): undefined
-+	VFP reg84 (s20): undefined
-+	VFP reg85 (s21): undefined
-+	VFP reg86 (s22): undefined
-+	VFP reg87 (s23): undefined
-+	VFP reg88 (s24): undefined
-+	VFP reg89 (s25): undefined
-+	VFP reg90 (s26): undefined
-+	VFP reg91 (s27): undefined
-+	VFP reg92 (s28): undefined
-+	VFP reg93 (s29): undefined
-+	VFP reg94 (s30): undefined
-+	VFP reg95 (s31): undefined
- 	FPA reg96 (f0): undefined
- 	FPA reg97 (f1): undefined
- 	FPA reg98 (f2): undefined
-@@ -3562,7 +3594,66 @@ dwarf_cfi_addrframe (.eh_frame): no matc
- 	FPA reg101 (f5): undefined
- 	FPA reg102 (f6): undefined
- 	FPA reg103 (f7): undefined
--	integer reg128 (spsr): undefined
-+	MMX reg104 (wcgr0): undefined
-+	MMX reg105 (wcgr1): undefined
-+	MMX reg106 (wcgr2): undefined
-+	MMX reg107 (wcgr3): undefined
-+	MMX reg108 (wcgr4): undefined
-+	MMX reg109 (wcgr5): undefined
-+	MMX reg110 (wcgr6): undefined
-+	MMX reg111 (wcgr7): undefined
-+	MMX reg112 (wr0): undefined
-+	MMX reg113 (wr1): undefined
-+	MMX reg114 (wr2): undefined
-+	MMX reg115 (wr3): undefined
-+	MMX reg116 (wr4): undefined
-+	MMX reg117 (wr5): undefined
-+	MMX reg118 (wr6): undefined
-+	MMX reg119 (wr7): undefined
-+	MMX reg120 (wr8): undefined
-+	MMX reg121 (wr9): undefined
-+	MMX reg122 (wr10): undefined
-+	MMX reg123 (wr11): undefined
-+	MMX reg124 (wr12): undefined
-+	MMX reg125 (wr13): undefined
-+	MMX reg126 (wr14): undefined
-+	MMX reg127 (wr15): undefined
-+	state reg128 (spsr): undefined
-+	state reg129 (spsr_fiq): undefined
-+	state reg130 (spsr_irq): undefined
-+	state reg131 (spsr_abt): undefined
-+	state reg132 (spsr_und): undefined
-+	state reg133 (spsr_svc): undefined
-+	integer reg144 (r8_usr): undefined
-+	integer reg145 (r9_usr): undefined
-+	integer reg146 (r10_usr): undefined
-+	integer reg147 (r11_usr): undefined
-+	integer reg148 (r12_usr): undefined
-+	integer reg149 (r13_usr): undefined
-+	integer reg150 (r14_usr): undefined
-+	integer reg151 (r8_fiq): undefined
-+	integer reg152 (r9_fiq): undefined
-+	integer reg153 (r10_fiq): undefined
-+	integer reg154 (r11_fiq): undefined
-+	integer reg155 (r12_fiq): undefined
-+	integer reg156 (r13_fiq): undefined
-+	integer reg157 (r14_fiq): undefined
-+	integer reg158 (r13_irq): undefined
-+	integer reg159 (r14_irq): undefined
-+	integer reg160 (r13_abt): undefined
-+	integer reg161 (r14_abt): undefined
-+	integer reg162 (r13_und): undefined
-+	integer reg163 (r14_und): undefined
-+	integer reg164 (r13_svc): undefined
-+	integer reg165 (r14_svc): undefined
-+	MMX reg192 (wc0): undefined
-+	MMX reg193 (wc1): undefined
-+	MMX reg194 (wc2): undefined
-+	MMX reg195 (wc3): undefined
-+	MMX reg196 (wc4): undefined
-+	MMX reg197 (wc5): undefined
-+	MMX reg198 (wc6): undefined
-+	MMX reg199 (wc7): undefined
- 	VFP reg256 (d0): undefined
- 	VFP reg257 (d1): undefined
- 	VFP reg258 (d2): undefined
diff --git a/poky/meta/recipes-devtools/elfutils/files/debian/hppa_backend.diff b/poky/meta/recipes-devtools/elfutils/files/debian/hppa_backend.diff
deleted file mode 100644
index 56f852a..0000000
--- a/poky/meta/recipes-devtools/elfutils/files/debian/hppa_backend.diff
+++ /dev/null
@@ -1,802 +0,0 @@
-Upstream-Status: Backport [from debian]
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
-
-Index: elfutils-0.170/backends/parisc_init.c
-===================================================================
---- /dev/null
-+++ elfutils-0.170/backends/parisc_init.c
-@@ -0,0 +1,73 @@
-+/* Initialization of PA-RISC specific backend library.
-+   Copyright (C) 2002, 2005, 2006 Red Hat, Inc.
-+   This file is part of Red Hat elfutils.
-+   Written by Ulrich Drepper <drepper@redhat.com>, 2002.
-+
-+   Red Hat elfutils is free software; you can redistribute it and/or modify
-+   it under the terms of the GNU General Public License as published by the
-+   Free Software Foundation; version 2 of the License.
-+
-+   Red Hat elfutils is distributed in the hope that it will be useful, but
-+   WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   General Public License for more details.
-+
-+   You should have received a copy of the GNU General Public License along
-+   with Red Hat elfutils; if not, write to the Free Software Foundation,
-+   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
-+
-+   Red Hat elfutils is an included package of the Open Invention Network.
-+   An included package of the Open Invention Network is a package for which
-+   Open Invention Network licensees cross-license their patents.  No patent
-+   license is granted, either expressly or impliedly, by designation as an
-+   included package.  Should you wish to participate in the Open Invention
-+   Network licensing program, please visit www.openinventionnetwork.com
-+   <http://www.openinventionnetwork.com>.  */
-+
-+#ifdef HAVE_CONFIG_H
-+# include <config.h>
-+#endif
-+
-+#define BACKEND		parisc_
-+#define RELOC_PREFIX	R_PARISC_
-+#include "libebl_CPU.h"
-+#include "libebl_parisc.h"
-+
-+/* This defines the common reloc hooks based on parisc_reloc.def.  */
-+#include "common-reloc.c"
-+
-+
-+const char *
-+parisc_init (Elf *elf __attribute__ ((unused)),
-+     GElf_Half machine __attribute__ ((unused)),
-+     Ebl *eh,
-+     size_t ehlen)
-+{
-+  int pa64 = 0;
-+
-+  /* Check whether the Elf_BH object has a sufficent size.  */
-+  if (ehlen < sizeof (Ebl))
-+    return NULL;
-+
-+  if (elf) {
-+    GElf_Ehdr ehdr_mem;
-+    GElf_Ehdr *ehdr = gelf_getehdr (elf, &ehdr_mem);
-+    if (ehdr && (ehdr->e_flags & EF_PARISC_WIDE))
-+      pa64 = 1;
-+  }
-+  /* We handle it.  */
-+  eh->name = "PA-RISC";
-+  parisc_init_reloc (eh);
-+  HOOK (eh, reloc_simple_type);
-+  HOOK (eh, machine_flag_check);
-+  HOOK (eh, symbol_type_name);
-+  HOOK (eh, segment_type_name);
-+  HOOK (eh, section_type_name);
-+  HOOK (eh, register_info);
-+  if (pa64)
-+    eh->return_value_location = parisc_return_value_location_64;
-+  else
-+    eh->return_value_location = parisc_return_value_location_32;
-+
-+  return MODVERSION;
-+}
-Index: elfutils-0.170/backends/parisc_regs.c
-===================================================================
---- /dev/null
-+++ elfutils-0.170/backends/parisc_regs.c
-@@ -0,0 +1,159 @@
-+/* Register names and numbers for PA-RISC DWARF.
-+   Copyright (C) 2005, 2006 Red Hat, Inc.
-+   This file is part of Red Hat elfutils.
-+
-+   Red Hat elfutils is free software; you can redistribute it and/or modify
-+   it under the terms of the GNU General Public License as published by the
-+   Free Software Foundation; version 2 of the License.
-+
-+   Red Hat elfutils is distributed in the hope that it will be useful, but
-+   WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   General Public License for more details.
-+
-+   You should have received a copy of the GNU General Public License along
-+   with Red Hat elfutils; if not, write to the Free Software Foundation,
-+   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
-+
-+   Red Hat elfutils is an included package of the Open Invention Network.
-+   An included package of the Open Invention Network is a package for which
-+   Open Invention Network licensees cross-license their patents.  No patent
-+   license is granted, either expressly or impliedly, by designation as an
-+   included package.  Should you wish to participate in the Open Invention
-+   Network licensing program, please visit www.openinventionnetwork.com
-+   <http://www.openinventionnetwork.com>.  */
-+
-+#ifdef HAVE_CONFIG_H
-+# include <config.h>
-+#endif
-+
-+#include <string.h>
-+#include <dwarf.h>
-+
-+#define BACKEND parisc_
-+#include "libebl_CPU.h"
-+
-+ssize_t
-+parisc_register_info (Ebl *ebl, int regno, char *name, size_t namelen,
-+		     const char **prefix, const char **setname,
-+		     int *bits, int *type)
-+{
-+  int pa64 = 0;
-+
-+  if (ebl->elf) {
-+    GElf_Ehdr ehdr_mem;
-+    GElf_Ehdr *ehdr = gelf_getehdr (ebl->elf, &ehdr_mem);
-+    if (ehdr->e_flags & EF_PARISC_WIDE)
-+      pa64 = 1;
-+  }
-+
-+  int nregs = pa64 ? 127 : 128;
-+
-+  if (name == NULL)
-+    return nregs;
-+
-+  if (regno < 0 || regno >= nregs || namelen < 6)
-+    return -1;
-+
-+  *prefix = "%";
-+
-+  if (regno < 32)
-+  {
-+    *setname = "integer";
-+    *type = DW_ATE_signed;
-+    if (pa64)
-+    {
-+	*bits = 64;
-+    }
-+    else
-+    {
-+    	*bits = 32;
-+    }
-+  }
-+  else if (regno == 32)
-+  {
-+    *setname = "special";
-+    if (pa64)
-+    {
-+	*bits = 6;
-+    }
-+    else
-+    {
-+    	*bits = 5;
-+    }
-+    *type = DW_ATE_unsigned;
-+  }
-+  else
-+  {
-+    *setname = "FPU";
-+    *type = DW_ATE_float;
-+    if (pa64)
-+    {
-+	*bits = 64;
-+    }
-+    else
-+    {
-+    	*bits = 32;
-+    }
-+  }
-+
-+  if (regno < 33) {
-+    switch (regno)
-+      {
-+      case 0 ... 9:
-+        name[0] = 'r';
-+        name[1] = regno + '0';
-+        namelen = 2;
-+        break;
-+      case 10 ... 31:
-+        name[0] = 'r';
-+        name[1] = regno / 10 + '0';
-+        name[2] = regno % 10 + '0';
-+        namelen = 3;
-+        break;
-+      case 32:
-+	*prefix = NULL;
-+	name[0] = 'S';
-+	name[1] = 'A';
-+	name[2] = 'R';
-+	namelen = 3;
-+	break;
-+      }
-+  }
-+  else {
-+    if (pa64 && ((regno - 72) % 2)) {
-+      *setname = NULL;
-+      return 0;
-+    }
-+
-+    switch (regno)
-+      {
-+      case 72 + 0 ... 72 + 11:
-+        name[0] = 'f';
-+	name[1] = 'r';
-+        name[2] = (regno + 8 - 72) / 2 + '0';
-+        namelen = 3;
-+        if ((regno + 8 - 72) % 2) {
-+	  name[3] = 'R';
-+	  namelen++;
-+        }
-+        break;
-+      case 72 + 12 ... 72 + 55:
-+        name[0] = 'f';
-+	name[1] = 'r';
-+        name[2] = (regno + 8 - 72) / 2 / 10 + '0';
-+        name[3] = (regno + 8 - 72) / 2 % 10 + '0';
-+        namelen = 4;
-+        if ((regno + 8 - 72) % 2) {
-+	  name[4] = 'R';
-+	  namelen++;
-+        }
-+        break;
-+      default:
-+        *setname = NULL;
-+        return 0;
-+      }
-+  }
-+  name[namelen++] = '\0';
-+  return namelen;
-+}
-Index: elfutils-0.170/backends/parisc_reloc.def
-===================================================================
---- /dev/null
-+++ elfutils-0.170/backends/parisc_reloc.def
-@@ -0,0 +1,128 @@
-+/* List the relocation types for PA-RISC.  -*- C -*-
-+   Copyright (C) 2005 Red Hat, Inc.
-+   This file is part of Red Hat elfutils.
-+
-+   Red Hat elfutils is free software; you can redistribute it and/or modify
-+   it under the terms of the GNU General Public License as published by the
-+   Free Software Foundation; version 2 of the License.
-+
-+   Red Hat elfutils is distributed in the hope that it will be useful, but
-+   WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   General Public License for more details.
-+
-+   You should have received a copy of the GNU General Public License along
-+   with Red Hat elfutils; if not, write to the Free Software Foundation,
-+   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
-+
-+   Red Hat elfutils is an included package of the Open Invention Network.
-+   An included package of the Open Invention Network is a package for which
-+   Open Invention Network licensees cross-license their patents.  No patent
-+   license is granted, either expressly or impliedly, by designation as an
-+   included package.  Should you wish to participate in the Open Invention
-+   Network licensing program, please visit www.openinventionnetwork.com
-+   <http://www.openinventionnetwork.com>.  */
-+
-+/*	    NAME,		REL|EXEC|DYN	*/
-+
-+RELOC_TYPE (NONE,		EXEC|DYN)
-+RELOC_TYPE (DIR32,		REL|EXEC|DYN)
-+RELOC_TYPE (DIR21L,		REL|EXEC|DYN)
-+RELOC_TYPE (DIR17R,		REL)
-+RELOC_TYPE (DIR17F,		REL)
-+RELOC_TYPE (DIR14R,		REL|DYN)
-+RELOC_TYPE (PCREL32,		REL)
-+RELOC_TYPE (PCREL21L,		REL)
-+RELOC_TYPE (PCREL17R,		REL)
-+RELOC_TYPE (PCREL17F,		REL)
-+RELOC_TYPE (PCREL14R,		REL|EXEC)
-+RELOC_TYPE (DPREL21L,		REL)
-+RELOC_TYPE (DPREL14WR,		REL)
-+RELOC_TYPE (DPREL14DR,          REL)
-+RELOC_TYPE (DPREL14R,		REL)
-+RELOC_TYPE (GPREL21L,		0)
-+RELOC_TYPE (GPREL14R,		0)
-+RELOC_TYPE (LTOFF21L,		REL)
-+RELOC_TYPE (LTOFF14R,		REL)
-+RELOC_TYPE (DLTIND14F,		0)
-+RELOC_TYPE (SETBASE,		0)
-+RELOC_TYPE (SECREL32,		REL)
-+RELOC_TYPE (BASEREL21L,		0)
-+RELOC_TYPE (BASEREL17R,		0)
-+RELOC_TYPE (BASEREL14R,		0)
-+RELOC_TYPE (SEGBASE,		0)
-+RELOC_TYPE (SEGREL32,		REL)
-+RELOC_TYPE (PLTOFF21L,		0)
-+RELOC_TYPE (PLTOFF14R,		0)
-+RELOC_TYPE (PLTOFF14F,		0)
-+RELOC_TYPE (LTOFF_FPTR32,	0)
-+RELOC_TYPE (LTOFF_FPTR21L,	0)
-+RELOC_TYPE (LTOFF_FPTR14R,	0)
-+RELOC_TYPE (FPTR64,		0)
-+RELOC_TYPE (PLABEL32,		REL|DYN)
-+RELOC_TYPE (PCREL64,		0)
-+RELOC_TYPE (PCREL22C,		0)
-+RELOC_TYPE (PCREL22F,		0)
-+RELOC_TYPE (PCREL14WR,		0)
-+RELOC_TYPE (PCREL14DR,		0)
-+RELOC_TYPE (PCREL16F,		0)
-+RELOC_TYPE (PCREL16WF,		0)
-+RELOC_TYPE (PCREL16DF,		0)
-+RELOC_TYPE (DIR64,		REL|DYN)
-+RELOC_TYPE (DIR14WR,		REL)
-+RELOC_TYPE (DIR14DR,		REL)
-+RELOC_TYPE (DIR16F,		REL)
-+RELOC_TYPE (DIR16WF,		REL)
-+RELOC_TYPE (DIR16DF,		REL)
-+RELOC_TYPE (GPREL64,		0)
-+RELOC_TYPE (GPREL14WR,		0)
-+RELOC_TYPE (GPREL14DR,		0)
-+RELOC_TYPE (GPREL16F,		0)
-+RELOC_TYPE (GPREL16WF,		0)
-+RELOC_TYPE (GPREL16DF,		0)
-+RELOC_TYPE (LTOFF64,		0)
-+RELOC_TYPE (LTOFF14WR,		0)
-+RELOC_TYPE (LTOFF14DR,		0)
-+RELOC_TYPE (LTOFF16F,		0)
-+RELOC_TYPE (LTOFF16WF,		0)
-+RELOC_TYPE (LTOFF16DF,		0)
-+RELOC_TYPE (SECREL64,		0)
-+RELOC_TYPE (BASEREL14WR,	0)
-+RELOC_TYPE (BASEREL14DR,	0)
-+RELOC_TYPE (SEGREL64,		0)
-+RELOC_TYPE (PLTOFF14WR,		0)
-+RELOC_TYPE (PLTOFF14DR,		0)
-+RELOC_TYPE (PLTOFF16F,		0)
-+RELOC_TYPE (PLTOFF16WF,		0)
-+RELOC_TYPE (PLTOFF16DF,		0)
-+RELOC_TYPE (LTOFF_FPTR64,	0)
-+RELOC_TYPE (LTOFF_FPTR14WR,	0)
-+RELOC_TYPE (LTOFF_FPTR14DR,	0)
-+RELOC_TYPE (LTOFF_FPTR16F,	0)
-+RELOC_TYPE (LTOFF_FPTR16WF,	0)
-+RELOC_TYPE (LTOFF_FPTR16DF,	0)
-+RELOC_TYPE (COPY,		EXEC)
-+RELOC_TYPE (IPLT,		EXEC|DYN)
-+RELOC_TYPE (EPLT,		0)
-+RELOC_TYPE (TPREL32,		DYN)
-+RELOC_TYPE (TPREL21L,		0)
-+RELOC_TYPE (TPREL14R,		0)
-+RELOC_TYPE (LTOFF_TP21L,	0)
-+RELOC_TYPE (LTOFF_TP14R,	0)
-+RELOC_TYPE (LTOFF_TP14F,	0)
-+RELOC_TYPE (TPREL64,		0)
-+RELOC_TYPE (TPREL14WR,		0)
-+RELOC_TYPE (TPREL14DR,		0)
-+RELOC_TYPE (TPREL16F,		0)
-+RELOC_TYPE (TPREL16WF,		0)
-+RELOC_TYPE (TPREL16DF,		0)
-+RELOC_TYPE (LTOFF_TP64,		0)
-+RELOC_TYPE (LTOFF_TP14WR,	0)
-+RELOC_TYPE (LTOFF_TP14DR,	0)
-+RELOC_TYPE (LTOFF_TP16F,	0)
-+RELOC_TYPE (LTOFF_TP16WF,	0)
-+RELOC_TYPE (LTOFF_TP16DF,	0)
-+RELOC_TYPE (TLS_DTPMOD32,	DYN)
-+RELOC_TYPE (TLS_DTPMOD64,	DYN)
-+
-+#define NO_RELATIVE_RELOC       1
-Index: elfutils-0.170/backends/parisc_retval.c
-===================================================================
---- /dev/null
-+++ elfutils-0.170/backends/parisc_retval.c
-@@ -0,0 +1,213 @@
-+/* Function return value location for Linux/PA-RISC ABI.
-+   Copyright (C) 2005 Red Hat, Inc.
-+   This file is part of Red Hat elfutils.
-+
-+   Red Hat elfutils is free software; you can redistribute it and/or modify
-+   it under the terms of the GNU General Public License as published by the
-+   Free Software Foundation; version 2 of the License.
-+
-+   Red Hat elfutils is distributed in the hope that it will be useful, but
-+   WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   General Public License for more details.
-+
-+   You should have received a copy of the GNU General Public License along
-+   with Red Hat elfutils; if not, write to the Free Software Foundation,
-+   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
-+
-+   Red Hat elfutils is an included package of the Open Invention Network.
-+   An included package of the Open Invention Network is a package for which
-+   Open Invention Network licensees cross-license their patents.  No patent
-+   license is granted, either expressly or impliedly, by designation as an
-+   included package.  Should you wish to participate in the Open Invention
-+   Network licensing program, please visit www.openinventionnetwork.com
-+   <http://www.openinventionnetwork.com>.  */
-+
-+#ifdef HAVE_CONFIG_H
-+# include <config.h>
-+#endif
-+
-+#include <assert.h>
-+#include <dwarf.h>
-+
-+#define BACKEND parisc_
-+#include "libebl_CPU.h"
-+#include "libebl_parisc.h"
-+
-+/* %r28, or pair %r28, %r29.  */
-+static const Dwarf_Op loc_intreg32[] =
-+  {
-+    { .atom = DW_OP_reg28 }, { .atom = DW_OP_piece, .number = 4 },
-+    { .atom = DW_OP_reg29 }, { .atom = DW_OP_piece, .number = 4 },
-+  };
-+
-+static const Dwarf_Op loc_intreg[] =
-+  {
-+    { .atom = DW_OP_reg28 }, { .atom = DW_OP_piece, .number = 8 },
-+    { .atom = DW_OP_reg29 }, { .atom = DW_OP_piece, .number = 8 },
-+  };
-+#define nloc_intreg	1
-+#define nloc_intregpair	4
-+
-+/* %fr4L, or pair %fr4L, %fr4R on pa-32 */
-+static const Dwarf_Op loc_fpreg32[] =
-+  {
-+    { .atom = DW_OP_regx, .number = 72 }, { .atom = DW_OP_piece, .number = 4 },
-+    { .atom = DW_OP_regx, .number = 73 }, { .atom = DW_OP_piece, .number = 4 },
-+  };
-+#define nloc_fpreg32 2
-+#define nloc_fpregpair32 4
-+
-+/* $fr4 */
-+static const Dwarf_Op loc_fpreg[] =
-+  {
-+    { .atom = DW_OP_regx, .number = 72 },
-+  };
-+#define nloc_fpreg  1
-+
-+#if 0
-+/* The return value is a structure and is actually stored in stack space
-+   passed in a hidden argument by the caller. Address of the location is stored
-+   in %r28 before function call, but it may be changed by function. */
-+static const Dwarf_Op loc_aggregate[] =
-+  {
-+    { .atom = DW_OP_breg28 },
-+  };
-+#define nloc_aggregate 1
-+#endif
-+
-+static int
-+parisc_return_value_location_ (Dwarf_Die *functypedie, const Dwarf_Op **locp, int pa64)
-+{
-+  Dwarf_Word regsize = pa64 ? 8 : 4;
-+
-+  /* Start with the function's type, and get the DW_AT_type attribute,
-+     which is the type of the return value.  */
-+
-+  Dwarf_Attribute attr_mem;
-+  Dwarf_Attribute *attr = dwarf_attr_integrate (functypedie, DW_AT_type, &attr_mem);
-+  if (attr == NULL)
-+    /* The function has no return value, like a `void' function in C.  */
-+    return 0;
-+
-+  Dwarf_Die die_mem;
-+  Dwarf_Die *typedie = dwarf_formref_die (attr, &die_mem);
-+  int tag = dwarf_tag (typedie);
-+
-+  /* Follow typedefs and qualifiers to get to the actual type.  */
-+  while (tag == DW_TAG_typedef
-+	 || tag == DW_TAG_const_type || tag == DW_TAG_volatile_type
-+	 || tag == DW_TAG_restrict_type)
-+    {
-+      attr = dwarf_attr_integrate (typedie, DW_AT_type, &attr_mem);
-+      typedie = dwarf_formref_die (attr, &die_mem);
-+      tag = dwarf_tag (typedie);
-+    }
-+
-+  switch (tag)
-+    {
-+    case -1:
-+      return -1;
-+
-+    case DW_TAG_subrange_type:
-+      if (! dwarf_hasattr_integrate (typedie, DW_AT_byte_size))
-+	{
-+	  attr = dwarf_attr_integrate (typedie, DW_AT_type, &attr_mem);
-+	  typedie = dwarf_formref_die (attr, &die_mem);
-+	  tag = dwarf_tag (typedie);
-+	}
-+      /* Fall through.  */
-+
-+    case DW_TAG_base_type:
-+    case DW_TAG_enumeration_type:
-+    case DW_TAG_pointer_type:
-+    case DW_TAG_ptr_to_member_type:
-+      {
-+        Dwarf_Word size;
-+	if (dwarf_formudata (dwarf_attr_integrate (typedie, DW_AT_byte_size,
-+					 &attr_mem), &size) != 0)
-+	  {
-+	    if (tag == DW_TAG_pointer_type || tag == DW_TAG_ptr_to_member_type)
-+	      size = 4;
-+	    else
-+	      return -1;
-+	  }
-+	if (tag == DW_TAG_base_type)
-+	  {
-+	    Dwarf_Word encoding;
-+	    if (dwarf_formudata (dwarf_attr_integrate (typedie, DW_AT_encoding,
-+					     &attr_mem), &encoding) != 0)
-+	      return -1;
-+
-+	    if (encoding == DW_ATE_float)
-+	      {
-+		if (pa64) {
-+		  *locp = loc_fpreg;
-+		  if (size <= 8)
-+		      return nloc_fpreg;
-+		}
-+		else {
-+		  *locp = loc_fpreg32;
-+		  if (size <= 4)
-+		    return nloc_fpreg32;
-+		  else if (size <= 8)
-+		    return nloc_fpregpair32;
-+		}
-+		goto aggregate;
-+	      }
-+	  }
-+	if (pa64)
-+	  *locp = loc_intreg;
-+	else
-+	  *locp = loc_intreg32;
-+	if (size <= regsize)
-+	  return nloc_intreg;
-+	if (size <= 2 * regsize)
-+	  return nloc_intregpair;
-+
-+	/* Else fall through.  */
-+      }
-+
-+    case DW_TAG_structure_type:
-+    case DW_TAG_class_type:
-+    case DW_TAG_union_type:
-+    case DW_TAG_array_type:
-+    aggregate: {
-+        Dwarf_Word size;
-+	if (dwarf_aggregate_size (typedie, &size) != 0)
-+	  return -1;
-+	if (pa64)
-+          *locp = loc_intreg;
-+	else
-+	  *locp = loc_intreg32;
-+        if (size <= regsize)
-+	  return nloc_intreg;
-+        if (size <= 2 * regsize)
-+	  return nloc_intregpair;
-+#if 0
-+	/* there should be some way to know this location... But I do not see it. */
-+        *locp = loc_aggregate;
-+        return nloc_aggregate;
-+#endif
-+	/* fall through.  */
-+      }
-+    }
-+
-+  /* XXX We don't have a good way to return specific errors from ebl calls.
-+     This value means we do not understand the type, but it is well-formed
-+     DWARF and might be valid.  */
-+  return -2;
-+}
-+
-+int
-+parisc_return_value_location_32 (Dwarf_Die *functypedie, const Dwarf_Op **locp)
-+{
-+  return parisc_return_value_location_ (functypedie, locp, 0);
-+}
-+
-+int
-+parisc_return_value_location_64 (Dwarf_Die *functypedie, const Dwarf_Op **locp)
-+{
-+  return parisc_return_value_location_ (functypedie, locp, 1);
-+}
-+
-Index: elfutils-0.170/backends/parisc_symbol.c
-===================================================================
---- /dev/null
-+++ elfutils-0.170/backends/parisc_symbol.c
-@@ -0,0 +1,112 @@
-+/* PA-RISC specific symbolic name handling.
-+   Copyright (C) 2002, 2005 Red Hat, Inc.
-+   This file is part of Red Hat elfutils.
-+   Written by Ulrich Drepper <drepper@redhat.com>, 2002.
-+
-+   Red Hat elfutils is free software; you can redistribute it and/or modify
-+   it under the terms of the GNU General Public License as published by the
-+   Free Software Foundation; version 2 of the License.
-+
-+   Red Hat elfutils is distributed in the hope that it will be useful, but
-+   WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   General Public License for more details.
-+
-+   You should have received a copy of the GNU General Public License along
-+   with Red Hat elfutils; if not, write to the Free Software Foundation,
-+   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
-+
-+   Red Hat elfutils is an included package of the Open Invention Network.
-+   An included package of the Open Invention Network is a package for which
-+   Open Invention Network licensees cross-license their patents.  No patent
-+   license is granted, either expressly or impliedly, by designation as an
-+   included package.  Should you wish to participate in the Open Invention
-+   Network licensing program, please visit www.openinventionnetwork.com
-+   <http://www.openinventionnetwork.com>.  */
-+
-+#ifdef HAVE_CONFIG_H
-+# include <config.h>
-+#endif
-+
-+#include <elf.h>
-+#include <stddef.h>
-+
-+#define BACKEND		parisc_
-+#include "libebl_CPU.h"
-+
-+const char *
-+parisc_segment_type_name (int segment, char *buf __attribute__ ((unused)),
-+			size_t len __attribute__ ((unused)))
-+{
-+  switch (segment)
-+    {
-+    case PT_PARISC_ARCHEXT:
-+      return "PARISC_ARCHEXT";
-+    case PT_PARISC_UNWIND:
-+      return "PARISC_UNWIND";
-+    default:
-+      break;
-+    }
-+  return NULL;
-+}
-+
-+/* Return symbolic representation of symbol type.  */
-+const char *
-+parisc_symbol_type_name(int symbol, char *buf __attribute__ ((unused)),
-+    size_t len __attribute__ ((unused)))
-+{
-+	if (symbol == STT_PARISC_MILLICODE)
-+	  return "PARISC_MILLI";
-+	return NULL;
-+}
-+
-+/* Return symbolic representation of section type.  */
-+const char *
-+parisc_section_type_name (int type,
-+			char *buf __attribute__ ((unused)),
-+			size_t len __attribute__ ((unused)))
-+{
-+  switch (type)
-+    {
-+    case SHT_PARISC_EXT:
-+      return "PARISC_EXT";
-+    case SHT_PARISC_UNWIND:
-+      return "PARISC_UNWIND";
-+    case SHT_PARISC_DOC:
-+      return "PARISC_DOC";
-+    }
-+
-+  return NULL;
-+}
-+
-+/* Check whether machine flags are valid.  */
-+bool
-+parisc_machine_flag_check (GElf_Word flags)
-+{
-+  if (flags &~ (EF_PARISC_TRAPNIL | EF_PARISC_EXT | EF_PARISC_LSB |
-+	EF_PARISC_WIDE | EF_PARISC_NO_KABP |
-+	EF_PARISC_LAZYSWAP | EF_PARISC_ARCH))
-+    return 0;
-+
-+  GElf_Word arch = flags & EF_PARISC_ARCH;
-+
-+  return ((arch == EFA_PARISC_1_0) || (arch == EFA_PARISC_1_1) ||
-+      (arch == EFA_PARISC_2_0));
-+}
-+
-+/* Check for the simple reloc types.  */
-+Elf_Type
-+parisc_reloc_simple_type (Ebl *ebl __attribute__ ((unused)), int type)
-+{
-+  switch (type)
-+    {
-+    case R_PARISC_DIR64:
-+    case R_PARISC_SECREL64:
-+      return ELF_T_XWORD;
-+    case R_PARISC_DIR32:
-+    case R_PARISC_SECREL32:
-+      return ELF_T_WORD;
-+    default:
-+      return ELF_T_NUM;
-+    }
-+}
-Index: elfutils-0.170/backends/libebl_parisc.h
-===================================================================
---- /dev/null
-+++ elfutils-0.170/backends/libebl_parisc.h
-@@ -0,0 +1,9 @@
-+#ifndef _LIBEBL_HPPA_H
-+#define _LIBEBL_HPPA_H 1
-+
-+#include <libdw.h>
-+
-+extern int parisc_return_value_location_32(Dwarf_Die *, const Dwarf_Op **locp);
-+extern int parisc_return_value_location_64(Dwarf_Die *, const Dwarf_Op **locp);
-+
-+#endif
-Index: elfutils-0.170/backends/Makefile.am
-===================================================================
---- elfutils-0.170.orig/backends/Makefile.am
-+++ elfutils-0.170/backends/Makefile.am
-@@ -33,12 +33,12 @@ AM_CPPFLAGS += -I$(top_srcdir)/libebl -I
- 
- 
- modules = i386 sh x86_64 ia64 alpha arm aarch64 sparc ppc ppc64 s390 \
--	  tilegx m68k bpf
-+	  tilegx m68k bpf parisc
- libebl_pic = libebl_i386_pic.a libebl_sh_pic.a libebl_x86_64_pic.a    \
- 	     libebl_ia64_pic.a libebl_alpha_pic.a libebl_arm_pic.a    \
- 	     libebl_aarch64_pic.a libebl_sparc_pic.a libebl_ppc_pic.a \
- 	     libebl_ppc64_pic.a libebl_s390_pic.a libebl_tilegx_pic.a \
--	     libebl_m68k_pic.a libebl_bpf_pic.a
-+	     libebl_m68k_pic.a libebl_bpf_pic.a libebl_parisc_pic.a
- noinst_LIBRARIES = $(libebl_pic)
- noinst_DATA = $(libebl_pic:_pic.a=.so)
- 
-@@ -124,6 +124,9 @@ cpu_bpf = ../libcpu/libcpu_bpf.a
- libebl_bpf_pic_a_SOURCES = $(bpf_SRCS)
- am_libebl_bpf_pic_a_OBJECTS = $(bpf_SRCS:.c=.os)
- 
-+parisc_SRCS = parisc_init.c parisc_symbol.c parisc_regs.c parisc_retval.c
-+libebl_parisc_pic_a_SOURCES = $(parisc_SRCS)
-+am_libebl_parisc_pic_a_OBJECTS = $(parisc_SRCS:.c=.os)
- 
- libebl_%.so libebl_%.map: libebl_%_pic.a $(libelf) $(libdw) $(libeu)
- 	@rm -f $(@:.so=.map)
-Index: elfutils-0.170/libelf/elf.h
-===================================================================
---- elfutils-0.170.orig/libelf/elf.h
-+++ elfutils-0.170/libelf/elf.h
-@@ -2056,16 +2056,24 @@ enum
- #define R_PARISC_PCREL17F	12	/* 17 bits of rel. address.  */
- #define R_PARISC_PCREL14R	14	/* Right 14 bits of rel. address.  */
- #define R_PARISC_DPREL21L	18	/* Left 21 bits of rel. address.  */
-+#define R_PARISC_DPREL14WR	19
-+#define R_PARISC_DPREL14DR	20
- #define R_PARISC_DPREL14R	22	/* Right 14 bits of rel. address.  */
- #define R_PARISC_GPREL21L	26	/* GP-relative, left 21 bits.  */
- #define R_PARISC_GPREL14R	30	/* GP-relative, right 14 bits.  */
- #define R_PARISC_LTOFF21L	34	/* LT-relative, left 21 bits.  */
- #define R_PARISC_LTOFF14R	38	/* LT-relative, right 14 bits.  */
-+#define R_PARISC_DLTIND14F	39
-+#define R_PARISC_SETBASE	40
- #define R_PARISC_SECREL32	41	/* 32 bits section rel. address.  */
-+#define R_PARISC_BASEREL21L	42
-+#define R_PARISC_BASEREL17R	43
-+#define R_PARISC_BASEREL14R	46
- #define R_PARISC_SEGBASE	48	/* No relocation, set segment base.  */
- #define R_PARISC_SEGREL32	49	/* 32 bits segment rel. address.  */
- #define R_PARISC_PLTOFF21L	50	/* PLT rel. address, left 21 bits.  */
- #define R_PARISC_PLTOFF14R	54	/* PLT rel. address, right 14 bits.  */
-+#define R_PARISC_PLTOFF14F	55
- #define R_PARISC_LTOFF_FPTR32	57	/* 32 bits LT-rel. function pointer. */
- #define R_PARISC_LTOFF_FPTR21L	58	/* LT-rel. fct ptr, left 21 bits. */
- #define R_PARISC_LTOFF_FPTR14R	62	/* LT-rel. fct ptr, right 14 bits. */
-@@ -2074,6 +2082,7 @@ enum
- #define R_PARISC_PLABEL21L	66	/* Left 21 bits of fdesc address.  */
- #define R_PARISC_PLABEL14R	70	/* Right 14 bits of fdesc address.  */
- #define R_PARISC_PCREL64	72	/* 64 bits PC-rel. address.  */
-+#define R_PARISC_PCREL22C	73
- #define R_PARISC_PCREL22F	74	/* 22 bits PC-rel. address.  */
- #define R_PARISC_PCREL14WR	75	/* PC-rel. address, right 14 bits.  */
- #define R_PARISC_PCREL14DR	76	/* PC rel. address, right 14 bits.  */
-@@ -2099,6 +2108,8 @@ enum
- #define R_PARISC_LTOFF16WF	102	/* 16 bits LT-rel. address.  */
- #define R_PARISC_LTOFF16DF	103	/* 16 bits LT-rel. address.  */
- #define R_PARISC_SECREL64	104	/* 64 bits section rel. address.  */
-+#define R_PARISC_BASEREL14WR	107
-+#define R_PARISC_BASEREL14DR	108
- #define R_PARISC_SEGREL64	112	/* 64 bits segment rel. address.  */
- #define R_PARISC_PLTOFF14WR	115	/* PLT-rel. address, right 14 bits.  */
- #define R_PARISC_PLTOFF14DR	116	/* PLT-rel. address, right 14 bits.  */
diff --git a/poky/meta/recipes-devtools/elfutils/files/debian/ignore_strmerge.diff b/poky/meta/recipes-devtools/elfutils/files/debian/ignore_strmerge.diff
new file mode 100644
index 0000000..55513ee
--- /dev/null
+++ b/poky/meta/recipes-devtools/elfutils/files/debian/ignore_strmerge.diff
@@ -0,0 +1,14 @@
+Upstream-Status: Pending [from debian]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+
+--- elfutils-0.165.orig/tests/run-strip-strmerge.sh
++++ elfutils-0.165/tests/run-strip-strmerge.sh
+@@ -30,7 +30,7 @@ remerged=remerged.elf
+ tempfiles $merged $stripped $debugfile $remerged
+ 
+ echo elflint $input
+-testrun ${abs_top_builddir}/src/elflint --gnu $input
++testrun_on_self_skip ${abs_top_builddir}/src/elflint --gnu $input
+ echo elfstrmerge
+ testrun ${abs_top_builddir}/tests/elfstrmerge -o $merged $input
+ echo elflint $merged
diff --git a/poky/meta/recipes-devtools/elfutils/files/debian/mips_backend.patch b/poky/meta/recipes-devtools/elfutils/files/debian/mips_backend.patch
deleted file mode 100644
index 2e0e54b..0000000
--- a/poky/meta/recipes-devtools/elfutils/files/debian/mips_backend.patch
+++ /dev/null
@@ -1,715 +0,0 @@
-From 46d0d0ca718093486eeeedf1b44134e9e29b56f7 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Wed, 16 Aug 2017 09:18:59 +0800
-Subject: [PATCH] mips backends
-
-Upstream-Status: Backport [from debian]
-
-Rebase to 0.170
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- backends/Makefile.am    |   8 +-
- backends/mips_init.c    |  59 +++++++++
- backends/mips_regs.c    | 104 ++++++++++++++++
- backends/mips_reloc.def |  79 ++++++++++++
- backends/mips_retval.c  | 321 ++++++++++++++++++++++++++++++++++++++++++++++++
- backends/mips_symbol.c  |  52 ++++++++
- libebl/eblopenbackend.c |   2 +
- 7 files changed, 623 insertions(+), 2 deletions(-)
- create mode 100644 backends/mips_init.c
- create mode 100644 backends/mips_regs.c
- create mode 100644 backends/mips_reloc.def
- create mode 100644 backends/mips_retval.c
- create mode 100644 backends/mips_symbol.c
-
-diff --git a/backends/Makefile.am b/backends/Makefile.am
-index 7f1f5d4..91baf6e 100644
---- a/backends/Makefile.am
-+++ b/backends/Makefile.am
-@@ -33,12 +33,12 @@ AM_CPPFLAGS += -I$(top_srcdir)/libebl -I$(top_srcdir)/libasm \
- 
- 
- modules = i386 sh x86_64 ia64 alpha arm aarch64 sparc ppc ppc64 s390 \
--	  tilegx m68k bpf parisc
-+	  tilegx m68k bpf parisc mips
- libebl_pic = libebl_i386_pic.a libebl_sh_pic.a libebl_x86_64_pic.a    \
- 	     libebl_ia64_pic.a libebl_alpha_pic.a libebl_arm_pic.a    \
- 	     libebl_aarch64_pic.a libebl_sparc_pic.a libebl_ppc_pic.a \
- 	     libebl_ppc64_pic.a libebl_s390_pic.a libebl_tilegx_pic.a \
--	     libebl_m68k_pic.a libebl_bpf_pic.a libebl_parisc_pic.a
-+	     libebl_m68k_pic.a libebl_bpf_pic.a libebl_parisc_pic.a libebl_mips_pic.a
- noinst_LIBRARIES = $(libebl_pic)
- noinst_DATA = $(libebl_pic:_pic.a=.so)
- 
-@@ -128,6 +128,10 @@ parisc_SRCS = parisc_init.c parisc_symbol.c parisc_regs.c parisc_retval.c
- libebl_parisc_pic_a_SOURCES = $(parisc_SRCS)
- am_libebl_parisc_pic_a_OBJECTS = $(parisc_SRCS:.c=.os)
- 
-+mips_SRCS = mips_init.c mips_symbol.c mips_regs.c mips_retval.c
-+libebl_mips_pic_a_SOURCES = $(mips_SRCS)
-+am_libebl_mips_pic_a_OBJECTS = $(mips_SRCS:.c=.os)
-+
- libebl_%.so libebl_%.map: libebl_%_pic.a $(libelf) $(libdw) $(libeu)
- 	@rm -f $(@:.so=.map)
- 	$(AM_V_at)echo 'ELFUTILS_$(PACKAGE_VERSION) { global: $*_init; local: *; };' \
-diff --git a/backends/mips_init.c b/backends/mips_init.c
-new file mode 100644
-index 0000000..975c04e
---- /dev/null
-+++ b/backends/mips_init.c
-@@ -0,0 +1,59 @@
-+/* Initialization of mips specific backend library.
-+   Copyright (C) 2006 Red Hat, Inc.
-+   This file is part of Red Hat elfutils.
-+
-+   Red Hat elfutils is free software; you can redistribute it and/or modify
-+   it under the terms of the GNU General Public License as published by the
-+   Free Software Foundation; version 2 of the License.
-+
-+   Red Hat elfutils is distributed in the hope that it will be useful, but
-+   WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   General Public License for more details.
-+
-+   You should have received a copy of the GNU General Public License along
-+   with Red Hat elfutils; if not, write to the Free Software Foundation,
-+   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
-+
-+   Red Hat elfutils is an included package of the Open Invention Network.
-+   An included package of the Open Invention Network is a package for which
-+   Open Invention Network licensees cross-license their patents.  No patent
-+   license is granted, either expressly or impliedly, by designation as an
-+   included package.  Should you wish to participate in the Open Invention
-+   Network licensing program, please visit www.openinventionnetwork.com
-+   <http://www.openinventionnetwork.com>.  */
-+
-+#ifdef HAVE_CONFIG_H
-+# include <config.h>
-+#endif
-+
-+#define BACKEND		mips_
-+#define RELOC_PREFIX	R_MIPS_
-+#include "libebl_CPU.h"
-+
-+/* This defines the common reloc hooks based on mips_reloc.def.  */
-+#include "common-reloc.c"
-+
-+const char *
-+mips_init (Elf *elf __attribute__ ((unused)),
-+     GElf_Half machine __attribute__ ((unused)),
-+     Ebl *eh,
-+     size_t ehlen)
-+{
-+  /* Check whether the Elf_BH object has a sufficent size.  */
-+  if (ehlen < sizeof (Ebl))
-+    return NULL;
-+
-+  /* We handle it.  */
-+  if (machine == EM_MIPS)
-+    eh->name = "MIPS R3000 big-endian";
-+  else if (machine == EM_MIPS_RS3_LE)
-+    eh->name = "MIPS R3000 little-endian";
-+
-+  mips_init_reloc (eh);
-+  HOOK (eh, reloc_simple_type);
-+  HOOK (eh, return_value_location);
-+  HOOK (eh, register_info);
-+
-+  return MODVERSION;
-+}
-diff --git a/backends/mips_regs.c b/backends/mips_regs.c
-new file mode 100644
-index 0000000..44f86cb
---- /dev/null
-+++ b/backends/mips_regs.c
-@@ -0,0 +1,104 @@
-+/* Register names and numbers for MIPS DWARF.
-+   Copyright (C) 2006 Red Hat, Inc.
-+   This file is part of Red Hat elfutils.
-+
-+   Red Hat elfutils is free software; you can redistribute it and/or modify
-+   it under the terms of the GNU General Public License as published by the
-+   Free Software Foundation; version 2 of the License.
-+
-+   Red Hat elfutils is distributed in the hope that it will be useful, but
-+   WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   General Public License for more details.
-+
-+   You should have received a copy of the GNU General Public License along
-+   with Red Hat elfutils; if not, write to the Free Software Foundation,
-+   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
-+
-+   Red Hat elfutils is an included package of the Open Invention Network.
-+   An included package of the Open Invention Network is a package for which
-+   Open Invention Network licensees cross-license their patents.  No patent
-+   license is granted, either expressly or impliedly, by designation as an
-+   included package.  Should you wish to participate in the Open Invention
-+   Network licensing program, please visit www.openinventionnetwork.com
-+   <http://www.openinventionnetwork.com>.  */
-+
-+#ifdef HAVE_CONFIG_H
-+# include <config.h>
-+#endif
-+
-+#include <string.h>
-+#include <dwarf.h>
-+
-+#define BACKEND mips_
-+#include "libebl_CPU.h"
-+
-+ssize_t
-+mips_register_info (Ebl *ebl __attribute__((unused)),
-+		    int regno, char *name, size_t namelen,
-+		    const char **prefix, const char **setname,
-+		    int *bits, int *type)
-+{
-+  if (name == NULL)
-+    return 66;
-+
-+  if (regno < 0 || regno > 65 || namelen < 4)
-+    return -1;
-+
-+  *prefix = "$";
-+
-+  if (regno < 32)
-+    {
-+      *setname = "integer";
-+      *type = DW_ATE_signed;
-+      *bits = 32;
-+      if (regno < 32 + 10)
-+        {
-+          name[0] = regno + '0';
-+          namelen = 1;
-+        }
-+      else
-+        {
-+          name[0] = (regno / 10) + '0';
-+          name[1] = (regno % 10) + '0';
-+          namelen = 2;
-+        }
-+    }
-+  else if (regno < 64)
-+    {
-+      *setname = "FPU";
-+      *type = DW_ATE_float;
-+      *bits = 32;
-+      name[0] = 'f';
-+      if (regno < 32 + 10)
-+	{
-+	  name[1] = (regno - 32) + '0';
-+	  namelen = 2;
-+	}
-+      else
-+	{
-+	  name[1] = (regno - 32) / 10 + '0';
-+	  name[2] = (regno - 32) % 10 + '0';
-+	  namelen = 3;
-+	}
-+    }
-+  else if (regno == 64)
-+    {
-+      *type = DW_ATE_signed;
-+      *bits = 32;
-+      name[0] = 'h';
-+      name[1] = 'i';
-+      namelen = 2;
-+    }
-+  else
-+    {
-+      *type = DW_ATE_signed;
-+      *bits = 32;
-+      name[0] = 'l';
-+      name[1] = 'o';
-+      namelen = 2;
-+    }
-+
-+  name[namelen++] = '\0';
-+  return namelen;
-+}
-diff --git a/backends/mips_reloc.def b/backends/mips_reloc.def
-new file mode 100644
-index 0000000..4579970
---- /dev/null
-+++ b/backends/mips_reloc.def
-@@ -0,0 +1,79 @@
-+/* List the relocation types for mips.  -*- C -*-
-+   Copyright (C) 2006 Red Hat, Inc.
-+   This file is part of Red Hat elfutils.
-+
-+   Red Hat elfutils is free software; you can redistribute it and/or modify
-+   it under the terms of the GNU General Public License as published by the
-+   Free Software Foundation; version 2 of the License.
-+
-+   Red Hat elfutils is distributed in the hope that it will be useful, but
-+   WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   General Public License for more details.
-+
-+   You should have received a copy of the GNU General Public License along
-+   with Red Hat elfutils; if not, write to the Free Software Foundation,
-+   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
-+
-+   Red Hat elfutils is an included package of the Open Invention Network.
-+   An included package of the Open Invention Network is a package for which
-+   Open Invention Network licensees cross-license their patents.  No patent
-+   license is granted, either expressly or impliedly, by designation as an
-+   included package.  Should you wish to participate in the Open Invention
-+   Network licensing program, please visit www.openinventionnetwork.com
-+   <http://www.openinventionnetwork.com>.  */
-+
-+/* 	    NAME,		REL|EXEC|DYN	*/
-+
-+RELOC_TYPE (NONE,               0)
-+RELOC_TYPE (16,                 0)
-+RELOC_TYPE (32,                 0)
-+RELOC_TYPE (REL32,              0)
-+RELOC_TYPE (26,                 0)
-+RELOC_TYPE (HI16,               0)
-+RELOC_TYPE (LO16,               0)
-+RELOC_TYPE (GPREL16,            0)
-+RELOC_TYPE (LITERAL,            0)
-+RELOC_TYPE (GOT16,              0)
-+RELOC_TYPE (PC16,               0)
-+RELOC_TYPE (CALL16,             0)
-+RELOC_TYPE (GPREL32,            0)
-+
-+RELOC_TYPE (SHIFT5,             0)
-+RELOC_TYPE (SHIFT6,             0)
-+RELOC_TYPE (64,                 0)
-+RELOC_TYPE (GOT_DISP,           0)
-+RELOC_TYPE (GOT_PAGE,           0)
-+RELOC_TYPE (GOT_OFST,           0)
-+RELOC_TYPE (GOT_HI16,           0)
-+RELOC_TYPE (GOT_LO16,           0)
-+RELOC_TYPE (SUB,                0)
-+RELOC_TYPE (INSERT_A,           0)
-+RELOC_TYPE (INSERT_B,           0)
-+RELOC_TYPE (DELETE,             0)
-+RELOC_TYPE (HIGHER,             0)
-+RELOC_TYPE (HIGHEST,            0)
-+RELOC_TYPE (CALL_HI16,          0)
-+RELOC_TYPE (CALL_LO16,          0)
-+RELOC_TYPE (SCN_DISP,           0)
-+RELOC_TYPE (REL16,              0)
-+RELOC_TYPE (ADD_IMMEDIATE,      0)
-+RELOC_TYPE (PJUMP,              0)
-+RELOC_TYPE (RELGOT,             0)
-+RELOC_TYPE (JALR,               0)
-+RELOC_TYPE (TLS_DTPMOD32,       0)
-+RELOC_TYPE (TLS_DTPREL32,       0)
-+RELOC_TYPE (TLS_DTPMOD64,       0)
-+RELOC_TYPE (TLS_DTPREL64,       0)
-+RELOC_TYPE (TLS_GD,             0)
-+RELOC_TYPE (TLS_LDM,            0)
-+RELOC_TYPE (TLS_DTPREL_HI16,    0)
-+RELOC_TYPE (TLS_DTPREL_LO16,    0)
-+RELOC_TYPE (TLS_GOTTPREL,       0)
-+RELOC_TYPE (TLS_TPREL32,        0)
-+RELOC_TYPE (TLS_TPREL64,        0)
-+RELOC_TYPE (TLS_TPREL_HI16,     0)
-+RELOC_TYPE (TLS_TPREL_LO16,     0)
-+
-+#define NO_COPY_RELOC 1
-+#define NO_RELATIVE_RELOC 1
-diff --git a/backends/mips_retval.c b/backends/mips_retval.c
-new file mode 100644
-index 0000000..656cd1f
---- /dev/null
-+++ b/backends/mips_retval.c
-@@ -0,0 +1,321 @@
-+/* Function return value location for Linux/mips ABI.
-+   Copyright (C) 2005 Red Hat, Inc.
-+   This file is part of Red Hat elfutils.
-+
-+   Red Hat elfutils is free software; you can redistribute it and/or modify
-+   it under the terms of the GNU General Public License as published by the
-+   Free Software Foundation; version 2 of the License.
-+
-+   Red Hat elfutils is distributed in the hope that it will be useful, but
-+   WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   General Public License for more details.
-+
-+   You should have received a copy of the GNU General Public License along
-+   with Red Hat elfutils; if not, write to the Free Software Foundation,
-+   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
-+
-+   Red Hat elfutils is an included package of the Open Invention Network.
-+   An included package of the Open Invention Network is a package for which
-+   Open Invention Network licensees cross-license their patents.  No patent
-+   license is granted, either expressly or impliedly, by designation as an
-+   included package.  Should you wish to participate in the Open Invention
-+   Network licensing program, please visit www.openinventionnetwork.com
-+   <http://www.openinventionnetwork.com>.  */
-+
-+#ifdef HAVE_CONFIG_H
-+# include <config.h>
-+#endif
-+
-+#include <string.h>
-+#include <assert.h>
-+#include <dwarf.h>
-+#include <elf.h>
-+
-+#include "../libebl/libeblP.h"
-+#include "../libdw/libdwP.h"
-+
-+#define BACKEND mips_
-+#include "libebl_CPU.h"
-+
-+/* The ABI of the file.  Also see EF_MIPS_ABI2 above. */
-+#define EF_MIPS_ABI		0x0000F000
-+
-+/* The original o32 abi. */
-+#define E_MIPS_ABI_O32          0x00001000
-+
-+/* O32 extended to work on 64 bit architectures */
-+#define E_MIPS_ABI_O64          0x00002000
-+
-+/* EABI in 32 bit mode */
-+#define E_MIPS_ABI_EABI32       0x00003000
-+
-+/* EABI in 64 bit mode */
-+#define E_MIPS_ABI_EABI64       0x00004000
-+
-+/* All the possible MIPS ABIs. */
-+enum mips_abi
-+  {
-+    MIPS_ABI_UNKNOWN = 0,
-+    MIPS_ABI_N32,
-+    MIPS_ABI_O32,
-+    MIPS_ABI_N64,
-+    MIPS_ABI_O64,
-+    MIPS_ABI_EABI32,
-+    MIPS_ABI_EABI64,
-+    MIPS_ABI_LAST
-+  };
-+
-+/* Find the mips ABI of the current file */
-+enum mips_abi find_mips_abi(Elf *elf)
-+{
-+  GElf_Ehdr ehdr_mem;
-+  GElf_Ehdr *ehdr = gelf_getehdr (elf, &ehdr_mem);
-+
-+  if (ehdr == NULL)
-+    return MIPS_ABI_LAST;
-+
-+  GElf_Word elf_flags = ehdr->e_flags;
-+
-+  /* Check elf_flags to see if it specifies the ABI being used.  */
-+  switch ((elf_flags & EF_MIPS_ABI))
-+    {
-+    case E_MIPS_ABI_O32:
-+      return MIPS_ABI_O32;
-+    case E_MIPS_ABI_O64:
-+      return MIPS_ABI_O64;
-+    case E_MIPS_ABI_EABI32:
-+      return MIPS_ABI_EABI32;
-+    case E_MIPS_ABI_EABI64:
-+      return MIPS_ABI_EABI64;
-+    default:
-+      if ((elf_flags & EF_MIPS_ABI2))
-+	return MIPS_ABI_N32;
-+    }
-+
-+  /* GCC creates a pseudo-section whose name describes the ABI.  */
-+  size_t shstrndx;
-+  if (elf_getshdrstrndx (elf, &shstrndx) < 0)
-+    return MIPS_ABI_LAST;
-+
-+  const char *name;
-+  Elf_Scn *scn = NULL;
-+  while ((scn = elf_nextscn (elf, scn)) != NULL)
-+    {
-+      GElf_Shdr shdr_mem;
-+      GElf_Shdr *shdr = gelf_getshdr (scn, &shdr_mem);
-+      if (shdr == NULL)
-+        return MIPS_ABI_LAST;
-+
-+      name = elf_strptr (elf, shstrndx, shdr->sh_name) ?: "";
-+      if (strncmp (name, ".mdebug.", 8) != 0)
-+        continue;
-+
-+      if (strcmp (name, ".mdebug.abi32") == 0)
-+        return MIPS_ABI_O32;
-+      else if (strcmp (name, ".mdebug.abiN32") == 0)
-+        return MIPS_ABI_N32;
-+      else if (strcmp (name, ".mdebug.abi64") == 0)
-+        return MIPS_ABI_N64;
-+      else if (strcmp (name, ".mdebug.abiO64") == 0)
-+        return MIPS_ABI_O64;
-+      else if (strcmp (name, ".mdebug.eabi32") == 0)
-+        return MIPS_ABI_EABI32;
-+      else if (strcmp (name, ".mdebug.eabi64") == 0)
-+        return MIPS_ABI_EABI64;
-+      else
-+        return MIPS_ABI_UNKNOWN;
-+    }
-+
-+  return MIPS_ABI_UNKNOWN;
-+}
-+
-+unsigned int
-+mips_abi_regsize (enum mips_abi abi)
-+{
-+  switch (abi)
-+    {
-+    case MIPS_ABI_EABI32:
-+    case MIPS_ABI_O32:
-+      return 4;
-+    case MIPS_ABI_N32:
-+    case MIPS_ABI_N64:
-+    case MIPS_ABI_O64:
-+    case MIPS_ABI_EABI64:
-+      return 8;
-+    case MIPS_ABI_UNKNOWN:
-+    case MIPS_ABI_LAST:
-+    default:
-+      return 0;
-+    }
-+}
-+
-+
-+/* $v0 or pair $v0, $v1 */
-+static const Dwarf_Op loc_intreg_o32[] =
-+  {
-+    { .atom = DW_OP_reg2 }, { .atom = DW_OP_piece, .number = 4 },
-+    { .atom = DW_OP_reg3 }, { .atom = DW_OP_piece, .number = 4 },
-+  };
-+
-+static const Dwarf_Op loc_intreg[] =
-+  {
-+    { .atom = DW_OP_reg2 }, { .atom = DW_OP_piece, .number = 8 },
-+    { .atom = DW_OP_reg3 }, { .atom = DW_OP_piece, .number = 8 },
-+  };
-+#define nloc_intreg	1
-+#define nloc_intregpair	4
-+
-+/* $f0 (float), or pair $f0, $f1 (double).
-+ * f2/f3 are used for COMPLEX (= 2 doubles) returns in Fortran */
-+static const Dwarf_Op loc_fpreg_o32[] =
-+  {
-+    { .atom = DW_OP_regx, .number = 32 }, { .atom = DW_OP_piece, .number = 4 },
-+    { .atom = DW_OP_regx, .number = 33 }, { .atom = DW_OP_piece, .number = 4 },
-+    { .atom = DW_OP_regx, .number = 34 }, { .atom = DW_OP_piece, .number = 4 },
-+    { .atom = DW_OP_regx, .number = 35 }, { .atom = DW_OP_piece, .number = 4 },
-+  };
-+
-+/* $f0, or pair $f0, $f2.  */
-+static const Dwarf_Op loc_fpreg[] =
-+  {
-+    { .atom = DW_OP_regx, .number = 32 }, { .atom = DW_OP_piece, .number = 8 },
-+    { .atom = DW_OP_regx, .number = 34 }, { .atom = DW_OP_piece, .number = 8 },
-+  };
-+#define nloc_fpreg  1
-+#define nloc_fpregpair 4
-+#define nloc_fpregquad 8
-+
-+/* The return value is a structure and is actually stored in stack space
-+   passed in a hidden argument by the caller.  But, the compiler
-+   helpfully returns the address of that space in $v0.  */
-+static const Dwarf_Op loc_aggregate[] =
-+  {
-+    { .atom = DW_OP_breg2, .number = 0 }
-+  };
-+#define nloc_aggregate 1
-+
-+int
-+mips_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
-+{
-+  /* First find the ABI used by the elf object */
-+  enum mips_abi abi = find_mips_abi(functypedie->cu->dbg->elf);
-+
-+  /* Something went seriously wrong while trying to figure out the ABI */
-+  if (abi == MIPS_ABI_LAST)
-+    return -1;
-+
-+  /* We couldn't identify the ABI, but the file seems valid */
-+  if (abi == MIPS_ABI_UNKNOWN)
-+    return -2;
-+
-+  /* Can't handle EABI variants */
-+  if ((abi == MIPS_ABI_EABI32) || (abi == MIPS_ABI_EABI64))
-+    return -2;
-+
-+  unsigned int regsize = mips_abi_regsize (abi);
-+  if (!regsize)
-+    return -2;
-+
-+  /* Start with the function's type, and get the DW_AT_type attribute,
-+     which is the type of the return value.  */
-+
-+  Dwarf_Attribute attr_mem;
-+  Dwarf_Attribute *attr = dwarf_attr_integrate (functypedie, DW_AT_type, &attr_mem);
-+  if (attr == NULL)
-+    /* The function has no return value, like a `void' function in C.  */
-+    return 0;
-+
-+  Dwarf_Die die_mem;
-+  Dwarf_Die *typedie = dwarf_formref_die (attr, &die_mem);
-+  int tag = dwarf_tag (typedie);
-+
-+  /* Follow typedefs and qualifiers to get to the actual type.  */
-+  while (tag == DW_TAG_typedef
-+	 || tag == DW_TAG_const_type || tag == DW_TAG_volatile_type
-+	 || tag == DW_TAG_restrict_type)
-+    {
-+      attr = dwarf_attr_integrate (typedie, DW_AT_type, &attr_mem);
-+      typedie = dwarf_formref_die (attr, &die_mem);
-+      tag = dwarf_tag (typedie);
-+    }
-+
-+  switch (tag)
-+    {
-+    case -1:
-+      return -1;
-+
-+    case DW_TAG_subrange_type:
-+      if (! dwarf_hasattr_integrate (typedie, DW_AT_byte_size))
-+	{
-+	  attr = dwarf_attr_integrate (typedie, DW_AT_type, &attr_mem);
-+	  typedie = dwarf_formref_die (attr, &die_mem);
-+	  tag = dwarf_tag (typedie);
-+	}
-+      /* Fall through.  */
-+
-+    case DW_TAG_base_type:
-+    case DW_TAG_enumeration_type:
-+    case DW_TAG_pointer_type:
-+    case DW_TAG_ptr_to_member_type:
-+      {
-+        Dwarf_Word size;
-+	if (dwarf_formudata (dwarf_attr_integrate (typedie, DW_AT_byte_size,
-+					 &attr_mem), &size) != 0)
-+	  {
-+	    if (tag == DW_TAG_pointer_type || tag == DW_TAG_ptr_to_member_type)
-+	      size = regsize;
-+	    else
-+	      return -1;
-+	  }
-+	if (tag == DW_TAG_base_type)
-+	  {
-+	    Dwarf_Word encoding;
-+	    if (dwarf_formudata (dwarf_attr_integrate (typedie, DW_AT_encoding,
-+					     &attr_mem), &encoding) != 0)
-+	      return -1;
-+
-+#define ABI_LOC(loc, regsize) ((regsize) == 4 ? (loc ## _o32) : (loc))
-+
-+	    if (encoding == DW_ATE_float)
-+	      {
-+		*locp = ABI_LOC(loc_fpreg, regsize);
-+		if (size <= regsize)
-+		    return nloc_fpreg;
-+
-+		if (size <= 2*regsize)
-+                  return nloc_fpregpair;
-+
-+		if (size <= 4*regsize && abi == MIPS_ABI_O32)
-+                  return nloc_fpregquad;
-+
-+		goto aggregate;
-+	      }
-+	  }
-+	*locp = ABI_LOC(loc_intreg, regsize);
-+	if (size <= regsize)
-+	  return nloc_intreg;
-+	if (size <= 2*regsize)
-+	  return nloc_intregpair;
-+
-+	/* Else fall through. Shouldn't happen though (at least with gcc) */
-+      }
-+
-+    case DW_TAG_structure_type:
-+    case DW_TAG_class_type:
-+    case DW_TAG_union_type:
-+    case DW_TAG_array_type:
-+    aggregate:
-+      /* XXX TODO: Can't handle structure return with other ABI's yet :-/ */
-+      if ((abi != MIPS_ABI_O32) && (abi != MIPS_ABI_O64))
-+        return -2;
-+
-+      *locp = loc_aggregate;
-+      return nloc_aggregate;
-+    }
-+
-+  /* XXX We don't have a good way to return specific errors from ebl calls.
-+     This value means we do not understand the type, but it is well-formed
-+     DWARF and might be valid.  */
-+  return -2;
-+}
-diff --git a/backends/mips_symbol.c b/backends/mips_symbol.c
-new file mode 100644
-index 0000000..ba465fe
---- /dev/null
-+++ b/backends/mips_symbol.c
-@@ -0,0 +1,52 @@
-+/* MIPS specific symbolic name handling.
-+   Copyright (C) 2002, 2003, 2005 Red Hat, Inc.
-+   This file is part of Red Hat elfutils.
-+   Written by Jakub Jelinek <jakub@redhat.com>, 2002.
-+
-+   Red Hat elfutils is free software; you can redistribute it and/or modify
-+   it under the terms of the GNU General Public License as published by the
-+   Free Software Foundation; version 2 of the License.
-+
-+   Red Hat elfutils is distributed in the hope that it will be useful, but
-+   WITHOUT ANY WARRANTY; without even the implied warranty of
-+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-+   General Public License for more details.
-+
-+   You should have received a copy of the GNU General Public License along
-+   with Red Hat elfutils; if not, write to the Free Software Foundation,
-+   Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA.
-+
-+   Red Hat elfutils is an included package of the Open Invention Network.
-+   An included package of the Open Invention Network is a package for which
-+   Open Invention Network licensees cross-license their patents.  No patent
-+   license is granted, either expressly or impliedly, by designation as an
-+   included package.  Should you wish to participate in the Open Invention
-+   Network licensing program, please visit www.openinventionnetwork.com
-+   <http://www.openinventionnetwork.com>.  */
-+
-+#ifdef HAVE_CONFIG_H
-+# include <config.h>
-+#endif
-+
-+#include <elf.h>
-+#include <stddef.h>
-+
-+#define BACKEND		mips_
-+#include "libebl_CPU.h"
-+
-+/* Check for the simple reloc types.  */
-+Elf_Type
-+mips_reloc_simple_type (Ebl *ebl __attribute__ ((unused)), int type)
-+{
-+  switch (type)
-+    {
-+    case R_MIPS_16:
-+      return ELF_T_HALF;
-+    case R_MIPS_32:
-+      return ELF_T_WORD;
-+    case R_MIPS_64:
-+      return ELF_T_XWORD;
-+    default:
-+      return ELF_T_NUM;
-+    }
-+}
-diff --git a/libebl/eblopenbackend.c b/libebl/eblopenbackend.c
-index 1f81477..5371396 100644
---- a/libebl/eblopenbackend.c
-+++ b/libebl/eblopenbackend.c
-@@ -72,6 +72,8 @@ static const struct
-   { "sparc", "elf_sparc", "sparc", 5, EM_SPARC, 0, 0 },
-   { "sparc", "elf_sparcv8plus", "sparc", 5, EM_SPARC32PLUS, 0, 0 },
-   { "s390", "ebl_s390", "s390", 4, EM_S390, 0, 0 },
-+  { "mips", "elf_mips", "mips", 4, EM_MIPS, 0, 0 },
-+  { "mips", "elf_mipsel", "mipsel", 4, EM_MIPS_RS3_LE, 0, 0 },
- 
-   { "m32", "elf_m32", "m32", 3, EM_M32, 0, 0 },
-   { "m68k", "elf_m68k", "m68k", 4, EM_68K, ELFCLASS32, ELFDATA2MSB },
--- 
-1.8.3.1
-
diff --git a/poky/meta/recipes-devtools/elfutils/files/debian/mips_readelf_w.patch b/poky/meta/recipes-devtools/elfutils/files/debian/mips_readelf_w.patch
deleted file mode 100644
index 790930c..0000000
--- a/poky/meta/recipes-devtools/elfutils/files/debian/mips_readelf_w.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From: Kurt Roeckx <kurt@roeckx.be>
-Subject: Make readelf -w output debug information on mips
-Bug-Debian: http://bugs.debian.org/662041
-Forwarded: not-needed
-
-Upstreams wants a change where this is handled by a hook that needs
-to be filled in by the backend for the arch.
-
-Upstream-Status: Backport [from debian]
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
-
-Index: b/src/readelf.c
-===================================================================
---- a/src/readelf.c
-+++ b/src/readelf.c
-@@ -8343,7 +8343,8 @@ print_debug (Dwfl_Module *dwflmod, Ebl *
-       GElf_Shdr shdr_mem;
-       GElf_Shdr *shdr = gelf_getshdr (scn, &shdr_mem);
- 
--      if (shdr != NULL && shdr->sh_type == SHT_PROGBITS)
-+      if (shdr != NULL && (
-+	 (shdr->sh_type == SHT_PROGBITS) || (shdr->sh_type == SHT_MIPS_DWARF)))
- 	{
- 	  static const struct
- 	  {
diff --git a/poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.3.bb b/poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.3.bb
deleted file mode 100644
index 4d617e3..0000000
--- a/poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.3.bb
+++ /dev/null
@@ -1,26 +0,0 @@
-SUMMARY = "Utility for modifying GPT disk partitioning"
-DESCRIPTION = "GPT fdisk is a disk partitioning tool loosely modeled on Linux fdisk, but used for modifying GUID Partition Table (GPT) disks. The related FixParts utility fixes some common problems on Master Boot Record (MBR) disks."
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552"
-
-DEPENDS = "util-linux popt ncurses"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${PV}/${BP}.tar.gz"
-SRC_URI[md5sum] = "07b625a583b66c8c5840be5923f3e3fe"
-SRC_URI[sha256sum] = "89fd5aec35c409d610a36cb49c65b442058565ed84042f767bba614b8fc91b5c"
-
-UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/gptfdisk/files/gptfdisk/"
-UPSTREAM_CHECK_REGEX = "/gptfdisk/(?P<pver>(\d+[\.\-_]*)+)/"
-
-EXTRA_OEMAKE = "'CC=${CC}' 'CXX=${CXX}'"
-
-do_install() {
-    install -d ${D}${sbindir}
-    install -m 0755 cgdisk ${D}${sbindir}
-    install -m 0755 gdisk ${D}${sbindir}
-    install -m 0755 sgdisk ${D}${sbindir}
-    install -m 0755 fixparts ${D}${sbindir}
-}
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.4.bb b/poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.4.bb
new file mode 100644
index 0000000..b043c96
--- /dev/null
+++ b/poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.4.bb
@@ -0,0 +1,33 @@
+SUMMARY = "Utility for modifying GPT disk partitioning"
+DESCRIPTION = "GPT fdisk is a disk partitioning tool loosely modeled on Linux fdisk, but used for modifying GUID Partition Table (GPT) disks. The related FixParts utility fixes some common problems on Master Boot Record (MBR) disks."
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552"
+
+DEPENDS = "util-linux"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${PV}/${BP}.tar.gz"
+SRC_URI[md5sum] = "5ecc3c44913bb6b53d3708d1ac7ac295"
+SRC_URI[sha256sum] = "b663391a6876f19a3cd901d862423a16e2b5ceaa2f4a3b9bb681e64b9c7ba78d"
+
+UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/gptfdisk/files/gptfdisk/"
+UPSTREAM_CHECK_REGEX = "/gptfdisk/(?P<pver>(\d+[\.\-_]*)+)/"
+
+EXTRA_OEMAKE = "'CC=${CC}' 'CXX=${CXX}' gdisk fixparts ${PACKAGECONFIG_CONFARGS}"
+
+PACKAGECONFIG ??= "ncurses popt"
+PACKAGECONFIG[ncurses] = "cgdisk,,ncurses"
+PACKAGECONFIG[popt] = "sgdisk,,popt"
+
+do_install() {
+    install -d ${D}${sbindir}
+    for f in cgdisk sgdisk; do
+        if [ -x $f ]; then
+            install -m 0755 $f ${D}${sbindir}
+        fi
+    done
+    install -m 0755 gdisk ${D}${sbindir}
+    install -m 0755 fixparts ${D}${sbindir}
+}
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-devtools/file/file/0001-Add-P-prompt-into-Usage-info.patch b/poky/meta/recipes-devtools/file/file/0001-Add-P-prompt-into-Usage-info.patch
deleted file mode 100644
index 8a16b2c..0000000
--- a/poky/meta/recipes-devtools/file/file/0001-Add-P-prompt-into-Usage-info.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From 08abf944b2bff27b6dd325dd15b4861cebef113a Mon Sep 17 00:00:00 2001
-From: Junling Zheng <zhengjunling@huawei.com>
-Date: Wed, 8 Apr 2015 03:26:57 +0000
-Subject: [PATCH] Add -P prompt into Usage info
-
-Currently, Usage info doesn't include -P prompt, add it:
-
-root@arma9el:~# file
-Usage: file [-bcEhikLlNnprsvz0] [--apple] [--mime-encoding] [--mime-type]
-            [-e testname] [-F separator] [-f namefile] [-m magicfiles]
-            [-P parameter=limits] file ...
-       file -C [-m magicfiles]
-       file [--help]
-
-Upstream-Status: Submitted
-
-Signed-off-by: Junling Zheng <zhengjunling@huawei.com>
----
- src/file.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/file.c b/src/file.c
-index 2b15e21..e5a957b 100644
---- a/src/file.c
-+++ b/src/file.c
-@@ -76,8 +76,8 @@ int getopt_long(int argc, char * const *argv, const char *optstring, const struc
- # define USAGE  \
-     "Usage: %s [" FILE_FLAGS \
- 	"] [--apple] [--extension] [--mime-encoding] [--mime-type]\n" \
--    "            [-e testname] [-F separator] [-f namefile] [-m magicfiles] " \
--    "file ...\n" \
-+    "            [-e testname] [-F separator] [-f namefile] [-m magicfiles]\n " \
-+    "            [-P parameter=limits] file ...\n" \
-     "       %s -C [-m magicfiles]\n" \
-     "       %s [--help]\n"
- 
--- 
-1.8.3.4
-
diff --git a/poky/meta/recipes-devtools/file/file_5.32.bb b/poky/meta/recipes-devtools/file/file_5.32.bb
deleted file mode 100644
index 5e15925..0000000
--- a/poky/meta/recipes-devtools/file/file_5.32.bb
+++ /dev/null
@@ -1,48 +0,0 @@
-SUMMARY = "File classification tool"
-DESCRIPTION = "File attempts to classify files depending \
-on their contents and prints a description if a match is found."
-HOMEPAGE = "http://www.darwinsys.com/file/"
-SECTION = "console/utils"
-
-# two clause BSD
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;beginline=2;md5=6a7382872edb68d33e1a9398b6e03188"
-
-DEPENDS = "zlib file-replacement-native"
-DEPENDS_class-native = "zlib-native"
-
-# Blacklist a bogus tag in upstream check
-UPSTREAM_CHECK_GITTAGREGEX = "FILE(?P<pver>(?!6_23).+)"
-
-SRC_URI = "git://github.com/file/file.git \
-        file://debian-742262.patch \
-        file://0001-Add-P-prompt-into-Usage-info.patch \
-        "
-
-SRCREV = "d474e35513940dbca039b510b4de705b44f5bd9c"
-S = "${WORKDIR}/git"
-
-inherit autotools
-
-EXTRA_OEMAKE_append_class-target = "-e FILE_COMPILE=${STAGING_BINDIR_NATIVE}/file-native/file"
-EXTRA_OEMAKE_append_class-nativesdk = "-e FILE_COMPILE=${STAGING_BINDIR_NATIVE}/file-native/file"
-
-CFLAGS_append = " -std=c99"
-
-FILES_${PN} += "${datadir}/misc/*.mgc"
-
-do_install_append_class-native() {
-	create_cmdline_wrapper ${D}/${bindir}/file \
-		--magic-file ${datadir}/misc/magic.mgc
-}
-
-do_install_append_class-nativesdk() {
-	create_cmdline_wrapper ${D}/${bindir}/file \
-		--magic-file ${datadir}/misc/magic.mgc
-}
-
-BBCLASSEXTEND = "native nativesdk"
-PROVIDES_append_class-native = " file-replacement-native"
-# Don't use NATIVE_PACKAGE_PATH_SUFFIX as that hides libmagic from anyone who
-# depends on file-replacement-native.
-bindir_append_class-native = "/file-native"
diff --git a/poky/meta/recipes-devtools/file/file_5.34.bb b/poky/meta/recipes-devtools/file/file_5.34.bb
new file mode 100644
index 0000000..5d92913
--- /dev/null
+++ b/poky/meta/recipes-devtools/file/file_5.34.bb
@@ -0,0 +1,50 @@
+SUMMARY = "File classification tool"
+DESCRIPTION = "File attempts to classify files depending \
+on their contents and prints a description if a match is found."
+HOMEPAGE = "http://www.darwinsys.com/file/"
+SECTION = "console/utils"
+
+# two clause BSD
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;beginline=2;md5=6a7382872edb68d33e1a9398b6e03188"
+
+DEPENDS = "zlib file-replacement-native"
+DEPENDS_class-native = "zlib-native"
+
+# Blacklist a bogus tag in upstream check
+UPSTREAM_CHECK_GITTAGREGEX = "FILE(?P<pver>(?!6_23).+)"
+
+SRC_URI = "git://github.com/file/file.git \
+        file://debian-742262.patch \
+        "
+
+SRCREV = "315cef2f699da3c31a54bd3c6c6070680fbaf1f5"
+S = "${WORKDIR}/git"
+
+inherit autotools update-alternatives
+
+ALTERNATIVE_${PN} = "file"
+ALTERNATIVE_LINK_NAME[file] = "${bindir}/file"
+
+EXTRA_OEMAKE_append_class-target = "-e FILE_COMPILE=${STAGING_BINDIR_NATIVE}/file-native/file"
+EXTRA_OEMAKE_append_class-nativesdk = "-e FILE_COMPILE=${STAGING_BINDIR_NATIVE}/file-native/file"
+
+CFLAGS_append = " -std=c99"
+
+FILES_${PN} += "${datadir}/misc/*.mgc"
+
+do_install_append_class-native() {
+	create_cmdline_wrapper ${D}/${bindir}/file \
+		--magic-file ${datadir}/misc/magic.mgc
+}
+
+do_install_append_class-nativesdk() {
+	create_cmdline_wrapper ${D}/${bindir}/file \
+		--magic-file ${datadir}/misc/magic.mgc
+}
+
+BBCLASSEXTEND = "native nativesdk"
+PROVIDES_append_class-native = " file-replacement-native"
+# Don't use NATIVE_PACKAGE_PATH_SUFFIX as that hides libmagic from anyone who
+# depends on file-replacement-native.
+bindir_append_class-native = "/file-native"
diff --git a/poky/meta/recipes-devtools/gcc/gcc-7.3.inc b/poky/meta/recipes-devtools/gcc/gcc-7.3.inc
index d4aaca4..c7c88f1 100644
--- a/poky/meta/recipes-devtools/gcc/gcc-7.3.inc
+++ b/poky/meta/recipes-devtools/gcc/gcc-7.3.inc
@@ -32,7 +32,6 @@
 SRC_URI = "\
            ${BASEURI} \
            file://0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch \
-           file://0008-c99-snprintf.patch \
            file://0009-gcc-poison-system-directories.patch \
            file://0010-gcc-poison-dir-extend.patch \
            file://0011-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch \
@@ -72,6 +71,7 @@
            file://0045-Link-libgcc-using-LDFLAGS-not-just-SHLIB_LDFLAGS.patch \
            file://0047-sync-gcc-stddef.h-with-musl.patch \
            file://0048-gcc-Enable-static-PIE.patch \
+           file://0049-gcc-override-TARGET_LIBC_PROVIDES_SSP.patch \
            file://fix-segmentation-fault-precompiled-hdr.patch \
            file://no-sse-fix-test-case-failures.patch \
            ${BACKPORTS} \
@@ -95,10 +95,12 @@
 JAVA = ""
 
 LTO = "--enable-lto"
+SSP ?= "--disable-libssp"
+SSP_mingw32 = "--enable-libssp"
 
 EXTRA_OECONF_BASE = "\
     ${LTO} \
-    --enable-libssp \
+    ${SSP} \
     --enable-libitm \
     --disable-bootstrap \
     --disable-libmudflap \
@@ -120,9 +122,10 @@
     --with-system-zlib \
     --disable-lto \
     --disable-plugin \
+    --enable-linker-build-id \
     --enable-decimal-float=no \
     --without-isl \
-    gcc_cv_libc_provides_ssp=yes \
+    --disable-libssp \
 "
 
 EXTRA_OECONF_PATHS = "\
diff --git a/poky/meta/recipes-devtools/gcc/gcc-7.3/0008-c99-snprintf.patch b/poky/meta/recipes-devtools/gcc/gcc-7.3/0008-c99-snprintf.patch
deleted file mode 100644
index ebd562b..0000000
--- a/poky/meta/recipes-devtools/gcc/gcc-7.3/0008-c99-snprintf.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From 732f10eead61830a8aee1bf38cce892da25c35b1 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:49:03 +0400
-Subject: [PATCH 08/47] c99-snprintf
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- libstdc++-v3/include/c_std/cstdio | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/libstdc++-v3/include/c_std/cstdio b/libstdc++-v3/include/c_std/cstdio
-index 43969892aa2..12148457909 100644
---- a/libstdc++-v3/include/c_std/cstdio
-+++ b/libstdc++-v3/include/c_std/cstdio
-@@ -144,7 +144,7 @@ namespace std
-   using ::vsprintf;
- } // namespace std
- 
--#if _GLIBCXX_USE_C99_STDIO
-+#if _GLIBCXX_USE_C99_STDIO || defined(__UCLIBC__)
- 
- #undef snprintf
- #undef vfscanf
--- 
-2.12.2
-
diff --git a/poky/meta/recipes-devtools/gcc/gcc-7.3/0049-gcc-override-TARGET_LIBC_PROVIDES_SSP.patch b/poky/meta/recipes-devtools/gcc/gcc-7.3/0049-gcc-override-TARGET_LIBC_PROVIDES_SSP.patch
new file mode 100644
index 0000000..7c53c95
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-7.3/0049-gcc-override-TARGET_LIBC_PROVIDES_SSP.patch
@@ -0,0 +1,204 @@
+From 9815bd97561c778ee0bc0c17f245e88e66570111 Mon Sep 17 00:00:00 2001
+From: sandra <sandra@138bc75d-0d04-0410-961f-82ee72b054a4>
+Date: Wed, 1 Nov 2017 02:14:19 +0000
+Subject: [PATCH] 2017-10-31  Sandra Loosemore  <sandra@codesourcery.com>
+
+	gcc/
+	* configure.ac (--enable-libssp): New.
+	(gcc_cv_libc_provides_ssp): Check for explicit setting before
+	trying to determine target-specific default.  Adjust indentation.
+	* configure: Regenerated.
+	* doc/install.texi (Configuration): Expand --disable-libssp
+	documentation.
+
+
+git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@254288 138bc75d-0d04-0410-961f-82ee72b054a4
+---
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Backport [https://patchwork.ozlabs.org/patch/823049/]
+
+ gcc/ChangeLog        |  9 +++++++++
+ gcc/configure        | 26 +++++++++++++++++++++++---
+ gcc/configure.ac     | 24 ++++++++++++++++++++----
+ gcc/doc/install.texi |  3 ++-
+ 4 files changed, 54 insertions(+), 8 deletions(-)
+
+Index: gcc-7.3.0/gcc/configure.ac
+===================================================================
+--- gcc-7.3.0.orig/gcc/configure.ac
++++ gcc-7.3.0/gcc/configure.ac
+@@ -5719,10 +5719,25 @@ if test x$gcc_cv_solaris_crts = xyes; th
+   	    [Define if the system-provided CRTs are present on Solaris.])
+ fi
+ 
++AC_ARG_ENABLE(libssp,
++[AS_HELP_STRING([--enable-libssp], [enable linking against libssp])],
++[case "${enableval}" in
++  yes|no)
++    ;;
++  *)
++    AC_MSG_ERROR([unknown libssp setting $enableval])
++    ;;
++esac], [])
++
+ # Test for stack protector support in target C library.
+ AC_CACHE_CHECK(__stack_chk_fail in target C library,
+-      gcc_cv_libc_provides_ssp,
+-      [gcc_cv_libc_provides_ssp=no
++  gcc_cv_libc_provides_ssp,
++  [gcc_cv_libc_provides_ssp=no
++  if test "x$enable_libssp" = "xno"; then
++    gcc_cv_libc_provides_ssp=yes
++  elif test "x$enable_libssp" = "xyes"; then
++    gcc_cv_libc_provides_ssp=no
++  else
+     case "$target" in
+        *-*-musl*)
+ 	 # All versions of musl provide stack protector
+@@ -5759,8 +5774,9 @@ AC_CACHE_CHECK(__stack_chk_fail in targe
+ 	 AC_CHECK_FUNC(__stack_chk_fail,[gcc_cv_libc_provides_ssp=yes],
+            [echo "no __stack_chk_fail on this target"])
+         ;;
+-  *) gcc_cv_libc_provides_ssp=no ;;
+-    esac])
++       *) gcc_cv_libc_provides_ssp=no ;;
++    esac
++  fi])
+ 
+ if test x$gcc_cv_libc_provides_ssp = xyes; then
+   AC_DEFINE(TARGET_LIBC_PROVIDES_SSP, 1,
+Index: gcc-7.3.0/gcc/doc/install.texi
+===================================================================
+--- gcc-7.3.0.orig/gcc/doc/install.texi
++++ gcc-7.3.0/gcc/doc/install.texi
+@@ -1658,7 +1658,8 @@ not be built.
+ 
+ @item --disable-libssp
+ Specify that the run-time libraries for stack smashing protection
+-should not be built.
++should not be built or linked against.  On many targets library support
++is provided by the C library instead.
+ 
+ @item --disable-libquadmath
+ Specify that the GCC quad-precision math library should not be built.
+Index: gcc-7.3.0/gcc/configure
+===================================================================
+--- gcc-7.3.0.orig/gcc/configure
++++ gcc-7.3.0/gcc/configure
+@@ -940,6 +940,7 @@ enable_fix_cortex_a53_843419
+ with_glibc_version
+ enable_gnu_unique_object
+ enable_linker_build_id
++enable_libssp
+ enable_default_ssp
+ with_long_double_128
+ with_gc
+@@ -1679,6 +1680,7 @@ Optional Features:
+                           extension on glibc systems
+   --enable-linker-build-id
+                           compiler will always pass --build-id to linker
++  --enable-libssp         enable linking against libssp
+   --enable-default-ssp    enable Stack Smashing Protection as default
+   --enable-maintainer-mode
+                           enable make rules and dependencies not useful (and
+@@ -18450,7 +18452,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 18436 "configure"
++#line 18455 "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -18556,7 +18558,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 18542 "configure"
++#line 18561 "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -25234,6 +25236,7 @@ $as_echo "#define HAVE_AS_SPARC5_VIS4 1"
+ 
+ fi
+ 
++
+     { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for SPARC6 instructions" >&5
+ $as_echo_n "checking assembler for SPARC6 instructions... " >&6; }
+ if test "${gcc_cv_as_sparc_sparc6+set}" = set; then :
+@@ -25270,6 +25273,7 @@ $as_echo "#define HAVE_AS_SPARC6 1" >>co
+ 
+ fi
+ 
++
+     { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for LEON instructions" >&5
+ $as_echo_n "checking assembler for LEON instructions... " >&6; }
+ if test "${gcc_cv_as_sparc_leon+set}" = set; then :
+@@ -28947,6 +28951,18 @@ $as_echo "#define HAVE_SOLARIS_CRTS 1" >
+ 
+ fi
+ 
++# Check whether --enable-libssp was given.
++if test "${enable_libssp+set}" = set; then :
++  enableval=$enable_libssp; case "${enableval}" in
++  yes|no)
++    ;;
++  *)
++    as_fn_error "unknown libssp setting $enableval" "$LINENO" 5
++    ;;
++esac
++fi
++
++
+ # Test for stack protector support in target C library.
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking __stack_chk_fail in target C library" >&5
+ $as_echo_n "checking __stack_chk_fail in target C library... " >&6; }
+@@ -28954,6 +28970,11 @@ if test "${gcc_cv_libc_provides_ssp+set}
+   $as_echo_n "(cached) " >&6
+ else
+   gcc_cv_libc_provides_ssp=no
++  if test "x$enable_libssp" = "xno"; then
++    gcc_cv_libc_provides_ssp=yes
++  elif test "x$enable_libssp" = "xyes"; then
++    gcc_cv_libc_provides_ssp=no
++  else
+     case "$target" in
+        *-*-musl*)
+ 	 # All versions of musl provide stack protector
+@@ -29001,8 +29022,9 @@ else
+ fi
+ 
+         ;;
+-  *) gcc_cv_libc_provides_ssp=no ;;
++       *) gcc_cv_libc_provides_ssp=no ;;
+     esac
++  fi
+ fi
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_libc_provides_ssp" >&5
+ $as_echo "$gcc_cv_libc_provides_ssp" >&6; }
+@@ -29037,18 +29059,15 @@ fi
+ 
+ 
+ # Test for <sys/sdt.h> on the target.
+-
+-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking sys/sdt.h in the target C library" >&5
+-$as_echo_n "checking sys/sdt.h in the target C library... " >&6; }
+-have_sys_sdt_h=no
++#GCC_TARGET_TEMPLATE([HAVE_SYS_SDT_H])
++#AC_MSG_CHECKING(sys/sdt.h in the target C library)
++#have_sys_sdt_h=no
+ #if test -f $target_header_dir/sys/sdt.h; then
+ #  have_sys_sdt_h=yes
+-#
+-#$as_echo "#define HAVE_SYS_SDT_H 1" >>confdefs.h
+-#
++#  AC_DEFINE(HAVE_SYS_SDT_H, 1,
++#            [Define if your target C library provides sys/sdt.h])
+ #fi
+-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_sys_sdt_h" >&5
+-$as_echo "$have_sys_sdt_h" >&6; }
++#AC_MSG_RESULT($have_sys_sdt_h)
+ 
+ # Check if TFmode long double should be used by default or not.
+ # Some glibc targets used DFmode long double, but with glibc 2.4
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2.inc b/poky/meta/recipes-devtools/gcc/gcc-8.2.inc
new file mode 100644
index 0000000..866a775
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2.inc
@@ -0,0 +1,127 @@
+require gcc-common.inc
+
+# Third digit in PV should be incremented after a minor release
+
+PV = "8.2.0"
+
+# BINV should be incremented to a revision after a minor gcc release
+
+BINV = "8.2.0"
+
+FILESEXTRAPATHS =. "${FILE_DIRNAME}/gcc-8.2:${FILE_DIRNAME}/gcc-8.2/backport:"
+
+DEPENDS =+ "mpfr gmp libmpc zlib flex-native"
+NATIVEDEPS = "mpfr-native gmp-native libmpc-native zlib-native flex-native"
+
+LICENSE = "GPL-3.0-with-GCC-exception & GPLv3"
+
+LIC_FILES_CHKSUM = "\
+    file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
+    file://COPYING3;md5=d32239bcb673463ab874e80d47fae504 \
+    file://COPYING3.LIB;md5=6a6a8e020838b23406c81b19c1d46df6 \
+    file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1 \
+    file://COPYING.RUNTIME;md5=fe60d87048567d4fe8c8a0ed2448bcc8 \
+"
+
+#RELEASE = "8.0.1-RC-20180427"
+BASEURI ?= "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.xz"
+#SRCREV = "f7cf798b73fd1a07098f9a490deec1e2a36e0bed"
+#BASEURI ?= "git://github.com/gcc-mirror/gcc;branch=gcc-6-branch;protocol=git"
+#BASEURI ?= "http://mirrors.concertpass.com/gcc/snapshots/${RELEASE}/gcc-${RELEASE}.tar.xz"
+
+SRC_URI = "\
+           ${BASEURI} \
+           file://0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch \
+           file://0003-gcc-poison-system-directories.patch \
+           file://0005-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch \
+           file://0006-64-bit-multilib-hack.patch \
+           file://0007-optional-libstdc.patch \
+           file://0008-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch \
+           file://0009-COLLECT_GCC_OPTIONS.patch \
+           file://0010-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch \
+           file://0011-fortran-cross-compile-hack.patch \
+           file://0012-cpp-honor-sysroot.patch \
+           file://0013-MIPS64-Default-to-N64-ABI.patch \
+           file://0014-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch \
+           file://0015-gcc-Fix-argument-list-too-long-error.patch \
+           file://0016-Disable-sdt.patch \
+           file://0017-libtool.patch \
+           file://0018-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch \
+           file://0019-Use-the-multilib-config-files-from-B-instead-of-usin.patch \
+           file://0020-Avoid-using-libdir-from-.la-which-usually-points-to-.patch \
+           file://0021-export-CPP.patch \
+           file://0022-Disable-the-MULTILIB_OSDIRNAMES-and-other-multilib-o.patch \
+           file://0023-Ensure-target-gcc-headers-can-be-included.patch \
+           file://0024-gcc-4.8-won-t-build-with-disable-dependency-tracking.patch \
+           file://0025-Don-t-search-host-directory-during-relink-if-inst_pr.patch \
+           file://0026-Use-SYSTEMLIBS_DIR-replacement-instead-of-hardcoding.patch \
+           file://0027-aarch64-Add-support-for-musl-ldso.patch \
+           file://0028-libcc1-fix-libcc1-s-install-path-and-rpath.patch \
+           file://0029-handle-sysroot-support-for-nativesdk-gcc.patch \
+           file://0030-Search-target-sysroot-gcc-version-specific-dirs-with.patch \
+           file://0031-Fix-various-_FOR_BUILD-and-related-variables.patch \
+           file://0032-nios2-Define-MUSL_DYNAMIC_LINKER.patch \
+           file://0033-Add-ssp_nonshared-to-link-commandline-for-musl-targe.patch \
+           file://0034-libgcc-Add-knob-to-use-ldbl-128-on-ppc.patch \
+           file://0035-Link-libgcc-using-LDFLAGS-not-just-SHLIB_LDFLAGS.patch \
+           file://0036-libgcc_s-Use-alias-for-__cpu_indicator_init-instead-.patch \
+           file://0037-sync-gcc-stddef.h-with-musl.patch \
+           file://0038-fix-segmentation-fault-in-precompiled-header-generat.patch \
+           file://0039-Fix-for-testsuite-failure.patch \
+           file://0040-Re-introduce-spe-commandline-options.patch \
+           file://0041-ARC-fix-spec-gen.patch \
+           ${BACKPORTS} \
+"
+BACKPORTS = "\
+"
+SRC_URI[md5sum] = "4ab282f414676496483b3e1793d07862"
+SRC_URI[sha256sum] = "196c3c04ba2613f893283977e6011b2345d1cd1af9abeac58e916b1aab3e0080"
+
+S = "${TMPDIR}/work-shared/gcc-${PV}-${PR}/gcc-${PV}"
+#S = "${TMPDIR}/work-shared/gcc-${PV}-${PR}/git"
+#S = "${TMPDIR}/work-shared/gcc-${PV}-${PR}/gcc-${RELEASE}"
+B = "${WORKDIR}/gcc-${PV}/build.${HOST_SYS}.${TARGET_SYS}"
+
+# Language Overrides
+FORTRAN = ""
+JAVA = ""
+
+LTO = "--enable-lto"
+SSP ?= "--disable-libssp"
+SSP_mingw32 = "--enable-libssp"
+
+EXTRA_OECONF_BASE = "\
+    ${LTO} \
+    ${SSP} \
+    --enable-libitm \
+    --disable-bootstrap \
+    --disable-libmudflap \
+    --with-system-zlib \
+    ${@'--with-linker-hash-style=${LINKER_HASH_STYLE}' if '${LINKER_HASH_STYLE}' else ''} \
+    --enable-linker-build-id \
+    --with-ppl=no \
+    --with-cloog=no \
+    --enable-checking=release \
+    --enable-cheaders=c_global \
+    --without-isl \
+"
+
+EXTRA_OECONF_INITIAL = "\
+    --disable-libmudflap \
+    --disable-libgomp \
+    --disable-libitm \
+    --disable-libquadmath \
+    --with-system-zlib \
+    --disable-lto \
+    --disable-plugin \
+    --enable-linker-build-id \
+    --enable-decimal-float=no \
+    --without-isl \
+    --disable-libssp \
+"
+
+EXTRA_OECONF_PATHS = "\
+    --with-gxx-include-dir=/not/exist{target_includedir}/c++/${BINV} \
+    --with-sysroot=/not/exist \
+    --with-build-sysroot=${STAGING_DIR_TARGET} \
+"
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch
new file mode 100644
index 0000000..423fe28
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch
@@ -0,0 +1,42 @@
+From b752fb2b6d6f6da68da5386b96abf0d74cd4bbe6 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 08:37:11 +0400
+Subject: [PATCH 01/39] gcc-4.3.1: ARCH_FLAGS_FOR_TARGET
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Inappropriate [embedded specific]
+---
+ configure    | 2 +-
+ configure.ac | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/configure b/configure
+index 69c99e99cca..517fb70192e 100755
+--- a/configure
++++ b/configure
+@@ -7511,7 +7511,7 @@ fi
+ # for target_alias and gcc doesn't manage it consistently.
+ target_configargs="--cache-file=./config.cache ${target_configargs}"
+ 
+-FLAGS_FOR_TARGET=
++FLAGS_FOR_TARGET="$ARCH_FLAGS_FOR_TARGET"
+ case " $target_configdirs " in
+  *" newlib "*)
+   case " $target_configargs " in
+diff --git a/configure.ac b/configure.ac
+index a1edc369a27..f8c254f1fac 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -3100,7 +3100,7 @@ fi
+ # for target_alias and gcc doesn't manage it consistently.
+ target_configargs="--cache-file=./config.cache ${target_configargs}"
+ 
+-FLAGS_FOR_TARGET=
++FLAGS_FOR_TARGET="$ARCH_FLAGS_FOR_TARGET"
+ case " $target_configdirs " in
+  *" newlib "*)
+   case " $target_configargs " in
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0003-gcc-poison-system-directories.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0003-gcc-poison-system-directories.patch
new file mode 100644
index 0000000..0513897
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0003-gcc-poison-system-directories.patch
@@ -0,0 +1,194 @@
+From 48c670d2678e0323d88eb72205e039f393cabe05 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 08:59:00 +0400
+Subject: [PATCH 03/39] gcc: poison-system-directories
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Inappropriate [distribution: codesourcery]
+---
+ gcc/common.opt      |  4 ++++
+ gcc/config.in       |  6 ++++++
+ gcc/configure       | 16 ++++++++++++++++
+ gcc/configure.ac    | 10 ++++++++++
+ gcc/doc/invoke.texi |  9 +++++++++
+ gcc/gcc.c           |  2 ++
+ gcc/incpath.c       | 19 +++++++++++++++++++
+ 7 files changed, 66 insertions(+)
+
+diff --git a/gcc/common.opt b/gcc/common.opt
+index d6ef85928f3..7b29efe3882 100644
+--- a/gcc/common.opt
++++ b/gcc/common.opt
+@@ -679,6 +679,10 @@ Wreturn-local-addr
+ Common Var(warn_return_local_addr) Init(1) Warning
+ Warn about returning a pointer/reference to a local or temporary variable.
+ 
++Wpoison-system-directories
++Common Var(flag_poison_system_directories) Init(1) Warning
++Warn for -I and -L options using system directories if cross compiling
++
+ Wshadow
+ Common Var(warn_shadow) Warning
+ Warn when one variable shadows another.  Same as -Wshadow=global.
+diff --git a/gcc/config.in b/gcc/config.in
+index 5bccb408016..1c784a8276b 100644
+--- a/gcc/config.in
++++ b/gcc/config.in
+@@ -194,6 +194,12 @@
+ #endif
+ 
+ 
++/* Define to warn for use of native system header directories */
++#ifndef USED_FOR_TARGET
++#undef ENABLE_POISON_SYSTEM_DIRECTORIES
++#endif
++
++
+ /* Define if you want all operations on RTL (the basic data structure of the
+    optimizer and back end) to be checked for dynamic type safety at runtime.
+    This is quite expensive. */
+diff --git a/gcc/configure b/gcc/configure
+index 5c345ce0fd7..cafd05fd150 100755
+--- a/gcc/configure
++++ b/gcc/configure
+@@ -953,6 +953,7 @@ with_system_zlib
+ enable_maintainer_mode
+ enable_link_mutex
+ enable_version_specific_runtime_libs
++enable_poison_system_directories
+ enable_plugin
+ enable_host_shared
+ enable_libquadmath_support
+@@ -1696,6 +1697,8 @@ Optional Features:
+   --enable-version-specific-runtime-libs
+                           specify that runtime libraries should be installed
+                           in a compiler-specific directory
++  --enable-poison-system-directories
++                          warn for use of native system header directories
+   --enable-plugin         enable plugin support
+   --enable-host-shared    build host code as shared libraries
+   --disable-libquadmath-support
+@@ -29715,6 +29718,19 @@ if test "${enable_version_specific_runtime_libs+set}" = set; then :
+ fi
+ 
+ 
++# Check whether --enable-poison-system-directories was given.
++if test "${enable_poison_system_directories+set}" = set; then :
++  enableval=$enable_poison_system_directories;
++else
++  enable_poison_system_directories=no
++fi
++
++if test "x${enable_poison_system_directories}" = "xyes"; then
++
++$as_echo "#define ENABLE_POISON_SYSTEM_DIRECTORIES 1" >>confdefs.h
++
++fi
++
+ # Substitute configuration variables
+ 
+ 
+diff --git a/gcc/configure.ac b/gcc/configure.ac
+index 65dbf1f2f80..dd5b38195ce 100644
+--- a/gcc/configure.ac
++++ b/gcc/configure.ac
+@@ -6341,6 +6341,16 @@ AC_ARG_ENABLE(version-specific-runtime-libs,
+                 [specify that runtime libraries should be
+                  installed in a compiler-specific directory])])
+ 
++AC_ARG_ENABLE([poison-system-directories],
++             AS_HELP_STRING([--enable-poison-system-directories],
++                            [warn for use of native system header directories]),,
++             [enable_poison_system_directories=no])
++if test "x${enable_poison_system_directories}" = "xyes"; then
++  AC_DEFINE([ENABLE_POISON_SYSTEM_DIRECTORIES],
++           [1],
++           [Define to warn for use of native system header directories])
++fi
++
+ # Substitute configuration variables
+ AC_SUBST(subdirs)
+ AC_SUBST(srcdir)
+diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
+index 255149fcfb8..cb71b60fe3c 100644
+--- a/gcc/doc/invoke.texi
++++ b/gcc/doc/invoke.texi
+@@ -303,6 +303,7 @@ Objective-C and Objective-C++ Dialects}.
+ -Wpacked  -Wpacked-bitfield-compat -Wpacked-not-aligned -Wpadded @gol
+ -Wparentheses  -Wno-pedantic-ms-format @gol
+ -Wplacement-new  -Wplacement-new=@var{n} @gol
++-Wno-poison-system-directories @gol
+ -Wpointer-arith  -Wpointer-compare  -Wno-pointer-to-int-cast @gol
+ -Wno-pragmas  -Wredundant-decls  -Wrestrict  -Wno-return-local-addr @gol
+ -Wreturn-type  -Wsequence-point  -Wshadow  -Wno-shadow-ivar @gol
+@@ -5712,6 +5713,14 @@ made up of data only and thus requires no special treatment.  But, for
+ most targets, it is made up of code and thus requires the stack to be
+ made executable in order for the program to work properly.
+ 
++@item -Wno-poison-system-directories
++@opindex Wno-poison-system-directories
++Do not warn for @option{-I} or @option{-L} options using system
++directories such as @file{/usr/include} when cross compiling.  This
++option is intended for use in chroot environments when such
++directories contain the correct headers and libraries for the target
++system rather than the host.
++
+ @item -Wfloat-equal
+ @opindex Wfloat-equal
+ @opindex Wno-float-equal
+diff --git a/gcc/gcc.c b/gcc/gcc.c
+index a716f708259..02b3cd39fc2 100644
+--- a/gcc/gcc.c
++++ b/gcc/gcc.c
+@@ -1037,6 +1037,8 @@ proper position among the other output files.  */
+    "%{fuse-ld=*:-fuse-ld=%*} " LINK_COMPRESS_DEBUG_SPEC \
+    "%X %{o*} %{e*} %{N} %{n} %{r}\
+     %{s} %{t} %{u*} %{z} %{Z} %{!nostdlib:%{!nostartfiles:%S}} \
++    %{Wno-poison-system-directories:--no-poison-system-directories} \
++    %{Werror=poison-system-directories:--error-poison-system-directories} \
+     %{static|no-pie|static-pie:} %{L*} %(mfwrap) %(link_libgcc) " \
+     VTABLE_VERIFICATION_SPEC " " SANITIZER_EARLY_SPEC " %o " CHKP_SPEC " \
+     %{fopenacc|fopenmp|%:gt(%{ftree-parallelize-loops=*:%*} 1):\
+diff --git a/gcc/incpath.c b/gcc/incpath.c
+index b11c6a57939..e3b7a21966f 100644
+--- a/gcc/incpath.c
++++ b/gcc/incpath.c
+@@ -26,6 +26,7 @@
+ #include "intl.h"
+ #include "incpath.h"
+ #include "cppdefault.h"
++#include "diagnostic-core.h"
+ 
+ /* Microsoft Windows does not natively support inodes.
+    VMS has non-numeric inodes.  */
+@@ -393,6 +394,26 @@ merge_include_chains (const char *sysroot, cpp_reader *pfile, int verbose)
+ 	}
+       fprintf (stderr, _("End of search list.\n"));
+     }
++
++#ifdef ENABLE_POISON_SYSTEM_DIRECTORIES
++  if (flag_poison_system_directories)
++    {
++       struct cpp_dir *p;
++
++       for (p = heads[INC_QUOTE]; p; p = p->next)
++         {
++          if ((!strncmp (p->name, "/usr/include", 12))
++              || (!strncmp (p->name, "/usr/local/include", 18))
++              || (!strncmp (p->name, "/usr/X11R6/include", 18))
++              || (!strncmp (p->name, "/sw/include", 11))
++              || (!strncmp (p->name, "/opt/include", 12)))
++            warning (OPT_Wpoison_system_directories,
++                     "include location \"%s\" is unsafe for "
++                     "cross-compilation",
++                     p->name);
++         }
++    }
++#endif
+ }
+ 
+ /* Use given -I paths for #include "..." but not #include <...>, and
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0005-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0005-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch
new file mode 100644
index 0000000..8b1b976
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0005-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch
@@ -0,0 +1,73 @@
+From ae3fe6e5e50937de6e4223ca90810187372a8cf5 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 09:08:31 +0400
+Subject: [PATCH 05/39] gcc-4.3.3: SYSROOT_CFLAGS_FOR_TARGET
+
+Before committing, I noticed that PR/32161 was marked as a dup of PR/32009, but my previous patch did not fix it.
+
+This alternative patch is better because it lets you just use CFLAGS_FOR_TARGET to set the compilation flags for libgcc. Since bootstrapped target libraries are never compiled with the native compiler, it makes little sense to use different flags for stage1 and later stages. And it also makes little sense to use a different variable than CFLAGS_FOR_TARGET.
+
+Other changes I had to do include:
+
+- moving the creation of default CFLAGS_FOR_TARGET from Makefile.am to configure.ac, because otherwise the BOOT_CFLAGS are substituted into CFLAGS_FOR_TARGET (which is "-O2 -g $(CFLAGS)") via $(CFLAGS). It is also cleaner this way though.
+
+- passing the right CFLAGS to configure scripts as exported environment variables
+
+I also stopped passing LIBCFLAGS to configure scripts since they are unused in the whole src tree. And I updated the documentation as H-P reminded me to do.
+
+Bootstrapped/regtested i686-pc-linux-gnu, will commit to 4.4 shortly. Ok for 4.3?
+
+Signed-off-by: Paolo Bonzini  <bonzini@gnu.org>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Pending
+---
+ configure | 32 ++++++++++++++++++++++++++++++++
+ 1 file changed, 32 insertions(+)
+
+diff --git a/configure b/configure
+index 517fb70192e..acd2b97df40 100755
+--- a/configure
++++ b/configure
+@@ -6772,6 +6772,38 @@ fi
+ 
+ 
+ 
++# During gcc bootstrap, if we use some random cc for stage1 then CFLAGS
++# might be empty or "-g".  We don't require a C++ compiler, so CXXFLAGS
++# might also be empty (or "-g", if a non-GCC C++ compiler is in the path).
++# We want to ensure that TARGET libraries (which we know are built with
++# gcc) are built with "-O2 -g", so include those options when setting
++# CFLAGS_FOR_TARGET and CXXFLAGS_FOR_TARGET.
++if test "x$CFLAGS_FOR_TARGET" = x; then
++  CFLAGS_FOR_TARGET=$CFLAGS
++  case " $CFLAGS " in
++    *" -O2 "*) ;;
++    *) CFLAGS_FOR_TARGET="-O2 $CFLAGS" ;;
++  esac
++  case " $CFLAGS " in
++    *" -g "* | *" -g3 "*) ;;
++    *) CFLAGS_FOR_TARGET="-g $CFLAGS" ;;
++  esac
++fi
++
++
++if test "x$CXXFLAGS_FOR_TARGET" = x; then
++  CXXFLAGS_FOR_TARGET=$CXXFLAGS
++  case " $CXXFLAGS " in
++    *" -O2 "*) ;;
++    *) CXXFLAGS_FOR_TARGET="-O2 $CXXFLAGS" ;;
++  esac
++  case " $CXXFLAGS " in
++    *" -g "* | *" -g3 "*) ;;
++    *) CXXFLAGS_FOR_TARGET="-g $CXXFLAGS" ;;
++  esac
++fi
++
++
+ # Handle --with-headers=XXX.  If the value is not "yes", the contents of
+ # the named directory are copied to $(tooldir)/sys-include.
+ if test x"${with_headers}" != x && test x"${with_headers}" != xno ; then
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0006-64-bit-multilib-hack.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0006-64-bit-multilib-hack.patch
new file mode 100644
index 0000000..0dce95c
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0006-64-bit-multilib-hack.patch
@@ -0,0 +1,85 @@
+From 89af3b7399313b337f06c19cc2d787aa16d27711 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 09:10:06 +0400
+Subject: [PATCH 06/39] 64-bit multilib hack.
+
+GCC has internal multilib handling code but it assumes a very specific rigid directory
+layout. The build system implementation of multilib layout is very generic and allows
+complete customisation of the library directories.
+
+This patch is a partial solution to allow any custom directories to be passed into gcc
+and handled correctly. It forces gcc to use the base_libdir (which is the current
+directory, "."). We need to do this for each multilib that is configured as we don't
+know which compiler options may be being passed into the compiler. Since we have a compiler
+per mulitlib at this point that isn't an issue.
+
+The one problem is the target compiler is only going to work for the default multlilib at
+this point. Ideally we'd figure out which multilibs were being enabled with which paths
+and be able to patch these entries with a complete set of correct paths but this we
+don't have such code at this point. This is something the target gcc recipe should do
+and override these platform defaults in its build config.
+
+RP 15/8/11
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Elvis Dowson <elvis.dowson@gmail.com>
+
+Upstream-Status: Pending
+---
+ gcc/config/i386/t-linux64   |  6 ++----
+ gcc/config/mips/t-linux64   | 10 +++-------
+ gcc/config/rs6000/t-linux64 |  5 ++---
+ 3 files changed, 7 insertions(+), 14 deletions(-)
+
+diff --git a/gcc/config/i386/t-linux64 b/gcc/config/i386/t-linux64
+index 8ea0faff369..266c6008004 100644
+--- a/gcc/config/i386/t-linux64
++++ b/gcc/config/i386/t-linux64
+@@ -32,7 +32,5 @@
+ #
+ comma=,
+ MULTILIB_OPTIONS    = $(subst $(comma),/,$(TM_MULTILIB_CONFIG))
+-MULTILIB_DIRNAMES   = $(patsubst m%, %, $(subst /, ,$(MULTILIB_OPTIONS)))
+-MULTILIB_OSDIRNAMES = m64=../lib64$(call if_multiarch,:x86_64-linux-gnu)
+-MULTILIB_OSDIRNAMES+= m32=$(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib)$(call if_multiarch,:i386-linux-gnu)
+-MULTILIB_OSDIRNAMES+= mx32=../libx32$(call if_multiarch,:x86_64-linux-gnux32)
++MULTILIB_DIRNAMES = . .
++MULTILIB_OSDIRNAMES = ../$(shell basename $(base_libdir)) ../$(shell basename $(base_libdir))
+diff --git a/gcc/config/mips/t-linux64 b/gcc/config/mips/t-linux64
+index c017b7d04c5..126892cf40b 100644
+--- a/gcc/config/mips/t-linux64
++++ b/gcc/config/mips/t-linux64
+@@ -17,10 +17,6 @@
+ # <http://www.gnu.org/licenses/>.
+ 
+ MULTILIB_OPTIONS = mabi=n32/mabi=32/mabi=64
+-MULTILIB_DIRNAMES = n32 32 64
+-MIPS_EL = $(if $(filter %el, $(firstword $(subst -, ,$(target)))),el)
+-MIPS_SOFT = $(if $(strip $(filter MASK_SOFT_FLOAT_ABI, $(target_cpu_default)) $(filter soft, $(with_float))),soft)
+-MULTILIB_OSDIRNAMES = \
+-	../lib32$(call if_multiarch,:mips64$(MIPS_EL)-linux-gnuabin32$(MIPS_SOFT)) \
+-	../lib$(call if_multiarch,:mips$(MIPS_EL)-linux-gnu$(MIPS_SOFT)) \
+-	../lib64$(call if_multiarch,:mips64$(MIPS_EL)-linux-gnuabi64$(MIPS_SOFT))
++MULTILIB_DIRNAMES = . . .
++MULTILIB_OSDIRNAMES = ../$(shell basename $(base_libdir)) ../$(shell basename $(base_libdir)) ../$(shell basename $(base_libdir))
++
+diff --git a/gcc/config/rs6000/t-linux64 b/gcc/config/rs6000/t-linux64
+index 0faa2a02df4..13fd8ca971e 100644
+--- a/gcc/config/rs6000/t-linux64
++++ b/gcc/config/rs6000/t-linux64
+@@ -26,10 +26,9 @@
+ # MULTILIB_OSDIRNAMES according to what is found on the target.
+ 
+ MULTILIB_OPTIONS    := m64/m32
+-MULTILIB_DIRNAMES   := 64 32
++MULTILIB_DIRNAMES   := . .
+ MULTILIB_EXTRA_OPTS := 
+-MULTILIB_OSDIRNAMES := m64=../lib64$(call if_multiarch,:powerpc64-linux-gnu)
+-MULTILIB_OSDIRNAMES += m32=$(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib)$(call if_multiarch,:powerpc-linux-gnu)
++MULTILIB_OSDIRNAMES := ../$(shell basename $(base_libdir)) ../$(shell basename $(base_libdir))
+ 
+ rs6000-linux.o: $(srcdir)/config/rs6000/rs6000-linux.c
+ 	$(COMPILE) $<
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0007-optional-libstdc.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0007-optional-libstdc.patch
new file mode 100644
index 0000000..721ea03
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0007-optional-libstdc.patch
@@ -0,0 +1,125 @@
+From fb7df63e9548c29b70601d642a1850fc455f8565 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 09:12:56 +0400
+Subject: [PATCH 07/39] optional libstdc
+
+gcc-runtime builds libstdc++ separately from gcc-cross-*. Its configure tests using g++
+will not run correctly since by default the linker will try to link against libstdc++
+which shouldn't exist yet. We need an option to disable -lstdc++
+option whilst leaving -lc, -lgcc and other automatic library dependencies added by gcc
+driver. This patch adds such an option which only disables the -lstdc++.
+
+A "standard" gcc build uses xgcc and hence avoids this. We should ask upstream how to
+do this officially, the likely answer is don't build libstdc++ separately.
+
+RP 29/6/10
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Inappropriate [embedded specific]
+---
+ gcc/c-family/c.opt  |  4 ++++
+ gcc/cp/g++spec.c    |  1 +
+ gcc/doc/invoke.texi | 32 +++++++++++++++++++++++++++++++-
+ gcc/gcc.c           |  1 +
+ 4 files changed, 37 insertions(+), 1 deletion(-)
+
+diff --git a/gcc/c-family/c.opt b/gcc/c-family/c.opt
+index 5013501b232..6312f2c8f90 100644
+--- a/gcc/c-family/c.opt
++++ b/gcc/c-family/c.opt
+@@ -1900,6 +1900,10 @@ nostdinc++
+ C++ ObjC++
+ Do not search standard system include directories for C++.
+ 
++nostdlib++
++Driver
++Do not link standard C++ runtime library
++
+ o
+ C ObjC C++ ObjC++ Joined Separate
+ ; Documented in common.opt
+diff --git a/gcc/cp/g++spec.c b/gcc/cp/g++spec.c
+index 443a1746da3..e9b51be62ef 100644
+--- a/gcc/cp/g++spec.c
++++ b/gcc/cp/g++spec.c
+@@ -137,6 +137,7 @@ lang_specific_driver (struct cl_decoded_option **in_decoded_options,
+       switch (decoded_options[i].opt_index)
+ 	{
+ 	case OPT_nostdlib:
++	case OPT_nostdlib__:
+ 	case OPT_nodefaultlibs:
+ 	  library = -1;
+ 	  break;
+diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
+index cb71b60fe3c..b0d481e3a30 100644
+--- a/gcc/doc/invoke.texi
++++ b/gcc/doc/invoke.texi
+@@ -211,6 +211,9 @@ in the following sections.
+ -fno-weak  -nostdinc++ @gol
+ -fvisibility-inlines-hidden @gol
+ -fvisibility-ms-compat @gol
++-fvtable-verify=@r{[}std@r{|}preinit@r{|}none@r{]} @gol
++-fvtv-counts -fvtv-debug @gol
++-nostdlib++ @gol
+ -fext-numeric-literals @gol
+ -Wabi=@var{n}  -Wabi-tag  -Wconversion-null  -Wctor-dtor-privacy @gol
+ -Wdelete-non-virtual-dtor  -Wliteral-suffix  -Wmultiple-inheritance @gol
+@@ -509,7 +512,7 @@ Objective-C and Objective-C++ Dialects}.
+ -s  -static -static-pie -static-libgcc  -static-libstdc++ @gol
+ -static-libasan  -static-libtsan  -static-liblsan  -static-libubsan @gol
+ -static-libmpx  -static-libmpxwrappers @gol
+--shared  -shared-libgcc  -symbolic @gol
++-shared  -shared-libgcc  -symbolic -nostdlib++ @gol
+ -T @var{script}  -Wl,@var{option}  -Xlinker @var{option} @gol
+ -u @var{symbol}  -z @var{keyword}}
+ 
+@@ -12331,6 +12334,33 @@ library subroutines.
+ constructors are called; @pxref{Collect2,,@code{collect2}, gccint,
+ GNU Compiler Collection (GCC) Internals}.)
+ 
++@item -nostdlib++
++@opindex nostdlib++
++Do not use the standard system C++ runtime libraries when linking.
++Only the libraries you specify will be passed to the linker.
++
++@cindex @option{-lgcc}, use with @option{-nostdlib}
++@cindex @option{-nostdlib} and unresolved references
++@cindex unresolved references and @option{-nostdlib}
++@cindex @option{-lgcc}, use with @option{-nodefaultlibs}
++@cindex @option{-nodefaultlibs} and unresolved references
++@cindex unresolved references and @option{-nodefaultlibs}
++One of the standard libraries bypassed by @option{-nostdlib} and
++@option{-nodefaultlibs} is @file{libgcc.a}, a library of internal subroutines
++which GCC uses to overcome shortcomings of particular machines, or special
++needs for some languages.
++(@xref{Interface,,Interfacing to GCC Output,gccint,GNU Compiler
++Collection (GCC) Internals},
++for more discussion of @file{libgcc.a}.)
++In most cases, you need @file{libgcc.a} even when you want to avoid
++other standard libraries.  In other words, when you specify @option{-nostdlib}
++or @option{-nodefaultlibs} you should usually specify @option{-lgcc} as well.
++This ensures that you have no unresolved references to internal GCC
++library subroutines.
++(An example of such an internal subroutine is @code{__main}, used to ensure C++
++constructors are called; @pxref{Collect2,,@code{collect2}, gccint,
++GNU Compiler Collection (GCC) Internals}.)
++
+ @item -pie
+ @opindex pie
+ Produce a dynamically linked position independent executable on targets
+diff --git a/gcc/gcc.c b/gcc/gcc.c
+index 02b3cd39fc2..8cd27a5dad5 100644
+--- a/gcc/gcc.c
++++ b/gcc/gcc.c
+@@ -1047,6 +1047,7 @@ proper position among the other output files.  */
+     %(mflib) " STACK_SPLIT_SPEC "\
+     %{fprofile-arcs|fprofile-generate*|coverage:-lgcov} " SANITIZER_SPEC " \
+     %{!nostdlib:%{!nodefaultlibs:%(link_ssp) %(link_gcc_c_sequence)}}\
++    %{!nostdlib++:}\
+     %{!nostdlib:%{!nostartfiles:%E}} %{T*}  \n%(post_link) }}}}}}"
+ #endif
+ 
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0008-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0008-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch
new file mode 100644
index 0000000..a76b7f7
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0008-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch
@@ -0,0 +1,59 @@
+From 11eb97efccb90b830c84ed077a25b1a15ad3335b Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 09:14:20 +0400
+Subject: [PATCH 08/39] gcc: disable MASK_RELAX_PIC_CALLS bit
+
+The new feature added after 4.3.3
+"http://www.pubbs.net/200909/gcc/94048-patch-add-support-for-rmipsjalr.html"
+will cause cc1plus eat up all the system memory when build webkit-gtk.
+The function mips_get_pic_call_symbol keeps on recursively calling itself.
+Disable this feature to walk aside the bug.
+
+Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Inappropriate [configuration]
+---
+ gcc/configure    | 7 -------
+ gcc/configure.ac | 7 -------
+ 2 files changed, 14 deletions(-)
+
+diff --git a/gcc/configure b/gcc/configure
+index cafd05fd150..19ba051d673 100755
+--- a/gcc/configure
++++ b/gcc/configure
+@@ -27553,13 +27553,6 @@ $as_echo_n "checking assembler and linker for explicit JALR relocation... " >&6;
+         rm -f conftest.*
+       fi
+     fi
+-    if test $gcc_cv_as_ld_jalr_reloc = yes; then
+-      if test x$target_cpu_default = x; then
+-        target_cpu_default=MASK_RELAX_PIC_CALLS
+-      else
+-        target_cpu_default="($target_cpu_default)|MASK_RELAX_PIC_CALLS"
+-      fi
+-    fi
+     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_ld_jalr_reloc" >&5
+ $as_echo "$gcc_cv_as_ld_jalr_reloc" >&6; }
+ 
+diff --git a/gcc/configure.ac b/gcc/configure.ac
+index dd5b38195ce..066dfe19bb6 100644
+--- a/gcc/configure.ac
++++ b/gcc/configure.ac
+@@ -4798,13 +4798,6 @@ x:
+         rm -f conftest.*
+       fi
+     fi
+-    if test $gcc_cv_as_ld_jalr_reloc = yes; then
+-      if test x$target_cpu_default = x; then
+-        target_cpu_default=MASK_RELAX_PIC_CALLS
+-      else
+-        target_cpu_default="($target_cpu_default)|MASK_RELAX_PIC_CALLS"
+-      fi
+-    fi
+     AC_MSG_RESULT($gcc_cv_as_ld_jalr_reloc)
+ 
+     AC_CACHE_CHECK([linker for .eh_frame personality relaxation],
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0009-COLLECT_GCC_OPTIONS.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0009-COLLECT_GCC_OPTIONS.patch
new file mode 100644
index 0000000..3abece0
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0009-COLLECT_GCC_OPTIONS.patch
@@ -0,0 +1,38 @@
+From e19d25847f08eeb5ef26a031fa5eff732bfd0d43 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 09:16:28 +0400
+Subject: [PATCH 09/39] COLLECT_GCC_OPTIONS
+
+This patch adds --sysroot into COLLECT_GCC_OPTIONS which is used to
+invoke collect2.
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Pending
+---
+ gcc/gcc.c | 9 +++++++++
+ 1 file changed, 9 insertions(+)
+
+diff --git a/gcc/gcc.c b/gcc/gcc.c
+index 8cd27a5dad5..d355d65583a 100644
+--- a/gcc/gcc.c
++++ b/gcc/gcc.c
+@@ -4677,6 +4677,15 @@ set_collect_gcc_options (void)
+ 		sizeof ("COLLECT_GCC_OPTIONS=") - 1);
+ 
+   first_time = TRUE;
++#ifdef HAVE_LD_SYSROOT
++  if (target_system_root_changed && target_system_root)
++    {
++      obstack_grow (&collect_obstack, "'--sysroot=", sizeof("'--sysroot=")-1);
++      obstack_grow (&collect_obstack, target_system_root,strlen(target_system_root));
++      obstack_grow (&collect_obstack, "'", 1);
++      first_time = FALSE;
++    }
++#endif
+   for (i = 0; (int) i < n_switches; i++)
+     {
+       const char *const *args;
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0010-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0010-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch
new file mode 100644
index 0000000..5785b58
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0010-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch
@@ -0,0 +1,96 @@
+From 265cb883c310f3bb7e49fd13b81362476fbeb6c1 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 09:17:25 +0400
+Subject: [PATCH 10/39] Use the defaults.h in ${B} instead of ${S}, and t-oe in
+ ${B}
+
+Use the defaults.h in ${B} instead of ${S}, and t-oe in ${B}, so that
+the source can be shared between gcc-cross-initial,
+gcc-cross-intermediate, gcc-cross, gcc-runtime, and also the sdk build.
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Pending
+
+While compiling gcc-crosssdk-initial-x86_64 on some host, there is
+occasionally failure that test the existance of default.h doesn't
+work, the reason is tm_include_list='** defaults.h' rather than
+tm_include_list='** ./defaults.h'
+
+So we add the test condition for this situation.
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ gcc/Makefile.in  | 2 +-
+ gcc/configure    | 4 ++--
+ gcc/configure.ac | 4 ++--
+ gcc/mkconfig.sh  | 4 ++--
+ 4 files changed, 7 insertions(+), 7 deletions(-)
+
+diff --git a/gcc/Makefile.in b/gcc/Makefile.in
+index 20bee0494b1..1367136bfac 100644
+--- a/gcc/Makefile.in
++++ b/gcc/Makefile.in
+@@ -538,7 +538,7 @@ TARGET_SYSTEM_ROOT = @TARGET_SYSTEM_ROOT@
+ TARGET_SYSTEM_ROOT_DEFINE = @TARGET_SYSTEM_ROOT_DEFINE@
+ 
+ xmake_file=@xmake_file@
+-tmake_file=@tmake_file@
++tmake_file=@tmake_file@ ./t-oe
+ TM_ENDIAN_CONFIG=@TM_ENDIAN_CONFIG@
+ TM_MULTILIB_CONFIG=@TM_MULTILIB_CONFIG@
+ TM_MULTILIB_EXCEPTIONS_CONFIG=@TM_MULTILIB_EXCEPTIONS_CONFIG@
+diff --git a/gcc/configure b/gcc/configure
+index 19ba051d673..a575839c1b2 100755
+--- a/gcc/configure
++++ b/gcc/configure
+@@ -12158,8 +12158,8 @@ for f in $tm_file; do
+        tm_include_list="${tm_include_list} $f"
+        ;;
+     defaults.h )
+-       tm_file_list="${tm_file_list} \$(srcdir)/$f"
+-       tm_include_list="${tm_include_list} $f"
++       tm_file_list="${tm_file_list} ./$f"
++       tm_include_list="${tm_include_list} ./$f"
+        ;;
+     * )
+        tm_file_list="${tm_file_list} \$(srcdir)/config/$f"
+diff --git a/gcc/configure.ac b/gcc/configure.ac
+index 066dfe19bb6..676116a6d96 100644
+--- a/gcc/configure.ac
++++ b/gcc/configure.ac
+@@ -1922,8 +1922,8 @@ for f in $tm_file; do
+        tm_include_list="${tm_include_list} $f"
+        ;;
+     defaults.h )
+-       tm_file_list="${tm_file_list} \$(srcdir)/$f"
+-       tm_include_list="${tm_include_list} $f"
++       tm_file_list="${tm_file_list} ./$f"
++       tm_include_list="${tm_include_list} ./$f"
+        ;;
+     * )
+        tm_file_list="${tm_file_list} \$(srcdir)/config/$f"
+diff --git a/gcc/mkconfig.sh b/gcc/mkconfig.sh
+index 0f75c863c0b..68d8d6613cf 100644
+--- a/gcc/mkconfig.sh
++++ b/gcc/mkconfig.sh
+@@ -77,7 +77,7 @@ if [ -n "$HEADERS" ]; then
+     if [ $# -ge 1 ]; then
+ 	echo '#ifdef IN_GCC' >> ${output}T
+ 	for file in "$@"; do
+-	    if test x"$file" = x"defaults.h"; then
++	    if test x"$file" = x"./defaults.h" -o x"$file" = x"defaults.h"; then
+ 		postpone_defaults_h="yes"
+ 	    else
+ 		echo "# include \"$file\"" >> ${output}T
+@@ -106,7 +106,7 @@ esac
+ 
+ # If we postponed including defaults.h, add the #include now.
+ if test x"$postpone_defaults_h" = x"yes"; then
+-    echo "# include \"defaults.h\"" >> ${output}T
++    echo "# include \"./defaults.h\"" >> ${output}T
+ fi
+ 
+ # Add multiple inclusion protection guard, part two.
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0011-fortran-cross-compile-hack.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0011-fortran-cross-compile-hack.patch
new file mode 100644
index 0000000..fe0fb7d
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0011-fortran-cross-compile-hack.patch
@@ -0,0 +1,46 @@
+From 71cba188d47b6ae9d9b87261eb4bc9eb68ae355d Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 09:20:01 +0400
+Subject: [PATCH 11/39] fortran cross-compile hack.
+
+* Fortran would have searched for arm-angstrom-gnueabi-gfortran but would have used
+used gfortan. For gcc_4.2.2.bb we want to use the gfortran compiler from our cross
+directory.
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Inappropriate [embedded specific]
+---
+ libgfortran/configure    | 2 +-
+ libgfortran/configure.ac | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/libgfortran/configure b/libgfortran/configure
+index 91fce8fecd0..6747f86eb98 100755
+--- a/libgfortran/configure
++++ b/libgfortran/configure
+@@ -12883,7 +12883,7 @@ esac
+ 
+ # We need gfortran to compile parts of the library
+ #AC_PROG_FC(gfortran)
+-FC="$GFORTRAN"
++#FC="$GFORTRAN"
+ ac_ext=${ac_fc_srcext-f}
+ ac_compile='$FC -c $FCFLAGS $ac_fcflags_srcext conftest.$ac_ext >&5'
+ ac_link='$FC -o conftest$ac_exeext $FCFLAGS $LDFLAGS $ac_fcflags_srcext conftest.$ac_ext $LIBS >&5'
+diff --git a/libgfortran/configure.ac b/libgfortran/configure.ac
+index bf6d3634dda..9dbe43cc616 100644
+--- a/libgfortran/configure.ac
++++ b/libgfortran/configure.ac
+@@ -250,7 +250,7 @@ AC_SUBST(enable_static)
+ 
+ # We need gfortran to compile parts of the library
+ #AC_PROG_FC(gfortran)
+-FC="$GFORTRAN"
++#FC="$GFORTRAN"
+ AC_PROG_FC(gfortran)
+ 
+ # extra LD Flags which are required for targets
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0012-cpp-honor-sysroot.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0012-cpp-honor-sysroot.patch
new file mode 100644
index 0000000..961f96f
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0012-cpp-honor-sysroot.patch
@@ -0,0 +1,54 @@
+From b3e8e7e8ae106e3207e9edc3d23dcce1464b755f Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 09:22:00 +0400
+Subject: [PATCH 12/39] cpp: honor sysroot.
+
+Currently, if the gcc toolchain is relocated and installed from sstate, then you try and compile
+preprocessed source (.i or .ii files), the compiler will try and access the builtin sysroot location
+rather than the --sysroot option specified on the commandline. If access to that directory is
+permission denied (unreadable), gcc will error.
+
+This happens when ccache is in use due to the fact it uses preprocessed source files.
+
+The fix below adds %I to the cpp-output spec macro so the default substitutions for -iprefix,
+-isystem, -isysroot happen and the correct sysroot is used.
+
+[YOCTO #2074]
+
+RP 2012/04/13
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Pending
+---
+ gcc/cp/lang-specs.h | 2 +-
+ gcc/gcc.c           | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/gcc/cp/lang-specs.h b/gcc/cp/lang-specs.h
+index f0802b8915c..f324d299849 100644
+--- a/gcc/cp/lang-specs.h
++++ b/gcc/cp/lang-specs.h
+@@ -64,5 +64,5 @@ along with GCC; see the file COPYING3.  If not see
+   {".ii", "@c++-cpp-output", 0, 0, 0},
+   {"@c++-cpp-output",
+    "%{!M:%{!MM:%{!E:\
+-    cc1plus -fpreprocessed %i %(cc1_options) %2\
++    cc1plus -fpreprocessed %i %I %(cc1_options) %2\
+     %{!fsyntax-only:%(invoke_as)}}}}", 0, 0, 0},
+diff --git a/gcc/gcc.c b/gcc/gcc.c
+index d355d65583a..570cdc00034 100644
+--- a/gcc/gcc.c
++++ b/gcc/gcc.c
+@@ -1343,7 +1343,7 @@ static const struct compiler default_compilers[] =
+ 					   %W{o*:--output-pch=%*}}%V}}}}}}}", 0, 0, 0},
+   {".i", "@cpp-output", 0, 0, 0},
+   {"@cpp-output",
+-   "%{!M:%{!MM:%{!E:cc1 -fpreprocessed %i %(cc1_options) %{!fsyntax-only:%(invoke_as)}}}}", 0, 0, 0},
++   "%{!M:%{!MM:%{!E:cc1 -fpreprocessed %i %I %(cc1_options) %{!fsyntax-only:%(invoke_as)}}}}", 0, 0, 0},
+   {".s", "@assembler", 0, 0, 0},
+   {"@assembler",
+    "%{!M:%{!MM:%{!E:%{!S:as %(asm_debug) %(asm_options) %i %A }}}}", 0, 0, 0},
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0013-MIPS64-Default-to-N64-ABI.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0013-MIPS64-Default-to-N64-ABI.patch
new file mode 100644
index 0000000..8ef8806
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0013-MIPS64-Default-to-N64-ABI.patch
@@ -0,0 +1,57 @@
+From 0f3629978cd7c98614e87d4fd190b89864221631 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 09:23:08 +0400
+Subject: [PATCH 13/39] MIPS64: Default to N64 ABI
+
+MIPS64 defaults to n32 ABI, this patch makes it
+so that it defaults to N64 ABI
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Inappropriate [OE config specific]
+---
+ gcc/config.gcc | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/gcc/config.gcc b/gcc/config.gcc
+index 8741dd1e3b2..2ffcb39d85f 100644
+--- a/gcc/config.gcc
++++ b/gcc/config.gcc
+@@ -2137,29 +2137,29 @@ mips*-*-linux*)				# Linux MIPS, either endian.
+ 			default_mips_arch=mips32
+ 			;;
+ 		mips64el-st-linux-gnu)
+-			default_mips_abi=n32
++			default_mips_abi=64
+ 			tm_file="${tm_file} mips/st.h"
+ 			tmake_file="${tmake_file} mips/t-st"
+ 			enable_mips_multilibs="yes"
+ 			;;
+ 		mips64octeon*-*-linux*)
+-			default_mips_abi=n32
++			default_mips_abi=64
+ 			tm_defines="${tm_defines} MIPS_CPU_STRING_DEFAULT=\\\"octeon\\\""
+ 			target_cpu_default=MASK_SOFT_FLOAT_ABI
+ 			enable_mips_multilibs="yes"
+ 			;;
+ 		mipsisa64r6*-*-linux*)
+-			default_mips_abi=n32
++			default_mips_abi=64
+ 			default_mips_arch=mips64r6
+ 			enable_mips_multilibs="yes"
+ 			;;
+ 		mipsisa64r2*-*-linux*)
+-			default_mips_abi=n32
++			default_mips_abi=64
+ 			default_mips_arch=mips64r2
+ 			enable_mips_multilibs="yes"
+ 			;;
+ 		mips64*-*-linux* | mipsisa64*-*-linux*)
+-			default_mips_abi=n32
++			default_mips_abi=64
+ 			enable_mips_multilibs="yes"
+ 			;;
+ 	esac
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0014-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0014-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch
new file mode 100644
index 0000000..043bb9d
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0014-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch
@@ -0,0 +1,248 @@
+From 53f1c382b1366c5621c8edead9c766950c290fd9 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 09:24:50 +0400
+Subject: [PATCH 14/39] Define GLIBC_DYNAMIC_LINKER and UCLIBC_DYNAMIC_LINKER
+ relative to SYSTEMLIBS_DIR
+
+This patch defines GLIBC_DYNAMIC_LINKER and UCLIBC_DYNAMIC_LINKER
+relative to SYSTEMLIBS_DIR which can be set in generated headers
+This breaks the assumption of hardcoded multilib in gcc
+Change is only for the supported architectures in OE including
+SH, sparc, alpha for possible future support (if any)
+
+Removes the do_headerfix task in metadata
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Inappropriate [OE configuration]
+---
+ gcc/config/alpha/linux-elf.h |  4 ++--
+ gcc/config/arm/linux-eabi.h  |  4 ++--
+ gcc/config/arm/linux-elf.h   |  2 +-
+ gcc/config/i386/linux.h      |  2 +-
+ gcc/config/i386/linux64.h    |  6 +++---
+ gcc/config/linux.h           |  8 ++++----
+ gcc/config/mips/linux.h      | 12 ++++++------
+ gcc/config/riscv/linux.h     |  2 +-
+ gcc/config/rs6000/linux64.h  | 16 ++++++----------
+ gcc/config/sh/linux.h        |  2 +-
+ gcc/config/sparc/linux.h     |  2 +-
+ gcc/config/sparc/linux64.h   |  4 ++--
+ 12 files changed, 30 insertions(+), 34 deletions(-)
+
+diff --git a/gcc/config/alpha/linux-elf.h b/gcc/config/alpha/linux-elf.h
+index 36b74dc1993..02373578af8 100644
+--- a/gcc/config/alpha/linux-elf.h
++++ b/gcc/config/alpha/linux-elf.h
+@@ -23,8 +23,8 @@ along with GCC; see the file COPYING3.  If not see
+ #define EXTRA_SPECS \
+ { "elf_dynamic_linker", ELF_DYNAMIC_LINKER },
+ 
+-#define GLIBC_DYNAMIC_LINKER	"/lib/ld-linux.so.2"
+-#define UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
++#define GLIBC_DYNAMIC_LINKER	SYSTEMLIBS_DIR "ld-linux.so.2"
++#define UCLIBC_DYNAMIC_LINKER  SYSTEMLIBS_DIR "ld-uClibc.so.0"
+ #if DEFAULT_LIBC == LIBC_UCLIBC
+ #define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}"
+ #elif DEFAULT_LIBC == LIBC_GLIBC
+diff --git a/gcc/config/arm/linux-eabi.h b/gcc/config/arm/linux-eabi.h
+index 8585fde3d41..b3af68cac57 100644
+--- a/gcc/config/arm/linux-eabi.h
++++ b/gcc/config/arm/linux-eabi.h
+@@ -62,8 +62,8 @@
+    GLIBC_DYNAMIC_LINKER_DEFAULT and TARGET_DEFAULT_FLOAT_ABI.  */
+ 
+ #undef  GLIBC_DYNAMIC_LINKER
+-#define GLIBC_DYNAMIC_LINKER_SOFT_FLOAT "/lib/ld-linux.so.3"
+-#define GLIBC_DYNAMIC_LINKER_HARD_FLOAT "/lib/ld-linux-armhf.so.3"
++#define GLIBC_DYNAMIC_LINKER_SOFT_FLOAT SYSTEMLIBS_DIR "ld-linux.so.3"
++#define GLIBC_DYNAMIC_LINKER_HARD_FLOAT SYSTEMLIBS_DIR "ld-linux-armhf.so.3"
+ #define GLIBC_DYNAMIC_LINKER_DEFAULT GLIBC_DYNAMIC_LINKER_SOFT_FLOAT
+ 
+ #define GLIBC_DYNAMIC_LINKER \
+diff --git a/gcc/config/arm/linux-elf.h b/gcc/config/arm/linux-elf.h
+index cfcd9cb1a5c..a798e987ecb 100644
+--- a/gcc/config/arm/linux-elf.h
++++ b/gcc/config/arm/linux-elf.h
+@@ -60,7 +60,7 @@
+ 
+ #define LIBGCC_SPEC "%{mfloat-abi=soft*:-lfloat} -lgcc"
+ 
+-#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
++#define GLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-linux.so.2"
+ 
+ #define LINUX_TARGET_LINK_SPEC  "%{h*} \
+    %{static:-Bstatic} \
+diff --git a/gcc/config/i386/linux.h b/gcc/config/i386/linux.h
+index 69f97f15b0d..71bc31d9231 100644
+--- a/gcc/config/i386/linux.h
++++ b/gcc/config/i386/linux.h
+@@ -20,7 +20,7 @@ along with GCC; see the file COPYING3.  If not see
+ <http://www.gnu.org/licenses/>.  */
+ 
+ #define GNU_USER_LINK_EMULATION "elf_i386"
+-#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
++#define GLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-linux.so.2"
+ 
+ #undef MUSL_DYNAMIC_LINKER
+ #define MUSL_DYNAMIC_LINKER "/lib/ld-musl-i386.so.1"
+diff --git a/gcc/config/i386/linux64.h b/gcc/config/i386/linux64.h
+index f2d913e30ac..8725f33d8a5 100644
+--- a/gcc/config/i386/linux64.h
++++ b/gcc/config/i386/linux64.h
+@@ -27,9 +27,9 @@ see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
+ #define GNU_USER_LINK_EMULATION64 "elf_x86_64"
+ #define GNU_USER_LINK_EMULATIONX32 "elf32_x86_64"
+ 
+-#define GLIBC_DYNAMIC_LINKER32 "/lib/ld-linux.so.2"
+-#define GLIBC_DYNAMIC_LINKER64 "/lib64/ld-linux-x86-64.so.2"
+-#define GLIBC_DYNAMIC_LINKERX32 "/libx32/ld-linux-x32.so.2"
++#define GLIBC_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-linux.so.2"
++#define GLIBC_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld-linux-x86-64.so.2"
++#define GLIBC_DYNAMIC_LINKERX32 SYSTEMLIBS_DIR "ld-linux-x32.so.2"
+ 
+ #undef MUSL_DYNAMIC_LINKER32
+ #define MUSL_DYNAMIC_LINKER32 "/lib/ld-musl-i386.so.1"
+diff --git a/gcc/config/linux.h b/gcc/config/linux.h
+index 2ea4ff92c1d..487b0c0923b 100644
+--- a/gcc/config/linux.h
++++ b/gcc/config/linux.h
+@@ -81,10 +81,10 @@ see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
+    GLIBC_DYNAMIC_LINKER must be defined for each target using them, or
+    GLIBC_DYNAMIC_LINKER32 and GLIBC_DYNAMIC_LINKER64 for targets
+    supporting both 32-bit and 64-bit compilation.  */
+-#define UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
+-#define UCLIBC_DYNAMIC_LINKER32 "/lib/ld-uClibc.so.0"
+-#define UCLIBC_DYNAMIC_LINKER64 "/lib/ld64-uClibc.so.0"
+-#define UCLIBC_DYNAMIC_LINKERX32 "/lib/ldx32-uClibc.so.0"
++#define UCLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-uClibc.so.0"
++#define UCLIBC_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-uClibc.so.0"
++#define UCLIBC_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld64-uClibc.so.0"
++#define UCLIBC_DYNAMIC_LINKERX32 SYSTEMLIBS_DIR "ldx32-uClibc.so.0"
+ #define BIONIC_DYNAMIC_LINKER "/system/bin/linker"
+ #define BIONIC_DYNAMIC_LINKER32 "/system/bin/linker"
+ #define BIONIC_DYNAMIC_LINKER64 "/system/bin/linker64"
+diff --git a/gcc/config/mips/linux.h b/gcc/config/mips/linux.h
+index 2dfd0c18b90..12057c51b5e 100644
+--- a/gcc/config/mips/linux.h
++++ b/gcc/config/mips/linux.h
+@@ -22,20 +22,20 @@ along with GCC; see the file COPYING3.  If not see
+ #define GNU_USER_LINK_EMULATIONN32 "elf32%{EB:b}%{EL:l}tsmipn32"
+ 
+ #define GLIBC_DYNAMIC_LINKER32 \
+-  "%{mnan=2008:/lib/ld-linux-mipsn8.so.1;:/lib/ld.so.1}"
++  "%{mnan=2008:" SYSTEMLIBS_DIR "ld-linux-mipsn8.so.1;:" SYSTEMLIBS_DIR "ld.so.1}"
+ #define GLIBC_DYNAMIC_LINKER64 \
+-  "%{mnan=2008:/lib64/ld-linux-mipsn8.so.1;:/lib64/ld.so.1}"
++  "%{mnan=2008:" SYSTEMLIBS_DIR "ld-linux-mipsn8.so.1;:" SYSTEMLIBS_DIR "ld.so.1}"
+ #define GLIBC_DYNAMIC_LINKERN32 \
+-  "%{mnan=2008:/lib32/ld-linux-mipsn8.so.1;:/lib32/ld.so.1}"
++  "%{mnan=2008:" SYSTEMLIBS_DIR "ld-linux-mipsn8.so.1;:" SYSTEMLIBS_DIR "ld.so.1}"
+ 
+ #undef UCLIBC_DYNAMIC_LINKER32
+ #define UCLIBC_DYNAMIC_LINKER32 \
+-  "%{mnan=2008:/lib/ld-uClibc-mipsn8.so.0;:/lib/ld-uClibc.so.0}"
++  "%{mnan=2008:" SYSTEMLIBS_DIR "ld-uClibc-mipsn8.so.0;:" SYSTEMLIBS_DIR "ld-uClibc.so.0}"
+ #undef UCLIBC_DYNAMIC_LINKER64
+ #define UCLIBC_DYNAMIC_LINKER64 \
+-  "%{mnan=2008:/lib/ld64-uClibc-mipsn8.so.0;:/lib/ld64-uClibc.so.0}"
++  "%{mnan=2008:" SYSTEMLIBS_DIR "ld64-uClibc-mipsn8.so.0;:" SYSTEMLIBS_DIR "ld64-uClibc.so.0}"
+ #define UCLIBC_DYNAMIC_LINKERN32 \
+-  "%{mnan=2008:/lib32/ld-uClibc-mipsn8.so.0;:/lib32/ld-uClibc.so.0}"
++  "%{mnan=2008:" SYSTEMLIBS_DIR "ld-uClibc-mipsn8.so.0;:" SYSTEMLIBS_DIR "ld-uClibc.so.0}"
+ 
+ #undef MUSL_DYNAMIC_LINKER32
+ #define MUSL_DYNAMIC_LINKER32 \
+diff --git a/gcc/config/riscv/linux.h b/gcc/config/riscv/linux.h
+index aa8a28d5d..ebf9551c9 100644
+--- a/gcc/config/riscv/linux.h
++++ b/gcc/config/riscv/linux.h
+@@ -22,7 +22,7 @@ along with GCC; see the file COPYING3.
+     GNU_USER_TARGET_OS_CPP_BUILTINS();				\
+   } while (0)
+ 
+-#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux-riscv" XLEN_SPEC "-" ABI_SPEC ".so.1"
++#define GLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-linux-riscv" XLEN_SPEC "-" ABI_SPEC ".so.1"
+ 
+ #define MUSL_ABI_SUFFIX \
+   "%{mabi=ilp32:-sf}" \
+diff --git a/gcc/config/rs6000/linux64.h b/gcc/config/rs6000/linux64.h
+index 90fe6566255..55695dadd91 100644
+--- a/gcc/config/rs6000/linux64.h
++++ b/gcc/config/rs6000/linux64.h
+@@ -420,16 +420,11 @@ extern int dot_symbols;
+ #undef	LINK_OS_DEFAULT_SPEC
+ #define LINK_OS_DEFAULT_SPEC "%(link_os_linux)"
+ 
+-#define GLIBC_DYNAMIC_LINKER32 "%(dynamic_linker_prefix)/lib/ld.so.1"
+-
++#define GLIBC_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld.so.1"
+ #ifdef LINUX64_DEFAULT_ABI_ELFv2
+-#define GLIBC_DYNAMIC_LINKER64 \
+-"%{mabi=elfv1:%(dynamic_linker_prefix)/lib64/ld64.so.1;" \
+-":%(dynamic_linker_prefix)/lib64/ld64.so.2}"
++#define GLIBC_DYNAMIC_LINKER64 "%{mabi=elfv1:" SYSTEMLIBS_DIR "ld64.so.1;:" SYSTEMLIBS_DIR "ld64.so.2}"
+ #else
+-#define GLIBC_DYNAMIC_LINKER64 \
+-"%{mabi=elfv2:%(dynamic_linker_prefix)/lib64/ld64.so.2;" \
+-":%(dynamic_linker_prefix)/lib64/ld64.so.1}"
++#define GLIBC_DYNAMIC_LINKER64 "%{mabi=elfv2:" SYSTEMLIBS_DIR "ld64.so.2;:" SYSTEMLIBS_DIR "ld64.so.1}"
+ #endif
+ 
+ #define MUSL_DYNAMIC_LINKER32 \
+@@ -437,8 +432,9 @@ extern int dot_symbols;
+ #define MUSL_DYNAMIC_LINKER64 \
+   "/lib/ld-musl-powerpc64" MUSL_DYNAMIC_LINKER_E "%{msoft-float:-sf}.so.1"
+ 
+-#define UCLIBC_DYNAMIC_LINKER32 "/lib/ld-uClibc.so.0"
+-#define UCLIBC_DYNAMIC_LINKER64 "/lib/ld64-uClibc.so.0"
++#define UCLIBC_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-uClibc.so.0"
++#define UCLIBC_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld64-uClibc.so.0"
++
+ #if DEFAULT_LIBC == LIBC_UCLIBC
+ #define CHOOSE_DYNAMIC_LINKER(G, U, M) \
+   "%{mglibc:" G ";:%{mmusl:" M ";:" U "}}"
+diff --git a/gcc/config/sh/linux.h b/gcc/config/sh/linux.h
+index 6d2ccd012ba..ec78a89ce15 100644
+--- a/gcc/config/sh/linux.h
++++ b/gcc/config/sh/linux.h
+@@ -64,7 +64,7 @@ along with GCC; see the file COPYING3.  If not see
+   "/lib/ld-musl-sh" MUSL_DYNAMIC_LINKER_E MUSL_DYNAMIC_LINKER_FP \
+   "%{mfdpic:-fdpic}.so.1"
+ 
+-#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
++#define GLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-linux.so.2"
+ 
+ #undef SUBTARGET_LINK_EMUL_SUFFIX
+ #define SUBTARGET_LINK_EMUL_SUFFIX "%{mfdpic:_fd;:_linux}"
+diff --git a/gcc/config/sparc/linux.h b/gcc/config/sparc/linux.h
+index 9fb03af0fe9..401fddbbb22 100644
+--- a/gcc/config/sparc/linux.h
++++ b/gcc/config/sparc/linux.h
+@@ -83,7 +83,7 @@ extern const char *host_detect_local_cpu (int argc, const char **argv);
+    When the -shared link option is used a final link is not being
+    done.  */
+ 
+-#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
++#define GLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-linux.so.2"
+ 
+ #undef  LINK_SPEC
+ #define LINK_SPEC "-m elf32_sparc %{shared:-shared} \
+diff --git a/gcc/config/sparc/linux64.h b/gcc/config/sparc/linux64.h
+index c1fe42165b7..26a79bfa2e3 100644
+--- a/gcc/config/sparc/linux64.h
++++ b/gcc/config/sparc/linux64.h
+@@ -84,8 +84,8 @@ along with GCC; see the file COPYING3.  If not see
+    When the -shared link option is used a final link is not being
+    done.  */
+ 
+-#define GLIBC_DYNAMIC_LINKER32 "/lib/ld-linux.so.2"
+-#define GLIBC_DYNAMIC_LINKER64 "/lib64/ld-linux.so.2"
++#define GLIBC_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-linux.so.2"
++#define GLIBC_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld-linux.so.2"
+ 
+ #ifdef SPARC_BI_ARCH
+ 
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0015-gcc-Fix-argument-list-too-long-error.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0015-gcc-Fix-argument-list-too-long-error.patch
new file mode 100644
index 0000000..4bff842
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0015-gcc-Fix-argument-list-too-long-error.patch
@@ -0,0 +1,40 @@
+From 2e75a14cd60227e036790184f0eb400abc3c870b Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 09:26:37 +0400
+Subject: [PATCH 15/39] gcc: Fix argument list too long error.
+
+There would be an "Argument list too long" error when the
+build directory is longer than 200, this is caused by:
+
+headers=`echo $(PLUGIN_HEADERS) | tr ' ' '\012' | sort -u`
+
+The PLUGIN_HEADERS is too long before sort, so the "echo" can't handle
+it, use the $(sort list) of GNU make which can handle the too long list
+would fix the problem, the header would be short enough after sorted.
+The "tr ' ' '\012'" was used for translating the space to "\n", the
+$(sort list) doesn't need this.
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Pending
+---
+ gcc/Makefile.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/gcc/Makefile.in b/gcc/Makefile.in
+index 1367136bfac..71a8275c39f 100644
+--- a/gcc/Makefile.in
++++ b/gcc/Makefile.in
+@@ -3538,7 +3538,7 @@ install-plugin: installdirs lang.install-plugin s-header-vars install-gengtype
+ # We keep the directory structure for files in config or c-family and .def
+ # files. All other files are flattened to a single directory.
+ 	$(mkinstalldirs) $(DESTDIR)$(plugin_includedir)
+-	headers=`echo $(PLUGIN_HEADERS) $$(cd $(srcdir); echo *.h *.def) | tr ' ' '\012' | sort -u`; \
++	headers="$(sort $(PLUGIN_HEADERS) $$(cd $(srcdir); echo *.h *.def))"; \
+ 	srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`; \
+ 	for file in $$headers; do \
+ 	  if [ -f $$file ] ; then \
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0016-Disable-sdt.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0016-Disable-sdt.patch
new file mode 100644
index 0000000..8197546
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0016-Disable-sdt.patch
@@ -0,0 +1,113 @@
+From 423d87ac47d21e399d759d7ff3b638f0c721a7df Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 09:28:10 +0400
+Subject: [PATCH 16/39] Disable sdt.
+
+We don't list dtrace in DEPENDS so we shouldn't be depending on this header.
+It may or may not exist from preivous builds though. To be determinstic, disable
+sdt.h usage always. This avoids build failures if the header is removed after configure
+but before libgcc is compiled for example.
+
+RP 2012/8/7
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Disable sdt for libstdc++-v3.
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+
+Upstream-Status: Inappropriate [hack]
+---
+ gcc/configure             | 12 ++++++------
+ gcc/configure.ac          | 18 +++++++++---------
+ libstdc++-v3/configure    |  6 +++---
+ libstdc++-v3/configure.ac |  2 +-
+ 4 files changed, 19 insertions(+), 19 deletions(-)
+
+diff --git a/gcc/configure b/gcc/configure
+index a575839c1b2..872338f29b6 100755
+--- a/gcc/configure
++++ b/gcc/configure
+@@ -29296,12 +29296,12 @@ fi
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking sys/sdt.h in the target C library" >&5
+ $as_echo_n "checking sys/sdt.h in the target C library... " >&6; }
+ have_sys_sdt_h=no
+-if test -f $target_header_dir/sys/sdt.h; then
+-  have_sys_sdt_h=yes
+-
+-$as_echo "#define HAVE_SYS_SDT_H 1" >>confdefs.h
+-
+-fi
++#if test -f $target_header_dir/sys/sdt.h; then
++#  have_sys_sdt_h=yes
++#
++#$as_echo "#define HAVE_SYS_SDT_H 1" >>confdefs.h
++#
++#fi
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_sys_sdt_h" >&5
+ $as_echo "$have_sys_sdt_h" >&6; }
+ 
+diff --git a/gcc/configure.ac b/gcc/configure.ac
+index 676116a6d96..55046e68926 100644
+--- a/gcc/configure.ac
++++ b/gcc/configure.ac
+@@ -5957,15 +5957,15 @@ fi
+ AC_SUBST([enable_default_ssp])
+ 
+ # Test for <sys/sdt.h> on the target.
+-GCC_TARGET_TEMPLATE([HAVE_SYS_SDT_H])
+-AC_MSG_CHECKING(sys/sdt.h in the target C library)
+-have_sys_sdt_h=no
+-if test -f $target_header_dir/sys/sdt.h; then
+-  have_sys_sdt_h=yes
+-  AC_DEFINE(HAVE_SYS_SDT_H, 1,
+-            [Define if your target C library provides sys/sdt.h])
+-fi
+-AC_MSG_RESULT($have_sys_sdt_h)
++#GCC_TARGET_TEMPLATE([HAVE_SYS_SDT_H])
++#AC_MSG_CHECKING(sys/sdt.h in the target C library)
++#have_sys_sdt_h=no
++#if test -f $target_header_dir/sys/sdt.h; then
++#  have_sys_sdt_h=yes
++#  AC_DEFINE(HAVE_SYS_SDT_H, 1,
++#            [Define if your target C library provides sys/sdt.h])
++#fi
++#AC_MSG_RESULT($have_sys_sdt_h)
+ 
+ # Check if TFmode long double should be used by default or not.
+ # Some glibc targets used DFmode long double, but with glibc 2.4
+diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure
+index c9dbaa139d5..c64a77d152b 100755
+--- a/libstdc++-v3/configure
++++ b/libstdc++-v3/configure
+@@ -21786,11 +21786,11 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ ac_compiler_gnu=$ac_cv_c_compiler_gnu
+ 
+-  if test $glibcxx_cv_sys_sdt_h = yes; then
++#  if test $glibcxx_cv_sys_sdt_h = yes; then
+ 
+-$as_echo "#define HAVE_SYS_SDT_H 1" >>confdefs.h
++#$as_echo "#define HAVE_SYS_SDT_H 1" >>confdefs.h
+ 
+-  fi
++#  fi
+   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $glibcxx_cv_sys_sdt_h" >&5
+ $as_echo "$glibcxx_cv_sys_sdt_h" >&6; }
+ 
+diff --git a/libstdc++-v3/configure.ac b/libstdc++-v3/configure.ac
+index 0ef96270c9c..afe55a1b215 100644
+--- a/libstdc++-v3/configure.ac
++++ b/libstdc++-v3/configure.ac
+@@ -230,7 +230,7 @@ GLIBCXX_CHECK_SC_NPROCESSORS_ONLN
+ GLIBCXX_CHECK_SC_NPROC_ONLN
+ GLIBCXX_CHECK_PTHREADS_NUM_PROCESSORS_NP
+ GLIBCXX_CHECK_SYSCTL_HW_NCPU
+-GLIBCXX_CHECK_SDT_H
++#GLIBCXX_CHECK_SDT_H
+ 
+ # Check for available headers.
+ AC_CHECK_HEADERS([endian.h execinfo.h float.h fp.h ieeefp.h inttypes.h \
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0017-libtool.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0017-libtool.patch
new file mode 100644
index 0000000..0caa1ce
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0017-libtool.patch
@@ -0,0 +1,42 @@
+From c8b11e96b11910b2d4df6ae8104466e3303d933f Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 09:29:11 +0400
+Subject: [PATCH 17/39] libtool
+
+libstdc++ from gcc-runtime gets created with -rpath=/usr/lib/../lib for qemux86-64
+when running on am x86_64 build host.
+
+This patch stops this speading to libdir in the libstdc++.la file within libtool.
+Arguably, it shouldn't be passing this into libtool in the first place but
+for now this resolves the nastiest problems this causes.
+
+func_normal_abspath would resolve an empty path to `pwd` so we need
+to filter the zero case.
+
+RP 2012/8/24
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Pending
+---
+ ltmain.sh | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/ltmain.sh b/ltmain.sh
+index 9503ec85d70..0121fba707f 100644
+--- a/ltmain.sh
++++ b/ltmain.sh
+@@ -6359,6 +6359,10 @@ func_mode_link ()
+ 	func_warning "ignoring multiple \`-rpath's for a libtool library"
+ 
+       install_libdir="$1"
++      if test -n "$install_libdir"; then
++	func_normal_abspath "$install_libdir"
++	install_libdir=$func_normal_abspath_result
++      fi
+ 
+       oldlibs=
+       if test -z "$rpath"; then
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0018-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0018-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch
new file mode 100644
index 0000000..643cc67
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0018-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch
@@ -0,0 +1,43 @@
+From 7dbba844a59bdf6e7d724f8bfa7927246cb7af8f Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 09:30:32 +0400
+Subject: [PATCH 18/39] gcc: armv4: pass fix-v4bx to linker to support EABI.
+
+The LINK_SPEC for linux gets overwritten by linux-eabi.h which
+means the value of TARGET_FIX_V4BX_SPEC gets lost and as a result
+the option is not passed to linker when chosing march=armv4
+This patch redefines this in linux-eabi.h and reinserts it
+for eabi defaulting toolchains.
+
+We might want to send it upstream.
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Upstream-Status: Pending
+---
+ gcc/config/arm/linux-eabi.h | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+diff --git a/gcc/config/arm/linux-eabi.h b/gcc/config/arm/linux-eabi.h
+index b3af68cac57..330b6e13c5f 100644
+--- a/gcc/config/arm/linux-eabi.h
++++ b/gcc/config/arm/linux-eabi.h
+@@ -88,10 +88,14 @@
+ #define MUSL_DYNAMIC_LINKER \
+   "/lib/ld-musl-arm" MUSL_DYNAMIC_LINKER_E "%{mfloat-abi=hard:hf}.so.1"
+ 
++/* For armv4 we pass --fix-v4bx to linker to support EABI */
++#undef TARGET_FIX_V4BX_SPEC
++#define TARGET_FIX_V4BX_SPEC "%{mcpu=arm8|mcpu=arm810|mcpu=strongarm*|march=armv4: --fix-v4bx}"
++
+ /* At this point, bpabi.h will have clobbered LINK_SPEC.  We want to
+    use the GNU/Linux version, not the generic BPABI version.  */
+ #undef  LINK_SPEC
+-#define LINK_SPEC EABI_LINK_SPEC					\
++#define LINK_SPEC TARGET_FIX_V4BX_SPEC EABI_LINK_SPEC			\
+   LINUX_OR_ANDROID_LD (LINUX_TARGET_LINK_SPEC,				\
+ 		       LINUX_TARGET_LINK_SPEC " " ANDROID_LINK_SPEC)
+ 
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0019-Use-the-multilib-config-files-from-B-instead-of-usin.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0019-Use-the-multilib-config-files-from-B-instead-of-usin.patch
new file mode 100644
index 0000000..0849186
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0019-Use-the-multilib-config-files-from-B-instead-of-usin.patch
@@ -0,0 +1,102 @@
+From 117140acd3c383f620ff75894276001c7405dcce Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Mar 2013 09:33:04 +0400
+Subject: [PATCH 19/39] Use the multilib config files from ${B} instead of
+ using the ones from ${S}
+
+Use the multilib config files from ${B} instead of using the ones from ${S}
+so that the source can be shared between gcc-cross-initial,
+gcc-cross-intermediate, gcc-cross, gcc-runtime, and also the sdk build.
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Constantin Musca <constantinx.musca@intel.com>
+
+Upstream-Status: Inappropriate [configuration]
+---
+ gcc/configure    | 22 ++++++++++++++++++----
+ gcc/configure.ac | 22 ++++++++++++++++++----
+ 2 files changed, 36 insertions(+), 8 deletions(-)
+
+diff --git a/gcc/configure b/gcc/configure
+index 872338f29b6..cfcadc93a01 100755
+--- a/gcc/configure
++++ b/gcc/configure
+@@ -12138,10 +12138,20 @@ done
+ tmake_file_=
+ for f in ${tmake_file}
+ do
+-	if test -f ${srcdir}/config/$f
+-	then
+-		tmake_file_="${tmake_file_} \$(srcdir)/config/$f"
+-	fi
++  case $f in
++    */t-linux64 )
++       if test -f ./config/$f
++       then
++         tmake_file_="${tmake_file_} ./config/$f"
++       fi
++       ;;
++    * )
++       if test -f ${srcdir}/config/$f
++       then
++         tmake_file_="${tmake_file_} \$(srcdir)/config/$f"
++       fi
++       ;;
++  esac
+ done
+ tmake_file="${tmake_file_}"
+ 
+@@ -12152,6 +12162,10 @@ tm_file_list="options.h"
+ tm_include_list="options.h insn-constants.h"
+ for f in $tm_file; do
+   case $f in
++    */linux64.h )
++       tm_file_list="${tm_file_list} ./config/$f"
++       tm_include_list="${tm_include_list} ./config/$f"
++       ;;
+     ./* )
+        f=`echo $f | sed 's/^..//'`
+        tm_file_list="${tm_file_list} $f"
+diff --git a/gcc/configure.ac b/gcc/configure.ac
+index 55046e68926..44b90478f55 100644
+--- a/gcc/configure.ac
++++ b/gcc/configure.ac
+@@ -1902,10 +1902,20 @@ done
+ tmake_file_=
+ for f in ${tmake_file}
+ do
+-	if test -f ${srcdir}/config/$f
+-	then
+-		tmake_file_="${tmake_file_} \$(srcdir)/config/$f"
+-	fi
++  case $f in
++    */t-linux64 )
++       if test -f ./config/$f
++       then
++         tmake_file_="${tmake_file_} ./config/$f"
++       fi
++       ;;
++    * )
++       if test -f ${srcdir}/config/$f
++       then
++         tmake_file_="${tmake_file_} \$(srcdir)/config/$f"
++       fi
++       ;;
++  esac
+ done
+ tmake_file="${tmake_file_}"
+ 
+@@ -1916,6 +1926,10 @@ tm_file_list="options.h"
+ tm_include_list="options.h insn-constants.h"
+ for f in $tm_file; do
+   case $f in
++    */linux64.h )
++       tm_file_list="${tm_file_list} ./config/$f"
++       tm_include_list="${tm_include_list} ./config/$f"
++       ;;
+     ./* )
+        f=`echo $f | sed 's/^..//'`
+        tm_file_list="${tm_file_list} $f"
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0020-Avoid-using-libdir-from-.la-which-usually-points-to-.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0020-Avoid-using-libdir-from-.la-which-usually-points-to-.patch
new file mode 100644
index 0000000..911fe85
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0020-Avoid-using-libdir-from-.la-which-usually-points-to-.patch
@@ -0,0 +1,31 @@
+From a7266111a5ba2d146c979e86ff84f6b807ca5fdc Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 20 Feb 2015 09:39:38 +0000
+Subject: [PATCH 20/39] Avoid using libdir from .la which usually points to a
+ host path
+
+Upstream-Status: Inappropriate [embedded specific]
+
+Signed-off-by: Jonathan Liu <net147@gmail.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ ltmain.sh | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/ltmain.sh b/ltmain.sh
+index 0121fba707f..52bdbdb5f9c 100644
+--- a/ltmain.sh
++++ b/ltmain.sh
+@@ -5628,6 +5628,9 @@ func_mode_link ()
+ 	    absdir="$abs_ladir"
+ 	    libdir="$abs_ladir"
+ 	  else
++	    # Instead of using libdir from .la which usually points to a host path,
++	    # use the path the .la is contained in.
++	    libdir="$abs_ladir"
+ 	    dir="$libdir"
+ 	    absdir="$libdir"
+ 	  fi
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0021-export-CPP.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0021-export-CPP.patch
new file mode 100644
index 0000000..2e6b411
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0021-export-CPP.patch
@@ -0,0 +1,53 @@
+From c8599fc3b5781b319707c9c0f1b0a1ef7cddb027 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 20 Feb 2015 09:40:59 +0000
+Subject: [PATCH 21/39] export CPP
+
+The OE environment sets and exports CPP as being the target gcc. When
+building gcc-cross-canadian for a mingw targetted sdk, the following can be found
+in build.x86_64-pokysdk-mingw32.i586-poky-linux/build-x86_64-linux/libiberty/config.log:
+
+configure:3641: checking for _FILE_OFFSET_BITS value needed for large files
+configure:3666: gcc  -c -isystem/media/build1/poky/build/tmp/sysroots/x86_64-linux/usr/include -O2 -pipe  conftest.c >&5
+configure:3666: $? = 0
+configure:3698: result: no
+configure:3786: checking how to run the C preprocessor
+configure:3856: result: x86_64-pokysdk-mingw32-gcc -E --sysroot=/media/build1/poky/build/tmp/sysroots/x86_64-nativesdk-mingw32-pokysdk-mingw32
+configure:3876: x86_64-pokysdk-mingw32-gcc -E --sysroot=/media/build1/poky/build/tmp/sysroots/x86_64-nativesdk-mingw32-pokysdk-mingw32 conftest.c
+configure:3876: $? = 0
+
+Note this is a *build* target (in build-x86_64-linux) so it should be
+using the host "gcc", not x86_64-pokysdk-mingw32-gcc. Since the mingw32
+headers are very different, using the wrong cpp is a real problem. It is leaking
+into configure through the CPP variable. Ultimately this leads to build
+failures related to not being able to include a process.h file for pem-unix.c.
+
+The fix is to ensure we export a sane CPP value into the build
+environment when using build targets. We could define a CPP_FOR_BUILD value which may be
+the version which needs to be upstreamed but for now, this fix is good enough to
+avoid the problem.
+
+RP 22/08/2013
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ Makefile.in | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/Makefile.in b/Makefile.in
+index 2bf83b72265..1af45580086 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -149,6 +149,7 @@ BUILD_EXPORTS = \
+ 	AR="$(AR_FOR_BUILD)"; export AR; \
+ 	AS="$(AS_FOR_BUILD)"; export AS; \
+ 	CC="$(CC_FOR_BUILD)"; export CC; \
++	CPP="$(CC_FOR_BUILD) -E"; export CPP; \
+ 	CFLAGS="$(CFLAGS_FOR_BUILD)"; export CFLAGS; \
+ 	CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ 	CXX="$(CXX_FOR_BUILD)"; export CXX; \
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0022-Disable-the-MULTILIB_OSDIRNAMES-and-other-multilib-o.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0022-Disable-the-MULTILIB_OSDIRNAMES-and-other-multilib-o.patch
new file mode 100644
index 0000000..17c581f
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0022-Disable-the-MULTILIB_OSDIRNAMES-and-other-multilib-o.patch
@@ -0,0 +1,42 @@
+From 5e2ee46c720b6ce03a18da70dd4e0917c258ab0b Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 20 Feb 2015 10:21:55 +0000
+Subject: [PATCH 22/39] Disable the MULTILIB_OSDIRNAMES and other multilib
+ options.
+
+Hard coding the MULTILIB_OSDIRNAMES with ../lib64 is causing problems on
+systems where the libdir is NOT set to /lib64.  This is allowed by the
+ABI, as
+long as the dynamic loader is present in /lib.
+
+We simply want to use the default rules in gcc to find and configure the
+normal libdir.
+
+Upstream-Status: Inappropriate[OE-Specific]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ gcc/config/aarch64/t-aarch64-linux | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/gcc/config/aarch64/t-aarch64-linux b/gcc/config/aarch64/t-aarch64-linux
+index b9897785a89..7d06f0d0edb 100644
+--- a/gcc/config/aarch64/t-aarch64-linux
++++ b/gcc/config/aarch64/t-aarch64-linux
+@@ -21,8 +21,8 @@
+ LIB1ASMSRC   = aarch64/lib1funcs.asm
+ LIB1ASMFUNCS = _aarch64_sync_cache_range
+ 
+-AARCH_BE = $(if $(findstring TARGET_BIG_ENDIAN_DEFAULT=1, $(tm_defines)),_be)
+-MULTILIB_OSDIRNAMES = mabi.lp64=../lib64$(call if_multiarch,:aarch64$(AARCH_BE)-linux-gnu)
+-MULTIARCH_DIRNAME = $(call if_multiarch,aarch64$(AARCH_BE)-linux-gnu)
++#AARCH_BE = $(if $(findstring TARGET_BIG_ENDIAN_DEFAULT=1, $(tm_defines)),_be)
++#MULTILIB_OSDIRNAMES = mabi.lp64=../lib64$(call if_multiarch,:aarch64$(AARCH_BE)-linux-gnu)
++#MULTIARCH_DIRNAME = $(call if_multiarch,aarch64$(AARCH_BE)-linux-gnu)
+ 
+-MULTILIB_OSDIRNAMES += mabi.ilp32=../libilp32$(call if_multiarch,:aarch64$(AARCH_BE)-linux-gnu_ilp32)
++#MULTILIB_OSDIRNAMES += mabi.ilp32=../libilp32$(call if_multiarch,:aarch64$(AARCH_BE)-linux-gnu_ilp32)
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0023-Ensure-target-gcc-headers-can-be-included.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0023-Ensure-target-gcc-headers-can-be-included.patch
new file mode 100644
index 0000000..4d4da1a
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0023-Ensure-target-gcc-headers-can-be-included.patch
@@ -0,0 +1,98 @@
+From 73766424a2f71b1810fb8afdd863028855d87e5a Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 20 Feb 2015 10:25:11 +0000
+Subject: [PATCH 23/39] Ensure target gcc headers can be included
+
+There are a few headers installed as part of the OpenEmbedded
+gcc-runtime target (omp.h, ssp/*.h). Being installed from a recipe
+built for the target architecture, these are within the target
+sysroot and not cross/nativesdk; thus they weren't able to be
+found by gcc with the existing search paths. Add support for
+picking up these headers under the sysroot supplied on the gcc
+command line in order to resolve this.
+
+Upstream-Status: Pending
+
+Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ gcc/Makefile.in  | 2 ++
+ gcc/cppdefault.c | 4 ++++
+ gcc/defaults.h   | 9 +++++++++
+ gcc/gcc.c        | 7 -------
+ 4 files changed, 15 insertions(+), 7 deletions(-)
+
+diff --git a/gcc/Makefile.in b/gcc/Makefile.in
+index 71a8275c39f..5ae693fb06c 100644
+--- a/gcc/Makefile.in
++++ b/gcc/Makefile.in
+@@ -614,6 +614,7 @@ libexecdir = @libexecdir@
+ 
+ # Directory in which the compiler finds libraries etc.
+ libsubdir = $(libdir)/gcc/$(real_target_noncanonical)/$(version)$(accel_dir_suffix)
++libsubdir_target = gcc/$(target_noncanonical)/$(version)
+ # Directory in which the compiler finds executables
+ libexecsubdir = $(libexecdir)/gcc/$(real_target_noncanonical)/$(version)$(accel_dir_suffix)
+ # Directory in which all plugin resources are installed
+@@ -2870,6 +2871,7 @@ CFLAGS-intl.o += -DLOCALEDIR=\"$(localedir)\"
+ 
+ PREPROCESSOR_DEFINES = \
+   -DGCC_INCLUDE_DIR=\"$(libsubdir)/include\" \
++  -DGCC_INCLUDE_SUBDIR_TARGET=\"$(libsubdir_target)/include\" \
+   -DFIXED_INCLUDE_DIR=\"$(libsubdir)/include-fixed\" \
+   -DGPLUSPLUS_INCLUDE_DIR=\"$(gcc_gxx_include_dir)\" \
+   -DGPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT=$(gcc_gxx_include_dir_add_sysroot) \
+diff --git a/gcc/cppdefault.c b/gcc/cppdefault.c
+index b36a979d5ba..e2e187dedaf 100644
+--- a/gcc/cppdefault.c
++++ b/gcc/cppdefault.c
+@@ -59,6 +59,10 @@ const struct default_include cpp_include_defaults[]
+     /* This is the dir for gcc's private headers.  */
+     { GCC_INCLUDE_DIR, "GCC", 0, 0, 0, 0 },
+ #endif
++#ifdef GCC_INCLUDE_SUBDIR_TARGET
++    /* This is the dir for gcc's private headers under the specified sysroot.  */
++    { STANDARD_STARTFILE_PREFIX_2 GCC_INCLUDE_SUBDIR_TARGET, "GCC", 0, 0, 1, 0 },
++#endif
+ #ifdef LOCAL_INCLUDE_DIR
+     /* /usr/local/include comes before the fixincluded header files.  */
+     { LOCAL_INCLUDE_DIR, 0, 0, 1, 1, 2 },
+diff --git a/gcc/defaults.h b/gcc/defaults.h
+index 78a08a33f12..c8851277674 100644
+--- a/gcc/defaults.h
++++ b/gcc/defaults.h
+@@ -1451,4 +1451,13 @@ see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
+ #define DWARF_GNAT_ENCODINGS_DEFAULT DWARF_GNAT_ENCODINGS_GDB
+ #endif
+ 
++/* Default prefixes to attach to command names.  */
++
++#ifndef STANDARD_STARTFILE_PREFIX_1
++#define STANDARD_STARTFILE_PREFIX_1 "/lib/"
++#endif
++#ifndef STANDARD_STARTFILE_PREFIX_2
++#define STANDARD_STARTFILE_PREFIX_2 "/usr/lib/"
++#endif
++
+ #endif  /* ! GCC_DEFAULTS_H */
+diff --git a/gcc/gcc.c b/gcc/gcc.c
+index 570cdc00034..3fb64d453f1 100644
+--- a/gcc/gcc.c
++++ b/gcc/gcc.c
+@@ -1464,13 +1464,6 @@ static const char *gcc_libexec_prefix;
+ 
+ /* Default prefixes to attach to command names.  */
+ 
+-#ifndef STANDARD_STARTFILE_PREFIX_1
+-#define STANDARD_STARTFILE_PREFIX_1 "/lib/"
+-#endif
+-#ifndef STANDARD_STARTFILE_PREFIX_2
+-#define STANDARD_STARTFILE_PREFIX_2 "/usr/lib/"
+-#endif
+-
+ #ifdef CROSS_DIRECTORY_STRUCTURE  /* Don't use these prefixes for a cross compiler.  */
+ #undef MD_EXEC_PREFIX
+ #undef MD_STARTFILE_PREFIX
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0024-gcc-4.8-won-t-build-with-disable-dependency-tracking.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0024-gcc-4.8-won-t-build-with-disable-dependency-tracking.patch
new file mode 100644
index 0000000..67b47f4
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0024-gcc-4.8-won-t-build-with-disable-dependency-tracking.patch
@@ -0,0 +1,54 @@
+From 57beef69396f6c187014b8e61cdc966218479d07 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 20 Feb 2015 11:17:19 +0000
+Subject: [PATCH 24/39] gcc 4.8+ won't build with --disable-dependency-tracking
+
+since the *.Ppo files don't get created unless --enable-dependency-tracking is true.
+
+This patch ensures we only use those compiler options when its enabled.
+
+Upstream-Status: Submitted
+
+(Problem was already reported upstream, attached this patch there
+http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55930)
+
+RP
+2012/09/22
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ libatomic/Makefile.am | 3 ++-
+ libatomic/Makefile.in | 3 ++-
+ 2 files changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/libatomic/Makefile.am b/libatomic/Makefile.am
+index 803b292cce5..b47842eb590 100644
+--- a/libatomic/Makefile.am
++++ b/libatomic/Makefile.am
+@@ -101,7 +101,8 @@ PAT_S		= $(word 3,$(PAT_SPLIT))
+ IFUNC_DEF	= -DIFUNC_ALT=$(PAT_S)
+ IFUNC_OPT	= $(word $(PAT_S),$(IFUNC_OPTIONS))
+ 
+-M_DEPS		= -MT $@ -MD -MP -MF $(DEPDIR)/$(@F).Ppo
++@AMDEP_TRUE@M_DEPS		= -MT $@ -MD -MP -MF $(DEPDIR)/$(@F).Ppo
++@AMDEP_FALSE@M_DEPS		=
+ M_SIZE		= -DN=$(PAT_N)
+ M_IFUNC		= $(if $(PAT_S),$(IFUNC_DEF) $(IFUNC_OPT))
+ M_FILE		= $(PAT_BASE)_n.c
+diff --git a/libatomic/Makefile.in b/libatomic/Makefile.in
+index c8f38be5835..4fab7cec3ea 100644
+--- a/libatomic/Makefile.in
++++ b/libatomic/Makefile.in
+@@ -335,7 +335,8 @@ PAT_N = $(word 2,$(PAT_SPLIT))
+ PAT_S = $(word 3,$(PAT_SPLIT))
+ IFUNC_DEF = -DIFUNC_ALT=$(PAT_S)
+ IFUNC_OPT = $(word $(PAT_S),$(IFUNC_OPTIONS))
+-M_DEPS = -MT $@ -MD -MP -MF $(DEPDIR)/$(@F).Ppo
++@AMDEP_TRUE@M_DEPS = -MT $@ -MD -MP -MF $(DEPDIR)/$(@F).Ppo
++@AMDEP_FALSE@M_DEPS =
+ M_SIZE = -DN=$(PAT_N)
+ M_IFUNC = $(if $(PAT_S),$(IFUNC_DEF) $(IFUNC_OPT))
+ M_FILE = $(PAT_BASE)_n.c
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0025-Don-t-search-host-directory-during-relink-if-inst_pr.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0025-Don-t-search-host-directory-during-relink-if-inst_pr.patch
new file mode 100644
index 0000000..d8b35bb
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0025-Don-t-search-host-directory-during-relink-if-inst_pr.patch
@@ -0,0 +1,38 @@
+From fd96c9b35c592f1bdd32bc5ae669157473e44063 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 3 Mar 2015 08:21:19 +0000
+Subject: [PATCH 25/39] Don't search host directory during "relink" if
+ $inst_prefix is provided
+
+http://lists.gnu.org/archive/html/libtool-patches/2011-01/msg00026.html
+
+Upstream-Status: Submitted
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ ltmain.sh | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/ltmain.sh b/ltmain.sh
+index 52bdbdb5f9c..82bcec39f05 100644
+--- a/ltmain.sh
++++ b/ltmain.sh
+@@ -6004,12 +6004,13 @@ func_mode_link ()
+ 	      fi
+ 	    else
+ 	      # We cannot seem to hardcode it, guess we'll fake it.
++	      # Default if $libdir is not relative to the prefix:
+ 	      add_dir="-L$libdir"
+-	      # Try looking first in the location we're being installed to.
++
+ 	      if test -n "$inst_prefix_dir"; then
+ 		case $libdir in
+ 		  [\\/]*)
+-		    add_dir="$add_dir -L$inst_prefix_dir$libdir"
++		    add_dir="-L$inst_prefix_dir$libdir"
+ 		    ;;
+ 		esac
+ 	      fi
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0026-Use-SYSTEMLIBS_DIR-replacement-instead-of-hardcoding.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0026-Use-SYSTEMLIBS_DIR-replacement-instead-of-hardcoding.patch
new file mode 100644
index 0000000..d3ab5aa
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0026-Use-SYSTEMLIBS_DIR-replacement-instead-of-hardcoding.patch
@@ -0,0 +1,29 @@
+From c2e400afe8c514357859fca88af4d3e1fcbfe2ff Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 28 Apr 2015 23:15:27 -0700
+Subject: [PATCH 26/39] Use SYSTEMLIBS_DIR replacement instead of hardcoding
+ base_libdir
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ gcc/config/aarch64/aarch64-linux.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/gcc/config/aarch64/aarch64-linux.h b/gcc/config/aarch64/aarch64-linux.h
+index bf1327e98cc..64436183bc8 100644
+--- a/gcc/config/aarch64/aarch64-linux.h
++++ b/gcc/config/aarch64/aarch64-linux.h
+@@ -21,7 +21,7 @@
+ #ifndef GCC_AARCH64_LINUX_H
+ #define GCC_AARCH64_LINUX_H
+ 
+-#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
++#define GLIBC_DYNAMIC_LINKER  SYSTEMLIBS_DIR "ld-linux-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
+ 
+ #undef MUSL_DYNAMIC_LINKER
+ #define MUSL_DYNAMIC_LINKER "/lib/ld-musl-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0027-aarch64-Add-support-for-musl-ldso.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0027-aarch64-Add-support-for-musl-ldso.patch
new file mode 100644
index 0000000..9e5ce8a
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0027-aarch64-Add-support-for-musl-ldso.patch
@@ -0,0 +1,28 @@
+From a2cc175769fd8255750eaecae64e3d1f9c38d48f Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 28 Apr 2015 23:18:39 -0700
+Subject: [PATCH 27/39] aarch64: Add support for musl ldso
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ gcc/config/aarch64/aarch64-linux.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/gcc/config/aarch64/aarch64-linux.h b/gcc/config/aarch64/aarch64-linux.h
+index 64436183bc8..ba156676026 100644
+--- a/gcc/config/aarch64/aarch64-linux.h
++++ b/gcc/config/aarch64/aarch64-linux.h
+@@ -24,7 +24,7 @@
+ #define GLIBC_DYNAMIC_LINKER  SYSTEMLIBS_DIR "ld-linux-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
+ 
+ #undef MUSL_DYNAMIC_LINKER
+-#define MUSL_DYNAMIC_LINKER "/lib/ld-musl-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
++#define MUSL_DYNAMIC_LINKER  SYSTEMLIBS_DIR "ld-musl-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
+ 
+ #undef  ASAN_CC1_SPEC
+ #define ASAN_CC1_SPEC "%{%:sanitize(address):-funwind-tables}"
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0028-libcc1-fix-libcc1-s-install-path-and-rpath.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0028-libcc1-fix-libcc1-s-install-path-and-rpath.patch
new file mode 100644
index 0000000..2673f4e
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0028-libcc1-fix-libcc1-s-install-path-and-rpath.patch
@@ -0,0 +1,54 @@
+From a8a8a02788ff98f253ce0b33adcb0e661d24b1e3 Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Sun, 5 Jul 2015 20:25:18 -0700
+Subject: [PATCH 28/39] libcc1: fix libcc1's install path and rpath
+
+* Install libcc1.so and libcc1plugin.so into
+  $(libexecdir)/gcc/$(target_noncanonical)/$(gcc_version), as what we
+  had done to lto-plugin.
+* Fix bad RPATH iussue:
+  gcc-5.2.0: package gcc-plugins contains bad RPATH /patht/to/tmp/sysroots/qemux86-64/usr/lib64/../lib64 in file
+ /path/to/gcc/5.2.0-r0/packages-split/gcc-plugins/usr/lib64/gcc/x86_64-poky-linux/5.2.0/plugin/libcc1plugin.so.0.0.0
+ [rpaths]
+
+Upstream-Status: Inappropriate [OE configuration]
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ libcc1/Makefile.am | 4 ++--
+ libcc1/Makefile.in | 4 ++--
+ 2 files changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/libcc1/Makefile.am b/libcc1/Makefile.am
+index 6ecb66b4365..634cce3c2a9 100644
+--- a/libcc1/Makefile.am
++++ b/libcc1/Makefile.am
+@@ -37,8 +37,8 @@ libiberty = $(if $(wildcard $(libiberty_noasan)),$(Wc)$(libiberty_noasan), \
+ 	    $(Wc)$(libiberty_normal)))
+ libiberty_dep = $(patsubst $(Wc)%,%,$(libiberty))
+ 
+-plugindir = $(libdir)/gcc/$(target_noncanonical)/$(gcc_version)/plugin
+-cc1libdir = $(libdir)/$(libsuffix)
++cc1libdir = $(libexecdir)/gcc/$(target_noncanonical)/$(gcc_version)
++plugindir = $(cc1libdir)
+ 
+ if ENABLE_PLUGIN
+ plugin_LTLIBRARIES = libcc1plugin.la libcp1plugin.la
+diff --git a/libcc1/Makefile.in b/libcc1/Makefile.in
+index 47be10025ad..8d5481d87bd 100644
+--- a/libcc1/Makefile.in
++++ b/libcc1/Makefile.in
+@@ -303,8 +303,8 @@ libiberty = $(if $(wildcard $(libiberty_noasan)),$(Wc)$(libiberty_noasan), \
+ 	    $(Wc)$(libiberty_normal)))
+ 
+ libiberty_dep = $(patsubst $(Wc)%,%,$(libiberty))
+-plugindir = $(libdir)/gcc/$(target_noncanonical)/$(gcc_version)/plugin
+-cc1libdir = $(libdir)/$(libsuffix)
++cc1libdir = $(libexecdir)/gcc/$(target_noncanonical)/$(gcc_version)
++plugindir = $(cc1libdir)
+ @ENABLE_PLUGIN_TRUE@plugin_LTLIBRARIES = libcc1plugin.la libcp1plugin.la
+ @ENABLE_PLUGIN_TRUE@cc1lib_LTLIBRARIES = libcc1.la
+ shared_source = callbacks.cc callbacks.hh connection.cc connection.hh \
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0029-handle-sysroot-support-for-nativesdk-gcc.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0029-handle-sysroot-support-for-nativesdk-gcc.patch
new file mode 100644
index 0000000..727bb0d
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0029-handle-sysroot-support-for-nativesdk-gcc.patch
@@ -0,0 +1,213 @@
+From 3bb74495e45e0e798daae5556497e688b8fc4eef Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 7 Dec 2015 23:39:54 +0000
+Subject: [PATCH 29/39] handle sysroot support for nativesdk-gcc
+
+Being able to build a nativesdk gcc is useful, particularly in cases
+where the host compiler may be of an incompatible version (or a 32
+bit compiler is needed).
+
+Sadly, building nativesdk-gcc is not straight forward. We install
+nativesdk-gcc into a relocatable location and this means that its
+library locations can change. "Normal" sysroot support doesn't help
+in this case since the values of paths like "libdir" change, not just
+base root directory of the system.
+
+In order to handle this we do two things:
+
+a) Add %r into spec file markup which can be used for injected paths
+   such as SYSTEMLIBS_DIR (see gcc_multilib_setup()).
+b) Add other paths which need relocation into a .gccrelocprefix section
+   which the relocation code will notice and adjust automatically.
+
+Upstream-Status: Inappropriate
+RP 2015/7/28
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ gcc/cppdefault.c | 50 +++++++++++++++++++++++++++++++++++-------------
+ gcc/cppdefault.h |  3 ++-
+ gcc/gcc.c        | 20 +++++++++++++------
+ 3 files changed, 53 insertions(+), 20 deletions(-)
+
+diff --git a/gcc/cppdefault.c b/gcc/cppdefault.c
+index e2e187dedaf..2faba2b1d63 100644
+--- a/gcc/cppdefault.c
++++ b/gcc/cppdefault.c
+@@ -35,6 +35,30 @@
+ # undef CROSS_INCLUDE_DIR
+ #endif
+ 
++static char GPLUSPLUS_INCLUDE_DIRVAR[4096] __attribute__ ((section (".gccrelocprefix"))) = GPLUSPLUS_INCLUDE_DIR;
++static char GCC_INCLUDE_DIRVAR[4096] __attribute__ ((section (".gccrelocprefix"))) = GCC_INCLUDE_DIR;
++static char GPLUSPLUS_TOOL_INCLUDE_DIRVAR[4096] __attribute__ ((section (".gccrelocprefix"))) = GPLUSPLUS_TOOL_INCLUDE_DIR;
++static char GPLUSPLUS_BACKWARD_INCLUDE_DIRVAR[4096] __attribute__ ((section (".gccrelocprefix"))) = GPLUSPLUS_BACKWARD_INCLUDE_DIR;
++static char STANDARD_STARTFILE_PREFIX_2VAR[4096] __attribute__ ((section (".gccrelocprefix"))) = STANDARD_STARTFILE_PREFIX_2 GCC_INCLUDE_SUBDIR_TARGET;
++#ifdef LOCAL_INCLUDE_DIR
++static char LOCAL_INCLUDE_DIRVAR[4096] __attribute__ ((section (".gccrelocprefix"))) = LOCAL_INCLUDE_DIR;
++#endif
++#ifdef PREFIX_INCLUDE_DIR
++static char PREFIX_INCLUDE_DIRVAR[4096] __attribute__ ((section (".gccrelocprefix"))) = PREFIX_INCLUDE_DIR;
++#endif
++#ifdef FIXED_INCLUDE_DIR
++static char FIXED_INCLUDE_DIRVAR[4096] __attribute__ ((section (".gccrelocprefix"))) = FIXED_INCLUDE_DIR;
++#endif
++#ifdef CROSS_INCLUDE_DIR
++static char CROSS_INCLUDE_DIRVAR[4096] __attribute__ ((section (".gccrelocprefix"))) = CROSS_INCLUDE_DIR;
++#endif
++#ifdef TOOL_INCLUDE_DIR
++static char TOOL_INCLUDE_DIRVAR[4096] __attribute__ ((section (".gccrelocprefix"))) = TOOL_INCLUDE_DIR;
++#endif
++#ifdef NATIVE_SYSTEM_HEADER_DIR
++static char NATIVE_SYSTEM_HEADER_DIRVAR[4096] __attribute__ ((section (".gccrelocprefix"))) = NATIVE_SYSTEM_HEADER_DIR;
++#endif
++
+ const struct default_include cpp_include_defaults[]
+ #ifdef INCLUDE_DEFAULTS
+ = INCLUDE_DEFAULTS;
+@@ -42,38 +66,38 @@ const struct default_include cpp_include_defaults[]
+ = {
+ #ifdef GPLUSPLUS_INCLUDE_DIR
+     /* Pick up GNU C++ generic include files.  */
+-    { GPLUSPLUS_INCLUDE_DIR, "G++", 1, 1,
++    { GPLUSPLUS_INCLUDE_DIRVAR, "G++", 1, 1,
+       GPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT, 0 },
+ #endif
+ #ifdef GPLUSPLUS_TOOL_INCLUDE_DIR
+     /* Pick up GNU C++ target-dependent include files.  */
+-    { GPLUSPLUS_TOOL_INCLUDE_DIR, "G++", 1, 1,
++    { GPLUSPLUS_TOOL_INCLUDE_DIRVAR, "G++", 1, 1,
+       GPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT, 1 },
+ #endif
+ #ifdef GPLUSPLUS_BACKWARD_INCLUDE_DIR
+     /* Pick up GNU C++ backward and deprecated include files.  */
+-    { GPLUSPLUS_BACKWARD_INCLUDE_DIR, "G++", 1, 1,
++    { GPLUSPLUS_BACKWARD_INCLUDE_DIRVAR, "G++", 1, 1,
+       GPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT, 0 },
+ #endif
+ #ifdef GCC_INCLUDE_DIR
+     /* This is the dir for gcc's private headers.  */
+-    { GCC_INCLUDE_DIR, "GCC", 0, 0, 0, 0 },
++    { GCC_INCLUDE_DIRVAR, "GCC", 0, 0, 0, 0 },
+ #endif
+ #ifdef GCC_INCLUDE_SUBDIR_TARGET
+     /* This is the dir for gcc's private headers under the specified sysroot.  */
+-    { STANDARD_STARTFILE_PREFIX_2 GCC_INCLUDE_SUBDIR_TARGET, "GCC", 0, 0, 1, 0 },
++    { STANDARD_STARTFILE_PREFIX_2VAR, "GCC", 0, 0, 1, 0 },
+ #endif
+ #ifdef LOCAL_INCLUDE_DIR
+     /* /usr/local/include comes before the fixincluded header files.  */
+-    { LOCAL_INCLUDE_DIR, 0, 0, 1, 1, 2 },
+-    { LOCAL_INCLUDE_DIR, 0, 0, 1, 1, 0 },
++    { LOCAL_INCLUDE_DIRVAR, 0, 0, 1, 1, 2 },
++    { LOCAL_INCLUDE_DIRVAR, 0, 0, 1, 1, 0 },
+ #endif
+ #ifdef PREFIX_INCLUDE_DIR
+-    { PREFIX_INCLUDE_DIR, 0, 0, 1, 0, 0 },
++    { PREFIX_INCLUDE_DIRVAR, 0, 0, 1, 0, 0 },
+ #endif
+ #ifdef FIXED_INCLUDE_DIR
+     /* This is the dir for fixincludes.  */
+-    { FIXED_INCLUDE_DIR, "GCC", 0, 0, 0,
++    { FIXED_INCLUDE_DIRVAR, "GCC", 0, 0, 0,
+       /* A multilib suffix needs adding if different multilibs use
+ 	 different headers.  */
+ #ifdef SYSROOT_HEADERS_SUFFIX_SPEC
+@@ -85,16 +109,16 @@ const struct default_include cpp_include_defaults[]
+ #endif
+ #ifdef CROSS_INCLUDE_DIR
+     /* One place the target system's headers might be.  */
+-    { CROSS_INCLUDE_DIR, "GCC", 0, 0, 0, 0 },
++    { CROSS_INCLUDE_DIRVAR, "GCC", 0, 0, 0, 0 },
+ #endif
+ #ifdef TOOL_INCLUDE_DIR
+     /* Another place the target system's headers might be.  */
+-    { TOOL_INCLUDE_DIR, "BINUTILS", 0, 1, 0, 0 },
++    { TOOL_INCLUDE_DIRVAR, "BINUTILS", 0, 1, 0, 0 },
+ #endif
+ #ifdef NATIVE_SYSTEM_HEADER_DIR
+     /* /usr/include comes dead last.  */
+-    { NATIVE_SYSTEM_HEADER_DIR, NATIVE_SYSTEM_HEADER_COMPONENT, 0, 0, 1, 2 },
+-    { NATIVE_SYSTEM_HEADER_DIR, NATIVE_SYSTEM_HEADER_COMPONENT, 0, 0, 1, 0 },
++    { NATIVE_SYSTEM_HEADER_DIRVAR, NATIVE_SYSTEM_HEADER_COMPONENT, 0, 0, 1, 2 },
++    { NATIVE_SYSTEM_HEADER_DIRVAR, NATIVE_SYSTEM_HEADER_COMPONENT, 0, 0, 1, 0 },
+ #endif
+     { 0, 0, 0, 0, 0, 0 }
+   };
+diff --git a/gcc/cppdefault.h b/gcc/cppdefault.h
+index 4a0186d1cf2..29e5d9da0dc 100644
+--- a/gcc/cppdefault.h
++++ b/gcc/cppdefault.h
+@@ -33,7 +33,8 @@
+ 
+ struct default_include
+ {
+-  const char *const fname;	/* The name of the directory.  */
++  const char *fname;     /* The name of the directory.  */
++
+   const char *const component;	/* The component containing the directory
+ 				   (see update_path in prefix.c) */
+   const char cplusplus;		/* Only look here if we're compiling C++.  */
+diff --git a/gcc/gcc.c b/gcc/gcc.c
+index 3fb64d453f1..cd0c7fbe961 100644
+--- a/gcc/gcc.c
++++ b/gcc/gcc.c
+@@ -248,6 +248,8 @@ FILE *report_times_to_file = NULL;
+ #endif
+ static const char *target_system_root = DEFAULT_TARGET_SYSTEM_ROOT;
+ 
++static char target_relocatable_prefix[4096] __attribute__ ((section (".gccrelocprefix"))) = SYSTEMLIBS_DIR;
++
+ /* Nonzero means pass the updated target_system_root to the compiler.  */
+ 
+ static int target_system_root_changed;
+@@ -519,6 +521,7 @@ or with constant text in a single argument.
+  %G     process LIBGCC_SPEC as a spec.
+  %R     Output the concatenation of target_system_root and
+         target_sysroot_suffix.
++ %r     Output the base path target_relocatable_prefix
+  %S     process STARTFILE_SPEC as a spec.  A capital S is actually used here.
+  %E     process ENDFILE_SPEC as a spec.  A capital E is actually used here.
+  %C     process CPP_SPEC as a spec.
+@@ -1487,10 +1490,10 @@ static const char *gcc_libexec_prefix;
+    gcc_exec_prefix is set because, in that case, we know where the
+    compiler has been installed, and use paths relative to that
+    location instead.  */
+-static const char *const standard_exec_prefix = STANDARD_EXEC_PREFIX;
+-static const char *const standard_libexec_prefix = STANDARD_LIBEXEC_PREFIX;
+-static const char *const standard_bindir_prefix = STANDARD_BINDIR_PREFIX;
+-static const char *const standard_startfile_prefix = STANDARD_STARTFILE_PREFIX;
++static char standard_exec_prefix[4096] __attribute__ ((section (".gccrelocprefix"))) = STANDARD_EXEC_PREFIX;
++static char standard_libexec_prefix[4096] __attribute__ ((section (".gccrelocprefix"))) = STANDARD_LIBEXEC_PREFIX;
++static char standard_bindir_prefix[4096] __attribute__ ((section (".gccrelocprefix"))) = STANDARD_BINDIR_PREFIX;
++static char *const standard_startfile_prefix = STANDARD_STARTFILE_PREFIX;
+ 
+ /* For native compilers, these are well-known paths containing
+    components that may be provided by the system.  For cross
+@@ -1498,9 +1501,9 @@ static const char *const standard_startfile_prefix = STANDARD_STARTFILE_PREFIX;
+ static const char *md_exec_prefix = MD_EXEC_PREFIX;
+ static const char *md_startfile_prefix = MD_STARTFILE_PREFIX;
+ static const char *md_startfile_prefix_1 = MD_STARTFILE_PREFIX_1;
+-static const char *const standard_startfile_prefix_1
++static char standard_startfile_prefix_1[4096] __attribute__ ((section (".gccrelocprefix")))
+   = STANDARD_STARTFILE_PREFIX_1;
+-static const char *const standard_startfile_prefix_2
++static char standard_startfile_prefix_2[4096] __attribute__ ((section (".gccrelocprefix")))
+   = STANDARD_STARTFILE_PREFIX_2;
+ 
+ /* A relative path to be used in finding the location of tools
+@@ -5849,6 +5852,11 @@ do_spec_1 (const char *spec, int inswitch, const char *soft_matched_part)
+ 	      }
+ 	    break;
+ 
++          case 'r':
++              obstack_grow (&obstack, target_relocatable_prefix,
++		      strlen (target_relocatable_prefix));
++            break;
++
+ 	  case 'S':
+ 	    value = do_spec_1 (startfile_spec, 0, NULL);
+ 	    if (value != 0)
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0030-Search-target-sysroot-gcc-version-specific-dirs-with.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0030-Search-target-sysroot-gcc-version-specific-dirs-with.patch
new file mode 100644
index 0000000..33566df
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0030-Search-target-sysroot-gcc-version-specific-dirs-with.patch
@@ -0,0 +1,102 @@
+From f5cc8cd0c44092dc487106ade27e011c1f584ada Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 7 Dec 2015 23:41:45 +0000
+Subject: [PATCH 30/39] Search target sysroot gcc version specific dirs with
+ multilib.
+
+We install the gcc libraries (such as crtbegin.p) into
+<sysroot><libdir>/<target-sys>/5.2.0/
+which is a default search path for GCC (aka multi_suffix in the
+code below). <target-sys> is 'machine' in gcc's terminology. We use
+these directories so that multiple gcc versions could in theory
+co-exist on target.
+
+We only want to build one gcc-cross-canadian per arch and have this work
+for all multilibs. <target-sys> can be handled by mapping the multilib
+<target-sys> to the one used by gcc-cross-canadian, e.g.
+mips64-polkmllib32-linux
+is symlinked to by mips64-poky-linux.
+
+The default gcc search path in the target sysroot for a "lib64" mutlilib
+is:
+
+<sysroot>/lib32/mips64-poky-linux/5.2.0/
+<sysroot>/lib32/../lib64/
+<sysroot>/usr/lib32/mips64-poky-linux/5.2.0/
+<sysroot>/usr/lib32/../lib64/
+<sysroot>/lib32/
+<sysroot>/usr/lib32/
+
+which means that the lib32 crtbegin.o will be found and the lib64 ones
+will not which leads to compiler failures.
+
+This patch injects a multilib version of that path first so the lib64
+binaries can be found first. With this change the search path becomes:
+
+<sysroot>/lib32/../lib64/mips64-poky-linux/5.2.0/
+<sysroot>/lib32/mips64-poky-linux/5.2.0/
+<sysroot>/lib32/../lib64/
+<sysroot>/usr/lib32/../lib64/mips64-poky-linux/5.2.0/
+<sysroot>/usr/lib32/mips64-poky-linux/5.2.0/
+<sysroot>/usr/lib32/../lib64/
+<sysroot>/lib32/
+<sysroot>/usr/lib32/
+
+Upstream-Status: Pending
+RP 2015/7/31
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ gcc/gcc.c | 29 ++++++++++++++++++++++++++++-
+ 1 file changed, 28 insertions(+), 1 deletion(-)
+
+diff --git a/gcc/gcc.c b/gcc/gcc.c
+index cd0c7fbe961..f6f3aa077c8 100644
+--- a/gcc/gcc.c
++++ b/gcc/gcc.c
+@@ -2527,7 +2527,7 @@ for_each_path (const struct path_prefix *paths,
+       if (path == NULL)
+ 	{
+ 	  len = paths->max_len + extra_space + 1;
+-	  len += MAX (MAX (suffix_len, multi_os_dir_len), multiarch_len);
++	  len += MAX ((suffix_len + multi_os_dir_len), multiarch_len);
+ 	  path = XNEWVEC (char, len);
+ 	}
+ 
+@@ -2539,6 +2539,33 @@ for_each_path (const struct path_prefix *paths,
+ 	  /* Look first in MACHINE/VERSION subdirectory.  */
+ 	  if (!skip_multi_dir)
+ 	    {
++	      if (!(pl->os_multilib ? skip_multi_os_dir : skip_multi_dir))
++	        {
++	          const char *this_multi;
++	          size_t this_multi_len;
++
++	          if (pl->os_multilib)
++		    {
++		      this_multi = multi_os_dir;
++		      this_multi_len = multi_os_dir_len;
++		    }
++	          else
++		    {
++		      this_multi = multi_dir;
++		      this_multi_len = multi_dir_len;
++		    }
++
++	          /* Look in multilib MACHINE/VERSION subdirectory first */
++	          if (this_multi_len)
++	            {
++		      memcpy (path + len, this_multi, this_multi_len + 1);
++	              memcpy (path + len + this_multi_len, multi_suffix, suffix_len + 1);
++	              ret = callback (path, callback_info);
++	                if (ret)
++		          break;
++	            }
++	        }
++
+ 	      memcpy (path + len, multi_suffix, suffix_len + 1);
+ 	      ret = callback (path, callback_info);
+ 	      if (ret)
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0031-Fix-various-_FOR_BUILD-and-related-variables.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0031-Fix-various-_FOR_BUILD-and-related-variables.patch
new file mode 100644
index 0000000..dabc005
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0031-Fix-various-_FOR_BUILD-and-related-variables.patch
@@ -0,0 +1,137 @@
+From 93b4e1d3a0f8417118d1c48fcd1ce51996e1420b Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 7 Dec 2015 23:42:45 +0000
+Subject: [PATCH 31/39] Fix various _FOR_BUILD and related variables
+
+When doing a FOR_BUILD thing, you have to override CFLAGS with
+CFLAGS_FOR_BUILD. And if you use C++, you also have to override
+CXXFLAGS with CXXFLAGS_FOR_BUILD.
+Without this, when building for mingw, you end up trying to use
+the mingw headers for a host build.
+
+The same goes for other variables as well, such as CPPFLAGS,
+CPP, and GMPINC.
+
+Upstream-Status: Pending
+
+Signed-off-by: Peter Seebach <peter.seebach@windriver.com>
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ Makefile.in      | 6 ++++++
+ Makefile.tpl     | 5 +++++
+ gcc/Makefile.in  | 2 +-
+ gcc/configure    | 2 +-
+ gcc/configure.ac | 2 +-
+ 5 files changed, 14 insertions(+), 3 deletions(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index 1af45580086..8966453c32c 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -152,6 +152,7 @@ BUILD_EXPORTS = \
+ 	CPP="$(CC_FOR_BUILD) -E"; export CPP; \
+ 	CFLAGS="$(CFLAGS_FOR_BUILD)"; export CFLAGS; \
+ 	CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
++	CPPFLAGS="$(CPPFLAGS_FOR_BUILD)"; export CPPFLAGS; \
+ 	CXX="$(CXX_FOR_BUILD)"; export CXX; \
+ 	CXXFLAGS="$(CXXFLAGS_FOR_BUILD)"; export CXXFLAGS; \
+ 	GFORTRAN="$(GFORTRAN_FOR_BUILD)"; export GFORTRAN; \
+@@ -169,6 +170,9 @@ BUILD_EXPORTS = \
+ # built for the build system to override those in BASE_FLAGS_TO_PASS.
+ EXTRA_BUILD_FLAGS = \
+ 	CFLAGS="$(CFLAGS_FOR_BUILD)" \
++	CXXFLAGS="$(CXXFLAGS_FOR_BUILD)" \
++	CPP="$(CC_FOR_BUILD) -E" \
++	CPPFLAGS="$(CPPFLAGS_FOR_BUILD)" \
+ 	LDFLAGS="$(LDFLAGS_FOR_BUILD)"
+ 
+ # This is the list of directories to built for the host system.
+@@ -186,6 +190,7 @@ HOST_SUBDIR = @host_subdir@
+ HOST_EXPORTS = \
+ 	$(BASE_EXPORTS) \
+ 	CC="$(CC)"; export CC; \
++	CPP="$(CC) -E"; export CPP; \
+ 	ADA_CFLAGS="$(ADA_CFLAGS)"; export ADA_CFLAGS; \
+ 	CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ 	CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+@@ -753,6 +758,7 @@ BASE_FLAGS_TO_PASS = \
+ 	"CC_FOR_BUILD=$(CC_FOR_BUILD)" \
+ 	"CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
+ 	"CXX_FOR_BUILD=$(CXX_FOR_BUILD)" \
++	"CXXFLAGS_FOR_BUILD=$(CXXFLAGS_FOR_BUILD)" \
+ 	"EXPECT=$(EXPECT)" \
+ 	"FLEX=$(FLEX)" \
+ 	"INSTALL=$(INSTALL)" \
+diff --git a/Makefile.tpl b/Makefile.tpl
+index abd2bc2fb89..5822b260404 100644
+--- a/Makefile.tpl
++++ b/Makefile.tpl
+@@ -154,6 +154,7 @@ BUILD_EXPORTS = \
+ 	CC="$(CC_FOR_BUILD)"; export CC; \
+ 	CFLAGS="$(CFLAGS_FOR_BUILD)"; export CFLAGS; \
+ 	CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
++	CPPFLAGS="$(CPPFLAGS_FOR_BUILD)"; export CPPFLAGS; \
+ 	CXX="$(CXX_FOR_BUILD)"; export CXX; \
+ 	CXXFLAGS="$(CXXFLAGS_FOR_BUILD)"; export CXXFLAGS; \
+ 	GFORTRAN="$(GFORTRAN_FOR_BUILD)"; export GFORTRAN; \
+@@ -171,6 +172,9 @@ BUILD_EXPORTS = \
+ # built for the build system to override those in BASE_FLAGS_TO_PASS.
+ EXTRA_BUILD_FLAGS = \
+ 	CFLAGS="$(CFLAGS_FOR_BUILD)" \
++	CXXFLAGS="$(CXXFLAGS_FOR_BUILD)" \
++	CPP="$(CC_FOR_BUILD) -E" \
++	CPPFLAGS="$(CPPFLAGS_FOR_BUILD)" \
+ 	LDFLAGS="$(LDFLAGS_FOR_BUILD)"
+ 
+ # This is the list of directories to built for the host system.
+@@ -188,6 +192,7 @@ HOST_SUBDIR = @host_subdir@
+ HOST_EXPORTS = \
+ 	$(BASE_EXPORTS) \
+ 	CC="$(CC)"; export CC; \
++	CPP="$(CC) -E"; export CPP; \
+ 	ADA_CFLAGS="$(ADA_CFLAGS)"; export ADA_CFLAGS; \
+ 	CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ 	CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+diff --git a/gcc/Makefile.in b/gcc/Makefile.in
+index 5ae693fb06c..02ee0aa72f4 100644
+--- a/gcc/Makefile.in
++++ b/gcc/Makefile.in
+@@ -801,7 +801,7 @@ BUILD_LDFLAGS=@BUILD_LDFLAGS@
+ BUILD_NO_PIE_FLAG = @BUILD_NO_PIE_FLAG@
+ BUILD_LDFLAGS += $(BUILD_NO_PIE_FLAG)
+ BUILD_CPPFLAGS= -I. -I$(@D) -I$(srcdir) -I$(srcdir)/$(@D) \
+-		-I$(srcdir)/../include @INCINTL@ $(CPPINC) $(CPPFLAGS)
++		-I$(srcdir)/../include @INCINTL@ $(CPPINC) $(CPPFLAGS_FOR_BUILD)
+ 
+ # Actual name to use when installing a native compiler.
+ GCC_INSTALL_NAME := $(shell echo gcc|sed '$(program_transform_name)')
+diff --git a/gcc/configure b/gcc/configure
+index cfcadc93a01..2f6b4f72ef3 100755
+--- a/gcc/configure
++++ b/gcc/configure
+@@ -11797,7 +11797,7 @@ else
+ 	CC="${CC_FOR_BUILD}" CFLAGS="${CFLAGS_FOR_BUILD}" \
+ 	CXX="${CXX_FOR_BUILD}" CXXFLAGS="${CXXFLAGS_FOR_BUILD}" \
+ 	LD="${LD_FOR_BUILD}" LDFLAGS="${LDFLAGS_FOR_BUILD}" \
+-	GMPINC="" CPPFLAGS="${CPPFLAGS} -DGENERATOR_FILE" \
++	GMPINC="" CPPFLAGS="${CPPFLAGS_FOR_BUILD} -DGENERATOR_FILE" \
+ 	${realsrcdir}/configure \
+ 		--enable-languages=${enable_languages-all} \
+ 		--target=$target_alias --host=$build_alias --build=$build_alias
+diff --git a/gcc/configure.ac b/gcc/configure.ac
+index 44b90478f55..9f8a51fc9bd 100644
+--- a/gcc/configure.ac
++++ b/gcc/configure.ac
+@@ -1708,7 +1708,7 @@ else
+ 	CC="${CC_FOR_BUILD}" CFLAGS="${CFLAGS_FOR_BUILD}" \
+ 	CXX="${CXX_FOR_BUILD}" CXXFLAGS="${CXXFLAGS_FOR_BUILD}" \
+ 	LD="${LD_FOR_BUILD}" LDFLAGS="${LDFLAGS_FOR_BUILD}" \
+-	GMPINC="" CPPFLAGS="${CPPFLAGS} -DGENERATOR_FILE" \
++	GMPINC="" CPPFLAGS="${CPPFLAGS_FOR_BUILD} -DGENERATOR_FILE" \
+ 	${realsrcdir}/configure \
+ 		--enable-languages=${enable_languages-all} \
+ 		--target=$target_alias --host=$build_alias --build=$build_alias
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0032-nios2-Define-MUSL_DYNAMIC_LINKER.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0032-nios2-Define-MUSL_DYNAMIC_LINKER.patch
new file mode 100644
index 0000000..6dd9d54
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0032-nios2-Define-MUSL_DYNAMIC_LINKER.patch
@@ -0,0 +1,28 @@
+From 99f3e3b427996ac579d95e68440a0bd7af7ef0fc Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 2 Feb 2016 10:26:10 -0800
+Subject: [PATCH 32/39] nios2: Define MUSL_DYNAMIC_LINKER
+
+Signed-off-by: Marek Vasut <marex@denx.de>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ gcc/config/nios2/linux.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/gcc/config/nios2/linux.h b/gcc/config/nios2/linux.h
+index 4729105626d..36181eb7b85 100644
+--- a/gcc/config/nios2/linux.h
++++ b/gcc/config/nios2/linux.h
+@@ -30,6 +30,7 @@
+ #define CPP_SPEC "%{posix:-D_POSIX_SOURCE} %{pthread:-D_REENTRANT}"
+ 
+ #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux-nios2.so.1"
++#define MUSL_DYNAMIC_LINKER  "/lib/ld-musl-nios2.so.1"
+ 
+ #undef LINK_SPEC
+ #define LINK_SPEC LINK_SPEC_ENDIAN \
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0033-Add-ssp_nonshared-to-link-commandline-for-musl-targe.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0033-Add-ssp_nonshared-to-link-commandline-for-musl-targe.patch
new file mode 100644
index 0000000..05a6b0a
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0033-Add-ssp_nonshared-to-link-commandline-for-musl-targe.patch
@@ -0,0 +1,87 @@
+From 84b55ab2f68710a583d4ec810ea8b3b68576f8aa Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 27 Jun 2017 18:10:54 -0700
+Subject: [PATCH 33/39] Add ssp_nonshared to link commandline for musl targets
+
+when -fstack-protector options are enabled we need to
+link with ssp_shared on musl since it does not provide
+the __stack_chk_fail_local() so essentially it provides
+libssp but not libssp_nonshared something like
+TARGET_LIBC_PROVIDES_SSP_BUT_NOT_SSP_NONSHARED
+ where-as for glibc the needed symbols
+are already present in libc_nonshared library therefore
+we do not need any library helper on glibc based systems
+but musl needs the libssp_noshared from gcc
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ gcc/config/linux.h          |  7 +++++++
+ gcc/config/rs6000/linux.h   | 10 ++++++++++
+ gcc/config/rs6000/linux64.h | 10 ++++++++++
+ 3 files changed, 27 insertions(+)
+
+diff --git a/gcc/config/linux.h b/gcc/config/linux.h
+index 487b0c0923b..4769d089538 100644
+--- a/gcc/config/linux.h
++++ b/gcc/config/linux.h
+@@ -182,6 +182,13 @@ see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
+     { GCC_INCLUDE_DIR, "GCC", 0, 1, 0, 0 },		\
+     { 0, 0, 0, 0, 0, 0 }				\
+   }
++#ifdef TARGET_LIBC_PROVIDES_SSP
++#undef LINK_SSP_SPEC
++#define LINK_SSP_SPEC "%{fstack-protector|fstack-protector-all" \
++		       "|fstack-protector-strong|fstack-protector-explicit" \
++		       ":-lssp_nonshared}"
++#endif
++
+ #endif
+ 
+ #if (DEFAULT_LIBC == LIBC_UCLIBC) && defined (SINGLE_LIBC) /* uClinux */
+diff --git a/gcc/config/rs6000/linux.h b/gcc/config/rs6000/linux.h
+index 01b40c762f6..e7c5e92215c 100644
+--- a/gcc/config/rs6000/linux.h
++++ b/gcc/config/rs6000/linux.h
+@@ -92,6 +92,16 @@
+ 					 " -m elf32ppclinux")
+ #endif
+ 
++/* link libssp_nonshared.a with musl */
++#if DEFAULT_LIBC == LIBC_MUSL
++#ifdef TARGET_LIBC_PROVIDES_SSP
++#undef LINK_SSP_SPEC
++#define LINK_SSP_SPEC "%{fstack-protector|fstack-protector-all" \
++		       "|fstack-protector-strong|fstack-protector-explicit" \
++		       ":-lssp_nonshared}"
++#endif
++#endif
++
+ #undef LINK_OS_LINUX_SPEC
+ #define LINK_OS_LINUX_SPEC LINK_OS_LINUX_EMUL " %{!shared: %{!static: \
+   %{!static-pie: \
+diff --git a/gcc/config/rs6000/linux64.h b/gcc/config/rs6000/linux64.h
+index 55695dadd91..60f1ee24985 100644
+--- a/gcc/config/rs6000/linux64.h
++++ b/gcc/config/rs6000/linux64.h
+@@ -473,6 +473,16 @@ extern int dot_symbols;
+ 					   " -m elf64ppc")
+ #endif
+ 
++/* link libssp_nonshared.a with musl */
++#if DEFAULT_LIBC == LIBC_MUSL
++#ifdef TARGET_LIBC_PROVIDES_SSP
++#undef LINK_SSP_SPEC
++#define LINK_SSP_SPEC "%{fstack-protector|fstack-protector-all" \
++		       "|fstack-protector-strong|fstack-protector-explicit" \
++		       ":-lssp_nonshared}"
++#endif
++#endif
++
+ #define LINK_OS_LINUX_SPEC32 LINK_OS_LINUX_EMUL32 " %{!shared: %{!static: \
+   %{!static-pie: \
+     %{rdynamic:-export-dynamic} \
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0034-libgcc-Add-knob-to-use-ldbl-128-on-ppc.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0034-libgcc-Add-knob-to-use-ldbl-128-on-ppc.patch
new file mode 100644
index 0000000..7a69ea2
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0034-libgcc-Add-knob-to-use-ldbl-128-on-ppc.patch
@@ -0,0 +1,125 @@
+From faf35e26740461fe1a1da5433d5a0169a663e3b5 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 29 Apr 2016 20:03:28 +0000
+Subject: [PATCH 34/39] libgcc: Add knob to use ldbl-128 on ppc
+
+musl does not support ldbl 128 so we can not assume
+that linux as a whole supports ldbl-128 bits, instead
+act upon configure option passed to gcc and assume no
+on musl and yes otherwise if no option is passed since
+default behaviour is to assume ldbl128 it does not
+change the defaults
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ libgcc/Makefile.in           |  1 +
+ libgcc/config/rs6000/t-linux |  5 ++++-
+ libgcc/configure             | 18 ++++++++++++++++++
+ libgcc/configure.ac          | 12 ++++++++++++
+ 4 files changed, 35 insertions(+), 1 deletion(-)
+ mode change 100644 => 100755 libgcc/configure
+
+diff --git a/libgcc/Makefile.in b/libgcc/Makefile.in
+index dd8cee99fd3..b5f478af382 100644
+--- a/libgcc/Makefile.in
++++ b/libgcc/Makefile.in
+@@ -48,6 +48,7 @@ unwind_header = @unwind_header@
+ md_unwind_header = @md_unwind_header@
+ sfp_machine_header = @sfp_machine_header@
+ thread_header = @thread_header@
++with_ldbl128 = @with_ldbl128@
+ 
+ host_noncanonical = @host_noncanonical@
+ real_host_noncanonical = @real_host_noncanonical@
+diff --git a/libgcc/config/rs6000/t-linux b/libgcc/config/rs6000/t-linux
+index 4f6d4c4a4d2..c50dd94a2da 100644
+--- a/libgcc/config/rs6000/t-linux
++++ b/libgcc/config/rs6000/t-linux
+@@ -1,3 +1,6 @@
+ SHLIB_MAPFILES += $(srcdir)/config/rs6000/libgcc-glibc.ver
+ 
+-HOST_LIBGCC2_CFLAGS += -mlong-double-128 -mno-minimal-toc
++ifeq ($(with_ldbl128),yes)
++HOST_LIBGCC2_CFLAGS += -mlong-double-128
++endif
++HOST_LIBGCC2_CFLAGS += -mno-minimal-toc
+diff --git a/libgcc/configure b/libgcc/configure
+old mode 100644
+new mode 100755
+index b2f3f870844..ed806587c17
+--- a/libgcc/configure
++++ b/libgcc/configure
+@@ -619,6 +619,7 @@ build_vendor
+ build_cpu
+ build
+ with_aix_soname
++with_ldbl128
+ enable_vtable_verify
+ enable_shared
+ libgcc_topdir
+@@ -668,6 +669,7 @@ with_cross_host
+ with_ld
+ enable_shared
+ enable_vtable_verify
++with_long_double_128
+ with_aix_soname
+ enable_version_specific_runtime_libs
+ with_slibdir
+@@ -1329,6 +1331,7 @@ Optional Packages:
+   --with-target-subdir=SUBDIR      Configuring in a subdirectory for target
+   --with-cross-host=HOST           Configuring with a cross compiler
+   --with-ld               arrange to use the specified ld (full pathname)
++  --with-long-double-128  use 128-bit long double by default
+   --with-aix-soname=aix|svr4|both
+                           shared library versioning (aka "SONAME") variant to
+                           provide on AIX
+@@ -2213,6 +2216,21 @@ fi
+ 
+ 
+ 
++# Check whether --with-long-double-128 was given.
++if test "${with_long_double_128+set}" = set; then :
++  withval=$with_long_double_128; with_ldbl128="$with_long_double_128"
++else
++  case "${host}" in
++ power*-*-musl*)
++   with_ldbl128="no";;
++ *) with_ldbl128="yes";;
++ esac
++
++fi
++
++
++
++
+ # Check whether --with-aix-soname was given.
+ if test "${with_aix_soname+set}" = set; then :
+   withval=$with_aix_soname; case "${host}:${enable_shared}" in
+diff --git a/libgcc/configure.ac b/libgcc/configure.ac
+index b59aa746afc..42220a263c5 100644
+--- a/libgcc/configure.ac
++++ b/libgcc/configure.ac
+@@ -78,6 +78,18 @@ AC_ARG_ENABLE(vtable-verify,
+ [enable_vtable_verify=no])
+ AC_SUBST(enable_vtable_verify)
+ 
++AC_ARG_WITH(long-double-128,
++[AS_HELP_STRING([--with-long-double-128],
++    [use 128-bit long double by default])],
++      with_ldbl128="$with_long_double_128",
++[case "${host}" in
++ power*-*-musl*)
++   with_ldbl128="no";;
++ *) with_ldbl128="yes";;
++ esac
++])
++AC_SUBST(with_ldbl128)
++
+ AC_ARG_WITH(aix-soname,
+ [AS_HELP_STRING([--with-aix-soname=aix|svr4|both],
+     [shared library versioning (aka "SONAME") variant to provide on AIX])],
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0035-Link-libgcc-using-LDFLAGS-not-just-SHLIB_LDFLAGS.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0035-Link-libgcc-using-LDFLAGS-not-just-SHLIB_LDFLAGS.patch
new file mode 100644
index 0000000..5e416e0
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0035-Link-libgcc-using-LDFLAGS-not-just-SHLIB_LDFLAGS.patch
@@ -0,0 +1,29 @@
+From 775c7fafcbfebed2d4bd8a6a011f18f70f3b59d3 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 4 May 2016 21:11:34 -0700
+Subject: [PATCH 35/39] Link libgcc using LDFLAGS, not just SHLIB_LDFLAGS
+
+Upstream-Status: Pending
+
+Signed-off-by: Christopher Larson <chris_larson@mentor.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ libgcc/config/t-slibgcc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/libgcc/config/t-slibgcc b/libgcc/config/t-slibgcc
+index 7e60b621a2d..ea22ede3361 100644
+--- a/libgcc/config/t-slibgcc
++++ b/libgcc/config/t-slibgcc
+@@ -32,7 +32,7 @@ SHLIB_INSTALL_SOLINK = $(LN_S) $(SHLIB_SONAME) \
+ 	$(DESTDIR)$(slibdir)$(SHLIB_SLIBDIR_QUAL)/$(SHLIB_SOLINK)
+ 
+ SHLIB_LINK = $(CC) $(LIBGCC2_CFLAGS) -shared -nodefaultlibs \
+-	$(SHLIB_LDFLAGS) \
++	$(LDFLAGS) $(SHLIB_LDFLAGS) \
+ 	-o $(SHLIB_DIR)/$(SHLIB_SONAME).tmp @multilib_flags@ \
+ 	$(SHLIB_OBJS) $(SHLIB_LC) && \
+ 	rm -f $(SHLIB_DIR)/$(SHLIB_SOLINK) && \
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0036-libgcc_s-Use-alias-for-__cpu_indicator_init-instead-.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0036-libgcc_s-Use-alias-for-__cpu_indicator_init-instead-.patch
new file mode 100644
index 0000000..8def33a
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0036-libgcc_s-Use-alias-for-__cpu_indicator_init-instead-.patch
@@ -0,0 +1,86 @@
+From b7faeed60261d7b75f2db3823926de1650ef64bc Mon Sep 17 00:00:00 2001
+From: Szabolcs Nagy <nsz@port70.net>
+Date: Sat, 24 Oct 2015 20:09:53 +0000
+Subject: [PATCH 36/39] libgcc_s: Use alias for __cpu_indicator_init instead of
+ symver
+
+Adapter from
+
+https://gcc.gnu.org/ml/gcc-patches/2015-05/msg00899.html
+
+This fix was debated but hasnt been applied gcc upstream since
+they expect musl to support '@' in symbol versioning which is
+a sun/gnu versioning extention. This patch however avoids the
+need for the '@' symbols at all
+
+libgcc/Changelog:
+
+2015-05-11  Szabolcs Nagy  <szabolcs.nagy@arm.com>
+
+	* config/i386/cpuinfo.c (__cpu_indicator_init_local): Add.
+	(__cpu_indicator_init@GCC_4.8.0, __cpu_model@GCC_4.8.0): Remove.
+
+	* config/i386/t-linux (HOST_LIBGCC2_CFLAGS): Remove -DUSE_ELF_SYMVER.
+
+gcc/Changelog:
+
+2015-05-11  Szabolcs Nagy  <szabolcs.nagy@arm.com>
+
+	* config/i386/i386.c (ix86_expand_builtin): Make __builtin_cpu_init
+	call __cpu_indicator_init_local instead of __cpu_indicator_init.
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ gcc/config/i386/i386.c       | 4 ++--
+ libgcc/config/i386/cpuinfo.c | 6 +++---
+ libgcc/config/i386/t-linux   | 2 +-
+ 3 files changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c
+index 6a2141e48db..455fccbdd50 100644
+--- a/gcc/config/i386/i386.c
++++ b/gcc/config/i386/i386.c
+@@ -36490,10 +36490,10 @@ ix86_expand_builtin (tree exp, rtx target, rtx subtarget,
+     {
+     case IX86_BUILTIN_CPU_INIT:
+       {
+-	/* Make it call __cpu_indicator_init in libgcc. */
++	/* Make it call __cpu_indicator_init_local in libgcc.a. */
+ 	tree call_expr, fndecl, type;
+         type = build_function_type_list (integer_type_node, NULL_TREE); 
+-	fndecl = build_fn_decl ("__cpu_indicator_init", type);
++	fndecl = build_fn_decl ("__cpu_indicator_init_local", type);
+ 	call_expr = build_call_expr (fndecl, 0); 
+ 	return expand_expr (call_expr, target, mode, EXPAND_NORMAL);
+       }
+diff --git a/libgcc/config/i386/cpuinfo.c b/libgcc/config/i386/cpuinfo.c
+index 86953db2743..e0476272810 100644
+--- a/libgcc/config/i386/cpuinfo.c
++++ b/libgcc/config/i386/cpuinfo.c
+@@ -482,7 +482,7 @@ __cpu_indicator_init (void)
+   return 0;
+ }
+ 
+-#if defined SHARED && defined USE_ELF_SYMVER
+-__asm__ (".symver __cpu_indicator_init, __cpu_indicator_init@GCC_4.8.0");
+-__asm__ (".symver __cpu_model, __cpu_model@GCC_4.8.0");
++#ifndef SHARED
++int __cpu_indicator_init_local (void)
++  __attribute__ ((weak, alias ("__cpu_indicator_init")));
+ #endif
+diff --git a/libgcc/config/i386/t-linux b/libgcc/config/i386/t-linux
+index 8506a635790..564296f788e 100644
+--- a/libgcc/config/i386/t-linux
++++ b/libgcc/config/i386/t-linux
+@@ -3,5 +3,5 @@
+ # t-slibgcc-elf-ver and t-linux
+ SHLIB_MAPFILES = libgcc-std.ver $(srcdir)/config/i386/libgcc-glibc.ver
+ 
+-HOST_LIBGCC2_CFLAGS += -mlong-double-80 -DUSE_ELF_SYMVER $(CET_FLAGS)
++HOST_LIBGCC2_CFLAGS += -mlong-double-80 $(CET_FLAGS)
+ CRTSTUFF_T_CFLAGS += $(CET_FLAGS)
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0037-sync-gcc-stddef.h-with-musl.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0037-sync-gcc-stddef.h-with-musl.patch
new file mode 100644
index 0000000..f8a7f41
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0037-sync-gcc-stddef.h-with-musl.patch
@@ -0,0 +1,91 @@
+From 602abaab15ffb60bf1797187a71b485042c56360 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 3 Feb 2017 12:56:00 -0800
+Subject: [PATCH 37/39] sync gcc stddef.h with musl
+
+musl defines ptrdiff_t size_t and wchar_t
+so dont define them here if musl is definining them
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ gcc/ginclude/stddef.h | 9 +++++++++
+ 1 file changed, 9 insertions(+)
+
+diff --git a/gcc/ginclude/stddef.h b/gcc/ginclude/stddef.h
+index 31b96a7e5e1..438a3ce7c56 100644
+--- a/gcc/ginclude/stddef.h
++++ b/gcc/ginclude/stddef.h
+@@ -134,6 +134,7 @@ _TYPE_wchar_t;
+ #ifndef ___int_ptrdiff_t_h
+ #ifndef _GCC_PTRDIFF_T
+ #ifndef _PTRDIFF_T_DECLARED /* DragonFly */
++#ifndef __DEFINED_ptrdiff_t /* musl */
+ #define _PTRDIFF_T
+ #define _T_PTRDIFF_
+ #define _T_PTRDIFF
+@@ -143,10 +144,12 @@ _TYPE_wchar_t;
+ #define ___int_ptrdiff_t_h
+ #define _GCC_PTRDIFF_T
+ #define _PTRDIFF_T_DECLARED
++#define __DEFINED_ptrdiff_t /* musl */
+ #ifndef __PTRDIFF_TYPE__
+ #define __PTRDIFF_TYPE__ long int
+ #endif
+ typedef __PTRDIFF_TYPE__ ptrdiff_t;
++#endif /* __DEFINED_ptrdiff_t */
+ #endif /* _PTRDIFF_T_DECLARED */
+ #endif /* _GCC_PTRDIFF_T */
+ #endif /* ___int_ptrdiff_t_h */
+@@ -184,6 +187,7 @@ typedef __PTRDIFF_TYPE__ ptrdiff_t;
+ #ifndef _GCC_SIZE_T
+ #ifndef _SIZET_
+ #ifndef __size_t
++#ifndef __DEFINED_size_t /* musl */
+ #define __size_t__	/* BeOS */
+ #define __SIZE_T__	/* Cray Unicos/Mk */
+ #define _SIZE_T
+@@ -200,6 +204,7 @@ typedef __PTRDIFF_TYPE__ ptrdiff_t;
+ #define ___int_size_t_h
+ #define _GCC_SIZE_T
+ #define _SIZET_
++#define __DEFINED_size_t /* musl */
+ #if (defined (__FreeBSD__) && (__FreeBSD__ >= 5)) \
+   || defined(__DragonFly__) \
+   || defined(__FreeBSD_kernel__)
+@@ -235,6 +240,7 @@ typedef long ssize_t;
+ #endif /* _SIZE_T */
+ #endif /* __SIZE_T__ */
+ #endif /* __size_t__ */
++#endif /* __DEFINED_size_t */
+ #undef	__need_size_t
+ #endif /* _STDDEF_H or __need_size_t.  */
+ 
+@@ -264,6 +270,7 @@ typedef long ssize_t;
+ #ifndef ___int_wchar_t_h
+ #ifndef __INT_WCHAR_T_H
+ #ifndef _GCC_WCHAR_T
++#ifndef __DEFINED_wchar_t /* musl */
+ #define __wchar_t__	/* BeOS */
+ #define __WCHAR_T__	/* Cray Unicos/Mk */
+ #define _WCHAR_T
+@@ -279,6 +286,7 @@ typedef long ssize_t;
+ #define __INT_WCHAR_T_H
+ #define _GCC_WCHAR_T
+ #define _WCHAR_T_DECLARED
++#define __DEFINED_wchar_t /* musl */
+ 
+ /* On BSD/386 1.1, at least, machine/ansi.h defines _BSD_WCHAR_T_
+    instead of _WCHAR_T_, and _BSD_RUNE_T_ (which, unlike the other
+@@ -344,6 +352,7 @@ typedef __WCHAR_TYPE__ wchar_t;
+ #endif
+ #endif /* __WCHAR_T__ */
+ #endif /* __wchar_t__ */
++#endif /* __DEFINED_wchar_t musl */
+ #undef	__need_wchar_t
+ #endif /* _STDDEF_H or __need_wchar_t.  */
+ 
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0038-fix-segmentation-fault-in-precompiled-header-generat.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0038-fix-segmentation-fault-in-precompiled-header-generat.patch
new file mode 100644
index 0000000..224d2ae
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0038-fix-segmentation-fault-in-precompiled-header-generat.patch
@@ -0,0 +1,60 @@
+From 00694849632dee23741925c6104df134f6bff747 Mon Sep 17 00:00:00 2001
+From: Juro Bystricky <juro.bystricky@intel.com>
+Date: Mon, 19 Mar 2018 22:31:20 -0700
+Subject: [PATCH 38/39] fix segmentation fault in precompiled header generation
+
+Prevent a segmentation fault which occurs when using incorrect
+structure trying to access name of some named operators, such as
+CPP_NOT, CPP_AND etc. "token->val.node.spelling" cannot be used in
+those cases, as is may not be initialized at all.
+
+[YOCTO #11738]
+
+Upstream-Status: Pending
+
+Signed-off-by: Juro Bystricky <juro.bystricky@intel.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ libcpp/lex.c | 26 +++++++++++++++++++++-----
+ 1 file changed, 21 insertions(+), 5 deletions(-)
+
+diff --git a/libcpp/lex.c b/libcpp/lex.c
+index 37c365a3560..63480048db6 100644
+--- a/libcpp/lex.c
++++ b/libcpp/lex.c
+@@ -3279,11 +3279,27 @@ cpp_spell_token (cpp_reader *pfile, const cpp_token *token,
+     spell_ident:
+     case SPELL_IDENT:
+       if (forstring)
+-	{
+-	  memcpy (buffer, NODE_NAME (token->val.node.spelling),
+-		  NODE_LEN (token->val.node.spelling));
+-	  buffer += NODE_LEN (token->val.node.spelling);
+-	}
++        {
++          if (token->type == CPP_NAME)
++            {
++              memcpy (buffer, NODE_NAME (token->val.node.spelling),
++                    NODE_LEN (token->val.node.spelling));
++              buffer += NODE_LEN (token->val.node.spelling);
++              break;
++            }
++          /* NAMED_OP, cannot use node.spelling */
++          if (token->flags & NAMED_OP)
++            {
++              const char *str = cpp_named_operator2name (token->type);
++              if (str)
++                {
++                  size_t len = strlen(str);
++                  memcpy(buffer, str, len);
++                  buffer += len;
++                }
++              break;
++            }
++        }
+       else
+ 	buffer = _cpp_spell_ident_ucns (buffer, token->val.node.node);
+       break;
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0039-Fix-for-testsuite-failure.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0039-Fix-for-testsuite-failure.patch
new file mode 100644
index 0000000..f351630
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0039-Fix-for-testsuite-failure.patch
@@ -0,0 +1,258 @@
+From d151a62c252749643c850a08d1335321e5b75d42 Mon Sep 17 00:00:00 2001
+From: RAGHUNATH LOLUR <raghunath.lolur@kpit.com>
+Date: Wed, 6 Dec 2017 22:52:26 -0800
+Subject: [PATCH 39/39] Fix for testsuite failure
+
+2017-11-16  Raghunath Lolur  <raghunath.lolur@kpit.com>
+
+	* gcc.dg/pr56275.c: If SSE is disabled, ensure that
+	"-mfpmath" is not set to use SSE. Set "-mfpmath=387".
+	* gcc.dg/pr68306.c: Likewise
+	* gcc.dg/pr68306-2.c: Likewise
+	* gcc.dg/pr68306-3.c: Likewise
+	* gcc.dg/pr69634.c: Likewise
+	* gcc.target/i386/amd64-abi-1.c: Likewise
+	* gcc.target/i386/funcspec-6.c: Likewise
+	* gcc.target/i386/interrupt-387-err-1.c: Likewise
+	* gcc.target/i386/isa-14.c: Likewise
+	* gcc.target/i386/pr44948-2b.c: Likewise
+	* gcc.target/i386/pr53425-1.c: Likewise
+	* gcc.target/i386/pr53425-2.c: Likewise
+	* gcc.target/i386/pr55247.c: Likewise
+	* gcc.target/i386/pr59644.c: Likewise
+	* gcc.target/i386/pr62120.c: Likewise
+	* gcc.target/i386/pr70467-1.c: Likewise
+	* gcc.target/i386/warn-vect-op-1.c: Likewise
+
+If -Wall, -Werror are used during compilation various test cases fail
+to compile.
+
+If SSE is disabled, be sure to -mfpmath=387 to resolve this.
+
+This patch removes the changes to Changelog from the original patch.
+This will help us avoid conflicts.
+
+Upstream-Status: Pending
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+---
+ gcc/testsuite/gcc.dg/pr56275.c                      | 2 +-
+ gcc/testsuite/gcc.dg/pr68306-2.c                    | 2 +-
+ gcc/testsuite/gcc.dg/pr68306-3.c                    | 2 +-
+ gcc/testsuite/gcc.dg/pr68306.c                      | 2 +-
+ gcc/testsuite/gcc.dg/pr69634.c                      | 2 +-
+ gcc/testsuite/gcc.target/i386/amd64-abi-1.c         | 2 +-
+ gcc/testsuite/gcc.target/i386/funcspec-6.c          | 1 +
+ gcc/testsuite/gcc.target/i386/interrupt-387-err-1.c | 2 +-
+ gcc/testsuite/gcc.target/i386/isa-14.c              | 2 +-
+ gcc/testsuite/gcc.target/i386/pr44948-2b.c          | 2 +-
+ gcc/testsuite/gcc.target/i386/pr53425-1.c           | 2 +-
+ gcc/testsuite/gcc.target/i386/pr53425-2.c           | 2 +-
+ gcc/testsuite/gcc.target/i386/pr55247.c             | 2 +-
+ gcc/testsuite/gcc.target/i386/pr59644.c             | 2 +-
+ gcc/testsuite/gcc.target/i386/pr62120.c             | 2 +-
+ gcc/testsuite/gcc.target/i386/pr70467-1.c           | 2 +-
+ gcc/testsuite/gcc.target/i386/warn-vect-op-1.c      | 2 +-
+ 17 files changed, 17 insertions(+), 16 deletions(-)
+
+diff --git a/gcc/testsuite/gcc.dg/pr56275.c b/gcc/testsuite/gcc.dg/pr56275.c
+index b901bb2b199..a4f6c95e1a1 100644
+--- a/gcc/testsuite/gcc.dg/pr56275.c
++++ b/gcc/testsuite/gcc.dg/pr56275.c
+@@ -1,6 +1,6 @@
+ /* { dg-do compile } */
+ /* { dg-options "-O2" } */
+-/* { dg-additional-options "-mno-sse" { target { i?86-*-* x86_64-*-* } } } */
++/* { dg-additional-options "-mno-sse -mfpmath=387" { target { i?86-*-* x86_64-*-* } } } */
+ 
+ typedef long long v2tw __attribute__ ((vector_size (2 * sizeof (long long))));
+ 
+diff --git a/gcc/testsuite/gcc.dg/pr68306-2.c b/gcc/testsuite/gcc.dg/pr68306-2.c
+index 4672ebe7987..2a368c484b6 100644
+--- a/gcc/testsuite/gcc.dg/pr68306-2.c
++++ b/gcc/testsuite/gcc.dg/pr68306-2.c
+@@ -1,6 +1,6 @@
+ /* { dg-do compile } */
+ /* { dg-options "-O3" } */
+-/* { dg-additional-options "-mno-sse -mno-mmx" { target i?86-*-* x86_64-*-* } } */
++/* { dg-additional-options "-mno-sse -mno-mmx -mfpmath=387" { target i?86-*-* x86_64-*-* } } */
+ 
+ struct {
+     int tz_minuteswest;
+diff --git a/gcc/testsuite/gcc.dg/pr68306-3.c b/gcc/testsuite/gcc.dg/pr68306-3.c
+index f5a8c102cf8..df3390c64c2 100644
+--- a/gcc/testsuite/gcc.dg/pr68306-3.c
++++ b/gcc/testsuite/gcc.dg/pr68306-3.c
+@@ -1,6 +1,6 @@
+ /* { dg-do compile } */
+ /* { dg-options "-O3" } */
+-/* { dg-additional-options "-mno-sse -mno-mmx" { target i?86-*-* x86_64-*-* } } */
++/* { dg-additional-options "-mno-sse -mno-mmx -mfpmath=387" { target i?86-*-* x86_64-*-* } } */
+ /* { dg-additional-options "-mno-altivec -mno-vsx" { target powerpc*-*-* } } */
+ 
+ extern void fn2();
+diff --git a/gcc/testsuite/gcc.dg/pr68306.c b/gcc/testsuite/gcc.dg/pr68306.c
+index 54e5b40f221..0813389e2c1 100644
+--- a/gcc/testsuite/gcc.dg/pr68306.c
++++ b/gcc/testsuite/gcc.dg/pr68306.c
+@@ -1,6 +1,6 @@
+ /* { dg-do compile } */
+ /* { dg-options "-O3" } */
+-/* { dg-additional-options "-mno-sse -mno-mmx" { target i?86-*-* x86_64-*-* } } */
++/* { dg-additional-options "-mno-sse -mno-mmx -mfpmath=387" { target i?86-*-* x86_64-*-* } } */
+ 
+ enum powerpc_pmc_type { PPC_PMC_IBM };
+ struct {
+diff --git a/gcc/testsuite/gcc.dg/pr69634.c b/gcc/testsuite/gcc.dg/pr69634.c
+index 60a56149463..bcc23f9ccd6 100644
+--- a/gcc/testsuite/gcc.dg/pr69634.c
++++ b/gcc/testsuite/gcc.dg/pr69634.c
+@@ -1,6 +1,6 @@
+ /* { dg-do compile } */
+ /* { dg-options "-O2 -fno-dce -fschedule-insns -fno-tree-vrp -fcompare-debug -Wno-psabi" } */
+-/* { dg-additional-options "-mno-sse" { target i?86-*-* x86_64-*-* } } */
++/* { dg-additional-options "-mno-sse -mfpmath=387" { target i?86-*-* x86_64-*-* } } */
+ /* { dg-require-effective-target scheduling } */
+ 
+ typedef unsigned short u16;
+diff --git a/gcc/testsuite/gcc.target/i386/amd64-abi-1.c b/gcc/testsuite/gcc.target/i386/amd64-abi-1.c
+index 69fde57bf06..7f1f1c03edf 100644
+--- a/gcc/testsuite/gcc.target/i386/amd64-abi-1.c
++++ b/gcc/testsuite/gcc.target/i386/amd64-abi-1.c
+@@ -1,5 +1,5 @@
+ /* { dg-do compile { target { ! ia32 } } } */
+-/* { dg-options "-mno-sse" } */
++/* { dg-options "-mno-sse -mfpmath=387" } */
+ /* { dg-additional-options "-mabi=sysv" { target *-*-mingw* } } */
+ 
+ double foo(void) { return 0; }	/* { dg-error "SSE disabled" } */
+diff --git a/gcc/testsuite/gcc.target/i386/funcspec-6.c b/gcc/testsuite/gcc.target/i386/funcspec-6.c
+index ea896b7ebfd..bf15569b826 100644
+--- a/gcc/testsuite/gcc.target/i386/funcspec-6.c
++++ b/gcc/testsuite/gcc.target/i386/funcspec-6.c
+@@ -1,6 +1,7 @@
+ /* Test whether all of the 64-bit function specific options are accepted
+    without error.  */
+ /* { dg-do compile { target { ! ia32 } } } */
++/* { dg-additional-options "-mfpmath=387" } */
+ 
+ #include "funcspec-56.inc"
+ 
+diff --git a/gcc/testsuite/gcc.target/i386/interrupt-387-err-1.c b/gcc/testsuite/gcc.target/i386/interrupt-387-err-1.c
+index 3fbdc881dda..6b4d9d1252a 100644
+--- a/gcc/testsuite/gcc.target/i386/interrupt-387-err-1.c
++++ b/gcc/testsuite/gcc.target/i386/interrupt-387-err-1.c
+@@ -1,5 +1,5 @@
+ /* { dg-do compile } */
+-/* { dg-options "-O2 -mgeneral-regs-only -mno-cld -mno-iamcu -m80387" } */
++/* { dg-options "-O2 -mgeneral-regs-only -mno-cld -mno-iamcu -m80387 -mfpmath=387" } */
+ 
+ typedef unsigned int uword_t __attribute__ ((mode (__word__)));
+ 
+diff --git a/gcc/testsuite/gcc.target/i386/isa-14.c b/gcc/testsuite/gcc.target/i386/isa-14.c
+index 5d49e6e77fe..1de2db92bdd 100644
+--- a/gcc/testsuite/gcc.target/i386/isa-14.c
++++ b/gcc/testsuite/gcc.target/i386/isa-14.c
+@@ -1,5 +1,5 @@
+ /* { dg-do run } */
+-/* { dg-options "-march=x86-64 -msse4a -mfma4 -mno-sse" } */
++/* { dg-options "-march=x86-64 -msse4a -mfma4 -mno-sse -mfpmath=387" } */
+ 
+ extern void abort (void);
+ 
+diff --git a/gcc/testsuite/gcc.target/i386/pr44948-2b.c b/gcc/testsuite/gcc.target/i386/pr44948-2b.c
+index fa1769b62fb..f79fb12726f 100644
+--- a/gcc/testsuite/gcc.target/i386/pr44948-2b.c
++++ b/gcc/testsuite/gcc.target/i386/pr44948-2b.c
+@@ -1,5 +1,5 @@
+ /* { dg-do compile } */
+-/* { dg-options "-O -mno-sse -Wno-psabi -mtune=generic" } */
++/* { dg-options "-O -mno-sse -Wno-psabi -mtune=generic -mfpmath=387" } */
+ 
+ struct A
+ { 
+diff --git a/gcc/testsuite/gcc.target/i386/pr53425-1.c b/gcc/testsuite/gcc.target/i386/pr53425-1.c
+index 2e89ff7d81d..6339bf6b736 100644
+--- a/gcc/testsuite/gcc.target/i386/pr53425-1.c
++++ b/gcc/testsuite/gcc.target/i386/pr53425-1.c
+@@ -1,6 +1,6 @@
+ /* PR target/53425 */
+ /* { dg-do compile { target { ! ia32 } } } */
+-/* { dg-options "-O2 -mno-sse" } */
++/* { dg-options "-O2 -mno-sse -mfpmath=387" } */
+ /* { dg-skip-if "no SSE vector" { x86_64-*-mingw* } } */
+ 
+ typedef double __v2df __attribute__ ((__vector_size__ (16)));
+diff --git a/gcc/testsuite/gcc.target/i386/pr53425-2.c b/gcc/testsuite/gcc.target/i386/pr53425-2.c
+index 61f6283dbe9..2c5a55f0ac3 100644
+--- a/gcc/testsuite/gcc.target/i386/pr53425-2.c
++++ b/gcc/testsuite/gcc.target/i386/pr53425-2.c
+@@ -1,6 +1,6 @@
+ /* PR target/53425 */
+ /* { dg-do compile { target { ! ia32 } } } */
+-/* { dg-options "-O2 -mno-sse" } */
++/* { dg-options "-O2 -mno-sse -mfpmath=387" } */
+ /* { dg-skip-if "no SSE vector" { x86_64-*-mingw* } } */
+ 
+ typedef float __v2sf __attribute__ ((__vector_size__ (8)));
+diff --git a/gcc/testsuite/gcc.target/i386/pr55247.c b/gcc/testsuite/gcc.target/i386/pr55247.c
+index 23366d0909d..9810e3abb76 100644
+--- a/gcc/testsuite/gcc.target/i386/pr55247.c
++++ b/gcc/testsuite/gcc.target/i386/pr55247.c
+@@ -1,6 +1,6 @@
+ /* { dg-do compile { target { ! ia32 } } } */
+ /* { dg-require-effective-target maybe_x32 } */
+-/* { dg-options "-O2 -mno-sse -mno-mmx -mx32 -maddress-mode=long" } */
++/* { dg-options "-O2 -mno-sse -mno-mmx -mx32 -maddress-mode=long -mfpmath=387" } */
+ 
+ typedef unsigned int uint32_t;
+ typedef uint32_t Elf32_Word;
+diff --git a/gcc/testsuite/gcc.target/i386/pr59644.c b/gcc/testsuite/gcc.target/i386/pr59644.c
+index 96006b3e338..4287e4538bf 100644
+--- a/gcc/testsuite/gcc.target/i386/pr59644.c
++++ b/gcc/testsuite/gcc.target/i386/pr59644.c
+@@ -1,6 +1,6 @@
+ /* PR target/59644 */
+ /* { dg-do run { target lp64 } } */
+-/* { dg-options "-O2 -ffreestanding -mno-sse -mpreferred-stack-boundary=3 -maccumulate-outgoing-args -mno-red-zone" } */
++/* { dg-options "-O2 -ffreestanding -mno-sse -mpreferred-stack-boundary=3 -maccumulate-outgoing-args -mno-red-zone -mfpmath=387" } */
+ 
+ /* This test uses __builtin_trap () instead of e.g. abort,
+    because due to -mpreferred-stack-boundary=3 it should not call
+diff --git a/gcc/testsuite/gcc.target/i386/pr62120.c b/gcc/testsuite/gcc.target/i386/pr62120.c
+index bfb8c4703eb..ed04cf181f3 100644
+--- a/gcc/testsuite/gcc.target/i386/pr62120.c
++++ b/gcc/testsuite/gcc.target/i386/pr62120.c
+@@ -1,5 +1,5 @@
+ /* { dg-do compile } */
+-/* { dg-options "-mno-sse" } */
++/* { dg-options "-mno-sse -mfpmath=387" } */
+ 
+ void foo ()
+ {
+diff --git a/gcc/testsuite/gcc.target/i386/pr70467-1.c b/gcc/testsuite/gcc.target/i386/pr70467-1.c
+index 4e112c88d07..bcfb396a68d 100644
+--- a/gcc/testsuite/gcc.target/i386/pr70467-1.c
++++ b/gcc/testsuite/gcc.target/i386/pr70467-1.c
+@@ -1,6 +1,6 @@
+ /* PR rtl-optimization/70467 */
+ /* { dg-do compile } */
+-/* { dg-options "-O2 -mno-sse" } */
++/* { dg-options "-O2 -mno-sse -mfpmath=387" } */
+ 
+ void foo (unsigned long long *);
+ 
+diff --git a/gcc/testsuite/gcc.target/i386/warn-vect-op-1.c b/gcc/testsuite/gcc.target/i386/warn-vect-op-1.c
+index 6cda1534311..26e37f5b8ba 100644
+--- a/gcc/testsuite/gcc.target/i386/warn-vect-op-1.c
++++ b/gcc/testsuite/gcc.target/i386/warn-vect-op-1.c
+@@ -1,5 +1,5 @@
+ /* { dg-do compile { target { ! ia32 } } }  */
+-/* { dg-options "-mno-sse -Wvector-operation-performance" }  */
++/* { dg-options "-mno-sse -Wvector-operation-performance -mfpmath=387" }  */
+ #define vector(elcount, type)  \
+ __attribute__((vector_size((elcount)*sizeof(type)))) type
+ 
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0040-Re-introduce-spe-commandline-options.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0040-Re-introduce-spe-commandline-options.patch
new file mode 100644
index 0000000..8afa010
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0040-Re-introduce-spe-commandline-options.patch
@@ -0,0 +1,41 @@
+From 8fb8f773e117ee70be00bb0da5f343fe110da5c4 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 6 Jun 2018 12:10:22 -0700
+Subject: [PATCH 40/40] Re-introduce spe commandline options
+
+This should ensure that we keep accepting
+spe options
+
+Upstream-Status: Inappropriate [SPE port is removed from rs600 port]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ gcc/config/rs6000/rs6000.opt | 12 ++++++++++++
+ 1 file changed, 12 insertions(+)
+
+diff --git a/gcc/config/rs6000/rs6000.opt b/gcc/config/rs6000/rs6000.opt
+index ace8a477550..d6a8f825d88 100644
+--- a/gcc/config/rs6000/rs6000.opt
++++ b/gcc/config/rs6000/rs6000.opt
+@@ -365,6 +365,18 @@ mdebug=
+ Target RejectNegative Joined
+ -mdebug=	Enable debug output.
+ 
++mspe
++Target Var(rs6000_spe) Save
++Generate SPE SIMD instructions on E500.
++
++mabi=spe
++Target RejectNegative Var(rs6000_spe_abi) Save
++Use the SPE ABI extensions.
++
++mabi=no-spe
++Target RejectNegative Var(rs6000_spe_abi, 0)
++Do not use the SPE ABI extensions.
++
+ mabi=altivec
+ Target RejectNegative Var(rs6000_altivec_abi) Save
+ Use the AltiVec ABI extensions.
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-8.2/0041-ARC-fix-spec-gen.patch b/poky/meta/recipes-devtools/gcc/gcc-8.2/0041-ARC-fix-spec-gen.patch
new file mode 100644
index 0000000..cbd5e41
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-8.2/0041-ARC-fix-spec-gen.patch
@@ -0,0 +1,44 @@
+From 892142379c6b99fe8c3ebdfe0b79e2a435228c1d Mon Sep 17 00:00:00 2001
+From: claziss <claziss@138bc75d-0d04-0410-961f-82ee72b054a4>
+Date: Mon, 17 Sep 2018 08:52:10 +0000
+Subject: [PATCH] [ARC] Update LINK_EH_SPEC linker spec.
+
+With no trailing space in LINK_EH_SPEC linker spec gets generated as:
+------------------------>8---------------------
+%{!r:--build-id} --eh-frame-hdr%{h*} ...
+------------------------>8---------------------
+
+or even worse if hash style is added:
+------------------------>8---------------------
+%{!r:--build-id} --eh-frame-hdr--hash-style=sysv %{h*} ...
+------------------------>8---------------------
+
+Now if that spec is really used by LD then it fails inevitably
+saying that it doesn't know option "--eh-frame-hdr--hash-style=sysv".
+
+2018-09-17  Alexey Brodkin  <abrodkin@synopsys.com>
+
+	* config/arc/linux.h (LINK_EH_SPEC): Add missing space.
+
+git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@264361 138bc75d-0d04-0410-961f-82ee72b054a4
+
+Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
+
+Upstream-Status: Backport[https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=892142379c6b]
+---
+ gcc/config/arc/linux.h | 2 +-
+ 1 files changed, 1 insertions(+), 1 deletion(-)
+
+diff --git a/gcc/config/arc/linux.h b/gcc/config/arc/linux.h
+index 96d548eae341..62ebe4de0fc7 100644
+--- a/gcc/config/arc/linux.h
++++ b/gcc/config/arc/linux.h
+@@ -98,7 +98,7 @@ along with GCC; see the file COPYING3.  If not see
+    Signalize that because we have fde-glibc, we don't need all C shared libs
+    linked against -lgcc_s.  */
+ #undef LINK_EH_SPEC
+-#define LINK_EH_SPEC "--eh-frame-hdr"
++#define LINK_EH_SPEC "--eh-frame-hdr "
+ #endif
+ 
+ #undef SUBTARGET_CPP_SPEC
diff --git a/poky/meta/recipes-devtools/gcc/gcc-common.inc b/poky/meta/recipes-devtools/gcc/gcc-common.inc
index aa3b53e..00fec0b 100644
--- a/poky/meta/recipes-devtools/gcc/gcc-common.inc
+++ b/poky/meta/recipes-devtools/gcc/gcc-common.inc
@@ -46,7 +46,7 @@
     if d.getVar('TRANSLATED_TARGET_ARCH') in [ 'powerpc', 'powerpc64' ] and d.getVar('TCLIBC') in [ 'glibc' ]:
         return "--with-long-double-128"
     else:
-        return "--without-long-double-128"
+        return "--without-long-double-128 libgcc_cv_powerpc_float128=no"
     return ""
 
 def get_gcc_multiarch_setting(bb, d):
diff --git a/poky/meta/recipes-devtools/gcc/gcc-cross-canadian.inc b/poky/meta/recipes-devtools/gcc/gcc-cross-canadian.inc
index bdd6f7e..2f32d34 100644
--- a/poky/meta/recipes-devtools/gcc/gcc-cross-canadian.inc
+++ b/poky/meta/recipes-devtools/gcc/gcc-cross-canadian.inc
@@ -160,11 +160,6 @@
 
 EXTRA_OECONF += "--enable-poison-system-directories"
 
-EXTRA_OECONF += "\
-    --with-mpfr=${STAGING_DIR_HOST}${layout_exec_prefix} \
-    --with-mpc=${STAGING_DIR_HOST}${layout_exec_prefix} \
-"
-
 EXTRA_OECONF_append_libc-baremetal = " --without-headers"
 EXTRA_OECONF_remove_libc-baremetal = "--with-sysroot=/not/exist"
 EXTRA_OECONF_remove_libc-baremetal = "--with-build-sysroot=${STAGING_DIR_TARGET}"
diff --git a/poky/meta/recipes-devtools/gcc/gcc-cross-canadian_8.2.bb b/poky/meta/recipes-devtools/gcc/gcc-cross-canadian_8.2.bb
new file mode 100644
index 0000000..bf53c5c
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-cross-canadian_8.2.bb
@@ -0,0 +1,5 @@
+require recipes-devtools/gcc/gcc-${PV}.inc
+require gcc-cross-canadian.inc
+
+
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-cross-initial_8.2.bb b/poky/meta/recipes-devtools/gcc/gcc-cross-initial_8.2.bb
new file mode 100644
index 0000000..4c73e5c
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-cross-initial_8.2.bb
@@ -0,0 +1,2 @@
+require recipes-devtools/gcc/gcc-cross_${PV}.bb
+require gcc-cross-initial.inc
diff --git a/poky/meta/recipes-devtools/gcc/gcc-cross.inc b/poky/meta/recipes-devtools/gcc/gcc-cross.inc
index 1e184a6..89b1968 100644
--- a/poky/meta/recipes-devtools/gcc/gcc-cross.inc
+++ b/poky/meta/recipes-devtools/gcc/gcc-cross.inc
@@ -28,13 +28,13 @@
 "
 
 EXTRA_OECONF += "\
-    --with-mpfr=${STAGING_DIR_NATIVE}${prefix_native} \
     --with-system-zlib \
 "
 
 DEPENDS_remove_libc-baremetal := "virtual/${TARGET_PREFIX}libc-for-gcc"
 EXTRA_OECONF_append_libc-baremetal = " --without-headers"
 EXTRA_OECONF_remove_libc-baremetal = "--enable-threads=posix"
+EXTRA_OECONF_remove_libc-newlib = "--enable-threads=posix"
 
 EXTRA_OECONF_PATHS = "\
     --with-gxx-include-dir=/not/exist${target_includedir}/c++/${BINV} \
diff --git a/poky/meta/recipes-devtools/gcc/gcc-cross_8.2.bb b/poky/meta/recipes-devtools/gcc/gcc-cross_8.2.bb
new file mode 100644
index 0000000..b43cca0
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-cross_8.2.bb
@@ -0,0 +1,3 @@
+require recipes-devtools/gcc/gcc-${PV}.inc
+require gcc-cross.inc
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-crosssdk-initial_8.2.bb b/poky/meta/recipes-devtools/gcc/gcc-crosssdk-initial_8.2.bb
new file mode 100644
index 0000000..fd90e11
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-crosssdk-initial_8.2.bb
@@ -0,0 +1,3 @@
+require recipes-devtools/gcc/gcc-cross-initial_${PV}.bb
+require gcc-crosssdk-initial.inc
+
diff --git a/poky/meta/recipes-devtools/gcc/gcc-crosssdk_8.2.bb b/poky/meta/recipes-devtools/gcc/gcc-crosssdk_8.2.bb
new file mode 100644
index 0000000..40a6c4f
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-crosssdk_8.2.bb
@@ -0,0 +1,2 @@
+require recipes-devtools/gcc/gcc-cross_${PV}.bb
+require gcc-crosssdk.inc
diff --git a/poky/meta/recipes-devtools/gcc/gcc-runtime.inc b/poky/meta/recipes-devtools/gcc/gcc-runtime.inc
index 7629fa5..9e7e7c5 100644
--- a/poky/meta/recipes-devtools/gcc/gcc-runtime.inc
+++ b/poky/meta/recipes-devtools/gcc/gcc-runtime.inc
@@ -17,13 +17,16 @@
 EXTRA_OECONF_append_linuxstdbase = " --enable-clocale=gnu"
 
 RUNTIMELIBITM = "libitm"
+RUNTIMELIBITM_arc = ""
 RUNTIMELIBITM_mipsarch = ""
 RUNTIMELIBITM_nios2 = ""
 RUNTIMELIBITM_microblaze = ""
 RUNTIMELIBITM_riscv32 = ""
 RUNTIMELIBITM_riscv64 = ""
+RUNTIMELIBSSP ?= ""
+RUNTIMELIBSSP_mingw32 ?= "libssp"
 
-RUNTIMETARGET = "libssp libstdc++-v3 libgomp libatomic ${RUNTIMELIBITM} \
+RUNTIMETARGET = "${RUNTIMELIBSSP} libstdc++-v3 libgomp libatomic ${RUNTIMELIBITM} \
     ${@bb.utils.contains_any('FORTRAN', [',fortran',',f77'], 'libquadmath', '', d)} \
 "
 RUNTIMETARGET_append_x86 = " libmpx"
diff --git a/poky/meta/recipes-devtools/gcc/gcc-runtime_8.2.bb b/poky/meta/recipes-devtools/gcc/gcc-runtime_8.2.bb
new file mode 100644
index 0000000..a1c7a76
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-runtime_8.2.bb
@@ -0,0 +1,12 @@
+require recipes-devtools/gcc/gcc-${PV}.inc
+require gcc-runtime.inc
+
+# Disable ifuncs for libatomic on arm conflicts -march/-mcpu
+EXTRA_OECONF_append_arm = " libat_cv_have_ifunc=no "
+
+FILES_libgomp-dev += "\
+    ${libdir}/gcc/${TARGET_SYS}/${BINV}/include/openacc.h \
+"
+
+# Building with thumb enabled on armv6t fails
+ARM_INSTRUCTION_SET_armv6 = "arm"
diff --git a/poky/meta/recipes-devtools/gcc/gcc-sanitizers.inc b/poky/meta/recipes-devtools/gcc/gcc-sanitizers.inc
index 3b7e002..e5e8452 100644
--- a/poky/meta/recipes-devtools/gcc/gcc-sanitizers.inc
+++ b/poky/meta/recipes-devtools/gcc/gcc-sanitizers.inc
@@ -94,6 +94,7 @@
 FILES_liblsan-dev += "\
     ${libdir}/liblsan.so \
     ${libdir}/liblsan.la \
+    ${libdir}/liblsan_preinit.o \
 "
 FILES_liblsan-staticdev += "${libdir}/liblsan.a"
 
diff --git a/poky/meta/recipes-devtools/gcc/gcc-sanitizers_8.2.bb b/poky/meta/recipes-devtools/gcc/gcc-sanitizers_8.2.bb
new file mode 100644
index 0000000..f3c7058
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-sanitizers_8.2.bb
@@ -0,0 +1,7 @@
+require recipes-devtools/gcc/gcc-${PV}.inc
+require gcc-sanitizers.inc
+
+# Building with thumb enabled on armv4t armv5t fails with
+# sanitizer_linux.s:5749: Error: lo register required -- `ldr ip,[sp],#8'
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
diff --git a/poky/meta/recipes-devtools/gcc/gcc-source_8.2.bb b/poky/meta/recipes-devtools/gcc/gcc-source_8.2.bb
new file mode 100644
index 0000000..b890fa3
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc-source_8.2.bb
@@ -0,0 +1,4 @@
+require recipes-devtools/gcc/gcc-${PV}.inc
+require recipes-devtools/gcc/gcc-source.inc
+
+EXCLUDE_FROM_WORLD = "1"
diff --git a/poky/meta/recipes-devtools/gcc/gcc-target.inc b/poky/meta/recipes-devtools/gcc/gcc-target.inc
index b6e31f5..bc2236f 100644
--- a/poky/meta/recipes-devtools/gcc/gcc-target.inc
+++ b/poky/meta/recipes-devtools/gcc/gcc-target.inc
@@ -9,13 +9,17 @@
 
 EXTRA_OECONF_append_linuxstdbase = " --enable-clocale=gnu"
 
-# ARMv6+ adds atomic instructions that affect the ABI in libraries built
-# with TUNE_CCARGS in gcc-runtime.  Make the compiler default to a
-# compatible architecture.  armv6 and armv7a cover the minimum tune
-# features used in OE.
-EXTRA_OECONF_append_armv6 = " --with-arch=armv6"
-EXTRA_OECONF_append_armv7a = " --with-arch=armv7-a"
-EXTRA_OECONF_append_armv7ve = " --with-arch=armv7-a"
+# Configure gcc running on the target to default to an architecture which will
+# be compatible with that of gcc-runtime (which is cross compiled to be target
+# specific). For example, for ARM, ARMv6+ adds atomic instructions that may
+# affect the ABI in the gcc-runtime libs. Since we can't rely on gcc on the
+# target to always be passed -march etc, its built-in default needs to be safe.
+
+ARMFPARCHEXT ?= ""
+
+EXTRA_OECONF_append_armv6 = " --with-arch=armv6${ARMFPARCHEXT}"
+EXTRA_OECONF_append_armv7a = " --with-arch=armv7-a${ARMFPARCHEXT}"
+EXTRA_OECONF_append_armv7ve = " --with-arch=armv7ve${ARMFPARCHEXT}"
 
 # libcc1 requres gcc_cv_objdump when cross build, but gcc_cv_objdump is
 # set in subdir gcc, so subdir libcc1 can't use it, export it here to
diff --git a/poky/meta/recipes-devtools/gcc/gcc_8.2.bb b/poky/meta/recipes-devtools/gcc/gcc_8.2.bb
new file mode 100644
index 0000000..7d93590
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/gcc_8.2.bb
@@ -0,0 +1,14 @@
+require recipes-devtools/gcc/gcc-${PV}.inc
+require gcc-target.inc
+
+# Building with thumb enabled on armv4t armv5t fails with
+# | gcc-4.8.1-r0/gcc-4.8.1/gcc/cp/decl.c:7438:(.text.unlikely+0x2fa): relocation truncated to fit: R_ARM_THM_CALL against symbol `fancy_abort(char const*, int, char const*)' defined in .glue_7 section in linker stubs
+# | gcc-4.8.1-r0/gcc-4.8.1/gcc/cp/decl.c:7442:(.text.unlikely+0x318): additional relocation overflows omitted from the output
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
+
+ARMFPARCHEXT_armv6 = "${@'+fp' if d.getVar('TARGET_FPU') == 'hard' else ''}"
+ARMFPARCHEXT_armv7a = "${@'+fp' if d.getVar('TARGET_FPU') == 'hard' else ''}"
+ARMFPARCHEXT_armv7ve = "${@'+fp' if d.getVar('TARGET_FPU') == 'hard' else ''}"
+
+BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-devtools/gcc/libgcc-common.inc b/poky/meta/recipes-devtools/gcc/libgcc-common.inc
index 848a476..d959566 100644
--- a/poky/meta/recipes-devtools/gcc/libgcc-common.inc
+++ b/poky/meta/recipes-devtools/gcc/libgcc-common.inc
@@ -47,8 +47,13 @@
 do_install_append_libc-baremetal () {
 	rmdir ${D}${base_libdir}
 }
+do_install_append_libc-newlib () {
+	rmdir ${D}${base_libdir}
+}
 
+# No rpm package is actually created but -dev depends on it, avoid dnf error
 RDEPENDS_${PN}-dev_libc-baremetal = ""
+RDEPENDS_${PN}-dev_libc-newlib = ""
 
 BBCLASSEXTEND = "nativesdk"
 
diff --git a/poky/meta/recipes-devtools/gcc/libgcc-initial_8.2.bb b/poky/meta/recipes-devtools/gcc/libgcc-initial_8.2.bb
new file mode 100644
index 0000000..0c698c2
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/libgcc-initial_8.2.bb
@@ -0,0 +1,5 @@
+require recipes-devtools/gcc/gcc-${PV}.inc
+require libgcc-initial.inc
+
+# Building with thumb enabled on armv6t fails
+ARM_INSTRUCTION_SET_armv6 = "arm"
diff --git a/poky/meta/recipes-devtools/gcc/libgcc_8.2.bb b/poky/meta/recipes-devtools/gcc/libgcc_8.2.bb
new file mode 100644
index 0000000..ea210a1
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/libgcc_8.2.bb
@@ -0,0 +1,5 @@
+require recipes-devtools/gcc/gcc-${PV}.inc
+require libgcc.inc
+
+# Building with thumb enabled on armv6t fails
+ARM_INSTRUCTION_SET_armv6 = "arm"
diff --git a/poky/meta/recipes-devtools/gcc/libgfortran_8.2.bb b/poky/meta/recipes-devtools/gcc/libgfortran_8.2.bb
new file mode 100644
index 0000000..71dd8b4
--- /dev/null
+++ b/poky/meta/recipes-devtools/gcc/libgfortran_8.2.bb
@@ -0,0 +1,3 @@
+require recipes-devtools/gcc/gcc-${PV}.inc
+require libgfortran.inc
+
diff --git a/poky/meta/recipes-devtools/gdb/gdb-8.0.1.inc b/poky/meta/recipes-devtools/gdb/gdb-8.0.1.inc
deleted file mode 100644
index 4a5299b..0000000
--- a/poky/meta/recipes-devtools/gdb/gdb-8.0.1.inc
+++ /dev/null
@@ -1,24 +0,0 @@
-LICENSE = "GPLv2 & GPLv3 & LGPLv2 & LGPLv3"
-LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
-		    file://COPYING3;md5=d32239bcb673463ab874e80d47fae504 \
-		    file://COPYING3.LIB;md5=6a6a8e020838b23406c81b19c1d46df6 \
-		    file://COPYING.LIB;md5=9f604d8a4f8e74f4f5140845a21b6674"
-
-SRC_URI = "http://ftp.gnu.org/gnu/gdb/gdb-${PV}.tar.xz \
-           file://0001-include-sys-types.h-for-mode_t.patch \
-           file://0002-make-man-install-relative-to-DESTDIR.patch \
-           file://0003-mips-linux-nat-Define-_ABIO32-if-not-defined.patch \
-           file://0004-ppc-ptrace-Define-pt_regs-uapi_pt_regs-on-GLIBC-syst.patch \
-           file://0005-Add-support-for-Renesas-SH-sh4-architecture.patch \
-           file://0006-Dont-disable-libreadline.a-when-using-disable-static.patch \
-           file://0007-use-asm-sgidefs.h.patch \
-           file://0008-Use-exorted-definitions-of-SIGRTMIN.patch \
-           file://0009-Change-order-of-CFLAGS.patch \
-           file://0010-resolve-restrict-keyword-conflict.patch \
-           file://package_devel_gdb_patches_120-sigprocmask-invalid-call.patch \
-           file://0012-Unbreak-GDBserver-build-for-x32.patch \
-           file://gdb-Fix-ia64-defining-TRAP_HWBKPT-before-including-g.patch \
-"
-SRC_URI[md5sum] = "48cac527e6f3018b865ece021e9723ac"
-SRC_URI[sha256sum] = "3dbd5f93e36ba2815ad0efab030dcd0c7b211d7b353a40a53f4c02d7d56295e3"
-
diff --git a/poky/meta/recipes-devtools/gdb/gdb-8.2.inc b/poky/meta/recipes-devtools/gdb/gdb-8.2.inc
new file mode 100644
index 0000000..dfb0059
--- /dev/null
+++ b/poky/meta/recipes-devtools/gdb/gdb-8.2.inc
@@ -0,0 +1,23 @@
+LICENSE = "GPLv2 & GPLv3 & LGPLv2 & LGPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
+		    file://COPYING3;md5=d32239bcb673463ab874e80d47fae504 \
+		    file://COPYING3.LIB;md5=6a6a8e020838b23406c81b19c1d46df6 \
+		    file://COPYING.LIB;md5=9f604d8a4f8e74f4f5140845a21b6674"
+
+SRC_URI = "http://ftp.gnu.org/gnu/gdb/gdb-${PV}.tar.xz \
+           file://0001-include-sys-types.h-for-mode_t.patch \
+           file://0002-make-man-install-relative-to-DESTDIR.patch \
+           file://0003-mips-linux-nat-Define-_ABIO32-if-not-defined.patch \
+           file://0004-ppc-ptrace-Define-pt_regs-uapi_pt_regs-on-GLIBC-syst.patch \
+           file://0005-Add-support-for-Renesas-SH-sh4-architecture.patch \
+           file://0006-Dont-disable-libreadline.a-when-using-disable-static.patch \
+           file://0007-use-asm-sgidefs.h.patch \
+           file://0008-Use-exorted-definitions-of-SIGRTMIN.patch \
+           file://0009-Change-order-of-CFLAGS.patch \
+           file://0010-resolve-restrict-keyword-conflict.patch \
+           file://0011-Fix-invalid-sigprocmask-call.patch \
+           file://gdbserver-ctrl-c-handling.patch \
+"
+SRC_URI[md5sum] = "b5a49dbff00d9a87fbe114d14b3101c0"
+SRC_URI[sha256sum] = "c3a441a29c7c89720b734e5a9c6289c0a06be7e0c76ef538f7bbcef389347c39"
+
diff --git a/poky/meta/recipes-devtools/gdb/gdb-common.inc b/poky/meta/recipes-devtools/gdb/gdb-common.inc
index 039577b..fa64939 100644
--- a/poky/meta/recipes-devtools/gdb/gdb-common.inc
+++ b/poky/meta/recipes-devtools/gdb/gdb-common.inc
@@ -1,7 +1,7 @@
 SUMMARY = "GNU debugger"
 HOMEPAGE = "http://www.gnu.org/software/gdb/"
 SECTION = "devel"
-DEPENDS = "expat zlib ncurses virtual/libiconv ${LTTNGUST}"
+DEPENDS = "expat zlib ncurses virtual/libiconv ${LTTNGUST} bison-native"
 
 LTTNGUST = "lttng-ust"
 LTTNGUST_aarch64 = ""
@@ -20,7 +20,7 @@
 
 EXPAT = "--with-expat --with-libexpat-prefix=${STAGING_DIR_HOST}"
 
-EXTRA_OECONF = "--disable-gdbtk --disable-tui --disable-x --disable-werror \
+EXTRA_OECONF = "--disable-gdbtk --disable-x --disable-werror \
                 --with-curses --disable-multilib --disable-sim \
                 --without-lzma --without-guile \
                 ${GDBPROPREFIX} ${EXPAT} \
@@ -36,6 +36,8 @@
 PACKAGECONFIG[readline] = "--with-system-readline,--without-system-readline,readline"
 PACKAGECONFIG[python] = "--with-python=${WORKDIR}/python,--without-python,python3,python3 python3-codecs"
 PACKAGECONFIG[babeltrace] = "--with-babeltrace,--without-babeltrace,babeltrace"
+# ncurses is already a hard DEPENDS, but would be added here if it weren't
+PACKAGECONFIG[tui] = "--enable-tui,--disable-tui"
 
 GDBPROPREFIX = "--program-prefix=''"
 
diff --git a/poky/meta/recipes-devtools/gdb/gdb-cross-canadian_8.0.1.bb b/poky/meta/recipes-devtools/gdb/gdb-cross-canadian_8.2.bb
similarity index 100%
rename from poky/meta/recipes-devtools/gdb/gdb-cross-canadian_8.0.1.bb
rename to poky/meta/recipes-devtools/gdb/gdb-cross-canadian_8.2.bb
diff --git a/poky/meta/recipes-devtools/gdb/gdb-cross_8.0.1.bb b/poky/meta/recipes-devtools/gdb/gdb-cross_8.2.bb
similarity index 100%
rename from poky/meta/recipes-devtools/gdb/gdb-cross_8.0.1.bb
rename to poky/meta/recipes-devtools/gdb/gdb-cross_8.2.bb
diff --git a/poky/meta/recipes-devtools/gdb/gdb/0001-include-sys-types.h-for-mode_t.patch b/poky/meta/recipes-devtools/gdb/gdb/0001-include-sys-types.h-for-mode_t.patch
index 4f06d46..2c8783e 100644
--- a/poky/meta/recipes-devtools/gdb/gdb/0001-include-sys-types.h-for-mode_t.patch
+++ b/poky/meta/recipes-devtools/gdb/gdb/0001-include-sys-types.h-for-mode_t.patch
@@ -1,30 +1,29 @@
-From 91da0458b333249eb9c2f4c1f1e53fa4bc085cc9 Mon Sep 17 00:00:00 2001
+From 6ae0fb9b49047cef338262e30273f63139fd1261 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Tue, 19 Jan 2016 18:18:52 -0800
-Subject: [PATCH 01/10] include sys/types.h for mode_t
+Subject: [PATCH 01/11] include sys/types.h for mode_t
 
 mode_t is used in target.h, so we need to include sys/types.h to get the
 defintion
 
+Upstream-Status: Pending
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 ---
-Upstream-Status: Pending
-
  gdb/gdbserver/target.h | 1 +
  1 file changed, 1 insertion(+)
 
 diff --git a/gdb/gdbserver/target.h b/gdb/gdbserver/target.h
-index 3cc2bc4bab..e6b19b06b9 100644
+index fce54e05ad..278cee78a8 100644
 --- a/gdb/gdbserver/target.h
 +++ b/gdb/gdbserver/target.h
-@@ -28,6 +28,7 @@
- #include "target/waitstatus.h"
+@@ -29,6 +29,7 @@
  #include "mem-break.h"
  #include "btrace-common.h"
+ #include <vector>
 +#include <sys/types.h>
  
  struct emit_ops;
  struct buffer;
 -- 
-2.13.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/gdb/gdb/0002-make-man-install-relative-to-DESTDIR.patch b/poky/meta/recipes-devtools/gdb/gdb/0002-make-man-install-relative-to-DESTDIR.patch
index 83c4dde..60479e5 100644
--- a/poky/meta/recipes-devtools/gdb/gdb/0002-make-man-install-relative-to-DESTDIR.patch
+++ b/poky/meta/recipes-devtools/gdb/gdb/0002-make-man-install-relative-to-DESTDIR.patch
@@ -1,7 +1,7 @@
-From 9ce61f97b7758794f06894e934fbb256ff62163e Mon Sep 17 00:00:00 2001
+From b0209f282716bed2c230c7b496fbcc7af503d0cc Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 02:27:55 +0000
-Subject: [PATCH 02/10] make man install relative to DESTDIR
+Subject: [PATCH 02/11] make man install relative to DESTDIR
 
 Upstream-Status: Pending
 
@@ -11,7 +11,7 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/sim/common/Makefile.in b/sim/common/Makefile.in
-index 3944956b5d..aa355e8347 100644
+index 227e4cfbc2..8c3457e0bd 100644
 --- a/sim/common/Makefile.in
 +++ b/sim/common/Makefile.in
 @@ -35,7 +35,7 @@ tooldir = $(libdir)/$(target_alias)
@@ -24,5 +24,5 @@
  includedir = @includedir@
  
 -- 
-2.13.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/gdb/gdb/0003-mips-linux-nat-Define-_ABIO32-if-not-defined.patch b/poky/meta/recipes-devtools/gdb/gdb/0003-mips-linux-nat-Define-_ABIO32-if-not-defined.patch
index 6f7955b..cf54c74 100644
--- a/poky/meta/recipes-devtools/gdb/gdb/0003-mips-linux-nat-Define-_ABIO32-if-not-defined.patch
+++ b/poky/meta/recipes-devtools/gdb/gdb/0003-mips-linux-nat-Define-_ABIO32-if-not-defined.patch
@@ -1,7 +1,7 @@
-From ca0ef06b7320912df350e730e63f9bafdaa6ea70 Mon Sep 17 00:00:00 2001
+From b14a57d90e1cdd8144cda4c8882bd1db44d26dab Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Wed, 23 Mar 2016 06:30:09 +0000
-Subject: [PATCH 03/10] mips-linux-nat: Define _ABIO32 if not defined
+Subject: [PATCH 03/11] mips-linux-nat: Define _ABIO32 if not defined
 
 This helps building gdb on mips64 on musl, since
 musl does not provide sgidefs.h this define is
@@ -9,29 +9,27 @@
 case gcc emits it as built-in define and hence
 it works ok for mips32
 
+Upstream-Status: Pending
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 ---
-Upstream-Status: Pending
-
- gdb/mips-linux-nat.c | 5 +++++
- 1 file changed, 5 insertions(+)
+ gdb/mips-linux-nat.c | 4 ++++
+ 1 file changed, 4 insertions(+)
 
 diff --git a/gdb/mips-linux-nat.c b/gdb/mips-linux-nat.c
-index 8041d84be7..f2df1b9907 100644
+index 32835c16b2..68a7587af2 100644
 --- a/gdb/mips-linux-nat.c
 +++ b/gdb/mips-linux-nat.c
-@@ -47,6 +47,11 @@
+@@ -41,6 +41,10 @@
+ #ifndef PTRACE_GET_THREAD_AREA
  #define PTRACE_GET_THREAD_AREA 25
  #endif
- 
 +/* musl does not define and relies on compiler built-in macros for it   */
 +#ifndef _ABIO32
 +#define _ABIO32 1
 +#endif
-+
- /* Assume that we have PTRACE_GETREGS et al. support.  If we do not,
-    we'll clear this and use PTRACE_PEEKUSER instead.  */
- static int have_ptrace_regsets = 1;
+ 
+ class mips_linux_nat_target final : public linux_nat_trad_target
+ {
 -- 
-2.13.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/gdb/gdb/0004-ppc-ptrace-Define-pt_regs-uapi_pt_regs-on-GLIBC-syst.patch b/poky/meta/recipes-devtools/gdb/gdb/0004-ppc-ptrace-Define-pt_regs-uapi_pt_regs-on-GLIBC-syst.patch
index 357db25..bbe0020 100644
--- a/poky/meta/recipes-devtools/gdb/gdb/0004-ppc-ptrace-Define-pt_regs-uapi_pt_regs-on-GLIBC-syst.patch
+++ b/poky/meta/recipes-devtools/gdb/gdb/0004-ppc-ptrace-Define-pt_regs-uapi_pt_regs-on-GLIBC-syst.patch
@@ -1,7 +1,7 @@
-From 0f6d71118ca914002fcad78d2c8a518223d06bfb Mon Sep 17 00:00:00 2001
+From 1dd5c44474b01d84de60faded960fef4a0a87e41 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sat, 30 Apr 2016 18:32:14 -0700
-Subject: [PATCH 04/10] ppc/ptrace: Define pt_regs uapi_pt_regs on !GLIBC
+Subject: [PATCH 04/11] ppc/ptrace: Define pt_regs uapi_pt_regs on !GLIBC
  systems
 
 Upstream-Status: Pending
@@ -13,7 +13,7 @@
  2 files changed, 12 insertions(+)
 
 diff --git a/gdb/gdbserver/linux-ppc-low.c b/gdb/gdbserver/linux-ppc-low.c
-index 33a9feb12c..1a9141faef 100644
+index 47428c1529..841a5e02b9 100644
 --- a/gdb/gdbserver/linux-ppc-low.c
 +++ b/gdb/gdbserver/linux-ppc-low.c
 @@ -21,7 +21,13 @@
@@ -28,10 +28,10 @@
 +# undef pt_regs
 +#endif
  
- #include "nat/ppc-linux.h"
- #include "linux-ppc-tdesc.h"
+ #include "arch/ppc-linux-common.h"
+ #include "arch/ppc-linux-tdesc.h"
 diff --git a/gdb/nat/ppc-linux.h b/gdb/nat/ppc-linux.h
-index 5837ea1767..7233929192 100644
+index 3d4d4fdc56..5b93af8d3a 100644
 --- a/gdb/nat/ppc-linux.h
 +++ b/gdb/nat/ppc-linux.h
 @@ -18,7 +18,13 @@
@@ -49,5 +49,5 @@
  
  /* This sometimes isn't defined.  */
 -- 
-2.13.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/gdb/gdb/0005-Add-support-for-Renesas-SH-sh4-architecture.patch b/poky/meta/recipes-devtools/gdb/gdb/0005-Add-support-for-Renesas-SH-sh4-architecture.patch
index cb1b7ab..f840caf 100644
--- a/poky/meta/recipes-devtools/gdb/gdb/0005-Add-support-for-Renesas-SH-sh4-architecture.patch
+++ b/poky/meta/recipes-devtools/gdb/gdb/0005-Add-support-for-Renesas-SH-sh4-architecture.patch
@@ -1,7 +1,7 @@
-From 60ac68f601885ea6480229a5c8a89a0257da376c Mon Sep 17 00:00:00 2001
+From 215486b53a7a6dfca064cd2e9196a9de6ed6f0c2 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 02:31:12 +0000
-Subject: [PATCH 05/10] Add support for Renesas SH (sh4) architecture.
+Subject: [PATCH 05/11] Add support for Renesas SH (sh4) architecture.
 
 gdb (7.4-1~cvs20111117.2) experimental; urgency=low
  .
@@ -15,35 +15,35 @@
 ---
  gdb/Makefile.in                      |   2 +
  gdb/configure.host                   |   1 +
- gdb/sh-linux-tdep.c                  | 519 +++++++++++++++++++++++++++++++++++
- gdb/sh-tdep.c                        |  54 ++--
- gdb/sh-tdep.h                        |  49 ++++
+ gdb/sh-linux-tdep.c                  | 519 +++++++++++++++++++++++++++
+ gdb/sh-tdep.c                        |  53 ++-
+ gdb/sh-tdep.h                        |  49 +++
  gdb/testsuite/gdb.asm/asm-source.exp |   5 +
  gdb/testsuite/gdb.asm/sh.inc         |   3 +-
  gdb/testsuite/gdb.base/annota1.c     |   3 +
  gdb/testsuite/gdb.base/annota3.c     |   4 +
  gdb/testsuite/gdb.base/sigall.c      |   3 +
  gdb/testsuite/gdb.base/signals.c     |   4 +
- 11 files changed, 618 insertions(+), 29 deletions(-)
+ 11 files changed, 617 insertions(+), 29 deletions(-)
 
 diff --git a/gdb/Makefile.in b/gdb/Makefile.in
-index 8be73ba423..e287ff6a2e 100644
+index c76a4e4394..921fdadb49 100644
 --- a/gdb/Makefile.in
 +++ b/gdb/Makefile.in
-@@ -2638,6 +2638,8 @@ ALLDEPFILES = \
+@@ -2326,6 +2326,8 @@ ALLDEPFILES = \
+ 	sh-nbsd-nat.c \
  	sh-nbsd-tdep.c \
  	sh-tdep.c \
- 	sh64-tdep.c \
 +	sh-linux-tdep.c \
 +	sh-linux-nat.c \
  	sol2-tdep.c \
  	solib-aix.c \
  	solib-spu.c \
 diff --git a/gdb/configure.host b/gdb/configure.host
-index d74fd04934..be12de1446 100644
+index 23a2f16399..39a886ec53 100644
 --- a/gdb/configure.host
 +++ b/gdb/configure.host
-@@ -150,6 +150,7 @@ powerpc*-*-linux*)	gdb_host=linux ;;
+@@ -153,6 +153,7 @@ riscv*-*-linux*)	gdb_host=linux ;;
  
  s390*-*-linux*)		gdb_host=linux ;;
  
@@ -52,7 +52,7 @@
  			gdb_host=nbsd ;;
  sh*-*-openbsd*)		gdb_host=nbsd ;;
 diff --git a/gdb/sh-linux-tdep.c b/gdb/sh-linux-tdep.c
-index c5c745d218..84e539aad3 100644
+index db93967910..4109c549e8 100644
 --- a/gdb/sh-linux-tdep.c
 +++ b/gdb/sh-linux-tdep.c
 @@ -18,14 +18,37 @@
@@ -600,7 +600,7 @@
  
    /* GNU/Linux uses SVR4-style shared libraries.  */
 diff --git a/gdb/sh-tdep.c b/gdb/sh-tdep.c
-index 2c2b26847d..14f5281ed4 100644
+index fe64cf979a..4417114cd0 100644
 --- a/gdb/sh-tdep.c
 +++ b/gdb/sh-tdep.c
 @@ -21,6 +21,9 @@
@@ -613,15 +613,7 @@
  #include "frame.h"
  #include "frame-base.h"
  #include "frame-unwind.h"
-@@ -35,6 +38,7 @@
- #include "arch-utils.h"
- #include "floatformat.h"
- #include "regcache.h"
-+#include "regset.h"
- #include "doublest.h"
- #include "osabi.h"
- #include "reggroups.h"
-@@ -68,23 +72,6 @@ static const char *const sh_cc_enum[] = {
+@@ -66,23 +69,6 @@ static const char *const sh_cc_enum[] = {
  
  static const char *sh_active_calling_convention = sh_cc_gcc;
  
@@ -645,7 +637,7 @@
  static int
  sh_is_renesas_calling_convention (struct type *func_type)
  {
-@@ -1052,7 +1039,7 @@ sh_treat_as_flt_p (struct type *type)
+@@ -1050,7 +1036,7 @@ sh_treat_as_flt_p (struct type *type)
      return 0;
    /* Otherwise if the type of that member is float, the whole type is
       treated as float.  */
@@ -654,7 +646,7 @@
      return 1;
    /* Otherwise it's not treated as float.  */
    return 0;
-@@ -1102,7 +1089,7 @@ sh_push_dummy_call_fpu (struct gdbarch *gdbarch,
+@@ -1100,7 +1086,7 @@ sh_push_dummy_call_fpu (struct gdbarch *gdbarch,
       in four registers available.  Loop thru args from first to last.  */
    for (argnum = 0; argnum < nargs; argnum++)
      {
@@ -663,7 +655,7 @@
        len = TYPE_LENGTH (type);
        val = sh_justify_value_in_reg (gdbarch, args[argnum], len);
  
-@@ -1828,7 +1815,7 @@ sh_dwarf2_frame_init_reg (struct gdbarch *gdbarch, int regnum,
+@@ -1834,7 +1820,7 @@ sh_dwarf2_frame_init_reg (struct gdbarch *gdbarch, int regnum,
      reg->how = DWARF2_FRAME_REG_UNDEFINED;
  }
  
@@ -672,7 +664,7 @@
  sh_alloc_frame_cache (void)
  {
    struct sh_frame_cache *cache;
-@@ -1855,7 +1842,7 @@ sh_alloc_frame_cache (void)
+@@ -1861,7 +1847,7 @@ sh_alloc_frame_cache (void)
    return cache;
  }
  
@@ -681,7 +673,7 @@
  sh_frame_cache (struct frame_info *this_frame, void **this_cache)
  {
    struct gdbarch *gdbarch = get_frame_arch (this_frame);
-@@ -1922,9 +1909,9 @@ sh_frame_cache (struct frame_info *this_frame, void **this_cache)
+@@ -1928,9 +1914,9 @@ sh_frame_cache (struct frame_info *this_frame, void **this_cache)
    return cache;
  }
  
@@ -694,7 +686,7 @@
  {
    struct gdbarch *gdbarch = get_frame_arch (this_frame);
    struct sh_frame_cache *cache = sh_frame_cache (this_frame, this_cache);
-@@ -1938,7 +1925,7 @@ sh_frame_prev_register (struct frame_info *this_frame,
+@@ -1944,7 +1930,7 @@ sh_frame_prev_register (struct frame_info *this_frame,
       the current frame.  Frob regnum so that we pull the value from
       the correct place.  */
    if (regnum == gdbarch_pc_regnum (gdbarch))
@@ -703,7 +695,7 @@
  
    if (regnum < SH_NUM_REGS && cache->saved_regs[regnum] != -1)
      return frame_unwind_got_memory (this_frame, regnum,
-@@ -2247,8 +2234,8 @@ sh_return_in_first_hidden_param_p (struct gdbarch *gdbarch,
+@@ -2255,8 +2241,8 @@ sh_return_in_first_hidden_param_p (struct gdbarch *gdbarch,
  static struct gdbarch *
  sh_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
  {
@@ -711,9 +703,9 @@
    struct gdbarch_tdep *tdep;
 +  struct gdbarch *gdbarch;
  
-   /* SH5 is handled entirely in sh64-tdep.c.  */
-   if (info.bfd_arch_info->mach == bfd_mach_sh5)
-@@ -2264,6 +2251,18 @@ sh_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
+   /* If there is already a candidate, use it.  */
+   arches = gdbarch_list_lookup_by_info (arches, &info);
+@@ -2268,6 +2254,18 @@ sh_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
    tdep = XCNEW (struct gdbarch_tdep);
    gdbarch = gdbarch_alloc (&info, tdep);
  
@@ -732,7 +724,7 @@
    set_gdbarch_short_bit (gdbarch, 2 * TARGET_CHAR_BIT);
    set_gdbarch_int_bit (gdbarch, 4 * TARGET_CHAR_BIT);
    set_gdbarch_long_bit (gdbarch, 4 * TARGET_CHAR_BIT);
-@@ -2418,10 +2417,11 @@ sh_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
+@@ -2422,10 +2420,11 @@ sh_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
        break;
      }
  
@@ -746,7 +738,7 @@
    frame_unwind_append_unwinder (gdbarch, &sh_frame_unwind);
  
 diff --git a/gdb/sh-tdep.h b/gdb/sh-tdep.h
-index d15ef050e0..c4642cefa4 100644
+index 59acd35b88..be3f998d84 100644
 --- a/gdb/sh-tdep.h
 +++ b/gdb/sh-tdep.h
 @@ -21,6 +21,12 @@
@@ -829,7 +821,7 @@
       where each general-purpose register is stored inside the associated
       core file section.  */
 diff --git a/gdb/testsuite/gdb.asm/asm-source.exp b/gdb/testsuite/gdb.asm/asm-source.exp
-index e07e5543f2..f5e60e1002 100644
+index 9879f0ca47..cbc0e4d5f7 100644
 --- a/gdb/testsuite/gdb.asm/asm-source.exp
 +++ b/gdb/testsuite/gdb.asm/asm-source.exp
 @@ -116,6 +116,11 @@ switch -glob -- [istarget] {
@@ -918,5 +910,5 @@
  static int count = 0;
  
 -- 
-2.13.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/gdb/gdb/0006-Dont-disable-libreadline.a-when-using-disable-static.patch b/poky/meta/recipes-devtools/gdb/gdb/0006-Dont-disable-libreadline.a-when-using-disable-static.patch
index 8b13958..9ae3ee6 100644
--- a/poky/meta/recipes-devtools/gdb/gdb/0006-Dont-disable-libreadline.a-when-using-disable-static.patch
+++ b/poky/meta/recipes-devtools/gdb/gdb/0006-Dont-disable-libreadline.a-when-using-disable-static.patch
@@ -1,7 +1,7 @@
-From 5c92ebd5e117e4cf118c984171e0703dfcfb8cd8 Mon Sep 17 00:00:00 2001
+From 5fdd42acaa965be7c420a3f2ba12b77ea503c59b Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sat, 30 Apr 2016 15:25:03 -0700
-Subject: [PATCH 06/10] Dont disable libreadline.a when using --disable-static
+Subject: [PATCH 06/11] Dont disable libreadline.a when using --disable-static
 
 If gdb is configured with --disable-static then this is dutifully passed to
 readline which then disables libreadline.a, which causes a problem when gdb
@@ -19,7 +19,7 @@
  2 files changed, 3 insertions(+), 2 deletions(-)
 
 diff --git a/Makefile.def b/Makefile.def
-index 0d13f037d0..8bcd86e13f 100644
+index 75063b6d12..c27bbe4d28 100644
 --- a/Makefile.def
 +++ b/Makefile.def
 @@ -105,7 +105,8 @@ host_modules= { module= libiconv;
@@ -33,7 +33,7 @@
  host_modules= { module= sim; };
  host_modules= { module= texinfo; no_install= true; };
 diff --git a/Makefile.in b/Makefile.in
-index 3acb83b8de..e348907128 100644
+index 7814fe745f..3b0dc7cbb0 100644
 --- a/Makefile.in
 +++ b/Makefile.in
 @@ -25470,7 +25470,7 @@ configure-readline:
@@ -46,5 +46,5 @@
  @endif readline
  
 -- 
-2.13.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/gdb/gdb/0007-use-asm-sgidefs.h.patch b/poky/meta/recipes-devtools/gdb/gdb/0007-use-asm-sgidefs.h.patch
index 33b4c30..808f4bf 100644
--- a/poky/meta/recipes-devtools/gdb/gdb/0007-use-asm-sgidefs.h.patch
+++ b/poky/meta/recipes-devtools/gdb/gdb/0007-use-asm-sgidefs.h.patch
@@ -1,7 +1,7 @@
-From 12a0b8d81e1fda6ba98abdce8d6f09f9555ebcf5 Mon Sep 17 00:00:00 2001
+From d6e12d52f9cef7f5e6315003ceaa236f6cc7723b Mon Sep 17 00:00:00 2001
 From: Andre McCurdy <amccurdy@gmail.com>
 Date: Sat, 30 Apr 2016 15:29:06 -0700
-Subject: [PATCH 07/10] use <asm/sgidefs.h>
+Subject: [PATCH 07/11] use <asm/sgidefs.h>
 
 Build fix for MIPS with musl libc
 
@@ -19,7 +19,7 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/gdb/mips-linux-nat.c b/gdb/mips-linux-nat.c
-index f2df1b9907..d24664cb56 100644
+index 68a7587af2..2b77221372 100644
 --- a/gdb/mips-linux-nat.c
 +++ b/gdb/mips-linux-nat.c
 @@ -31,7 +31,7 @@
@@ -32,5 +32,5 @@
  #include <asm/ptrace.h>
  #include "inf-ptrace.h"
 -- 
-2.13.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/gdb/gdb/0008-Use-exorted-definitions-of-SIGRTMIN.patch b/poky/meta/recipes-devtools/gdb/gdb/0008-Use-exorted-definitions-of-SIGRTMIN.patch
index 4f64dea..d32352b 100644
--- a/poky/meta/recipes-devtools/gdb/gdb/0008-Use-exorted-definitions-of-SIGRTMIN.patch
+++ b/poky/meta/recipes-devtools/gdb/gdb/0008-Use-exorted-definitions-of-SIGRTMIN.patch
@@ -1,7 +1,7 @@
-From d3f240b38eed7cd08f6c50ea896572f1327b437a Mon Sep 17 00:00:00 2001
+From d97878b272bd7c4993f4205983ae8b7ecddbcf82 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sat, 30 Apr 2016 15:31:40 -0700
-Subject: [PATCH 08/10] Use exorted definitions of SIGRTMIN
+Subject: [PATCH 08/11] Use exorted definitions of SIGRTMIN
 
 Define W_STOPCODE if not defined already
 
@@ -20,10 +20,10 @@
  2 files changed, 6 insertions(+), 2 deletions(-)
 
 diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
-index 8b29245c3d..f424ae9711 100644
+index 64015e7520..acf950c38b 100644
 --- a/gdb/linux-nat.c
 +++ b/gdb/linux-nat.c
-@@ -5021,6 +5021,6 @@ lin_thread_get_thread_signals (sigset_t *set)
+@@ -4724,6 +4724,6 @@ lin_thread_get_thread_signals (sigset_t *set)
    /* NPTL reserves the first two RT signals, but does not provide any
       way for the debugger to query the signal numbers - fortunately
       they don't change.  */
@@ -33,7 +33,7 @@
 +  sigaddset (set, SIGRTMIN + 1);
  }
 diff --git a/gdb/nat/linux-nat.h b/gdb/nat/linux-nat.h
-index 7dd18fefff..35137ab34f 100644
+index a90a124d3a..4f3e681962 100644
 --- a/gdb/nat/linux-nat.h
 +++ b/gdb/nat/linux-nat.h
 @@ -90,4 +90,8 @@ extern void linux_stop_lwp (struct lwp_info *lwp);
@@ -46,5 +46,5 @@
 +
  #endif /* LINUX_NAT_H */
 -- 
-2.13.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/gdb/gdb/0009-Change-order-of-CFLAGS.patch b/poky/meta/recipes-devtools/gdb/gdb/0009-Change-order-of-CFLAGS.patch
index 0c103ef..bc4bc26 100644
--- a/poky/meta/recipes-devtools/gdb/gdb/0009-Change-order-of-CFLAGS.patch
+++ b/poky/meta/recipes-devtools/gdb/gdb/0009-Change-order-of-CFLAGS.patch
@@ -1,7 +1,7 @@
-From 3f54036b891054072b3e43ea8daaa57aa367b2e0 Mon Sep 17 00:00:00 2001
+From ba6ffa461fe781d44d6dcbc0fbd569237b450fdc Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sat, 30 Apr 2016 15:35:39 -0700
-Subject: [PATCH 09/10] Change order of CFLAGS
+Subject: [PATCH 09/11] Change order of CFLAGS
 
 Lets us override Werror if need be
 
@@ -13,10 +13,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/gdb/gdbserver/Makefile.in b/gdb/gdbserver/Makefile.in
-index 01dfdc0b89..f6aebef464 100644
+index f2f8a084bd..9528db1364 100644
 --- a/gdb/gdbserver/Makefile.in
 +++ b/gdb/gdbserver/Makefile.in
-@@ -140,7 +140,7 @@ CPPFLAGS = @CPPFLAGS@
+@@ -143,7 +143,7 @@ CPPFLAGS = @CPPFLAGS@
  INTERNAL_CFLAGS_BASE = ${CXXFLAGS} ${GLOBAL_CFLAGS} \
  	${PROFILE_CFLAGS} ${INCLUDE_CFLAGS} ${CPPFLAGS}
  INTERNAL_WARN_CFLAGS = ${INTERNAL_CFLAGS_BASE} $(WARN_CFLAGS)
@@ -26,5 +26,5 @@
  # LDFLAGS is specifically reserved for setting from the command line
  # when running make.
 -- 
-2.13.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/gdb/gdb/0010-resolve-restrict-keyword-conflict.patch b/poky/meta/recipes-devtools/gdb/gdb/0010-resolve-restrict-keyword-conflict.patch
index c950710..809d52f 100644
--- a/poky/meta/recipes-devtools/gdb/gdb/0010-resolve-restrict-keyword-conflict.patch
+++ b/poky/meta/recipes-devtools/gdb/gdb/0010-resolve-restrict-keyword-conflict.patch
@@ -1,7 +1,7 @@
-From 3ead0dd143521b0ba69c9e753bc4a236f9445ad9 Mon Sep 17 00:00:00 2001
+From 19b581056c1709f7d2872cd76b977542a0fe6142 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Tue, 10 May 2016 08:47:05 -0700
-Subject: [PATCH 10/10] resolve restrict keyword conflict
+Subject: [PATCH 10/11] resolve restrict keyword conflict
 
 GCC detects that we call 'restrict' as param name in function
 signatures and complains since both params are called 'restrict'
@@ -15,7 +15,7 @@
  1 file changed, 4 insertions(+), 4 deletions(-)
 
 diff --git a/gdb/gnulib/import/sys_time.in.h b/gdb/gnulib/import/sys_time.in.h
-index d535a6a48b..7c34d5a1aa 100644
+index b4a0e49c50..d22cea9aaf 100644
 --- a/gdb/gnulib/import/sys_time.in.h
 +++ b/gdb/gnulib/import/sys_time.in.h
 @@ -93,20 +93,20 @@ struct timeval
@@ -44,5 +44,5 @@
  _GL_CXXALIASWARN (gettimeofday);
  # if defined __cplusplus && defined GNULIB_NAMESPACE
 -- 
-2.13.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/gdb/gdb/0011-Fix-invalid-sigprocmask-call.patch b/poky/meta/recipes-devtools/gdb/gdb/0011-Fix-invalid-sigprocmask-call.patch
new file mode 100644
index 0000000..bce025c
--- /dev/null
+++ b/poky/meta/recipes-devtools/gdb/gdb/0011-Fix-invalid-sigprocmask-call.patch
@@ -0,0 +1,49 @@
+From b1985595e46721bb168ac38f4c841a915cc2f799 Mon Sep 17 00:00:00 2001
+From: Yousong Zhou <yszhou4tech@gmail.com>
+Date: Fri, 24 Mar 2017 10:36:03 +0800
+Subject: [PATCH 11/11] Fix invalid sigprocmask call
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+The POSIX document says
+
+    The pthread_sigmask() and sigprocmask() functions shall fail if:
+
+    [EINVAL]
+    The value of the how argument is not equal to one of the defined values.
+
+and this is how musl-libc is currently doing.  Fix the call to be safe
+and correct
+
+ [1] http://pubs.opengroup.org/onlinepubs/9699919799/functions/pthread_sigmask.html
+
+gdb/ChangeLog:
+2017-03-24  Yousong Zhou  <yszhou4tech@gmail.com>
+
+    * common/signals-state-save-restore.c (save_original_signals_state):
+    Fix invalid sigprocmask call.
+
+Upstream-Status: Pending [not author, cherry-picked from LEDE https://bugs.lede-project.org/index.php?do=details&task_id=637&openedfrom=-1%2Bweek]
+Signed-off-by: André Draszik <adraszik@tycoint.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ gdb/common/signals-state-save-restore.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/gdb/common/signals-state-save-restore.c b/gdb/common/signals-state-save-restore.c
+index 5bb66321bb..6597decbc6 100644
+--- a/gdb/common/signals-state-save-restore.c
++++ b/gdb/common/signals-state-save-restore.c
+@@ -41,7 +41,7 @@ save_original_signals_state (bool quiet)
+   int i;
+   int res;
+ 
+-  res = sigprocmask (0,  NULL, &original_signal_mask);
++  res = sigprocmask (SIG_BLOCK,  NULL, &original_signal_mask);
+   if (res == -1)
+     perror_with_name (("sigprocmask"));
+ 
+-- 
+2.18.0
+
diff --git a/poky/meta/recipes-devtools/gdb/gdb/0012-Unbreak-GDBserver-build-for-x32.patch b/poky/meta/recipes-devtools/gdb/gdb/0012-Unbreak-GDBserver-build-for-x32.patch
deleted file mode 100644
index 18a3ce3..0000000
--- a/poky/meta/recipes-devtools/gdb/gdb/0012-Unbreak-GDBserver-build-for-x32.patch
+++ /dev/null
@@ -1,101 +0,0 @@
-From 3e1e401053ea5f02a9e9c65abddd31a03baa1bd1 Mon Sep 17 00:00:00 2001
-From: Yao Qi <yao.qi@linaro.org>
-Date: Fri, 29 Dec 2017 12:57:25 +0800
-Subject: [PATCH] Unbreak GDBserver build for x32
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-When I verify my target description changes, I build GDB and GDBserver for
-x32, but it failed.
-
-/../../binutils-gdb/gdb/gdbserver/linux-amd64-ipa.c
-../../../binutils-gdb/gdb/gdbserver/linux-amd64-ipa.c: In function ‘const target_desc* get_ipa_tdesc(int)’:
-../../../binutils-gdb/gdb/gdbserver/linux-amd64-ipa.c:184:10: error: ‘X86_TDESC_AVX512’ was not declared in this scope
-     case X86_TDESC_AVX512:
-          ^
-../../../binutils-gdb/gdb/gdbserver/linux-amd64-ipa.c:185:14: error: ‘tdesc_x32_avx512_linux’ was not declared in this scope
-       return tdesc_x32_avx512_linux;
-              ^
-../../../binutils-gdb/gdb/gdbserver/linux-amd64-ipa.c: In function ‘void initialize_low_tracepoint()’:
-../../../binutils-gdb/gdb/gdbserver/linux-amd64-ipa.c:282:36: error: ‘init_registers_x32_avx512_linux’ was not declared in this scope
-   init_registers_x32_avx512_linux ();
-                                    ^
-
-ipa_x32_linux_regobj use to be there, but removed by
-22049425ce40324139be82d9a6ec518c46b65815 by mistake.
-
-gdb/gdbserver:
-
-2017-08-04  Yao Qi  <yao.qi@linaro.org>
-
-        * configure.srv (ipa_x32_linux_regobj): New.
-        * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
-        instead of X86_TDESC_AVX512.
-        (initialize_low_tracepoint): Call
-        init_registers_x32_avx_avx512_linux.
-
-Upstream-Status: Backport [https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=commitdiff;h=f02fd7745d003d65fd3b981618e07b874b721d79]
-
-Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
----
- ChangeLog                       | 8 ++++++++
- gdb/gdbserver/configure.srv     | 1 +
- gdb/gdbserver/linux-amd64-ipa.c | 6 +++---
- 3 files changed, 12 insertions(+), 3 deletions(-)
-
-diff --git a/ChangeLog b/ChangeLog
-index 4ac2d63..b5b8228 100644
---- a/ChangeLog
-+++ b/ChangeLog
-@@ -1,3 +1,11 @@
-+ 2017-08-04  Yao Qi  <yao.qi@linaro.org>
-+
-+	* configure.srv (ipa_x32_linux_regobj): New.
-+	* linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
-+	instead of X86_TDESC_AVX512.
-+	(initialize_low_tracepoint): Call
-+	init_registers_x32_avx_avx512_linux.
-+
- 2017-04-13  Andrew Jenner  <andrew@codesourcery.com>
- 
- 	* config.sub: Sync with master version in config project.
-diff --git a/gdb/gdbserver/configure.srv b/gdb/gdbserver/configure.srv
-index d00d9e2..56951c8 100644
---- a/gdb/gdbserver/configure.srv
-+++ b/gdb/gdbserver/configure.srv
-@@ -31,6 +31,7 @@ srv_amd64_linux_regobj="amd64-linux.o amd64-avx-linux.o amd64-avx-avx512-linux.o
- 
- ipa_i386_linux_regobj="i386-linux-ipa.o i386-avx-linux-ipa.o  i386-avx-mpx-linux-ipa.o i386-avx-avx512-linux-ipa.o i386-avx-mpx-avx512-pku-linux-ipa.o i386-mpx-linux-ipa.o i386-mmx-linux-ipa.o"
- ipa_amd64_linux_regobj="amd64-linux-ipa.o amd64-avx-linux-ipa.o amd64-avx-mpx-linux-ipa.o amd64-avx-avx512-linux-ipa.o amd64-avx-mpx-avx512-pku-linux-ipa.o amd64-mpx-linux-ipa.o"
-+ipa_x32_linux_regobj="x32-linux-ipa.o x32-avx-linux-ipa.o x32-avx-avx512-linux-ipa.o"
- ipa_ppc_linux_regobj="powerpc-32l-ipa.o powerpc-altivec32l-ipa.o powerpc-cell32l-ipa.o powerpc-vsx32l-ipa.o powerpc-isa205-32l-ipa.o powerpc-isa205-altivec32l-ipa.o powerpc-isa205-vsx32l-ipa.o powerpc-e500l-ipa.o powerpc-64l-ipa.o powerpc-altivec64l-ipa.o powerpc-cell64l-ipa.o powerpc-vsx64l-ipa.o powerpc-isa205-64l-ipa.o powerpc-isa205-altivec64l-ipa.o powerpc-isa205-vsx64l-ipa.o"
- 
- srv_i386_32bit_xmlfiles="i386/32bit-core.xml i386/32bit-sse.xml i386/32bit-avx.xml i386/32bit-avx512.xml i386/32bit-mpx.xml i386/32bit-pkeys.xml"
-diff --git a/gdb/gdbserver/linux-amd64-ipa.c b/gdb/gdbserver/linux-amd64-ipa.c
-index 67f36c2..683339b 100644
---- a/gdb/gdbserver/linux-amd64-ipa.c
-+++ b/gdb/gdbserver/linux-amd64-ipa.c
-@@ -181,8 +181,8 @@ get_ipa_tdesc (int idx)
-       return tdesc_x32_linux;
-     case X86_TDESC_AVX:
-       return tdesc_x32_avx_linux;
--    case X86_TDESC_AVX512:
--      return tdesc_x32_avx512_linux;
-+    case X86_TDESC_AVX_AVX512:
-+      return tdesc_x32_avx_avx512_linux;
-     default:
-       break;
-     }
-@@ -279,7 +279,7 @@ initialize_low_tracepoint (void)
- #if defined __ILP32__
-   init_registers_x32_linux ();
-   init_registers_x32_avx_linux ();
--  init_registers_x32_avx512_linux ();
-+  init_registers_x32_avx_avx512_linux ();
- #else
-   init_registers_amd64_linux ();
-   init_registers_amd64_avx_linux ();
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-devtools/gdb/gdb/gdb-Fix-ia64-defining-TRAP_HWBKPT-before-including-g.patch b/poky/meta/recipes-devtools/gdb/gdb/gdb-Fix-ia64-defining-TRAP_HWBKPT-before-including-g.patch
deleted file mode 100644
index ef97de7..0000000
--- a/poky/meta/recipes-devtools/gdb/gdb/gdb-Fix-ia64-defining-TRAP_HWBKPT-before-including-g.patch
+++ /dev/null
@@ -1,56 +0,0 @@
-From b033a9663053eed87cb572397176747b88e9a699 Mon Sep 17 00:00:00 2001
-From: James Clarke <jrtc27@jrtc27.com>
-Date: Fri, 19 Jan 2018 17:22:49 +0000
-Subject: [PATCH] gdb: Fix ia64 defining TRAP_HWBKPT before including
- gdb_wait.h
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-On ia64, gdb_wait.h eventually includes siginfo-consts-arch.h, which
-contains an enum with TRAP_HWBKPT, along with a #define. Thus we cannot
-define TRAP_HWBKPT to 4 beforehand, and so gdb_wait.h must be included
-earlier; include it from linux-ptrace.h so it can never come afterwards.
-
-gdb/ChangeLog:
-
-	* nat/linux-ptrace.c: Remove unnecessary reinclusion of
-	gdb_ptrace.h, and move including gdb_wait.h ...
-	* nat/linux-ptrace.h: ... to here.
-
-Upstream-Status: Accepted [https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=commit;h=5a6c3296a7a90694ad4042f6256f3da6d4fa4ee8]
-
-Signed-off-by: Daniel Díaz <daniel.diaz@linaro.org>
----
- gdb/nat/linux-ptrace.c | 2 --
- gdb/nat/linux-ptrace.h | 1 +
- 2 files changed, 1 insertion(+), 2 deletions(-)
-
-diff --git a/gdb/nat/linux-ptrace.c b/gdb/nat/linux-ptrace.c
-index 3265b16..559c2de 100644
---- a/gdb/nat/linux-ptrace.c
-+++ b/gdb/nat/linux-ptrace.c
-@@ -21,8 +21,6 @@
- #include "linux-procfs.h"
- #include "linux-waitpid.h"
- #include "buffer.h"
--#include "gdb_wait.h"
--#include "gdb_ptrace.h"
- #ifdef HAVE_SYS_PROCFS_H
- #include <sys/procfs.h>
- #endif
-diff --git a/gdb/nat/linux-ptrace.h b/gdb/nat/linux-ptrace.h
-index 5954945..6faa89b 100644
---- a/gdb/nat/linux-ptrace.h
-+++ b/gdb/nat/linux-ptrace.h
-@@ -21,6 +21,7 @@
- struct buffer;
- 
- #include "nat/gdb_ptrace.h"
-+#include "gdb_wait.h"
- 
- #ifdef __UCLIBC__
- #if !(defined(__UCLIBC_HAS_MMU__) || defined(__ARCH_HAS_MMU__))
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-devtools/gdb/gdb/gdbserver-ctrl-c-handling.patch b/poky/meta/recipes-devtools/gdb/gdb/gdbserver-ctrl-c-handling.patch
new file mode 100644
index 0000000..71fe7f8
--- /dev/null
+++ b/poky/meta/recipes-devtools/gdb/gdb/gdbserver-ctrl-c-handling.patch
@@ -0,0 +1,26 @@
+This problem was created by the upstream commit 78708b7c8c
+After applying the commit, it will send SIGINT to the process group(-signal_pid).
+But if we use gdbserver send SIGINT, and the attached process is not a process
+group leader, then the "kill (-signal_pid, SIGINT)" returns error and fails  to
+interrupt the attached process.
+
+Upstream-Status: Submitted [https://sourceware.org/bugzilla/show_bug.cgi?id=18945]
+
+Author: Josh Gao
+Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
+
+Index: gdb-8.2/gdb/gdbserver/linux-low.c
+===================================================================
+--- gdb-8.2.orig/gdb/gdbserver/linux-low.c
++++ gdb-8.2/gdb/gdbserver/linux-low.c
+@@ -5940,9 +5940,7 @@ linux_look_up_symbols (void)
+ static void
+ linux_request_interrupt (void)
+ {
+-  /* Send a SIGINT to the process group.  This acts just like the user
+-     typed a ^C on the controlling terminal.  */
+-  kill (-signal_pid, SIGINT);
++  kill (signal_pid, SIGINT);
+ }
+ 
+ /* Copy LEN bytes from inferior's auxiliary vector starting at OFFSET
diff --git a/poky/meta/recipes-devtools/gdb/gdb/package_devel_gdb_patches_120-sigprocmask-invalid-call.patch b/poky/meta/recipes-devtools/gdb/gdb/package_devel_gdb_patches_120-sigprocmask-invalid-call.patch
deleted file mode 100644
index c5484f7..0000000
--- a/poky/meta/recipes-devtools/gdb/gdb/package_devel_gdb_patches_120-sigprocmask-invalid-call.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-From 56893a61aa4f0270fa8d1197b9848247f90fce0d Mon Sep 17 00:00:00 2001
-From: Yousong Zhou <yszhou4tech@gmail.com>
-Date: Fri, 24 Mar 2017 10:36:03 +0800
-Subject: [PATCH] Fix invalid sigprocmask call
-
-The POSIX document says
-
-    The pthread_sigmask() and sigprocmask() functions shall fail if:
-
-    [EINVAL]
-    The value of the how argument is not equal to one of the defined values.
-
-and this is how musl-libc is currently doing.  Fix the call to be safe
-and correct
-
- [1] http://pubs.opengroup.org/onlinepubs/9699919799/functions/pthread_sigmask.html
-
-gdb/ChangeLog:
-2017-03-24  Yousong Zhou  <yszhou4tech@gmail.com>
-
-    * common/signals-state-save-restore.c (save_original_signals_state):
-    Fix invalid sigprocmask call.
----
-Upstream-Status: Pending [not author, cherry-picked from LEDE https://bugs.lede-project.org/index.php?do=details&task_id=637&openedfrom=-1%2Bweek]
-Signed-off-by: André Draszik <adraszik@tycoint.com>
- gdb/ChangeLog                           | 5 +++++
- gdb/common/signals-state-save-restore.c | 2 +-
- 2 files changed, 6 insertions(+), 1 deletion(-)
-
-diff --git a/gdb/common/signals-state-save-restore.c b/gdb/common/signals-state-save-restore.c
-index d11a9ae..734335c 100644
---- a/gdb/common/signals-state-save-restore.c
-+++ b/gdb/common/signals-state-save-restore.c
-@@ -41,7 +41,7 @@ save_original_signals_state (void)
-   int i;
-   int res;
- 
--  res = sigprocmask (0,  NULL, &original_signal_mask);
-+  res = sigprocmask (SIG_BLOCK,  NULL, &original_signal_mask);
-   if (res == -1)
-     perror_with_name (("sigprocmask"));
- 
--- 
-2.6.4
-
diff --git a/poky/meta/recipes-devtools/gdb/gdb_8.0.1.bb b/poky/meta/recipes-devtools/gdb/gdb_8.0.1.bb
deleted file mode 100644
index ea8fef1..0000000
--- a/poky/meta/recipes-devtools/gdb/gdb_8.0.1.bb
+++ /dev/null
@@ -1,27 +0,0 @@
-require gdb.inc
-require gdb-${PV}.inc
-
-inherit python3-dir
-
-EXTRA_OEMAKE_append_libc-musl = "\
-                                 gt_cv_func_gnugettext1_libc=yes \
-                                 gt_cv_func_gnugettext2_libc=yes \
-                                 gl_cv_func_gettimeofday_clobber=no \
-                                "
-
-do_configure_prepend() {
-	if [ "${@bb.utils.filter('PACKAGECONFIG', 'python', d)}" ]; then
-		cat > ${WORKDIR}/python << EOF
-#!/bin/sh
-case "\$2" in
-	--includes) echo "-I${STAGING_INCDIR}/${PYTHON_DIR}${PYTHON_ABI}/" ;;
-	--ldflags) echo "-Wl,-rpath-link,${STAGING_LIBDIR}/.. -Wl,-rpath,${libdir}/.. -lpthread -ldl -lutil -lm -lpython${PYTHON_BASEVERSION}${PYTHON_ABI}" ;;
-	--exec-prefix) echo "${exec_prefix}" ;;
-	*) exit 1 ;;
-esac
-exit 0
-EOF
-		chmod +x ${WORKDIR}/python
-	fi
-}
-CFLAGS_append_libc-musl = " -Drpl_gettimeofday=gettimeofday"
diff --git a/poky/meta/recipes-devtools/gdb/gdb_8.2.bb b/poky/meta/recipes-devtools/gdb/gdb_8.2.bb
new file mode 100644
index 0000000..c6eac84
--- /dev/null
+++ b/poky/meta/recipes-devtools/gdb/gdb_8.2.bb
@@ -0,0 +1,29 @@
+require gdb.inc
+require gdb-${PV}.inc
+
+inherit python3-dir
+
+EXTRA_OEMAKE_append_libc-musl = "\
+                                 gt_cv_func_gnugettext1_libc=yes \
+                                 gt_cv_func_gnugettext2_libc=yes \
+                                 gl_cv_func_working_strerror=yes \
+                                 gl_cv_func_strerror_0_works=yes \
+                                 gl_cv_func_gettimeofday_clobber=no \
+                                "
+
+do_configure_prepend() {
+	if [ "${@bb.utils.filter('PACKAGECONFIG', 'python', d)}" ]; then
+		cat > ${WORKDIR}/python << EOF
+#!/bin/sh
+case "\$2" in
+	--includes) echo "-I${STAGING_INCDIR}/${PYTHON_DIR}${PYTHON_ABI}/" ;;
+	--ldflags) echo "-Wl,-rpath-link,${STAGING_LIBDIR}/.. -Wl,-rpath,${libdir}/.. -lpthread -ldl -lutil -lm -lpython${PYTHON_BASEVERSION}${PYTHON_ABI}" ;;
+	--exec-prefix) echo "${exec_prefix}" ;;
+	*) exit 1 ;;
+esac
+exit 0
+EOF
+		chmod +x ${WORKDIR}/python
+	fi
+}
+CPPFLAGS_append_libc-musl = " -Drpl_gettimeofday=gettimeofday -Drpl_stat=stat"
diff --git a/poky/meta/recipes-devtools/git/files/CVE-2018-11233.patch b/poky/meta/recipes-devtools/git/files/CVE-2018-11233.patch
deleted file mode 100644
index f4468cf..0000000
--- a/poky/meta/recipes-devtools/git/files/CVE-2018-11233.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From 014281e62b7920a6d710a85089e00ca012b0744c Mon Sep 17 00:00:00 2001
-From: Jeff King <peff@peff.net>
-Date: Sun, 13 May 2018 12:09:42 -0400
-Subject: [PATCH] is_ntfs_dotgit: use a size_t for traversing string
-
-We walk through the "name" string using an int, which can
-wrap to a negative value and cause us to read random memory
-before our array (e.g., by creating a tree with a name >2GB,
-since "int" is still 32 bits even on most 64-bit platforms).
-Worse, this is easy to trigger during the fsck_tree() check,
-which is supposed to be protecting us from malicious
-garbage.
-
-Note one bit of trickiness in the existing code: we
-sometimes assign -1 to "len" at the end of the loop, and
-then rely on the "len++" in the for-loop's increment to take
-it back to 0. This is still legal with a size_t, since
-assigning -1 will turn into SIZE_MAX, which then wraps
-around to 0 on increment.
-
-Signed-off-by: Jeff King <peff@peff.net>
-CVE: CVE-2018-11233
-Upstream-Status: Backport[https://github.com/git/git/commit/11a9f4d807a0d71dc6eff51bb87baf4ca2cccf1d]
-Signed-off-by: Sinan Kaya <okaya@kernel.org>
----
- path.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/path.c b/path.c
-index da8b65573..d31c795ff 100644
---- a/path.c
-+++ b/path.c
-@@ -1305,7 +1305,7 @@ static int only_spaces_and_periods(const char *path, size_t len, size_t skip)
- 
- int is_ntfs_dotgit(const char *name)
- {
--	int len;
-+	size_t len;
- 
- 	for (len = 0; ; len++)
- 		if (!name[len] || name[len] == '\\' || is_dir_sep(name[len])) {
--- 
-2.19.0
-
diff --git a/poky/meta/recipes-devtools/git/files/CVE-2018-11235.patch b/poky/meta/recipes-devtools/git/files/CVE-2018-11235.patch
deleted file mode 100644
index c272eac..0000000
--- a/poky/meta/recipes-devtools/git/files/CVE-2018-11235.patch
+++ /dev/null
@@ -1,288 +0,0 @@
-From 0383bbb9015898cbc79abd7b64316484d7713b44 Mon Sep 17 00:00:00 2001
-From: Jeff King <peff@peff.net>
-Date: Mon, 30 Apr 2018 03:25:25 -0400
-Subject: [PATCH] submodule-config: verify submodule names as paths
-
-Submodule "names" come from the untrusted .gitmodules file,
-but we blindly append them to $GIT_DIR/modules to create our
-on-disk repo paths. This means you can do bad things by
-putting "../" into the name (among other things).
-
-Let's sanity-check these names to avoid building a path that
-can be exploited. There are two main decisions:
-
-  1. What should the allowed syntax be?
-
-     It's tempting to reuse verify_path(), since submodule
-     names typically come from in-repo paths. But there are
-     two reasons not to:
-
-       a. It's technically more strict than what we need, as
-          we really care only about breaking out of the
-          $GIT_DIR/modules/ hierarchy.  E.g., having a
-          submodule named "foo/.git" isn't actually
-          dangerous, and it's possible that somebody has
-          manually given such a funny name.
-
-       b. Since we'll eventually use this checking logic in
-          fsck to prevent downstream repositories, it should
-          be consistent across platforms. Because
-          verify_path() relies on is_dir_sep(), it wouldn't
-          block "foo\..\bar" on a non-Windows machine.
-
-  2. Where should we enforce it? These days most of the
-     .gitmodules reads go through submodule-config.c, so
-     I've put it there in the reading step. That should
-     cover all of the C code.
-
-     We also construct the name for "git submodule add"
-     inside the git-submodule.sh script. This is probably
-     not a big deal for security since the name is coming
-     from the user anyway, but it would be polite to remind
-     them if the name they pick is invalid (and we need to
-     expose the name-checker to the shell anyway for our
-     test scripts).
-
-     This patch issues a warning when reading .gitmodules
-     and just ignores the related config entry completely.
-     This will generally end up producing a sensible error,
-     as it works the same as a .gitmodules file which is
-     missing a submodule entry (so "submodule update" will
-     barf, but "git clone --recurse-submodules" will print
-     an error but not abort the clone.
-
-     There is one minor oddity, which is that we print the
-     warning once per malformed config key (since that's how
-     the config subsystem gives us the entries). So in the
-     new test, for example, the user would see three
-     warnings. That's OK, since the intent is that this case
-     should never come up outside of malicious repositories
-     (and then it might even benefit the user to see the
-     message multiple times).
-
-Credit for finding this vulnerability and the proof of
-concept from which the test script was adapted goes to
-Etienne Stalmans.
-
-CVE: CVE-2018-11235
-Upstream-Status: Backport [https://github.com/gitster/git/commit/0383bbb9015898cbc79abd7b64316484d7713b44#diff-1772b951776d1647ca31a2256f7fe88f]
-
-Signed-off-by: Jeff King <peff@peff.net>
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- builtin/submodule--helper.c | 24 ++++++++++++++
- git-submodule.sh            |  5 +++
- submodule-config.c          | 31 ++++++++++++++++++
- submodule-config.h          |  7 +++++
- t/t7415-submodule-names.sh  | 76 +++++++++++++++++++++++++++++++++++++++++++++
- 5 files changed, 143 insertions(+)
- create mode 100755 t/t7415-submodule-names.sh
-
-diff --git a/builtin/submodule--helper.c b/builtin/submodule--helper.c
-index cbb17a902..b4b4d29d8 100644
---- a/builtin/submodule--helper.c
-+++ b/builtin/submodule--helper.c
-@@ -1480,6 +1480,29 @@ static int is_active(int argc, const cha
- 	return !is_submodule_active(the_repository, argv[1]);
- }
- 
-+/*
-+ * Exit non-zero if any of the submodule names given on the command line is
-+ * invalid. If no names are given, filter stdin to print only valid names
-+ * (which is primarily intended for testing).
-+ */
-+static int check_name(int argc, const char **argv, const char *prefix)
-+{
-+	if (argc > 1) {
-+		while (*++argv) {
-+			if (check_submodule_name(*argv) < 0)
-+				return 1;
-+		}
-+	} else {
-+		struct strbuf buf = STRBUF_INIT;
-+		while (strbuf_getline(&buf, stdin) != EOF) {
-+			if (!check_submodule_name(buf.buf))
-+				printf("%s\n", buf.buf);
-+		}
-+		strbuf_release(&buf);
-+	}
-+	return 0;
-+}
-+
- #define SUPPORT_SUPER_PREFIX (1<<0)
- 
- struct cmd_struct {
-@@ -1502,6 +1525,7 @@ static struct cmd_struct commands[] = {
- 	{"push-check", push_check, 0},
- 	{"absorb-git-dirs", absorb_git_dirs, SUPPORT_SUPER_PREFIX},
- 	{"is-active", is_active, 0},
-+	{"check-name", check_name, 0},
- };
- 
- int cmd_submodule__helper(int argc, const char **argv, const char *prefix)
-diff --git a/git-submodule.sh b/git-submodule.sh
-index c0d0e9a4c..92750b9e2 100755
---- a/git-submodule.sh
-+++ b/git-submodule.sh
-@@ -229,6 +229,11 @@ Use -f if you really want to add it." >&
- 		sm_name="$sm_path"
- 	fi
- 
-+	if ! git submodule--helper check-name "$sm_name"
-+	then
-+		die "$(eval_gettext "'$sm_name' is not a valid submodule name")"
-+	fi
-+
- 	# perhaps the path exists and is already a git repo, else clone it
- 	if test -e "$sm_path"
- 	then
-diff --git a/submodule-config.c b/submodule-config.c
-index 4f58491dd..de54351c6 100644
---- a/submodule-config.c
-+++ b/submodule-config.c
-@@ -190,6 +190,31 @@ static struct submodule *cache_lookup_na
- 	return NULL;
- }
- 
-+int check_submodule_name(const char *name)
-+{
-+	/* Disallow empty names */
-+	if (!*name)
-+		return -1;
-+
-+	/*
-+	 * Look for '..' as a path component. Check both '/' and '\\' as
-+	 * separators rather than is_dir_sep(), because we want the name rules
-+	 * to be consistent across platforms.
-+	 */
-+	goto in_component; /* always start inside component */
-+	while (*name) {
-+		char c = *name++;
-+		if (c == '/' || c == '\\') {
-+in_component:
-+			if (name[0] == '.' && name[1] == '.' &&
-+			    (!name[2] || name[2] == '/' || name[2] == '\\'))
-+				return -1;
-+		}
-+	}
-+
-+	return 0;
-+}
-+
- static int name_and_item_from_var(const char *var, struct strbuf *name,
- 				  struct strbuf *item)
- {
-@@ -201,6 +226,12 @@ static int name_and_item_from_var(const
- 		return 0;
- 
- 	strbuf_add(name, subsection, subsection_len);
-+	if (check_submodule_name(name->buf) < 0) {
-+		warning(_("ignoring suspicious submodule name: %s"), name->buf);
-+		strbuf_release(name);
-+		return 0;
-+	}
-+
- 	strbuf_addstr(item, key);
- 
- 	return 1;
-diff --git a/submodule-config.h b/submodule-config.h
-index d434ecdb4..103cc79dd 100644
---- a/submodule-config.h
-+++ b/submodule-config.h
-@@ -48,4 +48,11 @@ extern const struct submodule *submodule
- 						    const char *key);
- extern void submodule_free(void);
- 
-+/*
-+ * Returns 0 if the name is syntactically acceptable as a submodule "name"
-+ * (e.g., that may be found in the subsection of a .gitmodules file) and -1
-+ * otherwise.
-+ */
-+int check_submodule_name(const char *name);
-+
- #endif /* SUBMODULE_CONFIG_H */
-diff --git a/t/t7415-submodule-names.sh b/t/t7415-submodule-names.sh
-new file mode 100755
-index 000000000..75fa071c6
---- /dev/null
-+++ b/t/t7415-submodule-names.sh
-@@ -0,0 +1,76 @@
-+#!/bin/sh
-+
-+test_description='check handling of .. in submodule names
-+
-+Exercise the name-checking function on a variety of names, and then give a
-+real-world setup that confirms we catch this in practice.
-+'
-+. ./test-lib.sh
-+
-+test_expect_success 'check names' '
-+	cat >expect <<-\EOF &&
-+	valid
-+	valid/with/paths
-+	EOF
-+
-+	git submodule--helper check-name >actual <<-\EOF &&
-+	valid
-+	valid/with/paths
-+
-+	../foo
-+	/../foo
-+	..\foo
-+	\..\foo
-+	foo/..
-+	foo/../
-+	foo\..
-+	foo\..\
-+	foo/../bar
-+	EOF
-+
-+	test_cmp expect actual
-+'
-+
-+test_expect_success 'create innocent subrepo' '
-+	git init innocent &&
-+	git -C innocent commit --allow-empty -m foo
-+'
-+
-+test_expect_success 'submodule add refuses invalid names' '
-+	test_must_fail \
-+		git submodule add --name ../../modules/evil "$PWD/innocent" evil
-+'
-+
-+test_expect_success 'add evil submodule' '
-+	git submodule add "$PWD/innocent" evil &&
-+
-+	mkdir modules &&
-+	cp -r .git/modules/evil modules &&
-+	write_script modules/evil/hooks/post-checkout <<-\EOF &&
-+	echo >&2 "RUNNING POST CHECKOUT"
-+	EOF
-+
-+	git config -f .gitmodules submodule.evil.update checkout &&
-+	git config -f .gitmodules --rename-section \
-+		submodule.evil submodule.../../modules/evil &&
-+	git add modules &&
-+	git commit -am evil
-+'
-+
-+# This step seems like it shouldn't be necessary, since the payload is
-+# contained entirely in the evil submodule. But due to the vagaries of the
-+# submodule code, checking out the evil module will fail unless ".git/modules"
-+# exists. Adding another submodule (with a name that sorts before "evil") is an
-+# easy way to make sure this is the case in the victim clone.
-+test_expect_success 'add other submodule' '
-+	git submodule add "$PWD/innocent" another-module &&
-+	git add another-module &&
-+	git commit -am another
-+'
-+
-+test_expect_success 'clone evil superproject' '
-+	git clone --recurse-submodules . victim >output 2>&1 &&
-+	! grep "RUNNING POST CHECKOUT" output
-+'
-+
-+test_done
--- 
-2.13.3
-
diff --git a/poky/meta/recipes-devtools/git/git.inc b/poky/meta/recipes-devtools/git/git.inc
index 8603c04..26a22ac 100644
--- a/poky/meta/recipes-devtools/git/git.inc
+++ b/poky/meta/recipes-devtools/git/git.inc
@@ -7,9 +7,7 @@
 PROVIDES_append_class-native = " git-replacement-native"
 
 SRC_URI = "${KERNELORG_MIRROR}/software/scm/git/git-${PV}.tar.gz;name=tarball \
-           ${KERNELORG_MIRROR}/software/scm/git/git-manpages-${PV}.tar.gz;name=manpages \
-           file://CVE-2018-11235.patch \
-           file://CVE-2018-11233.patch"
+           ${KERNELORG_MIRROR}/software/scm/git/git-manpages-${PV}.tar.gz;name=manpages"
 
 S = "${WORKDIR}/git-${PV}"
 
@@ -54,13 +52,6 @@
 	       -e 's#${libdir}/perl-native/#${libdir}/#' \
 	    ${@d.getVar("PERLTOOLS").replace(' /',d.getVar('D') + '/')}
 
-	# ${libdir} is not applicable here, perl-native files are always
-	# installed to /usr/lib on both 32/64 bits targets.
-
-	mkdir -p ${D}${libdir}
-	mv ${D}${exec_prefix}/lib/perl-native/perl ${D}${libdir}
-	rmdir -p ${D}${exec_prefix}/lib/perl-native || true
-
 	if [ ! "${@bb.utils.filter('PACKAGECONFIG', 'cvsserver', d)}" ]; then
 		# Only install the git cvsserver command if explicitly requested
 		# as it requires the DBI Perl module, which does not exist in
@@ -74,8 +65,7 @@
 		# if explicitly requested as they require the SVN::Core Perl
 		# module, which does not exist in OE-Core.
 		rm -r ${D}${libexecdir}/git-core/git-svn \
-		      ${D}${libdir}/perl/site_perl/*/Git/SVN*
-		sed -i -e '/SVN/d' ${D}${libdir}/perl/site_perl/*/auto/Git/.packlist
+		      ${D}${datadir}/perl5/Git/SVN*
 	fi
 }
 
@@ -126,7 +116,7 @@
 FILES_${PN}-perltools += " \
     ${PERLTOOLS} \
     ${libdir}/perl \
-    ${datadir}/perl \
+    ${datadir}/perl5 \
 "
 
 RDEPENDS_${PN}-perltools = "${PN} perl perl-module-file-path findutils"
diff --git a/poky/meta/recipes-devtools/git/git_2.16.1.bb b/poky/meta/recipes-devtools/git/git_2.16.1.bb
deleted file mode 100644
index 9dc4eba..0000000
--- a/poky/meta/recipes-devtools/git/git_2.16.1.bb
+++ /dev/null
@@ -1,11 +0,0 @@
-require git.inc
-
-EXTRA_OECONF += "ac_cv_snprintf_returns_bogus=no \
-                 ac_cv_fread_reads_directories=${ac_cv_fread_reads_directories=yes} \
-                 "
-EXTRA_OEMAKE += "NO_GETTEXT=1"
-
-SRC_URI[tarball.md5sum] = "37467da8e79e72f28598d667f219f75e"
-SRC_URI[tarball.sha256sum] = "56cfa48af2b289bba172ca0a47c29f0083f5846cf4759978b70988e4f07fc9fd"
-SRC_URI[manpages.md5sum] = "5587407f3c28446af12fde3f3131ba34"
-SRC_URI[manpages.sha256sum] = "d499e825f429d76862be415f579c20cc26b046573a3a39237acaf9682cb71be7"
diff --git a/poky/meta/recipes-devtools/git/git_2.18.1.bb b/poky/meta/recipes-devtools/git/git_2.18.1.bb
new file mode 100644
index 0000000..b2960c0
--- /dev/null
+++ b/poky/meta/recipes-devtools/git/git_2.18.1.bb
@@ -0,0 +1,11 @@
+require git.inc
+
+EXTRA_OECONF += "ac_cv_snprintf_returns_bogus=no \
+                 ac_cv_fread_reads_directories=${ac_cv_fread_reads_directories=yes} \
+                 "
+EXTRA_OEMAKE += "NO_GETTEXT=1"
+
+SRC_URI[tarball.md5sum] = "9b62c267d878f6cb02f8abc59a99525d"
+SRC_URI[tarball.sha256sum] = "5c710c866d8c9ba3b3e062755e0e9d0ef4f665752bd64810e3eb9f1b0f0eb076"
+SRC_URI[manpages.md5sum] = "ef32a459a4a08a3b8e837a31c925c848"
+SRC_URI[manpages.sha256sum] = "d05bfab2dc45de4f6e7d61ca173071d6902905a4963f7ac3cbca608c0d4592c9"
diff --git a/poky/meta/recipes-devtools/glide/glide_0.13.1.bb b/poky/meta/recipes-devtools/glide/glide_0.13.1.bb
deleted file mode 100644
index 1a5b145..0000000
--- a/poky/meta/recipes-devtools/glide/glide_0.13.1.bb
+++ /dev/null
@@ -1,15 +0,0 @@
-SUMMARY = "Vendor Package Management for Golang"
-HOMEPAGE = "https://glide.sh"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://src/${GO_IMPORT}/LICENSE;md5=54905cf894f8cc416a92f4fc350c35b2"
-
-GO_IMPORT = "github.com/Masterminds/glide"
-SRC_URI = "git://${GO_IMPORT}"
-SRCREV = "67790b3dbede72cfdc54aa53be4706322c9499e0"
-
-inherit go
-
-RDEPENDS_${PN}-dev += "bash"
-RDEPENDS_${PN}-ptest += "bash"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-devtools/glide/glide_0.13.2.bb b/poky/meta/recipes-devtools/glide/glide_0.13.2.bb
new file mode 100644
index 0000000..3a32fa1
--- /dev/null
+++ b/poky/meta/recipes-devtools/glide/glide_0.13.2.bb
@@ -0,0 +1,35 @@
+SUMMARY = "Vendor Package Management for Golang"
+HOMEPAGE = "https://glide.sh"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://src/${GO_IMPORT}/LICENSE;md5=54905cf894f8cc416a92f4fc350c35b2"
+
+GO_IMPORT = "github.com/Masterminds/glide"
+SRC_URI = "git://${GO_IMPORT}"
+SRCREV = "9ef6ca313b3200079861f2de4e567b1d22081d19"
+
+inherit go
+
+RDEPENDS_${PN}-dev += "bash"
+RDEPENDS_${PN}-ptest += "bash"
+
+BBCLASSEXTEND = "native nativesdk"
+
+# for x86 ends with textrel in ${PN}
+# http://errors.yoctoproject.org/Errors/Details/185631/
+# ERROR: QA Issue: ELF binary '/work/i586-oe-linux/glide/0.13.1-r0/packages-split/glide/usr/bin/glide' has relocations in .text [textrel]
+INSANE_SKIP_${PN} += "textrel"
+
+# for aarch64 ends with textrel in ${PN}-ptest
+# http://errors.yoctoproject.org/Errors/Details/185633/
+# ERROR: QA Issue: ELF binary '/work/aarch64-oe-linux/glide/0.13.1-r0/packages-split/glide-ptest/usr/lib/glide/ptest/github.com/Masterminds/glide/glide.test' has relocations in .text
+# ELF binary '/work/aarch64-oe-linux/glide/0.13.1-r0/packages-split/glide-ptest/usr/lib/glide/ptest/github.com/Masterminds/glide/dependency/dependency.test' has relocations in .text
+# ELF binary '/work/aarch64-oe-linux/glide/0.13.1-r0/packages-split/glide-ptest/usr/lib/glide/ptest/github.com/Masterminds/glide/repo/repo.test' has relocations in .text
+# ELF binary '/work/aarch64-oe-linux/glide/0.13.1-r0/packages-split/glide-ptest/usr/lib/glide/ptest/github.com/Masterminds/glide/mirrors/mirrors.test' has relocations in .text
+# ELF binary '/work/aarch64-oe-linux/glide/0.13.1-r0/packages-split/glide-ptest/usr/lib/glide/ptest/github.com/Masterminds/glide/cfg/cfg.test' has relocations in .text
+# ELF binary '/work/aarch64-oe-linux/glide/0.13.1-r0/packages-split/glide-ptest/usr/lib/glide/ptest/github.com/Masterminds/glide/godep/strip/strip.test' has relocations in .text
+# ELF binary '/work/aarch64-oe-linux/glide/0.13.1-r0/packages-split/glide-ptest/usr/lib/glide/ptest/github.com/Masterminds/glide/path/path.test' has relocations in .text
+# ELF binary '/work/aarch64-oe-linux/glide/0.13.1-r0/packages-split/glide-ptest/usr/lib/glide/ptest/github.com/Masterminds/glide/tree/tree.test' has relocations in .text
+# ELF binary '/work/aarch64-oe-linux/glide/0.13.1-r0/packages-split/glide-ptest/usr/lib/glide/ptest/github.com/Masterminds/glide/util/util.test' has relocations in .text
+# ELF binary '/work/aarch64-oe-linux/glide/0.13.1-r0/packages-split/glide-ptest/usr/lib/glide/ptest/github.com/Masterminds/glide/action/action.test' has relocations in .text
+# ELF binary '/work/aarch64-oe-linux/glide/0.13.1-r0/packages-split/glide-ptest/usr/lib/glide/ptest/github.com/Masterminds/glide/cache/cache.test' has relocations in .text [textrel]
+INSANE_SKIP_${PN}-ptest += "textrel"
diff --git a/poky/meta/recipes-devtools/gnu-config/gnu-config/musl-support.patch b/poky/meta/recipes-devtools/gnu-config/gnu-config/musl-support.patch
deleted file mode 100644
index 3147435..0000000
--- a/poky/meta/recipes-devtools/gnu-config/gnu-config/musl-support.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-support musl
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Index: gnu-config-20120814/config.sub
-===================================================================
---- gnu-config-20120814.orig/config.sub	2012-09-18 02:27:45.000000000 -0700
-+++ gnu-config-20120814/config.sub	2014-03-26 00:34:19.955996709 -0700
-@@ -123,6 +123,7 @@
- maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
- case $maybe_os in
-   nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \
-+  linux-musl* | \
-   linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \
-   knetbsd*-gnu* | netbsd*-gnu* | \
-   kopensolaris*-gnu* | \
-@@ -1365,6 +1366,7 @@
- 	      | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
- 	      | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \
- 	      | -linux-newlib* | -linux-uclibc* \
-+	      | -linux-musl* \
- 	      | -uxpv* | -beos* | -mpeix* | -udk* \
- 	      | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
- 	      | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
diff --git a/poky/meta/recipes-devtools/gnu-config/gnu-config_20120814.bb b/poky/meta/recipes-devtools/gnu-config/gnu-config_20120814.bb
deleted file mode 100644
index 3d428b9..0000000
--- a/poky/meta/recipes-devtools/gnu-config/gnu-config_20120814.bb
+++ /dev/null
@@ -1,40 +0,0 @@
-SUMMARY = "gnu-configize"
-DESCRIPTION = "Tool that installs the GNU config.guess / config.sub into a directory tree"
-SECTION = "devel"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://config.guess;endline=39;md5=b79a4663475f4d724846463277817e0d"
-
-DEPENDS_class-native = "hostperl-runtime-native"
-
-INHIBIT_DEFAULT_DEPS = "1"
-
-
-SRC_URI = "http://downloads.yoctoproject.org/releases/gnu-config/gnu-config-${PV}.tar.bz2 \
-	   file://musl-support.patch \
-           file://gnu-configize.in"
-
-SRC_URI[md5sum] = "bcfca5a2bb39edad4aae5a65efc84094"
-SRC_URI[sha256sum] = "44f99a8e76f3e8e4fec0bb5ad4762f8e44366168554ce66cb85afbe2ed3efd8b"
-
-CLEANBROKEN = "1"
-
-do_compile[noexec] = "1"
-
-do_install () {
-	install -d ${D}${datadir}/gnu-config \
-		   ${D}${bindir}
-	cat ${WORKDIR}/gnu-configize.in | \
-		sed -e 's,@gnu-configdir@,${datadir}/gnu-config,g' \
-		    -e 's,@autom4te_perllibdir@,${datadir}/autoconf,g' > ${D}${bindir}/gnu-configize
-	# In the native case we want the system perl as perl-native can't have built yet
-	if [ "${PN}" != "gnu-config-native" -a "${PN}" != "nativesdk-gnu-config" ]; then
-		sed -i -e 's,/usr/bin/env,${bindir}/env,g' ${D}${bindir}/gnu-configize
-	fi
-	chmod 755 ${D}${bindir}/gnu-configize
-	install -m 0644 config.guess config.sub ${D}${datadir}/gnu-config/
-}
-
-PACKAGES = "${PN}"
-FILES_${PN} = "${bindir} ${datadir}/gnu-config"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-devtools/gnu-config/gnu-config_git.bb b/poky/meta/recipes-devtools/gnu-config/gnu-config_git.bb
index 8de8138..4745f19 100644
--- a/poky/meta/recipes-devtools/gnu-config/gnu-config_git.bb
+++ b/poky/meta/recipes-devtools/gnu-config/gnu-config_git.bb
@@ -2,14 +2,14 @@
 DESCRIPTION = "Tool that installs the GNU config.guess / config.sub into a directory tree"
 SECTION = "devel"
 LICENSE = "GPL-3.0-with-autoconf-exception"
-LIC_FILES_CHKSUM = "file://config.guess;beginline=7;endline=27;md5=9bac8b1743c2240ae07cce6e546ac2f2"
+LIC_FILES_CHKSUM = "file://config.guess;beginline=7;endline=27;md5=b75d42f59f706ea56d6a8e00216fca6a"
 
 DEPENDS_class-native = "hostperl-runtime-native"
 
 INHIBIT_DEFAULT_DEPS = "1"
 
-SRCREV = "b576fa87c140b824466ef1638e945e87dc5c0343"
-PV = "20150728+git${SRCPV}"
+SRCREV = "30d53fc428ea42af9d6f4d355db0022e3918a824"
+PV = "20180713+git${SRCPV}"
 
 SRC_URI = "git://git.savannah.gnu.org/config.git \
            file://gnu-configize.in"
diff --git a/poky/meta/recipes-devtools/go/go-1.10.inc b/poky/meta/recipes-devtools/go/go-1.10.inc
deleted file mode 100644
index 1df0fc5..0000000
--- a/poky/meta/recipes-devtools/go/go-1.10.inc
+++ /dev/null
@@ -1,24 +0,0 @@
-require go-common.inc
-
-GO_BASEVERSION = "1.10"
-GO_MINOR = ".3"
-PV .= "${GO_MINOR}"
-FILESEXTRAPATHS_prepend := "${FILE_DIRNAME}/go-${GO_BASEVERSION}:"
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=5d4950ecb7b26d2c5e4e7b4e0dd74707"
-
-SRC_URI += "\
-    file://0001-allow-CC-and-CXX-to-have-multiple-words.patch \
-    file://0002-cmd-go-make-content-based-hash-generation-less-pedan.patch \
-    file://0003-allow-GOTOOLDIR-to-be-overridden-in-the-environment.patch \
-    file://0004-ld-add-soname-to-shareable-objects.patch \
-    file://0005-make.bash-override-CC-when-building-dist-and-go_boot.patch \
-    file://0006-cmd-dist-separate-host-and-target-builds.patch \
-    file://0007-cmd-go-make-GOROOT-precious-by-default.patch \
-    file://0008-cmd-internal-obj-arm64-fix-branch-too-far-with-TBZ-l.patch \
-"
-
-SRC_URI_append_libc-musl = " file://0009-ld-replace-glibc-dynamic-linker-with-musl.patch"
-
-SRC_URI[main.md5sum] = "d15dfb264105c5e84fbe33f4a4aa5021"
-SRC_URI[main.sha256sum] = "567b1cc66c9704d1c019c50bef946272e911ec6baf244310f87f4e678be155f2"
diff --git a/poky/meta/recipes-devtools/go/go-1.10/0001-allow-CC-and-CXX-to-have-multiple-words.patch b/poky/meta/recipes-devtools/go/go-1.10/0001-allow-CC-and-CXX-to-have-multiple-words.patch
deleted file mode 100644
index 3bb33b0..0000000
--- a/poky/meta/recipes-devtools/go/go-1.10/0001-allow-CC-and-CXX-to-have-multiple-words.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 7a7de46129fa6859fb6311096eb9f54c53c7fe2f Mon Sep 17 00:00:00 2001
-From: Matt Madison <matt@madison.systems>
-Date: Mon, 19 Feb 2018 08:49:33 -0800
-Subject: [PATCH 1/9] allow CC and CXX to have multiple words
-
-Upstream-Status: Inappropriate [OE specific]
-
-Signed-off-by: Matt Madison <matt@madison.systems>
----
- src/cmd/go/internal/envcmd/env.go | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/cmd/go/internal/envcmd/env.go b/src/cmd/go/internal/envcmd/env.go
-index 603f7b5060..f891123f9c 100644
---- a/src/cmd/go/internal/envcmd/env.go
-+++ b/src/cmd/go/internal/envcmd/env.go
-@@ -82,11 +82,11 @@ func MkEnv() []cfg.EnvVar {
- 
- 	cc := cfg.DefaultCC(cfg.Goos, cfg.Goarch)
- 	if env := strings.Fields(os.Getenv("CC")); len(env) > 0 {
--		cc = env[0]
-+		cc = strings.Join(env, " ")
- 	}
- 	cxx := cfg.DefaultCXX(cfg.Goos, cfg.Goarch)
- 	if env := strings.Fields(os.Getenv("CXX")); len(env) > 0 {
--		cxx = env[0]
-+		cxx = strings.Join(env, " ")
- 	}
- 	env = append(env, cfg.EnvVar{Name: "CC", Value: cc})
- 	env = append(env, cfg.EnvVar{Name: "CXX", Value: cxx})
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-devtools/go/go-1.10/0002-cmd-go-make-content-based-hash-generation-less-pedan.patch b/poky/meta/recipes-devtools/go/go-1.10/0002-cmd-go-make-content-based-hash-generation-less-pedan.patch
deleted file mode 100644
index 74f37a9..0000000
--- a/poky/meta/recipes-devtools/go/go-1.10/0002-cmd-go-make-content-based-hash-generation-less-pedan.patch
+++ /dev/null
@@ -1,220 +0,0 @@
-From 8b2feaee81d7a16adc59e61d06c1e7314d3a5408 Mon Sep 17 00:00:00 2001
-From: Matt Madison <matt@madison.systems>
-Date: Mon, 19 Feb 2018 08:50:59 -0800
-Subject: [PATCH 2/9] cmd/go: make content-based hash generation less pedantic
-
-Go 1.10's build tool now uses content-based hashes to
-determine when something should be built or re-built.
-This same mechanism is used to maintain a built-artifact
-cache for speeding up builds.
-
-However, the hashes it generates include information that
-doesn't work well with OE, nor with using a shared runtime
-library.
-
-First, it embeds path names to source files, unless
-building within GOROOT.  This prevents the building
-of a package in GOPATH for later staging into GOROOT.
-
-This patch adds support for the environment variable
-GOPATH_OMIT_IN_ACTIONID.  If present, path name
-embedding is disabled.
-
-Second, if cgo is enabled, the build ID for cgo-related
-packages will include the current value of the environment
-variables for invoking the compiler (CC, CXX, FC) and
-any CGO_xxFLAGS variables.  Only if the settings used
-during a compilation exactly match, character for character,
-the values used for compiling runtime/cgo or any other
-cgo-enabled package being imported, will the tool
-decide that the imported package is up-to-date.
-
-This is done to help ensure correctness, but is overly
-simplistic and effectively prevents the reuse of built
-artifacts that use cgo (or shared runtime, which includes
-runtime/cgo).
-
-This patch filters out all compiler flags except those
-beginning with '-m'.  The default behavior can be restored
-by setting the CGO_PEDANTIC environment variable.
-
-Upstream-Status: Inappropriate [OE specific]
-
-Signed-off-by: Matt Madison <matt@madison.systems>
----
- src/cmd/go/internal/envcmd/env.go |  2 +-
- src/cmd/go/internal/work/exec.go  | 63 ++++++++++++++++++++++++++++-----------
- 2 files changed, 46 insertions(+), 19 deletions(-)
-
-diff --git a/src/cmd/go/internal/envcmd/env.go b/src/cmd/go/internal/envcmd/env.go
-index f891123f9c..ebacfbfdbc 100644
---- a/src/cmd/go/internal/envcmd/env.go
-+++ b/src/cmd/go/internal/envcmd/env.go
-@@ -113,7 +113,7 @@ func findEnv(env []cfg.EnvVar, name string) string {
- func ExtraEnvVars() []cfg.EnvVar {
- 	var b work.Builder
- 	b.Init()
--	cppflags, cflags, cxxflags, fflags, ldflags, err := b.CFlags(&load.Package{})
-+	cppflags, cflags, cxxflags, fflags, ldflags, err := b.CFlags(&load.Package{}, false)
- 	if err != nil {
- 		// Should not happen - b.CFlags was given an empty package.
- 		fmt.Fprintf(os.Stderr, "go: invalid cflags: %v\n", err)
-diff --git a/src/cmd/go/internal/work/exec.go b/src/cmd/go/internal/work/exec.go
-index c4c1500eb2..b0f6b45647 100644
---- a/src/cmd/go/internal/work/exec.go
-+++ b/src/cmd/go/internal/work/exec.go
-@@ -173,6 +173,8 @@ func (b *Builder) Do(root *Action) {
- 	wg.Wait()
- }
- 
-+var omitGopath = os.Getenv("GOPATH_OMIT_IN_ACTIONID") != ""
-+
- // buildActionID computes the action ID for a build action.
- func (b *Builder) buildActionID(a *Action) cache.ActionID {
- 	p := a.Package
-@@ -189,7 +191,7 @@ func (b *Builder) buildActionID(a *Action) cache.ActionID {
- 	// but it does not hide the exact value of $GOPATH.
- 	// Include the full dir in that case.
- 	// Assume b.WorkDir is being trimmed properly.
--	if !p.Goroot && !strings.HasPrefix(p.Dir, b.WorkDir) {
-+	if !p.Goroot && !omitGopath && !strings.HasPrefix(p.Dir, b.WorkDir) {
- 		fmt.Fprintf(h, "dir %s\n", p.Dir)
- 	}
- 	fmt.Fprintf(h, "goos %s goarch %s\n", cfg.Goos, cfg.Goarch)
-@@ -197,13 +199,13 @@ func (b *Builder) buildActionID(a *Action) cache.ActionID {
- 	fmt.Fprintf(h, "omitdebug %v standard %v local %v prefix %q\n", p.Internal.OmitDebug, p.Standard, p.Internal.Local, p.Internal.LocalPrefix)
- 	if len(p.CgoFiles)+len(p.SwigFiles) > 0 {
- 		fmt.Fprintf(h, "cgo %q\n", b.toolID("cgo"))
--		cppflags, cflags, cxxflags, fflags, _, _ := b.CFlags(p)
--		fmt.Fprintf(h, "CC=%q %q %q\n", b.ccExe(), cppflags, cflags)
-+		cppflags, cflags, cxxflags, fflags, _, _ := b.CFlags(p, true)
-+		fmt.Fprintf(h, "CC=%q %q %q\n", b.ccExe(true), cppflags, cflags)
- 		if len(p.CXXFiles)+len(p.SwigFiles) > 0 {
--			fmt.Fprintf(h, "CXX=%q %q\n", b.cxxExe(), cxxflags)
-+			fmt.Fprintf(h, "CXX=%q %q\n", b.cxxExe(true), cxxflags)
- 		}
- 		if len(p.FFiles) > 0 {
--			fmt.Fprintf(h, "FC=%q %q\n", b.fcExe(), fflags)
-+			fmt.Fprintf(h, "FC=%q %q\n", b.fcExe(true), fflags)
- 		}
- 		// TODO(rsc): Should we include the SWIG version or Fortran/GCC/G++/Objective-C compiler versions?
- 	}
-@@ -1731,33 +1733,33 @@ var (
- // gccCmd returns a gcc command line prefix
- // defaultCC is defined in zdefaultcc.go, written by cmd/dist.
- func (b *Builder) GccCmd(incdir, workdir string) []string {
--	return b.compilerCmd(b.ccExe(), incdir, workdir)
-+	return b.compilerCmd(b.ccExe(false), incdir, workdir)
- }
- 
- // gxxCmd returns a g++ command line prefix
- // defaultCXX is defined in zdefaultcc.go, written by cmd/dist.
- func (b *Builder) GxxCmd(incdir, workdir string) []string {
--	return b.compilerCmd(b.cxxExe(), incdir, workdir)
-+	return b.compilerCmd(b.cxxExe(false), incdir, workdir)
- }
- 
- // gfortranCmd returns a gfortran command line prefix.
- func (b *Builder) gfortranCmd(incdir, workdir string) []string {
--	return b.compilerCmd(b.fcExe(), incdir, workdir)
-+	return b.compilerCmd(b.fcExe(false), incdir, workdir)
- }
- 
- // ccExe returns the CC compiler setting without all the extra flags we add implicitly.
--func (b *Builder) ccExe() []string {
--	return b.compilerExe(origCC, cfg.DefaultCC(cfg.Goos, cfg.Goarch))
-+func (b *Builder) ccExe(filtered bool) []string {
-+	return b.compilerExe(origCC, cfg.DefaultCC(cfg.Goos, cfg.Goarch), filtered)
- }
- 
- // cxxExe returns the CXX compiler setting without all the extra flags we add implicitly.
--func (b *Builder) cxxExe() []string {
--	return b.compilerExe(origCXX, cfg.DefaultCXX(cfg.Goos, cfg.Goarch))
-+func (b *Builder) cxxExe(filtered bool) []string {
-+	return b.compilerExe(origCXX, cfg.DefaultCXX(cfg.Goos, cfg.Goarch), filtered)
- }
- 
- // fcExe returns the FC compiler setting without all the extra flags we add implicitly.
--func (b *Builder) fcExe() []string {
--	return b.compilerExe(os.Getenv("FC"), "gfortran")
-+func (b *Builder) fcExe(filtered bool) []string {
-+	return b.compilerExe(os.Getenv("FC"), "gfortran", filtered)
- }
- 
- // compilerExe returns the compiler to use given an
-@@ -1766,11 +1768,14 @@ func (b *Builder) fcExe() []string {
- // of the compiler but can have additional arguments if they
- // were present in the environment value.
- // For example if CC="gcc -DGOPHER" then the result is ["gcc", "-DGOPHER"].
--func (b *Builder) compilerExe(envValue string, def string) []string {
-+func (b *Builder) compilerExe(envValue string, def string, filtered bool) []string {
- 	compiler := strings.Fields(envValue)
- 	if len(compiler) == 0 {
- 		compiler = []string{def}
- 	}
-+	if filtered {
-+		return append(compiler[0:1], filterCompilerFlags(compiler[1:])...)
-+	}
- 	return compiler
- }
- 
-@@ -1920,8 +1925,23 @@ func envList(key, def string) []string {
- 	return strings.Fields(v)
- }
- 
-+var filterFlags = os.Getenv("CGO_PEDANTIC") == ""
-+
-+func filterCompilerFlags(flags []string) []string {
-+	var newflags []string
-+	if !filterFlags {
-+		return flags
-+	}
-+	for _, flag := range flags {
-+		if strings.HasPrefix(flag, "-m") {
-+			newflags = append(newflags, flag)
-+		}
-+	}
-+	return newflags
-+}
-+
- // CFlags returns the flags to use when invoking the C, C++ or Fortran compilers, or cgo.
--func (b *Builder) CFlags(p *load.Package) (cppflags, cflags, cxxflags, fflags, ldflags []string, err error) {
-+func (b *Builder) CFlags(p *load.Package, filtered bool) (cppflags, cflags, cxxflags, fflags, ldflags []string, err error) {
- 	defaults := "-g -O2"
- 
- 	if cppflags, err = buildFlags("CPPFLAGS", "", p.CgoCPPFLAGS, checkCompilerFlags); err != nil {
-@@ -1939,6 +1959,13 @@ func (b *Builder) CFlags(p *load.Package) (cppflags, cflags, cxxflags, fflags, l
- 	if ldflags, err = buildFlags("LDFLAGS", defaults, p.CgoLDFLAGS, checkLinkerFlags); err != nil {
- 		return
- 	}
-+	if filtered {
-+		cppflags = filterCompilerFlags(cppflags)
-+		cflags = filterCompilerFlags(cflags)
-+		cxxflags = filterCompilerFlags(cxxflags)
-+		fflags = filterCompilerFlags(fflags)
-+		ldflags = filterCompilerFlags(ldflags)
-+	}
- 
- 	return
- }
-@@ -1954,7 +1981,7 @@ var cgoRe = regexp.MustCompile(`[/\\:]`)
- 
- func (b *Builder) cgo(a *Action, cgoExe, objdir string, pcCFLAGS, pcLDFLAGS, cgofiles, gccfiles, gxxfiles, mfiles, ffiles []string) (outGo, outObj []string, err error) {
- 	p := a.Package
--	cgoCPPFLAGS, cgoCFLAGS, cgoCXXFLAGS, cgoFFLAGS, cgoLDFLAGS, err := b.CFlags(p)
-+	cgoCPPFLAGS, cgoCFLAGS, cgoCXXFLAGS, cgoFFLAGS, cgoLDFLAGS, err := b.CFlags(p, false)
- 	if err != nil {
- 		return nil, nil, err
- 	}
-@@ -2306,7 +2333,7 @@ func (b *Builder) swigIntSize(objdir string) (intsize string, err error) {
- 
- // Run SWIG on one SWIG input file.
- func (b *Builder) swigOne(a *Action, p *load.Package, file, objdir string, pcCFLAGS []string, cxx bool, intgosize string) (outGo, outC string, err error) {
--	cgoCPPFLAGS, cgoCFLAGS, cgoCXXFLAGS, _, _, err := b.CFlags(p)
-+	cgoCPPFLAGS, cgoCFLAGS, cgoCXXFLAGS, _, _, err := b.CFlags(p, false)
- 	if err != nil {
- 		return "", "", err
- 	}
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-devtools/go/go-1.10/0003-allow-GOTOOLDIR-to-be-overridden-in-the-environment.patch b/poky/meta/recipes-devtools/go/go-1.10/0003-allow-GOTOOLDIR-to-be-overridden-in-the-environment.patch
deleted file mode 100644
index 818fe66..0000000
--- a/poky/meta/recipes-devtools/go/go-1.10/0003-allow-GOTOOLDIR-to-be-overridden-in-the-environment.patch
+++ /dev/null
@@ -1,64 +0,0 @@
-From acd179b49f1fc8d6f7f69e569fb4a56039c725a1 Mon Sep 17 00:00:00 2001
-From: Matt Madison <matt@madison.systems>
-Date: Sat, 17 Feb 2018 05:24:20 -0800
-Subject: [PATCH 3/9] allow GOTOOLDIR to be overridden in the environment
-
-to allow for split host/target build roots
-
-Upstream-Status: Inappropriate [OE specific]
-
-Signed-off-by: Matt Madison <matt@madison.systems>
----
- src/cmd/dist/build.go          | 4 +++-
- src/cmd/go/internal/cfg/cfg.go | 6 +++++-
- src/go/build/build.go          | 2 +-
- 3 files changed, 9 insertions(+), 3 deletions(-)
-
-diff --git a/src/cmd/dist/build.go b/src/cmd/dist/build.go
-index 49ed80033e..afc615b5c2 100644
---- a/src/cmd/dist/build.go
-+++ b/src/cmd/dist/build.go
-@@ -220,7 +220,9 @@ func xinit() {
- 	workdir = xworkdir()
- 	xatexit(rmworkdir)
- 
--	tooldir = pathf("%s/pkg/tool/%s_%s", goroot, gohostos, gohostarch)
-+	if tooldir = os.Getenv("GOTOOLDIR"); tooldir == "" {
-+		tooldir = pathf("%s/pkg/tool/%s_%s", goroot, gohostos, gohostarch)
-+	}
- }
- 
- // compilerEnv returns a map from "goos/goarch" to the
-diff --git a/src/cmd/go/internal/cfg/cfg.go b/src/cmd/go/internal/cfg/cfg.go
-index 1de4f0dc79..4f6010d660 100644
---- a/src/cmd/go/internal/cfg/cfg.go
-+++ b/src/cmd/go/internal/cfg/cfg.go
-@@ -96,7 +96,11 @@ func init() {
- 	// as the tool directory does not move based on environment variables.
- 	// This matches the initialization of ToolDir in go/build,
- 	// except for using GOROOT rather than runtime.GOROOT().
--	build.ToolDir = filepath.Join(GOROOT, "pkg/tool/"+runtime.GOOS+"_"+runtime.GOARCH)
-+	if s := os.Getenv("GOTOOLDIR"); s != "" {
-+		build.ToolDir = filepath.Clean(s)
-+	} else {
-+		build.ToolDir = filepath.Join(GOROOT, "pkg/tool/"+runtime.GOOS+"_"+runtime.GOARCH)
-+	}
- }
- 
- func findGOROOT() string {
-diff --git a/src/go/build/build.go b/src/go/build/build.go
-index 68fb423983..81b1b32270 100644
---- a/src/go/build/build.go
-+++ b/src/go/build/build.go
-@@ -1594,7 +1594,7 @@ func init() {
- }
- 
- // ToolDir is the directory containing build tools.
--var ToolDir = filepath.Join(runtime.GOROOT(), "pkg/tool/"+runtime.GOOS+"_"+runtime.GOARCH)
-+var ToolDir = envOr("GOTOOLDIR", filepath.Join(runtime.GOROOT(), "pkg/tool/"+runtime.GOOS+"_"+runtime.GOARCH))
- 
- // IsLocalImport reports whether the import path is
- // a local import path, like ".", "..", "./foo", or "../foo".
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-devtools/go/go-1.10/0004-ld-add-soname-to-shareable-objects.patch b/poky/meta/recipes-devtools/go/go-1.10/0004-ld-add-soname-to-shareable-objects.patch
deleted file mode 100644
index c23ca94..0000000
--- a/poky/meta/recipes-devtools/go/go-1.10/0004-ld-add-soname-to-shareable-objects.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From 85252f0bd8743223eb778edbe9fb31dff17a23d8 Mon Sep 17 00:00:00 2001
-From: Matt Madison <matt@madison.systems>
-Date: Sat, 17 Feb 2018 06:26:10 -0800
-Subject: [PATCH 4/9] ld: add soname to shareable objects
-
-so that OE's shared library dependency handling
-can find them.
-
-Upstream-Status: Inappropriate [OE specific]
-
-Signed-off-by: Matt Madison <matt@madison.systems>
----
- src/cmd/link/internal/ld/lib.go | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/src/cmd/link/internal/ld/lib.go b/src/cmd/link/internal/ld/lib.go
-index 6dcaf64122..11cbb8a8bb 100644
---- a/src/cmd/link/internal/ld/lib.go
-+++ b/src/cmd/link/internal/ld/lib.go
-@@ -1134,6 +1134,7 @@ func (ctxt *Link) hostlink() {
- 				argv = append(argv, "-Wl,-z,relro")
- 			}
- 			argv = append(argv, "-shared")
-+			argv = append(argv, fmt.Sprintf("-Wl,-soname,%s", filepath.Base(*flagOutfile)))
- 			if ctxt.HeadType != objabi.Hwindows {
- 				// Pass -z nodelete to mark the shared library as
- 				// non-closeable: a dlclose will do nothing.
-@@ -1145,6 +1146,8 @@ func (ctxt *Link) hostlink() {
- 			argv = append(argv, "-Wl,-z,relro")
- 		}
- 		argv = append(argv, "-shared")
-+		argv = append(argv, fmt.Sprintf("-Wl,-soname,%s", filepath.Base(*flagOutfile)))
-+
- 	case BuildModePlugin:
- 		if ctxt.HeadType == objabi.Hdarwin {
- 			argv = append(argv, "-dynamiclib")
-@@ -1153,6 +1156,7 @@ func (ctxt *Link) hostlink() {
- 				argv = append(argv, "-Wl,-z,relro")
- 			}
- 			argv = append(argv, "-shared")
-+			argv = append(argv, fmt.Sprintf("-Wl,-soname,%s", filepath.Base(*flagOutfile)))
- 		}
- 	}
- 
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-devtools/go/go-1.10/0005-make.bash-override-CC-when-building-dist-and-go_boot.patch b/poky/meta/recipes-devtools/go/go-1.10/0005-make.bash-override-CC-when-building-dist-and-go_boot.patch
deleted file mode 100644
index 67a9393..0000000
--- a/poky/meta/recipes-devtools/go/go-1.10/0005-make.bash-override-CC-when-building-dist-and-go_boot.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From 16124d84648f4dfdfa4738c5660b5400b30bf9da Mon Sep 17 00:00:00 2001
-From: Matt Madison <matt@madison.systems>
-Date: Sat, 17 Feb 2018 06:32:45 -0800
-Subject: [PATCH 5/9] make.bash: override CC when building dist and
- go_bootstrap
-
-for handling OE cross-canadian builds.
-
-Upstream-Status: Inappropriate [OE specific]
-
-Signed-off-by: Matt Madison <matt@madison.systems>
----
- src/make.bash | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/make.bash b/src/make.bash
-index 93a5c43d11..3a63682bc4 100755
---- a/src/make.bash
-+++ b/src/make.bash
-@@ -162,7 +162,7 @@ if [ "$GOROOT_BOOTSTRAP" = "$GOROOT" ]; then
- 	exit 1
- fi
- rm -f cmd/dist/dist
--GOROOT="$GOROOT_BOOTSTRAP" GOOS="" GOARCH="" "$GOROOT_BOOTSTRAP/bin/go" build -o cmd/dist/dist ./cmd/dist
-+CC="${BUILD_CC:-${CC}}" GOROOT="$GOROOT_BOOTSTRAP" GOOS="" GOARCH="" "$GOROOT_BOOTSTRAP/bin/go" build -o cmd/dist/dist ./cmd/dist
- 
- # -e doesn't propagate out of eval, so check success by hand.
- eval $(./cmd/dist/dist env -p || echo FAIL=true)
-@@ -193,7 +193,7 @@ fi
- # Run dist bootstrap to complete make.bash.
- # Bootstrap installs a proper cmd/dist, built with the new toolchain.
- # Throw ours, built with Go 1.4, away after bootstrap.
--./cmd/dist/dist bootstrap $buildall $vflag $GO_DISTFLAGS "$@"
-+CC="${BUILD_CC:-${CC}}" ./cmd/dist/dist bootstrap $buildall $vflag $GO_DISTFLAGS "$@"
- rm -f ./cmd/dist/dist
- 
- # DO NOT ADD ANY NEW CODE HERE.
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-devtools/go/go-1.10/0006-cmd-dist-separate-host-and-target-builds.patch b/poky/meta/recipes-devtools/go/go-1.10/0006-cmd-dist-separate-host-and-target-builds.patch
deleted file mode 100644
index 9fe6996..0000000
--- a/poky/meta/recipes-devtools/go/go-1.10/0006-cmd-dist-separate-host-and-target-builds.patch
+++ /dev/null
@@ -1,277 +0,0 @@
-From 2f07af34697c61decdcfa5b11434451fbcf37704 Mon Sep 17 00:00:00 2001
-From: Matt Madison <matt@madison.systems>
-Date: Sat, 17 Feb 2018 10:03:48 -0800
-Subject: [PATCH 6/9] cmd/dist: separate host and target builds
-
-Change the dist tool to allow for OE-style cross-
-and cross-canadian builds:
-
- - command flags --host-only and --target only are added;
-   if one is present, the other changes mentioned below
-   take effect, and arguments may also be specified on
-   the command line to enumerate the package(s) to be
-   built.
-
- - for OE cross builds, go_bootstrap is always built for
-   the current build host, and is moved, along with the supporting
-   toolchain (asm, compile, etc.) to a separate 'native_native'
-   directory under GOROOT/pkg/tool.
-
- - go_bootstrap is not automatically removed after the build,
-   so it can be reused later (e.g., building both static and
-   shared runtime).
-
-Note that for --host-only builds, it would be nice to specify
-just the "cmd" package to build only the go commands/tools,
-the staleness checks in the dist tool will fail if the "std"
-library has not also been built.  So host-only builds have to
-build everything anyway.
-
-Upstream-Status: Inappropriate [OE specific]
-
-Signed-off-by: Matt Madison <matt@madison.systems>
-
-more dist cleanup
----
- src/cmd/dist/build.go | 149 +++++++++++++++++++++++++++++++++++++-------------
- 1 file changed, 111 insertions(+), 38 deletions(-)
-
-diff --git a/src/cmd/dist/build.go b/src/cmd/dist/build.go
-index afc615b5c2..36262665b2 100644
---- a/src/cmd/dist/build.go
-+++ b/src/cmd/dist/build.go
-@@ -38,6 +38,7 @@ var (
- 	goldflags        string
- 	workdir          string
- 	tooldir          string
-+	build_tooldir	 string
- 	oldgoos          string
- 	oldgoarch        string
- 	exe              string
-@@ -49,6 +50,7 @@ var (
- 
- 	rebuildall   bool
- 	defaultclang bool
-+	crossBuild   bool
- 
- 	vflag int // verbosity
- )
-@@ -223,6 +225,8 @@ func xinit() {
- 	if tooldir = os.Getenv("GOTOOLDIR"); tooldir == "" {
- 		tooldir = pathf("%s/pkg/tool/%s_%s", goroot, gohostos, gohostarch)
- 	}
-+	build_tooldir = pathf("%s/pkg/tool/native_native", goroot)
-+
- }
- 
- // compilerEnv returns a map from "goos/goarch" to the
-@@ -252,7 +256,6 @@ func compilerEnv(envName, def string) map[string]string {
- 		if gohostos != goos || gohostarch != goarch {
- 			m[gohostos+"/"+gohostarch] = m[""]
- 		}
--		m[""] = env
- 	}
- 
- 	for _, goos := range okgoos {
-@@ -479,8 +482,10 @@ func setup() {
- 	// We keep it in pkg/, just like the object directory above.
- 	if rebuildall {
- 		xremoveall(tooldir)
-+		xremoveall(build_tooldir)
- 	}
- 	xmkdirall(tooldir)
-+	xmkdirall(build_tooldir)
- 
- 	// Remove tool binaries from before the tool/gohostos_gohostarch
- 	xremoveall(pathf("%s/bin/tool", goroot))
-@@ -1130,11 +1135,29 @@ func cmdbootstrap() {
- 
- 	var noBanner bool
- 	var debug bool
-+	var hostOnly bool
-+	var targetOnly bool
-+	var toBuild = []string { "std", "cmd" }
-+
- 	flag.BoolVar(&rebuildall, "a", rebuildall, "rebuild all")
- 	flag.BoolVar(&debug, "d", debug, "enable debugging of bootstrap process")
- 	flag.BoolVar(&noBanner, "no-banner", noBanner, "do not print banner")
-+	flag.BoolVar(&hostOnly, "host-only", hostOnly, "build only host binaries, not target")
-+	flag.BoolVar(&targetOnly, "target-only", targetOnly, "build only target binaries, not host")
- 
--	xflagparse(0)
-+	xflagparse(-1)
-+
-+	if (hostOnly && targetOnly) {
-+		fatalf("specify only one of --host-only or --target-only\n")
-+	}
-+	crossBuild = hostOnly || targetOnly
-+	if flag.NArg() > 0 {
-+		if crossBuild {
-+			toBuild = flag.Args()
-+		} else {
-+			fatalf("package names not permitted without --host-only or --target-only\n")
-+		}
-+	}
- 
- 	if debug {
- 		// cmd/buildid is used in debug mode.
-@@ -1182,8 +1205,13 @@ func cmdbootstrap() {
- 		xprintf("\n")
- 	}
- 
--	gogcflags = os.Getenv("GO_GCFLAGS") // we were using $BOOT_GO_GCFLAGS until now
--	goldflags = os.Getenv("GO_LDFLAGS")
-+	// For split host/target cross/cross-canadian builds, we don't
-+	// want to be setting these flags until after we have compiled
-+	// the toolchain that runs on the build host.
-+	if ! crossBuild {
-+		gogcflags = os.Getenv("GO_GCFLAGS") // we were using $BOOT_GO_GCFLAGS until now
-+		goldflags = os.Getenv("GO_LDFLAGS")
-+	}
- 	goBootstrap := pathf("%s/go_bootstrap", tooldir)
- 	cmdGo := pathf("%s/go", gobin)
- 	if debug {
-@@ -1212,7 +1240,11 @@ func cmdbootstrap() {
- 		xprintf("\n")
- 	}
- 	xprintf("Building Go toolchain2 using go_bootstrap and Go toolchain1.\n")
--	os.Setenv("CC", compilerEnvLookup(defaultcc, goos, goarch))
-+	if crossBuild {
-+		os.Setenv("CC", defaultcc[""])
-+	} else {
-+		os.Setenv("CC", compilerEnvLookup(defaultcc, goos, goarch))
-+	}
- 	goInstall(goBootstrap, append([]string{"-i"}, toolchain...)...)
- 	if debug {
- 		run("", ShowOutput|CheckExit, pathf("%s/compile", tooldir), "-V=full")
-@@ -1249,45 +1281,82 @@ func cmdbootstrap() {
- 	}
- 	checkNotStale(goBootstrap, append(toolchain, "runtime/internal/sys")...)
- 
--	if goos == oldgoos && goarch == oldgoarch {
--		// Common case - not setting up for cross-compilation.
--		timelog("build", "toolchain")
--		if vflag > 0 {
--			xprintf("\n")
-+	if crossBuild {
-+		gogcflags = os.Getenv("GO_GCFLAGS")
-+		goldflags = os.Getenv("GO_LDFLAGS")
-+		tool_files, _ := filepath.Glob(pathf("%s/*", tooldir))
-+		for _, f := range tool_files {
-+			copyfile(pathf("%s/%s", build_tooldir, filepath.Base(f)), f, writeExec)
-+			xremove(f)
-+		}
-+		os.Setenv("GOTOOLDIR", build_tooldir)
-+		goBootstrap = pathf("%s/go_bootstrap", build_tooldir)
-+		if hostOnly {
-+			timelog("build", "host toolchain")
-+			if vflag > 0 {
-+				xprintf("\n")
-+			}
-+			xprintf("Building %s for host, %s/%s.\n", strings.Join(toBuild, ","), goos, goarch)
-+			goInstall(goBootstrap, toBuild...)
-+			checkNotStale(goBootstrap, toBuild...)
-+			// Skip cmdGo staleness checks here, since we can't necessarily run the cmdGo binary
-+
-+			timelog("build", "target toolchain")
-+			if vflag > 0 {
-+				xprintf("\n")
-+			}
-+		} else if targetOnly {
-+			goos = oldgoos
-+			goarch = oldgoarch
-+			os.Setenv("GOOS", goos)
-+			os.Setenv("GOARCH", goarch)
-+			os.Setenv("CC", compilerEnvLookup(defaultcc, goos, goarch))
-+			xprintf("Building %s for target, %s/%s.\n", strings.Join(toBuild, ","), goos, goarch)
-+			goInstall(goBootstrap, toBuild...)
-+			checkNotStale(goBootstrap, toBuild...)
-+			// Skip cmdGo staleness checks here, since we can't run the target's cmdGo binary
- 		}
--		xprintf("Building packages and commands for %s/%s.\n", goos, goarch)
- 	} else {
--		// GOOS/GOARCH does not match GOHOSTOS/GOHOSTARCH.
--		// Finish GOHOSTOS/GOHOSTARCH installation and then
--		// run GOOS/GOARCH installation.
--		timelog("build", "host toolchain")
--		if vflag > 0 {
--			xprintf("\n")
-+		if goos == oldgoos && goarch == oldgoarch {
-+			// Common case - not setting up for cross-compilation.
-+			timelog("build", "toolchain")
-+			if vflag > 0 {
-+				xprintf("\n")
-+			}
-+			xprintf("Building packages and commands for %s/%s.\n", goos, goarch)
-+		} else {
-+			// GOOS/GOARCH does not match GOHOSTOS/GOHOSTARCH.
-+			// Finish GOHOSTOS/GOHOSTARCH installation and then
-+			// run GOOS/GOARCH installation.
-+			timelog("build", "host toolchain")
-+			if vflag > 0 {
-+				xprintf("\n")
-+			}
-+			xprintf("Building packages and commands for host, %s/%s.\n", goos, goarch)
-+			goInstall(goBootstrap, "std", "cmd")
-+			checkNotStale(goBootstrap, "std", "cmd")
-+			checkNotStale(cmdGo, "std", "cmd")
-+
-+			timelog("build", "target toolchain")
-+			if vflag > 0 {
-+				xprintf("\n")
-+			}
-+			goos = oldgoos
-+			goarch = oldgoarch
-+			os.Setenv("GOOS", goos)
-+			os.Setenv("GOARCH", goarch)
-+			os.Setenv("CC", compilerEnvLookup(defaultcc, goos, goarch))
-+			xprintf("Building packages and commands for target, %s/%s.\n", goos, goarch)
- 		}
--		xprintf("Building packages and commands for host, %s/%s.\n", goos, goarch)
- 		goInstall(goBootstrap, "std", "cmd")
- 		checkNotStale(goBootstrap, "std", "cmd")
- 		checkNotStale(cmdGo, "std", "cmd")
--
--		timelog("build", "target toolchain")
--		if vflag > 0 {
--			xprintf("\n")
-+		if debug {
-+			run("", ShowOutput|CheckExit, pathf("%s/compile", tooldir), "-V=full")
-+			run("", ShowOutput|CheckExit, pathf("%s/buildid", tooldir), pathf("%s/pkg/%s_%s/runtime/internal/sys.a", goroot, goos, goarch))
-+			checkNotStale(goBootstrap, append(toolchain, "runtime/internal/sys")...)
-+			copyfile(pathf("%s/compile4", tooldir), pathf("%s/compile", tooldir), writeExec)
- 		}
--		goos = oldgoos
--		goarch = oldgoarch
--		os.Setenv("GOOS", goos)
--		os.Setenv("GOARCH", goarch)
--		os.Setenv("CC", compilerEnvLookup(defaultcc, goos, goarch))
--		xprintf("Building packages and commands for target, %s/%s.\n", goos, goarch)
--	}
--	goInstall(goBootstrap, "std", "cmd")
--	checkNotStale(goBootstrap, "std", "cmd")
--	checkNotStale(cmdGo, "std", "cmd")
--	if debug {
--		run("", ShowOutput|CheckExit, pathf("%s/compile", tooldir), "-V=full")
--		run("", ShowOutput|CheckExit, pathf("%s/buildid", tooldir), pathf("%s/pkg/%s_%s/runtime/internal/sys.a", goroot, goos, goarch))
--		checkNotStale(goBootstrap, append(toolchain, "runtime/internal/sys")...)
--		copyfile(pathf("%s/compile4", tooldir), pathf("%s/compile", tooldir), writeExec)
- 	}
- 
- 	// Check that there are no new files in $GOROOT/bin other than
-@@ -1305,7 +1374,11 @@ func cmdbootstrap() {
- 	}
- 
- 	// Remove go_bootstrap now that we're done.
--	xremove(pathf("%s/go_bootstrap", tooldir))
-+	// Except that for split host/target cross-builds, we need to
-+	// keep it.
-+	if ! crossBuild {
-+		xremove(pathf("%s/go_bootstrap", tooldir))
-+	}
- 
- 	// Print trailing banner unless instructed otherwise.
- 	if !noBanner {
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-devtools/go/go-1.10/0007-cmd-go-make-GOROOT-precious-by-default.patch b/poky/meta/recipes-devtools/go/go-1.10/0007-cmd-go-make-GOROOT-precious-by-default.patch
deleted file mode 100644
index 7242762..0000000
--- a/poky/meta/recipes-devtools/go/go-1.10/0007-cmd-go-make-GOROOT-precious-by-default.patch
+++ /dev/null
@@ -1,108 +0,0 @@
-From f98aa287941417226a6e4f78759f8a5e19732cde Mon Sep 17 00:00:00 2001
-From: Matt Madison <matt@madison.systems>
-Date: Fri, 2 Mar 2018 06:00:20 -0800
-Subject: [PATCH 7/9] cmd/go: make GOROOT precious by default
-
-The go build tool normally rebuilds whatever it detects is
-stale.  This can be a problem when GOROOT is intended to
-be read-only and the go runtime has been built as a shared
-library, since we don't want every application to be rebuilding
-the shared runtime - particularly in cross-build/packaging
-setups, since that would lead to 'abi mismatch' runtime errors.
-
-This patch prevents the install and linkshared actions from
-installing to GOROOT unless overridden with the GOROOT_OVERRIDE
-environment variable.
-
-Upstream-Status: Inappropriate [OE specific]
-
-Signed-off-by: Matt Madison <matt@madison.systems>
----
- src/cmd/go/internal/work/action.go |  3 +++
- src/cmd/go/internal/work/build.go  |  5 +++++
- src/cmd/go/internal/work/exec.go   | 25 +++++++++++++++++++++++++
- 3 files changed, 33 insertions(+)
-
-diff --git a/src/cmd/go/internal/work/action.go b/src/cmd/go/internal/work/action.go
-index 9f1f8f8a50..a382880474 100644
---- a/src/cmd/go/internal/work/action.go
-+++ b/src/cmd/go/internal/work/action.go
-@@ -563,6 +563,9 @@ func (b *Builder) addTransitiveLinkDeps(a, a1 *Action, shlib string) {
- 			if p1 == nil || p1.Shlib == "" || haveShlib[filepath.Base(p1.Shlib)] {
- 				continue
- 			}
-+			if goRootPrecious && (p1.Standard || p1.Goroot) {
-+				continue
-+			}
- 			haveShlib[filepath.Base(p1.Shlib)] = true
- 			// TODO(rsc): The use of ModeInstall here is suspect, but if we only do ModeBuild,
- 			// we'll end up building an overall library or executable that depends at runtime
-diff --git a/src/cmd/go/internal/work/build.go b/src/cmd/go/internal/work/build.go
-index 57b7b00879..e2ba95420e 100644
---- a/src/cmd/go/internal/work/build.go
-+++ b/src/cmd/go/internal/work/build.go
-@@ -143,6 +143,7 @@ See also: go install, go get, go clean.
- }
- 
- const concurrentGCBackendCompilationEnabledByDefault = true
-+var goRootPrecious bool = true
- 
- func init() {
- 	// break init cycle
-@@ -156,6 +157,10 @@ func init() {
- 
- 	AddBuildFlags(CmdBuild)
- 	AddBuildFlags(CmdInstall)
-+
-+	if x := os.Getenv("GOROOT_OVERRIDE"); x != "" {
-+		goRootPrecious = false
-+	}
- }
- 
- // Note that flags consulted by other parts of the code
-diff --git a/src/cmd/go/internal/work/exec.go b/src/cmd/go/internal/work/exec.go
-index b0f6b45647..c8f266a8ad 100644
---- a/src/cmd/go/internal/work/exec.go
-+++ b/src/cmd/go/internal/work/exec.go
-@@ -371,6 +371,23 @@ func (b *Builder) build(a *Action) (err error) {
- 		return fmt.Errorf("missing or invalid binary-only package")
- 	}
- 
-+	if goRootPrecious && (a.Package.Standard || a.Package.Goroot) {
-+		_, err := os.Stat(a.Package.Target)
-+		if err == nil {
-+			a.built = a.Package.Target
-+			a.Target = a.Package.Target
-+			a.buildID = b.fileHash(a.Package.Target)
-+			a.Package.Stale = false
-+			a.Package.StaleReason = "GOROOT-resident package"
-+			return nil
-+		}
-+		if b.ComputeStaleOnly {
-+			a.Package.Stale = true
-+			a.Package.StaleReason = "missing or invalid GOROOT-resident package"
-+			return nil
-+		}
-+	}
-+
- 	if err := b.Mkdir(a.Objdir); err != nil {
- 		return err
- 	}
-@@ -1097,6 +1114,14 @@ func BuildInstallFunc(b *Builder, a *Action) (err error) {
- 		return nil
- 	}
- 
-+	if goRootPrecious && a.Package != nil {
-+		p := a.Package
-+		if p.Standard || p.Goroot {
-+			err := fmt.Errorf("attempting to install package %s into read-only GOROOT", p.ImportPath)
-+			return err
-+		}
-+	}
-+
- 	if err := b.Mkdir(a.Objdir); err != nil {
- 		return err
- 	}
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-devtools/go/go-1.10/0008-cmd-internal-obj-arm64-fix-branch-too-far-with-TBZ-l.patch b/poky/meta/recipes-devtools/go/go-1.10/0008-cmd-internal-obj-arm64-fix-branch-too-far-with-TBZ-l.patch
deleted file mode 100644
index 1e75417..0000000
--- a/poky/meta/recipes-devtools/go/go-1.10/0008-cmd-internal-obj-arm64-fix-branch-too-far-with-TBZ-l.patch
+++ /dev/null
@@ -1,58 +0,0 @@
-From 41b90ed7af10a071ccfeede6a429e0d80518436d Mon Sep 17 00:00:00 2001
-From: Cherry Zhang <cherryyz@google.com>
-Date: Sat, 17 Feb 2018 10:31:39 -0500
-Subject: [PATCH 8/9] cmd/internal/obj/arm64: fix branch-too-far with TBZ like
- instructions
-
-The compiler now emits TBZ like instructions, but the assembler's
-too-far-branch patch code didn't include that case. Add it.
-
-Fixes #23889.
-
-Change-Id: Ib75f9250c660b9fb652835fbc83263a5d5073dc5
----
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Upstream-Status: Backport
-
- src/cmd/internal/obj/arm64/asm7.go     | 11 +++++++++--
- src/cmd/internal/obj/arm64/asm_test.go |  1 +
- 2 files changed, 10 insertions(+), 2 deletions(-)
-
-diff --git a/src/cmd/internal/obj/arm64/asm7.go b/src/cmd/internal/obj/arm64/asm7.go
-index ca81238c93..b1ee552489 100644
---- a/src/cmd/internal/obj/arm64/asm7.go
-+++ b/src/cmd/internal/obj/arm64/asm7.go
-@@ -696,9 +696,16 @@ func span7(ctxt *obj.Link, cursym *obj.LSym, newprog obj.ProgAlloc) {
- 			o = c.oplook(p)
- 
- 			/* very large branches */
--			if (o.type_ == 7 || o.type_ == 39) && p.Pcond != nil { // 7: BEQ and like, 39: CBZ and like
-+			if (o.type_ == 7 || o.type_ == 39 || o.type_ == 40) && p.Pcond != nil { // 7: BEQ and like, 39: CBZ and like, 40: TBZ and like
- 				otxt := p.Pcond.Pc - pc
--				if otxt <= -(1<<18)+10 || otxt >= (1<<18)-10 {
-+				var toofar bool
-+				switch o.type_ {
-+				case 7, 39: // branch instruction encodes 19 bits
-+					toofar = otxt <= -(1<<20)+10 || otxt >= (1<<20)-10
-+				case 40: // branch instruction encodes 14 bits
-+					toofar = otxt <= -(1<<15)+10 || otxt >= (1<<15)-10
-+				}
-+				if toofar {
- 					q := c.newprog()
- 					q.Link = p.Link
- 					p.Link = q
-diff --git a/src/cmd/internal/obj/arm64/asm_test.go b/src/cmd/internal/obj/arm64/asm_test.go
-index 369c48f510..3e0c9c13a6 100644
---- a/src/cmd/internal/obj/arm64/asm_test.go
-+++ b/src/cmd/internal/obj/arm64/asm_test.go
-@@ -52,6 +52,7 @@ func TestLarge(t *testing.T) {
- // gen generates a very large program, with a very far conditional branch.
- func gen(buf *bytes.Buffer) {
- 	fmt.Fprintln(buf, "TEXT f(SB),0,$0-0")
-+	fmt.Fprintln(buf, "TBZ $5, R0, label")
- 	fmt.Fprintln(buf, "CBZ R0, label")
- 	fmt.Fprintln(buf, "BEQ label")
- 	for i := 0; i < 1<<19; i++ {
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-devtools/go/go-1.10/0009-ld-replace-glibc-dynamic-linker-with-musl.patch b/poky/meta/recipes-devtools/go/go-1.10/0009-ld-replace-glibc-dynamic-linker-with-musl.patch
deleted file mode 100644
index 06b00b3..0000000
--- a/poky/meta/recipes-devtools/go/go-1.10/0009-ld-replace-glibc-dynamic-linker-with-musl.patch
+++ /dev/null
@@ -1,130 +0,0 @@
-From f575d85c4bd9b2903223d6c0dcc38a12775d582f Mon Sep 17 00:00:00 2001
-From: Matt Madison <matt@madison.systems>
-Date: Sun, 18 Feb 2018 08:24:05 -0800
-Subject: [PATCH 9/9] ld: replace glibc dynamic linker with musl
-
-Rework of patch by Khem Raj <raj.khem@gmail.com>
-for go 1.10.  Should be applied conditionally on
-musl being the system C library.
-
-Upstream-Status: Inappropriate [Real fix should be portable across libcs]
-
-Signed-off-by: Matt Madison <matt@madison.systems>
----
- src/cmd/link/internal/amd64/obj.go  | 2 +-
- src/cmd/link/internal/arm/obj.go    | 2 +-
- src/cmd/link/internal/arm64/obj.go  | 2 +-
- src/cmd/link/internal/mips/obj.go   | 2 +-
- src/cmd/link/internal/mips64/obj.go | 2 +-
- src/cmd/link/internal/ppc64/obj.go  | 2 +-
- src/cmd/link/internal/s390x/obj.go  | 2 +-
- src/cmd/link/internal/x86/obj.go    | 2 +-
- 8 files changed, 8 insertions(+), 8 deletions(-)
-
-diff --git a/src/cmd/link/internal/amd64/obj.go b/src/cmd/link/internal/amd64/obj.go
-index 87e809166a..f522a63034 100644
---- a/src/cmd/link/internal/amd64/obj.go
-+++ b/src/cmd/link/internal/amd64/obj.go
-@@ -62,7 +62,7 @@ func Init() (*sys.Arch, ld.Arch) {
- 		PEreloc1:         pereloc1,
- 		TLSIEtoLE:        tlsIEtoLE,
- 
--		Linuxdynld:     "/lib64/ld-linux-x86-64.so.2",
-+		Linuxdynld:     "/lib64/ld-musl-x86-64.so.1",
- 		Freebsddynld:   "/libexec/ld-elf.so.1",
- 		Openbsddynld:   "/usr/libexec/ld.so",
- 		Netbsddynld:    "/libexec/ld.elf_so",
-diff --git a/src/cmd/link/internal/arm/obj.go b/src/cmd/link/internal/arm/obj.go
-index da16f92345..fd14940ede 100644
---- a/src/cmd/link/internal/arm/obj.go
-+++ b/src/cmd/link/internal/arm/obj.go
-@@ -58,7 +58,7 @@ func Init() (*sys.Arch, ld.Arch) {
- 		Gentext:          gentext,
- 		Machoreloc1:      machoreloc1,
- 
--		Linuxdynld:     "/lib/ld-linux.so.3", // 2 for OABI, 3 for EABI
-+		Linuxdynld:     "/lib/ld-musl-armhf.so.1",
- 		Freebsddynld:   "/usr/libexec/ld-elf.so.1",
- 		Openbsddynld:   "/usr/libexec/ld.so",
- 		Netbsddynld:    "/libexec/ld.elf_so",
-diff --git a/src/cmd/link/internal/arm64/obj.go b/src/cmd/link/internal/arm64/obj.go
-index 6b386ad737..99863712cc 100644
---- a/src/cmd/link/internal/arm64/obj.go
-+++ b/src/cmd/link/internal/arm64/obj.go
-@@ -57,7 +57,7 @@ func Init() (*sys.Arch, ld.Arch) {
- 		Gentext:          gentext,
- 		Machoreloc1:      machoreloc1,
- 
--		Linuxdynld: "/lib/ld-linux-aarch64.so.1",
-+		Linuxdynld: "/lib/ld-musl-aarch64.so.1",
- 
- 		Freebsddynld:   "XXX",
- 		Openbsddynld:   "XXX",
-diff --git a/src/cmd/link/internal/mips/obj.go b/src/cmd/link/internal/mips/obj.go
-index c5d3451c39..fd85e6368d 100644
---- a/src/cmd/link/internal/mips/obj.go
-+++ b/src/cmd/link/internal/mips/obj.go
-@@ -60,7 +60,7 @@ func Init() (*sys.Arch, ld.Arch) {
- 		Gentext:          gentext,
- 		Machoreloc1:      machoreloc1,
- 
--		Linuxdynld: "/lib/ld.so.1",
-+		Linuxdynld: "/lib/ld-musl-mipsle.so.1",
- 
- 		Freebsddynld:   "XXX",
- 		Openbsddynld:   "XXX",
-diff --git a/src/cmd/link/internal/mips64/obj.go b/src/cmd/link/internal/mips64/obj.go
-index 83974e5b56..097224f6da 100644
---- a/src/cmd/link/internal/mips64/obj.go
-+++ b/src/cmd/link/internal/mips64/obj.go
-@@ -59,7 +59,7 @@ func Init() (*sys.Arch, ld.Arch) {
- 		Gentext:          gentext,
- 		Machoreloc1:      machoreloc1,
- 
--		Linuxdynld:     "/lib64/ld64.so.1",
-+		Linuxdynld:     "/lib64/ld-musl-mips64le.so.1",
- 		Freebsddynld:   "XXX",
- 		Openbsddynld:   "XXX",
- 		Netbsddynld:    "XXX",
-diff --git a/src/cmd/link/internal/ppc64/obj.go b/src/cmd/link/internal/ppc64/obj.go
-index 273d9b42cb..a503abe8ea 100644
---- a/src/cmd/link/internal/ppc64/obj.go
-+++ b/src/cmd/link/internal/ppc64/obj.go
-@@ -62,7 +62,7 @@ func Init() (*sys.Arch, ld.Arch) {
- 		Machoreloc1:      machoreloc1,
- 
- 		// TODO(austin): ABI v1 uses /usr/lib/ld.so.1,
--		Linuxdynld: "/lib64/ld64.so.1",
-+		Linuxdynld: "/lib64/ld-musl-powerpc64le.so.1",
- 
- 		Freebsddynld:   "XXX",
- 		Openbsddynld:   "XXX",
-diff --git a/src/cmd/link/internal/s390x/obj.go b/src/cmd/link/internal/s390x/obj.go
-index 9ac7eb8217..3825ff7abe 100644
---- a/src/cmd/link/internal/s390x/obj.go
-+++ b/src/cmd/link/internal/s390x/obj.go
-@@ -57,7 +57,7 @@ func Init() (*sys.Arch, ld.Arch) {
- 		Gentext:          gentext,
- 		Machoreloc1:      machoreloc1,
- 
--		Linuxdynld: "/lib64/ld64.so.1",
-+		Linuxdynld: "/lib64/ld-musl-s390x.so.1",
- 
- 		// not relevant for s390x
- 		Freebsddynld:   "XXX",
-diff --git a/src/cmd/link/internal/x86/obj.go b/src/cmd/link/internal/x86/obj.go
-index 6a744dc04e..d81f392549 100644
---- a/src/cmd/link/internal/x86/obj.go
-+++ b/src/cmd/link/internal/x86/obj.go
-@@ -58,7 +58,7 @@ func Init() (*sys.Arch, ld.Arch) {
- 		Machoreloc1:      machoreloc1,
- 		PEreloc1:         pereloc1,
- 
--		Linuxdynld:   "/lib/ld-linux.so.2",
-+		Linuxdynld:   "/lib/ld-musl-i386.so.1",
- 		Freebsddynld: "/usr/libexec/ld-elf.so.1",
- 		Openbsddynld: "/usr/libexec/ld.so",
- 		Netbsddynld:  "/usr/libexec/ld.elf_so",
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-devtools/go/go-1.11.inc b/poky/meta/recipes-devtools/go/go-1.11.inc
new file mode 100644
index 0000000..c02e468
--- /dev/null
+++ b/poky/meta/recipes-devtools/go/go-1.11.inc
@@ -0,0 +1,23 @@
+require go-common.inc
+
+GO_BASEVERSION = "1.11"
+GO_MINOR = ".1"
+PV .= "${GO_MINOR}"
+FILESEXTRAPATHS_prepend := "${FILE_DIRNAME}/go-${GO_BASEVERSION}:"
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=5d4950ecb7b26d2c5e4e7b4e0dd74707"
+
+SRC_URI += "\
+    file://0001-allow-CC-and-CXX-to-have-multiple-words.patch \
+    file://0002-cmd-go-make-content-based-hash-generation-less-pedan.patch \
+    file://0003-allow-GOTOOLDIR-to-be-overridden-in-the-environment.patch \
+    file://0004-ld-add-soname-to-shareable-objects.patch \
+    file://0005-make.bash-override-CC-when-building-dist-and-go_boot.patch \
+    file://0006-cmd-dist-separate-host-and-target-builds.patch \
+    file://0007-cmd-go-make-GOROOT-precious-by-default.patch \
+"
+
+SRC_URI_append_libc-musl = " file://0009-ld-replace-glibc-dynamic-linker-with-musl.patch"
+
+SRC_URI[main.md5sum] = "eb9e9792247143705a7aacea9398cde0"
+SRC_URI[main.sha256sum] = "558f8c169ae215e25b81421596e8de7572bd3ba824b79add22fba6e284db1117"
diff --git a/poky/meta/recipes-devtools/go/go-1.11/0001-allow-CC-and-CXX-to-have-multiple-words.patch b/poky/meta/recipes-devtools/go/go-1.11/0001-allow-CC-and-CXX-to-have-multiple-words.patch
new file mode 100644
index 0000000..4442858
--- /dev/null
+++ b/poky/meta/recipes-devtools/go/go-1.11/0001-allow-CC-and-CXX-to-have-multiple-words.patch
@@ -0,0 +1,31 @@
+From 7cc519aa5f84cf8fc7ac8c10fc69aa8040330ea0 Mon Sep 17 00:00:00 2001
+From: Matt Madison <matt@madison.systems>
+Date: Mon, 19 Feb 2018 08:49:33 -0800
+Subject: [PATCH] allow CC and CXX to have multiple words
+
+Upstream-Status: Inappropriate [OE specific]
+
+Signed-off-by: Matt Madison <matt@madison.systems>
+
+---
+ src/cmd/go/internal/envcmd/env.go | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/cmd/go/internal/envcmd/env.go b/src/cmd/go/internal/envcmd/env.go
+index afadbad..cedbfbf 100644
+--- a/src/cmd/go/internal/envcmd/env.go
++++ b/src/cmd/go/internal/envcmd/env.go
+@@ -85,11 +85,11 @@ func MkEnv() []cfg.EnvVar {
+ 
+ 	cc := cfg.DefaultCC(cfg.Goos, cfg.Goarch)
+ 	if env := strings.Fields(os.Getenv("CC")); len(env) > 0 {
+-		cc = env[0]
++		cc = strings.Join(env, " ")
+ 	}
+ 	cxx := cfg.DefaultCXX(cfg.Goos, cfg.Goarch)
+ 	if env := strings.Fields(os.Getenv("CXX")); len(env) > 0 {
+-		cxx = env[0]
++		cxx = strings.Join(env, " ")
+ 	}
+ 	env = append(env, cfg.EnvVar{Name: "CC", Value: cc})
+ 	env = append(env, cfg.EnvVar{Name: "CXX", Value: cxx})
diff --git a/poky/meta/recipes-devtools/go/go-1.11/0002-cmd-go-make-content-based-hash-generation-less-pedan.patch b/poky/meta/recipes-devtools/go/go-1.11/0002-cmd-go-make-content-based-hash-generation-less-pedan.patch
new file mode 100644
index 0000000..66b8561
--- /dev/null
+++ b/poky/meta/recipes-devtools/go/go-1.11/0002-cmd-go-make-content-based-hash-generation-less-pedan.patch
@@ -0,0 +1,218 @@
+From 47db69e20ed66fb62b01affd83d829654b829893 Mon Sep 17 00:00:00 2001
+From: Matt Madison <matt@madison.systems>
+Date: Mon, 19 Feb 2018 08:50:59 -0800
+Subject: [PATCH] cmd/go: make content-based hash generation less pedantic
+
+Go 1.10's build tool now uses content-based hashes to
+determine when something should be built or re-built.
+This same mechanism is used to maintain a built-artifact
+cache for speeding up builds.
+
+However, the hashes it generates include information that
+doesn't work well with OE, nor with using a shared runtime
+library.
+
+First, it embeds path names to source files, unless
+building within GOROOT.  This prevents the building
+of a package in GOPATH for later staging into GOROOT.
+
+This patch adds support for the environment variable
+GOPATH_OMIT_IN_ACTIONID.  If present, path name
+embedding is disabled.
+
+Second, if cgo is enabled, the build ID for cgo-related
+packages will include the current value of the environment
+variables for invoking the compiler (CC, CXX, FC) and
+any CGO_xxFLAGS variables.  Only if the settings used
+during a compilation exactly match, character for character,
+the values used for compiling runtime/cgo or any other
+cgo-enabled package being imported, will the tool
+decide that the imported package is up-to-date.
+
+This is done to help ensure correctness, but is overly
+simplistic and effectively prevents the reuse of built
+artifacts that use cgo (or shared runtime, which includes
+runtime/cgo).
+
+This patch filters out all compiler flags except those
+beginning with '-m'.  The default behavior can be restored
+by setting the CGO_PEDANTIC environment variable.
+
+Upstream-Status: Inappropriate [OE specific]
+
+Signed-off-by: Matt Madison <matt@madison.systems>
+
+---
+ src/cmd/go/internal/envcmd/env.go |  2 +-
+ src/cmd/go/internal/work/exec.go  | 63 ++++++++++++++++++++++---------
+ 2 files changed, 46 insertions(+), 19 deletions(-)
+
+diff --git a/src/cmd/go/internal/envcmd/env.go b/src/cmd/go/internal/envcmd/env.go
+index cedbfbf..5763a0d 100644
+--- a/src/cmd/go/internal/envcmd/env.go
++++ b/src/cmd/go/internal/envcmd/env.go
+@@ -128,7 +128,7 @@ func ExtraEnvVars() []cfg.EnvVar {
+ func ExtraEnvVarsCostly() []cfg.EnvVar {
+ 	var b work.Builder
+ 	b.Init()
+-	cppflags, cflags, cxxflags, fflags, ldflags, err := b.CFlags(&load.Package{})
++	cppflags, cflags, cxxflags, fflags, ldflags, err := b.CFlags(&load.Package{}, false)
+ 	if err != nil {
+ 		// Should not happen - b.CFlags was given an empty package.
+ 		fmt.Fprintf(os.Stderr, "go: invalid cflags: %v\n", err)
+diff --git a/src/cmd/go/internal/work/exec.go b/src/cmd/go/internal/work/exec.go
+index 12e1527..e41bfac 100644
+--- a/src/cmd/go/internal/work/exec.go
++++ b/src/cmd/go/internal/work/exec.go
+@@ -174,6 +174,8 @@ func (b *Builder) Do(root *Action) {
+ 	wg.Wait()
+ }
+ 
++var omitGopath = os.Getenv("GOPATH_OMIT_IN_ACTIONID") != ""
++
+ // buildActionID computes the action ID for a build action.
+ func (b *Builder) buildActionID(a *Action) cache.ActionID {
+ 	p := a.Package
+@@ -190,7 +192,7 @@ func (b *Builder) buildActionID(a *Action) cache.ActionID {
+ 	// but it does not hide the exact value of $GOPATH.
+ 	// Include the full dir in that case.
+ 	// Assume b.WorkDir is being trimmed properly.
+-	if !p.Goroot && !strings.HasPrefix(p.Dir, b.WorkDir) {
++	if !p.Goroot && !omitGopath && !strings.HasPrefix(p.Dir, b.WorkDir) {
+ 		fmt.Fprintf(h, "dir %s\n", p.Dir)
+ 	}
+ 	fmt.Fprintf(h, "goos %s goarch %s\n", cfg.Goos, cfg.Goarch)
+@@ -201,13 +203,13 @@ func (b *Builder) buildActionID(a *Action) cache.ActionID {
+ 	}
+ 	if len(p.CgoFiles)+len(p.SwigFiles) > 0 {
+ 		fmt.Fprintf(h, "cgo %q\n", b.toolID("cgo"))
+-		cppflags, cflags, cxxflags, fflags, ldflags, _ := b.CFlags(p)
+-		fmt.Fprintf(h, "CC=%q %q %q %q\n", b.ccExe(), cppflags, cflags, ldflags)
++		cppflags, cflags, cxxflags, fflags, ldflags, _ := b.CFlags(p, true)
++		fmt.Fprintf(h, "CC=%q %q %q %q\n", b.ccExe(true), cppflags, cflags, ldflags)
+ 		if len(p.CXXFiles)+len(p.SwigFiles) > 0 {
+-			fmt.Fprintf(h, "CXX=%q %q\n", b.cxxExe(), cxxflags)
++			fmt.Fprintf(h, "CXX=%q %q\n", b.cxxExe(true), cxxflags)
+ 		}
+ 		if len(p.FFiles) > 0 {
+-			fmt.Fprintf(h, "FC=%q %q\n", b.fcExe(), fflags)
++			fmt.Fprintf(h, "FC=%q %q\n", b.fcExe(true), fflags)
+ 		}
+ 		// TODO(rsc): Should we include the SWIG version or Fortran/GCC/G++/Objective-C compiler versions?
+ 	}
+@@ -2096,33 +2098,33 @@ var (
+ // gccCmd returns a gcc command line prefix
+ // defaultCC is defined in zdefaultcc.go, written by cmd/dist.
+ func (b *Builder) GccCmd(incdir, workdir string) []string {
+-	return b.compilerCmd(b.ccExe(), incdir, workdir)
++	return b.compilerCmd(b.ccExe(false), incdir, workdir)
+ }
+ 
+ // gxxCmd returns a g++ command line prefix
+ // defaultCXX is defined in zdefaultcc.go, written by cmd/dist.
+ func (b *Builder) GxxCmd(incdir, workdir string) []string {
+-	return b.compilerCmd(b.cxxExe(), incdir, workdir)
++	return b.compilerCmd(b.cxxExe(false), incdir, workdir)
+ }
+ 
+ // gfortranCmd returns a gfortran command line prefix.
+ func (b *Builder) gfortranCmd(incdir, workdir string) []string {
+-	return b.compilerCmd(b.fcExe(), incdir, workdir)
++	return b.compilerCmd(b.fcExe(false), incdir, workdir)
+ }
+ 
+ // ccExe returns the CC compiler setting without all the extra flags we add implicitly.
+-func (b *Builder) ccExe() []string {
+-	return b.compilerExe(origCC, cfg.DefaultCC(cfg.Goos, cfg.Goarch))
++func (b *Builder) ccExe(filtered bool) []string {
++	return b.compilerExe(origCC, cfg.DefaultCC(cfg.Goos, cfg.Goarch), filtered)
+ }
+ 
+ // cxxExe returns the CXX compiler setting without all the extra flags we add implicitly.
+-func (b *Builder) cxxExe() []string {
+-	return b.compilerExe(origCXX, cfg.DefaultCXX(cfg.Goos, cfg.Goarch))
++func (b *Builder) cxxExe(filtered bool) []string {
++	return b.compilerExe(origCXX, cfg.DefaultCXX(cfg.Goos, cfg.Goarch), filtered)
+ }
+ 
+ // fcExe returns the FC compiler setting without all the extra flags we add implicitly.
+-func (b *Builder) fcExe() []string {
+-	return b.compilerExe(os.Getenv("FC"), "gfortran")
++func (b *Builder) fcExe(filtered bool) []string {
++	return b.compilerExe(os.Getenv("FC"), "gfortran", filtered)
+ }
+ 
+ // compilerExe returns the compiler to use given an
+@@ -2131,11 +2133,14 @@ func (b *Builder) fcExe() []string {
+ // of the compiler but can have additional arguments if they
+ // were present in the environment value.
+ // For example if CC="gcc -DGOPHER" then the result is ["gcc", "-DGOPHER"].
+-func (b *Builder) compilerExe(envValue string, def string) []string {
++func (b *Builder) compilerExe(envValue string, def string, filtered bool) []string {
+ 	compiler := strings.Fields(envValue)
+ 	if len(compiler) == 0 {
+ 		compiler = []string{def}
+ 	}
++	if filtered {
++		return append(compiler[0:1], filterCompilerFlags(compiler[1:])...)
++	}
+ 	return compiler
+ }
+ 
+@@ -2285,8 +2290,23 @@ func envList(key, def string) []string {
+ 	return strings.Fields(v)
+ }
+ 
++var filterFlags = os.Getenv("CGO_PEDANTIC") == ""
++
++func filterCompilerFlags(flags []string) []string {
++	var newflags []string
++	if !filterFlags {
++		return flags
++	}
++	for _, flag := range flags {
++		if strings.HasPrefix(flag, "-m") {
++			newflags = append(newflags, flag)
++		}
++	}
++	return newflags
++}
++
+ // CFlags returns the flags to use when invoking the C, C++ or Fortran compilers, or cgo.
+-func (b *Builder) CFlags(p *load.Package) (cppflags, cflags, cxxflags, fflags, ldflags []string, err error) {
++func (b *Builder) CFlags(p *load.Package, filtered bool) (cppflags, cflags, cxxflags, fflags, ldflags []string, err error) {
+ 	defaults := "-g -O2"
+ 
+ 	if cppflags, err = buildFlags("CPPFLAGS", "", p.CgoCPPFLAGS, checkCompilerFlags); err != nil {
+@@ -2304,6 +2324,13 @@ func (b *Builder) CFlags(p *load.Package) (cppflags, cflags, cxxflags, fflags, l
+ 	if ldflags, err = buildFlags("LDFLAGS", defaults, p.CgoLDFLAGS, checkLinkerFlags); err != nil {
+ 		return
+ 	}
++	if filtered {
++		cppflags = filterCompilerFlags(cppflags)
++		cflags = filterCompilerFlags(cflags)
++		cxxflags = filterCompilerFlags(cxxflags)
++		fflags = filterCompilerFlags(fflags)
++		ldflags = filterCompilerFlags(ldflags)
++	}
+ 
+ 	return
+ }
+@@ -2319,7 +2346,7 @@ var cgoRe = regexp.MustCompile(`[/\\:]`)
+ 
+ func (b *Builder) cgo(a *Action, cgoExe, objdir string, pcCFLAGS, pcLDFLAGS, cgofiles, gccfiles, gxxfiles, mfiles, ffiles []string) (outGo, outObj []string, err error) {
+ 	p := a.Package
+-	cgoCPPFLAGS, cgoCFLAGS, cgoCXXFLAGS, cgoFFLAGS, cgoLDFLAGS, err := b.CFlags(p)
++	cgoCPPFLAGS, cgoCFLAGS, cgoCXXFLAGS, cgoFFLAGS, cgoLDFLAGS, err := b.CFlags(p, false)
+ 	if err != nil {
+ 		return nil, nil, err
+ 	}
+@@ -2679,7 +2706,7 @@ func (b *Builder) swigIntSize(objdir string) (intsize string, err error) {
+ 
+ // Run SWIG on one SWIG input file.
+ func (b *Builder) swigOne(a *Action, p *load.Package, file, objdir string, pcCFLAGS []string, cxx bool, intgosize string) (outGo, outC string, err error) {
+-	cgoCPPFLAGS, cgoCFLAGS, cgoCXXFLAGS, _, _, err := b.CFlags(p)
++	cgoCPPFLAGS, cgoCFLAGS, cgoCXXFLAGS, _, _, err := b.CFlags(p, false)
+ 	if err != nil {
+ 		return "", "", err
+ 	}
diff --git a/poky/meta/recipes-devtools/go/go-1.11/0003-allow-GOTOOLDIR-to-be-overridden-in-the-environment.patch b/poky/meta/recipes-devtools/go/go-1.11/0003-allow-GOTOOLDIR-to-be-overridden-in-the-environment.patch
new file mode 100644
index 0000000..b6ca40e
--- /dev/null
+++ b/poky/meta/recipes-devtools/go/go-1.11/0003-allow-GOTOOLDIR-to-be-overridden-in-the-environment.patch
@@ -0,0 +1,48 @@
+From 5c32c38bf19b24f0aadd78012d17ff5caa82151e Mon Sep 17 00:00:00 2001
+From: Matt Madison <matt@madison.systems>
+Date: Sat, 17 Feb 2018 05:24:20 -0800
+Subject: [PATCH] allow GOTOOLDIR to be overridden in the environment
+
+to allow for split host/target build roots
+
+Upstream-Status: Inappropriate [OE specific]
+
+Signed-off-by: Matt Madison <matt@madison.systems>
+
+---
+ src/cmd/dist/build.go          | 4 +++-
+ src/cmd/go/internal/cfg/cfg.go | 7 +++++--
+ 2 files changed, 8 insertions(+), 3 deletions(-)
+
+Index: go/src/cmd/dist/build.go
+===================================================================
+--- go.orig/src/cmd/dist/build.go
++++ go/src/cmd/dist/build.go
+@@ -228,7 +228,9 @@ func xinit() {
+ 	workdir = xworkdir()
+ 	xatexit(rmworkdir)
+ 
+-	tooldir = pathf("%s/pkg/tool/%s_%s", goroot, gohostos, gohostarch)
++	if tooldir = os.Getenv("GOTOOLDIR"); tooldir == "" {
++		tooldir = pathf("%s/pkg/tool/%s_%s", goroot, gohostos, gohostarch)
++	}
+ }
+ 
+ // compilerEnv returns a map from "goos/goarch" to the
+Index: go/src/cmd/go/internal/cfg/cfg.go
+===================================================================
+--- go.orig/src/cmd/go/internal/cfg/cfg.go
++++ go/src/cmd/go/internal/cfg/cfg.go
+@@ -116,7 +116,11 @@ func init() {
+ 		// variables. This matches the initialization of ToolDir in
+ 		// go/build, except for using GOROOT rather than
+ 		// runtime.GOROOT.
+-		build.ToolDir = filepath.Join(GOROOT, "pkg/tool/"+runtime.GOOS+"_"+runtime.GOARCH)
++		if s := os.Getenv("GOTOOLDIR"); s != "" {
++			build.ToolDir = filepath.Clean(s)
++		} else {
++			build.ToolDir = filepath.Join(GOROOT, "pkg/tool/"+runtime.GOOS+"_"+runtime.GOARCH)
++		}
+ 	}
+ }
+ 
diff --git a/poky/meta/recipes-devtools/go/go-1.11/0004-ld-add-soname-to-shareable-objects.patch b/poky/meta/recipes-devtools/go/go-1.11/0004-ld-add-soname-to-shareable-objects.patch
new file mode 100644
index 0000000..004a33a
--- /dev/null
+++ b/poky/meta/recipes-devtools/go/go-1.11/0004-ld-add-soname-to-shareable-objects.patch
@@ -0,0 +1,45 @@
+From 55eb8c95a89f32aec16b7764e78e8cf75169dc81 Mon Sep 17 00:00:00 2001
+From: Matt Madison <matt@madison.systems>
+Date: Sat, 17 Feb 2018 06:26:10 -0800
+Subject: [PATCH] ld: add soname to shareable objects
+
+so that OE's shared library dependency handling
+can find them.
+
+Upstream-Status: Inappropriate [OE specific]
+
+Signed-off-by: Matt Madison <matt@madison.systems>
+
+---
+ src/cmd/link/internal/ld/lib.go | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/src/cmd/link/internal/ld/lib.go b/src/cmd/link/internal/ld/lib.go
+index 220aab3..703925f 100644
+--- a/src/cmd/link/internal/ld/lib.go
++++ b/src/cmd/link/internal/ld/lib.go
+@@ -1135,6 +1135,7 @@ func (ctxt *Link) hostlink() {
+ 				argv = append(argv, "-Wl,-z,relro")
+ 			}
+ 			argv = append(argv, "-shared")
++			argv = append(argv, fmt.Sprintf("-Wl,-soname,%s", filepath.Base(*flagOutfile)))
+ 			if ctxt.HeadType != objabi.Hwindows {
+ 				// Pass -z nodelete to mark the shared library as
+ 				// non-closeable: a dlclose will do nothing.
+@@ -1146,6 +1147,8 @@ func (ctxt *Link) hostlink() {
+ 			argv = append(argv, "-Wl,-z,relro")
+ 		}
+ 		argv = append(argv, "-shared")
++		argv = append(argv, fmt.Sprintf("-Wl,-soname,%s", filepath.Base(*flagOutfile)))
++
+ 	case BuildModePlugin:
+ 		if ctxt.HeadType == objabi.Hdarwin {
+ 			argv = append(argv, "-dynamiclib")
+@@ -1154,6 +1157,7 @@ func (ctxt *Link) hostlink() {
+ 				argv = append(argv, "-Wl,-z,relro")
+ 			}
+ 			argv = append(argv, "-shared")
++			argv = append(argv, fmt.Sprintf("-Wl,-soname,%s", filepath.Base(*flagOutfile)))
+ 		}
+ 	}
+ 
diff --git a/poky/meta/recipes-devtools/go/go-1.11/0005-make.bash-override-CC-when-building-dist-and-go_boot.patch b/poky/meta/recipes-devtools/go/go-1.11/0005-make.bash-override-CC-when-building-dist-and-go_boot.patch
new file mode 100644
index 0000000..ace8de9
--- /dev/null
+++ b/poky/meta/recipes-devtools/go/go-1.11/0005-make.bash-override-CC-when-building-dist-and-go_boot.patch
@@ -0,0 +1,37 @@
+From 1bf15aa8fb773604b2524cfdab493fa4d8fa9285 Mon Sep 17 00:00:00 2001
+From: Matt Madison <matt@madison.systems>
+Date: Sat, 17 Feb 2018 06:32:45 -0800
+Subject: [PATCH] make.bash: override CC when building dist and go_bootstrap
+
+for handling OE cross-canadian builds.
+
+Upstream-Status: Inappropriate [OE specific]
+
+Signed-off-by: Matt Madison <matt@madison.systems>
+
+---
+ src/make.bash | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/make.bash b/src/make.bash
+index 78882d9..25943d0 100755
+--- a/src/make.bash
++++ b/src/make.bash
+@@ -163,7 +163,7 @@ if [ "$GOROOT_BOOTSTRAP" = "$GOROOT" ]; then
+ 	exit 1
+ fi
+ rm -f cmd/dist/dist
+-GOROOT="$GOROOT_BOOTSTRAP" GOOS="" GOARCH="" "$GOROOT_BOOTSTRAP/bin/go" build -o cmd/dist/dist ./cmd/dist
++CC="${BUILD_CC:-${CC}}" GOROOT="$GOROOT_BOOTSTRAP" GOOS="" GOARCH="" "$GOROOT_BOOTSTRAP/bin/go" build -o cmd/dist/dist ./cmd/dist
+ 
+ # -e doesn't propagate out of eval, so check success by hand.
+ eval $(./cmd/dist/dist env -p || echo FAIL=true)
+@@ -194,7 +194,7 @@ fi
+ # Run dist bootstrap to complete make.bash.
+ # Bootstrap installs a proper cmd/dist, built with the new toolchain.
+ # Throw ours, built with Go 1.4, away after bootstrap.
+-./cmd/dist/dist bootstrap $buildall $vflag $GO_DISTFLAGS "$@"
++CC="${BUILD_CC:-${CC}}" ./cmd/dist/dist bootstrap $buildall $vflag $GO_DISTFLAGS "$@"
+ rm -f ./cmd/dist/dist
+ 
+ # DO NOT ADD ANY NEW CODE HERE.
diff --git a/poky/meta/recipes-devtools/go/go-1.11/0006-cmd-dist-separate-host-and-target-builds.patch b/poky/meta/recipes-devtools/go/go-1.11/0006-cmd-dist-separate-host-and-target-builds.patch
new file mode 100644
index 0000000..0c0d5da
--- /dev/null
+++ b/poky/meta/recipes-devtools/go/go-1.11/0006-cmd-dist-separate-host-and-target-builds.patch
@@ -0,0 +1,282 @@
+From fe0fcaf43ef3aab81541dad2a71b46254dc4cf6a Mon Sep 17 00:00:00 2001
+From: Matt Madison <matt@madison.systems>
+Date: Sat, 17 Feb 2018 10:03:48 -0800
+Subject: [PATCH] cmd/dist: separate host and target builds
+
+Change the dist tool to allow for OE-style cross-
+and cross-canadian builds:
+
+ - command flags --host-only and --target only are added;
+   if one is present, the other changes mentioned below
+   take effect, and arguments may also be specified on
+   the command line to enumerate the package(s) to be
+   built.
+
+ - for OE cross builds, go_bootstrap is always built for
+   the current build host, and is moved, along with the supporting
+   toolchain (asm, compile, etc.) to a separate 'native_native'
+   directory under GOROOT/pkg/tool.
+
+ - go_bootstrap is not automatically removed after the build,
+   so it can be reused later (e.g., building both static and
+   shared runtime).
+
+Note that for --host-only builds, it would be nice to specify
+just the "cmd" package to build only the go commands/tools,
+the staleness checks in the dist tool will fail if the "std"
+library has not also been built.  So host-only builds have to
+build everything anyway.
+
+Upstream-Status: Inappropriate [OE specific]
+
+Signed-off-by: Matt Madison <matt@madison.systems>
+
+more dist cleanup
+
+---
+ src/cmd/dist/build.go | 153 ++++++++++++++++++++++++++++++------------
+ 1 file changed, 111 insertions(+), 42 deletions(-)
+
+Index: go/src/cmd/dist/build.go
+===================================================================
+--- go.orig/src/cmd/dist/build.go
++++ go/src/cmd/dist/build.go
+@@ -39,6 +39,7 @@ var (
+ 	goldflags        string
+ 	workdir          string
+ 	tooldir          string
++	build_tooldir	 string
+ 	oldgoos          string
+ 	oldgoarch        string
+ 	exe              string
+@@ -50,6 +51,7 @@ var (
+ 
+ 	rebuildall   bool
+ 	defaultclang bool
++	crossBuild   bool
+ 
+ 	vflag int // verbosity
+ )
+@@ -231,6 +233,8 @@ func xinit() {
+ 	if tooldir = os.Getenv("GOTOOLDIR"); tooldir == "" {
+ 		tooldir = pathf("%s/pkg/tool/%s_%s", goroot, gohostos, gohostarch)
+ 	}
++	build_tooldir = pathf("%s/pkg/tool/native_native", goroot)
++
+ }
+ 
+ // compilerEnv returns a map from "goos/goarch" to the
+@@ -260,7 +264,6 @@ func compilerEnv(envName, def string) ma
+ 		if gohostos != goos || gohostarch != goarch {
+ 			m[gohostos+"/"+gohostarch] = m[""]
+ 		}
+-		m[""] = env
+ 	}
+ 
+ 	for _, goos := range okgoos {
+@@ -487,8 +490,10 @@ func setup() {
+ 	// We keep it in pkg/, just like the object directory above.
+ 	if rebuildall {
+ 		xremoveall(tooldir)
++		xremoveall(build_tooldir)
+ 	}
+ 	xmkdirall(tooldir)
++	xmkdirall(build_tooldir)
+ 
+ 	// Remove tool binaries from before the tool/gohostos_gohostarch
+ 	xremoveall(pathf("%s/bin/tool", goroot))
+@@ -1155,11 +1160,29 @@ func cmdbootstrap() {
+ 
+ 	var noBanner bool
+ 	var debug bool
++	var hostOnly bool
++	var targetOnly bool
++	var toBuild = []string { "std", "cmd" }
++
+ 	flag.BoolVar(&rebuildall, "a", rebuildall, "rebuild all")
+ 	flag.BoolVar(&debug, "d", debug, "enable debugging of bootstrap process")
+ 	flag.BoolVar(&noBanner, "no-banner", noBanner, "do not print banner")
++	flag.BoolVar(&hostOnly, "host-only", hostOnly, "build only host binaries, not target")
++	flag.BoolVar(&targetOnly, "target-only", targetOnly, "build only target binaries, not host")
+ 
+-	xflagparse(0)
++	xflagparse(-1)
++
++	if (hostOnly && targetOnly) {
++		fatalf("specify only one of --host-only or --target-only\n")
++	}
++	crossBuild = hostOnly || targetOnly
++	if flag.NArg() > 0 {
++		if crossBuild {
++			toBuild = flag.Args()
++		} else {
++			fatalf("package names not permitted without --host-only or --target-only\n")
++		}
++	}
+ 
+ 	if debug {
+ 		// cmd/buildid is used in debug mode.
+@@ -1207,8 +1230,13 @@ func cmdbootstrap() {
+ 		xprintf("\n")
+ 	}
+ 
+-	gogcflags = os.Getenv("GO_GCFLAGS") // we were using $BOOT_GO_GCFLAGS until now
+-	goldflags = os.Getenv("GO_LDFLAGS")
++	// For split host/target cross/cross-canadian builds, we don't
++	// want to be setting these flags until after we have compiled
++	// the toolchain that runs on the build host.
++	if ! crossBuild {
++		gogcflags = os.Getenv("GO_GCFLAGS") // we were using $BOOT_GO_GCFLAGS until now
++		goldflags = os.Getenv("GO_LDFLAGS")
++	}
+ 	goBootstrap := pathf("%s/go_bootstrap", tooldir)
+ 	cmdGo := pathf("%s/go", gobin)
+ 	if debug {
+@@ -1237,7 +1265,11 @@ func cmdbootstrap() {
+ 		xprintf("\n")
+ 	}
+ 	xprintf("Building Go toolchain2 using go_bootstrap and Go toolchain1.\n")
+-	os.Setenv("CC", compilerEnvLookup(defaultcc, goos, goarch))
++	if crossBuild {
++		os.Setenv("CC", defaultcc[""])
++	} else {
++		os.Setenv("CC", compilerEnvLookup(defaultcc, goos, goarch))
++	}
+ 	goInstall(goBootstrap, append([]string{"-i"}, toolchain...)...)
+ 	if debug {
+ 		run("", ShowOutput|CheckExit, pathf("%s/compile", tooldir), "-V=full")
+@@ -1274,50 +1306,84 @@ func cmdbootstrap() {
+ 	}
+ 	checkNotStale(goBootstrap, append(toolchain, "runtime/internal/sys")...)
+ 
+-	if goos == oldgoos && goarch == oldgoarch {
+-		// Common case - not setting up for cross-compilation.
+-		timelog("build", "toolchain")
+-		if vflag > 0 {
+-			xprintf("\n")
++	if crossBuild {
++		gogcflags = os.Getenv("GO_GCFLAGS")
++		goldflags = os.Getenv("GO_LDFLAGS")
++		tool_files, _ := filepath.Glob(pathf("%s/*", tooldir))
++		for _, f := range tool_files {
++			copyfile(pathf("%s/%s", build_tooldir, filepath.Base(f)), f, writeExec)
++			xremove(f)
++		}
++		os.Setenv("GOTOOLDIR", build_tooldir)
++		goBootstrap = pathf("%s/go_bootstrap", build_tooldir)
++		if hostOnly {
++			timelog("build", "host toolchain")
++			if vflag > 0 {
++				xprintf("\n")
++			}
++			xprintf("Building %s for host, %s/%s.\n", strings.Join(toBuild, ","), goos, goarch)
++			goInstall(goBootstrap, toBuild...)
++			checkNotStale(goBootstrap, toBuild...)
++			// Skip cmdGo staleness checks here, since we can't necessarily run the cmdGo binary
++
++			timelog("build", "target toolchain")
++			if vflag > 0 {
++				xprintf("\n")
++			}
++		} else if targetOnly {
++			goos = oldgoos
++			goarch = oldgoarch
++			os.Setenv("GOOS", goos)
++			os.Setenv("GOARCH", goarch)
++			os.Setenv("CC", compilerEnvLookup(defaultcc, goos, goarch))
++			xprintf("Building %s for target, %s/%s.\n", strings.Join(toBuild, ","), goos, goarch)
++			goInstall(goBootstrap, toBuild...)
++			checkNotStale(goBootstrap, toBuild...)
++			// Skip cmdGo staleness checks here, since we can't run the target's cmdGo binary
+ 		}
+-		xprintf("Building packages and commands for %s/%s.\n", goos, goarch)
+ 	} else {
+-		// GOOS/GOARCH does not match GOHOSTOS/GOHOSTARCH.
+-		// Finish GOHOSTOS/GOHOSTARCH installation and then
+-		// run GOOS/GOARCH installation.
+-		timelog("build", "host toolchain")
+-		if vflag > 0 {
+-			xprintf("\n")
++
++		if goos == oldgoos && goarch == oldgoarch {
++			// Common case - not setting up for cross-compilation.
++			timelog("build", "toolchain")
++			if vflag > 0 {
++				xprintf("\n")
++			}
++			xprintf("Building packages and commands for %s/%s.\n", goos, goarch)
++		} else {
++			// GOOS/GOARCH does not match GOHOSTOS/GOHOSTARCH.
++			// Finish GOHOSTOS/GOHOSTARCH installation and then
++			// run GOOS/GOARCH installation.
++			timelog("build", "host toolchain")
++			if vflag > 0 {
++				xprintf("\n")
++			}
++			xprintf("Building packages and commands for host, %s/%s.\n", goos, goarch)
++			goInstall(goBootstrap, "std", "cmd")
++			checkNotStale(goBootstrap, "std", "cmd")
++			checkNotStale(cmdGo, "std", "cmd")
++
++			timelog("build", "target toolchain")
++			if vflag > 0 {
++				xprintf("\n")
++			}
++			goos = oldgoos
++			goarch = oldgoarch
++			os.Setenv("GOOS", goos)
++			os.Setenv("GOARCH", goarch)
++			os.Setenv("CC", compilerEnvLookup(defaultcc, goos, goarch))
++			xprintf("Building packages and commands for target, %s/%s.\n", goos, goarch)
+ 		}
+-		xprintf("Building packages and commands for host, %s/%s.\n", goos, goarch)
+ 		goInstall(goBootstrap, "std", "cmd")
+ 		checkNotStale(goBootstrap, "std", "cmd")
+ 		checkNotStale(cmdGo, "std", "cmd")
+ 
+-		timelog("build", "target toolchain")
+-		if vflag > 0 {
+-			xprintf("\n")
+-		}
+-		goos = oldgoos
+-		goarch = oldgoarch
+-		os.Setenv("GOOS", goos)
+-		os.Setenv("GOARCH", goarch)
+-		os.Setenv("CC", compilerEnvLookup(defaultcc, goos, goarch))
+-		xprintf("Building packages and commands for target, %s/%s.\n", goos, goarch)
+-	}
+-	targets := []string{"std", "cmd"}
+-	if goos == "js" && goarch == "wasm" {
+-		// Skip the cmd tools for js/wasm. They're not usable.
+-		targets = targets[:1]
+-	}
+-	goInstall(goBootstrap, targets...)
+-	checkNotStale(goBootstrap, targets...)
+-	checkNotStale(cmdGo, targets...)
+-	if debug {
+-		run("", ShowOutput|CheckExit, pathf("%s/compile", tooldir), "-V=full")
+-		run("", ShowOutput|CheckExit, pathf("%s/buildid", tooldir), pathf("%s/pkg/%s_%s/runtime/internal/sys.a", goroot, goos, goarch))
+-		checkNotStale(goBootstrap, append(toolchain, "runtime/internal/sys")...)
+-		copyfile(pathf("%s/compile4", tooldir), pathf("%s/compile", tooldir), writeExec)
++		if debug {
++			run("", ShowOutput|CheckExit, pathf("%s/compile", tooldir), "-V=full")
++			run("", ShowOutput|CheckExit, pathf("%s/buildid", tooldir), pathf("%s/pkg/%s_%s/runtime/internal/sys.a", goroot, goos, goarch))
++			checkNotStale(goBootstrap, append(toolchain, "runtime/internal/sys")...)
++			copyfile(pathf("%s/compile4", tooldir), pathf("%s/compile", tooldir), writeExec)
++		}
+ 	}
+ 
+ 	// Check that there are no new files in $GOROOT/bin other than
+@@ -1335,7 +1401,11 @@ func cmdbootstrap() {
+ 	}
+ 
+ 	// Remove go_bootstrap now that we're done.
+-	xremove(pathf("%s/go_bootstrap", tooldir))
++	// Except that for split host/target cross-builds, we need to
++	// keep it.
++	if ! crossBuild {
++		xremove(pathf("%s/go_bootstrap", tooldir))
++	}
+ 
+ 	// Print trailing banner unless instructed otherwise.
+ 	if !noBanner {
diff --git a/poky/meta/recipes-devtools/go/go-1.11/0007-cmd-go-make-GOROOT-precious-by-default.patch b/poky/meta/recipes-devtools/go/go-1.11/0007-cmd-go-make-GOROOT-precious-by-default.patch
new file mode 100644
index 0000000..f317e48
--- /dev/null
+++ b/poky/meta/recipes-devtools/go/go-1.11/0007-cmd-go-make-GOROOT-precious-by-default.patch
@@ -0,0 +1,106 @@
+From 7cc60b3887be2d5674b9f5d422d022976cf205e5 Mon Sep 17 00:00:00 2001
+From: Matt Madison <matt@madison.systems>
+Date: Fri, 2 Mar 2018 06:00:20 -0800
+Subject: [PATCH] cmd/go: make GOROOT precious by default
+
+The go build tool normally rebuilds whatever it detects is
+stale.  This can be a problem when GOROOT is intended to
+be read-only and the go runtime has been built as a shared
+library, since we don't want every application to be rebuilding
+the shared runtime - particularly in cross-build/packaging
+setups, since that would lead to 'abi mismatch' runtime errors.
+
+This patch prevents the install and linkshared actions from
+installing to GOROOT unless overridden with the GOROOT_OVERRIDE
+environment variable.
+
+Upstream-Status: Inappropriate [OE specific]
+
+Signed-off-by: Matt Madison <matt@madison.systems>
+
+---
+ src/cmd/go/internal/work/action.go |  3 +++
+ src/cmd/go/internal/work/build.go  |  5 +++++
+ src/cmd/go/internal/work/exec.go   | 25 +++++++++++++++++++++++++
+ 3 files changed, 33 insertions(+)
+
+Index: go/src/cmd/go/internal/work/action.go
+===================================================================
+--- go.orig/src/cmd/go/internal/work/action.go
++++ go/src/cmd/go/internal/work/action.go
+@@ -600,6 +600,9 @@ func (b *Builder) addTransitiveLinkDeps(
+ 			if p1 == nil || p1.Shlib == "" || haveShlib[filepath.Base(p1.Shlib)] {
+ 				continue
+ 			}
++			if goRootPrecious && (p1.Standard || p1.Goroot) {
++				continue
++			}
+ 			haveShlib[filepath.Base(p1.Shlib)] = true
+ 			// TODO(rsc): The use of ModeInstall here is suspect, but if we only do ModeBuild,
+ 			// we'll end up building an overall library or executable that depends at runtime
+Index: go/src/cmd/go/internal/work/build.go
+===================================================================
+--- go.orig/src/cmd/go/internal/work/build.go
++++ go/src/cmd/go/internal/work/build.go
+@@ -147,6 +147,7 @@ See also: go install, go get, go clean.
+ }
+ 
+ const concurrentGCBackendCompilationEnabledByDefault = true
++var goRootPrecious bool = true
+ 
+ func init() {
+ 	// break init cycle
+@@ -160,6 +161,10 @@ func init() {
+ 
+ 	AddBuildFlags(CmdBuild)
+ 	AddBuildFlags(CmdInstall)
++
++	if x := os.Getenv("GOROOT_OVERRIDE"); x != "" {
++		goRootPrecious = false
++	}
+ }
+ 
+ // Note that flags consulted by other parts of the code
+Index: go/src/cmd/go/internal/work/exec.go
+===================================================================
+--- go.orig/src/cmd/go/internal/work/exec.go
++++ go/src/cmd/go/internal/work/exec.go
+@@ -440,6 +440,23 @@ func (b *Builder) build(a *Action) (err
+ 		return fmt.Errorf("module requires Go %s", p.Module.GoVersion)
+ 	}
+ 
++	if goRootPrecious && (a.Package.Standard || a.Package.Goroot) {
++		_, err := os.Stat(a.Package.Target)
++		if err == nil {
++			a.built = a.Package.Target
++			a.Target = a.Package.Target
++			a.buildID = b.fileHash(a.Package.Target)
++			a.Package.Stale = false
++			a.Package.StaleReason = "GOROOT-resident package"
++			return nil
++		}
++		a.Package.Stale = true
++		a.Package.StaleReason = "missing or invalid GOROOT-resident package"
++		if b.IsCmdList {
++			return nil
++		}
++	}
++
+ 	if err := b.Mkdir(a.Objdir); err != nil {
+ 		return err
+ 	}
+@@ -1435,6 +1452,14 @@ func BuildInstallFunc(b *Builder, a *Act
+ 		return nil
+ 	}
+ 
++	if goRootPrecious && a.Package != nil {
++		p := a.Package
++		if p.Standard || p.Goroot {
++			err := fmt.Errorf("attempting to install package %s into read-only GOROOT", p.ImportPath)
++			return err
++		}
++	}
++
+ 	if err := b.Mkdir(a.Objdir); err != nil {
+ 		return err
+ 	}
diff --git a/poky/meta/recipes-devtools/go/go-1.11/0009-ld-replace-glibc-dynamic-linker-with-musl.patch b/poky/meta/recipes-devtools/go/go-1.11/0009-ld-replace-glibc-dynamic-linker-with-musl.patch
new file mode 100644
index 0000000..fd67375
--- /dev/null
+++ b/poky/meta/recipes-devtools/go/go-1.11/0009-ld-replace-glibc-dynamic-linker-with-musl.patch
@@ -0,0 +1,128 @@
+From 35ea4be34e94912b00837e0f7c7385f2e98fe769 Mon Sep 17 00:00:00 2001
+From: Matt Madison <matt@madison.systems>
+Date: Sun, 18 Feb 2018 08:24:05 -0800
+Subject: [PATCH] ld: replace glibc dynamic linker with musl
+
+Rework of patch by Khem Raj <raj.khem@gmail.com>
+for go 1.10.  Should be applied conditionally on
+musl being the system C library.
+
+Upstream-Status: Inappropriate [Real fix should be portable across libcs]
+
+Signed-off-by: Matt Madison <matt@madison.systems>
+
+---
+ src/cmd/link/internal/amd64/obj.go  | 2 +-
+ src/cmd/link/internal/arm/obj.go    | 2 +-
+ src/cmd/link/internal/arm64/obj.go  | 2 +-
+ src/cmd/link/internal/mips/obj.go   | 2 +-
+ src/cmd/link/internal/mips64/obj.go | 2 +-
+ src/cmd/link/internal/ppc64/obj.go  | 2 +-
+ src/cmd/link/internal/s390x/obj.go  | 2 +-
+ src/cmd/link/internal/x86/obj.go    | 2 +-
+ 8 files changed, 8 insertions(+), 8 deletions(-)
+
+diff --git a/src/cmd/link/internal/amd64/obj.go b/src/cmd/link/internal/amd64/obj.go
+index 87e8091..f522a63 100644
+--- a/src/cmd/link/internal/amd64/obj.go
++++ b/src/cmd/link/internal/amd64/obj.go
+@@ -62,7 +62,7 @@ func Init() (*sys.Arch, ld.Arch) {
+ 		PEreloc1:         pereloc1,
+ 		TLSIEtoLE:        tlsIEtoLE,
+ 
+-		Linuxdynld:     "/lib64/ld-linux-x86-64.so.2",
++		Linuxdynld:     "/lib64/ld-musl-x86-64.so.1",
+ 		Freebsddynld:   "/libexec/ld-elf.so.1",
+ 		Openbsddynld:   "/usr/libexec/ld.so",
+ 		Netbsddynld:    "/libexec/ld.elf_so",
+diff --git a/src/cmd/link/internal/arm/obj.go b/src/cmd/link/internal/arm/obj.go
+index 788be68..1d2b90e 100644
+--- a/src/cmd/link/internal/arm/obj.go
++++ b/src/cmd/link/internal/arm/obj.go
+@@ -58,7 +58,7 @@ func Init() (*sys.Arch, ld.Arch) {
+ 		Gentext:          gentext,
+ 		Machoreloc1:      machoreloc1,
+ 
+-		Linuxdynld:     "/lib/ld-linux.so.3", // 2 for OABI, 3 for EABI
++		Linuxdynld:     "/lib/ld-musl-armhf.so.1",
+ 		Freebsddynld:   "/usr/libexec/ld-elf.so.1",
+ 		Openbsddynld:   "/usr/libexec/ld.so",
+ 		Netbsddynld:    "/libexec/ld.elf_so",
+diff --git a/src/cmd/link/internal/arm64/obj.go b/src/cmd/link/internal/arm64/obj.go
+index 405d22d..b115659 100644
+--- a/src/cmd/link/internal/arm64/obj.go
++++ b/src/cmd/link/internal/arm64/obj.go
+@@ -57,7 +57,7 @@ func Init() (*sys.Arch, ld.Arch) {
+ 		Gentext:          gentext,
+ 		Machoreloc1:      machoreloc1,
+ 
+-		Linuxdynld: "/lib/ld-linux-aarch64.so.1",
++		Linuxdynld: "/lib/ld-musl-aarch64.so.1",
+ 
+ 		Freebsddynld:   "XXX",
+ 		Openbsddynld:   "XXX",
+diff --git a/src/cmd/link/internal/mips/obj.go b/src/cmd/link/internal/mips/obj.go
+index c5d3451..fd85e63 100644
+--- a/src/cmd/link/internal/mips/obj.go
++++ b/src/cmd/link/internal/mips/obj.go
+@@ -60,7 +60,7 @@ func Init() (*sys.Arch, ld.Arch) {
+ 		Gentext:          gentext,
+ 		Machoreloc1:      machoreloc1,
+ 
+-		Linuxdynld: "/lib/ld.so.1",
++		Linuxdynld: "/lib/ld-musl-mipsle.so.1",
+ 
+ 		Freebsddynld:   "XXX",
+ 		Openbsddynld:   "XXX",
+diff --git a/src/cmd/link/internal/mips64/obj.go b/src/cmd/link/internal/mips64/obj.go
+index 83974e5..097224f 100644
+--- a/src/cmd/link/internal/mips64/obj.go
++++ b/src/cmd/link/internal/mips64/obj.go
+@@ -59,7 +59,7 @@ func Init() (*sys.Arch, ld.Arch) {
+ 		Gentext:          gentext,
+ 		Machoreloc1:      machoreloc1,
+ 
+-		Linuxdynld:     "/lib64/ld64.so.1",
++		Linuxdynld:     "/lib64/ld-musl-mips64le.so.1",
+ 		Freebsddynld:   "XXX",
+ 		Openbsddynld:   "XXX",
+ 		Netbsddynld:    "XXX",
+diff --git a/src/cmd/link/internal/ppc64/obj.go b/src/cmd/link/internal/ppc64/obj.go
+index 273d9b4..a503abe 100644
+--- a/src/cmd/link/internal/ppc64/obj.go
++++ b/src/cmd/link/internal/ppc64/obj.go
+@@ -62,7 +62,7 @@ func Init() (*sys.Arch, ld.Arch) {
+ 		Machoreloc1:      machoreloc1,
+ 
+ 		// TODO(austin): ABI v1 uses /usr/lib/ld.so.1,
+-		Linuxdynld: "/lib64/ld64.so.1",
++		Linuxdynld: "/lib64/ld-musl-powerpc64le.so.1",
+ 
+ 		Freebsddynld:   "XXX",
+ 		Openbsddynld:   "XXX",
+diff --git a/src/cmd/link/internal/s390x/obj.go b/src/cmd/link/internal/s390x/obj.go
+index 9ac7eb8..3825ff7 100644
+--- a/src/cmd/link/internal/s390x/obj.go
++++ b/src/cmd/link/internal/s390x/obj.go
+@@ -57,7 +57,7 @@ func Init() (*sys.Arch, ld.Arch) {
+ 		Gentext:          gentext,
+ 		Machoreloc1:      machoreloc1,
+ 
+-		Linuxdynld: "/lib64/ld64.so.1",
++		Linuxdynld: "/lib64/ld-musl-s390x.so.1",
+ 
+ 		// not relevant for s390x
+ 		Freebsddynld:   "XXX",
+diff --git a/src/cmd/link/internal/x86/obj.go b/src/cmd/link/internal/x86/obj.go
+index 6a744dc..d81f392 100644
+--- a/src/cmd/link/internal/x86/obj.go
++++ b/src/cmd/link/internal/x86/obj.go
+@@ -58,7 +58,7 @@ func Init() (*sys.Arch, ld.Arch) {
+ 		Machoreloc1:      machoreloc1,
+ 		PEreloc1:         pereloc1,
+ 
+-		Linuxdynld:   "/lib/ld-linux.so.2",
++		Linuxdynld:   "/lib/ld-musl-i386.so.1",
+ 		Freebsddynld: "/usr/libexec/ld-elf.so.1",
+ 		Openbsddynld: "/usr/libexec/ld.so",
+ 		Netbsddynld:  "/usr/libexec/ld.elf_so",
diff --git a/poky/meta/recipes-devtools/go/go-cross-canadian_1.10.bb b/poky/meta/recipes-devtools/go/go-cross-canadian_1.11.bb
similarity index 100%
rename from poky/meta/recipes-devtools/go/go-cross-canadian_1.10.bb
rename to poky/meta/recipes-devtools/go/go-cross-canadian_1.11.bb
diff --git a/poky/meta/recipes-devtools/go/go-cross.inc b/poky/meta/recipes-devtools/go/go-cross.inc
index 44f230b..6d9aa5c 100644
--- a/poky/meta/recipes-devtools/go/go-cross.inc
+++ b/poky/meta/recipes-devtools/go/go-cross.inc
@@ -1,9 +1,9 @@
 inherit cross
 
-PROVIDES = "virtual/${TARGET_PREFIX}go"
+PROVIDES = "virtual/${TUNE_PKGARCH}-go"
 DEPENDS = "go-native"
 
-PN = "go-cross-${TARGET_ARCH}"
+PN = "go-cross-${TUNE_PKGARCH}"
 
 export GOHOSTOS = "${BUILD_GOOS}"
 export GOHOSTARCH = "${BUILD_GOARCH}"
diff --git a/poky/meta/recipes-devtools/go/go-cross_1.10.bb b/poky/meta/recipes-devtools/go/go-cross_1.11.bb
similarity index 100%
rename from poky/meta/recipes-devtools/go/go-cross_1.10.bb
rename to poky/meta/recipes-devtools/go/go-cross_1.11.bb
diff --git a/poky/meta/recipes-devtools/go/go-crosssdk_1.10.bb b/poky/meta/recipes-devtools/go/go-crosssdk_1.11.bb
similarity index 100%
rename from poky/meta/recipes-devtools/go/go-crosssdk_1.10.bb
rename to poky/meta/recipes-devtools/go/go-crosssdk_1.11.bb
diff --git a/poky/meta/recipes-devtools/go/go-dep_0.4.1.bb b/poky/meta/recipes-devtools/go/go-dep_0.4.1.bb
deleted file mode 100644
index d82e637..0000000
--- a/poky/meta/recipes-devtools/go/go-dep_0.4.1.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-SUMMARY = "Dependency management tool for Golang"
-HOMEPAGE = "https://github.com/golang/dep"
-LICENSE = "BSD-3-Clause"
-LIC_FILES_CHKSUM = "file://src/${GO_IMPORT}/LICENSE;md5=1bad315647751fab0007812f70d42c0d"
-
-GO_IMPORT = "github.com/golang/dep"
-SRC_URI = "git://${GO_IMPORT} \
-           file://0001-Add-support-for-mips-mips64.patch;patchdir=src/github.com/golang/dep \
-          "
-
-# Points to 0.4.1 tag
-SRCREV = "37d9ea0ac16f0e0a05afc3b60e1ac8c364b6c329"
-
-inherit go
-
-GO_INSTALL = "${GO_IMPORT}/cmd/dep"
-
-RDEPENDS_${PN}-dev += "bash"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-devtools/go/go-dep_0.5.0.bb b/poky/meta/recipes-devtools/go/go-dep_0.5.0.bb
new file mode 100644
index 0000000..cfc2186
--- /dev/null
+++ b/poky/meta/recipes-devtools/go/go-dep_0.5.0.bb
@@ -0,0 +1,35 @@
+SUMMARY = "Dependency management tool for Golang"
+HOMEPAGE = "https://github.com/golang/dep"
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://src/${GO_IMPORT}/LICENSE;md5=1bad315647751fab0007812f70d42c0d"
+
+GO_IMPORT = "github.com/golang/dep"
+SRC_URI = "git://${GO_IMPORT} \
+           file://0001-Add-support-for-mips-mips64.patch;patchdir=src/github.com/golang/dep \
+          "
+
+# Points to 0.5.0 tag
+SRCREV = "224a564abe296670b692fe08bb63a3e4c4ad7978"
+
+inherit go
+
+GO_INSTALL = "${GO_IMPORT}/cmd/dep"
+
+RDEPENDS_${PN}-dev += "bash"
+
+BBCLASSEXTEND = "native nativesdk"
+
+# for x86 ends with textrel in ${PN}
+# http://errors.yoctoproject.org/Errors/Details/185630/
+# ERROR: QA Issue: ELF binary '/work/i586-oe-linux/go-dep/0.4.1-r0/packages-split/go-dep/usr/bin/dep' has relocations in .text [textrel]
+INSANE_SKIP_${PN} += "textrel"
+
+# for aarch64 ends with textrel in ${PN}-ptest
+# http://errors.yoctoproject.org/Errors/Details/185632/
+# ERROR: QA Issue: ELF binary '/work/aarch64-oe-linux/go-dep/0.4.1-r0/packages-split/go-dep-ptest/usr/lib/go-dep/ptest/github.com/golang/dep/cmd/dep/dep.test' has relocations in .text [textrel]  
+INSANE_SKIP_${PN}-ptest += "textrel"
+
+# For compiling ptest on mips and mips64, the current go-dep version fails with the go 1.11 toolchain.
+# error message: vet config not found
+PTEST_ENABLED_mips = "0"
+PTEST_ENABLED_mips64 = "0"
diff --git a/poky/meta/recipes-devtools/go/go-native.inc b/poky/meta/recipes-devtools/go/go-native.inc
index b76fb08..2077087 100644
--- a/poky/meta/recipes-devtools/go/go-native.inc
+++ b/poky/meta/recipes-devtools/go/go-native.inc
@@ -1,7 +1,3 @@
-# Use immediate assingment here to get the original (/usr/lib)
-# instead of the one rewritten by native.bbclass.
-nonstaging_libdir := "${libdir}"
-
 inherit native
 
 SRC_URI_append = " https://dl.google.com/go/go1.4-bootstrap-20171003.tar.gz;name=bootstrap;subdir=go1.4"
@@ -20,7 +16,7 @@
 }
 
 do_compile() {
-	export GOROOT_FINAL="${nonstaging_libdir}/go"
+	export GOROOT_FINAL="${libdir_native}/go"
 	export GOROOT_BOOTSTRAP="${WORKDIR}/go1.4/go"
 
 	cd src
diff --git a/poky/meta/recipes-devtools/go/go-native_1.10.bb b/poky/meta/recipes-devtools/go/go-native_1.11.bb
similarity index 100%
rename from poky/meta/recipes-devtools/go/go-native_1.10.bb
rename to poky/meta/recipes-devtools/go/go-native_1.11.bb
diff --git a/poky/meta/recipes-devtools/go/go-runtime.inc b/poky/meta/recipes-devtools/go/go-runtime.inc
index 0041e8a..c219aa3 100644
--- a/poky/meta/recipes-devtools/go/go-runtime.inc
+++ b/poky/meta/recipes-devtools/go/go-runtime.inc
@@ -1,4 +1,4 @@
-DEPENDS = "virtual/${TARGET_PREFIX}go go-native"
+DEPENDS = "virtual/${TUNE_PKGARCH}-go go-native"
 DEPENDS_class-nativesdk = "virtual/${TARGET_PREFIX}go-crosssdk"
 PROVIDES = "virtual/${TARGET_PREFIX}go-runtime"
 
diff --git a/poky/meta/recipes-devtools/go/go-runtime_1.10.bb b/poky/meta/recipes-devtools/go/go-runtime_1.11.bb
similarity index 100%
rename from poky/meta/recipes-devtools/go/go-runtime_1.10.bb
rename to poky/meta/recipes-devtools/go/go-runtime_1.11.bb
diff --git a/poky/meta/recipes-devtools/go/go-target.inc b/poky/meta/recipes-devtools/go/go-target.inc
index 29a1344..c229ab2 100644
--- a/poky/meta/recipes-devtools/go/go-target.inc
+++ b/poky/meta/recipes-devtools/go/go-target.inc
@@ -1,4 +1,4 @@
-DEPENDS = "virtual/${TARGET_PREFIX}go go-native"
+DEPENDS = "virtual/${TUNE_PKGARCH}-go go-native"
 DEPENDS_class-nativesdk = "virtual/${TARGET_PREFIX}go-crosssdk go-native"
 
 export GOHOSTOS = "${BUILD_GOOS}"
diff --git a/poky/meta/recipes-devtools/go/go_1.10.bb b/poky/meta/recipes-devtools/go/go_1.11.bb
similarity index 100%
rename from poky/meta/recipes-devtools/go/go_1.10.bb
rename to poky/meta/recipes-devtools/go/go_1.11.bb
diff --git a/poky/meta/recipes-devtools/go/go_1.9.bb b/poky/meta/recipes-devtools/go/go_1.9.bb
index ec5a314..7da7897 100644
--- a/poky/meta/recipes-devtools/go/go_1.9.bb
+++ b/poky/meta/recipes-devtools/go/go_1.9.bb
@@ -15,3 +15,10 @@
 	./make.bash
 	cd ${B}
 }
+
+# for aarch64 ends with textrel in ${PN}
+# http://errors.yoctoproject.org/Errors/Details/185634/
+# ERROR: QA Issue: ELF binary '/work/aarch64-oe-linux/go/1.9.7-r0/packages-split/go/usr/lib/go/bin/go' has relocations in .text
+# ELF binary '/work/aarch64-oe-linux/go/1.9.7-r0/packages-split/go/usr/lib/go/pkg/tool/linux_arm64/trace' has relocations in .text
+# ELF binary '/work/aarch64-oe-linux/go/1.9.7-r0/packages-split/go/usr/lib/go/pkg/tool/linux_arm64/pprof' has relocations in .text [textrel]
+INSANE_SKIP_${PN} += "textrel"
diff --git a/poky/meta/recipes-devtools/help2man/help2man-native_1.47.5.bb b/poky/meta/recipes-devtools/help2man/help2man-native_1.47.5.bb
deleted file mode 100644
index 2dd6d38..0000000
--- a/poky/meta/recipes-devtools/help2man/help2man-native_1.47.5.bb
+++ /dev/null
@@ -1,25 +0,0 @@
-SUMMARY = "Program for creating simple man pages"
-SECTION = "devel"
-LICENSE = "GPLv3"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
-DEPENDS = "autoconf-native automake-native"
-
-SRC_URI = "${GNU_MIRROR}/${BPN}/${BPN}-${PV}.tar.xz"
-
-SRC_URI[md5sum] = "1c886063c9e0ab463906de804596aa2f"
-SRC_URI[sha256sum] = "7ca60b2519fdbe97f463fe2df66a6188d18b514bfd44127d985f0234ee2461b1"
-
-inherit autotools native
-
-EXTRA_OECONF = "--disable-nls"
-
-# We don't want to reconfigure things as it would require 'perlnative' to be
-# used.
-do_configure() {
-	oe_runconf
-}
-
-do_install_append () {
-	# Make sure we use /usr/bin/env perl
-	sed -i -e "1s:#!.*:#! /usr/bin/env perl:" ${D}${bindir}/help2man
-}
diff --git a/poky/meta/recipes-devtools/help2man/help2man-native_1.47.6.bb b/poky/meta/recipes-devtools/help2man/help2man-native_1.47.6.bb
new file mode 100644
index 0000000..794d308
--- /dev/null
+++ b/poky/meta/recipes-devtools/help2man/help2man-native_1.47.6.bb
@@ -0,0 +1,25 @@
+SUMMARY = "Program for creating simple man pages"
+SECTION = "devel"
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
+DEPENDS = "autoconf-native automake-native"
+
+SRC_URI = "${GNU_MIRROR}/${BPN}/${BPN}-${PV}.tar.xz"
+
+SRC_URI[md5sum] = "7424901e6eca8af372d2ad62be5cf659"
+SRC_URI[sha256sum] = "d91b0295b72a638e4a564f643e4e6d1928779131f628c00f356c13bf336de46f"
+
+inherit autotools native
+
+EXTRA_OECONF = "--disable-nls"
+
+# We don't want to reconfigure things as it would require 'perlnative' to be
+# used.
+do_configure() {
+	oe_runconf
+}
+
+do_install_append () {
+	# Make sure we use /usr/bin/env perl
+	sed -i -e "1s:#!.*:#! /usr/bin/env perl:" ${D}${bindir}/help2man
+}
diff --git a/poky/meta/recipes-devtools/i2c-tools/i2c-tools_4.0.bb b/poky/meta/recipes-devtools/i2c-tools/i2c-tools_4.0.bb
index 01ac47f..fe3247d 100644
--- a/poky/meta/recipes-devtools/i2c-tools/i2c-tools_4.0.bb
+++ b/poky/meta/recipes-devtools/i2c-tools/i2c-tools_4.0.bb
@@ -14,6 +14,8 @@
 SRC_URI[md5sum] = "d92a288d70f306d3895e3a7e9c14c9aa"
 SRC_URI[sha256sum] = "5b60daf6f011de0acb61de57dba62f2054bb39f19961d67e0c91610f071ca403"
 
+inherit update-alternatives
+
 EXTRA_OEMAKE = "bindir=${bindir} sbindir=${sbindir} \
                 incdir=${includedir} libdir=${libdir} \
                 mandir=${mandir} \
@@ -34,3 +36,10 @@
                        perl-module-constant perl-module-file-basename \
                        perl-module-fcntl perl-module-strict perl-module-vars \
                       "
+
+ALTERNATIVE_PRIORITY = "100"
+ALTERNATIVE_${PN} = "i2cdetect i2cdump i2cget i2cset"
+ALTERNATIVE_LINK_NAME[i2cdetect] = "${sbindir}/i2cdetect"
+ALTERNATIVE_LINK_NAME[i2cdump] = "${sbindir}/i2cdump"
+ALTERNATIVE_LINK_NAME[i2cget] = "${sbindir}/i2cget"
+ALTERNATIVE_LINK_NAME[i2cset] = "${sbindir}/i2cset"
diff --git a/poky/meta/recipes-devtools/icecc-toolchain/icecc-toolchain/icecc-setup.sh b/poky/meta/recipes-devtools/icecc-toolchain/icecc-toolchain/icecc-setup.sh
index 0480826..25250b7 100644
--- a/poky/meta/recipes-devtools/icecc-toolchain/icecc-toolchain/icecc-setup.sh
+++ b/poky/meta/recipes-devtools/icecc-toolchain/icecc-toolchain/icecc-setup.sh
@@ -20,11 +20,6 @@
 # SOFTWARE.
 #
 
-# Setup environment
-for env_setup_script in `ls $1/environment-setup-*`; do
-	. $env_setup_script
-done
-
 # ICECC_PATH will have been found icecc-env.sh
 if [ -z "$ICECC_PATH" ]; then
     exit 0
diff --git a/poky/meta/recipes-devtools/icon-naming-utils/icon-naming-utils_0.8.90.bb b/poky/meta/recipes-devtools/icon-naming-utils/icon-naming-utils_0.8.90.bb
deleted file mode 100644
index 6b356b0..0000000
--- a/poky/meta/recipes-devtools/icon-naming-utils/icon-naming-utils_0.8.90.bb
+++ /dev/null
@@ -1,30 +0,0 @@
-SUMMARY = "Enables backwards compatibility with current desktop icon themes"
-DESCRIPTION = "A Perl script used for maintaining backwards \
-compatibility with current desktop icon themes, while migrating to the \
-names specified in the Icon Naming Specification. The Icon Naming \
-Utilities map the icon names used by the GNOME and KDE desktops to the \
-icon names proposed in the Icon Naming Specification, and generate the \
-icon files appropriate to the desktop environment you use. The Icon \
-Naming Specification provides a standard list of common icon contexts \
-and names that can be used to make icon themes work in a desktop \
-environment or application that implements the naming specification. "
-LICENSE = "GPLv2"
-DEPENDS = "libxml-simple-perl-native"
-PR = "r5"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
-
-SRC_URI = "http://tango.freedesktop.org/releases/icon-naming-utils-${PV}.tar.gz"
-SRC_URI[md5sum] = "2c5c7a418e5eb3268f65e21993277fba"
-SRC_URI[sha256sum] = "044ab2199ed8c6a55ce36fd4fcd8b8021a5e21f5bab028c0a7cdcf52a5902e1c"
-
-inherit autotools allarch perlnative
-
-do_configure_append() {
-	# Make sure we use our nativeperl wrapper.
-	sed -i -e "1s:#!.*:#!/usr/bin/env nativeperl:" ${S}/icon-name-mapping.pl.in
-}
-
-FILES_${PN} += "${datadir}/dtds"
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-devtools/json-c/json-c_0.13.1.bb b/poky/meta/recipes-devtools/json-c/json-c_0.13.1.bb
new file mode 100644
index 0000000..5b10e68
--- /dev/null
+++ b/poky/meta/recipes-devtools/json-c/json-c_0.13.1.bb
@@ -0,0 +1,30 @@
+SUMMARY = "C bindings for apps which will manipulate JSON data"
+DESCRIPTION = "JSON-C implements a reference counting object model that allows you to easily construct JSON objects in C."
+HOMEPAGE = "https://github.com/json-c/json-c/wiki"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=de54b60fbbc35123ba193fea8ee216f2"
+
+SRC_URI = "https://s3.amazonaws.com/json-c_releases/releases/${BP}.tar.gz"
+SRC_URI[md5sum] = "04969ad59cc37bddd83741a08b98f350"
+SRC_URI[sha256sum] = "b87e608d4d3f7bfdd36ef78d56d53c74e66ab278d318b71e6002a369d36f4873"
+
+UPSTREAM_CHECK_REGEX = "json-c-(?P<pver>\d+(\.\d+)+).tar"
+# json-c releases page is fetching the list of releases in some weird XML format
+# from https://s3.amazonaws.com/json-c_releases and processes it with javascript :-/
+#UPSTREAM_CHECK_URI = "https://s3.amazonaws.com/json-c_releases/releases/index.html"
+RECIPE_UPSTREAM_VERSION = "0.13.1"
+RECIPE_UPSTREAM_DATE = "Mar 04, 2018"
+CHECK_DATE = "May 02, 2018"
+
+RPROVIDES_${PN} = "libjson"
+
+inherit autotools
+
+EXTRA_OECONF = "--enable-rdrand"
+
+do_configure_prepend() {
+    # Clean up autoconf cruft that should not be in the tarball
+    rm -f ${S}/config.status
+}
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-devtools/json-c/json-c_0.13.bb b/poky/meta/recipes-devtools/json-c/json-c_0.13.bb
deleted file mode 100644
index 06319de..0000000
--- a/poky/meta/recipes-devtools/json-c/json-c_0.13.bb
+++ /dev/null
@@ -1,31 +0,0 @@
-SUMMARY = "C bindings for apps which will manipulate JSON data"
-DESCRIPTION = "JSON-C implements a reference counting object model that allows you to easily construct JSON objects in C."
-HOMEPAGE = "https://github.com/json-c/json-c/wiki"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=de54b60fbbc35123ba193fea8ee216f2"
-
-SRC_URI = "https://s3.amazonaws.com/json-c_releases/releases/${BP}.tar.gz \
-           "
-SRC_URI[md5sum] = "11fc5d90c77375e5fc8401e8b9efbf21"
-SRC_URI[sha256sum] = "0316780be9ad16c42d7c26b015a784fd5df4b0909fef0aba51cfb13e492ac24d"
-
-UPSTREAM_CHECK_REGEX = "json-c-(?P<pver>\d+(\.\d+)+).tar"
-# json-c releases page is fetching the list of releases in some weird XML format
-# from https://s3.amazonaws.com/json-c_releases and processes it with javascript :-/
-#UPSTREAM_CHECK_URI = "https://s3.amazonaws.com/json-c_releases/releases/index.html"
-RECIPE_UPSTREAM_VERSION = "0.13"
-RECIPE_UPSTREAM_DATE = "Dec 07, 2017"
-CHECK_DATE = "Jan 31, 2018"
-
-RPROVIDES_${PN} = "libjson"
-
-inherit autotools
-
-EXTRA_OECONF = "--enable-rdrand"
-
-do_configure_prepend() {
-    # Clean up autoconf cruft that should not be in the tarball
-    rm -f ${S}/config.status
-}
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-devtools/libtool/libtool-cross_2.4.6.bb b/poky/meta/recipes-devtools/libtool/libtool-cross_2.4.6.bb
index b268310..522bf3a 100644
--- a/poky/meta/recipes-devtools/libtool/libtool-cross_2.4.6.bb
+++ b/poky/meta/recipes-devtools/libtool/libtool-cross_2.4.6.bb
@@ -13,11 +13,19 @@
 	rm -f ${STAGING_DATADIR}/aclocal/lt*.m4
 }
 
+#
+# ccache may or may not be INHERITED, we remove references to it so the sstate
+# artefact works on a machine where its not present. libtool-cross isn't used
+# heavily so any performance issue is minor.
+# Find references to LTCC="ccache xxx-gcc" and CC="ccache xxx-gcc"
+#
 do_install () {
 	install -d ${D}${bindir_crossscripts}/
 	install -m 0755 ${HOST_SYS}-libtool ${D}${bindir_crossscripts}/${HOST_SYS}-libtool
 	sed -e 's@^\(predep_objects="\).*@\1"@' \
 	    -e 's@^\(postdep_objects="\).*@\1"@' \
+	    -e 's@^CC="ccache.@CC="@' \
+	    -e 's@^LTCC="ccache.@LTCC="@' \
 	    -i ${D}${bindir_crossscripts}/${HOST_SYS}-libtool
 	sed -i '/^archive_cmds=/s/\-nostdlib//g' ${D}${bindir_crossscripts}/${HOST_SYS}-libtool
 	sed -i '/^archive_expsym_cmds=/s/\-nostdlib//g' ${D}${bindir_crossscripts}/${HOST_SYS}-libtool
diff --git a/poky/meta/recipes-devtools/libtool/libtool/multilib.patch b/poky/meta/recipes-devtools/libtool/libtool/multilib.patch
new file mode 100644
index 0000000..018f066
--- /dev/null
+++ b/poky/meta/recipes-devtools/libtool/libtool/multilib.patch
@@ -0,0 +1,23 @@
+Without this patch /usr/bin/libtoolize is different for each multilib
+since their host-triplets are different, despite there being no difference in
+the functionality of libtoolize itself.
+
+Ugly, but just patch this out. This fixes issues where libtool and
+libXX-libtool couldn't be installed into the same system.
+
+Upstream-Status: Inappropriate
+RP 2018/7/30
+
+Index: libtool-2.4.6/libtoolize.in
+===================================================================
+--- libtool-2.4.6.orig/libtoolize.in
++++ libtool-2.4.6/libtoolize.in
+@@ -113,7 +113,7 @@ You must 'cd' to the top directory of yo
+ When reporting a bug, please describe a test case to reproduce it and
+ include the following information:
+ 
+-       host-triplet:   @host_triplet@
++       host-triplet    <redacted>
+        version:        $progname (GNU @PACKAGE@) @VERSION@
+        automake:       `($AUTOMAKE --version) 2>/dev/null |$SED 1q`
+        autoconf:       `($AUTOCONF --version) 2>/dev/null |$SED 1q`
diff --git a/poky/meta/recipes-devtools/libtool/libtool_2.4.6.bb b/poky/meta/recipes-devtools/libtool/libtool_2.4.6.bb
index b02620b..f5fdd00 100644
--- a/poky/meta/recipes-devtools/libtool/libtool_2.4.6.bb
+++ b/poky/meta/recipes-devtools/libtool/libtool_2.4.6.bb
@@ -1,5 +1,7 @@
 require libtool-${PV}.inc
 
+SRC_URI += "file://multilib.patch"
+
 RDEPENDS_${PN} += "bash"
 
 #
@@ -26,3 +28,7 @@
             -e "s@${HOSTTOOLS_DIR}/@@g" \
             -i ${D}${bindir}/libtool
 }
+
+inherit multilib_script
+
+MULTILIB_SCRIPTS = "${PN}:${bindir}/libtool"
diff --git a/poky/meta/recipes-devtools/llvm/llvm/0001-Disable-generating-a-native-llvm-config.patch b/poky/meta/recipes-devtools/llvm/llvm/0001-Disable-generating-a-native-llvm-config.patch
deleted file mode 100644
index 2809e4c..0000000
--- a/poky/meta/recipes-devtools/llvm/llvm/0001-Disable-generating-a-native-llvm-config.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From 7f7743ce233fcd735ec580c75270413493658aa6 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 19 Apr 2018 18:08:31 -0700
-Subject: [PATCH] Disable generating a native llvm-config
-
-OpenEmbedded already builds this as part of llvm-native
-
-Upstream-Status: Inappropriate [OE-Specific]
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- tools/llvm-config/CMakeLists.txt | 16 ----------------
- 1 file changed, 16 deletions(-)
-
-diff --git a/tools/llvm-config/CMakeLists.txt b/tools/llvm-config/CMakeLists.txt
-index 25f99cec978..c45e9b642a8 100644
---- a/tools/llvm-config/CMakeLists.txt
-+++ b/tools/llvm-config/CMakeLists.txt
-@@ -63,19 +63,3 @@ endif()
- 
- # Add the dependency on the generation step.
- add_file_dependencies(${CMAKE_CURRENT_SOURCE_DIR}/llvm-config.cpp ${BUILDVARIABLES_OBJPATH})
--
--if(CMAKE_CROSSCOMPILING)
--  set(${project}_LLVM_CONFIG_EXE "${LLVM_NATIVE_BUILD}/bin/llvm-config")
--  set(${project}_LLVM_CONFIG_EXE ${${project}_LLVM_CONFIG_EXE} PARENT_SCOPE)
--
--  add_custom_command(OUTPUT "${${project}_LLVM_CONFIG_EXE}"
--    COMMAND ${CMAKE_COMMAND} --build . --target llvm-config --config $<CONFIGURATION>
--    DEPENDS ${LLVM_NATIVE_BUILD}/CMakeCache.txt
--    WORKING_DIRECTORY ${LLVM_NATIVE_BUILD}
--    COMMENT "Building native llvm-config..."
--    USES_TERMINAL)
--  add_custom_target(${project}NativeLLVMConfig DEPENDS ${${project}_LLVM_CONFIG_EXE})
--  add_dependencies(${project}NativeLLVMConfig CONFIGURE_LLVM_NATIVE)
--
--  add_dependencies(llvm-config ${project}NativeLLVMConfig)
--endif(CMAKE_CROSSCOMPILING)
--- 
-2.17.0
-
diff --git a/poky/meta/recipes-devtools/llvm/llvm/0002-llvm-allow-env-override-of-exe-path.patch b/poky/meta/recipes-devtools/llvm/llvm/0002-llvm-allow-env-override-of-exe-path.patch
index 21d2f81..6a92833 100644
--- a/poky/meta/recipes-devtools/llvm/llvm/0002-llvm-allow-env-override-of-exe-path.patch
+++ b/poky/meta/recipes-devtools/llvm/llvm/0002-llvm-allow-env-override-of-exe-path.patch
@@ -1,4 +1,4 @@
-From 2f8ea767afdaa440c6368040630e1b3ea6a0977a Mon Sep 17 00:00:00 2001
+From aeccf16eaccdd80e4d5ecaa51673ce4b2bac1130 Mon Sep 17 00:00:00 2001
 From: Martin Kelly <mkelly@xevo.com>
 Date: Fri, 19 May 2017 00:22:57 -0700
 Subject: [PATCH 2/2] llvm: allow env override of exe path
@@ -8,16 +8,19 @@
 than from the native sysroot. Thus provide an env override for calling
 llvm-config from a target sysroot.
 
+To let it work in multilib environment, we need to provide a knob to supply
+multilib dirname as well
+
+Upstream-Status: Inappropriate [OE-Specific]
+
 Signed-off-by: Martin Kelly <mkelly@xevo.com>
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 ---
-Upstream-Status: Pending
-
- tools/llvm-config/llvm-config.cpp | 7 +++++++
- 1 file changed, 7 insertions(+)
+ tools/llvm-config/llvm-config.cpp | 17 ++++++++++++++++-
+ 1 file changed, 16 insertions(+), 1 deletion(-)
 
 diff --git a/tools/llvm-config/llvm-config.cpp b/tools/llvm-config/llvm-config.cpp
-index 08b096afb05..d8d7742744e 100644
+index 08b096afb05..360cc5abf4e 100644
 --- a/tools/llvm-config/llvm-config.cpp
 +++ b/tools/llvm-config/llvm-config.cpp
 @@ -225,6 +225,13 @@ Typical components:\n\
@@ -34,6 +37,36 @@
    // This just needs to be some symbol in the binary; C++ doesn't
    // allow taking the address of ::main however.
    void *P = (void *)(intptr_t)GetExecutablePath;
+@@ -306,12 +313,20 @@ int main(int argc, char **argv) {
+   std::string ActivePrefix, ActiveBinDir, ActiveIncludeDir, ActiveLibDir,
+               ActiveCMakeDir;
+   std::string ActiveIncludeOption;
++  // Hack for Yocto: we need to override the multilib path when we are using
++  // llvm-config from within a target sysroot.
++  std::string Multilibdir = std::getenv("YOCTO_ALTERNATE_MULTILIB_NAME");
++  if (Multilibdir.empty()) {
++    Multilibdir = "/lib" LLVM_LIBDIR_SUFFIX;
++  }
++
+   if (IsInDevelopmentTree) {
+     ActiveIncludeDir = std::string(LLVM_SRC_ROOT) + "/include";
+     ActivePrefix = CurrentExecPrefix;
+ 
+     // CMake organizes the products differently than a normal prefix style
+     // layout.
++
+     switch (DevelopmentTreeLayout) {
+     case CMakeStyle:
+       ActiveBinDir = ActiveObjRoot + "/bin";
+@@ -336,7 +351,7 @@ int main(int argc, char **argv) {
+     SmallString<256> path(StringRef(LLVM_TOOLS_INSTALL_DIR));
+     sys::fs::make_absolute(ActivePrefix, path);
+     ActiveBinDir = path.str();
+-    ActiveLibDir = ActivePrefix + "/lib" + LLVM_LIBDIR_SUFFIX;
++    ActiveLibDir = ActivePrefix + Multilibdir;
+     ActiveCMakeDir = ActiveLibDir + "/cmake/llvm";
+     ActiveIncludeOption = "-I" + ActiveIncludeDir;
+   }
 -- 
-2.16.1
+2.18.0
 
diff --git a/poky/meta/recipes-devtools/llvm/llvm_git.bb b/poky/meta/recipes-devtools/llvm/llvm_git.bb
index cb3bba6..7278763 100644
--- a/poky/meta/recipes-devtools/llvm/llvm_git.bb
+++ b/poky/meta/recipes-devtools/llvm/llvm_git.bb
@@ -19,14 +19,13 @@
 LLVM_RELEASE = "${PV}"
 LLVM_DIR = "llvm${LLVM_RELEASE}"
 
-SRCREV = "089d4c0c490687db6c75f1d074e99c4d42936a50"
+SRCREV = "5136df4d089a086b70d452160ad5451861269498"
 PV = "6.0"
 BRANCH = "release_60"
-PATCH_VERSION = "0"
+PATCH_VERSION = "1"
 SRC_URI = "git://github.com/llvm-mirror/llvm.git;branch=${BRANCH};protocol=http \
            file://0001-llvm-TargetLibraryInfo-Undefine-libc-functions-if-th.patch \
            file://0002-llvm-allow-env-override-of-exe-path.patch \
-           file://0001-Disable-generating-a-native-llvm-config.patch \
           "
 UPSTREAM_CHECK_COMMITS = "1"
 S = "${WORKDIR}/git"
@@ -45,14 +44,13 @@
     else:
         raise bb.parse.SkipRecipe("Cannot map '%s' to a supported LLVM architecture" % a)
 
-def get_llvm_target_arch(bb, d):
-    return get_llvm_arch(bb, d, 'TARGET_ARCH')
+def get_llvm_host_arch(bb, d):
+    return get_llvm_arch(bb, d, 'HOST_ARCH')
+
 #
 # Default to build all OE-Core supported target arches (user overridable).
 #
-LLVM_TARGETS ?= "${@get_llvm_target_arch(bb, d)}"
-LLVM_TARGETS_prepend_x86 = "AMDGPU;"
-LLVM_TARGETS_prepend_x86-64 = "AMDGPU;"
+LLVM_TARGETS ?= "AMDGPU;${@get_llvm_host_arch(bb, d)}"
 
 ARM_INSTRUCTION_SET_armv5 = "arm"
 ARM_INSTRUCTION_SET_armv4t = "arm"
@@ -65,17 +63,19 @@
                   -DLLVM_ENABLE_FFI=ON \
                   -DFFI_INCLUDE_DIR=$(pkg-config --variable=includedir libffi) \
                   -DLLVM_OPTIMIZED_TABLEGEN=ON \
-                  -DLLVM_TARGETS_TO_BUILD="${LLVM_TARGETS}" \
+                  -DLLVM_TARGETS_TO_BUILD='${LLVM_TARGETS}' \
                   -G Ninja"
 
 EXTRA_OECMAKE_append_class-target = "\
                   -DCMAKE_CROSSCOMPILING:BOOL=ON \
                   -DLLVM_TABLEGEN=${STAGING_BINDIR_NATIVE}/llvm-tblgen${PV} \
+                  -DLLVM_CONFIG_PATH=${STAGING_BINDIR_NATIVE}/llvm-config${PV} \
                  "
 
 EXTRA_OECMAKE_append_class-nativesdk = "\
                   -DCMAKE_CROSSCOMPILING:BOOL=ON \
                   -DLLVM_TABLEGEN=${STAGING_BINDIR_NATIVE}/llvm-tblgen${PV} \
+                  -DLLVM_CONFIG_PATH=${STAGING_BINDIR_NATIVE}/llvm-config${PV} \
                  "
 
 do_configure_prepend() {
diff --git a/poky/meta/recipes-devtools/meson/meson.inc b/poky/meta/recipes-devtools/meson/meson.inc
new file mode 100644
index 0000000..b7fb3e6
--- /dev/null
+++ b/poky/meta/recipes-devtools/meson/meson.inc
@@ -0,0 +1,28 @@
+HOMEPAGE = "http://mesonbuild.com"
+SUMMARY = "A high performance build system"
+
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://COPYING;md5=3b83ef96387f14655fc854ddc3c6bd57"
+
+SRC_URI = "https://github.com/mesonbuild/meson/releases/download/${PV}/meson-${PV}.tar.gz \
+           file://0001-gtkdoc-fix-issues-that-arise-when-cross-compiling.patch \
+           file://0002-gobject-introspection-determine-g-ir-scanner-and-g-i.patch \
+           file://0001-Linker-rules-move-cross_args-in-front-of-output_args.patch \
+           file://0003-native_bindir.patch \
+           file://gi-flags.patch \
+           file://gtkdoc-flags.patch \
+           "
+SRC_URI[sha256sum] = "92d8afd921751261e36151643464efd3394162f69efbe8cd53e0a66b1cf395eb"
+SRC_URI[md5sum] = "31bda3519d8c0eb3438267268a78085e"
+
+SRC_URI_append_class-native = "file://0002-Make-CPU-family-warnings-fatal.patch \
+                               file://0001-Support-building-allarch-recipes-again.patch \
+                               "
+
+UPSTREAM_CHECK_URI = "https://github.com/mesonbuild/meson/releases"
+
+inherit setuptools3
+
+RDEPENDS_${PN} = "ninja python3-core python3-modules"
+
+FILES_${PN} += "${datadir}/polkit-1"
diff --git a/poky/meta/recipes-devtools/meson/meson/0001-Support-building-allarch-recipes-again.patch b/poky/meta/recipes-devtools/meson/meson/0001-Support-building-allarch-recipes-again.patch
new file mode 100644
index 0000000..f6dd230
--- /dev/null
+++ b/poky/meta/recipes-devtools/meson/meson/0001-Support-building-allarch-recipes-again.patch
@@ -0,0 +1,28 @@
+From d80d02a3ca6e21fa3d055c88c05234c2eb4db128 Mon Sep 17 00:00:00 2001
+From: Peter Kjellerstedt <pkj@axis.com>
+Date: Thu, 26 Jul 2018 16:32:49 +0200
+Subject: [PATCH] Support building allarch recipes again
+
+This registers "allarch" as a known CPU family.
+
+Upstream-Status: Inappropriate [OE specific]
+Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
+---
+ mesonbuild/environment.py | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py
+index a0580a2..712b1e8 100644
+--- a/mesonbuild/environment.py
++++ b/mesonbuild/environment.py
+@@ -73,6 +73,7 @@ from .compilers import (
+ build_filename = 'meson.build'
+ 
+ known_cpu_families = (
++    'allarch',
+     'aarch64',
+     'arm',
+     'e2k',
+-- 
+2.12.0
+
diff --git a/poky/meta/recipes-devtools/meson/meson/0001-gtkdoc-fix-issues-that-arise-when-cross-compiling.patch b/poky/meta/recipes-devtools/meson/meson/0001-gtkdoc-fix-issues-that-arise-when-cross-compiling.patch
index 1912e94..7ffd6c5 100644
--- a/poky/meta/recipes-devtools/meson/meson/0001-gtkdoc-fix-issues-that-arise-when-cross-compiling.patch
+++ b/poky/meta/recipes-devtools/meson/meson/0001-gtkdoc-fix-issues-that-arise-when-cross-compiling.patch
@@ -1,7 +1,7 @@
-From c5692cac9c555664281377a82bf8b1e46934f437 Mon Sep 17 00:00:00 2001
+From 3ac4e58c5494bd7e603a325b5b5c2b8075849fee Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Fri, 4 Aug 2017 16:16:41 +0300
-Subject: [PATCH 1/3] gtkdoc: fix issues that arise when cross-compiling
+Subject: [PATCH] gtkdoc: fix issues that arise when cross-compiling
 
 Specifically:
 1) Make it possible to specify a wrapper for executing binaries
@@ -21,10 +21,10 @@
  2 files changed, 22 insertions(+), 5 deletions(-)
 
 diff --git a/mesonbuild/modules/gnome.py b/mesonbuild/modules/gnome.py
-index 56765a5..4f7fe30 100644
+index cb69641..727eb6a 100644
 --- a/mesonbuild/modules/gnome.py
 +++ b/mesonbuild/modules/gnome.py
-@@ -769,6 +769,10 @@ This will become a hard error in the future.''')
+@@ -792,6 +792,10 @@ This will become a hard error in the future.''')
                  '--mode=' + mode]
          if namespace:
              args.append('--namespace=' + namespace)
@@ -35,53 +35,28 @@
          args += self._unpack_args('--htmlargs=', 'html_args', kwargs)
          args += self._unpack_args('--scanargs=', 'scan_args', kwargs)
          args += self._unpack_args('--scanobjsargs=', 'scanobjs_args', kwargs)
-@@ -796,14 +800,22 @@ This will become a hard error in the future.''')
-                 raise MesonException(
-                     'Gir include dirs should be include_directories().')
-         cflags.update(get_include_args(inc_dirs))
-+
-+        cross_c_args = " ".join(state.environment.cross_info.config["properties"].get('c_args', ""))
-+        cross_link_args = " ".join(state.environment.cross_info.config["properties"].get('c_link_args', ""))
-+
-         if cflags:
--            args += ['--cflags=%s' % ' '.join(cflags)]
-+            args += ['--cflags=%s %s' % (cross_c_args,' '.join(cflags))]
-         if ldflags:
--            args += ['--ldflags=%s' % ' '.join(ldflags)]
-+            args += ['--ldflags=%s %s' % (cross_link_args, ' '.join(ldflags))]
-         compiler = state.environment.coredata.compilers.get('c')
--        if compiler:
-+        cross_compiler = state.environment.coredata.cross_compilers.get('c')
-+        if compiler and not state.environment.is_cross_build():
-             args += ['--cc=%s' % ' '.join(compiler.get_exelist())]
-             args += ['--ld=%s' % ' '.join(compiler.get_linker_exelist())]
-+        elif cross_compiler and state.environment.is_cross_build():
-+            args += ['--cc=%s' % ' '.join(cross_compiler.get_exelist())]
-+            args += ['--ld=%s' % ' '.join(cross_compiler.get_linker_exelist())]
- 
-         return args
- 
 diff --git a/mesonbuild/scripts/gtkdochelper.py b/mesonbuild/scripts/gtkdochelper.py
-index 4406b28..b846827 100644
+index 948dc5a..9c5bd19 100644
 --- a/mesonbuild/scripts/gtkdochelper.py
 +++ b/mesonbuild/scripts/gtkdochelper.py
-@@ -44,13 +44,14 @@ parser.add_argument('--ignore-headers', dest='ignore_headers', default='')
+@@ -45,6 +45,7 @@ parser.add_argument('--ignore-headers', dest='ignore_headers', default='')
  parser.add_argument('--namespace', dest='namespace', default='')
  parser.add_argument('--mode', dest='mode', default='')
  parser.add_argument('--installdir', dest='install_dir')
 +parser.add_argument('--gtkdoc-exe-wrapper', dest='gtkdoc_exe_wrapper')
  
- def gtkdoc_run_check(cmd, cwd):
-     # Put stderr into stdout since we want to print it out anyway.
+ def gtkdoc_run_check(cmd, cwd, library_paths=None):
+     if library_paths is None:
+@@ -64,7 +65,7 @@ def gtkdoc_run_check(cmd, cwd, library_paths=None):
      # This preserves the order of messages.
-     p, out = Popen_safe(cmd, cwd=cwd, stderr=subprocess.STDOUT)[0:2]
+     p, out = Popen_safe(cmd, cwd=cwd, env=env, stderr=subprocess.STDOUT)[0:2]
      if p.returncode != 0:
 -        err_msg = ["{!r} failed with status {:d}".format(cmd[0], p.returncode)]
 +        err_msg = ["{!r} failed with status {:d}".format(cmd, p.returncode)]
          if out:
              err_msg.append(out)
          raise MesonException('\n'.join(err_msg))
-@@ -58,7 +59,7 @@ def gtkdoc_run_check(cmd, cwd):
+@@ -74,7 +75,7 @@ def gtkdoc_run_check(cmd, cwd, library_paths=None):
  def build_gtkdoc(source_root, build_root, doc_subdir, src_subdirs,
                   main_file, module,
                   html_args, scan_args, fixxref_args, mkdb_args,
@@ -90,7 +65,7 @@
                   html_assets, content_files, ignore_headers, namespace,
                   expand_content_files, mode):
      print("Building documentation for %s" % module)
-@@ -111,6 +112,9 @@ def build_gtkdoc(source_root, build_root, doc_subdir, src_subdirs,
+@@ -135,6 +136,9 @@ def build_gtkdoc(source_root, build_root, doc_subdir, src_subdirs,
      if gobject_typesfile:
          scanobjs_cmd = ['gtkdoc-scangobj'] + scanobjs_args + ['--types=' + gobject_typesfile,
                                                                '--module=' + module,
@@ -99,8 +74,8 @@
 +                                                              '--ld=' + ld,
                                                                '--cflags=' + cflags,
                                                                '--ldflags=' + ldflags,
-                                                               '--ld=' + ld]
-@@ -207,6 +211,7 @@ def run(args):
+                                                               '--cc=' + cc,
+@@ -238,6 +242,7 @@ def run(args):
          mkdbargs,
          options.gobject_typesfile,
          scanobjsargs,
@@ -108,6 +83,3 @@
          options.ld,
          options.cc,
          options.ldflags,
--- 
-2.15.0
-
diff --git a/poky/meta/recipes-devtools/meson/meson/0002-Make-CPU-family-warnings-fatal.patch b/poky/meta/recipes-devtools/meson/meson/0002-Make-CPU-family-warnings-fatal.patch
new file mode 100644
index 0000000..ca56a6a
--- /dev/null
+++ b/poky/meta/recipes-devtools/meson/meson/0002-Make-CPU-family-warnings-fatal.patch
@@ -0,0 +1,36 @@
+From 2e8553fc01e62ebc4faa240bf20984a8a0ac7387 Mon Sep 17 00:00:00 2001
+From: Ross Burton <ross.burton@intel.com>
+Date: Tue, 3 Jul 2018 13:59:09 +0100
+Subject: [PATCH] Make CPU family warnings fatal
+
+Upstream-Status: Inappropriate [OE specific]
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+---
+ mesonbuild/environment.py | 6 ++----
+ 1 file changed, 2 insertions(+), 4 deletions(-)
+
+diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py
+index d29a77f..267acf9 100644
+--- a/mesonbuild/environment.py
++++ b/mesonbuild/environment.py
+@@ -239,9 +239,7 @@ def detect_cpu_family(compilers):
+         return 'x86_64'
+ 
+     if trial not in known_cpu_families:
+-        mlog.warning('Unknown CPU family {!r}, please report this at '
+-                     'https://github.com/mesonbuild/meson/issues/new with the'
+-                     'output of `uname -a` and `cat /proc/cpuinfo`'.format(trial))
++        raise EnvironmentException('Unknown CPU family %s, see https://wiki.yoctoproject.org/wiki/Meson/UnknownCPU for directions.' % trial)
+ 
+     return trial
+ 
+@@ -1014,7 +1012,7 @@ class CrossBuildInfo:
+                     raise EnvironmentException('Malformed value in cross file variable %s.' % entry)
+ 
+                 if entry == 'cpu_family' and res not in known_cpu_families:
+-                    mlog.warning('Unknown CPU family %s, please report this at https://github.com/mesonbuild/meson/issues/new' % value)
++                    raise EnvironmentException('Unknown CPU family %s, see https://wiki.yoctoproject.org/wiki/Meson/UnknownCPU for directions.' % value)
+ 
+                 if self.ok_type(res):
+                     self.config[s][entry] = res
diff --git a/poky/meta/recipes-devtools/meson/meson/0002-gobject-introspection-determine-g-ir-scanner-and-g-i.patch b/poky/meta/recipes-devtools/meson/meson/0002-gobject-introspection-determine-g-ir-scanner-and-g-i.patch
index ded42d1..f32267d 100644
--- a/poky/meta/recipes-devtools/meson/meson/0002-gobject-introspection-determine-g-ir-scanner-and-g-i.patch
+++ b/poky/meta/recipes-devtools/meson/meson/0002-gobject-introspection-determine-g-ir-scanner-and-g-i.patch
@@ -1,7 +1,7 @@
-From 972667e0d789a6969a5d79249404f3539f891810 Mon Sep 17 00:00:00 2001
+From 0b860cb8a22ae876b6088939dbabca216bc29431 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Fri, 4 Aug 2017 16:18:47 +0300
-Subject: [PATCH 1/2] gobject-introspection: determine g-ir-scanner and
+Subject: [PATCH] gobject-introspection: determine g-ir-scanner and
  g-ir-compiler paths from pkgconfig
 
 Do not hardcode the name of those binaries; gobject-introspection
@@ -16,19 +16,19 @@
  1 file changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/mesonbuild/modules/gnome.py b/mesonbuild/modules/gnome.py
-index 4f7fe30..9610cf6 100644
+index b29bab9..dc4c401 100644
 --- a/mesonbuild/modules/gnome.py
 +++ b/mesonbuild/modules/gnome.py
-@@ -390,8 +390,6 @@ class GnomeModule(ExtensionModule):
+@@ -393,8 +393,6 @@ class GnomeModule(ExtensionModule):
              raise MesonException('Gir takes one argument')
          if kwargs.get('install_dir'):
              raise MesonException('install_dir is not supported with generate_gir(), see "install_dir_gir" and "install_dir_typelib"')
--        giscanner = find_program('g-ir-scanner', 'Gir')
--        gicompiler = find_program('g-ir-compiler', 'Gir')
+-        giscanner = self.interpreter.find_program_impl('g-ir-scanner')
+-        gicompiler = self.interpreter.find_program_impl('g-ir-compiler')
          girtarget = args[0]
          while hasattr(girtarget, 'held_object'):
              girtarget = girtarget.held_object
-@@ -402,6 +400,8 @@ class GnomeModule(ExtensionModule):
+@@ -405,6 +403,8 @@ class GnomeModule(ExtensionModule):
                  self.gir_dep = PkgConfigDependency('gobject-introspection-1.0',
                                                     state.environment,
                                                     {'native': True})
@@ -37,6 +37,3 @@
              pkgargs = self.gir_dep.get_compile_args()
          except Exception:
              raise MesonException('gobject-introspection dependency was not found, gir cannot be generated.')
--- 
-2.15.0
-
diff --git a/poky/meta/recipes-devtools/meson/meson/0003-native_bindir.patch b/poky/meta/recipes-devtools/meson/meson/0003-native_bindir.patch
index af5e6a1..da47745 100644
--- a/poky/meta/recipes-devtools/meson/meson/0003-native_bindir.patch
+++ b/poky/meta/recipes-devtools/meson/meson/0003-native_bindir.patch
@@ -1,7 +1,7 @@
-From ffa72eac56558aa4171dd70ac1e9c27a07338fa2 Mon Sep 17 00:00:00 2001
+From e762d85c823adfefc27ba6128c7b997aa50166ce Mon Sep 17 00:00:00 2001
 From: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
 Date: Wed, 15 Nov 2017 15:05:01 +0100
-Subject: [PATCH 4/4] native_bindir
+Subject: [PATCH] native_bindir
 
 Some libraries, like QT, have pre-processors that convert their input
 files into something that the cross-compiler can process. We find the
@@ -17,15 +17,15 @@
 Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
 
 ---
- mesonbuild/dependencies/base.py | 16 ++++++++++------
+ mesonbuild/dependencies/base.py | 19 +++++++++++--------
  mesonbuild/dependencies/ui.py   |  6 +++---
- 2 files changed, 13 insertions(+), 9 deletions(-)
+ 2 files changed, 14 insertions(+), 11 deletions(-)
 
 diff --git a/mesonbuild/dependencies/base.py b/mesonbuild/dependencies/base.py
-index bf79bc5..c9fd08c 100644
+index 6d3678f..90fdb80 100644
 --- a/mesonbuild/dependencies/base.py
 +++ b/mesonbuild/dependencies/base.py
-@@ -131,7 +131,7 @@ class Dependency:
+@@ -146,7 +146,7 @@ class Dependency:
      def need_threads(self):
          return False
  
@@ -34,7 +34,7 @@
          raise DependencyException('{!r} is not a pkgconfig dependency'.format(self.name))
  
      def get_configtool_variable(self, variable_name):
-@@ -150,7 +150,7 @@ class InternalDependency(Dependency):
+@@ -183,7 +183,7 @@ class InternalDependency(Dependency):
          self.sources = sources
          self.ext_deps = ext_deps
  
@@ -43,33 +43,47 @@
          raise DependencyException('Method "get_pkgconfig_variable()" is '
                                    'invalid for an internal dependency')
  
-@@ -425,10 +425,14 @@ class PkgConfigDependency(ExternalDependency):
+@@ -523,15 +523,18 @@ class PkgConfigDependency(ExternalDependency):
          return s.format(self.__class__.__name__, self.name, self.is_found,
                          self.version_reqs)
  
+-    def _call_pkgbin_real(self, args, env):
+-        cmd = self.pkgbin.get_command() + args
++    def _call_pkgbin_real(self, args, env, use_native=False):
++        if use_native:
++            cmd = self.pkgbin.get_command() + "-native" + args
++        else:
++            cmd = self.pkgbin.get_command() + args
+         p, out = Popen_safe(cmd, env=env)[0:2]
+         rc, out = p.returncode, out.strip()
+         call = ' '.join(cmd)
+         mlog.debug("Called `{}` -> {}\n{}".format(call, rc, out))
+         return rc, out
+ 
 -    def _call_pkgbin(self, args, env=None):
 +    def _call_pkgbin(self, args, env=None, use_native=False):
-         if not env:
+         if env is None:
+             fenv = env
              env = os.environ
--        p, out = Popen_safe([self.pkgbin] + args, env=env)[0:2]
-+        if use_native:
-+            pkgbin = [self.pkgbin + "-native"]
-+        else:
-+            pkgbin = [self.pkgbin]
-+        p, out = Popen_safe(pkgbin + args, env=env)[0:2]
-         return p.returncode, out.strip()
+@@ -540,7 +543,7 @@ class PkgConfigDependency(ExternalDependency):
+         targs = tuple(args)
+         cache = PkgConfigDependency.pkgbin_cache
+         if (self.pkgbin, targs, fenv) not in cache:
+-            cache[(self.pkgbin, targs, fenv)] = self._call_pkgbin_real(args, env)
++            cache[(self.pkgbin, targs, fenv)] = self._call_pkgbin_real(args, env, use_native)
+         return cache[(self.pkgbin, targs, fenv)]
  
      def _convert_mingw_paths(self, args):
-@@ -522,7 +526,7 @@ class PkgConfigDependency(ExternalDependency):
-             # linkers such as MSVC, so prepend them.
-             self.link_args = ['-L' + lp for lp in libpaths] + self.link_args
+@@ -718,7 +721,7 @@ class PkgConfigDependency(ExternalDependency):
+                                       (self.name, out_raw))
+         self.link_args, self.raw_link_args = self._search_libs(out, out_raw)
  
 -    def get_pkgconfig_variable(self, variable_name, kwargs):
 +    def get_pkgconfig_variable(self, variable_name, kwargs, use_native=False):
          options = ['--variable=' + variable_name, self.name]
  
          if 'define_variable' in kwargs:
-@@ -535,7 +539,7 @@ class PkgConfigDependency(ExternalDependency):
+@@ -731,7 +734,7 @@ class PkgConfigDependency(ExternalDependency):
  
              options = ['--define-variable=' + '='.join(definition)] + options
  
@@ -79,10 +93,10 @@
          if ret != 0:
              if self.required:
 diff --git a/mesonbuild/dependencies/ui.py b/mesonbuild/dependencies/ui.py
-index 1db518c..4ed1d04 100644
+index 197d22c..c683d21 100644
 --- a/mesonbuild/dependencies/ui.py
 +++ b/mesonbuild/dependencies/ui.py
-@@ -239,7 +239,7 @@ class QtBaseDependency(ExternalDependency):
+@@ -285,7 +285,7 @@ class QtBaseDependency(ExternalDependency):
          self.bindir = self.get_pkgconfig_host_bins(core)
          if not self.bindir:
              # If exec_prefix is not defined, the pkg-config file is broken
@@ -91,7 +105,7 @@
              if prefix:
                  self.bindir = os.path.join(prefix, 'bin')
  
-@@ -359,7 +359,7 @@ class Qt4Dependency(QtBaseDependency):
+@@ -427,7 +427,7 @@ class Qt4Dependency(QtBaseDependency):
          applications = ['moc', 'uic', 'rcc', 'lupdate', 'lrelease']
          for application in applications:
              try:
@@ -100,15 +114,12 @@
              except MesonException:
                  pass
  
-@@ -369,7 +369,7 @@ class Qt5Dependency(QtBaseDependency):
+@@ -437,7 +437,7 @@ class Qt5Dependency(QtBaseDependency):
          QtBaseDependency.__init__(self, 'qt5', env, kwargs)
  
      def get_pkgconfig_host_bins(self, core):
 -        return core.get_pkgconfig_variable('host_bins', {})
 +        return core.get_pkgconfig_variable('host_bins', {}, use_native=True)
  
- 
- # There are three different ways of depending on SDL2:
--- 
-2.15.1
-
+     def get_private_includes(self, mod_inc_dir, module):
+         return _qt_get_private_includes(mod_inc_dir, module, self.version)
diff --git a/poky/meta/recipes-devtools/meson/meson/gi-flags.patch b/poky/meta/recipes-devtools/meson/meson/gi-flags.patch
new file mode 100644
index 0000000..9a4c296
--- /dev/null
+++ b/poky/meta/recipes-devtools/meson/meson/gi-flags.patch
@@ -0,0 +1,35 @@
+Pass the correct cflags/ldflags to the gobject-introspection tools.
+
+Upstream-Status: Submitted [https://github.com/mesonbuild/meson/pull/4261]
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+diff --git a/mesonbuild/modules/gnome.py b/mesonbuild/modules/gnome.py
+index cb69641e..bb4449a0 100644
+--- a/mesonbuild/modules/gnome.py
++++ b/mesonbuild/modules/gnome.py
+@@ -579,7 +579,10 @@ class GnomeModule(ExtensionModule):
+         external_ldflags += list(dep_external_ldflags)
+         scan_command += ['--cflags-begin']
+         scan_command += cflags
+-        scan_command += state.environment.coredata.get_external_args(lang)
++        if state.environment.is_cross_build():
++            scan_command += state.environment.cross_info.config["properties"].get(lang + '_args', "")
++        else:
++            scan_command += state.environment.coredata.get_external_args(lang)
+         scan_command += ['--cflags-end']
+         # need to put our output directory first as we need to use the
+         # generated libraries instead of any possibly installed system/prefix
+@@ -614,7 +614,12 @@ class GnomeModule(ExtensionModule):
+                 scan_command.append('-L' + d)
+             scan_command += ['--library', libname]
+ 
+-        for link_arg in state.environment.coredata.get_external_link_args(lang):
++        if state.environment.is_cross_build():
++            link_args = state.environment.cross_info.config["properties"].get(lang + '_link_args', "")
++        else:
++            link_args = state.environment.coredata.get_external_link_args(lang)
++
++        for link_arg in link_args:
+             if link_arg.startswith('-L'):
+                 scan_command.append(link_arg)
+         scan_command += list(external_ldflags)
diff --git a/poky/meta/recipes-devtools/meson/meson/gtkdoc-flags.patch b/poky/meta/recipes-devtools/meson/meson/gtkdoc-flags.patch
new file mode 100644
index 0000000..ecf3489
--- /dev/null
+++ b/poky/meta/recipes-devtools/meson/meson/gtkdoc-flags.patch
@@ -0,0 +1,44 @@
+Ensure that in a cross compile only the target flags are passed to gtk-doc, and
+not the native flags.
+
+Upstream-Status: Submitted [https://github.com/mesonbuild/meson/pull/4261]
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+diff --git a/mesonbuild/modules/gnome.py b/mesonbuild/modules/gnome.py
+index 4af33304..8751f53c 100644
+--- a/mesonbuild/modules/gnome.py
++++ b/mesonbuild/modules/gnome.py
+@@ -851,17 +851,30 @@ This will become a hard error in the future.''')
+             if not isinstance(incd.held_object, (str, build.IncludeDirs)):
+                 raise MesonException(
+                     'Gir include dirs should be include_directories().')
++
+         cflags.update(get_include_args(inc_dirs))
+-        cflags.update(state.environment.coredata.get_external_args('c'))
++        if state.environment.is_cross_build():
++            cflags.update(state.environment.cross_info.config["properties"].get('c_args', ""))
++        else:
++            cflags.update(state.environment.coredata.get_external_args('c'))
++
+         ldflags = OrderedSet()
+         ldflags.update(internal_ldflags)
+-        ldflags.update(state.environment.coredata.get_external_link_args('c'))
++        if state.environment.is_cross_build():
++            ldflags.update(state.environment.cross_info.config["properties"].get('c_link_args', ""))
++        else:
++            ldflags.update(state.environment.coredata.get_external_link_args('c'))
+         ldflags.update(external_ldflags)
++
+         if cflags:
+             args += ['--cflags=%s' % ' '.join(cflags)]
+         if ldflags:
+             args += ['--ldflags=%s' % ' '.join(ldflags)]
+-        compiler = state.environment.coredata.compilers.get('c')
++
++        if state.environment.is_cross_build():
++            compiler = state.environment.coredata.cross_compilers.get('c')
++        else:
++            compiler = state.environment.coredata.compilers.get('c')
+         if compiler:
+             args += ['--cc=%s' % ' '.join(compiler.get_exelist())]
+             args += ['--ld=%s' % ' '.join(compiler.get_linker_exelist())]
diff --git a/poky/meta/recipes-devtools/meson/meson/meson-setup.py b/poky/meta/recipes-devtools/meson/meson/meson-setup.py
new file mode 100755
index 0000000..a9749ea
--- /dev/null
+++ b/poky/meta/recipes-devtools/meson/meson/meson-setup.py
@@ -0,0 +1,62 @@
+#!/usr/bin/env python3
+
+import os
+import sys
+
+def bail(msg):
+    print(msg, file=sys.stderr)
+    sys.exit(1)
+
+_MARKER = '@@'
+def transform_line(line):
+    # Substitute any special markers of this form:
+    # @@ENV@@
+    # with the value of ENV, split into meson array syntax.
+    start = line.find(_MARKER)
+    if start == -1:
+        return line
+
+    end = line.rfind(_MARKER)
+    if end == start:
+        return line
+
+    # Lookup value of the env var.
+    var = line[start+len(_MARKER):end]
+    try:
+        val = os.environ[var]
+    except KeyError:
+        bail('cannot generate meson.cross; env var %s not set' % var)
+
+    # Transform into meson array.
+    val = ["'%s'" % x for x in val.split()]
+    val = ', '.join(val)
+    val = '[%s]' % val
+
+    before = line[:start]
+    after = line[end+len(_MARKER):]
+
+    return '%s%s%s' % (before, val, after)
+
+# Make sure this is really an SDK extraction environment.
+try:
+    sysroot = os.environ['OECORE_NATIVE_SYSROOT']
+except KeyError:
+    bail('OECORE_NATIVE_SYSROOT env var must be set')
+
+cross_file = os.path.join(sysroot, 'usr/share/meson/meson.cross')
+tmp_cross_file = '%s.tmp' % cross_file
+
+# Read through and transform the current meson.cross.
+lines = []
+with open(cross_file, 'r') as f:
+    for line in f:
+        lines.append(transform_line(line))
+
+# Write the transformed result to a tmp file and atomically rename it. In case
+# we crash during the file write, we don't want an invalid meson.cross file.
+with open(tmp_cross_file, 'w') as f:
+    for line in lines:
+        f.write(line)
+    f.flush()
+    os.fdatasync(f.fileno())
+os.rename(tmp_cross_file, cross_file)
diff --git a/poky/meta/recipes-devtools/meson/meson/meson-wrapper b/poky/meta/recipes-devtools/meson/meson/meson-wrapper
new file mode 100755
index 0000000..b2e00da
--- /dev/null
+++ b/poky/meta/recipes-devtools/meson/meson/meson-wrapper
@@ -0,0 +1,14 @@
+#!/bin/sh
+
+if [ -z "$OECORE_NATIVE_SYSROOT" ]; then
+    echo "OECORE_NATIVE_SYSROOT not set; are you in a Yocto SDK environment?" >&2
+fi
+
+# If these are set to a cross-compile path, meson will get confused and try to
+# use them as native tools. Unset them to prevent this, as all the cross-compile
+# config is already in meson.cross.
+unset CC CXX CPP LD AR NM STRIP
+
+exec "$OECORE_NATIVE_SYSROOT/usr/bin/meson.real" \
+     --cross-file "$OECORE_NATIVE_SYSROOT/usr/share/meson/meson.cross" \
+     "$@"
diff --git a/poky/meta/recipes-devtools/meson/meson_0.44.1.bb b/poky/meta/recipes-devtools/meson/meson_0.44.1.bb
deleted file mode 100644
index 6a81dab..0000000
--- a/poky/meta/recipes-devtools/meson/meson_0.44.1.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-HOMEPAGE = "http://mesonbuild.com"
-SUMMARY = "A high performance build system"
-
-LICENSE = "Apache-2.0"
-LIC_FILES_CHKSUM = "file://COPYING;md5=3b83ef96387f14655fc854ddc3c6bd57"
-
-SRC_URI = "https://github.com/mesonbuild/meson/releases/download/${PV}/${BP}.tar.gz \
-           file://0001-gtkdoc-fix-issues-that-arise-when-cross-compiling.patch \
-           file://0002-gobject-introspection-determine-g-ir-scanner-and-g-i.patch \
-           file://0001-Linker-rules-move-cross_args-in-front-of-output_args.patch \
-           file://0003-native_bindir.patch \
-           "
-SRC_URI[md5sum] = "82b1198bf714b5a4da84bfe8376c79cc"
-SRC_URI[sha256sum] = "2ea1a721574adb23160b6481191bcc1173f374e02b0ff3bb0ae85d988d97e4fa"
-UPSTREAM_CHECK_URI = "https://github.com/mesonbuild/meson/releases"
-
-inherit setuptools3
-
-RDEPENDS_${PN} = "ninja python3-core python3-modules"
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-devtools/meson/meson_0.47.2.bb b/poky/meta/recipes-devtools/meson/meson_0.47.2.bb
new file mode 100644
index 0000000..897fa14
--- /dev/null
+++ b/poky/meta/recipes-devtools/meson/meson_0.47.2.bb
@@ -0,0 +1,3 @@
+include meson.inc
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-devtools/meson/nativesdk-meson_0.47.2.bb b/poky/meta/recipes-devtools/meson/nativesdk-meson_0.47.2.bb
new file mode 100644
index 0000000..53503aa
--- /dev/null
+++ b/poky/meta/recipes-devtools/meson/nativesdk-meson_0.47.2.bb
@@ -0,0 +1,74 @@
+include meson.inc
+
+inherit nativesdk
+
+SRC_URI += "file://meson-setup.py \
+            file://meson-wrapper"
+
+def meson_array(var, d):
+    return "', '".join(d.getVar(var).split()).join(("'", "'"))
+
+# both are required but not used by meson
+MESON_SDK_ENDIAN = "bogus-endian"
+MESON_TARGET_ENDIAN = "bogus-endian"
+
+MESON_TOOLCHAIN_ARGS = "${BUILDSDK_CC_ARCH}${TOOLCHAIN_OPTIONS}"
+MESON_C_ARGS = "${MESON_TOOLCHAIN_ARGS} ${BUILDSDK_CFLAGS}"
+MESON_CPP_ARGS = "${MESON_TOOLCHAIN_ARGS} ${BUILDSDK_CXXFLAGS}"
+MESON_LINK_ARGS = "${MESON_TOOLCHAIN_ARGS} ${BUILDSDK_LDFLAGS}"
+
+# This logic is similar but not identical to that in meson.bbclass, since it's
+# generating for an SDK rather than a cross-compile. Important differences are:
+# - We can't set vars like CC, CXX, etc. yet because they will be filled in with
+#   real paths by meson-setup.sh when the SDK is extracted.
+# - Some overrides aren't needed, since the SDK injects paths that take care of
+#   them.
+addtask write_config before do_install
+do_write_config[vardeps] += "MESON_C_ARGS MESON_CPP_ARGS MESON_LINK_ARGS CC CXX LD AR NM STRIP READELF"
+do_write_config() {
+    # This needs to be Py to split the args into single-element lists
+    cat >${WORKDIR}/meson.cross <<EOF
+[binaries]
+c = @@CC@@
+cpp = @@CXX@@
+ar = @@AR@@
+nm = @@NM@@
+ld = @@LD@@
+strip = @@STRIP@@
+pkgconfig = 'pkg-config'
+
+[properties]
+needs_exe_wrapper = true
+c_args = @@CFLAGS@@
+c_link_args = @@LDFLAGS@@
+cpp_args = @@CPPFLAGS@@
+cpp_link_args = @@LDFLAGS@@
+
+[host_machine]
+system = '${SDK_OS}'
+cpu_family = '${SDK_ARCH}'
+cpu = '${SDK_ARCH}'
+endian = '${MESON_SDK_ENDIAN}'
+EOF
+}
+
+do_install_append() {
+    install -d ${D}${datadir}/meson
+    install -m 0644 ${WORKDIR}/meson.cross ${D}${datadir}/meson/
+
+    install -d ${D}${SDKPATHNATIVE}/post-relocate-setup.d
+    install -m 0755 ${WORKDIR}/meson-setup.py ${D}${SDKPATHNATIVE}/post-relocate-setup.d/
+
+    # We need to wrap the real meson with a thin env setup wrapper.
+    mv ${D}${bindir}/meson ${D}${bindir}/meson.real
+    install -m 0755 ${WORKDIR}/meson-wrapper ${D}${bindir}/meson
+}
+
+RDEPENDS_${PN} += "\
+    nativesdk-ninja \
+    nativesdk-python3-core \
+    nativesdk-python3-misc \
+    nativesdk-python3-modules \
+    "
+
+FILES_${PN} += "${datadir}/meson ${SDKPATHNATIVE}"
diff --git a/poky/meta/recipes-devtools/mtd/mtd-utils_git.bb b/poky/meta/recipes-devtools/mtd/mtd-utils_git.bb
index 69f2eba..f53c6c1 100644
--- a/poky/meta/recipes-devtools/mtd/mtd-utils_git.bb
+++ b/poky/meta/recipes-devtools/mtd/mtd-utils_git.bb
@@ -10,9 +10,9 @@
 DEPENDS = "zlib lzo e2fsprogs util-linux"
 RDEPENDS_mtd-utils-tests += "bash"
 
-PV = "2.0.1+${SRCPV}"
+PV = "2.0.2+${SRCPV}"
 
-SRCREV = "9c6173559f95e939e66efb2ec3193d6f3618cf69"
+SRCREV = "bc63d36e39f389c8c17f6a8e9db47f2acc884659"
 SRC_URI = "git://git.infradead.org/mtd-utils.git \
            file://add-exclusion-to-mkfs-jffs2-git-2.patch \
            file://0001-Revert-Return-correct-error-number-in-ubi_get_vol_in.patch \
diff --git a/poky/meta/recipes-devtools/mtools/mtools/0001-remove-LOCK_NB-to-use-blocking-request.patch b/poky/meta/recipes-devtools/mtools/mtools/0001-remove-LOCK_NB-to-use-blocking-request.patch
new file mode 100644
index 0000000..47385a5
--- /dev/null
+++ b/poky/meta/recipes-devtools/mtools/mtools/0001-remove-LOCK_NB-to-use-blocking-request.patch
@@ -0,0 +1,44 @@
+From 5bdbfe0a63fed48104b17412854b26ee2275869a Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Wed, 22 Aug 2018 16:54:39 +0800
+Subject: [PATCH] remove LOCK_NB to use blocking request
+
+While invoking mtools frequently, the unblocking request
+caused race issue. Here is an example of syslinux
+[snip]
+dd if=/dev/zero of=floppy.img bs=1024 count=144
+losetup /dev/loop1 floppy.img
+mkdosfs /dev/loop1
+syslinux -i /dev/loop1
+|plain floppy: device "/proc/6351/fd/3" busy (Resource temporarily unavailable):
+|Cannot initialize 'S:'
+|Bad target s:/ldlinux.sys
+[snip]
+
+The idea is from:
+https://bugzilla.redhat.com/show_bug.cgi?id=1235016
+https://groups.google.com/a/chromium.org/forum/#!msg/chromium-os-dev/bRPUCFHoBTQ/ZjB8kjjx1vUJ
+
+Upstream-Status: Pending
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ lockdev.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/lockdev.h b/lockdev.h
+index 4467bc2..5a135ad 100644
+--- a/lockdev.h
++++ b/lockdev.h
+@@ -43,7 +43,7 @@ int lock_dev(int fd, int mode, struct device *dev)
+ 		return 0;
+ 
+ #if (defined(HAVE_FLOCK) && defined (LOCK_EX) && defined(LOCK_NB))
+-	if (flock(fd, (mode ? LOCK_EX : LOCK_SH)|LOCK_NB) < 0)
++	if (flock(fd, (mode ? LOCK_EX : LOCK_SH)) < 0)
+ #else /* FLOCK */
+ 
+ #if (defined(HAVE_LOCKF) && defined(F_TLOCK))
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/mtools/mtools/clang_UNUSED.patch b/poky/meta/recipes-devtools/mtools/mtools/clang_UNUSED.patch
new file mode 100644
index 0000000..6bb9d6a
--- /dev/null
+++ b/poky/meta/recipes-devtools/mtools/mtools/clang_UNUSED.patch
@@ -0,0 +1,17 @@
+Undefine UNUSED macros with clang
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Index: mtools-4.0.18/sysincludes.h
+===================================================================
+--- mtools-4.0.18.orig/sysincludes.h
++++ mtools-4.0.18/sysincludes.h
+@@ -101,7 +101,7 @@ typedef void *caddr_t;
+ #if defined __GNUC__ && defined __STDC__
+ /* gcc -traditional doesn't have PACKED, UNUSED and NORETURN */
+ # define PACKED __attribute__ ((packed))
+-# if __GNUC__ == 2 && __GNUC_MINOR__ > 6 || __GNUC__ >= 3
++# if (__GNUC__ == 2 && __GNUC_MINOR__ > 6 || __GNUC__ >= 3) && !defined(__clang__)
+ /* gcc 2.6.3 doesn't have "unused" */		/* mool */
+ #  define UNUSED(x) x __attribute__ ((unused));x
+ #  define UNUSEDP __attribute__ ((unused))
diff --git a/poky/meta/recipes-devtools/mtools/mtools_4.0.18.bb b/poky/meta/recipes-devtools/mtools/mtools_4.0.18.bb
index dcd32ed..3c31aca 100644
--- a/poky/meta/recipes-devtools/mtools/mtools_4.0.18.bb
+++ b/poky/meta/recipes-devtools/mtools/mtools_4.0.18.bb
@@ -31,6 +31,8 @@
            file://mtools-makeinfo.patch \
            file://no-x11.gplv3.patch \
            file://0001-Continue-even-if-fs-size-is-not-divisible-by-sectors.patch \
+           file://0001-remove-LOCK_NB-to-use-blocking-request.patch \
+           file://clang_UNUSED.patch \
            "
 
 SRC_URI_append_class-native = " file://disable-hardcoded-configs.patch"
diff --git a/poky/meta/recipes-devtools/opkg-utils/opkg-utils/pigz.patch b/poky/meta/recipes-devtools/opkg-utils/opkg-utils/pigz.patch
new file mode 100644
index 0000000..dd433e8
--- /dev/null
+++ b/poky/meta/recipes-devtools/opkg-utils/opkg-utils/pigz.patch
@@ -0,0 +1,51 @@
+From ab1436927b47badcd219a5f075dfc848020e061d Mon Sep 17 00:00:00 2001
+From: Mike Crowe <mac@mcrowe.com>
+Date: Thu, 4 Oct 2018 17:54:19 +0100
+Subject: [opkg-utils PATCH] opkg-build: Add support for explicit use of pigz
+To: opkg-devel@googlegroups.com,
+    yocto@yoctoproject.org
+
+oe-core has stopped[1] installing pigz as gzip. This means that in
+order to persuade opkg-build to use pigz it must be specified
+explicitly. Let's teach opkg-build to deal with being passed pigz as a
+compressor.
+
+We can't combine the check for whether -T is required with the one for
+gzip because opkg-build needs to call $compressor and gzip separately
+to construct the package.
+
+[1] http://lists.openembedded.org/pipermail/openembedded-commits/2018-February/218767.html
+
+Upstream-Status: Submitted [opkg-devel@googlegroups.com https://groups.google.com/forum/#!topic/opkg-devel/E0WVOhjK61w]
+Signed-off-by: Mike Crowe <mac@mcrowe.com>
+---
+ opkg-build | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+diff --git a/opkg-build b/opkg-build
+index 93a7956..f8403ea 100755
+--- a/opkg-build
++++ b/opkg-build
+@@ -170,7 +170,7 @@ fi
+ 
+ compressor_ext() {
+     case $1 in
+-	gzip)
++	gzip|pigz)
+ 	    echo gz
+ 	    ;;
+ 	bzip2)
+@@ -232,6 +232,10 @@ if [ $compressor = "gzip" ] ; then
+ 	compressorargs=$zipargs
+ elif [ $compressor = "xz" ] ; then
+ 	compressorargs="--threads 0"
++elif [ $compressor = "pigz" ] ; then
++	if $compressor --help 2>&1 | grep -- "-T" > /dev/null; then
++		compressorargs="-9nT"
++	fi
+ fi
+ 
+ tsortargs=
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-devtools/opkg-utils/opkg-utils_0.3.6.bb b/poky/meta/recipes-devtools/opkg-utils/opkg-utils_0.3.6.bb
index 0487c5f..cb3775d 100644
--- a/poky/meta/recipes-devtools/opkg-utils/opkg-utils_0.3.6.bb
+++ b/poky/meta/recipes-devtools/opkg-utils/opkg-utils_0.3.6.bb
@@ -12,6 +12,7 @@
            file://0001-Only-use-sort-name-on-versions-of-tar-which-support-.patch \
            file://0002-opkg-build-Use-local-time-for-build_date-since-opkg-.patch \
            file://threaded-xz.patch \
+           file://pigz.patch \
 "
 SRC_URI_append_class-native = " file://tar_ignore_error.patch"
 UPSTREAM_CHECK_URI = "http://git.yoctoproject.org/cgit/cgit.cgi/opkg-utils/refs/"
diff --git a/poky/meta/recipes-devtools/opkg/opkg-keyrings_1.0.bb b/poky/meta/recipes-devtools/opkg/opkg-keyrings_1.0.bb
index 18d6abd..a20e316 100644
--- a/poky/meta/recipes-devtools/opkg/opkg-keyrings_1.0.bb
+++ b/poky/meta/recipes-devtools/opkg/opkg-keyrings_1.0.bb
@@ -35,14 +35,6 @@
 # We need 'opkg-key' to run the postinst script
 RDEPENDS_${PN} = "opkg"
 
-pkg_postinst_${PN} () {
-#! /bin/sh
-set -e
-
-if [ x"$D" = "x" ]; then
-    # On target
-    opkg-key populate
-else
-    exit 1
-fi
+pkg_postinst_ontarget_${PN} () {
+opkg-key populate
 }
diff --git a/poky/meta/recipes-devtools/opkg/opkg/0001-remove_maintainer_scripts-use-strict-matching.patch b/poky/meta/recipes-devtools/opkg/opkg/0001-remove_maintainer_scripts-use-strict-matching.patch
new file mode 100644
index 0000000..ec16029
--- /dev/null
+++ b/poky/meta/recipes-devtools/opkg/opkg/0001-remove_maintainer_scripts-use-strict-matching.patch
@@ -0,0 +1,56 @@
+From 55c4ad666e76281bdd0db55fa6f4ab2744fea7e4 Mon Sep 17 00:00:00 2001
+From: Alejandro del Castillo <alejandro.delcastillo@ni.com>
+Date: Tue, 4 Sep 2018 18:06:00 -0500
+Subject: [PATCH] remove_maintainer_scripts: use strict matching
+
+The function is using a glob to select which metadata files needs to be
+deleted during package removal, on the info_dir. However, the glob may
+match metadata files from packages with similar names. For example,
+during removal of package glibc-binary-localedata-de-at, the current
+logic was also removing the metadata for
+glibc-binary-localedata-de-at.iso-8859-1. Add check for an exact match
+before deletion.
+
+Fixes bugzilla: 12905
+
+Upstream-Status: Submitted [https://groups.google.com/forum/#!topic/opkg-devel/Fr40Yt0NBno]
+Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
+---
+ libopkg/opkg_remove.c | 14 +++++++++++---
+ 1 file changed, 11 insertions(+), 3 deletions(-)
+
+diff --git a/libopkg/opkg_remove.c b/libopkg/opkg_remove.c
+index 82125fa..3936628 100644
+--- a/libopkg/opkg_remove.c
++++ b/libopkg/opkg_remove.c
+@@ -137,7 +137,7 @@ void remove_maintainer_scripts(pkg_t * pkg)
+ {
+     unsigned int i;
+     int err;
+-    char *globpattern;
++    char *globpattern, *filename, *lastdot;
+     glob_t globbuf;
+ 
+     if (opkg_config->noaction)
+@@ -151,8 +151,16 @@ void remove_maintainer_scripts(pkg_t * pkg)
+         return;
+ 
+     for (i = 0; i < globbuf.gl_pathc; i++) {
+-        opkg_msg(INFO, "Deleting %s.\n", globbuf.gl_pathv[i]);
+-        unlink(globbuf.gl_pathv[i]);
++        filename = xstrdup(basename(globbuf.gl_pathv[i]));
++        lastdot = strrchr(filename, '.');
++        *lastdot = '\0';
++        // Only delete files that match the package name (the glob may match files
++        // with similar names)
++        if (!strcmp(filename, pkg->name)) {
++            opkg_msg(INFO, "Deleting %s.\n", globbuf.gl_pathv[i]);
++            unlink(globbuf.gl_pathv[i]);
++        }
++        free(filename);
+     }
+     globfree(&globbuf);
+ }
+-- 
+2.18.0
+
diff --git a/poky/meta/recipes-devtools/opkg/opkg/opkg-configure.service b/poky/meta/recipes-devtools/opkg/opkg/opkg-configure.service
deleted file mode 100644
index 432c3dd..0000000
--- a/poky/meta/recipes-devtools/opkg/opkg/opkg-configure.service
+++ /dev/null
@@ -1,17 +0,0 @@
-[Unit]
-Description=Opkg first boot configure
-DefaultDependencies=no
-After=systemd-remount-fs.service systemd-tmpfiles-setup.service tmp.mount
-Before=sysinit.target
-
-[Service]
-Type=oneshot
-EnvironmentFile=-@SYSCONFDIR@/default/postinst
-ExecStart=-@BASE_BINDIR@/sh -c " if [ $POSTINST_LOGGING = '1' ]; then @BINDIR@/opkg configure > $LOGFILE 2>&1; else @BINDIR@/opkg configure; fi"
-ExecStartPost=@BASE_BINDIR@/systemctl --no-reload disable opkg-configure.service
-StandardOutput=syslog
-RemainAfterExit=No
-
-[Install]
-WantedBy=basic.target
-WantedBy=sysinit.target
diff --git a/poky/meta/recipes-devtools/opkg/opkg_0.3.6.bb b/poky/meta/recipes-devtools/opkg/opkg_0.3.6.bb
index 70f20af..6ebd58b 100644
--- a/poky/meta/recipes-devtools/opkg/opkg_0.3.6.bb
+++ b/poky/meta/recipes-devtools/opkg/opkg_0.3.6.bb
@@ -12,9 +12,9 @@
 PE = "1"
 
 SRC_URI = "http://downloads.yoctoproject.org/releases/${BPN}/${BPN}-${PV}.tar.gz \
-           file://opkg-configure.service \
            file://opkg.conf \
            file://0001-opkg_conf-create-opkg.lock-in-run-instead-of-var-run.patch \
+           file://0001-remove_maintainer_scripts-use-strict-matching.patch \
 "
 
 SRC_URI[md5sum] = "79e04307f6f54db431c251772d7d987c"
@@ -22,8 +22,6 @@
 
 inherit autotools pkgconfig systemd
 
-SYSTEMD_SERVICE_${PN} = "opkg-configure.service"
-
 target_localstatedir := "${localstatedir}"
 OPKGLIBDIR = "${target_localstatedir}/lib"
 
@@ -46,16 +44,6 @@
 
 	# We need to create the lock directory
 	install -d ${D}${OPKGLIBDIR}/opkg
-
-	if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)};then
-		install -d ${D}${systemd_unitdir}/system
-		install -m 0644 ${WORKDIR}/opkg-configure.service ${D}${systemd_unitdir}/system/
-		sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
-			-e 's,@SYSCONFDIR@,${sysconfdir},g' \
-			-e 's,@BINDIR@,${bindir},g' \
-			-e 's,@SYSTEMD_UNITDIR@,${systemd_unitdir},g' \
-			${D}${systemd_unitdir}/system/opkg-configure.service
-	fi
 }
 
 RDEPENDS_${PN} = "${VIRTUAL-RUNTIME_update-alternatives} opkg-arch-config libarchive"
@@ -68,7 +56,6 @@
 PACKAGES =+ "libopkg"
 
 FILES_libopkg = "${libdir}/*.so.* ${OPKGLIBDIR}/opkg/"
-FILES_${PN} += "${systemd_unitdir}/system/"
 
 BBCLASSEXTEND = "native nativesdk"
 
diff --git a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/0001-Change-library-name.patch b/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/0001-Change-library-name.patch
deleted file mode 100644
index ed67c50..0000000
--- a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/0001-Change-library-name.patch
+++ /dev/null
@@ -1,119 +0,0 @@
-From: Piotr Roszatycki <dexter@debian.org>
-Date: Wed, 27 Jan 2010 16:53:11 +0100
-Subject: [PATCH] Change library name
-
-The soname was changed to ossp-uuid to prevend the name clash with e2fsprogs's
-uuid library.
----
- Makefile.in      |    6 +++---
- perl/Makefile.PL |   12 ++++++------
- php/config.m4    |    2 +-
- uuid-config.in   |    2 +-
- uuid.pc.in       |    4 ++--
- 5 files changed, 13 insertions(+), 13 deletions(-)
-
-----
-Upstream-Status: Inappropriate [not author]
-
-This patch is from debian ossp-uuid 1.6.2 integration.
-
-Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
-
-diff --git a/Makefile.in b/Makefile.in
-index d28f4be..c2ba99d 100644
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -62,13 +62,13 @@ PERL        = @PERL@
- PHP         = @PHP@
- PG_CONFIG   = @PG_CONFIG@
- 
--LIB_NAME    = libuuid.la
-+LIB_NAME    = libossp-uuid.la
- LIB_OBJS    = uuid.lo uuid_md5.lo uuid_sha1.lo uuid_prng.lo uuid_mac.lo uuid_time.lo uuid_ui64.lo uuid_ui128.lo uuid_str.lo
- 
--DCE_NAME    = libuuid_dce.la
-+DCE_NAME    = libossp-uuid_dce.la
- DCE_OBJS    = uuid_dce.lo $(LIB_OBJS)
- 
--CXX_NAME    = libuuid++.la
-+CXX_NAME    = libossp-uuid++.la
- CXX_OBJS    = uuid++.lo $(LIB_OBJS)
- 
- PRG_NAME    = uuid
-diff --git a/perl/Makefile.PL b/perl/Makefile.PL
-index 92f4494..9c6fee6 100644
---- a/perl/Makefile.PL
-+++ b/perl/Makefile.PL
-@@ -33,9 +33,9 @@ use Config;
- use ExtUtils::MakeMaker;
- 
- #   determine source directory
--my ($srcdir) = map { my $d = $_; $d =~ s/\/libuuid\.la$//; $d }
--               grep { -f $_ } ("../libuuid.la", glob("../*/libuuid.la"))
--    or die "no source directory found (where libuuid.la is located)";
-+my ($srcdir) = map { my $d = $_; $d =~ s/\/libossp-uuid\.la$//; $d }
-+               grep { -f $_ } ("../libossp-uuid.la", glob("../*/libossp-uuid.la"))
-+    or die "no source directory found (where libossp-uuid.la is located)";
- 
- #   determine extra build options
- my $compat = 0;
-@@ -47,15 +47,15 @@ WriteMakefile(
-     VERSION_FROM      => 'uuid.pm',
-     ABSTRACT_FROM     => 'uuid.pod',
-     PREREQ_PM         => {},
--    LIBS              => [ "-L$srcdir/.libs -L$srcdir -luuid" ],
-+    LIBS              => [ "-L$srcdir/.libs -L$srcdir -lossp-uuid" ],
-     DEFINE            => '',
-     INC               => "-I. -I$srcdir",
-     PM                => { 'uuid.pm'   => '$(INST_LIBDIR)/uuid.pm',
-                            'uuid.pod'  => '$(INST_LIBDIR)/uuid.pod',
-                            ($compat ? ('uuid_compat.pm'  => '$(INST_LIBDIR)/../Data/UUID.pm')  : ()),
-                            ($compat ? ('uuid_compat.pod' => '$(INST_LIBDIR)/../Data/UUID.pod') : ()), },
--    MAN3PODS          => { 'uuid.pod' => '$(INST_MAN3DIR)/OSSP::uuid.3',
--                           ($compat ? ('uuid_compat.pod' => '$(INST_MAN3DIR)/Data::UUID.3') : ()), },
-+    MAN3PODS          => { 'uuid.pod' => '$(INST_MAN3DIR)/OSSP::uuid.3pm',
-+                           ($compat ? ('uuid_compat.pod' => '$(INST_MAN3DIR)/Data::UUID.3pm') : ()), },
-     TYPEMAPS          => [ 'uuid.tm' ],
-     test              => { TESTS => 'uuid.ts' . ($compat ? ' uuid_compat.ts' : '') },
-     NO_META           => 1,
-diff --git a/php/config.m4 b/php/config.m4
-index 5091b96..969b457 100644
---- a/php/config.m4
-+++ b/php/config.m4
-@@ -34,7 +34,7 @@ if test "$PHP_UUID" != "no"; then
-     PHP_NEW_EXTENSION(uuid, uuid.c, $ext_shared)
-     AC_DEFINE(HAVE_UUID, 1, [Have OSSP uuid library])
-     PHP_ADD_LIBPATH([..], )
--    PHP_ADD_LIBRARY([uuid],, UUID_SHARED_LIBADD)
-+    PHP_ADD_LIBRARY([ossp-uuid],, UUID_SHARED_LIBADD)
-     PHP_ADD_INCLUDE([..])
-     PHP_SUBST(UUID_SHARED_LIBADD)
- 
-diff --git a/uuid-config.in b/uuid-config.in
-index 8d2a063..5b58812 100644
---- a/uuid-config.in
-+++ b/uuid-config.in
-@@ -121,7 +121,7 @@ do
-             output_extra="$output_extra $uuid_ldflags"
-             ;;
-         --libs)
--            output="$output -luuid"
-+            output="$output -lossp-uuid"
-             output_extra="$output_extra $uuid_libs"
-             ;;
-         * )
-diff --git a/uuid.pc.in b/uuid.pc.in
-index c76ad1e..de00c2f 100644
---- a/uuid.pc.in
-+++ b/uuid.pc.in
-@@ -36,7 +36,7 @@ Name: OSSP uuid
- Description: Universally Unique Identifier (UUID) Library
- Version: @UUID_VERSION_RAW@
- URL: http://www.ossp.org/pkg/lib/uuid/
--Cflags: -I${includedir}
--Libs: -L${libdir} -luuid
-+Cflags: -I${includedir}/ossp
-+Libs: -L${libdir} -lossp-uuid
- Libs.private: @LIBS@
- 
--- 
diff --git a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/0002-uuid-preserve-m-option-status-in-v-option-handling.patch b/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/0002-uuid-preserve-m-option-status-in-v-option-handling.patch
deleted file mode 100644
index 804a627..0000000
--- a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/0002-uuid-preserve-m-option-status-in-v-option-handling.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-From: Marco Nenciarini <marco.nenciarini@devise.it>
-Date: Wed, 27 Jan 2010 19:46:21 +0100
-Subject: [PATCH] uuid: preserve -m option status in -v option handling
-
-Bug: 531396
----
- uuid_cli.c |   19 ++++++++++---------
- 1 files changed, 10 insertions(+), 9 deletions(-)
-
-----
-Upstream-Status: Inappropriate [not author]
-
-This patch is from debian ossp-uuid 1.6.2 integration.
-
-Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
-
-diff --git a/uuid_cli.c b/uuid_cli.c
-index d1b0b11..14a67fe 100644
---- a/uuid_cli.c
-+++ b/uuid_cli.c
-@@ -140,11 +140,12 @@ int main(int argc, char *argv[])
-                 i = strtol(optarg, &p, 10);
-                 if (*p != '\0')
-                     usage("invalid argument to option 'v'");
-+                version &= ~(UUID_MAKE_V1|UUID_MAKE_V3|UUID_MAKE_V4|UUID_MAKE_V5);
-                 switch (i) {
--                    case 1: version = UUID_MAKE_V1; break;
--                    case 3: version = UUID_MAKE_V3; break;
--                    case 4: version = UUID_MAKE_V4; break;
--                    case 5: version = UUID_MAKE_V5; break;
-+                    case 1: version |= UUID_MAKE_V1; break;
-+                    case 3: version |= UUID_MAKE_V3; break;
-+                    case 4: version |= UUID_MAKE_V4; break;
-+                    case 5: version |= UUID_MAKE_V5; break;
-                     default:
-                         usage("invalid version on option 'v'");
-                         break;
-@@ -213,10 +214,10 @@ int main(int argc, char *argv[])
-     }
-     else {
-         /* encoding */
--        if (   (version == UUID_MAKE_V1 && argc != 0)
--            || (version == UUID_MAKE_V3 && argc != 2)
--            || (version == UUID_MAKE_V4 && argc != 0)
--            || (version == UUID_MAKE_V5 && argc != 2))
-+        if (   (version & UUID_MAKE_V1 && argc != 0)
-+            || (version & UUID_MAKE_V3 && argc != 2)
-+            || (version & UUID_MAKE_V4 && argc != 0)
-+            || (version & UUID_MAKE_V5 && argc != 2))
-             usage("invalid number of arguments");
-         if ((rc = uuid_create(&uuid)) != UUID_RC_OK)
-             error(1, "uuid_create: %s", uuid_error(rc));
-@@ -232,7 +233,7 @@ int main(int argc, char *argv[])
-                 if ((rc = uuid_load(uuid, "nil")) != UUID_RC_OK)
-                     error(1, "uuid_load: %s", uuid_error(rc));
-             }
--            if (version == UUID_MAKE_V3 || version == UUID_MAKE_V5) {
-+            if (version & UUID_MAKE_V3 || version & UUID_MAKE_V5) {
-                 if ((rc = uuid_create(&uuid_ns)) != UUID_RC_OK)
-                     error(1, "uuid_create: %s", uuid_error(rc));
-                 if ((rc = uuid_load(uuid_ns, argv[0])) != UUID_RC_OK) {
--- 
diff --git a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/0003-Fix-whatis-entries.patch b/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/0003-Fix-whatis-entries.patch
deleted file mode 100644
index 13cbb59..0000000
--- a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/0003-Fix-whatis-entries.patch
+++ /dev/null
@@ -1,58 +0,0 @@
-From: Marco Nenciarini <marco.nenciarini@devise.it>
-Date: Tue, 2 Feb 2010 12:16:49 +0100
-Subject: [PATCH] Fix whatis entries
-
-Fix whatis entry of uuid.1, uuid.3ossp and uuid++.3ossp manpages
----
- uuid++.pod   |    2 +-
- uuid.pod     |    2 +-
- uuid_cli.pod |    2 +-
- 3 files changed, 3 insertions(+), 3 deletions(-)
-
-----
-Upstream-Status: Inappropriate [not author]
-
-This patch is from debian ossp-uuid 1.6.2 integration.
-
-Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
-
-diff --git a/uuid++.pod b/uuid++.pod
-index 8b5a4b1..89c5efb 100644
---- a/uuid++.pod
-+++ b/uuid++.pod
-@@ -31,7 +31,7 @@
- 
- =head1 NAME
- 
--B<OSSP uuid> - B<Universally Unique Identifier> (C++ API)
-+B<uuid++> - B<Universally Unique Identifier> (C++ API)
- 
- =head1 VERSION
- 
-diff --git a/uuid.pod b/uuid.pod
-index 4ad3742..0179a46 100644
---- a/uuid.pod
-+++ b/uuid.pod
-@@ -31,7 +31,7 @@
- 
- =head1 NAME
- 
--B<OSSP uuid> - B<Universally Unique Identifier>
-+B<uuid> - B<Universally Unique Identifier>
- 
- =head1 VERSION
- 
-diff --git a/uuid_cli.pod b/uuid_cli.pod
-index ddec6bb..df9dc83 100644
---- a/uuid_cli.pod
-+++ b/uuid_cli.pod
-@@ -31,7 +31,7 @@
- 
- =head1 NAME
- 
--B<OSSP uuid> - B<Universally Unique Identifier Command-Line Tool>
-+B<uuid> - B<Universally Unique Identifier Command-Line Tool>
- 
- =head1 VERSION
- 
--- 
diff --git a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/0004-fix-data-uuid-from-string.patch b/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/0004-fix-data-uuid-from-string.patch
deleted file mode 100644
index bc5e111..0000000
--- a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/0004-fix-data-uuid-from-string.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-Description: Support dash-less args to from_string.
-Author: Tim Retout <diocles@debian.org>
-Bug-Debian: http://bugs.debian.org/635607
-
-The module Data::GUID depends on Data::UUID supporting this behaviour.
-
-----
-Upstream-Status: Inappropriate [not author]
-
-This patch is from debian ossp-uuid 1.6.2 integration.
-
-Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
-
---- a/perl/uuid_compat.pm
-+++ b/perl/uuid_compat.pm
-@@ -93,7 +93,9 @@
-     $uuid->import('str',
-           $str =~ /^0x/
-         ? join '-', unpack('x2 a8 a4 a4 a4 a12', $str)
--        : $str
-+        : $str =~ /-/
-+        ? $str
-+        : join '-', unpack('A8 A4 A4 A4 A12', $str)
-     );
-     return $uuid->export('bin');
- }
---- a/perl/uuid_compat.ts
-+++ b/perl/uuid_compat.ts
-@@ -28,7 +28,7 @@
- ##  uuid_compat.ts: Data::UUID Backward Compatibility Perl API (Perl test suite part)
- ##
- 
--use Test::More tests => 14;
-+use Test::More tests => 16;
- 
- BEGIN {
-     use_ok('Data::UUID');
-@@ -53,3 +53,5 @@
- ok($uuid8 = $ug->from_string("6ba7b811-9dad-11d1-80b4-00c04fd430c8"));
- ok($ug->compare($uuid7, $uuid8) == 0);
- 
-+ok($uuid9 = $ug->from_string("6ba7b8119dad11d180b400c04fd430c8"));
-+ok($ug->compare($uuid7, $uuid9) == 0);
diff --git a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/install-pc.patch b/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/install-pc.patch
deleted file mode 100644
index 63b80f6..0000000
--- a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/install-pc.patch
+++ /dev/null
@@ -1,19 +0,0 @@
-uuid.pc is generated at build time so should be installed from the current
-directory, and not $S.
-
-Upstream-Status: Pending [should be submitted]
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
-Index: uuid-1.6.2/Makefile.in
-===================================================================
---- uuid-1.6.2.orig/Makefile.in	2012-11-13 16:58:28.624156000 +0000
-+++ uuid-1.6.2/Makefile.in	2012-11-13 17:05:24.224158670 +0000
-@@ -232,7 +232,7 @@
- 	$(SHTOOL) mkdir -f -p -m 755 $(DESTDIR)$(mandir)/man1
- 	$(SHTOOL) install -c -m 755 uuid-config $(DESTDIR)$(bindir)/
- 	$(SHTOOL) install -c -m 644 $(S)/uuid-config.1 $(DESTDIR)$(mandir)/man1/
--	$(SHTOOL) install -c -m 644 $(S)/uuid.pc $(DESTDIR)$(libdir)/pkgconfig/
-+	$(SHTOOL) install -c -m 644 uuid.pc $(DESTDIR)$(libdir)/pkgconfig/
- 	$(SHTOOL) install -c -m 644 uuid.h $(DESTDIR)$(includedir)/
- 	-@if [ ".$(WITH_DCE)" = .yes ]; then \
- 	    echo "$(SHTOOL) install -c -m 644 $(S)/uuid_dce.h $(DESTDIR)$(includedir)/"; \
diff --git a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/ldflags.patch b/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/ldflags.patch
deleted file mode 100644
index 4dfc137..0000000
--- a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/ldflags.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-Obey LDFLAGS
-
-Signed-off-by: Christopher Larson <chris_larson@mentor.com>
-Upstream-Status: Pending
-
---- uuid-1.6.2.orig/Makefile.in
-+++ uuid-1.6.2/Makefile.in
-@@ -113,15 +113,15 @@ all: $(TARGETS)
-	@$(LIBTOOL) --mode=compile $(CXX) $(CPPFLAGS) $(CXXFLAGS) -c $<
-
- $(LIB_NAME): $(LIB_OBJS)
--	@$(LIBTOOL) --mode=link $(CC) -o $(LIB_NAME) $(LIB_OBJS) -rpath $(libdir) \
-+	@$(LIBTOOL) --mode=link $(CC) $(LDFLAGS) -o $(LIB_NAME) $(LIB_OBJS) -rpath $(libdir) \
-	    -version-info `$(SHTOOL) version -l c -d libtool $(S)/uuid_vers.h`
-
- $(DCE_NAME): $(DCE_OBJS)
--	@$(LIBTOOL) --mode=link $(CC) -o $(DCE_NAME) $(DCE_OBJS) -rpath $(libdir) \
-+	@$(LIBTOOL) --mode=link $(CC) $(LDFLAGS) -o $(DCE_NAME) $(DCE_OBJS) -rpath $(libdir) \
-	    -version-info `$(SHTOOL) version -l c -d libtool $(S)/uuid_vers.h`
-
- $(CXX_NAME): $(CXX_OBJS)
--	@$(LIBTOOL) --mode=link $(CXX) -o $(CXX_NAME) $(CXX_OBJS) -rpath $(libdir) \
-+	@$(LIBTOOL) --mode=link $(CXX) $(LDFLAGS) -o $(CXX_NAME) $(CXX_OBJS) -rpath $(libdir) \
-	    -version-info `$(SHTOOL) version -l c -d libtool $(S)/uuid_vers.h`
-
- $(PRG_NAME): $(PRG_OBJS) $(LIB_NAME)
diff --git a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/libtool-tag.patch b/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/libtool-tag.patch
deleted file mode 100644
index 7f601af..0000000
--- a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/libtool-tag.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-Repect LIBTOOLFLAGS
-
-This add a knob that can be controlled from env to set generic options
-for libtool
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Index: uuid-1.6.2/Makefile.in
-===================================================================
---- uuid-1.6.2.orig/Makefile.in
-+++ uuid-1.6.2/Makefile.in
-@@ -56,7 +56,7 @@ RM          = rm -f
- CP          = cp
- RMDIR       = rmdir
- SHTOOL      = $(S)/shtool
--LIBTOOL     = @LIBTOOL@
-+LIBTOOL     = @LIBTOOL@ $(LIBTOOLFLAGS)
- TRUE        = true
- POD2MAN     = pod2man
- PERL        = @PERL@
diff --git a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/uuid-libtool.patch b/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/uuid-libtool.patch
deleted file mode 100644
index 4bc91b8..0000000
--- a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/uuid-libtool.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-Remove hardcoded libtool name, fall back to generated name
-
-Upstream-Status: Inappropriate [no upstream]
-The project appears to no longer be accepting changes.
-
-Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
-
-diff -ur uuid-1.6.2.orig/Makefile.in uuid-1.6.2/Makefile.in
---- uuid-1.6.2.orig/Makefile.in	2012-05-14 14:37:19.579672930 -0500
-+++ uuid-1.6.2/Makefile.in	2012-05-14 14:37:49.112733787 -0500
-@@ -32,6 +32,7 @@
- VPATH       = @srcdir@
- srcdir      = @srcdir@
- top_srcdir  = @top_srcdir@
-+top_builddir = @top_builddir@
- S           = $(srcdir)
- C           = .
- 
-@@ -55,7 +56,7 @@
- CP          = cp
- RMDIR       = rmdir
- SHTOOL      = $(S)/shtool
--LIBTOOL     = $(C)/libtool
-+LIBTOOL     = @LIBTOOL@
- TRUE        = true
- POD2MAN     = pod2man
- PERL        = @PERL@
diff --git a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/uuid-nostrip.patch b/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/uuid-nostrip.patch
deleted file mode 100644
index d806b5f..0000000
--- a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid/uuid-nostrip.patch
+++ /dev/null
@@ -1,19 +0,0 @@
-We don't want anything stripped
-
-Upstream-Status: Inappropriate [no upstream]
-The project appears to no longer be accepting changes.
-
-Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
-
-diff -ur uuid-1.6.2.orig/Makefile.in uuid-1.6.2/Makefile.in
---- uuid-1.6.2.orig/Makefile.in	2012-05-14 14:42:42.225789456 -0500
-+++ uuid-1.6.2/Makefile.in	2012-05-14 15:03:03.119733400 -0500
-@@ -254,7 +254,7 @@
- 	-@if [ ".$(WITH_CXX)" = .yes ]; then \
- 	    $(LIBTOOL) --mode=install $(SHTOOL) install -c -m 644 $(CXX_NAME) $(DESTDIR)$(libdir)/; \
- 	fi
--	@$(LIBTOOL) --mode=install $(SHTOOL) install -c -s -m 755 uuid $(DESTDIR)$(bindir)/
-+	@$(LIBTOOL) --mode=install $(SHTOOL) install -c -m 755 uuid $(DESTDIR)$(bindir)/
- 	$(SHTOOL) install -c -m 644 $(S)/uuid.1 $(DESTDIR)$(mandir)/man1/
- 	-@if [ ".$(WITH_PERL)" = .yes ]; then \
- 	    (cd $(S)/perl && $(MAKE) $(MFLAGS) install DESTDIR=$(DESTDIR)); \
diff --git a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid_1.6.2.bb b/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid_1.6.2.bb
deleted file mode 100644
index 5d9ca79..0000000
--- a/poky/meta/recipes-devtools/ossp-uuid/ossp-uuid_1.6.2.bb
+++ /dev/null
@@ -1,66 +0,0 @@
-SUMMARY = "Universally Unique Identifier (UUID) library"
-DESCRIPTION = "OSSP uuid is a ISO-C:1999 application programming interface \
-(API) and corresponding command line interface (CLI) for the generation of \
-DCE 1.1, ISO/IEC 11578:1996 and RFC 4122 compliant Universally Unique \
-Identifier (UUID). It supports DCE 1.1 variant UUIDs of version 1 (time \
-and node based), version 3 (name based, MD5), version 4 (random number \
-based) and version 5 (name based, SHA-1)."
-DESCRIPTION_uuid = "This package contains a tool to create Universally \
-Unique Identifiers (UUID) from the command-line."
-
-HOMEPAGE = "http://www.ossp.org/pkg/lib/uuid/"
-SECTION = "libs"
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://README;beginline=30;endline=55;md5=b394fadb039bbfca6ad9d9d769ee960e \
-	   file://uuid_md5.c;beginline=1;endline=28;md5=9c1f4b2218546deae24c91be1dcf00dd"
-
-PR = "r2"
-UPSTREAM_CHECK_URI = "${DEBIAN_MIRROR}/main/o/ossp-uuid/"
-
-SRC_URI = "http://snapshot.debian.org/archive/debian/20160728T043443Z/pool/main/o/${BPN}/${BPN}_${PV}.orig.tar.gz \
-	   file://0001-Change-library-name.patch \
-	   file://0002-uuid-preserve-m-option-status-in-v-option-handling.patch \
-	   file://0003-Fix-whatis-entries.patch \
-	   file://0004-fix-data-uuid-from-string.patch \
-	   file://uuid-libtool.patch \
-	   file://uuid-nostrip.patch \
-           file://install-pc.patch \
-           file://ldflags.patch \
-           file://libtool-tag.patch \
-	  "
-SRC_URI[md5sum] = "5db0d43a9022a6ebbbc25337ae28942f"
-SRC_URI[sha256sum] = "11a615225baa5f8bb686824423f50e4427acd3f70d394765bdff32801f0fd5b0"
-
-S = "${WORKDIR}/uuid-${PV}"
-
-inherit autotools update-alternatives
-
-EXTRA_OECONF = "--without-dce --without-cxx --without-perl --without-perl-compat --without-php --without-pgsql"
-EXTRA_OECONF = "--includedir=${includedir}/ossp"
-EXTRA_OEMAKE_class-target = "LIBTOOLFLAGS='--tag=CC'"
-
-do_configure_prepend() {
-  # This package has a completely custom aclocal.m4, which should be acinclude.m4.
-  if [ ! -e ${S}/acinclude.m4 ]; then
-    mv ${S}/aclocal.m4 ${S}/acinclude.m4
-  fi
-
-  rm -f ${S}/libtool.m4
-}
-
-do_install_append() {
-  mkdir -p  ${D}${includedir}/ossp
-  mv ${D}${libdir}/pkgconfig/uuid.pc ${D}${libdir}/pkgconfig/ossp-uuid.pc
-}
-
-PACKAGES =+ "uuid"
-FILES_uuid = "${bindir}/uuid"
-FILES_${PN} = "${libdir}/libossp-uuid.so.16*"
-FILES_${PN}-dev += "${bindir}/uuid-config"
-
-BBCLASSEXTEND = "native nativesdk"
-
-ALTERNATIVE_${PN}-doc = "uuid.3"
-ALTERNATIVE_PRIORITY_${PN}-doc = "200"
-ALTERNATIVE_LINK_NAME[uuid.3] = "${mandir}/man3/uuid.3"
diff --git a/poky/meta/recipes-devtools/perl/liberror-perl_0.17025.bb b/poky/meta/recipes-devtools/perl/liberror-perl_0.17025.bb
deleted file mode 100644
index f6dc30d..0000000
--- a/poky/meta/recipes-devtools/perl/liberror-perl_0.17025.bb
+++ /dev/null
@@ -1,33 +0,0 @@
-SUMMARY = "Error - Error/exception handling in an OO-ish way"
-DESCRIPTION = "The Error package provides two interfaces. Firstly \
-Error provides a procedural interface to exception handling. \
-Secondly Error is a base class for errors/exceptions that can \
-either be thrown, for subsequent catch, or can simply be recorded."
-
-SECTION = "libs"
-LICENSE = "Artistic-1.0 | GPL-1.0+"
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=8f3499d09ee74a050c0319391ff9d100"
-
-DEPENDS += "perl"
-
-SRC_URI = "http://cpan.metacpan.org/authors/id/S/SH/SHLOMIF/Error-${PV}.tar.gz"
-
-SRC_URI[md5sum] = "1a2ee7f0dc44f9ee76661a16bbbc0c48"
-SRC_URI[sha256sum] = "6c9f474ad3d4fe0cabff6b6be532cb1dd348245986d4a6b600ad921d5cfdefaf"
-
-S = "${WORKDIR}/Error-${PV}"
-
-inherit cpan ptest-perl
-
-do_compile() {
-	export LIBC="$(find ${STAGING_DIR_TARGET}/${base_libdir}/ -name 'libc-*.so')"
-	cpan_do_compile
-}
-
-do_install_prepend() {
-	# test requires "-T" (taint) command line option
-	rm -rf ${B}/t/pod-coverage.t
-}
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-devtools/perl/liberror-perl_0.17026.bb b/poky/meta/recipes-devtools/perl/liberror-perl_0.17026.bb
new file mode 100644
index 0000000..6f42b47
--- /dev/null
+++ b/poky/meta/recipes-devtools/perl/liberror-perl_0.17026.bb
@@ -0,0 +1,33 @@
+SUMMARY = "Error - Error/exception handling in an OO-ish way"
+DESCRIPTION = "The Error package provides two interfaces. Firstly \
+Error provides a procedural interface to exception handling. \
+Secondly Error is a base class for errors/exceptions that can \
+either be thrown, for subsequent catch, or can simply be recorded."
+
+SECTION = "libs"
+LICENSE = "Artistic-1.0 | GPL-1.0+"
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=8f3499d09ee74a050c0319391ff9d100"
+
+DEPENDS += "perl"
+
+SRC_URI = "http://cpan.metacpan.org/authors/id/S/SH/SHLOMIF/Error-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "0dcd94640f617df02b6d6c1e4e92018c"
+SRC_URI[sha256sum] = "37590a962cd73ae03470e1ff16459a6cbc5273fc57626b8981dab9c2433155d9"
+
+S = "${WORKDIR}/Error-${PV}"
+
+inherit cpan ptest-perl
+
+do_compile() {
+	export LIBC="$(find ${STAGING_DIR_TARGET}/${base_libdir}/ -name 'libc-*.so')"
+	cpan_do_compile
+}
+
+do_install_prepend() {
+	# test requires "-T" (taint) command line option
+	rm -rf ${B}/t/pod-coverage.t
+}
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-devtools/perl/liburi-perl_1.73.bb b/poky/meta/recipes-devtools/perl/liburi-perl_1.73.bb
deleted file mode 100644
index 49238f3..0000000
--- a/poky/meta/recipes-devtools/perl/liburi-perl_1.73.bb
+++ /dev/null
@@ -1,38 +0,0 @@
-SUMMARY = "Perl module to manipulate and access URI strings"
-DESCRIPTION = "This package contains the URI.pm module with friends. \
-The module implements the URI class. URI objects can be used to access \
-and manipulate the various components that make up these strings."
-
-HOMEPAGE = "http://search.cpan.org/dist/URI/"
-SECTION = "libs"
-LICENSE = "Artistic-1.0 | GPL-1.0+"
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=c453e94fae672800f83bc1bd7a38b53f"
-
-DEPENDS += "perl"
-
-SRC_URI = "http://www.cpan.org/authors/id/E/ET/ETHER/URI-${PV}.tar.gz"
-
-SRC_URI[md5sum] = "37d44a08e599aa945b32a9434ffe00a5"
-SRC_URI[sha256sum] = "cca7ab4a6f63f3ccaacae0f2e1337e8edf84137e73f18548ec7d659f23efe413"
-
-S = "${WORKDIR}/URI-${PV}"
-
-EXTRA_CPANFLAGS = "EXPATLIBPATH=${STAGING_LIBDIR} EXPATINCPATH=${STAGING_INCDIR}"
-
-inherit cpan ptest-perl
-
-do_compile() {
-	export LIBC="$(find ${STAGING_DIR_TARGET}/${base_libdir}/ -name 'libc-*.so')"
-	cpan_do_compile
-}
-
-do_install_prepend() {
-	# these tests require "-T" (taint) command line option
-	rm -rf ${B}/t/cwd.t
-	rm -rf ${B}/t/file.t
-}
-
-RDEPENDS_${PN}-ptest += "libtest-needs-perl"
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-devtools/perl/liburi-perl_1.74.bb b/poky/meta/recipes-devtools/perl/liburi-perl_1.74.bb
new file mode 100644
index 0000000..a7cfa0f
--- /dev/null
+++ b/poky/meta/recipes-devtools/perl/liburi-perl_1.74.bb
@@ -0,0 +1,38 @@
+SUMMARY = "Perl module to manipulate and access URI strings"
+DESCRIPTION = "This package contains the URI.pm module with friends. \
+The module implements the URI class. URI objects can be used to access \
+and manipulate the various components that make up these strings."
+
+HOMEPAGE = "http://search.cpan.org/dist/URI/"
+SECTION = "libs"
+LICENSE = "Artistic-1.0 | GPL-1.0+"
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=c453e94fae672800f83bc1bd7a38b53f"
+
+DEPENDS += "perl"
+
+SRC_URI = "http://www.cpan.org/authors/id/E/ET/ETHER/URI-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "892f7183b178af40f205ba37128225db"
+SRC_URI[sha256sum] = "a9c254f45f89cb1dd946b689dfe433095404532a4543bdaab0b71ce0fdcdd53d"
+
+S = "${WORKDIR}/URI-${PV}"
+
+EXTRA_CPANFLAGS = "EXPATLIBPATH=${STAGING_LIBDIR} EXPATINCPATH=${STAGING_INCDIR}"
+
+inherit cpan ptest-perl
+
+do_compile() {
+	export LIBC="$(find ${STAGING_DIR_TARGET}/${base_libdir}/ -name 'libc-*.so')"
+	cpan_do_compile
+}
+
+do_install_prepend() {
+	# these tests require "-T" (taint) command line option
+	rm -rf ${B}/t/cwd.t
+	rm -rf ${B}/t/file.t
+}
+
+RDEPENDS_${PN}-ptest += "libtest-needs-perl"
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-devtools/perl/libxml-parser-perl_2.44.bb b/poky/meta/recipes-devtools/perl/libxml-parser-perl_2.44.bb
index c5e0ae6..95af4d1 100644
--- a/poky/meta/recipes-devtools/perl/libxml-parser-perl_2.44.bb
+++ b/poky/meta/recipes-devtools/perl/libxml-parser-perl_2.44.bb
@@ -18,8 +18,15 @@
 
 # fix up sub MakeMaker project as arguments don't get propagated though
 # see https://rt.cpan.org/Public/Bug/Display.html?id=28632
+do_configure_append_class-target() {
+	sed -E \
+	    -e 's:-L${STAGING_LIBDIR}::g' -e 's:-I${STAGING_INCDIR}::g' \
+	    -i Makefile Expat/Makefile
+}
+
 do_configure_append() {
-	sed 's:--sysroot=.*\(\s\|$\):--sysroot=${STAGING_DIR_TARGET} :g' -i Makefile Expat/Makefile
+	sed -e 's:--sysroot=.*\(\s\|$\):--sysroot=${STAGING_DIR_TARGET} :g' \
+	    -i Makefile Expat/Makefile
 	sed 's:^FULL_AR = .*:FULL_AR = ${AR}:g' -i Expat/Makefile
 	# make sure these two do not build in parallel
 	sed 's!^$(INST_DYNAMIC):!$(INST_DYNAMIC): $(BOOTSTRAP)!' -i Expat/Makefile
diff --git a/poky/meta/recipes-devtools/perl/libxml-simple-perl_2.24.bb b/poky/meta/recipes-devtools/perl/libxml-simple-perl_2.24.bb
deleted file mode 100644
index f9d00d2..0000000
--- a/poky/meta/recipes-devtools/perl/libxml-simple-perl_2.24.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-SUMMARY = "Perl module for reading and writing XML"
-DESCRIPTION = "The XML::Simple Perl module provides a simple API layer \
-on top of an underlying XML parsing module to maintain XML files \
-(especially configuration files). It is a blunt rewrite of XML::Simple \
-(by Grant McLean) to use the XML::LibXML parser for XML structures, \
-where the original uses plain Perl or SAX parsers."
-HOMEPAGE = "http://search.cpan.org/~markov/XML-LibXML-Simple-0.93/lib/XML/LibXML/Simple.pod"
-SECTION = "libs"
-LICENSE = "Artistic-1.0 | GPL-1.0+"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=23477e18a0d04392cdf44ae70e49b495"
-DEPENDS += "libxml-parser-perl"
-
-SRC_URI = "http://www.cpan.org/modules/by-module/XML/XML-Simple-${PV}.tar.gz"
-
-SRC_URI[md5sum] = "1cd2e8e3421160c42277523d5b2f4dd2"
-SRC_URI[sha256sum] = "9a14819fd17c75fbb90adcec0446ceab356cab0ccaff870f2e1659205dc2424f"
-
-S = "${WORKDIR}/XML-Simple-${PV}"
-
-EXTRA_PERLFLAGS = "-I ${PERLHOSTLIB}"
-
-inherit cpan ptest-perl
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-devtools/perl/libxml-simple-perl_2.25.bb b/poky/meta/recipes-devtools/perl/libxml-simple-perl_2.25.bb
new file mode 100644
index 0000000..53788d5
--- /dev/null
+++ b/poky/meta/recipes-devtools/perl/libxml-simple-perl_2.25.bb
@@ -0,0 +1,35 @@
+SUMMARY = "Perl module for reading and writing XML"
+DESCRIPTION = "The XML::Simple Perl module provides a simple API layer \
+on top of an underlying XML parsing module to maintain XML files \
+(especially configuration files). It is a blunt rewrite of XML::Simple \
+(by Grant McLean) to use the XML::LibXML parser for XML structures, \
+where the original uses plain Perl or SAX parsers."
+HOMEPAGE = "http://search.cpan.org/~markov/XML-LibXML-Simple-0.93/lib/XML/LibXML/Simple.pod"
+SECTION = "libs"
+LICENSE = "Artistic-1.0 | GPL-1.0+"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=cf206df8c9fe775f1d4c484386491eac"
+DEPENDS += "libxml-parser-perl"
+
+SRC_URI = "http://www.cpan.org/modules/by-module/XML/XML-Simple-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "bb841dce889a26c89a1c2739970e9fbc"
+SRC_URI[sha256sum] = "531fddaebea2416743eb5c4fdfab028f502123d9a220405a4100e68fc480dbf8"
+
+S = "${WORKDIR}/XML-Simple-${PV}"
+
+EXTRA_PERLFLAGS = "-I ${PERLHOSTLIB}"
+
+inherit cpan ptest-perl
+
+RDEPENDS_${PN} += " \
+    libxml-namespacesupport-perl \
+    libxml-parser-perl \
+    libxml-sax-perl \
+"
+
+RDEPENDS_${PN}-ptest += " \
+    perl-module-file-temp \
+    perl-module-test-more \
+"
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-devtools/perl/perl-native_5.24.1.bb b/poky/meta/recipes-devtools/perl/perl-native_5.24.1.bb
deleted file mode 100644
index 71f4589..0000000
--- a/poky/meta/recipes-devtools/perl/perl-native_5.24.1.bb
+++ /dev/null
@@ -1,139 +0,0 @@
-require perl.inc
-
-# We need gnugrep (for -I)
-DEPENDS = "db-native grep-native gdbm-native zlib-native"
-
-EXTRA_OEMAKE = "-e MAKEFLAGS="
-
-SRC_URI += "\
-           file://Configure-multilib.patch \
-           file://perl-configpm-switch.patch \
-           file://native-nopacklist.patch \
-           file://native-perlinc.patch \
-           file://MM_Unix.pm.patch \
-           file://debian/errno_ver.diff \
-           file://dynaloaderhack.patch \
-           file://perl-PathTools-don-t-filter-out-blib-from-INC.patch \
-           file://0001-Configure-Remove-fstack-protector-strong-for-native-.patch \
-           file://perl-5.26.1-guard_old_libcrypt_fix.patch \
-          "
-
-SRC_URI[md5sum] = "af6a84c7c3e2b8b269c105a5db2f6d53"
-SRC_URI[sha256sum] = "03a77bac4505c270f1890ece75afc7d4b555090b41aa41ea478747e23b2afb3f"
-
-inherit native
-
-NATIVE_PACKAGE_PATH_SUFFIX = "/${PN}"
-
-export LD="${CCLD}"
-
-do_configure () {
-	./Configure \
-		-Dcc="${CC}" \
-		-Dcflags="${CFLAGS}" \
-		-Dldflags="${LDFLAGS}" \
-		-Dlddlflags="${LDFLAGS} -shared" \
-		-Dcf_by="Open Embedded" \
-		-Dprefix=${prefix} \
-		-Dvendorprefix=${prefix} \
-		-Dsiteprefix=${prefix} \
-		\
-		-Dbin=${STAGING_BINDIR}/${PN} \
-		-Dprivlib=${STAGING_LIBDIR}/perl/${PV} \
-		-Darchlib=${STAGING_LIBDIR}/perl/${PV} \
-		-Dvendorlib=${STAGING_LIBDIR}/perl/vendor_perl/${PV} \
-		-Dvendorarch=${STAGING_LIBDIR}/perl/vendor_perl/${PV} \
-		-Dsitelib=${STAGING_LIBDIR}/perl/site_perl/${PV} \
-		-Dsitearch=${STAGING_LIBDIR}/perl/site_perl/${PV} \
-		\
-		-Duseshrplib \
-		-Dusethreads \
-		-Duseithreads \
-		-Duselargefiles \
-		-Dnoextensions=ODBM_File \
-		-Ud_dosuid \
-		-Ui_db \
-		-Ui_ndbm \
-		-Ui_gdbm \
-		-Ui_gdbm_ndbm \
-		-Ui_gdbmndbm \
-		-Di_shadow \
-		-Di_syslog \
-		-Duseperlio \
-		-Dman3ext=3pm \
-		-Dsed=/bin/sed \
-		-Uafs \
-		-Ud_csh \
-		-Uusesfio \
-		-Uusenm -des
-}
-
-do_install () {
-	oe_runmake 'DESTDIR=${D}' install
-
-	# We need a hostperl link for building perl
-	ln -sf perl${PV} ${D}${bindir}/hostperl
-
-        ln -sf perl ${D}${libdir}/perl5
-
-	install -d ${D}${libdir}/perl/${PV}/CORE \
-	           ${D}${datadir}/perl/${PV}/ExtUtils
-
-	# Save native config 
-	install config.sh ${D}${libdir}/perl
-	install lib/Config.pm ${D}${libdir}/perl/${PV}/
-	install lib/ExtUtils/typemap ${D}${libdir}/perl/${PV}/ExtUtils/
-
-	# perl shared library headers
-	# reference perl 5.20.0-1 in debian:
-	# https://packages.debian.org/experimental/i386/perl/filelist
-	for i in av.h bitcount.h charclass_invlists.h config.h cop.h cv.h dosish.h \
-		embed.h embedvar.h EXTERN.h fakesdio.h feature.h form.h git_version.h \
-		gv.h handy.h hv_func.h hv.h inline.h INTERN.h intrpvar.h iperlsys.h \
-		keywords.h l1_char_class_tab.h malloc_ctl.h metaconfig.h mg_data.h \
-		mg.h mg_raw.h mg_vtable.h mydtrace.h nostdio.h opcode.h op.h \
-		opnames.h op_reg_common.h overload.h pad.h parser.h patchlevel.h \
-		perlapi.h perl.h perlio.h perliol.h perlsdio.h perlvars.h perly.h \
-		pp.h pp_proto.h proto.h reentr.h regcharclass.h regcomp.h regexp.h \
-		regnodes.h scope.h sv.h thread.h time64_config.h time64.h uconfig.h \
-		unicode_constants.h unixish.h utf8.h utfebcdic.h util.h uudmap.h \
-		vutil.h warnings.h XSUB.h
-	do
-		install $i ${D}${libdir}/perl/${PV}/CORE
-	done
-
-	# Those wrappers mean that perl installed from sstate (which may change
-	# path location) works and that in the nativesdk case, the SDK can be
-	# installed to a different location from the one it was built for.
-	create_wrapper ${D}${bindir}/perl PERL5LIB='$PERL5LIB:${STAGING_LIBDIR}/perl/site_perl/${PV}:${STAGING_LIBDIR}/perl/vendor_perl/${PV}:${STAGING_LIBDIR}/perl/${PV}'
-	create_wrapper ${D}${bindir}/perl${PV} PERL5LIB='$PERL5LIB:${STAGING_LIBDIR}/perl/site_perl/${PV}:${STAGING_LIBDIR}/perl/vendor_perl/${PV}:${STAGING_LIBDIR}/perl/${PV}'
-
-	# Use /usr/bin/env nativeperl for the perl script.
-	for f in `grep -Il '#! *${bindir}/perl' ${D}/${bindir}/*`; do
-		sed -i -e 's|${bindir}/perl|/usr/bin/env nativeperl|' $f
-	done
-
-	# The packlist is large with hardcoded paths meaning it needs relocating
-	# so just remove it.
-	rm ${D}${libdir}/perl/${PV}/.packlist
-}
-
-SYSROOT_PREPROCESS_FUNCS += "perl_sysroot_create_wrapper"
-
-perl_sysroot_create_wrapper () {
-	mkdir -p ${SYSROOT_DESTDIR}${bindir}
-	# Create a wrapper that /usr/bin/env perl will use to get perl-native.
-	# This MUST live in the normal bindir.
-	cat > ${SYSROOT_DESTDIR}${bindir}/../nativeperl << EOF
-#!/bin/sh
-realpath=\`readlink -fn \$0\`
-exec \`dirname \$realpath\`/perl-native/perl "\$@"
-EOF
-	chmod 0755 ${SYSROOT_DESTDIR}${bindir}/../nativeperl
-	cat ${SYSROOT_DESTDIR}${bindir}/../nativeperl
-}
-
-# Fix the path in sstate
-SSTATE_SCAN_FILES += "*.pm *.pod *.h *.pl *.sh"
-PACKAGES_DYNAMIC_class-native += "^perl-module-.*native$"
-
diff --git a/poky/meta/recipes-devtools/perl/perl-native_5.24.4.bb b/poky/meta/recipes-devtools/perl/perl-native_5.24.4.bb
new file mode 100644
index 0000000..81d3fd48
--- /dev/null
+++ b/poky/meta/recipes-devtools/perl/perl-native_5.24.4.bb
@@ -0,0 +1,140 @@
+require perl.inc
+
+# We need gnugrep (for -I)
+DEPENDS = "db-native grep-native gdbm-native zlib-native"
+
+EXTRA_OEMAKE = "-e MAKEFLAGS="
+
+SRC_URI += "\
+           file://Configure-multilib.patch \
+           file://perl-configpm-switch.patch \
+           file://native-nopacklist.patch \
+           file://native-perlinc.patch \
+           file://MM_Unix.pm.patch \
+           file://debian/errno_ver.diff \
+           file://dynaloaderhack.patch \
+           file://perl-PathTools-don-t-filter-out-blib-from-INC.patch \
+           file://0001-Configure-Remove-fstack-protector-strong-for-native-.patch \
+           file://perl-5.26.1-guard_old_libcrypt_fix.patch \
+           file://0001-ExtUtils-MM_Unix.pm-fix-race-issues.patch \
+          "
+
+SRC_URI[md5sum] = "04622bc4d3941dc7eb571c52b7c02993"
+SRC_URI[sha256sum] = "7f080287ff64750270689843ae945f02159a33cb8f2fc910248c15befba5db84"
+
+inherit native
+
+NATIVE_PACKAGE_PATH_SUFFIX = "/${PN}"
+
+export LD="${CCLD}"
+
+do_configure () {
+	./Configure \
+		-Dcc="${CC}" \
+		-Dcflags="${CFLAGS}" \
+		-Dldflags="${LDFLAGS}" \
+		-Dlddlflags="${LDFLAGS} -shared" \
+		-Dcf_by="Open Embedded" \
+		-Dprefix=${prefix} \
+		-Dvendorprefix=${prefix} \
+		-Dsiteprefix=${prefix} \
+		\
+		-Dbin=${STAGING_BINDIR}/${PN} \
+		-Dprivlib=${STAGING_LIBDIR}/perl/${PV} \
+		-Darchlib=${STAGING_LIBDIR}/perl/${PV} \
+		-Dvendorlib=${STAGING_LIBDIR}/perl/vendor_perl/${PV} \
+		-Dvendorarch=${STAGING_LIBDIR}/perl/vendor_perl/${PV} \
+		-Dsitelib=${STAGING_LIBDIR}/perl/site_perl/${PV} \
+		-Dsitearch=${STAGING_LIBDIR}/perl/site_perl/${PV} \
+		\
+		-Duseshrplib \
+		-Dusethreads \
+		-Duseithreads \
+		-Duselargefiles \
+		-Dnoextensions=ODBM_File \
+		-Ud_dosuid \
+		-Ui_db \
+		-Ui_ndbm \
+		-Ui_gdbm \
+		-Ui_gdbm_ndbm \
+		-Ui_gdbmndbm \
+		-Di_shadow \
+		-Di_syslog \
+		-Duseperlio \
+		-Dman3ext=3pm \
+		-Dsed=/bin/sed \
+		-Uafs \
+		-Ud_csh \
+		-Uusesfio \
+		-Uusenm -des
+}
+
+do_install () {
+	oe_runmake 'DESTDIR=${D}' install
+
+	# We need a hostperl link for building perl
+	ln -sf perl${PV} ${D}${bindir}/hostperl
+
+        ln -sf perl ${D}${libdir}/perl5
+
+	install -d ${D}${libdir}/perl/${PV}/CORE \
+	           ${D}${datadir}/perl/${PV}/ExtUtils
+
+	# Save native config 
+	install config.sh ${D}${libdir}/perl
+	install lib/Config.pm ${D}${libdir}/perl/${PV}/
+	install lib/ExtUtils/typemap ${D}${libdir}/perl/${PV}/ExtUtils/
+
+	# perl shared library headers
+	# reference perl 5.20.0-1 in debian:
+	# https://packages.debian.org/experimental/i386/perl/filelist
+	for i in av.h bitcount.h charclass_invlists.h config.h cop.h cv.h dosish.h \
+		embed.h embedvar.h EXTERN.h fakesdio.h feature.h form.h git_version.h \
+		gv.h handy.h hv_func.h hv.h inline.h INTERN.h intrpvar.h iperlsys.h \
+		keywords.h l1_char_class_tab.h malloc_ctl.h metaconfig.h mg_data.h \
+		mg.h mg_raw.h mg_vtable.h mydtrace.h nostdio.h opcode.h op.h \
+		opnames.h op_reg_common.h overload.h pad.h parser.h patchlevel.h \
+		perlapi.h perl.h perlio.h perliol.h perlsdio.h perlvars.h perly.h \
+		pp.h pp_proto.h proto.h reentr.h regcharclass.h regcomp.h regexp.h \
+		regnodes.h scope.h sv.h thread.h time64_config.h time64.h uconfig.h \
+		unicode_constants.h unixish.h utf8.h utfebcdic.h util.h uudmap.h \
+		vutil.h warnings.h XSUB.h
+	do
+		install $i ${D}${libdir}/perl/${PV}/CORE
+	done
+
+	# Those wrappers mean that perl installed from sstate (which may change
+	# path location) works and that in the nativesdk case, the SDK can be
+	# installed to a different location from the one it was built for.
+	create_wrapper ${D}${bindir}/perl PERL5LIB='$PERL5LIB:${STAGING_LIBDIR}/perl/site_perl/${PV}:${STAGING_LIBDIR}/perl/vendor_perl/${PV}:${STAGING_LIBDIR}/perl/${PV}'
+	create_wrapper ${D}${bindir}/perl${PV} PERL5LIB='$PERL5LIB:${STAGING_LIBDIR}/perl/site_perl/${PV}:${STAGING_LIBDIR}/perl/vendor_perl/${PV}:${STAGING_LIBDIR}/perl/${PV}'
+
+	# Use /usr/bin/env nativeperl for the perl script.
+	for f in `grep -Il '#! *${bindir}/perl' ${D}/${bindir}/*`; do
+		sed -i -e 's|${bindir}/perl|/usr/bin/env nativeperl|' $f
+	done
+
+	# The packlist is large with hardcoded paths meaning it needs relocating
+	# so just remove it.
+	rm ${D}${libdir}/perl/${PV}/.packlist
+}
+
+SYSROOT_PREPROCESS_FUNCS += "perl_sysroot_create_wrapper"
+
+perl_sysroot_create_wrapper () {
+	mkdir -p ${SYSROOT_DESTDIR}${bindir}
+	# Create a wrapper that /usr/bin/env perl will use to get perl-native.
+	# This MUST live in the normal bindir.
+	cat > ${SYSROOT_DESTDIR}${bindir}/../nativeperl << EOF
+#!/bin/sh
+realpath=\`readlink -fn \$0\`
+exec \`dirname \$realpath\`/perl-native/perl "\$@"
+EOF
+	chmod 0755 ${SYSROOT_DESTDIR}${bindir}/../nativeperl
+	cat ${SYSROOT_DESTDIR}${bindir}/../nativeperl
+}
+
+# Fix the path in sstate
+SSTATE_SCAN_FILES += "*.pm *.pod *.h *.pl *.sh"
+
+PACKAGES_DYNAMIC_class-native = "^perl-module-.*native$"
diff --git a/poky/meta/recipes-devtools/perl/perl-ptest.inc b/poky/meta/recipes-devtools/perl/perl-ptest.inc
index 6a7a2d7..8d46448 100644
--- a/poky/meta/recipes-devtools/perl/perl-ptest.inc
+++ b/poky/meta/recipes-devtools/perl/perl-ptest.inc
@@ -50,7 +50,7 @@
             '${PN}-ptest%s', '%s', recursive=True, match_path=True)
 }
 
-RDEPENDS_${PN}-ptest += "${PN}-modules ${PN}-doc ${PN}-misc sed libssp"
+RDEPENDS_${PN}-ptest += "${PN}-modules ${PN}-doc ${PN}-misc sed"
 
 # The perl-ptest package contains Perl internal modules and generating file
 # dependencies for it causes problems.
diff --git a/poky/meta/recipes-devtools/perl/perl-rdepends_5.24.1.inc b/poky/meta/recipes-devtools/perl/perl-rdepends_5.24.4.inc
similarity index 100%
rename from poky/meta/recipes-devtools/perl/perl-rdepends_5.24.1.inc
rename to poky/meta/recipes-devtools/perl/perl-rdepends_5.24.4.inc
diff --git a/poky/meta/recipes-devtools/perl/perl/0001-ExtUtils-MM_Unix.pm-fix-race-issues.patch b/poky/meta/recipes-devtools/perl/perl/0001-ExtUtils-MM_Unix.pm-fix-race-issues.patch
new file mode 100644
index 0000000..a43fbba
--- /dev/null
+++ b/poky/meta/recipes-devtools/perl/perl/0001-ExtUtils-MM_Unix.pm-fix-race-issues.patch
@@ -0,0 +1,52 @@
+From 40702abf3156fa92ef70ee5d445fe52dd6cfbc7d Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Thu, 20 Sep 2018 18:48:48 +0800
+Subject: [PATCH] ExtUtils/MM_Unix.pm: fix race issues
+
+Fixed a race issue when compile libhtml-parser-perl and others who use MakeMaker:
+[snip]
+chmod 755 blib/arch/auto/HTML/Parser/Parser.so 
+chmod 644 "Parser.bs"
+[snip]
+
+The rule INST_DYNAMIC removes '.bs' file which are generated by BOOTSTRAP, but
+the have no dependencies, so there is a race issue:
+
+BOOTSTRAP:
+    touch foo.bs
+    chmod 755 foo.bs
+
+INST_DYNAMIC:
+    rm -fr foo.bs
+
+The error would happen when INST_DYNAMIC removes foo.bs after BOOTSTRAP touched
+it but before chmod on it.
+
+Upstream-Status: Backport [https://github.com/Perl-Toolchain-Gang/ExtUtils-MakeMaker/commit/44e95e717372abe2b0a6ee55de4b686760b65360]
+
+Note, This is not a real backport, upstream has totally refactored it in one
+patch, please see the link above, it's not a good idea to backport such a big
+patch, I just referred it to fix the problem in a simple way. I mark it as
+backport is because we can drop the patch after upgrade perl to 5.26 or 5.28.
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm
+index 95d9761..9cabe2d 100644
+--- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm
++++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm
+@@ -933,7 +933,7 @@ OTHERLDFLAGS = '.$ld_opt.$otherldflags.'
+ INST_DYNAMIC_DEP = '.$inst_dynamic_dep.'
+ INST_DYNAMIC_FIX = '.$ld_fix.'
+ 
+-$(INST_DYNAMIC): $(OBJECT) $(MYEXTLIB) $(INST_ARCHAUTODIR)$(DFSEP).exists $(EXPORT_LIST) $(PERL_ARCHIVEDEP) $(PERL_ARCHIVE_AFTER) $(INST_DYNAMIC_DEP)
++$(INST_DYNAMIC): $(OBJECT) $(MYEXTLIB) $(INST_ARCHAUTODIR)$(DFSEP).exists $(EXPORT_LIST) $(PERL_ARCHIVEDEP) $(PERL_ARCHIVE_AFTER) $(INST_DYNAMIC_DEP) $(BOOTSTRAP)
+ ');
+     if ($armaybe ne ':'){
+ 	$ldfrom = 'tmp$(LIB_EXT)';
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/perl/perl/CVE-2017-12837.patch b/poky/meta/recipes-devtools/perl/perl/CVE-2017-12837.patch
deleted file mode 100644
index 0b59fcd..0000000
--- a/poky/meta/recipes-devtools/perl/perl/CVE-2017-12837.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From 73d7247ecab863ef26b5687a37ccc75d6144ad0f Mon Sep 17 00:00:00 2001
-From: Karl Williamson <khw@cpan.org>
-Date: Tue, 17 Oct 2017 13:49:14 +0800
-Subject: [PATCH] fix CVE-2017-12837
-
-Signed-off-by: Karl Williamson <khw@cpan.org>
-Signed-off-by: Steve Hay <steve.m.hay@googlemail.com>
-
-CVE: CVE-2017-12837
-Upstream-Status: Backport
-https://perl5.git.perl.org/perl.git/commitdiff/96c83ed78aeea1a0496dd2b2d935869a822dc8a5
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- regcomp.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/regcomp.c b/regcomp.c
-index 5498d14..31ec383 100644
---- a/regcomp.c
-+++ b/regcomp.c
-@@ -13021,6 +13021,7 @@ S_regatom(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth)
-                             goto loopdone;
-                         }
-                         p = RExC_parse;
-+                        RExC_parse = parse_start;
-                         if (ender > 0xff) {
-                             REQUIRE_UTF8(flagp);
-                         }
--- 
-1.8.3.1
-
diff --git a/poky/meta/recipes-devtools/perl/perl/CVE-2017-12883.patch b/poky/meta/recipes-devtools/perl/perl/CVE-2017-12883.patch
deleted file mode 100644
index 5c1805f..0000000
--- a/poky/meta/recipes-devtools/perl/perl/CVE-2017-12883.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From 40b3cdad3649334585cee8f4630ec9a025e62be6 Mon Sep 17 00:00:00 2001
-From: Karl Williamson <khw@cpan.org>
-Date: Fri, 25 Aug 2017 11:33:58 -0600
-Subject: [PATCH] PATCH: [perl #131598]
-
-The cause of this is that the vFAIL macro uses RExC_parse, and that
-variable has just been changed in preparation for code after the vFAIL.
-The solution is to not change RExC_parse until after the vFAIL.
-
-This is a case where the macro hides stuff that can bite you.
-
-(cherry picked from commit 2be4edede4ae226e2eebd4eff28cedd2041f300f)
-
-Upstream-Status: Backport
-CVE: CVE-2017-12833
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- regcomp.c | 6 ++++--
- 1 file changed, 4 insertions(+), 2 deletions(-)
-
-Index: perl-5.24.1/regcomp.c
-===================================================================
---- perl-5.24.1.orig/regcomp.c
-+++ perl-5.24.1/regcomp.c
-@@ -11918,14 +11918,16 @@ S_grok_bslash_N(pTHX_ RExC_state_t *pREx
- 	}
-         sv_catpv(substitute_parse, ")");
- 
--        RExC_parse = RExC_start = RExC_adjusted_start = SvPV(substitute_parse,
--                                                             len);
-+        len = SvCUR(substitute_parse);
- 
- 	/* Don't allow empty number */
- 	if (len < (STRLEN) 8) {
-             RExC_parse = endbrace;
- 	    vFAIL("Invalid hexadecimal number in \\N{U+...}");
- 	}
-+
-+        RExC_parse = RExC_start = RExC_adjusted_start
-+                                              = SvPV_nolen(substitute_parse);
- 	RExC_end = RExC_parse + len;
- 
-         /* The values are Unicode, and therefore not subject to recoding, but
diff --git a/poky/meta/recipes-devtools/perl/perl/CVE-2018-6797.patch b/poky/meta/recipes-devtools/perl/perl/CVE-2018-6797.patch
deleted file mode 100644
index b56ebd3..0000000
--- a/poky/meta/recipes-devtools/perl/perl/CVE-2018-6797.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-From abe1e6c568b96bcb382dfa4f61c56d1ab001ea51 Mon Sep 17 00:00:00 2001
-From: Karl Williamson <khw@cpan.org>
-Date: Fri, 2 Feb 2018 15:14:27 -0700
-Subject: [PATCH] (perl #132227) restart a node if we change to uni rules
- within the node and encounter a sharp S
-
-This could lead to a buffer overflow.
-
-(cherry picked from commit a02c70e35d1313a5f4e245e8f863c810e991172d)
-
-CVE: CVE-2018-6797
-Upstream-Status: Backport [https://perl5.git.perl.org/perl.git/commitdiff/abe1e6c568b96bcb382dfa4f61c56d1ab001ea51]
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- regcomp.c | 12 ++++++++++++
- 1 file changed, 12 insertions(+)
-
-diff --git a/regcomp.c b/regcomp.c
-index 3b9550b10d..a7dee9a09e 100644
---- a/regcomp.c
-+++ b/regcomp.c
-@@ -13543,6 +13543,18 @@ S_regatom(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth)
-                          * /u.  This includes the multi-char fold SHARP S to
-                          * 'ss' */
-                         if (UNLIKELY(ender == LATIN_SMALL_LETTER_SHARP_S)) {
-+
-+                            /* If the node started out having uni rules, we
-+                             * wouldn't have gotten here.  So this means
-+                             * something in the middle has changed it, but
-+                             * didn't think it needed to reparse.  But this
-+                             * sharp s now does indicate the need for
-+                             * reparsing. */
-+                            if (RExC_uni_semantics) {
-+                                p = oldp;
-+                                goto loopdone;
-+                            }
-+
-                             RExC_seen_unfolded_sharp_s = 1;
-                             maybe_exactfu = FALSE;
-                         }
--- 
-2.15.1-424-g9478a660812
-
-
diff --git a/poky/meta/recipes-devtools/perl/perl/CVE-2018-6798-1.patch b/poky/meta/recipes-devtools/perl/perl/CVE-2018-6798-1.patch
deleted file mode 100644
index 3477162..0000000
--- a/poky/meta/recipes-devtools/perl/perl/CVE-2018-6798-1.patch
+++ /dev/null
@@ -1,130 +0,0 @@
-From 0abf1e8d89aecd32dbdabda5da4d52a2d57a7cff Mon Sep 17 00:00:00 2001
-From: Karl Williamson <khw@cpan.org>
-Date: Tue, 6 Feb 2018 14:50:48 -0700
-Subject: [PATCH] [perl #132063]: Heap buffer overflow
-
-The proximal cause is several instances in regexec.c of the code
-assuming that the input was valid UTF-8, whereas the input was too short
-for what the start byte claimed it would be.
-
-I grepped through the core for any other similar uses, and did not find
-any.
-
-(cherry picked from commit fe7d8ba0a1bf567af8fa8fea128e2b9f4c553e84)
-
-CVE: CVE-2018-6798
-Upstream-Status: Backport [https://perl5.git.perl.org/perl.git/patch/0abf1e8d89aecd32dbdabda5da4d52a2d57a7cff]
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- regexec.c              | 29 ++++++++++++++++-------------
- t/lib/warnings/regexec |  7 +++++++
- 2 files changed, 23 insertions(+), 13 deletions(-)
-
-diff --git a/regexec.c b/regexec.c
-index 5735b997fd..ea432c39d3 100644
---- a/regexec.c
-+++ b/regexec.c
-@@ -1466,7 +1466,9 @@ Perl_re_intuit_start(pTHX_
-                                            ? trie_utf8_fold                         \
-                                            :   trie_latin_utf8_fold)))
- 
--#define REXEC_TRIE_READ_CHAR(trie_type, trie, widecharmap, uc, uscan, len, uvc, charid, foldlen, foldbuf, uniflags) \
-+/* 'uscan' is set to foldbuf, and incremented, so below the end of uscan is
-+ * 'foldbuf+sizeof(foldbuf)' */
-+#define REXEC_TRIE_READ_CHAR(trie_type, trie, widecharmap, uc, uc_end, uscan, len, uvc, charid, foldlen, foldbuf, uniflags) \
- STMT_START {                                                                        \
-     STRLEN skiplen;                                                                 \
-     U8 flags = FOLD_FLAGS_FULL;                                                     \
-@@ -1474,7 +1476,7 @@ STMT_START {
-     case trie_flu8:                                                                 \
-         _CHECK_AND_WARN_PROBLEMATIC_LOCALE;                                         \
-         if (utf8_target && UTF8_IS_ABOVE_LATIN1(*uc)) {                             \
--            _CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG(uc, uc + UTF8SKIP(uc));          \
-+            _CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG(uc, uc_end - uc);                \
-         }                                                                           \
-         goto do_trie_utf8_fold;                                                     \
-     case trie_utf8_exactfa_fold:                                                    \
-@@ -1483,7 +1485,7 @@ STMT_START {
-     case trie_utf8_fold:                                                            \
-       do_trie_utf8_fold:                                                            \
-         if ( foldlen>0 ) {                                                          \
--            uvc = utf8n_to_uvchr( (const U8*) uscan, UTF8_MAXLEN, &len, uniflags ); \
-+            uvc = utf8n_to_uvchr( (const U8*) uscan, foldlen, &len, uniflags );     \
-             foldlen -= len;                                                         \
-             uscan += len;                                                           \
-             len=0;                                                                  \
-@@ -1500,7 +1502,7 @@ STMT_START {
-         /* FALLTHROUGH */                                                           \
-     case trie_latin_utf8_fold:                                                      \
-         if ( foldlen>0 ) {                                                          \
--            uvc = utf8n_to_uvchr( (const U8*) uscan, UTF8_MAXLEN, &len, uniflags ); \
-+            uvc = utf8n_to_uvchr( (const U8*) uscan, foldlen, &len, uniflags );     \
-             foldlen -= len;                                                         \
-             uscan += len;                                                           \
-             len=0;                                                                  \
-@@ -1519,7 +1521,7 @@ STMT_START {
-         }                                                                           \
-         /* FALLTHROUGH */                                                           \
-     case trie_utf8:                                                                 \
--        uvc = utf8n_to_uvchr( (const U8*) uc, UTF8_MAXLEN, &len, uniflags );        \
-+        uvc = utf8n_to_uvchr( (const U8*) uc, uc_end - uc, &len, uniflags );        \
-         break;                                                                      \
-     case trie_plain:                                                                \
-         uvc = (UV)*uc;                                                              \
-@@ -2599,10 +2601,10 @@ S_find_byclass(pTHX_ regexp * prog, const regnode *c, char *s,
-                     }
-                     points[pointpos++ % maxlen]= uc;
-                     if (foldlen || uc < (U8*)strend) {
--                        REXEC_TRIE_READ_CHAR(trie_type, trie,
--                                         widecharmap, uc,
--                                         uscan, len, uvc, charid, foldlen,
--                                         foldbuf, uniflags);
-+                        REXEC_TRIE_READ_CHAR(trie_type, trie, widecharmap, uc,
-+                                             (U8 *) strend, uscan, len, uvc,
-+                                             charid, foldlen, foldbuf,
-+                                             uniflags);
-                         DEBUG_TRIE_EXECUTE_r({
-                             dump_exec_pos( (char *)uc, c, strend,
-                                         real_start, s, utf8_target, 0);
-@@ -5511,8 +5513,9 @@ S_regmatch(pTHX_ regmatch_info *reginfo, char *startpos, regnode *prog)
- 		    if ( base && (foldlen || uc < (U8*)(reginfo->strend))) {
- 			I32 offset;
- 			REXEC_TRIE_READ_CHAR(trie_type, trie, widecharmap, uc,
--					     uscan, len, uvc, charid, foldlen,
--					     foldbuf, uniflags);
-+                                             (U8 *) reginfo->strend, uscan,
-+                                             len, uvc, charid, foldlen,
-+                                             foldbuf, uniflags);
- 			charcount++;
- 			if (foldlen>0)
- 			    ST.longfold = TRUE;
-@@ -5642,8 +5645,8 @@ S_regmatch(pTHX_ regmatch_info *reginfo, char *startpos, regnode *prog)
- 			while (foldlen) {
- 			    if (!--chars)
- 				break;
--			    uvc = utf8n_to_uvchr(uscan, UTF8_MAXLEN, &len,
--					    uniflags);
-+			    uvc = utf8n_to_uvchr(uscan, foldlen, &len,
-+                                                 uniflags);
- 			    uscan += len;
- 			    foldlen -= len;
- 			}
-diff --git a/t/lib/warnings/regexec b/t/lib/warnings/regexec
-index 900dd6ee7f..6635142dea 100644
---- a/t/lib/warnings/regexec
-+++ b/t/lib/warnings/regexec
-@@ -260,3 +260,10 @@ setlocale(&POSIX::LC_CTYPE, $utf8_locale);
- "k" =~ /(?[ \N{KELVIN SIGN} ])/i;
- ":" =~ /(?[ \: ])/;
- EXPECT
-+########
-+# NAME perl #132063, read beyond buffer end
-+# OPTION fatal
-+"\xff" =~ /(?il)\x{100}|\x{100}/;
-+EXPECT
-+Malformed UTF-8 character: \xff (too short; 1 byte available, need 13) in pattern match (m//) at - line 2.
-+Malformed UTF-8 character (fatal) at - line 2.
--- 
-2.15.1-424-g9478a660812
-
diff --git a/poky/meta/recipes-devtools/perl/perl/CVE-2018-6798-2.patch b/poky/meta/recipes-devtools/perl/perl/CVE-2018-6798-2.patch
deleted file mode 100644
index fb9b41a..0000000
--- a/poky/meta/recipes-devtools/perl/perl/CVE-2018-6798-2.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From f65da1ca2eee74696d9c120e9d69af37b4fa1920 Mon Sep 17 00:00:00 2001
-From: Tony Cook <tony@develop-help.com>
-Date: Mon, 19 Feb 2018 15:11:42 +1100
-Subject: [PATCH] (perl #132063) we should no longer warn for this code
-
-The first patch for 132063 prevented the buffer read overflow when
-dumping the warning but didn't fix the underlying problem.
-
-The next change treats the supplied buffer correctly, preventing the
-non-UTF-8 SV from being treated as UTF-8, preventing the warning.
-
-(cherry picked from commit 1e8b61488f195e1396aa801c685340b156104f4f)
-
-CVE: CVE-2018-6798
-Upstream-Status: Backport [https://perl5.git.perl.org/perl.git/commitdiff/f65da1ca2eee74696d9c120e9d69af37b4fa1920]
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- t/lib/warnings/regexec | 3 ---
- 1 file changed, 3 deletions(-)
-
-diff --git a/t/lib/warnings/regexec b/t/lib/warnings/regexec
-index 6635142dea..c370ddc3c7 100644
---- a/t/lib/warnings/regexec
-+++ b/t/lib/warnings/regexec
-@@ -262,8 +262,5 @@ setlocale(&POSIX::LC_CTYPE, $utf8_locale);
- EXPECT
- ########
- # NAME perl #132063, read beyond buffer end
--# OPTION fatal
- "\xff" =~ /(?il)\x{100}|\x{100}/;
- EXPECT
--Malformed UTF-8 character: \xff (too short; 1 byte available, need 13) in pattern match (m//) at - line 2.
--Malformed UTF-8 character (fatal) at - line 2.
--- 
-2.15.1-424-g9478a660812
-
diff --git a/poky/meta/recipes-devtools/perl/perl/CVE-2018-6913.patch b/poky/meta/recipes-devtools/perl/perl/CVE-2018-6913.patch
deleted file mode 100644
index 157af7b..0000000
--- a/poky/meta/recipes-devtools/perl/perl/CVE-2018-6913.patch
+++ /dev/null
@@ -1,153 +0,0 @@
-From f17fed5006177dce8ac48229c424a2da0d6ba492 Mon Sep 17 00:00:00 2001
-From: Tony Cook <tony@develop-help.com>
-Date: Tue, 8 Aug 2017 09:32:58 +1000
-Subject: [PATCH] (perl #131844) fix various space calculation issues in
- pp_pack.c
-
-- for the originally reported case, if the start/cur pointer is in the
-  top 75% of the address space the add (cur) + glen addition would
-  overflow, resulting in the condition failing incorrectly.
-
-- the addition of the existing space used to the space needed could
-  overflow, resulting in too small an allocation and a buffer overflow.
-
-- the scaling for UTF8 could overflow.
-
-- the multiply to calculate the space needed for many items could
-  overflow.
-
-For the first case, do a space calculation without making new pointers.
-
-For the other cases, detect the overflow and croak if there's an
-overflow.
-
-Originally this used Size_t_MAX as the maximum size of a memory
-allocation, but for -DDEBUGGING builds realloc() throws a panic for
-allocations over half the address space in size, changing the error
-reported for the allocation.
-
-For non-DEBUGGING builds the Size_t_MAX limit has the small chance
-of finding a system that has 3GB of contiguous space available, and
-allocating that space, which could be a denial of servce in some cases.
-
-Unfortunately changing the limit to half the address space means that
-the exact case with the original issue can no longer occur, so the
-test is no longer testing against the address + length issue that
-caused the original problem, since the allocation is failing earlier.
-
-One option would be to change the test so the size request by pack is
-just under 2GB, but this has a higher (but still low) probability that
-the system has the address space available, and will actually try to
-allocate the memory, so let's not do that.
-
-Note: changed 
-plan tests => 14713;
-to 
-plan tests => 14712;
-in a/t/op/pack.t
-to apply this patch on perl 5.24.1.
-
-CVE: CVE-2018-6913
-Upstream-Status: Backport [https://perl5.git.perl.org/perl.git/commitdiff/f17fed5006177dce8ac48229c424a2da0d6ba492]
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- pp_pack.c   | 25 +++++++++++++++++++++----
- t/op/pack.t | 24 +++++++++++++++++++++++-
- 2 files changed, 44 insertions(+), 5 deletions(-)
-
-diff --git a/pp_pack.c b/pp_pack.c
-index 8937d6d715..5e9cc64301 100644
---- a/pp_pack.c
-+++ b/pp_pack.c
-@@ -357,11 +357,28 @@ STMT_START {							\
-     }								\
- } STMT_END
- 
-+#define SAFE_UTF8_EXPAND(var)	\
-+STMT_START {				\
-+    if ((var) > SSize_t_MAX / UTF8_EXPAND) \
-+        Perl_croak(aTHX_ "%s", "Out of memory during pack()"); \
-+    (var) = (var) * UTF8_EXPAND; \
-+} STMT_END
-+
-+#define GROWING2(utf8, cat, start, cur, item_size, item_count)	\
-+STMT_START {							\
-+    if (SSize_t_MAX / (item_size) < (item_count))		\
-+        Perl_croak(aTHX_ "%s", "Out of memory during pack()");	\
-+    GROWING((utf8), (cat), (start), (cur), (item_size) * (item_count)); \
-+} STMT_END
-+
- #define GROWING(utf8, cat, start, cur, in_len)	\
- STMT_START {					\
-     STRLEN glen = (in_len);			\
--    if (utf8) glen *= UTF8_EXPAND;		\
--    if ((cur) + glen >= (start) + SvLEN(cat)) {	\
-+    STRLEN catcur = (STRLEN)((cur) - (start));	\
-+    if (utf8) SAFE_UTF8_EXPAND(glen);		\
-+    if (SSize_t_MAX - glen < catcur)		\
-+        Perl_croak(aTHX_ "%s", "Out of memory during pack()"); \
-+    if (catcur + glen >= SvLEN(cat)) {	\
- 	(start) = sv_exp_grow(cat, glen);	\
- 	(cur) = (start) + SvCUR(cat);		\
-     }						\
-@@ -372,7 +389,7 @@ STMT_START {					\
- STMT_START {					\
-     const STRLEN glen = (in_len);		\
-     STRLEN gl = glen;				\
--    if (utf8) gl *= UTF8_EXPAND;		\
-+    if (utf8) SAFE_UTF8_EXPAND(gl);		\
-     if ((cur) + gl >= (start) + SvLEN(cat)) {	\
-         *cur = '\0';				\
-         SvCUR_set((cat), (cur) - (start));	\
-@@ -2126,7 +2143,7 @@ S_pack_rec(pTHX_ SV *cat, tempsym_t* sym
- 	    if (props && !(props & PACK_SIZE_UNPREDICTABLE)) {
- 		/* We can process this letter. */
- 		STRLEN size = props & PACK_SIZE_MASK;
--		GROWING(utf8, cat, start, cur, (STRLEN) len * size);
-+		GROWING2(utf8, cat, start, cur, size, (STRLEN)len);
- 	    }
-         }
- 
-diff --git a/t/op/pack.t b/t/op/pack.t
-index 664aaaf1b0..cf0e286509 100644
---- a/t/op/pack.t
-+++ b/t/op/pack.t
-@@ -12,7 +12,7 @@ my $no_endianness = $] > 5.009 ? '' :
- my $no_signedness = $] > 5.009 ? '' :
-   "Signed/unsigned pack modifiers not available on this perl";
- 
--plan tests => 14712;
-+plan tests => 14717;
- 
- use strict;
- use warnings qw(FATAL all);
-@@ -2044,3 +2044,25 @@ ok(1, "argument underflow did not crash"
-     is(pack("H40", $up_nul), $twenty_nuls,
-        "check pack H zero fills (utf8 source)");
- }
-+
-+SKIP:
-+{
-+  # [perl #131844] pointer addition overflow
-+    $Config{ptrsize} == 4
-+      or skip "[perl #131844] need 32-bit build for this test", 4;
-+    # prevent ASAN just crashing on the allocation failure
-+    local $ENV{ASAN_OPTIONS} = $ENV{ASAN_OPTIONS};
-+    $ENV{ASAN_OPTIONS} .= ",allocator_may_return_null=1";
-+    fresh_perl_like('pack "f999999999"', qr/Out of memory during pack/, { stderr => 1 },
-+		    "pointer addition overflow");
-+
-+    # integer (STRLEN) overflow from addition of glen to current length
-+    fresh_perl_like('pack "c10f1073741823"', qr/Out of memory during pack/, { stderr => 1 },
-+		    "integer overflow calculating allocation (addition)");
-+
-+    fresh_perl_like('pack "W10f536870913", 256', qr/Out of memory during pack/, { stderr => 1 },
-+		    "integer overflow calculating allocation (utf8)");
-+
-+    fresh_perl_like('pack "c10f1073741824"', qr/Out of memory during pack/, { stderr => 1 },
-+		    "integer overflow calculating allocation (multiply)");
-+}
--- 
-2.15.1-424-g9478a660812
-
diff --git a/poky/meta/recipes-devtools/perl/perl/Makefile.SH.patch b/poky/meta/recipes-devtools/perl/perl/Makefile.SH.patch
index c1db335..e4c3426 100644
--- a/poky/meta/recipes-devtools/perl/perl/Makefile.SH.patch
+++ b/poky/meta/recipes-devtools/perl/perl/Makefile.SH.patch
@@ -12,10 +12,10 @@
  Makefile.SH | 147 ++++++++++++++++++++++++++++--------------------------------
  1 file changed, 68 insertions(+), 79 deletions(-)
 
-Index: perl-5.24.1/Makefile.SH
+Index: perl-5.24.4/Makefile.SH
 ===================================================================
---- perl-5.24.1.orig/Makefile.SH
-+++ perl-5.24.1/Makefile.SH
+--- perl-5.24.4.orig/Makefile.SH
++++ perl-5.24.4/Makefile.SH
 @@ -48,10 +48,10 @@ case "$useshrplib" in
  true)
  	# Prefix all runs of 'miniperl' and 'perl' with
@@ -271,9 +271,9 @@
  	$(MINIPERL) autodoc.pl
  
  pod/perlmodlib.pod: $(MINIPERL_EXE) pod/perlmodlib.PL MANIFEST
-@@ -1089,7 +1099,7 @@ pod/perl5241delta.pod: pod/perldelta.pod
- 	$(RMS) pod/perl5241delta.pod
- 	$(LNS) perldelta.pod pod/perl5241delta.pod
+@@ -1089,7 +1099,7 @@ pod/perl5244delta.pod: pod/perldelta.pod
+ 	$(RMS) pod/perl5244delta.pod
+ 	$(LNS) perldelta.pod pod/perl5244delta.pod
  
 -extra.pods: $(MINIPERL_EXE)
 +extra.pods:
diff --git a/poky/meta/recipes-devtools/perl/perl/config.sh b/poky/meta/recipes-devtools/perl/perl/config.sh
index ac0484c..b1b5834 100644
--- a/poky/meta/recipes-devtools/perl/perl/config.sh
+++ b/poky/meta/recipes-devtools/perl/perl/config.sh
@@ -14,7 +14,7 @@
 
 : Configure command line arguments.
 config_arg0='Configure'
-config_args='-des -Doptimize=-O2 -Dmyhostname=localhost -Dperladmin=root@localhost -Dcc=gcc -Dcf_by=Open Embedded -Dinstallprefix=@EXECPREFIX@ -Dprefix=@EXECPREFIX@ -Dvendorprefix=@EXECPREFIX@ -Dsiteprefix=@EXECPREFIX@ -Dotherlibdirs=@LIBDIR@/perl/5.24.1 -Duseshrplib -Dusethreads -Duseithreads -Duselargefiles -Ud_dosuid -Dd_semctl_semun -Ui_db -Ui_ndbm -Ui_gdbm -Di_shadow -Di_syslog -Dman3ext=3pm -Duseperlio -Dinstallusrbinperl -Ubincompat5005 -Uversiononly -Dpager=@USRBIN@/less -isr'
+config_args='-des -Doptimize=-O2 -Dmyhostname=localhost -Dperladmin=root@localhost -Dcc=gcc -Dcf_by=Open Embedded -Dinstallprefix=@EXECPREFIX@ -Dprefix=@EXECPREFIX@ -Dvendorprefix=@EXECPREFIX@ -Dsiteprefix=@EXECPREFIX@ -Dotherlibdirs=@LIBDIR@/perl/5.24.4 -Duseshrplib -Dusethreads -Duseithreads -Duselargefiles -Ud_dosuid -Dd_semctl_semun -Ui_db -Ui_ndbm -Ui_gdbm -Di_shadow -Di_syslog -Dman3ext=3pm -Duseperlio -Dinstallusrbinperl -Ubincompat5005 -Uversiononly -Dpager=@USRBIN@/less -isr'
 config_argc=28
 config_arg1='-des'
 config_arg2='-Doptimize=-O2'
@@ -26,7 +26,7 @@
 config_arg8='-Dprefix=@EXECPREFIX@'
 config_arg9='-Dvendorprefix=@EXECPREFIX@'
 config_arg10='-Dsiteprefix=@EXECPREFIX@'
-config_arg11='-Dotherlibdirs=@LIBDIR@/perl/5.24.1'
+config_arg11='-Dotherlibdirs=@LIBDIR@/perl/5.24.4'
 config_arg12='-Duseshrplib'
 config_arg13='-Dusethreads'
 config_arg14='-Duseithreads'
@@ -64,13 +64,13 @@
 ansi2knr=''
 aphostname=''
 api_revision='5'
-api_subversion='1'
+api_subversion='4'
 api_version='24'
-api_versionstring='5.24.1'
+api_versionstring='5.24.4'
 ar='ar'
-archlib='@LIBDIR@/perl/5.24.1/@ARCH@-thread-multi'
-archlibexp='@STAGINGDIR@@LIBDIR@/perl/5.24.1/@ARCH@-thread-multi'
-archlib_exp='@LIBDIR@/perl/5.24.1/@ARCH@-thread-multi'
+archlib='@LIBDIR@/perl/5.24.4/@ARCH@-thread-multi'
+archlibexp='@STAGINGDIR@@LIBDIR@/perl/5.24.4/@ARCH@-thread-multi'
+archlib_exp='@LIBDIR@/perl/5.24.4/@ARCH@-thread-multi'
 archname64=''
 archname='@ARCH@-thread-multi'
 archobjs=''
@@ -88,7 +88,7 @@
 cat='cat'
 cc='gcc'
 cccdlflags='-fPIC'
-ccdlflags='-Wl,-E -Wl,-rpath,@LIBDIR@/perl/5.24.1/@ARCH@-thread-multi/CORE'
+ccdlflags='-Wl,-E -Wl,-rpath,@LIBDIR@/perl/5.24.4/@ARCH@-thread-multi/CORE'
 ccflags='-D_REENTRANT -D_GNU_SOURCE -fwrapv -fno-strict-aliasing -pipe -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2'
 ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64'
 ccname='gcc'
@@ -838,7 +838,7 @@
 incpath=''
 inews=''
 initialinstalllocation='@USRBIN@'
-installarchlib='@LIBDIR@/perl/5.24.1/@ARCH@-thread-multi'
+installarchlib='@LIBDIR@/perl/5.24.4/@ARCH@-thread-multi'
 installbin='@USRBIN@'
 installhtml1dir=''
 installhtml3dir=''
@@ -846,23 +846,23 @@
 installman3dir=''
 installprefix='@EXECPREFIX@'
 installprefixexp='@EXECPREFIX@'
-installprivlib='@LIBDIR@/perl/5.24.1'
+installprivlib='@LIBDIR@/perl/5.24.4'
 installscript='@USRBIN@'
-installsitearch='@LIBDIR@/perl/site_perl/5.24.1/@ARCH@-thread-multi'
+installsitearch='@LIBDIR@/perl/site_perl/5.24.4/@ARCH@-thread-multi'
 installsitebin='@USRBIN@'
 installsitehtml1dir=''
 installsitehtml3dir=''
-installsitelib='@LIBDIR@/perl/site_perl/5.24.1'
+installsitelib='@LIBDIR@/perl/site_perl/5.24.4'
 installsiteman1dir=''
 installsiteman3dir=''
 installsitescript='@USRBIN@'
 installstyle='lib/perl'
 installusrbinperl='define'
-installvendorarch='@LIBDIR@/perl/vendor_perl/5.24.1/@ARCH@-thread-multi'
+installvendorarch='@LIBDIR@/perl/vendor_perl/5.24.4/@ARCH@-thread-multi'
 installvendorbin='@USRBIN@'
 installvendorhtml1dir=''
 installvendorhtml3dir=''
-installvendorlib='@LIBDIR@/perl/vendor_perl/5.24.1'
+installvendorlib='@LIBDIR@/perl/vendor_perl/5.24.4'
 installvendorman1dir=''
 installvendorman3dir=''
 installvendorscript='@USRBIN@'
@@ -965,7 +965,7 @@
 orderlib='false'
 osname='linux'
 osvers='3.19.5-yocto-standard'
-otherlibdirs='@LIBDIR@/perl/5.24.1'
+otherlibdirs='@LIBDIR@/perl/5.24.4'
 package='perl'
 pager='/usr/bin/less -isr'
 passcat='cat /etc/passwd'
@@ -986,8 +986,8 @@
 pr=''
 prefix='@EXECPREFIX@'
 prefixexp='@EXECPREFIX@'
-privlib='@LIBDIR@/perl/5.24.1'
-privlibexp='@LIBDIR@/perl/5.24.1'
+privlib='@LIBDIR@/perl/5.24.4'
+privlibexp='@LIBDIR@/perl/5.24.4'
 procselfexe='"/proc/self/exe"'
 prototype='define'
 ptrsize='8'
@@ -1053,17 +1053,17 @@
 sig_num_init='0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 6, 17, 29, 31, 0'
 sig_size='69'
 signal_t='void'
-sitearch='@LIBDIR@/perl/site_perl/5.24.1/@ARCH@-thread-multi'
-sitearchexp='@LIBDIR@/perl/site_perl/5.24.1/@ARCH@-thread-multi'
+sitearch='@LIBDIR@/perl/site_perl/5.24.4/@ARCH@-thread-multi'
+sitearchexp='@LIBDIR@/perl/site_perl/5.24.4/@ARCH@-thread-multi'
 sitebin='@USRBIN@'
 sitebinexp='@USRBIN@'
 sitehtml1dir=''
 sitehtml1direxp=''
 sitehtml3dir=''
 sitehtml3direxp=''
-sitelib='@LIBDIR@/perl/site_perl/5.24.1'
+sitelib='@LIBDIR@/perl/site_perl/5.24.4'
 sitelib_stem='@LIBDIR@/perl/site_perl'
-sitelibexp='@LIBDIR@/perl/site_perl/5.24.1'
+sitelibexp='@LIBDIR@/perl/site_perl/5.24.4'
 siteman1dir=''
 siteman1direxp=''
 siteman3dir=''
@@ -1102,7 +1102,7 @@
 strerror_r_proto='REENTRANT_PROTO_B_IBW'
 strings='@INCLUDEDIR@/string.h'
 submit=''
-subversion='1'
+subversion='4'
 sysman='@EXECPREFIX@/share/man/man1'
 sysroot=''
 tail=''
@@ -1182,17 +1182,17 @@
 uvuformat='"lu"'
 uvxformat='"lx"'
 vaproto='define'
-vendorarch='@LIBDIR@/perl/vendor_perl/5.24.1/@ARCH@-thread-multi'
-vendorarchexp='@LIBDIR@/perl/vendor_perl/5.24.1/@ARCH@-thread-multi'
+vendorarch='@LIBDIR@/perl/vendor_perl/5.24.4/@ARCH@-thread-multi'
+vendorarchexp='@LIBDIR@/perl/vendor_perl/5.24.4/@ARCH@-thread-multi'
 vendorbin='@USRBIN@'
 vendorbinexp='@USRBIN@'
 vendorhtml1dir=' '
 vendorhtml1direxp=''
 vendorhtml3dir=' '
 vendorhtml3direxp=''
-vendorlib='@LIBDIR@/perl/vendor_perl/5.24.1'
+vendorlib='@LIBDIR@/perl/vendor_perl/5.24.4'
 vendorlib_stem='@LIBDIR@/perl/vendor_perl'
-vendorlibexp='@LIBDIR@/perl/vendor_perl/5.24.1'
+vendorlibexp='@LIBDIR@/perl/vendor_perl/5.24.4'
 vendorman1dir=' '
 vendorman1direxp=''
 vendorman3dir=' '
@@ -1201,8 +1201,8 @@
 vendorprefixexp='@EXECPREFIX@'
 vendorscript='@USRBIN@'
 vendorscriptexp='@USRBIN@'
-version='5.24.1'
-version_patchlevel_string='version 24 subversion 1'
+version='5.24.4'
+version_patchlevel_string='version 24 subversion 4'
 versiononly='undef'
 vi=''
 xlibpth='@LIBDIR@/386 @BASELIBDIR@386'
@@ -1212,10 +1212,10 @@
 zip='zip'
 PERL_REVISION=5
 PERL_VERSION=24
-PERL_SUBVERSION=1
+PERL_SUBVERSION=4
 PERL_API_REVISION=5
 PERL_API_VERSION=24
-PERL_API_SUBVERSION=1
+PERL_API_SUBVERSION=4
 PERL_PATCHLEVEL=''
 PERL_CONFIG_SH=true
 : Variables propagated from previous config.sh file.
diff --git a/poky/meta/recipes-devtools/perl/perl_5.24.1.bb b/poky/meta/recipes-devtools/perl/perl_5.24.1.bb
deleted file mode 100644
index 6e33bb0..0000000
--- a/poky/meta/recipes-devtools/perl/perl_5.24.1.bb
+++ /dev/null
@@ -1,358 +0,0 @@
-require perl.inc
-
-# We need gnugrep (for -I)
-DEPENDS = "db grep-native gdbm zlib virtual/crypt"
-
-# Pick up patches from debian
-# http://ftp.de.debian.org/debian/pool/main/p/perl/perl_5.22.0-1.debian.tar.xz
-SRC_URI += " \
-	file://debian/cpan_definstalldirs.diff \
-	file://debian/db_file_ver.diff \
-	file://debian/doc_info.diff \
-	file://debian/enc2xs_inc.diff \
-	file://debian/errno_ver.diff \
-	file://debian/libperl_embed_doc.diff \
-	file://debian/fixes/respect_umask.diff \
-	file://debian/writable_site_dirs.diff \
-	file://debian/extutils_set_libperl_path.diff \
-	file://debian/no_packlist_perllocal.diff \
-	file://debian/prefix_changes.diff \
-	file://debian/instmodsh_doc.diff \
-	file://debian/ld_run_path.diff \
-	file://debian/libnet_config_path.diff \
-	file://debian/mod_paths.diff \
-	file://debian/prune_libs.diff \
-	file://debian/fixes/net_smtp_docs.diff \
-	file://debian/perlivp.diff \
-	file://debian/squelch-locale-warnings.diff \
-	file://debian/skip-upstream-git-tests.diff \
-	file://debian/skip-kfreebsd-crash.diff \
-	file://debian/fixes/document_makemaker_ccflags.diff \
-	file://debian/find_html2text.diff \
-	file://debian/perl5db-x-terminal-emulator.patch \
-	file://debian/cpan-missing-site-dirs.diff \
-	file://debian/fixes/memoize_storable_nstore.diff \
-	file://debian/regen-skip.diff \
-"
-
-SRC_URI += " \
-        file://Makefile.patch \
-        file://Makefile.SH.patch \
-        file://installperl.patch \
-        file://perl-archlib-exp.patch \
-        file://perl-dynloader.patch \
-        file://perl-moreconfig.patch \
-        file://letgcc-find-errno.patch \
-        file://generate-sh.patch \
-        file://native-perlinc.patch \
-        file://cross-generate_uudmap.patch \
-        file://fix_bad_rpath.patch \
-        file://dynaloaderhack.patch \
-        file://config.sh \
-        file://config.sh-32 \
-        file://config.sh-32-le \
-        file://config.sh-32-be \
-        file://config.sh-64 \
-        file://config.sh-64-le \
-        file://config.sh-64-be \
-        file://make_ext.pl-fix-regenerate-makefile-failed-while-cc-.patch \
-        file://t-run-switches.t-perl5-perl.patch \
-        file://ext-ODBM_File-hints-linux.pl-link-libgdbm_compat.patch \
-        file://ext-ODBM_File-t-odbm.t-fix-the-path-of-dbmt_common.p.patch \
-        file://perl-PathTools-don-t-filter-out-blib-from-INC.patch \
-        file://perl-errno-generation-gcc5.patch \
-        file://perl-fix-conflict-between-skip_all-and-END.patch \
-        file://perl-5.26.1-guard_old_libcrypt_fix.patch \
-        file://CVE-2017-12883.patch \
-        file://CVE-2017-12837.patch \
-        file://CVE-2018-6798-1.patch \
-        file://CVE-2018-6798-2.patch \
-        file://CVE-2018-6797.patch \
-        file://CVE-2018-6913.patch \
-        file://CVE-2018-12015.patch \
-"
-
-# Fix test case issues
-SRC_URI_append_class-target = " \
-            file://test/dist-threads-t-join.t-adjust-ps-option.patch \
-            file://test/ext-DynaLoader-t-DynaLoader.t-fix-calling-dl_findfil.patch \
-            file://0001-Skip-various-tests-if-PERL_BUILD_PACKAGING-is-set.patch \
-           "
-
-SRC_URI[md5sum] = "af6a84c7c3e2b8b269c105a5db2f6d53"
-SRC_URI[sha256sum] = "03a77bac4505c270f1890ece75afc7d4b555090b41aa41ea478747e23b2afb3f"
-
-inherit perlnative siteinfo
-
-# Where to find the native perl
-HOSTPERL = "${STAGING_BINDIR_NATIVE}/perl-native/perl${PV}"
-
-# Where to find .so files - use the -native versions not those from the target build
-export PERLHOSTLIB = "${STAGING_LIBDIR_NATIVE}/perl-native/perl/${PV}/"
-
-# Where to find perl @INC/#include files
-# - use the -native versions not those from the target build
-export PERL_LIB = "${STAGING_LIBDIR_NATIVE}/perl-native/perl/${PV}/"
-export PERL_ARCHLIB = "${STAGING_LIBDIR_NATIVE}/perl-native/perl/${PV}/"
-
-EXTRA_OEMAKE = "-e MAKEFLAGS="
-
-# LDFLAGS for shared libraries
-export LDDLFLAGS = "${LDFLAGS} -shared"
-
-LDFLAGS_append = " -fstack-protector"
-
-# We're almost Debian, aren't we?
-CFLAGS += "-DDEBIAN"
-
-do_configure() {
-        # Make hostperl in build directory be the native perl
-        ln -sf ${HOSTPERL} hostperl
-
-	if [ -n "${CONFIGURESTAMPFILE}" -a -e "${CONFIGURESTAMPFILE}" ]; then
-		if [ "`cat ${CONFIGURESTAMPFILE}`" != "${BB_TASKHASH}" -a -e Makefile ]; then
-			${MAKE} clean
-		fi
-		find ${S} -name *.so -delete
-	fi
-	if [ -n "${CONFIGURESTAMPFILE}" ]; then
-		echo ${BB_TASKHASH} > ${CONFIGURESTAMPFILE}
-	fi
-
-        # Do our work in the cross subdir
-        cd Cross
-
-        # Generate configuration
-        rm -f config.sh-${TARGET_ARCH}-${TARGET_OS}
-        for i in ${WORKDIR}/config.sh \
-                 ${WORKDIR}/config.sh-${SITEINFO_BITS} \
-                 ${WORKDIR}/config.sh-${SITEINFO_BITS}-${SITEINFO_ENDIANNESS}; do
-            cat $i >> config.sh-${TARGET_ARCH}-${TARGET_OS}
-        done
-
-        # Fixups for musl
-        if [ "${TARGET_OS}" = "linux-musl" -o "${TARGET_OS}" = "linux-musleabi" -o "${TARGET_OS}" = "linux-muslx32" ]; then
-                sed -i -e "s,\(d_libm_lib_version=\)'define',\1'undef',g" \
-                       -e "s,\(d_stdio_ptr_lval=\)'define',\1'undef',g" \
-                       -e "s,\(d_stdio_ptr_lval_sets_cnt=\)'define',\1'undef',g" \
-                       -e "s,\(d_stdiobase=\)'define',\1'undef',g" \
-                       -e "s,\(d_stdstdio=\)'define',\1'undef',g" \
-                       -e "s,\(d_getnetbyname_r=\)'define',\1'undef',g" \
-                       -e "s,\(d_finitel=\)'define',\1'undef',g" \
-                       -e "s,\(getprotobyname_r=\)'define',\1'undef',g" \
-                       -e "s,\(getpwent_r=\)'define',\1'undef',g" \
-                       -e "s,\(getservent_r=\)'define',\1'undef',g" \
-                       -e "s,\(gethostent_r=\)'define',\1'undef',g" \
-                       -e "s,\(getnetent_r=\)'define',\1'undef',g" \
-                       -e "s,\(getnetbyaddr_r=\)'define',\1'undef',g" \
-                       -e "s,\(getprotoent_r=\)'define',\1'undef',g" \
-                       -e "s,\(getprotobynumber_r=\)'define',\1'undef',g" \
-                       -e "s,\(getgrent_r=\)'define',\1'undef',g" \
-                       -e "s,\(i_fcntl=\)'undef',\1'define',g" \
-                       -e "s,\(h_fcntl=\)'false',\1'true',g" \
-                       -e "s,-fstack-protector,-fno-stack-protector,g" \
-                       -e "s,-lnsl,,g" \
-                    config.sh-${TARGET_ARCH}-${TARGET_OS}
-        fi
-
-        # Update some paths in the configuration
-        sed -i -e 's,@ARCH@-thread-multi,,g' \
-               -e 's,@ARCH@,${TARGET_ARCH}-${TARGET_OS},g' \
-               -e 's,@STAGINGDIR@,${STAGING_DIR_HOST},g' \
-               -e "s,@INCLUDEDIR@,${STAGING_INCDIR},g" \
-               -e "s,@LIBDIR@,${libdir},g" \
-               -e "s,@BASELIBDIR@,${base_libdir},g" \
-               -e "s,@EXECPREFIX@,${exec_prefix},g" \
-               -e 's,@USRBIN@,${bindir},g' \
-            config.sh-${TARGET_ARCH}-${TARGET_OS}
-
-	case "${TARGET_ARCH}" in
-		x86_64 | powerpc | s390)
-			sed -i -e "s,\(need_va_copy=\)'undef',\1'define',g" \
-				config.sh-${TARGET_ARCH}-${TARGET_OS}
-			;;
-		arm)
-			sed -i -e "s,\(d_u32align=\)'undef',\1'define',g" \
-				config.sh-${TARGET_ARCH}-${TARGET_OS}
-			;;
-	esac
-        # These are strewn all over the source tree
-        for foo in `grep -I --exclude="*.patch" --exclude="*.diff" --exclude="*.pod" --exclude="README*" --exclude="Glossary" -m1 "/usr/include/.*\.h" ${S}/* -r -l` ${S}/utils/h2xs.PL ; do
-            echo Fixing: $foo
-            sed -e 's|\([ "^'\''I]\+\)/usr/include/|\1${STAGING_INCDIR}/|g' -i $foo
-        done
-
-        rm -f config
-        echo "ARCH = ${TARGET_ARCH}" > config
-        echo "OS = ${TARGET_OS}" >> config
-}
-
-do_compile() {
-        # Fix to avoid recursive substitution of path
-        sed -i -e 's|(@libpath, ".*"|(@libpath, "${STAGING_LIBDIR}"|g' cpan/ExtUtils-MakeMaker/lib/ExtUtils/Liblist/Kid.pm
-
-        cd Cross
-        oe_runmake perl LD="${CCLD}"
-}
-
-do_compile_append_class-target() {
-        # Remove build host references from numerous comments...
-        find "${S}/cpan/Encode" -type f \
-            \( -name '*.exh' -o -name '*.c' -o -name '*.h' \)\
-            -exec sed -i -e 's:${RECIPE_SYSROOT_NATIVE}::g' {} +
-        sed -i -e 's:${RECIPE_SYSROOT}::g' ${S}/perl.h ${S}/pp.h
-        sed -i -e 's:${RECIPE_SYSROOT_NATIVE}/usr/bin/perl-native/perl${PV}.real:/usr/bin/perl${PV}:g'  \
-            ${S}/cpan/Compress-Raw-Bzip2/constants.h \
-            ${S}/cpan/Compress-Raw-Zlib/constants.h \
-            ${S}/cpan/IPC-SysV/const-c.inc \
-            ${S}/dist/Time-HiRes/const-c.inc
-}
-
-do_install() {
-	#export hostperl="${STAGING_BINDIR_NATIVE}/perl-native/perl${PV}"
-	oe_runmake install DESTDIR=${D}
-        # Add perl pointing at current version
-        ln -sf perl${PV} ${D}${bindir}/perl
-
-        ln -sf perl ${D}/${libdir}/perl5
-
-        # Remove unwanted file and empty directories
-        rm -f ${D}/${libdir}/perl/${PV}/.packlist
-	rmdir ${D}/${libdir}/perl/site_perl/${PV}
-	rmdir ${D}/${libdir}/perl/site_perl
-
-        # Fix up shared library
-        mv ${D}/${libdir}/perl/${PV}/CORE/libperl.so ${D}/${libdir}/libperl.so.${PV}
-        ln -sf libperl.so.${PV} ${D}/${libdir}/libperl.so.5
-        ln -sf ../../../libperl.so.${PV} ${D}/${libdir}/perl/${PV}/CORE/libperl.so
-
-        # target config, used by cpan.bbclass to extract version information
-        install config.sh ${D}${libdir}/perl
-
-        ln -s Config_heavy.pl ${D}${libdir}/perl/${PV}/Config_heavy-target.pl
-}
-
-do_install_append_class-nativesdk () {
-        create_wrapper ${D}${bindir}/perl \
-            PERL5LIB='$PERL5LIB:$OECORE_NATIVE_SYSROOT/${libdir_nativesdk}/perl/site_perl/${PV}:$OECORE_NATIVE_SYSROOT/${libdir_nativesdk}/perl/vendor_perl/${PV}:$OECORE_NATIVE_SYSROOT/${libdir_nativesdk}/perl/${PV}'
-}
-
-PACKAGE_PREPROCESS_FUNCS += "perl_package_preprocess"
-
-perl_package_preprocess () {
-        # Fix up installed configuration
-        sed -i -e "s,${D},,g" \
-               -e "s,${DEBUG_PREFIX_MAP},,g" \
-               -e "s,--sysroot=${STAGING_DIR_HOST},,g" \
-               -e "s,-isystem${STAGING_INCDIR} ,,g" \
-               -e "s,${STAGING_LIBDIR},${libdir},g" \
-               -e "s,${STAGING_BINDIR},${bindir},g" \
-               -e "s,${STAGING_INCDIR},${includedir},g" \
-               -e "s,${STAGING_BINDIR_NATIVE}/perl-native/,${bindir}/,g" \
-               -e "s,${STAGING_BINDIR_NATIVE}/,,g" \
-               -e "s,${STAGING_BINDIR_TOOLCHAIN}/${TARGET_PREFIX},${bindir},g" \
-               -e 's:${RECIPE_SYSROOT}::g' \
-            ${PKGD}${bindir}/h2xs \
-            ${PKGD}${bindir}/h2ph \
-            ${PKGD}${bindir}/pod2man \
-            ${PKGD}${bindir}/pod2text \
-            ${PKGD}${bindir}/pod2usage \
-            ${PKGD}${bindir}/podchecker \
-            ${PKGD}${bindir}/podselect \
-            ${PKGD}${libdir}/perl/${PV}/CORE/config.h \
-            ${PKGD}${libdir}/perl/${PV}/CORE/perl.h \
-            ${PKGD}${libdir}/perl/${PV}/CORE/pp.h \
-            ${PKGD}${libdir}/perl/${PV}/Config.pm \
-            ${PKGD}${libdir}/perl/${PV}/Config.pod \
-            ${PKGD}${libdir}/perl/${PV}/Config_heavy.pl \
-            ${PKGD}${libdir}/perl/${PV}/ExtUtils/Liblist/Kid.pm \
-            ${PKGD}${libdir}/perl/${PV}/FileCache.pm \
-            ${PKGD}${libdir}/perl/${PV}/pod/*.pod \
-            ${PKGD}${libdir}/perl/config.sh
-}
-
-PACKAGES = "perl-dbg perl perl-misc perl-dev perl-pod perl-doc perl-lib \
-            perl-module-cpan perl-module-cpanplus perl-module-unicore"
-FILES_${PN} = "${bindir}/perl ${bindir}/perl${PV} \
-               ${libdir}/perl/${PV}/Config.pm \
-               ${libdir}/perl/${PV}/strict.pm \
-               ${libdir}/perl/${PV}/warnings.pm \
-               ${libdir}/perl/${PV}/warnings \
-               ${libdir}/perl/${PV}/vars.pm \
-              "
-FILES_${PN}_append_class-nativesdk = " ${bindir}/perl.real"
-RPROVIDES_${PN} += "perl-module-strict perl-module-vars perl-module-config perl-module-warnings \
-                    perl-module-warnings-register"
-FILES_${PN}-dev = "${libdir}/perl/${PV}/CORE"
-FILES_${PN}-lib = "${libdir}/libperl.so* \
-                   ${libdir}/perl5 \
-                   ${libdir}/perl/config.sh \
-		   ${libdir}/perl/${PV}/Config_git.pl \
-                   ${libdir}/perl/${PV}/Config_heavy.pl \
-                   ${libdir}/perl/${PV}/Config_heavy-target.pl"
-FILES_${PN}-pod = "${libdir}/perl/${PV}/pod \
-		   ${libdir}/perl/${PV}/*.pod \
-                   ${libdir}/perl/${PV}/*/*.pod \
-                   ${libdir}/perl/${PV}/*/*/*.pod "
-FILES_perl-misc = "${bindir}/*"
-FILES_${PN}-doc = "${libdir}/perl/${PV}/*/*.txt \
-                   ${libdir}/perl/${PV}/*/*/*.txt \
-                   ${libdir}/perl/${PV}/auto/XS/Typemap \
-                   ${libdir}/perl/${PV}/B/assemble \
-                   ${libdir}/perl/${PV}/B/cc_harness \
-                   ${libdir}/perl/${PV}/B/disassemble \
-                   ${libdir}/perl/${PV}/B/makeliblinks \
-                   ${libdir}/perl/${PV}/CGI/eg \
-                   ${libdir}/perl/${PV}/CPAN/PAUSE2003.pub \
-                   ${libdir}/perl/${PV}/CPAN/SIGNATURE \
-		   ${libdir}/perl/${PV}/CPANPLUS/Shell/Default/Plugins/HOWTO.pod \
-                   ${libdir}/perl/${PV}/Encode/encode.h \
-                   ${libdir}/perl/${PV}/ExtUtils/MANIFEST.SKIP \
-                   ${libdir}/perl/${PV}/ExtUtils/NOTES \
-                   ${libdir}/perl/${PV}/ExtUtils/PATCHING \
-                   ${libdir}/perl/${PV}/ExtUtils/typemap \
-                   ${libdir}/perl/${PV}/ExtUtils/xsubpp \
-		   ${libdir}/perl/${PV}/ExtUtils/Changes_EU-Install \
-                   ${libdir}/perl/${PV}/Net/*.eg \
-                   ${libdir}/perl/${PV}/unicore/mktables \
-                   ${libdir}/perl/${PV}/unicore/mktables.lst \
-                   ${libdir}/perl/${PV}/unicore/version "
-
-FILES_perl-module-cpan += "${libdir}/perl/${PV}/CPAN \
-                           ${libdir}/perl/${PV}/CPAN.pm"
-FILES_perl-module-cpanplus += "${libdir}/perl/${PV}/CPANPLUS \
-                               ${libdir}/perl/${PV}/CPANPLUS.pm"
-FILES_perl-module-unicore += "${libdir}/perl/${PV}/unicore"
-
-# Create a perl-modules package recommending all the other perl
-# packages (actually the non modules packages and not created too)
-ALLOW_EMPTY_perl-modules = "1"
-PACKAGES_append = " perl-modules "
-
-PACKAGESPLITFUNCS_prepend = "split_perl_packages "
-
-python split_perl_packages () {
-    libdir = d.expand('${libdir}/perl/${PV}')
-    do_split_packages(d, libdir, 'auto/([^.]*)/[^/]*\.(so|ld|ix|al)', 'perl-module-%s', 'perl module %s', recursive=True, match_path=True, prepend=False)
-    do_split_packages(d, libdir, 'Module/([^\/]*)\.pm', 'perl-module-%s', 'perl module %s', recursive=True, allow_dirs=False, match_path=True, prepend=False)
-    do_split_packages(d, libdir, 'Module/([^\/]*)/.*', 'perl-module-%s', 'perl module %s', recursive=True, allow_dirs=False, match_path=True, prepend=False)
-    do_split_packages(d, libdir, '(^(?!(CPAN\/|CPANPLUS\/|Module\/|unicore\/|auto\/)[^\/]).*)\.(pm|pl|e2x)', 'perl-module-%s', 'perl module %s', recursive=True, allow_dirs=False, match_path=True, prepend=False)
-
-    # perl-modules should recommend every perl module, and only the
-    # modules. Don't attempt to use the result of do_split_packages() as some
-    # modules are manually split (eg. perl-module-unicore).
-    packages = filter(lambda p: 'perl-module-' in p, d.getVar('PACKAGES').split())
-    d.setVar(d.expand("RRECOMMENDS_${PN}-modules"), ' '.join(packages))
-}
-
-PACKAGES_DYNAMIC += "^perl-module-.*(?<!\-native)$"
-PACKAGES_DYNAMIC_class-nativesdk += "^nativesdk-perl-module-.*"
-
-RPROVIDES_perl-lib = "perl-lib"
-
-require perl-rdepends_${PV}.inc
-require perl-ptest.inc
-
-SSTATE_SCAN_FILES += "*.pm *.pod *.h *.pl *.sh"
-
-BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-devtools/perl/perl_5.24.4.bb b/poky/meta/recipes-devtools/perl/perl_5.24.4.bb
new file mode 100644
index 0000000..a644970
--- /dev/null
+++ b/poky/meta/recipes-devtools/perl/perl_5.24.4.bb
@@ -0,0 +1,353 @@
+require perl.inc
+
+# We need gnugrep (for -I)
+DEPENDS = "db grep-native gdbm zlib virtual/crypt"
+
+# Pick up patches from debian
+# http://ftp.de.debian.org/debian/pool/main/p/perl/perl_5.22.0-1.debian.tar.xz
+SRC_URI += " \
+	file://debian/cpan_definstalldirs.diff \
+	file://debian/db_file_ver.diff \
+	file://debian/doc_info.diff \
+	file://debian/enc2xs_inc.diff \
+	file://debian/errno_ver.diff \
+	file://debian/libperl_embed_doc.diff \
+	file://debian/fixes/respect_umask.diff \
+	file://debian/writable_site_dirs.diff \
+	file://debian/extutils_set_libperl_path.diff \
+	file://debian/no_packlist_perllocal.diff \
+	file://debian/prefix_changes.diff \
+	file://debian/instmodsh_doc.diff \
+	file://debian/ld_run_path.diff \
+	file://debian/libnet_config_path.diff \
+	file://debian/mod_paths.diff \
+	file://debian/prune_libs.diff \
+	file://debian/fixes/net_smtp_docs.diff \
+	file://debian/perlivp.diff \
+	file://debian/squelch-locale-warnings.diff \
+	file://debian/skip-upstream-git-tests.diff \
+	file://debian/skip-kfreebsd-crash.diff \
+	file://debian/fixes/document_makemaker_ccflags.diff \
+	file://debian/find_html2text.diff \
+	file://debian/perl5db-x-terminal-emulator.patch \
+	file://debian/cpan-missing-site-dirs.diff \
+	file://debian/fixes/memoize_storable_nstore.diff \
+	file://debian/regen-skip.diff \
+"
+
+SRC_URI += " \
+        file://Makefile.patch \
+        file://Makefile.SH.patch \
+        file://installperl.patch \
+        file://perl-archlib-exp.patch \
+        file://perl-dynloader.patch \
+        file://perl-moreconfig.patch \
+        file://letgcc-find-errno.patch \
+        file://generate-sh.patch \
+        file://native-perlinc.patch \
+        file://cross-generate_uudmap.patch \
+        file://fix_bad_rpath.patch \
+        file://dynaloaderhack.patch \
+        file://config.sh \
+        file://config.sh-32 \
+        file://config.sh-32-le \
+        file://config.sh-32-be \
+        file://config.sh-64 \
+        file://config.sh-64-le \
+        file://config.sh-64-be \
+        file://make_ext.pl-fix-regenerate-makefile-failed-while-cc-.patch \
+        file://t-run-switches.t-perl5-perl.patch \
+        file://ext-ODBM_File-hints-linux.pl-link-libgdbm_compat.patch \
+        file://ext-ODBM_File-t-odbm.t-fix-the-path-of-dbmt_common.p.patch \
+        file://perl-PathTools-don-t-filter-out-blib-from-INC.patch \
+        file://perl-errno-generation-gcc5.patch \
+        file://perl-fix-conflict-between-skip_all-and-END.patch \
+        file://perl-5.26.1-guard_old_libcrypt_fix.patch \
+        file://CVE-2018-12015.patch \
+        file://0001-ExtUtils-MM_Unix.pm-fix-race-issues.patch \
+"
+
+# Fix test case issues
+SRC_URI_append_class-target = " \
+            file://test/dist-threads-t-join.t-adjust-ps-option.patch \
+            file://test/ext-DynaLoader-t-DynaLoader.t-fix-calling-dl_findfil.patch \
+            file://0001-Skip-various-tests-if-PERL_BUILD_PACKAGING-is-set.patch \
+           "
+
+SRC_URI[md5sum] = "04622bc4d3941dc7eb571c52b7c02993"
+SRC_URI[sha256sum] = "7f080287ff64750270689843ae945f02159a33cb8f2fc910248c15befba5db84"
+
+inherit perlnative siteinfo
+
+# Where to find the native perl
+HOSTPERL = "${STAGING_BINDIR_NATIVE}/perl-native/perl${PV}"
+
+# Where to find .so files - use the -native versions not those from the target build
+export PERLHOSTLIB = "${STAGING_LIBDIR_NATIVE}/perl-native/perl/${PV}/"
+
+# Where to find perl @INC/#include files
+# - use the -native versions not those from the target build
+export PERL_LIB = "${STAGING_LIBDIR_NATIVE}/perl-native/perl/${PV}/"
+export PERL_ARCHLIB = "${STAGING_LIBDIR_NATIVE}/perl-native/perl/${PV}/"
+
+EXTRA_OEMAKE = "-e MAKEFLAGS="
+
+# LDFLAGS for shared libraries
+export LDDLFLAGS = "${LDFLAGS} -shared"
+
+LDFLAGS_append = " -fstack-protector"
+
+# We're almost Debian, aren't we?
+CFLAGS += "-DDEBIAN"
+
+do_configure() {
+        # Make hostperl in build directory be the native perl
+        ln -sf ${HOSTPERL} hostperl
+
+	if [ -n "${CONFIGURESTAMPFILE}" -a -e "${CONFIGURESTAMPFILE}" ]; then
+		if [ "`cat ${CONFIGURESTAMPFILE}`" != "${BB_TASKHASH}" -a -e Makefile ]; then
+			${MAKE} clean
+		fi
+		find ${S} -name *.so -delete
+	fi
+	if [ -n "${CONFIGURESTAMPFILE}" ]; then
+		echo ${BB_TASKHASH} > ${CONFIGURESTAMPFILE}
+	fi
+
+        # Do our work in the cross subdir
+        cd Cross
+
+        # Generate configuration
+        rm -f config.sh-${TARGET_ARCH}-${TARGET_OS}
+        for i in ${WORKDIR}/config.sh \
+                 ${WORKDIR}/config.sh-${SITEINFO_BITS} \
+                 ${WORKDIR}/config.sh-${SITEINFO_BITS}-${SITEINFO_ENDIANNESS}; do
+            cat $i >> config.sh-${TARGET_ARCH}-${TARGET_OS}
+        done
+
+        # Fixups for musl
+        if [ "${TARGET_OS}" = "linux-musl" -o "${TARGET_OS}" = "linux-musleabi" -o "${TARGET_OS}" = "linux-muslx32" ]; then
+                sed -i -e "s,\(d_libm_lib_version=\)'define',\1'undef',g" \
+                       -e "s,\(d_stdio_ptr_lval=\)'define',\1'undef',g" \
+                       -e "s,\(d_stdio_ptr_lval_sets_cnt=\)'define',\1'undef',g" \
+                       -e "s,\(d_stdiobase=\)'define',\1'undef',g" \
+                       -e "s,\(d_stdstdio=\)'define',\1'undef',g" \
+                       -e "s,\(d_getnetbyname_r=\)'define',\1'undef',g" \
+                       -e "s,\(d_finitel=\)'define',\1'undef',g" \
+                       -e "s,\(getprotobyname_r=\)'define',\1'undef',g" \
+                       -e "s,\(getpwent_r=\)'define',\1'undef',g" \
+                       -e "s,\(getservent_r=\)'define',\1'undef',g" \
+                       -e "s,\(gethostent_r=\)'define',\1'undef',g" \
+                       -e "s,\(getnetent_r=\)'define',\1'undef',g" \
+                       -e "s,\(getnetbyaddr_r=\)'define',\1'undef',g" \
+                       -e "s,\(getprotoent_r=\)'define',\1'undef',g" \
+                       -e "s,\(getprotobynumber_r=\)'define',\1'undef',g" \
+                       -e "s,\(getgrent_r=\)'define',\1'undef',g" \
+                       -e "s,\(i_fcntl=\)'undef',\1'define',g" \
+                       -e "s,\(h_fcntl=\)'false',\1'true',g" \
+                       -e "s,-fstack-protector,-fno-stack-protector,g" \
+                    config.sh-${TARGET_ARCH}-${TARGET_OS}
+        fi
+
+        # Update some paths in the configuration
+        sed -i -e 's,@ARCH@-thread-multi,,g' \
+               -e 's,@ARCH@,${TARGET_ARCH}-${TARGET_OS},g' \
+               -e 's,@STAGINGDIR@,${STAGING_DIR_HOST},g' \
+               -e "s,@INCLUDEDIR@,${STAGING_INCDIR},g" \
+               -e "s,@LIBDIR@,${libdir},g" \
+               -e "s,@BASELIBDIR@,${base_libdir},g" \
+               -e "s,@EXECPREFIX@,${exec_prefix},g" \
+               -e 's,@USRBIN@,${bindir},g' \
+               -e "s,-lnsl,,g" \
+            config.sh-${TARGET_ARCH}-${TARGET_OS}
+
+	case "${TARGET_ARCH}" in
+		x86_64 | powerpc | s390)
+			sed -i -e "s,\(need_va_copy=\)'undef',\1'define',g" \
+				config.sh-${TARGET_ARCH}-${TARGET_OS}
+			;;
+		arm)
+			sed -i -e "s,\(d_u32align=\)'undef',\1'define',g" \
+				config.sh-${TARGET_ARCH}-${TARGET_OS}
+			;;
+	esac
+        # These are strewn all over the source tree
+        for foo in `grep -I --exclude="*.patch" --exclude="*.diff" --exclude="*.pod" --exclude="README*" --exclude="Glossary" -m1 "/usr/include/.*\.h" ${S}/* -r -l` ${S}/utils/h2xs.PL ; do
+            echo Fixing: $foo
+            sed -e 's|\([ "^'\''I]\+\)/usr/include/|\1${STAGING_INCDIR}/|g' -i $foo
+        done
+
+        rm -f config
+        echo "ARCH = ${TARGET_ARCH}" > config
+        echo "OS = ${TARGET_OS}" >> config
+}
+
+do_compile() {
+        # Fix to avoid recursive substitution of path
+        sed -i -e 's|(@libpath, ".*"|(@libpath, "${STAGING_LIBDIR}"|g' cpan/ExtUtils-MakeMaker/lib/ExtUtils/Liblist/Kid.pm
+
+        cd Cross
+        oe_runmake perl LD="${CCLD}"
+}
+
+do_compile_append_class-target() {
+        # Remove build host references from numerous comments...
+        find "${S}/cpan/Encode" -type f \
+            \( -name '*.exh' -o -name '*.c' -o -name '*.h' \)\
+            -exec sed -i -e 's:${RECIPE_SYSROOT_NATIVE}::g' {} +
+        sed -i -e 's:${RECIPE_SYSROOT}::g' ${S}/perl.h ${S}/pp.h
+        sed -i -e 's:${RECIPE_SYSROOT_NATIVE}/usr/bin/perl-native/perl${PV}.real:/usr/bin/perl${PV}:g'  \
+            ${S}/cpan/Compress-Raw-Bzip2/constants.h \
+            ${S}/cpan/Compress-Raw-Zlib/constants.h \
+            ${S}/cpan/IPC-SysV/const-c.inc \
+            ${S}/dist/Time-HiRes/const-c.inc
+}
+
+do_install() {
+	#export hostperl="${STAGING_BINDIR_NATIVE}/perl-native/perl${PV}"
+	oe_runmake install DESTDIR=${D}
+        # Add perl pointing at current version
+        ln -sf perl${PV} ${D}${bindir}/perl
+
+        ln -sf perl ${D}/${libdir}/perl5
+
+        # Remove unwanted file and empty directories
+        rm -f ${D}/${libdir}/perl/${PV}/.packlist
+	rmdir ${D}/${libdir}/perl/site_perl/${PV}
+	rmdir ${D}/${libdir}/perl/site_perl
+
+        # Fix up shared library
+        mv ${D}/${libdir}/perl/${PV}/CORE/libperl.so ${D}/${libdir}/libperl.so.${PV}
+        ln -sf libperl.so.${PV} ${D}/${libdir}/libperl.so.5
+        ln -sf ../../../libperl.so.${PV} ${D}/${libdir}/perl/${PV}/CORE/libperl.so
+
+        # target config, used by cpan.bbclass to extract version information
+        install config.sh ${D}${libdir}/perl
+
+        ln -s Config_heavy.pl ${D}${libdir}/perl/${PV}/Config_heavy-target.pl
+}
+
+do_install_append_class-nativesdk () {
+        create_wrapper ${D}${bindir}/perl \
+            PERL5LIB='$PERL5LIB:$OECORE_NATIVE_SYSROOT/${libdir_nativesdk}/perl/site_perl/${PV}:$OECORE_NATIVE_SYSROOT/${libdir_nativesdk}/perl/vendor_perl/${PV}:$OECORE_NATIVE_SYSROOT/${libdir_nativesdk}/perl/${PV}'
+}
+
+PACKAGE_PREPROCESS_FUNCS += "perl_package_preprocess"
+
+perl_package_preprocess () {
+        # Fix up installed configuration
+        sed -i -e "s,${D},,g" \
+               -e "s,${DEBUG_PREFIX_MAP},,g" \
+               -e "s,--sysroot=${STAGING_DIR_HOST},,g" \
+               -e "s,-isystem${STAGING_INCDIR} ,,g" \
+               -e "s,${STAGING_LIBDIR},${libdir},g" \
+               -e "s,${STAGING_BINDIR},${bindir},g" \
+               -e "s,${STAGING_INCDIR},${includedir},g" \
+               -e "s,${STAGING_BINDIR_NATIVE}/perl-native/,${bindir}/,g" \
+               -e "s,${STAGING_BINDIR_NATIVE}/,,g" \
+               -e "s,${STAGING_BINDIR_TOOLCHAIN}/${TARGET_PREFIX},${bindir},g" \
+               -e 's:${RECIPE_SYSROOT}::g' \
+            ${PKGD}${bindir}/h2xs \
+            ${PKGD}${bindir}/h2ph \
+            ${PKGD}${bindir}/pod2man \
+            ${PKGD}${bindir}/pod2text \
+            ${PKGD}${bindir}/pod2usage \
+            ${PKGD}${bindir}/podchecker \
+            ${PKGD}${bindir}/podselect \
+            ${PKGD}${libdir}/perl/${PV}/CORE/config.h \
+            ${PKGD}${libdir}/perl/${PV}/CORE/perl.h \
+            ${PKGD}${libdir}/perl/${PV}/CORE/pp.h \
+            ${PKGD}${libdir}/perl/${PV}/Config.pm \
+            ${PKGD}${libdir}/perl/${PV}/Config.pod \
+            ${PKGD}${libdir}/perl/${PV}/Config_heavy.pl \
+            ${PKGD}${libdir}/perl/${PV}/ExtUtils/Liblist/Kid.pm \
+            ${PKGD}${libdir}/perl/${PV}/FileCache.pm \
+            ${PKGD}${libdir}/perl/${PV}/pod/*.pod \
+            ${PKGD}${libdir}/perl/config.sh
+}
+
+PACKAGES = "perl-dbg perl perl-misc perl-dev perl-pod perl-doc perl-lib \
+            perl-module-cpan perl-module-cpanplus perl-module-unicore"
+FILES_${PN} = "${bindir}/perl ${bindir}/perl${PV} \
+               ${libdir}/perl/${PV}/Config.pm \
+               ${libdir}/perl/${PV}/strict.pm \
+               ${libdir}/perl/${PV}/warnings.pm \
+               ${libdir}/perl/${PV}/warnings \
+               ${libdir}/perl/${PV}/vars.pm \
+              "
+FILES_${PN}_append_class-nativesdk = " ${bindir}/perl.real"
+RPROVIDES_${PN} += "perl-module-strict perl-module-vars perl-module-config perl-module-warnings \
+                    perl-module-warnings-register"
+FILES_${PN}-dev = "${libdir}/perl/${PV}/CORE"
+FILES_${PN}-lib = "${libdir}/libperl.so* \
+                   ${libdir}/perl5 \
+                   ${libdir}/perl/config.sh \
+		   ${libdir}/perl/${PV}/Config_git.pl \
+                   ${libdir}/perl/${PV}/Config_heavy.pl \
+                   ${libdir}/perl/${PV}/Config_heavy-target.pl"
+FILES_${PN}-pod = "${libdir}/perl/${PV}/pod \
+		   ${libdir}/perl/${PV}/*.pod \
+                   ${libdir}/perl/${PV}/*/*.pod \
+                   ${libdir}/perl/${PV}/*/*/*.pod "
+FILES_perl-misc = "${bindir}/*"
+FILES_${PN}-doc = "${libdir}/perl/${PV}/*/*.txt \
+                   ${libdir}/perl/${PV}/*/*/*.txt \
+                   ${libdir}/perl/${PV}/auto/XS/Typemap \
+                   ${libdir}/perl/${PV}/B/assemble \
+                   ${libdir}/perl/${PV}/B/cc_harness \
+                   ${libdir}/perl/${PV}/B/disassemble \
+                   ${libdir}/perl/${PV}/B/makeliblinks \
+                   ${libdir}/perl/${PV}/CGI/eg \
+                   ${libdir}/perl/${PV}/CPAN/PAUSE2003.pub \
+                   ${libdir}/perl/${PV}/CPAN/SIGNATURE \
+		   ${libdir}/perl/${PV}/CPANPLUS/Shell/Default/Plugins/HOWTO.pod \
+                   ${libdir}/perl/${PV}/Encode/encode.h \
+                   ${libdir}/perl/${PV}/ExtUtils/MANIFEST.SKIP \
+                   ${libdir}/perl/${PV}/ExtUtils/NOTES \
+                   ${libdir}/perl/${PV}/ExtUtils/PATCHING \
+                   ${libdir}/perl/${PV}/ExtUtils/typemap \
+                   ${libdir}/perl/${PV}/ExtUtils/xsubpp \
+		   ${libdir}/perl/${PV}/ExtUtils/Changes_EU-Install \
+                   ${libdir}/perl/${PV}/Net/*.eg \
+                   ${libdir}/perl/${PV}/unicore/mktables \
+                   ${libdir}/perl/${PV}/unicore/mktables.lst \
+                   ${libdir}/perl/${PV}/unicore/version "
+
+FILES_perl-module-cpan += "${libdir}/perl/${PV}/CPAN \
+                           ${libdir}/perl/${PV}/CPAN.pm"
+FILES_perl-module-cpanplus += "${libdir}/perl/${PV}/CPANPLUS \
+                               ${libdir}/perl/${PV}/CPANPLUS.pm"
+FILES_perl-module-unicore += "${libdir}/perl/${PV}/unicore"
+
+# Create a perl-modules package recommending all the other perl
+# packages (actually the non modules packages and not created too)
+ALLOW_EMPTY_perl-modules = "1"
+PACKAGES_append = " perl-modules "
+
+PACKAGESPLITFUNCS_prepend = "split_perl_packages "
+
+python split_perl_packages () {
+    libdir = d.expand('${libdir}/perl/${PV}')
+    do_split_packages(d, libdir, 'auto/([^.]*)/[^/]*\.(so|ld|ix|al)', 'perl-module-%s', 'perl module %s', recursive=True, match_path=True, prepend=False)
+    do_split_packages(d, libdir, 'Module/([^\/]*)\.pm', 'perl-module-%s', 'perl module %s', recursive=True, allow_dirs=False, match_path=True, prepend=False)
+    do_split_packages(d, libdir, 'Module/([^\/]*)/.*', 'perl-module-%s', 'perl module %s', recursive=True, allow_dirs=False, match_path=True, prepend=False)
+    do_split_packages(d, libdir, '(^(?!(CPAN\/|CPANPLUS\/|Module\/|unicore\/|auto\/)[^\/]).*)\.(pm|pl|e2x)', 'perl-module-%s', 'perl module %s', recursive=True, allow_dirs=False, match_path=True, prepend=False)
+
+    # perl-modules should recommend every perl module, and only the
+    # modules. Don't attempt to use the result of do_split_packages() as some
+    # modules are manually split (eg. perl-module-unicore).
+    packages = filter(lambda p: 'perl-module-' in p, d.getVar('PACKAGES').split())
+    d.setVar(d.expand("RRECOMMENDS_${PN}-modules"), ' '.join(packages))
+}
+
+PACKAGES_DYNAMIC += "^perl-module-.*(?<!\-native)$"
+PACKAGES_DYNAMIC_class-nativesdk = "^nativesdk-perl-module-.*"
+
+RPROVIDES_perl-lib = "perl-lib"
+
+require perl-rdepends_${PV}.inc
+require perl-ptest.inc
+
+SSTATE_SCAN_FILES += "*.pm *.pod *.h *.pl *.sh"
+
+BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-devtools/pkgconf/pkgconf_1.4.2.bb b/poky/meta/recipes-devtools/pkgconf/pkgconf_1.4.2.bb
deleted file mode 100644
index ea7b666..0000000
--- a/poky/meta/recipes-devtools/pkgconf/pkgconf_1.4.2.bb
+++ /dev/null
@@ -1,71 +0,0 @@
-SUMMARY = "pkgconf provides compiler and linker configuration for development frameworks."
-DESCRIPTION = "pkgconf is a program which helps to configure compiler and linker \
-flags for development frameworks. It is similar to pkg-config from \
-freedesktop.org, providing additional functionality while also maintaining \
-compatibility."
-HOMEPAGE = "http://pkgconf.org"
-BUGTRACKER = "https://github.com/pkgconf/pkgconf/issues"
-SECTION = "devel"
-PROVIDES += "pkgconfig"
-RPROVIDES_${PN} += "pkgconfig"
-DEFAULT_PREFERENCE = "-1"
-
-# The pkgconf license seems to be functionally equivalent to BSD-2-Clause or
-# ISC, but has different wording, so needs its own name.
-LICENSE = "pkgconf"
-LIC_FILES_CHKSUM = "file://COPYING;md5=2214222ec1a820bd6cc75167a56925e0"
-
-SRC_URI = "\
-    https://distfiles.dereferenced.org/pkgconf/pkgconf-${PV}.tar.xz \
-    file://pkg-config-wrapper \
-    file://pkg-config-native.in \
-    file://pkg-config-esdk.in \
-"
-SRC_URI[md5sum] = "678d242b4eef1754bba6a58642af10bb"
-SRC_URI[sha256sum] = "bab39371d4ab972be1d539a8b10b6cc21f8eafc97f617102e667e82bd32eb234"
-
-inherit autotools update-alternatives
-
-EXTRA_OECONF += "--with-pkg-config-dir='${libdir}/pkgconfig:${datadir}/pkgconfig'"
-
-do_install_append () {
-    # Install a wrapper which deals, as much as possible with pkgconf vs
-    # pkg-config compatibility issues.
-    install -m 0755 "${WORKDIR}/pkg-config-wrapper" "${D}${bindir}/pkg-config"
-}
-
-do_install_append_class-native () {
-    # Install a pkg-config-native wrapper that will use the native sysroot instead
-    # of the MACHINE sysroot, for using pkg-config when building native tools.
-    sed -e "s|@PATH_NATIVE@|${PKG_CONFIG_PATH}|" \
-        < ${WORKDIR}/pkg-config-native.in > ${B}/pkg-config-native
-    install -m755 ${B}/pkg-config-native ${D}${bindir}/pkg-config-native
-    sed -e "s|@PATH_NATIVE@|${PKG_CONFIG_PATH}|" \
-        -e "s|@LIBDIR_NATIVE@|${PKG_CONFIG_LIBDIR}|" \
-        < ${WORKDIR}/pkg-config-esdk.in > ${B}/pkg-config-esdk
-    install -m755 ${B}/pkg-config-esdk ${D}${bindir}/pkg-config-esdk
-}
-
-ALTERNATIVE_${PN} = "pkg-config"
-
-# When using the RPM generated automatic package dependencies, some packages
-# will end up requiring 'pkgconfig(pkg-config)'.  Allow this behavior by
-# specifying an appropriate provide.
-RPROVIDES_${PN} += "pkgconfig(pkg-config)"
-
-# Include pkg.m4 in the main package, leaving libpkgconf dev files in -dev
-FILES_${PN}-dev_remove = "${datadir}/aclocal"
-FILES_${PN} += "${datadir}/aclocal"
-
-BBCLASSEXTEND += "native nativesdk"
-
-pkgconf_sstate_fixup_esdk () {
-   if [ "${BB_CURRENTTASK}" = "populate_sysroot_setscene" -a "${WITHIN_EXT_SDK}" = "1" ] ; then
-       pkgconfdir="${SSTATE_INSTDIR}/recipe-sysroot-native/${bindir_native}"
-       mv $pkgconfdir/pkg-config $pkgconfdir/pkg-config.real
-       lnr $pkgconfdir/pkg-config-esdk $pkgconfdir/pkg-config
-       sed -i -e "s|^pkg-config|pkg-config.real|" $pkgconfdir/pkg-config-native
-   fi
-}
-
-SSTATEPOSTUNPACKFUNCS_append_class-native = " pkgconf_sstate_fixup_esdk"
diff --git a/poky/meta/recipes-devtools/pkgconf/pkgconf_1.5.3.bb b/poky/meta/recipes-devtools/pkgconf/pkgconf_1.5.3.bb
new file mode 100644
index 0000000..415478d
--- /dev/null
+++ b/poky/meta/recipes-devtools/pkgconf/pkgconf_1.5.3.bb
@@ -0,0 +1,69 @@
+SUMMARY = "pkgconf provides compiler and linker configuration for development frameworks."
+DESCRIPTION = "pkgconf is a program which helps to configure compiler and linker \
+flags for development frameworks. It is similar to pkg-config from \
+freedesktop.org, providing additional functionality while also maintaining \
+compatibility."
+HOMEPAGE = "http://pkgconf.org"
+BUGTRACKER = "https://github.com/pkgconf/pkgconf/issues"
+SECTION = "devel"
+PROVIDES += "pkgconfig"
+RPROVIDES_${PN} += "pkgconfig"
+DEFAULT_PREFERENCE = "-1"
+
+# The pkgconf license seems to be functionally equivalent to BSD-2-Clause or
+# ISC, but has different wording, so needs its own name.
+LICENSE = "pkgconf"
+LIC_FILES_CHKSUM = "file://COPYING;md5=2214222ec1a820bd6cc75167a56925e0"
+
+SRC_URI = "\
+    https://distfiles.dereferenced.org/pkgconf/pkgconf-${PV}.tar.xz \
+    file://pkg-config-wrapper \
+    file://pkg-config-native.in \
+    file://pkg-config-esdk.in \
+"
+SRC_URI[md5sum] = "c21743bca14c882c0f282746168a5edc"
+SRC_URI[sha256sum] = "d3468308553c94389dadfd10c4d1067269052b5364276a9d24a643c88485f715"
+
+inherit autotools
+
+EXTRA_OECONF += "--with-pkg-config-dir='${libdir}/pkgconfig:${datadir}/pkgconfig'"
+
+do_install_append () {
+    # Install a wrapper which deals, as much as possible with pkgconf vs
+    # pkg-config compatibility issues.
+    install -m 0755 "${WORKDIR}/pkg-config-wrapper" "${D}${bindir}/pkg-config"
+}
+
+do_install_append_class-native () {
+    # Install a pkg-config-native wrapper that will use the native sysroot instead
+    # of the MACHINE sysroot, for using pkg-config when building native tools.
+    sed -e "s|@PATH_NATIVE@|${PKG_CONFIG_PATH}|" \
+        < ${WORKDIR}/pkg-config-native.in > ${B}/pkg-config-native
+    install -m755 ${B}/pkg-config-native ${D}${bindir}/pkg-config-native
+    sed -e "s|@PATH_NATIVE@|${PKG_CONFIG_PATH}|" \
+        -e "s|@LIBDIR_NATIVE@|${PKG_CONFIG_LIBDIR}|" \
+        < ${WORKDIR}/pkg-config-esdk.in > ${B}/pkg-config-esdk
+    install -m755 ${B}/pkg-config-esdk ${D}${bindir}/pkg-config-esdk
+}
+
+# When using the RPM generated automatic package dependencies, some packages
+# will end up requiring 'pkgconfig(pkg-config)'.  Allow this behavior by
+# specifying an appropriate provide.
+RPROVIDES_${PN} += "pkgconfig(pkg-config)"
+
+# Include pkg.m4 in the main package, leaving libpkgconf dev files in -dev
+FILES_${PN}-dev_remove = "${datadir}/aclocal"
+FILES_${PN} += "${datadir}/aclocal"
+
+BBCLASSEXTEND += "native nativesdk"
+
+pkgconf_sstate_fixup_esdk () {
+   if [ "${BB_CURRENTTASK}" = "populate_sysroot_setscene" -a "${WITHIN_EXT_SDK}" = "1" ] ; then
+       pkgconfdir="${SSTATE_INSTDIR}/recipe-sysroot-native/${bindir_native}"
+       mv $pkgconfdir/pkg-config $pkgconfdir/pkg-config.real
+       lnr $pkgconfdir/pkg-config-esdk $pkgconfdir/pkg-config
+       sed -i -e "s|^pkg-config|pkg-config.real|" $pkgconfdir/pkg-config-native
+   fi
+}
+
+SSTATEPOSTUNPACKFUNCS_append_class-native = " pkgconf_sstate_fixup_esdk"
diff --git a/poky/meta/recipes-devtools/prelink/prelink/0001-src-arch-mips.c-check-info-resolvetls-before-use-its.patch b/poky/meta/recipes-devtools/prelink/prelink/0001-src-arch-mips.c-check-info-resolvetls-before-use-its.patch
new file mode 100644
index 0000000..b168824
--- /dev/null
+++ b/poky/meta/recipes-devtools/prelink/prelink/0001-src-arch-mips.c-check-info-resolvetls-before-use-its.patch
@@ -0,0 +1,51 @@
+From 2136969e3e196b9cf7f4788340efa4b1d9b39565 Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Thu, 11 Oct 2018 10:05:52 +0800
+Subject: [PATCH] src/arch-mips.c: check info->resolvetls before use its member
+
+The info->resolvetls might be NULL according to src/prelink.c:
+[snip]
+ /* Dynamic linker does not depend on any other library,
+    all symbols resolve to themselves with the exception
+    of SHN_UNDEF symbols which resolve to 0.  */
+if (info->symtab[r_sym].st_shndx == SHN_UNDEF)
+  {
+    info->resolveent = NULL;
+    info->resolvetls = NULL;
+[snip]
+
+So we must check it before use its members, otherwise, there might be
+Segmentation fault error.
+
+Fixed:
+MACHINE = "qemumips"
+IMAGE_INSTALL_append = " qemu"
+$ bitbake core-image-minimal
+[snip]
+| /path/to/qemumips-poky-linux/core-image-minimal/1.0-r0/temp/run.prelink_image.1000: line 111:  1010 Segmentation fault      (core dumped)
+[snip]
+
+Upstream-Status: Submitted [https://lists.yoctoproject.org/pipermail/yocto/2018-October/042812.html]
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ src/arch-mips.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/src/arch-mips.c b/src/arch-mips.c
+index ccb1834..02c608f 100644
+--- a/src/arch-mips.c
++++ b/src/arch-mips.c
+@@ -567,7 +567,8 @@ mips_prelink_reloc (struct prelink_info *info, GElf_Addr r_offset,
+       if (dso->ehdr.e_type == ET_EXEC)
+ 	{
+ 	  value = info->resolve (info, r_sym, r_type);
+-	  value += info->resolvetls->offset - TLS_TP_OFFSET;
++	  if (info->resolvetls != NULL)
++	    value += info->resolvetls->offset - TLS_TP_OFFSET;
+ 	  if (r_type == R_MIPS_TLS_TPREL32)
+ 	    mips_prelink_32bit_reloc (dso, rela, value);
+ 	  else
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/prelink/prelink_git.bb b/poky/meta/recipes-devtools/prelink/prelink_git.bb
index 0f6d16e..b1261d5 100644
--- a/poky/meta/recipes-devtools/prelink/prelink_git.bb
+++ b/poky/meta/recipes-devtools/prelink/prelink_git.bb
@@ -9,7 +9,7 @@
 runtime and thus programs come up faster."
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING;md5=c93c0550bd3173f4504b2cbd8991e50b"
-SRCREV = "05aeafd053e56356ec8c62f4bb8f7b95bae192f3"
+SRCREV = "a853a5d715d84eec93aa68e8f2df26b7d860f5b2"
 PV = "1.0+git${SRCPV}"
 
 #
@@ -27,11 +27,13 @@
 
 PACKAGES =+ "${PN}-cron"
 
-SRC_URI = "git://git.yoctoproject.org/prelink-cross.git;branch=cross_prelink \
+SRC_URI = "git://git.yoctoproject.org/prelink-cross.git;branch=cross_prelink_staging \
            file://prelink.conf \
            file://prelink.cron.daily \
            file://prelink.default \
-	   file://macros.prelink"
+           file://macros.prelink \
+           file://0001-src-arch-mips.c-check-info-resolvetls-before-use-its.patch \
+"
 UPSTREAM_CHECK_COMMITS = "1"
 
 TARGET_OS_ORIG := "${TARGET_OS}"
diff --git a/poky/meta/recipes-devtools/pseudo/pseudo_git.bb b/poky/meta/recipes-devtools/pseudo/pseudo_git.bb
index 9103d49..79e0b6b 100644
--- a/poky/meta/recipes-devtools/pseudo/pseudo_git.bb
+++ b/poky/meta/recipes-devtools/pseudo/pseudo_git.bb
@@ -8,7 +8,7 @@
            file://toomanyfiles.patch \
            "
 
-SRCREV = "fddbe854c9db058d5a05830d3bcdd4233d95ee2e"
+SRCREV = "6294b344e5140f5467e6860f45a174440015304e"
 S = "${WORKDIR}/git"
 PV = "1.9.0+git${SRCPV}"
 
diff --git a/poky/meta/recipes-devtools/python-numpy/python-numpy.inc b/poky/meta/recipes-devtools/python-numpy/python-numpy.inc
index 284f213..1b51f7b 100644
--- a/poky/meta/recipes-devtools/python-numpy/python-numpy.inc
+++ b/poky/meta/recipes-devtools/python-numpy/python-numpy.inc
@@ -10,8 +10,8 @@
            file://fix_shebang_f2py.patch \
            file://0001-npy_cpu-Add-riscv-support.patch \
            ${CONFIGFILESURI} "
-SRC_URI[md5sum] = "e39878fafb11828983aeec583dda4a06"
-SRC_URI[sha256sum] = "ddbcda194f49e0cf0663fa8131cb9d7a3b876d14dea0047d3c5fdfaf20adbb40"
+SRC_URI[md5sum] = "e3189ee851c3a0e2e6e4c6e80a711ec8"
+SRC_URI[sha256sum] = "1b4a02758fb68a65ea986d808867f1d6383219c234aef553a8741818e795b529"
 
 UPSTREAM_CHECK_URI = "https://github.com/numpy/numpy/releases"
 UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)\.tar"
@@ -77,6 +77,8 @@
 
 S = "${WORKDIR}/numpy-${PV}"
 
+CLEANBROKEN = "1"
+
 # Make the build fail and replace *config.h with proper one
 # This is a ugly, ugly hack - Koen
 do_compile_prepend_class-target() {
diff --git a/poky/meta/recipes-devtools/python-numpy/python-numpy_1.14.2.bb b/poky/meta/recipes-devtools/python-numpy/python-numpy_1.14.5.bb
similarity index 100%
rename from poky/meta/recipes-devtools/python-numpy/python-numpy_1.14.2.bb
rename to poky/meta/recipes-devtools/python-numpy/python-numpy_1.14.5.bb
diff --git a/poky/meta/recipes-devtools/python-numpy/python3-numpy_1.14.2.bb b/poky/meta/recipes-devtools/python-numpy/python3-numpy_1.14.5.bb
similarity index 100%
rename from poky/meta/recipes-devtools/python-numpy/python3-numpy_1.14.2.bb
rename to poky/meta/recipes-devtools/python-numpy/python3-numpy_1.14.5.bb
diff --git a/poky/meta/recipes-devtools/python/files/0001-conditionally-do-not-fetch-code-by-easy_install.patch b/poky/meta/recipes-devtools/python/files/0001-conditionally-do-not-fetch-code-by-easy_install.patch
new file mode 100644
index 0000000..4b17921
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/files/0001-conditionally-do-not-fetch-code-by-easy_install.patch
@@ -0,0 +1,34 @@
+From 019422d19c6401fa8f45b1311ecd31bb087c809d Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Tue, 17 Jul 2018 10:13:38 +0800
+Subject: [PATCH] conditionally do not fetch code by easy_install
+
+If var-NO_FETCH_BUILD is set, do not allow to fetch code from
+internet by easy_install.
+
+Upstream-Status: Inappropriate [oe specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ setuptools/command/easy_install.py | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/setuptools/command/easy_install.py b/setuptools/command/easy_install.py
+index 85ee40f..7eb9d2a 100755
+--- a/setuptools/command/easy_install.py
++++ b/setuptools/command/easy_install.py
+@@ -637,6 +637,11 @@ class easy_install(Command):
+             os.path.exists(tmpdir) and rmtree(rmtree_safe(tmpdir))
+ 
+     def easy_install(self, spec, deps=False):
++        if os.environ.get('NO_FETCH_BUILD', None):
++            log.error("ERROR: Do not try to fetch `%s' for building. "
++                      "Please add its native recipe to DEPENDS." % spec)
++            return None
++
+         if not self.editable:
+             self.install_site_py()
+ 
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/python/python-extras.inc b/poky/meta/recipes-devtools/python/python-extras.inc
new file mode 100644
index 0000000..b5e11b7
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python-extras.inc
@@ -0,0 +1,12 @@
+SUMMARY = "Useful extra bits for Python - things that should be in the standard library"
+HOMEPAGE = "https://pypi.python.org/pypi/extras/"
+SECTION = "devel/python"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=6d108f338b2f68fe48ac366c4650bd8b"
+
+inherit pypi
+
+SRC_URI[md5sum] = "3a63ad60cf8f0186c9e3a02f55ec5b14"
+SRC_URI[sha256sum] = "132e36de10b9c91d5d4cc620160a476e0468a88f16c9431817a6729611a81b4e"
+
+BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-devtools/python/python-git.inc b/poky/meta/recipes-devtools/python/python-git.inc
index 8d37693..7ccf168 100644
--- a/poky/meta/recipes-devtools/python/python-git.inc
+++ b/poky/meta/recipes-devtools/python/python-git.inc
@@ -12,8 +12,8 @@
 
 inherit pypi
 
-SRC_URI[md5sum] = "7a94ee1b923fb772a2a0c6649430a17c"
-SRC_URI[sha256sum] = "ad61bc25deadb535b047684d06f3654c001d9415e1971e51c9c20f5b510076e9"
+SRC_URI[md5sum] = "cee43a39a1468084d49d1c49fb675204"
+SRC_URI[sha256sum] = "8237dc5bfd6f1366abeee5624111b9d6879393d84745a507de0fda86043b65a8"
 
 DEPENDS = "${PYTHON_PN}-gitdb"
 
diff --git a/poky/meta/recipes-devtools/python/python-gitdb.inc b/poky/meta/recipes-devtools/python/python-gitdb.inc
index 2d5292e..789ab95 100644
--- a/poky/meta/recipes-devtools/python/python-gitdb.inc
+++ b/poky/meta/recipes-devtools/python/python-gitdb.inc
@@ -8,8 +8,8 @@
 
 PYPI_PACKAGE = "gitdb2"
 
-SRC_URI[md5sum] = "d5217eb94ebd36fcec62b929d1f72b00"
-SRC_URI[sha256sum] = "b60e29d4533e5e25bb50b7678bbc187c8f6bcff1344b4f293b2ba55c85795f09"
+SRC_URI[md5sum] = "6e21f5795a204f7afecb0a72fff66932"
+SRC_URI[sha256sum] = "bb4c85b8a58531c51373c89f92163b92f30f81369605a67cd52d1fc21246c044"
 
 DEPENDS = "${PYTHON_PN}-async ${PYTHON_PN}-setuptools-native ${PYTHON_PN}-smmap"
 
diff --git a/poky/meta/recipes-devtools/python/python-pbr.inc b/poky/meta/recipes-devtools/python/python-pbr.inc
new file mode 100644
index 0000000..5a295c5
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python-pbr.inc
@@ -0,0 +1,15 @@
+SUMMARY = "Python Build Reasonableness"
+DESCRIPTION = "PBR is a library that injects some useful and sensible default behaviors into your setuptools run"
+HOMEPAGE = "https://pypi.python.org/pypi/pbr"
+SECTION = "devel/python"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=1dece7821bf3fd70fe1309eaa37d52a2"
+
+SRC_URI[md5sum] = "6619780896ca81c7cd19c6e2f439b6c9"
+SRC_URI[sha256sum] = "1b8be50d938c9bb75d0eaf7eda111eec1bf6dc88a62a6412e33bf077457e0f45"
+
+inherit pypi
+
+RDEPENDS_${PN} += "${PYTHON_PN}-pip"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-devtools/python/python-setuptools.inc b/poky/meta/recipes-devtools/python/python-setuptools.inc
index 74706bf..315ba31 100644
--- a/poky/meta/recipes-devtools/python/python-setuptools.inc
+++ b/poky/meta/recipes-devtools/python/python-setuptools.inc
@@ -2,27 +2,19 @@
 HOMEPAGE = "https://pypi.python.org/pypi/setuptools"
 SECTION = "devel/python"
 LICENSE = "MIT"
-
 LIC_FILES_CHKSUM = "file://LICENSE;beginline=1;endline=19;md5=9a33897f1bca1160d7aad3835152e158"
 
 PYPI_PACKAGE_EXT = "zip"
 
 inherit pypi
 
-SRC_URI[md5sum] = "379642a4f17214071fdc1894255d8d11"
-SRC_URI[sha256sum] = "94dc566247f35009ed42c0f4422f2b4f0a032fab1372c8308b864c8f26d93388"
+SRC_URI_append_class-native = " file://0001-conditionally-do-not-fetch-code-by-easy_install.patch"
+
+SRC_URI[md5sum] = "260630ae1a64bafa39dcc53404d63829"
+SRC_URI[sha256sum] = "012adb8e25fbfd64c652e99e7bab58799a3aaf05d39ab38561f69190a909015f"
 
 DEPENDS += "${PYTHON_PN}"
-DEPENDS_class-native += "${PYTHON_PN}-native"
-DEPENDS_class-nativesdk += "nativesdk-${PYTHON_PN}"
 
-DISTUTILS_INSTALL_ARGS += "--install-lib=${D}${PYTHON_SITEPACKAGES_DIR} \
-                           --script-dir=${bindir}"
-
-RDEPENDS_${PN}_class-native = "\
-  ${PYTHON_PN}-distutils \
-  ${PYTHON_PN}-compression \
-"
 RDEPENDS_${PN} = "\
   ${PYTHON_PN}-compile \
   ${PYTHON_PN}-compression \
@@ -40,7 +32,6 @@
   ${PYTHON_PN}-unittest \
   ${PYTHON_PN}-xml \
 "
-
 do_install_prepend() {
     install -d ${D}${PYTHON_SITEPACKAGES_DIR}
 }
diff --git a/poky/meta/recipes-devtools/python/python-setuptools_39.0.0.bb b/poky/meta/recipes-devtools/python/python-setuptools_40.0.0.bb
similarity index 100%
rename from poky/meta/recipes-devtools/python/python-setuptools_39.0.0.bb
rename to poky/meta/recipes-devtools/python/python-setuptools_40.0.0.bb
diff --git a/poky/meta/recipes-devtools/python/python-subunit.inc b/poky/meta/recipes-devtools/python/python-subunit.inc
new file mode 100644
index 0000000..afaaa51
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python-subunit.inc
@@ -0,0 +1,14 @@
+SUMMARY = "Python implementation of subunit test streaming protocol"
+HOMEPAGE = "https://pypi.python.org/pypi/python-subunit/"
+SECTION = "devel/python"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://README.rst;beginline=1;endline=20;md5=909c08e291647fd985fbe5d9836d51b6"
+
+PYPI_PACKAGE = "python-subunit"
+
+SRC_URI[md5sum] = "16d468a3aeafe6c60a0c3b2b9132d65b"
+SRC_URI[sha256sum] = "9607edbee4c1e5a30ff88549ce8d9feb0b9bcbcb5e55033a9d76e86075465cbb"
+
+inherit pypi
+
+BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-devtools/python/python-testtools.inc b/poky/meta/recipes-devtools/python/python-testtools.inc
new file mode 100644
index 0000000..1011c98
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python-testtools.inc
@@ -0,0 +1,27 @@
+SUMMARY = "Extensions to the Python standard library unit testing framework"
+HOMEPAGE = "https://pypi.python.org/pypi/testtools/"
+SECTION = "devel/python"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=e2c9d3e8ba7141c83bfef190e0b9379a"
+
+inherit pypi
+
+SRC_URI[md5sum] = "0f0feb915497816cb99e39437494217e"
+SRC_URI[sha256sum] = "5827ec6cf8233e0f29f51025addd713ca010061204fdea77484a2934690a0559"
+
+DEPENDS += " \
+    ${PYTHON_PN}-pbr \
+    "
+
+# Satisfy setup.py 'setup_requires'
+DEPENDS += " \
+    ${PYTHON_PN}-pbr-native \
+    "
+
+RDEPENDS_${PN} += "\
+    ${PYTHON_PN}-extras \
+    ${PYTHON_PN}-pbr \
+    ${PYTHON_PN}-six \
+    "
+
+BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-devtools/python/python.inc b/poky/meta/recipes-devtools/python/python.inc
index 062a20f..6692367 100644
--- a/poky/meta/recipes-devtools/python/python.inc
+++ b/poky/meta/recipes-devtools/python/python.inc
@@ -7,7 +7,13 @@
 
 LIC_FILES_CHKSUM = "file://LICENSE;md5=f257cc14f81685691652a3d3e1b5d754"
 
-SRC_URI = "http://www.python.org/ftp/python/${PV}/Python-${PV}.tar.xz"
+SRC_URI = "http://www.python.org/ftp/python/${PV}/Python-${PV}.tar.xz \
+           file://0001-bpo-33570-TLS-1.3-ciphers-for-OpenSSL-1.1.1-GH-6976-.patch \
+           file://0002-bpo-34818-Add-missing-closing-wrapper-in-test_tls1_3.patch \
+           file://0003-bpo-34834-Fix-test_ssl.test_options-to-account-for-O.patch \
+           file://0004-bpo-34836-fix-test_default_ecdh_curve-needs-no-tlsv1.patch \
+           file://0001-bpo-33354-Fix-test_ssl-when-a-filename-cannot-be-enc.patch \
+           "
 
 SRC_URI[md5sum] = "a80ae3cc478460b922242f43a1b4094d"
 SRC_URI[sha256sum] = "22d9b1ac5b26135ad2b8c2901a9413537e08749a753356ee913c84dbd2df5574"
@@ -33,6 +39,12 @@
   ${PYTHONLSBOPTS} \
 "
 
+do_configure_prepend() {
+	libdirleaf="$(echo ${libdir} | sed -e 's:${prefix}/::')"
+	sed -i -e "s:SEDMELIBLEAF:${libdirleaf}:g" \
+		${S}/configure.ac
+}
+
 do_install_append () {
 	sed -i -e 's:${HOSTTOOLS_DIR}/install:install:g' \
 		-e 's:${HOSTTOOLS_DIR}/mkdir:mkdir:g' \
diff --git a/poky/meta/recipes-devtools/python/python/0001-2.7-bpo-34623-Use-XML_SetHashSalt-in-_elementtree-GH.patch b/poky/meta/recipes-devtools/python/python/0001-2.7-bpo-34623-Use-XML_SetHashSalt-in-_elementtree-GH.patch
index 42c64ca..3c0d662 100644
--- a/poky/meta/recipes-devtools/python/python/0001-2.7-bpo-34623-Use-XML_SetHashSalt-in-_elementtree-GH.patch
+++ b/poky/meta/recipes-devtools/python/python/0001-2.7-bpo-34623-Use-XML_SetHashSalt-in-_elementtree-GH.patch
@@ -19,9 +19,7 @@
 https://bugs.python.org/issue34623
 
 Upstream-Status: Backport
-
-Fix CVE-2018-14647
-
+CVE: CVE-2018-14647
 Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
 ---
  Include/pyexpat.h                                                  | 4 +++-
diff --git a/poky/meta/recipes-devtools/python/python/0001-bpo-33354-Fix-test_ssl-when-a-filename-cannot-be-enc.patch b/poky/meta/recipes-devtools/python/python/0001-bpo-33354-Fix-test_ssl-when-a-filename-cannot-be-enc.patch
new file mode 100644
index 0000000..4c0b357
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python/0001-bpo-33354-Fix-test_ssl-when-a-filename-cannot-be-enc.patch
@@ -0,0 +1,55 @@
+From 19f6bd06af3c7fc0db5f96878aaa68f5589ff13e Mon Sep 17 00:00:00 2001
+From: Pablo Galindo <Pablogsal@gmail.com>
+Date: Thu, 24 May 2018 23:20:44 +0100
+Subject: [PATCH] bpo-33354: Fix test_ssl when a filename cannot be encoded
+ (GH-6613)
+
+Skip test_load_dh_params() of test_ssl when Python filesystem encoding
+cannot encode the provided path.
+
+Upstream-Status: Backport [https://github.com/python/cpython/commit/19f6bd06af3c7fc0db5f96878aaa68f5589ff13e]
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+---
+ Lib/test/test_ssl.py                                     | 9 ++++++++-
+ .../next/Tests/2018-04-26-22-39-17.bpo-33354.g35-44.rst  | 2 ++
+ 2 files changed, 10 insertions(+), 1 deletion(-)
+ create mode 100644 Misc/NEWS.d/next/Tests/2018-04-26-22-39-17.bpo-33354.g35-44.rst
+
+diff --git a/Lib/test/test_ssl.py b/Lib/test/test_ssl.py
+index b59fe73f04..7ced90fdf6 100644
+--- a/Lib/test/test_ssl.py
++++ b/Lib/test/test_ssl.py
+@@ -989,6 +989,13 @@ class ContextTests(unittest.TestCase):
+ 
+ 
+     def test_load_dh_params(self):
++        filename = u'dhpäräm.pem'
++        fs_encoding = sys.getfilesystemencoding()
++        try:
++            filename.encode(fs_encoding)
++        except UnicodeEncodeError:
++            self.skipTest("filename %r cannot be encoded to the filesystem encoding %r" % (filename, fs_encoding))
++
+         ctx = ssl.SSLContext(ssl.PROTOCOL_TLSv1)
+         ctx.load_dh_params(DHFILE)
+         if os.name != 'nt':
+@@ -1001,7 +1008,7 @@ class ContextTests(unittest.TestCase):
+         with self.assertRaises(ssl.SSLError) as cm:
+             ctx.load_dh_params(CERTFILE)
+         with support.temp_dir() as d:
+-            fname = os.path.join(d, u'dhpäräm.pem')
++            fname = os.path.join(d, filename)
+             shutil.copy(DHFILE, fname)
+             ctx.load_dh_params(fname)
+ 
+diff --git a/Misc/NEWS.d/next/Tests/2018-04-26-22-39-17.bpo-33354.g35-44.rst b/Misc/NEWS.d/next/Tests/2018-04-26-22-39-17.bpo-33354.g35-44.rst
+new file mode 100644
+index 0000000000..c66cecac32
+--- /dev/null
++++ b/Misc/NEWS.d/next/Tests/2018-04-26-22-39-17.bpo-33354.g35-44.rst
+@@ -0,0 +1,2 @@
++Skip ``test_ssl.test_load_dh_params`` when Python filesystem encoding cannot encode the
++provided path.
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-devtools/python/python/0001-bpo-33570-TLS-1.3-ciphers-for-OpenSSL-1.1.1-GH-6976-.patch b/poky/meta/recipes-devtools/python/python/0001-bpo-33570-TLS-1.3-ciphers-for-OpenSSL-1.1.1-GH-6976-.patch
new file mode 100644
index 0000000..1f70562
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python/0001-bpo-33570-TLS-1.3-ciphers-for-OpenSSL-1.1.1-GH-6976-.patch
@@ -0,0 +1,120 @@
+From a333351592f097220fc862911b34d3a300f0985e Mon Sep 17 00:00:00 2001
+From: Christian Heimes <christian@python.org>
+Date: Wed, 15 Aug 2018 09:07:28 +0200
+Subject: [PATCH 1/4] bpo-33570: TLS 1.3 ciphers for OpenSSL 1.1.1 (GH-6976)
+ (GH-8760)
+
+Change TLS 1.3 cipher suite settings for compatibility with OpenSSL
+1.1.1-pre6 and newer. OpenSSL 1.1.1 will have TLS 1.3 cipers enabled by
+default.
+
+Also update multissltests to test with latest OpenSSL.
+
+Signed-off-by: Christian Heimes <christian@python.org>.
+(cherry picked from commit 3e630c541b35c96bfe5619165255e559f577ee71)
+
+Co-authored-by: Christian Heimes <christian@python.org>
+
+Upstream-Status: Accepted [https://github.com/python/cpython/pull/8771]
+
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+---
+ Doc/library/ssl.rst                           |  8 ++--
+ Lib/test/test_ssl.py                          | 37 +++++++++++--------
+ .../2018-05-18-21-50-47.bpo-33570.7CZy4t.rst  |  3 ++
+ 3 files changed, 27 insertions(+), 21 deletions(-)
+ create mode 100644 Misc/NEWS.d/next/Library/2018-05-18-21-50-47.bpo-33570.7CZy4t.rst
+
+diff --git a/Doc/library/ssl.rst b/Doc/library/ssl.rst
+index 0421031772..7c7c85b833 100644
+--- a/Doc/library/ssl.rst
++++ b/Doc/library/ssl.rst
+@@ -294,11 +294,6 @@ purposes.
+ 
+      3DES was dropped from the default cipher string.
+ 
+-   .. versionchanged:: 2.7.15
+-
+-     TLS 1.3 cipher suites TLS_AES_128_GCM_SHA256, TLS_AES_256_GCM_SHA384,
+-     and TLS_CHACHA20_POLY1305_SHA256 were added to the default cipher string.
+-
+ .. function:: _https_verify_certificates(enable=True)
+ 
+    Specifies whether or not server certificates are verified when creating
+@@ -1179,6 +1174,9 @@ to speed up repeated connections from the same clients.
+       when connected, the :meth:`SSLSocket.cipher` method of SSL sockets will
+       give the currently selected cipher.
+ 
++      OpenSSL 1.1.1 has TLS 1.3 cipher suites enabled by default. The suites
++      cannot be disabled with :meth:`~SSLContext.set_ciphers`.
++
+ .. method:: SSLContext.set_alpn_protocols(protocols)
+ 
+    Specify which protocols the socket should advertise during the SSL/TLS
+diff --git a/Lib/test/test_ssl.py b/Lib/test/test_ssl.py
+index dc14e22ad1..f51572e319 100644
+--- a/Lib/test/test_ssl.py
++++ b/Lib/test/test_ssl.py
+@@ -2772,19 +2772,24 @@ else:
+                     sock.do_handshake()
+                 self.assertEqual(cm.exception.errno, errno.ENOTCONN)
+ 
+-        def test_default_ciphers(self):
+-            context = ssl.SSLContext(ssl.PROTOCOL_SSLv23)
+-            try:
+-                # Force a set of weak ciphers on our client context
+-                context.set_ciphers("DES")
+-            except ssl.SSLError:
+-                self.skipTest("no DES cipher available")
+-            with ThreadedEchoServer(CERTFILE,
+-                                    ssl_version=ssl.PROTOCOL_SSLv23,
+-                                    chatty=False) as server:
+-                with closing(context.wrap_socket(socket.socket())) as s:
+-                    with self.assertRaises(ssl.SSLError):
+-                        s.connect((HOST, server.port))
++        def test_no_shared_ciphers(self):
++            server_context = ssl.SSLContext(ssl.PROTOCOL_SSLv23)
++            server_context.load_cert_chain(SIGNED_CERTFILE)
++            client_context = ssl.SSLContext(ssl.PROTOCOL_SSLv23)
++            client_context.verify_mode = ssl.CERT_REQUIRED
++            client_context.check_hostname = True
++
++            # OpenSSL enables all TLS 1.3 ciphers, enforce TLS 1.2 for test
++            client_context.options |= ssl.OP_NO_TLSv1_3
++            # Force different suites on client and master
++            client_context.set_ciphers("AES128")
++            server_context.set_ciphers("AES256")
++            with ThreadedEchoServer(context=server_context) as server:
++                s = client_context.wrap_socket(
++                        socket.socket(),
++                        server_hostname="localhost")
++                with self.assertRaises(ssl.SSLError):
++                    s.connect((HOST, server.port))
+             self.assertIn("no shared cipher", str(server.conn_errors[0]))
+ 
+         def test_version_basic(self):
+@@ -2815,9 +2820,9 @@ else:
+                 with context.wrap_socket(socket.socket()) as s:
+                     s.connect((HOST, server.port))
+                     self.assertIn(s.cipher()[0], [
+-                        'TLS13-AES-256-GCM-SHA384',
+-                        'TLS13-CHACHA20-POLY1305-SHA256',
+-                        'TLS13-AES-128-GCM-SHA256',
++                        'TLS_AES_256_GCM_SHA384',
++                        'TLS_CHACHA20_POLY1305_SHA256',
++                        'TLS_AES_128_GCM_SHA256',
+                     ])
+ 
+         @unittest.skipUnless(ssl.HAS_ECDH, "test requires ECDH-enabled OpenSSL")
+diff --git a/Misc/NEWS.d/next/Library/2018-05-18-21-50-47.bpo-33570.7CZy4t.rst b/Misc/NEWS.d/next/Library/2018-05-18-21-50-47.bpo-33570.7CZy4t.rst
+new file mode 100644
+index 0000000000..bd719a47e8
+--- /dev/null
++++ b/Misc/NEWS.d/next/Library/2018-05-18-21-50-47.bpo-33570.7CZy4t.rst
+@@ -0,0 +1,3 @@
++Change TLS 1.3 cipher suite settings for compatibility with OpenSSL
++1.1.1-pre6 and newer. OpenSSL 1.1.1 will have TLS 1.3 cipers enabled by
++default.
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-devtools/python/python/0001-closes-bpo-34540-Convert-shutil._call_external_zip-t.patch b/poky/meta/recipes-devtools/python/python/0001-closes-bpo-34540-Convert-shutil._call_external_zip-t.patch
index e6fe5f2..125db85 100644
--- a/poky/meta/recipes-devtools/python/python/0001-closes-bpo-34540-Convert-shutil._call_external_zip-t.patch
+++ b/poky/meta/recipes-devtools/python/python/0001-closes-bpo-34540-Convert-shutil._call_external_zip-t.patch
@@ -5,9 +5,7 @@
  subprocess rather than distutils.spawn. (GH-8985)
 
 Upstream-Status: Backport
-
-Fix CVE-2018-1000802
-
+CVE: CVE-2018-1000802
 Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
 ---
  Lib/shutil.py                                            | 16 ++++++++++------
diff --git a/poky/meta/recipes-devtools/python/python/0002-bpo-34818-Add-missing-closing-wrapper-in-test_tls1_3.patch b/poky/meta/recipes-devtools/python/python/0002-bpo-34818-Add-missing-closing-wrapper-in-test_tls1_3.patch
new file mode 100644
index 0000000..9688271
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python/0002-bpo-34818-Add-missing-closing-wrapper-in-test_tls1_3.patch
@@ -0,0 +1,37 @@
+From 0e1f3856a7e1511fb64d99646c54ddf3897cd444 Mon Sep 17 00:00:00 2001
+From: Dimitri John Ledkov <xnox@ubuntu.com>
+Date: Fri, 28 Sep 2018 14:15:52 +0100
+Subject: [PATCH 2/4] bpo-34818: Add missing closing() wrapper in test_tls1_3.
+
+Python 2.7 socket classes do not implement context manager protocol,
+hence closing() is required around it. Resolves testcase error
+traceback.
+
+Signed-off-by: Dimitri John Ledkov <xnox@ubuntu.com>
+
+https://bugs.python.org/issue34818
+
+Patch taken from Ubuntu.
+
+Upstream-Status: Submitted [https://github.com/python/cpython/pull/9622]
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+---
+ Lib/test/test_ssl.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/Lib/test/test_ssl.py b/Lib/test/test_ssl.py
+index f51572e319..7a14053cee 100644
+--- a/Lib/test/test_ssl.py
++++ b/Lib/test/test_ssl.py
+@@ -2817,7 +2817,7 @@ else:
+                 ssl.OP_NO_TLSv1 | ssl.OP_NO_TLSv1_1 | ssl.OP_NO_TLSv1_2
+             )
+             with ThreadedEchoServer(context=context) as server:
+-                with context.wrap_socket(socket.socket()) as s:
++                with closing(context.wrap_socket(socket.socket())) as s:
+                     s.connect((HOST, server.port))
+                     self.assertIn(s.cipher()[0], [
+                         'TLS_AES_256_GCM_SHA384',
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-devtools/python/python/0003-bpo-34834-Fix-test_ssl.test_options-to-account-for-O.patch b/poky/meta/recipes-devtools/python/python/0003-bpo-34834-Fix-test_ssl.test_options-to-account-for-O.patch
new file mode 100644
index 0000000..77016cb
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python/0003-bpo-34834-Fix-test_ssl.test_options-to-account-for-O.patch
@@ -0,0 +1,37 @@
+From 8b06d56d26eee289fec22b9b72ab4c7cc3d6c482 Mon Sep 17 00:00:00 2001
+From: Dimitri John Ledkov <xnox@ubuntu.com>
+Date: Fri, 28 Sep 2018 16:34:16 +0100
+Subject: [PATCH 3/4] bpo-34834: Fix test_ssl.test_options to account for
+ OP_ENABLE_MIDDLEBOX_COMPAT.
+
+Signed-off-by: Dimitri John Ledkov <xnox@ubuntu.com>
+
+https://bugs.python.org/issue34834
+
+Patch taken from Ubuntu.
+Upstream-Status: Submitted [https://github.com/python/cpython/pull/9624]
+
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+---
+ Lib/test/test_ssl.py | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/Lib/test/test_ssl.py b/Lib/test/test_ssl.py
+index 7a14053cee..efc906a5ba 100644
+--- a/Lib/test/test_ssl.py
++++ b/Lib/test/test_ssl.py
+@@ -777,6 +777,11 @@ class ContextTests(unittest.TestCase):
+         default = (ssl.OP_ALL | ssl.OP_NO_SSLv2 | ssl.OP_NO_SSLv3)
+         if not IS_LIBRESSL and ssl.OPENSSL_VERSION_INFO >= (1, 1, 0):
+             default |= ssl.OP_NO_COMPRESSION
++        if not IS_LIBRESSL and ssl.OPENSSL_VERSION_INFO >= (1, 1, 1):
++            # define MIDDLEBOX constant, as python2.7 does not know about it
++            # but it is used by default.
++            OP_ENABLE_MIDDLEBOX_COMPAT = 1048576L
++            default |= OP_ENABLE_MIDDLEBOX_COMPAT
+         self.assertEqual(default, ctx.options)
+         ctx.options |= ssl.OP_NO_TLSv1
+         self.assertEqual(default | ssl.OP_NO_TLSv1, ctx.options)
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-devtools/python/python/0004-bpo-34836-fix-test_default_ecdh_curve-needs-no-tlsv1.patch b/poky/meta/recipes-devtools/python/python/0004-bpo-34836-fix-test_default_ecdh_curve-needs-no-tlsv1.patch
new file mode 100644
index 0000000..39e1bcf
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python/0004-bpo-34836-fix-test_default_ecdh_curve-needs-no-tlsv1.patch
@@ -0,0 +1,34 @@
+From 946a7969345c6697697effd226ec396d3fea05b7 Mon Sep 17 00:00:00 2001
+From: Dimitri John Ledkov <xnox@ubuntu.com>
+Date: Fri, 28 Sep 2018 17:30:19 +0100
+Subject: [PATCH 4/4] bpo-34836: fix test_default_ecdh_curve, needs no tlsv1.3.
+
+Signed-off-by: Dimitri John Ledkov <xnox@ubuntu.com>
+
+https://bugs.python.org/issue34836
+
+Patch taken from Ubuntu.
+Upstream-Status: Submitted [https://github.com/python/cpython/pull/9626]
+
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+---
+ Lib/test/test_ssl.py | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/Lib/test/test_ssl.py b/Lib/test/test_ssl.py
+index efc906a5ba..4a3286cd5f 100644
+--- a/Lib/test/test_ssl.py
++++ b/Lib/test/test_ssl.py
+@@ -2836,6 +2836,9 @@ else:
+             # should be enabled by default on SSL contexts.
+             context = ssl.SSLContext(ssl.PROTOCOL_SSLv23)
+             context.load_cert_chain(CERTFILE)
++            # TLSv1.3 defaults to PFS key agreement and no longer has KEA in
++            # cipher name.
++            context.options |= ssl.OP_NO_TLSv1_3
+             # Prior to OpenSSL 1.0.0, ECDH ciphers have to be enabled
+             # explicitly using the 'ECCdraft' cipher alias.  Otherwise,
+             # our default cipher list should prefer ECDH-based ciphers
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-devtools/python/python/create_manifest2.py b/poky/meta/recipes-devtools/python/python/create_manifest2.py
index 1af1443..8799999 100644
--- a/poky/meta/recipes-devtools/python/python/create_manifest2.py
+++ b/poky/meta/recipes-devtools/python/python/create_manifest2.py
@@ -137,7 +137,7 @@
     # Handle special cases, we assume that when they were manually added 
     # to the manifest we knew what we were doing.
     print ('Handling package %s' % key)
-    special_packages=['misc', 'modules', 'dev']
+    special_packages=['misc', 'modules', 'tests', 'dev']
     if key in special_packages or 'staticdev' in key:
         print('Passing %s package directly' % key)
         new_manifest[key]=old_manifest[key]
diff --git a/poky/meta/recipes-devtools/python/python/multilib.patch b/poky/meta/recipes-devtools/python/python/multilib.patch
index 1116dd5..d24bc15 100644
--- a/poky/meta/recipes-devtools/python/python/multilib.patch
+++ b/poky/meta/recipes-devtools/python/python/multilib.patch
@@ -11,7 +11,7 @@
  
 +AC_SUBST(LIB)
 +AC_MSG_CHECKING(LIB)
-+LIB=`basename ${libdir}`
++LIB="SEDMELIBLEAF"
 +AC_MSG_RESULT($LIB)
  
  AC_SUBST(LIBRARY)
diff --git a/poky/meta/recipes-devtools/python/python/python2-manifest.json b/poky/meta/recipes-devtools/python/python/python2-manifest.json
index 1e7004e..260fa6f 100644
--- a/poky/meta/recipes-devtools/python/python/python2-manifest.json
+++ b/poky/meta/recipes-devtools/python/python/python2-manifest.json
@@ -1,18 +1,18 @@
 {
     "tests": {
-        "summary": "Python test suite",
+        "summary": "Python test suite", 
         "rdepends": [
-            "core",
+            "core", 
             "modules"
-        ],
+        ], 
         "files": [
-            "${libdir}/python2.7/*/test",
-            "${libdir}/python2.7/*/tests",
-            "${libdir}/python2.7/idlelib/idle_test/",
+            "${libdir}/python2.7/*/test", 
+            "${libdir}/python2.7/*/tests", 
+            "${libdir}/python2.7/idlelib/idle_test/", 
             "${libdir}/python2.7/test"
-        ],
+        ], 
         "cached": []
-    },
+    }, 
     "2to3": {
         "summary": "Python automated Python 2 to 3 code translator", 
         "rdepends": [
@@ -881,10 +881,12 @@
     "sqlite3": {
         "summary": "Python Sqlite3 database support", 
         "rdepends": [
-            "core"
+            "core", 
+            "datetime"
         ], 
         "files": [
-            "${libdir}/python2.7/lib-dynload/_sqlite3.so"
+            "${libdir}/python2.7/lib-dynload/_sqlite3.so", 
+            "${libdir}/python2.7/sqlite3"
         ]
     }, 
     "stringold": {
@@ -1041,4 +1043,4 @@
             "${libdir}/python2.7/lib-dynload/zlib.so"
         ]
     }
-}
+}
\ No newline at end of file
diff --git a/poky/meta/recipes-devtools/python/python3-dbus_1.2.6.bb b/poky/meta/recipes-devtools/python/python3-dbus_1.2.6.bb
deleted file mode 100644
index 19cbae9..0000000
--- a/poky/meta/recipes-devtools/python/python3-dbus_1.2.6.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-SUMMARY = "Python bindings for the DBus inter-process communication system"
-SECTION = "devel/python"
-HOMEPAGE = "http://www.freedesktop.org/Software/dbus"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b03240518994df6d8c974675675e5ca4"
-DEPENDS = "expat dbus dbus-glib virtual/libintl"
-
-SRC_URI = "http://dbus.freedesktop.org/releases/dbus-python/dbus-python-${PV}.tar.gz \
-"
-
-RSRC_URI[md5sum] = "1ce1ddf2582060f8f971652ea54cc17e"
-SRC_URI[sha256sum] = "32f29c17172cdb9cb61c68b1f1a71dfe7351506fc830869029c47449bd04faeb"
-S = "${WORKDIR}/dbus-python-${PV}"
-
-inherit distutils3-base autotools pkgconfig
-
-PACKAGECONFIG ?= ""
-PACKAGECONFIG[docs] = "--enable-html-docs,--disable-html-docs,python3-docutils-native"
-PACKAGECONFIG[api-docs] = "--enable-api-docs,--disable-api-docs,python3-docutils-native python3-epydoc-native"
-
-RDEPENDS_${PN} = "python3-io python3-logging python3-stringold python3-threading python3-xml"
-
-FILES_${PN}-dev += "${libdir}/pkgconfig"
diff --git a/poky/meta/recipes-devtools/python/python3-dbus_1.2.8.bb b/poky/meta/recipes-devtools/python/python3-dbus_1.2.8.bb
new file mode 100644
index 0000000..c9bf8df
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3-dbus_1.2.8.bb
@@ -0,0 +1,24 @@
+SUMMARY = "Python bindings for the DBus inter-process communication system"
+SECTION = "devel/python"
+HOMEPAGE = "http://www.freedesktop.org/Software/dbus"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b03240518994df6d8c974675675e5ca4"
+DEPENDS = "expat dbus dbus-glib virtual/libintl"
+
+SRC_URI = "http://dbus.freedesktop.org/releases/dbus-python/dbus-python-${PV}.tar.gz \
+"
+
+SRC_URI[md5sum] = "7379db774c10904f27e7e2743d90fb43"
+SRC_URI[sha256sum] = "abf12bbb765e300bf8e2a1b2f32f85949eab06998dbda127952c31cb63957b6f"
+S = "${WORKDIR}/dbus-python-${PV}"
+
+inherit distutils3-base autotools pkgconfig
+
+# documentation needs python3-sphinx, which is not in oe-core or meta-python for now
+# change to use PACKAGECONFIG when python3-sphinx is added to oe-core
+EXTRA_OECONF += "--disable-documentation"
+
+
+RDEPENDS_${PN} = "python3-io python3-logging python3-stringold python3-threading python3-xml"
+
+FILES_${PN}-dev += "${libdir}/pkgconfig"
diff --git a/poky/meta/recipes-devtools/python/python3-extras_1.0.0.bb b/poky/meta/recipes-devtools/python/python3-extras_1.0.0.bb
new file mode 100644
index 0000000..76f87f2
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3-extras_1.0.0.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-extras.inc
diff --git a/poky/meta/recipes-devtools/python/python3-git_2.1.8.bb b/poky/meta/recipes-devtools/python/python3-git_2.1.11.bb
similarity index 100%
rename from poky/meta/recipes-devtools/python/python3-git_2.1.8.bb
rename to poky/meta/recipes-devtools/python/python3-git_2.1.11.bb
diff --git a/poky/meta/recipes-devtools/python/python3-gitdb_2.0.3.bb b/poky/meta/recipes-devtools/python/python3-gitdb_2.0.4.bb
similarity index 100%
rename from poky/meta/recipes-devtools/python/python3-gitdb_2.0.3.bb
rename to poky/meta/recipes-devtools/python/python3-gitdb_2.0.4.bb
diff --git a/poky/meta/recipes-devtools/python/python3-native_3.5.5.bb b/poky/meta/recipes-devtools/python/python3-native_3.5.5.bb
deleted file mode 100644
index 3098027..0000000
--- a/poky/meta/recipes-devtools/python/python3-native_3.5.5.bb
+++ /dev/null
@@ -1,112 +0,0 @@
-require recipes-devtools/python/python.inc
-
-PR = "${INC_PR}.0"
-PYTHON_MAJMIN = "3.5"
-DISTRO_SRC_URI ?= "file://sitecustomize.py"
-DISTRO_SRC_URI_linuxstdbase = ""
-SRC_URI = "http://www.python.org/ftp/python/${PV}/Python-${PV}.tar.xz \
-file://12-distutils-prefix-is-inside-staging-area.patch \
-file://python-config.patch \
-file://0001-cross-compile-support.patch \
-file://030-fixup-include-dirs.patch \
-file://070-dont-clean-ipkg-install.patch \
-file://080-distutils-dont_adjust_files.patch \
-file://130-readline-setup.patch \
-file://150-fix-setupterm.patch \
-file://python-3.3-multilib.patch \
-file://03-fix-tkinter-detection.patch \
-file://avoid_warning_about_tkinter.patch \
-file://shutil-follow-symlink-fix.patch \
-file://0001-h2py-Fix-issue-13032-where-it-fails-with-UnicodeDeco.patch \
-file://sysroot-include-headers.patch \
-file://unixccompiler.patch \
-${DISTRO_SRC_URI} \
-file://sysconfig.py-add-_PYTHON_PROJECT_SRC.patch \
-file://setup.py-check-cross_compiling-when-get-FLAGS.patch \
-file://0001-Do-not-use-the-shell-version-of-python-config-that-w.patch \
-file://support_SOURCE_DATE_EPOCH_in_py_compile.patch \
-file://regen-all.patch \
-"
-
-SRC_URI[md5sum] = "f3763edf9824d5d3a15f5f646083b6e0"
-SRC_URI[sha256sum] = "063d2c3b0402d6191b90731e0f735c64830e7522348aeb7ed382a83165d45009"
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=b6ec515b22618f55fa07276b897bacea"
-
-# exclude pre-releases for both python 2.x and 3.x
-UPSTREAM_CHECK_REGEX = "[Pp]ython-(?P<pver>\d+(\.\d+)+).tar"
-
-S = "${WORKDIR}/Python-${PV}"
-
-EXTRANATIVEPATH += "bzip2-native"
-DEPENDS = "openssl-native bzip2-replacement-native zlib-native readline-native sqlite3-native gdbm-native"
-
-inherit native
-
-EXTRA_OECONF_append = " --bindir=${bindir}/${PN} --without-ensurepip"
-
-EXTRA_OEMAKE = '\
-  LIBC="" \
-  STAGING_LIBDIR=${STAGING_LIBDIR_NATIVE} \
-  STAGING_INCDIR=${STAGING_INCDIR_NATIVE} \
-  LIB=${baselib} \
-  ARCH=${TARGET_ARCH} \
-'
-
-# No ctypes option for python 3
-PYTHONLSBOPTS = ""
-
-do_configure_append() {
-	autoreconf --verbose --install --force --exclude=autopoint ../Python-${PV}/Modules/_ctypes/libffi
-	sed -i -e 's,#define HAVE_GETRANDOM 1,/\* #undef HAVE_GETRANDOM \*/,' ${B}/pyconfig.h
-}
-
-# Regenerate all of the generated files
-# This ensures that pgen and friends get created during the compile phase
-#
-do_compile_prepend() {
-    # Assuming https://bugs.python.org/issue33080 has been addressed in Makefile.
-    oe_runmake regen-all
-}
-
-do_install() {
-	install -d ${D}${libdir}/pkgconfig
-	oe_runmake 'DESTDIR=${D}' install
-	if [ -e ${WORKDIR}/sitecustomize.py ]; then
-		install -m 0644 ${WORKDIR}/sitecustomize.py ${D}/${libdir}/python${PYTHON_MAJMIN}
-	fi
-	install -d ${D}${bindir}/${PN}
-	install -m 0755 Parser/pgen ${D}${bindir}/${PN}
-
-	# Make sure we use /usr/bin/env python
-	for PYTHSCRIPT in `grep -rIl ${bindir}/${PN}/python ${D}${bindir}/${PN}`; do
-		sed -i -e '1s|^#!.*|#!/usr/bin/env python3|' $PYTHSCRIPT
-	done
-
-        # Add a symlink to the native Python so that scripts can just invoke
-        # "nativepython" and get the right one without needing absolute paths
-        # (these often end up too long for the #! parser in the kernel as the
-        # buffer is 128 bytes long).
-        ln -s python3-native/python3 ${D}${bindir}/nativepython3
-}
-
-python(){
-
-    # Read JSON manifest
-    import json
-    pythondir = d.getVar('THISDIR',True)
-    with open(pythondir+'/python3/python3-manifest.json') as manifest_file:
-        python_manifest=json.load(manifest_file)
-
-    rprovides = d.getVar('RPROVIDES').split()
-
-    # Hardcoded since it cant be python3-native-foo, should be python3-foo-native
-    pn = 'python3'
-
-    for key in python_manifest:
-        pypackage = pn + '-' + key + '-native'
-        if pypackage not in rprovides:
-              rprovides.append(pypackage)
-
-    d.setVar('RPROVIDES', ' '.join(rprovides))
-}
diff --git a/poky/meta/recipes-devtools/python/python3-native_3.5.6.bb b/poky/meta/recipes-devtools/python/python3-native_3.5.6.bb
new file mode 100644
index 0000000..d5953cf
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3-native_3.5.6.bb
@@ -0,0 +1,100 @@
+require recipes-devtools/python/python3.inc
+
+DISTRO_SRC_URI ?= "file://sitecustomize.py"
+DISTRO_SRC_URI_linuxstdbase = ""
+SRC_URI = "http://www.python.org/ftp/python/${PV}/Python-${PV}.tar.xz \
+file://12-distutils-prefix-is-inside-staging-area.patch \
+file://python-config.patch \
+file://030-fixup-include-dirs.patch \
+file://070-dont-clean-ipkg-install.patch \
+file://080-distutils-dont_adjust_files.patch \
+file://130-readline-setup.patch \
+file://150-fix-setupterm.patch \
+file://python-3.3-multilib.patch \
+file://03-fix-tkinter-detection.patch \
+file://avoid_warning_about_tkinter.patch \
+file://0001-h2py-Fix-issue-13032-where-it-fails-with-UnicodeDeco.patch \
+file://sysroot-include-headers.patch \
+file://unixccompiler.patch \
+${DISTRO_SRC_URI} \
+file://sysconfig.py-add-_PYTHON_PROJECT_SRC.patch \
+file://setup.py-check-cross_compiling-when-get-FLAGS.patch \
+file://0001-Do-not-use-the-shell-version-of-python-config-that-w.patch \
+file://support_SOURCE_DATE_EPOCH_in_py_compile.patch \
+file://regen-all.patch \
+file://0001-Issue-28043-SSLContext-has-improved-default-settings.patch \
+file://0002-bpo-29136-Add-TLS-1.3-cipher-suites-and-OP_NO_TLSv1_.patch \
+file://0003-bpo-32947-Fixes-for-TLS-1.3-and-OpenSSL-1.1.1-GH-876.patch \
+file://0004-bpo-33570-TLS-1.3-ciphers-for-OpenSSL-1.1.1-GH-6976.patch \
+file://0005-bpo-30714-ALPN-changes-for-OpenSSL-1.1.0f-2305.patch \
+"
+
+EXTRANATIVEPATH += "bzip2-native"
+DEPENDS = "openssl-native bzip2-replacement-native zlib-native readline-native sqlite3-native gdbm-native"
+
+inherit native
+
+EXTRA_OECONF_append = " --bindir=${bindir}/${PN} --without-ensurepip"
+
+EXTRA_OEMAKE = '\
+  LIBC="" \
+  STAGING_LIBDIR=${STAGING_LIBDIR_NATIVE} \
+  STAGING_INCDIR=${STAGING_INCDIR_NATIVE} \
+  LIB=${baselib} \
+  ARCH=${TARGET_ARCH} \
+'
+
+do_configure_append() {
+	autoreconf --verbose --install --force --exclude=autopoint ../Python-${PV}/Modules/_ctypes/libffi
+	sed -i -e 's,#define HAVE_GETRANDOM 1,/\* #undef HAVE_GETRANDOM \*/,' ${B}/pyconfig.h
+}
+
+# Regenerate all of the generated files
+# This ensures that pgen and friends get created during the compile phase
+#
+do_compile_prepend() {
+    # Assuming https://bugs.python.org/issue33080 has been addressed in Makefile.
+    oe_runmake regen-all
+}
+
+do_install() {
+	install -d ${D}${libdir}/pkgconfig
+	oe_runmake 'DESTDIR=${D}' install
+	if [ -e ${WORKDIR}/sitecustomize.py ]; then
+		install -m 0644 ${WORKDIR}/sitecustomize.py ${D}/${libdir}/python${PYTHON_MAJMIN}
+	fi
+	install -d ${D}${bindir}/${PN}
+	install -m 0755 Parser/pgen ${D}${bindir}/${PN}
+
+	# Make sure we use /usr/bin/env python
+	for PYTHSCRIPT in `grep -rIl ${bindir}/${PN}/python ${D}${bindir}/${PN}`; do
+		sed -i -e '1s|^#!.*|#!/usr/bin/env python3|' $PYTHSCRIPT
+	done
+
+        # Add a symlink to the native Python so that scripts can just invoke
+        # "nativepython" and get the right one without needing absolute paths
+        # (these often end up too long for the #! parser in the kernel as the
+        # buffer is 128 bytes long).
+        ln -s python3-native/python3 ${D}${bindir}/nativepython3
+}
+
+python(){
+
+    # Read JSON manifest
+    import json
+    pythondir = d.getVar('THISDIR',True)
+    with open(pythondir+'/python3/python3-manifest.json') as manifest_file:
+        python_manifest=json.load(manifest_file)
+
+    rprovides = d.getVar('RPROVIDES').split()
+
+    # Hardcoded since it cant be python3-native-foo, should be python3-foo-native
+    pn = 'python3'
+
+    for key in python_manifest:
+        pypackage = pn + '-' + key + '-native'
+        if pypackage not in rprovides:
+              rprovides.append(pypackage)
+
+    d.setVar('RPROVIDES', ' '.join(rprovides))
+}
diff --git a/poky/meta/recipes-devtools/python/python3-pbr_4.2.0.bb b/poky/meta/recipes-devtools/python/python3-pbr_4.2.0.bb
new file mode 100644
index 0000000..97e7361
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3-pbr_4.2.0.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-pbr.inc
diff --git a/poky/meta/recipes-devtools/python/python3-pip_18.0.bb b/poky/meta/recipes-devtools/python/python3-pip_18.0.bb
new file mode 100644
index 0000000..3fcdb80
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3-pip_18.0.bb
@@ -0,0 +1,30 @@
+SUMMARY = "The PyPA recommended tool for installing Python packages"
+HOMEPAGE = "https://pypi.python.org/pypi/pip"
+SECTION = "devel/python"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=593c6cd9d639307226978cbcae61ad4b"
+
+DEPENDS += "python3 python3-setuptools-native"
+
+SRC_URI[md5sum] = "52f75ceb21e96c258f289859a2996b60"
+SRC_URI[sha256sum] = "a0e11645ee37c90b40c46d607070c4fd583e2cd46231b1c06e389c5e814eed76"
+
+inherit pypi distutils3
+
+do_install_append() {
+    # Install as pip3 and leave pip2 as default
+    rm ${D}/${bindir}/pip
+}
+
+RDEPENDS_${PN} = "\
+  python3-compile \
+  python3-io \
+  python3-html \
+  python3-json \
+  python3-netserver \
+  python3-setuptools \
+  python3-unixadmin \
+  python3-xmlrpc \
+"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-devtools/python/python3-pip_9.0.2.bb b/poky/meta/recipes-devtools/python/python3-pip_9.0.2.bb
deleted file mode 100644
index 53fd6dc..0000000
--- a/poky/meta/recipes-devtools/python/python3-pip_9.0.2.bb
+++ /dev/null
@@ -1,48 +0,0 @@
-SUMMARY = "The PyPA recommended tool for installing Python packages"
-HOMEPAGE = "https://pypi.python.org/pypi/pip"
-SECTION = "devel/python"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=25fba45109565f87de20bae85bc39452"
-
-DEPENDS += "python3 python3-setuptools-native"
-
-SRC_URI[md5sum] = "2fddd680422326b9d1fbf56112cf341d"
-SRC_URI[sha256sum] = "88110a224e9d30e5d76592a0b2130ef10e7e67a6426e8617bb918fffbfe91fe5"
-
-inherit pypi distutils3
-
-DISTUTILS_INSTALL_ARGS += "--install-lib=${D}${PYTHON_SITEPACKAGES_DIR}"
-
-do_install_prepend() {
-    install -d ${D}${PYTHON_SITEPACKAGES_DIR}
-}
-
-# Use setuptools site.py instead, avoid shared state issue
-do_install_append() {
-    rm ${D}${PYTHON_SITEPACKAGES_DIR}/site.py
-    rm ${D}${PYTHON_SITEPACKAGES_DIR}/__pycache__/site.cpython-*.pyc
-
-    # Install as pip3 and leave pip2 as default
-    rm ${D}/${bindir}/pip
-
-    # Installed eggs need to be passed directly to the interpreter via a pth file
-    echo "./${PYPI_PACKAGE}-${PV}-py${PYTHON_BASEVERSION}.egg" > ${D}${PYTHON_SITEPACKAGES_DIR}/${PYPI_PACKAGE}-${PV}.pth
-
-    # Make sure we use /usr/bin/env python3
-    for PYTHSCRIPT in `grep -rIl ${bindir} ${D}${bindir}/pip3*`; do
-        sed -i -e '1s|^#!.*|#!/usr/bin/env python3|' $PYTHSCRIPT
-    done
-}
-
-RDEPENDS_${PN} = "\
-  python3-compile \
-  python3-io \
-  python3-html \
-  python3-json \
-  python3-netserver \
-  python3-setuptools \
-  python3-unixadmin \
-  python3-xmlrpc \
-"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-devtools/python/python3-pygobject_3.28.1.bb b/poky/meta/recipes-devtools/python/python3-pygobject_3.28.1.bb
deleted file mode 100644
index 97286f4..0000000
--- a/poky/meta/recipes-devtools/python/python3-pygobject_3.28.1.bb
+++ /dev/null
@@ -1,29 +0,0 @@
-SUMMARY = "Python GObject bindings"
-SECTION = "devel/python"
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=a916467b91076e631dd8edb7424769c7"
-
-inherit gnomebase distutils3-base gobject-introspection upstream-version-is-even
-
-DEPENDS += "python3 glib-2.0"
-
-SRCNAME="pygobject"
-SRC_URI = " \
-    http://ftp.gnome.org/pub/GNOME/sources/${SRCNAME}/${@gnome_verdir("${PV}")}/${SRCNAME}-${PV}.tar.xz \
-"
-
-SRC_URI[md5sum] = "612e9e2863d117d810e78672f7bc3ad6"
-SRC_URI[sha256sum] = "42312b4a5015571fa0a4f2d201005da46b71c251ea2625bc95702d071c4ff895"
-
-S = "${WORKDIR}/${SRCNAME}-${PV}"
-
-PACKAGECONFIG ??= "${@bb.utils.contains_any('DISTRO_FEATURES', [ 'directfb', 'wayland', 'x11' ], 'cairo', '', d)}"
-
-# python3-pycairo is checked on configuration -> DEPENDS
-# we don't link against python3-pycairo -> RDEPENDS
-PACKAGECONFIG[cairo] = "--enable-cairo,--disable-cairo,cairo python3-pycairo, python3-pycairo"
-
-RDEPENDS_${PN} += "python3-setuptools"
-
-BBCLASSEXTEND = "native"
-PACKAGECONFIG_class-native = ""
diff --git a/poky/meta/recipes-devtools/python/python3-pygobject_3.28.3.bb b/poky/meta/recipes-devtools/python/python3-pygobject_3.28.3.bb
new file mode 100644
index 0000000..313af22
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3-pygobject_3.28.3.bb
@@ -0,0 +1,29 @@
+SUMMARY = "Python GObject bindings"
+SECTION = "devel/python"
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=a916467b91076e631dd8edb7424769c7"
+
+inherit gnomebase distutils3-base gobject-introspection upstream-version-is-even
+
+DEPENDS += "python3 glib-2.0"
+
+SRCNAME="pygobject"
+SRC_URI = " \
+    http://ftp.gnome.org/pub/GNOME/sources/${SRCNAME}/${@gnome_verdir("${PV}")}/${SRCNAME}-${PV}.tar.xz \
+"
+
+SRC_URI[md5sum] = "3bac63c86bb963aa401f97859464aa90"
+SRC_URI[sha256sum] = "3dd3e21015d06e00482ea665fc1733b77e754a6ab656a5db5d7f7bfaf31ad0b0"
+
+S = "${WORKDIR}/${SRCNAME}-${PV}"
+
+PACKAGECONFIG ??= "${@bb.utils.contains_any('DISTRO_FEATURES', [ 'directfb', 'wayland', 'x11' ], 'cairo', '', d)}"
+
+# python3-pycairo is checked on configuration -> DEPENDS
+# we don't link against python3-pycairo -> RDEPENDS
+PACKAGECONFIG[cairo] = "--enable-cairo,--disable-cairo,cairo python3-pycairo, python3-pycairo"
+
+RDEPENDS_${PN} += "python3-setuptools"
+
+BBCLASSEXTEND = "native"
+PACKAGECONFIG_class-native = ""
diff --git a/poky/meta/recipes-devtools/python/python3-setuptools_39.0.0.bb b/poky/meta/recipes-devtools/python/python3-setuptools_40.0.0.bb
similarity index 100%
rename from poky/meta/recipes-devtools/python/python3-setuptools_39.0.0.bb
rename to poky/meta/recipes-devtools/python/python3-setuptools_40.0.0.bb
diff --git a/poky/meta/recipes-devtools/python/python3-subunit_1.3.0.bb b/poky/meta/recipes-devtools/python/python3-subunit_1.3.0.bb
new file mode 100644
index 0000000..2ece445
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3-subunit_1.3.0.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-subunit.inc
diff --git a/poky/meta/recipes-devtools/python/python3-testtools_2.3.0.bb b/poky/meta/recipes-devtools/python/python3-testtools_2.3.0.bb
new file mode 100644
index 0000000..896ecee
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3-testtools_2.3.0.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-testtools.inc
diff --git a/poky/meta/recipes-devtools/python/python3.inc b/poky/meta/recipes-devtools/python/python3.inc
new file mode 100644
index 0000000..f565b3f
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3.inc
@@ -0,0 +1,43 @@
+SUMMARY = "The Python Programming Language"
+HOMEPAGE = "http://www.python.org"
+LICENSE = "PSFv2"
+SECTION = "devel/python"
+
+# TODO Remove this when we upgrade
+INC_PR = "r1"
+PR = "${INC_PR}.0"
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=b6ec515b22618f55fa07276b897bacea"
+
+# TODO consolidate patch set
+SRC_URI[md5sum] = "f5a99f765e765336a3ebbb2a24ca2be3"
+SRC_URI[sha256sum] = "f55cde04f521f273c7cba08912921cc5642cfc15ca7b22d5829f0aff4371155f"
+
+# exclude pre-releases for both python 2.x and 3.x
+UPSTREAM_CHECK_REGEX = "[Pp]ython-(?P<pver>\d+(\.\d+)+).tar"
+
+CVE_PRODUCT = "python"
+
+PYTHON_MAJMIN = "3.5"
+PYTHON_BINABI = "${PYTHON_MAJMIN}m"
+
+S = "${WORKDIR}/Python-${PV}"
+
+inherit autotools bluetooth pkgconfig
+
+EXTRA_OECONF = "\
+  --with-threads \
+  --with-pymalloc \
+  --without-cxx-main \
+  --with-signal-module \
+  --enable-shared \
+  --enable-ipv6=${@bb.utils.contains('DISTRO_FEATURES', 'ipv6', 'yes', 'no', d)} \
+"
+
+PACKAGECONFIG[bluetooth] = ",ac_cv_header_bluetooth_bluetooth_h=no ac_cv_header_bluetooth_h=no,${BLUEZ}"
+
+do_install_append () {
+	sed -i -e 's:${HOSTTOOLS_DIR}/install:install:g' \
+		-e 's:${HOSTTOOLS_DIR}/mkdir:mkdir:g' \
+		${D}/${libdir}/python${PYTHON_MAJMIN}/_sysconfigdata.py
+}
diff --git a/poky/meta/recipes-devtools/python/python3/0001-Issue-28043-SSLContext-has-improved-default-settings.patch b/poky/meta/recipes-devtools/python/python3/0001-Issue-28043-SSLContext-has-improved-default-settings.patch
new file mode 100644
index 0000000..321b4af
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3/0001-Issue-28043-SSLContext-has-improved-default-settings.patch
@@ -0,0 +1,272 @@
+From 758e7463c104f71b810c8588166747eeab6148d7 Mon Sep 17 00:00:00 2001
+From: Christian Heimes <christian@python.org>
+Date: Sat, 10 Sep 2016 22:43:48 +0200
+Subject: [PATCH 1/4] Issue 28043: SSLContext has improved default settings
+
+The options OP_NO_COMPRESSION, OP_CIPHER_SERVER_PREFERENCE, OP_SINGLE_DH_USE, OP_SINGLE_ECDH_USE, OP_NO_SSLv2 (except for PROTOCOL_SSLv2), and OP_NO_SSLv3 (except for PROTOCOL_SSLv3) are set by default. The initial cipher suite list contains only HIGH ciphers, no NULL ciphers and MD5 ciphers (except for PROTOCOL_SSLv2).
+
+Upstream-Status: Backport
+[https://github.com/python/cpython/commit/358cfd426ccc0fcd6a7940d306602138e76420ae]
+
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+---
+ Doc/library/ssl.rst  |  9 ++++++-
+ Lib/ssl.py           | 30 +++++----------------
+ Lib/test/test_ssl.py | 62 +++++++++++++++++++++++---------------------
+ Modules/_ssl.c       | 31 ++++++++++++++++++++++
+ 4 files changed, 78 insertions(+), 54 deletions(-)
+
+diff --git a/Doc/library/ssl.rst b/Doc/library/ssl.rst
+index a2f008346b..14f2d68217 100644
+--- a/Doc/library/ssl.rst
++++ b/Doc/library/ssl.rst
+@@ -1151,7 +1151,14 @@ to speed up repeated connections from the same clients.
+ 
+    .. versionchanged:: 3.5.3
+ 
+-      :data:`PROTOCOL_TLS` is the default value.
++      The context is created with secure default values. The options
++      :data:`OP_NO_COMPRESSION`, :data:`OP_CIPHER_SERVER_PREFERENCE`,
++      :data:`OP_SINGLE_DH_USE`, :data:`OP_SINGLE_ECDH_USE`,
++      :data:`OP_NO_SSLv2` (except for :data:`PROTOCOL_SSLv2`),
++      and :data:`OP_NO_SSLv3` (except for :data:`PROTOCOL_SSLv3`) are
++      set by default. The initial cipher suite list contains only ``HIGH``
++      ciphers, no ``NULL`` ciphers and no ``MD5`` ciphers (except for
++      :data:`PROTOCOL_SSLv2`).
+ 
+ 
+ :class:`SSLContext` objects have the following methods and attributes:
+diff --git a/Lib/ssl.py b/Lib/ssl.py
+index e1913904f3..4d302a78fa 100644
+--- a/Lib/ssl.py
++++ b/Lib/ssl.py
+@@ -446,32 +446,16 @@ def create_default_context(purpose=Purpose.SERVER_AUTH, *, cafile=None,
+     if not isinstance(purpose, _ASN1Object):
+         raise TypeError(purpose)
+ 
++    # SSLContext sets OP_NO_SSLv2, OP_NO_SSLv3, OP_NO_COMPRESSION,
++    # OP_CIPHER_SERVER_PREFERENCE, OP_SINGLE_DH_USE and OP_SINGLE_ECDH_USE
++    # by default.
+     context = SSLContext(PROTOCOL_TLS)
+ 
+-    # SSLv2 considered harmful.
+-    context.options |= OP_NO_SSLv2
+-
+-    # SSLv3 has problematic security and is only required for really old
+-    # clients such as IE6 on Windows XP
+-    context.options |= OP_NO_SSLv3
+-
+-    # disable compression to prevent CRIME attacks (OpenSSL 1.0+)
+-    context.options |= getattr(_ssl, "OP_NO_COMPRESSION", 0)
+-
+     if purpose == Purpose.SERVER_AUTH:
+         # verify certs and host name in client mode
+         context.verify_mode = CERT_REQUIRED
+         context.check_hostname = True
+     elif purpose == Purpose.CLIENT_AUTH:
+-        # Prefer the server's ciphers by default so that we get stronger
+-        # encryption
+-        context.options |= getattr(_ssl, "OP_CIPHER_SERVER_PREFERENCE", 0)
+-
+-        # Use single use keys in order to improve forward secrecy
+-        context.options |= getattr(_ssl, "OP_SINGLE_DH_USE", 0)
+-        context.options |= getattr(_ssl, "OP_SINGLE_ECDH_USE", 0)
+-
+-        # disallow ciphers with known vulnerabilities
+         context.set_ciphers(_RESTRICTED_SERVER_CIPHERS)
+ 
+     if cafile or capath or cadata:
+@@ -497,12 +481,10 @@ def _create_unverified_context(protocol=PROTOCOL_TLS, *, cert_reqs=None,
+     if not isinstance(purpose, _ASN1Object):
+         raise TypeError(purpose)
+ 
++    # SSLContext sets OP_NO_SSLv2, OP_NO_SSLv3, OP_NO_COMPRESSION,
++    # OP_CIPHER_SERVER_PREFERENCE, OP_SINGLE_DH_USE and OP_SINGLE_ECDH_USE
++    # by default.
+     context = SSLContext(protocol)
+-    # SSLv2 considered harmful.
+-    context.options |= OP_NO_SSLv2
+-    # SSLv3 has problematic security and is only required for really old
+-    # clients such as IE6 on Windows XP
+-    context.options |= OP_NO_SSLv3
+ 
+     if cert_reqs is not None:
+         context.verify_mode = cert_reqs
+diff --git a/Lib/test/test_ssl.py b/Lib/test/test_ssl.py
+index ffb7314f57..f91af7bd05 100644
+--- a/Lib/test/test_ssl.py
++++ b/Lib/test/test_ssl.py
+@@ -73,6 +73,12 @@ NULLBYTECERT = data_file("nullbytecert.pem")
+ DHFILE = data_file("dh1024.pem")
+ BYTES_DHFILE = os.fsencode(DHFILE)
+ 
++# Not defined in all versions of OpenSSL
++OP_NO_COMPRESSION = getattr(ssl, "OP_NO_COMPRESSION", 0)
++OP_SINGLE_DH_USE = getattr(ssl, "OP_SINGLE_DH_USE", 0)
++OP_SINGLE_ECDH_USE = getattr(ssl, "OP_SINGLE_ECDH_USE", 0)
++OP_CIPHER_SERVER_PREFERENCE = getattr(ssl, "OP_CIPHER_SERVER_PREFERENCE", 0)
++
+ 
+ def handle_error(prefix):
+     exc_format = ' '.join(traceback.format_exception(*sys.exc_info()))
+@@ -839,8 +845,9 @@ class ContextTests(unittest.TestCase):
+         ctx = ssl.SSLContext(ssl.PROTOCOL_TLSv1)
+         # OP_ALL | OP_NO_SSLv2 | OP_NO_SSLv3 is the default value
+         default = (ssl.OP_ALL | ssl.OP_NO_SSLv2 | ssl.OP_NO_SSLv3)
+-        if not IS_LIBRESSL and ssl.OPENSSL_VERSION_INFO >= (1, 1, 0):
+-            default |= ssl.OP_NO_COMPRESSION
++        # SSLContext also enables these by default
++        default |= (OP_NO_COMPRESSION | OP_CIPHER_SERVER_PREFERENCE |
++                    OP_SINGLE_DH_USE | OP_SINGLE_ECDH_USE)
+         self.assertEqual(default, ctx.options)
+         ctx.options |= ssl.OP_NO_TLSv1
+         self.assertEqual(default | ssl.OP_NO_TLSv1, ctx.options)
+@@ -1205,16 +1212,29 @@ class ContextTests(unittest.TestCase):
+             stats["x509"] += 1
+             self.assertEqual(ctx.cert_store_stats(), stats)
+ 
++    def _assert_context_options(self, ctx):
++        self.assertEqual(ctx.options & ssl.OP_NO_SSLv2, ssl.OP_NO_SSLv2)
++        if OP_NO_COMPRESSION != 0:
++            self.assertEqual(ctx.options & OP_NO_COMPRESSION,
++                             OP_NO_COMPRESSION)
++        if OP_SINGLE_DH_USE != 0:
++            self.assertEqual(ctx.options & OP_SINGLE_DH_USE,
++                             OP_SINGLE_DH_USE)
++        if OP_SINGLE_ECDH_USE != 0:
++            self.assertEqual(ctx.options & OP_SINGLE_ECDH_USE,
++                             OP_SINGLE_ECDH_USE)
++        if OP_CIPHER_SERVER_PREFERENCE != 0:
++            self.assertEqual(ctx.options & OP_CIPHER_SERVER_PREFERENCE,
++                             OP_CIPHER_SERVER_PREFERENCE)
++
+     def test_create_default_context(self):
+         ctx = ssl.create_default_context()
++
+         self.assertEqual(ctx.protocol, ssl.PROTOCOL_SSLv23)
+         self.assertEqual(ctx.verify_mode, ssl.CERT_REQUIRED)
+         self.assertTrue(ctx.check_hostname)
+-        self.assertEqual(ctx.options & ssl.OP_NO_SSLv2, ssl.OP_NO_SSLv2)
+-        self.assertEqual(
+-            ctx.options & getattr(ssl, "OP_NO_COMPRESSION", 0),
+-            getattr(ssl, "OP_NO_COMPRESSION", 0),
+-        )
++        self._assert_context_options(ctx)
++
+ 
+         with open(SIGNING_CA) as f:
+             cadata = f.read()
+@@ -1222,40 +1242,24 @@ class ContextTests(unittest.TestCase):
+                                          cadata=cadata)
+         self.assertEqual(ctx.protocol, ssl.PROTOCOL_SSLv23)
+         self.assertEqual(ctx.verify_mode, ssl.CERT_REQUIRED)
+-        self.assertEqual(ctx.options & ssl.OP_NO_SSLv2, ssl.OP_NO_SSLv2)
+-        self.assertEqual(
+-            ctx.options & getattr(ssl, "OP_NO_COMPRESSION", 0),
+-            getattr(ssl, "OP_NO_COMPRESSION", 0),
+-        )
++        self._assert_context_options(ctx)
+ 
+         ctx = ssl.create_default_context(ssl.Purpose.CLIENT_AUTH)
+         self.assertEqual(ctx.protocol, ssl.PROTOCOL_SSLv23)
+         self.assertEqual(ctx.verify_mode, ssl.CERT_NONE)
+-        self.assertEqual(ctx.options & ssl.OP_NO_SSLv2, ssl.OP_NO_SSLv2)
+-        self.assertEqual(
+-            ctx.options & getattr(ssl, "OP_NO_COMPRESSION", 0),
+-            getattr(ssl, "OP_NO_COMPRESSION", 0),
+-        )
+-        self.assertEqual(
+-            ctx.options & getattr(ssl, "OP_SINGLE_DH_USE", 0),
+-            getattr(ssl, "OP_SINGLE_DH_USE", 0),
+-        )
+-        self.assertEqual(
+-            ctx.options & getattr(ssl, "OP_SINGLE_ECDH_USE", 0),
+-            getattr(ssl, "OP_SINGLE_ECDH_USE", 0),
+-        )
++        self._assert_context_options(ctx)
+ 
+     def test__create_stdlib_context(self):
+         ctx = ssl._create_stdlib_context()
+         self.assertEqual(ctx.protocol, ssl.PROTOCOL_SSLv23)
+         self.assertEqual(ctx.verify_mode, ssl.CERT_NONE)
+         self.assertFalse(ctx.check_hostname)
+-        self.assertEqual(ctx.options & ssl.OP_NO_SSLv2, ssl.OP_NO_SSLv2)
++        self._assert_context_options(ctx)
+ 
+         ctx = ssl._create_stdlib_context(ssl.PROTOCOL_TLSv1)
+         self.assertEqual(ctx.protocol, ssl.PROTOCOL_TLSv1)
+         self.assertEqual(ctx.verify_mode, ssl.CERT_NONE)
+-        self.assertEqual(ctx.options & ssl.OP_NO_SSLv2, ssl.OP_NO_SSLv2)
++        self._assert_context_options(ctx)
+ 
+         ctx = ssl._create_stdlib_context(ssl.PROTOCOL_TLSv1,
+                                          cert_reqs=ssl.CERT_REQUIRED,
+@@ -1263,12 +1267,12 @@ class ContextTests(unittest.TestCase):
+         self.assertEqual(ctx.protocol, ssl.PROTOCOL_TLSv1)
+         self.assertEqual(ctx.verify_mode, ssl.CERT_REQUIRED)
+         self.assertTrue(ctx.check_hostname)
+-        self.assertEqual(ctx.options & ssl.OP_NO_SSLv2, ssl.OP_NO_SSLv2)
++        self._assert_context_options(ctx)
+ 
+         ctx = ssl._create_stdlib_context(purpose=ssl.Purpose.CLIENT_AUTH)
+         self.assertEqual(ctx.protocol, ssl.PROTOCOL_SSLv23)
+         self.assertEqual(ctx.verify_mode, ssl.CERT_NONE)
+-        self.assertEqual(ctx.options & ssl.OP_NO_SSLv2, ssl.OP_NO_SSLv2)
++        self._assert_context_options(ctx)
+ 
+     def test_check_hostname(self):
+         ctx = ssl.SSLContext(ssl.PROTOCOL_TLSv1)
+diff --git a/Modules/_ssl.c b/Modules/_ssl.c
+index 86482677ae..0d5c121d2c 100644
+--- a/Modules/_ssl.c
++++ b/Modules/_ssl.c
+@@ -2330,6 +2330,7 @@ _ssl__SSLContext_impl(PyTypeObject *type, int proto_version)
+     PySSLContext *self;
+     long options;
+     SSL_CTX *ctx = NULL;
++    int result;
+ #if defined(SSL_MODE_RELEASE_BUFFERS)
+     unsigned long libver;
+ #endif
+@@ -2393,8 +2394,38 @@ _ssl__SSLContext_impl(PyTypeObject *type, int proto_version)
+         options |= SSL_OP_NO_SSLv2;
+     if (proto_version != PY_SSL_VERSION_SSL3)
+         options |= SSL_OP_NO_SSLv3;
++    /* Minimal security flags for server and client side context.
++     * Client sockets ignore server-side parameters. */
++#ifdef SSL_OP_NO_COMPRESSION
++    options |= SSL_OP_NO_COMPRESSION;
++#endif
++#ifdef SSL_OP_CIPHER_SERVER_PREFERENCE
++    options |= SSL_OP_CIPHER_SERVER_PREFERENCE;
++#endif
++#ifdef SSL_OP_SINGLE_DH_USE
++    options |= SSL_OP_SINGLE_DH_USE;
++#endif
++#ifdef SSL_OP_SINGLE_ECDH_USE
++    options |= SSL_OP_SINGLE_ECDH_USE;
++#endif
+     SSL_CTX_set_options(self->ctx, options);
+ 
++    /* A bare minimum cipher list without completly broken cipher suites.
++     * It's far from perfect but gives users a better head start. */
++    if (proto_version != PY_SSL_VERSION_SSL2) {
++        result = SSL_CTX_set_cipher_list(ctx, "HIGH:!aNULL:!eNULL:!MD5");
++    } else {
++        /* SSLv2 needs MD5 */
++        result = SSL_CTX_set_cipher_list(ctx, "HIGH:!aNULL:!eNULL");
++    }
++    if (result == 0) {
++        Py_DECREF(self);
++        ERR_clear_error();
++        PyErr_SetString(PySSLErrorObject,
++                        "No cipher can be selected.");
++        return NULL;
++    }
++
+ #if defined(SSL_MODE_RELEASE_BUFFERS)
+     /* Set SSL_MODE_RELEASE_BUFFERS. This potentially greatly reduces memory
+        usage for no cost at all. However, don't do this for OpenSSL versions
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-devtools/python/python3/0001-cross-compile-support.patch b/poky/meta/recipes-devtools/python/python3/0001-cross-compile-support.patch
deleted file mode 100644
index 7cd7e3b..0000000
--- a/poky/meta/recipes-devtools/python/python3/0001-cross-compile-support.patch
+++ /dev/null
@@ -1,96 +0,0 @@
-From ecde3ea170999a9ef734e8af4d7c25be5ba81697 Mon Sep 17 00:00:00 2001
-From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Fri, 31 Mar 2017 15:42:46 +0300
-Subject: [PATCH] cross-compile support
-
-We cross compile python. This patch uses tools from host/native
-python instead of in-tree tools
-
--Khem
-
-Rebased on 3.5.4
-
-Upstream-Status: Inappropriate[Configuration Specific]
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
-Signed-off-by: Derek Straka <derek@asterius.io>
----
- Makefile.pre.in | 14 ++++++++------
- 1 file changed, 8 insertions(+), 6 deletions(-)
-
-diff --git a/Makefile.pre.in b/Makefile.pre.in
-index 144c1f8629..f252ac2417 100644
---- a/Makefile.pre.in
-+++ b/Makefile.pre.in
-@@ -223,6 +223,7 @@ LIBOBJS=	@LIBOBJS@
-
- PYTHON=		python$(EXE)
- BUILDPYTHON=	python$(BUILDEXE)
-+HOSTPYTHON=    $(BUILDPYTHON)
-
- PYTHON_FOR_REGEN=@PYTHON_FOR_REGEN@
- PYTHON_FOR_BUILD=@PYTHON_FOR_BUILD@
-@@ -277,6 +278,7 @@ LIBFFI_INCLUDEDIR=	@LIBFFI_INCLUDEDIR@
- ##########################################################################
- # Parser
- PGEN=		Parser/pgen$(EXE)
-+HOSTPGEN=	$(PGEN)$(EXE)
-
- PSRCS=		\
- 		Parser/acceler.c \
-@@ -478,7 +480,7 @@ build_all_generate_profile:
-
- run_profile_task:
- 	: # FIXME: can't run for a cross build
--	$(LLVM_PROF_FILE) $(RUNSHARED) ./$(BUILDPYTHON) $(PROFILE_TASK) || true
-+	$(LLVM_PROF_FILE) $(RUNSHARED) $(HOSTPYTHON) $(PROFILE_TASK) || true
-
- build_all_merge_profile:
- 	$(LLVM_PROF_MERGER)
-@@ -772,7 +774,7 @@ regen-grammar: $(PGEN)
- 	# Regenerate Include/graminit.h and Python/graminit.c
- 	# from Grammar/Grammar using pgen
- 	@$(MKDIR_P) Include
--	$(PGEN) $(srcdir)/Grammar/Grammar \
-+	$(HOSTPGEN) $(srcdir)/Grammar/Grammar \
- 		$(srcdir)/Include/graminit.h \
- 		$(srcdir)/Python/graminit.c
-
-@@ -978,7 +980,7 @@ $(LIBRARY_OBJS) $(MODOBJS) Programs/python.o: $(PYTHON_HEADERS)
- ######################################################################
-
- TESTOPTS=	$(EXTRATESTOPTS)
--TESTPYTHON=	$(RUNSHARED) ./$(BUILDPYTHON) $(TESTPYTHONOPTS)
-+TESTPYTHON=	$(RUNSHARED) $(HOSTPYTHON) $(TESTPYTHONOPTS)
- TESTRUNNER=	$(TESTPYTHON) $(srcdir)/Tools/scripts/run_tests.py
- TESTTIMEOUT=	3600
-
-@@ -1470,7 +1472,7 @@ frameworkinstallstructure:	$(LDLIBRARY)
- 		fi; \
- 	done
- 	$(LN) -fsn include/python$(LDVERSION) $(DESTDIR)$(prefix)/Headers
--	sed 's/%VERSION%/'"`$(RUNSHARED) ./$(BUILDPYTHON) -c 'import platform; print(platform.python_version())'`"'/g' < $(RESSRCDIR)/Info.plist > $(DESTDIR)$(prefix)/Resources/Info.plist
-+	sed 's/%VERSION%/'"`$(RUNSHARED) $(HOSTPYTHON) -c 'import platform; print(platform.python_version())'`"'/g' < $(RESSRCDIR)/Info.plist > $(DESTDIR)$(prefix)/Resources/Info.plist
- 	$(LN) -fsn $(VERSION) $(DESTDIR)$(PYTHONFRAMEWORKINSTALLDIR)/Versions/Current
- 	$(LN) -fsn Versions/Current/$(PYTHONFRAMEWORK) $(DESTDIR)$(PYTHONFRAMEWORKINSTALLDIR)/$(PYTHONFRAMEWORK)
- 	$(LN) -fsn Versions/Current/Headers $(DESTDIR)$(PYTHONFRAMEWORKINSTALLDIR)/Headers
-@@ -1543,7 +1545,7 @@ Python/dtoa.o: Python/dtoa.c
-
- # Run reindent on the library
- reindent:
--	./$(BUILDPYTHON) $(srcdir)/Tools/scripts/reindent.py -r $(srcdir)/Lib
-+	$(HOSTPYTHON) $(srcdir)/Tools/scripts/reindent.py -r $(srcdir)/Lib
-
- # Rerun configure with the same options as it was run last time,
- # provided the config.status script exists
-@@ -1678,7 +1680,7 @@ funny:
-
- # Perform some verification checks on any modified files.
- patchcheck: @DEF_MAKE_RULE@
--	$(RUNSHARED) ./$(BUILDPYTHON) $(srcdir)/Tools/scripts/patchcheck.py
-+	$(RUNSHARED) $(HOSTPYTHON) $(srcdir)/Tools/scripts/patchcheck.py
-
- # Dependencies
-
---
-2.11.0
-
diff --git a/poky/meta/recipes-devtools/python/python3/0002-Makefile-add-target-to-split-profile-generation.patch b/poky/meta/recipes-devtools/python/python3/0002-Makefile-add-target-to-split-profile-generation.patch
new file mode 100644
index 0000000..2b4ba31
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3/0002-Makefile-add-target-to-split-profile-generation.patch
@@ -0,0 +1,40 @@
+From 98586d6dc598e40b8b821b0dde57599e188a7ca4 Mon Sep 17 00:00:00 2001
+From: Anuj Mittal <anuj.mittal@intel.com>
+Date: Tue, 7 Aug 2018 16:43:17 +0800
+Subject: [PATCH 2/2] Makefile: add target to split profile generation
+
+We don't want to have profile task invoked from here and want to use
+qemu-user instead. Split the profile-opt task so qemu can be invoked
+once binaries have been built with instrumentation and then we can go
+ahead and build again using the profile data generated.
+
+Upstream-Status: Inappropriate [OE-specific]
+
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+---
+ Makefile.pre.in | 6 ++----
+ 1 file changed, 2 insertions(+), 4 deletions(-)
+
+diff --git a/Makefile.pre.in b/Makefile.pre.in
+index 84bc3ff..017a2c4 100644
+--- a/Makefile.pre.in
++++ b/Makefile.pre.in
+@@ -469,13 +469,12 @@ profile-opt:
+ 	$(MAKE) profile-removal
+ 	$(MAKE) build_all_generate_profile
+ 	$(MAKE) profile-removal
+-	@echo "Running code to generate profile data (this can take a while):"
+-	$(MAKE) run_profile_task
+-	$(MAKE) build_all_merge_profile
++
++clean_and_use_profile:
+ 	@echo "Rebuilding with profile guided optimizations:"
+ 	$(MAKE) clean
+ 	$(MAKE) build_all_use_profile
+ 	$(MAKE) profile-removal
+ 
+ build_all_generate_profile:
+ 	$(MAKE) @DEF_MAKE_RULE@ CFLAGS_NODIST="$(CFLAGS) $(EXTRA_CFLAGS) $(PGO_PROF_GEN_FLAG) @LTOFLAGS@" LDFLAGS="$(LDFLAGS) $(PGO_PROF_GEN_FLAG) @LTOFLAGS@" LIBS="$(LIBS)"
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-devtools/python/python3/0002-bpo-29136-Add-TLS-1.3-cipher-suites-and-OP_NO_TLSv1_.patch b/poky/meta/recipes-devtools/python/python3/0002-bpo-29136-Add-TLS-1.3-cipher-suites-and-OP_NO_TLSv1_.patch
new file mode 100644
index 0000000..d48cad7
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3/0002-bpo-29136-Add-TLS-1.3-cipher-suites-and-OP_NO_TLSv1_.patch
@@ -0,0 +1,227 @@
+From e950ea68dab006944af194c9910b8f2341d1437d Mon Sep 17 00:00:00 2001
+From: Christian Heimes <christian@python.org>
+Date: Thu, 7 Sep 2017 20:23:52 -0700
+Subject: [PATCH] bpo-29136: Add TLS 1.3 cipher suites and OP_NO_TLSv1_3
+ (GH-1363) (#3444)
+
+* bpo-29136: Add TLS 1.3 support
+
+TLS 1.3 introduces a new, distinct set of cipher suites. The TLS 1.3
+cipher suites don't overlap with cipher suites from TLS 1.2 and earlier.
+Since Python sets its own set of permitted ciphers, TLS 1.3 handshake
+will fail as soon as OpenSSL 1.1.1 is released. Let's enable the common
+AES-GCM and ChaCha20 suites.
+
+Additionally the flag OP_NO_TLSv1_3 is added. It defaults to 0 (no op) with
+OpenSSL prior to 1.1.1. This allows applications to opt-out from TLS 1.3
+now.
+
+Signed-off-by: Christian Heimes <christian@python.org>.
+(cherry picked from commit cb5b68abdeb1b1d56c581d5b4d647018703d61e3)
+
+Upstream-Status: Backport
+[https://github.com/python/cpython/commit/cb5b68abdeb1b1d56c581d5b4d647018703d61e3]
+
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+---
+ Doc/library/ssl.rst                           | 21 ++++++++++++++
+ Lib/ssl.py                                    |  7 +++++
+ Lib/test/test_ssl.py                          | 29 ++++++++++++++++++-
+ .../2017-09-04-16-39-49.bpo-29136.vSn1oR.rst  |  1 +
+ Modules/_ssl.c                                | 13 +++++++++
+ 5 files changed, 70 insertions(+), 1 deletion(-)
+ create mode 100644 Misc/NEWS.d/next/Library/2017-09-04-16-39-49.bpo-29136.vSn1oR.rst
+
+diff --git a/Doc/library/ssl.rst b/Doc/library/ssl.rst
+index 14f2d68217..29c5e94cf6 100644
+--- a/Doc/library/ssl.rst
++++ b/Doc/library/ssl.rst
+@@ -285,6 +285,11 @@ purposes.
+ 
+      3DES was dropped from the default cipher string.
+ 
++   .. versionchanged:: 3.7
++
++     TLS 1.3 cipher suites TLS_AES_128_GCM_SHA256, TLS_AES_256_GCM_SHA384,
++     and TLS_CHACHA20_POLY1305_SHA256 were added to the default cipher string.
++
+ 
+ Random generation
+ ^^^^^^^^^^^^^^^^^
+@@ -719,6 +724,16 @@ Constants
+ 
+    .. versionadded:: 3.4
+ 
++.. data:: OP_NO_TLSv1_3
++
++   Prevents a TLSv1.3 connection. This option is only applicable in conjunction
++   with :const:`PROTOCOL_TLS`. It prevents the peers from choosing TLSv1.3 as
++   the protocol version. TLS 1.3 is available with OpenSSL 1.1.1 or later.
++   When Python has been compiled against an older version of OpenSSL, the
++   flag defaults to *0*.
++
++   .. versionadded:: 3.7
++
+ .. data:: OP_CIPHER_SERVER_PREFERENCE
+ 
+    Use the server's cipher ordering preference, rather than the client's.
+@@ -783,6 +798,12 @@ Constants
+ 
+    .. versionadded:: 3.3
+ 
++.. data:: HAS_TLSv1_3
++
++   Whether the OpenSSL library has built-in support for the TLS 1.3 protocol.
++
++   .. versionadded:: 3.7
++
+ .. data:: CHANNEL_BINDING_TYPES
+ 
+    List of supported TLS channel binding types.  Strings in this list
+diff --git a/Lib/ssl.py b/Lib/ssl.py
+index 4d302a78fa..f233e72e1f 100644
+--- a/Lib/ssl.py
++++ b/Lib/ssl.py
+@@ -122,6 +122,7 @@ _import_symbols('OP_')
+ _import_symbols('ALERT_DESCRIPTION_')
+ _import_symbols('SSL_ERROR_')
+ _import_symbols('VERIFY_')
++from _ssl import HAS_SNI, HAS_ECDH, HAS_NPN, HAS_ALPN, HAS_TLSv1_3
+ 
+ from _ssl import HAS_SNI, HAS_ECDH, HAS_NPN, HAS_ALPN
+ 
+@@ -162,6 +163,7 @@ else:
+ # (OpenSSL's default setting is 'DEFAULT:!aNULL:!eNULL')
+ # Enable a better set of ciphers by default
+ # This list has been explicitly chosen to:
++#   * TLS 1.3 ChaCha20 and AES-GCM cipher suites
+ #   * Prefer cipher suites that offer perfect forward secrecy (DHE/ECDHE)
+ #   * Prefer ECDHE over DHE for better performance
+ #   * Prefer AEAD over CBC for better performance and security
+@@ -173,6 +175,8 @@ else:
+ #   * Disable NULL authentication, NULL encryption, 3DES and MD5 MACs
+ #     for security reasons
+ _DEFAULT_CIPHERS = (
++    'TLS13-AES-256-GCM-SHA384:TLS13-CHACHA20-POLY1305-SHA256:'
++    'TLS13-AES-128-GCM-SHA256:'
+     'ECDH+AESGCM:ECDH+CHACHA20:DH+AESGCM:DH+CHACHA20:ECDH+AES256:DH+AES256:'
+     'ECDH+AES128:DH+AES:ECDH+HIGH:DH+HIGH:RSA+AESGCM:RSA+AES:RSA+HIGH:'
+     '!aNULL:!eNULL:!MD5:!3DES'
+@@ -180,6 +184,7 @@ _DEFAULT_CIPHERS = (
+ 
+ # Restricted and more secure ciphers for the server side
+ # This list has been explicitly chosen to:
++#   * TLS 1.3 ChaCha20 and AES-GCM cipher suites
+ #   * Prefer cipher suites that offer perfect forward secrecy (DHE/ECDHE)
+ #   * Prefer ECDHE over DHE for better performance
+ #   * Prefer AEAD over CBC for better performance and security
+@@ -190,6 +195,8 @@ _DEFAULT_CIPHERS = (
+ #   * Disable NULL authentication, NULL encryption, MD5 MACs, DSS, RC4, and
+ #     3DES for security reasons
+ _RESTRICTED_SERVER_CIPHERS = (
++    'TLS13-AES-256-GCM-SHA384:TLS13-CHACHA20-POLY1305-SHA256:'
++    'TLS13-AES-128-GCM-SHA256:'
+     'ECDH+AESGCM:ECDH+CHACHA20:DH+AESGCM:DH+CHACHA20:ECDH+AES256:DH+AES256:'
+     'ECDH+AES128:DH+AES:ECDH+HIGH:DH+HIGH:RSA+AESGCM:RSA+AES:RSA+HIGH:'
+     '!aNULL:!eNULL:!MD5:!DSS:!RC4:!3DES'
+diff --git a/Lib/test/test_ssl.py b/Lib/test/test_ssl.py
+index f91af7bd05..1acc12ec2d 100644
+--- a/Lib/test/test_ssl.py
++++ b/Lib/test/test_ssl.py
+@@ -150,6 +150,13 @@ class BasicSocketTests(unittest.TestCase):
+             ssl.OP_NO_COMPRESSION
+         self.assertIn(ssl.HAS_SNI, {True, False})
+         self.assertIn(ssl.HAS_ECDH, {True, False})
++        ssl.OP_NO_SSLv2
++        ssl.OP_NO_SSLv3
++        ssl.OP_NO_TLSv1
++        ssl.OP_NO_TLSv1_3
++    if ssl.OPENSSL_VERSION_INFO >= (1, 0, 1):
++            ssl.OP_NO_TLSv1_1
++            ssl.OP_NO_TLSv1_2
+ 
+     def test_str_for_enums(self):
+         # Make sure that the PROTOCOL_* constants have enum-like string
+@@ -3028,12 +3035,33 @@ else:
+                     self.assertEqual(s.version(), 'TLSv1')
+                 self.assertIs(s.version(), None)
+ 
++        @unittest.skipUnless(ssl.HAS_TLSv1_3,
++                             "test requires TLSv1.3 enabled OpenSSL")
++        def test_tls1_3(self):
++            context = ssl.SSLContext(ssl.PROTOCOL_TLS)
++            context.load_cert_chain(CERTFILE)
++            # disable all but TLS 1.3
++            context.options |= (
++                ssl.OP_NO_TLSv1 | ssl.OP_NO_TLSv1_1 | ssl.OP_NO_TLSv1_2
++            )
++            with ThreadedEchoServer(context=context) as server:
++                with context.wrap_socket(socket.socket()) as s:
++                    s.connect((HOST, server.port))
++                    self.assertIn(s.cipher()[0], [
++                        'TLS13-AES-256-GCM-SHA384',
++                        'TLS13-CHACHA20-POLY1305-SHA256',
++                        'TLS13-AES-128-GCM-SHA256',
++                    ])
++
+         @unittest.skipUnless(ssl.HAS_ECDH, "test requires ECDH-enabled OpenSSL")
+         def test_default_ecdh_curve(self):
+             # Issue #21015: elliptic curve-based Diffie Hellman key exchange
+             # should be enabled by default on SSL contexts.
+             context = ssl.SSLContext(ssl.PROTOCOL_SSLv23)
+             context.load_cert_chain(CERTFILE)
++            # TLSv1.3 defaults to PFS key agreement and no longer has KEA in
++            # cipher name.
++            context.options |= ssl.OP_NO_TLSv1_3
+             # Prior to OpenSSL 1.0.0, ECDH ciphers have to be enabled
+             # explicitly using the 'ECCdraft' cipher alias.  Otherwise,
+             # our default cipher list should prefer ECDH-based ciphers
+@@ -3394,7 +3422,6 @@ else:
+                         s.sendfile(file)
+                         self.assertEqual(s.recv(1024), TEST_DATA)
+ 
+-
+ def test_main(verbose=False):
+     if support.verbose:
+         import warnings
+diff --git a/Misc/NEWS.d/next/Library/2017-09-04-16-39-49.bpo-29136.vSn1oR.rst b/Misc/NEWS.d/next/Library/2017-09-04-16-39-49.bpo-29136.vSn1oR.rst
+new file mode 100644
+index 0000000000..e76997ef83
+--- /dev/null
++++ b/Misc/NEWS.d/next/Library/2017-09-04-16-39-49.bpo-29136.vSn1oR.rst
+@@ -0,0 +1 @@
++Add TLS 1.3 cipher suites and OP_NO_TLSv1_3.
+diff --git a/Modules/_ssl.c b/Modules/_ssl.c
+index 0d5c121d2c..c71d89607c 100644
+--- a/Modules/_ssl.c
++++ b/Modules/_ssl.c
+@@ -4842,6 +4842,11 @@ PyInit__ssl(void)
+ #if HAVE_TLSv1_2
+     PyModule_AddIntConstant(m, "OP_NO_TLSv1_1", SSL_OP_NO_TLSv1_1);
+     PyModule_AddIntConstant(m, "OP_NO_TLSv1_2", SSL_OP_NO_TLSv1_2);
++#endif
++#ifdef SSL_OP_NO_TLSv1_3
++    PyModule_AddIntConstant(m, "OP_NO_TLSv1_3", SSL_OP_NO_TLSv1_3);
++#else
++    PyModule_AddIntConstant(m, "OP_NO_TLSv1_3", 0);
+ #endif
+     PyModule_AddIntConstant(m, "OP_CIPHER_SERVER_PREFERENCE",
+                             SSL_OP_CIPHER_SERVER_PREFERENCE);
+@@ -4890,6 +4895,14 @@ PyInit__ssl(void)
+     Py_INCREF(r);
+     PyModule_AddObject(m, "HAS_ALPN", r);
+ 
++#if defined(TLS1_3_VERSION) && !defined(OPENSSL_NO_TLS1_3)
++    r = Py_True;
++#else
++    r = Py_False;
++#endif
++    Py_INCREF(r);
++    PyModule_AddObject(m, "HAS_TLSv1_3", r);
++
+     /* Mappings for error codes */
+     err_codes_to_names = PyDict_New();
+     err_names_to_codes = PyDict_New();
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-devtools/python/python3/0003-bpo-32947-Fixes-for-TLS-1.3-and-OpenSSL-1.1.1-GH-876.patch b/poky/meta/recipes-devtools/python/python3/0003-bpo-32947-Fixes-for-TLS-1.3-and-OpenSSL-1.1.1-GH-876.patch
new file mode 100644
index 0000000..56d591d
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3/0003-bpo-32947-Fixes-for-TLS-1.3-and-OpenSSL-1.1.1-GH-876.patch
@@ -0,0 +1,173 @@
+From 170a614904febd14ff6cfd7a75c9bccc114b3948 Mon Sep 17 00:00:00 2001
+From: Christian Heimes <christian@python.org>
+Date: Tue, 14 Aug 2018 16:56:32 +0200
+Subject: [PATCH] bpo-32947: Fixes for TLS 1.3 and OpenSSL 1.1.1 (GH-8761)
+
+Backport of TLS 1.3 related fixes from 3.7.
+
+Misc fixes and workarounds for compatibility with OpenSSL 1.1.1 from git
+master and TLS 1.3 support. With OpenSSL 1.1.1, Python negotiates TLS 1.3 by
+default. Some test cases only apply to TLS 1.2.
+
+OpenSSL 1.1.1 has added a new option OP_ENABLE_MIDDLEBOX_COMPAT for TLS
+1.3. The feature is enabled by default for maximum compatibility with
+broken middle boxes. Users should be able to disable the hack and CPython's test suite needs
+it to verify default options
+
+Signed-off-by: Christian Heimes <christian@python.org>
+
+Upstream-Status: Backport
+[https://github.com/python/cpython/commit/2a4ee8aa01d61b6a9c8e9c65c211e61bdb471826]
+
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+---
+ Doc/library/ssl.rst                           |  9 ++++++
+ Lib/test/test_asyncio/test_events.py          |  6 +++-
+ Lib/test/test_ssl.py                          | 29 +++++++++++++++----
+ .../2018-08-14-08-57-01.bpo-32947.mqStVW.rst  |  2 ++
+ Modules/_ssl.c                                |  4 +++
+ 5 files changed, 44 insertions(+), 6 deletions(-)
+ create mode 100644 Misc/NEWS.d/next/Library/2018-08-14-08-57-01.bpo-32947.mqStVW.rst
+
+diff --git a/Doc/library/ssl.rst b/Doc/library/ssl.rst
+index 29c5e94cf6..f63a3deec5 100644
+--- a/Doc/library/ssl.rst
++++ b/Doc/library/ssl.rst
+@@ -757,6 +757,15 @@ Constants
+ 
+    .. versionadded:: 3.3
+ 
++.. data:: OP_ENABLE_MIDDLEBOX_COMPAT
++
++   Send dummy Change Cipher Spec (CCS) messages in TLS 1.3 handshake to make
++   a TLS 1.3 connection look more like a TLS 1.2 connection.
++
++   This option is only available with OpenSSL 1.1.1 and later.
++
++   .. versionadded:: 3.6.7
++
+ .. data:: OP_NO_COMPRESSION
+ 
+    Disable compression on the SSL channel.  This is useful if the application
+diff --git a/Lib/test/test_asyncio/test_events.py b/Lib/test/test_asyncio/test_events.py
+index 492a84a231..6f208474b9 100644
+--- a/Lib/test/test_asyncio/test_events.py
++++ b/Lib/test/test_asyncio/test_events.py
+@@ -1169,7 +1169,11 @@ class EventLoopTestsMixin:
+                     self.loop.run_until_complete(f_c)
+ 
+         # close connection
+-        proto.transport.close()
++        # transport may be None with TLS 1.3, because connection is
++        # interrupted, server is unable to send session tickets, and
++        # transport is closed.
++        if proto.transport is not None:
++            proto.transport.close()
+         server.close()
+ 
+     def test_legacy_create_server_ssl_match_failed(self):
+diff --git a/Lib/test/test_ssl.py b/Lib/test/test_ssl.py
+index 1acc12ec2d..a2e1d32a62 100644
+--- a/Lib/test/test_ssl.py
++++ b/Lib/test/test_ssl.py
+@@ -78,6 +78,7 @@ OP_NO_COMPRESSION = getattr(ssl, "OP_NO_COMPRESSION", 0)
+ OP_SINGLE_DH_USE = getattr(ssl, "OP_SINGLE_DH_USE", 0)
+ OP_SINGLE_ECDH_USE = getattr(ssl, "OP_SINGLE_ECDH_USE", 0)
+ OP_CIPHER_SERVER_PREFERENCE = getattr(ssl, "OP_CIPHER_SERVER_PREFERENCE", 0)
++OP_ENABLE_MIDDLEBOX_COMPAT = getattr(ssl, "OP_ENABLE_MIDDLEBOX_COMPAT", 0)
+ 
+ 
+ def handle_error(prefix):
+@@ -155,8 +156,8 @@ class BasicSocketTests(unittest.TestCase):
+         ssl.OP_NO_TLSv1
+         ssl.OP_NO_TLSv1_3
+     if ssl.OPENSSL_VERSION_INFO >= (1, 0, 1):
+-            ssl.OP_NO_TLSv1_1
+-            ssl.OP_NO_TLSv1_2
++        ssl.OP_NO_TLSv1_1
++        ssl.OP_NO_TLSv1_2
+ 
+     def test_str_for_enums(self):
+         # Make sure that the PROTOCOL_* constants have enum-like string
+@@ -854,7 +855,8 @@ class ContextTests(unittest.TestCase):
+         default = (ssl.OP_ALL | ssl.OP_NO_SSLv2 | ssl.OP_NO_SSLv3)
+         # SSLContext also enables these by default
+         default |= (OP_NO_COMPRESSION | OP_CIPHER_SERVER_PREFERENCE |
+-                    OP_SINGLE_DH_USE | OP_SINGLE_ECDH_USE)
++                    OP_SINGLE_DH_USE | OP_SINGLE_ECDH_USE |
++                    OP_ENABLE_MIDDLEBOX_COMPAT)
+         self.assertEqual(default, ctx.options)
+         ctx.options |= ssl.OP_NO_TLSv1
+         self.assertEqual(default | ssl.OP_NO_TLSv1, ctx.options)
+@@ -1860,11 +1862,26 @@ else:
+                         self.sock, server_side=True)
+                     self.server.selected_npn_protocols.append(self.sslconn.selected_npn_protocol())
+                     self.server.selected_alpn_protocols.append(self.sslconn.selected_alpn_protocol())
+-                except (ssl.SSLError, ConnectionResetError) as e:
++                except (ConnectionResetError, BrokenPipeError) as e:
+                     # We treat ConnectionResetError as though it were an
+                     # SSLError - OpenSSL on Ubuntu abruptly closes the
+                     # connection when asked to use an unsupported protocol.
+                     #
++                    # BrokenPipeError is raised in TLS 1.3 mode, when OpenSSL
++                    # tries to send session tickets after handshake.
++                    # https://github.com/openssl/openssl/issues/6342
++                    self.server.conn_errors.append(str(e))
++                    if self.server.chatty:
++                        handle_error(
++                            "\n server:  bad connection attempt from " + repr(
++                                self.addr) + ":\n")
++                    self.running = False
++                    self.close()
++                    return False
++                except (ssl.SSLError, OSError) as e:
++                    # OSError may occur with wrong protocols, e.g. both
++                    # sides use PROTOCOL_TLS_SERVER.
++                    #
+                     # XXX Various errors can have happened here, for example
+                     # a mismatching protocol version, an invalid certificate,
+                     # or a low-level bug. This should be made more discriminating.
+@@ -2974,7 +2991,7 @@ else:
+                 # Block on the accept and wait on the connection to close.
+                 evt.set()
+                 remote, peer = server.accept()
+-                remote.recv(1)
++                remote.send(remote.recv(4))
+ 
+             t = threading.Thread(target=serve)
+             t.start()
+@@ -2982,6 +2999,8 @@ else:
+             evt.wait()
+             client = context.wrap_socket(socket.socket())
+             client.connect((host, port))
++            client.send(b'data')
++            client.recv()
+             client_addr = client.getsockname()
+             client.close()
+             t.join()
+diff --git a/Misc/NEWS.d/next/Library/2018-08-14-08-57-01.bpo-32947.mqStVW.rst b/Misc/NEWS.d/next/Library/2018-08-14-08-57-01.bpo-32947.mqStVW.rst
+new file mode 100644
+index 0000000000..28de360c36
+--- /dev/null
++++ b/Misc/NEWS.d/next/Library/2018-08-14-08-57-01.bpo-32947.mqStVW.rst
+@@ -0,0 +1,2 @@
++Add OP_ENABLE_MIDDLEBOX_COMPAT and test workaround for TLSv1.3 for future
++compatibility with OpenSSL 1.1.1.
+diff --git a/Modules/_ssl.c b/Modules/_ssl.c
+index c71d89607c..eb123a87ba 100644
+--- a/Modules/_ssl.c
++++ b/Modules/_ssl.c
+@@ -4858,6 +4858,10 @@ PyInit__ssl(void)
+     PyModule_AddIntConstant(m, "OP_NO_COMPRESSION",
+                             SSL_OP_NO_COMPRESSION);
+ #endif
++#ifdef SSL_OP_ENABLE_MIDDLEBOX_COMPAT
++    PyModule_AddIntConstant(m, "OP_ENABLE_MIDDLEBOX_COMPAT",
++                            SSL_OP_ENABLE_MIDDLEBOX_COMPAT);
++#endif
+ 
+ #if HAVE_SNI
+     r = Py_True;
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-devtools/python/python3/0004-bpo-33570-TLS-1.3-ciphers-for-OpenSSL-1.1.1-GH-6976.patch b/poky/meta/recipes-devtools/python/python3/0004-bpo-33570-TLS-1.3-ciphers-for-OpenSSL-1.1.1-GH-6976.patch
new file mode 100644
index 0000000..b97d550
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3/0004-bpo-33570-TLS-1.3-ciphers-for-OpenSSL-1.1.1-GH-6976.patch
@@ -0,0 +1,110 @@
+From 0c9354362bfa5f90fbea8ff8237a1f1f5dba686f Mon Sep 17 00:00:00 2001
+From: Christian Heimes <christian@python.org>
+Date: Wed, 12 Sep 2018 15:20:31 +0800
+Subject: [PATCH] bpo-33570: TLS 1.3 ciphers for OpenSSL 1.1.1 (GH-6976)
+
+Change TLS 1.3 cipher suite settings for compatibility with OpenSSL
+1.1.1-pre6 and newer. OpenSSL 1.1.1 will have TLS 1.3 cipers enabled by
+default.
+
+Also update multissltests and Travis config to test with latest OpenSSL.
+
+Signed-off-by: Christian Heimes <christian@python.org>
+(cherry picked from commit e8eb6cb7920ded66abc5d284319a8539bdc2bae3)
+
+Co-authored-by: Christian Heimes <christian@python.org
+
+Upstream-Status: Backport
+[https://github.com/python/cpython/commit/3e630c541b35c96bfe5619165255e559f577ee71]
+
+Tweaked patch to not take changes for multissltests and Travis config.
+
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+---
+ Lib/test/test_ssl.py | 51 ++++++++++++++++++++++----------------------
+ 1 file changed, 26 insertions(+), 25 deletions(-)
+
+diff --git a/Lib/test/test_ssl.py b/Lib/test/test_ssl.py
+index a2e1d32a62..c484ead5ff 100644
+--- a/Lib/test/test_ssl.py
++++ b/Lib/test/test_ssl.py
+@@ -3024,17 +3024,21 @@ else:
+                     sock.do_handshake()
+                 self.assertEqual(cm.exception.errno, errno.ENOTCONN)
+ 
+-        def test_default_ciphers(self):
+-            context = ssl.SSLContext(ssl.PROTOCOL_SSLv23)
+-            try:
+-                # Force a set of weak ciphers on our client context
+-                context.set_ciphers("DES")
+-            except ssl.SSLError:
+-                self.skipTest("no DES cipher available")
+-            with ThreadedEchoServer(CERTFILE,
+-                                    ssl_version=ssl.PROTOCOL_SSLv23,
+-                                    chatty=False) as server:
+-                with context.wrap_socket(socket.socket()) as s:
++        def test_no_shared_ciphers(self):
++            server_context = ssl.SSLContext(ssl.PROTOCOL_SSLv23)
++            server_context.load_cert_chain(SIGNED_CERTFILE)
++            client_context = ssl.SSLContext(ssl.PROTOCOL_SSLv23)
++            client_context.verify_mode = ssl.CERT_REQUIRED
++            client_context.check_hostname = True
++
++            client_context.set_ciphers("AES128")
++            server_context.set_ciphers("AES256")
++            # OpenSSL enables all TLS 1.3 ciphers, enforce TLS 1.2 for test
++            client_context.options |= ssl.OP_NO_TLSv1_3
++            with ThreadedEchoServer(context=server_context) as server:
++                with client_context.wrap_socket(
++                        socket.socket(),
++                        server_hostname="localhost") as s:
+                     with self.assertRaises(OSError):
+                         s.connect((HOST, server.port))
+             self.assertIn("no shared cipher", str(server.conn_errors[0]))
+@@ -3067,9 +3071,9 @@ else:
+                 with context.wrap_socket(socket.socket()) as s:
+                     s.connect((HOST, server.port))
+                     self.assertIn(s.cipher()[0], [
+-                        'TLS13-AES-256-GCM-SHA384',
+-                        'TLS13-CHACHA20-POLY1305-SHA256',
+-                        'TLS13-AES-128-GCM-SHA256',
++                        'TLS_AES_256_GCM_SHA384',
++                        'TLS_CHACHA20_POLY1305_SHA256',
++                        'TLS_AES_128_GCM_SHA256',
+                     ])
+ 
+         @unittest.skipUnless(ssl.HAS_ECDH, "test requires ECDH-enabled OpenSSL")
+@@ -3391,22 +3395,19 @@ else:
+             client_context = ssl.SSLContext(ssl.PROTOCOL_TLSv1)
+             client_context.verify_mode = ssl.CERT_REQUIRED
+             client_context.load_verify_locations(SIGNING_CA)
+-            if ssl.OPENSSL_VERSION_INFO >= (1, 0, 2):
+-                client_context.set_ciphers("AES128:AES256")
+-                server_context.set_ciphers("AES256")
+-                alg1 = "AES256"
+-                alg2 = "AES-256"
+-            else:
+-                client_context.set_ciphers("AES:3DES")
+-                server_context.set_ciphers("3DES")
+-                alg1 = "3DES"
+-                alg2 = "DES-CBC3"
++            client_context.set_ciphers("AES128:AES256")
++            server_context.set_ciphers("AES256")
++            expected_algs = [
++                "AES256", "AES-256",
++                 # TLS 1.3 ciphers are always enabled
++                 "TLS_CHACHA20", "TLS_AES",
++            ]
+ 
+             stats = server_params_test(client_context, server_context)
+             ciphers = stats['server_shared_ciphers'][0]
+             self.assertGreater(len(ciphers), 0)
+             for name, tls_version, bits in ciphers:
+-                if not alg1 in name.split("-") and alg2 not in name:
++                if not any (alg in name for alg in expected_algs):
+                     self.fail(name)
+ 
+         def test_read_write_after_close_raises_valuerror(self):
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-devtools/python/python3/0005-bpo-30714-ALPN-changes-for-OpenSSL-1.1.0f-2305.patch b/poky/meta/recipes-devtools/python/python3/0005-bpo-30714-ALPN-changes-for-OpenSSL-1.1.0f-2305.patch
new file mode 100644
index 0000000..d609847
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3/0005-bpo-30714-ALPN-changes-for-OpenSSL-1.1.0f-2305.patch
@@ -0,0 +1,68 @@
+From 7b40cb7293cb14e5c7c8ed123efaf9acb33edae2 Mon Sep 17 00:00:00 2001
+From: Christian Heimes <christian@python.org>
+Date: Tue, 15 Aug 2017 10:33:43 +0200
+Subject: [PATCH] bpo-30714: ALPN changes for OpenSSL 1.1.0f (#2305)
+
+OpenSSL 1.1.0 to 1.1.0e aborted the handshake when server and client
+could not agree on a protocol using ALPN. OpenSSL 1.1.0f changed that.
+The most recent version now behaves like OpenSSL 1.0.2 again. The ALPN
+callback can pretend to not been set.
+
+See https://github.com/openssl/openssl/pull/3158 for more details
+
+Signed-off-by: Christian Heimes <christian@python.org>
+
+Upstream-Status: Backport
+[https://github.com/python/cpython/commit/7b40cb7293cb14e5c7c8ed123efaf9acb33edae2]
+
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+---
+ Doc/library/ssl.rst                                          | 5 +++--
+ Lib/test/test_ssl.py                                         | 5 +++--
+ .../next/Tests/2017-07-25-15-27-44.bpo-30715.Sp7bTF.rst      | 2 ++
+ 3 files changed, 8 insertions(+), 4 deletions(-)
+ create mode 100644 Misc/NEWS.d/next/Tests/2017-07-25-15-27-44.bpo-30715.Sp7bTF.rst
+
+diff --git a/Doc/library/ssl.rst b/Doc/library/ssl.rst
+index 729a239a1b..0a09e7e9d4 100644
+--- a/Doc/library/ssl.rst
++++ b/Doc/library/ssl.rst
+@@ -1447,8 +1447,9 @@ to speed up repeated connections from the same clients.
+    This method will raise :exc:`NotImplementedError` if :data:`HAS_ALPN` is
+    False.
+ 
+-   OpenSSL 1.1.0+ will abort the handshake and raise :exc:`SSLError` when
+-   both sides support ALPN but cannot agree on a protocol.
++   OpenSSL 1.1.0 to 1.1.0e will abort the handshake and raise :exc:`SSLError`
++   when both sides support ALPN but cannot agree on a protocol. 1.1.0f+
++   behaves like 1.0.2, :meth:`SSLSocket.selected_alpn_protocol` returns None.
+ 
+    .. versionadded:: 3.5
+ 
+diff --git a/Lib/test/test_ssl.py b/Lib/test/test_ssl.py
+index d960d82065..104b7f377a 100644
+--- a/Lib/test/test_ssl.py
++++ b/Lib/test/test_ssl.py
+@@ -3268,8 +3268,9 @@ if _have_threads:
+                 except ssl.SSLError as e:
+                     stats = e
+ 
+-                if expected is None and IS_OPENSSL_1_1:
+-                    # OpenSSL 1.1.0 raises handshake error
++                if (expected is None and IS_OPENSSL_1_1
++                        and ssl.OPENSSL_VERSION_INFO < (1, 1, 0, 6)):
++                    # OpenSSL 1.1.0 to 1.1.0e raises handshake error
+                     self.assertIsInstance(stats, ssl.SSLError)
+                 else:
+                     msg = "failed trying %s (s) and %s (c).\n" \
+diff --git a/Misc/NEWS.d/next/Tests/2017-07-25-15-27-44.bpo-30715.Sp7bTF.rst b/Misc/NEWS.d/next/Tests/2017-07-25-15-27-44.bpo-30715.Sp7bTF.rst
+new file mode 100644
+index 0000000000..88394e585c
+--- /dev/null
++++ b/Misc/NEWS.d/next/Tests/2017-07-25-15-27-44.bpo-30715.Sp7bTF.rst
+@@ -0,0 +1,2 @@
++Address ALPN callback changes for OpenSSL 1.1.0f. The latest version behaves
++like OpenSSL 1.0.2 and no longer aborts handshake.
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-devtools/python/python3/CVE-2018-1061.patch b/poky/meta/recipes-devtools/python/python3/CVE-2018-1061.patch
deleted file mode 100644
index 6373be3..0000000
--- a/poky/meta/recipes-devtools/python/python3/CVE-2018-1061.patch
+++ /dev/null
@@ -1,165 +0,0 @@
-From 6d7ef39198856395edd62ef143bfcfaaf2ed6e25 Mon Sep 17 00:00:00 2001
-From: Ned Deily <nad@python.org>
-Date: Sun, 11 Mar 2018 14:29:05 -0400
-Subject: [PATCH] [3.5] bpo-32981: Fix catastrophic backtracking vulns
- (GH-5955) (#6034)
-
-* Prevent low-grade poplib REDOS (CVE-2018-1060)
-
-The regex to test a mail server's timestamp is susceptible to
-catastrophic backtracking on long evil responses from the server.
-
-Happily, the maximum length of malicious inputs is 2K thanks
-to a limit introduced in the fix for CVE-2013-1752.
-
-A 2KB evil response from the mail server would result in small slowdowns
-(milliseconds vs. microseconds) accumulated over many apop calls.
-This is a potential DOS vector via accumulated slowdowns.
-
-Replace it with a similar non-vulnerable regex.
-
-The new regex is RFC compliant.
-The old regex was non-compliant in edge cases.
-
-* Prevent difflib REDOS (CVE-2018-1061)
-
-The default regex for IS_LINE_JUNK is susceptible to
-catastrophic backtracking.
-This is a potential DOS vector.
-
-Replace it with an equivalent non-vulnerable regex.
-
-Also introduce unit and REDOS tests for difflib.
-
-Co-authored-by: Tim Peters <tim.peters@gmail.com>
-Co-authored-by: Christian Heimes <christian@python.org>.
-(cherry picked from commit 0e6c8ee2358a2e23117501826c008842acb835ac)
-CVE: CVE-2018-1061
-CVE: CVE-2018-1060
-Upstream-Status: Backport [https://github.com/python/cpython/commit/937ac1fe069a4dc8471dff205f553d82e724015b]
-Signed-off-by: Sinan Kaya <okaya@kernel.org>
----
- Lib/difflib.py                                |  2 +-
- Lib/poplib.py                                 |  2 +-
- Lib/test/test_difflib.py                      | 22 ++++++++++++++++++-
- Lib/test/test_poplib.py                       | 12 +++++++++-
- Misc/ACKS                                     |  1 +
- .../2018-03-02-10-24-52.bpo-32981.O_qDyj.rst  |  4 ++++
- 6 files changed, 39 insertions(+), 4 deletions(-)
- create mode 100644 Misc/NEWS.d/next/Security/2018-03-02-10-24-52.bpo-32981.O_qDyj.rst
-
-diff --git a/Lib/difflib.py b/Lib/difflib.py
-index 076bbac01d..b4ec335056 100644
---- a/Lib/difflib.py
-+++ b/Lib/difflib.py
-@@ -1083,7 +1083,7 @@ class Differ:
- 
- import re
- 
--def IS_LINE_JUNK(line, pat=re.compile(r"\s*#?\s*$").match):
-+def IS_LINE_JUNK(line, pat=re.compile(r"\s*(?:#\s*)?$").match):
-     r"""
-     Return 1 for ignorable line: iff `line` is blank or contains a single '#'.
- 
-diff --git a/Lib/poplib.py b/Lib/poplib.py
-index 516b6f060d..2437ea0e27 100644
---- a/Lib/poplib.py
-+++ b/Lib/poplib.py
-@@ -308,7 +308,7 @@ class POP3:
-         return self._shortcmd('RPOP %s' % user)
- 
- 
--    timestamp = re.compile(br'\+OK.*(<[^>]+>)')
-+    timestamp = re.compile(br'\+OK.[^<]*(<.*>)')
- 
-     def apop(self, user, password):
-         """Authorisation
-diff --git a/Lib/test/test_difflib.py b/Lib/test/test_difflib.py
-index ab9debf8e2..b6c8a7dd5b 100644
---- a/Lib/test/test_difflib.py
-+++ b/Lib/test/test_difflib.py
-@@ -466,13 +466,33 @@ class TestBytes(unittest.TestCase):
-             list(generator(*args))
-         self.assertEqual(msg, str(ctx.exception))
- 
-+class TestJunkAPIs(unittest.TestCase):
-+    def test_is_line_junk_true(self):
-+        for line in ['#', '  ', ' #', '# ', ' # ', '']:
-+            self.assertTrue(difflib.IS_LINE_JUNK(line), repr(line))
-+
-+    def test_is_line_junk_false(self):
-+        for line in ['##', ' ##', '## ', 'abc ', 'abc #', 'Mr. Moose is up!']:
-+            self.assertFalse(difflib.IS_LINE_JUNK(line), repr(line))
-+
-+    def test_is_line_junk_REDOS(self):
-+        evil_input = ('\t' * 1000000) + '##'
-+        self.assertFalse(difflib.IS_LINE_JUNK(evil_input))
-+
-+    def test_is_character_junk_true(self):
-+        for char in [' ', '\t']:
-+            self.assertTrue(difflib.IS_CHARACTER_JUNK(char), repr(char))
-+
-+    def test_is_character_junk_false(self):
-+        for char in ['a', '#', '\n', '\f', '\r', '\v']:
-+            self.assertFalse(difflib.IS_CHARACTER_JUNK(char), repr(char))
- 
- def test_main():
-     difflib.HtmlDiff._default_prefix = 0
-     Doctests = doctest.DocTestSuite(difflib)
-     run_unittest(
-         TestWithAscii, TestAutojunk, TestSFpatches, TestSFbugs,
--        TestOutputFormat, TestBytes, Doctests)
-+        TestOutputFormat, TestBytes, TestJunkAPIs, Doctests)
- 
- if __name__ == '__main__':
-     test_main()
-diff --git a/Lib/test/test_poplib.py b/Lib/test/test_poplib.py
-index bceeb93ad1..799e403652 100644
---- a/Lib/test/test_poplib.py
-+++ b/Lib/test/test_poplib.py
-@@ -300,9 +300,19 @@ class TestPOP3Class(TestCase):
-     def test_rpop(self):
-         self.assertOK(self.client.rpop('foo'))
- 
--    def test_apop(self):
-+    def test_apop_normal(self):
-         self.assertOK(self.client.apop('foo', 'dummypassword'))
- 
-+    def test_apop_REDOS(self):
-+        # Replace welcome with very long evil welcome.
-+        # NB The upper bound on welcome length is currently 2048.
-+        # At this length, evil input makes each apop call take
-+        # on the order of milliseconds instead of microseconds.
-+        evil_welcome = b'+OK' + (b'<' * 1000000)
-+        with test_support.swap_attr(self.client, 'welcome', evil_welcome):
-+            # The evil welcome is invalid, so apop should throw.
-+            self.assertRaises(poplib.error_proto, self.client.apop, 'a', 'kb')
-+
-     def test_top(self):
-         expected =  (b'+OK 116 bytes',
-                      [b'From: postmaster@python.org', b'Content-Type: text/plain',
-diff --git a/Misc/ACKS b/Misc/ACKS
-index 1a35aad66c..72c5d740bd 100644
---- a/Misc/ACKS
-+++ b/Misc/ACKS
-@@ -341,6 +341,7 @@ Kushal Das
- Jonathan Dasteel
- Pierre-Yves David
- A. Jesse Jiryu Davis
-+Jamie (James C.) Davis
- Merlijn van Deen
- John DeGood
- Ned Deily
-diff --git a/Misc/NEWS.d/next/Security/2018-03-02-10-24-52.bpo-32981.O_qDyj.rst b/Misc/NEWS.d/next/Security/2018-03-02-10-24-52.bpo-32981.O_qDyj.rst
-new file mode 100644
-index 0000000000..9ebabb44f9
---- /dev/null
-+++ b/Misc/NEWS.d/next/Security/2018-03-02-10-24-52.bpo-32981.O_qDyj.rst
-@@ -0,0 +1,4 @@
-+Regexes in difflib and poplib were vulnerable to catastrophic backtracking.
-+These regexes formed potential DOS vectors (REDOS). They have been
-+refactored. This resolves CVE-2018-1060 and CVE-2018-1061.
-+Patch by Jamie Davis.
--- 
-2.19.0
-
diff --git a/poky/meta/recipes-devtools/python/python3/Use-correct-CFLAGS-for-extensions-when-cross-compili.patch b/poky/meta/recipes-devtools/python/python3/Use-correct-CFLAGS-for-extensions-when-cross-compili.patch
new file mode 100644
index 0000000..ae74ef5
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3/Use-correct-CFLAGS-for-extensions-when-cross-compili.patch
@@ -0,0 +1,56 @@
+From 7fd121bb7d6c25c2e0a1c31cf76fb9bd4a9794de Mon Sep 17 00:00:00 2001
+From: Markus Lehtonen <markus.lehtonen@linux.intel.com>
+Date: Tue, 14 Aug 2018 14:11:35 +0800
+Subject: [PATCH 1/2] Use correct CFLAGS for extensions when cross-compiling
+
+Take PY_CFLAGS_NODIST into account, like in native build. This is needed
+in order to to profile-optimized build. Also, pass EXTRA_CFLAGS to
+profile-optimized build.
+
+Upstream-Status: Pending
+
+Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
+---
+ Makefile.pre.in | 4 ++--
+ setup.py        | 3 ++-
+ 2 files changed, 4 insertions(+), 3 deletions(-)
+
+diff --git a/Makefile.pre.in b/Makefile.pre.in
+index e2d5d3d..84bc3ff 100644
+--- a/Makefile.pre.in
++++ b/Makefile.pre.in
+@@ -478,7 +478,7 @@ profile-opt:
+ 	$(MAKE) profile-removal
+ 
+ build_all_generate_profile:
+-	$(MAKE) @DEF_MAKE_RULE@ CFLAGS_NODIST="$(CFLAGS) $(PGO_PROF_GEN_FLAG) @LTOFLAGS@" LDFLAGS="$(LDFLAGS) $(PGO_PROF_GEN_FLAG) @LTOFLAGS@" LIBS="$(LIBS)"
++	$(MAKE) @DEF_MAKE_RULE@ CFLAGS_NODIST="$(CFLAGS) $(EXTRA_CFLAGS) $(PGO_PROF_GEN_FLAG) @LTOFLAGS@" LDFLAGS="$(LDFLAGS) $(PGO_PROF_GEN_FLAG) @LTOFLAGS@" LIBS="$(LIBS)"
+ 
+ run_profile_task:
+ 	: # FIXME: can't run for a cross build
+@@ -488,7 +488,7 @@ build_all_merge_profile:
+ 	$(LLVM_PROF_MERGER)
+ 
+ build_all_use_profile:
+-	$(MAKE) @DEF_MAKE_RULE@ CFLAGS_NODIST="$(CFLAGS) $(PGO_PROF_USE_FLAG) @LTOFLAGS@" LDFLAGS="$(LDFLAGS) @LTOFLAGS@"
++	$(MAKE) @DEF_MAKE_RULE@ CFLAGS_NODIST="$(CFLAGS) $(EXTRA_CFLAGS) $(PGO_PROF_USE_FLAG) @LTOFLAGS@" LDFLAGS="$(LDFLAGS) @LTOFLAGS@"
+ 
+ # Compile and run with gcov
+ .PHONY=coverage coverage-lcov coverage-report
+diff --git a/setup.py b/setup.py
+index add3346..65e83b1 100644
+--- a/setup.py
++++ b/setup.py
+@@ -263,7 +263,8 @@ class PyBuildExt(build_ext):
+         # compilers
+         if compiler is not None:
+             if cross_compiling:
+-                (ccshared,cflags) = (os.environ.get('CCSHARED') or '', os.environ.get('CFLAGS') or '')
++                (ccshared,cflags) = (os.environ.get('CCSHARED') or '',
++                                     (os.environ.get('CFLAGS') or '') + ' ' + sysconfig.get_config_var('PY_CFLAGS_NODIST'))
+             else:
+                 (ccshared,cflags) = sysconfig.get_config_vars('CCSHARED','CFLAGS')
+             args['compiler_so'] = compiler + ' ' + ccshared + ' ' + cflags
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-devtools/python/python3/create_manifest3.py b/poky/meta/recipes-devtools/python/python3/create_manifest3.py
index 2f944f9..fddb23c 100644
--- a/poky/meta/recipes-devtools/python/python3/create_manifest3.py
+++ b/poky/meta/recipes-devtools/python/python3/create_manifest3.py
@@ -43,194 +43,239 @@
 import subprocess
 import json
 import os
+import collections
+
+# Get python version from ${PYTHON_MAJMIN}
+pyversion = str(sys.argv[1])
 
 # Hack to get native python search path (for folders), not fond of it but it works for now
-pivot='recipe-sysroot-native'
+pivot = 'recipe-sysroot-native'
 for p in sys.path:
-  if pivot in p:
-    nativelibfolder=p[:p.find(pivot)+len(pivot)]
+    if pivot in p:
+        nativelibfolder = p[:p.find(pivot)+len(pivot)]
 
 # Empty dict to hold the whole manifest
-new_manifest = {}
+new_manifest = collections.OrderedDict()
 
 # Check for repeated files, folders and wildcards
-allfiles=[]
-repeated=[]
-wildcards=[]
+allfiles = []
+repeated = []
+wildcards = []
 
-hasfolders=[]
-allfolders=[]
+hasfolders = []
+allfolders = []
 
 def isFolder(value):
-  if os.path.isdir(value.replace('${libdir}',nativelibfolder+'/usr/lib')) or os.path.isdir(value.replace('${libdir}',nativelibfolder+'/usr/lib64')) or os.path.isdir(value.replace('${libdir}',nativelibfolder+'/usr/lib32')):
-    return True
-  else:
-    return False
+    value = value.replace('${PYTHON_MAJMIN}',pyversion)
+    if os.path.isdir(value.replace('${libdir}',nativelibfolder+'/usr/lib')) or os.path.isdir(value.replace('${libdir}',nativelibfolder+'/usr/lib64')) or os.path.isdir(value.replace('${libdir}',nativelibfolder+'/usr/lib32')):
+        return True
+    else:
+        return False
 
 def isCached(item):
-  if '__pycache__' in item:
-    return True
-  else:
-    return False
+    if '__pycache__' in item:
+        return True
+    else:
+        return False
 
 # Read existing JSON manifest
 with open('python3-manifest.json') as manifest:
-  old_manifest=json.load(manifest)
+    old_manifest = json.load(manifest, object_pairs_hook=collections.OrderedDict)
 
-
+#
 # First pass to get core-package functionality, because we base everything on the fact that core is actually working
 # Not exactly the same so it should not be a function
+#
+
 print ('Getting dependencies for package: core')
 
-# Special call to check for core package
+
+# This special call gets the core dependencies and
+# appends to the old manifest so it doesnt hurt what it
+# currently holds.
+# This way when other packages check for dependencies
+# on the new core package, they will still find them
+# even when checking the old_manifest
+
 output = subprocess.check_output([sys.executable, 'get_module_deps3.py', 'python-core-package']).decode('utf8')
-for item in output.split():
-    # We append it so it doesnt hurt what we currently have:
-    if isCached(item):
-        if item not in old_manifest['core']['cached']:
-            # We use the same data structure since its the one which will be used to check
-            # dependencies for other packages
-            old_manifest['core']['cached'].append(item)
+for coredep in output.split():
+    coredep = coredep.replace(pyversion,'${PYTHON_MAJMIN}')
+    if isCached(coredep):
+        if coredep not in old_manifest['core']['cached']:
+            old_manifest['core']['cached'].append(coredep)
     else:
-        if item not in old_manifest['core']['files']:
-            # We use the same data structure since its the one which will be used to check
-            # dependencies for other packages
-            old_manifest['core']['files'].append(item)
-
-for value in old_manifest['core']['files']:
-  # Ignore folders, since we don't import those, difficult to handle multilib
-  if isFolder(value):
-    # Pass it directly
-    if isCached(value):
-        if value not in old_manifest['core']['cached']:
-            old_manifest['core']['cached'].append(value)
-    else:
-        if value not in old_manifest['core']['files']:
-            old_manifest['core']['files'].append(value)
-    continue
-  # Ignore binaries, since we don't import those, assume it was added correctly (manually)
-  if '${bindir}' in value:
-    # Pass it directly
-    if value not in old_manifest['core']['files']:
-      old_manifest['core']['files'].append(value)
-    continue
-  # Ignore empty values
-  if value == '':
-    continue
-  if '${includedir}' in value:
-    if value not in old_manifest['core']['files']:
-      old_manifest['core']['files'].append(value)
-    continue
-  # Get module name , shouldnt be affected by libdir/bindir
-  value = os.path.splitext(os.path.basename(os.path.normpath(value)))[0]
-
-  # Launch separate task for each module for deterministic behavior
-  # Each module will only import what is necessary for it to work in specific
-  print ('Getting dependencies for module: %s' % value)
-  output = subprocess.check_output([sys.executable, 'get_module_deps3.py', '%s' % value]).decode('utf8')
-  print ('The following dependencies were found for module %s:\n' % value)
-  print (output)
-  for item in output.split():
-    # We append it so it doesnt hurt what we currently have:
-    if isCached(item):
-        if item not in old_manifest['core']['cached']:
-            # We use the same data structure since its the one which will be used to check
-            # dependencies for other packages
-            old_manifest['core']['cached'].append(item)
-    else:
-        if item not in old_manifest['core']['files']:
-            # We use the same data structure since its the one which will be used to check
-            # dependencies for other packages
-            old_manifest['core']['files'].append(item)
+        if coredep not in old_manifest['core']['files']:
+            old_manifest['core']['files'].append(coredep)
 
 
-# We check which packages include folders
-for key in old_manifest:
-    for value in old_manifest[key]['files']:
-        # Ignore folders, since we don't import those, difficult to handle multilib
-        if isFolder(value):
-            print ('%s is a folder' % value)
-            if key not in hasfolders:
-                hasfolders.append(key)
-            if value not in allfolders:
-                allfolders.append(value)
+# The second step is to loop through the existing files contained in the core package
+# according to the old manifest, identify if they are  modules, or some other type 
+# of file that we cant import (directories, binaries, configs) in which case we
+# can only assume they were added correctly (manually) so we ignore those and 
+# pass them to the manifest directly.
 
-for key in old_manifest:
+for filedep in old_manifest['core']['files']:
+    if isFolder(filedep):
+        if isCached(filedep):
+            if filedep not in old_manifest['core']['cached']:
+                old_manifest['core']['cached'].append(filedep)
+        else:
+            if filedep not in old_manifest['core']['files']:
+                old_manifest['core']['files'].append(filedep)
+        continue
+    if '${bindir}' in filedep:
+        if filedep not in old_manifest['core']['files']:
+            old_manifest['core']['files'].append(filedep)
+        continue
+    if filedep == '':
+        continue
+    if '${includedir}' in filedep:
+        if filedep not in old_manifest['core']['files']:
+            old_manifest['core']['files'].append(filedep)
+        continue
+
+    # Get actual module name , shouldnt be affected by libdir/bindir, etc.
+    pymodule = os.path.splitext(os.path.basename(os.path.normpath(filedep)))[0]
+
+
+    # We now know that were dealing with a python module, so we can import it
+    # and check what its dependencies are.
+    # We launch a separate task for each module for deterministic behavior.
+    # Each module will only import what is necessary for it to work in specific.
+    # The output of each task will contain each module's dependencies
+
+    print ('Getting dependencies for module: %s' % pymodule)
+    output = subprocess.check_output([sys.executable, 'get_module_deps3.py', '%s' % pymodule]).decode('utf8')
+    print ('The following dependencies were found for module %s:\n' % pymodule)
+    print (output)
+
+
+    for pymodule_dep in output.split():
+        pymodule_dep = pymodule_dep.replace(pyversion,'${PYTHON_MAJMIN}')
+
+        if isCached(pymodule_dep):
+            if pymodule_dep not in old_manifest['core']['cached']:
+                old_manifest['core']['cached'].append(pymodule_dep)
+        else:
+            if pymodule_dep not in old_manifest['core']['files']:
+                old_manifest['core']['files'].append(pymodule_dep)
+
+
+# At this point we are done with the core package.
+# The old_manifest dictionary is updated only for the core package because
+# all others will use this a base.
+
+
+# To improve the script speed, we check which packages contain directories
+# since we will be looping through (only) those later.
+for pypkg in old_manifest:
+    for filedep in old_manifest[pypkg]['files']:
+        if isFolder(filedep):
+            print ('%s is a folder' % filedep)
+            if pypkg not in hasfolders:
+                hasfolders.append(pypkg)
+            if filedep not in allfolders:
+                allfolders.append(filedep)
+
+
+
+# This is the main loop that will handle each package.
+# It works in a similar fashion than the step before, but
+# we will now be updating a new dictionary that will eventually
+# become the new manifest.
+#
+# The following loops though all packages in the manifest,
+# through all files on each of them, and checks whether or not
+# they are modules and can be imported.
+# If they can be imported, then it checks for dependencies for
+# each of them by launching a separate task.
+# The output of that task is then parsed and the manifest is updated
+# accordingly, wether it should add the module on FILES for the current package
+# or if that module already belongs to another package then the current one 
+# will RDEPEND on it
+
+for pypkg in old_manifest:
     # Use an empty dict as data structure to hold data for each package and fill it up
-    new_manifest[key]={}
-    new_manifest[key]['files']=[]
-    
-    new_manifest[key]['rdepends']=[]
+    new_manifest[pypkg] = collections.OrderedDict()
+    new_manifest[pypkg]['summary'] = old_manifest[pypkg]['summary']
+    new_manifest[pypkg]['rdepends'] = []
+    new_manifest[pypkg]['files'] = []
+    new_manifest[pypkg]['cached'] = old_manifest[pypkg]['cached']
+
     # All packages should depend on core
-    if key != 'core':
-         new_manifest[key]['rdepends'].append('core')
-         new_manifest[key]['cached']=[]
-    else:
-         new_manifest[key]['cached']=old_manifest[key]['cached']
-    new_manifest[key]['summary']=old_manifest[key]['summary']
+    if pypkg != 'core':
+        new_manifest[pypkg]['rdepends'].append('core')
+        new_manifest[pypkg]['cached'] = []
+
+    print('\n')
+    print('--------------------------')
+    print ('Handling package %s' % pypkg)
+    print('--------------------------')
 
     # Handle special cases, we assume that when they were manually added 
     # to the manifest we knew what we were doing.
-    print('\n')
-    print('--------------------------')
-    print ('Handling package %s' % key)
-    print('--------------------------')
-    special_packages=['misc', 'modules', 'dev']
-    if key in special_packages or 'staticdev' in key:
-        print('Passing %s package directly' % key)
-        new_manifest[key]=old_manifest[key]
+    special_packages = ['misc', 'modules', 'dev', 'tests']
+    if pypkg in special_packages or 'staticdev' in pypkg:
+        print('Passing %s package directly' % pypkg)
+        new_manifest[pypkg] = old_manifest[pypkg]
         continue
 
-    for value in old_manifest[key]['files']:
-        # We already handled core on the first pass
-        if key == 'core':
-            new_manifest[key]['files'].append(value)
-            continue
-        # Ignore folders, since we don't import those, difficult to handle multilib
-        if isFolder(value):
-            # Pass folders directly
-            new_manifest[key]['files'].append(value)
-        # Ignore binaries, since we don't import those
-        if '${bindir}' in value:
-            # Pass it directly to the new manifest data structure
-            if value not in new_manifest[key]['files']:
-                new_manifest[key]['files'].append(value)
-            continue
-        # Ignore empty values
-        if value == '':
-            continue
-        if '${includedir}' in value:
-            if value not in new_manifest[key]['files']:
-                new_manifest[key]['files'].append(value)
+    for filedep in old_manifest[pypkg]['files']:
+        # We already handled core on the first pass, we can ignore it now
+        if pypkg == 'core':
+            if filedep not in new_manifest[pypkg]['files']:
+                new_manifest[pypkg]['files'].append(filedep)
             continue
 
-        # Get module name , shouldnt be affected by libdir/bindir
+        # Handle/ignore what we cant import
+        if isFolder(filedep):
+            new_manifest[pypkg]['files'].append(filedep)
+            # Asyncio (and others) are both the package and the folder name, we should not skip those...
+            path,mod = os.path.split(filedep)
+            if mod != pypkg:
+                continue
+        if '${bindir}' in filedep:
+            if filedep not in new_manifest[pypkg]['files']:
+                new_manifest[pypkg]['files'].append(filedep)
+            continue
+        if filedep == '':
+            continue
+        if '${includedir}' in filedep:
+            if filedep not in new_manifest[pypkg]['files']:
+                new_manifest[pypkg]['files'].append(filedep)
+            continue
+
+        # Get actual module name , shouldnt be affected by libdir/bindir, etc.
         # We need to check if the imported module comes from another (e.g. sqlite3.dump)
-        path,value = os.path.split(value)
+        path,pymodule = os.path.split(filedep)
         path = os.path.basename(path)
-        value = os.path.splitext(os.path.basename(value))[0]
+        pymodule = os.path.splitext(os.path.basename(pymodule))[0]
 
         # If this condition is met, it means we need to import it from another module
         # or its the folder itself (e.g. unittest)
-        if path == key:
-          if value:
-            value = path + '.' + value
-          else:
-            value = path
+        if path == pypkg:
+            if pymodule:
+                pymodule = path + '.' + pymodule
+            else:
+                pymodule = path
 
-        # Launch separate task for each module for deterministic behavior
-        # Each module will only import what is necessary for it to work in specific
-        print ('\nGetting dependencies for module: %s' % value)
-        output = subprocess.check_output([sys.executable, 'get_module_deps3.py', '%s' % value]).decode('utf8')
-        # We can print dependencies for debugging purposes
-        print ('The following dependencies were found for module %s:\n' % value)
+
+
+        # We now know that were dealing with a python module, so we can import it
+        # and check what its dependencies are.
+        # We launch a separate task for each module for deterministic behavior.
+        # Each module will only import what is necessary for it to work in specific.
+        # The output of each task will contain each module's dependencies
+
+        print ('\nGetting dependencies for module: %s' % pymodule)
+        output = subprocess.check_output([sys.executable, 'get_module_deps3.py', '%s' % pymodule]).decode('utf8')
+        print ('The following dependencies were found for module %s:\n' % pymodule)
         print (output)
-        # Output will have all dependencies
 
         reportFILES = []
         reportRDEPS = []
 
-        for item in output.split():
+        for pymodule_dep in output.split():
 
             # Warning: This first part is ugly
             # One of the dependencies that was found, could be inside of one of the folders included by another package
@@ -250,22 +295,22 @@
             #   is folder_string inside path/folder1/folder2/filename?, 
             #   Yes, it works, but we waste a couple of milliseconds.
 
-            inFolders=False
+            pymodule_dep = pymodule_dep.replace(pyversion,'${PYTHON_MAJMIN}')
+            inFolders = False
             for folder in allfolders:
-                if folder in item:
+                if folder in pymodule_dep:
                     inFolders = True # Did we find a folder?
                     folderFound = False # Second flag to break inner for
                     # Loop only through packages which contain folders
-                    for keyfolder in hasfolders:
+                    for pypkg_with_folder in hasfolders:
                         if (folderFound == False):
-                            #print('Checking folder %s on package %s' % (item,keyfolder))
-                            for file_folder in old_manifest[keyfolder]['files'] or file_folder in old_manifest[keyfolder]['cached']:
-                                if file_folder==folder:
-                                    print ('%s folder found in %s' % (folder, keyfolder))
+                            # print('Checking folder %s on package %s' % (pymodule_dep,pypkg_with_folder))
+                            for folder_dep in old_manifest[pypkg_with_folder]['files'] or folder_dep in old_manifest[pypkg_with_folder]['cached']:
+                                if folder_dep == folder:
+                                    print ('%s folder found in %s' % (folder, pypkg_with_folder))
                                     folderFound = True
-                                    if keyfolder not in new_manifest[key]['rdepends'] and keyfolder != key:
-                                        new_manifest[key]['rdepends'].append(keyfolder)
-                                    
+                                    if pypkg_with_folder not in new_manifest[pypkg]['rdepends'] and pypkg_with_folder != pypkg:
+                                        new_manifest[pypkg]['rdepends'].append(pypkg_with_folder)
                         else:
                             break
 
@@ -274,81 +319,95 @@
                 continue
 
 
-            # We might already have it on the dictionary since it could depend on a (previously checked) module
-            if item not in new_manifest[key]['files'] and item not in new_manifest[key]['cached']:
+
+            # No directories beyond this point
+            # We might already have this module on the dictionary since it could depend on a (previously checked) module
+            if pymodule_dep not in new_manifest[pypkg]['files'] and pymodule_dep not in new_manifest[pypkg]['cached']:
                 # Handle core as a special package, we already did it so we pass it to NEW data structure directly
-                if key=='core':
-                  print('Adding %s to %s FILES' % (item, key))
-                  if item.endswith('*'):
-                      wildcards.append(item)
-                  if isCached(item):
-                      new_manifest[key]['cached'].append(item)
-                  else:
-                      new_manifest[key]['files'].append(item)
+                if pypkg == 'core':
+                    print('Adding %s to %s FILES' % (pymodule_dep, pypkg))
+                    if pymodule_dep.endswith('*'):
+                        wildcards.append(pymodule_dep)
+                    if isCached(pymodule_dep):
+                        new_manifest[pypkg]['cached'].append(pymodule_dep)
+                    else:
+                        new_manifest[pypkg]['files'].append(pymodule_dep)
 
-                  # Check for repeated files
-                  if item not in allfiles:
-                      allfiles.append(item)
-                  else:
-                      repeated.append(item)
-
+                    # Check for repeated files
+                    if pymodule_dep not in allfiles:
+                        allfiles.append(pymodule_dep)
+                    else:
+                        if pymodule_dep not in repeated:
+                            repeated.append(pymodule_dep)
                 else:
 
 
-                    # Check if this dependency is already contained on another package, so we add it
+                    # Last step: Figure out if we this belongs to FILES or RDEPENDS
+                    # We check if this module is already contained on another package, so we add that one
                     # as an RDEPENDS, or if its not, it means it should be contained on the current
-                    # package, so we should add it to FILES
-                    for newkey in old_manifest:
+                    # package, and we should add it to FILES
+                    for possible_rdep in old_manifest:
                         # Debug
-                        #print('Checking %s ' % item + ' in %s' % newkey)
-                        if item in old_manifest[newkey]['files'] or item in old_manifest[newkey]['cached']:      
-                                # Since were nesting, we need to check its not the same key
-                                if(newkey!=key):
-                                    if newkey not in new_manifest[key]['rdepends']:
-                                       # Add it to the new manifest data struct
-                                       reportRDEPS.append('Adding %s to %s RDEPENDS, because it contains %s\n' % (newkey, key, item))
-                                       new_manifest[key]['rdepends'].append(newkey)
-                                    break
+                        # print('Checking %s ' % pymodule_dep + ' in %s' % possible_rdep)
+                        if pymodule_dep in old_manifest[possible_rdep]['files'] or pymodule_dep in old_manifest[possible_rdep]['cached']:
+                            # Since were nesting, we need to check its not the same pypkg
+                            if(possible_rdep != pypkg):
+                                if possible_rdep not in new_manifest[pypkg]['rdepends']:
+                                    # Add it to the new manifest data struct as RDEPENDS since it contains something this module needs
+                                    reportRDEPS.append('Adding %s to %s RDEPENDS, because it contains %s\n' % (possible_rdep, pypkg, pymodule_dep))
+                                    new_manifest[pypkg]['rdepends'].append(possible_rdep)
+                                break
                     else:
-                      # A module shouldn't contain itself (${libdir}/python3/sqlite3 shouldnt be on sqlite3 files)
-                      if os.path.basename(item) != key:
-                        reportFILES.append(('Adding %s to %s FILES\n' % (item, key)))
-                        # Since it wasnt found on another package, its not an RDEP, so add it to FILES for this package
-                        if isCached(item):
-                            new_manifest[key]['cached'].append(item)
-                        else:
-                            new_manifest[key]['files'].append(item)
 
-                        if item.endswith('*'):
-                            wildcards.append(item)
-                        if item not in allfiles:
-                            allfiles.append(item)
+                      # Since this module wasnt found on another package, it is not an RDEP,
+                      # so we add it to FILES for this package.
+                      # A module shouldn't contain itself (${libdir}/python3/sqlite3 shouldnt be on sqlite3 files)
+                      if os.path.basename(pymodule_dep) != pypkg:
+                        reportFILES.append(('Adding %s to %s FILES\n' % (pymodule_dep, pypkg)))
+                        if isCached(pymodule_dep):
+                            new_manifest[pypkg]['cached'].append(pymodule_dep)
                         else:
-                            repeated.append(item)
+                            new_manifest[pypkg]['files'].append(pymodule_dep)
+                        if pymodule_dep.endswith('*'):
+                            wildcards.append(pymodule_dep)
+                        if pymodule_dep not in allfiles:
+                            allfiles.append(pymodule_dep)
+                        else:
+                            if pymodule_dep not in repeated:
+                                repeated.append(pymodule_dep)
 
         print('\n')
         print('#################################')
-        print('Summary for module %s' % value)
-        print('FILES found for module %s:' % value)
+        print('Summary for module %s' % pymodule)
+        print('FILES found for module %s:' % pymodule)
         print(''.join(reportFILES))
-        print('RDEPENDS found for module %s:' % value)
+        print('RDEPENDS found for module %s:' % pymodule)
         print(''.join(reportRDEPS))
         print('#################################')
 
-print ('The following files are repeated (contained in more than one package), please check which package should get it:')
-print (repeated)
-print('The following files contain wildcards, please check they are necessary')
+print('The following FILES contain wildcards, please check if they are necessary')
 print(wildcards)
-print('The following files contain folders, please check they are necessary')
+print('The following FILES contain folders, please check if they are necessary')
 print(hasfolders)
 
+
 # Sort it just so it looks nicer
-for key in new_manifest:
-    new_manifest[key]['files'].sort()
-    new_manifest[key]['cached'].sort()
-    new_manifest[key]['rdepends'].sort()
+for pypkg in new_manifest:
+    new_manifest[pypkg]['files'].sort()
+    new_manifest[pypkg]['cached'].sort()
+    new_manifest[pypkg]['rdepends'].sort()
 
 # Create the manifest from the data structure that was built
 with open('python3-manifest.json.new','w') as outfile:
-    json.dump(new_manifest,outfile,sort_keys=True, indent=4)
+    json.dump(new_manifest,outfile, indent=4)
     outfile.write('\n')
+
+if (repeated):
+    error_msg = '\n\nERROR:\n'
+    error_msg += 'The following files are repeated (contained in more than one package),\n'
+    error_msg += 'this is likely to happen when new files are introduced after an upgrade,\n'
+    error_msg += 'please check which package should get it,\n modify the manifest accordingly and re-run the create_manifest task:\n'
+    error_msg += '\n'.join(repeated)
+    error_msg += '\n'
+    sys.exit(error_msg)
+
diff --git a/poky/meta/recipes-devtools/python/python3/float-endian.patch b/poky/meta/recipes-devtools/python/python3/float-endian.patch
new file mode 100644
index 0000000..6ba3f5c
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3/float-endian.patch
@@ -0,0 +1,212 @@
+Python uses AC_RUN_IFELSE to determine the byte order for floats and doubles,
+and falls back onto "I don't know" if it can't run code.  This results in
+crippled floating point numbers in Python, and the regression tests fail.
+
+Instead of running code, take a macro from autoconf-archive which compiles C
+with a special double in which has an ASCII representation, and then greps the
+binary to identify the format.
+
+Upstream-Status: Submitted [https://bugs.python.org/issue34585]
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+From 50df2a4c3a65ed06322be7c26d42b06ce81730c1 Mon Sep 17 00:00:00 2001
+From: Ross Burton <ross.burton@intel.com>
+Date: Wed, 5 Sep 2018 11:45:52 +0100
+Subject: [PATCH] Don't do runtime test to get float byte order
+
+---
+ configure.ac                     | 74 +++++------------------------------
+ m4/ax_c_float_words_bigendian.m4 | 83 ++++++++++++++++++++++++++++++++++++++++
+ 2 files changed, 92 insertions(+), 65 deletions(-)
+ create mode 100644 m4/ax_c_float_words_bigendian.m4
+
+diff --git a/configure.ac b/configure.ac
+index c9b755f0f4..1215969871 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -9,6 +9,8 @@ AC_PREREQ(2.65)
+ 
+ AC_INIT(python, PYTHON_VERSION, https://bugs.python.org/)
+ 
++AC_CONFIG_MACRO_DIR(m4)
++
+ AC_SUBST(BASECPPFLAGS)
+ if test "$srcdir" != . -a "$srcdir" != "$(pwd)"; then
+     # If we're building out-of-tree, we need to make sure the following
+@@ -4128,77 +4130,19 @@ fi
+ # * Check for various properties of floating point *
+ # **************************************************
+ 
+-AC_MSG_CHECKING(whether C doubles are little-endian IEEE 754 binary64)
+-AC_CACHE_VAL(ac_cv_little_endian_double, [
+-AC_RUN_IFELSE([AC_LANG_SOURCE([[
+-#include <string.h>
+-int main() {
+-    double x = 9006104071832581.0;
+-    if (memcmp(&x, "\x05\x04\x03\x02\x01\xff\x3f\x43", 8) == 0)
+-        return 0;
+-    else
+-        return 1;
+-}
+-]])],
+-[ac_cv_little_endian_double=yes],
+-[ac_cv_little_endian_double=no],
+-[ac_cv_little_endian_double=no])])
+-AC_MSG_RESULT($ac_cv_little_endian_double)
+-if test "$ac_cv_little_endian_double" = yes
+-then
+-  AC_DEFINE(DOUBLE_IS_LITTLE_ENDIAN_IEEE754, 1,
+-  [Define if C doubles are 64-bit IEEE 754 binary format, stored
+-   with the least significant byte first])
+-fi
+-
+-AC_MSG_CHECKING(whether C doubles are big-endian IEEE 754 binary64)
+-AC_CACHE_VAL(ac_cv_big_endian_double, [
+-AC_RUN_IFELSE([AC_LANG_SOURCE([[
+-#include <string.h>
+-int main() {
+-    double x = 9006104071832581.0;
+-    if (memcmp(&x, "\x43\x3f\xff\x01\x02\x03\x04\x05", 8) == 0)
+-        return 0;
+-    else
+-        return 1;
+-}
+-]])],
+-[ac_cv_big_endian_double=yes],
+-[ac_cv_big_endian_double=no],
+-[ac_cv_big_endian_double=no])])
+-AC_MSG_RESULT($ac_cv_big_endian_double)
+-if test "$ac_cv_big_endian_double" = yes
++AX_C_FLOAT_WORDS_BIGENDIAN
++if test "$ax_cv_c_float_words_bigendian" = "yes"
+ then
+   AC_DEFINE(DOUBLE_IS_BIG_ENDIAN_IEEE754, 1,
+   [Define if C doubles are 64-bit IEEE 754 binary format, stored
+    with the most significant byte first])
+-fi
+-
+-# Some ARM platforms use a mixed-endian representation for doubles.
+-# While Python doesn't currently have full support for these platforms
+-# (see e.g., issue 1762561), we can at least make sure that float <-> string
+-# conversions work.
+-AC_MSG_CHECKING(whether C doubles are ARM mixed-endian IEEE 754 binary64)
+-AC_CACHE_VAL(ac_cv_mixed_endian_double, [
+-AC_RUN_IFELSE([AC_LANG_SOURCE([[
+-#include <string.h>
+-int main() {
+-    double x = 9006104071832581.0;
+-    if (memcmp(&x, "\x01\xff\x3f\x43\x05\x04\x03\x02", 8) == 0)
+-        return 0;
+-    else
+-        return 1;
+-}
+-]])],
+-[ac_cv_mixed_endian_double=yes],
+-[ac_cv_mixed_endian_double=no],
+-[ac_cv_mixed_endian_double=no])])
+-AC_MSG_RESULT($ac_cv_mixed_endian_double)
+-if test "$ac_cv_mixed_endian_double" = yes
++elif test "$ax_cv_c_float_words_bigendian" = "no"
+ then
+-  AC_DEFINE(DOUBLE_IS_ARM_MIXED_ENDIAN_IEEE754, 1,
++  AC_DEFINE(DOUBLE_IS_LITTLE_ENDIAN_IEEE754, 1,
+   [Define if C doubles are 64-bit IEEE 754 binary format, stored
+-   in ARM mixed-endian order (byte order 45670123)])
++   with the least significant byte first])
++else
++  AC_MSG_ERROR([Cannot identify floating point byte order])
+ fi
+ 
+ # The short float repr introduced in Python 3.1 requires the
+diff --git a/m4/ax_c_float_words_bigendian.m4 b/m4/ax_c_float_words_bigendian.m4
+new file mode 100644
+index 0000000000..216b90d803
+--- /dev/null
++++ b/m4/ax_c_float_words_bigendian.m4
+@@ -0,0 +1,83 @@
++# ===============================================================================
++#  https://www.gnu.org/software/autoconf-archive/ax_c_float_words_bigendian.html
++# ===============================================================================
++#
++# SYNOPSIS
++#
++#   AX_C_FLOAT_WORDS_BIGENDIAN([ACTION-IF-TRUE], [ACTION-IF-FALSE], [ACTION-IF-UNKNOWN])
++#
++# DESCRIPTION
++#
++#   Checks the ordering of words within a multi-word float. This check is
++#   necessary because on some systems (e.g. certain ARM systems), the float
++#   word ordering can be different from the byte ordering. In a multi-word
++#   float context, "big-endian" implies that the word containing the sign
++#   bit is found in the memory location with the lowest address. This
++#   implementation was inspired by the AC_C_BIGENDIAN macro in autoconf.
++#
++#   The endianness is detected by first compiling C code that contains a
++#   special double float value, then grepping the resulting object file for
++#   certain strings of ASCII values. The double is specially crafted to have
++#   a binary representation that corresponds with a simple string. In this
++#   implementation, the string "noonsees" was selected because the
++#   individual word values ("noon" and "sees") are palindromes, thus making
++#   this test byte-order agnostic. If grep finds the string "noonsees" in
++#   the object file, the target platform stores float words in big-endian
++#   order. If grep finds "seesnoon", float words are in little-endian order.
++#   If neither value is found, the user is instructed to specify the
++#   ordering.
++#
++# LICENSE
++#
++#   Copyright (c) 2008 Daniel Amelang <dan@amelang.net>
++#
++#   Copying and distribution of this file, with or without modification, are
++#   permitted in any medium without royalty provided the copyright notice
++#   and this notice are preserved. This file is offered as-is, without any
++#   warranty.
++
++#serial 11
++
++AC_DEFUN([AX_C_FLOAT_WORDS_BIGENDIAN],
++  [AC_CACHE_CHECK(whether float word ordering is bigendian,
++                  ax_cv_c_float_words_bigendian, [
++
++ax_cv_c_float_words_bigendian=unknown
++AC_COMPILE_IFELSE([AC_LANG_SOURCE([[
++
++double d = 90904234967036810337470478905505011476211692735615632014797120844053488865816695273723469097858056257517020191247487429516932130503560650002327564517570778480236724525140520121371739201496540132640109977779420565776568942592.0;
++
++]])], [
++
++if grep noonsees conftest.$ac_objext >/dev/null ; then
++  ax_cv_c_float_words_bigendian=yes
++fi
++if grep seesnoon conftest.$ac_objext >/dev/null ; then
++  if test "$ax_cv_c_float_words_bigendian" = unknown; then
++    ax_cv_c_float_words_bigendian=no
++  else
++    ax_cv_c_float_words_bigendian=unknown
++  fi
++fi
++
++])])
++
++case $ax_cv_c_float_words_bigendian in
++  yes)
++    m4_default([$1],
++      [AC_DEFINE([FLOAT_WORDS_BIGENDIAN], 1,
++                 [Define to 1 if your system stores words within floats
++                  with the most significant word first])]) ;;
++  no)
++    $2 ;;
++  *)
++    m4_default([$3],
++      [AC_MSG_ERROR([
++
++Unknown float word ordering. You need to manually preset
++ax_cv_c_float_words_bigendian=no (or yes) according to your system.
++
++    ])]) ;;
++esac
++
++])# AX_C_FLOAT_WORDS_BIGENDIAN
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-devtools/python/python3/ftplib.patch b/poky/meta/recipes-devtools/python/python3/ftplib.patch
new file mode 100644
index 0000000..49c5b27
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3/ftplib.patch
@@ -0,0 +1,60 @@
+Upstream-Status: Backport
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+From cabe916dc694997d4892b58986e73a713d5a2f8d Mon Sep 17 00:00:00 2001
+From: "Miss Islington (bot)"
+ <31488909+miss-islington@users.noreply.github.com>
+Date: Thu, 16 Aug 2018 15:38:03 -0400
+Subject: [PATCH] [3.6] bpo-34391: Fix ftplib test for TLS 1.3 (GH-8787)
+ (#8790)
+
+Read from data socket to avoid "[SSL] shutdown while in init" exception
+during shutdown of the dummy server.
+
+Signed-off-by: Christian Heimes <christian@python.org>
+
+
+<!-- issue-number: [bpo-34391](https://www.bugs.python.org/issue34391) -->
+https://bugs.python.org/issue34391
+<!-- /issue-number -->
+(cherry picked from commit 1590c393360df059160145e7475754427bfc6680)
+
+
+Co-authored-by: Christian Heimes <christian@python.org>
+---
+ Lib/test/test_ftplib.py                                         | 5 +++++
+ Misc/NEWS.d/next/Tests/2018-08-16-18-48-47.bpo-34391.ouNfxC.rst | 1 +
+ 2 files changed, 6 insertions(+)
+ create mode 100644 Misc/NEWS.d/next/Tests/2018-08-16-18-48-47.bpo-34391.ouNfxC.rst
+
+diff --git a/Lib/test/test_ftplib.py b/Lib/test/test_ftplib.py
+index 44dd73aeca..4ff2f71afb 100644
+--- a/Lib/test/test_ftplib.py
++++ b/Lib/test/test_ftplib.py
+@@ -876,18 +876,23 @@ class TestTLS_FTPClass(TestCase):
+         # clear text
+         with self.client.transfercmd('list') as sock:
+             self.assertNotIsInstance(sock, ssl.SSLSocket)
++            self.assertEqual(sock.recv(1024), LIST_DATA.encode('ascii'))
+         self.assertEqual(self.client.voidresp(), "226 transfer complete")
+ 
+         # secured, after PROT P
+         self.client.prot_p()
+         with self.client.transfercmd('list') as sock:
+             self.assertIsInstance(sock, ssl.SSLSocket)
++            # consume from SSL socket to finalize handshake and avoid
++            # "SSLError [SSL] shutdown while in init"
++            self.assertEqual(sock.recv(1024), LIST_DATA.encode('ascii'))
+         self.assertEqual(self.client.voidresp(), "226 transfer complete")
+ 
+         # PROT C is issued, the connection must be in cleartext again
+         self.client.prot_c()
+         with self.client.transfercmd('list') as sock:
+             self.assertNotIsInstance(sock, ssl.SSLSocket)
++            self.assertEqual(sock.recv(1024), LIST_DATA.encode('ascii'))
+         self.assertEqual(self.client.voidresp(), "226 transfer complete")
+ 
+     def test_login(self):
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-devtools/python/python3/python3-manifest.json b/poky/meta/recipes-devtools/python/python3/python3-manifest.json
index 2491f36..5329bf7 100644
--- a/poky/meta/recipes-devtools/python/python3/python3-manifest.json
+++ b/poky/meta/recipes-devtools/python/python3/python3-manifest.json
@@ -1,22 +1,31 @@
 {
-    "2to3": {
-        "cached": [],
-        "files": [
-            "${bindir}/2to3-*",
-            "${libdir}/python3.5/lib2to3"
+    "tests": {
+        "summary": "Python test suite",
+        "rdepends": [
+            "core",
+            "modules"
         ],
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/*/test",
+            "${libdir}/python${PYTHON_MAJMIN}/*/tests",
+            "${libdir}/python${PYTHON_MAJMIN}/idlelib/idle_test/",
+            "${libdir}/python${PYTHON_MAJMIN}/test"
+        ],
+        "cached": []
+    },
+    "2to3": {
+        "summary": "Python automated Python 2 to 3 code translator",
         "rdepends": [
             "core"
         ],
-        "summary": "Python automated Python 2 to 3 code translator"
+        "files": [
+            "${bindir}/2to3-*",
+            "${libdir}/python${PYTHON_MAJMIN}/lib2to3"
+        ],
+        "cached": []
     },
     "asyncio": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/asyncio",
-            "${libdir}/python3.5/concurrent",
-            "${libdir}/python3.5/concurrent/futures"
-        ],
+        "summary": "Python Asynchronous I/",
         "rdepends": [
             "compression",
             "core",
@@ -32,50 +41,48 @@
             "threading",
             "unixadmin"
         ],
-        "summary": "Python Asynchronous I/"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/asyncio",
+            "${libdir}/python${PYTHON_MAJMIN}/concurrent",
+            "${libdir}/python${PYTHON_MAJMIN}/concurrent/futures"
+        ],
+        "cached": []
     },
     "audio": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/chunk.*.pyc",
-            "${libdir}/python3.5/__pycache__/sndhdr.*.pyc",
-            "${libdir}/python3.5/__pycache__/sunau.*.pyc",
-            "${libdir}/python3.5/__pycache__/wave.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/chunk.py",
-            "${libdir}/python3.5/lib-dynload/audioop.*.so",
-            "${libdir}/python3.5/lib-dynload/ossaudiodev.*.so",
-            "${libdir}/python3.5/sndhdr.py",
-            "${libdir}/python3.5/sunau.py",
-            "${libdir}/python3.5/wave.py"
-        ],
+        "summary": "Python Audio Handling",
         "rdepends": [
             "core"
         ],
-        "summary": "Python Audio Handling"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/chunk.py",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/audioop.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/ossaudiodev.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/sndhdr.py",
+            "${libdir}/python${PYTHON_MAJMIN}/sunau.py",
+            "${libdir}/python${PYTHON_MAJMIN}/wave.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/chunk.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/sndhdr.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/sunau.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/wave.*.pyc"
+        ]
     },
     "codecs": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/xdrlib.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/lib-dynload/_multibytecodec.*.so",
-            "${libdir}/python3.5/xdrlib.py"
-        ],
+        "summary": "Python codec",
         "rdepends": [
             "core"
         ],
-        "summary": "Python codec"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_multibytecodec.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/xdrlib.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/xdrlib.*.pyc"
+        ]
     },
     "compile": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/compileall.*.pyc",
-            "${libdir}/python3.5/__pycache__/py_compile.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/compileall.py",
-            "${libdir}/python3.5/py_compile.py"
-        ],
+        "summary": "Python bytecode compilation support",
         "rdepends": [
             "asyncio",
             "compression",
@@ -91,305 +98,309 @@
             "threading",
             "unixadmin"
         ],
-        "summary": "Python bytecode compilation support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/compileall.py",
+            "${libdir}/python${PYTHON_MAJMIN}/py_compile.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/compileall.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/py_compile.*.pyc"
+        ]
     },
     "compression": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/_compression.*.pyc",
-            "${libdir}/python3.5/__pycache__/bz2.*.pyc",
-            "${libdir}/python3.5/__pycache__/gzip.*.pyc",
-            "${libdir}/python3.5/__pycache__/lzma.*.pyc",
-            "${libdir}/python3.5/__pycache__/tarfile.*.pyc",
-            "${libdir}/python3.5/__pycache__/zipfile.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/_compression.py",
-            "${libdir}/python3.5/bz2.py",
-            "${libdir}/python3.5/gzip.py",
-            "${libdir}/python3.5/lib-dynload/_bz2.*.so",
-            "${libdir}/python3.5/lib-dynload/_lzma.*.so",
-            "${libdir}/python3.5/lib-dynload/zlib.*.so",
-            "${libdir}/python3.5/lzma.py",
-            "${libdir}/python3.5/tarfile.py",
-            "${libdir}/python3.5/zipfile.py"
-        ],
+        "summary": "Python high-level compression support",
         "rdepends": [
             "core",
             "shell",
             "unixadmin"
         ],
-        "summary": "Python high-level compression support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/_compression.py",
+            "${libdir}/python${PYTHON_MAJMIN}/bz2.py",
+            "${libdir}/python${PYTHON_MAJMIN}/gzip.py",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_bz2.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_lzma.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/zlib.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lzma.py",
+            "${libdir}/python${PYTHON_MAJMIN}/tarfile.py",
+            "${libdir}/python${PYTHON_MAJMIN}/zipfile.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/_compression.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/bz2.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/gzip.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/lzma.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/tarfile.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/zipfile.*.pyc"
+        ]
     },
     "core": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/__future__.*.pyc",
-            "${libdir}/python3.5/__pycache__/_bootlocale.*.pyc",
-            "${libdir}/python3.5/__pycache__/_collections_abc.*.pyc",
-            "${libdir}/python3.5/__pycache__/_markupbase.*.pyc",
-            "${libdir}/python3.5/__pycache__/_sitebuiltins.*.pyc",
-            "${libdir}/python3.5/__pycache__/_sysconfigdata.*.pyc",
-            "${libdir}/python3.5/__pycache__/_weakrefset.*.pyc",
-            "${libdir}/python3.5/__pycache__/abc.*.pyc",
-            "${libdir}/python3.5/__pycache__/argparse.*.pyc",
-            "${libdir}/python3.5/__pycache__/ast.*.pyc",
-            "${libdir}/python3.5/__pycache__/bisect.*.pyc",
-            "${libdir}/python3.5/__pycache__/code.*.pyc",
-            "${libdir}/python3.5/__pycache__/codecs.*.pyc",
-            "${libdir}/python3.5/__pycache__/codeop.*.pyc",
-            "${libdir}/python3.5/__pycache__/configparser.*.pyc",
-            "${libdir}/python3.5/__pycache__/contextlib.*.pyc",
-            "${libdir}/python3.5/__pycache__/copy.*.pyc",
-            "${libdir}/python3.5/__pycache__/copyreg.*.pyc",
-            "${libdir}/python3.5/__pycache__/csv.*.pyc",
-            "${libdir}/python3.5/__pycache__/dis.*.pyc",
-            "${libdir}/python3.5/__pycache__/enum.*.pyc",
-            "${libdir}/python3.5/__pycache__/functools.*.pyc",
-            "${libdir}/python3.5/__pycache__/genericpath.*.pyc",
-            "${libdir}/python3.5/__pycache__/getopt.*.pyc",
-            "${libdir}/python3.5/__pycache__/gettext.*.pyc",
-            "${libdir}/python3.5/__pycache__/heapq.*.pyc",
-            "${libdir}/python3.5/__pycache__/imp.*.pyc",
-            "${libdir}/python3.5/__pycache__/inspect.*.pyc",
-            "${libdir}/python3.5/__pycache__/io.*.pyc",
-            "${libdir}/python3.5/__pycache__/keyword.*.pyc",
-            "${libdir}/python3.5/__pycache__/linecache.*.pyc",
-            "${libdir}/python3.5/__pycache__/locale.*.pyc",
-            "${libdir}/python3.5/__pycache__/opcode.*.pyc",
-            "${libdir}/python3.5/__pycache__/operator.*.pyc",
-            "${libdir}/python3.5/__pycache__/optparse.*.pyc",
-            "${libdir}/python3.5/__pycache__/os.*.pyc",
-            "${libdir}/python3.5/__pycache__/platform.*.pyc",
-            "${libdir}/python3.5/__pycache__/posixpath.*.pyc",
-            "${libdir}/python3.5/__pycache__/re.*.pyc",
-            "${libdir}/python3.5/__pycache__/reprlib.*.pyc",
-            "${libdir}/python3.5/__pycache__/rlcompleter.*.pyc",
-            "${libdir}/python3.5/__pycache__/selectors.*.pyc",
-            "${libdir}/python3.5/__pycache__/signal.*.pyc",
-            "${libdir}/python3.5/__pycache__/site.*.pyc",
-            "${libdir}/python3.5/__pycache__/sre_compile.*.pyc",
-            "${libdir}/python3.5/__pycache__/sre_constants.*.pyc",
-            "${libdir}/python3.5/__pycache__/sre_parse.*.pyc",
-            "${libdir}/python3.5/__pycache__/stat.*.pyc",
-            "${libdir}/python3.5/__pycache__/stringprep.*.pyc",
-            "${libdir}/python3.5/__pycache__/struct.*.pyc",
-            "${libdir}/python3.5/__pycache__/subprocess.*.pyc",
-            "${libdir}/python3.5/__pycache__/symbol.*.pyc",
-            "${libdir}/python3.5/__pycache__/sysconfig.*.pyc",
-            "${libdir}/python3.5/__pycache__/textwrap.*.pyc",
-            "${libdir}/python3.5/__pycache__/threading.*.pyc",
-            "${libdir}/python3.5/__pycache__/token.*.pyc",
-            "${libdir}/python3.5/__pycache__/tokenize.*.pyc",
-            "${libdir}/python3.5/__pycache__/traceback.*.pyc",
-            "${libdir}/python3.5/__pycache__/types.*.pyc",
-            "${libdir}/python3.5/__pycache__/warnings.*.pyc",
-            "${libdir}/python3.5/__pycache__/weakref.*.pyc",
-            "${libdir}/python3.5/collections/__pycache__",
-            "${libdir}/python3.5/collections/__pycache__/abc.*.pyc",
-            "${libdir}/python3.5/encodings/__pycache__",
-            "${libdir}/python3.5/encodings/__pycache__/aliases.*.pyc",
-            "${libdir}/python3.5/encodings/__pycache__/latin_1.*.pyc",
-            "${libdir}/python3.5/encodings/__pycache__/utf_8.*.pyc",
-            "${libdir}/python3.5/importlib/__pycache__",
-            "${libdir}/python3.5/importlib/__pycache__/abc.*.pyc",
-            "${libdir}/python3.5/importlib/__pycache__/machinery.*.pyc",
-            "${libdir}/python3.5/importlib/__pycache__/util.*.pyc"
-        ],
+        "summary": "Python interpreter and core modules",
+        "rdepends": [],
         "files": [
             "${bindir}/python*[!-config]",
             "${includedir}/python${PYTHON_BINABI}/pyconfig*.h",
+            "${libdir}/python${PYTHON_MAJMIN}/UserDict.py",
+            "${libdir}/python${PYTHON_MAJMIN}/UserList.py",
+            "${libdir}/python${PYTHON_MAJMIN}/UserString.py",
+            "${libdir}/python${PYTHON_MAJMIN}/__future__.py",
+            "${libdir}/python${PYTHON_MAJMIN}/_abcoll.py",
+            "${libdir}/python${PYTHON_MAJMIN}/_bootlocale.py",
             "${libdir}/python${PYTHON_MAJMIN}/_collections_abc.py",
+            "${libdir}/python${PYTHON_MAJMIN}/_markupbase.py",
             "${libdir}/python${PYTHON_MAJMIN}/_sitebuiltins.py",
+            "${libdir}/python${PYTHON_MAJMIN}/_sysconfigdata.py",
+            "${libdir}/python${PYTHON_MAJMIN}/_weakrefset.py",
+            "${libdir}/python${PYTHON_MAJMIN}/abc.py",
+            "${libdir}/python${PYTHON_MAJMIN}/argparse.py",
+            "${libdir}/python${PYTHON_MAJMIN}/ast.py",
+            "${libdir}/python${PYTHON_MAJMIN}/bisect.py",
+            "${libdir}/python${PYTHON_MAJMIN}/code.py",
+            "${libdir}/python${PYTHON_MAJMIN}/codecs.py",
+            "${libdir}/python${PYTHON_MAJMIN}/codeop.py",
             "${libdir}/python${PYTHON_MAJMIN}/collections",
+            "${libdir}/python${PYTHON_MAJMIN}/collections/abc.py",
+            "${libdir}/python${PYTHON_MAJMIN}/configparser.py",
+            "${libdir}/python${PYTHON_MAJMIN}/contextlib.py",
+            "${libdir}/python${PYTHON_MAJMIN}/copy.py",
+            "${libdir}/python${PYTHON_MAJMIN}/copyreg.py",
+            "${libdir}/python${PYTHON_MAJMIN}/csv.py",
+            "${libdir}/python${PYTHON_MAJMIN}/dis.py",
+            "${libdir}/python${PYTHON_MAJMIN}/encodings",
+            "${libdir}/python${PYTHON_MAJMIN}/encodings/aliases.py",
+            "${libdir}/python${PYTHON_MAJMIN}/encodings/latin_1.py",
+            "${libdir}/python${PYTHON_MAJMIN}/encodings/utf_8.py",
+            "${libdir}/python${PYTHON_MAJMIN}/enum.py",
+            "${libdir}/python${PYTHON_MAJMIN}/functools.py",
+            "${libdir}/python${PYTHON_MAJMIN}/genericpath.py",
+            "${libdir}/python${PYTHON_MAJMIN}/getopt.py",
+            "${libdir}/python${PYTHON_MAJMIN}/gettext.py",
+            "${libdir}/python${PYTHON_MAJMIN}/heapq.py",
+            "${libdir}/python${PYTHON_MAJMIN}/imp.py",
+            "${libdir}/python${PYTHON_MAJMIN}/importlib",
+            "${libdir}/python${PYTHON_MAJMIN}/importlib/_bootstrap.py",
+            "${libdir}/python${PYTHON_MAJMIN}/importlib/_bootstrap_external.py",
+            "${libdir}/python${PYTHON_MAJMIN}/importlib/abc.py",
+            "${libdir}/python${PYTHON_MAJMIN}/importlib/machinery.py",
+            "${libdir}/python${PYTHON_MAJMIN}/importlib/util.py",
+            "${libdir}/python${PYTHON_MAJMIN}/inspect.py",
+            "${libdir}/python${PYTHON_MAJMIN}/io.py",
+            "${libdir}/python${PYTHON_MAJMIN}/keyword.py",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/__pycache__/_struct.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/__pycache__/binascii.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/__pycache__/time.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/__pycache__/xreadlines.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_bisect.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_csv.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_heapq.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_opcode.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_posixsubprocess.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_struct.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/array.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/binascii.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/math.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/parser.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/readline.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/select.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/time.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/unicodedata.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/xreadlines.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/linecache.py",
+            "${libdir}/python${PYTHON_MAJMIN}/locale.py",
+            "${libdir}/python${PYTHON_MAJMIN}/new.py",
+            "${libdir}/python${PYTHON_MAJMIN}/opcode.py",
+            "${libdir}/python${PYTHON_MAJMIN}/operator.py",
+            "${libdir}/python${PYTHON_MAJMIN}/optparse.py",
+            "${libdir}/python${PYTHON_MAJMIN}/os.py",
+            "${libdir}/python${PYTHON_MAJMIN}/platform.py",
+            "${libdir}/python${PYTHON_MAJMIN}/posixpath.py",
+            "${libdir}/python${PYTHON_MAJMIN}/re.py",
+            "${libdir}/python${PYTHON_MAJMIN}/reprlib.py",
+            "${libdir}/python${PYTHON_MAJMIN}/rlcompleter.py",
+            "${libdir}/python${PYTHON_MAJMIN}/selectors.py",
+            "${libdir}/python${PYTHON_MAJMIN}/signal.py",
+            "${libdir}/python${PYTHON_MAJMIN}/site.py",
             "${libdir}/python${PYTHON_MAJMIN}/sitecustomize.py",
-            "${libdir}/python3.5/UserDict.py",
-            "${libdir}/python3.5/UserList.py",
-            "${libdir}/python3.5/UserString.py",
-            "${libdir}/python3.5/__future__.py",
-            "${libdir}/python3.5/_abcoll.py",
-            "${libdir}/python3.5/_bootlocale.py",
-            "${libdir}/python3.5/_collections_abc.py",
-            "${libdir}/python3.5/_markupbase.py",
-            "${libdir}/python3.5/_sitebuiltins.py",
-            "${libdir}/python3.5/_sysconfigdata.py",
-            "${libdir}/python3.5/_weakrefset.py",
-            "${libdir}/python3.5/abc.py",
-            "${libdir}/python3.5/argparse.py",
-            "${libdir}/python3.5/ast.py",
-            "${libdir}/python3.5/bisect.py",
-            "${libdir}/python3.5/code.py",
-            "${libdir}/python3.5/codecs.py",
-            "${libdir}/python3.5/codeop.py",
-            "${libdir}/python3.5/collections",
-            "${libdir}/python3.5/collections/abc.py",
-            "${libdir}/python3.5/configparser.py",
-            "${libdir}/python3.5/contextlib.py",
-            "${libdir}/python3.5/copy.py",
-            "${libdir}/python3.5/copyreg.py",
-            "${libdir}/python3.5/csv.py",
-            "${libdir}/python3.5/dis.py",
-            "${libdir}/python3.5/encodings",
-            "${libdir}/python3.5/encodings/aliases.py",
-            "${libdir}/python3.5/encodings/latin_1.py",
-            "${libdir}/python3.5/encodings/utf_8.py",
-            "${libdir}/python3.5/enum.py",
-            "${libdir}/python3.5/functools.py",
-            "${libdir}/python3.5/genericpath.py",
-            "${libdir}/python3.5/getopt.py",
-            "${libdir}/python3.5/gettext.py",
-            "${libdir}/python3.5/heapq.py",
-            "${libdir}/python3.5/imp.py",
-            "${libdir}/python3.5/importlib",
-            "${libdir}/python3.5/importlib/_bootstrap.py",
-            "${libdir}/python3.5/importlib/_bootstrap_external.py",
-            "${libdir}/python3.5/importlib/abc.py",
-            "${libdir}/python3.5/importlib/machinery.py",
-            "${libdir}/python3.5/importlib/util.py",
-            "${libdir}/python3.5/inspect.py",
-            "${libdir}/python3.5/io.py",
-            "${libdir}/python3.5/keyword.py",
-            "${libdir}/python3.5/lib-dynload/__pycache__/_struct.*.so",
-            "${libdir}/python3.5/lib-dynload/__pycache__/binascii.*.so",
-            "${libdir}/python3.5/lib-dynload/__pycache__/time.*.so",
-            "${libdir}/python3.5/lib-dynload/__pycache__/xreadlines.*.so",
-            "${libdir}/python3.5/lib-dynload/_bisect.*.so",
-            "${libdir}/python3.5/lib-dynload/_csv.*.so",
-            "${libdir}/python3.5/lib-dynload/_heapq.*.so",
-            "${libdir}/python3.5/lib-dynload/_opcode.*.so",
-            "${libdir}/python3.5/lib-dynload/_posixsubprocess.*.so",
-            "${libdir}/python3.5/lib-dynload/_struct.*.so",
-            "${libdir}/python3.5/lib-dynload/array.*.so",
-            "${libdir}/python3.5/lib-dynload/binascii.*.so",
-            "${libdir}/python3.5/lib-dynload/math.*.so",
-            "${libdir}/python3.5/lib-dynload/parser.*.so",
-            "${libdir}/python3.5/lib-dynload/readline.*.so",
-            "${libdir}/python3.5/lib-dynload/select.*.so",
-            "${libdir}/python3.5/lib-dynload/time.*.so",
-            "${libdir}/python3.5/lib-dynload/unicodedata.*.so",
-            "${libdir}/python3.5/lib-dynload/xreadlines.*.so",
-            "${libdir}/python3.5/linecache.py",
-            "${libdir}/python3.5/locale.py",
-            "${libdir}/python3.5/new.py",
-            "${libdir}/python3.5/opcode.py",
-            "${libdir}/python3.5/operator.py",
-            "${libdir}/python3.5/optparse.py",
-            "${libdir}/python3.5/os.py",
-            "${libdir}/python3.5/platform.py",
-            "${libdir}/python3.5/posixpath.py",
-            "${libdir}/python3.5/re.py",
-            "${libdir}/python3.5/reprlib.py",
-            "${libdir}/python3.5/rlcompleter.py",
-            "${libdir}/python3.5/selectors.py",
-            "${libdir}/python3.5/signal.py",
-            "${libdir}/python3.5/site.py",
-            "${libdir}/python3.5/sre_compile.py",
-            "${libdir}/python3.5/sre_constants.py",
-            "${libdir}/python3.5/sre_parse.py",
-            "${libdir}/python3.5/stat.py",
-            "${libdir}/python3.5/stringprep.py",
-            "${libdir}/python3.5/struct.py",
-            "${libdir}/python3.5/subprocess.py",
-            "${libdir}/python3.5/symbol.py",
-            "${libdir}/python3.5/sysconfig.py",
-            "${libdir}/python3.5/textwrap.py",
-            "${libdir}/python3.5/threading.py",
-            "${libdir}/python3.5/token.py",
-            "${libdir}/python3.5/tokenize.py",
-            "${libdir}/python3.5/traceback.py",
-            "${libdir}/python3.5/types.py",
-            "${libdir}/python3.5/warnings.py",
-            "${libdir}/python3.5/weakref.py"
+            "${libdir}/python${PYTHON_MAJMIN}/sre_compile.py",
+            "${libdir}/python${PYTHON_MAJMIN}/sre_constants.py",
+            "${libdir}/python${PYTHON_MAJMIN}/sre_parse.py",
+            "${libdir}/python${PYTHON_MAJMIN}/stat.py",
+            "${libdir}/python${PYTHON_MAJMIN}/stringprep.py",
+            "${libdir}/python${PYTHON_MAJMIN}/struct.py",
+            "${libdir}/python${PYTHON_MAJMIN}/subprocess.py",
+            "${libdir}/python${PYTHON_MAJMIN}/symbol.py",
+            "${libdir}/python${PYTHON_MAJMIN}/sysconfig.py",
+            "${libdir}/python${PYTHON_MAJMIN}/textwrap.py",
+            "${libdir}/python${PYTHON_MAJMIN}/threading.py",
+            "${libdir}/python${PYTHON_MAJMIN}/token.py",
+            "${libdir}/python${PYTHON_MAJMIN}/tokenize.py",
+            "${libdir}/python${PYTHON_MAJMIN}/traceback.py",
+            "${libdir}/python${PYTHON_MAJMIN}/types.py",
+            "${libdir}/python${PYTHON_MAJMIN}/warnings.py",
+            "${libdir}/python${PYTHON_MAJMIN}/weakref.py"
         ],
-        "rdepends": [],
-        "summary": "Python interpreter and core modules"
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/__future__.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/_bootlocale.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/_collections_abc.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/_markupbase.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/_sitebuiltins.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/_sysconfigdata.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/_weakrefset.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/abc.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/argparse.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/ast.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/bisect.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/code.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/codecs.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/codeop.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/configparser.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/contextlib.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/copy.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/copyreg.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/csv.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/dis.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/enum.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/functools.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/genericpath.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/getopt.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/gettext.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/heapq.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/imp.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/inspect.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/io.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/keyword.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/linecache.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/locale.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/opcode.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/operator.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/optparse.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/os.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/platform.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/posixpath.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/re.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/reprlib.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/rlcompleter.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/selectors.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/signal.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/site.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/sre_compile.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/sre_constants.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/sre_parse.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/stat.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/stringprep.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/struct.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/subprocess.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/symbol.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/sysconfig.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/textwrap.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/threading.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/token.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/tokenize.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/traceback.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/types.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/warnings.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/weakref.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/collections/__pycache__",
+            "${libdir}/python${PYTHON_MAJMIN}/collections/__pycache__/abc.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/encodings/__pycache__",
+            "${libdir}/python${PYTHON_MAJMIN}/encodings/__pycache__/aliases.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/encodings/__pycache__/latin_1.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/encodings/__pycache__/utf_8.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/importlib/__pycache__",
+            "${libdir}/python${PYTHON_MAJMIN}/importlib/__pycache__/abc.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/importlib/__pycache__/machinery.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/importlib/__pycache__/util.*.pyc"
+        ]
     },
     "crypt": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/crypt.*.pyc",
-            "${libdir}/python3.5/__pycache__/hashlib.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/crypt.py",
-            "${libdir}/python3.5/hashlib.py",
-            "${libdir}/python3.5/lib-dynload/_crypt.*.so",
-            "${libdir}/python3.5/lib-dynload/_hashlib.*.so",
-            "${libdir}/python3.5/lib-dynload/_sha256.*.so",
-            "${libdir}/python3.5/lib-dynload/_sha512.*.so"
-        ],
+        "summary": "Python basic cryptographic and hashing support",
         "rdepends": [
             "core",
             "math",
             "stringold"
         ],
-        "summary": "Python basic cryptographic and hashing support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/crypt.py",
+            "${libdir}/python${PYTHON_MAJMIN}/hashlib.py",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_crypt.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_hashlib.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_sha256.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_sha512.*.so"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/crypt.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/hashlib.*.pyc"
+        ]
     },
     "ctypes": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/ctypes",
-            "${libdir}/python3.5/lib-dynload/_ctypes.*.so",
-            "${libdir}/python3.5/lib-dynload/_ctypes_test.*.so"
-        ],
+        "summary": "Python C types support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python C types support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/ctypes",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_ctypes.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_ctypes_test.*.so"
+        ],
+        "cached": []
     },
     "curses": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/curses",
-            "${libdir}/python3.5/lib-dynload/_curses.*.so",
-            "${libdir}/python3.5/lib-dynload/_curses_panel.*.so"
-        ],
+        "summary": "Python curses support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python curses support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/curses",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_curses.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_curses_panel.*.so"
+        ],
+        "cached": []
     },
     "datetime": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/_strptime.*.pyc",
-            "${libdir}/python3.5/__pycache__/calendar.*.pyc",
-            "${libdir}/python3.5/__pycache__/datetime.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/_strptime.py",
-            "${libdir}/python3.5/calendar.py",
-            "${libdir}/python3.5/datetime.py",
-            "${libdir}/python3.5/lib-dynload/_datetime.*.so"
-        ],
+        "summary": "Python calendar and time support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python calendar and time support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/_strptime.py",
+            "${libdir}/python${PYTHON_MAJMIN}/calendar.py",
+            "${libdir}/python${PYTHON_MAJMIN}/datetime.py",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_datetime.*.so"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/_strptime.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/calendar.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/datetime.*.pyc"
+        ]
     },
     "db": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/dbm",
-            "${libdir}/python3.5/lib-dynload/_dbm.*.so"
-        ],
+        "summary": "Python file-based database support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python file-based database support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/dbm",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_dbm.*.so"
+        ],
+        "cached": []
     },
     "debugger": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/bdb.*.pyc",
-            "${libdir}/python3.5/__pycache__/pdb.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/bdb.py",
-            "${libdir}/python3.5/pdb.py"
-        ],
+        "summary": "Python debugger",
         "rdepends": [
             "core",
             "pprint",
             "shell",
             "stringold"
         ],
-        "summary": "Python debugger"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/bdb.py",
+            "${libdir}/python${PYTHON_MAJMIN}/pdb.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/bdb.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/pdb.*.pyc"
+        ]
     },
     "dev": {
         "cached": [],
@@ -405,8 +416,8 @@
             "${libdir}/*.o",
             "${libdir}/lib*${SOLIBSDEV}",
             "${libdir}/pkgconfig",
-            "${libdir}/python3.5/config*/Makefile",
-            "${libdir}/python3.5/config*/Makefile/__pycache__"
+            "${libdir}/python${PYTHON_MAJMIN}/config*/Makefile",
+            "${libdir}/python${PYTHON_MAJMIN}/config*/Makefile/__pycache__"
         ],
         "rdepends": [
             "core"
@@ -414,46 +425,41 @@
         "summary": "Python development package"
     },
     "difflib": {
+        "summary": "Python helpers for computing deltas between objects",
+        "rdepends": [
+            "core"
+        ],
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/difflib.py"
+        ],
         "cached": [
-            "${libdir}/python3.5/__pycache__/difflib.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/difflib.py"
-        ],
-        "rdepends": [
-            "core"
-        ],
-        "summary": "Python helpers for computing deltas between objects"
-    },
-    "distutils": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/distutils"
-        ],
-        "rdepends": [
-            "core"
-        ],
-        "summary": "Python Distribution Utilities"
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/difflib.*.pyc"
+        ]
     },
     "distutils-staticdev": {
         "cached": [
-            "${libdir}/python3.5/config/__pycache__/lib*.a"
+            "${libdir}/python${PYTHON_MAJMIN}/config/__pycache__/lib*.a"
         ],
         "files": [
-            "${libdir}/python3.5/config/lib*.a"
+            "${libdir}/python${PYTHON_MAJMIN}/config/lib*.a"
         ],
         "rdepends": [
             "distutils"
         ],
         "summary": "Python distribution utilities (static libraries)"
     },
-    "doctest": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/doctest.*.pyc"
+    "distutils": {
+        "summary": "Python Distribution Utilities",
+        "rdepends": [
+            "core"
         ],
         "files": [
-            "${libdir}/python3.5/doctest.py"
+            "${libdir}/python${PYTHON_MAJMIN}/distutils"
         ],
+        "cached": []
+    },
+    "doctest": {
+        "summary": "Python framework for running examples in docstrings",
         "rdepends": [
             "core",
             "debugger",
@@ -464,16 +470,15 @@
             "stringold",
             "unittest"
         ],
-        "summary": "Python framework for running examples in docstrings"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/doctest.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/doctest.*.pyc"
+        ]
     },
     "email": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/imaplib.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/email",
-            "${libdir}/python3.5/imaplib.py"
-        ],
+        "summary": "Python email support",
         "rdepends": [
             "core",
             "crypt",
@@ -482,86 +487,74 @@
             "math",
             "netclient"
         ],
-        "summary": "Python email support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/email",
+            "${libdir}/python${PYTHON_MAJMIN}/imaplib.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/imaplib.*.pyc"
+        ]
     },
     "fcntl": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/lib-dynload/fcntl.*.so"
-        ],
+        "summary": "Python's fcntl interface",
         "rdepends": [
             "core"
         ],
-        "summary": "Python's fcntl interface"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/fcntl.*.so"
+        ],
+        "cached": []
     },
     "gdbm": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/lib-dynload/_gdbm.*.so"
-        ],
+        "summary": "Python GNU database support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python GNU database support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_gdbm.*.so"
+        ],
+        "cached": []
     },
     "html": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/formatter.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/formatter.py",
-            "${libdir}/python3.5/html"
-        ],
+        "summary": "Python HTML processing support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python HTML processing support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/formatter.py",
+            "${libdir}/python${PYTHON_MAJMIN}/html"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/formatter.*.pyc"
+        ]
     },
     "idle": {
-        "cached": [],
+        "summary": "Python Integrated Development Environment",
+        "rdepends": [
+            "core"
+        ],
         "files": [
             "${bindir}/idle*",
-            "${libdir}/python3.5/idlelib"
+            "${libdir}/python${PYTHON_MAJMIN}/idlelib"
         ],
-        "rdepends": [
-            "core"
-        ],
-        "summary": "Python Integrated Development Environment"
+        "cached": []
     },
     "image": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/colorsys.*.pyc",
-            "${libdir}/python3.5/__pycache__/imghdr.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/colorsys.py",
-            "${libdir}/python3.5/imghdr.py"
-        ],
+        "summary": "Python graphical image handling",
         "rdepends": [
             "core"
         ],
-        "summary": "Python graphical image handling"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/colorsys.py",
+            "${libdir}/python${PYTHON_MAJMIN}/imghdr.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/colorsys.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/imghdr.*.pyc"
+        ]
     },
     "io": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/_pyio.*.pyc",
-            "${libdir}/python3.5/__pycache__/ipaddress.*.pyc",
-            "${libdir}/python3.5/__pycache__/pipes.*.pyc",
-            "${libdir}/python3.5/__pycache__/socket.*.pyc",
-            "${libdir}/python3.5/__pycache__/ssl.*.pyc",
-            "${libdir}/python3.5/__pycache__/tempfile.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/_pyio.py",
-            "${libdir}/python3.5/ipaddress.py",
-            "${libdir}/python3.5/lib-dynload/_socket.*.so",
-            "${libdir}/python3.5/lib-dynload/_ssl.*.so",
-            "${libdir}/python3.5/lib-dynload/termios.*.so",
-            "${libdir}/python3.5/pipes.py",
-            "${libdir}/python3.5/socket.py",
-            "${libdir}/python3.5/ssl.py",
-            "${libdir}/python3.5/tempfile.py"
-        ],
+        "summary": "Python low-level I/O",
         "rdepends": [
             "compression",
             "core",
@@ -571,37 +564,50 @@
             "shell",
             "unixadmin"
         ],
-        "summary": "Python low-level I/O"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/_pyio.py",
+            "${libdir}/python${PYTHON_MAJMIN}/ipaddress.py",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_socket.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_ssl.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/termios.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/pipes.py",
+            "${libdir}/python${PYTHON_MAJMIN}/socket.py",
+            "${libdir}/python${PYTHON_MAJMIN}/ssl.py",
+            "${libdir}/python${PYTHON_MAJMIN}/tempfile.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/_pyio.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/ipaddress.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/pipes.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/socket.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/ssl.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/tempfile.*.pyc"
+        ]
     },
     "json": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/json",
-            "${libdir}/python3.5/lib-dynload/_json.*.so"
-        ],
+        "summary": "Python JSON support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python JSON support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/json",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_json.*.so"
+        ],
+        "cached": []
     },
     "logging": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/logging"
-        ],
+        "summary": "Python logging support",
         "rdepends": [
             "core",
             "stringold"
         ],
-        "summary": "Python logging support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/logging"
+        ],
+        "cached": []
     },
     "mailbox": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/mailbox.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/mailbox.py"
-        ],
+        "summary": "Python mailbox format support",
         "rdepends": [
             "core",
             "crypt",
@@ -614,46 +620,51 @@
             "netclient",
             "stringold"
         ],
-        "summary": "Python mailbox format support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/mailbox.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/mailbox.*.pyc"
+        ]
     },
     "math": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/random.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/lib-dynload/_random.*.so",
-            "${libdir}/python3.5/lib-dynload/cmath.*.so",
-            "${libdir}/python3.5/random.py"
-        ],
+        "summary": "Python math support",
         "rdepends": [
             "core",
             "crypt"
         ],
-        "summary": "Python math support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_random.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/cmath.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/random.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/random.*.pyc"
+        ]
     },
     "mime": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/quopri.*.pyc",
-            "${libdir}/python3.5/__pycache__/uu.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/quopri.py",
-            "${libdir}/python3.5/uu.py"
-        ],
+        "summary": "Python MIME handling APIs",
         "rdepends": [
             "core"
         ],
-        "summary": "Python MIME handling APIs"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/quopri.py",
+            "${libdir}/python${PYTHON_MAJMIN}/uu.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/quopri.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/uu.*.pyc"
+        ]
     },
     "mmap": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/lib-dynload/mmap.*.so"
-        ],
+        "summary": "Python memory-mapped file support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python memory-mapped file support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/mmap.*.so"
+        ],
+        "cached": []
     },
     "modules": {
         "cached": [],
@@ -710,49 +721,25 @@
             "typing",
             "unittest",
             "unixadmin",
+            "venv",
             "xml",
             "xmlrpc"
         ],
         "summary": "All Python modules"
     },
     "multiprocessing": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/lib-dynload/_multiprocessing.*.so",
-            "${libdir}/python3.5/multiprocessing"
-        ],
+        "summary": "Python multiprocessing support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python multiprocessing support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_multiprocessing.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/multiprocessing"
+        ],
+        "cached": []
     },
     "netclient": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/base64.*.pyc",
-            "${libdir}/python3.5/__pycache__/ftplib.*.pyc",
-            "${libdir}/python3.5/__pycache__/hmac.*.pyc",
-            "${libdir}/python3.5/__pycache__/mimetypes.*.pyc",
-            "${libdir}/python3.5/__pycache__/nntplib.*.pyc",
-            "${libdir}/python3.5/__pycache__/poplib.*.pyc",
-            "${libdir}/python3.5/__pycache__/smtplib.*.pyc",
-            "${libdir}/python3.5/__pycache__/telnetlib.*.pyc",
-            "${libdir}/python3.5/__pycache__/uuid.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/base64.py",
-            "${libdir}/python3.5/ftplib.py",
-            "${libdir}/python3.5/hmac.py",
-            "${libdir}/python3.5/http",
-            "${libdir}/python3.5/http/__pycache__",
-            "${libdir}/python3.5/mimetypes.py",
-            "${libdir}/python3.5/nntplib.py",
-            "${libdir}/python3.5/poplib.py",
-            "${libdir}/python3.5/smtplib.py",
-            "${libdir}/python3.5/telnetlib.py",
-            "${libdir}/python3.5/urllib",
-            "${libdir}/python3.5/urllib/__pycache__",
-            "${libdir}/python3.5/uuid.py"
-        ],
+        "summary": "Python Internet Protocol clients",
         "rdepends": [
             "compression",
             "core",
@@ -767,17 +754,35 @@
             "stringold",
             "unixadmin"
         ],
-        "summary": "Python Internet Protocol clients"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/base64.py",
+            "${libdir}/python${PYTHON_MAJMIN}/ftplib.py",
+            "${libdir}/python${PYTHON_MAJMIN}/hmac.py",
+            "${libdir}/python${PYTHON_MAJMIN}/http",
+            "${libdir}/python${PYTHON_MAJMIN}/http/__pycache__",
+            "${libdir}/python${PYTHON_MAJMIN}/mimetypes.py",
+            "${libdir}/python${PYTHON_MAJMIN}/nntplib.py",
+            "${libdir}/python${PYTHON_MAJMIN}/poplib.py",
+            "${libdir}/python${PYTHON_MAJMIN}/smtplib.py",
+            "${libdir}/python${PYTHON_MAJMIN}/telnetlib.py",
+            "${libdir}/python${PYTHON_MAJMIN}/urllib",
+            "${libdir}/python${PYTHON_MAJMIN}/urllib/__pycache__",
+            "${libdir}/python${PYTHON_MAJMIN}/uuid.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/base64.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/ftplib.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/hmac.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/mimetypes.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/nntplib.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/poplib.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/smtplib.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/telnetlib.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/uuid.*.pyc"
+        ]
     },
     "netserver": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/cgi.*.pyc",
-            "${libdir}/python3.5/__pycache__/socketserver.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/cgi.py",
-            "${libdir}/python3.5/socketserver.py"
-        ],
+        "summary": "Python Internet Protocol servers",
         "rdepends": [
             "compression",
             "core",
@@ -793,175 +798,172 @@
             "stringold",
             "unixadmin"
         ],
-        "summary": "Python Internet Protocol servers"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/cgi.py",
+            "${libdir}/python${PYTHON_MAJMIN}/socketserver.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/cgi.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/socketserver.*.pyc"
+        ]
     },
     "numbers": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/_pydecimal.*.pyc",
-            "${libdir}/python3.5/__pycache__/decimal.*.pyc",
-            "${libdir}/python3.5/__pycache__/fractions.*.pyc",
-            "${libdir}/python3.5/__pycache__/numbers.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/_pydecimal.py",
-            "${libdir}/python3.5/decimal.py",
-            "${libdir}/python3.5/fractions.py",
-            "${libdir}/python3.5/lib-dynload/_decimal.*.so",
-            "${libdir}/python3.5/numbers.py"
-        ],
+        "summary": "Python number APIs",
         "rdepends": [
             "core"
         ],
-        "summary": "Python number APIs"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/_pydecimal.py",
+            "${libdir}/python${PYTHON_MAJMIN}/decimal.py",
+            "${libdir}/python${PYTHON_MAJMIN}/fractions.py",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_decimal.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/numbers.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/_pydecimal.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/decimal.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/fractions.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/numbers.*.pyc"
+        ]
     },
     "pickle": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/_compat_pickle.*.pyc",
-            "${libdir}/python3.5/__pycache__/pickle.*.pyc",
-            "${libdir}/python3.5/__pycache__/pickletools.*.pyc",
-            "${libdir}/python3.5/__pycache__/shelve.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/_compat_pickle.py",
-            "${libdir}/python3.5/lib-dynload/_pickle.*.so",
-            "${libdir}/python3.5/pickle.py",
-            "${libdir}/python3.5/pickletools.py",
-            "${libdir}/python3.5/shelve.py"
-        ],
+        "summary": "Python serialisation/persistence support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python serialisation/persistence support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/_compat_pickle.py",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_pickle.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/pickle.py",
+            "${libdir}/python${PYTHON_MAJMIN}/pickletools.py",
+            "${libdir}/python${PYTHON_MAJMIN}/shelve.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/_compat_pickle.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/pickle.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/pickletools.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/shelve.*.pyc"
+        ]
     },
     "pkgutil": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/pkgutil.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/pkgutil.py"
-        ],
+        "summary": "Python package extension utility support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python package extension utility support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/pkgutil.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/pkgutil.*.pyc"
+        ]
     },
     "plistlib": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/plistlib.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/plistlib.py"
-        ],
+        "summary": "Generate and parse Mac OS X .plist files",
         "rdepends": [
             "core",
             "datetime",
             "xml"
         ],
-        "summary": "Generate and parse Mac OS X .plist files"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/plistlib.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/plistlib.*.pyc"
+        ]
     },
     "pprint": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/pprint.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/pprint.py"
-        ],
+        "summary": "Python pretty-print support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python pretty-print support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/pprint.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/pprint.*.pyc"
+        ]
     },
     "profile": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/cProfile.*.pyc",
-            "${libdir}/python3.5/__pycache__/profile.*.pyc",
-            "${libdir}/python3.5/__pycache__/pstats.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/cProfile.py",
-            "${libdir}/python3.5/lib-dynload/_lsprof.*.so",
-            "${libdir}/python3.5/profile.py",
-            "${libdir}/python3.5/pstats.py"
-        ],
+        "summary": "Python basic performance profiling support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python basic performance profiling support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/cProfile.py",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_lsprof.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/profile.py",
+            "${libdir}/python${PYTHON_MAJMIN}/pstats.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/cProfile.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/profile.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/pstats.*.pyc"
+        ]
     },
     "pydoc": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/pydoc.*.pyc"
-        ],
-        "files": [
-            "${bindir}/pydoc*",
-            "${libdir}/python3.5/pydoc.py",
-            "${libdir}/python3.5/pydoc_data"
-        ],
+        "summary": "Python interactive help support",
         "rdepends": [
             "core",
             "netclient",
             "pkgutil"
         ],
-        "summary": "Python interactive help support"
+        "files": [
+            "${bindir}/pydoc*",
+            "${libdir}/python${PYTHON_MAJMIN}/pydoc.py",
+            "${libdir}/python${PYTHON_MAJMIN}/pydoc_data"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/pydoc.*.pyc"
+        ]
     },
     "resource": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/lib-dynload/resource.*.so"
-        ],
+        "summary": "Python resource control interface",
         "rdepends": [
             "core"
         ],
-        "summary": "Python resource control interface"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/resource.*.so"
+        ],
+        "cached": []
     },
     "runpy": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/runpy.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/runpy.py"
-        ],
+        "summary": "Python helper for locating/executing scripts in module namespace",
         "rdepends": [
             "core",
             "pkgutil"
         ],
-        "summary": "Python helper for locating/executing scripts in module namespace"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/runpy.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/runpy.*.pyc"
+        ]
     },
     "shell": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/cmd.*.pyc",
-            "${libdir}/python3.5/__pycache__/fnmatch.*.pyc",
-            "${libdir}/python3.5/__pycache__/glob.*.pyc",
-            "${libdir}/python3.5/__pycache__/shlex.*.pyc",
-            "${libdir}/python3.5/__pycache__/shutil.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/cmd.py",
-            "${libdir}/python3.5/fnmatch.py",
-            "${libdir}/python3.5/glob.py",
-            "${libdir}/python3.5/shlex.py",
-            "${libdir}/python3.5/shutil.py"
-        ],
+        "summary": "Python shell-like functionality",
         "rdepends": [
             "compression",
             "core",
             "stringold",
             "unixadmin"
         ],
-        "summary": "Python shell-like functionality"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/cmd.py",
+            "${libdir}/python${PYTHON_MAJMIN}/fnmatch.py",
+            "${libdir}/python${PYTHON_MAJMIN}/glob.py",
+            "${libdir}/python${PYTHON_MAJMIN}/shlex.py",
+            "${libdir}/python${PYTHON_MAJMIN}/shutil.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/cmd.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/fnmatch.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/glob.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/shlex.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/shutil.*.pyc"
+        ]
     },
     "smtpd": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/asynchat.*.pyc",
-            "${libdir}/python3.5/__pycache__/asyncore.*.pyc",
-            "${libdir}/python3.5/__pycache__/smtpd.*.pyc"
-        ],
-        "files": [
-            "${bindir}/smtpd.py",
-            "${libdir}/python3.5/asynchat.py",
-            "${libdir}/python3.5/asyncore.py",
-            "${libdir}/python3.5/smtpd.py"
-        ],
+        "summary": "Python Simple Mail Transport Daemon",
         "rdepends": [
             "core",
             "crypt",
@@ -973,130 +975,109 @@
             "netclient",
             "stringold"
         ],
-        "summary": "Python Simple Mail Transport Daemon"
+        "files": [
+            "${bindir}/smtpd.py",
+            "${libdir}/python${PYTHON_MAJMIN}/asynchat.py",
+            "${libdir}/python${PYTHON_MAJMIN}/asyncore.py",
+            "${libdir}/python${PYTHON_MAJMIN}/smtpd.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/asynchat.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/asyncore.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/smtpd.*.pyc"
+        ]
     },
     "sqlite3": {
-        "cached": [
-            "${libdir}/python3.5/sqlite3/__pycache__",
-            "${libdir}/python3.5/sqlite3/__pycache__/dbapi2.*.pyc",
-            "${libdir}/python3.5/sqlite3/__pycache__/dump.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/lib-dynload/_sqlite3.*.so",
-            "${libdir}/python3.5/sqlite3/dbapi2.py",
-            "${libdir}/python3.5/sqlite3/dump.py"
-        ],
+        "summary": "Python Sqlite3 database support",
         "rdepends": [
             "core",
             "datetime"
         ],
-        "summary": "Python Sqlite3 database support"
-    },
-    "sqlite3-tests": {
-        "cached": [],
         "files": [
-            "${libdir}/python3.5/sqlite3/test"
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_sqlite3.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/sqlite3"
         ],
-        "rdepends": [
-            "core",
-            "tests"
-        ],
-        "summary": "Python Sqlite3 database support tests"
+        "cached": []
     },
     "stringold": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/string.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/string.py"
-        ],
+        "summary": "Python string APIs [deprecated]",
         "rdepends": [
             "core"
         ],
-        "summary": "Python string APIs [deprecated]"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/string.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/string.*.pyc"
+        ]
     },
     "syslog": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/lib-dynload/syslog.*.so"
-        ],
+        "summary": "Python syslog interface",
         "rdepends": [
             "core"
         ],
-        "summary": "Python syslog interface"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/syslog.*.so"
+        ],
+        "cached": []
     },
     "terminal": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/pty.*.pyc",
-            "${libdir}/python3.5/__pycache__/tty.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/pty.py",
-            "${libdir}/python3.5/tty.py"
-        ],
+        "summary": "Python terminal controlling support",
         "rdepends": [
             "core",
             "io"
         ],
-        "summary": "Python terminal controlling support"
-    },
-    "tests": {
-        "cached": [],
         "files": [
-            "${libdir}/python3.5/test"
+            "${libdir}/python${PYTHON_MAJMIN}/pty.py",
+            "${libdir}/python${PYTHON_MAJMIN}/tty.py"
         ],
-        "rdepends": [
-            "core"
-        ],
-        "summary": "Python tests"
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/pty.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/tty.*.pyc"
+        ]
     },
     "threading": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/_dummy_thread.*.pyc",
-            "${libdir}/python3.5/__pycache__/_threading_local.*.pyc",
-            "${libdir}/python3.5/__pycache__/dummy_threading.*.pyc",
-            "${libdir}/python3.5/__pycache__/queue.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/_dummy_thread.py",
-            "${libdir}/python3.5/_threading_local.py",
-            "${libdir}/python3.5/dummy_threading.py",
-            "${libdir}/python3.5/queue.py"
-        ],
+        "summary": "Python threading & synchronization support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python threading & synchronization support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/_dummy_thread.py",
+            "${libdir}/python${PYTHON_MAJMIN}/_threading_local.py",
+            "${libdir}/python${PYTHON_MAJMIN}/dummy_threading.py",
+            "${libdir}/python${PYTHON_MAJMIN}/queue.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/_dummy_thread.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/_threading_local.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/dummy_threading.*.pyc",
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/queue.*.pyc"
+        ]
     },
     "tkinter": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/tkinter"
-        ],
+        "summary": "Python Tcl/Tk bindings",
         "rdepends": [
             "core"
         ],
-        "summary": "Python Tcl/Tk bindings"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/tkinter"
+        ],
+        "cached": []
     },
     "typing": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/typing.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/typing.py"
-        ],
+        "summary": "Python typing support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python typing support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/typing.py"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/typing.*.pyc"
+        ]
     },
     "unittest": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/unittest",
-            "${libdir}/python3.5/unittest/",
-            "${libdir}/python3.5/unittest/__pycache__"
-        ],
+        "summary": "Python unit testing framework",
         "rdepends": [
             "core",
             "difflib",
@@ -1105,45 +1086,66 @@
             "shell",
             "stringold"
         ],
-        "summary": "Python unit testing framework"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/unittest",
+            "${libdir}/python${PYTHON_MAJMIN}/unittest/",
+            "${libdir}/python${PYTHON_MAJMIN}/unittest/__pycache__"
+        ],
+        "cached": []
     },
     "unixadmin": {
-        "cached": [
-            "${libdir}/python3.5/__pycache__/getpass.*.pyc"
-        ],
-        "files": [
-            "${libdir}/python3.5/getpass.py",
-            "${libdir}/python3.5/lib-dynload/grp.*.so",
-            "${libdir}/python3.5/lib-dynload/nis.*.so"
-        ],
+        "summary": "Python Unix administration support",
         "rdepends": [
             "core",
             "io"
         ],
-        "summary": "Python Unix administration support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/getpass.py",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/grp.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/nis.*.so"
+        ],
+        "cached": [
+            "${libdir}/python${PYTHON_MAJMIN}/__pycache__/getpass.*.pyc"
+        ]
+    },
+    "venv": {
+        "summary": "Provides support for creating lightweight virtual environments with their own site directories, optionally isolated from system site directories.",
+        "rdepends": [
+            "compression",
+            "core",
+            "logging",
+            "shell",
+            "stringold",
+            "unixadmin"
+        ],
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/venv",
+            "${bindir}/pyvenv*"
+        ],
+        "cached": []
     },
     "xml": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/lib-dynload/_elementtree.*.so",
-            "${libdir}/python3.5/lib-dynload/pyexpat.*.so",
-            "${libdir}/python3.5/xml"
-        ],
+        "summary": "Python basic XML support",
         "rdepends": [
             "core"
         ],
-        "summary": "Python basic XML support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/_elementtree.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/pyexpat.*.so",
+            "${libdir}/python${PYTHON_MAJMIN}/xml"
+        ],
+        "cached": []
     },
     "xmlrpc": {
-        "cached": [],
-        "files": [
-            "${libdir}/python3.5/xmlrpc",
-            "${libdir}/python3.5/xmlrpc/__pycache__"
-        ],
+        "summary": "Python XML-RPC support",
         "rdepends": [
             "core",
             "xml"
         ],
-        "summary": "Python XML-RPC support"
+        "files": [
+            "${libdir}/python${PYTHON_MAJMIN}/xmlrpc",
+            "${libdir}/python${PYTHON_MAJMIN}/xmlrpc/__pycache__"
+        ],
+        "cached": []
     }
-}
\ No newline at end of file
+}
diff --git a/poky/meta/recipes-devtools/python/python3/run-ptest b/poky/meta/recipes-devtools/python/python3/run-ptest
new file mode 100644
index 0000000..3863c6d
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3/run-ptest
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+python3 -m test -v | sed -e '/\.\.\. ok/ s/^/PASS: /g' -e '/\.\.\. [ERROR|FAIL]/ s/^/FAIL: /g' -e '/\.\.\. skipped/ s/^/SKIP: /g' -e 's/ \.\.\. ok//g' -e 's/ \.\.\. ERROR//g' -e 's/ \.\.\. FAIL//g' -e 's/ \.\.\. skipped//g'
diff --git a/poky/meta/recipes-devtools/python/python3/shutil-follow-symlink-fix.patch b/poky/meta/recipes-devtools/python/python3/shutil-follow-symlink-fix.patch
deleted file mode 100644
index 802b1c7..0000000
--- a/poky/meta/recipes-devtools/python/python3/shutil-follow-symlink-fix.patch
+++ /dev/null
@@ -1,17 +0,0 @@
-shutils should consider symlinks
-
--Khem
-
-Upstream-Status: Pending
-
---- a/Lib/shutil.py	2013-01-29 12:31:06.926555779 -0800
-+++ b/Lib/shutil.py	2013-01-29 16:31:39.097554182 -0800
-@@ -132,7 +132,7 @@ def copymode(src, dst, *, follow_symlink
-     st = stat_func(src)
-     chmod_func(dst, stat.S_IMODE(st.st_mode))
- 
--if hasattr(os, 'listxattr'):
-+if hasattr(os, 'listxattr') and os.listxattr in os.supports_follow_symlinks:
-     def _copyxattr(src, dst, *, follow_symlinks=True):
-         """Copy extended filesystem attributes from `src` to `dst`.
- 
diff --git a/poky/meta/recipes-devtools/python/python3/signal.patch b/poky/meta/recipes-devtools/python/python3/signal.patch
new file mode 100644
index 0000000..534a097
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3/signal.patch
@@ -0,0 +1,56 @@
+Upstream-Status: Backport
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+From 4315389df3c4e8c1f94a18ab11a4b234762132b1 Mon Sep 17 00:00:00 2001
+From: Antoine Pitrou <pitrou@free.fr>
+Date: Mon, 23 Apr 2018 22:22:49 +0200
+Subject: [PATCH] [3.6] bpo-33329: Fix multiprocessing regression on newer
+ glibcs (GH-6575) (GH-6582)
+
+Starting with glibc 2.27.9000-xxx, sigaddset() can return EINVAL for some
+reserved signal numbers between 1 and NSIG.  The `range(1, NSIG)` idiom
+is commonly used to select all signals for blocking with `pthread_sigmask`.
+So we ignore the sigaddset() return value until we expose sigfillset()
+to provide a better idiom.
+(cherry picked from commit 25038ecfb665bef641abf8cb61afff7505b0e008)
+---
+ .../next/Library/2018-04-23-13-21-39.bpo-33329.lQ-Eod.rst  |  1 +
+ Modules/signalmodule.c                                     | 14 ++++++++------
+ 2 files changed, 9 insertions(+), 6 deletions(-)
+ create mode 100644 Misc/NEWS.d/next/Library/2018-04-23-13-21-39.bpo-33329.lQ-Eod.rst
+
+diff --git a/Modules/signalmodule.c b/Modules/signalmodule.c
+index e0d06b434d..138e74e8a9 100644
+--- a/Modules/signalmodule.c
++++ b/Modules/signalmodule.c
+@@ -744,7 +744,6 @@ iterable_to_sigset(PyObject *iterable, sigset_t *mask)
+     int result = -1;
+     PyObject *iterator, *item;
+     long signum;
+-    int err;
+ 
+     sigemptyset(mask);
+ 
+@@ -766,11 +765,14 @@ iterable_to_sigset(PyObject *iterable, sigset_t *mask)
+         Py_DECREF(item);
+         if (signum == -1 && PyErr_Occurred())
+             goto error;
+-        if (0 < signum && signum < NSIG)
+-            err = sigaddset(mask, (int)signum);
+-        else
+-            err = 1;
+-        if (err) {
++        if (0 < signum && signum < NSIG) {
++            /* bpo-33329: ignore sigaddset() return value as it can fail
++             * for some reserved signals, but we want the `range(1, NSIG)`
++             * idiom to allow selecting all valid signals.
++             */
++            (void) sigaddset(mask, (int)signum);
++        }
++        else {
+             PyErr_Format(PyExc_ValueError,
+                          "signal number %ld out of range", signum);
+             goto error;
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-devtools/python/python3_3.5.5.bb b/poky/meta/recipes-devtools/python/python3_3.5.5.bb
deleted file mode 100644
index c28be32..0000000
--- a/poky/meta/recipes-devtools/python/python3_3.5.5.bb
+++ /dev/null
@@ -1,324 +0,0 @@
-require recipes-devtools/python/python.inc
-
-DEPENDS = "python3-native libffi bzip2 gdbm openssl sqlite3 zlib virtual/libintl xz"
-
-PR = "${INC_PR}.0"
-PYTHON_MAJMIN = "3.5"
-PYTHON_BINABI= "${PYTHON_MAJMIN}m"
-DISTRO_SRC_URI ?= "file://sitecustomize.py"
-DISTRO_SRC_URI_linuxstdbase = ""
-SRC_URI = "http://www.python.org/ftp/python/${PV}/Python-${PV}.tar.xz \
-file://python-config.patch \
-file://0001-cross-compile-support.patch \
-file://030-fixup-include-dirs.patch \
-file://070-dont-clean-ipkg-install.patch \
-file://080-distutils-dont_adjust_files.patch \
-file://130-readline-setup.patch \
-file://150-fix-setupterm.patch \
-file://0001-h2py-Fix-issue-13032-where-it-fails-with-UnicodeDeco.patch \
-file://tweak-MULTIARCH-for-powerpc-linux-gnuspe.patch \
-file://support_SOURCE_DATE_EPOCH_in_py_compile.patch \
-${DISTRO_SRC_URI} \
-"
-
-SRC_URI += "\
-            file://03-fix-tkinter-detection.patch \
-            file://avoid_warning_about_tkinter.patch \
-            file://cgi_py.patch \
-            file://host_include_contamination.patch \
-            file://python-3.3-multilib.patch \
-            file://shutil-follow-symlink-fix.patch \
-            file://sysroot-include-headers.patch \
-            file://unixccompiler.patch \
-            file://avoid-ncursesw-include-path.patch \
-            file://python3-use-CROSSPYTHONPATH-for-PYTHON_FOR_BUILD.patch \
-            file://sysconfig.py-add-_PYTHON_PROJECT_SRC.patch \
-            file://setup.py-check-cross_compiling-when-get-FLAGS.patch \
-            file://configure.ac-fix-LIBPL.patch \
-            file://0001-Issue-21272-Use-_sysconfigdata.py-to-initialize-dist.patch \
-            file://pass-missing-libraries-to-Extension-for-mul.patch \
-            file://CVE-2018-1061.patch \
-           "
-SRC_URI[md5sum] = "f3763edf9824d5d3a15f5f646083b6e0"
-SRC_URI[sha256sum] = "063d2c3b0402d6191b90731e0f735c64830e7522348aeb7ed382a83165d45009"
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=b6ec515b22618f55fa07276b897bacea"
-
-# exclude pre-releases for both python 2.x and 3.x
-UPSTREAM_CHECK_REGEX = "[Pp]ython-(?P<pver>\d+(\.\d+)+).tar"
-
-S = "${WORKDIR}/Python-${PV}"
-
-inherit autotools multilib_header python3native pkgconfig
-
-CONFIGUREOPTS += " --with-system-ffi "
-
-CACHED_CONFIGUREVARS = "ac_cv_have_chflags=no \
-                ac_cv_have_lchflags=no \
-                ac_cv_have_long_long_format=yes \
-                ac_cv_buggy_getaddrinfo=no \
-                ac_cv_file__dev_ptmx=yes \
-                ac_cv_file__dev_ptc=no \
-"
-
-TARGET_CC_ARCH += "-DNDEBUG -fno-inline"
-SDK_CC_ARCH += "-DNDEBUG -fno-inline"
-EXTRA_OEMAKE += "CROSS_COMPILE=yes"
-EXTRA_OECONF += "CROSSPYTHONPATH=${STAGING_LIBDIR_NATIVE}/python${PYTHON_MAJMIN}/lib-dynload/ --without-ensurepip"
-
-export CROSS_COMPILE = "${TARGET_PREFIX}"
-export _PYTHON_PROJECT_BASE = "${B}"
-export _PYTHON_PROJECT_SRC = "${S}"
-export CCSHARED = "-fPIC"
-
-# Fix cross compilation of different modules
-export CROSSPYTHONPATH = "${STAGING_LIBDIR_NATIVE}/python${PYTHON_MAJMIN}/lib-dynload/:${B}/build/lib.linux-${TARGET_ARCH}-${PYTHON_MAJMIN}:${S}/Lib:${S}/Lib/plat-linux"
-
-# No ctypes option for python 3
-PYTHONLSBOPTS = ""
-
-PACKAGECONFIG ??= "readline"
-PACKAGECONFIG[readline] = ",,readline"
-
-do_configure_append() {
-	rm -f ${S}/Makefile.orig
-	autoreconf -Wcross --verbose --install --force --exclude=autopoint ../Python-${PV}/Modules/_ctypes/libffi
-}
-
-do_compile() {
-        # regenerate platform specific files, because they depend on system headers
-        cd ${S}/Lib/plat-linux*
-        include=${STAGING_INCDIR} ${STAGING_BINDIR_NATIVE}/python3-native/python3 \
-                ${S}/Tools/scripts/h2py.py -i '(u_long)' \
-                ${STAGING_INCDIR}/dlfcn.h \
-                ${STAGING_INCDIR}/linux/cdrom.h \
-                ${STAGING_INCDIR}/netinet/in.h \
-                ${STAGING_INCDIR}/sys/types.h
-        sed -e 's,${STAGING_DIR_HOST},,g' -i *.py
-        cd -
-
-
-	# remove any bogus LD_LIBRARY_PATH
-	sed -i -e s,RUNSHARED=.*,RUNSHARED=, Makefile
-
-	if [ ! -f Makefile.orig ]; then
-		install -m 0644 Makefile Makefile.orig
-	fi
-	sed -i -e 's,^CONFIGURE_LDFLAGS=.*,CONFIGURE_LDFLAGS=-L. -L${STAGING_LIBDIR},g' \
-		-e 's,libdir=${libdir},libdir=${STAGING_LIBDIR},g' \
-		-e 's,libexecdir=${libexecdir},libexecdir=${STAGING_DIR_HOST}${libexecdir},g' \
-		-e 's,^LIBDIR=.*,LIBDIR=${STAGING_LIBDIR},g' \
-		-e 's,includedir=${includedir},includedir=${STAGING_INCDIR},g' \
-		-e 's,^INCLUDEDIR=.*,INCLUDE=${STAGING_INCDIR},g' \
-		-e 's,^CONFINCLUDEDIR=.*,CONFINCLUDE=${STAGING_INCDIR},g' \
-		Makefile
-	# save copy of it now, because if we do it in do_install and 
-	# then call do_install twice we get Makefile.orig == Makefile.sysroot
-	install -m 0644 Makefile Makefile.sysroot
-
-	oe_runmake HOSTPGEN=${STAGING_BINDIR_NATIVE}/python3-native/pgen \
-		HOSTPYTHON=${STAGING_BINDIR_NATIVE}/python3-native/python3 \
-		STAGING_LIBDIR=${STAGING_LIBDIR} \
-		STAGING_BASELIBDIR=${STAGING_BASELIBDIR} \
-		STAGING_INCDIR=${STAGING_INCDIR} \
-		LIB=${baselib} \
-		ARCH=${TARGET_ARCH} \
-		OPT="${CFLAGS}" libpython3.so
-
-	oe_runmake HOSTPGEN=${STAGING_BINDIR_NATIVE}/python3-native/pgen \
-		HOSTPYTHON=${STAGING_BINDIR_NATIVE}/python3-native/python3 \
-		STAGING_LIBDIR=${STAGING_LIBDIR} \
-		STAGING_INCDIR=${STAGING_INCDIR} \
-		STAGING_BASELIBDIR=${STAGING_BASELIBDIR} \
-		LIB=${baselib} \
-		ARCH=${TARGET_ARCH} \
-		OPT="${CFLAGS}"
-}
-
-do_install() {
-	# make install needs the original Makefile, or otherwise the inclues would
-	# go to ${D}${STAGING...}/...
-	install -m 0644 Makefile.orig Makefile
-
-	install -d ${D}${libdir}/pkgconfig
-	install -d ${D}${libdir}/python${PYTHON_MAJMIN}/config
-
-	# rerun the build once again with original makefile this time
-	# run install in a separate step to avoid compile/install race
-	oe_runmake HOSTPGEN=${STAGING_BINDIR_NATIVE}/python3-native/pgen \
-		HOSTPYTHON=${STAGING_BINDIR_NATIVE}/python3-native/python3 \
-		STAGING_LIBDIR=${STAGING_LIBDIR} \
-		STAGING_INCDIR=${STAGING_INCDIR} \
-		STAGING_BASELIBDIR=${STAGING_BASELIBDIR} \
-		LIB=${baselib} \
-		ARCH=${TARGET_ARCH} \
-		DESTDIR=${D} LIBDIR=${libdir}
-	
-	oe_runmake HOSTPGEN=${STAGING_BINDIR_NATIVE}/python3-native/pgen \
-		HOSTPYTHON=${STAGING_BINDIR_NATIVE}/python3-native/python3 \
-		STAGING_LIBDIR=${STAGING_LIBDIR} \
-		STAGING_INCDIR=${STAGING_INCDIR} \
-		STAGING_BASELIBDIR=${STAGING_BASELIBDIR} \
-		LIB=${baselib} \
-		ARCH=${TARGET_ARCH} \
-		DESTDIR=${D} LIBDIR=${libdir} install
-
-	# avoid conflict with 2to3 from Python 2
-	rm -f ${D}/${bindir}/2to3
-
-	install -m 0644 Makefile.sysroot ${D}/${libdir}/python${PYTHON_MAJMIN}/config/Makefile
-	install -m 0644 Makefile.sysroot ${D}/${libdir}/python${PYTHON_MAJMIN}/config-${PYTHON_MAJMIN}${PYTHON_ABI}/Makefile
-
-	if [ -e ${WORKDIR}/sitecustomize.py ]; then
-		install -m 0644 ${WORKDIR}/sitecustomize.py ${D}/${libdir}/python${PYTHON_MAJMIN}
-	fi
-
-	oe_multilib_header python${PYTHON_BINABI}/pyconfig.h
-}
-
-do_install_append_class-nativesdk () {
-	create_wrapper ${D}${bindir}/python${PYTHON_MAJMIN} TERMINFO_DIRS='${sysconfdir}/terminfo:/etc/terminfo:/usr/share/terminfo:/usr/share/misc/terminfo:/lib/terminfo' PYTHONNOUSERSITE='1'
-}
-
-SSTATE_SCAN_FILES += "Makefile"
-PACKAGE_PREPROCESS_FUNCS += "py_package_preprocess"
-
-py_package_preprocess () {
-	# copy back the old Makefile to fix target package
-	install -m 0644 ${B}/Makefile.orig ${PKGD}/${libdir}/python${PYTHON_MAJMIN}/config/Makefile
-	install -m 0644 ${B}/Makefile.orig ${PKGD}/${libdir}/python${PYTHON_MAJMIN}/config-${PYTHON_MAJMIN}${PYTHON_ABI}/Makefile
-	# Remove references to buildmachine paths in target Makefile and _sysconfigdata
-	sed -i -e 's:--sysroot=${STAGING_DIR_TARGET}::g' -e s:'--with-libtool-sysroot=${STAGING_DIR_TARGET}'::g \
-		-e 's|${DEBUG_PREFIX_MAP}||g' \
-		-e 's:${HOSTTOOLS_DIR}/::g' \
-		-e 's:${RECIPE_SYSROOT_NATIVE}::g' \
-		-e 's:${RECIPE_SYSROOT}::g' \
-		-e 's:${BASE_WORKDIR}/${MULTIMACH_TARGET_SYS}::g' \
-		${PKGD}/${libdir}/python${PYTHON_MAJMIN}/config/Makefile \
-		${PKGD}/${libdir}/python${PYTHON_MAJMIN}/config-${PYTHON_MAJMIN}${PYTHON_ABI}/Makefile \
-		${PKGD}/${libdir}/python${PYTHON_MAJMIN}/_sysconfigdata.py \
-		${PKGD}/${bindir}/python${PYTHON_BINABI}-config
-
-	# Recompile _sysconfigdata after modifying it
-	cd ${PKGD}
-	${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} \
-	     -c "from py_compile import compile; compile('./${libdir}/python${PYTHON_MAJMIN}/_sysconfigdata.py')"
-	${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} \
-	     -c "from py_compile import compile; compile('./${libdir}/python${PYTHON_MAJMIN}/_sysconfigdata.py', optimize=1)"
-	${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} \
-	     -c "from py_compile import compile; compile('./${libdir}/python${PYTHON_MAJMIN}/_sysconfigdata.py', optimize=2)"
-	cd -
-}
-
-# manual dependency additions
-RPROVIDES_${PN}-modules = "${PN}"
-RRECOMMENDS_${PN}-core_append_class-nativesdk = " nativesdk-python3-modules"
-RRECOMMENDS_${PN}-crypt = "openssl"
-RRECOMMENDS_${PN}-crypt_class-nativesdk = "nativesdk-openssl"
-
-FILES_${PN}-2to3 += "${bindir}/2to3-${PYTHON_MAJMIN}"
-FILES_${PN}-pydoc += "${bindir}/pydoc${PYTHON_MAJMIN} ${bindir}/pydoc3"
-FILES_${PN}-idle += "${bindir}/idle3 ${bindir}/idle${PYTHON_MAJMIN}"
-
-PACKAGES =+ "${PN}-pyvenv"
-FILES_${PN}-pyvenv += "${bindir}/pyvenv-${PYTHON_MAJMIN} ${bindir}/pyvenv"
-
-# package libpython3
-PACKAGES =+ "libpython3 libpython3-staticdev"
-FILES_libpython3 = "${libdir}/libpython*.so.*"
-FILES_libpython3-staticdev += "${libdir}/python${PYTHON_MAJMIN}/config-${PYTHON_BINABI}/libpython${PYTHON_BINABI}.a"
-INSANE_SKIP_${PN}-dev += "dev-elf"
-
-# catch all the rest (unsorted)
-PACKAGES += "${PN}-misc"
-RDEPENDS_${PN}-misc += "${PN}-core ${PN}-email ${PN}-codecs"
-RDEPENDS_${PN}-modules += "${PN}-misc"
-FILES_${PN}-misc = "${libdir}/python${PYTHON_MAJMIN}"
-
-# catch manpage
-PACKAGES += "${PN}-man"
-FILES_${PN}-man = "${datadir}/man"
-
-BBCLASSEXTEND = "nativesdk"
-
-RPROVIDES_${PN} += "${PN}-modules"
-
-# We want bytecode precompiled .py files (.pyc's) by default
-# but the user may set it on their own conf
-INCLUDE_PYCS ?= "1"
-
-python(){
-    import json
-
-    filename = os.path.join(d.getVar('THISDIR'), 'python3', 'python3-manifest.json')
-    # This python changes the datastore based on the contents of a file, so mark
-    # that dependency.
-    bb.parse.mark_dependency(d, filename)
-
-    with open(filename) as manifest_file:
-        python_manifest=json.load(manifest_file)
-
-    include_pycs = d.getVar('INCLUDE_PYCS')
-
-    packages = d.getVar('PACKAGES').split()
-    pn = d.getVar('PN')
-
-    newpackages=[]
-    for key in python_manifest:
-        pypackage= pn + '-' + key
-
-        if pypackage not in packages:
-            # We need to prepend, otherwise python-misc gets everything
-            # so we use a new variable
-            newpackages.append(pypackage)
-
-        # "Build" python's manifest FILES, RDEPENDS and SUMMARY
-        d.setVar('FILES_' + pypackage, '')
-        for value in python_manifest[key]['files']:
-            d.appendVar('FILES_' + pypackage, ' ' + value)
-
-    	# Add cached files
-        if include_pycs == '1':
-            for value in python_manifest[key]['cached']:
-                    d.appendVar('FILES_' + pypackage, ' ' + value)
-
-        d.setVar('RDEPENDS_' + pypackage, '')
-        for value in python_manifest[key]['rdepends']:
-            # Make it work with or without $PN
-            if '${PN}' in value:
-                value=value.split('-')[1]
-            d.appendVar('RDEPENDS_' + pypackage, ' ' + pn + '-' + value)
-        d.setVar('SUMMARY_' + pypackage, python_manifest[key]['summary'])
-
-    # We need to ensure staticdev packages match for files first so we sort in reverse
-    newpackages.sort(reverse=True)
-    # Prepending so to avoid python-misc getting everything
-    packages = newpackages + packages
-    d.setVar('PACKAGES', ' '.join(packages))
-    d.setVar('ALLOW_EMPTY_${PN}-modules', '1')
-}
-
-# Files needed to create a new manifest
-SRC_URI += "file://create_manifest3.py file://get_module_deps3.py file://python3-manifest.json"
-
-do_create_manifest() {
-    # This task should be run with every new release of Python.
-    # We must ensure that PACKAGECONFIG enables everything when creating
-    # a new manifest, this is to base our new manifest on a complete
-    # native python build, containing all dependencies, otherwise the task
-    # wont be able to find the required files.
-    # e.g. BerkeleyDB is an optional build dependency so it may or may not
-    # be present, we must ensure it is.
-
-    cd ${WORKDIR}
-    # This needs to be executed by python-native and NOT by HOST's python
-    nativepython3 create_manifest3.py
-    cp python3-manifest.json.new ${THISDIR}/python3/python3-manifest.json
-}
-
-# bitbake python -c create_manifest
-addtask do_create_manifest
-
-# Make sure we have native python ready when we create a new manifest
-do_create_manifest[depends] += "python3:do_prepare_recipe_sysroot"
-do_create_manifest[depends] += "python3:do_patch"
diff --git a/poky/meta/recipes-devtools/python/python3_3.5.6.bb b/poky/meta/recipes-devtools/python/python3_3.5.6.bb
new file mode 100644
index 0000000..31f8ead
--- /dev/null
+++ b/poky/meta/recipes-devtools/python/python3_3.5.6.bb
@@ -0,0 +1,329 @@
+require recipes-devtools/python/python3.inc
+
+DEPENDS = "python3-native libffi bzip2 gdbm openssl \
+           sqlite3 zlib virtual/libintl xz qemu-native \
+           qemu-helper-native virtual/crypt"
+
+DISTRO_SRC_URI ?= "file://sitecustomize.py"
+DISTRO_SRC_URI_linuxstdbase = ""
+SRC_URI = "http://www.python.org/ftp/python/${PV}/Python-${PV}.tar.xz \
+file://python-config.patch \
+file://030-fixup-include-dirs.patch \
+file://070-dont-clean-ipkg-install.patch \
+file://080-distutils-dont_adjust_files.patch \
+file://130-readline-setup.patch \
+file://150-fix-setupterm.patch \
+file://0001-h2py-Fix-issue-13032-where-it-fails-with-UnicodeDeco.patch \
+file://tweak-MULTIARCH-for-powerpc-linux-gnuspe.patch \
+file://support_SOURCE_DATE_EPOCH_in_py_compile.patch \
+${DISTRO_SRC_URI} \
+"
+
+SRC_URI += "\
+            file://03-fix-tkinter-detection.patch \
+            file://avoid_warning_about_tkinter.patch \
+            file://cgi_py.patch \
+            file://host_include_contamination.patch \
+            file://python-3.3-multilib.patch \
+            file://sysroot-include-headers.patch \
+            file://unixccompiler.patch \
+            file://avoid-ncursesw-include-path.patch \
+            file://python3-use-CROSSPYTHONPATH-for-PYTHON_FOR_BUILD.patch \
+            file://sysconfig.py-add-_PYTHON_PROJECT_SRC.patch \
+            file://setup.py-check-cross_compiling-when-get-FLAGS.patch \
+            file://configure.ac-fix-LIBPL.patch \
+            file://0001-Issue-21272-Use-_sysconfigdata.py-to-initialize-dist.patch \
+            file://pass-missing-libraries-to-Extension-for-mul.patch \
+            file://Use-correct-CFLAGS-for-extensions-when-cross-compili.patch \
+            file://0002-Makefile-add-target-to-split-profile-generation.patch \
+            file://float-endian.patch \
+            file://ftplib.patch \
+            file://signal.patch \
+            file://0001-Issue-28043-SSLContext-has-improved-default-settings.patch \
+            file://0002-bpo-29136-Add-TLS-1.3-cipher-suites-and-OP_NO_TLSv1_.patch \
+            file://0003-bpo-32947-Fixes-for-TLS-1.3-and-OpenSSL-1.1.1-GH-876.patch \
+            file://0004-bpo-33570-TLS-1.3-ciphers-for-OpenSSL-1.1.1-GH-6976.patch \
+            file://0005-bpo-30714-ALPN-changes-for-OpenSSL-1.1.0f-2305.patch \
+            file://run-ptest \
+           "
+
+inherit multilib_header python3native update-alternatives qemu ptest
+
+MULTILIB_SUFFIX = "${@d.getVar('base_libdir',1).split('/')[-1]}"
+
+ALTERNATIVE_${PN}-dev = "python-config"
+ALTERNATIVE_LINK_NAME[python-config] = "${bindir}/python${PYTHON_BINABI}-config"
+ALTERNATIVE_TARGET[python-config] = "${bindir}/python${PYTHON_BINABI}-config-${MULTILIB_SUFFIX}"
+
+CONFIGUREOPTS += " --with-system-ffi "
+
+CACHED_CONFIGUREVARS = "ac_cv_have_chflags=no \
+                ac_cv_have_lchflags=no \
+                ac_cv_have_long_long_format=yes \
+                ac_cv_buggy_getaddrinfo=no \
+                ac_cv_file__dev_ptmx=yes \
+                ac_cv_file__dev_ptc=no \
+"
+
+TARGET_CC_ARCH += "-DNDEBUG -fno-inline"
+SDK_CC_ARCH += "-DNDEBUG -fno-inline"
+EXTRA_OEMAKE += "CROSS_COMPILE=yes"
+EXTRA_OECONF += "CROSSPYTHONPATH=${STAGING_LIBDIR_NATIVE}/python${PYTHON_MAJMIN}/lib-dynload/ --without-ensurepip"
+
+PYTHON3_PROFILE_TASK ?= "./python -m test.regrtest --pgo test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_support || true"
+
+export CROSS_COMPILE = "${TARGET_PREFIX}"
+export CCSHARED = "-fPIC"
+
+# Fix cross compilation of different modules
+export CROSSPYTHONPATH = "${STAGING_LIBDIR_NATIVE}/python${PYTHON_MAJMIN}/lib-dynload/:${B}/build/lib.linux-${TARGET_ARCH}-${PYTHON_MAJMIN}:${S}/Lib:${S}/Lib/plat-linux"
+
+PACKAGECONFIG ??= "readline ${@bb.utils.contains('MACHINE_FEATURES', 'qemu-usermode', 'pgo', '', d)}"
+PACKAGECONFIG[readline] = ",,readline"
+# Use profile guided optimisation by running PyBench inside qemu-user
+PACKAGECONFIG[pgo] = "--enable-optimizations"
+
+do_configure_append() {
+	rm -f ${S}/Makefile.orig
+}
+
+run_make() {
+	oe_runmake PGEN=${STAGING_BINDIR_NATIVE}/python3-native/pgen \
+		HOSTPYTHON=${STAGING_BINDIR_NATIVE}/python3-native/python3 \
+		STAGING_LIBDIR=${STAGING_LIBDIR} \
+		STAGING_INCDIR=${STAGING_INCDIR} \
+		STAGING_BASELIBDIR=${STAGING_BASELIBDIR} \
+		LIB=${baselib} \
+		ARCH=${TARGET_ARCH} \
+		OPT="${CFLAGS}" \
+		"$@"
+}
+
+do_compile() {
+	# regenerate platform specific files, because they depend on system headers
+	cd ${S}/Lib/plat-linux*
+	include=${STAGING_INCDIR} ${STAGING_BINDIR_NATIVE}/python3-native/python3 \
+		${S}/Tools/scripts/h2py.py -i '(u_long)' \
+		${STAGING_INCDIR}/dlfcn.h \
+		${STAGING_INCDIR}/linux/cdrom.h \
+		${STAGING_INCDIR}/netinet/in.h \
+		${STAGING_INCDIR}/sys/types.h
+	sed -e 's,${STAGING_DIR_HOST},,g' -i *.py
+	cd -
+
+	# remove any bogus LD_LIBRARY_PATH
+	sed -i -e s,RUNSHARED=.*,RUNSHARED=, Makefile
+
+	if [ ! -f Makefile.orig ]; then
+		install -m 0644 Makefile Makefile.orig
+	fi
+	sed -i -e 's,^CONFIGURE_LDFLAGS=.*,CONFIGURE_LDFLAGS=-L. -L${STAGING_LIBDIR},g' \
+		-e 's,libdir=${libdir},libdir=${STAGING_LIBDIR},g' \
+		-e 's,libexecdir=${libexecdir},libexecdir=${STAGING_DIR_HOST}${libexecdir},g' \
+		-e 's,^LIBDIR=.*,LIBDIR=${STAGING_LIBDIR},g' \
+		-e 's,includedir=${includedir},includedir=${STAGING_INCDIR},g' \
+		-e 's,^INCLUDEDIR=.*,INCLUDE=${STAGING_INCDIR},g' \
+		-e 's,^CONFINCLUDEDIR=.*,CONFINCLUDE=${STAGING_INCDIR},g' \
+		Makefile
+	# save copy of it now, because if we do it in do_install and 
+	# then call do_install twice we get Makefile.orig == Makefile.sysroot
+	install -m 0644 Makefile Makefile.sysroot
+
+	if ${@bb.utils.contains('PACKAGECONFIG', 'pgo', 'true', 'false', d)}; then
+		run_make profile-opt
+		qemu_binary="${@qemu_wrapper_cmdline(d, '${STAGING_DIR_TARGET}', ['${B}', '${STAGING_DIR_TARGET}/${base_libdir}'])}"
+		cat >pgo-wrapper <<EOF
+#!/bin/sh
+cd ${B}
+$qemu_binary "\$@"
+EOF
+		chmod +x pgo-wrapper
+		bbnote Gathering profiling data
+		./pgo-wrapper ${PYTHON3_PROFILE_TASK}
+		bbnote Profiling data gathered, rebuilding
+		run_make clean_and_use_profile
+	else
+		run_make libpython3.so
+		run_make
+	fi
+}
+
+do_install() {
+	# make install needs the original Makefile, or otherwise the inclues would
+	# go to ${D}${STAGING...}/...
+	install -m 0644 Makefile.orig Makefile
+
+	install -d ${D}${libdir}/pkgconfig
+	install -d ${D}${libdir}/python${PYTHON_MAJMIN}/config
+
+	# rerun the build once again with original makefile this time
+	# run install in a separate step to avoid compile/install race
+	if ${@bb.utils.contains('PACKAGECONFIG', 'pgo', 'true', 'false', d)}; then
+		run_make DESTDIR=${D} LIBDIR=${libdir} build_all_use_profile
+	else
+		run_make DESTDIR=${D} LIBDIR=${libdir}
+	fi
+
+	run_make DESTDIR=${D} LIBDIR=${libdir} install
+
+	# avoid conflict with 2to3 from Python 2
+	rm -f ${D}/${bindir}/2to3
+
+	install -m 0644 Makefile.sysroot ${D}/${libdir}/python${PYTHON_MAJMIN}/config/Makefile
+	install -m 0644 Makefile.sysroot ${D}/${libdir}/python${PYTHON_MAJMIN}/config-${PYTHON_MAJMIN}${PYTHON_ABI}/Makefile
+
+	if [ -e ${WORKDIR}/sitecustomize.py ]; then
+		install -m 0644 ${WORKDIR}/sitecustomize.py ${D}/${libdir}/python${PYTHON_MAJMIN}
+	fi
+
+	oe_multilib_header python${PYTHON_BINABI}/pyconfig.h
+}
+
+do_install_append_class-nativesdk () {
+	create_wrapper ${D}${bindir}/python${PYTHON_MAJMIN} PYTHONHOME='${prefix}' TERMINFO_DIRS='${sysconfdir}/terminfo:/etc/terminfo:/usr/share/terminfo:/usr/share/misc/terminfo:/lib/terminfo' PYTHONNOUSERSITE='1'
+}
+
+SSTATE_SCAN_FILES += "Makefile"
+PACKAGE_PREPROCESS_FUNCS += "py_package_preprocess"
+
+py_package_preprocess () {
+	# copy back the old Makefile to fix target package
+	install -m 0644 ${B}/Makefile.orig ${PKGD}/${libdir}/python${PYTHON_MAJMIN}/config/Makefile
+	install -m 0644 ${B}/Makefile.orig ${PKGD}/${libdir}/python${PYTHON_MAJMIN}/config-${PYTHON_MAJMIN}${PYTHON_ABI}/Makefile
+	# Remove references to buildmachine paths in target Makefile and _sysconfigdata
+	sed -i -e 's:--sysroot=${STAGING_DIR_TARGET}::g' -e s:'--with-libtool-sysroot=${STAGING_DIR_TARGET}'::g \
+		-e 's|${DEBUG_PREFIX_MAP}||g' \
+		-e 's:${HOSTTOOLS_DIR}/::g' \
+		-e 's:${RECIPE_SYSROOT_NATIVE}::g' \
+		-e 's:${RECIPE_SYSROOT}::g' \
+		-e 's:${BASE_WORKDIR}/${MULTIMACH_TARGET_SYS}::g' \
+		${PKGD}/${libdir}/python${PYTHON_MAJMIN}/config/Makefile \
+		${PKGD}/${libdir}/python${PYTHON_MAJMIN}/config-${PYTHON_MAJMIN}${PYTHON_ABI}/Makefile \
+		${PKGD}/${libdir}/python${PYTHON_MAJMIN}/_sysconfigdata.py \
+		${PKGD}/${bindir}/python${PYTHON_BINABI}-config
+
+	# Recompile _sysconfigdata after modifying it
+	cd ${PKGD}
+	${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} \
+	     -c "from py_compile import compile; compile('./${libdir}/python${PYTHON_MAJMIN}/_sysconfigdata.py')"
+	${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} \
+	     -c "from py_compile import compile; compile('./${libdir}/python${PYTHON_MAJMIN}/_sysconfigdata.py', optimize=1)"
+	${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} \
+	     -c "from py_compile import compile; compile('./${libdir}/python${PYTHON_MAJMIN}/_sysconfigdata.py', optimize=2)"
+	cd -
+
+	mv ${PKGD}/${bindir}/python${PYTHON_BINABI}-config ${PKGD}/${bindir}/python${PYTHON_BINABI}-config-${MULTILIB_SUFFIX}
+}
+
+PACKAGES_remove = "${PN}"
+
+# manual dependency additions
+RPROVIDES_${PN}-modules = "${PN}"
+RRECOMMENDS_${PN}-core_append_class-nativesdk = " nativesdk-python3-modules"
+RRECOMMENDS_${PN}-crypt = "openssl ca-certificates"
+
+FILES_${PN}-2to3 += "${bindir}/2to3-${PYTHON_MAJMIN}"
+FILES_${PN}-pydoc += "${bindir}/pydoc${PYTHON_MAJMIN} ${bindir}/pydoc3"
+FILES_${PN}-idle += "${bindir}/idle3 ${bindir}/idle${PYTHON_MAJMIN}"
+
+# provide python-pyvenv from python3-venv
+RPROVIDES_${PN}-venv += "${PN}-pyvenv"
+
+# package libpython3
+PACKAGES =+ "libpython3 libpython3-staticdev"
+FILES_libpython3 = "${libdir}/libpython*.so.*"
+FILES_libpython3-staticdev += "${libdir}/python${PYTHON_MAJMIN}/config-${PYTHON_BINABI}/libpython${PYTHON_BINABI}.a"
+INSANE_SKIP_${PN}-dev += "dev-elf"
+
+# catch all the rest (unsorted)
+PACKAGES += "${PN}-misc"
+RDEPENDS_${PN}-misc += "${PN}-core ${PN}-email ${PN}-codecs"
+RDEPENDS_${PN}-modules += "${PN}-misc"
+FILES_${PN}-misc = "${libdir}/python${PYTHON_MAJMIN}"
+
+# catch manpage
+PACKAGES += "${PN}-man"
+FILES_${PN}-man = "${datadir}/man"
+
+RDEPENDS_${PN}-ptest = "${PN}-modules ${PN}-tests unzip bzip2"
+
+RDEPENDS_${PN}-dev = ""
+
+BBCLASSEXTEND = "nativesdk"
+
+# We want bytecode precompiled .py files (.pyc's) by default
+# but the user may set it on their own conf
+INCLUDE_PYCS ?= "1"
+
+python(){
+    import collections, json
+
+    filename = os.path.join(d.getVar('THISDIR'), 'python3', 'python3-manifest.json')
+    # This python changes the datastore based on the contents of a file, so mark
+    # that dependency.
+    bb.parse.mark_dependency(d, filename)
+
+    with open(filename) as manifest_file:
+        python_manifest=json.load(manifest_file, object_pairs_hook=collections.OrderedDict)
+
+    include_pycs = d.getVar('INCLUDE_PYCS')
+
+    packages = d.getVar('PACKAGES').split()
+    pn = d.getVar('PN')
+
+    newpackages=[]
+    for key in python_manifest:
+        pypackage= pn + '-' + key
+
+        if pypackage not in packages:
+            # We need to prepend, otherwise python-misc gets everything
+            # so we use a new variable
+            newpackages.append(pypackage)
+
+        # "Build" python's manifest FILES, RDEPENDS and SUMMARY
+        d.setVar('FILES_' + pypackage, '')
+        for value in python_manifest[key]['files']:
+            d.appendVar('FILES_' + pypackage, ' ' + value)
+
+    	# Add cached files
+        if include_pycs == '1':
+            for value in python_manifest[key]['cached']:
+                    d.appendVar('FILES_' + pypackage, ' ' + value)
+
+        for value in python_manifest[key]['rdepends']:
+            # Make it work with or without $PN
+            if '${PN}' in value:
+                value=value.split('-')[1]
+            d.appendVar('RDEPENDS_' + pypackage, ' ' + pn + '-' + value)
+        d.setVar('SUMMARY_' + pypackage, python_manifest[key]['summary'])
+
+    # Prepending so to avoid python-misc getting everything
+    packages = newpackages + packages
+    d.setVar('PACKAGES', ' '.join(packages))
+    d.setVar('ALLOW_EMPTY_${PN}-modules', '1')
+}
+
+# Files needed to create a new manifest
+SRC_URI += "file://create_manifest3.py file://get_module_deps3.py file://python3-manifest.json"
+
+do_create_manifest() {
+    # This task should be run with every new release of Python.
+    # We must ensure that PACKAGECONFIG enables everything when creating
+    # a new manifest, this is to base our new manifest on a complete
+    # native python build, containing all dependencies, otherwise the task
+    # wont be able to find the required files.
+    # e.g. BerkeleyDB is an optional build dependency so it may or may not
+    # be present, we must ensure it is.
+
+    cd ${WORKDIR}
+    # This needs to be executed by python-native and NOT by HOST's python
+    nativepython3 create_manifest3.py ${PYTHON_MAJMIN}
+    cp python3-manifest.json.new ${THISDIR}/python3/python3-manifest.json
+}
+
+# bitbake python -c create_manifest
+addtask do_create_manifest
+
+# Make sure we have native python ready when we create a new manifest
+do_create_manifest[depends] += "python3:do_prepare_recipe_sysroot"
+do_create_manifest[depends] += "python3:do_patch"
diff --git a/poky/meta/recipes-devtools/python/python_2.7.15.bb b/poky/meta/recipes-devtools/python/python_2.7.15.bb
index 0b3958d..dd969d8 100644
--- a/poky/meta/recipes-devtools/python/python_2.7.15.bb
+++ b/poky/meta/recipes-devtools/python/python_2.7.15.bb
@@ -1,6 +1,7 @@
 require python.inc
 
-DEPENDS = "python-native libffi bzip2 gdbm openssl readline sqlite3 zlib"
+DEPENDS = "python-native libffi bzip2 gdbm openssl \
+           readline sqlite3 zlib virtual/crypt"
 
 PR = "${INC_PR}"
 
@@ -153,6 +154,7 @@
 	(cd ${PKGD}; python -m py_compile ./${libdir}/python${PYTHON_MAJMIN}/_sysconfigdata.py)
 }
 
+PACKAGES_remove = "${PN}"
 
 # manual dependency additions
 RPROVIDES_${PN}-core = "${PN}"
@@ -178,9 +180,9 @@
 # Nasty but if bdb isn't enabled the package won't be generated
 RDEPENDS_${PN}-modules_remove = "${@bb.utils.contains('PACKAGECONFIG', 'bdb', '', '${PN}-bsddb', d)}"
 
-BBCLASSEXTEND = "nativesdk"
+RDEPENDS_${PN}-dev = ""
 
-RPROVIDES_${PN} += "${PN}-modules"
+BBCLASSEXTEND = "nativesdk"
 
 # We want bytecode precompiled .py files (.pyc's) by default
 # but the user may set it on their own conf
@@ -221,7 +223,6 @@
                 if value.endswith('.py'):
                     d.appendVar('FILES_' + pypackage, ' ' + value + 'c')
 
-        d.setVar('RDEPENDS_' + pypackage, '')
         for value in python_manifest[key]['rdepends']:
             # Make it work with or without $PN
             if '${PN}' in value:
diff --git a/poky/meta/recipes-devtools/qemu/qemu-targets.inc b/poky/meta/recipes-devtools/qemu/qemu-targets.inc
index 66dd675..810401d 100644
--- a/poky/meta/recipes-devtools/qemu/qemu-targets.inc
+++ b/poky/meta/recipes-devtools/qemu/qemu-targets.inc
@@ -7,7 +7,7 @@
     archs = d.getVar('QEMU_TARGETS').split()
     tos = d.getVar('HOST_OS')
     softmmuonly = ""
-    for arch in ['ppcemb']:
+    for arch in ['ppcemb', 'lm32']:
         if arch in archs:
             softmmuonly += arch + "-softmmu,"
             archs.remove(arch)
diff --git a/poky/meta/recipes-devtools/qemu/qemu.inc b/poky/meta/recipes-devtools/qemu/qemu.inc
index dc73df8..b05c1ce 100644
--- a/poky/meta/recipes-devtools/qemu/qemu.inc
+++ b/poky/meta/recipes-devtools/qemu/qemu.inc
@@ -5,11 +5,11 @@
 RDEPENDS_${PN}_class-target += "bash"
 
 require qemu-targets.inc
-inherit autotools pkgconfig bluetooth
+inherit pkgconfig bluetooth
 BBCLASSEXTEND = "native nativesdk"
 
 # QEMU_TARGETS is overridable variable
-QEMU_TARGETS ?= "arm aarch64 i386 mips mipsel mips64 mips64el ppc sh4 x86_64"
+QEMU_TARGETS ?= "arm aarch64 i386 mips mipsel mips64 mips64el ppc riscv32 riscv64 sh4 x86_64"
 
 EXTRA_OECONF = " \
     --prefix=${prefix} \
@@ -27,6 +27,7 @@
     --disable-werror \
     --target-list=${@get_qemu_target_list(d)} \
     --extra-cflags='${CFLAGS}' \
+    ${PACKAGECONFIG_CONFARGS} \
     "
 EXTRA_OECONF_append_class-native = " --python=python2.7"
 
@@ -36,27 +37,23 @@
 
 export LIBTOOL="${HOST_SYS}-libtool"
 
+B = "${WORKDIR}/build"
+
 do_configure_prepend_class-native() {
 	# Append build host pkg-config paths for native target since the host may provide sdl
 	BHOST_PKGCONFIG_PATH=$(PATH=/usr/bin:/bin pkg-config --variable pc_path pkg-config || echo "")
 	if [ ! -z "$BHOST_PKGCONFIG_PATH" ]; then
 		export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:$BHOST_PKGCONFIG_PATH
 	fi
-
-	# Alter target makefiles to accept CFLAGS set via env
-	sed -i -r \
-		-e 's/^(C|OP_C|HELPER_C)FLAGS=/\1FLAGS+=/' \
-		"${S}"/Makefile "${S}"/Makefile.target
 }
 
 do_configure() {
     ${S}/configure ${EXTRA_OECONF}
-    test ! -e ${S}/target-i386/beginend_funcs.sh || chmod a+x ${S}/target-i386/beginend_funcs.sh
 }
 
 do_install () {
-	export STRIP="true"
-	autotools_do_install
+	export STRIP=""
+	oe_runmake 'DESTDIR=${D}' install
 }
 
 # The following fragment will create a wrapper for qemu-mips user emulation
@@ -74,10 +71,9 @@
 # END of qemu-mips workaround
 
 PACKAGECONFIG ??= " \
-	fdt sdl \
-	fdt sdl kvm \
-	${@bb.utils.filter('DISTRO_FEATURES', 'alsa xen', d)} \
-	"
+    fdt sdl kvm \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'alsa xen', d)} \
+"
 PACKAGECONFIG_class-native ??= "fdt alsa kvm"
 PACKAGECONFIG_class-nativesdk ??= "fdt sdl kvm"
 
@@ -88,7 +84,7 @@
 PACKAGECONFIG_remove_darwin = "kvm"
 PACKAGECONFIG_remove_mingw32 = "kvm"
 
-PACKAGECONFIG[sdl] = "--enable-sdl,--disable-sdl,libsdl"
+PACKAGECONFIG[sdl] = "--enable-sdl --with-sdlabi=2.0,--disable-sdl,libsdl2"
 PACKAGECONFIG[virtfs] = "--enable-virtfs --enable-attr,--disable-virtfs,libcap attr,"
 PACKAGECONFIG[aio] = "--enable-linux-aio,--disable-linux-aio,libaio,"
 PACKAGECONFIG[xfs] = "--enable-xfsctl,--disable-xfsctl,xfsprogs,"
@@ -115,5 +111,10 @@
 PACKAGECONFIG[bluez] = "--enable-bluez,--disable-bluez,${BLUEZ}"
 PACKAGECONFIG[libiscsi] = "--enable-libiscsi,--disable-libiscsi"
 PACKAGECONFIG[kvm] = "--enable-kvm,--disable-kvm"
+PACKAGECONFIG[virglrenderer] = "--enable-virglrenderer,--disable-virglrenderer,virglrenderer"
+# spice will be in meta-networking layer
+PACKAGECONFIG[spice] = "--enable-spice,--disable-spice,spice"
+# usbredir will be in meta-networking layer
+PACKAGECONFIG[usb-redir] = "--enable-usb-redir,--disable-usb-redir,usbredir"
 
 INSANE_SKIP_${PN} = "arch"
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0001-CVE-2018-11806-QEMU-slirp-heap-buffer-overflow.patch b/poky/meta/recipes-devtools/qemu/qemu/0001-CVE-2018-11806-QEMU-slirp-heap-buffer-overflow.patch
deleted file mode 100644
index 8622360..0000000
--- a/poky/meta/recipes-devtools/qemu/qemu/0001-CVE-2018-11806-QEMU-slirp-heap-buffer-overflow.patch
+++ /dev/null
@@ -1,69 +0,0 @@
-Upstream-Status: Backport
-
-https://lists.gnu.org/archive/html/qemu-devel/2018-06/msg01012.html
-
-From dc21a9d2951f0a2a7e63633e2b5c68c54e4edc4b Mon Sep 17 00:00:00 2001
-From: Jeremy Puhlman <jpuhlman@mvista.com>
-Date: Thu, 14 Jun 2018 01:28:49 +0000
-Subject: [PATCH] CVE-2018-11806 QEMU: slirp: heap buffer overflow
-
-Subject: [Qemu-devel] [PATCH 1/2] slirp: correct size computation while concatenating mbuf
-Date:	Tue, 5 Jun 2018 23:38:35 +0530
-From: Prasad J Pandit <address@hidden>
-
-While reassembling incoming fragmented datagrams, 'm_cat' routine
-extends the 'mbuf' buffer, if it has insufficient room. It computes
-a wrong buffer size, which leads to overwriting adjacent heap buffer
-area. Correct this size computation in m_cat.
-
-Reported-by: ZDI Disclosures <address@hidden>
-Signed-off-by: Prasad J Pandit <address@hidden>
----
- slirp/mbuf.c | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
-Signed-off-by: Jeremy Puhlman <jpuhlman@mvista.com>
----
- slirp/mbuf.c | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/slirp/mbuf.c b/slirp/mbuf.c
-index 5ff2455..7fb4501 100644
---- a/slirp/mbuf.c
-+++ b/slirp/mbuf.c
-@@ -138,7 +138,7 @@ m_cat(struct mbuf *m, struct mbuf *n)
- 	 * If there's no room, realloc
- 	 */
- 	if (M_FREEROOM(m) < n->m_len)
--		m_inc(m,m->m_size+MINCSIZE);
-+               m_inc(m, m->m_len + n->m_len);
- 
- 	memcpy(m->m_data+m->m_len, n->m_data, n->m_len);
- 	m->m_len += n->m_len;
-@@ -158,12 +158,12 @@ m_inc(struct mbuf *m, int size)
- 
-         if (m->m_flags & M_EXT) {
- 	  datasize = m->m_data - m->m_ext;
--          m->m_ext = g_realloc(m->m_ext, size);
-+          m->m_ext = g_realloc(m->m_ext, size + datasize);
- 	  m->m_data = m->m_ext + datasize;
-         } else {
- 	  char *dat;
- 	  datasize = m->m_data - m->m_dat;
--          dat = g_malloc(size);
-+          dat = g_malloc(size + datasize);
- 	  memcpy(dat, m->m_dat, m->m_size);
- 
- 	  m->m_ext = dat;
-@@ -171,7 +171,7 @@ m_inc(struct mbuf *m, int size)
- 	  m->m_flags |= M_EXT;
-         }
- 
--        m->m_size = size;
-+        m->m_size = size + datasize;
- 
- }
- 
--- 
-2.13.3
-
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0001-sdl.c-allow-user-to-disable-pointer-grabs.patch b/poky/meta/recipes-devtools/qemu/qemu/0001-sdl.c-allow-user-to-disable-pointer-grabs.patch
index add5d8b..b8a9206 100644
--- a/poky/meta/recipes-devtools/qemu/qemu/0001-sdl.c-allow-user-to-disable-pointer-grabs.patch
+++ b/poky/meta/recipes-devtools/qemu/qemu/0001-sdl.c-allow-user-to-disable-pointer-grabs.patch
@@ -1,4 +1,4 @@
-From 273e1af49d3e0a58bb9464369deb2652f243e649 Mon Sep 17 00:00:00 2001
+From 18fb45c34a473c4ba247bb82bcea94b7c3ba493a Mon Sep 17 00:00:00 2001
 From: Ross Burton <ross.burton@intel.com>
 Date: Wed, 18 Sep 2013 14:04:54 +0100
 Subject: [PATCH] sdl.c: allow user to disable pointer grabs
@@ -22,25 +22,26 @@
 Signed-off-by: Ross Burton <ross.burton@intel.com>
 Signed-off-by: Eric Bénard <eric@eukrea.com>
 ---
- ui/sdl.c | 12 ++++++++++--
- 1 file changed, 10 insertions(+), 2 deletions(-)
+ ui/sdl.c | 13 +++++++++++--
+ 1 file changed, 11 insertions(+), 2 deletions(-)
 
 diff --git a/ui/sdl.c b/ui/sdl.c
-index 7b71a9a..29ce1b9 100644
+index a5fd503c25..ab8d1b1eb1 100644
 --- a/ui/sdl.c
 +++ b/ui/sdl.c
-@@ -63,6 +63,10 @@ static SDL_PixelFormat host_format;
- static int scaling_active = 0;
- static Notifier mouse_mode_notifier;
- static int idle_counter;
+@@ -68,6 +68,11 @@ static int idle_counter;
+ static const guint16 *keycode_map;
+ static size_t keycode_maplen;
+ 
 +#ifndef True
 +#define True 1
 +#endif
 +static doing_grabs = True;
- 
++
  #define SDL_REFRESH_INTERVAL_BUSY 10
  #define SDL_MAX_IDLE_COUNT (2 * GUI_REFRESH_INTERVAL_DEFAULT \
-@@ -431,14 +435,16 @@ static void sdl_grab_start(void)
+                             / SDL_REFRESH_INTERVAL_BUSY + 1)
+@@ -398,14 +403,16 @@ static void sdl_grab_start(void)
          }
      } else
          sdl_hide_cursor();
@@ -59,7 +60,7 @@
      gui_grab = 0;
      sdl_show_cursor();
      sdl_update_caption();
-@@ -986,6 +992,8 @@ void sdl_display_init(DisplayState *ds, int full_screen, int no_frame)
+@@ -945,6 +952,8 @@ static void sdl1_display_init(DisplayState *ds, DisplayOptions *o)
       * This requires SDL >= 1.2.14. */
      setenv("SDL_DISABLE_LOCK_KEYS", "1", 1);
  
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0002-qemu-Add-missing-wacom-HID-descriptor.patch b/poky/meta/recipes-devtools/qemu/qemu/0002-qemu-Add-missing-wacom-HID-descriptor.patch
index 281803e..90e4b80 100644
--- a/poky/meta/recipes-devtools/qemu/qemu/0002-qemu-Add-missing-wacom-HID-descriptor.patch
+++ b/poky/meta/recipes-devtools/qemu/qemu/0002-qemu-Add-missing-wacom-HID-descriptor.patch
@@ -1,4 +1,4 @@
-From a42726e017605ed3ca2b3fc2b1cc8d01ccf34730 Mon Sep 17 00:00:00 2001
+From 41603f745caaecdc7c9d760fb7d2df01ccc60128 Mon Sep 17 00:00:00 2001
 From: Richard Purdie <richard.purdie@linuxfoundation.org>
 Date: Thu, 27 Nov 2014 14:04:29 +0000
 Subject: [PATCH] qemu: Add missing wacom HID descriptor
@@ -14,11 +14,11 @@
 Upstream-Status: Submitted
 2014/11/27
 ---
- hw/usb/dev-wacom.c | 94 +++++++++++++++++++++++++++++++++++++++++++++++++++++-
+ hw/usb/dev-wacom.c | 94 +++++++++++++++++++++++++++++++++++++++++++++-
  1 file changed, 93 insertions(+), 1 deletion(-)
 
 diff --git a/hw/usb/dev-wacom.c b/hw/usb/dev-wacom.c
-index bf70013..2f6e129 100644
+index bf70013059..2f6e129732 100644
 --- a/hw/usb/dev-wacom.c
 +++ b/hw/usb/dev-wacom.c
 @@ -72,6 +72,89 @@ static const USBDescStrings desc_strings = {
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0003-Add-subpackage-ptest-which-runs-all-unit-test-cases-.patch b/poky/meta/recipes-devtools/qemu/qemu/0003-Add-subpackage-ptest-which-runs-all-unit-test-cases-.patch
index dc07300..0d43271 100644
--- a/poky/meta/recipes-devtools/qemu/qemu/0003-Add-subpackage-ptest-which-runs-all-unit-test-cases-.patch
+++ b/poky/meta/recipes-devtools/qemu/qemu/0003-Add-subpackage-ptest-which-runs-all-unit-test-cases-.patch
@@ -1,4 +1,4 @@
-From fda1eee8bc717528d57f6ff454f72c5325043c31 Mon Sep 17 00:00:00 2001
+From a9a669448ba6f1b295427e271d99f61736fc5189 Mon Sep 17 00:00:00 2001
 From: Juro Bystricky <juro.bystricky@intel.com>
 Date: Thu, 31 Aug 2017 11:06:56 -0700
 Subject: [PATCH] Add subpackage -ptest which runs all unit test cases for
@@ -14,10 +14,10 @@
  1 file changed, 8 insertions(+)
 
 diff --git a/tests/Makefile.include b/tests/Makefile.include
-index c002352..f557c26 100644
+index 3b9a5e31a2..dfbcd728d7 100644
 --- a/tests/Makefile.include
 +++ b/tests/Makefile.include
-@@ -935,4 +935,12 @@ all: $(QEMU_IOTESTS_HELPERS-y)
+@@ -972,4 +972,12 @@ all: $(QEMU_IOTESTS_HELPERS-y)
  -include $(wildcard tests/*.d)
  -include $(wildcard tests/libqos/*.d)
  
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0004-qemu-Add-addition-environment-space-to-boot-loader-q.patch b/poky/meta/recipes-devtools/qemu/qemu/0004-qemu-Add-addition-environment-space-to-boot-loader-q.patch
index 4f28e16..5152dca 100644
--- a/poky/meta/recipes-devtools/qemu/qemu/0004-qemu-Add-addition-environment-space-to-boot-loader-q.patch
+++ b/poky/meta/recipes-devtools/qemu/qemu/0004-qemu-Add-addition-environment-space-to-boot-loader-q.patch
@@ -1,4 +1,4 @@
-From ad70fdcaf75084da2e02474c61d1d441ca100ab2 Mon Sep 17 00:00:00 2001
+From dd4404a334a545e9beafa1b1e41b3a8f35ef31a9 Mon Sep 17 00:00:00 2001
 From: Jason Wessel <jason.wessel@windriver.com>
 Date: Fri, 28 Mar 2014 17:42:43 +0800
 Subject: [PATCH] qemu: Add addition environment space to boot loader
@@ -18,10 +18,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/hw/mips/mips_malta.c b/hw/mips/mips_malta.c
-index ec6af4a..6e76166 100644
+index f6513a4fd5..d5efafb1e8 100644
 --- a/hw/mips/mips_malta.c
 +++ b/hw/mips/mips_malta.c
-@@ -61,7 +61,7 @@
+@@ -62,7 +62,7 @@
  
  #define ENVP_ADDR		0x80002000l
  #define ENVP_NB_ENTRIES	 	16
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0005-qemu-disable-Valgrind.patch b/poky/meta/recipes-devtools/qemu/qemu/0005-qemu-disable-Valgrind.patch
index b9e0183..70baf0f 100644
--- a/poky/meta/recipes-devtools/qemu/qemu/0005-qemu-disable-Valgrind.patch
+++ b/poky/meta/recipes-devtools/qemu/qemu/0005-qemu-disable-Valgrind.patch
@@ -1,4 +1,4 @@
-From e85ee3cc9988172662d6969af01f23fa8ffd5262 Mon Sep 17 00:00:00 2001
+From 4475b3d97371e588540333988a97d7df3ec2c65a Mon Sep 17 00:00:00 2001
 From: Ross Burton <ross.burton@intel.com>
 Date: Tue, 20 Oct 2015 22:19:08 +0100
 Subject: [PATCH] qemu: disable Valgrind
@@ -12,10 +12,10 @@
  1 file changed, 9 deletions(-)
 
 diff --git a/configure b/configure
-index 0c6e757..c30fd45 100755
+index 0a19b033bc..69e05fb6c0 100755
 --- a/configure
 +++ b/configure
-@@ -4741,15 +4741,6 @@ fi
+@@ -4895,15 +4895,6 @@ fi
  # check if we have valgrind/valgrind.h
  
  valgrind_h=no
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0006-qemu-Limit-paths-searched-during-user-mode-emulation.patch b/poky/meta/recipes-devtools/qemu/qemu/0006-qemu-Limit-paths-searched-during-user-mode-emulation.patch
index 9315f85..a9d798c 100644
--- a/poky/meta/recipes-devtools/qemu/qemu/0006-qemu-Limit-paths-searched-during-user-mode-emulation.patch
+++ b/poky/meta/recipes-devtools/qemu/qemu/0006-qemu-Limit-paths-searched-during-user-mode-emulation.patch
@@ -1,4 +1,4 @@
-From c79c48a79710d0e2ef68062435596ac455cd9f71 Mon Sep 17 00:00:00 2001
+From c532bcdae8259b0f71723cda331ded4dbb0fa908 Mon Sep 17 00:00:00 2001
 From: Richard Purdie <richard.purdie@linuxfoundation.org>
 Date: Wed, 9 Mar 2016 22:49:02 +0000
 Subject: [PATCH] qemu: Limit paths searched during user mode emulation
@@ -24,7 +24,7 @@
  1 file changed, 22 insertions(+), 22 deletions(-)
 
 diff --git a/util/path.c b/util/path.c
-index 7f9fc27..a416cd4 100644
+index 7f9fc272fb..a416cd4ac2 100644
 --- a/util/path.c
 +++ b/util/path.c
 @@ -15,6 +15,7 @@ struct pathelem
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0007-qemu-native-set-ld.bfd-fix-cflags-and-set-some-envir.patch b/poky/meta/recipes-devtools/qemu/qemu/0007-qemu-native-set-ld.bfd-fix-cflags-and-set-some-envir.patch
index ad52f37..12456bb 100644
--- a/poky/meta/recipes-devtools/qemu/qemu/0007-qemu-native-set-ld.bfd-fix-cflags-and-set-some-envir.patch
+++ b/poky/meta/recipes-devtools/qemu/qemu/0007-qemu-native-set-ld.bfd-fix-cflags-and-set-some-envir.patch
@@ -1,4 +1,4 @@
-From 4b21a8db60c32f93df56e6111bb926c91680d6f2 Mon Sep 17 00:00:00 2001
+From 2d29d52b6f755758cfca6af0bcfd78091e16a7bc Mon Sep 17 00:00:00 2001
 From: Stephen Arnold <sarnold@vctlabs.com>
 Date: Sun, 12 Jun 2016 18:09:56 -0700
 Subject: [PATCH] qemu-native: set ld.bfd, fix cflags, and set some environment
@@ -9,10 +9,10 @@
  1 file changed, 4 deletions(-)
 
 diff --git a/configure b/configure
-index c30fd45..b5312f4 100755
+index 69e05fb6c0..12fc3d8bdc 100755
 --- a/configure
 +++ b/configure
-@@ -5115,10 +5115,6 @@ fi
+@@ -5413,10 +5413,6 @@ write_c_skeleton
  if test "$gcov" = "yes" ; then
    CFLAGS="-fprofile-arcs -ftest-coverage -g $CFLAGS"
    LDFLAGS="-fprofile-arcs -ftest-coverage $LDFLAGS"
@@ -22,4 +22,4 @@
 -  CFLAGS="-O2 $CFLAGS"
  fi
  
- ##########################################
+ if test "$have_asan" = "yes"; then
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0008-chardev-connect-socket-to-a-spawned-command.patch b/poky/meta/recipes-devtools/qemu/qemu/0008-chardev-connect-socket-to-a-spawned-command.patch
index f0c0fa1..2afe4e9 100644
--- a/poky/meta/recipes-devtools/qemu/qemu/0008-chardev-connect-socket-to-a-spawned-command.patch
+++ b/poky/meta/recipes-devtools/qemu/qemu/0008-chardev-connect-socket-to-a-spawned-command.patch
@@ -1,4 +1,4 @@
-From 55c9510311b7481a0c8f3f71b3ce130cc25563f9 Mon Sep 17 00:00:00 2001
+From 20a09bb18907e67565c54fc505a741cbbef53f7f Mon Sep 17 00:00:00 2001
 From: Alistair Francis <alistair.francis@xilinx.com>
 Date: Thu, 21 Dec 2017 11:35:16 -0800
 Subject: [PATCH] chardev: connect socket to a spawned command
@@ -45,16 +45,16 @@
 
 Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
 ---
- chardev/char-socket.c | 99 +++++++++++++++++++++++++++++++++++++++++++++++++++
- chardev/char.c        |  3 ++
- qapi/char.json        |  5 +++
- 3 files changed, 107 insertions(+)
+ chardev/char-socket.c | 102 ++++++++++++++++++++++++++++++++++++++++++
+ chardev/char.c        |   3 ++
+ qapi/char.json        |   5 +++
+ 3 files changed, 110 insertions(+)
 
 diff --git a/chardev/char-socket.c b/chardev/char-socket.c
-index 53eda8e..6c63555 100644
+index 159e69c3b1..84778cf31a 100644
 --- a/chardev/char-socket.c
 +++ b/chardev/char-socket.c
-@@ -852,6 +852,68 @@ static gboolean socket_reconnect_timeout(gpointer opaque)
+@@ -934,6 +934,68 @@ static gboolean socket_reconnect_timeout(gpointer opaque)
      return false;
  }
  
@@ -123,7 +123,7 @@
  static void qmp_chardev_open_socket(Chardev *chr,
                                      ChardevBackend *backend,
                                      bool *be_opened,
-@@ -859,6 +921,9 @@ static void qmp_chardev_open_socket(Chardev *chr,
+@@ -941,6 +1003,9 @@ static void qmp_chardev_open_socket(Chardev *chr,
  {
      SocketChardev *s = SOCKET_CHARDEV(chr);
      ChardevSocket *sock = backend->u.socket.data;
@@ -133,24 +133,24 @@
      bool do_nodelay     = sock->has_nodelay ? sock->nodelay : false;
      bool is_listen      = sock->has_server  ? sock->server  : true;
      bool is_telnet      = sock->has_telnet  ? sock->telnet  : false;
-@@ -925,7 +990,14 @@ static void qmp_chardev_open_socket(Chardev *chr,
-     } else if (reconnect > 0) {
+@@ -1008,6 +1073,14 @@ static void qmp_chardev_open_socket(Chardev *chr,
          s->reconnect_time = reconnect;
      }
+ 
 +#ifndef _WIN32
 +    if (cmd) {
 +        chardev_open_socket_cmd(chr, cmd, errp);
- 
++
 +        /* everything ready (or failed permanently) before we return */
 +        *be_opened = true;
 +    } else
 +#endif
-     if (s->reconnect_time) {
-         sioc = qio_channel_socket_new();
-         tcp_chr_set_client_ioc_name(chr, sioc);
-@@ -985,10 +1057,26 @@ static void qemu_chr_parse_socket(QemuOpts *opts, ChardevBackend *backend,
-     const char *host = qemu_opt_get(opts, "host");
+     /* If reconnect_time is set, will do that in chr_machine_done. */
+     if (!s->reconnect_time) {
+         if (s->is_listen) {
+@@ -1065,9 +1138,26 @@ static void qemu_chr_parse_socket(QemuOpts *opts, ChardevBackend *backend,
      const char *port = qemu_opt_get(opts, "port");
+     const char *fd = qemu_opt_get(opts, "fd");
      const char *tls_creds = qemu_opt_get(opts, "tls-creds");
 +#ifndef _WIN32
 +    const char *cmd = qemu_opt_get(opts, "cmd");
@@ -158,7 +158,6 @@
      SocketAddressLegacy *addr;
      ChardevSocket *sock;
  
-     backend->type = CHARDEV_BACKEND_KIND_SOCKET;
 +#ifndef _WIN32
 +    if (cmd) {
 +        /*
@@ -172,17 +171,18 @@
 +        }
 +    } else
 +#endif
-     if (!path) {
-         if (!host) {
-             error_setg(errp, "chardev: socket: no host given");
-@@ -1021,13 +1109,24 @@ static void qemu_chr_parse_socket(QemuOpts *opts, ChardevBackend *backend,
-     sock->has_reconnect = true;
++
+     if ((!!path + !!fd + !!host) != 1) {
+         error_setg(errp,
+                    "Exactly one of 'path', 'fd' or 'host' required");
+@@ -1112,12 +1202,24 @@ static void qemu_chr_parse_socket(QemuOpts *opts, ChardevBackend *backend,
      sock->reconnect = reconnect;
      sock->tls_creds = g_strdup(tls_creds);
+ 
 +#ifndef _WIN32
 +    sock->cmd = g_strdup(cmd);
 +#endif
- 
++ 
      addr = g_new0(SocketAddressLegacy, 1);
 +#ifndef _WIN32
 +    if (path || cmd) {
@@ -197,25 +197,25 @@
 +#else
          q_unix->path = g_strdup(path);
 +#endif
-     } else {
+     } else if (host) {
          addr->type = SOCKET_ADDRESS_LEGACY_KIND_INET;
          addr->u.inet.data = g_new(InetSocketAddress, 1);
 diff --git a/chardev/char.c b/chardev/char.c
-index 2ae4f46..5d52cd5 100644
+index 76d866e6fe..9747d51d7c 100644
 --- a/chardev/char.c
 +++ b/chardev/char.c
-@@ -793,6 +793,9 @@ QemuOptsList qemu_chardev_opts = {
+@@ -792,6 +792,9 @@ QemuOptsList qemu_chardev_opts = {
+         },{
              .name = "path",
              .type = QEMU_OPT_STRING,
-         },{
++        },{
 +            .name = "cmd",
 +            .type = QEMU_OPT_STRING,
-+        },{
+         },{
              .name = "host",
              .type = QEMU_OPT_STRING,
-         },{
 diff --git a/qapi/char.json b/qapi/char.json
-index ae19dcd..6de0f29 100644
+index ae19dcd1ed..6de0f29bcd 100644
 --- a/qapi/char.json
 +++ b/qapi/char.json
 @@ -241,6 +241,10 @@
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0009-apic-fixup-fallthrough-to-PIC.patch b/poky/meta/recipes-devtools/qemu/qemu/0009-apic-fixup-fallthrough-to-PIC.patch
index 915bfda..5969d93 100644
--- a/poky/meta/recipes-devtools/qemu/qemu/0009-apic-fixup-fallthrough-to-PIC.patch
+++ b/poky/meta/recipes-devtools/qemu/qemu/0009-apic-fixup-fallthrough-to-PIC.patch
@@ -1,4 +1,4 @@
-From 945f428016f278fa8e38bc8d153397c3195f85a5 Mon Sep 17 00:00:00 2001
+From 5046c21efdbc7413cddd5c5dbd9e1d53258d3e8c Mon Sep 17 00:00:00 2001
 From: Mark Asselstine <mark.asselstine@windriver.com>
 Date: Tue, 26 Feb 2013 11:43:28 -0500
 Subject: [PATCH] apic: fixup fallthrough to PIC
@@ -29,10 +29,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/hw/intc/apic.c b/hw/intc/apic.c
-index fe15fb6..8352c39 100644
+index 6fda52b86c..cd7291962d 100644
 --- a/hw/intc/apic.c
 +++ b/hw/intc/apic.c
-@@ -591,7 +591,7 @@ int apic_accept_pic_intr(DeviceState *dev)
+@@ -603,7 +603,7 @@ int apic_accept_pic_intr(DeviceState *dev)
      APICCommonState *s = APIC(dev);
      uint32_t lvt0;
  
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0010-linux-user-Fix-webkitgtk-hangs-on-32-bit-x86-target.patch b/poky/meta/recipes-devtools/qemu/qemu/0010-linux-user-Fix-webkitgtk-hangs-on-32-bit-x86-target.patch
index ceb3980..e110f63 100644
--- a/poky/meta/recipes-devtools/qemu/qemu/0010-linux-user-Fix-webkitgtk-hangs-on-32-bit-x86-target.patch
+++ b/poky/meta/recipes-devtools/qemu/qemu/0010-linux-user-Fix-webkitgtk-hangs-on-32-bit-x86-target.patch
@@ -1,4 +1,4 @@
-From 4333b2b269d997a719e19f00d044105e17700be2 Mon Sep 17 00:00:00 2001
+From 3cd92c7a885e4997ef6843313298c1d748d6ca39 Mon Sep 17 00:00:00 2001
 From: Alistair Francis <alistair.francis@xilinx.com>
 Date: Wed, 17 Jan 2018 10:51:49 -0800
 Subject: [PATCH] linux-user: Fix webkitgtk hangs on 32-bit x86 target
@@ -18,10 +18,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/linux-user/main.c b/linux-user/main.c
-index 146ee3e..1332b5c 100644
+index 8907a84114..ea42c43610 100644
 --- a/linux-user/main.c
 +++ b/linux-user/main.c
-@@ -78,7 +78,7 @@ do {                                                                    \
+@@ -79,7 +79,7 @@ do {                                                                    \
        (TARGET_LONG_BITS == 32 || defined(TARGET_ABI32))
  /* There are a number of places where we assign reserved_va to a variable
     of type abi_ulong and expect it to fit.  Avoid the last page.  */
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0011-Revert-linux-user-fix-mmap-munmap-mprotect-mremap-sh.patch b/poky/meta/recipes-devtools/qemu/qemu/0011-Revert-linux-user-fix-mmap-munmap-mprotect-mremap-sh.patch
new file mode 100644
index 0000000..41626eb
--- /dev/null
+++ b/poky/meta/recipes-devtools/qemu/qemu/0011-Revert-linux-user-fix-mmap-munmap-mprotect-mremap-sh.patch
@@ -0,0 +1,141 @@
+From 3ed26be2091436296933ed2146f7269c791c7bfe Mon Sep 17 00:00:00 2001
+From: Martin Jansa <martin.jansa@lge.com>
+Date: Fri, 1 Jun 2018 08:41:07 +0000
+Subject: [PATCH] Revert "linux-user: fix mmap/munmap/mprotect/mremap/shmat"
+
+Causes qemu-i386 to hang during gobject-introspection in webkitgtk build
+when musl is used on qemux86 - the same issue as
+0010-linux-user-Fix-webkitgtk-hangs-on-32-bit-x86-target.patch
+was fixing in 2.11.0 release, but with this patch the fix no longer worked
+as discussed here:
+http://lists.openembedded.org/pipermail/openembedded-core/2018-May/150302.html
+http://lists.openembedded.org/pipermail/openembedded-core/2018-June/151382.html
+
+This reverts commit ebf9a3630c911d0cfc9c20f7cafe9ba4f88cf583.
+
+Upstream-Status: Pending
+---
+ include/exec/cpu-all.h  |  6 +-----
+ include/exec/cpu_ldst.h | 16 +++++++++-------
+ linux-user/mmap.c       | 17 ++++-------------
+ linux-user/syscall.c    |  5 +----
+ 4 files changed, 15 insertions(+), 29 deletions(-)
+
+diff --git a/include/exec/cpu-all.h b/include/exec/cpu-all.h
+index f4fa94e966..0b141683f0 100644
+--- a/include/exec/cpu-all.h
++++ b/include/exec/cpu-all.h
+@@ -159,12 +159,8 @@ extern unsigned long guest_base;
+ extern int have_guest_base;
+ extern unsigned long reserved_va;
+ 
+-#if HOST_LONG_BITS <= TARGET_VIRT_ADDR_SPACE_BITS
+-#define GUEST_ADDR_MAX (~0ul)
+-#else
+-#define GUEST_ADDR_MAX (reserved_va ? reserved_va - 1 : \
++#define GUEST_ADDR_MAX (reserved_va ? reserved_va : \
+                                     (1ul << TARGET_VIRT_ADDR_SPACE_BITS) - 1)
+-#endif
+ #else
+ 
+ #include "exec/hwaddr.h"
+diff --git a/include/exec/cpu_ldst.h b/include/exec/cpu_ldst.h
+index 5de8c8a5af..191f2e962a 100644
+--- a/include/exec/cpu_ldst.h
++++ b/include/exec/cpu_ldst.h
+@@ -51,13 +51,15 @@
+ /* All direct uses of g2h and h2g need to go away for usermode softmmu.  */
+ #define g2h(x) ((void *)((unsigned long)(target_ulong)(x) + guest_base))
+ 
+-#define guest_addr_valid(x) ((x) <= GUEST_ADDR_MAX)
+-#define h2g_valid(x) guest_addr_valid((unsigned long)(x) - guest_base)
+-
+-static inline int guest_range_valid(unsigned long start, unsigned long len)
+-{
+-    return len - 1 <= GUEST_ADDR_MAX && start <= GUEST_ADDR_MAX - len + 1;
+-}
++#if HOST_LONG_BITS <= TARGET_VIRT_ADDR_SPACE_BITS
++#define h2g_valid(x) 1
++#else
++#define h2g_valid(x) ({ \
++    unsigned long __guest = (unsigned long)(x) - guest_base; \
++    (__guest < (1ul << TARGET_VIRT_ADDR_SPACE_BITS)) && \
++    (!reserved_va || (__guest < reserved_va)); \
++})
++#endif
+ 
+ #define h2g_nocheck(x) ({ \
+     unsigned long __ret = (unsigned long)(x) - guest_base; \
+diff --git a/linux-user/mmap.c b/linux-user/mmap.c
+index 9168a2051c..de85669aab 100644
+--- a/linux-user/mmap.c
++++ b/linux-user/mmap.c
+@@ -80,7 +80,7 @@ int target_mprotect(abi_ulong start, abi_ulong len, int prot)
+         return -TARGET_EINVAL;
+     len = TARGET_PAGE_ALIGN(len);
+     end = start + len;
+-    if (!guest_range_valid(start, len)) {
++    if (end < start) {
+         return -TARGET_ENOMEM;
+     }
+     prot &= PROT_READ | PROT_WRITE | PROT_EXEC;
+@@ -482,8 +482,8 @@ abi_long target_mmap(abi_ulong start, abi_ulong len, int prot,
+ 	 * It can fail only on 64-bit host with 32-bit target.
+ 	 * On any other target/host host mmap() handles this error correctly.
+ 	 */
+-        if (!guest_range_valid(start, len)) {
+-            errno = ENOMEM;
++        if ((unsigned long)start + len - 1 > (abi_ulong) -1) {
++            errno = EINVAL;
+             goto fail;
+         }
+ 
+@@ -623,10 +623,8 @@ int target_munmap(abi_ulong start, abi_ulong len)
+     if (start & ~TARGET_PAGE_MASK)
+         return -TARGET_EINVAL;
+     len = TARGET_PAGE_ALIGN(len);
+-    if (len == 0 || !guest_range_valid(start, len)) {
++    if (len == 0)
+         return -TARGET_EINVAL;
+-    }
+-
+     mmap_lock();
+     end = start + len;
+     real_start = start & qemu_host_page_mask;
+@@ -681,13 +679,6 @@ abi_long target_mremap(abi_ulong old_addr, abi_ulong old_size,
+     int prot;
+     void *host_addr;
+ 
+-    if (!guest_range_valid(old_addr, old_size) ||
+-        ((flags & MREMAP_FIXED) &&
+-         !guest_range_valid(new_addr, new_size))) {
+-        errno = ENOMEM;
+-        return -1;
+-    }
+-
+     mmap_lock();
+ 
+     if (flags & MREMAP_FIXED) {
+diff --git a/linux-user/syscall.c b/linux-user/syscall.c
+index 643b8833de..271f215147 100644
+--- a/linux-user/syscall.c
++++ b/linux-user/syscall.c
+@@ -4919,9 +4919,6 @@ static inline abi_ulong do_shmat(CPUArchState *cpu_env,
+             return -TARGET_EINVAL;
+         }
+     }
+-    if (!guest_range_valid(shmaddr, shm_info.shm_segsz)) {
+-        return -TARGET_EINVAL;
+-    }
+ 
+     mmap_lock();
+ 
+@@ -7497,7 +7494,7 @@ static int open_self_maps(void *cpu_env, int fd)
+         }
+         if (h2g_valid(min)) {
+             int flags = page_get_flags(h2g(min));
+-            max = h2g_valid(max - 1) ? max : (uintptr_t)g2h(GUEST_ADDR_MAX) + 1;
++            max = h2g_valid(max - 1) ? max : (uintptr_t)g2h(GUEST_ADDR_MAX);
+             if (page_check_range(h2g(min), max - min, flags) == -1) {
+                 continue;
+             }
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0011-memfd-fix-configure-test.patch b/poky/meta/recipes-devtools/qemu/qemu/0011-memfd-fix-configure-test.patch
deleted file mode 100644
index 880cb98..0000000
--- a/poky/meta/recipes-devtools/qemu/qemu/0011-memfd-fix-configure-test.patch
+++ /dev/null
@@ -1,54 +0,0 @@
-From 0c8af3f651a125d636a71d93bafd35ff5240431a Mon Sep 17 00:00:00 2001
-From: Paolo Bonzini <pbonzini@redhat.com>
-Date: Tue, 28 Nov 2017 11:51:27 +0100
-Subject: [PATCH] memfd: fix configure test
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Recent glibc added memfd_create in sys/mman.h.  This conflicts with
-the definition in util/memfd.c:
-
-    /builddir/build/BUILD/qemu-2.11.0-rc1/util/memfd.c:40:12: error: static declaration of memfd_create follows non-static declaration
-
-Fix the configure test, and remove the sys/memfd.h inclusion since the
-file actually does not exist---it is a typo in the memfd_create(2) man
-page.
-
-Cc: Marc-André Lureau <marcandre.lureau@redhat.com>
-Upstream-Status: Backport
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
----
- configure    | 2 +-
- util/memfd.c | 4 +---
- 2 files changed, 2 insertions(+), 4 deletions(-)
-
-diff --git a/configure b/configure
-index b5312f4..ec12f36 100755
---- a/configure
-+++ b/configure
-@@ -3920,7 +3920,7 @@ fi
- # check if memfd is supported
- memfd=no
- cat > $TMPC << EOF
--#include <sys/memfd.h>
-+#include <sys/mman.h>
- 
- int main(void)
- {
-diff --git a/util/memfd.c b/util/memfd.c
-index 4571d1a..412e94a 100644
---- a/util/memfd.c
-+++ b/util/memfd.c
-@@ -31,9 +31,7 @@
- 
- #include "qemu/memfd.h"
- 
--#ifdef CONFIG_MEMFD
--#include <sys/memfd.h>
--#elif defined CONFIG_LINUX
-+#if defined CONFIG_LINUX && !defined CONFIG_MEMFD
- #include <sys/syscall.h>
- #include <asm/unistd.h>
- 
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0012-arm-translate-a64-treat-DISAS_UPDATE-as-variant-of-D.patch b/poky/meta/recipes-devtools/qemu/qemu/0012-arm-translate-a64-treat-DISAS_UPDATE-as-variant-of-D.patch
deleted file mode 100644
index be92502..0000000
--- a/poky/meta/recipes-devtools/qemu/qemu/0012-arm-translate-a64-treat-DISAS_UPDATE-as-variant-of-D.patch
+++ /dev/null
@@ -1,64 +0,0 @@
-From 7354b9b24c36ee712bb6e881d39504bf1b6a4c8b Mon Sep 17 00:00:00 2001
-From: Victor Kamensky <kamensky@cisco.com>
-Date: Fri, 23 Mar 2018 18:26:45 +0000
-Subject: [PATCH] arm/translate-a64: treat DISAS_UPDATE as variant of
- DISAS_EXIT
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-In OE project 4.15 linux kernel boot hang was observed under
-single cpu aarch64 qemu. Kernel code was in a loop waiting for
-vtimer arrival, spinning in TC generated blocks, while interrupt
-was pending unprocessed. This happened because when qemu tried to
-handle vtimer interrupt target had interrupts disabled, as
-result flag indicating TCG exit, cpu->icount_decr.u16.high,
-was cleared but arm_cpu_exec_interrupt function did not call
-arm_cpu_do_interrupt to process interrupt. Later when target
-reenabled interrupts, it happened without exit into main loop, so
-following code that waited for result of interrupt execution
-run in infinite loop.
-
-To solve the problem instructions that operate on CPU sys state
-(i.e enable/disable interrupt), and marked as DISAS_UPDATE,
-should be considered as DISAS_EXIT variant, and should be
-forced to exit back to main loop so qemu will have a chance
-processing pending CPU state updates, including pending
-interrupts.
-
-This change brings consistency with how DISAS_UPDATE is treated
-in aarch32 case.
-
-CC: Peter Maydell <peter.maydell@linaro.org>
-CC: Alex Bennée <alex.bennee@linaro.org>
-CC: qemu-stable@nongnu.org
-Suggested-by: Peter Maydell <peter.maydell@linaro.org>
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
-Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
-Message-id: 1521526368-1996-1-git-send-email-kamensky@cisco.com
-Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
-Upstream-Status: Backport
----
- target/arm/translate-a64.c | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/target/arm/translate-a64.c b/target/arm/translate-a64.c
-index 625ef2d..c381091 100644
---- a/target/arm/translate-a64.c
-+++ b/target/arm/translate-a64.c
-@@ -11384,12 +11384,12 @@ static void aarch64_tr_tb_stop(DisasContextBase *dcbase, CPUState *cpu)
-         case DISAS_UPDATE:
-             gen_a64_set_pc_im(dc->pc);
-             /* fall through */
--        case DISAS_JUMP:
--            tcg_gen_lookup_and_goto_ptr();
--            break;
-         case DISAS_EXIT:
-             tcg_gen_exit_tb(0);
-             break;
-+        case DISAS_JUMP:
-+            tcg_gen_lookup_and_goto_ptr();
-+            break;
-         case DISAS_NORETURN:
-         case DISAS_SWI:
-             break;
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0012-fix-libcap-header-issue-on-some-distro.patch b/poky/meta/recipes-devtools/qemu/qemu/0012-fix-libcap-header-issue-on-some-distro.patch
new file mode 100644
index 0000000..aa24f72
--- /dev/null
+++ b/poky/meta/recipes-devtools/qemu/qemu/0012-fix-libcap-header-issue-on-some-distro.patch
@@ -0,0 +1,85 @@
+From bb9e48e331eee06d7bac1dce809c70191d1a3b4d Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Tue, 12 Mar 2013 09:54:06 +0800
+Subject: [PATCH] fix libcap header issue on some distro
+
+1, When build qemu-native on SLED 11.2, there is an error:
+...
+| In file included from /usr/include/bits/sigcontext.h:28,
+|  from /usr/include/signal.h:339,
+|  from /buildarea2/tmp/work/i686-linux/qemu-native/1.4.0-r0/
+qemu-1.4.0/include/qemu-common.h:42,
+|  from fsdev/virtfs-proxy-helper.c:23:
+|  /usr/include/asm/sigcontext.h:28: error: expected specifier-
+qualifier-list before '__u64'
+|  /usr/include/asm/sigcontext.h:191: error: expected specifier-
+qualifier-list before '__u64'
+...
+
+2, The virtfs-proxy-helper.c includes <sys/capability.h> and
+qemu-common.h in sequence. The header include map is:
+(`-->' presents `include')
+...
+"virtfs-proxy-helper.c" --> <sys/capability.h>
+...
+"virtfs-proxy-helper.c" --> "qemu-common.h" --> <signal.h> -->
+<bits/sigcontext.h> --> <asm/sigcontext.h> --> <linux/types.h> -->
+<asm/types.h> --> <asm-generic/types.h> --> <asm-generic/int-ll64.h>
+...
+
+3, The bug is found on SLED 11.2 x86. In libcap header file
+/usr/include/sys/capability.h, it does evil stuff like this:
+...
+  25 /*
+  26  * Make sure we can be included from userland by preventing
+  27  * capability.h from including other kernel headers
+  28  */
+  29 #define _LINUX_TYPES_H
+  30 #define _LINUX_FS_H
+  31 #define __LINUX_COMPILER_H
+  32 #define __user
+  33
+  34 typedef unsigned int __u32;
+  35 typedef __u32 __le32;
+...
+This completely prevents including /usr/include/linux/types.h.
+The above `<asm/sigcontext.h> --> <linux/types.h>' is prevented,
+and '__u64' is defined in <asm-generic/int-ll64.h>.
+
+4, Modify virtfs-proxy-helper.c to include <sys/capability.h>
+last to workaround the issue.
+
+http://www.linuxtv.org/pipermail/vdr/2009-August/021194.html
+http://patchwork.linuxtv.org/patch/12748/
+
+Upstream-Status: Pending
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ fsdev/virtfs-proxy-helper.c | 7 +++++--
+ 1 file changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/fsdev/virtfs-proxy-helper.c b/fsdev/virtfs-proxy-helper.c
+index 6f132c5ff1..8329950c26 100644
+--- a/fsdev/virtfs-proxy-helper.c
++++ b/fsdev/virtfs-proxy-helper.c
+@@ -13,7 +13,6 @@
+ #include <sys/resource.h>
+ #include <getopt.h>
+ #include <syslog.h>
+-#include <sys/capability.h>
+ #include <sys/fsuid.h>
+ #include <sys/vfs.h>
+ #include <sys/ioctl.h>
+@@ -27,7 +26,11 @@
+ #include "9p-iov-marshal.h"
+ #include "hw/9pfs/9p-proxy.h"
+ #include "fsdev/9p-iov-marshal.h"
+-
++/*
++ * Include this one last due to some versions of it being buggy:
++ * http://www.linuxtv.org/pipermail/vdr/2009-August/021194.html
++ */
++#include <sys/capability.h>
+ #define PROGNAME "virtfs-proxy-helper"
+ 
+ #ifndef XFS_SUPER_MAGIC
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0013-cpus.c-Add-error-messages-when-qemi_cpu_kick_thread-.patch b/poky/meta/recipes-devtools/qemu/qemu/0013-cpus.c-Add-error-messages-when-qemi_cpu_kick_thread-.patch
new file mode 100644
index 0000000..8a9141a
--- /dev/null
+++ b/poky/meta/recipes-devtools/qemu/qemu/0013-cpus.c-Add-error-messages-when-qemi_cpu_kick_thread-.patch
@@ -0,0 +1,73 @@
+From edc8dba74c7a4a2121d76c982be0074183bf080a Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?An=C3=ADbal=20Lim=C3=B3n?= <anibal.limon@linux.intel.com>
+Date: Wed, 12 Aug 2015 15:11:30 -0500
+Subject: [PATCH] cpus.c: Add error messages when qemi_cpu_kick_thread fails.
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Add custom_debug.h with function for print backtrace information.
+When pthread_kill fails in qemu_cpu_kick_thread display backtrace and
+current cpu information.
+
+Upstream-Status: Inappropriate
+Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
+---
+ cpus.c         |  5 +++++
+ custom_debug.h | 24 ++++++++++++++++++++++++
+ 2 files changed, 29 insertions(+)
+ create mode 100644 custom_debug.h
+
+diff --git a/cpus.c b/cpus.c
+index 38eba8bff3..b84a60a4f3 100644
+--- a/cpus.c
++++ b/cpus.c
+@@ -1690,6 +1690,8 @@ static void *qemu_tcg_cpu_thread_fn(void *arg)
+     return NULL;
+ }
+ 
++#include "custom_debug.h"
++
+ static void qemu_cpu_kick_thread(CPUState *cpu)
+ {
+ #ifndef _WIN32
+@@ -1702,6 +1704,9 @@ static void qemu_cpu_kick_thread(CPUState *cpu)
+     err = pthread_kill(cpu->thread->thread, SIG_IPI);
+     if (err) {
+         fprintf(stderr, "qemu:%s: %s", __func__, strerror(err));
++        fprintf(stderr, "CPU #%d:\n", cpu->cpu_index);
++        cpu_dump_state(cpu, stderr, fprintf, 0);
++        backtrace_print();
+         exit(1);
+     }
+ #else /* _WIN32 */
+diff --git a/custom_debug.h b/custom_debug.h
+new file mode 100644
+index 0000000000..f029e45547
+--- /dev/null
++++ b/custom_debug.h
+@@ -0,0 +1,24 @@
++#include <execinfo.h>
++#include <stdio.h>
++#define BACKTRACE_MAX 128
++static void backtrace_print(void)
++{
++	int nfuncs = 0;
++	void *buf[BACKTRACE_MAX];
++	char **symbols;
++	int i;
++
++	nfuncs = backtrace(buf, BACKTRACE_MAX);
++
++	symbols = backtrace_symbols(buf, nfuncs);
++	if (symbols == NULL) {
++		fprintf(stderr, "backtrace_print failed to get symbols");
++		return;
++	}
++
++	fprintf(stderr, "Backtrace ...\n");
++	for (i = 0; i < nfuncs; i++)
++		fprintf(stderr, "%s\n", symbols[i]);
++
++	free(symbols);
++}
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0013-ps2-check-PS2Queue-pointers-in-post_load-routine.patch b/poky/meta/recipes-devtools/qemu/qemu/0013-ps2-check-PS2Queue-pointers-in-post_load-routine.patch
deleted file mode 100644
index d2bdf6b..0000000
--- a/poky/meta/recipes-devtools/qemu/qemu/0013-ps2-check-PS2Queue-pointers-in-post_load-routine.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-From 065061dca34fa5b91be6dce9a87a8755d8826c78 Mon Sep 17 00:00:00 2001
-From: Prasad J Pandit <pjp@fedoraproject.org>
-Date: Thu, 16 Nov 2017 13:21:55 +0530
-Subject: [PATCH] ps2: check PS2Queue pointers in post_load routine
-
-During Qemu guest migration, a destination process invokes ps2
-post_load function. In that, if 'rptr' and 'count' values were
-invalid, it could lead to OOB access or infinite loop issue.
-Add check to avoid it.
-
-Reported-by: Cyrille Chatras <cyrille.chatras@orange.com>
-Signed-off-by: Prasad J Pandit <pjp@fedoraproject.org>
-Message-id: 20171116075155.22378-1-ppandit@redhat.com
-Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
-
-CVE: CVE-2017-16845
-Upstream-Status: Backport
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- hw/input/ps2.c | 21 +++++++++------------
- 1 file changed, 9 insertions(+), 12 deletions(-)
-
-diff --git a/hw/input/ps2.c b/hw/input/ps2.c
-index f388a23..de171a2 100644
---- a/hw/input/ps2.c
-+++ b/hw/input/ps2.c
-@@ -1225,24 +1225,21 @@ static void ps2_common_reset(PS2State *s)
- static void ps2_common_post_load(PS2State *s)
- {
-     PS2Queue *q = &s->queue;
--    int size;
--    int i;
--    int tmp_data[PS2_QUEUE_SIZE];
-+    uint8_t i, size;
-+    uint8_t tmp_data[PS2_QUEUE_SIZE];
- 
-     /* set the useful data buffer queue size, < PS2_QUEUE_SIZE */
--    size = q->count > PS2_QUEUE_SIZE ? 0 : q->count;
-+    size = (q->count < 0 || q->count > PS2_QUEUE_SIZE) ? 0 : q->count;
- 
-     /* move the queue elements to the start of data array */
--    if (size > 0) {
--        for (i = 0; i < size; i++) {
--            /* move the queue elements to the temporary buffer */
--            tmp_data[i] = q->data[q->rptr];
--            if (++q->rptr == 256) {
--                q->rptr = 0;
--            }
-+    for (i = 0; i < size; i++) {
-+        if (q->rptr < 0 || q->rptr >= sizeof(q->data)) {
-+            q->rptr = 0;
-         }
--        memcpy(q->data, tmp_data, size);
-+        tmp_data[i] = q->data[q->rptr++];
-     }
-+    memcpy(q->data, tmp_data, size);
-+
-     /* reset rptr/wptr/count */
-     q->rptr = 0;
-     q->wptr = size;
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0014-fix-libcap-header-issue-on-some-distro.patch b/poky/meta/recipes-devtools/qemu/qemu/0014-fix-libcap-header-issue-on-some-distro.patch
deleted file mode 100644
index b662a41..0000000
--- a/poky/meta/recipes-devtools/qemu/qemu/0014-fix-libcap-header-issue-on-some-distro.patch
+++ /dev/null
@@ -1,85 +0,0 @@
-From 47fdb0b6e2e393194a8c81544c647fdd997aec7f Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Tue, 12 Mar 2013 09:54:06 +0800
-Subject: [PATCH] fix libcap header issue on some distro
-
-1, When build qemu-native on SLED 11.2, there is an error:
-...
-| In file included from /usr/include/bits/sigcontext.h:28,
-|  from /usr/include/signal.h:339,
-|  from /buildarea2/tmp/work/i686-linux/qemu-native/1.4.0-r0/
-qemu-1.4.0/include/qemu-common.h:42,
-|  from fsdev/virtfs-proxy-helper.c:23:
-|  /usr/include/asm/sigcontext.h:28: error: expected specifier-
-qualifier-list before '__u64'
-|  /usr/include/asm/sigcontext.h:191: error: expected specifier-
-qualifier-list before '__u64'
-...
-
-2, The virtfs-proxy-helper.c includes <sys/capability.h> and
-qemu-common.h in sequence. The header include map is:
-(`-->' presents `include')
-...
-"virtfs-proxy-helper.c" --> <sys/capability.h>
-...
-"virtfs-proxy-helper.c" --> "qemu-common.h" --> <signal.h> -->
-<bits/sigcontext.h> --> <asm/sigcontext.h> --> <linux/types.h> -->
-<asm/types.h> --> <asm-generic/types.h> --> <asm-generic/int-ll64.h>
-...
-
-3, The bug is found on SLED 11.2 x86. In libcap header file
-/usr/include/sys/capability.h, it does evil stuff like this:
-...
-  25 /*
-  26  * Make sure we can be included from userland by preventing
-  27  * capability.h from including other kernel headers
-  28  */
-  29 #define _LINUX_TYPES_H
-  30 #define _LINUX_FS_H
-  31 #define __LINUX_COMPILER_H
-  32 #define __user
-  33
-  34 typedef unsigned int __u32;
-  35 typedef __u32 __le32;
-...
-This completely prevents including /usr/include/linux/types.h.
-The above `<asm/sigcontext.h> --> <linux/types.h>' is prevented,
-and '__u64' is defined in <asm-generic/int-ll64.h>.
-
-4, Modify virtfs-proxy-helper.c to include <sys/capability.h>
-last to workaround the issue.
-
-http://www.linuxtv.org/pipermail/vdr/2009-August/021194.html
-http://patchwork.linuxtv.org/patch/12748/
-
-Upstream-Status: Pending
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- fsdev/virtfs-proxy-helper.c | 7 +++++--
- 1 file changed, 5 insertions(+), 2 deletions(-)
-
-diff --git a/fsdev/virtfs-proxy-helper.c b/fsdev/virtfs-proxy-helper.c
-index 8e48500..6490030 100644
---- a/fsdev/virtfs-proxy-helper.c
-+++ b/fsdev/virtfs-proxy-helper.c
-@@ -13,7 +13,6 @@
- #include <sys/resource.h>
- #include <getopt.h>
- #include <syslog.h>
--#include <sys/capability.h>
- #include <sys/fsuid.h>
- #include <sys/vfs.h>
- #include <sys/ioctl.h>
-@@ -27,7 +26,11 @@
- #include "9p-iov-marshal.h"
- #include "hw/9pfs/9p-proxy.h"
- #include "fsdev/9p-iov-marshal.h"
--
-+/*
-+ * Include this one last due to some versions of it being buggy:
-+ * http://www.linuxtv.org/pipermail/vdr/2009-August/021194.html
-+ */
-+#include <sys/capability.h>
- #define PROGNAME "virtfs-proxy-helper"
- 
- #ifndef XFS_SUPER_MAGIC
diff --git a/poky/meta/recipes-devtools/qemu/qemu/0015-cpus.c-Add-error-messages-when-qemi_cpu_kick_thread-.patch b/poky/meta/recipes-devtools/qemu/qemu/0015-cpus.c-Add-error-messages-when-qemi_cpu_kick_thread-.patch
deleted file mode 100644
index a5621ca..0000000
--- a/poky/meta/recipes-devtools/qemu/qemu/0015-cpus.c-Add-error-messages-when-qemi_cpu_kick_thread-.patch
+++ /dev/null
@@ -1,73 +0,0 @@
-From db914e0f93a32b6731a636517002ecadc207718b Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?An=C3=ADbal=20Lim=C3=B3n?= <anibal.limon@linux.intel.com>
-Date: Wed, 12 Aug 2015 15:11:30 -0500
-Subject: [PATCH] cpus.c: Add error messages when qemi_cpu_kick_thread fails.
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Add custom_debug.h with function for print backtrace information.
-When pthread_kill fails in qemu_cpu_kick_thread display backtrace and
-current cpu information.
-
-Upstream-Status: Inappropriate
-Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
----
- cpus.c         |  5 +++++
- custom_debug.h | 24 ++++++++++++++++++++++++
- 2 files changed, 29 insertions(+)
- create mode 100644 custom_debug.h
-
-diff --git a/cpus.c b/cpus.c
-index 114c29b..c3dd2e0 100644
---- a/cpus.c
-+++ b/cpus.c
-@@ -1510,6 +1510,8 @@ static void *qemu_tcg_cpu_thread_fn(void *arg)
-     return NULL;
- }
- 
-+#include "custom_debug.h"
-+
- static void qemu_cpu_kick_thread(CPUState *cpu)
- {
- #ifndef _WIN32
-@@ -1522,6 +1524,9 @@ static void qemu_cpu_kick_thread(CPUState *cpu)
-     err = pthread_kill(cpu->thread->thread, SIG_IPI);
-     if (err) {
-         fprintf(stderr, "qemu:%s: %s", __func__, strerror(err));
-+        fprintf(stderr, "CPU #%d:\n", cpu->cpu_index);
-+        cpu_dump_state(cpu, stderr, fprintf, 0);
-+        backtrace_print();
-         exit(1);
-     }
- #else /* _WIN32 */
-diff --git a/custom_debug.h b/custom_debug.h
-new file mode 100644
-index 0000000..f029e45
---- /dev/null
-+++ b/custom_debug.h
-@@ -0,0 +1,24 @@
-+#include <execinfo.h>
-+#include <stdio.h>
-+#define BACKTRACE_MAX 128
-+static void backtrace_print(void)
-+{
-+	int nfuncs = 0;
-+	void *buf[BACKTRACE_MAX];
-+	char **symbols;
-+	int i;
-+
-+	nfuncs = backtrace(buf, BACKTRACE_MAX);
-+
-+	symbols = backtrace_symbols(buf, nfuncs);
-+	if (symbols == NULL) {
-+		fprintf(stderr, "backtrace_print failed to get symbols");
-+		return;
-+	}
-+
-+	fprintf(stderr, "Backtrace ...\n");
-+	for (i = 0; i < nfuncs; i++)
-+		fprintf(stderr, "%s\n", symbols[i]);
-+
-+	free(symbols);
-+}
diff --git a/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-10839.patch b/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-10839.patch
new file mode 100644
index 0000000..7e1e442
--- /dev/null
+++ b/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-10839.patch
@@ -0,0 +1,52 @@
+From fdc89e90fac40c5ca2686733df17b6423fb8d8fb Mon Sep 17 00:00:00 2001
+From: Jason Wang <jasowang@redhat.com>
+Date: Wed, 30 May 2018 13:08:15 +0800
+Subject: [PATCH] ne2000: fix possible out of bound access in ne2000_receive
+
+In ne2000_receive(), we try to assign size_ to size which converts
+from size_t to integer. This will cause troubles when size_ is greater
+INT_MAX, this will lead a negative value in size and it can then pass
+the check of size < MIN_BUF_SIZE which may lead out of bound access of
+for both buf and buf1.
+
+Fixing by converting the type of size to size_t.
+
+CC: qemu-stable@nongnu.org
+Reported-by: Daniel Shapira <daniel@twistlock.com>
+Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
+Signed-off-by: Jason Wang <jasowang@redhat.com>
+
+Upstream-Status: Backport [https://git.qemu.org/?p=qemu.git;a=commitdiff
+;h=fdc89e90fac40c5ca2686733df17b6423fb8d8fb#patch1]
+
+CVE: CVE-2018-10839
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ hw/net/ne2000.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/hw/net/ne2000.c b/hw/net/ne2000.c
+index 07d79e3..869518e 100644
+--- a/hw/net/ne2000.c
++++ b/hw/net/ne2000.c
+@@ -174,7 +174,7 @@ static int ne2000_buffer_full(NE2000State *s)
+ ssize_t ne2000_receive(NetClientState *nc, const uint8_t *buf, size_t size_)
+ {
+     NE2000State *s = qemu_get_nic_opaque(nc);
+-    int size = size_;
++    size_t size = size_;
+     uint8_t *p;
+     unsigned int total_len, next, avail, len, index, mcast_idx;
+     uint8_t buf1[60];
+@@ -182,7 +182,7 @@ ssize_t ne2000_receive(NetClientState *nc, const uint8_t *buf, size_t size_)
+         { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff };
+ 
+ #if defined(DEBUG_NE2000)
+-    printf("NE2000: received len=%d\n", size);
++    printf("NE2000: received len=%zu\n", size);
+ #endif
+ 
+     if (s->cmd & E8390_STOP || ne2000_buffer_full(s))
+-- 
+1.8.3.1
diff --git a/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-12617.patch b/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-12617.patch
deleted file mode 100644
index c89f189..0000000
--- a/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-12617.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-From 141b197408ab398c4f474ac1a728ab316e921f2b Mon Sep 17 00:00:00 2001
-From: Prasad J Pandit <pjp@fedoraproject.org>
-Date: Wed, 13 Jun 2018 11:46:57 +0530
-Subject: [PATCH] qga: check bytes count read by guest-file-read
-
-While reading file content via 'guest-file-read' command,
-'qmp_guest_file_read' routine allocates buffer of count+1
-bytes. It could overflow for large values of 'count'.
-Add check to avoid it.
-
-Reported-by: Fakhri Zulkifli <mohdfakhrizulkifli@gmail.com>
-Signed-off-by: Prasad J Pandit <pjp@fedoraproject.org>
-Cc: qemu-stable@nongnu.org
-Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
-
-CVE: CVE-2018-12617
-Upstream-Status: Backport [https://git.qemu.org/?p=qemu.git;a=commitdiff;h=141b197408ab398c4f474ac1a728ab316e921f2b]
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- qga/commands-posix.c | 2 +-
- qga/commands-win32.c | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/qga/commands-posix.c b/qga/commands-posix.c
-index 594d21ef3e..9284e71666 100644
---- a/qga/commands-posix.c
-+++ b/qga/commands-posix.c
-@@ -458,7 +458,7 @@ struct GuestFileRead *qmp_guest_file_read(int64_t handle, bool has_count,
- 
-     if (!has_count) {
-         count = QGA_READ_COUNT_DEFAULT;
--    } else if (count < 0) {
-+    } else if (count < 0 || count >= UINT32_MAX) {
-         error_setg(errp, "value '%" PRId64 "' is invalid for argument count",
-                    count);
-         return NULL;
-diff --git a/qga/commands-win32.c b/qga/commands-win32.c
-index 70ee5379f6..73f31fa8c2 100644
---- a/qga/commands-win32.c
-+++ b/qga/commands-win32.c
-@@ -318,7 +318,7 @@ GuestFileRead *qmp_guest_file_read(int64_t handle, bool has_count,
-     }
-     if (!has_count) {
-         count = QGA_READ_COUNT_DEFAULT;
--    } else if (count < 0) {
-+    } else if (count < 0 || count >= UINT32_MAX) {
-         error_setg(errp, "value '%" PRId64
-                    "' is invalid for argument count", count);
-         return NULL;
--- 
-2.13.3
-
diff --git a/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-15746.patch b/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-15746.patch
new file mode 100644
index 0000000..2f61ea0
--- /dev/null
+++ b/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-15746.patch
@@ -0,0 +1,64 @@
+From 9acf4c64dd4560bd268006d7356c7455fab7e5b1 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Thu, 6 Sep 2018 14:52:12 +0800
+Subject: [PATCH] seccomp: set the seccomp filter to all threads
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+When using "-seccomp on", the seccomp policy is only applied to the
+main thread, the vcpu worker thread and other worker threads created
+after seccomp policy is applied; the seccomp policy is not applied to
+e.g. the RCU thread because it is created before the seccomp policy is
+applied and SECCOMP_FILTER_FLAG_TSYNC isn't used.
+
+This can be verified with
+for task in /proc/`pidof qemu`/task/*; do cat $task/status | grep Secc ; done
+Seccomp:	2
+Seccomp:	0
+Seccomp:	0
+Seccomp:	2
+Seccomp:	2
+Seccomp:	2
+
+Starting with libseccomp 2.2.0 and kernel >= 3.17, we can use
+seccomp_attr_set(ctx, > SCMP_FLTATR_CTL_TSYNC, 1) to update the policy
+on all threads.
+
+libseccomp requirement was bumped to 2.2.0 in previous patch.
+libseccomp should fail to set the filter if it can't honour
+SCMP_FLTATR_CTL_TSYNC (untested), and thus -sandbox will now fail on
+kernel < 3.17.
+
+Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
+Acked-by: Eduardo Otubo <otubo@redhat.com>
+
+Upstream-Status: Backport[https://github.com/qemu/qemu/commit/
+70dfabeaa79ba4d7a3b699abe1a047c8012db114#diff-18106d3b47a2d249f9d41e772b7db22d]
+
+CVE: CVE-2018-15746
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ qemu-seccomp.c | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/qemu-seccomp.c b/qemu-seccomp.c
+index 9cd8eb9..ba5500a 100644
+--- a/qemu-seccomp.c
++++ b/qemu-seccomp.c
+@@ -120,6 +120,11 @@ static int seccomp_start(uint32_t seccomp_opts)
+         goto seccomp_return;
+     }
+ 
++    rc = seccomp_attr_set(ctx, SCMP_FLTATR_CTL_TSYNC, 1);
++    if (rc != 0) {
++        goto seccomp_return;
++    }
++
+     for (i = 0; i < ARRAY_SIZE(blacklist); i++) {
+         if (!(seccomp_opts & blacklist[i].set)) {
+             continue;
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-17958.patch b/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-17958.patch
new file mode 100644
index 0000000..af40ff2
--- /dev/null
+++ b/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-17958.patch
@@ -0,0 +1,52 @@
+From 06e88ca78d056ea4de885e3a1496805179dc47bc Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Mon, 15 Oct 2018 16:33:04 +0800
+Subject: [PATCH] ne2000: fix possible out of bound access in ne2000_receive
+
+In ne2000_receive(), we try to assign size_ to size which converts
+from size_t to integer. This will cause troubles when size_ is greater
+INT_MAX, this will lead a negative value in size and it can then pass
+the check of size < MIN_BUF_SIZE which may lead out of bound access of
+for both buf and buf1.
+
+Fixing by converting the type of size to size_t.
+
+CC: address@hidden
+Reported-by: Daniel Shapira <address@hidden>
+Reviewed-by: Michael S. Tsirkin <address@hidden>
+Signed-off-by: Jason Wang <address@hidden>
+
+Upstream-Status: Backport [https://lists.gnu.org/archive/html/qemu-devel/2018-09/msg03273.html]
+
+CVE: CVE-2018-17958
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ hw/net/ne2000.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/hw/net/ne2000.c b/hw/net/ne2000.c
+index 07d79e3..869518e 100644
+--- a/hw/net/ne2000.c
++++ b/hw/net/ne2000.c
+@@ -174,7 +174,7 @@ static int ne2000_buffer_full(NE2000State *s)
+ ssize_t ne2000_receive(NetClientState *nc, const uint8_t *buf, size_t size_)
+ {
+     NE2000State *s = qemu_get_nic_opaque(nc);
+-    int size = size_;
++    size_t size = size_;
+     uint8_t *p;
+     unsigned int total_len, next, avail, len, index, mcast_idx;
+     uint8_t buf1[60];
+@@ -182,7 +182,7 @@ ssize_t ne2000_receive(NetClientState *nc, const uint8_t *buf, size_t size_)
+         { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff };
+ 
+ #if defined(DEBUG_NE2000)
+-    printf("NE2000: received len=%d\n", size);
++    printf("NE2000: received len=%zu\n", size);
+ #endif
+ 
+     if (s->cmd & E8390_STOP || ne2000_buffer_full(s))
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-17962.patch b/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-17962.patch
new file mode 100644
index 0000000..88bfd81
--- /dev/null
+++ b/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-17962.patch
@@ -0,0 +1,70 @@
+From 20abe443ad9464b18ac494f71f7d53f19ee3748f Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Mon, 15 Oct 2018 16:38:08 +0800
+Subject: [PATCH] rtl8139: fix possible out of bound access
+
+In rtl8139_do_receive(), we try to assign size_ to size which converts
+from size_t to integer. This will cause troubles when size_ is greater
+INT_MAX, this will lead a negative value in size and it can then pass
+the check of size < MIN_BUF_SIZE which may lead out of bound access of
+for both buf and buf1.
+
+Fixing by converting the type of size to size_t.
+
+CC: address@hidden
+Reported-by: Daniel Shapira <address@hidden>
+Reviewed-by: Michael S. Tsirkin <address@hidden>
+Signed-off-by: Jason Wang <address@hidden>
+
+Upstream-Status: Backport [https://lists.gnu.org/archive/html/qemu-devel/2018-09/msg03269.html]
+
+CVE: CVE-2018-17962
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ hw/net/rtl8139.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/hw/net/rtl8139.c b/hw/net/rtl8139.c
+index 46daa16..2342a09 100644
+--- a/hw/net/rtl8139.c
++++ b/hw/net/rtl8139.c
+@@ -817,7 +817,7 @@ static ssize_t rtl8139_do_receive(NetClientState *nc, const uint8_t *buf, size_t
+     RTL8139State *s = qemu_get_nic_opaque(nc);
+     PCIDevice *d = PCI_DEVICE(s);
+     /* size is the length of the buffer passed to the driver */
+-    int size = size_;
++    size_t size = size_;
+     const uint8_t *dot1q_buf = NULL;
+ 
+     uint32_t packet_header = 0;
+@@ -826,7 +826,7 @@ static ssize_t rtl8139_do_receive(NetClientState *nc, const uint8_t *buf, size_t
+     static const uint8_t broadcast_macaddr[6] =
+         { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff };
+ 
+-    DPRINTF(">>> received len=%d\n", size);
++    DPRINTF(">>> received len=%zu\n", size);
+ 
+     /* test if board clock is stopped */
+     if (!s->clock_enabled)
+@@ -1035,7 +1035,7 @@ static ssize_t rtl8139_do_receive(NetClientState *nc, const uint8_t *buf, size_t
+ 
+         if (size+4 > rx_space)
+         {
+-            DPRINTF("C+ Rx mode : descriptor %d size %d received %d + 4\n",
++            DPRINTF("C+ Rx mode : descriptor %d size %d received %zu + 4\n",
+                 descriptor, rx_space, size);
+ 
+             s->IntrStatus |= RxOverflow;
+@@ -1148,7 +1148,7 @@ static ssize_t rtl8139_do_receive(NetClientState *nc, const uint8_t *buf, size_t
+         if (avail != 0 && RX_ALIGN(size + 8) >= avail)
+         {
+             DPRINTF("rx overflow: rx buffer length %d head 0x%04x "
+-                "read 0x%04x === available 0x%04x need 0x%04x\n",
++                "read 0x%04x === available 0x%04x need 0x%04zx\n",
+                 s->RxBufferSize, s->RxBufAddr, s->RxBufPtr, avail, size + 8);
+ 
+             s->IntrStatus |= RxOverflow;
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-17963.patch b/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-17963.patch
new file mode 100644
index 0000000..054cdc8
--- /dev/null
+++ b/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-17963.patch
@@ -0,0 +1,51 @@
+From e5ff72a8005dd1d9c0f63f8a9cc4298df5bb7551 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Mon, 15 Oct 2018 16:39:46 +0800
+Subject: [PATCH] pcnet: fix possible buffer overflow
+
+In pcnet_receive(), we try to assign size_ to size which converts from
+size_t to integer. This will cause troubles when size_ is greater
+INT_MAX, this will lead a negative value in size and it can then pass
+the check of size < MIN_BUF_SIZE which may lead out of bound access
+for both buf and buf1.
+
+Fixing by converting the type of size to size_t.
+
+CC: address@hidden
+Reported-by: Daniel Shapira <address@hidden>
+Reviewed-by: Michael S. Tsirkin <address@hidden>
+Signed-off-by: Jason Wang <address@hidden>
+
+Upstream-Status: Backport [https://lists.gnu.org/archive/html/qemu-devel/2018-09/msg03268.html]
+
+CVE: CVE-2018-17963
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ hw/net/pcnet.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/hw/net/pcnet.c b/hw/net/pcnet.c
+index 0c44554..d9ba04b 100644
+--- a/hw/net/pcnet.c
++++ b/hw/net/pcnet.c
+@@ -988,14 +988,14 @@ ssize_t pcnet_receive(NetClientState *nc, const uint8_t *buf, size_t size_)
+     uint8_t buf1[60];
+     int remaining;
+     int crc_err = 0;
+-    int size = size_;
++    size_t size = size_;
+ 
+     if (CSR_DRX(s) || CSR_STOP(s) || CSR_SPND(s) || !size ||
+         (CSR_LOOP(s) && !s->looptest)) {
+         return -1;
+     }
+ #ifdef PCNET_DEBUG
+-    printf("pcnet_receive size=%d\n", size);
++    printf("pcnet_receive size=%zu\n", size);
+ #endif
+ 
+     /* if too small buffer, then expand it */
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-7550.patch b/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-7550.patch
deleted file mode 100644
index 9923d12..0000000
--- a/poky/meta/recipes-devtools/qemu/qemu/CVE-2018-7550.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-From 2a8fcd119eb7c6bb3837fc3669eb1b2dfb31daf8 Mon Sep 17 00:00:00 2001
-From: Jack Schwartz <jack.schwartz@oracle.com>
-Date: Thu, 21 Dec 2017 09:25:15 -0800
-Subject: [PATCH] multiboot: bss_end_addr can be zero
-
-The multiboot spec (https://www.gnu.org/software/grub/manual/multiboot/),
-section 3.1.3, allows for bss_end_addr to be zero.
-
-A zero bss_end_addr signifies there is no .bss section.
-
-CVE: CVE-2018-7550
-Upstream-Status: Backport [https://git.qemu.org/?p=qemu.git;a=commitdiff;h=2a8fcd119eb7c6bb3837fc3669eb1b2dfb31daf8]
-
-Suggested-by: Daniel Kiper <daniel.kiper@oracle.com>
-Signed-off-by: Jack Schwartz <jack.schwartz@oracle.com>
-Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
-Reviewed-by: Prasad J Pandit <pjp@fedoraproject.org>
-Signed-off-by: Kevin Wolf <kwolf@redhat.com>
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- hw/i386/multiboot.c | 18 ++++++++++--------
- 1 file changed, 10 insertions(+), 8 deletions(-)
-
-diff --git a/hw/i386/multiboot.c b/hw/i386/multiboot.c
-index 46d9c68bf5..bb8d8e4629 100644
---- a/hw/i386/multiboot.c
-+++ b/hw/i386/multiboot.c
-@@ -233,12 +233,6 @@ int load_multiboot(FWCfgState *fw_cfg,
-         mh_entry_addr = ldl_p(header+i+28);
- 
-         if (mh_load_end_addr) {
--            if (mh_bss_end_addr < mh_load_addr) {
--                fprintf(stderr, "invalid mh_bss_end_addr address\n");
--                exit(1);
--            }
--            mb_kernel_size = mh_bss_end_addr - mh_load_addr;
--
-             if (mh_load_end_addr < mh_load_addr) {
-                 fprintf(stderr, "invalid mh_load_end_addr address\n");
-                 exit(1);
-@@ -249,8 +243,16 @@ int load_multiboot(FWCfgState *fw_cfg,
-                 fprintf(stderr, "invalid kernel_file_size\n");
-                 exit(1);
-             }
--            mb_kernel_size = kernel_file_size - mb_kernel_text_offset;
--            mb_load_size = mb_kernel_size;
-+            mb_load_size = kernel_file_size - mb_kernel_text_offset;
-+        }
-+        if (mh_bss_end_addr) {
-+            if (mh_bss_end_addr < (mh_load_addr + mb_load_size)) {
-+                fprintf(stderr, "invalid mh_bss_end_addr address\n");
-+                exit(1);
-+            }
-+            mb_kernel_size = mh_bss_end_addr - mh_load_addr;
-+        } else {
-+            mb_kernel_size = mb_load_size;
-         }
- 
-         /* Valid if mh_flags sets MULTIBOOT_HEADER_HAS_VBE.
--- 
-2.13.3
-
diff --git a/poky/meta/recipes-devtools/qemu/qemu_2.11.1.bb b/poky/meta/recipes-devtools/qemu/qemu_2.11.1.bb
deleted file mode 100644
index a447dc7..0000000
--- a/poky/meta/recipes-devtools/qemu/qemu_2.11.1.bb
+++ /dev/null
@@ -1,61 +0,0 @@
-require qemu.inc
-
-inherit ptest
-
-RDEPENDS_${PN}-ptest = "bash make"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=441c28d2cf86e15a37fa47e15a72fbac \
-                    file://COPYING.LIB;endline=24;md5=c04def7ae38850e7d3ef548588159913"
-
-SRC_URI = "http://wiki.qemu-project.org/download/${BP}.tar.bz2 \
-           file://powerpc_rom.bin \
-           file://0001-sdl.c-allow-user-to-disable-pointer-grabs.patch \
-           file://0002-qemu-Add-missing-wacom-HID-descriptor.patch \
-           file://0003-Add-subpackage-ptest-which-runs-all-unit-test-cases-.patch \
-           file://run-ptest \
-           file://0004-qemu-Add-addition-environment-space-to-boot-loader-q.patch \
-           file://0005-qemu-disable-Valgrind.patch \
-           file://0006-qemu-Limit-paths-searched-during-user-mode-emulation.patch \
-           file://0007-qemu-native-set-ld.bfd-fix-cflags-and-set-some-envir.patch \
-           file://0008-chardev-connect-socket-to-a-spawned-command.patch \
-           file://0009-apic-fixup-fallthrough-to-PIC.patch \
-           file://0010-linux-user-Fix-webkitgtk-hangs-on-32-bit-x86-target.patch \
-           file://0011-memfd-fix-configure-test.patch \
-           file://0012-arm-translate-a64-treat-DISAS_UPDATE-as-variant-of-D.patch \
-           file://0013-ps2-check-PS2Queue-pointers-in-post_load-routine.patch \
-           file://0001-CVE-2018-11806-QEMU-slirp-heap-buffer-overflow.patch \
-           file://CVE-2018-7550.patch \
-           file://CVE-2018-12617.patch \
-           "
-UPSTREAM_CHECK_REGEX = "qemu-(?P<pver>\d+\..*)\.tar"
-
-SRC_URI_append_class-native = " \
-            file://0014-fix-libcap-header-issue-on-some-distro.patch \
-            file://0015-cpus.c-Add-error-messages-when-qemi_cpu_kick_thread-.patch \
-            "
-
-SRC_URI[md5sum] = "61cf862b6007eba4ac98247776af2e27"
-SRC_URI[sha256sum] = "d9df2213ceed32e91dab7bc9dd19c1af83f91ba72c7aeef7605dfaaf81732ccb"
-
-COMPATIBLE_HOST_mipsarchn32 = "null"
-COMPATIBLE_HOST_mipsarchn64 = "null"
-
-do_install_append() {
-    # Prevent QA warnings about installed ${localstatedir}/run
-    if [ -d ${D}${localstatedir}/run ]; then rmdir ${D}${localstatedir}/run; fi
-    install -Dm 0755 ${WORKDIR}/powerpc_rom.bin ${D}${datadir}/qemu
-}
-
-do_compile_ptest() {
-	make buildtest-TESTS
-}
-
-do_install_ptest() {
-	cp -rL ${B}/tests ${D}${PTEST_PATH}
-	find ${D}${PTEST_PATH}/tests -type f -name "*.[Sshcod]" | xargs -i rm -rf {}
-
-	cp ${S}/tests/Makefile.include ${D}${PTEST_PATH}/tests
-	# Don't check the file genreated by configure
-	sed -i -e '/wildcard config-host.mak/d' \
-	       -e '$ {/endif/d}' ${D}${PTEST_PATH}/tests/Makefile.include
-}
diff --git a/poky/meta/recipes-devtools/qemu/qemu_3.0.0.bb b/poky/meta/recipes-devtools/qemu/qemu_3.0.0.bb
new file mode 100644
index 0000000..776548b
--- /dev/null
+++ b/poky/meta/recipes-devtools/qemu/qemu_3.0.0.bb
@@ -0,0 +1,60 @@
+require qemu.inc
+
+inherit ptest
+
+RDEPENDS_${PN}-ptest = "bash make"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=441c28d2cf86e15a37fa47e15a72fbac \
+                    file://COPYING.LIB;endline=24;md5=c04def7ae38850e7d3ef548588159913"
+
+SRC_URI = "https://download.qemu.org/${BPN}-${PV}.tar.xz \
+           file://powerpc_rom.bin \
+           file://0001-sdl.c-allow-user-to-disable-pointer-grabs.patch \
+           file://0002-qemu-Add-missing-wacom-HID-descriptor.patch \
+           file://0003-Add-subpackage-ptest-which-runs-all-unit-test-cases-.patch \
+           file://run-ptest \
+           file://0004-qemu-Add-addition-environment-space-to-boot-loader-q.patch \
+           file://0005-qemu-disable-Valgrind.patch \
+           file://0006-qemu-Limit-paths-searched-during-user-mode-emulation.patch \
+           file://0007-qemu-native-set-ld.bfd-fix-cflags-and-set-some-envir.patch \
+           file://0008-chardev-connect-socket-to-a-spawned-command.patch \
+           file://0009-apic-fixup-fallthrough-to-PIC.patch \
+           file://0010-linux-user-Fix-webkitgtk-hangs-on-32-bit-x86-target.patch \
+           file://0011-Revert-linux-user-fix-mmap-munmap-mprotect-mremap-sh.patch \
+           file://CVE-2018-15746.patch \
+           file://CVE-2018-17958.patch \
+           file://CVE-2018-17962.patch \
+           file://CVE-2018-17963.patch \
+           "
+UPSTREAM_CHECK_REGEX = "qemu-(?P<pver>\d+(\.\d+)+)\.tar"
+
+SRC_URI_append_class-native = " \
+            file://0012-fix-libcap-header-issue-on-some-distro.patch \
+            file://0013-cpus.c-Add-error-messages-when-qemi_cpu_kick_thread-.patch \
+            "
+
+SRC_URI[md5sum] = "6a5c8df583406ea24ef25b239c3243e0"
+SRC_URI[sha256sum] = "8d7af64fe8bd5ea5c3bdf17131a8b858491bcce1ee3839425a6d91fb821b5713"
+
+COMPATIBLE_HOST_mipsarchn32 = "null"
+COMPATIBLE_HOST_mipsarchn64 = "null"
+
+do_install_append() {
+    # Prevent QA warnings about installed ${localstatedir}/run
+    if [ -d ${D}${localstatedir}/run ]; then rmdir ${D}${localstatedir}/run; fi
+    install -Dm 0755 ${WORKDIR}/powerpc_rom.bin ${D}${datadir}/qemu
+}
+
+do_compile_ptest() {
+	make buildtest-TESTS
+}
+
+do_install_ptest() {
+	cp -rL ${B}/tests ${D}${PTEST_PATH}
+	find ${D}${PTEST_PATH}/tests -type f -name "*.[Sshcod]" | xargs -i rm -rf {}
+
+	cp ${S}/tests/Makefile.include ${D}${PTEST_PATH}/tests
+	# Don't check the file genreated by configure
+	sed -i -e '/wildcard config-host.mak/d' \
+	       -e '$ {/endif/d}' ${D}${PTEST_PATH}/tests/Makefile.include
+}
diff --git a/poky/meta/recipes-devtools/qemu/qemuwrapper-cross_1.0.bb b/poky/meta/recipes-devtools/qemu/qemuwrapper-cross_1.0.bb
index c983fba..4aada52 100644
--- a/poky/meta/recipes-devtools/qemu/qemuwrapper-cross_1.0.bb
+++ b/poky/meta/recipes-devtools/qemu/qemuwrapper-cross_1.0.bb
@@ -13,38 +13,26 @@
 do_install () {
 	install -d ${D}${bindir_crossscripts}/
 
-	echo "#!/bin/sh" > ${D}${bindir_crossscripts}/qemuwrapper
 	qemu_binary=${@qemu_target_binary(d)}
-	qemu_options='${QEMU_OPTIONS}'
-	echo "$qemu_binary $qemu_options \"\$@\"" >> ${D}${bindir_crossscripts}/qemuwrapper
-	fallback_qemu_bin=
-	case $qemu_binary in
-		"qemu-i386")
-			fallback_qemu_bin=qemu-x86_64
-			;;
-		"qemu-x86_64")
-			fallback_qemu_bin=qemu-i386
-			;;
-		*)
-			;;
-	esac
+	qemu_options='${QEMU_OPTIONS} -E LD_LIBRARY_PATH=$D${libdir}:$D${base_libdir}'
 
-	if [ -n "$fallback_qemu_bin" ]; then
+	cat >> ${D}${bindir_crossscripts}/${MLPREFIX}qemuwrapper << EOF
+#!/bin/sh
+set -x
 
-		cat >> ${D}${bindir_crossscripts}/qemuwrapper << EOF
-rc=\$?
-if [ \$rc = 255 ]; then
-	$fallback_qemu_bin "\$@"
-	rc=\$?
+if [ ${@bb.utils.contains('MACHINE_FEATURES', 'qemu-usermode', 'True', 'False', d)} = False ]; then
+        echo "qemuwrapper: qemu usermode is not supported"
 fi
-exit \$rc
+
+
+$qemu_binary $qemu_options "\$@"
 EOF
 
-	fi
-
-	chmod +x ${D}${bindir_crossscripts}/qemuwrapper
+	chmod +x ${D}${bindir_crossscripts}/${MLPREFIX}qemuwrapper
 }
 
 SYSROOT_DIRS += "${bindir_crossscripts}"
 
 INHIBIT_DEFAULT_DEPS = "1"
+
+BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-devtools/quilt/quilt.inc b/poky/meta/recipes-devtools/quilt/quilt.inc
index c7bb741..48ed9ba 100644
--- a/poky/meta/recipes-devtools/quilt/quilt.inc
+++ b/poky/meta/recipes-devtools/quilt/quilt.inc
@@ -16,24 +16,8 @@
 
 inherit autotools-brokensep ptest
 
-EXTRA_OECONF_darwin += "--without-date \
-                        --without-getopt \
-                        "
-
 CLEANBROKEN = "1"
 
-PACKAGES += "guards guards-doc"
-FILES_${PN} = "${sysconfdir} ${datadir}/quilt \
-               ${bindir}/quilt ${libdir}/quilt"
-FILES_guards = "${bindir}/guards"
-FILES_${PN}-doc = "${mandir}/man1/quilt.1 ${docdir}/${BPN}"
-FILES_guards-doc = "${mandir}/man1/guards.1"
-
-RDEPENDS_${PN} = "bash"
-
-EXTRA_OE_MAKE_ARGS_darwin ?= ""
-EXTRA_OE_MAKE_ARGS ?= "BUILD_ROOT=${D}"
-
 EXTRA_OECONF = "--with-perl='${USRBINPATH}/env perl' --with-patch=patch"
 
 CACHED_CONFIGUREVARS += "ac_cv_path_BASH=/bin/bash"
@@ -49,9 +33,9 @@
 	sed -e 's,^COMPAT_SYMLINKS.*:=.*,COMPAT_SYMLINKS	:=,' -i ${S}/Makefile
 }
 
-# quilt ignores DESTDIR
+# quilt Makefiles install to BUILD_ROOT instead of DESTDIR
 do_install () {
-	oe_runmake ${EXTRA_OE_MAKE_ARGS} install
+	oe_runmake 'BUILD_ROOT=${D}' install
 	# cleanup unpackaged files
 	rm -rf ${D}/${datadir}/emacs
 }
@@ -69,6 +53,15 @@
 	cp ${WORKDIR}/test.sh ${D}${PTEST_PATH}
 }
 
+PACKAGES += "guards guards-doc"
+
+FILES_${PN} = "${sysconfdir} ${datadir}/quilt \
+               ${bindir}/quilt ${libdir}/quilt"
+FILES_guards = "${bindir}/guards"
+FILES_${PN}-doc = "${mandir}/man1/quilt.1 ${docdir}/${BPN}"
+FILES_guards-doc = "${mandir}/man1/guards.1"
+
+RDEPENDS_${PN} = "bash"
 RDEPENDS_${PN}-ptest = "make file sed gawk diffutils findutils ed perl \
                         perl-module-filehandle perl-module-getopt-std \
                         perl-module-posix perl-module-file-temp \
diff --git a/poky/meta/recipes-devtools/rpm/files/0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch b/poky/meta/recipes-devtools/rpm/files/0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch
index 5604cb9..82e7328 100644
--- a/poky/meta/recipes-devtools/rpm/files/0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch
+++ b/poky/meta/recipes-devtools/rpm/files/0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch
@@ -1,7 +1,7 @@
-From c82c19dc583843b1a975f2e3f2e151656a6f377c Mon Sep 17 00:00:00 2001
+From bd08eb0ae1312f347f49949481daa7c923752df2 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Mon, 27 Feb 2017 09:43:30 +0200
-Subject: [PATCH 06/14] Do not hardcode "lib/rpm" as the installation path for
+Subject: [PATCH] Do not hardcode "lib/rpm" as the installation path for
  default configuration and macros.
 
 Upstream-Status: Denied [https://github.com/rpm-software-management/rpm/pull/263]
@@ -14,10 +14,10 @@
  3 files changed, 4 insertions(+), 4 deletions(-)
 
 diff --git a/configure.ac b/configure.ac
-index 7155d9f00..21b95ae5f 100644
+index 09af7c4..9bd6903 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -1047,7 +1047,7 @@ else
+@@ -1055,7 +1055,7 @@ else
      usrprefix=$prefix
  fi
  
@@ -27,10 +27,10 @@
  
  AC_SUBST(OBJDUMP)
 diff --git a/macros.in b/macros.in
-index d08624856..68a972f1e 100644
+index a3aa7a9..62cee5c 100644
 --- a/macros.in
 +++ b/macros.in
-@@ -954,7 +954,7 @@ package or when debugging this package.\
+@@ -970,7 +970,7 @@ package or when debugging this package.\
  %_sharedstatedir	%{_prefix}/com
  %_localstatedir		%{_prefix}/var
  %_lib			lib
@@ -40,7 +40,7 @@
  %_infodir		%{_datadir}/info
  %_mandir		%{_datadir}/man
 diff --git a/rpm.am b/rpm.am
-index 51225892d..e0c834d37 100644
+index 82c2d7c..6341b51 100644
 --- a/rpm.am
 +++ b/rpm.am
 @@ -1,10 +1,10 @@
@@ -55,7 +55,4 @@
 +rpmconfigdir = $(libdir)/rpm
  
  # Libtool version (current-revision-age) for all our libraries
- rpm_version_info = 8:1:0
--- 
-2.15.1
-
+ rpm_version_info = 9:0:1
diff --git a/poky/meta/recipes-devtools/rpm/files/0001-Do-not-reset-the-PATH-environment-variable-before-ru.patch b/poky/meta/recipes-devtools/rpm/files/0001-Do-not-reset-the-PATH-environment-variable-before-ru.patch
index bf24d43..41cdf6e 100644
--- a/poky/meta/recipes-devtools/rpm/files/0001-Do-not-reset-the-PATH-environment-variable-before-ru.patch
+++ b/poky/meta/recipes-devtools/rpm/files/0001-Do-not-reset-the-PATH-environment-variable-before-ru.patch
@@ -1,25 +1,23 @@
-From ffb5301a8594140ad7a58bc0f2053be8ca2b2946 Mon Sep 17 00:00:00 2001
+From a674b9cc7af448d7c6748bc163bf37dc14a57f09 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Fri, 20 Jan 2017 13:32:06 +0200
-Subject: [PATCH 1/2] Do not reset the PATH environment variable before running
+Subject: [PATCH] Do not reset the PATH environment variable before running
  scriptlets.
 
 We add lots of native stuff into it and scriptlets rely on that.
 
-Also need to remove the xx test later in the function since the
-value could now be used un-initialised.
-
 Upstream-Status: Inappropriate [oe-core specific]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
 ---
  lib/rpmscript.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/lib/rpmscript.c b/lib/rpmscript.c
-index 92f949fa2..7c1aa75a8 100644
+index 6a31e0d..2b0e438 100644
 --- a/lib/rpmscript.c
 +++ b/lib/rpmscript.c
-@@ -201,7 +201,7 @@ static void doScriptExec(ARGV_const_t argv, ARGV_const_t prefixes,
+@@ -184,7 +184,7 @@ static void doScriptExec(ARGV_const_t argv, ARGV_const_t prefixes,
  	if (ipath && ipath[5] != '%')
  	    path = ipath;
  
@@ -28,13 +26,3 @@
  	free(ipath);
      }
  
-@@ -206,9 +206,7 @@ static void doScriptExec(ARGV_const_t ar
- 	/* XXX Don't mtrace into children. */
- 	unsetenv("MALLOC_CHECK_");
- 
--	if (xx == 0) {
- 	    xx = execv(argv[0], argv);
--	}
-     }
-     _exit(127); /* exit 127 for compatibility with bash(1) */
- }
diff --git a/poky/meta/recipes-devtools/rpm/files/0001-Factor-out-and-unify-setting-CLOEXEC.patch b/poky/meta/recipes-devtools/rpm/files/0001-Factor-out-and-unify-setting-CLOEXEC.patch
deleted file mode 100644
index 6f440c6..0000000
--- a/poky/meta/recipes-devtools/rpm/files/0001-Factor-out-and-unify-setting-CLOEXEC.patch
+++ /dev/null
@@ -1,148 +0,0 @@
-From 9c3e5de3240554c8ea1b29d52eeadee4840fefac Mon Sep 17 00:00:00 2001
-From: Kir Kolyshkin <kolyshkin@gmail.com>
-Date: Tue, 29 May 2018 17:37:05 -0700
-Subject: [PATCH 1/3] Factor out and unify setting CLOEXEC
-
-Commit 7a7c31f5 ("Set FD_CLOEXEC on opened files before exec from
-lua script is called") copied the code that sets CLOEXEC flag on all
-possible file descriptors from lib/rpmscript.c to luaext/lposix.c,
-essentially creating two copies of the same code (modulo comments
-and the unused assignment).
-
-This commit moves the functionality into its own function, without
-any code modifications, using the version from luaext/lposix.c.
-
-Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
-Upstream-Status: Accepted [https://github.com/rpm-software-management/rpm/pull/444]
-Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
----
- lib/rpmscript.c        | 18 ++----------------
- luaext/lposix.c        | 13 ++-----------
- rpmio/rpmio.c          | 16 ++++++++++++++++
- rpmio/rpmio_internal.h |  6 ++++++
- 4 files changed, 26 insertions(+), 27 deletions(-)
-
-diff --git a/lib/rpmscript.c b/lib/rpmscript.c
-index 747385a5b..b4ccd3246 100644
---- a/lib/rpmscript.c
-+++ b/lib/rpmscript.c
-@@ -3,7 +3,6 @@
- #include <sys/types.h>
- #include <sys/wait.h>
- #include <errno.h>
--#include <unistd.h>
- 
- #include <rpm/rpmfileutil.h>
- #include <rpm/rpmmacro.h>
-@@ -14,6 +13,7 @@
- 
- #include "rpmio/rpmlua.h"
- #include "lib/rpmscript.h"
-+#include "rpmio/rpmio_internal.h"
- 
- #include "lib/rpmplugins.h"     /* rpm plugins hooks */
- 
-@@ -170,26 +170,12 @@ static const char * const SCRIPT_PATH = "PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr
- static void doScriptExec(ARGV_const_t argv, ARGV_const_t prefixes,
- 			FD_t scriptFd, FD_t out)
- {
--    int flag;
--    int fdno;
-     int xx;
--    int open_max;
- 
-     /* SIGPIPE is ignored in rpm, reset to default for the scriptlet */
-     (void) signal(SIGPIPE, SIG_DFL);
- 
--    /* XXX Force FD_CLOEXEC on all inherited fdno's. */
--    open_max = sysconf(_SC_OPEN_MAX);
--    if (open_max == -1) {
--	open_max = 1024;
--    }
--    for (fdno = 3; fdno < open_max; fdno++) {
--	flag = fcntl(fdno, F_GETFD);
--	if (flag == -1 || (flag & FD_CLOEXEC))
--	    continue;
--	xx = fcntl(fdno, F_SETFD, FD_CLOEXEC);
--	/* XXX W2DO? debug msg for inheirited fdno w/o FD_CLOEXEC */
--    }
-+    rpmSetCloseOnExec();
- 
-     if (scriptFd != NULL) {
- 	int sfdno = Fileno(scriptFd);
-diff --git a/luaext/lposix.c b/luaext/lposix.c
-index 0a7c26c71..5d7ad3c87 100644
---- a/luaext/lposix.c
-+++ b/luaext/lposix.c
-@@ -27,6 +27,7 @@
- #include <unistd.h>
- #include <utime.h>
- #include <rpm/rpmutil.h>
-+#include "rpmio/rpmio_internal.h"
- 
- #define MYNAME		"posix"
- #define MYVERSION	MYNAME " library for " LUA_VERSION " / Nov 2003"
-@@ -335,21 +336,11 @@ static int Pexec(lua_State *L)			/** exec(path,[args]) */
- 	const char *path = luaL_checkstring(L, 1);
- 	int i,n=lua_gettop(L);
- 	char **argv;
--	int flag, fdno, open_max;
- 
- 	if (!have_forked)
- 	    return luaL_error(L, "exec not permitted in this context");
- 
--	open_max = sysconf(_SC_OPEN_MAX);
--	if (open_max == -1) {
--	    open_max = 1024;
--	}
--	for (fdno = 3; fdno < open_max; fdno++) {
--	    flag = fcntl(fdno, F_GETFD);
--	    if (flag == -1 || (flag & FD_CLOEXEC))
--		continue;
--	    fcntl(fdno, F_SETFD, FD_CLOEXEC);
--	}
-+	rpmSetCloseOnExec();
- 
- 	argv = malloc((n+1)*sizeof(char*));
- 	if (argv==NULL) return luaL_error(L,"not enough memory");
-diff --git a/rpmio/rpmio.c b/rpmio/rpmio.c
-index c7cbc32aa..ea111d2ec 100644
---- a/rpmio/rpmio.c
-+++ b/rpmio/rpmio.c
-@@ -1759,3 +1759,19 @@ DIGEST_CTX fdDupDigest(FD_t fd, int id)
- 
-     return ctx;
- }
-+
-+void rpmSetCloseOnExec(void)
-+{
-+	int flag, fdno, open_max;
-+
-+	open_max = sysconf(_SC_OPEN_MAX);
-+	if (open_max == -1) {
-+		open_max = 1024;
-+	}
-+	for (fdno = 3; fdno < open_max; fdno++) {
-+		flag = fcntl(fdno, F_GETFD);
-+		if (flag == -1 || (flag & FD_CLOEXEC))
-+			continue;
-+		fcntl(fdno, F_SETFD, FD_CLOEXEC);
-+	}
-+}
-diff --git a/rpmio/rpmio_internal.h b/rpmio/rpmio_internal.h
-index fbed183b0..370cbdc75 100644
---- a/rpmio/rpmio_internal.h
-+++ b/rpmio/rpmio_internal.h
-@@ -41,6 +41,12 @@ DIGEST_CTX fdDupDigest(FD_t fd, int id);
- int rpmioSlurp(const char * fn,
-                 uint8_t ** bp, ssize_t * blenp);
- 
-+/**
-+ * Set close-on-exec flag for all opened file descriptors, except
-+ * stdin/stdout/stderr.
-+ */
-+void rpmSetCloseOnExec(void);
-+
- #ifdef __cplusplus
- }
- #endif
diff --git a/poky/meta/recipes-devtools/rpm/files/0001-configure.ac-add-option-for-dbus.patch b/poky/meta/recipes-devtools/rpm/files/0001-configure.ac-add-option-for-dbus.patch
deleted file mode 100644
index dc71d9b..0000000
--- a/poky/meta/recipes-devtools/rpm/files/0001-configure.ac-add-option-for-dbus.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From dfb422c744fdc1838afc40b8e1f161bb46093d92 Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Sun, 8 Apr 2018 12:06:42 +0800
-Subject: [PATCH] configure.ac: add option for dbus
-
-Add option for dbus so that users could choose to build with dbus
-or with no dbus.
-
-Upstream-Status: Pending
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- configure.ac | 11 +++++++----
- 1 file changed, 7 insertions(+), 4 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index 4db15c7909..493f393d31 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -976,12 +976,15 @@ AS_IF([test "$enable_plugins" = yes],[
- ])
- AM_CONDITIONAL(ENABLE_PLUGINS,[test "$enable_plugins" = yes])
- 
--with_dbus=no
--AS_IF([test "$enable_plugins" != no],[
-+AC_ARG_WITH([dbus], [AS_HELP_STRING([--with-dbus], [build with dbus support])],
-+            [],
-+            [with_dbus=yes])
-+
-+AS_IF([test "$with_dbus" != no],[
-   PKG_CHECK_MODULES([DBUS],
-     [dbus-1 >= 1.3],
--    [AC_DEFINE(DBUS, 1, [Build with dbus support?]) with_dbus=yes],
--    [with_dbus=no])
-+    [AC_DEFINE(DBUS, 1, [Build with dbus support?])],
-+    [AC_MSG_ERROR([dbus not present (--without-dbus to disable)])])
-   AC_SUBST(DBUS_CFLAGS)
-   AC_SUBST(DBUS_LIBS)
- ])
--- 
-2.11.0
-
diff --git a/poky/meta/recipes-devtools/rpm/files/0001-rpm-rpmio.c-restrict-virtual-memory-usage-if-limit-s.patch b/poky/meta/recipes-devtools/rpm/files/0001-rpm-rpmio.c-restrict-virtual-memory-usage-if-limit-s.patch
new file mode 100644
index 0000000..6454785
--- /dev/null
+++ b/poky/meta/recipes-devtools/rpm/files/0001-rpm-rpmio.c-restrict-virtual-memory-usage-if-limit-s.patch
@@ -0,0 +1,65 @@
+From 0066b862bb3a09f39295abd5d972a53ac8dc1555 Mon Sep 17 00:00:00 2001
+From: Peter Bergin <peter@berginkonsult.se>
+Date: Wed, 19 Sep 2018 15:12:31 +0200
+Subject: [PATCH] rpm/rpmio.c: restrict virtual memory usage if limit set
+
+A solution to avoid OOM situation when the virtual memory is restricted
+for a user (ulimit -v). As the lzopen_internal function is run in parallel
+one instance per CPU thread the available virtual memory is limited per
+CPU thread.
+
+Upstream-Status: Pending [merge of multithreading patches to upstream]
+
+Signed-off-by: Peter Bergin <peter@berginkonsult.se>
+---
+ rpmio/rpmio.c | 34 ++++++++++++++++++++++++++++++++++
+ 1 file changed, 34 insertions(+)
+
+diff --git a/rpmio/rpmio.c b/rpmio/rpmio.c
+index e051c98..b3c56b6 100644
+--- a/rpmio/rpmio.c
++++ b/rpmio/rpmio.c
+@@ -845,6 +845,40 @@ static LZFILE *lzopen_internal(const char *mode, int fd, int xz)
+ 		}
+ #endif
+ 
++		struct rlimit virtual_memory;
++		getrlimit(RLIMIT_AS, &virtual_memory);
++		if (virtual_memory.rlim_cur != RLIM_INFINITY) {
++			const uint64_t virtual_memlimit = virtual_memory.rlim_cur;
++			const uint64_t virtual_memlimit_per_cpu_thread =
++				virtual_memlimit / lzma_cputhreads();
++			uint64_t memory_usage_virt;
++			rpmlog(RPMLOG_NOTICE, "XZ: virtual memory restricted to %lu and "
++			       "per CPU thread %lu\n", virtual_memlimit, virtual_memlimit_per_cpu_thread);
++			/* keep reducing the number of compression threads until memory
++			   usage falls below the limit per CPU thread*/
++			while ((memory_usage_virt = lzma_stream_encoder_mt_memusage(&mt_options)) >
++			       virtual_memlimit_per_cpu_thread) {
++				/* If number of threads goes down to zero lzma_stream_encoder will
++				 * will return UINT64_MAX. We must check here to avoid an infinite loop.
++				 * If we get into situation that one thread requires more virtual memory
++				 * than available we set one thread, print error message and try anyway. */
++				if (--mt_options.threads == 0) {
++					mt_options.threads = 1;
++					rpmlog(RPMLOG_WARNING,
++					       "XZ: Could not adjust number of threads to get below "
++					       "virtual memory limit %lu. usage %lu\n",
++					       virtual_memlimit_per_cpu_thread, memory_usage_virt);
++					break;
++				}
++			}
++			if (threads != (int)mt_options.threads)
++				rpmlog(RPMLOG_NOTICE,
++				       "XZ: Adjusted the number of threads from %d to %d to not "
++				       "exceed the memory usage limit of %lu bytes\n",
++				       threads, mt_options.threads, virtual_memlimit);
++
++		}
++
+ 		ret = lzma_stream_encoder_mt(&lzfile->strm, &mt_options);
+ 	    }
+ #endif
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/rpm/files/0002-Optimize-rpmSetCloseOnExec.patch b/poky/meta/recipes-devtools/rpm/files/0002-Optimize-rpmSetCloseOnExec.patch
deleted file mode 100644
index a27f8e6..0000000
--- a/poky/meta/recipes-devtools/rpm/files/0002-Optimize-rpmSetCloseOnExec.patch
+++ /dev/null
@@ -1,100 +0,0 @@
-From 5e6f05cd8dad6c1ee6bd1e6e43f176976c9c3416 Mon Sep 17 00:00:00 2001
-From: Kir Kolyshkin <kolyshkin@gmail.com>
-Date: Tue, 29 May 2018 17:52:56 -0700
-Subject: [PATCH 2/3] Optimize rpmSetCloseOnExec
-
-In case maximum number of open files limit is set too high, both
-luaext/Pexec() and lib/doScriptExec() spend way too much time
-trying to set FD_CLOEXEC flag for all those file descriptors,
-resulting in severe increase of time it takes to execute say
-rpm or dnf.
-
-This becomes increasingly noticeable when running with e.g. under
-Docker, the reason being:
-
-> $ docker run fedora ulimit -n
-> 1048576
-
-One obvious fix is to use procfs to get the actual list of opened fds
-and iterate over it. My quick-n-dirty benchmark shows the /proc approach
-is about 10x faster than iterating through a list of just 1024 fds,
-so it's an improvement even for default ulimit values.
-
-Note that the old method is still used in case /proc is not available.
-
-While at it,
-
- 1. fix the function by making sure we modify (rather than set)
-    the existing flags. As the only known flag is FD_CLOEXEC,
-    this change is currently purely aesthetical, but in case
-    other flags will appear it will become a real bug fix.
-
- 2. get rid of magic number 3; use STDERR_FILENO
-
-Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
-
-Fixes #444
-
-Upstream-Status: Accepted [https://github.com/rpm-software-management/rpm/pull/444]
-Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
----
- rpmio/rpmio.c | 43 ++++++++++++++++++++++++++++++++++---------
- 1 file changed, 34 insertions(+), 9 deletions(-)
-
-diff --git a/rpmio/rpmio.c b/rpmio/rpmio.c
-index ea111d2ec..55351c221 100644
---- a/rpmio/rpmio.c
-+++ b/rpmio/rpmio.c
-@@ -1760,18 +1760,43 @@ DIGEST_CTX fdDupDigest(FD_t fd, int id)
-     return ctx;
- }
- 
-+static void set_cloexec(int fd)
-+{
-+	int flags = fcntl(fd, F_GETFD);
-+
-+	if (flags == -1 || (flags & FD_CLOEXEC))
-+		return;
-+
-+	fcntl(fd, F_SETFD, flags | FD_CLOEXEC);
-+}
-+
- void rpmSetCloseOnExec(void)
- {
--	int flag, fdno, open_max;
-+	const int min_fd = STDERR_FILENO; /* don't touch stdin/out/err */
-+	int fd;
-+
-+	DIR *dir = opendir("/proc/self/fd");
-+	if (dir == NULL) { /* /proc not available */
-+		/* iterate over all possible fds, might be slow */
-+		int open_max = sysconf(_SC_OPEN_MAX);
-+		if (open_max == -1)
-+			open_max = 1024;
- 
--	open_max = sysconf(_SC_OPEN_MAX);
--	if (open_max == -1) {
--		open_max = 1024;
-+		for (fd = min_fd + 1; fd < open_max; fd++)
-+			set_cloexec(fd);
-+
-+		return;
- 	}
--	for (fdno = 3; fdno < open_max; fdno++) {
--		flag = fcntl(fdno, F_GETFD);
--		if (flag == -1 || (flag & FD_CLOEXEC))
--			continue;
--		fcntl(fdno, F_SETFD, FD_CLOEXEC);
-+
-+	/* iterate over fds obtained from /proc */
-+	struct dirent *entry;
-+	while ((entry = readdir(dir)) != NULL) {
-+		fd = atoi(entry->d_name);
-+		if (fd > min_fd)
-+			set_cloexec(fd);
- 	}
-+
-+	closedir(dir);
-+
-+	return;
- }
diff --git a/poky/meta/recipes-devtools/rpm/files/0003-rpmSetCloseOnExec-use-getrlimit.patch b/poky/meta/recipes-devtools/rpm/files/0003-rpmSetCloseOnExec-use-getrlimit.patch
deleted file mode 100644
index 389b41b..0000000
--- a/poky/meta/recipes-devtools/rpm/files/0003-rpmSetCloseOnExec-use-getrlimit.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-From 307e28b4cb08b05bc044482058eeebc9f59bb9a9 Mon Sep 17 00:00:00 2001
-From: Kir Kolyshkin <kolyshkin@gmail.com>
-Date: Tue, 29 May 2018 18:09:27 -0700
-Subject: [PATCH 3/3] rpmSetCloseOnExec: use getrlimit()
-
-In case /proc is not available to get the actual list of opened fds,
-we fall back to iterating through the list of all possible fds.
-
-It is possible that during the course of the program execution the limit
-on number of open file descriptors might be lowered, so using the
-current limit, as returned by sysconf(_SC_OPEN_MAX), might omit some
-fds. Therefore, it is better to use rlim_max from the structure
-filled in by gertlimit(RLIMIT_NOFILE) to make sure we're checking
-all fds.
-
-This slows down the function, but only in the case /proc is not
-available, which should be rare in practice.
-
-Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
-Upstream-Status: Accepted [https://github.com/rpm-software-management/rpm/pull/444]
-Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
----
- rpmio/rpmio.c | 10 +++++++++-
- 1 file changed, 9 insertions(+), 1 deletion(-)
-
-diff --git a/rpmio/rpmio.c b/rpmio/rpmio.c
-index 55351c221..e051c9863 100644
---- a/rpmio/rpmio.c
-+++ b/rpmio/rpmio.c
-@@ -10,6 +10,7 @@
- #include <sys/personality.h>
- #endif
- #include <sys/utsname.h>
-+#include <sys/resource.h>
- 
- #include <rpm/rpmlog.h>
- #include <rpm/rpmmacro.h>
-@@ -1778,7 +1779,14 @@ void rpmSetCloseOnExec(void)
- 	DIR *dir = opendir("/proc/self/fd");
- 	if (dir == NULL) { /* /proc not available */
- 		/* iterate over all possible fds, might be slow */
--		int open_max = sysconf(_SC_OPEN_MAX);
-+		struct rlimit rl;
-+		int open_max;
-+
-+		if (getrlimit(RLIMIT_NOFILE, &rl) == 0 && rl.rlim_max != RLIM_INFINITY)
-+			open_max = rl.rlim_max;
-+		else
-+			open_max = sysconf(_SC_OPEN_MAX);
-+
- 		if (open_max == -1)
- 			open_max = 1024;
- 
diff --git a/poky/meta/recipes-devtools/rpm/files/0004-build-pack.c-remove-static-local-variables-from-buil.patch b/poky/meta/recipes-devtools/rpm/files/0004-build-pack.c-remove-static-local-variables-from-buil.patch
index 8989dce..652e30b 100644
--- a/poky/meta/recipes-devtools/rpm/files/0004-build-pack.c-remove-static-local-variables-from-buil.patch
+++ b/poky/meta/recipes-devtools/rpm/files/0004-build-pack.c-remove-static-local-variables-from-buil.patch
@@ -1,8 +1,8 @@
-From 8ce9fbab2990609bdace457e146160334e931c89 Mon Sep 17 00:00:00 2001
+From 792693bb90768cfde4898e8dd31ee1b5de803d2f Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Thu, 8 Jun 2017 17:08:09 +0300
-Subject: [PATCH 14/15] build/pack.c: remove static local variables from
- buildHost() and getBuildTime()
+Subject: [PATCH] build/pack.c: remove static local variables from buildHost()
+ and getBuildTime()
 
 Their use is causing difficult to diagnoze data races when building multiple
 packages in parallel, and is a bad idea in general, as it also makes it more
@@ -20,7 +20,7 @@
  3 files changed, 74 insertions(+), 72 deletions(-)
 
 diff --git a/build/build.c b/build/build.c
-index 81152e53e..6001f9e52 100644
+index 13c3df2..b154f08 100644
 --- a/build/build.c
 +++ b/build/build.c
 @@ -6,6 +6,8 @@
@@ -99,7 +99,7 @@
  	if (((what & RPMBUILD_PACKAGESOURCE) && !test) &&
 -	    (rc = packageSources(spec, &cookie)))
 +	    (rc = packageSources(spec, &cookie, buildTime, host)))
- 		return rc;
+ 		goto exit;
  
  	if (((what & RPMBUILD_PACKAGEBINARY) && !test) &&
 -	    (rc = packageBinaries(spec, cookie, (didBuild == 0))))
@@ -116,7 +116,7 @@
      spec->rootDir = NULL;
      if (rc != RPMRC_OK && rpmlogGetNrecs() > 0) {
 diff --git a/build/pack.c b/build/pack.c
-index df15876ff..17a4b0905 100644
+index df15876..17a4b09 100644
 --- a/build/pack.c
 +++ b/build/pack.c
 @@ -6,8 +6,6 @@
@@ -305,7 +305,7 @@
  	/* Do check SRPM package if enabled */
  	if (rc == RPMRC_OK && pkgcheck[0] != ' ') {
 diff --git a/build/rpmbuild_internal.h b/build/rpmbuild_internal.h
-index 439b7d3b5..07e8338ad 100644
+index 439b7d3..07e8338 100644
 --- a/build/rpmbuild_internal.h
 +++ b/build/rpmbuild_internal.h
 @@ -427,19 +427,23 @@ rpmRC processSourceFiles(rpmSpec spec, rpmBuildPkgFlags pkgFlags);
@@ -334,6 +334,3 @@
  
  RPM_GNUC_INTERNAL
  int addLangTag(rpmSpec spec, Header h, rpmTagVal tag,
--- 
-2.14.2
-
diff --git a/poky/meta/recipes-devtools/rpm/rpm_4.14.1.bb b/poky/meta/recipes-devtools/rpm/rpm_4.14.1.bb
deleted file mode 100644
index 1a03a0f..0000000
--- a/poky/meta/recipes-devtools/rpm/rpm_4.14.1.bb
+++ /dev/null
@@ -1,152 +0,0 @@
-SUMMARY = "The RPM package management system"
-DESCRIPTION = "The RPM Package Manager (RPM) is a powerful command line driven \
-package management system capable of installing, uninstalling, \
-verifying, querying, and updating software packages. Each software \
-package consists of an archive of files along with information about \
-the package like its version, a description, etc."
-
-SUMMARY_${PN}-dev = "Development files for manipulating RPM packages"
-DESCRIPTION_${PN}-dev = "This package contains the RPM C library and header files. These \
-development files will simplify the process of writing programs that \
-manipulate RPM packages and databases. These files are intended to \
-simplify the process of creating graphical package managers or any \
-other tools that need an intimate knowledge of RPM packages in order \
-to function."
-
-SUMMARY_python3-rpm = "Python bindings for apps which will manupulate RPM packages"
-DESCRIPTION_python3-rpm = "The python3-rpm package contains a module that permits applications \
-written in the Python programming language to use the interface \
-supplied by the RPM Package Manager libraries."
-
-HOMEPAGE = "http://www.rpm.org"
-
-# libraries are also LGPL - how to express this?
-LICENSE = "GPL-2.0"
-LIC_FILES_CHKSUM = "file://COPYING;md5=c0bf017c0fd1920e6158a333acabfd4a"
-
-SRC_URI = "git://github.com/rpm-software-management/rpm;branch=rpm-4.14.x \
-           file://0001-Do-not-add-an-unsatisfiable-dependency-when-building.patch \
-           file://0001-Do-not-read-config-files-from-HOME.patch \
-           file://0001-When-cross-installing-execute-package-scriptlets-wit.patch \
-           file://0001-Do-not-reset-the-PATH-environment-variable-before-ru.patch \
-           file://0002-Add-support-for-prefixing-etc-from-RPM_ETCCONFIGDIR-.patch \
-           file://0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch \
-           file://0001-Fix-build-with-musl-C-library.patch \
-           file://0001-Add-a-color-setting-for-mips64_n32-binaries.patch \
-           file://0011-Do-not-require-that-ELF-binaries-are-executable-to-b.patch \
-           file://0001-Split-binary-package-building-into-a-separate-functi.patch \
-           file://0002-Run-binary-package-creation-via-thread-pools.patch \
-           file://0003-rpmstrpool.c-make-operations-over-string-pools-threa.patch \
-           file://0004-build-pack.c-remove-static-local-variables-from-buil.patch \
-           file://0001-perl-disable-auto-reqs.patch \
-           file://0001-configure.ac-add-option-for-dbus.patch \
-           file://0001-Factor-out-and-unify-setting-CLOEXEC.patch \
-           file://0002-Optimize-rpmSetCloseOnExec.patch \
-           file://0003-rpmSetCloseOnExec-use-getrlimit.patch \
-           "
-
-PE = "1"
-SRCREV = "bfee1410af51c1cc9724791fb8d985260a62102b"
-
-S = "${WORKDIR}/git"
-
-DEPENDS = "nss libarchive db file popt xz bzip2 dbus elfutils python3"
-DEPENDS_append_class-native = " file-replacement-native bzip2-replacement-native"
-
-inherit autotools gettext pkgconfig python3native
-export PYTHON_ABI
-
-# OE-core patches autoreconf to additionally run gnu-configize, which fails with this recipe
-EXTRA_AUTORECONF_append = " --exclude=gnu-configize"
-
-EXTRA_OECONF_append = " --without-lua --enable-python"
-EXTRA_OECONF_append_libc-musl = " --disable-nls"
-
-# --sysconfdir prevents rpm from attempting to access machine-specific configuration in sysroot/etc; we need to have it in rootfs
-#
-# --localstatedir prevents rpm from writing its database to native sysroot when building images
-#
-# Disable dbus for native, so that rpm doesn't attempt to inhibit shutdown via session dbus even when plugins support is enabled.
-# Also disable plugins by default for native.
-EXTRA_OECONF_append_class-native = " --sysconfdir=/etc --localstatedir=/var --without-dbus --disable-plugins"
-EXTRA_OECONF_append_class-nativesdk = " --sysconfdir=/etc --localstatedir=/var --without-dbus --disable-plugins"
-
-BBCLASSEXTEND = "native nativesdk"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[imaevm] = "--with-imaevm,,ima-evm-utils"
-
-# Direct rpm-native to read configuration from our sysroot, not the one it was compiled in
-# libmagic also has sysroot path contamination, so override it
-
-WRAPPER_TOOLS = " \
-   ${bindir}/rpm \
-   ${bindir}/rpm2archive \
-   ${bindir}/rpm2cpio \
-   ${bindir}/rpmbuild \
-   ${bindir}/rpmdb \
-   ${bindir}/rpmgraph \
-   ${bindir}/rpmkeys \
-   ${bindir}/rpmsign \
-   ${bindir}/rpmspec \
-   ${libdir}/rpm/rpmdeps \
-"
-
-do_install_append_class-native() {
-        for tool in ${WRAPPER_TOOLS}; do
-                create_wrapper ${D}$tool \
-                        RPM_CONFIGDIR=${STAGING_LIBDIR_NATIVE}/rpm \
-                        RPM_ETCCONFIGDIR=${STAGING_DIR_NATIVE} \
-                        MAGIC=${STAGING_DIR_NATIVE}${datadir_native}/misc/magic.mgc \
-                        RPM_NO_CHROOT_FOR_SCRIPTS=1
-        done
-}
-
-do_install_append_class-nativesdk() {
-        for tool in ${WRAPPER_TOOLS}; do
-                create_wrapper ${D}$tool \
-                        RPM_CONFIGDIR='`dirname $''realpath`'/${@os.path.relpath(d.getVar('libdir', True), d.getVar('bindir', True))}/rpm \
-                        RPM_ETCCONFIGDIR='$'{RPM_ETCCONFIGDIR-'`dirname $''realpath`'/${@os.path.relpath(d.getVar('sysconfdir', True), d.getVar('bindir', True))}/..} \
-                        MAGIC='`dirname $''realpath`'/${@os.path.relpath(d.getVar('datadir', True), d.getVar('bindir', True))}/misc/magic.mgc \
-                        RPM_NO_CHROOT_FOR_SCRIPTS=1
-        done
-
-        rm -rf ${D}/var
-}
-
-# Rpm's make install creates var/tmp which clashes with base-files packaging
-do_install_append_class-target() {
-    rm -rf ${D}/var
-}
-
-do_install_append () {
-	sed -i -e 's:${HOSTTOOLS_DIR}/::g' \
-	    ${D}/${libdir}/rpm/macros
-
-	sed -i -e 's|/usr/bin/python|${USRBINPATH}/env ${PYTHON_PN}|' \
-	    ${D}${libdir}/rpm/pythondistdeps.py \
-	    ${D}${libdir}/rpm/python-macro-helper
-}
-
-FILES_${PN} += "${libdir}/rpm-plugins/*.so \
-               "
-
-FILES_${PN}-dev += "${libdir}/rpm-plugins/*.la \
-                    "
-
-PACKAGES += "python3-rpm"
-PROVIDES += "python3-rpm"
-FILES_python3-rpm = "${PYTHON_SITEPACKAGES_DIR}/rpm/*"
-
-# rpm 5.x was packaging the rpm build tools separately
-RPROVIDES_${PN} += "rpm-build"
-
-RDEPENDS_${PN} = "bash perl python3-core"
-
-PACKAGE_PREPROCESS_FUNCS += "rpm_package_preprocess"
-
-# Do not specify a sysroot when compiling on a target.
-rpm_package_preprocess () {
-	sed -i -e 's:--sysroot[^ ]*::g' \
-	    ${PKGD}/${libdir}/rpm/macros
-}
diff --git a/poky/meta/recipes-devtools/rpm/rpm_4.14.2.bb b/poky/meta/recipes-devtools/rpm/rpm_4.14.2.bb
new file mode 100644
index 0000000..200fe4d
--- /dev/null
+++ b/poky/meta/recipes-devtools/rpm/rpm_4.14.2.bb
@@ -0,0 +1,151 @@
+SUMMARY = "The RPM package management system"
+DESCRIPTION = "The RPM Package Manager (RPM) is a powerful command line driven \
+package management system capable of installing, uninstalling, \
+verifying, querying, and updating software packages. Each software \
+package consists of an archive of files along with information about \
+the package like its version, a description, etc."
+
+SUMMARY_${PN}-dev = "Development files for manipulating RPM packages"
+DESCRIPTION_${PN}-dev = "This package contains the RPM C library and header files. These \
+development files will simplify the process of writing programs that \
+manipulate RPM packages and databases. These files are intended to \
+simplify the process of creating graphical package managers or any \
+other tools that need an intimate knowledge of RPM packages in order \
+to function."
+
+SUMMARY_python3-rpm = "Python bindings for apps which will manupulate RPM packages"
+DESCRIPTION_python3-rpm = "The python3-rpm package contains a module that permits applications \
+written in the Python programming language to use the interface \
+supplied by the RPM Package Manager libraries."
+
+HOMEPAGE = "http://www.rpm.org"
+
+# libraries are also LGPL - how to express this?
+LICENSE = "GPL-2.0"
+LIC_FILES_CHKSUM = "file://COPYING;md5=c0bf017c0fd1920e6158a333acabfd4a"
+
+SRC_URI = "git://github.com/rpm-software-management/rpm;branch=rpm-4.14.x \
+           file://0001-Do-not-add-an-unsatisfiable-dependency-when-building.patch \
+           file://0001-Do-not-read-config-files-from-HOME.patch \
+           file://0001-When-cross-installing-execute-package-scriptlets-wit.patch \
+           file://0001-Do-not-reset-the-PATH-environment-variable-before-ru.patch \
+           file://0002-Add-support-for-prefixing-etc-from-RPM_ETCCONFIGDIR-.patch \
+           file://0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch \
+           file://0001-Fix-build-with-musl-C-library.patch \
+           file://0001-Add-a-color-setting-for-mips64_n32-binaries.patch \
+           file://0011-Do-not-require-that-ELF-binaries-are-executable-to-b.patch \
+           file://0001-Split-binary-package-building-into-a-separate-functi.patch \
+           file://0002-Run-binary-package-creation-via-thread-pools.patch \
+           file://0003-rpmstrpool.c-make-operations-over-string-pools-threa.patch \
+           file://0004-build-pack.c-remove-static-local-variables-from-buil.patch \
+           file://0001-perl-disable-auto-reqs.patch \
+           file://0001-rpm-rpmio.c-restrict-virtual-memory-usage-if-limit-s.patch \
+           "
+
+PE = "1"
+SRCREV = "753f6941dc32e94047b7cfe713ddd604a810b4db"
+
+S = "${WORKDIR}/git"
+
+DEPENDS = "nss libarchive db file popt xz bzip2 dbus elfutils python3"
+DEPENDS_append_class-native = " file-replacement-native bzip2-replacement-native"
+
+inherit autotools gettext pkgconfig python3native
+export PYTHON_ABI
+
+# OE-core patches autoreconf to additionally run gnu-configize, which fails with this recipe
+EXTRA_AUTORECONF_append = " --exclude=gnu-configize"
+
+EXTRA_OECONF_append = " --without-lua --enable-python"
+EXTRA_OECONF_append_libc-musl = " --disable-nls"
+
+# --sysconfdir prevents rpm from attempting to access machine-specific configuration in sysroot/etc; we need to have it in rootfs
+#
+# --localstatedir prevents rpm from writing its database to native sysroot when building images
+#
+# Disable dbus for native, so that rpm doesn't attempt to inhibit shutdown via session dbus even when plugins support is enabled.
+# Also disable plugins by default for native.
+EXTRA_OECONF_append_class-native = " --sysconfdir=/etc --localstatedir=/var --disable-plugins"
+EXTRA_OECONF_append_class-nativesdk = " --sysconfdir=/etc --localstatedir=/var --disable-plugins"
+
+BBCLASSEXTEND = "native nativesdk"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[imaevm] = "--with-imaevm,,ima-evm-utils"
+
+ASNEEDED = ""
+
+# Direct rpm-native to read configuration from our sysroot, not the one it was compiled in
+# libmagic also has sysroot path contamination, so override it
+
+WRAPPER_TOOLS = " \
+   ${bindir}/rpm \
+   ${bindir}/rpm2archive \
+   ${bindir}/rpm2cpio \
+   ${bindir}/rpmbuild \
+   ${bindir}/rpmdb \
+   ${bindir}/rpmgraph \
+   ${bindir}/rpmkeys \
+   ${bindir}/rpmsign \
+   ${bindir}/rpmspec \
+   ${libdir}/rpm/rpmdeps \
+"
+
+do_install_append_class-native() {
+        for tool in ${WRAPPER_TOOLS}; do
+                create_wrapper ${D}$tool \
+                        RPM_CONFIGDIR=${STAGING_LIBDIR_NATIVE}/rpm \
+                        RPM_ETCCONFIGDIR=${STAGING_DIR_NATIVE} \
+                        MAGIC=${STAGING_DIR_NATIVE}${datadir_native}/misc/magic.mgc \
+                        RPM_NO_CHROOT_FOR_SCRIPTS=1
+        done
+}
+
+do_install_append_class-nativesdk() {
+        for tool in ${WRAPPER_TOOLS}; do
+                create_wrapper ${D}$tool \
+                        RPM_CONFIGDIR='`dirname $''realpath`'/${@os.path.relpath(d.getVar('libdir', True), d.getVar('bindir', True))}/rpm \
+                        RPM_ETCCONFIGDIR='$'{RPM_ETCCONFIGDIR-'`dirname $''realpath`'/${@os.path.relpath(d.getVar('sysconfdir', True), d.getVar('bindir', True))}/..} \
+                        MAGIC='`dirname $''realpath`'/${@os.path.relpath(d.getVar('datadir', True), d.getVar('bindir', True))}/misc/magic.mgc \
+                        RPM_NO_CHROOT_FOR_SCRIPTS=1
+        done
+
+        rm -rf ${D}/var
+}
+
+# Rpm's make install creates var/tmp which clashes with base-files packaging
+do_install_append_class-target() {
+    rm -rf ${D}/var
+}
+
+do_install_append () {
+	sed -i -e 's:${HOSTTOOLS_DIR}/::g' \
+	    ${D}/${libdir}/rpm/macros
+
+	sed -i -e 's|/usr/bin/python|${USRBINPATH}/env ${PYTHON_PN}|' \
+	    ${D}${libdir}/rpm/pythondistdeps.py \
+	    ${D}${libdir}/rpm/python-macro-helper
+}
+
+FILES_${PN} += "${libdir}/rpm-plugins/*.so \
+               "
+
+FILES_${PN}-dev += "${libdir}/rpm-plugins/*.la \
+                    "
+
+PACKAGES += "python3-rpm"
+PROVIDES += "python3-rpm"
+FILES_python3-rpm = "${PYTHON_SITEPACKAGES_DIR}/rpm/*"
+
+# rpm 5.x was packaging the rpm build tools separately
+RPROVIDES_${PN} += "rpm-build"
+
+RDEPENDS_${PN} = "bash perl python3-core"
+
+PACKAGE_PREPROCESS_FUNCS += "rpm_package_preprocess"
+
+# Do not specify a sysroot when compiling on a target.
+rpm_package_preprocess () {
+	sed -i -e 's:--sysroot[^ ]*::g' \
+	    ${PKGD}/${libdir}/rpm/macros
+}
diff --git a/poky/meta/recipes-devtools/rsync/rsync.inc b/poky/meta/recipes-devtools/rsync/rsync.inc
deleted file mode 100644
index 26c023a..0000000
--- a/poky/meta/recipes-devtools/rsync/rsync.inc
+++ /dev/null
@@ -1,20 +0,0 @@
-SUMMARY = "File synchronization tool"
-HOMEPAGE = "http://rsync.samba.org/"
-BUGTRACKER = "http://rsync.samba.org/bugzilla.html"
-SECTION = "console/network"
-
-DEPENDS = "popt"
-
-SRC_URI = "https://download.samba.org/pub/${BPN}/src/${BP}.tar.gz \
-           file://rsyncd.conf"
-
-inherit autotools
-
-do_install_append() {
-	install -d ${D}${sysconfdir}
-	install -m 0644 ${WORKDIR}/rsyncd.conf ${D}${sysconfdir}
-}
-
-EXTRA_OEMAKE='STRIP=""'
-
-PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
diff --git a/poky/meta/recipes-devtools/rsync/rsync_3.1.3.bb b/poky/meta/recipes-devtools/rsync/rsync_3.1.3.bb
index 84a0258..29cb231 100644
--- a/poky/meta/recipes-devtools/rsync/rsync_3.1.3.bb
+++ b/poky/meta/recipes-devtools/rsync/rsync_3.1.3.bb
@@ -1,24 +1,37 @@
-require rsync.inc
-
-SRC_URI += "file://makefile-no-rebuild.patch"
-
-SRC_URI[md5sum] = "1581a588fde9d89f6bc6201e8129afaf"
-SRC_URI[sha256sum] = "55cc554efec5fdaad70de921cd5a5eeb6c29a95524c715f3bbf849235b0800c0"
-
+SUMMARY = "File synchronization tool"
+HOMEPAGE = "http://rsync.samba.org/"
+BUGTRACKER = "http://rsync.samba.org/bugzilla.html"
+SECTION = "console/network"
 # GPLv2+ (<< 3.0.0), GPLv3+ (>= 3.0.0)
 LICENSE = "GPLv3+"
 LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
 
+DEPENDS = "popt"
+
+SRC_URI = "https://download.samba.org/pub/${BPN}/src/${BP}.tar.gz \
+           file://rsyncd.conf \
+           file://makefile-no-rebuild.patch \
+"
+
+SRC_URI[md5sum] = "1581a588fde9d89f6bc6201e8129afaf"
+SRC_URI[sha256sum] = "55cc554efec5fdaad70de921cd5a5eeb6c29a95524c715f3bbf849235b0800c0"
+
+inherit autotools
+
 PACKAGECONFIG ??= "acl attr \
     ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} \
 "
+
 PACKAGECONFIG[acl] = "--enable-acl-support,--disable-acl-support,acl,"
 PACKAGECONFIG[attr] = "--enable-xattr-support,--disable-xattr-support,attr,"
+PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
 
 # By default, if crosscompiling, rsync disables a number of
 # capabilities, hardlinking symlinks and special files (i.e. devices)
 CACHED_CONFIGUREVARS += "rsync_cv_can_hardlink_special=yes rsync_cv_can_hardlink_symlink=yes"
 
+EXTRA_OEMAKE = 'STRIP=""'
+
 # rsync 3.0 uses configure.sh instead of configure, and
 # makefile checks the existence of configure.sh
 do_configure_prepend () {
@@ -29,4 +42,9 @@
 	cp -f ${S}/configure ${S}/configure.sh
 }
 
+do_install_append() {
+	install -d ${D}${sysconfdir}
+	install -m 0644 ${WORKDIR}/rsyncd.conf ${D}${sysconfdir}
+}
+
 BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-devtools/ruby/ruby.inc b/poky/meta/recipes-devtools/ruby/ruby.inc
index fd3911b..5a5bef2 100644
--- a/poky/meta/recipes-devtools/ruby/ruby.inc
+++ b/poky/meta/recipes-devtools/ruby/ruby.inc
@@ -11,7 +11,7 @@
     file://COPYING;md5=340948e1882e579731841bf49cdc22c1 \
     file://BSDL;md5=19aaf65c88a40b508d17ae4be539c4b5\
     file://GPL;md5=b234ee4d69f5fce4486a80fdaf4a4263\
-    file://LEGAL;md5=8f871f3f03732c018a5fa9b185958231 \
+    file://LEGAL;md5=23a79bb4c1a40f6cc9bcb6f4e7c39799 \
 "
 
 DEPENDS = "ruby-native zlib openssl tcl libyaml gdbm readline"
diff --git a/poky/meta/recipes-devtools/ruby/ruby/CVE-2018-1000073.patch b/poky/meta/recipes-devtools/ruby/ruby/CVE-2018-1000073.patch
new file mode 100644
index 0000000..22fa1b5
--- /dev/null
+++ b/poky/meta/recipes-devtools/ruby/ruby/CVE-2018-1000073.patch
@@ -0,0 +1,34 @@
+From 1b931fc03b819b9a0214be3eaca844ef534175e2 Mon Sep 17 00:00:00 2001
+From: Jonathan Claudius <jclaudius@mozilla.com>
+Date: Wed, 7 Feb 2018 23:54:52 -0500
+Subject: [PATCH] Non-working patch for deducing symlinked base-dirs
+
+---
+CVE: CVE-2018-1000073
+
+Fixed in ruby 2.7.6.
+
+Upstream-Status: Backport [github.com/rubygems/rubygems/commit/1b931fc...]
+
+Signed-off-by: Joe Slater <joe.slater@windriver.com>
+
+---
+ lib/rubygems/package.rb |    2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/lib/rubygems/package.rb b/lib/rubygems/package.rb
+index dede959..cb9c74a 100644
+--- a/lib/rubygems/package.rb
++++ b/lib/rubygems/package.rb
+@@ -421,6 +421,8 @@ EOM
+     destination_dir = File.expand_path destination_dir
+ 
+     destination = File.join destination_dir, filename
++    destination = File.realpath destination if
++      File.respond_to? :realpath
+     destination = File.expand_path destination
+ 
+     raise Gem::Package::PathError.new(destination, destination_dir) unless
+-- 
+1.7.9.5
+
diff --git a/poky/meta/recipes-devtools/ruby/ruby_2.5.0.bb b/poky/meta/recipes-devtools/ruby/ruby_2.5.0.bb
deleted file mode 100644
index 1ac7f2a..0000000
--- a/poky/meta/recipes-devtools/ruby/ruby_2.5.0.bb
+++ /dev/null
@@ -1,49 +0,0 @@
-require ruby.inc
-
-SRC_URI += " \
-           file://ruby-CVE-2017-9226.patch \
-           file://ruby-CVE-2017-9228.patch \
-           "
-
-SRC_URI[md5sum] = "f4711f856fe14de222b9da3d3b8efa89"
-SRC_URI[sha256sum] = "46e6f3630f1888eb653b15fa811d77b5b1df6fd7a3af436b343cfe4f4503f2ab"
-
-# it's unknown to configure script, but then passed to extconf.rb
-# maybe it's not really needed as we're hardcoding the result with
-# 0001-socket-extconf-hardcode-wide-getaddr-info-test-outco.patch
-UNKNOWN_CONFIGURE_WHITELIST += "--enable-wide-getaddrinfo"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG += "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}"
-
-PACKAGECONFIG[valgrind] = "--with-valgrind=yes, --with-valgrind=no, valgrind"
-PACKAGECONFIG[gmp] = "--with-gmp=yes, --with-gmp=no, gmp"
-PACKAGECONFIG[ipv6] = ",--enable-wide-getaddrinfo,"
-
-EXTRA_AUTORECONF += "--exclude=aclocal"
-
-EXTRA_OECONF = "\
-    --disable-versioned-paths \
-    --disable-rpath \
-    --disable-dtrace \
-    --enable-shared \
-    --enable-load-relative \
-"
-
-do_install() {
-    oe_runmake 'DESTDIR=${D}' install
-}
-
-PACKAGES =+ "${PN}-ri-docs ${PN}-rdoc"
-
-SUMMARY_${PN}-ri-docs = "ri (Ruby Interactive) documentation for the Ruby standard library"
-RDEPENDS_${PN}-ri-docs = "${PN}"
-FILES_${PN}-ri-docs += "${datadir}/ri"
-
-SUMMARY_${PN}-rdoc = "RDoc documentation generator from Ruby source"
-RDEPENDS_${PN}-rdoc = "${PN}"
-FILES_${PN}-rdoc += "${libdir}/ruby/*/rdoc ${bindir}/rdoc"
-
-FILES_${PN} += "${datadir}/rubygems"
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-devtools/ruby/ruby_2.5.1.bb b/poky/meta/recipes-devtools/ruby/ruby_2.5.1.bb
new file mode 100644
index 0000000..1197323
--- /dev/null
+++ b/poky/meta/recipes-devtools/ruby/ruby_2.5.1.bb
@@ -0,0 +1,70 @@
+require ruby.inc
+
+SRC_URI += " \
+           file://ruby-CVE-2017-9226.patch \
+           file://ruby-CVE-2017-9228.patch \
+           file://CVE-2018-1000073.patch \
+           "
+
+SRC_URI[md5sum] = "23867bc8c16c55e43b14dfe0614bcfa8"
+SRC_URI[sha256sum] = "dac81822325b79c3ba9532b048c2123357d3310b2b40024202f360251d9829b1"
+
+# it's unknown to configure script, but then passed to extconf.rb
+# maybe it's not really needed as we're hardcoding the result with
+# 0001-socket-extconf-hardcode-wide-getaddr-info-test-outco.patch
+UNKNOWN_CONFIGURE_WHITELIST += "--enable-wide-getaddrinfo"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG += "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}"
+
+PACKAGECONFIG[valgrind] = "--with-valgrind=yes, --with-valgrind=no, valgrind"
+PACKAGECONFIG[gmp] = "--with-gmp=yes, --with-gmp=no, gmp"
+PACKAGECONFIG[ipv6] = ",--enable-wide-getaddrinfo,"
+
+EXTRA_AUTORECONF += "--exclude=aclocal"
+
+EXTRA_OECONF = "\
+    --disable-versioned-paths \
+    --disable-rpath \
+    --disable-dtrace \
+    --enable-shared \
+    --enable-load-relative \
+"
+
+do_install() {
+    oe_runmake 'DESTDIR=${D}' install
+}
+
+do_install_append_class-target () {
+    # Find out rbconfig.rb from .installed.list
+    rbconfig_rb=`grep rbconfig.rb ${B}/.installed.list`
+    # Remove build host directories
+    sed -i -e 's:--sysroot=${STAGING_DIR_TARGET}::g' \
+           -e s:'--with-libtool-sysroot=${STAGING_DIR_TARGET}'::g \
+           -e 's|${DEBUG_PREFIX_MAP}||g' \
+           -e 's:${HOSTTOOLS_DIR}/::g' \
+           -e 's:${RECIPE_SYSROOT_NATIVE}::g' \
+           -e 's:${RECIPE_SYSROOT}::g' \
+           -e 's:${BASE_WORKDIR}/${MULTIMACH_TARGET_SYS}::g' \
+        ${D}$rbconfig_rb
+
+    # Find out created.rid from .installed.list
+    created_rid=`grep created.rid ${B}/.installed.list`
+    # Remove build host directories
+    sed -i -e 's:${WORKDIR}::g' ${D}$created_rid
+
+}
+
+PACKAGES =+ "${PN}-ri-docs ${PN}-rdoc"
+
+SUMMARY_${PN}-ri-docs = "ri (Ruby Interactive) documentation for the Ruby standard library"
+RDEPENDS_${PN}-ri-docs = "${PN}"
+FILES_${PN}-ri-docs += "${datadir}/ri"
+
+SUMMARY_${PN}-rdoc = "RDoc documentation generator from Ruby source"
+RDEPENDS_${PN}-rdoc = "${PN}"
+FILES_${PN}-rdoc += "${libdir}/ruby/*/rdoc ${bindir}/rdoc"
+
+FILES_${PN} += "${datadir}/rubygems"
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts b/poky/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts
index 307feb7..95eff04 100755
--- a/poky/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts
+++ b/poky/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts
@@ -6,7 +6,8 @@
 #
 
 # The following script will run all the scriptlets found in #SYSCONFDIR#/deb-postinsts,
-# #SYSCONFDIR#/ipk-postinsts or #SYSCONFDIR#/rpm-postinsts.
+# #SYSCONFDIR#/ipk-postinsts or #SYSCONFDIR#/rpm-postinsts or the package manager in
+# case available.
 
 # the order of this list is important, do not change!
 backend_list="rpm deb ipk"
@@ -14,27 +15,29 @@
 pm_installed=false
 
 for pm in $backend_list; do
-	pi_dir="#SYSCONFDIR#/$pm-postinsts"
-
-	if [ ! -d $pi_dir ]; then
-		continue
-	fi
-
 	# found the package manager, it has postinsts
 	case $pm in
 		"deb")
 			if [ -s "#LOCALSTATEDIR#/lib/dpkg/status" ]; then
 				pm_installed=true
+				break
 			fi
 			;;
 
 		"ipk")
 			if [ -s "#LOCALSTATEDIR#/lib/opkg/status" ]; then
 				pm_installed=true
+				break
 			fi
 			;;
 	esac
-	break
+
+	pi_dir="#SYSCONFDIR#/$pm-postinsts"
+
+	# found postinsts directory
+	if [ -d $pi_dir ]; then
+		break
+	fi
 done
 
 remove_rcsd_link () {
@@ -43,7 +46,7 @@
 	fi
 }
 
-if ! [ -d $pi_dir ]; then
+if ! [ -d $pi_dir ] && ! $pm_installed; then
 	remove_rcsd_link
 	exit 0
 fi
diff --git a/poky/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts.service b/poky/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts.service
index 1b71a1f..d42addf 100644
--- a/poky/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts.service
+++ b/poky/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts.service
@@ -3,7 +3,6 @@
 DefaultDependencies=no
 After=systemd-remount-fs.service systemd-tmpfiles-setup.service tmp.mount
 Before=sysinit.target
-ConditionPathExistsGlob=#SYSCONFDIR#/*-postinsts
 
 [Service]
 Type=oneshot
diff --git a/poky/meta/recipes-devtools/squashfs-tools/squashfs-tools_git.bb b/poky/meta/recipes-devtools/squashfs-tools/squashfs-tools_git.bb
index 1eb0154..2f41263 100644
--- a/poky/meta/recipes-devtools/squashfs-tools/squashfs-tools_git.bb
+++ b/poky/meta/recipes-devtools/squashfs-tools/squashfs-tools_git.bb
@@ -37,6 +37,8 @@
 	install -m 0755 unsquashfs ${D}${sbindir}/
 }
 
-ARM_INSTRUCTION_SET = "arm"
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
+ARM_INSTRUCTION_SET_armv6 = "arm"
 
 BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-devtools/strace/strace/Makefile-ptest.patch b/poky/meta/recipes-devtools/strace/strace/Makefile-ptest.patch
index a12f4c3..460b6e2 100644
--- a/poky/meta/recipes-devtools/strace/strace/Makefile-ptest.patch
+++ b/poky/meta/recipes-devtools/strace/strace/Makefile-ptest.patch
@@ -1,36 +1,31 @@
-From 0574ae9926308dcbca78bd8cd0f0f143f19cbcb5 Mon Sep 17 00:00:00 2001
+From 207fc7814bbeb0241382329215d21fd3b57066f9 Mon Sep 17 00:00:00 2001
 From: Gabriel Barbu <gabriel.barbu@enea.com>
 Date: Thu, 25 Jul 2013 15:28:33 +0200
-Subject: [PATCH 4/8] strace: Add ptest
+Subject: [PATCH] strace: Add ptest
 
 Upstream-Status: Inappropriate
 
 Signed-off-by: Gabriel Barbu <gabriel.barbu@enea.com>
 Signed-off-by: Chong Lu <Chong.Lu@windriver.com>
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
 
 ---
- configure.ac      |  2 +-
- tests/Makefile.am | 18 ++++++++++++++++++
- 2 files changed, 19 insertions(+), 1 deletion(-)
+ tests/Makefile.am | 19 +++++++++++++++++++
+ 1 file changed, 19 insertions(+)
 
-diff --git a/configure.ac b/configure.ac
-index 5f0aec4..8eaacc6 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -42,7 +42,7 @@ AC_COPYRIGHT([Copyright (c) 1999-]copyright_year[ The strace developers.])
- AC_CONFIG_SRCDIR([strace.c])
- AC_CONFIG_AUX_DIR([.])
- AC_CONFIG_HEADERS([config.h])
--AM_INIT_AUTOMAKE([foreign nostdinc dist-xz silent-rules parallel-tests 1.13])
-+AM_INIT_AUTOMAKE([foreign nostdinc dist-xz silent-rules serial-tests 1.13])
- AM_MAINTAINER_MODE
- AC_CANONICAL_HOST
- 
 diff --git a/tests/Makefile.am b/tests/Makefile.am
-index b4ba22a..5836438 100644
+index a2f3950..4fa97e2 100644
 --- a/tests/Makefile.am
 +++ b/tests/Makefile.am
-@@ -408,3 +408,21 @@ BUILT_SOURCES = ksysent.h
+@@ -34,6 +34,7 @@ SIZEOF_LONG = @SIZEOF_LONG@
+ MPERS_NAME =
+ MPERS_CC_FLAGS =
+ ARCH_MFLAGS =
++TEST_SUITE_LOG = test-suite.log
+ AM_CFLAGS = $(WARN_CFLAGS)
+ AM_CPPFLAGS = $(ARCH_MFLAGS) \
+ 	      -I$(builddir) \
+@@ -490,3 +491,21 @@ BUILT_SOURCES = ksysent.h
  CLEANFILES = ksysent.h
  
  include ../scno.am
diff --git a/poky/meta/recipes-devtools/strace/strace/disable-git-version-gen.patch b/poky/meta/recipes-devtools/strace/strace/disable-git-version-gen.patch
index 76daf3a..9e5ec11 100644
--- a/poky/meta/recipes-devtools/strace/strace/disable-git-version-gen.patch
+++ b/poky/meta/recipes-devtools/strace/strace/disable-git-version-gen.patch
@@ -1,20 +1,37 @@
-The git-version-gen script is not included in tarball releases,
-so we need to avoid attempts to call it when running autoreconf.
+From bee0680754730498485e24dd037303318c68916c Mon Sep 17 00:00:00 2001
+From: Andre McCurdy <armccurdy@gmail.com>
+Date: Mon, 18 Jan 2016 13:33:50 -0800
+Subject: [PATCH] strace: remove need for scripts
+
+git-version-gen copyright-year-gen file-date-gen are not included in
+tarball releases, so we need to avoid attempts to call them.
 
 Upstream-Status: Inappropriate [configuration]
 
 Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+
+---
+ configure.ac | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
 
 diff --git a/configure.ac b/configure.ac
-index 7004bd3..b2b03c6 100644
+index ad1d00f..96fa205 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -31,7 +31,7 @@
+@@ -32,12 +32,12 @@
  
  AC_PREREQ(2.57)
  AC_INIT([strace],
 -	m4_esyscmd([./git-version-gen .tarball-version]),
 +	m4_esyscmd_s([cat .tarball-version]),
- 	[strace-devel@lists.sourceforge.net],
+ 	[strace-devel@lists.strace.io],
  	[strace],
  	[https://strace.io])
+-m4_define([copyright_year], m4_esyscmd([./copyright-year-gen .year]))
+-m4_define([manpage_date], m4_esyscmd([./file-date-gen strace.1.in]))
++m4_define([copyright_year], m4_esyscmd_s([cat .year]))
++m4_define([manpage_date], m4_esyscmd_s([cat .strace.1.in.date]))
+ AC_COPYRIGHT([Copyright (c) 1999-]copyright_year[ The strace developers.])
+ AC_CONFIG_SRCDIR([strace.c])
+ AC_CONFIG_AUX_DIR([.])
diff --git a/poky/meta/recipes-devtools/strace/strace/more-robust-test-for-m32-mx32-compile-support.patch b/poky/meta/recipes-devtools/strace/strace/more-robust-test-for-m32-mx32-compile-support.patch
index 756cd8b..3d4913d 100644
--- a/poky/meta/recipes-devtools/strace/strace/more-robust-test-for-m32-mx32-compile-support.patch
+++ b/poky/meta/recipes-devtools/strace/strace/more-robust-test-for-m32-mx32-compile-support.patch
@@ -22,25 +22,23 @@
  m4/mpers.m4 | 2 ++
  1 file changed, 2 insertions(+)
 
-diff --git a/m4/mpers.m4 b/m4/mpers.m4
-index 1fe8a8e..d72c717 100644
---- a/m4/mpers.m4
-+++ b/m4/mpers.m4
-@@ -53,12 +53,14 @@ case "$arch" in
- 	CFLAGS="$CFLAGS CFLAG $IFLAG"
- 	AC_CACHE_CHECK([for CFLAG compile support], [st_cv_cc],
+Index: strace-4.22/m4/mpers.m4
+===================================================================
+--- strace-4.22.orig/m4/mpers.m4
++++ strace-4.22/m4/mpers.m4
+@@ -108,6 +108,7 @@ case "$arch" in
+ 	CFLAGS="$CFLAGS MPERS_CFLAGS $IFLAG"
+ 	AC_CACHE_CHECK([for mpers_name personality compile support], [st_cv_cc],
  		[AC_COMPILE_IFELSE([AC_LANG_SOURCE([[#include <stdint.h>
 +						     #include <sys/syscall.h>
  						     int main(){return 0;}]])],
  				   [st_cv_cc=yes],
  				   [st_cv_cc=no])])
- 	if test $st_cv_cc = yes; then
- 		AC_CACHE_CHECK([for CFLAG runtime support], [st_cv_runtime],
+@@ -115,6 +116,7 @@ case "$arch" in
+ 		AC_CACHE_CHECK([for mpers_name personality runtime support],
+ 			[st_cv_runtime],
  			[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdint.h>
 +							 #include <sys/syscall.h>
  							 int main(){return 0;}]])],
  				       [st_cv_runtime=yes],
  				       [st_cv_runtime=no],
--- 
-1.9.1
-
diff --git a/poky/meta/recipes-devtools/strace/strace/run-ptest b/poky/meta/recipes-devtools/strace/strace/run-ptest
index 133cf92..8070d83 100755
--- a/poky/meta/recipes-devtools/strace/strace/run-ptest
+++ b/poky/meta/recipes-devtools/strace/strace/run-ptest
@@ -1,2 +1,2 @@
 #!/bin/sh
-make -C tests -k runtest-TESTS
+make -B -C tests -k test-suite.log
diff --git a/poky/meta/recipes-devtools/strace/strace_4.20.bb b/poky/meta/recipes-devtools/strace/strace_4.20.bb
deleted file mode 100644
index 869c12f..0000000
--- a/poky/meta/recipes-devtools/strace/strace_4.20.bb
+++ /dev/null
@@ -1,59 +0,0 @@
-SUMMARY = "System call tracing tool"
-HOMEPAGE = "http://strace.io"
-SECTION = "console/utils"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=f132b4d2adfccc63da4139a609367711"
-
-SRC_URI = "https://strace.io/files/${PV}/strace-${PV}.tar.xz \
-           file://disable-git-version-gen.patch \
-           file://more-robust-test-for-m32-mx32-compile-support.patch \
-           file://update-gawk-paths.patch \
-           file://Makefile-ptest.patch \
-           file://run-ptest \
-           file://0001-Fix-build-when-using-non-glibc-libc-implementation-o.patch \
-           file://mips-SIGEMT.patch \
-           file://0001-caps-abbrev.awk-fix-gawk-s-path.patch \
-           file://0001-tests-sigaction-Check-for-mips-and-alpha-before-usin.patch \
-           "
-
-SRC_URI[md5sum] = "f2271ab0fac49ebee9cbd7f3469227cb"
-SRC_URI[sha256sum] = "5bf3148dd17306a42566f7da17368fdd781afa147db05ea63a4ca2b50f58c523"
-
-inherit autotools ptest bluetooth
-
-RDEPENDS_${PN}-ptest += "make coreutils grep gawk sed"
-
-PACKAGECONFIG_class-target ??= "\
-    ${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', 'bluez', '', d)} \
-"
-
-PACKAGECONFIG[bluez] = "ac_cv_header_bluetooth_bluetooth_h=yes,ac_cv_header_bluetooth_bluetooth_h=no,${BLUEZ}"
-PACKAGECONFIG[libunwind] = "--with-libunwind,--without-libunwind,libunwind"
-
-TESTDIR = "tests"
-
-do_install_append() {
-	# We don't ship strace-graph here because it needs perl
-	rm ${D}${bindir}/strace-graph
-}
-
-do_compile_ptest() {
-	oe_runmake -C ${TESTDIR} buildtest-TESTS
-}
-
-do_install_ptest() {
-	oe_runmake -C ${TESTDIR} install-ptest BUILDDIR=${B} DESTDIR=${D}${PTEST_PATH} TESTDIR=${TESTDIR}
-	sed -i -e '/^src/s/strace.*[1-9]/ptest/' \
-	    -e 's,--sysroot=${STAGING_DIR_TARGET},,g' \
-	    -e 's|${DEBUG_PREFIX_MAP}||g' \
-	    -e 's:${HOSTTOOLS_DIR}/::g' \
-	    -e 's:${RECIPE_SYSROOT_NATIVE}::g' \
-	    -e 's:${RECIPE_SYSROOT}::g' \
-	    -e 's:${BASE_WORKDIR}/${MULTIMACH_TARGET_SYS}::g' \
-	    -e '/^DEB_CHANGELOGTIME/d' \
-	    -e '/^RPM_CHANGELOGTIME/d' \
-	${D}/${PTEST_PATH}/${TESTDIR}/Makefile
-}
-
-BBCLASSEXTEND = "native"
-TOOLCHAIN = "gcc"
diff --git a/poky/meta/recipes-devtools/strace/strace_4.24.bb b/poky/meta/recipes-devtools/strace/strace_4.24.bb
new file mode 100644
index 0000000..9e40a06
--- /dev/null
+++ b/poky/meta/recipes-devtools/strace/strace_4.24.bb
@@ -0,0 +1,64 @@
+SUMMARY = "System call tracing tool"
+HOMEPAGE = "http://strace.io"
+SECTION = "console/utils"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=6ddb91734b9c705f3e87362e97e5f64b"
+
+SRC_URI = "https://strace.io/files/${PV}/strace-${PV}.tar.xz \
+           file://disable-git-version-gen.patch \
+           file://more-robust-test-for-m32-mx32-compile-support.patch \
+           file://update-gawk-paths.patch \
+           file://Makefile-ptest.patch \
+           file://run-ptest \
+           file://0001-Fix-build-when-using-non-glibc-libc-implementation-o.patch \
+           file://mips-SIGEMT.patch \
+           file://0001-caps-abbrev.awk-fix-gawk-s-path.patch \
+           file://0001-tests-sigaction-Check-for-mips-and-alpha-before-usin.patch \
+           "
+SRC_URI[md5sum] = "8780136849c85acf76ad3a522aa4462a"
+SRC_URI[sha256sum] = "1f4e59fc1edfa2bfb4adf2a748623dc25b105ec79713dd84404199f91b0b0634"
+
+inherit autotools ptest bluetooth
+
+PACKAGECONFIG_class-target ??= "\
+    ${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', 'bluez', '', d)} \
+"
+
+PACKAGECONFIG[bluez] = "ac_cv_header_bluetooth_bluetooth_h=yes,ac_cv_header_bluetooth_bluetooth_h=no,${BLUEZ}"
+PACKAGECONFIG[libunwind] = "--with-libunwind,--without-libunwind,libunwind"
+
+EXTRA_OECONF += "--enable-mpers=no"
+
+CFLAGS_append_libc-musl = " -Dsigcontext_struct=sigcontext"
+
+TESTDIR = "tests"
+
+do_install_append() {
+	# We don't ship strace-graph here because it needs perl
+	rm ${D}${bindir}/strace-graph
+}
+
+do_compile_ptest() {
+	oe_runmake -C ${TESTDIR} buildtest-TESTS
+}
+
+do_install_ptest() {
+	oe_runmake -C ${TESTDIR} install-ptest BUILDDIR=${B} DESTDIR=${D}${PTEST_PATH} TESTDIR=${TESTDIR}
+	install -m 755 ${S}/test-driver ${D}${PTEST_PATH}
+	install -m 644 ${B}/config.h ${D}${PTEST_PATH}
+	sed -i -e '/^src/s/strace.*[1-9]/ptest/' \
+	    -e 's,--sysroot=${STAGING_DIR_TARGET},,g' \
+	    -e 's|${DEBUG_PREFIX_MAP}||g' \
+	    -e 's:${HOSTTOOLS_DIR}/::g' \
+	    -e 's:${RECIPE_SYSROOT_NATIVE}::g' \
+	    -e 's:${RECIPE_SYSROOT}::g' \
+	    -e 's:${BASE_WORKDIR}/${MULTIMACH_TARGET_SYS}::g' \
+	    -e '/^DEB_CHANGELOGTIME/d' \
+	    -e '/^RPM_CHANGELOGTIME/d' \
+	${D}/${PTEST_PATH}/${TESTDIR}/Makefile
+}
+
+RDEPENDS_${PN}-ptest += "make coreutils grep gawk sed"
+
+BBCLASSEXTEND = "native"
+TOOLCHAIN = "gcc"
diff --git a/poky/meta/recipes-devtools/subversion/subversion_1.10.0.bb b/poky/meta/recipes-devtools/subversion/subversion_1.10.0.bb
new file mode 100644
index 0000000..42c2562
--- /dev/null
+++ b/poky/meta/recipes-devtools/subversion/subversion_1.10.0.bb
@@ -0,0 +1,58 @@
+SUMMARY = "Subversion (svn) version control system client"
+HOMEPAGE = "http://subversion.apache.org"
+SECTION = "console/network"
+LICENSE = "Apache-2 & MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=83206f39819e7a4dfca2ff7c190f6ce0"
+
+DEPENDS = "apr-util serf sqlite3 file lz4"
+DEPENDS_append_class-native = " file-replacement-native"
+
+SRC_URI = "${APACHE_MIRROR}/${BPN}/${BPN}-${PV}.tar.bz2 \
+           file://disable_macos.patch \
+           file://0001-Fix-libtool-name-in-configure.ac.patch \
+           file://serfmacro.patch \
+           "
+
+SRC_URI[md5sum] = "0126847f9e8cb8ed0b90a6a18b203309"
+SRC_URI[sha256sum] = "2cf23f3abb837dea0585a6b0ebd70e80e01f95bddef7c1aa097c18e3eaa6b584"
+
+inherit autotools pkgconfig gettext
+
+PACKAGECONFIG ?= ""
+
+PACKAGECONFIG[sasl] = "--with-sasl,--without-sasl,cyrus-sasl"
+PACKAGECONFIG[gnome-keyring] = "--with-gnome-keyring,--without-gnome-keyring,glib-2.0 gnome-keyring"
+
+EXTRA_OECONF = " \
+    --with-apr=${STAGING_BINDIR_CROSS} \
+    --with-apr-util=${STAGING_BINDIR_CROSS} \
+    --without-apxs \
+    --without-berkeley-db \
+    --without-swig \
+    --disable-keychain \
+    --with-utf8proc=internal \
+    ac_cv_path_RUBY=none \
+"
+
+acpaths = "-I build/ -I build/ac-macros/"
+
+CPPFLAGS += "-P"
+BUILD_CPPFLAGS += "-P"
+
+do_configure_prepend () {
+	rm -f ${S}/libtool
+	rm -f ${S}/build/libtool.m4 ${S}/build/ltmain.sh ${S}/build/ltoptions.m4 ${S}/build/ltsugar.m4 ${S}/build/ltversion.m4 ${S}/build/lt~obsolete.m4
+	rm -f ${S}/aclocal.m4
+	sed -i -e 's:with_sasl="/usr/local":with_sasl="${STAGING_DIR}":' ${S}/build/ac-macros/sasl.m4
+}
+
+#| x86_64-linux-libtool: install: warning: `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/work/x86_64-linux/subversion-native/1.8.9-r0/build/subversion/libsvn_ra_local/libsvn_ra_local-1.la' has not been installed in `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/sysroots/x86_64-linux/usr/lib'| x86_64-linux-libtool: install: warning: `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/work/x86_64-linux/subversion-native/1.8.9-r0/build/subversion/libsvn_repos/libsvn_repos-1.la' has not been installed in `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/sysroots/x86_64-linux/usr/lib'| /usr/bin/ld: cannot find -lsvn_delta-1| collect2: ld returned 1 exit status| x86_64-linux-libtool: install: warning: `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/work/x86_64-linux/subversion-native/1.8.9-r0/build/subversion/libsvn_ra_svn/libsvn_ra_svn-1.la' has not been installed in `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/sysroots/x86_64-linux/usr/lib'| x86_64-linux-libtool: install: warning: `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/work/x86_64-linux/subversion-native/1.8.9-r0/build/subversion/libsvn_ra_serf/libsvn_ra_serf-1.la' has not been installed in `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/sysroots/x86_64-linux/usr/lib'
+#| x86_64-linux-libtool: install: error: relink `libsvn_ra_serf-1.la' with the above command before installing it
+#| x86_64-linux-libtool: install: warning: `../../subversion/libsvn_repos/libsvn_repos-1.la' has not been installed in `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/sysroots/x86_64-linux/usr/lib'
+#| /home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/work/x86_64-linux/subversion-native/1.8.9-r0/subversion-1.8.9/build-outputs.mk:1090: recipe for target 'install-serf-lib' failed
+#| make: *** [install-serf-lib] Error 1
+PARALLEL_MAKEINST = ""
+
+RDEPENDS_${PN} = "serf"
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-devtools/subversion/subversion_1.9.7.bb b/poky/meta/recipes-devtools/subversion/subversion_1.9.7.bb
deleted file mode 100644
index 57735f7..0000000
--- a/poky/meta/recipes-devtools/subversion/subversion_1.9.7.bb
+++ /dev/null
@@ -1,55 +0,0 @@
-SUMMARY = "Subversion (svn) version control system client"
-SECTION = "console/network"
-DEPENDS = "apr-util serf sqlite3 file"
-DEPENDS_append_class-native = " file-replacement-native"
-RDEPENDS_${PN} = "serf"
-LICENSE = "Apache-2"
-HOMEPAGE = "http://subversion.tigris.org"
-
-BBCLASSEXTEND = "native"
-
-inherit gettext pkgconfig
-
-SRC_URI = "${APACHE_MIRROR}/${BPN}/${BPN}-${PV}.tar.bz2 \
-           file://disable_macos.patch \
-           file://serf.m4-Regex-modified-to-allow-D-in-paths.patch \
-           file://0001-Fix-libtool-name-in-configure.ac.patch \
-           file://serfmacro.patch \
-           "
-
-SRC_URI[md5sum] = "05b0c677681073920f938c1f322e0be2"
-SRC_URI[sha256sum] = "c3b118333ce12e501d509e66bb0a47bcc34d053990acab45559431ac3e491623"
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=af81ae49ba359e70626c05e9bf313709"
-
-PACKAGECONFIG[sasl] = "--with-sasl,--without-sasl,cyrus-sasl"
-PACKAGECONFIG[gnome-keyring] = "--with-gnome-keyring,--without-gnome-keyring,glib-2.0 gnome-keyring"
-
-EXTRA_OECONF = " \
-                --without-berkeley-db --without-apxs \
-                --without-swig --with-apr=${STAGING_BINDIR_CROSS} \
-                --with-apr-util=${STAGING_BINDIR_CROSS} \
-                --disable-keychain \
-                ac_cv_path_RUBY=none"
-
-inherit autotools
-
-export LDFLAGS += " -L${STAGING_LIBDIR} "
-CPPFLAGS += "-P"
-BUILD_CPPFLAGS += "-P"
-
-acpaths = "-I build/ -I build/ac-macros/"
-
-do_configure_prepend () {
-	rm -f ${S}/libtool
-	rm -f ${S}/build/libtool.m4 ${S}/build/ltmain.sh ${S}/build/ltoptions.m4 ${S}/build/ltsugar.m4 ${S}/build/ltversion.m4 ${S}/build/lt~obsolete.m4
-	rm -f ${S}/aclocal.m4
-	sed -i -e 's:with_sasl="/usr/local":with_sasl="${STAGING_DIR}":' ${S}/build/ac-macros/sasl.m4
-}
-
-#| x86_64-linux-libtool: install: warning: `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/work/x86_64-linux/subversion-native/1.8.9-r0/build/subversion/libsvn_ra_local/libsvn_ra_local-1.la' has not been installed in `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/sysroots/x86_64-linux/usr/lib'| x86_64-linux-libtool: install: warning: `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/work/x86_64-linux/subversion-native/1.8.9-r0/build/subversion/libsvn_repos/libsvn_repos-1.la' has not been installed in `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/sysroots/x86_64-linux/usr/lib'| /usr/bin/ld: cannot find -lsvn_delta-1| collect2: ld returned 1 exit status| x86_64-linux-libtool: install: warning: `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/work/x86_64-linux/subversion-native/1.8.9-r0/build/subversion/libsvn_ra_svn/libsvn_ra_svn-1.la' has not been installed in `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/sysroots/x86_64-linux/usr/lib'| x86_64-linux-libtool: install: warning: `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/work/x86_64-linux/subversion-native/1.8.9-r0/build/subversion/libsvn_ra_serf/libsvn_ra_serf-1.la' has not been installed in `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/sysroots/x86_64-linux/usr/lib'
-#| x86_64-linux-libtool: install: error: relink `libsvn_ra_serf-1.la' with the above command before installing it
-#| x86_64-linux-libtool: install: warning: `../../subversion/libsvn_repos/libsvn_repos-1.la' has not been installed in `/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/sysroots/x86_64-linux/usr/lib'
-#| /home/pokybuild/yocto-autobuilder/yocto-worker/nightly-qa-logrotate/build/build/tmp/work/x86_64-linux/subversion-native/1.8.9-r0/subversion-1.8.9/build-outputs.mk:1090: recipe for target 'install-serf-lib' failed
-#| make: *** [install-serf-lib] Error 1
-PARALLEL_MAKEINST = ""
diff --git a/poky/meta/recipes-devtools/swig/swig/Python-Fix-new-GCC8-warnings-in-generated-code.patch b/poky/meta/recipes-devtools/swig/swig/Python-Fix-new-GCC8-warnings-in-generated-code.patch
new file mode 100644
index 0000000..a913859
--- /dev/null
+++ b/poky/meta/recipes-devtools/swig/swig/Python-Fix-new-GCC8-warnings-in-generated-code.patch
@@ -0,0 +1,191 @@
+From b6c0ef4b8f6e5c089ac7104b3aaba8f1d17b8b82 Mon Sep 17 00:00:00 2001
+From: Olly Betts <olly@survex.com>
+Date: Mon, 11 Jun 2018 15:51:53 +1200
+Subject: [PATCH] [Python] Fix new GCC8 warnings in generated code
+
+Avoid casts between incompatible function types where possible (when
+keyword args are in use, it is not possible to avoid such warnings as
+they are inherent in the design of Python's C API in that particular
+case).  Fixes #1259.
+
+Upstream-Status: Backport
+[https://github.com/swig/swig/commit/7f9883011029674553a2a4b623d459f02b512458]
+
+Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
+---
+ Lib/python/pyinit.swg     |  4 ++--
+ Lib/python/pyrun.swg      | 34 ++++++++++++++++++++++++++--------
+ Source/Modules/python.cxx | 26 +++++++++++++-------------
+ 3 files changed, 41 insertions(+), 23 deletions(-)
+
+diff --git a/Lib/python/pyinit.swg b/Lib/python/pyinit.swg
+index 2cc5828..6bf68c1 100644
+--- a/Lib/python/pyinit.swg
++++ b/Lib/python/pyinit.swg
+@@ -368,8 +368,8 @@ SWIG_init(void) {
+     (char *)"this", &SwigPyBuiltin_ThisClosure, NULL, NULL, NULL
+   };
+   static SwigPyGetSet thisown_getset_closure = {
+-    (PyCFunction) SwigPyObject_own,
+-    (PyCFunction) SwigPyObject_own
++    SwigPyObject_own,
++    SwigPyObject_own
+   };
+   static PyGetSetDef thisown_getset_def = {
+     (char *)"thisown", SwigPyBuiltin_GetterClosure, SwigPyBuiltin_SetterClosure, NULL, &thisown_getset_closure
+diff --git a/Lib/python/pyrun.swg b/Lib/python/pyrun.swg
+index ab1237f..3d0b1b3 100644
+--- a/Lib/python/pyrun.swg
++++ b/Lib/python/pyrun.swg
+@@ -465,6 +465,14 @@ SwigPyObject_repr(SwigPyObject *v, PyObject *args)
+   return repr;  
+ }
+ 
++/* We need a version taking two PyObject* parameters so it's a valid
++ * PyCFunction to use in swigobject_methods[]. */
++SWIGRUNTIME PyObject *
++SwigPyObject_repr2(PyObject *v, PyObject *SWIGUNUSEDPARM(args))
++{
++  return SwigPyObject_repr((SwigPyObject*)v);
++}
++
+ SWIGRUNTIME int
+ SwigPyObject_compare(SwigPyObject *v, SwigPyObject *w)
+ {
+@@ -594,11 +602,7 @@ SwigPyObject_append(PyObject* v, PyObject* next)
+ }
+ 
+ SWIGRUNTIME PyObject* 
+-#ifdef METH_NOARGS
+-SwigPyObject_next(PyObject* v)
+-#else
+ SwigPyObject_next(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
+-#endif
+ {
+   SwigPyObject *sobj = (SwigPyObject *) v;
+   if (sobj->next) {    
+@@ -633,6 +637,20 @@ SwigPyObject_acquire(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
+   return SWIG_Py_Void();
+ }
+ 
++#ifdef METH_NOARGS
++static PyObject*
++SwigPyObject_disown2(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
++{
++  return SwigPyObject_disown(v);
++}
++
++static PyObject*
++SwigPyObject_acquire2(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
++{
++  return SwigPyObject_acquire(v);
++}
++#endif
++
+ SWIGINTERN PyObject*
+ SwigPyObject_own(PyObject *v, PyObject *args)
+ {
+@@ -673,12 +691,12 @@ SwigPyObject_own(PyObject *v, PyObject *args)
+ #ifdef METH_O
+ static PyMethodDef
+ swigobject_methods[] = {
+-  {(char *)"disown",  (PyCFunction)SwigPyObject_disown,  METH_NOARGS,  (char *)"releases ownership of the pointer"},
+-  {(char *)"acquire", (PyCFunction)SwigPyObject_acquire, METH_NOARGS,  (char *)"acquires ownership of the pointer"},
++  {(char *)"disown",  (PyCFunction)SwigPyObject_disown2, METH_NOARGS,  (char *)"releases ownership of the pointer"},
++  {(char *)"acquire", (PyCFunction)SwigPyObject_acquire2,METH_NOARGS,  (char *)"acquires ownership of the pointer"},
+   {(char *)"own",     (PyCFunction)SwigPyObject_own,     METH_VARARGS, (char *)"returns/sets ownership of the pointer"},
+   {(char *)"append",  (PyCFunction)SwigPyObject_append,  METH_O,       (char *)"appends another 'this' object"},
+   {(char *)"next",    (PyCFunction)SwigPyObject_next,    METH_NOARGS,  (char *)"returns the next 'this' object"},
+-  {(char *)"__repr__",(PyCFunction)SwigPyObject_repr,    METH_NOARGS,  (char *)"returns object representation"},
++  {(char *)"__repr__",(PyCFunction)SwigPyObject_repr2,   METH_NOARGS,  (char *)"returns object representation"},
+   {0, 0, 0, 0}  
+ };
+ #else
+@@ -689,7 +707,7 @@ swigobject_methods[] = {
+   {(char *)"own",     (PyCFunction)SwigPyObject_own,     METH_VARARGS,  (char *)"returns/sets ownership of the pointer"},
+   {(char *)"append",  (PyCFunction)SwigPyObject_append,  METH_VARARGS,  (char *)"appends another 'this' object"},
+   {(char *)"next",    (PyCFunction)SwigPyObject_next,    METH_VARARGS,  (char *)"returns the next 'this' object"},
+-  {(char *)"__repr__",(PyCFunction)SwigPyObject_repr,   METH_VARARGS,  (char *)"returns object representation"},
++  {(char *)"__repr__",(PyCFunction)SwigPyObject_repr,    METH_VARARGS,  (char *)"returns object representation"},
+   {0, 0, 0, 0}  
+ };
+ #endif
+diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx
+index a6801fc..72eaa77 100644
+--- a/Source/Modules/python.cxx
++++ b/Source/Modules/python.cxx
+@@ -1109,7 +1109,7 @@ public:
+    * ------------------------------------------------------------ */
+   int add_pyinstancemethod_new() {
+     String *name = NewString("SWIG_PyInstanceMethod_New");
+-    Printf(methods, "\t { (char *)\"%s\", (PyCFunction)%s, METH_O, NULL},\n", name, name);
++    Printf(methods, "\t { \"%s\", %s, METH_O, NULL},\n", name, name);
+     Delete(name);
+     return 0;
+   }
+@@ -2479,17 +2479,17 @@ public:
+     if (!kw) {
+       if (n && funpack) {
+ 	if (num_required == 0 && num_arguments == 0) {
+-	  Printf(methods, "\t { (char *)\"%s\", (PyCFunction)%s, METH_NOARGS, ", name, function);
++	  Printf(methods, "\t { \"%s\", %s, METH_NOARGS, ", name, function);
+ 	} else if (num_required == 1 && num_arguments == 1) {
+-	  Printf(methods, "\t { (char *)\"%s\", (PyCFunction)%s, METH_O, ", name, function);
++	  Printf(methods, "\t { \"%s\", %s, METH_O, ", name, function);
+ 	} else {
+-	  Printf(methods, "\t { (char *)\"%s\", %s, METH_VARARGS, ", name, function);
++	  Printf(methods, "\t { \"%s\", %s, METH_VARARGS, ", name, function);
+ 	}
+       } else {
+-	Printf(methods, "\t { (char *)\"%s\", %s, METH_VARARGS, ", name, function);
++	Printf(methods, "\t { \"%s\", %s, METH_VARARGS, ", name, function);
+       }
+     } else {
+-      Printf(methods, "\t { (char *)\"%s\", (PyCFunction) %s, METH_VARARGS | METH_KEYWORDS, ", name, function);
++      Printf(methods, "\t { \"%s\", (PyCFunction)%s, METH_VARARGS|METH_KEYWORDS, ", name, function);
+     }
+ 
+     if (!n) {
+@@ -3857,7 +3857,7 @@ public:
+     if (shadow) {
+       if (builtin) {
+ 	String *rname = SwigType_namestr(real_classname);
+-	Printf(builtin_methods, "  { \"__disown__\", (PyCFunction) Swig::Director::swig_pyobj_disown< %s >, METH_NOARGS, \"\" },\n", rname);
++	Printf(builtin_methods, "  { \"__disown__\", Swig::Director::swig_pyobj_disown< %s >, METH_NOARGS, \"\" },\n", rname);
+ 	Delete(rname);
+       } else {
+ 	String *symname = Getattr(n, "sym:name");
+@@ -4694,13 +4694,13 @@ public:
+ 	int argcount = Getattr(n, "python:argcount") ? atoi(Char(Getattr(n, "python:argcount"))) : 2;
+ 	String *ds = have_docstring(n) ? cdocstring(n, AUTODOC_FUNC) : NewString("");
+ 	if (check_kwargs(n)) {
+-	  Printf(builtin_methods, "  { \"%s\", (PyCFunction) %s, METH_VARARGS|METH_KEYWORDS, (char *) \"%s\" },\n", symname, wname, ds);
++	  Printf(builtin_methods, "  { \"%s\", (PyCFunction)%s, METH_VARARGS|METH_KEYWORDS, \"%s\" },\n", symname, wname, ds);
+ 	} else if (argcount == 0) {
+-	  Printf(builtin_methods, "  { \"%s\", (PyCFunction) %s, METH_NOARGS, (char *) \"%s\" },\n", symname, wname, ds);
++	  Printf(builtin_methods, "  { \"%s\", %s, METH_NOARGS, \"%s\" },\n", symname, wname, ds);
+ 	} else if (argcount == 1) {
+-	  Printf(builtin_methods, "  { \"%s\", (PyCFunction) %s, METH_O, (char *) \"%s\" },\n", symname, wname, ds);
++	  Printf(builtin_methods, "  { \"%s\", %s, METH_O, \"%s\" },\n", symname, wname, ds);
+ 	} else {
+-	  Printf(builtin_methods, "  { \"%s\", (PyCFunction) %s, METH_VARARGS, (char *) \"%s\" },\n", symname, wname, ds);
++	  Printf(builtin_methods, "  { \"%s\", %s, METH_VARARGS, \"%s\" },\n", symname, wname, ds);
+ 	}
+ 	Delete(fullname);
+ 	Delete(wname);
+@@ -4801,10 +4801,10 @@ public:
+ 	  Append(pyflags, "METH_VARARGS");
+ 	if (have_docstring(n)) {
+ 	  String *ds = cdocstring(n, AUTODOC_STATICFUNC);
+-	  Printf(builtin_methods, "  { \"%s\", (PyCFunction) %s, %s, (char *) \"%s\" },\n", symname, wname, pyflags, ds);
++	  Printf(builtin_methods, "  { \"%s\", (PyCFunction)%s, %s, \"%s\" },\n", symname, wname, pyflags, ds);
+ 	  Delete(ds);
+ 	} else {
+-	  Printf(builtin_methods, "  { \"%s\", (PyCFunction) %s, %s, \"\" },\n", symname, wname, pyflags);
++	  Printf(builtin_methods, "  { \"%s\", (PyCFunction)%s, %s, \"\" },\n", symname, wname, pyflags);
+ 	}
+ 	Delete(fullname);
+ 	Delete(wname);
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-devtools/swig/swig/swig-3.0.12-Coverity-fix-issue-reported-for-SWIG_Python_FixMetho.patch b/poky/meta/recipes-devtools/swig/swig/swig-3.0.12-Coverity-fix-issue-reported-for-SWIG_Python_FixMetho.patch
new file mode 100644
index 0000000..10e4afd
--- /dev/null
+++ b/poky/meta/recipes-devtools/swig/swig/swig-3.0.12-Coverity-fix-issue-reported-for-SWIG_Python_FixMetho.patch
@@ -0,0 +1,36 @@
+From 9825fcbab5c4ddd867432f9922bebfbec7b78af0 Mon Sep 17 00:00:00 2001
+From: Mark Dufour <m.dufour@kopano.com>
+Date: Tue, 14 Feb 2017 10:34:37 +0100
+Subject: [PATCH] [Coverity] fix issue reported for SWIG_Python_FixMethods
+
+Fix Coverity issue reported for SWIG_Python_FixMethods:
+
+"buffer_size: Calling strncpy with a source string whose length
+(10 chars) is greater than or equal to the size argument (10)
+will fail to null-terminate buff."
+
+The issue is only reported for the "swig_ptr: " line, but for
+consistency we replace both occurrences of strncpy with memcpy.
+---
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Backport [https://github.com/swig/swig/pull/898]
+
+ Lib/python/pyinit.swg | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+Index: swig-3.0.12/Lib/python/pyinit.swg
+===================================================================
+--- swig-3.0.12.orig/Lib/python/pyinit.swg
++++ swig-3.0.12/Lib/python/pyinit.swg
+@@ -306,9 +306,9 @@ SWIG_Python_FixMethods(PyMethodDef *meth
+ 	  char *ndoc = (char*)malloc(ldoc + lptr + 10);
+ 	  if (ndoc) {
+ 	    char *buff = ndoc;
+-	    strncpy(buff, methods[i].ml_doc, ldoc);
++	    memcpy(buff, methods[i].ml_doc, ldoc);
+ 	    buff += ldoc;
+-	    strncpy(buff, "swig_ptr: ", 10);
++	    memcpy(buff, "swig_ptr: ", 10);
+ 	    buff += 10;
+ 	    SWIG_PackVoidPtr(buff, ptr, ty->name, lptr);
+ 	    methods[i].ml_doc = ndoc;
diff --git a/poky/meta/recipes-devtools/swig/swig_3.0.12.bb b/poky/meta/recipes-devtools/swig/swig_3.0.12.bb
index 15f7348..fe9d074 100644
--- a/poky/meta/recipes-devtools/swig/swig_3.0.12.bb
+++ b/poky/meta/recipes-devtools/swig/swig_3.0.12.bb
@@ -3,6 +3,8 @@
 SRC_URI += "file://0001-Use-proc-self-exe-for-swig-swiglib-on-non-Win32-plat.patch \
             file://0001-configure-use-pkg-config-for-pcre-detection.patch \
             file://0001-Add-Node-7.x-aka-V8-5.2-support.patch \
+            file://swig-3.0.12-Coverity-fix-issue-reported-for-SWIG_Python_FixMetho.patch \
+            file://Python-Fix-new-GCC8-warnings-in-generated-code.patch \
            "
 SRC_URI[md5sum] = "82133dfa7bba75ff9ad98a7046be687c"
 SRC_URI[sha256sum] = "7cf9f447ae7ed1c51722efc45e7f14418d15d7a1e143ac9f09a668999f4fc94d"
diff --git a/poky/meta/recipes-devtools/tcf-agent/tcf-agent/0001-canonicalize_file_name-is-specific-to-glibc.patch b/poky/meta/recipes-devtools/tcf-agent/tcf-agent/0001-canonicalize_file_name-is-specific-to-glibc.patch
deleted file mode 100644
index 5f93c46..0000000
--- a/poky/meta/recipes-devtools/tcf-agent/tcf-agent/0001-canonicalize_file_name-is-specific-to-glibc.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-From 23a3759b74d081b3b2849b0d37a0e5219f37813e Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 7 Jan 2016 22:37:48 +0000
-Subject: [PATCH] canonicalize_file_name is specific to glibc
-
-When on Linux and not using glibc then we need to define
-canonicalize_file_name() API, therefore add a check for finding out if
-its not glibc
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Pending
-
- agent/tcf/framework/mdep.c | 2 +-
- agent/tcf/framework/mdep.h | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/agent/tcf/framework/mdep.c b/agent/tcf/framework/mdep.c
-index 2b52ca8..7d09655 100644
---- a/agent/tcf/framework/mdep.c
-+++ b/agent/tcf/framework/mdep.c
-@@ -1042,7 +1042,7 @@ char * canonicalize_file_name(const char * path) {
-     return strdup(res);
- }
- 
--#elif defined(__UCLIBC__)
-+#elif defined(__UCLIBC__) || !defined(__GLIBC__)
- 
- char * canonicalize_file_name(const char * path) {
-     return realpath(path, NULL);
-diff --git a/agent/tcf/framework/mdep.h b/agent/tcf/framework/mdep.h
-index 1e718a2..187c399 100644
---- a/agent/tcf/framework/mdep.h
-+++ b/agent/tcf/framework/mdep.h
-@@ -276,7 +276,7 @@ extern int loc_clock_gettime(int, struct timespec *);
- 
- #define O_BINARY 0
- 
--#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__APPLE__)
-+#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__APPLE__) || !defined(__GLIBC__)
- #  define O_LARGEFILE 0
- extern char ** environ;
- extern char * canonicalize_file_name(const char * path);
--- 
-2.7.0
-
diff --git a/poky/meta/recipes-devtools/tcf-agent/tcf-agent/fix_ranlib.patch b/poky/meta/recipes-devtools/tcf-agent/tcf-agent/fix_ranlib.patch
index b66f41a..abd33ba 100644
--- a/poky/meta/recipes-devtools/tcf-agent/tcf-agent/fix_ranlib.patch
+++ b/poky/meta/recipes-devtools/tcf-agent/tcf-agent/fix_ranlib.patch
@@ -1,16 +1,17 @@
-Upstream-Status: Inappropriate [poky-specific fix]
+Actually pass the arguments to RANLIB.
+
+Upstream-Status: Pending
+Signed-off-by: Ross Burton <ross.burton@intel.com>
 
 Index: agent/Makefile.inc
 ===================================================================
---- agent.orig/Makefile.inc
-+++ agent/Makefile.inc
-@@ -88,6 +88,9 @@ ifneq ($(OPSYS),Windows)
-   ifneq ($(CC),g++)
-     OPTS += -Wmissing-prototypes
+--- a/Makefile.inc
++++ b/Makefile.inc
+@@ -92,6 +92,7 @@ ifeq ($(OPSYS),GNU/Linux)
+     OPTS += -DUSE_uuid_generate=0
    endif
-+  ifneq ($(RANLIB),)
-+    RANLIB += $@
-+  endif
+   OPTS += -DENABLE_arch_$(shell uname -m)
++  RANLIB += $@
  endif
- 
- # Compiler flags definition
+
+ ifneq ($(OPSYS),Windows)
diff --git a/poky/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb b/poky/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb
index ba14c42..d901c18 100644
--- a/poky/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb
+++ b/poky/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb
@@ -5,14 +5,13 @@
 LICENSE = "EPL-1.0 | EDL-1.0"
 LIC_FILES_CHKSUM = "file://edl-v10.html;md5=522a390a83dc186513f0500543ad3679"
 
-SRCREV = "2dddd5f440a15d5406032fac20f206484513646f"
-PV = "1.4.0+git${SRCPV}"
+SRCREV = "a022ef2f1acfd9209a1bf792dda14ae4b0d1b60f"
+PV = "1.7.0+git${SRCPV}"
 
 UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>(\d+(\.\d+)+))"
-SRC_URI = "git://git.eclipse.org/gitroot/tcf/org.eclipse.tcf.agent;branch=1.4_neon_bugfix \
+SRC_URI = "git://git.eclipse.org/gitroot/tcf/org.eclipse.tcf.agent \
            file://fix_ranlib.patch \
            file://ldflags.patch \
-           file://0001-canonicalize_file_name-is-specific-to-glibc.patch;striplevel=2 \
            file://tcf-agent.init \
            file://tcf-agent.service \
           "
@@ -46,6 +45,7 @@
 CFLAGS_append_mips64 = " ${LCL_STOP_SERVICES}"
 CFLAGS_append_libc-musl = " ${LCL_STOP_SERVICES}"
 CFLAGS_append_powerpc64 = " ${LCL_STOP_SERVICES}"
+CFLAGS_append_riscv64 = " ${LCL_STOP_SERVICES}"
 
 do_install() {
 	oe_runmake install INSTALLROOT=${D}
diff --git a/poky/meta/recipes-devtools/unfs3/unfs3/0001-attr-fix-utime-for-symlink.patch b/poky/meta/recipes-devtools/unfs3/unfs3/0001-attr-fix-utime-for-symlink.patch
new file mode 100644
index 0000000..6957d10
--- /dev/null
+++ b/poky/meta/recipes-devtools/unfs3/unfs3/0001-attr-fix-utime-for-symlink.patch
@@ -0,0 +1,85 @@
+From 3f4fcb62661059bad77a2e957b4621137797bc2f Mon Sep 17 00:00:00 2001
+From: Rui Wang <rui.wang@windriver.com>
+Date: Fri, 15 Jun 2018 14:19:10 +0800
+Subject: [PATCH] attr: fix utime for symlink
+
+unfs3 has an old defect that it can not change the timestamps of a
+symlink file because it only uses utime(), which will follow the
+symlink. This will not cause an error if the symlink points to an
+existent file. But under some special situation, such as installing
+a rpm package, rpm tool will create the symlink first and try to
+modify the timestamps of it, when the target file is non-existent.
+This will cause an ESTALE error. Making rpm tool ignore this error
+is a solution, but not the best one. An acceptable approach is
+Making unfs3 support lutimes(), which can modify the symlink file
+itself. Considering not every system support this function, so a
+function checking is necessary.
+
+Upstream-Status: Submitted [https://sourceforge.net/p/unfs3/bugs/12/]
+
+Signed-off-by: Rui Wang <rui.wang@windriver.com>
+---
+ attr.c         | 15 +++++++++++----
+ backend_unix.h |  2 ++
+ configure.ac   |  1 +
+ 3 files changed, 14 insertions(+), 4 deletions(-)
+
+diff --git a/attr.c b/attr.c
+index 73e5c75..427d0e2 100644
+--- a/attr.c
++++ b/attr.c
+@@ -280,7 +280,7 @@ post_op_attr get_post_cached(struct svc_req * req)
+ static nfsstat3 set_time(const char *path, backend_statstruct buf, sattr3 new)
+ {
+     time_t new_atime, new_mtime;
+-    struct utimbuf utim;
++    struct timeval stamps[2];
+     int res;
+
+     /* set atime and mtime */
+@@ -302,10 +302,17 @@ static nfsstat3 set_time(const char *path, backend_statstruct buf, sattr3 new)
+	else			       /* DONT_CHANGE */
+	    new_mtime = buf.st_mtime;
+
+-	utim.actime = new_atime;
+-	utim.modtime = new_mtime;
++	stamps[0].tv_sec = new_atime;
++	stamps[0].tv_usec = 0;
++	stamps[1].tv_sec = new_mtime;
++	stamps[1].tv_usec = 0;
++
++#if HAVE_LUTIMES
++	res = backend_lutimes(path, stamps);
++#else
++	res = backend_utimes(path, stamps);
++#endif
+
+-	res = backend_utime(path, &utim);
+	if (res == -1)
+	    return setattr_err();
+     }
+diff --git a/backend_unix.h b/backend_unix.h
+index fbc2af3..813ffd3 100644
+--- a/backend_unix.h
++++ b/backend_unix.h
+@@ -61,6 +61,8 @@
+ #define backend_symlink symlink
+ #define backend_truncate truncate
+ #define backend_utime utime
++#define backend_utimes utimes
++#define backend_lutimes lutimes
+ #define backend_statstruct struct stat
+ #define backend_dirstream DIR
+ #define backend_statvfsstruct struct statvfs
+diff --git a/configure.ac b/configure.ac
+index aeec598..ea7f167 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -37,6 +37,7 @@ AC_CHECK_FUNCS(setresuid setresgid)
+ AC_CHECK_FUNCS(vsyslog)
+ AC_CHECK_FUNCS(lchown)
+ AC_CHECK_FUNCS(setgroups)
++AC_CHECK_FUNCS(lutimes)
+ UNFS3_SOLARIS_RPC
+ UNFS3_PORTMAP_DEFINE
+ UNFS3_COMPILE_WARNINGS
diff --git a/poky/meta/recipes-devtools/unfs3/unfs3_0.9.22.r497.bb b/poky/meta/recipes-devtools/unfs3/unfs3_0.9.22.r497.bb
index 8127e4a..5a81a8f 100644
--- a/poky/meta/recipes-devtools/unfs3/unfs3_0.9.22.r497.bb
+++ b/poky/meta/recipes-devtools/unfs3/unfs3_0.9.22.r497.bb
@@ -29,7 +29,8 @@
            file://relative_max_socket_path_len.patch \
            file://tcp_no_delay.patch \
            file://0001-daemon.c-Libtirpc-porting-fixes.patch \
-           "
+           file://0001-attr-fix-utime-for-symlink.patch \
+          "
 SRC_URI[md5sum] = "2e43e471c77ade0331901c40b8f8e9a3"
 SRC_URI[sha256sum] = "21009468a9ba07b72ea93780d025a63ab4e55bf8fc3127803c296f0900fe1bac"
 
diff --git a/poky/meta/recipes-devtools/vala/vala.inc b/poky/meta/recipes-devtools/vala/vala.inc
index b22faad..f680640 100644
--- a/poky/meta/recipes-devtools/vala/vala.inc
+++ b/poky/meta/recipes-devtools/vala/vala.inc
@@ -24,12 +24,15 @@
 FILES_${PN} += "${datadir}/${BPN}-${SHRT_VER}/vapi ${libdir}/${BPN}-${SHRT_VER}/"
 FILES_${PN}-doc += "${datadir}/devhelp"
 
+# .gir files from gobject-introspection are installed to ${libdir} when multilib is enabled
+GIRDIR_OPT = "${@'--girdir=${STAGING_LIBDIR}/gir-1.0' if d.getVar('MULTILIBS') else ''}"
+
 do_configure_prepend_class-target() {
         # Write out a vapigen wrapper that will be provided by pkg-config file installed in target sysroot
         # The wrapper will call a native vapigen
         cat > ${B}/vapigen-wrapper << EOF
 #!/bin/sh
-vapigen-${SHRT_VER} "\$@"
+vapigen-${SHRT_VER} ${GIRDIR_OPT} "\$@"
 EOF
         chmod +x ${B}/vapigen-wrapper
 }
@@ -55,3 +58,5 @@
            -e "s|vapigen=.*|vapigen=${bindir}/vapigen-wrapper|" \
            ${SYSROOT_DESTDIR}${libdir}/pkgconfig/vapigen-${SHRT_VER}.pc
 }
+
+SSTATE_SCAN_FILES += "vapigen-wrapper"
diff --git a/poky/meta/recipes-devtools/vala/vala/disable-graphviz.patch b/poky/meta/recipes-devtools/vala/vala/disable-graphviz.patch
index 15d186d..477504d 100644
--- a/poky/meta/recipes-devtools/vala/vala/disable-graphviz.patch
+++ b/poky/meta/recipes-devtools/vala/vala/disable-graphviz.patch
@@ -1,12 +1,14 @@
-From eb716dc856c20b3da146a4e83e9800bd1f53c739 Mon Sep 17 00:00:00 2001
+From 57f6b661d7865e8cecd17be36fab68f7f8447998 Mon Sep 17 00:00:00 2001
 From: Rico Tzschichholz <ricotz@ubuntu.com>
 Date: Wed, 6 Sep 2017 18:52:55 +0200
 Subject: [PATCH] libvaladoc: Allow disabling the graphviz dependency of
+
  valadoc
 
 https://bugzilla.gnome.org/show_bug.cgi?id=787375
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
 Upstream-Status: Submitted [bugzilla link above]
+
 ---
  configure.ac                          | 60 +++++++++++++++++++----------------
  libvaladoc/Makefile.am                | 25 +++++++++++----
@@ -15,10 +17,10 @@
  4 files changed, 63 insertions(+), 34 deletions(-)
 
 diff --git a/configure.ac b/configure.ac
-index c73d5d6b1..291e503d5 100644
+index 730c72d..af81986 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -98,34 +98,38 @@ PKG_CHECK_MODULES(GMODULE, gmodule-2.0 >= $GLIB_REQUIRED)
+@@ -119,34 +119,38 @@ PKG_CHECK_MODULES(GMODULE, gmodule-2.0 >= $GLIB_REQUIRED)
  AC_SUBST(GMODULE_CFLAGS)
  AC_SUBST(GMODULE_LIBS)
  
@@ -86,10 +88,10 @@
  
  AC_PATH_PROG([XSLTPROC], [xsltproc], :)
 diff --git a/libvaladoc/Makefile.am b/libvaladoc/Makefile.am
-index 89245d86b..7c07498b9 100644
+index 384292f..cce50d8 100644
 --- a/libvaladoc/Makefile.am
 +++ b/libvaladoc/Makefile.am
-@@ -127,10 +127,6 @@ libvaladoc_la_VALASOURCES = \
+@@ -126,10 +126,6 @@ libvaladoc_la_VALASOURCES = \
  	content/tablerow.vala \
  	content/taglet.vala \
  	content/text.vala \
@@ -100,7 +102,7 @@
  	parser/manyrule.vala \
  	parser/oneofrule.vala \
  	parser/optionalrule.vala \
-@@ -158,13 +154,24 @@ libvaladoc_la_VALASOURCES = \
+@@ -156,13 +152,24 @@ libvaladoc_la_VALASOURCES = \
  	highlighter/codetoken.vala \
  	highlighter/highlighter.vala \
  	html/basicdoclet.vala \
@@ -126,17 +128,18 @@
  libvaladoc@PACKAGE_SUFFIX@_la_SOURCES = \
  	libvaladoc.vala.stamp \
  	$(libvaladoc_la_VALASOURCES:.vala=.c) \
-@@ -182,8 +189,8 @@ libvaladoc.vala.stamp: $(libvaladoc_la_VALASOURCES)
+@@ -182,9 +189,9 @@ libvaladoc.vala.stamp: $(libvaladoc_la_VALASOURCES)
  		--library valadoc \
  		--vapi valadoc@PACKAGE_SUFFIX@.vapi \
  		--vapidir $(top_srcdir)/vapi --pkg gmodule-2.0 \
 -		--vapidir $(top_srcdir)/vapi --pkg libgvc \
  		--vapidir $(top_srcdir)/gee --pkg gee \
+ 		--vapidir $(top_srcdir)/vala --pkg vala \
 +		$(LIBGVC_PKG) \
  		--pkg config \
  		$(filter %.vala %.c,$^)
  	touch $@
-@@ -209,6 +216,9 @@ nodist_pkgconfig_DATA = valadoc@PACKAGE_SUFFIX@.pc
+@@ -211,6 +218,9 @@ nodist_pkgconfig_DATA = valadoc@PACKAGE_SUFFIX@.pc
  
  valadoc@PACKAGE_SUFFIX@.pc: valadoc.pc
  	cp $< $@
@@ -146,7 +149,7 @@
  
  vapidir = $(datadir)/vala/vapi
  dist_vapi_DATA = valadoc@PACKAGE_SUFFIX@.vapi
-@@ -216,6 +226,9 @@ nodist_vapi_DATA = valadoc@PACKAGE_SUFFIX@.deps
+@@ -218,6 +228,9 @@ nodist_vapi_DATA = valadoc@PACKAGE_SUFFIX@.deps
  
  valadoc@PACKAGE_SUFFIX@.deps: valadoc.deps
  	cp $< $@
@@ -157,7 +160,7 @@
  EXTRA_DIST = \
  	$(libvaladoc_la_VALASOURCES) \
 diff --git a/libvaladoc/html/basicdoclet.vala b/libvaladoc/html/basicdoclet.vala
-index cc9ea4ed7..432c3818f 100644
+index 37c731c..e0326ef 100644
 --- a/libvaladoc/html/basicdoclet.vala
 +++ b/libvaladoc/html/basicdoclet.vala
 @@ -46,7 +46,11 @@ public abstract class Valadoc.Html.BasicDoclet : Api.Visitor, Doclet {
@@ -199,25 +202,23 @@
  
  	public void write_namespace_content (Namespace node, Api.Node? parent) {
 diff --git a/libvaladoc/html/htmlmarkupwriter.vala b/libvaladoc/html/htmlmarkupwriter.vala
-index 15ed9efd1..fe0d705d4 100644
+index 5aa4afd..e79b0b8 100644
 --- a/libvaladoc/html/htmlmarkupwriter.vala
 +++ b/libvaladoc/html/htmlmarkupwriter.vala
-@@ -43,12 +43,16 @@ public class Valadoc.Html.MarkupWriter : Valadoc.MarkupWriter {
- 		}, xml_declaration);
+@@ -51,12 +51,16 @@ public class Valadoc.Html.MarkupWriter : Valadoc.MarkupWriter {
+ 		}
  	}
  
 +#if HAVE_GRAPHVIZ
- 	public MarkupWriter add_usemap (Charts.Chart chart) {
+ 	public unowned MarkupWriter add_usemap (Charts.Chart chart) {
  		string? buf = (string?) chart.write_buffer ("cmapx");
  		if (buf != null) {
  			raw_text ("\n");
  			raw_text ((!) buf);
  		}
 +#else
-+	public MarkupWriter add_usemap (void* chart) {
++	public unowned MarkupWriter add_usemap (void* chart) {
 +#endif
  
  		return this;
  	}
--- 
-2.14.1
diff --git a/poky/meta/recipes-devtools/vala/vala_0.38.8.bb b/poky/meta/recipes-devtools/vala/vala_0.38.8.bb
deleted file mode 100644
index e2baf65..0000000
--- a/poky/meta/recipes-devtools/vala/vala_0.38.8.bb
+++ /dev/null
@@ -1,10 +0,0 @@
-require ${BPN}.inc
-
-SRC_URI += " file://0001-git-version-gen-don-t-append-dirty-if-we-re-not-in-g.patch \
-             file://0001-vapigen.m4-use-PKG_CONFIG_SYSROOT_DIR.patch \
-	     file://disable-graphviz.patch \
-	     file://0001-Disable-valadoc.patch \
-"
-
-SRC_URI[md5sum] = "37edd0467d056fd9e3937d0bbceda80b"
-SRC_URI[sha256sum] = "2fa746b51cd66e43577d1da06a80b708c2875cadaafee77e9700ea35cf23882c"
diff --git a/poky/meta/recipes-devtools/vala/vala_0.42.0.bb b/poky/meta/recipes-devtools/vala/vala_0.42.0.bb
new file mode 100644
index 0000000..2b02e0c
--- /dev/null
+++ b/poky/meta/recipes-devtools/vala/vala_0.42.0.bb
@@ -0,0 +1,10 @@
+require ${BPN}.inc
+
+SRC_URI += " file://0001-git-version-gen-don-t-append-dirty-if-we-re-not-in-g.patch \
+             file://0001-vapigen.m4-use-PKG_CONFIG_SYSROOT_DIR.patch \
+	     file://disable-graphviz.patch \
+	     file://0001-Disable-valadoc.patch \
+"
+
+SRC_URI[md5sum] = "aa6eb8097d25b5847ad3fab34c0ff865"
+SRC_URI[sha256sum] = "62a55986da23cf3aaafd7624c32db2a1af11c8419e0bb0751727d10f1f7ab7be"
diff --git a/poky/meta/recipes-devtools/valgrind/valgrind/0001-Guard-against-__GLIBC_PREREQ-for-musl-libc.patch b/poky/meta/recipes-devtools/valgrind/valgrind/0001-Guard-against-__GLIBC_PREREQ-for-musl-libc.patch
new file mode 100644
index 0000000..3efe65a
--- /dev/null
+++ b/poky/meta/recipes-devtools/valgrind/valgrind/0001-Guard-against-__GLIBC_PREREQ-for-musl-libc.patch
@@ -0,0 +1,36 @@
+From 1b5b6f827ac1153a41fc93e78bf34ccdf5720b9b Mon Sep 17 00:00:00 2001
+From: Randy MacLeod <Randy.MacLeod@windriver.com>
+Date: Fri, 19 Oct 2018 10:31:12 -0400
+Subject: [PATCH] Guard against __GLIBC_PREREQ for musl libc
+
+Upstream-Status: Pending
+
+Signed-off-by: Randy MacLeod <Randy.MacLeod@windriver.com>
+---
+ memcheck/tests/linux/sys-statx.c | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/memcheck/tests/linux/sys-statx.c b/memcheck/tests/linux/sys-statx.c
+index fe9f9ba45..473c2cd7f 100644
+--- a/memcheck/tests/linux/sys-statx.c
++++ b/memcheck/tests/linux/sys-statx.c
+@@ -7,11 +7,16 @@
+ #include <assert.h>
+ #include <string.h>
+ #include <sys/syscall.h>
++
++#if defined(__GLIBC__) && defined(__GLIBC_PREREQ)
+ #if __GLIBC_PREREQ(2,28)
+ /* struct statx provided in sys/stat.h */
+ #else
+ #include <linux/stat.h>
+ #endif
++#else
++#include <linux/stat.h>
++#endif
+ #include <errno.h>
+ 
+ int check_stat2;
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/valgrind/valgrind/0001-Make-local-functions-static-to-avoid-assembler-error.patch b/poky/meta/recipes-devtools/valgrind/valgrind/0001-Make-local-functions-static-to-avoid-assembler-error.patch
new file mode 100644
index 0000000..45e5ea3
--- /dev/null
+++ b/poky/meta/recipes-devtools/valgrind/valgrind/0001-Make-local-functions-static-to-avoid-assembler-error.patch
@@ -0,0 +1,182 @@
+From 2155c1b2cf00e744e280c493eb74bf457dfcc3b1 Mon Sep 17 00:00:00 2001
+From: Randy MacLeod <Randy.MacLeod@windriver.com>
+Date: Sun, 21 Oct 2018 15:09:31 -0400
+Subject: [PATCH] Make local functions static to avoid assembler error
+
+Avoid mips32 x-compiler warnings such as:
+
+| ../../../valgrind-3.14.0/helgrind/tests/annotate_hbefore.c:360:6: warning: no previous prototype for 'do_signal' [-Wmissing-prototypes]
+|  void do_signal ( UWord* w )
+|       ^~~~~~~~~
+
+by making functions and global variables that are file scope be static
+and more importantly also avoid an assembler error:
+
+/tmp/cce22iiw.s: Assembler messages:
+/tmp/cce22iiw.s:446: Error: symbol `exit_0' is already defined
+/tmp/cce22iiw.s:448: Error: symbol `exit' is already defined
+/tmp/cce22iiw.s:915: Error: symbol `exit_0' is already defined
+/tmp/cce22iiw.s:917: Error: symbol `exit' is already defined
+
+Upstream-Status: Pending
+
+Signed-off-by: Randy MacLeod <Randy.MacLeod@windriver.com>
+---
+ helgrind/tests/annotate_hbefore.c | 34 +++++++++++++++----------------
+ 1 file changed, 17 insertions(+), 17 deletions(-)
+
+diff --git a/helgrind/tests/annotate_hbefore.c b/helgrind/tests/annotate_hbefore.c
+index e311714f7..f55514e45 100644
+--- a/helgrind/tests/annotate_hbefore.c
++++ b/helgrind/tests/annotate_hbefore.c
+@@ -24,7 +24,7 @@ typedef  unsigned long int  UWord;
+ 
+ // ppc64
+ /* return 1 if success, 0 if failure */
+-UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
++static UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ {
+   UWord old, success;
+ 
+@@ -57,7 +57,7 @@ UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ 
+ // ppc32
+ /* return 1 if success, 0 if failure */
+-UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
++static UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ {
+   UWord old, success;
+ 
+@@ -90,7 +90,7 @@ UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ 
+ // amd64
+ /* return 1 if success, 0 if failure */
+-UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
++static UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ {
+    UWord block[4] = { (UWord)addr, expected, nyu, 2 };
+    __asm__ __volatile__(
+@@ -113,7 +113,7 @@ UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ 
+ // x86
+ /* return 1 if success, 0 if failure */
+-UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
++static UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ {
+    UWord block[4] = { (UWord)addr, expected, nyu, 2 };
+    __asm__ __volatile__(
+@@ -138,7 +138,7 @@ UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ 
+ // arm
+ /* return 1 if success, 0 if failure */
+-UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
++static UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ {
+   UWord old, success;
+   UWord block[2] = { (UWord)addr, nyu };
+@@ -171,7 +171,7 @@ UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ 
+ // arm64
+ /* return 1 if success, 0 if failure */
+-UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
++static UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ {
+   UWord old, success;
+   UWord block[2] = { (UWord)addr, nyu };
+@@ -204,7 +204,7 @@ UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ 
+ // s390x
+ /* return 1 if success, 0 if failure */
+-UWord do_acasW(UWord* addr, UWord expected, UWord nyu )
++static UWord do_acasW(UWord* addr, UWord expected, UWord nyu )
+ {
+    int cc;
+ 
+@@ -223,7 +223,7 @@ UWord do_acasW(UWord* addr, UWord expected, UWord nyu )
+ 
+ // mips32
+ /* return 1 if success, 0 if failure */
+-UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
++static UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ {
+   UWord success;
+   UWord block[3] = { (UWord)addr, nyu, expected};
+@@ -256,7 +256,7 @@ UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ 
+ // mips64
+ /* return 1 if success, 0 if failure */
+-UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
++static UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ {
+   UWord success;
+   UWord block[3] = { (UWord)addr, nyu, expected};
+@@ -287,7 +287,7 @@ UWord do_acasW ( UWord* addr, UWord expected, UWord nyu )
+ 
+ #endif
+ 
+-void atomic_incW ( UWord* w )
++static void atomic_incW ( UWord* w )
+ {
+    while (1) {
+       UWord old = *w;
+@@ -301,7 +301,7 @@ void atomic_incW ( UWord* w )
+ 
+ #define NNN 1000000
+ 
+-void* thread_fn ( void* arg )
++static void* thread_fn ( void* arg )
+ {
+   UWord* w = (UWord*)arg;
+   int i;
+@@ -331,10 +331,10 @@ int main ( void )
+ 
+ #endif
+ 
+-int shared_var = 0;  // is not raced upon
++static int shared_var = 0;  // is not raced upon
+ 
+ 
+-void delayXms ( int i )
++static void delayXms ( int i )
+ {
+    struct timespec ts = { 0, 1 * 1000 * 1000 };
+    // We do the sleep in small pieces to have scheduling
+@@ -348,7 +348,7 @@ void delayXms ( int i )
+    }
+ }
+ 
+-void do_wait ( UWord* w )
++static void do_wait ( UWord* w )
+ {
+   UWord w0 = *w;
+   UWord volatile * wV = w;
+@@ -357,7 +357,7 @@ void do_wait ( UWord* w )
+   ANNOTATE_HAPPENS_AFTER(w);
+ }
+ 
+-void do_signal ( UWord* w )
++static void do_signal ( UWord* w )
+ {
+   ANNOTATE_HAPPENS_BEFORE(w);
+   atomic_incW(w);
+@@ -365,7 +365,7 @@ void do_signal ( UWord* w )
+ 
+ 
+ 
+-void* thread_fn1 ( void* arg )
++static void* thread_fn1 ( void* arg )
+ {
+   UWord* w = (UWord*)arg;
+   delayXms(500);    // ensure t2 gets to its wait first
+@@ -376,7 +376,7 @@ void* thread_fn1 ( void* arg )
+   return NULL;
+ }
+ 
+-void* thread_fn2 ( void* arg )
++static void* thread_fn2 ( void* arg )
+ {
+   UWord* w = (UWord*)arg;
+   do_wait(w);      // wait for h-b edge from first thread
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-devtools/valgrind/valgrind/0001-memcheck-tests-Use-ucontext_t-instead-of-struct-ucon.patch b/poky/meta/recipes-devtools/valgrind/valgrind/0001-memcheck-tests-Use-ucontext_t-instead-of-struct-ucon.patch
deleted file mode 100644
index bf16a1a..0000000
--- a/poky/meta/recipes-devtools/valgrind/valgrind/0001-memcheck-tests-Use-ucontext_t-instead-of-struct-ucon.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 629ac492b1d9bc709d17337eb9b1c28603eca250 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 28 Jun 2017 11:01:25 -0700
-Subject: [PATCH] memcheck/tests: Use ucontext_t instead of struct ucontext
-
-glibc 2.26 does not expose struct ucontext anymore
-
-Upstream-Status: Submitted [https://bugs.kde.org/show_bug.cgi?id=381769]
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- memcheck/tests/linux/stack_changes.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/memcheck/tests/linux/stack_changes.c b/memcheck/tests/linux/stack_changes.c
-index ffb49c6..acc4109 100644
---- a/memcheck/tests/linux/stack_changes.c
-+++ b/memcheck/tests/linux/stack_changes.c
-@@ -11,7 +11,7 @@
- // checks that Valgrind notices their stack changes properly.
- 
- #ifdef __GLIBC__
--typedef  struct ucontext  mycontext;
-+typedef ucontext_t  mycontext;
- 
- mycontext ctx1, ctx2, oldc;
- int count;
--- 
-2.13.2
-
diff --git a/poky/meta/recipes-devtools/valgrind/valgrind/0002-context-APIs-are-not-available-on-musl.patch b/poky/meta/recipes-devtools/valgrind/valgrind/0002-context-APIs-are-not-available-on-musl.patch
index 3f9f33b..480fe33 100644
--- a/poky/meta/recipes-devtools/valgrind/valgrind/0002-context-APIs-are-not-available-on-musl.patch
+++ b/poky/meta/recipes-devtools/valgrind/valgrind/0002-context-APIs-are-not-available-on-musl.patch
@@ -1,17 +1,20 @@
-From 862b807076d57f2f58ed9d572ddac8bb402774a2 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 10 Jun 2017 01:01:10 -0700
-Subject: [PATCH 2/6] context APIs are not available on musl
+From bd4e926e7e14747b3cd4d7b2a1bd5410b22f3ea2 Mon Sep 17 00:00:00 2001
+From: Randy MacLeod <Randy.MacLeod@windriver.com>
+Date: Tue, 16 Oct 2018 21:27:46 -0400
+Subject: [PATCH] context APIs are not available on musl
 
 Upstream-Status: Pending
 
+Updated patch for valgrind-3.14
+
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Randy MacLeod <Randy.MacLeod@windriver.com>
 ---
  memcheck/tests/linux/stack_changes.c | 7 ++++++-
  1 file changed, 6 insertions(+), 1 deletion(-)
 
 diff --git a/memcheck/tests/linux/stack_changes.c b/memcheck/tests/linux/stack_changes.c
-index a978fc2..ffb49c6 100644
+index 7f97b90a5..a26cb4ae6 100644
 --- a/memcheck/tests/linux/stack_changes.c
 +++ b/memcheck/tests/linux/stack_changes.c
 @@ -10,6 +10,7 @@
@@ -19,7 +22,7 @@
  // checks that Valgrind notices their stack changes properly.
  
 +#ifdef __GLIBC__
- typedef  struct ucontext  mycontext;
+ typedef  ucontext_t  mycontext;
  
  mycontext ctx1, ctx2, oldc;
 @@ -51,9 +52,11 @@ int init_context(mycontext *uc)
@@ -45,5 +48,5 @@
      return 0;
  }
 -- 
-2.13.1
+2.17.0
 
diff --git a/poky/meta/recipes-devtools/valgrind/valgrind/0002-fix-broken-inline-asm-in-tests-on-mips32-linux.patch b/poky/meta/recipes-devtools/valgrind/valgrind/0002-fix-broken-inline-asm-in-tests-on-mips32-linux.patch
deleted file mode 100644
index 6df295f..0000000
--- a/poky/meta/recipes-devtools/valgrind/valgrind/0002-fix-broken-inline-asm-in-tests-on-mips32-linux.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From 63ce36396348e7c4c021cffa652d2e3d20f7963a Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Fri, 27 Jul 2018 17:51:54 +0800
-Subject: [PATCH 2/2] fix broken inline asm in tests on mips32-linux
-
-While build tests(`make check') with gcc 8.1.0 on mips32-linux,
-there is a failure
-[snip]
-|mips-wrsmllib32-linux-gcc  -meb -mabi=32 -mhard-float -march=mips32
--c -o tc08_hbl2-tc08_hbl2.o `test -f 'tc08_hbl2.c' || echo '../../../
-valgrind-3.13.0/helgrind/tests/'`tc08_hbl2.c
-|/tmp/cc37aJxQ.s: Assembler messages:
-|/tmp/cc37aJxQ.s:275: Error: symbol `L1xyzzy1main' is already defined
-|Makefile:1323: recipe for target 'tc08_hbl2-tc08_hbl2.o' failed
-[snip]
-
-Remove the duplicated L1xyzzy1main, and use local symbol to replace.
-http://tigcc.ticalc.org/doc/gnuasm.html#SEC46
-
-Upstream-Status: Submitted [https://bugs.kde.org/show_bug.cgi?id=396906]
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- helgrind/tests/tc08_hbl2.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/helgrind/tests/tc08_hbl2.c b/helgrind/tests/tc08_hbl2.c
-index 2a757a008..f660d82dd 100644
---- a/helgrind/tests/tc08_hbl2.c
-+++ b/helgrind/tests/tc08_hbl2.c
-@@ -121,12 +121,12 @@
- #elif defined(PLAT_mips32_linux) || defined(PLAT_mips64_linux)
- #  define INC(_lval,_lqual)                         \
-      __asm__ __volatile__ (                         \
--      "L1xyzzy1" _lqual":\n"                        \
-+      "1:\n"                                        \
-       "        move  $t0, %0\n"                     \
-       "        ll    $t1, 0($t0)\n"                 \
-       "        addiu $t1, $t1, 1\n"                 \
-       "        sc    $t1, 0($t0)\n"                 \
--      "        beqz  $t1, L1xyzzy1" _lqual          \
-+      "        beqz  $t1, 1b\n"                     \
-       : /*out*/ : /*in*/ "r"(&(_lval))              \
-       : /*trash*/ "t0", "t1", "memory"              \
-         )
--- 
-2.17.1
-
diff --git a/poky/meta/recipes-devtools/valgrind/valgrind/0004-Fix-out-of-tree-builds.patch b/poky/meta/recipes-devtools/valgrind/valgrind/0004-Fix-out-of-tree-builds.patch
index 39022d0..75bb0aa 100644
--- a/poky/meta/recipes-devtools/valgrind/valgrind/0004-Fix-out-of-tree-builds.patch
+++ b/poky/meta/recipes-devtools/valgrind/valgrind/0004-Fix-out-of-tree-builds.patch
@@ -1,7 +1,7 @@
-From 739421e253e6eba3eb6438651822f80fa9c0502a Mon Sep 17 00:00:00 2001
-From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Tue, 15 Dec 2015 15:31:50 +0200
-Subject: [PATCH 1/2] Fix out of tree builds.
+From 8f916dcb395fe5a2429f2867ba4daf8ef3af073a Mon Sep 17 00:00:00 2001
+From: Randy MacLeod <Randy.MacLeod@windriver.com>
+Date: Tue, 16 Oct 2018 21:01:04 -0400
+Subject: [PATCH] Fix out of tree builds.
 
 The paths to these files need to be fully specified in
 the out of tree build case. glibc-2.X.supp is a generated file so the full path
@@ -9,18 +9,21 @@
 
 RP 2013/03/23
 
-Upstream-Status: Pending
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+Patch refreshed for valgrind-3.14.0.
 
+Upstream-Status: Pending
+
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+Signed-off-by: Randy MacLeod <Randy.MacLeod@windriver.com>
 ---
- configure.ac | 68 ++++++++++++++++++++++++++++++------------------------------
+ configure.ac | 68 ++++++++++++++++++++++++++--------------------------
  1 file changed, 34 insertions(+), 34 deletions(-)
 
 diff --git a/configure.ac b/configure.ac
-index 3874296fde0b..7a5ba2c8557e 100644
+index c18ae5f2a..99667ce57 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -373,50 +373,50 @@ case "${host_os}" in
+@@ -392,50 +392,50 @@ case "${host_os}" in
  	     9.*)
  		  AC_MSG_RESULT([Darwin 9.x (${kernel}) / Mac OS X 10.5 Leopard])
  		  AC_DEFINE([DARWIN_VERS], DARWIN_10_5, [Darwin / Mac OS X version])
@@ -85,16 +88,18 @@
 +		  DEFAULT_SUPP="$srcdir/darwin16.supp ${DEFAULT_SUPP}"
 +		  DEFAULT_SUPP="$srcdir/darwin10-drd.supp ${DEFAULT_SUPP}"
  		  ;;
-              *) 
- 		  AC_MSG_RESULT([unsupported (${kernel})])
-@@ -428,13 +428,13 @@ case "${host_os}" in
-      solaris2.11*)
-         AC_MSG_RESULT([ok (${host_os})])
-         VGCONF_OS="solaris"
--        DEFAULT_SUPP="solaris11.supp ${DEFAULT_SUPP}"
-+        DEFAULT_SUPP="$srcdir/solaris11.supp ${DEFAULT_SUPP}"
+ 	     17.*)
+ 		  AC_MSG_RESULT([Darwin 17.x (${kernel}) / macOS 10.13 High Sierra])
+@@ -460,7 +460,7 @@ case "${host_os}" in
+                  DEFAULT_SUPP="solaris12.supp ${DEFAULT_SUPP}"
+                  ;;
+              *)
+-                 DEFAULT_SUPP="solaris11.supp ${DEFAULT_SUPP}"
++                 DEFAULT_SUPP="$srcdir/solaris11.supp ${DEFAULT_SUPP}"
+                  ;;
+ 	esac
          ;;
- 
+@@ -468,7 +468,7 @@ case "${host_os}" in
       solaris2.12*)
          AC_MSG_RESULT([ok (${host_os})])
          VGCONF_OS="solaris"
@@ -103,7 +108,7 @@
          ;;
  
       *) 
-@@ -982,29 +982,29 @@ AC_MSG_CHECKING([the glibc version])
+@@ -1051,29 +1051,29 @@ AC_MSG_CHECKING([the glibc version])
  case "${GLIBC_VERSION}" in
       2.2)
  	AC_MSG_RESULT(${GLIBC_VERSION} family)
@@ -143,7 +148,7 @@
  	;;
       2.*)
  	AC_MSG_RESULT(${GLIBC_VERSION} family)
-@@ -1013,8 +1013,8 @@ case "${GLIBC_VERSION}" in
+@@ -1082,8 +1082,8 @@ case "${GLIBC_VERSION}" in
  	AC_DEFINE([GLIBC_MANDATORY_INDEX_AND_STRLEN_REDIRECT], 1,
  		  [Define to 1 if index() and strlen() have been optimized heavily (x86 glibc >= 2.12)])
  	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
@@ -154,7 +159,7 @@
  	;;
       darwin)
  	AC_MSG_RESULT(Darwin)
-@@ -1024,7 +1024,7 @@ case "${GLIBC_VERSION}" in
+@@ -1093,7 +1093,7 @@ case "${GLIBC_VERSION}" in
       bionic)
  	AC_MSG_RESULT(Bionic)
  	AC_DEFINE([BIONIC_LIBC], 1, [Define to 1 if you're using Bionic])
@@ -163,7 +168,7 @@
  	;;
       solaris)
  	AC_MSG_RESULT(Solaris)
-@@ -1051,11 +1051,11 @@ if test "$VGCONF_OS" != "solaris"; then
+@@ -1120,11 +1120,11 @@ if test "$VGCONF_OS" != "solaris"; then
      # attempt to detect whether such libraries are installed on the
      # build machine (or even if any X facilities are present); just
      # add the suppressions antidisirregardless.
@@ -179,5 +184,5 @@
  
  
 -- 
-2.13.2.3.g44cd85c14
+2.17.0
 
diff --git a/poky/meta/recipes-devtools/valgrind/valgrind/link-gz-tests.patch b/poky/meta/recipes-devtools/valgrind/valgrind/link-gz-tests.patch
deleted file mode 100644
index db32239..0000000
--- a/poky/meta/recipes-devtools/valgrind/valgrind/link-gz-tests.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-When checking if the compiler supports compressed debug sections we need to
-actually link instead of just compile.  Otherwise the compiler thinks that
-they are supported, but gold does not support -gz=zlib.
-
-Upstream-Status: Backport (r16459)
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
---- a/configure.ac~	2017-07-11 11:53:16.000000000 +0100
-+++ b/configure.ac	2017-07-11 18:16:13.674130483 +0100
-@@ -2119,7 +2119,7 @@
- safe_CFLAGS=$CFLAGS
- CFLAGS="-g -gz=zlib"
- 
--AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ ]], [[
-+AC_LINK_IFELSE([AC_LANG_PROGRAM([[ ]], [[
-   return 0;
- ]])], [
- ac_have_gz_zlib=yes
-@@ -2139,7 +2139,7 @@
- safe_CFLAGS=$CFLAGS
- CFLAGS="-g -gz=zlib-gnu"
- 
--AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ ]], [[
-+AC_LINK_IFELSE([AC_LANG_PROGRAM([[ ]], [[
-   return 0;
- ]])], [
- ac_have_gz_zlib_gnu=yes
diff --git a/poky/meta/recipes-devtools/valgrind/valgrind/mask-CPUID-support-in-HWCAP-on-aarch64.patch b/poky/meta/recipes-devtools/valgrind/valgrind/mask-CPUID-support-in-HWCAP-on-aarch64.patch
deleted file mode 100644
index 89a95b8..0000000
--- a/poky/meta/recipes-devtools/valgrind/valgrind/mask-CPUID-support-in-HWCAP-on-aarch64.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-Fix runtime Valgrind failure
-
-This patch is derived from
-https://bugzilla.redhat.com/show_bug.cgi?id=1464211
-
-At runtime it will fails like this:
-
-ARM64 front end: branch_etc
-disInstr(arm64): unhandled instruction 0xD5380001
-disInstr(arm64): 1101'0101 0011'1000 0000'0000 0000'0001 ==2082==
-valgrind: Unrecognised instruction at address 0x4014e64.
-
-This patch is a workaround by masking all HWCAP
-
-Upstream-Status: Pending
-
-Signed-off-by: Manjukumar Matha <manjukumar.harthikote-matha@xilinx.com>
-
-Index: valgrind-3.13.0/coregrind/m_initimg/initimg-linux.c
-===================================================================
-
---- valgrind-3.13.0.orig/coregrind/m_initimg/initimg-linux.c   2018-03-04 22:22:17.698572675 -0800
-+++ valgrind-3.13.0/coregrind/m_initimg/initimg-linux.c        2018-03-04 22:23:25.727815624 -0800
-@@ -703,6 +703,12 @@
-                   (and anything above) are not supported by Valgrind. */
-                auxv->u.a_val &= VKI_HWCAP_S390_TE - 1;
-             }
-+#           elif defined(VGP_arm64_linux)
-+            {
-+               /* Linux 4.11 started populating this for arm64, but we
-+                  currently don't support any. */
-+               auxv->u.a_val = 0;
-+            }
- #           endif
-             break;
- #        if defined(VGP_ppc64be_linux) || defined(VGP_ppc64le_linux)
diff --git a/poky/meta/recipes-devtools/valgrind/valgrind/ppc-headers.patch b/poky/meta/recipes-devtools/valgrind/valgrind/ppc-headers.patch
deleted file mode 100644
index 4b531b4..0000000
--- a/poky/meta/recipes-devtools/valgrind/valgrind/ppc-headers.patch
+++ /dev/null
@@ -1,165 +0,0 @@
-Backport a patch from upstream to fix test compilation for PPC where
-system headers don't get included.
-
-Upstream-Status: Backport
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
-r16450 | mjw | 2017-06-16 10:33:35 +0100 (Fri, 16 Jun 2017) | 7 lines
-
-ppc64 doesn't compile test_isa_2_06_partx.c without VSX support
-
-The #ifdef HAS_VSX guard is wrongly placed. It makes the standard
-include headers not be used. Causing a build failure. Fix by moving
-the #ifdef HAS_VSX after the standard includes.
-
-[v2 changes]
-- Add #ifdef HAS_VSX guard correctly for ppc64 test_isa_2_06_partx.c 
-  test cases. The changes are similar to what was done for ppc32.
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
-Index: none/tests/ppc32/test_isa_2_06_part3.c
-===================================================================
---- a/none/tests/ppc32/test_isa_2_06_part3.c	(revision 16449)
-+++ b/none/tests/ppc32/test_isa_2_06_part3.c	(revision 16450)
-@@ -20,17 +20,18 @@
-  The GNU General Public License is contained in the file COPYING.
-  */
- 
--#ifdef HAS_VSX
--
- #include <stdio.h>
- #include <stdint.h>
- #include <stdlib.h>
- #include <string.h>
- #include <malloc.h>
--#include <altivec.h>
- #include <math.h>
- #include <unistd.h>    // getopt
- 
-+#ifdef HAS_VSX
-+
-+#include <altivec.h>
-+
- #ifndef __powerpc64__
- typedef uint32_t HWord_t;
- #else
-Index: none/tests/ppc32/test_isa_2_06_part1.c
-===================================================================
---- a/none/tests/ppc32/test_isa_2_06_part1.c	(revision 16449)
-+++ b/none/tests/ppc32/test_isa_2_06_part1.c	(revision 16450)
-@@ -20,13 +20,14 @@
-  The GNU General Public License is contained in the file COPYING.
-  */
- 
--#ifdef HAS_VSX
--
- #include <stdio.h>
- #include <stdint.h>
- #include <stdlib.h>
- #include <string.h>
- #include <malloc.h>
-+
-+#ifdef HAS_VSX
-+
- #include <altivec.h>
- 
- #ifndef __powerpc64__
-Index: none/tests/ppc32/test_isa_2_06_part2.c
-===================================================================
---- a/none/tests/ppc32/test_isa_2_06_part2.c	(revision 16449)
-+++ b/none/tests/ppc32/test_isa_2_06_part2.c	(revision 16450)
-@@ -20,17 +20,18 @@
-  The GNU General Public License is contained in the file COPYING.
-  */
- 
--#ifdef HAS_VSX
--
- #include <stdio.h>
- #include <stdint.h>
- #include <stdlib.h>
- #include <string.h>
- #include <malloc.h>
--#include <altivec.h>
- #include <math.h>
- #include <unistd.h>    // getopt
- 
-+#ifdef HAS_VSX
-+
-+#include <altivec.h>
-+
- #ifndef __powerpc64__
- typedef uint32_t HWord_t;
- #else
-Index: none/tests/ppc64/test_isa_2_06_part3.c
-===================================================================
---- a/none/tests/ppc64/test_isa_2_06_part3.c	(revision 16449)
-+++ b/none/tests/ppc64/test_isa_2_06_part3.c	(revision 16450)
-@@ -20,17 +20,18 @@
-  The GNU General Public License is contained in the file COPYING.
-  */
- 
--#ifdef HAS_VSX
--
- #include <stdio.h>
- #include <stdint.h>
- #include <stdlib.h>
- #include <string.h>
- #include <malloc.h>
--#include <altivec.h>
- #include <math.h>
- #include <unistd.h>    // getopt
- 
-+#ifdef HAS_VSX
-+
-+#include <altivec.h>
-+
- #ifndef __powerpc64__
- typedef uint32_t HWord_t;
- #else
-Index: none/tests/ppc64/test_isa_2_06_part1.c
-===================================================================
---- a/none/tests/ppc64/test_isa_2_06_part1.c	(revision 16449)
-+++ b/none/tests/ppc64/test_isa_2_06_part1.c	(revision 16450)
-@@ -20,13 +20,14 @@
-  The GNU General Public License is contained in the file COPYING.
-  */
- 
--#ifdef HAS_VSX
--
- #include <stdio.h>
- #include <stdint.h>
- #include <stdlib.h>
- #include <string.h>
- #include <malloc.h>
-+
-+#ifdef HAS_VSX
-+
- #include <altivec.h>
- 
- #ifndef __powerpc64__
-Index: none/tests/ppc64/test_isa_2_06_part2.c
-===================================================================
---- a/none/tests/ppc64/test_isa_2_06_part2.c	(revision 16449)
-+++ b/none/tests/ppc64/test_isa_2_06_part2.c	(revision 16450)
-@@ -20,17 +20,18 @@
-  The GNU General Public License is contained in the file COPYING.
-  */
- 
--#ifdef HAS_VSX
--
- #include <stdio.h>
- #include <stdint.h>
- #include <stdlib.h>
- #include <string.h>
- #include <malloc.h>
--#include <altivec.h>
- #include <math.h>
- #include <unistd.h>    // getopt
- 
-+#ifdef HAS_VSX
-+
-+#include <altivec.h>
-+
- #ifndef __powerpc64__
- typedef uint32_t HWord_t;
- #else
diff --git a/poky/meta/recipes-devtools/valgrind/valgrind_3.13.0.bb b/poky/meta/recipes-devtools/valgrind/valgrind_3.13.0.bb
deleted file mode 100644
index 39ec6f5..0000000
--- a/poky/meta/recipes-devtools/valgrind/valgrind_3.13.0.bb
+++ /dev/null
@@ -1,157 +0,0 @@
-SUMMARY = "Valgrind memory debugger and instrumentation framework"
-HOMEPAGE = "http://valgrind.org/"
-BUGTRACKER = "http://valgrind.org/support/bug_reports.html"
-LICENSE = "GPLv2 & GPLv2+ & BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-                    file://include/pub_tool_basics.h;beginline=6;endline=29;md5=d4de0407239381463cf01dd276d7c22e \
-                    file://include/valgrind.h;beginline=1;endline=56;md5=ad3b317f3286b6b704575d9efe6ca5df \
-                    file://COPYING.DOCS;md5=24ea4c7092233849b4394699333b5c56"
-
-X11DEPENDS = "virtual/libx11"
-DEPENDS = "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '${X11DEPENDS}', '', d)} \
-           ${@bb.utils.contains('DISTRO_FEATURES', 'ptest', 'boost', '', d)} \
-        "
-
-SRC_URI = "ftp://sourceware.org/pub/valgrind/valgrind-${PV}.tar.bz2 \
-           file://fixed-perl-path.patch \
-           file://Added-support-for-PPC-instructions-mfatbu-mfatbl.patch \
-           file://run-ptest \
-           file://0004-Fix-out-of-tree-builds.patch \
-           file://0005-Modify-vg_test-wrapper-to-support-PTEST-formats.patch \
-           file://0001-Remove-tests-that-fail-to-build-on-some-PPC32-config.patch \
-           file://use-appropriate-march-mcpu-mfpu-for-ARM-test-apps.patch \
-           file://avoid-neon-for-targets-which-don-t-support-it.patch \
-           file://valgrind-make-ld-XXX.so-strlen-intercept-optional.patch \
-           file://0001-makefiles-Drop-setting-mcpu-to-cortex-a8-on-arm-arch.patch \
-           file://0001-str_tester.c-Limit-rawmemchr-test-to-glibc.patch \
-           file://0001-sigqueue-Rename-_sifields-to-__si_fields-on-musl.patch \
-           file://0002-context-APIs-are-not-available-on-musl.patch \
-           file://0003-correct-include-directive-path-for-config.h.patch \
-           file://0004-pth_atfork1.c-Define-error-API-for-musl.patch \
-           file://0005-tc20_verifywrap.c-Fake-__GLIBC_PREREQ-with-musl.patch \
-           file://0006-pth_detached3.c-Dereference-pthread_t-before-adding-.patch \
-           file://0001-memcheck-tests-Use-ucontext_t-instead-of-struct-ucon.patch \
-           file://0001-memcheck-arm64-Define-__THROW-if-not-already-defined.patch \
-           file://0002-memcheck-x86-Define-__THROW-if-not-defined.patch \
-           file://0003-tests-seg_override-Replace-__modify_ldt-with-syscall.patch \
-           file://link-gz-tests.patch \
-           file://ppc-headers.patch \
-           file://mask-CPUID-support-in-HWCAP-on-aarch64.patch \
-           file://0001-fix-opcode-not-supported-on-mips32-linux.patch \
-           file://0002-fix-broken-inline-asm-in-tests-on-mips32-linux.patch \
-           "
-SRC_URI[md5sum] = "817dd08f1e8a66336b9ff206400a5369"
-SRC_URI[sha256sum] = "d76680ef03f00cd5e970bbdcd4e57fb1f6df7d2e2c071635ef2be74790190c3b"
-UPSTREAM_CHECK_REGEX = "valgrind-(?P<pver>\d+(\.\d+)+)\.tar"
-
-COMPATIBLE_HOST = '(i.86|x86_64|arm|aarch64|mips|powerpc|powerpc64).*-linux'
-
-# valgrind supports armv7 and above
-COMPATIBLE_HOST_armv4 = 'null'
-COMPATIBLE_HOST_armv5 = 'null'
-COMPATIBLE_HOST_armv6 = 'null'
-
-# X32 isn't supported by valgrind at this time
-COMPATIBLE_HOST_linux-gnux32 = 'null'
-COMPATIBLE_HOST_linux-muslx32 = 'null'
-
-# Disable for some MIPS variants
-COMPATIBLE_HOST_mipsarchr6 = 'null'
-
-inherit autotools ptest multilib_header
-
-EXTRA_OECONF = "--enable-tls --without-mpicc"
-EXTRA_OECONF += "${@['--enable-only32bit','--enable-only64bit'][d.getVar('SITEINFO_BITS') != '32']}"
-
-# valgrind checks host_cpu "armv7*)", so we need to over-ride the autotools.bbclass default --host option
-EXTRA_OECONF_append_arm = " --host=armv7${HOST_VENDOR}-${HOST_OS}"
-TARGET_CC_ARCH_remove_arm = "${@get_mcpu(d)}"
-
-EXTRA_OEMAKE = "-w"
-
-CACHED_CONFIGUREVARS += "ac_cv_path_PERL='/usr/bin/env perl'"
-
-# valgrind likes to control its own optimisation flags. It generally defaults
-# to -O2 but uses -O0 for some specific test apps etc. Passing our own flags
-# (via CFLAGS) means we interfere with that. Only pass DEBUG_FLAGS to it
-# which fixes build path issue in DWARF.
-SELECTED_OPTIMIZATION = "${DEBUG_FLAGS}"
-
-def get_mcpu(d):
-    for arg in (d.getVar('TUNE_CCARGS') or '').split():
-        if arg.startswith('-mcpu='):
-            return arg
-        else:
-            continue
-    return ""
-
-do_configure_prepend () {
-    rm -rf ${S}/config.h
-    sed -i -e 's:$(abs_top_builddir):$(pkglibdir)/ptest:g' ${S}/none/tests/Makefile.am
-    sed -i -e 's:$(top_builddir):$(pkglibdir)/ptest:g' ${S}/memcheck/tests/Makefile.am
-}
-
-do_install_append () {
-    install -m 644 ${B}/default.supp ${D}/${libdir}/valgrind/
-    oe_multilib_header valgrind/config.h
-}
-
-TUNE = "${@strip_mcpu(d)}"
-
-RDEPENDS_${PN} += "perl"
-
-# valgrind needs debug information for ld.so at runtime in order to
-# redirect functions like strlen.
-RRECOMMENDS_${PN} += "${TCLIBC}-dbg"
-
-RDEPENDS_${PN}-ptest += " sed perl perl-module-file-glob"
-RDEPENDS_${PN}-ptest_append_libc-glibc = " glibc-utils"
-
-# One of the tests contains a bogus interpreter path on purpose.
-# Skip file dependency check
-SKIP_FILEDEPS_${PN}-ptest = '1'
-
-do_compile_ptest() {
-    oe_runmake check
-}
-
-do_install_ptest() {
-    chmod +x ${B}/tests/vg_regtest
-
-    # The test application binaries are not automatically installed.
-    # Grab them from the build directory.
-    #
-    # The regression tests require scripts and data files that are not
-    # copied to the build directory.  They must be copied from the
-    # source directory. 
-    saved_dir=$PWD
-    for parent_dir in ${S} ${B} ; do
-        cd $parent_dir
-
-        # exclude shell or the package won't install
-        rm -rf none/tests/shell* 2>/dev/null
-
-        subdirs="tests cachegrind/tests callgrind/tests drd/tests helgrind/tests massif/tests memcheck/tests none/tests"
-
-        # Get the vg test scripts, filters, and expected files
-        for dir in $subdirs ; do
-            find $dir | cpio -pvdu ${D}${PTEST_PATH}
-        done
-        cd $saved_dir
-    done
-
-    # clean out build artifacts before building the rpm
-    find ${D}${PTEST_PATH} \
-         \( -name "Makefile*" \
-        -o -name "*.o" \
-        -o -name "*.c" \
-        -o -name "*.S" \
-        -o -name "*.h" \) \
-        -exec rm {} \;
-
-    # needed by massif tests
-    cp ${B}/massif/ms_print ${D}${PTEST_PATH}/massif/ms_print
-
-    # handle multilib
-    sed -i s:@libdir@:${libdir}:g ${D}${PTEST_PATH}/run-ptest
-}
diff --git a/poky/meta/recipes-devtools/valgrind/valgrind_3.14.0.bb b/poky/meta/recipes-devtools/valgrind/valgrind_3.14.0.bb
new file mode 100644
index 0000000..97e58a4
--- /dev/null
+++ b/poky/meta/recipes-devtools/valgrind/valgrind_3.14.0.bb
@@ -0,0 +1,155 @@
+SUMMARY = "Valgrind memory debugger and instrumentation framework"
+HOMEPAGE = "http://valgrind.org/"
+BUGTRACKER = "http://valgrind.org/support/bug_reports.html"
+LICENSE = "GPLv2 & GPLv2+ & BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                    file://include/pub_tool_basics.h;beginline=6;endline=29;md5=d4de0407239381463cf01dd276d7c22e \
+                    file://include/valgrind.h;beginline=1;endline=56;md5=ad3b317f3286b6b704575d9efe6ca5df \
+                    file://COPYING.DOCS;md5=24ea4c7092233849b4394699333b5c56"
+
+X11DEPENDS = "virtual/libx11"
+DEPENDS = "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '${X11DEPENDS}', '', d)} \
+           ${@bb.utils.contains('DISTRO_FEATURES', 'ptest', 'boost', '', d)} \
+        "
+
+SRC_URI = "http://www.valgrind.org/downloads/valgrind-${PV}.tar.bz2 \
+           file://fixed-perl-path.patch \
+           file://Added-support-for-PPC-instructions-mfatbu-mfatbl.patch \
+           file://run-ptest \
+           file://0004-Fix-out-of-tree-builds.patch \
+           file://0005-Modify-vg_test-wrapper-to-support-PTEST-formats.patch \
+           file://0001-Remove-tests-that-fail-to-build-on-some-PPC32-config.patch \
+           file://use-appropriate-march-mcpu-mfpu-for-ARM-test-apps.patch \
+           file://avoid-neon-for-targets-which-don-t-support-it.patch \
+           file://valgrind-make-ld-XXX.so-strlen-intercept-optional.patch \
+           file://0001-makefiles-Drop-setting-mcpu-to-cortex-a8-on-arm-arch.patch \
+           file://0001-str_tester.c-Limit-rawmemchr-test-to-glibc.patch \
+           file://0001-sigqueue-Rename-_sifields-to-__si_fields-on-musl.patch \
+           file://0002-context-APIs-are-not-available-on-musl.patch \
+           file://0003-correct-include-directive-path-for-config.h.patch \
+           file://0004-pth_atfork1.c-Define-error-API-for-musl.patch \
+           file://0005-tc20_verifywrap.c-Fake-__GLIBC_PREREQ-with-musl.patch \
+           file://0006-pth_detached3.c-Dereference-pthread_t-before-adding-.patch \
+           file://0001-memcheck-arm64-Define-__THROW-if-not-already-defined.patch \
+           file://0002-memcheck-x86-Define-__THROW-if-not-defined.patch \
+           file://0003-tests-seg_override-Replace-__modify_ldt-with-syscall.patch \
+           file://0001-fix-opcode-not-supported-on-mips32-linux.patch \
+           file://0001-Guard-against-__GLIBC_PREREQ-for-musl-libc.patch \
+           file://0001-Make-local-functions-static-to-avoid-assembler-error.patch \
+           "
+SRC_URI[md5sum] = "74175426afa280184b62591b58c671b3"
+SRC_URI[sha256sum] = "037c11bfefd477cc6e9ebe8f193bb237fe397f7ce791b4a4ce3fa1c6a520baa5"
+UPSTREAM_CHECK_REGEX = "valgrind-(?P<pver>\d+(\.\d+)+)\.tar"
+
+COMPATIBLE_HOST = '(i.86|x86_64|arm|aarch64|mips|powerpc|powerpc64).*-linux'
+
+# valgrind supports armv7 and above
+COMPATIBLE_HOST_armv4 = 'null'
+COMPATIBLE_HOST_armv5 = 'null'
+COMPATIBLE_HOST_armv6 = 'null'
+
+# X32 isn't supported by valgrind at this time
+COMPATIBLE_HOST_linux-gnux32 = 'null'
+COMPATIBLE_HOST_linux-muslx32 = 'null'
+
+# Disable for some MIPS variants
+COMPATIBLE_HOST_mipsarchr6 = 'null'
+COMPATIBLE_HOST_linux-gnun32 = 'null'
+
+inherit autotools ptest multilib_header
+
+EXTRA_OECONF = "--enable-tls --without-mpicc"
+EXTRA_OECONF += "${@['--enable-only32bit','--enable-only64bit'][d.getVar('SITEINFO_BITS') != '32']}"
+
+# valgrind checks host_cpu "armv7*)", so we need to over-ride the autotools.bbclass default --host option
+EXTRA_OECONF_append_arm = " --host=armv7${HOST_VENDOR}-${HOST_OS}"
+TARGET_CC_ARCH_remove_arm = "${@get_mcpu(d)}"
+
+EXTRA_OEMAKE = "-w"
+
+CACHED_CONFIGUREVARS += "ac_cv_path_PERL='/usr/bin/env perl'"
+
+# valgrind likes to control its own optimisation flags. It generally defaults
+# to -O2 but uses -O0 for some specific test apps etc. Passing our own flags
+# (via CFLAGS) means we interfere with that. Only pass DEBUG_FLAGS to it
+# which fixes build path issue in DWARF.
+SELECTED_OPTIMIZATION = "${DEBUG_FLAGS}"
+
+def get_mcpu(d):
+    for arg in (d.getVar('TUNE_CCARGS') or '').split():
+        if arg.startswith('-mcpu='):
+            return arg
+        else:
+            continue
+    return ""
+
+do_configure_prepend () {
+    rm -rf ${S}/config.h
+    sed -i -e 's:$(abs_top_builddir):$(pkglibdir)/ptest:g' ${S}/none/tests/Makefile.am
+    sed -i -e 's:$(top_builddir):$(pkglibdir)/ptest:g' ${S}/memcheck/tests/Makefile.am
+}
+
+do_install_append () {
+    install -m 644 ${B}/default.supp ${D}/${libdir}/valgrind/
+    oe_multilib_header valgrind/config.h
+}
+
+TUNE = "${@strip_mcpu(d)}"
+
+RDEPENDS_${PN} += "perl"
+
+# valgrind needs debug information for ld.so at runtime in order to
+# redirect functions like strlen.
+RRECOMMENDS_${PN} += "${TCLIBC}-dbg"
+
+RDEPENDS_${PN}-ptest += " sed perl perl-module-file-glob"
+RDEPENDS_${PN}-ptest_append_libc-glibc = " glibc-utils"
+
+# One of the tests contains a bogus interpreter path on purpose.
+# Skip file dependency check
+SKIP_FILEDEPS_${PN}-ptest = '1'
+
+do_compile_ptest() {
+    oe_runmake check
+}
+
+do_install_ptest() {
+    chmod +x ${B}/tests/vg_regtest
+
+    # The test application binaries are not automatically installed.
+    # Grab them from the build directory.
+    #
+    # The regression tests require scripts and data files that are not
+    # copied to the build directory.  They must be copied from the
+    # source directory. 
+    saved_dir=$PWD
+    for parent_dir in ${S} ${B} ; do
+        cd $parent_dir
+
+        # exclude shell or the package won't install
+        rm -rf none/tests/shell* 2>/dev/null
+
+        subdirs="tests cachegrind/tests callgrind/tests drd/tests helgrind/tests massif/tests memcheck/tests none/tests"
+
+        # Get the vg test scripts, filters, and expected files
+        for dir in $subdirs ; do
+            find $dir | cpio -pvdu ${D}${PTEST_PATH}
+        done
+        cd $saved_dir
+    done
+
+    # clean out build artifacts before building the rpm
+    find ${D}${PTEST_PATH} \
+         \( -name "Makefile*" \
+        -o -name "*.o" \
+        -o -name "*.c" \
+        -o -name "*.S" \
+        -o -name "*.h" \) \
+        -exec rm {} \;
+
+    # needed by massif tests
+    cp ${B}/massif/ms_print ${D}${PTEST_PATH}/massif/ms_print
+
+    # handle multilib
+    sed -i s:@libdir@:${libdir}:g ${D}${PTEST_PATH}/run-ptest
+}
diff --git a/poky/meta/recipes-devtools/yasm/yasm_1.3.0.bb b/poky/meta/recipes-devtools/yasm/yasm_1.3.0.bb
deleted file mode 100644
index 31af1e2..0000000
--- a/poky/meta/recipes-devtools/yasm/yasm_1.3.0.bb
+++ /dev/null
@@ -1,16 +0,0 @@
-SUMMARY = "x86 (SSE) assembler supporting NASM and GAS-syntaxes"
-LICENSE = "BSD"
-HOMEPAGE = "http://www.tortall.net/projects/yasm/"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=a12d8903508fb6bfd49d8d82c6170dd9"
-
-SRC_URI = "http://www.tortall.net/projects/yasm/releases/${BP}.tar.gz"
-
-SRC_URI[md5sum] = "fc9e586751ff789b34b1f21d572d96af"
-SRC_URI[sha256sum] = "3dce6601b495f5b3d45b59f7d2492a340ee7e84b5beca17e48f862502bd5603f"
-
-export CCLD_FOR_BUILD = "${CC_FOR_BUILD}"
-
-inherit autotools gettext
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-extended/acpica/acpica_20170303.bb b/poky/meta/recipes-extended/acpica/acpica_20170303.bb
deleted file mode 100644
index 51ae77b..0000000
--- a/poky/meta/recipes-extended/acpica/acpica_20170303.bb
+++ /dev/null
@@ -1,53 +0,0 @@
-SUMMARY = "ACPICA tools for the development and debug of ACPI tables"
-DESCRIPTION = "The ACPI Component Architecture (ACPICA) project provides an \
-OS-independent reference implementation of the Advanced Configuration and \
-Power Interface Specification (ACPI). ACPICA code contains those portions of \
-ACPI meant to be directly integrated into the host OS as a kernel-resident \
-subsystem, and a small set of tools to assist in developing and debugging \
-ACPI tables."
-
-HOMEPAGE = "http://www.acpica.org/"
-SECTION = "console/tools"
-
-LICENSE = "BSD | GPLv2"
-LIC_FILES_CHKSUM = "file://generate/unix/readme.txt;md5=204407e197c1a01154a48f6c6280c3aa"
-
-COMPATIBLE_HOST = "(i.86|x86_64|arm|aarch64).*-linux"
-
-DEPENDS = "bison flex"
-
-SRC_URI = "https://acpica.org/sites/acpica/files/acpica-unix2-${PV}.tar.gz \
-    file://rename-yy_scan_string-manually.patch \
-    file://manipulate-fds-instead-of-FILE.patch;striplevel=2 \
-    file://0001-Linux-add-support-for-X32-ABI-compilation.patch \
-    "
-SRC_URI[md5sum] = "48ef4314fb4ffdd0c96f14dcf20544e1"
-SRC_URI[sha256sum] = "b2d81e84107ac9a02be86ea43cbea7afa8fd4b4150270bc88c2d4c9fea0b8aad"
-UPSTREAM_CHECK_URI = "https://acpica.org/downloads"
-
-S = "${WORKDIR}/acpica-unix2-${PV}"
-
-inherit update-alternatives
-
-ALTERNATIVE_PRIORITY = "100"
-ALTERNATIVE_${PN} = "acpixtract"
-
-EXTRA_OEMAKE = "CC='${CC}' 'OPT_CFLAGS=-Wall'"
-
-do_install() {
-    install -D -p -m0755 generate/unix/bin*/iasl ${D}${bindir}/iasl
-    install -D -p -m0755 generate/unix/bin*/acpibin ${D}${bindir}/acpibin
-    install -D -p -m0755 generate/unix/bin*/acpiexec ${D}${bindir}/acpiexec
-    install -D -p -m0755 generate/unix/bin*/acpihelp ${D}${bindir}/acpihelp
-    install -D -p -m0755 generate/unix/bin*/acpinames ${D}${bindir}/acpinames
-    install -D -p -m0755 generate/unix/bin*/acpisrc ${D}${bindir}/acpisrc
-    install -D -p -m0755 generate/unix/bin*/acpixtract ${D}${bindir}/acpixtract
-}
-
-# iasl*.bb is a subset of this recipe, so RREPLACE it
-PROVIDES = "iasl"
-RPROVIDES_${PN} += "iasl"
-RREPLACES_${PN} += "iasl"
-RCONFLICTS_${PN} += "iasl"
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-extended/acpica/acpica_20180508.bb b/poky/meta/recipes-extended/acpica/acpica_20180508.bb
new file mode 100644
index 0000000..b5c89fa
--- /dev/null
+++ b/poky/meta/recipes-extended/acpica/acpica_20180508.bb
@@ -0,0 +1,52 @@
+SUMMARY = "ACPICA tools for the development and debug of ACPI tables"
+DESCRIPTION = "The ACPI Component Architecture (ACPICA) project provides an \
+OS-independent reference implementation of the Advanced Configuration and \
+Power Interface Specification (ACPI). ACPICA code contains those portions of \
+ACPI meant to be directly integrated into the host OS as a kernel-resident \
+subsystem, and a small set of tools to assist in developing and debugging \
+ACPI tables."
+
+HOMEPAGE = "http://www.acpica.org/"
+SECTION = "console/tools"
+
+LICENSE = "BSD | GPLv2"
+LIC_FILES_CHKSUM = "file://generate/unix/readme.txt;md5=204407e197c1a01154a48f6c6280c3aa"
+
+COMPATIBLE_HOST = "(i.86|x86_64|arm|aarch64).*-linux"
+
+DEPENDS = "bison flex bison-native"
+
+SRC_URI = "https://acpica.org/sites/acpica/files/acpica-unix2-${PV}.tar.gz \
+           file://rename-yy_scan_string-manually.patch \
+           file://manipulate-fds-instead-of-FILE.patch \
+           "
+SRC_URI[md5sum] = "31691e2eb82b2064f78536a3423c18d6"
+SRC_URI[sha256sum] = "5d8fc9d9db9e04830d40bec9add04b21c05d466e0187d354815006fdd823cf15"
+UPSTREAM_CHECK_URI = "https://acpica.org/downloads"
+
+S = "${WORKDIR}/acpica-unix2-${PV}"
+
+inherit update-alternatives
+
+ALTERNATIVE_PRIORITY = "100"
+ALTERNATIVE_${PN} = "acpixtract"
+
+EXTRA_OEMAKE = "CC='${CC}' 'OPT_CFLAGS=-Wall'"
+
+do_install() {
+    install -D -p -m0755 generate/unix/bin*/iasl ${D}${bindir}/iasl
+    install -D -p -m0755 generate/unix/bin*/acpibin ${D}${bindir}/acpibin
+    install -D -p -m0755 generate/unix/bin*/acpiexec ${D}${bindir}/acpiexec
+    install -D -p -m0755 generate/unix/bin*/acpihelp ${D}${bindir}/acpihelp
+    install -D -p -m0755 generate/unix/bin*/acpinames ${D}${bindir}/acpinames
+    install -D -p -m0755 generate/unix/bin*/acpisrc ${D}${bindir}/acpisrc
+    install -D -p -m0755 generate/unix/bin*/acpixtract ${D}${bindir}/acpixtract
+}
+
+# iasl*.bb is a subset of this recipe, so RREPLACE it
+PROVIDES = "iasl"
+RPROVIDES_${PN} += "iasl"
+RREPLACES_${PN} += "iasl"
+RCONFLICTS_${PN} += "iasl"
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-extended/acpica/files/0001-Linux-add-support-for-X32-ABI-compilation.patch b/poky/meta/recipes-extended/acpica/files/0001-Linux-add-support-for-X32-ABI-compilation.patch
deleted file mode 100644
index df74200..0000000
--- a/poky/meta/recipes-extended/acpica/files/0001-Linux-add-support-for-X32-ABI-compilation.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From d22241efc0708c9799f17a20eabb52a48d6d6ea1 Mon Sep 17 00:00:00 2001
-From: Anuj Mittal <anuj.mittal@intel.com>
-Date: Tue, 2 Jan 2018 12:35:32 +0800
-Subject: [PATCH] Linux: add support for X32 ABI compilation
-
-X32 follows ILP32 model. Check for ILP32 as well when checking for
-x86_64 to ensure the defines are correct for X32 ABI.
-
-Upstream-Status: Submitted [https://github.com/acpica/acpica/pull/348]
-
-Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
----
- source/include/platform/aclinux.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/source/include/platform/aclinux.h b/source/include/platform/aclinux.h
-index 75b1d82..6b8ff73 100644
---- a/source/include/platform/aclinux.h
-+++ b/source/include/platform/aclinux.h
-@@ -315,7 +315,7 @@
- #define ACPI_FLUSH_CPU_CACHE()
- #define ACPI_CAST_PTHREAD_T(Pthread) ((ACPI_THREAD_ID) (Pthread))
- 
--#if defined(__ia64__)    || defined(__x86_64__) ||\
-+#if defined(__ia64__)    || (defined(__x86_64__) && !defined(__ILP32__)) ||\
-     defined(__aarch64__) || defined(__PPC64__) ||\
-     defined(__s390x__)
- #define ACPI_MACHINE_WIDTH          64
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-extended/acpica/files/manipulate-fds-instead-of-FILE.patch b/poky/meta/recipes-extended/acpica/files/manipulate-fds-instead-of-FILE.patch
index 5610ed9..d8b5f9a 100644
--- a/poky/meta/recipes-extended/acpica/files/manipulate-fds-instead-of-FILE.patch
+++ b/poky/meta/recipes-extended/acpica/files/manipulate-fds-instead-of-FILE.patch
@@ -1,4 +1,4 @@
-From 69171c22f3872ecb4c1ab27985e93ca44084595e Mon Sep 17 00:00:00 2001
+From 540d80469e6a7dce6baf7214df90e86daffc5175 Mon Sep 17 00:00:00 2001
 From: Fan Xin <fan.xin@jp.fujitsu.com>
 Date: Mon, 5 Jun 2017 13:26:38 +0900
 Subject: [PATCH] aslfiles.c: manipulate fds instead of FILE
@@ -16,18 +16,20 @@
 Rebase on acpica 20170303
 
 Signed-off-by: Fan Xin <fan.xin@jp.fujitsu.com>
----
- acpica-unix2-20170303/source/compiler/aslfiles.c | 14 +++++++++++---
- 1 file changed, 11 insertions(+), 3 deletions(-)
 
-diff --git a/acpica-unix2-20170303/source/compiler/aslfiles.c b/acpica-unix2-20170303/source/compiler/aslfiles.c
-index 809090c..97898b1 100644
---- a/acpica-unix2-20170303/source/compiler/aslfiles.c
-+++ b/acpica-unix2-20170303/source/compiler/aslfiles.c
-@@ -44,6 +44,10 @@
+---
+ source/compiler/aslfiles.c | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/source/compiler/aslfiles.c b/source/compiler/aslfiles.c
+index 82865db..cc072dc 100644
+--- a/source/compiler/aslfiles.c
++++ b/source/compiler/aslfiles.c
+@@ -43,6 +43,11 @@
+ 
  #include "aslcompiler.h"
  #include "acapps.h"
- #include "dtcompiler.h"
++#include "dtcompiler.h"
 +#include <sys/types.h>
 +#include <sys/stat.h>
 +#include <fcntl.h>
@@ -35,7 +37,7 @@
  
  #define _COMPONENT          ACPI_COMPILER
          ACPI_MODULE_NAME    ("aslfiles")
-@@ -607,6 +611,8 @@ FlOpenMiscOutputFiles (
+@@ -606,6 +611,8 @@ FlOpenMiscOutputFiles (
  
      if (Gbl_DebugFlag)
      {
@@ -44,7 +46,7 @@
          Filename = FlGenerateFilename (FilenamePrefix, FILE_SUFFIX_DEBUG);
          if (!Filename)
          {
-@@ -618,10 +624,10 @@ FlOpenMiscOutputFiles (
+@@ -617,10 +624,10 @@ FlOpenMiscOutputFiles (
          /* Open the debug file as STDERR, text mode */
  
          Gbl_Files[ASL_FILE_DEBUG_OUTPUT].Filename = Filename;
@@ -58,7 +60,7 @@
          {
              /*
               * A problem with freopen is that on error, we no longer
-@@ -635,6 +641,8 @@ FlOpenMiscOutputFiles (
+@@ -634,6 +641,8 @@ FlOpenMiscOutputFiles (
              exit (1);
          }
  
@@ -67,6 +69,3 @@
          AslCompilerSignon (ASL_FILE_DEBUG_OUTPUT);
          AslCompilerFileHeader (ASL_FILE_DEBUG_OUTPUT);
      }
--- 
-1.9.1
-
diff --git a/poky/meta/recipes-extended/bash/bash/bash-memleak-bug-fix-for-builtin-command-read.patch b/poky/meta/recipes-extended/bash/bash/bash-memleak-bug-fix-for-builtin-command-read.patch
deleted file mode 100644
index 9fb6ba9..0000000
--- a/poky/meta/recipes-extended/bash/bash/bash-memleak-bug-fix-for-builtin-command-read.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From d3b6303a6853f612a56848ee4e59eaa0b0ab9489 Mon Sep 17 00:00:00 2001
-From: Zhang Xiao <xiao.zhang@windriver.com>
-Date: Tue, 21 Feb 2017 11:30:14 +0800
-Subject: [PATCH] bash: memleak bug fix for builtin command read
-
-Built in command "read" with "-e" use Readline to obtain the line
-in an interactive shell. In this process, a string "rlbuf" is
-just allocated without free operation thus cause memory leak. Fix it.
-
-Upstream-Status: Submitted [http://lists.gnu.org/archive/html/bug-bash/2017-02/msg00061.html]
-
-Signed-off-by: Zhang Xiao <xiao.zhang@windriver.com>
----
- builtins/read.def | 5 +++++
- 1 file changed, 5 insertions(+)
-
-diff --git a/builtins/read.def b/builtins/read.def
-index 4397154..ee0c5a6 100644
---- a/builtins/read.def
-+++ b/builtins/read.def
-@@ -674,6 +674,11 @@ add_char:
-   input_string[i] = '\0';
-   CHECK_ALRM;
- 
-+#if defined (READLINE)
-+  if (edit)
-+    xfree (rlbuf);
-+#endif
-+
-   if (retval < 0)
-     {
-       t_errno = errno;
--- 
-1.9.1
-
diff --git a/poky/meta/recipes-extended/bash/bash_4.4.12.bb b/poky/meta/recipes-extended/bash/bash_4.4.12.bb
deleted file mode 100644
index 9382a77..0000000
--- a/poky/meta/recipes-extended/bash/bash_4.4.12.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-require bash.inc
-
-# GPLv2+ (< 4.0), GPLv3+ (>= 4.0)
-LICENSE = "GPLv3+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
-
-SRC_URI = "${GNU_MIRROR}/bash/${BP}.tar.gz;name=tarball \
-           file://execute_cmd.patch;striplevel=0 \
-           file://mkbuiltins_have_stringize.patch \
-           file://build-tests.patch \
-           file://test-output.patch \
-           file://fix-run-coproc-run-heredoc-run-execscript-run-test-f.patch \
-           file://run-ptest \
-           file://fix-run-builtins.patch \
-           file://0001-help-fix-printf-format-security-warning.patch \
-           file://bash-memleak-bug-fix-for-builtin-command-read.patch \
-           file://pathexp-dep.patch \
-           "
-
-SRC_URI[tarball.md5sum] = "7c112970cbdcadfc331e10eeb5f6aa41"
-SRC_URI[tarball.sha256sum] = "57d8432be54541531a496fd4904fdc08c12542f43605a9202594fa5d5f9f2331"
-
-
-BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-extended/bash/bash_4.4.18.bb b/poky/meta/recipes-extended/bash/bash_4.4.18.bb
new file mode 100644
index 0000000..8fa0978
--- /dev/null
+++ b/poky/meta/recipes-extended/bash/bash_4.4.18.bb
@@ -0,0 +1,41 @@
+require bash.inc
+
+# GPLv2+ (< 4.0), GPLv3+ (>= 4.0)
+LICENSE = "GPLv3+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
+
+SRC_URI = "${GNU_MIRROR}/bash/${BP}.tar.gz;name=tarball \
+           ${GNU_MIRROR}/bash/bash-4.4-patches/bash44-019;apply=yes;striplevel=0;name=patch019 \
+           ${GNU_MIRROR}/bash/bash-4.4-patches/bash44-020;apply=yes;striplevel=0;name=patch020 \
+           ${GNU_MIRROR}/bash/bash-4.4-patches/bash44-021;apply=yes;striplevel=0;name=patch021 \
+           ${GNU_MIRROR}/bash/bash-4.4-patches/bash44-022;apply=yes;striplevel=0;name=patch022 \
+           ${GNU_MIRROR}/bash/bash-4.4-patches/bash44-023;apply=yes;striplevel=0;name=patch023 \
+           file://execute_cmd.patch;striplevel=0 \
+           file://mkbuiltins_have_stringize.patch \
+           file://build-tests.patch \
+           file://test-output.patch \
+           file://fix-run-coproc-run-heredoc-run-execscript-run-test-f.patch \
+           file://run-ptest \
+           file://fix-run-builtins.patch \
+           file://0001-help-fix-printf-format-security-warning.patch \
+           file://pathexp-dep.patch \
+           "
+
+SRC_URI[tarball.md5sum] = "518e2c187cc11a17040f0915dddce54e"
+SRC_URI[tarball.sha256sum] = "604d9eec5e4ed5fd2180ee44dd756ddca92e0b6aa4217bbab2b6227380317f23"
+
+SRC_URI[patch019.md5sum] = "8f43e1d277b02f3319a34c1cd4a4ff3e"
+SRC_URI[patch019.sha256sum] = "27170d6edfe8819835407fdc08b401d2e161b1400fe9d0c5317a51104c89c11e"
+SRC_URI[patch020.md5sum] = "5217ff08c444446ec306dce60437c288"
+SRC_URI[patch020.sha256sum] = "1840e2cbf26ba822913662f74037594ed562361485390c52813b38156c99522c"
+SRC_URI[patch021.md5sum] = "282c7d9b38da8005d25b4f816328a2f4"
+SRC_URI[patch021.sha256sum] = "bd8f59054a763ec1c64179ad5cb607f558708a317c2bdb22b814e3da456374c1"
+SRC_URI[patch022.md5sum] = "0b709c9d7f8e6cf267a8b863efb899f7"
+SRC_URI[patch022.sha256sum] = "45331f0936e36ab91bfe44b936e33ed8a1b1848fa896e8a1d0f2ef74f297cb79"
+SRC_URI[patch023.md5sum] = "fe2e0ca4cf9409ff0e9428e1236f983e"
+SRC_URI[patch023.sha256sum] = "4fec236f3fbd3d0c47b893fdfa9122142a474f6ef66c20ffb6c0f4864dd591b6"
+
+DEBUG_OPTIMIZATION_append_armv4 = " ${@bb.utils.contains('TUNE_CCARGS', '-mthumb', '-fomit-frame-pointer', '', d)}"
+DEBUG_OPTIMIZATION_append_armv5 = " ${@bb.utils.contains('TUNE_CCARGS', '-mthumb', '-fomit-frame-pointer', '', d)}"
+
+BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-extended/bc/bc/libmath.h b/poky/meta/recipes-extended/bc/bc/libmath.h
new file mode 100644
index 0000000..63e1acb
--- /dev/null
+++ b/poky/meta/recipes-extended/bc/bc/libmath.h
@@ -0,0 +1,46 @@
+{"@iK20:s2:p@r",
+"@iF1,5.6,7,8,9,10,11,12,13,14,15[l0:KA:#Z1:l0:s7:pKA:s0:pl5:C1,0:",
+"s14:pl7:s0:pl14:RN1:l5:0<Z2:1s12:pl5:ns5:pN2:l2:s15:pK6:l15:+",
+"K.44:l5:*+s13:pl5:cS1+s2:pN3:l5:1>Z4:l10:1+s10:pl5:K2:/s5:pl2:",
+"1+s2:pJ3:N4:l13:s2:p1l5:+s14:pl5:s6:p1s8:pK2:s11:pN6:1B7:J5:N8:",
+"l11:i11:pJ6:N7:l6:l5:*s6:l8:l11:*s8:/s9:pl9:0=Z9:l10:0>Z10:N11:",
+"l10:d10:Z12:l14:l14:*s14:pJ11:N12:N10:l15:s2:pl12:Z13:1l14:/R",
+"N13:l14:1/RN9:l14:l9:+s14:pJ8:N5:0R]@r",
+"@iF2,5.7,9,10,11,12,13,14,15[l0:KA:#Z1:l0:s7:pKA:s0:pl5:C2,0:",
+"s14:pl7:s0:pl14:RN1:l5:0{Z2:1K10:l2:^-1/RN2:l2:s15:pK6:l2:+s2:",
+"pK2:s10:p0s11:pN3:l5:K2:}Z4:l10:K2:*s10:pl5:cRs5:pJ3:N4:N5:l5:",
+"K.5:{Z6:l10:K2:*s10:pl5:cRs5:pJ5:N6:l5:1-l5:1+/s13:s14:pl13:l13:",
+"*s12:pK3:s11:pN8:1B9:J7:N10:l11:K2:+s11:pJ8:N9:l13:l12:*s13:l11:",
+"/s9:pl9:0=Z11:l10:l14:*s14:pl15:s2:pl14:1/RN11:l14:l9:+s14:pJ10:N7:",
+"0R]@r",
+"@iF3,5.7,9,11,12,13,16,14,15[l0:KA:#Z1:l0:s7:pKA:s0:pl5:C3,0:",
+"s14:pl7:s0:pl14:RN1:l2:s15:pK1.1:l15:*K2:+s2:p1C4,0:s14:pl5:0",
+"<Z2:1s12:pl5:ns5:pN2:0s2:pl5:l14:/K2:+K4:/s13:pl5:K4:l13:*l14:",
+"*-s5:pl13:K2:%Z3:l5:ns5:pN3:l15:K2:+s2:pl5:s9:s14:pl5:nl5:*s16:",
+"pK3:s11:pN5:1B6:J4:N7:l11:K2:+s11:pJ5:N6:l9:l16:l11:l11:1-*/*",
+"s9:pl9:0=Z8:l15:s2:pl12:Z9:l14:n1/RN9:l14:1/RN8:l14:l9:+s14:p",
+"J7:N4:0R]@r",
+"@iF5,5.7,14,15[l0:KA:#Z1:l0:s7:pKA:s0:pl5:C5,0:s14:pl7:s0:pl14:",
+"RN1:l2:s15:pl2:K1.2:*s2:pl5:1C4,0:K2:*+C3,0:s14:pl15:s2:pl14:",
+"1/R0R]@r",
+"@iF4,5.6,7,9,10,11,12,13,16,14,15[l0:KA:#Z1:l0:s7:pKA:s0:pl5:",
+"C4,0:s14:pl7:s0:pl14:RN1:1s12:pl5:0<Z2:1ns12:pl5:ns5:pN2:l5:1",
+"=Z3:l2:K25:{Z4:K.7853981633974483096156608:l12:/RN4:l2:K40:{Z5:",
+"K.7853981633974483096156608458198757210492:l12:/RN5:l2:K60:{Z6:",
+"K.785398163397448309615660845819875721049292349843776455243736",
+":l12:/RN6:N3:l5:K.2:=Z7:l2:K25:{Z8:K.1973955598498807583700497",
+":l12:/RN8:l2:K40:{Z9:K.1973955598498807583700497651947902934475",
+":l12:/RN9:l2:K60:{Z10:K.197395559849880758370049765194790293447585103787852101517688",
+":l12:/RN10:N7:l2:s15:pl5:K.2:>Z11:l15:K5:+s2:pK.2:C4,0:s6:pN11:",
+"l15:K3:+s2:pN12:l5:K.2:>Z13:l10:1+s10:pl5:K.2:-1l5:K.2:*+/s5:",
+"pJ12:N13:l5:s13:s14:pl5:nl5:*s16:pK3:s11:pN15:1B16:J14:N17:l11:",
+"K2:+s11:pJ15:N16:l13:l16:*s13:l11:/s9:pl9:0=Z18:l15:s2:pl10:l6:",
+"*l14:+l12:/RN18:l14:l9:+s14:pJ17:N14:0R]@r",
+"@iF6,13,5.6,7,8,9,10,11,12,16,14,15[l0:KA:#Z1:l0:s7:pKA:s0:pl13:",
+"l5:C6,00:s14:pl7:s0:pl14:RN1:l2:s15:p0s2:pl13:1/s13:pl13:0<Z2:",
+"l13:ns13:pl13:K2:%1=Z3:1s12:pN3:N2:1s10:pK2:s11:pN5:l11:l13:{",
+"B6:J4:N7:l11:i11:pJ5:N6:l10:l11:*s10:pJ7:N4:K1.5:l15:*s2:pl5:",
+"l13:^K2:l13:^/l10:/s10:p1s9:s14:pl5:nl5:*K4:/s16:pK1.5:l15:*l10:",
+"cL+l10:cS-s2:p1s11:pN9:1B10:J8:N11:l11:i11:pJ9:N10:l9:l16:*l11:",
+"/l13:l11:+/s9:pl9:0=Z12:l15:s2:pl12:Z13:l10:nl14:*1/RN13:l10:",
+"l14:*1/RN12:l14:l9:+s14:pJ11:N8:0R]@r",0}
diff --git a/poky/meta/recipes-extended/bc/bc/no-gen-libmath.patch b/poky/meta/recipes-extended/bc/bc/no-gen-libmath.patch
new file mode 100644
index 0000000..c4cce58
--- /dev/null
+++ b/poky/meta/recipes-extended/bc/bc/no-gen-libmath.patch
@@ -0,0 +1,24 @@
+These rules are not cross-friendly so delete them and we'll generate the file offline.
+
+Upstream-Status: Inappropriate
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+diff --git a/bc/Makefile.am b/bc/Makefile.am
+index d9d412e..f244241 100644
+--- a/bc/Makefile.am
++++ b/bc/Makefile.am
+@@ -31,14 +31,6 @@ global.o: libmath.h
+ 
+ fbcOBJ = main.o bc.o scan.o execute.o load.o storage.o util.o warranty.o
+ 
+-libmath.h: libmath.b $(fbcOBJ) $(LIBBC)
+-	echo '{0}' > libmath.h
+-	$(MAKE) global.o
+-	$(LINK) -o fbc $(fbcOBJ) global.o $(LIBBC) $(LIBL) $(READLINELIB) $(LIBS)
+-	./fbc -c $(srcdir)/libmath.b </dev/null >libmath.h
+-	$(srcdir)/fix-libmath_h
+-	rm -f ./fbc ./global.o
+-
+ sbcOBJ = main.o sbc.o scan.o execute.o global.o load.o storage.o util.o \
+          warranty.o
+ sbc.o: sbc.c
diff --git a/poky/meta/recipes-extended/bc/bc_1.06.bb b/poky/meta/recipes-extended/bc/bc_1.06.bb
deleted file mode 100644
index d8c8a86..0000000
--- a/poky/meta/recipes-extended/bc/bc_1.06.bb
+++ /dev/null
@@ -1,26 +0,0 @@
-SUMMARY = "Arbitrary precision calculator language"
-HOMEPAGE = "http://www.gnu.org/software/bc/bc.html"
-
-LICENSE = "GPLv2+ & LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
-                    file://COPYING.LIB;md5=d8045f3b8f929c1cb29a1e3fd737b499 \
-                    file://bc/bcdefs.h;endline=31;md5=46dffdaf10a99728dd8ce358e45d46d8 \
-                    file://dc/dc.h;endline=25;md5=2f9c558cdd80e31b4d904e48c2374328 \
-                    file://lib/number.c;endline=31;md5=99434a0898abca7784acfd36b8191199"
-
-SECTION = "base"
-DEPENDS = "flex"
-PR = "r3"
-
-SRC_URI = "${GNU_MIRROR}/bc/bc-${PV}.tar.gz \
-           file://fix-segment-fault.patch "
-
-SRC_URI[md5sum] = "d44b5dddebd8a7a7309aea6c36fda117"
-SRC_URI[sha256sum] = "4ef6d9f17c3c0d92d8798e35666175ecd3d8efac4009d6457b5c99cea72c0e33"
-
-inherit autotools texinfo update-alternatives
-
-ALTERNATIVE_${PN} = "dc"
-ALTERNATIVE_PRIORITY = "100"
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-extended/bc/bc_1.07.1.bb b/poky/meta/recipes-extended/bc/bc_1.07.1.bb
new file mode 100644
index 0000000..e808577
--- /dev/null
+++ b/poky/meta/recipes-extended/bc/bc_1.07.1.bb
@@ -0,0 +1,33 @@
+SUMMARY = "Arbitrary precision calculator language"
+HOMEPAGE = "http://www.gnu.org/software/bc/bc.html"
+
+LICENSE = "GPLv3+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
+                    file://COPYING.LIB;md5=6a6a8e020838b23406c81b19c1d46df6 \
+                    file://bc/bcdefs.h;endline=17;md5=4295c06df9e833519a342f7b5d43db06 \
+                    file://dc/dc.h;endline=18;md5=36b8c600b63ee8c3aeade2764f6b2a4b \
+                    file://lib/number.c;endline=20;md5=cf43068cc88f837731dc53240456cfaf"
+
+SECTION = "base"
+DEPENDS = "flex-native"
+
+SRC_URI = "${GNU_MIRROR}/${BPN}/${BP}.tar.gz \
+           file://no-gen-libmath.patch \
+           file://libmath.h"
+SRC_URI[md5sum] = "cda93857418655ea43590736fc3ca9fc"
+SRC_URI[sha256sum] = "62adfca89b0a1c0164c2cdca59ca210c1d44c3ffc46daf9931cf4942664cb02a"
+
+inherit autotools texinfo update-alternatives
+
+PACKAGECONFIG ??= "readline"
+PACKAGECONFIG[readline] = "--with-readline,--without-readline,readline"
+PACKAGECONFIG[libedit] = "--with-libedit,--without-libedit,libedit"
+
+do_compile_prepend() {
+    cp -f ${WORKDIR}/libmath.h ${B}/bc/libmath.h
+}
+
+ALTERNATIVE_${PN} = "dc"
+ALTERNATIVE_PRIORITY = "100"
+
+BBCLASSEXTEND = "native"
\ No newline at end of file
diff --git a/poky/meta/recipes-extended/bc/files/fix-segment-fault.patch b/poky/meta/recipes-extended/bc/files/fix-segment-fault.patch
deleted file mode 100644
index 20c0da2..0000000
--- a/poky/meta/recipes-extended/bc/files/fix-segment-fault.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-Upstream-Status: Pending
-
-when run command such as 'echo "a = 13" | bc -l', it segmentation faults.
-This patch is from http://www.mail-archive.com/blfs-support@linuxfromscratch.org/msg04602.html.
-
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
-
---- bc-1.06/lib/number.c.orig	2003-09-26 21:14:02.000000000 +0000
-+++ bc-1.06/lib/number.c	2003-09-26 21:14:26.000000000 +0000
-@@ -34,6 +34,7 @@
- #include <number.h>
- #include <assert.h>
- #include <stdlib.h>
-+#include <string.h>
- #include <ctype.h>/* Prototypes needed for external utility routines. */
- 
- #define bc_rt_warn rt_warn
---- bc-1.06/bc/load.c.orig	2003-09-26 21:14:14.000000000 +0000
-+++ bc-1.06/bc/load.c	2003-09-26 21:14:26.000000000 +0000
-@@ -156,7 +156,7 @@
-   long  label_no;
-   long  vaf_name;	/* variable, array or function number. */
-   long  func;
--  program_counter save_adr;
-+  static program_counter save_adr;
- 
-   /* Initialize. */
-   str = code;
diff --git a/poky/meta/recipes-extended/blktool/blktool/0001-fix-typos-in-manpage.patch b/poky/meta/recipes-extended/blktool/blktool/0001-fix-typos-in-manpage.patch
index fee368d..25a2fab 100644
--- a/poky/meta/recipes-extended/blktool/blktool/0001-fix-typos-in-manpage.patch
+++ b/poky/meta/recipes-extended/blktool/blktool/0001-fix-typos-in-manpage.patch
@@ -7,7 +7,7 @@
 ftp://ftp.debian.org/debian/pool/main/b/blktool/blktool_4-7.debian.tar.xz
 
 Upstream-Status: Inappropriate [upstream is dead]
-Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
 
 ---
  blktool.8 | 4 ++--
diff --git a/poky/meta/recipes-extended/blktool/blktool/0002-fix-string-error.patch b/poky/meta/recipes-extended/blktool/blktool/0002-fix-string-error.patch
index d08aba5..401e41e 100644
--- a/poky/meta/recipes-extended/blktool/blktool/0002-fix-string-error.patch
+++ b/poky/meta/recipes-extended/blktool/blktool/0002-fix-string-error.patch
@@ -7,7 +7,7 @@
 ftp://ftp.debian.org/debian/pool/main/b/blktool/blktool_4-7.debian.tar.xz
 
 Upstream-Status: Inappropriate [upstream is dead]
-Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
 
 ---
  util.c | 2 +-
diff --git a/poky/meta/recipes-extended/blktool/blktool/0003-Fix-3-d-argument-for-BLKROSET-it-must-be-const-int.patch b/poky/meta/recipes-extended/blktool/blktool/0003-Fix-3-d-argument-for-BLKROSET-it-must-be-const-int.patch
index d7ed0b9..d1f1e79 100644
--- a/poky/meta/recipes-extended/blktool/blktool/0003-Fix-3-d-argument-for-BLKROSET-it-must-be-const-int.patch
+++ b/poky/meta/recipes-extended/blktool/blktool/0003-Fix-3-d-argument-for-BLKROSET-it-must-be-const-int.patch
@@ -14,7 +14,7 @@
 ftp://ftp.debian.org/debian/pool/main/b/blktool/blktool_4-7.debian.tar.xz
 
 Upstream-Status: Inappropriate [upstream is dead]
-Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
 
 ---
  blktool.c | 11 +++++++++--
diff --git a/poky/meta/recipes-extended/blktool/blktool/blktool-gnulib-makedev.patch b/poky/meta/recipes-extended/blktool/blktool/blktool-gnulib-makedev.patch
new file mode 100644
index 0000000..6eea608
--- /dev/null
+++ b/poky/meta/recipes-extended/blktool/blktool/blktool-gnulib-makedev.patch
@@ -0,0 +1,23 @@
+include <sys/sysmacros.h> for major/minor defintions
+
+Fixes
+
+| ../blktool-4.orig/blktool.c: In function 'detect_dev_class':
+| ../blktool-4.orig/blktool.c:295:10: warning: implicit declaration of function 'major' [-Wimplicit-function-declaration]
+|   switch (major(st_rdev)) {
+|           ^~~~~
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Index: blktool-4.orig/blktool.c
+===================================================================
+--- blktool-4.orig.orig/blktool.c
++++ blktool-4.orig/blktool.c
+@@ -27,6 +27,7 @@
+ #include <linux/cdrom.h>
+ #include <linux/major.h>
+ #include <scsi/scsi.h>
++#include <sys/sysmacros.h>
+ 
+ #include "blktool.h"
+ 
diff --git a/poky/meta/recipes-extended/blktool/blktool_4-7.bb b/poky/meta/recipes-extended/blktool/blktool_4-7.bb
index 4551c32..0e6f7ee 100644
--- a/poky/meta/recipes-extended/blktool/blktool_4-7.bb
+++ b/poky/meta/recipes-extended/blktool/blktool_4-7.bb
@@ -13,6 +13,7 @@
            file://0001-fix-typos-in-manpage.patch \
            file://0002-fix-string-error.patch \
            file://0003-Fix-3-d-argument-for-BLKROSET-it-must-be-const-int.patch \
+           file://blktool-gnulib-makedev.patch \
           "
 
 SRC_URI[tarball.md5sum] = "62edc09c9908107e69391c87f4f3fd40"
diff --git a/poky/meta/recipes-extended/bzip2/bzip2_1.0.6.bb b/poky/meta/recipes-extended/bzip2/bzip2_1.0.6.bb
index acbf80a..025f45c 100644
--- a/poky/meta/recipes-extended/bzip2/bzip2_1.0.6.bb
+++ b/poky/meta/recipes-extended/bzip2/bzip2_1.0.6.bb
@@ -5,7 +5,7 @@
 HOMEPAGE = "https://sourceware.org/bzip2/"
 SECTION = "console/utils"
 LICENSE = "bzip2"
-LIC_FILES_CHKSUM = "file://LICENSE;beginline=8;endline=37;md5=40d9d1eb05736d1bfc86cfdd9106e6b2"
+LIC_FILES_CHKSUM = "file://LICENSE;beginline=4;endline=37;md5=39406315f540c69bd05b1531daedd2ae"
 PR = "r5"
 
 SRC_URI = "http://downloads.yoctoproject.org/mirror/sources/${BP}.tar.gz \
@@ -20,6 +20,7 @@
 SRC_URI[sha256sum] = "a2848f34fcd5d6cf47def00461fcb528a0484d8edef8208d6d2e2909dc61d9cd"
 
 UPSTREAM_CHECK_URI = "https://www.sourceware.org/bzip2/"
+UPSTREAM_VERSION_UNKNOWN = "1"
 
 PACKAGES =+ "libbz2"
 
diff --git a/poky/meta/recipes-extended/cronie/cronie_1.5.1.bb b/poky/meta/recipes-extended/cronie/cronie_1.5.1.bb
deleted file mode 100644
index cfb8c21..0000000
--- a/poky/meta/recipes-extended/cronie/cronie_1.5.1.bb
+++ /dev/null
@@ -1,83 +0,0 @@
-SUMMARY = "Cron daemon for executing programs at set times"
-DESCRIPTION = "Cronie contains the standard UNIX daemon crond that runs \
-specified programs at scheduled times and related tools. It is based on the \
-original cron and has security and configuration enhancements like the \
-ability to use pam and SELinux."
-HOMEPAGE = "https://github.com/cronie-crond/cronie/"
-BUGTRACKER = "https://bugzilla.redhat.com"
-
-# Internet Systems Consortium License
-LICENSE = "ISC & BSD-3-Clause & BSD-2-Clause & GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=dd2a592170760e1386c769e1043b3722 \
-                    file://src/cron.c;endline=20;md5=b425c334265026177128353a142633b4 \
-                    file://src/popen.c;beginline=3;endline=31;md5=edd50742d8def712e9472dba353668a9"
-
-SECTION = "utils"
-
-UPSTREAM_CHECK_URI = "https://github.com/cronie-crond/${BPN}/releases/"
-
-SRC_URI = "https://github.com/cronie-crond/cronie/releases/download/cronie-${PV}/cronie-${PV}.tar.gz \
-           file://crond.init \
-           file://crontab \
-           file://crond.service \
-           ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${PAM_SRC_URI}', '', d)}"
-
-PAM_SRC_URI = "file://crond_pam_config.patch"
-PAM_DEPS = "libpam libpam-runtime pam-plugin-access pam-plugin-loginuid"
-
-SRC_URI[md5sum] = "910e6effcc032998b0a49fbd46322e18"
-SRC_URI[sha256sum] = "6c73666102a6b5d35e2eaf1bd06925f2d4b0cef8d3323c37286dda3089a85338"
-
-inherit autotools update-rc.d useradd systemd
-
-PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'pam', d)}"
-
-PACKAGECONFIG[audit] = "--with-audit,--without-audit,audit,"
-PACKAGECONFIG[pam] = "--with-pam,--without-pam,libpam,${PAM_DEPS}"
-
-INITSCRIPT_NAME = "crond"
-INITSCRIPT_PARAMS = "start 90 2 3 4 5 . stop 60 0 1 6 ."
-
-USERADD_PACKAGES = "${PN}"
-GROUPADD_PARAM_${PN} = "--system crontab"
-
-SYSTEMD_SERVICE_${PN} = "crond.service"
-
-do_install_append () {
-	install -d ${D}${sysconfdir}/sysconfig/
-	install -d ${D}${sysconfdir}/init.d/
-	install -m 0644 ${S}/crond.sysconfig ${D}${sysconfdir}/sysconfig/crond
-	install -m 0755 ${WORKDIR}/crond.init ${D}${sysconfdir}/init.d/crond
-
-	# install systemd unit files
-	install -d ${D}${systemd_unitdir}/system
-	install -m 0644 ${WORKDIR}/crond.service ${D}${systemd_unitdir}/system
-	sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
-	       -e 's,@SBINDIR@,${sbindir},g' \
-	       ${D}${systemd_unitdir}/system/crond.service
-
-	# below are necessary for a complete cron environment
-	install -d ${D}${localstatedir}/spool/cron
-	install -m 0755 ${WORKDIR}/crontab ${D}${sysconfdir}/
-	mkdir -p ${D}${sysconfdir}/cron.d
-	mkdir -p ${D}${sysconfdir}/cron.hourly
-	mkdir -p ${D}${sysconfdir}/cron.daily
-	mkdir -p ${D}${sysconfdir}/cron.weekly
-	mkdir -p ${D}${sysconfdir}/cron.monthly
-	touch ${D}${sysconfdir}/cron.deny
-
-	# below setting is necessary to allow normal user using crontab
-
-	# setgid for crontab binary
-	chown root:crontab ${D}${bindir}/crontab
-	chmod 2755 ${D}${bindir}/crontab
-
-	# allow 'crontab' group write to /var/spool/cron
-	chown root:crontab ${D}${localstatedir}/spool/cron
-	chmod 770 ${D}${localstatedir}/spool/cron
-
-	chmod 600 ${D}${sysconfdir}/crontab
-}
-
-FILES_${PN} += "${sysconfdir}/cron*"
-CONFFILES_${PN} += "${sysconfdir}/crontab"
diff --git a/poky/meta/recipes-extended/cronie/cronie_1.5.2.bb b/poky/meta/recipes-extended/cronie/cronie_1.5.2.bb
new file mode 100644
index 0000000..3abca7f
--- /dev/null
+++ b/poky/meta/recipes-extended/cronie/cronie_1.5.2.bb
@@ -0,0 +1,83 @@
+SUMMARY = "Cron daemon for executing programs at set times"
+DESCRIPTION = "Cronie contains the standard UNIX daemon crond that runs \
+specified programs at scheduled times and related tools. It is based on the \
+original cron and has security and configuration enhancements like the \
+ability to use pam and SELinux."
+HOMEPAGE = "https://github.com/cronie-crond/cronie/"
+BUGTRACKER = "https://bugzilla.redhat.com"
+
+# Internet Systems Consortium License
+LICENSE = "ISC & BSD-3-Clause & BSD-2-Clause & GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=dd2a592170760e1386c769e1043b3722 \
+                    file://src/cron.c;endline=20;md5=b425c334265026177128353a142633b4 \
+                    file://src/popen.c;beginline=3;endline=31;md5=edd50742d8def712e9472dba353668a9"
+
+SECTION = "utils"
+
+UPSTREAM_CHECK_URI = "https://github.com/cronie-crond/${BPN}/releases/"
+
+SRC_URI = "https://github.com/cronie-crond/cronie/releases/download/cronie-${PV}/cronie-${PV}.tar.gz \
+           file://crond.init \
+           file://crontab \
+           file://crond.service \
+           ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${PAM_SRC_URI}', '', d)}"
+
+PAM_SRC_URI = "file://crond_pam_config.patch"
+PAM_DEPS = "libpam libpam-runtime pam-plugin-access pam-plugin-loginuid"
+
+SRC_URI[md5sum] = "703314f58a49ea136e9966d3937d9bf4"
+SRC_URI[sha256sum] = "370bf34641691489330e708bd4cdbd779267296a030668a12f77b7e36872fd75"
+
+inherit autotools update-rc.d useradd systemd
+
+PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'pam', d)}"
+
+PACKAGECONFIG[audit] = "--with-audit,--without-audit,audit,"
+PACKAGECONFIG[pam] = "--with-pam,--without-pam,libpam,${PAM_DEPS}"
+
+INITSCRIPT_NAME = "crond"
+INITSCRIPT_PARAMS = "start 90 2 3 4 5 . stop 60 0 1 6 ."
+
+USERADD_PACKAGES = "${PN}"
+GROUPADD_PARAM_${PN} = "--system crontab"
+
+SYSTEMD_SERVICE_${PN} = "crond.service"
+
+do_install_append () {
+	install -d ${D}${sysconfdir}/sysconfig/
+	install -d ${D}${sysconfdir}/init.d/
+	install -m 0644 ${S}/crond.sysconfig ${D}${sysconfdir}/sysconfig/crond
+	install -m 0755 ${WORKDIR}/crond.init ${D}${sysconfdir}/init.d/crond
+
+	# install systemd unit files
+	install -d ${D}${systemd_unitdir}/system
+	install -m 0644 ${WORKDIR}/crond.service ${D}${systemd_unitdir}/system
+	sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
+	       -e 's,@SBINDIR@,${sbindir},g' \
+	       ${D}${systemd_unitdir}/system/crond.service
+
+	# below are necessary for a complete cron environment
+	install -d ${D}${localstatedir}/spool/cron
+	install -m 0755 ${WORKDIR}/crontab ${D}${sysconfdir}/
+	mkdir -p ${D}${sysconfdir}/cron.d
+	mkdir -p ${D}${sysconfdir}/cron.hourly
+	mkdir -p ${D}${sysconfdir}/cron.daily
+	mkdir -p ${D}${sysconfdir}/cron.weekly
+	mkdir -p ${D}${sysconfdir}/cron.monthly
+	touch ${D}${sysconfdir}/cron.deny
+
+	# below setting is necessary to allow normal user using crontab
+
+	# setgid for crontab binary
+	chown root:crontab ${D}${bindir}/crontab
+	chmod 2755 ${D}${bindir}/crontab
+
+	# allow 'crontab' group write to /var/spool/cron
+	chown root:crontab ${D}${localstatedir}/spool/cron
+	chmod 770 ${D}${localstatedir}/spool/cron
+
+	chmod 600 ${D}${sysconfdir}/crontab
+}
+
+FILES_${PN} += "${sysconfdir}/cron*"
+CONFFILES_${PN} += "${sysconfdir}/crontab"
diff --git a/poky/meta/recipes-extended/cups/cups.inc b/poky/meta/recipes-extended/cups/cups.inc
index ac4d225..c142a4d 100644
--- a/poky/meta/recipes-extended/cups/cups.inc
+++ b/poky/meta/recipes-extended/cups/cups.inc
@@ -2,13 +2,14 @@
 HOMEPAGE = "https://www.cups.org/"
 SECTION = "console/utils"
 LICENSE = "GPLv2 & LGPLv2"
-DEPENDS = "gnutls libpng jpeg dbus dbus-glib zlib libusb"
+DEPENDS = "gnutls libpng jpeg dbus dbus-glib zlib libusb1"
 
 SRC_URI = "https://github.com/apple/cups/releases/download/v${PV}/${BP}-source.tar.gz \
            file://use_echo_only_in_init.patch \
            file://0001-don-t-try-to-run-generated-binaries.patch \
            file://cups_serverbin.patch \
-	  "
+           file://cups-avoid-install-file-conflicts.patch \
+           "
 
 UPSTREAM_CHECK_URI = "https://github.com/apple/cups/releases"
 UPSTREAM_CHECK_REGEX = "cups-(?P<pver>\d+\.\d+(\.\d+)?)-source.tar"
diff --git a/poky/meta/recipes-extended/cups/cups/cups-avoid-install-file-conflicts.patch b/poky/meta/recipes-extended/cups/cups/cups-avoid-install-file-conflicts.patch
new file mode 100644
index 0000000..68885fa
--- /dev/null
+++ b/poky/meta/recipes-extended/cups/cups/cups-avoid-install-file-conflicts.patch
@@ -0,0 +1,21 @@
+@CUPS_SERVERBIN@ is ${libdir} related that causes multilib install file
+conflict. Remove @CUPS_SERVERBIN@ from the comment line of cups-files.conf to
+avoid the conflict.
+
+Upstream-Status: Inappropriate [OE specific]
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+
+diff --git a/conf/cups-files.conf.in b/conf/cups-files.conf.in
+index 4a78ba6..03c6582 100644
+--- a/conf/cups-files.conf.in
++++ b/conf/cups-files.conf.in
+@@ -73,7 +73,7 @@ PageLog @CUPS_LOGDIR@/page_log
+ #RequestRoot @CUPS_REQUESTS@
+ 
+ # Location of helper programs...
+-#ServerBin @CUPS_SERVERBIN@
++#ServerBin
+ 
+ # SSL/TLS keychain for the scheduler...
+ #ServerKeychain @CUPS_SERVERKEYCHAIN@
diff --git a/poky/meta/recipes-extended/cups/cups_2.2.6.bb b/poky/meta/recipes-extended/cups/cups_2.2.6.bb
deleted file mode 100644
index 3aa934b..0000000
--- a/poky/meta/recipes-extended/cups/cups_2.2.6.bb
+++ /dev/null
@@ -1,6 +0,0 @@
-require cups.inc
-
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=f212b4338db0da8cb892e94bf2949460"
-
-SRC_URI[md5sum] = "e91c26d8d97b5a1630a962f530f02192"
-SRC_URI[sha256sum] = "40385778c2b3bdf55030d1c999734e22774c79e3425d91339ce677825620169b"
diff --git a/poky/meta/recipes-extended/cups/cups_2.2.8.bb b/poky/meta/recipes-extended/cups/cups_2.2.8.bb
new file mode 100644
index 0000000..de1bd84
--- /dev/null
+++ b/poky/meta/recipes-extended/cups/cups_2.2.8.bb
@@ -0,0 +1,6 @@
+require cups.inc
+
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=f212b4338db0da8cb892e94bf2949460"
+
+SRC_URI[md5sum] = "33150d08993a04c8e22176e93805a051"
+SRC_URI[sha256sum] = "3968fc1d26fc48727508db1c1380e36c6694ab90177fd6920aec5f6cc73af9e4"
diff --git a/poky/meta/recipes-extended/diffutils/diffutils_3.6.bb b/poky/meta/recipes-extended/diffutils/diffutils_3.6.bb
index deadd62..8ba897d 100644
--- a/poky/meta/recipes-extended/diffutils/diffutils_3.6.bb
+++ b/poky/meta/recipes-extended/diffutils/diffutils_3.6.bb
@@ -19,6 +19,8 @@
 
 inherit ptest
 
+RDEPENDS_${PN}-ptest += "make"
+
 do_install_ptest() {
 	t=${D}${PTEST_PATH}
 	install -D ${S}/build-aux/test-driver $t/build-aux/test-driver
diff --git a/poky/meta/recipes-extended/ethtool/ethtool/avoid_parallel_tests.patch b/poky/meta/recipes-extended/ethtool/ethtool/avoid_parallel_tests.patch
index de38104..d81320a 100644
--- a/poky/meta/recipes-extended/ethtool/ethtool/avoid_parallel_tests.patch
+++ b/poky/meta/recipes-extended/ethtool/ethtool/avoid_parallel_tests.patch
@@ -1,3 +1,8 @@
+From 1484545a150de79483b6e2a74be02ebd030f1920 Mon Sep 17 00:00:00 2001
+From: Tudor Florea <tudor.florea@enea.com>
+Date: Wed, 28 May 2014 18:59:54 +0200
+Subject: [PATCH] ethtool: use serial-tests config needed by ptest.
+
 ptest needs buildtest-TESTS and runtest-TESTS targets.
 serial-tests is required to generate those targets.
 
@@ -5,12 +10,16 @@
 Upstream-Status: Inappropriate
 (default automake behavior incompatible with ptest)
 
-Index: ethtool-4.13/configure.ac
-===================================================================
---- ethtool-4.13.orig/configure.ac
-+++ ethtool-4.13/configure.ac
-@@ -2,7 +2,7 @@ dnl Process this file with autoconf to p
- AC_INIT(ethtool, 4.13, netdev@vger.kernel.org)
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index e891d91..600f8a8 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -2,7 +2,7 @@ dnl Process this file with autoconf to produce a configure script.
+ AC_INIT(ethtool, 4.17, netdev@vger.kernel.org)
  AC_PREREQ(2.52)
  AC_CONFIG_SRCDIR([ethtool.c])
 -AM_INIT_AUTOMAKE([gnu])
diff --git a/poky/meta/recipes-extended/ethtool/ethtool_4.13.bb b/poky/meta/recipes-extended/ethtool/ethtool_4.13.bb
deleted file mode 100644
index c862a57..0000000
--- a/poky/meta/recipes-extended/ethtool/ethtool_4.13.bb
+++ /dev/null
@@ -1,30 +0,0 @@
-SUMMARY = "Display or change ethernet card settings"
-DESCRIPTION = "A small utility for examining and tuning the settings of your ethernet-based network interfaces."
-HOMEPAGE = "http://www.kernel.org/pub/software/network/ethtool/"
-SECTION = "console/network"
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-                    file://ethtool.c;beginline=4;endline=17;md5=c19b30548c582577fc6b443626fc1216"
-
-SRC_URI = "${KERNELORG_MIRROR}/software/network/ethtool/ethtool-${PV}.tar.gz \
-           file://run-ptest \
-           file://avoid_parallel_tests.patch \
-           "
-
-SRC_URI[md5sum] = "2ba44eb0ca96752392e9bf8dc83ba302"
-SRC_URI[sha256sum] = "d311c4b557c44c5248ac5436b9e19c391a60d8e4830b6a7f41be16d89c0556de"
-
-inherit autotools ptest
-RDEPENDS_${PN}-ptest += "make"
-
-do_compile_ptest() {
-   oe_runmake buildtest-TESTS
-}
-
-do_install_ptest () {
-   cp ${B}/Makefile                 ${D}${PTEST_PATH}
-   install ${B}/test-cmdline        ${D}${PTEST_PATH}
-   install ${B}/test-features       ${D}${PTEST_PATH}
-   install ${B}/ethtool             ${D}${PTEST_PATH}/ethtool
-   sed -i 's/^Makefile/_Makefile/'  ${D}${PTEST_PATH}/Makefile
-}
diff --git a/poky/meta/recipes-extended/ethtool/ethtool_4.17.bb b/poky/meta/recipes-extended/ethtool/ethtool_4.17.bb
new file mode 100644
index 0000000..844a958
--- /dev/null
+++ b/poky/meta/recipes-extended/ethtool/ethtool_4.17.bb
@@ -0,0 +1,30 @@
+SUMMARY = "Display or change ethernet card settings"
+DESCRIPTION = "A small utility for examining and tuning the settings of your ethernet-based network interfaces."
+HOMEPAGE = "http://www.kernel.org/pub/software/network/ethtool/"
+SECTION = "console/network"
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                    file://ethtool.c;beginline=4;endline=17;md5=c19b30548c582577fc6b443626fc1216"
+
+SRC_URI = "${KERNELORG_MIRROR}/software/network/ethtool/ethtool-${PV}.tar.gz \
+           file://run-ptest \
+           file://avoid_parallel_tests.patch \
+           "
+
+SRC_URI[md5sum] = "4dba0345a4ab9f51b4a4a9739284238d"
+SRC_URI[sha256sum] = "4130142a15f7409d18de3667998f3c99fba52fd7c8d94be7ecdabf8dcab3d6c1"
+
+inherit autotools ptest
+RDEPENDS_${PN}-ptest += "make"
+
+do_compile_ptest() {
+   oe_runmake buildtest-TESTS
+}
+
+do_install_ptest () {
+   cp ${B}/Makefile                 ${D}${PTEST_PATH}
+   install ${B}/test-cmdline        ${D}${PTEST_PATH}
+   install ${B}/test-features       ${D}${PTEST_PATH}
+   install ${B}/ethtool             ${D}${PTEST_PATH}/ethtool
+   sed -i 's/^Makefile/_Makefile/'  ${D}${PTEST_PATH}/Makefile
+}
diff --git a/poky/meta/recipes-extended/findutils/findutils/0001-Unset-need_charset_alias-when-building-for-musl.patch b/poky/meta/recipes-extended/findutils/findutils/0001-Unset-need_charset_alias-when-building-for-musl.patch
index 8729e1b..6064d18 100644
--- a/poky/meta/recipes-extended/findutils/findutils/0001-Unset-need_charset_alias-when-building-for-musl.patch
+++ b/poky/meta/recipes-extended/findutils/findutils/0001-Unset-need_charset_alias-when-building-for-musl.patch
@@ -1,4 +1,4 @@
-From b9565dc2fe0c4f7daaec91b7e83bc7313dee2f4a Mon Sep 17 00:00:00 2001
+From 86db2a5f3b7ef8113e5384b4e02d2b299c87a047 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 13 Apr 2015 17:02:13 -0700
 Subject: [PATCH] Unset need_charset_alias when building for musl
@@ -11,15 +11,16 @@
 Upstream-Status: Pending
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
 ---
- lib/gnulib.mk | 2 +-
+ gl/lib/Makefile.am | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-Index: findutils-4.5.14/gl/lib/Makefile.am
-===================================================================
---- findutils-4.5.14.orig/gl/lib/Makefile.am
-+++ findutils-4.5.14/gl/lib/Makefile.am
-@@ -1220,7 +1220,7 @@ install-exec-localcharset: all-local
+diff --git a/gl/lib/Makefile.am b/gl/lib/Makefile.am
+index a9e2fe4..1c6ea9c 100644
+--- a/gl/lib/Makefile.am
++++ b/gl/lib/Makefile.am
+@@ -1234,7 +1234,7 @@ install-exec-localcharset: all-local
  	  case '$(host_os)' in \
  	    darwin[56]*) \
  	      need_charset_alias=true ;; \
diff --git a/poky/meta/recipes-extended/findutils/findutils/0001-find-make-delete-honour-the-ignore_readdir_race-opti.patch b/poky/meta/recipes-extended/findutils/findutils/0001-find-make-delete-honour-the-ignore_readdir_race-opti.patch
new file mode 100644
index 0000000..a570473
--- /dev/null
+++ b/poky/meta/recipes-extended/findutils/findutils/0001-find-make-delete-honour-the-ignore_readdir_race-opti.patch
@@ -0,0 +1,144 @@
+From a3f4821c4a3f723d21c9298d54bee8a656bfd7fb Mon Sep 17 00:00:00 2001
+From: Bernhard Voelker <mail@bernhard-voelker.de>
+Date: Tue, 30 Jan 2018 23:30:09 +0100
+Subject: [PATCH] find: make -delete honour the -ignore_readdir_race option
+
+* find/pred.c (pred_delete): Return true when the -ignore_readdir_race
+option is active and unlinkat() came back with ENOENT.
+* doc/find.texi (Option -ignore_readdir_race): Document the change.
+(Action -delete): Likewise.
+* find/find.1: Likewise.
+* NEWS (Bug Fixes): Mention the fix.
+
+For now, it seems a bit hard to add a proper test for this,
+so the following shell snippet demonstrates the race:
+
+  $ seq 10 | xargs touch
+  $ env time -f 'find exit status: %x\nfind time: %e' \
+      find -ignore_readdir_race -type f \
+        -delete \
+        -exec sh -c 'sleep $(basename {})' \; \
+        -printf 'find deleted: %p\n' \
+        & \
+    sleep 20; \
+    seq 10 | xargs rm -fv; \
+    wait $!
+
+Reported by Alexander Golubev in
+https://savannah.gnu.org/bugs/?52981
+
+Upstream-Status: Backport
+Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
+
+---
+ NEWS          |  4 ++++
+ doc/find.texi | 15 ++++++++++++++-
+ find/find.1   | 22 ++++++++++++++++++++++
+ find/pred.c   |  6 ++++++
+ 4 files changed, 46 insertions(+), 1 deletion(-)
+
+diff --git a/NEWS b/NEWS
+index 660c241..b86ec1e 100644
+--- a/NEWS
++++ b/NEWS
+@@ -42,6 +42,10 @@ Updated the Danish translation.
+ 
+ ** Bug Fixes:
+ 
++#52981: find: the '-delete' action no longer complains about disappeared files
++        when the '-ignore_readdir_race' option is given, too.  That action will
++        also returns true in such a case now.
++
+ Applied patch #8688: Spelling fixes.
+ 
+ * Major changes in release 4.5.18, 2015-12-27
+diff --git a/doc/find.texi b/doc/find.texi
+index fdeb841..247c19a 100644
+--- a/doc/find.texi
++++ b/doc/find.texi
+@@ -1418,7 +1418,15 @@ gives a significant increase in search speed.
+ If a file disappears after its name has been read from a directory but
+ before @code{find} gets around to examining the file with @code{stat},
+ don't issue an error message.  If you don't specify this option, an
+-error message will be issued.  This option can be useful in system
++error message will be issued.
++
++Furthermore, @code{find} with the @samp{-ignore_readdir_race} option
++will ignore errors of the @samp{-delete} action in the case the file
++has disappeared since the parent directory was read: it will not output
++an error diagnostic, and the return code of the @samp{-delete} action
++will be true.
++
++This option can be useful in system
+ scripts (cron scripts, for example) that examine areas of the
+ filesystem that change frequently (mail queues, temporary directories,
+ and so forth), because this scenario is common for those sorts of
+@@ -2779,6 +2787,11 @@ explicitly.
+ 
+ If @samp{-delete} fails, @code{find}'s exit status will be nonzero
+ (when it eventually exits).
++
++Together with the @samp{-ignore_readdir_race} option, @code{find} will
++ignore errors of the @samp{-delete} action in the case the file has disappeared
++since the parent directory was read: it will not output an error diagnostic, and
++the return code of the @samp{-delete} action will be true.
+ @end deffn
+ 
+ @node Adding Tests
+diff --git a/find/find.1 b/find/find.1
+index 7b141b8..0eec41c 100644
+--- a/find/find.1
++++ b/find/find.1
+@@ -479,6 +479,17 @@ one part of the filesystem with this option on and part of it with this option
+ off (if you need to do that, you will need to issue two \fBfind\fR commands
+ instead, one with the option and one without it).
+ 
++Furthermore,
++.B find
++with the
++.B \-ignore_readdir_race
++option will ignore errors of the
++.B \-delete
++action in the case the file has disappeared since the parent directory was read:
++it will not output an error diagnostic, and the return code of the
++.B \-delete
++action will be true.
++
+ .IP "\-maxdepth \fIlevels\fR"
+ Descend at most \fIlevels\fR (a non-negative integer) levels of
+ directories below the starting-points.
+@@ -1030,6 +1041,17 @@ and
+ .B \-delete
+ together.
+ 
++Together with the
++.B \-ignore_readdir_race
++option,
++.B find
++will ignore errors of the
++.B \-delete
++action in the case the file has disappeared since the parent directory was
++read: it will not output an error diagnostic, and the return code of the
++.B \-delete
++action will be true.
++
+ .IP "\-exec \fIcommand\fR ;"
+ Execute \fIcommand\fR; true if 0 status is returned.  All following
+ arguments to
+diff --git a/find/pred.c b/find/pred.c
+index 32938fb..431f065 100644
+--- a/find/pred.c
++++ b/find/pred.c
+@@ -324,6 +324,12 @@ pred_delete (const char *pathname, struct stat *stat_buf, struct predicate *pred
+ 	}
+       else
+ 	{
++	  if (ENOENT == errno && options.ignore_readdir_race)
++	    {
++	      /* Ignore unlink() error for vanished files.  */
++	      errno = 0;
++	      return true;
++	    }
+ 	  if (EISDIR == errno)
+ 	    {
+ 	      if ((flags & AT_REMOVEDIR) == 0)
diff --git a/poky/meta/recipes-extended/findutils/findutils/findutils-4.6.0-gnulib-fflush.patch b/poky/meta/recipes-extended/findutils/findutils/findutils-4.6.0-gnulib-fflush.patch
new file mode 100644
index 0000000..d13e8ed
--- /dev/null
+++ b/poky/meta/recipes-extended/findutils/findutils/findutils-4.6.0-gnulib-fflush.patch
@@ -0,0 +1,140 @@
+From 80cdfba079627e15129a926a133825b961d41e36 Mon Sep 17 00:00:00 2001
+From: Paul Eggert <eggert@cs.ucla.edu>
+Date: Mon, 5 Mar 2018 10:56:29 -0800
+Subject: [PATCH] fflush: adjust to glibc 2.28 libio.h removal
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Problem reported by Daniel P. Berrangé in:
+https://lists.gnu.org/r/bug-gnulib/2018-03/msg00000.html
+* lib/fflush.c (clear_ungetc_buffer_preserving_position)
+(disable_seek_optimization, rpl_fflush):
+* lib/fpurge.c (fpurge):
+* lib/freadahead.c (freadahead):
+* lib/freading.c (freading):
+* lib/fseeko.c (fseeko):
+* lib/stdio-impl.h (_IO_IN_BACKUP) [_IO_EOF_SEEN]:
+Define if not already defined.
+
+Upstream-commit: 4af4a4a71827c0bc5e0ec67af23edef4f15cee8e
+Signed-off-by: Kamil Dudka <kdudka@redhat.com>
+Upstream-Status: Backport [4af4a4a71827c0bc5e0ec67af23edef4f15cee8e]
+---
+ gl/lib/fflush.c     | 6 +++---
+ gl/lib/fpurge.c     | 2 +-
+ gl/lib/freadahead.c | 2 +-
+ gl/lib/freading.c   | 2 +-
+ gl/lib/fseeko.c     | 4 ++--
+ gl/lib/stdio-impl.h | 6 ++++++
+ 6 files changed, 14 insertions(+), 8 deletions(-)
+
+Index: findutils-4.6.0/gl/lib/fflush.c
+===================================================================
+--- findutils-4.6.0.orig/gl/lib/fflush.c
++++ findutils-4.6.0/gl/lib/fflush.c
+@@ -33,7 +33,7 @@
+ #undef fflush
+ 
+ 
+-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
++#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+ 
+ /* Clear the stream's ungetc buffer, preserving the value of ftello (fp).  */
+ static void
+@@ -72,7 +72,7 @@ clear_ungetc_buffer (FILE *fp)
+ 
+ #endif
+ 
+-#if ! (defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */)
++#if ! (defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */)
+ 
+ # if (defined __sferror || defined __DragonFly__ || defined __ANDROID__) && defined __SNPT
+ /* FreeBSD, NetBSD, OpenBSD, DragonFly, Mac OS X, Cygwin, Android */
+@@ -148,7 +148,7 @@ rpl_fflush (FILE *stream)
+   if (stream == NULL || ! freading (stream))
+     return fflush (stream);
+ 
+-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
++#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+ 
+   clear_ungetc_buffer_preserving_position (stream);
+ 
+Index: findutils-4.6.0/gl/lib/fpurge.c
+===================================================================
+--- findutils-4.6.0.orig/gl/lib/fpurge.c
++++ findutils-4.6.0/gl/lib/fpurge.c
+@@ -62,7 +62,7 @@ fpurge (FILE *fp)
+   /* Most systems provide FILE as a struct and the necessary bitmask in
+      <stdio.h>, because they need it for implementing getc() and putc() as
+      fast macros.  */
+-# if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
++# if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+   fp->_IO_read_end = fp->_IO_read_ptr;
+   fp->_IO_write_ptr = fp->_IO_write_base;
+   /* Avoid memory leak when there is an active ungetc buffer.  */
+Index: findutils-4.6.0/gl/lib/freadahead.c
+===================================================================
+--- findutils-4.6.0.orig/gl/lib/freadahead.c
++++ findutils-4.6.0/gl/lib/freadahead.c
+@@ -25,7 +25,7 @@
+ size_t
+ freadahead (FILE *fp)
+ {
+-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
++#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+   if (fp->_IO_write_ptr > fp->_IO_write_base)
+     return 0;
+   return (fp->_IO_read_end - fp->_IO_read_ptr)
+Index: findutils-4.6.0/gl/lib/freading.c
+===================================================================
+--- findutils-4.6.0.orig/gl/lib/freading.c
++++ findutils-4.6.0/gl/lib/freading.c
+@@ -31,7 +31,7 @@ freading (FILE *fp)
+   /* Most systems provide FILE as a struct and the necessary bitmask in
+      <stdio.h>, because they need it for implementing getc() and putc() as
+      fast macros.  */
+-# if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
++# if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+   return ((fp->_flags & _IO_NO_WRITES) != 0
+           || ((fp->_flags & (_IO_NO_READS | _IO_CURRENTLY_PUTTING)) == 0
+               && fp->_IO_read_base != NULL));
+Index: findutils-4.6.0/gl/lib/fseeko.c
+===================================================================
+--- findutils-4.6.0.orig/gl/lib/fseeko.c
++++ findutils-4.6.0/gl/lib/fseeko.c
+@@ -47,7 +47,7 @@ fseeko (FILE *fp, off_t offset, int when
+ #endif
+ 
+   /* These tests are based on fpurge.c.  */
+-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
++#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+   if (fp->_IO_read_end == fp->_IO_read_ptr
+       && fp->_IO_write_ptr == fp->_IO_write_base
+       && fp->_IO_save_base == NULL)
+@@ -123,7 +123,7 @@ fseeko (FILE *fp, off_t offset, int when
+           return -1;
+         }
+ 
+-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
++#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+       fp->_flags &= ~_IO_EOF_SEEN;
+       fp->_offset = pos;
+ #elif defined __sferror || defined __DragonFly__ || defined __ANDROID__
+Index: findutils-4.6.0/gl/lib/stdio-impl.h
+===================================================================
+--- findutils-4.6.0.orig/gl/lib/stdio-impl.h
++++ findutils-4.6.0/gl/lib/stdio-impl.h
+@@ -18,6 +18,12 @@
+    the same implementation of stdio extension API, except that some fields
+    have different naming conventions, or their access requires some casts.  */
+ 
++/* Glibc 2.28 made _IO_IN_BACKUP private.  For now, work around this
++   problem by defining it ourselves.  FIXME: Do not rely on glibc
++   internals.  */
++#if !defined _IO_IN_BACKUP && defined _IO_EOF_SEEN
++# define _IO_IN_BACKUP 0x100
++#endif
+ 
+ /* BSD stdio derived implementations.  */
+ 
diff --git a/poky/meta/recipes-extended/findutils/findutils/findutils-4.6.0-gnulib-makedev.patch b/poky/meta/recipes-extended/findutils/findutils/findutils-4.6.0-gnulib-makedev.patch
new file mode 100644
index 0000000..0fb3953
--- /dev/null
+++ b/poky/meta/recipes-extended/findutils/findutils/findutils-4.6.0-gnulib-makedev.patch
@@ -0,0 +1,78 @@
+From 80628047a6cc83f82e0c410a82b8f7facd9d50f2 Mon Sep 17 00:00:00 2001
+From: Eric Blake <eblake@redhat.com>
+Date: Wed, 14 Sep 2016 19:21:42 -0500
+Subject: [PATCH] mountlist: include sysmacros.h for glibc
+
+On Fedora rawhide (glibc 2.25), './gnulib-tool --test mountlist'
+reports:
+../../gllib/mountlist.c: In function 'read_file_system_list':
+../../gllib/mountlist.c:534:13: warning: '__makedev_from_sys_types' is deprecated:
+  In the GNU C Library, `makedev' is defined by <sys/sysmacros.h>.
+  For historical compatibility, it is currently defined by
+  <sys/types.h> as well, but we plan to remove this soon.
+  To use `makedev', include <sys/sysmacros.h> directly.
+  If you did not intend to use a system-defined macro `makedev',
+  you should #undef it after including <sys/types.h>.
+  [-Wdeprecated-declarations]
+             me->me_dev = makedev (devmaj, devmin);
+             ^~
+In file included from /usr/include/features.h:397:0,
+                 from /usr/include/sys/types.h:25,
+                 from ./sys/types.h:28,
+                 from ../../gllib/mountlist.h:23,
+                 from ../../gllib/mountlist.c:20:
+/usr/include/sys/sysmacros.h:89:1: note: declared here
+ __SYSMACROS_DEFINE_MAKEDEV (__SYSMACROS_FST_IMPL_TEMPL)
+ ^
+
+Fix it by including the right headers.  We also need a fix to
+autoconf's AC_HEADER_MAJOR, but that's a separate patch.
+
+* m4/mountlist.m4 (gl_PREREQ_MOUTLIST_EXTRA): Include
+AC_HEADER_MAJOR.
+* lib/mountlist.c (includes): Use correct headers.
+
+Signed-off-by: Eric Blake <eblake@redhat.com>
+
+Upstream-commit: 4da63c5881f60f71999a943612da9112232b9161
+Signed-off-by: Kamil Dudka <kdudka@redhat.com>
+Upstream-Status: Backport [4da63c5881f60f71999a943612da9112232b9161]
+---
+ gl/lib/mountlist.c | 6 ++++++
+ gl/m4/mountlist.m4 | 3 ++-
+ 2 files changed, 8 insertions(+), 1 deletion(-)
+
+Index: findutils-4.6.0/gl/lib/mountlist.c
+===================================================================
+--- findutils-4.6.0.orig/gl/lib/mountlist.c
++++ findutils-4.6.0/gl/lib/mountlist.c
+@@ -37,6 +37,12 @@
+ # include <sys/param.h>
+ #endif
+ 
++#if MAJOR_IN_MKDEV
++# include <sys/mkdev.h>
++#elif MAJOR_IN_SYSMACROS
++# include <sys/sysmacros.h>
++#endif
++
+ #if defined MOUNTED_GETFSSTAT   /* OSF_1 and Darwin1.3.x */
+ # if HAVE_SYS_UCRED_H
+ #  include <grp.h> /* needed on OSF V4.0 for definition of NGROUPS,
+Index: findutils-4.6.0/gl/m4/mountlist.m4
+===================================================================
+--- findutils-4.6.0.orig/gl/m4/mountlist.m4
++++ findutils-4.6.0/gl/m4/mountlist.m4
+@@ -1,4 +1,4 @@
+-# serial 11
++# serial 12
+ dnl Copyright (C) 2002-2006, 2009-2015 Free Software Foundation, Inc.
+ dnl This file is free software; the Free Software Foundation
+ dnl gives unlimited permission to copy and/or distribute it,
+@@ -15,5 +15,6 @@ AC_DEFUN([gl_PREREQ_MOUNTLIST_EXTRA],
+ [
+   dnl Note gl_LIST_MOUNTED_FILE_SYSTEMS checks for mntent.h, not sys/mntent.h.
+   AC_CHECK_HEADERS([sys/mntent.h])
++  AC_HEADER_MAJOR()dnl for use of makedev ()
+   gl_FSTYPENAME
+ ])
diff --git a/poky/meta/recipes-extended/findutils/findutils_4.6.0.bb b/poky/meta/recipes-extended/findutils/findutils_4.6.0.bb
index 072d3b3..5e4ca94 100644
--- a/poky/meta/recipes-extended/findutils/findutils_4.6.0.bb
+++ b/poky/meta/recipes-extended/findutils/findutils_4.6.0.bb
@@ -6,7 +6,11 @@
 
 DEPENDS = "bison-native"
 
-SRC_URI += "file://0001-Unset-need_charset_alias-when-building-for-musl.patch"
+SRC_URI += "file://0001-Unset-need_charset_alias-when-building-for-musl.patch \
+            file://0001-find-make-delete-honour-the-ignore_readdir_race-opti.patch \
+            file://findutils-4.6.0-gnulib-fflush.patch \
+            file://findutils-4.6.0-gnulib-makedev.patch \
+"
 
 SRC_URI[md5sum] = "9936aa8009438ce185bea2694a997fc1"
 SRC_URI[sha256sum] = "ded4c9f73731cd48fec3b6bdaccce896473b6d8e337e9612e16cf1431bb1169d"
diff --git a/poky/meta/recipes-extended/ghostscript/files/0001-Bug-699795-add-operand-checking-to-.setnativefontmap.patch b/poky/meta/recipes-extended/ghostscript/files/0001-Bug-699795-add-operand-checking-to-.setnativefontmap.patch
new file mode 100644
index 0000000..f175da0
--- /dev/null
+++ b/poky/meta/recipes-extended/ghostscript/files/0001-Bug-699795-add-operand-checking-to-.setnativefontmap.patch
@@ -0,0 +1,59 @@
+From 274b2cc08b0d10a4cac3fe8b50022889f22580cb Mon Sep 17 00:00:00 2001
+From: Chris Liddell <chris.liddell@artifex.com>
+Date: Thu, 20 Sep 2018 16:35:28 +0100
+Subject: [PATCH 1/5] Bug 699795: add operand checking to
+ .setnativefontmapbuilt
+
+.setnativefontmapbuilt .forceputs a value into systemdict - it is intended
+to be a boolean, but in this case was being called with a compound object
+(a dictionary). Such an object, in local VM, being forced into systemdict
+would then confuse the garbager, since it could be restored away with the
+reference remaining.
+
+This adds operand checking, so .setnativefontmapbuilt will simply ignore
+anything other than a boolean value, and also removes the definition of
+.setnativefontmapbuilt after use, since it is only used in two, closely
+related places.
+
+CVE: CVE-2018-17961
+Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ Resource/Init/gs_fonts.ps | 11 ++++++++---
+ 1 file changed, 8 insertions(+), 3 deletions(-)
+
+diff --git a/Resource/Init/gs_fonts.ps b/Resource/Init/gs_fonts.ps
+index 38f0f6c..45b6613 100644
+--- a/Resource/Init/gs_fonts.ps
++++ b/Resource/Init/gs_fonts.ps
+@@ -372,9 +372,13 @@ FONTPATH length 0 eq { (%END FONTPATH) .skipeof } if
+ % of strings: what the system thinks is the ps name,
+ % and the access path.
+ /.setnativefontmapbuilt { % set whether we've been run
+-  systemdict exch /.nativefontmapbuilt exch .forceput
++  dup type /booleantype eq {
++      systemdict exch /.nativefontmapbuilt exch .forceput
++  }
++  {pop}
++  ifelse
+ } .bind executeonly def
+-systemdict /NONATIVEFONTMAP known .setnativefontmapbuilt
++systemdict /NONATIVEFONTMAP known //.setnativefontmapbuilt exec
+ /.buildnativefontmap {   % - .buildnativefontmap <bool>
+   systemdict /.nativefontmapbuilt .knownget not
+   { //false} if
+@@ -415,9 +419,10 @@ systemdict /NONATIVEFONTMAP known .setnativefontmapbuilt
+       } forall
+     } if
+     % record that we've been run
+-    //true .setnativefontmapbuilt
++    //true //.setnativefontmapbuilt exec
+   } ifelse
+ } bind def
++currentdict /.setnativefontmapbuilt .forceundef
+ 
+ % Create the dictionary that registers the .buildfont procedure
+ % (called by definefont) for each FontType.
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-extended/ghostscript/files/0002-Bug-699816-Improve-hiding-of-security-critical-custo.patch b/poky/meta/recipes-extended/ghostscript/files/0002-Bug-699816-Improve-hiding-of-security-critical-custo.patch
new file mode 100644
index 0000000..000f9c9
--- /dev/null
+++ b/poky/meta/recipes-extended/ghostscript/files/0002-Bug-699816-Improve-hiding-of-security-critical-custo.patch
@@ -0,0 +1,434 @@
+From 0661bf23a5be32973682e17afed4a2f23a8214ba Mon Sep 17 00:00:00 2001
+From: Chris Liddell <chris.liddell@artifex.com>
+Date: Sat, 29 Sep 2018 15:34:55 +0100
+Subject: [PATCH 2/5] Bug 699816: Improve hiding of security critical custom
+ operators
+
+Make procedures that use .forceput/.forcedef/.forceundef into operators.
+
+The result of this is that errors get reported against the "top" operator,
+rather than the "called" operator within the procedure.
+
+For example:
+/myproc
+{
+  myop
+} bind def
+
+If 'myop' throws an error, the error handler will be passed the 'myop'
+operator. Promoting 'myproc' to a operator means the error handler will be
+passed 'myproc'.
+
+CVE: CVE-2018-17961
+Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ Resource/Init/gs_diskn.ps |  2 +-
+ Resource/Init/gs_dps.ps   |  2 +-
+ Resource/Init/gs_fntem.ps |  2 +-
+ Resource/Init/gs_fonts.ps | 10 +++++-----
+ Resource/Init/gs_lev2.ps  | 13 +++++++++----
+ Resource/Init/gs_pdfwr.ps |  2 +-
+ Resource/Init/gs_setpd.ps | 25 +++++++++++++++++--------
+ Resource/Init/gs_typ32.ps | 14 +++++++++-----
+ Resource/Init/gs_type1.ps |  2 +-
+ Resource/Init/pdf_base.ps |  2 +-
+ Resource/Init/pdf_draw.ps | 10 +++++-----
+ Resource/Init/pdf_font.ps |  8 ++++----
+ Resource/Init/pdf_main.ps |  4 ++--
+ Resource/Init/pdf_ops.ps  |  8 ++++----
+ 14 files changed, 61 insertions(+), 43 deletions(-)
+
+diff --git a/Resource/Init/gs_diskn.ps b/Resource/Init/gs_diskn.ps
+index 5540715..26ec0b5 100644
+--- a/Resource/Init/gs_diskn.ps
++++ b/Resource/Init/gs_diskn.ps
+@@ -53,7 +53,7 @@ systemdict begin
+     exch .setglobal
+   }
+   if
+-} .bind executeonly def % must be bound and hidden for .forceput
++} .bind executeonly odef % must be bound and hidden for .forceput
+ 
+ % Modify .putdevparams to force regeneration of .searchabledevs list
+ /.putdevparams {
+diff --git a/Resource/Init/gs_dps.ps b/Resource/Init/gs_dps.ps
+index cad7056..daf7b0f 100644
+--- a/Resource/Init/gs_dps.ps
++++ b/Resource/Init/gs_dps.ps
+@@ -70,7 +70,7 @@
+                 % Save a copy of the initial gstate.
+   //systemdict /savedinitialgstate gstate readonly .forceput
+   .setglobal
+-} .bind executeonly def % must be bound and hidden for .forceput
++} .bind executeonly odef % must be bound and hidden for .forceput
+ 
+ % Initialize local dictionaries and gstate when creating a new context.
+ % Note that until this completes, we are in the anomalous situation of
+diff --git a/Resource/Init/gs_fntem.ps b/Resource/Init/gs_fntem.ps
+index 3ceee18..c1f7651 100644
+--- a/Resource/Init/gs_fntem.ps
++++ b/Resource/Init/gs_fntem.ps
+@@ -408,7 +408,7 @@ currentdict end def
+     exit
+   } loop
+   exch setglobal
+-} .bind executeonly def % must be bound and hidden for .forceput
++} .bind executeonly odef % must be bound and hidden for .forceput
+ 
+ currentdict end /ProcSet defineresource pop
+ 
+diff --git a/Resource/Init/gs_fonts.ps b/Resource/Init/gs_fonts.ps
+index 45b6613..89c3ab7 100644
+--- a/Resource/Init/gs_fonts.ps
++++ b/Resource/Init/gs_fonts.ps
+@@ -377,8 +377,8 @@ FONTPATH length 0 eq { (%END FONTPATH) .skipeof } if
+   }
+   {pop}
+   ifelse
+-} .bind executeonly def
+-systemdict /NONATIVEFONTMAP known //.setnativefontmapbuilt exec
++} .bind executeonly odef
++systemdict /NONATIVEFONTMAP known .setnativefontmapbuilt
+ /.buildnativefontmap {   % - .buildnativefontmap <bool>
+   systemdict /.nativefontmapbuilt .knownget not
+   { //false} if
+@@ -419,7 +419,7 @@ systemdict /NONATIVEFONTMAP known //.setnativefontmapbuilt exec
+       } forall
+     } if
+     % record that we've been run
+-    //true //.setnativefontmapbuilt exec
++    //true .setnativefontmapbuilt
+   } ifelse
+ } bind def
+ currentdict /.setnativefontmapbuilt .forceundef
+@@ -1103,7 +1103,7 @@ $error /SubstituteFont { } put
+ 
+                 % Check to make sure the font was actually loaded.
+         dup 3 index .fontknownget
+-         { dup /PathLoad 4 index //.putgstringcopy exec
++         { dup /PathLoad 4 index .putgstringcopy
+            4 1 roll pop pop pop //true exit
+          } if
+ 
+@@ -1115,7 +1115,7 @@ $error /SubstituteFont { } put
+          {            % Stack: origfontname fontdirectory path filefontname
+            2 index 1 index .fontknownget
+             {   % Yes.  Stack: origfontname fontdirectory path filefontname fontdict
+-              dup 4 -1 roll /PathLoad exch //.putgstringcopy exec
++              dup 4 -1 roll /PathLoad exch .putgstringcopy
+                       % Stack: origfontname fontdirectory filefontname fontdict
+               3 -1 roll pop
+                       % Stack: origfontname filefontname fontdict
+diff --git a/Resource/Init/gs_lev2.ps b/Resource/Init/gs_lev2.ps
+index eee0b9f..a8ed892 100644
+--- a/Resource/Init/gs_lev2.ps
++++ b/Resource/Init/gs_lev2.ps
+@@ -163,10 +163,11 @@ end
+         % Set them again to the new values.  From here on, we are safe,
+         % since a context switch will consult userparams.
+   .setuserparams
+-} .bind executeonly def % must be bound and hidden for .forceput
++} .bind executeonly odef % must be bound and hidden for .forceput
+ 
+ /setuserparams {		% <dict> setuserparams -
+-    .setuserparams2
++    {.setuserparams2} stopped
++    {/setuserparams load $error /errorname get signalerror} if
+ } .bind odef
+ % Initialize user parameters managed here.
+ /JobName () .definepsuserparam
+@@ -415,7 +416,9 @@ psuserparams /ProcessDSCComment {.checkprocesscomment} put
+ 
+ % VMReclaim and VMThreshold are user parameters.
+ /setvmthreshold {		% <int> setvmthreshold -
+-  mark /VMThreshold 2 .argindex .dicttomark .setuserparams2 pop
++  mark /VMThreshold 2 .argindex .dicttomark {.setuserparams2} stopped
++  {pop /setvmthreshold load $error /errorname get signalerror}
++  {pop} ifelse
+ } odef
+ /vmreclaim {			% <int> vmreclaim -
+   dup 0 gt {
+@@ -427,7 +430,9 @@ psuserparams /ProcessDSCComment {.checkprocesscomment} put
+     ifelse
+   } {
+     % VMReclaim userparam controls enable/disable GC
+-    mark /VMReclaim 2 index .dicttomark .setuserparams2 pop
++    mark /VMReclaim 2 index .dicttomark {.setuserparams2} stopped
++    {pop /vmreclaim load $error /errorname get signalerror}
++    {pop} ifelse
+   } ifelse
+ } odef
+ -1 setvmthreshold
+diff --git a/Resource/Init/gs_pdfwr.ps b/Resource/Init/gs_pdfwr.ps
+index fb1c419..58e75d3 100644
+--- a/Resource/Init/gs_pdfwr.ps
++++ b/Resource/Init/gs_pdfwr.ps
+@@ -660,7 +660,7 @@ currentdict /.pdfmarkparams .undef
+   {
+     pop
+   } ifelse
+-} .bind executeonly def % must be bound and hidden for .forceput
++} .bind executeonly odef % must be bound and hidden for .forceput
+ 
+ % Use the DSC processing hook to pass DSC comments to the driver.
+ % We use a pseudo-parameter named DSC whose value is an array:
+diff --git a/Resource/Init/gs_setpd.ps b/Resource/Init/gs_setpd.ps
+index 8fa7c51..afb4ffa 100644
+--- a/Resource/Init/gs_setpd.ps
++++ b/Resource/Init/gs_setpd.ps
+@@ -608,6 +608,20 @@ NOMEDIAATTRS {
+ % in the <failed> dictionary with the policy value,
+ % and we replace the key in the <merged> dictionary with its prior value
+ % (or remove it if it had no prior value).
++
++% Making this an operator means we can properly hide
++% the contents - specifically .forceput
++/1Policy
++{
++  % Roll back the failed request to its previous status.
++  SETPDDEBUG { (Rolling back.) = pstack flush } if
++  3 index 2 index 3 -1 roll .forceput
++  4 index 1 index .knownget
++   { 4 index 3 1 roll .forceput }
++   { 3 index exch .undef }
++  ifelse
++} bind executeonly odef
++
+ /.policyprocs mark
+ % These procedures are called with the following on the stack:
+ %   <orig> <merged> <failed> <Policies> <key> <policy>
+@@ -631,14 +645,7 @@ NOMEDIAATTRS {
+         /setpagedevice .systemvar /configurationerror signalerror
+       } ifelse
+   } bind
+-  1 {		% Roll back the failed request to its previous status.
+-SETPDDEBUG { (Rolling back.) = pstack flush } if
+-        3 index 2 index 3 -1 roll .forceput
+-        4 index 1 index .knownget
+-         { 4 index 3 1 roll .forceput }
+-         { 3 index exch .undef }
+-        ifelse
+-  } .bind executeonly % must be bound and hidden for .forceput
++  1 /1Policy load
+   7 {		% For PageSize only, just impose the request.
+         1 index /PageSize eq
+          { pop pop 1 index /PageSize 7 put }
+@@ -646,6 +653,8 @@ SETPDDEBUG { (Rolling back.) = pstack flush } if
+         ifelse
+   } bind
+ .dicttomark readonly def
++currentdict /1Policy undef
++
+ /.applypolicies		% <orig> <merged> <failed> .applypolicies
+                         %   <orig> <merged'> <failed'>
+  { 1 index /Policies get 1 index
+diff --git a/Resource/Init/gs_typ32.ps b/Resource/Init/gs_typ32.ps
+index b6600b0..9150f71 100644
+--- a/Resource/Init/gs_typ32.ps
++++ b/Resource/Init/gs_typ32.ps
+@@ -79,15 +79,19 @@ systemdict /.removeglyphs .undef
+ .dicttomark /ProcSet defineresource pop
+ 
+ /.cidfonttypes where { pop } { /.cidfonttypes 6 dict def } ifelse
+-.cidfonttypes begin
+-
+-4	% CIDFontType 4 = FontType 32
+-{ dup /FontType 32 .forceput
++/CIDFontType4
++{
++  dup /FontType 32 .forceput
+   dup /CharStrings 20 dict .forceput
+   1 index exch .buildfont32 exch pop
+-} .bind executeonly def % must be bound and hidden for .forceput
++} .bind executeonly odef
++.cidfonttypes begin
++
++
++4 /CIDFontType4 load def % CIDFontType 4 = FontType 32
+ 
+ end		% .cidfonttypes
++currentdict /CIDFontType4 .forceundef
+ 
+ % Define the BuildGlyph procedure.
+ % Since Type 32 fonts are indexed by CID, there is no BuildChar procedure.
+diff --git a/Resource/Init/gs_type1.ps b/Resource/Init/gs_type1.ps
+index efdae48..2935d9c 100644
+--- a/Resource/Init/gs_type1.ps
++++ b/Resource/Init/gs_type1.ps
+@@ -283,7 +283,7 @@ currentdict /closesourcedict .undef
+   } if
+   2 copy /WeightVector exch .forceput
+   .setweightvector
+-} .bind executeonly def
++} .bind executeonly odef
+ end
+ 
+ % Register the font types for definefont.
+diff --git a/Resource/Init/pdf_base.ps b/Resource/Init/pdf_base.ps
+index a82a2a3..7ccd4cd 100644
+--- a/Resource/Init/pdf_base.ps
++++ b/Resource/Init/pdf_base.ps
+@@ -218,7 +218,7 @@ currentdict /num-chars-dict .undef
+       } ifelse
+     } ifelse
+   } ifelse
+-} bind executeonly def
++} bind executeonly odef
+ /PDFScanRules_true << /PDFScanRules //true >> def
+ /PDFScanRules_null << /PDFScanRules //null >> def
+ /.pdfrun {			% <file> <opdict> .pdfrun -
+diff --git a/Resource/Init/pdf_draw.ps b/Resource/Init/pdf_draw.ps
+index d1b6ac9..c239daf 100644
+--- a/Resource/Init/pdf_draw.ps
++++ b/Resource/Init/pdf_draw.ps
+@@ -1158,7 +1158,7 @@ currentdict end readonly def
+   Q
+   PDFDEBUG { pdfdict /PDFSTEPcount .knownget { 1 le } { //true } ifelse { (%End PaintProc) print dup === flush } if } if
+   PDFfile exch setfileposition
+-} bind executeonly def
++} bind executeonly odef
+ 
+ /.pdfpaintproc {
+     %% Get the /m from pdfopdict (must be present)
+@@ -1189,7 +1189,7 @@ currentdict end readonly def
+     {
+       switch_to_text_marking_ops
+     } if
+-}bind executeonly def
++}bind executeonly odef
+ 
+ /resolvepattern {	% <patternstreamdict> resolvepattern <patterndict>
+                 % Don't do the resolvestream now: just capture the data
+@@ -2353,7 +2353,7 @@ currentdict /last-ditch-bpc-csp undef
+   }{
+     pdfdict /AppearanceNumber 0 .forceput
+   } ifelse
+-}bind executeonly def
++}bind executeonly odef
+ 
+ /MakeAppearanceName {
+   pdfdict /AppearanceNumber get
+@@ -2382,7 +2382,7 @@ currentdict /last-ditch-bpc-csp undef
+   DoForm
+   pdfdict /.PreservePDFForm 3 -1 roll .forceput
+   grestore
+-} bind executeonly def
++} bind executeonly odef
+ 
+ /DoForm {
+   %% save the current value, if its true we will set it to false later, in order
+@@ -2541,7 +2541,7 @@ currentdict /last-ditch-bpc-csp undef
+     end
+   } if
+   pdfdict /.PreservePDFForm 3 -1 roll .forceput
+-} bind executeonly def
++} bind executeonly odef
+ 
+ /_dops_save 1 array def
+ 
+diff --git a/Resource/Init/pdf_font.ps b/Resource/Init/pdf_font.ps
+index feaf0d0..535b14a 100644
+--- a/Resource/Init/pdf_font.ps
++++ b/Resource/Init/pdf_font.ps
+@@ -718,7 +718,7 @@ currentdict end readonly def
+   {pop pop pop}
+   ifelse
+ 
+-} bind executeonly def
++} bind executeonly odef
+ 
+ currentdict /.DoToUnicode? .forceundef
+ 
+@@ -1241,7 +1241,7 @@ currentdict /eexec_pdf_param_dict .undef
+     } bdef
+     dup currentdict Encoding .processToUnicode
+     currentdict end .completefont exch pop
+-} bind executeonly def
++} bind executeonly odef
+ /.adjustcharwidth {	% <wx> <wy> .adjustcharwidth <wx'> <wy'>
+   % Enforce the metrics, in glyph space, to the values found in the PDF Font object
+   % - force wy == 0 (assumed, and not stored in the PDF font)
+@@ -2026,7 +2026,7 @@ currentdict /CMap_read_dict undef
+     } if
+     /findresource cvx /undefined signalerror
+   } loop
+-} bind executeonly def
++} bind executeonly odef
+ 
+ /buildCIDType0 {	% <CIDFontType0-font-resource> buildCIDType0 <font>
+   dup /BaseFont get findCIDFont exch pop
+@@ -2211,7 +2211,7 @@ currentdict /CMap_read_dict undef
+   /Type0 //buildType0
+   /Type1 //buildType1
+   /MMType1 //buildType1
+-  /Type3 //buildType3
++  /Type3 /buildType3 load
+   /TrueType //buildTrueType
+   /CIDFontType0 //buildCIDType0
+   /CIDFontType2 //buildCIDType2
+diff --git a/Resource/Init/pdf_main.ps b/Resource/Init/pdf_main.ps
+index 09f8735..c823e69 100644
+--- a/Resource/Init/pdf_main.ps
++++ b/Resource/Init/pdf_main.ps
+@@ -660,7 +660,7 @@ currentdict /runpdfstring .undef
+     } forall
+     pop
+   } ifelse
+-} bind executeonly def
++} bind executeonly odef
+ 
+ currentdict /pdf_collection_files .undef
+ 
+@@ -2715,7 +2715,7 @@ currentdict /PDF2PS_matrix_key undef
+   .setglobal
+   /RepairedAnError exch def
+   /Repaired exch def
+-} bind executeonly def
++} bind executeonly odef
+ 
+ % Display the contents of a page (including annotations).
+ /showpagecontents {	% <pagedict> showpagecontents -
+diff --git a/Resource/Init/pdf_ops.ps b/Resource/Init/pdf_ops.ps
+index c45fc51..8672d61 100644
+--- a/Resource/Init/pdf_ops.ps
++++ b/Resource/Init/pdf_ops.ps
+@@ -193,7 +193,7 @@ currentdict /gput_always_allow .undef
+       pdfformaterror
+     } ifelse
+   } if
+-} bind executeonly def
++} bind executeonly odef
+ 
+ % Save PDF gstate
+ /qstate {       % - qstate <qstate>
+@@ -451,7 +451,7 @@ currentdict /gput_always_allow .undef
+   %% a gsave, so we haven't copied it to /self, if we don't do that here
+   %% then transparent annotations cause an invalid access error.
+   currentdict //nodict eq {/self dup load end 5 dict begin def} if
+-} bind executeonly def
++} bind executeonly odef
+ /AIS { .setalphaisshape } bind executeonly def
+ /BM {
+   /.setblendmode where {
+@@ -1077,7 +1077,7 @@ end readonly def
+     pdfopdict /v {inside_text_v} bind .forceput
+     pdfopdict /y {inside_text_y} bind .forceput
+     pdfopdict /re {inside_text_re} bind .forceput
+-} bind executeonly def
++} bind executeonly odef
+ 
+ /switch_to_normal_marking_ops {
+     pdfopdict /m {normal_m} bind .forceput
+@@ -1086,7 +1086,7 @@ end readonly def
+     pdfopdict /v {normal_v} bind .forceput
+     pdfopdict /y {normal_y} bind .forceput
+     pdfopdict /re {normal_re} bind .forceput
+-} bind executeonly def
++} bind executeonly odef
+ 
+ /BT {
+   currentdict /TextSaveMatrix known {
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-extended/ghostscript/files/0003-Bug-699832-add-control-over-hiding-error-handlers.patch b/poky/meta/recipes-extended/ghostscript/files/0003-Bug-699832-add-control-over-hiding-error-handlers.patch
new file mode 100644
index 0000000..cd78659
--- /dev/null
+++ b/poky/meta/recipes-extended/ghostscript/files/0003-Bug-699832-add-control-over-hiding-error-handlers.patch
@@ -0,0 +1,172 @@
+From 1f9a91c86bd56acf57826b9b0e020ebe1953e2ae Mon Sep 17 00:00:00 2001
+From: Chris Liddell <chris.liddell@artifex.com>
+Date: Thu, 4 Oct 2018 10:42:13 +0100
+Subject: [PATCH 3/5] Bug 699832: add control over hiding error handlers.
+
+With a previous commit changing error handling in SAFER so the handler gets
+passed a name object (rather than executable object), it is less critical to
+hide the error handlers.
+
+This introduces a -dSAFERERRORS option to force only use of the default error
+handlers.
+
+It also adds a .setsafererrors Postscript call, meaning a caller, without
+-dSAFERERRORS, can create their own default error handlers (in errordict, as
+normal), and then call .setsafererrors meaning their own handlers are always
+called.
+
+With -dSAFERERRORS or after a call to .setsafererrors, .setsafererrors is
+removed.
+
+CVE: CVE-2018-17961
+Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ Resource/Init/gs_init.ps | 42 +++++++++++++++++++++++++++++------------
+ psi/interp.c             | 49 ++++++++++++++++++++++++++++--------------------
+ 2 files changed, 59 insertions(+), 32 deletions(-)
+
+diff --git a/Resource/Init/gs_init.ps b/Resource/Init/gs_init.ps
+index bec307d..f952f32 100644
+--- a/Resource/Init/gs_init.ps
++++ b/Resource/Init/gs_init.ps
+@@ -188,6 +188,16 @@ currentdict /DELAYSAFER known { /DELAYSAFER //true def /NOSAFER //true def } if
+   currentdict /PARANOIDSAFER known or	% PARANOIDSAFER is equivalent
+ }
+ ifelse def
++
++/SAFERERRORS
++currentdict /NOSAFERERRORS known
++{
++  //false
++}
++{
++  currentdict /SAFERERRORS known
++} ifelse def
++
+ currentdict /SHORTERRORS known   /SHORTERRORS exch def
+ currentdict /TTYPAUSE known   /TTYPAUSE exch def
+ currentdict /WRITESYSTEMDICT known   /WRITESYSTEMDICT exch def
+@@ -1123,12 +1133,23 @@ errordict begin
+  } bind def
+ end		% errordict
+ 
+-% Put all the default handlers in gserrordict
+-gserrordict
+-errordict {2 index 3 1 roll put} forall
+-noaccess pop
+-% remove the non-standard errors from errordict
++gserrordict /unknownerror errordict /unknownerror get put
+ errordict /unknownerror .undef
++
++/.SAFERERRORLIST ErrorNames def
++/.setsafererrors
++{
++% Put all the requested handlers in gserrordict
++  gserrordict
++  //.SAFERERRORLIST
++  {dup errordict exch get 2 index 3 1 roll put} forall
++  noaccess pop
++  systemdict /.setsafeerrors .forceundef
++  systemdict /.SAFERERRORLIST .forceundef
++} bind executeonly odef
++
++SAFERERRORS {.setsafererrors} if
++
+ % Define a stable private copy of handleerror that we will always use under
+ % JOBSERVER mode.
+ /.GShandleerror errordict /handleerror get def
+@@ -1760,18 +1781,15 @@ currentdict /.runlibfile .undef
+ 
+ % Bind all the operators defined as procedures.
+ /.bindoperators		% binds operators in currentdict
+- { % Temporarily disable the typecheck error.
+-   errordict /typecheck 2 copy get
+-   errordict /typecheck { pop } put	% pop the command
++ {
+    currentdict
+     { dup type /operatortype eq
+-       { % This might be a real operator, so bind might cause a typecheck,
+-         % but we've made the error a no-op temporarily.
+-         .bind
++       {
++         % This might be a real operator, so bind might cause a typecheck
++         {.bind} .internalstopped pop
+        }
+       if pop pop
+     } forall
+-   put
+  } def
+ DELAYBIND not { .bindoperators } if
+ 
+diff --git a/psi/interp.c b/psi/interp.c
+index 3dd5f7a..cd894f9 100644
+--- a/psi/interp.c
++++ b/psi/interp.c
+@@ -662,27 +662,18 @@ again:
+     if (gs_errorname(i_ctx_p, code, &error_name) < 0)
+         return code;            /* out-of-range error code! */
+ 
+-    /*  If LockFilePermissions is true, we only refer to gserrordict, which
+-     *  is not accessible to Postcript jobs
++    /*  We refer to gserrordict first, which is not accessible to Postcript jobs
++     *  If we're running with SAFERERRORS all the handlers are copied to gserrordict
++     *  so we'll always find the default one. If not SAFERERRORS, only gs specific
++     *  errors are in gserrordict.
+      */
+-    if (i_ctx_p->LockFilePermissions) {
+-        if (((dict_find_string(systemdict, "gserrordict", &perrordict) <= 0 ||
+-              dict_find(perrordict, &error_name, &epref) <= 0))
+-            )
+-            return code;            /* error name not in errordict??? */
+-    }
+-    else {
+-        /*
+-         * For greater Adobe compatibility, only the standard PostScript errors
+-         * are defined in errordict; the rest are in gserrordict.
+-         */
+-        if (dict_find_string(systemdict, "errordict", &perrordict) <= 0 ||
+-            (dict_find(perrordict, &error_name, &epref) <= 0 &&
+-             (dict_find_string(systemdict, "gserrordict", &perrordict) <= 0 ||
+-              dict_find(perrordict, &error_name, &epref) <= 0))
+-            )
+-            return code;            /* error name not in errordict??? */
+-    }
++    if (dict_find_string(systemdict, "gserrordict", &perrordict) <= 0 ||
++        (dict_find(perrordict, &error_name, &epref) <= 0 &&
++         (dict_find_string(systemdict, "errordict", &perrordict) <= 0 ||
++          dict_find(perrordict, &error_name, &epref) <= 0))
++        )
++        return code;            /* error name not in errordict??? */
++
+     doref = *epref;
+     epref = &doref;
+     /* Push the error object on the operand stack if appropriate. */
+@@ -695,6 +686,24 @@ again:
+         }
+         *osp = *perror_object;
+         errorexec_find(i_ctx_p, osp);
++        /* If using SAFER, hand a name object to the error handler, rather than the executable
++         * object/operator itself.
++         */
++        if (i_ctx_p->LockFilePermissions) {
++            code = obj_cvs(imemory, osp, buf + 2, 256, &rlen, (const byte **)&bufptr);
++            if (code < 0) {
++                const char *unknownstr = "--unknown--";
++                rlen = strlen(unknownstr);
++                memcpy(buf, unknownstr, rlen);
++            }
++            else {
++                buf[0] = buf[1] = buf[rlen + 2] = buf[rlen + 3] = '-';
++                rlen += 4;
++            }
++            code = name_ref(imemory, buf, rlen, osp, 1);
++            if (code < 0)
++                make_null(osp);
++        }
+     }
+     goto again;
+ }
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-extended/ghostscript/files/0004-For-hidden-operators-pass-a-name-object-to-error-han.patch b/poky/meta/recipes-extended/ghostscript/files/0004-For-hidden-operators-pass-a-name-object-to-error-han.patch
new file mode 100644
index 0000000..6c715ad
--- /dev/null
+++ b/poky/meta/recipes-extended/ghostscript/files/0004-For-hidden-operators-pass-a-name-object-to-error-han.patch
@@ -0,0 +1,105 @@
+From 34a8c5aa987d4db5234172a62218b168371606b1 Mon Sep 17 00:00:00 2001
+From: Chris Liddell <chris.liddell@artifex.com>
+Date: Tue, 2 Oct 2018 16:02:58 +0100
+Subject: [PATCH 4/5] For hidden operators, pass a name object to error
+ handler.
+
+In normal operation, Postscript error handlers are passed the object which
+triggered the error: this is invariably an operator object.
+
+The issue arises when an error is triggered by an operator which is for internal
+use only, and that operator is then passed to the error handler, meaning it
+becomes visible to the error handler code.
+
+By converting to a name object, the error message is still valid, but we no
+longer expose internal use only operators.
+
+The change in gs_dps1.ps is related to the above: previously an error in
+scheck would throw an error against .gcheck, but as .gcheck is now a hidden
+operator, it resulted in a name object being passed to the error handler. As
+scheck is a 'real' operator, it's better to use the real operator, rather than
+the name of an internal, hidden one.
+
+CVE: CVE-2018-17961
+Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ Resource/Init/gs_dps1.ps |  2 +-
+ psi/interp.c             | 33 ++++++++++++++++++++++++---------
+ 2 files changed, 25 insertions(+), 10 deletions(-)
+
+diff --git a/Resource/Init/gs_dps1.ps b/Resource/Init/gs_dps1.ps
+index 1182f53..ec5db61 100644
+--- a/Resource/Init/gs_dps1.ps
++++ b/Resource/Init/gs_dps1.ps
+@@ -21,7 +21,7 @@ level2dict begin
+ % ------ Virtual memory ------ %
+ 
+ /currentshared /.currentglobal load def
+-/scheck /.gcheck load def
++/scheck {.gcheck} bind odef
+ %****** FOLLOWING IS WRONG ******
+ /shareddict currentdict /globaldict .knownget not { 20 dict } if def
+ 
+diff --git a/psi/interp.c b/psi/interp.c
+index cd894f9..b70769d 100644
+--- a/psi/interp.c
++++ b/psi/interp.c
+@@ -678,6 +678,8 @@ again:
+     epref = &doref;
+     /* Push the error object on the operand stack if appropriate. */
+     if (!GS_ERROR_IS_INTERRUPT(code)) {
++        byte buf[260], *bufptr;
++        uint rlen;
+         /* Replace the error object if within an oparray or .errorexec. */
+         osp++;
+         if (osp >= ostop) {
+@@ -686,23 +688,36 @@ again:
+         }
+         *osp = *perror_object;
+         errorexec_find(i_ctx_p, osp);
+-        /* If using SAFER, hand a name object to the error handler, rather than the executable
+-         * object/operator itself.
+-         */
+-        if (i_ctx_p->LockFilePermissions) {
++
++        if (!r_has_type(osp, t_string) && !r_has_type(osp, t_name)) {
+             code = obj_cvs(imemory, osp, buf + 2, 256, &rlen, (const byte **)&bufptr);
+             if (code < 0) {
+                 const char *unknownstr = "--unknown--";
+                 rlen = strlen(unknownstr);
+                 memcpy(buf, unknownstr, rlen);
++                bufptr = buf;
+             }
+             else {
+-                buf[0] = buf[1] = buf[rlen + 2] = buf[rlen + 3] = '-';
+-                rlen += 4;
++                ref *tobj;
++                bufptr[rlen] = '\0';
++                /* Only pass a name object if the operator doesn't exist in systemdict
++                 * i.e. it's an internal operator we have hidden
++                 */
++                code = dict_find_string(systemdict, (const char *)bufptr, &tobj);
++                if (code < 0) {
++                    buf[0] = buf[1] = buf[rlen + 2] = buf[rlen + 3] = '-';
++                    rlen += 4;
++                    bufptr = buf;
++                }
++                else {
++                    bufptr = NULL;
++                }
++            }
++            if (bufptr) {
++                code = name_ref(imemory, buf, rlen, osp, 1);
++                if (code < 0)
++                    make_null(osp);
+             }
+-            code = name_ref(imemory, buf, rlen, osp, 1);
+-            if (code < 0)
+-                make_null(osp);
+         }
+     }
+     goto again;
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-extended/ghostscript/files/0005-Bug-699938-.loadfontloop-must-be-an-operator.patch b/poky/meta/recipes-extended/ghostscript/files/0005-Bug-699938-.loadfontloop-must-be-an-operator.patch
new file mode 100644
index 0000000..4924b3c
--- /dev/null
+++ b/poky/meta/recipes-extended/ghostscript/files/0005-Bug-699938-.loadfontloop-must-be-an-operator.patch
@@ -0,0 +1,31 @@
+From f0a61679d28bc1561640403d92492e199bc1c0f3 Mon Sep 17 00:00:00 2001
+From: Chris Liddell <chris.liddell@artifex.com>
+Date: Wed, 10 Oct 2018 23:25:51 +0100
+Subject: [PATCH 5/5] Bug 699938: .loadfontloop must be an operator
+
+In the fix for Bug 699816, I omitted to make .loadfontloop into an operator, to
+better hide .forceundef and .putgstringcopy.
+
+CVE: CVE-2018-17961
+Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ Resource/Init/gs_fonts.ps | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/Resource/Init/gs_fonts.ps b/Resource/Init/gs_fonts.ps
+index 89c3ab7..72feff2 100644
+--- a/Resource/Init/gs_fonts.ps
++++ b/Resource/Init/gs_fonts.ps
+@@ -1148,7 +1148,7 @@ $error /SubstituteFont { } put
+ 
+     } loop              % end of loop
+ 
+- } bind executeonly def % must be bound and hidden for .putgstringcopy
++ } bind executeonly odef % must be bound and hidden for .putgstringcopy
+ 
+ currentdict /.putgstringcopy .undef
+ 
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-extended/ghostscript/files/0006-Undefine-some-additional-internal-operators.patch b/poky/meta/recipes-extended/ghostscript/files/0006-Undefine-some-additional-internal-operators.patch
new file mode 100644
index 0000000..19cf7cc
--- /dev/null
+++ b/poky/meta/recipes-extended/ghostscript/files/0006-Undefine-some-additional-internal-operators.patch
@@ -0,0 +1,42 @@
+From 37d7c9117b70e75ebed21c6c8192251f127c0fb0 Mon Sep 17 00:00:00 2001
+From: Nancy Durgin <nancy.durgin@artifex.com>
+Date: Mon, 5 Nov 2018 15:36:27 +0800
+Subject: [PATCH 1/2] Undefine some additional internal operators.
+
+.type, .writecvs, .setSMask, .currentSMask
+
+These don't seem to be referenced anywhere outside of the initialization code,
+which binds their usages.  Passes cluster if they are removed.
+
+CVE: CVE-2018-18073
+Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ Resource/Init/gs_init.ps | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/Resource/Init/gs_init.ps b/Resource/Init/gs_init.ps
+index f952f32..7c71d18 100644
+--- a/Resource/Init/gs_init.ps
++++ b/Resource/Init/gs_init.ps
+@@ -2230,6 +2230,7 @@ SAFER { .setsafeglobal } if
+   /.localvmarray /.localvmdict /.localvmpackedarray /.localvmstring /.systemvmarray /.systemvmdict /.systemvmpackedarray /.systemvmstring /.systemvmfile /.systemvmlibfile
+   /.systemvmSFD /.settrapparams /.currentsystemparams /.currentuserparams /.getsystemparam /.getuserparam /.setsystemparams /.setuserparams
+   /.checkpassword /.locale_to_utf8 /.currentglobal /.gcheck /.imagepath
++  /.type /.writecvs /.setSMask /.currentSMask
+ 
+   % Used by a free user in the Library of Congress. Apparently this is used to
+   % draw a partial page, which is then filled in by the results of a barcode
+@@ -2248,7 +2249,7 @@ SAFER { .setsafeglobal } if
+   % test files/utilities, or engineers expressed a desire to keep them visible.
+   %
+   %/currentdevice /.sort /.buildfont0 /.buildfont1 /.buildfont2 /.buildfont3 /.buildfont4 /.buildfont9 /.buildfont10 /.buildfont11
+-  %/.buildfotn32 /.buildfont42 /.type9mapcid /.type11mapcid /.swapcolors
++  %/.buildfont32 /.buildfont42 /.type9mapcid /.type11mapcid /.swapcolors
+   %/currentdevice  /.quit /.setuseciecolor /.needinput /.setoverprintmode /.special_op /.dicttomark /.knownget
+   %/.FAPIavailable /.FAPIpassfont /.FAPIrebuildfont /.FAPIBuildGlyph /.FAPIBuildChar /.FAPIBuildGlyph9
+   %/.tempfile /.numicc_components /.set_outputintent  /.max /.min /.vmreclaim /.getpath /.setglobal
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-extended/ghostscript/files/0007-Bug-699927-don-t-include-operator-arrays-in-execstac.patch b/poky/meta/recipes-extended/ghostscript/files/0007-Bug-699927-don-t-include-operator-arrays-in-execstac.patch
new file mode 100644
index 0000000..ad66fc3
--- /dev/null
+++ b/poky/meta/recipes-extended/ghostscript/files/0007-Bug-699927-don-t-include-operator-arrays-in-execstac.patch
@@ -0,0 +1,197 @@
+From 430f39144244ba4fd7b720cf87031e415e0fabce Mon Sep 17 00:00:00 2001
+From: Chris Liddell <chris.liddell@artifex.com>
+Date: Mon, 5 Nov 2018 15:42:52 +0800
+Subject: [PATCH 2/2] Bug 699927: don't include operator arrays in execstack
+ output
+
+When we transfer the contents of the execution stack into the array, take the
+extra step of replacing any operator arrays on the stack with the operator
+that reference them.
+
+This prevents the contents of Postscript defined, internal only operators (those
+created with .makeoperator) being exposed via execstack (and thus, via error
+handling).
+
+This necessitates a change in the resource remapping 'resource', which contains
+a procedure which relies on the contents of the operators arrays being present.
+As we already had internal-only variants of countexecstack and execstack
+(.countexecstack and .execstack) - using those, and leaving thier operation
+including the operator arrays means the procedure continues to work correctly.
+
+Both .countexecstack and .execstack are undefined after initialization.
+
+Also, when we store the execstack (or part thereof) for an execstackoverflow
+error, make the same oparray/operator substitution as above for execstack.
+
+CVE: CVE-2018-18073
+Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ Resource/Init/gs_init.ps  |  4 ++--
+ Resource/Init/gs_resmp.ps |  2 +-
+ psi/int.mak               |  2 +-
+ psi/interp.c              | 14 +++++++++++---
+ psi/interp.h              |  2 ++
+ psi/zcontrol.c            | 13 ++++++++++---
+ 6 files changed, 27 insertions(+), 10 deletions(-)
+
+diff --git a/Resource/Init/gs_init.ps b/Resource/Init/gs_init.ps
+index 7c71d18..f4c1053 100644
+--- a/Resource/Init/gs_init.ps
++++ b/Resource/Init/gs_init.ps
+@@ -2191,7 +2191,7 @@ SAFER { .setsafeglobal } if
+   %% but can be easily restored (just delete the name from the list in the array). In future
+   %% we may remove the operator and the code implementation entirely.
+   [
+-  /.bitadd /.charboxpath /.cond /.countexecstack /.execstack /.runandhide /.popdevicefilter
++  /.bitadd /.charboxpath /.cond /.runandhide /.popdevicefilter
+   /.execfile /.filenamesplit /.file_name_parent
+   /.setdefaultmatrix /.isprocfilter /.unread /.psstringencode
+   /.buildsampledfunction /.isencapfunction /.currentaccuratecurves /.currentcurvejoin /.currentdashadapt /.currentdotlength
+@@ -2230,7 +2230,7 @@ SAFER { .setsafeglobal } if
+   /.localvmarray /.localvmdict /.localvmpackedarray /.localvmstring /.systemvmarray /.systemvmdict /.systemvmpackedarray /.systemvmstring /.systemvmfile /.systemvmlibfile
+   /.systemvmSFD /.settrapparams /.currentsystemparams /.currentuserparams /.getsystemparam /.getuserparam /.setsystemparams /.setuserparams
+   /.checkpassword /.locale_to_utf8 /.currentglobal /.gcheck /.imagepath
+-  /.type /.writecvs /.setSMask /.currentSMask
++  /.type /.writecvs /.setSMask /.currentSMask /.countexecstack /.execstack
+ 
+   % Used by a free user in the Library of Congress. Apparently this is used to
+   % draw a partial page, which is then filled in by the results of a barcode
+diff --git a/Resource/Init/gs_resmp.ps b/Resource/Init/gs_resmp.ps
+index 7cacaf8..9bb4263 100644
+--- a/Resource/Init/gs_resmp.ps
++++ b/Resource/Init/gs_resmp.ps
+@@ -183,7 +183,7 @@ setpacking
+   % We don't check them.
+ 
+   currentglobal //false setglobal                  % <object> bGlobal
+-  countexecstack array execstack                   % <object> bGlobal [execstack]
++  //false .countexecstack array //false .execstack % <object> bGlobal [execstack]
+   dup //null exch                                  % <object> bGlobal [execstack] null [execstack]
+   length 3 sub -1 0 {                              % <object> bGlobal [execstack] null i
+     2 index exch get                               % <object> bGlobal [execstack] null proc
+diff --git a/psi/int.mak b/psi/int.mak
+index 5d9b3d5..6ab5bf0 100644
+--- a/psi/int.mak
++++ b/psi/int.mak
+@@ -323,7 +323,7 @@ $(PSOBJ)zarray.$(OBJ) : $(PSSRC)zarray.c $(OP) $(memory__h)\
+ 
+ $(PSOBJ)zcontrol.$(OBJ) : $(PSSRC)zcontrol.c $(OP) $(string__h)\
+  $(estack_h) $(files_h) $(ipacked_h) $(iutil_h) $(store_h) $(stream_h)\
+- $(INT_MAK) $(MAKEDIRS)
++ $(interp_h) $(INT_MAK) $(MAKEDIRS)
+ 	$(PSCC) $(PSO_)zcontrol.$(OBJ) $(C_) $(PSSRC)zcontrol.c
+ 
+ $(PSOBJ)zdict.$(OBJ) : $(PSSRC)zdict.c $(OP)\
+diff --git a/psi/interp.c b/psi/interp.c
+index b70769d..6dc0dda 100644
+--- a/psi/interp.c
++++ b/psi/interp.c
+@@ -142,7 +142,6 @@ static int oparray_pop(i_ctx_t *);
+ static int oparray_cleanup(i_ctx_t *);
+ static int zerrorexec(i_ctx_t *);
+ static int zfinderrorobject(i_ctx_t *);
+-static int errorexec_find(i_ctx_t *, ref *);
+ static int errorexec_pop(i_ctx_t *);
+ static int errorexec_cleanup(i_ctx_t *);
+ static int zsetstackprotect(i_ctx_t *);
+@@ -761,7 +760,7 @@ copy_stack(i_ctx_t *i_ctx_p, const ref_stack_t * pstack, int skip, ref * arr)
+ {
+     uint size = ref_stack_count(pstack) - skip;
+     uint save_space = ialloc_space(idmemory);
+-    int code;
++    int code, i;
+ 
+     if (size > 65535)
+         size = 65535;
+@@ -770,6 +769,15 @@ copy_stack(i_ctx_t *i_ctx_p, const ref_stack_t * pstack, int skip, ref * arr)
+     if (code >= 0)
+         code = ref_stack_store(pstack, arr, size, 0, 1, true, idmemory,
+                                "copy_stack");
++    /* If we are copying the exec stack, try to replace any oparrays with
++     * with the operator than references them
++     */
++    if (pstack == &e_stack) {
++        for (i = 0; i < size; i++) {
++            if (errorexec_find(i_ctx_p, &arr->value.refs[i]) < 0)
++                make_null(&arr->value.refs[i]);
++        }
++    }
+     ialloc_set_space(idmemory, save_space);
+     return code;
+ }
+@@ -1934,7 +1942,7 @@ zfinderrorobject(i_ctx_t *i_ctx_p)
+  * .errorexec with errobj != null, store it in *perror_object and return 1,
+  * otherwise return 0;
+  */
+-static int
++int
+ errorexec_find(i_ctx_t *i_ctx_p, ref *perror_object)
+ {
+     long i;
+diff --git a/psi/interp.h b/psi/interp.h
+index e9275b9..4f551d1 100644
+--- a/psi/interp.h
++++ b/psi/interp.h
+@@ -91,5 +91,7 @@ void gs_interp_reset(i_ctx_t *i_ctx_p);
+ /* Define the top-level interface to the interpreter. */
+ int gs_interpret(i_ctx_t **pi_ctx_p, ref * pref, int user_errors,
+                  int *pexit_code, ref * perror_object);
++int
++errorexec_find(i_ctx_t *i_ctx_p, ref *perror_object);
+ 
+ #endif /* interp_INCLUDED */
+diff --git a/psi/zcontrol.c b/psi/zcontrol.c
+index 36da22c..0362cf4 100644
+--- a/psi/zcontrol.c
++++ b/psi/zcontrol.c
+@@ -24,6 +24,7 @@
+ #include "ipacked.h"
+ #include "iutil.h"
+ #include "store.h"
++#include "interp.h"
+ 
+ /* Forward references */
+ static int check_for_exec(const_os_ptr);
+@@ -787,7 +788,7 @@ zexecstack2(i_ctx_t *i_ctx_p)
+ /* Continuation operator to do the actual transfer. */
+ /* r_size(op1) was set just above. */
+ static int
+-do_execstack(i_ctx_t *i_ctx_p, bool include_marks, os_ptr op1)
++do_execstack(i_ctx_t *i_ctx_p, bool include_marks, bool include_oparrays, os_ptr op1)
+ {
+     os_ptr op = osp;
+     ref *arefs = op1->value.refs;
+@@ -829,6 +830,12 @@ do_execstack(i_ctx_t *i_ctx_p, bool include_marks, os_ptr op1)
+                                   strlen(tname), (const byte *)tname);
+                 break;
+             }
++            case t_array:
++            case t_shortarray:
++            case t_mixedarray:
++                if (!include_oparrays && errorexec_find(i_ctx_p, rq) < 0)
++                    make_null(rq);
++                break;
+             default:
+                 ;
+         }
+@@ -841,14 +848,14 @@ execstack_continue(i_ctx_t *i_ctx_p)
+ {
+     os_ptr op = osp;
+ 
+-    return do_execstack(i_ctx_p, false, op);
++    return do_execstack(i_ctx_p, false, false, op);
+ }
+ static int
+ execstack2_continue(i_ctx_t *i_ctx_p)
+ {
+     os_ptr op = osp;
+ 
+-    return do_execstack(i_ctx_p, op->value.boolval, op - 1);
++    return do_execstack(i_ctx_p, op->value.boolval, true, op - 1);
+ }
+ 
+ /* - .needinput - */
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-extended/ghostscript/files/0008-Make-.forceput-unavailable-from-.policyprocs-helper-.patch b/poky/meta/recipes-extended/ghostscript/files/0008-Make-.forceput-unavailable-from-.policyprocs-helper-.patch
new file mode 100644
index 0000000..7cc5162
--- /dev/null
+++ b/poky/meta/recipes-extended/ghostscript/files/0008-Make-.forceput-unavailable-from-.policyprocs-helper-.patch
@@ -0,0 +1,245 @@
+From 9096beaa4451c12dd2a2caf000658fbac4a5bcdf Mon Sep 17 00:00:00 2001
+From: Ken Sharp <ken.sharp@artifex.com>
+Date: Mon, 5 Nov 2018 15:51:32 +0800
+Subject: [PATCH] Make .forceput unavailable from '.policyprocs' helper
+ dictionary
+
+Bug #69963 "1Policy is a dangerous operator, any callers should be odef"
+
+Leaving the .policyprocs dictionary with a procedure which is a simple
+wrapper for .forceput effectively leaves .forceput available.
+
+It seems that the only reason to have .policyprocs is to minimise the
+code in .applypolicies, so we can remove the dictionary and put the
+code straight into .applypolicies, which we can then bind and make
+executeonly, which hides the .forceput. Also, since we don't need
+.applypolicies after startup, we can undefine that from systemdict too.
+
+While we're here, review all the uses of .force* to make certain that
+there are no other similar cases. This showed a few places where we
+hadn't made a function executeonly, so do that too. Its probably not
+required, since I'm reasonably sure its impossible to load those
+functions as packed arrays (they are all defined as operators), but lets
+have a belt and braces approach, the additional time cost is negligible.
+
+CVE: CVE-2018-18284
+Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ Resource/Init/gs_diskn.ps |   2 +-
+ Resource/Init/gs_dps.ps   |   2 +-
+ Resource/Init/gs_epsf.ps  |   2 +-
+ Resource/Init/gs_fonts.ps |   4 +-
+ Resource/Init/gs_init.ps  |   2 +-
+ Resource/Init/gs_setpd.ps | 100 ++++++++++++++++++++++++----------------------
+ 6 files changed, 58 insertions(+), 54 deletions(-)
+
+diff --git a/Resource/Init/gs_diskn.ps b/Resource/Init/gs_diskn.ps
+index 26ec0b5..fd694bc 100644
+--- a/Resource/Init/gs_diskn.ps
++++ b/Resource/Init/gs_diskn.ps
+@@ -61,7 +61,7 @@ systemdict begin
+   % doesn't get run enough to justify the complication
+   //.putdevparams
+   //systemdict /.searchabledevs .forceundef
+-} .bind odef % must be bound and hidden for .forceundef
++} .bind executeonly odef % must be bound and hidden for .forceundef
+ 
+ % ------ extend filenameforall to handle wildcards in %dev% part of pattern -------%
+ /filenameforall {
+diff --git a/Resource/Init/gs_dps.ps b/Resource/Init/gs_dps.ps
+index daf7b0f..00c14d5 100644
+--- a/Resource/Init/gs_dps.ps
++++ b/Resource/Init/gs_dps.ps
+@@ -124,7 +124,7 @@
+   /savedinitialgstate .systemvar setgstate gsave
+                 % Wrap up.
+   end .setglobal
+-} odef
++} bind executeonly odef
+ 
+ % Check whether an object is a procedure.
+ /.proccheck {			% <obj> .proccheck <bool>
+diff --git a/Resource/Init/gs_epsf.ps b/Resource/Init/gs_epsf.ps
+index e4037d9..2d0f677 100644
+--- a/Resource/Init/gs_epsf.ps
++++ b/Resource/Init/gs_epsf.ps
+@@ -31,7 +31,7 @@
+ /EPSBoundingBoxState 5 def
+ /EPSBoundingBoxSetState {
+   //systemdict /EPSBoundingBoxState 3 -1 roll .forceput
+-} .bind odef % .forceput must be bound and hidden
++} .bind executeonly odef % .forceput must be bound and hidden
+ 
+ % Parse 4 numbers for a bounding box
+ /EPSBoundingBoxParse { % (llx lly urx ury) -- llx lly urx ury true OR false
+diff --git a/Resource/Init/gs_fonts.ps b/Resource/Init/gs_fonts.ps
+index 72feff2..803faca 100644
+--- a/Resource/Init/gs_fonts.ps
++++ b/Resource/Init/gs_fonts.ps
+@@ -583,7 +583,7 @@ buildfontdict 3 /.buildfont3 cvx put
+ } bind def
+ /.setloadingfont {
+    //systemdict /.loadingfont 3 -1 roll .forceput
+-} .bind odef % .forceput must be bound and hidden
++} .bind executeonly odef % .forceput must be bound and hidden
+ /.loadfont
+  {              % Some buggy fonts leave extra junk on the stack,
+                 % so we have to make a closure that records the stack depth
+@@ -1012,7 +1012,7 @@ $error /SubstituteFont { } put
+     dup length string copy
+     .forceput setglobal
+   } ifelse
+-} .bind odef % must be bound and hidden for .forceput
++} .bind executeonly odef % must be bound and hidden for .forceput
+ 
+ % Attempt to load a font from a file.
+ /.tryloadfont {         % <fontname> .tryloadfont <font> true
+diff --git a/Resource/Init/gs_init.ps b/Resource/Init/gs_init.ps
+index f4c1053..07ee968 100644
+--- a/Resource/Init/gs_init.ps
++++ b/Resource/Init/gs_init.ps
+@@ -2230,7 +2230,7 @@ SAFER { .setsafeglobal } if
+   /.localvmarray /.localvmdict /.localvmpackedarray /.localvmstring /.systemvmarray /.systemvmdict /.systemvmpackedarray /.systemvmstring /.systemvmfile /.systemvmlibfile
+   /.systemvmSFD /.settrapparams /.currentsystemparams /.currentuserparams /.getsystemparam /.getuserparam /.setsystemparams /.setuserparams
+   /.checkpassword /.locale_to_utf8 /.currentglobal /.gcheck /.imagepath
+-  /.type /.writecvs /.setSMask /.currentSMask /.countexecstack /.execstack
++  /.type /.writecvs /.setSMask /.currentSMask /.countexecstack /.execstack /.applypolicies
+ 
+   % Used by a free user in the Library of Congress. Apparently this is used to
+   % draw a partial page, which is then filled in by the results of a barcode
+diff --git a/Resource/Init/gs_setpd.ps b/Resource/Init/gs_setpd.ps
+index afb4ffa..7c076ad 100644
+--- a/Resource/Init/gs_setpd.ps
++++ b/Resource/Init/gs_setpd.ps
+@@ -609,6 +609,23 @@ NOMEDIAATTRS {
+ % and we replace the key in the <merged> dictionary with its prior value
+ % (or remove it if it had no prior value).
+ 
++% These procedures are called with the following on the stack:
++%   <orig> <merged> <failed> <Policies> <key> <policy>
++% They are expected to consume the top 2 operands.
++% NOTE: we currently treat all values other than 0, 1, or 7 (for PageSize)
++% the same as 0, i.e., we signal an error.
++/0Policy {		% Set errorinfo and signal a configurationerror.
++  NOMEDIAATTRS {
++    % NOMEDIAATTRS means that the default policy is 7...
++    pop 2 index exch 7 put
++  } {
++    pop dup 4 index exch get 2 array astore
++    $error /errorinfo 3 -1 roll put
++    cleartomark
++    /setpagedevice .systemvar /configurationerror signalerror
++  } ifelse
++} bind executeonly odef
++
+ % Making this an operator means we can properly hide
+ % the contents - specifically .forceput
+ /1Policy
+@@ -617,59 +634,46 @@ NOMEDIAATTRS {
+   SETPDDEBUG { (Rolling back.) = pstack flush } if
+   3 index 2 index 3 -1 roll .forceput
+   4 index 1 index .knownget
+-   { 4 index 3 1 roll .forceput }
+-   { 3 index exch .undef }
++  { 4 index 3 1 roll .forceput }
++  { 3 index exch .undef }
+   ifelse
+ } bind executeonly odef
+ 
+-/.policyprocs mark
+-% These procedures are called with the following on the stack:
+-%   <orig> <merged> <failed> <Policies> <key> <policy>
+-% They are expected to consume the top 2 operands.
+-% NOTE: we currently treat all values other than 0, 1, or 7 (for PageSize)
+-% the same as 0, i.e., we signal an error.
+-%
+-% M. Sweet, Easy Software Products:
+-%
+-% Define NOMEDIAATTRS to turn off the default (but unimplementable) media
+-% selection policies for setpagedevice.  This is used by CUPS to support
+-% the standard Adobe media attributes.
+-  0 {		% Set errorinfo and signal a configurationerror.
+-      NOMEDIAATTRS {
+-        % NOMEDIAATTRS means that the default policy is 7...
+-        pop 2 index exch 7 put
+-      } {
+-        pop dup 4 index exch get 2 array astore
+-        $error /errorinfo 3 -1 roll put
+-        cleartomark
+-        /setpagedevice .systemvar /configurationerror signalerror
+-      } ifelse
+-  } bind
+-  1 /1Policy load
+-  7 {		% For PageSize only, just impose the request.
+-        1 index /PageSize eq
+-         { pop pop 1 index /PageSize 7 put }
+-         { .policyprocs 0 get exec }
+-        ifelse
+-  } bind
+-.dicttomark readonly def
+-currentdict /1Policy undef
++/7Policy {		% For PageSize only, just impose the request.
++  1 index /PageSize eq
++  { pop pop 1 index /PageSize 7 put }
++  { .policyprocs 0 get exec }
++  ifelse
++} bind executeonly odef
+ 
+ /.applypolicies		% <orig> <merged> <failed> .applypolicies
+                         %   <orig> <merged'> <failed'>
+- { 1 index /Policies get 1 index
+-    { type /integertype eq
+-       { pop		% already processed
+-       }
+-       { 2 copy .knownget not { 1 index /PolicyNotFound get } if
+-                        % Stack: <orig> <merged> <failed> <Policies> <key>
+-                        %   <policy>
+-         .policyprocs 1 index .knownget not { .policyprocs 0 get } if exec
+-       }
+-      ifelse
+-    }
+-   forall pop
+- } bind def
++{
++  1 index /Policies get 1 index
++  { type /integertype eq
++     {
++       pop		% already processed
++     }{
++       2 copy .knownget not { 1 index /PolicyNotFound get } if
++                      % Stack: <orig> <merged> <failed> <Policies> <key>
++                      %   <policy>
++        dup 1 eq {
++          1Policy
++        }{
++          dup 7 eq {
++            7Policy
++          }{
++            0Policy
++          } ifelse
++        } ifelse
++     } ifelse
++  }
++  forall pop
++} bind executeonly odef
++
++currentdict /0Policy undef
++currentdict /1Policy undef
++currentdict /7Policy undef
+ 
+ % Prepare to present parameters to the device, by spreading them onto the
+ % operand stack and removing any that shouldn't be presented.
+@@ -1006,7 +1010,7 @@ SETPDDEBUG { (Installing.) = pstack flush } if
+     .postinstall
+   } ifelse
+   setglobal           % return to original VM allocation mode
+-} odef
++} bind executeonly odef
+ 
+ % We break out the code after calling the Install procedure into a
+ % separate procedure, since it is executed even if Install causes an error.
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-extended/ghostscript/files/do-not-check-local-libpng-source.patch b/poky/meta/recipes-extended/ghostscript/files/do-not-check-local-libpng-source.patch
index c3e44fe..5834ffa 100644
--- a/poky/meta/recipes-extended/ghostscript/files/do-not-check-local-libpng-source.patch
+++ b/poky/meta/recipes-extended/ghostscript/files/do-not-check-local-libpng-source.patch
@@ -1,7 +1,7 @@
-From 5ef8b85bc98f3bd9a15d5f47e24d3e23ae27c265 Mon Sep 17 00:00:00 2001
+From a954bf29a5f906b3151dffbecb5856e02e1565da Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Mon, 18 Jan 2016 01:00:30 -0500
-Subject: [PATCH] configure.ac: do not check local png source
+Subject: [PATCH 03/10] configure.ac: do not check local png source
 
 In oe-core, it did not need to compile local libpng
 source in ghostscript, so do not check local png
@@ -16,10 +16,10 @@
  1 file changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/configure.ac b/configure.ac
-index bf6d3f5..01df03f 100644
+index 9341930..80a60b1 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -930,11 +930,11 @@ AC_SUBST(ZLIBDIR)
+@@ -1114,11 +1114,11 @@ AC_SUBST(ZLIBDIR)
  AC_SUBST(FT_SYS_ZLIB)
  
  dnl png for the png output device; it also requires zlib
@@ -34,5 +34,5 @@
          SHARE_LIBPNG=0
          LIBPNGDIR=$srcdir/libpng
 -- 
-2.8.1
+1.8.3.1
 
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-11714.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-11714.patch
deleted file mode 100644
index 84983c5..0000000
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-11714.patch
+++ /dev/null
@@ -1,61 +0,0 @@
-From 671fd59eb657743aa86fbc1895cb15872a317caa Mon Sep 17 00:00:00 2001
-From: Chris Liddell <chris.liddell@artifex.com>
-Date: Thu, 6 Jul 2017 14:54:02 +0100
-Subject: [PATCH] Bug 698158: prevent trying to reloc a freed object
-
-In the token reader, we pass the scanner state structure around as a
-t_struct ref on the Postscript operand stack.
-
-But we explicitly free the scanner state when we're done, which leaves a
-dangling reference on the operand stack and, unless that reference gets
-overwritten before the next garbager run, we can end up with the garbager
-trying to deal with an already freed object - that can cause a crash, or
-memory corruption.
----
- psi/ztoken.c |   14 +++++++++++++-
- 1 file changed, 13 insertions(+), 1 deletion(-)
-
---- end of original header
-
-CVE: CVE-2017-11714
-
-Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
-
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
-
-diff --git a/psi/ztoken.c b/psi/ztoken.c
-index 4dba7c5..af1ceeb 100644
---- a/psi/ztoken.c
-+++ b/psi/ztoken.c
-@@ -107,6 +107,12 @@ token_continue(i_ctx_t *i_ctx_p, scanner_state * pstate, bool save)
-     int code;
-     ref token;
- 
-+    /* Since we might free pstate below, and we're dealing with
-+     * gc memory referenced by the stack, we need to explicitly
-+     * remove the reference to pstate from the stack, otherwise
-+     * the garbager will fall over
-+     */
-+    make_null(osp);
-     /* Note that gs_scan_token may change osp! */
-     pop(1);                     /* remove the file or scanner state */
- again:
-@@ -183,8 +189,14 @@ ztokenexec_continue(i_ctx_t *i_ctx_p)
- static int
- tokenexec_continue(i_ctx_t *i_ctx_p, scanner_state * pstate, bool save)
- {
--    os_ptr op;
-+    os_ptr op = osp;
-     int code;
-+    /* Since we might free pstate below, and we're dealing with
-+     * gc memory referenced by the stack, we need to explicitly
-+     * remove the reference to pstate from the stack, otherwise
-+     * the garbager will fall over
-+     */
-+    make_null(osp);
-     /* Note that gs_scan_token may change osp! */
-     pop(1);
- again:
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-5951.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-5951.patch
deleted file mode 100644
index 62cc134..0000000
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-5951.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From bfa6b2ecbe48edc69a7d9d22a12419aed25960b8 Mon Sep 17 00:00:00 2001
-From: Chris Liddell <chris.liddell@artifex.com>
-Date: Thu, 6 Apr 2017 16:44:54 +0100
-Subject: [PATCH] Bug 697548: use the correct param list enumerator
-
-When we encountered dictionary in a ref_param_list, we were using the enumerator
-for the "parent" param_list, rather than the enumerator for the param_list
-we just created for the dictionary. That parent was usually the stack
-list enumerator, and caused a segfault.
-
-Using the correct enumerator works better.
-
-Upstream-Status: Backport
-CVE: CVE-2017-5951
-
-Signed-off-by: Catalin Enache <catalin.enache@windriver.com>
----
- psi/iparam.c | 7 ++++---
- 1 file changed, 4 insertions(+), 3 deletions(-)
-
-diff --git a/psi/iparam.c b/psi/iparam.c
-index 4e63b6d..b2fa85f 100644
---- a/psi/iparam.c
-+++ b/psi/iparam.c
-@@ -770,12 +770,13 @@ ref_param_read_typed(gs_param_list * plist, gs_param_name pkey,
-                 gs_param_enumerator_t enumr;
-                 gs_param_key_t key;
-                 ref_type keytype;
-+                dict_param_list *dlist = (dict_param_list *) pvalue->value.d.list;
- 
-                 param_init_enumerator(&enumr);
--                if (!(*((iparam_list *) plist)->enumerate)
--                    ((iparam_list *) pvalue->value.d.list, &enumr, &key, &keytype)
-+                if (!(*(dlist->enumerate))
-+                    ((iparam_list *) dlist, &enumr, &key, &keytype)
-                     && keytype == t_integer) {
--                    ((dict_param_list *) pvalue->value.d.list)->int_keys = 1;
-+                    dlist->int_keys = 1;
-                     pvalue->type = gs_param_type_dict_int_keys;
-                 }
-             }
--- 
-2.10.2
-
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-7207.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-7207.patch
deleted file mode 100644
index a05dc02..0000000
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-7207.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From 0e88bee1304993668fede72498d656a2dd33a35e Mon Sep 17 00:00:00 2001
-From: Ken Sharp <ken.sharp@artifex.com>
-Date: Mon, 20 Mar 2017 09:34:11 +0000
-Subject: [PATCH] Ensure a device has raster memory, before trying to read it.
-
-Bug #697676 "Null pointer dereference in mem_get_bits_rectangle()"
-
-This is only possible by abusing/mis-using Ghostscript-specific
-language extensions, so cannot happen in a general PostScript program.
-
-Nevertheless, Ghostscript should not crash. So this commit checks the
-memory device to see if raster memory has been allocated, before trying
-to read from it.
-
-Upstream-Status: Backport
-CVE: CVE-2017-7207
-
-Author: Ken Sharp <ken.sharp@artifex.com>
-Signed-off-by: Catalin Enache <catalin.enache@windriver.com>
----
- base/gdevmem.c | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/base/gdevmem.c b/base/gdevmem.c
-index 41108ba..183f96d 100644
---- a/base/gdevmem.c
-+++ b/base/gdevmem.c
-@@ -605,6 +605,8 @@ mem_get_bits_rectangle(gx_device * dev, const gs_int_rect * prect,
-             GB_PACKING_CHUNKY | GB_COLORS_NATIVE | GB_ALPHA_NONE;
-         return_error(gs_error_rangecheck);
-     }
-+    if (mdev->line_ptrs == 0x00)
-+        return_error(gs_error_rangecheck);
-     if ((w <= 0) | (h <= 0)) {
-         if ((w | h) < 0)
-             return_error(gs_error_rangecheck);
--- 
-2.10.2
-
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-7975.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-7975.patch
deleted file mode 100644
index e406086..0000000
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-7975.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From b39be1019b4acc1aa50c6026463c543332e95a31 Mon Sep 17 00:00:00 2001
-From: Catalin Enache <catalin.enache@windriver.com>
-Date: Mon, 8 May 2017 16:18:14 +0300
-
-Subject: [PATCH] Bug 697693: Prevent SEGV due to integer overflow.
-
-While building a Huffman table, the start and end points were susceptible
-to integer overflow.
-
-Thank you to Jiaqi for finding this issue and suggesting a patch.
-
-Upstream-Status: Backport
-CVE: CVE-2017-7975
-
-Signed-off-by: Catalin Enache <catalin.enache@windriver.com>
-
-Contents of this patch were extracted from a larger patch which addressed
-two CVE's.  The context (location of {) was also modified to apply to
-ghostscript 9.21.
-
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
-
-
---- a/jbig2dec/jbig2_huffman.c
-+++ b/jbig2dec/jbig2_huffman.c
-@@ -421,8 +421,8 @@ jbig2_build_huffman_table(Jbig2Ctx *ctx,
- 
-             if (PREFLEN == CURLEN) {
-                 int RANGELEN = lines[CURTEMP].RANGELEN;
--                int start_j = CURCODE << shift;
--                int end_j = (CURCODE + 1) << shift;
-+                uint32_t start_j = CURCODE << shift;
-+                uint32_t end_j = (CURCODE + 1) << shift;
-                 byte eflags = 0;
- 
-                 if (end_j > max_j) {
-
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9216.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9216.patch
deleted file mode 100644
index 1caeb3e..0000000
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9216.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From 3ebffb1d96ba0cacec23016eccb4047dab365853 Mon Sep 17 00:00:00 2001
-From: Shailesh Mistry <shailesh.mistry@hotmail.co.uk>
-Date: Wed, 24 May 2017 19:29:57 +0100
-Subject: [PATCH] Bug 697934: Fix SEGV due to error code being ignored.
-
-The return code from jbig2_decode_text_region was being ignored so the
-code continued to try and parse the invalid file using incomplete/empty
-structures.
-
-Upstream-Status: Backport
-CVE: CVE-2017-9216
-
-Signed-off-by: Catalin Enache <catalin.enache@windriver.com>
----
- jbig2dec/jbig2_symbol_dict.c | 4 +++-
- 1 file changed, 3 insertions(+), 1 deletion(-)
-
-diff --git a/jbig2dec/jbig2_symbol_dict.c b/jbig2dec/jbig2_symbol_dict.c
-index 3cc1731..672425d 100644
---- a/jbig2dec/jbig2_symbol_dict.c
-+++ b/jbig2dec/jbig2_symbol_dict.c
-@@ -493,8 +493,10 @@ jbig2_decode_symbol_dict(Jbig2Ctx *ctx,
-                         }
- 
-                         /* multiple symbols are handled as a text region */
--                        jbig2_decode_text_region(ctx, segment, tparams, (const Jbig2SymbolDict * const *)refagg_dicts,
-+                        code = jbig2_decode_text_region(ctx, segment, tparams, (const Jbig2SymbolDict * const *)refagg_dicts,
-                                                  n_refagg_dicts, image, data, size, GR_stats, as, ws);
-+                        if (code < 0)
-+                            goto cleanup4;
- 
-                         SDNEWSYMS->glyphs[NSYMSDECODED] = image;
-                         refagg_dicts[0]->glyphs[params->SDNUMINSYMS + NSYMSDECODED] = jbig2_image_clone(ctx, SDNEWSYMS->glyphs[NSYMSDECODED]);
--- 
-2.10.2
-
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9611.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9611.patch
deleted file mode 100644
index 58ef04d..0000000
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9611.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From c7c55972758a93350882c32147801a3485b010fe Mon Sep 17 00:00:00 2001
-From: Chris Liddell <chris.liddell@artifex.com>
-Date: Mon, 12 Jun 2017 13:08:40 +0100
-Subject: [PATCH] Bug 698024: bounds check zone pointer in Ins_MIRP()
-
----
- base/ttinterp.c |    3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
---- end of original header
-
-CVE: CVE-2017-9611
-
-Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
-
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
-
-diff --git a/base/ttinterp.c b/base/ttinterp.c
-index e56aec6..f6a6d95 100644
---- a/base/ttinterp.c
-+++ b/base/ttinterp.c
-@@ -3858,7 +3858,8 @@ static int nInstrCount=0;
-     /* XXX: UNDOCUMENTED! cvt[-1] = 0 always */
- 
-     if ( BOUNDS( args[0],   CUR.zp1.n_points ) ||
--         BOUNDS( args[1]+1, CUR.cvtSize+1 )    )
-+         BOUNDS( args[1]+1, CUR.cvtSize+1 )    ||
-+         BOUNDS(CUR.GS.rp0,  CUR.zp0.n_points) )
-     {
-       CUR.error = TT_Err_Invalid_Reference;
-       return;
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9612.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9612.patch
deleted file mode 100644
index b737cc5..0000000
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9612.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From 98f6da60b9d463c617e631fc254cf6d66f2e8e3c Mon Sep 17 00:00:00 2001
-From: Chris Liddell <chris.liddell@artifex.com>
-Date: Mon, 12 Jun 2017 13:15:17 +0100
-Subject: [PATCH] Bug 698026: bounds check zone pointers in Ins_IP()
-
----
- base/ttinterp.c |    4 +++-
- 1 file changed, 3 insertions(+), 1 deletion(-)
-
---- end of original header
-
-CVE: CVE-2017-9612
-
-Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
-
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
-
-diff --git a/base/ttinterp.c b/base/ttinterp.c
-index f6a6d95..e7c9d68 100644
---- a/base/ttinterp.c
-+++ b/base/ttinterp.c
-@@ -4129,7 +4129,9 @@ static int nInstrCount=0;
-     Int         point;
-     (void)args;
- 
--    if ( CUR.top < CUR.GS.loop )
-+    if ( CUR.top < CUR.GS.loop ||
-+         BOUNDS(CUR.GS.rp1, CUR.zp0.n_points) ||
-+         BOUNDS(CUR.GS.rp2, CUR.zp1.n_points))
-     {
-       CUR.error = TT_Err_Invalid_Reference;
-       return;
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9726.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9726.patch
deleted file mode 100644
index 3e6c656..0000000
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9726.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 7755e67116e8973ee0e3b22d653df026a84fa01b Mon Sep 17 00:00:00 2001
-From: Chris Liddell <chris.liddell@artifex.com>
-Date: Thu, 15 Jun 2017 08:58:31 +0100
-Subject: [PATCH] Bug 698055: bounds check zone pointer in Ins_MDRP
-
----
- base/ttinterp.c |    3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
---- end of original header
-
-CVE: CVE-2017-9726
-
-Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
-
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
-diff --git a/base/ttinterp.c b/base/ttinterp.c
-index e7c9d68..af457e8 100644
---- a/base/ttinterp.c
-+++ b/base/ttinterp.c
-@@ -3770,7 +3770,8 @@ static int nInstrCount=0;
- 
-     point = (Int)args[0];
- 
--    if ( BOUNDS( args[0], CUR.zp1.n_points ) )
-+    if ( BOUNDS( args[0], CUR.zp1.n_points ) ||
-+         BOUNDS( CUR.GS.rp0, CUR.zp0.n_points) )
-     {
-         /* Current version of FreeType silently ignores this out of bounds error
-          * and drops the instruction, see bug #691121
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9727.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9727.patch
deleted file mode 100644
index a2f7bfa..0000000
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9727.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From 937ccd17ac65935633b2ebc06cb7089b91e17e6b Mon Sep 17 00:00:00 2001
-From: Chris Liddell <chris.liddell@artifex.com>
-Date: Thu, 15 Jun 2017 09:05:20 +0100
-Subject: [PATCH] Bug 698056: make bounds check in gx_ttfReader__Read more
- robust
-
----
- base/gxttfb.c |    3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
---- end of original header
-
-CVE: CVE-2017-9727
-
-Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
-
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
-
-diff --git a/base/gxttfb.c b/base/gxttfb.c
-index 0e9a444..e1561af 100644
---- a/base/gxttfb.c
-+++ b/base/gxttfb.c
-@@ -79,7 +79,8 @@ static void gx_ttfReader__Read(ttfReader *self, void *p, int n)
-     if (!r->error) {
-         if (r->extra_glyph_index != -1) {
-             q = r->glyph_data.bits.data + r->pos;
--            r->error = (r->glyph_data.bits.size - r->pos < n ?
-+            r->error = ((r->pos >= r->glyph_data.bits.size ||
-+                        r->glyph_data.bits.size - r->pos < n) ?
-                             gs_note_error(gs_error_invalidfont) : 0);
-             if (r->error == 0)
-                 memcpy(p, q, n);
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9739.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9739.patch
deleted file mode 100644
index 69a94df..0000000
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9739.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From c501a58f8d5650c8ba21d447c0d6f07eafcb0f15 Mon Sep 17 00:00:00 2001
-From: Chris Liddell <chris.liddell@artifex.com>
-Date: Fri, 16 Jun 2017 08:29:25 +0100
-Subject: [PATCH] Bug 698063: Bounds check Ins_JMPR
-
----
- base/ttinterp.c |    6 ++++++
- 1 file changed, 6 insertions(+)
-
---- end of original header
-
-CVE: CVE-2017-9739
-
-Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
-
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
-
-diff --git a/base/ttinterp.c b/base/ttinterp.c
-index af457e8..adf3f0c 100644
---- a/base/ttinterp.c
-+++ b/base/ttinterp.c
-@@ -1794,6 +1794,12 @@ static int nInstrCount=0;
- 
-   static void  Ins_JMPR( INS_ARG )
-   {
-+    if ( BOUNDS(CUR.IP + args[0], CUR.codeSize ) )
-+    {
-+      CUR.error = TT_Err_Invalid_Reference;
-+      return;
-+    }
-+
-     CUR.IP      += (Int)(args[0]);
-     CUR.step_ins = FALSE;
- 
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9835.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9835.patch
deleted file mode 100644
index 7c65690..0000000
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/CVE-2017-9835.patch
+++ /dev/null
@@ -1,125 +0,0 @@
-From cfde94be1d4286bc47633c6e6eaf4e659bd78066 Mon Sep 17 00:00:00 2001
-From: Chris Liddell <chris.liddell@artifex.com>
-Date: Wed, 7 Jun 2017 14:55:12 +0100
-Subject: [PATCH] Bug 697985: bounds check the array allocations methods
-
-The clump allocator has four allocation functions that use 'number of elements'
-and 'size of elements' parameters (rather than a simple 'number of bytes').
-
-Those need specific bounds checking.
----
- base/gsalloc.c |   42 ++++++++++++++++++++++++++++--------------
- 1 file changed, 28 insertions(+), 14 deletions(-)
-
---- end of original header
-
-CVE: CVE-2017-9835
-
-Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
-
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
-
-diff --git a/base/gsalloc.c b/base/gsalloc.c
-index 741ba00..10c04dd 100644
---- a/base/gsalloc.c
-+++ b/base/gsalloc.c
-@@ -1248,19 +1248,32 @@ i_alloc_struct_immovable(gs_memory_t * mem, gs_memory_type_ptr_t pstype,
-     alloc_trace("|+<.", imem, cname, pstype, size, obj);
-     return obj;
- }
-+
-+static inline bool
-+alloc_array_check_size(ulong num_elements, ulong elt_size, ulong *lsize)
-+{
-+    int64_t s = (int64_t)num_elements * elt_size;
-+    if (s > max_uint) {
-+        return false;
-+    }
-+    *lsize = (ulong)s;
-+    return true;
-+}
-+
- static byte *
- i_alloc_byte_array(gs_memory_t * mem, uint num_elements, uint elt_size,
-                    client_name_t cname)
- {
-     gs_ref_memory_t * const imem = (gs_ref_memory_t *)mem;
-     obj_header_t *obj;
--
-+    ulong lsize;
- #ifdef MEMENTO
-     if (Memento_failThisEvent())
-         return NULL;
- #endif
--
--    obj = alloc_obj(imem, (ulong) num_elements * elt_size,
-+    if (alloc_array_check_size(num_elements, elt_size, &lsize) == false)
-+        return NULL;
-+    obj = alloc_obj(imem, lsize,
-                     &st_bytes, ALLOC_DIRECT, cname);
- 
-     if_debug6m('A', mem, "[a%d:+b.]%s -bytes-*(%lu=%u*%u) = 0x%lx\n",
-@@ -1275,13 +1288,14 @@ i_alloc_byte_array_immovable(gs_memory_t * mem, uint num_elements,
- {
-     gs_ref_memory_t * const imem = (gs_ref_memory_t *)mem;
-     obj_header_t *obj;
--
-+    ulong lsize;
- #ifdef MEMENTO
-     if (Memento_failThisEvent())
-         return NULL;
- #endif
--
--    obj = alloc_obj(imem, (ulong) num_elements * elt_size,
-+    if (alloc_array_check_size(num_elements, elt_size, &lsize) == false)
-+        return NULL;
-+    obj = alloc_obj(imem, lsize,
-                     &st_bytes, ALLOC_IMMOVABLE | ALLOC_DIRECT,
-                     cname);
- 
-@@ -1297,7 +1311,7 @@ i_alloc_struct_array(gs_memory_t * mem, uint num_elements,
- {
-     gs_ref_memory_t * const imem = (gs_ref_memory_t *)mem;
-     obj_header_t *obj;
--
-+    ulong lsize;
- #ifdef MEMENTO
-     if (Memento_failThisEvent())
-         return NULL;
-@@ -1311,9 +1325,9 @@ i_alloc_struct_array(gs_memory_t * mem, uint num_elements,
-         return NULL;		/* fail */
-     }
- #endif
--    obj = alloc_obj(imem,
--                    (ulong) num_elements * pstype->ssize,
--                    pstype, ALLOC_DIRECT, cname);
-+    if (alloc_array_check_size(num_elements, pstype->ssize, &lsize) == false)
-+        return NULL;
-+    obj = alloc_obj(imem, lsize, pstype, ALLOC_DIRECT, cname);
-     if_debug7m('A', mem, "[a%d:+<.]%s %s*(%lu=%u*%u) = 0x%lx\n",
-                alloc_trace_space(imem), client_name_string(cname),
-                struct_type_name_string(pstype),
-@@ -1327,16 +1341,16 @@ i_alloc_struct_array_immovable(gs_memory_t * mem, uint num_elements,
- {
-     gs_ref_memory_t * const imem = (gs_ref_memory_t *)mem;
-     obj_header_t *obj;
--
-+    ulong lsize;
- #ifdef MEMENTO
-     if (Memento_failThisEvent())
-         return NULL;
- #endif
- 
-     ALLOC_CHECK_SIZE(mem,pstype);
--    obj = alloc_obj(imem,
--                    (ulong) num_elements * pstype->ssize,
--                    pstype, ALLOC_IMMOVABLE | ALLOC_DIRECT, cname);
-+    if (alloc_array_check_size(num_elements, pstype->ssize, &lsize) == false)
-+        return NULL;
-+    obj = alloc_obj(imem, lsize, pstype, ALLOC_IMMOVABLE | ALLOC_DIRECT, cname);
-     if_debug7m('A', mem, "[a%d|+<.]%s %s*(%lu=%u*%u) = 0x%lx\n",
-                alloc_trace_space(imem), client_name_string(cname),
-                struct_type_name_string(pstype),
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/avoid-host-contamination.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/avoid-host-contamination.patch
index c4794e7..e8cb16c 100644
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/avoid-host-contamination.patch
+++ b/poky/meta/recipes-extended/ghostscript/ghostscript/avoid-host-contamination.patch
@@ -1,14 +1,25 @@
+From 0ccbaa134093bf6afc79f2d20d061bca5a8754ed Mon Sep 17 00:00:00 2001
+From: Kai Kang <kai.kang@windriver.com>
+Date: Thu, 29 Mar 2018 16:02:05 +0800
+Subject: [PATCH 04/10] avoid host contamination
+
 Remove hardcode path refer to host to avoid host contamination.
 
 Upstream-Status: Inappropriate [embedded specific]
 
 Signed-off-by: Kai Kang <kai.kang@windriver.com>
+
+Rebase to 9.23
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
+ devices/devs.mak | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
 diff --git a/devices/devs.mak b/devices/devs.mak
-index 3070d2e..df663f0 100644
+index 846aa50..9570182 100644
 --- a/devices/devs.mak
 +++ b/devices/devs.mak
-@@ -546,7 +546,7 @@ $(DEVOBJ)gdevxalt.$(OBJ) : $(DEVSRC)gdevxalt.c $(GDEVX) $(math__h) $(memory__h)\
+@@ -393,7 +393,7 @@ $(DEVOBJ)gdevxalt.$(OBJ) : $(DEVSRC)gdevxalt.c $(GDEVX) $(math__h) $(memory__h)\
  ### NON PORTABLE, ONLY UNIX WITH GCC SUPPORT
  
  $(DEVOBJ)X11.so : $(x11alt_) $(x11_) $(DEVS_MAK) $(MAKEDIRS)
@@ -17,3 +28,6 @@
  
  ###### --------------- Memory-buffered printer devices --------------- ######
  
+-- 
+1.8.3.1
+
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/base-genht.c-add-a-preprocessor-define-to-allow-fope.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/base-genht.c-add-a-preprocessor-define-to-allow-fope.patch
index d97d4ec..7d80066 100644
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/base-genht.c-add-a-preprocessor-define-to-allow-fope.patch
+++ b/poky/meta/recipes-extended/ghostscript/ghostscript/base-genht.c-add-a-preprocessor-define-to-allow-fope.patch
@@ -1,4 +1,8 @@
-base/genht.c: add a preprocessor define to allow fopen calling
+From 9ca6f795409b988d38dd98bc2a6ecb68a9392312 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 29 Mar 2018 16:37:40 +0800
+Subject: [PATCH 10/10] base/genht.c: add a preprocessor define to allow fopen
+ calling
 
 The commit in upstream:
 http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=773c69e46e70bdd5482676437dafd2ca83397643
@@ -7,17 +11,19 @@
 that any unintential calls directly to fopen will cause an error.
 
 Only exceptions are those in the platform specific code, and mkromfs.c.
-This patch add a preprocessor define to allow fopen calling in base/genht.c.
+This patch add a preprocessor define to allow fopen calling in
+base/genht.c.
 
 Upstream-Status: Pending
 
+Rebase to 9.23
 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
  base/genht.c | 4 ++++
  1 file changed, 4 insertions(+)
 
 diff --git a/base/genht.c b/base/genht.c
-index 4b04085..cc82fff 100644
+index e597e72..e96bfb5 100644
 --- a/base/genht.c
 +++ b/base/genht.c
 @@ -16,6 +16,10 @@
@@ -32,5 +38,5 @@
  #include "string_.h"
  #include "gscdefs.h"
 -- 
-1.8.1.2
+1.8.3.1
 
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/cups-no-gcrypt.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/cups-no-gcrypt.patch
index a1c9368..4c9bb22 100644
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/cups-no-gcrypt.patch
+++ b/poky/meta/recipes-extended/ghostscript/ghostscript/cups-no-gcrypt.patch
@@ -1,6 +1,12 @@
-Subject: [PATCH] Don't build-depend on libgcrypt, as nothing is used from it
+From 9129eb7fa9dc160d64a7d9df9279a3b1dae4d793 Mon Sep 17 00:00:00 2001
+From: Jackie Huang <jackie.huang@windriver.com>
+Date: Thu, 29 Mar 2018 16:16:18 +0800
+Subject: [PATCH 08/10] cups no gcrypt
 
-Backported from http://www.cups.org/strfiles.php/3308/cups-no-gcrypt.patch
+Don't build-depend on libgcrypt, as nothing is used from it
+
+Backported from
+http://www.cups.org/strfiles.php/3308/cups-no-gcrypt.patch
 
 This addresses the cryto dependency seen during build.
 
@@ -8,7 +14,7 @@
 
 Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
 
-Rebase the patch to ghostscript-9.15
+Rebase to 9.23
 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
  cups/libs/cups/http-private.h | 1 -
@@ -27,5 +33,5 @@
  #    include <CoreFoundation/CoreFoundation.h>
  #    include <Security/Security.h>
 -- 
-1.9.1
+1.8.3.1
 
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.02-genarch.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.02-genarch.patch
index b4c14ea..fc144f6 100644
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.02-genarch.patch
+++ b/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.02-genarch.patch
@@ -1,22 +1,28 @@
-Import patch from windriver linux for cross compilation, and split patches
-into oe way under different directories such as i586, powerpc etc according 
-to Richard's opinion.
+From 94850954b88440df6c41d2dd133c422ffc84d9aa Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 29 Mar 2018 16:12:48 +0800
+Subject: [PATCH 07/10] not generate objarch.h at compile time
+
+Import patch from windriver linux for cross compilation, and split
+patches into oe way under different directories such as i586, powerpc etc
+according to Richard's opinion.
 
 Upstream-Status: Pending
 
 Signed-off-by: Kang Kai <kai.kang@windriver.com>
 Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
 
-# Author: Chi Xu <chi.xu@windriver.com>
-# Date: Feb 26 2010
-# Summary: Generate arch.h for ppc32
-#
+Rebase to 9.23
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ base/lib.mak | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
 
-Index: ghostscript-9.21/base/lib.mak
-===================================================================
---- ghostscript-9.21.orig/base/lib.mak
-+++ ghostscript-9.21/base/lib.mak
-@@ -73,8 +73,8 @@ arch_h=$(GLGEN)arch.h
+diff --git a/base/lib.mak b/base/lib.mak
+index 0036d1e..302877e 100644
+--- a/base/lib.mak
++++ b/base/lib.mak
+@@ -87,8 +87,8 @@ arch_h=$(GLGEN)arch.h
  stdpre_h=$(GLSRC)stdpre.h
  stdint__h=$(GLSRC)stdint_.h $(std_h)
  
@@ -27,3 +33,6 @@
  
  # Platform interfaces
  
+-- 
+1.8.3.1
+
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.15-parallel-make.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.15-parallel-make.patch
index 3ec3956..ffa269e 100644
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.15-parallel-make.patch
+++ b/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.15-parallel-make.patch
@@ -1,25 +1,23 @@
-From 14937d9247330065359ca0fb648c28dfa5c3b224 Mon Sep 17 00:00:00 2001
-From: Huang Qiyu <huangqy.fnst@cn.fujitsu.com>
-Date: Tue, 13 Dec 2016 18:16:41 +0900
-Subject: [PATCH] ghostscript-9.15-parallel-make
+From 84bb692d6b047c09266de154f404af9817fa04aa Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Thu, 29 Mar 2018 15:59:05 +0800
+Subject: [PATCH 01/10] contrib.mak: fix for parallel build
 
-From 767bdf8a412b0cce2b734998e9b7e55abeaf932c Mon Sep 17 00:00:00 2001
-From: Huang Qiyu <huangqy.fnst@cn.fujitsu.com>
-Date: Tue, 13 Dec 2016 17:55:54 +0900
-Subject: [PATCH] Robert Yang <liezhi.yang@windriver.com> Date: Fri, 30 Jan
-2015 00:40:22 -0800  Subject: [PATCH] contrib.mak: fix for parallel build
-
-Signed-off-by: Huang Qiyu <huangqy.fnst@cn.fujitsu.com>
 Upstream-Status: Pending
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+
+Rebase to 9.23
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
  contrib/contrib.mak | 2 ++
  1 file changed, 2 insertions(+)
 
 diff --git a/contrib/contrib.mak b/contrib/contrib.mak
-index 55415b3..0b6b5ae 100644
+index f5a2fa4..4999752 100644
 --- a/contrib/contrib.mak
 +++ b/contrib/contrib.mak
-@@ -1099,6 +1099,7 @@ $(DEVOBJ)dviprlib.$(OBJ) : $(JAPSRC)dviprlib.c $(JAPSRC)dviprlib.h \
+@@ -1067,6 +1067,7 @@ $(DEVOBJ)dviprlib.$(OBJ) : $(JAPSRC)dviprlib.c $(JAPSRC)dviprlib.h \
  	$(DEVCC) $(O_)$@ $(C_) $(JAPSRC)dviprlib.c
  
  extra-dmprt-install: install-libdata
@@ -27,7 +25,7 @@
  	$(INSTALL_DATA) $(JAPSRC)dmp_init.ps $(DESTDIR)$(gsdatadir)$(D)lib || exit 1
  	$(INSTALL_DATA) $(JAPSRC)dmp_site.ps $(DESTDIR)$(gsdatadir)$(D)lib || exit 1
  	$(INSTALL_DATA) $(JAPSRC)escp_24.src $(DESTDIR)$(gsdatadir)$(D)lib || exit 1
-@@ -1267,6 +1268,7 @@ $(DEVOBJ)gdevalps.$(OBJ) : $(JAPSRC)gdevalps.c $(PDEVH) \
+@@ -1235,6 +1236,7 @@ $(DEVOBJ)gdevalps.$(OBJ) : $(JAPSRC)gdevalps.c $(PDEVH) \
  ### ----------------- Additional .upp files ---------------- ###
  
  extra-upp-install: install-libdata
@@ -36,5 +34,5 @@
  	    $(INSTALL_DATA) $$f $(DESTDIR)$(gsdatadir)$(D)lib || exit 1; \
  	done
 -- 
-2.7.4
+1.8.3.1
 
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.16-Werror-return-type.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.16-Werror-return-type.patch
index d786482..8c4a5d4 100644
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.16-Werror-return-type.patch
+++ b/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.16-Werror-return-type.patch
@@ -1,7 +1,7 @@
-From 5d5c83c89be0cff29dde2267fa168e6f7146be8c Mon Sep 17 00:00:00 2001
+From c481b055cd464734a3c2d80719ead4c1c92a40c9 Mon Sep 17 00:00:00 2001
 From: Robert Yang <liezhi.yang@windriver.com>
 Date: Mon, 4 May 2015 22:31:48 -0700
-Subject: [PATCH] base/gendev.c: fix for -Werror=return-type
+Subject: [PATCH 02/10] base/gendev.c: fix for -Werror=return-type
 
 Fixed:
 base/gendev.c:80:1: error: return type defaults to 'int' [-Werror=return-type]
@@ -10,11 +10,11 @@
 
 Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
 ---
- base/gendev.c |    1 +
+ base/gendev.c | 1 +
  1 file changed, 1 insertion(+)
 
 diff --git a/base/gendev.c b/base/gendev.c
-index 68a745f..8058b5a 100644
+index 59d5999..7766b08 100644
 --- a/base/gendev.c
 +++ b/base/gendev.c
 @@ -77,6 +77,7 @@ static const char *indent_item = "";
@@ -26,5 +26,5 @@
  {
      config conf;
 -- 
-1.7.9.5
+1.8.3.1
 
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.21-native-fix-disable-system-libtiff.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.21-native-fix-disable-system-libtiff.patch
index bff3e61..a382c7f 100644
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.21-native-fix-disable-system-libtiff.patch
+++ b/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.21-native-fix-disable-system-libtiff.patch
@@ -1,31 +1,38 @@
-ghostscript-native:fix disable-system-libtiff
+From 0124b1c29b9cfe46d73ae82ce023dd7c5b055744 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 29 Mar 2018 16:36:12 +0800
+Subject: [PATCH 09/10] ghostscript-native:fix disable-system-libtiff
 
 Modify configure to add the check to make sure
 ghostscrip could work while system-libtiff is
 disabled.
 
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
-
-Updated to apply to ghostscript 9.21.
-
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
-
 Upstream-Status: Pending
 
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 
+Rebase to ghostscript 9.25.
 
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
+---
+ configure.ac | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/configure.ac b/configure.ac
+index 80a60b1..f3e9efb 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -1259,6 +1259,7 @@ case "x$with_system_libtiff" in
- esac
+@@ -1319,6 +1319,7 @@ AC_TRY_COMPILE([], [return 0;],
+ CFLAGS=$CGLAGS_STORE
  
  if test x"$SHARE_LIBTIFF" = x"0" ; then
 +    if test -e $LIBTIFFDIR/configure; then
        echo "Running libtiff configure script..."
        olddir=`pwd`
        if ! test -d "$LIBTIFFCONFDIR" ; then
-@@ -1272,6 +1273,10 @@ if test x"$SHARE_LIBTIFF" = x"0" ; then
-       cd "$olddir"
+@@ -1337,6 +1338,10 @@ if test x"$SHARE_LIBTIFF" = x"0" ; then
+ 
        echo
        echo "Continuing with Ghostscript configuration..."
 +    else
@@ -35,3 +42,6 @@
  fi
  
  AC_SUBST(SHARE_LIBTIFF)
+-- 
+1.8.3.1
+
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.21-prevent_recompiling.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.21-prevent_recompiling.patch
index f2c6d04..c76915f 100644
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.21-prevent_recompiling.patch
+++ b/poky/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.21-prevent_recompiling.patch
@@ -1,32 +1,41 @@
-Just use commands provided by ghostscript-native, preventing recompile them when
-compile ghostscript.
-Way to enable cross compile.
+From 239d681306a8d97ed10954788d32ba2f4b55f77c Mon Sep 17 00:00:00 2001
+From: Kang Kai <kai.kang@windriver.com>
+Date: Thu, 29 Mar 2018 16:10:16 +0800
+Subject: [PATCH 06/10] prevent recompiling
+
+Just use commands provided by ghostscript-native, preventing recompile
+them when compile ghostscript. Way to enable cross compile.
 
 Upstream-Status: Pending
 
 Signed-off-by: Kang Kai <kai.kang@windriver.com>
 Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
 
-Rebase to 9.19
+Rebase to 9.25
 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
+---
+ base/unix-aux.mak | 44 --------------------------------------------
+ 1 file changed, 44 deletions(-)
 
-Rebase to 9.21
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
-
+diff --git a/base/unix-aux.mak b/base/unix-aux.mak
+index 5bf72e9..9cb39d7 100644
 --- a/base/unix-aux.mak
 +++ b/base/unix-aux.mak
-@@ -66,45 +66,45 @@ $(GLOBJ)gp_sysv.$(OBJ): $(GLSRC)gp_sysv.
+@@ -54,50 +54,6 @@ $(AUX)gp_stdia.$(OBJ): $(GLSRC)gp_stdia.
+   $(stdio__h) $(time__h) $(unistd__h) $(gx_h) $(gp_h) $(UNIX_AUX_MAK) $(MAKEDIRS)
+ 	$(GLCCAUX) $(AUXO_)gp_stdia.$(OBJ) $(C_) $(GLSRC)gp_stdia.c
  
- # -------------------------- Auxiliary programs --------------------------- #
- 
+-# -------------------------- Auxiliary programs --------------------------- #
+-
 -$(ECHOGS_XE): $(GLSRC)echogs.c $(AK) $(stdpre_h) $(UNIX_AUX_MAK) $(MAKEDIRS)
 -	$(CCAUX_) $(I_)$(GLSRCDIR)$(_I) $(O_)$(ECHOGS_XE) $(GLSRC)echogs.c $(AUXEXTRALIBS)
 -
-+#$(ECHOGS_XE): $(GLSRC)echogs.c $(AK) $(stdpre_h) $(UNIX_AUX_MAK) $(MAKEDIRS)
-+#	$(CCAUX_) $(I_)$(GLSRCDIR)$(_I) $(O_)$(ECHOGS_XE) $(GLSRC)echogs.c $(AUXEXTRALIBS)
-+#
- # On the RS/6000 (at least), compiling genarch.c with gcc with -O
- # produces a buggy executable.
+-$(PACKPS_XE): $(GLSRC)pack_ps.c $(stdpre_h) $(UNIX_AUX_MAK) $(MAKEDIRS)
+-	$(CCAUX_) $(I_)$(GLSRCDIR)$(_I) $(O_)$(PACKPS_XE) $(GLSRC)pack_ps.c $(AUXEXTRALIBS)
+-
+-# On the RS/6000 (at least), compiling genarch.c with gcc with -O
+-# produces a buggy executable.
 -$(GENARCH_XE): $(GLSRC)genarch.c $(AK) $(GENARCH_DEPS) $(UNIX_AUX_MAK) $(MAKEDIRS)
 -	$(CCAUX_) $(I_)$(GLSRCDIR)$(_I) $(O_)$(GENARCH_XE) $(GLSRC)genarch.c $(AUXEXTRALIBS)
 -
@@ -39,21 +48,9 @@
 -$(GENHT_XE): $(GLSRC)genht.c $(AK) $(GENHT_DEPS) $(UNIX_AUX_MAK) $(MAKEDIRS)
 -	$(CCAUX_) $(GENHT_CFLAGS) $(O_)$(GENHT_XE) $(GLSRC)genht.c $(AUXEXTRALIBS)
 -
-+#$(GENARCH_XE): $(GLSRC)genarch.c $(AK) $(GENARCH_DEPS) $(UNIX_AUX_MAK) $(MAKEDIRS)
-+#	$(CCAUX_) $(I_)$(GLSRCDIR)$(_I) $(O_)$(GENARCH_XE) $(GLSRC)genarch.c $(AUXEXTRALIBS)
-+#
-+#$(GENCONF_XE): $(GLSRC)genconf.c $(AK) $(GENCONF_DEPS) $(UNIX_AUX_MAK) $(MAKEDIRS)
-+#	$(CCAUX_) $(I_)$(GLSRCDIR)$(_I) $(O_)$(GENCONF_XE) $(GLSRC)genconf.c $(AUXEXTRALIBS)
-+#
-+#$(GENDEV_XE): $(GLSRC)gendev.c $(AK) $(GENDEV_DEPS) $(UNIX_AUX_MAK) $(MAKEDIRS)
-+#	$(CCAUX_) $(I_)$(GLSRCDIR)$(_I) $(O_)$(GENDEV_XE) $(GLSRC)gendev.c $(AUXEXTRALIBS)
-+#
-+#$(GENHT_XE): $(GLSRC)genht.c $(AK) $(GENHT_DEPS) $(UNIX_AUX_MAK) $(MAKEDIRS)
-+#	$(CCAUX_) $(GENHT_CFLAGS) $(O_)$(GENHT_XE) $(GLSRC)genht.c $(AUXEXTRALIBS)
-+#
- # To get GS to use the system zlib, you remove/hide the gs/zlib directory
- # which means that the mkromfs build can't find the zlib source it needs.
- # So it's split into two targets, one using the zlib source directly.....
+-# To get GS to use the system zlib, you remove/hide the gs/zlib directory
+-# which means that the mkromfs build can't find the zlib source it needs.
+-# So it's split into two targets, one using the zlib source directly.....
 -MKROMFS_OBJS_0=$(MKROMFS_ZLIB_OBJS) $(AUX)gpmisc.$(OBJ) $(AUX)gp_getnv.$(OBJ) \
 - $(AUX)gscdefs.$(OBJ) $(AUX)gp_unix.$(OBJ) $(AUX)gp_unifs.$(OBJ) $(AUX)gp_unifn.$(OBJ) \
 - $(AUX)gp_stdia.$(OBJ) $(AUX)gsutil.$(OBJ) $(AUX)memento.$(OBJ)
@@ -61,14 +58,7 @@
 -$(MKROMFS_XE)_0: $(GLSRC)mkromfs.c $(MKROMFS_COMMON_DEPS) $(MKROMFS_OBJS_0) $(UNIX_AUX_MAK) $(MAKEDIRS)
 -	$(CCAUX_) $(GENOPTAUX) $(I_)$(GLSRCDIR)$(_I) $(I_)$(GLOBJ)$(_I) $(I_)$(ZSRCDIR)$(_I) $(GLSRC)mkromfs.c $(O_)$(MKROMFS_XE)_0 $(MKROMFS_OBJS_0) $(AUXEXTRALIBS)
 -
-+#MKROMFS_OBJS_0=$(MKROMFS_ZLIB_OBJS) $(AUX)gpmisc.$(OBJ) $(AUX)gp_getnv.$(OBJ) \
-+# $(AUX)gscdefs.$(OBJ) $(AUX)gp_unix.$(OBJ) $(AUX)gp_unifs.$(OBJ) $(AUX)gp_unifn.$(OBJ) \
-+# $(AUX)gp_stdia.$(OBJ) $(AUX)gsutil.$(OBJ) $(AUX)memento.$(OBJ)
-+#
-+#$(MKROMFS_XE)_0: $(GLSRC)mkromfs.c $(MKROMFS_COMMON_DEPS) $(MKROMFS_OBJS_0) $(UNIX_AUX_MAK) $(MAKEDIRS)
-+#	$(CCAUX_) $(GENOPTAUX) $(I_)$(GLSRCDIR)$(_I) $(I_)$(GLOBJ)$(_I) $(I_)$(ZSRCDIR)$(_I) $(GLSRC)mkromfs.c $(O_)$(MKROMFS_XE)_0 $(MKROMFS_OBJS_0) $(AUXEXTRALIBS)
-+#
- # .... and one using the zlib library linked via the command line
+-# .... and one using the zlib library linked via the command line
 -MKROMFS_OBJS_1=$(AUX)gscdefs.$(OBJ) \
 - $(AUX)gpmisc.$(OBJ) $(AUX)gp_getnv.$(OBJ) \
 - $(AUX)gp_unix.$(OBJ) $(AUX)gp_unifs.$(OBJ) $(AUX)gp_unifn.$(OBJ) \
@@ -80,17 +70,9 @@
 -$(MKROMFS_XE): $(MKROMFS_XE)_$(SHARE_ZLIB) $(UNIX_AUX_MAK) $(MAKEDIRS)
 -	$(CP_) $(MKROMFS_XE)_$(SHARE_ZLIB) $(MKROMFS_XE)
 -
-+#MKROMFS_OBJS_1=$(AUX)gscdefs.$(OBJ) \
-+# $(AUX)gpmisc.$(OBJ) $(AUX)gp_getnv.$(OBJ) \
-+# $(AUX)gp_unix.$(OBJ) $(AUX)gp_unifs.$(OBJ) $(AUX)gp_unifn.$(OBJ) \
-+# $(AUX)gp_stdia.$(OBJ) $(AUX)gsutil.$(OBJ)
-+#
-+#$(MKROMFS_XE)_1: $(GLSRC)mkromfs.c $(MKROMFS_COMMON_DEPS) $(MKROMFS_OBJS_1) $(UNIX_AUX_MAK) $(MAKEDIRS)
-+#	$(CCAUX_) $(GENOPTAUX) $(I_)$(GLSRCDIR)$(_I) $(I_)$(GLOBJ)$(_I) $(I_)$(ZSRCDIR)$(_I) $(GLSRC)mkromfs.c $(O_)$(MKROMFS_XE)_1 $(MKROMFS_OBJS_1) $(AUXEXTRALIBS)
-+#
-+#$(MKROMFS_XE): $(MKROMFS_XE)_$(SHARE_ZLIB) $(UNIX_AUX_MAK) $(MAKEDIRS)
-+#	$(CP_) $(MKROMFS_XE)_$(SHARE_ZLIB) $(MKROMFS_XE)
-+#
  # Query the environment to construct gconfig_.h.
  # These are all defined conditionally (except the JasPER one), so that
  # they can be overridden by settings from the configure script.
+-- 
+1.8.3.1
+
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript/mkdir-p.patch b/poky/meta/recipes-extended/ghostscript/ghostscript/mkdir-p.patch
index 5a7eab1..3e6d3e3 100644
--- a/poky/meta/recipes-extended/ghostscript/ghostscript/mkdir-p.patch
+++ b/poky/meta/recipes-extended/ghostscript/ghostscript/mkdir-p.patch
@@ -1,4 +1,8 @@
-ghostscript: allow directories to be created more than once
+From 2b23026f8e2a352417fb1c4da94bf69b19bef267 Mon Sep 17 00:00:00 2001
+From: Joe Slater <joe.slater@windriver.com>
+Date: Thu, 29 Mar 2018 16:04:32 +0800
+Subject: [PATCH 05/10] ghostscript: allow directories to be created more than
+ once
 
 When doing parallel builds, we might try to create directories
 more than once.  This should not cause an error.
@@ -7,7 +11,14 @@
 
 Signed-off-by: Joe Slater <joe.slater@windriver.com>
 
+Rebase to 9.23
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ base/unix-end.mak | 17 ++++++++---------
+ 1 file changed, 8 insertions(+), 9 deletions(-)
 
+diff --git a/base/unix-end.mak b/base/unix-end.mak
+index 9ce599a..feff5a6 100644
 --- a/base/unix-end.mak
 +++ b/base/unix-end.mak
 @@ -17,15 +17,14 @@
@@ -34,3 +45,6 @@
  
  
  gs: .gssubtarget $(UNIX_END_MAK)
+-- 
+1.8.3.1
+
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript_9.21.bb b/poky/meta/recipes-extended/ghostscript/ghostscript_9.21.bb
deleted file mode 100644
index 50ec7e2..0000000
--- a/poky/meta/recipes-extended/ghostscript/ghostscript_9.21.bb
+++ /dev/null
@@ -1,136 +0,0 @@
-SUMMARY = "The GPL Ghostscript PostScript/PDF interpreter"
-DESCRIPTION = "Ghostscript is used for PostScript/PDF preview and printing.  Usually as \
-a back-end to a program such as ghostview, it can display PostScript and PDF \
-documents in an X11 environment. \
-\
-Furthermore, it can render PostScript and PDF files as graphics to be printed \
-on non-PostScript printers. Supported printers include common \
-dot-matrix, inkjet and laser models. \
-"
-HOMEPAGE = "http://www.ghostscript.com"
-SECTION = "console/utils"
-
-LICENSE = "GPLv3"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=70dc2bac4d0ce4448da873cd86b123fc"
-
-DEPENDS = "ghostscript-native tiff jpeg fontconfig cups libpng"
-DEPENDS_class-native = "libpng-native"
-
-UPSTREAM_CHECK_URI = "https://github.com/ArtifexSoftware/ghostpdl-downloads/releases"
-UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)\.tar"
-
-SRC_URI_BASE = "https://github.com/ArtifexSoftware/ghostpdl-downloads/releases/download/gs921/${BPN}-${PV}.tar.gz \
-                file://ghostscript-9.15-parallel-make.patch \
-                file://ghostscript-9.16-Werror-return-type.patch \
-                file://do-not-check-local-libpng-source.patch \
-                file://avoid-host-contamination.patch \
-                file://mkdir-p.patch \
-"
-
-SRC_URI = "${SRC_URI_BASE} \
-           file://ghostscript-9.21-prevent_recompiling.patch \
-           file://ghostscript-9.02-genarch.patch \
-           file://objarch.h \
-           file://cups-no-gcrypt.patch \
-           file://CVE-2017-7207.patch \
-           file://CVE-2017-5951.patch \
-           file://CVE-2017-7975.patch \
-           file://CVE-2017-9216.patch \
-           file://CVE-2017-9611.patch \
-           file://CVE-2017-9612.patch \
-           file://CVE-2017-9739.patch \
-           file://CVE-2017-9726.patch \
-           file://CVE-2017-9727.patch \
-           file://CVE-2017-9835.patch \
-           file://CVE-2017-11714.patch \
-           "
-
-SRC_URI_class-native = "${SRC_URI_BASE} \
-                        file://ghostscript-9.21-native-fix-disable-system-libtiff.patch \
-                        file://base-genht.c-add-a-preprocessor-define-to-allow-fope.patch \
-                        "
-
-SRC_URI[md5sum] = "5f213281761d2750fcf27476c404d17f"
-SRC_URI[sha256sum] = "02bceadbc4dddeb6f2eec9c8b1623d945d355ca11b8b4df035332b217d58ce85"
-
-# Put something like
-#
-#   PACKAGECONFIG_append_pn-ghostscript = " x11"
-#
-# in local.conf to enable building with X11.  Be careful.  The order
-# of the overrides matters!
-#
-#PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', '', d)}"
-PACKAGECONFIG_class-native = ""
-
-PACKAGECONFIG[x11] = "--with-x --x-includes=${STAGING_INCDIR} --x-libraries=${STAGING_LIBDIR}, \
-                      --without-x, virtual/libx11 libxext libxt gtk+3\
-                      "
-
-EXTRA_OECONF = "--with-system-libtiff --without-jbig2dec \
-                --with-fontpath=${datadir}/fonts \
-                --without-libidn --with-cups-serverbin=${exec_prefix}/lib/cups \
-                --with-cups-datadir=${datadir}/cups \
-                CUPSCONFIG="${STAGING_BINDIR_CROSS}/cups-config" \
-                "
-
-EXTRA_OECONF_append_mipsarcho32 = " --with-large_color_index=0"
-
-# Explicity disable libtiff, fontconfig,
-# freetype, cups for ghostscript-native
-EXTRA_OECONF_class-native = "--without-x --with-system-libtiff=no \
-                             --without-jbig2dec \
-                             --with-fontpath=${datadir}/fonts \
-                             --without-libidn --disable-fontconfig \
-                             --disable-freetype --disable-cups"
-
-# This has been fixed upstream but for now we need to subvert the check for time.h
-# http://bugs.ghostscript.com/show_bug.cgi?id=692443
-# http://bugs.ghostscript.com/show_bug.cgi?id=692426
-CFLAGS += "-DHAVE_SYS_TIME_H=1"
-BUILD_CFLAGS += "-DHAVE_SYS_TIME_H=1"
-
-inherit autotools
-
-do_configure_prepend () {
-	mkdir -p obj
-	mkdir -p soobj
-	if [ -e ${WORKDIR}/objarch.h ]; then
-		cp ${WORKDIR}/objarch.h obj/arch.h
-	fi
-}
-
-do_configure_append () {
-	# copy tools from the native ghostscript build
-	if [ "${PN}" != "ghostscript-native" ]; then
-		mkdir -p obj/aux soobj
-		for i in genarch genconf mkromfs echogs gendev genht; do
-			cp ${STAGING_BINDIR_NATIVE}/ghostscript-${PV}/$i obj/aux/$i
-		done
-	fi
-}
-
-do_install_append () {
-    mkdir -p ${D}${datadir}/ghostscript/${PV}/
-    cp -r ${S}/Resource ${D}${datadir}/ghostscript/${PV}/
-    cp -r ${S}/iccprofiles ${D}${datadir}/ghostscript/${PV}/
-}
-
-do_compile_class-native () {
-    mkdir -p obj
-    for i in genarch genconf mkromfs echogs gendev genht; do
-        oe_runmake obj/aux/$i
-    done
-}
-
-do_install_class-native () {
-    install -d ${D}${bindir}/ghostscript-${PV}
-    for i in genarch genconf mkromfs echogs gendev genht; do
-        install -m 755 obj/aux/$i ${D}${bindir}/ghostscript-${PV}/$i
-    done
-}
-
-BBCLASSEXTEND = "native"
-
-# ghostscript does not supports "arc"
-COMPATIBLE_HOST = "^(?!arc).*"
diff --git a/poky/meta/recipes-extended/ghostscript/ghostscript_9.25.bb b/poky/meta/recipes-extended/ghostscript/ghostscript_9.25.bb
new file mode 100644
index 0000000..fdca8a2
--- /dev/null
+++ b/poky/meta/recipes-extended/ghostscript/ghostscript_9.25.bb
@@ -0,0 +1,133 @@
+SUMMARY = "The GPL Ghostscript PostScript/PDF interpreter"
+DESCRIPTION = "Ghostscript is used for PostScript/PDF preview and printing.  Usually as \
+a back-end to a program such as ghostview, it can display PostScript and PDF \
+documents in an X11 environment. \
+\
+Furthermore, it can render PostScript and PDF files as graphics to be printed \
+on non-PostScript printers. Supported printers include common \
+dot-matrix, inkjet and laser models. \
+"
+HOMEPAGE = "http://www.ghostscript.com"
+SECTION = "console/utils"
+
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=70dc2bac4d0ce4448da873cd86b123fc"
+
+DEPENDS = "ghostscript-native tiff jpeg fontconfig cups libpng"
+DEPENDS_class-native = "libpng-native"
+
+UPSTREAM_CHECK_URI = "https://github.com/ArtifexSoftware/ghostpdl-downloads/releases"
+UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)\.tar"
+
+SRC_URI_BASE = "https://github.com/ArtifexSoftware/ghostpdl-downloads/releases/download/gs925/${BPN}-${PV}.tar.gz \
+                file://ghostscript-9.15-parallel-make.patch \
+                file://ghostscript-9.16-Werror-return-type.patch \
+                file://do-not-check-local-libpng-source.patch \
+                file://avoid-host-contamination.patch \
+                file://mkdir-p.patch \
+                file://0001-Bug-699795-add-operand-checking-to-.setnativefontmap.patch \
+                file://0002-Bug-699816-Improve-hiding-of-security-critical-custo.patch \
+                file://0003-Bug-699832-add-control-over-hiding-error-handlers.patch \
+                file://0004-For-hidden-operators-pass-a-name-object-to-error-han.patch \
+                file://0005-Bug-699938-.loadfontloop-must-be-an-operator.patch \
+                file://0006-Undefine-some-additional-internal-operators.patch \
+                file://0007-Bug-699927-don-t-include-operator-arrays-in-execstac.patch \
+                file://0008-Make-.forceput-unavailable-from-.policyprocs-helper-.patch \
+"
+
+SRC_URI = "${SRC_URI_BASE} \
+           file://ghostscript-9.21-prevent_recompiling.patch \
+           file://ghostscript-9.02-genarch.patch \
+           file://objarch.h \
+           file://cups-no-gcrypt.patch \
+           "
+
+SRC_URI_class-native = "${SRC_URI_BASE} \
+                        file://ghostscript-9.21-native-fix-disable-system-libtiff.patch \
+                        file://base-genht.c-add-a-preprocessor-define-to-allow-fope.patch \
+                        "
+
+SRC_URI[md5sum] = "eebd0fadbfa8e800094422ce65e94d5d"
+SRC_URI[sha256sum] = "baafa64740b090bff50b220a6df3be95c46069b7e30f4b4effed28316e5b2389"
+
+# Put something like
+#
+#   PACKAGECONFIG_append_pn-ghostscript = " x11"
+#
+# in local.conf to enable building with X11.  Be careful.  The order
+# of the overrides matters!
+#
+#PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', '', d)}"
+PACKAGECONFIG_class-native = ""
+
+PACKAGECONFIG[x11] = "--with-x --x-includes=${STAGING_INCDIR} --x-libraries=${STAGING_LIBDIR}, \
+                      --without-x, virtual/libx11 libxext libxt gtk+3\
+                      "
+
+EXTRA_OECONF = "--with-system-libtiff --without-jbig2dec \
+                --with-fontpath=${datadir}/fonts \
+                --without-libidn --with-cups-serverbin=${exec_prefix}/lib/cups \
+                --with-cups-datadir=${datadir}/cups \
+                CUPSCONFIG="${STAGING_BINDIR_CROSS}/cups-config" \
+                "
+
+EXTRA_OECONF_append_mipsarcho32 = " --with-large_color_index=0"
+
+# Explicity disable libtiff, fontconfig,
+# freetype, cups for ghostscript-native
+EXTRA_OECONF_class-native = "--without-x --with-system-libtiff=no \
+                             --without-jbig2dec \
+                             --with-fontpath=${datadir}/fonts \
+                             --without-libidn --disable-fontconfig \
+                             --disable-freetype --disable-cups"
+
+# This has been fixed upstream but for now we need to subvert the check for time.h
+# http://bugs.ghostscript.com/show_bug.cgi?id=692443
+# http://bugs.ghostscript.com/show_bug.cgi?id=692426
+CFLAGS += "-DHAVE_SYS_TIME_H=1"
+BUILD_CFLAGS += "-DHAVE_SYS_TIME_H=1"
+
+inherit autotools
+
+do_configure_prepend () {
+	mkdir -p obj
+	mkdir -p soobj
+	if [ -e ${WORKDIR}/objarch.h ]; then
+		cp ${WORKDIR}/objarch.h obj/arch.h
+	fi
+}
+
+do_configure_append () {
+	# copy tools from the native ghostscript build
+	if [ "${PN}" != "ghostscript-native" ]; then
+		mkdir -p obj/aux soobj
+		for i in genarch genconf mkromfs echogs gendev genht packps; do
+			cp ${STAGING_BINDIR_NATIVE}/ghostscript-${PV}/$i obj/aux/$i
+		done
+	fi
+}
+
+do_install_append () {
+    mkdir -p ${D}${datadir}/ghostscript/${PV}/
+    cp -r ${S}/Resource ${D}${datadir}/ghostscript/${PV}/
+    cp -r ${S}/iccprofiles ${D}${datadir}/ghostscript/${PV}/
+}
+
+do_compile_class-native () {
+    mkdir -p obj
+    for i in genarch genconf mkromfs echogs gendev genht packps; do
+        oe_runmake obj/aux/$i
+    done
+}
+
+do_install_class-native () {
+    install -d ${D}${bindir}/ghostscript-${PV}
+    for i in genarch genconf mkromfs echogs gendev genht packps; do
+        install -m 755 obj/aux/$i ${D}${bindir}/ghostscript-${PV}/$i
+    done
+}
+
+BBCLASSEXTEND = "native"
+
+# ghostscript does not supports "arc"
+COMPATIBLE_HOST = "^(?!arc).*"
diff --git a/poky/meta/recipes-extended/groff/groff-1.22.3/groff-not-search-fonts-on-build-host.patch b/poky/meta/recipes-extended/groff/groff-1.22.3/groff-not-search-fonts-on-build-host.patch
new file mode 100644
index 0000000..ff8f320
--- /dev/null
+++ b/poky/meta/recipes-extended/groff/groff-1.22.3/groff-not-search-fonts-on-build-host.patch
@@ -0,0 +1,20 @@
+groff searchs fonts which are provided by ghostscript on build host.
+It causes non-determinism issue. So not search font dirs on host.
+
+Upstream-Status: Inappropriate [cross build specific]
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+
+diff --git a/font/devpdf/Foundry.in b/font/devpdf/Foundry.in
+index a6e968f..8094642 100644
+--- a/font/devpdf/Foundry.in
++++ b/font/devpdf/Foundry.in
+@@ -65,7 +65,7 @@ ZD|Y||||Dingbats!d050000l.pfb
+ #======================================================================
+ 
+ #Foundry|Name|Searchpath
+-foundry|U|(gs):/usr/share/fonts/type1/gsfonts :/opt/local/share/fonts/urw-fonts # the URW fonts delivered with ghostscript (may be different)
++foundry|U|(gs) # the URW fonts delivered with ghostscript (may be different)
+ #Define Flags for afmtodit
+ 
+ r=-i 0 -m
diff --git a/poky/meta/recipes-extended/groff/groff_1.22.3.bb b/poky/meta/recipes-extended/groff/groff_1.22.3.bb
index 7472f59..ba90cad 100644
--- a/poky/meta/recipes-extended/groff/groff_1.22.3.bb
+++ b/poky/meta/recipes-extended/groff/groff_1.22.3.bb
@@ -11,6 +11,7 @@
 	file://groff-1.22.2-correct-man.local-install-path.patch \
 	file://0001-Unset-need_charset_alias-when-building-for-musl.patch \
 	file://0001-replace-perl-w-with-use-warnings.patch \
+	file://groff-not-search-fonts-on-build-host.patch \
 "
 
 SRC_URI[md5sum] = "cc825fa64bc7306a885f2fb2268d3ec5"
@@ -20,7 +21,9 @@
 DEPENDS_class-native = ""
 RDEPENDS_${PN} += "perl sed"
 
-inherit autotools texinfo
+inherit autotools texinfo multilib_script
+
+MULTILIB_SCRIPTS = "${PN}:${bindir}/gpinyin ${PN}:${bindir}/groffer ${PN}:${bindir}/grog"
 
 EXTRA_OECONF = "--without-x"
 PARALLEL_MAKE = ""
diff --git a/poky/meta/recipes-extended/gzip/gzip-1.9/gnulib.patch b/poky/meta/recipes-extended/gzip/gzip-1.9/gnulib.patch
new file mode 100644
index 0000000..c3cdd72
--- /dev/null
+++ b/poky/meta/recipes-extended/gzip/gzip-1.9/gnulib.patch
@@ -0,0 +1,189 @@
+From 1831628c0630ae96a43586b2a25ca51cbdba3e53 Mon Sep 17 00:00:00 2001
+From: Paul Eggert <address@hidden>
+Date: Mon, 5 Mar 2018 10:56:29 -0800
+Subject: [PATCH] fflush: adjust to glibc 2.28 libio.h removal
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Problem reported by Daniel P. Berrangé in:
+https://lists.gnu.org/r/bug-gnulib/2018-03/msg00000.html
+* lib/fbufmode.c (fbufmode):
+* lib/fflush.c (clear_ungetc_buffer_preserving_position)
+(disable_seek_optimization, rpl_fflush):
+* lib/fpending.c (__fpending):
+* lib/fpurge.c (fpurge):
+* lib/freadable.c (freadable):
+* lib/freadahead.c (freadahead):
+* lib/freading.c (freading):
+* lib/freadptr.c (freadptr):
+* lib/freadseek.c (freadptrinc):
+* lib/fseeko.c (fseeko):
+* lib/fseterr.c (fseterr):
+* lib/fwritable.c (fwritable):
+* lib/fwriting.c (fwriting):
+Check _IO_EOF_SEEN instead of _IO_ftrylockfile.
+* lib/stdio-impl.h (_IO_IN_BACKUP) [_IO_EOF_SEEN]:
+Define if not already defined.
+---
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+ ChangeLog        | 23 +++++++++++++++++++++++
+ lib/fbufmode.c   |  2 +-
+ lib/fflush.c     |  6 +++---
+ lib/fpending.c   |  2 +-
+ lib/fpurge.c     |  2 +-
+ lib/freadable.c  |  2 +-
+ lib/freadahead.c |  2 +-
+ lib/freading.c   |  2 +-
+ lib/freadptr.c   |  2 +-
+ lib/freadseek.c  |  2 +-
+ lib/fseeko.c     |  4 ++--
+ lib/fseterr.c    |  2 +-
+ lib/fwritable.c  |  2 +-
+ lib/fwriting.c   |  2 +-
+ lib/stdio-impl.h |  6 ++++++
+ 15 files changed, 45 insertions(+), 16 deletions(-)
+
+Index: gzip-1.9/ChangeLog
+===================================================================
+--- gzip-1.9.orig/ChangeLog
++++ gzip-1.9/ChangeLog
+@@ -1,3 +1,26 @@
++2018-03-05  Paul Eggert  <address@hidden>
++
++	fflush: adjust to glibc 2.28 libio.h removal
++	Problem reported by Daniel P. Berrangé in:
++	https://lists.gnu.org/r/bug-gnulib/2018-03/msg00000.html
++	* lib/fbufmode.c (fbufmode):
++	* lib/fflush.c (clear_ungetc_buffer_preserving_position)
++	(disable_seek_optimization, rpl_fflush):
++	* lib/fpending.c (__fpending):
++	* lib/fpurge.c (fpurge):
++	* lib/freadable.c (freadable):
++	* lib/freadahead.c (freadahead):
++	* lib/freading.c (freading):
++	* lib/freadptr.c (freadptr):
++	* lib/freadseek.c (freadptrinc):
++	* lib/fseeko.c (fseeko):
++	* lib/fseterr.c (fseterr):
++	* lib/fwritable.c (fwritable):
++	* lib/fwriting.c (fwriting):
++	Check _IO_EOF_SEEN instead of _IO_ftrylockfile.
++	* lib/stdio-impl.h (_IO_IN_BACKUP) [_IO_EOF_SEEN]:
++	Define if not already defined.
++
+ 2018-01-07  Jim Meyering  <meyering@fb.com>
+ 
+ 	version 1.9
+Index: gzip-1.9/lib/fflush.c
+===================================================================
+--- gzip-1.9.orig/lib/fflush.c
++++ gzip-1.9/lib/fflush.c
+@@ -33,7 +33,7 @@
+ #undef fflush
+ 
+ 
+-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
++#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+ 
+ /* Clear the stream's ungetc buffer, preserving the value of ftello (fp).  */
+ static void
+@@ -72,7 +72,7 @@ clear_ungetc_buffer (FILE *fp)
+ 
+ #endif
+ 
+-#if ! (defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */)
++#if ! (defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */)
+ 
+ # if (defined __sferror || defined __DragonFly__ || defined __ANDROID__) && defined __SNPT
+ /* FreeBSD, NetBSD, OpenBSD, DragonFly, Mac OS X, Cygwin, Minix 3, Android */
+@@ -148,7 +148,7 @@ rpl_fflush (FILE *stream)
+   if (stream == NULL || ! freading (stream))
+     return fflush (stream);
+ 
+-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
++#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+ 
+   clear_ungetc_buffer_preserving_position (stream);
+ 
+Index: gzip-1.9/lib/fpurge.c
+===================================================================
+--- gzip-1.9.orig/lib/fpurge.c
++++ gzip-1.9/lib/fpurge.c
+@@ -62,7 +62,7 @@ fpurge (FILE *fp)
+   /* Most systems provide FILE as a struct and the necessary bitmask in
+      <stdio.h>, because they need it for implementing getc() and putc() as
+      fast macros.  */
+-# if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
++# if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+   fp->_IO_read_end = fp->_IO_read_ptr;
+   fp->_IO_write_ptr = fp->_IO_write_base;
+   /* Avoid memory leak when there is an active ungetc buffer.  */
+Index: gzip-1.9/lib/freading.c
+===================================================================
+--- gzip-1.9.orig/lib/freading.c
++++ gzip-1.9/lib/freading.c
+@@ -31,7 +31,7 @@ freading (FILE *fp)
+   /* Most systems provide FILE as a struct and the necessary bitmask in
+      <stdio.h>, because they need it for implementing getc() and putc() as
+      fast macros.  */
+-# if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
++# if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+   return ((fp->_flags & _IO_NO_WRITES) != 0
+           || ((fp->_flags & (_IO_NO_READS | _IO_CURRENTLY_PUTTING)) == 0
+               && fp->_IO_read_base != NULL));
+Index: gzip-1.9/lib/fseeko.c
+===================================================================
+--- gzip-1.9.orig/lib/fseeko.c
++++ gzip-1.9/lib/fseeko.c
+@@ -47,7 +47,7 @@ fseeko (FILE *fp, off_t offset, int when
+ #endif
+ 
+   /* These tests are based on fpurge.c.  */
+-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
++#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+   if (fp->_IO_read_end == fp->_IO_read_ptr
+       && fp->_IO_write_ptr == fp->_IO_write_base
+       && fp->_IO_save_base == NULL)
+@@ -123,7 +123,7 @@ fseeko (FILE *fp, off_t offset, int when
+           return -1;
+         }
+ 
+-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
++#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+       fp->_flags &= ~_IO_EOF_SEEN;
+       fp->_offset = pos;
+ #elif defined __sferror || defined __DragonFly__ || defined __ANDROID__
+Index: gzip-1.9/lib/fseterr.c
+===================================================================
+--- gzip-1.9.orig/lib/fseterr.c
++++ gzip-1.9/lib/fseterr.c
+@@ -29,7 +29,7 @@ fseterr (FILE *fp)
+   /* Most systems provide FILE as a struct and the necessary bitmask in
+      <stdio.h>, because they need it for implementing getc() and putc() as
+      fast macros.  */
+-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
++#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+   fp->_flags |= _IO_ERR_SEEN;
+ #elif defined __sferror || defined __DragonFly__ || defined __ANDROID__
+   /* FreeBSD, NetBSD, OpenBSD, DragonFly, Mac OS X, Cygwin, Minix 3, Android */
+Index: gzip-1.9/lib/stdio-impl.h
+===================================================================
+--- gzip-1.9.orig/lib/stdio-impl.h
++++ gzip-1.9/lib/stdio-impl.h
+@@ -18,6 +18,12 @@
+    the same implementation of stdio extension API, except that some fields
+    have different naming conventions, or their access requires some casts.  */
+ 
++/* Glibc 2.28 made _IO_IN_BACKUP private.  For now, work around this
++   problem by defining it ourselves.  FIXME: Do not rely on glibc
++   internals.  */
++#if !defined _IO_IN_BACKUP && defined _IO_EOF_SEEN
++# define _IO_IN_BACKUP 0x100
++#endif
+ 
+ /* BSD stdio derived implementations.  */
+ 
diff --git a/poky/meta/recipes-extended/gzip/gzip_1.9.bb b/poky/meta/recipes-extended/gzip/gzip_1.9.bb
index a8eeba1..19f6586 100644
--- a/poky/meta/recipes-extended/gzip/gzip_1.9.bb
+++ b/poky/meta/recipes-extended/gzip/gzip_1.9.bb
@@ -3,7 +3,9 @@
 LICENSE = "GPLv3+"
 
 SRC_URI = "${GNU_MIRROR}/gzip/${BP}.tar.gz \
-            file://run-ptest"
+           file://run-ptest \
+           file://gnulib.patch \
+          "
 SRC_URI_append_class-target = " file://wrong-path-fix.patch"
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
diff --git a/poky/meta/recipes-extended/hdparm/hdparm_9.53.bb b/poky/meta/recipes-extended/hdparm/hdparm_9.53.bb
deleted file mode 100644
index 4c3ec5c4..0000000
--- a/poky/meta/recipes-extended/hdparm/hdparm_9.53.bb
+++ /dev/null
@@ -1,43 +0,0 @@
-SUMMARY = "Utility for viewing/manipulating IDE disk drive/driver parameters"
-HOMEPAGE = "http://sourceforge.net/projects/hdparm/"
-DESCRIPTION = "hdparm is a Linux shell utility for viewing \
-and manipulating various IDE drive and driver parameters."
-SECTION = "console/utils"
-
-LICENSE = "BSD & GPLv2"
-LICENSE_${PN} = "BSD"
-LICENSE_${PN}-dbg = "BSD"
-LICENSE_wiper = "GPLv2"
-
-LIC_FILES_CHKSUM = "file://LICENSE.TXT;md5=495d03e50dc6c89d6a30107ab0df5b03 \
-                    file://debian/copyright;md5=a82d7ba3ade9e8ec902749db98c592f3 \
-                    file://wiper/GPLv2.txt;md5=fcb02dc552a041dee27e4b85c7396067 \
-                    file://wiper/wiper.sh;beginline=7;endline=31;md5=b7bc642addc152ea307505bf1a296f09"
-
-
-PACKAGES =+ "wiper"
-
-FILES_wiper = "${bindir}/wiper.sh"
-
-RDEPENDS_wiper = "bash gawk coreutils"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/hdparm/${BP}.tar.gz \
-           file://wiper.sh-fix-stat-path.patch \
-          "
-
-SRC_URI[md5sum] = "1e54b52e0c8cb79389d4d47eacba411d"
-SRC_URI[sha256sum] = "2673f591df6916c6a1faec07069a7eb1cb8ee307615a615d808192fb0c0265e5"
-
-EXTRA_OEMAKE = 'STRIP="echo" LDFLAGS="${LDFLAGS}"'
-
-inherit update-alternatives
-
-ALTERNATIVE_${PN} = "hdparm"
-ALTERNATIVE_LINK_NAME[hdparm] = "${base_sbindir}/hdparm"
-ALTERNATIVE_PRIORITY = "100"
-
-do_install () {
-	install -d ${D}/${base_sbindir} ${D}/${mandir}/man8 ${D}/${bindir}
-	oe_runmake 'DESTDIR=${D}' 'sbindir=${base_sbindir}' install
-	cp ${S}/wiper/wiper.sh ${D}/${bindir}
-}
diff --git a/poky/meta/recipes-extended/hdparm/hdparm_9.56.bb b/poky/meta/recipes-extended/hdparm/hdparm_9.56.bb
new file mode 100644
index 0000000..17932ad
--- /dev/null
+++ b/poky/meta/recipes-extended/hdparm/hdparm_9.56.bb
@@ -0,0 +1,43 @@
+SUMMARY = "Utility for viewing/manipulating IDE disk drive/driver parameters"
+HOMEPAGE = "http://sourceforge.net/projects/hdparm/"
+DESCRIPTION = "hdparm is a Linux shell utility for viewing \
+and manipulating various IDE drive and driver parameters."
+SECTION = "console/utils"
+
+LICENSE = "BSD & GPLv2"
+LICENSE_${PN} = "BSD"
+LICENSE_${PN}-dbg = "BSD"
+LICENSE_wiper = "GPLv2"
+
+LIC_FILES_CHKSUM = "file://LICENSE.TXT;md5=495d03e50dc6c89d6a30107ab0df5b03 \
+                    file://debian/copyright;md5=a82d7ba3ade9e8ec902749db98c592f3 \
+                    file://wiper/GPLv2.txt;md5=fcb02dc552a041dee27e4b85c7396067 \
+                    file://wiper/wiper.sh;beginline=7;endline=31;md5=b7bc642addc152ea307505bf1a296f09"
+
+
+PACKAGES =+ "wiper"
+
+FILES_wiper = "${bindir}/wiper.sh"
+
+RDEPENDS_wiper = "bash gawk coreutils"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/hdparm/${BP}.tar.gz \
+           file://wiper.sh-fix-stat-path.patch \
+          "
+
+SRC_URI[md5sum] = "7900608e32834f65d2654fdb696e71a0"
+SRC_URI[sha256sum] = "6ff9ed695f1017396eec4101f990f114b7b0e0a04c5aa6369c0394053d16e4da"
+
+EXTRA_OEMAKE = 'STRIP="echo" LDFLAGS="${LDFLAGS}"'
+
+inherit update-alternatives
+
+ALTERNATIVE_${PN} = "hdparm"
+ALTERNATIVE_LINK_NAME[hdparm] = "${base_sbindir}/hdparm"
+ALTERNATIVE_PRIORITY = "100"
+
+do_install () {
+	install -d ${D}/${base_sbindir} ${D}/${mandir}/man8 ${D}/${bindir}
+	oe_runmake 'DESTDIR=${D}' 'sbindir=${base_sbindir}' install
+	cp ${S}/wiper/wiper.sh ${D}/${bindir}
+}
diff --git a/poky/meta/recipes-extended/iptables/iptables_1.6.2.bb b/poky/meta/recipes-extended/iptables/iptables_1.6.2.bb
index 38a83d2..e00824f 100644
--- a/poky/meta/recipes-extended/iptables/iptables_1.6.2.bb
+++ b/poky/meta/recipes-extended/iptables/iptables_1.6.2.bb
@@ -7,17 +7,6 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263\
                     file://iptables/iptables.c;beginline=13;endline=25;md5=c5cffd09974558cf27d0f763df2a12dc"
 
-RRECOMMENDS_${PN} = "kernel-module-x-tables \
-                     kernel-module-ip-tables \
-                     kernel-module-iptable-filter \
-                     kernel-module-iptable-nat \
-                     kernel-module-nf-defrag-ipv4 \
-                     kernel-module-nf-conntrack \
-                     kernel-module-nf-conntrack-ipv4 \
-                     kernel-module-nf-nat \
-                     kernel-module-ipt-masquerade"
-FILES_${PN} =+ "${libdir}/xtables/ ${datadir}/xtables"
-
 SRC_URI = "http://netfilter.org/projects/iptables/files/iptables-${PV}.tar.bz2 \
            file://0001-configure-Add-option-to-enable-disable-libnfnetlink.patch \
            file://0002-configure.ac-only-check-conntrack-when-libnfnetlink-enabled.patch \
@@ -28,8 +17,8 @@
 
 inherit autotools pkgconfig
 
-EXTRA_OECONF = "--with-kernel=${STAGING_INCDIR} \
-               "
+EXTRA_OECONF = "--with-kernel=${STAGING_INCDIR}"
+
 PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}"
 
 PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
@@ -45,3 +34,31 @@
 	# Keep ax_check_linker_flags.m4 which belongs to autoconf-archive.
 	rm -f libtool.m4 lt~obsolete.m4 ltoptions.m4 ltsugar.m4 ltversion.m4
 }
+
+PACKAGES += "${PN}-modules"
+PACKAGES_DYNAMIC += "^${PN}-module-.*"
+
+python populate_packages_prepend() {
+    modules = do_split_packages(d, '${libdir}/xtables', 'lib(.*)\.so$', '${PN}-module-%s', '${PN} module %s', extra_depends='')
+    if modules:
+        metapkg = d.getVar('PN') + '-modules'
+        d.appendVar('RDEPENDS_' + metapkg, ' ' + ' '.join(modules))
+}
+
+FILES_${PN} += "${datadir}/xtables"
+
+ALLOW_EMPTY_${PN}-modules = "1"
+
+RDEPENDS_${PN} = "${PN}-module-xt-standard"
+RRECOMMENDS_${PN} = " \
+    ${PN}-modules \
+    kernel-module-x-tables \
+    kernel-module-ip-tables \
+    kernel-module-iptable-filter \
+    kernel-module-iptable-nat \
+    kernel-module-nf-defrag-ipv4 \
+    kernel-module-nf-conntrack \
+    kernel-module-nf-conntrack-ipv4 \
+    kernel-module-nf-nat \
+    kernel-module-ipt-masquerade \
+"
diff --git a/poky/meta/recipes-extended/iputils/files/0001-Fix-build-on-MUSL.patch b/poky/meta/recipes-extended/iputils/files/0001-Fix-build-on-MUSL.patch
deleted file mode 100644
index ce8cfeb..0000000
--- a/poky/meta/recipes-extended/iputils/files/0001-Fix-build-on-MUSL.patch
+++ /dev/null
@@ -1,95 +0,0 @@
-From c6c5966d9fae27bc2f0a34ab59b999555111bd2d Mon Sep 17 00:00:00 2001
-From: Aric Belsito <lluixhi@gmail.com>
-Date: Sun, 29 Oct 2017 23:17:03 +0100
-Subject: [PATCH] Fix build on MUSL
-
-Add missing AI_IDN and NI_IDN declarations.
-
-Bug: https://bugs.gentoo.org/503914
-
-Upstream-Status: Pending
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
----
- arping.c      |  7 +++++++
- ping.h        | 11 +++++++++++
- tracepath.c   |  8 ++++++++
- traceroute6.c |  4 ++++
- 4 files changed, 30 insertions(+)
-
-diff --git a/arping.c b/arping.c
-index 1a3f40b..531d29d 100644
---- a/arping.c
-+++ b/arping.c
-@@ -45,6 +45,13 @@ struct sysfs_devattr_values;
- #ifdef USE_IDN
- #include <idna.h>
- #include <locale.h>
-+
-+#ifndef AI_IDN
-+#define AI_IDN 0x0040
-+#endif
-+#ifndef AI_CANONIDN
-+#define AI_CANONIDN 0x0080
-+#endif
- #endif
- 
- #include "SNAPSHOT.h"
-diff --git a/ping.h b/ping.h
-index 749f3ff..227315f 100644
---- a/ping.h
-+++ b/ping.h
-@@ -38,6 +38,17 @@
- #include <locale.h>
- #include <idna.h>
- #include <stringprep.h>
-+
-+#ifndef AI_IDN
-+#define AI_IDN 0x0040
-+#endif
-+#ifndef AI_CANONIDN
-+#define AI_CANONIDN 0x0080
-+#endif
-+#ifndef NI_IDN
-+#define NI_IDN 32
-+#endif
-+
- #define getaddrinfo_flags (AI_CANONNAME | AI_IDN | AI_CANONIDN)
- #define getnameinfo_flags NI_IDN
- #else
-diff --git a/tracepath.c b/tracepath.c
-index 74a829d..dcec5b9 100644
---- a/tracepath.c
-+++ b/tracepath.c
-@@ -30,6 +30,14 @@
- #ifdef USE_IDN
- #include <idna.h>
- #include <locale.h>
-+
-+#ifndef AI_IDN
-+#define AI_IDN 0x0040
-+#endif
-+#ifndef NI_IDN
-+#define NI_IDN 32
-+#endif
-+
- #define getnameinfo_flags	NI_IDN
- #else
- #define getnameinfo_flags	0
-diff --git a/traceroute6.c b/traceroute6.c
-index 48fc5c5..8d1eebf 100644
---- a/traceroute6.c
-+++ b/traceroute6.c
-@@ -251,6 +251,10 @@
- #include <idna.h>
- #include <locale.h>
- 
-+#ifndef NI_IDN
-+#define NI_IDN 32
-+#endif
-+
- #define getnameinfo_flags	NI_IDN
- #else
- #define getnameinfo_flags	0
--- 
-2.15.1
-
diff --git a/poky/meta/recipes-extended/iputils/iputils/ai_canonidn.patch b/poky/meta/recipes-extended/iputils/iputils/ai_canonidn.patch
new file mode 100644
index 0000000..cd91267
--- /dev/null
+++ b/poky/meta/recipes-extended/iputils/iputils/ai_canonidn.patch
@@ -0,0 +1,58 @@
+From 714e2b458c151c5bdfe93647445cd00dd8e36fff Mon Sep 17 00:00:00 2001
+From: Petr Vorel <petr.vorel@gmail.com>
+Date: Sat, 21 Jul 2018 17:46:14 +0200
+Subject: [PATCH] ping: Fix AI_CANONIDN usage on some systems
+
+Upstream-Status: Backport
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+Commit 99f67db used AI_CANONIDN in a way, which broke compilation on
+systems where AI_CANONIDN is not defined in netdb.h (e.g. glibc < 2.3.4,
+alternative libcs that don't support IDN: e.g. current musl 1.1.19 and
+uClibc-ng 1.0.30) when not using the system libidn2.
+
+Fixes: 99f67db ping: Fix ping name encoded using ACE on C locale
+
+Reported-by: Nicholas Fish
+Signed-off-by: Petr Vorel <petr.vorel@gmail.com>
+
+---
+ ping.c | 2 +-
+ ping.h | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/ping.c b/ping.c
+index 733477f..b241815 100644
+--- a/ping.c
++++ b/ping.c
+@@ -207,9 +207,9 @@ main(int argc, char **argv)
+ 
+ #ifdef USE_IDN
+ 	setlocale(LC_ALL, "");
+-#endif
+ 	if (!strcmp(setlocale(LC_ALL, NULL), "C"))
+ 		hints.ai_flags &= ~ AI_CANONIDN;
++#endif
+ 
+ 	/* Support being called using `ping4` or `ping6` symlinks */
+ 	if (argv[0][strlen(argv[0])-1] == '4')
+diff --git a/ping.h b/ping.h
+index 3e09685..8a0c4ef 100644
+--- a/ping.h
++++ b/ping.h
+@@ -28,7 +28,6 @@
+ #include <netinet/icmp6.h>
+ #include <linux/filter.h>
+ #include <resolv.h>
+-#include <locale.h>
+ 
+ #ifdef CAPABILITIES
+ #include <sys/prctl.h>
+@@ -36,6 +35,7 @@
+ #endif
+ 
+ #ifdef USE_IDN
++#include <locale.h>
+ #include <idn2.h>
+ #define getaddrinfo_flags (AI_CANONNAME | AI_IDN | AI_CANONIDN)
+ #define getnameinfo_flags NI_IDN
diff --git a/poky/meta/recipes-extended/iputils/iputils/install.patch b/poky/meta/recipes-extended/iputils/iputils/install.patch
new file mode 100644
index 0000000..abfefd7
--- /dev/null
+++ b/poky/meta/recipes-extended/iputils/iputils/install.patch
@@ -0,0 +1,26 @@
+From 5c8c3b04d73304679340f893636e87691992053b Mon Sep 17 00:00:00 2001
+From: Ross Burton <ross@burtonini.com>
+Date: Mon, 23 Jul 2018 14:21:03 +0100
+Subject: [PATCH] Add install
+
+Add a simple install rule so that we always install the binaries that were built.
+
+Upstream-Status: Inappropriate
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+---
+ Makefile | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/Makefile b/Makefile
+index 17fc5c9..e0c2784 100644
+--- a/Makefile
++++ b/Makefile
+@@ -231,3 +231,7 @@ rpm:
+ 	@$(RPMBUILD) -ta --define 'current yes' $(RPMTMP)/iputils.tar.bz2
+ 	@rm -f $(RPMTMP)/iputils.tar.bz2
+ 
++install:
++	for t in $(TARGETS); do \
++		install -D $$t $(DESTDIR)$(bindir)/$$t; \
++	done
diff --git a/poky/meta/recipes-extended/iputils/iputils_s20161105.bb b/poky/meta/recipes-extended/iputils/iputils_s20161105.bb
deleted file mode 100644
index 0125739..0000000
--- a/poky/meta/recipes-extended/iputils/iputils_s20161105.bb
+++ /dev/null
@@ -1,62 +0,0 @@
-SUMMARY = "Network monitoring tools"
-DESCRIPTION = "Utilities for the IP protocol, including traceroute6, \
-tracepath, tracepath6, ping, ping6 and arping."
-HOMEPAGE = "https://github.com/iputils/iputils"
-SECTION = "console/network"
-
-LICENSE = "BSD & GPLv2+"
-
-LIC_FILES_CHKSUM = "file://ping.c;beginline=1;endline=35;md5=f9ceb201733e9a6cf8f00766dd278d82 \
-                    file://tracepath.c;beginline=1;endline=10;md5=0ecea2bf60bff2f3d840096d87647f3d \
-                    file://arping.c;beginline=1;endline=11;md5=fe84301b5c2655c950f8b92a057fafa6 \
-                    file://tftpd.c;beginline=1;endline=32;md5=28834bf8a91a5b8a92755dbee709ef96 "
-
-DEPENDS = "gnutls libcap libgcrypt"
-
-SRC_URI = "git://github.com/iputils/iputils \
-           file://0001-Fix-build-on-MUSL.patch \
-           "
-S = "${WORKDIR}/git"
-SRCREV = "bffc0e957b98d626ab4cea218c89251201425442"
-
-UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>s\d+)"
-
-EXTRA_OEMAKE = "-e MAKEFLAGS="
-
-PACKAGECONFIG ?= ""
-PACKAGECONFIG[libidn] = "USE_IDN=yes,USE_IDN=no,libidn"
-
-do_compile () {
-	oe_runmake 'CC=${CC} -D_GNU_SOURCE' VPATH="${STAGING_LIBDIR}:${STAGING_DIR_HOST}/${base_libdir}" ${PACKAGECONFIG_CONFARGS} all
-}
-
-do_install () {
-	install -m 0755 -d ${D}${base_bindir}
-	# SUID root programs
-	install -m 4555 ping ${D}${base_bindir}/ping
-	install -m 4555 traceroute6 ${D}${base_bindir}/
-	install -m 4555 clockdiff ${D}${base_bindir}/
-	# Other programgs
-	for i in arping tracepath; do
-	  install -m 0755 $i ${D}${base_bindir}/
-	done
-}
-
-inherit update-alternatives
-
-ALTERNATIVE_PRIORITY = "100"
-
-ALTERNATIVE_${PN}-ping = "ping"
-ALTERNATIVE_LINK_NAME[ping] = "${base_bindir}/ping"
-
-PACKAGES += "${PN}-ping ${PN}-arping ${PN}-tracepath ${PN}-traceroute6 ${PN}-clockdiff"
-
-ALLOW_EMPTY_${PN} = "1"
-RDEPENDS_${PN} += "${PN}-ping ${PN}-arping ${PN}-tracepath ${PN}-traceroute6 ${PN}-clockdiff"
-
-FILES_${PN}	= ""
-FILES_${PN}-ping = "${base_bindir}/ping.${BPN}"
-FILES_${PN}-arping = "${base_bindir}/arping"
-FILES_${PN}-tracepath = "${base_bindir}/tracepath"
-FILES_${PN}-traceroute6	= "${base_bindir}/traceroute6"
-FILES_${PN}-clockdiff = "${base_bindir}/clockdiff"
diff --git a/poky/meta/recipes-extended/iputils/iputils_s20180629.bb b/poky/meta/recipes-extended/iputils/iputils_s20180629.bb
new file mode 100644
index 0000000..eff44be
--- /dev/null
+++ b/poky/meta/recipes-extended/iputils/iputils_s20180629.bb
@@ -0,0 +1,61 @@
+SUMMARY = "Network monitoring tools"
+DESCRIPTION = "Utilities for the IP protocol, including traceroute6, \
+tracepath, tracepath6, ping, ping6 and arping."
+HOMEPAGE = "https://github.com/iputils/iputils"
+SECTION = "console/network"
+
+LICENSE = "BSD & GPLv2+"
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=b792e38abdc59f766a3153908f23e766 \
+                    file://LICENSE.BSD3;md5=0f00d99239d922ffd13cabef83b33444 \
+                    file://LICENSE.GPL2;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+DEPENDS = "gnutls libcap libgcrypt"
+
+SRC_URI = "git://github.com/iputils/iputils \
+           file://ai_canonidn.patch \
+           file://install.patch"
+SRCREV = "f6aac8dbe3f8c45c53424854a3312bdd8cdd58d3"
+
+S = "${WORKDIR}/git"
+
+UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>s\d+)"
+
+EXTRA_OEMAKE = "-e MAKEFLAGS="
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[libidn] = "USE_IDN=yes,USE_IDN=no,libidn2"
+
+do_compile () {
+	oe_runmake 'CC=${CC} -D_GNU_SOURCE' VPATH="${STAGING_LIBDIR}:${STAGING_DIR_HOST}/${base_libdir}" ${PACKAGECONFIG_CONFARGS} all
+}
+
+do_install() {
+	oe_runmake DESTDIR=${D} bindir=${base_bindir} install
+	for b in ping traceroute6 clockdiff; do
+		chmod u+s ${D}${base_bindir}/$b
+	done
+}
+
+inherit update-alternatives
+
+ALTERNATIVE_PRIORITY = "100"
+
+ALTERNATIVE_${PN}-ping = "ping"
+ALTERNATIVE_LINK_NAME[ping] = "${base_bindir}/ping"
+
+SPLITPKGS = "${PN}-ping ${PN}-arping ${PN}-tracepath ${PN}-traceroute6 ${PN}-clockdiff ${PN}-tftpd ${PN}-rarpd ${PN}-rdisc"
+PACKAGES += "${SPLITPKGS}"
+
+ALLOW_EMPTY_${PN} = "1"
+RDEPENDS_${PN} += "${SPLITPKGS}"
+
+FILES_${PN}	= ""
+FILES_${PN}-ping = "${base_bindir}/ping.${BPN}"
+FILES_${PN}-arping = "${base_bindir}/arping"
+FILES_${PN}-tracepath = "${base_bindir}/tracepath"
+FILES_${PN}-traceroute6	= "${base_bindir}/traceroute6"
+FILES_${PN}-clockdiff = "${base_bindir}/clockdiff"
+FILES_${PN}-tftpd = "${base_bindir}/tftpd"
+FILES_${PN}-rarpd = "${base_bindir}/rarpd"
+FILES_${PN}-rdisc = "${base_bindir}/rdisc"
diff --git a/poky/meta/recipes-extended/less/less_529.bb b/poky/meta/recipes-extended/less/less_529.bb
deleted file mode 100644
index c86f754..0000000
--- a/poky/meta/recipes-extended/less/less_529.bb
+++ /dev/null
@@ -1,42 +0,0 @@
-SUMMARY = "Text file viewer similar to more"
-DESCRIPTION = "Less is a program similar to more, i.e. a terminal \
-based program for viewing text files and the output from other \
-programs. Less offers many features beyond those that more does."
-HOMEPAGE = "http://www.greenwoodsoftware.com/"
-SECTION = "console/utils"
-
-# (GPLv2+ (<< 418), GPLv3+ (>= 418)) | less
-# Including email author giving permissing to use BSD
-#
-# From: Mark Nudelman <markn@greenwoodsoftware.com>
-# To: Elizabeth Flanagan <elizabeth.flanagan@intel.com
-# Date: 12/19/11
-#
-# Hi Elizabeth,
-# Using a generic BSD license for less is fine with me.
-# Thanks,
-#
-# --Mark
-#
-
-LICENSE = "GPLv3+ | BSD-2-Clause"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
-                    file://LICENSE;md5=2ef3e4b8dafc85612bc5254b8081e234"
-DEPENDS = "ncurses"
-
-SRC_URI = "http://www.greenwoodsoftware.com/${BPN}/${BPN}-${PV}.tar.gz \
-	  "
-
-SRC_URI[md5sum] = "32018b53a1f7319ab54349baf80e6aa8"
-SRC_URI[sha256sum] = "dba42cd4c38174b7bd0d426d8a39df2be6bcc1ec18946a4642713290f6bf9a0b"
-
-UPSTREAM_CHECK_URI = "http://www.greenwoodsoftware.com/less/download.html"
-
-inherit autotools update-alternatives
-
-do_install () {
-        oe_runmake 'bindir=${D}${bindir}' 'mandir=${D}${mandir}' install
-}
-
-ALTERNATIVE_${PN} = "less"
-ALTERNATIVE_PRIORITY = "100"
diff --git a/poky/meta/recipes-extended/less/less_530.bb b/poky/meta/recipes-extended/less/less_530.bb
new file mode 100644
index 0000000..c07b121
--- /dev/null
+++ b/poky/meta/recipes-extended/less/less_530.bb
@@ -0,0 +1,42 @@
+SUMMARY = "Text file viewer similar to more"
+DESCRIPTION = "Less is a program similar to more, i.e. a terminal \
+based program for viewing text files and the output from other \
+programs. Less offers many features beyond those that more does."
+HOMEPAGE = "http://www.greenwoodsoftware.com/"
+SECTION = "console/utils"
+
+# (GPLv2+ (<< 418), GPLv3+ (>= 418)) | less
+# Including email author giving permissing to use BSD
+#
+# From: Mark Nudelman <markn@greenwoodsoftware.com>
+# To: Elizabeth Flanagan <elizabeth.flanagan@intel.com
+# Date: 12/19/11
+#
+# Hi Elizabeth,
+# Using a generic BSD license for less is fine with me.
+# Thanks,
+#
+# --Mark
+#
+
+LICENSE = "GPLv3+ | BSD-2-Clause"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
+                    file://LICENSE;md5=2ef3e4b8dafc85612bc5254b8081e234"
+DEPENDS = "ncurses"
+
+SRC_URI = "http://www.greenwoodsoftware.com/${BPN}/${BPN}-${PV}.tar.gz \
+	  "
+
+SRC_URI[md5sum] = "6a39bccf420c946b0fd7ffc64961315b"
+SRC_URI[sha256sum] = "503f91ab0af4846f34f0444ab71c4b286123f0044a4964f1ae781486c617f2e2"
+
+UPSTREAM_CHECK_URI = "http://www.greenwoodsoftware.com/less/download.html"
+
+inherit autotools update-alternatives
+
+do_install () {
+        oe_runmake 'bindir=${D}${bindir}' 'mandir=${D}${mandir}' install
+}
+
+ALTERNATIVE_${PN} = "less"
+ALTERNATIVE_PRIORITY = "100"
diff --git a/poky/meta/recipes-extended/libaio/libaio/00_arches.patch b/poky/meta/recipes-extended/libaio/libaio/00_arches.patch
index 9d6447d..bec189f 100644
--- a/poky/meta/recipes-extended/libaio/libaio/00_arches.patch
+++ b/poky/meta/recipes-extended/libaio/libaio/00_arches.patch
@@ -1,11 +1,27 @@
+From ceba1e03e5b57cdae0b3b2d2c9afebc085c986d8 Mon Sep 17 00:00:00 2001
+From: Qing He <qing.he@intel.com>
+Date: Fri, 27 Aug 2010 10:15:31 +0800
+Subject: [PATCH] libaio: add new recipe
+
 Upstream-Status: Inappropriate [embedded specific]
 
 from openembedded, added by Qing He <qing.he@intel.com>
 
-Index: libaio-0.3.110/src/syscall-m68k.h
-===================================================================
+---
+ src/syscall-m68k.h   |  78 ++++++++++++++++++
+ src/syscall-mips.h   | 223 +++++++++++++++++++++++++++++++++++++++++++++++++++
+ src/syscall-parisc.h | 146 +++++++++++++++++++++++++++++++++
+ src/syscall.h        |   6 ++
+ 4 files changed, 453 insertions(+)
+ create mode 100644 src/syscall-m68k.h
+ create mode 100644 src/syscall-mips.h
+ create mode 100644 src/syscall-parisc.h
+
+diff --git a/src/syscall-m68k.h b/src/syscall-m68k.h
+new file mode 100644
+index 0000000..f440412
 --- /dev/null
-+++ libaio-0.3.110/src/syscall-m68k.h
++++ b/src/syscall-m68k.h
 @@ -0,0 +1,78 @@
 +#define __NR_io_setup		241
 +#define __NR_io_destroy		242
@@ -85,27 +101,11 @@
 +return (type) __res; \
 +}
 +
-Index: libaio-0.3.110/src/syscall.h
-===================================================================
---- libaio-0.3.110.orig/src/syscall.h
-+++ libaio-0.3.110/src/syscall.h
-@@ -28,6 +28,12 @@
- #include "syscall-sparc.h"
- #elif defined(__aarch64__)
- #include "syscall-arm64.h"
-+#elif defined(__m68k__)
-+#include "syscall-m68k.h"
-+#elif defined(__hppa__)
-+#include "syscall-parisc.h"
-+#elif defined(__mips__)
-+#include "syscall-mips.h"
- #else
- #warning "using generic syscall method"
- #include "syscall-generic.h"
-Index: libaio-0.3.110/src/syscall-mips.h
-===================================================================
+diff --git a/src/syscall-mips.h b/src/syscall-mips.h
+new file mode 100644
+index 0000000..4142499
 --- /dev/null
-+++ libaio-0.3.110/src/syscall-mips.h
++++ b/src/syscall-mips.h
 @@ -0,0 +1,223 @@
 +/*
 + * This file is subject to the terms and conditions of the GNU General Public
@@ -330,10 +330,11 @@
 +
 +#endif /* (_MIPS_SIM == _MIPS_SIM_NABI32) || (_MIPS_SIM == _MIPS_SIM_ABI64) */
 +
-Index: libaio-0.3.110/src/syscall-parisc.h
-===================================================================
+diff --git a/src/syscall-parisc.h b/src/syscall-parisc.h
+new file mode 100644
+index 0000000..ff61746
 --- /dev/null
-+++ libaio-0.3.110/src/syscall-parisc.h
++++ b/src/syscall-parisc.h
 @@ -0,0 +1,146 @@
 +/*
 + * Linux system call numbers.
@@ -481,127 +482,20 @@
 +    return K_INLINE_SYSCALL(sname, 5, arg1, arg2, arg3, arg4, arg5);	\
 +}
 +
-Index: libaio-0.3.110/src/syscall-arm.h
-===================================================================
---- libaio-0.3.110.orig/src/syscall-arm.h
-+++ libaio-0.3.110/src/syscall-arm.h
-@@ -114,3 +114,119 @@ type fname(type1 arg1, type2 arg2, type3
-   return (type) __res_r0;						\
- }
- 
-+/*
-+ *  linux/include/asm-arm/unistd.h
-+ *
-+ *  Copyright (C) 2001-2005 Russell King
-+ *
-+ * This program is free software; you can redistribute it and/or modify
-+ * it under the terms of the GNU General Public License version 2 as
-+ * published by the Free Software Foundation.
-+ *
-+ * Please forward _all_ changes to this file to rmk@arm.linux.org.uk,
-+ * no matter what the change is.  Thanks!
-+ */
-+
-+#define __NR_OABI_SYSCALL_BASE	0x900000
-+
-+#if defined(__thumb__) || defined(__ARM_EABI__)
-+#define __NR_SYSCALL_BASE	0
-+#else
-+#define __NR_SYSCALL_BASE	__NR_OABI_SYSCALL_BASE
-+#endif
-+
-+#define __NR_io_setup			(__NR_SYSCALL_BASE+243)
-+#define __NR_io_destroy			(__NR_SYSCALL_BASE+244)
-+#define __NR_io_getevents		(__NR_SYSCALL_BASE+245)
-+#define __NR_io_submit			(__NR_SYSCALL_BASE+246)
-+#define __NR_io_cancel			(__NR_SYSCALL_BASE+247)
-+
-+#define __sys2(x) #x
-+#define __sys1(x) __sys2(x)
-+
-+#if defined(__thumb__) || defined(__ARM_EABI__)
-+#define __SYS_REG(name) register long __sysreg __asm__("r7") = __NR_##name;
-+#define __SYS_REG_LIST(regs...) "r" (__sysreg) , ##regs
-+#define __syscall(name) "swi\t0"
-+#else
-+#define __SYS_REG(name)
-+#define __SYS_REG_LIST(regs...) regs
-+#define __syscall(name) "swi\t" __sys1(__NR_##name) ""
-+#endif
-+
-+#define io_syscall1(type,fname,sname,type1,arg1)			\
-+type fname(type1 arg1) {						\
-+  __SYS_REG(sname)							\
-+  register long __r0 __asm__("r0") = (long)arg1;			\
-+  register long __res_r0 __asm__("r0");					\
-+  __asm__ __volatile__ (						\
-+  __syscall(sname)							\
-+	: "=r" (__res_r0)						\
-+	: __SYS_REG_LIST( "0" (__r0) )					\
-+	: "memory" );							\
-+  return (type) __res_r0;						\
-+}
-+
-+#define io_syscall2(type,fname,sname,type1,arg1,type2,arg2)		\
-+type fname(type1 arg1,type2 arg2) {					\
-+  __SYS_REG(sname)							\
-+  register long __r0 __asm__("r0") = (long)arg1;			\
-+  register long __r1 __asm__("r1") = (long)arg2;			\
-+  register long __res_r0 __asm__("r0");					\
-+  __asm__ __volatile__ (						\
-+  __syscall(sname)							\
-+	: "=r" (__res_r0)						\
-+	: __SYS_REG_LIST( "0" (__r0), "r" (__r1) )			\
-+	: "memory" );							\
-+  return (type) __res_r0;						\
-+}
-+
-+#define io_syscall3(type,fname,sname,type1,arg1,type2,arg2,type3,arg3)	\
-+type fname(type1 arg1,type2 arg2,type3 arg3) {				\
-+  __SYS_REG(sname)							\
-+  register long __r0 __asm__("r0") = (long)arg1;			\
-+  register long __r1 __asm__("r1") = (long)arg2;			\
-+  register long __r2 __asm__("r2") = (long)arg3;			\
-+  register long __res_r0 __asm__("r0");					\
-+  __asm__ __volatile__ (						\
-+  __syscall(sname)							\
-+	: "=r" (__res_r0)						\
-+	: __SYS_REG_LIST( "0" (__r0), "r" (__r1), "r" (__r2) )		\
-+	: "memory" );							\
-+  return (type) __res_r0;						\
-+}
-+
-+#define io_syscall4(type,fname,sname,type1,arg1,type2,arg2,type3,arg3,type4,arg4)\
-+type fname(type1 arg1, type2 arg2, type3 arg3, type4 arg4) {		\
-+  __SYS_REG(sname)							\
-+  register long __r0 __asm__("r0") = (long)arg1;			\
-+  register long __r1 __asm__("r1") = (long)arg2;			\
-+  register long __r2 __asm__("r2") = (long)arg3;			\
-+  register long __r3 __asm__("r3") = (long)arg4;			\
-+  register long __res_r0 __asm__("r0");					\
-+  __asm__ __volatile__ (						\
-+  __syscall(sname)							\
-+	: "=r" (__res_r0)						\
-+	: __SYS_REG_LIST( "0" (__r0), "r" (__r1), "r" (__r2), "r" (__r3) ) \
-+	: "memory" );							\
-+  return (type) __res_r0;						\
-+}
-+
-+#define io_syscall5(type,fname,sname,type1,arg1,type2,arg2,type3,arg3,type4,arg4,type5,arg5)	\
-+type fname(type1 arg1, type2 arg2, type3 arg3, type4 arg4, type5 arg5) {\
-+  __SYS_REG(sname)							\
-+  register long __r0 __asm__("r0") = (long)arg1;			\
-+  register long __r1 __asm__("r1") = (long)arg2;			\
-+  register long __r2 __asm__("r2") = (long)arg3;			\
-+  register long __r3 __asm__("r3") = (long)arg4;			\
-+  register long __r4 __asm__("r4") = (long)arg5;			\
-+  register long __res_r0 __asm__("r0");					\
-+  __asm__ __volatile__ (						\
-+  __syscall(sname)							\
-+	: "=r" (__res_r0)						\
-+	: __SYS_REG_LIST( "0" (__r0), "r" (__r1), "r" (__r2),		\
-+			  "r" (__r3), "r" (__r4) )			\
-+	: "memory" );							\
-+  return (type) __res_r0;						\
-+}
-+
+diff --git a/src/syscall.h b/src/syscall.h
+index 9b9e9c1..9ecd3b4 100644
+--- a/src/syscall.h
++++ b/src/syscall.h
+@@ -29,6 +29,12 @@
+ #include "syscall-sparc.h"
+ #elif defined(__aarch64__) || defined(__riscv)
+ #include "syscall-generic.h"
++#elif defined(__m68k__)
++#include "syscall-m68k.h"
++#elif defined(__hppa__)
++#include "syscall-parisc.h"
++#elif defined(__mips__)
++#include "syscall-mips.h"
+ #else
+ #warning "using system call numbers from sys/syscall.h"
+ #endif
diff --git a/poky/meta/recipes-extended/libaio/libaio/generic-arch-dectection-for-padding-defines.patch b/poky/meta/recipes-extended/libaio/libaio/generic-arch-dectection-for-padding-defines.patch
deleted file mode 100644
index bba7e55..0000000
--- a/poky/meta/recipes-extended/libaio/libaio/generic-arch-dectection-for-padding-defines.patch
+++ /dev/null
@@ -1,65 +0,0 @@
-From: Nathan Rossi <nathan.rossi@xilinx.com>
-Date: Tue, 27 Jan 2015 14:59:35 +1000
-Subject: [PATCH] Generic arch dectection for padding defines
-
-When available use the GNU C defines for endian and bitwidth to
-determine the padding required. This reduces the need to define the
-padding selection for every architecture.
-
-Signed-off-by: Nathan Rossi <nathan.rossi@xilinx.com>
-Signed-off-by: Jeff Moyer <jmoyer@redhat.com>
-Upstream-Status: Backport
----
- src/libaio.h | 16 ++++++++++++----
- 1 file changed, 12 insertions(+), 4 deletions(-)
-
-diff --git a/src/libaio.h b/src/libaio.h
-index 1223146..4a4e0f5 100644
---- a/src/libaio.h
-+++ b/src/libaio.h
-@@ -52,14 +52,18 @@ typedef enum io_iocb_cmd {
- /* little endian, 32 bits */
- #if defined(__i386__) || (defined(__arm__) && !defined(__ARMEB__)) || \
-     defined(__sh__) || defined(__bfin__) || defined(__MIPSEL__) || \
--    defined(__cris__)
-+    defined(__cris__) || \
-+    (defined(__GNUC__) && defined(__BYTE_ORDER__) && \
-+         __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__ && __SIZEOF_LONG__ == 4)
- #define PADDED(x, y)	x; unsigned y
- #define PADDEDptr(x, y)	x; unsigned y
- #define PADDEDul(x, y)	unsigned long x; unsigned y
- 
- /* little endian, 64 bits */
- #elif defined(__ia64__) || defined(__x86_64__) || defined(__alpha__) || \
--      (defined(__aarch64__) && defined(__AARCH64EL__))
-+      (defined(__aarch64__) && defined(__AARCH64EL__)) || \
-+      (defined(__GNUC__) && defined(__BYTE_ORDER__) && \
-+          __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__ && __SIZEOF_LONG__ == 8)
- #define PADDED(x, y)	x, y
- #define PADDEDptr(x, y)	x
- #define PADDEDul(x, y)	unsigned long x
-@@ -67,7 +71,9 @@ typedef enum io_iocb_cmd {
- /* big endian, 64 bits */
- #elif defined(__powerpc64__) || defined(__s390x__) || \
-       (defined(__sparc__) && defined(__arch64__)) || \
--      (defined(__aarch64__) && defined(__AARCH64EB__))
-+      (defined(__aarch64__) && defined(__AARCH64EB__)) || \
-+      (defined(__GNUC__) && defined(__BYTE_ORDER__) && \
-+           __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__ && __SIZEOF_LONG__ == 8)
- #define PADDED(x, y)	unsigned y; x
- #define PADDEDptr(x,y)	x
- #define PADDEDul(x, y)	unsigned long x
-@@ -76,7 +82,9 @@ typedef enum io_iocb_cmd {
- #elif defined(__PPC__) || defined(__s390__) || \
-       (defined(__arm__) && defined(__ARMEB__)) || \
-       defined(__sparc__) || defined(__MIPSEB__) || defined(__m68k__) || \
--      defined(__hppa__) || defined(__frv__) || defined(__avr32__)
-+      defined(__hppa__) || defined(__frv__) || defined(__avr32__) || \
-+      (defined(__GNUC__) && defined(__BYTE_ORDER__) && \
-+           __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__ && __SIZEOF_LONG__ == 4)
- #define PADDED(x, y)	unsigned y; x
- #define PADDEDptr(x, y)	unsigned y; x
- #define PADDEDul(x, y)	unsigned y; unsigned long x
--- 
-2.1.1
-
diff --git a/poky/meta/recipes-extended/libaio/libaio/libaio_fix_for_x32.patch b/poky/meta/recipes-extended/libaio/libaio/libaio_fix_for_x32.patch
deleted file mode 100644
index dc4ba50..0000000
--- a/poky/meta/recipes-extended/libaio/libaio/libaio_fix_for_x32.patch
+++ /dev/null
@@ -1,61 +0,0 @@
-Upstream-Status: Pending
-
-Properly load arguments 5 an 6 for x86-64 syscall
-Use asm ("r10") and asm ("r8") to load arguments 5 an 6 for x86-64
-syscall so that it works with both x32 and x86-64.
-
-Received this patch from H.J. Lu <hjl.tools@gmail.com>
-
-Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
-2011/12/02
-
---- libaio-0.3.109/src/syscall-x86_64.h.x32	2009-10-09 11:17:02.000000000 -0700
-+++ libaio-0.3.109/src/syscall-x86_64.h	2011-12-02 09:09:07.537603224 -0800
-@@ -1,8 +1,18 @@
-+#ifndef __NR_io_setup
- #define __NR_io_setup		206
-+#endif
-+#ifndef __NR_io_destroy
- #define __NR_io_destroy		207
-+#endif
-+#ifndef __NR_io_getevents
- #define __NR_io_getevents	208
-+#endif
-+#ifndef __NR_io_submit
- #define __NR_io_submit		209
-+#endif
-+#ifndef __NR_io_cancel
- #define __NR_io_cancel		210
-+#endif
- 
- #define __syscall_clobber "r11","rcx","memory" 
- #define __syscall "syscall"
-@@ -42,10 +52,11 @@ return __res;								\
- type fname (type1 arg1, type2 arg2, type3 arg3, type4 arg4)		\
- {									\
- long __res;								\
--__asm__ volatile ("movq %5,%%r10 ;" __syscall				\
-+register long __a4 asm ("r10") = (long) arg4;				\
-+__asm__ volatile (__syscall						\
- 	: "=a" (__res)							\
- 	: "0" (__NR_##sname),"D" ((long)(arg1)),"S" ((long)(arg2)),	\
--	  "d" ((long)(arg3)),"g" ((long)(arg4)) : __syscall_clobber,"r10" ); \
-+	  "d" ((long)(arg3)),"r" (__a4)); \
- return __res;								\
- } 
- 
-@@ -54,10 +65,11 @@ return __res;								\
- type fname (type1 arg1,type2 arg2,type3 arg3,type4 arg4,type5 arg5)	\
- {									\
- long __res;								\
--__asm__ volatile ("movq %5,%%r10 ; movq %6,%%r8 ; " __syscall		\
-+register long __a4 asm ("r10") = (long) arg4;				\
-+register long __a5 asm ("r8") = (long) arg5;				\
-+__asm__ volatile ( __syscall						\
- 	: "=a" (__res)							\
- 	: "0" (__NR_##sname),"D" ((long)(arg1)),"S" ((long)(arg2)),	\
--	  "d" ((long)(arg3)),"g" ((long)(arg4)),"g" ((long)(arg5)) :	\
--	__syscall_clobber,"r8","r10" );					\
-+	  "d" ((long)(arg3)),"r" (__a4),"r" (__a5));			\
- return __res;								\
- }
diff --git a/poky/meta/recipes-extended/libaio/libaio_0.3.110.bb b/poky/meta/recipes-extended/libaio/libaio_0.3.110.bb
deleted file mode 100644
index 75975d4..0000000
--- a/poky/meta/recipes-extended/libaio/libaio_0.3.110.bb
+++ /dev/null
@@ -1,26 +0,0 @@
-SUMMARY = "Asynchronous I/O library"
-DESCRIPTION = "Asynchronous input/output library that uses the kernels native interface"
-HOMEPAGE = "http://lse.sourceforge.net/io/aio.html"
-
-LICENSE = "LGPLv2.1+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d8045f3b8f929c1cb29a1e3fd737b499"
-
-SRC_URI = "http://snapshot.debian.org/archive/debian/20160728T043443Z/pool/main/liba/${BPN}/${BPN}_${PV}.orig.tar.gz \
-           file://generic-arch-dectection-for-padding-defines.patch \
-           file://00_arches.patch \
-           file://destdir.patch \
-           file://libaio_fix_for_x32.patch \
-           file://libaio_fix_for_mips_syscalls.patch \
-           file://system-linkage.patch \
-           "
-
-SRC_URI[md5sum] = "2a35602e43778383e2f4907a4ca39ab8"
-SRC_URI[sha256sum] = "e019028e631725729376250e32b473012f7cb68e1f7275bfc1bbcdd0f8745f7e"
-
-UPSTREAM_CHECK_URI = "${DEBIAN_MIRROR}/main/liba/libaio/"
-
-EXTRA_OEMAKE =+ "prefix=${prefix} includedir=${includedir} libdir=${libdir}"
-
-do_install () {
-    oe_runmake install DESTDIR=${D}
-}
diff --git a/poky/meta/recipes-extended/libaio/libaio_0.3.111.bb b/poky/meta/recipes-extended/libaio/libaio_0.3.111.bb
new file mode 100644
index 0000000..04b50b6
--- /dev/null
+++ b/poky/meta/recipes-extended/libaio/libaio_0.3.111.bb
@@ -0,0 +1,23 @@
+SUMMARY = "Asynchronous I/O library"
+DESCRIPTION = "Asynchronous input/output library that uses the kernels native interface"
+HOMEPAGE = "http://lse.sourceforge.net/io/aio.html"
+
+LICENSE = "LGPLv2.1+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d8045f3b8f929c1cb29a1e3fd737b499"
+
+SRC_URI = "git://pagure.io/libaio.git;protocol=https \
+           file://00_arches.patch \
+           file://destdir.patch \
+           file://libaio_fix_for_mips_syscalls.patch \
+           file://system-linkage.patch \
+           "
+SRCREV = "f66be22ab0a59a39858900ab72a8c6a6e8b0b7ec"
+S = "${WORKDIR}/git"
+
+EXTRA_OEMAKE =+ "prefix=${prefix} includedir=${includedir} libdir=${libdir}"
+
+do_install () {
+    oe_runmake install DESTDIR=${D}
+}
+
+BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-extended/libarchive/libarchive/CVE-2017-14166.patch b/poky/meta/recipes-extended/libarchive/libarchive/CVE-2017-14166.patch
deleted file mode 100644
index e85fec4..0000000
--- a/poky/meta/recipes-extended/libarchive/libarchive/CVE-2017-14166.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-libarchive-3.3.2: Fix CVE-2017-14166
-
-[No upstream tracking] -- https://github.com/libarchive/libarchive/pull/935
-
-archive_read_support_format_xar: heap-based buffer overflow in xml_data
-
-Upstream-Status: Backport [https://github.com/libarchive/libarchive/commit/fa7438a0ff4033e4741c807394a9af6207940d71]
-CVE: CVE-2017-14166
-Bug: 935
-Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
-
-diff --git a/libarchive/archive_read_support_format_xar.c b/libarchive/archive_read_support_format_xar.c
-index 7a22beb..93eeacc 100644
---- a/libarchive/archive_read_support_format_xar.c
-+++ b/libarchive/archive_read_support_format_xar.c
-@@ -1040,6 +1040,9 @@ atol10(const char *p, size_t char_cnt)
- 	uint64_t l;
- 	int digit;
- 
-+	if (char_cnt == 0)
-+		return (0);
-+
- 	l = 0;
- 	digit = *p - '0';
- 	while (digit >= 0 && digit < 10  && char_cnt-- > 0) {
-@@ -1054,7 +1057,10 @@ atol8(const char *p, size_t char_cnt)
- {
- 	int64_t l;
- 	int digit;
--        
-+
-+	if (char_cnt == 0)
-+		return (0);
-+
- 	l = 0;
- 	while (char_cnt-- > 0) {
- 		if (*p >= '0' && *p <= '7')
diff --git a/poky/meta/recipes-extended/libarchive/libarchive/CVE-2017-14501.patch b/poky/meta/recipes-extended/libarchive/libarchive/CVE-2017-14501.patch
deleted file mode 100644
index 1038102..0000000
--- a/poky/meta/recipes-extended/libarchive/libarchive/CVE-2017-14501.patch
+++ /dev/null
@@ -1,79 +0,0 @@
-From f9569c086ff29259c73790db9cbf39fe8fb9d862 Mon Sep 17 00:00:00 2001
-From: John Starks <jostarks@microsoft.com>
-Date: Wed, 25 Jul 2018 12:16:34 -0700
-Subject: [PATCH] iso9660: validate directory record length
-
-CVE: CVE-2017-14501
-Upstream-Status: Backport [https://github.com/mmatuska/libarchive/commit/13e87dcd9c37b533127cceb9f3e1e5a38d95e784]
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- libarchive/archive_read_support_format_iso9660.c | 17 +++++++++++------
- 1 file changed, 11 insertions(+), 6 deletions(-)
-
-diff --git a/libarchive/archive_read_support_format_iso9660.c b/libarchive/archive_read_support_format_iso9660.c
-index f01d37bf..089bb723 100644
---- a/libarchive/archive_read_support_format_iso9660.c
-+++ b/libarchive/archive_read_support_format_iso9660.c
-@@ -409,7 +409,8 @@ static int	next_entry_seek(struct archive_read *, struct iso9660 *,
- 		    struct file_info **);
- static struct file_info *
- 		parse_file_info(struct archive_read *a,
--		    struct file_info *parent, const unsigned char *isodirrec);
-+		    struct file_info *parent, const unsigned char *isodirrec,
-+		    size_t reclen);
- static int	parse_rockridge(struct archive_read *a,
- 		    struct file_info *file, const unsigned char *start,
- 		    const unsigned char *end);
-@@ -1022,7 +1023,7 @@ read_children(struct archive_read *a, struct file_info *parent)
- 			if (*(p + DR_name_len_offset) == 1
- 			    && *(p + DR_name_offset) == '\001')
- 				continue;
--			child = parse_file_info(a, parent, p);
-+			child = parse_file_info(a, parent, p, b - p);
- 			if (child == NULL) {
- 				__archive_read_consume(a, skip_size);
- 				return (ARCHIVE_FATAL);
-@@ -1112,7 +1113,7 @@ choose_volume(struct archive_read *a, struct iso9660 *iso9660)
- 	 */
- 	seenJoliet = iso9660->seenJoliet;/* Save flag. */
- 	iso9660->seenJoliet = 0;
--	file = parse_file_info(a, NULL, block);
-+	file = parse_file_info(a, NULL, block, vd->size);
- 	if (file == NULL)
- 		return (ARCHIVE_FATAL);
- 	iso9660->seenJoliet = seenJoliet;
-@@ -1144,7 +1145,7 @@ choose_volume(struct archive_read *a, struct iso9660 *iso9660)
- 			return (ARCHIVE_FATAL);
- 		}
- 		iso9660->seenJoliet = 0;
--		file = parse_file_info(a, NULL, block);
-+		file = parse_file_info(a, NULL, block, vd->size);
- 		if (file == NULL)
- 			return (ARCHIVE_FATAL);
- 		iso9660->seenJoliet = seenJoliet;
-@@ -1749,7 +1750,7 @@ archive_read_format_iso9660_cleanup(struct archive_read *a)
-  */
- static struct file_info *
- parse_file_info(struct archive_read *a, struct file_info *parent,
--    const unsigned char *isodirrec)
-+    const unsigned char *isodirrec, size_t reclen)
- {
- 	struct iso9660 *iso9660;
- 	struct file_info *file, *filep;
-@@ -1763,7 +1764,11 @@ parse_file_info(struct archive_read *a, struct file_info *parent,
- 
- 	iso9660 = (struct iso9660 *)(a->format->data);
- 
--	dr_len = (size_t)isodirrec[DR_length_offset];
-+	if (reclen == 0 || reclen < (dr_len = (size_t)isodirrec[DR_length_offset])) {
-+		archive_set_error(&a->archive, ARCHIVE_ERRNO_MISC,
-+			"Invalid directory record length");
-+		return (NULL);
-+	}
- 	name_len = (size_t)isodirrec[DR_name_len_offset];
- 	location = archive_le32dec(isodirrec + DR_extent_offset);
- 	fsize = toi(isodirrec + DR_size_offset, DR_size_size);
--- 
-2.13.3
-
diff --git a/poky/meta/recipes-extended/libarchive/libarchive/CVE-2017-14502.patch b/poky/meta/recipes-extended/libarchive/libarchive/CVE-2017-14502.patch
deleted file mode 100644
index 72e1546..0000000
--- a/poky/meta/recipes-extended/libarchive/libarchive/CVE-2017-14502.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From 5562545b5562f6d12a4ef991fae158bf4ccf92b6 Mon Sep 17 00:00:00 2001
-From: Joerg Sonnenberger <joerg@bec.de>
-Date: Sat, 9 Sep 2017 17:47:32 +0200
-Subject: [PATCH] Avoid a read off-by-one error for UTF16 names in RAR
- archives.
-
-Reported-By: OSS-Fuzz issue 573
-
-CVE: CVE-2017-14502
-
-Upstream-Status: Backport
-
-Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
----
- libarchive/archive_read_support_format_rar.c | 6 +++++-
- 1 file changed, 5 insertions(+), 1 deletion(-)
-
-diff --git a/libarchive/archive_read_support_format_rar.c b/libarchive/archive_read_support_format_rar.c
-index cbb14c3..751de69 100644
---- a/libarchive/archive_read_support_format_rar.c
-+++ b/libarchive/archive_read_support_format_rar.c
-@@ -1496,7 +1496,11 @@ read_header(struct archive_read *a, struct archive_entry *entry,
-         return (ARCHIVE_FATAL);
-       }
-       filename[filename_size++] = '\0';
--      filename[filename_size++] = '\0';
-+      /*
-+       * Do not increment filename_size here as the computations below
-+       * add the space for the terminating NUL explicitly.
-+       */
-+      filename[filename_size] = '\0';
- 
-       /* Decoded unicode form is UTF-16BE, so we have to update a string
-        * conversion object for it. */
--- 
-1.9.1
-
diff --git a/poky/meta/recipes-extended/libarchive/libarchive/CVE-2017-14503.patch b/poky/meta/recipes-extended/libarchive/libarchive/CVE-2017-14503.patch
deleted file mode 100644
index 42fa68c..0000000
--- a/poky/meta/recipes-extended/libarchive/libarchive/CVE-2017-14503.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 2c8c83b9731ff822fad6cc8c670ea5519c366a14 Mon Sep 17 00:00:00 2001
-From: Joerg Sonnenberger <joerg@bec.de>
-Date: Thu, 19 Jul 2018 21:14:53 +0200
-Subject: [PATCH] Reject LHA archive entries with negative size.
-
-CVE: CVE-2017-14503
-Upstream-Status: Backport [https://github.com/libarchive/libarchive/commit/2c8c83b9731ff822fad6cc8c670ea5519c366a14]
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- libarchive/archive_read_support_format_lha.c | 6 ++++++
- 1 file changed, 6 insertions(+)
-
-diff --git a/libarchive/archive_read_support_format_lha.c b/libarchive/archive_read_support_format_lha.c
-index b8ef4ae1..95c99bb1 100644
---- a/libarchive/archive_read_support_format_lha.c
-+++ b/libarchive/archive_read_support_format_lha.c
-@@ -701,6 +701,12 @@ archive_read_format_lha_read_header(struct archive_read *a,
- 	 * Prepare variables used to read a file content.
- 	 */
- 	lha->entry_bytes_remaining = lha->compsize;
-+	if (lha->entry_bytes_remaining < 0) {
-+		archive_set_error(&a->archive,
-+		    ARCHIVE_ERRNO_FILE_FORMAT,
-+		    "Invalid LHa entry size");
-+		return (ARCHIVE_FATAL);
-+	}
- 	lha->entry_offset = 0;
- 	lha->entry_crc_calculated = 0;
- 
--- 
-2.13.3
-
diff --git a/poky/meta/recipes-extended/libarchive/libarchive/bug1066.patch b/poky/meta/recipes-extended/libarchive/libarchive/bug1066.patch
new file mode 100644
index 0000000..0a662b5
--- /dev/null
+++ b/poky/meta/recipes-extended/libarchive/libarchive/bug1066.patch
@@ -0,0 +1,54 @@
+libarchive-3.3.3: Fix bug1066
+
+[No upstream tracking] -- https://github.com/libarchive/libarchive/pull/1066
+
+archive_write_set_format_*.c: fix out of bounds read on empty string () filename
+for guntar, pax and v7tar
+
+There is an out of bounds read flaw in the archive_write_gnutar_header,
+archive_write_pax_header and archive_write_v7tar_header functions which
+could leds to cause a denial of service.
+
+Upstream-Status: Backport [https://github.com/libarchive/libarchive/commit/c246ec5d058a3f70a2d3fb765f92fe9db77b25df]
+Bug: 1066
+Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
+
+diff --git a/libarchive/archive_write_set_format_gnutar.c b/libarchive/archive_write_set_format_gnutar.c
+index 2d858c9..1966c53 100644
+--- a/libarchive/archive_write_set_format_gnutar.c
++++ b/libarchive/archive_write_set_format_gnutar.c
+@@ -339,7 +339,7 @@ archive_write_gnutar_header(struct archive_write *a,
+ 		 * case getting WCS failed. On POSIX, this is a
+ 		 * normal operation.
+ 		 */
+-		if (p != NULL && p[strlen(p) - 1] != '/') {
++		if (p != NULL && p[0] != '\0' && p[strlen(p) - 1] != '/') {
+ 			struct archive_string as;
+ 
+ 			archive_string_init(&as);
+diff --git a/libarchive/archive_write_set_format_pax.c b/libarchive/archive_write_set_format_pax.c
+index 6a301ac..4cfa8ff 100644
+--- a/libarchive/archive_write_set_format_pax.c
++++ b/libarchive/archive_write_set_format_pax.c
+@@ -660,7 +660,7 @@ archive_write_pax_header(struct archive_write *a,
+ 			 * case getting WCS failed. On POSIX, this is a
+ 			 * normal operation.
+ 			 */
+-			if (p != NULL && p[strlen(p) - 1] != '/') {
++			if (p != NULL && p[0] != '\0' && p[strlen(p) - 1] != '/') {
+ 				struct archive_string as;
+ 
+ 				archive_string_init(&as);
+diff --git a/libarchive/archive_write_set_format_v7tar.c b/libarchive/archive_write_set_format_v7tar.c
+index 62b1522..53c0db0 100644
+--- a/libarchive/archive_write_set_format_v7tar.c
++++ b/libarchive/archive_write_set_format_v7tar.c
+@@ -284,7 +284,7 @@ archive_write_v7tar_header(struct archive_write *a, struct archive_entry *entry)
+ 		 * case getting WCS failed. On POSIX, this is a
+ 		 * normal operation.
+ 		 */
+-		if (p != NULL && p[strlen(p) - 1] != '/') {
++		if (p != NULL && p[0] != '\0' && p[strlen(p) - 1] != '/') {
+ 			struct archive_string as;
+ 
+ 			archive_string_init(&as);
diff --git a/poky/meta/recipes-extended/libarchive/libarchive/bug929.patch b/poky/meta/recipes-extended/libarchive/libarchive/bug929.patch
deleted file mode 100644
index 2f3254c..0000000
--- a/poky/meta/recipes-extended/libarchive/libarchive/bug929.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-libarchive-3.3.2: Fix bug929
-
-[No upstream tracking] -- https://github.com/libarchive/libarchive/pull/929
-
-archive_read_support_format_cpio: header_newc(): Avoid overflow when reading corrupt
-cpio archive
-
-A cpio "newc" archive with a namelength of "FFFFFFFF", if read on a
-system with a 32-bit size_t, would result in namelength + name_pad
-overflowing 32 bits and libarchive attempting to copy 2^32-1 bytes
-from a 2-byte buffer, with appropriately hilarious results.
-
-Check for this overflow and fail; there's no legitimate reason for a
-cpio archive to contain a file with a name over 4 billion characters
-in length.
-
-Upstream-Status: Backport [https://github.com/libarchive/libarchive/commit/bac4659e0b970990e7e3f3a3d239294e96311630]
-Bug: 929
-Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
-
-diff --git a/libarchive/archive_read_support_format_cpio.c b/libarchive/archive_read_support_format_cpio.c
-index ad9f782..1faa64d 100644
---- a/libarchive/archive_read_support_format_cpio.c
-+++ b/libarchive/archive_read_support_format_cpio.c
-@@ -633,6 +633,13 @@ header_newc(struct archive_read *a, struct cpio *cpio,
- 	/* Pad name to 2 more than a multiple of 4. */
- 	*name_pad = (2 - *namelength) & 3;
- 
-+	/* Make sure that the padded name length fits into size_t. */
-+	if ((size_t)(*namelength + *name_pad) < *namelength) {
-+		archive_set_error(&a->archive, ARCHIVE_ERRNO_FILE_FORMAT,
-+		    "cpio archive has invalid namelength");
-+		return (ARCHIVE_FATAL);
-+	}
-+
- 	/*
- 	 * Note: entry_bytes_remaining is at least 64 bits and
- 	 * therefore guaranteed to be big enough for a 33-bit file
diff --git a/poky/meta/recipes-extended/libarchive/libarchive_3.3.2.bb b/poky/meta/recipes-extended/libarchive/libarchive_3.3.2.bb
deleted file mode 100644
index e3d90b2..0000000
--- a/poky/meta/recipes-extended/libarchive/libarchive_3.3.2.bb
+++ /dev/null
@@ -1,73 +0,0 @@
-SUMMARY = "Support for reading various archive formats"
-DESCRIPTION = "C library and command-line tools for reading and writing tar, cpio, zip, ISO, and other archive formats"
-HOMEPAGE = "http://www.libarchive.org/"
-SECTION = "devel"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=ed99aca006bc346974bb745a35336425"
-
-DEPENDS = "e2fsprogs-native"
-
-PACKAGECONFIG ?= "zlib bz2 xz lzo"
-
-PACKAGECONFIG_append_class-target = "\
-	libxml2 \
-	${@bb.utils.filter('DISTRO_FEATURES', 'acl xattr', d)} \
-"
-
-DEPENDS_BZIP2 = "bzip2-replacement-native"
-DEPENDS_BZIP2_class-target = "bzip2"
-
-PACKAGECONFIG[acl] = "--enable-acl,--disable-acl,acl,"
-PACKAGECONFIG[xattr] = "--enable-xattr,--disable-xattr,attr,"
-PACKAGECONFIG[zlib] = "--with-zlib,--without-zlib,zlib,"
-PACKAGECONFIG[bz2] = "--with-bz2lib,--without-bz2lib,${DEPENDS_BZIP2},"
-PACKAGECONFIG[xz] = "--with-lzma,--without-lzma,xz,"
-PACKAGECONFIG[openssl] = "--with-openssl,--without-openssl,openssl,"
-PACKAGECONFIG[libxml2] = "--with-xml2,--without-xml2,libxml2,"
-PACKAGECONFIG[expat] = "--with-expat,--without-expat,expat,"
-PACKAGECONFIG[lzo] = "--with-lzo2,--without-lzo2,lzo,"
-PACKAGECONFIG[nettle] = "--with-nettle,--without-nettle,nettle,"
-PACKAGECONFIG[lz4] = "--with-lz4,--without-lz4,lz4,"
-
-EXTRA_OECONF += "--enable-largefile"
-
-SRC_URI = "http://libarchive.org/downloads/libarchive-${PV}.tar.gz \
-           file://bug929.patch \
-           file://CVE-2017-14166.patch \
-           file://CVE-2017-14502.patch \
-           file://non-recursive-extract-and-list.patch \
-           file://CVE-2017-14503.patch \
-           file://CVE-2017-14501.patch \
-          "
-
-SRC_URI[md5sum] = "4583bd6b2ebf7e0e8963d90879eb1b27"
-SRC_URI[sha256sum] = "ed2dbd6954792b2c054ccf8ec4b330a54b85904a80cef477a1c74643ddafa0ce"
-
-inherit autotools update-alternatives pkgconfig
-
-CPPFLAGS += "-I${WORKDIR}/extra-includes"
-
-do_configure[cleandirs] += "${WORKDIR}/extra-includes"
-do_configure_prepend() {
-	# We just need the headers for some type constants, so no need to
-	# build all of e2fsprogs for the target
-	cp -R ${STAGING_INCDIR_NATIVE}/ext2fs ${WORKDIR}/extra-includes/
-}
-
-ALTERNATIVE_PRIORITY = "80"
-
-PACKAGES =+ "bsdtar"
-FILES_bsdtar = "${bindir}/bsdtar"
-
-ALTERNATIVE_bsdtar = "tar"
-ALTERNATIVE_LINK_NAME[tar] = "${base_bindir}/tar"
-ALTERNATIVE_TARGET[tar] = "${bindir}/bsdtar"
-
-PACKAGES =+ "bsdcpio"
-FILES_bsdcpio = "${bindir}/bsdcpio"
-
-ALTERNATIVE_bsdcpio = "cpio"
-ALTERNATIVE_LINK_NAME[cpio] = "${base_bindir}/cpio"
-ALTERNATIVE_TARGET[cpio] = "${bindir}/bsdcpio"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/libarchive/libarchive_3.3.3.bb b/poky/meta/recipes-extended/libarchive/libarchive_3.3.3.bb
new file mode 100644
index 0000000..46a3d43
--- /dev/null
+++ b/poky/meta/recipes-extended/libarchive/libarchive_3.3.3.bb
@@ -0,0 +1,69 @@
+SUMMARY = "Support for reading various archive formats"
+DESCRIPTION = "C library and command-line tools for reading and writing tar, cpio, zip, ISO, and other archive formats"
+HOMEPAGE = "http://www.libarchive.org/"
+SECTION = "devel"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=ed99aca006bc346974bb745a35336425"
+
+DEPENDS = "e2fsprogs-native"
+
+PACKAGECONFIG ?= "zlib bz2 xz lzo"
+
+PACKAGECONFIG_append_class-target = "\
+	libxml2 \
+	${@bb.utils.filter('DISTRO_FEATURES', 'acl xattr', d)} \
+"
+
+DEPENDS_BZIP2 = "bzip2-replacement-native"
+DEPENDS_BZIP2_class-target = "bzip2"
+
+PACKAGECONFIG[acl] = "--enable-acl,--disable-acl,acl,"
+PACKAGECONFIG[xattr] = "--enable-xattr,--disable-xattr,attr,"
+PACKAGECONFIG[zlib] = "--with-zlib,--without-zlib,zlib,"
+PACKAGECONFIG[bz2] = "--with-bz2lib,--without-bz2lib,${DEPENDS_BZIP2},"
+PACKAGECONFIG[xz] = "--with-lzma,--without-lzma,xz,"
+PACKAGECONFIG[openssl] = "--with-openssl,--without-openssl,openssl,"
+PACKAGECONFIG[libxml2] = "--with-xml2,--without-xml2,libxml2,"
+PACKAGECONFIG[expat] = "--with-expat,--without-expat,expat,"
+PACKAGECONFIG[lzo] = "--with-lzo2,--without-lzo2,lzo,"
+PACKAGECONFIG[nettle] = "--with-nettle,--without-nettle,nettle,"
+PACKAGECONFIG[lz4] = "--with-lz4,--without-lz4,lz4,"
+
+EXTRA_OECONF += "--enable-largefile"
+
+SRC_URI = "http://libarchive.org/downloads/libarchive-${PV}.tar.gz \
+           file://non-recursive-extract-and-list.patch \
+           file://bug1066.patch \
+"
+
+SRC_URI[md5sum] = "4038e366ca5b659dae3efcc744e72120"
+SRC_URI[sha256sum] = "ba7eb1781c9fbbae178c4c6bad1c6eb08edab9a1496c64833d1715d022b30e2e"
+
+inherit autotools update-alternatives pkgconfig
+
+CPPFLAGS += "-I${WORKDIR}/extra-includes"
+
+do_configure[cleandirs] += "${WORKDIR}/extra-includes"
+do_configure_prepend() {
+	# We just need the headers for some type constants, so no need to
+	# build all of e2fsprogs for the target
+	cp -R ${STAGING_INCDIR_NATIVE}/ext2fs ${WORKDIR}/extra-includes/
+}
+
+ALTERNATIVE_PRIORITY = "80"
+
+PACKAGES =+ "bsdtar"
+FILES_bsdtar = "${bindir}/bsdtar"
+
+ALTERNATIVE_bsdtar = "tar"
+ALTERNATIVE_LINK_NAME[tar] = "${base_bindir}/tar"
+ALTERNATIVE_TARGET[tar] = "${bindir}/bsdtar"
+
+PACKAGES =+ "bsdcpio"
+FILES_bsdcpio = "${bindir}/bsdcpio"
+
+ALTERNATIVE_bsdcpio = "cpio"
+ALTERNATIVE_LINK_NAME[cpio] = "${base_bindir}/cpio"
+ALTERNATIVE_TARGET[cpio] = "${bindir}/bsdcpio"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/libidn/libidn/0001-idn-fix-printf-format-security-warnings.patch b/poky/meta/recipes-extended/libidn/libidn/0001-idn-fix-printf-format-security-warnings.patch
deleted file mode 100644
index 2d5faab..0000000
--- a/poky/meta/recipes-extended/libidn/libidn/0001-idn-fix-printf-format-security-warnings.patch
+++ /dev/null
@@ -1,694 +0,0 @@
-From 7148adf34dae30345c2e4d9d437838a45ba6f6e8 Mon Sep 17 00:00:00 2001
-From: =?utf8?q?Tim=20R=C3=BChsen?= <tim.ruehsen@gmx.de>
-Date: Wed, 1 Feb 2017 11:06:39 +0100
-Subject: [PATCH] Fix -Wformat warnings
-
----
-Upstream-Status: Backport
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
- examples/example.c     |  6 +++---
- examples/example3.c    |  4 ++--
- examples/example4.c    |  4 ++--
- examples/example5.c    |  2 +-
- src/idn.c              |  2 +-
- tests/tst_idna.c       | 25 +++++++++++++------------
- tests/tst_idna2.c      |  8 ++++----
- tests/tst_idna3.c      |  8 ++++----
- tests/tst_nfkc.c       |  8 ++++----
- tests/tst_pr29.c       | 12 ++++++------
- tests/tst_punycode.c   | 13 +++++++------
- tests/tst_strerror.c   | 20 ++++++++++----------
- tests/tst_stringprep.c | 12 ++++++------
- tests/tst_tld.c        | 20 ++++++++++----------
- tests/utils.c          |  6 +++---
- 15 files changed, 76 insertions(+), 74 deletions(-)
-
-diff --git a/examples/example.c b/examples/example.c
-index 6e91783..24f64e0 100644
---- a/examples/example.c
-+++ b/examples/example.c
-@@ -55,7 +55,7 @@ main (void)
- 
-   printf ("Before locale2utf8 (length %ld): ", (long int) strlen (buf));
-   for (i = 0; i < strlen (buf); i++)
--    printf ("%02x ", buf[i] & 0xFF);
-+    printf ("%02x ", (unsigned) buf[i] & 0xFF);
-   printf ("\n");
- 
-   p = stringprep_locale_to_utf8 (buf);
-@@ -69,7 +69,7 @@ main (void)
- 
-   printf ("Before stringprep (length %ld): ", (long int) strlen (buf));
-   for (i = 0; i < strlen (buf); i++)
--    printf ("%02x ", buf[i] & 0xFF);
-+    printf ("%02x ", (unsigned) buf[i] & 0xFF);
-   printf ("\n");
- 
-   rc = stringprep (buf, BUFSIZ, 0, stringprep_nameprep);
-@@ -79,7 +79,7 @@ main (void)
-     {
-       printf ("After stringprep (length %ld): ", (long int) strlen (buf));
-       for (i = 0; i < strlen (buf); i++)
--	printf ("%02x ", buf[i] & 0xFF);
-+	printf ("%02x ", (unsigned) buf[i] & 0xFF);
-       printf ("\n");
-     }
- 
-diff --git a/examples/example3.c b/examples/example3.c
-index fc11c1c..ffb9042 100644
---- a/examples/example3.c
-+++ b/examples/example3.c
-@@ -56,7 +56,7 @@ main (void)
- 
-   printf ("Read string (length %ld): ", (long int) strlen (buf));
-   for (i = 0; i < strlen (buf); i++)
--    printf ("%02x ", buf[i] & 0xFF);
-+    printf ("%02x ", (unsigned) buf[i] & 0xFF);
-   printf ("\n");
- 
-   rc = idna_to_ascii_lz (buf, &p, 0);
-@@ -68,7 +68,7 @@ main (void)
- 
-   printf ("ACE label (length %ld): '%s'\n", (long int) strlen (p), p);
-   for (i = 0; i < strlen (p); i++)
--    printf ("%02x ", p[i] & 0xFF);
-+    printf ("%02x ", (unsigned) p[i] & 0xFF);
-   printf ("\n");
- 
-   free (p);
-diff --git a/examples/example4.c b/examples/example4.c
-index 1b319c9..a3315a1 100644
---- a/examples/example4.c
-+++ b/examples/example4.c
-@@ -56,7 +56,7 @@ main (void)
- 
-   printf ("Read string (length %ld): ", (long int) strlen (buf));
-   for (i = 0; i < strlen (buf); i++)
--    printf ("%02x ", buf[i] & 0xFF);
-+    printf ("%02x ", (unsigned) buf[i] & 0xFF);
-   printf ("\n");
- 
-   rc = idna_to_unicode_lzlz (buf, &p, 0);
-@@ -68,7 +68,7 @@ main (void)
- 
-   printf ("ACE label (length %ld): '%s'\n", (long int) strlen (p), p);
-   for (i = 0; i < strlen (p); i++)
--    printf ("%02x ", p[i] & 0xFF);
-+    printf ("%02x ", (unsigned) p[i] & 0xFF);
-   printf ("\n");
- 
-   free (p);
-diff --git a/examples/example5.c b/examples/example5.c
-index df55798..29d40b9 100644
---- a/examples/example5.c
-+++ b/examples/example5.c
-@@ -68,7 +68,7 @@ main (void)
- 
-   printf ("Read string (length %ld): ", (long int) strlen (buf));
-   for (i = 0; i < strlen (buf); i++)
--    printf ("%02x ", buf[i] & 0xFF);
-+    printf ("%02x ", (unsigned) buf[i] & 0xFF);
-   printf ("\n");
- 
-   p = stringprep_locale_to_utf8 (buf);
-diff --git a/src/idn.c b/src/idn.c
-index be1c7d1..13eb3c9 100644
---- a/src/idn.c
-+++ b/src/idn.c
-@@ -419,7 +419,7 @@ main (int argc, char *argv[])
- 	      size_t i;
- 	      for (i = 0; p[i]; i++)
- 		fprintf (stderr, "output[%lu] = U+%04x\n",
--			 (unsigned long) i, p[i]);
-+			 (unsigned long) i, (unsigned) p[i]);
- 	    }
- 
- 	  fprintf (stdout, "%s\n", p);
-diff --git a/tests/tst_idna.c b/tests/tst_idna.c
-index 415764e..4ac046f 100644
---- a/tests/tst_idna.c
-+++ b/tests/tst_idna.c
-@@ -220,13 +220,14 @@ doit (void)
-   char label[100];
-   uint32_t *ucs4label = NULL;
-   uint32_t tmp[100];
--  size_t len, len2, i;
-+  size_t len, len2;
-   int rc;
-+  unsigned i;
- 
-   for (i = 0; i < sizeof (idna) / sizeof (idna[0]); i++)
-     {
-       if (debug)
--	printf ("IDNA entry %ld: %s\n", i, idna[i].name);
-+	printf ("IDNA entry %u: %s\n", i, idna[i].name);
- 
-       if (debug)
- 	{
-@@ -237,7 +238,7 @@ doit (void)
-       rc = idna_to_ascii_4i (idna[i].in, idna[i].inlen, label, idna[i].flags);
-       if (rc != idna[i].toasciirc)
- 	{
--	  fail ("IDNA entry %ld failed: %d\n", i, rc);
-+	  fail ("IDNA entry %u failed: %d\n", i, rc);
- 	  if (debug)
- 	    printf ("FATAL\n");
- 	  continue;
-@@ -256,7 +257,7 @@ doit (void)
- 	  if (strlen (idna[i].out) != strlen (label) ||
- 	      strcasecmp (idna[i].out, label) != 0)
- 	    {
--	      fail ("IDNA entry %ld failed\n", i);
-+	      fail ("IDNA entry %u failed\n", i);
- 	      if (debug)
- 		printf ("ERROR\n");
- 	    }
-@@ -273,8 +274,8 @@ doit (void)
- 
-       if (debug)
- 	{
--	  printf ("in: %s (%ld==%ld)\n", idna[i].out, strlen (idna[i].out),
--		  len);
-+	  printf ("in: %s (%d==%d)\n", idna[i].out, (int) strlen (idna[i].out),
-+		  (int) len);
- 	  ucs4print (ucs4label, len);
- 	}
- 
-@@ -282,20 +283,20 @@ doit (void)
-       rc = idna_to_unicode_44i (ucs4label, len, tmp, &len2, idna[i].flags);
-       if (debug)
- 	{
--	  printf ("expected out (%ld):\n",
-+	  printf ("expected out (%lu):\n",
- 		  rc == IDNA_SUCCESS ? idna[i].inlen : len);
- 	  if (rc == IDNA_SUCCESS)
- 	    ucs4print (idna[i].in, idna[i].inlen);
- 	  else
- 	    ucs4print (ucs4label, len);
- 
--	  printf ("computed out (%ld):\n", len2);
-+	  printf ("computed out (%d):\n", (int) len2);
- 	  ucs4print (tmp, len2);
- 	}
- 
-       if (rc != idna[i].tounicoderc)
- 	{
--	  fail ("IDNA entry %ld failed: %d\n", i, rc);
-+	  fail ("IDNA entry %u failed: %d\n", i, rc);
- 	  if (debug)
- 	    printf ("FATAL\n");
- 	  continue;
-@@ -309,11 +310,11 @@ doit (void)
- 	  if (debug)
- 	    {
- 	      if (rc == IDNA_SUCCESS)
--		printf ("len=%ld len2=%ld\n", len2, idna[i].inlen);
-+		printf ("len=%d len2=%d\n", (int) len2, (int) idna[i].inlen);
- 	      else
--		printf ("len=%ld len2=%ld\n", len, len2);
-+		printf ("len=%d len2=%d\n", (int) len, (int) len2);
- 	    }
--	  fail ("IDNA entry %ld failed\n", i);
-+	  fail ("IDNA entry %u failed\n", i);
- 	  if (debug)
- 	    printf ("ERROR\n");
- 	}
-diff --git a/tests/tst_idna2.c b/tests/tst_idna2.c
-index 65b3a4d..38932ca 100644
---- a/tests/tst_idna2.c
-+++ b/tests/tst_idna2.c
-@@ -461,14 +461,14 @@ static const struct idna idna[] = {
- void
- doit (void)
- {
--  size_t i;
-+  unsigned i;
-   char *out;
-   int rc;
- 
-   for (i = 0; i < sizeof (idna) / sizeof (idna[0]); i++)
-     {
-       if (debug)
--	printf ("IDNA2 entry %ld\n", i);
-+	printf ("IDNA2 entry %u\n", i);
- 
-       if (debug)
- 	{
-@@ -487,7 +487,7 @@ doit (void)
- 			     IDNA_USE_STD3_ASCII_RULES);
-       if (rc != IDNA_SUCCESS && strlen (idna[i].out) > 0)
- 	{
--	  fail ("IDNA2 entry %ld failed: %d\n", i, rc);
-+	  fail ("IDNA2 entry %u failed: %d\n", i, rc);
- 	  continue;
- 	}
- 
-@@ -504,7 +504,7 @@ doit (void)
- 	  if (strlen (idna[i].out) != strlen (out) ||
- 	      strcasecmp (idna[i].out, out) != 0)
- 	    {
--	      fail ("IDNA2 entry %ld failed\n", i);
-+	      fail ("IDNA2 entry %u failed\n", i);
- 	      if (debug)
- 		printf ("ERROR\n");
- 	    }
-diff --git a/tests/tst_idna3.c b/tests/tst_idna3.c
-index a189378..f65628c 100644
---- a/tests/tst_idna3.c
-+++ b/tests/tst_idna3.c
-@@ -59,13 +59,13 @@ doit (void)
- {
-   int rc;
-   char *out = NULL;
--  size_t i;
-+  unsigned i;
- 
-   for (i = 0; i < sizeof (idna) / sizeof (idna[0]); i++)
-     {
-       rc = idna_to_unicode_8z8z (idna[i].in, &out, 0);
-       if (rc != IDNA_SUCCESS)
--	fail ("IDNA3[%ld] failed %d\n", i, rc);
-+	fail ("IDNA3[%u] failed %d\n", i, rc);
- 
-       if (debug && rc == IDNA_SUCCESS)
- 	{
-@@ -75,9 +75,9 @@ doit (void)
- 	}
- 
-       if (strcmp (out, idna[i].out) != 0)
--	fail ("IDNA3[%ld] failed\n", i);
-+	fail ("IDNA3[%u] failed\n", i);
-       else if (debug)
--	printf ("IDNA3[%ld] success\n", i);
-+	printf ("IDNA3[%u] success\n", i);
- 
-       if (out)
- 	idn_free (out);
-diff --git a/tests/tst_nfkc.c b/tests/tst_nfkc.c
-index d150fec..f5af9c6 100644
---- a/tests/tst_nfkc.c
-+++ b/tests/tst_nfkc.c
-@@ -68,18 +68,18 @@ void
- doit (void)
- {
-   char *out;
--  size_t i;
-+  unsigned i;
- 
-   for (i = 0; i < sizeof (nfkc) / sizeof (nfkc[0]); i++)
-     {
-       if (debug)
--	printf ("NFKC entry %ld\n", i);
-+	printf ("NFKC entry %u\n", i);
- 
-       out = stringprep_utf8_nfkc_normalize (nfkc[i].in,
- 					    (ssize_t) strlen (nfkc[i].in));
-       if (out == NULL)
- 	{
--	  fail ("NFKC entry %ld failed fatally\n", i);
-+	  fail ("NFKC entry %u failed fatally\n", i);
- 	  continue;
- 	}
- 
-@@ -114,7 +114,7 @@ doit (void)
-       if (strlen (nfkc[i].out) != strlen (out) ||
- 	  memcmp (nfkc[i].out, out, strlen (out)) != 0)
- 	{
--	  fail ("NFKC entry %ld failed\n", i);
-+	  fail ("NFKC entry %u failed\n", i);
- 	  if (debug)
- 	    printf ("ERROR\n");
- 	}
-diff --git a/tests/tst_pr29.c b/tests/tst_pr29.c
-index 3dc5466..11d0ede 100644
---- a/tests/tst_pr29.c
-+++ b/tests/tst_pr29.c
-@@ -91,7 +91,7 @@ static const struct tv tv[] = {
- void
- doit (void)
- {
--  size_t i;
-+  unsigned i;
-   int rc;
- 
-   for (i = 0; i < sizeof (tv) / sizeof (tv[0]); i++)
-@@ -100,7 +100,7 @@ doit (void)
- 	{
- 	  uint32_t *p, *q;
- 
--	  printf ("PR29 entry %ld: %s\n", i, tv[i].name);
-+	  printf ("PR29 entry %u: %s\n", i, tv[i].name);
- 
- 	  printf ("in:\n");
- 	  ucs4print (tv[i].in, tv[i].inlen);
-@@ -120,7 +120,7 @@ doit (void)
-       rc = pr29_4 (tv[i].in, tv[i].inlen);
-       if (rc != tv[i].rc)
- 	{
--	  fail ("PR29 entry %ld failed (expected %d): %d\n", i, tv[i].rc, rc);
-+	  fail ("PR29 entry %u failed (expected %d): %d\n", i, tv[i].rc, rc);
- 	  if (debug)
- 	    printf ("FATAL\n");
- 	  continue;
-@@ -129,7 +129,7 @@ doit (void)
-       rc = pr29_4z (tv[i].in);
-       if (rc != tv[i].rc)
- 	{
--	  fail ("PR29 entry %ld failed (expected %d): %d\n", i, tv[i].rc, rc);
-+	  fail ("PR29 entry %u failed (expected %d): %d\n", i, tv[i].rc, rc);
- 	  if (debug)
- 	    printf ("FATAL\n");
- 	  continue;
-@@ -142,7 +142,7 @@ doit (void)
- 	p = stringprep_ucs4_to_utf8 (tv[i].in, (ssize_t) tv[i].inlen,
- 				     &items_read, &items_written);
- 	if (p == NULL)
--	  fail ("FAIL: stringprep_ucs4_to_utf8(tv[%ld]) == NULL\n", i);
-+	  fail ("FAIL: stringprep_ucs4_to_utf8(tv[%u]) == NULL\n", i);
- 	if (debug)
- 	  hexprint (p, strlen (p));
- 
-@@ -150,7 +150,7 @@ doit (void)
- 	free (p);
- 	if (rc != tv[i].rc)
- 	  {
--	    fail ("PR29 entry %ld failed (expected %d): %d\n",
-+	    fail ("PR29 entry %u failed (expected %d): %d\n",
- 		  i, tv[i].rc, rc);
- 	    if (debug)
- 	      printf ("FATAL\n");
-diff --git a/tests/tst_punycode.c b/tests/tst_punycode.c
-index 493b8a2..997744a 100644
---- a/tests/tst_punycode.c
-+++ b/tests/tst_punycode.c
-@@ -173,7 +173,8 @@ doit (void)
-   char *p;
-   uint32_t *q;
-   int rc;
--  size_t i, outlen;
-+  size_t outlen;
-+  unsigned i;
- 
-   p = malloc (sizeof (*p) * BUFSIZ);
-   if (p == NULL)
-@@ -186,7 +187,7 @@ doit (void)
-   for (i = 0; i < sizeof (punycode) / sizeof (punycode[0]); i++)
-     {
-       if (debug)
--	printf ("PUNYCODE entry %ld: %s\n", i, punycode[i].name);
-+	printf ("PUNYCODE entry %u: %s\n", i, punycode[i].name);
- 
-       if (debug)
- 	{
-@@ -199,7 +200,7 @@ doit (void)
- 			    NULL, &outlen, p);
-       if (rc != punycode[i].rc)
- 	{
--	  fail ("punycode_encode() entry %ld failed: %d\n", i, rc);
-+	  fail ("punycode_encode() entry %u failed: %d\n", i, rc);
- 	  if (debug)
- 	    printf ("FATAL\n");
- 	  continue;
-@@ -221,7 +222,7 @@ doit (void)
- 	  if (strlen (punycode[i].out) != strlen (p) ||
- 	      memcmp (punycode[i].out, p, strlen (p)) != 0)
- 	    {
--	      fail ("punycode() entry %ld failed\n", i);
-+	      fail ("punycode() entry %u failed\n", i);
- 	      if (debug)
- 		printf ("ERROR\n");
- 	    }
-@@ -241,7 +242,7 @@ doit (void)
- 			    &outlen, q, NULL);
-       if (rc != punycode[i].rc)
- 	{
--	  fail ("punycode() entry %ld failed: %d\n", i, rc);
-+	  fail ("punycode() entry %u failed: %d\n", i, rc);
- 	  if (debug)
- 	    printf ("FATAL\n");
- 	  continue;
-@@ -262,7 +263,7 @@ doit (void)
- 	  if (punycode[i].inlen != outlen ||
- 	      memcmp (punycode[i].in, q, outlen) != 0)
- 	    {
--	      fail ("punycode_decode() entry %ld failed\n", i);
-+	      fail ("punycode_decode() entry %u failed\n", i);
- 	      if (debug)
- 		printf ("ERROR\n");
- 	    }
-diff --git a/tests/tst_strerror.c b/tests/tst_strerror.c
-index 71fff59..730f5e4 100644
---- a/tests/tst_strerror.c
-+++ b/tests/tst_strerror.c
-@@ -110,7 +110,7 @@ doit (void)
-   /* Iterate through all error codes. */
- 
-   {
--    size_t i;
-+    unsigned i;
-     const char *last_p = NULL;
- 
-     for (i = 0;; i++)
-@@ -126,13 +126,13 @@ doit (void)
- 	    break;
- 	  }
- 	if (debug)
--	  printf ("idna %ld: %s\n", i, p);
-+	  printf ("idna %u: %s\n", i, p);
- 	last_p = p;
-       }
-   }
- 
-   {
--    size_t i;
-+    unsigned i;
-     const char *last_p = NULL;
- 
-     for (i = 0;; i++)
-@@ -141,13 +141,13 @@ doit (void)
- 	if (p == last_p)
- 	  break;
- 	if (debug)
--	  printf ("pr29 %ld: %s\n", i, p);
-+	  printf ("pr29 %u: %s\n", i, p);
- 	last_p = p;
-       }
-   }
- 
-   {
--    size_t i;
-+    unsigned i;
-     const char *last_p = NULL;
- 
-     for (i = 0;; i++)
-@@ -156,13 +156,13 @@ doit (void)
- 	if (p == last_p)
- 	  break;
- 	if (debug)
--	  printf ("punycode %ld: %s\n", i, p);
-+	  printf ("punycode %u: %s\n", i, p);
- 	last_p = p;
-       }
-   }
- 
-   {
--    size_t i;
-+    unsigned i;
-     const char *last_p = NULL;
- 
-     for (i = 0;; i++)
-@@ -183,13 +183,13 @@ doit (void)
- 	    break;
- 	  }
- 	if (debug)
--	  printf ("stringprep %ld: %s\n", i, p);
-+	  printf ("stringprep %u: %s\n", i, p);
- 	last_p = p;
-       }
-   }
- 
-   {
--    size_t i;
-+    unsigned i;
-     const char *last_p = NULL;
- 
-     for (i = 0;; i++)
-@@ -198,7 +198,7 @@ doit (void)
- 	if (p == last_p)
- 	  break;
- 	if (debug)
--	  printf ("tld %ld: %s\n", i, p);
-+	  printf ("tld %u: %s\n", i, p);
- 	last_p = p;
-       }
-   }
-diff --git a/tests/tst_stringprep.c b/tests/tst_stringprep.c
-index 149ce6f..7c9ab06 100644
---- a/tests/tst_stringprep.c
-+++ b/tests/tst_stringprep.c
-@@ -205,7 +205,7 @@ doit (void)
- {
-   char *p;
-   int rc;
--  size_t i;
-+  unsigned i;
- 
-   if (!stringprep_check_version (STRINGPREP_VERSION))
-     fail ("stringprep_check_version failed (header %s runtime %s)\n",
-@@ -224,7 +224,7 @@ doit (void)
-   for (i = 0; i < sizeof (strprep) / sizeof (strprep[0]); i++)
-     {
-       if (debug)
--	printf ("STRINGPREP entry %ld\n", i);
-+	printf ("STRINGPREP entry %u\n", i);
- 
-       if (debug)
- 	{
-@@ -247,12 +247,12 @@ doit (void)
- 	  continue;
- 	else if (l == NULL)
- 	  {
--	    fail ("bad UTF-8 in entry %ld\n", i);
-+	    fail ("bad UTF-8 in entry %u\n", i);
- 	    continue;
- 	  }
- 	else if (strcmp (strprep[i].in, x) != 0)
- 	  {
--	    fail ("bad UTF-8 in entry %ld\n", i);
-+	    fail ("bad UTF-8 in entry %u\n", i);
- 	    if (debug)
- 	      {
- 		puts ("expected:");
-@@ -274,7 +274,7 @@ doit (void)
- 			       "Nameprep", strprep[i].flags);
-       if (rc != strprep[i].rc)
- 	{
--	  fail ("stringprep() entry %ld failed: %d\n", i, rc);
-+	  fail ("stringprep() entry %u failed: %d\n", i, rc);
- 	  if (debug)
- 	    printf ("FATAL\n");
- 	  if (rc == STRINGPREP_OK)
-@@ -302,7 +302,7 @@ doit (void)
- 	  if (strlen (strprep[i].out) != strlen (p) ||
- 	      memcmp (strprep[i].out, p, strlen (p)) != 0)
- 	    {
--	      fail ("stringprep() entry %ld failed\n", i);
-+	      fail ("stringprep() entry %ld failed\n", (long) i);
- 	      if (debug)
- 		printf ("ERROR\n");
- 	    }
-diff --git a/tests/tst_tld.c b/tests/tst_tld.c
-index 2f8e12e..d038c79 100644
---- a/tests/tst_tld.c
-+++ b/tests/tst_tld.c
-@@ -80,7 +80,7 @@ const Tld_table * my_tld_tables[] =
- void
- doit (void)
- {
--  size_t i;
-+  unsigned i;
-   const Tld_table *tldtable;
-   char *out;
-   size_t errpos;
-@@ -206,7 +206,7 @@ doit (void)
-   for (i = 0; i < sizeof (tld) / sizeof (tld[0]); i++)
-     {
-       if (debug)
--	printf ("TLD entry %ld: %s\n", i, tld[i].name);
-+	printf ("TLD entry %u: %s\n", i, tld[i].name);
- 
-       if (debug)
- 	{
-@@ -217,7 +217,7 @@ doit (void)
-       tldtable = tld_default_table (tld[i].tld, NULL);
-       if (tldtable == NULL)
- 	{
--	  fail ("TLD entry %ld tld_get_table (%s)\n", i, tld[i].tld);
-+	  fail ("TLD entry %u tld_get_table (%s)\n", i, tld[i].tld);
- 	  if (debug)
- 	    printf ("FATAL\n");
- 	  continue;
-@@ -226,7 +226,7 @@ doit (void)
-       rc = tld_check_4t (tld[i].in, tld[i].inlen, &errpos, tldtable);
-       if (rc != tld[i].rc)
- 	{
--	  fail ("TLD entry %ld failed: %d\n", i, rc);
-+	  fail ("TLD entry %u failed: %d\n", i, rc);
- 	  if (debug)
- 	    printf ("FATAL\n");
- 	  continue;
-@@ -237,7 +237,7 @@ doit (void)
- 
-       if (rc != tld[i].rc)
- 	{
--	  fail ("TLD entry %ld failed\n", i);
-+	  fail ("TLD entry %u failed\n", i);
- 	  if (debug)
- 	    printf ("ERROR\n");
- 	}
-@@ -245,12 +245,12 @@ doit (void)
- 	{
- 	  if (debug)
- 	    printf ("returned errpos %ld expected errpos %ld\n",
--		    errpos, tld[i].errpos);
-+		    (long) errpos, (long) tld[i].errpos);
- 
- 	  if (tld[i].errpos != errpos)
- 	    {
--	      fail ("TLD entry %ld failed because errpos %ld != %ld\n", i,
--		    tld[i].errpos, errpos);
-+	      fail ("TLD entry %u failed because errpos %ld != %ld\n", i,
-+		    (long) tld[i].errpos, (long) errpos);
- 	      if (debug)
- 		printf ("ERROR\n");
- 	    }
-@@ -262,12 +262,12 @@ doit (void)
- 	rc = tld_check_8z (tld[i].example, &errpos, NULL);
- 	if (rc != tld[i].rc)
- 	  {
--	    fail ("TLD entry %ld failed\n", i);
-+	    fail ("TLD entry %u failed\n", i);
- 	    if (debug)
- 	      printf ("ERROR\n");
- 	  }
- 	if (debug)
--	  printf ("TLD entry %ld tld_check_8z (%s)\n", i, tld[i].example);
-+	  printf ("TLD entry %u tld_check_8z (%s)\n", i, tld[i].example);
-       }
-     }
- }
-diff --git a/tests/utils.c b/tests/utils.c
-index 717ee01..5577dc3 100644
---- a/tests/utils.c
-+++ b/tests/utils.c
-@@ -49,7 +49,7 @@ escapeprint (const char *str, size_t len)
- {
-   size_t i;
- 
--  printf (" (length %ld bytes):\n\t", len);
-+  printf (" (length %ld bytes):\n\t", (long) len);
-   for (i = 0; i < len; i++)
-     {
-       if (((str[i] & 0xFF) >= 'A' && (str[i] & 0xFF) <= 'Z') ||
-@@ -58,7 +58,7 @@ escapeprint (const char *str, size_t len)
- 	  || (str[i] & 0xFF) == ' ' || (str[i] & 0xFF) == '.')
- 	printf ("%c", (str[i] & 0xFF));
-       else
--	printf ("\\x%02X", (str[i] & 0xFF));
-+	printf ("\\x%02X", (unsigned) (str[i] & 0xFF));
-       if ((i + 1) % 16 == 0 && (i + 1) < len)
- 	printf ("'\n\t'");
-     }
-@@ -73,7 +73,7 @@ hexprint (const char *str, size_t len)
-   printf ("\t;; ");
-   for (i = 0; i < len; i++)
-     {
--      printf ("%02x ", (str[i] & 0xFF));
-+      printf ("%02x ", (unsigned) (str[i] & 0xFF));
-       if ((i + 1) % 8 == 0)
- 	printf (" ");
-       if ((i + 1) % 16 == 0 && i + 1 < len)
--- 
-1.9.1
-
diff --git a/poky/meta/recipes-extended/libidn/libidn/avoid_AM_PROG_MKDIR_P_warning_error_with_automake_1.12.patch b/poky/meta/recipes-extended/libidn/libidn/avoid_AM_PROG_MKDIR_P_warning_error_with_automake_1.12.patch
index 98ba4d6..43bd232 100644
--- a/poky/meta/recipes-extended/libidn/libidn/avoid_AM_PROG_MKDIR_P_warning_error_with_automake_1.12.patch
+++ b/poky/meta/recipes-extended/libidn/libidn/avoid_AM_PROG_MKDIR_P_warning_error_with_automake_1.12.patch
@@ -1,25 +1,34 @@
-Upstream-Status: Inappropriate 
+From cdd9e2e960eeb4eda7b08f0113d0cd03524c1d45 Mon Sep 17 00:00:00 2001
+From: Nitin A Kamble <nitin.a.kamble@intel.com>
+Date: Tue, 10 Jul 2012 02:44:30 -0700
+Subject: [PATCH] libidn: fix build with automake 1.12
+
+Upstream-Status: Inappropriate
 
 automake 1.12.x has deprecated AM_PROG_MKDIR_P , and throws a warning for that,
 and the warnings are treated as errors because of the -Werror parameter.
 
-These AM_PROG_MKDIR_P are coming from gettext, and the latest gettext code has not 
+These AM_PROG_MKDIR_P are coming from gettext, and the latest gettext code has not
 eliminated these deprecated macros yet. So disable the treatment of warnings
 as errors until gettext is updated to remove the deprecated macros.
 
 Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
 2012/07/10
 
-Index: libidn-1.24/configure.ac
-===================================================================
---- libidn-1.24.orig/configure.ac
-+++ libidn-1.24/configure.ac
-@@ -23,7 +23,7 @@ AC_COPYRIGHT([Copyright (c) 2002-2011 Si
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index 261dad2..c4f935e 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -22,7 +22,7 @@ AC_INIT([GNU Libidn], [1.34], [bug-libidn@gnu.org])
  AC_CONFIG_AUX_DIR([build-aux])
  AC_CONFIG_MACRO_DIR([m4])
  AC_CONFIG_HEADERS(config.h)
 -AM_INIT_AUTOMAKE([1.10 -Wall -Werror -Wno-override])
 +AM_INIT_AUTOMAKE([1.10 -Wall -Wno-override])
- AM_SILENT_RULES([yes])
+ m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
  
  # Library code modified:                              REVISION++
diff --git a/poky/meta/recipes-extended/libidn/libidn/gcc7-compatibility.patch b/poky/meta/recipes-extended/libidn/libidn/gcc7-compatibility.patch
deleted file mode 100644
index 546a6ea..0000000
--- a/poky/meta/recipes-extended/libidn/libidn/gcc7-compatibility.patch
+++ /dev/null
@@ -1,334 +0,0 @@
-From 230930b3bc3e431b819eb45420cb42475d83ca93 Mon Sep 17 00:00:00 2001
-From: =?utf8?q?Tim=20R=C3=BChsen?= <tim.ruehsen@gmx.de>
-Date: Wed, 1 Feb 2017 10:44:36 +0100
-Subject: [PATCH] Update intprops.h for gcc-7 compatibility
-
----
-Upstream-Status: Backport
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
- gl/intprops.h          | 65 ++++++++++++++++++++++++++++++--------------------
- lib/gltests/intprops.h | 65 ++++++++++++++++++++++++++++++--------------------
- 2 files changed, 78 insertions(+), 52 deletions(-)
-
-diff --git a/gl/intprops.h b/gl/intprops.h
-index e1fce5c..eb06b69 100644
---- a/gl/intprops.h
-+++ b/gl/intprops.h
-@@ -1,18 +1,18 @@
- /* intprops.h -- properties of integer types
- 
--   Copyright (C) 2001-2016 Free Software Foundation, Inc.
-+   Copyright (C) 2001-2017 Free Software Foundation, Inc.
- 
-    This program is free software: you can redistribute it and/or modify it
--   under the terms of the GNU General Public License as published
--   by the Free Software Foundation; either version 3 of the License, or
-+   under the terms of the GNU Lesser General Public License as published
-+   by the Free Software Foundation; either version 2.1 of the License, or
-    (at your option) any later version.
- 
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
--   GNU General Public License for more details.
-+   GNU Lesser General Public License for more details.
- 
--   You should have received a copy of the GNU General Public License
-+   You should have received a copy of the GNU Lesser General Public License
-    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
- 
- /* Written by Paul Eggert.  */
-@@ -47,12 +47,16 @@
- 
- /* Minimum and maximum values for integer types and expressions.  */
- 
-+/* The width in bits of the integer type or expression T.
-+   Padding bits are not supported; this is checked at compile-time below.  */
-+#define TYPE_WIDTH(t) (sizeof (t) * CHAR_BIT)
-+
- /* The maximum and minimum values for the integer type T.  */
- #define TYPE_MINIMUM(t) ((t) ~ TYPE_MAXIMUM (t))
- #define TYPE_MAXIMUM(t)                                                 \
-   ((t) (! TYPE_SIGNED (t)                                               \
-         ? (t) -1                                                        \
--        : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
-+        : ((((t) 1 << (TYPE_WIDTH (t) - 2)) - 1) * 2 + 1)))
- 
- /* The maximum and minimum values for the type of the expression E,
-    after integer promotion.  E should not have side effects.  */
-@@ -65,7 +69,13 @@
-    ? _GL_SIGNED_INT_MAXIMUM (e)                                         \
-    : _GL_INT_NEGATE_CONVERT (e, 1))
- #define _GL_SIGNED_INT_MAXIMUM(e)                                       \
--  (((_GL_INT_CONVERT (e, 1) << (sizeof ((e) + 0) * CHAR_BIT - 2)) - 1) * 2 + 1)
-+  (((_GL_INT_CONVERT (e, 1) << (TYPE_WIDTH ((e) + 0) - 2)) - 1) * 2 + 1)
-+
-+/* Work around OpenVMS incompatibility with C99.  */
-+#if !defined LLONG_MAX && defined __INT64_MAX
-+# define LLONG_MAX __INT64_MAX
-+# define LLONG_MIN __INT64_MIN
-+#endif
- 
- /* This include file assumes that signed types are two's complement without
-    padding bits; the above macros have undefined behavior otherwise.
-@@ -84,10 +94,15 @@ verify (TYPE_MAXIMUM (long int) == LONG_MAX);
- verify (TYPE_MINIMUM (long long int) == LLONG_MIN);
- verify (TYPE_MAXIMUM (long long int) == LLONG_MAX);
- #endif
-+/* Similarly, sanity-check one ISO/IEC TS 18661-1:2014 macro if defined.  */
-+#ifdef UINT_WIDTH
-+verify (TYPE_WIDTH (unsigned int) == UINT_WIDTH);
-+#endif
- 
- /* Does the __typeof__ keyword work?  This could be done by
-    'configure', but for now it's easier to do it by hand.  */
--#if (2 <= __GNUC__ || defined __IBM__TYPEOF__ \
-+#if (2 <= __GNUC__ \
-+     || (1210 <= __IBMC__ && defined __IBM__TYPEOF__) \
-      || (0x5110 <= __SUNPRO_C && !__STDC__))
- # define _GL_HAVE___TYPEOF__ 1
- #else
-@@ -116,8 +131,7 @@ verify (TYPE_MAXIMUM (long long int) == LLONG_MAX);
-    signed, this macro may overestimate the true bound by one byte when
-    applied to unsigned types of size 2, 4, 16, ... bytes.  */
- #define INT_STRLEN_BOUND(t)                                     \
--  (INT_BITS_STRLEN_BOUND (sizeof (t) * CHAR_BIT                 \
--                          - _GL_SIGNED_TYPE_OR_EXPR (t))        \
-+  (INT_BITS_STRLEN_BOUND (TYPE_WIDTH (t) - _GL_SIGNED_TYPE_OR_EXPR (t)) \
-    + _GL_SIGNED_TYPE_OR_EXPR (t))
- 
- /* Bound on buffer size needed to represent an integer type or expression T,
-@@ -222,20 +236,23 @@ verify (TYPE_MAXIMUM (long long int) == LLONG_MAX);
-    ? (a) < (min) >> (b)                                 \
-    : (max) >> (b) < (a))
- 
--/* True if __builtin_add_overflow (A, B, P) works when P is null.  */
--#define _GL_HAS_BUILTIN_OVERFLOW_WITH_NULL (7 <= __GNUC__)
-+/* True if __builtin_add_overflow (A, B, P) works when P is non-null.  */
-+#define _GL_HAS_BUILTIN_OVERFLOW (5 <= __GNUC__)
-+
-+/* True if __builtin_add_overflow_p (A, B, C) works.  */
-+#define _GL_HAS_BUILTIN_OVERFLOW_P (7 <= __GNUC__)
- 
- /* The _GL*_OVERFLOW macros have the same restrictions as the
-    *_RANGE_OVERFLOW macros, except that they do not assume that operands
-    (e.g., A and B) have the same type as MIN and MAX.  Instead, they assume
-    that the result (e.g., A + B) has that type.  */
--#if _GL_HAS_BUILTIN_OVERFLOW_WITH_NULL
--# define _GL_ADD_OVERFLOW(a, b, min, max)
--   __builtin_add_overflow (a, b, (__typeof__ ((a) + (b)) *) 0)
--# define _GL_SUBTRACT_OVERFLOW(a, b, min, max)
--   __builtin_sub_overflow (a, b, (__typeof__ ((a) - (b)) *) 0)
--# define _GL_MULTIPLY_OVERFLOW(a, b, min, max)
--   __builtin_mul_overflow (a, b, (__typeof__ ((a) * (b)) *) 0)
-+#if _GL_HAS_BUILTIN_OVERFLOW_P
-+# define _GL_ADD_OVERFLOW(a, b, min, max)                               \
-+   __builtin_add_overflow_p (a, b, (__typeof__ ((a) + (b))) 0)
-+# define _GL_SUBTRACT_OVERFLOW(a, b, min, max)                          \
-+   __builtin_sub_overflow_p (a, b, (__typeof__ ((a) - (b))) 0)
-+# define _GL_MULTIPLY_OVERFLOW(a, b, min, max)                          \
-+   __builtin_mul_overflow_p (a, b, (__typeof__ ((a) * (b))) 0)
- #else
- # define _GL_ADD_OVERFLOW(a, b, min, max)                                \
-    ((min) < 0 ? INT_ADD_RANGE_OVERFLOW (a, b, min, max)                  \
-@@ -315,7 +332,7 @@ verify (TYPE_MAXIMUM (long long int) == LLONG_MAX);
-   _GL_BINARY_OP_OVERFLOW (a, b, _GL_ADD_OVERFLOW)
- #define INT_SUBTRACT_OVERFLOW(a, b) \
-   _GL_BINARY_OP_OVERFLOW (a, b, _GL_SUBTRACT_OVERFLOW)
--#if _GL_HAS_BUILTIN_OVERFLOW_WITH_NULL
-+#if _GL_HAS_BUILTIN_OVERFLOW_P
- # define INT_NEGATE_OVERFLOW(a) INT_SUBTRACT_OVERFLOW (0, a)
- #else
- # define INT_NEGATE_OVERFLOW(a) \
-@@ -349,10 +366,6 @@ verify (TYPE_MAXIMUM (long long int) == LLONG_MAX);
- #define INT_MULTIPLY_WRAPV(a, b, r) \
-   _GL_INT_OP_WRAPV (a, b, r, *, __builtin_mul_overflow, INT_MULTIPLY_OVERFLOW)
- 
--#ifndef __has_builtin
--# define __has_builtin(x) 0
--#endif
--
- /* Nonzero if this compiler has GCC bug 68193 or Clang bug 25390.  See:
-    https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68193
-    https://llvm.org/bugs/show_bug.cgi?id=25390
-@@ -369,7 +382,7 @@ verify (TYPE_MAXIMUM (long long int) == LLONG_MAX);
-    the operation.  BUILTIN is the builtin operation, and OVERFLOW the
-    overflow predicate.  Return 1 if the result overflows.  See above
-    for restrictions.  */
--#if 5 <= __GNUC__ || __has_builtin (__builtin_add_overflow)
-+#if _GL_HAS_BUILTIN_OVERFLOW
- # define _GL_INT_OP_WRAPV(a, b, r, op, builtin, overflow) builtin (a, b, r)
- #elif 201112 <= __STDC_VERSION__ && !_GL__GENERIC_BOGUS
- # define _GL_INT_OP_WRAPV(a, b, r, op, builtin, overflow) \
-@@ -412,7 +425,7 @@ verify (TYPE_MAXIMUM (long long int) == LLONG_MAX);
- # else
- #  define _GL_INT_OP_WRAPV_LONGISH(a, b, r, op, overflow) \
-     _GL_INT_OP_CALC (a, b, r, op, overflow, unsigned long int, \
--                     long int, LONG_MIN, LONG_MAX))
-+                     long int, LONG_MIN, LONG_MAX)
- # endif
- #endif
- 
-diff --git a/lib/gltests/intprops.h b/lib/gltests/intprops.h
-index e1fce5c..eb06b69 100644
---- a/lib/gltests/intprops.h
-+++ b/lib/gltests/intprops.h
-@@ -1,18 +1,18 @@
- /* intprops.h -- properties of integer types
- 
--   Copyright (C) 2001-2016 Free Software Foundation, Inc.
-+   Copyright (C) 2001-2017 Free Software Foundation, Inc.
- 
-    This program is free software: you can redistribute it and/or modify it
--   under the terms of the GNU General Public License as published
--   by the Free Software Foundation; either version 3 of the License, or
-+   under the terms of the GNU Lesser General Public License as published
-+   by the Free Software Foundation; either version 2.1 of the License, or
-    (at your option) any later version.
- 
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
--   GNU General Public License for more details.
-+   GNU Lesser General Public License for more details.
- 
--   You should have received a copy of the GNU General Public License
-+   You should have received a copy of the GNU Lesser General Public License
-    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
- 
- /* Written by Paul Eggert.  */
-@@ -47,12 +47,16 @@
- 
- /* Minimum and maximum values for integer types and expressions.  */
- 
-+/* The width in bits of the integer type or expression T.
-+   Padding bits are not supported; this is checked at compile-time below.  */
-+#define TYPE_WIDTH(t) (sizeof (t) * CHAR_BIT)
-+
- /* The maximum and minimum values for the integer type T.  */
- #define TYPE_MINIMUM(t) ((t) ~ TYPE_MAXIMUM (t))
- #define TYPE_MAXIMUM(t)                                                 \
-   ((t) (! TYPE_SIGNED (t)                                               \
-         ? (t) -1                                                        \
--        : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
-+        : ((((t) 1 << (TYPE_WIDTH (t) - 2)) - 1) * 2 + 1)))
- 
- /* The maximum and minimum values for the type of the expression E,
-    after integer promotion.  E should not have side effects.  */
-@@ -65,7 +69,13 @@
-    ? _GL_SIGNED_INT_MAXIMUM (e)                                         \
-    : _GL_INT_NEGATE_CONVERT (e, 1))
- #define _GL_SIGNED_INT_MAXIMUM(e)                                       \
--  (((_GL_INT_CONVERT (e, 1) << (sizeof ((e) + 0) * CHAR_BIT - 2)) - 1) * 2 + 1)
-+  (((_GL_INT_CONVERT (e, 1) << (TYPE_WIDTH ((e) + 0) - 2)) - 1) * 2 + 1)
-+
-+/* Work around OpenVMS incompatibility with C99.  */
-+#if !defined LLONG_MAX && defined __INT64_MAX
-+# define LLONG_MAX __INT64_MAX
-+# define LLONG_MIN __INT64_MIN
-+#endif
- 
- /* This include file assumes that signed types are two's complement without
-    padding bits; the above macros have undefined behavior otherwise.
-@@ -84,10 +94,15 @@ verify (TYPE_MAXIMUM (long int) == LONG_MAX);
- verify (TYPE_MINIMUM (long long int) == LLONG_MIN);
- verify (TYPE_MAXIMUM (long long int) == LLONG_MAX);
- #endif
-+/* Similarly, sanity-check one ISO/IEC TS 18661-1:2014 macro if defined.  */
-+#ifdef UINT_WIDTH
-+verify (TYPE_WIDTH (unsigned int) == UINT_WIDTH);
-+#endif
- 
- /* Does the __typeof__ keyword work?  This could be done by
-    'configure', but for now it's easier to do it by hand.  */
--#if (2 <= __GNUC__ || defined __IBM__TYPEOF__ \
-+#if (2 <= __GNUC__ \
-+     || (1210 <= __IBMC__ && defined __IBM__TYPEOF__) \
-      || (0x5110 <= __SUNPRO_C && !__STDC__))
- # define _GL_HAVE___TYPEOF__ 1
- #else
-@@ -116,8 +131,7 @@ verify (TYPE_MAXIMUM (long long int) == LLONG_MAX);
-    signed, this macro may overestimate the true bound by one byte when
-    applied to unsigned types of size 2, 4, 16, ... bytes.  */
- #define INT_STRLEN_BOUND(t)                                     \
--  (INT_BITS_STRLEN_BOUND (sizeof (t) * CHAR_BIT                 \
--                          - _GL_SIGNED_TYPE_OR_EXPR (t))        \
-+  (INT_BITS_STRLEN_BOUND (TYPE_WIDTH (t) - _GL_SIGNED_TYPE_OR_EXPR (t)) \
-    + _GL_SIGNED_TYPE_OR_EXPR (t))
- 
- /* Bound on buffer size needed to represent an integer type or expression T,
-@@ -222,20 +236,23 @@ verify (TYPE_MAXIMUM (long long int) == LLONG_MAX);
-    ? (a) < (min) >> (b)                                 \
-    : (max) >> (b) < (a))
- 
--/* True if __builtin_add_overflow (A, B, P) works when P is null.  */
--#define _GL_HAS_BUILTIN_OVERFLOW_WITH_NULL (7 <= __GNUC__)
-+/* True if __builtin_add_overflow (A, B, P) works when P is non-null.  */
-+#define _GL_HAS_BUILTIN_OVERFLOW (5 <= __GNUC__)
-+
-+/* True if __builtin_add_overflow_p (A, B, C) works.  */
-+#define _GL_HAS_BUILTIN_OVERFLOW_P (7 <= __GNUC__)
- 
- /* The _GL*_OVERFLOW macros have the same restrictions as the
-    *_RANGE_OVERFLOW macros, except that they do not assume that operands
-    (e.g., A and B) have the same type as MIN and MAX.  Instead, they assume
-    that the result (e.g., A + B) has that type.  */
--#if _GL_HAS_BUILTIN_OVERFLOW_WITH_NULL
--# define _GL_ADD_OVERFLOW(a, b, min, max)
--   __builtin_add_overflow (a, b, (__typeof__ ((a) + (b)) *) 0)
--# define _GL_SUBTRACT_OVERFLOW(a, b, min, max)
--   __builtin_sub_overflow (a, b, (__typeof__ ((a) - (b)) *) 0)
--# define _GL_MULTIPLY_OVERFLOW(a, b, min, max)
--   __builtin_mul_overflow (a, b, (__typeof__ ((a) * (b)) *) 0)
-+#if _GL_HAS_BUILTIN_OVERFLOW_P
-+# define _GL_ADD_OVERFLOW(a, b, min, max)                               \
-+   __builtin_add_overflow_p (a, b, (__typeof__ ((a) + (b))) 0)
-+# define _GL_SUBTRACT_OVERFLOW(a, b, min, max)                          \
-+   __builtin_sub_overflow_p (a, b, (__typeof__ ((a) - (b))) 0)
-+# define _GL_MULTIPLY_OVERFLOW(a, b, min, max)                          \
-+   __builtin_mul_overflow_p (a, b, (__typeof__ ((a) * (b))) 0)
- #else
- # define _GL_ADD_OVERFLOW(a, b, min, max)                                \
-    ((min) < 0 ? INT_ADD_RANGE_OVERFLOW (a, b, min, max)                  \
-@@ -315,7 +332,7 @@ verify (TYPE_MAXIMUM (long long int) == LLONG_MAX);
-   _GL_BINARY_OP_OVERFLOW (a, b, _GL_ADD_OVERFLOW)
- #define INT_SUBTRACT_OVERFLOW(a, b) \
-   _GL_BINARY_OP_OVERFLOW (a, b, _GL_SUBTRACT_OVERFLOW)
--#if _GL_HAS_BUILTIN_OVERFLOW_WITH_NULL
-+#if _GL_HAS_BUILTIN_OVERFLOW_P
- # define INT_NEGATE_OVERFLOW(a) INT_SUBTRACT_OVERFLOW (0, a)
- #else
- # define INT_NEGATE_OVERFLOW(a) \
-@@ -349,10 +366,6 @@ verify (TYPE_MAXIMUM (long long int) == LLONG_MAX);
- #define INT_MULTIPLY_WRAPV(a, b, r) \
-   _GL_INT_OP_WRAPV (a, b, r, *, __builtin_mul_overflow, INT_MULTIPLY_OVERFLOW)
- 
--#ifndef __has_builtin
--# define __has_builtin(x) 0
--#endif
--
- /* Nonzero if this compiler has GCC bug 68193 or Clang bug 25390.  See:
-    https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68193
-    https://llvm.org/bugs/show_bug.cgi?id=25390
-@@ -369,7 +382,7 @@ verify (TYPE_MAXIMUM (long long int) == LLONG_MAX);
-    the operation.  BUILTIN is the builtin operation, and OVERFLOW the
-    overflow predicate.  Return 1 if the result overflows.  See above
-    for restrictions.  */
--#if 5 <= __GNUC__ || __has_builtin (__builtin_add_overflow)
-+#if _GL_HAS_BUILTIN_OVERFLOW
- # define _GL_INT_OP_WRAPV(a, b, r, op, builtin, overflow) builtin (a, b, r)
- #elif 201112 <= __STDC_VERSION__ && !_GL__GENERIC_BOGUS
- # define _GL_INT_OP_WRAPV(a, b, r, op, builtin, overflow) \
-@@ -412,7 +425,7 @@ verify (TYPE_MAXIMUM (long long int) == LLONG_MAX);
- # else
- #  define _GL_INT_OP_WRAPV_LONGISH(a, b, r, op, overflow) \
-     _GL_INT_OP_CALC (a, b, r, op, overflow, unsigned long int, \
--                     long int, LONG_MIN, LONG_MAX))
-+                     long int, LONG_MIN, LONG_MAX)
- # endif
- #endif
- 
--- 
-1.9.1
-
diff --git a/poky/meta/recipes-extended/libidn/libidn/libidn_fix_for_automake-1.12.patch b/poky/meta/recipes-extended/libidn/libidn/libidn_fix_for_automake-1.12.patch
index db91317..3c0559e 100644
--- a/poky/meta/recipes-extended/libidn/libidn/libidn_fix_for_automake-1.12.patch
+++ b/poky/meta/recipes-extended/libidn/libidn/libidn_fix_for_automake-1.12.patch
@@ -1,3 +1,8 @@
+From d4f64b78419139eda3c0e1c6ee116bb5f70ea67c Mon Sep 17 00:00:00 2001
+From: Nitin A Kamble <nitin.a.kamble@intel.com>
+Date: Wed, 2 May 2012 18:05:19 -0700
+Subject: [PATCH] libtasn1: fix build with automake 1.12
+
 Upstream-Status: Pending
 
 This patch fixes following issue with automake 1.12
@@ -9,12 +14,16 @@
 Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
 2012/05/03
 
-Index: libidn-1.33/configure.ac
-===================================================================
---- libidn-1.33.orig/configure.ac
-+++ libidn-1.33/configure.ac
-@@ -33,6 +33,10 @@ AC_SUBST(LT_CURRENT, 17)
- AC_SUBST(LT_REVISION, 16)
+---
+ configure.ac | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/configure.ac b/configure.ac
+index 8297649..7b9626e 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -33,6 +33,10 @@ AC_SUBST(LT_CURRENT, 18)
+ AC_SUBST(LT_REVISION, 0)
  AC_SUBST(LT_AGE, 6)
  
 +# automake 1.12 seems to require this, but automake 1.11 doesn't recognize it
diff --git a/poky/meta/recipes-extended/libidn/libidn2/Unset-need_charset_alias-when-building-for-musl.patch b/poky/meta/recipes-extended/libidn/libidn2/Unset-need_charset_alias-when-building-for-musl.patch
new file mode 100644
index 0000000..ace50bb
--- /dev/null
+++ b/poky/meta/recipes-extended/libidn/libidn2/Unset-need_charset_alias-when-building-for-musl.patch
@@ -0,0 +1,23 @@
+Unset need_charset_alias when building for musl
+
+localcharset uses ac_cv_gnu_library_2_1 from glibc21.m4
+which actually shoudl be fixed in gnulib and then all downstream
+projects will get it eventually. For now we apply the fix to
+coreutils
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Index: libidn2-2.0.5/unistring/Makefile.am
+===================================================================
+--- libidn2-2.0.5.orig/unistring/Makefile.am
++++ libidn2-2.0.5/unistring/Makefile.am
+@@ -293,7 +293,7 @@ install-exec-localcharset: all-local
+ 	  case '$(host_os)' in \
+ 	    darwin[56]*) \
+ 	      need_charset_alias=true ;; \
+-	    darwin* | cygwin* | mingw* | pw32* | cegcc*) \
++	    darwin* | cygwin* | mingw* | pw32* | cegcc* | linux-musl*) \
+ 	      need_charset_alias=false ;; \
+ 	    *) \
+ 	      need_charset_alias=true ;; \
diff --git a/poky/meta/recipes-extended/libidn/libidn2_2.0.5.bb b/poky/meta/recipes-extended/libidn/libidn2_2.0.5.bb
new file mode 100644
index 0000000..0daf7a6
--- /dev/null
+++ b/poky/meta/recipes-extended/libidn/libidn2_2.0.5.bb
@@ -0,0 +1,29 @@
+SUMMARY = "Internationalized Domain Name support library"
+DESCRIPTION = "Implementation of the Stringprep, Punycode and IDNA specifications defined by the IETF Internationalized Domain Names (IDN) working group."
+HOMEPAGE = "http://www.gnu.org/software/libidn/"
+SECTION = "libs"
+LICENSE = "(GPLv2+ | LGPLv3) & GPLv3+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=ab90e75ef97cc6318ce4f2fbda62fe4d \
+                    file://COPYING.LESSERv3;md5=e6a600fd5e1d9cbde2d983680233ad02 \
+                    file://COPYINGv2;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                    file://src/idn2.c;endline=16;md5=0283aec28e049f5bcaaeee52aa865874 \
+                    file://lib/idn2.h.in;endline=27;md5=c2cd28d3f87260f157f022eabb83714f"
+
+SRC_URI = "${GNU_MIRROR}/libidn/${BPN}-${PV}.tar.gz \
+           file://Unset-need_charset_alias-when-building-for-musl.patch \
+          "
+SRC_URI[md5sum] = "eaf9a5b9d03b0cce3760f34b3124eb36"
+SRC_URI[sha256sum] = "53f69170886f1fa6fa5b332439c7a77a7d22626a82ef17e2c1224858bb4ca2b8"
+
+DEPENDS = "virtual/libiconv libunistring"
+
+inherit pkgconfig autotools gettext texinfo gtk-doc lib_package
+
+EXTRA_OECONF += "--disable-rpath \
+                 --with-libunistring-prefix=${STAGING_EXECPREFIXDIR} \
+                 "
+
+LICENSE_${PN} = "(GPLv2+ | LGPLv3)"
+LICENSE_${PN}-bin = "GPLv3+"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/libidn/libidn_1.33.bb b/poky/meta/recipes-extended/libidn/libidn_1.33.bb
deleted file mode 100644
index 9e8bdba..0000000
--- a/poky/meta/recipes-extended/libidn/libidn_1.33.bb
+++ /dev/null
@@ -1,44 +0,0 @@
-SUMMARY = "Internationalized Domain Name support library"
-DESCRIPTION = "Implementation of the Stringprep, Punycode and IDNA specifications defined by the IETF Internationalized Domain Names (IDN) working group."
-HOMEPAGE = "http://www.gnu.org/software/libidn/"
-SECTION = "libs"
-LICENSE = "(LGPLv2.1+ | LGPLv3) & GPLv3+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=df4be47940a91ee69556f5f71eed4aec \
-                    file://COPYING.LESSERv2;md5=4fbd65380cdd255951079008b364516c \
-                    file://COPYING.LESSERv3;md5=e6a600fd5e1d9cbde2d983680233ad02 \
-                    file://COPYINGv2;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-                    file://COPYINGv3;md5=d32239bcb673463ab874e80d47fae504 \
-                    file://lib/idna.h;endline=21;md5=37cffad24807f446a24de3e7371f20b9 \
-                    file://src/idn.c;endline=20;md5=09e97034a8877b3451cb65065fc2c06e"
-DEPENDS = "virtual/libiconv"
-
-inherit pkgconfig autotools gettext texinfo gtk-doc
-
-SRC_URI = "${GNU_MIRROR}/libidn/${BPN}-${PV}.tar.gz \
-           file://libidn_fix_for_automake-1.12.patch \
-           file://avoid_AM_PROG_MKDIR_P_warning_error_with_automake_1.12.patch \
-           file://dont-depend-on-help2man.patch \
-           file://0001-idn-fix-printf-format-security-warnings.patch \
-           file://gcc7-compatibility.patch \
-           file://0001-idn-format-security-warnings.patch \
-"
-
-SRC_URI[md5sum] = "a9aa7e003665de9c82bd3f9fc6ccf308"
-SRC_URI[sha256sum] = "44a7aab635bb721ceef6beecc4d49dfd19478325e1b47f3196f7d2acc4930e19"
-
-# command tool is under GPLv3+, while libidn itself is under LGPLv2.1+ or LGPLv3
-# so package command into a separate package
-PACKAGES =+ "idn"
-FILES_idn = "${bindir}/*"
-
-LICENSE_${PN} = "LGPLv2.1+ | LGPLv3"
-LICENSE_idn = "GPLv3+"
-
-EXTRA_OECONF = "--disable-csharp"
-
-do_install_append() {
-	rm -rf ${D}${datadir}/emacs
-}
-
-BBCLASSEXTEND = "native nativesdk"
-
diff --git a/poky/meta/recipes-extended/libidn/libidn_1.35.bb b/poky/meta/recipes-extended/libidn/libidn_1.35.bb
new file mode 100644
index 0000000..d5ce5b4
--- /dev/null
+++ b/poky/meta/recipes-extended/libidn/libidn_1.35.bb
@@ -0,0 +1,42 @@
+SUMMARY = "Internationalized Domain Name support library"
+DESCRIPTION = "Implementation of the Stringprep, Punycode and IDNA specifications defined by the IETF Internationalized Domain Names (IDN) working group."
+HOMEPAGE = "http://www.gnu.org/software/libidn/"
+SECTION = "libs"
+LICENSE = "(LGPLv2.1+ | LGPLv3) & GPLv3+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=df4be47940a91ee69556f5f71eed4aec \
+                    file://COPYING.LESSERv2;md5=4fbd65380cdd255951079008b364516c \
+                    file://COPYING.LESSERv3;md5=e6a600fd5e1d9cbde2d983680233ad02 \
+                    file://COPYINGv2;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                    file://COPYINGv3;md5=d32239bcb673463ab874e80d47fae504 \
+                    file://lib/idna.h;endline=21;md5=37cffad24807f446a24de3e7371f20b9 \
+                    file://src/idn.c;endline=20;md5=09e97034a8877b3451cb65065fc2c06e"
+DEPENDS = "virtual/libiconv autoconf-archive"
+
+inherit pkgconfig autotools gettext texinfo gtk-doc
+
+SRC_URI = "${GNU_MIRROR}/libidn/${BPN}-${PV}.tar.gz \
+           file://libidn_fix_for_automake-1.12.patch \
+           file://avoid_AM_PROG_MKDIR_P_warning_error_with_automake_1.12.patch \
+           file://dont-depend-on-help2man.patch \
+           file://0001-idn-format-security-warnings.patch \
+           "
+
+SRC_URI[md5sum] = "bef634141fe39326cb354b75e891fead"
+SRC_URI[sha256sum] = "f11af1005b46b7b15d057d7f107315a1ad46935c7fcdf243c16e46ec14f0fe1e"
+
+# command tool is under GPLv3+, while libidn itself is under LGPLv2.1+ or LGPLv3
+# so package command into a separate package
+PACKAGES =+ "idn"
+FILES_idn = "${bindir}/*"
+
+LICENSE_${PN} = "LGPLv2.1+ | LGPLv3"
+LICENSE_idn = "GPLv3+"
+
+EXTRA_OECONF = "--disable-csharp"
+
+do_install_append() {
+	rm -rf ${D}${datadir}/emacs
+}
+
+BBCLASSEXTEND = "native nativesdk"
+
diff --git a/poky/meta/recipes-extended/libnsl/libnsl2/0001-include-sys-cdefs.h-explicitly.patch b/poky/meta/recipes-extended/libnsl/libnsl2/0001-include-sys-cdefs.h-explicitly.patch
deleted file mode 100644
index bd647ac..0000000
--- a/poky/meta/recipes-extended/libnsl/libnsl2/0001-include-sys-cdefs.h-explicitly.patch
+++ /dev/null
@@ -1,68 +0,0 @@
-From 508a0ff690dfebc17c4f55a5f81824ed549bed66 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 18 Apr 2017 09:13:33 -0700
-Subject: [PATCH 1/2] include sys/cdefs.h explicitly
-
-glibc includes this header indirectly but not musl
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Pending
-
- src/rpcsvc/nis.h    | 1 +
- src/rpcsvc/nislib.h | 1 +
- src/rpcsvc/ypclnt.h | 1 +
- src/rpcsvc/ypupd.h  | 1 +
- 4 files changed, 4 insertions(+)
-
-diff --git a/src/rpcsvc/nis.h b/src/rpcsvc/nis.h
-index 933c4d9..88cbca0 100644
---- a/src/rpcsvc/nis.h
-+++ b/src/rpcsvc/nis.h
-@@ -32,6 +32,7 @@
- #ifndef _RPCSVC_NIS_H
- #define _RPCSVC_NIS_H 1
- 
-+#include <sys/cdefs.h>
- #include <features.h>
- #include <rpc/rpc.h>
- #include <rpcsvc/nis_tags.h>
-diff --git a/src/rpcsvc/nislib.h b/src/rpcsvc/nislib.h
-index a59c19b..a53fab3 100644
---- a/src/rpcsvc/nislib.h
-+++ b/src/rpcsvc/nislib.h
-@@ -19,6 +19,7 @@
- #ifndef	__RPCSVC_NISLIB_H__
- #define	__RPCSVC_NISLIB_H__
- 
-+#include <sys/cdefs.h>
- #include <features.h>
- 
- __BEGIN_DECLS
-diff --git a/src/rpcsvc/ypclnt.h b/src/rpcsvc/ypclnt.h
-index fe43fd4..a686b61 100644
---- a/src/rpcsvc/ypclnt.h
-+++ b/src/rpcsvc/ypclnt.h
-@@ -20,6 +20,7 @@
- #ifndef	__RPCSVC_YPCLNT_H__
- #define	__RPCSVC_YPCLNT_H__
- 
-+#include <sys/cdefs.h>
- #include <features.h>
- 
- /* Some defines */
-diff --git a/src/rpcsvc/ypupd.h b/src/rpcsvc/ypupd.h
-index d07fd4d..2c57301 100644
---- a/src/rpcsvc/ypupd.h
-+++ b/src/rpcsvc/ypupd.h
-@@ -33,6 +33,7 @@
- #ifndef __RPCSVC_YPUPD_H__
- #define __RPCSVC_YPUPD_H__
- 
-+#include <sys/cdefs.h>
- #include <features.h>
- 
- #include <rpc/rpc.h>
--- 
-2.12.2
-
diff --git a/poky/meta/recipes-extended/libnsl/libnsl2/0001-nis_call.c-Include-stdint.h-for-uintptr_t-definition.patch b/poky/meta/recipes-extended/libnsl/libnsl2/0001-nis_call.c-Include-stdint.h-for-uintptr_t-definition.patch
deleted file mode 100644
index e9ae517..0000000
--- a/poky/meta/recipes-extended/libnsl/libnsl2/0001-nis_call.c-Include-stdint.h-for-uintptr_t-definition.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From d71cbeb3b76e54778a4d5eec6d387cce653537ca Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 9 Jun 2017 09:49:35 -0700
-Subject: [PATCH] nis_call.c: Include stdint.h for uintptr_t definition
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Pending
-
- src/nisplus/nis_call.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/src/nisplus/nis_call.c b/src/nisplus/nis_call.c
-index 1a2b90c..1dc982d 100644
---- a/src/nisplus/nis_call.c
-+++ b/src/nisplus/nis_call.c
-@@ -23,6 +23,7 @@
- #include <errno.h>
- #include <fcntl.h>
- #include <string.h>
-+#include <stdint.h>
- #include <libintl.h>
- #include <rpc/rpc.h>
- #include <rpc/auth.h>
--- 
-2.13.1
-
diff --git a/poky/meta/recipes-extended/libnsl/libnsl2/0002-Define-glibc-specific-macros.patch b/poky/meta/recipes-extended/libnsl/libnsl2/0002-Define-glibc-specific-macros.patch
deleted file mode 100644
index 75fda4b..0000000
--- a/poky/meta/recipes-extended/libnsl/libnsl2/0002-Define-glibc-specific-macros.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-From 60282514ea01af004d7f9e66dd3929223b7d2e7b Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 18 Apr 2017 09:16:12 -0700
-Subject: [PATCH 2/2] Define glibc specific macros
-
-Check and define
-rawmemchr, __asprintf, __mempcpy, __strtok_r
-__always_inline, TEMP_FAILURE_RETRY
-
-if not existing. Helps compiling with musl
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Pending
-
-diff --git a/src/rpcsvc/nis.h b/src/rpcsvc/nis.h
-index 88cbca0..23fc20c 100644
---- a/src/rpcsvc/nis.h
-+++ b/src/rpcsvc/nis.h
-@@ -57,6 +57,34 @@ __BEGIN_DECLS
-  *                                              <kukuk@suse.de>
-  */
- 
-+#ifndef rawmemchr
-+#define rawmemchr(s,c) memchr((s),(size_t)-1,(c))
-+#endif
-+
-+#ifndef __asprintf
-+#define __asprintf asprintf
-+#endif
-+
-+#ifndef __mempcpy
-+#define __mempcpy mempcpy
-+#endif
-+
-+#ifndef __strtok_r
-+#define __strtok_r strtok_r
-+#endif
-+
-+#ifndef __always_inline
-+#define __always_inline __attribute__((__always_inline__))
-+#endif
-+
-+#ifndef TEMP_FAILURE_RETRY
-+#define TEMP_FAILURE_RETRY(exp) ({ \
-+typeof (exp) _rc; \
-+ do { \
-+  _rc = (exp); \
-+ } while (_rc == -1 && errno == EINTR); \
-+ _rc; })
-+#endif
- 
- #ifndef __nis_object_h
- #define __nis_object_h
--- 
-2.12.2
-
diff --git a/poky/meta/recipes-extended/libnsl/libnsl2_git.bb b/poky/meta/recipes-extended/libnsl/libnsl2_git.bb
index a539148..c3a24fa 100644
--- a/poky/meta/recipes-extended/libnsl/libnsl2_git.bb
+++ b/poky/meta/recipes-extended/libnsl/libnsl2_git.bb
@@ -9,29 +9,16 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
 SECTION = "libs"
 DEPENDS = "libtirpc"
-DEPENDS_append_libc-musl = " bsd-headers"
 
-PV = "1.0.5+git${SRCPV}"
+PV = "1.2.0+git${SRCPV}"
 
-SRCREV = "dfa2f313524aff9243c4d8ce1bace73786478356"
+SRCREV = "37c5ffe3038d42e9fa9ed232ad2cbca4d8f14681"
 
 SRC_URI = "git://github.com/thkukuk/libnsl \
-           file://0001-include-sys-cdefs.h-explicitly.patch \
-           file://0002-Define-glibc-specific-macros.patch \
-           file://0001-nis_call.c-Include-stdint.h-for-uintptr_t-definition.patch \
           "
 
 S = "${WORKDIR}/git"
 
 inherit autotools pkgconfig gettext
 
-EXTRA_OECONF += "--libdir=${libdir}/nsl --includedir=${includedir}/nsl"
-
-do_install_append() {
-	install -d ${D}${libdir}
-	mv ${D}${libdir}/nsl/pkgconfig ${D}${libdir}
-}
-
-FILES_${PN} += "${libdir}/nsl/*.so.*"
-FILES_${PN}-dev += "${includedir}/nsl ${libdir}/nsl/*.so"
-FILES_${PN}-staticdev += "${libdir}/nsl/*.a"
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/libnss-nis/libnss-nis.bb b/poky/meta/recipes-extended/libnss-nis/libnss-nis.bb
new file mode 100644
index 0000000..47447ac
--- /dev/null
+++ b/poky/meta/recipes-extended/libnss-nis/libnss-nis.bb
@@ -0,0 +1,31 @@
+# Copyright (C) 2018 Khem Raj <raj.khem@gmail.com>
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+SUMMARY = "NSS module for glibc, to provide NIS support for glibc"
+
+DESCRIPTION = "This package contains the NSS NIS plugin for glibc.\
+This code was formerly part of glibc, but is now standalone to\
+be able to link against TI-RPC for IPv6 support."
+
+HOMEPAGE = "https://github.com/thkukuk/libnss_nis"
+LICENSE = "LGPL-2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
+SECTION = "libs"
+DEPENDS += "libtirpc libnsl2"
+
+PV = "3.0+git${SRCPV}"
+
+SRCREV = "d4aea48657a8e90d7922574b8021ee03915a36cb"
+
+SRC_URI = "git://github.com/thkukuk/libnss_nis \
+          "
+
+S = "${WORKDIR}/git"
+
+inherit autotools pkgconfig
+
+BBCLASSEXTEND += "native nativesdk"
+#
+# We will skip parsing this packagegeoup for non-glibc systems
+#
+COMPATIBLE_HOST_libc-musl = 'null'
diff --git a/poky/meta/recipes-extended/libsolv/libsolv_0.6.33.bb b/poky/meta/recipes-extended/libsolv/libsolv_0.6.33.bb
deleted file mode 100644
index 0401ced..0000000
--- a/poky/meta/recipes-extended/libsolv/libsolv_0.6.33.bb
+++ /dev/null
@@ -1,30 +0,0 @@
-SUMMARY = "Library for solving packages and reading repositories"
-HOMEPAGE = "https://github.com/openSUSE/libsolv"
-BUGTRACKER = "https://github.com/openSUSE/libsolv/issues"
-SECTION = "devel"
-LICENSE = "BSD-3-Clause"
-LIC_FILES_CHKSUM = "file://LICENSE.BSD;md5=62272bd11c97396d4aaf1c41bc11f7d8"
-
-DEPENDS = "expat zlib rpm"
-
-SRC_URI = "git://github.com/openSUSE/libsolv.git \
-          "
-SRC_URI_append_libc-musl = " file://0001-Add-fallback-fopencookie-implementation.patch \
-                             file://0002-Fixes-to-internal-fopencookie-implementation.patch \
-                           "
-
-SRCREV = "69f1803978ba7a46a57928fa4be6430792419e4e"
-UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+(\.\d+)+)"
-
-S = "${WORKDIR}/git"
-
-inherit cmake
-
-EXTRA_OECMAKE = "-DLIB=${baselib} -DMULTI_SEMANTICS=ON -DENABLE_RPMMD=ON -DENABLE_RPMDB=ON -DENABLE_COMPLEX_DEPS=ON"
-
-PACKAGES =+ "${PN}-tools ${PN}ext"
-
-FILES_${PN}-tools = "${bindir}/*"
-FILES_${PN}ext = "${libdir}/${PN}ext.so.*"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/libsolv/libsolv_0.6.35.bb b/poky/meta/recipes-extended/libsolv/libsolv_0.6.35.bb
new file mode 100644
index 0000000..12dfc5d
--- /dev/null
+++ b/poky/meta/recipes-extended/libsolv/libsolv_0.6.35.bb
@@ -0,0 +1,32 @@
+SUMMARY = "Library for solving packages and reading repositories"
+HOMEPAGE = "https://github.com/openSUSE/libsolv"
+BUGTRACKER = "https://github.com/openSUSE/libsolv/issues"
+SECTION = "devel"
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE.BSD;md5=62272bd11c97396d4aaf1c41bc11f7d8"
+
+DEPENDS = "expat zlib"
+
+SRC_URI = "git://github.com/openSUSE/libsolv.git"
+SRC_URI_append_libc-musl = " file://0001-Add-fallback-fopencookie-implementation.patch \
+                             file://0002-Fixes-to-internal-fopencookie-implementation.patch \
+                           "
+
+SRCREV = "38c5374d4712667b0b6ada4bf78ddbb343095d0c"
+UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+(\.\d+)+)"
+
+S = "${WORKDIR}/git"
+
+inherit cmake
+
+PACKAGECONFIG ??= "rpm"
+PACKAGECONFIG[rpm] = "-DENABLE_RPMMD=ON -DENABLE_RPMDB=ON,,rpm"
+
+EXTRA_OECMAKE = "-DLIB=${baselib} -DMULTI_SEMANTICS=ON -DENABLE_COMPLEX_DEPS=ON"
+
+PACKAGES =+ "${PN}-tools ${PN}ext"
+
+FILES_${PN}-tools = "${bindir}/*"
+FILES_${PN}ext = "${libdir}/${PN}ext.so.*"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/libtirpc/libtirpc/0001-include-stdint.h-for-uintptr_t.patch b/poky/meta/recipes-extended/libtirpc/libtirpc/0001-include-stdint.h-for-uintptr_t.patch
deleted file mode 100644
index 7e3e2f8..0000000
--- a/poky/meta/recipes-extended/libtirpc/libtirpc/0001-include-stdint.h-for-uintptr_t.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-Upstream-Status: Backport
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
-From acb9a37977cf0a9630eac74af9adebf35e38e719 Mon Sep 17 00:00:00 2001
-From: Thorsten Kukuk <kukuk@thkukuk.de>
-Date: Tue, 14 Nov 2017 10:39:08 -0500
-Subject: [PATCH] Include stdint.h from xdr_sizeof.c to avoid missing
- declaration errors.
-
-Signed-off-by: Thorsten Kukuk <kukuk@suse.de>
-Signed-off-by: Steve Dickson <steved@redhat.com>
----
- src/xdr_sizeof.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/src/xdr_sizeof.c b/src/xdr_sizeof.c
-index d23fbd1..79d6707 100644
---- a/src/xdr_sizeof.c
-+++ b/src/xdr_sizeof.c
-@@ -39,6 +39,7 @@
- #include <rpc/xdr.h>
- #include <sys/types.h>
- #include <stdlib.h>
-+#include <stdint.h>
- #include "un-namespace.h"
- 
- /* ARGSUSED */
--- 
-1.8.3.1
diff --git a/poky/meta/recipes-extended/libtirpc/libtirpc/0001-replace-__bzero-with-memset-API.patch b/poky/meta/recipes-extended/libtirpc/libtirpc/0001-replace-__bzero-with-memset-API.patch
deleted file mode 100644
index 7ae19cb..0000000
--- a/poky/meta/recipes-extended/libtirpc/libtirpc/0001-replace-__bzero-with-memset-API.patch
+++ /dev/null
@@ -1,64 +0,0 @@
-Upstream-Status: Backport
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
-From 5356b63005e9d8169e0399cb76f26fbd29a78dee Mon Sep 17 00:00:00 2001
-From: Joshua Kinard <kumba@gentoo.org>
-Date: Wed, 23 Aug 2017 14:31:36 -0400
-Subject: [PATCH] Replace bzero() calls with equivalent memset() calls
-
-As annotated in the bzero(3) man page, bzero() was marked as LEGACY in
-POSIX.1-2001 and removed in POSIX.1-2008, and should be replaced with
-memset() calls to write zeros to a memory region.  The attached patch
-replaces two bzero() calls and one __bzero() call in libtirpc with
-equivalent memset() calls.  The latter replacement fixes a compile error
-under uclibc-ng, which lacks a definition for __bzero()
-
-Signed-off-by: Joshua Kinard <kumba@gentoo.org>
-Signed-off-by: Steve Dickson <steved@redhat.com>
----
- src/auth_time.c    | 2 +-
- src/des_impl.c     | 2 +-
- src/svc_auth_des.c | 2 +-
- 3 files changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/src/auth_time.c b/src/auth_time.c
-index 7f83ab4..69400bc 100644
---- a/src/auth_time.c
-+++ b/src/auth_time.c
-@@ -317,7 +317,7 @@ __rpc_get_time_offset(td, srv, thost, uaddr, netid)
- 	sprintf(ipuaddr, "%d.%d.%d.%d.0.111", a1, a2, a3, a4);
- 	useua = &ipuaddr[0];
- 
--	bzero((char *)&sin, sizeof(sin));
-+	memset(&sin, 0, sizeof(sin));
- 	if (uaddr_to_sockaddr(useua, &sin)) {
- 		msg("unable to translate uaddr to sockaddr.");
- 		if (needfree)
-diff --git a/src/des_impl.c b/src/des_impl.c
-index 9dbccaf..15bec2a 100644
---- a/src/des_impl.c
-+++ b/src/des_impl.c
-@@ -588,7 +588,7 @@ _des_crypt (char *buf, unsigned len, struct desparams *desp)
-     }
-   tin0 = tin1 = tout0 = tout1 = xor0 = xor1 = 0;
-   tbuf[0] = tbuf[1] = 0;
--  __bzero (schedule, sizeof (schedule));
-+  memset (schedule, 0, sizeof (schedule));
- 
-   return (1);
- }
-diff --git a/src/svc_auth_des.c b/src/svc_auth_des.c
-index 2e90146..19a7c60 100644
---- a/src/svc_auth_des.c
-+++ b/src/svc_auth_des.c
-@@ -356,7 +356,7 @@ cache_init()
- 
- 	authdes_cache = (struct cache_entry *)
- 		mem_alloc(sizeof(struct cache_entry) * AUTHDES_CACHESZ);	
--	bzero((char *)authdes_cache, 
-+	memset(authdes_cache, 0,
- 		sizeof(struct cache_entry) * AUTHDES_CACHESZ);
- 
- 	authdes_lru = (short *)mem_alloc(sizeof(short) * AUTHDES_CACHESZ);
--- 
-1.8.3.1
diff --git a/poky/meta/recipes-extended/libtirpc/libtirpc/Use-netbsd-queue.h.patch b/poky/meta/recipes-extended/libtirpc/libtirpc/Use-netbsd-queue.h.patch
deleted file mode 100644
index f93223f..0000000
--- a/poky/meta/recipes-extended/libtirpc/libtirpc/Use-netbsd-queue.h.patch
+++ /dev/null
@@ -1,878 +0,0 @@
-musl does not provide sys/queue.h implementation. Borrow queue.h from
-the NetBSD project
-http://cvsweb.netbsd.org/bsdweb.cgi/src/sys/sys/queue.h?rev=1.68
-
-Upstream-Status: Inappropriate [musl specific]
-
-Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
-Signed-off-by: Maxin B. John <maxin.john@intel.com>
----
-diff -Naur libtirpc-1.0.1-orig/src/clnt_bcast.c libtirpc-1.0.1/src/clnt_bcast.c
---- libtirpc-1.0.1-orig/src/clnt_bcast.c	2015-10-30 17:15:14.000000000 +0200
-+++ libtirpc-1.0.1/src/clnt_bcast.c	2015-12-21 17:03:52.066008311 +0200
-@@ -40,7 +40,6 @@
-  */
- #include <sys/socket.h>
- #include <sys/types.h>
--#include <sys/queue.h>
- 
- #include <net/if.h>
- #include <netinet/in.h>
-@@ -62,6 +61,7 @@
- #include <err.h>
- #include <string.h>
- 
-+#include "queue.h"
- #include "rpc_com.h"
- #include "debug.h"
- 
-diff -Naur libtirpc-1.0.1-orig/tirpc/queue.h libtirpc-1.0.1/tirpc/queue.h
---- libtirpc-1.0.1-orig/tirpc/queue.h	1970-01-01 02:00:00.000000000 +0200
-+++ libtirpc-1.0.1/tirpc/queue.h	2015-12-21 17:02:44.427853905 +0200
-@@ -0,0 +1,846 @@
-+/*	$NetBSD: queue.h,v 1.68 2014/11/19 08:10:01 uebayasi Exp $	*/
-+
-+/*
-+ * Copyright (c) 1991, 1993
-+ *	The Regents of the University of California.  All rights reserved.
-+ *
-+ * Redistribution and use in source and binary forms, with or without
-+ * modification, are permitted provided that the following conditions
-+ * are met:
-+ * 1. Redistributions of source code must retain the above copyright
-+ *    notice, this list of conditions and the following disclaimer.
-+ * 2. 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.
-+ * 3. Neither the name of the University 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 REGENTS 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 REGENTS 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.
-+ *
-+ *	@(#)queue.h	8.5 (Berkeley) 8/20/94
-+ */
-+
-+#ifndef	_SYS_QUEUE_H_
-+#define	_SYS_QUEUE_H_
-+
-+/*
-+ * This file defines five types of data structures: singly-linked lists,
-+ * lists, simple queues, tail queues, and circular queues.
-+ *
-+ * A singly-linked list is headed by a single forward pointer. The
-+ * elements are singly linked for minimum space and pointer manipulation
-+ * overhead at the expense of O(n) removal for arbitrary elements. New
-+ * elements can be added to the list after an existing element or at the
-+ * head of the list.  Elements being removed from the head of the list
-+ * should use the explicit macro for this purpose for optimum
-+ * efficiency. A singly-linked list may only be traversed in the forward
-+ * direction.  Singly-linked lists are ideal for applications with large
-+ * datasets and few or no removals or for implementing a LIFO queue.
-+ *
-+ * A list is headed by a single forward pointer (or an array of forward
-+ * pointers for a hash table header). The elements are doubly linked
-+ * so that an arbitrary element can be removed without a need to
-+ * traverse the list. New elements can be added to the list before
-+ * or after an existing element or at the head of the list. A list
-+ * may only be traversed in the forward direction.
-+ *
-+ * A simple queue is headed by a pair of pointers, one the head of the
-+ * list and the other to the tail of the list. The elements are singly
-+ * linked to save space, so elements can only be removed from the
-+ * head of the list. New elements can be added to the list after
-+ * an existing element, at the head of the list, or at the end of the
-+ * list. A simple queue may only be traversed in the forward direction.
-+ *
-+ * A tail queue is headed by a pair of pointers, one to the head of the
-+ * list and the other to the tail of the list. The elements are doubly
-+ * linked so that an arbitrary element can be removed without a need to
-+ * traverse the list. New elements can be added to the list before or
-+ * after an existing element, at the head of the list, or at the end of
-+ * the list. A tail queue may be traversed in either direction.
-+ *
-+ * A circle queue is headed by a pair of pointers, one to the head of the
-+ * list and the other to the tail of the list. The elements are doubly
-+ * linked so that an arbitrary element can be removed without a need to
-+ * traverse the list. New elements can be added to the list before or after
-+ * an existing element, at the head of the list, or at the end of the list.
-+ * A circle queue may be traversed in either direction, but has a more
-+ * complex end of list detection.
-+ *
-+ * For details on the use of these macros, see the queue(3) manual page.
-+ */
-+
-+/*
-+ * Include the definition of NULL only on NetBSD because sys/null.h
-+ * is not available elsewhere.  This conditional makes the header
-+ * portable and it can simply be dropped verbatim into any system.
-+ * The caveat is that on other systems some other header
-+ * must provide NULL before the macros can be used.
-+ */
-+#ifdef __NetBSD__
-+#include <sys/null.h>
-+#endif
-+
-+#if defined(QUEUEDEBUG)
-+# if defined(_KERNEL)
-+#  define QUEUEDEBUG_ABORT(...) panic(__VA_ARGS__)
-+# else
-+#  include <err.h>
-+#  define QUEUEDEBUG_ABORT(...) err(1, __VA_ARGS__)
-+# endif
-+#endif
-+
-+/*
-+ * Singly-linked List definitions.
-+ */
-+#define	SLIST_HEAD(name, type)						\
-+struct name {								\
-+	struct type *slh_first;	/* first element */			\
-+}
-+
-+#define	SLIST_HEAD_INITIALIZER(head)					\
-+	{ NULL }
-+
-+#define	SLIST_ENTRY(type)						\
-+struct {								\
-+	struct type *sle_next;	/* next element */			\
-+}
-+
-+/*
-+ * Singly-linked List access methods.
-+ */
-+#define	SLIST_FIRST(head)	((head)->slh_first)
-+#define	SLIST_END(head)		NULL
-+#define	SLIST_EMPTY(head)	((head)->slh_first == NULL)
-+#define	SLIST_NEXT(elm, field)	((elm)->field.sle_next)
-+
-+#define	SLIST_FOREACH(var, head, field)					\
-+	for((var) = (head)->slh_first;					\
-+	    (var) != SLIST_END(head);					\
-+	    (var) = (var)->field.sle_next)
-+
-+#define	SLIST_FOREACH_SAFE(var, head, field, tvar)			\
-+	for ((var) = SLIST_FIRST((head));				\
-+	    (var) != SLIST_END(head) &&					\
-+	    ((tvar) = SLIST_NEXT((var), field), 1);			\
-+	    (var) = (tvar))
-+
-+/*
-+ * Singly-linked List functions.
-+ */
-+#define	SLIST_INIT(head) do {						\
-+	(head)->slh_first = SLIST_END(head);				\
-+} while (/*CONSTCOND*/0)
-+
-+#define	SLIST_INSERT_AFTER(slistelm, elm, field) do {			\
-+	(elm)->field.sle_next = (slistelm)->field.sle_next;		\
-+	(slistelm)->field.sle_next = (elm);				\
-+} while (/*CONSTCOND*/0)
-+
-+#define	SLIST_INSERT_HEAD(head, elm, field) do {			\
-+	(elm)->field.sle_next = (head)->slh_first;			\
-+	(head)->slh_first = (elm);					\
-+} while (/*CONSTCOND*/0)
-+
-+#define	SLIST_REMOVE_AFTER(slistelm, field) do {			\
-+	(slistelm)->field.sle_next =					\
-+	    SLIST_NEXT(SLIST_NEXT((slistelm), field), field);		\
-+} while (/*CONSTCOND*/0)
-+
-+#define	SLIST_REMOVE_HEAD(head, field) do {				\
-+	(head)->slh_first = (head)->slh_first->field.sle_next;		\
-+} while (/*CONSTCOND*/0)
-+
-+#define	SLIST_REMOVE(head, elm, type, field) do {			\
-+	if ((head)->slh_first == (elm)) {				\
-+		SLIST_REMOVE_HEAD((head), field);			\
-+	}								\
-+	else {								\
-+		struct type *curelm = (head)->slh_first;		\
-+		while(curelm->field.sle_next != (elm))			\
-+			curelm = curelm->field.sle_next;		\
-+		curelm->field.sle_next =				\
-+		    curelm->field.sle_next->field.sle_next;		\
-+	}								\
-+} while (/*CONSTCOND*/0)
-+
-+
-+/*
-+ * List definitions.
-+ */
-+#define	LIST_HEAD(name, type)						\
-+struct name {								\
-+	struct type *lh_first;	/* first element */			\
-+}
-+
-+#define	LIST_HEAD_INITIALIZER(head)					\
-+	{ NULL }
-+
-+#define	LIST_ENTRY(type)						\
-+struct {								\
-+	struct type *le_next;	/* next element */			\
-+	struct type **le_prev;	/* address of previous next element */	\
-+}
-+
-+/*
-+ * List access methods.
-+ */
-+#define	LIST_FIRST(head)		((head)->lh_first)
-+#define	LIST_END(head)			NULL
-+#define	LIST_EMPTY(head)		((head)->lh_first == LIST_END(head))
-+#define	LIST_NEXT(elm, field)		((elm)->field.le_next)
-+
-+#define	LIST_FOREACH(var, head, field)					\
-+	for ((var) = ((head)->lh_first);				\
-+	    (var) != LIST_END(head);					\
-+	    (var) = ((var)->field.le_next))
-+
-+#define	LIST_FOREACH_SAFE(var, head, field, tvar)			\
-+	for ((var) = LIST_FIRST((head));				\
-+	    (var) != LIST_END(head) &&					\
-+	    ((tvar) = LIST_NEXT((var), field), 1);			\
-+	    (var) = (tvar))
-+
-+#define	LIST_MOVE(head1, head2) do {					\
-+	LIST_INIT((head2));						\
-+	if (!LIST_EMPTY((head1))) {					\
-+		(head2)->lh_first = (head1)->lh_first;			\
-+		LIST_INIT((head1));					\
-+	}								\
-+} while (/*CONSTCOND*/0)
-+
-+/*
-+ * List functions.
-+ */
-+#if defined(QUEUEDEBUG)
-+#define	QUEUEDEBUG_LIST_INSERT_HEAD(head, elm, field)			\
-+	if ((head)->lh_first &&						\
-+	    (head)->lh_first->field.le_prev != &(head)->lh_first)	\
-+		QUEUEDEBUG_ABORT("LIST_INSERT_HEAD %p %s:%d", (head),	\
-+		    __FILE__, __LINE__);
-+#define	QUEUEDEBUG_LIST_OP(elm, field)					\
-+	if ((elm)->field.le_next &&					\
-+	    (elm)->field.le_next->field.le_prev !=			\
-+	    &(elm)->field.le_next)					\
-+		QUEUEDEBUG_ABORT("LIST_* forw %p %s:%d", (elm),		\
-+		    __FILE__, __LINE__);				\
-+	if (*(elm)->field.le_prev != (elm))				\
-+		QUEUEDEBUG_ABORT("LIST_* back %p %s:%d", (elm),		\
-+		    __FILE__, __LINE__);
-+#define	QUEUEDEBUG_LIST_POSTREMOVE(elm, field)				\
-+	(elm)->field.le_next = (void *)1L;				\
-+	(elm)->field.le_prev = (void *)1L;
-+#else
-+#define	QUEUEDEBUG_LIST_INSERT_HEAD(head, elm, field)
-+#define	QUEUEDEBUG_LIST_OP(elm, field)
-+#define	QUEUEDEBUG_LIST_POSTREMOVE(elm, field)
-+#endif
-+
-+#define	LIST_INIT(head) do {						\
-+	(head)->lh_first = LIST_END(head);				\
-+} while (/*CONSTCOND*/0)
-+
-+#define	LIST_INSERT_AFTER(listelm, elm, field) do {			\
-+	QUEUEDEBUG_LIST_OP((listelm), field)				\
-+	if (((elm)->field.le_next = (listelm)->field.le_next) != 	\
-+	    LIST_END(head))						\
-+		(listelm)->field.le_next->field.le_prev =		\
-+		    &(elm)->field.le_next;				\
-+	(listelm)->field.le_next = (elm);				\
-+	(elm)->field.le_prev = &(listelm)->field.le_next;		\
-+} while (/*CONSTCOND*/0)
-+
-+#define	LIST_INSERT_BEFORE(listelm, elm, field) do {			\
-+	QUEUEDEBUG_LIST_OP((listelm), field)				\
-+	(elm)->field.le_prev = (listelm)->field.le_prev;		\
-+	(elm)->field.le_next = (listelm);				\
-+	*(listelm)->field.le_prev = (elm);				\
-+	(listelm)->field.le_prev = &(elm)->field.le_next;		\
-+} while (/*CONSTCOND*/0)
-+
-+#define	LIST_INSERT_HEAD(head, elm, field) do {				\
-+	QUEUEDEBUG_LIST_INSERT_HEAD((head), (elm), field)		\
-+	if (((elm)->field.le_next = (head)->lh_first) != LIST_END(head))\
-+		(head)->lh_first->field.le_prev = &(elm)->field.le_next;\
-+	(head)->lh_first = (elm);					\
-+	(elm)->field.le_prev = &(head)->lh_first;			\
-+} while (/*CONSTCOND*/0)
-+
-+#define	LIST_REMOVE(elm, field) do {					\
-+	QUEUEDEBUG_LIST_OP((elm), field)				\
-+	if ((elm)->field.le_next != NULL)				\
-+		(elm)->field.le_next->field.le_prev = 			\
-+		    (elm)->field.le_prev;				\
-+	*(elm)->field.le_prev = (elm)->field.le_next;			\
-+	QUEUEDEBUG_LIST_POSTREMOVE((elm), field)			\
-+} while (/*CONSTCOND*/0)
-+
-+#define LIST_REPLACE(elm, elm2, field) do {				\
-+	if (((elm2)->field.le_next = (elm)->field.le_next) != NULL)	\
-+		(elm2)->field.le_next->field.le_prev =			\
-+		    &(elm2)->field.le_next;				\
-+	(elm2)->field.le_prev = (elm)->field.le_prev;			\
-+	*(elm2)->field.le_prev = (elm2);				\
-+	QUEUEDEBUG_LIST_POSTREMOVE((elm), field)			\
-+} while (/*CONSTCOND*/0)
-+
-+/*
-+ * Simple queue definitions.
-+ */
-+#define	SIMPLEQ_HEAD(name, type)					\
-+struct name {								\
-+	struct type *sqh_first;	/* first element */			\
-+	struct type **sqh_last;	/* addr of last next element */		\
-+}
-+
-+#define	SIMPLEQ_HEAD_INITIALIZER(head)					\
-+	{ NULL, &(head).sqh_first }
-+
-+#define	SIMPLEQ_ENTRY(type)						\
-+struct {								\
-+	struct type *sqe_next;	/* next element */			\
-+}
-+
-+/*
-+ * Simple queue access methods.
-+ */
-+#define	SIMPLEQ_FIRST(head)		((head)->sqh_first)
-+#define	SIMPLEQ_END(head)		NULL
-+#define	SIMPLEQ_EMPTY(head)		((head)->sqh_first == SIMPLEQ_END(head))
-+#define	SIMPLEQ_NEXT(elm, field)	((elm)->field.sqe_next)
-+
-+#define	SIMPLEQ_FOREACH(var, head, field)				\
-+	for ((var) = ((head)->sqh_first);				\
-+	    (var) != SIMPLEQ_END(head);					\
-+	    (var) = ((var)->field.sqe_next))
-+
-+#define	SIMPLEQ_FOREACH_SAFE(var, head, field, next)			\
-+	for ((var) = ((head)->sqh_first);				\
-+	    (var) != SIMPLEQ_END(head) &&				\
-+	    ((next = ((var)->field.sqe_next)), 1);			\
-+	    (var) = (next))
-+
-+/*
-+ * Simple queue functions.
-+ */
-+#define	SIMPLEQ_INIT(head) do {						\
-+	(head)->sqh_first = NULL;					\
-+	(head)->sqh_last = &(head)->sqh_first;				\
-+} while (/*CONSTCOND*/0)
-+
-+#define	SIMPLEQ_INSERT_HEAD(head, elm, field) do {			\
-+	if (((elm)->field.sqe_next = (head)->sqh_first) == NULL)	\
-+		(head)->sqh_last = &(elm)->field.sqe_next;		\
-+	(head)->sqh_first = (elm);					\
-+} while (/*CONSTCOND*/0)
-+
-+#define	SIMPLEQ_INSERT_TAIL(head, elm, field) do {			\
-+	(elm)->field.sqe_next = NULL;					\
-+	*(head)->sqh_last = (elm);					\
-+	(head)->sqh_last = &(elm)->field.sqe_next;			\
-+} while (/*CONSTCOND*/0)
-+
-+#define	SIMPLEQ_INSERT_AFTER(head, listelm, elm, field) do {		\
-+	if (((elm)->field.sqe_next = (listelm)->field.sqe_next) == NULL)\
-+		(head)->sqh_last = &(elm)->field.sqe_next;		\
-+	(listelm)->field.sqe_next = (elm);				\
-+} while (/*CONSTCOND*/0)
-+
-+#define	SIMPLEQ_REMOVE_HEAD(head, field) do {				\
-+	if (((head)->sqh_first = (head)->sqh_first->field.sqe_next) == NULL) \
-+		(head)->sqh_last = &(head)->sqh_first;			\
-+} while (/*CONSTCOND*/0)
-+
-+#define SIMPLEQ_REMOVE_AFTER(head, elm, field) do {			\
-+	if (((elm)->field.sqe_next = (elm)->field.sqe_next->field.sqe_next) \
-+	    == NULL)							\
-+		(head)->sqh_last = &(elm)->field.sqe_next;		\
-+} while (/*CONSTCOND*/0)
-+
-+#define	SIMPLEQ_REMOVE(head, elm, type, field) do {			\
-+	if ((head)->sqh_first == (elm)) {				\
-+		SIMPLEQ_REMOVE_HEAD((head), field);			\
-+	} else {							\
-+		struct type *curelm = (head)->sqh_first;		\
-+		while (curelm->field.sqe_next != (elm))			\
-+			curelm = curelm->field.sqe_next;		\
-+		if ((curelm->field.sqe_next =				\
-+			curelm->field.sqe_next->field.sqe_next) == NULL) \
-+			    (head)->sqh_last = &(curelm)->field.sqe_next; \
-+	}								\
-+} while (/*CONSTCOND*/0)
-+
-+#define	SIMPLEQ_CONCAT(head1, head2) do {				\
-+	if (!SIMPLEQ_EMPTY((head2))) {					\
-+		*(head1)->sqh_last = (head2)->sqh_first;		\
-+		(head1)->sqh_last = (head2)->sqh_last;		\
-+		SIMPLEQ_INIT((head2));					\
-+	}								\
-+} while (/*CONSTCOND*/0)
-+
-+#define	SIMPLEQ_LAST(head, type, field)					\
-+	(SIMPLEQ_EMPTY((head)) ?						\
-+		NULL :							\
-+	        ((struct type *)(void *)				\
-+		((char *)((head)->sqh_last) - offsetof(struct type, field))))
-+
-+/*
-+ * Tail queue definitions.
-+ */
-+#define	_TAILQ_HEAD(name, type, qual)					\
-+struct name {								\
-+	qual type *tqh_first;		/* first element */		\
-+	qual type *qual *tqh_last;	/* addr of last next element */	\
-+}
-+#define TAILQ_HEAD(name, type)	_TAILQ_HEAD(name, struct type,)
-+
-+#define	TAILQ_HEAD_INITIALIZER(head)					\
-+	{ TAILQ_END(head), &(head).tqh_first }
-+
-+#define	_TAILQ_ENTRY(type, qual)					\
-+struct {								\
-+	qual type *tqe_next;		/* next element */		\
-+	qual type *qual *tqe_prev;	/* address of previous next element */\
-+}
-+#define TAILQ_ENTRY(type)	_TAILQ_ENTRY(struct type,)
-+
-+/*
-+ * Tail queue access methods.
-+ */
-+#define	TAILQ_FIRST(head)		((head)->tqh_first)
-+#define	TAILQ_END(head)			(NULL)
-+#define	TAILQ_NEXT(elm, field)		((elm)->field.tqe_next)
-+#define	TAILQ_LAST(head, headname) \
-+	(*(((struct headname *)((head)->tqh_last))->tqh_last))
-+#define	TAILQ_PREV(elm, headname, field) \
-+	(*(((struct headname *)((elm)->field.tqe_prev))->tqh_last))
-+#define	TAILQ_EMPTY(head)		(TAILQ_FIRST(head) == TAILQ_END(head))
-+
-+
-+#define	TAILQ_FOREACH(var, head, field)					\
-+	for ((var) = ((head)->tqh_first);				\
-+	    (var) != TAILQ_END(head);					\
-+	    (var) = ((var)->field.tqe_next))
-+
-+#define	TAILQ_FOREACH_SAFE(var, head, field, next)			\
-+	for ((var) = ((head)->tqh_first);				\
-+	    (var) != TAILQ_END(head) &&					\
-+	    ((next) = TAILQ_NEXT(var, field), 1); (var) = (next))
-+
-+#define	TAILQ_FOREACH_REVERSE(var, head, headname, field)		\
-+	for ((var) = (*(((struct headname *)((head)->tqh_last))->tqh_last));\
-+	    (var) != TAILQ_END(head);					\
-+	    (var) = (*(((struct headname *)((var)->field.tqe_prev))->tqh_last)))
-+
-+#define	TAILQ_FOREACH_REVERSE_SAFE(var, head, headname, field, prev)	\
-+	for ((var) = TAILQ_LAST((head), headname);			\
-+	    (var) != TAILQ_END(head) && 				\
-+	    ((prev) = TAILQ_PREV((var), headname, field), 1); (var) = (prev))
-+
-+/*
-+ * Tail queue functions.
-+ */
-+#if defined(QUEUEDEBUG)
-+#define	QUEUEDEBUG_TAILQ_INSERT_HEAD(head, elm, field)			\
-+	if ((head)->tqh_first &&					\
-+	    (head)->tqh_first->field.tqe_prev != &(head)->tqh_first)	\
-+		QUEUEDEBUG_ABORT("TAILQ_INSERT_HEAD %p %s:%d", (head),	\
-+		    __FILE__, __LINE__);
-+#define	QUEUEDEBUG_TAILQ_INSERT_TAIL(head, elm, field)			\
-+	if (*(head)->tqh_last != NULL)					\
-+		QUEUEDEBUG_ABORT("TAILQ_INSERT_TAIL %p %s:%d", (head),	\
-+		    __FILE__, __LINE__);
-+#define	QUEUEDEBUG_TAILQ_OP(elm, field)					\
-+	if ((elm)->field.tqe_next &&					\
-+	    (elm)->field.tqe_next->field.tqe_prev !=			\
-+	    &(elm)->field.tqe_next)					\
-+		QUEUEDEBUG_ABORT("TAILQ_* forw %p %s:%d", (elm),	\
-+		    __FILE__, __LINE__);				\
-+	if (*(elm)->field.tqe_prev != (elm))				\
-+		QUEUEDEBUG_ABORT("TAILQ_* back %p %s:%d", (elm),	\
-+		    __FILE__, __LINE__);
-+#define	QUEUEDEBUG_TAILQ_PREREMOVE(head, elm, field)			\
-+	if ((elm)->field.tqe_next == NULL &&				\
-+	    (head)->tqh_last != &(elm)->field.tqe_next)			\
-+		QUEUEDEBUG_ABORT("TAILQ_PREREMOVE head %p elm %p %s:%d",\
-+		    (head), (elm), __FILE__, __LINE__);
-+#define	QUEUEDEBUG_TAILQ_POSTREMOVE(elm, field)				\
-+	(elm)->field.tqe_next = (void *)1L;				\
-+	(elm)->field.tqe_prev = (void *)1L;
-+#else
-+#define	QUEUEDEBUG_TAILQ_INSERT_HEAD(head, elm, field)
-+#define	QUEUEDEBUG_TAILQ_INSERT_TAIL(head, elm, field)
-+#define	QUEUEDEBUG_TAILQ_OP(elm, field)
-+#define	QUEUEDEBUG_TAILQ_PREREMOVE(head, elm, field)
-+#define	QUEUEDEBUG_TAILQ_POSTREMOVE(elm, field)
-+#endif
-+
-+#define	TAILQ_INIT(head) do {						\
-+	(head)->tqh_first = TAILQ_END(head);				\
-+	(head)->tqh_last = &(head)->tqh_first;				\
-+} while (/*CONSTCOND*/0)
-+
-+#define	TAILQ_INSERT_HEAD(head, elm, field) do {			\
-+	QUEUEDEBUG_TAILQ_INSERT_HEAD((head), (elm), field)		\
-+	if (((elm)->field.tqe_next = (head)->tqh_first) != TAILQ_END(head))\
-+		(head)->tqh_first->field.tqe_prev =			\
-+		    &(elm)->field.tqe_next;				\
-+	else								\
-+		(head)->tqh_last = &(elm)->field.tqe_next;		\
-+	(head)->tqh_first = (elm);					\
-+	(elm)->field.tqe_prev = &(head)->tqh_first;			\
-+} while (/*CONSTCOND*/0)
-+
-+#define	TAILQ_INSERT_TAIL(head, elm, field) do {			\
-+	QUEUEDEBUG_TAILQ_INSERT_TAIL((head), (elm), field)		\
-+	(elm)->field.tqe_next = TAILQ_END(head);			\
-+	(elm)->field.tqe_prev = (head)->tqh_last;			\
-+	*(head)->tqh_last = (elm);					\
-+	(head)->tqh_last = &(elm)->field.tqe_next;			\
-+} while (/*CONSTCOND*/0)
-+
-+#define	TAILQ_INSERT_AFTER(head, listelm, elm, field) do {		\
-+	QUEUEDEBUG_TAILQ_OP((listelm), field)				\
-+	if (((elm)->field.tqe_next = (listelm)->field.tqe_next) != 	\
-+	    TAILQ_END(head))						\
-+		(elm)->field.tqe_next->field.tqe_prev = 		\
-+		    &(elm)->field.tqe_next;				\
-+	else								\
-+		(head)->tqh_last = &(elm)->field.tqe_next;		\
-+	(listelm)->field.tqe_next = (elm);				\
-+	(elm)->field.tqe_prev = &(listelm)->field.tqe_next;		\
-+} while (/*CONSTCOND*/0)
-+
-+#define	TAILQ_INSERT_BEFORE(listelm, elm, field) do {			\
-+	QUEUEDEBUG_TAILQ_OP((listelm), field)				\
-+	(elm)->field.tqe_prev = (listelm)->field.tqe_prev;		\
-+	(elm)->field.tqe_next = (listelm);				\
-+	*(listelm)->field.tqe_prev = (elm);				\
-+	(listelm)->field.tqe_prev = &(elm)->field.tqe_next;		\
-+} while (/*CONSTCOND*/0)
-+
-+#define	TAILQ_REMOVE(head, elm, field) do {				\
-+	QUEUEDEBUG_TAILQ_PREREMOVE((head), (elm), field)		\
-+	QUEUEDEBUG_TAILQ_OP((elm), field)				\
-+	if (((elm)->field.tqe_next) != TAILQ_END(head))			\
-+		(elm)->field.tqe_next->field.tqe_prev = 		\
-+		    (elm)->field.tqe_prev;				\
-+	else								\
-+		(head)->tqh_last = (elm)->field.tqe_prev;		\
-+	*(elm)->field.tqe_prev = (elm)->field.tqe_next;			\
-+	QUEUEDEBUG_TAILQ_POSTREMOVE((elm), field);			\
-+} while (/*CONSTCOND*/0)
-+
-+#define TAILQ_REPLACE(head, elm, elm2, field) do {			\
-+        if (((elm2)->field.tqe_next = (elm)->field.tqe_next) != 	\
-+	    TAILQ_END(head))   						\
-+                (elm2)->field.tqe_next->field.tqe_prev =		\
-+                    &(elm2)->field.tqe_next;				\
-+        else								\
-+                (head)->tqh_last = &(elm2)->field.tqe_next;		\
-+        (elm2)->field.tqe_prev = (elm)->field.tqe_prev;			\
-+        *(elm2)->field.tqe_prev = (elm2);				\
-+	QUEUEDEBUG_TAILQ_POSTREMOVE((elm), field);			\
-+} while (/*CONSTCOND*/0)
-+
-+#define	TAILQ_CONCAT(head1, head2, field) do {				\
-+	if (!TAILQ_EMPTY(head2)) {					\
-+		*(head1)->tqh_last = (head2)->tqh_first;		\
-+		(head2)->tqh_first->field.tqe_prev = (head1)->tqh_last;	\
-+		(head1)->tqh_last = (head2)->tqh_last;			\
-+		TAILQ_INIT((head2));					\
-+	}								\
-+} while (/*CONSTCOND*/0)
-+
-+/*
-+ * Singly-linked Tail queue declarations.
-+ */
-+#define	STAILQ_HEAD(name, type)						\
-+struct name {								\
-+	struct type *stqh_first;	/* first element */		\
-+	struct type **stqh_last;	/* addr of last next element */	\
-+}
-+
-+#define	STAILQ_HEAD_INITIALIZER(head)					\
-+	{ NULL, &(head).stqh_first }
-+
-+#define	STAILQ_ENTRY(type)						\
-+struct {								\
-+	struct type *stqe_next;	/* next element */			\
-+}
-+
-+/*
-+ * Singly-linked Tail queue access methods.
-+ */
-+#define	STAILQ_FIRST(head)	((head)->stqh_first)
-+#define	STAILQ_END(head)	NULL
-+#define	STAILQ_NEXT(elm, field)	((elm)->field.stqe_next)
-+#define	STAILQ_EMPTY(head)	(STAILQ_FIRST(head) == STAILQ_END(head))
-+
-+/*
-+ * Singly-linked Tail queue functions.
-+ */
-+#define	STAILQ_INIT(head) do {						\
-+	(head)->stqh_first = NULL;					\
-+	(head)->stqh_last = &(head)->stqh_first;				\
-+} while (/*CONSTCOND*/0)
-+
-+#define	STAILQ_INSERT_HEAD(head, elm, field) do {			\
-+	if (((elm)->field.stqe_next = (head)->stqh_first) == NULL)	\
-+		(head)->stqh_last = &(elm)->field.stqe_next;		\
-+	(head)->stqh_first = (elm);					\
-+} while (/*CONSTCOND*/0)
-+
-+#define	STAILQ_INSERT_TAIL(head, elm, field) do {			\
-+	(elm)->field.stqe_next = NULL;					\
-+	*(head)->stqh_last = (elm);					\
-+	(head)->stqh_last = &(elm)->field.stqe_next;			\
-+} while (/*CONSTCOND*/0)
-+
-+#define	STAILQ_INSERT_AFTER(head, listelm, elm, field) do {		\
-+	if (((elm)->field.stqe_next = (listelm)->field.stqe_next) == NULL)\
-+		(head)->stqh_last = &(elm)->field.stqe_next;		\
-+	(listelm)->field.stqe_next = (elm);				\
-+} while (/*CONSTCOND*/0)
-+
-+#define	STAILQ_REMOVE_HEAD(head, field) do {				\
-+	if (((head)->stqh_first = (head)->stqh_first->field.stqe_next) == NULL) \
-+		(head)->stqh_last = &(head)->stqh_first;			\
-+} while (/*CONSTCOND*/0)
-+
-+#define	STAILQ_REMOVE(head, elm, type, field) do {			\
-+	if ((head)->stqh_first == (elm)) {				\
-+		STAILQ_REMOVE_HEAD((head), field);			\
-+	} else {							\
-+		struct type *curelm = (head)->stqh_first;		\
-+		while (curelm->field.stqe_next != (elm))			\
-+			curelm = curelm->field.stqe_next;		\
-+		if ((curelm->field.stqe_next =				\
-+			curelm->field.stqe_next->field.stqe_next) == NULL) \
-+			    (head)->stqh_last = &(curelm)->field.stqe_next; \
-+	}								\
-+} while (/*CONSTCOND*/0)
-+
-+#define	STAILQ_FOREACH(var, head, field)				\
-+	for ((var) = ((head)->stqh_first);				\
-+		(var);							\
-+		(var) = ((var)->field.stqe_next))
-+
-+#define	STAILQ_FOREACH_SAFE(var, head, field, tvar)			\
-+	for ((var) = STAILQ_FIRST((head));				\
-+	    (var) && ((tvar) = STAILQ_NEXT((var), field), 1);		\
-+	    (var) = (tvar))
-+
-+#define	STAILQ_CONCAT(head1, head2) do {				\
-+	if (!STAILQ_EMPTY((head2))) {					\
-+		*(head1)->stqh_last = (head2)->stqh_first;		\
-+		(head1)->stqh_last = (head2)->stqh_last;		\
-+		STAILQ_INIT((head2));					\
-+	}								\
-+} while (/*CONSTCOND*/0)
-+
-+#define	STAILQ_LAST(head, type, field)					\
-+	(STAILQ_EMPTY((head)) ?						\
-+		NULL :							\
-+	        ((struct type *)(void *)				\
-+		((char *)((head)->stqh_last) - offsetof(struct type, field))))
-+
-+
-+#ifndef _KERNEL
-+/*
-+ * Circular queue definitions. Do not use. We still keep the macros
-+ * for compatibility but because of pointer aliasing issues their use
-+ * is discouraged!
-+ */
-+
-+/*
-+ * __launder_type():  We use this ugly hack to work around the the compiler
-+ * noticing that two types may not alias each other and elide tests in code.
-+ * We hit this in the CIRCLEQ macros when comparing 'struct name *' and
-+ * 'struct type *' (see CIRCLEQ_HEAD()).  Modern compilers (such as GCC
-+ * 4.8) declare these comparisons as always false, causing the code to
-+ * not run as designed.
-+ *
-+ * This hack is only to be used for comparisons and thus can be fully const.
-+ * Do not use for assignment.
-+ *
-+ * If we ever choose to change the ABI of the CIRCLEQ macros, we could fix
-+ * this by changing the head/tail sentinal values, but see the note above
-+ * this one.
-+ */
-+static __inline const void * __launder_type(const void *);
-+static __inline const void *
-+__launder_type(const void *__x)
-+{
-+	__asm __volatile("" : "+r" (__x));
-+	return __x;
-+}
-+
-+#if defined(QUEUEDEBUG)
-+#define QUEUEDEBUG_CIRCLEQ_HEAD(head, field)				\
-+	if ((head)->cqh_first != CIRCLEQ_ENDC(head) &&			\
-+	    (head)->cqh_first->field.cqe_prev != CIRCLEQ_ENDC(head))	\
-+		QUEUEDEBUG_ABORT("CIRCLEQ head forw %p %s:%d", (head),	\
-+		      __FILE__, __LINE__);				\
-+	if ((head)->cqh_last != CIRCLEQ_ENDC(head) &&			\
-+	    (head)->cqh_last->field.cqe_next != CIRCLEQ_ENDC(head))	\
-+		QUEUEDEBUG_ABORT("CIRCLEQ head back %p %s:%d", (head),	\
-+		      __FILE__, __LINE__);
-+#define QUEUEDEBUG_CIRCLEQ_ELM(head, elm, field)			\
-+	if ((elm)->field.cqe_next == CIRCLEQ_ENDC(head)) {		\
-+		if ((head)->cqh_last != (elm))				\
-+			QUEUEDEBUG_ABORT("CIRCLEQ elm last %p %s:%d",	\
-+			    (elm), __FILE__, __LINE__);			\
-+	} else {							\
-+		if ((elm)->field.cqe_next->field.cqe_prev != (elm))	\
-+			QUEUEDEBUG_ABORT("CIRCLEQ elm forw %p %s:%d",	\
-+			    (elm), __FILE__, __LINE__);			\
-+	}								\
-+	if ((elm)->field.cqe_prev == CIRCLEQ_ENDC(head)) {		\
-+		if ((head)->cqh_first != (elm))				\
-+			QUEUEDEBUG_ABORT("CIRCLEQ elm first %p %s:%d",	\
-+			    (elm), __FILE__, __LINE__);			\
-+	} else {							\
-+		if ((elm)->field.cqe_prev->field.cqe_next != (elm))	\
-+			QUEUEDEBUG_ABORT("CIRCLEQ elm prev %p %s:%d",	\
-+			    (elm), __FILE__, __LINE__);			\
-+	}
-+#define QUEUEDEBUG_CIRCLEQ_POSTREMOVE(elm, field)			\
-+	(elm)->field.cqe_next = (void *)1L;				\
-+	(elm)->field.cqe_prev = (void *)1L;
-+#else
-+#define QUEUEDEBUG_CIRCLEQ_HEAD(head, field)
-+#define QUEUEDEBUG_CIRCLEQ_ELM(head, elm, field)
-+#define QUEUEDEBUG_CIRCLEQ_POSTREMOVE(elm, field)
-+#endif
-+
-+#define	CIRCLEQ_HEAD(name, type)					\
-+struct name {								\
-+	struct type *cqh_first;		/* first element */		\
-+	struct type *cqh_last;		/* last element */		\
-+}
-+
-+#define	CIRCLEQ_HEAD_INITIALIZER(head)					\
-+	{ CIRCLEQ_END(&head), CIRCLEQ_END(&head) }
-+
-+#define	CIRCLEQ_ENTRY(type)						\
-+struct {								\
-+	struct type *cqe_next;		/* next element */		\
-+	struct type *cqe_prev;		/* previous element */		\
-+}
-+
-+/*
-+ * Circular queue functions.
-+ */
-+#define	CIRCLEQ_INIT(head) do {						\
-+	(head)->cqh_first = CIRCLEQ_END(head);				\
-+	(head)->cqh_last = CIRCLEQ_END(head);				\
-+} while (/*CONSTCOND*/0)
-+
-+#define	CIRCLEQ_INSERT_AFTER(head, listelm, elm, field) do {		\
-+	QUEUEDEBUG_CIRCLEQ_HEAD((head), field)				\
-+	QUEUEDEBUG_CIRCLEQ_ELM((head), (listelm), field)		\
-+	(elm)->field.cqe_next = (listelm)->field.cqe_next;		\
-+	(elm)->field.cqe_prev = (listelm);				\
-+	if ((listelm)->field.cqe_next == CIRCLEQ_ENDC(head))		\
-+		(head)->cqh_last = (elm);				\
-+	else								\
-+		(listelm)->field.cqe_next->field.cqe_prev = (elm);	\
-+	(listelm)->field.cqe_next = (elm);				\
-+} while (/*CONSTCOND*/0)
-+
-+#define	CIRCLEQ_INSERT_BEFORE(head, listelm, elm, field) do {		\
-+	QUEUEDEBUG_CIRCLEQ_HEAD((head), field)				\
-+	QUEUEDEBUG_CIRCLEQ_ELM((head), (listelm), field)		\
-+	(elm)->field.cqe_next = (listelm);				\
-+	(elm)->field.cqe_prev = (listelm)->field.cqe_prev;		\
-+	if ((listelm)->field.cqe_prev == CIRCLEQ_ENDC(head))		\
-+		(head)->cqh_first = (elm);				\
-+	else								\
-+		(listelm)->field.cqe_prev->field.cqe_next = (elm);	\
-+	(listelm)->field.cqe_prev = (elm);				\
-+} while (/*CONSTCOND*/0)
-+
-+#define	CIRCLEQ_INSERT_HEAD(head, elm, field) do {			\
-+	QUEUEDEBUG_CIRCLEQ_HEAD((head), field)				\
-+	(elm)->field.cqe_next = (head)->cqh_first;			\
-+	(elm)->field.cqe_prev = CIRCLEQ_END(head);			\
-+	if ((head)->cqh_last == CIRCLEQ_ENDC(head))			\
-+		(head)->cqh_last = (elm);				\
-+	else								\
-+		(head)->cqh_first->field.cqe_prev = (elm);		\
-+	(head)->cqh_first = (elm);					\
-+} while (/*CONSTCOND*/0)
-+
-+#define	CIRCLEQ_INSERT_TAIL(head, elm, field) do {			\
-+	QUEUEDEBUG_CIRCLEQ_HEAD((head), field)				\
-+	(elm)->field.cqe_next = CIRCLEQ_END(head);			\
-+	(elm)->field.cqe_prev = (head)->cqh_last;			\
-+	if ((head)->cqh_first == CIRCLEQ_ENDC(head))			\
-+		(head)->cqh_first = (elm);				\
-+	else								\
-+		(head)->cqh_last->field.cqe_next = (elm);		\
-+	(head)->cqh_last = (elm);					\
-+} while (/*CONSTCOND*/0)
-+
-+#define	CIRCLEQ_REMOVE(head, elm, field) do {				\
-+	QUEUEDEBUG_CIRCLEQ_HEAD((head), field)				\
-+	QUEUEDEBUG_CIRCLEQ_ELM((head), (elm), field)			\
-+	if ((elm)->field.cqe_next == CIRCLEQ_ENDC(head))		\
-+		(head)->cqh_last = (elm)->field.cqe_prev;		\
-+	else								\
-+		(elm)->field.cqe_next->field.cqe_prev =			\
-+		    (elm)->field.cqe_prev;				\
-+	if ((elm)->field.cqe_prev == CIRCLEQ_ENDC(head))		\
-+		(head)->cqh_first = (elm)->field.cqe_next;		\
-+	else								\
-+		(elm)->field.cqe_prev->field.cqe_next =			\
-+		    (elm)->field.cqe_next;				\
-+	QUEUEDEBUG_CIRCLEQ_POSTREMOVE((elm), field)			\
-+} while (/*CONSTCOND*/0)
-+
-+#define	CIRCLEQ_FOREACH(var, head, field)				\
-+	for ((var) = ((head)->cqh_first);				\
-+		(var) != CIRCLEQ_ENDC(head);				\
-+		(var) = ((var)->field.cqe_next))
-+
-+#define	CIRCLEQ_FOREACH_REVERSE(var, head, field)			\
-+	for ((var) = ((head)->cqh_last);				\
-+		(var) != CIRCLEQ_ENDC(head);				\
-+		(var) = ((var)->field.cqe_prev))
-+
-+/*
-+ * Circular queue access methods.
-+ */
-+#define	CIRCLEQ_FIRST(head)		((head)->cqh_first)
-+#define	CIRCLEQ_LAST(head)		((head)->cqh_last)
-+/* For comparisons */
-+#define	CIRCLEQ_ENDC(head)		(__launder_type(head))
-+/* For assignments */
-+#define	CIRCLEQ_END(head)		((void *)(head))
-+#define	CIRCLEQ_NEXT(elm, field)	((elm)->field.cqe_next)
-+#define	CIRCLEQ_PREV(elm, field)	((elm)->field.cqe_prev)
-+#define	CIRCLEQ_EMPTY(head)						\
-+    (CIRCLEQ_FIRST(head) == CIRCLEQ_ENDC(head))
-+
-+#define CIRCLEQ_LOOP_NEXT(head, elm, field)				\
-+	(((elm)->field.cqe_next == CIRCLEQ_ENDC(head))			\
-+	    ? ((head)->cqh_first)					\
-+	    : (elm->field.cqe_next))
-+#define CIRCLEQ_LOOP_PREV(head, elm, field)				\
-+	(((elm)->field.cqe_prev == CIRCLEQ_ENDC(head))			\
-+	    ? ((head)->cqh_last)					\
-+	    : (elm->field.cqe_prev))
-+#endif /* !_KERNEL */
-+
-+#endif	/* !_SYS_QUEUE_H_ */
diff --git a/poky/meta/recipes-extended/libtirpc/libtirpc/export_key_secretkey_is_set.patch b/poky/meta/recipes-extended/libtirpc/libtirpc/export_key_secretkey_is_set.patch
deleted file mode 100644
index d7f4968..0000000
--- a/poky/meta/recipes-extended/libtirpc/libtirpc/export_key_secretkey_is_set.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-Upstream-Status: Backport
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
-From e51d67549b516b2dac6c71d92c8499f6e67125ad Mon Sep 17 00:00:00 2001
-From: Thorsten Kukuk <kukuk@thkukuk.de>
-Date: Tue, 14 Nov 2017 10:43:53 -0500
-Subject: [PATCH] Fix typo in src/libtirpc.map
-
-Which prevents that key_secretkey_is_set will be exported.
-
-Signed-off-by: Thorsten Kukuk <kukuk@suse.de>
-Signed-off-by: Steve Dickson <steved@redhat.com>
----
- src/libtirpc.map | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/libtirpc.map b/src/libtirpc.map
-index f385de5..21d6065 100644
---- a/src/libtirpc.map
-+++ b/src/libtirpc.map
-@@ -298,7 +298,7 @@ TIRPC_0.3.2 {
-     key_gendes;
-     key_get_conv;
-     key_setsecret;
--    key_secret_is_set;
-+    key_secretkey_is_set;
-     key_setnet;
-     netname2host;
-     netname2user;
--- 
-1.8.3.1
diff --git a/poky/meta/recipes-extended/libtirpc/libtirpc/libtirpc-1.0.4-rc1.patch b/poky/meta/recipes-extended/libtirpc/libtirpc/libtirpc-1.0.4-rc1.patch
new file mode 100644
index 0000000..6d40d3c
--- /dev/null
+++ b/poky/meta/recipes-extended/libtirpc/libtirpc/libtirpc-1.0.4-rc1.patch
@@ -0,0 +1,103 @@
+Patch from Fedora https://src.fedoraproject.org/rpms/libtirpc/raw/master/f/libtirpc-1.0.4-rc1.patch
+
+Upstream-Status: Backport
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+diff --git a/src/clnt_generic.c b/src/clnt_generic.c
+index e5a314f..3f3dabf 100644
+--- a/src/clnt_generic.c
++++ b/src/clnt_generic.c
+@@ -47,7 +47,6 @@
+ 
+ extern bool_t __rpc_is_local_host(const char *);
+ int __rpc_raise_fd(int);
+-extern int __binddynport(int fd);
+ 
+ #ifndef NETIDLEN
+ #define	NETIDLEN 32
+@@ -341,8 +340,7 @@ clnt_tli_create(int fd, const struct netconfig *nconf,
+ 		servtype = nconf->nc_semantics;
+ 		if (!__rpc_fd2sockinfo(fd, &si))
+ 			goto err;
+-		if (__binddynport(fd) == -1)
+-			goto err;
++		bindresvport(fd, NULL);
+ 	} else {
+ 		if (!__rpc_fd2sockinfo(fd, &si))
+ 			goto err;
+diff --git a/src/rpc_soc.c b/src/rpc_soc.c
+index af6c482..5a6eeb7 100644
+--- a/src/rpc_soc.c
++++ b/src/rpc_soc.c
+@@ -67,8 +67,6 @@
+ 
+ extern mutex_t	rpcsoc_lock;
+ 
+-extern int __binddynport(int fd);
+-
+ static CLIENT *clnt_com_create(struct sockaddr_in *, rpcprog_t, rpcvers_t,
+     int *, u_int, u_int, char *, int);
+ static SVCXPRT *svc_com_create(int, u_int, u_int, char *);
+@@ -147,8 +145,7 @@ clnt_com_create(raddr, prog, vers, sockp, sendsz, recvsz, tp, flags)
+ 	bindaddr.maxlen = bindaddr.len =  sizeof (struct sockaddr_in);
+ 	bindaddr.buf = raddr;
+ 
+-	if (__binddynport(fd) == -1)
+-		goto err;
++	bindresvport(fd, NULL);
+ 	cl = clnt_tli_create(fd, nconf, &bindaddr, prog, vers,
+ 				sendsz, recvsz);
+ 	if (cl) {
+diff --git a/src/rpcb_clnt.c b/src/rpcb_clnt.c
+index a94fc73..4b44364 100644
+--- a/src/rpcb_clnt.c
++++ b/src/rpcb_clnt.c
+@@ -752,7 +752,7 @@ __try_protocol_version_2(program, version, nconf, host, tp)
+ 
+ 	client = getpmaphandle(nconf, host, &parms.r_addr);
+ 	if (client == NULL)
+-		return (NULL);
++		goto error;
+ 
+ 	/*
+ 	 * Set retry timeout.
+@@ -771,11 +771,11 @@ __try_protocol_version_2(program, version, nconf, host, tp)
+ 	if (clnt_st != RPC_SUCCESS) {
+ 		rpc_createerr.cf_stat = RPC_PMAPFAILURE;
+ 		clnt_geterr(client, &rpc_createerr.cf_error);
+-		return (NULL);
++		goto error;
+ 	} else if (port == 0) {
+ 		pmapaddress = NULL;
+ 		rpc_createerr.cf_stat = RPC_PROGNOTREGISTERED;
+-		return (NULL);
++		goto error;
+ 	}
+ 	port = htons(port);
+ 	CLNT_CONTROL(client, CLGET_SVC_ADDR, (char *)&remote);
+@@ -789,14 +789,24 @@ __try_protocol_version_2(program, version, nconf, host, tp)
+ 			free(pmapaddress);
+ 			pmapaddress = NULL;
+ 		}
+-		return (NULL);
++		goto error;
+ 	}
+ 	memcpy(pmapaddress->buf, remote.buf, remote.len);
+ 	memcpy(&((char *)pmapaddress->buf)[sizeof (short)],
+ 			(char *)(void *)&port, sizeof (short));
+ 	pmapaddress->len = pmapaddress->maxlen = remote.len;
+ 
++	CLNT_DESTROY(client);
+ 	return pmapaddress;
++
++error:
++	if (client) {
++		CLNT_DESTROY(client);
++		client = NULL;
++
++	}
++	return (NULL);
++
+ }
+ #endif
+ 
diff --git a/poky/meta/recipes-extended/libtirpc/libtirpc/musl.patch b/poky/meta/recipes-extended/libtirpc/libtirpc/musl.patch
new file mode 100644
index 0000000..0c3ce60
--- /dev/null
+++ b/poky/meta/recipes-extended/libtirpc/libtirpc/musl.patch
@@ -0,0 +1,18 @@
+Consider musl provided built-in defines
+
+Helps compile libtirpc with musl
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+--- ./tirpc/rpc/types.h.orig	2018-03-17 10:23:10.022055255 +0100
++++ ./tirpc/rpc/types.h	2018-03-17 10:23:30.877751656 +0100
+@@ -66,7 +66,7 @@
+ #define mem_free(ptr, bsize)	free(ptr)
+ 
+ 
+-#if defined __APPLE_CC__ || defined __FreeBSD__
++#if defined __APPLE_CC__ || defined __FreeBSD__ || !defined(__GLIBC__)
+ # define __u_char_defined
+ # define __daddr_t_defined
+ #endif
diff --git a/poky/meta/recipes-extended/libtirpc/libtirpc_1.0.2.bb b/poky/meta/recipes-extended/libtirpc/libtirpc_1.0.2.bb
deleted file mode 100644
index 9921260..0000000
--- a/poky/meta/recipes-extended/libtirpc/libtirpc_1.0.2.bb
+++ /dev/null
@@ -1,33 +0,0 @@
-SUMMARY = "Transport-Independent RPC library"
-DESCRIPTION = "Libtirpc is a port of Suns Transport-Independent RPC library to Linux"
-SECTION = "libs/network"
-HOMEPAGE = "http://sourceforge.net/projects/libtirpc/"
-BUGTRACKER = "http://sourceforge.net/tracker/?group_id=183075&atid=903784"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=f835cce8852481e4b2bbbdd23b5e47f3 \
-                    file://src/netname.c;beginline=1;endline=27;md5=f8a8cd2cb25ac5aa16767364fb0e3c24"
-
-PROVIDES = "virtual/librpc"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BP}.tar.bz2 \
-           file://export_key_secretkey_is_set.patch \
-           file://0001-replace-__bzero-with-memset-API.patch \
-           file://0001-include-stdint.h-for-uintptr_t.patch \
-           "
-
-SRC_URI_append_libc-musl = " \
-                             file://Use-netbsd-queue.h.patch \
-                           "
-
-SRC_URI[md5sum] = "d5a37f1dccec484f9cabe2b97e54e9a6"
-SRC_URI[sha256sum] = "723c5ce92706cbb601a8db09110df1b4b69391643158f20ff587e20e7c5f90f5"
-
-inherit autotools pkgconfig
-
-EXTRA_OECONF = "--disable-gssapi"
-
-do_install_append() {
-        chown root:root ${D}${sysconfdir}/netconfig
-}
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/libtirpc/libtirpc_1.0.3.bb b/poky/meta/recipes-extended/libtirpc/libtirpc_1.0.3.bb
new file mode 100644
index 0000000..17bc038
--- /dev/null
+++ b/poky/meta/recipes-extended/libtirpc/libtirpc_1.0.3.bb
@@ -0,0 +1,28 @@
+SUMMARY = "Transport-Independent RPC library"
+DESCRIPTION = "Libtirpc is a port of Suns Transport-Independent RPC library to Linux"
+SECTION = "libs/network"
+HOMEPAGE = "http://sourceforge.net/projects/libtirpc/"
+BUGTRACKER = "http://sourceforge.net/tracker/?group_id=183075&atid=903784"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=f835cce8852481e4b2bbbdd23b5e47f3 \
+                    file://src/netname.c;beginline=1;endline=27;md5=f8a8cd2cb25ac5aa16767364fb0e3c24"
+
+PROVIDES = "virtual/librpc"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BP}.tar.bz2 \
+           file://libtirpc-1.0.4-rc1.patch \
+           file://musl.patch \
+           "
+
+SRC_URI[md5sum] = "f8403a10695348854e71d525c4db5931"
+SRC_URI[sha256sum] = "86c3a78fc1bddefa96111dd233124c703b22a78884203c55c3e06b3be6a0fd5e"
+
+inherit autotools pkgconfig
+
+EXTRA_OECONF = "--disable-gssapi"
+
+do_install_append() {
+        chown root:root ${D}${sysconfdir}/netconfig
+}
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/lighttpd/lighttpd_1.4.48.bb b/poky/meta/recipes-extended/lighttpd/lighttpd_1.4.48.bb
deleted file mode 100644
index 3c4444c..0000000
--- a/poky/meta/recipes-extended/lighttpd/lighttpd_1.4.48.bb
+++ /dev/null
@@ -1,85 +0,0 @@
-SUMMARY = "Lightweight high-performance web server"
-HOMEPAGE = "http://www.lighttpd.net/"
-BUGTRACKER = "http://redmine.lighttpd.net/projects/lighttpd/issues"
-
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=e4dac5c6ab169aa212feb5028853a579"
-
-SECTION = "net"
-RDEPENDS_${PN} = "lighttpd-module-dirlisting \
-                  lighttpd-module-indexfile \
-                  lighttpd-module-staticfile"
-RRECOMMENDS_${PN} = "lighttpd-module-access \
-                     lighttpd-module-accesslog"
-
-SRC_URI = "http://download.lighttpd.net/lighttpd/releases-1.4.x/lighttpd-${PV}.tar.xz \
-        file://index.html.lighttpd \
-        file://lighttpd.conf \
-        file://lighttpd \
-        file://lighttpd.service \
-        file://0001-Use-pkg-config-for-pcre-dependency-instead-of-config.patch \
-        "
-
-SRC_URI[md5sum] = "1e3a9eb5078f481e3a8a1d0aaac8c3c8"
-SRC_URI[sha256sum] = "0f8ad5aac7529d7b948b9d7e8cd0b4a9e177309d85d6bf6516e28e6e40d74f36"
-
-PACKAGECONFIG ??= "openssl pcre zlib \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'xattr', 'attr', '', d)} \
-"
-
-PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6"
-PACKAGECONFIG[mmap] = "--enable-mmap,--disable-mmap"
-PACKAGECONFIG[libev] = "--with-libev,--without-libev,libev"
-PACKAGECONFIG[mysql] = "--with-mysql,--without-mysql,mariadb"
-PACKAGECONFIG[ldap] = "--with-ldap,--without-ldap,openldap"
-PACKAGECONFIG[attr] = "--with-attr,--without-attr,attr"
-PACKAGECONFIG[valgrind] = "--with-valgrind,--without-valgrind,valgrind"
-PACKAGECONFIG[openssl] = "--with-openssl,--without-openssl,openssl"
-PACKAGECONFIG[krb5] = "--with-krb5,--without-krb5,krb5"
-PACKAGECONFIG[pcre] = "--with-pcre,--without-pcre,libpcre"
-PACKAGECONFIG[zlib] = "--with-zlib,--without-zlib,zlib"
-PACKAGECONFIG[bzip2] = "--with-bzip2,--without-bzip2,bzip2"
-PACKAGECONFIG[fam] = "--with-fam,--without-fam,gamin"
-PACKAGECONFIG[webdav-props] = "--with-webdav-props,--without-webdav-props,libxml2 sqlite3"
-PACKAGECONFIG[webdav-locks] = "--with-webdav-locks,--without-webdav-locks,util-linux"
-PACKAGECONFIG[gdbm] = "--with-gdbm,--without-gdbm,gdbm"
-PACKAGECONFIG[memcache] = "--with-memcached,--without-memcached,libmemcached"
-PACKAGECONFIG[lua] = "--with-lua,--without-lua,lua5.1"
-
-EXTRA_OECONF += "--enable-lfs"
-
-inherit autotools pkgconfig update-rc.d gettext systemd
-
-INITSCRIPT_NAME = "lighttpd"
-INITSCRIPT_PARAMS = "defaults 70"
-
-SYSTEMD_SERVICE_${PN} = "lighttpd.service"
-
-do_install_append() {
-	install -d ${D}${sysconfdir}/init.d ${D}${sysconfdir}/lighttpd.d ${D}/www/pages/dav
-	install -m 0755 ${WORKDIR}/lighttpd ${D}${sysconfdir}/init.d
-	install -m 0644 ${WORKDIR}/lighttpd.conf ${D}${sysconfdir}
-	install -m 0644 ${WORKDIR}/index.html.lighttpd ${D}/www/pages/index.html
-
-	install -d ${D}${systemd_unitdir}/system
-	install -m 0644 ${WORKDIR}/lighttpd.service ${D}${systemd_unitdir}/system
-	sed -i -e 's,@SBINDIR@,${sbindir},g' \
-		-e 's,@SYSCONFDIR@,${sysconfdir},g' \
-		-e 's,@BASE_BINDIR@,${base_bindir},g' \
-		${D}${systemd_unitdir}/system/lighttpd.service
-	#For FHS compliance, create symbolic links to /var/log and /var/tmp for logs and temporary data
-	ln -sf ${localstatedir}/log ${D}/www/logs
-	ln -sf ${localstatedir}/tmp ${D}/www/var
-}
-
-FILES_${PN} += "${sysconfdir} /www"
-
-CONFFILES_${PN} = "${sysconfdir}/lighttpd.conf"
-
-PACKAGES_DYNAMIC += "^lighttpd-module-.*"
-
-python populate_packages_prepend () {
-    lighttpd_libdir = d.expand('${libdir}')
-    do_split_packages(d, lighttpd_libdir, '^mod_(.*)\.so$', 'lighttpd-module-%s', 'Lighttpd module for %s', extra_depends='')
-}
diff --git a/poky/meta/recipes-extended/lighttpd/lighttpd_1.4.50.bb b/poky/meta/recipes-extended/lighttpd/lighttpd_1.4.50.bb
new file mode 100644
index 0000000..5373a61
--- /dev/null
+++ b/poky/meta/recipes-extended/lighttpd/lighttpd_1.4.50.bb
@@ -0,0 +1,85 @@
+SUMMARY = "Lightweight high-performance web server"
+HOMEPAGE = "http://www.lighttpd.net/"
+BUGTRACKER = "http://redmine.lighttpd.net/projects/lighttpd/issues"
+
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=e4dac5c6ab169aa212feb5028853a579"
+
+SECTION = "net"
+RDEPENDS_${PN} = "lighttpd-module-dirlisting \
+                  lighttpd-module-indexfile \
+                  lighttpd-module-staticfile"
+RRECOMMENDS_${PN} = "lighttpd-module-access \
+                     lighttpd-module-accesslog"
+
+SRC_URI = "http://download.lighttpd.net/lighttpd/releases-1.4.x/lighttpd-${PV}.tar.xz \
+        file://index.html.lighttpd \
+        file://lighttpd.conf \
+        file://lighttpd \
+        file://lighttpd.service \
+        file://0001-Use-pkg-config-for-pcre-dependency-instead-of-config.patch \
+        "
+
+SRC_URI[md5sum] = "0547831efda8492648b7f0c652865dfd"
+SRC_URI[sha256sum] = "29378312d8887cbc14ffe8a7fadef2d5a08c7e7e1be942795142346ad95629eb"
+
+PACKAGECONFIG ??= "openssl pcre zlib \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'xattr', 'attr', '', d)} \
+"
+
+PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6"
+PACKAGECONFIG[mmap] = "--enable-mmap,--disable-mmap"
+PACKAGECONFIG[libev] = "--with-libev,--without-libev,libev"
+PACKAGECONFIG[mysql] = "--with-mysql,--without-mysql,mariadb"
+PACKAGECONFIG[ldap] = "--with-ldap,--without-ldap,openldap"
+PACKAGECONFIG[attr] = "--with-attr,--without-attr,attr"
+PACKAGECONFIG[valgrind] = "--with-valgrind,--without-valgrind,valgrind"
+PACKAGECONFIG[openssl] = "--with-openssl,--without-openssl,openssl"
+PACKAGECONFIG[krb5] = "--with-krb5,--without-krb5,krb5"
+PACKAGECONFIG[pcre] = "--with-pcre,--without-pcre,libpcre"
+PACKAGECONFIG[zlib] = "--with-zlib,--without-zlib,zlib"
+PACKAGECONFIG[bzip2] = "--with-bzip2,--without-bzip2,bzip2"
+PACKAGECONFIG[fam] = "--with-fam,--without-fam,gamin"
+PACKAGECONFIG[webdav-props] = "--with-webdav-props,--without-webdav-props,libxml2 sqlite3"
+PACKAGECONFIG[webdav-locks] = "--with-webdav-locks,--without-webdav-locks,util-linux"
+PACKAGECONFIG[gdbm] = "--with-gdbm,--without-gdbm,gdbm"
+PACKAGECONFIG[memcache] = "--with-memcached,--without-memcached,libmemcached"
+PACKAGECONFIG[lua] = "--with-lua,--without-lua,lua5.1"
+
+EXTRA_OECONF += "--enable-lfs"
+
+inherit autotools pkgconfig update-rc.d gettext systemd
+
+INITSCRIPT_NAME = "lighttpd"
+INITSCRIPT_PARAMS = "defaults 70"
+
+SYSTEMD_SERVICE_${PN} = "lighttpd.service"
+
+do_install_append() {
+	install -d ${D}${sysconfdir}/init.d ${D}${sysconfdir}/lighttpd.d ${D}/www/pages/dav
+	install -m 0755 ${WORKDIR}/lighttpd ${D}${sysconfdir}/init.d
+	install -m 0644 ${WORKDIR}/lighttpd.conf ${D}${sysconfdir}
+	install -m 0644 ${WORKDIR}/index.html.lighttpd ${D}/www/pages/index.html
+
+	install -d ${D}${systemd_unitdir}/system
+	install -m 0644 ${WORKDIR}/lighttpd.service ${D}${systemd_unitdir}/system
+	sed -i -e 's,@SBINDIR@,${sbindir},g' \
+		-e 's,@SYSCONFDIR@,${sysconfdir},g' \
+		-e 's,@BASE_BINDIR@,${base_bindir},g' \
+		${D}${systemd_unitdir}/system/lighttpd.service
+	#For FHS compliance, create symbolic links to /var/log and /var/tmp for logs and temporary data
+	ln -sf ${localstatedir}/log ${D}/www/logs
+	ln -sf ${localstatedir}/tmp ${D}/www/var
+}
+
+FILES_${PN} += "${sysconfdir} /www"
+
+CONFFILES_${PN} = "${sysconfdir}/lighttpd.conf"
+
+PACKAGES_DYNAMIC += "^lighttpd-module-.*"
+
+python populate_packages_prepend () {
+    lighttpd_libdir = d.expand('${libdir}')
+    do_split_packages(d, lighttpd_libdir, '^mod_(.*)\.so$', 'lighttpd-module-%s', 'Lighttpd module for %s', extra_depends='')
+}
diff --git a/poky/meta/recipes-extended/logrotate/logrotate_3.13.0.bb b/poky/meta/recipes-extended/logrotate/logrotate_3.13.0.bb
deleted file mode 100644
index 990cf91..0000000
--- a/poky/meta/recipes-extended/logrotate/logrotate_3.13.0.bb
+++ /dev/null
@@ -1,85 +0,0 @@
-SUMMARY = "Rotates, compresses, removes and mails system log files"
-SECTION = "console/utils"
-HOMEPAGE = "https://github.com/logrotate/logrotate/issues"
-LICENSE = "GPLv2"
-
-# TODO: Document coreutils dependency. Why not RDEPENDS? Why not busybox?
-
-DEPENDS="coreutils popt"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-
-# When updating logrotate to latest upstream, SRC_URI should point to
-# a proper release tarball from https://github.com/logrotate/logrotate/releases
-# and we have to take the snapshot for now because there is no such
-# tarball available for 3.9.1.
-
-S = "${WORKDIR}/${BPN}-${PV}"
-
-UPSTREAM_CHECK_URI = "https://github.com/${BPN}/${BPN}/releases"
-UPSTREAM_CHECK_REGEX = "logrotate-(?P<pver>\d+(\.\d+)+).tar"
-
-SRC_URI = "https://github.com/${BPN}/${BPN}/releases/download/${PV}/${BP}.tar.xz \
-            file://act-as-mv-when-rotate.patch \
-            file://update-the-manual.patch \
-            file://disable-check-different-filesystems.patch \
-            "
-
-SRC_URI[md5sum] = "78ef24d6fddcc4df8e412dd75c551b4c"
-SRC_URI[sha256sum] = "3222ca032f99be8d7a4a8c6ad69f3dcc49b9511bfe384bd5a271ebcd9bd3e52c"
-
-PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'acl selinux', d)}"
-
-PACKAGECONFIG[acl] = ",,acl"
-PACKAGECONFIG[selinux] = ",,libselinux"
-
-CONFFILES_${PN} += "${localstatedir}/lib/logrotate.status \
-		    ${sysconfdir}/logrotate.conf"
-
-# If RPM_OPT_FLAGS is unset, it adds -g itself rather than obeying our
-# optimization variables, so use it rather than EXTRA_CFLAGS.
-EXTRA_OEMAKE = "\
-    LFS= \
-    OS_NAME='${OS_NAME}' \
-    'CC=${CC}' \
-    'RPM_OPT_FLAGS=${CFLAGS}' \
-    'EXTRA_LDFLAGS=${LDFLAGS}' \
-    ${@bb.utils.contains('PACKAGECONFIG', 'acl', 'WITH_ACL=yes', '', d)} \
-    ${@bb.utils.contains('PACKAGECONFIG', 'selinux', 'WITH_SELINUX=yes', '', d)} \
-"
-
-# OS_NAME in the makefile defaults to `uname -s`. The behavior for
-# freebsd/netbsd is questionable, so leave it as Linux, which only sets
-# INSTALL=install and BASEDIR=/usr.
-OS_NAME = "Linux"
-
-inherit autotools systemd
-
-SYSTEMD_SERVICE_${PN} = "\
-    ${BPN}.service \
-    ${BPN}.timer \
-"
-
-LOGROTATE_SYSTEMD_TIMER_BASIS ?= "daily"
-LOGROTATE_SYSTEMD_TIMER_ACCURACY ?= "12h"
-
-do_install(){
-    oe_runmake install DESTDIR=${D} PREFIX=${D} MANDIR=${mandir}
-    mkdir -p ${D}${sysconfdir}/logrotate.d
-    mkdir -p ${D}${localstatedir}/lib
-    install -p -m 644 ${S}/examples/logrotate-default ${D}${sysconfdir}/logrotate.conf
-    touch ${D}${localstatedir}/lib/logrotate.status
-
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-        install -d ${D}${systemd_system_unitdir}
-        install -m 0644 ${S}/examples/logrotate.service ${D}${systemd_system_unitdir}/logrotate.service
-        install -m 0644 ${S}/examples/logrotate.timer ${D}${systemd_system_unitdir}/logrotate.timer
-        sed -i -e 's,OnCalendar=.*$,OnCalendar=${LOGROTATE_SYSTEMD_TIMER_BASIS},g' ${D}${systemd_system_unitdir}/logrotate.timer
-        sed -i -e 's,AccuracySec=.*$,AccuracySec=${LOGROTATE_SYSTEMD_TIMER_ACCURACY},g' ${D}${systemd_system_unitdir}/logrotate.timer
-    fi
-
-    if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
-        mkdir -p ${D}${sysconfdir}/cron.daily
-        install -p -m 0755 ${S}/examples/logrotate.cron ${D}${sysconfdir}/cron.daily/logrotate
-    fi
-}
diff --git a/poky/meta/recipes-extended/logrotate/logrotate_3.14.0.bb b/poky/meta/recipes-extended/logrotate/logrotate_3.14.0.bb
new file mode 100644
index 0000000..ccc68ad
--- /dev/null
+++ b/poky/meta/recipes-extended/logrotate/logrotate_3.14.0.bb
@@ -0,0 +1,99 @@
+SUMMARY = "Rotates, compresses, removes and mails system log files"
+SECTION = "console/utils"
+HOMEPAGE = "https://github.com/logrotate/logrotate/issues"
+LICENSE = "GPLv2"
+
+# TODO: Document coreutils dependency. Why not RDEPENDS? Why not busybox?
+
+DEPENDS="coreutils popt"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+# When updating logrotate to latest upstream, SRC_URI should point to
+# a proper release tarball from https://github.com/logrotate/logrotate/releases
+# and we have to take the snapshot for now because there is no such
+# tarball available for 3.9.1.
+
+S = "${WORKDIR}/${BPN}-${PV}"
+
+UPSTREAM_CHECK_URI = "https://github.com/${BPN}/${BPN}/releases"
+UPSTREAM_CHECK_REGEX = "logrotate-(?P<pver>\d+(\.\d+)+).tar"
+
+SRC_URI = "https://github.com/${BPN}/${BPN}/releases/download/${PV}/${BP}.tar.xz \
+            file://act-as-mv-when-rotate.patch \
+            file://update-the-manual.patch \
+            file://disable-check-different-filesystems.patch \
+            "
+
+SRC_URI[md5sum] = "1c0f6e6e490c4bcac0a1e77ad1310683"
+SRC_URI[sha256sum] = "4703bdc0e2df3b322f9dff0aafc99aa9172c9e4acae28b7c924cc7d4e5b29d55"
+
+PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'acl selinux', d)}"
+
+PACKAGECONFIG[acl] = ",,acl"
+PACKAGECONFIG[selinux] = ",,libselinux"
+
+CONFFILES_${PN} += "${localstatedir}/lib/logrotate.status \
+                    ${sysconfdir}/logrotate.conf \
+                    ${sysconfdir}/logrotate.d/btmp \
+                    ${sysconfdir}/logrotate.d/wtmp"
+
+# If RPM_OPT_FLAGS is unset, it adds -g itself rather than obeying our
+# optimization variables, so use it rather than EXTRA_CFLAGS.
+EXTRA_OEMAKE = "\
+    LFS= \
+    OS_NAME='${OS_NAME}' \
+    'CC=${CC}' \
+    'RPM_OPT_FLAGS=${CFLAGS}' \
+    'EXTRA_LDFLAGS=${LDFLAGS}' \
+    ${@bb.utils.contains('PACKAGECONFIG', 'acl', 'WITH_ACL=yes', '', d)} \
+    ${@bb.utils.contains('PACKAGECONFIG', 'selinux', 'WITH_SELINUX=yes', '', d)} \
+"
+
+# OS_NAME in the makefile defaults to `uname -s`. The behavior for
+# freebsd/netbsd is questionable, so leave it as Linux, which only sets
+# INSTALL=install and BASEDIR=/usr.
+OS_NAME = "Linux"
+
+inherit autotools systemd
+
+SYSTEMD_SERVICE_${PN} = "\
+    ${BPN}.service \
+    ${BPN}.timer \
+"
+
+LOGROTATE_OPTIONS ?= ""
+
+LOGROTATE_SYSTEMD_TIMER_BASIS ?= "daily"
+LOGROTATE_SYSTEMD_TIMER_ACCURACY ?= "12h"
+LOGROTATE_SYSTEMD_TIMER_PERSISTENT ?= "true"
+
+do_install(){
+    oe_runmake install DESTDIR=${D} PREFIX=${D} MANDIR=${mandir}
+    mkdir -p ${D}${sysconfdir}/logrotate.d
+    mkdir -p ${D}${localstatedir}/lib
+    install -p -m 644 ${S}/examples/logrotate-default ${D}${sysconfdir}/logrotate.conf
+    install -p -m 644 ${S}/examples/btmp ${D}${sysconfdir}/logrotate.d/btmp
+    install -p -m 644 ${S}/examples/wtmp ${D}${sysconfdir}/logrotate.d/wtmp
+    touch ${D}${localstatedir}/lib/logrotate.status
+
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+        install -d ${D}${systemd_system_unitdir}
+        install -m 0644 ${S}/examples/logrotate.service ${D}${systemd_system_unitdir}/logrotate.service
+        install -m 0644 ${S}/examples/logrotate.timer ${D}${systemd_system_unitdir}/logrotate.timer
+        [ -z "${LOGROTATE_OPTIONS}" ] ||
+            sed -ri \
+                -e 's|(ExecStart=.*/logrotate.*)$|\1 ${LOGROTATE_OPTIONS}|g' \
+                ${D}${systemd_system_unitdir}/logrotate.service
+        sed -ri \
+            -e 's|(OnCalendar=).*$|\1${LOGROTATE_SYSTEMD_TIMER_BASIS}|g' \
+            -e 's|(AccuracySec=).*$|\1${LOGROTATE_SYSTEMD_TIMER_ACCURACY}|g' \
+            -e 's|(Persistent=).*$|\1${LOGROTATE_SYSTEMD_TIMER_PERSISTENT}|g' \
+            ${D}${systemd_system_unitdir}/logrotate.timer
+    fi
+
+    if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
+        mkdir -p ${D}${sysconfdir}/cron.daily
+        install -p -m 0755 ${S}/examples/logrotate.cron ${D}${sysconfdir}/cron.daily/logrotate
+    fi
+}
diff --git a/poky/meta/recipes-extended/lsb/lsb_5.0.bb b/poky/meta/recipes-extended/lsb/lsb_5.0.bb
index df4812e..d1de334 100644
--- a/poky/meta/recipes-extended/lsb/lsb_5.0.bb
+++ b/poky/meta/recipes-extended/lsb/lsb_5.0.bb
@@ -34,7 +34,7 @@
 CLEANBROKEN = "1"
 
 do_install() {
-	oe_runmake install prefix=${D}${base_prefix} mandir=${D}${datadir}/man/ DESTDIR=${D}
+	oe_runmake install prefix=${D}${root_prefix} mandir=${D}${datadir}/man/ DESTDIR=${D}
 
 	# these two dirs are needed by package lsb-dist-checker
 	mkdir -p ${D}${sysconfdir}/opt
@@ -99,7 +99,9 @@
        fi
 
        if [ "${TARGET_ARCH}" = "x86_64" ]; then
-               if [ "${base_libdir}" != "${base_prefix}/lib64" ]; then
+       	       # don't symlink if usrmerge is in DISTRO_FEATURES as it manages the symlink
+               if ${@bb.utils.contains('DISTRO_FEATURES','usrmerge','false','true',d)} && \
+	       	  [ "${base_libdir}" != "${base_prefix}/lib64" ]; then
                    lnr ${D}${base_libdir} ${D}${base_prefix}/lib64
                fi
 	       cd ${D}${base_libdir}
diff --git a/poky/meta/recipes-extended/lsb/lsbinitscripts_9.79.bb b/poky/meta/recipes-extended/lsb/lsbinitscripts_9.79.bb
index 46edeed..6d3fcf1 100644
--- a/poky/meta/recipes-extended/lsb/lsbinitscripts_9.79.bb
+++ b/poky/meta/recipes-extended/lsb/lsbinitscripts_9.79.bb
@@ -2,7 +2,6 @@
 HOMEPAGE = "https://wiki.debian.org/LSBInitScripts"
 SECTION = "base"
 LICENSE = "GPLv2"
-DEPENDS = "popt glib-2.0"
 
 RPROVIDES_${PN} += "initd-functions"
 RDEPENDS_${PN} += "util-linux"
diff --git a/poky/meta/recipes-extended/lsof/lsof_4.89.bb b/poky/meta/recipes-extended/lsof/lsof_4.89.bb
deleted file mode 100644
index 14546db..0000000
--- a/poky/meta/recipes-extended/lsof/lsof_4.89.bb
+++ /dev/null
@@ -1,64 +0,0 @@
-SUMMARY = "LiSt Open Files tool"
-DESCRIPTION = "Lsof is a Unix-specific diagnostic tool. \
-Its name stands for LiSt Open Files, and it does just that."
-HOMEPAGE = "http://people.freebsd.org/~abe/"
-SECTION = "devel"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://00README;beginline=645;endline=679;md5=964df275d26429ba3b39dbb9f205172a"
-
-# Upstream lsof releases are hosted on an ftp server which times out download
-# attempts from hosts for which it can not perform a DNS reverse-lookup (See:
-# https://people.freebsd.org/~abe/ ). http://www.mirrorservice.org seems to be
-# the most commonly used alternative.
-
-SRC_URI = "http://www.mirrorservice.org/sites/lsof.itap.purdue.edu/pub/tools/unix/lsof/lsof_${PV}.tar.bz2 \
-           file://lsof-remove-host-information.patch \
-          "
-
-SRC_URI[md5sum] = "1b9cd34f3fb86856a125abbf2be3a386"
-SRC_URI[sha256sum] = "81ac2fc5fdc944793baf41a14002b6deb5a29096b387744e28f8c30a360a3718"
-
-LOCALSRC = "file://${WORKDIR}/lsof_${PV}/lsof_${PV}_src.tar"
-
-S = "${WORKDIR}/lsof_${PV}_src"
-
-python do_unpack () {
-    # temporarily change S for unpack
-    # of lsof_${PV}
-    s = d.getVar('S', False)
-    d.setVar('S', '${WORKDIR}/lsof_${PV}')
-    bb.build.exec_func('base_do_unpack', d)
-    # temporarily change SRC_URI for unpack
-    # of lsof_${PV}_src
-    src_uri = d.getVar('SRC_URI', False)
-    d.setVar('SRC_URI', '${LOCALSRC}')
-    d.setVar('S', s)
-    bb.build.exec_func('base_do_unpack', d)
-    d.setVar('SRC_URI', src_uri)
-}
-
-export LSOF_INCLUDE = "${STAGING_INCDIR}"
-
-do_configure () {
-	export LSOF_AR="${AR} cr"
-	export LSOF_RANLIB="${RANLIB}"
-	if [ "x${GLIBCVERSION}" != "x" ]; then
-		LINUX_CLIB=`echo ${GLIBCVERSION} |sed -e 's,\.,,g'`
-		LINUX_CLIB="-DGLIBCV=${LINUX_CLIB}"
-		export LINUX_CLIB
-	fi
-	yes | ./Configure linux
-}
-
-export I = "${STAGING_INCDIR}"
-export L = "${STAGING_INCDIR}"
-
-do_compile () {
-	oe_runmake 'CC=${CC}' 'CFGL=${LDFLAGS} -L./lib -llsof' 'DEBUG=' 'INCL=${CFLAGS}'
-}
-
-do_install () {
-	install -d ${D}${sbindir} ${D}${mandir}/man8
-	install -m 0755 lsof ${D}${sbindir}/lsof
-	install -m 0644 lsof.8 ${D}${mandir}/man8/lsof.8
-}
diff --git a/poky/meta/recipes-extended/lsof/lsof_4.91.bb b/poky/meta/recipes-extended/lsof/lsof_4.91.bb
new file mode 100644
index 0000000..b3adfd5
--- /dev/null
+++ b/poky/meta/recipes-extended/lsof/lsof_4.91.bb
@@ -0,0 +1,63 @@
+SUMMARY = "LiSt Open Files tool"
+DESCRIPTION = "Lsof is a Unix-specific diagnostic tool. \
+Its name stands for LiSt Open Files, and it does just that."
+HOMEPAGE = "http://people.freebsd.org/~abe/"
+SECTION = "devel"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://00README;beginline=645;endline=679;md5=964df275d26429ba3b39dbb9f205172a"
+
+# Upstream lsof releases are hosted on an ftp server which times out download
+# attempts from hosts for which it can not perform a DNS reverse-lookup (See:
+# https://people.freebsd.org/~abe/ ). http://www.mirrorservice.org seems to be
+# the most commonly used alternative.
+
+SRC_URI = "http://www.mirrorservice.org/sites/lsof.itap.purdue.edu/pub/tools/unix/lsof/lsof_${PV}.tar.bz2 \
+           file://lsof-remove-host-information.patch \
+          "
+
+SRC_URI[md5sum] = "148ed410cb52e08c2adc0c60f480f11f"
+SRC_URI[sha256sum] = "c9da946a525fbf82ff80090b6d1879c38df090556f3fe0e6d782cb44172450a3"
+
+LOCALSRC = "file://${WORKDIR}/lsof_${PV}/lsof_${PV}_src.tar"
+
+S = "${WORKDIR}/lsof_${PV}_src"
+
+python do_unpack () {
+    if not bb.data.inherits_class('externalsrc', d) or not d.getVar('EXTERNALSRC'):
+        # temporarily change S for unpack of lsof_${PV}
+        s = d.getVar('S', False)
+        d.setVar('S', '${WORKDIR}/lsof_${PV}')
+        bb.build.exec_func('base_do_unpack', d)
+        # temporarily change SRC_URI for unpack of lsof_${PV}_src
+        src_uri = d.getVar('SRC_URI', False)
+        d.setVar('SRC_URI', '${LOCALSRC}')
+        d.setVar('S', s)
+        bb.build.exec_func('base_do_unpack', d)
+        d.setVar('SRC_URI', src_uri)
+}
+
+export LSOF_INCLUDE = "${STAGING_INCDIR}"
+
+do_configure () {
+	export LSOF_AR="${AR} cr"
+	export LSOF_RANLIB="${RANLIB}"
+	if [ "x${GLIBCVERSION}" != "x" ]; then
+		LINUX_CLIB=`echo ${GLIBCVERSION} |sed -e 's,\.,,g'`
+		LINUX_CLIB="-DGLIBCV=${LINUX_CLIB}"
+		export LINUX_CLIB
+	fi
+	yes | ./Configure linux
+}
+
+export I = "${STAGING_INCDIR}"
+export L = "${STAGING_INCDIR}"
+
+do_compile () {
+	oe_runmake 'CC=${CC}' 'CFGL=${LDFLAGS} -L./lib -llsof' 'DEBUG=' 'INCL=${CFLAGS}'
+}
+
+do_install () {
+	install -d ${D}${sbindir} ${D}${mandir}/man8
+	install -m 0755 lsof ${D}${sbindir}/lsof
+	install -m 0644 lsof.8 ${D}${mandir}/man8/lsof.8
+}
diff --git a/poky/meta/recipes-extended/ltp/ltp/0001-configure-Fix-default-value-of-without-numa-switch-i.patch b/poky/meta/recipes-extended/ltp/ltp/0001-configure-Fix-default-value-of-without-numa-switch-i.patch
deleted file mode 100644
index da62687..0000000
--- a/poky/meta/recipes-extended/ltp/ltp/0001-configure-Fix-default-value-of-without-numa-switch-i.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 4ace68a6ba501907a0741dba5f5f155e06a74c35 Mon Sep 17 00:00:00 2001
-From: Petr Vorel <pvorel@suse.cz>
-Date: Wed, 7 Feb 2018 11:09:49 +0100
-Subject: [PATCH] configure: Fix default value of --without-numa switch in help
-
-The default value is no.
-
-Fixes: 39a85a1f1 ("configure: add knob to control numa support")
-
-Signed-off-by: Petr Vorel <pvorel@suse.cz>
-Upstream-Status: Accepted
----
- configure.ac | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/configure.ac b/configure.ac
-index b39a31d..d66ea00 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -86,7 +86,7 @@ fi
- # Numa
- AC_ARG_WITH([numa],
-   AC_HELP_STRING([--without-numa],
--    [without numa support (default=yes)]),
-+    [without numa support (default=no)]),
-   [with_numa=no],
-   [with_numa=yes]
- )
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-extended/ltp/ltp/0001-configure-add-knob-to-control-numa-support.patch b/poky/meta/recipes-extended/ltp/ltp/0001-configure-add-knob-to-control-numa-support.patch
deleted file mode 100644
index 8aaa287..0000000
--- a/poky/meta/recipes-extended/ltp/ltp/0001-configure-add-knob-to-control-numa-support.patch
+++ /dev/null
@@ -1,50 +0,0 @@
-From 39a85a1f1e6624f554215ba4b6843d3689a8415e Mon Sep 17 00:00:00 2001
-From: Anders Roxell <anders.roxell@linaro.org>
-Date: Mon, 5 Feb 2018 11:56:04 +0100
-Subject: [PATCH] configure: add knob to control numa support
-
-Allow to disable numa from the top level.
-
-Based on patch:
-http://cgit.openembedded.org/openembedded-core/commit/meta/recipes-extended/ltp?id=4c7873552e13dfdba96afca7562c398d2966ca71
-
-Reported-by: Roy Li <rongqing.li@windriver.com>
-Signed-off-by: Anders Roxell <anders.roxell@linaro.org>
-Signed-off-by: Petr Vorel <pvorel@suse.cz>
-Upstream-Status: Accepted
----
- configure.ac | 10 ++++++++++
- 1 file changed, 10 insertions(+)
-
-diff --git a/configure.ac b/configure.ac
-index 5c8d4ea..b39a31d 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -83,6 +83,14 @@ else
-     AC_SUBST([WITH_EXPECT],["no"])
- fi
- 
-+# Numa
-+AC_ARG_WITH([numa],
-+  AC_HELP_STRING([--without-numa],
-+    [without numa support (default=yes)]),
-+  [with_numa=no],
-+  [with_numa=yes]
-+)
-+
- # Perl
- AC_ARG_WITH([perl],
-   [AC_HELP_STRING([--with-perl],
-@@ -157,7 +165,9 @@ LTP_CHECK_SELINUX
- LTP_CHECK_SIGNAL
- LTP_CHECK_SYSCALL_EVENTFD
- LTP_CHECK_SYSCALL_MODIFY_LDT
-+if test "x$with_numa" = xyes; then
- LTP_CHECK_SYSCALL_NUMA
-+fi
- LTP_CHECK_SYSCALL_QUOTACTL
- LTP_CHECK_SYSCALL_SIGNALFD
- LTP_CHECK_SYSCALL_UNSHARE
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-extended/ltp/ltp/0001-mmap15-mips64-return-EINVAL.patch b/poky/meta/recipes-extended/ltp/ltp/0001-mmap15-mips64-return-EINVAL.patch
new file mode 100644
index 0000000..18eba27
--- /dev/null
+++ b/poky/meta/recipes-extended/ltp/ltp/0001-mmap15-mips64-return-EINVAL.patch
@@ -0,0 +1,41 @@
+From b909805b4fc1b72e0ce299afb4abc02720ee81da Mon Sep 17 00:00:00 2001
+From: Dengke Du <dengke.du@windriver.com>
+Date: Wed, 12 Sep 2018 14:24:35 +0800
+Subject: [PATCH] mmap15: mips64 return EINVAL
+
+In mips64 kernel, system check the addr that passed to mmap:
+
+    if (TASK_SIZE - len < addr)
+        return -EINVAL;
+
+Link: https://github.com/torvalds/linux/blob/master/arch/mips/mm/mmap.c#L71
+
+Upstream-Status: Submitted [https://github.com/linux-test-project/ltp/pull/394]
+
+Signed-off-by: Dengke Du <dengke.du@windriver.com>
+---
+ testcases/kernel/syscalls/mmap/mmap15.c | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/testcases/kernel/syscalls/mmap/mmap15.c b/testcases/kernel/syscalls/mmap/mmap15.c
+index eff27d6..a10b5c7 100644
+--- a/testcases/kernel/syscalls/mmap/mmap15.c
++++ b/testcases/kernel/syscalls/mmap/mmap15.c
+@@ -81,9 +81,14 @@ int main(int ac, char **av)
+ 		}
+ 
+ 		if (errno != ENOMEM) {
++#ifdef __mips__
++			tst_resm(TPASS | TERRNO, "mmap into high region "
++                                 "failed as expected");                        
++#else
+ 			tst_resm(TFAIL | TERRNO, "mmap into high region "
+ 				 "failed unexpectedly - expect "
+ 				 "errno=ENOMEM, got");
++#endif
+ 		} else {
+ 			tst_resm(TPASS | TERRNO, "mmap into high region "
+ 				 "failed as expected");
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-extended/ltp/ltp/0001-netns_helper.sh-use-ping-6-when-ping6-is-not-avaliab.patch b/poky/meta/recipes-extended/ltp/ltp/0001-netns_helper.sh-use-ping-6-when-ping6-is-not-avaliab.patch
new file mode 100644
index 0000000..32e7a0e
--- /dev/null
+++ b/poky/meta/recipes-extended/ltp/ltp/0001-netns_helper.sh-use-ping-6-when-ping6-is-not-avaliab.patch
@@ -0,0 +1,45 @@
+From 76d8343ad300f6507233abcdf97629290e35848a Mon Sep 17 00:00:00 2001
+From: Lei Yang <Lei.Yang@windriver.com>
+Date: Wed, 29 Aug 2018 11:51:24 +0800
+Subject: [PATCH] netns_helper.sh: use 'ping -6' when ping6 is not avaliable
+
+ping6 has been merged into ping since 2015 by using "ping -6"
+in some distributions (e.g. OpenEmbedded) they dropped ping6 completely
+this patch will let both "ping -6" and ping6 work.
+
+[pvorel: change was done in s20150815:
+ebad35f ("ping: merge `ping6` command into `ping`"),
+before that release switch '-6' didn't exist.
+Upstream leaves ping6 symlink to distributions.]
+
+Upstream-Status: Backport
+[https://github.com/linux-test-project/ltp/commit/76d8343ad300f6507233abcdf97629290e35848a]
+
+Signed-off-by: Lei Yang <Lei.Yang@windriver.com>
+Signed-off-by: Petr Vorel <pvorel@suse.cz>
+Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
+---
+ testcases/kernel/containers/netns/netns_helper.sh | 7 ++++++-
+ 1 file changed, 6 insertions(+), 1 deletion(-)
+
+diff --git a/testcases/kernel/containers/netns/netns_helper.sh b/testcases/kernel/containers/netns/netns_helper.sh
+index 6aea10b..a9d0459 100755
+--- a/testcases/kernel/containers/netns/netns_helper.sh
++++ b/testcases/kernel/containers/netns/netns_helper.sh
+@@ -168,7 +168,12 @@ netns_setup()
+ 	ipv6)
+ 		IFCONF_IN6_ARG="inet6 add"
+ 		IP0=$6; IP1=$7;
+-		tping="ping6"; NETMASK=64
++		if which ping6 >/dev/null 2>&1; then
++		    tping="ping6"
++		else
++		    tping="ping -6"
++		fi
++		NETMASK=64
+ 		;;
+ 	*)
+ 		tst_brkm TBROK "second argument must be an ip version (ipv4|ipv6)"
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-extended/ltp/ltp/0001-open_posix_testsuite-mmap24-2-Relax-condition-a-bit.patch b/poky/meta/recipes-extended/ltp/ltp/0001-open_posix_testsuite-mmap24-2-Relax-condition-a-bit.patch
new file mode 100644
index 0000000..4d771c0
--- /dev/null
+++ b/poky/meta/recipes-extended/ltp/ltp/0001-open_posix_testsuite-mmap24-2-Relax-condition-a-bit.patch
@@ -0,0 +1,68 @@
+From 85c972f730e8efe891a06ea3a2dfb5cbbdfbfbf4 Mon Sep 17 00:00:00 2001
+From: "Hongzhi.Song" <hongzhi.song@windriver.com>
+Date: Wed, 10 Oct 2018 22:07:05 -0400
+Subject: [PATCH] open_posix_testsuite/mmap24-2: Relax condition a bit
+
+Mips will return EINVAL instead of ENOMEM as expected
+if the range [addr + len) exceeds TASK_SIZE.
+
+Linux kernel code: arch/mips/mm/mmap.c
+if (flags & MAP_FIXED) {
+    /* Even MAP_FIXED mappings must reside within TASK_SIZE */
+    if (TASK_SIZE - len < addr)
+        return -EINVAL;
+
+Relax the condition and accept both ENOMEM and EINVAL
+as expected outcome.
+
+Upstream-Status: Submitted [https://lists.linux.it/pipermail/ltp/2018-October/009624.html]
+
+Signed-off-by: Hongzhi.Song <hongzhi.song@windriver.com>
+---
+ .../open_posix_testsuite/conformance/interfaces/mmap/24-2.c    | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/testcases/open_posix_testsuite/conformance/interfaces/mmap/24-2.c b/testcases/open_posix_testsuite/conformance/interfaces/mmap/24-2.c
+index de51d43..810e5c8 100644
+--- a/testcases/open_posix_testsuite/conformance/interfaces/mmap/24-2.c
++++ b/testcases/open_posix_testsuite/conformance/interfaces/mmap/24-2.c
+@@ -7,7 +7,7 @@
+  * source tree.
+  *
+  * The mmap() function shall fail if:
+- * [ENOMEM] MAP_FIXED was specified,
++ * [ENOMEM or EINVAL] MAP_FIXED was specified,
+  * and the range [addr,addr+len) exceeds that allowed
+  * for the address space of a process; or, if MAP_FIXED was not specified and
+  * there is insufficient room in the address space to effect the mapping.
+@@ -15,7 +15,7 @@
+  * Test Step:
+  * 1. Map a shared memory object, with size exceeding the value get from
+  *    rlim_cur of resource RLIMIT_AS, setting MAP_FIXED;
+- * 3. Should get ENOMEM.
++ * 3. Should get ENOMEM or EINVAL.
+  */
+ 
+ #define _XOPEN_SOURCE 600
+@@ -93,8 +93,8 @@ int main(void)
+ 	       (unsigned long)len);
+ 	pa = mmap(addr, len, PROT_READ | PROT_WRITE, MAP_FIXED | MAP_SHARED, fd,
+ 		  0);
+-	if (pa == MAP_FAILED && errno == ENOMEM) {
+-		printf("Got ENOMEM: %s\nTest PASSED\n", strerror(errno));
++	if (pa == MAP_FAILED && (errno == ENOMEM || errno == EINVAL)) {
++		printf("Got ENOMEM or EINVAL: %s\nTest PASSED\n", strerror(errno));
+ 		exit(PTS_PASS);
+ 	}
+ 
+@@ -103,6 +103,6 @@ int main(void)
+ 	else
+ 		munmap(pa, len);
+ 	close(fd);
+-	printf("Test Fail: Did not get ENOMEM as expected\n");
++	printf("Test Failed: Did not get ENOMEM or EINVAL as expected\n");
+ 	return PTS_FAIL;
+ }
+-- 
+2.8.1
+
diff --git a/poky/meta/recipes-extended/ltp/ltp/0001-sigwaitinfo01-recent-glibc-calls-syscall-directly.patch b/poky/meta/recipes-extended/ltp/ltp/0001-sigwaitinfo01-recent-glibc-calls-syscall-directly.patch
new file mode 100644
index 0000000..c412c89
--- /dev/null
+++ b/poky/meta/recipes-extended/ltp/ltp/0001-sigwaitinfo01-recent-glibc-calls-syscall-directly.patch
@@ -0,0 +1,75 @@
+From bb977ca0716ae98f10102c7122fe15bc0ddb5356 Mon Sep 17 00:00:00 2001
+From: "Hongzhi.Song" <hongzhi.song@windriver.com>
+Date: Thu, 20 Sep 2018 21:49:02 -0400
+Subject: [PATCH] sigwaitinfo01: recent glibc calls syscall directly
+
+glibc commit
+  8b0e795aaa44 ("Simplify Linux sig{timed}wait{info} implementations")
+changed sigwaitinfo to call sigtimedwait, which calls rt_sigtimedwait
+syscall directly.
+
+So, an invalid pointer no longer crashes child process and test
+reports failure. Fix it by accepting either crash or EFAULT.
+
+Signed-off-by: Jan Stancek <jstancek@redhat.com>
+
+Upstream-Status: Submitted [https://lists.linux.it/pipermail/ltp/2018-September/009338.html]
+
+Signed-off-by: Hongzhi.Song <hongzhi.song@windriver.com>
+---
+ .../kernel/syscalls/sigwaitinfo/sigwaitinfo01.c    | 30 +++++++++++++++++++---
+ 1 file changed, 26 insertions(+), 4 deletions(-)
+
+diff --git a/testcases/kernel/syscalls/sigwaitinfo/sigwaitinfo01.c b/testcases/kernel/syscalls/sigwaitinfo/sigwaitinfo01.c
+index 95a9436a4..8fa8ac34b 100644
+--- a/testcases/kernel/syscalls/sigwaitinfo/sigwaitinfo01.c
++++ b/testcases/kernel/syscalls/sigwaitinfo/sigwaitinfo01.c
+@@ -371,19 +371,41 @@ void test_bad_address2(swi_func sigwaitinfo, int signo)
+ 		tst_brkm(TBROK | TERRNO, NULL, "fork() failed");
+ 	case 0:
+ 		signal(SIGSEGV, SIG_DFL);
++
++       /*
++        * depending on glibc implementation we should
++        * either crash or get EFAULT
++        */
+ 		TEST(sigwaitinfo((void *)1, NULL, NULL));
+ 
+-		_exit(0);
++       if (TEST_RETURN == -1 && TEST_ERRNO == EFAULT)
++           _exit(0);
++
++       tst_resm(TINFO, "swi_func returned: %ld, errno: %d",
++           TEST_RETURN, TEST_ERRNO);
++       _exit(1);
++
+ 		break;
+ 	default:
+ 		break;
+ 	}
+ 
+ 	SUCCEED_OR_DIE(waitpid, "waitpid failed", pid, &status, 0);
+-	if (WIFSIGNALED(status) && WTERMSIG(status) == SIGSEGV)
++
++   if ((WIFSIGNALED(status) && WTERMSIG(status) == SIGSEGV)
++       || (WIFEXITED(status) && WEXITSTATUS(status) == 0)) {
+ 		tst_resm(TPASS, "Test passed");
+-	else
+-		tst_resm(TFAIL, "Unrecognised child exit code");
++       return;
++   }
++
++   if (WIFEXITED(status)) {
++       tst_resm(TFAIL, "Unrecognised child exit code: %d",
++           WEXITSTATUS(status));
++   }
++   if (WIFSIGNALED(status)) {
++       tst_resm(TFAIL, "Unrecognised child termsig: %d",
++           WTERMSIG(status));
++   }
+ }
+ 
+ void test_bad_address3(swi_func sigwaitinfo, int signo)
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-extended/ltp/ltp/0001-syscalls-fcntl-make-OFD-command-use-fcntl64-syscall-.patch b/poky/meta/recipes-extended/ltp/ltp/0001-syscalls-fcntl-make-OFD-command-use-fcntl64-syscall-.patch
new file mode 100644
index 0000000..2755596
--- /dev/null
+++ b/poky/meta/recipes-extended/ltp/ltp/0001-syscalls-fcntl-make-OFD-command-use-fcntl64-syscall-.patch
@@ -0,0 +1,184 @@
+From 8de03ea1200480b922d5ba05b69dc94db60496f5 Mon Sep 17 00:00:00 2001
+From: "Hongzhi.Song" <hongzhi.song@windriver.com>
+Date: Sat, 15 Sep 2018 22:39:32 -0400
+Subject: [PATCH] syscalls/fcntl: make OFD command use fcntl64() syscall on
+ 32-bit
+
+To cope with glibc commit:
+  06ab719d30b0 ("Fix Linux fcntl OFD locks for non-LFS architectures
+(BZ#20251)")
+
+WIP: Still need to test this with new glibc.
+     Test with old glibc look OK so far.
+
+Signed-off-by: Jan Stancek <jstancek@redhat.com>
+
+Upstream-Status: Backport
+    Backported from upstream maillist
+    https://lists.linux.it/pipermail/ltp/2018-September/009370.html
+
+Signed-off-by: Hongzhi Song <hongzhi.song@windriver.com>
+---
+ testcases/kernel/syscalls/fcntl/fcntl34.c      | 12 +++++++---
+ testcases/kernel/syscalls/fcntl/fcntl36.c      | 23 +++++++++++++-----
+ testcases/kernel/syscalls/fcntl/fcntl_common.h | 32 ++++++++++++++++++++++++++
+ 3 files changed, 58 insertions(+), 9 deletions(-)
+ create mode 100644 testcases/kernel/syscalls/fcntl/fcntl_common.h
+
+diff --git a/testcases/kernel/syscalls/fcntl/fcntl34.c b/testcases/kernel/syscalls/fcntl/fcntl34.c
+index aa29cf9..109f834 100644
+--- a/testcases/kernel/syscalls/fcntl/fcntl34.c
++++ b/testcases/kernel/syscalls/fcntl/fcntl34.c
+@@ -28,6 +28,7 @@
+ #include "lapi/fcntl.h"
+ #include "tst_safe_pthread.h"
+ #include "tst_test.h"
++#include "fcntl_common.h"
+ 
+ static int thread_cnt;
+ static const int max_thread_cnt = 32;
+@@ -68,7 +69,12 @@ void *thread_fn_01(void *arg)
+ 
+ 	memset(buf, (intptr_t)arg, write_size);
+ 
+-	struct flock64 lck = {
++    /* see explanation in fcntl_common.h */
++    #ifdef USE_STRUCT_FLOCK
++        struct flock lck = {
++    #else
++        struct flock64 lck = {
++    #endif
+ 		.l_whence = SEEK_SET,
+ 		.l_start  = 0,
+ 		.l_len    = 1,
+@@ -76,13 +82,13 @@ void *thread_fn_01(void *arg)
+ 
+ 	for (i = 0; i < writes_num; ++i) {
+ 		lck.l_type = F_WRLCK;
+-		SAFE_FCNTL(fd, F_OFD_SETLKW, &lck);
++        my_fcntl(fd, F_OFD_SETLKW, &lck);
+ 
+ 		SAFE_LSEEK(fd, 0, SEEK_END);
+ 		SAFE_WRITE(1, fd, buf, write_size);
+ 
+ 		lck.l_type = F_UNLCK;
+-		SAFE_FCNTL(fd, F_OFD_SETLKW, &lck);
++        my_fcntl(fd, F_OFD_SETLKW, &lck);
+ 
+ 		sched_yield();
+ 	}
+diff --git a/testcases/kernel/syscalls/fcntl/fcntl36.c b/testcases/kernel/syscalls/fcntl/fcntl36.c
+index 3246d13..f263b6b 100644
+--- a/testcases/kernel/syscalls/fcntl/fcntl36.c
++++ b/testcases/kernel/syscalls/fcntl/fcntl36.c
+@@ -57,6 +57,7 @@
+ #include "lapi/fcntl.h"
+ #include "tst_safe_pthread.h"
+ #include "tst_test.h"
++#include "fcntl_common.h"
+ 
+ static int thread_cnt;
+ static int fail_flag = 0;
+@@ -87,7 +88,12 @@ static void *fn_ofd_w(void *arg)
+ 	int fd = SAFE_OPEN(fname, O_RDWR);
+ 	long wt = pa->cnt;
+ 
+-	struct flock64 lck = {
++    /* see explanation in fcntl_common.h */
++    #ifdef USE_STRUCT_FLOCK
++        struct flock lck = {
++    #else
++        struct flock64 lck = {
++    #endif
+ 		.l_whence = SEEK_SET,
+ 		.l_start  = pa->offset,
+ 		.l_len    = pa->length,
+@@ -99,13 +105,13 @@ static void *fn_ofd_w(void *arg)
+ 		memset(buf, wt, pa->length);
+ 
+ 		lck.l_type = F_WRLCK;
+-		SAFE_FCNTL(fd, F_OFD_SETLKW, &lck);
++        my_fcntl(fd, F_OFD_SETLKW, &lck);
+ 
+ 		SAFE_LSEEK(fd, pa->offset, SEEK_SET);
+ 		SAFE_WRITE(1, fd, buf, pa->length);
+ 
+ 		lck.l_type = F_UNLCK;
+-		SAFE_FCNTL(fd, F_OFD_SETLKW, &lck);
++        my_fcntl(fd, F_OFD_SETLKW, &lck);
+ 
+ 		wt++;
+ 		if (wt >= 255)
+@@ -166,7 +172,12 @@ static void *fn_ofd_r(void *arg)
+ 	int i;
+ 	int fd = SAFE_OPEN(fname, O_RDWR);
+ 
+-	struct flock64 lck = {
++    /* see explanation in fcntl_common.h */
++    #ifdef USE_STRUCT_FLOCK
++        struct flock lck = {
++    #else
++        struct flock64 lck = {
++    #endif
+ 		.l_whence = SEEK_SET,
+ 		.l_start  = pa->offset,
+ 		.l_len    = pa->length,
+@@ -178,7 +189,7 @@ static void *fn_ofd_r(void *arg)
+ 		memset(buf, 0, pa->length);
+ 
+ 		lck.l_type = F_RDLCK;
+-		SAFE_FCNTL(fd, F_OFD_SETLKW, &lck);
++        my_fcntl(fd, F_OFD_SETLKW, &lck);
+ 
+ 		/* rlock acquired */
+ 		SAFE_LSEEK(fd, pa->offset, SEEK_SET);
+@@ -209,7 +220,7 @@ static void *fn_ofd_r(void *arg)
+ 		}
+ 
+ 		lck.l_type = F_UNLCK;
+-		SAFE_FCNTL(fd, F_OFD_SETLK, &lck);
++        my_fcntl(fd, F_OFD_SETLK, &lck);
+ 
+ 		sched_yield();
+ 	}
+diff --git a/testcases/kernel/syscalls/fcntl/fcntl_common.h b/testcases/kernel/syscalls/fcntl/fcntl_common.h
+new file mode 100644
+index 0000000..3fe399b
+--- /dev/null
++++ b/testcases/kernel/syscalls/fcntl/fcntl_common.h
+@@ -0,0 +1,32 @@
++#include "lapi/syscalls.h"
++
++/*
++ * glibc commit:
++ *   06ab719d30b0 ("Fix Linux fcntl OFD locks for non-LFS architectures (BZ#20251)")
++ * changed behavior of arg parameter for OFD commands. It is no
++ * longer passing arg directly to syscall, but expects it to be
++ * 'struct flock'.
++ *
++ * On 64-bit or _FILE_OFFSET_BITS == 64 we can use fcntl() and
++ * struct flock with any glibc version. struct flock and flock64
++ * should be identical.
++ *
++ * On 32-bit, older glibc would pass arg directly, recent one treats
++ * it as 'struct flock' and converts it to 'struct flock64'.
++ * So, for 32-bit we use fcntl64 syscall directly with struct flock64.
++ */
++#if __WORDSIZE == 64 || _FILE_OFFSET_BITS == 64
++#define USE_STRUCT_FLOCK
++static int my_fcntl(int fd, int cmd, void *lck)
++{
++        return SAFE_FCNTL(fd, cmd, lck);
++}
++#else
++static int my_fcntl(int fd, int cmd, void *lck)
++{
++        int ret = tst_syscall(__NR_fcntl64, fd, cmd, lck);
++        if (ret == -1)
++                tst_brk(TBROK|TERRNO, "fcntl64");
++        return ret;
++}
++#endif
+-- 
+2.8.1
+
diff --git a/poky/meta/recipes-extended/ltp/ltp/0003-Add-knob-to-control-tirpc-support.patch b/poky/meta/recipes-extended/ltp/ltp/0003-Add-knob-to-control-tirpc-support.patch
deleted file mode 100644
index 5cf1e05..0000000
--- a/poky/meta/recipes-extended/ltp/ltp/0003-Add-knob-to-control-tirpc-support.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-From b193011da301b3d944e8fddcf4817513c31c5b88 Mon Sep 17 00:00:00 2001
-From: Fathi Boudra <fathi.boudra@linaro.org>
-Date: Thu, 7 Jan 2016 17:36:19 +0000
-Subject: [PATCH 03/32] Add knob to control tirpc support
-
-allow to disable tirpc. Helps to disable it at top level for eg. musl it
-does not yet work.
-
-Signed-off-by: Fathi Boudra <fathi.boudra@linaro.org>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Upstream-Status: Pending
----
- configure.ac | 9 +++++++++
- 1 file changed, 9 insertions(+)
-
-diff --git a/configure.ac b/configure.ac
-index cc50397..9e2936b 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -98,6 +98,13 @@ if test "x$with_python" = xyes; then
- else
-     AC_SUBST([WITH_PYTHON],["no"])
- fi
-+
-+# TI RPC
-+AC_ARG_WITH([tirpc],
-+  AC_HELP_STRING([--without-tirpc],
-+    [without libtirpc support]),
-+  [],[with_tirpc=yes],
-+)
- # END tools knobs
- 
- # Testsuites knobs
-@@ -169,7 +176,9 @@ LTP_CHECK_RENAMEAT2
- LTP_CHECK_FALLOCATE
- LTP_CHECK_SYSCALL_FCNTL
- LTP_CHECK_SYSCALL_PERF_EVENT_OPEN
-+if test "x$with_tirpc" = xyes; then
- LTP_CHECK_TIRPC
-+fi
- LTP_CHECK_TEE
- LTP_CHECK_SPLICE
- LTP_CHECK_VMSPLICE
--- 
-2.7.0
-
diff --git a/poky/meta/recipes-extended/ltp/ltp/0004-build-Add-option-to-select-libc-implementation.patch b/poky/meta/recipes-extended/ltp/ltp/0004-build-Add-option-to-select-libc-implementation.patch
index 84ab37e..2df3855 100644
--- a/poky/meta/recipes-extended/ltp/ltp/0004-build-Add-option-to-select-libc-implementation.patch
+++ b/poky/meta/recipes-extended/ltp/ltp/0004-build-Add-option-to-select-libc-implementation.patch
@@ -22,10 +22,10 @@
  testcases/realtime/stress/pi-tests/Makefile | 5 +++++
  8 files changed, 35 insertions(+), 2 deletions(-)
 
-Index: git/Makefile
-===================================================================
---- git.orig/Makefile
-+++ git/Makefile
+diff --git a/Makefile b/Makefile
+index 297f8e7..906b280 100644
+--- a/Makefile
++++ b/Makefile
 @@ -49,6 +49,11 @@ SKIP_IDCHECK		?= 0
  UCLINUX			?= 0
  export UCLINUX
@@ -38,10 +38,10 @@
  # CLEAN_TARGETS:	Targets which exist solely in clean.
  # COMMON_TARGETS:	Targets which exist in all, clean, and install.
  # INSTALL_TARGETS:	Targets which exist in clean and install (contains
-Index: git/testcases/kernel/Makefile
-===================================================================
---- git.orig/testcases/kernel/Makefile
-+++ git/testcases/kernel/Makefile
+diff --git a/testcases/kernel/Makefile b/testcases/kernel/Makefile
+index 50a12fa..4f1987f 100644
+--- a/testcases/kernel/Makefile
++++ b/testcases/kernel/Makefile
 @@ -48,13 +48,16 @@ SUBDIRS			+= connectors \
  			   logging \
  			   mem \
@@ -60,10 +60,10 @@
  ifeq ($(WITH_POWER_MANAGEMENT_TESTSUITE),yes)
  SUBDIRS			+= power_management
  endif
-Index: git/testcases/kernel/sched/Makefile
-===================================================================
---- git.orig/testcases/kernel/sched/Makefile
-+++ git/testcases/kernel/sched/Makefile
+diff --git a/testcases/kernel/sched/Makefile b/testcases/kernel/sched/Makefile
+index 6245ed0..aa4eb7f 100644
+--- a/testcases/kernel/sched/Makefile
++++ b/testcases/kernel/sched/Makefile
 @@ -23,5 +23,7 @@
  top_srcdir		?= ../../..
  
@@ -73,10 +73,10 @@
 +	FILTER_OUT_DIRS += process_stress
 +endif
  include $(top_srcdir)/include/mk/generic_trunk_target.mk
-Index: git/testcases/kernel/syscalls/Makefile
-===================================================================
---- git.orig/testcases/kernel/syscalls/Makefile
-+++ git/testcases/kernel/syscalls/Makefile
+diff --git a/testcases/kernel/syscalls/Makefile b/testcases/kernel/syscalls/Makefile
+index 8acb395..b749126 100644
+--- a/testcases/kernel/syscalls/Makefile
++++ b/testcases/kernel/syscalls/Makefile
 @@ -28,6 +28,11 @@ ifeq ($(UCLINUX),1)
  FILTER_OUT_DIRS	+= capget capset chmod chown clone fork getcontext llseek \
  		   mincore mprotect nftw profil remap_file_pages sbrk
@@ -89,11 +89,11 @@
  
  ifeq ($(UCLIBC),1)
  FILTER_OUT_DIRS	+= profil
-Index: git/testcases/network/nfsv4/acl/Makefile
-===================================================================
---- git.orig/testcases/network/nfsv4/acl/Makefile
-+++ git/testcases/network/nfsv4/acl/Makefile
-@@ -26,4 +26,8 @@ include $(top_srcdir)/include/mk/env_pre
+diff --git a/testcases/network/nfsv4/acl/Makefile b/testcases/network/nfsv4/acl/Makefile
+index 8bc78c2..c36cf50 100644
+--- a/testcases/network/nfsv4/acl/Makefile
++++ b/testcases/network/nfsv4/acl/Makefile
+@@ -26,4 +26,8 @@ include $(top_srcdir)/include/mk/env_pre.mk
  
  LDLIBS			+= $(ACL_LIBS)
  
@@ -102,10 +102,10 @@
 +endif
 +
  include $(top_srcdir)/include/mk/generic_leaf_target.mk
-Index: git/testcases/network/rpc/basic_tests/Makefile
-===================================================================
---- git.orig/testcases/network/rpc/basic_tests/Makefile
-+++ git/testcases/network/rpc/basic_tests/Makefile
+diff --git a/testcases/network/rpc/basic_tests/Makefile b/testcases/network/rpc/basic_tests/Makefile
+index 3160813..9bdf5d0 100644
+--- a/testcases/network/rpc/basic_tests/Makefile
++++ b/testcases/network/rpc/basic_tests/Makefile
 @@ -23,4 +23,9 @@
  top_srcdir		?= ../../../..
  
@@ -116,11 +116,11 @@
 +endif
 +
  include $(top_srcdir)/include/mk/generic_trunk_target.mk
-Index: git/testcases/realtime/func/pi-tests/Makefile
-===================================================================
---- git.orig/testcases/realtime/func/pi-tests/Makefile
-+++ git/testcases/realtime/func/pi-tests/Makefile
-@@ -27,5 +27,9 @@ include $(top_srcdir)/include/mk/env_pre
+diff --git a/testcases/realtime/func/pi-tests/Makefile b/testcases/realtime/func/pi-tests/Makefile
+index 7a7a57a..5808866 100644
+--- a/testcases/realtime/func/pi-tests/Makefile
++++ b/testcases/realtime/func/pi-tests/Makefile
+@@ -27,5 +27,9 @@ include $(top_srcdir)/include/mk/env_pre.mk
  include $(abs_srcdir)/../../config.mk
  
  MAKE_TARGETS		:= testpi-0 testpi-1 testpi-2 testpi-4 testpi-5 testpi-6 testpi-7 sbrk_mutex
@@ -130,10 +130,10 @@
 +
  
  include $(top_srcdir)/include/mk/generic_leaf_target.mk
-Index: git/testcases/realtime/stress/pi-tests/Makefile
-===================================================================
---- git.orig/testcases/realtime/stress/pi-tests/Makefile
-+++ git/testcases/realtime/stress/pi-tests/Makefile
+diff --git a/testcases/realtime/stress/pi-tests/Makefile b/testcases/realtime/stress/pi-tests/Makefile
+index 5edc3b4..aa5987a 100644
+--- a/testcases/realtime/stress/pi-tests/Makefile
++++ b/testcases/realtime/stress/pi-tests/Makefile
 @@ -24,4 +24,9 @@ top_srcdir		?= ../../../..
  
  include $(top_srcdir)/include/mk/env_pre.mk
@@ -144,3 +144,6 @@
 +endif
 +
  include $(top_srcdir)/include/mk/generic_leaf_target.mk
+-- 
+2.7.0
+
diff --git a/poky/meta/recipes-extended/ltp/ltp/0008-Check-if-__GLIBC_PREREQ-is-defined-before-using-it.patch b/poky/meta/recipes-extended/ltp/ltp/0008-Check-if-__GLIBC_PREREQ-is-defined-before-using-it.patch
index e325ce4..428ac30 100644
--- a/poky/meta/recipes-extended/ltp/ltp/0008-Check-if-__GLIBC_PREREQ-is-defined-before-using-it.patch
+++ b/poky/meta/recipes-extended/ltp/ltp/0008-Check-if-__GLIBC_PREREQ-is-defined-before-using-it.patch
@@ -11,9 +11,9 @@
 Upstream-Status: Pending
 ---
  testcases/kernel/syscalls/accept4/accept4_01.c     |  9 ++++-
- testcases/kernel/syscalls/getcpu/getcpu01.c        | 40 +++++++++++++++++++++-
- .../sched_getaffinity/sched_getaffinity01.c        | 26 ++++++++++++++
- 3 files changed, 73 insertions(+), 2 deletions(-)
+ testcases/kernel/syscalls/getcpu/getcpu01.c        | 39 +++++++++++++++++++++-
+ .../sched_getaffinity/sched_getaffinity01.c        | 26 +++++++++++++++
+ 3 files changed, 72 insertions(+), 2 deletions(-)
 
 diff --git a/testcases/kernel/syscalls/accept4/accept4_01.c b/testcases/kernel/syscalls/accept4/accept4_01.c
 index 6072bfa..2b090cb 100644
@@ -102,7 +102,7 @@
  	*cpu_id = sched_getcpu();
  #endif
  	return 0;
-@@ -191,15 +204,20 @@ unsigned int set_cpu_affinity(void)
+@@ -191,15 +203,20 @@ unsigned int set_cpu_affinity(void)
  	cpu_set_t *set;
  	size_t size;
  	int nrcpus = 1024;
@@ -123,7 +123,7 @@
  #if __GLIBC_PREREQ(2, 7)
  	size = CPU_ALLOC_SIZE(nrcpus);
  	CPU_ZERO_S(size, set);
-@@ -207,8 +225,13 @@ realloc:
+@@ -207,8 +224,13 @@ realloc:
  	size = sizeof(cpu_set_t);
  	CPU_ZERO(set);
  #endif
@@ -137,7 +137,7 @@
  #if __GLIBC_PREREQ(2, 7)
  		if (errno == EINVAL && nrcpus < (1024 << 8)) {
  			nrcpus = nrcpus << 2;
-@@ -220,10 +243,17 @@ realloc:
+@@ -220,10 +242,17 @@ realloc:
  				 "NR_CPUS of the kernel is more than 1024, so we'd better use a newer glibc(>= 2.7)");
  		else
  #endif
@@ -155,7 +155,7 @@
  #if __GLIBC_PREREQ(2, 7)
  	CPU_ZERO_S(size, set);
  	CPU_SET_S(cpu_max, size, set);
-@@ -231,6 +261,10 @@ realloc:
+@@ -231,6 +260,10 @@ realloc:
  	CPU_ZERO(set);
  	CPU_SET(cpu_max, set);
  #endif
@@ -166,7 +166,7 @@
  	if (sched_setaffinity(0, size, set) < 0) {
  		CPU_FREE(set);
  		tst_brkm(TFAIL, NULL, "sched_setaffinity:errno:%d", errno);
-@@ -247,11 +281,15 @@ unsigned int max_cpuid(size_t size, cpu_set_t * set)
+@@ -247,11 +280,15 @@ unsigned int max_cpuid(size_t size, cpu_set_t * set)
  {
  	unsigned int index, max = 0;
  	for (index = 0; index < size * BITS_PER_BYTE; index++)
@@ -186,7 +186,7 @@
 index 9d6a81a..4ed13b2 100644
 --- a/testcases/kernel/syscalls/sched_getaffinity/sched_getaffinity01.c
 +++ b/testcases/kernel/syscalls/sched_getaffinity/sched_getaffinity01.c
-@@ -66,9 +66,11 @@ do { \
+@@ -67,9 +67,11 @@ do { \
  	tst_resm((TEST_RETURN == -1 ? TPASS : TFAIL) | TTERRNO, #t); \
  } while (0)
  
@@ -198,7 +198,7 @@
  
  int main(int ac, char **av)
  {
-@@ -95,14 +97,19 @@ static void do_test(void)
+@@ -96,14 +98,19 @@ static void do_test(void)
  	pid_t unused_pid;
  	unsigned len;
  
@@ -218,7 +218,7 @@
  #if __GLIBC_PREREQ(2, 7)
  	len = CPU_ALLOC_SIZE(nrcpus);
  	CPU_ZERO_S(len, mask);
-@@ -110,10 +117,15 @@ realloc:
+@@ -111,10 +118,15 @@ realloc:
  	len = sizeof(cpu_set_t);
  	CPU_ZERO(mask);
  #endif
@@ -234,7 +234,7 @@
  #if __GLIBC_PREREQ(2, 7)
  		if (errno == EINVAL && nrcpus < (1024 << 8)) {
  			nrcpus = nrcpus << 2;
-@@ -125,17 +137,27 @@ realloc:
+@@ -126,17 +138,27 @@ realloc:
  				 "newer glibc(>= 2.7)");
  		else
  #endif
@@ -262,7 +262,7 @@
  			if (TEST_RETURN != -1)
  				tst_resm(TPASS, "sched_getaffinity() succeed, "
  					 "this process %d is running "
-@@ -143,11 +165,15 @@ realloc:
+@@ -144,11 +166,15 @@ realloc:
  		}
  	}
  
diff --git a/poky/meta/recipes-extended/ltp/ltp/0010-replace-__BEGIN_DECLS-and-__END_DECLS.patch b/poky/meta/recipes-extended/ltp/ltp/0010-replace-__BEGIN_DECLS-and-__END_DECLS.patch
deleted file mode 100644
index b9fce88..0000000
--- a/poky/meta/recipes-extended/ltp/ltp/0010-replace-__BEGIN_DECLS-and-__END_DECLS.patch
+++ /dev/null
@@ -1,75 +0,0 @@
-From 0130f4146ced320aadb01b22e36b13d269a8ebba Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 7 Jan 2016 19:48:14 +0000
-Subject: [PATCH 10/32] replace __BEGIN_DECLS and __END_DECLS
-
-They are not portable across libc implementations
-therefore replace them with expanded macros
-
-Include <asm-generic/types.h> to get __s32 definitions
-its not a generally available typedef
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- testcases/kernel/syscalls/epoll2/include/epoll.h | 8 ++++++--
- utils/sctp/include/netinet/sctp.h                | 9 +++++++--
- 2 files changed, 13 insertions(+), 4 deletions(-)
-
-diff --git a/testcases/kernel/syscalls/epoll2/include/epoll.h b/testcases/kernel/syscalls/epoll2/include/epoll.h
-index be599c7..8cc5e7e 100644
---- a/testcases/kernel/syscalls/epoll2/include/epoll.h
-+++ b/testcases/kernel/syscalls/epoll2/include/epoll.h
-@@ -85,7 +85,9 @@ struct epoll_event
- } EPOLL_PACKED;
- 
- 
--__BEGIN_DECLS
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
- 
- /* Creates an epoll instance.  Returns an fd for the new instance.
-    The "size" parameter is a hint specifying the number of file
-@@ -114,6 +116,8 @@ extern int epoll_ctl (int __epfd, int __op, int __fd,
- extern int epoll_wait (int __epfd, struct epoll_event *__events,
- 		       int __maxevents, int __timeout) __THROW;
- 
--__END_DECLS
-+#ifdef __cplusplus
-+}
-+#endif
- 
- #endif /* sys/epoll.h */
-diff --git a/utils/sctp/include/netinet/sctp.h b/utils/sctp/include/netinet/sctp.h
-index 51f5bfb..c61aef3 100644
---- a/utils/sctp/include/netinet/sctp.h
-+++ b/utils/sctp/include/netinet/sctp.h
-@@ -35,9 +35,12 @@
- 
- #include <stdint.h>
- #include <linux/types.h>
-+#include <asm-generic/types.h>
- #include <sys/socket.h>
- 
--__BEGIN_DECLS
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
- 
- typedef __s32 sctp_assoc_t;
- 
-@@ -862,6 +865,8 @@ int sctp_recvmsg(int s, void *msg, size_t len, struct sockaddr *from,
- /* Return the address length for an address family. */
- int sctp_getaddrlen(sa_family_t family);
- 
--__END_DECLS
-+#ifdef __cplusplus
-+}
-+#endif
- 
- #endif /* __linux_sctp_h__ */
--- 
-2.7.0
-
diff --git a/poky/meta/recipes-extended/ltp/ltp/0021-Define-_GNU_SOURCE-for-MREMAP_MAYMOVE-definition.patch b/poky/meta/recipes-extended/ltp/ltp/0021-Define-_GNU_SOURCE-for-MREMAP_MAYMOVE-definition.patch
index 462976d..6c5f360 100644
--- a/poky/meta/recipes-extended/ltp/ltp/0021-Define-_GNU_SOURCE-for-MREMAP_MAYMOVE-definition.patch
+++ b/poky/meta/recipes-extended/ltp/ltp/0021-Define-_GNU_SOURCE-for-MREMAP_MAYMOVE-definition.patch
@@ -18,10 +18,10 @@
  testcases/kernel/syscalls/mremap/mremap03.c | 2 ++
  3 files changed, 7 insertions(+), 1 deletion(-)
 
-Index: git/testcases/kernel/syscalls/mremap/mremap01.c
-===================================================================
---- git.orig/testcases/kernel/syscalls/mremap/mremap01.c
-+++ git/testcases/kernel/syscalls/mremap/mremap01.c
+diff --git a/testcases/kernel/syscalls/mremap/mremap01.c b/testcases/kernel/syscalls/mremap/mremap01.c
+index d63d1e4..24ca174 100644
+--- a/testcases/kernel/syscalls/mremap/mremap01.c
++++ b/testcases/kernel/syscalls/mremap/mremap01.c
 @@ -76,10 +76,12 @@
   */
  #include <unistd.h>
@@ -36,10 +36,10 @@
  
  #include "test.h"
  #include "safe_macros.h"
-Index: git/testcases/kernel/syscalls/mremap/mremap02.c
-===================================================================
---- git.orig/testcases/kernel/syscalls/mremap/mremap02.c
-+++ git/testcases/kernel/syscalls/mremap/mremap02.c
+diff --git a/testcases/kernel/syscalls/mremap/mremap02.c b/testcases/kernel/syscalls/mremap/mremap02.c
+index 5a51b9a..a530a6b 100644
+--- a/testcases/kernel/syscalls/mremap/mremap02.c
++++ b/testcases/kernel/syscalls/mremap/mremap02.c
 @@ -75,9 +75,11 @@
  #include <errno.h>
  #include <unistd.h>
@@ -52,10 +52,10 @@
  
  #include "test.h"
  
-Index: git/testcases/kernel/syscalls/mremap/mremap03.c
-===================================================================
---- git.orig/testcases/kernel/syscalls/mremap/mremap03.c
-+++ git/testcases/kernel/syscalls/mremap/mremap03.c
+diff --git a/testcases/kernel/syscalls/mremap/mremap03.c b/testcases/kernel/syscalls/mremap/mremap03.c
+index 12e3829..9b39f8b 100644
+--- a/testcases/kernel/syscalls/mremap/mremap03.c
++++ b/testcases/kernel/syscalls/mremap/mremap03.c
 @@ -76,9 +76,11 @@
  #include <errno.h>
  #include <unistd.h>
@@ -68,3 +68,6 @@
  
  #include "test.h"
  
+-- 
+2.7.0
+
diff --git a/poky/meta/recipes-extended/ltp/ltp/0028-rt_sigaction.h-Use-sighandler_t-instead-of-__sighand.patch b/poky/meta/recipes-extended/ltp/ltp/0028-rt_sigaction.h-Use-sighandler_t-instead-of-__sighand.patch
index c730d46..40ee894 100644
--- a/poky/meta/recipes-extended/ltp/ltp/0028-rt_sigaction.h-Use-sighandler_t-instead-of-__sighand.patch
+++ b/poky/meta/recipes-extended/ltp/ltp/0028-rt_sigaction.h-Use-sighandler_t-instead-of-__sighand.patch
@@ -11,14 +11,14 @@
 
 Upstream-Status: Pending
 ---
- include/lapi/rt_sigaction.h                      | 2 +-
+ include/lapi/rt_sigaction.h                      | 4 ++--
  testcases/kernel/syscalls/rt_sigsuspend/Makefile | 3 +++
- 2 files changed, 4 insertions(+), 1 deletion(-)
+ 2 files changed, 5 insertions(+), 2 deletions(-)
 
-Index: git/include/lapi/rt_sigaction.h
-===================================================================
---- git.orig/include/lapi/rt_sigaction.h
-+++ git/include/lapi/rt_sigaction.h
+diff --git a/include/lapi/rt_sigaction.h b/include/lapi/rt_sigaction.h
+index 18236db..15facda 100644
+--- a/include/lapi/rt_sigaction.h
++++ b/include/lapi/rt_sigaction.h
 @@ -36,12 +36,12 @@
  #if defined(__mips__)
  struct kernel_sigaction {
@@ -34,10 +34,10 @@
  	unsigned long sa_flags;
  	void (*sa_restorer) (void);
  	sigset_t sa_mask;
-Index: git/testcases/kernel/syscalls/rt_sigsuspend/Makefile
-===================================================================
---- git.orig/testcases/kernel/syscalls/rt_sigsuspend/Makefile
-+++ git/testcases/kernel/syscalls/rt_sigsuspend/Makefile
+diff --git a/testcases/kernel/syscalls/rt_sigsuspend/Makefile b/testcases/kernel/syscalls/rt_sigsuspend/Makefile
+index 37bc3a9..2ca7f7c 100644
+--- a/testcases/kernel/syscalls/rt_sigsuspend/Makefile
++++ b/testcases/kernel/syscalls/rt_sigsuspend/Makefile
 @@ -19,4 +19,7 @@
  top_srcdir		?= ../../../..
  
diff --git a/poky/meta/recipes-extended/ltp/ltp/0036-testcases-network-nfsv4-acl-acl1.c-Security-fix-on-s.patch b/poky/meta/recipes-extended/ltp/ltp/0036-testcases-network-nfsv4-acl-acl1.c-Security-fix-on-s.patch
index 04532be..e826d48 100644
--- a/poky/meta/recipes-extended/ltp/ltp/0036-testcases-network-nfsv4-acl-acl1.c-Security-fix-on-s.patch
+++ b/poky/meta/recipes-extended/ltp/ltp/0036-testcases-network-nfsv4-acl-acl1.c-Security-fix-on-s.patch
@@ -27,7 +27,7 @@
 index b8b67b4..7c7c506 100644
 --- a/testcases/network/nfsv4/acl/acl1.c
 +++ b/testcases/network/nfsv4/acl/acl1.c
-@@ -314,7 +314,7 @@ void test_acl_default(char *dir, acl_t acl)
+@@ -303,7 +303,7 @@ void test_acl_default(char *dir, acl_t acl)
  	char *cmd = malloc(256);
  
  	strcpy(cmd, "chmod 7777 ");
diff --git a/poky/meta/recipes-extended/ltp/ltp/0040-read_all-Define-FNM_EXTMATCH-if-not-already-like-und.patch b/poky/meta/recipes-extended/ltp/ltp/0040-read_all-Define-FNM_EXTMATCH-if-not-already-like-und.patch
new file mode 100644
index 0000000..0245a89
--- /dev/null
+++ b/poky/meta/recipes-extended/ltp/ltp/0040-read_all-Define-FNM_EXTMATCH-if-not-already-like-und.patch
@@ -0,0 +1,44 @@
+From 23518508de307790231d16af307291f1b45e903a Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Daniel=20D=C3=ADaz?= <daniel.diaz@linaro.org>
+Date: Tue, 5 Jun 2018 15:36:30 -0500
+Subject: [PATCH] read_all: Define FNM_EXTMATCH if not already (like under
+ musl).
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+With musl, FNM_EXTMATCH is not defined:
+| read_all.c: In function 'read_test':
+| read_all.c:201:41: error: 'FNM_EXTMATCH' undeclared (first use in this function); did you mean 'FNM_NOMATCH'?
+|   if (exclude && !fnmatch(exclude, path, FNM_EXTMATCH)) {
+|                                          ^~~~~~~~~~~~
+|                                          FNM_NOMATCH
+| read_all.c:201:41: note: each undeclared identifier is reported only once for each function it appears in
+| <builtin>: recipe for target 'read_all' failed
+| make[4]: *** [read_all] Error 1
+
+Signed-off-by: Daniel Díaz <daniel.diaz@linaro.org>
+
+Upstream-Status: Pending
+---
+ testcases/kernel/fs/read_all/read_all.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/testcases/kernel/fs/read_all/read_all.c b/testcases/kernel/fs/read_all/read_all.c
+index a8e1611..e9ff47a 100644
+--- a/testcases/kernel/fs/read_all/read_all.c
++++ b/testcases/kernel/fs/read_all/read_all.c
+@@ -59,6 +59,10 @@
+ #define MAX_PATH 4096
+ #define MAX_DISPLAY 40
+ 
++#if !defined(FNM_EXTMATCH)
++#define FNM_EXTMATCH 0
++#endif
++
+ struct queue {
+ 	sem_t sem;
+ 	int front;
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-extended/ltp/ltp/0040-safe_macros-make-is_fuse-return-zero-if-fs_type-is-N.patch b/poky/meta/recipes-extended/ltp/ltp/0040-safe_macros-make-is_fuse-return-zero-if-fs_type-is-N.patch
deleted file mode 100644
index 5096a85..0000000
--- a/poky/meta/recipes-extended/ltp/ltp/0040-safe_macros-make-is_fuse-return-zero-if-fs_type-is-N.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From 67af7dbe8bdf29f9ed980d8d29feeae32a0a7a1d Mon Sep 17 00:00:00 2001
-From: Li Wang <liwang@redhat.com>
-Date: Tue, 23 Jan 2018 17:46:35 +0800
-Subject: [PATCH] safe_macros: make is_fuse() return zero if fs_type is NULL
-
-This commmit 28507e514c(safe_mount: Do not try mount() syscall for FUSE fs)
-involves FUSE fs check in safe_mount(), but we'd better guarantee the "fs_type"
-is legal to check in is_fuse() function otherwise system will kill the program.
-
-  cmdline="fanotify06"
-  contacts=""
-  analysis=exit
-  <<<test_output>>>
-  tst_test.c:980: INFO: Timeout per run is 0h 10m 00s
-  tst_test.c:1025: BROK: Test killed by SIGSEGV!
-
-Signed-off-by: Li Wang <liwang@redhat.com>
-Acked-by: Jan Stancek <jstancek@redhat.com>
-Upstream-Status: Accepted [https://github.com/linux-test-project/ltp/commit/67af7dbe8bdf29f9ed980d8d29feeae32a0a7a1d]
----
- lib/safe_macros.c | 3 +++
- 1 file changed, 3 insertions(+)
-
-diff --git a/lib/safe_macros.c b/lib/safe_macros.c
-index c48e436dc..abdeca013 100644
---- a/lib/safe_macros.c
-+++ b/lib/safe_macros.c
-@@ -708,6 +708,9 @@ static int is_fuse(const char *fs_type)
- {
- 	unsigned int i;
- 
-+	if (!fs_type)
-+		return 0;
-+
- 	for (i = 0; i < ARRAY_SIZE(fuse_fs_types); i++) {
- 		if (!strcmp(fuse_fs_types[i], fs_type))
- 			return 1;
--- 
-2.11.0
-
diff --git a/poky/meta/recipes-extended/ltp/ltp/0041-cve-2017-5669-shmat-for-0-or-PAGESIZE-with-RND-flag-.patch b/poky/meta/recipes-extended/ltp/ltp/0041-cve-2017-5669-shmat-for-0-or-PAGESIZE-with-RND-flag-.patch
new file mode 100644
index 0000000..0d2d2cb
--- /dev/null
+++ b/poky/meta/recipes-extended/ltp/ltp/0041-cve-2017-5669-shmat-for-0-or-PAGESIZE-with-RND-flag-.patch
@@ -0,0 +1,97 @@
+From b767b73ef027ba8d35f297c7d3659265ac80425b Mon Sep 17 00:00:00 2001
+From: Rafael David Tinoco <rafael.tinoco@canonical.com>
+Date: Wed, 30 May 2018 09:14:34 -0300
+Subject: [PATCH] cve-2017-5669: shmat() for 0 (or <PAGESIZE with RND flag) has
+ to fail with REMAPs
+
+Fixes: https://github.com/linux-test-project/ltp/issues/319
+
+According to upstream thread (https://lkml.org/lkml/2018/5/28/2056),
+cve-2017-5669 needs to address the "new" way of handling nil addresses
+for shmat() when used with MAP_FIXED or SHM_REMAP flags.
+
+- mapping nil-page is OK on lower addresses with MAP_FIXED (or else X11 is broken)
+- mapping nil-page is NOT OK with SHM_REMAP on lower addresses
+
+Addresses Davidlohr Bueso's comments/changes:
+
+commit 8f89c007b6de
+Author: Davidlohr Bueso <dave@stgolabs.net>
+Date:   Fri May 25 14:47:30 2018 -0700
+
+    ipc/shm: fix shmat() nil address after round-down when remapping
+
+commit a73ab244f0da
+Author: Davidlohr Bueso <dave@stgolabs.net>
+Date:   Fri May 25 14:47:27 2018 -0700
+
+    Revert "ipc/shm: Fix shmat mmap nil-page protection"
+
+For previously test, and now broken, made based on:
+
+commit 95e91b831f87
+Author: Davidlohr Bueso <dave@stgolabs.net>
+Date:   Mon Feb 27 14:28:24 2017 -0800
+
+    ipc/shm: Fix shmat mmap nil-page protection
+
+Signed-off-by: Rafael David Tinoco <rafael.tinoco@linaro.org>
+Tested-by: Naresh Kamboju <naresh.kamboju@linaro.org>
+Reviewed-by: Jan Stancek <jstancek@redhat.com>
+
+Upstream-Status: Accepted [https://github.com/linux-test-project/ltp/pull/324]
+CVE: CVE-2017-5669
+Signed-off-by: Rafael David Tinoco <rafael.tinoco@linaro.org>
+---
+ testcases/cve/cve-2017-5669.c | 20 +++++++++++++++++++-
+ 1 file changed, 19 insertions(+), 1 deletion(-)
+
+diff --git a/testcases/cve/cve-2017-5669.c b/testcases/cve/cve-2017-5669.c
+index 1ca5983..0834626 100644
+--- a/testcases/cve/cve-2017-5669.c
++++ b/testcases/cve/cve-2017-5669.c
+@@ -28,7 +28,20 @@
+  * is just to see if we get an access error or some other unexpected behaviour.
+  *
+  * See commit 95e91b831f (ipc/shm: Fix shmat mmap nil-page protection)
++ *
++ * The commit above disallowed SHM_RND maps to zero (and rounded) entirely and
++ * that broke userland for cases like Xorg. New behavior disallows REMAPs to
++ * lower addresses (0<=PAGESIZE).
++ *
++ * See commit a73ab244f0da (Revert "ipc/shm: Fix shmat mmap nil-page protect...)
++ * See commit 8f89c007b6de (ipc/shm: fix shmat() nil address after round-dow...)
++ * See https://github.com/linux-test-project/ltp/issues/319
++ *
++ * This test needs root permissions or else security_mmap_addr(), from
++ * get_unmapped_area(), will cause permission errors when trying to mmap lower
++ * addresses.
+  */
++
+ #include <sys/types.h>
+ #include <sys/ipc.h>
+ #include <sys/shm.h>
+@@ -60,7 +73,11 @@ static void cleanup(void)
+ static void run(void)
+ {
+ 	tst_res(TINFO, "Attempting to attach shared memory to null page");
+-	shm_addr = shmat(shm_id, ((void *)1), SHM_RND);
++	/*
++	 * shmat() for 0 (or < PAGESIZE with RND flag) has to fail with REMAPs
++	 * https://github.com/linux-test-project/ltp/issues/319
++	 */
++	shm_addr = shmat(shm_id, ((void *)1), SHM_RND | SHM_REMAP);
+ 	if (shm_addr == (void *)-1) {
+ 		shm_addr = NULL;
+ 		if (errno == EINVAL) {
+@@ -89,6 +106,7 @@ static void run(void)
+ }
+ 
+ static struct tst_test test = {
++	.needs_root = 1,
+ 	.setup = setup,
+ 	.cleanup = cleanup,
+ 	.test_all = run,
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-extended/ltp/ltp/0042-fs-ftest-ftest06.c-Fix-too-small-name-string-and-rel.patch b/poky/meta/recipes-extended/ltp/ltp/0042-fs-ftest-ftest06.c-Fix-too-small-name-string-and-rel.patch
new file mode 100644
index 0000000..407d98e
--- /dev/null
+++ b/poky/meta/recipes-extended/ltp/ltp/0042-fs-ftest-ftest06.c-Fix-too-small-name-string-and-rel.patch
@@ -0,0 +1,34 @@
+From baeef026f80e19a634a4096e97286419aca1cf68 Mon Sep 17 00:00:00 2001
+From: He Zhe <zhe.he@windriver.com>
+Date: Thu, 23 Aug 2018 00:22:04 +0800
+Subject: [PATCH] fs/ftest/ftest06.c: Fix too small name string and related
+ failure
+
+The name string is too small to contain normal full path names and causes
+the following failure.
+
+"ftest06     2  TFAIL  :  ftest06.c:223: Can't chdir(): errno=ENOENT(2): No such file or directory"
+
+Upstream-Status: Submitted [ltp-list@lists.sourceforge.net]
+
+Signed-off-by: He Zhe <zhe.he@windriver.com>
+---
+ testcases/kernel/fs/ftest/ftest06.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/testcases/kernel/fs/ftest/ftest06.c b/testcases/kernel/fs/ftest/ftest06.c
+index 2ca7c88..b434067 100644
+--- a/testcases/kernel/fs/ftest/ftest06.c
++++ b/testcases/kernel/fs/ftest/ftest06.c
+@@ -100,7 +100,7 @@ static char *fstyp;
+ int main(int ac, char *av[])
+ {
+ 	int pid, child, status, count, k, j;
+-	char name[3];
++	char name[MAXPATHLEN];
+ 
+ 	int lc;
+ 
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-extended/ltp/ltp/0043-open-creat-skip-S_ISGID-check-on-files-created-by-no.patch b/poky/meta/recipes-extended/ltp/ltp/0043-open-creat-skip-S_ISGID-check-on-files-created-by-no.patch
new file mode 100644
index 0000000..dc61fcc
--- /dev/null
+++ b/poky/meta/recipes-extended/ltp/ltp/0043-open-creat-skip-S_ISGID-check-on-files-created-by-no.patch
@@ -0,0 +1,81 @@
+From 3c87ef2961dedb10d1f674c6a530e00dbab8ec1b Mon Sep 17 00:00:00 2001
+From: Jan Stancek <jstancek@redhat.com>
+Date: Tue, 17 Jul 2018 10:26:39 +0200
+Subject: [PATCH] open|creat: skip S_ISGID check on files created by non-group
+ members
+
+0fa3ecd87848 ("Fix up non-directory creation in SGID directories")
+fixes problem described in CVE-2018-13405. This commit is getting
+backported to older streams as well.
+
+This patch removes S_ISGID check for files created by non-group members
+in LTP tests creat08 and open10.
+
+Once 0fa3ecd87848 will be in non-rc kernel, we could add a new test
+for this CVE that would be limited to 4.18+ kernels.
+
+Signed-off-by: Jan Stancek <jstancek@redhat.com>
+Acked-by: Cyril Hrubis <chrubis@suse.cz>
+Reviewed-by: Naresh Kamboju <naresh.kamboju@linaro.org>
+
+Upstream-Status: Backport
+[ git://github.com/linux-test-project/ltp.git
+  3c87ef2961dedb10d1f674c6a530e00dbab8ec1b
+  "open|creat: skip S_ISGID check on files created by non-group members" ]
+
+Signed-off-by: He Zhe <zhe.he@windriver.com>
+---
+ testcases/kernel/syscalls/creat/creat08.c | 13 ++++++-------
+ testcases/kernel/syscalls/open/open10.c   | 12 +++++-------
+ 2 files changed, 11 insertions(+), 14 deletions(-)
+
+diff --git a/testcases/kernel/syscalls/creat/creat08.c b/testcases/kernel/syscalls/creat/creat08.c
+index 50f2b3993..d22558ac3 100644
+--- a/testcases/kernel/syscalls/creat/creat08.c
++++ b/testcases/kernel/syscalls/creat/creat08.c
+@@ -361,13 +361,12 @@ int main(int ac, char **av)
+ 			local_flag = FAILED;
+ 		}
+ 
+-		/* Verify modes */
+-		if (!(buf.st_mode & S_ISGID)) {
+-			tst_resm(TFAIL,
+-				 "%s: Incorrect modes, setgid bit should be set",
+-				 setgid_B);
+-			local_flag = FAILED;
+-		}
++		/*
++		 * Skip S_ISGID check
++		 * 0fa3ecd87848 ("Fix up non-directory creation in SGID directories")
++		 * clears S_ISGID for files created by non-group members
++		 */
++
+ 		close(fd);
+ 
+ 		if (local_flag == PASSED) {
+diff --git a/testcases/kernel/syscalls/open/open10.c b/testcases/kernel/syscalls/open/open10.c
+index 613f2288f..14feec9e1 100644
+--- a/testcases/kernel/syscalls/open/open10.c
++++ b/testcases/kernel/syscalls/open/open10.c
+@@ -345,13 +345,11 @@ int main(int ac, char *av[])
+ 			local_flag = FAILED;
+ 		}
+ 
+-		/* Verify modes */
+-		if (!(buf.st_mode & S_ISGID)) {
+-			tst_resm(TFAIL,
+-				 "%s: Incorrect modes, setgid bit not set",
+-				 setgid_B);
+-			local_flag = FAILED;
+-		}
++		/*
++		 * Skip S_ISGID check
++		 * 0fa3ecd87848 ("Fix up non-directory creation in SGID directories")
++		 * clears S_ISGID for files created by non-group members
++		 */
+ 
+ 		if (local_flag == PASSED) {
+ 			tst_resm(TPASS, "Test passed in block2.");
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-extended/ltp/ltp_20180118.bb b/poky/meta/recipes-extended/ltp/ltp_20180118.bb
deleted file mode 100644
index 8754fcd..0000000
--- a/poky/meta/recipes-extended/ltp/ltp_20180118.bb
+++ /dev/null
@@ -1,116 +0,0 @@
-SUMMARY = "Linux Test Project"
-DESCRIPTION = "The Linux Test Project is a joint project with SGI, IBM, OSDL, and Bull with a goal to deliver test suites to the open source community that validate the reliability, robustness, and stability of Linux. The Linux Test Project is a collection of tools for testing the Linux kernel and related features."
-HOMEPAGE = "http://ltp.sourceforge.net"
-SECTION = "console/utils"
-LICENSE = "GPLv2 & GPLv2+ & LGPLv2+ & LGPLv2.1+ & BSD-2-Clause"
-LIC_FILES_CHKSUM = "\
-    file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-    file://testcases/kernel/controllers/freezer/COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3 \
-    file://testcases/kernel/controllers/freezer/run_freezer.sh;beginline=5;endline=17;md5=86a61d2c042d59836ffb353a21456498 \
-    file://testcases/kernel/hotplug/memory_hotplug/COPYING;md5=e04a2e542b2b8629bf9cd2ba29b0fe41 \
-    file://testcases/kernel/hotplug/cpu_hotplug/COPYING;md5=e04a2e542b2b8629bf9cd2ba29b0fe41 \
-    file://testcases/open_posix_testsuite/COPYING;md5=48b1c5ec633e3e30ec2cf884ae699947 \
-    file://testcases/realtime/COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e \
-    file://tools/pounder21/COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
-    file://utils/benchmark/kernbench-0.42/COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
-    file://utils/ffsb-6.0-rc2/COPYING;md5=c46082167a314d785d012a244748d803 \
-"
-
-DEPENDS = "attr libaio libcap acl openssl zip-native"
-DEPENDS_append_libc-musl = " fts "
-EXTRA_OEMAKE_append_libc-musl = " LIBC=musl "
-CFLAGS_append_powerpc64 = " -D__SANE_USERSPACE_TYPES__"
-CFLAGS_append_mipsarchn64 = " -D__SANE_USERSPACE_TYPES__"
-SRCREV = "731cd34e682d297b207668be8b1d15320a9ac1b1"
-
-SRC_URI = "git://github.com/linux-test-project/ltp.git \
-           file://0001-configure-add-knob-to-control-numa-support.patch \
-           file://0001-configure-Fix-default-value-of-without-numa-switch-i.patch \
-           file://0003-Add-knob-to-control-tirpc-support.patch \
-           file://0004-build-Add-option-to-select-libc-implementation.patch \
-           file://0005-kernel-controllers-Link-with-libfts-explicitly-on-mu.patch \
-           file://0007-fix-__WORDSIZE-undeclared-when-building-with-musl.patch \
-           file://0008-Check-if-__GLIBC_PREREQ-is-defined-before-using-it.patch \
-           file://0009-fix-redefinition-of-struct-msgbuf-error-building-wit.patch \
-           file://0010-replace-__BEGIN_DECLS-and-__END_DECLS.patch \
-           file://0018-guard-mallocopt-with-__GLIBC__.patch \
-           file://0020-getdents-define-getdents-getdents64-only-for-glibc.patch \
-           file://0021-Define-_GNU_SOURCE-for-MREMAP_MAYMOVE-definition.patch \
-           file://0023-ptrace-Use-int-instead-of-enum-__ptrace_request.patch \
-           file://0024-rt_sigaction-rt_sigprocmark-Define-_GNU_SOURCE.patch \
-           file://0026-crash01-Define-_GNU_SOURCE.patch \
-           file://0028-rt_sigaction.h-Use-sighandler_t-instead-of-__sighand.patch \
-           file://0034-periodic_output.patch \
-           file://0035-fix-test_proc_kill-hang.patch \
-           file://0036-testcases-network-nfsv4-acl-acl1.c-Security-fix-on-s.patch \
-           file://0039-commands-ar01-Fix-for-test-in-deterministic-mode.patch \
-           file://0040-safe_macros-make-is_fuse-return-zero-if-fs_type-is-N.patch \
-           "
-
-S = "${WORKDIR}/git"
-
-inherit autotools-brokensep
-
-TARGET_CC_ARCH += "${LDFLAGS}"
-
-export prefix = "/opt/ltp"
-export exec_prefix = "/opt/ltp"
-
-PACKAGECONFIG[numa] = "--with-numa, --without-numa, numactl,"
-EXTRA_AUTORECONF += "-I ${S}/testcases/realtime/m4"
-EXTRA_OECONF = " --with-power-management-testsuite --with-realtime-testsuite --with-open-posix-testsuite "
-# ltp network/rpc test cases ftbfs when libtirpc is found
-EXTRA_OECONF += " --without-tirpc "
-
-do_install(){
-    install -d ${D}/opt/ltp/
-    oe_runmake DESTDIR=${D} SKIP_IDCHECK=1 install
-
-    # fixup not deploy STPfailure_report.pl to avoid confusing about it fails to run
-    # as it lacks dependency on some perl moudle such as LWP::Simple
-    # And this script previously works as a tool for analyzing failures from LTP
-    # runs on the OSDL's Scaleable Test Platform (STP) and it mainly accesses
-    # http://khack.osdl.org to retrieve ltp test results run on
-    # OSDL's Scaleable Test Platform, but now http://khack.osdl.org unaccessible
-    rm -rf ${D}/opt/ltp/bin/STPfailure_report.pl
-
-    # Copy POSIX test suite into ${D}/opt/ltp/testcases by manual
-    cp -r testcases/open_posix_testsuite ${D}/opt/ltp/testcases
-}
-
-RDEPENDS_${PN} = "\
-    acl \
-    at \
-    attr \
-    bash \
-    cpio \
-    cronie \
-    curl \
-    e2fsprogs-mke2fs \
-    expect \
-    gawk \
-    gzip \
-    iproute2 \
-    ldd \
-    libaio \
-    logrotate \
-    perl \
-    python-core \
-    procps \
-    unzip \
-    util-linux \
-    which \
-    tar \
-"
-
-FILES_${PN} += "/opt/ltp/* /opt/ltp/runtest/* /opt/ltp/scenario_groups/* /opt/ltp/testcases/bin/* /opt/ltp/testcases/bin/*/bin/* /opt/ltp/testscripts/* /opt/ltp/testcases/open_posix_testsuite/* /opt/ltp/testcases/open_posix_testsuite/conformance/* /opt/ltp/testcases/open_posix_testsuite/Documentation/* /opt/ltp/testcases/open_posix_testsuite/functional/* /opt/ltp/testcases/open_posix_testsuite/include/* /opt/ltp/testcases/open_posix_testsuite/scripts/* /opt/ltp/testcases/open_posix_testsuite/stress/* /opt/ltp/testcases/open_posix_testsuite/tools/* /opt/ltp/testcases/data/nm01/lib.a /opt/ltp/lib/libmem.a"
-
-# Avoid stripping some generated binaries otherwise some of the ltp tests such as ldd01 & nm01 fail
-INHIBIT_PACKAGE_STRIP_FILES = "/opt/ltp/testcases/bin/nm01 /opt/ltp/testcases/bin/ldd01"
-INSANE_SKIP_${PN} += "already-stripped staticdev"
-
-# Avoid file dependency scans, as LTP checks for things that may or may not
-# exist on the running system.  For instance it has specific checks for
-# csh and ksh which are not typically part of OpenEmbedded systems (but
-# can be added via additional layers.)
-SKIP_FILEDEPS_${PN} = '1'
diff --git a/poky/meta/recipes-extended/ltp/ltp_20180515.bb b/poky/meta/recipes-extended/ltp/ltp_20180515.bb
new file mode 100644
index 0000000..ff85be7
--- /dev/null
+++ b/poky/meta/recipes-extended/ltp/ltp_20180515.bb
@@ -0,0 +1,127 @@
+SUMMARY = "Linux Test Project"
+DESCRIPTION = "The Linux Test Project is a joint project with SGI, IBM, OSDL, and Bull with a goal to deliver test suites to the open source community that validate the reliability, robustness, and stability of Linux. The Linux Test Project is a collection of tools for testing the Linux kernel and related features."
+HOMEPAGE = "http://ltp.sourceforge.net"
+SECTION = "console/utils"
+LICENSE = "GPLv2 & GPLv2+ & LGPLv2+ & LGPLv2.1+ & BSD-2-Clause"
+LIC_FILES_CHKSUM = "\
+    file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+    file://testcases/kernel/controllers/freezer/COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3 \
+    file://testcases/kernel/controllers/freezer/run_freezer.sh;beginline=5;endline=17;md5=86a61d2c042d59836ffb353a21456498 \
+    file://testcases/kernel/hotplug/memory_hotplug/COPYING;md5=e04a2e542b2b8629bf9cd2ba29b0fe41 \
+    file://testcases/kernel/hotplug/cpu_hotplug/COPYING;md5=e04a2e542b2b8629bf9cd2ba29b0fe41 \
+    file://testcases/open_posix_testsuite/COPYING;md5=48b1c5ec633e3e30ec2cf884ae699947 \
+    file://testcases/realtime/COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e \
+    file://tools/pounder21/COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
+    file://utils/benchmark/kernbench-0.42/COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
+    file://utils/ffsb-6.0-rc2/COPYING;md5=c46082167a314d785d012a244748d803 \
+"
+
+DEPENDS = "attr libaio libcap acl openssl zip-native"
+DEPENDS_append_libc-musl = " fts "
+EXTRA_OEMAKE_append_libc-musl = " LIBC=musl "
+
+# since ltp contains x86-64 assembler which uses the frame-pointer register,
+# set -fomit-frame-pointer x86-64 to handle cases where optimisation
+# is set to -O0 or frame pointers have been enabled by -fno-omit-frame-pointer
+# earlier in CFLAGS, etc.
+CFLAGS_append_x86-64 = " -fomit-frame-pointer"
+
+CFLAGS_append_powerpc64 = " -D__SANE_USERSPACE_TYPES__"
+CFLAGS_append_mipsarchn64 = " -D__SANE_USERSPACE_TYPES__"
+SRCREV = "96cbf48313afa65ef4d693d3441cbfd60a8d9b27"
+
+SRC_URI = "git://github.com/linux-test-project/ltp.git \
+           file://0001-mmap15-mips64-return-EINVAL.patch \
+           file://0004-build-Add-option-to-select-libc-implementation.patch \
+           file://0005-kernel-controllers-Link-with-libfts-explicitly-on-mu.patch \
+           file://0007-fix-__WORDSIZE-undeclared-when-building-with-musl.patch \
+           file://0008-Check-if-__GLIBC_PREREQ-is-defined-before-using-it.patch \
+           file://0009-fix-redefinition-of-struct-msgbuf-error-building-wit.patch \
+           file://0018-guard-mallocopt-with-__GLIBC__.patch \
+           file://0020-getdents-define-getdents-getdents64-only-for-glibc.patch \
+           file://0021-Define-_GNU_SOURCE-for-MREMAP_MAYMOVE-definition.patch \
+           file://0023-ptrace-Use-int-instead-of-enum-__ptrace_request.patch \
+           file://0024-rt_sigaction-rt_sigprocmark-Define-_GNU_SOURCE.patch \
+           file://0026-crash01-Define-_GNU_SOURCE.patch \
+           file://0028-rt_sigaction.h-Use-sighandler_t-instead-of-__sighand.patch \
+           file://0034-periodic_output.patch \
+           file://0035-fix-test_proc_kill-hang.patch \
+           file://0036-testcases-network-nfsv4-acl-acl1.c-Security-fix-on-s.patch \
+           file://0039-commands-ar01-Fix-for-test-in-deterministic-mode.patch \
+           file://0040-read_all-Define-FNM_EXTMATCH-if-not-already-like-und.patch \
+           file://0041-cve-2017-5669-shmat-for-0-or-PAGESIZE-with-RND-flag-.patch \
+           file://0042-fs-ftest-ftest06.c-Fix-too-small-name-string-and-rel.patch \
+           file://0043-open-creat-skip-S_ISGID-check-on-files-created-by-no.patch \
+           file://0001-syscalls-fcntl-make-OFD-command-use-fcntl64-syscall-.patch \
+           file://0001-sigwaitinfo01-recent-glibc-calls-syscall-directly.patch \
+           file://0001-netns_helper.sh-use-ping-6-when-ping6-is-not-avaliab.patch \
+           file://0001-open_posix_testsuite-mmap24-2-Relax-condition-a-bit.patch \
+           "
+
+S = "${WORKDIR}/git"
+
+inherit autotools-brokensep
+
+TARGET_CC_ARCH += "${LDFLAGS}"
+
+export prefix = "/opt/ltp"
+export exec_prefix = "/opt/ltp"
+
+PACKAGECONFIG[numa] = "--with-numa, --without-numa, numactl,"
+EXTRA_AUTORECONF += "-I ${S}/testcases/realtime/m4"
+EXTRA_OECONF = " --with-power-management-testsuite --with-realtime-testsuite --with-open-posix-testsuite "
+# ltp network/rpc test cases ftbfs when libtirpc is found
+EXTRA_OECONF += " --without-tirpc "
+
+do_install(){
+    install -d ${D}/opt/ltp/
+    oe_runmake DESTDIR=${D} SKIP_IDCHECK=1 install
+
+    # fixup not deploy STPfailure_report.pl to avoid confusing about it fails to run
+    # as it lacks dependency on some perl moudle such as LWP::Simple
+    # And this script previously works as a tool for analyzing failures from LTP
+    # runs on the OSDL's Scaleable Test Platform (STP) and it mainly accesses
+    # http://khack.osdl.org to retrieve ltp test results run on
+    # OSDL's Scaleable Test Platform, but now http://khack.osdl.org unaccessible
+    rm -rf ${D}/opt/ltp/bin/STPfailure_report.pl
+
+    # Copy POSIX test suite into ${D}/opt/ltp/testcases by manual
+    cp -r testcases/open_posix_testsuite ${D}/opt/ltp/testcases
+}
+
+RDEPENDS_${PN} = "\
+    acl \
+    at \
+    attr \
+    bash \
+    cpio \
+    cronie \
+    curl \
+    e2fsprogs-mke2fs \
+    expect \
+    gawk \
+    gzip \
+    iproute2 \
+    ldd \
+    libaio \
+    logrotate \
+    perl \
+    python-core \
+    procps \
+    unzip \
+    util-linux \
+    which \
+    tar \
+"
+
+FILES_${PN} += "/opt/ltp/* /opt/ltp/runtest/* /opt/ltp/scenario_groups/* /opt/ltp/testcases/bin/* /opt/ltp/testcases/bin/*/bin/* /opt/ltp/testscripts/* /opt/ltp/testcases/open_posix_testsuite/* /opt/ltp/testcases/open_posix_testsuite/conformance/* /opt/ltp/testcases/open_posix_testsuite/Documentation/* /opt/ltp/testcases/open_posix_testsuite/functional/* /opt/ltp/testcases/open_posix_testsuite/include/* /opt/ltp/testcases/open_posix_testsuite/scripts/* /opt/ltp/testcases/open_posix_testsuite/stress/* /opt/ltp/testcases/open_posix_testsuite/tools/* /opt/ltp/testcases/data/nm01/lib.a /opt/ltp/lib/libmem.a"
+
+# Avoid stripping some generated binaries otherwise some of the ltp tests such as ldd01 & nm01 fail
+INHIBIT_PACKAGE_STRIP_FILES = "/opt/ltp/testcases/bin/nm01 /opt/ltp/testcases/bin/ldd01"
+INSANE_SKIP_${PN} += "already-stripped staticdev"
+
+# Avoid file dependency scans, as LTP checks for things that may or may not
+# exist on the running system.  For instance it has specific checks for
+# csh and ksh which are not typically part of OpenEmbedded systems (but
+# can be added via additional layers.)
+SKIP_FILEDEPS_${PN} = '1'
diff --git a/poky/meta/recipes-extended/lzip/lzip_1.19.bb b/poky/meta/recipes-extended/lzip/lzip_1.19.bb
deleted file mode 100644
index 099b364..0000000
--- a/poky/meta/recipes-extended/lzip/lzip_1.19.bb
+++ /dev/null
@@ -1,41 +0,0 @@
-SUMMARY = "Lossless data compressor based on the LZMA algorithm"
-HOMEPAGE = "http://lzip.nongnu.org/lzip.html"
-SECTION = "console/utils"
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=76d6e300ffd8fb9d18bd9b136a9bba13 \
-                    file://decoder.cc;beginline=3;endline=16;md5=db09fe3f9573f94d0076f7f07959e6e1"
-
-SRC_URI = "${SAVANNAH_GNU_MIRROR}/lzip/lzip-${PV}.tar.gz"
-
-SRC_URI[md5sum] = "4dd8790d7528440d034fc713a8680bd3"
-SRC_URI[sha256sum] = "ffadc4f56be1bc0d3ae155ec4527bd003133bdc703a753b2cc683f610e646ba9"
-
-CONFIGUREOPTS = "\
-    '--srcdir=${S}' \
-    '--prefix=${prefix}' \
-    '--exec-prefix=${exec_prefix}' \
-    '--bindir=${bindir}' \
-    '--datadir=${datadir}' \
-    '--infodir=${infodir}' \
-    '--sysconfdir=${sysconfdir}' \
-    'CXX=${CXX}' \
-    'CPPFLAGS=${CPPFLAGS}' \
-    'CXXFLAGS=${CXXFLAGS}' \
-    'LDFLAGS=${LDFLAGS}' \
-"
-EXTRA_OEMAKE = ""
-
-B = "${S}/obj"
-do_configure () {
-    ${S}/configure ${CONFIGUREOPTS}
-}
-
-do_install () {
-    oe_runmake 'DESTDIR=${D}' install
-    # Info dir listing isn't interesting at this point so remove it if it exists.
-    if [ -e "${D}${infodir}/dir" ]; then
-        rm -f ${D}${infodir}/dir
-    fi
-}
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/lzip/lzip_1.20.bb b/poky/meta/recipes-extended/lzip/lzip_1.20.bb
new file mode 100644
index 0000000..d1fc2a1
--- /dev/null
+++ b/poky/meta/recipes-extended/lzip/lzip_1.20.bb
@@ -0,0 +1,41 @@
+SUMMARY = "Lossless data compressor based on the LZMA algorithm"
+HOMEPAGE = "http://lzip.nongnu.org/lzip.html"
+SECTION = "console/utils"
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=76d6e300ffd8fb9d18bd9b136a9bba13 \
+                    file://decoder.cc;beginline=3;endline=16;md5=db09fe3f9573f94d0076f7f07959e6e1"
+
+SRC_URI = "${SAVANNAH_GNU_MIRROR}/lzip/lzip-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "21c1517da2ace9689fd953918660b3c3"
+SRC_URI[sha256sum] = "c93b81a5a7788ef5812423d311345ba5d3bd4f5ebf1f693911e3a13553c1290c"
+
+CONFIGUREOPTS = "\
+    '--srcdir=${S}' \
+    '--prefix=${prefix}' \
+    '--exec-prefix=${exec_prefix}' \
+    '--bindir=${bindir}' \
+    '--datadir=${datadir}' \
+    '--infodir=${infodir}' \
+    '--sysconfdir=${sysconfdir}' \
+    'CXX=${CXX}' \
+    'CPPFLAGS=${CPPFLAGS}' \
+    'CXXFLAGS=${CXXFLAGS}' \
+    'LDFLAGS=${LDFLAGS}' \
+"
+EXTRA_OEMAKE = ""
+
+B = "${S}/obj"
+do_configure () {
+    ${S}/configure ${CONFIGUREOPTS}
+}
+
+do_install () {
+    oe_runmake 'DESTDIR=${D}' install
+    # Info dir listing isn't interesting at this point so remove it if it exists.
+    if [ -e "${D}${infodir}/dir" ]; then
+        rm -f ${D}${infodir}/dir
+    fi
+}
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/man-db/files/99_mandb b/poky/meta/recipes-extended/man-db/files/99_mandb
new file mode 100644
index 0000000..9b8a171
--- /dev/null
+++ b/poky/meta/recipes-extended/man-db/files/99_mandb
@@ -0,0 +1 @@
+d man man 0755 /var/cache/man none
diff --git a/poky/meta/recipes-extended/man-db/files/man_db.conf-avoid-multilib-install-file-conflict.patch b/poky/meta/recipes-extended/man-db/files/man_db.conf-avoid-multilib-install-file-conflict.patch
new file mode 100644
index 0000000..03273d3
--- /dev/null
+++ b/poky/meta/recipes-extended/man-db/files/man_db.conf-avoid-multilib-install-file-conflict.patch
@@ -0,0 +1,16 @@
+The first line of man_db.conf will be replaced by package name. And it causes
+multilib install file conflict. Remove the line to avoid the issue.
+
+Upstream-Status: Pending
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+
+diff --git a/src/man_db.conf.in b/src/man_db.conf.in
+index bc8bb7e..04cfb31 100644
+--- a/src/man_db.conf.in
++++ b/src/man_db.conf.in
+@@ -1,4 +1,3 @@
+-# @config_file_basename@
+ #
+ # This file is used by the man-db package to configure the man and cat paths.
+ # It is also used to provide a manpath for those without one by examining
diff --git a/poky/meta/recipes-extended/man-db/man-db_2.8.1.bb b/poky/meta/recipes-extended/man-db/man-db_2.8.1.bb
deleted file mode 100644
index 8328a67..0000000
--- a/poky/meta/recipes-extended/man-db/man-db_2.8.1.bb
+++ /dev/null
@@ -1,43 +0,0 @@
-SUMMARY = "An implementation of the standard Unix documentation system accessed using the man command"
-HOMEPAGE = "http://man-db.nongnu.org/"
-LICENSE = "LGPLv2.1 & GPLv2"
-LIC_FILES_CHKSUM = "file://docs/COPYING.LIB;md5=a6f89e2100d9b6cdffcea4f398e37343 \
-                    file://docs/COPYING;md5=eb723b61539feef013de476e68b5c50a"
-
-SRC_URI = "${SAVANNAH_NONGNU_MIRROR}/man-db/man-db-${PV}.tar.xz"
-SRC_URI[md5sum] = "51842978e06686286421f9498d1009b7"
-SRC_URI[sha256sum] = "a6aec641ca3d9942b054cc0e9c3f05cb46a3a992bc0006795755e2fed1357f3e"
-
-DEPENDS = "libpipeline gdbm groff-native"
-
-# | /usr/src/debug/man-db/2.8.0-r0/man-db-2.8.0/src/whatis.c:939: undefined reference to `_nl_msg_cat_cntr'
-USE_NLS_libc-musl = "no"
-
-inherit gettext pkgconfig autotools
-
-EXTRA_OECONF = "--with-pager=less --disable-cache-owner"
-
-do_install_append_libc-musl() {
-        rm -f ${D}${libdir}/charset.alias
-}
-
-FILES_${PN} += "${prefix}/lib/tmpfiles.d"
-
-FILES_${PN}-dev += "${libdir}/man-db/libman.so ${libdir}/${BPN}/libmandb.so"
-
-RDEPENDS_${PN} += "groff"
-RRECOMMENDS_${PN} += "less"
-RPROVIDES_${PN} += " man"
-
-def compress_pkg(d):
-    if bb.utils.contains("INHERIT", "compress_doc", True, False, d):
-         compress = d.getVar("DOC_COMPRESS")
-         if compress == "gz":
-             return "gzip"
-         elif compress == "bz2":
-             return "bzip2"
-         elif compress == "xz":
-             return "xz"
-    return ""
-
-RDEPENDS_${PN} += "${@compress_pkg(d)}"
diff --git a/poky/meta/recipes-extended/man-db/man-db_2.8.3.bb b/poky/meta/recipes-extended/man-db/man-db_2.8.3.bb
new file mode 100644
index 0000000..cd8d27c
--- /dev/null
+++ b/poky/meta/recipes-extended/man-db/man-db_2.8.3.bb
@@ -0,0 +1,55 @@
+SUMMARY = "An implementation of the standard Unix documentation system accessed using the man command"
+HOMEPAGE = "http://man-db.nongnu.org/"
+LICENSE = "LGPLv2.1 & GPLv2"
+LIC_FILES_CHKSUM = "file://docs/COPYING.LIB;md5=a6f89e2100d9b6cdffcea4f398e37343 \
+                    file://docs/COPYING;md5=eb723b61539feef013de476e68b5c50a"
+
+SRC_URI = "${SAVANNAH_NONGNU_MIRROR}/man-db/man-db-${PV}.tar.xz \
+           file://99_mandb \
+           file://man_db.conf-avoid-multilib-install-file-conflict.patch"
+SRC_URI[md5sum] = "6f3055e18fdd1ce5cbbdb30403991ec7"
+SRC_URI[sha256sum] = "5932a1ca366e1ec61a3ece1a3afa0e92f2fdc125b61d236f20cc6ff9d80cc4ac"
+
+DEPENDS = "libpipeline gdbm groff-native base-passwd"
+RDEPENDS_${PN} += "base-passwd"
+
+# | /usr/src/debug/man-db/2.8.0-r0/man-db-2.8.0/src/whatis.c:939: undefined reference to `_nl_msg_cat_cntr'
+USE_NLS_libc-musl = "no"
+
+inherit gettext pkgconfig autotools
+
+EXTRA_OECONF = "--with-pager=less"
+
+do_install() {
+	autotools_do_install
+
+	if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
+	        install -d ${D}/etc/default/volatiles
+		install -m 0644 ${WORKDIR}/99_mandb ${D}/etc/default/volatiles
+	fi
+}
+
+do_install_append_libc-musl() {
+        rm -f ${D}${libdir}/charset.alias
+}
+
+FILES_${PN} += "${prefix}/lib/tmpfiles.d"
+
+FILES_${PN}-dev += "${libdir}/man-db/libman.so ${libdir}/${BPN}/libmandb.so"
+
+RDEPENDS_${PN} += "groff"
+RRECOMMENDS_${PN} += "less"
+RPROVIDES_${PN} += " man"
+
+def compress_pkg(d):
+    if bb.utils.contains("INHERIT", "compress_doc", True, False, d):
+         compress = d.getVar("DOC_COMPRESS")
+         if compress == "gz":
+             return "gzip"
+         elif compress == "bz2":
+             return "bzip2"
+         elif compress == "xz":
+             return "xz"
+    return ""
+
+RDEPENDS_${PN} += "${@compress_pkg(d)}"
diff --git a/poky/meta/recipes-extended/man-pages/man-pages_4.14.bb b/poky/meta/recipes-extended/man-pages/man-pages_4.14.bb
deleted file mode 100644
index f8bd090..0000000
--- a/poky/meta/recipes-extended/man-pages/man-pages_4.14.bb
+++ /dev/null
@@ -1,31 +0,0 @@
-SUMMARY = "Linux man-pages"
-DESCRIPTION = "The Linux man-pages project documents the Linux kernel and C library interfaces that are employed by user programs"
-SECTION = "console/utils"
-HOMEPAGE = "http://www.kernel.org/pub/linux/docs/man-pages"
-LICENSE = "GPLv2+"
-
-LIC_FILES_CHKSUM = "file://README;md5=794f701617cc03fe50c53257660d8ec4"
-SRC_URI = "${KERNELORG_MIRROR}/linux/docs/${BPN}/Archive/${BP}.tar.gz"
-
-SRC_URI[md5sum] = "82bd2d05c4d0dba5e7a90d39c9555197"
-SRC_URI[sha256sum] = "aeebc6b09a11e7f7bbc98f3984fe8b8b2bde9d2f5f9dcbd4348a9e0d93704238"
-
-RDEPENDS_${PN} = "man"
-
-do_configure[noexec] = "1"
-do_compile[noexec] = "1"
-
-do_install() {
-        oe_runmake install DESTDIR=${D}
-}
-
-# Only deliveres man-pages so FILES_${PN} gets everything
-FILES_${PN}-doc = ""
-FILES_${PN} = "${mandir}/*"
-
-inherit update-alternatives
-
-ALTERNATIVE_PRIORITY = "100"
-ALTERNATIVE_${PN} = "passwd.5 getspnam.3"
-ALTERNATIVE_LINK_NAME[passwd.5] = "${mandir}/man5/passwd.5"
-ALTERNATIVE_LINK_NAME[getspnam.3] = "${mandir}/man3/getspnam.3"
diff --git a/poky/meta/recipes-extended/man-pages/man-pages_4.16.bb b/poky/meta/recipes-extended/man-pages/man-pages_4.16.bb
new file mode 100644
index 0000000..a64587c
--- /dev/null
+++ b/poky/meta/recipes-extended/man-pages/man-pages_4.16.bb
@@ -0,0 +1,36 @@
+SUMMARY = "Linux man-pages"
+DESCRIPTION = "The Linux man-pages project documents the Linux kernel and C library interfaces that are employed by user programs"
+SECTION = "console/utils"
+HOMEPAGE = "http://www.kernel.org/pub/linux/docs/man-pages"
+LICENSE = "GPLv2+"
+
+LIC_FILES_CHKSUM = "file://README;md5=794f701617cc03fe50c53257660d8ec4"
+SRC_URI = "${KERNELORG_MIRROR}/linux/docs/${BPN}/Archive/${BP}.tar.gz"
+
+SRC_URI[md5sum] = "d1fb8ba312a1c15e0bfda911a98c5544"
+SRC_URI[sha256sum] = "d38b0460bf3f35c95faf7f8cf52dac1216d86a47866f5e5f2fda88c61da04960"
+
+inherit manpages
+
+MAN_PKG = "${PN}"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[manpages] = ""
+
+do_configure[noexec] = "1"
+do_compile[noexec] = "1"
+
+do_install() {
+        oe_runmake install DESTDIR=${D}
+}
+
+# Only deliveres man-pages so FILES_${PN} gets everything
+FILES_${PN}-doc = ""
+FILES_${PN} = "${mandir}/*"
+
+inherit update-alternatives
+
+ALTERNATIVE_PRIORITY = "100"
+ALTERNATIVE_${PN} = "passwd.5 getspnam.3"
+ALTERNATIVE_LINK_NAME[passwd.5] = "${mandir}/man5/passwd.5"
+ALTERNATIVE_LINK_NAME[getspnam.3] = "${mandir}/man3/getspnam.3"
diff --git a/poky/meta/recipes-extended/mc/mc_4.8.20.bb b/poky/meta/recipes-extended/mc/mc_4.8.20.bb
deleted file mode 100644
index 70d1b5e..0000000
--- a/poky/meta/recipes-extended/mc/mc_4.8.20.bb
+++ /dev/null
@@ -1,49 +0,0 @@
-SUMMARY = "Midnight Commander is an ncurses based file manager"
-HOMEPAGE = "http://www.midnight-commander.org/"
-LICENSE = "GPLv3"
-LIC_FILES_CHKSUM = "file://COPYING;md5=270bbafe360e73f9840bd7981621f9c2"
-SECTION = "console/utils"
-DEPENDS = "ncurses glib-2.0 util-linux"
-RDEPENDS_${PN} = "ncurses-terminfo"
-
-SRC_URI = "http://www.midnight-commander.org/downloads/${BPN}-${PV}.tar.bz2 \
-           file://0001-mc-replace-perl-w-with-use-warnings.patch \
-           "
-SRC_URI[md5sum] = "dcfc7aa613c62291a0f71f6b698d8267"
-SRC_URI[sha256sum] = "2d85daaa6ab26e524946df4823ac2f69802bc16bc967781b5e28d5b86fc3b979"
-
-inherit autotools gettext pkgconfig
-
-#
-# Both Samba (smb) and sftp require package delivered from meta-openembedded
-#
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[smb] = "--enable-vfs-smb,--disable-vfs-smb,samba,"
-PACKAGECONFIG[sftp] = "--enable-vfs-sftp,--disable-vfs-sftp,libssh2,"
-
-EXTRA_OECONF = "--with-screen=ncurses --without-gpm-mouse --without-x"
-
-CACHED_CONFIGUREVARS += "ac_cv_path_PERL='/usr/bin/env perl'"
-
-do_install_append () {
-	sed -i -e '1s,#!.*perl,#!${bindir}/env perl,' ${D}${libexecdir}/mc/extfs.d/*
-        
-        rm ${D}${libexecdir}/mc/extfs.d/s3+ ${D}${libexecdir}/mc/extfs.d/uc1541
-}
-
-PACKAGES =+ "${BPN}-helpers-perl ${BPN}-helpers ${BPN}-fish"
-
-SUMMARY_${BPN}-helpers-perl = "Midnight Commander Perl-based helper scripts"
-FILES_${BPN}-helpers-perl = "${libexecdir}/mc/extfs.d/a+ ${libexecdir}/mc/extfs.d/apt+ \
-                             ${libexecdir}/mc/extfs.d/deb ${libexecdir}/mc/extfs.d/deba \
-                             ${libexecdir}/mc/extfs.d/debd ${libexecdir}/mc/extfs.d/dpkg+ \
-                             ${libexecdir}/mc/extfs.d/mailfs ${libexecdir}/mc/extfs.d/patchfs \ 
-                             ${libexecdir}/mc/extfs.d/rpms+ ${libexecdir}/mc/extfs.d/ulib \ 
-                             ${libexecdir}/mc/extfs.d/uzip"
-RDEPENDS_${BPN}-helpers-perl = "perl"
-
-SUMMARY_${BPN}-helpers = "Midnight Commander shell helper scripts"
-FILES_${BPN}-helpers = "${libexecdir}/mc/extfs.d/* ${libexecdir}/mc/ext.d/*"
-
-SUMMARY_${BPN}-fish = "Midnight Commander Fish scripts"
-FILES_${BPN}-fish = "${libexecdir}/mc/fish"
diff --git a/poky/meta/recipes-extended/mc/mc_4.8.21.bb b/poky/meta/recipes-extended/mc/mc_4.8.21.bb
new file mode 100644
index 0000000..c6a4500
--- /dev/null
+++ b/poky/meta/recipes-extended/mc/mc_4.8.21.bb
@@ -0,0 +1,49 @@
+SUMMARY = "Midnight Commander is an ncurses based file manager"
+HOMEPAGE = "http://www.midnight-commander.org/"
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=270bbafe360e73f9840bd7981621f9c2"
+SECTION = "console/utils"
+DEPENDS = "ncurses glib-2.0 util-linux"
+RDEPENDS_${PN} = "ncurses-terminfo"
+
+SRC_URI = "http://www.midnight-commander.org/downloads/${BPN}-${PV}.tar.bz2 \
+           file://0001-mc-replace-perl-w-with-use-warnings.patch \
+           "
+SRC_URI[md5sum] = "63d2b90e2198ee79d08eb4a8989220e2"
+SRC_URI[sha256sum] = "251d9f0ef9309ef3eea0fdc4c12b8b61149e5056bef1b2de2ccc7f015d973444"
+
+inherit autotools gettext pkgconfig
+
+#
+# Both Samba (smb) and sftp require package delivered from meta-openembedded
+#
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[smb] = "--enable-vfs-smb,--disable-vfs-smb,samba,"
+PACKAGECONFIG[sftp] = "--enable-vfs-sftp,--disable-vfs-sftp,libssh2,"
+
+EXTRA_OECONF = "--with-screen=ncurses --without-gpm-mouse --without-x"
+
+CACHED_CONFIGUREVARS += "ac_cv_path_PERL='/usr/bin/env perl'"
+
+do_install_append () {
+	sed -i -e '1s,#!.*perl,#!${bindir}/env perl,' ${D}${libexecdir}/mc/extfs.d/*
+        
+        rm ${D}${libexecdir}/mc/extfs.d/s3+ ${D}${libexecdir}/mc/extfs.d/uc1541
+}
+
+PACKAGES =+ "${BPN}-helpers-perl ${BPN}-helpers ${BPN}-fish"
+
+SUMMARY_${BPN}-helpers-perl = "Midnight Commander Perl-based helper scripts"
+FILES_${BPN}-helpers-perl = "${libexecdir}/mc/extfs.d/a+ ${libexecdir}/mc/extfs.d/apt+ \
+                             ${libexecdir}/mc/extfs.d/deb ${libexecdir}/mc/extfs.d/deba \
+                             ${libexecdir}/mc/extfs.d/debd ${libexecdir}/mc/extfs.d/dpkg+ \
+                             ${libexecdir}/mc/extfs.d/mailfs ${libexecdir}/mc/extfs.d/patchfs \ 
+                             ${libexecdir}/mc/extfs.d/rpms+ ${libexecdir}/mc/extfs.d/ulib \ 
+                             ${libexecdir}/mc/extfs.d/uzip"
+RDEPENDS_${BPN}-helpers-perl = "perl"
+
+SUMMARY_${BPN}-helpers = "Midnight Commander shell helper scripts"
+FILES_${BPN}-helpers = "${libexecdir}/mc/extfs.d/* ${libexecdir}/mc/ext.d/*"
+
+SUMMARY_${BPN}-fish = "Midnight Commander Fish scripts"
+FILES_${BPN}-fish = "${libexecdir}/mc/fish"
diff --git a/poky/meta/recipes-extended/mdadm/files/0001-Disable-gcc8-warnings.patch b/poky/meta/recipes-extended/mdadm/files/0001-Disable-gcc8-warnings.patch
new file mode 100644
index 0000000..739652c
--- /dev/null
+++ b/poky/meta/recipes-extended/mdadm/files/0001-Disable-gcc8-warnings.patch
@@ -0,0 +1,152 @@
+From b83218de2623c0bbe9af355a81ae8385d7f30cfc Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 9 May 2018 12:56:41 -0700
+Subject: [PATCH] Disable gcc8 warnings
+
+This is needed until
+https://bugzilla.redhat.com/show_bug.cgi?id=1553958
+
+Fix super0.c issue which is triggered only in DEBUG_BUILD with -O1 (or any
+configuration without -ftree-vrp or with -fno-tree-vrp)
+
+super0.c: In function 'examine_super0':
+super0.c:238:32: error: 'snprintf' output may be truncated before the last format character [-Werror=format-truncation=]
+   snprintf(nb, sizeof(nb), "%4d", d);
+                                ^
+
+Upstream-Status: Inappropriate [Workaround]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+---
+ Monitor.c     | 4 +++-
+ mdopen.c      | 4 ++++
+ super-ddf.c   | 4 ++++
+ super-intel.c | 6 ++++++
+ super1.c      | 5 +++++
+ super0.c      | 2 +-
+ 6 files changed, 22 insertions(+), 1 deletion(-)
+
+diff --git a/super0.c b/super0.c
+index f5b4507..264b598 100644
+--- a/super0.c
++++ b/super0.c
+@@ -231,7 +231,7 @@
+ 	     d++) {
+ 		mdp_disk_t *dp;
+ 		char *dv;
+-		char nb[11];
++		char nb[12];
+ 		int wonly, failfast;
+ 		if (d>=0) dp = &sb->disks[d];
+ 		else dp = &sb->this_disk;
+diff --git a/Monitor.c b/Monitor.c
+index 802a9d9..23b246b 100644
+--- a/Monitor.c
++++ b/Monitor.c
+@@ -441,7 +441,8 @@ static void alert(char *event, char *dev, char *disc, struct alert_info *info)
+ 			       event, dev);
+ 	}
+ }
+-
++#pragma GCC diagnostic push
++#pragma GCC diagnostic ignored "-Wformat-truncation"
+ static int check_array(struct state *st, struct mdstat_ent *mdstat,
+ 		       int test, struct alert_info *ainfo,
+ 		       int increments, char *prefer)
+@@ -683,6 +684,7 @@ static int check_array(struct state *st, struct mdstat_ent *mdstat,
+ 		return 1;
+ 	return 0;
+ }
++#pragma GCC diagnostic pop
+ 
+ static int add_new_arrays(struct mdstat_ent *mdstat, struct state **statelist,
+ 			  int test, struct alert_info *info)
+diff --git a/mdopen.c b/mdopen.c
+index 685ca32..406aba4 100644
+--- a/mdopen.c
++++ b/mdopen.c
+@@ -26,6 +26,9 @@
+ #include "md_p.h"
+ #include <ctype.h>
+ 
++#pragma GCC diagnostic push
++#pragma GCC diagnostic ignored "-Wformat-truncation"
++
+ void make_parts(char *dev, int cnt)
+ {
+ 	/* make 'cnt' partition devices for 'dev'
+@@ -99,6 +102,7 @@ void make_parts(char *dev, int cnt)
+ 	}
+ 	free(name);
+ }
++#pragma GCC diagnostic pop
+ 
+ /*
+  * We need a new md device to assemble/build/create an array.
+diff --git a/super-ddf.c b/super-ddf.c
+index 1707ad1..e08d289 100644
+--- a/super-ddf.c
++++ b/super-ddf.c
+@@ -2846,6 +2846,9 @@ static void _set_config_size(struct phys_disk_entry *pde, const struct dl *dl)
+ 		(unsigned long long)cfs, (unsigned long long)(dl->size-cfs));
+ }
+ 
++#pragma GCC diagnostic push
++#pragma GCC diagnostic ignored "-Wformat-overflow"
++
+ /* Add a device to a container, either while creating it or while
+  * expanding a pre-existing container
+  */
+@@ -2981,6 +2984,7 @@ static int add_to_super_ddf(struct supertype *st,
+ 
+ 	return 0;
+ }
++#pragma GCC diagnostic pop
+ 
+ static int remove_from_super_ddf(struct supertype *st, mdu_disk_info_t *dk)
+ {
+diff --git a/super-intel.c b/super-intel.c
+index 00a2925..44fbead 100644
+--- a/super-intel.c
++++ b/super-intel.c
+@@ -298,6 +298,11 @@ struct md_list {
+ };
+ 
+ #define pr_vrb(fmt, arg...) (void) (verbose && pr_err(fmt, ##arg))
++#pragma GCC diagnostic push
++# if __GNUC__ == 8
++# pragma GCC diagnostic ignored "-Wstringop-truncation"
++# endif
++#pragma GCC diagnostic ignored "-Wformat-truncation"
+ 
+ static __u8 migr_type(struct imsm_dev *dev)
+ {
+@@ -11618,3 +11623,4 @@ struct superswitch super_imsm = {
+ 	.get_bad_blocks   = imsm_get_badblocks,
+ #endif /* MDASSEMBLE */
+ };
++#pragma GCC diagnostic pop
+diff --git a/super1.c b/super1.c
+index 87a74cb..71c515f 100644
+--- a/super1.c
++++ b/super1.c
+@@ -1091,6 +1091,10 @@ static struct mdinfo *container_content1(struct supertype *st, char *subarray)
+ 	return info;
+ }
+ 
++#pragma GCC diagnostic push
++# if __GNUC__ == 8
++# pragma GCC diagnostic ignored "-Wstringop-truncation"
++#endif
+ static int update_super1(struct supertype *st, struct mdinfo *info,
+ 			 char *update,
+ 			 char *devname, int verbose,
+@@ -1473,6 +1477,7 @@ static int init_super1(struct supertype *st, mdu_array_info_t *info,
+ 
+ 	return 1;
+ }
++#pragma GCC diagnostic pop
+ 
+ struct devinfo {
+ 	int fd;
diff --git a/poky/meta/recipes-extended/mdadm/files/0001-use-memmove-instead-of-memcpy-on-overlapping-region.patch b/poky/meta/recipes-extended/mdadm/files/0001-use-memmove-instead-of-memcpy-on-overlapping-region.patch
new file mode 100644
index 0000000..44351b6
--- /dev/null
+++ b/poky/meta/recipes-extended/mdadm/files/0001-use-memmove-instead-of-memcpy-on-overlapping-region.patch
@@ -0,0 +1,31 @@
+From ab18f04cf89ef4e8521c81c50477e1363b2d333b Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 28 Apr 2018 09:46:12 -0700
+Subject: [PATCH] use memmove instead of memcpy on overlapping region
+
+Fixes
+super0.c:526:3: error: 'memcpy' accessing 3936 bytes at offsets 156 and 160 overlaps 3932 bytes at offset 160 [-Werror=restrict]
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ super0.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/super0.c b/super0.c
+index f5b4507..264b598 100644
+--- a/super0.c
++++ b/super0.c
+@@ -523,7 +523,7 @@ static int update_super0(struct supertype *st, struct mdinfo *info,
+ 		 * up 4 bytes before continuing
+ 		 */
+ 		__u32 *sb32 = (__u32*)sb;
+-		memcpy(sb32+MD_SB_GENERIC_CONSTANT_WORDS+7,
++		memmove(sb32+MD_SB_GENERIC_CONSTANT_WORDS+7,
+ 		       sb32+MD_SB_GENERIC_CONSTANT_WORDS+7+1,
+ 		       (MD_SB_WORDS - (MD_SB_GENERIC_CONSTANT_WORDS+7+1))*4);
+ 		if (verbose >= 0)
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-extended/mdadm/mdadm_4.0.bb b/poky/meta/recipes-extended/mdadm/mdadm_4.0.bb
index dc098f1..2c4d88a 100644
--- a/poky/meta/recipes-extended/mdadm/mdadm_4.0.bb
+++ b/poky/meta/recipes-extended/mdadm/mdadm_4.0.bb
@@ -22,6 +22,8 @@
            file://0004-mdadm-Forced-type-conversion-to-avoid-truncation.patch \
            file://0005-Add-a-comment-to-indicate-valid-fallthrough.patch \
            file://0001-Use-CC-to-check-for-implicit-fallthrough-warning-sup.patch \
+           file://0001-use-memmove-instead-of-memcpy-on-overlapping-region.patch \
+           file://0001-Disable-gcc8-warnings.patch \
            "
 SRC_URI[md5sum] = "2cb4feffea9167ba71b5f346a0c0a40d"
 SRC_URI[sha256sum] = "1d6ae7f24ced3a0fa7b5613b32f4a589bb4881e3946a5a2c3724056254ada3a9"
@@ -40,7 +42,7 @@
 
 do_compile() {
 	# Point to right sbindir
-	sed -i -e "s;BINDIR  = /sbin;BINDIR = $base_sbindir;" ${S}/Makefile
+	sed -i -e "s;BINDIR  = /sbin;BINDIR = $base_sbindir;" -e "s;UDEVDIR = /lib;UDEVDIR = $nonarch_base_libdir;" ${S}/Makefile
 	oe_runmake SYSROOT="${STAGING_DIR_TARGET}"
 }
 
diff --git a/poky/meta/recipes-extended/mingetty/mingetty_1.08.bb b/poky/meta/recipes-extended/mingetty/mingetty_1.08.bb
index 3c16228..491b892 100644
--- a/poky/meta/recipes-extended/mingetty/mingetty_1.08.bb
+++ b/poky/meta/recipes-extended/mingetty/mingetty_1.08.bb
@@ -16,6 +16,7 @@
                 CFLAGS='${CFLAGS} -D_GNU_SOURCE'"
 
 do_install(){
+    sed -i -e "s;SBINDIR=/sbin;SBINDIR=$base_sbindir;"  ${S}/Makefile
     install -d ${D}${mandir}/man8 ${D}/${base_sbindir}
     oe_runmake install DESTDIR=${D}
 }
diff --git a/poky/meta/recipes-extended/minicom/minicom_2.7.1.bb b/poky/meta/recipes-extended/minicom/minicom_2.7.1.bb
index be0b48d..1e6f131 100644
--- a/poky/meta/recipes-extended/minicom/minicom_2.7.1.bb
+++ b/poky/meta/recipes-extended/minicom/minicom_2.7.1.bb
@@ -16,8 +16,6 @@
 SRC_URI[md5sum] = "9021cb8c5445f6e6e74b2acc39962d62"
 SRC_URI[sha256sum] = "532f836b7a677eb0cb1dca8d70302b73729c3d30df26d58368d712e5cca041f1"
 
-UPSTREAM_CHECK_URI = "https://alioth.debian.org/frs/?group_id=30018"
-
 PACKAGECONFIG ??= ""
 PACKAGECONFIG[lockdev] = "--enable-lockdev,--disable-lockdev,lockdev"
 
diff --git a/poky/meta/recipes-extended/mktemp/files/disable-strip.patch b/poky/meta/recipes-extended/mktemp/files/disable-strip.patch
deleted file mode 100644
index e06869e..0000000
--- a/poky/meta/recipes-extended/mktemp/files/disable-strip.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-Upstream-Status: Inappropriate [configuration]
-
-diff --git a/Makefile.in b/Makefile.in
-index 37b3cc9..f1026f3 100644
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -95,7 +95,7 @@ install-dirs:
- 	    $(DESTDIR)$(mandir)/man1
- 
- install-binaries: $(PROG)
--	$(INSTALL) -m 0555 -s $(PROG) $(DESTDIR)$(bindir)/$(PROG)
-+	$(INSTALL) -m 0555 $(PROG) $(DESTDIR)$(bindir)/$(PROG)
- 
- install-man:
- 	$(INSTALL) -m 0444 $(srcdir)/mktemp.$(mantype) \
diff --git a/poky/meta/recipes-extended/mktemp/files/fix-parallel-make.patch b/poky/meta/recipes-extended/mktemp/files/fix-parallel-make.patch
deleted file mode 100644
index f3b6dcc..0000000
--- a/poky/meta/recipes-extended/mktemp/files/fix-parallel-make.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-This fixes the parallel make install failure
-
-Upstream-Status: Accepted
-http://www.gratisoft.us/bugzilla/show_bug.cgi?id=528
-
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
-
-Index: mktemp-1.7/Makefile.in
-===================================================================
---- mktemp-1.7.orig/Makefile.in
-+++ mktemp-1.7/Makefile.in
-@@ -94,10 +94,10 @@ install-dirs:
- 	$(SHELL) $(srcdir)/mkinstalldirs $(DESTDIR)$(bindir) \
- 	    $(DESTDIR)$(mandir)/man1
- 
--install-binaries: $(PROG)
-+install-binaries: install-dirs $(PROG)
- 	$(INSTALL) -m 0555 $(PROG) $(DESTDIR)$(bindir)/$(PROG)
- 
--install-man:
-+install-man: install-dirs
- 	$(INSTALL) -m 0444 $(srcdir)/mktemp.$(mantype) \
- 	    $(DESTDIR)$(mandir)/man1/mktemp.1
- 
diff --git a/poky/meta/recipes-extended/mktemp/mktemp_1.7.bb b/poky/meta/recipes-extended/mktemp/mktemp_1.7.bb
deleted file mode 100644
index e8ae5c6..0000000
--- a/poky/meta/recipes-extended/mktemp/mktemp_1.7.bb
+++ /dev/null
@@ -1,36 +0,0 @@
-SUMMARY = "Enables safe temporary file creation from shell scripts"
-HOMEPAGE = "http://www.mktemp.org/"
-BUGTRACKER = "http://www.mktemp.org/bugs"
-SECTION = "console/utils"
-LICENSE = "ISC"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=430680f6322a1eb87199b5e01a82c0d4"
-
-PR = "r3"
-
-SRC_URI = "ftp://ftp.mktemp.org/pub/mktemp/${BPN}-${PV}.tar.gz \
-        file://disable-strip.patch \
-        file://fix-parallel-make.patch \
-        "
-
-SRC_URI[md5sum] = "787bbed9fa2ee8e7645733c0e8e65172"
-SRC_URI[sha256sum] = "8e94b9e1edf866b2609545da65b627996ac5d158fda071e492bddb2f4a482675"
-
-inherit autotools update-alternatives
-
-EXTRA_OECONF = "--with-libc"
-
-do_install_append () {
-	if [ "${base_bindir}" != "${bindir}" ] ; then
-		install -d ${D}${base_bindir}
-		mv ${D}${bindir}/mktemp ${D}${base_bindir}/mktemp
-		rmdir ${D}${bindir}
-	fi
-}
-
-ALTERNATIVE_${PN} = "mktemp"
-ALTERNATIVE_LINK_NAME[mktemp] = "${base_bindir}/mktemp"
-ALTERNATIVE_PRIORITY = "60"
-
-ALTERNATIVE_${PN}-doc = "mktemp.1"
-ALTERNATIVE_PRIORITY_${PN}-doc = "300"
-ALTERNATIVE_LINK_NAME[mktemp.1] = "${mandir}/man1/mktemp.1"
diff --git a/poky/meta/recipes-extended/net-tools/net-tools_1.60-26.bb b/poky/meta/recipes-extended/net-tools/net-tools_1.60-26.bb
index 5657fd8..a4e3285 100644
--- a/poky/meta/recipes-extended/net-tools/net-tools_1.60-26.bb
+++ b/poky/meta/recipes-extended/net-tools/net-tools_1.60-26.bb
@@ -48,7 +48,16 @@
 # up all previously applied patches in the start
 nettools_do_patch() {
 	cd ${S}
-	quilt pop -a || true
+	# it's important that we only pop the existing patches when they've
+	# been applied, otherwise quilt will climb the directory tree
+	# and reverse out some completely different set of patches
+	if [ -d ${S}/patches ]; then
+		# whilst this is the default directory, doing it like this
+		# defeats the directory climbing that quilt will otherwise
+		# do; note the directory must exist to defeat this, hence
+		# the test inside which we operate
+		QUILT_PATCHES=${S}/patches quilt pop -a
+	fi
 	if [ -d ${S}/.pc-nettools ]; then
 		rm -rf ${S}/.pc
 		mv ${S}/.pc-nettools ${S}/.pc
diff --git a/poky/meta/recipes-extended/newt/libnewt-python_0.52.20.bb b/poky/meta/recipes-extended/newt/libnewt-python_0.52.20.bb
index 20369ef..433d184 100644
--- a/poky/meta/recipes-extended/newt/libnewt-python_0.52.20.bb
+++ b/poky/meta/recipes-extended/newt/libnewt-python_0.52.20.bb
@@ -25,4 +25,4 @@
 
 FILES_${PN} = "${PYTHON_SITEPACKAGES_DIR}/*"
 
-BBCLASSEXTEND = "native"
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/newt/libnewt_0.52.20.bb b/poky/meta/recipes-extended/newt/libnewt_0.52.20.bb
index 65ce70c..264ef3b 100644
--- a/poky/meta/recipes-extended/newt/libnewt_0.52.20.bb
+++ b/poky/meta/recipes-extended/newt/libnewt_0.52.20.bb
@@ -51,4 +51,4 @@
 
 FILES_whiptail = "${bindir}/whiptail"
 
-BBCLASSEXTEND = "native"
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/packagegroups/packagegroup-core-full-cmdline.bb b/poky/meta/recipes-extended/packagegroups/packagegroup-core-full-cmdline.bb
index 9002fbc..ffa8388 100644
--- a/poky/meta/recipes-extended/packagegroups/packagegroup-core-full-cmdline.bb
+++ b/poky/meta/recipes-extended/packagegroups/packagegroup-core-full-cmdline.bb
@@ -86,10 +86,8 @@
     mc-fish \
     mc-helpers \
     mc-helpers-perl \
-    mktemp \
     ncurses \
     net-tools \
-    popt \
     procps \
     psmisc \
     sed \
@@ -127,25 +125,17 @@
     "
 
 RDEPENDS_packagegroup-core-full-cmdline-multiuser = "\
+    bzip2 \
     cracklib \
     gzip \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libuser', '', d)} \
     shadow \
     sudo \
     "
 
 RDEPENDS_packagegroup-core-full-cmdline-sys-services = "\
     at \
-    bzip2 \
     cronie \
-    dbus \
-    elfutils \
-    gzip \
-    less \
     logrotate \
     nfs-utils \
-    pciutils \
     rpcbind \
-    tcp-wrappers \
-    tzdata \
     "
diff --git a/poky/meta/recipes-extended/packagegroups/packagegroup-core-lsb.bb b/poky/meta/recipes-extended/packagegroups/packagegroup-core-lsb.bb
index 53d100c..e8dc421 100644
--- a/poky/meta/recipes-extended/packagegroups/packagegroup-core-lsb.bb
+++ b/poky/meta/recipes-extended/packagegroups/packagegroup-core-lsb.bb
@@ -76,7 +76,7 @@
     screen \
     setserial \
     sysstat \
-    udev-extraconf \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '', 'udev-extraconf', d)} \
     unzip \
     watchdog \
     wget \
@@ -136,6 +136,7 @@
     bc \
     binutils \
     binutils-symlinks \
+    bzip2 \
     coreutils \
     cpio \
     cronie \
@@ -158,7 +159,6 @@
     make \
     man \
     man-pages \
-    mktemp \
     msmtp \
     patch \
     procps \
@@ -220,7 +220,7 @@
     liberation-fonts \
     gtk+ \
     atk \
-    libasound \
+    alsa-lib \
 "
 
 RDEPENDS_packagegroup-core-lsb-runtime-add = "\
diff --git a/poky/meta/recipes-extended/pam/libpam_1.3.0.bb b/poky/meta/recipes-extended/pam/libpam_1.3.0.bb
index 92ab72a..3aec2cd 100644
--- a/poky/meta/recipes-extended/pam/libpam_1.3.0.bb
+++ b/poky/meta/recipes-extended/pam/libpam_1.3.0.bb
@@ -32,7 +32,7 @@
                              file://include_paths_header.patch \
                            "
 
-DEPENDS = "bison-native flex flex-native cracklib libxml2-native"
+DEPENDS = "bison-native flex flex-native cracklib libxml2-native virtual/crypt"
 
 EXTRA_OECONF = "--with-db-uniquename=_pam \
                 --includedir=${includedir}/security \
diff --git a/poky/meta/recipes-extended/parted/parted_3.2.bb b/poky/meta/recipes-extended/parted/parted_3.2.bb
index ab30108..6189fd2 100644
--- a/poky/meta/recipes-extended/parted/parted_3.2.bb
+++ b/poky/meta/recipes-extended/parted/parted_3.2.bb
@@ -48,3 +48,9 @@
 }
 
 RDEPENDS_${PN}-ptest = "bash coreutils perl util-linux-losetup python3"
+
+inherit update-alternatives
+
+ALTERNATIVE_PRIORITY = "100"
+ALTERNATIVE_${PN} = "partprobe"
+ALTERNATIVE_LINK_NAME[partprobe] = "${sbindir}/partprobe"
diff --git a/poky/meta/recipes-extended/pbzip2/pbzip2/0001-pbzip2-Fix-invalid-suffix-on-literal-C-11-warning.patch b/poky/meta/recipes-extended/pbzip2/pbzip2/0001-pbzip2-Fix-invalid-suffix-on-literal-C-11-warning.patch
new file mode 100644
index 0000000..8fc377c
--- /dev/null
+++ b/poky/meta/recipes-extended/pbzip2/pbzip2/0001-pbzip2-Fix-invalid-suffix-on-literal-C-11-warning.patch
@@ -0,0 +1,73 @@
+From de4a948d356c9befb88c796168e97eb05b9a3385 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 23 Apr 2018 22:54:42 -0700
+Subject: [PATCH] pbzip2: Fix invalid suffix on literal C++11 warning
+
+Fixes -Wreserved-user-defined-literal] errors.
+Also reported in launchpad here https://bugs.launchpad.net/pbzip2/+bug/1746369
+
+Upstream-Status: Submitted [https://launchpadlibrarian.net/355230152/pbzip2.patch]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ pbzip2.cpp | 12 ++++++------
+ 1 file changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/pbzip2.cpp b/pbzip2.cpp
+index 66ca978..4287ea7 100644
+--- a/pbzip2.cpp
++++ b/pbzip2.cpp
+@@ -1220,7 +1220,7 @@ int producer_decompress(int hInfile, OFF_T fileSize, queue *fifo)
+ 			// give warning to user if block is larger than 250 million bytes
+ 			if (fileData->bufSize > 250000000)
+ 			{
+-				fprintf(stderr, "pbzip2:  *WARNING: Compressed block size is large [%"PRIuMAX" bytes].\n",
++				fprintf(stderr, "pbzip2:  *WARNING: Compressed block size is large [%" PRIuMAX " bytes].\n",
+ 						(uintmax_t) fileData->bufSize);
+ 				fprintf(stderr, "          If program aborts, use regular BZIP2 to decompress.\n");
+ 			}
+@@ -1829,7 +1829,7 @@ void *fileWriter(void *outname)
+ 	
+ 	if (QuietMode != 1)
+ 	{
+-		fprintf(stderr, "    Output Size: %"PRIuMAX" bytes\n", (uintmax_t)CompressedSize);
++		fprintf(stderr, "    Output Size: %" PRIuMAX " bytes\n", (uintmax_t)CompressedSize);
+ 	}
+ 
+ 	#ifdef PBZIP_DEBUG
+@@ -2072,7 +2072,7 @@ int directcompress(int hInfile, OFF_T fileSize, int blockSize, const char *OutFi
+ 		close(hOutfile);
+ 	if (QuietMode != 1)
+ 	{
+-		fprintf(stderr, "    Output Size: %"PRIuMAX" bytes\n", (uintmax_t)CompressedSize);
++		fprintf(stderr, "    Output Size: %" PRIuMAX " bytes\n", (uintmax_t)CompressedSize);
+ 	}
+ 
+ 	syncSetProducerDone(1); // Not really needed for direct version
+@@ -2794,7 +2794,7 @@ void outputBufferInit(size_t size)
+ 	// unlikely to get here since more likely exception will be thrown
+ 	if (OutputBuffer.size() != size)
+ 	{
+-		fprintf(stderr, "pbzip2: *ERROR: Could not initialize (OutputBuffer); size=%"PRIuMAX"!  Aborting...\n", (uintmax_t)size);
++		fprintf(stderr, "pbzip2: *ERROR: Could not initialize (OutputBuffer); size=%" PRIuMAX "!  Aborting...\n", (uintmax_t)size);
+ 		safe_mutex_unlock(OutMutex);
+ 		exit(1);
+ 	}
+@@ -4102,7 +4102,7 @@ int main(int argc, char* argv[])
+ 			if (decompress == 1)
+ 				fprintf(stderr, " BWT Block Size: %c00k\n", BWTblockSizeChar);
+ 			if (hasInFile)
+-				fprintf(stderr, "     Input Size: %"PRIuMAX" bytes\n", (uintmax_t)InFileSize);
++				fprintf(stderr, "     Input Size: %" PRIuMAX " bytes\n", (uintmax_t)InFileSize);
+ 		}
+ 
+ 		if (decompress == 1)
+@@ -4224,7 +4224,7 @@ int main(int argc, char* argv[])
+ 			{
+ 				NumBufferedBlocksMax = numCPU;
+ 				if (QuietMode != 1)
+-					fprintf(stderr, "*Warning* Max memory limit increased to %"PRIuMAX" MB to support %d CPUs\n", (uintmax_t)((NumBufferedBlocksMax + (numCPU * 2)) * blockSize)/1000000, numCPU);
++					fprintf(stderr, "*Warning* Max memory limit increased to %" PRIuMAX " MB to support %d CPUs\n", (uintmax_t)((NumBufferedBlocksMax + (numCPU * 2)) * blockSize)/1000000, numCPU);
+ 			}
+ 			else
+ 			{
diff --git a/poky/meta/recipes-extended/pbzip2/pbzip2_1.1.13.bb b/poky/meta/recipes-extended/pbzip2/pbzip2_1.1.13.bb
index 06d37ad..7b1b0a1 100644
--- a/poky/meta/recipes-extended/pbzip2/pbzip2_1.1.13.bb
+++ b/poky/meta/recipes-extended/pbzip2/pbzip2_1.1.13.bb
@@ -11,12 +11,15 @@
 DEPENDS = "bzip2"
 DEPENDS_append_class-native = " bzip2-replacement-native"
 
-SRC_URI = "https://launchpad.net/${BPN}/1.1/${PV}/+download/${BP}.tar.gz"
+SRC_URI = "https://launchpad.net/${BPN}/1.1/${PV}/+download/${BP}.tar.gz \
+           file://0001-pbzip2-Fix-invalid-suffix-on-literal-C-11-warning.patch \
+           "
 
 SRC_URI[md5sum] = "4cb87da2dba05540afce162f34b3a9a6"
 SRC_URI[sha256sum] = "8fd13eaaa266f7ee91f85c1ea97c86d9c9cc985969db9059cdebcb1e1b7bdbe6"
 
-UPSTREAM_CHECK_URI = "http://compression.ca/pbzip2/"
+UPSTREAM_CHECK_URI = "https://launchpad.net/pbzip2/+milestones"
+UPSTREAM_CHECK_REGEX = "pbzip2 (?P<pver>\d+(\.\d+)+)"
 
 EXTRA_OEMAKE = "CXX='${CXX} ${CXXFLAGS}' LDFLAGS='${LDFLAGS}'"
 
diff --git a/poky/meta/recipes-extended/perl/libxml-sax-perl_0.99.bb b/poky/meta/recipes-extended/perl/libxml-sax-perl_0.99.bb
deleted file mode 100644
index cdcbebf..0000000
--- a/poky/meta/recipes-extended/perl/libxml-sax-perl_0.99.bb
+++ /dev/null
@@ -1,33 +0,0 @@
-SUMMARY = "Perl module for using and building Perl SAX2 XML processors"
-HOMEPAGE = "http://search.cpan.org/dist/XML-SAX/"
-DESCRIPTION = "XML::SAX consists of several framework classes for using and \
-building Perl SAX2 XML parsers, filters, and drivers.  It is designed \ 
-around the need to be able to "plug in" different SAX parsers to an \
-application without requiring programmer intervention.  Those of you \
-familiar with the DBI will be right at home.  Some of the designs \
-come from the Java JAXP specification (SAX part), only without the \
-javaness."
-
-SECTION = "libs"
-LICENSE = "Artistic-1.0 | GPL-1.0+"
-DEPENDS += "libxml-namespacesupport-perl-native"
-RDEPENDS_${PN} += "libxml-namespacesupport-perl libxml-sax-base-perl perl-module-file-temp"
-PR = "r2"
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=65c4cd8f39c24c7135ed70dacbcb09e3"
-
-SRC_URI = "http://search.cpan.org/CPAN/authors/id/G/GR/GRANTM/XML-SAX-${PV}.tar.gz"
-
-SRC_URI[md5sum] = "290f5375ae87fdebfdb5bc3854019f24"
-SRC_URI[sha256sum] = "32b04b8e36b6cc4cfc486de2d859d87af5386dd930f2383c49347050d6f5ad84"
-
-S = "${WORKDIR}/XML-SAX-${PV}"
-
-inherit cpan ptest-perl
-
-do_install_ptest() {
-	cp -r ${B}/testfiles ${D}${PTEST_PATH}
-	chown -R root:root ${D}${PTEST_PATH}/testfiles
-}
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-extended/perl/libxml-sax-perl_1.00.bb b/poky/meta/recipes-extended/perl/libxml-sax-perl_1.00.bb
new file mode 100644
index 0000000..141830e
--- /dev/null
+++ b/poky/meta/recipes-extended/perl/libxml-sax-perl_1.00.bb
@@ -0,0 +1,32 @@
+SUMMARY = "Perl module for using and building Perl SAX2 XML processors"
+HOMEPAGE = "http://search.cpan.org/dist/XML-SAX/"
+DESCRIPTION = "XML::SAX consists of several framework classes for using and \
+building Perl SAX2 XML parsers, filters, and drivers.  It is designed \ 
+around the need to be able to "plug in" different SAX parsers to an \
+application without requiring programmer intervention.  Those of you \
+familiar with the DBI will be right at home.  Some of the designs \
+come from the Java JAXP specification (SAX part), only without the \
+javaness."
+
+SECTION = "libs"
+LICENSE = "Artistic-1.0 | GPL-1.0+"
+DEPENDS += "libxml-namespacesupport-perl-native"
+RDEPENDS_${PN} += "libxml-namespacesupport-perl libxml-sax-base-perl perl-module-file-temp"
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=65c4cd8f39c24c7135ed70dacbcb09e3"
+
+SRC_URI = "http://search.cpan.org/CPAN/authors/id/G/GR/GRANTM/XML-SAX-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "861a454f7bf269990ed2c1c125f4db48"
+SRC_URI[sha256sum] = "45ea6564ef8692155d57b2de0862b6442d3c7e29f4a9bc9ede5d7ecdc74c2ae3"
+
+S = "${WORKDIR}/XML-SAX-${PV}"
+
+inherit cpan ptest-perl
+
+do_install_ptest() {
+	cp -r ${B}/testfiles ${D}${PTEST_PATH}
+	chown -R root:root ${D}${PTEST_PATH}/testfiles
+}
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-extended/pixz/pixz/0001-configure-Detect-headers-before-using-them.patch b/poky/meta/recipes-extended/pixz/pixz/0001-configure-Detect-headers-before-using-them.patch
deleted file mode 100644
index 12bae28..0000000
--- a/poky/meta/recipes-extended/pixz/pixz/0001-configure-Detect-headers-before-using-them.patch
+++ /dev/null
@@ -1,51 +0,0 @@
-From c84480be8df6966c538d1fb67ccae2f42cc46421 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 22 Mar 2016 07:36:54 +0000
-Subject: [PATCH 1/2] configure: Detect headers before using them
-
-Current logic does not work when system does not have
-sys/endian.h, since it tried to reuse the cached results
-from first try of detecting htole64 in sys/endian.h which is
-'no' and hence the second try to look into endian.h also
-comes out negative.
-
-So we check for header and then run the test for symbols
-and these symbols are not standard and we need to define _GNU_SOURCE
-for it to work, this issue is exposed by systems using musl e.g.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Submitted
-
- configure.ac | 13 +++++++++----
- 1 file changed, 9 insertions(+), 4 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index 4cb56bc..5e23c50 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -69,12 +69,17 @@ AC_FUNC_MALLOC
- AC_FUNC_REALLOC
- AC_FUNC_STRTOD
- AC_CHECK_FUNCS([memchr memmove memset strerror strtol])
--AC_CHECK_DECLS([htole64, le64toh],
--               [],
-+AC_CHECK_HEADER([sys/endian.h],
-                [
--                 AC_CHECK_DECLS([htole64, le64toh], [], [], [#include <endian.h>])
-+                 AC_CHECK_DECLS([htole64, le64toh], [], [], [#define _GNU_SOURCE 1 #include <sys/endian.h>])
-                ],
--               [#include <sys/endian.h>])
-+               [], [])
-+
-+AC_CHECK_HEADER([endian.h],
-+               [
-+                 AC_CHECK_DECLS([htole64, le64toh], [], [], [#define _GNU_SOURCE 1 #include <endian.h>])
-+               ],
-+               [], [])
- 
- AC_CONFIG_FILES([Makefile
-                  src/Makefile
--- 
-1.8.3.1
-
diff --git a/poky/meta/recipes-extended/pixz/pixz/0002-endian-Use-macro-bswap_64-instead-of-__bswap_64.patch b/poky/meta/recipes-extended/pixz/pixz/0002-endian-Use-macro-bswap_64-instead-of-__bswap_64.patch
deleted file mode 100644
index 6b61598..0000000
--- a/poky/meta/recipes-extended/pixz/pixz/0002-endian-Use-macro-bswap_64-instead-of-__bswap_64.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From 5f3a535987bae4c3e3d9e9079c7526e399f7aecd Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Tue, 22 Mar 2016 07:42:39 +0000
-Subject: [PATCH 2/2] endian: Use macro bswap_64 instead of __bswap_64
-
-byteswap.h defines then as public APIs on all libc
-on linux including musl
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Submitted
- src/endian.c | 5 +++--
- 1 file changed, 3 insertions(+), 2 deletions(-)
-
-diff --git a/src/endian.c b/src/endian.c
-index b7724f3..51aea58 100644
---- a/src/endian.c
-+++ b/src/endian.c
-@@ -15,6 +15,7 @@ void xle64enc(uint8_t *d, uint64_t n) {
- #include <stdint.h>
- #ifdef __linux__
- 	#include <endian.h>
-+	#include <byteswap.h>
- #else
- 	#include <sys/endian.h>
- #endif
-@@ -23,7 +24,7 @@ void xle64enc(uint8_t *d, uint64_t n) {
- # if __BYTE_ORDER == __LITTLE_ENDIAN
- #  define htole64(x) (x)
- # else
--#  define htole64(x) __bswap_64 (x)
-+#  define htole64(x) bswap_64 (x)
- # endif
- #endif
- 
-@@ -31,7 +32,7 @@ void xle64enc(uint8_t *d, uint64_t n) {
- # if __BYTE_ORDER == __LITTLE_ENDIAN
- #  define le64toh(x) (x)
- # else
--#  define le64toh(x) __bswap_64 (x)
-+#  define le64toh(x) bswap_64 (x)
- # endif
- #endif
- 
--- 
-1.8.3.1
-
diff --git a/poky/meta/recipes-extended/pixz/pixz/936d8068ae19d95260d3058f41dd6cf718101cd6.patch b/poky/meta/recipes-extended/pixz/pixz/936d8068ae19d95260d3058f41dd6cf718101cd6.patch
deleted file mode 100644
index e3489db..0000000
--- a/poky/meta/recipes-extended/pixz/pixz/936d8068ae19d95260d3058f41dd6cf718101cd6.patch
+++ /dev/null
@@ -1,68 +0,0 @@
-From 936d8068ae19d95260d3058f41dd6cf718101cd6 Mon Sep 17 00:00:00 2001
-From: Christian Krause <kizkizzbangbang@googlemail.com>
-Date: Sat, 26 Dec 2015 14:36:17 +0100
-Subject: [PATCH] option to not build man page
-
-fixes #56
----
- configure.ac    | 23 +++++++++++++++++++----
- src/Makefile.am |  2 ++
- 2 files changed, 21 insertions(+), 4 deletions(-)
-
-Upstream-Status: Backport
-RP 2016/01/22
-
-diff --git a/configure.ac b/configure.ac
-index b437e56..4cb56bc 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -20,13 +20,28 @@ AC_CHECK_FILE(
-   [src/pixz.1],
-   [],
-   [
--    AC_CHECK_PROG(A2X, a2x, a2x, [])
--    if test "x$A2X" = x ; then
--      AC_MSG_ERROR([AsciiDoc not found, not able to generate the man page.])
--    fi
-+    AC_ARG_WITH(
-+      [manpage],
-+      [  --without-manpage       don't build man page],
-+      [case ${withval} in
-+        yes) manpage=true ;;
-+        no)  manpage=false ;;
-+        *)   AC_MSG_ERROR([bad value ${withval} for --with-manpage]) ;;
-+      esac],
-+      [manpage=true]
-+    )
-   ]
- )
- 
-+AM_CONDITIONAL([MANPAGE], [test x$manpage = xtrue])
-+
-+if test x$manpage = xtrue ; then
-+  AC_CHECK_PROG(A2X, a2x, a2x, [])
-+  if test "x$A2X" = x ; then
-+    AC_MSG_ERROR([AsciiDoc not found, not able to generate the man page.])
-+  fi
-+fi
-+
- # Checks for libraries.
- AC_CHECK_LIB([m], [ceil])
- AX_PTHREAD
-diff --git a/src/Makefile.am b/src/Makefile.am
-index 600ec90..b98f450 100644
---- a/src/Makefile.am
-+++ b/src/Makefile.am
-@@ -15,6 +15,7 @@ pixz_SOURCES = \
- 	read.c \
- 	write.c
- 
-+if MANPAGE
- # TODO remove when possible: This is a hack because a2x is not able to output the man pages to a
- # specific directory, only to where the source is.
- pixz.1: pixz.1.asciidoc
-@@ -26,3 +27,4 @@ man_MANS = pixz.1
- CLEANFILES = pixz.1
- 
- EXTRA_DIST = $(man_MANS) pixz.1.asciidoc
-+endif
diff --git a/poky/meta/recipes-extended/pixz/pixz_1.0.6.bb b/poky/meta/recipes-extended/pixz/pixz_1.0.6.bb
deleted file mode 100644
index 3032586..0000000
--- a/poky/meta/recipes-extended/pixz/pixz_1.0.6.bb
+++ /dev/null
@@ -1,25 +0,0 @@
-SUMMARY = "Parallel, indexed xz compressor"
-
-DEPENDS = "xz libarchive"
-
-SRC_URI = "https://github.com/vasi/pixz/releases/download/v${PV}/${BPN}-${PV}.tar.xz"
-SRC_URI[md5sum] = "f6dc5909c9a31b192f69aa397ae8df48"
-SRC_URI[sha256sum] = "02c50746b134fa1b1aae41fcc314d7c6f1919b3d48bcdea01bf11769f83f72e8"
-
-LICENSE = "BSD-2-Clause"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=5cf6d164086105f1512ccb81bfff1926"
-
-SRC_URI += "file://936d8068ae19d95260d3058f41dd6cf718101cd6.patch \
-            file://0001-configure-Detect-headers-before-using-them.patch \
-            file://0002-endian-Use-macro-bswap_64-instead-of-__bswap_64.patch \
-"
-UPSTREAM_CHECK_URI = "https://github.com/vasi/pixz/releases"
-
-PACKAGECONFIG[manpages] = "--with-manpage, --without-manpage, asciidoc-native"
-
-CFLAGS_append_libc-musl = " -D_GNU_SOURCE"
-CACHED_CONFIGUREVARS += "ac_cv_file_src_pixz_1=no"
-
-inherit autotools pkgconfig manpages
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-extended/procps/procps/0001-Fix-out-of-tree-builds.patch b/poky/meta/recipes-extended/procps/procps/0001-Fix-out-of-tree-builds.patch
new file mode 100644
index 0000000..e548194
--- /dev/null
+++ b/poky/meta/recipes-extended/procps/procps/0001-Fix-out-of-tree-builds.patch
@@ -0,0 +1,24 @@
+From 0825db94fc91fa2150c0e649e92cc8dcc44f4b38 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Wed, 4 Apr 2018 14:09:45 +0300
+Subject: [PATCH] Fix out of tree builds
+
+Upstream-Status: Pending
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ include/nls.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/include/nls.h b/include/nls.h
+index 1166b7b..f5abe05 100644
+--- a/include/nls.h
++++ b/include/nls.h
+@@ -6,7 +6,7 @@
+ #define PROCPS_NG_NLS_H
+ 
+ /* programs issuing textdomain() need PACKAGE string */
+-#include "../config.h"
++#include "config.h"
+ 
+ /* programs issuing bindtextdomain() also need LOCALEDIR string */
+ #ifndef LOCALEDIR
diff --git a/poky/meta/recipes-extended/procps/procps/CVE-2018-1124.patch b/poky/meta/recipes-extended/procps/procps/CVE-2018-1124.patch
deleted file mode 100644
index bc78faf..0000000
--- a/poky/meta/recipes-extended/procps/procps/CVE-2018-1124.patch
+++ /dev/null
@@ -1,176 +0,0 @@
-From bdd058a0e676d2f013027fcfb2b344c313112a50 Mon Sep 17 00:00:00 2001
-From: Qualys Security Advisory <qsa@qualys.com>
-Date: Thu, 1 Jan 1970 00:00:00 +0000
-Subject: [PATCH 074/126] proc/readproc.c: Fix bugs and overflows in
- file2strvec().
-
-Note: this is by far the most important and complex patch of the whole
-series, please review it carefully; thank you very much!
-
-For this patch, we decided to keep the original function's design and
-skeleton, to avoid regressions and behavior changes, while fixing the
-various bugs and overflows. And like the "Harden file2str()" patch, this
-patch does not fail when about to overflow, but truncates instead: there
-is information available about this process, so return it to the caller;
-also, we used INT_MAX as a limit, but a lower limit could be used.
-
-The easy changes:
-
-- Replace sprintf() with snprintf() (and check for truncation).
-
-- Replace "if (n == 0 && rbuf == 0)" with "if (n <= 0 && tot <= 0)" and
-  do break instead of return: it simplifies the code (only one place to
-  handle errors), and also guarantees that in the while loop either n or
-  tot is > 0 (or both), even if n is reset to 0 when about to overflow.
-
-- Remove the "if (n < 0)" block in the while loop: it is (and was) dead
-  code, since we enter the while loop only if n >= 0.
-
-- Rewrite the missing-null-terminator detection: in the original
-  function, if the size of the file is a multiple of 2047, a null-
-  terminator is appended even if the file is already null-terminated.
-
-- Replace "if (n <= 0 && !end_of_file)" with "if (n < 0 || tot <= 0)":
-  originally, it was equivalent to "if (n < 0)", but we added "tot <= 0"
-  to handle the first break of the while loop, and to guarantee that in
-  the rest of the function tot is > 0.
-
-- Double-force ("belt and suspenders") the null-termination of rbuf:
-  this is (and was) essential to the correctness of the function.
-
-- Replace the final "while" loop with a "for" loop that behaves just
-  like the preceding "for" loop: in the original function, this would
-  lead to unexpected results (for example, if rbuf is |\0|A|\0|, this
-  would return the array {"",NULL} but should return {"","A",NULL}; and
-  if rbuf is |A|\0|B| (should never happen because rbuf should be null-
-  terminated), this would make room for two pointers in ret, but would
-  write three pointers to ret).
-
-The hard changes:
-
-- Prevent the integer overflow of tot in the while loop, but unlike
-  file2str(), file2strvec() cannot let tot grow until it almost reaches
-  INT_MAX, because it needs more space for the pointers: this is why we
-  introduced ARG_LEN, which also guarantees that we can add "align" and
-  a few sizeof(char*)s to tot without overflowing.
-
-- Prevent the integer overflow of "tot + c + align": when INT_MAX is
-  (almost) reached, we write the maximal safe amount of pointers to ret
-  (ARG_LEN guarantees that there is always space for *ret = rbuf and the
-  NULL terminator).
-[carnil: backport for 3.3.9: Add include for limits.h and use of MAX_INT]
-
-CVE: CVE-2018-1124
-Upstream-Status: Backport [https://gitlab.com/procps-ng/procps/commit/36c350f07c75aabf747fb833f52a234ae5781b20]
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- proc/readproc.c | 53 ++++++++++++++++++++++++++++++++---------------------
- 1 file changed, 32 insertions(+), 21 deletions(-)
-
-diff -Naurp procps-ng-3.3.12_org/proc/readproc.c procps-ng-3.3.12/proc/readproc.c
---- procps-ng-3.3.12_org/proc/readproc.c	2016-07-09 14:49:25.825306872 -0700
-+++ procps-ng-3.3.12/proc/readproc.c	2018-07-24 00:46:49.366202531 -0700
-@@ -37,6 +37,7 @@
- #include <dirent.h>
- #include <sys/types.h>
- #include <sys/stat.h>
-+#include <limits.h>
- #ifdef WITH_SYSTEMD
- #include <systemd/sd-login.h>
- #endif
---- a/proc/readproc.c
-+++ b/proc/readproc.c
-@@ -600,11 +601,12 @@ static int file2str(const char *director
- 
- static char** file2strvec(const char* directory, const char* what) {
-     char buf[2048];	/* read buf bytes at a time */
--    char *p, *rbuf = 0, *endbuf, **q, **ret;
-+    char *p, *rbuf = 0, *endbuf, **q, **ret, *strp;
-     int fd, tot = 0, n, c, end_of_file = 0;
-     int align;
- 
--    sprintf(buf, "%s/%s", directory, what);
-+    const int len = snprintf(buf, sizeof buf, "%s/%s", directory, what);
-+    if(len <= 0 || (size_t)len >= sizeof buf) return NULL;
-     fd = open(buf, O_RDONLY, 0);
-     if(fd==-1) return NULL;
- 
-@@ -612,18 +614,23 @@ static char** file2strvec(const char* di
-     while ((n = read(fd, buf, sizeof buf - 1)) >= 0) {
- 	if (n < (int)(sizeof buf - 1))
- 	    end_of_file = 1;
--	if (n == 0 && rbuf == 0) {
--	    close(fd);
--	    return NULL;	/* process died between our open and read */
-+	if (n <= 0 && tot <= 0) { /* nothing read now, nothing read before */
-+	    break;		/* process died between our open and read */
- 	}
--	if (n < 0) {
--	    if (rbuf)
--		free(rbuf);
--	    close(fd);
--	    return NULL;	/* read error */
-+	/* ARG_LEN is our guesstimated median length of a command-line argument
-+	   or environment variable (the minimum is 1, the maximum is 131072) */
-+	#define ARG_LEN 64
-+	if (tot >= INT_MAX / (ARG_LEN + (int)sizeof(char*)) * ARG_LEN - n) {
-+	    end_of_file = 1; /* integer overflow: null-terminate and break */
-+	    n = 0; /* but tot > 0 */
- 	}
--	if (end_of_file && (n == 0 || buf[n-1]))/* last read char not null */
-+	#undef ARG_LEN
-+	if (end_of_file &&
-+	    ((n > 0 && buf[n-1] != '\0') ||	/* last read char not null */
-+	     (n <= 0 && rbuf[tot-1] != '\0')))	/* last read char not null */
- 	    buf[n++] = '\0';			/* so append null-terminator */
-+
-+	if (n <= 0) break; /* unneeded (end_of_file = 1) but avoid realloc */
- 	rbuf = xrealloc(rbuf, tot + n);		/* allocate more memory */
- 	memcpy(rbuf + tot, buf, n);		/* copy buffer into it */
- 	tot += n;				/* increment total byte ctr */
-@@ -631,29 +638,34 @@ static char** file2strvec(const char* di
- 	    break;
-     }
-     close(fd);
--    if (n <= 0 && !end_of_file) {
-+    if (n < 0 || tot <= 0) {	/* error, or nothing read */
- 	if (rbuf) free(rbuf);
- 	return NULL;		/* read error */
-     }
-+    rbuf[tot-1] = '\0'; /* belt and suspenders (the while loop did it, too) */
-     endbuf = rbuf + tot;			/* count space for pointers */
-     align = (sizeof(char*)-1) - ((tot + sizeof(char*)-1) & (sizeof(char*)-1));
--    for (c = 0, p = rbuf; p < endbuf; p++) {
--	if (!*p || *p == '\n')
-+    c = sizeof(char*);				/* one extra for NULL term */
-+    for (p = rbuf; p < endbuf; p++) {
-+	if (!*p || *p == '\n') {
-+	    if (c >= INT_MAX - (tot + (int)sizeof(char*) + align)) break;
- 	    c += sizeof(char*);
-+	}
- 	if (*p == '\n')
- 	    *p = 0;
-     }
--    c += sizeof(char*);				/* one extra for NULL term */
- 
-     rbuf = xrealloc(rbuf, tot + c + align);	/* make room for ptrs AT END */
-     endbuf = rbuf + tot;			/* addr just past data buf */
-     q = ret = (char**) (endbuf+align);		/* ==> free(*ret) to dealloc */
--    *q++ = p = rbuf;				/* point ptrs to the strings */
--    endbuf--;					/* do not traverse final NUL */
--    while (++p < endbuf)
--    	if (!*p)				/* NUL char implies that */
--	    *q++ = p+1;				/* next string -> next char */
--
-+    for (strp = p = rbuf; p < endbuf; p++) {
-+	if (!*p) {				/* NUL char implies that */
-+	    if (c < 2 * (int)sizeof(char*)) break;
-+	    c -= sizeof(char*);
-+	    *q++ = strp;			/* point ptrs to the strings */
-+	    strp = p+1;				/* next string -> next char */
-+	}
-+    }
-     *q = 0;					/* null ptr list terminator */
-     return ret;
- }
diff --git a/poky/meta/recipes-extended/procps/procps_3.3.12.bb b/poky/meta/recipes-extended/procps/procps_3.3.12.bb
deleted file mode 100644
index 6e15b0a..0000000
--- a/poky/meta/recipes-extended/procps/procps_3.3.12.bb
+++ /dev/null
@@ -1,66 +0,0 @@
-SUMMARY = "System and process monitoring utilities"
-DESCRIPTION = "Procps contains a set of system utilities that provide system information about processes using \
-the /proc filesystem. The package includes the programs ps, top, vmstat, w, kill, and skill."
-HOMEPAGE = "https://gitlab.com/procps-ng/procps"
-SECTION = "base"
-LICENSE = "GPLv2+ & LGPLv2+"
-LIC_FILES_CHKSUM="file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-                  file://COPYING.LIB;md5=4cf66a4984120007c9881cc871cf49db \
-                 "
-
-DEPENDS = "ncurses"
-
-inherit autotools gettext pkgconfig update-alternatives
-
-SRC_URI = "http://downloads.sourceforge.net/project/procps-ng/Production/procps-ng-${PV}.tar.xz \
-           file://sysctl.conf \
-           file://CVE-2018-1124.patch \
-          "
-
-SRC_URI[md5sum] = "957e42e8b193490b2111252e4a2b443c"
-SRC_URI[sha256sum] = "6ed65ab86318f37904e8f9014415a098bec5bc53653e5d9ab404f95ca5e1a7d4"
-
-S = "${WORKDIR}/procps-ng-${PV}"
-
-EXTRA_OECONF = "--enable-skill --disable-modern-top"
-
-do_install_append () {
-	install -d ${D}${base_bindir}
-	[ "${bindir}" != "${base_bindir}" ] && for i in ${base_bindir_progs}; do mv ${D}${bindir}/$i ${D}${base_bindir}/$i; done
-	install -d ${D}${base_sbindir}
-	[ "${sbindir}" != "${base_sbindir}" ] && for i in ${base_sbindir_progs}; do mv ${D}${sbindir}/$i ${D}${base_sbindir}/$i; done
-        if [ "${base_sbindir}" != "${sbindir}" ]; then
-                rmdir ${D}${sbindir}
-        fi
-
-        install -d ${D}${sysconfdir}
-        install -m 0644 ${WORKDIR}/sysctl.conf ${D}${sysconfdir}/sysctl.conf
-        if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
-                install -d ${D}${sysconfdir}/sysctl.d
-                ln -sf ../sysctl.conf ${D}${sysconfdir}/sysctl.d/99-sysctl.conf
-        fi
-}
-
-CONFFILES_${PN} = "${sysconfdir}/sysctl.conf"
-
-bindir_progs = "free pkill pmap pgrep pwdx skill snice top uptime w"
-base_bindir_progs += "kill pidof ps watch"
-base_sbindir_progs += "sysctl"
-
-ALTERNATIVE_PRIORITY = "200"
-ALTERNATIVE_PRIORITY[pidof] = "150"
-
-ALTERNATIVE_${PN} = "${bindir_progs} ${base_bindir_progs} ${base_sbindir_progs}"
-
-ALTERNATIVE_${PN}-doc = "kill.1 uptime.1"
-ALTERNATIVE_LINK_NAME[kill.1] = "${mandir}/man1/kill.1"
-ALTERNATIVE_LINK_NAME[uptime.1] = "${mandir}/man1/uptime.1"
-
-python __anonymous() {
-    for prog in d.getVar('base_bindir_progs').split():
-        d.setVarFlag('ALTERNATIVE_LINK_NAME', prog, '%s/%s' % (d.getVar('base_bindir'), prog))
-
-    for prog in d.getVar('base_sbindir_progs').split():
-        d.setVarFlag('ALTERNATIVE_LINK_NAME', prog, '%s/%s' % (d.getVar('base_sbindir'), prog))
-}
-
diff --git a/poky/meta/recipes-extended/procps/procps_3.3.15.bb b/poky/meta/recipes-extended/procps/procps_3.3.15.bb
new file mode 100644
index 0000000..9756db0
--- /dev/null
+++ b/poky/meta/recipes-extended/procps/procps_3.3.15.bb
@@ -0,0 +1,66 @@
+SUMMARY = "System and process monitoring utilities"
+DESCRIPTION = "Procps contains a set of system utilities that provide system information about processes using \
+the /proc filesystem. The package includes the programs ps, top, vmstat, w, kill, and skill."
+HOMEPAGE = "https://gitlab.com/procps-ng/procps"
+SECTION = "base"
+LICENSE = "GPLv2+ & LGPLv2+"
+LIC_FILES_CHKSUM="file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                  file://COPYING.LIB;md5=4cf66a4984120007c9881cc871cf49db \
+                 "
+
+DEPENDS = "ncurses"
+
+inherit autotools gettext pkgconfig update-alternatives
+
+SRC_URI = "http://downloads.sourceforge.net/project/procps-ng/Production/procps-ng-${PV}.tar.xz \
+           file://sysctl.conf \
+           file://0001-Fix-out-of-tree-builds.patch \
+           "
+
+SRC_URI[md5sum] = "2b0717a7cb474b3d6dfdeedfbad2eccc"
+SRC_URI[sha256sum] = "10bd744ffcb3de2d591d2f6acf1a54a7ba070fdcc432a855931a5057149f0465"
+
+S = "${WORKDIR}/procps-ng-${PV}"
+
+EXTRA_OECONF = "--enable-skill --disable-modern-top"
+
+do_install_append () {
+	install -d ${D}${base_bindir}
+	[ "${bindir}" != "${base_bindir}" ] && for i in ${base_bindir_progs}; do mv ${D}${bindir}/$i ${D}${base_bindir}/$i; done
+	install -d ${D}${base_sbindir}
+	[ "${sbindir}" != "${base_sbindir}" ] && for i in ${base_sbindir_progs}; do mv ${D}${sbindir}/$i ${D}${base_sbindir}/$i; done
+        if [ "${base_sbindir}" != "${sbindir}" ]; then
+                rmdir ${D}${sbindir}
+        fi
+
+        install -d ${D}${sysconfdir}
+        install -m 0644 ${WORKDIR}/sysctl.conf ${D}${sysconfdir}/sysctl.conf
+        if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
+                install -d ${D}${sysconfdir}/sysctl.d
+                ln -sf ../sysctl.conf ${D}${sysconfdir}/sysctl.d/99-sysctl.conf
+        fi
+}
+
+CONFFILES_${PN} = "${sysconfdir}/sysctl.conf"
+
+bindir_progs = "free pkill pmap pgrep pwdx skill snice top uptime w"
+base_bindir_progs += "kill pidof ps watch"
+base_sbindir_progs += "sysctl"
+
+ALTERNATIVE_PRIORITY = "200"
+ALTERNATIVE_PRIORITY[pidof] = "150"
+
+ALTERNATIVE_${PN} = "${bindir_progs} ${base_bindir_progs} ${base_sbindir_progs}"
+
+ALTERNATIVE_${PN}-doc = "kill.1 uptime.1"
+ALTERNATIVE_LINK_NAME[kill.1] = "${mandir}/man1/kill.1"
+ALTERNATIVE_LINK_NAME[uptime.1] = "${mandir}/man1/uptime.1"
+
+python __anonymous() {
+    for prog in d.getVar('base_bindir_progs').split():
+        d.setVarFlag('ALTERNATIVE_LINK_NAME', prog, '%s/%s' % (d.getVar('base_bindir'), prog))
+
+    for prog in d.getVar('base_sbindir_progs').split():
+        d.setVarFlag('ALTERNATIVE_LINK_NAME', prog, '%s/%s' % (d.getVar('base_sbindir'), prog))
+}
+
diff --git a/poky/meta/recipes-extended/psmisc/psmisc_23.0.bb b/poky/meta/recipes-extended/psmisc/psmisc_23.0.bb
deleted file mode 100644
index 2b07f49..0000000
--- a/poky/meta/recipes-extended/psmisc/psmisc_23.0.bb
+++ /dev/null
@@ -1,10 +0,0 @@
-require psmisc.inc
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3"
-
-SRC_URI = "git://gitlab.com/psmisc/psmisc.git;protocol=https \
-           file://0001-Use-UINTPTR_MAX-instead-of-__WORDSIZE.patch \
-	   file://0001-Makefile.am-create-src-directory-before-attempting-t.patch \
-           "
-SRCREV = "67b1da268f4c0ce6859980e3dfcfaec5b2448e80"
-S = "${WORKDIR}/git"
diff --git a/poky/meta/recipes-extended/psmisc/psmisc_23.1.bb b/poky/meta/recipes-extended/psmisc/psmisc_23.1.bb
new file mode 100644
index 0000000..f07c9db
--- /dev/null
+++ b/poky/meta/recipes-extended/psmisc/psmisc_23.1.bb
@@ -0,0 +1,10 @@
+require psmisc.inc
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3"
+
+SRC_URI = "git://gitlab.com/psmisc/psmisc.git;protocol=https \
+           file://0001-Use-UINTPTR_MAX-instead-of-__WORDSIZE.patch \
+	   file://0001-Makefile.am-create-src-directory-before-attempting-t.patch \
+           "
+SRCREV = "bd952b3063f2466ecab4ec093026cf0c4ce373c7"
+S = "${WORKDIR}/git"
diff --git a/poky/meta/recipes-extended/rpcbind/rpcbind/rpcbind_add_option_to_fix_port_number.patch b/poky/meta/recipes-extended/rpcbind/rpcbind/rpcbind_add_option_to_fix_port_number.patch
new file mode 100644
index 0000000..434b6b1
--- /dev/null
+++ b/poky/meta/recipes-extended/rpcbind/rpcbind/rpcbind_add_option_to_fix_port_number.patch
@@ -0,0 +1,130 @@
+From 76f8598fd20727908e760cbb497dd6a17eda4af5 Mon Sep 17 00:00:00 2001
+From: Roy Li <rongqing.li@windriver.com>
+Date: Wed, 17 Sep 2014 13:22:14 +0800
+Subject: [PATCH] add option to make users able to use fixed port number
+
+Upstream-Status: Submitted [https://sourceforge.net/p/rpcbind/discussion/716839/thread/32af721d/]
+
+Signed-off-by: Li Wang <li.wang@windriver.com>
+Signed-off-by: Roy Li <rongqing.li@windriver.com>
+Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
+---
+ man/rpcbind.8      |  4 +++-
+ src/rpcb_svc_com.c | 17 +++++++++++++++++
+ src/rpcbind.c      |  8 ++++++--
+ 3 files changed, 26 insertions(+), 3 deletions(-)
+
+diff --git a/man/rpcbind.8 b/man/rpcbind.8
+index af6200f..2e6146b 100644
+--- a/man/rpcbind.8
++++ b/man/rpcbind.8
+@@ -11,7 +11,7 @@
+ .Nd universal addresses to RPC program number mapper
+ .Sh SYNOPSIS
+ .Nm
+-.Op Fl adhiLls
++.Op Fl adhpiLls
+ .Sh DESCRIPTION
+ The
+ .Nm
+@@ -107,6 +107,8 @@ will automatically add
+ and if IPv6 is enabled,
+ .Li ::1
+ to the list.
++.It Fl p
++Bind for fixed UDP port number
+ .It Fl i
+ .Dq Insecure
+ mode.
+diff --git a/src/rpcb_svc_com.c b/src/rpcb_svc_com.c
+index 8aef9e5..c2632a4 100644
+--- a/src/rpcb_svc_com.c
++++ b/src/rpcb_svc_com.c
+@@ -48,6 +48,7 @@
+ #include <rpc/rpc.h>
+ #include <rpc/rpcb_prot.h>
+ #include <rpc/svc_dg.h>
++#include <rpc/rpc_com.h>
+ #include <netconfig.h>
+ #include <errno.h>
+ #include <syslog.h>
+@@ -497,6 +498,7 @@ xdr_opaque_parms(XDR *xdrs, struct r_rmtcall_args *cap)
+ 
+ static struct rmtcallfd_list *rmthead;
+ static struct rmtcallfd_list *rmttail;
++extern unsigned short fixed_port;
+ 
+ int
+ create_rmtcall_fd(struct netconfig *nconf)
+@@ -504,6 +506,8 @@ create_rmtcall_fd(struct netconfig *nconf)
+ 	int fd;
+ 	struct rmtcallfd_list *rmt;
+ 	SVCXPRT *xprt;
++	struct __rpc_sockinfo si;
++	struct t_bind taddr;
+ 
+ 	if ((fd = __rpc_nconf2fd(nconf)) == -1) {
+ 		if (debugging)
+@@ -512,6 +516,19 @@ create_rmtcall_fd(struct netconfig *nconf)
+ 			nconf->nc_device, errno);
+ 		return (-1);
+ 	}
++
++	if (fixed_port) {
++		__rpc_fd2sockinfo(fd, &si);
++		memset(&taddr, 0, sizeof(taddr));
++		taddr.addr.maxlen = taddr.addr.len = si.si_alen;
++		taddr.addr.buf = malloc(si.si_alen);
++		if (taddr.addr.buf == NULL) {
++			return -1;
++		}
++		*(unsigned short *)(&(taddr.addr.buf[0])) = si.si_af;
++		*(unsigned short *)(&(taddr.addr.buf[2])) = htons(fixed_port);
++		xprt = svc_tli_create(fd, nconf, &taddr, RPC_MAXDATASIZE, RPC_MAXDATASIZE);
++	} else
+ 	xprt = svc_tli_create(fd, 0, (struct t_bind *) 0, 0, 0);
+ 	if (xprt == NULL) {
+ 		if (debugging)
+diff --git a/src/rpcbind.c b/src/rpcbind.c
+index 137011b..dc3d2d6 100644
+--- a/src/rpcbind.c
++++ b/src/rpcbind.c
+@@ -111,6 +111,7 @@ int runasdaemon = 0;
+ int insecure = 0;
+ int oldstyle_local = 0;
+ int verboselog = 0;
++unsigned short fixed_port = 0;
+ 
+ char **hosts = NULL;
+ int nhosts = 0;
+@@ -869,7 +870,7 @@ parseargs(int argc, char *argv[])
+ {
+ 	int c;
+ 	oldstyle_local = 1;
+-	while ((c = getopt(argc, argv, "adh:ilswf")) != -1) {
++	while ((c = getopt(argc, argv, "adh:p:ilswf")) != -1) {
+ 		switch (c) {
+ 		case 'a':
+ 			doabort = 1;	/* when debugging, do an abort on */
+@@ -887,6 +888,9 @@ parseargs(int argc, char *argv[])
+ 			if (hosts[nhosts - 1] == NULL)
+ 				errx(1, "Out of memory");
+ 			break;
++		case 'p':
++			fixed_port = atoi(optarg);
++			break;
+ 		case 'i':
+ 			insecure = 1;
+ 			break;
+@@ -905,7 +909,7 @@ parseargs(int argc, char *argv[])
+ 			break;
+ #endif
+ 		default:	/* error */
+-			fprintf(stderr,	"usage: rpcbind [-adhilswf]\n");
++			fprintf(stderr,	"usage: rpcbind [-adhpilswf]\n");
+ 			exit (1);
+ 		}
+ 	}
+-- 
+1.9.1
+
diff --git a/poky/meta/recipes-extended/rpcbind/rpcbind_0.2.4.bb b/poky/meta/recipes-extended/rpcbind/rpcbind_0.2.4.bb
index dcdee6c..3c6774c 100644
--- a/poky/meta/recipes-extended/rpcbind/rpcbind_0.2.4.bb
+++ b/poky/meta/recipes-extended/rpcbind/rpcbind_0.2.4.bb
@@ -18,6 +18,7 @@
            file://0001-rpcbind-pair-all-svc_getargs-calls-with-svc_freeargs.patch \
            file://pmapproc_dump-Fixed-typo-in-memory-leak-patch.patch \
            file://rpcbproc_callit_com-Stop-freeing-a-static-pointer.patch \
+           file://rpcbind_add_option_to_fix_port_number.patch \
           "
 SRC_URI[md5sum] = "cf10cd41ed8228fc54c316191c1f07fe"
 SRC_URI[sha256sum] = "074a9a530dc7c11e0d905aa59bcb0847c009313f02e98d3d798aa9568f414c66"
diff --git a/poky/meta/recipes-extended/rpcsvc-proto/rpcsvc-proto.bb b/poky/meta/recipes-extended/rpcsvc-proto/rpcsvc-proto.bb
new file mode 100644
index 0000000..cb5b288
--- /dev/null
+++ b/poky/meta/recipes-extended/rpcsvc-proto/rpcsvc-proto.bb
@@ -0,0 +1,37 @@
+# Copyright (C) 2018 Khem Raj <raj.khem@gmail.com>
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+SUMMARY = "rpcsvc protocol definitions from glibc"
+
+DESCRIPTION = "This package contains rpcsvc proto.x files from glibc, which are\
+missing in libtirpc. Additional it contains rpcgen, which is needed\
+to create header files and sources from protocol files.\
+This package is only needed, if glibc is installed without the\
+deprecated sunrpc functionality and libtirpc should replace it."
+
+HOMEPAGE = "https://github.com/thkukuk/rpcsvc-proto"
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://COPYING;md5=0daaf958d5531ab86169ec6e275e1517"
+SECTION = "libs"
+DEPENDS += "rpcsvc-proto-native"
+
+PV = "1.4+git${SRCPV}"
+
+SRCREV = "9bc3b5b785723cfff459b0c01b39d87d4bed975c"
+
+SRC_URI = "git://github.com/thkukuk/${BPN} \
+           file://0001-Use-cross-compiled-rpcgen.patch \
+          "
+
+S = "${WORKDIR}/git"
+
+inherit autotools
+
+EXTRA_OEMAKE_class-native = " -C rpcgen"
+
+do_install_append() {
+	# They come from quota recipe
+	rm -rf ${D}${includedir}/rpcsvc/rquota.[hx]
+}
+
+BBCLASSEXTEND += "native nativesdk"
diff --git a/poky/meta/recipes-extended/rpcsvc-proto/rpcsvc-proto/0001-Use-cross-compiled-rpcgen.patch b/poky/meta/recipes-extended/rpcsvc-proto/rpcsvc-proto/0001-Use-cross-compiled-rpcgen.patch
new file mode 100644
index 0000000..2089740
--- /dev/null
+++ b/poky/meta/recipes-extended/rpcsvc-proto/rpcsvc-proto/0001-Use-cross-compiled-rpcgen.patch
@@ -0,0 +1,23 @@
+From de9345207beb71e4d5b6b40b52cac4ebd2e3858c Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 27 Apr 2018 23:23:20 -0700
+Subject: [PATCH] Use cross compiled rpcgen
+
+Upstream-Status: Inappropriate [OE-Specific]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ rpcsvc/Makefile.am | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+Index: git/rpcsvc/Makefile.am
+===================================================================
+--- git.orig/rpcsvc/Makefile.am
++++ git/rpcsvc/Makefile.am
+@@ -12,5 +12,5 @@ nodist_rpcsvc_HEADERS = klm_prot.h nlm_p
+ 	nfs_prot.h rquota.h sm_inter.h
+ 
+ %.h: %.x
+-	$(top_builddir)/rpcgen/rpcgen -h -o $@ $<
++	rpcgen -h -o $@ $<
+ 
diff --git a/poky/meta/recipes-extended/screen/screen_4.6.2.bb b/poky/meta/recipes-extended/screen/screen_4.6.2.bb
index 7a33c31..375dce9 100644
--- a/poky/meta/recipes-extended/screen/screen_4.6.2.bb
+++ b/poky/meta/recipes-extended/screen/screen_4.6.2.bb
@@ -11,7 +11,7 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
                     file://screen.h;endline=26;md5=3971142989289a8198a544220703c2bf"
 
-DEPENDS = "ncurses \
+DEPENDS = "ncurses virtual/crypt \
           ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)}"
 RDEPENDS_${PN} = "base-files"
 
diff --git a/poky/meta/recipes-extended/shadow/files/0001-Disable-use-of-syslog-for-sysroot.patch b/poky/meta/recipes-extended/shadow/files/0001-Disable-use-of-syslog-for-sysroot.patch
index a6f604b..aac2d42 100644
--- a/poky/meta/recipes-extended/shadow/files/0001-Disable-use-of-syslog-for-sysroot.patch
+++ b/poky/meta/recipes-extended/shadow/files/0001-Disable-use-of-syslog-for-sysroot.patch
@@ -11,6 +11,7 @@
 
 Signed-off-by: Scott Garman <scott.a.garman@intel.com>
 Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
 ---
  src/groupadd.c  | 3 +++
  src/groupdel.c  | 3 +++
@@ -22,7 +23,7 @@
  7 files changed, 21 insertions(+)
 
 diff --git a/src/groupadd.c b/src/groupadd.c
-index 39b4ec0..f716f57 100644
+index 63e1c48..a596c49 100644
 --- a/src/groupadd.c
 +++ b/src/groupadd.c
 @@ -34,6 +34,9 @@
@@ -36,7 +37,7 @@
  #include <fcntl.h>
  #include <getopt.h>
 diff --git a/src/groupdel.c b/src/groupdel.c
-index da99347..46a679c 100644
+index 70bed01..ababd81 100644
 --- a/src/groupdel.c
 +++ b/src/groupdel.c
 @@ -34,6 +34,9 @@
@@ -50,7 +51,7 @@
  #include <fcntl.h>
  #include <grp.h>
 diff --git a/src/groupmems.c b/src/groupmems.c
-index e4f107f..95cb073 100644
+index fc91c8b..2842514 100644
 --- a/src/groupmems.c
 +++ b/src/groupmems.c
 @@ -32,6 +32,9 @@
@@ -64,7 +65,7 @@
  #include <getopt.h>
  #include <grp.h>
 diff --git a/src/groupmod.c b/src/groupmod.c
-index d9d3807..6229737 100644
+index 72daf2c..8965f9d 100644
 --- a/src/groupmod.c
 +++ b/src/groupmod.c
 @@ -34,6 +34,9 @@
@@ -78,7 +79,7 @@
  #include <fcntl.h>
  #include <getopt.h>
 diff --git a/src/useradd.c b/src/useradd.c
-index e1ebf50..25679d8 100644
+index 3aaf45c..1ab9174 100644
 --- a/src/useradd.c
 +++ b/src/useradd.c
 @@ -34,6 +34,9 @@
@@ -92,7 +93,7 @@
  #include <ctype.h>
  #include <errno.h>
 diff --git a/src/userdel.c b/src/userdel.c
-index 19b12bc..a083929 100644
+index c8de1d3..24d3ea9 100644
 --- a/src/userdel.c
 +++ b/src/userdel.c
 @@ -34,6 +34,9 @@
@@ -102,11 +103,11 @@
 +/* Disable use of syslog since we're running this command against a sysroot */
 +#undef USE_SYSLOG
 +
+ #include <assert.h>
  #include <errno.h>
  #include <fcntl.h>
- #include <getopt.h>
 diff --git a/src/usermod.c b/src/usermod.c
-index 685b50a..28e5cfc 100644
+index ccfbb99..24fb60d 100644
 --- a/src/usermod.c
 +++ b/src/usermod.c
 @@ -34,6 +34,9 @@
@@ -116,9 +117,9 @@
 +/* Disable use of syslog since we're running this command against a sysroot */
 +#undef USE_SYSLOG
 +
+ #include <assert.h>
  #include <ctype.h>
  #include <errno.h>
- #include <fcntl.h>
 -- 
-2.1.0
+2.11.0
 
diff --git a/poky/meta/recipes-extended/shadow/files/0001-Do-not-read-login.defs-before-doing-chroot.patch b/poky/meta/recipes-extended/shadow/files/0001-Do-not-read-login.defs-before-doing-chroot.patch
deleted file mode 100644
index 828b95a..0000000
--- a/poky/meta/recipes-extended/shadow/files/0001-Do-not-read-login.defs-before-doing-chroot.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-From 170c25c8e0b5c3dc2615d1db94c8d24a13ff99bf Mon Sep 17 00:00:00 2001
-From: Peter Kjellerstedt <pkj@axis.com>
-Date: Thu, 11 Sep 2014 15:11:23 +0200
-Subject: [PATCH] Do not read login.defs before doing chroot()
-
-If "useradd --root <root> ..." was used, the login.defs file would still
-be read from /etc/login.defs instead of <root>/etc/login.defs. This was
-due to getdef_ulong() being called before process_root_flag().
-
-Upstream-Status: Submitted [http://lists.alioth.debian.org/pipermail/pkg-shadow-devel/2014-September/010446.html]
-
-Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
----
- src/useradd.c | 8 ++++++--
- 1 file changed, 6 insertions(+), 2 deletions(-)
-
-diff --git a/src/useradd.c b/src/useradd.c
-index a8a1f76..e1ebf50 100644
---- a/src/useradd.c
-+++ b/src/useradd.c
-@@ -1993,9 +1993,11 @@ int main (int argc, char **argv)
- #endif				/* USE_PAM */
- #endif				/* ACCT_TOOLS_SETUID */
- 
-+#ifdef ENABLE_SUBIDS
- 	/* Needed for userns check */
--	uid_t uid_min = (uid_t) getdef_ulong ("UID_MIN", 1000UL);
--	uid_t uid_max = (uid_t) getdef_ulong ("UID_MAX", 60000UL);
-+	uid_t uid_min;
-+	uid_t uid_max;
-+#endif
- 
- 	/*
- 	 * Get my name so that I can use it to report errors.
-@@ -2026,6 +2028,8 @@ int main (int argc, char **argv)
- 	is_shadow_grp = sgr_file_present ();
- #endif
- #ifdef ENABLE_SUBIDS
-+	uid_min = (uid_t) getdef_ulong ("UID_MIN", 1000UL);
-+	uid_max = (uid_t) getdef_ulong ("UID_MAX", 60000UL);
- 	is_sub_uid = sub_uid_file_present () && !rflg &&
- 	    (!user_id || (user_id <= uid_max && user_id >= uid_min));
- 	is_sub_gid = sub_gid_file_present () && !rflg &&
--- 
-1.9.0
-
diff --git a/poky/meta/recipes-extended/shadow/files/0001-shadow-CVE-2017-12424 b/poky/meta/recipes-extended/shadow/files/0001-shadow-CVE-2017-12424
deleted file mode 100644
index 4d3e1e0..0000000
--- a/poky/meta/recipes-extended/shadow/files/0001-shadow-CVE-2017-12424
+++ /dev/null
@@ -1,46 +0,0 @@
-From 954e3d2e7113e9ac06632aee3c69b8d818cc8952 Mon Sep 17 00:00:00 2001
-From: Tomas Mraz <tmraz@fedoraproject.org>
-Date: Fri, 31 Mar 2017 16:25:06 +0200
-Subject: [PATCH] Fix buffer overflow if NULL line is present in db.
-
-If ptr->line == NULL for an entry, the first cycle will exit,
-but the second one will happily write past entries buffer.
-We actually do not want to exit the first cycle prematurely
-on ptr->line == NULL.
-Signed-off-by: Tomas Mraz <tmraz@fedoraproject.org>
-
-CVE: CVE-2017-12424
-Upstream-Status: Backport
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- lib/commonio.c | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/lib/commonio.c b/lib/commonio.c
-index b10da06..31edbaa 100644
---- a/lib/commonio.c
-+++ b/lib/commonio.c
-@@ -751,16 +751,16 @@ commonio_sort (struct commonio_db *db, int (*cmp) (const void *, const void *))
- 	for (ptr = db->head;
- 	        (NULL != ptr)
- #if KEEP_NIS_AT_END
--	     && (NULL != ptr->line)
--	     && (   ('+' != ptr->line[0])
--	         && ('-' != ptr->line[0]))
-+	     && ((NULL == ptr->line)
-+	         || (('+' != ptr->line[0])
-+	             && ('-' != ptr->line[0])))
- #endif
- 	     ;
- 	     ptr = ptr->next) {
- 		n++;
- 	}
- #if KEEP_NIS_AT_END
--	if ((NULL != ptr) && (NULL != ptr->line)) {
-+	if (NULL != ptr) {
- 		nis = ptr;
- 	}
- #endif
--- 
-2.1.0
-
diff --git a/poky/meta/recipes-extended/shadow/files/0001-useradd-copy-extended-attributes-of-home.patch b/poky/meta/recipes-extended/shadow/files/0001-useradd-copy-extended-attributes-of-home.patch
index 60a46e1..474b3a2 100644
--- a/poky/meta/recipes-extended/shadow/files/0001-useradd-copy-extended-attributes-of-home.patch
+++ b/poky/meta/recipes-extended/shadow/files/0001-useradd-copy-extended-attributes-of-home.patch
@@ -1,47 +1,41 @@
-From acec93540eba6899661c607408498ac72ab07a47 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Jos=C3=A9=20Bollo?= <jose.bollo@iot.bzh>
-Date: Tue, 7 Mar 2017 16:03:03 +0100
 Subject: [PATCH] useradd: copy extended attributes of home
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
 
 The Home directory wasn't getting the extended attributes
 of /etc/skel. This patch fixes that issue and adds the copy
 of the extended attributes of the root of the home directory.
 
-Upstream-Status: Submitted [http://lists.alioth.debian.org/pipermail/pkg-shadow-commits/2017-March/003804.html]
+Upstream-Status: Pending
 
-Change-Id: Icd633f7c6c494efd2a30cb8f04c306f749ad0c3b
 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
 ---
  src/useradd.c | 6 ++++++
  1 file changed, 6 insertions(+)
 
 diff --git a/src/useradd.c b/src/useradd.c
-index a8a1f76..8aefb9c 100644
+index e721e52..c74e491 100644
 --- a/src/useradd.c
 +++ b/src/useradd.c
-@@ -52,6 +52,9 @@
- #include <sys/stat.h>
- #include <sys/types.h>
+@@ -54,6 +54,9 @@
+ #include <sys/wait.h>
  #include <time.h>
+ #include <unistd.h>
 +#ifdef WITH_ATTR
 +#include <attr/libattr.h>
 +#endif
  #include "chkname.h"
  #include "defines.h"
  #include "faillog.h"
-@@ -1915,6 +1918,9 @@ static void create_home (void)
- 		chown (user_home, user_id, user_gid);
- 		chmod (user_home,
+@@ -2042,6 +2045,9 @@ static void create_home (void)
+ 		(void) chown (prefix_user_home, user_id, user_gid);
+ 		chmod (prefix_user_home,
  		       0777 & ~getdef_num ("UMASK", GETDEF_DEFAULT_UMASK));
 +#ifdef WITH_ATTR
-+		attr_copy_file (def_template, user_home, NULL, NULL);
++	               attr_copy_file (def_template, user_home, NULL, NULL);
 +#endif
  		home_added = true;
  #ifdef WITH_AUDIT
  		audit_logger (AUDIT_ADD_USER, Prog,
 -- 
-2.9.3
+2.11.0
 
diff --git a/poky/meta/recipes-extended/shadow/files/0001-useradd.c-create-parent-directories-when-necessary.patch b/poky/meta/recipes-extended/shadow/files/0001-useradd.c-create-parent-directories-when-necessary.patch
index 2f084b4..7024136 100644
--- a/poky/meta/recipes-extended/shadow/files/0001-useradd.c-create-parent-directories-when-necessary.patch
+++ b/poky/meta/recipes-extended/shadow/files/0001-useradd.c-create-parent-directories-when-necessary.patch
@@ -1,17 +1,17 @@
-Upstream-Status: Inappropriate [OE specific]
+Subject: [PATCH] useradd.c: create parent directories when necessary
 
-Subject: useradd.c: create parent directories when necessary
+Upstream-Status: Inappropriate [OE specific]
 
 Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
 ---
- src/useradd.c |   72 +++++++++++++++++++++++++++++++++++++++------------------
- 1 file changed, 49 insertions(+), 23 deletions(-)
+ src/useradd.c | 82 +++++++++++++++++++++++++++++++++++++++--------------------
+ 1 file changed, 54 insertions(+), 28 deletions(-)
 
 diff --git a/src/useradd.c b/src/useradd.c
-index 4bd969d..cb5dd6c 100644
+index 7214e72..3aaf45c 100644
 --- a/src/useradd.c
 +++ b/src/useradd.c
-@@ -1896,6 +1896,35 @@ static void usr_update (void)
+@@ -2021,6 +2021,35 @@ static void usr_update (void)
  }
  
  /*
@@ -47,63 +47,68 @@
   * create_home - create the user's home directory
   *
   *	create_home() creates the user's home directory if it does not
-@@ -1910,39 +1939,36 @@ static void create_home (void)
+@@ -2038,42 +2067,39 @@ static void create_home (void)
  			fail_exit (E_HOMEDIR);
  		}
  #endif
 -		/* XXX - create missing parent directories.  --marekm */
--		if (mkdir (user_home, 0) != 0) {
+-		if (mkdir (prefix_user_home, 0) != 0) {
 -			fprintf (stderr,
 -			         _("%s: cannot create directory %s\n"),
--			         Prog, user_home);
--#ifdef WITH_AUDIT
+-			         Prog, prefix_user_home);
++		mkdir_p(user_home);
++	}
++	if (access (prefix_user_home, F_OK) != 0) {
+ #ifdef WITH_AUDIT
 -			audit_logger (AUDIT_ADD_USER, Prog,
 -			              "adding home directory",
 -			              user_name, (unsigned int) user_id,
 -			              SHADOW_AUDIT_FAILURE);
--#endif
--			fail_exit (E_HOMEDIR);
--		}
--		chown (user_home, user_id, user_gid);
--		chmod (user_home,
--		       0777 & ~getdef_num ("UMASK", GETDEF_DEFAULT_UMASK));
--#ifdef WITH_ATTR
--		attr_copy_file (def_template, user_home, NULL, NULL);
--#endif
--		home_added = true;
-+		mkdir_p(user_home);
-+	}
-+	if (access (user_home, F_OK) != 0) {
- #ifdef WITH_AUDIT
- 		audit_logger (AUDIT_ADD_USER, Prog,
- 		              "adding home directory",
- 		              user_name, (unsigned int) user_id,
--		              SHADOW_AUDIT_SUCCESS);
-+		              SHADOW_AUDIT_FAILURE);
++		audit_logger (AUDIT_ADD_USER, Prog,
++			      "adding home directory",
++			      user_name, (unsigned int) user_id,
++			      SHADOW_AUDIT_FAILURE);
  #endif
--#ifdef WITH_SELINUX
--		/* Reset SELinux to create files with default contexts */
--		if (reset_selinux_file_context () != 0) {
 -			fail_exit (E_HOMEDIR);
 -		}
+-		(void) chown (prefix_user_home, user_id, user_gid);
+-		chmod (prefix_user_home,
+-		       0777 & ~getdef_num ("UMASK", GETDEF_DEFAULT_UMASK));
 +		fail_exit (E_HOMEDIR);
 +	}
-+	chown (user_home, user_id, user_gid);
-+	chmod (user_home,
++	(void) chown (prefix_user_home, user_id, user_gid);
++	chmod (prefix_user_home,
 +	       0777 & ~getdef_num ("UMASK", GETDEF_DEFAULT_UMASK));
-+#ifdef WITH_ATTR
+ #ifdef WITH_ATTR
+-	               attr_copy_file (def_template, user_home, NULL, NULL);
 +	attr_copy_file (def_template, user_home, NULL, NULL);
-+#endif
+ #endif
+-		home_added = true;
 +	home_added = true;
-+#ifdef WITH_AUDIT
+ #ifdef WITH_AUDIT
+-		audit_logger (AUDIT_ADD_USER, Prog,
+-		              "adding home directory",
+-		              user_name, (unsigned int) user_id,
+-		              SHADOW_AUDIT_SUCCESS);
 +	audit_logger (AUDIT_ADD_USER, Prog,
 +		      "adding home directory",
 +		      user_name, (unsigned int) user_id,
 +		      SHADOW_AUDIT_SUCCESS);
  #endif
-+#ifdef WITH_SELINUX
+ #ifdef WITH_SELINUX
+-		/* Reset SELinux to create files with default contexts */
+-		if (reset_selinux_file_context () != 0) {
+-			fprintf (stderr,
+-			         _("%s: cannot reset SELinux file creation context\n"),
+-			         Prog);
+-			fail_exit (E_HOMEDIR);
+-		}
+-#endif
 +	/* Reset SELinux to create files with default contexts */
 +	if (reset_selinux_file_context () != 0) {
++		fprintf (stderr,
++			 _("%s: cannot reset SELinux file creation context\n"),
++			 Prog);
 +		fail_exit (E_HOMEDIR);
  	}
 +#endif
@@ -111,5 +116,5 @@
  
  /*
 -- 
-1.7.9.5
+2.11.0
 
diff --git a/poky/meta/recipes-extended/shadow/files/CVE-2017-2616.patch b/poky/meta/recipes-extended/shadow/files/CVE-2017-2616.patch
deleted file mode 100644
index ee728f0..0000000
--- a/poky/meta/recipes-extended/shadow/files/CVE-2017-2616.patch
+++ /dev/null
@@ -1,64 +0,0 @@
-shadow-4.2.1: Fix CVE-2017-2616
-
-[No upstream tracking] -- https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=855943
-
-su: properly clear child PID
-
-If su is compiled with PAM support, it is possible for any local user
-to send SIGKILL to other processes with root privileges. There are
-only two conditions. First, the user must be able to perform su with
-a successful login. This does NOT have to be the root user, even using
-su with the same id is enough, e.g. "su $(whoami)". Second, SIGKILL
-can only be sent to processes which were executed after the su process.
-It is not possible to send SIGKILL to processes which were already
-running. I consider this as a security vulnerability, because I was
-able to write a proof of concept which unlocked a screen saver of
-another user this way.
-
-Upstream-Status: Backport [https://github.com/shadow-maint/shadow/commit/08fd4b69e84364677a10e519ccb25b71710ee686]
-CVE: CVE-2017-2616
-bug: 855943
-Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
-
-diff --git a/src/su.c b/src/su.c
-index 3704217..1efcd61 100644
---- a/src/su.c
-+++ b/src/su.c
-@@ -363,20 +363,35 @@ static void prepare_pam_close_session (void)
- 				/* wake child when resumed */
- 				kill (pid, SIGCONT);
- 				stop = false;
-+			} else {
-+				pid_child = 0;
- 			}
- 		} while (!stop);
- 	}
- 
--	if (0 != caught) {
-+	if (0 != caught && 0 != pid_child) {
- 		(void) fputs ("\n", stderr);
- 		(void) fputs (_("Session terminated, terminating shell..."),
- 		              stderr);
- 		(void) kill (-pid_child, caught);
- 
- 		(void) signal (SIGALRM, kill_child);
-+		(void) signal (SIGCHLD, catch_signals);
- 		(void) alarm (2);
- 
--		(void) wait (&status);
-+		sigemptyset (&ourset);
-+		if ((sigaddset (&ourset, SIGALRM) != 0)
-+		    || (sigprocmask (SIG_BLOCK, &ourset, NULL) != 0)) {
-+			fprintf (stderr, _("%s: signal masking malfunction\n"), Prog);
-+			kill_child (0);
-+		} else {
-+			while (0 == waitpid (pid_child, &status, WNOHANG)) {
-+				sigsuspend (&ourset);
-+			}
-+			pid_child = 0;
-+			(void) sigprocmask (SIG_UNBLOCK, &ourset, NULL);
-+		}
-+
- 		(void) fputs (_(" ...terminated.\n"), stderr);
- 	}
- 
diff --git a/poky/meta/recipes-extended/shadow/files/CVE-2018-7169.patch b/poky/meta/recipes-extended/shadow/files/CVE-2018-7169.patch
deleted file mode 100644
index 36887d4..0000000
--- a/poky/meta/recipes-extended/shadow/files/CVE-2018-7169.patch
+++ /dev/null
@@ -1,186 +0,0 @@
-From fb28c99b8a66ff2605c5cb96abc0a4d975f92de0 Mon Sep 17 00:00:00 2001
-From: Aleksa Sarai <asarai@suse.de>
-Date: Thu, 15 Feb 2018 23:49:40 +1100
-Subject: [PATCH] newgidmap: enforce setgroups=deny if self-mapping a group
-
-This is necessary to match the kernel-side policy of "self-mapping in a
-user namespace is fine, but you cannot drop groups" -- a policy that was
-created in order to stop user namespaces from allowing trivial privilege
-escalation by dropping supplementary groups that were "blacklisted" from
-certain paths.
-
-This is the simplest fix for the underlying issue, and effectively makes
-it so that unless a user has a valid mapping set in /etc/subgid (which
-only administrators can modify) -- and they are currently trying to use
-that mapping -- then /proc/$pid/setgroups will be set to deny. This
-workaround is only partial, because ideally it should be possible to set
-an "allow_setgroups" or "deny_setgroups" flag in /etc/subgid to allow
-administrators to further restrict newgidmap(1).
-
-We also don't write anything in the "allow" case because "allow" is the
-default, and users may have already written "deny" even if they
-technically are allowed to use setgroups. And we don't write anything if
-the setgroups policy is already "deny".
-
-Ref: https://bugs.launchpad.net/ubuntu/+source/shadow/+bug/1729357
-Fixes: CVE-2018-7169
-
-Upstream-Status: Backport [https://github.com/shadow-maint/shadow/commit/fb28c99b8a66ff2605c5cb96abc0a4d975f92de0]
-Reported-by: Craig Furman <craig.furman89@gmail.com>
-Signed-off-by: Aleksa Sarai <asarai@suse.de>
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- src/newgidmap.c | 89 +++++++++++++++++++++++++++++++++++++++++++++++++++------
- 1 file changed, 80 insertions(+), 9 deletions(-)
-
-diff --git a/src/newgidmap.c b/src/newgidmap.c
-index b1e33513..59a2e75c 100644
---- a/src/newgidmap.c
-+++ b/src/newgidmap.c
-@@ -46,32 +46,37 @@
-  */
- const char *Prog;
- 
--static bool verify_range(struct passwd *pw, struct map_range *range)
-+
-+static bool verify_range(struct passwd *pw, struct map_range *range, bool *allow_setgroups)
- {
- 	/* An empty range is invalid */
- 	if (range->count == 0)
- 		return false;
- 
--	/* Test /etc/subgid */
--	if (have_sub_gids(pw->pw_name, range->lower, range->count))
-+	/* Test /etc/subgid. If the mapping is valid then we allow setgroups. */
-+	if (have_sub_gids(pw->pw_name, range->lower, range->count)) {
-+		*allow_setgroups = true;
- 		return true;
-+	}
- 
--	/* Allow a process to map it's own gid */
--	if ((range->count == 1) && (pw->pw_gid == range->lower))
-+	/* Allow a process to map its own gid. */
-+	if ((range->count == 1) && (pw->pw_gid == range->lower)) {
-+		/* noop -- if setgroups is enabled already we won't disable it. */
- 		return true;
-+	}
- 
- 	return false;
- }
- 
- static void verify_ranges(struct passwd *pw, int ranges,
--	struct map_range *mappings)
-+	struct map_range *mappings, bool *allow_setgroups)
- {
- 	struct map_range *mapping;
- 	int idx;
- 
- 	mapping = mappings;
- 	for (idx = 0; idx < ranges; idx++, mapping++) {
--		if (!verify_range(pw, mapping)) {
-+		if (!verify_range(pw, mapping, allow_setgroups)) {
- 			fprintf(stderr, _( "%s: gid range [%lu-%lu) -> [%lu-%lu) not allowed\n"),
- 				Prog,
- 				mapping->upper,
-@@ -89,6 +94,70 @@ static void usage(void)
- 	exit(EXIT_FAILURE);
- }
- 
-+void write_setgroups(int proc_dir_fd, bool allow_setgroups)
-+{
-+	int setgroups_fd;
-+	char *policy, policy_buffer[4096];
-+
-+	/*
-+	 * Default is "deny", and any "allow" will out-rank a "deny". We don't
-+	 * forcefully write an "allow" here because the process we are writing
-+	 * mappings for may have already set themselves to "deny" (and "allow"
-+	 * is the default anyway). So allow_setgroups == true is a noop.
-+	 */
-+	policy = "deny\n";
-+	if (allow_setgroups)
-+		return;
-+
-+	setgroups_fd = openat(proc_dir_fd, "setgroups", O_RDWR|O_CLOEXEC);
-+	if (setgroups_fd < 0) {
-+		/*
-+		 * If it's an ENOENT then we are on too old a kernel for the setgroups
-+		 * code to exist. Emit a warning and bail on this.
-+		 */
-+		if (ENOENT == errno) {
-+			fprintf(stderr, _("%s: kernel doesn't support setgroups restrictions\n"), Prog);
-+			goto out;
-+		}
-+		fprintf(stderr, _("%s: couldn't open process setgroups: %s\n"),
-+			Prog,
-+			strerror(errno));
-+		exit(EXIT_FAILURE);
-+	}
-+
-+	/*
-+	 * Check whether the policy is already what we want. /proc/self/setgroups
-+	 * is write-once, so attempting to write after it's already written to will
-+	 * fail.
-+	 */
-+	if (read(setgroups_fd, policy_buffer, sizeof(policy_buffer)) < 0) {
-+		fprintf(stderr, _("%s: failed to read setgroups: %s\n"),
-+			Prog,
-+			strerror(errno));
-+		exit(EXIT_FAILURE);
-+	}
-+	if (!strncmp(policy_buffer, policy, strlen(policy)))
-+		goto out;
-+
-+	/* Write the policy. */
-+	if (lseek(setgroups_fd, 0, SEEK_SET) < 0) {
-+		fprintf(stderr, _("%s: failed to seek setgroups: %s\n"),
-+			Prog,
-+			strerror(errno));
-+		exit(EXIT_FAILURE);
-+	}
-+	if (dprintf(setgroups_fd, "%s", policy) < 0) {
-+		fprintf(stderr, _("%s: failed to setgroups %s policy: %s\n"),
-+			Prog,
-+			policy,
-+			strerror(errno));
-+		exit(EXIT_FAILURE);
-+	}
-+
-+out:
-+	close(setgroups_fd);
-+}
-+
- /*
-  * newgidmap - Set the gid_map for the specified process
-  */
-@@ -103,6 +172,7 @@ int main(int argc, char **argv)
- 	struct stat st;
- 	struct passwd *pw;
- 	int written;
-+	bool allow_setgroups = false;
- 
- 	Prog = Basename (argv[0]);
- 
-@@ -145,7 +215,7 @@ int main(int argc, char **argv)
- 				(unsigned long) getuid ()));
- 		return EXIT_FAILURE;
- 	}
--	
-+
- 	/* Get the effective uid and effective gid of the target process */
- 	if (fstat(proc_dir_fd, &st) < 0) {
- 		fprintf(stderr, _("%s: Could not stat directory for target %u\n"),
-@@ -177,8 +247,9 @@ int main(int argc, char **argv)
- 	if (!mappings)
- 		usage();
- 
--	verify_ranges(pw, ranges, mappings);
-+	verify_ranges(pw, ranges, mappings, &allow_setgroups);
- 
-+	write_setgroups(proc_dir_fd, allow_setgroups);
- 	write_mapping(proc_dir_fd, ranges, mappings, "gid_map");
- 	sub_gid_close();
- 
--- 
-2.13.3
-
diff --git a/poky/meta/recipes-extended/shadow/files/allow-for-setting-password-in-clear-text.patch b/poky/meta/recipes-extended/shadow/files/allow-for-setting-password-in-clear-text.patch
index 615c6e0..fa7eb07 100644
--- a/poky/meta/recipes-extended/shadow/files/allow-for-setting-password-in-clear-text.patch
+++ b/poky/meta/recipes-extended/shadow/files/allow-for-setting-password-in-clear-text.patch
@@ -1,21 +1,21 @@
-Upstream-Status: Inappropriate [OE specific]
+Subject: [PATCH] Allow for setting password in clear text
 
-Allow for setting password in clear text.
+Upstream-Status: Inappropriate [OE specific]
 
 Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
 ---
- src/Makefile.am |    8 ++++----
- src/groupadd.c  |    8 +++++++-
- src/groupmod.c  |    8 +++++++-
- src/useradd.c   |    9 +++++++--
- src/usermod.c   |    8 +++++++-
- 5 files changed, 32 insertions(+), 9 deletions(-)
+ src/Makefile.am |  8 ++++----
+ src/groupadd.c  | 20 +++++++++++++++-----
+ src/groupmod.c  | 20 +++++++++++++++-----
+ src/useradd.c   | 21 +++++++++++++++------
+ src/usermod.c   | 20 +++++++++++++++-----
+ 5 files changed, 64 insertions(+), 25 deletions(-)
 
 diff --git a/src/Makefile.am b/src/Makefile.am
-index 25e288d..856b087 100644
+index 3c98a8d..b8093d5 100644
 --- a/src/Makefile.am
 +++ b/src/Makefile.am
-@@ -88,10 +88,10 @@ chgpasswd_LDADD = $(LDADD) $(LIBPAM_SUID) $(LIBSELINUX) $(LIBCRYPT)
+@@ -93,10 +93,10 @@ chgpasswd_LDADD = $(LDADD) $(LIBPAM_SUID) $(LIBSELINUX) $(LIBCRYPT)
  chsh_LDADD     = $(LDADD) $(LIBPAM) $(LIBSELINUX) $(LIBCRYPT_NOPAM) $(LIBSKEY) $(LIBMD)
  chpasswd_LDADD = $(LDADD) $(LIBPAM) $(LIBSELINUX) $(LIBCRYPT)
  gpasswd_LDADD  = $(LDADD) $(LIBAUDIT) $(LIBSELINUX) $(LIBCRYPT)
@@ -28,9 +28,9 @@
  grpck_LDADD    = $(LDADD) $(LIBSELINUX)
  grpconv_LDADD  = $(LDADD) $(LIBSELINUX)
  grpunconv_LDADD = $(LDADD) $(LIBSELINUX)
-@@ -111,9 +111,9 @@ su_SOURCES     = \
+@@ -117,9 +117,9 @@ su_SOURCES     = \
  	suauth.c
- su_LDADD       = $(LDADD) $(LIBPAM) $(LIBCRYPT_NOPAM) $(LIBSKEY) $(LIBMD)
+ su_LDADD       = $(LDADD) $(LIBPAM) $(LIBAUDIT) $(LIBCRYPT_NOPAM) $(LIBSKEY) $(LIBMD)
  sulogin_LDADD  = $(LDADD) $(LIBCRYPT)
 -useradd_LDADD  = $(LDADD) $(LIBPAM_SUID) $(LIBAUDIT) $(LIBSELINUX) $(LIBSEMANAGE) $(LIBACL) $(LIBATTR)
 +useradd_LDADD  = $(LDADD) $(LIBPAM_SUID) $(LIBAUDIT) $(LIBSELINUX) $(LIBSEMANAGE) $(LIBACL) $(LIBATTR) $(LIBCRYPT)
@@ -41,33 +41,39 @@
  
  install-am: all-am
 diff --git a/src/groupadd.c b/src/groupadd.c
-index f716f57..4e28c26 100644
+index b57006c..63e1c48 100644
 --- a/src/groupadd.c
 +++ b/src/groupadd.c
-@@ -124,6 +124,7 @@ static /*@noreturn@*/void usage (int status)
+@@ -123,9 +123,10 @@ static /*@noreturn@*/void usage (int status)
  	(void) fputs (_("  -o, --non-unique              allow to create groups with duplicate\n"
  	                "                                (non-unique) GID\n"), usageout);
  	(void) fputs (_("  -p, --password PASSWORD       use this encrypted password for the new group\n"), usageout);
 +	(void) fputs (_("  -P, --clear-password PASSWORD use this clear password for the new group\n"), usageout);
  	(void) fputs (_("  -r, --system                  create a system account\n"), usageout);
  	(void) fputs (_("  -R, --root CHROOT_DIR         directory to chroot into\n"), usageout);
+-	(void) fputs (_("  -P, --prefix PREFIX_DIR       directory prefix\n"), usageout);
++	(void) fputs (_("  -A, --prefix PREFIX_DIR       directory prefix\n"), usageout);
  	(void) fputs ("\n", usageout);
-@@ -387,12 +388,13 @@ static void process_flags (int argc, char **argv)
+ 	exit (status);
+ }
+@@ -387,13 +388,14 @@ static void process_flags (int argc, char **argv)
  		{"key",        required_argument, NULL, 'K'},
  		{"non-unique", no_argument,       NULL, 'o'},
  		{"password",   required_argument, NULL, 'p'},
 +		{"clear-password", required_argument, NULL, 'P'},
  		{"system",     no_argument,       NULL, 'r'},
  		{"root",       required_argument, NULL, 'R'},
+-		{"prefix",     required_argument, NULL, 'P'},
++		{"prefix",     required_argument, NULL, 'A'},
  		{NULL, 0, NULL, '\0'}
  	};
  
--	while ((c = getopt_long (argc, argv, "fg:hK:op:rR:",
-+	while ((c = getopt_long (argc, argv, "fg:hK:op:P:rR:",
+-	while ((c = getopt_long (argc, argv, "fg:hK:op:rR:P:",
++	while ((c = getopt_long (argc, argv, "fg:hK:op:P:rR:A:",
  		                 long_options, NULL)) != -1) {
  		switch (c) {
  		case 'f':
-@@ -444,6 +446,10 @@ static void process_flags (int argc, char **argv)
+@@ -445,12 +447,20 @@ static void process_flags (int argc, char **argv)
  			pflg = true;
  			group_passwd = optarg;
  			break;
@@ -78,32 +84,57 @@
  		case 'r':
  			rflg = true;
  			break;
+ 		case 'R': /* no-op, handled in process_root_flag () */
+ 			break;
+-		case 'P': /* no-op, handled in process_prefix_flag () */
++		case 'A': /* no-op, handled in process_prefix_flag () */
++			fprintf (stderr,
++				 _("%s: -A is deliberately not supported \n"),
++				 Prog);
++			exit (E_BAD_ARG);
+ 			break;
+ 		default:
+ 			usage (E_USAGE);
+@@ -584,7 +594,7 @@ int main (int argc, char **argv)
+ 	(void) textdomain (PACKAGE);
+ 
+ 	process_root_flag ("-R", argc, argv);
+-	prefix = process_prefix_flag ("-P", argc, argv);
++	prefix = process_prefix_flag ("-A", argc, argv);
+ 
+ 	OPENLOG ("groupadd");
+ #ifdef WITH_AUDIT
 diff --git a/src/groupmod.c b/src/groupmod.c
-index d9d3807..68f49d1 100644
+index b293b98..72daf2c 100644
 --- a/src/groupmod.c
 +++ b/src/groupmod.c
-@@ -127,6 +127,7 @@ static void usage (int status)
+@@ -134,8 +134,9 @@ static void usage (int status)
  	(void) fputs (_("  -o, --non-unique              allow to use a duplicate (non-unique) GID\n"), usageout);
  	(void) fputs (_("  -p, --password PASSWORD       change the password to this (encrypted)\n"
  	                "                                PASSWORD\n"), usageout);
 +	(void) fputs (_("  -P, --clear-password PASSWORD change the password to this clear PASSWORD\n"), usageout);
  	(void) fputs (_("  -R, --root CHROOT_DIR         directory to chroot into\n"), usageout);
+-	(void) fputs (_("  -P, --prefix PREFIX_DIR       prefix directory where are located the /etc/* files\n"), usageout);
++	(void) fputs (_("  -A, --prefix PREFIX_DIR       prefix directory where are located the /etc/* files\n"), usageout);
  	(void) fputs ("\n", usageout);
  	exit (status);
-@@ -375,10 +376,11 @@ static void process_flags (int argc, char **argv)
+ }
+@@ -383,11 +384,12 @@ static void process_flags (int argc, char **argv)
  		{"new-name",   required_argument, NULL, 'n'},
  		{"non-unique", no_argument,       NULL, 'o'},
  		{"password",   required_argument, NULL, 'p'},
 +		{"clear-password", required_argument, NULL, 'P'},
  		{"root",       required_argument, NULL, 'R'},
+-		{"prefix",     required_argument, NULL, 'P'},
++		{"prefix",     required_argument, NULL, 'A'},
  		{NULL, 0, NULL, '\0'}
  	};
--	while ((c = getopt_long (argc, argv, "g:hn:op:R:",
-+	while ((c = getopt_long (argc, argv, "g:hn:op:P:R:",
+-	while ((c = getopt_long (argc, argv, "g:hn:op:R:P:",
++	while ((c = getopt_long (argc, argv, "g:hn:op:P:R:A:",
  		                 long_options, NULL)) != -1) {
  		switch (c) {
  		case 'g':
-@@ -405,6 +407,10 @@ static void process_flags (int argc, char **argv)
+@@ -414,9 +416,17 @@ static void process_flags (int argc, char **argv)
  			group_passwd = optarg;
  			pflg = true;
  			break;
@@ -113,40 +144,65 @@
 +			break;
  		case 'R': /* no-op, handled in process_root_flag () */
  			break;
+-		case 'P': /* no-op, handled in process_prefix_flag () */
++		case 'A': /* no-op, handled in process_prefix_flag () */
++			fprintf (stderr,
++				 _("%s: -A is deliberately not supported \n"),
++				 Prog);
++			exit (E_BAD_ARG);
+ 			break;
  		default:
+ 			usage (E_USAGE);
+@@ -757,7 +767,7 @@ int main (int argc, char **argv)
+ 	(void) textdomain (PACKAGE);
+ 
+ 	process_root_flag ("-R", argc, argv);
+-	prefix = process_prefix_flag ("-P", argc, argv);
++	prefix = process_prefix_flag ("-A", argc, argv);
+ 
+ 	OPENLOG ("groupmod");
+ #ifdef WITH_AUDIT
 diff --git a/src/useradd.c b/src/useradd.c
-index b3bd451..4416f90 100644
+index c74e491..7214e72 100644
 --- a/src/useradd.c
 +++ b/src/useradd.c
-@@ -776,6 +776,7 @@ static void usage (int status)
+@@ -829,9 +829,10 @@ static void usage (int status)
  	(void) fputs (_("  -o, --non-unique              allow to create users with duplicate\n"
  	                "                                (non-unique) UID\n"), usageout);
  	(void) fputs (_("  -p, --password PASSWORD       encrypted password of the new account\n"), usageout);
 +	(void) fputs (_("  -P, --clear-password PASSWORD clear password of the new account\n"), usageout);
  	(void) fputs (_("  -r, --system                  create a system account\n"), usageout);
  	(void) fputs (_("  -R, --root CHROOT_DIR         directory to chroot into\n"), usageout);
+-	(void) fputs (_("  -P, --prefix PREFIX_DIR       prefix directory where are located the /etc/* files\n"), usageout);
++	(void) fputs (_("  -A, --prefix PREFIX_DIR       prefix directory where are located the /etc/* files\n"), usageout);
  	(void) fputs (_("  -s, --shell SHELL             login shell of the new account\n"), usageout);
-@@ -1050,6 +1051,7 @@ static void process_flags (int argc, char **argv)
+ 	(void) fputs (_("  -u, --uid UID                 user ID of the new account\n"), usageout);
+ 	(void) fputs (_("  -U, --user-group              create a group with the same name as the user\n"), usageout);
+@@ -1104,9 +1105,10 @@ static void process_flags (int argc, char **argv)
  			{"no-user-group",  no_argument,       NULL, 'N'},
  			{"non-unique",     no_argument,       NULL, 'o'},
  			{"password",       required_argument, NULL, 'p'},
 +			{"clear-password", required_argument, NULL, 'P'},
  			{"system",         no_argument,       NULL, 'r'},
  			{"root",           required_argument, NULL, 'R'},
+-			{"prefix",         required_argument, NULL, 'P'},
++			{"prefix",         required_argument, NULL, 'A'},
  			{"shell",          required_argument, NULL, 's'},
-@@ -1062,9 +1064,9 @@ static void process_flags (int argc, char **argv)
+ 			{"uid",            required_argument, NULL, 'u'},
+ 			{"user-group",     no_argument,       NULL, 'U'},
+@@ -1117,9 +1119,9 @@ static void process_flags (int argc, char **argv)
  		};
  		while ((c = getopt_long (argc, argv,
  #ifdef WITH_SELINUX
--		                         "b:c:d:De:f:g:G:hk:K:lmMNop:rR:s:u:UZ:",
-+		                         "b:c:d:De:f:g:G:hk:K:lmMNop:P:rR:s:u:UZ:",
+-		                         "b:c:d:De:f:g:G:hk:K:lmMNop:rR:P:s:u:UZ:",
++		                         "b:c:d:De:f:g:G:hk:K:lmMNop:P:rR:A:s:u:UZ:",
  #else				/* !WITH_SELINUX */
--		                         "b:c:d:De:f:g:G:hk:K:lmMNop:rR:s:u:U",
-+		                         "b:c:d:De:f:g:G:hk:K:lmMNop:P:rR:s:u:U",
+-		                         "b:c:d:De:f:g:G:hk:K:lmMNop:rR:P:s:u:U",
++		                         "b:c:d:De:f:g:G:hk:K:lmMNop:P:rR:A:s:u:U",
  #endif				/* !WITH_SELINUX */
  		                         long_options, NULL)) != -1) {
  			switch (c) {
-@@ -1230,6 +1232,9 @@ static void process_flags (int argc, char **argv)
+@@ -1285,12 +1287,19 @@ static void process_flags (int argc, char **argv)
  				}
  				user_pass = optarg;
  				break;
@@ -156,36 +212,62 @@
  			case 'r':
  				rflg = true;
  				break;
+ 			case 'R': /* no-op, handled in process_root_flag () */
+ 				break;
+-			case 'P': /* no-op, handled in process_prefix_flag () */
++			case 'A': /* no-op, handled in process_prefix_flag () */
++				fprintf (stderr,
++					 _("%s: -A is deliberately not supported \n"),
++					 Prog);
++				exit (E_BAD_ARG);
+ 				break;
+ 			case 's':
+ 				if (   ( !VALID (optarg) )
+@@ -2148,7 +2157,7 @@ int main (int argc, char **argv)
+ 
+ 	process_root_flag ("-R", argc, argv);
+ 
+-	prefix = process_prefix_flag("-P", argc, argv);
++	prefix = process_prefix_flag("-A", argc, argv);
+ 
+ 	OPENLOG ("useradd");
+ #ifdef WITH_AUDIT
 diff --git a/src/usermod.c b/src/usermod.c
-index e7d4351..b79f7a3 100644
+index e571426..ccfbb99 100644
 --- a/src/usermod.c
 +++ b/src/usermod.c
-@@ -419,6 +419,7 @@ static /*@noreturn@*/void usage (int status)
+@@ -424,8 +424,9 @@ static /*@noreturn@*/void usage (int status)
  	                "                                new location (use only with -d)\n"), usageout);
  	(void) fputs (_("  -o, --non-unique              allow using duplicate (non-unique) UID\n"), usageout);
  	(void) fputs (_("  -p, --password PASSWORD       use encrypted password for the new password\n"), usageout);
 +	(void) fputs (_("  -P, --clear-password PASSWORD use clear password for the new password\n"), usageout);
  	(void) fputs (_("  -R, --root CHROOT_DIR         directory to chroot into\n"), usageout);
+-	(void) fputs (_("  -P, --prefix PREFIX_DIR       prefix directory where are located the /etc/* files\n"), usageout);
++	(void) fputs (_("  -A, --prefix PREFIX_DIR       prefix directory where are located the /etc/* files\n"), usageout);
  	(void) fputs (_("  -s, --shell SHELL             new login shell for the user account\n"), usageout);
  	(void) fputs (_("  -u, --uid UID                 new UID for the user account\n"), usageout);
-@@ -996,6 +997,7 @@ static void process_flags (int argc, char **argv)
+ 	(void) fputs (_("  -U, --unlock                  unlock the user account\n"), usageout);
+@@ -1002,8 +1003,9 @@ static void process_flags (int argc, char **argv)
  			{"move-home",    no_argument,       NULL, 'm'},
  			{"non-unique",   no_argument,       NULL, 'o'},
  			{"password",     required_argument, NULL, 'p'},
 +			{"clear-password", required_argument, NULL, 'P'},
  			{"root",         required_argument, NULL, 'R'},
+-			{"prefix",       required_argument, NULL, 'P'},
++			{"prefix",       required_argument, NULL, 'A'},
  			{"shell",        required_argument, NULL, 's'},
  			{"uid",          required_argument, NULL, 'u'},
-@@ -1012,7 +1014,7 @@ static void process_flags (int argc, char **argv)
+ 			{"unlock",       no_argument,       NULL, 'U'},
+@@ -1019,7 +1021,7 @@ static void process_flags (int argc, char **argv)
  			{NULL, 0, NULL, '\0'}
  		};
  		while ((c = getopt_long (argc, argv,
--		                         "ac:d:e:f:g:G:hl:Lmop:R:s:u:U"
-+		                         "ac:d:e:f:g:G:hl:Lmop:P:R:s:u:U"
+-		                         "ac:d:e:f:g:G:hl:Lmop:R:s:u:UP:"
++		                         "ac:d:e:f:g:G:hl:Lmop:P:R:s:u:UA:"
  #ifdef ENABLE_SUBIDS
  		                         "v:w:V:W:"
  #endif				/* ENABLE_SUBIDS */
-@@ -1112,6 +1114,10 @@ static void process_flags (int argc, char **argv)
+@@ -1119,9 +1121,17 @@ static void process_flags (int argc, char **argv)
  				user_pass = optarg;
  				pflg = true;
  				break;
@@ -195,7 +277,24 @@
 +				break;
  			case 'R': /* no-op, handled in process_root_flag () */
  				break;
+-			case 'P': /* no-op, handled in process_prefix_flag () */
++			case 'A': /* no-op, handled in process_prefix_flag () */
++				fprintf (stderr,
++					 _("%s: -A is deliberately not supported \n"),
++					 Prog);
++				exit (E_BAD_ARG);
+ 				break;
  			case 's':
+ 				if (!VALID (optarg)) {
+@@ -2098,7 +2108,7 @@ int main (int argc, char **argv)
+ 	(void) textdomain (PACKAGE);
+ 
+ 	process_root_flag ("-R", argc, argv);
+-	prefix = process_prefix_flag ("-P", argc, argv);
++	prefix = process_prefix_flag ("-A", argc, argv);
+ 
+ 	OPENLOG ("usermod");
+ #ifdef WITH_AUDIT
 -- 
-1.7.9.5
+2.11.0
 
diff --git a/poky/meta/recipes-extended/shadow/files/check_size_of_uid_t_and_gid_t_using_AC_CHECK_SIZEOF.patch b/poky/meta/recipes-extended/shadow/files/check_size_of_uid_t_and_gid_t_using_AC_CHECK_SIZEOF.patch
deleted file mode 100644
index 185590c..0000000
--- a/poky/meta/recipes-extended/shadow/files/check_size_of_uid_t_and_gid_t_using_AC_CHECK_SIZEOF.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From 2cb54158b80cdbd97ca3b36df83f9255e923ae3f Mon Sep 17 00:00:00 2001
-From: James Le Cuirot <chewi@aura-online.co.uk>
-Date: Sat, 23 Aug 2014 09:46:39 +0100
-Subject: [PATCH] Check size of uid_t and gid_t using AC_CHECK_SIZEOF
-
-This built-in check is simpler than the previous method and, most
-importantly, works when cross-compiling.
-
-Upstream-Status: Accepted
-[https://github.com/shadow-maint/shadow/commit/2cb54158b80cdbd97ca3b36df83f9255e923ae3f]
-
-Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com>
----
- configure.in | 14 ++++----------
- 1 file changed, 4 insertions(+), 10 deletions(-)
-
-diff --git a/configure.in b/configure.in
-index 1a3f841..4a4d6d0 100644
---- a/configure.in
-+++ b/configure.in
-@@ -335,16 +335,10 @@ if test "$enable_subids" != "no"; then
- 	dnl
- 	dnl FIXME: check if 32 bit UIDs/GIDs are supported by libc
- 	dnl
--	AC_RUN_IFELSE([AC_LANG_SOURCE([
--#include <sys/types.h>
--int main(void) {
--	uid_t u;
--	gid_t g;
--	return (sizeof u < 4) || (sizeof g < 4);
--}
--	])], [id32bit="yes"], [id32bit="no"])
--
--	if test "x$id32bit" = "xyes"; then
-+	AC_CHECK_SIZEOF([uid_t],, [#include "sys/types.h"])
-+	AC_CHECK_SIZEOF([gid_t],, [#include "sys/types.h"])
-+
-+	if test "$ac_cv_sizeof_uid_t" -ge 4 && test "$ac_cv_sizeof_gid_t" -ge 4; then
- 		AC_DEFINE(ENABLE_SUBIDS, 1, [Define to support the subordinate IDs.])
- 		enable_subids="yes"
- 	else
diff --git a/poky/meta/recipes-extended/shadow/files/fix-installation-failure-with-subids-disabled.patch b/poky/meta/recipes-extended/shadow/files/fix-installation-failure-with-subids-disabled.patch
deleted file mode 100644
index 02cb91a..0000000
--- a/poky/meta/recipes-extended/shadow/files/fix-installation-failure-with-subids-disabled.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-Upstream-Status: Pending
-
-Subject: fix installation failure with subids disabled
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- src/Makefile.am |    5 ++++-
- 1 file changed, 4 insertions(+), 1 deletion(-)
-
-diff --git a/src/Makefile.am b/src/Makefile.am
-index 25e288d..076f8ef 100644
---- a/src/Makefile.am
-+++ b/src/Makefile.am
-@@ -52,7 +52,10 @@ usbin_PROGRAMS = \
- noinst_PROGRAMS = id sulogin
- 
- suidbins       = su
--suidubins      = chage chfn chsh expiry gpasswd newgrp passwd newuidmap newgidmap
-+suidubins      = chage chfn chsh expiry gpasswd newgrp passwd
-+if ENABLE_SUBIDS
-+suidubins += newgidmap newuidmap
-+endif
- if ACCT_TOOLS_SETUID
- 	suidubins += chage chgpasswd chpasswd groupadd groupdel groupmod newusers useradd userdel usermod
- endif
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-extended/shadow/files/usermod-fix-compilation-failure-with-subids-disabled.patch b/poky/meta/recipes-extended/shadow/files/usermod-fix-compilation-failure-with-subids-disabled.patch
deleted file mode 100644
index 37dc153..0000000
--- a/poky/meta/recipes-extended/shadow/files/usermod-fix-compilation-failure-with-subids-disabled.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-Upstream-Status: Pending
-
-usermod: fix compilation failure with subids disabled
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- src/usermod.c |    3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
-diff --git a/src/usermod.c b/src/usermod.c
-index e7d4351..685b50a 100644
---- a/src/usermod.c
-+++ b/src/usermod.c
-@@ -1360,7 +1360,7 @@ static void process_flags (int argc, char **argv)
- 		         Prog, (unsigned long) user_newid);
- 		exit (E_UID_IN_USE);
- 	}
--
-+#ifdef ENABLE_SUBIDS
- 	if (   (vflg || Vflg)
- 	    && !is_sub_uid) {
- 		fprintf (stderr,
-@@ -1376,6 +1376,7 @@ static void process_flags (int argc, char **argv)
- 		         Prog, sub_gid_dbname (), "-w", "-W");
- 		exit (E_USAGE);
- 	}
-+#endif
- }
- 
- /*
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-extended/shadow/shadow-securetty_4.2.1.bb b/poky/meta/recipes-extended/shadow/shadow-securetty_4.6.bb
similarity index 100%
rename from poky/meta/recipes-extended/shadow/shadow-securetty_4.2.1.bb
rename to poky/meta/recipes-extended/shadow/shadow-securetty_4.6.bb
diff --git a/poky/meta/recipes-extended/shadow/shadow-sysroot_4.2.1.bb b/poky/meta/recipes-extended/shadow/shadow-sysroot_4.6.bb
similarity index 100%
rename from poky/meta/recipes-extended/shadow/shadow-sysroot_4.2.1.bb
rename to poky/meta/recipes-extended/shadow/shadow-sysroot_4.6.bb
diff --git a/poky/meta/recipes-extended/shadow/shadow.inc b/poky/meta/recipes-extended/shadow/shadow.inc
index 4e1eaed..09c37ef 100644
--- a/poky/meta/recipes-extended/shadow/shadow.inc
+++ b/poky/meta/recipes-extended/shadow/shadow.inc
@@ -9,18 +9,10 @@
 DEPENDS = "virtual/crypt"
 
 UPSTREAM_CHECK_URI = "https://github.com/shadow-maint/shadow/releases"
-
-SRC_URI = "https://downloads.yoctoproject.org/mirror/sources/${BP}.tar.xz \
+SRC_URI = "https://github.com/shadow-maint/shadow/releases/download/${PV}/${BP}.tar.gz \
            file://shadow-4.1.3-dots-in-usernames.patch \
-           file://usermod-fix-compilation-failure-with-subids-disabled.patch \
-           file://fix-installation-failure-with-subids-disabled.patch \
-           file://0001-Do-not-read-login.defs-before-doing-chroot.patch \
-           file://check_size_of_uid_t_and_gid_t_using_AC_CHECK_SIZEOF.patch \
            file://0001-useradd-copy-extended-attributes-of-home.patch \
-           file://0001-shadow-CVE-2017-12424 \
-           file://CVE-2017-2616.patch \
            ${@bb.utils.contains('PACKAGECONFIG', 'pam', '${PAM_SRC_URI}', '', d)} \
-           file://CVE-2018-7169.patch \
            "
 
 SRC_URI_append_class-target = " \
@@ -39,8 +31,8 @@
            file://0001-Disable-use-of-syslog-for-sysroot.patch \
            "
 
-SRC_URI[md5sum] = "2bfafe7d4962682d31b5eba65dba4fc8"
-SRC_URI[sha256sum] = "3b0893d1476766868cd88920f4f1231c4795652aa407569faff802bcda0f3d41"
+SRC_URI[md5sum] = "36feb15665338ae3de414f2a88e434db"
+SRC_URI[sha256sum] = "4668f99bd087399c4a586084dc3b046b75f560720d83e92fd23bf7a89dda4d31"
 
 # Additional Policy files for PAM
 PAM_SRC_URI = "file://pam.d/chfn \
diff --git a/poky/meta/recipes-extended/shadow/shadow_4.2.1.bb b/poky/meta/recipes-extended/shadow/shadow_4.6.bb
similarity index 100%
rename from poky/meta/recipes-extended/shadow/shadow_4.2.1.bb
rename to poky/meta/recipes-extended/shadow/shadow_4.6.bb
diff --git a/poky/meta/recipes-extended/slang/slang_2.3.2.bb b/poky/meta/recipes-extended/slang/slang_2.3.2.bb
index 87fd41a..e53c432 100644
--- a/poky/meta/recipes-extended/slang/slang_2.3.2.bb
+++ b/poky/meta/recipes-extended/slang/slang_2.3.2.bb
@@ -78,4 +78,4 @@
 PARALLEL_MAKE = ""
 PARALLEL_MAKEINST = ""
 
-BBCLASSEXTEND = "native"
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/sudo/sudo.inc b/poky/meta/recipes-extended/sudo/sudo.inc
index 362bd3a..69dccde 100644
--- a/poky/meta/recipes-extended/sudo/sudo.inc
+++ b/poky/meta/recipes-extended/sudo/sudo.inc
@@ -4,7 +4,7 @@
 BUGTRACKER = "http://www.sudo.ws/bugs/"
 SECTION = "admin"
 LICENSE = "ISC & BSD & Zlib"
-LIC_FILES_CHKSUM = "file://doc/LICENSE;md5=7765a3d787cb4fed3ccc3c9cee030af9 \
+LIC_FILES_CHKSUM = "file://doc/LICENSE;md5=cc4bf2366b059c9598e3947f885931ec \
                     file://plugins/sudoers/redblack.c;beginline=1;endline=41;md5=805782a8466975716f8376b2be9aedde \
                     file://lib/util/reallocarray.c;beginline=3;endline=16;md5=85b0905b795d4d58bf2e00635649eec6 \
                     file://lib/util/fnmatch.c;beginline=3;endline=27;md5=67f83ee9bd456557397082f8f1be0efd \
@@ -12,12 +12,14 @@
                     file://lib/util/glob.c;beginline=6;endline=31;md5=5872733146b9eb0deb79e1f664815b85 \
                     file://lib/util/snprintf.c;beginline=6;endline=34;md5=c82c1b3a5c32e08545c9ec5d71e41e50 \
                     file://include/sudo_queue.h;beginline=5;endline=27;md5=449af4cc57fc7d46f42090608ba3e681 \
-                    file://lib/util/inet_pton.c;beginline=3;endline=17;md5=3970ab0518ab79cbd0bafb697f10b33a"
+                    file://lib/util/inet_pton.c;beginline=3;endline=17;md5=3970ab0518ab79cbd0bafb697f10b33a \
+                    "
 
 inherit autotools
 
 PACKAGECONFIG ??= ""
 PACKAGECONFIG[zlib] = "--enable-zlib,--disable-zlib,zlib"
+PACKAGECONFIG[pam-wheel] = ",,,pam-plugin-wheel"
 
 CONFFILES_${PN} = "${sysconfdir}/sudoers"
 
diff --git a/poky/meta/recipes-extended/sudo/sudo_1.8.22.bb b/poky/meta/recipes-extended/sudo/sudo_1.8.22.bb
deleted file mode 100644
index 9150178..0000000
--- a/poky/meta/recipes-extended/sudo/sudo_1.8.22.bb
+++ /dev/null
@@ -1,36 +0,0 @@
-require sudo.inc
-
-SRC_URI = "http://ftp.sudo.ws/sudo/dist/sudo-${PV}.tar.gz \
-           ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${PAM_SRC_URI}', '', d)} \
-           file://0001-Include-sys-types.h-for-id_t-definition.patch \
-           "
-
-PAM_SRC_URI = "file://sudo.pam"
-
-SRC_URI[md5sum] = "24abdea48db4c5abcd410167c801cc8c"
-SRC_URI[sha256sum] = "7256cb27c20883b14360eddbd17f98922073d104b214cf65aeacf1d9c9b9fd02"
-
-DEPENDS += " ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)}"
-RDEPENDS_${PN} += " ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'pam-plugin-limits pam-plugin-keyinit', '', d)}"
-
-EXTRA_OECONF += " \
-             ac_cv_type_rsize_t=no \
-             ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '--with-pam', '--without-pam', d)} \
-             ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '--enable-tmpfiles.d=${libdir}/tmpfiles.d', '--disable-tmpfiles.d', d)} \
-             "
-
-do_install_append () {
-	if [ "${@bb.utils.filter('DISTRO_FEATURES', 'pam', d)}" ]; then
-		install -D -m 644 ${WORKDIR}/sudo.pam ${D}/${sysconfdir}/pam.d/sudo
-	fi
-
-	chmod 4111 ${D}${bindir}/sudo
-	chmod 0440 ${D}${sysconfdir}/sudoers
-
-	# Explicitly remove the ${localstatedir}/run directory to avoid QA error
-	rmdir -p --ignore-fail-on-non-empty ${D}${localstatedir}/run/sudo
-}
-
-FILES_${PN} += "${libdir}/tmpfiles.d"
-FILES_${PN}-dev += "${libexecdir}/${BPN}/lib*${SOLIBSDEV} ${libexecdir}/${BPN}/*.la \
-                    ${libexecdir}/lib*${SOLIBSDEV} ${libexecdir}/*.la"
diff --git a/poky/meta/recipes-extended/sudo/sudo_1.8.23.bb b/poky/meta/recipes-extended/sudo/sudo_1.8.23.bb
new file mode 100644
index 0000000..ce32bd1
--- /dev/null
+++ b/poky/meta/recipes-extended/sudo/sudo_1.8.23.bb
@@ -0,0 +1,40 @@
+require sudo.inc
+
+SRC_URI = "http://ftp.sudo.ws/sudo/dist/sudo-${PV}.tar.gz \
+           ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${PAM_SRC_URI}', '', d)} \
+           file://0001-Include-sys-types.h-for-id_t-definition.patch \
+           "
+
+PAM_SRC_URI = "file://sudo.pam"
+
+SRC_URI[md5sum] = "ea444d747feb1decfebdffd0b38b0739"
+SRC_URI[sha256sum] = "d863d29b6fc87bc784a3223350e2b28a2ff2c4738f0fb8f1c92bb38c3017e679"
+
+DEPENDS += " virtual/crypt ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)}"
+RDEPENDS_${PN} += " ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'pam-plugin-limits pam-plugin-keyinit', '', d)}"
+
+EXTRA_OECONF += " \
+             ac_cv_type_rsize_t=no \
+             ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '--with-pam', '--without-pam', d)} \
+             ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '--enable-tmpfiles.d=${libdir}/tmpfiles.d', '--disable-tmpfiles.d', d)} \
+             "
+
+do_install_append () {
+	if [ "${@bb.utils.filter('DISTRO_FEATURES', 'pam', d)}" ]; then
+		install -D -m 644 ${WORKDIR}/sudo.pam ${D}/${sysconfdir}/pam.d/sudo
+		if ${@bb.utils.contains('PACKAGECONFIG', 'pam-wheel', 'true', 'false', d)} ; then
+			echo 'auth       required     pam_wheel.so use_uid' >>${D}${sysconfdir}/pam.d/sudo
+			sed -i 's/# \(%wheel ALL=(ALL) ALL\)/\1/' ${D}${sysconfdir}/sudoers
+		fi
+	fi
+
+	chmod 4111 ${D}${bindir}/sudo
+	chmod 0440 ${D}${sysconfdir}/sudoers
+
+	# Explicitly remove the /run directory to avoid QA error
+	rmdir -p --ignore-fail-on-non-empty ${D}/run/sudo
+}
+
+FILES_${PN} += "${libdir}/tmpfiles.d"
+FILES_${PN}-dev += "${libexecdir}/${BPN}/lib*${SOLIBSDEV} ${libexecdir}/${BPN}/*.la \
+                    ${libexecdir}/lib*${SOLIBSDEV} ${libexecdir}/*.la"
diff --git a/poky/meta/recipes-extended/sysklogd/sysklogd.inc b/poky/meta/recipes-extended/sysklogd/sysklogd.inc
index fc4e67c..f151dd8 100644
--- a/poky/meta/recipes-extended/sysklogd/sysklogd.inc
+++ b/poky/meta/recipes-extended/sysklogd/sysklogd.inc
@@ -11,7 +11,7 @@
                     file://klogd.c;beginline=2;endline=19;md5=7e87ed0ae6142de079bce738c10c899d \
                    "
 
-inherit update-rc.d systemd
+inherit update-rc.d update-alternatives systemd
 
 SRC_URI = "http://www.infodrom.org/projects/sysklogd/download/sysklogd-${PV}.tar.gz \
            file://no-strip-install.patch \
@@ -58,6 +58,11 @@
 
 FILES_${PN} += "${@bb.utils.contains('DISTRO_FEATURES','systemd','${exec_prefix}/lib/tmpfiles.d/sysklogd.conf', '', d)}"
 
+ALTERNATIVE_PRIORITY = "100"
+
+ALTERNATIVE_${PN}-doc = "syslogd.8"
+ALTERNATIVE_LINK_NAME[syslogd.8] = "${mandir}/man8/syslogd.8"
+
 pkg_prerm_${PN} () {
 	if test "x$D" = "x"; then
 	if test "$1" = "upgrade" -o "$1" = "remove"; then
diff --git a/poky/meta/recipes-extended/sysstat/sysstat_11.7.1.bb b/poky/meta/recipes-extended/sysstat/sysstat_11.7.1.bb
deleted file mode 100644
index 86738e7..0000000
--- a/poky/meta/recipes-extended/sysstat/sysstat_11.7.1.bb
+++ /dev/null
@@ -1,8 +0,0 @@
-require sysstat.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=a23a74b3f4caf9616230789d94217acb"
-
-SRC_URI += "file://0001-Include-needed-headers-explicitly.patch"
-
-SRC_URI[md5sum] = "bdcda7c9048c7c22fb1f30f75285d13d"
-SRC_URI[sha256sum] = "303a595b1af0330b183a0f1febfccf89f183b9575ae0562b91fdb876f3ef1feb"
diff --git a/poky/meta/recipes-extended/sysstat/sysstat_11.7.4.bb b/poky/meta/recipes-extended/sysstat/sysstat_11.7.4.bb
new file mode 100644
index 0000000..c9b9130
--- /dev/null
+++ b/poky/meta/recipes-extended/sysstat/sysstat_11.7.4.bb
@@ -0,0 +1,8 @@
+require sysstat.inc
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=a23a74b3f4caf9616230789d94217acb"
+
+SRC_URI += "file://0001-Include-needed-headers-explicitly.patch"
+
+SRC_URI[md5sum] = "421f958db80e67a27eda1ff6b8ebcdeb"
+SRC_URI[sha256sum] = "a96265a22784c29888669f961a0896841d177853f8f057efe063e891962b9090"
diff --git a/poky/meta/recipes-extended/tar/tar.inc b/poky/meta/recipes-extended/tar/tar.inc
deleted file mode 100644
index 93e4da1..0000000
--- a/poky/meta/recipes-extended/tar/tar.inc
+++ /dev/null
@@ -1,52 +0,0 @@
-SUMMARY = "GNU file archiving program"
-DESCRIPTION = "GNU tar saves many files together into a single tape \
-or disk archive, and can restore individual files from the archive."
-HOMEPAGE = "http://www.gnu.org/software/tar/"
-SECTION = "base"
-
-SRC_URI = "${GNU_MIRROR}/tar/tar-${PV}.tar.bz2"
-
-inherit autotools gettext texinfo
-
-EXTRA_OECONF += "DEFAULT_RMT_DIR=${base_sbindir}"
-
-# Let aclocal use the relative path for the m4 file rather than the
-# absolute since tar has a lot of m4 files, otherwise there might
-# be an "Argument list too long" error when it is built in a long/deep
-# directory.
-acpaths = "-I ./m4"
-
-do_install () {
-    autotools_do_install
-    ln -s tar ${D}${bindir}/gtar
-}
-
-do_install_append_class-target() {
-    if [ "${base_bindir}" != "${bindir}" ]; then
-        install -d ${D}${base_bindir}
-        mv ${D}${bindir}/tar ${D}${base_bindir}/tar
-        mv ${D}${bindir}/gtar ${D}${base_bindir}/gtar
-        rmdir ${D}${bindir}/
-    fi
-}
-
-PACKAGES =+ "${PN}-rmt"
-
-FILES_${PN}-rmt = "${base_sbindir}/rmt*"
-
-inherit update-alternatives
-
-ALTERNATIVE_PRIORITY = "100"
-
-ALTERNATIVE_${PN} = "tar"
-ALTERNATIVE_${PN}-rmt = "rmt"
-ALTERNATIVE_${PN}_class-nativesdk = ""
-ALTERNATIVE_${PN}-rmt_class-nativesdk = ""
-
-ALTERNATIVE_LINK_NAME[tar] = "${base_bindir}/tar"
-ALTERNATIVE_LINK_NAME[rmt] = "${base_sbindir}/rmt"
-
-PROVIDES_append_class-native = " tar-replacement-native"
-NATIVE_PACKAGE_PATH_SUFFIX = "/${PN}"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/tar/tar_1.30.bb b/poky/meta/recipes-extended/tar/tar_1.30.bb
index e743a6d..bd24f47 100644
--- a/poky/meta/recipes-extended/tar/tar_1.30.bb
+++ b/poky/meta/recipes-extended/tar/tar_1.30.bb
@@ -1,18 +1,70 @@
-require tar.inc
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[acl] = "--with-posix-acls, --without-posix-acls, acl,"
-
+SUMMARY = "GNU file archiving program"
+DESCRIPTION = "GNU tar saves many files together into a single tape \
+or disk archive, and can restore individual files from the archive."
+HOMEPAGE = "http://www.gnu.org/software/tar/"
+SECTION = "base"
 LICENSE = "GPLv3"
 LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
 
-SRC_URI += "file://remove-gets.patch \
-            file://musl_dirent.patch \
-           "
+SRC_URI = "${GNU_MIRROR}/tar/tar-${PV}.tar.bz2 \
+           file://remove-gets.patch \
+           file://musl_dirent.patch \
+"
+
 SRC_URI[md5sum] = "8404e4c1fc5a3000228ab2b8ad674a65"
 SRC_URI[sha256sum] = "87592b86cb037c554375f5868bdd3cc57748aef38d6cb741c81065f0beac63b7"
 
-do_install_append_libc-musl() {
-	rm -f ${D}${libdir}/charset.alias
-	rmdir ${D}${libdir}
+inherit autotools gettext texinfo
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG_append_class-target = " ${@bb.utils.filter('DISTRO_FEATURES', 'acl', d)}"
+
+PACKAGECONFIG[acl] = "--with-posix-acls,--without-posix-acls,acl"
+
+EXTRA_OECONF += "DEFAULT_RMT_DIR=${base_sbindir}"
+
+# Let aclocal use the relative path for the m4 file rather than the
+# absolute since tar has a lot of m4 files, otherwise there might
+# be an "Argument list too long" error when it is built in a long/deep
+# directory.
+acpaths = "-I ./m4"
+
+do_install () {
+    autotools_do_install
+    ln -s tar ${D}${bindir}/gtar
 }
+
+do_install_append_class-target() {
+    if [ "${base_bindir}" != "${bindir}" ]; then
+        install -d ${D}${base_bindir}
+        mv ${D}${bindir}/tar ${D}${base_bindir}/tar
+        mv ${D}${bindir}/gtar ${D}${base_bindir}/gtar
+        rmdir ${D}${bindir}/
+    fi
+}
+
+do_install_append_libc-musl() {
+    rm -f ${D}${libdir}/charset.alias
+    rmdir ${D}${libdir}
+}
+
+PACKAGES =+ "${PN}-rmt"
+
+FILES_${PN}-rmt = "${base_sbindir}/rmt*"
+
+inherit update-alternatives
+
+ALTERNATIVE_PRIORITY = "100"
+
+ALTERNATIVE_${PN} = "tar"
+ALTERNATIVE_${PN}-rmt = "rmt"
+ALTERNATIVE_${PN}_class-nativesdk = ""
+ALTERNATIVE_${PN}-rmt_class-nativesdk = ""
+
+ALTERNATIVE_LINK_NAME[tar] = "${base_bindir}/tar"
+ALTERNATIVE_LINK_NAME[rmt] = "${base_sbindir}/rmt"
+
+PROVIDES_append_class-native = " tar-replacement-native"
+NATIVE_PACKAGE_PATH_SUFFIX = "/${PN}"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/tcp-wrappers/tcp-wrappers_7.6.bb b/poky/meta/recipes-extended/tcp-wrappers/tcp-wrappers_7.6.bb
index 3ece8c3..0f50674 100644
--- a/poky/meta/recipes-extended/tcp-wrappers/tcp-wrappers_7.6.bb
+++ b/poky/meta/recipes-extended/tcp-wrappers/tcp-wrappers_7.6.bb
@@ -8,6 +8,7 @@
 LIC_FILES_CHKSUM = "file://DISCLAIMER;md5=071bd69cb78b18888ea5e3da5c3127fa"
 PR ="r10"
 
+DEPENDS += "libnsl2"
 
 PACKAGES = "${PN}-dbg libwrap libwrap-doc libwrap-dev libwrap-staticdev ${PN} ${PN}-doc"
 FILES_libwrap = "${base_libdir}/lib*${SOLIBS}"
@@ -67,7 +68,6 @@
                 'KILL_OPT=-DKILL_IP_OPTIONS' \
                 'UMASK=-DDAEMON_UMASK=022' \
                 'NETGROUP=${EXTRA_OEMAKE_NETGROUP}' \
-                'LIBS=-lnsl' \
                 'ARFLAGS=rv' \
                 'AUX_OBJ=weak_symbols.o' \
                 'TLI=' \
diff --git a/poky/meta/recipes-extended/time/time_1.8.bb b/poky/meta/recipes-extended/time/time_1.8.bb
deleted file mode 100644
index fb3147a..0000000
--- a/poky/meta/recipes-extended/time/time_1.8.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-SUMMARY = "Tool that measures CPU resources"
-DESCRIPTION = "time measures many of the CPU resources, such as time and \
-memory, that other programs use."
-HOMEPAGE = "http://www.gnu.org/software/time/"
-SECTION = "utils"
-LICENSE = "GPLv3"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
-
-inherit texinfo update-alternatives
-
-ALTERNATIVE_${PN} = "time"
-ALTERNATIVE_PRIORITY = "100"
-
-BBCLASSEXTEND = "native nativesdk"
-
-SRC_URI = "${GNU_MIRROR}/time/time-${PV}.tar.gz"
-
-SRC_URI[md5sum] = "4e00dcb8c3ab11c7cf5a0d698828ac96"
-SRC_URI[sha256sum] = "8a2f540155961a35ba9b84aec5e77e3ae36c74cecb4484db455960601b7a2e1b"
-
-inherit autotools
diff --git a/poky/meta/recipes-extended/time/time_1.9.bb b/poky/meta/recipes-extended/time/time_1.9.bb
new file mode 100644
index 0000000..e2b084c
--- /dev/null
+++ b/poky/meta/recipes-extended/time/time_1.9.bb
@@ -0,0 +1,21 @@
+SUMMARY = "Tool that measures CPU resources"
+DESCRIPTION = "time measures many of the CPU resources, such as time and \
+memory, that other programs use."
+HOMEPAGE = "http://www.gnu.org/software/time/"
+SECTION = "utils"
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
+
+inherit texinfo update-alternatives
+
+ALTERNATIVE_${PN} = "time"
+ALTERNATIVE_PRIORITY = "100"
+
+BBCLASSEXTEND = "native nativesdk"
+
+SRC_URI = "${GNU_MIRROR}/time/time-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "d2356e0fe1c0b85285d83c6b2ad51b5f"
+SRC_URI[sha256sum] = "fbacf0c81e62429df3e33bda4cee38756604f18e01d977338e23306a3e3b521e"
+
+inherit autotools
diff --git a/poky/meta/recipes-extended/tzcode/tzcode-native_2018f.bb b/poky/meta/recipes-extended/tzcode/tzcode-native_2018f.bb
deleted file mode 100644
index 816e34d..0000000
--- a/poky/meta/recipes-extended/tzcode/tzcode-native_2018f.bb
+++ /dev/null
@@ -1,30 +0,0 @@
-# note that we allow for us to use data later than our code version
-#
-SUMMARY = "tzcode, timezone zoneinfo utils -- zic, zdump, tzselect"
-LICENSE = "PD & BSD & BSD-3-Clause"
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=c679c9d6b02bc2757b3eaf8f53c43fba"
-
-SRC_URI =" http://www.iana.org/time-zones/repository/releases/tzcode${PV}.tar.gz;name=tzcode \
-           http://www.iana.org/time-zones/repository/releases/tzdata${PV}.tar.gz;name=tzdata \
-           "
-
-UPSTREAM_CHECK_URI = "http://www.iana.org/time-zones"
-
-SRC_URI[tzdata.md5sum] = "e5e84f00f9d18bd6ebc8b1affec91b15"
-SRC_URI[tzdata.sha256sum] = "0af6a85fc4ea95832f76524f35696a61abb3992fd3f8db33e5a1f95653e043f2"
-SRC_URI[tzcode.md5sum] = "011d394b70e6ee3823fd77010b99737f"
-SRC_URI[tzcode.sha256sum] = "4ec74f8a84372570135ea4be16a042442fafe100f5598cb1017bfd30af6aaa70"
-
-S = "${WORKDIR}"
-
-inherit native
-
-EXTRA_OEMAKE += "cc='${CC}'"
-
-do_install () {
-        install -d ${D}${bindir}/
-        install -m 755 zic ${D}${bindir}/
-        install -m 755 zdump ${D}${bindir}/
-        install -m 755 tzselect ${D}${bindir}/
-}
diff --git a/poky/meta/recipes-extended/tzcode/tzcode-native_2018g.bb b/poky/meta/recipes-extended/tzcode/tzcode-native_2018g.bb
new file mode 100644
index 0000000..3e2b60a
--- /dev/null
+++ b/poky/meta/recipes-extended/tzcode/tzcode-native_2018g.bb
@@ -0,0 +1,30 @@
+# note that we allow for us to use data later than our code version
+#
+SUMMARY = "tzcode, timezone zoneinfo utils -- zic, zdump, tzselect"
+LICENSE = "PD & BSD & BSD-3-Clause"
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=c679c9d6b02bc2757b3eaf8f53c43fba"
+
+SRC_URI =" http://www.iana.org/time-zones/repository/releases/tzcode${PV}.tar.gz;name=tzcode \
+           http://www.iana.org/time-zones/repository/releases/tzdata${PV}.tar.gz;name=tzdata \
+           "
+
+UPSTREAM_CHECK_URI = "http://www.iana.org/time-zones"
+
+SRC_URI[tzcode.md5sum] = "b48f0282b80bb7dbe16e35626f446ae9"
+SRC_URI[tzcode.sha256sum] = "aa53f4fb6570f02081be61dc11ade19ea5a280c23822a5b4016ce0c6be23c427"
+SRC_URI[tzdata.md5sum] = "e71cb1f9d8d53c43904d79d7aeeedc1b"
+SRC_URI[tzdata.sha256sum] = "02dfde534872f6513ae4553a3388fdae579441e31b862ea99170dfc447f46a16"
+
+S = "${WORKDIR}"
+
+inherit native
+
+EXTRA_OEMAKE += "cc='${CC}'"
+
+do_install () {
+        install -d ${D}${bindir}/
+        install -m 755 zic ${D}${bindir}/
+        install -m 755 zdump ${D}${bindir}/
+        install -m 755 tzselect ${D}${bindir}/
+}
diff --git a/poky/meta/recipes-extended/tzdata/tzdata_2018f.bb b/poky/meta/recipes-extended/tzdata/tzdata_2018f.bb
deleted file mode 100644
index b167540..0000000
--- a/poky/meta/recipes-extended/tzdata/tzdata_2018f.bb
+++ /dev/null
@@ -1,215 +0,0 @@
-SUMMARY = "Timezone data"
-HOMEPAGE = "http://www.iana.org/time-zones"
-SECTION = "base"
-LICENSE = "PD & BSD & BSD-3-Clause"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=c679c9d6b02bc2757b3eaf8f53c43fba"
-
-DEPENDS = "tzcode-native"
-
-SRC_URI = "http://www.iana.org/time-zones/repository/releases/tzdata${PV}.tar.gz;name=tzdata"
-UPSTREAM_CHECK_URI = "http://www.iana.org/time-zones"
-
-SRC_URI[tzdata.md5sum] = "e5e84f00f9d18bd6ebc8b1affec91b15"
-SRC_URI[tzdata.sha256sum] = "0af6a85fc4ea95832f76524f35696a61abb3992fd3f8db33e5a1f95653e043f2"
-
-inherit allarch
-
-RCONFLICTS_${PN} = "timezones timezone-africa timezone-america timezone-antarctica \
-             timezone-arctic timezone-asia timezone-atlantic \
-             timezone-australia timezone-europe timezone-indian \
-             timezone-iso3166.tab timezone-pacific timezone-zone.tab"
-
-S = "${WORKDIR}"
-
-DEFAULT_TIMEZONE ?= "Universal"
-INSTALL_TIMEZONE_FILE ?= "1"
-
-TZONES= "africa antarctica asia australasia europe northamerica southamerica  \
-         factory etcetera backward systemv \
-        "
-# pacificnew 
-
-do_compile () {
-        for zone in ${TZONES}; do \
-            ${STAGING_BINDIR_NATIVE}/zic -d ${WORKDIR}${datadir}/zoneinfo -L /dev/null \
-                -y ${S}/yearistype.sh ${S}/${zone} ; \
-            ${STAGING_BINDIR_NATIVE}/zic -d ${WORKDIR}${datadir}/zoneinfo/posix -L /dev/null \
-                -y ${S}/yearistype.sh ${S}/${zone} ; \
-            ${STAGING_BINDIR_NATIVE}/zic -d ${WORKDIR}${datadir}/zoneinfo/right -L ${S}/leapseconds \
-                -y ${S}/yearistype.sh ${S}/${zone} ; \
-        done
-}
-
-do_install () {
-        install -d ${D}/$exec_prefix ${D}${datadir}/zoneinfo
-        cp -pPR ${S}/$exec_prefix ${D}/
-        # libc is removing zoneinfo files from package
-        cp -pP "${S}/zone.tab" ${D}${datadir}/zoneinfo
-        cp -pP "${S}/zone1970.tab" ${D}${datadir}/zoneinfo
-        cp -pP "${S}/iso3166.tab" ${D}${datadir}/zoneinfo
-
-        # Install default timezone
-        if [ -e ${D}${datadir}/zoneinfo/${DEFAULT_TIMEZONE} ]; then
-            install -d ${D}${sysconfdir}
-            if [ "${INSTALL_TIMEZONE_FILE}" = "1" ]; then
-                echo ${DEFAULT_TIMEZONE} > ${D}${sysconfdir}/timezone
-            fi
-            ln -s ${datadir}/zoneinfo/${DEFAULT_TIMEZONE} ${D}${sysconfdir}/localtime
-        else
-            bberror "DEFAULT_TIMEZONE is set to an invalid value."
-            exit 1
-        fi
-
-        chown -R root:root ${D}
-}
-
-pkg_postinst_${PN} () {
-	etc_lt="$D${sysconfdir}/localtime"
-	src="$D${sysconfdir}/timezone"
-
-	if [ -e ${src} ] ; then
-		tz=$(sed -e 's:#.*::' -e 's:[[:space:]]*::g' -e '/^$/d' "${src}")
-	fi
-	
-	if [ -z "${tz}" ] ; then
-		exit 0
-	fi
-	
-	if [ ! -e "$D${datadir}/zoneinfo/${tz}" ] ; then
-		echo "You have an invalid TIMEZONE setting in ${src}"
-		echo "Your ${etc_lt} has been reset to Universal; enjoy!"
-		tz="Universal"
-		echo "Updating ${etc_lt} with $D${datadir}/zoneinfo/${tz}"
-		if [ -L ${etc_lt} ] ; then
-			rm -f "${etc_lt}"
-		fi
-		ln -s "${datadir}/zoneinfo/${tz}" "${etc_lt}"
-	fi
-}
-
-# Packages primarily organized by directory with a major city
-# in most time zones in the base package
-
-PACKAGES = "tzdata tzdata-misc tzdata-posix tzdata-right tzdata-africa \
-    tzdata-americas tzdata-antarctica tzdata-arctic tzdata-asia \
-    tzdata-atlantic tzdata-australia tzdata-europe tzdata-pacific"
-
-FILES_tzdata-africa += "${datadir}/zoneinfo/Africa/*"
-RPROVIDES_tzdata-africa = "tzdata-africa"
-
-FILES_tzdata-americas += "${datadir}/zoneinfo/America/*  \
-                ${datadir}/zoneinfo/US/*                \
-                ${datadir}/zoneinfo/Brazil/*            \
-                ${datadir}/zoneinfo/Canada/*            \
-                ${datadir}/zoneinfo/Mexico/*            \
-                ${datadir}/zoneinfo/Chile/*"
-RPROVIDES_tzdata-americas = "tzdata-americas"
-
-FILES_tzdata-antarctica += "${datadir}/zoneinfo/Antarctica/*"
-RPROVIDES_tzdata-antarctica = "tzdata-antarctica"
-
-FILES_tzdata-arctic += "${datadir}/zoneinfo/Arctic/*"
-RPROVIDES_tzdata-arctic = "tzdata-arctic"
-
-FILES_tzdata-asia += "${datadir}/zoneinfo/Asia/*        \
-                ${datadir}/zoneinfo/Indian/*            \
-                ${datadir}/zoneinfo/Mideast/*"
-RPROVIDES_tzdata-asia = "tzdata-asia"
-
-FILES_tzdata-atlantic += "${datadir}/zoneinfo/Atlantic/*"
-RPROVIDES_tzdata-atlantic = "tzdata-atlantic"
-
-FILES_tzdata-australia += "${datadir}/zoneinfo/Australia/*"
-RPROVIDES_tzdata-australia = "tzdata-australia"
-
-FILES_tzdata-europe += "${datadir}/zoneinfo/Europe/*"
-RPROVIDES_tzdata-europe = "tzdata-europe"
-
-FILES_tzdata-pacific += "${datadir}/zoneinfo/Pacific/*"
-RPROVIDES_tzdata-pacific = "tzdata-pacific"
-
-FILES_tzdata-posix += "${datadir}/zoneinfo/posix/*"
-RPROVIDES_tzdata-posix = "tzdata-posix"
-
-FILES_tzdata-right += "${datadir}/zoneinfo/right/*"
-RPROVIDES_tzdata-right = "tzdata-right"
-
-
-FILES_tzdata-misc += "${datadir}/zoneinfo/Cuba           \
-                ${datadir}/zoneinfo/Egypt                \
-                ${datadir}/zoneinfo/Eire                 \
-                ${datadir}/zoneinfo/Factory              \
-                ${datadir}/zoneinfo/GB-Eire              \
-                ${datadir}/zoneinfo/Hongkong             \
-                ${datadir}/zoneinfo/Iceland              \
-                ${datadir}/zoneinfo/Iran                 \
-                ${datadir}/zoneinfo/Israel               \
-                ${datadir}/zoneinfo/Jamaica              \
-                ${datadir}/zoneinfo/Japan                \
-                ${datadir}/zoneinfo/Kwajalein            \
-                ${datadir}/zoneinfo/Libya                \
-                ${datadir}/zoneinfo/Navajo               \
-                ${datadir}/zoneinfo/Poland               \
-                ${datadir}/zoneinfo/Portugal             \
-                ${datadir}/zoneinfo/Singapore            \
-                ${datadir}/zoneinfo/Turkey"
-RPROVIDES_tzdata-misc = "tzdata-misc"
-
-
-FILES_${PN} += "${datadir}/zoneinfo/Pacific/Honolulu     \
-                ${datadir}/zoneinfo/America/Anchorage    \
-                ${datadir}/zoneinfo/America/Los_Angeles  \
-                ${datadir}/zoneinfo/America/Denver       \
-                ${datadir}/zoneinfo/America/Chicago      \
-                ${datadir}/zoneinfo/America/New_York     \
-                ${datadir}/zoneinfo/America/Caracas      \
-                ${datadir}/zoneinfo/America/Sao_Paulo    \
-                ${datadir}/zoneinfo/Europe/London        \
-                ${datadir}/zoneinfo/Europe/Paris         \
-                ${datadir}/zoneinfo/Africa/Cairo         \
-                ${datadir}/zoneinfo/Europe/Moscow        \
-                ${datadir}/zoneinfo/Asia/Dubai           \
-                ${datadir}/zoneinfo/Asia/Karachi         \
-                ${datadir}/zoneinfo/Asia/Dhaka           \
-                ${datadir}/zoneinfo/Asia/Bangkok         \
-                ${datadir}/zoneinfo/Asia/Hong_Kong       \
-                ${datadir}/zoneinfo/Asia/Tokyo           \
-                ${datadir}/zoneinfo/Australia/Darwin     \
-                ${datadir}/zoneinfo/Australia/Adelaide   \
-                ${datadir}/zoneinfo/Australia/Brisbane   \
-                ${datadir}/zoneinfo/Australia/Sydney     \
-                ${datadir}/zoneinfo/Pacific/Noumea       \
-                ${datadir}/zoneinfo/CET                  \
-                ${datadir}/zoneinfo/CST6CDT              \
-                ${datadir}/zoneinfo/EET                  \
-                ${datadir}/zoneinfo/EST                  \
-                ${datadir}/zoneinfo/EST5EDT              \
-                ${datadir}/zoneinfo/GB                   \
-                ${datadir}/zoneinfo/GMT                  \
-                ${datadir}/zoneinfo/GMT+0                \
-                ${datadir}/zoneinfo/GMT-0                \
-                ${datadir}/zoneinfo/GMT0                 \
-                ${datadir}/zoneinfo/Greenwich            \
-                ${datadir}/zoneinfo/HST                  \
-                ${datadir}/zoneinfo/MET                  \
-                ${datadir}/zoneinfo/MST                  \
-                ${datadir}/zoneinfo/MST7MDT              \
-                ${datadir}/zoneinfo/NZ                   \
-                ${datadir}/zoneinfo/NZ-CHAT              \
-                ${datadir}/zoneinfo/PRC                  \
-                ${datadir}/zoneinfo/PST8PDT              \
-                ${datadir}/zoneinfo/ROC                  \
-                ${datadir}/zoneinfo/ROK                  \
-                ${datadir}/zoneinfo/UCT                  \
-                ${datadir}/zoneinfo/UTC                  \
-                ${datadir}/zoneinfo/Universal            \
-                ${datadir}/zoneinfo/W-SU                 \
-                ${datadir}/zoneinfo/WET                  \
-                ${datadir}/zoneinfo/Zulu                 \
-                ${datadir}/zoneinfo/zone.tab             \
-                ${datadir}/zoneinfo/zone1970.tab         \
-                ${datadir}/zoneinfo/iso3166.tab          \
-                ${datadir}/zoneinfo/Etc/*"
-
-CONFFILES_${PN} += "${@ "${sysconfdir}/timezone" if bb.utils.to_boolean(d.getVar('INSTALL_TIMEZONE_FILE')) else "" }"
-CONFFILES_${PN} += "${sysconfdir}/localtime"
diff --git a/poky/meta/recipes-extended/tzdata/tzdata_2018g.bb b/poky/meta/recipes-extended/tzdata/tzdata_2018g.bb
new file mode 100644
index 0000000..dba82ac
--- /dev/null
+++ b/poky/meta/recipes-extended/tzdata/tzdata_2018g.bb
@@ -0,0 +1,215 @@
+SUMMARY = "Timezone data"
+HOMEPAGE = "http://www.iana.org/time-zones"
+SECTION = "base"
+LICENSE = "PD & BSD & BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=c679c9d6b02bc2757b3eaf8f53c43fba"
+
+DEPENDS = "tzcode-native"
+
+SRC_URI = "http://www.iana.org/time-zones/repository/releases/tzdata${PV}.tar.gz;name=tzdata"
+UPSTREAM_CHECK_URI = "http://www.iana.org/time-zones"
+
+SRC_URI[tzdata.md5sum] = "e71cb1f9d8d53c43904d79d7aeeedc1b"
+SRC_URI[tzdata.sha256sum] = "02dfde534872f6513ae4553a3388fdae579441e31b862ea99170dfc447f46a16"
+
+inherit allarch
+
+RCONFLICTS_${PN} = "timezones timezone-africa timezone-america timezone-antarctica \
+             timezone-arctic timezone-asia timezone-atlantic \
+             timezone-australia timezone-europe timezone-indian \
+             timezone-iso3166.tab timezone-pacific timezone-zone.tab"
+
+S = "${WORKDIR}"
+
+DEFAULT_TIMEZONE ?= "Universal"
+INSTALL_TIMEZONE_FILE ?= "1"
+
+TZONES= "africa antarctica asia australasia europe northamerica southamerica  \
+         factory etcetera backward systemv \
+        "
+# pacificnew 
+
+do_compile () {
+        for zone in ${TZONES}; do \
+            ${STAGING_BINDIR_NATIVE}/zic -d ${WORKDIR}${datadir}/zoneinfo -L /dev/null \
+                -y ${S}/yearistype.sh ${S}/${zone} ; \
+            ${STAGING_BINDIR_NATIVE}/zic -d ${WORKDIR}${datadir}/zoneinfo/posix -L /dev/null \
+                -y ${S}/yearistype.sh ${S}/${zone} ; \
+            ${STAGING_BINDIR_NATIVE}/zic -d ${WORKDIR}${datadir}/zoneinfo/right -L ${S}/leapseconds \
+                -y ${S}/yearistype.sh ${S}/${zone} ; \
+        done
+}
+
+do_install () {
+        install -d ${D}/$exec_prefix ${D}${datadir}/zoneinfo
+        cp -pPR ${S}/$exec_prefix ${D}/
+        # libc is removing zoneinfo files from package
+        cp -pP "${S}/zone.tab" ${D}${datadir}/zoneinfo
+        cp -pP "${S}/zone1970.tab" ${D}${datadir}/zoneinfo
+        cp -pP "${S}/iso3166.tab" ${D}${datadir}/zoneinfo
+
+        # Install default timezone
+        if [ -e ${D}${datadir}/zoneinfo/${DEFAULT_TIMEZONE} ]; then
+            install -d ${D}${sysconfdir}
+            if [ "${INSTALL_TIMEZONE_FILE}" = "1" ]; then
+                echo ${DEFAULT_TIMEZONE} > ${D}${sysconfdir}/timezone
+            fi
+            ln -s ${datadir}/zoneinfo/${DEFAULT_TIMEZONE} ${D}${sysconfdir}/localtime
+        else
+            bberror "DEFAULT_TIMEZONE is set to an invalid value."
+            exit 1
+        fi
+
+        chown -R root:root ${D}
+}
+
+pkg_postinst_${PN} () {
+	etc_lt="$D${sysconfdir}/localtime"
+	src="$D${sysconfdir}/timezone"
+
+	if [ -e ${src} ] ; then
+		tz=$(sed -e 's:#.*::' -e 's:[[:space:]]*::g' -e '/^$/d' "${src}")
+	fi
+	
+	if [ -z "${tz}" ] ; then
+		exit 0
+	fi
+	
+	if [ ! -e "$D${datadir}/zoneinfo/${tz}" ] ; then
+		echo "You have an invalid TIMEZONE setting in ${src}"
+		echo "Your ${etc_lt} has been reset to Universal; enjoy!"
+		tz="Universal"
+		echo "Updating ${etc_lt} with $D${datadir}/zoneinfo/${tz}"
+		if [ -L ${etc_lt} ] ; then
+			rm -f "${etc_lt}"
+		fi
+		ln -s "${datadir}/zoneinfo/${tz}" "${etc_lt}"
+	fi
+}
+
+# Packages primarily organized by directory with a major city
+# in most time zones in the base package
+
+PACKAGES = "tzdata tzdata-misc tzdata-posix tzdata-right tzdata-africa \
+    tzdata-americas tzdata-antarctica tzdata-arctic tzdata-asia \
+    tzdata-atlantic tzdata-australia tzdata-europe tzdata-pacific"
+
+FILES_tzdata-africa += "${datadir}/zoneinfo/Africa/*"
+RPROVIDES_tzdata-africa = "tzdata-africa"
+
+FILES_tzdata-americas += "${datadir}/zoneinfo/America/*  \
+                ${datadir}/zoneinfo/US/*                \
+                ${datadir}/zoneinfo/Brazil/*            \
+                ${datadir}/zoneinfo/Canada/*            \
+                ${datadir}/zoneinfo/Mexico/*            \
+                ${datadir}/zoneinfo/Chile/*"
+RPROVIDES_tzdata-americas = "tzdata-americas"
+
+FILES_tzdata-antarctica += "${datadir}/zoneinfo/Antarctica/*"
+RPROVIDES_tzdata-antarctica = "tzdata-antarctica"
+
+FILES_tzdata-arctic += "${datadir}/zoneinfo/Arctic/*"
+RPROVIDES_tzdata-arctic = "tzdata-arctic"
+
+FILES_tzdata-asia += "${datadir}/zoneinfo/Asia/*        \
+                ${datadir}/zoneinfo/Indian/*            \
+                ${datadir}/zoneinfo/Mideast/*"
+RPROVIDES_tzdata-asia = "tzdata-asia"
+
+FILES_tzdata-atlantic += "${datadir}/zoneinfo/Atlantic/*"
+RPROVIDES_tzdata-atlantic = "tzdata-atlantic"
+
+FILES_tzdata-australia += "${datadir}/zoneinfo/Australia/*"
+RPROVIDES_tzdata-australia = "tzdata-australia"
+
+FILES_tzdata-europe += "${datadir}/zoneinfo/Europe/*"
+RPROVIDES_tzdata-europe = "tzdata-europe"
+
+FILES_tzdata-pacific += "${datadir}/zoneinfo/Pacific/*"
+RPROVIDES_tzdata-pacific = "tzdata-pacific"
+
+FILES_tzdata-posix += "${datadir}/zoneinfo/posix/*"
+RPROVIDES_tzdata-posix = "tzdata-posix"
+
+FILES_tzdata-right += "${datadir}/zoneinfo/right/*"
+RPROVIDES_tzdata-right = "tzdata-right"
+
+
+FILES_tzdata-misc += "${datadir}/zoneinfo/Cuba           \
+                ${datadir}/zoneinfo/Egypt                \
+                ${datadir}/zoneinfo/Eire                 \
+                ${datadir}/zoneinfo/Factory              \
+                ${datadir}/zoneinfo/GB-Eire              \
+                ${datadir}/zoneinfo/Hongkong             \
+                ${datadir}/zoneinfo/Iceland              \
+                ${datadir}/zoneinfo/Iran                 \
+                ${datadir}/zoneinfo/Israel               \
+                ${datadir}/zoneinfo/Jamaica              \
+                ${datadir}/zoneinfo/Japan                \
+                ${datadir}/zoneinfo/Kwajalein            \
+                ${datadir}/zoneinfo/Libya                \
+                ${datadir}/zoneinfo/Navajo               \
+                ${datadir}/zoneinfo/Poland               \
+                ${datadir}/zoneinfo/Portugal             \
+                ${datadir}/zoneinfo/Singapore            \
+                ${datadir}/zoneinfo/Turkey"
+RPROVIDES_tzdata-misc = "tzdata-misc"
+
+
+FILES_${PN} += "${datadir}/zoneinfo/Pacific/Honolulu     \
+                ${datadir}/zoneinfo/America/Anchorage    \
+                ${datadir}/zoneinfo/America/Los_Angeles  \
+                ${datadir}/zoneinfo/America/Denver       \
+                ${datadir}/zoneinfo/America/Chicago      \
+                ${datadir}/zoneinfo/America/New_York     \
+                ${datadir}/zoneinfo/America/Caracas      \
+                ${datadir}/zoneinfo/America/Sao_Paulo    \
+                ${datadir}/zoneinfo/Europe/London        \
+                ${datadir}/zoneinfo/Europe/Paris         \
+                ${datadir}/zoneinfo/Africa/Cairo         \
+                ${datadir}/zoneinfo/Europe/Moscow        \
+                ${datadir}/zoneinfo/Asia/Dubai           \
+                ${datadir}/zoneinfo/Asia/Karachi         \
+                ${datadir}/zoneinfo/Asia/Dhaka           \
+                ${datadir}/zoneinfo/Asia/Bangkok         \
+                ${datadir}/zoneinfo/Asia/Hong_Kong       \
+                ${datadir}/zoneinfo/Asia/Tokyo           \
+                ${datadir}/zoneinfo/Australia/Darwin     \
+                ${datadir}/zoneinfo/Australia/Adelaide   \
+                ${datadir}/zoneinfo/Australia/Brisbane   \
+                ${datadir}/zoneinfo/Australia/Sydney     \
+                ${datadir}/zoneinfo/Pacific/Noumea       \
+                ${datadir}/zoneinfo/CET                  \
+                ${datadir}/zoneinfo/CST6CDT              \
+                ${datadir}/zoneinfo/EET                  \
+                ${datadir}/zoneinfo/EST                  \
+                ${datadir}/zoneinfo/EST5EDT              \
+                ${datadir}/zoneinfo/GB                   \
+                ${datadir}/zoneinfo/GMT                  \
+                ${datadir}/zoneinfo/GMT+0                \
+                ${datadir}/zoneinfo/GMT-0                \
+                ${datadir}/zoneinfo/GMT0                 \
+                ${datadir}/zoneinfo/Greenwich            \
+                ${datadir}/zoneinfo/HST                  \
+                ${datadir}/zoneinfo/MET                  \
+                ${datadir}/zoneinfo/MST                  \
+                ${datadir}/zoneinfo/MST7MDT              \
+                ${datadir}/zoneinfo/NZ                   \
+                ${datadir}/zoneinfo/NZ-CHAT              \
+                ${datadir}/zoneinfo/PRC                  \
+                ${datadir}/zoneinfo/PST8PDT              \
+                ${datadir}/zoneinfo/ROC                  \
+                ${datadir}/zoneinfo/ROK                  \
+                ${datadir}/zoneinfo/UCT                  \
+                ${datadir}/zoneinfo/UTC                  \
+                ${datadir}/zoneinfo/Universal            \
+                ${datadir}/zoneinfo/W-SU                 \
+                ${datadir}/zoneinfo/WET                  \
+                ${datadir}/zoneinfo/Zulu                 \
+                ${datadir}/zoneinfo/zone.tab             \
+                ${datadir}/zoneinfo/zone1970.tab         \
+                ${datadir}/zoneinfo/iso3166.tab          \
+                ${datadir}/zoneinfo/Etc/*"
+
+CONFFILES_${PN} += "${@ "${sysconfdir}/timezone" if bb.utils.to_boolean(d.getVar('INSTALL_TIMEZONE_FILE')) else "" }"
+CONFFILES_${PN} += "${sysconfdir}/localtime"
diff --git a/poky/meta/recipes-extended/unzip/unzip_6.0.bb b/poky/meta/recipes-extended/unzip/unzip_6.0.bb
index f6a4cb6..daba722 100644
--- a/poky/meta/recipes-extended/unzip/unzip_6.0.bb
+++ b/poky/meta/recipes-extended/unzip/unzip_6.0.bb
@@ -61,4 +61,4 @@
 ALTERNATIVE_${PN} = "unzip"
 ALTERNATIVE_LINK_NAME[unzip] = "${bindir}/unzip"
 
-BBCLASSEXTEND = "native"
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-extended/watchdog/watchdog/watchdog-conf.patch b/poky/meta/recipes-extended/watchdog/watchdog/watchdog-conf.patch
deleted file mode 100644
index ec44c80..0000000
--- a/poky/meta/recipes-extended/watchdog/watchdog/watchdog-conf.patch
+++ /dev/null
@@ -1,16 +0,0 @@
-Signed-off-by: Diego Rondini <diego.ml@zoho.com>
-Upstream-Status: Inappropriate
-
-Index: watchdog-5.15/watchdog.conf
-===================================================================
---- watchdog-5.15.orig/watchdog.conf
-+++ watchdog-5.15/watchdog.conf
-@@ -28,7 +28,7 @@
- #retry-timeout		= 60
- #repair-maximum		= 1
- 
--#watchdog-device	= /dev/watchdog
-+watchdog-device	= /dev/watchdog
- 
- # Defaults compiled into the binary
- #temperature-sensor	=
diff --git a/poky/meta/recipes-extended/watchdog/watchdog/watchdog-init.patch b/poky/meta/recipes-extended/watchdog/watchdog/watchdog-init.patch
deleted file mode 100644
index b2765f1..0000000
--- a/poky/meta/recipes-extended/watchdog/watchdog/watchdog-init.patch
+++ /dev/null
@@ -1,56 +0,0 @@
-Signed-off-by: Diego Rondini <diego.ml@zoho.com>
-Upstream-Status: Inappropriate
-
---- watchdog-5.13.orig/redhat/watchdog.init	2014-11-12 17:18:39.125943000 +0100
-+++ watchdog-5.13/redhat/watchdog.init	2014-11-12 18:27:36.189943000 +0100
-@@ -7,7 +7,7 @@
- #                 Henning P. Schmiedehausen <hps@tanstaafl.de>
- 
- # Source function library.
--. /etc/rc.d/init.d/functions
-+. /etc/init.d/functions
- 
- [ -x /usr/sbin/watchdog -a -e /etc/watchdog.conf ] || exit 0
- 
-@@ -23,22 +23,22 @@
- 
- start() {
- 
--	echo -n $"Starting $prog: "
-+	echo -n "Starting $prog: "
- 	if [ -n "$(pidofproc $prog)" ]; then
--		echo -n $"$prog: already running"
--		echo_failure
-+		echo -n "$prog: already running "
-+		failure
- 		echo
- 		return 1
- 	fi
- 	if [ "$VERBOSE" = "yes" ]; then
--	    daemon /usr/sbin/${prog} -v
-+	    /usr/sbin/${prog} -v
- 	else
--	    daemon /usr/sbin/${prog}
-+	    /usr/sbin/${prog}
-         fi
- 	RETVAL=$?
- 	[ $RETVAL -eq 0 ] && touch $lockfile
--	[ $RETVAL -eq 0 ] && echo_success
--	[ $RETVAL -ne 0 ] && echo_failure
-+	[ $RETVAL -eq 0 ] && success
-+	[ $RETVAL -ne 0 ] && failure
- 	echo
- 	return $RETVAL
- }
-@@ -50,8 +50,10 @@
- 	# and reboot the box.
- 	killproc $prog -TERM
- 	RETVAL=$?
--	echo
- 	[ $RETVAL -eq 0 ] && rm -f $lockfile $pidfile
-+	[ $RETVAL -eq 0 ] && success
-+	[ $RETVAL -ne 0 ] && failure
-+	echo
- 	return $RETVAL
- }
- 
diff --git a/poky/meta/recipes-extended/watchdog/watchdog/watchdog.init b/poky/meta/recipes-extended/watchdog/watchdog/watchdog.init
new file mode 100644
index 0000000..d37107c
--- /dev/null
+++ b/poky/meta/recipes-extended/watchdog/watchdog/watchdog.init
@@ -0,0 +1,110 @@
+#!/bin/sh
+#/etc/init.d/watchdog: start watchdog daemon.
+
+### BEGIN INIT INFO
+# Provides:          watchdog
+# Short-Description: Start software watchdog daemon
+# Required-Start:    $all
+# Required-Stop:     $all
+# Should-Start:      
+# Should-Stop:       
+# Default-Start:     2 3 4 5
+# Default-Stop:      0 1 6
+### END INIT INFO
+
+PATH=/bin:/usr/bin:/sbin:/usr/sbin
+
+test -x /usr/sbin/watchdog || exit 0
+
+# For configuration of the init script use the file
+# /etc/default/watchdog, do not edit this init script.
+
+# Set run_watchdog to 1 to start watchdog or 0 to disable it.
+run_watchdog=0
+
+# Specify additional watchdog options here (see manpage).
+watchdog_options=""
+
+# Specify module to load
+watchdog_module="none"
+
+[ -e /etc/default/watchdog ] && . /etc/default/watchdog
+
+NAME=watchdog
+DAEMON=/usr/sbin/watchdog
+
+STOP_RETRY_SCHEDULE='TERM/10/forever/KILL/1'
+
+. /etc/init.d/functions
+
+# Mock Debian stuff
+log_begin_msg() {
+    echo -n $*
+}
+
+log_end_msg() {
+    if [ "$1" = "0" ]; then
+        echo 'done'
+    else
+        echo 'error'
+    fi
+}
+
+log_daemon_msg() {
+    echo $*
+}
+
+log_progress_msg() {
+    echo $*
+}
+
+case "$1" in
+  start)
+    if [ $run_watchdog = 1 ]
+    then
+    	# do we have to load a module?
+	[ "${watchdog_module:-none}" != "none" ] && /sbin/modprobe $watchdog_module
+
+	# Check /dev/watchdog here because if it does not exist after module loading,
+	# it makes no sense to start the daemon
+	test -e /dev/watchdog || { log_daemon_msg "daemon not start due to lack of /dev/watchdog"; exit 0; }
+
+	log_begin_msg "Starting watchdog daemon..."
+	start-stop-daemon --start --quiet --pidfile /var/run/$NAME.pid \
+             --exec $DAEMON -- $watchdog_options
+	log_end_msg $?
+    fi
+    ;;
+
+  stop)
+    if [ $run_watchdog = 1 ]
+    then
+	log_begin_msg "Stopping watchdog daemon..."
+	start-stop-daemon --stop --quiet --retry $STOP_RETRY_SCHEDULE \
+	    --pidfile /var/run/$NAME.pid
+	
+    fi
+    ;;
+
+  restart)
+    $0 force-reload
+    ;;
+
+  force-reload)
+    if [ $run_watchdog = 0 ]; then exit 0; fi
+    log_daemon_msg "Restarting $NAME"
+    $0 stop
+    $0 start
+    ;;
+
+  status)
+    status "$DAEMON"
+    ;;
+
+  *)
+    echo "Usage: /etc/init.d/watchdog {start|stop|restart|force-reload|status}"
+    exit 1
+
+esac
+
+exit 0
diff --git a/poky/meta/recipes-extended/watchdog/watchdog_5.15.bb b/poky/meta/recipes-extended/watchdog/watchdog_5.15.bb
index 37b37ae..1acab2e 100644
--- a/poky/meta/recipes-extended/watchdog/watchdog_5.15.bb
+++ b/poky/meta/recipes-extended/watchdog/watchdog_5.15.bb
@@ -11,8 +11,7 @@
 SRC_URI = "${SOURCEFORGE_MIRROR}/watchdog/watchdog-${PV}.tar.gz \
            file://0001-Include-linux-param.h-for-EXEC_PAGESIZE-definition.patch \
            file://0001-watchdog-remove-interdependencies-of-watchdog-and-wd.patch \
-           file://watchdog-init.patch \
-           file://watchdog-conf.patch \
+           file://watchdog.init \
            file://wd_keepalive.init \
 "
 
@@ -22,31 +21,35 @@
 UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/watchdog/files/watchdog/"
 UPSTREAM_CHECK_REGEX = "/watchdog/(?P<pver>(\d+[\.\-_]*)+)/"
 
-inherit autotools update-rc.d systemd
+inherit autotools update-rc.d systemd pkgconfig
 
-DEPENDS_append_libc-musl = " libtirpc "
-CFLAGS_append_libc-musl = " -I${STAGING_INCDIR}/tirpc "
-LDFLAGS_append_libc-musl = " -ltirpc "
-EXTRA_OECONF_append_libc-musl = " --disable-nfs "
+DEPENDS += "libtirpc"
+CFLAGS += "-I${STAGING_INCDIR}/tirpc"
+LDFLAGS += "-ltirpc"
+
+EXTRA_OECONF += " --disable-nfs "
 
 INITSCRIPT_PACKAGES = "${PN} ${PN}-keepalive"
 
-INITSCRIPT_NAME_${PN} = "watchdog.sh"
-INITSCRIPT_PARAMS_${PN} = "start 15 1 2 3 4 5 . stop 85 0 6 ."
+INITSCRIPT_NAME_${PN} = "watchdog"
+INITSCRIPT_PARAMS_${PN} = "start 25 1 2 3 4 5 . stop 85 0 6 ."
 
 INITSCRIPT_NAME_${PN}-keepalive = "wd_keepalive"
-INITSCRIPT_PARAMS_${PN}-keepalive = "start 15 1 2 3 4 5 . stop 85 0 6 ."
+INITSCRIPT_PARAMS_${PN}-keepalive = "start 25 1 2 3 4 5 . stop 85 0 6 ."
 
 SYSTEMD_PACKAGES = "${PN} ${PN}-keepalive"
 SYSTEMD_SERVICE_${PN} = "watchdog.service"
 SYSTEMD_SERVICE_${PN}-keepalive = "wd_keepalive.service"
+# When using systemd, consider making use of internal watchdog support of systemd.
+# See RuntimeWatchdogSec in /etc/systemd/system.conf.
+SYSTEMD_AUTO_ENABLE = "disable"
 
 do_install_append() {
 	install -d ${D}${systemd_system_unitdir}
 	install -m 0644 ${S}/debian/watchdog.service ${D}${systemd_system_unitdir}
 	install -m 0644 ${S}/debian/wd_keepalive.service ${D}${systemd_system_unitdir}
 
-	install -D ${S}/redhat/watchdog.init ${D}/${sysconfdir}/init.d/watchdog.sh
+	install -Dm 0755 ${WORKDIR}/watchdog.init ${D}/${sysconfdir}/init.d/watchdog
 	install -Dm 0755 ${WORKDIR}/wd_keepalive.init ${D}${sysconfdir}/init.d/wd_keepalive
 
 	# watchdog.conf is provided by the watchdog-config recipe
diff --git a/poky/meta/recipes-extended/xdg-utils/xdg-utils_1.1.2.bb b/poky/meta/recipes-extended/xdg-utils/xdg-utils_1.1.2.bb
deleted file mode 100644
index 7339289..0000000
--- a/poky/meta/recipes-extended/xdg-utils/xdg-utils_1.1.2.bb
+++ /dev/null
@@ -1,37 +0,0 @@
-SUMMARY = "Basic desktop integration functions"
-HOMEPAGE = "https://www.freedesktop.org/wiki/Software/xdg-utils/"
-DESCRIPTION = "The xdg-utils package is a set of simple scripts that provide basic \
-desktop integration functions for any Free Desktop, such as Linux. \
-They are intended to provide a set of defacto standards. \
-The following scripts are provided at this time: \
-xdg-desktop-icon \
-xdg-desktop-menu \
-xdg-email \
-xdg-icon-resource \
-xdg-mime \
-xdg-open \
-xdg-screensaver \
-xdg-terminal \
-"
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=a5367a90934098d6b05af3b746405014"
-
-SRC_URI = "http://portland.freedesktop.org/download/${BPN}-${PV}.tar.gz \
-           file://0001-Reinstate-xdg-terminal.patch \
-           file://0001-Don-t-build-the-in-script-manual.patch \
-          "
-
-SRC_URI[md5sum] = "361e75eb76c94d19f6f4f330d8ee626b"
-SRC_URI[sha256sum] = "951952e2c6bb21214e0bb54e0dffa057d30f5563300225c24c16fba846258bcc"
-
-UPSTREAM_CHECK_REGEX = "xdg-utils-(?P<pver>((\d+[\.\-_]*)+)((rc|alpha|beta)\d+)?)\.(tar\.gz|tgz)"
-
-# Needs brokensep as this doesn't use automake
-inherit autotools-brokensep distro_features_check
-
-# The xprop requires x11 in DISTRO_FEATURES
-REQUIRED_DISTRO_FEATURES = "x11"
-
-DEPENDS = "xmlto-native libxslt-native"
-RDEPENDS_${PN} += "xprop"
diff --git a/poky/meta/recipes-extended/xdg-utils/xdg-utils_1.1.3.bb b/poky/meta/recipes-extended/xdg-utils/xdg-utils_1.1.3.bb
new file mode 100644
index 0000000..8e46638
--- /dev/null
+++ b/poky/meta/recipes-extended/xdg-utils/xdg-utils_1.1.3.bb
@@ -0,0 +1,37 @@
+SUMMARY = "Basic desktop integration functions"
+HOMEPAGE = "https://www.freedesktop.org/wiki/Software/xdg-utils/"
+DESCRIPTION = "The xdg-utils package is a set of simple scripts that provide basic \
+desktop integration functions for any Free Desktop, such as Linux. \
+They are intended to provide a set of defacto standards. \
+The following scripts are provided at this time: \
+xdg-desktop-icon \
+xdg-desktop-menu \
+xdg-email \
+xdg-icon-resource \
+xdg-mime \
+xdg-open \
+xdg-screensaver \
+xdg-terminal \
+"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=a5367a90934098d6b05af3b746405014"
+
+SRC_URI = "http://portland.freedesktop.org/download/${BPN}-${PV}.tar.gz \
+           file://0001-Reinstate-xdg-terminal.patch \
+           file://0001-Don-t-build-the-in-script-manual.patch \
+          "
+
+SRC_URI[md5sum] = "902042508b626027a3709d105f0b63ff"
+SRC_URI[sha256sum] = "d798b08af8a8e2063ddde6c9fa3398ca81484f27dec642c5627ffcaa0d4051d9"
+
+UPSTREAM_CHECK_REGEX = "xdg-utils-(?P<pver>((\d+[\.\-_]*)+)((rc|alpha|beta)\d+)?)\.(tar\.gz|tgz)"
+
+# Needs brokensep as this doesn't use automake
+inherit autotools-brokensep distro_features_check
+
+# The xprop requires x11 in DISTRO_FEATURES
+REQUIRED_DISTRO_FEATURES = "x11"
+
+DEPENDS = "xmlto-native libxslt-native"
+RDEPENDS_${PN} += "xprop"
diff --git a/poky/meta/recipes-extended/xinetd/xinetd_2.3.15.bb b/poky/meta/recipes-extended/xinetd/xinetd_2.3.15.bb
index 1beb545..6e43f5b 100644
--- a/poky/meta/recipes-extended/xinetd/xinetd_2.3.15.bb
+++ b/poky/meta/recipes-extended/xinetd/xinetd_2.3.15.bb
@@ -6,8 +6,7 @@
 LICENSE = "BSD"
 LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=8ad8615198542444f84d28a6cf226dd8"
 
-DEPENDS = ""
-DEPENDS_append_libc-musl = " libtirpc "
+DEPENDS += "libtirpc"
 PR = "r2"
 
 # Blacklist a bogus tag in upstream check
@@ -42,8 +41,8 @@
 PACKAGECONFIG ??= "tcp-wrappers"
 PACKAGECONFIG[tcp-wrappers] = "--with-libwrap,,tcp-wrappers"
 
-CFLAGS_append_libc-musl = " -I${STAGING_INCDIR}/tirpc "
-LDFLAGS_append_libc-musl = " -ltirpc "
+CFLAGS += "-I${STAGING_INCDIR}/tirpc"
+LDFLAGS += "-ltirpc"
 
 do_configure() {
 	# Looks like configure.in is broken, so we are skipping
diff --git a/poky/meta/recipes-extended/xz/xz_5.2.3.bb b/poky/meta/recipes-extended/xz/xz_5.2.3.bb
deleted file mode 100644
index c0f8b82..0000000
--- a/poky/meta/recipes-extended/xz/xz_5.2.3.bb
+++ /dev/null
@@ -1,36 +0,0 @@
-SUMMARY = "Utilities for managing LZMA compressed files"
-HOMEPAGE = "http://tukaani.org/xz/"
-SECTION = "base"
-
-# The source includes bits of PD, GPLv2, GPLv3, LGPLv2.1+, but the only file
-# which is GPLv3 is an m4 macro which isn't shipped in any of our packages,
-# and the LGPL bits are under lib/, which appears to be used for libgnu, which
-# appears to be used for DOS builds. So we're left with GPLv2+ and PD.
-LICENSE = "GPLv2+ & GPL-3.0-with-autoconf-exception & LGPLv2.1+ & PD"
-LICENSE_${PN} = "GPLv2+"
-LICENSE_${PN}-dev = "GPLv2+"
-LICENSE_${PN}-staticdev = "GPLv2+"
-LICENSE_${PN}-doc = "GPLv2+"
-LICENSE_${PN}-dbg = "GPLv2+"
-LICENSE_${PN}-locale = "GPLv2+"
-LICENSE_liblzma = "PD"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=c475b6c7dca236740ace4bba553e8e1c \
-                    file://COPYING.GPLv2;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-                    file://COPYING.GPLv3;md5=d32239bcb673463ab874e80d47fae504 \
-                    file://COPYING.LGPLv2.1;md5=4fbd65380cdd255951079008b364516c \
-                    file://lib/getopt.c;endline=23;md5=2069b0ee710572c03bb3114e4532cd84 "
-
-SRC_URI = "http://tukaani.org/xz/xz-${PV}.tar.gz"
-SRC_URI[md5sum] = "ef68674fb47a8b8e741b34e429d86e9d"
-SRC_URI[sha256sum] = "71928b357d0a09a12a4b4c5fafca8c31c19b0e7d3b8ebb19622e96f26dbf28cb"
-
-inherit autotools gettext
-
-PACKAGES =+ "liblzma"
-
-FILES_liblzma = "${libdir}/liblzma*${SOLIBS}"
-
-BBCLASSEXTEND = "native nativesdk"
-
-export CONFIG_SHELL="/bin/sh"
diff --git a/poky/meta/recipes-extended/xz/xz_5.2.4.bb b/poky/meta/recipes-extended/xz/xz_5.2.4.bb
new file mode 100644
index 0000000..791746e
--- /dev/null
+++ b/poky/meta/recipes-extended/xz/xz_5.2.4.bb
@@ -0,0 +1,43 @@
+SUMMARY = "Utilities for managing LZMA compressed files"
+HOMEPAGE = "http://tukaani.org/xz/"
+SECTION = "base"
+
+# The source includes bits of PD, GPLv2, GPLv3, LGPLv2.1+, but the only file
+# which is GPLv3 is an m4 macro which isn't shipped in any of our packages,
+# and the LGPL bits are under lib/, which appears to be used for libgnu, which
+# appears to be used for DOS builds. So we're left with GPLv2+ and PD.
+LICENSE = "GPLv2+ & GPL-3.0-with-autoconf-exception & LGPLv2.1+ & PD"
+LICENSE_${PN} = "GPLv2+"
+LICENSE_${PN}-dev = "GPLv2+"
+LICENSE_${PN}-staticdev = "GPLv2+"
+LICENSE_${PN}-doc = "GPLv2+"
+LICENSE_${PN}-dbg = "GPLv2+"
+LICENSE_${PN}-locale = "GPLv2+"
+LICENSE_liblzma = "PD"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=97d554a32881fee0aa283d96e47cb24a \
+                    file://COPYING.GPLv2;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                    file://COPYING.GPLv3;md5=d32239bcb673463ab874e80d47fae504 \
+                    file://COPYING.LGPLv2.1;md5=4fbd65380cdd255951079008b364516c \
+                    file://lib/getopt.c;endline=23;md5=2069b0ee710572c03bb3114e4532cd84 \
+                    "
+
+SRC_URI = "http://tukaani.org/xz/xz-${PV}.tar.gz"
+SRC_URI[md5sum] = "5ace3264bdd00c65eeec2891346f65e6"
+SRC_URI[sha256sum] = "b512f3b726d3b37b6dc4c8570e137b9311e7552e8ccbab4d39d47ce5f4177145"
+UPSTREAM_CHECK_REGEX = "xz-(?P<pver>\d+(\.\d+)+)\.tar"
+
+inherit autotools gettext
+
+PACKAGES =+ "liblzma"
+
+FILES_liblzma = "${libdir}/liblzma*${SOLIBS}"
+
+inherit update-alternatives
+ALTERNATIVE_PRIORITY = "100"
+ALTERNATIVE_${PN} = "xz xzcat unxz \
+                     lzma lzcat unlzma"
+
+BBCLASSEXTEND = "native nativesdk"
+
+export CONFIG_SHELL="/bin/sh"
diff --git a/poky/meta/recipes-gnome/epiphany/epiphany_3.26.6.bb b/poky/meta/recipes-gnome/epiphany/epiphany_3.26.6.bb
deleted file mode 100644
index e250f76..0000000
--- a/poky/meta/recipes-gnome/epiphany/epiphany_3.26.6.bb
+++ /dev/null
@@ -1,22 +0,0 @@
-SUMMARY = "WebKit based web browser for GNOME"
-LICENSE = "GPLv3+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
-
-DEPENDS = "libsoup-2.4 webkitgtk gtk+3 iso-codes avahi libnotify gcr \
-	   gsettings-desktop-schemas gnome-desktop3 libxml2-native \
-	   glib-2.0 glib-2.0-native json-glib"
-
-GNOMEBASEBUILDCLASS = "meson"
-inherit gnomebase gsettings distro_features_check upstream-version-is-even gettext
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI = "${GNOME_MIRROR}/${GNOMEBN}/${@gnome_verdir("${PV}")}/${GNOMEBN}-${PV}.tar.${GNOME_COMPRESS_TYPE};name=archive \
-           file://0002-help-meson.build-disable-the-use-of-yelp.patch \
-           "
-SRC_URI[archive.md5sum] = "8449968366a6f9aaff3ac228ddfc7c66"
-SRC_URI[archive.sha256sum] = "01b16aa55d312ae0f17d3136f90d8c68ac748715f119412fb1917023c6f630a8"
-
-EXTRA_OEMESON += " -Ddistributor_name=${DISTRO}"
-
-FILES_${PN} += "${datadir}/dbus-1 ${datadir}/gnome-shell/search-providers"
-RDEPENDS_${PN} = "iso-codes adwaita-icon-theme"
diff --git a/poky/meta/recipes-gnome/epiphany/epiphany_3.28.3.1.bb b/poky/meta/recipes-gnome/epiphany/epiphany_3.28.3.1.bb
new file mode 100644
index 0000000..b46c9d3
--- /dev/null
+++ b/poky/meta/recipes-gnome/epiphany/epiphany_3.28.3.1.bb
@@ -0,0 +1,22 @@
+SUMMARY = "WebKit based web browser for GNOME"
+LICENSE = "GPLv3+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
+
+DEPENDS = "libsoup-2.4 webkitgtk gtk+3 iso-codes avahi libnotify gcr \
+	   gsettings-desktop-schemas libxml2-native \
+	   glib-2.0 glib-2.0-native json-glib"
+
+GNOMEBASEBUILDCLASS = "meson"
+inherit gnomebase gsettings distro_features_check upstream-version-is-even gettext
+REQUIRED_DISTRO_FEATURES = "x11 opengl"
+
+SRC_URI = "${GNOME_MIRROR}/${GNOMEBN}/${@gnome_verdir("${PV}")}/${GNOMEBN}-${PV}.tar.${GNOME_COMPRESS_TYPE};name=archive \
+           file://0002-help-meson.build-disable-the-use-of-yelp.patch \
+           "
+SRC_URI[archive.md5sum] = "31a4a443e8e22f085a10f80b7e41d5f3"
+SRC_URI[archive.sha256sum] = "690546a701f046c5c2b3a092659589ea6e17cb0f9a81ec3fdb3046b00cede6f7"
+
+EXTRA_OEMESON += " -Ddistributor_name=${DISTRO}"
+
+FILES_${PN} += "${datadir}/dbus-1 ${datadir}/gnome-shell/search-providers ${datadir}/metainfo"
+RDEPENDS_${PN} = "iso-codes adwaita-icon-theme gsettings-desktop-schemas"
diff --git a/poky/meta/recipes-gnome/epiphany/files/0002-help-meson.build-disable-the-use-of-yelp.patch b/poky/meta/recipes-gnome/epiphany/files/0002-help-meson.build-disable-the-use-of-yelp.patch
index 249517d..d4f3cc1 100644
--- a/poky/meta/recipes-gnome/epiphany/files/0002-help-meson.build-disable-the-use-of-yelp.patch
+++ b/poky/meta/recipes-gnome/epiphany/files/0002-help-meson.build-disable-the-use-of-yelp.patch
@@ -1,34 +1,30 @@
-From fc314fc3a66c92fe73e1a0cea4f49d11b29e1f45 Mon Sep 17 00:00:00 2001
+From 0048ae2d225d25cc58f378718ca6f9ddb1a228f9 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Wed, 31 Jan 2018 15:50:38 +0200
-Subject: [PATCH 2/2] help/meson.build: disable the use of yelp
+Subject: [PATCH] help/meson.build: disable the use of yelp
 
 In particular this avoids calling itstool which oe-core doesn't provide.
 
 Upstream-Status: Inappropriate [oe-core specific]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
 ---
- help/meson.build | 10 +++++-----
- 1 file changed, 5 insertions(+), 5 deletions(-)
+ help/meson.build | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
 
 diff --git a/help/meson.build b/help/meson.build
-index f720add..cbfeb1e 100644
+index fddcf4c..f7d76c6 100644
 --- a/help/meson.build
 +++ b/help/meson.build
-@@ -46,8 +46,8 @@ help_linguas = [
-   'sv'
+@@ -32,7 +32,7 @@ help_media = [
+   'media/web-browser.png'
  ]
  
 -gnome.yelp(meson.project_name(),
 -  sources: help_files,
 -  media: help_media,
--  languages: help_linguas,
 -)
 +#gnome.yelp(meson.project_name(),
 +#  sources: help_files,
 +#  media: help_media,
-+#  languages: help_linguas,
 +#)
--- 
-2.15.1
-
diff --git a/poky/meta/recipes-gnome/gcr/files/gcr-add-missing-dependencies-for-vapi.patch b/poky/meta/recipes-gnome/gcr/files/gcr-add-missing-dependencies-for-vapi.patch
deleted file mode 100644
index a205429..0000000
--- a/poky/meta/recipes-gnome/gcr/files/gcr-add-missing-dependencies-for-vapi.patch
+++ /dev/null
@@ -1,51 +0,0 @@
-From e7e0c56ca82031121f192f7f711b78418b154c9f Mon Sep 17 00:00:00 2001
-From: Jackie Huang <jackie.huang@windriver.com>
-Date: Mon, 28 Nov 2016 10:17:34 +0800
-Subject: [PATCH] gcr: add missing dependencies for vapi
-
-According to the vapi_DEPS definition:
-gcr-3.vapi depends on gck-1.vapi,
-gcr-ui-3.vapi depends on gck-1.vapi and gcr-3.vapi
-
-But these dependencies are missing for the make targets,
-so it will fail when build in parallel:
-error: Package `gck-1' not found in specified Vala API directories or GObject-Introspection GIR directories
-error: Package `gcr-3' not found in specified Vala API directories or GObject-Introspection GIR directories
-
-Upstream-Status: Submitted [https://bug775966.bugzilla-attachments.gnome.org/attachment.cgi?id=341791]
-
-Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
----
- gcr/Makefile.am | 2 +-
- ui/Makefile.am  | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/gcr/Makefile.am b/gcr/Makefile.am
-index eda302f..6e78dba 100644
---- a/gcr/Makefile.am
-+++ b/gcr/Makefile.am
-@@ -221,7 +221,7 @@ gir_DATA += Gcr-@GCR_MAJOR@.gir
- 
- if ENABLE_VAPIGEN
- 
--gcr-@GCR_MAJOR@.vapi: Gcr-@GCR_MAJOR@.gir gcr/Gcr-@GCR_MAJOR@.metadata gcr-@GCR_MAJOR@.deps
-+gcr-@GCR_MAJOR@.vapi: Gcr-@GCR_MAJOR@.gir gcr/Gcr-@GCR_MAJOR@.metadata gcr-@GCR_MAJOR@.deps gck-@GCK_MAJOR@.vapi
- 
- VAPIGEN_VAPIS += gcr-@GCR_MAJOR@.vapi
- 
-diff --git a/ui/Makefile.am b/ui/Makefile.am
-index aa52476..6612f0d 100644
---- a/ui/Makefile.am
-+++ b/ui/Makefile.am
-@@ -160,7 +160,7 @@ gir_DATA += GcrUi-@GCR_MAJOR@.gir
- 
- if ENABLE_VAPIGEN
- 
--gcr-ui-@GCR_MAJOR@.vapi: GcrUi-@GCR_MAJOR@.gir ui/GcrUi-@GCR_MAJOR@.metadata gcr-ui-@GCR_MAJOR@.deps
-+gcr-ui-@GCR_MAJOR@.vapi: GcrUi-@GCR_MAJOR@.gir ui/GcrUi-@GCR_MAJOR@.metadata gcr-ui-@GCR_MAJOR@.deps gck-@GCK_MAJOR@.vapi gcr-@GCR_MAJOR@.vapi
- 
- VAPIGEN_VAPIS += gcr-ui-@GCR_MAJOR@.vapi
- 
--- 
-2.8.3
-
diff --git a/poky/meta/recipes-gnome/gcr/gcr_3.20.0.bb b/poky/meta/recipes-gnome/gcr/gcr_3.20.0.bb
deleted file mode 100644
index a68e0f6..0000000
--- a/poky/meta/recipes-gnome/gcr/gcr_3.20.0.bb
+++ /dev/null
@@ -1,26 +0,0 @@
-SUMMARY = "A library for bits of crypto UI and parsing etc"
-HOMEPAGE = "http://www.gnome.org/"
-BUGTRACKER = "https://bugzilla.gnome.org/"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=55ca817ccb7d5b5b66355690e9abc605"
-
-DEPENDS = "intltool-native gtk+3 p11-kit glib-2.0 libgcrypt \
-           ${@bb.utils.contains('GI_DATA_ENABLED', 'True', 'libxslt-native', '', d)}"
-
-inherit gnomebase gtk-icon-cache gtk-doc distro_features_check upstream-version-is-even vala gobject-introspection
-# depends on gtk+3, but also x11 through gtk+-x11
-REQUIRED_DISTRO_FEATURES = "x11"
-
-SRC_URI += "file://gcr-add-missing-dependencies-for-vapi.patch"
-
-SRC_URI[archive.md5sum] = "4314bf89eac293dd0a9d806593ff1b35"
-SRC_URI[archive.sha256sum] = "90572c626d8a708225560c42b4421f7941315247fa1679d4ef569bde7f4bb379"
-
-FILES_${PN} += " \
-    ${datadir}/dbus-1 \
-    ${datadir}/gcr-3 \
-"
-
-# http://errors.yoctoproject.org/Errors/Details/20229/
-ARM_INSTRUCTION_SET = "arm"
diff --git a/poky/meta/recipes-gnome/gcr/gcr_3.28.0.bb b/poky/meta/recipes-gnome/gcr/gcr_3.28.0.bb
new file mode 100644
index 0000000..0796362
--- /dev/null
+++ b/poky/meta/recipes-gnome/gcr/gcr_3.28.0.bb
@@ -0,0 +1,32 @@
+SUMMARY = "A library for bits of crypto UI and parsing etc"
+HOMEPAGE = "http://www.gnome.org/"
+BUGTRACKER = "https://bugzilla.gnome.org/"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=55ca817ccb7d5b5b66355690e9abc605"
+
+DEPENDS = "intltool-native gtk+3 p11-kit glib-2.0 libgcrypt \
+           ${@bb.utils.contains('GI_DATA_ENABLED', 'True', 'libxslt-native', '', d)}"
+
+inherit gnomebase gtk-icon-cache gtk-doc distro_features_check upstream-version-is-even vala gobject-introspection
+# depends on gtk+3, but also x11 through gtk+-x11
+REQUIRED_DISTRO_FEATURES = "x11"
+
+SRC_URI[archive.md5sum] = "5321319307dad34dca2fd52e7c9c01ab"
+SRC_URI[archive.sha256sum] = "15e175d1da7ec486d59749ba34906241c442898118ce224a7b70bf2e849faf0b"
+
+FILES_${PN} += " \
+    ${datadir}/dbus-1 \
+    ${datadir}/gcr-3 \
+"
+
+# http://errors.yoctoproject.org/Errors/Details/20229/
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
+ARM_INSTRUCTION_SET_armv6 = "arm"
+
+# These files may be out of date or missing our fixes
+# libgcrypt.m4 in particular is calling into libgcrypt-config
+do_configure_prepend() {
+    rm -f ${S}/build/m4/*
+}
diff --git a/poky/meta/recipes-gnome/gnome-desktop/gnome-desktop/0001-Disable-libseccomp-sycall-filtering-mechanism.patch b/poky/meta/recipes-gnome/gnome-desktop/gnome-desktop/0001-Disable-libseccomp-sycall-filtering-mechanism.patch
deleted file mode 100644
index 10b0743..0000000
--- a/poky/meta/recipes-gnome/gnome-desktop/gnome-desktop/0001-Disable-libseccomp-sycall-filtering-mechanism.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-From 9dfada06f8d2e02d7a04f793ba6e1d4a2aa5ffb7 Mon Sep 17 00:00:00 2001
-From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Thu, 5 Oct 2017 14:54:17 +0300
-Subject: [PATCH] Disable libseccomp (sycall filtering mechanism)
-
-Upstream forgot to make it optional, and it is not currently used in Yocto
-
-Upstream-Status: Inappropriate [oe-core specific]
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
----
- configure.ac | 11 -----------
- 1 file changed, 11 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index 86bcf1f..8911f19 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -157,17 +157,6 @@ else
- fi
- 
- SECCOMP_PKG=""
--dnl Check for bubblewrap compatible platform
--case $host_os in
--  linux*)
--    PKG_CHECK_MODULES(LIBSECCOMP, [libseccomp])
--    SECCOMP_PKG="libseccomp"
--    AC_DEFINE_UNQUOTED(_GNU_SOURCE, 1, [Define to include GNU extensions])
--    AC_DEFINE_UNQUOTED(HAVE_BWRAP, 1, [Define to 1 if Bubblewrap support is available])
--    AC_DEFINE([ENABLE_SECCOMP], [1], [Define if using seccomp])
--    AC_DEFINE_UNQUOTED(INSTALL_PREFIX, "$prefix", [Path to library install prefix])
--    ;;
--esac
- 
- dnl pkg-config dependency checks
- 
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-gnome/gnome-desktop/gnome-desktop/0001-configure.ac-Remove-gnome-common-macro-calls.patch b/poky/meta/recipes-gnome/gnome-desktop/gnome-desktop/0001-configure.ac-Remove-gnome-common-macro-calls.patch
deleted file mode 100644
index e95393c..0000000
--- a/poky/meta/recipes-gnome/gnome-desktop/gnome-desktop/0001-configure.ac-Remove-gnome-common-macro-calls.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 834bc861921fe0361f2d6a5b5716fc97a9519478 Mon Sep 17 00:00:00 2001
-From: Jussi Kukkonen <jussi.kukkonen@intel.com>
-Date: Thu, 6 Jul 2017 13:13:45 +0300
-Subject: [PATCH] configure.ac: Remove gnome-common macro calls
-
-gnome-common is deprecated and these aren't doing much for us.
-
-Upstreamable fix would probably involve using autoconf-archive:
-Trying to avoid that dependency for now.
-
-Upstream-Status: Inappropriate
-Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
----
- configure.ac | 3 ---
- 1 file changed, 3 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index 7adcf0e..bb7659d 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -71,9 +71,6 @@ AC_SUBST(GNOME_DATE)
- AC_SUBST(GNOME_DATE_COMMENT_START)
- AC_SUBST(GNOME_DATE_COMMENT_END)
- 
--GNOME_COMPILE_WARNINGS([maximum])
--GNOME_MAINTAINER_MODE_DEFINES
--
- AC_ARG_ENABLE(deprecation_flags,
-               [AC_HELP_STRING([--enable-deprecation-flags],
-                               [use *_DISABLE_DEPRECATED flags @<:@default=no@:>@])],,
--- 
-2.1.4
-
diff --git a/poky/meta/recipes-gnome/gnome-desktop/gnome-desktop3_3.26.2.bb b/poky/meta/recipes-gnome/gnome-desktop/gnome-desktop3_3.26.2.bb
deleted file mode 100644
index 879dc9a..0000000
--- a/poky/meta/recipes-gnome/gnome-desktop/gnome-desktop3_3.26.2.bb
+++ /dev/null
@@ -1,29 +0,0 @@
-SUMMARY = "GNOME library for reading .desktop files"
-SECTION = "x11/gnome"
-LICENSE = "GPLv2 & LGPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-                    file://COPYING.LIB;md5=5f30f0716dfdd0d91eb439ebec522ec2"
-
-BPN = "gnome-desktop"
-
-inherit gnome pkgconfig upstream-version-is-even gobject-introspection
-SRC_URI[archive.md5sum] = "6cee2ecd677d87eaa0eb5ebfa7b45fb3"
-SRC_URI[archive.sha256sum] = "f7561a7a313fc474b2c390cd9696df1f5c1e1556080e43f4afe042b1060e5f2a"
-
-SRC_URI += " \
-           file://gnome-desktop-thumbnail-don-t-assume-time_t-is-long.patch \
-           file://0001-configure.ac-Remove-gnome-common-macro-calls.patch \
-           file://0001-Disable-libseccomp-sycall-filtering-mechanism.patch \
-           "
-
-DEPENDS += "intltool-native gsettings-desktop-schemas gconf virtual/libx11 gtk+3 glib-2.0 startup-notification xkeyboard-config iso-codes udev"
-
-inherit distro_features_check gtk-doc
-REQUIRED_DISTRO_FEATURES = "x11"
-
-EXTRA_OECONF = "--disable-desktop-docs"
-
-PACKAGES =+ "libgnome-desktop3"
-FILES_libgnome-desktop3 = "${libdir}/lib*${SOLIBS} ${datadir}/libgnome-desktop*/pnp.ids ${datadir}/gnome/*xml"
-
-RRECOMMENDS_libgnome-desktop3 += "gsettings-desktop-schemas"
diff --git a/poky/meta/recipes-gnome/gnome/adwaita-icon-theme/0001-Don-t-use-AC_CANONICAL_HOST.patch b/poky/meta/recipes-gnome/gnome/adwaita-icon-theme/0001-Don-t-use-AC_CANONICAL_HOST.patch
index 96ec96b..b5992eb 100644
--- a/poky/meta/recipes-gnome/gnome/adwaita-icon-theme/0001-Don-t-use-AC_CANONICAL_HOST.patch
+++ b/poky/meta/recipes-gnome/gnome/adwaita-icon-theme/0001-Don-t-use-AC_CANONICAL_HOST.patch
@@ -1,7 +1,7 @@
-From 88ed996cc9e2b296cacfdbeece4be28a90bab511 Mon Sep 17 00:00:00 2001
+From 9661951838773251d0a914e897e8a0d95ce027f6 Mon Sep 17 00:00:00 2001
 From: Jussi Kukkonen <jussi.kukkonen@intel.com>
 Date: Tue, 30 May 2017 14:55:49 +0300
-Subject: [PATCH 1/2] Don't use AC_CANONICAL_HOST
+Subject: [PATCH] Don't use AC_CANONICAL_HOST
 
 This won't work when building allarch (and is only used to find out if
 target is windows).
@@ -13,13 +13,13 @@
  configure.ac | 1 -
  1 file changed, 1 deletion(-)
 
-Index: adwaita-icon-theme-3.26.1/configure.ac
-===================================================================
---- adwaita-icon-theme-3.26.1.orig/configure.ac
-+++ adwaita-icon-theme-3.26.1/configure.ac
+diff --git a/configure.ac b/configure.ac
+index fb787dc..5caef0c 100644
+--- a/configure.ac
++++ b/configure.ac
 @@ -3,7 +3,6 @@ AC_PREREQ(2.53)
  
- AC_INIT([adwaita-icon-theme], [3.26.1],
+ AC_INIT([adwaita-icon-theme], [3.28.0],
          [http://bugzilla.gnome.org/enter_bug.cgi?product=adwaita-icon-theme])
 -AC_CANONICAL_HOST
  AC_CONFIG_MACRO_DIR([m4])
diff --git a/poky/meta/recipes-gnome/gnome/adwaita-icon-theme_3.26.1.bb b/poky/meta/recipes-gnome/gnome/adwaita-icon-theme_3.26.1.bb
deleted file mode 100644
index 6437d5e..0000000
--- a/poky/meta/recipes-gnome/gnome/adwaita-icon-theme_3.26.1.bb
+++ /dev/null
@@ -1,44 +0,0 @@
-SUMMARY = "GTK+ icon theme"
-HOMEPAGE = "http://ftp.gnome.org/pub/GNOME/sources/adwaita-icon-theme/"
-BUGTRACKER = "https://bugzilla.gnome.org/"
-SECTION = "x11/gnome"
-
-LICENSE = "LGPL-3.0 | CC-BY-SA-3.0"
-LIC_FILES_CHKSUM = "file://COPYING;md5=c84cac88e46fc07647ea07e6c24eeb7c"
-
-inherit allarch autotools pkgconfig gettext gtk-icon-cache upstream-version-is-even
-
-
-MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}"
-SRC_URI = "${GNOME_MIRROR}/${BPN}/${MAJ_VER}/${BPN}-${PV}.tar.xz \
-           file://0001-Don-t-use-AC_CANONICAL_HOST.patch \
-           file://0001-Run-installation-commands-as-shell-jobs.patch \
-           "
-
-SRC_URI[md5sum] = "3ef87e789711e5130792d4b5366c005d"
-SRC_URI[sha256sum] = "28ba7392c7761996efd780779167ea6c940eedfb1bf37cfe9bccb7021f54d79d"
-
-do_install_append() {
-	# Build uses gtk-encode-symbolic-svg to create png versions:
-        # no need to store the svgs anymore.
-	rm -f ${D}${prefix}/share/icons/Adwaita/scalable/*/*-symbolic.svg \
-	      ${D}${prefix}/share/icons/Adwaita/scalable/*/*-symbolic-rtl.svg
-}
-
-PACKAGES = "${PN}-cursors ${PN}-symbolic-hires ${PN}-symbolic ${PN}-hires ${PN}"
-
-RREPLACES_${PN} = "gnome-icon-theme"
-RCONFLICTS_${PN} = "gnome-icon-theme"
-RPROVIDES_${PN} = "gnome-icon-theme"
-
-FILES_${PN}-cursors = "${prefix}/share/icons/Adwaita/cursors/"
-FILES_${PN}-symbolic-hires = "${prefix}/share/icons/Adwaita/96x96/*/*.symbolic.png \
-                              ${prefix}/share/icons/Adwaita/64x64/*/*.symbolic.png \
-                              ${prefix}/share/icons/Adwaita/48x48/*/*.symbolic.png \
-                              ${prefix}/share/icons/Adwaita/32x32/*/*.symbolic.png"
-FILES_${PN}-symbolic = "${prefix}/share/icons/Adwaita/16x16/*/*.symbolic.png \
-                        ${prefix}/share/icons/Adwaita/24x24/*/*.symbolic.png"
-FILES_${PN}-hires = "${prefix}/share/icons/Adwaita/256x256/ \
-                     ${prefix}/share/icons/Adwaita/512x512/"
-FILES_${PN} = "${prefix}/share/icons/Adwaita/ \
-               ${prefix}/share/pkgconfig/adwaita-icon-theme.pc"
diff --git a/poky/meta/recipes-gnome/gnome/adwaita-icon-theme_3.28.0.bb b/poky/meta/recipes-gnome/gnome/adwaita-icon-theme_3.28.0.bb
new file mode 100644
index 0000000..40dd35b
--- /dev/null
+++ b/poky/meta/recipes-gnome/gnome/adwaita-icon-theme_3.28.0.bb
@@ -0,0 +1,44 @@
+SUMMARY = "GTK+ icon theme"
+HOMEPAGE = "http://ftp.gnome.org/pub/GNOME/sources/adwaita-icon-theme/"
+BUGTRACKER = "https://bugzilla.gnome.org/"
+SECTION = "x11/gnome"
+
+LICENSE = "LGPL-3.0 | CC-BY-SA-3.0"
+LIC_FILES_CHKSUM = "file://COPYING;md5=c84cac88e46fc07647ea07e6c24eeb7c"
+
+inherit allarch autotools pkgconfig gettext gtk-icon-cache upstream-version-is-even
+
+
+MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}"
+SRC_URI = "${GNOME_MIRROR}/${BPN}/${MAJ_VER}/${BPN}-${PV}.tar.xz \
+           file://0001-Don-t-use-AC_CANONICAL_HOST.patch \
+           file://0001-Run-installation-commands-as-shell-jobs.patch \
+           "
+
+SRC_URI[md5sum] = "b25b2d82cbebf2cc9cd469457b604f2c"
+SRC_URI[sha256sum] = "7aae8c1dffd6772fd1a21a3d365a0ea28b7c3988bdbbeafbf8742cda68242150"
+
+do_install_append() {
+	# Build uses gtk-encode-symbolic-svg to create png versions:
+        # no need to store the svgs anymore.
+	rm -f ${D}${prefix}/share/icons/Adwaita/scalable/*/*-symbolic.svg \
+	      ${D}${prefix}/share/icons/Adwaita/scalable/*/*-symbolic-rtl.svg
+}
+
+PACKAGES = "${PN}-cursors ${PN}-symbolic-hires ${PN}-symbolic ${PN}-hires ${PN}"
+
+RREPLACES_${PN} = "gnome-icon-theme"
+RCONFLICTS_${PN} = "gnome-icon-theme"
+RPROVIDES_${PN} = "gnome-icon-theme"
+
+FILES_${PN}-cursors = "${prefix}/share/icons/Adwaita/cursors/"
+FILES_${PN}-symbolic-hires = "${prefix}/share/icons/Adwaita/96x96/*/*.symbolic.png \
+                              ${prefix}/share/icons/Adwaita/64x64/*/*.symbolic.png \
+                              ${prefix}/share/icons/Adwaita/48x48/*/*.symbolic.png \
+                              ${prefix}/share/icons/Adwaita/32x32/*/*.symbolic.png"
+FILES_${PN}-symbolic = "${prefix}/share/icons/Adwaita/16x16/*/*.symbolic.png \
+                        ${prefix}/share/icons/Adwaita/24x24/*/*.symbolic.png"
+FILES_${PN}-hires = "${prefix}/share/icons/Adwaita/256x256/ \
+                     ${prefix}/share/icons/Adwaita/512x512/"
+FILES_${PN} = "${prefix}/share/icons/Adwaita/ \
+               ${prefix}/share/pkgconfig/adwaita-icon-theme.pc"
diff --git a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-Relocate-the-repository-directory-for-native-builds.patch b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-Relocate-the-repository-directory-for-native-builds.patch
new file mode 100644
index 0000000..ba85c31
--- /dev/null
+++ b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-Relocate-the-repository-directory-for-native-builds.patch
@@ -0,0 +1,62 @@
+From 4cf37d56fddcc22bcd818f6d470404f56d907f3c Mon Sep 17 00:00:00 2001
+From: Sascha Silbe <x-yo17@se-silbe.de>
+Date: Fri, 8 Jun 2018 13:55:10 +0200
+Subject: [PATCH] Relocate the repository directory for native builds
+
+Instead of hard-coding GOBJECT_INTROSPECTION_LIBDIR when
+gobject-introspection is built, use dladdr() to determine where
+GOBJECT_INTROSPECTION_LIBDIR is and use that path to calculate the
+repository directory.
+
+This fixes gobject-introspection-native accessing paths across build
+directories (e.g. if the build directories use the same shared state
+cache or sstate mirror).
+
+Upstream-Status: Inappropriate
+Signed-off-by: Sascha Silbe <x-yo17@se-silbe.de>
+
+---
+ girepository/girepository.c | 15 +++++++++++++--
+ 1 file changed, 13 insertions(+), 2 deletions(-)
+
+diff --git a/girepository/girepository.c b/girepository/girepository.c
+index c1fa3d3..efa557e 100644
+--- a/girepository/girepository.c
++++ b/girepository/girepository.c
+@@ -21,6 +21,8 @@
+  * Boston, MA 02111-1307, USA.
+  */
+ 
++#define _GNU_SOURCE
++
+ #include "config.h"
+ 
+ #include <stdio.h>
+@@ -34,6 +36,8 @@
+ #include "gitypelib-internal.h"
+ #include "girepository-private.h"
+ 
++#include <dlfcn.h>
++
+ /**
+  * SECTION:girepository
+  * @short_description: GObject Introspection repository manager
+@@ -188,9 +192,16 @@ init_globals (void)
+           g_free (custom_dirs);
+         }
+ 
+-      libdir = GOBJECT_INTROSPECTION_LIBDIR;
++      Dl_info gi_lib_info;
+ 
+-      typelib_dir = g_build_filename (libdir, "girepository-1.0", NULL);
++      if (dladdr (g_irepository_get_default, &gi_lib_info)) {
++        char *libdir = g_path_get_dirname (gi_lib_info.dli_fname);
++        typelib_dir = g_build_filename (libdir, "girepository-1.0", NULL);
++        g_free (libdir);
++      } else {
++        libdir = GOBJECT_INTROSPECTION_LIBDIR;
++        typelib_dir = g_build_filename (libdir, "girepository-1.0", NULL);
++      }
+ 
+       typelib_search_path = g_slist_prepend (typelib_search_path, typelib_dir);
+ 
diff --git a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-Revert-an-incomplete-upstream-attempt-at-cross-compi.patch b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-Revert-an-incomplete-upstream-attempt-at-cross-compi.patch
index 9abaea7..86cd4ea 100644
--- a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-Revert-an-incomplete-upstream-attempt-at-cross-compi.patch
+++ b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-Revert-an-incomplete-upstream-attempt-at-cross-compi.patch
@@ -1,11 +1,12 @@
-From 3a9d1e5ee0aae56fafec0beba2014c19e4ff310c Mon Sep 17 00:00:00 2001
+From ca0fb17e268c176ac89df081b1efa4a42989f014 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Wed, 23 Mar 2016 17:07:28 +0200
-Subject: [PATCH 1/5] Revert an incomplete upstream attempt at cross-compile
+Subject: [PATCH] Revert an incomplete upstream attempt at cross-compile
  support
 
 Upstream-Status: Pending
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
 ---
  common.mk                | 4 ----
  giscanner/gdumpparser.py | 6 ------
@@ -29,10 +30,10 @@
  
  INTROSPECTION_COMPILER_ARGS = \
 diff --git a/giscanner/gdumpparser.py b/giscanner/gdumpparser.py
-index 1134f33..9bdc2bc 100644
+index cd9d94d..b41772c 100644
 --- a/giscanner/gdumpparser.py
 +++ b/giscanner/gdumpparser.py
-@@ -162,12 +162,6 @@ blob containing data gleaned from GObject's primitive introspection."""
+@@ -161,12 +161,6 @@ blob containing data gleaned from GObject's primitive introspection."""
          out_path = os.path.join(self._binary.tmpdir, 'dump.xml')
  
          args = []
@@ -45,6 +46,3 @@
          args.extend(self._binary.args)
          args.append('--introspect-dump=%s,%s' % (in_path, out_path))
  
--- 
-2.7.0
-
diff --git a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-configure.ac-make-GIR_DIR-configurable.patch b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-configure.ac-make-GIR_DIR-configurable.patch
new file mode 100644
index 0000000..e0402f8
--- /dev/null
+++ b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-configure.ac-make-GIR_DIR-configurable.patch
@@ -0,0 +1,68 @@
+configure.ac: make GIR_DIR configurable
+
+Some .gir files such as GLib-2.0.gir are arch related which contain such
+as lengths of pointers that they are different for 64 and 32 bit target.
+It causes install file conflicts for multilib when intall
+gobject-introspection and lib32-gobject-introspection both.
+
+Add configure option 'with-gir-dir-prefix' for autotools to make .gir
+could be installed to a configured path such as ${libdir}. And update
+girdir in .pc files as well.
+
+Upstream-Status: Accepted [https://gitlab.gnome.org/GNOME/gobject-introspection/commit/3301c7e]
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+---
+ configure.ac                              | 7 +++++--
+ gobject-introspection-1.0.pc.in           | 2 +-
+ gobject-introspection-no-export-1.0.pc.in | 2 +-
+ 3 files changed, 7 insertions(+), 4 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index b4294c57..60506947 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -114,9 +114,12 @@ GIR_SUFFIX="gir-1.0"
+ AC_SUBST(GIR_SUFFIX)
+ AC_DEFINE_UNQUOTED(GIR_SUFFIX, "$GIR_SUFFIX", [Name of the gir directory])
+ 
+-GIR_DIR="$EXPANDED_DATADIR/$GIR_SUFFIX"
++AC_ARG_WITH([gir-dir-prefix],
++		[AS_HELP_STRING([--with-gir-dir-prefix], [Directory prefix for gir installation])],
++		[GIR_DIR_PREFIX="$withval"], [GIR_DIR_PREFIX="$EXPANDED_DATADIR"])
++GIR_DIR="$GIR_DIR_PREFIX/$GIR_SUFFIX"
+ AC_SUBST(GIR_DIR)
+-AC_DEFINE_UNQUOTED(GIR_DIR, "$GIR_DIR", [Director prefix for gir installation])
++AC_DEFINE_UNQUOTED(GIR_DIR, "$GIR_DIR", [Directory prefix for gir installation])
+ 
+ PKG_CHECK_MODULES(GLIB, [glib-2.0 >= 2.58.0])
+ 
+diff --git a/gobject-introspection-1.0.pc.in b/gobject-introspection-1.0.pc.in
+index a08b5d27..3409856c 100644
+--- a/gobject-introspection-1.0.pc.in
++++ b/gobject-introspection-1.0.pc.in
+@@ -10,7 +10,7 @@ g_ir_scanner=${bindir}/g-ir-scanner
+ g_ir_compiler=${bindir}/g-ir-compiler@EXEEXT@
+ g_ir_generate=${bindir}/g-ir-generate@EXEEXT@
+ gidatadir=${datadir}/gobject-introspection-1.0
+-girdir=${datadir}/gir-1.0
++girdir=@GIR_DIR@
+ typelibdir=${libdir}/girepository-1.0
+ 
+ Cflags: -I${includedir}/gobject-introspection-1.0 @FFI_PC_CFLAGS@
+diff --git a/gobject-introspection-no-export-1.0.pc.in b/gobject-introspection-no-export-1.0.pc.in
+index d214d22d..745aaade 100644
+--- a/gobject-introspection-no-export-1.0.pc.in
++++ b/gobject-introspection-no-export-1.0.pc.in
+@@ -9,7 +9,7 @@ includedir=@includedir@
+ g_ir_scanner=${bindir}/g-ir-scanner
+ g_ir_compiler=${bindir}/g-ir-compiler@EXEEXT@
+ g_ir_generate=${bindir}/g-ir-generate@EXEEXT@
+-girdir=${datadir}/gir-1.0
++girdir=@GIR_DIR@
+ typelibdir=${libdir}/girepository-1.0
+ 
+ Cflags: -I${includedir}/gobject-introspection-1.0 @FFI_PC_CFLAGS@
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-a-lib-dirs-envvar-option.patch b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-a-lib-dirs-envvar-option.patch
index 4ec527d..e9338e9 100644
--- a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-a-lib-dirs-envvar-option.patch
+++ b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-a-lib-dirs-envvar-option.patch
@@ -1,4 +1,4 @@
-From e48f1e18f5ea41656f0ba10fe61d69d2604b0064 Mon Sep 17 00:00:00 2001
+From 3fea5e83803f4cfef21b2e06e37a6ba56f2bb914 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Wed, 3 Jan 2018 17:02:01 +0200
 Subject: [PATCH] giscanner: add a --lib-dirs-envvar option
@@ -19,7 +19,7 @@
  3 files changed, 7 insertions(+), 3 deletions(-)
 
 diff --git a/giscanner/ccompiler.py b/giscanner/ccompiler.py
-index 29de0ee..928eae8 100644
+index c003828..8a8ba2b 100644
 --- a/giscanner/ccompiler.py
 +++ b/giscanner/ccompiler.py
 @@ -109,7 +109,7 @@ class CCompiler(object):
@@ -32,19 +32,19 @@
          # is being built in the current directory.
  
 @@ -119,7 +119,7 @@ class CCompiler(object):
-         if self.check_is_msvc():
+         if os.name == 'nt':
              runtime_path_envvar = ['LIB', 'PATH']
          else:
--            runtime_path_envvar = ['LD_LIBRARY_PATH']
-+            runtime_path_envvar = ['LD_LIBRARY_PATH'] if not lib_dirs_envvar else [lib_dirs_envvar]
+-            runtime_path_envvar = ['LD_LIBRARY_PATH', 'DYLD_FALLBACK_LIBRARY_PATH']
++            runtime_path_envvar = ['LD_LIBRARY_PATH', 'DYLD_FALLBACK_LIBRARY_PATH'] if not lib_dirs_envvar else [lib_dirs_envvar]
              # Search the current directory first
              # (This flag is not supported nor needed for Visual C++)
              args.append('-L.')
 diff --git a/giscanner/dumper.py b/giscanner/dumper.py
-index 7f77bd2..db96df6 100644
+index 2c668f5..2e515a0 100644
 --- a/giscanner/dumper.py
 +++ b/giscanner/dumper.py
-@@ -259,7 +259,8 @@ class DumpCompiler(object):
+@@ -249,7 +249,8 @@ class DumpCompiler(object):
                                                     libtool,
                                                     self._options.libraries,
                                                     self._options.extra_libraries,
@@ -55,10 +55,10 @@
  
          else:
 diff --git a/giscanner/scannermain.py b/giscanner/scannermain.py
-index 38a45c1..b603850 100755
+index 5cb793e..87227e2 100644
 --- a/giscanner/scannermain.py
 +++ b/giscanner/scannermain.py
-@@ -130,6 +130,9 @@ def _get_option_parser():
+@@ -132,6 +132,9 @@ def _get_option_parser():
      parser.add_option("", "--use-ldd-wrapper",
                        action="store", dest="ldd_wrapper", default=None,
                        help="wrapper to use instead of ldd (useful when cross-compiling)")
@@ -68,6 +68,3 @@
      parser.add_option("", "--program-arg",
                        action="append", dest="program_args", default=[],
                        help="extra arguments to program")
--- 
-2.15.1
-
diff --git a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-ignore-error-return-codes-from-ldd-wrapper.patch b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-ignore-error-return-codes-from-ldd-wrapper.patch
new file mode 100644
index 0000000..9167f04
--- /dev/null
+++ b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-ignore-error-return-codes-from-ldd-wrapper.patch
@@ -0,0 +1,27 @@
+From f128cbeead687bfc6532cc1f2cc3e2dc5a2b5b30 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Wed, 5 Sep 2018 16:46:52 +0200
+Subject: [PATCH] giscanner: ignore error return codes from ldd-wrapper
+
+prelink-rtld, which we use instead of ldd returns 127 when it can't find a library.
+It is not an error per se, but it breaks subprocess.check_output().
+
+Upstream-Status: Inappropriate [oe-core specific]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ giscanner/shlibs.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/giscanner/shlibs.py b/giscanner/shlibs.py
+index 01d21a3..3bd3250 100644
+--- a/giscanner/shlibs.py
++++ b/giscanner/shlibs.py
+@@ -108,7 +108,7 @@ def _resolve_non_libtool(options, binary, libraries):
+             args.extend(['otool', '-L', binary.args[0]])
+         else:
+             args.extend(['ldd', binary.args[0]])
+-        output = subprocess.check_output(args)
++        output = subprocess.run(args, check=False, stdout=subprocess.PIPE).stdout
+         if isinstance(output, bytes):
+             output = output.decode("utf-8", "replace")
+ 
diff --git a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0002-configure.ac-add-host-gi-gi-cross-wrapper-gi-ldd-wra.patch b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0002-configure.ac-add-host-gi-gi-cross-wrapper-gi-ldd-wra.patch
index c682b42..03ef2b0 100644
--- a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0002-configure.ac-add-host-gi-gi-cross-wrapper-gi-ldd-wra.patch
+++ b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0002-configure.ac-add-host-gi-gi-cross-wrapper-gi-ldd-wra.patch
@@ -1,8 +1,8 @@
-From b1503fe2693d602b3e24e4b832dc0934960d5d22 Mon Sep 17 00:00:00 2001
+From a28cc8413b68bec5b4cf2ee5f37b40a8965490a5 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Mon, 19 Oct 2015 18:29:21 +0300
-Subject: [PATCH 2/5] configure.ac: add host-gi, gi-cross-wrapper,
- gi-ldd-wrapper and introspection-data options
+Subject: [PATCH] configure.ac: add host-gi, gi-cross-wrapper, gi-ldd-wrapper
+ and introspection-data options
 
 With the first option, gobject-introspection tools (g-ir-doc-tool and g-ir-scanner)
 that are already installed in the host system will be used for building the source tree.
@@ -25,6 +25,7 @@
 
 Upstream-Status: Pending [review on oe-core list]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
 ---
  Makefile.am       |  2 ++
  common.mk         | 39 +++++++++++++++++++++++++++++++++++++++
@@ -32,10 +33,10 @@
  tests/Makefile.am |  5 ++++-
  4 files changed, 87 insertions(+), 1 deletion(-)
 
-Index: gobject-introspection-1.52.1/Makefile.am
-===================================================================
---- gobject-introspection-1.52.1.orig/Makefile.am
-+++ gobject-introspection-1.52.1/Makefile.am
+diff --git a/Makefile.am b/Makefile.am
+index 44ed115..2a1fa56 100644
+--- a/Makefile.am
++++ b/Makefile.am
 @@ -21,7 +21,9 @@ include Makefile-cmph.am
  include Makefile-girepository.am
  include Makefile-giscanner.am
@@ -44,12 +45,12 @@
  include Makefile-gir.am
 +endif
  include Makefile-tools.am
- include Makefile-msvcproj.am
  
-Index: gobject-introspection-1.52.1/common.mk
-===================================================================
---- gobject-introspection-1.52.1.orig/common.mk
-+++ gobject-introspection-1.52.1/common.mk
+ ## Process this file with automake to produce Makefile.in
+diff --git a/common.mk b/common.mk
+index e26c637..9f3a65f 100644
+--- a/common.mk
++++ b/common.mk
 @@ -6,6 +6,15 @@
  # module itself.
  #
@@ -130,11 +131,11 @@
  
  INTROSPECTION_DOCTOOL_ARGS = \
      --add-include-path=$(srcdir) \
-Index: gobject-introspection-1.52.1/configure.ac
-===================================================================
---- gobject-introspection-1.52.1.orig/configure.ac
-+++ gobject-introspection-1.52.1/configure.ac
-@@ -366,6 +366,48 @@ dnl
+diff --git a/configure.ac b/configure.ac
+index d48e6c3..ed5f8a2 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -367,6 +367,48 @@ dnl
  AM_CONDITIONAL(MSVC_BASE_NO_TOOLSET_SET, [test x$MSVC_BASE_TOOLSET = x])
  AM_CONDITIONAL(MSVC_NO_TOOLSET_SET, [test x$MSVC_TOOLSET = x])
  
@@ -183,10 +184,10 @@
  AC_CONFIG_FILES([
  Makefile
  tests/Makefile
-Index: gobject-introspection-1.52.1/tests/Makefile.am
-===================================================================
---- gobject-introspection-1.52.1.orig/tests/Makefile.am
-+++ gobject-introspection-1.52.1/tests/Makefile.am
+diff --git a/tests/Makefile.am b/tests/Makefile.am
+index 4bdb9c3..10b0f27 100644
+--- a/tests/Makefile.am
++++ b/tests/Makefile.am
 @@ -1,6 +1,9 @@
  include $(top_srcdir)/common.mk
  
diff --git a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0002-g-ir-tools-respect-gir_dir_prefix.patch b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0002-g-ir-tools-respect-gir_dir_prefix.patch
new file mode 100644
index 0000000..5e41767
--- /dev/null
+++ b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0002-g-ir-tools-respect-gir_dir_prefix.patch
@@ -0,0 +1,76 @@
+g-ir-tools: respect gir_dir_prefix
+
+Configure option gir_dir_prefix is used to configure install dir for
+.gir files, so add its value to include file search paths.
+
+Upstream-Status: Accepted [https://gitlab.gnome.org/GNOME/gobject-introspection/commit/3fe995a]
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+---
+ Makefile-tools.am           |  2 +-
+ giscanner/transformer.py    |  1 +
+ tests/warn/warningtester.py |  1 +
+ tools/g-ir-tool-template.in | 10 ++++++++++
+ 6 files changed, 15 insertions(+), 2 deletions(-)
+
+diff --git a/Makefile-tools.am b/Makefile-tools.am
+index c70d9850..fcaf1e01 100644
+--- a/Makefile-tools.am
++++ b/Makefile-tools.am
+@@ -9,7 +9,7 @@ EXTRA_DIST += 				\
+ 	tools/g-ir-tool-template.in \
+ 	tools/meson.build
+ 
+-TOOL_SUBSTITUTIONS = -e s,@libdir\@,$(libdir), -e s,@datarootdir\@,$(datarootdir), -e s,@PYTHON_CMD\@,\/usr\/bin\/env\ $(PYTHON),
++TOOL_SUBSTITUTIONS = -e s,@libdir\@,$(libdir), -e s,@datarootdir\@,$(datarootdir), -e s,@PYTHON_CMD\@,\/usr\/bin\/env\ $(PYTHON), -e s,@GIR_DIR\@,$(GIR_DIR),g
+ 
+ g-ir-scanner: tools/g-ir-tool-template.in _giscanner.la Makefile
+ 	$(AM_V_GEN) sed $(TOOL_SUBSTITUTIONS) -e s,@TOOL_MODULE\@,scannermain, -e s,@TOOL_FUNCTION\@,scanner_main, $< > $@.tmp && mv $@.tmp $@
+diff --git a/giscanner/transformer.py b/giscanner/transformer.py
+index 335e229f..2c412339 100644
+--- a/giscanner/transformer.py
++++ b/giscanner/transformer.py
+@@ -184,6 +184,7 @@ None."""
+     def _get_gi_data_dirs(self):
+         data_dirs = utils.get_system_data_dirs()
+         data_dirs.append(DATADIR)
++        data_dirs.append(GIRDIR)
+         if os.name != 'nt':
+             # For backwards compatibility, was always unconditionally added to the list.
+             data_dirs.append('/usr/share')
+diff --git a/tests/warn/warningtester.py b/tests/warn/warningtester.py
+index f17c8889..be5aec13 100644
+--- a/tests/warn/warningtester.py
++++ b/tests/warn/warningtester.py
+@@ -18,6 +18,7 @@ sys.path.insert(0, path)
+ 
+ # Not correct, but enough to get the tests going uninstalled
+ builtins.__dict__['DATADIR'] = path
++builtins.__dict__['GIRDIR'] = ''
+ 
+ from giscanner.annotationparser import GtkDocCommentBlockParser
+ from giscanner.ast import Include, Namespace
+diff --git a/tools/g-ir-tool-template.in b/tools/g-ir-tool-template.in
+index ed33d16b..b9cf0911 100755
+--- a/tools/g-ir-tool-template.in
++++ b/tools/g-ir-tool-template.in
+@@ -60,6 +60,16 @@ if not os.path.isdir(os.path.join(datadir, 'gir-1.0')):
+ 
+ builtins.__dict__['DATADIR'] = datadir
+ 
++# Respect gir_dir_prefix for meson and autotools
++girdir = ''
++# for meson
++if '@gir_dir_prefix@' and not '@gir_dir_prefix@'.startswith('@'):
++    girdir = os.path.abspath(os.path.join(filedir, '..', '@gir_dir_prefix@'))
++# for autotools
++elif '@GIR_DIR@' and not '@GIR_DIR@'.startswith('@'):
++    girdir = os.path.dirname(os.path.abspath('@GIR_DIR@'))
++builtins.__dict__['GIRDIR'] = girdir
++
+ # Again, relative paths first so that the installation prefix is relocatable
+ pylibdir = os.path.abspath(os.path.join(filedir, '..', 'lib', 'gobject-introspection'))
+ 
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0003-giscanner-add-use-binary-wrapper-option.patch b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0003-giscanner-add-use-binary-wrapper-option.patch
index f21eaca..45fe27a 100644
--- a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0003-giscanner-add-use-binary-wrapper-option.patch
+++ b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0003-giscanner-add-use-binary-wrapper-option.patch
@@ -1,7 +1,7 @@
-From 704b888d0abfb01067352c40156f49f655691c7c Mon Sep 17 00:00:00 2001
+From 46dbe963aa6435591c87e788cdb54bc0daeac42e Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Mon, 19 Oct 2015 18:26:40 +0300
-Subject: [PATCH 3/5] giscanner: add --use-binary-wrapper option
+Subject: [PATCH] giscanner: add --use-binary-wrapper option
 
 With this option, giscanner will use a wrapper executable to run
 binaries it's producing, instead of running them directly. This
@@ -10,15 +10,16 @@
 
 Upstream-Status: Pending [review on oe-core list]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
 ---
  giscanner/scannermain.py | 14 ++++++++++++++
  1 file changed, 14 insertions(+)
 
 diff --git a/giscanner/scannermain.py b/giscanner/scannermain.py
-index 633496f..d684cd0 100755
+index ccb14e9..061def0 100644
 --- a/giscanner/scannermain.py
 +++ b/giscanner/scannermain.py
-@@ -124,6 +124,9 @@ def _get_option_parser():
+@@ -126,6 +126,9 @@ def _get_option_parser():
      parser.add_option("", "--program",
                        action="store", dest="program", default=None,
                        help="program to execute")
@@ -28,7 +29,7 @@
      parser.add_option("", "--program-arg",
                        action="append", dest="program_args", default=[],
                        help="extra arguments to program")
-@@ -419,6 +422,17 @@ def create_binary(transformer, options, args):
+@@ -418,6 +421,17 @@ def create_binary(transformer, options, args):
                                                gdump_parser.get_error_quark_functions())
  
      shlibs = resolve_shlibs(options, binary, options.libraries)
@@ -46,6 +47,3 @@
      gdump_parser.set_introspection_binary(binary)
      gdump_parser.parse()
      return shlibs
--- 
-2.7.0
-
diff --git a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0004-giscanner-add-a-use-ldd-wrapper-option.patch b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0004-giscanner-add-a-use-ldd-wrapper-option.patch
index afb71e7..2e36b64 100644
--- a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0004-giscanner-add-a-use-ldd-wrapper-option.patch
+++ b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0004-giscanner-add-a-use-ldd-wrapper-option.patch
@@ -1,23 +1,24 @@
-From d4ad57fd4a32c4f0d2f0522a3090ef940746431b Mon Sep 17 00:00:00 2001
+From eba2b999e81d81b5f43bb1f0ab33881786bebdec Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Fri, 30 Oct 2015 16:28:46 +0200
-Subject: [PATCH 4/5] giscanner: add a --use-ldd-wrapper option
+Subject: [PATCH] giscanner: add a --use-ldd-wrapper option
 
 This is useful in cross-compile environments where system's ldd
 command does not work on binaries built for a different architecture
 
 Upstream-Status: Pending [review in oe-core]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
 ---
  giscanner/scannermain.py | 3 +++
  giscanner/shlibs.py      | 4 +++-
  2 files changed, 6 insertions(+), 1 deletion(-)
 
 diff --git a/giscanner/scannermain.py b/giscanner/scannermain.py
-index d684cd0..1b3b369 100755
+index 061def0..5cb793e 100644
 --- a/giscanner/scannermain.py
 +++ b/giscanner/scannermain.py
-@@ -127,6 +127,9 @@ def _get_option_parser():
+@@ -129,6 +129,9 @@ def _get_option_parser():
      parser.add_option("", "--use-binary-wrapper",
                        action="store", dest="wrapper", default=None,
                        help="wrapper to use for running programs (useful when cross-compiling)")
@@ -28,10 +29,10 @@
                        action="append", dest="program_args", default=[],
                        help="extra arguments to program")
 diff --git a/giscanner/shlibs.py b/giscanner/shlibs.py
-index c93d20c..c5b5942 100644
+index 7b7b2d0..01d21a3 100644
 --- a/giscanner/shlibs.py
 +++ b/giscanner/shlibs.py
-@@ -105,7 +105,9 @@ def _resolve_non_libtool(options, binary, libraries):
+@@ -102,7 +102,9 @@ def _resolve_non_libtool(options, binary, libraries):
              args.extend(libtool)
              args.append('--mode=execute')
          platform_system = platform.system()
@@ -42,6 +43,3 @@
              args.extend(['otool', '-L', binary.args[0]])
          else:
              args.extend(['ldd', binary.args[0]])
--- 
-2.7.0
-
diff --git a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0005-Prefix-pkg-config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0005-Prefix-pkg-config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch
index 47a18ec..2a31117 100644
--- a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0005-Prefix-pkg-config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch
+++ b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection/0005-Prefix-pkg-config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch
@@ -1,7 +1,7 @@
-From e08b3677dd04d6ec407ba8f74f601b2d51310eff Mon Sep 17 00:00:00 2001
+From a97d060933932e478c03f1de9513b69bc459eefc Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Thu, 8 Oct 2015 18:30:35 +0300
-Subject: [PATCH 5/5] Prefix pkg-config paths with PKG_CONFIG_SYSROOT_DIR
+Subject: [PATCH] Prefix pkg-config paths with PKG_CONFIG_SYSROOT_DIR
  environment variable
 
 This environment variable sets the location of sysroot directory in cross-compilation
@@ -9,16 +9,17 @@
 
 Upstream-Status: Pending [review on oe-core list]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
 ---
  Makefile-gir.am     | 18 +++++++++---------
  m4/introspection.m4 |  8 ++++----
  2 files changed, 13 insertions(+), 13 deletions(-)
 
 diff --git a/Makefile-gir.am b/Makefile-gir.am
-index a09260a..ba6e89e 100644
+index 2cd7358..eaf0afd 100644
 --- a/Makefile-gir.am
 +++ b/Makefile-gir.am
-@@ -55,8 +55,8 @@ else
+@@ -58,8 +58,8 @@ else
  endif
  
  # glib
@@ -29,7 +30,7 @@
  
  GLIB_LIBRARY=glib-2.0
  
-@@ -92,8 +92,8 @@ GLib-2.0.gir: g-ir-scanner g-ir-compiler$(EXEEXT)
+@@ -95,8 +95,8 @@ GLib-2.0.gir: g-ir-scanner g-ir-compiler$(EXEEXT)
  gir/DBusGLib-1.0.typelib: GObject-2.0.gir
  
  # gobject
@@ -40,7 +41,7 @@
  
  GOBJECT_LIBRARY=gobject-2.0
  
-@@ -120,8 +120,8 @@ GObject_2_0_gir_FILES = \
+@@ -123,8 +123,8 @@ GObject_2_0_gir_FILES = \
  BUILT_GIRSOURCES += GObject-2.0.gir
  
  # gmodule
@@ -51,7 +52,7 @@
  
  GMODULE_LIBRARY=gmodule-2.0
  
-@@ -146,13 +146,13 @@ GModule_2_0_gir_FILES = $(GLIB_INCLUDEDIR)/gmodule.h \
+@@ -149,13 +149,13 @@ GModule_2_0_gir_FILES = $(GLIB_INCLUDEDIR)/gmodule.h \
  BUILT_GIRSOURCES += GModule-2.0.gir
  
  # gio
@@ -91,6 +92,3 @@
      fi
      AC_SUBST(INTROSPECTION_SCANNER)
      AC_SUBST(INTROSPECTION_COMPILER)
--- 
-2.7.0
-
diff --git a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection_1.54.1.bb b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection_1.54.1.bb
deleted file mode 100644
index 85c8001..0000000
--- a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection_1.54.1.bb
+++ /dev/null
@@ -1,190 +0,0 @@
-SUMMARY = "Middleware layer between GObject-using C libraries and language bindings"
-HOMEPAGE = "https://wiki.gnome.org/action/show/Projects/GObjectIntrospection"
-BUGTRACKER = "https://bugzilla.gnome.org/"
-SECTION = "libs"
-LICENSE = "LGPLv2+ & GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=90d577535a3898e1ae5dbf0ae3509a8c \
-                    file://tools/compiler.c;endline=20;md5=fc5007fc20022720e6c0b0cdde41fabd \
-                    file://giscanner/sourcescanner.c;endline=22;md5=194d6e0c1d00662f32d030ce44de8d39 \
-                    file://girepository/giregisteredtypeinfo.c;endline=21;md5=661847611ae6979465415f31a759ba27"
-
-SRC_URI = "${GNOME_MIRROR}/${BPN}/1.54/${BPN}-${PV}.tar.xz \
-           file://0001-Revert-an-incomplete-upstream-attempt-at-cross-compi.patch \
-           file://0002-configure.ac-add-host-gi-gi-cross-wrapper-gi-ldd-wra.patch \
-           file://0003-giscanner-add-use-binary-wrapper-option.patch \
-           file://0004-giscanner-add-a-use-ldd-wrapper-option.patch \
-           file://0005-Prefix-pkg-config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch \
-           file://0001-giscanner-add-a-lib-dirs-envvar-option.patch \
-           "
-SRC_URI[md5sum] = "126c29e4d54adbed2ed4e2b04483de41"
-SRC_URI[sha256sum] = "b88ded5e5f064ab58a93aadecd6d58db2ec9d970648534c63807d4f9a7bb877e"
-
-inherit autotools pkgconfig gtk-doc python3native qemu gobject-introspection-data upstream-version-is-even
-BBCLASSEXTEND = "native"
-
-# needed for writing out the qemu wrapper script
-export STAGING_DIR_HOST
-export B
-
-DEPENDS_append = " libffi zlib glib-2.0 python3 flex-native bison-native"
-
-# target build needs qemu to run temporary introspection binaries created
-# on the fly by g-ir-scanner and a native version of itself to run
-# native versions of its own tools during build.
-# Also prelink-rtld is used to find out library dependencies of introspection binaries
-# (standard ldd doesn't work when cross-compiling).
-DEPENDS_class-target_append = " gobject-introspection-native qemu-native prelink-native"
-
-SSTATE_SCAN_FILES += "g-ir-scanner-qemuwrapper g-ir-scanner-wrapper g-ir-compiler-wrapper g-ir-scanner-lddwrapper Gio-2.0.gir postinst-ldsoconf-${PN}"
-
-do_configure_prepend_class-native() {
-        # Tweak the native python scripts so that they don't refer to the
-        # full path of native python binary (the solution is taken from glib-2.0 recipe)
-        # This removes the risk of exceeding Linux kernel's shebang line limit (128 bytes)
-        sed -i -e '1s,#!.*,#!${USRBINPATH}/env python3,' ${S}/tools/g-ir-tool-template.in
-}
-
-do_configure_prepend_class-target() {
-        # Write out a qemu wrapper that will be given to gi-scanner so that it
-        # can run target helper binaries through that.
-        qemu_binary="${@qemu_wrapper_cmdline(d, '$STAGING_DIR_HOST', ['\$GIR_EXTRA_LIBS_PATH','.libs','$STAGING_DIR_HOST/${libdir}','$STAGING_DIR_HOST/${base_libdir}'])}"
-        cat > ${B}/g-ir-scanner-qemuwrapper << EOF
-#!/bin/sh
-# Use a modules directory which doesn't exist so we don't load random things
-# which may then get deleted (or their dependencies) and potentially segfault
-export GIO_MODULE_DIR=${STAGING_LIBDIR}/gio/modules-dummy
-
-$qemu_binary "\$@"
-if [ \$? -ne 0 ]; then
-    echo "If the above error message is about missing .so libraries, then setting up GIR_EXTRA_LIBS_PATH in the recipe should help."
-    echo "(typically like this: GIR_EXTRA_LIBS_PATH=\"$""{B}/something/.libs\" )"
-    exit 1
-fi
-EOF
-        chmod +x ${B}/g-ir-scanner-qemuwrapper
-
-        # Write out a wrapper for g-ir-scanner itself, which will be used when building introspection files
-        # for glib-based packages. This wrapper calls the native version of the scanner, and tells it to use
-        # a qemu wrapper for running transient target binaries produced by the scanner, and an include directory 
-        # from the target sysroot.
-        cat > ${B}/g-ir-scanner-wrapper << EOF
-#!/bin/sh
-# This prevents g-ir-scanner from writing cache data to $HOME
-export GI_SCANNER_DISABLE_CACHE=1
-
-g-ir-scanner --lib-dirs-envvar=GIR_EXTRA_LIBS_PATH --use-binary-wrapper=${STAGING_BINDIR}/g-ir-scanner-qemuwrapper --use-ldd-wrapper=${STAGING_BINDIR}/g-ir-scanner-lddwrapper --add-include-path=${STAGING_DATADIR}/gir-1.0 "\$@"
-EOF
-        chmod +x ${B}/g-ir-scanner-wrapper
-
-        # Write out a wrapper for g-ir-compiler, which runs the target version of it through qemu.
-        # g-ir-compiler writes out the raw content of a C struct to disk, and therefore is architecture dependent.
-        cat > ${B}/g-ir-compiler-wrapper << EOF
-#!/bin/sh
-${STAGING_BINDIR}/g-ir-scanner-qemuwrapper ${STAGING_BINDIR}/g-ir-compiler "\$@"
-EOF
-        chmod +x ${B}/g-ir-compiler-wrapper
-
-        # Write out a wrapper to use instead of ldd, which does not work when a binary is built
-        # for a different architecture
-        cat > ${B}/g-ir-scanner-lddwrapper << EOF
-#!/bin/sh
-prelink-rtld --root=$STAGING_DIR_HOST "\$@"
-EOF
-        chmod +x ${B}/g-ir-scanner-lddwrapper
-
-        # Also tweak the target python scripts so that they don't refer to the
-        # native version of python binary (the solution is taken from glib-2.0 recipe)
-        sed -i -e '1s,#!.*,#!${USRBINPATH}/env python3,' ${S}/tools/g-ir-tool-template.in
-}
-
-# Configure target build to use native tools of itself and to use a qemu wrapper
-# and optionally to generate introspection data
-EXTRA_OECONF_class-target += "--enable-host-gi \
-                              --disable-static \
-                              --enable-gi-cross-wrapper=${B}/g-ir-scanner-qemuwrapper \
-                              --enable-gi-ldd-wrapper=${B}/g-ir-scanner-lddwrapper \
-                              ${@bb.utils.contains('GI_DATA_ENABLED', 'True', '--enable-introspection-data', '--disable-introspection-data', d)} \
-                             "
-
-PACKAGECONFIG ?= ""
-PACKAGECONFIG[doctool] = "--enable-doctool,--disable-doctool,python3-mako,"
-
-do_compile_prepend() {
-        # This prevents g-ir-scanner from writing cache data to $HOME
-        export GI_SCANNER_DISABLE_CACHE=1
-
-        # Needed to run g-ir unit tests, which won't be able to find the built libraries otherwise
-        export GIR_EXTRA_LIBS_PATH=$B/.libs
-}
-
-# Our wrappers need to be available system-wide, because they will be used 
-# to build introspection files for all other gobject-based packages
-do_install_append_class-target() {
-        install -d ${D}${bindir}/
-        install ${B}/g-ir-scanner-qemuwrapper ${D}${bindir}/
-        install ${B}/g-ir-scanner-wrapper ${D}${bindir}/
-        install ${B}/g-ir-compiler-wrapper ${D}${bindir}/
-        install ${B}/g-ir-scanner-lddwrapper ${D}${bindir}/
-}
-
-# .typelib files are needed at runtime and so they go to the main package
-FILES_${PN}_append = " ${libdir}/girepository-*/*.typelib"
-
-# .gir files go to dev package, as they're needed for developing (but not for running)
-# things that depends on introspection.
-FILES_${PN}-dev_append = " ${datadir}/gir-*/*.gir"
-FILES_${PN}-dev_append = " ${datadir}/gir-*/*.rnc"
-
-# These are used by gobject-based packages
-# to generate transient introspection binaries
-FILES_${PN}-dev_append = " ${datadir}/gobject-introspection-1.0/gdump.c \
-               ${datadir}/gobject-introspection-1.0/Makefile.introspection"
-
-# These are used by dependent packages (e.g. pygobject) to build their
-# testsuites.
-FILES_${PN}-dev_append = " ${datadir}/gobject-introspection-1.0/tests/*.c \
-                   ${datadir}/gobject-introspection-1.0/tests/*.h"
-
-FILES_${PN}-dbg += "${libdir}/gobject-introspection/giscanner/.debug/"
-FILES_${PN}-staticdev += "${libdir}/gobject-introspection/giscanner/*.a"
-
-# we need target versions of introspection tools in sysroot so that they can be run via qemu
-# when building introspection files in other packages
-SYSROOT_DIRS_append_class-target = " ${bindir}"
-
-SYSROOT_PREPROCESS_FUNCS_append_class-target = " gi_binaries_sysroot_preprocess"
-gi_binaries_sysroot_preprocess() {
-        # Tweak the binary names in the introspection pkgconfig file, so that it
-        # picks up our wrappers which do the cross-compile and qemu magic.
-        sed -i \
-           -e "s|g_ir_scanner=.*|g_ir_scanner=${bindir}/g-ir-scanner-wrapper|" \
-           -e "s|g_ir_compiler=.*|g_ir_compiler=${bindir}/g-ir-compiler-wrapper|" \
-           ${SYSROOT_DESTDIR}${libdir}/pkgconfig/gobject-introspection-1.0.pc
-}
-
-# Need to ensure ld.so.conf exists so prelink-native works
-# both before we build and if we install from sstate
-do_configure[prefuncs] += "gobject_introspection_preconfigure"
-python gobject_introspection_preconfigure () {
-    oe.utils.write_ld_so_conf(d)
-}
-
-SYSROOT_PREPROCESS_FUNCS_append = " gi_ldsoconf_sysroot_preprocess"
-gi_ldsoconf_sysroot_preprocess () {
-	mkdir -p ${SYSROOT_DESTDIR}${bindir}
-	dest=${SYSROOT_DESTDIR}${bindir}/postinst-ldsoconf-${PN}
-	echo "#!/bin/sh" > $dest
-	echo "mkdir -p ${STAGING_DIR_TARGET}${sysconfdir}" >> $dest
-	echo "echo ${base_libdir} >> ${STAGING_DIR_TARGET}${sysconfdir}/ld.so.conf" >> $dest
-	echo "echo ${libdir} >> ${STAGING_DIR_TARGET}${sysconfdir}/ld.so.conf" >> $dest
-	chmod 755 $dest
-}
-
-# Remove wrapper files from the package, only used for cross-compiling
-PACKAGE_PREPROCESS_FUNCS += "gi_package_preprocess"
-gi_package_preprocess() {
-	rm -f ${PKGD}${bindir}/g-ir-scanner-qemuwrapper
-	rm -f ${PKGD}${bindir}/g-ir-scanner-wrapper
-	rm -f ${PKGD}${bindir}/g-ir-compiler-wrapper
-	rm -f ${PKGD}${bindir}/g-ir-scanner-lddwrapper
-}
diff --git a/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection_1.58.0.bb b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection_1.58.0.bb
new file mode 100644
index 0000000..55ca87d
--- /dev/null
+++ b/poky/meta/recipes-gnome/gobject-introspection/gobject-introspection_1.58.0.bb
@@ -0,0 +1,204 @@
+SUMMARY = "Middleware layer between GObject-using C libraries and language bindings"
+HOMEPAGE = "https://wiki.gnome.org/action/show/Projects/GObjectIntrospection"
+BUGTRACKER = "https://bugzilla.gnome.org/"
+SECTION = "libs"
+LICENSE = "LGPLv2+ & GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=c434e8128a68bedd59b80b2ac1eb1c4a \
+                    file://tools/compiler.c;endline=20;md5=fc5007fc20022720e6c0b0cdde41fabd \
+                    file://giscanner/sourcescanner.c;endline=22;md5=194d6e0c1d00662f32d030ce44de8d39 \
+                    file://girepository/giregisteredtypeinfo.c;endline=21;md5=661847611ae6979465415f31a759ba27 \
+                    "
+
+SRC_URI = "${GNOME_MIRROR}/${BPN}/${@oe.utils.trim_version("${PV}", 2)}/${BPN}-${PV}.tar.xz \
+           file://0001-Revert-an-incomplete-upstream-attempt-at-cross-compi.patch \
+           file://0002-configure.ac-add-host-gi-gi-cross-wrapper-gi-ldd-wra.patch \
+           file://0003-giscanner-add-use-binary-wrapper-option.patch \
+           file://0004-giscanner-add-a-use-ldd-wrapper-option.patch \
+           file://0005-Prefix-pkg-config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch \
+           file://0001-giscanner-add-a-lib-dirs-envvar-option.patch \
+           file://0001-giscanner-ignore-error-return-codes-from-ldd-wrapper.patch \
+           file://0001-configure.ac-make-GIR_DIR-configurable.patch \
+           file://0002-g-ir-tools-respect-gir_dir_prefix.patch \
+           "
+
+SRC_URI[md5sum] = "94fec875276262037bfcd51226db12fe"
+SRC_URI[sha256sum] = "27c1590a32749de0a5481ce897772547043e94bccba4bc0a7edb3d8513e401ec"
+
+SRC_URI_append_class-native = " file://0001-Relocate-the-repository-directory-for-native-builds.patch"
+
+inherit autotools pkgconfig gtk-doc python3native qemu gobject-introspection-data upstream-version-is-even multilib_script
+
+MULTILIB_SCRIPTS = "${PN}:${bindir}/g-ir-annotation-tool ${PN}:${bindir}/g-ir-scanner"
+
+DEPENDS_append = " libffi zlib glib-2.0 python3 flex-native bison-native autoconf-archive"
+
+# target build needs qemu to run temporary introspection binaries created
+# on the fly by g-ir-scanner and a native version of itself to run
+# native versions of its own tools during build.
+# Also prelink-rtld is used to find out library dependencies of introspection binaries
+# (standard ldd doesn't work when cross-compiling).
+DEPENDS_class-target_append = " gobject-introspection-native qemu-native prelink-native"
+
+# needed for writing out the qemu wrapper script
+export STAGING_DIR_HOST
+export B
+
+PACKAGECONFIG ?= ""
+PACKAGECONFIG[doctool] = "--enable-doctool,--disable-doctool,python3-mako,"
+
+# Configure target build to use native tools of itself and to use a qemu wrapper
+# and optionally to generate introspection data
+EXTRA_OECONF_class-target = " \
+    --disable-static \
+    --enable-host-gi \
+    --enable-gi-cross-wrapper=${B}/g-ir-scanner-qemuwrapper \
+    --enable-gi-ldd-wrapper=${B}/g-ir-scanner-lddwrapper \
+    ${@bb.utils.contains('GI_DATA_ENABLED', 'True', '--enable-introspection-data', '--disable-introspection-data', d)} \
+    ${@'--with-gir-dir-prefix=${libdir}' if d.getVar('MULTILIBS') else ''} \
+"
+
+# Need to ensure ld.so.conf exists so prelink-native works
+# both before we build and if we install from sstate
+do_configure[prefuncs] += "gobject_introspection_preconfigure"
+python gobject_introspection_preconfigure () {
+    oe.utils.write_ld_so_conf(d)
+}
+
+do_configure_prepend_class-native() {
+        # Tweak the native python scripts so that they don't refer to the
+        # full path of native python binary (the solution is taken from glib-2.0 recipe)
+        # This removes the risk of exceeding Linux kernel's shebang line limit (128 bytes)
+        sed -i -e '1s,#!.*,#!${USRBINPATH}/env python3,' ${S}/tools/g-ir-tool-template.in
+}
+
+do_configure_prepend_class-target() {
+        # Write out a qemu wrapper that will be given to gi-scanner so that it
+        # can run target helper binaries through that.
+        qemu_binary="${@qemu_wrapper_cmdline(d, '$STAGING_DIR_HOST', ['\$GIR_EXTRA_LIBS_PATH','.libs','$STAGING_DIR_HOST/${libdir}','$STAGING_DIR_HOST/${base_libdir}'])}"
+        cat > ${B}/g-ir-scanner-qemuwrapper << EOF
+#!/bin/sh
+# Use a modules directory which doesn't exist so we don't load random things
+# which may then get deleted (or their dependencies) and potentially segfault
+export GIO_MODULE_DIR=${STAGING_LIBDIR}/gio/modules-dummy
+
+$qemu_binary "\$@"
+if [ \$? -ne 0 ]; then
+    echo "If the above error message is about missing .so libraries, then setting up GIR_EXTRA_LIBS_PATH in the recipe should help."
+    echo "(typically like this: GIR_EXTRA_LIBS_PATH=\"$""{B}/something/.libs\" )"
+    exit 1
+fi
+EOF
+        chmod +x ${B}/g-ir-scanner-qemuwrapper
+
+        # Write out a wrapper for g-ir-scanner itself, which will be used when building introspection files
+        # for glib-based packages. This wrapper calls the native version of the scanner, and tells it to use
+        # a qemu wrapper for running transient target binaries produced by the scanner, and an include directory 
+        # from the target sysroot.
+        cat > ${B}/g-ir-scanner-wrapper << EOF
+#!/bin/sh
+# This prevents g-ir-scanner from writing cache data to $HOME
+export GI_SCANNER_DISABLE_CACHE=1
+
+g-ir-scanner --lib-dirs-envvar=GIR_EXTRA_LIBS_PATH --use-binary-wrapper=${STAGING_BINDIR}/g-ir-scanner-qemuwrapper --use-ldd-wrapper=${STAGING_BINDIR}/g-ir-scanner-lddwrapper --add-include-path=${STAGING_DATADIR}/gir-1.0 --add-include-path=${STAGING_LIBDIR}/gir-1.0 "\$@"
+EOF
+        chmod +x ${B}/g-ir-scanner-wrapper
+
+        # Write out a wrapper for g-ir-compiler, which runs the target version of it through qemu.
+        # g-ir-compiler writes out the raw content of a C struct to disk, and therefore is architecture dependent.
+        cat > ${B}/g-ir-compiler-wrapper << EOF
+#!/bin/sh
+${STAGING_BINDIR}/g-ir-scanner-qemuwrapper ${STAGING_BINDIR}/g-ir-compiler "\$@"
+EOF
+        chmod +x ${B}/g-ir-compiler-wrapper
+
+        # Write out a wrapper to use instead of ldd, which does not work when a binary is built
+        # for a different architecture
+        cat > ${B}/g-ir-scanner-lddwrapper << EOF
+#!/bin/sh
+prelink-rtld --root=$STAGING_DIR_HOST "\$@"
+EOF
+        chmod +x ${B}/g-ir-scanner-lddwrapper
+
+        # Also tweak the target python scripts so that they don't refer to the
+        # native version of python binary (the solution is taken from glib-2.0 recipe)
+        sed -i -e '1s,#!.*,#!${USRBINPATH}/env python3,' ${S}/tools/g-ir-tool-template.in
+}
+
+do_compile_prepend() {
+        # This prevents g-ir-scanner from writing cache data to $HOME
+        export GI_SCANNER_DISABLE_CACHE=1
+
+        # Needed to run g-ir unit tests, which won't be able to find the built libraries otherwise
+        export GIR_EXTRA_LIBS_PATH=$B/.libs
+}
+
+# Our wrappers need to be available system-wide, because they will be used 
+# to build introspection files for all other gobject-based packages
+do_install_append_class-target() {
+        install -d ${D}${bindir}/
+        install ${B}/g-ir-scanner-qemuwrapper ${D}${bindir}/
+        install ${B}/g-ir-scanner-wrapper ${D}${bindir}/
+        install ${B}/g-ir-compiler-wrapper ${D}${bindir}/
+        install ${B}/g-ir-scanner-lddwrapper ${D}${bindir}/
+}
+
+# we need target versions of introspection tools in sysroot so that they can be run via qemu
+# when building introspection files in other packages
+SYSROOT_DIRS_append_class-target = " ${bindir}"
+
+SYSROOT_PREPROCESS_FUNCS_append_class-target = " gi_binaries_sysroot_preprocess"
+gi_binaries_sysroot_preprocess() {
+        # Tweak the binary names in the introspection pkgconfig file, so that it
+        # picks up our wrappers which do the cross-compile and qemu magic.
+        sed -i \
+           -e "s|g_ir_scanner=.*|g_ir_scanner=${bindir}/g-ir-scanner-wrapper|" \
+           -e "s|g_ir_compiler=.*|g_ir_compiler=${bindir}/g-ir-compiler-wrapper|" \
+           ${SYSROOT_DESTDIR}${libdir}/pkgconfig/gobject-introspection-1.0.pc
+}
+
+SYSROOT_PREPROCESS_FUNCS_append = " gi_ldsoconf_sysroot_preprocess"
+gi_ldsoconf_sysroot_preprocess () {
+	mkdir -p ${SYSROOT_DESTDIR}${bindir}
+	dest=${SYSROOT_DESTDIR}${bindir}/postinst-ldsoconf-${PN}
+	echo "#!/bin/sh" > $dest
+	echo "mkdir -p ${STAGING_DIR_TARGET}${sysconfdir}" >> $dest
+	echo "echo ${base_libdir} >> ${STAGING_DIR_TARGET}${sysconfdir}/ld.so.conf" >> $dest
+	echo "echo ${libdir} >> ${STAGING_DIR_TARGET}${sysconfdir}/ld.so.conf" >> $dest
+	chmod 755 $dest
+}
+
+# Remove wrapper files from the package, only used for cross-compiling
+PACKAGE_PREPROCESS_FUNCS += "gi_package_preprocess"
+gi_package_preprocess() {
+	rm -f ${PKGD}${bindir}/g-ir-scanner-qemuwrapper
+	rm -f ${PKGD}${bindir}/g-ir-scanner-wrapper
+	rm -f ${PKGD}${bindir}/g-ir-compiler-wrapper
+	rm -f ${PKGD}${bindir}/g-ir-scanner-lddwrapper
+}
+
+SSTATE_SCAN_FILES += "g-ir-scanner-qemuwrapper g-ir-scanner-wrapper g-ir-compiler-wrapper g-ir-scanner-lddwrapper Gio-2.0.gir postinst-ldsoconf-${PN}"
+
+# .typelib files are needed at runtime and so they go to the main package
+FILES_${PN}_append = " ${libdir}/girepository-*/*.typelib"
+
+# .gir files go to dev package, as they're needed for developing (but not for running)
+# things that depends on introspection.
+FILES_${PN}-dev_append = " ${datadir}/gir-*/*.gir ${libdir}/gir-*/*.gir"
+FILES_${PN}-dev_append = " ${datadir}/gir-*/*.rnc"
+
+# These are used by gobject-based packages
+# to generate transient introspection binaries
+FILES_${PN}-dev_append = " ${datadir}/gobject-introspection-1.0/gdump.c \
+                           ${datadir}/gobject-introspection-1.0/Makefile.introspection"
+
+# These are used by dependent packages (e.g. pygobject) to build their
+# testsuites.
+FILES_${PN}-dev_append = " ${datadir}/gobject-introspection-1.0/tests/*.c \
+                           ${datadir}/gobject-introspection-1.0/tests/*.h"
+
+FILES_${PN}-dbg += "${libdir}/gobject-introspection/giscanner/.debug/"
+FILES_${PN}-staticdev += "${libdir}/gobject-introspection/giscanner/*.a"
+
+RDEPENDS_${PN} = "python3-pickle python3-xml"
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-gnome/gsettings-desktop-schemas/gsettings-desktop-schemas_3.24.1.bb b/poky/meta/recipes-gnome/gsettings-desktop-schemas/gsettings-desktop-schemas_3.24.1.bb
deleted file mode 100644
index b61fd24..0000000
--- a/poky/meta/recipes-gnome/gsettings-desktop-schemas/gsettings-desktop-schemas_3.24.1.bb
+++ /dev/null
@@ -1,13 +0,0 @@
-SUMMARY = "GNOME desktop-wide GSettings schemas"
-HOMEPAGE = "http://live.gnome.org/gsettings-desktop-schemas"
-BUGTRACKER = "https://bugzilla.gnome.org/"
-
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
-
-DEPENDS = "glib-2.0 intltool-native"
-
-inherit gnomebase gsettings gettext gobject-introspection upstream-version-is-even
-
-SRC_URI[archive.md5sum] = "796b6ac1eff450261edd521b72e7fe6d"
-SRC_URI[archive.sha256sum] = "76a3fa309f9de6074d66848987214f0b128124ba7184c958c15ac78a8ac7eea7"
diff --git a/poky/meta/recipes-gnome/gsettings-desktop-schemas/gsettings-desktop-schemas_3.28.0.bb b/poky/meta/recipes-gnome/gsettings-desktop-schemas/gsettings-desktop-schemas_3.28.0.bb
new file mode 100644
index 0000000..c2b3cd8
--- /dev/null
+++ b/poky/meta/recipes-gnome/gsettings-desktop-schemas/gsettings-desktop-schemas_3.28.0.bb
@@ -0,0 +1,13 @@
+SUMMARY = "GNOME desktop-wide GSettings schemas"
+HOMEPAGE = "http://live.gnome.org/gsettings-desktop-schemas"
+BUGTRACKER = "https://bugzilla.gnome.org/"
+
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
+
+DEPENDS = "glib-2.0 intltool-native"
+
+inherit gnomebase gsettings gettext gobject-introspection upstream-version-is-even
+
+SRC_URI[archive.md5sum] = "370610e29b37d063ede3ef0f29c06eb9"
+SRC_URI[archive.sha256sum] = "4cb4cd7790b77e5542ec75275237613ad22f3a1f2f41903a298cf6cc996a9167"
diff --git a/poky/meta/recipes-gnome/gtk+/gtk+.inc b/poky/meta/recipes-gnome/gtk+/gtk+.inc
index 558bc48..14ed8d8 100644
--- a/poky/meta/recipes-gnome/gtk+/gtk+.inc
+++ b/poky/meta/recipes-gnome/gtk+/gtk+.inc
@@ -90,6 +90,10 @@
 	install -m 0644 ${S}/gtk/gtkfilesystemmodel.h    ${D}${includedir}/gtk-2.0/gtk/
 
 	mv ${D}${bindir}/gtk-update-icon-cache ${D}${bindir}/gtk-update-icon-cache-2.0
+
+    # duplicate gtk-query-immodules for post install script update_gtk_immodules_cache
+    mkdir -p ${D}${libexecdir}
+    ln ${D}${bindir}/gtk-query-immodules-2.0 ${D}${libexecdir}/${MLPREFIX}gtk-query-immodules-2.0
 }
 
 SYSROOT_PREPROCESS_FUNCS += "gtk_sysroot_preprocess"
diff --git a/poky/meta/recipes-gnome/gtk+/gtk+/0001-Do-not-look-into-HOME-when-looking-for-gtk-modules.patch b/poky/meta/recipes-gnome/gtk+/gtk+/0001-Do-not-look-into-HOME-when-looking-for-gtk-modules.patch
new file mode 100644
index 0000000..83be39c
--- /dev/null
+++ b/poky/meta/recipes-gnome/gtk+/gtk+/0001-Do-not-look-into-HOME-when-looking-for-gtk-modules.patch
@@ -0,0 +1,29 @@
+From 34ce93e1c50bfb88f92a687d4f82de55584f3f6a Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Wed, 11 Apr 2018 14:20:39 +0300
+Subject: [PATCH] Do not look into $HOME when looking for gtk modules
+
+On the host it causes host contamination, on the target it's a
+potential security issue. Gtk+3 has already removed this.
+
+Upstream-Status: Inappropriate [gtk2 is in maintenance mode]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ gtk/gtkmodules.c | 4 ----
+ 1 file changed, 4 deletions(-)
+
+diff --git a/gtk/gtkmodules.c b/gtk/gtkmodules.c
+index 50729b6..e09b583 100644
+--- a/gtk/gtkmodules.c
++++ b/gtk/gtkmodules.c
+@@ -65,10 +65,6 @@ get_module_path (void)
+   if (result)
+     return result;
+ 
+-  home_dir = g_get_home_dir();
+-  if (home_dir)
+-    home_gtk_dir = g_build_filename (home_dir, ".gtk-2.0", NULL);
+-
+   module_path_env = g_getenv ("GTK_PATH");
+   exe_prefix = g_getenv ("GTK_EXE_PREFIX");
+ 
diff --git a/poky/meta/recipes-gnome/gtk+/gtk+3.inc b/poky/meta/recipes-gnome/gtk+/gtk+3.inc
index 420ead2..6331a43 100644
--- a/poky/meta/recipes-gnome/gtk+/gtk+3.inc
+++ b/poky/meta/recipes-gnome/gtk+/gtk+3.inc
@@ -53,6 +53,10 @@
 
 do_install_append() {
 	mv ${D}${bindir}/gtk-update-icon-cache ${D}${bindir}/gtk-update-icon-cache-3.0
+
+    # duplicate gtk-query-immodules for post install script update_gtk_immodules_cache
+    mkdir -p ${D}${libexecdir}
+    ln ${D}${bindir}/gtk-query-immodules-3.0 ${D}${libexecdir}/${MLPREFIX}gtk-query-immodules-3.0
 }
 
 PACKAGES =+ "${PN}-demo"
diff --git a/poky/meta/recipes-gnome/gtk+/gtk+3_3.22.28.bb b/poky/meta/recipes-gnome/gtk+/gtk+3_3.22.28.bb
deleted file mode 100644
index 864e826..0000000
--- a/poky/meta/recipes-gnome/gtk+/gtk+3_3.22.28.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-require gtk+3.inc
-
-MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}"
-
-SRC_URI = "http://ftp.gnome.org/pub/gnome/sources/gtk+/${MAJ_VER}/gtk+-${PV}.tar.xz \
-           file://0001-Hardcoded-libtool.patch \
-           file://0002-Do-not-try-to-initialize-GL-without-libGL.patch \
-           file://0003-Add-disable-opengl-configure-option.patch \
-          "
-SRC_URI[md5sum] = "8c1f5ab987ddc7dab3e59660f89dcd9b"
-SRC_URI[sha256sum] = "d299612b018cfed7b2c689168ab52b668023708e17c335eb592260d186f15e1f"
-
-S = "${WORKDIR}/gtk+-${PV}"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2 \
-                    file://gtk/gtk.h;endline=25;md5=1d8dc0fccdbfa26287a271dce88af737 \
-                    file://gdk/gdk.h;endline=25;md5=c920ce39dc88c6f06d3e7c50e08086f2 \
-                    file://tests/testgtk.c;endline=25;md5=cb732daee1d82af7a2bf953cf3cf26f1"
diff --git a/poky/meta/recipes-gnome/gtk+/gtk+3_3.22.30.bb b/poky/meta/recipes-gnome/gtk+/gtk+3_3.22.30.bb
new file mode 100644
index 0000000..697b518
--- /dev/null
+++ b/poky/meta/recipes-gnome/gtk+/gtk+3_3.22.30.bb
@@ -0,0 +1,18 @@
+require gtk+3.inc
+
+MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}"
+
+SRC_URI = "http://ftp.gnome.org/pub/gnome/sources/gtk+/${MAJ_VER}/gtk+-${PV}.tar.xz \
+           file://0001-Hardcoded-libtool.patch \
+           file://0002-Do-not-try-to-initialize-GL-without-libGL.patch \
+           file://0003-Add-disable-opengl-configure-option.patch \
+          "
+SRC_URI[md5sum] = "61e60dc073e0a6893c72043d20579dc0"
+SRC_URI[sha256sum] = "a1a4a5c12703d4e1ccda28333b87ff462741dc365131fbc94c218ae81d9a6567"
+
+S = "${WORKDIR}/gtk+-${PV}"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2 \
+                    file://gtk/gtk.h;endline=25;md5=1d8dc0fccdbfa26287a271dce88af737 \
+                    file://gdk/gdk.h;endline=25;md5=c920ce39dc88c6f06d3e7c50e08086f2 \
+                    file://tests/testgtk.c;endline=25;md5=cb732daee1d82af7a2bf953cf3cf26f1"
diff --git a/poky/meta/recipes-gnome/gtk+/gtk+_2.24.32.bb b/poky/meta/recipes-gnome/gtk+/gtk+_2.24.32.bb
index 2070358..89fca73 100644
--- a/poky/meta/recipes-gnome/gtk+/gtk+_2.24.32.bb
+++ b/poky/meta/recipes-gnome/gtk+/gtk+_2.24.32.bb
@@ -10,7 +10,8 @@
            file://toggle-font.diff;striplevel=0 \
            file://doc-fixes.patch \
            file://strict-prototypes.patch \
-	  "
+           file://0001-Do-not-look-into-HOME-when-looking-for-gtk-modules.patch \
+           "
 
 SRC_URI[md5sum] = "d5742aa42275203a499b59b4c382a784"
 SRC_URI[sha256sum] = "b6c8a93ddda5eabe3bfee1eb39636c9a03d2a56c7b62828b359bf197943c582e"
diff --git a/poky/meta/recipes-gnome/gtk+/gtk-icon-utils-native_3.22.28.bb b/poky/meta/recipes-gnome/gtk+/gtk-icon-utils-native_3.22.28.bb
deleted file mode 100644
index 942c047..0000000
--- a/poky/meta/recipes-gnome/gtk+/gtk-icon-utils-native_3.22.28.bb
+++ /dev/null
@@ -1,63 +0,0 @@
-SUMMARY = "Native icon utils for GTK+"
-DESCRIPTION = "gtk-update-icon-cache and gtk-encode-symbolic-svg built from GTK+ natively, for build time and on-host postinst script execution."
-SECTION = "libs"
-
-DEPENDS = "glib-2.0-native gdk-pixbuf-native librsvg-native"
-
-LICENSE = "LGPLv2 & LGPLv2+ & LGPLv2.1+"
-
-MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}"
-
-SRC_URI = "http://ftp.gnome.org/pub/gnome/sources/gtk+/${MAJ_VER}/gtk+-${PV}.tar.xz \
-          file://Remove-Gdk-dependency-from-gtk-encode-symbolic-svg.patch"
-SRC_URI[md5sum] = "8c1f5ab987ddc7dab3e59660f89dcd9b"
-SRC_URI[sha256sum] = "d299612b018cfed7b2c689168ab52b668023708e17c335eb592260d186f15e1f"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2 \
-                    file://gtk/gtk.h;endline=25;md5=1d8dc0fccdbfa26287a271dce88af737 \
-                    file://gdk/gdk.h;endline=25;md5=c920ce39dc88c6f06d3e7c50e08086f2 \
-                    file://tests/testgtk.c;endline=25;md5=cb732daee1d82af7a2bf953cf3cf26f1"
-
-S = "${WORKDIR}/gtk+-${PV}"
-
-inherit pkgconfig native
-
-# versions >= 3.90 are development versions, otherwise like upstream-version-is-even
-UPSTREAM_CHECK_REGEX = "[^\d\.](?P<pver>3\.([1-8]?[02468])+(\.\d+)+)\.tar"
-
-PKG_CONFIG_FOR_BUILD = "${STAGING_BINDIR_NATIVE}/pkg-config-native"
-
-do_configure() {
-	# Quite ugly but defines enough to compile the tools.
-	if ! test -f gtk/config.h; then
-		echo "#define GETTEXT_PACKAGE \"gtk30\"" >> gtk/config.h
-		echo "#define HAVE_UNISTD_H 1" >> gtk/config.h
-		echo "#define HAVE_FTW_H 1" >> gtk/config.h
-	fi
-	if ! test -f gdk/config.h; then
-		touch gdk/config.h
-	fi
-}
-
-do_compile() {
-	${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS} \
-		${S}/gtk/updateiconcache.c \
-		$(${PKG_CONFIG_FOR_BUILD} --cflags --libs gdk-pixbuf-2.0) \
-		-o gtk-update-icon-cache
-
-	${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS} \
-		${S}/gtk/encodesymbolic.c \
-		$(${PKG_CONFIG_FOR_BUILD} --cflags --libs gio-2.0 gdk-pixbuf-2.0) \
-		-o gtk-encode-symbolic-svg
-}
-
-do_install() {
-	install -d ${D}${bindir}
-	install -m 0755 ${B}/gtk-update-icon-cache ${D}${bindir}
-	install -m 0755 ${B}/gtk-encode-symbolic-svg ${D}${bindir}
-
-	create_wrapper ${D}/${bindir}/gtk-update-icon-cache \
-		GDK_PIXBUF_MODULE_FILE=${STAGING_LIBDIR_NATIVE}/gdk-pixbuf-2.0/2.10.0/loaders.cache
-	create_wrapper ${D}/${bindir}/gtk-encode-symbolic-svg \
-		GDK_PIXBUF_MODULE_FILE=${STAGING_LIBDIR_NATIVE}/gdk-pixbuf-2.0/2.10.0/loaders.cache
-}
diff --git a/poky/meta/recipes-gnome/gtk+/gtk-icon-utils-native_3.22.30.bb b/poky/meta/recipes-gnome/gtk+/gtk-icon-utils-native_3.22.30.bb
new file mode 100644
index 0000000..28e7a31
--- /dev/null
+++ b/poky/meta/recipes-gnome/gtk+/gtk-icon-utils-native_3.22.30.bb
@@ -0,0 +1,63 @@
+SUMMARY = "Native icon utils for GTK+"
+DESCRIPTION = "gtk-update-icon-cache and gtk-encode-symbolic-svg built from GTK+ natively, for build time and on-host postinst script execution."
+SECTION = "libs"
+
+DEPENDS = "glib-2.0-native gdk-pixbuf-native librsvg-native"
+
+LICENSE = "LGPLv2 & LGPLv2+ & LGPLv2.1+"
+
+MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}"
+
+SRC_URI = "http://ftp.gnome.org/pub/gnome/sources/gtk+/${MAJ_VER}/gtk+-${PV}.tar.xz \
+          file://Remove-Gdk-dependency-from-gtk-encode-symbolic-svg.patch"
+SRC_URI[md5sum] = "61e60dc073e0a6893c72043d20579dc0"
+SRC_URI[sha256sum] = "a1a4a5c12703d4e1ccda28333b87ff462741dc365131fbc94c218ae81d9a6567"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2 \
+                    file://gtk/gtk.h;endline=25;md5=1d8dc0fccdbfa26287a271dce88af737 \
+                    file://gdk/gdk.h;endline=25;md5=c920ce39dc88c6f06d3e7c50e08086f2 \
+                    file://tests/testgtk.c;endline=25;md5=cb732daee1d82af7a2bf953cf3cf26f1"
+
+S = "${WORKDIR}/gtk+-${PV}"
+
+inherit pkgconfig native
+
+# versions >= 3.90 are development versions, otherwise like upstream-version-is-even
+UPSTREAM_CHECK_REGEX = "[^\d\.](?P<pver>3\.([1-8]?[02468])+(\.\d+)+)\.tar"
+
+PKG_CONFIG_FOR_BUILD = "${STAGING_BINDIR_NATIVE}/pkg-config-native"
+
+do_configure() {
+	# Quite ugly but defines enough to compile the tools.
+	if ! test -f gtk/config.h; then
+		echo "#define GETTEXT_PACKAGE \"gtk30\"" >> gtk/config.h
+		echo "#define HAVE_UNISTD_H 1" >> gtk/config.h
+		echo "#define HAVE_FTW_H 1" >> gtk/config.h
+	fi
+	if ! test -f gdk/config.h; then
+		touch gdk/config.h
+	fi
+}
+
+do_compile() {
+	${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS} \
+		${S}/gtk/updateiconcache.c \
+		$(${PKG_CONFIG_FOR_BUILD} --cflags --libs gdk-pixbuf-2.0) \
+		-o gtk-update-icon-cache
+
+	${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS} \
+		${S}/gtk/encodesymbolic.c \
+		$(${PKG_CONFIG_FOR_BUILD} --cflags --libs gio-2.0 gdk-pixbuf-2.0) \
+		-o gtk-encode-symbolic-svg
+}
+
+do_install() {
+	install -d ${D}${bindir}
+	install -m 0755 ${B}/gtk-update-icon-cache ${D}${bindir}
+	install -m 0755 ${B}/gtk-encode-symbolic-svg ${D}${bindir}
+
+	create_wrapper ${D}/${bindir}/gtk-update-icon-cache \
+		GDK_PIXBUF_MODULE_FILE=${STAGING_LIBDIR_NATIVE}/gdk-pixbuf-2.0/2.10.0/loaders.cache
+	create_wrapper ${D}/${bindir}/gtk-encode-symbolic-svg \
+		GDK_PIXBUF_MODULE_FILE=${STAGING_LIBDIR_NATIVE}/gdk-pixbuf-2.0/2.10.0/loaders.cache
+}
diff --git a/poky/meta/recipes-gnome/gtk-doc/files/0001-Do-not-hardocode-paths-to-perl-python-in-scripts.patch b/poky/meta/recipes-gnome/gtk-doc/files/0001-Do-not-hardocode-paths-to-perl-python-in-scripts.patch
index 2fe3ab9..19e05f1 100644
--- a/poky/meta/recipes-gnome/gtk-doc/files/0001-Do-not-hardocode-paths-to-perl-python-in-scripts.patch
+++ b/poky/meta/recipes-gnome/gtk-doc/files/0001-Do-not-hardocode-paths-to-perl-python-in-scripts.patch
@@ -1,7 +1,7 @@
-From 928102874bc2339a1d57c6b178877e0c6002cb3a Mon Sep 17 00:00:00 2001
+From 80e6aff72affa6d92f5abd7ff6353dfc4a7bff38 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Wed, 31 Aug 2016 16:44:46 +0300
-Subject: [PATCH 1/3] Do not hardocode paths to perl/python in scripts.
+Subject: [PATCH] Do not hardocode paths to perl/python in scripts.
 
 Doing so when the interpreters are somewhere deep in a sysroot directory
 can reach the shebang line limit, and resulting scripts wouldn't work
@@ -35,7 +35,7 @@
  #
  # gtk-doc - GTK DocBook documentation generator.
 diff --git a/gtkdoc-depscan.in b/gtkdoc-depscan.in
-index 9bfaf30..aadc952 100644
+index 9bfaf30..aadc952 100755
 --- a/gtkdoc-depscan.in
 +++ b/gtkdoc-depscan.in
 @@ -1,4 +1,4 @@
@@ -45,7 +45,7 @@
  from __future__ import print_function
  
 diff --git a/gtkdoc-fixxref.in b/gtkdoc-fixxref.in
-index 0ea02d4..bdd443a 100755
+index 44f6bd1..26fbd93 100755
 --- a/gtkdoc-fixxref.in
 +++ b/gtkdoc-fixxref.in
 @@ -1,4 +1,4 @@
@@ -65,7 +65,7 @@
  #
  # gtk-doc - GTK DocBook documentation generator.
 diff --git a/gtkdoc-mkhtml.in b/gtkdoc-mkhtml.in
-index 0d0a15d..914ff55 100644
+index 0d0a15d..914ff55 100755
 --- a/gtkdoc-mkhtml.in
 +++ b/gtkdoc-mkhtml.in
 @@ -1,4 +1,4 @@
@@ -75,7 +75,7 @@
  #
  # gtk-doc - GTK DocBook documentation generator.
 diff --git a/gtkdoc-mkman.in b/gtkdoc-mkman.in
-index c5445cd..65db71a 100644
+index c5445cd..65db71a 100755
 --- a/gtkdoc-mkman.in
 +++ b/gtkdoc-mkman.in
 @@ -1,4 +1,4 @@
@@ -115,7 +115,7 @@
  #
  # gtk-doc - GTK DocBook documentation generator.
 diff --git a/gtkdoc-scangobj.in b/gtkdoc-scangobj.in
-index 4cbe130..52c2c24 100644
+index 4cbe130..52c2c24 100755
 --- a/gtkdoc-scangobj.in
 +++ b/gtkdoc-scangobj.in
 @@ -1,4 +1,4 @@
@@ -125,18 +125,15 @@
  #
  # gtk-doc - GTK DocBook documentation generator.
 diff --git a/tests/tools.sh.in b/tests/tools.sh.in
-index 4d301d0..565fc1e 100644
+index 343844a..9dc6692 100644
 --- a/tests/tools.sh.in
 +++ b/tests/tools.sh.in
-@@ -31,7 +31,7 @@ done
- # TODO: test python 2 and 3 (python3 -mcompileall gtkdoc/*.py)
- for file in gtkdoc-check gtkdoc-depscan gtkdoc-fixxref gtkdoc-mkdb gtkdoc-mkhtml gtkdoc-mkman gtkdoc-mkpdf gtkdoc-rebase gtkdoc-scangobj; do
+@@ -30,7 +30,7 @@ done
+ # TODO: also test the module files
+ for file in gtkdoc-check gtkdoc-depscan gtkdoc-fixxref gtkdoc-mkdb gtkdoc-mkhtml gtkdoc-mkhtml2 gtkdoc-mkman gtkdoc-mkpdf gtkdoc-rebase gtkdoc-scangobj; do
      fullfile=`which $file`
 -    @PYTHON@ -m py_compile $fullfile
 +    python3 -m py_compile $fullfile
      if test $? != 0 ; then failed=`expr $failed + 1`; fi
      tested=`expr $tested + 1`
  done
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-gnome/gtk-doc/files/no-clobber.patch b/poky/meta/recipes-gnome/gtk-doc/files/no-clobber.patch
index 0fa22b2..d169547 100644
--- a/poky/meta/recipes-gnome/gtk-doc/files/no-clobber.patch
+++ b/poky/meta/recipes-gnome/gtk-doc/files/no-clobber.patch
@@ -1,3 +1,8 @@
+From 8bc4c1f169f89bc5531da5b7e892b8f20e0f9a18 Mon Sep 17 00:00:00 2001
+From: Ross Burton <ross.burton@intel.com>
+Date: Wed, 21 Mar 2018 14:47:29 +0000
+Subject: [PATCH] gtk-doc: don't regenerate gtk-doc in do_install
+
 In out-of-tree builds gtk-doc's setup-build target copies all the content from $srcdir to $builddir.
 
 However, if some of this content is regenerated at configure time this can happen:
@@ -16,12 +21,20 @@
 Upstream-Status: Submitted [https://bugzilla.gnome.org/show_bug.cgi?id=794571]
 Signed-off-by: Ross Burton <ross.burton@intel.com>
 
-diff --git a/gtk-doc.make b/gtk-doc.make
-index f87eaab..246f3c0 100644
---- a/gtk-doc.make
-+++ b/gtk-doc.make
-@@ -113,3 +113,3 @@ setup-build.stamp:
+---
+ buildsystems/autotools/gtk-doc.make | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/buildsystems/autotools/gtk-doc.make b/buildsystems/autotools/gtk-doc.make
+index 7d9a27f..8cb336d 100644
+--- a/buildsystems/autotools/gtk-doc.make
++++ b/buildsystems/autotools/gtk-doc.make
+@@ -111,7 +111,7 @@ setup-build.stamp:
+ 	      destdir=`dirname $(abs_builddir)/$$file`; \
+ 	      test -d "$$destdir" || mkdir -p "$$destdir"; \
  	      test -f $(abs_srcdir)/$$file && \
 -	        cp -pf $(abs_srcdir)/$$file $(abs_builddir)/$$file || true; \
 +	        cp -pn $(abs_srcdir)/$$file $(abs_builddir)/$$file || true; \
  	    done; \
+ 	  fi; \
+ 	fi
diff --git a/poky/meta/recipes-gnome/gtk-doc/files/pkg-config-native.patch b/poky/meta/recipes-gnome/gtk-doc/files/pkg-config-native.patch
index bfbc777..9b128e1 100644
--- a/poky/meta/recipes-gnome/gtk-doc/files/pkg-config-native.patch
+++ b/poky/meta/recipes-gnome/gtk-doc/files/pkg-config-native.patch
@@ -1,7 +1,7 @@
-From 5f145621b4780cfd6a5632fcc97c45f572938efc Mon Sep 17 00:00:00 2001
+From 04af15322f677db42ecc2acc465334a04de9a871 Mon Sep 17 00:00:00 2001
 From: Ross Burton <ross.burton@intel.com>
 Date: Mon, 5 Sep 2016 22:25:44 +0100
-Subject: [PATCH 5/5] Use native pkg-config when looking for gtk-doc.
+Subject: [PATCH] Use native pkg-config when looking for gtk-doc.
 
 Upstream-Status: Inappropriate
 Signed-off-by: Ross Burton <ross.burton@intel.com>
@@ -10,10 +10,10 @@
  gtk-doc.m4 | 7 ++++++-
  1 file changed, 6 insertions(+), 1 deletion(-)
 
-Index: gtk-doc-1.27/gtk-doc.m4
-===================================================================
---- gtk-doc-1.27.orig/gtk-doc.m4
-+++ gtk-doc-1.27/gtk-doc.m4
+diff --git a/gtk-doc.m4 b/gtk-doc.m4
+index 2d12f01..e5afc3f 100644
+--- a/buildsystems/autotools/gtk-doc.m4
++++ b/buildsystems/autotools/gtk-doc.m4
 @@ -25,7 +25,7 @@
  # Macro appear in them. The GNU General Public License (GPL) does govern
  # all other use of the material that constitutes the Autoconf Macro.
diff --git a/poky/meta/recipes-gnome/gtk-doc/gtk-doc_1.27.bb b/poky/meta/recipes-gnome/gtk-doc/gtk-doc_1.27.bb
deleted file mode 100644
index 4552811..0000000
--- a/poky/meta/recipes-gnome/gtk-doc/gtk-doc_1.27.bb
+++ /dev/null
@@ -1,50 +0,0 @@
-SUMMARY = "Documentation generator for glib-based software"
-DESCRIPTION = "Gtk-doc is a set of scripts that extract specially formatted comments \
-               from glib-based software and produce a set of html documentation files from them"
-HOMEPAGE = "http://www.gtk.org/gtk-doc/"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
-
-inherit gnomebase
-
-# Configure the scripts correctly (and build their dependencies) only if they are actually
-# going to be used; otheriwse we need only the m4/makefile includes from the gtk-doc tarball.
-PACKAGECONFIG ??= "${@bb.utils.contains("DISTRO_FEATURES", "api-documentation", "working-scripts", "", d)}"
-
-# This will cause target gtk-doc to hardcode paths of native dependencies
-# into its scripts. This means that target gtk-doc package is broken;
-# hopefully no one minds because its scripts are not used for anything during build
-# and shouldn't be used on targets.
-PACKAGECONFIG[working-scripts] = "--with-highlight=source-highlight,--with-highlight=no,libxslt-native xmlto-native source-highlight-native python3-six"
-PACKAGECONFIG[tests] = "--enable-tests,--disable-tests,glib-2.0"
-
-SRC_URI[archive.md5sum] = "b29949e0964762e474b706ce22171602"
-SRC_URI[archive.sha256sum] = "e26bd3f7080c749b1cb66c46c6bf8239e2f320a949964fb9c6d56e1b0c6d9a6f"
-SRC_URI += "file://0001-Do-not-hardocode-paths-to-perl-python-in-scripts.patch \
-           file://0001-Do-not-error-out-if-xsltproc-is-not-found.patch \
-           file://conditionaltests.patch \
-           file://no-clobber.patch \
-           "
-SRC_URI_append_class-native = " file://pkg-config-native.patch"
-
-BBCLASSEXTEND = "native nativesdk"
-
-# Do not check for XML catalogs when building because that
-# information is not used for anything during build. Recipe
-# dependencies make sure we have all the right bits.
-do_configure_prepend() {
-        sed -i -e 's,^JH_CHECK_XML_CATALOG.*,,' ${S}/configure.ac
-}
-
-FILES_${PN} += "${datadir}/sgml"
-FILES_${PN}-dev += "${libdir}/cmake"
-FILES_${PN}-doc = ""
-
-SYSROOT_PREPROCESS_FUNCS_append_class-native = " gtkdoc_makefiles_sysroot_preprocess"
-gtkdoc_makefiles_sysroot_preprocess() {
-        # Patch the gtk-doc makefiles so that the qemu wrapper is used to run transient binaries
-        # instead of libtool wrapper or running them directly
-        sed -i \
-           -e "s|GTKDOC_RUN =.*|GTKDOC_RUN = \$(top_builddir)/gtkdoc-qemuwrapper|" \
-           ${SYSROOT_DESTDIR}${datadir}/gtk-doc/data/gtk-doc*make
-}
diff --git a/poky/meta/recipes-gnome/gtk-doc/gtk-doc_1.29.bb b/poky/meta/recipes-gnome/gtk-doc/gtk-doc_1.29.bb
new file mode 100644
index 0000000..2c4ee17
--- /dev/null
+++ b/poky/meta/recipes-gnome/gtk-doc/gtk-doc_1.29.bb
@@ -0,0 +1,50 @@
+SUMMARY = "Documentation generator for glib-based software"
+DESCRIPTION = "Gtk-doc is a set of scripts that extract specially formatted comments \
+               from glib-based software and produce a set of html documentation files from them"
+HOMEPAGE = "http://www.gtk.org/gtk-doc/"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+
+inherit gnomebase
+
+# Configure the scripts correctly (and build their dependencies) only if they are actually
+# going to be used; otheriwse we need only the m4/makefile includes from the gtk-doc tarball.
+PACKAGECONFIG ??= "${@bb.utils.contains("DISTRO_FEATURES", "api-documentation", "working-scripts", "", d)}"
+
+# This will cause target gtk-doc to hardcode paths of native dependencies
+# into its scripts. This means that target gtk-doc package is broken;
+# hopefully no one minds because its scripts are not used for anything during build
+# and shouldn't be used on targets.
+PACKAGECONFIG[working-scripts] = "--with-highlight=source-highlight,--with-highlight=no,libxslt-native xmlto-native source-highlight-native python3-six"
+PACKAGECONFIG[tests] = "--enable-tests,--disable-tests,glib-2.0"
+
+SRC_URI[archive.md5sum] = "df26a38c209b3d7358f26268fcbdb9e3"
+SRC_URI[archive.sha256sum] = "14578e002496567276d310a62c9ffd6c56ee8806ce5079ffb0b81c4111f586b1"
+SRC_URI += "file://0001-Do-not-hardocode-paths-to-perl-python-in-scripts.patch \
+           file://0001-Do-not-error-out-if-xsltproc-is-not-found.patch \
+           file://conditionaltests.patch \
+           file://no-clobber.patch \
+           "
+SRC_URI_append_class-native = " file://pkg-config-native.patch"
+
+BBCLASSEXTEND = "native nativesdk"
+
+# Do not check for XML catalogs when building because that
+# information is not used for anything during build. Recipe
+# dependencies make sure we have all the right bits.
+do_configure_prepend() {
+        sed -i -e 's,^JH_CHECK_XML_CATALOG.*,,' ${S}/configure.ac
+}
+
+FILES_${PN} += "${datadir}/sgml"
+FILES_${PN}-dev += "${libdir}/cmake"
+FILES_${PN}-doc = ""
+
+SYSROOT_PREPROCESS_FUNCS_append_class-native = " gtkdoc_makefiles_sysroot_preprocess"
+gtkdoc_makefiles_sysroot_preprocess() {
+        # Patch the gtk-doc makefiles so that the qemu wrapper is used to run transient binaries
+        # instead of libtool wrapper or running them directly
+        sed -i \
+           -e "s|GTKDOC_RUN =.*|GTKDOC_RUN = \$(top_builddir)/gtkdoc-qemuwrapper|" \
+           ${SYSROOT_DESTDIR}${datadir}/gtk-doc/data/gtk-doc*make
+}
diff --git a/poky/meta/recipes-gnome/libsecret/libsecret_0.18.5.bb b/poky/meta/recipes-gnome/libsecret/libsecret_0.18.5.bb
deleted file mode 100644
index 2b917ec..0000000
--- a/poky/meta/recipes-gnome/libsecret/libsecret_0.18.5.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-SUMMARY = "libsecret is a library for storing and retrieving passwords and other secrets"
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=23c2a5e0106b99d75238986559bb5fc6"
-
-inherit gnomebase gtk-doc vala gobject-introspection manpages
-
-DEPENDS += "glib-2.0 libgcrypt gettext-native intltool-native"
-
-PACKAGECONFIG[manpages] = "--enable-manpages, --disable-manpages, libxslt-native xmlto-native"
-
-SRC_URI[archive.md5sum] = "2d688825921313da8731313b0a7f394c"
-SRC_URI[archive.sha256sum] = "9ce7bd8dd5831f2786c935d82638ac428fa085057cc6780aba0e39375887ccb3"
-
-# http://errors.yoctoproject.org/Errors/Details/20228/
-ARM_INSTRUCTION_SET = "arm"
-
-# vapigen.m4 bundled with the tarball does not yet have our cross-compilation fixes
-do_configure_prepend() {
-    rm -f ${S}/build/m4/vapigen.m4
-}
diff --git a/poky/meta/recipes-gnome/libsecret/libsecret_0.18.6.bb b/poky/meta/recipes-gnome/libsecret/libsecret_0.18.6.bb
new file mode 100644
index 0000000..518c71f
--- /dev/null
+++ b/poky/meta/recipes-gnome/libsecret/libsecret_0.18.6.bb
@@ -0,0 +1,22 @@
+SUMMARY = "libsecret is a library for storing and retrieving passwords and other secrets"
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=23c2a5e0106b99d75238986559bb5fc6"
+
+inherit gnomebase gtk-doc vala gobject-introspection manpages
+
+DEPENDS += "glib-2.0 libgcrypt gettext-native intltool-native"
+
+PACKAGECONFIG[manpages] = "--enable-manpages, --disable-manpages, libxslt-native xmlto-native"
+
+SRC_URI[archive.md5sum] = "c6cf132a56bd346fbf49a43abb02e5c2"
+SRC_URI[archive.sha256sum] = "5efbc890ba41a323ffe0599cd260fd12bd8eb62a04aa1bd1b2762575d253d66f"
+
+# http://errors.yoctoproject.org/Errors/Details/20228/
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
+ARM_INSTRUCTION_SET_armv6 = "arm"
+
+# vapigen.m4 bundled with the tarball does not yet have our cross-compilation fixes
+do_configure_prepend() {
+    rm -f ${S}/build/m4/vapigen.m4
+}
diff --git a/poky/meta/recipes-graphics/cairo/cairo-fpu.inc b/poky/meta/recipes-graphics/cairo/cairo-fpu.inc
deleted file mode 100644
index fe7c533..0000000
--- a/poky/meta/recipes-graphics/cairo/cairo-fpu.inc
+++ /dev/null
@@ -1,6 +0,0 @@
-
-def get_cairo_fpu_setting(bb, d):
-    if d.getVar('TARGET_FPU') in [ 'soft' ]:
-        return "--disable-some-floating-point"
-    return ""
-
diff --git a/poky/meta/recipes-graphics/cairo/cairo.inc b/poky/meta/recipes-graphics/cairo/cairo.inc
deleted file mode 100644
index 20e0d2c..0000000
--- a/poky/meta/recipes-graphics/cairo/cairo.inc
+++ /dev/null
@@ -1,48 +0,0 @@
-SUMMARY = "The Cairo 2D vector graphics library"
-DESCRIPTION = "Cairo is a multi-platform library providing anti-aliased \
-vector-based rendering for multiple target backends. Paths consist \
-of line segments and cubic splines and can be rendered at any width \
-with various join and cap styles. All colors may be specified with \
-optional translucence (opacity/alpha) and combined using the \
-extended Porter/Duff compositing algebra as found in the X Render \
-Extension."
-HOMEPAGE = "http://cairographics.org"
-BUGTRACKER = "http://bugs.freedesktop.org"
-SECTION = "libs"
-
-LICENSE = "MPL-1 & LGPLv2.1 & GPLv3+"
-LICENSE_${PN} = "MPL-1 & LGPLv2.1"
-LICENSE_${PN}-dev = "MPL-1 & LGPLv2.1"
-LICENSE_${PN}-doc = "MPL-1 & LGPLv2.1"
-LICENSE_${PN}-gobject = "MPL-1 & LGPLv2.1"
-LICENSE_${PN}-script-interpreter = "MPL-1 & LGPLv2.1"
-LICENSE_${PN}-perf-utils = "GPLv3+"
-
-X11DEPENDS = "virtual/libx11 libsm libxrender libxext"
-DEPENDS = "libpng fontconfig pixman glib-2.0 zlib"
-
-PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11 xcb', '', d)} \
-           ${@bb.utils.filter('DISTRO_FEATURES', 'directfb', d)}"
-
-PACKAGECONFIG[x11] = "--with-x=yes -enable-xlib,--with-x=no --disable-xlib,${X11DEPENDS}"
-PACKAGECONFIG[xcb] = "--enable-xcb,--disable-xcb,libxcb"
-PACKAGECONFIG[directfb] = "--enable-directfb=yes,,directfb"
-PACKAGECONFIG[valgrind] = "--enable-valgrind=yes,--disable-valgrind,valgrind"
-PACKAGECONFIG[egl] = "--enable-egl=yes,--disable-egl,virtual/egl"
-PACKAGECONFIG[glesv2] = "--enable-glesv2,--disable-glesv2,virtual/libgles2"
-PACKAGECONFIG[opengl] = "--enable-gl,--disable-gl,virtual/libgl"
-
-#check for TARGET_FPU=soft and inform configure of the result so it can disable some floating points 
-require cairo-fpu.inc
-EXTRA_OECONF += "${@get_cairo_fpu_setting(bb, d)} \
-                 --enable-tee \
-                "
-
-inherit autotools pkgconfig upstream-version-is-even gtk-doc
-
-# We don't depend on binutils so we need to disable this
-export ac_cv_lib_bfd_bfd_openr="no"
-# Ensure we don't depend on LZO
-export ac_cv_lib_lzo2_lzo2a_decompress="no"
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-graphics/cairo/cairo_1.14.12.bb b/poky/meta/recipes-graphics/cairo/cairo_1.14.12.bb
index 075ca1e..18b9479 100644
--- a/poky/meta/recipes-graphics/cairo/cairo_1.14.12.bb
+++ b/poky/meta/recipes-graphics/cairo/cairo_1.14.12.bb
@@ -1,7 +1,27 @@
-require cairo.inc
+SUMMARY = "The Cairo 2D vector graphics library"
+DESCRIPTION = "Cairo is a multi-platform library providing anti-aliased \
+vector-based rendering for multiple target backends. Paths consist \
+of line segments and cubic splines and can be rendered at any width \
+with various join and cap styles. All colors may be specified with \
+optional translucence (opacity/alpha) and combined using the \
+extended Porter/Duff compositing algebra as found in the X Render \
+Extension."
+HOMEPAGE = "http://cairographics.org"
+BUGTRACKER = "http://bugs.freedesktop.org"
+SECTION = "libs"
+
+LICENSE = "MPL-1 & LGPLv2.1 & GPLv3+"
+LICENSE_${PN} = "MPL-1 & LGPLv2.1"
+LICENSE_${PN}-dev = "MPL-1 & LGPLv2.1"
+LICENSE_${PN}-doc = "MPL-1 & LGPLv2.1"
+LICENSE_${PN}-gobject = "MPL-1 & LGPLv2.1"
+LICENSE_${PN}-script-interpreter = "MPL-1 & LGPLv2.1"
+LICENSE_${PN}-perf-utils = "GPLv3+"
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=e73e999e0c72b5ac9012424fa157ad77"
 
+DEPENDS = "fontconfig glib-2.0 libpng pixman zlib"
+
 SRC_URI = "http://cairographics.org/releases/cairo-${PV}.tar.xz \
            file://cairo-get_bitmap_surface-bsc1036789-CVE-2017-7475.diff \ 
            file://0001-cairo-Fix-CVE-2017-9814.patch \
@@ -10,16 +30,43 @@
 SRC_URI[md5sum] = "9f0db9dbfca0966be8acd682e636d165"
 SRC_URI[sha256sum] = "8c90f00c500b2299c0a323dd9beead2a00353752b2092ead558139bd67f7bf16"
 
-PACKAGES =+ "cairo-gobject cairo-script-interpreter cairo-perf-utils"
+inherit autotools pkgconfig upstream-version-is-even gtk-doc multilib_script
 
-SUMMARY_${PN} = "The Cairo 2D vector graphics library"
-DESCRIPTION_${PN} = "Cairo is a multi-platform library providing anti-aliased \
-vector-based rendering for multiple target backends. Paths consist \
-of line segments and cubic splines and can be rendered at any width \
-with various join and cap styles. All colors may be specified with \
-optional translucence (opacity/alpha) and combined using the \
-extended Porter/Duff compositing algebra as found in the X Render \
-Extension."
+MULTILIB_SCRIPTS = "${PN}-perf-utils:${bindir}/cairo-trace"
+
+X11DEPENDS = "virtual/libx11 libsm libxrender libxext"
+
+PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'directfb', d)} \
+                   ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11 xcb', '', d)} \
+                   ${@bb.utils.contains('DISTRO_FEATURES', 'x11 opengl', 'opengl', '', d)}"
+
+PACKAGECONFIG[x11] = "--with-x=yes -enable-xlib,--with-x=no --disable-xlib,${X11DEPENDS}"
+PACKAGECONFIG[xcb] = "--enable-xcb,--disable-xcb,libxcb"
+PACKAGECONFIG[directfb] = "--enable-directfb=yes,,directfb"
+PACKAGECONFIG[valgrind] = "--enable-valgrind=yes,--disable-valgrind,valgrind"
+PACKAGECONFIG[egl] = "--enable-egl=yes,--disable-egl,virtual/egl"
+PACKAGECONFIG[glesv2] = "--enable-glesv2,--disable-glesv2,virtual/libgles2"
+PACKAGECONFIG[opengl] = "--enable-gl,--disable-gl,virtual/libgl"
+
+EXTRA_OECONF += " \
+    ${@bb.utils.contains('TARGET_FPU', 'soft', '--disable-some-floating-point', '', d)} \
+    --enable-tee \
+"
+
+# We don't depend on binutils so we need to disable this
+export ac_cv_lib_bfd_bfd_openr="no"
+# Ensure we don't depend on LZO
+export ac_cv_lib_lzo2_lzo2a_decompress="no"
+
+do_install_append () {
+	rm -rf ${D}${bindir}/cairo-sphinx
+	rm -rf ${D}${libdir}/cairo/cairo-fdr*
+	rm -rf ${D}${libdir}/cairo/cairo-sphinx*
+	rm -rf ${D}${libdir}/cairo/.debug/cairo-fdr*
+	rm -rf ${D}${libdir}/cairo/.debug/cairo-sphinx*
+}
+
+PACKAGES =+ "cairo-gobject cairo-script-interpreter cairo-perf-utils"
 
 SUMMARY_cairo-gobject = "The Cairo library GObject wrapper library"
 DESCRIPTION_cairo-gobject = "A GObject wrapper library for the Cairo API."
@@ -32,15 +79,9 @@
 DESCRIPTION_cairo-perf-utils = "The Cairo library performance utilities"
 
 FILES_${PN} = "${libdir}/libcairo.so.*"
-FILES_${PN}-dev += "${libdir}/cairo/*.so"
 FILES_${PN}-gobject = "${libdir}/libcairo-gobject.so.*"
 FILES_${PN}-script-interpreter = "${libdir}/libcairo-script-interpreter.so.*"
-FILES_${PN}-perf-utils = "${bindir}/cairo-trace ${libdir}/cairo/*.la ${libdir}/cairo/libcairo-trace.so.*"
+FILES_${PN}-perf-utils = "${bindir}/cairo-trace* ${libdir}/cairo/*.la ${libdir}/cairo/libcairo-trace.so.*"
+FILES_${PN}-dev += "${libdir}/cairo/*.so"
 
-do_install_append () {
-	rm -rf ${D}${bindir}/cairo-sphinx
-	rm -rf ${D}${libdir}/cairo/cairo-fdr*
-	rm -rf ${D}${libdir}/cairo/cairo-sphinx*
-	rm -rf ${D}${libdir}/cairo/.debug/cairo-fdr*
-	rm -rf ${D}${libdir}/cairo/.debug/cairo-sphinx*
-}
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-graphics/cantarell-fonts/cantarell-fonts_git.bb b/poky/meta/recipes-graphics/cantarell-fonts/cantarell-fonts_git.bb
index 9d8fb28..db480bd 100644
--- a/poky/meta/recipes-graphics/cantarell-fonts/cantarell-fonts_git.bb
+++ b/poky/meta/recipes-graphics/cantarell-fonts/cantarell-fonts_git.bb
@@ -10,10 +10,10 @@
 LICENSE = "OFL-1.1"
 LIC_FILES_CHKSUM = "file://COPYING;md5=df91e3ffcab8cfb972a66bf11255188d"
 
-PV = "0.0.24"
+PV = "0.0.25"
 
-SRCREV = "07b6ea2cbbebfc360aa4668612a376be5e214eaa"
-SRC_URI = "git://gitlab.gnome.org/GNOME/cantarell-fonts;protocol=https;branch=master"
+SRCREV = "e28a9096da43984212b5b4002b949bcb8c7527f9"
+SRC_URI = "git://gitlab.gnome.org/GNOME/cantarell-fonts.git;protocol=https;branch=reconstruction-0.0.25"
 UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>(?!0\.13)(?!0\.10\.1)\d+\.\d+(\.\d+)+)"
 
 S = "${WORKDIR}/git"
diff --git a/poky/meta/recipes-graphics/clutter/clutter-gst-3.0_3.0.24.bb b/poky/meta/recipes-graphics/clutter/clutter-gst-3.0_3.0.24.bb
deleted file mode 100644
index ca5e0ae..0000000
--- a/poky/meta/recipes-graphics/clutter/clutter-gst-3.0_3.0.24.bb
+++ /dev/null
@@ -1,7 +0,0 @@
-require clutter-gst-3.0.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c \
-                    file://clutter-gst/clutter-gst.h;beginline=1;endline=24;md5=95baacba194e814c110ea3bdf25ddbf4"
-
-SRC_URI[archive.md5sum] = "3e145e24bb3c340eeeddafd18efe547d"
-SRC_URI[archive.sha256sum] = "e9f1c87d8f4c47062e952fb8008704f8942cf2d6f290688f3f7d13e83578cc6c"
diff --git a/poky/meta/recipes-graphics/clutter/clutter-gst-3.0_3.0.26.bb b/poky/meta/recipes-graphics/clutter/clutter-gst-3.0_3.0.26.bb
new file mode 100644
index 0000000..8a0dda5
--- /dev/null
+++ b/poky/meta/recipes-graphics/clutter/clutter-gst-3.0_3.0.26.bb
@@ -0,0 +1,7 @@
+require clutter-gst-3.0.inc
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c \
+                    file://clutter-gst/clutter-gst.h;beginline=1;endline=24;md5=95baacba194e814c110ea3bdf25ddbf4"
+
+SRC_URI[archive.md5sum] = "7809ca6ce9d1a3490597fd4a7375c389"
+SRC_URI[archive.sha256sum] = "d8618a6d9accec0f2a8574c5e1220051f8505fb82b20336c26bdbd482aa6cb3a"
diff --git a/poky/meta/recipes-graphics/drm/libdrm/0001-configure.ac-Allow-explicit-enabling-of-cunit-tests.patch b/poky/meta/recipes-graphics/drm/libdrm/0001-configure.ac-Allow-explicit-enabling-of-cunit-tests.patch
deleted file mode 100644
index 40bebc0..0000000
--- a/poky/meta/recipes-graphics/drm/libdrm/0001-configure.ac-Allow-explicit-enabling-of-cunit-tests.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-From e6bd4205b0b546afe991ae6f72256645f4404ad4 Mon Sep 17 00:00:00 2001
-From: Jussi Kukkonen <jussi.kukkonen@intel.com>
-Date: Mon, 5 Sep 2016 14:41:37 +0300
-Subject: [PATCH libdrm] configure.ac: Allow explicit enabling of cunit tests
-
-Add --with-cunit to make it easier to do reproducible builds. Default
-is still to probe cunit and build opportunistically.
-
-Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
-Upstream-Status: Submitted [mailing list]
----
- configure.ac | 14 ++++++++++++--
- 1 file changed, 12 insertions(+), 2 deletions(-)
-
-Index: libdrm-2.4.91/configure.ac
-===================================================================
---- libdrm-2.4.91.orig/configure.ac
-+++ libdrm-2.4.91/configure.ac
-@@ -163,6 +163,12 @@ AC_ARG_ENABLE(install-test-programs,
- 		  [Install test programs (default: no)]),
- 		  [INSTALL_TESTS=$enableval], [INSTALL_TESTS=no])
- 
-+AC_ARG_WITH([cunit],
-+            [AS_HELP_STRING([--with-cunit],
-+                            [Build tests that use cunit (default: auto)])],
-+            [],
-+            [with_cunit=auto])
-+
- dnl ===========================================================================
- dnl check compiler flags
- AC_DEFUN([LIBDRM_CC_TRY_FLAG], [
-@@ -411,7 +417,7 @@ else
- 	AC_DEFINE(HAVE_RADEON, 0)
- fi
- 
--if test "x$AMDGPU" != xno; then
-+if test "x$with_cunit" != xno -a "x$AMDGPU" != xno; then
- 	# Detect cunit library
- 	PKG_CHECK_MODULES([CUNIT], [cunit >= 2.1], [have_cunit=yes], [have_cunit=no])
- 	# If pkg-config does not find cunit, check it using AC_CHECK_LIB.  We
-@@ -436,7 +442,11 @@ if test "x$AMDGPU" = xyes; then
- 	AC_DEFINE(HAVE_AMDGPU, 1, [Have amdgpu support])
- 
- 	if test "x$have_cunit" = "xno"; then
--		AC_MSG_WARN([Could not find cunit library. Disabling amdgpu tests])
-+		if test "x$with_cunit" = "xyes"; then
-+			AC_MSG_ERROR([Could not find cunit library but --with-cunit was given])
-+		elif test "x$with_cunit" = "xauto"; then
-+			AC_MSG_WARN([Could not find cunit library. Disabling amdgpu tests])
-+		fi
- 	fi
- else
- 	AC_DEFINE(HAVE_AMDGPU, 0)
diff --git a/poky/meta/recipes-graphics/drm/libdrm/fix_O_CLOEXEC_undeclared.patch b/poky/meta/recipes-graphics/drm/libdrm/fix_O_CLOEXEC_undeclared.patch
deleted file mode 100644
index 4708bf1..0000000
--- a/poky/meta/recipes-graphics/drm/libdrm/fix_O_CLOEXEC_undeclared.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-drmdevice.c: define _GNU_SOURCE
-
-Include config.h to fix this build error with uclibc:
-
-libdrm-2.4.66/tests/drmdevice.c: In function 'main':
-libdrm-2.4.66/tests/drmdevice.c:96:60: error:
-'O_CLOEXEC' undeclared (first use in this function)
-fd = open(devices[i]->nodes[j],O_RDONLY | O_CLOEXEC, 0);
-
-Upstream-Status: Pending
-
-Signed-off-by: Maxin B. John <maxin.john@intel.com>
----
-diff -Naur libdrm-2.4.66-orig/tests/drmdevice.c libdrm-2.4.66/tests/drmdevice.c
---- libdrm-2.4.66-orig/tests/drmdevice.c	2016-02-23 11:34:02.054904502 +0200
-+++ libdrm-2.4.66/tests/drmdevice.c	2016-02-23 11:35:34.371750383 +0200
-@@ -21,6 +21,7 @@
-  *
-  */
- 
-+#include <config.h>
- #include <errno.h>
- #include <stdio.h>
- #include <stdlib.h>
diff --git a/poky/meta/recipes-graphics/drm/libdrm/installtests.patch b/poky/meta/recipes-graphics/drm/libdrm/installtests.patch
deleted file mode 100644
index ec1fb02..0000000
--- a/poky/meta/recipes-graphics/drm/libdrm/installtests.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 5c6eb43c2f6e7f2ee7c25c92e42f4e4403fa0527 Mon Sep 17 00:00:00 2001
-From: Jussi Kukkonen <jussi.kukkonen@intel.com>
-Date: Tue, 21 Feb 2017 14:37:52 +0200
-Subject: [PATCH] tests: also install test apps
-
-Upstream-Status: Inappropriate [configuration]
-
-Signed-off-by: Yu Ke <ke.yu@intel.com>
-Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
----
- tests/Makefile.am | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/tests/Makefile.am b/tests/Makefile.am
-index 0355a92..b4882cd 100644
---- a/tests/Makefile.am
-+++ b/tests/Makefile.am
-@@ -45,3 +45,4 @@ TESTS = \
- check_PROGRAMS = \
- 	$(TESTS) \
- 	drmdevice
-+bin_PROGRAMS = $(check_PROGRAMS)
--- 
-2.1.4
-
diff --git a/poky/meta/recipes-graphics/drm/libdrm/musl-ioctl.patch b/poky/meta/recipes-graphics/drm/libdrm/musl-ioctl.patch
new file mode 100644
index 0000000..e3d6c5b
--- /dev/null
+++ b/poky/meta/recipes-graphics/drm/libdrm/musl-ioctl.patch
@@ -0,0 +1,35 @@
+Upstream-Status: Submitted
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+From 46c0fd6c827a8cb4d04e067bf04fab579ac4712e Mon Sep 17 00:00:00 2001
+From: Ross Burton <ross.burton@intel.com>
+Date: Mon, 18 Jun 2018 15:07:03 +0100
+Subject: [PATCH] tests/nouveau/threaded: adapt ioctl signature
+
+POSIX says ioctl() has the signature (int, int, ...) but glibc has decided to
+use (int, unsigned long int, ...) instead.
+
+Use a #ifdef to adapt the replacement function as appropriate.
+---
+ tests/nouveau/threaded.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/tests/nouveau/threaded.c b/tests/nouveau/threaded.c
+index 3669bcd3..e1c27c01 100644
+--- a/tests/nouveau/threaded.c
++++ b/tests/nouveau/threaded.c
+@@ -36,7 +36,11 @@ static int failed;
+ 
+ static int import_fd;
+ 
++#ifdef __GLIBC__
+ int ioctl(int fd, unsigned long request, ...)
++#else
++int ioctl(int fd, int request, ...)
++#endif
+ {
+ 	va_list va;
+ 	int ret;
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-graphics/drm/libdrm_2.4.91.bb b/poky/meta/recipes-graphics/drm/libdrm_2.4.91.bb
deleted file mode 100644
index c490285..0000000
--- a/poky/meta/recipes-graphics/drm/libdrm_2.4.91.bb
+++ /dev/null
@@ -1,51 +0,0 @@
-SUMMARY = "Userspace interface to the kernel DRM services"
-DESCRIPTION = "The runtime library for accessing the kernel DRM services.  DRM \
-stands for \"Direct Rendering Manager\", which is the kernel portion of the \
-\"Direct Rendering Infrastructure\" (DRI).  DRI is required for many hardware \
-accelerated OpenGL drivers."
-HOMEPAGE = "http://dri.freedesktop.org"
-SECTION = "x11/base"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://xf86drm.c;beginline=9;endline=32;md5=c8a3b961af7667c530816761e949dc71"
-PROVIDES = "drm"
-DEPENDS = "libpthread-stubs libpciaccess"
-
-SRC_URI = "http://dri.freedesktop.org/libdrm/${BP}.tar.bz2 \
-           file://installtests.patch \
-           file://fix_O_CLOEXEC_undeclared.patch \
-           file://0001-configure.ac-Allow-explicit-enabling-of-cunit-tests.patch \
-          "
-
-SRC_URI[md5sum] = "23d87cda92700b710a37d9b8edaa9f54"
-SRC_URI[sha256sum] = "634a0ed0cc1eff06f48674b1da81aafa661a9f001e7a4f43dde81076886dc800"
-
-inherit autotools pkgconfig manpages
-
-EXTRA_OECONF += "--disable-cairo-tests \
-                 --without-cunit \
-                 --enable-omap-experimental-api \
-                 --enable-etnaviv-experimental-api \
-                 --enable-install-test-programs \
-                 --disable-valgrind \
-                "
-PACKAGECONFIG[manpages] = "--enable-manpages, --disable-manpages, libxslt-native xmlto-native"
-
-ALLOW_EMPTY_${PN}-drivers = "1"
-PACKAGES =+ "${PN}-tests ${PN}-drivers ${PN}-radeon ${PN}-nouveau ${PN}-omap \
-             ${PN}-intel ${PN}-exynos ${PN}-kms ${PN}-freedreno ${PN}-amdgpu \
-             ${PN}-etnaviv"
-
-RRECOMMENDS_${PN}-drivers = "${PN}-radeon ${PN}-nouveau ${PN}-omap ${PN}-intel \
-                             ${PN}-exynos ${PN}-freedreno ${PN}-amdgpu \
-                             ${PN}-etnaviv"
-
-FILES_${PN}-tests = "${bindir}/*"
-FILES_${PN}-radeon = "${libdir}/libdrm_radeon.so.*"
-FILES_${PN}-nouveau = "${libdir}/libdrm_nouveau.so.*"
-FILES_${PN}-omap = "${libdir}/libdrm_omap.so.*"
-FILES_${PN}-intel = "${libdir}/libdrm_intel.so.*"
-FILES_${PN}-exynos = "${libdir}/libdrm_exynos.so.*"
-FILES_${PN}-kms = "${libdir}/libkms*.so.*"
-FILES_${PN}-freedreno = "${libdir}/libdrm_freedreno.so.*"
-FILES_${PN}-amdgpu = "${libdir}/libdrm_amdgpu.so.*"
-FILES_${PN}-etnaviv = "${libdir}/libdrm_etnaviv.so.*"
diff --git a/poky/meta/recipes-graphics/drm/libdrm_2.4.94.bb b/poky/meta/recipes-graphics/drm/libdrm_2.4.94.bb
new file mode 100644
index 0000000..d654292
--- /dev/null
+++ b/poky/meta/recipes-graphics/drm/libdrm_2.4.94.bb
@@ -0,0 +1,60 @@
+SUMMARY = "Userspace interface to the kernel DRM services"
+DESCRIPTION = "The runtime library for accessing the kernel DRM services.  DRM \
+stands for \"Direct Rendering Manager\", which is the kernel portion of the \
+\"Direct Rendering Infrastructure\" (DRI).  DRI is required for many hardware \
+accelerated OpenGL drivers."
+HOMEPAGE = "http://dri.freedesktop.org"
+SECTION = "x11/base"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://xf86drm.c;beginline=9;endline=32;md5=c8a3b961af7667c530816761e949dc71"
+PROVIDES = "drm"
+DEPENDS = "libpthread-stubs"
+
+SRC_URI = "http://dri.freedesktop.org/libdrm/${BP}.tar.bz2 \
+           file://musl-ioctl.patch"
+SRC_URI[md5sum] = "e9803233838007047f39eb385c70d9e0"
+SRC_URI[sha256sum] = "b73c59b0a3760502c428ba81de49cd4807657d26be5e697eba3a87dd021d16be"
+
+inherit meson pkgconfig manpages
+
+PACKAGECONFIG ??= "libkms intel radeon amdgpu nouveau vmwgfx omap freedreno vc4 etnaviv install-test-programs"
+PACKAGECONFIG[libkms] = "-Dlibkms=true,-Dlibkms=false"
+PACKAGECONFIG[intel] = "-Dintel=true,-Dintel=false,libpciaccess"
+PACKAGECONFIG[radeon] = "-Dradeon=true,-Dradeon=false"
+PACKAGECONFIG[amdgpu] = "-Damdgpu=true,-Damdgpu=false"
+PACKAGECONFIG[nouveau] = "-Dnouveau=true,-Dnouveau=false"
+PACKAGECONFIG[vmwgfx] = "-Dvmwgfx=true,-Dvmwgfx=false"
+PACKAGECONFIG[omap] = "-Domap=true,-Domap=false"
+PACKAGECONFIG[exynos] = "-Dexynos=true,-Dexynos=false"
+PACKAGECONFIG[freedreno] = "-Dfreedreno=true,-Dfreedreno=false"
+PACKAGECONFIG[tegra] = "-Dtegra=true,-Dtegra=false"
+PACKAGECONFIG[vc4] = "-Dvc4=true,-Dvc4=false"
+PACKAGECONFIG[etnaviv] = "-Detnaviv=true,-Detnaviv=false"
+PACKAGECONFIG[freedreno-kgsl] = "-Dfreedreno-kgsl=true,-Dfreedreno-kgsl=false"
+PACKAGECONFIG[valgrind] = "-Dvalgrind=true,-Dvalgrind=false,valgrind"
+PACKAGECONFIG[install-test-programs] = "-Dinstall-test-programs=true,-Dinstall-test-programs=false"
+PACKAGECONFIG[cairo-tests] = "-Dcairo-tests=true,-Dcairo-tests=false"
+PACKAGECONFIG[udev] = "-Dudev=true,-Dudev=false,udev"
+PACKAGECONFIG[manpages] = "-Dman-pages=true,-Dman-pages=false,libxslt-native xmlto-native"
+
+ALLOW_EMPTY_${PN}-drivers = "1"
+PACKAGES =+ "${PN}-tests ${PN}-drivers ${PN}-radeon ${PN}-nouveau ${PN}-omap \
+             ${PN}-intel ${PN}-exynos ${PN}-kms ${PN}-freedreno ${PN}-amdgpu \
+             ${PN}-etnaviv"
+
+RRECOMMENDS_${PN}-drivers = "${PN}-radeon ${PN}-nouveau ${PN}-omap ${PN}-intel \
+                             ${PN}-exynos ${PN}-freedreno ${PN}-amdgpu \
+                             ${PN}-etnaviv"
+
+FILES_${PN}-tests = "${bindir}/*"
+FILES_${PN}-radeon = "${libdir}/libdrm_radeon.so.*"
+FILES_${PN}-nouveau = "${libdir}/libdrm_nouveau.so.*"
+FILES_${PN}-omap = "${libdir}/libdrm_omap.so.*"
+FILES_${PN}-intel = "${libdir}/libdrm_intel.so.*"
+FILES_${PN}-exynos = "${libdir}/libdrm_exynos.so.*"
+FILES_${PN}-kms = "${libdir}/libkms*.so.*"
+FILES_${PN}-freedreno = "${libdir}/libdrm_freedreno.so.*"
+FILES_${PN}-amdgpu = "${libdir}/libdrm_amdgpu.so.*"
+FILES_${PN}-etnaviv = "${libdir}/libdrm_etnaviv.so.*"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-graphics/eglinfo/eglinfo.inc b/poky/meta/recipes-graphics/eglinfo/eglinfo.inc
index 8e7d9bd..07ad072 100644
--- a/poky/meta/recipes-graphics/eglinfo/eglinfo.inc
+++ b/poky/meta/recipes-graphics/eglinfo/eglinfo.inc
@@ -7,15 +7,17 @@
 DEPENDS = "virtual/egl"
 
 SRC_URI = "git://github.com/dv1/eglinfo.git;branch=master \
+           file://waf \
            file://0001-Add-STAGING_INCDIR-to-searchpath-for-egl-headers.patch \
-          "
+           file://0001-Check-for-libegl-using-pkg-config.patch \
+           "
 SRCREV = "4b317648ec6cf39556a9e5d8078f605bc0edd5de"
 
 CVE_PRODUCT = "eglinfo"
 
 S = "${WORKDIR}/git"
 
-inherit waf distro_features_check
+inherit waf distro_features_check pkgconfig
 # depends on virtual/egl
 REQUIRED_DISTRO_FEATURES ?= "opengl"
 
@@ -28,6 +30,9 @@
                 --device=${EGLINFO_DEVICE} \
                 --sysroot ${STAGING_DIR_TARGET}"
 
+do_configure_prepend() {
+	install -D -m 0755 ${WORKDIR}/waf ${S}/waf
+}
 do_install_append() {
 	mv ${D}/${bindir}/eglinfo ${D}/${bindir}/${EGLINFO_BINARY_NAME}
 }
diff --git a/poky/meta/recipes-graphics/eglinfo/files/0001-Check-for-libegl-using-pkg-config.patch b/poky/meta/recipes-graphics/eglinfo/files/0001-Check-for-libegl-using-pkg-config.patch
new file mode 100644
index 0000000..0289ac2
--- /dev/null
+++ b/poky/meta/recipes-graphics/eglinfo/files/0001-Check-for-libegl-using-pkg-config.patch
@@ -0,0 +1,31 @@
+From 58d51d941d3f4dfa38be18282d3e285d76d9020d Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 13 Aug 2018 15:46:53 -0700
+Subject: [PATCH] Check for libegl using pkg-config
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ wscript | 1 +
+ 1 file changed, 1 insertion(+)
+
+Index: git/wscript
+===================================================================
+--- git.orig/wscript
++++ git/wscript
+@@ -160,14 +160,9 @@ def configure_raspberrypi_device(conf, p
+ 		conf.env['PLATFORM_USELIBS'] += ["X11"]
+ 	elif platform == "fb":
+ 		conf.env['PLATFORM_SOURCE'] = ['src/platform_fb_raspberrypi.cpp']
+-	conf.check_cxx(mandatory = 1, lib = ['GLESv2', 'EGL', 'bcm_host'], uselib_store = 'EGL')
++	conf.check_cfg(package='egl', args='--libs --cflags')
+ 	import os
+ 	sysroot = conf.options.sysroot + conf.options.prefix
+-        std_include_path = os.path.join(sysroot, 'include')
+-	vcos_pthread_path = os.path.join(sysroot, 'include/interface/vcos/pthreads')
+-	vcms_host_path = os.path.join(sysroot, 'include/interface/vmcs_host/linux')
+-	if not conf.check_cxx(mandatory = 0, header_name = ['vcos_platform_types.h', 'EGL/egl.h', 'bcm_host.h'], includes = [vcos_pthread_path, vcms_host_path, std_include_path], uselib_store = 'EGL'):
+-		conf.fatal('Check if --prefix and --sysroot are set correctly.')
+ 	conf.env['WITH_APIS'] = []
+ 	if check_gles2(conf):
+ 		conf.env['WITH_APIS'] += ['GLES1', 'GLES2']
diff --git a/poky/meta/recipes-graphics/eglinfo/files/waf b/poky/meta/recipes-graphics/eglinfo/files/waf
new file mode 100755
index 0000000..04ddd9f
--- /dev/null
+++ b/poky/meta/recipes-graphics/eglinfo/files/waf
@@ -0,0 +1,169 @@
+#!/usr/bin/env python
+# encoding: latin-1
+# Thomas Nagy, 2005-2018
+#
+"""
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions
+are met:
+
+1. Redistributions of source code must retain the above copyright
+   notice, this list of conditions and the following disclaimer.
+
+2. 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.
+
+3. The name of the author may not be used to endorse or promote products
+   derived from this software without specific prior written permission.
+
+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.
+"""
+
+import os, sys, inspect
+
+VERSION="2.0.11"
+REVISION="41b69b45f8aa445dce066a4aec3cdb75"
+GIT="fe03c6fa470f0bc3c086baafed8c6b4b6d28a245"
+INSTALL=''
+C1='#4'
+C2='#*'
+C3='#)'
+cwd = os.getcwd()
+join = os.path.join
+
+
+WAF='waf'
+def b(x):
+	return x
+if sys.hexversion>0x300000f:
+	WAF='waf3'
+	def b(x):
+		return x.encode()
+
+def err(m):
+	print(('\033[91mError: %s\033[0m' % m))
+	sys.exit(1)
+
+def unpack_wafdir(dir, src):
+	f = open(src,'rb')
+	c = 'corrupt archive (%d)'
+	while 1:
+		line = f.readline()
+		if not line: err('run waf-light from a folder containing waflib')
+		if line == b('#==>\n'):
+			txt = f.readline()
+			if not txt: err(c % 1)
+			if f.readline() != b('#<==\n'): err(c % 2)
+			break
+	if not txt: err(c % 3)
+	txt = txt[1:-1].replace(b(C1), b('\n')).replace(b(C2), b('\r')).replace(b(C3), b('\x00'))
+
+	import shutil, tarfile
+	try: shutil.rmtree(dir)
+	except OSError: pass
+	try:
+		for x in ('Tools', 'extras'):
+			os.makedirs(join(dir, 'waflib', x))
+	except OSError:
+		err("Cannot unpack waf lib into %s\nMove waf in a writable directory" % dir)
+
+	os.chdir(dir)
+	tmp = 't.gz'
+	t = open(tmp,'wb')
+	try: t.write(txt)
+	finally: t.close()
+
+	try:
+		t = tarfile.open(tmp)
+	except:
+		try:
+			os.system('gzip -d t.gz')
+			t = tarfile.open('t')
+			tmp = 't'
+		except:
+			os.chdir(cwd)
+			try: shutil.rmtree(dir)
+			except OSError: pass
+			err("Waf cannot be unpacked, check that bzip2 support is present")
+
+	try:
+		for x in t: t.extract(x)
+	finally:
+		t.close()
+
+	for x in ('Tools', 'extras'):
+		os.chmod(join('waflib',x), 493)
+
+	if sys.hexversion<0x300000f:
+		sys.path = [join(dir, 'waflib')] + sys.path
+		import fixpy2
+		fixpy2.fixdir(dir)
+
+	os.remove(tmp)
+	os.chdir(cwd)
+
+	try: dir = unicode(dir, 'mbcs')
+	except: pass
+	try:
+		from ctypes import windll
+		windll.kernel32.SetFileAttributesW(dir, 2)
+	except:
+		pass
+
+def test(dir):
+	try:
+		os.stat(join(dir, 'waflib'))
+		return os.path.abspath(dir)
+	except OSError:
+		pass
+
+def find_lib():
+	src = os.path.abspath(inspect.getfile(inspect.getmodule(err)))
+	base, name = os.path.split(src)
+
+	#devs use $WAFDIR
+	w=test(os.environ.get('WAFDIR', ''))
+	if w: return w
+
+	#waf-light
+	if name.endswith('waf-light'):
+		w = test(base)
+		if w: return w
+		err('waf-light requires waflib -> export WAFDIR=/folder')
+
+	dirname = '%s-%s-%s' % (WAF, VERSION, REVISION)
+	for i in (INSTALL,'/usr','/usr/local','/opt'):
+		w = test(i + '/lib/' + dirname)
+		if w: return w
+
+	#waf-local
+	dir = join(base, (sys.platform != 'win32' and '.' or '') + dirname)
+	w = test(dir)
+	if w: return w
+
+	#unpack
+	unpack_wafdir(dir, src)
+	return dir
+
+wafdir = find_lib()
+sys.path.insert(0, wafdir)
+
+if __name__ == '__main__':
+
+	from waflib import Scripting
+	Scripting.waf_entry_point(cwd, VERSION, wafdir)
+
+#==>
+#‹‰†[ÿtmp-waf-2.0.11.tar#)ì½kcÛƱ0ܯâ¯`Ôê#)° Z’/iu‚´Ž­$>q$?–Ó´Gfq(”‘€•&ïoçº#)¤ä6iŸç4n#‹ÝÙÙûÌì\nãéäâá`^Nª¬˜õ·¿úÉÿíÿ§Ó/ü«ý|¼ð«ƒG?z´øñÁá¯ö?~òèWÝý_ýþ-ËjPt»¿*ò¼Ú”ï®ïõÆý?òï×u.ËâáÅdþ0›¿ï.n««|Þùu7›óÑd~yÔ]Vã½ßBÊ·Ïޜ¼<ùâ£î‹¼;Ï«n6šTu¯ªjQ=|x3÷&ùË<¿~8™²U漢MæÕ`2@iu•¥+O¦Y§3™-ò¢êæe\dqy[vÆE>ëÞÐtìÊÇoªÉ´ìÜLóáuBϽêªÈˆVï$†Q§*n:[TvXÝ.²R˞UÅrX-ø#* 3Æô¼‚ð»4Ó|~	¿“y_ÜÙžo†Wƒ"~}úòäíñxÇ,l5ÌU÷%>.Š¼€J‡ÓAYvŸÁÊy+'Ì/¾Ë†U¶FÙ¸›ÔI•¦a™MÇqYÞ3ú¸…	=NHøS¹!ú9Ã:ÊÄÉ*I˜E°yVUÅäbYeŠü[#)J¦BŒ$#4š7¬{ƱZ1öêùÞ`ø×å¤È ³·|ì{\Ë5>§ÐË\d<™¦Sd‘M³AÉ œóœÐ`Š†nÞõ rS„*°%Ú+ǜ“rPU·›Kž¨“MË̌íóÓÓ7/B3“¨4Lßl:*Óä<ÜþӶΪ(·ÿlßú#4áìëg¯^¥oŽŸ¿Ý#)æU6®<Hoó…÷þfryåçø,¯ª|ÖRáóӓ³ÓWÇéÙó7ÇÇ'égß|þùñ›ôåÉç§8›|ŸmÇÔZþ|Y”yñ:‡#a’ϝfƕÛfaú·°Âò›íضS¿¬&³åŒ?ºU4}þ͛³Ó»°F$ÐuUœ”“‹)%Â"FÈ2ySÜ’å|³=ëè’9Ììjá,0 PŽÅ“é`v1tçËÙEVÄ0wËiuįÝÁ|ԅL!¿Fyѕ­³·/ÒÓoÞ¾þæmú峓¯Ž“½ƒN>~óZfR;[¼õ®³bžMö¾Èª³jô%€Ÿf½AqI»Xr.­ìßQ ÈJj†doÍý<Ÿ—ù4;Y6ÿl9gÅËù8oV¦Û^¸~EýªÂ¢×ŽÝ™)ú6[Uf~µ ¦ó­ wUþùd:•‚§Ëj±¬žÃÖ?ôm+|44ûŠV‡¾êììX}Œë}úê§ÄõþÝj‡ÃßH6Î7Ùî#*ëC‘¸ç„wv¢û Ó:Ç?ˆ.h!	ÖSÿ#*àžüümHmH¯&e•·Éy¿\Ѿ’„¥9p“ä0Âͯ¾ualì|øՐ;*Ù´}…\[dJ¥%¢ã<ÙpŒ9™‡¥—Ù=F(×úÊ_èaËd`肏œ#4óbry_‹äþûä$œ*]L˜`IŠ$9‰UÌô‚€¦…Êì'AÅÅÂ¥¡äƒà1Ò®H§“¹•Øã„òÁYœÐ»9Mù+̤}jw-/‡f{¨æɸKp’žîXSŠL\•0½¶3˜^mËøsdóÃ̾¬®ɈtEïO´¬¦üáðíÀÿôwVº·#C´¨Dkþ¿¿<ÒÊ	ù*›+Ѿz6_µI#Getƒ(vЊm;dbyÕG÷«ÖìyµZ¥•–HýЪíìå¹×>™Vä‰ïGﴕŠ¼yËÐä“?’õ±{°fºµO⬌§Í÷íÏ̽Ýóx®Ï[}äOl±õ3ÛÃ1ï5¹£]¿1^©?ï­[­Ñ?gQ¸-r»çŸ²,>¸r\ )S¦ëâ>ó¿…âè#*‹l>jßQM½ùb]µ0Ë[ òÄʧ£t‘‹¥V-€aÆß9Ÿ¸¢XfÕ:oã2[Ä+>ôzð·bxÁ„ÁJ·“U|íPMº5I÷éßyvC#*æå=›ÌÃÙ`Ë|ÅÞBˆbûíÖÿöçö™vÏN¼NɧËYs]ù{èÏÓÊMÇñOÓÂYþ>óÆ}•æã1´;ž5÷_!ëÚ¶fƒÛÕê6ðšNؽm-ú“Ž?õÎrÑÜ+°Ûu¦«öj³Âƒ4Êoæ#)k¨i6®îµºZJæ>#)ØXólUµ“Ì÷ÞZÛq_G¬ÞÕQ‹"{ÿ¯Ah]w—‡—²Ò†® 7‡ÿq}òÉaô<á_øy}úéam/jٟ!µ”͹\L'•Ù˜ïÓLàÀŠ¤q¼’Èš!ð7]„/”ŽvõP)/8¾÷Éð“G¿å/Ä¿ÿ±¿ÇûÑT¿6}¸÷HŠ…÷?^SxýP+ýxzé±a˜$ûnñÇYk–)uà”ú!Ù_íÿÖûü¸öù·ûÞçÛQþíoqèäõã}ÀÇNÂþÇù{ÊÿjûÂ1â*¿YKÌ8¼OÌÄeßKt?y"q5e†ÄþO‹^úº˜Í€O«Öð·àYp$[w|&ϸùÆÁsy£=/^È+n§qp™M,>ŽÌ_G–ˆƒ/啰ƒ±ÿú_Á‘˃ÅÁWšÀÀ® »½8˜GNGÆÁÌT†o% b	×8X»!(㵪ü:›—I‘õ ;“iáïÞ­.ޝ‡çû{¿ûýöDáù`ïûg{ÿ݇iyþüÚߍ¢ j¹JËîu—¦¬HsdYàæÁ»ßp6Â[9ÜH(ŸƒkoÓ`0†¶*eômžÓñr>Llio¸{—ìG³Q¤¸<•1@w’ÊGËÈ霥Nygo|-÷‡™d»ÇE¡Þ¿µÜÄ´9¥R¹oñ£¬ gÂVÀz›K4Rbº)’N¾7¬o1û(ŸË²­òQž#)Ïe:exµœ_'?ùä€×õÌ».fûHwåQŽ’[$ç(sŒ¹Cá,J#)Ð9Â?Â?»”—$¸(y¬w“³,Ç1åmåöâ€e&gaÏBàÓOyÄss^MæËLЄúJïˆæžyÿ‰îwEª}煮¬¥-®Û òee.xamIjV&¡ˆà»¥Œ#4¿=A·J¿]‰x‡:æC¤Þ÷“%c£a©¦¨¡ƒ;[~°T·v´Hr=¡Ê(Vˆ2EI—²ñx8¯¦1b1ÉËv¥&Yî¨è¾#@œã%ÅûI!îLÁÛã7_qD¨n« -gÍÃ2 >øüźs’ujùU×'ÜrúӉÝ[΃áu¸ý%üÛæ.èMòa5#*?¡}Ñ{ûòôùß¾<9ûïXŠ¹…öùQàÕCªì˜Ëœcúz¸;(»™;ëÍþé͂ÊwþAýV¸y¨·Rÿý¯ýýƒú_ž>ýEÿëµþׯ~ù÷Ã?Yÿp^L`ë™_þÀúŸO5Öÿ“Yÿÿ»×?©l¦ÀX ®WšªÚæͤºÂۈ*›eóÊÑ-¯¦Ù#4þ.«	 Å`˜]À	ÃA>ÏQ4ÆBk•Hc ‹Æ“KT}•_–ñ)³š,4>!#!SƟ-'ÓPã¬séhR¤Àî0›	Rɝyž§“Ù…òTerµš ßõ°ø§d›€lwˆ‡>€¶·é"'Ð²(àkȆxAC5% CNHD¢‘îÑ=͉©êV0î}ûìó?¿9{yzòQ"%‘V "¤0ßH?#)–xw‡5Ù ƒŠAq‹¯#ÎÙ ^uCƒ|ŠƒJ³2Å©X ª²Õ¤#4àMsb3á{ÂÙlz±œSº¾OÀ[^QR£':[t1µî£Ž@R'ONŸ¿zùõgwr]ˆâ ¸|}J²«EÜN5LÓî±TW½ïrd·C¢å€ÃT-püé|0ËÂÌ(1ü(û—¯ß¦Ÿ¿ÎAH]*=)q9´”ò¯º2˜Íób†¡&#)vk*f¦é:-0¸(	#)þá+íÀ·órÚLº#ÃÑV+Óà)`]¦C~#*ƒœör(ϱ®…Æ#J 4^z•.‚#)—!pøùM#4Ìä<¿™S½<H WålºE~ݼŒÜ8[°Óh‘¬ÅáÕ+ï”—‚Áü(¹F	Lc¹©¤÷–%½N*ºíQJÜÑÂkÑ4zxyèÖkèée‘˜VwD#)‰GÃ0-i¢N'ÀÂL#4œ¦ûpzf•À0#ës¹ÛÀgmÝ]ÎQ›%A±#)Ìesì¡g'6#)`ÖÄlš=óÄr#ì‚\Pz0#4ë«*®ÃŽDØ0ϱa¸‡S«Îñ©wöxàÓ¾£ïvÌ«φ7+fÂaY!ˈ˜ÈÌÁ)©³†že#4èÐÈà¯T åÉ8ð+› LÊøîG‡®Ì#*†.1嶰åÎøš®KÌLwqšX5Û¿Õ:Ìnãëâ8cA¯&Ù#4ó¸9È9ÅiÖÜ#4à¹'ó÷ƒéN±®N‡ÒLúù#)ŠëäÇU_¿ÎˆøtA;ÃägÐ%댝·‚tk5ª®@ë^ìLí¦Ð@ÜQ )©o¹v±ÐçDÖ©Ág~Q¤ì~¢YêçNcw§%SC)nkC™KËÂa\Veèž%ÎNxs•Mi“u‡ùíUVfÝA‘uNë^fó¬˜µH7œç]öpQä¨ÑÚçËùˆÅß[f£/z‹ˆš«Ë@%èîªF•uß,ç]¢Ú#)p:ʊ.®;&!#*6*šs!,hX/ݽ«.®íXií:}"«ºjx…›h­‹£NËBk`#*½¥èÖ·R‹†…ØŠ^SÌ ¡é,-ÐÑ20)ڃ#4éÉH…›õs¼9~ÄY贋ÎÙYyYëæ²*BÞf=$ÖʜZÛ*¸ÑÒ¿O{#*.Ójqa‡Ñ¡OÀÃÜ4o™Š¾æ¤x;#nxš‚ÕÂôƒÚß°µÿi	M=­C˜5ûÿP½jUь^$\Qïÿ†õ¯½ÀŸߪÉ,"i)§}ü»XöSÝçÍ~ïc`7C;˜~]èáÄ#*‚~lj6æeW	÷ãй›nùP€À+aúÌlVkšb0¡ÝüŽ©ˆÈ҄‘ù÷©ÜßcŠº-ëi¢7Gµö³ÛÐ<†d–ÏÖpkŠMï9ýüù§ð¾Ên/òA1z	³º(–2,Í&C6#4|pOuTñÀ]âˆCJÔ÷‘eˆ.å«åˆàðl–hè¡L‚>&&[Ç(<À/ÚÐægV/½4ÅÇ4µ‡%¾ã²n#)Oa-«4•ûè#4ïÏÃz®‹ÇXMÇPÊÀB–UŒðÞvÎOWِi`EíڜZòµÁ](4>b)±#4ÃNd ¡ˆ#)/¬?¢–lƒª¼Î•‚.LR°!®H>Ò½Ã=9-<i³U6D{ð+Yír!õ4U·tä@36èƒõ§º{¨“vŽÝÑðB™fٍ2Ù¸MÓü2ō´žz‹Ï¡|ÔN¬aÊQ¾¢ÀÌáZë&çj¿Ðëä{ú$·=\o	Km¤:îîò܍”]kE-iŒòØDa/µö Ç´¯DÍ'åU6ê–Ëá0+ËñZÕ#*wúÑR±×u„Íòà3ËOîPÈ[l6¬æ÷X¾EãþRF0ùs¤§×nNZøÈl¥V걀¶G#æ~à—Ã~ٛåCüq	"áºÆ¼5¹4/Õ:æɲH¥ÈPá$k׬a‰¢öy¾œŽhpY ^‚XËQ'è‹Ï`ŒEˆ‡]ÈwŒŠ„Eaµ†íf^Lé;’UöŠYUdYÃ&´’—T̍Æë‚€«,»$A¢³$ÒhP#* oùœ-EÝ^ÇãåÜÃ/¯ÝÛÆ+íéY«%ôÓ;>9=>yëíº÷zó®dä)Ž#èqG›!	Pz¸wØå¿øòˆßà'M½ÈPK×®¤e¥ì|£C¼ñˆXà5¶Î&œXŠ¼.S©£0§›ƒdEÒ¯­"™5D³×#ê3a'y+êÜ!ƒ'wKUœq_'±o˜uæ°å±£<`©	‡5G	Mv¾öeC´Ðفš$uxþæÊu܋óÚlp²5æ…%dÜ\uá‘2;¼îý!¹n:‹Øl(Q‡F_@[Ìv$¿²#*ð鉘ôáÕV›Ã(#?¬|y™/‹!~e´;àù`/Á3læy0½Ì“#)VNïâûÃ#)'m•RÚß~ä-EÏO£hÃú¤jÏeáy]&²ž<HfÎJhŒ;ž£X…¾š*„ϬèšhksðùIåQÂ$…î<§Ï(Œ:xƒ‰¬Ÿ•K¡9šMùß{³Áu–â‡ÐÔìVŒ_z£lš1©±þ\Ø¢óѶƒ^C‘#qï@÷»›Žìð˜H·ÀF”ÍCªWEúQÜ»J‘-¦À	T¢‰ÜÖ9«e`F¨XRá*†ÇHjí#*§¹¨à‘¯©#I‚ï'‹€Ï7x—qۂÇD^{ÿ=Y|Žp(xa°(€’åb³¿|¾8þüÕ³·Ç/Öb-S§67hÔxnìƒÝ#*lŠ²ÐV¦  JQC\9ˆ¹°ãµXaY·od«¡jÆp6OÃà´¿aguÙ;#*	ØxÉÅôpù=ÿ®¾Ç#*ûӝ[$Ó¸”WŽP£¼>yj'š¯€…âe‡.}‹”&vC.žàíÞ?ó°àÎŽ§ƒË2	Š˜.½«lÅÅÂ!z’ÝØMˆö¥ÑQw§D¡°YäÜw\^;)/Á£N&åM¬˜f·áþü-˜lgC³“';ð0Ñf©ÕQÿfüÞ4S8¸þœ¡¢E6ž¬îž4xo9‘f'¿]zoKª À#*0°YüDç#4Q/U«¯ºêÒ#4_Ä4@˜yÎcƒ ?(7%ÂØïdìMÁF¾úpkÍ®«ÓÍU¤´ù6î¥n‘Ú´uÚ»Q¥?aîÞ¶[ÎoÍ÷dÔӌ.„Í–›'Kouë((Ön;ÖæûF¬ë&t/׉P4áÙë×'Ͼþcžc)ÉýûÝ¥õV>8èíQÇDðØ#*ö‚]Zë§=ÚЬéæi‚9î5̕ 6=-GYZd—ånÐ}ðà!ù½øØsž™Ú·éæåÁÿGaÃúŽÐ`…Ÿ·C}ÈùábpÍå͂ !E¶wó ¨]#4	™ÇËl>âɅK•íùô¯å5jÒó‘«ÛŽ#*܅6؝6>ÍnÔngÊ Ñïý@ûÝÉlI™Á¼J/§ùE`§1‹YH4ڑ³2¸åL¦I"8ÌðäºL§t'Sd˜‰ÐP’”IђÈP¢,™û%‚!>‘´AéRºD«&üR±Q&Ädó"ÒÏ "3±:˜-”øŽ/ùª½E’fK¢î›)@vÒe6vsoW§šV]C©²Fj^ydã^€Þk¨ÏYT‡‡·5V‘e¿;êJq@òø%ˇéž–sû¼·7ʈÃM‚]n|ð±Sêâ.ãþkôٌ¨¨ØRötÎym…§_å	äu«Â=míùÈG\?­©7»ásôð“&µó"’^b‹Åæ`PY"š,—Àk¡ø­÷šðF;áͨõDŠ`ïšTJå{…Q¿U	í„ïŽЄ©Ã'‡œñ”®)ÉE¯¢y?Ø$;ÌFÙ(îÂZåE޽ɀ2E[.¹ÞßqšîK²Úûш¯høíNAï%NQ—G3«²š)]fM#»_¸¬r3QCÙÒYV]å#¬¤ug°ª#)\®g¡¸G˜‹w6k¹Œò”áGÒÒ¢õRSoh׀¹·†›Scùù¼·ˆ‰~‡Ù8D„""‹’6‰fqç:ðŠm˜¬¤Á9¼˜«Êr%«ä*E™X^ÅüŽüÅ83I+j?›ÕzÚpZ§°bs^}D""dšx˜O¼‰ÂjÇ‹ø.g#´tAcâ#)¿ìÞÅEV²Íõ+	s¤Äɐø› º®Dâd­	¿k—Üyž¹Üz¨€¤?˜mÀÜ4>ùƒ#?Û°^üҝíÑ_iò)ñ×òúŒÑ/öÿTýÿ·ƒòú‹lþ³˜ÿÜ¡ÿÿèððÑ£ºþÿÁӏÑÿÿwðÿ<Ì·è:/ñÂjXåù´Õ4NP>HX_Ôô­þ>©ê³A¥Wír͍»`ˆ®N:_?{qü&=þÓÛ³ä<è]áUäÕbA?«ý\}aQ*¨/½Úκoœ#*íPøy1’i”¢ßtÚk‘:X#)3²®þ÷®ã®o,/Ãó*…R‹…yL¤ÂÎ[:°É°—–^™òº4<	j/\#)e§öõÃ‘oR䥓ъ}#g»‡º¨€'×7çTI߃¯Ÿñú£P>ˁh²ˆü}˗ȻÂÀºWLÄχ—sÌØ÷’HøƒÉñ~´{p‡ßL· ݁ÜQÑA¥ê2…ïp’.ç•-rwêýp»ô½¾ÊnQ;¬KƒÞƒ):S›aÕä¡ù'ÙÌÜö]¦¦#•ÝþDY‹d°@`Þ3›ðéöÓ$ím6ºÈl£¡nÙY2ßvµŽ¯íªí/Ì!äR‰GöÃ0Õ!åê@«®ËöN™ì”€ä*FÂK·õ«(r„Û#))¸aPd;în3	#)£#*C^Ø¿z¿uÍÁsrC­¹Û…ŠžûrEßM³YÄSª¨#)j€®"¿Ÿ9+«–[i*K#4q+4íöiÇzÖRúRà¹b-+H,ÝÇFmÄÃyY>_#)K]T·¡öS¬Å¥·«œ†“WØ=§3 Í°=knHSŁº¾vÄݜ€V°ÞŒ	ðs3Ü$¸#)”äYB¹”gE†r8‘BÓþIro¹#*€m¥së<xX¹”Ù×%ðÓjó-j,ýÂK½Jðª¯îòDtâÖmÆXí·=:	•Ås¸P©„mǀ‡'b#)ݽ.Уî ê¢ÛŽª½ÔeV†­;©~Ä$«¡c’¶X|J«Bâ›Û&ýjwÜÐ#)y±û€ÏиD³qC‘+3;ËÀ+áî‘úlé(’Pfµã0l¦ý#)Y7–AÄ5‘"pXd(QÏԜi+_Êæ&N=f¬nŸ!3fÝ"wè7H™âÍq%S{3×æ«ìv£Ì(›vR¶æÆêÁš0aFǪÅtÔùmÿè.SÛ3«ÈIkíÉØV…ŽL΃ç·Cè¦QV©ÅGJ7dæ0KˆVL^Ðù¿7ÃèžnO	ö`ïÆ*é—ÁNx»ÒS›*”¾8Ãh—½›ËŽà£È'ÅHˆ—Ç(»X^†—G´› ¬ðر2žÈAá-^1N³ãý>©Uwkge}\ ƒ.ëÚ rl:1¨ vîã`geU²­ØûîŒ"X¾þ[ïíÕpkãa0Í­°êMȎɻ£žˆWÀ7Ôî„ùdÀ;#9ê˜Hk™÷û#*71Èmu¯­>˜=]µìùµ»˜ÞÞ.Ü.%Í2²Š#*͙µmôv—֏=L—k•ÖQÚþœUŸð¢ƪ+ÅØ"D‘"ðC]d~m‚Ý‚Ô[©4ˆ(×bïÛc6.‹!ÑìquYñƒa70gânóçX¢ºÝ¥Ùc3a‘âiR嶠à)=™/–UBºä€jý9¹ª-Cø	†äÓ	ô8]ÏøâÌ|•¶OsuTˆV§4w²¼W#4,ŒîAhúD¦·kHG$çCú2êq«¹•¸æêa±ÔéMwndGn¸‡š„ªi”RJqø¤4À’>RÀcÅÓi#4	å9üé»L™AË)Uã۔²£,ñgn ^“Ï#4AhÍ@Ó#*½UÅ`.³¼²%Ág¯¾9Æ»Gœ1pNÒ™ñEÄpL7>@@‚!”ÃÁœŸän*5Œi\^eÓ)÷¶_àûô'Füël~fãÇ<ÂlFØ.ŒïPò¡­n< ‹Zj;5\Éèþ1í”_m,ÿHƒé/7ÿH£è¯,õ•£#4c6K¤%¨ÂÔ«÷|ŸÈ"Xï,Úu¶#4š€àEÓ>ñU"îÔ2¡ÑÆÄ.NXueOâ..H"®y놉1¿Ì`Á«ÔaՓMA×ùµGfò|DãkveÀó4Ã1ß#Ï·‰P|`¾aðmû";¾|Üßzk»T ¶KL8YßÚ	j¥%šJû¯Ñ¼ÓT¾ø7yòÄb¦<ÊǧçÜ]7E3:F<-ôh¶ÇÐÎ<›Œ_^‰Ñ‚ì[eý(žÃÎÐMK¡‘ÜÎћ½À7&;eøàZ¯ì`2åè=¡RËÔbéšIzâpèìÒäÜ+Ûwõ}A7^ÚΟ#)CxN},M×=í㇠Ô"‘õöÁ—¯HqÓøç6 å.Ü-œ#*p¶8}˜¢Ù’~#4ÜW-H»ž±Zãüyß™îf¬’ë›SÑSŽ“ñªr:ZŨBDé¬Lm#ÚٍpIGêDwußÀŸ¾³¦ýkZV-•C B3V+F+HÃ#)I½¹ŠÖ4³9Wž!pp46r)hºA(‡82ž3FÙ&%ÑMǬd>~DæÄsÒn@¬•±pøI9t›-:ÐÍ$x VL¢Ž‘2x#¿qEê~|©g	âsâiA•=%ø³Yv…0sNÈbð÷•ÀG²†9RoéLIÌážÔ>ˆáüÜ4®œ[ç"‹èpjºY{D³º”„WÃÄȚªëÌҐôJ(§§³ž1Ý\D@ëY>ò¹Ý€ÒuFÊ$PmÈ0-ˆE¤À$W#*¦NÄ&BA’ª’L-éûAQÖ2`M¢úP<^¯„S#*|¶ì&/F-9å‹É½DÇ8ÔCµ¼¦›#)lb@¤_¶«–ÝùÄLþrs¡IÓ{:Êe¢«^-Jñ„Yivkdñá¾Æ5u+ègbGŠ‰T&|cé’Øip¬cêäØA8âN“›%@Æô‰+Ç”xûvñK¿díÙï:q"[Þ§e‹’U×àú:ŒŠ|O2]‡Þ²&‰TÂ3Àl†[æïQS\O}W-S+¢ÔôôLšî‚5û)¡ò6¿«áÜìøh¹»8‡ãpyaéex½»$HÄnd‘lN!™͂fU˜‚’"…ÙB…©N"BQ‰„Ìdliy(và?˜;g-3èøÑñ%LǠܞÖev\õøõvRóYV/sëùidtÖL“&0âÓúºeN-Œª˜™Xû<FR£›AٝTæºî÷‘Êø¤…µãÕ¶Îé+ìy}¿¹ëtË®ÊòvÖs™®Ám@ #4Zè„D¾Ä¤È¬²À§úÊë†,Ek‡š‘=¼;ˆá.Jè]C ÔÍW£PV^!x7…à¹Ó¼Bój¬ÊžÉXTR…Þà—–ÂƒéÍඬ•åDØøçÖ}Y­N:Ýbëo#*èê8ÏÎm˜Ìµ;¯]HçµkĶëŖ{J‡2mãýí%+­Š¼He‡#*á¹&ÈæêùN#4qmÒrµ]ä¹|µ{÷÷ðè^™Œz¼ØácöôéãÇ2¯ÛiToÂ9àӶ͵è•4 oF5°F—êL#4~‡	jµu8ª•ÜÃÊפñՔÓÕ!”Ë쯁úJùë2ƒRR¬qia{ÙBfïöõ|ï ÿQø%ƒ#ï~ÆÜÕrÕì­ký•C¢µ̸ܵ#*£ó ì½“×jµ@:	l[$Ðæ;I¹}o‚Vú͓ý–¤ç¨¥I['MjW¹Ç^‹?„ïnv£?1$~­fÆåò¢¬ÒÅ0¤£ÿ(×#*@-Ы9™d–kïÂÝÓÎ%×ý{VÊéQM­DSídSªIüq܇I™¢à¼ŽÅ$f©ä|9ܲ³©ÜLwºC–Ôù¤Ï‘¤­7Ä¸‡ÚŸ¾ZW/„[ºÄÀ«ÒˇäæÆb€c}›á›íµ9*®¢…(emèX5•…:!2Ö^îXÒCmîƒüPð%q¤Sö¥Mâuj #)¦Ðó½¶WÞÐ(žÄµ¦#*[ˆ,“QbG)Áƒt)±ù5N`Ë/hÏÌÿÝ#*ù€¤6Ù$Wl¸w#)ÜÎMA£7ÅN?Ӑ®(¹ù—	½ô.‹|¹6^†M½(Lt©¾íÔ}*·w.Ù󖤓Þ!!´®Á´åàö?öuˆH™^VnT•Ñ°Ú¨Þ4<³•…”¶­Áf…vî*ïÈæïÏW}ï­·„æ­Ð¯é×#È@®øáÙs.S»¦¼(o1ùF(Ud-{3t;£ÎÏ3Zx€bpC#*SdK`Þ£~½åö~6mˆÊÉemQ'Y?sé؞\Ûh7iÔm¢)V5:ðº\¨Ý•î?hƒ"¡J&tmûZÄÏÅÊëCw’;à›2~-$CÚ0F֙ƉEK[Àˆãp$˜íVð‚–;¯sñ!âþ#4%§Ù6­«é#)ú¿IFx\·ƒžõŒÍÿ¬\>è-†°©©†Ôðbؼ…leþ¥6Êׯ4jJJØ| #*¾‰º~ó·W/?{ñò͏חl~òNõõ×i™*ú‘F·qˆWüt·¤7\)o]d͕¨ÄºÖn¤7IªkÌ_1¬] ´søƒ#4 ›#)+cÙÊÖ#)#´søÓ·þՋaôÇ·ºdnqÍ#*€º‚ì"+ºùXŒ„Šxg-Þ5B“8&šøûɂڨ}Eq4t»éâa¾œNÕ3úm­lk_°*¥©¼+E®·‰·&q•$ŒÂ ©±±d=ÎҗçÙP¢rŠãaæÖ¥Àjþ!.#4S´Ýš<°kô·†ïnàW>‘œÌ+ë>BX5«¸uª¸HÖsò·­•Ü6*¹Hní(6#*î°!þҁõî”ÖïNA#ï¹~º¯ˆjååÞRº¶1Ô#)wøìëú ,ëZ”îyv“Å­cœ¢£wQSE0qþp«U#4û¸K&-LØØйwmŽŠ¬(,@öHW~ý}õâþ2š¤â㼞ýŸ5wýÄÿy|p؈ÿóä—ø?ÿöy‰Ö^pæCâãÅ¹Í ÐZþ±U Fô!ë@#*æÃQ|ø¼è|ûìóôùéÉç/¿H_~‘¸n>;Ž‘7ëUâKŠî#€qBÆà×ÆwÁNLtTvó¨›Ï»¨“{©·ÐU¨«»Âß÷Yiáàb‚Å.&QKÃûâ?¯¸4´š¢Œõùëî²$­ñ\€”_£C¦Iu¡°µÒÌu¿Òó`\º6ïä†;帔ß~µX+SÅ%rÑm¨ðiÛ3å¨Hǚ¢•B&‘6duÅ"ª©Ìù‹P›cB=¦u#d͎	$rQ¤Ëhå¸’[.Þm"ÐPy‘±ZÂw«Lì«{ïB#4RlÖõðG~JN_7ÇOÙR#¤êòµkµ\¿÷X.a›¾#)ÿ7Aܚk'i\ÃbÍ#)r÷­)—é5¾ÚP*!Ã*ÄÙ³ë"-eþ•Þ¦ù‚®†³¸|‘¸“Àƒâ–•rÔýp –ŒwzÐz{úÚ¥†êåÛmRñK=¼¤Ù‹—bH¿¡¥å!e1wx´xcÓÌHÒ,ÔÐ/Dr  ÕÎÈ]s5(Áõ.bÝ–ŒwvÑé7oë]ÔV‘º6±Lq»»ÿN™¿u½;+п3U´d$—•ÒDí; k§#EÂGÈ#*H[c–M=lY®`?Õ`Åðƒ—·Æ”á¶Ú¼—gžƒ6bväìÄY+™m¸Éí•]1Öuni¸5úm1-eϟ=ÿò8}ñòM£œÓl/òÉEÛQŒýSՀ„Sõ2+²"8±ƒá˜ep®Ÿt8Äә€z^pnn('®ð´±a™ˆo±Æm²f*ю^1Ä·¸Ìàì	àŽ#)é#*éú&Š:©ƒ#œ¶WÙJcârfó;ŸñÔŽ¶Õz؄ž‹¦‚£–hzPöóÏ^BÊbÁç4$ÇÁm²Ãx[£´ò2àDalùþÍÙ7ükªfX¶L۔$VqäïEI¢)R"ª».rQJ’.1Ъ“3q.þ£’:p=H½Và}ßfÌÇNᆭê³"ëÞæËî¶ÏÙ*J¨‡7pJ¡m*œFˆZ²ÝÛîþž0»“ÈqÂhTû¼à×zH«öþo‰F×Þéwx¤Br#)'X¢3MÒÖDMp]ùžuý#_ê!÷lØ.Çv= ŸV¾ôÃ÷ÙJ½3%†R“Ä6÷†ì‘.!i·g“Ü;9…mèùWé˓ôÍ7'B‰ÕƒCºYè¾H÷’ZO¡+Nã¯Q$öÆ`]­ž¾6 È]C–{#ãqO„7º&ۀ0w!Yî0í	÷BX²·!ÌÂuKB{vŽ›ú×oŽ?ù'Ý[êk„=ßbëÚ¢þÙòI{Áͮك‡Æg/Oà(^‡šÓ«ƒ6›;iÏÖ¬T²·…eÅ×JÁoþÆøüˆŒ›á Å&ëÐ>ÜC‹s'íٚhIöMhAQ¤‹8¼<}ç°exn‚Hô<-cHvk){\oqK[û\®b9É»Iwµ³z7'6ÞvŠwó`ÇL·/ÿ¤Ç´å6ÅáóM#*'àãŠ>Æ[íۇîÙҕ¸8‘õáÒ`-Õ,Ã\¥¶K£åcÛâñ»ÈRpPr×¥Ͼù†@—94dŸ§È5ãÕ=)ŽŠ`¬¾sìæےM2Qƒ1f&ۘdn1Ÿî_D¸j4ÌЅñ⚚%Ä5%„WêS®SÖª¨nÍ—	•QÛuÜ­"m5Àøò…¼Vÿʈ	\ûB!‚ˆ†ñ“²;˜¢šË-uºÕ,¯'dp;˜Kôn½€¢µT1ê§ÜLdVU¡-TBáöi“0 ™?$ޛëQÀq!oÃÀxsØr2dŽŽÓ÷[1H§ûÐáª!G„‹îø‘½¦Ú€<бè8­ãæ÷ød¶ Õføï?(:õŽßjȨQ΃Cò| ‘ð¢ŽæŽAñ5Ê@ÙûÁ”.oËÐÌǦt9vD™ǵ®¹’Z†ÖÜÙ¶rƒŠéÅq–iLO1ƒUÏò=o´à7´B!ÖÁ”¹õ·#)_·ÁN¤×ø»5,€oÁ¿?FÖNªþ•}ƒã;Éc¯¬#4,¬pη*1鱍E`…Z’ÐÕZoòɶWztüDãkm'á,#*ÕLJfÂ6?²ë›Ëä$GïºWµ­´añ¯$Ä8d5#)ÌŽúåM ­ ýq¢BÇmr}C~c“blŸêî£ÆB#|£7Zž')öÈ]€Ž±±LÆNð@'`søǞ]fds7Ý}6ój#:Àž1Ú&y™Rh#4<1º£æcg´\ØF:ƒãX¸~¶]Æá#)ôm˜&׊ÈÑò¸èVÔÂbÄâ^Mkq̈́jfˆRŽT‹ĦÑôMÉóPè䋼ÓjŒæ湺B¬GuÕô<­·î̀RĘvÀ{ßd,³E‚ä¨çzÌé°ºX½´5oë}²JÔülúÜڊ7âN'#n<>„R㮘Mæ“$8èý®÷»ßñl°‚·Ã>0KGr§NÒ#*r7D.t¼žQҏ¼½íѱ…Z}:Šé	ÀF‘®$”85ÉÁŽ#*>_Î!øTäMîÖàVZ^Ñqz‘YWYr°IP坰*Iª¢¶:ÕO>¤ÎY~w•T«”	<âÎ̯¥£¡"‰µU	Ã'º5¡8‹“ó¾ÄìΛv̚ß5óPõ [Ùjûײ¬=ŠwÏ#Ý°kÓ‘75Ԏ(”;Áz›E~Yfµfë<„ùRâæM|1¾¨Òƒ2”hÒ@!cTڏ{ƒ*FL€Æ«=8{‹i,Œ‹JB<~|Ó(›ìܱñ#4#?¢Šc²f:[0Ȧxâ îê6¨¹pM#4“#*žEÞ*‡#$±B$Ú#^pp¾×ëC®40ý„j±¢“±ý<ÏkR,p“t$bj.±nªØ0Ì6¯'¬xýìí—]¶#™(°=r}¶…Ó¥˜Êzw“F¨œ‡Ž–)ûþ6õ¼—E­eëç’	³…Ç	&®-éår[Óá7eiÊÏ?(nÍX¢_–RZ=Ånï9Èú†û¦n‘OúÒùx³©ä6…“Žã1¹z_~uüçôù7oÞŸ¼M¿9;~;Óîg¨êÕéóg¯Ò¯¯}yrìÕÕڛ`ÁÆiåFLN’Å—ü°[ד¤|°£ iâªÉÊÚ½ÓH6Úeàk̅ôà‘>ÑYø×å$3֑oDû”@J`S§)Œ¸#)á}¸¡>\s_&j#4[h+“Ö;;¢ÙqŠ‚7êÕ·IÑ20qº{‚¡²#)7³[†“&KÛIAFL™0ÁŠG—IØ/C‚X.Äi—kˆ^^t”³³¡PL<#*o#*ùè2o¢ý]*àØÁÔÎYlÞñPҒ£1(õP4t)ƒƒ«bvŒ®$œÓxÒjgß|jëײFÖ28îûÕëlÍa¹4AG‰ˆ¯ZÝyúÒUŸ©Ëš5×°1[¢Žgc»åê$Îk8Ï6nnߣÖ{¸ˆßGžçc<6>JÈ»¬ÙóÉ^n×ß¾ì2±¼ÚIèÞxTÑ.±ü)ÏÏ`לGWÙ*¼²®4r¾¥‹[–a­‰ì c³u™Ýé>ÌI‹c…ìǦåÉ#)Iú4s-|"zCٌ(CåkTŽ7FePͨõ¦Ê§ÌPÞ n.dTƒ;#¡ˆAŠ»å¢^Éwç#*Pý—b'KæÏN¼¤·Ø5Ɨ­`ÓàîßÁ1­{p'ͦa_˜N]…@(Ð#*ØãΈ”iÉ«\÷JÓ²>y*êÆý®Áœ”pGlPÓ#*Lֆc—*c½ÖÃvè%ž EþÏ]µ¶>…--.à¤Ùç4V¯/“#)ã¬a‚¨8ªœ®âkãŒØ•iK¸Á#q%«“®o …qr²ñë9¡§N@[ž~Ÿ…ìÝ;0ËIç)—e+Ù¦¤DuËÍ4k›"G¤ºÑ.^ì´Noæê’1$#)ñÄû~°ú–…¶~…Eúµe=ð±ÆŸÛ.6,HãìߋÅ3¢õ؃7â™WR†Ô²ü¢²Iç™õÈ8‘›¿Ä8Àéab˜ùÒôeZ'ê'8ñxµ	Ï)}vDZ$`¤€úJŸáH²”^f–!,íqer2Ë©MB9á¦Ö0åՏƒ?¿zuúm`d|ÐRx#)Vý"/³O¬©Äº°´o‡Ç+¥Hae©ÓÇé8’îrl>ÃÖ`	']:ÐRÓЦû ë„D«‘k#3ýz:±ºüškƒ*œÑÓùûo­ÿO¶7?KðŸ»õÿŸ<~ü¤¦ÿÿèÉá/ñþôÿoKÑþoSõgÑâwãÇ¢^~‡"Ââß_?ø5þô~ý#)vìÐ[JoÿžÿñL~> /½áûrr9‡ßΞ??Ó_Éð¾,agí•Ã!e/ßÏõW2|6©¾Ê²4˜~9©ôWk€G[CïâûBýTÍ~u)?’~ýöD5ÈܛŒJ|ù¾üH9FðXÚ'Í#*ìê”Îvz{q–ž!€G÷+sØ"Ñm#)z]‰§á€¯SŠŒoRŠ¬÷ýåÛ¯ìxŸÀóõ*ùn•¬¬Žï»w@¡>tµ~>ä>ÍVÖæ#*éôZí1IQ{ÃáÒÆw ðz“`rãA•PÑú„2ë<_'׎ú1àqÞ뻸=@ãänÊï1ÅM؅„wïvÅEÈuüe§üM°s]ó2#)Œ²ë›å:Ö¾•ËŸ­Íwáë¬_ŠE-sUV̙*½ŽåÊÙ¹+v{p)˜‰h_ýQ'G¹¼ÀE‹~gØ_ôœ§†w`¡)¨ÄÜר¿ô¡0­D‘32NýlFdnø*¤Ì–”<è·»ãw œõëÎðl¶¶w0iÀ«A; hkºD׌ŠÓh¦Ï¡“¶NÃP#€›Ùwë³ô‰f:ïcBNv>@±¯ÕE¼ÇøQ£•»‰TFêô…”&;[iZNóªLÓ$Ï c,%Ô¢…ç@é|˜wRyZã—	ÚɊ$ˆ>è3$ü#ñ?èÙXȈ«a1fVŒ6F¶ ­;%ž)U¥Š!HH۝Bs‚ÐE•%¿21›aNR¢a[!,­¶`Pk&&±Øm)¥ÈU+½öëŠ%kš+g†Á[(…L§_ú¨8<S3ü¢×ÍmuŒÙ%áÆx_¢qf•Ûxm̌®˜¼Ìë±ìƬE·\#)ûQ¬ ¤ùfI˜©T=4Þ5ƒ"°^T¬37쬏%ƒ0Å¥ëŠFZë¹Y[\7`±F#*B½D(ý®Ì;¢9«Ëيˆè#4ÜÚX¥E´ÊÓÅ`R”ä†8±¾#4{Iól>Ù_=bÂÔ¿ËOQç(YÎ'CŠOfΟ˜Oέ=g+«ÂxJåšBºð²‚f?4È	Ef”¤h6ÍPºGnJ䙝•@¹¾]m 	—z0ý*õ3ÏÆ÷b½;DÞíþú—Á¤hNÚ#)ø7m%N€-:b±ø¤àmkÂZZÇM±Sǒt÷JåR]'YfÂěáQŠ;yiEóo(ª[Ž»ÔœIH¥ÃfuH›Z‘#)QX&xG]¶€ì)…µaP„d:™g(óÄ_(i|ÎÄ»:WýÅfL,)4ò3ÅîWêœÑr¶àm0Pü;ìcl5OÑ®#)×͙×7WÒ\ijjE²Ùú&WÝúk]-eX[IÇn¬^Ýáy•ÆI^mW±±G°dt·ÊÞĵ£¬‹Û‰´#*ÕnmFy¯y´sÖUŽ;ë,ߚ±yIѦ‚ÑŽ…Ê­ÜèÖx•Žmô42%â*+þ©iAÁ gÎYhxsTª5ër<ž¬lÁëd6X…û6\U¯ ÏùHí×ý$‘öÂõ‘@ºÊ&—W.#4BH{”>K$¸‘ø6õ5„Y8fH=!nžÞœš=÷“ßùè䍢®9“30„Èö}®;E6%¤Y᪊9ÓÈíIÇÍLsˆ…ÐW 9ÇÎC÷¢ãž³F#Ú¹zö.¶ë‹VÃKÇäÒñùS᪓å>Yגo2/­óÑâ³£>Ç9t‘é©	änYÅaP*ò8ôQSSèLäÁ0Q8÷zëüèâËt¢C€[ÇÔÃjE¦²ŽýC‹4_Ïa	4¾¥	…ßm“-ÿ´5\ºîü°1Àözªc^øODõHxk„â2c6¼¢Ü÷57kÛ yÁ#*ßN(]I͚kF3mµá½”ë#)’xC¢«EŒ8ɎY,ÍþÖæç³µX­”_Hµ+±+i#0üsÏ̟sì%»ÙßWý|üïWÓÅgÓ ×û½ÌPX÷ÿPϯ]Í~—¾ýŽµ+k$ûš‰IjI(®™´-Ãă)C,þƒžœ½´ÑBÊ¡›bÜ¥.䄏a(ù)äÕî5ALJ¬^í)#*Eö{CéO!I\Eòù¨AíN™C¯-ÛTDnªÚ«ãàÃGŽïÀÝÉžÄë9DZí?X²Rü QX½Ý5[l°ç¼€¹Ó¹É×׍a¬=‰Ò}œº½Ó2$£َªØ%M¹a³î:Äm~w6ô|ÜRÍF°GV3úØ®‘hk5•èÛ:iÓÖF9ýD­#fêŽ^²Ý€I»¦o¿¶£zìM“EȅZûm}Ç5¨Üº!¿]ó]ò£Éx,Öâ²²÷ˆØpÖ¹×ñSqà#/>€³°‹F¾YPƒ²£8vRi¼ÃÁûŸ­K€#ÁËUrø„´‘ˆÒé¤#)«$¹afˆŸIGÓ1z„ìx^ˆö‹Pî‘ý`éu¸k™ˆáºÍ:qd×O;éRÏA$c]t•ïa傝\ÑÙòbÍÊ'¥˜²¤ãÞtÄä:ñ…ά¹ÇÍe#*äÏF	ËÀå[Ǐ¡b	܊}Ñ¥âÂF…@Ï!ԚÞQ'ܵó¶u;Ɉ}`™˜¬%#*wÛü^ƒ¶–PS+žPƸOo±XëP'¢ÌAþ±³Pöx6R÷Ī¯…Ó]¤Êl䙏ô7ª5ñÚNÿËi~ÑЭ!²ªóÏÖê«Ôr?€Órê;§äÕ^×Òõ޳Ш_èbۍ:0æǛ!&œ¨Fÿ^mí¦?Œ™‚$ñáªÇ\TZ}c“d£dmqßøÚÕö+uqè^"–îiì~Äƺå>S¡ÿ́ËjËÙ1|›šÂËdˆÃڝ“™±l‡Ç›+—MÇΪ‡ã·a<TúZ†¬z>ífýOO*W—”"›?ThH‡f]YžT<§@â­M=]K‘ò՘€/IëÛ?q5l²“aåeÐÅê“ĝ:#)ÁþB´‘ëØÿãˆ~#)h#*ñw£!•ï‡fƒ¦4úÛ¾ø ÚÔق¤G	C½–#4_Óx{M§N”ÿ©m¯aßhÝÚ¾©WÝÒU÷îŠz%Ž¨©¥®wê(ÌI’CWRd•-ŽÃqâ5=ÿðÙ{7þçAš¢ð(Mƒþ®èÔ«Ì8˜þ¹y^7Ț:×vyî©gÓd‚«ùÅp)E¾$ËeL±8$ÆÑZq‹¥/ë>°ïÑXoØ¡ùï”ØùáÜ[º¤‘›ÚÓò¶7CEÈÿœq¼cª#4'ô#)ߞ¬*#*Ln¼{rPU‡Ÿ1áÕ]»$Œqî_¨îѧɾT]ˆó£ë¾ZìXË|–OvÐl¹=\¹1]A¸«QF­>ÃYL®§#Ÿõ¸Ç¶»ºÕÙN1ü ÒÖA%ßwOýÒíô½OÉæÒÓæÝydô´)¶_Ò¶[;·càtÓcœ›ÊÎÇÆ5Ÿ¬>ßє™8qr±3L„–¼ÞºBì?×ÇHìT̹6xjR—ñøÂ#4„°âÜVσK›ÑNë-Ò2a´$ŽN£ÏJë|—k2Ïå	"ú‘'U+s‹è$/&ÃëiFÎÆÔXø#4ïÝ'óËÞ+H#«Lõ(Ô8$où߯ÿ-ÑH0$éÏãÿýã'OÖèï>yú´îÿýéÓG¿èÿ›è“¿w5¢Š/€q~ú8FìÁ´Ã[ä¾¦%Üi:­²yx•£Ö¬æö@#)ï+SÉâÒyßÕÉÆàÞr`×ãÕbRd£Ä~ïù_:ëvoÞjüÌ¡ÑúŒ¨†@$ß6«Š\|¢#)qN:C¨Þ‚.‰c­¥!d$Ù#*äÍV“Š"º¡ó—øú-ªâ!þí'ÒC¢ˆÄß»xúH¤·#)#4EçÆÌ	ýíæ-¸OtP]'Ίˆ'¾$4¡sìkøŠävÔëxòƒÂ&¶ô²gŽ#)GóÎ!jLÏPG#*-<j^õ0ãu¢Ñÿ&"¸"ó­yv“–E/ãËpœcêÉtº¸T£O8™8!¤ú“‘LÈÞÙË/¾zùêUí®˜ra	>×"¯‡eRxÊHC£áƒ©‘ç&Æp?å(qV@4J1E'VMHïÃØaÏ?Vî[«ZH©…uìš(®.ž=C8oǹª|¤¤ò•´™<2Ì°,NTªC?»Á»y°«~”d®&ÉìUªãt#4o}âM“_|—Ø	,Ùt~³.ÆëC{>^@#)CÂ.¾ëɌoýŽ˜úéãé²D‰	ÕëuŠªëVê"£—è, X.hMrhžÿëÎÿñdµ¸=ü™,À6ÛíÂÉ_?ÿ÷Ÿürþÿï>ÿÉÎ+MÇK¥—¦jëÅ.*QÕ¹K%tÐ(þɘƒ°0b……˜Ñ›k›Q}h¼÷“ϯù¢‰ÞZ¬ yI†éb'}œ?Ò%zª»cdÓÑÊýȕ!jç ×}Kei/e ×ýɹÕækàrYÝj×*ŠüA	#åÈoõ*vµ)}Øf¬Ä۞Ñö3>¡(ˆüëí҉m<È£%{ADÒDԘ#&TЕ!RíEolQU̥̬•‰˜˜Ô£\‚$J¿Û†]ûwêίúÚ'ÒÐvůDryY'¼ÛÅ¡óF%x a‹#4èŠxµÄí¥õ3ÒwnæØÖ£Ç9^tå¡óAµ7ˆÙX<	¤`m³C,՟ñª5!IÙk–âüf9Ÿgû#ÜÜ[ÁÌUFÖ»ÀË#„fßzô5rÀ«c	ÿÉFøÛapLÎxÔ¤66^C*!‹b¤ ÷ËÇ$§O´œö·£_âÈÝãügÈÏd#)¾ùüôä|«Ùüøà—óÿ—ó_Ïx>6aì…sŠ2¹È†š£¿Šgb°xR„˜üïâILìÕO!T`k9þÉói FWbqE[Ðù~ÿ“G–?¸[±ÕŠF‹BxϹ|‚†q˜O§y8.uGÙ_õƒS`°œVd„êõzÊNú°õüÔÞÿ~¿IÎ5}Ä_Ùâ¨Å‰€¸`ˆôÝM;f£'‘ 2ÉͿ꯽FÔ¼fž±›ÿ:ýì,`’P<ډ1ú‡äý$8tˆdÇþW´9ɶo¤ï3üërâPP½B¹°Éeó£/.Oìë[zJ0µsöò‹ôäå«$‡T-QÒÁx¯ÉãÃýÎéÇOž$÷¨Säè4¦HÎÙ7Àä#* ö‚>}šŒVɾHçób”Á\$uŠcâ¥k]E&R¾f¦¨ß#*«^{	¹*„Žp.‡(¿“Ö#4՘£ë9{ÝÆÖT¥Sہ ’ZŸíl©öUðÙAv-`ãé€J2B£lZ+g›ÔúµnÔÄHfò±úº¯ŒŽQÓdX”ĺͪ#4ø±>3O„i±”ømfn{fî@ŠRäõì=ü#)hø‹¶ÚìØ£îlUéå¤c|ï%#)$/ò$jÉһŊî°Ö 5¬¦dkÏ.(ãà#4–N»q=gMö÷-~’Æ?Æ(‚r‚f"ÈÄtOä&ÛÒ«÷É4U>Ëó¶‰c/è©v#*?¢—ó“²k Õm„X˜U NƉ^ç|½mž'“Óý”ømr¶·/YÕÖßiÁsÓz®­fÛ5ů‹¶¶*D‹íˆíh]_Ž¢.ê#)XPÑ'Îd8²š±Þ˜¯ë}¸~Xl§ÕTL+©“[ ZÃc˜ÉB°µWî°¤Ò¼	ü·¶m?3¢²$}ÍJÇMFcÉ¡K<=ëZs9OH`,!1L ÿܱѹÎ$°;Ü,Ú+ª¢9©6ÞõÛl‰b>prÕu1'#*KA­º£ê`‰qþ‡-Åt‚B"å	:êª`ŽId3Ûàqoø=wŸwª¦\ a3£ »	¼ÅfC\…‘	ÕäI¤~£üˆ~†ÿTxâxXpâøy/q÷®W:;ÆÆ^ûƒLÓgÜC|X§ 8ò¢d’Û&í±õˆ«\”t=•±ú¶™%@°†Q…YQ8|¥16f"cö5Ì=rHÈsx"uØ9ù :mì&—è¤1²ˆg]8Þ8…ØÙÌÌÓôäôåɗÇo^¾ý^ß¼8=yõgìO§»(ûœÿ³—'ÏÞp†ÝÖo^|ûƒñ#LäökԍÓc¾M{yªöÄìXÛ£±Ž‚qôNý²71&£òä¿WÍ­Óߌæ¿b8³äù›ãg2CÞ¾ùæä9?~û'Ëþ<ú×ÌI0s‡º]ÛèÔÙ4ëÖ³ö¾®êÄhQ;sWQ­c>#)ûÚÌ×@þ¦â¶åçÚVxKYÎ'«„;2-)…Ÿ;ÒW”ÄÏ(°q¯ûN`]€w9Å]U“8[4—êIÜÑÙâšw D°JÃþÁ¿z_úýUž_/5qzŒ/‡“	“âB¼4nVõ3â;ŒoÃÒQinqxm´#)ѹ™lÖ뉫"'{D[­DÎÔÚÀy}̇ÀÜloowÞȖq•uáÓ#)j›ÌÓ.úŽÊÊl^±ÿÖ|Ü Ï”‡tŽˆ€é–G’‚KDÜítŽP•À~ê`ŽgY#*¥õÜ-=ÚJD|¥ìl­‘Ö¨c¢Õnp‘Þ.Ï>{þâøó/¾|ù__½úúäôõÿysöö›?~û§?ÿwà~!Gö˜¦ï`5B'Ãerø”|L/Ç	W®Þ¶¹)|sˆÎÿ#)a°“ Å £éßbžMö¾ÈªWùåd8˜¾À|g®|VƒKé‹Ûè¨,rŒ~ÉO>¤õŠÁÍùã“#øo÷°ofÍ­€=M­)P_:œÌ«P{HØFýŽáLŒIú¯K’í£m"ŸwÍn{uš\Yböšo`u@*m=û&ô·w|rz|òÖìVYDZh6¾Q¢Ž<&6µCÊêÆLW3xŠ¦˜†AÂ#)H#*×Րh–F†ª–‹)¥ª#JvÓ,DÍJޗËL§›–“O°k¥z½ÝäðÉÓÂG{“è|=Ÿôk«ØXØfEG–2iÐ#4ÃÚð©UwÂ#*IzSíE2Q«]ñÿUæS°Ë‡t5¤µºê6ˆH#*t£#*3p1¸Ì6Lÿç\óó×at{r—‰Vè®y0\쌂ýd:¯ý>6„ì‡Og‘#TKøð¶1p C(ÔØäj|ŒkÀº,­Þ^ÞHü0.àxtyøкݮAC˜ümx e×Īi™$uT#4Ø£</¥ÁùCtÓßmâÉ»ï&4ÙñŒ"J°¥2*…þaT)·Å–‡³¿Püô{/T~2Åë­jÔԙÁ€âËêj#*Á›Ú’4›bœè´dá<”E{Z8ú´b{Dk#4ëd(^Î#*‡a…¿ð<€é þ8÷nH0ޏî©5y5èƒU¥XFåcü?)ÿkFÕ&‘h±º2Z'@G¨}GÀÓÍIÓ¼#^þ̖ÌWk^ˆ®¯Ïþ|ööøk	{Ô#4qvüÀ·æáÍ]ò´gÁÕÚ±ïms†É%Mçâ¶ûý¤¼{÷ŸÝ_ˆ¢“z½§˜‰ùI¤1ýùŸÿÑ®¦þç:BàDCäAÄiTŽÆ#ƒ£.þÃMI©mij@gF7_ýh5nï\Øç¬/âÍ×{åb^ÂqÉ儣‘pAI9ÍÀ8O¢lþޘg©õžp\™½†0õp¨'´ëf³Eu+=õQ`þØ ÞðÙÇ"ú.æx#4ˆÀiÈeý)=ý#4CvÐûØS¡âíG`»”‡¨$©Ø¸®Õ«F8RT'µºÂIgHǏЄÁ©8¢]¿ÎNÎE˜ñ²{á6l‘–"þ¥Ãɘ NLŸinßqf½&—щýŽSäÆJ<cnéH‰/&}=¼Éñ)­,–¹Öë²Ê&©ÂÞ_—9Ûð4™sø)¦5ÇKEœÿe°÷ý³½ÿÞßû„$D*ÓɐîJ¤Â%§—¨Ð©]Òqyå—ïޕ?¼~ØÖãò*Ãh6åp°0ñXׇpu‚ ÖÍ둅#4WŠP§XµB#4ùawL,)œ*KLx+Kz ¿N 0Ù\ÉF¾Øî#4診#*k"Jq=O¼IzùÍC‘ºÑ¿@au5‘‹V‡ãؓ#)Uµú)YÝ¡g”Œ”øPø“£R§Ed3Ë}§A»GA°9βà›Ho%u³=f#¼JDµ±[-ÂMvnWI0ÏTàÀ²Õ߇Xœ®d`$íj‰œî”A|;#*o¹˜‰Üï"ƒá'û\òƒç\ÛÊqÚ0/û>ýO¹'h}ƒ„ÏÒ|•‘eÆ`5›¯p§FŸÑs³^d—¬oé.­b;Dò*ú!|÷›w¿‰~€¿Ïÿòc7z÷㶣;š¾oQ8—9,Ž^Lñc8ÓMeÖ»,òå"<ð\Z#)#*ç>ô>ÿ&hz»âŠÈÄ]d„ZòÑþz¼âç¶Tßéé¢*Mˆ±y‘l¥e•—Ãòb2ϪPîhùb±Ñ BL[0÷ò@æß^†rñ+ÝKþAÒÊu¬,pŠËs6ó]Ñr.s ¥P UBöï2qiCž8£ðÝàý€ë #¾ö¦À«²ÍÙm	«)»„±§_9lÈÕmˆ.–(¡Ñ_†@·tÿä2#*ÚêCÌÇá[`6ó›²ë»7‘ë0-OÏzPóÒÏðåë½oüz¯{˕ÍCÝ}¶œŸžA÷žåÓA1)ýZËå</'6è¾Þ4¿áÃG*Yàûb莪idaÔñ†^IW–gr#*§“@ˆÑg›W.Tí#)3•]|7Úý#*›È­‘Äd0¸ÑëiS³zdo^íu+Ûj¡žžàç7á:õ£lZ#*œl{5­bQ*dT{ø‡’¸ÿdó+T#4äý¨L8/]XÜÊ[!å#4Î#4g3KF“÷轙¿JÉøÑS–rÏ&sØ`WˆœÊÅO÷Y[ƒ>ì#4ôÙdXä’öà Û{JcS.§Ιcܖ2}0}7	vF#øñ’H8ŠõœWÁ¥·dÅÁ·^jìÈ;Wvʝޣ1ÆRçŒÚF@¤ú¹éj󰬆2èŽÐžÔ;aç)Æé0_Î)f¬j³y`Í­‚ró;W’étÀ·£Jùû""øœ+	œ+É» ì=ˆÞÁ–M’’#*<’„vtCN`xY[è1Vi<ÍÆU\ ¯º8MŒ`³*/N$ÉhxŽ9û	e½CÃJ»ohB£æBn‘-¹@lùæn°ƒŠú¹Åöö×ëÜàNª5Gsk4AWô‚• Ýy!Hِߤ²#*‚rú¤4f騇„fPgÔµq£Ãˊ¶a¡=†Z¥õ!¡ ÿÏ2+n©	ÚöY>®nEöîÝ×´¶àõÝ;Ùþß½{¾,ÐñÃù8{÷îÙbÑ},Ô»w;h]mï8áË7pubq×XJF/òåY˜$·O‡‘‘…°²ÆÃ@`é1JA €¢u± ìéã‹	oß-×Rõ&ðÖôº<°é{Ü€¶Ç>Ÿùå#)Ø+¤…ÃbÔ¹À–8Áh‰)Ò®tŒÚMéô°É{¸%z‹|áØZ¾DsÓýØǞhk4)ˆ¬£–ò]]'–ë	wW ‹“s6+ÑÀÑq°7bQŽ‘ª"×IR›‘3‹é<藯c²ån¤^,Çåäû,ُÌê^#)±œצ{êæÜm‘01C9²51GÄ$¥Y+ApBßmDÛ´"Ì „ooâó×'t=uNh#4,É%Ð<ë›Òacqo6tl‰|ø÷ÃycöۖŒÖ¾–-ö2¨Ù/õ“¦£èÕZâ[YÛÅw-wé¯y³N‘=ÁÍ0Ð͎ښKµfª{‹iǺ¾ÃrÛ9aÂh0M+IžÐmØO'€\©¯#¢s	íÀ†5-¡b&–嶇”[À‘ʵ”ñÍ‚£5Öñ8œ?]¼õkÌJc¶®ÈÙM{‰wäáU~#Ò0ÜÀ’½ƒ˜85xh²ç˜ÃðçjBr3",µž‘}YÜÀžD™û{ÊÑÒãÁ7ók sæۛå¥Zð¡bç‡ý:*„d—ËbapgÄå÷GÎý!ÈPÂÆån±ø8÷²µNŒ¥Œîpw­b gˆ­¸‰†\¨7»–#øbð_Oü-·–e‹ï	ÁX]!ÖÐÀ)}3#)ù®>÷n$þ•oQŽœ.±wfÔ0oKá3}ãL_3‰ÉwîšYìŠwËýû¥d?4æÃÔ=¤ÂyµÁYbÜ^Ëý§ÓÎØ9Ðã&sx 22 x<sò€çæŒ(LºÌ2»÷H#Ãd•Š9Òf-zn±¤¥å¸•Y IÝå¶ÖömGøJºÌ¹ß<ßn™ÚÝ͵kš˜¿Û€ÇLÒk‘“qØÐo;ÜÿxlÜ(ê#*l$áŽP7A©îSÌ#*`÷óièQض%ê´ÜÝ~ûìóôä4}ýæøóÓ7_QSáPè@µ·<:YŠ»é>cô‹•÷öߧDýLà›í¿>~úh¿îÿåðãÃ_ì¿ÿMü¿UÙliq¾¨ƒ¢äpàE«ï«"Ž.î&4.xÎ38Q =b=qD:h€‚Öó~šˆ—CøˆŽ õ»¾c½:}þyÆ<{ˆóN™^,'S`ÒÜÍKM¡Î”*ÊB«çõšRۍ†ÕŠNÁ›tÉä´2¢LÍVÕM¦Ûá#4Z7& @7ËSt“?Ò«lºH¹W$X…ìç	z¸ÁйáN;¡úí€vÿñøÍÙËӓØIzsüǗ˜;Böù….@n&£ê*Á1¡‹/Hš¥Ã|ZZ›Chcÿé«ß\ïMzHwo¤5ÄË0ý%SWVe•òBEN”¹ö®»`ë(ÆägƒCbцI6»˜\.óeé|l´nõzê5R]öñ¦‘¸{8}E«ÇXä@‡Äq±§£/ŠÉ¼J—åàRIÓ46΋=¶”§B(Š*f³ÅÙ)ïlT"lFŠÉpJQ•u*ÐL—[#)#*A6-{P®Ë™ñï™x6Ñ»dK•àv#h•	f]+T`£#)6ŠÒ¹Àé'rC¡(]¢ïž¥X[Ê!ê8(ëw„Œë$u5J˜e ›8E9py¡—›«%ÐÚ7sãcÉùåPk+„ºJ~2}ÄJÞC~l¬‘÷¦qJn]·÷ŠÓêë~bŠÁ·ïà 2#4Ã×¢èA9©$}Fjb$˜¯#ÿ*èÂrg—9@BN1勠¿œ~S€ÚMý–p’		ÈLÀ({õЮr®›m¿{.ÝÚït¾ tùÒ#*³Õ`¶€aëöðÔèÒÆÚÝûîqÔÙ);#)hïxgºD:ØtôsÛÃ8ëÌ¢¦ÎÜ}mñ	`,Q›Ç¯€"FvŸ_#)ÆòE-ÎfïyàJSj”¼Œ¾Ë/J¾žÄ'Ö¸?Ë°As\{ù4/ÇÐÉéóÓW§oȅô[0ÏaMƒe•æNÁ+ðüÕK[Vâ~ Z6‹«ìm]Á(ôçÇZüÀ+~›Ñuô"$Ùw°·GéAŒÊ@ÂãK¨¿„Þã)@&À æJ¸ÁÙs•!P N#êJrÉnðÎó‡Ø¼¨{.pŽºøÞâáU>Ý;		sWÐ$G¬¾#¬°Ÿ)}f”ð-¦0Ö°Ê+Åf0ÃËAÔ¢D#*Œé4›v1#ø¨ð¯	þu–-¾>3ü}Ó\ºoÔ#4tç@-€±#¯n¸w}}#)ÇV÷j€>-¢@«zOUÁi}‘c¬®ÍyÝX!ç›T·Ýiöš³÷þOJƒðóÞéÚý¾©pï{8;L¿™®'Úr”],//Qã˜#4tÃjP^£um]”qßá'«†¶i(ôƃHër^ë­¢ÊÒªXjæä=ûæ5°“ggé—ǯ^[È£•ÿAˆ¤q½‡Ü	y»¼ÊoXß»3 =༥íùåm•Ö7Þ=ȕÚˆ‹BÌ¥d;kßjÎqŽQîÌäì'—UàÀ†åÔ""ՇÔl]ޔG“‚QU†#4Õ7´/HÕRGEuTùâî:Êb¸©„ÑVÃÞ<ß#Â|2ß+–ó uꕵµÔ4ÏÉ-<ìú)¼«Òfþƒ•®ëK·Òfþƒ•j÷Jy’NVxéF"Ò:~Æ ®#(âyù§ r.ü"J;²³¹õ#4cFu‰i¢Q¢"փÏ6²[#*ùƳ5Ýݑ؇8$u-»ÜuçÃÁôaÐÖÿÚTݬô{܇&“š®^¦S^¹üÅÙtwŠ~°ã—kx`Ç1¨šT¬o²4ù­µ°ÊN9}ãrò¶yçùŒÖ=)©»#*¹kº¨»k+ZÐ6+þ˜ÖÒ9è=½wžt{‹£®èBÿìî- i2‚}î,Ú»ÈnÔë5»Œ}Ý|ÞáqÖ5nDð`ë]öºÛ\þ æßÃí;ú÷¬ÊwöféfZӁ{¸ L+ÌËæ6P6$;T#4f,Ev™­ڞg@­÷†ñƒ‡€æ·|ÛÛ*°N1«ôv€Çgo_¼dtc/¼tçΚåüƒ¦›d~hŠÝÙ[‚rжJQ´·nJ¹Æš·éØý#4½mi¦Ó†-}a˜,YKKpö.Ž·(Û§÷hRVd;³‡B† žÁ~þ~#)ü³7_œ²·¸\¢ö:Ïr#—wMI‹ÝÒù3IDÄÐXé®Ë-RëS‚ÖÅûz(PÆOä$N¾ùú³ã7ééçéë7§Ïá¬:}Óâ#)oüVñAT»®«™ÿÃyƒDi¢•eԃ³ç鉔žž¼:|¼"†Ywñ’a+(²‘D랟ž|þ×B@"ï”íѐ·qt{ù¢¦	n¢ŽÎµç¤‰üì³ðn6J¡4P—á9õY…:÷P)üê¦7.–A_¢‹îkûÄBÂ7ýRÐêÍÉs±¡gBR†Á_ÎÑ$5‹Ña¿	Wjû#)“›“‰¿(‹K¯Ÿì>v¿Â«cdƒiþÔ® †ßÀZD(”%:Ù}®M»Y·F_Ȩë41µD©Êb²µ2oÒ ËÂÊ›8«Hr]\oºä^‡:Ò÷¬)2ñ;҃b*½öªI5͒D@û±ã)G#ԛh$NªÉ÷¢•HM!}“áÍÈ#4HuyÜ°Î~Sjw:X·Wh=I²š6ÕE1\ø†r#)$^øéƞ¶–®Ê‡Çn!’]엔֝SÓ#ïÄڊµ×ÞÙ$kß#4åÀ$Ýä(qª&òæcC˜©ÑÅ°·(¸¶ìõ#45d£‹p²îøxôbP¤¢pHLèrxùȊòôàºjœøÓÈ5"ùו#YIp&š»B{žø'´ølN!“S3_Äh’¼	ÖV.ÂaâÝ°l«H£ä›6-–>U”C2ÆVMŸ¼¸Lµ>›²ø"åõ‰®u#)œ½—2-75"Ùsâ“0E#4sB£´8çqª7ß"g&¨ñž‹š3mÜϊ¬FjbŊ©Ô÷lþË>NHUë“OyэP÷¸Q4êû	•qºŽ±Òìn­}N}F×Y"mK´™ò.‚W?ñÓäÀq“šFaSR‘ŠwËäo$»<:Áåщ1öTAy3ö‡lŽJ)§†üùä*§ôšxµ»bœ·>·<ýV›cÔMýt¿^ÑyPPD@¼5x¹›¹`F»Íµmqî¬m³9Ù=ÒxvŒ×¯—Õ]UJ ¾bHîX*­¿;мþµÅ•…-#4T:l,tþ'ë°Àñ,«~®øâÿ|üø铺þǓÃ'¿èü;èóÅ-ºðÏËÍêhi‰ž©ý_Â_G~žÿå×IÿÁï£wÝä]7ìÁÓoÐ:£÷µªg˜É½Æ'³ºb怯íΘM€³KÕ]/£‡ÉT;Œõ’ÆK!蔲îTy­+a?$|A.Áj=ؾŸîõÆÇN$yß7¾Á¦Ë—¿NØ^¡—Õ!—’x—Ðf¯æ‘‰È«”<›Ž6ú¿T™ç㓦x÷Έ'&Þáq“CõÓ]šØ»#*ËQξýn¾ÍäûùöjÕo¸áyY•Rv?ºÃG¶Ž“·eBs'¡CFɜÍ+/Ä´iÙª£*!‰3à÷Þóþ½œÒ×(;ÔÓZïñø¹m%2КÕø8‘hY¦Ítg"¯ÏžB#*ò@yFvþs´k§¡u|÷û01(¬ââ`+oôØßÑ#*¦ò¶âžÏAñ¤í¶{”¡w>;ÇçÙ#*ºŒ±»_deöèz6Ž£ñ›«C'hwu1µAägYq™8ú‚«¿/X3ÎÎvúnÚh+€Êdy‘Ò0‰dÀ€]xxôFY¶À‡#ß8ÂjsÈm5ø:1SºáȤôœiŠ#*}ÝK‹RŒ8ÉáÇÀL¡#*hÍ1Œœ©¾QPÞ—ñmB#°s#4qGóë{]#4÷RRß5à2c"²q)úË¢'ǘôÓoóÉ.ÄóÉW3ÎoÔÙ#4éÄú%ԵǢîwîft—áxë_ãýñ'À}>ì°+S§sïR¨&ªU^«Wå½ì'ÀÏé(Mݲû!X:µœOþú¯é)³°!›Î‡•È¨»\‘þx=kM*̂v÷%»sèð|Ç=Ñ£cø`¶Ù€=D»Ép¹@	¸à­8qÄeàM+¾nm	nÁHjøŠÍµÕ³[@'·ÒVuåääé'ÞÐøôêZo¾—2“-Ú7X— O[êG¯AkKÚyM²Ô¡Oé9~“ñ¬¸œ#)zŽL2 +W!ҜHG”Ë9†m„sìZćèõV¦#*úšMº;å»9êD¢‡*Áóë>;˜bv]=ÿ›ø•²Ý‹k]2EJ¿¥ëõܔab§WÕZ›ßº0fì^™žÞ…—HÙj8Å­­ËD|uä8¼£~’ÁÚ/Åë	_HM+DÓoR#)("Œ¸Ì.B}T#uê"`ƒÒ!#4òbré·Îo®KêÒí­z{Êuî>Ó	”Ѥö¾{ŽÈ%„bœIUs,có’ƒHB¡«éZfý–rÿûìÞÊëŸ+üãòŸ'ûO÷ëñŸ=yôôùÏ¿‰ýOÁ?ÆÈD—o“±íɅÄðçäômú曓d¿óõ˳3@09è<óììËãÉaçøOϏ_¿}yz’<ê<vòüø$?îœ}õòõkxúmçì›çx…žü®óìì«ôÕ³·Ço’½ʐ~}œìv#)8=)#)zyÜy~úõ뗯ŽÓ·Ç_¿Æb)ÔøêUˆo”qX•äq{5éÂK˜«Ël.¯F—¨³u1A"$ô੃7’+“©JáwÎ$!Ù¡¬Kg3L@g¡FÒå¿ïüÚ÷èS׺"4VÙPïeȾoB¬3î*i#~FY@ƒMj´öäôçn¯ë»|µj¡IW€0Ѥ]iÝùjåð«às­b4Î=TH˜BÚ˜èòuøáühï ßÝížÓ?c>¼G×GÏý4Aãä£ڃdÒ;ZÇ4X¾:>;1‰ß~cLÉ5ǺÁƒßàaPÆ?>{sÖ=¾ÙÀšÒ”¤§icÅQ¯œ\òeIô³Îi ©œ®Ãì&(ù-E’ËqЂ#*Ó$¤ªYà+*T¨Nö9ø§aƒ‡c‰îB÷)e¬Q$¥j bÈí؅ÔË¡`…ÃlƤþ­Tؤhö~2%/{òŽçmP¿}FŒðJ#*…•{ýŒÑvè:*Ù79áÄÊ$7¢×#W³,JÄ×+‡ÒdïžN›#*ɦTR'‡É ß$è¡ILÆæ.çh¢°XSvçÈËfI}Vá‘d! U¯M4óMóDƜ#4²Ý(l¸ä”0m|uYïTéP#*<D½ƒºbyF—ØGww!áÃKø –y‰<¾vpܓútäÙËmDÅûQ¯*p^„øGÞèX¦7ƒÛG)Y=µ¾ˆ‰ÎoŽOЩ窂yJñzàóºƒ`™Ï`øғÛN‰ÔÚÙBÖT÷ ­ä&C§thVäæuQLò”¢²â›{¯r5(©ã³+À3ú BC»Å•nÖÔŧTŠQûðç!Ù~ӈëÊ5%B#4ÔC—šê“ë›s™u¢µZ!7ú'n±„<iÙëdlsŬōrRLãœ4ÓH½bá†NM3s4”j3é„5[3õ)epˆìÞ ’u0.ïÆ'kA܍OÖ ¡'…aÎà(IüááӅLuY²øÊɚGõ3ù™å<aѹøƒö)/t’ç¾opQâWë/A@VE+~3ø’UrŸìãM#)e\ŠÖ“9Æãf1”C7¬kôU»ÛV¬’UO*‡I™ãQpÎí5·)߶:ÏØ%+´ÂíR|zWéãv°í@	¶wÊí`gÕq¯©ÄD™²vãÆws¼yìšIÀÛG¼ç í©8¨.1t*Úÿû*rá8#*ƒâ’|*²M<{X×ÚÐ]Rlñ9t:Óñty€”ë;ʆÂR v¿{8‡ÈÇßZÀ–€)}+ÇÕ<æy©ž•"SÒøZy	¿v¬#*9RHèԟ¤¹[;ó»¾aehL"+Z¨. $ ñàwk7î7ZäkÞF;7[k“Õs‘i±$Hõü¶¦ qm¤1ÁdT͋õªOdr&îóqvÀ–÷ۃßv’LJœåa¶O%*ݑX¢Ç¤¢ÄµzӎÜí»Òa~‡:ÊÖjiv«Bõä"N¤ yï#4cNMʕ®ëAÎ;œæ%æ5$SSwËô	^GÝ?ìݽOÑ9¢÷úÞìm£#*Îp÷<øC°¥ûF·xk<™¦Si«ÕÏK.úÙ­2äæ}ßý‘q­ÕÕS#š®‰0ìÃ"ÚÈĒ÷ådÄÖím§¿`è(Y$z\»!§Œï@K2À\Lgåebâ*#…"¡½—bÅH&j7bP¡sõ…0‰F»søGÞ_s ã÷;ôóz~kïÝÊõílº·L"…qö<þð‘~áèr´ü†ƒ¹ºfÐ'³Eۘ·š¶aë§ù%°°È|z!¥ ;K-®ÉZ’<r&µ¹Oî)8uO¯Cå¡ºËLàçÄ&û#+Ÿqµw¶î‡(ØK+‘ö†ËØ°4wØúuîT#44î8ËŠbü#*öá"̂#	@…ÞDtÿ›RÖGÆ8Ž†ð{¿‡?Fm©ÃmƒA¿‡øû£,wxÄþh교Ï$z#*\¿‰'§o¾~ö#4/±%àmý8ZièJaY„Þå?—ìÉN”ö$/un{E÷½f¼ï7Jë·B“›¼Ì*±TWåÕ`cûñÏá}kdyW6PP¶=öûœ­	:Eb…©9[‘ê½ÑfaN¨Ýq'JßkòKw@¶êNð+pÂ)ü𻩻Sþ νññ%!‹O§Ñ¿$þÒ½ ßÇÔí>áÇÐw¯ðÊ:qƒúÆ)[$q!’ƒC#4Ÿ‰þí1…Ný1à~¾³³3=¤¿ýîÎNiþOxÍc"ä®oUGÃÈ8:ÝMº›#)	ï„î)wdîpƒ®oxޔ:s(êÌ ¼BBÀi0™Weƒ€çP—T/K¢ØI"~ÖKaiD#	݉ª¦ÈäŒÓ¯$T‰'å„a_HŠQ1„'S€6œïæ薖wpŸ1TÉ™©zZUT¸¹ÃÛöދ]$î6Ý4¶‹ûâ‡b¨ØoßB1IÄÖIÛrŽn;‚>wÏª‰OÓʞ‹n¬2L†5ôÞ̀çŠúˆP™Ã”†m©„sœ|õ²øRç,‡$qÎb%+üCV€¤t*€Öqo¡_ñt#4ŸÈِ©ÈÐ11´é®õ»©*V#)5їk ·‹ÔlR–è­„m 	æ=€éQ 4DF[‘#*èË&›JF¤äÄü$ƒ:°Š&ÑüãûÁt2Ò>c}mo}¨£Ho¸§ªDö~Pà¾×0ƛÈä᧾ݖà[M/´¡äS:rÊƒtè=†˜Ö#)¬FMOîÒvœËŽIåAšþÿì½{CG²7üþk}#4…7œÑ˜Aì8YΎ³Æ	OÛǐìîV¯PÐm5ˆÝÍwëÚ]=¹gO¼Y£™ž¾_ª«««~¥Š9¤pË1„GÈçª@åN&:·qxiS£ëKK´†Ô˜íRv§˜†¶DPŠº÷ÎPEwQ`|âXKý¶ÇuFaNj3dg¦^É–‘¯I¼ÝlÑko¾TËñ;ýñ µLM=ÚKÎe¢Q×@Úe|F±²¾²üAêúЪæ³]85Èã®I×­HDf‚UlÃübþ³²²<BÕÈ¢/#*ZÀQ¨Å;e†Áù±AeüO¶Ê]Š[#*«sšHµc§EOò¦à]ÓÍҍ׃ñ™¨vlùVSÃu¶„|f´G÷,>ŸªÙ\Ճ.=‚ÝIòP҉_ß/Æcù(!ï˜Sæ@^¨(”±+Õùmþp-QÕü¥ç—•œ&ñ{wÄ·ó¢~ë	F¾l߻ܪè¶X±9ÐèÑÉødþO"øHí£õL˜Z¶h­¹FüçÎß5fC£#\.ýrWZê#):+›?’› tYS	jøbšê¥l  mzh£<oÓÖÒ?Ç^‚Õ‚üœÊÊZ“¼7CV3䝞+´ Ô(Û*¥ð[Ôݗoº¥`–¾0©¾Üa,æ¥!¤{¡4Iµ‘²P3,N>jyŒª¯å¹!.çå+Ž<ì6Ÿ¼,ŒK·I#*@ß5c„±'A+'ûm‚È÷Qק¥Ù¢»8r\t²åt8è#*.ejL5­*£1e¹Ž‹;³)ȱ°'Þg.‡ a¾ý#4a¶—_ƒùW¼„A3WÒÏeNí×Q"ÜäAlùã–íqÑ.R%`·vÜ Zõø¹åù5§¬ä.¼5ÚE·)ˆî4—Ìè“wmØKåÞ}3™¿GɆm…­zšôr6SÊt–]S1¡v…eƒ•fc‚ݦÉæh‘Ïq0vCä³ênbH“Ï¢MA’£8›½KôЏÜqG+ÏZ]²õqO|”jeï]W˜ë¿{”HR#*¬\a—`*!]…¨«èjG¯)ÝF-u¼W%»cÄâR/éèkljZª*­N쯟\ Ž”ˆÓú8ÕO•`î(œ}³C`rOÿäZô'™Ž!§UåÚ«J¯zALÇAæß-aºP!ûݔaåà×7ØJå€Û(‰ä£Â1—ϐ”›ÛwWøg·yQ¼`ãÓi¸ÈkïVªˆŠå1“i¾~¾CZà%÷åçîá#).F7#)ÇÐÔó3Nc—Ù >p4xÙya¸ƒöV 3’	öäʌºCªXj#<€…òw;ý´åñòÔ^݄·!€5!m`aý2øÓuz¶(€uªêÿàÚö:‰ÐäpØ1Ö˜©f„}ví9“jú[¦nõh‘¬ œtsôÔ¬±VýÆ4!amÀ.#*¹ðíP0Zª#)æ©›š;8VCҍ4£“85_ûØ(Na?€¤pEBFˆ¬Lj`JLÐÝ}UڑqsKíؚ'Çz\Æ(áj”ÀT˜&83¢EnSZ+cšj6-`$˜وUžÕýêpƒeRõ}±q,©ÝÈ*êú²@Uƒ©O”g©–ô½ËÁ°Orœ<•HÕËË_bÁå£c$×ó«-tÚ#)¿$#ní£¤¤§4ëÞøÁh¢ÄqÜn˜p·‰Ña~٘¤³ÿl.Æâ0¢OE¢·wWÁðw¥ÆÞ9S«GۙsÝo°e¬¯Š#K]pӅ}<z©ÂØ[’#cÌÐÈ^¶ÊÝ&aõx^®ŸÁ©wæÁ)ñœ’žÒGQre˜;žÁbvTÓf·Z«¶æ3ØԋÓyêÐM¢3™ºr»CHaîì!¤¸Wå]Ê‘ìá‡,Cë*s7ÕÑiÁˆi›ëÍ™­<aV'I½Cc¯ëћs0íjJFquG‹UI8s>ånBÒÜÍ”Ӄ­óFû5ø€÷Êdîš9íÙ’02„Å#*ºguAÂ#>—ÇÛª+NB ½íUqÎtMh“=j–i–ïV„ñiNDäõ«à1†ÑÿvCєêNE:Þ܎’h9ÂqFù\´!ó—`= ¸û‹¹à¯úüHÉ&Ï4iH#4ÿÈl÷7:ø¶˜n€ÄbFºKތ‹9µ¨™ïèÕ¬"Ï_·Ý-­«m2fåÞ/äÍÁFãW’îܕt[¯•Ã´ò´ÕPY9n¶Õ´JÉmâ8—ÖŒ­Øƒ£¤D¶uýâÖïT|œwOi.ã0Vx@XÑN,¬”7Œ¯w2PSi¨#)ôhž/Ê#*soDí—RÇ*\òÄa6©ä«Sk}ð€z ¤²ö=òvÉX܈/°ˆÂóQ#)~NñS€^65@C¸1­ñ„!Üæ/êvø#41˜×øWɚ*’ÉYy:›L³Ùü¶åØ!HPN/Cî f:õð:Q¼º”gÉ~«¦Îeºl—”)HÉçw|yja¼­¼‰ãGyÔ]H_D@’°Ìws‰Ÿ™¾n§¶Œ}<8=å»=LôƒO4ØØN\ÂGórÊ4%¾Kô'V:`óúô'41w’ù¶‹ùƒÄ„·Fö|Ú-W¢K°¸¬ôåìTë†=Ӎÿ¸ƒ2@|>ƒçâñAöµey%têiìÆØ/\]¼š™CÆñÝÙâZ6þÏ°Z=ZP=â4PE£ÕKú=ïuºß;ŽÎ£S„:ƒþèXg­/ÞýŒÏOn6âáËžÿŏÀ£>ÿô±2C[û6)gÑßZ‡ï÷þuôÕQ|òçöã/>¦˜.0CADÌ:s —ÏON8÷þd8Ă?>ù˜òÅY>Ç÷ÚJá3î‡Ï€íäÇX!ؔ1«µY.µP‘ŒE—ó™ÂM³E0Ð4].Rzv0¨AǪNd·¥µ×Tw"¸qØÂD£VH¬….Ä|»Æx #1‚вÖóµFA·“J¶!_T6&ÔDœ‹:Å;c.ŠÆ–3ku¸'}g׷иËØ÷Q¯5ÒdÑBÛ°½trq#*vñ&³B4¨ap¾L]\ê‘^iuMRÔ!¬üeŽ¿³›–M§)¾H½‰J¡^	âÐ_¢“1ìk©<ÎÔ4‚Éé,!1’PŠ)T#)RÞwñ"žrW)ÅZk®U¨#4 ½iÜtû ÏꔽQ·p#*`i¬ªlÕ¿HÜ}°¯ƒ+QžÇp»*EsC Ø9ÈclõqB©mob„èž=5šžòpýq¯<´I&¥C‚é>ŠMnvLaŸ8$©{¤tcQHê”Ê]?¼¹èèx÷É©BßÏñ΍#)á/œÅ¼”Š@iù¨bT±dÖ¸ZŸ%Íõ<F·™4©cW]»/4ïl9E’LDÝч^¢Ãû§èwMSÐ5'¤¬­IY˜KÑ­JZ¡Ú¬§âVY8a0Ž/Bß\¥‰…±Ö¦Åkë: ÌÞ& •¾¶¾ÎU\[oE	*2œÌE_¿ÇÆ·8ÅGݚ^Z˜°N›ABé¡)ñº[ÓS\g6¿Á$ÌÉen°b(­Ì&6•µÝíbS8Ÿ=?É7²©QTû}Þ:þÛÇMhöødvr~r}ú/Ú7ⵚmOêá6>…QòûÁ(‹ŒdÔ£ý/Ý4ÌQ0XïH{+¨5œT(贀[€c&Ih¡q#4Ÿ½IäÇuøXµƒƒÂ#*ۀ»G¹Ýd­ã‚™ƒò^Øð؇Eߑ.ªX>ªJEHä(æ=i»§P…Ý®¶xKdzùn_ðð¥ÉKõ^W±ÙuÆøn·«Øî¼ßUnxßñVo\«÷¼{¦­Þõ*¥}ïþ_¸óy¾'ØñÂ#*ÏgõŽW·åéƶ(‘üew¿ãÓ¸´ýÙv—6@?_«v@.1I´Tjš‹P`ë#4Uƒ˜nB§è@pfø=š¦ÃάçÚ}@Ώ7wNúÝæ. Û"~o0>>¦^öD¢KÛEdô¡)O£T#*NÙûmRÏúîÓk¸®~³…lîµÝÂ_·á6<ÞÔ#*LIæÕ9Ž!ºâx€‡w"ý­èQü|«)‡'	{^öÿ¬7CEqoé0RÕ:NÁªeßøÎ`ìŒ/-º×cǔÜÎ#)€e™ÈWÖFÚgÿ|‰º!Ÿ€ˆŸgÅËX#*Π Ižõ©$§	èk­	=¾ÀRµþ#4v¤:[Ñ,É9Cò¥%®)4bÔÆÝ0jÅaÞ÷zE¼€û	¦Š»IWÿÊy™üd6Ïúî;ñ=H×êiš…y4ϼd˜›…`SUžÍµ(I뤪B>Ú^$ *TH8‡E4™Ý²ÑdÚco=4q؁EjIPKâqZӒ(J‹]E‰SÀ¦¢ÏâzÁ¢]üR°Cæh—ý0³Ò.#WRfÑ.ýÀ^=ïâßäÇâúÄÐ@9c!˜¬¹báï¡Ç·èQxzÿ¯ßÝ·Þ0O		‡4X¹»è9‰Žc$BÓ1`:X?î3²ùærƒÞu´äZÃE‡Žµñ±ŸË	Xgõ¿&ÑãËEw·h›G,ŒÌ!nÂ`;_Ûë½ ¶Ôî*LtùSóÝ~.iÔ4HR2-…•Äü¾ìæÉ@ÍýÀa6êN/Q°»êŽ`¼ùÛxIá_ÃùDè¡ù‚s,À ÝÁÜÊåFÍú%”gÚ YÅÏS-HŽJ½¿/#4…+ÈfNÑØç+‡ºå<@ÌBփ‹öºcäš0[ý!{Xhë\;•ëY6Ì ëÂâƒøŠ•€IþoÀÿ”;Þ_ôÿ/۟}¶Uôÿ²½½ýÿó÷€ÿéP$TȌSHuøÕD†T^qõNY\ŠvÕ«ÙA¶ª›Šl|K|©Î^‡Õ`2[ÚkIHaT40´ʖq™£Ì–‰6ÍjõrîÐaô²‡&‚ÇÛ °„Þ¼3?k¡ÞE¶ìuF!>Þ9#*ë¼Q‘Š>@Ü]>t°*"뎱±0:%|øÓ¼ïð­ÒtÀ¤MÌ#KÞ¥ylmO”‡–,½Yñ&¥ÁeÆó>hNᐳŽe`8¯´&§ƒø¿f[ãH	VuÆ+͗sÔö)”!Ãw‹öªæ5¯"üƒz¥§¢랕û‰”ýV,„+b8}RœýOŽÜþGèÿÎö ùEúŸ?Ðÿßý¿ÌºÓ¿ÈgV#àç¿/²E¦¸Ïÿ…/É;•£·†h‹PU£¤ÿUJÚPµ³ò÷0ÓG•¹òi$ŒÚ¢¿±àNCê#;Sw‰#)0–ÊKP*¿þ5S,à)àÜžqž©,º©§Aàç„É¥U}Â8В1©'S“8®GئÓs…„¶ÝøêÅ»ôÓFØ#*)_u0Œ¯ˆ] r\±cx¶>ŸÇ÷vôå#³sÓúr…‡¶•U=‹¸ÊƂ’Ó¡;ۇ§Õ·u¯ß‘ïQAÃ|œ\TÜcq£Í³"$‹(fenù¼ä]»ˆ„=Á<œßòÎTæG$þú}+_Œ`Däì{‰ª¡xÎ9¢§ê=>Ÿvo`ÓñÝY¸†“ÃT)þqg—ʯÎæ/»pÚ·¶-o4sÇÌ@ÍY [%É°-Ø=ù|2µÌYøU]zbÍZ®¢¤üg€ó‚”y6jë‰1nÔä;YÌÛJ\–¦'9è#4#4ä:ä #*ýð¡P-þñã *¼>/KVžݟþ¬Á““ödZ×gáÞì#4µx`®þ¡› èì#)êëBÄ®™m•>XƒÍÒäÁŒÚkŽuzJ'=J…»3˜PÙp¥ oHwav1)â1ŠÓ°Ÿ²î¾j<#­ÀñIC:ï=ÚNòù¦V¿.Â`ŒâÝa6ÏB!uXn¢[±)9-†ä+âJ«ž© ­ù ìQw¬Œ“™ÁY>ýBˆàñÍæ·a¢YvMB±:Ýàpaéj’i¯#4­¨ðêW¾õ5_ìÚÝZI|1&9‰½™)v|…`ɍ‰;lip\CÆwg8JÉÛwôs;CÎoá°IFJcÉÉj›¥»ei(¥Í"€	R{YÉµ®hIz’bÖ×í£tM,ÕÜLiÜe¾èA/ýµ"]nŽÕ<Ò@UØRêFœL¤ãAߢàAÑi‡6k$kÖö°­ç'sÆo]gôZÑóŽõŠWg™xiXÉɸé,£-&šø4Q';ã§Á<o>.à<þ‚@I°\-±Úp8z)n#¡AYÁ¦ÊØOá]md"nËcX3JËÅðO>®)Â/f½v‚›Ðfâ:™±£hê© `2RøìuٗEc›:ö`ên÷‹dUåÇË8ˆ`ûÁ2ƒÅ¼mÖ5#úålr•á!‘E7®ÍÉØÃ}}J÷ò,§AzØò48ÖëHØ/ðWp¨x‡½Ñ±î}ãѪ¦\lÓ;¢Ó-EØHŒÂ¨û¿ªi²tªZÔiC^ºFP ?J"ÏúìÀPÚüȃ‰‹Âî#H½C&º?òtÒ ÕMÎâ‚âzWºõvÁ*ZV«Ÿ›k#*s,öaR>_\͜#*O=ÓvÚñ±±¿R4ÓJ7M]™\¹Ùéì®Èðã?Fr	gf·ÌÅãNƒ´´v©Ú6MâÊØàÜgú•‡ìîYx9ègàÙq”Ê!oEÝÙUÎ#4ƒü2ë‡3î™g·Åø|–eÿÈDÐYV’¢ÕƒZE†<¡(‚5× •äÅ¡ÖøGe·ly§ã±O«<Ò.kæݒæLp©ځ;[¢°C>¹Iföç2y#*ºÝÍZÎAYKþÂQ#4Ém#CÌ{"'¹ž‰"…”‘”Ù…K ;2js•™é]jS­Þ1¬xéI~È]Te2u$;H#)‰‘µîU'ëV5¿r0‡î›õ¨Ã²‰¢Î#*rU8ãíڈ7ÓíoWïËÓlÇ{‡Ì1Ôðøì¹âNuüŸ4±ÊŸþt\Tžèî—}Tí}{€‡».Øð]àx"SþDOuñ7/ž-+–!ÐV ¹ÐÚhÿn¸}OÐÍ\Ÿú~.	D\Wc¥Èߓ	üNK]ÌùŒýɬsÙEyÜÌ“_#*¦åìŐ³bX¬U³Ž„ˆ„êº:+…½+¯°²ÅyæV#4r"ˆcDCx¨•yî›]>Ú1Š%ó5m¬åô€˜­öeP˜gÔw#ÿ׿GíÚ(Ä!›µ ¢Ã®/\<ßnZìÕÌÂpÔõÕ£ªŽ-žøÂBt.M‰ÀËAq¾k§qm†ây·ì¤¶Ž™-ÐCJ\ÄReï»ÆË1ì¨B”ðPdÎI!ÀéWÇL«»LvÜDrr؀NlæòË穓~ê”Ö~Ädó”ûž»v«ö6G¡‡6CµÛ-k’تVUÌøûb!‡Þ·ÛX5WWLÕ•‚'QHˆrò+؏vIšSØdÙ¾º†0z>Ûªî ^õÑs¢Þߔáà¬4w†å¡u6°n×ÀXÎE’H> sè­Q}P«È«žÅ¾ß±éŽSSí¡©pfrœ¬´¦pP2‹R#Øsö"uIkW\«ë®BËŨʼn¯b×câŽqžn	R¶Ùv($l#*DµóuMµ¾*(¯aé¸mn°¯§ëx£²Jø¥Øõ™j¹ã%E¾-Û»•r1‡<Ô»í#*”x1îYjo˯ž_x¾Ó?ÒÞ³dÒ1rÜàeBjèéG„mg‹‹ÕKàéhÖRAY=mô¬ªÍßsþWœ0ÛŠ¨ŒÜ׃I#M±ñÄþ 8Ä«WÛO\£Ÿp~*šßÀg+\I·×{À‚(Ì~i±LDÊ+dòi_„‚ǧn]Èëv˜Ÿ´‚Ñ@#*֙f#*I6\ö’…Ÿ±ZĶSJÒS«gCrÉԈèٟ©)zÞ¬Ô,ƒ#FÕ*¬(qÍ͗µ¦ÁÉ +”’Œ¸bÈd¾€Ýÿóá?]ÿw¨	L×_Gìý¯OwÊú_;Ÿ>û ÿõ{Ðÿš }Nè5ä6¯WG²šHò£µßLúYãëý¿|¿ÿþNKéÖ=7žmm5þüâ•®í´·ÚÛÛkö~ÿûìþá³ógçg[xº½õ‡í³§xöììÙΧç۟f½';çÝÏ>Òýü,ë­5^|yîl5^~ùêàõ~µ¡ìé w5Ì6×óÍõ>üýDÜæíé°;ÇCq¢%AÜxñîݛßBzyˆZ¿H¢ÆÑÛwi¼rÔxûÝQŠî‘£ÆŸ÷Þ¼;êpá7yo6˜B°¸Áèfh_”T!¹>Bz}Ä®—G¹ÞîèË­7RàÉ0sÁÀï^À᤿f|}~xôkµûïߧ›Û/ß}#*[¦º`‡M…„(肬?‘ª ÷F‚ú²Ž›½ûUNª¦]mô9j#4+ÄX¶4yãQo¾L…f…¡mr!.©½AË|¸†×ŠÝË1|…_xI¿Â+üNáÉ&ê%‘4$°±·PŠ84ƒ\]³ñ~+`ÐâF“]]fM©?÷=Þ#*“SvTdNnŸósçCÝՊúÚÕNÎfxVkmQï4p¤ÂNçVWy?×…DÍI¹Uˆl7æĽUxW÷¼NðÕ''¹²*j]}C4‰âôc›‘ªÃ&j˜'P]CnèT¼”#4†š—L§kÕ'Š*¢Rßïâ¸Ç¤…H­HzÝI„³“€@§-ÖS—ÙÇb³Z³~hСˆ^;†Ü¬¢¢KúO˜]ñž=Ÿë3ZVÊã=þè-šÈ)¥Ç*&‘1z?,éeIT“ì>¾&Üi€dx§ÒáÄ-þÑÛëá>¨ïøᤫi0ƒHæxçyZí¹˜œŒ=~WË痺’C;øÐ~îe„F	Êcëûj ×ÆDm±ÊmÍL“„ùo,§‡•¨«•óH´pvBÇÖh¯­“	ù¹žÉÎUÎûÀ^̳‚¼q–¡kЬu¬îСå˜{Kw	šz\©S'þÏ:šŽ-Ñ@·<%ÛF;×ÌñªiYÓ^U!˜«Åã¯/ÖdV¬†Þ„9!§‹j„ãn­ù¯AùAÑÐK¼¡°#*0b¼†á‹¬d‡I~r»±#²!˜®ƒ­\>u‰üù·s/œ×X×ØjÀêP³çû¾œ:û©†{à<ˆŠŽšð“°.aô~b9¯óê»7©<oDhƒöTç÷LÍç½Û2OëȘÉÆK®û#41[Ôè즂Ëč:%V<%ÄfGî–@Ñ(݄rÎ8Œ"6ã#*#4;k¦	‰2ŠV4û.r#ëÀôúOЈ‚„Iè«!‰0j$¡¥øA{5g}=k锛Æ~å®”Ö-¦)e“TŽBmïBºªÎ•Þ#Ö²ëÜU½kÁمëíXÉÏ­BŸ¹eTèõG`K:ÚݎZ†'å	ç	¦_AVEµ.·À½þJp;RÏ®½™45SV؃Éh•:O•¶j…ÙW6´åýœ¦Ìª9S5ijÛ¶Î¬z¤*ȆôCG¡Søºþ;l\HĶžÃf›ÍHMó«ïIXr„BYh%V›:³{oßêdž¨5zšÆ #4Yÿ|4Gb–1r=ï°p¨ìì}û²ó#4½J9´'Œš¢§ltyÈC‹ó8#ððÙ#):há7¥Xq×F&{ŒÜ_ÿOì6¯nRÄu¡C’îïåf;Ž(_œÉ]‘VƐÛácA‘8M+ZbCW„tª5eñnÏÍ;»—ÖΡóúxbâë‡ÓÔ׬ýîàݾKg‡êdø¡:Y0ØNyÆ´Vƒä´Œ#4®èI¬ïñÖi¼ê öŽ9ÂÔ£ä`]Râá©;»àÃ#*6#)½ocû|íËë)‚¬?õG’ñKzJç÷f¦_DwÉrz…'cSŽöS1†'Ù¨ÈT̪Lˆa…1ŸU”°Ô|oø’dW+Ø'b{7ý°ÐÂúÂçÔ¬2–º§À?’ÛA€…Fv0êg¸9wº°„Š¢“8T¶@/h¼,ëϖªâÂk ¡>¨Ò½hvóf¶jíSŽ1Ñ<y1ËXLNææ1ZÁëÑ]#)O*zkçû#*.P‡›×Ò&%r½½Š77X¹Bu°lb@{™Cˋ8uš£Ã™ª“uGp¨„ÙÍ«ŸÛÑný(́êÔ4¾˜æ`·Ã¿_¦9lÍaÙÔËðPÛ¬FMsð“mNѳ JªðÚJýméð߃lî&8½y9œfæ+ÃÏE	‹ÿâߎXÎjˆe°ÜMשuxcõFoÕE}†º]v›øþ¥ð*ªû¢{Å{Áãm*-‡R^Í6eù¥åá(úºPt¦È…œöß¿¿;§"15 uYZfþEf#*T€©fÖgc(G,ä6¤c· ÜeBy±sÜ»ô»^ñ“#´ÎWY4d9XÇµ÷\Š¼P$í¢6žâÔ 5÷á#º#4[—«ðJ	âªÄ¡xÏ:V¾Ú#*CtìÞƛ‰WoF xŹSqäy÷þàÍQçՋƒ×ß½ßï¼~û•¢ŠìMjâî힌×ó“14D*™Èò„“ݹ†Á­)LÖR]/<­ñi5±[5iCGÕk®åí#44ŠLÕÚejê0YÕ\öq÷1÷6ñœéµ¢о™#*P¢:§Jˆ_ ÿõ|ˆj’K•1µ3v’Mø­½Ö 8ì¶ÃÛL£î.u€Ü–²™Eåûz¬¿.‘˜ÇÄh†*gfÈÁj²Å8„ŽpqBÎɆ#)"Bò¿î¿~ýöÏî®$ÖkÍQ>Q«ï´b;•ÝEÛ׌¹›Âíw#GÀ®D”Cé2 ʆå‰T‹ÒeY¿¢L*o¹ls	M×ã¬óÃ"Ÿ#XH+JPÁM'Іù<Ý#4Òêýk!ÿÇÑfäVB@¾IýŠ¸¾ét6C·½AyÇë(YƒSíîÚ:¤j1B–(¾œ¦‘^Çè˜>xÄL§mÆf|\d7§9C™×f¡*§îG4'WDnË­¥hråPÑY"…ÑügǦFbÊ'Yûéì(‚"„q΂;Yè‡üË#4;–ÕU·.ÅýÍUü|›¶a\ @'i´(¥Š•<y	.x0\ë^k^y\;½SëäÓ¬7èé¢J4î‚ù¬;VÌ.Þ9äŀ¢„À#;Tî‚Z#™ ¹Iý„ŽYy·»è·o89sáeLgý%×íÍ3uÿÈ߯ñWüޞ޺Ë<×7´ýc0eQ¢ Ýþ÷`ŠÛ)Ù^QíòÔº6h;%•æµîk+=Ë<lø'È R¸«ïc¨mûqcÏǕÎ~ÝÝîÿt]'#4—ý	Ž”ÃΧʜ…ý4KÏÊE9a°«ä,9w& œ«“ï«…úÄgzžž—û»8.çqƒ®D.O'37ñDðO7£¥[3Y;ªùa39Ƨª%Ä<Ü.À·ñì%ån«¤#)â8-CÕ¥Á½„Xáô´Nþ=YûÍPŽSÙ`¹ú]Tì)ÞÊJRK¢¨z>oMp'EWQÔ½€’ûÝÝ?u:è}Ìß%¸Äl2È¿b#)R~sÚ9òꆗ/¾áO"×ëž<gºpN·é.ŽÑÓ4ú¡{ݍôfŸ_o"HL¡øÇύ#*ôÞ¸ŒÓ;<(ƒ<ž:Ý	m®i9éSHOJ= ÚÖÞÁ0Cò5QõŸ‹|Ù0%øë”N‡)O§C9¶…«Ìbá؃DÈõCHÎqè}9¸rWöåQî«;uˆ0¦9ÜÒ(¥ÍƒÓœßì)£²ãUÌ`K]]9ŽFÕnŽ°è6#4#5„©hDÏèë¦ìÝôørÝõyJ¡-Ž#*l“ÉZüf£Xߝ¥‘´½YOnøCFÔÔ¢¶ZƒÔ-«úÛÿ“úß{ú+ÁÞ¡ÿýé“gϞô¿Ÿ|¶õéýï߉þ7”´'¨	ž_.€¥JРS°@%bï)\Wƒ~JÖÉF⩱+ÊIy“ñnɄç«lÌÒ¨„åE‡ÙœÑ/ñü“¼%Ñ0}#_QFÝ{±÷õ~çåÁû4ê='’Ãï^½:øK±ª2·ƒ7‡G/^¿Na†ÖønÒûá‹ï÷_v^½?Æq"úè#ãn|‚šóì{CHýMçA<b-pœØ{õq¨Qïü‚z9ïÞAþ·oööÓ-~}ýâ¿ÿ#4èwïß½Ý{‹UQÞª¾LTo8@ÊEÚ²Ϊ¨«[‚üâE‘hæÄ°ðSDàFý4â×úÎÀŽ<íPçe¥k[&éB¥kf)´?±Y᳨6¼WÙ¤÷(ñûÙT·?E8È»O ÞòUTA”Ž]	ðWr^s_£ø ‹è†|s–ºAsê‹ÄSÛ"]HT4¼u_¼@Ç'/kñIÛ7Á]¥»¨Ž2¾–;2¯¥Œӄ¹YkÂtþ“PšÓÙ]Ìí"óz"%zû™0/d‰¶'ò‹>ýú§GÂ5ã` Ý¸˜!ŒÅYwVŠh?:¨hGgÔ×»Œvš¨¨6Ê>ý¤Ó^M›lû‘Û½F.ݐËG+Š	‹eÞëܲ»¢»ÈŠ$¥ñJøB‰°[ô\/SÆ܁ÔÎ*ý2C·6c”¹˜J„®»Í½¦f²¾»Ù0ÒDš¡âú©jØ#g+ôÞM+c;r¯ùFЬÞ6ò°é*¤7–/ú¡¢“ém#)d\}æg <±•ÈŽàm6¦ƒ¬o•Úi9úk•:ÃEo„Óí«³Ûú#*£€v°‰²êRO.UãèZs#*vW¸Ö<Ìò9[8£Ü‹UUX=~üÉc”aÙÝ2a]Պ—º©DlEÕ¨IF¯o#)‡¦Ñt~»‹ú×Z#ڄ¤Q`Fª%jöÒ¸ü#-H'ªY/‘''ptüDüŽ¯SÇ?´ÝSkiô3=LŽRñm*<NJ¡»9·›ËÍý8»©_ ;“Å½2ÅöÔ'±(E^áø¤'W¨»†Ìõ™#4ž’º¾ý(ZWëڙQ“¼HGZ¡6¹Ýžc[W|Ö½6þçiA§?ŸõªºZéb‰_#)*Sˆ?ê^eféÚULÔ]a¾w˜]ýT	`Kg‘½‰T¢[óȲCd¥PŽºÒ¼FÓôínsŒè0üûÿ`ñ®%µ­r"–/ò>IPÍÛUDî`ä\fás+.^‡©T²¢íAíޜòˆ¹Yà>x«“¾ç Eû‹žÇëFdËYs[k‡ÙâEV«—ôsÒþòõwûA#)_†ÅհѝŠa6ì¼É¬39G¬êo㽦¯«×Y÷ú¾Cô®ë	āV‰•«Ó¯÷Ñð\k0Ùtú–ÌÁêHf™}p{WÂÛc›×1¯ì=h•d½J™#4n‹×•ÿöÄ+=Þ*ã)I¸š]èüóóÙ¹¦dߜœ£7£¤9%¬¾€vx;òV`X-o	æ#)ЁÓxü˜ÆþÙù¸‚e·¬‘6‡-•í`÷»ónp]¹%Ñì,ò=Ø*ö`²ÿö•ñWdÕËi v›þŠ‰?ñÉ漞7[#ÞOâ(Á"ƒ‹5'l%³J>¾Naˆ¡þH­.Ÿ­#V8ÔH9û5Ì[[è#4}¯;Z&b…rÛXùž:²ëøŒ"ƒ^ä×	֑8È%²äeà½RïXwr®[®ÓŒÖuL|R¬FAü“‹ n<ï~ò¬[=®+‡u鲿My G÷‚•=ijžôopÚoDíùhA¿Òè†ç¿#‰d݁Ò'ˆHuœäîÂãÌ¢¡q¦ƒ¼s3?Ù…jTtÜŒM!ùrë,}yºôÍz‰i"V1±%\T>ÝçùL©&Ƌjaç±Û>#*¯#T=·OΓ€wœ¸að{ÄÀyGÀC•@ZШU¿·8Ÿ#*æêõlҝõÅ˜-¦óPá&ïÔg+t“¦L»ñ°Dý>	#*ÇÀõʪ#*荛²ŠøÞ=%—Ur|$¡8²&‰˜;Käðvýù*‚…C㶗ð@/èJ›Å@óC}'¾Úvò¦Ê‹Ö8D@›¸5Êx-6Êmß#B€¬¼ÍÛ^qKBê•Í*FÑ©ëLW^rÝz~¹ºâ4ˆçä#4HV±ÁþîŽÝaÇCq1t%ù,2+q·Z<‡¾ÇïÂ.Œ!ö#)/S§Žhïî£L¹;|îm:XÈU0i…G$Êh·Î$Öµ<·^|lʬ:vµÀ6Ïo‘˜ŸW·‘:ÏLå@VƆ·#4­Íý\‚˜-D«qL¢¥ºóWílœv†÷PÛÃXµgA/¶«sÇ#4ÁrºÄ	Ǝ®Ù¿!L;õ²mçñ€ˆÒê8dQÓr-ÀßãÍýU¿9x¹õ—¤d6è£ïú8ÞÀW^µe93Ù,‹¸—U¹KÀŒE™©³½á"CÝNÍ­w°äuÓ#|2ŒÜ=Eb×Eb§Õ'ÍS²$ƜðZØÚK6a—ڝrÂ1@]jâ؜Íûe¶D1^œH¢¢Ô)ÄŁg·$,DIÙmQ%8ôÃJŽv_8Àsózõ…9}º(«"ˆéôE›%Fó‹@û Ò¯‰öea拉;fSGwïRF¢ÅÞe¿UÚaː¶R#)“hs–fçvýeBˆµ¨Õ»v‰sÍ^œg¢Jå˜@ôqfS>±gõf“yòˆì±šÔbpïrvDZŠý0í¥­í­­öc‰?¡üÃÌÓµãõõõ~ÿøs#4ùúúNþ—Ã;ü[[o(ƒžÙù<=Ï×[…ÆM{Ü>œa,™F˜ÿ;E{Œâ…!.jaIhÓ4Ìf£µâMl7–ÅO”e¼±ó_03ó¼#$þñ3Õ)ÍÓÏH#)#*§ ´…Ñrn77<ÞÜ&}§YڊÒè1EۈžG±h÷büX4¨EÑôp¬S­Hšp¥ü’"§»ŒÒ>¢]vå(ˆí#*2#4êÃØ^Z¯Ð"	ÎÁ-!{ˆ‰0&òW‘ÃMYÖÅÈ,îÌ	£®È#4™)MŒ#42Ù¡Œ1WH·/Šu­H’¥Ç˜àÔ)ÕZY¦Vý¡…jº Tœ’|#*"çÄâm‘!mîê„Ȕ\yv¯à¤Çåû±ÓFÁم¹«Î…¿ӎSQÄÒô¡»×a›Üî8¦œUùZ–1ÇXÅK%T2¯ŠCX¡l±A$o³àO¾Géoì0œ1ËB§›Í(°Y1Å^.KܜH£/×Ê~D¦M xÂnŒÓ>\„è¿Ë†¥ËaE®h‡#4‡ŽÌ/ô&N+£)K¿ÐË]W¤ßRWÞaœ¤ÑÔã*C.1:ûr8Áì´Qð«¦ÃkÆÖ`ñÀ¹Þ):d62]ñêiV½Cºbve̛Ý!!Õ"­ÊaG‰"¬]TßíʍÐEx¬SáB–VÛÈǃ+dçDUz‰¹ž—L ½/4qßrV:vÖHí”w»ïÈÉ@]ð´ø±…«	+>Q€C®¿µ¿Tó-5²$/Äߒ©Eq«X-ÃiÑh„ˆÖCÏEÛø¢ZÅmI¢m㘄™ÇF²Æ­,‘mž£ÁÚ6uu¦Ÿ$MŸ(]Õù…—ÄLªÎ1½ÉW#¯=šFÏ¥X±·“:Œ¸?´zó‹S‡"4JÓ ‰Dò¤Ê@4KÄDâÖU÷Ù¸à]IS%‹Œ¨Är845Éw­ÛÇý÷>“.ðKK(Q>š¶·ÆêÁU^¸{ˆ“Tɘ¥¨0ÁîØϤ]ýÖé¡dúT´ÉÿÈþ‚y`ÑaÙ¶…a>lÙíá4sɨãZÁù\ÏÉö#)®sm8Fá\󖽍#*žÂMfNDò7¼Í"õ=/ww—[	ž6zcsS{_-S´r `UÕBâ•k±÷ç—HÂ|Ÿ¼ôP^Yt³…WÌ}ØpÑ©àø‹8J (oªk*(TÕWċ22U\¤QSšºb"ðSÜ[NƒŽp%x܁#*¸ª(ûæ'È ¹¸k àyyþYo\á©Wö¤rë+jgB²®œW–£m|8þ(è]㖡¢MUcñÀUWw»Îü–#)[KÕ¦ÌÞ1,ûpHË(‰RÇ`ÛZ198Qñfˆu_ӂ ßªuXR坅HÀGŽ$¶Z•„D%6™l“¸^G÷#?ºŽÎ–G"éÜ5)}®þDò󪫣¨Ü֗'ƒlN†°”‚ÈÇ¡.NÇà凙.pœ½e×u1~%WDFœí—À¾8•ÔÖ6}9>U•Òºe­c½ÌòyBïþt/'(üÄç jë<ë¬Ëò4Ò|°À(qo“”rs¥À¶š¬)«6FA²èSq8ÂøúœE/Úû¦Ý=u7#ð¬Âaù]NÆEØà®m-#*7øUÚdþwææ·£á`|Ujî¯ÖÔû7ÓW-â`|Ã,~N£ÿ¤‡z©+¬~ì#œeçn¢‘IŠww³ÅŠq¯|µé¬K<›¥£©NX|}ü˜)¦³¿ü“•: óÏhèq·”·©¢ç9¯3ïåo#*ßsǾå†2Q†F!:MƒÀ} |Anü)L˕óŒÉ¬0wë¢E;oe¶™r+ÁÐóÔnÊÙBô<Ö»òìæñMoÞ>{úTbÑäÑHøBÖÉ av¢Šå2y×C#)êÁ5<ô®î€#*Ž²¶–$4}}£9Ь|¥©_„0&­…jvZ¨ûÆßôƒ6±+ZîïlIˆ+šû£BÄP+:õQsÙ-âÆ=Ö©úOOn0qþyߕ`¶&]#4U3N÷‡àö¹¼‘8Ý·äî=ŠíþBe	uU™żG™løƒZ^Žé¼&#)k¨µ‚ÀÅ žðeÕNó|C|éåXAC®á‰Ô]i{d$¹×~Ný؏vȨâšz€¹8ªsÜ^©„µ™Oè`+êÉv͸‚R^æ§Ä…Kœœzç®È·q¨~$	†vÛ}æVšô×ý®fž«bK•,ø!R¿‰³z#*˜"Â#)mö± ša-÷ÀálQ1Ú%5òŽê.û9YçþÒõ–Ü¡S¯†^,«:ƒ:À´BàräTn¥@˜Rϸ¤¸2+'ªûiÍt°YnúH6-ùU܂ïW»ZS¶±ÃnÛº*O±ŒÕú»ôǽ°¢!Gx5eoœ7íC½0ò@\è	4˜÷ŽEí)+¾7¢ì=˜küªòqBBAŠéà7ó¹×â°Ù\Õµô•TŽz¨h.&ß|æÁĨ‰íÖ	û³ÁµLôãíÓöA¦§¨8gSk~„1TSpzëo‘Áž_8͓UcÁ	I¿çñóOÿàà=!€UùrTxF˜““/NNœ<zžº #*xÃyIæ¼m,}§¥¥ê|=,;0õFy‹Ci¦Ž:dÃãíG\Eùð	o®´"=’̽T•'G¨¬£_ªàÇåÆA։Ù3¼1éÊIn¯ß*&~é²M–¦÷)èŠIÅ8X<´‹Þ·¹‹¾£Šìü:í£›‡ñ•‘‡÷ÅCƈل¥ªˆH-=e½G‰ò1,Ô÷Ý##.®êè’4™z3!zþqú-EPéØ{61FX@sý³5ú2ÅĞj¿éÍqˆ¦jÜRE$ùMÜ´ÍK,嬰fÂÏo&ó÷x]h•mä°Ø\Ÿíj愂Éë˜bk‰ìuÂççìG]T0ܘÔ ž#*46,¾HŽPø]PóÊçÛNiZ×î¸@È¿vñ•ïV¨·QWz„ú0;ÏSÈ̽óÔâùà°ä+¾„Ž#4*&“µR©²7¥‰6U®C†ÁGÚ;qpÕ¬ÈY(͵qwQÚäVÇUì]sbývnû°sðíۗû-;m‘EÞ×8Æ$ºî2Ž#VH"Zº¹x#4_S¬7º(8˜ÛDœ+æ&F`¸_±ñ!Ì܌×Ŏ7³†%w5ç¤_™Ûiã®Ïôj§Kƍ>·;àtä@.Õwó;[°ƒÕ›ÐÑ:T5#4ØlóŒ£&ŽŸm•±ê;º&c>ß;g]ÆkêM;÷3·mÈfØ%gs›µièÑhûÃ]§¥=Îyždø;#4FÑòeIWE¶b`Šú.,E9¡÷"Á=˜Vñ|â×°L¦²Vli‘­¤‹?±^wÕ«!Q쪭gÌì®}÷¶ñ@b¸Ùä.!ÏR•{¥€ dm’ù(¥Ÿöþ›·ûoŽ<¬p)¸uˆ4Xÿ†Ò…Æq‘¹)K›|2bz€¶J+β¦Ë#ë7QÝxv˃›××M_ )ő3â¶èúÏ·wK%Zd@é¸f‹jØDð> H0ÜYû\àžéÏ(lva”W,-ûӖKyœ²ëÔ՝%TÜË#4NcQc™FƁ‘iôÒr2¦×ü6Ÿg#T£Âé{àӄß¡Fxe©üw:I´úa¦Ò#)þnrùº»wŸÚK¾oý–‘zïDՇOªy€Çà*Lߢ_Í#4¾Þ.=äc°%;óЈŒÓo¥ÑÆhöxX#4VUâ`cˆ´Ù«9ŽÝ)Ñ|(AÐ[¡ÔL”h*Ô¼“wÌÁ½kª6™Í8@£_U°w™Ì:¢‰Ý:kp*ârä Äÿ#)´ì#*Ó¨†š›Ñ$ºÃBàëc±«FXõ&aka#4âÉy#)œ¢ÞåC#4/p¦¾Bç:e<®HÁ‘}æ :¼#)^!_1ÿ‘·+ˆ¿Lv¿0ÖÿÄBx@C­Ž^IŸÇ¸H´êvÖY:/›—–£Èž<Bþ=8¼ˆÞV>™Í3™ìU<dÓ€¨“X,ö#4ɜQL:<¦X妪qr ‰)¢«l\o5tÌQOE<È^J•m!eòHƒÑ/Œ‚'³ÐÑ;*•F¦ü#¦“½ñÈf±›	}wܙ"½3DzÂy%ÃîY6L5²ÎþÃy6]1û=(ê’`—táŸM7Ïn7ñ·yÞÍ/ÑU:5½@Çyna`¤ûlg¦+w2"­%,/#4­1®¶«ÍfÕ½è£]<æÙlì¢¨-¬Áȍ˖]ôgÁ4ÔöÍM®Í¨;·{Iw:]ãQµÙ*º#4—	^Ý©”åÖAµ–ñƒÖ¹YX ˜ª©P;ý¤ú—%T1WgêØ¢êô#Â-·¦ì€Æ¯q9^Á&û"	.C=Ò-W¦ƒÊÑUËóøóü*ÜÄŽ+ÅÀ²Ë¦Š\ý€n¼ÛöK4¹¥ö䬕埜ƒQÔœý	&D2.cåÔ+Ê1›ò½ŠÐ)ã¸Dx³$ü-ÅX¶Ç8Ül>G™ÏœÌ7!*9#)ò·CZ/µÒæå:v8ô©'¯ˆ\cÆ»‘wÎäz¢¡éµÇûÂxBn‰ÿ*惞’$#,»>#Š(9ukaÛd*#49Ql!B]Çæy+ô 2Ó©Ž¥Gko|^#4i€Û“)Öó]t­Â,s4H*GÞjÈ€™N3’_Ýõ‘ú%,#4P,(Œ}XÝ7_¿r?¦^å;¿KÚ¾¶á•†Ú)âgÙÑöÇ×uÞ{à®ämŒ~CfíWÀæÝþׁ¾ÿy{糝þó§Ow>à?ÿNðŸgY2Ÿ]D(xƒ®mf€æî8GôQϯdoÞþõ͞jÙ±®£÷+êɑÀ ^’ûÂæiøŽêLÒéÄêÙB|ÇiÙíðp6½-ɚ¬‡%¡;¹°$	KB¯uµ%‘;:ét:Úxýö+ñ;]é–ÚF/­nÞÃó\œ7×[½í8_oýžðÛÛ¡@8ä݁½éë·ß½_•·ùŽ™½»þíîú!$Ä<‰&bG;'Dé?£ï÷£]܎“èË·¯_F»ÑÉrûìxkû?·Q¥òý¾#*zBa|#)‘Ð';$¾•4ì	†½;xóùC§Ïæö÷þúÂgöLòÿ«ùCŕ&Å Á§¡_ì|ziÂÏÏ͇a”üØp–ñit2£/ß°Ý$àæ‹ñ#)嵊jþXfåsåo1ì8‹î›¹+[7Ãá)M·#*ÊfÅDÄ»÷òBˆõî‰ì«A&ì³è#ãVåÎÎҔ8Úÿ­gôÖcEÌþbt¦²1ŒG®;(0‰²Q·§r1©·ô9·ÔgyÌٝ¦Ñõ|{kO‹n®ÓT;M!ôw€¤àWZܨ;y8»Å` >ßjQY{ÒëtÒµµµÆ£÷‰Å?h1óßÍ ?¿Dn»wÙ)óv£ñh—3Üe4#*è¼@;7‘špÌmâQã¢*È.dŒ¤u¤Nhõ†2GJ}b]$¹o4<½!¢Sädfˆb‘úykr†Â[¯*Â	=wm¯øºt+!›ë#sµRSnܘ!ºÛ…åCgQëäf#Þm¶Úãö’ö·*@ÇÇ°×@µ„Z¶_Ñ«¯¹#UxÄs.Œß.Gt÷¼”=·&m鵑¦ø žŽX®×f×Ùp<yžj	o^½#*´äø”2J¹©ê`³Êù·$rF|.omnjȪ D”mI*R‚IôÒ¶†Ö£R#*ÆlNfÑãH߬ï;½•Ú±™)on[áGA¼ºa8$,Ô¯9TG##*æ®''³~pßä•MXéSŽ'ow˜ºqÿcôÒ_ãpL¦©-ΓբèáÎ4âx–•¡	ôâl#)‡<i«¿zU? #4XBÊKé¢jNÃFÈ%ð'#4îuV^pÅhOû˜.7¢4’)Œiû2“ãEþ̚“1C–šÏ3O62ïýÚ9™èD&O¶#Îs<~F…Jó`pnq8Ы©C<—»å¥jÀv"̬\ðª¸#4:ÏÕ}2Çm[¿Ò!“D`?®çùº,H?ï¾ãì“3â#)Š)Hªi¹¨rÁ%#*⺂ÅúW?_ðpX¹2Û¥%)kÚ#*ž'¬RI[CšêF>$«žUMg©„–'I@h­C\¡z:–ÚÆ#4/ßÅ$#*f0J$ÍÝóVÄa|éXÇ?[E1˜ö¶Ó€¨ö¶Cu™Þv#)yƒñ	Ȫ~wØÿþí{šnK%ÛÀ Ë©K’4Ÿ’yæ;»-ɦ$œ¹ShäN””!°Åw3±ºxÔ ؽ¸è	öë|q»øɬõÅG'ãø_À%yrÜúæ_íÇ_´Fÿºü×0ŽqgJüþ·ºÖ½¼ H¿®B`*¿kº7ßt<ThàN´Õ€P”fwqÊ6sqÌ<_ä+¼s䝕¼W°£·+l1:¬%oÎÆó#)Þû4ÙÉÂä¢fƇ"û&ŒÚ2y7GµžÄÙW^oŽú­½+¯Þª0¹°Pv7هìÙâÜ\4;äPǓÄ=“H^$€D-¢fó•ú hëý„|ÃÌ©Ê,vZ2(3Õfø“â·6ëÅǺ#)!’Üt»ÎÀ®dÅ{øsßÑeN¡ë‚°›OŠ±‚°†3FBϾïÀ»Cœ+ÝÍ]XP¯É‰¸º.đÅüÔ};u/0ÃÉï—ýá,µìUÌahâ¦aËÓêX2íöûBà[݇¾r̲ò͚r|ÎÑû—û_~÷·,RØ:C˜*<"‡U4Rh™\fKAK¾µ|ÂÒ3òHª.TÍÁUü3ÏÀý«ïåÞ3m){3½©öÌêú(--ãV#4EVõp¬m®îbüPב–Œd3߯£l¤}KˀÝD'¤øüùö2‘ÄešŸÎœ}›&³[©ÌÝcBý¤iaY‰^&Sñ¿iAH›RüðSzò|–¹Ê?ÆO°wÃùj¡X¶{É ˆkÁ¬‚¥•]Ǿ–Å J2lr´iä»ó(bŸèÈ9#í—[.üTãDÆ?1ïœvÓá<œc	ÊïB¦?>ì~@äÿä*õ“_ÉäjùÿÖÓ­­í‚üÿéöÓgäÿÿ«åÿµB~ò½(nM¤¶>käÐþ9œ†„ô×p3	Óâô֔ýNÞ뎓~‡ÍÊÛ½¹bTQ;šXaqI>wÏrê‡Ñ´NS‘V)ZŒÑ<:>þçË›ðçÕë_ÒÓÁ›½ÎáÑ.ü¼{qô5‡ußïu^íÂ_~=úê^áÖ9媷ñV CÞu/³n¨	MZê×/á°µ‹¶}jîµ}Šª{|7º¢f6ɖM¹ÊI½ª:‰$óµí|½ÿâåþ{|Æò\^¤XܵÜÛÚy#*Œ:'Ä'ßê×o¾áüÈYj˜ï_y=‚CçðèõÁ—o_¼—\9@ã¹Wƒ9èëBr“8Húµ$ńîùñ M_¼yyðÞ÷A~	“´¥]Á[‡‹ÉÃÈsŒlæ,Ƨ}éOn•´¢vŽíþ#)ÿ¾€7XÆ"í“YHâ|æóIŽx©@4ÎG|ÄAq<lÁ‡G·‡qšFÓA@¢ÉÙlLh^¢Á×^﷉µ§+xbjX±¸¿ÄÅ«¶Œâ!RÞ¾1¡°­÷ÃÅ¡?jFYÔdŋ»:gS\¢ÇÆÂÞ»*7LœãÏiªEloh„ úó™,–ÜX! ÎI}WDÁ⏸W+£`NNýÐÞæ"ë >ƒ2^mˆ¡lõ]»Â,G$E¡mœ\u†c%Å¡‹©ö±;ÿöÖHfN=ãUŽBvéñªŒNr(?ýD©6±Úêy#A_’ƒ…^éaa#)äònÅȱ×'¼”7ᬭuͪŒ}ÓæERœ´æãøƒÛõþßÿߝý*€;øÿ­O·?+òÿOž|ðÿþ»áÿÅ÷9ÅgïÐøýåkV žÝY˜ƒ³Â\+ê΄b;Çza,Jª¬#ÆF·+iôâ=J&(‚;s>ì^ä-ø@|cäA©(n•ò‰ÂÒãhÖË£ÓÆ¿÷ú¿èþ*J€w¯ÿ'ÅõÿéÖö‡õÿ{ÐÿÎÝÝ|TlïÎî½Î#˜Ép ¹èõ¢SYð‡nÁÓº=äÓ,ÜÍÄÜ$X=óٝ1†ÿ¨”(‰P>ŠþM9©`ý'ì^õ¦w­ÿ§ÛÏ#4ëÿÓ'Ï>ìÿ¿;ù#4ˆh³	âÙ°¯Ú.S=šÒRTH#*¢±  7ÌQ­‰dP$Éò6ĉú^}A-Æ)üû†‚õ6È'ã_ž¸cýo?ýl§¸þ·>Èÿ§ë…ÈßËöYÂIÓõž²å/ß¾Aq+=8Ùðáû½#)ÜìÇææ‚açÇ`$(‘…‚XXö%°øô§·=ú{+g‘³ÁE‡+ˆP/»yç26û‘/ä5|…HFÊwûtöù¨1Ñ‚ˆhMVÈö"ô ÙÖ'öÀKµo»#Ùåedå€÷(ç§C©æ• ÍÔs"µš0†%á7ßôS+Î%¿l©Î*‡$[Ób'|)ñ€³¡KÜ"IÀ0úQB†°ÿïxÔ»›þ«BÞ/¼ÜÅÿmV¼ÿýôé³ôÿ7ýÿ zý¿oý÷GýÿùÏ㝭¢üçégO?¬ÿ߃ü§`ïYù$ý‡Ša¯”#*Áw´>õwàgØw""¼ý¦[jJÔõ;]H‡º›Žx¹›ÿæe6œF§,!F­DÌ¿µö²¹Ç7¥³æõZœ¦›ÛÂ@ݕŸh?Fz%è³D@qºì{ùíËæõvÛg+#*ë¢ûõ~6ÏzsˆÙÓ#4°%´ñhàZlºâŒ&cwwà£ëªëT«Ï헞×Ñ#4¦ï&ù`‰¢°ë¶S° nU£wXASͲᤇžƒÇ›ˆD:L§ƒ²ÎÕõ°CV¨kn°œŽ‹¹\´99GCJ#4bՏéÝi|‚½”“±:hˆÕÙÀܬ#4ˆæ¥ª©‹Oy¼Þº\ŒžÆ2oïµÄsØQl&A]EÕ½zþî`¯0#)æëëÍüxã¾$ö7û)]öÚ­â#)&ýe _Ÿk“JáÜÉ?ãÐyeÞé°;GíÎ4e/Ñ=׀_SÁ#4ˆì¢ÚiGñóòô§•Œ‹äϐbrãöå‹é”ð´Ñh^ô{U#43~‡ó éQ\¾J²>Bi²ê +Òb¹@’®˜ÏLciÒmA9[\‹¿½9Øÿ¯»Ãî¯À#)¬Þÿw*ä¿OŸ}úÿÿ]ìÿ³¬JDp+‰¢x±BL‚%äÆ!Ð.V%¥´{‰’‚‚Òݜ˙pYôB9ú€H×¾ñúÅÞZ¿ï÷ß¼}#ïDi×NKÒ£²@dœ8ˆ²Ú^E8ôHõ‡ò 3Ö¯ƒ˜Š‹~F#4Hœ§b9w½|eç]';g ©&âé(P—+ã4V÷ T•eÖCM°ï䝠4†¾PáýÁ¬S†ÔaŸ!ÖL˜Ü}8€2Û_Œ¦~6Í;Nje•ó;㝒ˠÞU÷"Ë-²–]¥¢F"jEÙlËäº%ìo	ÅF6…T¥å¦îU&Ñní¹#4ùH$3Íí	W%Zä™Æ'*΁&iNóÓXÇ»,ZږºVx‰è«·_þŸý½#'¨\XgÜðâl­4bì<­ó>H½)1NeNÒ!ÌÑVä&v”pÜRÍÈ« æ,‚VµGm¼—#ìÂNTßeÔU­QÇàÝ knáL7º}Niœóy…>Iªó3N>*ñÀY5Ð9íÖg¯;&Ÿ^fŠ~’	’¾º¨ÀsUë4ȋƒïߍ`èœãf¼š°´£4póËql֙WõvSøèë÷À—¦pÅ–˜AÇXÇw\blÂx<ir}Ð#*´ð™ê6ÏÍI5¢§ˆ©qa‚©$ÛQÚ̆C[FÞ>êÉù *Í&ôâZÓ/Ž^\74ëJפG¬¢x]©¢Â4jo_–òp‰*Ǘn²ÙÊȑëÂœ¬º|P¹ëîtÖO¶¡‚Âõ @z¿Ðiü€’0.èBÖ·m$„Q5gïæ«®‘~mú¥Çmè\à¨ØñÍç(Ñï<Óª¨àgM1Fqþð§Mª†›CÅDvÁãy6ƒÁ˜iõ²énìWmlÜé”LvDdAtëêLgƒk r÷ÚP5²n”AͦWÅjӝ*T#*¶æTG$ ¬0`Òh»½…ðފÖzÑað—$zñî@yC4ÒäŸmU0K×Úkj¾,©Ð<]ÛZ‡‚¦6k[íµ#*Å¶ÙFÂFô9m¬µ·Ö<“d")	_¹š“ÑHÚánš[Eû7$øIp£Ì„zT¤qáàã¾|qôâýÛ·GhõBg×Oˆ#)،`°	U¹ÈÁIpäü¶µß½ØûæÅWû6±¨õWÔÃ|¡š¼Ù{ýÝË}ªÈz¾Iö-¥:$åéTÙWgˆ6¾¨é.ù*®Q¹€\ÑBêŸV¯5‰eXÉp¿E6S`;z]¤J~V·Ò˜8K¨K6f$#)öՆhÙaúøù–#)qÓ{~mO'âݳ¶¼Ýeã*öl¬ôS"‡œ–Âô‡ÔqN%Ðp›ttxP´ÉÙ{v¡4ál¦“êôÝ#*¬‰Âä]c[ÈÙuxĐ:`S¢@¯Ã[¥Ý&Mmm`•ã¯)›sè2µ$ºçh—­fN‚èX g*‡ÝëÆ.‰Ž÷li«Æw÷š™›†.7bîñ}º»ò–Ë3­Ï×,``ÜJ0luþÛA^äÒ^´_še¸ÆÅp¼¸†Ž"Ð惿ÿŒgp|s#*ÉƧa²šmlÊ9Ù±9eí7×½¥®Ï=ú©è"óZ¹"þœ:UöMx€ÑØƼéÚê#*Sý¡’ÿ¼(ȚßãÉö¿¦;,ìÚ³ÍÑUÀò'¡/×uù(Á>ñ€E„l³ÇI·s¼*õøDLtoŽ¹¢¬¸²–u[VXŒi~¦Çšža©8å&í|q~>X¶bà(ڗkoóðÇ~-ìZxø’Ëhö¹l<˜Wí¤Ià·Ü–Ä]ƒ}Ÿª·|Õ㖐·d:|-Ž¥!.»ŠVÀ§‡4Á±a\	X{äâÜï&¤ÂšC¹¾x¦¸»º¥ƒN#*·_6‘uÃÖhñqèĉ#gå˜;’hüb‡‘ã’è@¤•®¾úµB˜¹AÙÚXl©âMú[½`#4	ÉRÌ_ùÄxj(ôa1¨Íw‘‹6Õè\/8m>a3êDOµ¶©Õ	*ôàHìyÏK¡œ2䋶¾ð•¸#)wú<Þõú„3¾ŽjGñéFÔî!dꃛlíud¬œdCµ<ýVèqâÚ¹¯a9ýÛõuAïØ=>2÷?Œ•ñçø"XˆV?Á¤ ­ºÀšIˆ×n‚¹O¥tt•jõ	êZ.G„¼!:1PwDf˺3Númù)Æ¿À‹ÆêZ£Å¥\ç‹)Œä1âß,c·<áë©ÎŽQ~ъöÐ÷ŠÒ0Êz®çÜæó”]ÝÖtb¾¹m҅<OmZÆ>Ãïå˜4 ª¦vì?t>™4'èØeœe}®ñÚz8ˆ¶’¶ÚîÖGOþiÆÙØS¨Õ  —YÊsÍ䝶¶’Ï“­89›‹w™ª°Ky	-²óíÁ([iSWÅ©MÜùòý‹7{_cRڊXΪ’£šD¦üãݝSÏTXQ¼T7E¢sƒSoJS·Oã$iY\+^zÛG#4*nIT…ÙUõ?ñkîæÈúyÀ^øúÅ÷û¹'!h¨«‹‚¦ÿTU´«ìÍؔé̼^‡|GÀG½dI"L››=Úך$ÝÍ£C1ç}…€|—êGÝù0뢃{% %ïHÅ|ð#)uEïü¢õø±æ×õKÛë{‚eà5=!¢ú³ž•h‚+FV5¹/X£D¡8¹Êá.(4`ö÷j–¾ÈÝÛb<ø{áò#*vŒ½Hôä¥q-øÅúÁOEõ°lø’§ø™Ê¦Tì²ÆcœSڑn³éL>½#*»VÄ%P“îb8'¢• ØLZ1j#`Ú¿}ñÞ¾o‘yû>JP‹(ŽØëšê	L<9áîBµûê-­5ö”*—Æ8ÊñïÝþ«×é]´ûE•€îÒÿýìIÑÿ˧Ϟ}°ÿþÝÙ1þ[ô[µrŽº:pG‰¼5̉p¡Ú#4Š¡kî$–nOF¶ô×þËtI§%¾Q~y¼4ǧíÝS„#4&X§|<8‡VÊílKña¡š¤¸cë{usñ‰¸õùí4Å øE#)f‘#*‰zËe³76{Í^¯¹	û­í¡ÖbIì¤3p×ܐ–#4Š7¶Áyԋ$:ÂýÓÁ×¼Ãþj2+ä%¶\+8÷üa«ùªù#4þbà+ Å¨Øy¯X¯~}É}†æ`o$µ±è«WþáwbH oÉшި'éÏâw1³›ÁpHæݽ½›JTŽê,)+ìXÂÄ–$QOÅÅA•–P2‹ƒ}îÞ'NDî´y®nØcŠN&/U%#4!”	­ DUF‡ãˆû†G¬´æ–®õšªY°öE´N˜Ð2™©î<aʺÉ|u“`3 #4nž¦ð—_]-O×D•Íˆ7#4wIËƲÛz@>ƒÓ–].VÏ#*¬o*¤8PfŸ!ƒéݕώ»3›ß+³ù½2ã³@~gv¯.ÃïÿpPvøÛÚÿ}¶ý¬„ÿðlëƒþïï`ÿïtÎ8;ÝÙÉ.†dž²ñ<ðWÅ2¨Š°×&5áJtFu]¥)¬ ²gûL¡eWh#*cYNÍ)ð=ØhÝí0ãã|ϺxŠÅýŽ:WóÉ_q/¹Êné€{Ï_LæYŸŽ»ü¸I™¸/ËÑÐ|„7÷}vÞû|g§Ÿáwt֒Ã	rÔ¥œ"GR.Ñ[Y•v,p*rEÔë3¼à«“r¼~»÷â5j@X#*=2ð÷þV#HÂèÑ«ò&W TÑ»wNïÞï¿:øÒòî;Åeö§`¤‰) ØGáÉbƒ©´±3‹¬6öámDŽwÎ]ïXXKÌ<ØðŠ"T>õ=êÅ:Y{8–†#)Õ¢&xãYPjÁ0¼¹ˆ4BÝ%-}ôò—#)õ‰‘XëMCæA0©–R4’ojz瀚ܗ—VæC#4Ç*ù+•8xsôzïÅÞ×ûéq8p’IA§4N¨à„2Â+¾ £woq¸¶x8âF#42¦)HXuZ›F7ÈEì¼Üõâ»×G¬2ƒ&iÉÁEsCoTußgýŸßϛ›½&€Ì¤NÒç a·øö¦å[èPYÒ¢BVF·¬%íleI-•9¦çS_ûMv[@®55šKh®­çkjU]7èC5ñC\¡Ý­&ӷǾ*ª™0pځ&¯‰{à§ÆµÐ¿®úu°§W'¾•úhª„ƒªc{»òúÃU{AVIN¦“jr2üfÄJ®Ð‘“P¿6JŠðâÝ»7/¾Ý‡#4+õªÒ´¬_߇VÝ9n­$þGòüÄ¢›'©Þ”„	Fôø–$ç“Þü²9™¢¢ݑnÞd1C˜>¹qq£ÞlÐEs·o‚%åŽrâ}Æ»ãþõPșm¤ƒÏÈDI;Ú(ãÝ0:ÞìnþãÅæwþÔ>݈ô–³ Å!ÌÊ;=ÒÄi ~•BW®¦Š«ÎK¯ü6¢6ÎZ>ÌÖ,CˆP‡;<riíâÂë†h֌Âðpª]«!^µÛí©1s‡,-*qŽN&ø´Ñólº¡yè{ôz¯óíþáዯö##*”Ù¿AÕmx=2»ü»¥µO…Õ#)¼¦ê]Âê)Ìv#4‹˜m¿…£’…àa×ÜìE„|ã&k´°Ñ#4Aæ5ù\hhÔ›xª5õÙô$°`3ØHß~õêÛ#}ä¡÷C<%ÎH)TmvHúÞ¾}Ù¸m@_h»gò¢_hÿÖ¢¥"Å.ÚGùâϯ#)õá‚êÃíŒJ÷õŽæŽ²Ù…·q.⿾Ûÿڙî†ÅL³ÙP#4ÁXrmuŠ÷UÄ+‘	x'`0Èm²!ô¤+Që¼IuŽ`ÎͳÙø±LëÀÕÑÁ¸J®ôflÃ#4]‹3Y©öÞšTû׿üś6ã=UKô¾Øµ*ï9ýôüåÿÎûŸQ~ÝûÍí¿Ÿ=ÝÙ*á¶ýáþçwaÿ=ɓü¥;‰ó<X5Dàjü}·‹ Rj/8º‡€¦Ž†HI/é-—IwÖ#)FL''¼¨}FQÔèö†‹A³Û›®³~Þìö·áԍcóÁ ?¨å†îÕóÛ:ÚkvóË4Ï.є°y6˜çè©ð<›¡ÞóáäfÑìua€²y£×6{ÙlÞíèwÐ6{ƒÅ²…bsȁUzó!dýá?PÎòÛׇ÷ÀA×½¼L\ªß›ÝN瘡`~€ý'ýÏç—WÍ~wB¥öÏ.2`FáïޛýÞ`ÔE×ñ}ˆðäSùé7øw!ïH—#*»·Ð¯Íþeoڃ¢éÐöègÌo9ìy-_€Ãkö…‚¤"0˦ÍsÜOûÃ!<šç}øûcÖ¿íëøyÑÇކ¿Sè¢æÅ°»X^4Å9?#lKãbìú“›&=@ó/éç15§:ViÐAbøýͽÈ.áã`DSx¦8XëÆU6g8WùöÖ6fy¿‹œ|¸ŸõFsùéÓïTÞ§0™S 9üä1‚|#ž:£‹Ñ‹ÁÒBñæhÔkŽ&gùí~§3üGßÿ>阼£¼KÕå½QŽ'³,kŒò~7‡ù`tAQÆs”“DçĈ_÷þ·7ù¤‡–£!¤›/ñ_Ԁ¹Â5cMÇ<ñÆÓéœÒxÞ§AÅß³ÞFð÷E6»mNúg=HŒ?Ð#*üíM1`ØG&"‡‡Œ^³n¯G?‹9¿÷ÏèïðþB'c #4$òg[ôp£Ð˜äÓùUsڝaçOû—Mø0ÇNj	Э9ð°ø8C‰ØÍ-y›<#§ð)Ÿô·/‹†üö›Ÿäd%3ëæÜ|x€ºàå#)‡­’°æl#)󷿳՜M{ãþŒ~ò§ø3›ÃÏ|ԘÍ%æ:§K-ïug}Ì,ïÍ`M\gúpÓÌ3(-Ïx±À|AÓ/?ï5s˜´Øêüòºš™_oèã ?»ZL›ùxđºÑ÷	šÓäóBØäÝs(ëºGSW†u~¹_A¦@­ÏÏ=vî}“7³!þMƈ¶ƒuÂÜQùt{«IÄb±„=#)zéÏ·ü·ß¼î€z4T[çúüߜe´&›Í›ì-¬š7ƒ.Õã7“ßÇ£þ¥î¡‡)JÒða>5à—§y3ìwq#4݌ܱ7*!ßéÐtýÂt¦_H1—A\vñôÞ»l.aRÁÂn#)}wgv<áýW <=nEËgOQ9mԇß8÷ϟ¡”þâÛ KŸéG¾v8n!M§2ælDŠo#ÂiéC)—NX*‡…©]˜MJ‚žëea«àûõS›ß&`4˜ÂÞø`B:çÓRàu9¤-¿|J÷ò¦{µ†k8è#*ÃúáégXèÅš4BÝ';¦[æÝñ`1r½|Z§*¬Ñ˜«b ކÃÑý£M&ëŸaÕ>KèÆ}‚¶·Ú[	=ý¡½µæÝÈöµ¦ VzËW$1¤ ˜ÀšŒîÎ}<¡6‡ÝÜF	²+hÎLz–sTzÐB Â`xËÚ®MS"pˆ×ƒÙdŒ÷t¹/UDk@ù7åH£håÐ4‘ŽêzÔá~\ku8΁ö©z"n[|pŽŽNIê‚B­wxýöðû½Îы÷_íƓÙñ€4YÉ(Q)¯õÒ<ܨX;„ö“€§ÒsW³ÜĪhV)+׺җ°Y¢W~H#)hØj1Oì·rBHk™1hã½#Z&£˜Æ®Ãè‚wT›g‘˜$[•ÿúÅÿµó⻣·/÷ö÷Žð.ôjȾؔ!Ê6*Cõ_öÿº;W]ºËQñ+Á̀`£p#4_µAbÅ{~êõÇëTCÚæҝ«½¦J~àË ïЕ‡È(mmÚäa;Þ½xýzÿ¥ëñÔTUŒ2eŸƒGÍIû؟;õìn“{#)™²õYs“M"…¶3°Þe}Ø#4ËsÝM±p&KnX©-9k¯º©­bgýPm£íáØZ»ßoa‚ÐNÇDªëÇ¥ª‚AÖåqÃyW2ÅĄ#æõÀ‚´g²¼šQ²Íã.J4¥$	fK6–³œža•»gàÖÝsoºh؄<„p~ÌóØ»Ò…j—oÒ¨û8Àx#4Ŏ&ßv´×[ÅaNxjW®Ù?ª‘–¤0µumÓ9ÄŸ\÷ÒIysB»\þT—Ÿ·W¢Þ Ô½ñ|#Ý^a­DŘg0×PzOÎà@@Id)‚Cú&	Æy+[ï·!E´ä»l4lmmíOYïrҜœŸ7`Š7¼!¥—×_¦pʆó$Ýz®ç#*Š‹ðéú:þ¬¯s&[_—'ý€Y¬¯Ãßõõÿ¤_I¯·¸ŸO“W¢cGà†—çŸìï҆ðÉ÷ò»%Ú$kÅøˆ.¢R̐w¹˜jØK)¼ƒ ²‹Ï„·°ˆzQ…Žíá]:Ónò*+böò‹reÒuå%W^„Ÿ1Ž?%”Sš¿½iEÿ)ÊUÙi_KŽ¶’ºQk•Ž?ß=5YâÓim¾8T6Oil)ϧUyÂö#4ª€º%¦j‰É2ö–0ì…Zw…Vq-vžÄtí;¾N‘àežðeÚ^LûH ]w“xŸ×,¨¡ŒÃ?Ÿ±°ž Jð²^óv`ËeZ¾•3ÆÒØÚu«Mì½&ÅÝñ5³.Ã<cèilx±ËåÆqô	ãÄ&Ø^øç/¼¿Ãshßx€§N ØÆ#*«‹Š×½–ÜéÊëÅE6óx²üÎ6b-¶è.™Äê^@¡™/Fý#4žv/²/ÌEü>ýEbÞ̪wøzúÚÜ|Þ<ï†8ÖóZj‹Zë-Âtª¨pU‚Q¸ÁµTŒèq©àfcѕøæ5nUýÌúî-76ç™f¯%Ќ·ß¬Ú,`ͽµ¾ƒÙtJè˼Aßc¹ñ’3Oîà€=wNL£/{½"¦ï_ÉÑâͲ‹öÛi6î¤~ýÍþ_;¤«ÐùöÅÞ×oö“èðí«£?¿x¿ròçÉͳ§Ovpó:9ùvЛMòÉù¹xo¿I瓓×ßäf(@åš~¡*Ý«Uˆ„R~ù‹R#4Ùõ`Rµ]‹*ýl™n5(h;Ðbê_Û=èeaëöNj¶ŽËI(‹XT÷ƒÄôÖ´E¸VÄ£¸Ê❽ƒþ¥•¬d³laôÕûÉdþr0«ë1ƒKtÿ<ÆL¼Ø>­2„&‚Ì—£a¨ÑÒϛqN7> ‘î®N"ÃËq|§¬L®"w‚H,õ©8/ë¡B3䨢*¨ø²“è5nЁBŽw.'5»hÅ&õYŒr‚²KîU¦ôNXýÚYïª$9¹±×߯_2† ‘UÐw* j¦\ÔxžÍƁ.ÑßZ'ý“þ'mú‰[ûËiüÅnjÜZÈË»Šä™VäsZÑ÷{l–å(x'¤}?ÈÝáá|ÑLHpAƒ±ÎËôä/Ú b̪#€­ËO"q\zÍJ,W­²6~Åþ’õ¹k;Òhi£ýJÒhëidU‰Jó,Ñ{DÊ^ia‰#4˜7¨§IOA• gÙ,=Nºó}…±mV÷ò²#)K¯JsÏ-“ [e6h.JwnD4\OTzãÖ|A6JºªàŽ=ó¼ò¯œžSHåWa)ž¨>‰²R“Ûߨ“JõžÅJ]½ùғÞtáx8º‰ð<k"“ê0Äθ òÐwâÊùæ aé°à,Ô4´‘Â@­FªîÃt‘’ÈBPCtH§Äì*œúGóC]ŽÚ}à®qr‡ynP­°Â$¼Ø±‘Óp-ZŸÄ&–dA{Ûª¤Ð÷nhÄþ*tˆšn÷µÖ&iÓÃêJ ÀÂäqi¥Ü6)vqSœ^ç:í`;—Yg'=nòUýsñ~£(¨Y6­*ƒvF`%ì:²knS³Wù;Üu»ýEv8ú1 9?Ÿ~ßcsMä›?½šÿEkv¿ÊTm:‰Wñå?a繯­8+·¢„Zke—uU³»Ø}øp›=2‰¤ÙK„á]ª×Ì†ŽHšp¤F£^ÏØÈU™ËŒ`åu˜Í÷Ç×(#)nÊÉóÿù£^tÈZR|ùŽjW´Y²Î¿§iq£áªc¶ÖmTÑ'ц”q¿zšI’SŽÍÈÃïžjÙyyÑÛ+½pÍ»ê`Ëðt¦/‚ÓB¹S%UŒ+T÷Åb9º3tÚJ>Fà—%²Ð{$<Ž‹ii:Lס\xVvòñîîæö©¢;z“G&Û¢,çgV¿Á¢Î{õÉ¿GÓN÷ÈÃÒgÐO$ÒÀþÊ1·';¦ÉZyÒX]wÖFp+„Þ~bÉiƗ´Ø¸#~¡ª×Õ»²(FNಠNV9)òªÜ-Ö¯q>ÑÞk‘'ÜWI…Лs´xˆ¦;ÈrtÓIL:	-W¾z]àR9-ÞrBÅ÷öIpRÝelyåö±PxáÇå³ÏjI‡K™DP¡•RY‡ðˆÛI“ŠH´Ú'+£‘:Q´ábóݸpžõEH¿Eõ¹wçÃÁbø¨òÄE?[_DØö»Ë)ćW.Hœ¢m‡¯áùÍõO¯䖿%ŽÙ”ïl'8µQ9¢È£%ÞF!™òíʲÛ±Öpõ¢u35$9²<Âæˆ4Ê,S¿NyµlD~C^½P§—pôzÐZ-îË?i¹'¯"õ[µ•H¥ê	—fr¯¹Îoà'[q,vT4ÅÈñø,lá…9֐.NøŽI$gM5w¶¶?Su	¯þ¾̲¼ùŽtò›;íg‘5ºžÎ.:J•äΏaVÞñuÜ+²N…ù­¯kfo÷äD‚šÖät䟀ÛÒ>-;‰üA#hLä˜ålF{eB7ÚhqŠ Ç˜DèÚ©¿è‘6×c´zfÝr9›,ý†'ìÒÈßÈ̗·æ;X#*zºâÎԎ®Û²>ݶe¶·ÅÁ¥RãóÉñÖéŸheàdŠw€rbƒÚå“aÖQC#4#ïÎf)¶„põò$â@/ˆvGgýns¹»<V+X:n|oP]qmec„õÁõ4›)f+…Õ$“((ˆÚâ5#*|+ÂnÆÁ¹jTäÿ#*tOU®	²å ºAÛzŒ؄XÑÿÚßúU,ÙIøz¡úô°BdÀ„ÊIµ[׎ZÀy/ƋÐ;ë^¯J±w<ï:¹CðÆÚÉÉ!*Džœ|¿·V+¬ý¥Ë*-Ú½µŸx&~Çk÷>_?¿kw‹aìm4xyA‡ŸqëÞ<+/¸ëê͸uÆeÙIqE¹›8¾L²Ùyg?-³Úkïôî{ñ@UQ7zZ³R¢8y'`ŠxªèA¢£ÌmÎïyBb’R[Ë*yŠgEBŠ=î:uÔùÛôõÿüîðå7ôûù–;ÃâG=òt®¢Ïh·ÀÌIÝ/Óâ{Ñ÷@ÎS&ó¨nýÃm'þÍ$Ãh“pr¢P¸9<nlü†ÂàÚòÿ—È‹‡ú#4qh Ÿ¿ë\*ÑUVêŒF¬˜v±4ÚÿöÙӣΛGßïG!a÷±ŒO'ÝÞî-}æ{K——(ûÙý@9ö½v5“}iÏ®ÜÙ4Æ6þ„ñ4jÂPG¡ªh”ÏGÜ÷;÷р„Ôþ&U³|ÈtpC÷“:ßã¯8Õ,Æ¿Í`Œº?LfÞã aû›s8å‡pŠ¶âNñ¨“Oä?wøâ·Þƒy–ÿö€/÷áÿ•¿{x$VpùÈÈKIE[tÅÖPE|‹°R…º«ï»_¤:”³ÐÓ#‚ALϋAÿ.²§Uº8ƒÒ%Ã[(ª»égqŸoôaK­¢âސ#4ëÒA~ˆé&iÔ©üvƒ¬Õµä&ëö“OojSX”òg³Â]áºWÒΑ);¥†,fÃ4B‡ÝO>AADÏÚÔ|Ü>Éƛ‹ü ‹QþÉ|2ô>y²óùÓÏ?ð¯ (ì®úñ*E5#ǧ©¢Œ	÷áÿ?ÜÞÞÚ{ûíÄi:„ `ËhÓ©mÒ¦—êzšy'cÍ¢løا=ݘEíöÉÁËý“ïÿ<‹J'Ig5£~v÷÷Ë"£­‰M?8oÍ"¨1‰›këa+×kŠ_‹Z?B띷J+6zAÖXhx]4Û¬Øõ¬õLيŽ.³&mžMSºÉæd¬æÐ9{ùg¡ì»yøÍwÍ(j7ÏÐ{ë¼ÙŸd¹ çf#´³8˚"TÍúM(b}ֆ°­ÇD¶Wh¦¶˜Z<I«1‡ëÕ\Œ‡ª*BZvZ?‹¢AÞ¤EõÛÍÃ,ÛEIl¼^첤Ô׉[:ñ/Áɱd•M¿U—L•ÕþÓ[†³kõ‚vš8®0pô˜ú½¹m¶Èú"‘”ÂÁVÉ ]ñs#*×YŽª­•¿‡5-/]1q”:{`˜'“ì0É$´oLA½2ko^¼ÎÙ¬Ë÷5ÞQ’ÑÖ 'ôíA±75vzŒw«ëy{؍Ö5~Tx½q•yˆf6ƒÜu–d['9ÈæyMv‰pö‡CÕ~­¸g€¤ê¡wŽƒœz#4ÒQߍG¢tøBÖeHŒ”/Çø3i²+f§KÃñŽ5Ωµw}G¢ÉBŽ³îŒNç6ch÷­É×Ä<5¡Òš1‡“›lf?¢Ó¾ÅY+:iÃÛÇXPqpYíڂŸìFÉ&’¦Ö“a¿#õ±už@˜«¯sêQ‡ãSVÌÓ_©™û¢@¦VRçÒ(²rߪ|+K	?‡Eޖ#“ªB<½pXÏrÞÇ`ÌƜ˜ökV'¢Lxg¤-Èý±dNVÖ=×*#*ö³ý̀7žØ9‡KJ/%83£êKÎl>cŸ)a.Àٍ"“Šö8¯eêy64KÕcã3$KØ鮅Rgô­\Ydš%ª=²foθÍâ$)Ô©¢LŸåöP¾n©š·Šô±Ëq¸FŠRšãhñL”¶º÷ð«ý„–·PåBf¸æKùaX×çF)|§~¡ðTB:Úê[Ö(C¶6—˜¶ÞA2»k¸^tÛ¤gcì3¿a܇Î`¥#)孔½Â-Æ}ZI]r‹#*Q½ŽÆº™‹å-rnBÑüՃéŸ	L¯Û0­û¨Êœ)NÑé$ÚißIë;љ—`äT-	<a)åáal6ؓA¶JlÓ)HD¥Óò&®ˆãèðENÝ&§SX_×©_K>þŠØ=SÁÖäU´R'ⶕ}„IBc‘ö|E‡­#)Øí.æfÜZ²‘XÜÝëžCÝeØ#4Ö#cŽú¥+e#*!éùÐå²2¸×A¸§B·ŠöÿÁ×t¢éät¢	¾û.Ãß° ÁHùÞ¼íM6£þ Ä¯Ð;&«B>$‘ðCuí#)Øqo!ë]늢hc.>ÛIåÐéâ%dú„yÚC	O_,šn5Û/÷:{ï¾c#©ë¶QÀÁ¤8L5obŸJ1Dõ„ƒï»ƒ×ûï	–ú´ šÄz®ä¼6Äó_•æxwó‰¸ó\#*â°+@Mb&bшMðå}콎2äʅýåàõÁ›o8ø̄}ù\Ȧ"—rœCˆ§¨¢Œ.°bêíøhº‚¡‰½Û‹›Á8*‚q`o6Ù©?›ßLfWpšF`DN&zx‘3S3!IB“ÃO¿´0ðî^"#*ïAã,¿}ñæàLÙ´eF•ôHÉǵúÁþ<žÌl2ýb<+Äà™DÙÞ¾'#4¡ïýå/‘Á¥#)Z¢})°%b0CÞh#4&ÑF~{Žã¤½.d<TF,‡§#)ÊKHIÍY¨›ö ŸçƒóAFîù<%¼óÊá÷ºÀà@~äžw5DÚð曎ÅHzÍ|ØS	-FùE#4ìWó¦Ë““±þ%QŒÜ„OM=®…Eq©{LBä%õ31_¼g˜‚䨰ª¾g••¥Ò_¼r€Ë&´òÄRô>õu*ô=˜Ï5 ûßE•…˗ÉQEöÿ?{ïÞÖƑô#*ÿ#*ŸbÂ.×hÌ ƒ;÷²g	`‡]<€û•õèÒ#)Z„¤ÕHX<Ž¿û[§î®žƒo²{Û{mŒ¦Õçîêêª_i|vnL¢}ý07×Ô	#4Ãñ á挚º¸@FÌãhƒåq½QUÚç}šJnûª:oLëÖÞ(<OìN¥WÎ#¾¦ßÖGãÔ÷uħU7fuf©©4,…ÖѬU‰›uyqrÎ+#*3—”äz¤È#4™]ï¾rJÿ¸øüåYŽPwô´c}]ۉ•¤zýz¡t¸\*îî=ß?Ü;%OwÉÇí#*§';­ç„•BŸg/Îà2£½ÂÃç4/yçðÂwYÊÞE-ÏUèmÞ;^d·/¦w›~.ýSP]Íç;asÍq¼®I`¨úÇÇ8¸/ö¥/¶O$R;€mÇ~½~í>ÇG¯Î¶¸Ø-ÆÎÉYë嫃³}öÿ¾·ËYª"¡J°4çhíÌ%B	Ðî}„~|q!H@5êÞ_¥¨I"ªšPÄö³\Ð'ÊÝo¤¯2#4|ÿÊe ÀŠ,å{òü…aRÊҐFwȟ*ib«VÂ)ªÃ-!“ܲia‰pp:Ą:Û;9„ô&•#*a5µw3ÊG™^Øylúæ!ÿ6¦+5quå\ɓ*òÆÝ®Ÿ>ˆ9ø-íî'.ü!|Q}þ¦}ÔBö†G¬ç³¼“×gç`ŒvRÿ#*F{kFæÙQ†|¦ùîŠèƈøðâ&M_¿Ü=[¹ÕqƒäŠÙB{I‚P|2=gÉcÞë	'4W֏bó…]ÊWí#4‘ÈÛ¦' …û€6ª™[âҎg7Qˆ-ͨ\ЅgÝEîáCHóÓM.´ÔA}Ñ26dL‰âƨ{î<vÙNÒ.±<‡Z\ž—Ë3Åq!kuÊ]®åÖP…Ì-$¹ßž€W¸<îcè;ÉòjƊBj;WÝã«Û-þ0^šç­·nڃÞE*^+V€>Smœ·Z…¡zeÀ ´æ&=­8‘I]µÇpå`–w8nuÓNBj6Þx'“¦„P¤røMžÛÆÝ#wm$â¼bØbÈÈ#*»hßôúwئ•”»}4ѵP!T`ß?Ü>Þo=ß~¹ðÝ^­#41—Øc¼þ¿_Ó9;¶†N¸•Î{N,R	nïÓ‹äÔ[¢Ñƒ‡\ÅébÜ)N³´4rÔ¾Dw"ˆÄgr™V¦ÃXÅÞtöW¡+ýiÿtt¸×Ú>>Kü”gšþÁzx$NÂðp"u^ÇXúöhô¹ÿÓ0›Px3×üOË\ä£\û?ΎŽ¥é_qý'øÿêuþî¿îóÿ¾ñÝwyÿïß>è¯þ¿¾#)ÿ_ÀMÝëp«=Ž/;<wåý:vœ,¸Ó)‘a5BH‚–ʈ=,’Ê뼑Ô%|z'†Ô‰~¾Ñ쑺×Ç"VÉ{üií7´±üå#n`0.z°)iö}ïBEžzrë<=¿ûÝýÿm|÷í·›Eÿß}]ÿ_†ÿ¿2w,µ®þЯ{ǝçîï<½@ç5¾¿?tœÎpýÃòI¸ 'òBYs¥è#*:¤ #)›GÎw,)Χƒnß}ª;¡DJ–]òîJô¢þùýöÉÎO»û'­“W?¾A_¸”ˆy°ÄóžîßB8#±škjˆ4¬·zNaŸ¶ùÓÜ8©ŸsïõÙGdÆÔÑGô&uN<—Ïä„H:šü®Ã­8'ráyY‘Š™ˆ‚6•§±%ã›Þ#)a؟F+ý%û2áâ—ú2&B’sC¥Ãºkïœ’y%d•õ …‰×á:N)¼ÕPËÞ íþPÑmüÈÏ`+ÀrP®#)ut5ªU‚cØєç0÷ø…ïããÔ;Ƙ@ﶢËrà¡®AÉd:ê§pÿÕz‹Ô¢'¢…ë5X³l¯>ä(Žš#€¯&ç£7#4}„kMæg‘}¡à´òt¿¾w™½jPѽ,€3]šÒM§Üd—pÅ„ï?Hݯ+ÜMWÙT¸tÞáÄDÅú¾S°Ö¸êø|QID*)82]`ŠÆ,(ÈÓ&0:ó.B3ó… ôƒÎÃÎښ{ý²ôÍ$öǽt¾È,X©¯Do”Ôv‡ÓI#*¦¿†õt#4Ä#+e<>gVqd`Ù@â¦WÇ"ꊏj*Åó2;9ç³bkkçèðùþ‹Æ긮b˜f£mÕ¨1‚ÊÁšj(Òßöἶÿ%Þàq”¯ºãBVŒàpëH1k‰Ê°¼äS}oU•<O«TF×ÇÞR¥ ÃúB£Â‚ Ì©EùŽ¾‰¼#4­ÒM"هìŽïö„¦,S 7Ґ´ ZBs‚¾äŒšr^#)ԒãÆo«(gÏI¿fÆL%1O¤–¦T[%‘GŒÒBwvvه»Wnî„!Ñ~¸æeÜ= ó’,§ö¢vOÚ>ÙÛE²lœI‰h±Ò/Èÿÿ&	×I|Ì$8fs‹Ôûé€ØѳM•q³™$+£Qg%ŸïÑVÓë;óòaN©æ¥ÈM>èýÓÜpܛ#¶O^´\ë¡!eG¨Œ¤V¬kÎ)™“©¨mègõ*•õ&©]Õ4\5âùçQe¿$Õõá,%Õѵ1+Sz†°R“°.ô›Ö¨e›ÈR‹Î«\…¢…'”NnOóûw]äOäÄ	ÞÂlþ•öÑMbóþ?%u®ËšµPÐPÎqjïŒuýÇùú{$ùÿ7{5#)&d|.Œ¦°óÜe$.ÏY)u`&)IØqW´˜ÛcÉ:ãěÐÞPèšÂÜâ#)¡º‘±'†>€¿?Ò"ø¬ïÃ×éɾíˆäߺöúÀQÂÅü“¢ûžu,}ÝÌ՜ïPvفñôy:J;½à`ì:“áø. “$´/“›	{ûË(]¯C›uVî^ÔÕÂXÓTUÂÄûuh÷Ñ:šÇÕ(ScÜW ³ÔÕšø¹J¢ÿõ’iOþ³wpùù@÷È67¾}œ“ÿ<ـ?_å?ÿ›å?ÿ.¡/Íáùbߐ҄|)aµÈ—éÜ+ôå*yb_'î÷oo`§&_ÚFÍê“ÿ9Bâ¯ÿû2öÿYÿxÿ{´ñ¨ ÿ²¹ùuÿÿÂ÷ÿßûaþÞ÷àIZ¸ÙÂߊ'?LᎀÒ}3«²1ÇzÊVX”‚í:>B®í÷¹ºú;;œ•e}jN}¶!´|Üu£ƒ«•”×w­v#+=®÷]€ËzPPµé|µQ›òÄýҏ×Ç$ÿ1YŽ°1’ë~úR}¹}ò½tVRú—2œØP$~>žôE#*´D“2,Ñ>#*×/Ž÷wÂreSˆ}ãaHÿélt1í÷KuMÅÐ6~„–¨äißÏ;à”®â#4óîëiÿõ¿éþNJ¹Ÿ›˜þ?~úèñ·ùûߣÇ_Ïÿ/äý?§e*#)îÍ?>vÓXTÐüjž€Ö\ŒË5Prw™Lp¹‚€Ï’´Úý^;K³¸ÓBC§ñ®†"ˆ…Ãlÿâ;E¶#)Ïrúæôlï%:ª&Ödž†##)9ž~‹Ê«òa;í~.ÖÁôêtIý¼}r*°7‚´G–•"“ª$؞Bk#*e>?ù—£“°Ñ–RßÂhÕîììîÓ‚¢rÔ/õ˜Í>½ˆ×¯MN›·´”nY»œ%ŸÖ¼C-R­ò&]óf’oª‹aÒhÕ3Àüµfp¡e“(Ôªó†'*Lšn«TU=H]ÑRя/VӄÿgTrRQɉ®¤1ÏPÅ&ÁgïýB	Ÿ¹ãŠô?¶ÍíÌ5wûÔöðßü]ùJ~©÷ù.?Yð»îšÇátBϒ«Ýú0\­Yëq>ÚE@Wgñ¡Ÿ?,™ø“…(ÿ‚¤«d#*ÄHޅ¶'“qï|:Iýg!?kÒÀ?MûBƒ_¥}1¢ÎVSžvzƒ~F/(ð‡˜ô,MÔ¯bwàLVÊÍ‚·4‰†“Gl¤fy ZŒÄGŠÚLJ”EԌµú¡ÁÖÂtè)ë³}žA´@¹ìNµß­ûFš÷ØRHŠíÈ9_ƺ76ÐäèO'v”X#4ð¥"‚¯È‚uëfãNuB‘%´©x½†¼µÈ«£GšÒb#)=åv®z}˜[µ|}©Ò¨~sŽÔ¢|#4!·zBK¬æâý+âz‹CíÁ,[ÔB¢ ¨Uٌ¡UîÁyh¦›7U+´ülmâF3ŠÖ#4j‘U*ätÔ¡Y‚m]ê¼y¿ëÖ"_B“#*™hÕ •Ó“"Myë´æFþcggØŽ“ðÍÞÁÁÑ/p3~—ö.¯&ÉcDšÎ&hÆà`«›aW—£ïž<aõ¼2~$7V0Ö·#4ëÈøžŒyœ—fZ6HÇíÉp\g˜Ì¯Þ¾Ö`DáY`+Ys¢‚ šwâ2‡€Æ-^ýhµ¨Z-øE0K­µÐÜÿ)OD=’Ý 3-–[ =!:™¥ýڂ#²Æ”‚7ÖkÅ"i/®…b÷l£`²æZ‡·ƒégøßY¾í˜Hiî™Õéìɔ1>Yãˤ°ÍÚz¸†”ÙðM#)þüüG§w«ô<ëÚ=ÊõLÕj­È‚¢²FϒGÎO¯%!e¦<›f¸“e܌þ^ƒþÎÒњd]%¸Òæc­£ô,-„Þê1ÀAÓû<7”ä*}–²T§-{üà:~ðàúÑQK²)Bm9sZÚ@ê^>“Åap@ÆÀ3eT†–Cf0º¹¨EZ%n¢*wsá¹q÷_žiĽ#*¶l$Eƒ¶Iˆ¹bÄhOXé	{ài#GÔڐµª¬Å¡”!nsX­	eJªÆLWÍ-QGԝö%†næËù ¾u„ð­SµQêE§ä7]må±›Ëf	9eáj~^H Î÷¨Ô‘]zsžvñÖ˜ž!­Vìj‰½ëOfyÖÔ¨q`îÂÝZI?p2b7£ÈOÝ×í¸ÄæWÓ$2záë<Æek5û+-c=þ¨ýbk«fáóù39—”u¹Ë“SÃÙ>AÝaºù'‹Ð?üù=ü•³0:8þ‰õôÛoéLÃÐ^Nj>MØ?’ÐN¼nލÛÎ2Òº"DíÍð6­î„#4_#4$o€-û¼SÐ!.ðèý,Få¤0Æ¢£e©Ÿgr_Åñ¯ƒlO¥•h	;ƒtm}öÙ,Ã8#—Yh‡%—¥]š%zI-›u‚ùyA,›*–¸š"F²—eÓs#4«éèƬ{Sg‰á˒™Þ\ÌÞb†çÿÄk‰NrRA«çßdˆ3Z—¶Ô❣b,#ʧ­ç¸¦º=WŒsRá¼#4¶&sî\^W”Ó{•ü¶7´D	ì> @…­üV3æ嗋§ÀبgyÉe˜ôÖ8í¨»°9`ñ<<Hô-B’—Çá=OO#)éí;wWB.{‚u8g`çš(%Þ£é[ÖHž¥|½èŠi"M#4ÌQ¹«†]uïl2(Îó÷úÀ@ówh ]~áâMjh˜´Òn>ß¹±™3ë\ôB«0MåH+tYAoÛ+: &¹ÕË55Yó¥0ô ãrÑ,õY6Z7‚‰T%00ëýŽl²ø¢&» ½,¬ðSçÊÚ¬Yðt#çÄ6¢ü,®ûGz§NH—4H½VM!šé³87º±»ê£€jÂbvp¥Ö[Ր÷c…E`O™ëI~òMa¾“HnjOqÄÈ{ÐGšÓ5ÈzÄ»S'ßϗ—*yn9&­NíØMDzB‹¥L+r&íÛ#)˜ ,ïóû‹ì©¨ÇðJ#^rõ|Îít{­ª“›xʵոÞ*gœ–u±Qàc‚±£!ÙªaUMJšõfE  .±¢é^º ˜M²{]Áþç]OI®/ݺ±Ø»»¦¹^š&z’¯\3{A†ŽßË£ÆïÜu„Ôøx€âP·2šeÌ=ª·Z#*(0’¨³’2Ü»ÙlçƒÓ¨Q#4÷Y$‰ÃÐÛÅ©=Ä=	—`¦¦çûÔ?7‚¯‚^*qãNØû£>&áßÒ£µÍ­f³©›ŽXôeî+wEÆ"2÷y6½½+]ù¶“‰ù"´¨´	‚ámXєÓÌzg±êÒvçP*œF§v'W|uÒ¤3|kl¹íÇItJö.óµvçÉïê92•å°j±˜Â(º?o´%	¡òíÏ,ü{gh5K•—U8òYÓ>º-Ï9—2c¾ŒÞþsjrmkr]Z“²ªTð¸ívÍüÕhp]jӂ…•ÊZU¬”téTdAí%’.p}þ’œÃøñŽm:–.NÙµ¾:M.K/N[Þ^>qëv˓P–uÊÌ:yQ·›5+ӱ¬#4}•?$åoÂ$sr{TÊþ«÷6:sï[;ÿæþÏöm›‚³PA̽Ï3ê“ð^E&®Ð4ÙõtsvµÐyI~€þàŠ·4×ezemaŒœ¨Á™Ó“á³~)l=(Ð?ÿî0³9¯úìns4¢ÃÅ+"£HKý:³GL Nw5k‘©Ì¢¦=ö˜¾-#)iêQ›'ä[Î1,+MÃKåðævˆ®‚æ ÑùO,J”{´$™¾Š®³ܬޒG-– ù;·Â2øȜ"U—D誤≙S” ¨‘IÝ3—Aú\åÜx¨X¡Û|$=[\DÆÇ…¾´½l8* u5ÊÈG¹«œâcc—3Æå+D‹dž­“Bwl—õÊº*Oÿ<Q´<#3—Z‘KÛµ mÒ½/©°4¬C¥ôK–’cŠÇ’r]-C›—ßæÿüž'Þîþɇб0™˜¦Kœ_疘f¼ˆ$gJlÅt¼Ô>‡´ŽI}´h½Ý#*¦7¾‡æZcsý/Í·o»~݈jzÓˆÞoď>üðçð¾í´›ßWå}ó^yÄ=4H$¿éúӐŸQÃu/`÷cßTáh˜õfx*ÛX„5¨…YoڝõaèÁê’Ø9ÏEÙ§=ª•¸M¦Dø͹eîËFéÐA‘s£L[†#ûmÃÆð6@+Û=ž…ioúz'K‡;'§îBóqº,éä‰Êãn‡_wí;/#4f)m~CÙ³9`vKœ{íIï¼å@Z°­Ÿ«Ä²ÉÆßYžeîÞÙg:Œzl½#ÓQ¿#*›ºIã3´ü^u#&ù-–Oj§[[""ܬYÂyºÛ¡} X»2:IŠát?Z^䨸5ž}ßæ}ÿÿ}æH–4´™S¢vk%ÂùGߐ"Ác~CËåùEVrî™ïóZ%#*¶!‹=UŠ›öU;O	= þcÿøxo·4Ý`ØJÇcÆh@Q¡î²Ã鹈ÉËKK(J˜¹Z#*m56‹Û}ÛÛëaj>4ªWÖ™¿õSßUoüîøÇ®ö›Úd3öNýûkDp5¢—Asàã+3yì#4ÉînØþ¥²ëåË+†f¤)ägäÒäÑǔ@ù«èÏëºÉ£xò8§Û7/ùcšÝẸàÃ-¤§ü^ži.³tߛaîÑpi$¯é®>áë¤a3Lõ"Q´Ê»ÝŽyu/ƾ6ÂuÓ>ȬnÌlæÖù»:+>‚ÔtŒ;•GD¬Å@ìF™bÝΛíC|›¡ˆ.i„uô=ÞdmƒëôîÝpÜu#4ÌE„§<CP°¦—ÈUhñ	õûÌW­±±Sb¯N¥#4Fïå“ÅQ“Ù¥7¨x.1†lJ']à^O\ž¯é!M ³ÂèŸf~s'¶¹¨B|¡–NdO÷#4¥ÁØ>ýGë`ûÝzyá¸ï·^îyõšÐ5}òR3gµJ`BÜkî\<6ãœøW‰œ6a©›BÆ©Y?cj“%!õ±.=£í<ñµ¢…ô|‘¹ï|ù9±q¡e“ÿ„–M>G˄>êfÉ{é®­†3<%ϬôWœ¾#4³h]À†Æ×k،¥R6›#Ûåéµ_Zë#)¶P×/Ûþó­–NÑm€#)ŕøŒ÷:R¨pjŪ¡#*㣔º²Yx“´¾Ö°"”æZÞ¸j«TE  }?K|zÅ8úœŒFi¦mÖý×o÷öѽnQ'̉;G¢kTJÍö¸ÄGâ;/÷UEÇ^^:؟Ö#*%j‡”;s©!³p}Ð=ï®BKRµ#¯äT~•Êú9×·¡æè~Ý&žJö 4ƒÃ¥ËAÓ¾ô³–­¥­7Ü¡^ÎÝjKwH#*†kª><ÿ§‘ †ÕÕèD4â=©Lª5DÙµ€„-b#4ó)–0h“[–\õ¼îÆ\µÔ-ó4ù<MÝÉ°¥,˜€»ûGZ¬R£~An¯æÇ$îKø­D+jÑBDì¢ÕuD+¨RŠýÝ<·‡cÅR7,„åÖçÿ”Y«äLžÓós1#*÷Úß&À»Wëj4•ú¡q7å«Ñútæ	ðU‚¶ÙQš{!i”š©‘悱|Z*xèk@Þ¦Õåðì%†Eû£¼‰‘Š2ìú`8¾¡Êyü;¶#žE‘vICe“™ÊWëüßÙþÐÎn~üÿï¾}’ÇÿyúÝ·_íÿ¿üù¥#*ïë0çYù˖¬öf~ßvrzœÊþãuŽÜØÐÆs^Ÿ‰¤ðtt/l‹°áÙí#4¼Ûi¨a…¶Os¸=*¦ê£×r›uò—>ڏȘ–Æÿ0ž›á¤ûŒûÀ=ëÿñ·6rëÿ鷏]ÿ_Âú÷Á?ʐÀÊÀAŠ¾@ÐÊĒIÔ2Ìá–õaþ=Ÿ=~„·^òꇗkkÈÅ!4#ü‚k±ñ#*ß% ÛK€I›¨vo†á³~džz´€ù›Î©XåïuFºƒOÃÀŽ¦Ü÷fªÈªÏav±ù³ú¾L‹¥4YÈEH‹‹µ¤’&~ Nâm7²‚ïù°#*ĤÈn§‘c¦(ôÎ<ÊÑ0Ëzxý²ûyìÖD¶>áXÇ7l]›–™ã¾”~Õ&-—/´ÄkA9nŽÐ>j0¹ù}FWõUK:dÎ-Mù—_Ùîv}èfü’}\o»a´"ì»-·‡˜æ´ÄM¥BíC{<	`OËXPKA#4åÛóJ±:j;ʃC®ÚŸêÀ9:VšÍeVyLÚY:"„ˆšÊ–"K`è{Ilu¿l‘cš×˜uØ|¯_[Œ#i£Q!ð	¹‰E‚â2‹_ìD&¦T?	Zö&9³Òh”©´šJjbgiÐô€|#<Mô»8wK'¦™a-ìn÷ï±­p¾ó f8¢ig‰­Ýº§#”©¡5õ)%Ã妅´©ÖM*Äâ¦Ú’DP`¸qÅïõè_%€I4V³f¸Zh5cz¯—êŠÖ¼,d3/Ó$8°‹¥N³/þÎãÿúÓö€ÿº¹¹ùÝWü×/ÿտݕ"²i\8_F³V‰gák¡,$ë„#4»Ès¨M‘¤¹"/Ùå*!äŒÀ)E¼ÚÞÝ?!×â~ÏPãKŒmJ,e?^ÓnâÙ¬Ð#ècŠW:€*í|Ö³`}XûvcÔίÊÇû‡ÿ¾ÜJ'²ñ$ÿêÇ÷¿ÿóß±ûߏÿ½ù]ÿ{óÉ×ûÿ³ÿë­Žr÷9ŒS 8‹Iê,10)K-Á—ÿ&ÅÔõґ¤Óº‚øHÑ[ž¤#WA>òêȃØ©}ŸBÕûúΕì äoÿâ÷Ž5ñà1‰@i-Lø–ÿÂ`¾%?)ñŽ‡ˆÂ!#45ÅÃ/ê\ÈF¢†mj¦+üÌ:íAbG¸ŽŸ¦ýæÔ©sŒt,ÑêZqí,Vº®²•¬VÔÚ#)˜o˜^º¿m€[6:ßÜ~ºöÃ¥4¡ò“ŸWåTù$—ä,΢2†z§NgLÅAN.ksk~ ãÀ*Cf8h¸ÄÖ°Á$.Ó~"]°¯GïàùBÀÏ*ú_èþ·ñ$ÿ{òø»¯þ¿¿ û_…ÿ§Ùìý?ÍfîÚ2›Uº€By7»#)A¡`…¨Ù¬Ê#*”8Çý8?PPµÏä	Š^%ž  bŽ'(ˆ-sÁ_½C|áûÿE§…×ï¼ÿ?~ôx£°ÿ?úêÿïKyÿ…+GëdïÅÞëdee¥öÃÖÿýµ®<k¾Íü5‚ ä×?ÁßH€ßfkôöÝZ+ú¡ñýJجÕ×~ˆj?$•ðY3˜ž£H” sfk¿Âúõ 揁ÚþáÙÉþáéþNôomET<”DD_í–…àW@÷ø}|r´³·ûêd/ú#*åŒST×F±¶ƒbÜ'»Ùi–ê¶Á.A©¶ö’BfaÆíAk7€t\c=L£5ۂzô&­–ÁKg¤/§ìia¶ø“á¥Õ7+z7HÌ.…Žµn:Ê©Ò.Mf6¸D#*QzXƒ|BZ/¿ •™Óa„ãŠ4U!/?ò`€A¥B;cìY¨7z±Å{dj°oŒ‘vÇjàÞÔùåk“)7”;'7Öj^n¨ëœÜؒòÜ,*¨aåb,Q3A¦—Ý\ÏQo¿k÷&°èبû‡Q¶t+¥‹©œ„òֆ³cêM`ZºR}ù…ùµ@;¤Æ°ß>Æar#ÌΤ‚½›d¾š)ëiï¨öÏ1M4îQ“wÇßV³•Õ™RØ÷€ó#)TôܳԱŠ:,¬ßN<øM¢nÆ­Òøë†La´ŒòÀ–a–”Àà`ºAN#*ڒ² ×JWK2P¤²@4³£mžÂ¥åŽª	bëWɯœÙÀÿáé<Å=ßÌ?8ŸÿÛ¾ïi^ÿïéWÿÏ_ÿ7Ìâ쪟Îâì.[@ã7öü{åP¹ªéA<‡ÅG¬¸r¯Î!.€þ°s-Úm“+äBp<€@àFNwNöÏZg{/ÑÚYBèÉÕw_d•š³é¹X€Ä¶°sÓ#*H£1ô)‚þ#*§P“Á•]Hñ)@C‹à²{¾µü'Nßá+Œƒp½=¾ÌÂf°@Ä2ŽCûèñ2Û6A€+³Þi÷ûXV 8üèúc•¼yŒ¡JWi¿Ÿ(#J‹Þ4¢e¨n=!hŽ–‘9-B»jº}`Žò‡Î­ëôŽDP–÷tá±{‡è¢Gtî<#4Îo°Þ”ÊLªüß`êy+ço†r8­rÒÊ:ãÞhb``(mo#)³pŒ¾Ö¤‚‘¯‘Ï^Vchû¡“ôÅ3)[ãȁyÕÎ\	6ý¿k¶M"ázÁMO°AYi)‡#*mO1šü0Ä9ßZb^/­YÌÄWð[†	˜ÕÜÐЋÂÅ×L‰ÅXI·ˆ²–ÊÎ"D÷R5Ž)9Tˆ*5ô£ž=k@ƒ×̇„3â"-`ô¤år*+L§=©d¢ûý#)!¡`àÍé-ˆÕ€O‡í;iÉuʂ:‚ÜùÁbHÙÞÕjé65§4Af~ÿ{¸vßFгŒœý\њ"MÜkÄ/=9Y€²ZX¬·n©Þ&·¥éÆu3q‘¢»»v›_pmQGKÒ[†¥ÀLyü[³}Þì*ÇR)‹vB‡äabî]{œ­t±aTn‰UMî²9Ê;©°½`4Ožb"_°ô¢}@´ùˆ¬®j.>šÁ‡ðü”å,@ïbqP[#)v—º›kÄ]	j¯g=mz[\˜“$çXsÁÕ½‡:*,ÕΤd¹ZÇVT#*2®:$f‹G¯NkL+Ñ#ÃPV3#½¬EÆai2¸pd¼dܧ•Ÿ$Ö¾Á'³ûæ`íçO¶OÞ´,M• ,ڎÚÜdUL‡ß‰`—plF1Ÿ·8Ì!¢¡–¶B¸þNû‘-M¦#,F¹ÍY™NP±|…¢|»ì©ÎoͲ)Ù|³l/cҀ,MŸ2.•O¦^È,%V´*µIE$|”¶A†uý–h§M¶›Ó	hÞc?¯6ÀÂ8#*†ì×”ö¿äÜk¯VT]ñì“/U&N4Ã)Vք*UñêròêÐVÅóxE{v7,än@ÎC/·î5Z¾N±6MtOWvúi{ܺh³vn‰UDò®îfn46›NÓ÷_‡‹¦•õ.gcÚ>§)Â¥4PïÂ[´ÚiŸm¡7ºÅn±ÔôN9K;I•/:‰GÎβÛ8±y¹½¢„ŠÞ)¨!æºÅԄn¡ÂÁpšUk`¤z©¬¿4í°Í¦¬r膗,ëÑM;ñŸŽÙÔoˆ÷L‹îÎeç·0¶DÉ]WW߇|Q#*·ø–—v¦\jqˆږÅpµ3?‚I|Ėîªœu…ØÑ[ðÏU6Þô“ª\qZ ʲ…;y7¶ô¢¦²Çª‘8Í"07/‘óiěԭpø³ôÙ&/x#4ë#*.†µð]£ñm›€r±à	Ü£Úƒ–8ÚHYN‡Qf.×ǼG7æ¢;MÕ3;ס٤›ŽÇ%d÷÷0u´*"Ëní|i_ZªqV!%¤G‡Óv‡°¶µÈ=”l	œ&I­jÌb¢Æ³G$ö³:œÔ۝M{c.Î0‹åûCá°æspé¢7€›sZ²ãöBösa¶g#uÐ;ó¼æqœk óˆ‚Ï1…¥:¾«Á.iܲj‡Þé2¨8²ûšc£Ñ¸7@[3iCO	¸¾ÐnJhÏ4NÚýKÉkàOY ]­ä²w“ý[x¼8ÙÛÃ’#4dÁ䪍EáÜ_í>\톫5*eHÇôÛ`›×`ÜËǎ‹Ò¢ûŽE%ª(3 aÃEE­ÐÝ*µ(ِ?OövóUÅxWՏ­dEM9¶zu¥Y´‘|ÔØέ†®ÅMvɗ'qa)ïz™}6	yµl­f„ª9D0­A#4÷$g#)U-$qk(ÈÙ($K)ax‘„–SÂCŸí]j>݀nTjfè[¢1Læ>ÚB€3ÄšŒ§©³ê£3HÌúö`êÃd#4pŸ	$/Yí9ö0*+þ§”ÙJŠrü_iYÄ]­3wµxyχãNp.U&JqáXڗmÿJgÞ»IMUJ8¹Ò:ÙKŽW|M˜¦MË;™ŠÏ W§)I1¿×Q¨dž¥³öÍο[d²rÛî_ŽÆk}ìz×qݱ	+jÅ´p:€)˜ÄåÍ@…¯[eÑþÝ!AŒ¼GVÞ90ZŽno”‹ÜÐ×Wď|ÿC؀wŸßhþûߣǏŸô7¾Úÿ|AïÀõ«‚˜·rpÐ	^à!уÄóžï})¤vÑ#^wšä÷§îlŸž#4èÚß·ÞfcÄ®8=zu²ƒÊZIøàÁÃuBêXþûö‰#*ۉ›µ.]†Ë£éy¿×	X®C˜÷ËKˆ"øs;ìuƒèïÚ)íïfÐ_ÞF˜ri‡MD{çeÆ¥†Quà7/'WÁ÷Á&§Z:½Ë&é#*B:ԉ¡êj+/åq	rLir%ú«NŠ¯„ß}Ga˜ÝgR8”I@åÖ¡·Q&Œ…"Ê?%:è³ ¨Q’Ãáä9ªì‘#)ÙåtN•Ê³”TlÓ֋«3˜öû¢Ól`šË–±ŸÝkê‚ø‰üHYìm„¯oè,YL‘Bþ³=&Í¡0Œi(	]94„üU‡Ïq§ÛÓOÈѺa$̒÷L #AÌ*0’˜ËCà@ýðÄ!åਗGHÂîÍo^ÀSÂU×½žähH© /ª³šúÖo®á_ëÇS2ðÜuôêý™H…vH)h°X´ü5nj¦ur)]ìw†,tÏyB¢¨\Ï‘ÿÕ0µ9/ê¼`´wä_Ú¹¡Í#[bWyè³wêmÛ±ù#4ð•@Y‘ý»ö‘i[ÍÚãèò0s¨šüºäÜV">,¾/I!¦ä͋!ѵÃ~cÍᬩmØ͋xf.éL&’Û´ÿFà–F(špýnÒ¨èC‰Î‚"j/w[¹£^OJýЏŷ¡Æ{ƒ'žóõiæ\q ÆqIRםMëm:ûÈ^cÜÊٌÛ®÷ÌKRdÝdóªrX·æÚÜh~¢ÿ܏qƒk1~Ë^绉ķ³ûBÞë×ÑyÉödàw°5æ§ä"ê]ÝDêWÈxsnǪ£xÂ"½+9õåñŽDø™vûTIÑ„+#)¯B‚¨’ùT9Oª<&Ñ(ê¹£°o퉥_ës[ŠI’I/úUÕÕ¯$’sª,ÒÒ{36æ2d#4+ÞÙy›$ÞÓ°î®ñ=U씅8œþ#4Ä/	×óÞç8Xê\£%øCÈN~b	)×M{лH•<Œ™`Ë< boñДPÍbHP9Á‹šSä?SÂ|VCR©MwN>ûô¬*µÀi)©ƒ,çËԜaYþc<Ÿû·8@ÓµXˆä¸âI˜Ï7aTڛ†R¾'çú4™¼#*r˜˜¿ƒùN3.´LãuÐõ—­›é+:è*=#)ʤD_1ˆ§¶ïM]ë2¥v :̬“\‡ÙU•ë3åhÒ$qdMHٜrþ9×3¶¦g&²oË©¡ËÂ(3¿å¯]ÖV&¼¾£»	•ÔžsË|Fò­fø¸ŠŸ&’È‹Ø9ÙCeWÛÅ%[·;ƒr¡"åΫè¾mÔnk’ß¿(†ÄÛtœ›˜útÔÅg>ጥ×ßQRôŒ@ïÝ-¸““›	ó:-–=øJ4àò¿6 Õá+ˆaôæVXüúß#*ƒÄÔª#)㙲‰¥–ýk:„½íŽ!µg…„bÎaZç6×Úßsj.üå!…ÀLFL;¡?88,™ýÂßËG—á÷H_½NE$úYPŸCõö`ÒºìÏk,GŠÙ!‹Ó#¼mb“ôº5íÛ	¥0M¥–g…(RãrW¿åœ´À¤#4ã­Ránj.셁ýñàÕ^~\&„3Ëù!ЋaÚ ¼ß,Cà¡6W+…ƒfðiÊåwò™Œq¸5í©hºQó­#4ø…;B«瞾󢌢ê%ßÙµŸr¸àß'¤[ËÚÃøQùÄÞÜmzÚómã­#A͍½¦—ŸÁš¨áf®[Iª?ÝK¦̞j•²re­‚ߓ☙z°—FZ6»u+ò8OêV¤¢ž8¥«åPÏb®²Ý¹"Z¹›ZwØ©öð>žöÍmB¸RÉb›\-3cÂtˆ;iã¼»–ÈAÞ֨ݹn_¦INV’¤”Yóò֕ÁS¸Sº”+É¡7ì—2•IÙrØ86±Ö>öV³-¯­?ƒßÌFxÿN ²Å\h¾ŠEÕ<«]Dš‡øʟ§šÿvå*†å–Îå¨KMÝåt´ÄIeie‘µDëJ»Ð2Úî2·p)nÖy×p“«Ai¸ºÎÛøÈ#¿²Âi¼hÖþog¬jh}æàn,›’?±™Wþy{÷h‡6#•°®Ý£ª1Î)8ú™µøO:¹$•ZŒög±é¹,»,ÌGWTÑ-S>åJԔšåût]«#*k°?¼Ä“‰4æÞuc±xÁÉRjü¯i¸ìÊ­Y™Uw¢ÚœÃ(·Ÿ[“¢ßm£öLK°Î-·ÅR ÁŠüÍ2c½Ô{Č´~:z¹§¹"#*¾ê#*Ïå’_–#ьC„ƒ‹šk6§–ºÙ„Â۔QP|¤Í™s³«†{Ûa¤Íà#4ƒwD>ÙW€­;±uüYI˵0ϯ«ËÖ´'#*]l]uøâŽUîeÁ8%Æ.Mó›6áæS“ì‰<:À)a?äi±%G˔©é{6Ê/8Äp ¾ï4~!¦®!#4rßä«ï`êÐ\Ç1Šùyñ]ûb݄ °M®’ùŽÉl/nUí´kÅ´ù·4¿n֌¬œœŸØÒ¨o&ã4­©ŠÆ‚ÑyùIQÅE˾’±·*4#*Ræ‡ù(.¾Å[IzAïÛ¬“µÆBě¢ÉkÔÓñ|ñ­án>RÛ8gÝ›W<|`k]A¦þÆ¯ñ$ôžˆ¯Â¤2ì•NiŠ>"Ü¥çB7»,ÜC´À€GNé‹3xÐԋ̢¦YT¶¶CXk„¼êG#4[Þ¹bœmçEã¢7†#ªvÙéÄÁåÚZÔë‘Z¾–žÝÏò³tØHzʃ«oFJAêœp²î¶ýÓð&MŠTáÒ#*[O¼8g£8YKS¯…ÅO¬ÔoÚ°Ÿàj&¡åÇѪ×þÄ]]NN·Øµ¶;L3¹âAk'Ãà¡d&è3vê>)4_$…kQ#*FöW]˜‹õ+*pÐÙíém4o—ç^S?²‡ÊË~ðÏۛz-þÚí÷%‡¸4Üðw#4Ç#*3†Í9Ô#*Q„SÙb&ޘÅwúMíçÓÖIìŸG¶yâû1IÂXPçY7ôÜ»äžÀ,Üm»ý‹° ”W¯®*t+ï؅Ö`×_‹5S`È`¸bv@,a?mÿ¼×úûá~ë'rx‰noèÝØ:7–!Žå=ô<“k&²YþÒÂPOô$¶ V<˜óA[îBÅ8ž#* ^Ø\ôm³Uø®:ìŽQ¸*}ðU1´\ÿQ}~ø×{ñßKðÿ=yòUÿóKÃgYóÈ°#4›)DØ[{,ËÕIÊ XwPÆÛ!_jVöMÞ6Ս¶ÓAND6	oɏ޻VéàŞl§ÓeU€ÉêÐMÀÌÂÂ<-®S…P©]s³<,lY³™6a¢“4ƒ¿­£Iô·Ž®¯½{¬3ؽûJ(¯°HëŽj΃%ӄ9/¾*1ÐÎCà®29ô]€Ëz &]¥Ó˜ê:åö)‡ýҏׯb¡pÕ!îÇîœ|½Ž"ïâXߖ¢œWh4t?Û;9LB¡ÍçsÒl:öÁŒL)F½ÎãGØÍ»Çû;Ü%î×É_p¤	reÀÇjVφa1ïDòšjZ#4“#4íû‹³<h±‚!Ϊ`ˆ¿#*ÿ÷á¿?nÝÏÊÜwþ?ÝÈÛ<ÝxòÿíKÁÿ­„mC«Îå®v⪖^vñ”ê¢Ý[Øïvý>>K»s=–vÿh¥ÝßÓ[i÷w÷Uºûç©T£7¸Ž¹ÏYéîb®Jw«•îþánJw?““Òîos?Ú]Àùhw1×£»éx4̯¹ð¿Ðí¨þ·DZòy%#)óÏ8ýŸîÿO67¾žÿÿûïÿ­ÖÅ5XZ-sòÓS^[R¦++ÑqÊ@±eìxÇ#4ëU róULGO\gži¨‡-+º5ˆ~Ù~ÞÚ9:|¾ÿ¢õl#4¼‚®Âe¸ÍþcïÍiŠõ:½ÑÙŠ¼”CO÷[{/ÏÞ´ŽOŽ^œl¿$‹ÏÞ`Â֜ø£=¾ìÄAç#4fëƒÖª³†&ŸÆý5°¿oÿj_\6þ*V/·wNŽZgG-”-3Õj‘›úV+܇õ1„½8|E!èZ¿ŸÓôÇÓ]#43Âh?L'&xNLèÑ(˜`„Ç1á(Àد÷øÍ~íÙ½=Å_öà³7îÑçöþkøjóGkç͋_ö‰dçî!ë0ôåé›Ó\Ø+HSù„¯§ßÂ7åI#)üP­½ÃŸ÷OŽ_îžÁå~§utÚzÝúyïätÿè°õ#4=Ùû?¯öOö¸A˜—ϸüÓÑáæ]$çÿ9|MAÿpëp¤Ý+ØïÁ|çîlwúáÀZ;ǯhÈfÿó´õô[JÇ?‰Hû¦[ì=†ßÆmIÔkÓ÷Mo”Ñ7þàaµÇ#4¢_L»?ºjSýâ0ôb Ää7…O®¦7çJ¿8íø†ÓodèGLPÈhø.¸\ùÍá%a°¼nSž³ü“[òô®¹%ðƒ[òø/œŒ~Ù0Ä!Wü}E_ä’ëÆ?Ãøƒ’¬‘“PÐK;)"ëgÒg!ÎâÑAZ,~Xàú{3ûþÀ‰©q¢&(N¢c­Eã# ú¹Ž‰â#+©a†o߆ôÔñ]ƒàÀ„G¨Äûö­KˆbéÌàŸá¿\ÎKÿr’ú»«p5£6¶y)£ïL9ƒ‹-Y5ÅÌò죻Šµ{Ú£!\Þ¶ûF›-g¶šµÈJSqþˆRÛüÓ*æu¬š‚žeq!¸>3TôrÎ0 9³ÆÖ#TnâÏG[MV{…”_¢›gúùp?Ôê³C‚L½%ªx(mNÃx8±ÈL²ÇtÈTy»ÌMÉ#*,±è$C’ÈŠÄÑ+’»P˚ç¸,	o²ÛNH ‚TûÝ0Z´úp=aimIåû‹uÂhã,	I¸ö.jzÕÐܧ_¡GaS4g,–{ð	å²ѽeS2;rÅ#4øv%ǖôçg+qW¸QV .mÕ+*²žMºI®vŽÀ~±¶†ÛÀŒºdFåzyVAz-Œä®SsÎq¸~mü;êuä{O¾S©‰7ge³WZÑv¨«‚Ã}1nߤï†ãëpË­)ëv5T«¦ªwž»#4鬬ùOËÜ/ßƤZ‰M7!'¡kՉµ¤•¢ë}„Z‚LZ=ND'Öýsbjñ®EI®ÒLOçg³6QYÎÍͲV›§ÓnóÍz”¼‘Ê1”ËhžQlN ³Ê\Q_=ÓÆ&;ª9ø3ª|¦hbÿ†æ"þ£á?—0:3=Ëêz>Eø폮biáÐk|Ai‚P_–í¾Š.¨YI4$ÜËî2¼ÆÊ¿ùp)ÔD:hWÝ5u¨#§‡Uð/)ãàüéXì«LٝŠŽ[øjÀ çÝ#)y127šéP²¹$‡Ú—âvâS)iù¦wýn+gº‚gãñ?^ð]Εë;]_®óO|‡Ú¤Ðrý®Á%4“"M`9€kOÂrÒJLȼär­¢µZx3ìÂDçTX%󛄠MÙTëgä˜ÄJ+µ;“þ]#)l"Š¶*‹ŒWéÖI)ÁÍ4›ˆ–—Ó’váRwÝ}M¡>ÄÁ|ÍÄ躎Lž%4š˜£šrS&X¡“æ–¶:6¥0}•¹©gZu~`!ypyš®W†×¶_Œ~biå0;§êw)¾…t<öºSJX¡EӒ2,Òé¬AUÙKRªæÇs]èE5“’JG,GBÇ4ñIÜ\ÃU~~aO•¬V,Y‰¤?ºÒ¾Y†?vÉ!Zæßq´pk*_Zo·±Þ­¿‘Ò\Yq琠Ý?”u͘ëwôø„[‘l[G64q-²d]‡hMøˆoJ#*Ü»ŒèŠÕâi¤ótÅÊQ:ÁÈ°µv`¡¸"¦¢¨6ÙîKo…ñ¦2““T™ãM‡×í#)%—;£1‚7¼â(Ä+«Y²¹²ª¨G~Íð¹€FFœ³èºa©¬ÍdsÑõ‡šÜ¤ÅÞ@,SN¿nÓ¯KúÄÔzÎfgíi<}£k:)'&«Ý”V ck¨rÅù¥Þ´%ՙ‘UFm|v©˜#*N,ûã\˜(±¤Sf›6'ÛZ­±Î?æJÌ°		8{hÎj8†‹ž™Þ	læ¹ÌXPï?ðs#*:¥žm0—öŒ£Ln͔J]7¥ÂðÑք@äD#4¦žúŠç`èq¡/ÛqøU²°³/îo(^È@.Œ€Ø°u˜ó™‰(áÈÑOL‚qËÕfkþþȵ4-UU½%'¦}´dL/cEÉ~ºHØjk¬[ìoLÎރÚýâüÄjãô´®Ý–NÇ%bČ §d¸åT䄈œ­@yjáŒ#*¬CÞLÍ-2µù‰©„¸¤Øònò…ƒüG¤mvgÇ/º,*y³	{¤<¸¶î¨^ÑgÝØüÚ¾´[¦‡ép‡ðq#/붇ìaFéäec|mGûžeçÙ³½vmé†Ù‰Ã7{G¿„¦&Xþޅ`‡mZŒy:N·ÈP%r–XgW©}Àægd|.ðØÛ¯Þ,!¬d6í 15lnä[–ß½†±Y}êúXöFäTO›ñőe…t%判ÔïÖ1·u%NRÙmAö`’lÜ!°…‘T™1’Œl¥v9rˆkò–%&Þ@—´ºˆfÂ¥ޞÌëøuLKŸsêÍ6“òa|MÖ`6qBZdÊ|Y•¢–‚1}J’gohÿô}’¬¬æ›Tv=Ôم•0LîFr8ÅáE/…á0ÓaWó·a¶è±_F_ùéÛ胘ŠÑ#4`ÿ|r„Ú÷™ÜLìow]€ýÄ¿+@€ºpvÓqï–|$ðf-	l~«°àßYìðz´mb`âQãU×Y)2eg¿flÆÈCՙÍDR 1JLëlYµØ_µí ³¶¦ô‹œ!e˜W¯ñ‰í”Òª¤ä÷úêNK»c\WPk#4`Ÿöü7=JøA8ù%©Œ$Ü!ùžråPoIõpnúÕ¢L&#4—¶8š¡L}d¨Š‘"®¤`ïwdÁg«ç¶€¤Q¬nìªT¸UÏÏÙt›p.q‘›p‘Ł³Péà¹í‰÷¥z'\«ÕJºû±DÃÑ(V+4^º‡ÆAw·3‘= ߣc\»åjÎÞ¼ÔMå©3õÀFø'Q¾_͞!Š„2´MÇ,‡,°’ðÜåõâݵ½ŸåÒ4?åJ-ô#4Wg;}¦{díCdÌ®fõ+`Í$,#*°¦ÉÍ@.­îpÒº2ÀQHþkl­ÓóqŠ&½îIáZ{=œdÔ×@±¹\-í±}Å.D¸¶fjÚWÛ"j),,µèŠ¥²r™B`î…^;/Y…ÙÄ/Ë9–‰b«Ý&¶8…TÜӛфœ0¹ó2qÓ…Eõ”O™<ýÏ+té³é'ô;ʑ?­¿!ç¸=¾³Ž”šŸ* £Ì®P1²·øĪɻ`¾†Lò“ë(Ù½Z„¾$ËåܖÙ5™l‚æÇ6‰Ù ¥MB—¹pÈË;Cq»ƒ—+Þ0ð,lÄ\°µU¬NÒÂKCñL3ÞÛ#4Úíš"WÚÄjÉpÆDMÛVBK¼©àº‹­/k¾IK®£r§™	lšg3ÚBUxñµRv@†®õÌkyS³Û$úPû$±t™@¨ZàÝ)á¯h¾•m5#4|¢!úsÍ\¶NÉÒÓÓ;;TšÑæ\s”<ëM#4W##45çC³$._'¼Œà•Ä @‘³2¡ÅÞµk‰m¿I@Et¹ÓÕ\@£­ÂÔ‡Ë÷SƦT	á*x4ïl܋¯@ŠÂ}t¶ãu†RPšRÚÃqyE/kI¥“ò‰+a¶ib#i4žôøH#ÆæN¸¤É{Drp“.UÍïF²ҀùɊqCчJ¿O;¨øò]Hv®ú¯XeÆp¥Bæ*ìürß+†¯”Ã+jôT“¸[øpBùcÓLù<8²h? œ„+«ÙJ¸êÊ¡8—ŸS¡O7—„-	øU×S™$ãäžç×ú‚Þ™Ñ)Ë]1ïI\èݪîœßm¿½æ¥]“ëÇhÁ—•Ä«ƒn2n©‹<ŠÑŠ¨,4¿sex1þ´qÝW‘:?‹æðë¶K¦ÐÔ/*aTúÅ}/ÇJ|—n<‹˜ê ¥‚‘»ÏÑÒ!î“ß¡H£‡ú翅祭»à¿ˆ{Ž(ýš”¸7š`Rr=вbûYr]ï£v®õ‘ Åa½t½¶øÈ-ˆË¡ 'Uœ}ß'öfáô§¹#4•¤n5SF©¨»hD¦|ºl›´9#4Ÿ!Å.‘UÛ¦©£ÙµÍ{D©©N#)iUÁß"%g(*ËÆÎsm^æǺÊ1ì8çnb^ZµCyÅKà!}ÚªFDœïä:¿·-Z‚‡÷5¿[B‰ÞÁûaÅI`˜Ye‚È ûÞ"jÞ ì¶`ç8Ù>yÓåÝ7Å0ú#=gßåJýòúH¡„«fáÄ`’O½0úÏ8ý>ÿo@W”Ö×¼R$x»M›–ޝ<,}ØÑä·LçüÜDÅWÊÙ¬°]—¿hïйª@´s?ÍE)¢c˳?&ïBéaÔxk¹ÉÜÒ`ö¬µsôM€NŒÜM&üuê—¦h@MÃâƒ~¨êuY]¯{ë#ËVڏIi•`“Bï¦&¼šm0ÌDaöQìoÕ0t6+úYð¦ánªéݖ§‘fE 9Ò€©¾ÉòRŽ°í±Ûy1ÅF.ë,^¾s¡ýa›ñ™¹¨ƒ&¡Æqtߎm2X#4I¶jZQŽóö  µ0K–\/Ÿ*+_çÚSº‘Álo ÊYDÖfÀC™%˜f¾™¬‰—xp-(14¤™a؞âäÑóYÍ#)+ÈOúOôBÿ5JD0¦/¡Q辦j®‰ôÑ)Í¿£ôÍ[Ÿglåµ  ×fÉ-Л#*N\£Æ¤¤îÀ&‹ò¸·?H]á+ÈI	\½‘ª¢¹ܸ -	ù`©dÙNöÖpÖÀ#4mښûï*ª¯¯º¦âzÄKXˆÀ¿à–M¿a7‰ªµZqFºBHå"'dà^#4"+a_NÛã.þ˜GÖÝ7Íxk–÷‰#esŸ0§ÊE)PÛ0//¡•6—Oÿb36¶ Uµò®£†NuP+jN#k°ø	€Ûs̨<tQŽœK¤a­¿PÚ^‡œqúv¿F҃Ë4n ‹Êá#4N rÀô®ÑçiЇkÐ7Áƒ‡oI™Y«ùý©wàûÿÄí3Pþ¶[bû+Š¼Üb^83f¹ò¾rC¨ü…áƒ6®f\ãUWü²VãqBptþQ}^¹|}çù‹Öóýƒ½Ó¸á;Ùq0O)ãW©– ËvÛT~‹Ô~©#Í&õÁ«‹½D‹`Î/›×Ž_ãSë¹Ü:>ÙC˜2çܴ⁔ËÞ*xdÉ¿Bäfÿö »Ü(‚ñ9ïûç¤)e›ÙR;nÅçÉ5Î÷IÑL¾Þ#)F»™œ—‘ðG¥Ó&„ÄNÊüYh®K’P@i$Whg\¸*ažc¢ÉNE·@V3úÇÉÅzð:Æ#4_7c¡)‡CÿHïœï+&eþi*ë#4/%©i©Þ#4VV°òv°âւ¾@tΜuGÐ1™Ä„;ÇÇbŠÔŽDwIÂb2Uš‡v÷YŠ³FX¥æ€ô攨Œ­î)ò`wn;æ¯#4¿[=ä'ƒr|?—Ãu#4;a¾×ÒQ+(¿‹)(N;ø²c¬þ{öW§‡RbÅh"À¸¡Ý—hœG6²xámÞVÒ3ýµ·í8þWÞ,@ÜßlÄ$)àwQ‚rIk‘’I,†Pê|}uÓI:¾Á¥>!1Ÿ(ÑÃ-ñ!à<;ìt„!ƒÊõ\-lµöÏöZÀ*Œž%mK‰ᖗö]	°æQY=Ðq mœ`jâ/_í´Zaôý1:Šºã#4åÝÛ>Rei}§S o¡K8D_FÎÃ^gÔBT¡ûª™§AÑéßµ5#*[?Ÿ˜try›	1:ô!jÃAÿ.ØÁŒQÐñ\]—`°ÒË­`g'´ßþO€˜¯~â Á°R×t´IgÁ´½ä?T™¹è½‘°d"³oø…GD›CÕ@Rl– UÐȓjìêωúDz‡WÃÆfÓ>â'ë‹-]³”…5þù´‹òBïvÀ¢ËàÚi´•íÅÍõï¨þ=̞ÃØ1rd,°mùHm†B.O£×ô°Ûôë#ҁÑÝ>>>ØÃÑå[…•Ÿ0¨¢@c_ß$0„³yÙHÙ3Z¿’iïà¹Íãgùqÿðù˳$†#\öKúeÿðð³‘‡‚,®c„žy¤a=*u_›fÿåñÁþ»û'¹–Øp·¥ò·WB>	ÆItl·Ï©ÝM»³>«&§ªÎÎ'bËÁÙ;¶Î{ƒ‹›I-?,Qå”C” û'B	²åçlH‚[äÆ60ãV®YDˆ)¡1kÂeñ‡Ð©ÓK¥ñÀ5Õ|AÁaÔ4OÑ=>8Ð`-¹n÷צ×s;;Æ 4©AREk²†ý»ÙŒÊWÝÕ#4Ⱋö?‡ã’¡£ªùɛ±ì#*ŠpµêÀvv›ö1&÷*P]ŒlBŠ¾^îp?SKøñöÙÎO{?Cµ 7´ùÐuŽe™õ<‹Ï“üK™ú~Ûñ	¬CP!ÅDû°ÚxeÿǗÁëƒ`çáÎÛµ·kõÁϵŽ¿§~ö¶û z[§oìrú^‰#eóاÉ8­Ëy^»ác?ªg)B"@²•Ä%®A;ðĂvʜ¤¬£˜Ðï:!RÒX´<g쨊<pT;ô9¾,ª¸‘×;†Ñª˜Ï|ÙXþüÙQÙta=kWíŒÞÙÒ8ä‰Fšl´ªTT6éå²`¨‰€˜37¨‰jv‘Ö™,.ph}ekíê¥	5ý¨9rÉS>aÆ°÷mµl2íö†õ?üú6[‹~¨AàG­ƒSò×Nôkí—áøúôj8‚Ѓ!E?`¢¹³5ÌMÈÂ|tÖ±z.–Oŏš‰3y#)J§ ^ÛYk¦ÝÔùÀÕÒ}À1g€1ÈÇ+gt֘(V<•½ŽßàÝ	ÁfÖÛÙ:×%4þ<;—“R××­VoЛˆOý’¸d“ÖËӘY¹Fû†žz0·ÚwÇ ‹x”žÍwÆ;[ȯ?yuØz¹Wâ¤Øó|ºÿ¢u¸ Á{—~D^ ±§]“BÌhqz°3R–5Ò¿;C¸ÚÍ&µÉpÔ²þŒÕ¢•>â.ä¢Ejì»;¦·ñögAA4T“/‚J%¤t†Ÿ°Ï]Ò`áã5ý–ˆ›iÒã—eœ+”˜eSj¶¶Â/Tš‡5áY\!|"¯Y{=2¹npÒfŒ5Á#)Q-Î.I4&mÁÚ/Åz7*Nq(2ÇBpQª!¨4€šwaSkCg6—We£W%îc{K~CGôQQĄ#*ºÝï›4EBóªUåþI¦Û¦8#)eÆnš¹ÕéE±%–è/ÛA#‚ø”èW¨jõ‡k¥¡‘C"·äDƒ,2ê­¢ôˆ‹2I¨N‡Gg-Xuڃµ´MZAŸ¹ú}Â{ªH”_}ªß0ÕÓW;;{§§•Tmsód0„™’/Á©×ÞGÇÌETÝ:/Nöö½íßõ`¹JžÖ¾Óó~?QŸ|µ›SÃþÉÂU¼ã_GVL«ÙGq‘vGÕè¨äR—©bÜ£AÁgȨ=®#*Ïÿ™ŠÅ_áôP:¡×i:²hfb¦n\IJà_ÐÐ\=sŸ·Ç¨î ƅx;Š²°/HÙtij.÷ßGüz!#Ch¬”5²Ã£¥ßoqG›m€¶Ë›‘«'Èo+(]åÑ@ft;ä7þš¡2µño#”7l¢Y9ˆ[TTBêG²Ö=†ÌhÂ%@’>$ý¶'J1™ìåtM¥Ûô¦Å5Ôåè!õ(V{½ì½®6Ñtmkm&Ä6›ÉLã¸c…s¯`¾~ïL­˜ó’¥¦oÑ藑֠ïTQ(Rç:Äʑ^Àñ:҂XGàXüºFîØ-—€{îͅjÉ#4a¿C%g¹*a“ŠÐZØs'£—rÂ`e5XŠÁùG^ÜÇÃî´>JÇ»~ÜÃ,Nû8ËÞ·õ†ñÏáy&“:·ÉJ‚«„#*¨~#)äð£~ÞCVN!|Ø=›¶1Ö±ñžV‹Ê¦ˆ™–u˜ŒŒQ7®_ô§ìÞ"·!†ëÏÌنû u lP[ã™sÄzÆs¨Â´¢ã,Æ=¿E›«SaõP2fuIiÕli jꆱhϞìíÊYÁC»’˜~L–£íA@Õ1ÞPÅX1°s•çEöŸ<ÄL”ÑNOxŒØÑê§ƒ	nƒÅ>%½>iÂ	 ÄXŸºbs¬‰®1hSà–h9çÎUV16ÊÕ«^öÈôTNºT½9„Y¯C}’U¶°ä¸§Øj®€r`¡ðÁïˆa#)qŒhÕã=\Ú¶ð`åu0á#4׶šO"4G½K¹ö“š¾Íɕ•DŸ}«u¤l"ë	ïºH©y‡ûÎN©;9âšLSÐWËÒLÝ$¤·kò®®Ö5ÅùûSú£È;óÏwéúž]f"#4²Ü0ð°Ï+ÚÇØÖÅüøƒíÝ¥ VhýÂÌ÷ÿñopþ¹€ÿ¯Ç›9ÿß>yôô«ÿ/Íÿ§¸ã -}ŽPÔÁ“³˜¤Î/&¥UPÑì]~/ÿMŠa4›†õÎh„ˆ´ý;CõúMÏ­FÕà#4ZǛJ%œj` µåExصy¢FɗÅȶN’S#*ºÀÅØØÑú	τʸfn&sã¡)M#üšÍ|Á²cÀ'áŸßþø!øóûí“t¹…ñÛè—àoy”ÚºñÜÚ?ÜÁŸ”Ñ9òܒŸBš½ƒ~øó{øk‚hg† øë6}®#*z¹D;·*ÀìîŸÒ¾?›À5ÂêR™Áµ:±Ó£ŽŸ®€¯¹î0þL±T+W”*Z·¦^Åí©RQ÷Ó3'¦·îïOàŖ“öHj¿#*]ûáRšP#4ùÉÏ«rª|’Kòˆì%=(–‡¡€„ÌèÙîصüœ#49í`Ða[s£B,ƒËÀï±^Ä­¨©eÌ ªYöÕQègôÿÕ=Ÿfÿà¾óóQÞÿ×·OŸ~õÿõEžÿq™pßM.8óŒ£.¹ð×òßüXûH…S›JæãÛ#)Å¢Sz#ǹ;Ì3%¥#*)o?{t6ä …ÒÊmžŠ²Bh¬Ff³Ñ—Uö2	¡lR5ʪŠvv^»1fžE—`åŠpUB/¥ÚrR5…DlÒ©ï2>ÜV¨Èš¡©`Á0½³i.JH'ßâÈᚦ1‘—ß#4‘ê³µKS#4¶-f®èŸ:+þ·ð•	y‚HÈ°€÷ÇW§-:Š_´ÎŽŽPßûùþ넻`nʗG»{	ö‘œH…J”š!ÿxðj/ôÎFbSÓQ(éC°¾.#4î%±RcLD·Ý²$XUL ùĚЙ|T&»Jû}~ß¹Ïë·uy€­]—Ö®s—3FE¾ðð«ßîÿêóŸ7ÿÏÎÌ?ÿ¿Åÿòþ?}ûÝ×óÿKðÿ=Ìâì.+ãÄm'¹ð<ÄÞ8õ$6Äøó¸{»÷„ø|Â]ìùät>ǼZ®žAØ¿	vFýi†ÿ-cñãA°²³¼_f.¸8#*{Ýàø®µ?èMzí~ïÿ¥ì²ó¯.ê9>¨«ˆÒ½{܃.¿_‚ ÊA(Dù5‰L˜­‡ä‰îžž±wR{,»ŸV#4’ û¶±ÙŒûñH<†~ŠDÒ»û§g¯ÎöN[û/D „ñéö²É”^o —xŽ‘:(c2|ò¥ožÉ-†K¼—[rÐ	£;až$ù d¦Úï“oŒÄg˜tTÃüæì§#¾ýF|ÅÅhlNENŒ’7‘¢»pÔìA~©xZ&õCaeýÒrLšOêø(×6Ê£?HCN9T v™¾å›oS'‘ÆÇ7Q,ÛgB(2çQ!þÓ0gO.&£0g†Òè¤Fö}BœC¼:;Â{öxÓÖÁ´àñ#fyþ¦e~v Íd¶²=ñÑé_¼!Ž¢³+¿_Ý­„NN'–§žB7;ݼ§Øì ;D“aR {cE<pç]7)ЏÇiŸ}ÌNƽÎubô~|x¡ß\vy)eö™Çovò¾5FwÆ:F¥:*¦êTwîè®+ϾÙô<›|Um…P‰WšÑkœXO®ˆD­@Ô輋íÈÏQ~úô#*y¤îëÂñU¦´D¡éö»iØàÃ#íŸÈ(v‰0‰.þjl­?nr[†çÿL´ÍµµÕVÚè¤÷®Ó†UŠ:ó*Z]§ÿCØϫT•fÜ *§`Ö­ûÔÖC]îVˆrJöžå÷Dˆã{!0÷@ìCø¯d²˜I´Àj0DPW2|‚‘¿ ¨LZ¥X¾VDÕèî^H«Þµæ‘»•; §¶™›eܕ“Y½ßž:W<\QT¦ÏyÓM…ùlµÚ¥I¸Þ	cäâ*˜¢8WÁ|ôbSc°ÍB5ð(tûcߕ'#i{ëèøì?©Ÿ5—+,,CÚ—¸Ü[³‡:UŠHe\g2¨	*×Q>ï%ž¤­bj6ùŒ§`µ&+š;~³÷úÌÊä8‰Z¡O{ÊpZ­3Ø¡ç#44°9Û;9tLyÈ(ÆÜ´;ܜb5Ê«B.ªJéV„牮‚öƒQØیƅ¨lC¯õΧ“ÔW%ðø[;eñ݉eîŸj°ã²ÑE`Ð&÷b'֌ÑÉSÛ!$üÝB³ÑçöӛsRíÒÓƒ>×Ä{ùãÞîâSRç|ÿk¼hq‰ö3æ[PfËË$à-­¹.)e+ ²æÔ±‹óÂæó.fËK""d_ï’&²Á¶]¡²é#4lµ‰©ñS®ŒÆÈÖãnm5‹¢•U䀆Y˺1T¸ƒvÎwÓ~ÀiáË흣Ó׭ݽャ7¨ÉÛ:Û>y±wƏ”Ø	v”錣ŠnÀrW4¨B%µb^0†«1×#4.™i¯µ¨Á4í“bÝt0Í°¶Ìý/XáÁZï¢	áÊví>¨ºµöcÝgÖÝ%ObWí=1:ZVðédÆkҐ#)rJ°ôpn…j‘RÌÈý^TŪṓ$+á#4¡ÿ !&}EñD…+¡Š‚¯¨šrz‹:ÑÎq6j½¬Û»4:¤åùHÿ,²Ì¤Þ¹ÃÌåP«0õ³>ª}A_a)Ú×[f")Š)À_`@DRÆø›¡£Ìš§2à?§'†"'c¢l³È¼$h››4Õ¥ÕAà„1Á%ŒÃ8§Ü&“ÔTÝSs‹Jš/Çnyãg“Ï×t8i?²á¦Ùæ"ŸKç%W´²¡²õuÆC¸÷[1½Zbfœå”ÛR*ƒ¾jµRÚÃÈP9Eaôàօ€Z’‚ú`±t8MªRj;-±>0Š¦¡/\	øVèq¡€,h²àQ€">F§¥ä!q‚Dx˜’žðîWg¥n\3ç­ÓÀôl–ì	¹5¨ ':ì눇Š3ÝN#4҈Tã‘d-ØÒ^Ž+әÆ"{À†l½è8JX^·=\ƒ“«ñpzy”‹Æ³å¾Ë#4î$éßØq¢²Õ»Å9c`)˽|toxsé÷ì]ð'õˆ0H¹>¡ýšzEæU–eÕ´[Kÿ¶õ."²ÀÓ®8Y£x¥¬.6ž•ˆÍƒ¥‹ëà!,h!¸âÃ-+¯ÏÆpÖÊ}ôrÊ[ü"¨%ïæ¢7†Òk—N\®­Å{ö ØÌVºmÚ¦å€/Máþþc«P&Ú%CŒ»óÞ q--Š¸G#)· {B ™q|ãKïêÁéQ`æë™áŸãƒ`ÿpÑߎßàÈÞáö{­ÓŸ¶Oövƒ*¦IŠ!¸k|œ›Õ2—(	¥Š—2ôÿ	£"¤$Ú¯‡áŠvasÛtÌåɘ´›´_a…Ï݀ØÅáˆð…ÍTsúµõ[¢Ü…‹L𨾂=ÇGÒÀ£4a¯÷³ø.BoLøjðÿ€_¼§)ÚƧ§ž.,¬'zºXo±wΕÕ#*¤b¡±DòGóˆËwe@è,©æê^¯3dKœšÏšv]ÈђpZ3þµ9†p,¿NðŠ0˜Þ$a]êUœ¼2ª"jl=jFeê#*ãǏš­Á}ú.#*<쫙	Y…âL¨„­#à#4^Íntê&k^H­¹9¨ÌJl#*EçvZ/GÎKÞ§QlI'F½-[ZëìVš~t9°)ÎiðÙî*Éªý~cöhã;|õfìBEïºiA#4m0ðïHŽûy'ýœã5˜ø(Rt–ŠsL<ävvíޞ¤‡hâ›-U腫҆¾£˜„ …n‹ÅS6â³j'‰=¡b²Vd"n"¯˜Â±e/ß<wçÙ{,™9æ7*v¤BQ¼µ‰ã†ï/€'°Ò¯­qÃË(FÎÕõՖÄÆeE{öYGl6ù¼ã…w…FË0^èXam)Wײq¢¤×jîbÔ]?¡ßuŒ»µÌE#4?ØDè'Þ7þҜši³™=Æí~’æTý¤b˜cfKJëAM€ÎŠ=¡W¨»óaIÙã6Î;qX“mÙÖԜ÷ÍØÆI¬…7á¼ø¶ç‹[Bܜ@•éUËodfÎç"-®Ž9 Ñݟ€5¾ÃµÃßFÊyŠ°¸ð”¦‡H®PW*o(¥G=ŠºM¾¨2ô¼™;bßvÎw¿‰ÛB~CZÍ)“ªž(.*6·.*ڏÊíË6”HÀëvLäþÈÀŠ/ÐîãƒÒfc𧴸ßZ6„	ç:úcº0O'Vö¨˜jSa ógæ§BPýõûv•®{E‡©þ1/¶tPPgqÝaÕ® ³}D¯ÙVg1	WåõÞ"`ÿ¿BàЫ¶©äëú› ö®7xüè÷ï&][¯›T‰`Ô,ÙL¨ËÞé$N*ÐNÈ1ÆÝ©0åuêŸþ„3=8<:ž½:Üå^±@½¬E½0ÎDÙÉYRÅ×g; „úi\¼W½}¹vcS©7óÂÆ Æ7§Û^» ¸ÌÎÁSÌÞ'a–á5†à(9ìTjÓÈ'l“Qߗ%v^®ûIB˜Z[¥#槤pýb0\GÙg²Þî÷ڈAà\Vå&Þ£:¯©‘pôó«$f†Ÿ\)•Áj™ŽZ¹Én;+Ö¹žS+Äp+#4Í—§?ïH7äzè>M¾Io(^4RåÊzÖÏlÒ¤Åb½ð	$¬­c9#*¹ùµ²«ö8íšïGú#*sYØÞʅþ»vi1äCi÷‡àÇñð:5;«‰ –û‡àE:É]Ãwߔ ädN$¼éỳ}Aß$jžï}ˆ#ãÉtDþ)XneAø^u^¡6	0¯NõöíÀÇݑ'A‚D膭€_SgEÈ;kTW.i¥H¥™)Ê(ú‰Y„^K##'åÒ^ç1}”$OâÞ,WÞÎËt6J;¸p?Á½vJ—>æ?؏·Nƒ½šÐ#E lDì¾6½¯GMɎjÄ.øÛfä®5,Q:«Jz–pt”;)‰“5¸/‹£€ò ¦Ãèóø	¥å;²Õ#4#eHoT#*ô#ᰈËsÚ×?7I¿TŽf×?nù†XS¬ðÞéYL£\JV+½ŒW|mì.Ÿn{ÜŏdÃ$Ëcâú‘›×ªß_§Êã@,¬VÇVÂêzœ,¬¬¿v¿ÞˇŠ;i¹eçªîqŸ¹îVHÓ£pa_ˆ×}۟‡%í´ž’I‡è£%O2ø“¯„Šš€yJzšœÞD¬Ù<7¦¨ÔÊ`;é]ô:Éf|ú óþ,µ0³Ï4„¦3ÍFœq&©áÀ@Å-9Y?)LĶ´’ýÉMʇ'±ÙÍæy1í÷ݦuÓá{›Õc£¥äo‹ö„"è"ïf!çƒQ]QŠÛgjlޘ/_vØhÑ"‚gI@î_Ñ8RÅ#4#4“»@áp¬W¼¿‰\™=ô41†ý®9­¥pl«¼¼ìì/v_Á­älïå1‚¯j£¸~µ³ 3£æo‹ï˦ŒÄšÙú	â l®1¼ù BÔU;lŒ”;Þ#*Lp´,ÁQátp#*<4¶®©à‡¸ÂÑovŽ^ñzìˆf;½6”›è/áÁ®ò›×C¦A“Y<è!TñÂ~Í.]†Ãt@iY¦\49Y“T>HºfÍûÑÊ#*Š—yCYðíÑöD¨ËŸÓðŸS»Ê÷W*{MfŽdשüpÎAΦ‘¥*AG›ô¹Êäï?v–ñ>³ôgàÉÁô¦öà:rpúÎe0hä¡Ó'Ö$j•\Ô5{#)Pç^Yökr/õHއPp‹^É Îᖗ;#*q6ÓۄTÇl÷Æï?Ä]%&JoKиþ#4ºÃ”ìû½ìâŽúS4Õ+×£¦Œ˜ã‚9Nq”jçžÿ͖’ƒB4ü#)œ#4P.yìD›~²rð”6‡S9y{`Í+b0㏼5_)¶é=šTFW,iÜÓ&)#*5'áFånbˆohø#4!&¸ô=ØRU/·¤‘P%r"c¿På?	׏$l'™Sۿ֐±Ô¼tCN'{¨Øà,º®Èv#)þÊÇ#4ü"&mÒ¾¬Epîn;«ÞNIÓg²Ô«	Äç~$ð;£ÈÛ[%iÑJ$©UÊZ¸¾NÎb‡l’p§´;|\Ñ_ë÷nKà{°ŠWi”„bÅl„Üçw“Ýe˜n#)Sµ#†Š5Oá1#4»LlKr7Ã9uºº#*?­nH聯‘Ω«ÜðsTNÖWPø՜À&úu›fi ¬¿à³4ß¡§.[qMÎ\•ÚÓÉ°²>f¡PeDŸaEJ•ƒõ¼7hsç)V¡ëHÃÆÝ®Â[²s¢}ˌŒ#*àâö•dɉƒ½Ó:~t[8ëhôŽ‚5TµÑ¡·7…¢ù¶û¨®#*\ NVDµBã7W1U­lˆw¡z÷5dm½¾¢`|Åÿ`ü¯bæýÎøOž|—Çÿz²ùô+þçÿáƒo˜«£{C¯¦‚â³6s SÀ: ÇXfÄÂøBPõLú|zAF07íYBúd/|ž^öÍ`ã½ï!šn^	ij4¼”‘Y#4:/$Ó~)^(W³#*"´Õc1R7í÷n’]Œsz)Oß+Á”Aٌ‡#*q½&v.Xƒ·oC‰4Díó—›Ó[V¹†÷V×RK\’ØÚ*èª#4Õ5©Š­É€MBä«ãD´…†/Æp눚’î’±b$ÖOL]’-”è•Âí•Ìk6óÃ|æu›/Rgq>êw»OÞ´Óvëƒ|üæ&?(©µªN¡ó5PÅ¿ÁÅ|Cn_·òDÌåZfÌú¦Ñp3–^%sJO¢0ð•ô9ué,k:E|ˆ7 i-ÒÚÒ®4Š~˜`Š{ƒ²7™ƒÛ¶6Û´‰ó¥TVÚ_×#4¡ß­Æÿýks-Z‰TzÞ\¼ô47½Áy˼Œ~ÒoÕêJ3Ñ´—£ñ“æZR«ëBÄ!¯ùD{rÝÆ|›MÇ$æ÷ ÜëÈó«‡l(N¥¦ƒ.¹!6kÒcò‹n&&T ùùºiÃh-¬³µ„`^…AO-0ó"•»wí.¾’h3éåÚ#)©Œm#)õŒ.¿-awX7ypA…!ä.ꄶ!æYDž\#*\Éò¶?×ÄQ[­ÃøðTO)ÝŠ›–Ùô¼ÂäB¥¾Ø$d¯mµM¶©áقž'P¯'ñg#*	ÆésY¬z­„“g8짲tK:IéóµÔ	¼šÂ É:àȤb•Ô)¶–/ȺLò©˜M*_-?•­¥¦ XùLF9?ïäÇÀô†d2Žªpu–·ƒ¢¤ôodwm•ËìÖLBEøUÕð5–˜ñê“MÄã9ñ‡¼õ’40¸iÝ£è8†pÔ³¾FÃQm#²ó‘&­4v¼’Žs…‘~YZf	§\²²"ÚÕ96Œaj–>&3Hn™ùje¼nÁ¢C»ŽÍƾU8‹¼hÏaX~ɦ7H¸¸X‹}ÜVÍþº¼t9žö®{úà	“C¾s«Œ#)=PÁ¡‚X„#*¡#î_Ï}‰7lŽ ßËÒ!„¿ÍIHy²˜ÂþsîÜÞýïòñÿðdóÛþó“Ç_ï_þsοùpˆÛãPÝK&1/0Žíl–”g]®áA‡nĖjçõëÐîI—E¹ÓÍâËNǀ™9«FÑ5XÇlF{äp ¶	e5œŸü	³ÁßÖ?#*êw­æzÄ0¾	Xzo¾Ê(ù­‹G2çõ†ƒ­¿†$\ß_Íè•Áyk€À]	dôè»#)—õ@o•N;"P)O\zj“>³Ér„½é"]„rT q?vï`%Ÿô¦x?«J´s0àüIÿðs‹ñÁNº8Þßá~rZ‘:ž• 9EüÕoV³z6‹&B@WÐR™”Pi爼ÜÞùñÕáîÁR,˜&ðƒ4JЏ¤ôK«+p:#4›^+½ü®™Eœ"蟺ÐÏÍkà_{=`H]¬bf—÷8JäÃòNƒÈn¿O‘°°K¢¤+ö_ۙFž~‡ÓÉ:爫‡”Y¡ïJ:ÃD*%¼ëø6±Î»ê#*W´¾swùN”¯°ùU=SÒ1¹–!Õø*¥\“¯ª¶íËtý¼¥¤é\Ñ-a0¥ê-êãׇLA†\³Fèýš÷ˆ£û\†S»B¡ÂaR¥ï†ãk¦-þP0¯de՚¸9àm$tV²ûPu¯µ{³Š.ó#47ÈH2jçãI%v©áßt6B=§°´Õ»M«ê·XìT;Tm×åæׯÜ5†0¿Ï³®3‡iU§Ã9ì2g›?ÿ¦f-2´j¬tq£gûÈÎ*€^|¸f›D>ϏNŒoå…ÀZt/(?²8žš{yeî%Ï}èˆb+­2?Ä"92ȼ`|ªôI‘žbpÑ% Ùr}[ü¯zÿƒÑËþ#*7Àù÷¿Í§Oóïß~½ÿ}1øÿW¨~›}©Ò3нÿ9Ç@@à#þûނ€ë"SRÝýþ‡ÙMßhê%+›õÛÉÊ«³çëÿ³òóåï¿Ù=Ú9{s¼ŒPù+8}sz¶÷2XÁfA?ô‡vÿj˜Mž’1íöÈ|¸{¶›=<Ã98žÜ@ÎzwÒ]zLƖ»Qÿ†"ʳå¥ï¯Ó»g;Ï$–ü˜QÎîFé÷1âYâölûøøàû‡ò‘Ëö"ìC#O)2Ÿq‡@“»Áù]ðKû¢ŠÄiïr@½™Ïþü/Ÿéðèl/Ÿîì§ýÓ#)þ¿¼Ø;Ü;Ù>ÛÛ#*žïìÅÁ¾<ÚÝþ¦ªü=«Ò“'üÇ…j\Þïrï}ÿúök=[ÌO¼aóédÀHá;_«›ŽúÃ;”p¶`S@ ,Oj±ÉªÀhB2sFÕP”ɽ´Ø§m5	Ö\q¢uúqª‹V×jîB¼z‹FƘÅ)óÁ%ØÜrÛìöÆòCæˆ^‰¯½q‚8•‚—MìÍî)i§!5ó¤Ó; p¸ƒò©áÎp0a×»áËvç蔮H”ÁåY<ª¢b-¥zXRÚÙbåšÔ„°‚¬Ö~ðû‰¡±õ4M®ŸñÛ2㪤úus-Ä^è„m¬1ˆÓHZMU¹GðŒ5ʂ®¬º›üƒB“!¾j*ÃƁ:a>–-/V+f½wÕº`ô³©Esú¬cÇP»žv ©ÍEG46£Ñ´OªPm¬\‰ç0îA»+´"ЛñB9ׯÇÃmèï^‡4ñ2|}¸š=4•{HU{Èæöˋ#)ÊK™9§#4›qç#4˜vÑp9úîÉy#),QԞßm`ٖ¤"EZg#y~?YŒox[òþæÏy!Lt?‰}ûÃ]ˏ’w´¢ÃÛv¿×Í%&{#4‹ûœ£?†œ`ƒM³§Î[Á‰<ngò~ýÉcí™Qævñ¢gyéŧæ×ØHôݳ›C˜Ï5XhJSÔSzéÄ?ÔªÙRT¤²ëéØ.un@Û½™˜†BÑíGɔÄq„^ÌLz^zøâ´úØク½ÿÇþqëåÞçßþˆø_¶"GW§†…nó£oÚþܯÒùÂãFS¶=›¼Žo°él’¼#*cnU6›öÞ8„ž”Dðëƒ!×êLf¹µ%á\„Ûyz5›ƒ'J¡>õé¨-Péª6Ciš¸ù^+íê¤|Î$´kìmMø)Ø<E›Ù¯M–U¥M‰–²çÔÄOhn!ŸçøùíÆÇïˆô9´‚è{àþ« ÷É«rPµù™¢|Eš‡7¶6§«²Ü²,F¿|V÷@Z›Lÿ{ÜÆI€m5ÚTOeŽÀ_«xçDteÅ#*#ñvŸùÐî¨2Ná…¼ÇSŠçÎ$ïS¤à¯‡ïð0Gwj9×$Ù¸sŸk’ÈU÷ê9•sNßÅÓx¡¶…mW™>†Pq˜·Et骦pµGÕbчá1OZö²÷ÈÉ$€ÿêxIjOjH|T҉ïÆ=ØÐH)ù?DþwÑOg€ÿïGßmü÷Õÿ÷—"ÿ+7 ‘ŸøîS¡Ã¸¤^—݃yêm½ö¶\Òòvœ÷z’÷ƒ „”Kàãv˜	ïG¨^&¾¢——€Û¥ϏÒòÒ»n‚÷°LZdëJººr(Ìff«RW®ÙÌ]³¤"³™rG5›-“3Ø+ºé&F_Õɬ[3à9õü`ïu͍¦“‘  hÇKmuávAQï`${í6áü[fÈÁ!­ÖËÓ7§ìy’iͬò0\+²tDúÃV%ВPÕã0ã8Pá^÷ý"ÀÞÀ=ûV›®B4ù[{׍E§G¹ÜõãM{é$AÈ‰Ï¿Ú=Ø©9¿¿°ƒ—HJP´,s².\y«s….Xí#4'JQýWæL,ÇL(4îÃ):NÜT™^Ž¿4k0…&Î<áíAéøÏpšñõW§{øÆùóöÉi#„yŠŒ^M¥ÊÎfeIöÎí#µ)ªŽVŠ²ñÉx"úKc«2=^yûö«Þ66ÖÿRo®½}{ÎÛ·t椳ôÏ+±G#4­ý·4扝aìêéëÓÝ¿áýOPßZÏÉÜsþ?~ô8¯ÿùôÑæ×óÿK·ÿ#×ßÕGÿEgù¢ã°߇¤}n5ÂK85&ã6îâ½ÒæŠí«‡{ù—':#*Ü`§³ùIþÙ¾mÏO!¦ü^"n÷|ÊÍ´PjÛöÌEžŽì«MrߣÎòÒh˜e½s¸ÚŒ‡|¢ú‡ÜºøtcÝ°õv¦[Z½œzÕ±!(DŽ"0;B´“¬V‘Þ°ióµØ%s<jŸÛÝ®._uTmA¨E»µ…d€…œ…ûÐIÅïX n®…q¡þqÛFf%<¼"ÒjuԞs+mqQ¸j*ß|¬_ƒµÕ±AÍ#ؔ‡s¬Ë-z¦‰#42ÊÈCƒtýÕÝ"#)H™FÞ=ßQ#)ù†´E¦ñ¦°;¡žöôÑËãýƒ½“Ö󣓳“íäãðUU2ÔdêI”aêÂíó#)ˆ€›vÞK›Ÿo„%Ê!•gtéT5sŽÁéÚ}Q«#4aµ=`ŸãKùipY9Jè;U‘*UɁKÐ*[—”ë&¥Ã!æ˜Ñ%H	axQèÄÚ@ìÁkú@À:ʗ³YgÄÁ²j§cn¡"âÛì«ÞØÂÿeÓA§ó{ëm<Ú|ú]AÿëÉæWþïK±ÿ1£Fý[,ƒ²N§T}¸Ó)1#4;¹äîì„7«ˆ—ÕAˆ,ñŒt?– œA«cãØN§n£¦ Ã:üTÂr•a­Ng›ÔÑ&#4о…vþö¾¼¯+Yûoô)ÚJH«¡%/IˆÙæ#*p&s…Ò?¡4h³ZÂb‚ïgk;[wKàÄÉÜ{ã™uŸ>ûR§Nª§\#¡ÝŒÙQèçXíچG»hw´ËɍÕc˜qˆetÄÙý'íŽj[´È®È±)škQä\?Aëgt¹7ê6áTâhÏgîª òkQ¬ M‘¶(r­‰æÙÝ'àÁå1O«<3µ´Îw3Wm¼ù­ñ/ïÿÄýÎÄÈ}fàýï'Ï62úßO7¿èÿßÞÿ'·£aýêË}Œ¿¥žð:[]YoɱB.ñÊ\Øl‚”?¶g{¡¿¹E»·ä!ÑH¿ÂÉM4#ôG£›à}7†£3Tx¢Û}¬"]ò, ‚DsKk~71qÌJ¢Ö¤Ô+ˆrï &=7>òx%<»‡/Qž¢Ú—}]2Ktڞ„Ì‹ä©ÎϹEãƒ\‚úKÒãú^½?I”œÉS§(ÍL»-̏|ÇÅy®‘ܘ)†ÂºëšH}õ-¿q:gc­c40ŒiB*?ÝV½³îwXrÄè£#4³d.X女‡RŽ%ݏí[ãÐ/•"Âç:s/µîÝÙ3„Oècuhςô!!Ϙ“Ë#4v–'IuŸåo0+þrc#Pvk:jGÆxé:¼A¯­ýâ€ôíãÑn‚í#*ʅѵʒÀs¯x8­<fV›b#ЗM®­†0„ÀZx˜Œe{úú3ñãö–¿“|	øՋaҎ¢#*D¨*z%4iôúí$i\¶!χé•oà??(ÇÅ¢‘M‘¼K#)À-,‘íÁ.Ašâ$õ=o¹U!QÖÆêM…èRi„3s]›q¹—K]”	ëÁ)Íë,u¢¤{’n˜¿ßñn‡SèQ`°_'øHþµ¡‹)NHîÕSó{m¢:^-(ìGSæž~œµöÈÌ#)§^+Þ)J×=*"!¬W,0!&„%SŠ'.à#*Ø8ª±¡æɪçÏKoQ·5l&k´öq‹xqÕ½"xy5‰ –_Y¦=üÐgr‹§âԍ»ÒÁÍL	ñj27ez%Þä΁²àؒ0ýIˆÑ½š˜%w¼Âcx"íσCSp`‘×.«7£"d2ÃöhQYÜ#ô’-;Ó:QxñŒ1 ‰h)£É8_T™ð\ˆIg'V.›UJ҇…ÆWFãvӞ”¯…I­2•Û-y/›ek•É¶ä“0 TåÈ÷×L²Ö=CÚÔ|ü‹£¹+˜È#)¤1¬j˜à\5nÚ**¬˜ð¬¹åy3(¸ÏË۞Òb\s×íaô°+êf —8ý®.èÝnÏxBÞ^Ÿ=fþàøºI2½ ”%ÈÐÚîø£Þácå#4O‹–úzjM‹Jþ.©ÉQ/$%ñ¨F4ìxÀj´=´ŒÚ¶½W<GlëdÛ+á:æ-ü#4ÕGJ÷0`Ýt¶©äsÏcB}&;/~&.º6Ž†üf¤ã¸ekþ;ýxI+g¹aCíá4ñ†ãVïhԁ6FØ̾¦t…eÝRý­ùeë#)bu|ÔÉ°U#)ó‹l¨#*Ö+b‚b¦0¯4f ºÉ£ðªø©âI#QTGúXÞ°×BÞOëãV¡¿»¬ öŸã±ÓÊu¸²rý!P~/$÷£±EŒ¦ƒ±uýAÀ,ŠÊ®R`b&ä¦ÙUg´xp_ŽÊåôÛ«îŒ÷!(û–#4U§6«‡âÆB”˜à§°”,èˆ[ɝØ\á!‡?DҍàÜgÍÝ£:›;U®.{ËlG¢…µŒÜé«LP)°m‹Ú‘ ŽÐ¦º"\ó•M‹_©jÙ(;•‹û]ÌÖv͖‡i Aâù“C¯5D^Z#>kÖ4u¿êzQq¿¡4]ú°k¡É—%Þgr“ÁbÕÊ<¥GÍÄC±Bì‘	VAvTÍ|TféMdwùvªß˜µàå*Ú|ŠÎ½3D;#4v€šŒ	æXxÃ<¬h{%qÒCÂÏ.®Ïñôv…ãë.7'3Tâ#B¤ÔØY”§ô:ç¯ØewMìÂÜEš«‡Aëqz{è%Ø%˜ƒ#)¯Õ\¶áœ#)lžÉÔ[“êrØ`í¾c#)¹WÈ6êWîRݛԕ؏؃ÒyÜo¹‹Y¤ƒÒKÑÌGH͆=Ðü¡z-M6ÂɦMà$D»P¡m”Â7ÃÉF–t#Ñ7ð$ŠžÒ;íá²ã i"fM`“#·–Qª¾Ì´A‰±"F×Ɉ£íï(™Šû5>ä[äÄn‚Äõ(ÒP–‡^‹C1¶öÞ¬ì˜C‘cP±ÁÆLÕj“Ø…Ö/,ðî 6[½õÔ6^š+êÙÃô£jNcHzѸèÝz}àvÄWÍØyI›g%{’?(eû3Hw4¤£ÑMRBÞ«hKWÔlh.Qw‡cË>Gf˜¡ HŒ¤ÁHHÓlü¡1Üø e¬³‡xM­Ô±YöLµÔõyôNÌ°bóMNlVì~^ìÁÌX©ÍÞ+#*†^2m^ñZ˜#“¦Ü3(_gø`²ü{ÎL–4‰“¾q÷RgD‹¦;#)Â,z6sD\)šeMœl£œïò)7­Jæ4’Û#*ly;°e¯ÙÕ²ÛH›È’ç´®¿¸%†SÙÅ/¸~T»ƒÑäiÍÜI`C°îŠ¥áü8·ÊLâlC€Ø£_8e¹K"P¯Ñoæ#*P„bŅÂÈdáË=Ç†\j{ØEÉ>'>ê¨ÛŒä†ÒqBN…à—PsÅ0ÉC–•„P4Ƀ"çÇ"՗ó`"‹2“L63åõ¹ØŽe¾Ê‡œt*‰ŽAxéÎâ¦rmuM/Q!=òY ‰ŽT@«å/:aÑ´aÐ+°'-‘ùπ¼l‘@(íJzÍ#4˜ºï§m‹7•ÉͽåK<ã-U¬|çrýÀ4XÂ8NzÀUDZ%)5‚MEÇ+FLN“I×ÆqÉîW‡ [ûº/,åähç©Ç<¥2ç„Søßÿ]þÚ?÷ãÿ®?~œ¶ÿzòìé—û¿/ø¿ŸŠÿkiùäjöÔ°7DŸº­á“þÛÌÇþݝýû¹4p~“úÊíæïÃõs:r¬ßOÕÊÉâüþ¡(¿Ÿã×Ü\ˆñ»á÷Ä÷u‡è3aûÚ­NcûÎé‘L‡ü6dßOÂõM·}Ncú~Ú#4È ùþÇ°|?’¯ÝWBò}ŽïçAñµ«öÙP|aø>Á×áýŸ‰àk—’Eðµ¿æ!øÚß#ø¦s"ßtàC|èZ^ÎÓµÌoåçÐĜ‡ßûEGó¯§ÿÙo='À¶ôGŸõxÏùoã1œùRö¿ëë›_Îüä“çÇÂéÙÉÑák Ì|÷ÆBÖӝŸª{1lb'§/骑\µ“ØLg1転²ªø‰c1§åû*™ ÖËö%Gž®#}C˜)„¶	ÛS% )=ÕÔ·zm½EÉJˆû“.ûŽ¹R:æuÓÕ]™Rã Y•Trª.ù›TNãýÓ½ý“R2©ñûYüöh¯Z·µLöDövHF)˜›8å@#!‡q©dU:äç¤ûïvThºÀ®TZÝËvBŠB©¶DNjV#4°îܖJ·†Í8¶nÝ…ô‡ˆ¾lW¿Ÿþw›£æŸÿ´þí·ßfðŸž}±ÿûKÐÿ”zûQ`x9›}º8§ó=þÀ|Œã?ÈXw¡#°.Jïcý©Bÿ£¼w¸ëÿCw0n'¶ÿwXùûßÍ/þþÊø/xºÈӃÖó]@;b¼%›£\ò+ã¦ð‚ã¦a5VÜðâ_ˆÊa¼#4ŠwmpÒìž(q}ä¯u†ti%i£°kܜƒº‹‹«) ÍêܼB#*0¬“Lcl,ð”¤%Т4ò,—°%'qTãdõÂ/mÇ9µ_z±õKÍ;ŸÔWJ_Ý-oòÜí@WÝu;þ¹Cîòotï "ðW,¥î¸ÏïXL}Gòê»Ñ¸qÙo¨œ*+/‚ódåëàΧÂÎ?¬Ê—ýݣû—ûgowŽïvߝœÜ½9{{p÷êèðìîmõôtçuõlçåAõn쿼;©¾Þ†øŸw{÷^ýœ)ÁÞ²²ÿúð褺»sZ½ƒ··ïÎöö«#4hF_ÜÁêyRQAÊ1yÚç­ë4—Œ{i5B(â£èÜðÎÆv™‘ö³=.5ÂTÈ7Ñ0J¥)4Èÿˆ¢i#`ží×¤„qôØy³*»Ù8Íш"ف£žN€<>ÁájÕZè.ívZÍã2›\^‹“ãMe®—Ì·P=>‚P²@[ñéøO9¾u4à1£ä"Êväý+­Îž<øßÌå×Öþá.>R°¹þڒG”W8¾Âƒ	¥{6|…‡¾¥}yð®*ˆ¹Žâ¥I™YvŸÃaŒ^1Ž #*þl¨Èé’ÆegÂôÄ…óy[Ъo©ArH4š‘ßOnš¾Ar¥“]a“(µJ$¡LÝT°[iˆ]"I4Ò6Pf2äÝ"ôO-¯œ[\¹ë9>Lÿc0%lé?Õþ{ýéãǛûï'_ô?þ*ò¿E€G¬-Šef(ae¡C§Ü¥Æ!j…”[¿1h%!PèêÏÕÝøøèúϱa…DEMÈ%—¯q·ŒP‰ö¬Ý¤B“Ê„åÕé6ç'•T(I¥F7`&iÓFòÂô*i{ÉèêEtmJŠ÷ °7Qg¶Œý‰»%k¢ðE¯íµ“†ô@œ™LæƅØLŠ$¶dKÖ#_esš·œdßâÆÛONì¼%NaØk͋î±Åö üzwWãß@&4Uz¬3.ºÅ݁±<’XU Î¤îOŒéövÎvNŽŽÎööO>Є•’½>|çñ­èµ†Í)2zèìk仁ºž›ÊåÅå°£¸vg-&‚ßi£ç—ܝN\øX€:PD§.ºéNtˆ²½±³û#ðθ))òÕ9m9Ú¥†·nºkï§ýù‘F-žÚÇ{¯DJ8LÿÓæ¸g”¹Qa!/³Œfس'ÀG|ÁG‹¹UèY°ÑBøq§¥€‘¡óY º$nOæf¾£Úi‰ÞÕÍ°ÐUª$¾xJF7Ì{šx	m"ðé—û‡øˆœ5¾ZK)2uñ­`q«+üp"?}c­4É/Q4íA…vŽ‘u»F¨œ•9Ôþ¨×žh4#)²ÎY/,}¸‚å& ˆƒUáós´	W¬’R6†¯Ft¸Åô©#Zń ¨z‡HåÀÞW”«³Êt„ú·e£õe%Z>hÓ¬%ýA. Ⱥƒ\‰”Lÿ9i°º×üáƃPøf­ž-£©luœ~Q>#4ˆ<ŒÃØnŸg5c¦šW'ÀvºX±A;†óOŠ*S£º“)-äN£ÛCy&*¸÷ºjJY˜üµ—¼\¨È}†'aÂ#)§½Nmƒ^Þª9zET…“"¨z@p¦ֈ'ÂÜœ¼"Ña¢O¸}C'Öiу-«âíT^v‘Þ²C6a¥,zp@ò.ÚÞe÷¦ŽNÐZ¨X.s2(û¸=k`ߛðèë7Go«EA¼ô®ÉF}D–2"PB§ø#4H½hbñыD¹‚ˆy-§t~eˆ&"[Á9quÛ¸šür?B}#*ÐõcpͼnÂÖ(n«ñʯhNßghM‡H°ûÃD“ÈÌeÜÙm+ÔÐû׬dǘö岿ª<#4MÐ×OÓA#4åf.'Z¢ÜRwzQûç_ŸÿZªýò±¾œôCØðC+³@œcé†e»;֕ŽTy™®²‰Ìõ•ßpþ뵚›þýßƳ§ÿ/OŸ~ûåü÷×ÔÿoŒÃÖ§ßõáÔ]๢æc¥ô¿‡”ýùe!=µ B{Êõéàâ¶1e§´¥"[puÝ{»çÝlVŠA•7Òxä­6: ¢Ágs&¬KÑÖB¶ïýܦ¸š’{JÝ­ê¢e_¥Ú£njõ$‚GzO£tî+;ÙþánÊFÀQÌÄwGõ^â(k#)ŸM#)´mÀžc€¥;¦ÚXÀ(Ô¶´Öꁣ†¿÷¦º³W=‘ë–V—³—4ñ‡îä*æS&&}ƒ¼Á›Žê¥7{'ØÜtY¢[º—.xÜF–7ž20ÛíÂxúõ{/xièôe+áY7ƾÐÒïÙQW_Hÿ˜éúÿHþó¯ûèÿ·³þ¿‘ÿýuè¿+ò#$C%÷˃„v¯‚h§ÐFv#4Åäü^ÜÃû7›\_J	9rŸ [ÖSå¤içô´úöåÁ~_Nª§GïNv«äy\²@•{AgI06©ÍYFÐGÛñfŽ§M¼¿k'I,¨˜¶Wͦ¥hʽ·ÁÐzÑB”Ŝ§2žÑ½:UH°–ü#4Vˆol${u…7sìcUyöW+ÿH}/,Á”C¼ª”CE	7ÝhmÕmjñÁgAå­?ûhy¤Ê€ªÑíû$ßï-4!TµSa-?»ªä@ü…‘¦Ï)Þ>Gþ›¥o¡›©ª‰tô¶´5`èsÊ՘­_ªT#4\Û 3Öù§ŒÒ>tù"An›£©¨³è=ŽcU‡GÔg؍_ÿʂªØ‘_ÿʬ%(Y⨢ò”ßKôMž“¥gܕ#r‰¼õ×fó¶ûçè7ú¨µ[÷ñV]<¦Ã¿ ³’ò<F7•cZ¼¬·]©>Љë¥ÂœÈÃf°VåéB:\Tßbä†û§Ê¸ÝiZ··Äu†Ùu[#*Y§©Å[Bî?#=´¾ig϶“f¢ú‰©˜å²½™0¢	Ó#*†^ -1#){#)#*÷•óv=ÔøµÚ#!ÊG¡ÔLd ¸1ÞúÓp*|ÔOí¤y+óÁ³†f€™>äCÇ¥À”^3êë;} *{՗ï^èN‰b¤ÒË{uz¯×]¥ÝS}“?ˆvr,òRGßpj®ú•~‹#)†%×I-=%¿2âHyõQŸ˜gœðÚëÞBâc2ܺˆ?‘.d]ɛ.±ÐõQ£ùPÞpл¥.‚É»ï}ZŹÂ# ¢ ¿ç$&k¾)•µŸêH;Z?Ü7]áý¾™¨fœš€Ãfjú#*›ÙÉ7lºSïhיxÃæç]þä˜õ{ÀäÀÆýÁ“ã~‚½ƒ¤e#)Y·ÕÐ÷y«ÿY=88ú‡ïè)½Ýe½$â'øI++÷ˆI†‰ÄÀVSÒÌ$†£a©"‘òކÅÀ›¥Æf¿ÅÜÜ#)oÉ¢¼ÃØÕ)„'´ÞmPøyc«®ñ#á¸ú%©¨ë8ò©×8,ÊÑáÿ,í.Î]}¥®}?†GYƦUšLœQÈ)æšN&f.§ïæ`Z7Iˆ~ë[¶šèøjƒ> ,_0`€‰7ô/ñG„DÈñoʃ1Þ")‚þpRUÄÕzê»"ËTSl±?U•T_³x‰*l[%'"îy×Cîm#)^E Û\†b˪ˆYó¡|8©Ӆj>w׸»ÑÙdñÄVl'ö½öÄN†ì1ª!L-¤<¹e¥ìNÜ?ŽßV-	*Qê"#*²®3<º²ŸAÞ)éKEuÈK€.c­É¤^Y’þÒ;·\¸¾\äÊbtÒöم@÷øÿXßÜÌè¡Hè‹üç/&ÿÉhýçcƒ„„ó…BàìíUI…ì+Rp÷â·§»ñOՓÂW¬ÁN¾#4«?œy1ñʨÄUjõzìL$(|…Û]Ntø€Šñ+KDDð#)7Ãn+ð~õ„–}ÿƒG*0…·;û‡¿£ZÜüßY­#4ÖGoæø#)¼D3ô€¿{++ðrõ.,qTüöƒ§Ÿo~ÐÔùQIgxQä}Ùr#*CK‡K¢ÉP‡J¹œDX€ÞYð+ùq—OÈ#)M”S‘窾7ÿ¢OøDÄeøSÜVÇ,E1¸Â_Ÿ„I˜„"#)x½\³‰a_sÓøïtYŽe	Â>× -‹ÔÔ#@Í_¿¡”6]È^‹è­DçS}²¤*¢ä•Ê!û#)µ‚$Æéà$Ö3UR›ýwYöÖå~(²>§h»:~NbáȤSÂö,ÐÙؕPÙ#){é‡p#4—Cúëܬ°…ˆy0i,[Zw,öméÓF¹2#*~aÉ=hÿü3;—áϳ™¯=XšrßkûòZÝbSÜÙ’·Çe°VÂô¹ªÜl]UýöѦÅÐ#*äq`–og8Œ'?„#4:•<~áŃú«¬Úu¤C:Žú¨õºZÃRàO;盛p¨eþç8æGòn¤^üzf øƒÀ²È)K‡çøO–œôAU|6‘tÍ×÷×j·zäKUßîìžù:µÆ·×IóƳÓ1Q6C\·¥ÜÙ¾-^wúIU°ƒQíÁâ[·\šR²–ZI!ü‹|ë9ÏôVJð§ë*ÍcïÈ3¥~7{©á„{:kS'–ôÀÎB:ºEÆi´L‰™Œ[Ʊ2Šú8µ‡»€rW|°sòº¿:Ùyý¶zx†³õ+QôõžOÝdÒª\mž#*	†Ò°Ó‰'·yߙ=(M˜Xv€jJ~â\{³óS5¦¾Ú?¨šÙ†«t:I¥UuQ£üý3“PÀ„÷}Ó"[QSóÒ%þ³Ûè’(ì7RDPUBU£&ÉT¶@€J/÷_½=ƒ‰7’I§›ùþàéΰÆäÅX0úÕY“j3¯å½‡+>zõ괊•;;ž=ñÖs§åF«ëf~ÖF8«0S°>{’u¥a–áÙU™e’ÀËÀ¤Æ×bõpoçÐYŒ…ä#4ãÒ²KšÝnÜï×ê^œêúìÉæ“ïCüýöÙSü}V}ò„~¿¶ÁïOãï·ßÓ¯÷ñ‡LnÝ®ÎíÙ÷Ov1öÓ'O9—§Ïv%WÎý{ɽJ¹cn˜ÊÛ)/hC×ޞt»uoՔحã²7Ui_4[°õYuùîû=ªyõq•~¿{ú=ý~ÿt—êòÝ÷»Oøý»LË$;«£v7w©£v¿ýî©d󄳡äð^ÝÄߝïè×ng–Ó6S#45δ[‡7&ãÚð "Ç2œËq{Dî֑óo`.çË(÷ôµèƲ_œM"ב#*]I%òÇ~#)ó”@_|T5”73$AÖA÷ì¬×®ö Z¢µ”2†D#F…ÜÓëN&=8ÚdõrÎy˜Ïéí郲ºè^ú9ÈÍå#*ë$’ÓIYY{îq$'¥s(ÉÞ>ç•æXjcO›K–—µÆS†¶¦xl1‘p«OKÞ Éî-Z¥H”"	»Úôr+že[í¯LÀ"Ÿ³=¬žåÂJ¿pxiu5#*Ôï‹Lî?‡ÿã8ùü*`‹å›7à9%ÿ[òEÿ÷¯cÿNƍfû¢Ñ¼ž¯FoóÔÁl…®N3ì ‚&òYø„&ùô`E¯²Å\Õ²4â. }qÕiæ"a±m墏Ó'#*:ÔiÚ×O¯îøþ«£“3û(éR@ŊøßDŠ'”eLÿcÿðñ¦°ê˜qŽZ/¾É	Ôª¾*Þ{-“힉aT}]Xð5yÙR À»‚ÈÀ_÷u°M¾¦°É;Øi;Œ„"yxԝ€Ô*w.DµÕ4£5M:^¬ñÖ×ðpµ6D×yuþÄZÅRéD£æ¬Ã×ö|ÆAÎ`c¯ñ³ê¿¹Ø×þZ–‘©óºËö”#)È·;‡û¯Mp!ˆöšŠé¢f§¦\#4uZ/Á#4F7ù1ç痁ñŋÊx˜Di|^£b6Ȳ6#4šîàd¥rρNÅðW¥@ëN9'>tf‚K¾xfYS‰°¶qqrP<nÛ`<ãâùÅþ`Òî_TVÎ/~âHçÉJéÅñó~ã_Ãñöyk%8¯Ð{w ïE‚½	*I흩ÎÜ5݄iÝ&÷[Q§iŽ›üŽ¶½á%ù€‰Ây52ƒM`~”«IB4¸h¡P¿1i^E¦1¤ä#c…@ŽFׄ⧌%ü&¹rõÐfbÜGéõšÊ£‚ø:¢”CÞÇSò§êÉéþÑaTº†?v”_ñû'p¾~A~G‰ÉF( ›èPᶄl<Ÿ„ØÕ<+ÙØCv#)<wؖK2cwßE<:KŒbBÔô´ðàDŠTâóHf$åQØÛӟvãÝ£·Çû@šUE-	¢DQ½Ñé#*“’´Ã'þ„ë݈¥ªm•׃‚Ö“š7ý%w+²tÊRÉKn–z‹œucÙ!wN|7#æI@ÓàÛéõ.·Zm@= þª“¨†âOX~Ϟ Šm¿¿AXòÛýgO&NH·ñxfß=£×ýIcН¢^n·1”òź”€]„¨	–ØA4Ĉ®_*•Ê‹Ê‹ó#4ÿú+¡r{iBò»¬aÿ±}[rßüXýg|p´»s€Òñ7°Õ†þéÑ«3àïªççÿ~xöäñ&*wŸ3:ßU#*ç篘¢ûFÂutªçš€ŸµBëS	­ÁF\¨1xß°k(µs+WLûX9»ú!å2§¤8ß_“>Äay²äd…—^ƒiQ½¸¡‹~ý(#4Y@Ô¯rf©RӒë°HOY±¤§à½.¬ êÛgO΀w<Ûÿ©ê»šZ&?9îQsÇÍéyXõÏÏýU—¸ªmêˆÑƒs#4ĕ)PZR×qþ}Úß2͚•¬ìCÿx<lM›X¶o»IµGJyÀ³CÂÂÄïn	kŠG3_øD¨@líó×Sñ»	]˜œ”EÐÿÖ¥{•×?Íuàù4Êz›‘‘·²ü´)a¼Ûþ–°‡òÛ£ôÿÊ!æBq<µõ­M¼uQYã|<•¢©Âk;H€D¬Ó¢*#*™¬²ÙŒ\o¦Fi·ê3¼­9;V«ÖåËÒð_sæ	“î¸cM˜ÝÌdß'–šÊ·1f»U¢7«‚•ëö-l®„Ò×1l–œ.Ã&¹ŠÈY9Õä¹nÈ+ÌÌÜÛL,HÍý93¾Ù¹T]]èukú9Ù:óRUÚxôiLÚ›$W–*‰ðƒÐ-]ZTŠ3Hç‡‚7$(÷t’³e(ª„žÕÓϊ£ÄçæhZp˜cÍ-o¿?&I±C&C’8x#*ýmÚG-èøì×+³ÛÌôè„FvÁ	Ær…fØdY.7M\¤$›æá¡Ö À`ÜLh«œ‹^êDŘ°öˆ*ÐqÌ#*;êu›ÌFJèß³<â+cªòr‹ˆÃ²“O ³ b±ø·vójè#*;¬GOðˆ^€ïŽ#4è‡Þ+.'Eo9)P\âŗ—ñgy™ƒT²åeyR0‹åeø»¼üýJ*(x¹Äý#½…)É5G¯ùðF²8ÔW·†H×~’ß]?TM2ªFV;[mÄ°Á9Íx¯X„ƒš¤dô^['Ýoz®Œ†£Ò:D Ò@­¦'h"Âѳ ±æ/ë­Èíå ²¤'NºbÂGy‰!!iì`ŒÚÓ-Z¬¦4¢æ²°~0×A™ìTïKŽv%MTUª}·U·²Ä#}}n¾8xvžÒØLžOòò„ìDªÑ-#4­ª…V–Aú,K}W+T<p™—æ¬ÓÀg8©ˆÌ°QÂswL¼Ò~8H#áӝ4©cÈTW2Ï#4×è5qiA0Gòéækð<uфôwPê†=s¸„èJZ\jb/’a¬!*ù±µŒü$4æÝ ‹•yi‰3ʨ€;!ªñecýËËöØ@”ò»8ÆN&Aþ°IIìZè.]s¾#ºÛëìT¥Ü<‰Gl9E&ëgf`·Ø—=Qöm…Æ­sÈ1´ƒ9uÉËx:Š*°ŠA¶h¯„Ñp Ge؄Z]˜þ[npØdŸÞ”£ç6'•ñá­X—š3§ê$bӒûWž\”§YAÆCTŠ¥¨Ë֝ı˜ÔLf¦‚°KëJ͍#*§â΁“+r-™°Úä¡Þi-1ÛXá9™mA$7PUÃ#)ñ‡Ñ4"‚_Õ@~U°©pd­ªsT­QÜ5škÒÍJáG*ìœÆݦ‚œ>Ž‹µmþMˆu¥¡›ڍSMÒïYãÚ9zsù½o*¯Z¦zÀ­µò¹1F«:Ci.7Aq€¢]Ñ4/ÂÑM¢f_BÞ¨ÓWùì‹ça™*+„ÿÎɃ?!3Ã:O•«e¤S±O9¢¨1I‹ÀX†¼ßäuœnDï“ÆM[+춚›pþ¹R6ˆb”ॠ¼¨Û;/oµƒ±TX/1‘®ø¶`XÐÑø6ù¦kú3‚ÍÿÈÁVØKߖ…:ídrÉæÁ9¤Îó÷éÜëɾ]‰!cÁ´a¢”ÄYK)#÷äøY‡ôUTÊ‚H#*¶£‡qê¶Õb;„ÛѬ‘êaŽ`ü1ŽTšOVÏH&ˆ6Ÿ+én%Ìð'iÖó`сܛ™½Øè×^#)_‰ ²(Ê&(¡ìÕpÊô«Ý­\1»=@Ô?;ÝI!BÔ¢zÕ­ò£óß9™—õEšË£œ”H?›%Ý~#4$“î²úÜK˜Kƒ·g~nqÎù¿=ËÉßf(Ÿ‰àØLZ–X›#*`3ü1ú4cELûp:hU<Z#{®lCYi¶› ã„f’­y(8:¾mÞi:x/Œå_­tk]÷{C®˜k֒†y°#*Àaóbc¨›Éô )Ð(:•èUTð]‚ð(«.ŸSè:oÈy™{jÜ2u:ûÍAô#4‚HÿPWŽddæ yŒ¹½ž‹A9„:O3Ÿu¦["pêh¨†÷•¬ióoEeµ+B#2Ÿ2Å "vn]CzÝI¶ARº‚bH2	”r£d«åŸ2¦_ú3Àœšñýˆ=…•êyèw”ÿkßÕâ¸g=˜#)$¤ÛÁkúÌȝÿ¸mÜ?ùSÝÎ÷ʑ3€B..%õA‘­Ö#)F:^<eHþ<àH*ö<|ý]a|H§ùAá¾9¦Êp#)VöŽÌÖLLí#*ÊÿKöߊgjþ™þ?YœñÿÑ¿èþåü¿ÝÏ稄:	‘#S_i.4µH'úÕ§3¿UcGä÷-¡z°÷Cî7o/!~ÇÀzjÀqBõ¡Ña謗“ÒéLeê”]N™LÿÂC³ir쎻V"|ãð«‘É^‡Igã'ëýr0M¡ÿjÜ4L°46UÍÎ6î£ëé³î½¤„ûəõ}bt¿Òº©Òù0_nF¥%7ÛÐ|­éjÖõáÝ÷Ô¹+7ïyú]Ââ³móp[’3`úâ8$˜#4xÆ׃Ý÷Ý[	ôïN«å¢³à›0•õƒ¢Ü¡ÚB×±òþæ×¼°¾ê‡™š0°äÊ(;ͳ¤]{%ãm%Àû1}ìւ8s²¿J“mwY9ša›šÑ2ky©@¶B5æ¤"6}‚a?l;–;J&O–»ú×䧿¢xø{è»Ý]ŸÝÎY:"Áˆwwm©©y»Ra­Ýó	íqõÜÒ¦±zjz#*όÄ#?××CvºæÎF5­br3Ôè‰X¿¯ÀŽ7„4ûŒ[Óþ…r#)Ḩšf²ÇäT)ߛ€3Òª–~Núö-¨r³¬â×d{ÏpÝzÎÕ	Þ*ÀtO™n`Тbz¹ª…DæיD² ”‡Yˆ‚—ø…ÿSüßûÉÓ?#)z1ÿ÷øÙ·ÿßO¾àÿÿðâ¸3EÑ@+ލPÜɃÚ%x_¢¸³~¯’4f*"é°ç7Bå#4Ú´•rDr›4˜¼áЂìeûôQíÝW$†äêâÇMñ`Aˆ»ŠKÇ_cÅüO¸™u=˜Û˜G¡ëëŽåÚåÝàŽÓ$ííØEAú4ã'ŽluáíÑnüv‘Ê°Š•+^¨\]ùõBõç³ø6Uˆò~ܔ€wûø>íÊëßϞâ{“S{Zað‚Ê.Dá»Ø÷³)Ók;äüËؕk×°¤-›+ùq”£?lòäú=huJÀ£8°º°Üä6çBš›ZŠ¨k·”àŽuaÆ&ðIdtv!;§?Æ;gxé"#*À=ëD¦Â¥àSjEÜ1[$«¸“®HÎöcíÜX±ƒ¯Ù€½6JZ#ܑþh8Ä,SüÀ,XõY+-Ò_k\Ãyj‚ˆkœ‰¹ó¾ûuT%ѼPW%U³@ò$¬a¶~/]iQ˜þ"â²Rßýd‰›§ƒî{´¨Âõ£L³Ê]_ɋÝR-˞Ýöû-`ÇKð9¯/G¤xË-¦CýPh4<'‡ÊdÜ)ë¬kìäڞ»­vÏƏÅ΍6ª')¬3õÂ1²K#*#)¡²Ê©sõr°¨8˜3Ô¢Æý:.‰!‚¿·Ä¤õՅþ˜	ø©)nÓëüF"q‚ûW#4Ù-\ÖØñãƇ¸Õ%t ¥Œ§ÝV)µR/ó–#*dÓ1È*£â-f«#4ÌÆP_”Z4š<7•Éú¦ÙŒZµ­òRª7jZ#4\Ûҏ•1c+TÐX…‹çÔ'ââ%ÿ—Ù#4ۚßvzZÈAàGÚ=$På5cA5©oR‰«rc@uàH*‰9‡Ùe»½bEJ¥çÕq{ÙBcrLNnûªi}‡COÝÞ὞:N¸ê¢BrÇ9ȋnöües¯’¦¸.±•!u×yÃB5×[†ºÆ)¨RÙ}mCi5ƒ$–4ó|¦ÿý,>xw¼ŒBöʓD<Ÿ§}œs¾?¿=¶¨ärI¹{4Mq7ž»Aë\L;¼ÖΆV›‚´ ‰FµG¡…#*‹?Q›5iD>…O/¹’ºÒ •ÉcqjYh‚cTÆù“Ê;PÊ5RÕhNðLΊ$¢ü¬k¡r¡…¿i­´"¼“¯x²Œ›öö¬våqS¯Cg"CôÊr‹8«e&¼-ítÃA #×E³³Â3üh”™ª™x3Ž'?îê’xEÈwŒ‰n1—°Hp–“:ªIººQwá€Lç½ÛwúnÚÍë;©'~´˜¤Þ:hA%#΅H|‹ªÉÓ%1u±¬1’íòi÷)O`’©[9gÿÊ÷XBj*]e¼¾l|4Þ¬ÛçW&#4:·q”»ýÅWƒ¼ÈÑ#*Æ*·Éºê}?yúPdO4ÌðèvÕuR㖍Ä[<pØÞeÔVʔDz…‹wəôØ,od.¸˜ð¼œèuWâô¡µþ(ºìvs†Íd¨é ×RßÁJÆ#*†ãÏû`šH™îÐE:ĵoÏóÆXßN¿ï[lQƛõºž:šû±ôGf¨Š,Œ`<JG¦4[•	º¤Ktàä^˜$›ïûØ3—@ÁÐ@¸¡ˆhw§<¹Ð)-ÄúÂ|…7Rè#mÏfÂN6K¶Iº\BV_“" aƒT¬èLpšfNMw½tuzp;ÇbüPÕºŠËÈí;B6´TGÞ÷¥Ù3K!]	ª™ìRzˆëØÔ<ÅL;Y®S&Ž°*;nÚ#KWA}ßߤ=Ojo¶½¥¥ë(w¯8Ð[Y=î65¯ÝØä*Z`@QÉ(iœ#ÿn·1Eð|3cøáecq;ìy“û¨UˆOkû¾Zn¥Ô6¨TKƒ¢•ýUÊnc«žb}­XT“¹N1¬Ó,ù©NïÇ?{*òl_#*‡i.ÆR–!pVŒr<PÌsÂåB×1_šbh—.gð±x ‡A‡—R ,®ãð‡ükì¢ÛKH34Œ/4	Ï÷,óþQòI«O+ÓSºa@ʓÍ#6“ÁÄÊ6GȄƒHiH³°­Jè©À?4>ƒ„Ø+;adڃ&ú&wÞ¨:PþËù–€¨T«ãÞGˆ“(5,	*ßNÇJâiqù&J=\^¾d’`42BÒ} û;ôÇ~€MÃ<eK?%:#4Ou⃋QôžÆ"äÕñ_¢ëR1gçA+"#*ÅÔþ¢}Ћu§ã±nÐJ-#*ªŠãíDz”©#4}–ƒ€åè„fý̞*3å.fø	ó–ÎR½êäe÷øX “¶EI}1èI[ò¨wœÍ)ùŽ‘™þàJsúðJ¿Ûß5'ÊùëJŽª¸?<êAu甎¬Ö«é.õ}_+²eÚ•CÜR$ÅHLÿ| ‡ÀšÿçÙörò|üåk"¤ÉKÀÒóä	(öž5ŸY±ÄŸ?Ú;ÚEÏ@¥íçðGéºGōÊzqû|ðü½šÇð²œ@Àšò|#*SúËPYÅ4fàïïÞՖp€+i¹#)Ï+õÚk!J>ñC¯{‘Ä­î8ÿlx0™þ*°º:\¤AÏõ'<˜à—±ã51!ˆ®Î­.Ë2cµèèç'£h™¨õ~þY”õµ²§>ÇÊ­?#4±Œ^7¼µåµº-ïv8E°]xÙmÔŒÄlæuºãdBƂˆÒYxÙß¾½Ëî‰aÄïÍÖ(îaò–¦	âzÂ6½{tRõà÷û{ˆ#€¯ßíûSƒ]Ã/wŽ÷«>ÿîâo2iEÍÕՍ#*ijß$j=/xׯ“…1A‡ž¶áÉûû„Q‰UÓ=ÚÇÒùú ¹\|ÚYðºÃó±Ò#*b)Ì¤è#)‹h‘Là,J߉fMrüjT| lSF&ýäõ´dZ’®³Ì#*cÛKêOp" YÝÆÞh˜¡ùûT­Pn5n·/’‰®~ïdñìXÇ¢Ï?(Ç%‡ï¼G#°¯^éˆÈ{Ððxf¹©ì@ø»÷¡Í%¡ƒ$M‚Þ×_A»_žîÁš·›“ÞíÿÓÆìÓë—3“àì¦|ºGG·á½5RlÏiË~â¹± ?ßO”«ž²Örè¯"Ïö#*iÿD©kaéýúCÛ^@pèS˜]¼Ÿ@¦éό®‚Ÿ•Ç-š{”ŽÎý”ȁe¡oŒËbH°•#)+¡jŠ6Ut=‚d'>9::“Ò$ãüx/÷}đ[\,åÀ@êTsz¯gkğ³%!ïDµ%!)-i•J9&­ñ“OzT–Yãns‡T¨ÛŠux6䕌'AÜ8ídgãa¯7i7¯ÖæZ¥ÉYrÅG·DÁ©ñ«€·HF~Ëɚ¿Iøžî#½¤:EbJ€¢d`¾åjÅ£ý%ðy°@üuú'ã÷ýk:À¾ÇãG™V?ëß¹‚¦ È0ÊÞòI™{%¿`kÅp1u°Ìù¨*ˆ•øя ºÀ~Šñ#v½êJ6è‘]Ç«oº‰M<ßh#*Ú¨Όè„Vdh~s”mÕßúj‡‚j+z@$…1YlðÈ¡Ø®]ÝûINñpPó_ÿ"Ô¤)üýl÷ÍÌïêÎI„ƒ_f»Œê‹\uòdñ€Qç¹còǂúòe+`é"S÷·;?V#¾o{'èj]²PÖÊè,~sÄn1N#‹Ú­sKM5T§v¦¯Îî A]ÕõP­O½¯Àk	<ZG*)<ztؽk#8Ekôph§Îdéä-ÉO˜39c(P½z4f|:ÅXé¦Ôüi·)„žPÝO Ö¶$½#*éÁð)D¿€Ӟ´yªÕ˜Hæ'ƅW\k™±4µÀqT	ê!ŸÏ"Qøª¼<"(ÉEÝ9ò«5Ìò€àGØlÃÆ9ñÞÁÈ{›8î@§=ÞåtÌyÑ°EŸÈí8’:P·J¹|Aâ=²ô(*oxÜ֗'ò%Ýñ“«nâöv7‘ìÑϓ/§(Žž–àì4&Ël?p&A¨&©úÐ$x{´›Š§=‰5nªX'»éX½q»×n$j{R¯_I҉Xʮ҈Ì]’ð-»@ñT`r6JGΙp؎8¸<”#)s›ÁÔÆû¦+ù’|DxàBcr=͹!dºo—cCl—	bÛ§søù¼ç{ÄÎNæ{æåïÆ»|>ÇX,‰É€Ê_N9TèáÙÎÁfíÆÝ6¿ú)eŸ@GþœÚý¥Ây<ûž#*¤#¯H¡)Ïßa~k)ˆ‡Œ%ç¨ÇöD–>*$@‰zm5j–ŽŸW$'øÑ#)Æ°¢šm1wΎ-žÀ­‚0›$°#*Ôؔf¨[SŸ€Þ-l9æÅæ¸ìÔñB€ ‚-[–‹éµþ$ó‹ÑSBØr±š=,²æûu£’4¢øl[¬î@–n»í^«4â^¹&k¤›91–—SkMuá»:¤Ç“zôZnÐÔ·ö¶¾„!Ÿná•G‘²DcN½{Îá­Âj[åÌÍÇRiYCî×U?öWe¼9IÈQr´(÷֜.0S.7¡Â¨6™õð4©~ÔS’oÜÍ>†dö!¾¸Uâèk}ƒÄºÚ9gf#JœG¸T‘sΝªÊ¾&[ŸBÞTwö€uh‚½˜æúêèd·#4ôxçŒ9—¬57þÏ"”no­ögoq&ot}YfQ£ ÷·bIAâfç²Ô˜àf7‰!>G×0²þzeÃÿ×f+ÀÃØ ê!՗çBÔ­Laº…»”i&¯÷אGΤá¯À“¶?Çׇ¨ßqWýŠó帻w¯Û<€Ú83ÓÝÐÉ'„|2À³²îíÜåÉY¯NvÞVÿqtò£Y:ӅñiÝê4¦†ïcù½Úuý×'Õê¡t“¥U¹0Zq¡rþ–~ӊŸÛ¯þ›v£ã.v{–V¦sÖHíuÝ0Ós÷9[ëÞþ@z„'þ_™#4Òæžî„"Ô8°ëBÚˬîU=ÀâÅåd‹þ[Ós‹:"rÂ_ëðayÁ©N<ØrÄc?¾Žw_í¿Žµ¤Ìn·;	¬ø™5š×ËvÔ#*ct(W.7I ï•ËÌ7ˆ žw#*µ_Bhžøªˆ©«Ò>€³wFùƒ­Œ†ÃŒUÃæpŒÐcšA!múÄ pqÔJQ1ü`ñ³:ܤH¬¥òã¯âW'‡ï*٘cJ-XF×h6§|5¾$È«\)Ž±W)SæëLc6JŠ‡»¿>o§ªaD”ê™®q†7Ôñ¥Évç»×xùo© eŽƒIÖõ¶=Tœsv°òF+;\‹G#5sÆÐy#"ãQjbÌ«ôh9Ãå—ÿÑËevzí¯êÑãá;ÉޒÛ[¿ü{]ç¶Xå“+wµÊT$¥€icUÙtŽIYY¹%2S”šaĉÍÙÌqóTXÊ÷êB©àŸáÈ”uF™Ëo¹ü™ÎÌ©ÂdNÌÏ`ŽÅåäÜp)EÒĀ°}@´eäu^  d›·++¿êíö)Š»’¯Q#ÊDüPhý—¾¥7¨AM±"°œ—û1'@¥E™;vs%kÁ­u¾½õJË@Õ÷(#)7î,èH¾å É#4Ö²&Ý&¹À±â(yzèyÓ])*Ø°R·ÀÆÈÈ=²rJ\êêÃÚsÍò˜ÔÚæVÝ¢Ei…;ÅP)a#*Ù««øtæXNPÊá/ßæB¸öüh“Ä´,Ä´A'€È§»Ìx<‹±Ðç—,íÌFûm².$¡…‹xÎr\/§käøî‘oéD¸ã§ÍñÝJú«]ö8áãù	ՏUµ|ŸëÔ#*òGº®=RtÍk×½9ìõàìã©ÈxÉÍÅ$’¹¯5~Sý‘[¨3×ڝ¸\Ȭ‹Y5zNâå6v/#Ô¡Ø%¡·ÌyÂwà3QtÚoÀl5ààEP‚¿Óÿ'Ï|v€{ðŸ67?Kûÿ„°/öÿÿ÷íÿ]cóû¼{2œ`˞F¾¥™zÛlÊ­5A2¼„ác¼ ”ñfVâØA5ŒfÔšM;Ž{£Š*éMºkßQI#4Ÿ*MÊjSÔ_#)‚ßl:÷JLír|]á»;@³íY»9E²ÜlÒ,ç4ùA g	½ÊöäHuF•îþp ~Øòz²8=ÙEg—¾¼*Gše(ًfΊSÓ×)Ì[Fý"£‰ы§[®ñëYÓ¥*—›åž”h;2-H ñªã¹.OǔóR_}H¹'…—ååæüq’ó±áϺ²¼ëñtì°æhä°'=v—3jê„ÀY¡Ž£=ŽB;	;ø¾âÿ*üŸNó€ÿ¹oÿÿöÛõ§iüŸÇ7¾ìÿµýŸap灬@ÆÙ÷"´m§ô#)öA€­ßV‘Âÿ´srZC#)î:!@Ô|qí۔ìDð¤oBø||Ì`ÎÏʁ<®G#ébñ¬Êe«Ú¨y¶ý@ŸXa{ÕãÕa,æ?¡œ‰]ŽÂívS:vÊμÂ?ï×é™àxIoG'üí)£ŸÎúczãŸÎúwüöX½ÂTù-fi¦²J3ÜNØ"‡ƒäÆ@#4pV¿ú„îoѵ¦ …#ó°…ê!ø^y{´—ùŽa¡ÿîø¸zBqù»úuzúžù†i?ÖlÈïîïŸíìÿ×ÎÙþÑ¡Ç5«kwÊM7C¹LØ6![Ð~.…ØÂö¿h)éMU½ÅÝÖ¬ä$4Žgmæ¨>eë	wšº’Qb Yè†Ôxmª›úuKCb*3£N¾í_À8FF¯ÈxIÖ8?OõŽ¹Õ«9ÖVñ«]èù£wgVÌc~$£¤Œâ+a†?æÛ(j‚‚FT$j­\üdçÊÁêà×b®‘á¤?Š„:jìbõ·'഍!珞²ð³lâ0#4ÛÅѓe·k+mܟ;’66T2ÅIßi’Å}¼#4a¡|9;í	©…$׎Ö#L›t”OŸœèxw8ÉÁáRRWü¹ø^)@­Ú½4ˬ€~æ"…uµ×e‘“„QjþלÖ\·o©5jä؞ÛàG5ˆVךÌ3ǙLÑ¿iE‚Zaì/¦–d”"â£\fI8ÆM$mN$W<¼¦`¹Œj2Tj’ `ý!M…íîaM¥ˆ÷6U[¬Z#*UX#L#*èÈĀ…X7Nø‘bI#ð9݊%Z+©OÚÖô#N¬ü~¼f¨DˆêÛ·†„×®¥¨FЈF纸+@Bmµ„|¸34u JϸV#*ΩžuC:Éæ‰äI®´Õ •„™êýQöÙ\àœé5ú­†7ۚ²=”(j…\ßÓÀeÐô”‚ôC© Úú´W$æʌ»³ŠÞAÎN¨Y=ފ´å£6+~e„(s6¸µ}Ò§añÉ۝“«'VˆŠ©_ìØ*\ÂÞ¤s°Ò;©%­¤<ØÓ»)rèâZûrÿpoÿDW\Ò½G÷@&:«®Úё¹-åøÄAÎ8n©Ñ æßÍ~á>I:)2âvö@g·9ýqÿ8~[Õ{ž¼;„0ÛÜDð²fm–5v%lö[qsîîzý¡æ'Wí^Ø|‹©ÃÄ÷¡bLZ°æ Š¼´ÇÀÊ¾”L/䶺r¼\•Í-¿i?rðªvy\½D;!’êQ ^CZ›°å¡­´¿õPuàE™®[ÚÆ%É0”Ê9ep¢AEhs–7x$W6#*µj‡aR3‰˜P|&†Y	°†…Ï%ÿ¹üþ?€ÿ¼¾ùìñzVþóô‹üç¯çÿc¾Gú^Fò󛮅`Âkéy®AÿE#4Ê{ ’sÓ)÷û§J1ȱú"Çn¾y#*imǖbхˆ8cÙwð6‚­æé£>ía$ú\e„,dÝN¼W}ùŽ>ÿƒ4sá£[H„žÇ)/º;õ1/â¼¼Ø}ÊC2³cÎˍb’›s^nZ×Få‡wññ0Ñ]¯tóÑèè~·&Nޝ頩õTHä;ßýU)ÌRSÉd€>XJ{Dµ§•Ô!³#*å!wܶõƒÆEˆ~ž¬ zP¿ñ¯áxû¼µœWè½;÷b#)&t(^ ÛLrVY6ׇ<7…¸¥š€šð¦)Ž;iO*¡$P%šw9Ò4ŠLýJ¼µ)ÖÌgÚÈԉ…¾fi°B*¯ûèki›Ý]G”ŒÕ•èP›Z•b•®k>u‹_ñ{÷ݪ!µ˜wƒ}äޅuò.È	°C²sõÏ»9söÿFÒÿìÿO62÷?O7¾Üÿüåîð<’Ýô+| R‘ŒóQë„õ°k>~Á$ ØÔxwNõÙwçômž8_¼sš>%CˆuD†ƒ£sӑà-ޅT †ø¥áOÂNjgÒÿM”­«¶/`}Vuº#)ÿ\yG#)¯î‰ßÚ­v1¿cёjÄgnSµÅ‡nL@§î¼ãözŽ;‚M¥YòW¿ÿ¿ë3o÷ù|¶™¦ÿOŸ>[ÿBÿ¿œÿþðóŸLøŇÀš¯â¡«Äo¿¶1÷D¨Î'÷å,çœ#*UÚÏx@üŸv8\tðûM'ą‡¿ßvL\xümgÅLÄÏ}`̐wjÌDÊ=:æfEçÇÜ/ÙCdz†>à$ùúðœ$_qÂbßöÿ—#*9:¢r½Aµ}Zɺ5-ä¼Êyø‰#*ÛOn` Ä1tânûÁóõß\¹kr4€ŒfL=¥)¨B{Vû³A[®¼¶äƛ¾Šå~ô4â8ooê+PDÛ¨‹¥"½öôÒ5]FÈ7Ýd¯¤@„„ý ¡kál^º¾¼&dŸG‘¿îÏ?©ëޣú¼½Ý?<:I…3·ûæ úSõ#)?<à8¯ˆÿï<Ó»¤;œwºZ2†Õ‡q2»á?UmÖáÿZjzÿ©üßæfFÿóé“o¿øükê~g\GËêSw¥)ëb¶}›-"Ëý;8tM§?Ñ:3ÉdH†°lLS%C&þ’&òGìPè¦Òʱ#)¨´gmŸ¿æš mª|žc@*¦´~£Y.(paa·¨šyoq¼#*zödÒ°(ï=8ÚG¾ïs²ÿÄO›÷«Ùä&­#4nµÃP. `¶a‰À­;½A©8º^“ÍbðƒÙyÖáùcá#,`tUÌYcp9ä¤ˆ	†`!M]Rº¨¥ÑB:¥"Åår삠¤%ST^Ý39¦k¿1'×ÂÇö’Y¼´Ä¶–¥Bb¹ÃìK‡"€¡iÞ¶¼–ºÕ˜µ8¡0!´bI™ÉGuƒJË×ùËoÈæ²1ihH>:à‰˜ïÉÎÉ?ÎOãã|1ÃøŸbÿñ‡0#)‹÷ÿMø_ÆþóÙÓ/òÿ¿ˆü'çÉ|zù$/Åóü!»Žá<ñêdçõÛêáYä{ò?¡xDÏ*´#*‡’ìWßÎbÓäq|rôúdç­÷vgÿÐäQ=ÜÃ$–¤©yTGìk"«É·ƒ´uÐ-KÈW»÷ÚB¾²m!_¡-ä«]Njl!UÙy¶yb§­$ÓÌgÈnq„ÎBÇÎ\G®NÚ¼ÒVð³Ì+v wŽ1¦«y1–ÊKRÞd#´>‹Í<P–ÇÙâÇ«ÐÅÐtNŠÎѓàùbY#4…­éH‹Crc>,že—s_̽l¼4W¡ŽÈi‡Û)^Bq#*Ö:™Ç<t€ÉЬG§i´!}û§dˆ”¥Ý"H%ЁŸSÅf¦v¤.(¿ŽÅèE¡ÂñXÞF³îë[JÁÐþ’JER'6…P,UÿLªåùÅè¯uÕ3߯Ûyd«GÕ²º8uéGÀ<Úá¹5ïš~‚9wµËº î+^/ ΎÖÐ+µ452cÑ­/[þ„ʯç-ØÜež^¸þ¢>r…ßnu2ÖÜvŽeÎ!/§_ô	ï¦Be™OB÷ßkâF°OÃé¤Ì)BMÒRÃBÝâ:n³(CM2b$—rc:–y%¼ùݒá/º#4ÈôZªù—ÕsêªZ4¯ÎËvù‚°™ƒ9ý0‡¤Å­i¿Ó	,M?l|#rח#*ßñ\àjåƃÛæ•ã+>rq»{ã#>È/}‘_œóèÌAyŸè+3A,¤/VâxPƒå•ï1Þ'ÐÔWÀA•?´½A»®g¨zžªåÜ £#*e²€´G3F«Gø“ëæÅÙ|<á.'x¾õô!ÖC1Ë%*c8&Âç֎ànPC*jAw`aW)kG贈4®—\àr0L»úΤ“F¥SÞ¶ÂkÄρåØç“=!8®¬ŠYÀ.~–s3Мè±S̹ۡÄÄ*¤nè$×¢QÉëÝÝxïdÿ§êIK«j_ñø¿ì»7ÈéC¼ã£ÓýŸå,®þ|æD<?]=’¤b!Mbìq;R¹ќmº›ÏY¼tº&mq´9#ˆ*è™60#)|;ûB;Ë{bªir7ÅW#4‚9Ý,'“jP6mkGFsˆÝu/͵üê¥ù'k…ª1%/G’’œ`ù–¯bèÜ<”%>[?¹ŽSæ‰{lž‹ÍÏÃ<þms‡µdïYµY=g•þv'!#4~/oÎThgUF#4šyqL¼<ÜÊ®jÀËõÑ¥Wf§ÑíAeÖ¥¹±ã£--¶¹ãç•p=šµ8@øªë呠øG³‚q»h¶ÀýׇG'Õ½¨6†ÕÕ\®ø!>5ǓZ£üïò­—¿?¯ÔWÎ+Cùò5ÿž|?w/úÝ=쟞mq‡GðT/0’1#*rä&(Aί·!Ì­3žH-¦°€oòóu{<h÷Ô[£uÓuÕ[?¹#4ó3™é@z>Èã°×b–8(È d«!Æ¿l6W ?OòºÊ¤N Ý˜d"²#*|L÷Æq÷r0·õª×X¶Ùü…ütOÑЉùd‚KÑìZœ+”4¡ÒºƒF/–UUw©EZ@òÒµˆ¥ ZLßB«m‹ïY…ÓãÝj|t|æ’ô_ʵƒ“é?ÿ]G|Éãù±NꢣèÔ`2¼ÆKfàƒÇ!=£i¸Ôƒ¹-w#)(NÀÈǼsB#4tlm­ùFp#)6>cDì¥ÂÕÔÅ©ÉÃ%HΦ=ґ¦üIDµf¨j…ÜšOœš‡bó;‰&ˆé(¦ŸÃæf‹qät­XB±ŒèR5»³³•[تô–ö	©ê4ö}nÈԙd‡:²Av”‹ÒAÀ¿k4Lº3µopI®º@¾ñ&<¦~Cû܊èFВ”KÉ7Z³ÏYv–­ï¢E2o¿ojÏx4i´ZTñENJõOŸ1r¢àQƒ³˜l©ë•lNj¼ÃÀëöd"@äÌFN“n_,R-Œ¹ûå<›Ÿ,è¦Ãb"æõˆ#*aG?âÍÙ¨•„»÷úöj–ÄÕ#*Ø<µíù©©Ñiu'¨¥€Z79U?‡ª§Ut‚w1¼öJËIà/ûžxÿà)çàÀš}ŞÏ?½ÉÈ«`ªh4—EŠV¸ÏÌÅ]$ggJ	G\!N·f¹x/dddM ƒ‚‚ß9|b­]²¯FßVT	Ôù!ÿÉt·Ð.!Ç`2۔žUÙځÂ?å-k=äœéï\¨C¯‘xm³s–®	©ÝµCetL[‡Œ†Éìç.0rm›EÅÉЮp4:RB…éæDÞtuŒ˜îÓ÷R@ŒËce«,À*Ò9Àî½;#‰ÿîÑ^5*‹ç¾yH¦cˆ…Yv†ÃÒdâ/‚P¬/9rÄS@9N¨RèúÕ[.±|õ#*ãdÛã !·°Á9QRHD@Ò#)Éq.Hd#)EÏÉ’yù™Òs_þ‘*ý7¡Bè¶*KZPr<¬:7F%_¥3ú†ð49É'—*‰R<Áˆt“Ïr@‚ýPF	„”õÆM¡ÆŠžsûz²ª‡?¥ñ´×ŽRy‡@×aÍ£æGwPiú!¹×ãÄÛqŒ5Žƒä£H7åãÌ4I¢éèrG™ävv~&¥#äQIUTR”ö“ã]•	nÁñ/â6%寉\ðÑù8Ö.Ÿûª<GžÁ$ib`‘$iÅ°HàYE9#²“¨iؚ†M«¼6MK	OÁ|iä"r,ÕJÁêt•^”ò§8ÆC2Ž}î5K¬š÷¹%’Ù©ëyüH6SÅ%üî¬IȖq•i{EQ7‚­tr¯¤xžâ<kQü¦a}t‰<›DÖ¢&@w?ÝæHX2lP­n1@óh_z#*†ðã#y·_³Ô/ʙ>Óz?Óq^옣»T7Jwöïä8ÜN¹Ô=ý·ÜD©}P\VÝ©,›3@M_ô:ÒËò¹fíyÆ1va”e_Uùš}bt'ü]aÔ¸DË:qÎþ,Rõn‰ñ*…8TøŽ{®§lYúD bµûKɑĿñNiý‘ÎÏ#4vø)è'þ;³>ñÏû¤?ŠðyÞTî4K|k¯Í#Èæí1K´È#*‘úiUŠf£×󠄏jƒ)ðûW0^-X<çT°°ãÁÝþD3ë@0KùY?:®¾=þþ‡ó&Mþi€›C¦3ªÚ¶wkùàã#ËÐIKUÔh¸#vÞöۉ„Žt+¹*¹Ò”zÛ÷dj™!D‰0™å!Ÿòúӄð½éˆâщ#)6Ý)g’/#*NåøNîS|ÁéVkr²ÍO­ß”%õÑ/Ä…ÀÿŒþߤ=ûóíÿ7Ÿ|ûmÖþÿÉýÿ¿„þß0	˜€Ú`ÐáÁð­áZíOW„§‹îÅtÐuÜ(ýós„DAUžm8“A”༆!XÅíÚ/çµóz}%8¯ûh÷ö–7wÉÈY%ôF•Y0iá0Z¦Pô5³ -A>â.Yҗð“æJMÕé@§64d›öh¡ž”|¬¹rd…_åØ,Æ#*u|êV.Žóñ;¸Òj_LUR°åÁ΂»Çr‚L抓ÊN—k<jŒa£HaUbÄUã"³ÓÝR~Ñ°›*—ZúÜéÚ×ûuN¥šîf­ªÉ3Q;Ú¹rg؃6F:ÓÎJ¶(¹‚»uÆ]&’g°Ý’“°É @õüŒZ„Q=B—?~ÐýM&·°ASNœ‰Cg%ϛ‘StìCNïNøDt,¯Ô{5èu‘™]ݖxºþú&ìOf"t›ÉMÎ;^)w襨;¸ë%#4G_k”ÎkjæŸ×ƒ¿Zë2ÿ¨Ã%NLh@ÊdԇÐðU&Úeo˜$ä×(õüüoƒöù~«R0´äìâtHipb	cÆ.ÔG®)Lf“xyVý(øIƒUœžì¾Ú?¨BÍéæQ+EšQF2lÆ1	¶–ªrÊę£¸Õ•Ž½²RX¢HýÆu›݂¡›àýÃ=®”~¹·^NÖ©šNàÔÎê÷ÅU|}ptzºs²_½·Vn–­šI¥ë÷#)„I›©>>9z{|FÇ?³ê\I!sB*Œ›€d:eZHŽ#47;nLg.°Š¢ã|ËÞø NzÕþÖÐüÅ".+éª#)s*éìs6€¥Ì#)%æÿ…€"¸Bmá'áBMÔåTü$¸ÂÔ|!ás(,ԎA†—Çp|À  Ä[¬ŽÐÁéÎÉì”YlóÜ}×Úx	‚Y“v{ÀO©íX	µ\!–Ï/ÀLŽþÚ[?ˆÒíA<ù!cŒÜwÞ÷§½Iˆ;ÎÊ.\9J>õâÜQÛ{…F¨6YËC#*ÍÁÓqëx:7gØåpÊåú˜µ\Kë²4~9v#)ù$I[f[S[ÍÓ s«Å¢+ÃS¤X‹Ûñœ#*]_“ìx¤6Â'žI±=í?‰72µ˜ŽpFö¢3ÅhíB]9ÁNAídý–‘f›–‚òAÁӅXC´hÅÚýÍ-KV-¡suÛÝkÚHÚE(¥ãYӞM+V.AÈ­®C¨œiŸWŒÃß.Ùøۖ»sÉd^³ qçdÕ(yÝ@°«nÓIˆÄ¨Â	Ρ~ÝÌř¢ä([ÃK• Ò¿F¹ߚ£Å¹ü/²¼Œµ€—b˜"|¹äÐÁ,Tj^£sM¬n_EëÖjêV–\ÎÉ&s¦‹–±˜)]z–ìL¥äî 3Ì܉è±Ä¯9XÔöI6¼¼l£o‹Î°°h,)êA‰JejsŠ%9úхžÞã~:‹Í~#)•P‰øޜDꋵ	¨ûb¾AG±›5½¨:mî1¾ÎƄLv¶h³Õ9:¸ó.FäêIjôz¥¦£I­õQt+‡$<¢®¦4ÞÀ#I*Lù;Š#)ùq~õ5ß?<~wvêo¹]Ú¾<=›÷ñc*SáRMŸâL­m•ŸÔM<gÂúԑ¨E=ðRíù¢UŸz¿ؔµØəõV!¿“ÐGDez(Û;¿¿slAˆåjFæºúed%f	š‰nÏs®ˆ•Åþ–‚°ú&>S€©ó/¦þjÃÓ#*´Òæ¸1¸l—6BdhTŠ`u#ÐnÝ;Û¹DÞüG/¼*©oüS&©›Züo»Tnjð:Vøï1}L4CƍoñJ±ÒP vb{5l¤‰:AS]HDÇ'CˆHW&ANqRRq猿5T=ÎÐ>u‘#)EÙ?ª4R7l›Gw8M’üâ¶#)—Ê¢%}ï0èâèªLU’GÅ9ÚÛKi2u›f\Fé±Hïû¼ÛŠN)k»	L#õJ#4e#3¡1Á#$üSšMîVµAìÁE5%¥¶^þ¾Î±ÍÌ1§xkúŒ›$ÏM×֞hžÅ‘Tõ0„.¥Ur-ŒubþqæéäÁÿª#*×ze7Ý´‚„+†ڒÏ<Ï,‹ïŽŒúýn’@Ó¨#*`éœa%š³µbÏÂfêfJsŸÆTÏ{Wx¤zNœqš‚h;=A€QžæÉ]»6# xyG¸z°jÒj+&\Ü+HK®Ì	SfŠ;J̈WëÝœÜÅõüžgɒ8ÈOzŒÖ׿9õÏՇ&æ±ûÐz#)=±(')Ñxx…Ž› qE“Œd³qO¸€I§l©9ÇWDv|Šõ’4ã4‰{#*ëê°yq5=´Cˆõ¶˜ûÐ!fws‚,²¥(ˆÍ ¬ó‚Û7ÜÕÛÜ×2í¼["fÉÈá	Våʛ=Q+ôUJ•ŠÎcº¬H×e«àsv¶{F&¯çq¤Z’aà\²ºðܤɭ›†{̑¨Îc,xS²hóþ‘E’eý»R]Æ⺊ñ΢TSoâcÍPf}€vëVWçYÓ/.?älú÷³ñù\<,υŒú.$w}¦¦È|€'¡±|›Â̈́ØJþ’#ɼ;¢-ä'kç×(\À¨Õù¤2ýÌZxoI³ö'$¤³µ©æ½Å´nº£Ä½²€Ñ÷~Ú?fðw|°süˆj6#4á=.OŽïà¼"#å«NƒGi•_·Šou–¿÷JU`ï•[ƒß_<|Ú\Ð|(q“ÛÏOŸ¯x£†Çˆ©f³ž½….»çv’™3 .^/¨‡¡˜&2Q#4¶MôɅÈ-#` eF“NæÓUñ͉ÔýÑDI\Õ!'õ•åß¹—e‘[7Nà‡nDGILଯà&kѵ¶vŠ¯b#=@/¬¶XxF‹AêÜnyC0y3‰p^Äö»sˆØì²sèÆ^ÌWà[&#y–&RQ8)܌TåbãjU½êËAÈV•P*‡æ†&’«mˏTg™ý¶ÂMtn:i®E2/ywUÎw•Ovå Ós£?î†#4¤ƒ7Tª»³žÆ‹27ËaNþ¨ñŸ¿Z>‹²Wqî͝ì"²ì¹3jÔÇÙ±´G™²ÑN;•óO'ÐñnG›	ÕpÊÔsH}Šò ¶l"7Qͺ¡#*íÛZ͛‡z}˜'ó•$Z¸t#*WÂVp†	}Ísj*¡¿r—@«‘9)­fãIº“±HœôëÖB®+cô•kîñÔ1¿›#)ŸSšéš‘6z©M¢t+2̕ÊHߥäõ¨¾ZQ)œ+.›9ßÀyªÛòtñ¢¤Õ_­#4´SۉwÙ«ÞM~a^wၺ›nrÕÙÍ_éݎ4V¼Ôrq“ÜõC|	šÉ˜«½¼U”(×Â^E•9{T0,¹–ÜêÜ_´ZÀ÷–}}Êé’\jµùðþ°(o$&“"<<˜î¨a0‘#40­9]ň*i1#*ŒðmÞ(ÙÄ##4äz¦%/²x²‡/ÇňüMŒ*d¬Är“OՃ¿©F5òËÇ8H…Œÿ—Vó?áÿëéӍ´þï“g_ôÿ2øß®s—Æ8lýO.­fÄ¿qãÙjŠÏ=Ü	ц7kd¬ý{¸-RW1ˆ¢òFʶ·È†:í–c,G§La[“ûý¡8pjî"¦1>£`¹í)¤N„•6ñËCAÛC8ĺƒGz7#)ŸŒ~·gH¬Tû‡».¨èžƒ¦‡ïY ½=¸©ã;è›{ø&?g¡8…{+=tïMug¯z‚D<ƶë›~‰[1ªxÄWíÚºùå"r7¥#ÞìP#9°L×Xæ½N!ZMퟡ7lÀm圀–~ό£úÁ¥ÿkÒâÐØ]zÀpýúìqÆþãÛõÇ_èÿ_Ãþcž'Èðˆ#)’-A¤âwáCkw‹a¾™HZÖÄb¥î I,½kéÎ1uIa=±))+1u'±¹f¡œÞ•¨¸Ž¡¤J‚{\=9¨þ|æ+ùGÒò&~ÕàB*¶mQ8ϵ9›Í3Råú3Uۅå,‘¦Î’éÅhke)­L#*»è@«Â:zSW̕PN",Ô.¯¨?Š”˜Î`BoHøôÝËãã^y0„ñœñ ’xeüé7FºìÝÙþÁi|öÏãê۝c-äܞ'æ´^^ùYüQìA퀋µèºè}$Râ5´²d‰jÜÒ7â40Ž_´¨\	š"i˚’ãùYëw×ØfcÚ÷°6s$ñ—19ä†áQö$BSZ8)ìB|ìMÛZÊ(k¶2”µKñ¶u50О7ä„iq`yµV,·‹¸ºpçö΋Ë7­óbè}ýËOŠ#ls΃oˆ­‘ª².¾\†EAÃ"ÌPê*äÉ°"[;šLG0I±;¡¼PÒ˱¬X)ÛáËs3v¡Žù¹dò” tÎAË}R­¢°ÿÏêÁÁÑ?Œõ9JògHؚªÕÃÏĨô[f-â#) «Šè°Ø¦”¢Ö³£OÍ_­ˆFD=ÎÃÏäëÌ·»w.ìœ(cTM¬/ÕüüÆãjµoÚ=M']9 ÍNÕzN`hÚ´›äÁÔvºÒVú,ØL*‰yÁRbëð4ôËoyƒÁûõ¶/3'dr^ô—“ºäÔ¹DšR‚_;¼ÎtJÄøÉ¢$?•…{Ç`—#éhe#4Óê¨ì`#*ïIº7´eø7ÐÿÃqOëAsŠH•êÍÍüu9ù¸VM¨Ø5Ž¤>µgD¦?úËèÎM…4ï`éÚ¶;w¸œê#—¼¹hÀ­Ól^ÙJ÷Z­±ØU"8ͼ۫.HƒØ®Ð×vNª*Ùî=5§#)È¿h¦‹NïÙ\dT¬Ž–FeÁûQämæ6+—Êb«ZݱuMCNŽOvßìíŸP»"5‡tu’n?Úhg™d*VêŸâÉÜ_ÍÜêÑtbnAò+!ð!ò£	{* àÅñœWƜËj+á[9ô„f—è”+r¶š«voù§£v³Û¹õ½I{<#)¦‚)Š$—`‘xØ\T®îÜyënÉÔn"ÞÔ£:zt“Ôëy˜ÂK(^·Éæ¨é*ýÙç¿&,Ä6^°þ™þžl<y¼žöÿóíú³/ç¿¿ˆÿ^LádÜh¶/Íë¼!Ùþ;Aæòy¾²bdŠEÑ~àQÇ#ÞÝÙ}SO÷ÿ«mÐ!Àr^ðñÑ1©ãøe¿#)‹wʞf{Ý~wm<]/\ãÆE2ì¡û3æ#)ñf¸Õ·b±·N€õ§Ní#*›Þš„ÂNLê•P—yï&ì8σټê`îbè$2ÈK¢õöXs¿Ÿ'm|¿Dš5n’èW”÷·üGP<Åí÷ò‚\è–ÿÍ7üÈáßDðLé–wGO|‡Á3#4ÿ…Ÿ8ü¿èN$+~áäðŒ2Ï<ÿ·~DËvB¾t‚kÞù¤¾Rz±õÕÝòV oÝм»ngÀ?w¸Ý!Ï~lüU¶îbµÎŽæî¦}„H5#*•Se%8¯|M·ŒÓ¼»sZ½CûÛw°-ÃpX³~£i׫ø‹ hÇõó+EŠÒ™RUWQâv\_©•ïâsEâá éÚ·ÿrž¬` ü¤ªEɽ”5<üo¼r>`£a§ÒMàØ“ãµµÊʋ¯ïÖÎWà÷|eíî܇ž=?¯ÜÕ~l଴rîß­°")ë½£³ƒƒTÏ঻ÕJþ‹þj#¼ :øÅËÌwG¥bT^{䗂çÛÅpìõßçw¿Ôê¿Â6^/4¯`–$M˜€ëþÖ:L2ë[˜ þÖw¡ò{˜ŽþÖ|èÀÏ0¥ð³ú0{6‡Ðrˆ²ýâÖãï?ß½ü®_8:Žü#¿°¿G®»ÎüÂéÙ	l¾~a÷Í<4ýÂdxӑ=ªA¢¾‡;<:Fà…‘ú8.‹ëµÙÏu4оj϶a;;åW¨ç¾`àûi£·±]›¾ë ‚ÂÁʃ›WñvIu!ôêjàßá‡ÁÆöyk5¨U۔'”µ¾][-×a0Zœc§7lL °óŠ³¤T›jå¼Bq¬´VÚà…N½‘JýËÄÔ+NêÍüԛnêas²½¾BU¬o«Zb»7u»¡›`d^Kµ_Šççõ;h9Ïß^%ø¾¼µ¼u÷üyt·½ÝAàÿðz÷|ùî9„cð~X=_…?Ñ]¹|WÞ¾+CÈJt·¸[†¿ÛwQt÷Í7wßÀø?ü¿Dw[Ûw¢»¯¾º«—΃ó_Ï?"$Åóíóí—ó•óÕo¢­G_ý.¯—!ð¿Ï+u?$L&cMÛ+ëN¤&µ"6y9Ù^NyŽ0GpD¦‰®ßÔtד+Ô3)¨bÐßhⱸ݊`ª¸¼E“–HÐ(x›ú…äº;á³Ü=À~Õ+õIòõÅޙ|TúŒ"Í7G@ß󍏧ðfMTIŽpƒYñÖ¼e »«^þ>îmoã¯÷<ò¶á?xŽ"ï’ìo¼;	ù7ð€”:„­‡Ô3Âä¶OŠ#4íÁ´ªim`ÁQÓÃö5Ö¡6­G3iLkÚl#Æ[Rºiôâ#*”śôwH(ç"\hDë«A‹Π7µ ¡!<E0‰I³™ŸæB§ÙÄãpÄeRO¶ —©›QcùBD@ºªBWíв#4-Û¡+*tÅ]S¡kvè/*ô;þã`¬i#Š.ëã¢Âáƒl¢œþÎN§ã蔊Qœ¼¾±ò¢Ý™3ûÆÎìÉÄàÜð#)ïd÷(RQab?r[ñ‹Š9s«ø‹ë¹ÓÏÝ,ž;ߜOÛö§m÷““åv*K•gãùs»¶U†ííKb#4,”ZfM£³ºgwK™TT™Ø*Çá<ýv4¹õPPCÒUI‡bTÞPOŠ°)Pw)ŠŽŽEëï*Uòd:˜ h}Dþ‹ºüÐöÝçhÅ(•ÿ™<»ÚœQg»¤s|ƒÉ ™—9[1?ÐEŠ±vÊ؞úͪ¢Ñªdԕ£$•×=cÒhó€Œò9jfbs0A	:*Œƒˆ€ýÛcêôÚÆV·Ø؇ڻº±UתC7zI[h¼jàj阼̗$«('ª*ͦk~yÃ1#*„ ”Jë<=8Oœ§Œ¨2ÁÖÙ¼þûÁyý·ÊÄä!½Ÿ×ùJÉm8b'J=VMR	ªÌ"à£,!äM(å›Ä`YQÖí(\EÕXPµôÔ4øÍk3ÀŗӗA&K3Ãjõ‡,Ø03ã¬iëN¹éµ½þg¬í‡¬[iKGºŸ$üþՎÊÔ2yÙpþê·Êɉf‰ÙnÎ]<î°säÈ^ê8(‡› ·ÌZ	Ï#¨¯ª ú¦ž.<\›ôxåõ,Äy}CüÕÍf};â§ú笪éMøðxn?Ñ×ti›!¥¹Ù¼§¼ ¤	ª÷Ǻü¼žh*Z,Ëô…Å[¶h¨Õa¯fM"4Ž³ª#)#0“L©ûï¶JK¦#*(‚† Æ7#*[ .UÅ"t%Fo¢‘b%¥ÉF8Ù$¡Ò†#)!¬î±íGÇÄFM6åxå#*xPދ8‘NŒY’˜€0?ü$-}r“ÃW»¡ÔXwoÍ-ØÆ<BÉíðZCq¡xÝöej(åƀ礴ÖtïÞ7jõU(|£îŒ‘ôôʯ“ð¢@[D¼‘àåѹ•³6ªÐ¥¢œ¢Š4c[ížgh"‘Ù¤MÎMk»â¹Éæ#*ˆÄI"š@9:ßö÷õ  ‰'f.ãÀ¢¶nes떉óùj¦?/ڄ¹s‘Û‰ö7bs$îx85KÄt T–=O#¼ˆÚ3”çNPØ6ª8XËÐKtoôÄNLfCôžéo0á²åš¯ëõwmŒãô,œÓ§gX$3wÚb=oWu-	{«OFLCúí `ÝE?R2(Ù}±1§TÙa3¶#wúæ36j“(yd:‡ë³tIÈu“+„êô—…üϛý¸!u¹'3?X–Î=U }È!4úª}ših˜Á™ÃÚX{å‚e`-+;cÏÐRq¸S%¥$¢A¼¬œ4$,ЦÃM‘ª¯Ề|ápjE#õ9È93Y™†N¦ä02›ñ|†–"ÔÌt@úֈÜ[£Ì¥Œ`îé0;î}}›3ïm+¦b_ï¡`ýFõja¦ì#4ZåÒTè™x‚>¢#›DЧ9óó_4?™6¨)ªV’PŒåÎKjÅW6ßü¯Õ#*;3Ú¤%‡Õº»÷;_6êH`TYÓð:‰pˆkú[ÍMV¯ë™#)m×cƒpÃü`6Yÿ²GÚ#*N©‰×r§é˜˜¾¥úÀ´e#Â8µòFÝZ¿«{>©¸4.qIÕ'Ê0xõVܨÚ3 ~Õlr<qAGæeÆOè€8þi'Þ9y}Çf)-Ý4bꖚi9ZèµÎViê3âØ‹æHv{Ô¹£I9™à)Ëj££2²ŸT£´9p#)/%NN†£á¨äD¥ÚAŸÛVôÒŽ!ƒÌœÂ/O›'êËfÝ¡¼yìÎ\= n±÷	‘oìûÑä¹6ž›ƒV#iG>®æ‚§÷s¬S‹gÛôòÖNÞʁ§ê,—7ÂÈ9¼ÑÜ©l×v~euó̈Í`‹ž卐þòX3êîå@¼ÁMãó£ê¨Â궹‡˜Z=xˆðI°–<9[M†TÌ´1i‹,Iç#$Ȳׂµ¬YìEEQ,~³NŸ–µ<›.I‚G°ï1â¶Í•‹öID•§ýb&ò1¾W~Ð%"”Dð¯Ò#4,w¬96HË<³—윀&ÀˆôDhK&#aÀ„¿Av¢ öi^ýŠÇæbõAbî#%¢\RYぃ˓PzÖëŒrYg;³ãÙ‹aôîáR¦Ýb–w–¾ÁàJ[µÌ©™GŠzóùjF°«x&¨T*Z•©š.ÿéO(zÑY„CÔk#:Ι#*é»ßÔ6¯´™íz«#4ªÉb‘àÓuŒèÛhºx¹\ã¾EtY·”.Y bè1Rjã“<nÂZ­’ Î{:ßk%ÿŒþ1¬cQ É襔ž—^lUV‚mR‡b ú˜ŠJHJ\þšZö#“¥MØXÌ˜g}³½a)„C8žÔñgc‹ömڊR´gÞþSóQuLëNÚ¬˜‰üù `A]ٓäD;u¥™e…-,Š6DÊ/\ ±aÀP[}ì}Å#åSC`%"í¹ÏŒ•׶­ï#*ð{šK¯ô0`T‚OAe,ÏÛ¾uíƒÐʅßÖNƒeú,Šž«œÍÝÝ“	F‰ŠIÞ#*o0…Ã(æ#;죈´x,ľqKÆ´Ñ ómJ/‹ý-k–Cœ(zœ.Ä{Œ,?wNåª=ku/Ö«µ¥aÄÍ­z¸ñ̚a™´à›•nB™”Ö#4VaȔ¿i—°nãÄ=7Ã#*%÷R	¶»º¾[«Ýº[ˆ^’ð)TÕâˆáw¶±Ž²ùW·Ï¬EUk֍‰ÿíÛÿßÞ³ö¶qc»_£_1Wّê‘jgû#)ŒN4u“ Í±Ó[@kdi«Ö«£G,,òߗçEÎp$¥›{[#*`k†<$_‡äy8eþ}Zš&ã™Eìw;Öʁ©f ›2 ‹6”ixEépQö_@r7΅éTL´Û±ªl&C4Í"6X·u:ÁiRîBÖΖp•ƒ\´Ë,’Âu"(»»#‡.úzm™Fn.‹UÞеe²1ž¡S]ƒ”§JvJFjFˆ(ŸË³Ë„V<,	ú5É­˜n J3@7buÊI(÷r<=Ö°PeÁ1JFª¥›ÝN¬S5'¬ƒÆR(ó1¸ê†·/âv¹¶å›ÉûîBq#*§$¥ëFó#)Bå(S.įe± Ab7¸ž®yGÁ̏š&Q=fV˜®—ÑQ÷BÎ!uïÝ(5¦tŠóÙ"Ý°óÞԚ́PVù÷Ù(Îb¶xx\ˆï“)ÔÖ¦wj .“MÏüàÍe£ø	ôéö:­ß´½*“@ô Ã6-Z³«_r²6´È2Ô>͜6&ª´â=V²#4ˆ¤@E¼â0…a´öÜ=6úuÍ|»oÃÑæ'µvÁ‚a.>Y@K#4Ï#)Q‡®#4°˜‚ÉÃÁ­Jàзofµñã^;¡¼Ñ#)(I²)±þÔ	\/ò¥3ºùPÂÈjäà&f¾¡2KÖDÜÿz&]0#*+½.ﺬe‘a0Ú,Újbsgj6G7.VØ*I¼CmnóMÚò1¬?ºg@k×3z¿ú:Kva'oÑ2a‰™ŒFã¡iX¥¥Ä¹Z—-8–`#)‚g³ë–­üÕxè<ñü'sG˜E1ÀwbKÉjd=$¥‚j6m;uÁ],邮ù®C×Ãב,EþÌçÖp-68›`J%·&(v4mîè/ ´“Él+³Ýžö¾µT¯·\£ä$lj¸#)2Âæ Eê󟬛ÚS{3¥ÅÔ\sªRu¨¶=‡l‚60h¦^Wøñ›Z7IîÊ3Œ0á^a?ƒ¶nþ³_¡åŠ”ê!Õ°s‰W%6Ή`¢g&iÏ=eÄÙð”Ø´7'VܐaÜá'{®Ý-HÕvèQ`{7å^ŠÅ‰*+¨è¡c6pB\òÀðžeó´b¤[ ¶#)¬%k3°)xÈ`€sÊ2÷Û$èqՖÜQ£»X]WÌ;à‘˜Á|ŽQ ¼m#í0'Ugââݖ‹hë×h¯…þö•ðòÒPÒzª]ÄÝ]hP)•Âª¼~#ZïgD aÝXÁ#4Ž(T,Ï)-=1ЫôQŸŽáá®Ý¯±1Åv€Û Ó*1A§"–ô¾j·^.B¸ˆ•ù<ÍdŒæM½®f<ž´1n­Sëc€¼^dìB7Œ¢±îR¶Í¥Áö#*#”Lþ¡¸èûå<ñ‡#*-”k$Ü®6Šø¡aò"ºî›L‡ÖêSðë2gnÊ`cvçHý/ÆÌ:’PW¿X*VˬRØ	‚DÓãS2‘µF`Û¢Mxà´äÙٔiIw&rXÁ¬™?K#4‰xüîì{3¤ÈŠ&H™•¶#4¤Í ~_¯Ö¹×Š)5Ô†4ñԏÎÄ]*,¸…[õÚ©ÊÑÞSx7Ÿ¦<ü´=E×óå¾f\¹k/íGÎÞ1ù{ªäÞé8]ËîAd¨Z­µ¿d„cTôS9Dlöx•Çn3ʪ7v)Ŕp:ÌÚ:~DÐ}¡BÂa#)ܟºK²‡*HüÄn~Oc¹aÆïE¨ºkw0Œh•"¨4)øà‘¬Á¥‹-„†;~ ?y¢i$UÖRfŸ§é.°'o)>0a.	BERÁ³¼obÀÚiùØp®4guŽ «MÌ㛴ÈÙãÜÔ¸WîC^ÑÕ­'2R•B#bìºã'F¦„%E•H<ÔqŒJÆDVbûôp{L´OSàÈïˆó>8ð´*›GçÒÖ©'oiP¥‰Ïiìö¹‡Ð%äD×·vPxH®>é8’#)ð՜éð$ËZ6I xÒeV-åë7+D䈴ý[:t™Áˆú‹(·‡Æ©f•GZ#4ÏÁGË,õèå8×ÄzÞø#4ÝÚÈ] •O=¿ÔVsÓú$^²1îT†Óm;³ÿB±^ۑêf:ïNQ?b;sÑb5¸ò5ÍÄü»»kÂ*ה⚧Q|ßG….n”%q¦LÇj€üQ¯„½o’|Ž*æ¤b¶@ݍ¹|{w‘MeD`EÈ;ç¹Ó9p芖øBœÌS{äijcY¿Â†qnU±*ï$Û”œâ9<ýÛ_äñí?›×ŸÞ#)èvû/¾<ù⫊ýÏì?ÿUìòˆ9/¡†ì¿<1\¹áÏ4Jv`Ä<(M“	,Ûl¸7“Ûöô#*Zs Ö˜å>¨ý|JaVŠbqcx'güҞùšeëzt§®Þ}G’NՔŒ·jJµg*Ö+ÃZ[š:­=€)㳧“RÖ4úDå¼¾ru¥Ä]®s6púr­hp›i<·p§¦ÀUar:ý˜½Á£™A¶Í#4iç˜3ÓâBd:…èQY	åy©=—tŸ‚Yì§g/_<~sþìñÙë7gß?ÿ9%ZùÞ|1>#*¹ØúkÀö)•-¦OKxú6PÑOV/c'å0ýռiÕ£¢YžÞ¸M„©”3^	J|àGZc2<I›È°E'Åw²í=7å÷[èÔ¤ŒïGœß4Ã<°ÓÓ¼T”“±ÃÏßî¦Àðäwù cOå`Âñ¤Ýð¶ôú®çÞ ãøEøÆT¨ùÏ©	¹_.‰oa¼à“ËîûÂpç­A›(ò L‘«Ùp=üý	rR%T4D“íÚ¹‹,ðê-A¢1ʐ@—æNƒßŽú¼1DŠ'ðt†lÞk§Kʼ4YºÀ]S%B*kȒN#)ÿ%Ãî”~“˜POéÂ&„ßœ°ÛƧ¦ôiJԟf=Ó'ªbє®JLßåx—\ˆŸÊۇMQO|ÀMéÛ(×~@¡ð¹ØÄÇ&¢/?N’ýw6§m> f¹qUCZÚxíi‰ä5«¥–׺–l~#;úíHé7º#j]ãÌ:îz„¬âR]ÁUÃÈú½mœÜÚ¦@«½²â¦æ–Ä@”¨i=Ã琺'u©x•bK ûcÈ1|Ž&7JÅöê8[åRØÁ_Ú¥*˜-¦â´ú⇳—o_œgç¯Þ¾yr–†—r‡ÃPkûԏ`Ëõ[¾[f!îjVdÃÜ°EÞò‹bKºnYôÀ<ð¹IÓ‘àâñ›§g©ÍW»3eƒ¯V¸ˆ1’ñH՗Ïl+³XNJnçÙP­ÌŽ#)(–—µZç覛ØÖQƒ¶•¦‚7Ów:×øæOø&ßüy߄â›?ýw:9Ãz«@§³æŒ½ÅÀ{Ð6ë5gífh?>°ü%Ö!!*A—¤:uáppÁ¬Ò*Åê_e²¦(<Qðí`—xõúâù«—çi±96Îв̋NßÑG.ýx1̚¨n§Ø]žujíýkDÀ„±J8#*c2õèÜÊôÿëç/˜þ¯Y‹Mm–f›yyp“Oú›˜‰2{p™,¥¥k;µbãÅ«'Šp8z¯D§Cï§=ïÓZ–#˜~Mv“Añ&xü6ïò 9jHË«MIÄϞ͋bDÒìèä€}µ·îÑd†šÍ®0‚óîæ}+ËÒ.×Ý/7µo¿­±<jPP¹Á#¼ÒB/é•1}XÑíRƒ¬R«îîH¥i°3Zݹ`´t²[AZO^½x#*R‹çOž½x|¾¥	ßNAiQùSžžK;ò€Š:8+tXá¥#ÁïûuZ0\’sÕlïìdj´1÷ä„*ìN ßÿœ=q8é¹Tµ} ÿ„qá½Ã¶q#Þ½›Œãý˜ʵ]­Kuöß^“müG¹ÿËqxj „8a^ÔÂ5¿ùŸN'zÄߏÌ>ýa3b¦ÀDR÷Âa𚂣è›G ýð(#*Ó‚_‰î£3ƒÙKC¾Gæ›`aXk}4#*nü~Â#)Gä‡Å…¯&ü9e\ø9•HØQè7Ÿ{è™õ|[“î"»¬ñL%ÚWP$o˜pí¢ïmÃ	/Q!Œ`iXQ²­,"Á荄K´…Ñn²Wô 2R\•2Íåò#*õUJyðûßQO^ú´Ø2Œ5TÝ,j›£×jvx$_xÍ#5ÄwŒq&¯CÒ?35ƒ»‹m·ÈÛq벪Åþ§Ç?>ÿîñ… Ÿ½z{ñú­Ã.©ÆìI&xa¤20”×¼­«ñPª¡áÜj´È¸¡ÔÑJyzy”|»ã‰W#*yÛè}±ŽŠ´ä£Ëá¸c€»OÈ'+£[äï@‚¶I`NÄ~[!™øU&†™ãa…A#)N—ÛÄØ/oˆ¡§[Ð{•@'…8G6-qI”ÄoçftÁ‚X^NI"y}ÈÃó$]=ô«xԃ$â~ß/¦Úeû#4ÊÍ÷(U—é7&¥€fpLÅùÙÅÅó—OÏ©­¾{þ¦<¡köÙÕ0-‹©E­Å#*ÖিΣ«<ǹÍÔ%ꯖ³‰!$tÅM…Çh‹h¨7gœjYì̋jÉ×r–Z¼RÌ&©Ïò³Ò¯l¯ÖŒP0‰·ôFÖwPV«9Š¦S¥$ÛF[#4°J6"42F)òl>[,Áò@«n`×TM„<Þΰ´lÔì‹IÔ¹–m^xúýýïQš>˜åtXl:&»·Ç4™,g ±±½°òÞÒs´÷N7ä¬|nßÆeeÝ$µ§óÞoΈÿûHîû#*HKc‰õlöc¾c‹½õjÈ[›…“ÇiÔ^ïe°áß`D¯Aº7+‘¯ö–oË5œÚŽÙêÔ5ҕ!Æ8÷ŽaGV2U!UÖîûÓÑÎ+ÌRá\Å#4­H>f˜|üŸÌ9P¾›-x^3à{ÎhíÏgڕ»§éï/r$û—”Ÿ³¼¸4m‡!K™Á²>᲌EÂíY#*˜™¯Pª#*ãÔʀí¾½}Oº’·ï{ñàý0¾°ef>qF„¨_W#8›MYì¡ûí«‹gt-ÈÜÉbuew¹­=kˆ·‡¥OÆ.ïsè¿ùt0ÊY[µt‡X&KùŽÑÒ#Á<f"sn¢°u‘)*9ÉK>ûìö}›û8+N[!”iôd¾=º4lè#4”Â2c4TP3ÐÀX	r»àbµIÅòˆ§Öň•#c²`Çå1èÎåËùJ{Âe»Y³›;¾¬´¸ÉÇãP¦]G±ioÞ²£ßRïÊûƒî|éNnNa¦„Ÿ¦Ð“ºByq…î3ðœYL(vœ:°¡5	M¿5í!ìÁGUR<ĂV 9s-û«/Éhló]Ë©;A𥉉kÿ`	r,.Ùóòo]݃?çÆ~«§×v=rrЦ.òbnZ&WþaY>"¨Á´Äðí$HéhOTb½Äç§i 4#)m¶¢ŸíÌX2h"ñB6AK¤=FvÛ.+°‰ˆ•;ÇJ:ÀÉðª^†7”t’Ah›HÂ!®EQœm&sFÞ’À“Øô¤‚°÷÷œ”MBdÐ=6[E!ºô‰ð†+­f½µé-«¸wãÛ¡æw'ñ^–Õd_ŽíJ¤Œ¤jL¹çÂ6–üM*>qk¸úV’Üb¾+RßCeF2èñsâúx›''G9¶Î»¢äÒ²Ú$â²²²ÿïu˜g»àçÒøÄpqéVÆâ3Øãÿvxþ?Èߍww´ü÷ñƒã¯¿(ûÿ<9>9Èÿ©å¿=Qmè}V¸z#)¤NúÅ>2Øþj‚ý×Íîw¼,zH/6PGGY®-á-¾¤µãÉÏ?Ûõöc&2coî-“•^êhöòñ‹³”sPx #4xj&hômñYÛEÚ¼c†K̾Ç}#*}æ¾ãÎ#)|ŽÏbwiO¾°3„~ëíWŠ	9ý&¬”%Ù\1CüúõëÇϲó‹4î<7»=de#4üŽa5ŀ±pIäÀó‹#4U!߸ ÿ'˜ŒD’¼ŠB$!þyÆÇo~8{#A• ç!ܐ›ª#4Ù_Ë1ÕØÅi¿Ô1ÓȦ_€WpH}ýúù“¸š¿#4Í#E˜ÿùÝüz5v…! +Ê|Ü7[öY\Íq‰9ÚtË@º~¼“{¡~ï1ýÂ~º¤DAÄxÖf¨xáÛà›=ö­|X=ÿ4ë?ê>/>3a¤ÿïã㓯OÊëÿW†%8¬ÿæõÿ0ôþÇ?ìLû˓/ÿÈñÿà'_Uøÿ/¿þò0þÿ#4úŸ‹M¾§ávÎó%êuZ]ÏóA1šÃ!)‚~»‡‰Ý$/áëÍj:͋„Õ?YY”•Dù>¥aJíNfÃÕ8_ôbe7‰®\¨ä†}ë*ßu^v€°ÉõQ½®„‰ã7?ÚÖÍ#)ØwêdbáǏ@B˜üõ£,ulÝÌ»d3±ðãG)M½T‘1f|̛t7‘ø[A	„b—wÃՐ›.³“Ã8¶!ßþø‡Ôo36á—Á¦°%â°ý,(,£< кƒÙ|êÝa^ŒÖy0#*HG™çÈP‚oõ¦ýa¿A¯sÀÖ]öñ½q¸‹ÿ…>(I½ºŽŠEˆ&ey(å4×ÂpðJš¡ÔE–…Ò:ù›ô¸=§û’ìóÑÚ&äèB­Î핣#)ñîhÈ=^à0òƒh74²d™»3Ÿê ½¤CT' #)%¸}‚B#)w¬u‰2\ã–"Q„Ü%3#){à¬n‚¯Óµé"¬Ÿxïc”ü7 	.ò`94èËðPDè¾~þúŒD™S.À$ȋ¢>›™âgó|êݬòåënó&«éh#)j™mt=À&I^ã„im²TL£ÎQ›®2æ]ºFð%ªˆ˜XüïMïÒ&ˆE -¶Âse²×‚¦Z:Q¤R¨Ô"I!§R¸ÉNU¬øŠÉyá~äºHê^±ó Üürf–¦_X!Ò3Â0?£äֈE:HP"jêÌðNŒÂµ›ÑÕ&jb¿Ň«#*Y—Á‹§fì7ÛÛlÑWWRªÞÉeÃtÍ®•	¹ââ~¡‹ƒ1mà=€qm®-<j‹~Ó˜ÉÝ"xÅG%[žhL6€´B,Uïd7ÇÔÂ|¬Å¬_#)×ÏθDx·š=Ä)\êö^º,FùZ#*s”î#4L=ڗt#)˜íEiX‰úEù´X¢¶ªÊ½£æä7©;^Üäºe`,Mú%•hύ†Qö7qÂm·?!…T©¼ì¤üꊗËtgÖ´>í#)Üäƒ[<¦Ú•!œg©Ü#)‹%ÜLùAuåa;¦,õVá¹EÄáҒx\CnùW“Côj@„5ÑPs›…zU–„Ïú ÑPԔÓ@1Ž:·¡ÅH¸Ã~’Æ>dQ×}¸WÜ4¬ÔU*òEª?d`ƒ.!#*¬Û|CÚà<·šo²ÌĦOžàq()Հ•róGÞäI=”¡}mÌ%ÈJe™e)¿51[ÚµÂx  nCISº÷çóñÌV¡x4_ÏÆÌøBµB'ʜ9‹Á9 «ÍP֚<|9°-Ömùx˜ê6ÅþŽÙ¯Ög·–ÛAC”ã¡#*"Ždîy§¦º:`‡?ËN·¥õW·‚L>7UnMù”œyæI	˜º#41æË|°üHPFX~ÓɋZlbAÀžg„#4ISŸ¸(}·*@~MZ¯—(#4áôʃR¦†ÝšçÅrÓr¹%Ž«oۂÅ ® ±_u–żü¢),XôÕxXW´ˆÇí]4ååMa^Ñ{ÍêæößåÙÉ®©§Ì°—ïƒ]ùæÓ!æ#4®Á¼ÎBû@7黅÷Vr@b™Ž&?ö”MûѺ_´ãD”4v#*Pê*Ÿ!̈pYÎæ!<L0ဠX<u—OP<eĤX-ƒdX-±xmÜã­&7¨mt	hܓÕsÜ7«à#*ȶºžaƒêgÎWw"XS@½AŽKº²õîB(I‡ÏXÖÛò¿"üžVÅÁ%ŠzØ`˜ß“’hœ­IÑp–“¨~~gŠ‹úÓ#*êD·VfÖ4I‡Å+Ë°/“™a¥j¤Č,Øj#*Ì#4øɐ¶9î@¯XÉ>¦\¸n¯Cµ¶^êî®RpKñ¬ˆ©l–ÿóوÁ#)ïT•›‘=iÐä”MÔ® 1¤…’ÂÖÀ:ôá6ÎÜ7YR6ØCSÛMáW$#;¢Ð{o¶#ï"†‰Z*ã	ÄEÜ&*:é~M@cRÁ¦ê]Ù¬2v .MìÅâ%`gÞZ¦SŽP±Ð)û×àÀŒ½7%ªÚÒ!ÎæÆJÉ~mµÑ÷*çŽ]’súÆô9rú”©?ðý^CžY8Ÿí'IHÒõ;Ë¡êI"«ú#*Âõå@&ŸŠŽ¼g¶6çiÔÜÃüם‹,؛àdþ1ý_ãÖó¸ÃÜl°áDk˜D௣?Èñ,Æ#)â` óù\#4$%—¶“9ؔç×Kq/"q¤Œ““e~º-‚D'¼Ó‡^4zñjØoÊTuþ…œMÝP‹lBÍÁæY®~A”Ø#·ùtøx…›˜$¶ÝÍ÷mT5\ùXàDõSköˆÇSá]µžÁ‚0)¿é’ì|O^ºZRgµÖ#Ü	’f‘Ãi³#Ñ"|2Ü2¶b”2´²Å^–|¯U“ˆg…[§ß*4](¤BÀ¦c’qÇ£TAŠžSƒèˆúT¡x¥„cUj”z¦$…~cêҋYþŠm)aýààɯ B$=I|)ÃëÝÝOu<ôÅÈ΁ÔX6#)ÇÃZéÜ,	U늏֗~tXèïéÙQ~'ëjÇËï`fÍÜt纟7WŠÕš#*ÔÌR£ÎM·”¾Ý­<,WFú µ>q#)„ݸ0~º$CRäÖåH¯>f€š¾å)h>÷§pG€Ê<X`­ZX#*dvÞgÎY6šbmÎwdǺ6¾ófT* x¬W&ÙÀ¬âUÈ5¬	·ä |±ll6]•"ìˆzþJy„$'S²%÷ TyLaµÕ%žŒ/x` ÄiÙcJe¡P“'`±ÔFø6h͆8#¸ƒ¦òÖ˸;/#4åΎ$¼¡ëhª¯ª#**·u×ñW.´SaõNy[,ÕÅÓÃ{¤ùҀ=))љÓÚ·>ÂÊZV\¡ŒåóÑ¥3Ò4J©Ši”#4Ñ~ÑÚ¸9$Ë»Î*dŸÜg—G¥£mçÓÀ;M~]͖9j£‰AN¶ÇéJ$ØvðôöÙãŸÎ2Ï`çškO°NâÖgÿZIŠšzI´C´Z•Z˜¬Â±½¥2k#)ܯS††2¥íNùNЭŠîK«Iә*õ#à”»ºóstÇnè¿UaHÃY´©å´ŽBÜX€O7p{¨]¹Àãéªz1žf)Õ]1Âá#)È#*’c4½žµâÏ"Ô9'ç[¤$g1|5‹Çs€Š#÷.~ÖßT³Æ½c(kñæ2³›wë_l³•°@…¢^ªÞ°›HÿœçÀì,ãÓò¦0±S+ï)k!`pÝ(ð/ùÀ°—c]~~ çòϐé½M{€,Ê-èïælúäèâøöÒîô½•@ìĚL0KÞ0ÿÖ<}㳐©“ÒÏAôóðžÃsxÏá9<‡çðžÃsxÏá9<‡çðžÃsxÏá9<‡çðžÃsxÏá9<‡çðžOôü~._k#)¨#)
+#<==
diff --git a/poky/meta/recipes-graphics/fontconfig/fontconfig_2.12.6.bb b/poky/meta/recipes-graphics/fontconfig/fontconfig_2.12.6.bb
index d4cbce8..cec5247 100644
--- a/poky/meta/recipes-graphics/fontconfig/fontconfig_2.12.6.bb
+++ b/poky/meta/recipes-graphics/fontconfig/fontconfig_2.12.6.bb
@@ -35,9 +35,15 @@
     rm -f ${S}/src/fcobjshash.h ${S}/src/fcobjshash.gperf
 }
 
+do_install_append_class-target() {
+    # duplicate fc-cache for postinstall script
+    mkdir -p ${D}${libexecdir}
+    ln ${D}${bindir}/fc-cache ${D}${libexecdir}/${MLPREFIX}fc-cache
+}
+
 PACKAGES =+ "fontconfig-utils"
 FILES_${PN} =+ "${datadir}/xml/*"
-FILES_fontconfig-utils = "${bindir}/*"
+FILES_fontconfig-utils = "${bindir}/* ${libexecdir}/*"
 
 # Work around past breakage in debian.bbclass
 RPROVIDES_fontconfig-utils = "libfontconfig-utils"
diff --git a/poky/meta/recipes-graphics/freetype/freetype_2.9.1.bb b/poky/meta/recipes-graphics/freetype/freetype_2.9.1.bb
new file mode 100644
index 0000000..1e6f66e
--- /dev/null
+++ b/poky/meta/recipes-graphics/freetype/freetype_2.9.1.bb
@@ -0,0 +1,49 @@
+SUMMARY = "Freetype font rendering library"
+DESCRIPTION = "FreeType is a software font engine that is designed to be small, efficient, \
+highly customizable, and portable while capable of producing high-quality output (glyph \
+images). It can be used in graphics libraries, display servers, font conversion tools, text \
+image generation tools, and many other products as well."
+HOMEPAGE = "http://www.freetype.org/"
+BUGTRACKER = "https://savannah.nongnu.org/bugs/?group=freetype"
+SECTION = "libs"
+
+LICENSE = "FreeType | GPLv2+"
+LIC_FILES_CHKSUM = "file://docs/LICENSE.TXT;md5=4af6221506f202774ef74f64932878a1 \
+                    file://docs/FTL.TXT;md5=9f37b4e6afa3fef9dba8932b16bd3f97 \
+                    file://docs/GPLv2.TXT;md5=8ef380476f642c20ebf40fecb0add2ec"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/freetype/freetype-${PV}.tar.bz2 \
+           file://use-right-libtool.patch \
+          "
+
+UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/freetype/files/freetype2/"
+UPSTREAM_CHECK_REGEX = "freetype-(?P<pver>\d+(\.\d+)+)"
+
+SRC_URI[md5sum] = "60ef7d8160cd4bf8cb118ee9d65367ca"
+SRC_URI[sha256sum] = "db8d87ea720ea9d5edc5388fc7a0497bb11ba9fe972245e0f7f4c7e8b1e1e84d"
+
+inherit autotools pkgconfig multilib_header
+
+# Adapt autotools to work with the minimal autoconf usage in freetype
+AUTOTOOLS_SCRIPT_PATH = "${S}/builds/unix"
+CONFIGURE_SCRIPT = "${S}/configure"
+EXTRA_AUTORECONF += "--exclude=autoheader --exclude=automake"
+
+PACKAGECONFIG ??= "zlib"
+
+PACKAGECONFIG[bzip2] = "--with-bzip2,--without-bzip2,bzip2"
+# harfbuzz results in a circular dependency so enabling is non-trivial
+PACKAGECONFIG[harfbuzz] = "--with-harfbuzz,--without-harfbuzz,harfbuzz"
+PACKAGECONFIG[pixmap] = "--with-png,--without-png,libpng"
+PACKAGECONFIG[zlib] = "--with-zlib,--without-zlib,zlib"
+PACKAGECONFIG[freetypeconfig] = "--enable-freetype-config=yes,--enable-freetype-config=no,"
+
+EXTRA_OECONF = "CC_BUILD='${BUILD_CC}'"
+
+TARGET_CPPFLAGS += "-D_FILE_OFFSET_BITS=64"
+
+do_install_append() {
+	oe_multilib_header freetype2/freetype/config/ftconfig.h
+}
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-graphics/freetype/freetype_2.9.bb b/poky/meta/recipes-graphics/freetype/freetype_2.9.bb
deleted file mode 100644
index da05916..0000000
--- a/poky/meta/recipes-graphics/freetype/freetype_2.9.bb
+++ /dev/null
@@ -1,49 +0,0 @@
-SUMMARY = "Freetype font rendering library"
-DESCRIPTION = "FreeType is a software font engine that is designed to be small, efficient, \
-highly customizable, and portable while capable of producing high-quality output (glyph \
-images). It can be used in graphics libraries, display servers, font conversion tools, text \
-image generation tools, and many other products as well."
-HOMEPAGE = "http://www.freetype.org/"
-BUGTRACKER = "https://savannah.nongnu.org/bugs/?group=freetype"
-SECTION = "libs"
-
-LICENSE = "FreeType | GPLv2+"
-LIC_FILES_CHKSUM = "file://docs/LICENSE.TXT;md5=4af6221506f202774ef74f64932878a1 \
-                    file://docs/FTL.TXT;md5=9f37b4e6afa3fef9dba8932b16bd3f97 \
-                    file://docs/GPLv2.TXT;md5=8ef380476f642c20ebf40fecb0add2ec"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/freetype/freetype-${PV}.tar.bz2 \
-           file://use-right-libtool.patch"
-
-UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/freetype/files/freetype2/"
-UPSTREAM_CHECK_REGEX = "freetype-(?P<pver>\d+(\.\d+)+)"
-
-SRC_URI[md5sum] = "513c403c110016fdc7e537216a642b1d"
-SRC_URI[sha256sum] = "e6ffba3c8cef93f557d1f767d7bc3dee860ac7a3aaff588a521e081bc36f4c8a"
-
-inherit autotools pkgconfig binconfig-disabled multilib_header
-
-# Adapt autotools to work with the minimal autoconf usage in freetype
-AUTOTOOLS_SCRIPT_PATH = "${S}/builds/unix"
-CONFIGURE_SCRIPT = "${S}/configure"
-EXTRA_AUTORECONF += "--exclude=autoheader --exclude=automake"
-
-PACKAGECONFIG ??= "zlib"
-
-PACKAGECONFIG[bzip2] = "--with-bzip2,--without-bzip2,bzip2"
-# harfbuzz results in a circular dependency so enabling is non-trivial
-PACKAGECONFIG[harfbuzz] = "--with-harfbuzz,--without-harfbuzz,harfbuzz"
-PACKAGECONFIG[pixmap] = "--with-png,--without-png,libpng"
-PACKAGECONFIG[zlib] = "--with-zlib,--without-zlib,zlib"
-
-EXTRA_OECONF = "CC_BUILD='${BUILD_CC}'"
-
-TARGET_CPPFLAGS += "-D_FILE_OFFSET_BITS=64"
-
-do_install_append() {
-	oe_multilib_header freetype2/freetype/config/ftconfig.h
-}
-
-BINCONFIG = "${bindir}/freetype-config"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-graphics/fstests/fstests_git.bb b/poky/meta/recipes-graphics/fstests/fstests_git.bb
deleted file mode 100644
index 69f2178..0000000
--- a/poky/meta/recipes-graphics/fstests/fstests_git.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-SUMMARY = "Various benchmarning tests for X"
-HOMEPAGE = "http://www.o-hand.com"
-SECTION = "devel"
-LICENSE = "Zlib"
-DEPENDS = "pango libxext libxft virtual/libx11 gtk+"
-
-SRCREV = "e5939ff608b95cdd4d0ab0e1935781ab9a276ac0"
-PV = "0.1+git${SRCPV}"
-
-SRC_URI = "git://git.yoctoproject.org/${BPN}"
-UPSTREAM_CHECK_COMMITS = "1"
-
-LIC_FILES_CHKSUM = "file://test-pango-gdk.c;endline=24;md5=1ee74ec851ecda57eb7ac6cc180f7655"
-
-S = "${WORKDIR}/git/tests"
-
-inherit autotools pkgconfig distro_features_check
-# depends on virtual/libx11
-REQUIRED_DISTRO_FEATURES = "x11"
diff --git a/poky/meta/recipes-graphics/harfbuzz/harfbuzz_1.7.5.bb b/poky/meta/recipes-graphics/harfbuzz/harfbuzz_1.7.5.bb
deleted file mode 100644
index 0a9b029..0000000
--- a/poky/meta/recipes-graphics/harfbuzz/harfbuzz_1.7.5.bb
+++ /dev/null
@@ -1,39 +0,0 @@
-SUMMARY = "Text shaping library"
-DESCRIPTION = "HarfBuzz is an OpenType text shaping engine."
-HOMEPAGE = "http://www.freedesktop.org/wiki/Software/HarfBuzz"
-BUGTRACKER = "https://bugs.freedesktop.org/enter_bug.cgi?product=HarfBuzz"
-SECTION = "libs"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=e021dd6dda6ff1e6b1044002fc662b9b \
-                    file://src/hb-ucdn/COPYING;md5=994ba0f1295f15b4bda4999a5bbeddef \
-"
-
-DEPENDS = "glib-2.0 cairo fontconfig freetype"
-
-SRC_URI = "http://www.freedesktop.org/software/harfbuzz/release/${BP}.tar.bz2"
-
-SRC_URI[md5sum] = "1466ab51fc5aaa6af4065936939cec62"
-SRC_URI[sha256sum] = "84574e1b1f65ca694cb8fb6905309665c0368af18a312357f8ff886ee2f29563"
-
-inherit autotools pkgconfig lib_package gtk-doc
-
-PACKAGECONFIG ??= "icu"
-PACKAGECONFIG[icu] = "--with-icu,--without-icu,icu"
-
-EXTRA_OECONF = " \
-    --with-cairo \
-    --with-fontconfig \
-    --with-freetype \
-    --with-glib \
-    --without-graphite2 \
-"
-
-PACKAGES =+ "${PN}-icu ${PN}-icu-dev"
-
-FILES_${PN}-icu = "${libdir}/libharfbuzz-icu.so.*"
-FILES_${PN}-icu-dev = "${libdir}/libharfbuzz-icu.la \
-                       ${libdir}/libharfbuzz-icu.so \
-                       ${libdir}/pkgconfig/harfbuzz-icu.pc \
-"
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-graphics/harfbuzz/harfbuzz_1.8.8.bb b/poky/meta/recipes-graphics/harfbuzz/harfbuzz_1.8.8.bb
new file mode 100644
index 0000000..b904d93
--- /dev/null
+++ b/poky/meta/recipes-graphics/harfbuzz/harfbuzz_1.8.8.bb
@@ -0,0 +1,46 @@
+SUMMARY = "Text shaping library"
+DESCRIPTION = "HarfBuzz is an OpenType text shaping engine."
+HOMEPAGE = "http://www.freedesktop.org/wiki/Software/HarfBuzz"
+BUGTRACKER = "https://bugs.freedesktop.org/enter_bug.cgi?product=HarfBuzz"
+SECTION = "libs"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=e021dd6dda6ff1e6b1044002fc662b9b \
+                    file://src/hb-ucdn/COPYING;md5=994ba0f1295f15b4bda4999a5bbeddef \
+"
+
+DEPENDS = "glib-2.0 cairo fontconfig freetype"
+
+SRC_URI = "http://www.freedesktop.org/software/harfbuzz/release/${BP}.tar.bz2"
+SRC_URI[md5sum] = "81dbce82d6471ec2b2a627ce02d03e5d"
+SRC_URI[sha256sum] = "a8e5c86e4d99e1cc9865ec1b8e9b05b98e413c2a885cd11f8e9bb9502dd3e3a9"
+
+inherit autotools pkgconfig lib_package gtk-doc
+
+PACKAGECONFIG ??= "icu"
+PACKAGECONFIG[icu] = "--with-icu,--without-icu,icu"
+
+EXTRA_OECONF = " \
+    --with-cairo \
+    --with-fontconfig \
+    --with-freetype \
+    --with-glib \
+    --without-graphite2 \
+"
+
+do_configure_prepend() {
+    # This is ancient and can get used instead of the patched one we ship,
+    # so delete it. In 1.8.9 this should be removed upstream.
+    rm -f ${S}/m4/pkg.m4
+}
+
+PACKAGES =+ "${PN}-icu ${PN}-icu-dev"
+
+LEAD_SONAME = "libharfbuzz.so"
+
+FILES_${PN}-icu = "${libdir}/libharfbuzz-icu.so.*"
+FILES_${PN}-icu-dev = "${libdir}/libharfbuzz-icu.la \
+                       ${libdir}/libharfbuzz-icu.so \
+                       ${libdir}/pkgconfig/harfbuzz-icu.pc \
+"
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-graphics/jpeg/files/0001-libjpeg-turbo-fix-package_qa-error.patch b/poky/meta/recipes-graphics/jpeg/files/0001-libjpeg-turbo-fix-package_qa-error.patch
new file mode 100644
index 0000000..44c2c76
--- /dev/null
+++ b/poky/meta/recipes-graphics/jpeg/files/0001-libjpeg-turbo-fix-package_qa-error.patch
@@ -0,0 +1,32 @@
+From 0a24f03a67425a7b58b3fd40d965c0c9801ae7a1 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Mon, 27 Aug 2018 16:10:55 +0800
+Subject: [PATCH] libjpeg-turbo: fix package_qa error
+
+Fix package qa errors like below:
+libjpeg.so.62.3.0 contains probably-redundant RPATH /usr/lib [useless-rpaths]
+usr/bin/cjpeg contains probably-redundant RPATH /usr/lib
+
+Upstream-Status: Inappropriate[oe-specific]
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ CMakeLists.txt | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 1719522..682cef1 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -109,8 +109,6 @@ endif()
+ 
+ include(cmakescripts/GNUInstallDirs.cmake)
+ 
+-set(CMAKE_INSTALL_RPATH ${CMAKE_INSTALL_FULL_LIBDIR})
+-
+ macro(report_directory var)
+   if(CMAKE_INSTALL_${var} STREQUAL CMAKE_INSTALL_FULL_${var})
+     message(STATUS "CMAKE_INSTALL_${var} = ${CMAKE_INSTALL_${var}}")
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-graphics/jpeg/files/0001-libjpeg-turbo-fix-wrongly-defined-define-HAVE_STDLIB.patch b/poky/meta/recipes-graphics/jpeg/files/0001-libjpeg-turbo-fix-wrongly-defined-define-HAVE_STDLIB.patch
new file mode 100644
index 0000000..16767eb
--- /dev/null
+++ b/poky/meta/recipes-graphics/jpeg/files/0001-libjpeg-turbo-fix-wrongly-defined-define-HAVE_STDLIB.patch
@@ -0,0 +1,119 @@
+From d301019d0f23d12b9666d3d88b0859067a4ade77 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Thu, 30 Aug 2018 15:08:23 +0800
+Subject: [PATCH] libjpeg-turbo: fix wrongly defined define HAVE_STDLIB_H
+
+when change build system from autotools to cmake, below
+part is replace wrongly:
+
+"#undef HAVE_STDLIB_H"
+should be change to "#cmakedefine HAVE_STDLIB_H 1"
+not "#cmakedefine HAVE_STDLIB_H"
+
+otherwise, even if stdlib.h is found, output file
+of configure_file() will define like: #define HAVE_STDLIB_H
+but we need it as #define HAVE_STDLIB_H 1, since for
+different defination of HAVE_STDLIB_H will cause below error:
+error: "HAVE_STDLIB_H" redefined [-Werror]
+
+Upstream-Status: Submitted[https://github.com/libjpeg-turbo/libjpeg-turbo/pull/275]
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ jconfig.h.in    | 28 ++++++++++++++--------------
+ jconfigint.h.in |  4 ++--
+ 2 files changed, 16 insertions(+), 16 deletions(-)
+
+diff --git a/jconfig.h.in b/jconfig.h.in
+index 2842754..18a69a4 100644
+--- a/jconfig.h.in
++++ b/jconfig.h.in
+@@ -10,16 +10,16 @@
+ #define LIBJPEG_TURBO_VERSION_NUMBER  @LIBJPEG_TURBO_VERSION_NUMBER@
+ 
+ /* Support arithmetic encoding */
+-#cmakedefine C_ARITH_CODING_SUPPORTED
++#cmakedefine C_ARITH_CODING_SUPPORTED 1
+ 
+ /* Support arithmetic decoding */
+-#cmakedefine D_ARITH_CODING_SUPPORTED
++#cmakedefine D_ARITH_CODING_SUPPORTED 1
+ 
+ /* Support in-memory source/destination managers */
+-#cmakedefine MEM_SRCDST_SUPPORTED
++#cmakedefine MEM_SRCDST_SUPPORTED 1
+ 
+ /* Use accelerated SIMD routines. */
+-#cmakedefine WITH_SIMD
++#cmakedefine WITH_SIMD 1
+ 
+ /*
+  * Define BITS_IN_JSAMPLE as either
+@@ -33,37 +33,37 @@
+ #define BITS_IN_JSAMPLE  @BITS_IN_JSAMPLE@      /* use 8 or 12 */
+ 
+ /* Define to 1 if you have the <locale.h> header file. */
+-#cmakedefine HAVE_LOCALE_H
++#cmakedefine HAVE_LOCALE_H 1
+ 
+ /* Define to 1 if you have the <stddef.h> header file. */
+-#cmakedefine HAVE_STDDEF_H
++#cmakedefine HAVE_STDDEF_H 1
+ 
+ /* Define to 1 if you have the <stdlib.h> header file. */
+-#cmakedefine HAVE_STDLIB_H
++#cmakedefine HAVE_STDLIB_H 1
+ 
+ /* Define if you need to include <sys/types.h> to get size_t. */
+-#cmakedefine NEED_SYS_TYPES_H
++#cmakedefine NEED_SYS_TYPES_H 1
+ 
+ /* Define if you have BSD-like bzero and bcopy in <strings.h> rather than
+    memset/memcpy in <string.h>. */
+-#cmakedefine NEED_BSD_STRINGS
++#cmakedefine NEED_BSD_STRINGS 1
+ 
+ /* Define to 1 if the system has the type `unsigned char'. */
+-#cmakedefine HAVE_UNSIGNED_CHAR
++#cmakedefine HAVE_UNSIGNED_CHAR 1
+ 
+ /* Define to 1 if the system has the type `unsigned short'. */
+-#cmakedefine HAVE_UNSIGNED_SHORT
++#cmakedefine HAVE_UNSIGNED_SHORT 1
+ 
+ /* Compiler does not support pointers to undefined structures. */
+-#cmakedefine INCOMPLETE_TYPES_BROKEN
++#cmakedefine INCOMPLETE_TYPES_BROKEN 1
+ 
+ /* Define if your (broken) compiler shifts signed values as if they were
+    unsigned. */
+-#cmakedefine RIGHT_SHIFT_IS_UNSIGNED
++#cmakedefine RIGHT_SHIFT_IS_UNSIGNED 1
+ 
+ /* Define to 1 if type `char' is unsigned and you are not using gcc.  */
+ #ifndef __CHAR_UNSIGNED__
+-  #cmakedefine __CHAR_UNSIGNED__
++  #cmakedefine __CHAR_UNSIGNED__ 1
+ #endif
+ 
+ /* Define to empty if `const' does not conform to ANSI C. */
+diff --git a/jconfigint.h.in b/jconfigint.h.in
+index 55df053..6c898ac 100644
+--- a/jconfigint.h.in
++++ b/jconfigint.h.in
+@@ -17,10 +17,10 @@
+ #define SIZEOF_SIZE_T  @SIZE_T@
+ 
+ /* Define if your compiler has __builtin_ctzl() and sizeof(unsigned long) == sizeof(size_t). */
+-#cmakedefine HAVE_BUILTIN_CTZL
++#cmakedefine HAVE_BUILTIN_CTZL 1
+ 
+ /* Define to 1 if you have the <intrin.h> header file. */
+-#cmakedefine HAVE_INTRIN_H
++#cmakedefine HAVE_INTRIN_H 1
+ 
+ #if defined(_MSC_VER) && defined(HAVE_INTRIN_H)
+ #if (SIZEOF_SIZE_T == 8)
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-graphics/jpeg/libjpeg-turbo_1.5.3.bb b/poky/meta/recipes-graphics/jpeg/libjpeg-turbo_1.5.3.bb
deleted file mode 100644
index 50a5ae0..0000000
--- a/poky/meta/recipes-graphics/jpeg/libjpeg-turbo_1.5.3.bb
+++ /dev/null
@@ -1,59 +0,0 @@
-SUMMARY = "Hardware accelerated JPEG compression/decompression library"
-DESCRIPTION = "libjpeg-turbo is a derivative of libjpeg that uses SIMD instructions (MMX, SSE2, NEON) to accelerate baseline JPEG compression and decompression"
-HOMEPAGE = "http://libjpeg-turbo.org/"
-
-LICENSE = "BSD-3-Clause"
-LIC_FILES_CHKSUM = "file://cdjpeg.h;endline=13;md5=8184bcc7c4ac7b9edc6a7bc00f231d0b \
-                    file://jpeglib.h;endline=16;md5=f67d70e547a2662c079781c72f877f72 \
-                    file://djpeg.c;endline=11;md5=c59e19811c006cb38f82d6477134d314 \
-"
-DEPENDS_append_x86-64_class-target = " nasm-native"
-DEPENDS_append_x86_class-target    = " nasm-native"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BPN}-${PV}.tar.gz"
-
-SRC_URI[md5sum] = "7c82f0f6a3130ec06b8a4d0b321cbca3"
-SRC_URI[sha256sum] = "b24890e2bb46e12e72a79f7e965f409f4e16466d00e1dd15d93d73ee6b592523"
-UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/libjpeg-turbo/files/"
-UPSTREAM_CHECK_REGEX = "/libjpeg-turbo/files/(?P<pver>(\d+[\.\-_]*)+)/"
-
-PE= "1"
-
-# Drop-in replacement for jpeg
-PROVIDES = "jpeg"
-RPROVIDES_${PN} += "jpeg"
-RREPLACES_${PN} += "jpeg"
-RCONFLICTS_${PN} += "jpeg"
-
-inherit autotools pkgconfig
-
-# Add nasm-native dependency consistently for all build arches is hard
-EXTRA_OECONF_append_class-native = " --without-simd"
-
-# Work around missing x32 ABI support
-EXTRA_OECONF_append_class-target = " ${@bb.utils.contains("TUNE_FEATURES", "mx32", "--without-simd", "", d)}"
-
-# Work around missing non-floating point ABI support in MIPS
-EXTRA_OECONF_append_class-target = " ${@bb.utils.contains("MIPSPKGSFX_FPU", "-nf", "--without-simd", "", d)}"
-
-# Provide a workaround if Altivec unit is not present in PPC
-EXTRA_OECONF_append_class-target_powerpc = " ${@bb.utils.contains("TUNE_FEATURES", "altivec", "", "--without-simd", d)}"
-EXTRA_OECONF_append_class-target_powerpc64 = " ${@bb.utils.contains("TUNE_FEATURES", "altivec", "", "--without-simd", d)}"
-
-def get_build_time(d):
-    if d.getVar('SOURCE_DATE_EPOCH') != None:
-        import datetime
-        return " --with-build-date="+ datetime.datetime.fromtimestamp(float(d.getVar('SOURCE_DATE_EPOCH'))).strftime("%Y%m%d")
-    return ""
-
-EXTRA_OECONF_append_class-target = "${@get_build_time(d)}"
-
-PACKAGES =+ "jpeg-tools libturbojpeg"
-
-DESCRIPTION_jpeg-tools = "The jpeg-tools package includes client programs to access libjpeg functionality.  These tools allow for the compression, decompression, transformation and display of JPEG files and benchmarking of the libjpeg library."
-FILES_jpeg-tools = "${bindir}/*"
-
-DESCRIPTION_libturbojpeg = "A SIMD-accelerated JPEG codec which provides only TurboJPEG APIs"
-FILES_libturbojpeg = "${libdir}/libturbojpeg.so.*"
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-graphics/jpeg/libjpeg-turbo_2.0.0.bb b/poky/meta/recipes-graphics/jpeg/libjpeg-turbo_2.0.0.bb
new file mode 100644
index 0000000..282bf95
--- /dev/null
+++ b/poky/meta/recipes-graphics/jpeg/libjpeg-turbo_2.0.0.bb
@@ -0,0 +1,56 @@
+SUMMARY = "Hardware accelerated JPEG compression/decompression library"
+DESCRIPTION = "libjpeg-turbo is a derivative of libjpeg that uses SIMD instructions (MMX, SSE2, NEON) to accelerate baseline JPEG compression and decompression"
+HOMEPAGE = "http://libjpeg-turbo.org/"
+
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://cdjpeg.h;endline=13;md5=8184bcc7c4ac7b9edc6a7bc00f231d0b \
+                    file://jpeglib.h;endline=16;md5=7ea97dc83b0f59052ee837e61ef0e08f \
+                    file://djpeg.c;endline=11;md5=c59e19811c006cb38f82d6477134d314 \
+"
+DEPENDS_append_x86-64_class-target = " nasm-native"
+DEPENDS_append_x86_class-target    = " nasm-native"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BPN}-${PV}.tar.gz \
+           file://0001-libjpeg-turbo-fix-package_qa-error.patch \
+           file://0001-libjpeg-turbo-fix-wrongly-defined-define-HAVE_STDLIB.patch"
+
+SRC_URI[md5sum] = "b12a3fcf1d078db38410f27718a91b83"
+SRC_URI[sha256sum] = "778876105d0d316203c928fd2a0374c8c01f755d0a00b12a1c8934aeccff8868"
+UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/libjpeg-turbo/files/"
+UPSTREAM_CHECK_REGEX = "/libjpeg-turbo/files/(?P<pver>(\d+[\.\-_]*)+)/"
+
+PE= "1"
+
+# Drop-in replacement for jpeg
+PROVIDES = "jpeg"
+RPROVIDES_${PN} += "jpeg"
+RREPLACES_${PN} += "jpeg"
+RCONFLICTS_${PN} += "jpeg"
+
+inherit cmake pkgconfig
+
+# Add nasm-native dependency consistently for all build arches is hard
+EXTRA_OECMAKE_append_class-native = " -DWITH_SIMD=False"
+
+# Work around missing x32 ABI support
+EXTRA_OECMAKE_append_class-target = " ${@bb.utils.contains("TUNE_FEATURES", "mx32", "-DWITH_SIMD=False", "", d)}"
+
+# Work around missing non-floating point ABI support in MIPS
+EXTRA_OECMAKE_append_class-target = " ${@bb.utils.contains("MIPSPKGSFX_FPU", "-nf", "-DWITH_SIMD=False", "", d)}"
+
+# Provide a workaround if Altivec unit is not present in PPC
+EXTRA_OECMAKE_append_class-target_powerpc = " ${@bb.utils.contains("TUNE_FEATURES", "altivec", "", "-DWITH_SIMD=False", d)}"
+EXTRA_OECMAKE_append_class-target_powerpc64 = " ${@bb.utils.contains("TUNE_FEATURES", "altivec", "", "-DWITH_SIMD=False", d)}"
+
+DEBUG_OPTIMIZATION_append_armv4 = " ${@bb.utils.contains('TUNE_CCARGS', '-mthumb', '-fomit-frame-pointer', '', d)}"
+DEBUG_OPTIMIZATION_append_armv5 = " ${@bb.utils.contains('TUNE_CCARGS', '-mthumb', '-fomit-frame-pointer', '', d)}"
+
+PACKAGES =+ "jpeg-tools libturbojpeg"
+
+DESCRIPTION_jpeg-tools = "The jpeg-tools package includes client programs to access libjpeg functionality.  These tools allow for the compression, decompression, transformation and display of JPEG files and benchmarking of the libjpeg library."
+FILES_jpeg-tools = "${bindir}/*"
+
+DESCRIPTION_libturbojpeg = "A SIMD-accelerated JPEG codec which provides only TurboJPEG APIs"
+FILES_libturbojpeg = "${libdir}/libturbojpeg.so.*"
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-graphics/kmscube/kmscube/detect-gst_bo_map-_unmap-and-use-it-or-avoid-it.patch b/poky/meta/recipes-graphics/kmscube/kmscube/detect-gst_bo_map-_unmap-and-use-it-or-avoid-it.patch
index 3605446..611e541 100644
--- a/poky/meta/recipes-graphics/kmscube/kmscube/detect-gst_bo_map-_unmap-and-use-it-or-avoid-it.patch
+++ b/poky/meta/recipes-graphics/kmscube/kmscube/detect-gst_bo_map-_unmap-and-use-it-or-avoid-it.patch
@@ -49,9 +49,9 @@
 index 8397f7b..c7f1f4d 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -65,5 +65,8 @@ if test "x$enable_gbm_modifiers" = xyes; then
- 	AC_DEFINE(HAVE_GBM_MODIFIERS, 1, [Define if you can use GBM properties.])
+@@ -49,5 +49,8 @@ if test "x$HAVE_GST" = "xyes"; then
  fi
+ AM_CONDITIONAL(ENABLE_GST, [test "x$HAVE_GST" = "xyes"])
  
 +AC_CHECK_LIB([gbm], [gbm_bo_map], [HAVE_GBM_BO_MAP=yes], [])
 +AM_CONDITIONAL(ENABLE_GBM_MAP, [test "x$HAVE_GBM_BO_MAP" = "xyes"])
@@ -99,12 +99,12 @@
 index 3a2c4dd..276dc55 100644
 --- a/kmscube.c
 +++ b/kmscube.c
-@@ -142,7 +142,11 @@ int main(int argc, char *argv[])
+@@ -148,7 +148,11 @@ int main(int argc, char *argv[])
  	else if (mode == VIDEO)
- 		egl = init_cube_video(gbm, video);
+ 		egl = init_cube_video(gbm, video, samples);
  	else
 +#if HAVE_GBM_BO_MAP
- 		egl = init_cube_tex(gbm, mode);
+ 		egl = init_cube_tex(gbm, mode, samples);
 +#else
 +		printf("gbm_bo_map() support missing\n");
 +#endif
diff --git a/poky/meta/recipes-graphics/kmscube/kmscube_git.bb b/poky/meta/recipes-graphics/kmscube/kmscube_git.bb
index 5b64ed6..46aeeb0 100644
--- a/poky/meta/recipes-graphics/kmscube/kmscube_git.bb
+++ b/poky/meta/recipes-graphics/kmscube/kmscube_git.bb
@@ -6,7 +6,7 @@
 
 LIC_FILES_CHKSUM = "file://kmscube.c;beginline=1;endline=23;md5=8b309d4ee67b7315ff7381270dd631fb"
 
-SRCREV = "0d8de4ce3a03f36af1817f9b0586d132ad2c5d2e"
+SRCREV = "9dcce71e603616ee7a54707e932f962cdf8fb20a"
 SRC_URI = "git://anongit.freedesktop.org/mesa/kmscube;branch=master;protocol=git \
     file://detect-gst_bo_map-_unmap-and-use-it-or-avoid-it.patch"
 UPSTREAM_CHECK_COMMITS = "1"
diff --git a/poky/meta/recipes-graphics/libepoxy/libepoxy/no-tests.patch b/poky/meta/recipes-graphics/libepoxy/libepoxy/no-tests.patch
deleted file mode 100644
index d2b6c1a..0000000
--- a/poky/meta/recipes-graphics/libepoxy/libepoxy/no-tests.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-Add option to disable tests.
-
-Upstream-Status: Submitted (https://github.com/anholt/libepoxy/pull/158)
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
-diff --git a/meson.build b/meson.build
-index b2ebaef..9632c7a 100644
---- a/meson.build
-+++ b/meson.build
-@@ -242,7 +242,10 @@ libepoxy_inc = [
- 
- subdir('include/epoxy')
- subdir('src')
--subdir('test')
-+
-+if get_option('tests')
-+  subdir('test')
-+endif
- 
- if get_option('docs')
-   doxygen = find_program('doxygen', required: false)
-diff --git a/meson_options.txt b/meson_options.txt
-index b5d7c98..dc30e68 100644
---- a/meson_options.txt
-+++ b/meson_options.txt
-@@ -15,3 +15,7 @@ option('x11',
-        type: 'boolean',
-        value: true,
-        description: 'Enable X11 support (GLX or EGL-X11)')
-+option('tests',
-+       type: 'boolean',
-+       value: true,
-+       description: 'Build the test suite')
diff --git a/poky/meta/recipes-graphics/libepoxy/libepoxy_1.5.0.bb b/poky/meta/recipes-graphics/libepoxy/libepoxy_1.5.0.bb
deleted file mode 100644
index 5ca0868..0000000
--- a/poky/meta/recipes-graphics/libepoxy/libepoxy_1.5.0.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-SUMMARY = "OpenGL function pointer management library"
-HOMEPAGE = "https://github.com/anholt/libepoxy/"
-SECTION = "libs"
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=58ef4c80d401e07bd9ee8b6b58cf464b"
-
-SRC_URI = "https://github.com/anholt/${BPN}/releases/download/${PV}/${BP}.tar.xz \
-           file://no-tests.patch \
-           "
-SRC_URI[md5sum] = "63fe3847789258254dcd7e3fdb9e7f5e"
-SRC_URI[sha256sum] = "4c94995398a6ebf691600dda2e9685a0cac261414175c2adf4645cdfab42a5d5"
-UPSTREAM_CHECK_URI = "https://github.com/anholt/libepoxy/releases"
-
-inherit meson pkgconfig distro_features_check
-
-REQUIRED_DISTRO_FEATURES = "opengl"
-
-PACKAGECONFIG[egl] = "-Degl=yes, -Degl=no, virtual/egl"
-PACKAGECONFIG[x11] = "-Dglx=yes, -Dglx=no, virtual/libx11 virtual/libgl"
-PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)} egl"
-
-EXTRA_OEMESON += "-Dtests=false"
diff --git a/poky/meta/recipes-graphics/libepoxy/libepoxy_1.5.2.bb b/poky/meta/recipes-graphics/libepoxy/libepoxy_1.5.2.bb
new file mode 100644
index 0000000..1067212
--- /dev/null
+++ b/poky/meta/recipes-graphics/libepoxy/libepoxy_1.5.2.bb
@@ -0,0 +1,22 @@
+SUMMARY = "OpenGL function pointer management library"
+HOMEPAGE = "https://github.com/anholt/libepoxy/"
+SECTION = "libs"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=58ef4c80d401e07bd9ee8b6b58cf464b"
+
+SRC_URI = "https://github.com/anholt/${BPN}/releases/download/${PV}/${BP}.tar.xz \
+           "
+SRC_URI[md5sum] = "4a6b9e581da229dee74c2263c84b1eca"
+SRC_URI[sha256sum] = "a9562386519eb3fd7f03209f279f697a8cba520d3c155d6e253c3e138beca7d8"
+UPSTREAM_CHECK_URI = "https://github.com/anholt/libepoxy/releases"
+
+inherit meson pkgconfig distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "opengl"
+
+PACKAGECONFIG[egl] = "-Degl=yes, -Degl=no, virtual/egl"
+PACKAGECONFIG[x11] = "-Dglx=yes, -Dglx=no, virtual/libx11 virtual/libgl"
+PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)} egl"
+
+EXTRA_OEMESON += "-Dtests=false"
diff --git a/poky/meta/recipes-graphics/libsdl2/libsdl2/more-gen-depends.patch b/poky/meta/recipes-graphics/libsdl2/libsdl2/more-gen-depends.patch
new file mode 100644
index 0000000..29076bf
--- /dev/null
+++ b/poky/meta/recipes-graphics/libsdl2/libsdl2/more-gen-depends.patch
@@ -0,0 +1,47 @@
+Many source files include e.g. wayland-protocols.h which should be found in the
+sysroot but SDL wants to build its own headers from the XML definitions.
+
+However the rules to generate those headers are only dependencies of the
+top-level libSDL2.la object so can be built in parallel with the rest of the
+objects, which can lead to interesting errors if the header is parsed by the
+compiler whilst it's being written by another process:
+
+| gen/wayland-client-protocol.h:3: error: unterminated #ifndef
+|  #ifndef WAYLAND_CLIENT_PROTOCOL_H
+
+Solve this by adding more dependencies so the generated files are built before
+the primary objects.
+
+Upstream-Status: Pending
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+diff --git a/configure.in b/data/poky-tmp/master/work/corei7-64-poky-linux/libsdl2/2.0.8-r0/SDL2-2.0.8/configure.in
+index 1c7e79338..ba07a4a4e 100644
+--- a/configure.in
++++ b/data/poky-tmp/master/work/corei7-64-poky-linux/libsdl2/2.0.8-r0/SDL2-2.0.8/configure.in
+@@ -4011,7 +4011,7 @@ DEPENDS=`echo $SOURCES | tr ' ' '\n'`
+ for EXT in asm cc m c S; do
+     OBJECTS=`echo "$OBJECTS" | sed 's,[[^ ]]*/\([[^ ]]*\)\.'$EXT',$(objects)/\1.lo,g'`
+     DEPENDS=`echo "$DEPENDS" | sed "s,^\\([[^ ]]*\\)/\\([[^ ]]*\\)\\.$EXT\\$,\\\\
+-\\$(objects)/\\2.lo: \\1/\\2.$EXT\\\\
++\\$(objects)/\\2.lo: \\1/\\2.$EXT \\$(GEN_OBJECTS)\\\\
+ 	\\$(RUN_CMD_CC)\\$(LIBTOOL) --tag=CC --mode=compile \\$(CC) \\$(CFLAGS) \\$(EXTRA_CFLAGS) $DEPENDENCY_TRACKING_OPTIONS -c \\$< -o \\$@,g"`
+ done
+ 
+@@ -4028,14 +4028,14 @@ SDLMAIN_OBJECTS=`echo $SDLMAIN_SOURCES`
+ SDLMAIN_DEPENDS=`echo $SDLMAIN_SOURCES`
+ SDLMAIN_OBJECTS=`echo "$SDLMAIN_OBJECTS" | sed 's,[[^ ]]*/\([[^ ]]*\)\.c,$(objects)/\1.lo,g'`
+ SDLMAIN_DEPENDS=`echo "$SDLMAIN_DEPENDS" | sed "s,\\([[^ ]]*\\)/\\([[^ ]]*\\)\\.c,\\\\
+-\\$(objects)/\\2.lo: \\1/\\2.c\\\\
++\\$(objects)/\\2.lo: \\1/\\2.c \\$(GEN_OBJECTS)\\\\
+ 	\\$(RUN_CMD_CC)\\$(LIBTOOL) --tag=CC --mode=compile \\$(CC) \\$(CFLAGS) \\$(EXTRA_CFLAGS) $DEPENDENCY_TRACKING_OPTIONS -c \\$< -o \\$@,g"`
+ 
+ SDLTEST_OBJECTS=`echo $SDLTEST_SOURCES`
+ SDLTEST_DEPENDS=`echo $SDLTEST_SOURCES`
+ SDLTEST_OBJECTS=`echo "$SDLTEST_OBJECTS" | sed 's,[[^ ]]*/\([[^ ]]*\)\.c,$(objects)/\1.lo,g'`
+ SDLTEST_DEPENDS=`echo "$SDLTEST_DEPENDS" | sed "s,\\([[^ ]]*\\)/\\([[^ ]]*\\)\\.c,\\\\
+-\\$(objects)/\\2.lo: \\1/\\2.c\\\\
++\\$(objects)/\\2.lo: \\1/\\2.c\\\\ \\$(GEN_OBJECTS)\\\\
+ 	\\$(RUN_CMD_CC)\\$(LIBTOOL) --tag=CC --mode=compile \\$(CC) \\$(CFLAGS) \\$(EXTRA_CFLAGS) $DEPENDENCY_TRACKING_OPTIONS -c \\$< -o \\$@,g"`
+ 
+ # Set runtime shared library paths as needed
diff --git a/poky/meta/recipes-graphics/libsdl2/libsdl2_2.0.8.bb b/poky/meta/recipes-graphics/libsdl2/libsdl2_2.0.8.bb
index 8092fad..812a9ab 100644
--- a/poky/meta/recipes-graphics/libsdl2/libsdl2_2.0.8.bb
+++ b/poky/meta/recipes-graphics/libsdl2/libsdl2_2.0.8.bb
@@ -12,11 +12,9 @@
 
 PROVIDES = "virtual/libsdl2"
 
-DEPENDS_class-nativesdk = "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'virtual/nativesdk-libx11 nativesdk-libxrandr nativesdk-libxrender nativesdk-libxext', '', d)}"
-
-SRC_URI = " \
-    http://www.libsdl.org/release/SDL2-${PV}.tar.gz \
-    file://0001-GLES2-Get-sin-cos-out-of-vertex-shader.patch \
+SRC_URI = "http://www.libsdl.org/release/SDL2-${PV}.tar.gz \
+           file://more-gen-depends.patch \
+           file://0001-GLES2-Get-sin-cos-out-of-vertex-shader.patch \
 "
 
 S = "${WORKDIR}/SDL2-${PV}"
@@ -32,12 +30,15 @@
                 --enable-pthreads \
                 --enable-sdl-dlopen \
                 --disable-rpath \
+                --disable-sndio \
                 "
 
 # opengl packageconfig factored out to make it easy for distros
 # and BSP layers to pick either (desktop) opengl, gles2, or no GL
 PACKAGECONFIG_GL ?= "${@bb.utils.filter('DISTRO_FEATURES', 'opengl', d)}"
 
+PACKAGECONFIG_class-native = "x11"
+PACKAGECONFIG_class-nativesdk = "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}"
 PACKAGECONFIG ??= " \
     ${PACKAGECONFIG_GL} \
     ${@bb.utils.filter('DISTRO_FEATURES', 'alsa directfb pulseaudio x11', d)} \
@@ -64,3 +65,5 @@
 }
 
 FILES_${PN}-dev += "${libdir}/cmake"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-graphics/libva/libva-utils_2.1.0.bb b/poky/meta/recipes-graphics/libva/libva-utils_2.1.0.bb
deleted file mode 100644
index a8018ea..0000000
--- a/poky/meta/recipes-graphics/libva/libva-utils_2.1.0.bb
+++ /dev/null
@@ -1,32 +0,0 @@
-SUMMARY = "libva-utils is a collection of utilities from libva project"
-
-DESCRIPTION = "libva-utils is a collection of utilities \
-and examples to exercise VA-API in accordance with the libva \
-project.VA-API is an open-source library and API specification, \
-which provides access to graphics hardware acceleration capabilities \
-for video processing. It consists of a main library and driver-specific \
-acceleration backends for each supported hardware vendor"
-
-HOMEPAGE = "https://01.org/linuxmedia/vaapi"
-BUGTRACKER = "https://github.com/intel/libva-utils/issues"
-
-SECTION = "x11"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b148fc8adf19dc9aec17cf9cd29a9a5e"
-
-SRC_URI = "https://github.com/intel/${BPN}/releases/download/${PV}/${BP}.tar.bz2"
-SRC_URI[md5sum] = "6649be70390606651cb636320bfd43c6"
-SRC_URI[sha256sum] = "f6a7790c3dcc56537372c90a83036a3136194a8b397e84e97bf9cc9254fa2c51"
-
-UPSTREAM_CHECK_URI = "https://github.com/intel/libva-utils/releases"
-
-DEPENDS = "libva"
-
-inherit autotools pkgconfig distro_features_check
-
-# depends on libva which requires opengl
-REQUIRED_DISTRO_FEATURES = "opengl"
-
-PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'wayland x11', d)}"
-PACKAGECONFIG[x11] = "--enable-x11,--disable-x11,virtual/libx11 libxext libxfixes"
-PACKAGECONFIG[wayland] = "--enable-wayland,--disable-wayland,wayland-native wayland"
diff --git a/poky/meta/recipes-graphics/libva/libva-utils_2.2.0.bb b/poky/meta/recipes-graphics/libva/libva-utils_2.2.0.bb
new file mode 100644
index 0000000..e35085c
--- /dev/null
+++ b/poky/meta/recipes-graphics/libva/libva-utils_2.2.0.bb
@@ -0,0 +1,32 @@
+SUMMARY = "libva-utils is a collection of utilities from libva project"
+
+DESCRIPTION = "libva-utils is a collection of utilities \
+and examples to exercise VA-API in accordance with the libva \
+project.VA-API is an open-source library and API specification, \
+which provides access to graphics hardware acceleration capabilities \
+for video processing. It consists of a main library and driver-specific \
+acceleration backends for each supported hardware vendor"
+
+HOMEPAGE = "https://01.org/linuxmedia/vaapi"
+BUGTRACKER = "https://github.com/intel/libva-utils/issues"
+
+SECTION = "x11"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b148fc8adf19dc9aec17cf9cd29a9a5e"
+
+SRC_URI = "https://github.com/intel/${BPN}/releases/download/${PV}/${BP}.tar.bz2"
+SRC_URI[md5sum] = "93b58aa5b14c16f4bace8a45dc255ec9"
+SRC_URI[sha256sum] = "ed7a6ed1fab657df4e83ea11f90310efcf31c27828f32d65351a28ca3c404dc0"
+
+UPSTREAM_CHECK_URI = "https://github.com/intel/libva-utils/releases"
+
+DEPENDS = "libva"
+
+inherit autotools pkgconfig distro_features_check
+
+# depends on libva which requires opengl
+REQUIRED_DISTRO_FEATURES = "opengl"
+
+PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'wayland x11', d)}"
+PACKAGECONFIG[x11] = "--enable-x11,--disable-x11,virtual/libx11 libxext libxfixes"
+PACKAGECONFIG[wayland] = "--enable-wayland,--disable-wayland,wayland-native wayland"
diff --git a/poky/meta/recipes-graphics/libva/libva_2.1.0.bb b/poky/meta/recipes-graphics/libva/libva_2.1.0.bb
deleted file mode 100644
index d3cf633..0000000
--- a/poky/meta/recipes-graphics/libva/libva_2.1.0.bb
+++ /dev/null
@@ -1,46 +0,0 @@
-SUMMARY = "Video Acceleration (VA) API for Linux"
-DESCRIPTION = "Video Acceleration API (VA API) is a library (libVA) \
-and API specification which enables and provides access to graphics \
-hardware (GPU) acceleration for video processing on Linux and UNIX \
-based operating systems. Accelerated processing includes video \
-decoding, video encoding, subpicture blending and rendering. The \
-specification was originally designed by Intel for its GMA (Graphics \
-Media Accelerator) series of GPU hardware, the API is however not \
-limited to GPUs or Intel specific hardware, as other hardware and \
-manufacturers can also freely use this API for hardware accelerated \
-video decoding."
-
-HOMEPAGE = "https://01.org/linuxmedia/vaapi"
-BUGTRACKER = "https://github.com/intel/libva/issues"
-
-SECTION = "x11"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=2e48940f94acb0af582e5ef03537800f"
-
-SRC_URI = "https://github.com/intel/${BPN}/releases/download/${PV}/${BP}.tar.bz2"
-
-SRC_URI[md5sum] = "9d6e4f1d36c407566343e9dde5a972b8"
-SRC_URI[sha256sum] = "f3fa953a11d3210c3a4ee79031abdbe0863d5ce13d9b3f93f315f1eec60a4b0f"
-
-UPSTREAM_CHECK_URI = "https://github.com/intel/libva/releases"
-
-DEPENDS = "libdrm virtual/mesa"
-
-inherit autotools pkgconfig distro_features_check
-
-REQUIRED_DISTRO_FEATURES = "opengl"
-
-EXTRA_OECONF = "ac_cv_prog_WAYLAND_SCANNER=wayland-scanner"
-
-PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'wayland x11', d)}"
-PACKAGECONFIG[x11] = "--enable-x11,--disable-x11,virtual/libx11 libxext libxfixes"
-PACKAGECONFIG[wayland] = "--enable-wayland,--disable-wayland,wayland-native wayland"
-
-PACKAGES =+ "${PN}-x11 ${PN}-glx ${PN}-wayland"
-
-RDEPENDS_${PN}-x11 =+ "${PN}"
-RDEPENDS_${PN}-glx =+ "${PN}-x11"
-
-FILES_${PN}-x11 =+ "${libdir}/libva-x11*${SOLIBS}"
-FILES_${PN}-glx =+ "${libdir}/libva-glx*${SOLIBS}"
-FILES_${PN}-wayland =+ "${libdir}/libva-wayland*${SOLIBS}"
diff --git a/poky/meta/recipes-graphics/libva/libva_2.2.0.bb b/poky/meta/recipes-graphics/libva/libva_2.2.0.bb
new file mode 100644
index 0000000..11e57e0
--- /dev/null
+++ b/poky/meta/recipes-graphics/libva/libva_2.2.0.bb
@@ -0,0 +1,46 @@
+SUMMARY = "Video Acceleration (VA) API for Linux"
+DESCRIPTION = "Video Acceleration API (VA API) is a library (libVA) \
+and API specification which enables and provides access to graphics \
+hardware (GPU) acceleration for video processing on Linux and UNIX \
+based operating systems. Accelerated processing includes video \
+decoding, video encoding, subpicture blending and rendering. The \
+specification was originally designed by Intel for its GMA (Graphics \
+Media Accelerator) series of GPU hardware, the API is however not \
+limited to GPUs or Intel specific hardware, as other hardware and \
+manufacturers can also freely use this API for hardware accelerated \
+video decoding."
+
+HOMEPAGE = "https://01.org/linuxmedia/vaapi"
+BUGTRACKER = "https://github.com/intel/libva/issues"
+
+SECTION = "x11"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=2e48940f94acb0af582e5ef03537800f"
+
+SRC_URI = "https://github.com/intel/${BPN}/releases/download/${PV}/${BP}.tar.bz2"
+
+SRC_URI[md5sum] = "92d04ad1700136dc75b1e5f47516e704"
+SRC_URI[sha256sum] = "6f6ca04c785544d30d315ef130a6aeb9435b75f934d7fbe0e4e9ba6084ce4ef2"
+
+UPSTREAM_CHECK_URI = "https://github.com/intel/libva/releases"
+
+DEPENDS = "libdrm virtual/mesa"
+
+inherit autotools pkgconfig distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "opengl"
+
+EXTRA_OECONF = "ac_cv_prog_WAYLAND_SCANNER=wayland-scanner"
+
+PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'wayland x11', d)}"
+PACKAGECONFIG[x11] = "--enable-x11,--disable-x11,virtual/libx11 libxext libxfixes"
+PACKAGECONFIG[wayland] = "--enable-wayland,--disable-wayland,wayland-native wayland"
+
+PACKAGES =+ "${PN}-x11 ${PN}-glx ${PN}-wayland"
+
+RDEPENDS_${PN}-x11 =+ "${PN}"
+RDEPENDS_${PN}-glx =+ "${PN}-x11"
+
+FILES_${PN}-x11 =+ "${libdir}/libva-x11*${SOLIBS}"
+FILES_${PN}-glx =+ "${libdir}/libva-glx*${SOLIBS}"
+FILES_${PN}-wayland =+ "${libdir}/libva-wayland*${SOLIBS}"
diff --git a/poky/meta/recipes-graphics/mesa/files/0001-Makefile.vulkan.am-explictly-add-lib-expat-to-intel-.patch b/poky/meta/recipes-graphics/mesa/files/0001-Makefile.vulkan.am-explictly-add-lib-expat-to-intel-.patch
deleted file mode 100644
index f908d46..0000000
--- a/poky/meta/recipes-graphics/mesa/files/0001-Makefile.vulkan.am-explictly-add-lib-expat-to-intel-.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From 342311dbb190735b7b32ab20f81c1d8dbcfe717a Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Wed, 11 Oct 2017 15:40:42 +0800
-Subject: [PATCH] Makefile.vulkan.am: explictly add lib expat to intel
- libvulkan's lib depends
-
-While built with "-fvisibility=default"
-...
-|i586-oe-linux-gcc ... -fvisibility=default ... -o common/.libs/common_libintel_common_la-gen_decoder.o
-...
-
-It triggered the failure
-...
-|i586-oe-linux-g++  ... common/.libs/libintel_common.a ... -o vulkan/.libs/libvulkan_intel.so
-|common/.libs/libintel_common.a(common_libintel_common_la-gen_decoder.o):
-|In function `start_element':
-|/usr/src/debug/mesa/2_17.1.7-r0/mesa-17.1.7/src/intel/common/gen_decoder.c:371:
-undefined reference to `XML_GetCurrentLineNumber'
-...
-
-explictly add EXPAT_LIBS to intel's VULKAN_LIB_DEPS
-
-Upstream-Status: Accepted
-https://cgit.freedesktop.org/mesa/mesa/commit/?id=05fc62d89f59ce19a18bfd4e63a09624910d6caf
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- src/intel/Makefile.vulkan.am | 1 +
- 1 file changed, 1 insertion(+)
-
-Index: mesa-17.3.6/src/intel/Makefile.vulkan.am
-===================================================================
---- mesa-17.3.6.orig/src/intel/Makefile.vulkan.am
-+++ mesa-17.3.6/src/intel/Makefile.vulkan.am
-@@ -144,6 +144,7 @@ VULKAN_LIB_DEPS = \
- 	$(LIBDRM_LIBS) \
- 	$(PTHREAD_LIBS) \
- 	$(DLOPEN_LIBS) \
-+	$(EXPAT_LIBS) \
- 	-lm
- 
- if HAVE_PLATFORM_ANDROID
diff --git a/poky/meta/recipes-graphics/mesa/files/0001-Simplify-wayland-scanner-lookup.patch b/poky/meta/recipes-graphics/mesa/files/0001-Simplify-wayland-scanner-lookup.patch
new file mode 100644
index 0000000..a50d2a2
--- /dev/null
+++ b/poky/meta/recipes-graphics/mesa/files/0001-Simplify-wayland-scanner-lookup.patch
@@ -0,0 +1,39 @@
+From 7e8e0f8a8ac2425e19a2f340c9e3da9345f25940 Mon Sep 17 00:00:00 2001
+From: Jussi Kukkonen <jussi.kukkonen@intel.com>
+Date: Tue, 15 Nov 2016 15:20:49 +0200
+Subject: [PATCH 1/6] Simplify wayland-scanner lookup
+Organization: O.S. Systems Software LTDA.
+
+Don't use pkg-config to lookup the path of a binary that's in the path.
+
+Alternatively we'd have to prefix the path returned by pkg-config with
+PKG_CONFIG_SYSROOT_DIR.
+
+Upstream-Status: Pending
+Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
+Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
+---
+ configure.ac | 7 +------
+ 1 file changed, 1 insertion(+), 6 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 14f1af2b2f..916d0bd207 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -1825,12 +1825,7 @@ for plat in $platforms; do
+         PKG_CHECK_MODULES([WAYLAND_PROTOCOLS], [wayland-protocols >= $WAYLAND_PROTOCOLS_REQUIRED])
+         WAYLAND_PROTOCOLS_DATADIR=`$PKG_CONFIG --variable=pkgdatadir wayland-protocols`
+ 
+-        PKG_CHECK_MODULES([WAYLAND_SCANNER], [wayland-scanner],
+-                          WAYLAND_SCANNER=`$PKG_CONFIG --variable=wayland_scanner wayland-scanner`,
+-                          WAYLAND_SCANNER='')
+-        if test "x$WAYLAND_SCANNER" = x; then
+-            AC_PATH_PROG([WAYLAND_SCANNER], [wayland-scanner], [:])
+-        fi
++        AC_PATH_PROG([WAYLAND_SCANNER], [wayland-scanner], [:])
+ 
+         if test "x$WAYLAND_SCANNER" = "x:"; then
+                 AC_MSG_ERROR([wayland-scanner is needed to compile the wayland platform])
+-- 
+2.18.0
+
diff --git a/poky/meta/recipes-graphics/mesa/files/0001-Use-wayland-scanner-in-the-path.patch b/poky/meta/recipes-graphics/mesa/files/0001-Use-wayland-scanner-in-the-path.patch
deleted file mode 100644
index 2444b28..0000000
--- a/poky/meta/recipes-graphics/mesa/files/0001-Use-wayland-scanner-in-the-path.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From c908f0c13ac81a3a52140f129a13b2bc997ff4ee Mon Sep 17 00:00:00 2001
-From: Jussi Kukkonen <jussi.kukkonen@intel.com>
-Date: Tue, 15 Nov 2016 15:20:49 +0200
-Subject: [PATCH] Simplify wayland-scanner lookup
-
-Don't use pkg-config to lookup the path of a binary that's in the path.
-
-Alternatively we'd have to prefix the path returned by pkg-config with
-PKG_CONFIG_SYSROOT_DIR.
-
-Upstream-Status: Pending
-Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
----
- configure.ac | 7 +------
- 1 file changed, 1 insertion(+), 6 deletions(-)
-
-Index: mesa-17.3.6/configure.ac
-===================================================================
---- mesa-17.3.6.orig/configure.ac
-+++ mesa-17.3.6/configure.ac
-@@ -1694,12 +1694,7 @@ if test "x$with_platforms" = xauto; then
-     with_platforms=$with_egl_platforms
- fi
- 
--PKG_CHECK_MODULES([WAYLAND_SCANNER], [wayland-scanner],
--        WAYLAND_SCANNER=`$PKG_CONFIG --variable=wayland_scanner wayland-scanner`,
--        WAYLAND_SCANNER='')
--if test "x$WAYLAND_SCANNER" = x; then
--    AC_PATH_PROG([WAYLAND_SCANNER], [wayland-scanner], [:])
--fi
-+AC_PATH_PROG([WAYLAND_SCANNER], [wayland-scanner])
- 
- PKG_CHECK_EXISTS([wayland-protocols >= $WAYLAND_PROTOCOLS_REQUIRED], [have_wayland_protocols=yes], [have_wayland_protocols=no])
- if test "x$have_wayland_protocols" = xyes; then
diff --git a/poky/meta/recipes-graphics/mesa/files/0001-st-dri-Initialise-modifier-to-INVALID-for-DRI2.patch b/poky/meta/recipes-graphics/mesa/files/0001-st-dri-Initialise-modifier-to-INVALID-for-DRI2.patch
deleted file mode 100644
index 6aba785..0000000
--- a/poky/meta/recipes-graphics/mesa/files/0001-st-dri-Initialise-modifier-to-INVALID-for-DRI2.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 4cbecb61682a0ee426faaa03d824fc8fd7aef826 Mon Sep 17 00:00:00 2001
-From: Daniel Stone <daniels@collabora.com>
-Date: Mon, 2 Apr 2018 13:20:34 +0100
-Subject: [PATCH] st/dri: Initialise modifier to INVALID for DRI2
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-When allocating a buffer for DRI2, set the modifier to INVALID to inform
-the backend that we have no supplied modifiers and it should do its own
-thing. The missed initialisation forced linear, even if the
-implementation had made other decisions.
-
-This resulted in VC4 DRI2 clients failing with:
-  Modifier 0x0 vs. tiling (0x700000000000001) mismatch
-
-Signed-off-by: Daniel Stone <daniels@collabora.com>
-Reported-by: Andreas Müller <schnitzeltony@gmail.com>
-Reviewed-by: Eric Anholt <eric@anholt.net>
-Fixes: 3f8513172ff6 ("gallium/winsys/drm: introduce modifier field to winsys_handle")
-
-Upstream-Status: Backport [1]
-
-[1] https://cgit.freedesktop.org/mesa/mesa/commit/?id=4cbecb61682a0ee426faaa03d824fc8fd7aef826
----
- src/gallium/state_trackers/dri/dri2.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/src/gallium/state_trackers/dri/dri2.c b/src/gallium/state_trackers/dri/dri2.c
-index 31d17d46c2..58a6757f03 100644
---- a/src/gallium/state_trackers/dri/dri2.c
-+++ b/src/gallium/state_trackers/dri/dri2.c
-@@ -806,6 +806,7 @@ dri2_allocate_textures(struct dri_context *ctx,
-          whandle.handle = buf->name;
-          whandle.stride = buf->pitch;
-          whandle.offset = 0;
-+         whandle.modifier = DRM_FORMAT_MOD_INVALID;
-          if (screen->can_share_buffer)
-             whandle.type = DRM_API_HANDLE_TYPE_SHARED;
-          else
--- 
-2.14.3
-
diff --git a/poky/meta/recipes-graphics/mesa/files/0001-winsys-svga-drm-Include-sys-types.h.patch b/poky/meta/recipes-graphics/mesa/files/0001-winsys-svga-drm-Include-sys-types.h.patch
deleted file mode 100644
index 549b867..0000000
--- a/poky/meta/recipes-graphics/mesa/files/0001-winsys-svga-drm-Include-sys-types.h.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From d8750776404b1031d762966d0f551d13d2fe05a7 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 16 Aug 2017 18:58:20 -0700
-Subject: [PATCH] winsys/svga/drm: Include sys/types.h
-
-vmw_screen.h uses dev_t which is defines in sys/types.h
-this header is required to be included for getting dev_t
-definition. This issue happens on musl C library, it is hidden
-on glibc since sys/types.h is included through another
-system headers
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-
-Upstream-Status: Submitted
-
- src/gallium/winsys/svga/drm/vmw_screen.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/src/gallium/winsys/svga/drm/vmw_screen.h b/src/gallium/winsys/svga/drm/vmw_screen.h
-index 0ef8e84..2eda97e 100644
---- a/src/gallium/winsys/svga/drm/vmw_screen.h
-+++ b/src/gallium/winsys/svga/drm/vmw_screen.h
-@@ -41,6 +41,7 @@
- #include "svga_winsys.h"
- #include "pipebuffer/pb_buffer_fenced.h"
- #include <os/os_thread.h>
-+#include <sys/types.h>
- 
- #define VMW_GMR_POOL_SIZE (16*1024*1024)
- #define VMW_QUERY_POOL_SIZE (8192)
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-graphics/mesa/files/0002-hardware-gloat.patch b/poky/meta/recipes-graphics/mesa/files/0002-hardware-gloat.patch
deleted file mode 100644
index 0e014dc..0000000
--- a/poky/meta/recipes-graphics/mesa/files/0002-hardware-gloat.patch
+++ /dev/null
@@ -1,51 +0,0 @@
-From 00bcd599310dc7fce4fe336ffd85902429051a0c Mon Sep 17 00:00:00 2001
-From: Igor Gnatenko <i.gnatenko.brain@gmail.com>
-Date: Sun, 20 Mar 2016 13:27:04 +0100
-Subject: [PATCH 2/4] hardware gloat
-
-Upstream-Status: Inappropriate [not author]
-Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
----
- src/gallium/drivers/llvmpipe/lp_screen.c | 7 +++++++
- src/gallium/drivers/softpipe/sp_screen.c | 7 +++++++
- 2 files changed, 14 insertions(+)
-
-diff --git a/src/gallium/drivers/llvmpipe/lp_screen.c b/src/gallium/drivers/llvmpipe/lp_screen.c
-index 4f61de8..3b0ec77 100644
---- a/src/gallium/drivers/llvmpipe/lp_screen.c
-+++ b/src/gallium/drivers/llvmpipe/lp_screen.c
-@@ -411,6 +411,13 @@ llvmpipe_is_format_supported( struct pipe_screen *_screen,
-    if (!format_desc)
-       return FALSE;
- 
-+   if ((bind & PIPE_BIND_RENDER_TARGET) &&
-+       format != PIPE_FORMAT_R9G9B9E5_FLOAT &&
-+       format != PIPE_FORMAT_R11G11B10_FLOAT &&
-+       util_format_is_float(format)) {
-+      return FALSE;
-+   }
-+
-    assert(target == PIPE_BUFFER ||
-           target == PIPE_TEXTURE_1D ||
-           target == PIPE_TEXTURE_1D_ARRAY ||
-diff --git a/src/gallium/drivers/softpipe/sp_screen.c b/src/gallium/drivers/softpipe/sp_screen.c
-index 031602b..c279120 100644
---- a/src/gallium/drivers/softpipe/sp_screen.c
-+++ b/src/gallium/drivers/softpipe/sp_screen.c
-@@ -358,6 +358,13 @@ softpipe_is_format_supported( struct pipe_screen *screen,
-    if (!format_desc)
-       return FALSE;
- 
-+   if ((bind & PIPE_BIND_RENDER_TARGET) &&
-+       format != PIPE_FORMAT_R9G9B9E5_FLOAT &&
-+       format != PIPE_FORMAT_R11G11B10_FLOAT &&
-+       util_format_is_float(format)) {
-+      return FALSE;
-+   }
-+
-    if (sample_count > 1)
-       return FALSE;
- 
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-graphics/mesa/files/0002-winsys-svga-drm-Include-sys-types.h.patch b/poky/meta/recipes-graphics/mesa/files/0002-winsys-svga-drm-Include-sys-types.h.patch
new file mode 100644
index 0000000..ffb3bf7
--- /dev/null
+++ b/poky/meta/recipes-graphics/mesa/files/0002-winsys-svga-drm-Include-sys-types.h.patch
@@ -0,0 +1,34 @@
+From 7792f228991744a0396b8bf811e281dca86165d3 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 16 Aug 2017 18:58:20 -0700
+Subject: [PATCH 2/6] winsys/svga/drm: Include sys/types.h
+Organization: O.S. Systems Software LTDA.
+
+vmw_screen.h uses dev_t which is defines in sys/types.h
+this header is required to be included for getting dev_t
+definition. This issue happens on musl C library, it is hidden
+on glibc since sys/types.h is included through another
+system headers
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Backport [7dfdfbf8c37e52e7b9b09f7d1d434edad3ebc864]
+Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
+---
+ src/gallium/winsys/svga/drm/vmw_screen.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/gallium/winsys/svga/drm/vmw_screen.h b/src/gallium/winsys/svga/drm/vmw_screen.h
+index f21cabb51f..4c972fdaa9 100644
+--- a/src/gallium/winsys/svga/drm/vmw_screen.h
++++ b/src/gallium/winsys/svga/drm/vmw_screen.h
+@@ -41,6 +41,7 @@
+ #include "svga_winsys.h"
+ #include "pipebuffer/pb_buffer_fenced.h"
+ #include <os/os_thread.h>
++#include <sys/types.h>
+ 
+ #define VMW_GMR_POOL_SIZE (16*1024*1024)
+ #define VMW_QUERY_POOL_SIZE (8192)
+-- 
+2.18.0
+
diff --git a/poky/meta/recipes-graphics/mesa/files/0003-Properly-get-LLVM-version-when-using-LLVM-Git-releas.patch b/poky/meta/recipes-graphics/mesa/files/0003-Properly-get-LLVM-version-when-using-LLVM-Git-releas.patch
new file mode 100644
index 0000000..5e735ca
--- /dev/null
+++ b/poky/meta/recipes-graphics/mesa/files/0003-Properly-get-LLVM-version-when-using-LLVM-Git-releas.patch
@@ -0,0 +1,44 @@
+From 8b42fb47138f91d9378439ab716bac7701e4e326 Mon Sep 17 00:00:00 2001
+From: Otavio Salvador <otavio@ossystems.com.br>
+Date: Tue, 5 Jun 2018 11:11:10 -0300
+Subject: [PATCH 3/6] Properly get LLVM version when using LLVM Git releases
+Organization: O.S. Systems Software LTDA.
+
+$ llvm-config-host --version
+5.0.0git-9a5c333388c
+
+We need to ignore everything after 5.0.0 which is what the cut cmd is
+doing
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
+---
+ configure.ac | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 916d0bd207..dd172f1ebe 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -1090,7 +1090,7 @@ strip_unwanted_llvm_flags() {
+ 
+ llvm_set_environment_variables() {
+     if test "x$LLVM_CONFIG" != xno; then
+-        LLVM_VERSION=`$LLVM_CONFIG --version | egrep -o '^[[0-9.]]+'`
++        LLVM_VERSION=`$LLVM_CONFIG --version | cut -c1-5`
+         LLVM_CPPFLAGS=`strip_unwanted_llvm_flags "$LLVM_CONFIG --cppflags"`
+         LLVM_INCLUDEDIR=`$LLVM_CONFIG --includedir`
+         LLVM_LIBDIR=`$LLVM_CONFIG --libdir`
+@@ -2808,7 +2808,7 @@ detect_old_buggy_llvm() {
+     dnl ourselves.
+     dnl (See https://llvm.org/bugs/show_bug.cgi?id=6823)
+     dnl We can't use $LLVM_VERSION because it has 'svn' stripped out,
+-    LLVM_SO_NAME=LLVM-`$LLVM_CONFIG --version`
++    LLVM_SO_NAME=LLVM-`$LLVM_CONFIG --version | cut -c1-5`
+     AS_IF([test -f "$LLVM_LIBDIR/lib$LLVM_SO_NAME.$IMP_LIB_EXT"], [llvm_have_one_so=yes])
+ 
+     if test "x$llvm_have_one_so" = xyes; then
+-- 
+2.18.0
+
diff --git a/poky/meta/recipes-graphics/mesa/files/0004-Use-Python-3-to-execute-the-scripts.patch b/poky/meta/recipes-graphics/mesa/files/0004-Use-Python-3-to-execute-the-scripts.patch
new file mode 100644
index 0000000..8953c4a
--- /dev/null
+++ b/poky/meta/recipes-graphics/mesa/files/0004-Use-Python-3-to-execute-the-scripts.patch
@@ -0,0 +1,32 @@
+From ebe6077a1d74e56b28249f71e8760295fa846ed2 Mon Sep 17 00:00:00 2001
+From: Otavio Salvador <otavio@ossystems.com.br>
+Date: Fri, 29 Dec 2017 10:27:59 -0200
+Subject: [PATCH 4/6] Use Python 3 to execute the scripts
+Organization: O.S. Systems Software LTDA.
+
+The MESA build system uses Python 2 but as OE-Core has moved away from
+it, we change it to use Python 3 instead.
+
+Upstream-Status: Inappropriate [ configuration ]
+
+Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index dd172f1ebe..40cac36ac2 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -122,7 +122,7 @@ AM_PROG_CC_C_O
+ AC_PROG_NM
+ AM_PROG_AS
+ AX_CHECK_GNU_MAKE
+-AC_CHECK_PROGS([PYTHON2], [python2.7 python2 python])
++AC_CHECK_PROGS([PYTHON2], [python3.5 python3 python])
+ AC_PROG_SED
+ AC_PROG_MKDIR_P
+ 
+-- 
+2.18.0
+
diff --git a/poky/meta/recipes-graphics/mesa/files/0005-dri-i965-Add-missing-time.h-include.patch b/poky/meta/recipes-graphics/mesa/files/0005-dri-i965-Add-missing-time.h-include.patch
new file mode 100644
index 0000000..d40e7b5
--- /dev/null
+++ b/poky/meta/recipes-graphics/mesa/files/0005-dri-i965-Add-missing-time.h-include.patch
@@ -0,0 +1,36 @@
+From 9e0368af471af3a36e0eb526453f892598120065 Mon Sep 17 00:00:00 2001
+From: Otavio Salvador <otavio@ossystems.com.br>
+Date: Wed, 6 Jun 2018 09:50:35 -0300
+Subject: [PATCH 5/6] dri: i965: Add missing time.h include
+Organization: O.S. Systems Software LTDA.
+
+This fixes a build error when using musl:
+
+,----
+| In file included from .../src/mesa/drivers/dri/i965/intel_upload.c:33:0:
+| .../src/mesa/drivers/dri/i965/brw_bufmgr.h:132:4: error: unknown type name 'time_t'
+|     time_t free_time;
+|     ^~~~~~
+`----
+
+Upstream-Status: Backport [3c288da5eec81ee58b85927df18d9194ead8f5c2]
+Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
+---
+ src/mesa/drivers/dri/i965/brw_bufmgr.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/mesa/drivers/dri/i965/brw_bufmgr.h b/src/mesa/drivers/dri/i965/brw_bufmgr.h
+index 68f5e0c2c8..5b60a23763 100644
+--- a/src/mesa/drivers/dri/i965/brw_bufmgr.h
++++ b/src/mesa/drivers/dri/i965/brw_bufmgr.h
+@@ -37,6 +37,7 @@
+ #include <stdbool.h>
+ #include <stdint.h>
+ #include <stdio.h>
++#include <time.h>
+ #include "util/u_atomic.h"
+ #include "util/list.h"
+ 
+-- 
+2.18.0
+
diff --git a/poky/meta/recipes-graphics/mesa/files/0006-use-PKG_CHECK_VAR-for-defining-WAYLAND_PROTOCOLS_DAT.patch b/poky/meta/recipes-graphics/mesa/files/0006-use-PKG_CHECK_VAR-for-defining-WAYLAND_PROTOCOLS_DAT.patch
new file mode 100644
index 0000000..0212922
--- /dev/null
+++ b/poky/meta/recipes-graphics/mesa/files/0006-use-PKG_CHECK_VAR-for-defining-WAYLAND_PROTOCOLS_DAT.patch
@@ -0,0 +1,37 @@
+From 754ccf89a732fc3da6e9bc62ebd6b28686ff3d26 Mon Sep 17 00:00:00 2001
+From: Otavio Salvador <otavio@ossystems.com.br>
+Date: Wed, 29 Aug 2018 22:10:30 -0300
+Subject: [PATCH 6/6] use PKG_CHECK_VAR for defining WAYLAND_PROTOCOLS_DATADIR
+Organization: O.S. Systems Software LTDA.
+
+This allows to override the wayland-protocols pkgdatadir with the
+WAYLAND_PROTOCOLS_DATADIR from environment.
+
+pkgconfig would return an absolute path in
+/usr/share/wayland-protocols
+for the pkgdatadir value, which is not suitable for cross-compiling.
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Pending
+
+Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index 40cac36ac2..728bbdcbc4 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -1823,7 +1823,7 @@ for plat in $platforms; do
+         PKG_CHECK_MODULES([WAYLAND_CLIENT], [wayland-client >= $WAYLAND_REQUIRED])
+         PKG_CHECK_MODULES([WAYLAND_SERVER], [wayland-server >= $WAYLAND_REQUIRED])
+         PKG_CHECK_MODULES([WAYLAND_PROTOCOLS], [wayland-protocols >= $WAYLAND_PROTOCOLS_REQUIRED])
+-        WAYLAND_PROTOCOLS_DATADIR=`$PKG_CONFIG --variable=pkgdatadir wayland-protocols`
++        PKG_CHECK_VAR([WAYLAND_PROTOCOLS_DATADIR], [wayland-protocols >= $WAYLAND_PROTOCOLS_REQUIRED], pkgdatadir)
+ 
+         AC_PATH_PROG([WAYLAND_SCANNER], [wayland-scanner], [:])
+ 
+-- 
+2.18.0
+
diff --git a/poky/meta/recipes-graphics/mesa/files/Use-Python-3-to-execute-the-scripts.patch b/poky/meta/recipes-graphics/mesa/files/Use-Python-3-to-execute-the-scripts.patch
deleted file mode 100644
index 0b4aabf..0000000
--- a/poky/meta/recipes-graphics/mesa/files/Use-Python-3-to-execute-the-scripts.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From 18c3e684a8259a0644214f88c7ead7fa31573fd9 Mon Sep 17 00:00:00 2001
-From: Otavio Salvador <otavio@ossystems.com.br>
-Date: Fri, 29 Dec 2017 10:27:59 -0200
-Subject: [PATCH] Use Python 3 to execute the scripts
-Organization: O.S. Systems Software LTDA.
-
-The MESA build system uses Python 2 but as OE-Core has moved away from
-it, we change it to use Python 3 instead.
-
-Upstream-Status: Inappropriate [ configuration ]
-
-Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
----
- configure.ac | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/configure.ac b/configure.ac
-index b107f04c2e..055546142d 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -114,7 +114,7 @@ AC_PROG_CXX
- AM_PROG_CC_C_O
- AM_PROG_AS
- AX_CHECK_GNU_MAKE
--AC_CHECK_PROGS([PYTHON2], [python2.7 python2 python])
-+AC_CHECK_PROGS([PYTHON2], [python3.5 python3 python])
- AC_PROG_SED
- AC_PROG_MKDIR_P
- 
--- 
-2.15.1
-
diff --git a/poky/meta/recipes-graphics/mesa/files/disable-asm-on-non-gcc.patch b/poky/meta/recipes-graphics/mesa/files/disable-asm-on-non-gcc.patch
deleted file mode 100644
index d2d6755..0000000
--- a/poky/meta/recipes-graphics/mesa/files/disable-asm-on-non-gcc.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-Configure checks for compiler to be gcc and then it enables asm_offsets
-generation. see
-
-https://cgit.freedesktop.org/mesa/mesa/commit/?id=73c9b4b0e05fc66629ba250846948dc55c0e7a0d
-
-However, we missed the check when enabling this on cross compilation
-when architecture for both host and target is x86
-
-Fixes errors like
-./gen_matypes > matypes.h
-/bin/bash: ./gen_matypes: No such file or directory
-
--Khem
-
-Upstream-Status: Submitted
-
-Index: mesa-12.0.1/configure.ac
-===================================================================
---- mesa-12.0.1.orig/configure.ac
-+++ mesa-12.0.1/configure.ac
-@@ -732,7 +732,7 @@ test "x$enable_asm" = xno && AC_MSG_RESU
- if test "x$enable_asm" = xyes -a "x$cross_compiling" = xyes; then
-     case "$host_cpu" in
-     i?86 | x86_64 | amd64)
--        if test "x$host_cpu" != "x$target_cpu"; then
-+        if test "x$host_cpu" != "x$target_cpu" -o "x$acv_mesa_CLANG" = xyes; then
-             enable_asm=no
-             AC_MSG_RESULT([no, cross compiling])
-         fi
diff --git a/poky/meta/recipes-graphics/mesa/files/llvm-config-version.patch b/poky/meta/recipes-graphics/mesa/files/llvm-config-version.patch
deleted file mode 100644
index fd79991..0000000
--- a/poky/meta/recipes-graphics/mesa/files/llvm-config-version.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From: Otavio Salvador <otavio@ossystems.com.br>
-Subject: [PATCH] Properly get LLVM version when using LLVM Git releases
-
-$ llvm-config-host --version
-5.0.0git-9a5c333388c
-
-We need to ignore everything after 5.0.0 which is what the cut cmd is
-doing
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
----
- configure.ac | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index a02173f244..b107f04c2e 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -995,7 +995,7 @@ strip_unwanted_llvm_flags() {
- 
- llvm_set_environment_variables() {
-     if test "x$LLVM_CONFIG" != xno; then
--        LLVM_VERSION=`$LLVM_CONFIG --version | egrep -o '^[[0-9.]]+'`
-+        LLVM_VERSION=`$LLVM_CONFIG --version | cut -c1-5`
-         LLVM_CPPFLAGS=`strip_unwanted_llvm_flags "$LLVM_CONFIG --cppflags"`
-         LLVM_INCLUDEDIR=`$LLVM_CONFIG --includedir`
-         LLVM_LIBDIR=`$LLVM_CONFIG --libdir`
-@@ -2644,7 +2644,7 @@ detect_old_buggy_llvm() {
-     dnl ourselves.
-     dnl (See https://llvm.org/bugs/show_bug.cgi?id=6823)
-     dnl We can't use $LLVM_VERSION because it has 'svn' stripped out,
--    LLVM_SO_NAME=LLVM-`$LLVM_CONFIG --version`
-+    LLVM_SO_NAME=LLVM-`$LLVM_CONFIG --version | cut -c1-5`
-     AS_IF([test -f "$LLVM_LIBDIR/lib$LLVM_SO_NAME.$IMP_LIB_EXT"], [llvm_have_one_so=yes])
- 
-     if test "x$llvm_have_one_so" = xyes; then
--- 
-2.15.1
-
diff --git a/poky/meta/recipes-graphics/mesa/mesa-gl_17.3.8.bb b/poky/meta/recipes-graphics/mesa/mesa-gl_18.1.9.bb
similarity index 100%
rename from poky/meta/recipes-graphics/mesa/mesa-gl_17.3.8.bb
rename to poky/meta/recipes-graphics/mesa/mesa-gl_18.1.9.bb
diff --git a/poky/meta/recipes-graphics/mesa/mesa.inc b/poky/meta/recipes-graphics/mesa/mesa.inc
index b501b7e..0cc0a82 100644
--- a/poky/meta/recipes-graphics/mesa/mesa.inc
+++ b/poky/meta/recipes-graphics/mesa/mesa.inc
@@ -29,12 +29,16 @@
 ANY_OF_DISTRO_FEATURES = "opengl vulkan"
 
 PLATFORMS ??= "${@bb.utils.filter('PACKAGECONFIG', 'x11 wayland', d)} \
-               ${@bb.utils.contains('PACKAGECONFIG', 'gbm', 'drm', '', d)}"
+               ${@bb.utils.contains('PACKAGECONFIG', 'gbm', 'drm', '', d)} \
+               surfaceless"
 
 export LLVM_CONFIG = "${STAGING_BINDIR_NATIVE}/llvm-config${MESA_LLVM_RELEASE}"
 export YOCTO_ALTERNATE_EXE_PATH = "${STAGING_LIBDIR}/llvm${MESA_LLVM_RELEASE}/llvm-config"
+export YOCTO_ALTERNATE_MULTILIB_NAME = "${base_libdir}"
 EXTRA_OECONF = "--enable-shared-glapi \
                 --disable-opencl \
+                --enable-glx-read-only-text \
+                PYTHON2=python2 \
                 --with-llvm-prefix=${STAGING_LIBDIR}/llvm${MESA_LLVM_RELEASE} \
                 --with-platforms='${PLATFORMS}'"
 
@@ -47,7 +51,7 @@
 # "gbm" requires "dri", "opengl"
 PACKAGECONFIG[gbm] = "--enable-gbm,--disable-gbm"
 
-X11_DEPS = "xf86driproto glproto virtual/libx11 libxext libxxf86vm libxdamage libxfixes"
+X11_DEPS = "xorgproto virtual/libx11 libxext libxxf86vm libxdamage libxfixes"
 # "x11" requires "opengl"
 PACKAGECONFIG[x11] = "--enable-glx-tls,--disable-glx,${X11_DEPS}"
 PACKAGECONFIG[xvmc] = "--enable-xvmc,--disable-xvmc,libxvmc"
@@ -57,8 +61,8 @@
 DRIDRIVERS_append_x86 = ",radeon,r200,nouveau,i965,i915"
 DRIDRIVERS_append_x86-64 = ",radeon,r200,nouveau,i965,i915"
 # "dri" requires "opengl"
-PACKAGECONFIG[dri] = "--enable-dri --with-dri-drivers=${DRIDRIVERS}, --disable-dri, dri2proto libdrm"
-PACKAGECONFIG[dri3] = "--enable-dri3, --disable-dri3, dri3proto presentproto libxshmfence"
+PACKAGECONFIG[dri] = "--enable-dri --with-dri-drivers=${DRIDRIVERS}, --disable-dri, xorgproto libdrm"
+PACKAGECONFIG[dri3] = "--enable-dri3, --disable-dri3, xorgproto libxshmfence"
 
 # Vulkan drivers need dri3 enabled
 # radeon could be enabled as well but requires gallium-llvm with llvm >= 3.9
@@ -87,6 +91,8 @@
 GALLIUMDRIVERS_LLVM = "r300,svga,nouveau${@',${GALLIUMDRIVERS_LLVM33}' if ${GALLIUMDRIVERS_LLVM33_ENABLED} else ''}"
 GALLIUMDRIVERS_append_x86 = "${@bb.utils.contains('PACKAGECONFIG', 'gallium-llvm', ',${GALLIUMDRIVERS_LLVM}', '', d)}"
 GALLIUMDRIVERS_append_x86-64 = "${@bb.utils.contains('PACKAGECONFIG', 'gallium-llvm', ',${GALLIUMDRIVERS_LLVM}', '', d)}"
+GALLIUMDRIVERS_append_x86 = ",virgl"
+GALLIUMDRIVERS_append_x86-64 = ",virgl"
 # keep --with-gallium-drivers separate, because when only one of gallium versions is enabled, other 2 were adding --without-gallium-drivers
 PACKAGECONFIG[gallium]      = "--enable-texture-float --with-gallium-drivers=${GALLIUMDRIVERS}, --without-gallium-drivers"
 MESA_LLVM_RELEASE ?= "6.0"
@@ -100,10 +106,15 @@
 
 PACKAGECONFIG[unwind] = "--enable-libunwind,--disable-libunwind,libunwind"
 
+EXTRA_OECONF_remove_libc-musl = "--enable-glx-tls"
+EXTRA_OECONF_append_libc-musl = " --disable-glx-tls"
+EXTRA_OECONF_append_libc-musl_x86 = " --disable-asm"
+
 # llvmpipe is slow if compiled with -fomit-frame-pointer (e.g. -O2)
 FULL_OPTIMIZATION_append = " -fno-omit-frame-pointer"
 
 CFLAGS_append_armv5 = " -DMISSING_64BIT_ATOMICS"
+EXTRA_OEMAKE += "WAYLAND_PROTOCOLS_DATADIR=${STAGING_DATADIR}/wayland-protocols"
 
 # Remove the mesa dependency on mesa-dev, as mesa is empty
 RDEPENDS_${PN}-dev = ""
@@ -119,7 +130,6 @@
              libgles1-mesa libgles1-mesa-dev \
              libgles2-mesa libgles2-mesa-dev \
              libgles3-mesa libgles3-mesa-dev \
-             libwayland-egl libwayland-egl-dev \
              libxatracker libxatracker-dev \
              mesa-megadriver mesa-vulkan-drivers \
             "
@@ -134,6 +144,11 @@
     # it was packaged in libdricore9.1.3-1 and preventing upgrades when debian.bbclass was used 
     rm -f ${D}${sysconfdir}/drirc
     chrpath --delete ${D}${libdir}/dri/*_dri.so || true
+
+    # libwayland-egl has been moved to wayland 1.15+
+    rm -f ${D}${libdir}/libwayland-egl*
+    rm -f ${D}${libdir}/pkgconfig/wayland-egl.pc
+    rmdir --ignore-fail-on-non-empty ${D}${libdir}/pkgconfig
 }
 
 # For the packages that make up the OpenGL interfaces, inject variables so that
@@ -204,7 +219,6 @@
 FILES_libgl-mesa = "${libdir}/libGL.so.*"
 FILES_libglapi = "${libdir}/libglapi.so.*"
 FILES_libosmesa = "${libdir}/libOSMesa.so.*"
-FILES_libwayland-egl = "${libdir}/libwayland-egl.so.*"
 FILES_libxatracker = "${libdir}/libxatracker.so.*"
 
 FILES_${PN}-dev = "${libdir}/pkgconfig/dri.pc ${includedir}/vulkan"
@@ -216,7 +230,6 @@
 FILES_libgles2-mesa-dev = "${libdir}/libGLESv2.* ${includedir}/GLES2 ${libdir}/pkgconfig/glesv2.pc"
 FILES_libgles3-mesa-dev = "${includedir}/GLES3"
 FILES_libosmesa-dev = "${libdir}/libOSMesa.* ${includedir}/GL/osmesa.h ${libdir}/pkgconfig/osmesa.pc"
-FILES_libwayland-egl-dev = "${libdir}/pkgconfig/wayland-egl.pc ${libdir}/libwayland-egl.*"
 FILES_libxatracker-dev = "${libdir}/libxatracker.so ${libdir}/libxatracker.la \
                           ${includedir}/xa_tracker.h ${includedir}/xa_composite.h ${includedir}/xa_context.h \
                           ${libdir}/pkgconfig/xatracker.pc"
diff --git a/poky/meta/recipes-graphics/mesa/mesa_17.3.8.bb b/poky/meta/recipes-graphics/mesa/mesa_17.3.8.bb
deleted file mode 100644
index 2d3fd3c..0000000
--- a/poky/meta/recipes-graphics/mesa/mesa_17.3.8.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-require ${BPN}.inc
-
-SRC_URI = "https://mesa.freedesktop.org/archive/mesa-${PV}.tar.xz \
-           file://disable-asm-on-non-gcc.patch \
-	   file://Use-Python-3-to-execute-the-scripts.patch \
-           file://0001-Use-wayland-scanner-in-the-path.patch \
-           file://0002-hardware-gloat.patch \
-           file://llvm-config-version.patch \
-           file://0001-winsys-svga-drm-Include-sys-types.h.patch \
-           file://0001-Makefile.vulkan.am-explictly-add-lib-expat-to-intel-.patch \
-           file://0001-st-dri-Initialise-modifier-to-INVALID-for-DRI2.patch \
-           "
-
-SRC_URI[md5sum] = "203d1a79156ab6926f2d253b377e9d9d"
-SRC_URI[sha256sum] = "8f9d9bf281c48e4a8f5228816577263b4c655248dc7666e75034ab422951a6b1"
-
-#because we cannot rely on the fact that all apps will use pkgconfig,
-#make eglplatform.h independent of MESA_EGL_NO_X11_HEADER
-do_install_append() {
-    if ${@bb.utils.contains('PACKAGECONFIG', 'egl', 'true', 'false', d)}; then
-        sed -i -e 's/^#if defined(MESA_EGL_NO_X11_HEADERS)$/#if defined(MESA_EGL_NO_X11_HEADERS) || ${@bb.utils.contains('PACKAGECONFIG', 'x11', '0', '1', d)}/' ${D}${includedir}/EGL/eglplatform.h
-    fi
-}
diff --git a/poky/meta/recipes-graphics/mesa/mesa_18.1.9.bb b/poky/meta/recipes-graphics/mesa/mesa_18.1.9.bb
new file mode 100644
index 0000000..86d6a6b
--- /dev/null
+++ b/poky/meta/recipes-graphics/mesa/mesa_18.1.9.bb
@@ -0,0 +1,21 @@
+require ${BPN}.inc
+
+SRC_URI = "https://mesa.freedesktop.org/archive/mesa-${PV}.tar.xz \
+           file://0001-Simplify-wayland-scanner-lookup.patch \
+           file://0002-winsys-svga-drm-Include-sys-types.h.patch \
+           file://0003-Properly-get-LLVM-version-when-using-LLVM-Git-releas.patch \
+           file://0004-Use-Python-3-to-execute-the-scripts.patch \
+           file://0005-dri-i965-Add-missing-time.h-include.patch \
+           file://0006-use-PKG_CHECK_VAR-for-defining-WAYLAND_PROTOCOLS_DAT.patch \
+"
+
+SRC_URI[md5sum] = "2f8d2098ab478bc3907e42130577b54a"
+SRC_URI[sha256sum] = "55f5778d58a710a63d6635f000535768faf7db9e8144dc0f4fd1989f936c1a83"
+
+#because we cannot rely on the fact that all apps will use pkgconfig,
+#make eglplatform.h independent of MESA_EGL_NO_X11_HEADER
+do_install_append() {
+    if ${@bb.utils.contains('PACKAGECONFIG', 'egl', 'true', 'false', d)}; then
+        sed -i -e 's/^#if defined(MESA_EGL_NO_X11_HEADERS)$/#if defined(MESA_EGL_NO_X11_HEADERS) || ${@bb.utils.contains('PACKAGECONFIG', 'x11', '0', '1', d)}/' ${D}${includedir}/EGL/eglplatform.h
+    fi
+}
diff --git a/poky/meta/recipes-graphics/pango/pango/0001-Drop-introspection-macros-from-acinclude.m4.patch b/poky/meta/recipes-graphics/pango/pango/0001-Drop-introspection-macros-from-acinclude.m4.patch
deleted file mode 100644
index 9e1626e..0000000
--- a/poky/meta/recipes-graphics/pango/pango/0001-Drop-introspection-macros-from-acinclude.m4.patch
+++ /dev/null
@@ -1,120 +0,0 @@
-From 867a512eddbeb1899d3e7096df3da1dd0ce3e7b7 Mon Sep 17 00:00:00 2001
-From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Fri, 23 Oct 2015 14:06:17 +0300
-Subject: [PATCH] Drop introspection macros from acinclude.m4
-
-They take precendence over our customized macros, and so
-introspection doesn't work correctly.
-
-Upstream-Status: Backport [upstream 5ccfe0]
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
----
- acinclude.m4 | 96 ------------------------------------------------------------
- 1 file changed, 96 deletions(-)
-
-diff --git a/acinclude.m4 b/acinclude.m4
-index 8899c7c..48fd5d8 100644
---- a/acinclude.m4
-+++ b/acinclude.m4
-@@ -55,99 +55,3 @@ AC_DEFUN([JH_CHECK_XML_CATALOG],
- ])
- 
- 
--dnl REMOVE THIS WHEN introspection.m4 is widely available
--dnl
--dnl -*- mode: autoconf -*-
--dnl Copyright 2009 Johan Dahlin
--dnl
--dnl This file is free software; the author(s) gives unlimited
--dnl permission to copy and/or distribute it, with or without
--dnl modifications, as long as this notice is preserved.
--dnl
--
--# serial 1
--
--m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL],
--[
--    AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first
--    AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first
--    AC_BEFORE([LT_INIT],[$0])dnl setup libtool first
--
--    dnl enable/disable introspection
--    m4_if([$2], [require],
--    [dnl
--        enable_introspection=yes
--    ],[dnl
--        AC_ARG_ENABLE(introspection,
--                  AS_HELP_STRING([--enable-introspection[=@<:@no/auto/yes@:>@]],
--                                 [Enable introspection for this build]),, 
--                                 [enable_introspection=auto])
--    ])dnl
--
--    AC_MSG_CHECKING([for gobject-introspection])
--
--    dnl presence/version checking
--    AS_CASE([$enable_introspection],
--    [no], [dnl
--        found_introspection="no (disabled, use --enable-introspection to enable)"
--    ],dnl
--    [yes],[dnl
--        PKG_CHECK_EXISTS([gobject-introspection-1.0],,
--                         AC_MSG_ERROR([gobject-introspection-1.0 is not installed]))
--        PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1],
--                         found_introspection=yes,
--                         AC_MSG_ERROR([You need to have gobject-introspection >= $1 installed to build AC_PACKAGE_NAME]))
--    ],dnl
--    [auto],[dnl
--        PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1], found_introspection=yes, found_introspection=no)
--    ],dnl
--    [dnl	
--        AC_MSG_ERROR([invalid argument passed to --enable-introspection, should be one of @<:@no/auto/yes@:>@])
--    ])dnl
--
--    AC_MSG_RESULT([$found_introspection])
--
--    INTROSPECTION_SCANNER=
--    INTROSPECTION_COMPILER=
--    INTROSPECTION_GENERATE=
--    INTROSPECTION_GIRDIR=
--    INTROSPECTION_TYPELIBDIR=
--    if test "x$found_introspection" = "xyes"; then
--       INTROSPECTION_SCANNER=`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0`
--       INTROSPECTION_COMPILER=`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0`
--       INTROSPECTION_GENERATE=`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0`
--       INTROSPECTION_GIRDIR=`$PKG_CONFIG --variable=girdir gobject-introspection-1.0`
--       INTROSPECTION_TYPELIBDIR="$($PKG_CONFIG --variable=typelibdir gobject-introspection-1.0)"
--       INTROSPECTION_CFLAGS=`$PKG_CONFIG --cflags gobject-introspection-1.0`
--       INTROSPECTION_LIBS=`$PKG_CONFIG --libs gobject-introspection-1.0`
--       INTROSPECTION_MAKEFILE=`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection
--    fi
--    AC_SUBST(INTROSPECTION_SCANNER)
--    AC_SUBST(INTROSPECTION_COMPILER)
--    AC_SUBST(INTROSPECTION_GENERATE)
--    AC_SUBST(INTROSPECTION_GIRDIR)
--    AC_SUBST(INTROSPECTION_TYPELIBDIR)
--    AC_SUBST(INTROSPECTION_CFLAGS)
--    AC_SUBST(INTROSPECTION_LIBS)
--    AC_SUBST(INTROSPECTION_MAKEFILE)
--
--    AM_CONDITIONAL(HAVE_INTROSPECTION, test "x$found_introspection" = "xyes")
--])
--
--
--dnl Usage:
--dnl   GOBJECT_INTROSPECTION_CHECK([minimum-g-i-version])
--
--AC_DEFUN([GOBJECT_INTROSPECTION_CHECK],
--[
--  _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1])
--])
--
--dnl Usage:
--dnl   GOBJECT_INTROSPECTION_REQUIRE([minimum-g-i-version])
--
--
--AC_DEFUN([GOBJECT_INTROSPECTION_REQUIRE],
--[
--  _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1], [require])
--])
--- 
-2.1.4
diff --git a/poky/meta/recipes-graphics/pango/pango_1.40.14.bb b/poky/meta/recipes-graphics/pango/pango_1.40.14.bb
deleted file mode 100644
index 3bd9c64..0000000
--- a/poky/meta/recipes-graphics/pango/pango_1.40.14.bb
+++ /dev/null
@@ -1,50 +0,0 @@
-SUMMARY = "Framework for layout and rendering of internationalized text"
-DESCRIPTION = "Pango is a library for laying out and rendering of text, \
-with an emphasis on internationalization. Pango can be used anywhere \
-that text layout is needed, though most of the work on Pango so far has \
-been done in the context of the GTK+ widget toolkit. Pango forms the \
-core of text and font handling for GTK+-2.x."
-HOMEPAGE = "http://www.pango.org/"
-BUGTRACKER = "http://bugzilla.gnome.org"
-SECTION = "libs"
-LICENSE = "LGPLv2.0+"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=3bf50002aefd002f49e7bb854063f7e7"
-
-inherit gnomebase gtk-doc ptest-gnome upstream-version-is-even gobject-introspection
-
-SRC_URI += "file://run-ptest \
-            file://0001-Drop-introspection-macros-from-acinclude.m4.patch \
-            file://0001-Enforce-recreation-of-docs-pango.types-it-is-build-c.patch \
-"
-SRC_URI[archive.md5sum] = "18d7eb8d52e7e445e733c109ddaa7b78"
-SRC_URI[archive.sha256sum] = "90af1beaa7bf9e4c52db29ec251ec4fd0a8f2cc185d521ad1f88d01b3a6a17e3"
-
-DEPENDS = "glib-2.0 glib-2.0-native fontconfig freetype virtual/libiconv cairo harfbuzz"
-
-PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}"
-PACKAGECONFIG[x11] = "--with-xft,--without-xft,virtual/libx11 libxft"
-
-EXTRA_OECONF = " \
-	        --disable-debug \
-	        "
-
-LEAD_SONAME = "libpango-1.0*"
-LIBV = "1.8.0"
-
-# This binary needs to be compiled for the host architecture.  This isn't pretty!
-do_compile_prepend_class-target () {
-	if ${@bb.utils.contains('DISTRO_FEATURES', 'ptest', 'true', 'false', d)}; then
-		make CC="${BUILD_CC}" CFLAGS="" LDFLAGS="${BUILD_LDFLAGS}" AM_CPPFLAGS="$(pkg-config-native --cflags glib-2.0)" gen_all_unicode_LDADD="$(pkg-config-native --libs glib-2.0)" -C ${B}/tests gen-all-unicode
-	fi
-}
-
-FILES_${PN} = "${bindir}/* ${libdir}/libpango*${SOLIBS}"
-FILES_${PN}-dev += "${libdir}/pango/${LIBV}/modules/*.la"
-
-RDEPENDS_${PN}-ptest += "liberation-fonts cantarell-fonts"
-
-RPROVIDES_${PN} += "pango-modules pango-module-indic-lang \
-                    pango-module-basic-fc pango-module-arabic-lang"
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-graphics/pango/pango_1.42.4.bb b/poky/meta/recipes-graphics/pango/pango_1.42.4.bb
new file mode 100644
index 0000000..22fe3af
--- /dev/null
+++ b/poky/meta/recipes-graphics/pango/pango_1.42.4.bb
@@ -0,0 +1,45 @@
+SUMMARY = "Framework for layout and rendering of internationalized text"
+DESCRIPTION = "Pango is a library for laying out and rendering of text, \
+with an emphasis on internationalization. Pango can be used anywhere \
+that text layout is needed, though most of the work on Pango so far has \
+been done in the context of the GTK+ widget toolkit. Pango forms the \
+core of text and font handling for GTK+-2.x."
+HOMEPAGE = "http://www.pango.org/"
+BUGTRACKER = "http://bugzilla.gnome.org"
+SECTION = "libs"
+LICENSE = "LGPLv2.0+"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=3bf50002aefd002f49e7bb854063f7e7"
+
+inherit gnomebase gtk-doc ptest-gnome upstream-version-is-even gobject-introspection
+
+SRC_URI += "file://run-ptest \
+            file://0001-Enforce-recreation-of-docs-pango.types-it-is-build-c.patch \
+"
+SRC_URI[archive.md5sum] = "deb171a31a3ad76342d5195a1b5bbc7c"
+SRC_URI[archive.sha256sum] = "1d2b74cd63e8bd41961f2f8d952355aa0f9be6002b52c8aa7699d9f5da597c9d"
+
+DEPENDS = "glib-2.0 glib-2.0-native fontconfig freetype virtual/libiconv cairo harfbuzz fribidi"
+
+PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}"
+PACKAGECONFIG[x11] = "--with-xft,--without-xft,virtual/libx11 libxft"
+
+LEAD_SONAME = "libpango-1.0*"
+LIBV = "1.8.0"
+
+# This binary needs to be compiled for the host architecture.  This isn't pretty!
+do_compile_prepend_class-target () {
+	if ${@bb.utils.contains('PTEST_ENABLED', '1', 'true', 'false', d)}; then
+		make CC="${BUILD_CC}" CFLAGS="" LDFLAGS="${BUILD_LDFLAGS}" AM_CPPFLAGS="$(pkg-config-native --cflags glib-2.0)" gen_all_unicode_LDADD="$(pkg-config-native --libs glib-2.0)" -C ${B}/tests gen-all-unicode
+	fi
+}
+
+FILES_${PN} = "${bindir}/* ${libdir}/libpango*${SOLIBS}"
+FILES_${PN}-dev += "${libdir}/pango/${LIBV}/modules/*.la"
+
+RDEPENDS_${PN}-ptest += "liberation-fonts cantarell-fonts"
+
+RPROVIDES_${PN} += "pango-modules pango-module-indic-lang \
+                    pango-module-basic-fc pango-module-arabic-lang"
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-graphics/piglit/piglit/0001-cmake-use-proper-WAYLAND_INCLUDE_DIRS-variable.patch b/poky/meta/recipes-graphics/piglit/piglit/0001-cmake-use-proper-WAYLAND_INCLUDE_DIRS-variable.patch
new file mode 100644
index 0000000..5d6ec36
--- /dev/null
+++ b/poky/meta/recipes-graphics/piglit/piglit/0001-cmake-use-proper-WAYLAND_INCLUDE_DIRS-variable.patch
@@ -0,0 +1,32 @@
+From 3bf1beee1ddd19bc536ff2856e04ac269d43daa2 Mon Sep 17 00:00:00 2001
+From: Pascal Bach <pascal.bach@siemens.com>
+Date: Thu, 4 Oct 2018 14:43:17 +0200
+Subject: [PATCH] cmake: use proper WAYLAND_INCLUDE_DIRS variable
+
+WAYLAND_wayland-client_INCLUDEDIR is an internal variable and is not correctly
+set when cross compiling. WAYLAND_INCLUDE_DIRS includes the correct path even
+when cross compiling.
+
+Signed-off-by: Pascal Bach <pascal.bach@siemens.com>
+
+Upstream-Status: Submitted [piglit@lists.freedesktop.org]
+---
+ tests/util/CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/tests/util/CMakeLists.txt b/tests/util/CMakeLists.txt
+index a5f080156..a303a9f58 100644
+--- a/tests/util/CMakeLists.txt
++++ b/tests/util/CMakeLists.txt
+@@ -97,7 +97,7 @@ if(PIGLIT_USE_WAFFLE)
+ 			piglit-framework-gl/piglit_wl_framework.c
+ 		)
+ 		list(APPEND UTIL_GL_INCLUDES
+-			${WAYLAND_wayland-client_INCLUDEDIR}
++			${WAYLAND_INCLUDE_DIRS}
+ 		)
+ 	endif()
+ 	if(PIGLIT_HAS_X11)
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-graphics/piglit/piglit_git.bb b/poky/meta/recipes-graphics/piglit/piglit_git.bb
index b936ad8..9e45751 100644
--- a/poky/meta/recipes-graphics/piglit/piglit_git.bb
+++ b/poky/meta/recipes-graphics/piglit/piglit_git.bb
@@ -5,11 +5,12 @@
 SRC_URI = "git://anongit.freedesktop.org/piglit \
            file://0001-cmake-install-bash-completions-in-the-right-place.patch \
            file://0001-tests-Use-FE_UPWARD-only-if-its-defined-in-fenv.h.patch \
+           file://0001-cmake-use-proper-WAYLAND_INCLUDE_DIRS-variable.patch \
            "
 UPSTREAM_CHECK_COMMITS = "1"
 
-# From 2018-02-26
-SRCREV = "4ce0887e2f7f848d2be2e435a2d0f3c80e44ea3b"
+# From 2018-08-13
+SRCREV = "57859e15dc8ba4034348b04d0b72f213b74d6347"
 # (when PV goes above 1.0 remove the trailing r)
 PV = "1.0+gitr${SRCPV}"
 
@@ -17,7 +18,7 @@
 
 DEPENDS = "libpng virtual/libx11 libxkbcommon libxrender waffle virtual/libgl libglu python3-mako-native python3-numpy-native python3-six-native virtual/egl"
 
-inherit cmake python3native distro_features_check bash-completion
+inherit cmake pkgconfig python3native distro_features_check bash-completion
 # depends on virtual/libx11
 REQUIRED_DISTRO_FEATURES = "x11"
 
diff --git a/poky/meta/recipes-graphics/vulkan/vulkan-demos/0001-Don-t-build-demos-with-questionably-licensed-data.patch b/poky/meta/recipes-graphics/vulkan/vulkan-demos/0001-Don-t-build-demos-with-questionably-licensed-data.patch
index d32c8f2..93bcfbf 100644
--- a/poky/meta/recipes-graphics/vulkan/vulkan-demos/0001-Don-t-build-demos-with-questionably-licensed-data.patch
+++ b/poky/meta/recipes-graphics/vulkan/vulkan-demos/0001-Don-t-build-demos-with-questionably-licensed-data.patch
@@ -1,6 +1,6 @@
-From 55770fb07c42fe410cf8d09f8f5976babc89b9ef Mon Sep 17 00:00:00 2001
-From: Jussi Kukkonen <jussi.kukkonen@intel.com>
-Date: Tue, 4 Jul 2017 17:13:45 +0300
+From 0a27144d43b70121f57f6036514d069ca9d2b971 Mon Sep 17 00:00:00 2001
+From: "Maxin B. John" <maxin.john@intel.com>
+Date: Mon, 30 Jul 2018 17:23:29 +0300
 Subject: [PATCH] Don't build demos with questionably licensed data
 
 Some of the models don't have open source compatible licenses:
@@ -9,43 +9,46 @@
 
 ssao:
 scenerendering:
-	Sibenik model, no license found
+        Sibenik model, no license found
 
 deferred:
 deferredmultisampling:
 deferredshadows:
-	armor model, CC-BY-3.0
+        armor model, CC-BY-3.0
 
 vulkanscene:
 imgui:
 shadowmapping:
-	vulkanscene model, no license found
+        vulkanscene model, no license found
 
 indirectdraw:
-	plant model, no license found
+        plant model, no license found
 
 hdr:
 pbribl:
 pbrtexture:
-	Require external Vulkan Asset Pack
+        Require external Vulkan Asset Pack
 
 Upstream-Status: Inappropriate [configuration]
-Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
----
- CMakeLists.txt | 13 -------------
- 1 file changed, 13 deletions(-)
 
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 4958fff..0f9d3e4 100644
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -150,17 +150,11 @@ set(EXAMPLES
- 	computeparticles
+Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
+Signed-off-by: Maxin B. John <maxin.john@intel.com>
+---
+ examples/CMakeLists.txt | 14 --------------
+ 1 file changed, 14 deletions(-)
+
+diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt
+index 8eee3a4..698d3b3 100644
+--- a/examples/CMakeLists.txt
++++ b/examples/CMakeLists.txt
+@@ -47,18 +47,12 @@ set(EXAMPLES
  	computeshader
+ 	conservativeraster
  	debugmarker
 -	deferred
 -	deferredmultisampling
 -	deferredshadows
+ 	descriptorsets
  	displacement
  	distancefieldfonts
  	dynamicuniformbuffer
@@ -53,32 +56,36 @@
  	geometryshader
 -	hdr
 -	imgui
--	indirectdraw	
+-	indirectdraw
+ 	inputattachments
  	instancing
  	mesh
- 	multisampling
-@@ -170,20 +164,14 @@ set(EXAMPLES
+@@ -70,8 +64,6 @@ set(EXAMPLES
  	parallaxmapping
  	particlefire
  	pbrbasic
 -	pbribl
 -	pbrtexture
  	pipelines
+ 	pipelinestatistics
  	pushconstants
+@@ -79,15 +71,10 @@ set(EXAMPLES
  	radialblur
  	raytracing
+ 	renderheadless
 -	scenerendering
  	screenshot
 -	shadowmapping
 -	shadowmappingomni
+-	shadowmappingcascade
  	skeletalanimation
  	specializationconstants
  	sphericalenvmapping
 -	ssao
+ 	stencilbuffer
  	subpasses
  	terraintessellation
- 	tessellation
-@@ -196,7 +184,6 @@ set(EXAMPLES
+@@ -101,7 +88,6 @@ set(EXAMPLES
  	texturesparseresidency
  	triangle
  	viewportarray
@@ -87,5 +94,5 @@
  
  buildExamples()
 -- 
-2.13.2
+2.4.0
 
diff --git a/poky/meta/recipes-graphics/vulkan/vulkan-demos/0001-Fix-build-on-x86.patch b/poky/meta/recipes-graphics/vulkan/vulkan-demos/0001-Fix-build-on-x86.patch
deleted file mode 100644
index 681b342..0000000
--- a/poky/meta/recipes-graphics/vulkan/vulkan-demos/0001-Fix-build-on-x86.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From b0495efb6c3ea3a530fcbaddac86da57ecce5a66 Mon Sep 17 00:00:00 2001
-From: Jussi Kukkonen <jussi.kukkonen@intel.com>
-Date: Mon, 10 Jul 2017 13:11:12 +0300
-Subject: [PATCH] Fix build on x86
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-| func_common.inl:193:51: error: wrong number of template arguments
-| (5, should be 6) struct compute_sign<T, P, vecType, false, Aligned>
-
-The fix is backported from the upstream glm project.
-
-Upstream-Status: Pending [https://github.com/SaschaWillems/Vulkan/issues/356]
-Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
----
- external/glm/glm/detail/func_common.inl | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/external/glm/glm/detail/func_common.inl b/external/glm/glm/detail/func_common.inl
-index cafaed5..2dd94e1 100644
---- a/external/glm/glm/detail/func_common.inl
-+++ b/external/glm/glm/detail/func_common.inl
-@@ -190,12 +190,12 @@ namespace detail
- 
- #	if GLM_ARCH == GLM_ARCH_X86
- 	template<length_t L, typename T, precision P, template<length_t, typename, precision> class vecType, bool Aligned>
--	struct compute_sign<T, P, vecType, false, Aligned>
-+	struct compute_sign<L, T, P, vecType, false, Aligned>
- 	{
- 		GLM_FUNC_QUALIFIER static vecType<L, T, P> call(vecType<L, T, P> const & x)
- 		{
- 			T const Shift(static_cast<T>(sizeof(T) * 8 - 1));
--			vecType<L, T, P> const y(vecType<typename make_unsigned<T>::type, P>(-x) >> typename make_unsigned<T>::type(Shift));
-+			vecType<L, T, P> const y(vecType<L, typename make_unsigned<T>::type, P>(-x) >> typename make_unsigned<T>::type(Shift));
- 
- 			return (x >> Shift) | y;
- 		}
--- 
-2.1.4
-
diff --git a/poky/meta/recipes-graphics/vulkan/vulkan-demos/0001-Support-installing-demos-support-out-of-tree-builds.patch b/poky/meta/recipes-graphics/vulkan/vulkan-demos/0001-Support-installing-demos-support-out-of-tree-builds.patch
deleted file mode 100644
index 4addea3..0000000
--- a/poky/meta/recipes-graphics/vulkan/vulkan-demos/0001-Support-installing-demos-support-out-of-tree-builds.patch
+++ /dev/null
@@ -1,85 +0,0 @@
-From edca667684764cfcc0460e448e834fadf623a887 Mon Sep 17 00:00:00 2001
-From: Jussi Kukkonen <jussi.kukkonen@intel.com>
-Date: Mon, 3 Jul 2017 14:49:18 +0300
-Subject: [PATCH] Support installing demos, support out-of-tree builds
-
-This is especially useful for cross-compile situation where testing
-happens on target.
-
--DRESOURCE_INSTALL_DIR=<path> decides where data is installed (and
-where the binaries will load the data from): if it's left empty,
-then nothing will be installed and binaries will load the data from
-CMAKE_SOURCE_DIR.
-
-Binaries are now correctly built in CMAKE_BINARY_DIR.
-
-Upstream-Status: Submitted [https://github.com/SaschaWillems/Vulkan/pull/352]
-Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
----
- CMakeLists.txt             | 15 ++++++++++++++-
- base/vulkanexamplebase.cpp |  2 +-
- 2 files changed, 15 insertions(+), 2 deletions(-)
-
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index b9886bc..4958fff 100644
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -16,6 +16,8 @@ include_directories(base)
- OPTION(USE_D2D_WSI "Build the project using Direct to Display swapchain" OFF)
- OPTION(USE_WAYLAND_WSI "Build the project using Wayland swapchain" OFF)
- 
-+set(RESOURCE_INSTALL_DIR "" CACHE PATH "Path to install resources to (leave empty for running uninstalled)")
-+
- # Use FindVulkan module added with CMAKE 3.7
- if (NOT CMAKE_VERSION VERSION_LESS 3.7.0)
- 	message(STATUS "Using module to find Vulkan")
-@@ -108,6 +110,10 @@ function(buildExample EXAMPLE_NAME)
- 		add_executable(${EXAMPLE_NAME} ${MAIN_CPP} ${SOURCE} ${SHADERS})
- 		target_link_libraries(${EXAMPLE_NAME} ${Vulkan_LIBRARY} ${ASSIMP_LIBRARIES} ${WAYLAND_CLIENT_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT})
- 	endif(WIN32)
-+
-+	if(RESOURCE_INSTALL_DIR)
-+		install(TARGETS ${EXAMPLE_NAME} DESTINATION ${CMAKE_INSTALL_BINDIR})
-+	endif()
- endfunction(buildExample)
- 
- # Build all examples
-@@ -117,6 +123,13 @@ function(buildExamples)
- 	endforeach(EXAMPLE)
- endfunction(buildExamples)
- 
-+if(RESOURCE_INSTALL_DIR)
-+	add_definitions(-DVK_EXAMPLE_DATA_DIR=\"${RESOURCE_INSTALL_DIR}/\")
-+	install(DIRECTORY data/ DESTINATION ${RESOURCE_INSTALL_DIR}/)
-+else()
-+	add_definitions(-DVK_EXAMPLE_DATA_DIR=\"${CMAKE_SOURCE_DIR}/data/\")
-+endif()
-+
- # Compiler specific stuff
- IF(MSVC)
- 	SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /EHsc")
-@@ -128,7 +141,7 @@ ELSE(WIN32)
- 	link_libraries(${XCB_LIBRARIES} ${Vulkan_LIBRARY})
- ENDIF(WIN32)
- 
--set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_SOURCE_DIR}/bin/")
-+set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/")
- 
- set(EXAMPLES 
- 	bloom
-diff --git a/base/vulkanexamplebase.cpp b/base/vulkanexamplebase.cpp
-index 647368a..a0f28a5 100644
---- a/base/vulkanexamplebase.cpp
-+++ b/base/vulkanexamplebase.cpp
-@@ -84,7 +84,7 @@ const std::string VulkanExampleBase::getAssetPath()
- #if defined(__ANDROID__)
- 	return "";
- #else
--	return "./../data/";
-+	return VK_EXAMPLE_DATA_DIR;
- #endif
- }
- #endif
--- 
-2.13.2
-
diff --git a/poky/meta/recipes-graphics/vulkan/vulkan-demos_git.bb b/poky/meta/recipes-graphics/vulkan/vulkan-demos_git.bb
index 5fc9c2d..bf30c98 100644
--- a/poky/meta/recipes-graphics/vulkan/vulkan-demos_git.bb
+++ b/poky/meta/recipes-graphics/vulkan/vulkan-demos_git.bb
@@ -3,15 +3,18 @@
 DEPENDS = "zlib"
 
 LIC_FILES_CHKSUM = "file://LICENSE.md;md5=dcf473723faabf17baa9b5f2207599d0 \
-                    file://triangle/triangle.cpp;endline=12;md5=bccd1bf9cadd9e10086cf7872157e4fa"
+                    file://examples/triangle/triangle.cpp;endline=12;md5=bccd1bf9cadd9e10086cf7872157e4fa"
+
+SRCREV_glm = "01f9ab5b6d21e5062ac0f6e0f205c7fa2ca9d769"
+SRCREV_gli = "8e43030b3e12bb58a4663d85adc5c752f89099c0"
 
 SRC_URI = "git://github.com/SaschaWillems/Vulkan.git \
-           file://0001-Support-installing-demos-support-out-of-tree-builds.patch \
+           git://github.com/g-truc/glm;destsuffix=git/external/glm;name=glm \
+           git://github.com/g-truc/gli;destsuffix=git/external/gli;name=gli \
            file://0001-Don-t-build-demos-with-questionably-licensed-data.patch \
-           file://0001-Fix-build-on-x86.patch \
 "
 UPSTREAM_CHECK_COMMITS = "1"
-SRCREV = "18df00c7b4677b0889486e16977857aa987947e2"
+SRCREV = "ae0b59c6e2e8630a2ae26f4a0b7a72cbe7547948"
 UPSTREAM_CHECK_GITTAGREGEX = "These are not the releases you're looking for"
 S = "${WORKDIR}/git"
 
diff --git a/poky/meta/recipes-graphics/vulkan/vulkan/demos-Don-t-build-tri-or-cube.patch b/poky/meta/recipes-graphics/vulkan/vulkan/demos-Don-t-build-tri-or-cube.patch
index bcf84a5..b0b9fc4 100644
--- a/poky/meta/recipes-graphics/vulkan/vulkan/demos-Don-t-build-tri-or-cube.patch
+++ b/poky/meta/recipes-graphics/vulkan/vulkan/demos-Don-t-build-tri-or-cube.patch
@@ -1,21 +1,30 @@
-commit f63cbe944107b5cd8f150ceaaec43b26099d5688
+From 9b13be109bc66f4d4a1ad53ce5c92c7c495e41d7 Mon Sep 17 00:00:00 2001
+From: "Maxin B. John" <maxin.john@intel.com>
+Date: Tue, 24 Jul 2018 17:40:52 +0300
+Subject: [PATCH] commit f63cbe944107b5cd8f150ceaaec43b26099d5688
+
 Author: Adam Jackson <ajax@redhat.com>
 Date:   Tue Feb 16 10:05:25 2016 -0500
 
-    demos: Don't build tri or cube
-    
-    There are more interesting demos, all we really want here is vulkaninfo.
-    This helps because we don't need to pre-build glslang/llvm/lunarglass
-    just to get the loader and layers.
+demos: Don't build tri or cube
+
+There are more interesting demos, all we really want here is vulkaninfo.
+This helps because we don't need to pre-build glslang/llvm/lunarglass
+just to get the loader and layers.
 
 Upstream-Status: Inappropriate [configuration]
-Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
 
-Index: git/demos/CMakeLists.txt
-===================================================================
---- git.orig/demos/CMakeLists.txt
-+++ git/demos/CMakeLists.txt
-@@ -63,46 +63,6 @@ elseif(UNIX)
+Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
+Signed-off-by: Maxin B. John <maxin.john@intel.com>
+---
+ demos/CMakeLists.txt | 88 ----------------------------------------------------
+ 1 file changed, 88 deletions(-)
+
+diff --git a/demos/CMakeLists.txt b/demos/CMakeLists.txt
+index 4f32679..26e4cdf 100644
+--- a/demos/CMakeLists.txt
++++ b/demos/CMakeLists.txt
+@@ -93,42 +93,6 @@ elseif(UNIX)
  else()
  endif()
  
@@ -37,38 +46,40 @@
 -        endif()
 -    endforeach()
 -
--    add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/demos/cube-vert.spv
--       COMMAND ${GLSLANG_VALIDATOR} -s -V -o ${CMAKE_BINARY_DIR}/demos/cube-vert.spv ${PROJECT_SOURCE_DIR}/demos/cube.vert
--       DEPENDS cube.vert ${GLSLANG_VALIDATOR}
--       )
--    add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/demos/cube-frag.spv
--       COMMAND ${GLSLANG_VALIDATOR} -s -V -o ${CMAKE_BINARY_DIR}/demos/cube-frag.spv ${PROJECT_SOURCE_DIR}/demos/cube.frag
--       DEPENDS cube.frag ${GLSLANG_VALIDATOR}
--       )
 -   file(COPY cube.vcxproj.user DESTINATION ${CMAKE_BINARY_DIR}/demos)
 -   file(COPY vulkaninfo.vcxproj.user DESTINATION ${CMAKE_BINARY_DIR}/demos)
--else()
--    if (${CMAKE_SYSTEM_PROCESSOR} STREQUAL ${CMAKE_HOST_SYSTEM_PROCESSOR})
--        add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/demos/cube-vert.spv
--            COMMAND ${GLSLANG_VALIDATOR} -s -V -o cube-vert.spv ${PROJECT_SOURCE_DIR}/demos/cube.vert
--            DEPENDS cube.vert ${GLSLANG_VALIDATOR}
--            )
--        add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/demos/cube-frag.spv
--            COMMAND ${GLSLANG_VALIDATOR} -s -V -o cube-frag.spv ${PROJECT_SOURCE_DIR}/demos/cube.frag
--            DEPENDS cube.frag ${GLSLANG_VALIDATOR}
--            )
--    endif()         
 -endif()
+-
+-add_custom_command(
+-    COMMENT "Compiling cube demo vertex shader"
+-    OUTPUT cube.vert.inc
+-    COMMAND ${GLSLANG_VALIDATOR} -V -x -o ${CMAKE_CURRENT_BINARY_DIR}/cube.vert.inc ${PROJECT_SOURCE_DIR}/demos/cube.vert
+-    MAIN_DEPENDENCY ${PROJECT_SOURCE_DIR}/demos/cube.vert
+-    DEPENDS ${PROJECT_SOURCE_DIR}/demos/cube.vert ${GLSLANG_VALIDATOR}
+-)
+-add_custom_command(
+-    COMMENT "Compiling cube demo fragment shader"
+-    OUTPUT cube.frag.inc
+-    COMMAND ${GLSLANG_VALIDATOR} -V -x -o ${CMAKE_CURRENT_BINARY_DIR}/cube.frag.inc ${PROJECT_SOURCE_DIR}/demos/cube.frag
+-    MAIN_DEPENDENCY ${PROJECT_SOURCE_DIR}/demos/cube.frag
+-    DEPENDS ${PROJECT_SOURCE_DIR}/demos/cube.frag ${GLSLANG_VALIDATOR}
+-)
  
- if(WIN32)
-     include_directories (
-@@ -116,43 +76,6 @@ endif()
- add_executable(${API_LOWERCASE}info vulkaninfo.c)
- target_link_libraries(${API_LOWERCASE}info ${LIBRARIES})
+ include_directories(${CMAKE_CURRENT_BINARY_DIR})
  
--if(NOT WIN32)
+@@ -172,55 +136,3 @@ if(${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
+         install(TARGETS ${API_LOWERCASE}info DESTINATION ${CMAKE_INSTALL_BINDIR})
+     endif()
+ endif()
+-
+-######################################################################################
+-# cube
+-
+-if(APPLE)
+-    include(macOS/cube/cube.cmake)
+-elseif(NOT WIN32)
 -    if (${CMAKE_SYSTEM_PROCESSOR} STREQUAL ${CMAKE_HOST_SYSTEM_PROCESSOR})
--        add_executable(cube cube.c ${CMAKE_BINARY_DIR}/demos/cube-vert.spv ${CMAKE_BINARY_DIR}/demos/cube-frag.spv)
+-        add_executable(cube cube.c ${PROJECT_SOURCE_DIR}/demos/cube.vert ${PROJECT_SOURCE_DIR}/demos/cube.frag cube.vert.inc cube.frag.inc)
 -        target_link_libraries(cube ${LIBRARIES})
 -    endif()
 -else()
@@ -78,13 +89,18 @@
 -        set (LIB_DIR "Win32")
 -    endif()
 -
--    add_executable(cube WIN32 cube.c ${CMAKE_BINARY_DIR}/demos/cube-vert.spv ${CMAKE_BINARY_DIR}/demos/cube-frag.spv)
+-    add_executable(cube WIN32 cube.c ${PROJECT_SOURCE_DIR}/demos/cube.vert ${PROJECT_SOURCE_DIR}/demos/cube.frag cube.vert.inc cube.frag.inc)
 -    target_link_libraries(cube ${LIBRARIES})
 -endif()
 -
--if(NOT WIN32)
+-######################################################################################
+-# cubepp
+-
+-if(APPLE)
+-    include(macOS/cubepp/cubepp.cmake)
+-elseif(NOT WIN32)
 -    if (${CMAKE_SYSTEM_PROCESSOR} STREQUAL ${CMAKE_HOST_SYSTEM_PROCESSOR})
--        add_executable(cubepp cube.cpp ${CMAKE_BINARY_DIR}/demos/cube-vert.spv ${CMAKE_BINARY_DIR}/demos/cube-frag.spv)
+-        add_executable(cubepp cube.cpp ${PROJECT_SOURCE_DIR}/demos/cube.vert ${PROJECT_SOURCE_DIR}/demos/cube.frag cube.vert.inc cube.frag.inc)
 -        target_link_libraries(cubepp ${LIBRARIES})
 -    endif()
 -else()
@@ -94,15 +110,19 @@
 -        set (LIB_DIR "Win32")
 -    endif()
 -
--    add_executable(cubepp WIN32 cube.cpp ${CMAKE_BINARY_DIR}/demos/cube-vert.spv ${CMAKE_BINARY_DIR}/demos/cube-frag.spv)
+-    add_executable(cubepp WIN32 cube.cpp ${PROJECT_SOURCE_DIR}/demos/cube.vert ${PROJECT_SOURCE_DIR}/demos/cube.frag cube.vert.inc cube.frag.inc)
 -    target_link_libraries(cubepp ${LIBRARIES})
 -endif()
 -
+-######################################################################################
+-# smoke
+-
 -if ((${CMAKE_SYSTEM_PROCESSOR} STREQUAL ${CMAKE_HOST_SYSTEM_PROCESSOR}))
--    if  ((DEMOS_WSI_SELECTION STREQUAL "XCB") OR (DEMOS_WSI_SELECTION STREQUAL "WAYLAND") OR WIN32 OR (CMAKE_SYSTEM_NAME STREQUAL "Android"))
+-    if ((DEMOS_WSI_SELECTION STREQUAL "XCB") OR (DEMOS_WSI_SELECTION STREQUAL "WAYLAND") OR WIN32 OR
+-        (CMAKE_SYSTEM_NAME STREQUAL "Android") OR (CMAKE_SYSTEM_NAME STREQUAL "Darwin"))
 -        add_subdirectory(smoke)
 -    endif()
 -endif()
- 
- if(UNIX)
-     if(INSTALL_LVL_FILES)
+-- 
+2.4.0
+
diff --git a/poky/meta/recipes-graphics/vulkan/vulkan_1.0.65.2.bb b/poky/meta/recipes-graphics/vulkan/vulkan_1.0.65.2.bb
deleted file mode 100644
index 1c8a895..0000000
--- a/poky/meta/recipes-graphics/vulkan/vulkan_1.0.65.2.bb
+++ /dev/null
@@ -1,36 +0,0 @@
-SUMMARY = "3D graphics and compute API common loader"
-DESCRIPTION = "Vulkan is a new generation graphics and compute API \
-that provides efficient access to modern GPUs. These packages \
-provide only the common vendor-agnostic library loader, headers and \
-the vulkaninfo utility."
-HOMEPAGE = "https://www.khronos.org/vulkan/"
-BUGTRACKER = "https://github.com/KhronosGroup/Vulkan-LoaderAndValidationLayers"
-SECTION = "libs"
-
-LICENSE = "Apache-2.0"
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=99c647ca3d4f6a4b9d8628f757aad156 \
-                    file://loader/loader.c;endline=25;md5=a87cd5442291c23d1fce4eece4cfde9d"
-SRC_URI = "git://github.com/KhronosGroup/Vulkan-LoaderAndValidationLayers.git;branch=sdk-1.0.65 \
-           file://demos-Don-t-build-tri-or-cube.patch \
-           "
-SRCREV = "73486a1a169d862d5210e2ad520d95319a2383fa"
-UPSTREAM_CHECK_GITTAGREGEX = "sdk-(?P<pver>\d+(\.\d+)+)"
-
-S = "${WORKDIR}/git"
-
-REQUIRED_DISTRO_FEATURES = "vulkan"
-
-inherit cmake python3native lib_package distro_features_check
-ANY_OF_DISTRO_FEATURES = "x11 wayland"
-
-EXTRA_OECMAKE = "-DBUILD_WSI_MIR_SUPPORT=OFF \
-                 -DBUILD_LAYERS=OFF \
-                 -DBUILD_TESTS=OFF"
-
-# must choose x11 or wayland or both
-PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', '' ,d)} \
-                   ${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'wayland', '' ,d)}"
-PACKAGECONFIG[x11] = "-DBUILD_WSI_XLIB_SUPPORT=ON -DBUILD_WSI_XCB_SUPPORT=ON -DDEMOS_WSI_SELECTION=XCB, -DBUILD_WSI_XLIB_SUPPORT=OFF -DBUILD_WSI_XCB_SUPPORT=OFF -DDEMOS_WSI_SELECTION=WAYLAND, libxcb libx11 libxrandr"
-PACKAGECONFIG[wayland] = "-DBUILD_WSI_WAYLAND_SUPPORT=ON, -DBUILD_WSI_WAYLAND_SUPPORT=OFF, wayland"
-
-RRECOMMENDS_${PN} = "mesa-vulkan-drivers"
diff --git a/poky/meta/recipes-graphics/vulkan/vulkan_1.1.73.0.bb b/poky/meta/recipes-graphics/vulkan/vulkan_1.1.73.0.bb
new file mode 100644
index 0000000..5496f53
--- /dev/null
+++ b/poky/meta/recipes-graphics/vulkan/vulkan_1.1.73.0.bb
@@ -0,0 +1,37 @@
+SUMMARY = "3D graphics and compute API common loader"
+DESCRIPTION = "Vulkan is a new generation graphics and compute API \
+that provides efficient access to modern GPUs. These packages \
+provide only the common vendor-agnostic library loader, headers and \
+the vulkaninfo utility."
+HOMEPAGE = "https://www.khronos.org/vulkan/"
+BUGTRACKER = "https://github.com/KhronosGroup/Vulkan-LoaderAndValidationLayers"
+SECTION = "libs"
+
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=99c647ca3d4f6a4b9d8628f757aad156 \
+                    file://loader/loader.c;endline=25;md5=151b392f46568aaedb4ad22b246237ec"
+SRC_URI = "git://github.com/KhronosGroup/Vulkan-LoaderAndValidationLayers.git;branch=sdk-1.1.73 \
+           file://demos-Don-t-build-tri-or-cube.patch \
+           "
+SRCREV = "5998d6f444a85e6381b7a089ebf3f9e86482a31d"
+UPSTREAM_CHECK_GITTAGREGEX = "sdk-(?P<pver>\d+(\.\d+)+)"
+
+S = "${WORKDIR}/git"
+
+REQUIRED_DISTRO_FEATURES = "vulkan"
+
+inherit cmake python3native lib_package distro_features_check
+ANY_OF_DISTRO_FEATURES = "x11 wayland"
+
+EXTRA_OECMAKE = "-DBUILD_WSI_MIR_SUPPORT=OFF \
+                 -DBUILD_LAYERS=OFF \
+                 -DBUILD_TESTS=OFF"
+
+# must choose x11 or wayland or both
+PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', '' ,d)} \
+                   ${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'wayland', '' ,d)}"
+PACKAGECONFIG[x11] = "-DBUILD_WSI_XLIB_SUPPORT=ON -DBUILD_WSI_XCB_SUPPORT=ON -DDEMOS_WSI_SELECTION=XCB, -DBUILD_WSI_XLIB_SUPPORT=OFF -DBUILD_WSI_XCB_SUPPORT=OFF -DDEMOS_WSI_SELECTION=WAYLAND, libxcb libx11 libxrandr"
+PACKAGECONFIG[wayland] = "-DBUILD_WSI_WAYLAND_SUPPORT=ON, -DBUILD_WSI_WAYLAND_SUPPORT=OFF, wayland"
+
+RRECOMMENDS_${PN} = "mesa-vulkan-drivers"
+INSANE_SKIP_${PN}-dev += "dev-elf"
diff --git a/poky/meta/recipes-graphics/wayland/libinput_1.11.3.bb b/poky/meta/recipes-graphics/wayland/libinput_1.11.3.bb
new file mode 100644
index 0000000..12e2091
--- /dev/null
+++ b/poky/meta/recipes-graphics/wayland/libinput_1.11.3.bb
@@ -0,0 +1,29 @@
+SUMMARY = "Library to handle input devices in Wayland compositors"
+HOMEPAGE = "http://www.freedesktop.org/wiki/Software/libinput/"
+SECTION = "libs"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=1f2ea9ebff3a2c6d458faf58492efb63"
+
+DEPENDS = "libevdev udev mtdev"
+
+SRC_URI = "http://www.freedesktop.org/software/${BPN}/${BP}.tar.xz \
+           "
+SRC_URI[md5sum] = "df6e877f11de4a9793511e9abfe7ef01"
+SRC_URI[sha256sum] = "f31191d96e425b4f16319842279d65946d9d983dcd3d9e466ae1206aa10ecb06"
+
+UPSTREAM_CHECK_REGEX = "libinput-(?P<pver>\d+\.\d+\.(?!9\d+)\d+)"
+inherit meson pkgconfig lib_package
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[libwacom] = "-Dlibwacom=true,-Dlibwacom=false,libwacom"
+PACKAGECONFIG[gui] = "-Ddebug-gui=true,-Ddebug-gui=false,cairo gtk+3"
+
+UDEVDIR = "`pkg-config --variable=udevdir udev`"
+
+EXTRA_OEMESON += "-Dudev-dir=${UDEVDIR} -Ddocumentation=false -Dtests=false"
+
+# package name changed in 1.8.1 upgrade: make sure package upgrades work
+RPROVIDES_${PN} = "libinput"
+RREPLACES_${PN} = "libinput"
+RCONFLICTS_${PN} = "libinput"
diff --git a/poky/meta/recipes-graphics/wayland/libinput_1.9.4.bb b/poky/meta/recipes-graphics/wayland/libinput_1.9.4.bb
deleted file mode 100644
index 67a49df..0000000
--- a/poky/meta/recipes-graphics/wayland/libinput_1.9.4.bb
+++ /dev/null
@@ -1,29 +0,0 @@
-SUMMARY = "Library to handle input devices in Wayland compositors"
-HOMEPAGE = "http://www.freedesktop.org/wiki/Software/libinput/"
-SECTION = "libs"
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=2184aef38ff137ed33ce9a63b9d1eb8f"
-
-DEPENDS = "libevdev udev mtdev"
-
-SRC_URI = "http://www.freedesktop.org/software/${BPN}/${BP}.tar.xz \
-           "
-SRC_URI[md5sum] = "8b43d07d1698fb207a0492fc67554d4f"
-SRC_URI[sha256sum] = "0bcdbd4c4e3c2a2db322fbdf2ef3284f2e6d6fb7be3af80e6d8de7783f675190"
-
-UPSTREAM_CHECK_REGEX = "libinput-(?P<pver>\d+\.\d+\.(?!9\d+)\d+)"
-inherit meson pkgconfig lib_package
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[libwacom] = "-Dlibwacom=true,-Dlibwacom=false,libwacom"
-PACKAGECONFIG[gui] = "-Ddebug-gui=true,-Ddebug-gui=false,cairo gtk+3"
-
-UDEVDIR = "`pkg-config --variable=udevdir udev`"
-
-EXTRA_OEMESON += "-Dudev-dir=${UDEVDIR} -Ddocumentation=false -Dtests=false"
-
-# package name changed in 1.8.1 upgrade: make sure package upgrades work
-RPROVIDES_${PN} = "libinput"
-RREPLACES_${PN} = "libinput"
-RCONFLICTS_${PN} = "libinput"
diff --git a/poky/meta/recipes-graphics/wayland/wayland-protocols_1.13.bb b/poky/meta/recipes-graphics/wayland/wayland-protocols_1.13.bb
deleted file mode 100644
index 1ef1ee1..0000000
--- a/poky/meta/recipes-graphics/wayland/wayland-protocols_1.13.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-SUMMARY = "Collection of additional Wayland protocols"
-DESCRIPTION = "Wayland protocols that add functionality not \
-available in the Wayland core protocol. Such protocols either add \
-completely new functionality, or extend the functionality of some other \
-protocol either in Wayland core, or some other protocol in \
-wayland-protocols."
-HOMEPAGE = "http://wayland.freedesktop.org"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=c7b12b6702da38ca028ace54aae3d484 \
-                    file://stable/presentation-time/presentation-time.xml;endline=26;md5=4646cd7d9edc9fa55db941f2d3a7dc53"
-
-SRC_URI = "https://wayland.freedesktop.org/releases/${BPN}-${PV}.tar.xz \
-           "
-SRC_URI[md5sum] = "29312149dafcd4a0e739ba94995a574d"
-SRC_URI[sha256sum] = "0758bc8008d5332f431b2a84fea7de64d971ce270ed208206a098ff2ebc68f38"
-
-inherit allarch autotools pkgconfig
-
-PACKAGES = "${PN}"
-FILES_${PN} += "${datadir}/pkgconfig/wayland-protocols.pc"
diff --git a/poky/meta/recipes-graphics/wayland/wayland-protocols_1.16.bb b/poky/meta/recipes-graphics/wayland/wayland-protocols_1.16.bb
new file mode 100644
index 0000000..fc4b711
--- /dev/null
+++ b/poky/meta/recipes-graphics/wayland/wayland-protocols_1.16.bb
@@ -0,0 +1,22 @@
+SUMMARY = "Collection of additional Wayland protocols"
+DESCRIPTION = "Wayland protocols that add functionality not \
+available in the Wayland core protocol. Such protocols either add \
+completely new functionality, or extend the functionality of some other \
+protocol either in Wayland core, or some other protocol in \
+wayland-protocols."
+HOMEPAGE = "http://wayland.freedesktop.org"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=c7b12b6702da38ca028ace54aae3d484 \
+                    file://stable/presentation-time/presentation-time.xml;endline=26;md5=4646cd7d9edc9fa55db941f2d3a7dc53"
+
+SRC_URI = "https://wayland.freedesktop.org/releases/${BPN}-${PV}.tar.xz \
+           "
+SRC_URI[md5sum] = "e0b523ff162e30bab46be1d65d527683"
+SRC_URI[sha256sum] = "6b1485951fdcd36a960c870c46f28b03a3e5121fb46246916333ed07f78c98c5"
+
+UPSTREAM_CHECK_URI = "https://wayland.freedesktop.org/releases.html"
+
+inherit allarch autotools pkgconfig
+
+PACKAGES = "${PN}"
+FILES_${PN} += "${datadir}/pkgconfig/wayland-protocols.pc"
diff --git a/poky/meta/recipes-graphics/wayland/wayland_1.14.0.bb b/poky/meta/recipes-graphics/wayland/wayland_1.14.0.bb
deleted file mode 100644
index 1a9ff98..0000000
--- a/poky/meta/recipes-graphics/wayland/wayland_1.14.0.bb
+++ /dev/null
@@ -1,42 +0,0 @@
-SUMMARY = "Wayland, a protocol between a compositor and clients"
-DESCRIPTION = "Wayland is a protocol for a compositor to talk to its clients \
-as well as a C library implementation of that protocol. The compositor can be \
-a standalone display server running on Linux kernel modesetting and evdev \
-input devices, an X application, or a wayland client itself. The clients can \
-be traditional applications, X servers (rootless or fullscreen) or other \
-display servers."
-HOMEPAGE = "http://wayland.freedesktop.org"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b31d8f53b6aaf2b4985d7dd7810a70d1 \
-                    file://src/wayland-server.c;endline=24;md5=b8e046164a766bb1ede8ba38e9dcd7ce"
-
-DEPENDS = "expat libxml2 libffi wayland-native"
-
-SRC_URI = "https://wayland.freedesktop.org/releases/${BPN}-${PV}.tar.xz \
-	   file://fixpathinpcfiles.patch \
-           "
-SRC_URI[md5sum] = "0235f6075c32c3be61cff94fa0b9f108"
-SRC_URI[sha256sum] = "ed80cabc0961a759a42092e2c39aabfc1ec9a13c86c98bbe2b812f008da27ab8"
-
-inherit autotools pkgconfig
-
-EXTRA_OECONF = "--disable-documentation --with-host-scanner"
-EXTRA_OECONF_class-native = "--disable-documentation --disable-libraries"
-
-# Wayland installs a M4 macro for other projects to use, which uses the target
-# pkg-config to find files.  Replace pkg-config with pkg-config-native.
-do_install_append_class-native() {
-  sed -e 's,PKG_CHECK_MODULES(.*),,g' \
-      -e 's,$PKG_CONFIG,pkg-config-native,g' \
-      -i ${D}/${datadir}/aclocal/wayland-scanner.m4
-}
-
-sysroot_stage_all_append_class-target () {
-	rm ${SYSROOT_DESTDIR}/${datadir}/aclocal/wayland-scanner.m4
-	cp ${STAGING_DATADIR_NATIVE}/aclocal/wayland-scanner.m4 ${SYSROOT_DESTDIR}/${datadir}/aclocal/
-}
-
-FILES_${PN} = "${libdir}/*${SOLIBS}"
-FILES_${PN}-dev += "${bindir} ${datadir}/wayland"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-graphics/wayland/wayland_1.16.0.bb b/poky/meta/recipes-graphics/wayland/wayland_1.16.0.bb
new file mode 100644
index 0000000..112ee1a
--- /dev/null
+++ b/poky/meta/recipes-graphics/wayland/wayland_1.16.0.bb
@@ -0,0 +1,44 @@
+SUMMARY = "Wayland, a protocol between a compositor and clients"
+DESCRIPTION = "Wayland is a protocol for a compositor to talk to its clients \
+as well as a C library implementation of that protocol. The compositor can be \
+a standalone display server running on Linux kernel modesetting and evdev \
+input devices, an X application, or a wayland client itself. The clients can \
+be traditional applications, X servers (rootless or fullscreen) or other \
+display servers."
+HOMEPAGE = "http://wayland.freedesktop.org"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b31d8f53b6aaf2b4985d7dd7810a70d1 \
+                    file://src/wayland-server.c;endline=24;md5=b8e046164a766bb1ede8ba38e9dcd7ce"
+
+DEPENDS = "expat libxml2 libffi wayland-native"
+
+SRC_URI = "https://wayland.freedesktop.org/releases/${BPN}-${PV}.tar.xz \
+	   file://fixpathinpcfiles.patch \
+           "
+SRC_URI[md5sum] = "0c215e53de71d6fb26f7102cdc6432d3"
+SRC_URI[sha256sum] = "4e72c2b56109ccfb6610d776e465f4ca0af2280c9c2f7d5cc23f0ed2548752f5"
+
+UPSTREAM_CHECK_URI = "https://wayland.freedesktop.org/releases.html"
+
+inherit autotools pkgconfig
+
+EXTRA_OECONF = "--disable-documentation --with-host-scanner"
+EXTRA_OECONF_class-native = "--disable-documentation --disable-libraries"
+
+# Wayland installs a M4 macro for other projects to use, which uses the target
+# pkg-config to find files.  Replace pkg-config with pkg-config-native.
+do_install_append_class-native() {
+  sed -e 's,PKG_CHECK_MODULES(.*),,g' \
+      -e 's,$PKG_CONFIG,pkg-config-native,g' \
+      -i ${D}/${datadir}/aclocal/wayland-scanner.m4
+}
+
+sysroot_stage_all_append_class-target () {
+	rm ${SYSROOT_DESTDIR}/${datadir}/aclocal/wayland-scanner.m4
+	cp ${STAGING_DATADIR_NATIVE}/aclocal/wayland-scanner.m4 ${SYSROOT_DESTDIR}/${datadir}/aclocal/
+}
+
+FILES_${PN} = "${libdir}/*${SOLIBS}"
+FILES_${PN}-dev += "${bindir} ${datadir}/wayland"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-graphics/wayland/weston-conf.bb b/poky/meta/recipes-graphics/wayland/weston-conf.bb
new file mode 100644
index 0000000..f52200c
--- /dev/null
+++ b/poky/meta/recipes-graphics/wayland/weston-conf.bb
@@ -0,0 +1,35 @@
+SUMMARY = "Weston, a Wayland compositor, configuration files"
+HOMEPAGE = "http://wayland.freedesktop.org"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+CONFFILES_${PN} = "${sysconfdir}/xdg/weston/weston.ini"
+
+FILES_${PN} = "${sysconfdir}/xdg/weston/weston.ini"
+
+PACKAGES = "${PN}"
+
+do_configure[noexec] = '1'
+do_compile[noexec] = '1'
+
+do_install() {
+	:
+}
+
+do_install_qemux86() {
+	mkdir -p ${D}/${sysconfdir}/xdg/weston
+	cat << EOF > ${D}/${sysconfdir}/xdg/weston/weston.ini
+[core]
+backend=fbdev-backend.so
+EOF
+}
+
+do_install_qemux86-64() {
+	mkdir -p ${D}/${sysconfdir}/xdg/weston
+	cat << EOF > ${D}/${sysconfdir}/xdg/weston/weston.ini
+[core]
+backend=fbdev-backend.so
+EOF
+}
diff --git a/poky/meta/recipes-graphics/wayland/weston-init/weston.service b/poky/meta/recipes-graphics/wayland/weston-init/weston.service
index 689ce41..18f7262 100644
--- a/poky/meta/recipes-graphics/wayland/weston-init/weston.service
+++ b/poky/meta/recipes-graphics/wayland/weston-init/weston.service
@@ -4,6 +4,7 @@
 
 [Service]
 User=root
+PAMName=login
 EnvironmentFile=-/etc/default/weston
 ExecStart=/usr/bin/weston-start -v -e -- $OPTARGS
 
diff --git a/poky/meta/recipes-graphics/wayland/weston/0001-make-error-portable.patch b/poky/meta/recipes-graphics/wayland/weston/0001-make-error-portable.patch
index 0671a45..09ec155 100644
--- a/poky/meta/recipes-graphics/wayland/weston/0001-make-error-portable.patch
+++ b/poky/meta/recipes-graphics/wayland/weston/0001-make-error-portable.patch
@@ -1,26 +1,27 @@
-From c22e90365d89346258394833cbcad03ff32b2e27 Mon Sep 17 00:00:00 2001
+From ad1d2161c811cff25d1684c33611f300adb753bc Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 May 2015 20:56:00 -0700
-Subject: [PATCH weston] make error() portable
+Subject: [PATCH] make error() portable
 
 error() is not posix but gnu extension so may not be available on all
 kind of systemsi e.g. musl.
 
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
 Upstream-Status: Submitted
 
- configure.ac              |    2 ++
- libweston/weston-error.h  |   20 ++++++++++++++++++++
- libweston/weston-launch.c |    2 +-
- 3 files changed, 23 insertions(+), 1 deletion(-)
- create mode 100644 src/weston-error.h
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
-Index: weston-3.0.0/configure.ac
-===================================================================
---- weston-3.0.0.orig/configure.ac
-+++ weston-3.0.0/configure.ac
-@@ -103,6 +103,8 @@ AC_CHECK_DECL(CLOCK_MONOTONIC,[],
+---
+ configure.ac              |  2 ++
+ libweston/weston-error.h  | 20 ++++++++++++++++++++
+ libweston/weston-launch.c |  2 +-
+ 3 files changed, 23 insertions(+), 1 deletion(-)
+ create mode 100644 libweston/weston-error.h
+
+diff --git a/configure.ac b/configure.ac
+index 7aebbdb..dc9c802 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -109,6 +109,8 @@ AC_CHECK_DECL(CLOCK_MONOTONIC,[],
  	      [[#include <time.h>]])
  AC_CHECK_HEADERS([execinfo.h])
  
@@ -29,10 +30,11 @@
  AC_CHECK_FUNCS([mkostemp strchrnul initgroups posix_fallocate])
  
  # check for libdrm as a build-time dependency only
-Index: weston-3.0.0/libweston/weston-error.h
-===================================================================
+diff --git a/libweston/weston-error.h b/libweston/weston-error.h
+new file mode 100644
+index 0000000..2089d02
 --- /dev/null
-+++ weston-3.0.0/libweston/weston-error.h
++++ b/libweston/weston-error.h
 @@ -0,0 +1,20 @@
 +#ifndef _WESTON_ERROR_H
 +#define _WESTON_ERROR_H
@@ -54,10 +56,10 @@
 +
 +#endif
 +
-Index: weston-3.0.0/libweston/weston-launch.c
-===================================================================
---- weston-3.0.0.orig/libweston/weston-launch.c
-+++ weston-3.0.0/libweston/weston-launch.c
+diff --git a/libweston/weston-launch.c b/libweston/weston-launch.c
+index 1adcf21..166bf3b 100644
+--- a/libweston/weston-launch.c
++++ b/libweston/weston-launch.c
 @@ -33,7 +33,6 @@
  #include <poll.h>
  #include <errno.h>
@@ -66,7 +68,7 @@
  #include <getopt.h>
  
  #include <sys/types.h>
-@@ -60,6 +59,7 @@
+@@ -59,6 +58,7 @@
  #endif
  
  #include "weston-launch.h"
diff --git a/poky/meta/recipes-graphics/wayland/weston/0001-weston-launch-Provide-a-default-version-that-doesn-t.patch b/poky/meta/recipes-graphics/wayland/weston/0001-weston-launch-Provide-a-default-version-that-doesn-t.patch
index 70b9888..d648538 100644
--- a/poky/meta/recipes-graphics/wayland/weston/0001-weston-launch-Provide-a-default-version-that-doesn-t.patch
+++ b/poky/meta/recipes-graphics/wayland/weston/0001-weston-launch-Provide-a-default-version-that-doesn-t.patch
@@ -1,8 +1,7 @@
-From 8ff6ed03ec4079f32e9b34085414e57be4730e04 Mon Sep 17 00:00:00 2001
+From b98b9dbda902225cdd972b5bff6a641c36cc7e90 Mon Sep 17 00:00:00 2001
 From: Tom Hochstein <tom.hochstein@nxp.com>
 Date: Wed, 22 Feb 2017 15:53:30 +0200
-Subject: [PATCH] weston-launch: Provide a default version that doesn't require
- PAM
+Subject: [PATCH] weston-launch: Provide a default version that doesn't require PAM
 
 weston-launch requires PAM for starting weston as a non-root user.
 
@@ -14,16 +13,18 @@
 
 Signed-off-by: Tom Hochstein <tom.hochstein@nxp.com>
 Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
+Signed-off-by: Denys Dmytriyenko <denys@ti.com>
+
 ---
  configure.ac              |  9 +++++++--
  libweston/weston-launch.c | 20 ++++++++++++++++++++
  2 files changed, 27 insertions(+), 2 deletions(-)
 
 diff --git a/configure.ac b/configure.ac
-index 46cb2c7..bb45f46 100644
+index dc9c802..48cf5cb 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -435,13 +435,17 @@ AC_ARG_ENABLE(resize-optimization,
+@@ -451,13 +451,17 @@ AC_ARG_ENABLE(resize-optimization,
  AS_IF([test "x$enable_resize_optimization" = "xyes"],
        [AC_DEFINE([USE_RESIZE_POOL], [1], [Use resize memory pool as a performance optimization])])
  
@@ -43,7 +44,7 @@
  fi
  
  AM_CONDITIONAL(HAVE_PANGO, test "x$have_pango" = "xyes")
-@@ -701,6 +705,7 @@ AC_MSG_RESULT([
+@@ -702,6 +706,7 @@ AC_MSG_RESULT([
  	Enable developer documentation	${enable_devdocs}
  
  	weston-launch utility		${enable_weston_launch}
@@ -52,7 +53,7 @@
  	systemd notify support		${enable_systemd_notify}
  
 diff --git a/libweston/weston-launch.c b/libweston/weston-launch.c
-index 0491896..07e7469 100644
+index 166bf3b..6fb9232 100644
 --- a/libweston/weston-launch.c
 +++ b/libweston/weston-launch.c
 @@ -51,7 +51,9 @@
@@ -65,7 +66,7 @@
  
  #ifdef HAVE_SYSTEMD_LOGIN
  #include <systemd/sd-login.h>
-@@ -93,8 +95,10 @@ drmSetMaster(int drm_fd)
+@@ -101,8 +103,10 @@ drmSetMaster(int drm_fd)
  #endif
  
  struct weston_launch {
@@ -76,7 +77,7 @@
  	int tty;
  	int ttynr;
  	int sock[2];
-@@ -181,6 +185,7 @@ weston_launch_allowed(struct weston_launch *wl)
+@@ -189,6 +193,7 @@ weston_launch_allowed(struct weston_launch *wl)
  	return false;
  }
  
@@ -84,7 +85,7 @@
  static int
  pam_conversation_fn(int msg_count,
  		    const struct pam_message **messages,
-@@ -221,6 +226,7 @@ setup_pam(struct weston_launch *wl)
+@@ -229,6 +234,7 @@ setup_pam(struct weston_launch *wl)
  
  	return 0;
  }
@@ -92,7 +93,7 @@
  
  static int
  setup_launcher_socket(struct weston_launch *wl)
-@@ -414,6 +420,7 @@ quit(struct weston_launch *wl, int status)
+@@ -422,6 +428,7 @@ quit(struct weston_launch *wl, int status)
  	close(wl->signalfd);
  	close(wl->sock[0]);
  
@@ -100,7 +101,7 @@
  	if (wl->new_user) {
  		err = pam_close_session(wl->ph, 0);
  		if (err)
-@@ -421,6 +428,7 @@ quit(struct weston_launch *wl, int status)
+@@ -429,6 +436,7 @@ quit(struct weston_launch *wl, int status)
  				err, pam_strerror(wl->ph, err));
  		pam_end(wl->ph, err);
  	}
@@ -108,7 +109,7 @@
  
  	if (ioctl(wl->tty, KDSKBMUTE, 0) &&
  	    ioctl(wl->tty, KDSKBMODE, wl->kb_mode))
-@@ -600,6 +608,7 @@ setup_session(struct weston_launch *wl, char **child_argv)
+@@ -608,6 +616,7 @@ setup_session(struct weston_launch *wl, char **child_argv)
  	setenv("HOME", wl->pw->pw_dir, 1);
  	setenv("SHELL", wl->pw->pw_shell, 1);
  
@@ -116,7 +117,7 @@
  	env = pam_getenvlist(wl->ph);
  	if (env) {
  		for (i = 0; env[i]; ++i) {
-@@ -608,6 +617,7 @@ setup_session(struct weston_launch *wl, char **child_argv)
+@@ -616,6 +625,7 @@ setup_session(struct weston_launch *wl, char **child_argv)
  		}
  		free(env);
  	}
@@ -124,17 +125,18 @@
  
  	/*
  	 * We open a new session, so it makes sense
-@@ -675,7 +685,9 @@ static void
+@@ -683,8 +693,10 @@ static void
  help(const char *name)
  {
  	fprintf(stderr, "Usage: %s [args...] [-- [weston args..]]\n", name);
 +#ifdef HAVE_PAM
- 	fprintf(stderr, "  -u, --user      Start session as specified username\n");
+ 	fprintf(stderr, "  -u, --user      Start session as specified username,\n"
+ 			"                  e.g. -u joe, requires root.\n");
 +#endif
- 	fprintf(stderr, "  -t, --tty       Start session on alternative tty\n");
+ 	fprintf(stderr, "  -t, --tty       Start session on alternative tty,\n"
+ 			"                  e.g. -t /dev/tty4, requires -u option.\n");
  	fprintf(stderr, "  -v, --verbose   Be verbose\n");
- 	fprintf(stderr, "  -h, --help      Display this help message\n");
-@@ -688,7 +700,9 @@ main(int argc, char *argv[])
+@@ -698,7 +710,9 @@ main(int argc, char *argv[])
  	int i, c;
  	char *tty = NULL;
  	struct option opts[] = {
@@ -144,8 +146,8 @@
  		{ "tty",     required_argument, NULL, 't' },
  		{ "verbose", no_argument,       NULL, 'v' },
  		{ "help",    no_argument,       NULL, 'h' },
-@@ -700,9 +714,13 @@ main(int argc, char *argv[])
- 	while ((c = getopt_long(argc, argv, "u:t::vh", opts, &i)) != -1) {
+@@ -710,9 +724,13 @@ main(int argc, char *argv[])
+ 	while ((c = getopt_long(argc, argv, "u:t:vh", opts, &i)) != -1) {
  		switch (c) {
  		case 'u':
 +#ifdef HAVE_PAM
@@ -158,7 +160,7 @@
  			break;
  		case 't':
  			tty = optarg;
-@@ -740,8 +758,10 @@ main(int argc, char *argv[])
+@@ -753,8 +771,10 @@ main(int argc, char *argv[])
  	if (setup_tty(&wl, tty) < 0)
  		exit(EXIT_FAILURE);
  
@@ -169,6 +171,3 @@
  
  	if (setup_launcher_socket(&wl) < 0)
  		exit(EXIT_FAILURE);
--- 
-2.1.4
-
diff --git a/poky/meta/recipes-graphics/wayland/weston/fix-missing-header.patch b/poky/meta/recipes-graphics/wayland/weston/fix-missing-header.patch
deleted file mode 100644
index 55c0d4f..0000000
--- a/poky/meta/recipes-graphics/wayland/weston/fix-missing-header.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-On the musl C library, tests/timespec-text.c does not build, with the
-following error:
-
-    In file included from tests/timespec-test.c:36:0:
-    ./shared/timespec-util.h:41:21: warning: ‘struct timespec’ declared
-    inside parameter list will not be visible outside of this definition
-    or declaration
-     timespec_sub(struct timespec *r,
-                         ^~~~~~~~
-   [...]
-
-Indeed, struct timespec is defined in time.h, so we must include it.
-
-Upstream-Status: Backport [fa41bdfbc0b962fd73b89f01aab1a5370c9c28eb]
-
-Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
-Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
-
-Index: weston-3.0.0/shared/timespec-util.h
-===================================================================
---- weston-3.0.0.orig/shared/timespec-util.h
-+++ weston-3.0.0/shared/timespec-util.h
-@@ -28,6 +28,7 @@
- 
- #include <stdint.h>
- #include <assert.h>
-+#include <time.h>
- 
- #define NSEC_PER_SEC 1000000000
- 
diff --git a/poky/meta/recipes-graphics/wayland/weston/weston-gl-renderer-Set-pitch-correctly-for-subsampled-textures.patch b/poky/meta/recipes-graphics/wayland/weston/weston-gl-renderer-Set-pitch-correctly-for-subsampled-textures.patch
deleted file mode 100644
index b3e1d06..0000000
--- a/poky/meta/recipes-graphics/wayland/weston/weston-gl-renderer-Set-pitch-correctly-for-subsampled-textures.patch
+++ /dev/null
@@ -1,55 +0,0 @@
-Multi-plane sub-sampled textures have partial width/height, e.g.
-YUV420/I420 has a full-size Y plane, followed by a half-width/height U
-plane, and a half-width/height V plane.
-
-zwp_linux_dmabuf_v1 allows clients to pass an explicit pitch for each
-plane, but for wl_shm this must be inferred. gl-renderer was correctly
-accounting for the width and height when subsampling, but the pitch was
-being taken as the pitch for the first plane.
-
-This does not match the requirements for GStreamer's waylandsink, in
-particular, as well as other clients. Fix the SHM upload path to
-correctly set the pitch for each plane, according to subsampling.
-
-Tested with:
-  $ gst-launch-1.0 videotestsrc ! waylandsink
-
-Upstream-Status: Backport [https://patchwork.freedesktop.org/patch/180767/]
-
-Signed-off-by: Daniel Stone <daniels@collabora.com>
-Fixes: fdeefe42418 ("gl-renderer: add support of WL_SHM_FORMAT_YUV420")
-Reported-by: Fabien Lahoudere <fabien.lahoudere@collabora.co.uk>
-Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=103063
-
----
- libweston/gl-renderer.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/libweston/gl-renderer.c b/libweston/gl-renderer.c
-index 244ce309..40bf0bb6 100644
---- a/libweston/gl-renderer.c
-+++ b/libweston/gl-renderer.c
-@@ -1445,14 +1445,13 @@ gl_renderer_flush_damage(struct weston_surface *surface)
- 		goto done;
- 	}
- 
--	glPixelStorei(GL_UNPACK_ROW_LENGTH_EXT, gs->pitch);
--
- 	if (gs->needs_full_upload) {
- 		glPixelStorei(GL_UNPACK_SKIP_PIXELS_EXT, 0);
- 		glPixelStorei(GL_UNPACK_SKIP_ROWS_EXT, 0);
- 		wl_shm_buffer_begin_access(buffer->shm_buffer);
- 		for (j = 0; j < gs->num_textures; j++) {
- 			glBindTexture(GL_TEXTURE_2D, gs->textures[j]);
-+			glPixelStorei(GL_UNPACK_ROW_LENGTH_EXT, gs->pitch / gs->hsub[j]);
- 			glTexImage2D(GL_TEXTURE_2D, 0,
- 				     gs->gl_format[j],
- 				     gs->pitch / gs->hsub[j],
-@@ -1477,6 +1476,7 @@ gl_renderer_flush_damage(struct weston_surface *surface)
- 		glPixelStorei(GL_UNPACK_SKIP_ROWS_EXT, r.y1);
- 		for (j = 0; j < gs->num_textures; j++) {
- 			glBindTexture(GL_TEXTURE_2D, gs->textures[j]);
-+			glPixelStorei(GL_UNPACK_ROW_LENGTH_EXT, gs->pitch / gs->hsub[j]);
- 			glTexSubImage2D(GL_TEXTURE_2D, 0,
- 					r.x1 / gs->hsub[j],
- 					r.y1 / gs->vsub[j],
diff --git a/poky/meta/recipes-graphics/wayland/weston_3.0.0.bb b/poky/meta/recipes-graphics/wayland/weston_3.0.0.bb
deleted file mode 100644
index ad0cdc2..0000000
--- a/poky/meta/recipes-graphics/wayland/weston_3.0.0.bb
+++ /dev/null
@@ -1,114 +0,0 @@
-SUMMARY = "Weston, a Wayland compositor"
-DESCRIPTION = "Weston is the reference implementation of a Wayland compositor"
-HOMEPAGE = "http://wayland.freedesktop.org"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d79ee9e66bb0f95d3386a7acae780b70 \
-                    file://libweston/compositor.c;endline=26;md5=e342df749174a8ee11065583157c7a38"
-
-SRC_URI = "https://wayland.freedesktop.org/releases/${BPN}-${PV}.tar.xz \
-           file://weston.png \
-           file://weston.desktop \
-           file://0001-make-error-portable.patch \
-           file://xwayland.weston-start \
-           file://0001-weston-launch-Provide-a-default-version-that-doesn-t.patch \
-	   file://weston-gl-renderer-Set-pitch-correctly-for-subsampled-textures.patch \
-	   file://fix-missing-header.patch \
-"
-SRC_URI[md5sum] = "9c42a4c51a1b9f35d040fa9d45ada36d"
-SRC_URI[sha256sum] = "cde1d55e8dd70c3cbb3d1ec72f60e60000041579caa1d6a262bd9c35e93723a5"
-
-inherit autotools pkgconfig useradd distro_features_check
-# depends on virtual/egl
-REQUIRED_DISTRO_FEATURES = "opengl"
-
-DEPENDS = "libxkbcommon gdk-pixbuf pixman cairo glib-2.0 jpeg"
-DEPENDS += "wayland wayland-protocols libinput virtual/egl pango wayland-native"
-
-EXTRA_OECONF = "--enable-setuid-install \
-                --disable-rdp-compositor \
-                "
-EXTRA_OECONF_append_qemux86 = "\
-		WESTON_NATIVE_BACKEND=fbdev-backend.so \
-		"
-EXTRA_OECONF_append_qemux86-64 = "\
-		WESTON_NATIVE_BACKEND=fbdev-backend.so \
-		"
-PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'kms fbdev wayland egl', '', d)} \
-                   ${@bb.utils.contains('DISTRO_FEATURES', 'x11 wayland', 'xwayland', '', d)} \
-                   ${@bb.utils.filter('DISTRO_FEATURES', 'pam systemd x11', d)} \
-                   clients launch"
-#
-# Compositor choices
-#
-# Weston on KMS
-PACKAGECONFIG[kms] = "--enable-drm-compositor,--disable-drm-compositor,drm udev virtual/mesa mtdev"
-# Weston on Wayland (nested Weston)
-PACKAGECONFIG[wayland] = "--enable-wayland-compositor,--disable-wayland-compositor,virtual/mesa"
-# Weston on X11
-PACKAGECONFIG[x11] = "--enable-x11-compositor,--disable-x11-compositor,virtual/libx11 libxcb libxcb libxcursor cairo"
-# Headless Weston
-PACKAGECONFIG[headless] = "--enable-headless-compositor,--disable-headless-compositor"
-# Weston on framebuffer
-PACKAGECONFIG[fbdev] = "--enable-fbdev-compositor,--disable-fbdev-compositor,udev mtdev"
-# weston-launch
-PACKAGECONFIG[launch] = "--enable-weston-launch,--disable-weston-launch,drm"
-# VA-API desktop recorder
-PACKAGECONFIG[vaapi] = "--enable-vaapi-recorder,--disable-vaapi-recorder,libva"
-# Weston with EGL support
-PACKAGECONFIG[egl] = "--enable-egl --enable-simple-egl-clients,--disable-egl --disable-simple-egl-clients,virtual/egl"
-# Weston with cairo glesv2 support
-PACKAGECONFIG[cairo-glesv2] = "--with-cairo-glesv2,--with-cairo=image,cairo"
-# Weston with lcms support
-PACKAGECONFIG[lcms] = "--enable-lcms,--disable-lcms,lcms"
-# Weston with webp support
-PACKAGECONFIG[webp] = "--with-webp,--without-webp,libwebp"
-# Weston with unwinding support
-PACKAGECONFIG[libunwind] = "--enable-libunwind,--disable-libunwind,libunwind"
-# Weston with systemd-login support
-PACKAGECONFIG[systemd] = "--enable-systemd-login,--disable-systemd-login,systemd dbus"
-# Weston with Xwayland support (requires X11 and Wayland)
-PACKAGECONFIG[xwayland] = "--enable-xwayland,--disable-xwayland"
-# colord CMS support
-PACKAGECONFIG[colord] = "--enable-colord,--disable-colord,colord"
-# Clients support
-PACKAGECONFIG[clients] = "--enable-clients --enable-simple-clients --enable-demo-clients-install,--disable-clients --disable-simple-clients"
-# Weston with PAM support
-PACKAGECONFIG[pam] = "--with-pam,--without-pam,libpam"
-
-do_install_append() {
-	# Weston doesn't need the .la files to load modules, so wipe them
-	rm -f ${D}/${libdir}/libweston-3/*.la
-
-	# If X11, ship a desktop file to launch it
-	if [ "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}" ]; then
-		install -d ${D}${datadir}/applications
-		install ${WORKDIR}/weston.desktop ${D}${datadir}/applications
-
-		install -d ${D}${datadir}/icons/hicolor/48x48/apps
-		install ${WORKDIR}/weston.png ${D}${datadir}/icons/hicolor/48x48/apps
-	fi
-
-	if [ "${@bb.utils.contains('PACKAGECONFIG', 'xwayland', 'yes', 'no', d)}" = "yes" ]; then
-		install -Dm 644 ${WORKDIR}/xwayland.weston-start ${D}${datadir}/weston-start/xwayland
-	fi
-}
-
-PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'xwayland', '${PN}-xwayland', '', d)} \
-             libweston-3 ${PN}-examples"
-
-FILES_${PN} = "${bindir}/weston ${bindir}/weston-terminal ${bindir}/weston-info ${bindir}/weston-launch ${bindir}/wcap-decode ${libexecdir} ${libdir}/${BPN}/*.so ${datadir}"
-
-FILES_libweston-3 = "${libdir}/lib*${SOLIBS} ${libdir}/libweston-3/*.so"
-SUMMARY_libweston-3 = "Helper library for implementing 'wayland window managers'."
-
-FILES_${PN}-examples = "${bindir}/*"
-
-FILES_${PN}-xwayland = "${libdir}/libweston-3/xwayland.so"
-RDEPENDS_${PN}-xwayland += "xserver-xorg-xwayland"
-
-RDEPENDS_${PN} += "xkeyboard-config"
-RRECOMMENDS_${PN} = "liberation-fonts"
-RRECOMMENDS_${PN}-dev += "wayland-protocols"
-
-USERADD_PACKAGES = "${PN}"
-GROUPADD_PARAM_${PN} = "--system weston-launch"
diff --git a/poky/meta/recipes-graphics/wayland/weston_5.0.0.bb b/poky/meta/recipes-graphics/wayland/weston_5.0.0.bb
new file mode 100644
index 0000000..e517109
--- /dev/null
+++ b/poky/meta/recipes-graphics/wayland/weston_5.0.0.bb
@@ -0,0 +1,108 @@
+SUMMARY = "Weston, a Wayland compositor"
+DESCRIPTION = "Weston is the reference implementation of a Wayland compositor"
+HOMEPAGE = "http://wayland.freedesktop.org"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d79ee9e66bb0f95d3386a7acae780b70 \
+                    file://libweston/compositor.c;endline=27;md5=6c53bbbd99273f4f7c4affa855c33c0a"
+
+SRC_URI = "https://wayland.freedesktop.org/releases/${BPN}-${PV}.tar.xz \
+           file://weston.png \
+           file://weston.desktop \
+           file://0001-make-error-portable.patch \
+           file://xwayland.weston-start \
+           file://0001-weston-launch-Provide-a-default-version-that-doesn-t.patch \
+"
+SRC_URI[md5sum] = "752a04ce3c65af4884cfac4e57231bdb"
+SRC_URI[sha256sum] = "15a23423bcfa45e31e1dedc0cd524ba71e2930df174fde9c99b71a537c4e4caf"
+
+UPSTREAM_CHECK_URI = "https://wayland.freedesktop.org/releases.html"
+
+inherit autotools pkgconfig useradd distro_features_check
+# depends on virtual/egl
+REQUIRED_DISTRO_FEATURES = "opengl"
+
+DEPENDS = "libxkbcommon gdk-pixbuf pixman cairo glib-2.0 jpeg"
+DEPENDS += "wayland wayland-protocols libinput virtual/egl pango wayland-native"
+
+WESTON_MAJOR_VERSION = "${@'.'.join(d.getVar('PV').split('.')[0:1])}"
+
+EXTRA_OECONF = "--enable-setuid-install \
+                --disable-rdp-compositor \
+                "
+PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'kms fbdev wayland egl', '', d)} \
+                   ${@bb.utils.contains('DISTRO_FEATURES', 'x11 wayland', 'xwayland', '', d)} \
+                   ${@bb.utils.filter('DISTRO_FEATURES', 'pam systemd x11', d)} \
+                   clients launch"
+#
+# Compositor choices
+#
+# Weston on KMS
+PACKAGECONFIG[kms] = "--enable-drm-compositor,--disable-drm-compositor,drm udev virtual/mesa virtual/libgbm mtdev"
+# Weston on Wayland (nested Weston)
+PACKAGECONFIG[wayland] = "--enable-wayland-compositor,--disable-wayland-compositor,virtual/mesa"
+# Weston on X11
+PACKAGECONFIG[x11] = "--enable-x11-compositor,--disable-x11-compositor,virtual/libx11 libxcb libxcb libxcursor cairo"
+# Headless Weston
+PACKAGECONFIG[headless] = "--enable-headless-compositor,--disable-headless-compositor"
+# Weston on framebuffer
+PACKAGECONFIG[fbdev] = "--enable-fbdev-compositor,--disable-fbdev-compositor,udev mtdev"
+# weston-launch
+PACKAGECONFIG[launch] = "--enable-weston-launch,--disable-weston-launch,drm"
+# VA-API desktop recorder
+PACKAGECONFIG[vaapi] = "--enable-vaapi-recorder,--disable-vaapi-recorder,libva"
+# Weston with EGL support
+PACKAGECONFIG[egl] = "--enable-egl --enable-simple-egl-clients,--disable-egl --disable-simple-egl-clients,virtual/egl"
+# Weston with cairo glesv2 support
+PACKAGECONFIG[cairo-glesv2] = "--with-cairo-glesv2,--with-cairo=image,cairo"
+# Weston with lcms support
+PACKAGECONFIG[lcms] = "--enable-lcms,--disable-lcms,lcms"
+# Weston with webp support
+PACKAGECONFIG[webp] = "--with-webp,--without-webp,libwebp"
+# Weston with systemd-login support
+PACKAGECONFIG[systemd] = "--enable-systemd-login,--disable-systemd-login,systemd dbus"
+# Weston with Xwayland support (requires X11 and Wayland)
+PACKAGECONFIG[xwayland] = "--enable-xwayland,--disable-xwayland"
+# colord CMS support
+PACKAGECONFIG[colord] = "--enable-colord,--disable-colord,colord"
+# Clients support
+PACKAGECONFIG[clients] = "--enable-clients --enable-simple-clients --enable-demo-clients-install,--disable-clients --disable-simple-clients"
+# Weston with PAM support
+PACKAGECONFIG[pam] = "--with-pam,--without-pam,libpam"
+
+do_install_append() {
+	# Weston doesn't need the .la files to load modules, so wipe them
+	rm -f ${D}/${libdir}/libweston-${WESTON_MAJOR_VERSION}/*.la
+
+	# If X11, ship a desktop file to launch it
+	if [ "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}" ]; then
+		install -d ${D}${datadir}/applications
+		install ${WORKDIR}/weston.desktop ${D}${datadir}/applications
+
+		install -d ${D}${datadir}/icons/hicolor/48x48/apps
+		install ${WORKDIR}/weston.png ${D}${datadir}/icons/hicolor/48x48/apps
+	fi
+
+	if [ "${@bb.utils.contains('PACKAGECONFIG', 'xwayland', 'yes', 'no', d)}" = "yes" ]; then
+		install -Dm 644 ${WORKDIR}/xwayland.weston-start ${D}${datadir}/weston-start/xwayland
+	fi
+}
+
+PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'xwayland', '${PN}-xwayland', '', d)} \
+             libweston-${WESTON_MAJOR_VERSION} ${PN}-examples"
+
+FILES_${PN} = "${bindir}/weston ${bindir}/weston-terminal ${bindir}/weston-info ${bindir}/weston-launch ${bindir}/wcap-decode ${libexecdir} ${libdir}/${BPN}/*.so ${datadir}"
+
+FILES_libweston-${WESTON_MAJOR_VERSION} = "${libdir}/lib*${SOLIBS} ${libdir}/libweston-${WESTON_MAJOR_VERSION}/*.so"
+SUMMARY_libweston-${WESTON_MAJOR_VERSION} = "Helper library for implementing 'wayland window managers'."
+
+FILES_${PN}-examples = "${bindir}/*"
+
+FILES_${PN}-xwayland = "${libdir}/libweston-${WESTON_MAJOR_VERSION}/xwayland.so"
+RDEPENDS_${PN}-xwayland += "xserver-xorg-xwayland"
+
+RDEPENDS_${PN} += "xkeyboard-config"
+RRECOMMENDS_${PN} = "weston-conf liberation-fonts"
+RRECOMMENDS_${PN}-dev += "wayland-protocols"
+
+USERADD_PACKAGES = "${PN}"
+GROUPADD_PARAM_${PN} = "--system weston-launch"
diff --git a/poky/meta/recipes-graphics/xorg-app/mkfontscale_1.1.2.bb b/poky/meta/recipes-graphics/xorg-app/mkfontscale_1.1.2.bb
deleted file mode 100644
index 31cf186..0000000
--- a/poky/meta/recipes-graphics/xorg-app/mkfontscale_1.1.2.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-require xorg-app-common.inc
-
-SUMMARY = "A program to create an index of scalable font files for X"
-
-DESCRIPTION = "For each directory argument, mkfontscale reads all of the \
-scalable font files in the directory. For every font file found, an X11 \
-font name (XLFD) is generated, and is written together with the file \
-name to a file fonts.scale in the directory.  The resulting fonts.scale \
-is used by the mkfontdir program."
-
-DEPENDS = "util-macros-native zlib libfontenc freetype xproto"
-
-BBCLASSEXTEND = "native"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=2e0d129d05305176d1a790e0ac1acb7f"
-
-SRC_URI[md5sum] = "9bdd6ebfa62b1bbd474906ac86a40fd8"
-SRC_URI[sha256sum] = "8c6d5228af885477b9aec60ca6f172578e7d2de42234357af62fb00439453f20"
diff --git a/poky/meta/recipes-graphics/xorg-app/mkfontscale_1.1.3.bb b/poky/meta/recipes-graphics/xorg-app/mkfontscale_1.1.3.bb
new file mode 100644
index 0000000..2a6bec1
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-app/mkfontscale_1.1.3.bb
@@ -0,0 +1,18 @@
+require xorg-app-common.inc
+
+SUMMARY = "A program to create an index of scalable font files for X"
+
+DESCRIPTION = "For each directory argument, mkfontscale reads all of the \
+scalable font files in the directory. For every font file found, an X11 \
+font name (XLFD) is generated, and is written together with the file \
+name to a file fonts.scale in the directory.  The resulting fonts.scale \
+is used by the mkfontdir program."
+
+DEPENDS = "util-macros-native zlib libfontenc freetype xorgproto"
+
+BBCLASSEXTEND = "native"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=2e0d129d05305176d1a790e0ac1acb7f"
+
+SRC_URI[md5sum] = "987c438e79f5ddb84a9c5726a1610819"
+SRC_URI[sha256sum] = "1e98df69ee5f4542d711e140e1d93e2c3f2775407ccbb7849110d52b91782a6a"
diff --git a/poky/meta/recipes-graphics/xorg-app/rgb_1.0.6.bb b/poky/meta/recipes-graphics/xorg-app/rgb_1.0.6.bb
index 8726804..c3e8536 100644
--- a/poky/meta/recipes-graphics/xorg-app/rgb_1.0.6.bb
+++ b/poky/meta/recipes-graphics/xorg-app/rgb_1.0.6.bb
@@ -6,7 +6,7 @@
 lookup, the rgb program to convert the text file into the binary database \
 format."
 
-DEPENDS += " xproto util-macros"
+DEPENDS += " xorgproto util-macros"
 LIC_FILES_CHKSUM = "file://COPYING;md5=ef598adbe241bd0b0b9113831f6e249a"
 PE = "1"
 
diff --git a/poky/meta/recipes-graphics/xorg-app/xev_1.2.2.bb b/poky/meta/recipes-graphics/xorg-app/xev_1.2.2.bb
index f151b57..0705b7f 100644
--- a/poky/meta/recipes-graphics/xorg-app/xev_1.2.2.bb
+++ b/poky/meta/recipes-graphics/xorg-app/xev_1.2.2.bb
@@ -10,7 +10,7 @@
 
 PE = "1"
 
-DEPENDS += "libxrandr xproto"
+DEPENDS += "libxrandr xorgproto"
 
 SRC_URI += "file://diet-x11.patch"
 
diff --git a/poky/meta/recipes-graphics/xorg-app/xeyes_1.1.1.bb b/poky/meta/recipes-graphics/xorg-app/xeyes_1.1.1.bb
deleted file mode 100644
index 84d0cb8..0000000
--- a/poky/meta/recipes-graphics/xorg-app/xeyes_1.1.1.bb
+++ /dev/null
@@ -1,14 +0,0 @@
-require xorg-app-common.inc
-
-SUMMARY = "X11 eyes that follow the mouse cursor demo"
-DESCRIPTION = "Xeyes is a small X11 application that shows a pair of eyes that move to \
-follow the location of the mouse cursor around the screen."
-
-PE = "1"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=3ea51b365051ac32d1813a7dbaa4bfc6"
-
-SRC_URI[md5sum] = "a3035dcecdbdb89e864177c080924981"
-SRC_URI[sha256sum] = "975e98680cd59e1f9439016386609546ed08c284d0f05a95276f96aca6e8a521"
-
-DEPENDS += "libxau libxt libxext libxmu libxrender"
diff --git a/poky/meta/recipes-graphics/xorg-app/xeyes_1.1.2.bb b/poky/meta/recipes-graphics/xorg-app/xeyes_1.1.2.bb
new file mode 100644
index 0000000..06885f8
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-app/xeyes_1.1.2.bb
@@ -0,0 +1,14 @@
+require xorg-app-common.inc
+
+SUMMARY = "X11 eyes that follow the mouse cursor demo"
+DESCRIPTION = "Xeyes is a small X11 application that shows a pair of eyes that move to \
+follow the location of the mouse cursor around the screen."
+
+PE = "1"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=3ea51b365051ac32d1813a7dbaa4bfc6"
+
+SRC_URI[md5sum] = "6f0543ec84283df5743eeafc173bea4a"
+SRC_URI[sha256sum] = "57bcec0d2d167af9e5d44d0dbd74c6d7c0f0591cd0608952b23c749fdd910553"
+
+DEPENDS += "libxau libxt libxext libxmu libxrender"
diff --git a/poky/meta/recipes-graphics/xorg-app/xinit_1.3.4.bb b/poky/meta/recipes-graphics/xorg-app/xinit_1.3.4.bb
deleted file mode 100644
index 9318518..0000000
--- a/poky/meta/recipes-graphics/xorg-app/xinit_1.3.4.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-require xorg-app-common.inc
-
-SUMMARY = "X Window System initializer"
-
-DESCRIPTION = "The xinit program is used to start the X Window System \
-server and a first client program on systems that cannot start X \
-directly from /etc/init or in environments that use multiple window \
-systems. When this first client exits, xinit will kill the X server and \
-then terminate."
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=18f01e7b39807bebe2b8df101a039b68"
-
-PE = "1"
-
-SRC_URI[md5sum] = "4e928452dfaf73851413a2d8b8c76388"
-SRC_URI[sha256sum] = "75d88d7397a07e01db253163b7c7a00b249b3d30e99489f2734cac9a0c7902b3"
-
-EXTRA_OECONF = "ac_cv_path_MCOOKIE=${bindir}/mcookie"
-
-RDEPENDS_${PN} += "util-linux-mcookie"
diff --git a/poky/meta/recipes-graphics/xorg-app/xinit_1.4.0.bb b/poky/meta/recipes-graphics/xorg-app/xinit_1.4.0.bb
new file mode 100644
index 0000000..dc2a06b
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-app/xinit_1.4.0.bb
@@ -0,0 +1,20 @@
+require xorg-app-common.inc
+
+SUMMARY = "X Window System initializer"
+
+DESCRIPTION = "The xinit program is used to start the X Window System \
+server and a first client program on systems that cannot start X \
+directly from /etc/init or in environments that use multiple window \
+systems. When this first client exits, xinit will kill the X server and \
+then terminate."
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=18f01e7b39807bebe2b8df101a039b68"
+
+PE = "1"
+
+SRC_URI[md5sum] = "2da154b2f80ca9637b1a17b13af0880c"
+SRC_URI[sha256sum] = "230835eef2f5978a1e1344928168119373f6df1d0a32c09515e545721ee582ef"
+
+EXTRA_OECONF = "ac_cv_path_MCOOKIE=${bindir}/mcookie"
+
+RDEPENDS_${PN} += "util-linux-mcookie"
diff --git a/poky/meta/recipes-graphics/xorg-app/xkbcomp_1.4.0.bb b/poky/meta/recipes-graphics/xorg-app/xkbcomp_1.4.0.bb
deleted file mode 100644
index c9dc327..0000000
--- a/poky/meta/recipes-graphics/xorg-app/xkbcomp_1.4.0.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-require xorg-app-common.inc
-
-SUMMARY = "A program to compile XKB keyboard description"
-
-DESCRIPTION = "The xkbcomp keymap compiler converts a description of an \
-XKB keymap into one of several output formats. The most common use for \
-xkbcomp is to create a compiled keymap file (.xkm extension) which can \
-be read directly by XKB-capable X servers or utilities."
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=08436e4f4476964e2e2dd7e7e41e076a"
-
-PR = "${INC_PR}.0"
-
-DEPENDS += "libxkbfile"
-
-BBCLASSEXTEND = "native"
-
-SRC_URI[md5sum] = "cc22b232bc78a303371983e1b48794ab"
-SRC_URI[sha256sum] = "bc69c8748c03c5ad9afdc8dff9db11994dd871b614c65f8940516da6bf61ce6b"
diff --git a/poky/meta/recipes-graphics/xorg-app/xkbcomp_1.4.2.bb b/poky/meta/recipes-graphics/xorg-app/xkbcomp_1.4.2.bb
new file mode 100644
index 0000000..eaf8eaa
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-app/xkbcomp_1.4.2.bb
@@ -0,0 +1,17 @@
+require xorg-app-common.inc
+
+SUMMARY = "A program to compile XKB keyboard description"
+
+DESCRIPTION = "The xkbcomp keymap compiler converts a description of an \
+XKB keymap into one of several output formats. The most common use for \
+xkbcomp is to create a compiled keymap file (.xkm extension) which can \
+be read directly by XKB-capable X servers or utilities."
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=08436e4f4476964e2e2dd7e7e41e076a"
+
+DEPENDS += "libxkbfile"
+
+BBCLASSEXTEND = "native"
+
+SRC_URI[md5sum] = "12610df19df2af3797f2c130ee2bce97"
+SRC_URI[sha256sum] = "6dd8bcb9be7e85bd7294abe261b8c7b0539d2fc93e41b80fb8bd013767ce8424"
diff --git a/poky/meta/recipes-graphics/xorg-app/xprop_1.2.2.bb b/poky/meta/recipes-graphics/xorg-app/xprop_1.2.2.bb
deleted file mode 100644
index d78bf0451..0000000
--- a/poky/meta/recipes-graphics/xorg-app/xprop_1.2.2.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-require xorg-app-common.inc
-
-SUMMARY = "Utility to display window and font properties of an X server"
-
-DESCRIPTION = "The xprop utility is for displaying window and font \
-properties in an X server. One window or font is selected using the \
-command line arguments or possibly in the case of a window, by clicking \
-on the desired window. A list of properties is then given, possibly with \
-formatting information."
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=e226ab8db88ac0bc0391673be40c9f91"
-
-DEPENDS += "libxmu"
-
-PE = "1"
-
-SRC_URI[md5sum] = "fae3d2fda07684027a643ca783d595cc"
-SRC_URI[sha256sum] = "9bee88b1025865ad121f72d32576dd3027af1446774aa8300cce3c261d869bc6"
diff --git a/poky/meta/recipes-graphics/xorg-app/xprop_1.2.3.bb b/poky/meta/recipes-graphics/xorg-app/xprop_1.2.3.bb
new file mode 100644
index 0000000..ca58d47
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-app/xprop_1.2.3.bb
@@ -0,0 +1,18 @@
+require xorg-app-common.inc
+
+SUMMARY = "Utility to display window and font properties of an X server"
+
+DESCRIPTION = "The xprop utility is for displaying window and font \
+properties in an X server. One window or font is selected using the \
+command line arguments or possibly in the case of a window, by clicking \
+on the desired window. A list of properties is then given, possibly with \
+formatting information."
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=e226ab8db88ac0bc0391673be40c9f91"
+
+DEPENDS += "libxmu"
+
+PE = "1"
+
+SRC_URI[md5sum] = "4becb3ddc4674d741487189e4ce3d0b6"
+SRC_URI[sha256sum] = "d22afb28c86d85fff10a50156a7d0fa930c80ae865d70b26d805fd28a17a521b"
diff --git a/poky/meta/recipes-graphics/xorg-app/xset_1.2.3.bb b/poky/meta/recipes-graphics/xorg-app/xset_1.2.3.bb
deleted file mode 100644
index f683b76..0000000
--- a/poky/meta/recipes-graphics/xorg-app/xset_1.2.3.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-require xorg-app-common.inc
-
-SUMMARY = "Utility for setting various user preference options of the display"
-
-DESCRIPTION = "xset is a utility that is used to set various user \
-preference options of the display."
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=bea81cc9827cdf1af0e12c2b8228cf8d"
-DEPENDS += "libxext libxxf86misc libxmu libxau"
-PE = "1"
-
-SRC_URI += "file://disable-xkb.patch"
-
-SRC_URI[md5sum] = "dcd227388b57487d543cab2fd7a602d7"
-SRC_URI[sha256sum] = "4382f4fb29b88647e13f3b4bc29263134270747fc159cfc5f7e3af23588c8063"
-
-CFLAGS += "-D_GNU_SOURCE"
-EXTRA_OECONF = "--disable-xkb --without-fontcache"
diff --git a/poky/meta/recipes-graphics/xorg-app/xset_1.2.4.bb b/poky/meta/recipes-graphics/xorg-app/xset_1.2.4.bb
new file mode 100644
index 0000000..5748837
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-app/xset_1.2.4.bb
@@ -0,0 +1,19 @@
+require xorg-app-common.inc
+
+SUMMARY = "Utility for setting various user preference options of the display"
+
+DESCRIPTION = "xset is a utility that is used to set various user \
+preference options of the display."
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=bea81cc9827cdf1af0e12c2b8228cf8d"
+DEPENDS += "libxext libxxf86misc libxmu libxau"
+PE = "1"
+
+SRC_URI += "file://disable-xkb.patch"
+
+SRC_URI[md5sum] = "70ea7bc7bacf1a124b1692605883f620"
+SRC_URI[sha256sum] = "e4fd95280df52a88e9b0abc1fee11dcf0f34fc24041b9f45a247e52df941c957"
+
+CFLAGS += "-D_GNU_SOURCE"
+EXTRA_OECONF = "--disable-xkb --without-fontcache"
diff --git a/poky/meta/recipes-graphics/xorg-app/xwininfo_1.1.3.bb b/poky/meta/recipes-graphics/xorg-app/xwininfo_1.1.3.bb
deleted file mode 100644
index 0c23d19..0000000
--- a/poky/meta/recipes-graphics/xorg-app/xwininfo_1.1.3.bb
+++ /dev/null
@@ -1,15 +0,0 @@
-require xorg-app-common.inc
-
-SUMMARY = "Window information utility for X"
-
-DESCRIPTION = "Xwininfo is a utility for displaying information about \
-windows.  Information may include window position, size, color depth, \
-and a number of other items."
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=78976cd3115f6faf615accc4e094d90e"
-DEPENDS += "libxext libxmu gettext-native"
-
-PE = "0"
-
-SRC_URI[md5sum] = "b777bafb674555e48fd8437618270931"
-SRC_URI[sha256sum] = "218eb0ea95bd8de7903dfaa26423820c523ad1598be0751d2d8b6a2c23b23ff8"
diff --git a/poky/meta/recipes-graphics/xorg-app/xwininfo_1.1.4.bb b/poky/meta/recipes-graphics/xorg-app/xwininfo_1.1.4.bb
new file mode 100644
index 0000000..1fb90dd
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-app/xwininfo_1.1.4.bb
@@ -0,0 +1,15 @@
+require xorg-app-common.inc
+
+SUMMARY = "Window information utility for X"
+
+DESCRIPTION = "Xwininfo is a utility for displaying information about \
+windows.  Information may include window position, size, color depth, \
+and a number of other items."
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=78976cd3115f6faf615accc4e094d90e"
+DEPENDS += "libxext libxmu gettext-native"
+
+PE = "0"
+
+SRC_URI[md5sum] = "9a505b91ae7160bbdec360968d060c83"
+SRC_URI[sha256sum] = "839498aa46b496492a5c65cd42cd2e86e0da88149b0672e90cb91648f8cd5b01"
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-input-evdev_2.10.5.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-input-evdev_2.10.5.bb
deleted file mode 100644
index 96b220c..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-input-evdev_2.10.5.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-require xorg-driver-input.inc
-
-SUMMARY = "X.Org X server -- event devices (evdev) input driver"
-
-DESCRIPTION = "evdev is an Xorg input driver for Linux's generic event \
-devices. It therefore supports all input devices that the kernel knows \
-about, including most mice and keyboards. \
-\
-The evdev driver can serve as both a pointer and a keyboard input \
-device, and may be used as both the core keyboard and the core pointer. \
-Multiple input devices are supported by multiple instances of this \
-driver, with one Load directive for evdev in the Module section of your \
-xorg.conf for each input device that will use this driver. "
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=fefe33b1cf0cacba0e72e3b0fa0f0e16"
-
-DEPENDS += "mtdev libevdev"
-
-SRC_URI[md5sum] = "94c2c8354c74ab1cfbbb0a222078b9c6"
-SRC_URI[sha256sum] = "9edaa6205baf6d2922cc4db3d8e54a7e7773b5f733b0ae90f6be7725f983b70d"
-
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-input-evdev_2.10.6.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-input-evdev_2.10.6.bb
new file mode 100644
index 0000000..60e325c
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-driver/xf86-input-evdev_2.10.6.bb
@@ -0,0 +1,20 @@
+require xorg-driver-input.inc
+
+SUMMARY = "X.Org X server -- event devices (evdev) input driver"
+
+DESCRIPTION = "evdev is an Xorg input driver for Linux's generic event \
+devices. It therefore supports all input devices that the kernel knows \
+about, including most mice and keyboards. \
+\
+The evdev driver can serve as both a pointer and a keyboard input \
+device, and may be used as both the core keyboard and the core pointer. \
+Multiple input devices are supported by multiple instances of this \
+driver, with one Load directive for evdev in the Module section of your \
+xorg.conf for each input device that will use this driver. "
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=fefe33b1cf0cacba0e72e3b0fa0f0e16"
+
+DEPENDS += "mtdev libevdev"
+
+SRC_URI[md5sum] = "e8bd1edc6751f92e425cae7eba3c61eb"
+SRC_URI[sha256sum] = "8726073e81861bc7b2321e76272cbdbd33c7e1a121535a9827977265b9033ec0"
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-input-libinput_0.26.0.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-input-libinput_0.26.0.bb
deleted file mode 100644
index 54c33d7..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-input-libinput_0.26.0.bb
+++ /dev/null
@@ -1,11 +0,0 @@
-require xorg-driver-input.inc
-
-SUMMARY = "Generic input driver for the X.Org server based on libinput"
-LIC_FILES_CHKSUM = "file://COPYING;md5=5e6b20ea2ef94a998145f0ea3f788ee0"
-
-DEPENDS += "libinput"
-
-SRC_URI[md5sum] = "da47ef62eab1d0e922a8fa929ff81758"
-SRC_URI[sha256sum] = "abca558fc2226f295691f1cf3412d4c0edeaa439f677ca25b5c9fab310d2387b"
-
-FILES_${PN} += "${datadir}/X11/xorg.conf.d"
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-input-libinput_0.28.0.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-input-libinput_0.28.0.bb
new file mode 100644
index 0000000..5853b5b
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-driver/xf86-input-libinput_0.28.0.bb
@@ -0,0 +1,11 @@
+require xorg-driver-input.inc
+
+SUMMARY = "Generic input driver for the X.Org server based on libinput"
+LIC_FILES_CHKSUM = "file://COPYING;md5=5e6b20ea2ef94a998145f0ea3f788ee0"
+
+DEPENDS += "libinput"
+
+SRC_URI[md5sum] = "2d7519ac0e39d4c88f3be32e81a637aa"
+SRC_URI[sha256sum] = "21994d065fc26e85d1c3fc87d8479b9c22699ed5a0119df98fbe0000e84630a1"
+
+FILES_${PN} += "${datadir}/X11/xorg.conf.d"
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-input-mouse_1.9.2.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-input-mouse_1.9.2.bb
deleted file mode 100644
index 0750476..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-input-mouse_1.9.2.bb
+++ /dev/null
@@ -1,14 +0,0 @@
-require xorg-driver-input.inc
-
-SUMMARY = "X.Org X server -- mouse input driver"
-
-DESCRIPTION = "mouse is an Xorg input driver for mice. The driver \
-supports most available mouse types and interfaces.  The mouse driver \
-functions as a pointer input device, and may be used as the X server's \
-core pointer. Multiple mice are supported by multiple instances of this \
-driver."
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=90ea9f90d72b6d9327dede5ffdb2a510"
-
-SRC_URI[md5sum] = "ce2d679283a22c8e0dccdd9248594845"
-SRC_URI[sha256sum] = "f425d5b05c6ab412a27e0a1106bb83f9e2662b307210abbe48270892387f4b2f"
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-input-mouse_1.9.3.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-input-mouse_1.9.3.bb
new file mode 100644
index 0000000..c38dab5
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-driver/xf86-input-mouse_1.9.3.bb
@@ -0,0 +1,14 @@
+require xorg-driver-input.inc
+
+SUMMARY = "X.Org X server -- mouse input driver"
+
+DESCRIPTION = "mouse is an Xorg input driver for mice. The driver \
+supports most available mouse types and interfaces.  The mouse driver \
+functions as a pointer input device, and may be used as the X server's \
+core pointer. Multiple mice are supported by multiple instances of this \
+driver."
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=90ea9f90d72b6d9327dede5ffdb2a510"
+
+SRC_URI[md5sum] = "a2104693bbcfe1413397f7905eecd3dc"
+SRC_URI[sha256sum] = "93ecb350604d05be98b7d4e5db3b8155a44890069a7d8d6b800c0bea79c85cc5"
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-input-synaptics_1.9.0.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-input-synaptics_1.9.0.bb
deleted file mode 100644
index d327a3b..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-input-synaptics_1.9.0.bb
+++ /dev/null
@@ -1,16 +0,0 @@
-require xorg-driver-input.inc
-
-SUMMARY = "X.Org X server -- synaptics touchpad input driver"
-
-DESCRIPTION = "synaptics is an Xorg input driver for the touchpads from \
-Synaptics Incorporated. Even though these touchpads (by default, \
-operating in a compatibility mode emulating a standard mouse) can be \
-handled by the normal evdev or mouse drivers, this driver allows more \
-advanced features of the touchpad to become available."
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=55aacd3535a741824955c5eb8f061398"
-
-SRC_URI[md5sum] = "58e5b7722a402114093bf193962d1e3a"
-SRC_URI[sha256sum] = "afba3289d7a40217a19d90db98ce181772f9ca6d77e1898727b0afcf02073b5a"
-
-DEPENDS += "libxi mtdev libxtst libevdev"
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-input-synaptics_1.9.1.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-input-synaptics_1.9.1.bb
new file mode 100644
index 0000000..dc31890
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-driver/xf86-input-synaptics_1.9.1.bb
@@ -0,0 +1,16 @@
+require xorg-driver-input.inc
+
+SUMMARY = "X.Org X server -- synaptics touchpad input driver"
+
+DESCRIPTION = "synaptics is an Xorg input driver for the touchpads from \
+Synaptics Incorporated. Even though these touchpads (by default, \
+operating in a compatibility mode emulating a standard mouse) can be \
+handled by the normal evdev or mouse drivers, this driver allows more \
+advanced features of the touchpad to become available."
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=55aacd3535a741824955c5eb8f061398"
+
+SRC_URI[md5sum] = "cfb79d3c975151f9bbf30b727c260cb9"
+SRC_URI[sha256sum] = "7af83526eff1c76e8b9e1553b34245c203d029028d8044dd9dcf71eef1001576"
+
+DEPENDS += "libxi mtdev libxtst libevdev"
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-fbdev_0.4.4.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-video-fbdev_0.4.4.bb
deleted file mode 100644
index 52e9bd1..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-fbdev_0.4.4.bb
+++ /dev/null
@@ -1,9 +0,0 @@
-require xorg-driver-video.inc
-
-SUMMARY = "X.Org X server -- fbdev display driver"
-DESCRIPTION = "fbdev is an Xorg driver for framebuffer devices. This is a non-accelerated driver."
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=d8cbd99fff773f92e844948f74ef0df8"
-
-SRC_URI[md5sum] = "3931c0e19d441cc576dc088f9eb9fd73"
-SRC_URI[sha256sum] = "9dd4b326498223abbfdf786089a46ea3db4fa6bbd341308eb48a9e00bc3fd51b"
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-fbdev_0.5.0.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-video-fbdev_0.5.0.bb
new file mode 100644
index 0000000..7b4ac88
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-driver/xf86-video-fbdev_0.5.0.bb
@@ -0,0 +1,9 @@
+require xorg-driver-video.inc
+
+SUMMARY = "X.Org X server -- fbdev display driver"
+DESCRIPTION = "fbdev is an Xorg driver for framebuffer devices. This is a non-accelerated driver."
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=d8cbd99fff773f92e844948f74ef0df8"
+
+SRC_URI[md5sum] = "f07475655376be5a124d8187aacd87b6"
+SRC_URI[sha256sum] = "dcc3d85f378022180e437a9ec00a59b6cb7680ff79c40394d695060af2374699"
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-intel/always_include_xorg_server.h.patch b/poky/meta/recipes-graphics/xorg-driver/xf86-video-intel/always_include_xorg_server.h.patch
deleted file mode 100644
index 8a5dd39..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-intel/always_include_xorg_server.h.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-Include xorg-server.h to fix build errors seen with glibc 2.20
-
-In file included from /home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/sysroots/qemux86/usr/include/string.h:634:0,
-                 from /home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/work/i586-oe-linux/xf86-video-intel/2_2.99.912-r0/xf86-video-intel-2.99.912/src/backlight.c:39:
-/home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/sysroots/qemux86/usr/include/xorg/os.h:579:1: error: expected identifier or '(' before '__extension__'
- strndup(const char *str, size_t n);
- ^
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
-
-Index: xf86-video-intel-2.99.912/src/backlight.c
-===================================================================
---- xf86-video-intel-2.99.912.orig/src/backlight.c	2014-04-09 10:41:18.000000000 -0700
-+++ xf86-video-intel-2.99.912/src/backlight.c	2014-08-28 18:52:25.524070587 -0700
-@@ -29,6 +29,7 @@
- #include "config.h"
- #endif
- 
-+#include <xorg-server.h>
- #include <sys/types.h>
- #include <sys/wait.h>
- #include <sys/stat.h>
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-intel/disable-x11-dri3.patch b/poky/meta/recipes-graphics/xorg-driver/xf86-video-intel/disable-x11-dri3.patch
deleted file mode 100644
index 3dddd33..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-intel/disable-x11-dri3.patch
+++ /dev/null
@@ -1,17 +0,0 @@
-These modules are only used for tests that don't get installed, and the
-automatic detection without explicit dependencies means that a build can find
-e.g. xshmfence at configure time but then it's been removed from the sysroot by
-the time compile happens.
-
-As the tests don't get installed, just disable the checks.
-
-Upstream-Status: Inappropriate [OE-specific]
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
-diff --git a/configure.ac b/configure.ac
-index bd654f3..78a0e0d 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -279 +279 @@ fi
--PKG_CHECK_MODULES(X11_DRI3, [xcb-dri3 xcb-sync xcb-xfixes xcb-present x11-xcb xshmfence x11 xcomposite xdamage xrender xrandr xxf86vm xext libdrm], [x11_dri3="yes"], [x11_dri3="no"])
-+#PKG_CHECK_MODULES(X11_DRI3, [xcb-dri3 xcb-sync xcb-xfixes xcb-present x11-xcb xshmfence x11 xcomposite xdamage xrender xrandr xxf86vm xext libdrm], [x11_dri3="yes"], [x11_dri3="no"])
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-intel/glibc.patch b/poky/meta/recipes-graphics/xorg-driver/xf86-video-intel/glibc.patch
new file mode 100644
index 0000000..ada9eb5
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-driver/xf86-video-intel/glibc.patch
@@ -0,0 +1,25 @@
+Add a missing include needed for glibc 2.28 to avoid:
+
+| ../../git/tools/backlight_helper.c: In function 'main':
+| ../../git/tools/backlight_helper.c:54:34: error: implicit declaration of function 'major' [-Werror=implicit-function-declaration]
+|   if (fd < 0 || fstat(fd, &st) || major(st.st_dev))
+|                                   ^~~~~
+| ../../git/tools/backlight_helper.c:54:34: warning: nested extern declaration of 'major' [-Wnested-externs]
+| cc1: some warnings being treated as errors
+| Makefile:666: recipe for target 'backlight_helper.o' failed
+
+Upstream-Status: Pending
+RP 2018/8/12
+
+Index: git/tools/backlight_helper.c
+===================================================================
+--- git.orig/tools/backlight_helper.c
++++ git/tools/backlight_helper.c
+@@ -8,6 +8,7 @@
+ 
+ #include <sys/types.h>
+ #include <sys/stat.h>
++#include <sys/sysmacros.h>
+ 
+ #if MAJOR_IN_MKDEV
+ #include <sys/mkdev.h>
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-intel_git.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-video-intel_git.bb
index 2623cb2..655fd4d 100644
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-intel_git.bb
+++ b/poky/meta/recipes-graphics/xorg-driver/xf86-video-intel_git.bb
@@ -14,28 +14,25 @@
 S = "${WORKDIR}/git"
 
 SRC_URI = "git://anongit.freedesktop.org/xorg/driver/xf86-video-intel \
-           file://disable-x11-dri3.patch \
-           file://always_include_xorg_server.h.patch \
            file://0001-Add-Coffeelake-PCI-IDs-for-S-Skus.patch \
+           file://glibc.patch \
            "
 
-SRC_URI[md5sum] = "fa196a66e52c0c624fe5d350af7a5e7b"
-SRC_URI[sha256sum] = "00b781eea055582820a123c47b62411bdf6aabf4f03dc0568faec55faf9667c9"
 UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+(\.\d+)+)"
 
 DEPENDS += "virtual/libx11 drm libpciaccess pixman"
 
-PACKAGECONFIG ??= "xvmc uxa udev ${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'dri dri1 dri2', '', d)}"
+PACKAGECONFIG ??= "xvmc uxa udev ${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'dri dri2 dri3', '', d)}"
 
 PACKAGECONFIG[dri] = "--enable-dri,--disable-dri"
-PACKAGECONFIG[dri1] = "--enable-dri1,--disable-dri1,xf86driproto"
-PACKAGECONFIG[dri2] = "--enable-dri2,--disable-dri2,dri2proto"
-PACKAGECONFIG[dri3] = "--enable-dri3,--disable-dri3,dri3proto"
+PACKAGECONFIG[dri1] = "--enable-dri1,--disable-dri1"
+PACKAGECONFIG[dri2] = "--enable-dri2,--disable-dri2"
+PACKAGECONFIG[dri3] = "--enable-dri3,--disable-dri3"
 PACKAGECONFIG[sna] = "--enable-sna,--disable-sna"
 PACKAGECONFIG[uxa] = "--enable-uxa,--disable-uxa"
 PACKAGECONFIG[udev] = "--enable-udev,--disable-udev,udev"
 PACKAGECONFIG[xvmc] = "--enable-xvmc,--disable-xvmc,libxvmc xcb-util"
-PACKAGECONFIG[tools] = "--enable-tools,--disable-tools,libxinerama libxrandr libxdamage libxfixes libxcursor libxtst libxext libxrender"
+PACKAGECONFIG[tools] = "--enable-tools,--disable-tools,libxinerama libxrandr libxdamage libxfixes libxcursor libxtst libxrender libxscrnsaver libxext libx11 pixman libxcb libxshmfence"
 
 # --enable-kms-only option is required by ROOTLESS_X
 EXTRA_OECONF += '${@oe.utils.conditional( "ROOTLESS_X", "1", " --enable-kms-only", "", d )}'
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omap_0.4.5.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-video-omap_0.4.5.bb
deleted file mode 100644
index bef3636..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omap_0.4.5.bb
+++ /dev/null
@@ -1,41 +0,0 @@
-require xorg-driver-video.inc
-
-SUMMARY = "X.Org X server -- Texas Instruments OMAP framebuffer driver"
-
-SUMMARY = "X.Org X server -- TI OMAP integrated graphics chipsets driver"
-
-DESCRIPTION = "Open-source X.org graphics driver for TI OMAP graphics \
-Currently relies on a closed-source submodule for EXA acceleration on \
-the following chipsets: \
-  + OMAP3430 \
-  + OMAP3630 \
-  + OMAP4430 \
-  + OMAP4460 \
-  + OMAP5430 \
-  + OMAP5432 \
-\
-NOTE: this driver is work in progress..  you probably don't want to try \
-and use it yet.  The API/ABI between driver and kernel, and driver and \
-acceleration submodules is not stable yet.  This driver requires the \
-omapdrm kernel driver w/ GEM support. \
-"
-
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=10ce5de3b111315ea652a5f74ec0c602"
-DEPENDS += "virtual/libx11 libdrm xf86driproto"
-
-SRC_URI[md5sum] = "3b8ea5e8fba63355c0dc6681c49d5fe5"
-SRC_URI[sha256sum] = "93e7d42107521e61f61980eaea64fb452e87b7b94272e48938ac8d904ccfab5a"
-
-CFLAGS += " -I${STAGING_INCDIR}/xorg "
-
-# Use overlay 2 on omap3 to enable other apps to use overlay 1 (e.g. dmai or omapfbplay)
-do_compile_prepend_armv7a () {
-        sed -i -e s:fb1:fb2:g ${S}/src/omap_xv.c
-}
-
-python () {
-    if not bb.utils.contains ('DISTRO_FEATURES', 'opengl', True, False, d):
-        raise bb.parse.SkipRecipe("'opengl' not in DISTRO_FEATURES")
-}
-
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0001-Prevents-omapfb-from-from-crashing-when-pixelclock-o.patch b/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0001-Prevents-omapfb-from-from-crashing-when-pixelclock-o.patch
deleted file mode 100644
index ac19219..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0001-Prevents-omapfb-from-from-crashing-when-pixelclock-o.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From 28c006c94e57ea71df11ec4fff79d7ffcfc4860f Mon Sep 17 00:00:00 2001
-From: Far McKon <FarMcKon@buglabs.net>
-Date: Tue, 3 May 2011 20:59:04 +0300
-Subject: [PATCH] Prevents omapfb from from crashing when pixelclock of 0 is
- sent to it.
-
-Due to a Linux design bug it is easy to get a pixelclock set to zero
-when changing displays at runtime.
-
-Upstream-Status: Pending
----
- src/omapfb-output.c | 9 +++++++--
- 1 file changed, 7 insertions(+), 2 deletions(-)
-
-diff --git a/src/omapfb-output.c b/src/omapfb-output.c
-index f8b4db3..4d59265 100644
---- a/src/omapfb-output.c
-+++ b/src/omapfb-output.c
-@@ -125,8 +125,13 @@ OMAPFBOutputGetModes(xf86OutputPtr output)
- 	/* Only populate the native (current) mode */
- 	mode = calloc(1, sizeof(DisplayModeRec));
- 	mode->type      |= M_T_PREFERRED;
--	mode->Clock = PICOS2KHZ(ofb->state_info.pixclock);
--	mode->SynthClock = PICOS2KHZ(ofb->state_info.pixclock);
-+	if (ofb->state_info.pixclock == 0) {
-+		mode->Clock = 0;
-+		mode->SynthClock = 0;
-+	} else {
-+		mode->Clock = PICOS2KHZ(ofb->state_info.pixclock);
-+		mode->SynthClock = PICOS2KHZ(ofb->state_info.pixclock);
-+	}
- 	mode->HDisplay   = ofb->state_info.xres;
- 	mode->HSyncStart = mode->HDisplay
- 	                  + ofb->state_info.right_margin;
--- 
-2.1.4
-
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0001-Revert-Set-a-large-CRTC-upper-limit-to-not-prune-lar.patch b/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0001-Revert-Set-a-large-CRTC-upper-limit-to-not-prune-lar.patch
deleted file mode 100644
index 9fb01d4..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0001-Revert-Set-a-large-CRTC-upper-limit-to-not-prune-lar.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From 8fb7d0f99d4afbb574b30cb4f1e66a8f89d94ad5 Mon Sep 17 00:00:00 2001
-From: Koen Kooi <koen@dominion.thruhere.net>
-Date: Wed, 26 Jan 2011 12:04:36 +0100
-Subject: [PATCH 1/6] Revert "Set a large CRTC upper limit to not prune larger
- resolutions"
-
-Picture is garbled after switching resolutions, so revert it.
-Virtual size too big, revert the commit 9c4d7592dcb7dc20a48a6f941d9d94bd73d34153.
-
-Upstream-Status: Pending
-
-Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
----
- src/omapfb-crtc.c | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/src/omapfb-crtc.c b/src/omapfb-crtc.c
-index 9aaa52f..cbeff35 100644
---- a/src/omapfb-crtc.c
-+++ b/src/omapfb-crtc.c
-@@ -190,13 +190,13 @@ OMAPFBCRTCInit(ScrnInfoPtr pScrn)
- 	 * In practise, this doesn't seem to be supported.
- 	 * (no way to setup the overlay offset/base address)
- 	 */
--	 /* FIXME: figure out what makes sense here. A known max resolution?
--	  * framebuffer size?
--	  */
- 	xf86CrtcSetSizeRange(pScrn,
--	                     8, 8, 2048, 2048);
-+	                     8, 8,
-+	                     ofb->state_info.xres_virtual,
-+	                     ofb->state_info.yres_virtual);
- 
- 	ofb->crtc = xf86CrtcCreate(pScrn, &OMAPFBCrtcFuncs);
-+
- }
- 
- 
--- 
-1.8.0
-
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0002-Revert-Set-virtual-size-when-configuring-framebuffer.patch b/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0002-Revert-Set-virtual-size-when-configuring-framebuffer.patch
deleted file mode 100644
index 683a989..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0002-Revert-Set-virtual-size-when-configuring-framebuffer.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From 855c333ac0d16350f895f1d1b9391e9cbb0b6db4 Mon Sep 17 00:00:00 2001
-From: Koen Kooi <koen@dominion.thruhere.net>
-Date: Wed, 26 Jan 2011 13:27:20 +0100
-Subject: [PATCH 2/6] Revert "Set virtual size when configuring framebuffer"
-
-Virtual size too big, so revert it.
-
-This reverts commit 2653ef07883fbd1a5e7025f9300cf89b79ba429a.
-
-Upstream-Status: Pending
-
-Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
----
- src/omapfb-crtc.c | 2 --
- 1 file changed, 2 deletions(-)
-
-diff --git a/src/omapfb-crtc.c b/src/omapfb-crtc.c
-index cbeff35..9655db2 100644
---- a/src/omapfb-crtc.c
-+++ b/src/omapfb-crtc.c
-@@ -98,8 +98,6 @@ OMAPFBCrtcCommitChangeMode (xf86CrtcPtr crtc)
- 	v = ofb->state_info;
- 	v.xres = mode->HDisplay;
- 	v.yres = mode->VDisplay;
--	v.xres_virtual = crtc->scrn->virtualX;
--	v.yres_virtual = crtc->scrn->virtualY;
- 	v.activate = FB_ACTIVATE_NOW;
- 	v.pixclock = KHZ2PICOS(mode->Clock ? mode->Clock : 56000);
- 	v.left_margin = mode->HTotal - mode->HSyncEnd;
--- 
-1.8.0
-
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0003-force-plain-mode.patch b/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0003-force-plain-mode.patch
deleted file mode 100644
index 67ea7c1..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0003-force-plain-mode.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 252f44c072d3447a32127fc9afe5d0d40f3c510e Mon Sep 17 00:00:00 2001
-From: Koen Kooi <koen@dominion.thruhere.net>
-Date: Wed, 26 Jan 2011 13:20:20 +0100
-Subject: [PATCH 3/6] force 'plain' mode
-
-The new DSS mode breaks XV, so force plain mode
-
-Upstream-Status: Pending
-
-Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
-Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
----
- src/omapfb-driver.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/omapfb-driver.c b/src/omapfb-driver.c
-index 018e040..48aa09c 100644
---- a/src/omapfb-driver.c
-+++ b/src/omapfb-driver.c
-@@ -326,7 +326,7 @@ OMAPFBPreInit(ScrnInfoPtr pScrn, int flags)
- 	OMAPFBProbeController(ofb->ctrl_name);
- 
- 	/* Do we have the DSS kernel API? */
--	if (stat(SYSFS_DSS_DIR, &st) == 0) {
-+	if (0) { //stat(SYSFS_DSS_DIR, &st) == 0) {
- 		ofb->dss = TRUE;
- 	} else {
- 		ofb->dss = FALSE;
--- 
-1.8.0
-
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0004-blacklist-tv-out.patch b/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0004-blacklist-tv-out.patch
deleted file mode 100644
index b0ac9a4..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0004-blacklist-tv-out.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From cfa46b67f59115f6d8ef9414af60380749ff3eb3 Mon Sep 17 00:00:00 2001
-From: Koen Kooi <koen@dominion.thruhere.net>
-Date: Wed, 26 Jan 2011 13:21:12 +0100
-Subject: [PATCH 4/6] blacklist tv out
-
-The tv-out gets added last and the driver tries to reconfigure dvi to TV resolutions, which fails. so blacklist it
-
-Upstream-Status: Pending
-
-Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
-Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
----
- src/omapfb-output-dss.c | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/src/omapfb-output-dss.c b/src/omapfb-output-dss.c
-index 6cc52de..83cb711 100644
---- a/src/omapfb-output-dss.c
-+++ b/src/omapfb-output-dss.c
-@@ -205,6 +205,10 @@ OMAPFBDSSOutputDetect (xf86OutputPtr output)
- 	if(ofb->timings[idx][0] == '\0')
- 		return XF86OutputStatusDisconnected;
- 
-+	// Hack to disable the tv out
-+	if (strncmp(output->name, "tv", 2) == 0)
-+		return XF86OutputStatusDisconnected;
-+
- 	return XF86OutputStatusConnected;
- }
- 
--- 
-1.8.0
-
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0005-Attempt-to-fix-VRFB.patch b/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0005-Attempt-to-fix-VRFB.patch
deleted file mode 100644
index 67b2840..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0005-Attempt-to-fix-VRFB.patch
+++ /dev/null
@@ -1,325 +0,0 @@
-From 8b1f697a60e35ab82fffdabfaefdb45e9a9df379 Mon Sep 17 00:00:00 2001
-From: Eino-Ville Talvala <talvala@stanford.edu>
-Date: Tue, 23 Aug 2011 18:37:01 +0200
-Subject: [PATCH 5/6] Attempt to fix VRFB
-
-Upstream-Status: Pending
-
-http://dominion.thruhere.net/git/cgit.cgi/xf86-video-omapfb/commit/?h=koen/fixups&id=6833fc9f795265e4943d248103fbaf3463b515d6
-
-Signed-off-by: Sebastian Krzyszkowiak <dos@dosowisko.net>
-Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
----
- src/image-format-conversions.c |  4 +--
- src/image-format-conversions.h |  2 +-
- src/omapfb-driver.c            | 28 +++++++++++++---
- src/omapfb-xv-blizzard.c       |  1 +
- src/omapfb-xv-generic.c        | 72 +++++++++++++++++++++++++++++++++---------
- src/omapfb-xv.c                |  3 ++
- 6 files changed, 88 insertions(+), 22 deletions(-)
-
-diff --git a/src/image-format-conversions.c b/src/image-format-conversions.c
-index dcefa9b..d43427d 100644
---- a/src/image-format-conversions.c
-+++ b/src/image-format-conversions.c
-@@ -38,13 +38,13 @@
- #include "image-format-conversions.h"
- 
- /* Basic line-based copy for packed formats */
--void packed_line_copy(int w, int h, int stride, uint8_t *src, uint8_t *dest)
-+void packed_line_copy(int w, int h, int src_stride, int dst_stride, uint8_t *src, uint8_t *dest)
- {
- 	int i;
- 	int len = w * 2;
- 	for (i = 0; i < h; i++)
- 	{
--		memcpy(dest + i * len, src + i * stride, len);
-+		memcpy(dest + i * dst_stride, src + i * src_stride, len);
- 	}
- }
- 
-diff --git a/src/image-format-conversions.h b/src/image-format-conversions.h
-index 584896a..ba7caf2 100644
---- a/src/image-format-conversions.h
-+++ b/src/image-format-conversions.h
-@@ -27,7 +27,7 @@
- #include <stdint.h>
- 
- /* Basic line-based copy for packed formats */
--void packed_line_copy(int w, int h, int stride, uint8_t *src, uint8_t *dest);
-+void packed_line_copy(int w, int h, int src_stride, int dst_stride, uint8_t *src, uint8_t *dest);
- 
- /* Basic C implementation of YV12/I420 to UYVY conversion */
- void uv12_to_uyvy(int w, int h, int y_pitch, int uv_pitch, uint8_t *y_p, uint8_t *u_p, uint8_t *v_p, uint8_t *dest);
-diff --git a/src/omapfb-driver.c b/src/omapfb-driver.c
-index 48aa09c..07989f5 100644
---- a/src/omapfb-driver.c
-+++ b/src/omapfb-driver.c
-@@ -66,6 +66,7 @@
- #define OMAPFB_VERSION 1000
- #define OMAPFB_DRIVER_NAME "OMAPFB"
- #define OMAPFB_NAME "omapfb"
-+#define ENFORCE_MODES
- 
- static Bool OMAPFBProbe(DriverPtr drv, int flags);
- static Bool OMAPFBPreInit(ScrnInfoPtr pScrn, int flags);
-@@ -105,11 +106,13 @@ static SymTabRec OMAPFBChipsets[] = {
- typedef enum {
- 	OPTION_ACCELMETHOD,
- 	OPTION_FB,
-+	OPTION_ROTATE,
- } FBDevOpts;
- 
- static const OptionInfoRec OMAPFBOptions[] = {
- 	{ OPTION_ACCELMETHOD,	"AccelMethod",	OPTV_STRING,	{0},	FALSE },
- 	{ OPTION_FB,		"fb",		OPTV_STRING,	{0},	FALSE },
-+	{ OPTION_ROTATE,	"rotation",	OPTV_STRING,	{0},	FALSE },
- 	{ -1,			NULL,		OPTV_NONE,	{0},	FALSE }
- };
- 
-@@ -286,6 +289,7 @@ OMAPFBPreInit(ScrnInfoPtr pScrn, int flags)
- {
- 	OMAPFBPtr ofb;
- 	EntityInfoPtr pEnt;
-+	char *rotate;
- 	rgb zeros = { 0, 0, 0 };
- 	struct stat st;
- 
-@@ -379,6 +383,8 @@ OMAPFBPreInit(ScrnInfoPtr pScrn, int flags)
- 	pScrn->progClock = TRUE;
- 	pScrn->chipset   = "omapfb";
- 	
-+	xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Rotate test version 0.02\n");
-+	
- 	/* Start with configured virtual size */
- 	pScrn->virtualX = pScrn->display->virtualX;
- 	pScrn->virtualY = pScrn->display->virtualY;
-@@ -496,12 +502,21 @@ OMAPFBScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
- 	ofb->CloseScreen = pScreen->CloseScreen;
- 	pScreen->CloseScreen = OMAPFBCloseScreen;
- 
-+	/* Enforce the default mode (this is silly I guess) */
-+#ifdef ENFORCE_MODES
-+	//xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Enforcing modes\n");
-+	//set_mode(ofb, &ofb->default_mode);
-+	//pScrn->displayWidth = ofb->fixed_info.line_length /
-+	//  (ofb->state_info.bits_per_pixel>>3); //ofb->state_info.xres;
-+#endif
-+
- 	/* Map our framebuffer memory */
-+	ofb->mem_info.size = ofb->fixed_info.line_length * ofb->state_info.yres;
- 	ofb->fb = mmap (NULL, ofb->mem_info.size,
- 	                PROT_READ | PROT_WRITE, MAP_SHARED,
- 	                ofb->fd, 0);
--	if (ofb->fb == NULL) {
--		xf86DrvMsg(scrnIndex, X_ERROR, "Mapping framebuffer memory failed\n");
-+	if (ofb->fb == MAP_FAILED) {
-+		xf86DrvMsg(scrnIndex, X_ERROR, "Mapping framebuffer memory failed, wanted %d bytes.\n", ofb->mem_info.size);
- 		return FALSE;
- 	}
- 
-@@ -578,8 +593,13 @@ OMAPFBScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
- 	} else if (!ofb->dss) {
- 
- 		ofb->plane_info.enabled = 1;
--		ofb->plane_info.out_width = ofb->state_info.xres;
--		ofb->plane_info.out_height = ofb->state_info.yres;
-+		if (ofb->state_info.rotate == 0 || ofb->state_info.rotate == 2) {
-+			ofb->plane_info.out_width = ofb->state_info.xres;
-+			ofb->plane_info.out_height = ofb->state_info.yres;
-+		} else {
-+			ofb->plane_info.out_width = ofb->state_info.yres;
-+			ofb->plane_info.out_height = ofb->state_info.xres;
-+		}
- 
- 		if (ioctl (ofb->fd, OMAPFB_SETUP_PLANE, &ofb->plane_info)) {
- 			xf86DrvMsg(scrnIndex, X_ERROR,
-diff --git a/src/omapfb-xv-blizzard.c b/src/omapfb-xv-blizzard.c
-index 406ffc6..b71d2aa 100644
---- a/src/omapfb-xv-blizzard.c
-+++ b/src/omapfb-xv-blizzard.c
-@@ -220,6 +220,7 @@ int OMAPFBXVPutImageBlizzard (ScrnInfoPtr pScrn,
- 			packed_line_copy(src_w & ~3,
- 			                 src_h & ~3,
- 			                 ((src_w + 1) & ~1) * 2,
-+					 ofb->port->fixed_info.line_length,
- 			                 (uint8_t*)buf,
- 			                 (uint8_t*)ofb->port->fb);
- 			break;
-diff --git a/src/omapfb-xv-generic.c b/src/omapfb-xv-generic.c
-index e6f89fe..b33f344 100644
---- a/src/omapfb-xv-generic.c
-+++ b/src/omapfb-xv-generic.c
-@@ -62,7 +62,7 @@ int OMAPXVAllocPlane(ScrnInfoPtr pScrn)
- {
- 	OMAPFBPtr ofb = OMAPFB(pScrn);
- 
--	/* The memory size is already set in OMAPFBXVQueryImageAttributes */
-+	/* The memory size is already set before we get here */
- 	if (ioctl(ofb->port->fd, OMAPFB_SETUP_MEM, &ofb->port->mem_info) != 0) {
- 		xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
- 		           "Failed to allocate video plane memory\n");
-@@ -73,19 +73,20 @@ int OMAPXVAllocPlane(ScrnInfoPtr pScrn)
- 	ofb->port->fb = mmap (NULL, ofb->port->mem_info.size,
- 	                PROT_READ | PROT_WRITE, MAP_SHARED,
- 	                ofb->port->fd, 0);
--	if (ofb->port->fb == NULL) {
-+	if (ofb->port->fb == MAP_FAILED) {
- 		xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
- 		           "Mapping video memory failed\n");
- 		return XvBadAlloc;
- 	}
- 
- 	/* Update the state info */
-+	/* Let's not - it's bad
- 	if (ioctl (ofb->port->fd, FBIOGET_VSCREENINFO, &ofb->port->state_info))
- 	{
- 		xf86Msg(X_ERROR, "%s: Reading state info failed\n", __FUNCTION__);
- 		return XvBadAlloc;
- 	}
--
-+	*/
- 	return Success;
- }
- 
-@@ -93,6 +94,7 @@ int OMAPXVAllocPlane(ScrnInfoPtr pScrn)
- int OMAPXVSetupVideoPlane(ScrnInfoPtr pScrn)
- {
- 	OMAPFBPtr ofb = OMAPFB(pScrn);
-+	int ret;
- 
- 	if (ioctl (ofb->port->fd, FBIOPUT_VSCREENINFO, &ofb->port->state_info))
- 	{
-@@ -104,6 +106,31 @@ int OMAPXVSetupVideoPlane(ScrnInfoPtr pScrn)
- 		xf86Msg(X_ERROR, "%s: Reading state info failed\n", __FUNCTION__);
- 		return XvBadAlloc;
- 	}
-+	/* Changing rotation/nonstd flags can change the fixed info! */
-+	if (ioctl (ofb->port->fd, FBIOGET_FSCREENINFO, &ofb->port->fixed_info))
-+	{
-+		xf86Msg(X_ERROR, "%s: Reading state info failed\n", __FUNCTION__);
-+		return XvBadAlloc;
-+	}
-+	/* Correct fixed info requires recalculation of needed memory */
-+	ofb->port->mem_info.size = ofb->port->fixed_info.line_length * ofb->port->state_info.yres;
-+
-+	/* Allocate buffer memory */
-+	ret = OMAPXVAllocPlane(pScrn);
-+	if (ret != Success)
-+		return ret;
-+
-+	/* Workaround for reset of mode after memory allo */
-+	if (ioctl (ofb->port->fd, FBIOPUT_VSCREENINFO, &ofb->port->state_info))
-+	{
-+		xf86Msg(X_ERROR, "%s: setting state info failed\n", __FUNCTION__);
-+		return XvBadAlloc;
-+	}
-+	if (ioctl (ofb->port->fd, FBIOGET_VSCREENINFO, &ofb->port->state_info))
-+	{
-+		xf86Msg(X_ERROR, "%s: Reading state info failed\n", __FUNCTION__);
-+		return XvBadAlloc;
-+	}
- 
- 	if(ioctl(ofb->port->fd, OMAPFB_SETUP_PLANE,
- 	   &ofb->port->plane_info) != 0) {
-@@ -124,6 +151,8 @@ int OMAPFBXVPutImageGeneric (ScrnInfoPtr pScrn,
-                              DrawablePtr pDraw)
- {
- 	OMAPFBPtr ofb = OMAPFB(pScrn);
-+	short drw_temp;
-+	short rot_xres, rot_yres;
- 
- 	if (!ofb->port->plane_info.enabled
- 	 || ofb->port->update_window.x != src_x
-@@ -163,13 +192,6 @@ int OMAPFBXVPutImageGeneric (ScrnInfoPtr pScrn,
- 			return Success;
- 		}
- 
--		/* If we don't have the plane running, enable it */
--		if (!ofb->port->plane_info.enabled) {
--			ret = OMAPXVAllocPlane(pScrn);
--			if (ret != Success)
--				return ret;
--		}
--
- 		/* Set up the state info, xres and yres will be used for
- 		 * scaling to the values in the plane info struct
- 		 */
-@@ -179,12 +201,31 @@ int OMAPFBXVPutImageGeneric (ScrnInfoPtr pScrn,
- 		ofb->port->state_info.yres_virtual = 0;
- 		ofb->port->state_info.xoffset = 0;
- 		ofb->port->state_info.yoffset = 0;
--		ofb->port->state_info.rotate = 0;
-+		//ofb->port->state_info.rotate = 0;
- 		ofb->port->state_info.grayscale = 0;
- 		ofb->port->state_info.activate = FB_ACTIVATE_NOW;
- 		ofb->port->state_info.bits_per_pixel = 0;
- 		ofb->port->state_info.nonstd = xv_to_omapfb_format(image);
- 
-+		/* Plane info does not rotate with state_info */
-+		if (ofb->port->state_info.rotate == 1 ||
-+		  ofb->port->state_info.rotate == 3) {
-+			drw_temp = drw_x;
-+			drw_x = drw_y;
-+			drw_y = drw_temp;
-+
-+			drw_temp = drw_w;
-+			drw_w = drw_h;
-+			drw_h = drw_temp;
-+
-+			rot_xres = ofb->port->state_info.yres;
-+			rot_yres = ofb->port->state_info.xres;
-+		} else {
-+			rot_xres = ofb->port->state_info.xres;
-+			rot_yres = ofb->port->state_info.yres;
-+		}
-+
-+
- 		/* Set up the video plane info */
- 		ofb->port->plane_info.enabled = 1;
- 		ofb->port->plane_info.pos_x = drw_x;
-@@ -193,13 +234,13 @@ int OMAPFBXVPutImageGeneric (ScrnInfoPtr pScrn,
- 		ofb->port->plane_info.out_height = drw_h & ~15;
- 
- 		/* Cap output to screen size */
--		if (ofb->port->plane_info.out_width > ofb->state_info.xres) {
-+		if (ofb->port->plane_info.out_width > rot_xres) {
- 			ofb->port->plane_info.pos_x = 0;
--			ofb->port->plane_info.out_width = ofb->state_info.xres;
-+			ofb->port->plane_info.out_width = rot_xres;
- 		}
--		if (ofb->port->plane_info.out_height > ofb->state_info.yres) {
-+		if (ofb->port->plane_info.out_height > rot_yres) {
- 			ofb->port->plane_info.pos_y = 0;
--			ofb->port->plane_info.out_height = ofb->state_info.yres;
-+			ofb->port->plane_info.out_height = rot_yres;
- 		}
- 
- 		ret = OMAPXVSetupVideoPlane(pScrn);
-@@ -223,6 +264,7 @@ int OMAPFBXVPutImageGeneric (ScrnInfoPtr pScrn,
- 			packed_line_copy(src_w & ~15,
- 			                 src_h & ~15,
- 			                 ((src_w + 1) & ~1) * 2,
-+			                 ofb->port->fixed_info.line_length,
- 			                 (uint8_t*)buf,
- 			                 (uint8_t*)ofb->port->fb);
- 			break;
-diff --git a/src/omapfb-xv.c b/src/omapfb-xv.c
-index 1df651e..0fee2c6 100644
---- a/src/omapfb-xv.c
-+++ b/src/omapfb-xv.c
-@@ -169,8 +169,11 @@ static int OMAPFBXVQueryImageAttributes (ScrnInfoPtr pScrn,
- 	h = *height;
- 
- 	w = (w + 1) & ~1;
-+
-+	/* Can't calculate these here - don't know line length
- 	ofb->port->mem_info.size = w << 1;
- 	ofb->port->mem_info.size *= h;
-+	*/
- 
- 	return size;
- }
--- 
-1.8.0
-
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0006-omapfb-port-to-new-xserver-video-API.patch b/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0006-omapfb-port-to-new-xserver-video-API.patch
deleted file mode 100644
index d567299..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0006-omapfb-port-to-new-xserver-video-API.patch
+++ /dev/null
@@ -1,272 +0,0 @@
-From 803ecf2909949e6152f4a81b6cbb92a4430679ac Mon Sep 17 00:00:00 2001
-From: Martin Jansa <Martin.Jansa@gmail.com>
-Date: Fri, 23 Nov 2012 00:31:06 +0100
-Subject: [PATCH 6/6] omapfb: port to new xserver video API
-
-Upstream-Status: Pending
-
-Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
----
- src/compat-api.h    | 96 +++++++++++++++++++++++++++++++++++++++++++++++++++++
- src/omapfb-driver.c | 41 ++++++++++++-----------
- 2 files changed, 118 insertions(+), 19 deletions(-)
- create mode 100644 src/compat-api.h
-
-diff --git a/src/compat-api.h b/src/compat-api.h
-new file mode 100644
-index 0000000..b1591b1
---- /dev/null
-+++ b/src/compat-api.h
-@@ -0,0 +1,96 @@
-+/*
-+ * Copyright 2012 Red Hat, Inc.
-+ *
-+ * Permission is hereby granted, free of charge, to any person obtaining a
-+ * copy of this software and associated documentation files (the "Software"),
-+ * to deal in the Software without restriction, including without limitation
-+ * the rights to use, copy, modify, merge, publish, distribute, sublicense,
-+ * and/or sell copies of the Software, and to permit persons to whom the
-+ * Software is furnished to do so, subject to the following conditions:
-+ *
-+ * The above copyright notice and this permission notice (including the next
-+ * paragraph) shall be included in all copies or substantial portions of the
-+ * Software.
-+ *
-+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
-+ * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
-+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
-+ * DEALINGS IN THE SOFTWARE.
-+ *
-+ * Author: Dave Airlie <airlied@redhat.com>
-+ */
-+
-+/* this file provides API compat between server post 1.13 and pre it,
-+   it should be reused inside as many drivers as possible */
-+#ifndef COMPAT_API_H
-+#define COMPAT_API_H
-+
-+#ifndef GLYPH_HAS_GLYPH_PICTURE_ACCESSOR
-+#define GetGlyphPicture(g, s) GlyphPicture((g))[(s)->myNum]
-+#define SetGlyphPicture(g, s, p) GlyphPicture((g))[(s)->myNum] = p
-+#endif
-+
-+#ifndef XF86_HAS_SCRN_CONV
-+#define xf86ScreenToScrn(s) xf86Screens[(s)->myNum]
-+#define xf86ScrnToScreen(s) screenInfo.screens[(s)->scrnIndex]
-+#endif
-+
-+#ifndef XF86_SCRN_INTERFACE
-+
-+#define SCRN_ARG_TYPE int
-+#define SCRN_INFO_PTR(arg1) ScrnInfoPtr pScrn = xf86Screens[(arg1)]
-+
-+#define SCREEN_ARG_TYPE int
-+#define SCREEN_PTR(arg1) ScreenPtr pScreen = screenInfo.screens[(arg1)]
-+
-+#define SCREEN_INIT_ARGS_DECL int index, ScreenPtr pScreen, int argc, char **argv
-+
-+#define BLOCKHANDLER_ARGS_DECL int arg, pointer blockData, pointer pTimeout, pointer pReadmask
-+#define BLOCKHANDLER_ARGS arg, blockData, pTimeout, pReadmask
-+
-+#define CLOSE_SCREEN_ARGS_DECL int scrnIndex, ScreenPtr pScreen
-+#define CLOSE_SCREEN_ARGS scrnIndex, pScreen
-+
-+#define ADJUST_FRAME_ARGS_DECL int arg, int x, int y, int flags
-+
-+#define SWITCH_MODE_ARGS_DECL int arg, DisplayModePtr mode, int flags
-+
-+#define FREE_SCREEN_ARGS_DECL int arg, int flags
-+#define FREE_SCREEN_ARGS(x) (x)->scrnIndex, 0
-+
-+#define VT_FUNC_ARGS_DECL int arg, int flags
-+#define VT_FUNC_ARGS(flags) pScrn->scrnIndex, (flags)
-+
-+#define XF86_ENABLEDISABLEFB_ARG(x) ((x)->scrnIndex)
-+#else
-+#define SCRN_ARG_TYPE ScrnInfoPtr
-+#define SCRN_INFO_PTR(arg1) ScrnInfoPtr pScrn = (arg1)
-+
-+#define SCREEN_ARG_TYPE ScreenPtr
-+#define SCREEN_PTR(arg1) ScreenPtr pScreen = (arg1)
-+
-+#define SCREEN_INIT_ARGS_DECL ScreenPtr pScreen, int argc, char **argv
-+
-+#define BLOCKHANDLER_ARGS_DECL ScreenPtr arg, pointer pTimeout, pointer pReadmask
-+#define BLOCKHANDLER_ARGS arg, pTimeout, pReadmask
-+
-+#define CLOSE_SCREEN_ARGS_DECL ScreenPtr pScreen
-+#define CLOSE_SCREEN_ARGS pScreen
-+
-+#define ADJUST_FRAME_ARGS_DECL ScrnInfoPtr arg, int x, int y
-+#define SWITCH_MODE_ARGS_DECL ScrnInfoPtr arg, DisplayModePtr mode
-+
-+#define FREE_SCREEN_ARGS_DECL ScrnInfoPtr arg
-+#define FREE_SCREEN_ARGS(x) (x)
-+
-+#define VT_FUNC_ARGS_DECL ScrnInfoPtr arg
-+#define VT_FUNC_ARGS(flags) pScrn
-+
-+#define XF86_ENABLEDISABLEFB_ARG(x) (x)
-+
-+#endif
-+
-+#endif
-diff --git a/src/omapfb-driver.c b/src/omapfb-driver.c
-index 07989f5..486ffa4 100644
---- a/src/omapfb-driver.c
-+++ b/src/omapfb-driver.c
-@@ -44,6 +44,8 @@
- 
- #include "exa.h"
- 
-+#include "compat-api.h"
-+
- #ifdef HAVE_XEXTPROTO_71
- #include <X11/extensions/dpmsconst.h>
- #else
-@@ -70,10 +72,10 @@
- 
- static Bool OMAPFBProbe(DriverPtr drv, int flags);
- static Bool OMAPFBPreInit(ScrnInfoPtr pScrn, int flags);
--static Bool OMAPFBScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv);
--static Bool OMAPFBEnterVT(int scrnIndex, int flags);
--static void OMAPFBLeaveVT(int scrnIndex, int flags);
--static Bool OMAPFBSwitchMode(int scrnIndex, DisplayModePtr mode, int flags);
-+static Bool OMAPFBScreenInit(SCREEN_INIT_ARGS_DECL);
-+static Bool OMAPFBEnterVT(VT_FUNC_ARGS_DECL);
-+static void OMAPFBLeaveVT(VT_FUNC_ARGS_DECL);
-+static Bool OMAPFBSwitchMode(SWITCH_MODE_ARGS_DECL);
- 
- static Bool
- OMAPFBEnsureRec(ScrnInfoPtr pScrn)
-@@ -481,7 +483,7 @@ OMAPFBXvScreenInit(ScreenPtr pScreen)
- }
- 
- static Bool
--OMAPFBCloseScreen(int scrnIndex, ScreenPtr pScreen)
-+OMAPFBCloseScreen(CLOSE_SCREEN_ARGS_DECL)
- {
- 	ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum];
- 	OMAPFBPtr ofb = OMAPFB(pScrn);
-@@ -490,11 +492,11 @@ OMAPFBCloseScreen(int scrnIndex, ScreenPtr pScreen)
- 
- 	pScreen->CloseScreen = ofb->CloseScreen;
- 	
--	return (*pScreen->CloseScreen)(scrnIndex, pScreen);
-+	return (*pScreen->CloseScreen)(CLOSE_SCREEN_ARGS);
- }
- 
- static Bool
--OMAPFBScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
-+OMAPFBScreenInit(SCREEN_INIT_ARGS_DECL)
- {
- 	ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum];
- 	OMAPFBPtr ofb = OMAPFB(pScrn);
-@@ -516,7 +518,7 @@ OMAPFBScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
- 	                PROT_READ | PROT_WRITE, MAP_SHARED,
- 	                ofb->fd, 0);
- 	if (ofb->fb == MAP_FAILED) {
--		xf86DrvMsg(scrnIndex, X_ERROR, "Mapping framebuffer memory failed, wanted %d bytes.\n", ofb->mem_info.size);
-+		xf86DrvMsg(pScrn->scrnIndex, X_ERROR, "Mapping framebuffer memory failed, wanted %d bytes.\n", ofb->mem_info.size);
- 		return FALSE;
- 	}
- 
-@@ -526,7 +528,7 @@ OMAPFBScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
- 	/* Only support TrueColor for now */
- 	if (!miSetVisualTypes(pScrn->depth, TrueColorMask,
- 		pScrn->rgbBits, pScrn->defaultVisual)) {
--		xf86DrvMsg(scrnIndex, X_ERROR, "visual type setup failed"
-+		xf86DrvMsg(pScrn->scrnIndex, X_ERROR, "visual type setup failed"
- 		           " for %d bits per pixel [1]\n",
- 		           pScrn->bitsPerPixel);
- 		return FALSE;
-@@ -534,7 +536,7 @@ OMAPFBScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
- 
- 	/* Set up pixmap depth information */
- 	if (!miSetPixmapDepths()) {
--		xf86DrvMsg(scrnIndex,X_ERROR,"pixmap depth setup failed\n");
-+		xf86DrvMsg(pScrn->scrnIndex,X_ERROR,"pixmap depth setup failed\n");
- 		return FALSE;
- 	}
- 
-@@ -546,7 +548,7 @@ OMAPFBScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
- 	                  pScrn->virtualY, pScrn->xDpi,
- 	                  pScrn->yDpi, pScrn->displayWidth,
- 	                  pScrn->bitsPerPixel)) {
--		xf86DrvMsg(scrnIndex, X_ERROR, "fbScreenInit failed\n");
-+		xf86DrvMsg(pScrn->scrnIndex, X_ERROR, "fbScreenInit failed\n");
- 		return FALSE;
- 	}
- 
-@@ -567,7 +569,7 @@ OMAPFBScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
- 
- 	/* Initialize XRender fallbacks */
- 	if (!fbPictureInit(pScreen, NULL, 0)) {
--		xf86DrvMsg(scrnIndex, X_ERROR, "fbPictureInit failed\n");
-+		xf86DrvMsg(pScrn->scrnIndex, X_ERROR, "fbPictureInit failed\n");
- 		return FALSE;
- 	}
- 	
-@@ -579,7 +581,7 @@ OMAPFBScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
- 
- 	/* Initialize default colormap */
- 	if (!miCreateDefColormap(pScreen)) {
--		xf86DrvMsg(scrnIndex, X_ERROR,
-+		xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
- 		           "creating default colormap failed\n");
- 		return FALSE;
- 	}
-@@ -589,7 +591,7 @@ OMAPFBScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
- 		/* This is non-fatal since we might be running against older
- 		 * kernel driver in which case we only do basic 2D stuff...
- 		 */
--		xf86DrvMsg(scrnIndex, X_ERROR, "Reading plane info failed\n");
-+		xf86DrvMsg(pScrn->scrnIndex, X_ERROR, "Reading plane info failed\n");
- 	} else if (!ofb->dss) {
- 
- 		ofb->plane_info.enabled = 1;
-@@ -602,7 +604,7 @@ OMAPFBScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
- 		}
- 
- 		if (ioctl (ofb->fd, OMAPFB_SETUP_PLANE, &ofb->plane_info)) {
--			xf86DrvMsg(scrnIndex, X_ERROR,
-+			xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
- 			            "%s: Plane setup failed: %s\n",
- 			            __FUNCTION__, strerror(errno));
- 			return FALSE;
-@@ -645,9 +647,10 @@ OMAPFBScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
- 	return TRUE;
- }
- 
--static Bool OMAPFBSwitchMode(int scrnIndex, DisplayModePtr mode, int flags)
-+static Bool OMAPFBSwitchMode(SWITCH_MODE_ARGS_DECL)
- {
--	return xf86SetSingleMode (xf86Screens[scrnIndex], mode, RR_Rotate_0);
-+	SCRN_INFO_PTR(arg);
-+	return xf86SetSingleMode (pScrn, mode, RR_Rotate_0);
- }
- 
- void
-@@ -699,14 +702,14 @@ OMAPFBPrintCapabilities(ScrnInfoPtr pScrn,
- /*** Unimplemented: */
- 
- static Bool
--OMAPFBEnterVT(int scrnIndex, int flags)
-+OMAPFBEnterVT(VT_FUNC_ARGS_DECL)
- {
- 	xf86Msg(X_NOT_IMPLEMENTED, "%s\n", __FUNCTION__);
- 	return TRUE;
- }
- 
- static void
--OMAPFBLeaveVT(int scrnIndex, int flags)
-+OMAPFBLeaveVT(VT_FUNC_ARGS_DECL)
- {
- 	xf86Msg(X_NOT_IMPLEMENTED, "%s\n", __FUNCTION__);
- }
--- 
-1.8.0
-
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0007-always_include_xorg_server.h.patch b/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0007-always_include_xorg_server.h.patch
deleted file mode 100644
index dc0b9b3..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb/0007-always_include_xorg_server.h.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-Fix errors with glibc 2.20
-
-In file included from /home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/sysroots/qemux86/usr/include/string.h:634:0,
-                 from /home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/sysroots/qemux86/usr/include/xorg/os.h:53,
-                 from /home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/sysroots/qemux86/usr/include/xorg/misc.h:115,
-                 from /home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/sysroots/qemux86/usr/include/xorg/xf86str.h:37,
-                 from /home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/sysroots/qemux86/usr/include/xorg/xf86.h:44,
-                 from /home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/work/i586-oe-linux/xf86-video-omapfb/2_0.1.1+gitrAUTOINC+28c006c94e-r21.7/git/src/omapfb-xv-blizzard.c:33:
-/home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/sysroots/qemux86/usr/include/xorg/os.h:579:1: error: expected identifier or '(' before '__extension__'
- strndup(const char *str, size_t n);
- ^
-In file included from /home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/sysroots/qemux86/usr/include/string.h:634:0,
-                 from /home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/sysroots/qemux86/usr/include/xorg/os.h:53,
-                 from /home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/sysroots/qemux86/usr/include/xorg/misc.h:115,
-                 from /home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/sysroots/qemux86/usr/include/xorg/xf86str.h:37,
-                 from /home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/sysroots/qemux86/usr/include/xorg/xf86.h:44,
-                 from /home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/work/i586-oe-linux/xf86-video-omapfb/2_0.1.1+gitrAUTOINC+28c006c94e-r21.7/git/src/omapfb-xv-generic.c:28:
-/home/ubuntu/work/upstream/openembedded-core/build/tmp-glibc/sysroots/qemux86/usr/include/xorg/os.h:579:1: error: expected identifier or '(' before '__extension__'
- strndup(const char *str, size_t n);
- ^
-
-Singed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
-Index: git/src/omapfb-xv-blizzard.c
-===================================================================
---- git.orig/src/omapfb-xv-blizzard.c	2014-08-28 05:16:25.684070587 -0700
-+++ git/src/omapfb-xv-blizzard.c	2014-08-28 19:05:39.440070587 -0700
-@@ -30,6 +30,7 @@
-  *  -
-  */
- 
-+#include <xorg-server.h>
- #include "xf86.h"
- #include "xf86_OSlib.h"
- #include "xf86xv.h"
-Index: git/src/omapfb-xv-generic.c
-===================================================================
---- git.orig/src/omapfb-xv-generic.c	2014-08-28 05:16:25.684070587 -0700
-+++ git/src/omapfb-xv-generic.c	2014-08-28 19:05:51.780070587 -0700
-@@ -25,6 +25,7 @@
-  * Generic functions for the XV driver
-  */
- 
-+#include <xorg-server.h>
- #include "xf86.h"
- #include "xf86_OSlib.h"
- #include "xf86xv.h"
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb_git.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb_git.bb
deleted file mode 100644
index 7ebb960..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-omapfb_git.bb
+++ /dev/null
@@ -1,37 +0,0 @@
-require xorg-driver-video.inc
-
-SUMMARY = "X.Org X server -- Texas Instruments OMAP framebuffer driver"
-
-DESCRIPTION = "omapfb driver supports the basic Texas Instruments OMAP \
-framebuffer."
-
-LICENSE = "MIT-X & GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=63e2cbac53863f60e2f43343fb34367f"
-DEPENDS += "virtual/libx11"
-
-SRCREV = "33e36c12dde336edbdd34626dd8adfcaebc8fbb8"
-PR = "${INC_PR}.7"
-PV = "0.1.1+gitr${SRCPV}"
-
-# Blacklist debian-specific tags in upstream version check
-UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+(\.\d+)+)(?!-)"
-
-SRC_URI = "git://anonscm.debian.org/collab-maint/xf86-video-omapfb.git \
-  file://0001-Prevents-omapfb-from-from-crashing-when-pixelclock-o.patch \
-  file://0001-Revert-Set-a-large-CRTC-upper-limit-to-not-prune-lar.patch \
-  file://0002-Revert-Set-virtual-size-when-configuring-framebuffer.patch \
-  file://0003-force-plain-mode.patch \
-  file://0004-blacklist-tv-out.patch \
-  file://0005-Attempt-to-fix-VRFB.patch \
-  file://0006-omapfb-port-to-new-xserver-video-API.patch \
-  file://0007-always_include_xorg_server.h.patch \
-"
-
-S = "${WORKDIR}/git"
-
-CFLAGS += " -I${STAGING_INCDIR}/xorg "
-
-# Use overlay 2 on omap3 to enable other apps to use overlay 1 (e.g. dmai or omapfbplay)
-do_compile_prepend_armv7a () {
-        sed -i -e s:fb1:fb2:g ${S}/src/omapfb-xv.c
-}
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-vesa_2.3.4.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-video-vesa_2.3.4.bb
deleted file mode 100644
index fa251b5..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-vesa_2.3.4.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-require xorg-driver-video.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=a1f0610ebdc6f314a9fa5102a8c5c1b0"
-
-SUMMARY = "X.Org X server -- Generic Vesa video driver"
-
-DESCRIPTION = "vesa is an Xorg driver for generic VESA video cards. It \
-can drive most VESA-compatible video cards, but only makes use of the \
-basic standard VESA core that is common to these cards. The driver \
-supports depths 8, 15 16 and 24."
-
-PR = "${INC_PR}.0"
-
-DEPENDS += "virtual/libx11 randrproto libpciaccess"
-
-COMPATIBLE_HOST = '(i.86|x86_64).*-linux'
-
-RRECOMMENDS_${PN} += "xserver-xorg-module-libint10"
-
-SRC_URI[md5sum] = "a893c37c589f7a31cea929a5d896a0e2"
-SRC_URI[sha256sum] = "7bddf4d879dd6f67088ecb203a31e12334aab980174bd0909930a21f32e251c1"
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-vesa_2.4.0.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-video-vesa_2.4.0.bb
new file mode 100644
index 0000000..9a11014
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-driver/xf86-video-vesa_2.4.0.bb
@@ -0,0 +1,19 @@
+require xorg-driver-video.inc
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=a1f0610ebdc6f314a9fa5102a8c5c1b0"
+
+SUMMARY = "X.Org X server -- Generic Vesa video driver"
+
+DESCRIPTION = "vesa is an Xorg driver for generic VESA video cards. It \
+can drive most VESA-compatible video cards, but only makes use of the \
+basic standard VESA core that is common to these cards. The driver \
+supports depths 8, 15 16 and 24."
+
+DEPENDS += "virtual/libx11 xorgproto libpciaccess"
+
+COMPATIBLE_HOST = '(i.86|x86_64).*-linux'
+
+RRECOMMENDS_${PN} += "xserver-xorg-module-libint10"
+
+SRC_URI[md5sum] = "8134201beaf6f77150c7809c3cc802e6"
+SRC_URI[sha256sum] = "bf443c94d7bf6cd4e248f8a3147f4647be04dc4c80250d9405006263bbdee38c"
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-vmware_13.2.1.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-video-vmware_13.2.1.bb
deleted file mode 100644
index 706d35d..0000000
--- a/poky/meta/recipes-graphics/xorg-driver/xf86-video-vmware_13.2.1.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-require xorg-driver-video.inc
-
-SUMMARY = "X.Org X server -- VMware SVGA display driver"
-
-DESCRIPTION = "vmware is an Xorg driver for VMware virtual video cards."
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=5fcd7d437a959a15fbee8707747c6b53"
-
-DEPENDS += "virtual/libx11 xineramaproto videoproto libpciaccess"
-
-SRC_URI += "file://0002-add-option-for-vmwgfx.patch"
-
-SRC_URI[md5sum] = "4c3912e4d8947f6c2fc1ee9e2f211d74"
-SRC_URI[sha256sum] = "e2f7f7101fba7f53b268e7a25908babbf155b3984fb5268b3d244eb6c11bf62b"
-
-COMPATIBLE_HOST = '(i.86.*-linux|x86_64.*-linux)'
-
-PACKAGECONFIG ?= ""
-PACKAGECONFIG[vmwgfx] = "--enable-vmwgfx, --disable-vmwgfx, libdrm virtual/mesa"
diff --git a/poky/meta/recipes-graphics/xorg-driver/xf86-video-vmware_13.3.0.bb b/poky/meta/recipes-graphics/xorg-driver/xf86-video-vmware_13.3.0.bb
new file mode 100644
index 0000000..41612b7
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-driver/xf86-video-vmware_13.3.0.bb
@@ -0,0 +1,19 @@
+require xorg-driver-video.inc
+
+SUMMARY = "X.Org X server -- VMware SVGA display driver"
+
+DESCRIPTION = "vmware is an Xorg driver for VMware virtual video cards."
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=5fcd7d437a959a15fbee8707747c6b53"
+
+DEPENDS += "virtual/libx11 xorgproto libpciaccess"
+
+SRC_URI += "file://0002-add-option-for-vmwgfx.patch"
+
+SRC_URI[md5sum] = "08d66d062055080ff699ab4869726ea2"
+SRC_URI[sha256sum] = "47971924659e51666a757269ad941a059ef5afe7a47b5101c174a6022ac4066c"
+
+COMPATIBLE_HOST = '(i.86.*-linux|x86_64.*-linux)'
+
+PACKAGECONFIG ?= ""
+PACKAGECONFIG[vmwgfx] = "--enable-vmwgfx, --disable-vmwgfx, libdrm virtual/mesa"
diff --git a/poky/meta/recipes-graphics/xorg-driver/xorg-driver-common.inc b/poky/meta/recipes-graphics/xorg-driver/xorg-driver-common.inc
index bca0aad..e657c65 100644
--- a/poky/meta/recipes-graphics/xorg-driver/xorg-driver-common.inc
+++ b/poky/meta/recipes-graphics/xorg-driver/xorg-driver-common.inc
@@ -7,7 +7,7 @@
 PE = "2"
 INC_PR = "r21"
 
-DEPENDS = "virtual/xserver xproto randrproto util-macros"
+DEPENDS = "virtual/xserver xorgproto util-macros"
 
 SRC_URI = "${XORG_MIRROR}/individual/driver/${BPN}-${PV}.tar.bz2"
 
diff --git a/poky/meta/recipes-graphics/xorg-driver/xorg-driver-input.inc b/poky/meta/recipes-graphics/xorg-driver/xorg-driver-input.inc
index 342067d..57912e7 100644
--- a/poky/meta/recipes-graphics/xorg-driver/xorg-driver-input.inc
+++ b/poky/meta/recipes-graphics/xorg-driver/xorg-driver-input.inc
@@ -1,6 +1,6 @@
 require xorg-driver-common.inc
 
-DEPENDS += "inputproto kbproto "
+DEPENDS += "xorgproto"
 
 python add_xorg_abi_depends() {
     _add_xorg_abi_depends(d, "input")
diff --git a/poky/meta/recipes-graphics/xorg-driver/xorg-driver-video.inc b/poky/meta/recipes-graphics/xorg-driver/xorg-driver-video.inc
index b5862da..2938ef1 100644
--- a/poky/meta/recipes-graphics/xorg-driver/xorg-driver-video.inc
+++ b/poky/meta/recipes-graphics/xorg-driver/xorg-driver-video.inc
@@ -1,6 +1,6 @@
 require xorg-driver-common.inc
 
-DEPENDS =+ "renderproto videoproto xextproto fontsproto"
+DEPENDS =+ "xorgproto"
 
 python add_xorg_abi_depends() {
     _add_xorg_abi_depends(d, "video")
diff --git a/poky/meta/recipes-graphics/xorg-lib/libdmx_1.1.3.bb b/poky/meta/recipes-graphics/xorg-lib/libdmx_1.1.3.bb
deleted file mode 100644
index e623cee..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/libdmx_1.1.3.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-require xorg-lib-common.inc
-
-SUMMARY = "DMX: Distributed Multihead X extension library"
-
-DESCRIPTION = "The DMX extension provides support for communication with \
-and control of Xdmx(1) server. Attributes of the Xdmx(1) server and of \
-the back-end screens attached to the server can be queried and modified \
-via this protocol."
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=a3c3499231a8035efd0e004cfbd3b72a \
-                    file://src/dmx.c;endline=33;md5=c43f19af03c7c8619cadc9724ed9afe1"
-
-DEPENDS += "libxext dmxproto"
-
-PE = "1"
-
-SRC_URI[md5sum] = "ba983eba5a9f05d152a0725b8e863151"
-SRC_URI[sha256sum] = "c97da36d2e56a2d7b6e4f896241785acc95e97eb9557465fd66ba2a155a7b201"
-
diff --git a/poky/meta/recipes-graphics/xorg-lib/libdmx_1.1.4.bb b/poky/meta/recipes-graphics/xorg-lib/libdmx_1.1.4.bb
new file mode 100644
index 0000000..66172cb
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libdmx_1.1.4.bb
@@ -0,0 +1,20 @@
+require xorg-lib-common.inc
+
+SUMMARY = "DMX: Distributed Multihead X extension library"
+
+DESCRIPTION = "The DMX extension provides support for communication with \
+and control of Xdmx(1) server. Attributes of the Xdmx(1) server and of \
+the back-end screens attached to the server can be queried and modified \
+via this protocol."
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=a3c3499231a8035efd0e004cfbd3b72a \
+                    file://src/dmx.c;endline=33;md5=c43f19af03c7c8619cadc9724ed9afe1"
+
+DEPENDS += "libxext xorgproto"
+
+PE = "1"
+
+SRC_URI[md5sum] = "d2f1f0ec68ac3932dd7f1d9aa0a7a11c"
+SRC_URI[sha256sum] = "253f90005d134fa7a209fbcbc5a3024335367c930adf0f3203e754cf32747243"
+
diff --git a/poky/meta/recipes-graphics/xorg-lib/libfontenc_1.1.3.bb b/poky/meta/recipes-graphics/xorg-lib/libfontenc_1.1.3.bb
index a181f05..34d5fc4 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libfontenc_1.1.3.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libfontenc_1.1.3.bb
@@ -8,7 +8,7 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://COPYING;md5=96254c20ab81c63e65b26f0dbcd4a1c1"
 
-DEPENDS += "zlib xproto font-util"
+DEPENDS += "zlib xorgproto font-util"
 PE = "1"
 
 BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libice_1.0.9.bb b/poky/meta/recipes-graphics/xorg-lib/libice_1.0.9.bb
index 5ccd1d8..999434e 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libice_1.0.9.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libice_1.0.9.bb
@@ -11,7 +11,7 @@
 LICENSE = "MIT-style"
 LIC_FILES_CHKSUM = "file://COPYING;md5=d162b1b3c6fa812da9d804dcf8584a93"
 
-DEPENDS += "xproto xtrans"
+DEPENDS += "xorgproto xtrans"
 PROVIDES = "ice"
 
 PE = "1"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libpciaccess_0.14.bb b/poky/meta/recipes-graphics/xorg-lib/libpciaccess_0.14.bb
index a44a5c8..d030c31 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libpciaccess_0.14.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libpciaccess_0.14.bb
@@ -16,3 +16,5 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=277aada5222b9a22fbf3471ff3687068"
 
 REQUIRED_DISTRO_FEATURES = ""
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libsm_1.2.2.bb b/poky/meta/recipes-graphics/xorg-lib/libsm_1.2.2.bb
index 48922cb..fdc693b 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libsm_1.2.2.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libsm_1.2.2.bb
@@ -11,7 +11,7 @@
 LICENSE = "MIT-style"
 LIC_FILES_CHKSUM = "file://COPYING;md5=c0fb37f44e02bdbde80546024400728d"
 
-DEPENDS += "libice xproto xtrans"
+DEPENDS += "libice xorgproto xtrans"
 
 # libSM can work without libuuid, we explicitly disable it to break the following circular dependency
 # when DISTRO_FEATURES contains 'systemd' and 'x11'.
diff --git a/poky/meta/recipes-graphics/xorg-lib/libx11-diet_1.6.5.bb b/poky/meta/recipes-graphics/xorg-lib/libx11-diet_1.6.5.bb
deleted file mode 100644
index 295f96a..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/libx11-diet_1.6.5.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-require libx11.inc
-
-DESCRIPTION += " Support for XCMS and XLOCALE is disabled in \
-this version."
-
-SRC_URI += "file://X18NCMSstubs.diff \
-            file://fix-disable-xlocale.diff \
-            file://fix-utf8-wrong-define.patch \
-           "
-
-RPROVIDES_${PN}-dev = "libx11-dev"
-RPROVIDES_${PN}-locale = "libx11-locale"
-
-SRC_URI[md5sum] = "0f618db70c4054ca67cee0cc156a4255"
-SRC_URI[sha256sum] = "4d3890db2ba225ba8c55ca63c6409c1ebb078a2806de59fb16342768ae63435d"
-
-EXTRA_OECONF += "--disable-xlocale"
-
-PACKAGECONFIG ??= ""
diff --git a/poky/meta/recipes-graphics/xorg-lib/libx11-diet_1.6.6.bb b/poky/meta/recipes-graphics/xorg-lib/libx11-diet_1.6.6.bb
new file mode 100644
index 0000000..a4ba4e5
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libx11-diet_1.6.6.bb
@@ -0,0 +1,19 @@
+require libx11.inc
+
+DESCRIPTION += " Support for XCMS and XLOCALE is disabled in \
+this version."
+
+SRC_URI += "file://X18NCMSstubs.patch \
+            file://fix-disable-xlocale.patch \
+            file://fix-utf8-wrong-define.patch \
+           "
+
+RPROVIDES_${PN}-dev = "libx11-dev"
+RPROVIDES_${PN}-locale = "libx11-locale"
+
+SRC_URI[md5sum] = "6b0f83e851b3b469dd660f3a95ac3e42"
+SRC_URI[sha256sum] = "65fe181d40ec77f45417710c6a67431814ab252d21c2e85c75dd1ed568af414f"
+
+EXTRA_OECONF += "--disable-xlocale"
+
+PACKAGECONFIG ??= ""
diff --git a/poky/meta/recipes-graphics/xorg-lib/libx11.inc b/poky/meta/recipes-graphics/xorg-lib/libx11.inc
index 4af40ab..36c950a 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libx11.inc
+++ b/poky/meta/recipes-graphics/xorg-lib/libx11.inc
@@ -6,8 +6,6 @@
 
 require xorg-lib-common.inc
 
-inherit siteinfo
-
 FILESEXTRAPATHS =. "${FILE_DIRNAME}/libx11:"
 
 PE = "1"
@@ -18,8 +16,8 @@
 LICENSE = "MIT & MIT-style & BSD"
 LIC_FILES_CHKSUM = "file://COPYING;md5=172255dee66bb0151435b2d5d709fcf7"
 
-DEPENDS += "xproto xextproto xtrans libxcb kbproto inputproto"
-DEPENDS += "xproto-native"
+DEPENDS += "xorgproto xtrans libxcb"
+DEPENDS += "xorgproto-native"
 
 EXTRA_OECONF += "--with-keysymdefdir=${STAGING_INCDIR}/X11/ --disable-xf86bigfont"
 EXTRA_OEMAKE += 'CWARNFLAGS=""'
diff --git a/poky/meta/recipes-graphics/xorg-lib/libx11/X18NCMSstubs.diff b/poky/meta/recipes-graphics/xorg-lib/libx11/X18NCMSstubs.diff
deleted file mode 100644
index 744cedc..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/libx11/X18NCMSstubs.diff
+++ /dev/null
@@ -1,520 +0,0 @@
-Upstream-Status: Pending
-
-Upstream-Status: Inappropriate [configuration]
-Index: libX11-1.3/src/imConv.c
-===================================================================
---- libX11-1.3.orig/src/imConv.c
-+++ libX11-1.3/src/imConv.c
-@@ -83,6 +83,7 @@ static const struct SubstRec SubstTable[
-  * from UCS char to specified charset char.
-  * This converter is needed for _XimGetCharCode subroutine.
-  */
-+#ifdef XLOCALE
- XPointer
- _XimGetLocaleCode (
-     _Xconst char*	encoding_name)
-@@ -96,6 +97,7 @@ _XimGetLocaleCode (
-     }
-     return cvt;
- }
-+#endif
- 
- /*
-  * Returns the locale dependent representation of a keysym.
-@@ -106,6 +108,7 @@ _XimGetLocaleCode (
-  * terminating NUL byte. Return 0 if the keysym is not representable in the
-  * locale
-  */
-+#ifdef XLOCALE
- /*ARGSUSED*/
- int
- _XimGetCharCode (
-@@ -135,6 +138,7 @@ _XimGetCharCode (
-         buf[count]= '\0';
-     return count;
- }
-+#endif
- 
- #ifdef XKB
- static int lookup_string(
-Index: libX11-1.3/src/X18NCMSstubs.c
-===================================================================
---- /dev/null
-+++ libX11-1.3/src/X18NCMSstubs.c
-@@ -0,0 +1,428 @@
-+/*
-+ * X18NCMSstubs.c
-+ * - Provides stubs and dummy funcs needed when Xcms and XLocale stuff removed
-+ *
-+ * Copyright © 2003 Matthew Allum
-+ *
-+ * Permission to use, copy, modify, distribute, and sell this software and its
-+ * documentation for any purpose is hereby granted without fee, provided that
-+ * the above copyright notice appear in all copies and that both that
-+ * copyright notice and this permission notice appear in supporting
-+ * documentation, and that the name of Matthew Allum not be used in
-+ * advertising or publicity pertaining to distribution of the software without
-+ * specific, written prior permission.  Keith Packard and Compaq makes no
-+ * representations about the suitability of this software for any purpose.  It
-+ * is provided "as is" without express or implied warranty.
-+ *
-+ * MATTHEW ALLUM DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS 
-+ * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, 
-+ * IN NO EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR
-+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
-+ * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
-+ * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
-+ * PERFORMANCE OF THIS SOFTWARE.
-+ */
-+
-+#include <stdlib.h>
-+#include "Xlibint.h"
-+#include "Xlcint.h"
-+#include <X11/Xlocale.h>
-+#include <X11/Xos.h>
-+#ifdef WIN32
-+#undef close
-+#endif
-+#include <X11/Xutil.h>
-+#include "XlcPubI.h"
-+
-+#include "Xcmsint.h" 		/* for XcmsCCC type  */
-+#include "XlcPubI.h"            /* for XLCd type */
-+#include "config.h"
-+
-+#if ! XLOCALE
-+
-+Bool
-+XSupportsLocale()
-+{
-+  return False; 		
-+}
-+
-+char *
-+XSetLocaleModifiers(
-+    const char *modifiers)
-+{
-+  return NULL;
-+}
-+
-+XLCd
-+_XOpenLC(
-+    char *name)
-+{
-+  return NULL;
-+}
-+
-+XLCd
-+_XlcCurrentLC()
-+{
-+  return NULL;
-+}
-+
-+void
-+_XlcVaToArgList(
-+    va_list var,
-+    int count,
-+    XlcArgList *args_ret)
-+{
-+  return;
-+}
-+
-+void
-+_XlcCountVaList(
-+    va_list var,
-+    int *count_ret)
-+{
-+  return;
-+}
-+
-+void
-+_XCloseLC(
-+    XLCd lcd)
-+{
-+  return;
-+}
-+
-+int
-+_XlcConvert(
-+    XlcConv conv,
-+    XPointer *from,
-+    int *from_left,
-+    XPointer *to,
-+    int *to_left,
-+    XPointer *args,
-+    int num_args)
-+{
-+  return 0;
-+}
-+
-+/* XIM Stubs */
-+
-+XPointer
-+_XimGetLocaleCode ( _Xconst char* encoding_name )
-+{
-+  return NULL;
-+}
-+
-+int
-+_XimGetCharCode (
-+    XPointer            ucs_conv,
-+    KeySym              keysym,
-+    unsigned char*      buf,
-+    int                 nbytes)
-+{
-+  return 0;
-+}
-+
-+/* Xrm Stubs */
-+
-+XrmMethods
-+_XrmInitParseInfo(
-+    XPointer *state)
-+{
-+    return (XrmMethods) NULL;
-+}
-+
-+/* Xwc Stubs */
-+
-+int
-+XwcTextExtents(
-+    XFontSet            font_set,
-+    _Xconst wchar_t    *text,
-+    int                 text_len,
-+    XRectangle         *overall_ink_extents,
-+    XRectangle         *overall_logical_extents)
-+{
-+  return 0;
-+}
-+
-+void 
-+XwcDrawString(Display *display,
-+	      Drawable d,
-+	      XFontSet font_set,
-+	      GC gc,
-+	      int x, int y,
-+	      _Xconst wchar_t *string,
-+	      int num_wchars)
-+{
-+  ;
-+}
-+
-+void
-+XwcDrawText(
-+    Display            *dpy,
-+    Drawable            d,
-+    GC                  gc,
-+    int                 x,
-+    int                 y,
-+    XwcTextItem        *text_items,
-+    int                 nitems)
-+{
-+  ;
-+}
-+
-+void
-+XwcDrawImageString(
-+    Display            *dpy,
-+    Drawable            d,
-+    XFontSet            font_set,
-+    GC                  gc,
-+    int                 x,
-+    int                 y,
-+    _Xconst wchar_t    *text,
-+    int                 text_len)
-+{
-+  ;
-+}
-+
-+int
-+XwcTextEscapement(
-+    XFontSet            font_set,
-+    _Xconst wchar_t    *text,
-+    int                 text_len)
-+{
-+  return 0;
-+}
-+
-+Status
-+XwcTextPerCharExtents(
-+    XFontSet            font_set,
-+    _Xconst wchar_t    *text,
-+    int                 text_len,
-+    XRectangle         *ink_extents_buffer,
-+    XRectangle         *logical_extents_buffer,
-+    int                 buffer_size,
-+    int                *num_chars,
-+    XRectangle         *max_ink_extents,
-+    XRectangle         *max_logical_extents)
-+{
-+  return(XcmsFailure);
-+}
-+
-+int
-+XwcTextPropertyToTextList(
-+    Display *dpy,
-+    const XTextProperty *text_prop,
-+    wchar_t ***list_ret,
-+    int *count_ret)
-+{
-+  return 0;
-+}
-+
-+int
-+XwcTextListToTextProperty(
-+    Display *dpy,
-+    wchar_t **list,
-+    int count,
-+    XICCEncodingStyle style,
-+    XTextProperty *text_prop)
-+{
-+  return 0;
-+}
-+
-+void
-+XwcFreeStringList(wchar_t **list)
-+{
-+  return;
-+}
-+
-+
-+void XmbSetWMProperties (        /* Actually from mbWMProps.c */
-+    Display *dpy,
-+    Window w,
-+    _Xconst char *windowName,
-+    _Xconst char *iconName,
-+    char **argv,
-+    int argc,
-+    XSizeHints *sizeHints,
-+    XWMHints *wmHints,
-+    XClassHint *classHints)
-+{
-+  return;
-+}
-+
-+int
-+XmbTextPropertyToTextList(
-+    Display *dpy,
-+    const XTextProperty *text_prop,
-+    char ***list_ret,
-+    int *count_ret)
-+{
-+  return XLocaleNotSupported;
-+}
-+
-+int
-+XmbTextListToTextProperty(
-+    Display *dpy,
-+    char **list,
-+    int count,
-+    XICCEncodingStyle style,
-+    XTextProperty *text_prop)
-+{
-+  return XLocaleNotSupported;
-+}
-+
-+int
-+XmbTextExtents(
-+    XFontSet        font_set,
-+    _Xconst char   *text,
-+    int             text_len,
-+    XRectangle     *overall_ink_extents,
-+    XRectangle     *overall_logical_extents)
-+{
-+  return 0;
-+}
-+
-+void
-+XmbDrawText(
-+    Display            *dpy,
-+    Drawable            d,
-+    GC                  gc,
-+    int                 x,
-+    int                 y,
-+    XmbTextItem        *text_items,
-+    int                 nitems)
-+{
-+  ;
-+}
-+
-+void
-+XmbDrawString(
-+    Display            *dpy,
-+    Drawable            d,
-+    XFontSet            font_set,
-+    GC                  gc,
-+    int                 x,
-+    int                 y,
-+    _Xconst char       *text,
-+    int                 text_len)
-+{
-+  ;
-+}
-+
-+void
-+XmbDrawImageString(
-+    Display            *dpy,
-+    Drawable            d,
-+    XFontSet            font_set,
-+    GC                  gc,
-+    int                 x,
-+    int                 y,
-+    _Xconst char       *text,
-+    int                 text_len)
-+{
-+  ;
-+}
-+
-+int
-+XmbTextEscapement(
-+    XFontSet        font_set,
-+    _Xconst char   *text,
-+    int             text_len)
-+{
-+  return 0;
-+}
-+
-+Status
-+XmbTextPerCharExtents(
-+    XFontSet        font_set,
-+    _Xconst char   *text,
-+    int             text_len,
-+    XRectangle     *ink_extents_buffer,
-+    XRectangle     *logical_extents_buffer,
-+    int             buffer_size,
-+    int            *num_chars,
-+    XRectangle     *max_ink_extents,
-+    XRectangle     *max_logical_extents)
-+{
-+  return 0;
-+}
-+
-+unsigned int
-+KeySymToUcs4(KeySym keysym)
-+{
-+  return 0;
-+}
-+
-+#endif 
-+
-+#if ! XCMS
-+
-+XcmsCCC 
-+XcmsCCCOfColormap(dpy, cmap)
-+    Display *dpy;
-+    Colormap cmap;
-+{
-+  return NULL;
-+}
-+
-+Status
-+_XcmsResolveColorString (
-+    XcmsCCC ccc,
-+    const char **color_string,
-+    XcmsColor *pColor_exact_return,
-+    XcmsColorFormat result_format)
-+{
-+  return(XcmsFailure);
-+}
-+
-+void
-+_XcmsUnresolveColor(
-+    XcmsCCC ccc,
-+    XcmsColor *pColor)
-+{
-+  return;
-+}
-+
-+void
-+_XUnresolveColor(
-+    XcmsCCC ccc,
-+    XColor *pXColor)
-+{
-+  return;
-+}
-+
-+XcmsCmapRec *
-+_XcmsAddCmapRec(dpy, cmap, windowID, visual)
-+    Display *dpy;
-+    Colormap cmap;
-+    Window windowID;
-+    Visual *visual;
-+{
-+  return NULL;
-+}
-+
-+void
-+_XcmsRGB_to_XColor(
-+    XcmsColor *pColors,
-+    XColor *pXColors,
-+    unsigned int nColors)
-+{
-+  return;
-+}
-+
-+XcmsCmapRec *
-+_XcmsCopyCmapRecAndFree(
-+    Display *dpy,
-+    Colormap src_cmap,
-+    Colormap copy_cmap)
-+{
-+  return NULL;
-+}
-+
-+void
-+_XcmsDeleteCmapRec(
-+    Display *dpy,
-+    Colormap cmap)
-+{
-+  return;
-+}
-+
-+#endif
-Index: libX11-1.3/src/Makefile.am
-===================================================================
---- libX11-1.3.orig/src/Makefile.am
-+++ libX11-1.3/src/Makefile.am
-@@ -335,6 +335,8 @@ if THRSTUBS
- libX11_la_SOURCES+=UIThrStubs.c
- endif
- 
-+libX11_la_SOURCES+=X18NCMSstubs.c
-+
- x11datadir = @X11_DATADIR@
- x11data_DATA = XKeysymDB XErrorDB
- 
-@@ -342,6 +344,7 @@ EXTRA_DIST = \
- 	$(x11data_DATA) \
- 	os2Stubs.c \
--	UIThrStubs.c 
-+	UIThrStubs.c \
-+	X18NCMSstubs.c
- 
- if XCB
- libX11_la_SOURCES += \
-Index: libX11-1.3/src/locking.c
-===================================================================
---- libX11-1.3.orig/src/locking.c
-+++ libX11-1.3/src/locking.c
-@@ -66,7 +66,9 @@ in this Software without prior written a
- #define NUM_FREE_CVLS 4
- 
- /* in lcWrap.c */
-+#ifdef XLOCALE
- extern LockInfoPtr _Xi18n_lock;
-+#endif
- 
- #ifdef WIN32
- static DWORD _X_TlsIndex = (DWORD)-1;
-@@ -594,9 +596,11 @@ Status XInitThreads(void)
-     _Xglobal_lock = &global_lock;
-     xmutex_init(_Xglobal_lock->lock);
-     xmutex_set_name(_Xglobal_lock->lock, "Xlib global");
-+#ifdef XLOCALE
-     _Xi18n_lock = &i18n_lock;
-     xmutex_init(_Xi18n_lock->lock);
-     xmutex_set_name(_Xi18n_lock->lock, "Xlib i18n");
-+#endif
-     _XLockMutex_fn = _XLockMutex;
-     _XUnlockMutex_fn = _XUnlockMutex;
-     _XCreateMutex_fn = _XCreateMutex;
diff --git a/poky/meta/recipes-graphics/xorg-lib/libx11/X18NCMSstubs.patch b/poky/meta/recipes-graphics/xorg-lib/libx11/X18NCMSstubs.patch
new file mode 100644
index 0000000..c117214
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libx11/X18NCMSstubs.patch
@@ -0,0 +1,536 @@
+From 62005ad019d6afb81da100b3113292a16472d241 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Mon, 10 Sep 2018 09:08:27 +0800
+Subject: [PATCH] Stub out x18n
+
+Update patch to version 1.6.6
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+Upstream-Status: Inappropriate [configuration]
+---
+ src/Makefile.am    |   5 +-
+ src/X18NCMSstubs.c | 426 +++++++++++++++++++++++++++++++++++++++++++++++++++++
+ src/imConv.c       |   5 +-
+ src/locking.c      |   4 +
+ 4 files changed, 438 insertions(+), 2 deletions(-)
+ create mode 100644 src/X18NCMSstubs.c
+
+diff --git a/src/Makefile.am b/src/Makefile.am
+index f8c476d..cdbcbbd 100644
+--- a/src/Makefile.am
++++ b/src/Makefile.am
+@@ -336,13 +336,16 @@ if THRSTUBS
+ libX11_la_SOURCES+=UIThrStubs.c
+ endif
+ 
++libX11_la_SOURCES+=X18NCMSstubs.c
++
+ x11datadir = @X11_DATADIR@
+ x11data_DATA = XErrorDB
+ 
+ EXTRA_DIST = \
+ 	$(x11data_DATA) \
+ 	os2Stubs.c \
+-	UIThrStubs.c 
++	UIThrStubs.c \
++	X18NCMSstubs.c
+ 
+ libX11_xcb_la_SOURCES = x11_xcb.c Xxcbint.h
+ libX11_xcb_la_LDFLAGS = -version-number 1:0:0 -no-undefined
+diff --git a/src/X18NCMSstubs.c b/src/X18NCMSstubs.c
+new file mode 100644
+index 0000000..429cb31
+--- /dev/null
++++ b/src/X18NCMSstubs.c
+@@ -0,0 +1,426 @@
++ /* - Provides stubs and dummy funcs needed when Xcms and XLocale stuff removed
++ *
++ * Copyright © 2003 Matthew Allum
++ *
++ * Permission to use, copy, modify, distribute, and sell this software and its
++ * documentation for any purpose is hereby granted without fee, provided that
++ * the above copyright notice appear in all copies and that both that
++ * copyright notice and this permission notice appear in supporting
++ * documentation, and that the name of Matthew Allum not be used in
++ * advertising or publicity pertaining to distribution of the software without
++ * specific, written prior permission.  Keith Packard and Compaq makes no
++ * representations about the suitability of this software for any purpose.  It
++ * is provided "as is" without express or implied warranty.
++ *
++ * MATTHEW ALLUM DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS 
++ * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, 
++ * IN NO EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR
++ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
++ * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
++ * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
++ * PERFORMANCE OF THIS SOFTWARE.
++ */
++
++#include <stdlib.h>
++#include "Xlibint.h"
++#include "Xlcint.h"
++#include <X11/Xlocale.h>
++#include <X11/Xos.h>
++#ifdef WIN32
++#undef close
++#endif
++#include <X11/Xutil.h>
++#include "XlcPubI.h"
++
++#include "Xcmsint.h" 		/* for XcmsCCC type  */
++#include "XlcPubI.h"            /* for XLCd type */
++#include "config.h"
++
++#if ! XLOCALE
++
++Bool
++XSupportsLocale()
++{
++  return False; 		
++}
++
++char *
++XSetLocaleModifiers(
++    const char *modifiers)
++{
++  return NULL;
++}
++
++XLCd
++_XOpenLC(
++    char *name)
++{
++  return NULL;
++}
++
++XLCd
++_XlcCurrentLC()
++{
++  return NULL;
++}
++
++void
++_XlcVaToArgList(
++    va_list var,
++    int count,
++    XlcArgList *args_ret)
++{
++  return;
++}
++
++void
++_XlcCountVaList(
++    va_list var,
++    int *count_ret)
++{
++  return;
++}
++
++void
++_XCloseLC(
++    XLCd lcd)
++{
++  return;
++}
++
++int
++_XlcConvert(
++    XlcConv conv,
++    XPointer *from,
++    int *from_left,
++    XPointer *to,
++    int *to_left,
++    XPointer *args,
++    int num_args)
++{
++  return 0;
++}
++
++/* XIM Stubs */
++
++XPointer
++_XimGetLocaleCode ( _Xconst char* encoding_name )
++{
++  return NULL;
++}
++
++int
++_XimGetCharCode (
++    XPointer            ucs_conv,
++    KeySym              keysym,
++    unsigned char*      buf,
++    int                 nbytes)
++{
++  return 0;
++}
++
++/* Xrm Stubs */
++
++XrmMethods
++_XrmInitParseInfo(
++    XPointer *state)
++{
++    return (XrmMethods) NULL;
++}
++
++/* Xwc Stubs */
++
++int
++XwcTextExtents(
++    XFontSet            font_set,
++    _Xconst wchar_t    *text,
++    int                 text_len,
++    XRectangle         *overall_ink_extents,
++    XRectangle         *overall_logical_extents)
++{
++  return 0;
++}
++
++void 
++XwcDrawString(Display *display,
++	      Drawable d,
++	      XFontSet font_set,
++	      GC gc,
++	      int x, int y,
++	      _Xconst wchar_t *string,
++	      int num_wchars)
++{
++  ;
++}
++
++void
++XwcDrawText(
++    Display            *dpy,
++    Drawable            d,
++    GC                  gc,
++    int                 x,
++    int                 y,
++    XwcTextItem        *text_items,
++    int                 nitems)
++{
++  ;
++}
++
++void
++XwcDrawImageString(
++    Display            *dpy,
++    Drawable            d,
++    XFontSet            font_set,
++    GC                  gc,
++    int                 x,
++    int                 y,
++    _Xconst wchar_t    *text,
++    int                 text_len)
++{
++  ;
++}
++
++int
++XwcTextEscapement(
++    XFontSet            font_set,
++    _Xconst wchar_t    *text,
++    int                 text_len)
++{
++  return 0;
++}
++
++Status
++XwcTextPerCharExtents(
++    XFontSet            font_set,
++    _Xconst wchar_t    *text,
++    int                 text_len,
++    XRectangle         *ink_extents_buffer,
++    XRectangle         *logical_extents_buffer,
++    int                 buffer_size,
++    int                *num_chars,
++    XRectangle         *max_ink_extents,
++    XRectangle         *max_logical_extents)
++{
++  return(XcmsFailure);
++}
++
++int
++XwcTextPropertyToTextList(
++    Display *dpy,
++    const XTextProperty *text_prop,
++    wchar_t ***list_ret,
++    int *count_ret)
++{
++  return 0;
++}
++
++int
++XwcTextListToTextProperty(
++    Display *dpy,
++    wchar_t **list,
++    int count,
++    XICCEncodingStyle style,
++    XTextProperty *text_prop)
++{
++  return 0;
++}
++
++void
++XwcFreeStringList(wchar_t **list)
++{
++  return;
++}
++
++
++void XmbSetWMProperties (        /* Actually from mbWMProps.c */
++    Display *dpy,
++    Window w,
++    _Xconst char *windowName,
++    _Xconst char *iconName,
++    char **argv,
++    int argc,
++    XSizeHints *sizeHints,
++    XWMHints *wmHints,
++    XClassHint *classHints)
++{
++  return;
++}
++
++int
++XmbTextPropertyToTextList(
++    Display *dpy,
++    const XTextProperty *text_prop,
++    char ***list_ret,
++    int *count_ret)
++{
++  return XLocaleNotSupported;
++}
++
++int
++XmbTextListToTextProperty(
++    Display *dpy,
++    char **list,
++    int count,
++    XICCEncodingStyle style,
++    XTextProperty *text_prop)
++{
++  return XLocaleNotSupported;
++}
++
++int
++XmbTextExtents(
++    XFontSet        font_set,
++    _Xconst char   *text,
++    int             text_len,
++    XRectangle     *overall_ink_extents,
++    XRectangle     *overall_logical_extents)
++{
++  return 0;
++}
++
++void
++XmbDrawText(
++    Display            *dpy,
++    Drawable            d,
++    GC                  gc,
++    int                 x,
++    int                 y,
++    XmbTextItem        *text_items,
++    int                 nitems)
++{
++  ;
++}
++
++void
++XmbDrawString(
++    Display            *dpy,
++    Drawable            d,
++    XFontSet            font_set,
++    GC                  gc,
++    int                 x,
++    int                 y,
++    _Xconst char       *text,
++    int                 text_len)
++{
++  ;
++}
++
++void
++XmbDrawImageString(
++    Display            *dpy,
++    Drawable            d,
++    XFontSet            font_set,
++    GC                  gc,
++    int                 x,
++    int                 y,
++    _Xconst char       *text,
++    int                 text_len)
++{
++  ;
++}
++
++int
++XmbTextEscapement(
++    XFontSet        font_set,
++    _Xconst char   *text,
++    int             text_len)
++{
++  return 0;
++}
++
++Status
++XmbTextPerCharExtents(
++    XFontSet        font_set,
++    _Xconst char   *text,
++    int             text_len,
++    XRectangle     *ink_extents_buffer,
++    XRectangle     *logical_extents_buffer,
++    int             buffer_size,
++    int            *num_chars,
++    XRectangle     *max_ink_extents,
++    XRectangle     *max_logical_extents)
++{
++  return 0;
++}
++
++unsigned int
++KeySymToUcs4(KeySym keysym)
++{
++  return 0;
++}
++
++#endif 
++
++#if ! XCMS
++
++XcmsCCC 
++XcmsCCCOfColormap(dpy, cmap)
++    Display *dpy;
++    Colormap cmap;
++{
++  return NULL;
++}
++
++Status
++_XcmsResolveColorString (
++    XcmsCCC ccc,
++    const char **color_string,
++    XcmsColor *pColor_exact_return,
++    XcmsColorFormat result_format)
++{
++  return(XcmsFailure);
++}
++
++void
++_XcmsUnresolveColor(
++    XcmsCCC ccc,
++    XcmsColor *pColor)
++{
++  return;
++}
++
++void
++_XUnresolveColor(
++    XcmsCCC ccc,
++    XColor *pXColor)
++{
++  return;
++}
++
++XcmsCmapRec *
++_XcmsAddCmapRec(dpy, cmap, windowID, visual)
++    Display *dpy;
++    Colormap cmap;
++    Window windowID;
++    Visual *visual;
++{
++  return NULL;
++}
++
++void
++_XcmsRGB_to_XColor(
++    XcmsColor *pColors,
++    XColor *pXColors,
++    unsigned int nColors)
++{
++  return;
++}
++
++XcmsCmapRec *
++_XcmsCopyCmapRecAndFree(
++    Display *dpy,
++    Colormap src_cmap,
++    Colormap copy_cmap)
++{
++  return NULL;
++}
++
++void
++_XcmsDeleteCmapRec(
++    Display *dpy,
++    Colormap cmap)
++{
++  return;
++}
++
++#endif
+diff --git a/src/imConv.c b/src/imConv.c
+index c3c1974..04ecc81 100644
+--- a/src/imConv.c
++++ b/src/imConv.c
+@@ -80,6 +80,7 @@ static const struct SubstRec SubstTable[] = {
+  * from UCS char to specified charset char.
+  * This converter is needed for _XimGetCharCode subroutine.
+  */
++#ifdef XLOCALE
+ XPointer
+ _XimGetLocaleCode (
+     _Xconst char*	encoding_name)
+@@ -93,7 +94,7 @@ _XimGetLocaleCode (
+     }
+     return cvt;
+ }
+-
++#endif
+ /*
+  * Returns the locale dependent representation of a keysym.
+  * The locale's encoding is passed in form of pointer to UCS convertor.
+@@ -105,6 +105,7 @@ _XimGetLocaleCode (
+  * locale
+  */
+ /*ARGSUSED*/
++#ifdef XLOCALE
+ int
+ _XimGetCharCode (
+     XPointer            ucs_conv,
+@@ -133,6 +134,7 @@ _XimGetCharCode (
+         buf[count]= '\0';
+     return count;
+ }
++#endif
+
+ #ifdef XKB
+ static int lookup_string(
+diff --git a/src/locking.c b/src/locking.c
+index 9f4fe06..e6967ee 100644
+--- a/src/locking.c
++++ b/src/locking.c
+@@ -65,7 +65,9 @@ in this Software without prior written authorization from The Open Group.
+ #define NUM_FREE_CVLS 4
+ 
+ /* in lcWrap.c */
++#ifdef XLOCALE
+ extern LockInfoPtr _Xi18n_lock;
++#endif
+ 
+ #ifdef WIN32
+ static DWORD _X_TlsIndex = (DWORD)-1;
+@@ -597,9 +599,11 @@ Status XInitThreads(void)
+     _Xglobal_lock = &global_lock;
+     xmutex_init(_Xglobal_lock->lock);
+     xmutex_set_name(_Xglobal_lock->lock, "Xlib global");
++#ifdef XLOCALE
+     _Xi18n_lock = &i18n_lock;
+     xmutex_init(_Xi18n_lock->lock);
+     xmutex_set_name(_Xi18n_lock->lock, "Xlib i18n");
++#endif
+     _XLockMutex_fn = _XLockMutex;
+     _XUnlockMutex_fn = _XUnlockMutex;
+     _XCreateMutex_fn = _XCreateMutex;
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-graphics/xorg-lib/libx11/fix-disable-xlocale.diff b/poky/meta/recipes-graphics/xorg-lib/libx11/fix-disable-xlocale.diff
deleted file mode 100644
index a7c3984..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/libx11/fix-disable-xlocale.diff
+++ /dev/null
@@ -1,17 +0,0 @@
-Upstream-Status: Pending
-
-Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
---- libX11-X11R7.0-1.0.0/src/Font.c.orig	2006-03-12 18:35:42.000000000 +0100
-+++ libX11-X11R7.0-1.0.0/src/Font.c	2006-03-12 18:40:27.000000000 +0100
-@@ -701,7 +701,11 @@
-     }
-     if (l - 2 - (p - charset) < 0)
- 	return 0;
-+#ifdef XLOCALE
-     if (_XlcNCompareISOLatin1(name + l - 2 - (p - charset), charset, p - charset))
-+#else
-+    if (strncasecmp(name + l - 2 - (p - charset), charset, p - charset))
-+#endif
- 	return 0;
-     if (strlen(p + 1) + l - 1 >= sizeof(buf) - 1)
- 	return 0;
diff --git a/poky/meta/recipes-graphics/xorg-lib/libx11/fix-disable-xlocale.patch b/poky/meta/recipes-graphics/xorg-lib/libx11/fix-disable-xlocale.patch
new file mode 100644
index 0000000..09cf74f
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libx11/fix-disable-xlocale.patch
@@ -0,0 +1,33 @@
+From 5c1693028ef12ab767d7cdbc349c27efa1ada87a Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Mon, 10 Sep 2018 09:13:38 +0800
+Subject: [PATCH] Fix build when xlocale disabled
+
+Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
+
+Update patch to version 1.6.6
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+Upstream-Status: Pending
+---
+ src/Font.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/src/Font.c b/src/Font.c
+index a73f9b1..8f4d210 100644
+--- a/src/Font.c
++++ b/src/Font.c
+@@ -675,7 +675,11 @@ int _XF86LoadQueryLocaleFont(
+     }
+     if (l - 2 - (p - charset) < 0)
+ 	return 0;
++#ifdef XLOCALE
+     if (_XlcNCompareISOLatin1(name + l - 2 - (p - charset), charset, p - charset))
++#else
++    if (strncasecmp(name + l - 2 - (p - charset), charset, p - charset))
++#endif
+ 	return 0;
+     if (strlen(p + 1) + l - 1 >= sizeof(buf) - 1)
+ 	return 0;
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-graphics/xorg-lib/libx11/fix-utf8-wrong-define.patch b/poky/meta/recipes-graphics/xorg-lib/libx11/fix-utf8-wrong-define.patch
index c6347f5..0b57e0b 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libx11/fix-utf8-wrong-define.patch
+++ b/poky/meta/recipes-graphics/xorg-lib/libx11/fix-utf8-wrong-define.patch
@@ -1,19 +1,31 @@
-Upstream-Status: Pending
+From 046703373055c7029c19d171e415ff3caaa87372 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Mon, 10 Sep 2018 09:16:33 +0800
+Subject: [PATCH] Disable unicode
 
 Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
 
-#
-# Patch managed by http://www.holgerschurig.de/patcher.html
-#
+Update patch to version 1.6.6
 
---- libX11-X11R7.0-1.0.0/include/X11/Xlib.h~fix-utf8-wrong-define
-+++ libX11-X11R7.0-1.0.0/include/X11/Xlib.h
-@@ -103,7 +103,7 @@
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+Upstream-Status: Pending
+---
+ include/X11/Xlib.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/include/X11/Xlib.h b/include/X11/Xlib.h
+index 84403f7..56be654 100644
+--- a/include/X11/Xlib.h
++++ b/include/X11/Xlib.h
+@@ -67,7 +67,7 @@ _Xmblen(
  
  /* API mentioning "UTF8" or "utf8" is an XFree86 extension, introduced in
     November 2000. Its presence is indicated through the following macro. */
 -#define X_HAVE_UTF8_STRING 1
 +#undef X_HAVE_UTF8_STRING
  
- typedef char *XPointer;
- 
+ /* The Xlib structs are full of implicit padding to properly align members.
+    We can't clean that up without breaking ABI, so tell clang not to bother
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-graphics/xorg-lib/libx11_1.6.5.bb b/poky/meta/recipes-graphics/xorg-lib/libx11_1.6.5.bb
deleted file mode 100644
index 427bf28..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/libx11_1.6.5.bb
+++ /dev/null
@@ -1,14 +0,0 @@
-require libx11.inc
-inherit gettext
-
-BBCLASSEXTEND = "native nativesdk"
-
-SRC_URI += "file://disable_tests.patch \
-            file://Fix-hanging-issue-in-_XReply.patch \
-           "
-do_configure_append () {
-    sed -i -e "/X11_CFLAGS/d" ${B}/src/util/Makefile
-}
-
-SRC_URI[md5sum] = "0f618db70c4054ca67cee0cc156a4255"
-SRC_URI[sha256sum] = "4d3890db2ba225ba8c55ca63c6409c1ebb078a2806de59fb16342768ae63435d"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libx11_1.6.6.bb b/poky/meta/recipes-graphics/xorg-lib/libx11_1.6.6.bb
new file mode 100644
index 0000000..0fee1a9
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libx11_1.6.6.bb
@@ -0,0 +1,14 @@
+require libx11.inc
+inherit gettext
+
+BBCLASSEXTEND = "native nativesdk"
+
+SRC_URI += "file://disable_tests.patch \
+            file://Fix-hanging-issue-in-_XReply.patch \
+           "
+do_configure_append () {
+    sed -i -e "/X11_CFLAGS/d" ${B}/src/util/Makefile
+}
+
+SRC_URI[md5sum] = "6b0f83e851b3b469dd660f3a95ac3e42"
+SRC_URI[sha256sum] = "65fe181d40ec77f45417710c6a67431814ab252d21c2e85c75dd1ed568af414f"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxau_1.0.8.bb b/poky/meta/recipes-graphics/xorg-lib/libxau_1.0.8.bb
index 2ef8bfa..8c52475 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxau_1.0.8.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxau_1.0.8.bb
@@ -11,7 +11,7 @@
 LICENSE = "MIT-style"
 LIC_FILES_CHKSUM = "file://COPYING;md5=7908e342491198401321cec1956807ec"
 
-DEPENDS += " xproto"
+DEPENDS += " xorgproto"
 PROVIDES = "xau"
 
 PE = "1"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxcalibrate/fix-xcb.patch b/poky/meta/recipes-graphics/xorg-lib/libxcalibrate/fix-xcb.patch
deleted file mode 100644
index d614883..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/libxcalibrate/fix-xcb.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-Upstream-Status: Pending
-
-There is no extra reply data and if we say not to disgard it, xcb
-throws fatal asserts.
-
-RP - 26/11/09
-
-Index: git/xcalibrate.c
-===================================================================
---- git.orig/xcalibrate.c	2009-11-26 08:11:48.000000000 +0000
-+++ git/xcalibrate.c	2009-11-26 08:09:55.000000000 +0000
-@@ -216,7 +216,7 @@
-   req->reqType = info->codes->major_opcode;
-   req->xCalibrateReqType = X_XCalibrateRawMode;
-   req->on = enable;
--  if (!_XReply (dpy, (xReply *) &rep, 0, xFalse)) 
-+  if (!_XReply (dpy, (xReply *) &rep, 0, xTrue)) 
-     {
-       UnlockDisplay (dpy);
-       SyncHandle ();
-@@ -240,7 +240,7 @@
-   req->xCalibrateReqType = X_XCalibrateScreenToCoord;
-   req->x = *x;
-   req->y = *y;
--  if (!_XReply (dpy, (xReply *) &rep, 0, xFalse)) 
-+  if (!_XReply (dpy, (xReply *) &rep, 0, xTrue)) 
-     {
-       UnlockDisplay (dpy);
-       SyncHandle ();
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxcalibrate_git.bb b/poky/meta/recipes-graphics/xorg-lib/libxcalibrate_git.bb
deleted file mode 100644
index 0fe6531..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/libxcalibrate_git.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-SUMMARY = "XCalibrate: Touchscreen calibration library"
-
-DESCRIPTION = "libXCalibrate is a library for performing touchscreen \
-calibration with the kdrive tslib touchscreen driver."
-
-require xorg-lib-common.inc
-
-LICENSE = "MIT-style"
-LIC_FILES_CHKSUM = "file://xcalibrate.h;endline=21;md5=fa572df6439f0f235f2612f370f153d7 \
-                    file://xcalibrate.c;endline=21;md5=fa572df6439f0f235f2612f370f153d7"
-
-DEPENDS = "virtual/libx11 calibrateproto libxext"
-
-SRCREV = "209d83af61ed38a002c8096377deac292b3e396c"
-PV = "0.0+git${SRCPV}"
-
-SRC_URI = "git://anongit.freedesktop.org/git/xorg/lib/libXCalibrate \
-           file://fix-xcb.patch"
-UPSTREAM_CHECK_COMMITS = "1"
-
-S = "${WORKDIR}/git"
-
-FILES_${PN}-locale += "${datadir}/X11/locale"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxcb/Fix-inconsistent-use-of-tabs-vs.-space.patch b/poky/meta/recipes-graphics/xorg-lib/libxcb/Fix-inconsistent-use-of-tabs-vs.-space.patch
deleted file mode 100644
index 8992386..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/libxcb/Fix-inconsistent-use-of-tabs-vs.-space.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-From 8740a288ca468433141341347aa115b9544891d3 Mon Sep 17 00:00:00 2001
-From: Thomas Klausner <wiz@NetBSD.org>
-Date: Thu, 19 May 2016 17:31:18 +0200
-Subject: [PATCH] Fix inconsistent use of tabs vs. space.
-
-Needed for at least python-3.5.x.
-
-Signed-off-by: Thomas Klausner <wiz@NetBSD.org>
-Signed-off-by: Uli Schlachter <psychon@znc.in>
-
-Upstream-Status: Backport
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
----
- src/c_client.py | 14 +++++++-------
- 1 file changed, 7 insertions(+), 7 deletions(-)
-
-diff --git a/src/c_client.py b/src/c_client.py
-index 57de3fb..043338d 100644
---- a/src/c_client.py
-+++ b/src/c_client.py
-@@ -1364,7 +1364,7 @@ def _c_serialize(context, self):
-             _c('    unsigned int xcb_align_to = 0;')
-         if self.is_switch:
-             _c('    unsigned int xcb_padding_offset = %d;',
--	       self.get_align_offset() )
-+               self.get_align_offset() )
-         prefix = [('_aux', '->', self)]
-         aux_ptr = 'xcb_out'
- 
-@@ -1390,7 +1390,7 @@ def _c_serialize(context, self):
-         _c('    unsigned int xcb_align_to = 0;')
-         if self.is_switch:
-             _c('    unsigned int xcb_padding_offset = %d;',
--	       self.get_align_offset() )
-+               self.get_align_offset() )
- 
-     elif 'sizeof' == context:
-         param_names = [p[2] for p in params]
-@@ -1930,14 +1930,14 @@ def _c_accessors_list(self, field):
-                     # from the request size and divide that by the member size
-                     return '(((R->length * 4) - sizeof('+ self.c_type + '))/'+'sizeof('+field.type.member.c_wiretype+'))'
-                 else:
--		    # use the accessor to get the start of the list, then
--		    # compute the length of it by subtracting it from
-+                    # use the accessor to get the start of the list, then
-+                    # compute the length of it by subtracting it from
-                     # the adress of the first byte after the end of the
-                     # request
--		    after_end_of_request = '(((char*)R) + R->length * 4)'
--		    start_of_list = '%s(R)' % (field.c_accessor_name)
-+                    after_end_of_request = '(((char*)R) + R->length * 4)'
-+                    start_of_list = '%s(R)' % (field.c_accessor_name)
-                     bytesize_of_list = '%s - (char*)(%s)' % (after_end_of_request, start_of_list)
--		    return '(%s) / sizeof(%s)' % (bytesize_of_list, field.type.member.c_wiretype)
-+                    return '(%s) / sizeof(%s)' % (bytesize_of_list, field.type.member.c_wiretype)
-             else:
-                 raise Exception(
-                     "lengthless lists with varsized members are not supported. Fieldname '%s'"
--- 
-2.9.0
-
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxcb_1.12.bb b/poky/meta/recipes-graphics/xorg-lib/libxcb_1.12.bb
deleted file mode 100644
index a38bdea..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/libxcb_1.12.bb
+++ /dev/null
@@ -1,39 +0,0 @@
-SUMMARY = "XCB: The X protocol C binding library"
-DESCRIPTION = "The X protocol C-language Binding (XCB) is a replacement \
-for Xlib featuring a small footprint, latency hiding, direct access to \
-the protocol, improved threading support, and extensibility."
-HOMEPAGE = "http://xcb.freedesktop.org"
-BUGTRACKER = "https://bugs.freedesktop.org/enter_bug.cgi?product=XCB"
-SECTION = "x11/libs"
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d763b081cb10c223435b01e00dc0aba7"
-
-SRC_URI = "http://xcb.freedesktop.org/dist/libxcb-${PV}.tar.bz2 \
-           file://xcbincludedir.patch \
-           file://disable-check.patch \
-           file://gcc-mips-pr68302-mips-workaround.patch \
-           file://Fix-inconsistent-use-of-tabs-vs.-space.patch \
-          "
-SRC_URI[md5sum] = "28e552bd78bc1050b6b26ca1db0e5bb6"
-SRC_URI[sha256sum] = "4adfb1b7c67e99bc9c2ccb110b2f175686576d2f792c8a71b9c8b19014057b5b"
-
-BBCLASSEXTEND = "native nativesdk"
-
-DEPENDS = "xcb-proto xproto libxau libpthread-stubs libxdmcp"
-
-PACKAGES_DYNAMIC = "^libxcb-.*"
-
-FILES_${PN} = "${libdir}/libxcb.so.*"
-
-inherit autotools pkgconfig distro_features_check
-
-# The libxau and others requires x11 in DISTRO_FEATURES
-REQUIRED_DISTRO_FEATURES = "x11"
-REQUIRED_DISTRO_FEATURES_class-native = ""
-
-export PYTHON = "python3"
-
-python populate_packages_prepend () {
-    do_split_packages(d, '${libdir}', '^libxcb-(.*)\.so\..*$', 'libxcb-%s', 'XCB library module for %s', allow_links=True)
-}
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxcb_1.13.bb b/poky/meta/recipes-graphics/xorg-lib/libxcb_1.13.bb
new file mode 100644
index 0000000..a8e0307
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libxcb_1.13.bb
@@ -0,0 +1,39 @@
+SUMMARY = "XCB: The X protocol C binding library"
+DESCRIPTION = "The X protocol C-language Binding (XCB) is a replacement \
+for Xlib featuring a small footprint, latency hiding, direct access to \
+the protocol, improved threading support, and extensibility."
+HOMEPAGE = "http://xcb.freedesktop.org"
+BUGTRACKER = "https://bugs.freedesktop.org/enter_bug.cgi?product=XCB"
+SECTION = "x11/libs"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d763b081cb10c223435b01e00dc0aba7"
+
+SRC_URI = "http://xcb.freedesktop.org/dist/libxcb-${PV}.tar.bz2 \
+           file://xcbincludedir.patch \
+           file://disable-check.patch \
+           file://gcc-mips-pr68302-mips-workaround.patch \
+          "
+
+SRC_URI[md5sum] = "c2b6cf928afa16b0047c974e7aaa783f"
+SRC_URI[sha256sum] = "188c8752193c50ff2dbe89db4554c63df2e26a2e47b0fa415a70918b5b851daa"
+
+BBCLASSEXTEND = "native nativesdk"
+
+DEPENDS = "xcb-proto xorgproto libxau libpthread-stubs libxdmcp"
+
+PACKAGES_DYNAMIC = "^libxcb-.*"
+
+FILES_${PN} = "${libdir}/libxcb.so.*"
+
+inherit autotools pkgconfig distro_features_check
+
+# The libxau and others requires x11 in DISTRO_FEATURES
+REQUIRED_DISTRO_FEATURES = "x11"
+REQUIRED_DISTRO_FEATURES_class-native = ""
+
+export PYTHON = "python3"
+
+python populate_packages_prepend () {
+    do_split_packages(d, '${libdir}', '^libxcb-(.*)\.so\..*$', 'libxcb-%s', 'XCB library module for %s', allow_links=True)
+}
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxcomposite_0.4.4.bb b/poky/meta/recipes-graphics/xorg-lib/libxcomposite_0.4.4.bb
index 7025719..73e2948 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxcomposite_0.4.4.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxcomposite_0.4.4.bb
@@ -14,7 +14,7 @@
 LICENSE = "MIT-style"
 LIC_FILES_CHKSUM = "file://COPYING;md5=3f2907aad541f6f226fbc58cc1b3cdf1"
 
-DEPENDS += " compositeproto virtual/libx11 libxfixes libxext"
+DEPENDS += " xorgproto virtual/libx11 libxfixes libxext"
 PROVIDES = "xcomposite"
 BBCLASSEXTEND = "native"
 
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxdamage_1.1.4.bb b/poky/meta/recipes-graphics/xorg-lib/libxdamage_1.1.4.bb
index c3d7004..6d6ffad 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxdamage_1.1.4.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxdamage_1.1.4.bb
@@ -16,7 +16,7 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://COPYING;md5=9fe101f30dd24134cf43146863241868"
 
-DEPENDS += "virtual/libx11 damageproto libxfixes"
+DEPENDS += "virtual/libx11 xorgproto libxfixes"
 PROVIDES = "xdamage"
 BBCLASSEXTEND = "native"
 
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxdmcp_1.1.2.bb b/poky/meta/recipes-graphics/xorg-lib/libxdmcp_1.1.2.bb
index f4e30d9..466f349 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxdmcp_1.1.2.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxdmcp_1.1.2.bb
@@ -13,7 +13,7 @@
 LICENSE = "MIT-style"
 LIC_FILES_CHKSUM = "file://COPYING;md5=d559fb26e129626022e052a5e6e0e123"
 
-DEPENDS += "xproto"
+DEPENDS += "xorgproto"
 PROVIDES = "xdmcp"
 
 PE = "1"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxext_1.3.3.bb b/poky/meta/recipes-graphics/xorg-lib/libxext_1.3.3.bb
index 063e531..aae8f2a 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxext_1.3.3.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxext_1.3.3.bb
@@ -13,7 +13,7 @@
 LICENSE = "MIT-style"
 LIC_FILES_CHKSUM = "file://COPYING;md5=879ce266785414bd1cbc3bc2f4d9d7c8"
 
-DEPENDS += "xproto virtual/libx11 xextproto"
+DEPENDS += "xorgproto virtual/libx11"
 PROVIDES = "xext"
 
 PE = "1"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxfixes_5.0.3.bb b/poky/meta/recipes-graphics/xorg-lib/libxfixes_5.0.3.bb
index c80042d..f0e2f60 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxfixes_5.0.3.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxfixes_5.0.3.bb
@@ -10,7 +10,7 @@
 LICENSE = "MIT-style"
 LIC_FILES_CHKSUM = "file://COPYING;md5=3c1ce42c334a6f5cccb0277556a053e0"
 
-DEPENDS += "virtual/libx11 xproto fixesproto xextproto"
+DEPENDS += "virtual/libx11 xorgproto"
 
 PE = "1"
 
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxfont2_2.0.3.bb b/poky/meta/recipes-graphics/xorg-lib/libxfont2_2.0.3.bb
index 5f27a55..2b72d67 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxfont2_2.0.3.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxfont2_2.0.3.bb
@@ -9,7 +9,7 @@
 LICENSE = "MIT & MIT-style & BSD"
 LIC_FILES_CHKSUM = "file://COPYING;md5=a46c8040f2f737bcd0c435feb2ab1c2c"
 
-DEPENDS += "freetype xtrans fontsproto libfontenc zlib"
+DEPENDS += "freetype xtrans xorgproto libfontenc zlib"
 
 XORG_PN = "libXfont2"
 
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxfont_1.5.4.bb b/poky/meta/recipes-graphics/xorg-lib/libxfont_1.5.4.bb
index 79f77fc..94c6c66 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxfont_1.5.4.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxfont_1.5.4.bb
@@ -9,7 +9,7 @@
 LICENSE = "MIT & MIT-style & BSD"
 LIC_FILES_CHKSUM = "file://COPYING;md5=a46c8040f2f737bcd0c435feb2ab1c2c"
 
-DEPENDS += "freetype xtrans fontsproto libfontenc zlib"
+DEPENDS += "freetype xtrans xorgproto libfontenc zlib"
 PROVIDES = "xfont"
 
 PE = "1"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxi_1.7.9.bb b/poky/meta/recipes-graphics/xorg-lib/libxi_1.7.9.bb
index 74f0527..08381d9 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxi_1.7.9.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxi_1.7.9.bb
@@ -11,7 +11,7 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=17b064789fab936a1c58c4e13d965b0f \
                     file://src/XIGetDevFocus.c;endline=23;md5=cdfb0d435a33ec57ea0d1e8e395b729f"
 
-DEPENDS += "libxext inputproto libxfixes"
+DEPENDS += "libxext xorgproto libxfixes"
 
 PE = "1"
 
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxinerama_1.1.3.bb b/poky/meta/recipes-graphics/xorg-lib/libxinerama_1.1.3.bb
deleted file mode 100644
index bb03f44..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/libxinerama_1.1.3.bb
+++ /dev/null
@@ -1,22 +0,0 @@
-require xorg-lib-common.inc
-
-SUMMARY = "Xinerama: Xinerama extension library"
-
-DESCRIPTION = "Xinerama is a simple library designed to interface the \
-Xinerama Extension for retrieving information about physical output \
-devices which may be combined into a single logical X screen."
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=6f4f634d1643a2e638bba3fcd19c2536 \
-                    file://src/Xinerama.c;beginline=2;endline=25;md5=fcef273bfb66339256411dd06ea79c02"
-
-DEPENDS += "libxext xineramaproto"
-PROVIDES = "xinerama"
-PE = "1"
-
-XORG_PN = "libXinerama"
-
-SRC_URI[md5sum] = "9336dc46ae3bf5f81c247f7131461efd"
-SRC_URI[sha256sum] = "7a45699f1773095a3f821e491cbd5e10c887c5a5fce5d8d3fced15c2ff7698e2"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxinerama_1.1.4.bb b/poky/meta/recipes-graphics/xorg-lib/libxinerama_1.1.4.bb
new file mode 100644
index 0000000..edce35d
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libxinerama_1.1.4.bb
@@ -0,0 +1,22 @@
+require xorg-lib-common.inc
+
+SUMMARY = "Xinerama: Xinerama extension library"
+
+DESCRIPTION = "Xinerama is a simple library designed to interface the \
+Xinerama Extension for retrieving information about physical output \
+devices which may be combined into a single logical X screen."
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=6f4f634d1643a2e638bba3fcd19c2536 \
+                    file://src/Xinerama.c;beginline=2;endline=25;md5=fcef273bfb66339256411dd06ea79c02"
+
+DEPENDS += "libxext xorgproto"
+PROVIDES = "xinerama"
+PE = "1"
+
+XORG_PN = "libXinerama"
+
+SRC_URI[md5sum] = "0d5f826a197dae74da67af4a9ef35885"
+SRC_URI[sha256sum] = "0008dbd7ecf717e1e507eed1856ab0d9cf946d03201b85d5dcf61489bb02d720"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxkbcommon_0.8.0.bb b/poky/meta/recipes-graphics/xorg-lib/libxkbcommon_0.8.0.bb
deleted file mode 100644
index 050d0b7..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/libxkbcommon_0.8.0.bb
+++ /dev/null
@@ -1,22 +0,0 @@
-SUMMARY = "Generic XKB keymap library"
-DESCRIPTION = "libxkbcommon is a keymap compiler and support library which \
-processes a reduced subset of keymaps as defined by the XKB specification."
-HOMEPAGE = "http://www.xkbcommon.org"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=e525ed9809e1f8a07cf4bce8b09e8b87"
-LICENSE = "MIT & MIT-style"
-
-DEPENDS = "util-macros flex-native bison-native"
-
-SRC_URI = "http://xkbcommon.org/download/${BPN}-${PV}.tar.xz"
-
-SRC_URI[md5sum] = "7d0e4c4a137d0ac45bf6b328c84c3a81"
-SRC_URI[sha256sum] = "e829265db04e0aebfb0591b6dc3377b64599558167846c3f5ee5c5e53641fe6d"
-
-UPSTREAM_CHECK_URI = "http://xkbcommon.org/"
-
-inherit autotools pkgconfig
-
-EXTRA_OECONF = "--disable-docs"
-
-PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}"
-PACKAGECONFIG[x11] = "--enable-x11,--disable-x11,libxcb xkeyboard-config,"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxkbcommon_0.8.2.bb b/poky/meta/recipes-graphics/xorg-lib/libxkbcommon_0.8.2.bb
new file mode 100644
index 0000000..8cf508b
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libxkbcommon_0.8.2.bb
@@ -0,0 +1,22 @@
+SUMMARY = "Generic XKB keymap library"
+DESCRIPTION = "libxkbcommon is a keymap compiler and support library which \
+processes a reduced subset of keymaps as defined by the XKB specification."
+HOMEPAGE = "http://www.xkbcommon.org"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=e525ed9809e1f8a07cf4bce8b09e8b87"
+LICENSE = "MIT & MIT-style"
+
+DEPENDS = "util-macros flex-native bison-native"
+
+SRC_URI = "http://xkbcommon.org/download/${BPN}-${PV}.tar.xz"
+
+SRC_URI[md5sum] = "5f7f8533f907ebcfb1cf8dceb9501264"
+SRC_URI[sha256sum] = "7ab8c4b3403d89d01898066b72cb6069bddeb5af94905a65368f671a026ed58c"
+
+UPSTREAM_CHECK_URI = "http://xkbcommon.org/"
+
+inherit autotools pkgconfig
+
+EXTRA_OECONF = "--disable-docs"
+
+PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}"
+PACKAGECONFIG[x11] = "--enable-x11,--disable-x11,libxcb xkeyboard-config,"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxkbfile_1.0.9.bb b/poky/meta/recipes-graphics/xorg-lib/libxkbfile_1.0.9.bb
index 39a344c..f5c1860 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxkbfile_1.0.9.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxkbfile_1.0.9.bb
@@ -8,7 +8,7 @@
 LICENSE = "MIT-style"
 LIC_FILES_CHKSUM = "file://COPYING;md5=8be7367f7e5d605a426f76bb37d4d61f"
 
-DEPENDS += "virtual/libx11 kbproto"
+DEPENDS += "virtual/libx11 xorgproto"
 
 PE = "1"
 
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxrandr_1.5.1.bb b/poky/meta/recipes-graphics/xorg-lib/libxrandr_1.5.1.bb
index 48e88d2..b90ebc6 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxrandr_1.5.1.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxrandr_1.5.1.bb
@@ -11,7 +11,7 @@
 LICENSE = "MIT-style"
 LIC_FILES_CHKSUM = "file://COPYING;md5=c9d1a2118a6cd5727521db8e7a2fee69"
 
-DEPENDS += "virtual/libx11 randrproto libxrender libxext"
+DEPENDS += "virtual/libx11 xorgproto libxrender libxext"
 
 PE = "1"
 
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxrender_0.9.10.bb b/poky/meta/recipes-graphics/xorg-lib/libxrender_0.9.10.bb
index 92b3102..9b18366 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxrender_0.9.10.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxrender_0.9.10.bb
@@ -11,7 +11,7 @@
 LICENSE = "MIT-style"
 LIC_FILES_CHKSUM = "file://COPYING;md5=d8bc71986d3b9b3639f6dfd6fac8f196"
 
-DEPENDS += "virtual/libx11 renderproto xproto"
+DEPENDS += "virtual/libx11 xorgproto"
 
 PE = "1"
 
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxres_1.2.0.bb b/poky/meta/recipes-graphics/xorg-lib/libxres_1.2.0.bb
index 8c34e47..af6bb19 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxres_1.2.0.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxres_1.2.0.bb
@@ -10,7 +10,7 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://COPYING;md5=8c89441a8df261bdc56587465e13c7fa"
 
-DEPENDS += "libxext resourceproto"
+DEPENDS += "libxext xorgproto"
 
 PE = "1"
 
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxscrnsaver_1.2.2.bb b/poky/meta/recipes-graphics/xorg-lib/libxscrnsaver_1.2.2.bb
deleted file mode 100644
index 354e5de..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/libxscrnsaver_1.2.2.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-require xorg-lib-common.inc
-
-SUMMARY = "Xscrnsaver: X Screen Saver extension library"
-
-DESCRIPTION = "The X Window System provides support for changing the \
-image on a display screen after a user-settable period of inactivity to \
-avoid burning the cathode ray tube phosphors. However, no interfaces are \
-provided for the user to control the image that is drawn. This extension \
-allows an external \"screen saver\" client to detect when the alternate \
-image is to be displayed and to provide the graphics."
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=21fd154ee757813632ada871a34113fb"
-
-DEPENDS += "libxext scrnsaverproto"
-PROVIDES = "libxss"
-RREPLACES_${PN} = "libxss"
-PE = "1"
-
-XORG_PN = "libXScrnSaver"
-
-SRC_URI[md5sum] = "7a773b16165e39e938650bcc9027c1d5"
-SRC_URI[sha256sum] = "8ff1efa7341c7f34bcf9b17c89648d6325ddaae22e3904e091794e0b4426ce1d"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxscrnsaver_1.2.3.bb b/poky/meta/recipes-graphics/xorg-lib/libxscrnsaver_1.2.3.bb
new file mode 100644
index 0000000..aed52e7
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libxscrnsaver_1.2.3.bb
@@ -0,0 +1,23 @@
+require xorg-lib-common.inc
+
+SUMMARY = "Xscrnsaver: X Screen Saver extension library"
+
+DESCRIPTION = "The X Window System provides support for changing the \
+image on a display screen after a user-settable period of inactivity to \
+avoid burning the cathode ray tube phosphors. However, no interfaces are \
+provided for the user to control the image that is drawn. This extension \
+allows an external \"screen saver\" client to detect when the alternate \
+image is to be displayed and to provide the graphics."
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=21fd154ee757813632ada871a34113fb"
+
+DEPENDS += "libxext xorgproto"
+PROVIDES = "libxss"
+RREPLACES_${PN} = "libxss"
+PE = "1"
+
+XORG_PN = "libXScrnSaver"
+
+SRC_URI[md5sum] = "eeea9d5af3e6c143d0ea1721d27a5e49"
+SRC_URI[sha256sum] = "f917075a1b7b5a38d67a8b0238eaab14acd2557679835b154cf2bca576e89bf8"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxshmfence/extensions.patch b/poky/meta/recipes-graphics/xorg-lib/libxshmfence/extensions.patch
deleted file mode 100644
index 4cc9e05..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/libxshmfence/extensions.patch
+++ /dev/null
@@ -1,17 +0,0 @@
-With glibc 2.27 memfd_create is behind a _GNU_SOURCE guard, so call
-AC_USE_SYSTEM_EXTENSIONS to get that defined.
-
-Upstream-Status: Submitted
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
-diff --git a/configure.ac b/configure.ac
-index 0c98875..ebf4dee 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -29,4 +29,6 @@ AC_CONFIG_SRCDIR([Makefile.am])
- AC_CONFIG_HEADERS([config.h])
- 
-+AC_USE_SYSTEM_EXTENSIONS
-+
- # Initialize Automake
- AM_INIT_AUTOMAKE([foreign dist-bzip2])
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxshmfence_1.2.bb b/poky/meta/recipes-graphics/xorg-lib/libxshmfence_1.2.bb
deleted file mode 100644
index 1df068d..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/libxshmfence_1.2.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-SUMMARY = "Shared memory 'SyncFence' synchronization primitive"
-
-DESCRIPTION = "This library offers a CPU-based synchronization primitive compatible \
-with the X SyncFence objects that can be shared between processes \
-using file descriptor passing."
-
-require xorg-lib-common.inc
-
-LICENSE = "MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=47e508ca280fde97906eacb77892c3ac"
-
-DEPENDS += "virtual/libx11"
-
-BBCLASSEXTEND = "native nativesdk"
-
-SRC_URI += "file://extensions.patch"
-
-SRC_URI[md5sum] = "66662e76899112c0f99e22f2fc775a7e"
-SRC_URI[sha256sum] = "d21b2d1fd78c1efbe1f2c16dae1cb23f8fd231dcf891465b8debe636a9054b0c"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxshmfence_1.3.bb b/poky/meta/recipes-graphics/xorg-lib/libxshmfence_1.3.bb
new file mode 100644
index 0000000..85a48e4
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libxshmfence_1.3.bb
@@ -0,0 +1,17 @@
+SUMMARY = "Shared memory 'SyncFence' synchronization primitive"
+
+DESCRIPTION = "This library offers a CPU-based synchronization primitive compatible \
+with the X SyncFence objects that can be shared between processes \
+using file descriptor passing."
+
+require xorg-lib-common.inc
+
+LICENSE = "MIT-style"
+LIC_FILES_CHKSUM = "file://COPYING;md5=47e508ca280fde97906eacb77892c3ac"
+
+DEPENDS += "virtual/libx11"
+
+BBCLASSEXTEND = "native nativesdk"
+
+SRC_URI[md5sum] = "42dda8016943dc12aff2c03a036e0937"
+SRC_URI[sha256sum] = "b884300d26a14961a076fbebc762a39831cb75f92bed5ccf9836345b459220c7"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxt_1.1.5.bb b/poky/meta/recipes-graphics/xorg-lib/libxt_1.1.5.bb
index 180d00d..f8d94a2 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxt_1.1.5.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxt_1.1.5.bb
@@ -16,7 +16,7 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=6565b1e0094ea1caae0971cc4035f343"
 
 
-DEPENDS += "util-linux libxcb libsm virtual/libx11 kbproto libxdmcp"
+DEPENDS += "util-linux libxcb libsm virtual/libx11 xorgproto libxdmcp"
 PROVIDES = "xt"
 
 PE = "1"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxtst_1.2.3.bb b/poky/meta/recipes-graphics/xorg-lib/libxtst_1.2.3.bb
index 5717fa5..266bd1c 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxtst_1.2.3.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxtst_1.2.3.bb
@@ -10,7 +10,7 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=bb4f89972c3869f617f61c1a79ad1952 \
                     file://src/XTest.c;beginline=2;endline=32;md5=b1c8c9dff842b4d5b89ca5fa32c40e99"
 
-DEPENDS += "libxext recordproto inputproto libxi"
+DEPENDS += "libxext xorgproto libxi"
 PROVIDES = "xtst"
 PE = "1"
 
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxv_1.0.11.bb b/poky/meta/recipes-graphics/xorg-lib/libxv_1.0.11.bb
index a226c27..c602723 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxv_1.0.11.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxv_1.0.11.bb
@@ -10,7 +10,7 @@
 LICENSE = "MIT-style"
 LIC_FILES_CHKSUM = "file://COPYING;md5=827da9afab1f727f2a66574629e0f39c"
 
-DEPENDS += "libxext videoproto"
+DEPENDS += "libxext xorgproto"
 
 XORG_PN = "libXv"
 
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxvmc_1.0.10.bb b/poky/meta/recipes-graphics/xorg-lib/libxvmc_1.0.10.bb
index 6ed49b1..7e49a98 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxvmc_1.0.10.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxvmc_1.0.10.bb
@@ -9,7 +9,7 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=0a207f08d4961489c55046c9a5e500da \
                     file://wrapper/XvMCWrapper.c;endline=26;md5=5151daa8172a3f1bb0cb0e0ff157d9de"
 
-DEPENDS += "libxext libxv videoproto"
+DEPENDS += "libxext libxv xorgproto"
 
 PE = "1"
 
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxxf86dga_1.1.4.bb b/poky/meta/recipes-graphics/xorg-lib/libxxf86dga_1.1.4.bb
index 695a396..626199e 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxxf86dga_1.1.4.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxxf86dga_1.1.4.bb
@@ -9,7 +9,7 @@
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=abb99ac125f84f424a4278153988e32f"
 
-DEPENDS += "libxext xf86dgaproto"
+DEPENDS += "libxext"
 
 PE = "1"
 
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxxf86misc_1.0.3.bb b/poky/meta/recipes-graphics/xorg-lib/libxxf86misc_1.0.3.bb
deleted file mode 100644
index af6f1f7..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/libxxf86misc_1.0.3.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-SUMMARY = "XFree86-Misc: XFree86 miscellaneous extension library"
-
-DESCRIPTION = "The XFree86-Misc extension, provides a means to access \
-input device configuration settings specific to the XFree86/Xorg DDX."
-
-require xorg-lib-common.inc
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=27c91ecc435bd3d2bfad868914c94b45"
-
-DEPENDS += "libxext xf86miscproto"
-PROVIDES = "xxf86misc"
-
-PE = "1"
-
-XORG_PN = "libXxf86misc"
-
-SRC_URI[md5sum] = "6bc0bf78909fd71021c466c793d4385c"
-SRC_URI[sha256sum] = "563f4200862efd3334c33a669e0a0aae5bab31f3998db75b87a99a697cc26b5b"
-
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxxf86misc_1.0.4.bb b/poky/meta/recipes-graphics/xorg-lib/libxxf86misc_1.0.4.bb
new file mode 100644
index 0000000..45b0673
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/libxxf86misc_1.0.4.bb
@@ -0,0 +1,19 @@
+SUMMARY = "XFree86-Misc: XFree86 miscellaneous extension library"
+
+DESCRIPTION = "The XFree86-Misc extension, provides a means to access \
+input device configuration settings specific to the XFree86/Xorg DDX."
+
+require xorg-lib-common.inc
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=27c91ecc435bd3d2bfad868914c94b45"
+
+DEPENDS += "libxext"
+PROVIDES = "xxf86misc"
+
+PE = "1"
+
+XORG_PN = "libXxf86misc"
+
+SRC_URI[md5sum] = "37ad70f8b53b94b550f9290be97fbe2d"
+SRC_URI[sha256sum] = "a89c03e2b0f16239d67a2031b9003f31b5a686106bbdb3c797fb88ae472af380"
diff --git a/poky/meta/recipes-graphics/xorg-lib/libxxf86vm_1.1.4.bb b/poky/meta/recipes-graphics/xorg-lib/libxxf86vm_1.1.4.bb
index 35f87d2..95fc0b6 100644
--- a/poky/meta/recipes-graphics/xorg-lib/libxxf86vm_1.1.4.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/libxxf86vm_1.1.4.bb
@@ -10,7 +10,7 @@
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://COPYING;md5=fa0b9c462d8f2f13eba26492d42ea63d"
 
-DEPENDS += "libxext xf86vidmodeproto"
+DEPENDS += "libxext xorgproto"
 
 PE = "1"
 
diff --git a/poky/meta/recipes-graphics/xorg-lib/xkeyboard-config_2.22.bb b/poky/meta/recipes-graphics/xorg-lib/xkeyboard-config_2.22.bb
deleted file mode 100644
index 4fd894f..0000000
--- a/poky/meta/recipes-graphics/xorg-lib/xkeyboard-config_2.22.bb
+++ /dev/null
@@ -1,32 +0,0 @@
-SUMMARY = "Keyboard configuration database for X Window"
-
-DESCRIPTION = "The non-arch keyboard configuration database for X \
-Window.  The goal is to provide the consistent, well-structured, \
-frequently released open source of X keyboard configuration data for X \
-Window System implementations.  The project is targeted to XKB-based \
-systems."
-
-HOMEPAGE = "http://freedesktop.org/wiki/Software/XKeyboardConfig"
-BUGTRACKER = "https://bugs.freedesktop.org/enter_bug.cgi?product=xkeyboard-config"
-
-LICENSE = "MIT & MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=0e7f21ca7db975c63467d2e7624a12f9"
-
-SRC_URI = "${XORG_MIRROR}/individual/data/xkeyboard-config/${BPN}-${PV}.tar.bz2"
-
-SRC_URI[md5sum] = "eb61fb3fd419e817df572b0c8d94a883"
-SRC_URI[sha256sum] = "deaec9989fbc443358b43864437b7b6d39caff07890a4a8055105ce9fcaa59bd"
-
-SECTION = "x11/libs"
-DEPENDS = "intltool-native util-macros libxslt-native"
-
-EXTRA_OECONF = "--with-xkb-rules-symlink=xorg --disable-runtime-deps"
-
-FILES_${PN} += "${datadir}/X11/xkb"
-
-inherit autotools pkgconfig gettext
-
-do_install_append () {
-    install -d ${D}${datadir}/X11/xkb/compiled
-    cd ${D}${datadir}/X11/xkb/rules && ln -sf base xorg
-}
diff --git a/poky/meta/recipes-graphics/xorg-lib/xkeyboard-config_2.24.bb b/poky/meta/recipes-graphics/xorg-lib/xkeyboard-config_2.24.bb
new file mode 100644
index 0000000..7d0e608
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/xkeyboard-config_2.24.bb
@@ -0,0 +1,32 @@
+SUMMARY = "Keyboard configuration database for X Window"
+
+DESCRIPTION = "The non-arch keyboard configuration database for X \
+Window.  The goal is to provide the consistent, well-structured, \
+frequently released open source of X keyboard configuration data for X \
+Window System implementations.  The project is targeted to XKB-based \
+systems."
+
+HOMEPAGE = "http://freedesktop.org/wiki/Software/XKeyboardConfig"
+BUGTRACKER = "https://bugs.freedesktop.org/enter_bug.cgi?product=xkeyboard-config"
+
+LICENSE = "MIT & MIT-style"
+LIC_FILES_CHKSUM = "file://COPYING;md5=0e7f21ca7db975c63467d2e7624a12f9"
+
+SRC_URI = "${XORG_MIRROR}/individual/data/xkeyboard-config/${BPN}-${PV}.tar.bz2"
+
+SRC_URI[md5sum] = "74c4bdf52382127cb5802c3f2ab441e0"
+SRC_URI[sha256sum] = "91b18580f46b4e4ea913707f6c8d68ab5286879c3a6591462f3b9e760d3ac4d7"
+
+SECTION = "x11/libs"
+DEPENDS = "intltool-native util-macros libxslt-native"
+
+EXTRA_OECONF = "--with-xkb-rules-symlink=xorg --disable-runtime-deps"
+
+FILES_${PN} += "${datadir}/X11/xkb"
+
+inherit autotools pkgconfig gettext
+
+do_install_append () {
+    install -d ${D}${datadir}/X11/xkb/compiled
+    cd ${D}${datadir}/X11/xkb/rules && ln -sf base xorg
+}
diff --git a/poky/meta/recipes-graphics/xorg-lib/xtrans/multilibfix.patch b/poky/meta/recipes-graphics/xorg-lib/xtrans/multilibfix.patch
new file mode 100644
index 0000000..c513bad
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-lib/xtrans/multilibfix.patch
@@ -0,0 +1,18 @@
+The xtrans.pc file is installed into a non-arch directory yet contains libdir
+which can vary depending on which multilib is configured. The .pc file does
+not require libdir so remove this to fix multilib builds.
+
+Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
+Upstream-Status: Pending
+
+Index: xtrans-1.3.5/xtrans.pc.in
+===================================================================
+--- xtrans-1.3.5.orig/xtrans.pc.in
++++ xtrans-1.3.5/xtrans.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+ 
+ Name: XTrans
diff --git a/poky/meta/recipes-graphics/xorg-lib/xtrans_1.3.5.bb b/poky/meta/recipes-graphics/xorg-lib/xtrans_1.3.5.bb
index d5b7f1a..200716f 100644
--- a/poky/meta/recipes-graphics/xorg-lib/xtrans_1.3.5.bb
+++ b/poky/meta/recipes-graphics/xorg-lib/xtrans_1.3.5.bb
@@ -12,6 +12,8 @@
 LICENSE = "MIT & MIT-style"
 LIC_FILES_CHKSUM = "file://COPYING;md5=49347921d4d5268021a999f250edc9ca"
 
+SRC_URI += "file://multilibfix.patch"
+
 PE = "1"
 
 RDEPENDS_${PN}-dev = ""
diff --git a/poky/meta/recipes-graphics/xorg-proto/bigreqsproto_1.1.2.bb b/poky/meta/recipes-graphics/xorg-proto/bigreqsproto_1.1.2.bb
deleted file mode 100644
index f798a43..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/bigreqsproto_1.1.2.bb
+++ /dev/null
@@ -1,16 +0,0 @@
-require xorg-proto-common.inc
-
-PE = "1"
-
-SUMMARY = "BigReqs: X Big Requests extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the \
-BIG-REQUESTS extension, used to send larger requests that usual in order \
-to avoid fragmentation."
-
-BBCLASSEXTEND = "native nativesdk"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=b12715630da6f268d0d3712ee1a504f4"
-
-SRC_URI[md5sum] = "1a05fb01fa1d5198894c931cf925c025"
-SRC_URI[sha256sum] = "462116ab44e41d8121bfde947321950370b285a5316612b8fce8334d50751b1e"
diff --git a/poky/meta/recipes-graphics/xorg-proto/calibrateproto/fix.patch b/poky/meta/recipes-graphics/xorg-proto/calibrateproto/fix.patch
deleted file mode 100644
index ff8cb25..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/calibrateproto/fix.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-Upstream-Status: Pending
-
-Add missing length fields to the replies. Without these, sanity checking in recent X
-breaks things.
-
-RP 11/2/10
-
-
-Index: git/xcalibrateproto.h
-===================================================================
---- git.orig/xcalibrateproto.h	2010-02-11 11:47:45.711985932 +0000
-+++ git/xcalibrateproto.h	2010-02-11 11:40:21.000000000 +0000
-@@ -67,13 +67,13 @@
-     BYTE    type;   /* X_Reply */
-     BYTE    pad1;
-     CARD16  sequenceNumber B16;
-+    CARD32  length;
-     CARD32  status;
-     CARD32  pad2 B32;
-     CARD32  pad3 B32;
-     CARD32  pad4 B32;
-     CARD32  pad5 B32;
-     CARD32  pad6 B32;
--    CARD32  pad7 B32;
- } xXCalibrateRawModeReply;
- 
- #define sz_xXCalibrateRawModeReply	32
-@@ -92,13 +92,13 @@
-     BYTE    type;   /* X_Reply */
-     BYTE    pad1;
-     CARD16  sequenceNumber B16;
-+    CARD32  length;
-     CARD32  x;
-     CARD32  y;
-     CARD32  pad2 B32;
-     CARD32  pad3 B32;
-     CARD32  pad4 B32;
-     CARD32  pad5 B32;
--    CARD32  pad6 B32;
- } xXCalibrateScreenToCoordReply;
- 
- #define sz_xXCalibrateScreenToCoordReply	32
diff --git a/poky/meta/recipes-graphics/xorg-proto/calibrateproto_git.bb b/poky/meta/recipes-graphics/xorg-proto/calibrateproto_git.bb
deleted file mode 100644
index eb4b422..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/calibrateproto_git.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "XCalibrate: Touchscreen calibration headers"
-
-DESCRIPTION = "This package provides the wire protocol for the \
-Touchscreen calibration extension."
-
-LICENSE = "MIT-style"
-LIC_FILES_CHKSUM = "file://xcalibratewire.h;endline=23;md5=7f86ef7b03cce6c4c9ebd59d20ca485f \
-                    file://xcalibrateproto.h;endline=23;md5=e4490491edcc171ca24f98569ee580db"
-
-SRCREV = "1da6fd1e2c7a49648245c98481fabea8b9690a8c"
-
-PV = "0.0+git${SRCPV}"
-PR = "r2"
-
-SRC_URI = "git://anongit.freedesktop.org/git/xorg/proto/calibrateproto \
-           file://fix.patch;apply=yes"
-S = "${WORKDIR}/git"
-UPSTREAM_CHECK_COMMITS = "1"
-
diff --git a/poky/meta/recipes-graphics/xorg-proto/compositeproto_0.4.2.bb b/poky/meta/recipes-graphics/xorg-proto/compositeproto_0.4.2.bb
deleted file mode 100644
index adfee26..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/compositeproto_0.4.2.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "Xcomposite: X composite extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the X \
-composite extension.  The X composite extension provides three related \
-mechanisms for compositing and off-screen storage."
-
-LICENSE = "MIT & MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=2c4bfe136f4a4418ea2f2a96b7c8f3c5 \
-                    file://composite.h;endline=43;md5=cbd44d4079053aa75930ed2f02b92926"
-
-RCONFLICTS_${PN} = "compositeext"
-BBCLASSEXTEND = "native"
-
-PR = "r1"
-PE = "1"
-
-SRC_URI[md5sum] = "98482f65ba1e74a08bf5b056a4031ef0"
-SRC_URI[sha256sum] = "049359f0be0b2b984a8149c966dd04e8c58e6eade2a4a309cf1126635ccd0cfc"
-
diff --git a/poky/meta/recipes-graphics/xorg-proto/damageproto_1.2.1.bb b/poky/meta/recipes-graphics/xorg-proto/damageproto_1.2.1.bb
deleted file mode 100644
index 75d0268..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/damageproto_1.2.1.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "Xdamage: X Damage extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the DAMAGE \
-extension.  The DAMAGE extension allows applications to receive \
-information about changes made to pixel contents of windows and \
-pixmaps."
-
-LICENSE = "MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d5f5a2de65c3a84cbde769f07a769608 \
-                    file://damagewire.h;endline=23;md5=4a4501a592dbc7de5ce89255e50d0296"
-
-RCONFLICTS_${PN} = "damageext"
-BBCLASSEXTEND = "native"
-PR = "r1"
-PE = "1"
-
-SRC_URI[md5sum] = "998e5904764b82642cc63d97b4ba9e95"
-SRC_URI[sha256sum] = "5c7c112e9b9ea8a9d5b019e5f17d481ae20f766cb7a4648360e7c1b46fc9fc5b"
diff --git a/poky/meta/recipes-graphics/xorg-proto/dmxproto_2.3.1.bb b/poky/meta/recipes-graphics/xorg-proto/dmxproto_2.3.1.bb
deleted file mode 100644
index d960e5d..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/dmxproto_2.3.1.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "DMX: Distributed Multihead extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the DMX \
-extension.  The DMX extension provides support for communication with \
-and control of Xdmx server.  Attributes of the Xdmx server and of the \
-back-end screens attached to the server can be queried and modified via \
-this protocol."
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=a3c3499231a8035efd0e004cfbd3b72a \
-                    file://dmxproto.h;endline=32;md5=ab8509955c3dd4c65fac728e1b367bc4"
-
-PE = "1"
-
-SRC_URI[md5sum] = "4ee175bbd44d05c34d43bb129be5098a"
-SRC_URI[sha256sum] = "e72051e6a3e06b236d19eed56368117b745ca1e1a27bdc50fd51aa375bea6509"
diff --git a/poky/meta/recipes-graphics/xorg-proto/dri2proto_2.8.bb b/poky/meta/recipes-graphics/xorg-proto/dri2proto_2.8.bb
deleted file mode 100644
index f4c40c5..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/dri2proto_2.8.bb
+++ /dev/null
@@ -1,15 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "DRI2: Direct Rendering Infrastructure 2 headers"
-
-DESCRIPTION = "This package provides the wire protocol for the Direct \
-Rendering Ifnrastructure 2.  DIR is required for may hardware \
-accelerated OpenGL drivers."
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=2e396fa91834f8786032cad2da5638f3 \
-                    file://dri2proto.h;endline=31;md5=22f28bf68d01b533f26195e94b3ed8ca"
-
-
-SRC_URI[md5sum] = "b2721d5d24c04d9980a0c6540cb5396a"
-SRC_URI[sha256sum] = "f9b55476def44fc7c459b2537d17dbc731e36ed5d416af7ca0b1e2e676f8aa04"
diff --git a/poky/meta/recipes-graphics/xorg-proto/dri3proto_1.0.bb b/poky/meta/recipes-graphics/xorg-proto/dri3proto_1.0.bb
deleted file mode 100644
index bed97b3..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/dri3proto_1.0.bb
+++ /dev/null
@@ -1,14 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "Direct Rendering Infrastructure 3 Extension"
-
-DESCRIPTION = "The DRI3 extension provides mechanisms to translate between direct \
-rendered buffers and X pixmaps. When combined with the Present extension, \
-a complete direct rendering solution for OpenGL is provided."
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://dri3proto.h;endline=21;md5=ac90d1d416be3cb13e1d3c88cd5166bf"
-
-
-SRC_URI[md5sum] = "a3d2cbe60a9ca1bf3aea6c93c817fee3"
-SRC_URI[sha256sum] = "01be49d70200518b9a6b297131f6cc71f4ea2de17436896af153226a774fc074"
diff --git a/poky/meta/recipes-graphics/xorg-proto/fixesproto_5.0.bb b/poky/meta/recipes-graphics/xorg-proto/fixesproto_5.0.bb
deleted file mode 100644
index 39fb88d..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/fixesproto_5.0.bb
+++ /dev/null
@@ -1,22 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "XFixes: X Fixes extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the X Fixes \
-extension.  This extension is designed to provide server-side support \
-for application work arounds to shortcomings in the core X window \
-system."
-
-
-LICENSE = "MIT & MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=262a7a87da56e66dd639bf7334a110c6 \
-                    file://xfixesproto.h;endline=43;md5=c3a9ee6db3532ed0d44dea266cfc97f4"
-
-RCONFLICTS_${PN} = "fixesext"
-PR = "r1"
-PE = "1"
-
-BBCLASSEXTEND = "native nativesdk"
-
-SRC_URI[md5sum] = "e7431ab84d37b2678af71e29355e101d"
-SRC_URI[sha256sum] = "ba2f3f31246bdd3f2a0acf8bd3b09ba99cab965c7fb2c2c92b7dc72870e424ce"
diff --git a/poky/meta/recipes-graphics/xorg-proto/fontsproto_2.1.3.bb b/poky/meta/recipes-graphics/xorg-proto/fontsproto_2.1.3.bb
deleted file mode 100644
index 27fc281..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/fontsproto_2.1.3.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "XFont: X Font rasterisation headers"
-
-DESCRIPTION = "This package provides the wire protocol for the X Font \
-rasterisation extensions.  These extensions are used to control \
-server-side font configurations."
-
-LICENSE = "MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=c3e48aa9ce868c8e90f0401db41c11a2 \
-                    file://FSproto.h;endline=44;md5=d2e58e27095e5ea7d4ad456ccb91986c"
-
-PE = "1"
-
-BBCLASSEXTEND = "native"
-
-SRC_URI[md5sum] = "36934d00b00555eaacde9f091f392f97"
-SRC_URI[sha256sum] = "259046b0dd9130825c4a4c479ba3591d6d0f17a33f54e294b56478729a6e5ab8"
diff --git a/poky/meta/recipes-graphics/xorg-proto/glproto_1.4.17.bb b/poky/meta/recipes-graphics/xorg-proto/glproto_1.4.17.bb
deleted file mode 100644
index eb03d33..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/glproto_1.4.17.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "OpenGL: X OpenGL extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the \
-OpenGL-related extensions, used to enable the rendering of applications \
-using OpenGL."
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d44ed0146997856304dfbb512a59a8de \
-                    file://glxproto.h;beginline=4;endline=32;md5=6b79c570f644363b356456e7d44471d9"
-
-PE = "1"
-
-BBCLASSEXTEND = "nativesdk"
-
-SRC_URI[md5sum] = "5565f1b0facf4a59c2778229c1f70d10"
-SRC_URI[sha256sum] = "adaa94bded310a2bfcbb9deb4d751d965fcfe6fb3a2f6d242e2df2d6589dbe40"
diff --git a/poky/meta/recipes-graphics/xorg-proto/inputproto_2.3.2.bb b/poky/meta/recipes-graphics/xorg-proto/inputproto_2.3.2.bb
deleted file mode 100644
index eb5e66b..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/inputproto_2.3.2.bb
+++ /dev/null
@@ -1,22 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "XI: X Input extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the X Input \
-extension.  The extension supports input devices other then the core X \
-keyboard and pointer."
-
-LICENSE = "MIT & MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=e562cc0f6587b961f032211d8160f31e \
-                    file://XI2proto.h;endline=48;md5=1ac1581e61188da2885cc14ff49b20be"
-
-PE = "1"
-
-inherit gettext
-
-BBCLASSEXTEND = "native nativesdk"
-
-SRC_URI[md5sum] = "b290a463af7def483e6e190de460f31a"
-SRC_URI[sha256sum] = "893a6af55733262058a27b38eeb1edc733669f01d404e8581b167f03c03ef31d"
-
-EXTRA_OECONF += "--without-asciidoc"
diff --git a/poky/meta/recipes-graphics/xorg-proto/kbproto_1.0.7.bb b/poky/meta/recipes-graphics/xorg-proto/kbproto_1.0.7.bb
deleted file mode 100644
index 46f5c92..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/kbproto_1.0.7.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "XKB: X Keyboard extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the X \
-Keyboard extension.  This extension is used to control options related \
-to keyboard handling and layout."
-
-LICENSE = "MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=7dd6ea99e2a83a552c02c80963623c38 \
-                    file://XKBproto.h;beginline=1;endline=25;md5=5744eeff407aeb6e7a1346eebab486a2"
-
-PE = "1"
-
-BBCLASSEXTEND = "native nativesdk"
-
-SRC_URI[md5sum] = "94afc90c1f7bef4a27fdd59ece39c878"
-SRC_URI[sha256sum] = "f882210b76376e3fa006b11dbd890e56ec0942bc56e65d1249ff4af86f90b857"
diff --git a/poky/meta/recipes-graphics/xorg-proto/presentproto_git.bb b/poky/meta/recipes-graphics/xorg-proto/presentproto_git.bb
deleted file mode 100644
index e6d32f9..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/presentproto_git.bb
+++ /dev/null
@@ -1,22 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "This package provides the basic headers for the X Window System"
-DESCRIPTION = "The Present extension provides a way for applications to update their \
-               window contents from a pixmap in a well defined fashion, synchronizing \
-               with the display refresh and potentially using a more efficient \
-               mechanism than copying the contents of the source pixmap.\
-              "
-
-LICENSE = "GPLv2"
-
-SRCREV = "bfdc7e052302c79c5803ad95a73c9b63b350c40c"
-PV = "1.1+git${SRCPV}"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=47e508ca280fde97906eacb77892c3ac"
-
-SRC_URI = "git://anongit.freedesktop.org/git/xorg/proto/presentproto"
-S = "${WORKDIR}/git"
-
-inherit autotools
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-graphics/xorg-proto/randrproto_1.5.0.bb b/poky/meta/recipes-graphics/xorg-proto/randrproto_1.5.0.bb
deleted file mode 100644
index b59e525..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/randrproto_1.5.0.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "XRandR: X Resize, Rotate and Reflect extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the X Resize, \
-Rotate and Reflect extension.  This extension provides the ability to \
-resize, rotate and reflect the root window of a screen."
-
-LICENSE = "MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=00426d41bd3d9267cf9bbb2df9323a5e \
-                    file://randrproto.h;endline=30;md5=3885957c6048fdf3310ac8ba54ca2c3f"
-
-RCONFLICTS_${PN} = "randrext"
-PE = "1"
-
-BBCLASSEXTEND = "native nativesdk"
-
-SRC_URI[md5sum] = "a46765c8dcacb7114c821baf0df1e797"
-SRC_URI[sha256sum] = "4c675533e79cd730997d232c8894b6692174dce58d3e207021b8f860be498468"
diff --git a/poky/meta/recipes-graphics/xorg-proto/recordproto_1.14.2.bb b/poky/meta/recipes-graphics/xorg-proto/recordproto_1.14.2.bb
deleted file mode 100644
index ad2317c..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/recordproto_1.14.2.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "XRecord: X Record extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the X Record \
-extension.  This extension is used to record and play back event \
-sequences."
-
-LICENSE = "MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=575827a0f554bbed332542976d5f3d40 \
-                    file://recordproto.h;endline=19;md5=1cbb0dd45a0b060ff833901620a3e738"
-
-RCONFLICTS_${PN} = "recordext"
-PR = "r1"
-PE = "1"
-
-SRC_URI[md5sum] = "1b4e5dede5ea51906f1530ca1e21d216"
-SRC_URI[sha256sum] = "a777548d2e92aa259f1528de3c4a36d15e07a4650d0976573a8e2ff5437e7370"
diff --git a/poky/meta/recipes-graphics/xorg-proto/renderproto_0.11.1.bb b/poky/meta/recipes-graphics/xorg-proto/renderproto_0.11.1.bb
deleted file mode 100644
index ff800ec..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/renderproto_0.11.1.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "XRender: X rendering Extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the X \
-Rendering extension.  This is the basis the image composition within the \
-X window system."
-
-LICENSE = "MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=f826d99765196352e6122a406cf0d024 \
-                    file://renderproto.h;beginline=4;endline=24;md5=3e5e2851dad240b0a3a27c4776b4fd1f"
-
-RCONFLICTS_${PN} = "renderext"
-PR = "r1"
-PE = "1"
-
-BBCLASSEXTEND = "native nativesdk"
-
-SRC_URI[md5sum] = "a914ccc1de66ddeb4b611c6b0686e274"
-SRC_URI[sha256sum] = "06735a5b92b20759204e4751ecd6064a2ad8a6246bb65b3078b862a00def2537"
-
diff --git a/poky/meta/recipes-graphics/xorg-proto/resourceproto_1.2.0.bb b/poky/meta/recipes-graphics/xorg-proto/resourceproto_1.2.0.bb
deleted file mode 100644
index 08b610a..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/resourceproto_1.2.0.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "XRes: X Resource extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the X \
-Resource extension.  XRes provides an interface that allows X clients to \
-see and monitor X resource usage of various clients."
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=604859305e662503077240fee8c77d97"
-
-RCONFLICTS_${PN} = "resourceext"
-
-PR = "r1"
-PE = "1"
-
-SRC_URI[md5sum] = "cfdb57dae221b71b2703f8e2980eaaf4"
-SRC_URI[sha256sum] = "3c66003a6bdeb0f70932a9ed3cf57cc554234154378d301e0c5cfa189d8f6818"
-
diff --git a/poky/meta/recipes-graphics/xorg-proto/scrnsaverproto_1.2.2.bb b/poky/meta/recipes-graphics/xorg-proto/scrnsaverproto_1.2.2.bb
deleted file mode 100644
index ab07f51..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/scrnsaverproto_1.2.2.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "Xscrnsaver: X Screen Saver extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the X Screen \
-Saver extension.  This extension allows an external \"screen saver\" \
-client to detect when the alternative image is to be displayed and to \
-provide the graphics."
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=eed49b78b15b436c933b6b8b054e3901 \
-                    file://saverproto.h;endline=26;md5=a84c0637305159f3c0ab173aaeede48d"
-
-PE = "1"
-
-EXTRA_OECONF_append = " --enable-specs=no"
-
-SRC_URI[md5sum] = "edd8a73775e8ece1d69515dd17767bfb"
-SRC_URI[sha256sum] = "8bb70a8da164930cceaeb4c74180291660533ad3cc45377b30a795d1b85bcd65"
diff --git a/poky/meta/recipes-graphics/xorg-proto/videoproto_2.3.3.bb b/poky/meta/recipes-graphics/xorg-proto/videoproto_2.3.3.bb
deleted file mode 100644
index 6f97a26..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/videoproto_2.3.3.bb
+++ /dev/null
@@ -1,14 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "Xv: X Video extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the X Video \
-extension.  This extension alows for accerlated drawing of videos."
-
-LICENSE = "MIT & MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=ce3472a119a864085fa4155cb0979a7b"
-
-PE = "1"
-
-SRC_URI[md5sum] = "fe86de8ea3eb53b5a8f52956c5cd3174"
-SRC_URI[sha256sum] = "c7803889fd08e6fcaf7b68cc394fb038b2325d1f315e571a6954577e07cca702"
diff --git a/poky/meta/recipes-graphics/xorg-proto/xcb-proto/0001-Make-whitespace-use-consistent.patch b/poky/meta/recipes-graphics/xorg-proto/xcb-proto/0001-Make-whitespace-use-consistent.patch
deleted file mode 100644
index 89ec666..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/xcb-proto/0001-Make-whitespace-use-consistent.patch
+++ /dev/null
@@ -1,215 +0,0 @@
-From ea7a3ac6c658164690e0febb55f4467cb9e0bcac Mon Sep 17 00:00:00 2001
-From: Thomas Klausner <wiz@NetBSD.org>
-Date: Thu, 19 May 2016 17:30:04 +0200
-Subject: [PATCH 1/2] Make whitespace use consistent.
-
-At least python-3.5.x complains about this forcefully.
-
-Signed-off-by: Thomas Klausner <wiz@NetBSD.org>
-Signed-off-by: Uli Schlachter <psychon@znc.in>
-
-Upstream-Status: Backport
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
----
- xcbgen/align.py | 96 ++++++++++++++++++++++++++++-----------------------------
- 1 file changed, 48 insertions(+), 48 deletions(-)
-
-diff --git a/xcbgen/align.py b/xcbgen/align.py
-index 5e31838..d4c12ee 100644
---- a/xcbgen/align.py
-+++ b/xcbgen/align.py
-@@ -16,12 +16,12 @@ class Alignment(object):
-         return self.align == other.align and self.offset == other.offset
- 
-     def __str__(self):
--	return "(align=%d, offset=%d)" % (self.align, self.offset)
-+        return "(align=%d, offset=%d)" % (self.align, self.offset)
- 
-     @staticmethod
-     def for_primitive_type(size):
--	# compute the required start_alignment based on the size of the type
--	if size % 8 == 0:
-+        # compute the required start_alignment based on the size of the type
-+        if size % 8 == 0:
-             # do 8-byte primitives require 8-byte alignment in X11?
-             return Alignment(8,0)
-         elif size % 4 == 0:
-@@ -33,7 +33,7 @@ class Alignment(object):
- 
- 
-     def align_after_fixed_size(self, size):
--	new_offset = (self.offset + size) % self.align
-+        new_offset = (self.offset + size) % self.align
-         return Alignment(self.align, new_offset)
- 
- 
-@@ -41,7 +41,7 @@ class Alignment(object):
-         '''
-         Assuming the given external_align, checks whether
-         self is fulfilled for all cases.
--	Returns True if yes, False otherwise.
-+        Returns True if yes, False otherwise.
-         '''
-         if self.align == 1 and self.offset == 0:
-             # alignment 1 with offset 0 is always fulfilled
-@@ -55,9 +55,9 @@ class Alignment(object):
-             # the external align guarantees less alignment -> not guaranteed
-             return False
- 
--	if external_align.align % self.align != 0:
-+        if external_align.align % self.align != 0:
-             # the external align cannot be divided by our align
--	    # -> not guaranteed
-+            # -> not guaranteed
-             # (this can only happen if there are alignments that are not
-             # a power of 2, which is highly discouraged. But better be
-             # safe and check for it)
-@@ -72,7 +72,7 @@ class Alignment(object):
- 
-     def combine_with(self, other):
-         # returns the alignment that is guaranteed when
--	# both, self or other, can happen
-+        # both, self or other, can happen
-         new_align = gcd(self.align, other.align)
-         new_offset_candidate1 = self.offset % new_align
-         new_offset_candidate2 = other.offset % new_align
-@@ -83,8 +83,8 @@ class Alignment(object):
-             new_align = gcd(new_align, offset_diff)
-             new_offset_candidate1 = self.offset % new_align
-             new_offset_candidate2 = other.offset % new_align
--	    assert new_offset_candidate1 == new_offset_candidate2
--	    new_offset = new_offset_candidate1
-+            assert new_offset_candidate1 == new_offset_candidate2
-+            new_offset = new_offset_candidate1
-         # return the result
-         return Alignment(new_align, new_offset)
- 
-@@ -92,44 +92,44 @@ class Alignment(object):
- class AlignmentLog(object):
- 
-     def __init__(self):
--	self.ok_list = []
--	self.fail_list = []
--	self.verbosity = 1
-+        self.ok_list = []
-+        self.fail_list = []
-+        self.verbosity = 1
- 
-     def __str__(self):
--	result = ""
-+        result = ""
- 
--	# output the OK-list
--	for (align_before, field_name, type_obj, callstack, align_after) in self.ok_list:
--	    stacksize = len(callstack)
-+        # output the OK-list
-+        for (align_before, field_name, type_obj, callstack, align_after) in self.ok_list:
-+            stacksize = len(callstack)
-             indent = '  ' * stacksize
--	    if self.ok_callstack_is_relevant(callstack):
-+            if self.ok_callstack_is_relevant(callstack):
-                 if field_name is None or field_name == "":
--	            result += ("    %sok: %s:\n\t%sbefore: %s, after: %s\n"
--		        % (indent, str(type_obj), indent, str(align_before), str(align_after)))
--	        else:
--		    result += ("    %sok: field \"%s\" in %s:\n\t%sbefore: %s, after: %s\n"
--		        % (indent, str(field_name), str(type_obj),
--		           indent, str(align_before), str(align_after)))
-+                    result += ("    %sok: %s:\n\t%sbefore: %s, after: %s\n"
-+                        % (indent, str(type_obj), indent, str(align_before), str(align_after)))
-+                else:
-+                    result += ("    %sok: field \"%s\" in %s:\n\t%sbefore: %s, after: %s\n"
-+                        % (indent, str(field_name), str(type_obj),
-+                           indent, str(align_before), str(align_after)))
-                 if self.verbosity >= 1:
--		    result += self.callstack_to_str(indent, callstack)
-+                    result += self.callstack_to_str(indent, callstack)
- 
--	# output the fail-list
--	for (align_before, field_name, type_obj, callstack, reason) in self.fail_list:
--	    stacksize = len(callstack)
-+        # output the fail-list
-+        for (align_before, field_name, type_obj, callstack, reason) in self.fail_list:
-+            stacksize = len(callstack)
-             indent = '  ' * stacksize
--	    if field_name is None or field_name == "":
--	        result += ("    %sfail: align %s is incompatible with\n\t%s%s\n\t%sReason: %s\n"
--		    % (indent, str(align_before), indent, str(type_obj), indent, reason))
--	    else:
--		result += ("    %sfail: align %s is incompatible with\n\t%sfield \"%s\" in %s\n\t%sReason: %s\n"
--		    % (indent, str(align_before), indent, str(field_name), str(type_obj), indent, reason))
-+            if field_name is None or field_name == "":
-+                result += ("    %sfail: align %s is incompatible with\n\t%s%s\n\t%sReason: %s\n"
-+                    % (indent, str(align_before), indent, str(type_obj), indent, reason))
-+            else:
-+                result += ("    %sfail: align %s is incompatible with\n\t%sfield \"%s\" in %s\n\t%sReason: %s\n"
-+                    % (indent, str(align_before), indent, str(field_name), str(type_obj), indent, reason))
- 
-             if self.verbosity >= 1:
--	        result += self.callstack_to_str(indent, callstack)
-+                result += self.callstack_to_str(indent, callstack)
- 
- 
--	return result
-+        return result
- 
- 
-     def callstack_to_str(self, indent, callstack):
-@@ -137,41 +137,41 @@ class AlignmentLog(object):
-         for stack_elem in callstack:
-             result += "\t  %s%s\n" % (indent, str(stack_elem))
-         result += "\t%s]\n" % indent
--	return result
-+        return result
- 
- 
-     def ok_callstack_is_relevant(self, ok_callstack):
-         # determine whether an ok callstack is relevant for logging
--	if self.verbosity >= 2:
--	    return True
-+        if self.verbosity >= 2:
-+            return True
- 
-         # empty callstacks are always relevant
--	if len(ok_callstack) == 0:
-+        if len(ok_callstack) == 0:
-             return True
- 
--	# check whether the ok_callstack is a subset or equal to a fail_callstack
-+        # check whether the ok_callstack is a subset or equal to a fail_callstack
-         for (align_before, field_name, type_obj, fail_callstack, reason) in self.fail_list:
-             if len(ok_callstack) <= len(fail_callstack):
-                 zipped = zip(ok_callstack, fail_callstack[:len(ok_callstack)])
--		is_subset = all([i == j for i, j in zipped])
--		if is_subset:
-+                is_subset = all([i == j for i, j in zipped])
-+                if is_subset:
-                     return True
- 
-         return False
- 
- 
-     def ok(self, align_before, field_name, type_obj, callstack, align_after):
--	self.ok_list.append((align_before, field_name, type_obj, callstack, align_after))
-+        self.ok_list.append((align_before, field_name, type_obj, callstack, align_after))
- 
-     def fail(self, align_before, field_name, type_obj, callstack, reason):
--	self.fail_list.append((align_before, field_name, type_obj, callstack, reason))
-+        self.fail_list.append((align_before, field_name, type_obj, callstack, reason))
- 
-     def append(self, other):
--	self.ok_list.extend(other.ok_list)
--	self.fail_list.extend(other.fail_list)
-+        self.ok_list.extend(other.ok_list)
-+        self.fail_list.extend(other.fail_list)
- 
-     def ok_count(self):
--	return len(self.ok_list)
-+        return len(self.ok_list)
- 
- 
- 
--- 
-2.9.0
-
diff --git a/poky/meta/recipes-graphics/xorg-proto/xcb-proto/0002-print-is-a-function-and-needs-parentheses.patch b/poky/meta/recipes-graphics/xorg-proto/xcb-proto/0002-print-is-a-function-and-needs-parentheses.patch
deleted file mode 100644
index 542acb8..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/xcb-proto/0002-print-is-a-function-and-needs-parentheses.patch
+++ /dev/null
@@ -1,75 +0,0 @@
-From bea5e1c85bdc0950913790364e18228f20395a3d Mon Sep 17 00:00:00 2001
-From: Thomas Klausner <wiz@NetBSD.org>
-Date: Thu, 19 May 2016 17:30:05 +0200
-Subject: [PATCH 2/2] print() is a function and needs parentheses.
-
-Fixes build with python-3.x.
-
-Signed-off-by: Thomas Klausner <wiz@NetBSD.org>
-Signed-off-by: Uli Schlachter <psychon@znc.in>
-
-Upstream-Status: Backport
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
----
- xcbgen/xtypes.py | 12 ++++++------
- 1 file changed, 6 insertions(+), 6 deletions(-)
-
-diff --git a/xcbgen/xtypes.py b/xcbgen/xtypes.py
-index c3b5758..b83b119 100644
---- a/xcbgen/xtypes.py
-+++ b/xcbgen/xtypes.py
-@@ -501,7 +501,7 @@ class ComplexType(Type):
-                 int(required_start_align_element.get('align', "4"), 0),
-                 int(required_start_align_element.get('offset', "0"), 0))
-             if verbose_align_log:
--                print "Explicit start-align for %s: %s\n" % (self, self.required_start_align)
-+                print ("Explicit start-align for %s: %s\n" % (self, self.required_start_align))
- 
-     def resolve(self, module):
-         if self.resolved:
-@@ -592,7 +592,7 @@ class ComplexType(Type):
-                 if verbose_align_log:
-                     print ("calc_required_start_align: %s has start-align %s"
-                         % (str(self), str(self.required_start_align)))
--                    print "Details:\n" + str(log)
-+                    print ("Details:\n" + str(log))
-                 if self.required_start_align.offset != 0:
-                     print (("WARNING: %s\n\thas start-align with non-zero offset: %s"
-                         + "\n\tsuggest to add explicit definition with:"
-@@ -619,12 +619,12 @@ class ComplexType(Type):
-             for offset in range(0,align):
-                 align_candidate = Alignment(align, offset)
-                 if verbose_align_log:
--                    print "trying %s for %s" % (str(align_candidate), str(self))
-+                    print ("trying %s for %s" % (str(align_candidate), str(self)))
-                 my_log = AlignmentLog()
-                 if self.is_possible_start_align(align_candidate, callstack, my_log):
-                     log.append(my_log)
-                     if verbose_align_log:
--                        print "found start-align %s for %s" % (str(align_candidate), str(self))
-+                        print ("found start-align %s for %s" % (str(align_candidate), str(self)))
-                     return align_candidate
-                 else:
-                     my_ok_count = my_log.ok_count()
-@@ -641,7 +641,7 @@ class ComplexType(Type):
-         # none of the candidates applies
-         # this type has illegal internal aligns for all possible start_aligns
-         if verbose_align_log:
--            print "didn't find start-align for %s" % str(self)
-+            print ("didn't find start-align for %s" % str(self))
-         log.append(best_log)
-         return None
- 
-@@ -900,7 +900,7 @@ class SwitchType(ComplexType):
-     # aux function for unchecked_get_alignment_after
-     def get_align_for_selected_case_field(self, case_field, start_align, callstack, log):
-         if verbose_align_log:
--            print "get_align_for_selected_case_field: %s, case_field = %s" % (str(self), str(case_field))
-+            print ("get_align_for_selected_case_field: %s, case_field = %s" % (str(self), str(case_field)))
-         total_align = start_align
-         for field in self.bitcases:
-             my_callstack = callstack[:]
--- 
-2.9.0
-
diff --git a/poky/meta/recipes-graphics/xorg-proto/xcb-proto_1.12.bb b/poky/meta/recipes-graphics/xorg-proto/xcb-proto_1.12.bb
deleted file mode 100644
index 25a8373..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/xcb-proto_1.12.bb
+++ /dev/null
@@ -1,53 +0,0 @@
-SUMMARY = "XCB: The X protocol C binding headers"
-DESCRIPTION = "Function prototypes for the X protocol C-language Binding \
-(XCB).  XCB is a replacement for Xlib featuring a small footprint, \
-latency hiding, direct access to the protocol, improved threading \
-support, and extensibility."
-HOMEPAGE = "http://xcb.freedesktop.org"
-BUGTRACKER = "https://bugs.freedesktop.org/enter_bug.cgi?product=XCB"
-
-SECTION = "x11/libs"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d763b081cb10c223435b01e00dc0aba7 \
-                    file://src/dri2.xml;beginline=2;endline=28;md5=f8763b13ff432e8597e0d610cf598e65"
-
-SRC_URI = "http://xcb.freedesktop.org/dist/${BP}.tar.bz2 \
-           file://0001-Make-whitespace-use-consistent.patch \
-           file://0002-print-is-a-function-and-needs-parentheses.patch \
-           "
-SRC_URI[md5sum] = "14e60919f859560f28426a685a555962"
-SRC_URI[sha256sum] = "5922aba4c664ab7899a29d92ea91a87aa4c1fc7eb5ee550325c3216c480a4906"
-
-inherit autotools pkgconfig
-
-# Force the use of Python 3 and a specific library path so we don't need to
-# depend on python3-native
-CACHED_CONFIGUREVARS += "PYTHON=python3 am_cv_python_pythondir=${libdir}/xcb-proto"
-
-PACKAGES += "python-xcbgen"
-
-FILES_${PN} = ""
-FILES_${PN}-dev += "${datadir}/xcb/*.xml ${datadir}/xcb/*.xsd"
-FILES_python-xcbgen = "${libdir}/xcb-proto"
-
-RDEPENDS_${PN}-dev = ""
-RRECOMMENDS_${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})"
-
-BBCLASSEXTEND = "native nativesdk"
-
-# Need to do this dance because we're forcing the use of host Python above and
-# if xcb-proto is built with Py3.5 and then re-used from sstate on a host with
-# Py3.6 the second build will write new cache files into the sysroot which won't
-# be listed in the manifest so won't be deleted, resulting in an error on
-# rebuilds.  Solve this by deleting the entire cache directory when this package
-# is removed from the sysroot.
-SSTATEPOSTINSTFUNCS += "xcb_sstate_postinst"
-xcb_sstate_postinst() {
-	if [ "${BB_CURRENTTASK}" = "populate_sysroot" -o "${BB_CURRENTTASK}" = "populate_sysroot_setscene" ]
-	then
-		cat <<EOF >${SSTATE_INST_POSTRM}
-#!/bin/sh
-rm -rf ${libdir}/xcb-proto/xcbgen/__pycache__
-EOF
-	fi
-}
diff --git a/poky/meta/recipes-graphics/xorg-proto/xcb-proto_1.13.bb b/poky/meta/recipes-graphics/xorg-proto/xcb-proto_1.13.bb
new file mode 100644
index 0000000..d503786
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-proto/xcb-proto_1.13.bb
@@ -0,0 +1,51 @@
+SUMMARY = "XCB: The X protocol C binding headers"
+DESCRIPTION = "Function prototypes for the X protocol C-language Binding \
+(XCB).  XCB is a replacement for Xlib featuring a small footprint, \
+latency hiding, direct access to the protocol, improved threading \
+support, and extensibility."
+HOMEPAGE = "http://xcb.freedesktop.org"
+BUGTRACKER = "https://bugs.freedesktop.org/enter_bug.cgi?product=XCB"
+
+SECTION = "x11/libs"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d763b081cb10c223435b01e00dc0aba7 \
+                    file://src/dri2.xml;beginline=2;endline=28;md5=f8763b13ff432e8597e0d610cf598e65"
+
+SRC_URI = "http://xcb.freedesktop.org/dist/${BP}.tar.bz2"
+
+SRC_URI[md5sum] = "abe9aa4886138150bbc04ae4f29b90e3"
+SRC_URI[sha256sum] = "7b98721e669be80284e9bbfeab02d2d0d54cd11172b72271e47a2fe875e2bde1"
+
+inherit autotools pkgconfig
+
+# Force the use of Python 3 and a specific library path so we don't need to
+# depend on python3-native
+CACHED_CONFIGUREVARS += "PYTHON=python3 am_cv_python_pythondir=${libdir}/xcb-proto"
+
+PACKAGES += "python-xcbgen"
+
+FILES_${PN} = ""
+FILES_${PN}-dev += "${datadir}/xcb/*.xml ${datadir}/xcb/*.xsd"
+FILES_python-xcbgen = "${libdir}/xcb-proto"
+
+RDEPENDS_${PN}-dev = ""
+RRECOMMENDS_${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})"
+
+BBCLASSEXTEND = "native nativesdk"
+
+# Need to do this dance because we're forcing the use of host Python above and
+# if xcb-proto is built with Py3.5 and then re-used from sstate on a host with
+# Py3.6 the second build will write new cache files into the sysroot which won't
+# be listed in the manifest so won't be deleted, resulting in an error on
+# rebuilds.  Solve this by deleting the entire cache directory when this package
+# is removed from the sysroot.
+SSTATEPOSTINSTFUNCS += "xcb_sstate_postinst"
+xcb_sstate_postinst() {
+	if [ "${BB_CURRENTTASK}" = "populate_sysroot" -o "${BB_CURRENTTASK}" = "populate_sysroot_setscene" ]
+	then
+		cat <<EOF >${SSTATE_INST_POSTRM}
+#!/bin/sh
+rm -rf ${libdir}/xcb-proto/xcbgen/__pycache__
+EOF
+	fi
+}
diff --git a/poky/meta/recipes-graphics/xorg-proto/xcmiscproto_1.2.2.bb b/poky/meta/recipes-graphics/xorg-proto/xcmiscproto_1.2.2.bb
deleted file mode 100644
index 0751b94..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/xcmiscproto_1.2.2.bb
+++ /dev/null
@@ -1,17 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "XC-MISC: X XC-Miscellaneous extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the XC-MISC \
-extension, which is used to get details of XID allocations within the \
-server."
-
-LICENSE = "MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=09d83047c15994e05db29b423ed6662e"
-
-PE = "1"
-
-BBCLASSEXTEND = "native nativesdk"
-
-SRC_URI[md5sum] = "5f4847c78e41b801982c8a5e06365b24"
-SRC_URI[sha256sum] = "b13236869372256c36db79ae39d54214172677fb79e9cdc555dceec80bd9d2df"
diff --git a/poky/meta/recipes-graphics/xorg-proto/xextproto_7.3.0.bb b/poky/meta/recipes-graphics/xorg-proto/xextproto_7.3.0.bb
deleted file mode 100644
index dd0bd95..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/xextproto_7.3.0.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "XExt: X Extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for several X \
-extensions.  These protocol extensions include DOUBLE-BUFFER, DPMS, \
-Extended-Visual-Information, LBX, MIT_SHM, MIT_SUNDRY-NONSTANDARD, \
-Multi-Buffering, SECURITY, SHAPE, SYNC, TOG-CUP, XC-APPGROUP, XC-MISC, \
-XTEST.  In addition a small set of utility functions are also \
-available."
-
-LICENSE = "MIT & MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=86f273291759d0ba2a22585cd1c06c53"
-
-PE = "1"
-
-inherit gettext
-
-EXTRA_OECONF_append = " --enable-specs=no"
-
-BBCLASSEXTEND = "native nativesdk"
-
-SRC_URI[md5sum] = "70c90f313b4b0851758ef77b95019584"
-SRC_URI[sha256sum] = "f3f4b23ac8db9c3a9e0d8edb591713f3d70ef9c3b175970dd8823dfc92aa5bb0"
diff --git a/poky/meta/recipes-graphics/xorg-proto/xf86dgaproto_2.1.bb b/poky/meta/recipes-graphics/xorg-proto/xf86dgaproto_2.1.bb
deleted file mode 100644
index 86f3ce3..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/xf86dgaproto_2.1.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "XFree86-DGA: XFree86 Direct Graphics Access extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the XFree86 \
-Direct Graphics Access extension. This extension allows direct graphics \
-access to a framebuffer-like region, as well as relative mouse \
-reporting."
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=e01e66e4b317088cf869bc98e6af4fb6"
-
-RCONFLICTS_${PN} = "xxf86dgaext"
-PR = "r2"
-PE = "1"
-
-SRC_URI[md5sum] = "a036dc2fcbf052ec10621fd48b68dbb1"
-SRC_URI[sha256sum] = "ac5ef65108e1f2146286e53080975683dae49fc94680042e04bd1e2010e99050"
diff --git a/poky/meta/recipes-graphics/xorg-proto/xf86driproto_2.1.1.bb b/poky/meta/recipes-graphics/xorg-proto/xf86driproto_2.1.1.bb
deleted file mode 100644
index b3f9210..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/xf86driproto_2.1.1.bb
+++ /dev/null
@@ -1,17 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "XFree86-DRI: XFree86 Direct Rendering Infrastructure extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the XFree86 \
-Direct Rendering Infrastructure extension.  The XFree86-DRI extension is \
-used to organize direct rendering support or 3D clients and help \
-arbitrate requests."
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=ef103b9d951e39ff7e23d386e2011fa3 \
-                    file://xf86driproto.h;endline=35;md5=42be3d8e6d429ab79172572bb0cff544"
-
-PE = "1"
-
-SRC_URI[md5sum] = "1d716d0dac3b664e5ee20c69d34bc10e"
-SRC_URI[sha256sum] = "9c4b8d7221cb6dc4309269ccc008a22753698ae9245a398a59df35f1404d661f"
diff --git a/poky/meta/recipes-graphics/xorg-proto/xf86miscproto_0.9.3.bb b/poky/meta/recipes-graphics/xorg-proto/xf86miscproto_0.9.3.bb
deleted file mode 100644
index d4663ea..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/xf86miscproto_0.9.3.bb
+++ /dev/null
@@ -1,17 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "XFree86-Misc: XFree86 miscellaneous extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the XFree \
-miscellaneous extension.  The XFree86-Misc extension provides a means to \
-access input device configuration settings specific to the XFree86/Xorg \
-DDX."
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=e01e66e4b317088cf869bc98e6af4fb6"
-
-PR = "r1"
-PE = "1"
-
-SRC_URI[md5sum] = "ca63bbb31cf5b7f37b2237e923ff257a"
-SRC_URI[sha256sum] = "45b8ec6a4a8ca21066dce117e09dcc88539862e616e60fb391de05b36f63b095"
diff --git a/poky/meta/recipes-graphics/xorg-proto/xf86vidmodeproto_2.3.1.bb b/poky/meta/recipes-graphics/xorg-proto/xf86vidmodeproto_2.3.1.bb
deleted file mode 100644
index 0f31900..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/xf86vidmodeproto_2.3.1.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "XFree86-VM: XFree86 video mode extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the XFree86 \
-video mode extension.  This extension allows client applications to get \
-and set video mode timings."
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=499be2ff387a42f84628c35f311f1502"
-
-RCONFLICTS_${PN} = "xxf86vmext"
-
-PR = "r1"
-PE = "1"
-
-SRC_URI[md5sum] = "e793ecefeaecfeabd1aed6a01095174e"
-SRC_URI[sha256sum] = "45d9499aa7b73203fd6b3505b0259624afed5c16b941bd04fcf123e5de698770"
diff --git a/poky/meta/recipes-graphics/xorg-proto/xineramaproto_1.2.1.bb b/poky/meta/recipes-graphics/xorg-proto/xineramaproto_1.2.1.bb
deleted file mode 100644
index dde7e9d..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/xineramaproto_1.2.1.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "Xinerama: Xinerama extension headers"
-
-DESCRIPTION = "This package provides the wire protocol for the Xinerama \
-extension.  This extension is used for retrieving information about \
-physical output devices which may be combined into a single logical X \
-screen."
-
-LICENSE = "MIT & MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=3e397a5326c83d5d0ebf5b3f87163ac6 \
-                    file://panoramiXproto.h;endline=24;md5=098e0bc089368a988092b3cbda617a57"
-
-PE = "1"
-
-SRC_URI[md5sum] = "9959fe0bfb22a0e7260433b8d199590a"
-SRC_URI[sha256sum] = "977574bb3dc192ecd9c55f59f991ec1dff340be3e31392c95deff423da52485b"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-graphics/xorg-proto/xorgproto/0001-Remove-libdir-specification.patch b/poky/meta/recipes-graphics/xorg-proto/xorgproto/0001-Remove-libdir-specification.patch
new file mode 100644
index 0000000..48296f7
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-proto/xorgproto/0001-Remove-libdir-specification.patch
@@ -0,0 +1,468 @@
+Upstream-Status: Submitted
+
+https://cgit.freedesktop.org/xorg/proto/xorgproto/commit/?id=91c1c8e1490c970379efb16784003426faec806e
+
+From 6feb974e0deb3355908c30e07293d82a3f6996ed Mon Sep 17 00:00:00 2001
+From: Jeremy Puhlman <jpuhlman@mvista.com>
+Date: Mon, 11 Jun 2018 16:42:43 +0000
+Subject: [PATCH] Remove libdir specification.
+
+Currently the pc files define libdir, however they are installed into
+/usr/share, which means they should be architecture agnostic. In a
+multilib system, xorg-proto built for each multilib abi, the value of
+libdir is going to be different. These should either be installed in
+<libdir>/pkgconfig or they shouldn't define libdir, espeically since
+they don't actually use the definition. This specifically causes an
+issue when trying to install both abis at the same time, since they are
+not binary identical, something like rpm will complain that they
+
+---
+ applewmproto.pc.in     | 1 -
+ bigreqsproto.pc.in     | 1 -
+ compositeproto.pc.in   | 1 -
+ damageproto.pc.in      | 1 -
+ dmxproto.pc.in         | 1 -
+ dri2proto.pc.in        | 1 -
+ dri3proto.pc.in        | 1 -
+ evieproto.pc.in        | 1 -
+ fixesproto.pc.in       | 1 -
+ fontcacheproto.pc.in   | 1 -
+ fontsproto.pc.in       | 1 -
+ glproto.pc.in          | 1 -
+ inputproto.pc.in       | 1 -
+ kbproto.pc.in          | 1 -
+ lg3dproto.pc.in        | 1 -
+ presentproto.pc.in     | 1 -
+ printproto.pc.in       | 1 -
+ randrproto.pc.in       | 1 -
+ recordproto.pc.in      | 1 -
+ renderproto.pc.in      | 1 -
+ resourceproto.pc.in    | 1 -
+ scrnsaverproto.pc.in   | 1 -
+ trapproto.pc.in        | 1 -
+ videoproto.pc.in       | 1 -
+ windowswmproto.pc.in   | 1 -
+ xcalibrateproto.pc.in  | 1 -
+ xcmiscproto.pc.in      | 1 -
+ xextproto.pc.in        | 1 -
+ xf86bigfontproto.pc.in | 1 -
+ xf86dgaproto.pc.in     | 1 -
+ xf86driproto.pc.in     | 1 -
+ xf86miscproto.pc.in    | 1 -
+ xf86rushproto.pc.in    | 1 -
+ xf86vidmodeproto.pc.in | 1 -
+ xineramaproto.pc.in    | 1 -
+ xproto.pc.in           | 1 -
+ xproxymngproto.pc.in   | 1 -
+ 37 files changed, 37 deletions(-)
+
+diff --git a/applewmproto.pc.in b/applewmproto.pc.in
+index 17841ac..3227b21 100644
+--- a/applewmproto.pc.in
++++ b/applewmproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: AppleWMProto
+diff --git a/bigreqsproto.pc.in b/bigreqsproto.pc.in
+index 94577ed..e21bb59 100644
+--- a/bigreqsproto.pc.in
++++ b/bigreqsproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: BigReqsProto
+diff --git a/compositeproto.pc.in b/compositeproto.pc.in
+index da429c7..b0dada1 100644
+--- a/compositeproto.pc.in
++++ b/compositeproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+ 
+ Name: CompositeExt
+diff --git a/damageproto.pc.in b/damageproto.pc.in
+index 6fd9ef1..bfd5244 100644
+--- a/damageproto.pc.in
++++ b/damageproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+ 
+ Name: DamageProto
+diff --git a/dmxproto.pc.in b/dmxproto.pc.in
+index e82ee7d..d140e1c 100644
+--- a/dmxproto.pc.in
++++ b/dmxproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: DMXProto
+diff --git a/dri2proto.pc.in b/dri2proto.pc.in
+index cb5b171..fa9d24d 100644
+--- a/dri2proto.pc.in
++++ b/dri2proto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: DRI2Proto
+diff --git a/dri3proto.pc.in b/dri3proto.pc.in
+index e42d60e..20da358 100644
+--- a/dri3proto.pc.in
++++ b/dri3proto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: DRI3Proto
+diff --git a/evieproto.pc.in b/evieproto.pc.in
+index 64e0ec4..fd5442b 100644
+--- a/evieproto.pc.in
++++ b/evieproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+ 
+ Name: EvIEExt
+diff --git a/fixesproto.pc.in b/fixesproto.pc.in
+index f8258e2..c7fcb81 100644
+--- a/fixesproto.pc.in
++++ b/fixesproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+ 
+ Name: FixesProto
+diff --git a/fontcacheproto.pc.in b/fontcacheproto.pc.in
+index eb4238b..8ffffe9 100644
+--- a/fontcacheproto.pc.in
++++ b/fontcacheproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: FontcacheProto
+diff --git a/fontsproto.pc.in b/fontsproto.pc.in
+index 9d22354..ebb61a4 100644
+--- a/fontsproto.pc.in
++++ b/fontsproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: FontsProto
+diff --git a/glproto.pc.in b/glproto.pc.in
+index b951db5..e97bfc9 100644
+--- a/glproto.pc.in
++++ b/glproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: GLProto
+diff --git a/inputproto.pc.in b/inputproto.pc.in
+index 1eb6619..270b95c 100644
+--- a/inputproto.pc.in
++++ b/inputproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: InputProto
+diff --git a/kbproto.pc.in b/kbproto.pc.in
+index bdd39f1..32a172d 100644
+--- a/kbproto.pc.in
++++ b/kbproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: KBProto
+diff --git a/lg3dproto.pc.in b/lg3dproto.pc.in
+index 3930ad7..43fba29 100644
+--- a/lg3dproto.pc.in
++++ b/lg3dproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: Lg3dProto
+diff --git a/presentproto.pc.in b/presentproto.pc.in
+index 6ec4b7d..55b84dc 100644
+--- a/presentproto.pc.in
++++ b/presentproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: PresentProto
+diff --git a/printproto.pc.in b/printproto.pc.in
+index 8a2e2d6..a2da66d 100644
+--- a/printproto.pc.in
++++ b/printproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+ 
+ Name: PrintProto
+diff --git a/randrproto.pc.in b/randrproto.pc.in
+index 5a5edb2..6d60cbb 100644
+--- a/randrproto.pc.in
++++ b/randrproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: RandrProto
+diff --git a/recordproto.pc.in b/recordproto.pc.in
+index 0ff4c0b..a87aa82 100644
+--- a/recordproto.pc.in
++++ b/recordproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: RecordProto
+diff --git a/renderproto.pc.in b/renderproto.pc.in
+index e6028ac..34b15e0 100644
+--- a/renderproto.pc.in
++++ b/renderproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+ 
+ Name: RenderProto
+diff --git a/resourceproto.pc.in b/resourceproto.pc.in
+index a409db9..f927cbb 100644
+--- a/resourceproto.pc.in
++++ b/resourceproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: ResourceProto
+diff --git a/scrnsaverproto.pc.in b/scrnsaverproto.pc.in
+index 6556a2c..fd9d368 100644
+--- a/scrnsaverproto.pc.in
++++ b/scrnsaverproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: ScrnSaverProto
+diff --git a/trapproto.pc.in b/trapproto.pc.in
+index 8cb0aa8..8a220b9 100644
+--- a/trapproto.pc.in
++++ b/trapproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: TrapProto
+diff --git a/videoproto.pc.in b/videoproto.pc.in
+index 14b907a..5c22f7a 100644
+--- a/videoproto.pc.in
++++ b/videoproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+ 
+ Name: VideoProto
+diff --git a/windowswmproto.pc.in b/windowswmproto.pc.in
+index 0a2ec0b..ec56e82 100644
+--- a/windowswmproto.pc.in
++++ b/windowswmproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: WindowsWMProto
+diff --git a/xcalibrateproto.pc.in b/xcalibrateproto.pc.in
+index 40b6fd0..f1ea5de 100644
+--- a/xcalibrateproto.pc.in
++++ b/xcalibrateproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+ 
+ Name: XCalibrate
+diff --git a/xcmiscproto.pc.in b/xcmiscproto.pc.in
+index 0dfbf21..b72bbc6 100644
+--- a/xcmiscproto.pc.in
++++ b/xcmiscproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: XCMiscProto
+diff --git a/xextproto.pc.in b/xextproto.pc.in
+index f66eeae..9419c91 100644
+--- a/xextproto.pc.in
++++ b/xextproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: XExtProto
+diff --git a/xf86bigfontproto.pc.in b/xf86bigfontproto.pc.in
+index 18c5647..4a67be6 100644
+--- a/xf86bigfontproto.pc.in
++++ b/xf86bigfontproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: XF86BigFontProto
+diff --git a/xf86dgaproto.pc.in b/xf86dgaproto.pc.in
+index 5c5f8b1..e029cd4 100644
+--- a/xf86dgaproto.pc.in
++++ b/xf86dgaproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: XF86DGAProto
+diff --git a/xf86driproto.pc.in b/xf86driproto.pc.in
+index 93df292..c8faf14 100644
+--- a/xf86driproto.pc.in
++++ b/xf86driproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: XF86DRIProto
+diff --git a/xf86miscproto.pc.in b/xf86miscproto.pc.in
+index af73fa3..05d5d9e 100644
+--- a/xf86miscproto.pc.in
++++ b/xf86miscproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: XF86MiscProto
+diff --git a/xf86rushproto.pc.in b/xf86rushproto.pc.in
+index fc5f63b..1c7ff1b 100644
+--- a/xf86rushproto.pc.in
++++ b/xf86rushproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: XF86RushProto
+diff --git a/xf86vidmodeproto.pc.in b/xf86vidmodeproto.pc.in
+index fcb74f2..ef062b3 100644
+--- a/xf86vidmodeproto.pc.in
++++ b/xf86vidmodeproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: XF86VidModeProto
+diff --git a/xineramaproto.pc.in b/xineramaproto.pc.in
+index 1ffd37d..9172f1e 100644
+--- a/xineramaproto.pc.in
++++ b/xineramaproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: XineramaProto
+diff --git a/xproto.pc.in b/xproto.pc.in
+index 8ff2d3d..899316a 100644
+--- a/xproto.pc.in
++++ b/xproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+ includex11dir=@includedir@/X11
+  
+diff --git a/xproxymngproto.pc.in b/xproxymngproto.pc.in
+index 5c6fad6..1a81e28 100644
+--- a/xproxymngproto.pc.in
++++ b/xproxymngproto.pc.in
+@@ -1,6 +1,5 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+-libdir=@libdir@
+ includedir=@includedir@
+  
+ Name: XProxyManagementProtocol
+-- 
+2.11.1
+
diff --git a/poky/meta/recipes-graphics/xorg-proto/xorgproto_2018.4.bb b/poky/meta/recipes-graphics/xorg-proto/xorgproto_2018.4.bb
new file mode 100644
index 0000000..cec6e87
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-proto/xorgproto_2018.4.bb
@@ -0,0 +1,16 @@
+require xorg-proto-common.inc
+
+SUMMARY = "XCalibrate: Touchscreen calibration headers"
+
+DESCRIPTION = "This package provides the headers and specification documents defining \
+the core protocol and (many) extensions for the X Window System"
+
+LICENSE = "MIT-style"
+LIC_FILES_CHKSUM = "file://COPYING-x11proto;md5=b9e051107d5628966739a0b2e9b32676"
+
+SRC_URI += "file://0001-Remove-libdir-specification.patch"
+
+SRC_URI[md5sum] = "81557ca47ee66a4e54590fcdadd28114"
+SRC_URI[sha256sum] = "fee885e0512899ea5280c593fdb2735beb1693ad170c22ebcc844470eec415a0"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-graphics/xorg-proto/xproto/xproto_fix_for_x32.patch b/poky/meta/recipes-graphics/xorg-proto/xproto/xproto_fix_for_x32.patch
deleted file mode 100644
index 4f9ed99..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/xproto/xproto_fix_for_x32.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-Upstream-Status: Pending
-
-Don't always define LONG64 for AMD64
-    
-X32 defines __amd64__/amd64 with 32bit long.  We should simply check
-__LP64__ before defining LONG64 without checking __amd64__/amd64.
-
-This fixes compilation with x32 toolchain.
-
-Received this patch from H.J. Lu <hjl.tools@gmail.com>
-Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com> 2011/12/1
-
-Index: xproto-7.0.31/Xmd.h
-===================================================================
---- xproto-7.0.31.orig/Xmd.h
-+++ xproto-7.0.31/Xmd.h
-@@ -62,7 +62,6 @@ SOFTWARE.
-      defined(__ia64__) || defined(ia64) || \
-      defined(__sparc64__) || \
-      defined(__s390x__) || \
--     defined(__amd64__) || defined(amd64) || \
-      defined(__powerpc64__)
- #  if !defined(__ILP32__) /* amd64-x32 is 32bit */
- #   define LONG64				/* 32/64-bit architecture */
diff --git a/poky/meta/recipes-graphics/xorg-proto/xproto_7.0.31.bb b/poky/meta/recipes-graphics/xorg-proto/xproto_7.0.31.bb
deleted file mode 100644
index febcc67..0000000
--- a/poky/meta/recipes-graphics/xorg-proto/xproto_7.0.31.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-require xorg-proto-common.inc
-
-SUMMARY = "Xlib: C Language X interface headers"
-
-DESCRIPTION = "This package provides the basic headers for the X Window \
-System."
-
-LICENSE = "MIT & MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b9e051107d5628966739a0b2e9b32676"
-
-PE = "1"
-
-SRC_URI += "file://xproto_fix_for_x32.patch"
-
-EXTRA_OECONF_append = " --enable-specs=no"
-BBCLASSEXTEND = "native nativesdk"
-
-SRC_URI[md5sum] = "16791f7ca8c51a20608af11702e51083"
-SRC_URI[sha256sum] = "c6f9747da0bd3a95f86b17fb8dd5e717c8f3ab7f0ece3ba1b247899ec1ef7747"
diff --git a/poky/meta/recipes-graphics/xorg-util/gccmakedep_1.0.3.bb b/poky/meta/recipes-graphics/xorg-util/gccmakedep_1.0.3.bb
deleted file mode 100644
index be3a667..0000000
--- a/poky/meta/recipes-graphics/xorg-util/gccmakedep_1.0.3.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-SUMMARY = "Program to create dependencies in makefiles"
-
-DESCRIPTION = "The gccmakedep program calls 'gcc -M' to output makefile \
-rules describing the dependencies of each sourcefile, so that make knows \
-which object files must be recompiled when a dependency has changed."
-
-require xorg-util-common.inc
-LIC_FILES_CHKSUM = "file://Makefile.am;endline=20;md5=23c277396d690413245ebb89b18c5d4d"
-DESCRIPTION = "create dependencies in makefiles using 'gcc -M'"
-DEPENDS = "util-macros"
-RDEPENDS_${PN} = "gcc"
-
-PR = "r3"
-PE = "1"
-
-SRC_URI[md5sum] = "127ddb6131eb4a56fdf6644a63ade788"
-SRC_URI[sha256sum] = "f9e2e7a590e27f84b6708ab7a81e546399b949bf652fb9b95193e0e543e6a548"
-
-do_install_append() {
-	sed -i "s,--sysroot=${STAGING_DIR_TARGET},," ${D}${bindir}/gccmakedep
-}
diff --git a/poky/meta/recipes-graphics/xorg-util/makedepend_1.0.5.bb b/poky/meta/recipes-graphics/xorg-util/makedepend_1.0.5.bb
index 84a967a..727ab54 100644
--- a/poky/meta/recipes-graphics/xorg-util/makedepend_1.0.5.bb
+++ b/poky/meta/recipes-graphics/xorg-util/makedepend_1.0.5.bb
@@ -10,7 +10,7 @@
 can reference files having other #include directives, and parsing will \
 occur in these files as well."
 
-DEPENDS = "xproto util-macros"
+DEPENDS = "xorgproto util-macros"
 PE = "1"
 
 BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-graphics/xorg-util/util-macros_1.19.1.bb b/poky/meta/recipes-graphics/xorg-util/util-macros_1.19.1.bb
deleted file mode 100644
index b39d787..0000000
--- a/poky/meta/recipes-graphics/xorg-util/util-macros_1.19.1.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-SUMMARY = "X autotools macros"
-
-DESCRIPTION = "M4 autotools macros used by various X.org programs."
-
-require xorg-util-common.inc
-
-LICENSE = "MIT & MIT-style"
-LIC_FILES_CHKSUM = "file://COPYING;md5=1970511fddd439b07a6ba789d28ff662"
-
-PE = "1"
-
-SRC_URI[md5sum] = "3f8a8e6100556f7f28e469809805dee8"
-SRC_URI[sha256sum] = "472ad0e41d1e0abf5ecafd29460bf1b8d47e53d4b7d3abf1f66d02dc576547b8"
-
-# ${PN} is empty so we need to tweak -dev and -dbg package dependencies
-RDEPENDS_${PN}-dev = ""
-RRECOMMENDS_${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-graphics/xorg-util/util-macros_1.19.2.bb b/poky/meta/recipes-graphics/xorg-util/util-macros_1.19.2.bb
new file mode 100644
index 0000000..2680599
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-util/util-macros_1.19.2.bb
@@ -0,0 +1,19 @@
+SUMMARY = "X autotools macros"
+
+DESCRIPTION = "M4 autotools macros used by various X.org programs."
+
+require xorg-util-common.inc
+
+LICENSE = "MIT & MIT-style"
+LIC_FILES_CHKSUM = "file://COPYING;md5=1970511fddd439b07a6ba789d28ff662"
+
+PE = "1"
+
+SRC_URI[md5sum] = "5059b328fac086b733ffac6607164c41"
+SRC_URI[sha256sum] = "9225c45c3de60faf971979a55a5536f3562baa4b6f02246c23e98ac0c09a75b7"
+
+# ${PN} is empty so we need to tweak -dev and -dbg package dependencies
+RDEPENDS_${PN}-dev = ""
+RRECOMMENDS_${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-graphics/xorg-xserver/xserver-xf86-config/qemumips64/xorg.conf b/poky/meta/recipes-graphics/xorg-xserver/xserver-xf86-config/qemumips64/xorg.conf
index f4cd139..03b94dc 100644
--- a/poky/meta/recipes-graphics/xorg-xserver/xserver-xf86-config/qemumips64/xorg.conf
+++ b/poky/meta/recipes-graphics/xorg-xserver/xserver-xf86-config/qemumips64/xorg.conf
@@ -26,6 +26,7 @@
     Identifier    "Default Screen"
     Device        "Graphics Controller"
     Monitor        "Generic Monitor"
+    DefaultDepth    16
     SubSection "Display"
         Modes     "640x480"
     EndSubSection
diff --git a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg.inc b/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg.inc
index cf2286c..489a428 100644
--- a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg.inc
+++ b/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg.inc
@@ -17,7 +17,6 @@
 
 XORG_PN = "xorg-server"
 SRC_URI = "${XORG_MIRROR}/individual/xserver/${XORG_PN}-${PV}.tar.bz2"
-SRC_URI += "file://macro_tweak.patch"
 
 S = "${WORKDIR}/${XORG_PN}-${PV}"
 
@@ -26,7 +25,7 @@
 inherit distro_features_check
 REQUIRED_DISTRO_FEATURES = "x11"
 
-PROTO_DEPS = "randrproto renderproto fixesproto damageproto xextproto xproto xf86dgaproto xf86miscproto xf86vidmodeproto compositeproto recordproto resourceproto videoproto scrnsaverproto  xineramaproto fontsproto kbproto inputproto bigreqsproto xcmiscproto presentproto"
+PROTO_DEPS = "xorgproto"
 LIB_DEPS = "pixman libxfont2 xtrans libxau libxext libxdmcp libdrm libxkbfile libpciaccess"
 DEPENDS = "${PROTO_DEPS} ${LIB_DEPS} font-util"
 
@@ -123,22 +122,22 @@
 PACKAGECONFIG ??= "dri2 udev ${XORG_CRYPTO} \
                    ${@bb.utils.contains('DISTRO_FEATURES', 'opengl', '${OPENGL_PKGCONFIGS}', '', d)} \
                    ${@bb.utils.contains('DISTRO_FEATURES', 'opengl wayland', 'xwayland', '', d)} \
-                   ${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} \
+                   ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd systemd-logind', '', d)} \
 "
 
 PACKAGECONFIG[udev] = "--enable-config-udev,--disable-config-udev,udev"
-PACKAGECONFIG[dri] = "--enable-dri,--disable-dri,glproto virtual/mesa xf86driproto"
-PACKAGECONFIG[dri2] = "--enable-dri2,--disable-dri2,dri2proto"
+PACKAGECONFIG[dri] = "--enable-dri,--disable-dri,xorgproto virtual/mesa"
+PACKAGECONFIG[dri2] = "--enable-dri2,--disable-dri2,xorgproto"
 # DRI3 requires xshmfence to also be enabled
-PACKAGECONFIG[dri3] = "--enable-dri3,--disable-dri3,dri3proto"
-PACKAGECONFIG[glx] = "--enable-glx,--disable-glx,glproto virtual/libgl virtual/libx11"
+PACKAGECONFIG[dri3] = "--enable-dri3,--disable-dri3,xorgproto"
+PACKAGECONFIG[glx] = "--enable-glx,--disable-glx,xorgproto virtual/libgl virtual/libx11"
 PACKAGECONFIG[glamor] = "--enable-glamor,--disable-glamor,libepoxy virtual/libgbm,libegl"
 PACKAGECONFIG[unwind] = "--enable-libunwind,--disable-libunwind,libunwind"
 PACKAGECONFIG[xshmfence] = "--enable-xshmfence,--disable-xshmfence,libxshmfence"
 PACKAGECONFIG[xmlto] = "--with-xmlto, --without-xmlto, xmlto-native docbook-xml-dtd4-native docbook-xsl-stylesheets-native"
 PACKAGECONFIG[systemd-logind] = "--enable-systemd-logind=yes,--enable-systemd-logind=no,dbus,"
 PACKAGECONFIG[systemd] = "--with-systemd-daemon,--without-systemd-daemon,systemd"
-PACKAGECONFIG[xinerama] = "--enable-xinerama,--disable-xinerama,xineramaproto"
+PACKAGECONFIG[xinerama] = "--enable-xinerama,--disable-xinerama,xorgproto"
 PACKAGECONFIG[xwayland] = "--enable-xwayland,--disable-xwayland,wayland wayland-native wayland-protocols libepoxy"
 
 # Xorg requires a SHA1 implementation, pick one
diff --git a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-config-fix-NULL-value-detection-for-ID_INPUT-being-u.patch b/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-config-fix-NULL-value-detection-for-ID_INPUT-being-u.patch
deleted file mode 100644
index 964d5dd..0000000
--- a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-config-fix-NULL-value-detection-for-ID_INPUT-being-u.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From a309323328d9d6e0bf5d9ea1d75920e53b9beef3 Mon Sep 17 00:00:00 2001
-From: Peter Hutterer <peter.hutterer@who-t.net>
-Date: Fri, 5 Jan 2018 11:58:42 +1000
-Subject: [PATCH] config: fix NULL value detection for ID_INPUT being unset
-
-Erroneous condition caused us to keep going with all devices that didn't have
-ID_INPUT set.
-
-Fixes: 5aad81445c8c3d6
-Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=104382
-Reviewed-by: Adam Jackson <ajax@redhat.com>
-Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-
-Upstream-status: Backport
-https://patchwork.freedesktop.org/patch/196090/
-Affects: < 1.20.0
-[Yocto # 12899]
-
-Signed-off-by: Armin Kuster <akuser808@gmail.com>
-
----
- config/udev.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/config/udev.c b/config/udev.c
-index e198e8609..3a73189e2 100644
---- a/config/udev.c
-+++ b/config/udev.c
-@@ -135,7 +135,7 @@ device_added(struct udev_device *udev_device)
- #endif
- 
-     value = udev_device_get_property_value(udev_device, "ID_INPUT");
--    if (value && !strcmp(value, "0")) {
-+    if (!value || !strcmp(value, "0")) {
-         LogMessageVerb(X_INFO, 10,
-                        "config/udev: ignoring device %s without "
-                        "property ID_INPUT set\n", path);
--- 
-2.17.1
-
diff --git a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-configure.ac-Fix-check-for-CLOCK_MONOTONIC.patch b/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-configure.ac-Fix-check-for-CLOCK_MONOTONIC.patch
deleted file mode 100644
index 16ec3ed..0000000
--- a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/0001-configure.ac-Fix-check-for-CLOCK_MONOTONIC.patch
+++ /dev/null
@@ -1,61 +0,0 @@
-Discover monotonic clock using compile-time check
-
-monotonic clock check does not work when cross-compiling.
-
-Upstream-Status: Denied [Does not work on OpenBSD]
-Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
-
-
-
-Original patch follows:
-
-When xorg-xserver is being cross-compiled, there is currently no way
-for us to detect whether the monotonic clock is available on the
-target system, because we aren't able to run a test program on the host
-system. Currently, in this situation, we default to not use the
-monotonic clock. One problem with this situation is that the user will
-be treated as idle when the date is updated.
-
-To fix this situation, we now use a compile-time check to detect whether the
-monotonic clock is available. This check can run just fine when we are
-cross-compiling.
-
-Signed-off-by: David James <davidjames at google.com>
----
- configure.ac | 17 +++++++----------
- 1 file changed, 7 insertions(+), 10 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index f7ab48c..26e85cd 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -1048,19 +1048,16 @@ if ! test "x$have_clock_gettime" = xno; then
-         CPPFLAGS="$CPPFLAGS -D_POSIX_C_SOURCE=200112L"
-     fi
- 
--    AC_RUN_IFELSE([AC_LANG_SOURCE([
-+    AC_COMPILE_IFELSE([AC_LANG_SOURCE([[
- #include <time.h>
--
--int main(int argc, char *argv[[]]) {
--    struct timespec tp;
--
--    if (clock_gettime(CLOCK_MONOTONIC, &tp) == 0)
-+#include <unistd.h>
-+int main() {
-+#if !(defined(_POSIX_MONOTONIC_CLOCK) && _POSIX_MONOTONIC_CLOCK >= 0 && defined(CLOCK_MONOTONIC))
-+        #error No monotonic clock
-+#endif
-         return 0;
--    else
--        return 1;
- }
--    ])], [MONOTONIC_CLOCK=yes], [MONOTONIC_CLOCK=no],
--       [MONOTONIC_CLOCK="cross compiling"])
-+]])],[MONOTONIC_CLOCK=yes], [MONOTONIC_CLOCK=no])
- 
-     LIBS="$LIBS_SAVE"
-     CPPFLAGS="$CPPFLAGS_SAVE"
--- 
-2.1.4
-
diff --git a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/0003-Remove-check-for-useSIGIO-option.patch b/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/0003-Remove-check-for-useSIGIO-option.patch
deleted file mode 100644
index beed6cb..0000000
--- a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/0003-Remove-check-for-useSIGIO-option.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From cf407b16cd65ad6e26a9c8e5984e163409a5c0f7 Mon Sep 17 00:00:00 2001
-From: Prabhu Sundararaj <prabhu.sundararaj@nxp.com>
-Date: Mon, 30 Jan 2017 16:32:06 -0600
-Subject: [PATCH] Remove check for useSIGIO option
-
-Commit 6a5a4e60373c1386b311b2a8bb666c32d68a9d99 removes the configure of useSIGIO
-option.
-
-As the xfree86 SIGIO support is reworked to use internal versions of OsBlockSIGIO
-and OsReleaseSIGIO.
-
-No longer the check for useSIGIO is needed
-
-Upstream-Status: Pending
-
-Signed-off-by: Prabhu Sundararaj <prabhu.sundararaj@nxp.com>
----
- hw/xfree86/os-support/shared/sigio.c | 6 ------
- 1 file changed, 6 deletions(-)
-
-diff --git a/hw/xfree86/os-support/shared/sigio.c b/hw/xfree86/os-support/shared/sigio.c
-index 884a71c..be76498 100644
---- a/hw/xfree86/os-support/shared/sigio.c
-+++ b/hw/xfree86/os-support/shared/sigio.c
-@@ -185,9 +185,6 @@ xf86InstallSIGIOHandler(int fd, void (*f) (int, void *), void *closure)
-     int i;
-     int installed = FALSE;
- 
--    if (!xf86Info.useSIGIO)
--        return 0;
--
-     for (i = 0; i < MAX_FUNCS; i++) {
-         if (!xf86SigIOFuncs[i].f) {
-             if (xf86IsPipe(fd))
-@@ -256,9 +253,6 @@ xf86RemoveSIGIOHandler(int fd)
-     int max;
-     int ret;
- 
--    if (!xf86Info.useSIGIO)
--        return 0;
--
-     max = 0;
-     ret = 0;
-     for (i = 0; i < MAX_FUNCS; i++) {
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/0003-modesetting-Fix-16-bit-depth-bpp-mode.patch b/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/0003-modesetting-Fix-16-bit-depth-bpp-mode.patch
deleted file mode 100644
index 5243761..0000000
--- a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/0003-modesetting-Fix-16-bit-depth-bpp-mode.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-From 5028ef46ff4ab0930224b71024a7349b05610d42 Mon Sep 17 00:00:00 2001
-From: Stefan Agner <stefan@agner.ch>
-Date: Thu, 22 Dec 2016 15:41:06 +0100
-Subject: [PATCH] modesetting: Fix 16 bit depth/bpp mode
-
-When setting DefaultDepth to 16 in the Screen section, the current
-code requests a 32 bpp framebuffer, however the X-Server seems to
-assumes 16 bpp.
-
-Fixes commit 21217d02168d ("modesetting: Implement 32->24 bpp
-conversion in shadow update")
-
-Signed-off-by: Stefan Agner <stefan@agner.ch>
-
-Upstream-Status: Submitted [1]
-
-[1] https://lists.x.org/archives/xorg-devel/2016-December/052113.html
----
- hw/xfree86/drivers/modesetting/driver.c | 4 +++-
- 1 file changed, 3 insertions(+), 1 deletion(-)
-
-diff --git a/hw/xfree86/drivers/modesetting/driver.c b/hw/xfree86/drivers/modesetting/driver.c
-index d7030e5..647ad83 100644
---- a/hw/xfree86/drivers/modesetting/driver.c
-+++ b/hw/xfree86/drivers/modesetting/driver.c
-@@ -930,7 +930,7 @@ PreInit(ScrnInfoPtr pScrn, int flags)
-                    "Using 24bpp hw front buffer with 32bpp shadow\n");
-         defaultbpp = 32;
-     } else {
--        ms->drmmode.kbpp = defaultbpp;
-+        ms->drmmode.kbpp = 0;
-     }
-     bppflags = PreferConvert24to32 | SupportConvert24to32 | Support32bppFb;
- 
-@@ -950,6 +950,8 @@ PreInit(ScrnInfoPtr pScrn, int flags)
-         return FALSE;
-     }
-     xf86PrintDepthBpp(pScrn);
-+    if (!ms->drmmode.kbpp)
-+        ms->drmmode.kbpp = pScrn->bitsPerPixel;
- 
-     /* Process the options */
-     xf86CollectOptions(pScrn, NULL);
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2018-14665.patch b/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2018-14665.patch
new file mode 100644
index 0000000..7f6235b
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/CVE-2018-14665.patch
@@ -0,0 +1,62 @@
+Incorrect command-line parameter validation in the Xorg X server can lead to
+privilege elevation and/or arbitrary files overwrite, when the X server is
+running with elevated privileges (ie when Xorg is installed with the setuid bit
+set and started by a non-root user). The -modulepath argument can be used to
+specify an insecure path to modules that are going to be loaded in the X server,
+allowing to execute unprivileged code in the privileged process. The -logfile
+argument can be used to overwrite arbitrary files in the file system, due to
+incorrect checks in the parsing of the option.
+
+CVE: CVE-2018-14665
+Upstream-Status: Backport
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+From 50c0cf885a6e91c0ea71fb49fa8f1b7c86fe330e Mon Sep 17 00:00:00 2001
+From: Matthieu Herrb <matthieu@herrb.eu>
+Date: Tue, 23 Oct 2018 21:29:08 +0200
+Subject: [PATCH] Disable -logfile and -modulepath when running with elevated
+ privileges
+
+Could cause privilege elevation and/or arbitrary files overwrite, when
+the X server is running with elevated privileges (ie when Xorg is
+installed with the setuid bit set and started by a non-root user).
+
+CVE-2018-14665
+
+Issue reported by Narendra Shinde and Red Hat.
+
+Signed-off-by: Matthieu Herrb <matthieu@herrb.eu>
+Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
+Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
+Reviewed-by: Adam Jackson <ajax@redhat.com>
+---
+ hw/xfree86/common/xf86Init.c | 8 ++++++--
+ 1 file changed, 6 insertions(+), 2 deletions(-)
+
+diff --git a/hw/xfree86/common/xf86Init.c b/hw/xfree86/common/xf86Init.c
+index 6c25eda73..0f57efa86 100644
+--- a/hw/xfree86/common/xf86Init.c
++++ b/hw/xfree86/common/xf86Init.c
+@@ -935,14 +935,18 @@ ddxProcessArgument(int argc, char **argv, int i)
+     /* First the options that are not allowed with elevated privileges */
+     if (!strcmp(argv[i], "-modulepath")) {
+         CHECK_FOR_REQUIRED_ARGUMENT();
+-        xf86CheckPrivs(argv[i], argv[i + 1]);
++        if (xf86PrivsElevated())
++              FatalError("\nInvalid argument -modulepath "
++                "with elevated privileges\n");
+         xf86ModulePath = argv[i + 1];
+         xf86ModPathFrom = X_CMDLINE;
+         return 2;
+     }
+     if (!strcmp(argv[i], "-logfile")) {
+         CHECK_FOR_REQUIRED_ARGUMENT();
+-        xf86CheckPrivs(argv[i], argv[i + 1]);
++        if (xf86PrivsElevated())
++              FatalError("\nInvalid argument -logfile "
++                "with elevated privileges\n");
+         xf86LogFile = argv[i + 1];
+         xf86LogFileFrom = X_CMDLINE;
+         return 2;
+-- 
+2.18.1
diff --git a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/macro_tweak.patch b/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/macro_tweak.patch
deleted file mode 100644
index c36e4e7..0000000
--- a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/macro_tweak.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-This is the revised version of files/macro_tweak.patch for
-xorg-server 1.8.99.904 and newer.
-
-Upstream-Status: Pending
-
-Signed-off-by: Yu Ke <ke.yu@intel.com>
-
-Index: xorg-server-1.19.6/xorg-server.m4
-===================================================================
---- xorg-server-1.19.6.orig/xorg-server.m4
-+++ xorg-server-1.19.6/xorg-server.m4
-@@ -28,10 +28,12 @@ dnl
- # Checks for the MACRO define in xorg-server.h (from the sdk).  If it
- # is defined, then add the given PROTO to $REQUIRED_MODULES.
- 
-+m4_pattern_allow(PKG_CONFIG_SYSROOT_DIR)
-+
- AC_DEFUN([XORG_DRIVER_CHECK_EXT],[
- 	AC_REQUIRE([PKG_PROG_PKG_CONFIG])
- 	SAVE_CFLAGS="$CFLAGS"
--	CFLAGS="$CFLAGS -I`$PKG_CONFIG --variable=sdkdir xorg-server`"
-+	CFLAGS="$CFLAGS -I$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=sdkdir xorg-server`"
- 	AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
- #include "xorg-server.h"
- #if !defined $1
diff --git a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/pkgconfig.patch b/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/pkgconfig.patch
new file mode 100644
index 0000000..2ef9fa9
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg/pkgconfig.patch
@@ -0,0 +1,34 @@
+Upstream-Status: Submitted [https://gitlab.freedesktop.org/xorg/xserver/merge_requests/22]
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+From 5f65a6246fe752764045dd1e38912f1dccec71e4 Mon Sep 17 00:00:00 2001
+From: Ross Burton <ross.burton@intel.com>
+Date: Thu, 20 Sep 2018 20:12:24 +0100
+Subject: [PATCH] xorg-server.m4: just all cflags instead of just sdkdir
+
+Instead of fetching just the sdkdir variable of xorg-server using pkg-config,
+simply get all of the CFLAGS.  Aside from completeness, this helps builds in
+sysroots as pkg-config knows what to do with --cflags but doesn't remap
+arbitrary variables.
+
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+---
+ xorg-server.m4 | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/xorg-server.m4 b/xorg-server.m4
+index 18255b91a..195bda5d8 100644
+--- a/xorg-server.m4
++++ b/xorg-server.m4
+@@ -31,7 +31,7 @@ dnl
+ AC_DEFUN([XORG_DRIVER_CHECK_EXT],[
+ 	AC_REQUIRE([PKG_PROG_PKG_CONFIG])
+ 	SAVE_CFLAGS="$CFLAGS"
+-	CFLAGS="$CFLAGS -I`$PKG_CONFIG --variable=sdkdir xorg-server`"
++	CFLAGS="$CFLAGS `$PKG_CONFIG --cflags xorg-server`"
+ 	AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
+ #include "xorg-server.h"
+ #if !defined $1
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg_1.19.6.bb b/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg_1.19.6.bb
deleted file mode 100644
index 7e8a954..0000000
--- a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg_1.19.6.bb
+++ /dev/null
@@ -1,33 +0,0 @@
-require xserver-xorg.inc
-
-SRC_URI += "file://musl-arm-inb-outb.patch \
-            file://0001-configure.ac-Fix-check-for-CLOCK_MONOTONIC.patch \
-            file://0003-modesetting-Fix-16-bit-depth-bpp-mode.patch \
-            file://0003-Remove-check-for-useSIGIO-option.patch \
-            file://0001-xf86pciBus.c-use-Intel-ddx-only-for-pre-gen4-hardwar.patch \
-            file://0001-config-fix-NULL-value-detection-for-ID_INPUT-being-u.patch \
-            "
-SRC_URI[md5sum] = "3e47777ff034a331aed2322b078694a8"
-SRC_URI[sha256sum] = "a732502f1db000cf36a376cd0c010ffdbf32ecdd7f1fa08ba7f5bdf9601cc197"
-
-# These extensions are now integrated into the server, so declare the migration
-# path for in-place upgrades.
-
-RREPLACES_${PN} =  "${PN}-extension-dri \
-                    ${PN}-extension-dri2 \
-                    ${PN}-extension-record \
-                    ${PN}-extension-extmod \
-                    ${PN}-extension-dbe \
-                   "
-RPROVIDES_${PN} =  "${PN}-extension-dri \
-                    ${PN}-extension-dri2 \
-                    ${PN}-extension-record \
-                    ${PN}-extension-extmod \
-                    ${PN}-extension-dbe \
-                   "
-RCONFLICTS_${PN} = "${PN}-extension-dri \
-                    ${PN}-extension-dri2 \
-                    ${PN}-extension-record \
-                    ${PN}-extension-extmod \
-                    ${PN}-extension-dbe \
-                   "
diff --git a/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg_1.20.1.bb b/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg_1.20.1.bb
new file mode 100644
index 0000000..9fd2e8d
--- /dev/null
+++ b/poky/meta/recipes-graphics/xorg-xserver/xserver-xorg_1.20.1.bb
@@ -0,0 +1,31 @@
+require xserver-xorg.inc
+
+SRC_URI += "file://musl-arm-inb-outb.patch \
+            file://0001-xf86pciBus.c-use-Intel-ddx-only-for-pre-gen4-hardwar.patch \
+            file://pkgconfig.patch \
+            file://CVE-2018-14665.patch \
+            "
+SRC_URI[md5sum] = "e525846d1d0af5732ba835f2e2ec066d"
+SRC_URI[sha256sum] = "59c99fe86fe75b8164c6567bfc6e982aecc2e4a51e6fbac1b842d5d00549e918"
+
+# These extensions are now integrated into the server, so declare the migration
+# path for in-place upgrades.
+
+RREPLACES_${PN} =  "${PN}-extension-dri \
+                    ${PN}-extension-dri2 \
+                    ${PN}-extension-record \
+                    ${PN}-extension-extmod \
+                    ${PN}-extension-dbe \
+                   "
+RPROVIDES_${PN} =  "${PN}-extension-dri \
+                    ${PN}-extension-dri2 \
+                    ${PN}-extension-record \
+                    ${PN}-extension-extmod \
+                    ${PN}-extension-dbe \
+                   "
+RCONFLICTS_${PN} = "${PN}-extension-dri \
+                    ${PN}-extension-dri2 \
+                    ${PN}-extension-record \
+                    ${PN}-extension-extmod \
+                    ${PN}-extension-dbe \
+                   "
diff --git a/poky/meta/recipes-kernel/cryptodev/cryptodev-module_1.9.bb b/poky/meta/recipes-kernel/cryptodev/cryptodev-module_1.9.bb
index 6052650..ed4327d 100644
--- a/poky/meta/recipes-kernel/cryptodev/cryptodev-module_1.9.bb
+++ b/poky/meta/recipes-kernel/cryptodev/cryptodev-module_1.9.bb
@@ -11,6 +11,9 @@
 file://0001-Disable-installing-header-file-provided-by-another-p.patch \
 file://0001-ioctl.c-Fix-build-with-linux-4.13.patch \
 file://0001-ioctl.c-Fix-build-with-linux-4.17.patch \
+file://0001-refactoring-split-big-function-to-simplify-maintaina.patch \
+file://0002-refactoring-relocate-code-to-simplify-later-patches.patch \
+file://0003-convert-to-new-AEAD-interface-in-kernels-v4.2.patch \
 "
 
 EXTRA_OEMAKE='KERNEL_DIR="${STAGING_KERNEL_DIR}" PREFIX="${D}"'
diff --git a/poky/meta/recipes-kernel/cryptodev/cryptodev-tests_1.9.bb b/poky/meta/recipes-kernel/cryptodev/cryptodev-tests_1.9.bb
index 9afb3de..617db6c 100644
--- a/poky/meta/recipes-kernel/cryptodev/cryptodev-tests_1.9.bb
+++ b/poky/meta/recipes-kernel/cryptodev/cryptodev-tests_1.9.bb
@@ -2,10 +2,11 @@
 
 SUMMARY = "A test suite for /dev/crypto device driver"
 
-DEPENDS += "openssl10"
+DEPENDS += "openssl"
 
 SRC_URI += " \
 file://0001-Add-the-compile-and-install-rules-for-cryptodev-test.patch \
+file://0001-Port-tests-to-openssl-1.1.patch \
 "
 
 EXTRA_OEMAKE='KERNEL_DIR="${STAGING_EXECPREFIXDIR}" PREFIX="${D}"'
diff --git a/poky/meta/recipes-kernel/cryptodev/files/0001-Port-tests-to-openssl-1.1.patch b/poky/meta/recipes-kernel/cryptodev/files/0001-Port-tests-to-openssl-1.1.patch
new file mode 100644
index 0000000..c969126
--- /dev/null
+++ b/poky/meta/recipes-kernel/cryptodev/files/0001-Port-tests-to-openssl-1.1.patch
@@ -0,0 +1,103 @@
+From 2fe4bdeb8cdd0b0f46d9caed807812855d51ea56 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Wed, 28 Mar 2018 20:11:05 +0300
+Subject: [PATCH] Port tests to openssl 1.1
+
+Upstream-Status: Accepted [https://github.com/cryptodev-linux/cryptodev-linux/pull/36]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+---
+ tests/openssl_wrapper.c | 33 +++++++++++++++++++++++++++++++++
+ 1 file changed, 33 insertions(+)
+
+diff --git a/tests/openssl_wrapper.c b/tests/openssl_wrapper.c
+index 038c58f..dea2496 100644
+--- a/tests/openssl_wrapper.c
++++ b/tests/openssl_wrapper.c
+@@ -4,6 +4,7 @@
+ #include <openssl/aes.h>
+ #include <openssl/evp.h>
+ #include <openssl/hmac.h>
++#include <openssl/opensslv.h>
+ 
+ //#define DEBUG
+ 
+@@ -23,10 +24,17 @@ enum ctx_type {
+ 	ctx_type_md,
+ };
+ 
++#if OPENSSL_VERSION_NUMBER >= 0x10100000L
++union openssl_ctx {
++	HMAC_CTX *hmac;
++	EVP_MD_CTX *md;
++};
++#else
+ union openssl_ctx {
+ 	HMAC_CTX hmac;
+ 	EVP_MD_CTX md;
+ };
++#endif
+ 
+ struct ctx_mapping {
+ 	__u32 ses;
+@@ -63,6 +71,16 @@ static void remove_mapping(__u32 ses)
+ 	switch (mapping->type) {
+ 	case ctx_type_none:
+ 		break;
++#if OPENSSL_VERSION_NUMBER >= 0x10100000L
++	case ctx_type_hmac:
++		dbgp("%s: calling HMAC_CTX_free\n", __func__);
++		HMAC_CTX_free(mapping->ctx.hmac);
++		break;
++	case ctx_type_md:
++		dbgp("%s: calling EVP_MD_CTX_free\n", __func__);
++		EVP_MD_CTX_free(mapping->ctx.md);
++		break;
++#else
+ 	case ctx_type_hmac:
+ 		dbgp("%s: calling HMAC_CTX_cleanup\n", __func__);
+ 		HMAC_CTX_cleanup(&mapping->ctx.hmac);
+@@ -71,6 +89,7 @@ static void remove_mapping(__u32 ses)
+ 		dbgp("%s: calling EVP_MD_CTX_cleanup\n", __func__);
+ 		EVP_MD_CTX_cleanup(&mapping->ctx.md);
+ 		break;
++#endif
+ 	}
+ 	memset(mapping, 0, sizeof(*mapping));
+ }
+@@ -127,10 +146,17 @@ static int openssl_hmac(struct session_op *sess, struct crypt_op *cop)
+ 
+ 		mapping->ses = sess->ses;
+ 		mapping->type = ctx_type_hmac;
++#if OPENSSL_VERSION_NUMBER >= 0x10100000L
++		ctx = mapping->ctx.hmac;
++
++		dbgp("calling HMAC_CTX_new");
++		ctx = HMAC_CTX_new();
++#else
+ 		ctx = &mapping->ctx.hmac;
+ 
+ 		dbgp("calling HMAC_CTX_init");
+ 		HMAC_CTX_init(ctx);
++#endif
+ 		dbgp("calling HMAC_Init_ex");
+ 		if (!HMAC_Init_ex(ctx, sess->mackey, sess->mackeylen,
+ 				sess_to_evp_md(sess), NULL)) {
+@@ -172,10 +198,17 @@ static int openssl_md(struct session_op *sess, struct crypt_op *cop)
+ 
+ 		mapping->ses = sess->ses;
+ 		mapping->type = ctx_type_md;
++#if OPENSSL_VERSION_NUMBER >= 0x10100000L
++		ctx = mapping->ctx.md;
++
++		dbgp("calling EVP_MD_CTX_new");
++		ctx = EVP_MD_CTX_new();
++#else
+ 		ctx = &mapping->ctx.md;
+ 
+ 		dbgp("calling EVP_MD_CTX_init");
+ 		EVP_MD_CTX_init(ctx);
++#endif
+ 		dbgp("calling EVP_DigestInit");
+ 		EVP_DigestInit(ctx, sess_to_evp_md(sess));
+ 	}
diff --git a/poky/meta/recipes-kernel/cryptodev/files/0001-refactoring-split-big-function-to-simplify-maintaina.patch b/poky/meta/recipes-kernel/cryptodev/files/0001-refactoring-split-big-function-to-simplify-maintaina.patch
new file mode 100644
index 0000000..f557b5d
--- /dev/null
+++ b/poky/meta/recipes-kernel/cryptodev/files/0001-refactoring-split-big-function-to-simplify-maintaina.patch
@@ -0,0 +1,250 @@
+From 20dcf071bc3076ee7db9d603cfbe6a06e86c7d5f Mon Sep 17 00:00:00 2001
+From: Cristian Stoica <cristian.stoica@nxp.com>
+Date: Thu, 4 May 2017 15:06:20 +0300
+Subject: [PATCH 1/3] refactoring: split big function to simplify maintainance
+
+The setup of auth_buf in tls and aead is now duplicated but this
+is temporary and allows necessary corrections for the aead case
+with v4.2+ kernels.
+
+Signed-off-by: Cristian Stoica <cristian.stoica@nxp.com>
+
+Upstream-Status: Backport
+
+Commit ID: 20dcf071bc3076ee7db9d603c
+
+Signed-off-by: Hongzhi.Song <hongzhi.song@windriver.com>
+---
+ authenc.c | 197 ++++++++++++++++++++++++++++++++++++++++----------------------
+ 1 file changed, 126 insertions(+), 71 deletions(-)
+
+diff --git a/authenc.c b/authenc.c
+index 1bd7377..28eb0f9 100644
+--- a/authenc.c
++++ b/authenc.c
+@@ -609,96 +609,151 @@ auth_n_crypt(struct csession *ses_ptr, struct kernel_crypt_auth_op *kcaop,
+ 	return 0;
+ }
+ 
+-/* This is the main crypto function - zero-copy edition */
+-static int
+-__crypto_auth_run_zc(struct csession *ses_ptr, struct kernel_crypt_auth_op *kcaop)
++static int crypto_auth_zc_srtp(struct csession *ses_ptr, struct kernel_crypt_auth_op *kcaop)
+ {
+-	struct scatterlist *dst_sg, *auth_sg, *src_sg;
++	struct scatterlist *dst_sg, *auth_sg;
+ 	struct crypt_auth_op *caop = &kcaop->caop;
+-	int ret = 0;
++	int ret;
+ 
+-	if (caop->flags & COP_FLAG_AEAD_SRTP_TYPE) {
+-		if (unlikely(ses_ptr->cdata.init != 0 &&
+-		             (ses_ptr->cdata.stream == 0 ||
+-			      ses_ptr->cdata.aead != 0))) {
+-			derr(0, "Only stream modes are allowed in SRTP mode (but not AEAD)");
+-			return -EINVAL;
+-		}
++	if (unlikely(ses_ptr->cdata.init != 0 &&
++		(ses_ptr->cdata.stream == 0 || ses_ptr->cdata.aead != 0))) {
++		derr(0, "Only stream modes are allowed in SRTP mode (but not AEAD)");
++		return -EINVAL;
++	}
+ 
+-		ret = get_userbuf_srtp(ses_ptr, kcaop, &auth_sg, &dst_sg);
+-		if (unlikely(ret)) {
+-			derr(1, "get_userbuf_srtp(): Error getting user pages.");
+-			return ret;
+-		}
++	ret = get_userbuf_srtp(ses_ptr, kcaop, &auth_sg, &dst_sg);
++	if (unlikely(ret)) {
++		derr(1, "get_userbuf_srtp(): Error getting user pages.");
++		return ret;
++	}
+ 
+-		ret = srtp_auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
+-			   dst_sg, caop->len);
++	ret = srtp_auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
++			dst_sg, caop->len);
+ 
+-		release_user_pages(ses_ptr);
+-	} else { /* TLS and normal cases. Here auth data are usually small
+-	          * so we just copy them to a free page, instead of trying
+-	          * to map them.
+-	          */
+-		unsigned char *auth_buf = NULL;
+-		struct scatterlist tmp;
++	release_user_pages(ses_ptr);
+ 
+-		if (unlikely(caop->auth_len > PAGE_SIZE)) {
+-			derr(1, "auth data len is excessive.");
+-			return -EINVAL;
+-		}
++	return ret;
++}
+ 
+-		auth_buf = (char *)__get_free_page(GFP_KERNEL);
+-		if (unlikely(!auth_buf)) {
+-			derr(1, "unable to get a free page.");
+-			return -ENOMEM;
+-		}
++static int crypto_auth_zc_tls(struct csession *ses_ptr, struct kernel_crypt_auth_op *kcaop)
++{
++	struct crypt_auth_op *caop = &kcaop->caop;
++	struct scatterlist *dst_sg, *auth_sg;
++	unsigned char *auth_buf = NULL;
++	struct scatterlist tmp;
++	int ret;
+ 
+-		if (caop->auth_src && caop->auth_len > 0) {
+-			if (unlikely(copy_from_user(auth_buf, caop->auth_src, caop->auth_len))) {
+-				derr(1, "unable to copy auth data from userspace.");
+-				ret = -EFAULT;
+-				goto free_auth_buf;
+-			}
++	if (unlikely(ses_ptr->cdata.aead != 0)) {
++		return -EINVAL;
++	}
++
++	if (unlikely(caop->auth_len > PAGE_SIZE)) {
++		derr(1, "auth data len is excessive.");
++		return -EINVAL;
++	}
++
++	auth_buf = (char *)__get_free_page(GFP_KERNEL);
++	if (unlikely(!auth_buf)) {
++		derr(1, "unable to get a free page.");
++		return -ENOMEM;
++	}
+ 
+-			sg_init_one(&tmp, auth_buf, caop->auth_len);
+-			auth_sg = &tmp;
+-		} else {
+-			auth_sg = NULL;
++	if (caop->auth_src && caop->auth_len > 0) {
++		if (unlikely(copy_from_user(auth_buf, caop->auth_src, caop->auth_len))) {
++			derr(1, "unable to copy auth data from userspace.");
++			ret = -EFAULT;
++			goto free_auth_buf;
+ 		}
+ 
+-		if (caop->flags & COP_FLAG_AEAD_TLS_TYPE && ses_ptr->cdata.aead == 0) {
+-			ret = get_userbuf_tls(ses_ptr, kcaop, &dst_sg);
+-			if (unlikely(ret)) {
+-				derr(1, "get_userbuf_tls(): Error getting user pages.");
+-				goto free_auth_buf;
+-			}
++		sg_init_one(&tmp, auth_buf, caop->auth_len);
++		auth_sg = &tmp;
++	} else {
++		auth_sg = NULL;
++	}
+ 
+-			ret = tls_auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
+-				   dst_sg, caop->len);
+-		} else {
+-			if (unlikely(ses_ptr->cdata.init == 0 ||
+-			             (ses_ptr->cdata.stream == 0 &&
+-				      ses_ptr->cdata.aead == 0))) {
+-				derr(0, "Only stream and AEAD ciphers are allowed for authenc");
+-				ret = -EINVAL;
+-				goto free_auth_buf;
+-			}
++	ret = get_userbuf_tls(ses_ptr, kcaop, &dst_sg);
++	if (unlikely(ret)) {
++		derr(1, "get_userbuf_tls(): Error getting user pages.");
++		goto free_auth_buf;
++	}
+ 
+-			ret = get_userbuf(ses_ptr, caop->src, caop->len, caop->dst, kcaop->dst_len,
+-					  kcaop->task, kcaop->mm, &src_sg, &dst_sg);
+-			if (unlikely(ret)) {
+-				derr(1, "get_userbuf(): Error getting user pages.");
+-				goto free_auth_buf;
+-			}
++	ret = tls_auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
++			dst_sg, caop->len);
++	release_user_pages(ses_ptr);
++
++free_auth_buf:
++	free_page((unsigned long)auth_buf);
++	return ret;
++}
++
++static int crypto_auth_zc_aead(struct csession *ses_ptr, struct kernel_crypt_auth_op *kcaop)
++{
++	struct scatterlist *dst_sg, *auth_sg, *src_sg;
++	struct crypt_auth_op *caop = &kcaop->caop;
++	unsigned char *auth_buf = NULL;
++	struct scatterlist tmp;
++	int ret;
+ 
+-			ret = auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
+-					   src_sg, dst_sg, caop->len);
++	if (unlikely(ses_ptr->cdata.init == 0 ||
++		(ses_ptr->cdata.stream == 0 && ses_ptr->cdata.aead == 0))) {
++		derr(0, "Only stream and AEAD ciphers are allowed for authenc");
++		return -EINVAL;
++	}
++
++	if (unlikely(caop->auth_len > PAGE_SIZE)) {
++		derr(1, "auth data len is excessive.");
++		return -EINVAL;
++	}
++
++	auth_buf = (char *)__get_free_page(GFP_KERNEL);
++	if (unlikely(!auth_buf)) {
++		derr(1, "unable to get a free page.");
++		return -ENOMEM;
++	}
++
++	if (caop->auth_src && caop->auth_len > 0) {
++		if (unlikely(copy_from_user(auth_buf, caop->auth_src, caop->auth_len))) {
++			derr(1, "unable to copy auth data from userspace.");
++			ret = -EFAULT;
++			goto free_auth_buf;
+ 		}
+ 
+-		release_user_pages(ses_ptr);
++		sg_init_one(&tmp, auth_buf, caop->auth_len);
++		auth_sg = &tmp;
++	} else {
++		auth_sg = NULL;
++	}
++
++	ret = get_userbuf(ses_ptr, caop->src, caop->len, caop->dst, kcaop->dst_len,
++			kcaop->task, kcaop->mm, &src_sg, &dst_sg);
++	if (unlikely(ret)) {
++		derr(1, "get_userbuf(): Error getting user pages.");
++		goto free_auth_buf;
++	}
++
++	ret = auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
++			src_sg, dst_sg, caop->len);
++
++	release_user_pages(ses_ptr);
+ 
+ free_auth_buf:
+-		free_page((unsigned long)auth_buf);
++	free_page((unsigned long)auth_buf);
++
++	return ret;
++}
++
++static int
++__crypto_auth_run_zc(struct csession *ses_ptr, struct kernel_crypt_auth_op *kcaop)
++{
++	struct crypt_auth_op *caop = &kcaop->caop;
++	int ret;
++
++	if (caop->flags & COP_FLAG_AEAD_SRTP_TYPE) {
++		ret = crypto_auth_zc_srtp(ses_ptr, kcaop);
++	} else if (caop->flags & COP_FLAG_AEAD_TLS_TYPE) {
++		ret = crypto_auth_zc_tls(ses_ptr, kcaop);
++	} else {
++		ret = crypto_auth_zc_aead(ses_ptr, kcaop);
+ 	}
+ 
+ 	return ret;
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-kernel/cryptodev/files/0002-refactoring-relocate-code-to-simplify-later-patches.patch b/poky/meta/recipes-kernel/cryptodev/files/0002-refactoring-relocate-code-to-simplify-later-patches.patch
new file mode 100644
index 0000000..83d9005
--- /dev/null
+++ b/poky/meta/recipes-kernel/cryptodev/files/0002-refactoring-relocate-code-to-simplify-later-patches.patch
@@ -0,0 +1,64 @@
+From c2bf0e42b1d9fda60cde4a3a682784d349ef1c0b Mon Sep 17 00:00:00 2001
+From: Cristian Stoica <cristian.stoica@nxp.com>
+Date: Thu, 4 May 2017 15:06:21 +0300
+Subject: [PATCH 2/3] refactoring: relocate code to simplify later patches
+
+This code move will simplify the conversion to new AEAD interface in
+next patches
+
+Signed-off-by: Cristian Stoica <cristian.stoica@nxp.com>
+
+Upstream-Status: Backport
+
+Commit ID: c2bf0e42b1d9fda
+
+Signed-off-by: Hongzhi.Song <hongzhi.song@windriver.com>
+---
+ authenc.c | 17 +++++++++--------
+ 1 file changed, 9 insertions(+), 8 deletions(-)
+
+diff --git a/authenc.c b/authenc.c
+index 28eb0f9..95727b4 100644
+--- a/authenc.c
++++ b/authenc.c
+@@ -711,11 +711,18 @@ static int crypto_auth_zc_aead(struct csession *ses_ptr, struct kernel_crypt_aut
+ 		return -ENOMEM;
+ 	}
+ 
++	ret = get_userbuf(ses_ptr, caop->src, caop->len, caop->dst, kcaop->dst_len,
++			kcaop->task, kcaop->mm, &src_sg, &dst_sg);
++	if (unlikely(ret)) {
++		derr(1, "get_userbuf(): Error getting user pages.");
++		goto free_auth_buf;
++	}
++
+ 	if (caop->auth_src && caop->auth_len > 0) {
+ 		if (unlikely(copy_from_user(auth_buf, caop->auth_src, caop->auth_len))) {
+ 			derr(1, "unable to copy auth data from userspace.");
+ 			ret = -EFAULT;
+-			goto free_auth_buf;
++			goto free_pages;
+ 		}
+ 
+ 		sg_init_one(&tmp, auth_buf, caop->auth_len);
+@@ -724,16 +731,10 @@ static int crypto_auth_zc_aead(struct csession *ses_ptr, struct kernel_crypt_aut
+ 		auth_sg = NULL;
+ 	}
+ 
+-	ret = get_userbuf(ses_ptr, caop->src, caop->len, caop->dst, kcaop->dst_len,
+-			kcaop->task, kcaop->mm, &src_sg, &dst_sg);
+-	if (unlikely(ret)) {
+-		derr(1, "get_userbuf(): Error getting user pages.");
+-		goto free_auth_buf;
+-	}
+-
+ 	ret = auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
+ 			src_sg, dst_sg, caop->len);
+ 
++free_pages:
+ 	release_user_pages(ses_ptr);
+ 
+ free_auth_buf:
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-kernel/cryptodev/files/0003-convert-to-new-AEAD-interface-in-kernels-v4.2.patch b/poky/meta/recipes-kernel/cryptodev/files/0003-convert-to-new-AEAD-interface-in-kernels-v4.2.patch
new file mode 100644
index 0000000..8602307
--- /dev/null
+++ b/poky/meta/recipes-kernel/cryptodev/files/0003-convert-to-new-AEAD-interface-in-kernels-v4.2.patch
@@ -0,0 +1,102 @@
+From a705360197260d28535746ae98c461ba2cfb7a9e Mon Sep 17 00:00:00 2001
+From: Cristian Stoica <cristian.stoica@nxp.com>
+Date: Thu, 4 May 2017 15:06:22 +0300
+Subject: [PATCH 3/3] convert to new AEAD interface in kernels v4.2+
+
+The crypto API for AEAD ciphers changed in recent kernels so that
+associated data is now part of both source and destination scatter
+gathers. The source, destination and associated data buffers need
+to be stiched accordingly for the operations to succeed:
+
+src_sg: auth_buf + src_buf
+dst_sg: auth_buf + (dst_buf + tag space)
+
+This patch fixes a kernel crash observed with cipher-gcm test.
+
+See also kernel patch: 81c4c35eb61a69c229871c490b011c1171511d5a
+    crypto: ccm - Convert to new AEAD interface
+
+Reported-by: Phil Sutter <phil@nwl.cc>
+Signed-off-by: Cristian Stoica <cristian.stoica@nxp.com>
+
+Upstream-Status: Backport
+
+Commit ID: a705360197260d2853574
+
+Signed-off-by: Hongzhi.Song <hongzhi.song@windriver.com>
+---
+ authenc.c | 40 ++++++++++++++++++++++++++++++++++++++--
+ 1 file changed, 38 insertions(+), 2 deletions(-)
+
+diff --git a/authenc.c b/authenc.c
+index 95727b4..692951f 100644
+--- a/authenc.c
++++ b/authenc.c
+@@ -688,12 +688,20 @@ free_auth_buf:
+ 
+ static int crypto_auth_zc_aead(struct csession *ses_ptr, struct kernel_crypt_auth_op *kcaop)
+ {
+-	struct scatterlist *dst_sg, *auth_sg, *src_sg;
++	struct scatterlist *dst_sg;
++	struct scatterlist *src_sg;
+ 	struct crypt_auth_op *caop = &kcaop->caop;
+ 	unsigned char *auth_buf = NULL;
+-	struct scatterlist tmp;
+ 	int ret;
+ 
++#if (LINUX_VERSION_CODE < KERNEL_VERSION(4, 2, 0))
++	struct scatterlist tmp;
++	struct scatterlist *auth_sg;
++#else
++	struct scatterlist auth1[2];
++	struct scatterlist auth2[2];
++#endif
++
+ 	if (unlikely(ses_ptr->cdata.init == 0 ||
+ 		(ses_ptr->cdata.stream == 0 && ses_ptr->cdata.aead == 0))) {
+ 		derr(0, "Only stream and AEAD ciphers are allowed for authenc");
+@@ -718,6 +726,7 @@ static int crypto_auth_zc_aead(struct csession *ses_ptr, struct kernel_crypt_aut
+ 		goto free_auth_buf;
+ 	}
+ 
++#if (LINUX_VERSION_CODE < KERNEL_VERSION(4, 2, 0))
+ 	if (caop->auth_src && caop->auth_len > 0) {
+ 		if (unlikely(copy_from_user(auth_buf, caop->auth_src, caop->auth_len))) {
+ 			derr(1, "unable to copy auth data from userspace.");
+@@ -733,6 +742,33 @@ static int crypto_auth_zc_aead(struct csession *ses_ptr, struct kernel_crypt_aut
+ 
+ 	ret = auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
+ 			src_sg, dst_sg, caop->len);
++#else
++	if (caop->auth_src && caop->auth_len > 0) {
++		if (unlikely(copy_from_user(auth_buf, caop->auth_src, caop->auth_len))) {
++			derr(1, "unable to copy auth data from userspace.");
++			ret = -EFAULT;
++			goto free_pages;
++		}
++
++		sg_init_table(auth1, 2);
++		sg_set_buf(auth1, auth_buf, caop->auth_len);
++		sg_chain(auth1, 2, src_sg);
++
++		if (src_sg == dst_sg) {
++			src_sg = auth1;
++			dst_sg = auth1;
++		} else {
++			sg_init_table(auth2, 2);
++			sg_set_buf(auth2, auth_buf, caop->auth_len);
++			sg_chain(auth2, 2, dst_sg);
++			src_sg = auth1;
++			dst_sg = auth2;
++		}
++	}
++
++	ret = auth_n_crypt(ses_ptr, kcaop, NULL, caop->auth_len,
++			src_sg, dst_sg, caop->len);
++#endif
+ 
+ free_pages:
+ 	release_user_pages(ses_ptr);
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-kernel/dtc/dtc.inc b/poky/meta/recipes-kernel/dtc/dtc.inc
index 9a90d44..7a923bf 100644
--- a/poky/meta/recipes-kernel/dtc/dtc.inc
+++ b/poky/meta/recipes-kernel/dtc/dtc.inc
@@ -7,7 +7,6 @@
 
 SRC_URI = "git://git.kernel.org/pub/scm/utils/dtc/dtc.git \
            file://make_install.patch \
-           file://0001-checks-Use-proper-format-modifier-for-size_t.patch \
            "
 UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+(\.\d+)+)"
 
diff --git a/poky/meta/recipes-kernel/dtc/dtc/0001-checks-Use-proper-format-modifier-for-size_t.patch b/poky/meta/recipes-kernel/dtc/dtc/0001-checks-Use-proper-format-modifier-for-size_t.patch
deleted file mode 100644
index cab384d..0000000
--- a/poky/meta/recipes-kernel/dtc/dtc/0001-checks-Use-proper-format-modifier-for-size_t.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From c7a4c3817796107bb824a1f173faf90fae45396b Mon Sep 17 00:00:00 2001
-From: Thierry Reding <treding@nvidia.com>
-Date: Wed, 27 Sep 2017 15:04:09 +0200
-Subject: [PATCH] checks: Use proper format modifier for size_t
-
-The size of size_t can vary between architectures, so using %ld isn't
-going to work on 32-bit builds. Use the %zu modifier to make sure it is
-always correct.
-
-Upstream-Status: Backport
-Signed-off-by: Thierry Reding <treding@nvidia.com>
-Acked-by: Rob Herring <robh@kernel.org>
-Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
----
- checks.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/checks.c b/checks.c
-index 902f2e3..08a3a29 100644
---- a/checks.c
-+++ b/checks.c
-@@ -972,7 +972,7 @@ static void check_property_phandle_args(struct check *c,
- 	int cell, cellsize = 0;
- 
- 	if (prop->val.len % sizeof(cell_t)) {
--		FAIL(c, dti, "property '%s' size (%d) is invalid, expected multiple of %ld in node %s",
-+		FAIL(c, dti, "property '%s' size (%d) is invalid, expected multiple of %zu in node %s",
- 		     prop->name, prop->val.len, sizeof(cell_t), node->fullpath);
- 		return;
- 	}
-@@ -1163,7 +1163,7 @@ static void check_interrupts_property(struct check *c,
- 		return;
- 
- 	if (irq_prop->val.len % sizeof(cell_t))
--		FAIL(c, dti, "property '%s' size (%d) is invalid, expected multiple of %ld in node %s",
-+		FAIL(c, dti, "property '%s' size (%d) is invalid, expected multiple of %zu in node %s",
- 		     irq_prop->name, irq_prop->val.len, sizeof(cell_t),
- 		     node->fullpath);
- 
--- 
-2.15.0
-
diff --git a/poky/meta/recipes-kernel/dtc/dtc/make_install.patch b/poky/meta/recipes-kernel/dtc/dtc/make_install.patch
index ccf17b3..ea9359e 100644
--- a/poky/meta/recipes-kernel/dtc/dtc/make_install.patch
+++ b/poky/meta/recipes-kernel/dtc/dtc/make_install.patch
@@ -1,17 +1,26 @@
+From e9852b9d206df1e42aa4c8afec55a0f5e099b533 Mon Sep 17 00:00:00 2001
+From: Saul Wold <sgw@linux.intel.com>
+Date: Thu, 3 Nov 2011 08:35:47 -0700
+Subject: [PATCH] dtc: Add patch to correctly install shared libraries and
+
 Upstream-Status: Inappropriate [configuration]
 
-Index: git/Makefile
-===================================================================
---- git.orig/Makefile
-+++ git/Makefile
-@@ -168,8 +168,8 @@ install-bin: all $(SCRIPTS)
+---
+ Makefile | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index d8ebc4f..f5e01be 100644
+--- a/Makefile
++++ b/Makefile
+@@ -205,8 +205,8 @@ install-bin: all $(SCRIPTS)
  install-lib: all
  	@$(VECHO) INSTALL-LIB
  	$(INSTALL) -d $(DESTDIR)$(LIBDIR)
--	$(INSTALL) $(LIBFDT_lib) $(DESTDIR)$(LIBDIR)
+-	$(INSTALL_LIB) $(LIBFDT_lib) $(DESTDIR)$(LIBDIR)
 -	ln -sf $(notdir $(LIBFDT_lib)) $(DESTDIR)$(LIBDIR)/$(LIBFDT_soname)
 +	$(INSTALL) $(LIBFDT_lib) $(DESTDIR)$(LIBDIR)/$(LIBFDT_soname)
 +	ln -sf $(LIBFDT_soname) $(DESTDIR)$(LIBDIR)/$(notdir $(LIBFDT_lib))
  	ln -sf $(LIBFDT_soname) $(DESTDIR)$(LIBDIR)/libfdt.$(SHAREDLIB_EXT)
- 	$(INSTALL) -m 644 $(LIBFDT_archive) $(DESTDIR)$(LIBDIR)
+ 	$(INSTALL_DATA) $(LIBFDT_archive) $(DESTDIR)$(LIBDIR)
  
diff --git a/poky/meta/recipes-kernel/dtc/dtc_1.4.5.bb b/poky/meta/recipes-kernel/dtc/dtc_1.4.5.bb
deleted file mode 100644
index 0e46cfb..0000000
--- a/poky/meta/recipes-kernel/dtc/dtc_1.4.5.bb
+++ /dev/null
@@ -1,10 +0,0 @@
-require dtc.inc
-
-LIC_FILES_CHKSUM = "file://GPL;md5=94d55d512a9ba36caa9b7df079bae19f \
-		    file://libfdt/libfdt.h;beginline=3;endline=52;md5=fb360963151f8ec2d6c06b055bcbb68c"
-
-SRCREV = "22a65c5331c22979d416738eb756b9541672e00d"
-
-S = "${WORKDIR}/git"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-kernel/dtc/dtc_1.4.7.bb b/poky/meta/recipes-kernel/dtc/dtc_1.4.7.bb
new file mode 100644
index 0000000..6ce462a
--- /dev/null
+++ b/poky/meta/recipes-kernel/dtc/dtc_1.4.7.bb
@@ -0,0 +1,10 @@
+require dtc.inc
+
+LIC_FILES_CHKSUM = "file://GPL;md5=94d55d512a9ba36caa9b7df079bae19f \
+		    file://libfdt/libfdt.h;beginline=3;endline=52;md5=fb360963151f8ec2d6c06b055bcbb68c"
+
+SRCREV = "88f18909db731a627456f26d779445f84e449536"
+
+S = "${WORKDIR}/git"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb b/poky/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb
index 4ccf9b0..b353c21 100644
--- a/poky/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb
+++ b/poky/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb
@@ -4,7 +4,7 @@
 
 DEPENDS = "git-native"
 
-SRCREV = "8cd13500a27c0a6a911cc83c0349dec01ef66e27"
+SRCREV = "d6529f86fc5bcb3514953ff9fa2f51a3fbf03a0f"
 PR = "r12"
 PV = "0.2+git${SRCPV}"
 
diff --git a/poky/meta/recipes-kernel/kexec/kexec-tools/0001-kexec-fix-for-Unhandled-rela-relocation-R_X86_64_PLT.patch b/poky/meta/recipes-kernel/kexec/kexec-tools/0001-kexec-fix-for-Unhandled-rela-relocation-R_X86_64_PLT.patch
new file mode 100644
index 0000000..e0cced5
--- /dev/null
+++ b/poky/meta/recipes-kernel/kexec/kexec-tools/0001-kexec-fix-for-Unhandled-rela-relocation-R_X86_64_PLT.patch
@@ -0,0 +1,41 @@
+From b9de21ef51a7ceab7122a707c188602eae22c4ee Mon Sep 17 00:00:00 2001
+From: Chris Clayton <chris2553@googlemail.com>
+Date: Mon, 20 Aug 2018 12:00:31 +0100
+Subject: [PATCH] kexec: fix for "Unhandled rela relocation: R_X86_64_PLT32" error
+
+In response to a change in binutils, commit b21ebf2fb4c
+(x86: Treat R_X86_64_PLT32 as R_X86_64_PC32) was applied to
+the linux kernel during the 4.16 development cycle and has
+since been backported to earlier stable kernel series. The
+change results in the failure message in $SUBJECT when
+rebooting via kexec.
+
+Fix this by replicating the change in kexec.
+
+Upstream-Status: Backport[https://git.kernel.org/pub/scm/utils/kernel/kexec/kexec-tools.git/commit/?id=b9de21ef51a7ceab7122a707c188602eae22c4ee]
+
+Signed-off-by: Chris Clayton <chris2553@googlemail.com>
+Acked-by: Baoquan He <bhe@redhat.com>
+Tested-by: Bhupesh Sharma <bhsharma@redhat.com>
+Acked-by: Bhupesh Sharma <bhsharma@redhat.com>
+Signed-off-by: Simon Horman <horms@verge.net.au>
+Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
+---
+ kexec/arch/x86_64/kexec-elf-rel-x86_64.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/kexec/arch/x86_64/kexec-elf-rel-x86_64.c b/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
+index 7fdde73..db85b44 100644
+--- a/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
++++ b/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
+@@ -79,6 +79,7 @@ void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr),
+ 			goto overflow;
+ 		break;
+ 	case R_X86_64_PC32: 
++	case R_X86_64_PLT32:
+ 		*(uint32_t *)location = value - address;
+ 		break;
+ 	default:
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-kernel/kexec/kexec-tools/kdump.service b/poky/meta/recipes-kernel/kexec/kexec-tools/kdump.service
index 013c5a6..b4a2c06 100644
--- a/poky/meta/recipes-kernel/kexec/kexec-tools/kdump.service
+++ b/poky/meta/recipes-kernel/kexec/kexec-tools/kdump.service
@@ -1,7 +1,8 @@
 [Unit]
 Description=Reboot and dump vmcore via kexec
 DefaultDependencies=no
-After=basic.target
+Requires=sysinit.target
+After=sysinit.target
 
 [Service]
 Type=oneshot
diff --git a/poky/meta/recipes-kernel/kexec/kexec-tools_2.0.16.bb b/poky/meta/recipes-kernel/kexec/kexec-tools_2.0.16.bb
deleted file mode 100644
index ebb4832..0000000
--- a/poky/meta/recipes-kernel/kexec/kexec-tools_2.0.16.bb
+++ /dev/null
@@ -1,86 +0,0 @@
-
-SUMMARY = "Kexec fast reboot tools"
-DESCRIPTION = "Kexec is a fast reboot feature that lets you reboot to a new Linux kernel"
-AUTHOR = "Eric Biederman"
-HOMEPAGE = "http://kernel.org/pub/linux/utils/kernel/kexec/"
-SECTION = "kernel/userland"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=ea5bed2f60d357618ca161ad539f7c0a \
-                    file://kexec/kexec.c;beginline=1;endline=20;md5=af10f6ae4a8715965e648aa687ad3e09"
-DEPENDS = "zlib xz"
-
-PR = "r1"
-
-SRC_URI = "${KERNELORG_MIRROR}/linux/utils/kernel/kexec/kexec-tools-${PV}.tar.gz \
-           file://kdump \
-           file://kdump.conf \
-           file://kdump.service \
-           file://0002-powerpc-change-the-memory-size-limit.patch \
-           file://0001-purgatory-Pass-r-directly-to-linker.patch \
-           file://0010-kexec-ARM-Fix-add_buffer_phys_virt-align-issue.patch \
-           file://kexec-x32.patch \
-           file://0001-Disable-PIE-during-link.patch \
-         "
-
-SRC_URI[md5sum] = "5198968de79b5ded96f97f3c2ea9637b"
-SRC_URI[sha256sum] = "cf17fc99bf77c9b39f06ee88ac0e86d0349c4a0c3f8214a3cc78eece872f6f3a"
-
-inherit autotools update-rc.d systemd
-
-export LDFLAGS = "-L${STAGING_LIBDIR}"
-EXTRA_OECONF = " --with-zlib=yes"
-
-do_compile_prepend() {
-    # Remove the prepackaged config.h from the source tree as it overrides
-    # the same file generated by configure and placed in the build tree
-    rm -f ${S}/include/config.h
-
-    # Remove the '*.d' file to make sure the recompile is OK
-    for dep in `find ${B} -type f -name '*.d'`; do
-        dep_no_d="`echo $dep | sed 's#.d$##'`"
-        # Remove file.d when there is a file.o
-        if [ -f "$dep_no_d.o" ]; then
-            rm -f $dep
-        fi
-    done
-}
-
-do_install_append () {
-        install -d ${D}${sysconfdir}/sysconfig
-        install -m 0644 ${WORKDIR}/kdump.conf ${D}${sysconfdir}/sysconfig
-
-        if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
-                install -D -m 0755 ${WORKDIR}/kdump ${D}${sysconfdir}/init.d/kdump
-        fi
-
-        if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-                install -D -m 0755 ${WORKDIR}/kdump ${D}${libexecdir}/kdump-helper
-                install -D -m 0644 ${WORKDIR}/kdump.service ${D}${systemd_unitdir}/system/kdump.service
-                sed -i -e 's,@LIBEXECDIR@,${libexecdir},g' ${D}${systemd_unitdir}/system/kdump.service
-        fi
-}
-
-PACKAGES =+ "kexec kdump vmcore-dmesg"
-
-ALLOW_EMPTY_${PN} = "1"
-RRECOMMENDS_${PN} = "kexec kdump vmcore-dmesg"
-
-FILES_kexec = "${sbindir}/kexec"
-FILES_kdump = "${sbindir}/kdump \
-               ${sysconfdir}/sysconfig/kdump.conf \
-               ${sysconfdir}/init.d/kdump \
-               ${libexecdir}/kdump-helper \
-               ${systemd_unitdir}/system/kdump.service \
-"
-
-FILES_vmcore-dmesg = "${sbindir}/vmcore-dmesg"
-
-INITSCRIPT_PACKAGES = "kdump"
-INITSCRIPT_NAME_kdump = "kdump"
-INITSCRIPT_PARAMS_kdump = "start 56 2 3 4 5 . stop 56 0 1 6 ."
-
-SECURITY_PIE_CFLAGS_remove = "-fPIE -pie"
-
-COMPATIBLE_HOST = '(x86_64.*|i.86.*|arm.*|aarch64.*|powerpc.*|mips.*)-(linux|freebsd.*)'
-
-INSANE_SKIP_${PN} = "arch"
diff --git a/poky/meta/recipes-kernel/kexec/kexec-tools_2.0.17.bb b/poky/meta/recipes-kernel/kexec/kexec-tools_2.0.17.bb
new file mode 100644
index 0000000..4b9b5ac
--- /dev/null
+++ b/poky/meta/recipes-kernel/kexec/kexec-tools_2.0.17.bb
@@ -0,0 +1,88 @@
+
+SUMMARY = "Kexec fast reboot tools"
+DESCRIPTION = "Kexec is a fast reboot feature that lets you reboot to a new Linux kernel"
+AUTHOR = "Eric Biederman"
+HOMEPAGE = "http://kernel.org/pub/linux/utils/kernel/kexec/"
+SECTION = "kernel/userland"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=ea5bed2f60d357618ca161ad539f7c0a \
+                    file://kexec/kexec.c;beginline=1;endline=20;md5=af10f6ae4a8715965e648aa687ad3e09"
+DEPENDS = "zlib xz"
+
+SRC_URI = "${KERNELORG_MIRROR}/linux/utils/kernel/kexec/kexec-tools-${PV}.tar.gz \
+           file://kdump \
+           file://kdump.conf \
+           file://kdump.service \
+           file://0002-powerpc-change-the-memory-size-limit.patch \
+           file://0001-purgatory-Pass-r-directly-to-linker.patch \
+           file://0010-kexec-ARM-Fix-add_buffer_phys_virt-align-issue.patch \
+           file://kexec-x32.patch \
+           file://0001-Disable-PIE-during-link.patch \
+           file://0001-kexec-fix-for-Unhandled-rela-relocation-R_X86_64_PLT.patch \
+           "
+
+SRC_URI[md5sum] = "8e071ca473694a71e4ae60ed7ef6f377"
+SRC_URI[sha256sum] = "450c87ba048641eb05f9717f5567aca57f063c266149ae663b58a34e5852deaf"
+
+inherit autotools update-rc.d systemd
+
+export LDFLAGS = "-L${STAGING_LIBDIR}"
+EXTRA_OECONF = " --with-zlib=yes"
+
+do_compile_prepend() {
+    # Remove the prepackaged config.h from the source tree as it overrides
+    # the same file generated by configure and placed in the build tree
+    rm -f ${S}/include/config.h
+
+    # Remove the '*.d' file to make sure the recompile is OK
+    for dep in `find ${B} -type f -name '*.d'`; do
+        dep_no_d="`echo $dep | sed 's#.d$##'`"
+        # Remove file.d when there is a file.o
+        if [ -f "$dep_no_d.o" ]; then
+            rm -f $dep
+        fi
+    done
+}
+
+do_install_append () {
+        install -d ${D}${sysconfdir}/sysconfig
+        install -m 0644 ${WORKDIR}/kdump.conf ${D}${sysconfdir}/sysconfig
+
+        if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
+                install -D -m 0755 ${WORKDIR}/kdump ${D}${sysconfdir}/init.d/kdump
+        fi
+
+        if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+                install -D -m 0755 ${WORKDIR}/kdump ${D}${libexecdir}/kdump-helper
+                install -D -m 0644 ${WORKDIR}/kdump.service ${D}${systemd_unitdir}/system/kdump.service
+                sed -i -e 's,@LIBEXECDIR@,${libexecdir},g' ${D}${systemd_unitdir}/system/kdump.service
+        fi
+}
+
+PACKAGES =+ "kexec kdump vmcore-dmesg"
+
+ALLOW_EMPTY_${PN} = "1"
+RRECOMMENDS_${PN} = "kexec kdump vmcore-dmesg"
+
+FILES_kexec = "${sbindir}/kexec"
+FILES_kdump = "${sbindir}/kdump \
+               ${sysconfdir}/sysconfig/kdump.conf \
+               ${sysconfdir}/init.d/kdump \
+               ${libexecdir}/kdump-helper \
+               ${systemd_unitdir}/system/kdump.service \
+"
+
+FILES_vmcore-dmesg = "${sbindir}/vmcore-dmesg"
+
+INITSCRIPT_PACKAGES = "kdump"
+INITSCRIPT_NAME_kdump = "kdump"
+INITSCRIPT_PARAMS_kdump = "start 56 2 3 4 5 . stop 56 0 1 6 ."
+
+SYSTEMD_PACKAGES = "kdump"
+SYSTEMD_SERVICE_kdump = "kdump.service"
+
+SECURITY_PIE_CFLAGS_remove = "-fPIE -pie"
+
+COMPATIBLE_HOST = '(x86_64.*|i.86.*|arm.*|aarch64.*|powerpc.*|mips.*)-(linux|freebsd.*)'
+
+INSANE_SKIP_${PN} = "arch"
diff --git a/poky/meta/recipes-kernel/kmod/kmod_git.bb b/poky/meta/recipes-kernel/kmod/kmod_git.bb
index 69185b2..bd21d2f 100644
--- a/poky/meta/recipes-kernel/kmod/kmod_git.bb
+++ b/poky/meta/recipes-kernel/kmod/kmod_git.bb
@@ -13,9 +13,7 @@
 RCONFLICTS_libkmod2 += "module-init-tools-insmod-static module-init-tools-depmod module-init-tools"
 
 # autotools set prefix to /usr, however we want them in /bin and /sbin
-bindir = "${base_bindir}"
-sbindir = "${base_sbindir}"
-# libdir = "${base_libdir}"
+EXTRA_OECONF += " --bindir=${base_bindir} --sbindir=${base_sbindir}"
 
 do_install_append () {
         install -dm755 ${D}${base_bindir}
@@ -41,7 +39,7 @@
 
 inherit update-alternatives bash-completion
 
-ALTERNATIVE_PRIORITY = "60"
+ALTERNATIVE_PRIORITY = "70"
 
 ALTERNATIVE_kmod = "insmod modprobe rmmod modinfo bin-lsmod lsmod depmod"
 
diff --git a/poky/meta/recipes-kernel/linux-firmware/linux-firmware_git.bb b/poky/meta/recipes-kernel/linux-firmware/linux-firmware_git.bb
index cf7abb0..2525545 100644
--- a/poky/meta/recipes-kernel/linux-firmware/linux-firmware_git.bb
+++ b/poky/meta/recipes-kernel/linux-firmware/linux-firmware_git.bb
@@ -66,12 +66,13 @@
     file://LICENCE.Abilis;md5=b5ee3f410780e56711ad48eadc22b8bc \
     file://LICENCE.adsp_sst;md5=615c45b91a5a4a9fe046d6ab9a2df728 \
     file://LICENCE.agere;md5=af0133de6b4a9b2522defd5f188afd31 \
-    file://LICENSE.amdgpu;md5=0aa3c2f3e736af320a08a3aeeccecf29 \
+    file://LICENSE.amdgpu;md5=88b865bc74f3ffcc54640b4ea8540b46 \
     file://LICENSE.amd-ucode;md5=3c5399dc9148d7f0e1f41e34b69cf14f \
     file://LICENCE.atheros_firmware;md5=30a14c7823beedac9fa39c64fdd01a13 \
     file://LICENSE.atmel;md5=aa74ac0c60595dee4d4e239107ea77a3 \
     file://LICENCE.broadcom_bcm43xx;md5=3160c14df7228891b868060e1951dfbc \
     file://LICENCE.ca0132;md5=209b33e66ee5be0461f13d31da392198 \
+    file://LICENCE.cadence;md5=009f46816f6956cfb75ede13d3e1cee0 \
     file://LICENCE.cavium;md5=c37aaffb1ebe5939b2580d073a95daea \
     file://LICENCE.chelsio_firmware;md5=819aa8c3fa453f1b258ed8d168a9d903 \
     file://LICENCE.cw1200;md5=f0f770864e7a8444a5c5aa9d12a3a7ed \
@@ -91,6 +92,7 @@
     file://LICENCE.iwlwifi_firmware;md5=3fd842911ea93c29cd32679aa23e1c88 \
     file://LICENCE.kaweth;md5=b1d876e562f4b3b8d391ad8395dfe03f \
     file://LICENCE.Marvell;md5=9ddea1734a4baf3c78d845151f42a37a \
+    file://LICENCE.mediatek;md5=7c1976b63217d76ce47d0a11d8a79cf2 \
     file://LICENCE.moxa;md5=1086614767d8ccf744a923289d3d4261 \
     file://LICENCE.myri10ge_firmware;md5=42e32fb89f6b959ca222e25ac8df8fed \
     file://LICENCE.Netronome;md5=4add08f2577086d44447996503cddf5f \
@@ -120,7 +122,7 @@
     file://LICENCE.xc4000;md5=0ff51d2dc49fce04814c9155081092f0 \
     file://LICENCE.xc5000;md5=1e170c13175323c32c7f4d0998d53f66 \
     file://LICENCE.xc5000c;md5=12b02efa3049db65d524aeb418dd87ca \
-    file://WHENCE;md5=eaaf310bac02fee05ea1b334f58c5caf \
+    file://WHENCE;md5=36ef3e9887bb8b38ff265c602de6740e \
 "
 
 # These are not common licenses, set NO_GENERIC_LICENSE for them
@@ -134,6 +136,7 @@
 NO_GENERIC_LICENSE[Firmware-atmel] = "LICENSE.atmel"
 NO_GENERIC_LICENSE[Firmware-broadcom_bcm43xx] = "LICENCE.broadcom_bcm43xx"
 NO_GENERIC_LICENSE[Firmware-ca0132] = "LICENCE.ca0132"
+NO_GENERIC_LICENSE[Firmware-cadence] = "LICENCE.cadence"
 NO_GENERIC_LICENSE[Firmware-cavium] = "LICENCE.cavium"
 NO_GENERIC_LICENSE[Firmware-chelsio_firmware] = "LICENCE.chelsio_firmware"
 NO_GENERIC_LICENSE[Firmware-cw1200] = "LICENCE.cw1200"
@@ -153,6 +156,7 @@
 NO_GENERIC_LICENSE[Firmware-iwlwifi_firmware] = "LICENCE.iwlwifi_firmware"
 NO_GENERIC_LICENSE[Firmware-kaweth] = "LICENCE.kaweth"
 NO_GENERIC_LICENSE[Firmware-Marvell] = "LICENCE.Marvell"
+NO_GENERIC_LICENSE[Firmware-mediatek] = "LICENCE.mediatek"
 NO_GENERIC_LICENSE[Firmware-moxa] = "LICENCE.moxa"
 NO_GENERIC_LICENSE[Firmware-myri10ge_firmware] = "LICENCE.myri10ge_firmware"
 NO_GENERIC_LICENSE[Firmware-netronome] = "LICENCE.Netronome"
@@ -184,7 +188,7 @@
 NO_GENERIC_LICENSE[Firmware-xc5000c] = "LICENCE.xc5000c"
 NO_GENERIC_LICENSE[WHENCE] = "WHENCE"
 
-SRCREV = "d1147327232ec4616a66ab898df84f9700c816c1"
+SRCREV = "44d4fca9922a252a0bd81f6307bcc072a78da54a"
 PE = "1"
 PV = "0.0+git${SRCPV}"
 
@@ -232,6 +236,7 @@
              ${PN}-radeon-license ${PN}-radeon \
              ${PN}-marvell-license ${PN}-pcie8897 ${PN}-pcie8997 \
              ${PN}-sd8686 ${PN}-sd8688 ${PN}-sd8787 ${PN}-sd8797 ${PN}-sd8801 ${PN}-sd8887 ${PN}-sd8897 \
+             ${PN}-usb8997 \
              ${PN}-ti-connectivity-license ${PN}-wl12xx ${PN}-wl18xx \
              ${PN}-vt6656-license ${PN}-vt6656 \
              ${PN}-rtl-license ${PN}-rtl8188 ${PN}-rtl8192cu ${PN}-rtl8192ce ${PN}-rtl8192su ${PN}-rtl8723 ${PN}-rtl8821 \
@@ -409,6 +414,7 @@
 LICENSE_${PN}-sd8801 = "Firmware-Marvell"
 LICENSE_${PN}-sd8887 = "Firmware-Marvell"
 LICENSE_${PN}-sd8897 = "Firmware-Marvell"
+LICENSE_${PN}-usb8997 = "Firmware-Marvell"
 LICENSE_${PN}-marvell-license = "Firmware-Marvell"
 
 FILES_${PN}-marvell-license = "${nonarch_base_libdir}/firmware/LICENCE.Marvell"
@@ -443,6 +449,9 @@
 FILES_${PN}-sd8897 = " \
   ${nonarch_base_libdir}/firmware/mrvl/sd8897_uapsta.bin \
 "
+FILES_${PN}-usb8997 = " \
+  ${nonarch_base_libdir}/firmware/mrvl/usbusb8997_combo_v4.bin \
+"
 
 RDEPENDS_${PN}-sd8686 += "${PN}-marvell-license"
 RDEPENDS_${PN}-sd8688 += "${PN}-marvell-license"
@@ -451,6 +460,7 @@
 RDEPENDS_${PN}-sd8801 += "${PN}-marvell-license"
 RDEPENDS_${PN}-sd8887 += "${PN}-marvell-license"
 RDEPENDS_${PN}-sd8897 += "${PN}-marvell-license"
+RDEPENDS_${PN}-usb8997 += "${PN}-marvell-license"
 
 # For netronome
 LICENSE_${PN}-netronome = "Firmware-netronome"
@@ -801,9 +811,9 @@
 FILES_${PN}-ibt-license = "${nonarch_base_libdir}/firmware/LICENCE.ibt_firmware"
 FILES_${PN}-ibt-hw-37-7 = "${nonarch_base_libdir}/firmware/intel/ibt-hw-37.7*.bseq"
 FILES_${PN}-ibt-hw-37-8 = "${nonarch_base_libdir}/firmware/intel/ibt-hw-37.8*.bseq"
-FILES_${PN}-ibt-11-5    = "${nonarch_base_libdir}/firmware/intel/ibt-11-5.sfi /lib/firmware/intel/ibt-11-5.ddc"
-FILES_${PN}-ibt-12-16   = "${nonarch_base_libdir}/firmware/intel/ibt-12-16.sfi /lib/firmware/intel/ibt-12-16.ddc"
-FILES_${PN}-ibt-17 = "${nonarch_base_libdir}/firmware/intel/ibt-17-*.sfi /lib/firmware/intel/ibt-17-*.ddc"
+FILES_${PN}-ibt-11-5    = "${nonarch_base_libdir}/firmware/intel/ibt-11-5.sfi ${nonarch_base_libdir}/firmware/intel/ibt-11-5.ddc"
+FILES_${PN}-ibt-12-16   = "${nonarch_base_libdir}/firmware/intel/ibt-12-16.sfi ${nonarch_base_libdir}/firmware/intel/ibt-12-16.ddc"
+FILES_${PN}-ibt-17 = "${nonarch_base_libdir}/firmware/intel/ibt-17-*.sfi ${nonarch_base_libdir}/firmware/intel/ibt-17-*.ddc"
 FILES_${PN}-ibt-misc    = "${nonarch_base_libdir}/firmware/ibt-*"
 
 RDEPENDS_${PN}-ibt-hw-37-7 = "${PN}-ibt-license"
diff --git a/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers.inc b/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers.inc
index b5cf96d..be215af 100644
--- a/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers.inc
+++ b/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers.inc
@@ -30,7 +30,7 @@
 #
 # -- RP
 
-LIC_FILES_CHKSUM = "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
+LIC_FILES_CHKSUM = "file://COPYING;md5=bbea815ee2795b2f4230826c0c6b8814"
 
 python __anonymous () {
     major = d.getVar("PV").split('.')[0]
@@ -53,12 +53,9 @@
 
 EXTRA_OEMAKE = " HOSTCC="${BUILD_CC}" HOSTCPP="${BUILD_CPP}""
 
-do_configure() {
-	oe_runmake allnoconfig
-}
+do_configure[noexec] = "1"
 
-do_compile () {
-}
+do_compile[noexec] = "1"
 
 do_install() {
 	oe_runmake headers_install INSTALL_HDR_PATH=${D}${exec_prefix}
@@ -92,4 +89,4 @@
 RRECOMMENDS_${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})"
 
 INHIBIT_DEFAULT_DEPS = "1"
-DEPENDS += "unifdef-native"
+DEPENDS += "unifdef-native bison-native"
diff --git a/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers/0001-include-linux-stddef.h-in-swab.h-uapi-header.patch b/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers/0001-include-linux-stddef.h-in-swab.h-uapi-header.patch
new file mode 100644
index 0000000..9d17daa
--- /dev/null
+++ b/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers/0001-include-linux-stddef.h-in-swab.h-uapi-header.patch
@@ -0,0 +1,44 @@
+From 9708dc74d9f49488d669e070982f6224a888d61a Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 12 Sep 2018 17:08:58 -0700
+Subject: [PATCH] include linux/stddef.h in swab.h uapi header
+
+swab.h uses __always_inline without including the header where it is
+defined, this is exposed by musl based distributions where this macro is
+not defined by system C library headers unlike glibc where it is defined
+in sys/cdefs.h and that header gets pulled in indirectly via
+
+features.h -> sys/cdefs.h
+
+and features.h gets pulled in a lot of headers. Therefore it may work in
+cases where features.h is includes but not otherwise.
+
+Adding linux/stddef.h here ensures that __always_inline is always
+defined independent of which C library is used in userspace
+
+Upstream-Status: Submitted [https://lkml.org/lkml/2018/9/13/78]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Cc: Philippe Ombredanne <pombredanne@nexb.com>
+Cc: Kate Stewart <kstewart@linuxfoundation.org>
+Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+Cc: Thomas Gleixner <tglx@linutronix.de>
+---
+ include/uapi/linux/swab.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/include/uapi/linux/swab.h b/include/uapi/linux/swab.h
+index 23cd84868cc3..acddbe50a20d 100644
+--- a/include/uapi/linux/swab.h
++++ b/include/uapi/linux/swab.h
+@@ -3,6 +3,7 @@
+ #define _UAPI_LINUX_SWAB_H
+ 
+ #include <linux/types.h>
++#include <linux/stddef.h>
+ #include <linux/compiler.h>
+ #include <asm/swab.h>
+ 
+-- 
+2.19.0
+
diff --git a/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers_4.15.7.bb b/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers_4.15.7.bb
deleted file mode 100644
index a7db4c9..0000000
--- a/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers_4.15.7.bb
+++ /dev/null
@@ -1,13 +0,0 @@
-require linux-libc-headers.inc
-
-SRC_URI_append_libc-musl = "\
-    file://0001-libc-compat.h-fix-some-issues-arising-from-in6.h.patch \
-    file://0002-libc-compat.h-prevent-redefinition-of-struct-ethhdr.patch \
-    file://0003-remove-inclusion-of-sysinfo.h-in-kernel.h.patch \
-    file://0001-libc-compat.h-musl-_does_-define-IFF_LOWER_UP-DORMAN.patch \
-    file://0001-if_ether-move-muslc-ethhdr-protection-to-uapi-file.patch \
-   "
-
-
-SRC_URI[md5sum] = "8186ce63c489199b58b6a58ad2a24a94"
-SRC_URI[sha256sum] = "cd44df4b23a3e0edc14be63df95d768b9600b31c35be05fb89f93226907fc8c6"
diff --git a/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers_4.18.bb b/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers_4.18.bb
new file mode 100644
index 0000000..eb7bee7
--- /dev/null
+++ b/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers_4.18.bb
@@ -0,0 +1,13 @@
+require linux-libc-headers.inc
+
+SRC_URI_append_libc-musl = "\
+    file://0001-libc-compat.h-fix-some-issues-arising-from-in6.h.patch \
+    file://0002-libc-compat.h-prevent-redefinition-of-struct-ethhdr.patch \
+    file://0003-remove-inclusion-of-sysinfo.h-in-kernel.h.patch \
+    file://0001-libc-compat.h-musl-_does_-define-IFF_LOWER_UP-DORMAN.patch \
+    file://0001-if_ether-move-muslc-ethhdr-protection-to-uapi-file.patch \
+    file://0001-include-linux-stddef.h-in-swab.h-uapi-header.patch \
+   "
+
+SRC_URI[md5sum] = "bee5fe53ee1c3142b8f0c12c0d3348f9"
+SRC_URI[sha256sum] = "19d8bcf49ef530cd4e364a45b4a22fa70714b70349c8100e7308488e26f1eaf1"
diff --git a/poky/meta/recipes-kernel/linux/kernel-devsrc.bb b/poky/meta/recipes-kernel/linux/kernel-devsrc.bb
index 8bbfa23..361ad21 100644
--- a/poky/meta/recipes-kernel/linux/kernel-devsrc.bb
+++ b/poky/meta/recipes-kernel/linux/kernel-devsrc.bb
@@ -25,62 +25,214 @@
 do_patch[noexec] = "1"
 do_configure[noexec] = "1"
 do_compile[noexec] = "1"
-do_populate_sysroot[noexec] = "1"
+deltask do_populate_sysroot
 
 S = "${STAGING_KERNEL_DIR}"
 B = "${STAGING_KERNEL_BUILDDIR}"
 
-KERNEL_VERSION = "${@get_kernelversion_headers('${S}')}"
-
 PACKAGE_ARCH = "${MACHINE_ARCH}"
 
+KERNEL_BUILD_ROOT="/lib/modules/"
+
 do_install() {
-        kerneldir=${D}${KERNEL_SRC_PATH}
-        install -d $kerneldir
+    kerneldir=${D}${KERNEL_BUILD_ROOT}${KERNEL_VERSION}
+    install -d $kerneldir
 
-        #
-        # Copy the staging dir source (and module build support) into the devsrc structure.
-        # We can keep this copy simple and take everything, since a we'll clean up any build
-        # artifacts afterwards, and the extra i/o is not significant
-        #
-        cd ${B}
-        find . -type d -name '.git*' -prune -o -path '.debug' -prune -o -type f -print0 | cpio --null -pdlu $kerneldir
-        cd ${S}
-	find . -type d -name '.git*' -prune -o -type d -name '.kernel-meta' -prune -o -type f -print0 | cpio --null -pdlu $kerneldir
+    # create the directory structure
+    rm -f $kerneldir/build
+    rm -f $kerneldir/source
+    mkdir -p $kerneldir/build
 
-        # Explicitly set KBUILD_OUTPUT to ensure that the image directory is cleaned and not
-        # The main build artifacts. We clean the directory to avoid QA errors on mismatched
-        # architecture (since scripts and helpers are native format).
-        KBUILD_OUTPUT="$kerneldir"
-        oe_runmake -C $kerneldir CC="${KERNEL_CC}" LD="${KERNEL_LD}" clean _mrproper_scripts
-        # make clean generates an absolute path symlink called "source"
-        # in $kerneldir points to $kerneldir, which doesn't make any
-        # sense, so remove it.
-        if [ -L $kerneldir/source ]; then
-            bbnote "Removing $kerneldir/source symlink"
-            rm -f $kerneldir/source
-        fi
+    # for compatibility with some older variants of this package, we
+    # create  a /usr/src/kernel symlink to /lib/modules/<version>/source
+    mkdir -p ${D}/usr/src
+    (
+	cd ${D}/usr/src
+	ln -s ${KERNEL_BUILD_ROOT}${KERNEL_VERSION}/source kernel
+    )
 
-        # As of Linux kernel version 3.0.1, the clean target removes
-        # arch/powerpc/lib/crtsavres.o which is present in
-        # KBUILD_LDFLAGS_MODULE, making it required to build external modules.
-        if [ ${ARCH} = "powerpc" ]; then
-                mkdir -p $kerneldir/arch/powerpc/lib/
-                cp ${B}/arch/powerpc/lib/crtsavres.o $kerneldir/arch/powerpc/lib/crtsavres.o
-        fi
+    # for on target purposes, we unify build and source
+    (
+	cd $kerneldir
+	ln -s build source
+    )
 
-        # Remove fixdep/objtool as they won't be target binaries
-        for i in fixdep objtool; do
-                if [ -e $kerneldir/tools/objtool/$i ]; then
-                        rm -rf $kerneldir/tools/objtool/$i
-                fi
-        done
+    # first copy everything
+    (
+	cd ${S}
+	cp --parents $(find  -type f -name "Makefile*" -o -name "Kconfig*") $kerneldir/build
+	cp --parents $(find  -type f -name "Build" -o -name "Build.include") $kerneldir/build
+    )
 
-        chown -R root:root ${D}
+    # then drop all but the needed Makefiles/Kconfig files
+    rm -rf $kerneldir/build/Documentation
+    rm -rf $kerneldir/build/scripts
+    rm -rf $kerneldir/build/include
+
+    # now copy in parts from the build that we'll need later
+    (
+	cd ${B}
+
+	cp Module.symvers $kerneldir/build
+	cp System.map* $kerneldir/build
+	if [ -s Module.markers ]; then
+	    cp Module.markers $kerneldir/build
+	fi
+
+	cp .config $kerneldir/build
+
+	# This scripts copy blow up QA, so for now, we require a more
+	# complex 'make scripts' to restore these, versus copying them
+	# here. Left as a reference to indicate that we know the scripts must
+	# be dealt with.
+	# cp -a scripts $kerneldir/build
+
+        if [ -d arch/${ARCH}/scripts ]; then
+	    cp -a arch/${ARCH}/scripts $kerneldir/build/arch/${ARCH}
+	fi
+	if [ -f arch/${ARCH}/*lds ]; then
+	    cp -a arch/${ARCH}/*lds $kerneldir/build/arch/${ARCH}
+	fi
+
+	rm -f $kerneldir/build/scripts/*.o
+	rm -f $kerneldir/build/scripts/*/*.o
+
+	if [ "${ARCH}" = "powerpc" ]; then
+	    if [ -e arch/powerpc/lib/crtsavres.S ] ||
+		   [ -e arch/powerpc/lib/crtsavres.o ]; then
+		cp -a --parents arch/powerpc/lib/crtsavres.[So] $kerneldir/build/
+	    fi
+	fi
+
+	if [ "${ARCH}" = "arm64" ]; then
+	    cp -a --parents arch/arm64/kernel/vdso/vdso.lds $kerneldir/build/
+	fi
+
+	cp -a include $kerneldir/build/include
+    )
+
+    # now grab the chunks from the source tree that we need
+    (
+	cd ${S}
+
+	cp -a scripts $kerneldir/build
+
+	# if our build dir had objtool, it will also be rebuilt on target, so
+	# we copy what is required for that build
+	if [ -f ${B}/tools/objtool/objtool ]; then
+	    # these are a few files associated with objtool, since we'll need to
+	    # rebuild it
+	    cp -a --parents tools/build/Build.include $kerneldir/build/
+	    cp -a --parents tools/build/Build $kerneldir/build/
+	    cp -a --parents tools/build/fixdep.c $kerneldir/build/
+	    cp -a --parents tools/scripts/utilities.mak $kerneldir/build/
+
+	    # extra files, just in case
+	    cp -a --parents tools/objtool/* $kerneldir/build/
+	    cp -a --parents tools/lib/str_error_r.c $kerneldir/build/
+	    cp -a --parents tools/lib/string.c $kerneldir/build/
+	    cp -a --parents tools/lib/subcmd/* $kerneldir/build/
+
+	    cp -a --parents tools/include/* $kerneldir/build/
+	fi
+
+	if [ "${ARCH}" = "arm64" ]; then
+	    # arch/arm64/include/asm/xen references arch/arm
+	    cp -a --parents arch/arm/include/asm/xen $kerneldir/build/
+	    # arch/arm64/include/asm/opcodes.h references arch/arm
+	    cp -a --parents arch/arm/include/asm/opcodes.h $kerneldir/build/
+
+            cp -a --parents arch/arm64/kernel/vdso/gettimeofday.S $kerneldir/build/
+            cp -a --parents arch/arm64/kernel/vdso/sigreturn.S $kerneldir/build/
+            cp -a --parents arch/arm64/kernel/vdso/note.S $kerneldir/build/
+            cp -a --parents arch/arm64/kernel/vdso/gen_vdso_offsets.sh $kerneldir/build/
+
+            cp -a --parents arch/arm64/kernel/module.lds $kerneldir/build/
+	fi
+
+	# include the machine specific headers for ARM variants, if available.
+	if [ "${ARCH}" = "arm" ]; then
+	    cp -a --parents arch/${ARCH}/mach-*/include $kerneldir/build/
+
+	    # include a few files for 'make prepare'
+	    cp -a --parents arch/arm/tools/gen-mach-types $kerneldir/build/
+	    cp -a --parents arch/arm/tools/mach-types $kerneldir/build/
+	    cp -a --parents arch/arm/tools/syscall* $kerneldir/build/
+
+            cp -a --parents arch/arm/kernel/module.lds $kerneldir/build/
+	fi
+
+	if [ -d arch/${ARCH}/include ]; then
+	    cp -a --parents arch/${ARCH}/include $kerneldir/build/
+	fi
+
+	cp -a include $kerneldir/build
+
+	cp -a --parents tools/include/tools/le_byteshift.h $kerneldir/build/
+	cp -a --parents tools/include/tools/be_byteshift.h $kerneldir/build/
+
+	# required for generate missing syscalls prepare phase
+	cp -a --parents arch/x86/entry/syscalls/syscall_32.tbl $kerneldir/build
+
+	if [ "${ARCH}" = "x86" ]; then
+	    # files for 'make prepare' to succeed with kernel-devel
+	    cp -a --parents arch/x86/entry/syscalls/syscall_32.tbl $kerneldir/build/
+	    cp -a --parents arch/x86/entry/syscalls/syscalltbl.sh $kerneldir/build/
+	    cp -a --parents arch/x86/entry/syscalls/syscallhdr.sh $kerneldir/build/
+	    cp -a --parents arch/x86/entry/syscalls/syscall_64.tbl $kerneldir/build/
+	    cp -a --parents arch/x86/tools/relocs_32.c $kerneldir/build/
+	    cp -a --parents arch/x86/tools/relocs_64.c $kerneldir/build/
+	    cp -a --parents arch/x86/tools/relocs.c $kerneldir/build/
+	    cp -a --parents arch/x86/tools/relocs_common.c $kerneldir/build/
+	    cp -a --parents arch/x86/tools/relocs.h $kerneldir/build/
+	    cp -a --parents arch/x86/purgatory/purgatory.c $kerneldir/build/
+
+	    # 4.18 + have unified the purgatory files, so we ignore any errors if
+	    # these files are not present
+	    cp -a --parents arch/x86/purgatory/sha256.h $kerneldir/build/ 2>/dev/null || :
+	    cp -a --parents arch/x86/purgatory/sha256.c $kerneldir/build/ 2>/dev/null || :
+
+	    cp -a --parents arch/x86/purgatory/stack.S $kerneldir/build/
+	    cp -a --parents arch/x86/purgatory/string.c $kerneldir/build/
+	    cp -a --parents arch/x86/purgatory/setup-x86_64.S $kerneldir/build/
+	    cp -a --parents arch/x86/purgatory/entry64.S $kerneldir/build/
+	    cp -a --parents arch/x86/boot/string.h $kerneldir/build/
+	    cp -a --parents arch/x86/boot/string.c $kerneldir/build/
+	    cp -a --parents arch/x86/boot/ctype.h $kerneldir/build/
+	fi
+
+	if [ "${ARCH}" = "mips" ]; then
+	    cp -a --parents arch/mips/Kbuild.platforms $kerneldir/build/
+	    cp --parents $(find	 -type f -name "Platform") $kerneldir/build
+	    cp --parents arch/mips/boot/tools/relocs* $kerneldir/build
+	    cp -a --parents arch/mips/kernel/asm-offsets.c $kerneldir/build
+	    cp -a --parents kernel/time/timeconst.bc $kerneldir/build
+	    cp -a --parents kernel/bounds.c $kerneldir/build
+	    cp -a --parents Kbuild $kerneldir/build
+	fi
+
+        # required to build scripts/selinux/genheaders/genheaders
+        cp -a --parents security/selinux/include/* $kerneldir/build/
+    )
+
+    # Make sure the Makefile and version.h have a matching timestamp so that
+    # external modules can be built
+    touch -r $kerneldir/build/Makefile $kerneldir/build/include/generated/uapi/linux/version.h
+
+    # Copy .config to include/config/auto.conf so "make prepare" is unnecessary.
+    cp $kerneldir/build/.config $kerneldir/build/include/config/auto.conf
+
+    chown -R root:root ${D}
 }
+
 # Ensure we don't race against "make scripts" during cpio
 do_install[lockfiles] = "${TMPDIR}/kernel-scripts.lock"
 
-PACKAGES = "kernel-devsrc"
-FILES_${PN} = "${KERNEL_SRC_PATH}"
-RDEPENDS_${PN} = "bc"
+FILES_${PN} = "${KERNEL_BUILD_ROOT} ${KERNEL_SRC_PATH}"
+FILES_${PN}-dbg += "${KERNEL_BUILD_ROOT}*/build/scripts/*/.debug/*"
+
+RDEPENDS_${PN} = "bc python flex bison ${TCLIBC}-utils"
+# 4.15+ needs these next two RDEPENDS
+RDEPENDS_${PN} += "openssl-dev util-linux"
+# and x86 needs a bit more for 4.15+
+RDEPENDS_${PN} += "${@bb.utils.contains('ARCH', 'x86', 'elfutils', '', d)}"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto-dev.bb b/poky/meta/recipes-kernel/linux/linux-yocto-dev.bb
index 4201faf..23cb355 100644
--- a/poky/meta/recipes-kernel/linux/linux-yocto-dev.bb
+++ b/poky/meta/recipes-kernel/linux/linux-yocto-dev.bb
@@ -10,6 +10,8 @@
 
 inherit kernel
 require recipes-kernel/linux/linux-yocto.inc
+# for ncurses tests
+inherit pkgconfig
 
 # provide this .inc to set specific revisions
 include recipes-kernel/linux/linux-yocto-dev-revisions.inc
@@ -28,10 +30,12 @@
 SRCREV_machine ?= '${@oe.utils.conditional("PREFERRED_PROVIDER_virtual/kernel", "linux-yocto-dev", "${AUTOREV}", "29594404d7fe73cd80eaa4ee8c43dcc53970c60e", d)}'
 SRCREV_meta ?= '${@oe.utils.conditional("PREFERRED_PROVIDER_virtual/kernel", "linux-yocto-dev", "${AUTOREV}", "29594404d7fe73cd80eaa4ee8c43dcc53970c60e", d)}'
 
-LINUX_VERSION ?= "4.16-rc+"
+LINUX_VERSION ?= "4.19-rc+"
 LINUX_VERSION_EXTENSION ?= "-yoctodev-${LINUX_KERNEL_TYPE}"
 PV = "${LINUX_VERSION}+git${SRCPV}"
 
+LIC_FILES_CHKSUM = "file://COPYING;md5=bbea815ee2795b2f4230826c0c6b8814"
+
 DEPENDS += "${@bb.utils.contains('ARCH', 'x86', 'elfutils-native', '', d)}"
 DEPENDS += "openssl-native util-linux-native"
 
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.12.bb b/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.12.bb
deleted file mode 100644
index a6a8b60..0000000
--- a/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.12.bb
+++ /dev/null
@@ -1,38 +0,0 @@
-KBRANCH ?= "standard/preempt-rt/base"
-
-require recipes-kernel/linux/linux-yocto.inc
-
-# Skip processing of this recipe if it is not explicitly specified as the
-# PREFERRED_PROVIDER for virtual/kernel. This avoids errors when trying
-# to build multiple virtual/kernel providers, e.g. as dependency of
-# core-image-rt-sdk, core-image-rt.
-python () {
-    if d.getVar("KERNEL_PACKAGE_NAME") == "kernel" and d.getVar("PREFERRED_PROVIDER_virtual/kernel") != "linux-yocto-rt":
-        raise bb.parse.SkipRecipe("Set PREFERRED_PROVIDER_virtual/kernel to linux-yocto-rt to enable it")
-}
-
-SRCREV_machine ?= "ef88c3326f62cec4b98340324ddbe7f7f7704fd5"
-SRCREV_meta ?= "2ae65226f64ed5c888d60eef76b6249db678d060"
-
-SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.12.git;branch=${KBRANCH};name=machine \
-           git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.12;destsuffix=${KMETA}"
-
-LINUX_VERSION ?= "4.12.28"
-
-PV = "${LINUX_VERSION}+git${SRCPV}"
-
-KMETA = "kernel-meta"
-KCONF_BSP_AUDIT_LEVEL = "2"
-
-LINUX_KERNEL_TYPE = "preempt-rt"
-
-COMPATIBLE_MACHINE = "(qemux86|qemux86-64|qemuarm|qemuppc|qemumips)"
-
-KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb"
-
-# Functionality flags
-KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc features/taskstats/taskstats.scc"
-KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}"
-KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc"
-KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.15.bb b/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.15.bb
deleted file mode 100644
index d166a40..0000000
--- a/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.15.bb
+++ /dev/null
@@ -1,41 +0,0 @@
-KBRANCH ?= "v4.15/standard/preempt-rt/base"
-
-require recipes-kernel/linux/linux-yocto.inc
-
-# Skip processing of this recipe if it is not explicitly specified as the
-# PREFERRED_PROVIDER for virtual/kernel. This avoids errors when trying
-# to build multiple virtual/kernel providers, e.g. as dependency of
-# core-image-rt-sdk, core-image-rt.
-python () {
-    if d.getVar("KERNEL_PACKAGE_NAME") == "kernel" and d.getVar("PREFERRED_PROVIDER_virtual/kernel") != "linux-yocto-rt":
-        raise bb.parse.SkipRecipe("Set PREFERRED_PROVIDER_virtual/kernel to linux-yocto-rt to enable it")
-}
-
-SRCREV_machine ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_meta ?= "45c256a5ca6f9478bce212fec19e2bc273472631"
-
-SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;branch=${KBRANCH};name=machine \
-           git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.15;destsuffix=${KMETA}"
-
-LINUX_VERSION ?= "4.15.18"
-
-DEPENDS += "${@bb.utils.contains('ARCH', 'x86', 'elfutils-native', '', d)}"
-DEPENDS += "openssl-native util-linux-native"
-
-PV = "${LINUX_VERSION}+git${SRCPV}"
-
-KMETA = "kernel-meta"
-KCONF_BSP_AUDIT_LEVEL = "2"
-
-LINUX_KERNEL_TYPE = "preempt-rt"
-
-COMPATIBLE_MACHINE = "(qemux86|qemux86-64|qemuarm|qemuppc|qemumips)"
-
-KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb"
-
-# Functionality flags
-KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc features/taskstats/taskstats.scc"
-KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}"
-KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc"
-KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.18.bb b/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.18.bb
new file mode 100644
index 0000000..f77de3a
--- /dev/null
+++ b/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.18.bb
@@ -0,0 +1,43 @@
+KBRANCH ?= "v4.18/standard/preempt-rt/base"
+
+require recipes-kernel/linux/linux-yocto.inc
+
+# Skip processing of this recipe if it is not explicitly specified as the
+# PREFERRED_PROVIDER for virtual/kernel. This avoids errors when trying
+# to build multiple virtual/kernel providers, e.g. as dependency of
+# core-image-rt-sdk, core-image-rt.
+python () {
+    if d.getVar("KERNEL_PACKAGE_NAME") == "kernel" and d.getVar("PREFERRED_PROVIDER_virtual/kernel") != "linux-yocto-rt":
+        raise bb.parse.SkipRecipe("Set PREFERRED_PROVIDER_virtual/kernel to linux-yocto-rt to enable it")
+}
+
+SRCREV_machine ?= "8e00c30ce22f378ecb7f243b1df3d209b8ee29bc"
+SRCREV_meta ?= "bf98e195a4cf2404a064056b3593e83a7de84f25"
+
+SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;branch=${KBRANCH};name=machine \
+           git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.18;destsuffix=${KMETA}"
+
+LINUX_VERSION ?= "4.18.14"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=bbea815ee2795b2f4230826c0c6b8814"
+
+DEPENDS += "${@bb.utils.contains('ARCH', 'x86', 'elfutils-native', '', d)}"
+DEPENDS += "openssl-native util-linux-native"
+
+PV = "${LINUX_VERSION}+git${SRCPV}"
+
+KMETA = "kernel-meta"
+KCONF_BSP_AUDIT_LEVEL = "2"
+
+LINUX_KERNEL_TYPE = "preempt-rt"
+
+COMPATIBLE_MACHINE = "(qemux86|qemux86-64|qemuarm|qemuarm64|qemuppc|qemumips)"
+
+KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb"
+
+# Functionality flags
+KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc features/taskstats/taskstats.scc"
+KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}"
+KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc"
+KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
+KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc cfg/paravirt_kvm.scc"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.12.bb b/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.12.bb
deleted file mode 100644
index cb4ef3a..0000000
--- a/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.12.bb
+++ /dev/null
@@ -1,25 +0,0 @@
-KBRANCH ?= "standard/tiny/common-pc"
-LINUX_KERNEL_TYPE = "tiny"
-KCONFIG_MODE = "--allnoconfig"
-
-require recipes-kernel/linux/linux-yocto.inc
-
-LINUX_VERSION ?= "4.12.28"
-
-KMETA = "kernel-meta"
-KCONF_BSP_AUDIT_LEVEL = "2"
-
-SRCREV_machine ?= "e562267bae5b518acca880c929fbbdf6be047e0a"
-SRCREV_meta ?= "2ae65226f64ed5c888d60eef76b6249db678d060"
-
-PV = "${LINUX_VERSION}+git${SRCPV}"
-
-SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.12.git;branch=${KBRANCH};name=machine \
-           git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.12;destsuffix=${KMETA}"
-
-COMPATIBLE_MACHINE = "qemux86|qemux86-64"
-
-# Functionality flags
-KERNEL_FEATURES = ""
-
-KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.15.bb b/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.15.bb
deleted file mode 100644
index 5f9b3c7..0000000
--- a/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.15.bb
+++ /dev/null
@@ -1,25 +0,0 @@
-KBRANCH ?= "v4.15/standard/tiny/common-pc"
-LINUX_KERNEL_TYPE = "tiny"
-KCONFIG_MODE = "--allnoconfig"
-
-require recipes-kernel/linux/linux-yocto.inc
-
-LINUX_VERSION ?= "4.15.18"
-
-KMETA = "kernel-meta"
-KCONF_BSP_AUDIT_LEVEL = "2"
-
-SRCREV_machine ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_meta ?= "45c256a5ca6f9478bce212fec19e2bc273472631"
-
-PV = "${LINUX_VERSION}+git${SRCPV}"
-
-SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;branch=${KBRANCH};name=machine \
-           git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.15;destsuffix=${KMETA}"
-
-COMPATIBLE_MACHINE = "qemux86|qemux86-64"
-
-# Functionality flags
-KERNEL_FEATURES = ""
-
-KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.18.bb b/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.18.bb
new file mode 100644
index 0000000..591d41b
--- /dev/null
+++ b/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.18.bb
@@ -0,0 +1,29 @@
+KBRANCH ?= "v4.18/standard/tiny/common-pc"
+LINUX_KERNEL_TYPE = "tiny"
+KCONFIG_MODE = "--allnoconfig"
+
+require recipes-kernel/linux/linux-yocto.inc
+
+LINUX_VERSION ?= "4.18.14"
+LIC_FILES_CHKSUM = "file://COPYING;md5=bbea815ee2795b2f4230826c0c6b8814"
+
+DEPENDS += "${@bb.utils.contains('ARCH', 'x86', 'elfutils-native', '', d)}"
+DEPENDS += "openssl-native util-linux-native"
+
+KMETA = "kernel-meta"
+KCONF_BSP_AUDIT_LEVEL = "2"
+
+SRCREV_machine ?= "33859b3077c83d8a024946ba06a59990546fcbc7"
+SRCREV_meta ?= "bf98e195a4cf2404a064056b3593e83a7de84f25"
+
+PV = "${LINUX_VERSION}+git${SRCPV}"
+
+SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;branch=${KBRANCH};name=machine \
+           git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.18;destsuffix=${KMETA}"
+
+COMPATIBLE_MACHINE = "qemux86|qemux86-64"
+
+# Functionality flags
+KERNEL_FEATURES = ""
+
+KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto.inc b/poky/meta/recipes-kernel/linux/linux-yocto.inc
index 3bb872a..1ebfb60 100644
--- a/poky/meta/recipes-kernel/linux/linux-yocto.inc
+++ b/poky/meta/recipes-kernel/linux/linux-yocto.inc
@@ -2,7 +2,7 @@
 SECTION = "kernel"
 LICENSE = "GPLv2"
 
-LIC_FILES_CHKSUM = "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
+LIC_FILES_CHKSUM ?= "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
 
 UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+\.\d+(\.\d+)*)"
 
@@ -28,6 +28,8 @@
 
 KERNEL_FEATURES_append_qemuall=" features/debug/printk.scc"
 
+KERNEL_FEATURES_append = " ${@bb.utils.contains('MACHINE_FEATURES', 'numa', 'features/numa/numa.scc', '', d)}"
+
 # A KMACHINE is the mapping of a yocto $MACHINE to what is built
 # by the kernel. This is typically the branch that should be built,
 # and it can be specific to the machine or shared
@@ -67,3 +69,6 @@
 addtask kernel_version_sanity_check after do_kernel_metadata do_kernel_checkout before do_compile
 addtask validate_branches before do_patch after do_kernel_checkout
 addtask kernel_configcheck after do_configure before do_compile
+
+# enable kernel-sample for oeqa/runtime/cases's ksample.py test
+KERNEL_FEATURES_append_qemuall=" features/kernel-sample/kernel-sample.scc"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto_4.12.bb b/poky/meta/recipes-kernel/linux/linux-yocto_4.12.bb
deleted file mode 100644
index 0aea05b..0000000
--- a/poky/meta/recipes-kernel/linux/linux-yocto_4.12.bb
+++ /dev/null
@@ -1,46 +0,0 @@
-KBRANCH ?= "standard/base"
-
-require recipes-kernel/linux/linux-yocto.inc
-
-# board specific branches
-KBRANCH_qemuarm  ?= "standard/arm-versatile-926ejs"
-KBRANCH_qemuarm64 ?= "standard/qemuarm64"
-KBRANCH_qemumips ?= "standard/mti-malta32"
-KBRANCH_qemuppc  ?= "standard/qemuppc"
-KBRANCH_qemux86  ?= "standard/base"
-KBRANCH_qemux86-64 ?= "standard/base"
-KBRANCH_qemumips64 ?= "standard/mti-malta64"
-
-SRCREV_machine_qemuarm ?= "b84ecefc243a6ed67d8b6020394963de1240a9f0"
-SRCREV_machine_qemuarm64 ?= "e562267bae5b518acca880c929fbbdf6be047e0a"
-SRCREV_machine_qemumips ?= "15b1ab68f73fa60dd95a74c640e87e05fad1716d"
-SRCREV_machine_qemuppc ?= "e562267bae5b518acca880c929fbbdf6be047e0a"
-SRCREV_machine_qemux86 ?= "e562267bae5b518acca880c929fbbdf6be047e0a"
-SRCREV_machine_qemux86-64 ?= "e562267bae5b518acca880c929fbbdf6be047e0a"
-SRCREV_machine_qemumips64 ?= "57a3f72a020fc84f2da5b0b4c5de4cdbc22b3284"
-SRCREV_machine ?= "e562267bae5b518acca880c929fbbdf6be047e0a"
-SRCREV_meta ?= "2ae65226f64ed5c888d60eef76b6249db678d060"
-
-SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.12.git;name=machine;branch=${KBRANCH}; \
-           git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.12;destsuffix=${KMETA}"
-
-DEPENDS += "openssl-native util-linux-native"
-
-LINUX_VERSION ?= "4.12.28"
-
-PV = "${LINUX_VERSION}+git${SRCPV}"
-
-KMETA = "kernel-meta"
-KCONF_BSP_AUDIT_LEVEL = "2"
-
-KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb"
-
-COMPATIBLE_MACHINE = "qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
-
-# Functionality flags
-KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc"
-KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}"
-KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc"
-KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES_append = " ${@bb.utils.contains("TUNE_FEATURES", "mx32", " cfg/x32.scc", "" ,d)}"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto_4.15.bb b/poky/meta/recipes-kernel/linux/linux-yocto_4.15.bb
deleted file mode 100644
index 693670c..0000000
--- a/poky/meta/recipes-kernel/linux/linux-yocto_4.15.bb
+++ /dev/null
@@ -1,47 +0,0 @@
-KBRANCH ?= "v4.15/standard/base"
-
-require recipes-kernel/linux/linux-yocto.inc
-
-# board specific branches
-KBRANCH_qemuarm  ?= "v4.15/standard/arm-versatile-926ejs"
-KBRANCH_qemuarm64 ?= "v4.15/standard/qemuarm64"
-KBRANCH_qemumips ?= "v4.15/standard/mti-malta32"
-KBRANCH_qemuppc  ?= "v4.15/standard/qemuppc"
-KBRANCH_qemux86  ?= "v4.15/standard/base"
-KBRANCH_qemux86-64 ?= "v4.15/standard/base"
-KBRANCH_qemumips64 ?= "v4.15/standard/mti-malta64"
-
-SRCREV_machine_qemuarm ?= "d16b10fb69974f1804a02f2678f40d22c80526cf"
-SRCREV_machine_qemuarm64 ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_machine_qemumips ?= "182eaefab712f4360126e044c758e75d763d05c4"
-SRCREV_machine_qemuppc ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_machine_qemux86 ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_machine_qemux86-64 ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_machine_qemumips64 ?= "ce3876a091477260fcb1197e3c6565dfbf9c6e80"
-SRCREV_machine ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_meta ?= "45c256a5ca6f9478bce212fec19e2bc273472631"
-
-SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;name=machine;branch=${KBRANCH}; \
-           git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.15;destsuffix=${KMETA}"
-
-LINUX_VERSION ?= "4.15.18"
-
-DEPENDS += "${@bb.utils.contains('ARCH', 'x86', 'elfutils-native', '', d)}"
-DEPENDS += "openssl-native util-linux-native"
-
-PV = "${LINUX_VERSION}+git${SRCPV}"
-
-KMETA = "kernel-meta"
-KCONF_BSP_AUDIT_LEVEL = "2"
-
-KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb"
-
-COMPATIBLE_MACHINE = "qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
-
-# Functionality flags
-KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc"
-KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}"
-KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc"
-KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES_append = " ${@bb.utils.contains("TUNE_FEATURES", "mx32", " cfg/x32.scc", "" ,d)}"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto_4.18.bb b/poky/meta/recipes-kernel/linux/linux-yocto_4.18.bb
new file mode 100644
index 0000000..81160ca
--- /dev/null
+++ b/poky/meta/recipes-kernel/linux/linux-yocto_4.18.bb
@@ -0,0 +1,48 @@
+KBRANCH ?= "v4.18/standard/base"
+
+require recipes-kernel/linux/linux-yocto.inc
+
+# board specific branches
+KBRANCH_qemuarm  ?= "v4.18/standard/arm-versatile-926ejs"
+KBRANCH_qemuarm64 ?= "v4.18/standard/qemuarm64"
+KBRANCH_qemumips ?= "v4.18/standard/mti-malta32"
+KBRANCH_qemuppc  ?= "v4.18/standard/qemuppc"
+KBRANCH_qemux86  ?= "v4.18/standard/base"
+KBRANCH_qemux86-64 ?= "v4.18/standard/base"
+KBRANCH_qemumips64 ?= "v4.18/standard/mti-malta64"
+
+SRCREV_machine_qemuarm ?= "0573ed3c737c82b24fd661cc5ea961cac07ea2fe"
+SRCREV_machine_qemuarm64 ?= "33859b3077c83d8a024946ba06a59990546fcbc7"
+SRCREV_machine_qemumips ?= "465252ba0ec00ae10397cb4623c3d77c89e542a5"
+SRCREV_machine_qemuppc ?= "33859b3077c83d8a024946ba06a59990546fcbc7"
+SRCREV_machine_qemux86 ?= "33859b3077c83d8a024946ba06a59990546fcbc7"
+SRCREV_machine_qemux86-64 ?= "33859b3077c83d8a024946ba06a59990546fcbc7"
+SRCREV_machine_qemumips64 ?= "6d91dc62811f4688efc67845185858645b4ccfb8"
+SRCREV_machine ?= "33859b3077c83d8a024946ba06a59990546fcbc7"
+SRCREV_meta ?= "bf98e195a4cf2404a064056b3593e83a7de84f25"
+
+SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;name=machine;branch=${KBRANCH}; \
+           git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.18;destsuffix=${KMETA}"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=bbea815ee2795b2f4230826c0c6b8814"
+LINUX_VERSION ?= "4.18.14"
+
+DEPENDS += "${@bb.utils.contains('ARCH', 'x86', 'elfutils-native', '', d)}"
+DEPENDS += "openssl-native util-linux-native"
+
+PV = "${LINUX_VERSION}+git${SRCPV}"
+
+KMETA = "kernel-meta"
+KCONF_BSP_AUDIT_LEVEL = "2"
+
+KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb"
+
+COMPATIBLE_MACHINE = "qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
+
+# Functionality flags
+KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc"
+KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}"
+KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc"
+KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
+KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc cfg/paravirt_kvm.scc"
+KERNEL_FEATURES_append = " ${@bb.utils.contains("TUNE_FEATURES", "mx32", " cfg/x32.scc", "" ,d)}"
diff --git a/poky/meta/recipes-kernel/lttng/babeltrace_1.5.4.bb b/poky/meta/recipes-kernel/lttng/babeltrace_1.5.4.bb
deleted file mode 100644
index a29402a..0000000
--- a/poky/meta/recipes-kernel/lttng/babeltrace_1.5.4.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-SUMMARY = "Babeltrace - Trace Format Babel Tower"
-DESCRIPTION = "Babeltrace provides trace read and write libraries in host side, as well as a trace converter, which used to convert LTTng 2.0 traces into human-readable log."
-HOMEPAGE = "http://www.efficios.com/babeltrace/"
-BUGTRACKER = "https://bugs.lttng.org/projects/babeltrace"
-
-LICENSE = "MIT & GPLv2"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=76ba15dd76a248e1dd526bca0e2125fa"
-
-DEPENDS = "glib-2.0 util-linux popt bison-native flex-native"
-
-inherit autotools pkgconfig
-
-SRC_URI = "http://www.efficios.com/files/babeltrace/babeltrace-${PV}.tar.bz2 \
-"
-
-EXTRA_OECONF = "--disable-debug-info"
-
-SRC_URI[md5sum] = "3e8cdafec3ac0346a389870e87bf1344"
-SRC_URI[sha256sum] = "9643039923a0abc75a25b3d594cee0017423b57f10d2b625e96ed1e8d4891fc1"
diff --git a/poky/meta/recipes-kernel/lttng/babeltrace_1.5.6.bb b/poky/meta/recipes-kernel/lttng/babeltrace_1.5.6.bb
new file mode 100644
index 0000000..f5c31c4
--- /dev/null
+++ b/poky/meta/recipes-kernel/lttng/babeltrace_1.5.6.bb
@@ -0,0 +1,20 @@
+SUMMARY = "Babeltrace - Trace Format Babel Tower"
+DESCRIPTION = "Babeltrace provides trace read and write libraries in host side, as well as a trace converter, which used to convert LTTng 2.0 traces into human-readable log."
+HOMEPAGE = "http://www.efficios.com/babeltrace/"
+BUGTRACKER = "https://bugs.lttng.org/projects/babeltrace"
+LICENSE = "MIT & GPLv2"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=76ba15dd76a248e1dd526bca0e2125fa"
+
+DEPENDS = "glib-2.0 util-linux popt bison-native flex-native"
+
+SRC_URI = "git://git.linuxfoundation.org/diamon/babeltrace.git;branch=stable-1.5"
+SRCREV = "4f10a4adabee5ca61c27ba399b3438505e0cd6de"
+UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+(\.\d+)+)$"
+
+S = "${WORKDIR}/git"
+
+inherit autotools pkgconfig
+
+EXTRA_OECONF = "--disable-debug-info"
+
+ASNEEDED = ""
diff --git a/poky/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-btrfs-Remove-unnecessary-fs_info-parameter.patch b/poky/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-btrfs-Remove-unnecessary-fs_info-parameter.patch
new file mode 100644
index 0000000..0fe4ee8
--- /dev/null
+++ b/poky/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-btrfs-Remove-unnecessary-fs_info-parameter.patch
@@ -0,0 +1,116 @@
+From 51ab0b1da29354375a19f865abcd233dd2178295 Mon Sep 17 00:00:00 2001
+From: Michael Jeanson <mjeanson@efficios.com>
+Date: Mon, 18 Jun 2018 14:53:19 -0400
+Subject: [PATCH] Fix: btrfs: Remove unnecessary fs_info parameter
+
+See upstream commit:
+
+  commit 3dca5c942dac60164e6a6e89172f25b86af07ce7
+  Author: Qu Wenruo <wqu@suse.com>
+  Date:   Thu Apr 26 14:24:25 2018 +0800
+
+    btrfs: trace: Remove unnecessary fs_info parameter for btrfs__reserve_extent event class
+
+    fs_info can be extracted from btrfs_block_group_cache, and all
+    btrfs_block_group_cache is created by btrfs_create_block_group_cache()
+    with fs_info initialized, no need to worry about NULL pointer
+    dereference.
+
+Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
+Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
+Upstream-Status: Backport
+Signed-off-by: He Zhe <zhe.he@windriver.com>
+---
+ instrumentation/events/lttng-module/btrfs.h | 54 ++++++++++++++++++++++++++++-
+ 1 file changed, 53 insertions(+), 1 deletion(-)
+
+diff --git a/instrumentation/events/lttng-module/btrfs.h b/instrumentation/events/lttng-module/btrfs.h
+index 75cc73b..fd1b6b8 100644
+--- a/instrumentation/events/lttng-module/btrfs.h
++++ b/instrumentation/events/lttng-module/btrfs.h
+@@ -1658,8 +1658,57 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserved_extent,  btrfs_reserved_extent_f
+ 
+ #endif /* #else #if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,10,0)) */
+ 
+-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0))
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,18,0))
++LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent,
++
++	btrfs_find_free_extent,
++
++	TP_PROTO(const struct btrfs_fs_info *info, u64 num_bytes, u64 empty_size,
++		 u64 data),
++
++	TP_ARGS(info, num_bytes, empty_size, data),
++
++	TP_FIELDS(
++		ctf_array(u8, fsid, info->fsid, BTRFS_UUID_SIZE)
++		ctf_integer(u64, num_bytes, num_bytes)
++		ctf_integer(u64, empty_size, empty_size)
++		ctf_integer(u64, data, data)
++	)
++)
++
++LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserve_extent,
++
++	TP_PROTO(const struct btrfs_block_group_cache *block_group, u64 start,
++		 u64 len),
++
++	TP_ARGS(block_group, start, len),
++
++	TP_FIELDS(
++		ctf_array(u8, fsid, block_group->fs_info->fsid, BTRFS_UUID_SIZE)
++		ctf_integer(u64, bg_objectid, block_group->key.objectid)
++		ctf_integer(u64, flags, block_group->flags)
++		ctf_integer(u64, start, start)
++		ctf_integer(u64, len, len)
++	)
++)
++
++LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent,
++
++	TP_PROTO(const struct btrfs_block_group_cache *block_group, u64 start,
++		 u64 len),
++
++	TP_ARGS(block_group, start, len)
++)
++
++LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent_cluster,
++
++	TP_PROTO(const struct btrfs_block_group_cache *block_group, u64 start,
++		 u64 len),
++
++	TP_ARGS(block_group, start, len)
++)
+ 
++#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0))
+ LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent,
+ 
+ 	btrfs_find_free_extent,
+@@ -1670,6 +1719,7 @@ LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent,
+ 	TP_ARGS(info, num_bytes, empty_size, data),
+ 
+ 	TP_FIELDS(
++		ctf_array(u8, fsid, info->fsid, BTRFS_UUID_SIZE)
+ 		ctf_integer(u64, num_bytes, num_bytes)
+ 		ctf_integer(u64, empty_size, empty_size)
+ 		ctf_integer(u64, data, data)
+@@ -1685,6 +1735,7 @@ LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserve_extent,
+ 	TP_ARGS(info, block_group, start, len),
+ 
+ 	TP_FIELDS(
++		ctf_array(u8, fsid, info->fsid, BTRFS_UUID_SIZE)
+ 		ctf_integer(u64, bg_objectid, block_group->key.objectid)
+ 		ctf_integer(u64, flags, block_group->flags)
+ 		ctf_integer(u64, start, start)
+@@ -1722,6 +1773,7 @@ LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent,
+ 	TP_ARGS(info, num_bytes, empty_size, data),
+ 
+ 	TP_FIELDS(
++		ctf_array(u8, fsid, info->fsid, BTRFS_UUID_SIZE)
+ 		ctf_integer(u64, num_bytes, num_bytes)
+ 		ctf_integer(u64, empty_size, empty_size)
+ 		ctf_integer(u64, data, data)
+-- 
+2.13.3
+
diff --git a/poky/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-net-expose-sk-wmem-in-sock_exceed_buf_limit-trac.patch b/poky/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-net-expose-sk-wmem-in-sock_exceed_buf_limit-trac.patch
new file mode 100644
index 0000000..92e12df
--- /dev/null
+++ b/poky/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-net-expose-sk-wmem-in-sock_exceed_buf_limit-trac.patch
@@ -0,0 +1,67 @@
+From 9e67b4c94b94493123d38379bd9b3eceae23a6f1 Mon Sep 17 00:00:00 2001
+From: Michael Jeanson <mjeanson@efficios.com>
+Date: Fri, 7 Sep 2018 12:21:12 -0400
+Subject: [PATCH] Fix: net: expose sk wmem in sock_exceed_buf_limit tracepoint
+ (4.19)
+
+See upstream commit:
+
+  commit d6f19938eb031ee2158272757db33258153ae59c
+  Author: Yafang Shao <laoar.shao@gmail.com>
+  Date:   Sun Jul 1 23:31:30 2018 +0800
+
+    net: expose sk wmem in sock_exceed_buf_limit tracepoint
+
+    Currently trace_sock_exceed_buf_limit() only show rmem info,
+    but wmem limit may also be hit.
+    So expose wmem info in this tracepoint as well.
+
+    Regarding memcg, I think it is better to introduce a new tracepoint(if
+    that is needed), i.e. trace_memcg_limit_hit other than show memcg info in
+    trace_sock_exceed_buf_limit.
+
+Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
+Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
+Upstream-Status: Backport
+Signed-off-by: He Zhe <zhe.he@windriver.com>
+---
+ instrumentation/events/lttng-module/sock.h | 23 ++++++++++++++++++++++-
+ 1 file changed, 22 insertions(+), 1 deletion(-)
+
+diff --git a/instrumentation/events/lttng-module/sock.h b/instrumentation/events/lttng-module/sock.h
+index 5cd02ca..cd0c92b 100644
+--- a/instrumentation/events/lttng-module/sock.h
++++ b/instrumentation/events/lttng-module/sock.h
+@@ -21,7 +21,28 @@ LTTNG_TRACEPOINT_EVENT(sock_rcvqueue_full,
+ 	)
+ )
+ 
+-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,15,0))
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,19,0))
++
++LTTNG_TRACEPOINT_EVENT(sock_exceed_buf_limit,
++
++	TP_PROTO(struct sock *sk, struct proto *prot, long allocated, int kind),
++
++	TP_ARGS(sk, prot, allocated, kind),
++
++	TP_FIELDS(
++		ctf_string(name, prot->name)
++		ctf_array(long, sysctl_mem, prot->sysctl_mem, 3)
++		ctf_integer(long, allocated, allocated)
++		ctf_integer(int, sysctl_rmem, sk_get_rmem0(sk, prot))
++		ctf_integer(int, rmem_alloc, atomic_read(&sk->sk_rmem_alloc))
++		ctf_integer(int, sysctl_wmem, sk_get_wmem0(sk, prot))
++		ctf_integer(int, wmem_alloc, refcount_read(&sk->sk_wmem_alloc))
++		ctf_integer(int, wmem_queued, sk->sk_wmem_queued)
++		ctf_integer(int, kind, kind)
++	)
++)
++
++#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(4,15,0))
+ 
+ LTTNG_TRACEPOINT_EVENT(sock_exceed_buf_limit,
+ 
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-kernel/lttng/lttng-modules_2.10.6.bb b/poky/meta/recipes-kernel/lttng/lttng-modules_2.10.6.bb
deleted file mode 100644
index 6146966..0000000
--- a/poky/meta/recipes-kernel/lttng/lttng-modules_2.10.6.bb
+++ /dev/null
@@ -1,35 +0,0 @@
-SECTION = "devel"
-SUMMARY = "Linux Trace Toolkit KERNEL MODULE"
-DESCRIPTION = "The lttng-modules 2.0 package contains the kernel tracer modules"
-LICENSE = "LGPLv2.1 & GPLv2 & MIT"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=c4613d1f8a9587bd7b366191830364b3 \
-                    file://gpl-2.0.txt;md5=751419260aa954499f7abaabaa882bbe \
-                    file://lgpl-2.1.txt;md5=243b725d71bb5df4a1e5920b344b86ad \
-                    "
-
-inherit module
-
-COMPATIBLE_HOST = '(x86_64|i.86|powerpc|aarch64|mips|nios2|arm).*-linux'
-
-SRC_URI = "https://lttng.org/files/${BPN}/${BPN}-${PV}.tar.bz2 \
-           file://Makefile-Do-not-fail-if-CONFIG_TRACEPOINTS-is-not-en.patch \
-           file://BUILD_RUNTIME_BUG_ON-vs-gcc7.patch \
-"
-
-SRC_URI[md5sum] = "8110099f4615fc89a74ffe9189b56cfc"
-SRC_URI[sha256sum] = "04a080c81743eb29d181bac29ceb0c15819a2f4210793f2cc9958d885435029f"
-
-export INSTALL_MOD_DIR="kernel/lttng-modules"
-
-EXTRA_OEMAKE += "KERNELDIR='${STAGING_KERNEL_DIR}'"
-
-do_install_append() {
-	# Delete empty directories to avoid QA failures if no modules were built
-	find ${D}/${nonarch_base_libdir} -depth -type d -empty -exec rmdir {} \;
-}
-
-python do_package_prepend() {
-    if not os.path.exists(os.path.join(d.getVar('D'), d.getVar('nonarch_base_libdir')[1:], 'modules')):
-        bb.warn("%s: no modules were created; this may be due to CONFIG_TRACEPOINTS not being enabled in your kernel." % d.getVar('PN'))
-}
-
diff --git a/poky/meta/recipes-kernel/lttng/lttng-modules_2.10.7.bb b/poky/meta/recipes-kernel/lttng/lttng-modules_2.10.7.bb
new file mode 100644
index 0000000..f6c865a
--- /dev/null
+++ b/poky/meta/recipes-kernel/lttng/lttng-modules_2.10.7.bb
@@ -0,0 +1,37 @@
+SECTION = "devel"
+SUMMARY = "Linux Trace Toolkit KERNEL MODULE"
+DESCRIPTION = "The lttng-modules 2.0 package contains the kernel tracer modules"
+LICENSE = "LGPLv2.1 & GPLv2 & MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=c4613d1f8a9587bd7b366191830364b3 \
+                    file://gpl-2.0.txt;md5=751419260aa954499f7abaabaa882bbe \
+                    file://lgpl-2.1.txt;md5=243b725d71bb5df4a1e5920b344b86ad \
+                    "
+
+inherit module
+
+COMPATIBLE_HOST = '(x86_64|i.86|powerpc|aarch64|mips|nios2|arm).*-linux'
+
+#https://lttng.org/files/lttng-modules/lttng-modules-2.10.7.tar.bz2
+SRC_URI = "https://lttng.org/files/${BPN}/${BPN}-${PV}.tar.bz2 \
+           file://Makefile-Do-not-fail-if-CONFIG_TRACEPOINTS-is-not-en.patch \
+           file://BUILD_RUNTIME_BUG_ON-vs-gcc7.patch \
+           file://0001-Fix-net-expose-sk-wmem-in-sock_exceed_buf_limit-trac.patch \
+"
+
+SRC_URI[md5sum] = "d3cb4520948083bf1573a2e4cb7406aa"
+SRC_URI[sha256sum] = "f049428d3d131e103a7a7038d184731bf7bcdce00503fc19a2c9b5693ecbb3b5"
+
+export INSTALL_MOD_DIR="kernel/lttng-modules"
+
+EXTRA_OEMAKE += "KERNELDIR='${STAGING_KERNEL_DIR}'"
+
+do_install_append() {
+	# Delete empty directories to avoid QA failures if no modules were built
+	find ${D}/${nonarch_base_libdir} -depth -type d -empty -exec rmdir {} \;
+}
+
+python do_package_prepend() {
+    if not os.path.exists(os.path.join(d.getVar('D'), d.getVar('nonarch_base_libdir')[1:], 'modules')):
+        bb.warn("%s: no modules were created; this may be due to CONFIG_TRACEPOINTS not being enabled in your kernel." % d.getVar('PN'))
+}
+
diff --git a/poky/meta/recipes-kernel/lttng/lttng-tools/0001-Allow-multiple-attempts-to-connect-to-relayd.patch b/poky/meta/recipes-kernel/lttng/lttng-tools/0001-Allow-multiple-attempts-to-connect-to-relayd.patch
new file mode 100644
index 0000000..62a0978
--- /dev/null
+++ b/poky/meta/recipes-kernel/lttng/lttng-tools/0001-Allow-multiple-attempts-to-connect-to-relayd.patch
@@ -0,0 +1,43 @@
+From 70eff899104b86bae02862927c76caaef5de5d3c Mon Sep 17 00:00:00 2001
+From: Mikael Beckius <mikael.beckius@windriver.com>
+Date: Thu, 7 May 2015 16:14:25 +0200
+Subject: [PATCH] Allow multiple attempts to connect to relayd.
+
+It is unclear why a session needs to be made
+unusable after a failure to connect to relayd
+since a check for a relayd connection is
+always made before a session can be configured.
+
+The behaviour was introduced in:
+d9078d0c000d04d49c599a72c1a725026b636ec0
+
+Signed-off-by: Mikael Beckius <mikael.beckius@windriver.com>
+[ The context has moved, adjust the hunk accordingly ]
+Signed-off-by: He Zhe <zhe.he@windriver.com>
+Upstream-Status: Pending
+---
+ src/bin/lttng-sessiond/cmd.c |    8 --------
+ 1 file changed, 8 deletions(-)
+
+diff --git a/src/bin/lttng-sessiond/cmd.c b/src/bin/lttng-sessiond/cmd.c
+index 73b4ce3..36f62ee 100644
+--- a/src/bin/lttng-sessiond/cmd.c
++++ b/src/bin/lttng-sessiond/cmd.c
+@@ -689,14 +689,6 @@ close_sock:
+ 	free(rsock);
+ 
+ error:
+-	if (ret != LTTNG_OK) {
+-		/*
+-		 * The consumer output for this session should not be used anymore
+-		 * since the relayd connection failed thus making any tracing or/and
+-		 * streaming not usable.
+-		 */
+-		consumer->enabled = 0;
+-	}
+ 	return ret;
+ }
+ 
+-- 
+1.7.9.5
+
diff --git a/poky/meta/recipes-kernel/lttng/lttng-tools/lttng-sessiond.service b/poky/meta/recipes-kernel/lttng/lttng-tools/lttng-sessiond.service
new file mode 100644
index 0000000..aaf8130
--- /dev/null
+++ b/poky/meta/recipes-kernel/lttng/lttng-tools/lttng-sessiond.service
@@ -0,0 +1,9 @@
+[Unit]
+Description=LTTng 2.x central tracing registry session daemon
+
+[Service]
+Type=forking
+ExecStart=/usr/bin/lttng-sessiond -d
+
+[Install]
+WantedBy=multi-user.target
diff --git a/poky/meta/recipes-kernel/lttng/lttng-tools_2.9.5.bb b/poky/meta/recipes-kernel/lttng/lttng-tools_2.9.5.bb
index 93626dd..0314b53 100644
--- a/poky/meta/recipes-kernel/lttng/lttng-tools_2.9.5.bb
+++ b/poky/meta/recipes-kernel/lttng/lttng-tools_2.9.5.bb
@@ -30,12 +30,17 @@
 SRC_URI = "https://lttng.org/files/lttng-tools/lttng-tools-${PV}.tar.bz2 \
            file://x32.patch \
            file://run-ptest \
+           file://0001-Allow-multiple-attempts-to-connect-to-relayd.patch \
+           file://lttng-sessiond.service \
            "
 
 SRC_URI[md5sum] = "051224eb991aee07f8721ff1877d0b96"
 SRC_URI[sha256sum] = "77839eb6fc6c652125f08acfd9369701c2516eb05cc2084160e7efc7a3fb731c"
 
-inherit autotools ptest pkgconfig useradd python3-dir manpages
+inherit autotools ptest pkgconfig useradd python3-dir manpages systemd
+
+SYSTEMD_SERVICE_${PN} = "lttng-sessiond.service"
+SYSTEMD_AUTO_ENABLE = "disable"
 
 USERADD_PACKAGES = "${PN}"
 GROUPADD_PARAM_${PN} = "tracing"
@@ -51,6 +56,12 @@
 INSANE_SKIP_${PN} = "libexec dev-so"
 INSANE_SKIP_${PN}-dbg = "libexec"
 
+do_install_append () {
+    # install systemd unit file
+    install -d ${D}${systemd_unitdir}/system
+    install -m 0644 ${WORKDIR}/lttng-sessiond.service ${D}${systemd_unitdir}/system
+}
+
 do_install_ptest () {
     for f in Makefile tests/Makefile tests/utils/utils.sh ; do
         install -D "${B}/$f" "${D}${PTEST_PATH}/$f"
diff --git a/poky/meta/recipes-kernel/perf/perf-perl.inc b/poky/meta/recipes-kernel/perf/perf-perl.inc
new file mode 100644
index 0000000..ae77319
--- /dev/null
+++ b/poky/meta/recipes-kernel/perf/perf-perl.inc
@@ -0,0 +1,7 @@
+inherit perlnative cpan-base
+
+# Env var which tells perl if it should use host (no) or target (yes) settings
+export PERLCONFIGTARGET = "${@is_target(d)}"
+export PERL_INC = "${STAGING_LIBDIR}${PERL_OWN_DIR}/perl/${@get_perl_version(d)}/CORE"
+export PERL_LIB = "${STAGING_LIBDIR}${PERL_OWN_DIR}/perl/${@get_perl_version(d)}"
+export PERL_ARCHLIB = "${STAGING_LIBDIR}${PERL_OWN_DIR}/perl/${@get_perl_version(d)}"
diff --git a/poky/meta/recipes-kernel/perf/perf.bb b/poky/meta/recipes-kernel/perf/perf.bb
index 90bbed2..bae4948 100644
--- a/poky/meta/recipes-kernel/perf/perf.bb
+++ b/poky/meta/recipes-kernel/perf/perf.bb
@@ -12,6 +12,7 @@
 PR = "r9"
 
 PACKAGECONFIG ??= "scripting tui libunwind"
+PACKAGECONFIG[dwarf] = ",NO_DWARF=1"
 PACKAGECONFIG[scripting] = ",NO_LIBPERL=1 NO_LIBPYTHON=1,perl python"
 # gui support was added with kernel 3.6.35
 # since 3.10 libnewt was replaced by slang
@@ -21,24 +22,26 @@
 PACKAGECONFIG[libnuma] = ",NO_LIBNUMA=1"
 PACKAGECONFIG[systemtap] = ",NO_SDT=1,systemtap"
 PACKAGECONFIG[jvmti] = ",NO_JVMTI=1"
-
 # libaudit support would need scripting to be enabled
 PACKAGECONFIG[audit] = ",NO_LIBAUDIT=1,audit"
+PACKAGECONFIG[manpages] = ",,xmlto-native asciidoc-native"
+
+# libunwind is not yet ported for some architectures
+PACKAGECONFIG_remove_arc = "libunwind"
+PACKAGECONFIG_remove_riscv64 = "libunwind"
 
 DEPENDS = " \
     virtual/${MLPREFIX}libc \
     ${MLPREFIX}elfutils \
     ${MLPREFIX}binutils \
     bison-native flex-native xz \
-    xmlto-native \
-    asciidoc-native \
 "
 
 do_configure[depends] += "virtual/kernel:do_shared_workdir"
 
 PROVIDES = "virtual/perf"
 
-inherit linux-kernel-base kernel-arch
+inherit linux-kernel-base kernel-arch manpages
 
 # needed for building the tools/perf Python bindings
 inherit ${@bb.utils.contains('PACKAGECONFIG', 'scripting', 'pythonnative', '', d)}
@@ -51,13 +54,7 @@
 do_populate_lic[depends] += "virtual/kernel:do_patch"
 
 # needed for building the tools/perf Perl binding
-inherit ${@bb.utils.contains('PACKAGECONFIG', 'scripting', 'perlnative', '', d)}
-inherit cpan-base
-# Env var which tells perl if it should use host (no) or target (yes) settings
-export PERLCONFIGTARGET = "${@is_target(d)}"
-export PERL_INC = "${STAGING_LIBDIR}${PERL_OWN_DIR}/perl/${@get_perl_version(d)}/CORE"
-export PERL_LIB = "${STAGING_LIBDIR}${PERL_OWN_DIR}/perl/${@get_perl_version(d)}"
-export PERL_ARCHLIB = "${STAGING_LIBDIR}${PERL_OWN_DIR}/perl/${@get_perl_version(d)}"
+include ${@bb.utils.contains('PACKAGECONFIG', 'scripting', 'perf-perl.inc', '', d)}
 
 inherit kernelsrc
 
@@ -80,8 +77,9 @@
     EXTRA_CFLAGS="-ldw" \
     EXTRA_LDFLAGS="${PERF_EXTRA_LDFLAGS}" \
     perfexecdir=${libexecdir} \
-    NO_GTK2=1 NO_DWARF=1 \
+    NO_GTK2=1 \
     ${PACKAGECONFIG_CONFARGS} \
+    TMPDIR="${B}" \
 '
 
 EXTRA_OEMAKE += "\
@@ -146,6 +144,8 @@
     for s in sources:
         src = oe.path.join(src_dir, s)
         dest = oe.path.join(dest_dir, s)
+        if not os.path.exists(src):
+            bb.fatal("Path does not exist: %s. Maybe PERF_SRC does not match the kernel version." % src)
         if os.path.isdir(src):
             oe.path.copyhardlinktree(src, dest)
         else:
@@ -246,7 +246,6 @@
 PACKAGES =+ "${PN}-archive ${PN}-tests ${PN}-perl ${PN}-python"
 
 RDEPENDS_${PN} += "elfutils bash"
-RDEPENDS_${PN}-doc += "man"
 RDEPENDS_${PN}-archive =+ "bash"
 RDEPENDS_${PN}-python =+ "bash python python-modules ${@bb.utils.contains('PACKAGECONFIG', 'audit', 'audit-python', '', d)}"
 RDEPENDS_${PN}-perl =+ "bash perl perl-modules"
diff --git a/poky/meta/recipes-kernel/sysprof/files/0001-Do-not-build-anything-in-help-as-it-requires-itstool.patch b/poky/meta/recipes-kernel/sysprof/files/0001-Do-not-build-anything-in-help-as-it-requires-itstool.patch
index e28fdca..ade51cf 100644
--- a/poky/meta/recipes-kernel/sysprof/files/0001-Do-not-build-anything-in-help-as-it-requires-itstool.patch
+++ b/poky/meta/recipes-kernel/sysprof/files/0001-Do-not-build-anything-in-help-as-it-requires-itstool.patch
@@ -1,26 +1,27 @@
-From c2495a4c042e6a675da69bab20cc3669391e8e2a Mon Sep 17 00:00:00 2001
+From d332b480257aa98b63d39c3c94896a111536f937 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Wed, 23 Aug 2017 18:38:26 +0300
-Subject: [PATCH 1/2] Do not build anything in help/ as it requires itstool.
+Subject: [PATCH 2/2] Do not build anything in help/ as it requires itstool.
 
 Upstream-Status: Inappropriate [oe-core specific]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
 ---
  meson.build | 1 -
  1 file changed, 1 deletion(-)
 
 diff --git a/meson.build b/meson.build
-index 4ac3934..8c4369a 100644
+index 3986273..ae2f65e 100644
 --- a/meson.build
 +++ b/meson.build
-@@ -116,7 +116,6 @@ subdir('tools')
+@@ -164,7 +164,6 @@ subdir('tools')
  subdir('tests')
  
  subdir('data')
 -subdir('help')
  subdir('po')
  
- meson.add_install_script('build-aux/meson_post_install.sh')
+ meson.add_install_script('build-aux/meson/post_install.sh')
 -- 
-2.14.1
+2.7.4
 
diff --git a/poky/meta/recipes-kernel/sysprof/files/0001-fix-non-literal-format-string-issues.patch b/poky/meta/recipes-kernel/sysprof/files/0001-fix-non-literal-format-string-issues.patch
new file mode 100644
index 0000000..38f9f5f
--- /dev/null
+++ b/poky/meta/recipes-kernel/sysprof/files/0001-fix-non-literal-format-string-issues.patch
@@ -0,0 +1,34 @@
+From de13d1f908335cc882c447e4d7c4360b9e5da190 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 6 Sep 2018 17:49:44 -0700
+Subject: [PATCH] fix non-literal format string issues
+
+clang errors out when using -Werror=format-nonliteral
+since the definition of g_strdup_vprintf() from glib-2.0
+is using va_list and clangs still warns where as
+gcc doesn't do that for va_list arguments
+
+Fixes
+src/sp-window.c:96:27: error: format string is not a string literal [-Werror,-Wformat-nonliteral]
+|   str = g_strdup_vprintf (format, args);
+|                           ^~~~~~
+
+Upstream-Status: Submitted [https://gitlab.gnome.org/GNOME/sysprof/merge_requests/6]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/sp-window.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/sp-window.c b/src/sp-window.c
+index 4dfac2d..aff4779 100644
+--- a/src/sp-window.c
++++ b/src/sp-window.c
+@@ -80,7 +80,7 @@ static guint signals [N_SIGNALS];
+ static void sp_window_set_profiler (SpWindow   *self,
+                                     SpProfiler *profiler);
+ 
+-static void
++static G_GNUC_PRINTF(3, 4) void
+ sp_window_notify_user (SpWindow       *self,
+                        GtkMessageType  message_type,
+                        const gchar    *format,
diff --git a/poky/meta/recipes-kernel/sysprof/files/wordsize.patch b/poky/meta/recipes-kernel/sysprof/files/wordsize.patch
new file mode 100644
index 0000000..d65b13a
--- /dev/null
+++ b/poky/meta/recipes-kernel/sysprof/files/wordsize.patch
@@ -0,0 +1,38 @@
+Upstream-Status: Submitted [https://gitlab.gnome.org/GNOME/sysprof/merge_requests/5]
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+From bc7e3e27c28d0bab8bea72f2314191532b2e7840 Mon Sep 17 00:00:00 2001
+From: Ross Burton <ross.burton@intel.com>
+Date: Fri, 7 Sep 2018 01:30:09 +0100
+Subject: [PATCH] capture: use size of void* instead of glibc-specific
+ __WORDSIZE
+
+__WORDSIZE is glibc-specific so sp-capture-types.h doesn't work with musl.
+---
+ lib/capture/sp-capture-types.h | 6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/lib/capture/sp-capture-types.h b/lib/capture/sp-capture-types.h
+index 48fcfb8..1d6cd1d 100644
+--- a/lib/capture/sp-capture-types.h
++++ b/lib/capture/sp-capture-types.h
+@@ -32,12 +32,14 @@ G_BEGIN_DECLS
+ #define SP_CAPTURE_MAGIC (GUINT32_TO_LE(0xFDCA975E))
+ #define SP_CAPTURE_ALIGN (sizeof(SpCaptureAddress))
+ 
+-#if __WORDSIZE == 64
++#if GLIB_SIZEOF_VOID_P == 8
+ # define SP_CAPTURE_JITMAP_MARK    G_GUINT64_CONSTANT(0xE000000000000000)
+ # define SP_CAPTURE_ADDRESS_FORMAT "0x%016lx"
+-#else
++#elif GLIB_SIZEOF_VOID_P == 4
+ # define SP_CAPTURE_JITMAP_MARK    G_GUINT64_CONSTANT(0xE0000000)
+ # define SP_CAPTURE_ADDRESS_FORMAT "0x%016llx"
++#else
++#error Unknown GLIB_SIZEOF_VOID_P
+ #endif
+ 
+ #define SP_CAPTURE_CURRENT_TIME   (sp_clock_get_current_time())
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-kernel/sysprof/sysprof_3.26.1.bb b/poky/meta/recipes-kernel/sysprof/sysprof_3.26.1.bb
deleted file mode 100644
index 1989b52..0000000
--- a/poky/meta/recipes-kernel/sysprof/sysprof_3.26.1.bb
+++ /dev/null
@@ -1,34 +0,0 @@
-SUMMARY = "System-wide Performance Profiler for Linux"
-HOMEPAGE = "http://www.sysprof.com"
-LICENSE = "GPLv3+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
-                    file://src/sp-application.c;endline=17;md5=40e55577ef122c88fe20052acda64875"
-
-GNOMEBASEBUILDCLASS = "meson"
-inherit gnomebase gettext systemd upstream-version-is-even
-
-DEPENDS = "glib-2.0 libxml2-native glib-2.0-native"
-
-SRC_URI[archive.md5sum] = "6f9f947960ba79bb1269d8ee49b7db78"
-SRC_URI[archive.sha256sum] = "d8b9d5c2246696e4a3776a312731dc7c014fbd33478bb14d5512c6f1f35a3b11"
-SRC_URI += " \
-           file://define-NT_GNU_BUILD_ID.patch \
-           file://0001-Do-not-build-anything-in-help-as-it-requires-itstool.patch \
-           "
-
-PACKAGECONFIG ?= "${@bb.utils.contains_any('DISTRO_FEATURES', '${GTK3DISTROFEATURES}', 'gtk', '', d)}"
-PACKAGECONFIG[gtk] = "-Denable_gtk=true,-Denable_gtk=false,gtk+3"
-PACKAGECONFIG[sysprofd] = "-Dwith_sysprofd=bundled,-Dwith_sysprofd=none,polkit"
-
-SOLIBS = ".so"
-FILES_SOLIBSDEV = ""
-
-SYSTEMD_SERVICE_${PN} = "${@bb.utils.contains('PACKAGECONFIG', 'sysprofd', 'sysprof2.service', '', d)}"
-
-# We do not yet work for aarch64.
-COMPATIBLE_HOST = "^(?!aarch64).*"
-
-FILES_${PN} += " \
-               ${datadir}/dbus-1/system-services \
-               ${datadir}/dbus-1/system.d \
-               "
diff --git a/poky/meta/recipes-kernel/sysprof/sysprof_3.30.0.bb b/poky/meta/recipes-kernel/sysprof/sysprof_3.30.0.bb
new file mode 100644
index 0000000..19dcf25
--- /dev/null
+++ b/poky/meta/recipes-kernel/sysprof/sysprof_3.30.0.bb
@@ -0,0 +1,35 @@
+SUMMARY = "System-wide Performance Profiler for Linux"
+HOMEPAGE = "http://www.sysprof.com"
+LICENSE = "GPLv3+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
+                    file://src/sp-application.c;endline=17;md5=40e55577ef122c88fe20052acda64875"
+
+GNOMEBASEBUILDCLASS = "meson"
+inherit gnomebase gettext systemd upstream-version-is-even
+
+DEPENDS = "glib-2.0 libxml2-native glib-2.0-native"
+
+SRC_URI[archive.md5sum] = "ae896a8a2364e18c07fafa9573202f59"
+SRC_URI[archive.sha256sum] = "29cd2c4be277f00698dce48259219557c4fddc2c01254b8fac95900a8c663f63"
+SRC_URI += " \
+           file://define-NT_GNU_BUILD_ID.patch \
+           file://0001-Do-not-build-anything-in-help-as-it-requires-itstool.patch \
+           file://wordsize.patch \
+           file://0001-fix-non-literal-format-string-issues.patch \
+           "
+RECIPE_NO_UPDATE_REASON = "Waiting for resolution of https://bugzilla.gnome.org/show_bug.cgi?id=794625"
+
+PACKAGECONFIG ?= "${@bb.utils.contains_any('DISTRO_FEATURES', '${GTK3DISTROFEATURES}', 'gtk', '', d)}"
+PACKAGECONFIG[gtk] = "-Denable_gtk=true,-Denable_gtk=false,gtk+3"
+PACKAGECONFIG[sysprofd] = "-Dwith_sysprofd=bundled,-Dwith_sysprofd=none,polkit"
+
+SOLIBS = ".so"
+FILES_SOLIBSDEV = ""
+
+SYSTEMD_SERVICE_${PN} = "${@bb.utils.contains('PACKAGECONFIG', 'sysprofd', 'sysprof2.service', '', d)}"
+
+FILES_${PN} += " \
+               ${datadir}/dbus-1/system-services \
+               ${datadir}/dbus-1/system.d \
+               ${datadir}/metainfo \
+               "
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Added-a-couple-of-small-sysroot-fixes.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Added-a-couple-of-small-sysroot-fixes.patch
deleted file mode 100644
index c0ceb5a..0000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Added-a-couple-of-small-sysroot-fixes.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From a714658727206d2a98a7194b7e6d29dbd3e27b8d Mon Sep 17 00:00:00 2001
-From: David Smith <dsmith@redhat.com>
-Date: Mon, 19 Mar 2018 16:50:05 -0500
-Subject: [PATCH] Added a couple of small sysroot fixes.
-
-* tapsets.cxx (dwarf_builder::build): Fix commit 4ffecddf5.
-  (path_remove_sysroot): Fix extra '/' present at start of paths.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- tapsets.cxx | 10 +++++++---
- 1 file changed, 7 insertions(+), 3 deletions(-)
-
-Index: git/tapsets.cxx
-===================================================================
---- git.orig/tapsets.cxx
-+++ git/tapsets.cxx
-@@ -1395,7 +1395,8 @@ string path_remove_sysroot(const systemt
-   string retval = path;
-   if (!sess.sysroot.empty() &&
-       (pos = retval.find(sess.sysroot)) != string::npos)
--    retval.replace(pos, sess.sysroot.length(), "/");
-+    retval.replace(pos, sess.sysroot.length(),
-+		   (sess.sysroot.back() == '/' ? "/": ""));
-   return retval;
- }
- 
-@@ -8412,8 +8413,11 @@ dwarf_builder::build(systemtap_session &
- 
-       // PR13338: unquote glob results
-       module_name = unescape_glob_chars (module_name);
--      user_path = find_executable (module_name, "", sess.sysenv); // canonicalize it
--      if (!is_fully_resolved(user_path, sess.sysroot, sess.sysenv))
-+      user_path = find_executable (module_name, sess.sysroot, sess.sysenv); // canonicalize it
-+      // Note we don't need to pass the sysroot to
-+      // is_fully_resolved(), since we just passed it to
-+      // find_executable().
-+      if (!is_fully_resolved(user_path, "", sess.sysenv))
-         throw SEMANTIC_ERROR(_F("cannot find executable '%s'",
-                                 user_path.to_string().c_str()));
- 
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Delay-adding-sysroot-path-to-module-name-in-case-of-.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Delay-adding-sysroot-path-to-module-name-in-case-of-.patch
deleted file mode 100644
index 89951a2..0000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Delay-adding-sysroot-path-to-module-name-in-case-of-.patch
+++ /dev/null
@@ -1,61 +0,0 @@
-From 4ffecddf5433d65a6f01241990c9d516586b1c79 Mon Sep 17 00:00:00 2001
-From: Victor Kamensky <kamensky@cisco.com>
-Date: Mon, 19 Mar 2018 08:53:51 -0500
-Subject: [PATCH] Delay adding sysroot path to module name in case of non
- absolute executable
-
-Current stap code adds sysroot prematurely for probes that specify non
-absolute path name, i.e like "foo", so when find_executable called it
-receives full path as <sysroot>/foo and find_executable does not search
-PATH while applying sysroot.
-
-Fix delays adding sysroot till path inside of sysroot is searched first.
-
-Also fix missing sysroot addition in glob expansion case.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- tapsets.cxx | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
-Index: git/tapsets.cxx
-===================================================================
---- git.orig/tapsets.cxx
-+++ git/tapsets.cxx
-@@ -746,7 +746,7 @@ base_query::base_query(dwflpp & dw, lite
-               pid_val = 0;
-               get_string_param(params, TOK_PROCESS, module_val);
-             }
--          module_val = find_executable (module_val, "", sess.sysenv);
-+          module_val = find_executable (module_val, sess.sysroot, sess.sysenv);
-           if (!is_fully_resolved(module_val, "", sess.sysenv))
-             throw SEMANTIC_ERROR(_F("cannot find executable '%s'",
-                                     module_val.to_string().c_str()));
-@@ -8287,7 +8287,6 @@ dwarf_builder::build(systemtap_session &
-             }
-           else
-             {
--              module_name = (string)sess.sysroot + (string)module_name;
-               filled_parameters[TOK_PROCESS] = new literal_string(module_name);
-             }
-         }
-@@ -8321,7 +8320,8 @@ dwarf_builder::build(systemtap_session &
-           assert (lit);
- 
-           // Evaluate glob here, and call derive_probes recursively with each match.
--          const auto& globs = glob_executable (module_name);
-+          const auto& globs = glob_executable (sess.sysroot
-+					       + string(module_name));
-           unsigned results_pre = finished_results.size();
-           for (auto it = globs.begin(); it != globs.end(); ++it)
-             {
-@@ -8413,7 +8413,7 @@ dwarf_builder::build(systemtap_session &
-       // PR13338: unquote glob results
-       module_name = unescape_glob_chars (module_name);
-       user_path = find_executable (module_name, "", sess.sysenv); // canonicalize it
--      if (!is_fully_resolved(user_path, "", sess.sysenv))
-+      if (!is_fully_resolved(user_path, sess.sysroot, sess.sysenv))
-         throw SEMANTIC_ERROR(_F("cannot find executable '%s'",
-                                 user_path.to_string().c_str()));
- 
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Fix-PR22551-by-updating-the-use-of-timers-for-the-4..patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Fix-PR22551-by-updating-the-use-of-timers-for-the-4..patch
deleted file mode 100644
index 460c3b7..0000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Fix-PR22551-by-updating-the-use-of-timers-for-the-4..patch
+++ /dev/null
@@ -1,277 +0,0 @@
-From fbb26e17a4c026f05a497fc5d584516bad3b6950 Mon Sep 17 00:00:00 2001
-From: David Smith <dsmith@redhat.com>
-Date: Wed, 6 Dec 2017 14:37:42 -0600
-Subject: [PATCH] Fix PR22551 by updating the use of timers for the 4.15
- kernel.
-
-* runtime/linux/timer_compatibility.h: New file.
-* runtime/time.c: Update timer callback function parameter type. Update
-  timer initialization.
-* runtime/transport/relay_v2.c: Ditto.
-* runtime/transport/transport.c: Ditto.
-* tapset-timers.cxx (timer_derived_probe_group::emit_module_decls):
-  Ditto. Handle old and new timer callback interface.
-* runtime/linux/runtime.h: Include timer_compatibility.h instead of timer.h.
-* tapset/linux/scsi.stp: Ditto.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
-
----
- runtime/linux/runtime.h             |  2 +-
- runtime/linux/timer_compatibility.h | 76 +++++++++++++++++++++++++++++++++++++
- runtime/time.c                      |  7 ++--
- runtime/transport/relay_v2.c        |  8 ++--
- runtime/transport/transport.c       | 13 +++----
- tapset-timers.cxx                   | 14 +++++--
- tapset/linux/scsi.stp               |  2 +-
- 7 files changed, 100 insertions(+), 22 deletions(-)
- create mode 100644 runtime/linux/timer_compatibility.h
-
-diff --git a/runtime/linux/runtime.h b/runtime/linux/runtime.h
-index 9c585a2..df9b74c 100644
---- a/runtime/linux/runtime.h
-+++ b/runtime/linux/runtime.h
-@@ -34,7 +34,7 @@
- #include <linux/compat.h>
- #include <linux/sched.h>
- #include <linux/mm.h>
--#include <linux/timer.h>
-+#include "timer_compatibility.h"
- #include <linux/delay.h>
- #include <linux/profile.h>
- #include <linux/rcupdate.h>
-diff --git a/runtime/linux/timer_compatibility.h b/runtime/linux/timer_compatibility.h
-new file mode 100644
-index 0000000..ac03de9
---- /dev/null
-+++ b/runtime/linux/timer_compatibility.h
-@@ -0,0 +1,76 @@
-+/*
-+ * linux/timer.h compatibility defines and inlines
-+ * Copyright (C) 2017 Red Hat Inc.
-+ *
-+ * This file is part of systemtap, and is free software.  You can
-+ * redistribute it and/or modify it under the terms of the GNU General
-+ * Public License (GPL); either version 2, or (at your option) any
-+ * later version.
-+ */
-+
-+#ifndef _TIMER_COMPATIBILITY_H_
-+#define _TIMER_COMPATIBILITY_H_
-+
-+#include <linux/timer.h>
-+
-+/*
-+ * Starting with the 4.15 kernel, the timer interface
-+ * changed. Originally, you'd do something like:
-+ *
-+ *   static void timer_func(unsigned long val);
-+ *
-+ *   init_timer(&timer);
-+ *   timer.expires = jiffies + STP_RELAY_TIMER_INTERVAL;
-+ *   timer.function = timer_func;
-+ *   timer.data = 0;
-+ *   add_timer(&timer);
-+ *
-+ * The 'data' parameter would get passed to the callback
-+ * function. Starting with 4.15, you'd do something like this:
-+ *
-+ *   static void timer_func(struct timer_list *val);
-+ *
-+ *   timer_setup(&timer, timer_func, 0);
-+ *   timer.expires = jiffies + STP_RELAY_TIMER_INTERVAL;
-+ *   add_timer(&timer);
-+ *   
-+ * With the new code, the timer that caused the callback gets passed
-+ * to the timer callback function. The 'data' field has been removed.
-+ *
-+ * So, we're going to use the new interface. To hide the differences
-+ * between the callback function parameter type, we'll define a new
-+ * type, 'stp_timer_callback_parameter_t'.
-+ *
-+ * If code needs to figure out the difference between the old and new
-+ * interface, it should test the TIMER_TRACE_FLAGMASK define (which
-+ * only exists in the new interface).
-+ */
-+
-+#if defined(TIMER_TRACE_FLAGMASK) 
-+/* This is the >= 4.15 kernel interface. */
-+
-+typedef struct timer_list * stp_timer_callback_parameter_t;
-+
-+#else
-+/* This is the < 4.15 kernel interface. */
-+
-+typedef unsigned long stp_timer_callback_parameter_t;
-+
-+/**
-+ * timer_setup - prepare a timer for first use
-+ * @timer: the timer in question
-+ * @callback: the function to call when timer expires
-+ * @flags: any TIMER_* flags (note that anything other than 0 is an
-+ * 	   error, since this compatibility function can't support any
-+ *	   of the TIMER_* flags)
-+ */
-+#define timer_setup(timer, callback, flags)			\
-+	{							\
-+		init_timer((timer));				\
-+		(timer)->function = callback;			\
-+		(timer)->data = 0;				\
-+		BUILD_BUG_ON_ZERO((flags) != 0);		\
-+	}
-+#endif
-+
-+#endif /* _TIMER_COMPATIBILITY_H_ */
-diff --git a/runtime/time.c b/runtime/time.c
-index 2e666d5..91ceafa 100644
---- a/runtime/time.c
-+++ b/runtime/time.c
-@@ -168,10 +168,10 @@ __stp_time_smp_callback(void *val)
- 
- /* The timer callback is in a softIRQ -- interrupts enabled. */
- static void
--__stp_time_timer_callback(unsigned long val)
-+__stp_time_timer_callback(stp_timer_callback_parameter_t unused)
- {
-     stp_time_t *time =__stp_time_local_update();
--    (void) val;
-+    (void) unused;
- 
-     /* PR6481: make sure IRQs are enabled before resetting the timer
-        (IRQs are disabled and then reenabled in
-@@ -200,9 +200,8 @@ __stp_init_time(void *info)
-     time->freq = __stp_get_freq();
-     __stp_time_local_update();
- 
--    init_timer(&time->timer);
-+    timer_setup(&time->timer, __stp_time_timer_callback, 0);
-     time->timer.expires = jiffies + STP_TIME_SYNC_INTERVAL;
--    time->timer.function = __stp_time_timer_callback;
- 
- #ifndef STAPCONF_ADD_TIMER_ON
-     add_timer(&time->timer);
-diff --git a/runtime/transport/relay_v2.c b/runtime/transport/relay_v2.c
-index f81d75d..135951a 100644
---- a/runtime/transport/relay_v2.c
-+++ b/runtime/transport/relay_v2.c
-@@ -30,7 +30,7 @@
- #include <linux/debugfs.h>
- #include <linux/mm.h>
- #include <linux/relay.h>
--#include <linux/timer.h>
-+#include "../linux/timer_compatibility.h"
- #include "../uidgid_compatibility.h"
- #include "relay_compat.h"
- 
-@@ -120,7 +120,7 @@ static void __stp_relay_wakeup_readers(struct rchan_buf *buf)
- 		wake_up_interruptible(&buf->read_wait);
- }
- 
--static void __stp_relay_wakeup_timer(unsigned long val)
-+static void __stp_relay_wakeup_timer(stp_timer_callback_parameter_t unused)
- {
- #ifdef STP_BULKMODE
- 	int i;
-@@ -151,10 +151,8 @@ static void __stp_relay_wakeup_timer(unsigned long val)
- static void __stp_relay_timer_init(void)
- {
- 	atomic_set(&_stp_relay_data.wakeup, 0);
--	init_timer(&_stp_relay_data.timer);
-+	timer_setup(&_stp_relay_data.timer, __stp_relay_wakeup_timer, 0);
- 	_stp_relay_data.timer.expires = jiffies + STP_RELAY_TIMER_INTERVAL;
--	_stp_relay_data.timer.function = __stp_relay_wakeup_timer;
--	_stp_relay_data.timer.data = 0;
- 	add_timer(&_stp_relay_data.timer);
- 	smp_mb();
- }
-diff --git a/runtime/transport/transport.c b/runtime/transport/transport.c
-index 3400f22..320fd18 100644
---- a/runtime/transport/transport.c
-+++ b/runtime/transport/transport.c
-@@ -311,7 +311,7 @@ static void _stp_detach(void)
- }
- 
- 
--static void _stp_ctl_work_callback(unsigned long val);
-+static void _stp_ctl_work_callback(stp_timer_callback_parameter_t unused);
- 
- /*
-  * Called when stapio opens the control channel.
-@@ -320,13 +320,12 @@ static void _stp_attach(void)
- {
- 	dbug_trans(1, "attach\n");
- 	_stp_pid = current->pid;
--  if (_stp_namespaces_pid < 1)
--    _stp_namespaces_pid = _stp_pid;
-+	if (_stp_namespaces_pid < 1)
-+		_stp_namespaces_pid = _stp_pid;
- 	_stp_transport_data_fs_overwrite(0);
--	init_timer(&_stp_ctl_work_timer);
-+
-+	timer_setup(&_stp_ctl_work_timer, _stp_ctl_work_callback, 0);
- 	_stp_ctl_work_timer.expires = jiffies + STP_CTL_TIMER_INTERVAL;
--	_stp_ctl_work_timer.function = _stp_ctl_work_callback;
--	_stp_ctl_work_timer.data= 0;
- 	add_timer(&_stp_ctl_work_timer);
- }
- 
-@@ -341,7 +340,7 @@ static void _stp_attach(void)
-  *	notified. Reschedules itself if someone is still attached
-  *	to the cmd channel.
-  */
--static void _stp_ctl_work_callback(unsigned long val)
-+static void _stp_ctl_work_callback(stp_timer_callback_parameter_t unused)
- {
- 	int do_io = 0;
- 	unsigned long flags;
-diff --git a/tapset-timers.cxx b/tapset-timers.cxx
-index 1a40bcd..0ab4d69 100644
---- a/tapset-timers.cxx
-+++ b/tapset-timers.cxx
-@@ -122,9 +122,13 @@ timer_derived_probe_group::emit_module_decls (systemtap_session& s)
-   s.op->newline(-1) << "};";
-   s.op->newline();
- 
--  s.op->newline() << "static void enter_timer_probe (unsigned long val) {";
-+  s.op->newline() << "static void enter_timer_probe (stp_timer_callback_parameter_t val) {";
-+  s.op->newline() << "#if defined(TIMER_TRACE_FLAGMASK)";
-+  s.op->newline(1) << "struct stap_timer_probe* stp = container_of(val, struct stap_timer_probe, timer_list);";
-+  s.op->newline(-1) << "#else";
-   s.op->newline(1) << "struct stap_timer_probe* stp = & stap_timer_probes [val];";
--  s.op->newline() << "if ((atomic_read (session_state()) == STAP_SESSION_STARTING) ||";
-+  s.op->newline(-1) << "#endif";
-+  s.op->newline(1) << "if ((atomic_read (session_state()) == STAP_SESSION_STARTING) ||";
-   s.op->newline() << "    (atomic_read (session_state()) == STAP_SESSION_RUNNING))";
-   s.op->newline(1) << "mod_timer (& stp->timer_list, jiffies + ";
-   emit_interval (s.op);
-@@ -148,9 +152,11 @@ timer_derived_probe_group::emit_module_init (systemtap_session& s)
-   s.op->newline() << "for (i=0; i<" << probes.size() << "; i++) {";
-   s.op->newline(1) << "struct stap_timer_probe* stp = & stap_timer_probes [i];";
-   s.op->newline() << "probe_point = stp->probe->pp;";
--  s.op->newline() << "init_timer (& stp->timer_list);";
--  s.op->newline() << "stp->timer_list.function = & enter_timer_probe;";
-+
-+  s.op->newline() << "timer_setup (& stp->timer_list, enter_timer_probe, 0);";
-+  s.op->newline() << "#if !defined(TIMER_TRACE_FLAGMASK)";
-   s.op->newline() << "stp->timer_list.data = i;"; // NB: important!
-+  s.op->newline() << "#endif";
-   // copy timer renew calculations from above :-(
-   s.op->newline() << "stp->timer_list.expires = jiffies + ";
-   emit_interval (s.op);
-diff --git a/tapset/linux/scsi.stp b/tapset/linux/scsi.stp
-index 44f686c..3577942 100644
---- a/tapset/linux/scsi.stp
-+++ b/tapset/linux/scsi.stp
-@@ -14,7 +14,7 @@
- #include <scsi/scsi_cmnd.h>
- #include <scsi/scsi_device.h>
- #include <scsi/scsi_host.h>
--#include <linux/timer.h>
-+#include "linux/timer_compatibility.h"
- #include <linux/blkdev.h>
- %}
- 
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Fixes-for-gcc-8.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Fixes-for-gcc-8.patch
deleted file mode 100644
index a1b0bff..0000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Fixes-for-gcc-8.patch
+++ /dev/null
@@ -1,215 +0,0 @@
-From 4ffe00f1d9eac332d928f7dc01fe250dc32b1bb8 Mon Sep 17 00:00:00 2001
-From: Stan Cox <scox@redhat.com>
-Date: Tue, 13 Feb 2018 22:38:03 -0500
-Subject: [PATCH] Fixes for gcc 8
-
-* includes/sys/sdt.h (__SDT_COND_SIGNED):  Add CT, cast type argument
-
-Author: Will Cohen <wcohen.redhat.com>
-
-* stap-serverd.cxx (generate_mok, handleRequest, handle_connection):
-  Catch format overflow
-
-* translate.cxx (translate_pass): Use ref in catch.
----
-Upstream-Status: Backport
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
- includes/sys/sdt.h | 20 ++++++++--------
- stap-serverd.cxx   | 67 +++++++++++++++++++++++++++++++++++++++++++++++-------
- translate.cxx      |  2 +-
- 3 files changed, 70 insertions(+), 19 deletions(-)
-
-diff --git a/includes/sys/sdt.h b/includes/sys/sdt.h
-index 940f74483..c0c5a492c 100644
---- a/includes/sys/sdt.h
-+++ b/includes/sys/sdt.h
-@@ -119,8 +119,8 @@ struct __sdt_type
-   
- #define __SDT_ALWAYS_SIGNED(T) \
- template<> struct __sdt_type<T> { static const bool __sdt_signed = true; };
--#define __SDT_COND_SIGNED(T) \
--template<> struct __sdt_type<T> { static const bool __sdt_signed = ((T)(-1) < 1); };
-+#define __SDT_COND_SIGNED(T,CT)						\
-+template<> struct __sdt_type<T> { static const bool __sdt_signed = ((CT)(-1) < 1); };
- __SDT_ALWAYS_SIGNED(signed char)
- __SDT_ALWAYS_SIGNED(short)
- __SDT_ALWAYS_SIGNED(int)
-@@ -141,14 +141,14 @@ __SDT_ALWAYS_SIGNED(const volatile short)
- __SDT_ALWAYS_SIGNED(const volatile int)
- __SDT_ALWAYS_SIGNED(const volatile long)
- __SDT_ALWAYS_SIGNED(const volatile long long)
--__SDT_COND_SIGNED(char)
--__SDT_COND_SIGNED(wchar_t)
--__SDT_COND_SIGNED(volatile char)
--__SDT_COND_SIGNED(volatile wchar_t)
--__SDT_COND_SIGNED(const char)
--__SDT_COND_SIGNED(const wchar_t)
--__SDT_COND_SIGNED(const volatile char)
--__SDT_COND_SIGNED(const volatile wchar_t)
-+__SDT_COND_SIGNED(char, char)
-+__SDT_COND_SIGNED(wchar_t, wchar_t)
-+__SDT_COND_SIGNED(volatile char, char)
-+__SDT_COND_SIGNED(volatile wchar_t, wchar_t)
-+__SDT_COND_SIGNED(const char, char)
-+__SDT_COND_SIGNED(const wchar_t, wchar_t)
-+__SDT_COND_SIGNED(const volatile char, char)
-+__SDT_COND_SIGNED(const volatile wchar_t, wchar_t)
- #if defined (__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
- /* __SDT_COND_SIGNED(char16_t) */
- /* __SDT_COND_SIGNED(char32_t) */
-diff --git a/stap-serverd.cxx b/stap-serverd.cxx
-index 7cf76c617..41f77ee9e 100644
---- a/stap-serverd.cxx
-+++ b/stap-serverd.cxx
-@@ -1607,6 +1607,7 @@ generate_mok(string &mok_fingerprint)
-   char tmpdir[PATH_MAX] = { '\0' };
-   string public_cert_path, private_cert_path, destdir;
-   mode_t old_umask;
-+  int retlen;
- 
-   mok_fingerprint.clear ();
- 
-@@ -1631,7 +1632,14 @@ generate_mok(string &mok_fingerprint)
-     }
- 
-   // Make a temporary directory to store results in.
--  snprintf (tmpdir, PATH_MAX, "%s/stap-server.XXXXXX", mok_path.c_str ());
-+  retlen = snprintf (tmpdir, PATH_MAX, "%s/stap-server.XXXXXX", mok_path.c_str ());
-+  if (retlen < 0 || retlen >= PATH_MAX)
-+    {
-+      server_error (_F("Could not create %s name", "temporary directory"));
-+      tmpdir[0] = '\0';
-+      goto cleanup;
-+    }
-+
-   if (mkdtemp (tmpdir) == NULL)
-     {
-       server_error (_F("Could not create temporary directory %s: %s", tmpdir, 
-@@ -1704,6 +1712,7 @@ handleRequest (const string &requestDirName, const string &responseDirName, stri
-   unsigned u;
-   unsigned i;
-   FILE* f;
-+  int retlen;
- 
-   // Save the server version. Do this early, so the client knows what version of the server
-   // it is dealing with, even if the request is not fully completed.
-@@ -1782,7 +1791,12 @@ handleRequest (const string &requestDirName, const string &responseDirName, stri
-       struct stat st;
-       char *arg;
- 
--      snprintf (stapargfile, PATH_MAX, "%s/argv%d", requestDirName.c_str (), i);
-+      retlen = snprintf (stapargfile, PATH_MAX, "%s/argv%d", requestDirName.c_str (), i);
-+      if (retlen < 0 || retlen >= PATH_MAX)
-+        {
-+          server_error (_F("Error creating %s name", "path"));
-+          return;
-+        }
- 
-       rc = stat(stapargfile, & st);
-       if (rc) break;
-@@ -1888,7 +1902,15 @@ handleRequest (const string &requestDirName, const string &responseDirName, stri
-     {
-       glob_t globber;
-       char pattern[PATH_MAX];
--      snprintf (pattern, PATH_MAX, "%s/*.ko", new_staptmpdir.c_str());
-+      int retlen;
-+
-+      retlen = snprintf (pattern, PATH_MAX, "%s/*.ko", new_staptmpdir.c_str());
-+      if (retlen < 0 || retlen >= PATH_MAX)
-+        {
-+          server_error (_F("Error creating %s name", "pattern"));
-+          return;
-+        }
-+
-       rc = glob (pattern, GLOB_ERR, NULL, &globber);
-       if (rc)
-         server_error (_F("Unable to find a module in %s", new_staptmpdir.c_str()));
-@@ -2164,6 +2186,7 @@ handle_connection (void *arg)
-                         copy for each connection.*/
-   vector<string>     argv;
-   PRInt32            bytesRead;
-+  int		     retlen;
- 
-   /* Detatch to avoid a memory leak */
-   if(max_threads > 0)
-@@ -2213,7 +2236,13 @@ handle_connection (void *arg)
- #endif
- 
-   secStatus = SECFailure;
--  snprintf(tmpdir, PATH_MAX, "%s/stap-server.XXXXXX", getenv("TMPDIR") ?: "/tmp");
-+  retlen = snprintf(tmpdir, PATH_MAX, "%s/stap-server.XXXXXX", getenv("TMPDIR") ?: "/tmp");
-+  if (retlen < 0 || retlen >= PATH_MAX)
-+    {
-+      server_error (_F("Error creating %s name", "temporary directory"));
-+      tmpdir[0]=0; /* prevent /bin/rm */
-+      goto cleanup;
-+    }
-   rc1 = mkdtemp(tmpdir);
-   if (! rc1)
-     {
-@@ -2223,9 +2252,20 @@ handle_connection (void *arg)
-     }
- 
-   /* Create a temporary files names and directories.  */
--  snprintf (requestFileName, PATH_MAX, "%s/request.zip", tmpdir);
-+  retlen = snprintf (requestFileName, PATH_MAX, "%s/request.zip", tmpdir);
-+  if (retlen < 0 || retlen >= PATH_MAX)
-+    {
-+      server_error (_F("Error creating %s name", "request.zip path"));
-+      goto cleanup;
-+    }
-+
-+  retlen = snprintf (requestDirName, PATH_MAX, "%s/request", tmpdir);
-+  if (retlen < 0 || retlen >= PATH_MAX)
-+    {
-+      server_error (_F("Error creating %s name", "request directory path"));
-+      goto cleanup;
-+    }
- 
--  snprintf (requestDirName, PATH_MAX, "%s/request", tmpdir);
-   rc = mkdir(requestDirName, 0700);
-   if (rc)
-     {
-@@ -2233,7 +2273,13 @@ handle_connection (void *arg)
-       goto cleanup;
-     }
- 
--  snprintf (responseDirName, PATH_MAX, "%s/response", tmpdir);
-+  retlen = snprintf (responseDirName, PATH_MAX, "%s/response", tmpdir);
-+  if (retlen < 0 || retlen >= PATH_MAX)
-+    {
-+      server_error (_F("Error creating %s name", "response directory path"));
-+      goto cleanup;
-+    }
-+
-   rc = mkdir(responseDirName, 0700);
-   if (rc)
-     {
-@@ -2243,7 +2289,12 @@ handle_connection (void *arg)
-   // Set this early, since it gets used for errors to be returned to the client.
-   stapstderr = string(responseDirName) + "/stderr";
- 
--  snprintf (responseFileName, PATH_MAX, "%s/response.zip", tmpdir);
-+  retlen = snprintf (responseFileName, PATH_MAX, "%s/response.zip", tmpdir);
-+  if (retlen < 0 || retlen >= PATH_MAX)
-+    {
-+      server_error (_F("Error creating %s name", "response.zip path"));
-+      goto cleanup;
-+    }
- 
-   /* Read data from the socket.
-    * If the user is requesting/requiring authentication, authenticate
-diff --git a/translate.cxx b/translate.cxx
-index 1240a80ec..4ade06fdd 100644
---- a/translate.cxx
-+++ b/translate.cxx
-@@ -7860,7 +7860,7 @@ translate_pass (systemtap_session& s)
- 	  if (versions.size() >= 3 && s.verbose > 1)
- 	    clog << _F("ignoring extra parts of compat version: %s", s.compatible.c_str()) << endl;
- 	}
--      catch (const runtime_error)
-+      catch (const runtime_error&)
- 	{
- 	  throw SEMANTIC_ERROR(_F("parse error in compatibility version: %s", s.compatible.c_str()));
- 	}
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Install-python-modules-to-correct-library-dir.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Install-python-modules-to-correct-library-dir.patch
index 528864c..48cf4ae 100644
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Install-python-modules-to-correct-library-dir.patch
+++ b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Install-python-modules-to-correct-library-dir.patch
@@ -5,32 +5,52 @@
 
 Upstream-Status: Inappropriate [oe-core specific]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+Add OE's CFLAGS which contains `-fdebug-prefix-map' options to
+setup.py
+
+Supply "--root" directory to the "install" command, and use
+it as a prefix to strip off the purported filename encoded
+in bytecode files. (It strips build path prefix from .pyc files)
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
- python/Makefile.am | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
+ python/Makefile.am | 8 ++++++--
+ 1 file changed, 6 insertions(+), 2 deletions(-)
 
 diff --git a/python/Makefile.am b/python/Makefile.am
-index a254480f9..efe9f3c01 100644
+index a254480..578602f 100644
 --- a/python/Makefile.am
 +++ b/python/Makefile.am
-@@ -47,7 +47,7 @@ install-exec-local:
+@@ -8,6 +8,10 @@ AUTOMAKE_OPTIONS = subdir-objects
+ AM_CPPFLAGS = -I$(srcdir)/../includes
+ AM_CPPFLAGS += -I$(abs_builddir)/../includes/sys
+ 
++# Add OE's CFLAGS which contains `-fdebug-prefix-map' options to
++# fix build path issue
++AM_CPPFLAGS += $(CFLAGS)
++
+ # Any script in the following variable will get byte-compiled at
+ # install time.
+ pkglibexecpython_PYTHON =
+@@ -47,7 +51,7 @@ install-exec-local:
  if HAVE_PYTHON2_PROBES
  	(cd $(srcdir); CFLAGS="$(AM_CPPFLAGS)" $(PYTHON) setup.py build \
           --build-base $(shell readlink -f $(builddir))/py2build \
 -	 install --prefix $(DESTDIR)$(prefix) \
-+	 install --prefix $(DESTDIR)$(prefix) --install-lib=$(DESTDIR)${pythondir} \
++	 install --root $(DESTDIR) --prefix $(prefix) --prefix $(prefix) --install-lib=${pythondir} \
  	 --single-version-externally-managed \
  	 --record $(shell readlink -f $(builddir))/py2build/install_files.txt \
           --verbose)
-@@ -55,7 +55,7 @@ endif
+@@ -55,7 +59,7 @@ endif
  if HAVE_PYTHON3_PROBES
  	(cd $(srcdir); CFLAGS="$(AM_CPPFLAGS)" $(PYTHON3) setup.py build \
           --build-base $(shell readlink -f $(builddir))/py3build \
 -	 install --prefix $(DESTDIR)$(prefix) \
-+	 install --prefix $(DESTDIR)$(prefix) --install-lib=$(DESTDIR)${python3dir} \
++	 install --root $(DESTDIR) --prefix $(prefix) --install-lib=${python3dir} \
  	 --single-version-externally-managed \
  	 --record $(shell readlink -f $(builddir))/py3build/install_files.txt \
           --verbose)
 -- 
-2.11.0
+2.7.4
 
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Make-sure-sysroot-paths-don-t-end-with-a-slash.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Make-sure-sysroot-paths-don-t-end-with-a-slash.patch
deleted file mode 100644
index 7cd9030..0000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Make-sure-sysroot-paths-don-t-end-with-a-slash.patch
+++ /dev/null
@@ -1,128 +0,0 @@
-From 41efad04730be89889d1483719f9a6c9396dc250 Mon Sep 17 00:00:00 2001
-From: David Smith <dsmith@redhat.com>
-Date: Wed, 14 Mar 2018 17:05:25 -0500
-Subject: [PATCH] Make sure sysroot paths don't end with a slash.
-
-* session.cxx (parse_cmdline): Make sure a sysroot path does not end with
-  a '/', since we build paths like: sysroot + "/lib/modules". If the
-  sysroot path ends with a '/', we end up with paths like
-  '/SYSROOT//lib/modules'.
-  (setup_kernel_release): Take a string parameter, not a character pointer.
-* session.h: Update setup_kernel_release() prototype.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- session.cxx | 34 ++++++++++++++++++++++++++--------
- session.h   |  2 +-
- 2 files changed, 27 insertions(+), 9 deletions(-)
-
-Index: git/session.cxx
-===================================================================
---- git.orig/session.cxx
-+++ git/session.cxx
-@@ -722,6 +722,9 @@ systemtap_session::parse_cmdline (int ar
-   client_options_disallowed_for_unprivileged = "";
-   std::set<std::string> additional_unwindsym_modules;
-   struct rlimit our_rlimit;
-+  bool sysroot_option_seen = false;
-+  string kernel_release_value;
-+
-   while (true)
-     {
-       char * num_endptr;
-@@ -887,7 +890,7 @@ systemtap_session::parse_cmdline (int ar
- 	    // Note that '-' must come last in a regex bracket expression.
-             assert_regexp_match("-r parameter from client", optarg, "^[a-z0-9_.+-]+$");
- 	  server_args.push_back (string ("-") + (char)grc + optarg);
--          setup_kernel_release(optarg);
-+	  kernel_release_value = optarg;
-           break;
- 
-         case 'a':
-@@ -1473,7 +1476,7 @@ systemtap_session::parse_cmdline (int ar
- 	  if (client_options) {
- 	      cerr << _F("ERROR: %s invalid with %s", "--sysroot", "--client-options") << endl;
- 	      return 1;
--	  } else if (!sysroot.empty()) {
-+	  } else if (sysroot_option_seen) {
- 	      cerr << "ERROR: multiple --sysroot options not supported" << endl;
- 	      return 1;
- 	  } else {
-@@ -1487,11 +1490,17 @@ systemtap_session::parse_cmdline (int ar
- 
- 	      sysroot = string(spath);
- 	      free (spath);
--	      if (sysroot[sysroot.size() - 1] != '/')
--		  sysroot.append("/");
- 
--	      break;
-+	      // We do path creation like this:
-+	      //   sysroot + "/lib/modules"
-+	      // So, we don't want the sysroot path to end with a '/',
-+	      // otherwise we'll end up with '/foo//lib/modules'.
-+	      if (sysroot.back() == '/') {
-+		  sysroot.pop_back();
-+	      }
- 	  }
-+	  sysroot_option_seen = true;
-+	  break;
- 
- 	case LONG_OPT_SYSENV:
- 	  if (client_options) {
-@@ -1501,7 +1510,7 @@ systemtap_session::parse_cmdline (int ar
- 	      string sysenv_str = optarg;
- 	      string value;
- 	      size_t pos;
--	      if (sysroot.empty()) {
-+	      if (! sysroot_option_seen) {
- 		  cerr << "ERROR: --sysenv must follow --sysroot" << endl;
- 		  return 1;
- 	      }
-@@ -1646,6 +1655,15 @@ systemtap_session::parse_cmdline (int ar
- 	}
-     }
- 
-+  if (! kernel_release_value.empty())
-+  {
-+      setup_kernel_release(kernel_release_value);
-+  }
-+  else if (! sysroot.empty())
-+  {
-+      kernel_build_tree = sysroot + "/lib/modules/" + kernel_release  + "/build";
-+  }
-+
-   return 0;
- }
- 
-@@ -2152,7 +2170,7 @@ void systemtap_session::insert_loaded_mo
- }
- 
- void
--systemtap_session::setup_kernel_release (const char* kstr) 
-+systemtap_session::setup_kernel_release (const string& kstr) 
- {
-   // Sometimes we may get dupes here... e.g. a server may have a full
-   // -r /path/to/kernel followed by a client's -r kernel.
-@@ -2183,7 +2201,7 @@ systemtap_session::setup_kernel_release
-   else
-     {
-       update_release_sysroot = true;
--      kernel_release = string (kstr);
-+      kernel_release = kstr;
-       if (!kernel_release.empty())
-         kernel_build_tree = "/lib/modules/" + kernel_release + "/build";
- 
-Index: git/session.h
-===================================================================
---- git.orig/session.h
-+++ git/session.h
-@@ -144,7 +144,7 @@ public:
- 
-   // NB: It is very important for all of the above (and below) fields
-   // to be cleared in the systemtap_session ctor (session.cxx).
--  void setup_kernel_release (const char* kstr);
-+  void setup_kernel_release (const std::string& kstr);
-   void insert_loaded_modules ();
- 
-   // command line parsing
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Use-sysroot-when-looking-for-the-System.map-file.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Use-sysroot-when-looking-for-the-System.map-file.patch
deleted file mode 100644
index b2820b3..0000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Use-sysroot-when-looking-for-the-System.map-file.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From 436063d5e4738a9b03535d330a2242be5118e745 Mon Sep 17 00:00:00 2001
-From: David Smith <dsmith@redhat.com>
-Date: Thu, 8 Mar 2018 16:01:58 -0600
-Subject: [PATCH] Use sysroot when looking for the System.map file.
-
-Add sysroot to system_map_path + "/boot/System.map" case. Otherwise
-stap tries to look symbols on host system and it produce error like this:
-
-> Kernel symbol table /boot/System.map-4.9.78-yocto-standard unavailable, (No such file or directory)
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- session.cxx | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-Index: git/session.cxx
-===================================================================
---- git.orig/session.cxx
-+++ git/session.cxx
-@@ -2013,7 +2013,7 @@ systemtap_session::parse_kernel_function
- 	clog << _F("Kernel symbol table %s unavailable, (%s)",
- 		   system_map_path.c_str(), strerror(errno)) << endl;
- 
--      system_map_path = "/boot/System.map-" + kernel_release;
-+      system_map_path = sysroot + "/boot/System.map-" + kernel_release;
-       system_map.clear();
-       system_map.open(system_map_path.c_str(), ifstream::in);
-       if (! system_map.is_open())
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-_stp_umodule_relocate-needs-target-file-path-not-hos.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-_stp_umodule_relocate-needs-target-file-path-not-hos.patch
deleted file mode 100644
index 98181a1..0000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-_stp_umodule_relocate-needs-target-file-path-not-hos.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From 183c7a7a8167333c873525f7908913837b8dc3cb Mon Sep 17 00:00:00 2001
-From: Victor Kamensky <kamensky@cisco.com>
-Date: Tue, 20 Mar 2018 12:41:05 -0500
-Subject: [PATCH] _stp_umodule_relocate needs target file path, not host file
- path
-
-Strip of sysroot from module name is required when _stp_umodule_relocate
-call is generated. Otherwise path won't match path on target and could
-will fail to calculated address within the file.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- loc2stap.cxx | 5 ++++-
- 1 file changed, 4 insertions(+), 1 deletion(-)
-
-diff --git a/loc2stap.cxx b/loc2stap.cxx
-index 4818ee0..e09954f 100644
---- a/loc2stap.cxx
-+++ b/loc2stap.cxx
-@@ -17,6 +17,7 @@
- 
- #include "loc2stap.h"
- #include "dwflpp.h"
-+#include "tapsets.h"
- 
- #if ! _ELFUTILS_PREREQ(0, 153)
- #define DW_OP_GNU_entry_value 0xf3
-@@ -106,7 +107,9 @@ location_context::translate_address(Dwarf_Addr addr)
-           c = "/* pragma:vma */ "
-               "({ unsigned long addr = 0; "
-               "addr = _stp_umodule_relocate (\""
--              + resolve_path(dw->module_name.c_str()) + "\", "
-+              + path_remove_sysroot(dw->sess,
-+				    resolve_path(dw->module_name.c_str()))
-+	      + "\", "
-               + lex_cast_hex (addr)
- 	      + ", current); addr; })";
- 	}
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-buildrun-remove-quotes-around-I-include-line.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-buildrun-remove-quotes-around-I-include-line.patch
deleted file mode 100644
index 7996fdd..0000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-buildrun-remove-quotes-around-I-include-line.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-From 75c4aec6de3a615909f3283eac585760de101b8c Mon Sep 17 00:00:00 2001
-From: Saul Wold <sgw@linux.intel.com>
-Date: Tue, 7 Mar 2017 10:46:12 -0800
-Subject: [PATCH] buildrun: remove quotes around -I include line
-
-By having the quotes, the kernel Makefile addtree macro adds the
-kernel $srctree directory as a prefix and causes compilation failures.
-Removing the quotes resolves the issue.
-
-This is trimmed from the verbose output of the GCC command line
-Before:
- -I/srv/sdb/builds/4.9/tmp/work-shared/qemux86-64/kernel-source/"/srv/sdb/releases/jethro/builds/4.1/tmp/sysroots/x86_64-linux/usr/share/systemtap/runtime"
-
-After:
- -I/srv/sdb/builds/4.9/tmp/sysroots/x86_64-linux/usr/share/systemtap/runtime
-
-Upstream-Status: Pending
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
----
- buildrun.cxx | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/buildrun.cxx b/buildrun.cxx
-index aaea64c..8a8ee9f 100644
---- a/buildrun.cxx
-+++ b/buildrun.cxx
-@@ -495,7 +495,7 @@ compile_pass (systemtap_session& s)
-   #if CHECK_POINTER_ARITH_PR5947
-   o << "EXTRA_CFLAGS += -Wpointer-arith" << endl;
-   #endif
--  o << "EXTRA_CFLAGS += -I\"" << s.runtime_path << "\"" << endl;
-+  o << "EXTRA_CFLAGS += -I" << s.runtime_path << endl;
-   // XXX: this may help ppc toc overflow
-   // o << "CFLAGS := $(subst -Os,-O2,$(CFLAGS)) -fminimal-toc" << endl;
-   o << "obj-m := " << s.module_name << ".o" << endl;
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-debuginfo-lookup-with-sysroot-case-do-not-remove-sys.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-debuginfo-lookup-with-sysroot-case-do-not-remove-sys.patch
deleted file mode 100644
index 160642d..0000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-debuginfo-lookup-with-sysroot-case-do-not-remove-sys.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From b29e448e12040ed8f4d83743a14db0f138a7cc67 Mon Sep 17 00:00:00 2001
-From: Victor Kamensky <kamensky@cisco.com>
-Date: Wed, 14 Mar 2018 16:54:08 -0500
-Subject: [PATCH] debuginfo lookup with sysroot case do not remove sysroot from
- file_name
-
-If sysroot option is passed, and debug symbols reside in sysroot along
-with executable <foo> in <foo_dir>/.debug/<foo_file> directory,
-stap fails to find debuginfo because it strips out sysroot path
-from file_name so dwfl_standard_find_debuginfo ends up looking at
-host <foo_dir>/.debug/<foo_file> rather then checking
-<sysroot>/<foo_dir>/.debug/<foo_file>.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- setupdwfl.cxx | 12 ------------
- 1 file changed, 12 deletions(-)
-
-diff --git a/setupdwfl.cxx b/setupdwfl.cxx
-index 11e0bb2..2a87982 100644
---- a/setupdwfl.cxx
-+++ b/setupdwfl.cxx
-@@ -627,18 +627,6 @@ internal_find_debuginfo (Dwfl_Module *mod,
- 
-   call_dwfl_standard_find_debuginfo:
- 
--  if (current_session_for_find_debuginfo)
--    {
--      string sysroot = current_session_for_find_debuginfo->sysroot + "/*";
--      int    found   = fnmatch(sysroot.c_str(), file_name, 0);
--
--      if (found)
--	{
--	  file_name = file_name
--	    + current_session_for_find_debuginfo->sysroot.length() - 1;
--	}
--    }
--
-   /* Call the original dwfl_standard_find_debuginfo */
-   return dwfl_standard_find_debuginfo(mod, userdata, modname, base,
-               file_name, debuglink_file,
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-improve-reproducibility-for-c-compiling.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-improve-reproducibility-for-c-compiling.patch
new file mode 100644
index 0000000..15a6f2a
--- /dev/null
+++ b/poky/meta/recipes-kernel/systemtap/systemtap/0001-improve-reproducibility-for-c-compiling.patch
@@ -0,0 +1,31 @@
+From 6288ba5df0a8c73ef842b609081449ac4de86123 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Wed, 18 Jul 2018 16:58:33 +0800
+Subject: [PATCH] improve reproducibility for c++ compiling
+
+Use relative dir to include header string_ref to
+strip build path prefix in c++ object file
+
+Upstream-Status: Inappropriate [oe specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ stringtable.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/stringtable.h b/stringtable.h
+index 5fc42e7..6fd8a1e 100644
+--- a/stringtable.h
++++ b/stringtable.h
+@@ -19,7 +19,7 @@
+ 
+ #if defined(HAVE_BOOST_UTILITY_STRING_REF_HPP)
+ #include <boost/version.hpp>
+-#include <boost/utility/string_ref.hpp> //header with string_ref
++#include "@RELATIVE_STAGING_INCDIR@/boost/utility/string_ref.hpp" //header with string_ref
+ 
+ // XXX: experimental tunables
+ #define INTERNED_STRING_FIND_MEMMEM 1 /* perf stat indicates a very slight benefit */
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-fix-short-release-r-option-handling-follow-u.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-fix-short-release-r-option-handling-follow-u.patch
deleted file mode 100644
index 6fe7d4d..0000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-fix-short-release-r-option-handling-follow-u.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From 7e11f129ff370ce5f39812ce2ae6ce40818a347f Mon Sep 17 00:00:00 2001
-From: Victor Kamensky <kamensky@cisco.com>
-Date: Thu, 22 Mar 2018 16:02:02 -0500
-Subject: [PATCH] sysroot: fix short release -r option handling follow up
-
-In case of sysroot set and short release -r option it does not make sense
-to pass short release name into dwfl_linux_kernel_report_offline
-function. This function is not aware about sysroot and it won't look for
-kernel modules under sysroot directory.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- setupdwfl.cxx | 10 +++++++++-
- 1 file changed, 9 insertions(+), 1 deletion(-)
-
-diff --git a/setupdwfl.cxx b/setupdwfl.cxx
-index c419afa..0cf5810 100644
---- a/setupdwfl.cxx
-+++ b/setupdwfl.cxx
-@@ -367,7 +367,15 @@ setup_dwfl_kernel (unsigned *modules_found, systemtap_session &s)
-   // hard-code this magic here.
-   string lib_path = s.sysroot + "/lib/modules/" + s.kernel_release + "/build";
-   if (s.kernel_build_tree == lib_path)
--    elfutils_kernel_path = s.kernel_release;
-+    {
-+      if (s.sysroot != "")
-+        // If we have sysroot set does not make sense to pass
-+        // short release to dwfl, it won't take a sysroot into
-+        // account. Let's construct full path in such case.
-+	elfutils_kernel_path = string(s.sysroot + "/lib/modules/" + s.kernel_release);
-+      else
-+	elfutils_kernel_path = s.kernel_release;
-+    }
-   else
-     elfutils_kernel_path = s.kernel_build_tree;
-   offline_modules_found = 0;
--- 
-2.7.4
-
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-fix-short-release-r-option-handling.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-fix-short-release-r-option-handling.patch
deleted file mode 100644
index b31d627..0000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-fix-short-release-r-option-handling.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-From a9ce89bcd2d78728faef59bda60e75510972cd56 Mon Sep 17 00:00:00 2001
-From: Victor Kamensky <kamensky@cisco.com>
-Date: Wed, 14 Mar 2018 17:09:44 -0500
-Subject: [PATCH] sysroot: fix short release -r option handling
-
-* setupdwfl.cxx (debuginfo_path_insert_sysroot): Add a '/' to the end of
-  the sysroot for path_insert_sysroot().
-  (setup_dwfl_kernel): Simplify logic when finding the kernel path to send
-  to elfutils.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- setupdwfl.cxx | 19 ++++++++++++-------
- 1 file changed, 12 insertions(+), 7 deletions(-)
-
-diff --git a/setupdwfl.cxx b/setupdwfl.cxx
-index 2a87982..f6c3157 100644
---- a/setupdwfl.cxx
-+++ b/setupdwfl.cxx
-@@ -339,6 +339,13 @@ static char * path_insert_sysroot(string sysroot, string path)
- 
- void debuginfo_path_insert_sysroot(string sysroot)
- {
-+  // FIXME: This is a short-term fix, until we expect sysroot paths to
-+  // always end with a '/' (and never be empty).
-+  //
-+  // The path_insert_sysroot() function assumes that sysroot has a '/'
-+  // on the end. Make sure that is true.
-+  if (sysroot.back() != '/')
-+    sysroot.push_back('/');
-   debuginfo_path = path_insert_sysroot(sysroot, debuginfo_path);
-   debuginfo_usr_path = path_insert_sysroot(sysroot, debuginfo_usr_path);
- }
-@@ -358,13 +365,11 @@ setup_dwfl_kernel (unsigned *modules_found, systemtap_session &s)
-   // no way to set the dwfl_callback.debuginfo_path and always
-   // passs the plain kernel_release here.  So instead we have to
-   // hard-code this magic here.
--   string lib_path = "/lib/modules/" + s.kernel_release + "/build";
--   if (s.kernel_build_tree == string(s.sysroot + lib_path) ||
--       (s.kernel_build_tree == lib_path
--	&& s.sysroot == "/"))
--      elfutils_kernel_path = s.kernel_release;
--   else
--      elfutils_kernel_path = s.kernel_build_tree;
-+  string lib_path = s.sysroot + "/lib/modules/" + s.kernel_release + "/build";
-+  if (s.kernel_build_tree == lib_path)
-+    elfutils_kernel_path = s.kernel_release;
-+  else
-+    elfutils_kernel_path = s.kernel_build_tree;
-   offline_modules_found = 0;
- 
-   // First try to report full path modules.
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-handle-symbolic-links-with-absolute-name-rel.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-handle-symbolic-links-with-absolute-name-rel.patch
deleted file mode 100644
index 8a3d39a..0000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-handle-symbolic-links-with-absolute-name-rel.patch
+++ /dev/null
@@ -1,117 +0,0 @@
-From 2041085d1a700201dc088991ca8136e7935bf42f Mon Sep 17 00:00:00 2001
-From: Victor Kamensky <kamensky@cisco.com>
-Date: Wed, 21 Mar 2018 11:35:26 -0500
-Subject: [PATCH] sysroot: handle symbolic links with absolute name relative to
- sysroot
-
-In case of symbolic link found under sysroot point to absolute path,
-instead of trying to look for such absolute path in host system,
-apply sysroot prefix first.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- util.cxx | 76 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- 1 file changed, 76 insertions(+)
-
-Index: git/util.cxx
-===================================================================
---- git.orig/util.cxx
-+++ git/util.cxx
-@@ -441,6 +441,64 @@ split_lines(const char *buf, size_t n)
-   return lines;
- }
- 
-+static string
-+follow_link(const string& name, const string& sysroot)
-+{
-+  char *linkname;
-+  ssize_t r;
-+  string retpath;
-+  struct stat st;
-+
-+  const char *f = name.c_str();
-+
-+  lstat(f, &st);
-+
-+  linkname = (char *) malloc(st.st_size + 1);
-+
-+  if (linkname)
-+    {
-+      r = readlink(f, linkname, st.st_size + 1);
-+      linkname[st.st_size] = '\0';
-+      /*
-+       * If we have non-empty sysroot and we got link that
-+       * points to absolute path name, we need to look at
-+       * this path relative to sysroot itself. access and
-+       * stat will follow symbolic links correctly only in
-+       * case with empty sysroot.
-+       */
-+      while (r != -1 && linkname && linkname[0] == '/')
-+	{
-+	  string fname1 = sysroot + linkname;
-+	  const char *f1 = fname1.c_str();
-+	  if (access(f1, X_OK) == 0
-+	      && stat(f1, &st) == 0
-+	      && S_ISREG(st.st_mode))
-+	    {
-+	      retpath = fname1;
-+	      break;
-+	    }
-+	  else if (lstat(f1, &st) == 0
-+		   && S_ISLNK(st.st_mode))
-+	    {
-+	      free(linkname);
-+	      linkname = (char *) malloc(st.st_size + 1);
-+	      if (linkname)
-+		{
-+		  r = readlink(f1, linkname, st.st_size + 1);
-+		  linkname[st.st_size] = '\0';
-+		}
-+	    }
-+	  else
-+	    {
-+	      break;
-+	    }
-+	}
-+    }
-+  free(linkname);
-+
-+  return retpath;
-+}
-+
- // Resolve an executable name to a canonical full path name, with the
- // same policy as execvp().  A program name not containing a slash
- // will be searched along the $PATH.
-@@ -465,6 +523,14 @@ string find_executable(const string& nam
-   if (name.find('/') != string::npos) // slash in the path already?
-     {
-       retpath = sysroot + name;
-+
-+      const char *f = retpath.c_str();
-+      if (sysroot != ""
-+	  && lstat(f, &st) == 0
-+	  && S_ISLNK(st.st_mode))
-+	{
-+	  retpath = follow_link(f, sysroot);
-+	}
-     }
-   else // Nope, search $PATH.
-     {
-@@ -493,6 +559,16 @@ string find_executable(const string& nam
-                   retpath = fname;
-                   break;
-                 }
-+              else if (sysroot != ""
-+                       && lstat(f, &st) == 0
-+                       && S_ISLNK(st.st_mode))
-+		{
-+		  retpath = follow_link(f, sysroot);
-+		  if (retpath != "")
-+		    {
-+		      break;
-+		    }
-+		}
-             }
-         }
-     }
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/monitor-option.patch b/poky/meta/recipes-kernel/systemtap/systemtap/monitor-option.patch
index b7ee070..9313a5a 100644
--- a/poky/meta/recipes-kernel/systemtap/systemtap/monitor-option.patch
+++ b/poky/meta/recipes-kernel/systemtap/systemtap/monitor-option.patch
@@ -13,18 +13,18 @@
  configure.ac | 5 ++++-
  1 file changed, 4 insertions(+), 1 deletion(-)
 
-diff --git a/configure.ac b/configure.ac
-index 6bd0c5fc4..2ea9b3cbf 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -752,13 +752,16 @@ dnl We want either (or both) python probe support.
+Index: git/configure.ac
+===================================================================
+--- git.orig/configure.ac
++++ git/configure.ac
+@@ -766,13 +766,16 @@ dnl We want either (or both) python prob
  AM_CONDITIONAL([HAVE_PYTHON_PROBES],
    [test "x$have_python2_support" = "xyes" -o "x$have_python3_support" = "xyes"])
  
 +AC_ARG_ENABLE([monitor], AS_HELP_STRING([--disable-monitor],[Disable monitor]))
 +if test "$enable_monitor" != "no"; then
  dnl Check for presence of json-c and ncurses for use in monitor mode
- PKG_CHECK_MODULES([jsonc], [json-c >= 0.12], [have_jsonc=yes], [have_jsonc=no])
+ PKG_CHECK_MODULES([jsonc], [json-c >= 0.11], [have_jsonc=yes], [have_jsonc=no])
  PKG_CHECK_MODULES([ncurses], [ncurses], [have_ncurses=yes], [have_ncurses=no])
 -AM_CONDITIONAL([HAVE_MONITOR_LIBS], [test "${have_jsonc}" == "yes" -a "${have_ncurses}" == "yes"])
  if test "${have_jsonc}" == "yes" -a "${have_ncurses}" == yes; then
@@ -35,6 +35,3 @@
  
  AC_CACHE_CHECK([for assembler .section "?" flags support], stap_cv_sectionq, [
  old_CFLAGS="$CFLAGS"
--- 
-2.11.0
-
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap_git.bb b/poky/meta/recipes-kernel/systemtap/systemtap_git.bb
index b280f58..6ee3e1c 100644
--- a/poky/meta/recipes-kernel/systemtap/systemtap_git.bb
+++ b/poky/meta/recipes-kernel/systemtap/systemtap_git.bb
@@ -3,6 +3,8 @@
 
 require systemtap_git.inc
 
+SRC_URI += "file://0001-improve-reproducibility-for-c-compiling.patch"
+
 DEPENDS = "elfutils"
 
 EXTRA_OECONF += "--with-libelf=${STAGING_DIR_TARGET} --without-rpm \
@@ -23,7 +25,24 @@
 PACKAGECONFIG[monitor] = "--enable-monitor,--disable-monitor,ncurses json-c"
 PACKAGECONFIG[python3-probes] = "--with-python3-probes,--without-python3-probes,python3-setuptools-native"
 
-inherit autotools gettext pkgconfig distutils3-base
+inherit autotools gettext pkgconfig distutils3-base systemd
+
+PACKAGES =+ "${PN}-exporter"
+
+FILES_${PN}-exporter = "${sysconfdir}/stap-exporter/* \
+                        ${sysconfdir}/sysconfig/stap-exporter \
+                        ${systemd_unitdir}/system/stap-exporter.service \
+                        ${sbindir}/stap-exporter"
+
+RDEPENDS_${PN}-exporter = "${PN} python3-core python3-netclient"
+
+SYSTEMD_SERVICE_${PN}-exporter = "stap-exporter.service"
+
+do_configure_prepend () {
+    # Improve reproducibility for c++ object files
+    reltivepath="${@os.path.relpath(d.getVar('STAGING_INCDIR'), d.getVar('S'))}"
+    sed -i "s:@RELATIVE_STAGING_INCDIR@:$reltivepath:g" ${S}/stringtable.h
+}
 
 do_install_append () {
    if [ ! -f ${D}${bindir}/stap ]; then
@@ -31,6 +50,14 @@
       rm -rf ${D}${datadir}/${PN}
       rm ${D}${libexecdir}/${PN}/stap-env
    fi
+
+   # Fix makefile hardcoded path assumptions for systemd (assumes $prefix)
+   install -d `dirname ${D}${systemd_unitdir}`
+   mv ${D}${prefix}/lib/systemd `dirname ${D}${systemd_unitdir}`
+   rmdir ${D}${prefix}/lib --ignore-fail-on-non-empty
+
+   # Ensure correct ownership for files copied in
+   chown root:root ${D}${sysconfdir}/stap-exporter/* -R
 }
 
 BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap_git.inc b/poky/meta/recipes-kernel/systemtap/systemtap_git.inc
index e2f5204..274fcde 100644
--- a/poky/meta/recipes-kernel/systemtap/systemtap_git.inc
+++ b/poky/meta/recipes-kernel/systemtap/systemtap_git.inc
@@ -1,7 +1,7 @@
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-SRCREV = "4051c70c9318c837981384cbb23f3e9eb1bd0892"
-PV = "3.2"
+SRCREV = "428f84e9e656bce71018e8902e4edb8aacafcc0e"
+PV = "4.0"
 
 SRC_URI = "git://sourceware.org/git/systemtap.git \
            file://configure-allow-to-disable-libvirt.patch \
@@ -10,19 +10,7 @@
            file://no-msgfmt-check.patch \
            file://0001-Do-not-let-configure-write-a-python-location-into-th.patch \
            file://0001-Install-python-modules-to-correct-library-dir.patch \
-           file://0001-buildrun-remove-quotes-around-I-include-line.patch \
            file://0001-staprun-stapbpf-don-t-support-installing-a-non-root.patch \
-           file://0001-Fix-PR22551-by-updating-the-use-of-timers-for-the-4..patch \
-           file://0001-Fixes-for-gcc-8.patch \
-           file://0001-Use-sysroot-when-looking-for-the-System.map-file.patch \
-           file://0001-debuginfo-lookup-with-sysroot-case-do-not-remove-sys.patch \
-           file://0001-Make-sure-sysroot-paths-don-t-end-with-a-slash.patch \
-           file://0001-sysroot-fix-short-release-r-option-handling.patch \
-           file://0001-Delay-adding-sysroot-path-to-module-name-in-case-of-.patch \
-           file://0001-Added-a-couple-of-small-sysroot-fixes.patch \
-           file://0001-_stp_umodule_relocate-needs-target-file-path-not-hos.patch \
-           file://0001-sysroot-handle-symbolic-links-with-absolute-name-rel.patch \
-           file://0001-sysroot-fix-short-release-r-option-handling-follow-u.patch \
            "
 
 COMPATIBLE_HOST = '(x86_64|i.86|powerpc|arm|aarch64|microblazeel|mips).*-linux'
diff --git a/poky/meta/recipes-kernel/trace-cmd/kernelshark_git.bb b/poky/meta/recipes-kernel/trace-cmd/kernelshark_git.bb
deleted file mode 100644
index 9a5e800..0000000
--- a/poky/meta/recipes-kernel/trace-cmd/kernelshark_git.bb
+++ /dev/null
@@ -1,33 +0,0 @@
-SUMMARY = "Graphical trace viewer for Ftrace"
-LICENSE = "GPLv2"
-
-require trace-cmd.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \
-                    file://kernel-shark.c;beginline=6;endline=8;md5=2c22c965a649ddd7973d7913c5634a5e"
-
-DEPENDS = "gtk+ libxml2"
-RDEPENDS_${PN} = "trace-cmd"
-
-inherit distro_features_check
-ANY_OF_DISTRO_FEATURES = "${GTK2DISTROFEATURES}"
-
-EXTRA_OEMAKE = "\
-    'prefix=${prefix}' \
-    'bindir_relative=${@oe.path.relative(prefix, bindir)}' \
-    'libdir=${libdir}' \
-    NO_PYTHON=1 \
-    gui \
-"
-do_configure_prepend() {
-    # Make sure the recompile is OK
-    rm -f ${B}/.*.d
-}
-
-do_install() {
-    oe_runmake DESTDIR="${D}" install_gui
-    rm ${D}${bindir}/trace-cmd
-    rm -rf ${D}${libdir}/trace-cmd
-    rm -rf ${D}${sysconfdir}/bash_completion.d/trace-cmd.bash
-    rmdir ${D}${libdir}
-}
diff --git a/poky/meta/recipes-kernel/trace-cmd/trace-cmd.inc b/poky/meta/recipes-kernel/trace-cmd/trace-cmd.inc
deleted file mode 100644
index 0a1789c..0000000
--- a/poky/meta/recipes-kernel/trace-cmd/trace-cmd.inc
+++ /dev/null
@@ -1,13 +0,0 @@
-SRCREV = "7d0147bbba3ed1d5ef6eea4eec3f0ad4c98f02b5"
-PV = "2.7"
-
-inherit pkgconfig
-
-FILESEXTRAPATHS =. "${FILE_DIRNAME}/trace-cmd:"
-
-SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/trace-cmd.git \
-           file://blktrace-api-compatibility.patch \
-           file://0001-Include-limits.h-so-that-PATH_MAX-is-defined-an-issu.patch \
-"
-
-S = "${WORKDIR}/git"
diff --git a/poky/meta/recipes-kernel/trace-cmd/trace-cmd/0001-Include-limits.h-so-that-PATH_MAX-is-defined-an-issu.patch b/poky/meta/recipes-kernel/trace-cmd/trace-cmd/0001-Include-limits.h-so-that-PATH_MAX-is-defined-an-issu.patch
deleted file mode 100644
index 5763083..0000000
--- a/poky/meta/recipes-kernel/trace-cmd/trace-cmd/0001-Include-limits.h-so-that-PATH_MAX-is-defined-an-issu.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 9488f92c1d0c7931c3e17950d1f9eea2aeb3e2bd Mon Sep 17 00:00:00 2001
-From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Wed, 14 Jun 2017 15:56:18 +0300
-Subject: [PATCH] Include limits.h so that PATH_MAX is defined (an issue on
- musl).
-
-Upstream-Status: Pending
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
----
- trace-listen.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/trace-listen.c b/trace-listen.c
-index 17ff9d8..838d6bc 100644
---- a/trace-listen.c
-+++ b/trace-listen.c
-@@ -31,6 +31,7 @@
- #include <fcntl.h>
- #include <signal.h>
- #include <errno.h>
-+#include <limits.h>
- 
- #include "trace-local.h"
- #include "trace-msg.h"
--- 
-2.11.0
-
diff --git a/poky/meta/recipes-kernel/trace-cmd/trace-cmd/blktrace-api-compatibility.patch b/poky/meta/recipes-kernel/trace-cmd/trace-cmd/blktrace-api-compatibility.patch
deleted file mode 100644
index 320db6a..0000000
--- a/poky/meta/recipes-kernel/trace-cmd/trace-cmd/blktrace-api-compatibility.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-trace-cmd: Add blktrace_api compatibility for TC_BARRIER
-
-Newer kernels replace TC_BARRIER with TC_FLUSH. Ensure trace-cmd
-can build regardless of the linux-kernel-headers version.
-
-Upstream-Status: Inappropriate [Stop gap]
-
-Signed-off-by: Darren Hart <dvhart@linux.intel.com>
-
-diff --git a/plugin_blk.c b/plugin_blk.c
-index 9327b17..c8e5e1c 100644
---- a/plugin_blk.c
-+++ b/plugin_blk.c
-@@ -44,6 +44,15 @@ struct blk_data {
- 	unsigned short		pdu_len;
- };
- 
-+/*
-+ * Newer kernels don't define BLK_TC_BARRIER and have replaced it with
-+ * BLK_TC_FLUSH. In this case, define it here and report FLUSHES as BARRIERS as
-+ * a workaround, as described in:
-+ * http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commit;h=c09c47caedc9854d59378d6e34c989e51cfdd2b4
-+ */
-+#ifndef BLK_TC_BARRIER
-+#define BLK_TC_BARRIER 1<<2
-+#endif
- static void fill_rwbs(char *rwbs, int action, unsigned int bytes)
- {
- 	int i = 0;
diff --git a/poky/meta/recipes-kernel/trace-cmd/trace-cmd_git.bb b/poky/meta/recipes-kernel/trace-cmd/trace-cmd_git.bb
deleted file mode 100644
index 27c7c19..0000000
--- a/poky/meta/recipes-kernel/trace-cmd/trace-cmd_git.bb
+++ /dev/null
@@ -1,34 +0,0 @@
-SUMMARY = "User interface to Ftrace"
-HOMEPAGE = "http://git.kernel.org/"
-LICENSE = "GPLv2 & LGPLv2.1"
-
-require trace-cmd.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \
-                    file://trace-cmd.c;beginline=6;endline=8;md5=2c22c965a649ddd7973d7913c5634a5e \
-                    file://COPYING.LIB;md5=edb195fe538e4552c1f6ca0fd7bf4f0a \
-                    file://trace-input.c;beginline=5;endline=8;md5=3ec82f43bbe0cfb5951ff414ef4d44d0 \
-"
-
-EXTRA_OEMAKE = "\
-    'prefix=${prefix}' \
-    'bindir=${bindir}' \
-    'man_dir=${mandir}' \
-    'html_install=${datadir}/kernelshark/html' \
-    'img_install=${datadir}/kernelshark/html/images' \
-    \
-    'bindir_relative=${@oe.path.relative(prefix, bindir)}' \
-    'libdir=${libdir}' \
-    \
-    NO_PYTHON=1 \
-"
-
-do_compile_prepend() {
-    # Make sure the recompile is OK
-    rm -f ${B}/.*.d
-}
-
-do_install() {
-        oe_runmake DESTDIR="${D}" install
-}
-
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-fpu.inc b/poky/meta/recipes-multimedia/alsa/alsa-fpu.inc
deleted file mode 100644
index 355a9df..0000000
--- a/poky/meta/recipes-multimedia/alsa/alsa-fpu.inc
+++ /dev/null
@@ -1,4 +0,0 @@
-def get_alsa_fpu_setting(bb, d):
-    if d.getVar('TARGET_FPU') in [ 'soft' ]:
-        return "--with-softfloat"
-    return ""
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-lib_1.1.5.bb b/poky/meta/recipes-multimedia/alsa/alsa-lib_1.1.5.bb
deleted file mode 100644
index 0f1e2db..0000000
--- a/poky/meta/recipes-multimedia/alsa/alsa-lib_1.1.5.bb
+++ /dev/null
@@ -1,39 +0,0 @@
-SUMMARY = "ALSA sound library"
-HOMEPAGE = "http://www.alsa-project.org"
-BUGTRACKER = "http://alsa-project.org/main/index.php/Bug_Tracking"
-SECTION = "libs/multimedia"
-LICENSE = "LGPLv2.1 & GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=7fbc338309ac38fefcd64b04bb903e34 \
-                    file://src/socket.c;beginline=1;endline=26;md5=11ff89a8a7a4a690a5c78effe8159545"
-
-BBCLASSEXTEND = "native nativesdk"
-
-SRC_URI = "ftp://ftp.alsa-project.org/pub/lib/${BP}.tar.bz2"
-SRC_URI[md5sum] = "a2b465c3a5265d8a57f3ff39c6c4fc29"
-SRC_URI[sha256sum] = "f4f68ad3c6da36b0b5241ac3c798a7a71e0e97d51f972e9f723b3f20a9650ae6"
-
-inherit autotools pkgconfig
-
-require alsa-fpu.inc
-EXTRA_OECONF += "${@get_alsa_fpu_setting(bb, d)} "
-
-EXTRA_OECONF += "--disable-python"
-
-PACKAGES =+ "alsa-server alsa-conf alsa-doc"
-FILES_alsa-server = "${bindir}/*"
-FILES_alsa-conf = "${datadir}/alsa/"
-
-RDEPENDS_${PN}_class-target = "alsa-conf"
-
-# upgrade path
-RPROVIDES_${PN} = "libasound"
-RREPLACES_${PN} = "libasound"
-RCONFLICTS_${PN} = "libasound"
-
-RPROVIDES_${PN}-dev = "alsa-dev"
-RREPLACES_${PN}-dev = "alsa-dev"
-RCONFLICTS_${PN}-dev = "alsa-dev"
-
-RPROVIDES_alsa-conf = "alsa-conf-base"
-RREPLACES_alsa-conf = "alsa-conf-base"
-RCONFLICTS_alsa-conf = "alsa-conf-base"
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-lib_1.1.6.bb b/poky/meta/recipes-multimedia/alsa/alsa-lib_1.1.6.bb
new file mode 100644
index 0000000..25e7a3c
--- /dev/null
+++ b/poky/meta/recipes-multimedia/alsa/alsa-lib_1.1.6.bb
@@ -0,0 +1,41 @@
+SUMMARY = "ALSA sound library"
+HOMEPAGE = "http://www.alsa-project.org"
+BUGTRACKER = "http://alsa-project.org/main/index.php/Bug_Tracking"
+SECTION = "libs/multimedia"
+LICENSE = "LGPLv2.1 & GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=a916467b91076e631dd8edb7424769c7 \
+                    file://src/socket.c;md5=dd1bc7f44872690224d89c1a9806e495;beginline=1;endline=26 \
+                    "
+
+SRC_URI = "ftp://ftp.alsa-project.org/pub/lib/${BP}.tar.bz2"
+SRC_URI[md5sum] = "2f981a8f7897c59ec2ddc44916d33788"
+SRC_URI[sha256sum] = "5f2cd274b272cae0d0d111e8a9e363f08783329157e8dd68b3de0c096de6d724"
+
+inherit autotools pkgconfig
+
+EXTRA_OECONF += " \
+    ${@bb.utils.contains('TARGET_FPU', 'soft', '--with-softfloat', '', d)} \
+    --disable-python \
+"
+
+PACKAGES =+ "alsa-server alsa-conf alsa-doc"
+
+FILES_alsa-server = "${bindir}/*"
+FILES_alsa-conf = "${datadir}/alsa/"
+
+RDEPENDS_${PN}_class-target = "alsa-conf"
+
+# upgrade path
+RPROVIDES_${PN} = "libasound"
+RREPLACES_${PN} = "libasound"
+RCONFLICTS_${PN} = "libasound"
+
+RPROVIDES_${PN}-dev = "alsa-dev"
+RREPLACES_${PN}-dev = "alsa-dev"
+RCONFLICTS_${PN}-dev = "alsa-dev"
+
+RPROVIDES_alsa-conf = "alsa-conf-base"
+RREPLACES_alsa-conf = "alsa-conf-base"
+RCONFLICTS_alsa-conf = "alsa-conf-base"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-plugins_1.1.5.bb b/poky/meta/recipes-multimedia/alsa/alsa-plugins_1.1.5.bb
deleted file mode 100644
index 4bd0acc..0000000
--- a/poky/meta/recipes-multimedia/alsa/alsa-plugins_1.1.5.bb
+++ /dev/null
@@ -1,103 +0,0 @@
-SUMMARY = "ALSA Plugins"
-HOMEPAGE = "http://alsa-project.org"
-BUGTRACKER = "http://alsa-project.org/main/index.php/Bug_Tracking"
-SECTION = "multimedia"
-
-# The primary license of alsa-plugins is LGPLv2.1.
-#
-# m4/attributes.m4 is licensed under GPLv2+. m4/attributes.m4 is part of the
-# build system, and doesn't affect the licensing of the build result.
-#
-# The samplerate plugin source code is licensed under GPLv2+ to be consistent
-# with the libsamplerate license. However, if the licensee has a commercial
-# license for libsamplerate, the samplerate plugin may be used under the terms
-# of LGPLv2.1 like the rest of the plugins.
-LICENSE = "LGPLv2.1 & GPLv2+"
-LIC_FILES_CHKSUM = "\
-        file://COPYING;md5=7fbc338309ac38fefcd64b04bb903e34 \
-        file://COPYING.GPL;md5=94d55d512a9ba36caa9b7df079bae19f \
-        file://m4/attributes.m4;endline=33;md5=b25958da44c02231e3641f1bccef53eb \
-        file://rate/rate_samplerate.c;endline=35;md5=fd77bce85f4a338c0e8ab18430b69fae \
-"
-
-SRC_URI = "ftp://ftp.alsa-project.org/pub/plugins/${BP}.tar.bz2"
-SRC_URI[md5sum] = "f898b0e6e8acf3f6f82bc2a0f0c84a97"
-SRC_URI[sha256sum] = "797da5f8f53379fbea28817bc466de16affd2c07849e84f1af8d5e22f7bb7f1c"
-
-DEPENDS += "alsa-lib"
-
-inherit autotools pkgconfig
-
-PACKAGECONFIG ??= "\
-        samplerate \
-        speexdsp \
-        ${@bb.utils.filter('DISTRO_FEATURES', 'pulseaudio', d)} \
-"
-PACKAGECONFIG[avcodec] = "--enable-avcodec,--disable-avcodec,libav"
-PACKAGECONFIG[jack] = "--enable-jack,--disable-jack,jack"
-PACKAGECONFIG[maemo-plugin] = "--enable-maemo-plugin,--disable-maemo-plugin"
-PACKAGECONFIG[maemo-resource-manager] = "--enable-maemo-resource-manager,--disable-maemo-resource-manager,dbus"
-PACKAGECONFIG[pulseaudio] = "--enable-pulseaudio,--disable-pulseaudio,pulseaudio"
-PACKAGECONFIG[samplerate] = "--enable-samplerate,--disable-samplerate,libsamplerate0"
-PACKAGECONFIG[speexdsp] = "--with-speex=lib,--with-speex=no,speexdsp"
-
-PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'pulseaudio', 'alsa-plugins-pulseaudio-conf', '', d)}"
-
-PACKAGES_DYNAMIC = "^libasound-module-.*"
-
-# The alsa-plugins package doesn't itself contain anything, it just depends on
-# all built plugins.
-ALLOW_EMPTY_${PN} = "1"
-
-do_install_append() {
-	rm ${D}${libdir}/alsa-lib/*.la
-
-	# We use the example as is, so just drop the .example suffix.
-	if [ "${@bb.utils.contains('PACKAGECONFIG', 'pulseaudio', 'yes', 'no', d)}" = "yes" ]; then
-		mv ${D}${datadir}/alsa/alsa.conf.d/99-pulseaudio-default.conf.example ${D}${datadir}/alsa/alsa.conf.d/99-pulseaudio-default.conf
-	fi
-}
-
-python populate_packages_prepend() {
-    plugindir = d.expand('${libdir}/alsa-lib/')
-    packages = " ".join(do_split_packages(d, plugindir, '^libasound_module_(.*)\.so$', 'libasound-module-%s', 'Alsa plugin for %s', extra_depends=''))
-    d.setVar("RDEPENDS_alsa-plugins", packages)
-}
-
-# The rate plugins create some symlinks. For example, the samplerate plugin
-# creates these links to the main plugin file:
-#
-#   libasound_module_rate_samplerate_best.so
-#   libasound_module_rate_samplerate_linear.so
-#   libasound_module_rate_samplerate_medium.so
-#   libasound_module_rate_samplerate_order.so
-#
-# The other rate plugins create similar links. We have to add the links to
-# FILES manually, because do_split_packages() skips the links (which is good,
-# because we wouldn't want do_split_packages() to create separate packages for
-# the symlinks).
-#
-# The symlinks cause QA errors, because usually it's a bug if a non
-# -dev/-dbg/-nativesdk package contains links to .so files, but in this case
-# the errors are false positives, so we disable the QA checks.
-FILES_${MLPREFIX}libasound-module-rate-lavcrate += "${libdir}/alsa-lib/*rate_lavcrate_*.so"
-FILES_${MLPREFIX}libasound-module-rate-samplerate += "${libdir}/alsa-lib/*rate_samplerate_*.so"
-FILES_${MLPREFIX}libasound-module-rate-speexrate += "${libdir}/alsa-lib/*rate_speexrate_*.so"
-INSANE_SKIP_${MLPREFIX}libasound-module-rate-lavcrate = "dev-so"
-INSANE_SKIP_${MLPREFIX}libasound-module-rate-samplerate = "dev-so"
-INSANE_SKIP_${MLPREFIX}libasound-module-rate-speexrate = "dev-so"
-
-# 50-pulseaudio.conf defines a device named "pulse" that applications can use
-# if they explicitly want to use the PulseAudio plugin.
-# 99-pulseaudio-default.conf configures the "default" device to use the
-# PulseAudio plugin.
-FILES_${PN}-pulseaudio-conf += "\
-        ${datadir}/alsa/alsa.conf.d/50-pulseaudio.conf \
-        ${datadir}/alsa/alsa.conf.d/99-pulseaudio-default.conf \
-"
-
-RDEPENDS_${PN}-pulseaudio-conf += "\
-        libasound-module-conf-pulse \
-        libasound-module-ctl-pulse \
-        libasound-module-pcm-pulse \
-"
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-plugins_1.1.6.bb b/poky/meta/recipes-multimedia/alsa/alsa-plugins_1.1.6.bb
new file mode 100644
index 0000000..17c1879
--- /dev/null
+++ b/poky/meta/recipes-multimedia/alsa/alsa-plugins_1.1.6.bb
@@ -0,0 +1,103 @@
+SUMMARY = "ALSA Plugins"
+HOMEPAGE = "http://alsa-project.org"
+BUGTRACKER = "http://alsa-project.org/main/index.php/Bug_Tracking"
+SECTION = "multimedia"
+
+# The primary license of alsa-plugins is LGPLv2.1.
+#
+# m4/attributes.m4 is licensed under GPLv2+. m4/attributes.m4 is part of the
+# build system, and doesn't affect the licensing of the build result.
+#
+# The samplerate plugin source code is licensed under GPLv2+ to be consistent
+# with the libsamplerate license. However, if the licensee has a commercial
+# license for libsamplerate, the samplerate plugin may be used under the terms
+# of LGPLv2.1 like the rest of the plugins.
+LICENSE = "LGPLv2.1 & GPLv2+"
+LIC_FILES_CHKSUM = "\
+        file://COPYING;md5=a916467b91076e631dd8edb7424769c7 \
+        file://COPYING.GPL;md5=59530bdf33659b29e73d4adb9f9f6552 \
+        file://m4/attributes.m4;endline=33;md5=b25958da44c02231e3641f1bccef53eb \
+        file://rate/rate_samplerate.c;endline=35;md5=fd77bce85f4a338c0e8ab18430b69fae \
+"
+
+SRC_URI = "ftp://ftp.alsa-project.org/pub/plugins/${BP}.tar.bz2"
+SRC_URI[md5sum] = "8387279e99feeb2ecffaac5f293223d7"
+SRC_URI[sha256sum] = "6f1d31ebe3b1fa1cc8dade60b7bed1cb2583ac998167002d350dc0a5e3e40c13"
+
+DEPENDS += "alsa-lib"
+
+inherit autotools pkgconfig
+
+PACKAGECONFIG ??= "\
+        samplerate \
+        speexdsp \
+        ${@bb.utils.filter('DISTRO_FEATURES', 'pulseaudio', d)} \
+"
+PACKAGECONFIG[avcodec] = "--enable-avcodec,--disable-avcodec,libav"
+PACKAGECONFIG[jack] = "--enable-jack,--disable-jack,jack"
+PACKAGECONFIG[maemo-plugin] = "--enable-maemo-plugin,--disable-maemo-plugin"
+PACKAGECONFIG[maemo-resource-manager] = "--enable-maemo-resource-manager,--disable-maemo-resource-manager,dbus"
+PACKAGECONFIG[pulseaudio] = "--enable-pulseaudio,--disable-pulseaudio,pulseaudio"
+PACKAGECONFIG[samplerate] = "--enable-samplerate,--disable-samplerate,libsamplerate0"
+PACKAGECONFIG[speexdsp] = "--with-speex=lib,--with-speex=no,speexdsp"
+
+PACKAGES += "${@bb.utils.contains('PACKAGECONFIG', 'pulseaudio', 'alsa-plugins-pulseaudio-conf', '', d)}"
+
+PACKAGES_DYNAMIC = "^libasound-module-.*"
+
+# The alsa-plugins package doesn't itself contain anything, it just depends on
+# all built plugins.
+ALLOW_EMPTY_${PN} = "1"
+
+do_install_append() {
+	rm ${D}${libdir}/alsa-lib/*.la
+
+	# We use the example as is, so just drop the .example suffix.
+	if [ "${@bb.utils.contains('PACKAGECONFIG', 'pulseaudio', 'yes', 'no', d)}" = "yes" ]; then
+		mv ${D}${datadir}/alsa/alsa.conf.d/99-pulseaudio-default.conf.example ${D}${datadir}/alsa/alsa.conf.d/99-pulseaudio-default.conf
+	fi
+}
+
+python populate_packages_prepend() {
+    plugindir = d.expand('${libdir}/alsa-lib/')
+    packages = " ".join(do_split_packages(d, plugindir, '^libasound_module_(.*)\.so$', 'libasound-module-%s', 'Alsa plugin for %s', extra_depends=''))
+    d.setVar("RDEPENDS_alsa-plugins", packages)
+}
+
+# The rate plugins create some symlinks. For example, the samplerate plugin
+# creates these links to the main plugin file:
+#
+#   libasound_module_rate_samplerate_best.so
+#   libasound_module_rate_samplerate_linear.so
+#   libasound_module_rate_samplerate_medium.so
+#   libasound_module_rate_samplerate_order.so
+#
+# The other rate plugins create similar links. We have to add the links to
+# FILES manually, because do_split_packages() skips the links (which is good,
+# because we wouldn't want do_split_packages() to create separate packages for
+# the symlinks).
+#
+# The symlinks cause QA errors, because usually it's a bug if a non
+# -dev/-dbg/-nativesdk package contains links to .so files, but in this case
+# the errors are false positives, so we disable the QA checks.
+FILES_${MLPREFIX}libasound-module-rate-lavcrate += "${libdir}/alsa-lib/*rate_lavcrate_*.so"
+FILES_${MLPREFIX}libasound-module-rate-samplerate += "${libdir}/alsa-lib/*rate_samplerate_*.so"
+FILES_${MLPREFIX}libasound-module-rate-speexrate += "${libdir}/alsa-lib/*rate_speexrate_*.so"
+INSANE_SKIP_${MLPREFIX}libasound-module-rate-lavcrate = "dev-so"
+INSANE_SKIP_${MLPREFIX}libasound-module-rate-samplerate = "dev-so"
+INSANE_SKIP_${MLPREFIX}libasound-module-rate-speexrate = "dev-so"
+
+# 50-pulseaudio.conf defines a device named "pulse" that applications can use
+# if they explicitly want to use the PulseAudio plugin.
+# 99-pulseaudio-default.conf configures the "default" device to use the
+# PulseAudio plugin.
+FILES_${PN}-pulseaudio-conf += "\
+        ${datadir}/alsa/alsa.conf.d/50-pulseaudio.conf \
+        ${datadir}/alsa/alsa.conf.d/99-pulseaudio-default.conf \
+"
+
+RDEPENDS_${PN}-pulseaudio-conf += "\
+        libasound-module-conf-pulse \
+        libasound-module-ctl-pulse \
+        libasound-module-pcm-pulse \
+"
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-tools/0002-Fix-clang-Wreserved-user-defined-literal-warnings.patch b/poky/meta/recipes-multimedia/alsa/alsa-tools/0002-Fix-clang-Wreserved-user-defined-literal-warnings.patch
new file mode 100644
index 0000000..c137bc8
--- /dev/null
+++ b/poky/meta/recipes-multimedia/alsa/alsa-tools/0002-Fix-clang-Wreserved-user-defined-literal-warnings.patch
@@ -0,0 +1,34 @@
+Upstream-Status: Backport
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+From a861bdabf02cd9bfb3ec7c0571c563c0fa14adfb Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 24 Apr 2018 12:24:32 -0700
+Subject: [PATCH] us428control: Fix clang -Wreserved-user-defined-literal
+ warnings
+
+| us428control.cc:66:18: error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Wreserved-user-defined-literal]
+|         printf("usage: "PROGNAME" [-v verbosity_level 0..2] [-c card] [-D device] [-u usb-device] [-m mode]\n");
+|                         ^
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Takashi Iwai <tiwai@suse.de>
+---
+ us428control/us428control.cc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/us428control/us428control.cc b/us428control/us428control.cc
+index e839bf4..8cb3c42 100644
+--- a/us428control/us428control.cc
++++ b/us428control/us428control.cc
+@@ -63,7 +63,7 @@ static void usage(void)
+ {
+ 	printf("Tascam US-428 Control\n");
+ 	printf("version %s\n", VERSION);
+-	printf("usage: "PROGNAME" [-v verbosity_level 0..2] [-c card] [-D device] [-u usb-device] [-m mode]\n");
++	printf("usage: " PROGNAME " [-v verbosity_level 0..2] [-c card] [-D device] [-u usb-device] [-m mode]\n");
+ 	printf("mode is one of (us224, us428, mixxx)\n");
+ }
+ /*
+-- 
+1.7.11.7
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-tools/autotools.patch b/poky/meta/recipes-multimedia/alsa/alsa-tools/autotools.patch
deleted file mode 100644
index 2e74963..0000000
--- a/poky/meta/recipes-multimedia/alsa/alsa-tools/autotools.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-Add parameters to autoreconf to support cross compile.
-Remove some sub-components which needs further recipe support.
-
-Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
-
-Upstream-Status: Inappropriate [configuration]
-
-diff -ruN alsa-tools-1.0.24.1-orig//ld10k1/gitcompile alsa-tools-1.0.24.1/ld10k1/gitcompile
---- alsa-tools-1.0.24.1-orig//ld10k1/gitcompile	2011-07-06 11:27:40.227665002 +0800
-+++ alsa-tools-1.0.24.1/ld10k1/gitcompile	2011-07-14 13:26:18.017665004 +0800
-@@ -1,6 +1,6 @@
- #!/bin/bash
- 
--autoreconf -fi || exit 1
-+autoreconf $ACLOCAL_FLAGS -fi || exit 1
- export CFLAGS='-O2 -Wall -pipe -g'
- echo "CFLAGS=$CFLAGS"
- echo "./configure $@"
-diff -ruN alsa-tools-1.0.24.1-orig//Makefile alsa-tools-1.0.24.1/Makefile
---- alsa-tools-1.0.24.1-orig//Makefile	2011-07-06 11:27:40.207665000 +0800
-+++ alsa-tools-1.0.24.1/Makefile	2011-07-14 15:08:08.877665009 +0800
-@@ -1,8 +1,8 @@
- VERSION = 1.1.5
- TOP = .
--SUBDIRS = as10k1 envy24control hdsploader hdspconf hdspmixer \
-+SUBDIRS = as10k1 envy24control \
- 	  mixartloader pcxhrloader rmedigicontrol sb16_csp seq sscape_ctl \
--	  us428control usx2yloader vxloader echomixer ld10k1 qlo10k1 \
-+	  us428control usx2yloader vxloader echomixer \
- 	  hwmixvolume hdajackretask hda-verb hdajacksensetest
- 
- all:
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-tools/gitcompile_hdajacksensetest b/poky/meta/recipes-multimedia/alsa/alsa-tools/gitcompile_hdajacksensetest
deleted file mode 100755
index 58328bd..0000000
--- a/poky/meta/recipes-multimedia/alsa/alsa-tools/gitcompile_hdajacksensetest
+++ /dev/null
@@ -1,13 +0,0 @@
-#!/bin/bash
-
-aclocal $ACLOCAL_FLAGS || exit 1
-automake --foreign --add-missing || exit 1
-autoconf || exit 1
-export CFLAGS='-O2 -Wall -pipe -g'
-echo "CFLAGS=$CFLAGS"
-echo "./configure $@"
-./configure $@ || exit 1
-unset CFLAGS
-if [ -z "$GITCOMPILE_NO_MAKE" ]; then
-  make || exit 1
-fi
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-tools/makefile_no_gtk.patch b/poky/meta/recipes-multimedia/alsa/alsa-tools/makefile_no_gtk.patch
deleted file mode 100644
index 54373d1..0000000
--- a/poky/meta/recipes-multimedia/alsa/alsa-tools/makefile_no_gtk.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-Remove some sub-components which need gtk+.
-
-Upstream-Status: Inappropriate [configuration]
-
-Signed-off-by: Rogerio Nunes <ronunes@gmail.com>
-Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
-
-Update patch for alsa-tools 1.0.29
-
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
-
-diff --git a/Makefile b/Makefile
-index 2457a1c..72346d9 100644
---- a/Makefile
-+++ b/Makefile
-@@ -1,9 +1,9 @@
- VERSION = 1.1.5
- TOP = .
--SUBDIRS = as10k1 envy24control \
--	  mixartloader pcxhrloader rmedigicontrol sb16_csp seq sscape_ctl \
--	  us428control usx2yloader vxloader echomixer \
--	  hwmixvolume hdajackretask hda-verb hdajacksensetest
-+SUBDIRS = as10k1 \
-+	  mixartloader pcxhrloader sb16_csp seq sscape_ctl \
-+	  us428control usx2yloader vxloader \
-+	  hwmixvolume hda-verb hdajacksensetest
- 
- all:
- 	@for i in $(SUBDIRS); do \
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-tools/musl.patch b/poky/meta/recipes-multimedia/alsa/alsa-tools/musl.patch
new file mode 100644
index 0000000..9eb129c
--- /dev/null
+++ b/poky/meta/recipes-multimedia/alsa/alsa-tools/musl.patch
@@ -0,0 +1,47 @@
+Upstream-Status: Backport
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+From 235d9c5e8381518b0a8661786e7e0cbdd1bbcd01 Mon Sep 17 00:00:00 2001
+From: Ross Burton <ross.burton@intel.com>
+Date: Tue, 12 Jun 2018 13:24:34 +0100
+Subject: [PATCH] ld10k1: define _GNU_SOURCE and use sighandler_t
+
+__sighandler_t is a glibc internal type which doesn't exist in musl.  By using
+AC_USE_SYSTEM_EXTENSIONS to get _GNU_SOURCE defined, both glibc and musl
+then expose sighandler_t.
+
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+Signed-off-by: Takashi Iwai <tiwai@suse.de>
+---
+ ld10k1/configure.ac      | 1 +
+ ld10k1/src/ld10k1_fnc1.c | 2 +-
+ 2 files changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/ld10k1/configure.ac b/ld10k1/configure.ac
+index 276b24e..f48ca31 100644
+--- a/ld10k1/configure.ac
++++ b/ld10k1/configure.ac
+@@ -4,6 +4,7 @@ AC_CONFIG_MACRO_DIR([m4])
+ AM_MAINTAINER_MODE([enable])
+ 
+ AC_CONFIG_HEADERS(config.h)
++AC_USE_SYSTEM_EXTENSIONS
+ AC_PROG_CC
+ AC_PROG_LD
+ AC_PROG_INSTALL
+diff --git a/ld10k1/src/ld10k1_fnc1.c b/ld10k1/src/ld10k1_fnc1.c
+index 343584c..ddc43c6 100644
+--- a/ld10k1/src/ld10k1_fnc1.c
++++ b/ld10k1/src/ld10k1_fnc1.c
+@@ -179,7 +179,7 @@ int main_loop(comm_param *param, int audigy, const char *card_id, int tram_size,
+ {
+ 	fd_set active_fd_set/*, read_fd_set*/;
+ 	int i, j, res = 0;
+-	__sighandler_t old_sig_pipe;
++	sighandler_t old_sig_pipe;
+ 
+ 	int main_sock = 0;
+ 	int data_sock = 0;
+-- 
+2.11.0
+
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-tools_1.1.5.bb b/poky/meta/recipes-multimedia/alsa/alsa-tools_1.1.5.bb
deleted file mode 100644
index 1be43aa..0000000
--- a/poky/meta/recipes-multimedia/alsa/alsa-tools_1.1.5.bb
+++ /dev/null
@@ -1,40 +0,0 @@
-SUMMARY = "Advanced tools for certain ALSA sound card drivers"
-HOMEPAGE = "http://www.alsa-project.org"
-BUGTRACKER = "http://alsa-project.org/main/index.php/Bug_Tracking"
-SECTION = "console/utils"
-LICENSE = "GPLv2 & LGPLv2+"
-DEPENDS = "alsa-lib ncurses glib-2.0"
-
-LIC_FILES_CHKSUM = "file://hdsploader/COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
-                    file://ld10k1/COPYING.LIB;md5=7fbc338309ac38fefcd64b04bb903e34"
-
-SRC_URI = "ftp://ftp.alsa-project.org/pub/tools/${BP}.tar.bz2 \
-           file://autotools.patch \
-           ${@bb.utils.contains('DISTRO_FEATURES', 'x11', '', 'file://makefile_no_gtk.patch', d)} \
-           file://gitcompile_hdajacksensetest \
-           "
-
-SRC_URI[md5sum] = "3afb92eb1b4f2edc8691498e57c3ec78"
-SRC_URI[sha256sum] = "bc3c6567de835223ee7d69487b8c22fb395a2e8c613341b0c96e6a5f6a2bd534"
-
-inherit autotools-brokensep pkgconfig
-
-CLEANBROKEN = "1"
-
-EXTRA_OEMAKE += "GITCOMPILE_ARGS='--host=${HOST_SYS} --build=${BUILD_SYS} --target=${TARGET_SYS} --with-libtool-sysroot=${STAGING_DIR_HOST} --prefix=${prefix}'"
-
-PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'gtk+', '', d)}"
-PACKAGECONFIG[gtk+] = ",,gtk+ gtk+3,"
-
-# configure.ac/.in doesn't exist so force copy
-AUTOTOOLS_COPYACLOCAL = "1"
-
-do_compile_prepend () {
-    #Automake dir is not correctly detected in cross compilation case
-    export AUTOMAKE_DIR="$(automake --print-libdir)"
-    export ACLOCAL_FLAGS="--system-acdir=${ACLOCALDIR}/ ${ACLOCALEXTRAPATH}"
-
-    cp ${WORKDIR}/gitcompile_hdajacksensetest ${S}/hdajacksensetest/gitcompile
-}
-
-FILES_${PN} += "${datadir}/ld10k1"
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-tools_1.1.6.bb b/poky/meta/recipes-multimedia/alsa/alsa-tools_1.1.6.bb
new file mode 100644
index 0000000..90e54db
--- /dev/null
+++ b/poky/meta/recipes-multimedia/alsa/alsa-tools_1.1.6.bb
@@ -0,0 +1,87 @@
+SUMMARY = "Advanced tools for certain ALSA sound card drivers"
+HOMEPAGE = "http://www.alsa-project.org"
+BUGTRACKER = "http://alsa-project.org/main/index.php/Bug_Tracking"
+SECTION = "console/utils"
+LICENSE = "GPLv2 & LGPLv2+"
+DEPENDS = "alsa-lib"
+
+LIC_FILES_CHKSUM = "file://hdsploader/COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
+                    file://ld10k1/COPYING.LIB;md5=a916467b91076e631dd8edb7424769c7 \
+                    "
+
+SRC_URI = "ftp://ftp.alsa-project.org/pub/tools/${BP}.tar.bz2 \
+           file://0002-Fix-clang-Wreserved-user-defined-literal-warnings.patch \
+           file://musl.patch \
+           "
+
+SRC_URI[md5sum] = "5ca8c9437ae779997cd62fb2815fef19"
+SRC_URI[sha256sum] = "d69c4dc2fb641a974d9903e9eb78c94cb0c7ac6c45bae664f0c9d6c0a1593227"
+
+inherit autotools-brokensep pkgconfig
+# brokensep as as10k1 (and probably more) fail out of tree
+CLEANBROKEN = "1"
+
+# Here we use PACKAGECONFIG options to pick which directories we configure/build.
+# Remember on upgrades to check that no new tools have been added.
+PACKAGECONFIG ??= "as10k1 hdajacksensetest hda-verb hdsploader ld10k1 mixartloader pcxhrloader \
+                   sb16_csp seq--sbiload sscape_ctl us428control usx2yloader vxloader \
+                   ${@bb.utils.contains_any('DISTRO_FEATURES', '${GTK2DISTROFEATURES}', 'echomixer envy24control rmedigicontrol', '', d)} \
+                   ${@bb.utils.contains_any('DISTRO_FEATURES', '${GTK3DISTROFEATURES}', 'hdajackretask', '', d)} \
+                   "
+
+PACKAGECONFIG[as10k1] = ""
+PACKAGECONFIG[echomixer] = ",,gtk+"
+PACKAGECONFIG[envy24control] = ",,gtk+"
+PACKAGECONFIG[hda-verb] = ""
+PACKAGECONFIG[hdajackretask] = ",,gtk+3"
+PACKAGECONFIG[hdajacksensetest] = ",,glib-2.0"
+PACKAGECONFIG[hdspconf] = ",,fltk"
+PACKAGECONFIG[hdsploader] = ""
+PACKAGECONFIG[hdspmixer] = ",,fltk"
+PACKAGECONFIG[hwmixvolume] = ",,,python-core python-pygtk"
+PACKAGECONFIG[ld10k1] = ""
+PACKAGECONFIG[mixartloader] = ""
+PACKAGECONFIG[pcxhrloader] = ""
+PACKAGECONFIG[qlo10k1] = ",,qt-x11-free"
+PACKAGECONFIG[rmedigicontrol] = ",,gtk+"
+PACKAGECONFIG[sb16_csp] = ""
+PACKAGECONFIG[seq--sbiload] = ""
+PACKAGECONFIG[sscape_ctl] = ""
+PACKAGECONFIG[us428control] = ""
+PACKAGECONFIG[usx2yloader] = ""
+PACKAGECONFIG[vxloader] = ""
+
+python do_configure() {
+    for subdir in d.getVar("PACKAGECONFIG").split():
+        subdir = subdir.replace("--", "/")
+        bb.note("Configuring %s" % subdir)
+        dd = d.createCopy()
+        dd.setVar("S", os.path.join(d.getVar("S"), subdir))
+        bb.build.exec_func("autotools_do_configure", dd)
+}
+
+python do_compile() {
+    for subdir in d.getVar("PACKAGECONFIG").split():
+        subdir = subdir.replace("--", "/")
+        bb.note("Compiling %s" % subdir)
+        dd = d.createCopy()
+        dd.setVar("S", os.path.join(d.getVar("S"), subdir))
+        bb.build.exec_func("autotools_do_compile", dd)
+}
+
+python do_install() {
+    for subdir in d.getVar("PACKAGECONFIG").split():
+        subdir = subdir.replace("--", "/")
+        bb.note("Installing %s" % subdir)
+        dd = d.createCopy()
+        dd.setVar("S", os.path.join(d.getVar("S"), subdir))
+        bb.build.exec_func("autotools_do_install", dd)
+
+    # Just remove bash-needing init script that isn't installed as an init script
+    try:
+        os.remove(oe.path.join(d.getVar("D"), d.getVar("sbindir"), "ld10k1d"))
+    except:
+        pass
+}
+
+FILES_${PN} += "${datadir}"
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-utils-scripts_1.1.5.bb b/poky/meta/recipes-multimedia/alsa/alsa-utils-scripts_1.1.6.bb
similarity index 100%
rename from poky/meta/recipes-multimedia/alsa/alsa-utils-scripts_1.1.5.bb
rename to poky/meta/recipes-multimedia/alsa/alsa-utils-scripts_1.1.6.bb
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-utils/0001-alsactl-don-t-let-systemd-unit-restore-the-volume-wh.patch b/poky/meta/recipes-multimedia/alsa/alsa-utils/0001-alsactl-don-t-let-systemd-unit-restore-the-volume-wh.patch
deleted file mode 100644
index 907ca5c..0000000
--- a/poky/meta/recipes-multimedia/alsa/alsa-utils/0001-alsactl-don-t-let-systemd-unit-restore-the-volume-wh.patch
+++ /dev/null
@@ -1,56 +0,0 @@
-From b9d41b784657152a4c5683a9458dffab557f0689 Mon Sep 17 00:00:00 2001
-From: Koen Kooi <koen@dominion.thruhere.net>
-Date: Fri, 29 Aug 2014 18:58:56 +0300
-Subject: [PATCH] alsactl: don't let systemd unit restore the volume when
- asound.state is missing
-
-This avoids an error on bootup
-
-Filed as https://bugtrack.alsa-project.org/alsa-bug/view.php?id=5459
-
-Upstream-Status: Pending
-
-Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
-Signed-off-by: Cristian Iorga <cristian.iorga@intel.com>
-
-Rebased on 1.1.0.
-
-Signed-off-by: Tanu Kaskinen <tanuk@iki.fi>
----
- alsactl/Makefile.am             | 7 ++++---
- alsactl/alsa-restore.service.in | 1 +
- 2 files changed, 5 insertions(+), 3 deletions(-)
-
-diff --git a/alsactl/Makefile.am b/alsactl/Makefile.am
-index 90fab9d..190525a 100644
---- a/alsactl/Makefile.am
-+++ b/alsactl/Makefile.am
-@@ -38,9 +38,10 @@ install-data-hook:
- endif
- 
- edit = \
--	$(SED) -r -e 's,@sbindir\@,$(sbindir),g' \
--		  -e 's,@mydatadir\@,$(mydatadir),g' \
--		  -e 's,@daemonswitch\@,$(ALSACTL_DAEMONSWITCH),g' \
-+	$(SED) -e 's,@localstatedir\@,$(localstatedir),g' \
-+	       -e 's,@sbindir\@,$(sbindir),g' \
-+	       -e 's,@mydatadir\@,$(mydatadir),g' \
-+	       -e 's,@daemonswitch\@,$(ALSACTL_DAEMONSWITCH),g' \
- 							< $< > $@ || rm $@
- 
- alsa-state.service: alsa-state.service.in
-diff --git a/alsactl/alsa-restore.service.in b/alsactl/alsa-restore.service.in
-index 80fd5fd..6beb36d 100644
---- a/alsactl/alsa-restore.service.in
-+++ b/alsactl/alsa-restore.service.in
-@@ -7,6 +7,7 @@
- Description=Save/Restore Sound Card State
- ConditionPathExists=!@daemonswitch@
- ConditionPathExistsGlob=/dev/snd/control*
-+ConditionPathExists=@localstatedir@/lib/alsa/asound.state
- 
- [Service]
- Type=oneshot
--- 
-2.14.2
-
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-utils_1.1.5.bb b/poky/meta/recipes-multimedia/alsa/alsa-utils_1.1.5.bb
deleted file mode 100644
index 33215bf..0000000
--- a/poky/meta/recipes-multimedia/alsa/alsa-utils_1.1.5.bb
+++ /dev/null
@@ -1,108 +0,0 @@
-SUMMARY = "ALSA sound utilities"
-HOMEPAGE = "http://www.alsa-project.org"
-BUGTRACKER = "http://alsa-project.org/main/index.php/Bug_Tracking"
-SECTION = "console/utils"
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
-                    file://alsactl/utils.c;beginline=1;endline=20;md5=fe9526b055e246b5558809a5ae25c0b9"
-DEPENDS = "alsa-lib ncurses libsamplerate0"
-
-PACKAGECONFIG ??= "udev"
-
-# alsabat can be built also without fftw support (with reduced functionality).
-# It would be better to always enable alsabat, but provide an option for
-# enabling/disabling fftw. The configure script doesn't support that, however
-# (at least in any obvious way), so for now we only support alsabat with fftw
-# or no alsabat at all.
-PACKAGECONFIG[bat] = "--enable-bat,--disable-bat,fftwf"
-
-PACKAGECONFIG[udev] = "--with-udev-rules-dir=`pkg-config --variable=udevdir udev`/rules.d,--with-udev-rules-dir=/unwanted/rules.d,udev"
-PACKAGECONFIG[manpages] = "--enable-xmlto, --disable-xmlto, xmlto-native docbook-xml-dtd4-native docbook-xsl-stylesheets-native"
-
-SRC_URI = "ftp://ftp.alsa-project.org/pub/utils/alsa-utils-${PV}.tar.bz2 \
-           file://0001-alsactl-don-t-let-systemd-unit-restore-the-volume-wh.patch \
-          "
-
-SRC_URI[md5sum] = "dfe6ea147a5e07a056919591c2f5dac3"
-SRC_URI[sha256sum] = "320bd285e91db6e7fd7db3c9ec6f55b02f35449ff273c7844780ac6a5a3de2e8"
-
-# On build machines with python-docutils (not python3-docutils !!) installed
-# rst2man (not rst2man.py) is detected and compile fails with
-# | make[1]: *** No rule to make target 'alsaucm.1', needed by 'all-am'.  Stop.
-# Avoid this by disabling expicitly
-EXTRA_OECONF = "--disable-rst2man"
-
-inherit autotools gettext pkgconfig manpages
-
-# This are all packages that we need to make. Also, the now empty alsa-utils
-# ipk depends on them.
-
-ALSA_UTILS_PKGS = "\
-             ${@bb.utils.contains('PACKAGECONFIG', 'bat', 'alsa-utils-alsabat', '', d)} \
-             alsa-utils-alsamixer \
-             alsa-utils-alsatplg \
-             alsa-utils-midi \
-             alsa-utils-aplay \
-             alsa-utils-amixer \
-             alsa-utils-aconnect \
-             alsa-utils-iecset \
-             alsa-utils-speakertest \
-             alsa-utils-aseqnet \
-             alsa-utils-aseqdump \
-             alsa-utils-alsactl \
-             alsa-utils-alsaloop \
-             alsa-utils-alsaucm \
-            "
-
-PACKAGES += "${ALSA_UTILS_PKGS}"
-RDEPENDS_${PN} += "${ALSA_UTILS_PKGS}"
-
-FILES_${PN} = ""
-FILES_alsa-utils-alsabat     = "${bindir}/alsabat"
-FILES_alsa-utils-alsatplg    = "${bindir}/alsatplg"
-FILES_alsa-utils-aplay       = "${bindir}/aplay ${bindir}/arecord"
-FILES_alsa-utils-amixer      = "${bindir}/amixer"
-FILES_alsa-utils-alsamixer   = "${bindir}/alsamixer"
-FILES_alsa-utils-speakertest = "${bindir}/speaker-test ${datadir}/sounds/alsa/ ${datadir}/alsa/speaker-test/"
-FILES_alsa-utils-midi        = "${bindir}/aplaymidi ${bindir}/arecordmidi ${bindir}/amidi"
-FILES_alsa-utils-aconnect    = "${bindir}/aconnect"
-FILES_alsa-utils-aseqnet     = "${bindir}/aseqnet"
-FILES_alsa-utils-iecset      = "${bindir}/iecset"
-FILES_alsa-utils-alsactl     = "${sbindir}/alsactl */udev/rules.d */*/udev/rules.d ${systemd_unitdir} ${localstatedir}/lib/alsa ${datadir}/alsa/init/"
-FILES_alsa-utils-aseqdump    = "${bindir}/aseqdump"
-FILES_alsa-utils-alsaloop    = "${bindir}/alsaloop"
-FILES_alsa-utils-alsaucm     = "${bindir}/alsaucm"
-
-SUMMARY_alsa-utils-alsabat      = "Command-line sound tester for ALSA sound card driver"
-SUMMARY_alsa-utils-alsatplg     = "Converts topology text files into binary format for kernel"
-SUMMARY_alsa-utils-aplay        = "Play (and record) sound files using ALSA"
-SUMMARY_alsa-utils-amixer       = "Command-line control for ALSA mixer and settings"
-SUMMARY_alsa-utils-alsamixer    = "ncurses-based control for ALSA mixer and settings"
-SUMMARY_alsa-utils-speakertest  = "ALSA surround speaker test utility"
-SUMMARY_alsa-utils-midi         = "Miscellaneous MIDI utilities for ALSA"
-SUMMARY_alsa-utils-aconnect     = "ALSA sequencer connection manager"
-SUMMARY_alsa-utils-aseqnet      = "Network client/server for ALSA sequencer"
-SUMMARY_alsa-utils-iecset       = "ALSA utility for setting/showing IEC958 (S/PDIF) status bits"
-SUMMARY_alsa-utils-alsactl      = "Saves/restores ALSA-settings in /etc/asound.state"
-SUMMARY_alsa-utils-aseqdump     = "Shows the events received at an ALSA sequencer port"
-SUMMARY_alsa-utils-alsaloop     = "ALSA PCM loopback utility"
-SUMMARY_alsa-utils-alsaucm      = "ALSA Use Case Manager"
-
-RRECOMMENDS_alsa-utils-alsactl = "alsa-states"
-
-ALLOW_EMPTY_alsa-utils = "1"
-
-do_install() {
-	autotools_do_install
-
-	# We don't ship this here because it requires a dependency on bash.
-	# See alsa-utils-scripts_${PV}.bb
-	rm ${D}${sbindir}/alsaconf
-	rm ${D}${sbindir}/alsa-info.sh
-	rm -f ${D}${sbindir}/alsabat-test.sh
-
-	# If udev is disabled, we told configure to install the rules
-	# in /unwanted, so we can remove them now. If udev is enabled,
-	# then /unwanted won't exist and this will have no effect.
-	rm -rf ${D}/unwanted
-}
diff --git a/poky/meta/recipes-multimedia/alsa/alsa-utils_1.1.6.bb b/poky/meta/recipes-multimedia/alsa/alsa-utils_1.1.6.bb
new file mode 100644
index 0000000..b8ba0cb
--- /dev/null
+++ b/poky/meta/recipes-multimedia/alsa/alsa-utils_1.1.6.bb
@@ -0,0 +1,107 @@
+SUMMARY = "ALSA sound utilities"
+HOMEPAGE = "http://www.alsa-project.org"
+BUGTRACKER = "http://alsa-project.org/main/index.php/Bug_Tracking"
+SECTION = "console/utils"
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
+                    file://alsactl/utils.c;beginline=1;endline=20;md5=2ce7f7b6739487fb72c689d46521f958"
+DEPENDS = "alsa-lib ncurses libsamplerate0"
+
+PACKAGECONFIG ??= "udev"
+
+# alsabat can be built also without fftw support (with reduced functionality).
+# It would be better to always enable alsabat, but provide an option for
+# enabling/disabling fftw. The configure script doesn't support that, however
+# (at least in any obvious way), so for now we only support alsabat with fftw
+# or no alsabat at all.
+PACKAGECONFIG[bat] = "--enable-bat,--disable-bat,fftwf"
+
+PACKAGECONFIG[udev] = "--with-udev-rules-dir=`pkg-config --variable=udevdir udev`/rules.d,--with-udev-rules-dir=/unwanted/rules.d,udev"
+PACKAGECONFIG[manpages] = "--enable-xmlto, --disable-xmlto, xmlto-native docbook-xml-dtd4-native docbook-xsl-stylesheets-native"
+
+SRC_URI = "ftp://ftp.alsa-project.org/pub/utils/alsa-utils-${PV}.tar.bz2 \
+          "
+
+SRC_URI[md5sum] = "50ae75567459646b843bed78d916b002"
+SRC_URI[sha256sum] = "155caecc40b2220f686f34ba3655a53e3bdbc0586adb1056733949feaaf7d36e"
+
+# On build machines with python-docutils (not python3-docutils !!) installed
+# rst2man (not rst2man.py) is detected and compile fails with
+# | make[1]: *** No rule to make target 'alsaucm.1', needed by 'all-am'.  Stop.
+# Avoid this by disabling expicitly
+EXTRA_OECONF = "--disable-rst2man"
+
+inherit autotools gettext pkgconfig manpages
+
+# This are all packages that we need to make. Also, the now empty alsa-utils
+# ipk depends on them.
+
+ALSA_UTILS_PKGS = "\
+             ${@bb.utils.contains('PACKAGECONFIG', 'bat', 'alsa-utils-alsabat', '', d)} \
+             alsa-utils-alsamixer \
+             alsa-utils-alsatplg \
+             alsa-utils-midi \
+             alsa-utils-aplay \
+             alsa-utils-amixer \
+             alsa-utils-aconnect \
+             alsa-utils-iecset \
+             alsa-utils-speakertest \
+             alsa-utils-aseqnet \
+             alsa-utils-aseqdump \
+             alsa-utils-alsactl \
+             alsa-utils-alsaloop \
+             alsa-utils-alsaucm \
+            "
+
+PACKAGES += "${ALSA_UTILS_PKGS}"
+RDEPENDS_${PN} += "${ALSA_UTILS_PKGS}"
+
+FILES_${PN} = ""
+FILES_alsa-utils-alsabat     = "${bindir}/alsabat"
+FILES_alsa-utils-alsatplg    = "${bindir}/alsatplg"
+FILES_alsa-utils-aplay       = "${bindir}/aplay ${bindir}/arecord"
+FILES_alsa-utils-amixer      = "${bindir}/amixer"
+FILES_alsa-utils-alsamixer   = "${bindir}/alsamixer"
+FILES_alsa-utils-speakertest = "${bindir}/speaker-test ${datadir}/sounds/alsa/ ${datadir}/alsa/speaker-test/"
+FILES_alsa-utils-midi        = "${bindir}/aplaymidi ${bindir}/arecordmidi ${bindir}/amidi"
+FILES_alsa-utils-aconnect    = "${bindir}/aconnect"
+FILES_alsa-utils-aseqnet     = "${bindir}/aseqnet"
+FILES_alsa-utils-iecset      = "${bindir}/iecset"
+FILES_alsa-utils-alsactl     = "${sbindir}/alsactl */udev/rules.d */*/udev/rules.d ${systemd_unitdir} ${localstatedir}/lib/alsa ${datadir}/alsa/init/"
+FILES_alsa-utils-aseqdump    = "${bindir}/aseqdump"
+FILES_alsa-utils-alsaloop    = "${bindir}/alsaloop"
+FILES_alsa-utils-alsaucm     = "${bindir}/alsaucm"
+
+SUMMARY_alsa-utils-alsabat      = "Command-line sound tester for ALSA sound card driver"
+SUMMARY_alsa-utils-alsatplg     = "Converts topology text files into binary format for kernel"
+SUMMARY_alsa-utils-aplay        = "Play (and record) sound files using ALSA"
+SUMMARY_alsa-utils-amixer       = "Command-line control for ALSA mixer and settings"
+SUMMARY_alsa-utils-alsamixer    = "ncurses-based control for ALSA mixer and settings"
+SUMMARY_alsa-utils-speakertest  = "ALSA surround speaker test utility"
+SUMMARY_alsa-utils-midi         = "Miscellaneous MIDI utilities for ALSA"
+SUMMARY_alsa-utils-aconnect     = "ALSA sequencer connection manager"
+SUMMARY_alsa-utils-aseqnet      = "Network client/server for ALSA sequencer"
+SUMMARY_alsa-utils-iecset       = "ALSA utility for setting/showing IEC958 (S/PDIF) status bits"
+SUMMARY_alsa-utils-alsactl      = "Saves/restores ALSA-settings in /etc/asound.state"
+SUMMARY_alsa-utils-aseqdump     = "Shows the events received at an ALSA sequencer port"
+SUMMARY_alsa-utils-alsaloop     = "ALSA PCM loopback utility"
+SUMMARY_alsa-utils-alsaucm      = "ALSA Use Case Manager"
+
+RRECOMMENDS_alsa-utils-alsactl = "alsa-states"
+
+ALLOW_EMPTY_alsa-utils = "1"
+
+do_install() {
+	autotools_do_install
+
+	# We don't ship this here because it requires a dependency on bash.
+	# See alsa-utils-scripts_${PV}.bb
+	rm ${D}${sbindir}/alsaconf
+	rm ${D}${sbindir}/alsa-info.sh
+	rm -f ${D}${sbindir}/alsabat-test.sh
+
+	# If udev is disabled, we told configure to install the rules
+	# in /unwanted, so we can remove them now. If udev is enabled,
+	# then /unwanted won't exist and this will have no effect.
+	rm -rf ${D}/unwanted
+}
diff --git a/poky/meta/recipes-multimedia/ffmpeg/ffmpeg/CVE-2018-15822.patch b/poky/meta/recipes-multimedia/ffmpeg/ffmpeg/CVE-2018-15822.patch
new file mode 100644
index 0000000..7d5868a
--- /dev/null
+++ b/poky/meta/recipes-multimedia/ffmpeg/ffmpeg/CVE-2018-15822.patch
@@ -0,0 +1,37 @@
+From 6b67d7f05918f7a1ee8fc6ff21355d7e8736aa10 Mon Sep 17 00:00:00 2001
+From: Michael Niedermayer <michael@niedermayer.cc>
+Date: Sat, 28 Jul 2018 15:03:50 +0200
+Subject: [PATCH] avformat/flvenc: Check audio packet size
+
+Fixes: Assertion failure
+Fixes: assert_flvenc.c:941_1.swf
+
+Upstream-Status: Backport [https://github.com/FFmpeg/FFmpeg/commit/6b67d7f05918f7a1ee8fc6ff21355d7e8736aa10]
+CVE: CVE-2018-15822
+
+Found-by: #CHEN HONGXU# <HCHEN017@e.ntu.edu.sg>
+Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
+Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
+---
+ libavformat/flvenc.c | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/libavformat/flvenc.c b/libavformat/flvenc.c
+index 1c552a3e6b..e4863f1fc7 100644
+--- a/libavformat/flvenc.c
++++ b/libavformat/flvenc.c
+@@ -883,6 +883,11 @@ static int flv_write_packet(AVFormatContext *s, AVPacket *pkt)
+     int flags = -1, flags_size, ret;
+     int64_t cur_offset = avio_tell(pb);
+ 
++    if (par->codec_type == AVMEDIA_TYPE_AUDIO && !pkt->size) {
++        av_log(s, AV_LOG_WARNING, "Empty audio Packet\n");
++        return AVERROR(EINVAL);
++    }
++
+     if (par->codec_id == AV_CODEC_ID_VP6F || par->codec_id == AV_CODEC_ID_VP6A ||
+         par->codec_id == AV_CODEC_ID_VP6  || par->codec_id == AV_CODEC_ID_AAC)
+         flags_size = 2;
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-multimedia/ffmpeg/ffmpeg_3.4.2.bb b/poky/meta/recipes-multimedia/ffmpeg/ffmpeg_3.4.2.bb
deleted file mode 100644
index 879cf7f..0000000
--- a/poky/meta/recipes-multimedia/ffmpeg/ffmpeg_3.4.2.bb
+++ /dev/null
@@ -1,151 +0,0 @@
-SUMMARY = "A complete, cross-platform solution to record, convert and stream audio and video."
-DESCRIPTION = "FFmpeg is the leading multimedia framework, able to decode, encode, transcode, \
-               mux, demux, stream, filter and play pretty much anything that humans and machines \
-               have created. It supports the most obscure ancient formats up to the cutting edge."
-HOMEPAGE = "https://www.ffmpeg.org/"
-SECTION = "libs"
-
-LICENSE = "BSD & GPLv2+ & LGPLv2.1+ & MIT"
-LICENSE_${PN} = "GPLv2+"
-LICENSE_libavcodec = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
-LICENSE_libavdevice = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
-LICENSE_libavfilter = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
-LICENSE_libavformat = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
-LICENSE_libavresample = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
-LICENSE_libavutil = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
-LICENSE_libpostproc = "GPLv2+"
-LICENSE_libswresample = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
-LICENSE_libswscale = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
-LICENSE_FLAGS = "commercial"
-
-LIC_FILES_CHKSUM = "file://COPYING.GPLv2;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-                    file://COPYING.GPLv3;md5=d32239bcb673463ab874e80d47fae504 \
-                    file://COPYING.LGPLv2.1;md5=bd7a443320af8c812e4c18d1b79df004 \
-                    file://COPYING.LGPLv3;md5=e6a600fd5e1d9cbde2d983680233ad02"
-
-SRC_URI = "https://www.ffmpeg.org/releases/${BP}.tar.xz \
-           file://mips64_cpu_detection.patch \
-           "
-SRC_URI[md5sum] = "cbf4ead227fcedddf54c86013705a988"
-SRC_URI[sha256sum] = "2b92e9578ef8b3e49eeab229e69305f5f4cbc1fdaa22e927fc7fca18acccd740"
-
-# Build fails when thumb is enabled: https://bugzilla.yoctoproject.org/show_bug.cgi?id=7717
-ARM_INSTRUCTION_SET = "arm"
-
-# Should be API compatible with libav (which was a fork of ffmpeg)
-# libpostproc was previously packaged from a separate recipe
-PROVIDES = "libav libpostproc"
-
-DEPENDS = "alsa-lib zlib libogg yasm-native"
-
-inherit autotools pkgconfig
-
-PACKAGECONFIG ??= "avdevice avfilter avcodec avformat swresample swscale postproc \
-                   bzlib gpl lzma theora x264 \
-                   ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'xv', '', d)}"
-
-# libraries to build in addition to avutil
-PACKAGECONFIG[avdevice] = "--enable-avdevice,--disable-avdevice"
-PACKAGECONFIG[avfilter] = "--enable-avfilter,--disable-avfilter"
-PACKAGECONFIG[avcodec] = "--enable-avcodec,--disable-avcodec"
-PACKAGECONFIG[avformat] = "--enable-avformat,--disable-avformat"
-PACKAGECONFIG[swresample] = "--enable-swresample,--disable-swresample"
-PACKAGECONFIG[swscale] = "--enable-swscale,--disable-swscale"
-PACKAGECONFIG[postproc] = "--enable-postproc,--disable-postproc"
-PACKAGECONFIG[avresample] = "--enable-avresample,--disable-avresample"
-
-# features to support
-PACKAGECONFIG[bzlib] = "--enable-bzlib,--disable-bzlib,bzip2"
-PACKAGECONFIG[gpl] = "--enable-gpl,--disable-gpl"
-PACKAGECONFIG[gsm] = "--enable-libgsm,--disable-libgsm,libgsm"
-PACKAGECONFIG[jack] = "--enable-indev=jack,--disable-indev=jack,jack"
-PACKAGECONFIG[libvorbis] = "--enable-libvorbis,--disable-libvorbis,libvorbis"
-PACKAGECONFIG[lzma] = "--enable-lzma,--disable-lzma,xz"
-PACKAGECONFIG[mp3lame] = "--enable-libmp3lame,--disable-libmp3lame,lame"
-PACKAGECONFIG[openssl] = "--enable-openssl,--disable-openssl,openssl"
-PACKAGECONFIG[sdl2] = "--enable-sdl2,--disable-sdl2,virtual/libsdl2"
-PACKAGECONFIG[speex] = "--enable-libspeex,--disable-libspeex,speex"
-PACKAGECONFIG[theora] = "--enable-libtheora,--disable-libtheora,libtheora"
-PACKAGECONFIG[vaapi] = "--enable-vaapi,--disable-vaapi,libva"
-PACKAGECONFIG[vdpau] = "--enable-vdpau,--disable-vdpau,libvdpau"
-PACKAGECONFIG[vpx] = "--enable-libvpx,--disable-libvpx,libvpx"
-PACKAGECONFIG[x264] = "--enable-libx264,--disable-libx264,x264"
-PACKAGECONFIG[xv] = "--enable-outdev=xv,--disable-outdev=xv,libxv"
-
-# Check codecs that require --enable-nonfree
-USE_NONFREE = "${@bb.utils.contains_any('PACKAGECONFIG', [ 'openssl' ], 'yes', '', d)}"
-
-def cpu(d):
-    for arg in (d.getVar('TUNE_CCARGS') or '').split():
-        if arg.startswith('-mcpu='):
-            return arg[6:]
-    return 'generic'
-
-EXTRA_OECONF = " \
-    --disable-stripping \
-    --enable-pic \
-    --enable-shared \
-    --enable-pthreads \
-    --disable-libxcb \
-    --disable-libxcb-shm \
-    --disable-libxcb-xfixes \
-    --disable-libxcb-shape \
-    ${@bb.utils.contains('USE_NONFREE', 'yes', '--enable-nonfree', '', d)} \
-    \
-    --cross-prefix=${TARGET_PREFIX} \
-    \
-    --ld="${CCLD}" \
-    --cc="${CC}" \
-    --cxx="${CXX}" \
-    --arch=${TARGET_ARCH} \
-    --target-os="linux" \
-    --enable-cross-compile \
-    --extra-cflags="${TARGET_CFLAGS} ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}" \
-    --extra-ldflags="${TARGET_LDFLAGS}" \
-    --sysroot="${STAGING_DIR_TARGET}" \
-    --enable-hardcoded-tables \
-    ${EXTRA_FFCONF} \
-    --libdir=${libdir} \
-    --shlibdir=${libdir} \
-    --datadir=${datadir}/ffmpeg \
-    ${@bb.utils.contains('AVAILTUNES', 'mips32r2', '', '--disable-mipsdsp --disable-mipsdspr2', d)} \
-    --cpu=${@cpu(d)} \
-    --pkg-config=pkg-config \
-"
-
-EXTRA_OECONF_append_linux-gnux32 = " --disable-asm"
-
-do_configure() {
-    ${S}/configure ${EXTRA_OECONF}
-}
-
-PACKAGES =+ "libavcodec \
-             libavdevice \
-             libavfilter \
-             libavformat \
-             libavresample \
-             libavutil \
-             libpostproc \
-             libswresample \
-             libswscale"
-
-FILES_libavcodec = "${libdir}/libavcodec${SOLIBS}"
-FILES_libavdevice = "${libdir}/libavdevice${SOLIBS}"
-FILES_libavfilter = "${libdir}/libavfilter${SOLIBS}"
-FILES_libavformat = "${libdir}/libavformat${SOLIBS}"
-FILES_libavresample = "${libdir}/libavresample${SOLIBS}"
-FILES_libavutil = "${libdir}/libavutil${SOLIBS}"
-FILES_libpostproc = "${libdir}/libpostproc${SOLIBS}"
-FILES_libswresample = "${libdir}/libswresample${SOLIBS}"
-FILES_libswscale = "${libdir}/libswscale${SOLIBS}"
-
-# ffmpeg disables PIC on some platforms (e.g. x86-32)
-INSANE_SKIP_${MLPREFIX}libavcodec = "textrel"
-INSANE_SKIP_${MLPREFIX}libavdevice = "textrel"
-INSANE_SKIP_${MLPREFIX}libavfilter = "textrel"
-INSANE_SKIP_${MLPREFIX}libavformat = "textrel"
-INSANE_SKIP_${MLPREFIX}libavutil = "textrel"
-INSANE_SKIP_${MLPREFIX}libavresample = "textrel"
-INSANE_SKIP_${MLPREFIX}libswscale = "textrel"
-INSANE_SKIP_${MLPREFIX}libswresample = "textrel"
-INSANE_SKIP_${MLPREFIX}libpostproc = "textrel"
diff --git a/poky/meta/recipes-multimedia/ffmpeg/ffmpeg_4.0.2.bb b/poky/meta/recipes-multimedia/ffmpeg/ffmpeg_4.0.2.bb
new file mode 100644
index 0000000..7d1af04
--- /dev/null
+++ b/poky/meta/recipes-multimedia/ffmpeg/ffmpeg_4.0.2.bb
@@ -0,0 +1,158 @@
+SUMMARY = "A complete, cross-platform solution to record, convert and stream audio and video."
+DESCRIPTION = "FFmpeg is the leading multimedia framework, able to decode, encode, transcode, \
+               mux, demux, stream, filter and play pretty much anything that humans and machines \
+               have created. It supports the most obscure ancient formats up to the cutting edge."
+HOMEPAGE = "https://www.ffmpeg.org/"
+SECTION = "libs"
+
+LICENSE = "BSD & GPLv2+ & LGPLv2.1+ & MIT"
+LICENSE_${PN} = "GPLv2+"
+LICENSE_libavcodec = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
+LICENSE_libavdevice = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
+LICENSE_libavfilter = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
+LICENSE_libavformat = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
+LICENSE_libavresample = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
+LICENSE_libavutil = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
+LICENSE_libpostproc = "GPLv2+"
+LICENSE_libswresample = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
+LICENSE_libswscale = "${@bb.utils.contains('PACKAGECONFIG', 'gpl', 'GPLv2+', 'LGPLv2.1+', d)}"
+LICENSE_FLAGS = "commercial"
+
+LIC_FILES_CHKSUM = "file://COPYING.GPLv2;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                    file://COPYING.GPLv3;md5=d32239bcb673463ab874e80d47fae504 \
+                    file://COPYING.LGPLv2.1;md5=bd7a443320af8c812e4c18d1b79df004 \
+                    file://COPYING.LGPLv3;md5=e6a600fd5e1d9cbde2d983680233ad02"
+
+SRC_URI = "https://www.ffmpeg.org/releases/${BP}.tar.xz \
+           file://mips64_cpu_detection.patch \
+           file://CVE-2018-15822.patch \
+           "
+SRC_URI[md5sum] = "ae0bfdf809306a212b4f0e6eb8d1c75e"
+SRC_URI[sha256sum] = "a95c0cc9eb990e94031d2183f2e6e444cc61c99f6f182d1575c433d62afb2f97"
+
+# Build fails when thumb is enabled: https://bugzilla.yoctoproject.org/show_bug.cgi?id=7717
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
+ARM_INSTRUCTION_SET_armv6 = "arm"
+
+# Should be API compatible with libav (which was a fork of ffmpeg)
+# libpostproc was previously packaged from a separate recipe
+PROVIDES = "libav libpostproc"
+
+DEPENDS = "alsa-lib zlib libogg nasm-native"
+
+inherit autotools pkgconfig
+
+PACKAGECONFIG ??= "avdevice avfilter avcodec avformat swresample swscale postproc \
+                   bzlib gpl lzma theora x264 \
+                   ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'xv', '', d)}"
+
+# libraries to build in addition to avutil
+PACKAGECONFIG[avdevice] = "--enable-avdevice,--disable-avdevice"
+PACKAGECONFIG[avfilter] = "--enable-avfilter,--disable-avfilter"
+PACKAGECONFIG[avcodec] = "--enable-avcodec,--disable-avcodec"
+PACKAGECONFIG[avformat] = "--enable-avformat,--disable-avformat"
+PACKAGECONFIG[swresample] = "--enable-swresample,--disable-swresample"
+PACKAGECONFIG[swscale] = "--enable-swscale,--disable-swscale"
+PACKAGECONFIG[postproc] = "--enable-postproc,--disable-postproc"
+PACKAGECONFIG[avresample] = "--enable-avresample,--disable-avresample"
+
+# features to support
+PACKAGECONFIG[bzlib] = "--enable-bzlib,--disable-bzlib,bzip2"
+PACKAGECONFIG[gpl] = "--enable-gpl,--disable-gpl"
+PACKAGECONFIG[gsm] = "--enable-libgsm,--disable-libgsm,libgsm"
+PACKAGECONFIG[jack] = "--enable-indev=jack,--disable-indev=jack,jack"
+PACKAGECONFIG[libvorbis] = "--enable-libvorbis,--disable-libvorbis,libvorbis"
+PACKAGECONFIG[lzma] = "--enable-lzma,--disable-lzma,xz"
+PACKAGECONFIG[mp3lame] = "--enable-libmp3lame,--disable-libmp3lame,lame"
+PACKAGECONFIG[openssl] = "--enable-openssl,--disable-openssl,openssl"
+PACKAGECONFIG[sdl2] = "--enable-sdl2,--disable-sdl2,virtual/libsdl2"
+PACKAGECONFIG[speex] = "--enable-libspeex,--disable-libspeex,speex"
+PACKAGECONFIG[theora] = "--enable-libtheora,--disable-libtheora,libtheora"
+PACKAGECONFIG[vaapi] = "--enable-vaapi,--disable-vaapi,libva"
+PACKAGECONFIG[vdpau] = "--enable-vdpau,--disable-vdpau,libvdpau"
+PACKAGECONFIG[vpx] = "--enable-libvpx,--disable-libvpx,libvpx"
+PACKAGECONFIG[x264] = "--enable-libx264,--disable-libx264,x264"
+PACKAGECONFIG[xv] = "--enable-outdev=xv,--disable-outdev=xv,libxv"
+
+# Check codecs that require --enable-nonfree
+USE_NONFREE = "${@bb.utils.contains_any('PACKAGECONFIG', [ 'openssl' ], 'yes', '', d)}"
+
+def cpu(d):
+    for arg in (d.getVar('TUNE_CCARGS') or '').split():
+        if arg.startswith('-mcpu='):
+            return arg[6:]
+    return 'generic'
+
+EXTRA_OECONF = " \
+    --disable-stripping \
+    --enable-pic \
+    --enable-shared \
+    --enable-pthreads \
+    --disable-libxcb \
+    --disable-libxcb-shm \
+    --disable-libxcb-xfixes \
+    --disable-libxcb-shape \
+    ${@bb.utils.contains('USE_NONFREE', 'yes', '--enable-nonfree', '', d)} \
+    \
+    --cross-prefix=${TARGET_PREFIX} \
+    \
+    --ld="${CCLD}" \
+    --cc="${CC}" \
+    --cxx="${CXX}" \
+    --arch=${TARGET_ARCH} \
+    --target-os="linux" \
+    --enable-cross-compile \
+    --extra-cflags="${TARGET_CFLAGS} ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}" \
+    --extra-ldflags="${TARGET_LDFLAGS}" \
+    --sysroot="${STAGING_DIR_TARGET}" \
+    --enable-hardcoded-tables \
+    ${EXTRA_FFCONF} \
+    --libdir=${libdir} \
+    --shlibdir=${libdir} \
+    --datadir=${datadir}/ffmpeg \
+    ${@bb.utils.contains('AVAILTUNES', 'mips32r2', '', '--disable-mipsdsp --disable-mipsdspr2', d)} \
+    --cpu=${@cpu(d)} \
+    --pkg-config=pkg-config \
+"
+
+EXTRA_OECONF_append_linux-gnux32 = " --disable-asm"
+# gold crashes on x86, another solution is to --disable-asm but thats more hacky
+# ld.gold: internal error in relocate_section, at ../../gold/i386.cc:3684
+
+LDFLAGS_append_x86 = "${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-gold', ' -fuse-ld=bfd ', '', d)}"
+
+do_configure() {
+    ${S}/configure ${EXTRA_OECONF}
+}
+
+PACKAGES =+ "libavcodec \
+             libavdevice \
+             libavfilter \
+             libavformat \
+             libavresample \
+             libavutil \
+             libpostproc \
+             libswresample \
+             libswscale"
+
+FILES_libavcodec = "${libdir}/libavcodec${SOLIBS}"
+FILES_libavdevice = "${libdir}/libavdevice${SOLIBS}"
+FILES_libavfilter = "${libdir}/libavfilter${SOLIBS}"
+FILES_libavformat = "${libdir}/libavformat${SOLIBS}"
+FILES_libavresample = "${libdir}/libavresample${SOLIBS}"
+FILES_libavutil = "${libdir}/libavutil${SOLIBS}"
+FILES_libpostproc = "${libdir}/libpostproc${SOLIBS}"
+FILES_libswresample = "${libdir}/libswresample${SOLIBS}"
+FILES_libswscale = "${libdir}/libswscale${SOLIBS}"
+
+# ffmpeg disables PIC on some platforms (e.g. x86-32)
+INSANE_SKIP_${MLPREFIX}libavcodec = "textrel"
+INSANE_SKIP_${MLPREFIX}libavdevice = "textrel"
+INSANE_SKIP_${MLPREFIX}libavfilter = "textrel"
+INSANE_SKIP_${MLPREFIX}libavformat = "textrel"
+INSANE_SKIP_${MLPREFIX}libavutil = "textrel"
+INSANE_SKIP_${MLPREFIX}libavresample = "textrel"
+INSANE_SKIP_${MLPREFIX}libswscale = "textrel"
+INSANE_SKIP_${MLPREFIX}libswresample = "textrel"
+INSANE_SKIP_${MLPREFIX}libpostproc = "textrel"
diff --git a/poky/meta/recipes-multimedia/flac/files/CVE-2017-6888.patch b/poky/meta/recipes-multimedia/flac/files/CVE-2017-6888.patch
deleted file mode 100644
index 389ab96..0000000
--- a/poky/meta/recipes-multimedia/flac/files/CVE-2017-6888.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 4f47b63e9c971e6391590caf00a0f2a5ed612e67 Mon Sep 17 00:00:00 2001
-From: Erik de Castro Lopo <erikd@mega-nerd.com>
-Date: Sat, 8 Apr 2017 18:34:49 +1000
-Subject: [PATCH] stream_decoder.c: Fix a memory leak
-
-Leak reported by Secunia Research.
-CVE: CVE-2017-6888
-Upstream-Status: Backport [https://git.xiph.org/?p=flac.git;a=commitdiff;h=4f47b63e9c971e6391590caf00a0f2a5ed612e67]
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- src/libFLAC/stream_decoder.c | 3 +++
- 1 file changed, 3 insertions(+)
-
-diff --git a/src/libFLAC/stream_decoder.c b/src/libFLAC/stream_decoder.c
-index 14d5fe7f..a5527511 100644
---- a/src/libFLAC/stream_decoder.c
-+++ b/src/libFLAC/stream_decoder.c
-@@ -1753,6 +1753,9 @@ FLAC__bool read_metadata_vorbiscomment_(FLAC__StreamDecoder *decoder, FLAC__Stre
- 					}
- 					memset (obj->comments[i].entry, 0, obj->comments[i].length) ;
- 					if (!FLAC__bitreader_read_byte_block_aligned_no_crc(decoder->private_->input, obj->comments[i].entry, obj->comments[i].length)) {
-+						/* Current i-th entry is bad, so we delete it. */
-+						free (obj->comments[i].entry) ;
-+						obj->comments[i].entry = NULL ;
- 						obj->num_comments = i;
- 						goto skip;
- 					}
--- 
-2.13.3
-
diff --git a/poky/meta/recipes-multimedia/flac/flac/CVE-2017-6888.patch b/poky/meta/recipes-multimedia/flac/flac/CVE-2017-6888.patch
new file mode 100644
index 0000000..f017916
--- /dev/null
+++ b/poky/meta/recipes-multimedia/flac/flac/CVE-2017-6888.patch
@@ -0,0 +1,37 @@
+From 43ecb6431077ff54e9df27f71737e6e96d6c039f Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Tue, 21 Aug 2018 14:46:43 +0800
+Subject: [PATCH] From 5f47b63e9c971e6391590caf00a0f2a5ed612e67 Mon Sep 17
+ 00:00:00 2001 From: Erik de Castro Lopo <erikd@mega-nerd.com> Date: Sat, 8
+ Apr 2017 18:34:49 +1000 Subject: [PATCH] stream_decoder.c: Fix a memory leak
+
+Leak reported by Secunia Research.
+
+Upstream-Status: Backport[https://git.xiph.org/?p=flac.git;a=commit;
+                 h=4f47b63e9c971e6391590caf00a0f2a5ed612e67]
+
+Update patch to version 1.3.2
+CVE: CVE-2017-6888
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ src/libFLAC/stream_decoder.c | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/src/libFLAC/stream_decoder.c b/src/libFLAC/stream_decoder.c
+index d364b0c..ebf93da 100644
+--- a/src/libFLAC/stream_decoder.c
++++ b/src/libFLAC/stream_decoder.c
+@@ -1759,6 +1759,9 @@ FLAC__bool read_metadata_vorbiscomment_(FLAC__StreamDecoder *decoder, FLAC__Stre
+ 					}
+ 					memset (obj->comments[i].entry, 0, obj->comments[i].length) ;
+ 					if (!FLAC__bitreader_read_byte_block_aligned_no_crc(decoder->private_->input, obj->comments[i].entry, obj->comments[i].length)) {
++						/* Current i-th entry is bad, so we delete it. */\
++						free (obj->comments[i].entry) ;
++						obj->comments[i].entry = NULL ;						
+ 						obj->num_comments = i;
+ 						goto skip;
+ 					}
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-multimedia/flac/flac_1.3.2.bb b/poky/meta/recipes-multimedia/flac/flac_1.3.2.bb
index 028a429..92ef897 100644
--- a/poky/meta/recipes-multimedia/flac/flac_1.3.2.bb
+++ b/poky/meta/recipes-multimedia/flac/flac_1.3.2.bb
@@ -15,7 +15,8 @@
 DEPENDS = "libogg"
 
 SRC_URI = "http://downloads.xiph.org/releases/flac/${BP}.tar.xz \
-           file://CVE-2017-6888.patch"
+           file://CVE-2017-6888.patch "
+
 
 SRC_URI[md5sum] = "454f1bfa3f93cc708098d7890d0499bd"
 SRC_URI[sha256sum] = "91cfc3ed61dc40f47f050a109b08610667d73477af6ef36dcad31c31a4a8d53f"
diff --git a/poky/meta/recipes-multimedia/gstreamer/files/0001-connect-has-a-different-signature-on-musl.patch b/poky/meta/recipes-multimedia/gstreamer/files/0001-connect-has-a-different-signature-on-musl.patch
new file mode 100644
index 0000000..a0d215c
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/files/0001-connect-has-a-different-signature-on-musl.patch
@@ -0,0 +1,38 @@
+From 0bd8004d8dddc486d3961a5316d24e8f2645e4c8 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 9 Sep 2018 17:38:10 -0700
+Subject: [PATCH] connect has a different signature on musl
+
+On linux when not using glibc and using musl for C library, connect
+API has a different signature, this patch fixes this so it can compile
+on musl, the functionality should remain same as it is immediately
+typcasted to struct sockaddr_in* type inside the function before use
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ plugins/fault_injection/socket_interposer.c | 7 ++++++-
+ 1 file changed, 6 insertions(+), 1 deletion(-)
+
+diff --git a/plugins/fault_injection/socket_interposer.c b/plugins/fault_injection/socket_interposer.c
+index 53c1ebb..ad7adf8 100644
+--- a/plugins/fault_injection/socket_interposer.c
++++ b/plugins/fault_injection/socket_interposer.c
+@@ -100,10 +100,15 @@ socket_interposer_set_callback (struct sockaddr_in *addrin,
+ }
+ 
+ int
+-connect (int socket, const struct sockaddr_in *addrin, socklen_t address_len)
++#if defined(__linux__) && !defined(__GLIBC__)
++connect (int socket, const struct sockaddr *addr, socklen_t address_len)
++#else
++connect (int socket, const struct sockaddr_in *addr, socklen_t address_len)
++#endif
+ {
+   size_t i;
+   int override_errno = 0;
++  struct sockaddr_in* addrin = (struct sockaddr_in*)addr;
+   typedef ssize_t (*real_connect_fn) (int, const struct sockaddr_in *,
+       socklen_t);
+   static real_connect_fn real_connect = 0;
diff --git a/poky/meta/recipes-multimedia/gstreamer/files/0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch b/poky/meta/recipes-multimedia/gstreamer/files/0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch
index 2cab87f..1b7f115 100644
--- a/poky/meta/recipes-multimedia/gstreamer/files/0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch
+++ b/poky/meta/recipes-multimedia/gstreamer/files/0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch
@@ -1,4 +1,4 @@
-From 90916f96262fa7b27a0a99788c69f9fd6df11000 Mon Sep 17 00:00:00 2001
+From 2b0436f9a07773fae8c74df902d7024e8bfc3512 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Tue, 24 Nov 2015 16:46:27 +0200
 Subject: [PATCH] introspection.m4: prefix pkgconfig paths with
@@ -10,12 +10,13 @@
 
 Upstream-Status: Pending [review on oe-core list]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
 ---
- common/m4/introspection.m4 | 12 ++++++------
- 1 file changed, 6 insertions(+), 6 deletions(-)
+ common/m4/introspection.m4 | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
 
 diff --git a/common/m4/introspection.m4 b/common/m4/introspection.m4
-index 162be57..217a6ae 100644
+index 162be57..933f979 100644
 --- a/common/m4/introspection.m4
 +++ b/common/m4/introspection.m4
 @@ -54,14 +54,14 @@ m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL],
@@ -37,6 +38,3 @@
         INTROSPECTION_INIT="extern void gst_init(gint*,gchar**); gst_init(NULL,NULL);"
      fi
      AC_SUBST(INTROSPECTION_SCANNER)
--- 
-2.6.2
-
diff --git a/poky/meta/recipes-multimedia/gstreamer/files/add-a-target-to-compile-tests.patch b/poky/meta/recipes-multimedia/gstreamer/files/add-a-target-to-compile-tests.patch
new file mode 100644
index 0000000..d02d869
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/files/add-a-target-to-compile-tests.patch
@@ -0,0 +1,69 @@
+From d61414bc17cf2df019510c2908048c4cabf5cf09 Mon Sep 17 00:00:00 2001
+From: Anuj Mittal <anuj.mittal@intel.com>
+Date: Tue, 27 Feb 2018 09:27:01 +0800
+Subject: [PATCH] add targets for test installation
+
+Targets to make sure tests can be installed and then run on
+the target.
+
+Upstream-Status: Inappropriate [specific to oe setup]
+
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+
+---
+ tests/check/Makefile.am | 27 ++++++++++++++++++++-------
+ 1 file changed, 20 insertions(+), 7 deletions(-)
+
+diff --git a/tests/check/Makefile.am b/tests/check/Makefile.am
+index 13b916d..a66786d 100644
+--- a/tests/check/Makefile.am
++++ b/tests/check/Makefile.am
+@@ -8,11 +8,7 @@ REGISTRY_ENVIRONMENT = \
+ 	GST_REGISTRY=$(CHECK_REGISTRY)
+ 
+ AM_TESTS_ENVIRONMENT += \
+-        GST_STATE_IGNORE_ELEMENTS="$(STATE_IGNORE_ELEMENTS)"	\
+-        $(REGISTRY_ENVIRONMENT)					\
+-        GST_PLUGIN_SCANNER_1_0=$(top_builddir)/libs/gst/helpers/gst-plugin-scanner \
+-        GST_PLUGIN_SYSTEM_PATH_1_0=					\
+-        GST_PLUGIN_PATH_1_0=$(top_builddir)/plugins
++        GST_STATE_IGNORE_ELEMENTS="$(STATE_IGNORE_ELEMENTS)"
+ 
+ plugindir = $(libdir)/gstreamer-@GST_API_VERSION@
+ 
+@@ -178,6 +174,23 @@ noinst_PROGRAMS =
+ 
+ TESTS = $(check_PROGRAMS)
+ 
++install-ptest: $(TESTS)
++	@$(INSTALL) -d $(DESTDIR)
++	@for dir in `find -maxdepth 1 -type d`; do \
++		if [ -x $$dir/.libs ]; then \
++			$(INSTALL) -d $(DESTDIR)/$$dir; \
++			$(INSTALL_PROGRAM) $$dir/.libs/* $(DESTDIR)/$$dir/; \
++		fi \
++	done
++
++runtests:
++	@for b in $(TESTS); do \
++		if [ -x $$b ]; then \
++			$(AM_TESTS_ENVIRONMENT) $(SHELL) test-driver --test-name "$$b" \
++			--log-file $$b.log --trs-file $$b.trs $$b; \
++		fi \
++	done
++
+ noinst_HEADERS = \
+ 	gst/capslist.h \
+ 	gst/struct_arm.h \
+@@ -221,9 +234,9 @@ gst_gstprintf_LDADD = \
+ 	$(LDADD)
+ 
+ elements_fdsrc_CFLAGS=$(GST_OBJ_CFLAGS) $(AM_CFLAGS) \
+-	-DTESTFILE=\"$(top_srcdir)/configure.ac\"
++	-DTESTFILE=\"Makefile\"
+ elements_filesrc_CFLAGS=$(GST_OBJ_CFLAGS) $(AM_CFLAGS) \
+-	-DTESTFILE=\"$(top_srcdir)/configure.ac\"
++	-DTESTFILE=\"Makefile\"
+ 
+ libs_controller_LDADD = \
+ 	$(top_builddir)/libs/gst/controller/libgstcontroller-@GST_API_VERSION@.la \
diff --git a/poky/meta/recipes-multimedia/gstreamer/files/run-ptest b/poky/meta/recipes-multimedia/gstreamer/files/run-ptest
new file mode 100644
index 0000000..473d0b6
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/files/run-ptest
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+make -k runtests
diff --git a/poky/meta/recipes-multimedia/gstreamer/gst-validate_1.12.4.bb b/poky/meta/recipes-multimedia/gstreamer/gst-validate_1.12.4.bb
deleted file mode 100644
index 0f2585a..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gst-validate_1.12.4.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-SUMMARY = "Gstreamer validation tool"
-DESCRIPTION = "A Tool to test GStreamer components"
-HOMEPAGE = "https://gstreamer.freedesktop.org/releases/gst-validate/1.12.3.html"
-SECTION = "multimedia"
-
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=a6f89e2100d9b6cdffcea4f398e37343"
-
-SRC_URI = "https://gstreamer.freedesktop.org/src/${BPN}/${BP}.tar.xz"
-SRC_URI[md5sum] = "bc074d49677081f9c27de11a09165746"
-SRC_URI[sha256sum] = "f9da9dfe6e5d6f5ba3b38c5752b42d3f927715904942b405c2924d3cb77afba1"
-
-DEPENDS = "json-glib glib-2.0 gstreamer1.0 gstreamer1.0-plugins-base"
-RRECOMMENDS_${PN} = "git"
-
-FILES_${PN} += "${datadir}/gstreamer-1.0/* ${libdir}/gst-validate-launcher/* ${libdir}/gstreamer-1.0/*"
-
-inherit pkgconfig gettext autotools gobject-introspection gtk-doc upstream-version-is-even
-
-# With gtk-doc enabled this recipe fails to build, so forcibly disable it:
-# WORKDIR/build/docs/validate/gst-validate-scan: line 117:
-# WORKDIR/build/docs/validate/.libs/lt-gst-validate-scan: No such file or directory
-GTKDOC_ENABLED = "False"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gst-validate_1.14.2.bb b/poky/meta/recipes-multimedia/gstreamer/gst-validate_1.14.2.bb
new file mode 100644
index 0000000..f4438dc
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gst-validate_1.14.2.bb
@@ -0,0 +1,25 @@
+SUMMARY = "Gstreamer validation tool"
+DESCRIPTION = "A Tool to test GStreamer components"
+HOMEPAGE = "https://gstreamer.freedesktop.org/releases/gst-validate/1.12.3.html"
+SECTION = "multimedia"
+
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=a6f89e2100d9b6cdffcea4f398e37343"
+
+SRC_URI = "https://gstreamer.freedesktop.org/src/${BPN}/${BP}.tar.xz \
+           file://0001-connect-has-a-different-signature-on-musl.patch \
+           "
+SRC_URI[md5sum] = "f334102b0e706008505d00f7f5b5e023"
+SRC_URI[sha256sum] = "ea9e423e5470ef85ef8a0aea1714e7abfc49deb2ed282057367484cdeba6f19f"
+
+DEPENDS = "json-glib glib-2.0 glib-2.0-native gstreamer1.0 gstreamer1.0-plugins-base"
+RRECOMMENDS_${PN} = "git"
+
+FILES_${PN} += "${datadir}/gstreamer-1.0/* ${libdir}/gst-validate-launcher/* ${libdir}/gstreamer-1.0/*"
+
+inherit pkgconfig gettext autotools gobject-introspection gtk-doc upstream-version-is-even
+
+# With gtk-doc enabled this recipe fails to build, so forcibly disable it:
+# WORKDIR/build/docs/validate/gst-validate-scan: line 117:
+# WORKDIR/build/docs/validate/.libs/lt-gst-validate-scan: No such file or directory
+GTKDOC_ENABLED = "False"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-libav.inc b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-libav.inc
deleted file mode 100644
index c228306..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-libav.inc
+++ /dev/null
@@ -1,51 +0,0 @@
-SUMMARY = "Libav-based GStreamer 1.x plugin"
-HOMEPAGE = "http://gstreamer.freedesktop.org/"
-SECTION = "multimedia"
-
-LICENSE = "GPLv2+ & LGPLv2+ & ( (GPLv2+ & LGPLv2.1+) | (GPLv3+ & LGPLv3+) )"
-LICENSE_FLAGS = "commercial"
-
-DEPENDS = "gstreamer1.0 gstreamer1.0-plugins-base zlib bzip2 xz"
-
-inherit autotools pkgconfig upstream-version-is-even gtk-doc
-
-# CAUTION: Using the system libav is not recommended. Since the libav API is changing all the time,
-# compilation errors (and other, more subtle bugs) can happen. It is usually better to rely on the
-# libav copy included in the gst-libav package.
-PACKAGECONFIG ??= "orc yasm"
-
-PACKAGECONFIG[gpl] = "--enable-gpl,--disable-gpl,"
-PACKAGECONFIG[libav] = "--with-system-libav,,libav"
-PACKAGECONFIG[orc] = "--enable-orc,--disable-orc,orc"
-PACKAGECONFIG[yasm] = "--enable-yasm,--disable-yasm,yasm-native"
-PACKAGECONFIG[valgrind] = "--enable-valgrind,--disable-valgrind,valgrind"
-
-GSTREAMER_1_0_DEBUG ?= "--disable-debug"
-
-LIBAV_EXTRA_CONFIGURE = "--with-libav-extra-configure"
-
-LIBAV_EXTRA_CONFIGURE_COMMON_ARG = "--target-os=linux \
-  --cc='${CC}' --as='${CC}' --ld='${CC}' --nm='${NM}' --ar='${AR}' \
-  --ranlib='${RANLIB}' \
-  ${GSTREAMER_1_0_DEBUG} \
-  --cross-prefix='${HOST_PREFIX}'"
-
-# Disable assembly optimizations for X32, as this libav lacks the support
-PACKAGECONFIG_remove_linux-gnux32 = "yasm"
-LIBAV_EXTRA_CONFIGURE_COMMON_ARG_append_linux-gnux32 = " --disable-asm"
-
-LIBAV_EXTRA_CONFIGURE_COMMON = \
-'${LIBAV_EXTRA_CONFIGURE}="${LIBAV_EXTRA_CONFIGURE_COMMON_ARG}"'
-
-EXTRA_OECONF = "${LIBAV_EXTRA_CONFIGURE_COMMON}"
-
-FILES_${PN} += "${libdir}/gstreamer-1.0/*.so"
-FILES_${PN}-dev += "${libdir}/gstreamer-1.0/*.la"
-FILES_${PN}-staticdev += "${libdir}/gstreamer-1.0/*.a"
-
-# http://errors.yoctoproject.org/Errors/Details/20493/
-ARM_INSTRUCTION_SET_armv4 = "arm"
-ARM_INSTRUCTION_SET_armv5 = "arm"
-
-# ffmpeg/libav disables PIC on some platforms (e.g. x86-32)
-INSANE_SKIP_${PN} = "textrel"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-libav/0001-fix-host-contamination.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-libav/0001-fix-host-contamination.patch
new file mode 100644
index 0000000..120c079
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-libav/0001-fix-host-contamination.patch
@@ -0,0 +1,36 @@
+From c1700f867f876ee33c130a8e28b688e2b1d89663 Mon Sep 17 00:00:00 2001
+From: Anuj Mittal <anuj.mittal@intel.com>
+Date: Wed, 11 Apr 2018 17:14:55 +0800
+Subject: [PATCH] Prevent host contamination
+
+Remove reference to host $(libdir) from .la files.
+
+Upstream-Status: Inappropriate [cross-compile specific]
+
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+---
+ gst-libs/ext/Makefile.am | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/gst-libs/ext/Makefile.am b/gst-libs/ext/Makefile.am
+index 6cdc048..a19d255 100644
+--- a/gst-libs/ext/Makefile.am
++++ b/gst-libs/ext/Makefile.am
+@@ -49,7 +49,7 @@ echo "  GEN      $1.la" && \
+  echo "library_names=''" && \
+  echo "old_library='$1.a'" && \
+  echo "inherited_linker_flags=''" && \
+- echo "dependency_libs=' -L$(libdir) $(if $2,$(foreach dep,$2,$(abs_builddir)/$(dep).la)) $(call find_library_la,$3 $(LIBM),$(LDFLAGS)) '" && \
++ echo "dependency_libs=' -L $(if $2,$(foreach dep,$2,$(abs_builddir)/$(dep).la)) $(call find_library_la,$3 $(LIBM),$(LDFLAGS)) '" && \
+  echo "weak_library_names=''" &&  \
+  echo "current=" && \
+  echo "age=" && \
+@@ -58,7 +58,7 @@ echo "  GEN      $1.la" && \
+  echo "shouldnotlink=no" && \
+  echo "dlopen=''" && \
+  echo "dlpreopen=''" && \
+- echo "libdir='$(libdir)'") > $1.la
++ echo "libdir=''") > $1.la
+ endef
+ 
+ libavutil.la:
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-libav/0001-hevcpred_msa.c-Fix-build-by-Including-libavcodec-hev.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-libav/0001-hevcpred_msa.c-Fix-build-by-Including-libavcodec-hev.patch
deleted file mode 100644
index afbfc84..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-libav/0001-hevcpred_msa.c-Fix-build-by-Including-libavcodec-hev.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From b5226c096a0b7049874858e94a59d43e10ba3fd2 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 21 Sep 2017 10:22:56 -0700
-Subject: [PATCH] hevcpred_msa.c: Fix build by Including libavcodec/hevcdec.h
-
-src/libavcodec/mips/hevcpred_msa.c:1913:32: error: unknown type name 'HEVCContext'; did you mean 'HEVCPredContext'?
- void ff_intra_pred_8_16x16_msa(HEVCContext *s, int x0, int y0, int c_idx)
-                                ^~~~~~~~~~~
-                                HEVCPredContext
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Pending
-
- gst-libs/ext/libav/libavcodec/mips/hevcpred_msa.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/gst-libs/ext/libav/libavcodec/mips/hevcpred_msa.c b/gst-libs/ext/libav/libavcodec/mips/hevcpred_msa.c
-index 6a3b281..963c64c 100644
---- a/gst-libs/ext/libav/libavcodec/mips/hevcpred_msa.c
-+++ b/gst-libs/ext/libav/libavcodec/mips/hevcpred_msa.c
-@@ -18,7 +18,7 @@
-  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
-  */
- 
--#include "libavcodec/hevc.h"
-+#include "libavcodec/hevcdec.h"
- #include "libavutil/mips/generic_macros_msa.h"
- #include "hevcpred_mips.h"
- 
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-libav_1.12.4.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-libav_1.12.4.bb
deleted file mode 100644
index af547ba..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-libav_1.12.4.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-require gstreamer1.0-libav.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-                    file://COPYING.LIB;md5=6762ed442b3822387a51c92d928ead0d \
-                    file://ext/libav/gstav.h;beginline=1;endline=18;md5=a752c35267d8276fd9ca3db6994fca9c \
-                    file://gst-libs/ext/libav/COPYING.GPLv2;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-                    file://gst-libs/ext/libav/COPYING.GPLv3;md5=d32239bcb673463ab874e80d47fae504 \
-                    file://gst-libs/ext/libav/COPYING.LGPLv2.1;md5=bd7a443320af8c812e4c18d1b79df004 \
-                    file://gst-libs/ext/libav/COPYING.LGPLv3;md5=e6a600fd5e1d9cbde2d983680233ad02"
-
-SRC_URI = "http://gstreamer.freedesktop.org/src/gst-libav/gst-libav-${PV}.tar.xz \
-           file://0001-Disable-yasm-for-libav-when-disable-yasm.patch \
-           file://workaround-to-build-gst-libav-for-i586-with-gcc.patch \
-           file://mips64_cpu_detection.patch \
-           file://0001-configure-check-for-armv7ve-variant.patch \
-           file://0001-hevcpred_msa.c-Fix-build-by-Including-libavcodec-hev.patch \
-           "
-SRC_URI[md5sum] = "8a851bf2e475e90a3fdac9506e3e4dbd"
-SRC_URI[sha256sum] = "2a56aa5d2d8cd912f2bce17f174713d2c417ca298f1f9c28ee66d4aa1e1d9e62"
-
-S = "${WORKDIR}/gst-libav-${PV}"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-libav_1.14.2.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-libav_1.14.2.bb
new file mode 100644
index 0000000..718db17
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-libav_1.14.2.bb
@@ -0,0 +1,70 @@
+SUMMARY = "Libav-based GStreamer 1.x plugin"
+HOMEPAGE = "http://gstreamer.freedesktop.org/"
+SECTION = "multimedia"
+
+LICENSE = "GPLv2+ & LGPLv2+ & ( (GPLv2+ & LGPLv2.1+) | (GPLv3+ & LGPLv3+) )"
+LICENSE_FLAGS = "commercial"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                    file://COPYING.LIB;md5=6762ed442b3822387a51c92d928ead0d \
+                    file://ext/libav/gstav.h;beginline=1;endline=18;md5=a752c35267d8276fd9ca3db6994fca9c \
+                    file://gst-libs/ext/libav/COPYING.GPLv2;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                    file://gst-libs/ext/libav/COPYING.GPLv3;md5=d32239bcb673463ab874e80d47fae504 \
+                    file://gst-libs/ext/libav/COPYING.LGPLv2.1;md5=bd7a443320af8c812e4c18d1b79df004 \
+                    file://gst-libs/ext/libav/COPYING.LGPLv3;md5=e6a600fd5e1d9cbde2d983680233ad02"
+
+SRC_URI = "http://gstreamer.freedesktop.org/src/gst-libav/gst-libav-${PV}.tar.xz \
+           file://0001-Disable-yasm-for-libav-when-disable-yasm.patch \
+           file://workaround-to-build-gst-libav-for-i586-with-gcc.patch \
+           file://mips64_cpu_detection.patch \
+           file://0001-configure-check-for-armv7ve-variant.patch \
+           file://0001-fix-host-contamination.patch \
+           "
+SRC_URI[md5sum] = "da3d4655268bc6766a261065ca737590"
+SRC_URI[sha256sum] = "8a351c39c5cfc2bbd31ca434ec4a290a730a26efbdea962fdd8306dce5c576de"
+
+S = "${WORKDIR}/gst-libav-${PV}"
+
+DEPENDS = "gstreamer1.0 gstreamer1.0-plugins-base zlib bzip2 xz"
+
+inherit autotools pkgconfig upstream-version-is-even gtk-doc
+
+# CAUTION: Using the system libav is not recommended. Since the libav API is changing all the time,
+# compilation errors (and other, more subtle bugs) can happen. It is usually better to rely on the
+# libav copy included in the gst-libav package.
+PACKAGECONFIG ??= "orc yasm"
+
+PACKAGECONFIG[gpl] = "--enable-gpl,--disable-gpl,"
+PACKAGECONFIG[libav] = "--with-system-libav,,libav"
+PACKAGECONFIG[orc] = "--enable-orc,--disable-orc,orc"
+PACKAGECONFIG[yasm] = "--enable-yasm,--disable-yasm,nasm-native"
+PACKAGECONFIG[valgrind] = "--enable-valgrind,--disable-valgrind,valgrind"
+
+GSTREAMER_1_0_DEBUG ?= "--disable-debug"
+
+LIBAV_EXTRA_CONFIGURE = "--with-libav-extra-configure"
+
+LIBAV_EXTRA_CONFIGURE_COMMON_ARG = "--target-os=linux \
+  --cc='${CC}' --as='${CC}' --ld='${CC}' --nm='${NM}' --ar='${AR}' \
+  --ranlib='${RANLIB}' \
+  ${GSTREAMER_1_0_DEBUG} \
+  --cross-prefix='${HOST_PREFIX}'"
+
+# Disable assembly optimizations for X32, as this libav lacks the support
+PACKAGECONFIG_remove_linux-gnux32 = "yasm"
+LIBAV_EXTRA_CONFIGURE_COMMON_ARG_append_linux-gnux32 = " --disable-asm"
+
+LIBAV_EXTRA_CONFIGURE_COMMON = \
+'${LIBAV_EXTRA_CONFIGURE}="${LIBAV_EXTRA_CONFIGURE_COMMON_ARG}"'
+
+EXTRA_OECONF = "${LIBAV_EXTRA_CONFIGURE_COMMON}"
+
+FILES_${PN} += "${libdir}/gstreamer-1.0/*.so"
+FILES_${PN}-dev += "${libdir}/gstreamer-1.0/*.la"
+FILES_${PN}-staticdev += "${libdir}/gstreamer-1.0/*.a"
+
+# http://errors.yoctoproject.org/Errors/Details/20493/
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
+
+# ffmpeg/libav disables PIC on some platforms (e.g. x86-32)
+INSANE_SKIP_${PN} = "textrel"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-omx.inc b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-omx.inc
deleted file mode 100644
index 5d92351..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-omx.inc
+++ /dev/null
@@ -1,49 +0,0 @@
-SUMMARY = "OpenMAX IL plugins for GStreamer"
-HOMEPAGE = "http://gstreamer.freedesktop.org/"
-SECTION = "multimedia"
-
-LICENSE = "LGPLv2.1"
-LICENSE_FLAGS = "commercial"
-
-DEPENDS = "gstreamer1.0 gstreamer1.0-plugins-base gstreamer1.0-plugins-bad"
-
-inherit autotools pkgconfig gettext gtk-doc upstream-version-is-even
-
-acpaths = "-I ${S}/common/m4 -I ${S}/m4"
-
-
-GSTREAMER_1_0_OMX_TARGET ?= "bellagio"
-GSTREAMER_1_0_OMX_CORE_NAME ?= "${libdir}/libomxil-bellagio.so.0"
-
-EXTRA_OECONF += "--disable-valgrind --with-omx-target=${GSTREAMER_1_0_OMX_TARGET}"
-
-python __anonymous () {
-    omx_target = d.getVar("GSTREAMER_1_0_OMX_TARGET")
-    if omx_target in ['generic', 'bellagio']:
-        # Bellagio headers are incomplete (they are missing the OMX_VERSION_MAJOR,#
-        # OMX_VERSION_MINOR, OMX_VERSION_REVISION, and OMX_VERSION_STEP macros);
-        # appending a directory path to gst-omx' internal OpenMAX IL headers fixes this
-        d.appendVar("CFLAGS", " -I${S}/omx/openmax")
-    elif omx_target == "rpi":
-        # Dedicated Raspberry Pi OpenMAX IL support makes this package machine specific
-        d.setVar("PACKAGE_ARCH", d.getVar("MACHINE_ARCH"))
-}
-
-delete_pkg_m4_file() {
-    # Delete m4 files which we provide patched versions of but will be ignored
-    # if these exist
-	rm -f "${S}/common/m4/pkg.m4"
-	rm -f "${S}/common/m4/gtk-doc.m4"
-}
-do_configure[prefuncs] += "delete_pkg_m4_file"
-
-set_omx_core_name() {
-	sed -i -e "s;^core-name=.*;core-name=${GSTREAMER_1_0_OMX_CORE_NAME};" "${D}${sysconfdir}/xdg/gstomx.conf"
-}
-do_install[postfuncs] += " set_omx_core_name "
-
-FILES_${PN} += "${libdir}/gstreamer-1.0/*.so"
-FILES_${PN}-dev += "${libdir}/gstreamer-1.0/*.la"
-FILES_${PN}-staticdev += "${libdir}/gstreamer-1.0/*.a"
-
-RDEPENDS_${PN} = "libomxil"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-omx_1.12.4.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-omx_1.12.4.bb
deleted file mode 100644
index 7f7eae3..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-omx_1.12.4.bb
+++ /dev/null
@@ -1,11 +0,0 @@
-include gstreamer1.0-omx.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c \
-                    file://omx/gstomx.h;beginline=1;endline=21;md5=5c8e1fca32704488e76d2ba9ddfa935f"
-
-SRC_URI = "http://gstreamer.freedesktop.org/src/gst-omx/gst-omx-${PV}.tar.xz"
-
-SRC_URI[md5sum] = "eb8d5ae3b69cfeed9dc77c592106247e"
-SRC_URI[sha256sum] = "a025fa24242ec868fe0ff1e66d806a1070bcbc7c14a987a89cdc3395d0d56d5f"
-
-S = "${WORKDIR}/gst-omx-${PV}"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-omx_1.14.2.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-omx_1.14.2.bb
new file mode 100644
index 0000000..3f7bc8f
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-omx_1.14.2.bb
@@ -0,0 +1,57 @@
+SUMMARY = "OpenMAX IL plugins for GStreamer"
+HOMEPAGE = "http://gstreamer.freedesktop.org/"
+SECTION = "multimedia"
+
+LICENSE = "LGPLv2.1"
+LICENSE_FLAGS = "commercial"
+LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c \
+                    file://omx/gstomx.h;beginline=1;endline=21;md5=5c8e1fca32704488e76d2ba9ddfa935f"
+
+SRC_URI = "http://gstreamer.freedesktop.org/src/gst-omx/gst-omx-${PV}.tar.xz"
+
+SRC_URI[md5sum] = "d4fc97e3516befe04be3d1665a6f7bbe"
+SRC_URI[sha256sum] = "316dbb13693795383cad6ec4dbebd94a869cd1f9d59a393686cad0b77bf9b5a9"
+
+S = "${WORKDIR}/gst-omx-${PV}"
+
+DEPENDS = "gstreamer1.0 gstreamer1.0-plugins-base gstreamer1.0-plugins-bad"
+
+inherit autotools pkgconfig gettext gtk-doc upstream-version-is-even
+
+acpaths = "-I ${S}/common/m4 -I ${S}/m4"
+
+GSTREAMER_1_0_OMX_TARGET ?= "bellagio"
+GSTREAMER_1_0_OMX_CORE_NAME ?= "${libdir}/libomxil-bellagio.so.0"
+
+EXTRA_OECONF += "--disable-valgrind --with-omx-target=${GSTREAMER_1_0_OMX_TARGET}"
+
+python __anonymous () {
+    omx_target = d.getVar("GSTREAMER_1_0_OMX_TARGET")
+    if omx_target in ['generic', 'bellagio']:
+        # Bellagio headers are incomplete (they are missing the OMX_VERSION_MAJOR,#
+        # OMX_VERSION_MINOR, OMX_VERSION_REVISION, and OMX_VERSION_STEP macros);
+        # appending a directory path to gst-omx' internal OpenMAX IL headers fixes this
+        d.appendVar("CFLAGS", " -I${S}/omx/openmax")
+    elif omx_target == "rpi":
+        # Dedicated Raspberry Pi OpenMAX IL support makes this package machine specific
+        d.setVar("PACKAGE_ARCH", d.getVar("MACHINE_ARCH"))
+}
+
+delete_pkg_m4_file() {
+    # Delete m4 files which we provide patched versions of but will be ignored
+    # if these exist
+	rm -f "${S}/common/m4/pkg.m4"
+	rm -f "${S}/common/m4/gtk-doc.m4"
+}
+do_configure[prefuncs] += "delete_pkg_m4_file"
+
+set_omx_core_name() {
+	sed -i -e "s;^core-name=.*;core-name=${GSTREAMER_1_0_OMX_CORE_NAME};" "${D}${sysconfdir}/xdg/gstomx.conf"
+}
+do_install[postfuncs] += " set_omx_core_name "
+
+FILES_${PN} += "${libdir}/gstreamer-1.0/*.so"
+FILES_${PN}-dev += "${libdir}/gstreamer-1.0/*.la"
+FILES_${PN}-staticdev += "${libdir}/gstreamer-1.0/*.a"
+
+RDEPENDS_${PN} = "libomxil"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad.inc b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad.inc
deleted file mode 100644
index ca2ea9e..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad.inc
+++ /dev/null
@@ -1,147 +0,0 @@
-require gstreamer1.0-plugins.inc
-
-LICENSE = "GPLv2+ & LGPLv2+ & LGPLv2.1+"
-
-DEPENDS += "gstreamer1.0-plugins-base libpng jpeg"
-
-inherit gettext bluetooth
-
-SRC_URI_append = " \
-    file://0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch \
-"
-
-# opengl packageconfig factored out to make it easy for distros
-# and BSP layers to pick either (desktop) opengl, gles2, or no GL
-PACKAGECONFIG_GL ?= "${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'gles2 egl', '', d)}"
-
-# gtk is not in the PACKAGECONFIG variable by default until
-# the transition to gtk+3 is finished
-PACKAGECONFIG ??= " \
-    ${GSTREAMER_ORC} \
-    ${PACKAGECONFIG_GL} \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', 'bluez', '', d)} \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'directfb vulkan', d)} \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'wayland egl', '', d)} \
-    bz2 curl dash dtls hls rsvg sbc smoothstreaming sndfile uvch264 webp \
-"
-
-PACKAGECONFIG[assrender]       = "--enable-assrender,--disable-assrender,libass"
-PACKAGECONFIG[bluez]           = "--enable-bluez,--disable-bluez,${BLUEZ}"
-PACKAGECONFIG[bz2]             = "--enable-bz2,--disable-bz2,bzip2"
-PACKAGECONFIG[curl]            = "--enable-curl,--disable-curl,curl"
-PACKAGECONFIG[dash]            = "--enable-dash,--disable-dash,libxml2"
-PACKAGECONFIG[dc1394]          = "--enable-dc1394,--disable-dc1394,libdc1394"
-PACKAGECONFIG[directfb]        = "--enable-directfb,--disable-directfb,directfb"
-PACKAGECONFIG[dtls]            = "--enable-dtls,--disable-dtls,openssl"
-PACKAGECONFIG[egl]             = "--enable-egl,--disable-egl,virtual/egl"
-PACKAGECONFIG[faac]            = "--enable-faac,--disable-faac,faac"
-PACKAGECONFIG[faad]            = "--enable-faad,--disable-faad,faad2"
-PACKAGECONFIG[flite]           = "--enable-flite,--disable-flite,flite-alsa"
-PACKAGECONFIG[fluidsynth]      = "--enable-fluidsynth,--disable-fluidsynth,fluidsynth"
-PACKAGECONFIG[gles2]           = "--enable-gles2,--disable-gles2,virtual/libgles2"
-PACKAGECONFIG[gtk]             = "--enable-gtk3,--disable-gtk3,gtk+3"
-PACKAGECONFIG[hls]             = "--enable-hls --with-hls-crypto=nettle,--disable-hls,nettle"
-PACKAGECONFIG[kms]             = "--enable-kms,--disable-kms,libdrm"
-PACKAGECONFIG[libmms]          = "--enable-libmms,--disable-libmms,libmms"
-PACKAGECONFIG[libssh2]         = "--enable-libssh2,--disable-libssh2,libssh2"
-PACKAGECONFIG[modplug]         = "--enable-modplug,--disable-modplug,libmodplug"
-PACKAGECONFIG[neon]            = "--enable-neon,--disable-neon,neon"
-PACKAGECONFIG[openal]          = "--enable-openal,--disable-openal,openal-soft"
-PACKAGECONFIG[opencv]          = "--enable-opencv,--disable-opencv,opencv"
-PACKAGECONFIG[opengl]          = "--enable-opengl,--disable-opengl,virtual/libgl libglu"
-PACKAGECONFIG[openjpeg]        = "--enable-openjpeg,--disable-openjpeg,openjpeg"
-# the opus encoder/decoder elements are now in the -base package,
-# but the opus parser remains in -bad
-PACKAGECONFIG[opusparse]       = "--enable-opus,--disable-opus,libopus"
-PACKAGECONFIG[resindvd]        = "--enable-resindvd,--disable-resindvd,libdvdread libdvdnav"
-PACKAGECONFIG[rsvg]            = "--enable-rsvg,--disable-rsvg,librsvg"
-PACKAGECONFIG[rtmp]            = "--enable-rtmp,--disable-rtmp,rtmpdump"
-PACKAGECONFIG[sbc]             = "--enable-sbc,--disable-sbc,sbc"
-PACKAGECONFIG[schroedinger]    = "--enable-schro,--disable-schro,schroedinger"
-PACKAGECONFIG[smoothstreaming] = "--enable-smoothstreaming,--disable-smoothstreaming,libxml2"
-PACKAGECONFIG[sndfile]         = "--enable-sndfile,--disable-sndfile,libsndfile1"
-PACKAGECONFIG[srtp]            = "--enable-srtp,--disable-srtp,libsrtp"
-PACKAGECONFIG[uvch264]         = "--enable-uvch264,--disable-uvch264,libusb1 libgudev"
-PACKAGECONFIG[voaacenc]        = "--enable-voaacenc,--disable-voaacenc,vo-aacenc"
-PACKAGECONFIG[voamrwbenc]      = "--enable-voamrwbenc,--disable-voamrwbenc,vo-amrwbenc"
-PACKAGECONFIG[vulkan]          = "--enable-vulkan,--disable-vulkan,vulkan"
-PACKAGECONFIG[wayland]         = "--enable-wayland,--disable-wayland,wayland-native wayland wayland-protocols libdrm"
-PACKAGECONFIG[webp]            = "--enable-webp,--disable-webp,libwebp"
-
-# these plugins have no corresponding library in OE-core or meta-openembedded:
-#   openni2 winks direct3d directsound winscreencap acm apple_media iqa
-#   android_media avc bs2b chromaprint daala dts fdkaac gme gsm kate ladspa libde265
-#   lv2 mpeg2enc mplex msdk musepack nvenc ofa openh264 opensles soundtouch spandsp
-#   spc teletextdec tinyalsa vdpau wasapi x265 zbar webrtcdsp
-
-# qt5 support is disabled, because it is not present in OE core, and requires more work than
-# just adding a packageconfig (it requires access to moc, uic, rcc, and qmake paths).
-# This is better done in a separate qt5 layer (which then should add a "qt5" packageconfig
-# in a gstreamer1.0-plugins-bad bbappend).
-
-EXTRA_OECONF += " \
-    --enable-decklink \
-    --enable-dvb \
-    --enable-fbdev \
-    --enable-netsim \
-    --enable-shm \
-    --enable-vcd \
-    --disable-acm \
-    --disable-android_media \
-    --disable-apple_media \
-    --disable-avc \
-    --disable-bs2b \
-    --disable-chromaprint \
-    --disable-cocoa \
-    --disable-daala \
-    --disable-direct3d \
-    --disable-directsound \
-    --disable-dts \
-    --disable-fdk_aac \
-    --disable-gme \
-    --disable-gsm \
-    --disable-iqa \
-    --disable-kate \
-    --disable-ladspa \
-    --disable-libde265 \
-    --disable-lv2 \
-    --disable-mpeg2enc \
-    --disable-mplex \
-    --disable-msdk \
-    --disable-musepack \
-    --disable-nvenc \
-    --disable-ofa \
-    --disable-openexr \
-    --disable-openh264 \
-    --disable-openni2 \
-    --disable-opensles \
-    --disable-qt \
-    --disable-soundtouch \
-    --disable-spandsp \
-    --disable-spc \
-    --disable-teletextdec \
-    --disable-tinyalsa \
-    --disable-vdpau \
-    --disable-wasapi \
-    --disable-webrtcdsp \
-    --disable-wildmidi \
-    --disable-winks \
-    --disable-winscreencap \
-    --disable-x265 \
-    --disable-zbar \
-    ${@bb.utils.contains("TUNE_FEATURES", "mx32", "--disable-yadif", "", d)} \
-"
-
-export OPENCV_PREFIX = "${STAGING_DIR_TARGET}${prefix}"
-
-ARM_INSTRUCTION_SET_armv4 = "arm"
-ARM_INSTRUCTION_SET_armv5 = "arm"
-
-FILES_${PN}-dev += "${libdir}/gstreamer-${LIBV}/include/gst/gl/gstglconfig.h"
-FILES_${PN}-freeverb += "${datadir}/gstreamer-${LIBV}/presets/GstFreeverb.prs"
-FILES_${PN}-opencv += "${datadir}/gst-plugins-bad/${LIBV}/opencv*"
-FILES_${PN}-voamrwbenc += "${datadir}/gstreamer-${LIBV}/presets/GstVoAmrwbEnc.prs"
-
-do_compile_prepend() {
-    export GIR_EXTRA_LIBS_PATH="${B}/gst-libs/gst/allocators/.libs"
-}
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch
index 8d99dc6..05b991a 100644
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch
@@ -1,48 +1,17 @@
-From 7592e793b3906355d76ca9a59f8fea2749ea2a4e Mon Sep 17 00:00:00 2001
-From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Tue, 27 Oct 2015 14:36:58 +0200
-Subject: [PATCH] Makefile.am: don't hardcode libtool name when running
+From 7d8e8b8bcce34d01fc7ad7285b4eb17ad8949399 Mon Sep 17 00:00:00 2001
+From: Anuj Mittal <anuj.mittal@intel.com>
+Date: Wed, 11 Apr 2018 11:06:39 +0800
+Subject: [PATCH] Makefile.am: don't hardcode libtool name when running 
  introspection tools
 
 Upstream-Status: Pending [review on oe-core list]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
-
-%% original patch: 0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch
-
 Signed-off-by: Maxin B. John <maxin.john@intel.com>
 ---
- gst-libs/gst/allocators/Makefile.am | 2 +-
- gst-libs/gst/gl/Makefile.am         | 2 +-
- gst-libs/gst/insertbin/Makefile.am  | 2 +-
- gst-libs/gst/mpegts/Makefile.am     | 2 +-
- 4 files changed, 4 insertions(+), 4 deletions(-)
+ gst-libs/gst/insertbin/Makefile.am | 2 +-
+ gst-libs/gst/mpegts/Makefile.am    | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
 
-diff --git a/gst-libs/gst/allocators/Makefile.am b/gst-libs/gst/allocators/Makefile.am
-index e50d077..623f092 100644
---- a/gst-libs/gst/allocators/Makefile.am
-+++ b/gst-libs/gst/allocators/Makefile.am
-@@ -37,7 +37,7 @@ GstBadAllocators-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstbadalloca
- 		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
- 		--library=libgstbadallocators-@GST_API_VERSION@.la \
- 		--include=Gst-@GST_API_VERSION@ \
--		--libtool="$(top_builddir)/libtool" \
-+		--libtool="$(LIBTOOL)" \
- 		--pkg gstreamer-@GST_API_VERSION@ \
- 		--pkg-export gstreamer-badallocators-@GST_API_VERSION@ \
- 		--output $@ \
-diff --git a/gst-libs/gst/gl/Makefile.am b/gst-libs/gst/gl/Makefile.am
-index 2ae4773..dfa7a7d 100644
---- a/gst-libs/gst/gl/Makefile.am
-+++ b/gst-libs/gst/gl/Makefile.am
-@@ -178,7 +178,7 @@ GstGL-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstgl-@GST_API_VERSION@
- 		--include=Gst-@GST_API_VERSION@ \
- 		--include=GstBase-@GST_API_VERSION@ \
- 		--include=GstVideo-@GST_API_VERSION@ \
--		--libtool="$(top_builddir)/libtool" \
-+		--libtool="$(LIBTOOL)" \
- 		--pkg gstreamer-@GST_API_VERSION@ \
- 		--pkg gstreamer-base-@GST_API_VERSION@ \
- 		--pkg gstreamer-video-@GST_API_VERSION@ \
 diff --git a/gst-libs/gst/insertbin/Makefile.am b/gst-libs/gst/insertbin/Makefile.am
 index 1f8ea30..4b98ef6 100644
 --- a/gst-libs/gst/insertbin/Makefile.am
@@ -57,10 +26,10 @@
  		--pkg gstreamer-base-@GST_API_VERSION@ \
  		--pkg-export gstreamer-insertbin-@GST_API_VERSION@ \
 diff --git a/gst-libs/gst/mpegts/Makefile.am b/gst-libs/gst/mpegts/Makefile.am
-index aeea32e..929d9cc 100644
+index f264e33..9934a4d 100644
 --- a/gst-libs/gst/mpegts/Makefile.am
 +++ b/gst-libs/gst/mpegts/Makefile.am
-@@ -79,7 +79,7 @@ GstMpegts-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstmpegts-@GST_API_
+@@ -82,7 +82,7 @@ GstMpegts-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstmpegts-@GST_API_
  		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-video-@GST_API_VERSION@` \
  		--library=libgstmpegts-@GST_API_VERSION@.la \
  		--include=Gst-@GST_API_VERSION@ \
@@ -70,5 +39,5 @@
  		--pkg gstreamer-video-@GST_API_VERSION@ \
  		--pkg-export gstreamer-mpegts-@GST_API_VERSION@ \
 -- 
-2.4.0
+2.7.4
 
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-gstreamer-gl.pc.in-don-t-append-GL_CFLAGS-to-CFLAGS.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-gstreamer-gl.pc.in-don-t-append-GL_CFLAGS-to-CFLAGS.patch
deleted file mode 100644
index 2235a57..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-gstreamer-gl.pc.in-don-t-append-GL_CFLAGS-to-CFLAGS.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From 5622ca3b61603dc316a0f1fbede3f9aa353a5e48 Mon Sep 17 00:00:00 2001
-From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Fri, 12 May 2017 16:47:12 +0300
-Subject: [PATCH] gstreamer-gl.pc.in: don't append GL_CFLAGS to CFLAGS
-
-Dependencies' include directories should not be added in this way;
-it causes problems when cross-compiling in sysroot environments.
-
-Upstream-Status: Pending
-
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
-Signed-off-by: Maxin B. John <maxin.john@intel.com>
----
- pkgconfig/gstreamer-gl.pc.in | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/pkgconfig/gstreamer-gl.pc.in b/pkgconfig/gstreamer-gl.pc.in
-index 8e7a303..d167be1 100644
---- a/pkgconfig/gstreamer-gl.pc.in
-+++ b/pkgconfig/gstreamer-gl.pc.in
-@@ -13,4 +13,4 @@ Version: @VERSION@
- Requires: gstreamer-base-@GST_API_VERSION@ gstreamer-@GST_API_VERSION@
- 
- Libs: -L${libdir} -lgstgl-@GST_API_VERSION@
--Cflags: -I${includedir} -I${libdir}/gstreamer-@GST_API_VERSION@/include @GL_CFLAGS@
-+Cflags: -I${includedir} -I${libdir}/gstreamer-@GST_API_VERSION@/include
--- 
-2.4.0
-
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-vkdisplay-Use-ifdef-for-platform-specific-defines.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-vkdisplay-Use-ifdef-for-platform-specific-defines.patch
deleted file mode 100644
index caaa62d..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-vkdisplay-Use-ifdef-for-platform-specific-defines.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From 1523ab462c1bf19055960ced255f4872b6cf9f5c Mon Sep 17 00:00:00 2001
-From: Jussi Kukkonen <jussi.kukkonen@intel.com>
-Date: Wed, 5 Jul 2017 11:00:42 +0300
-Subject: [PATCH 1/2] vkdisplay: Use ifdef for platform specific defines
-
-VK_KHR_*_SURFACE_EXTENSION_NAME are only available when corresponding
-WSI is enabled.
-
-Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
-Upstream-Status: Submitted [https://bugzilla.gnome.org/show_bug.cgi?id=784539]
----
- ext/vulkan/vkdisplay.c | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/ext/vulkan/vkdisplay.c b/ext/vulkan/vkdisplay.c
-index 550134cd8..ade5d4583 100644
---- a/ext/vulkan/vkdisplay.c
-+++ b/ext/vulkan/vkdisplay.c
-@@ -448,11 +448,15 @@ gst_vulkan_display_type_to_extension_string (GstVulkanDisplayType type)
-   if (type == GST_VULKAN_DISPLAY_TYPE_NONE)
-     return NULL;
- 
-+#if GST_VULKAN_HAVE_WINDOW_XCB
-   if (type & GST_VULKAN_DISPLAY_TYPE_XCB)
-     return VK_KHR_XCB_SURFACE_EXTENSION_NAME;
-+#endif
- 
-+#if GST_VULKAN_HAVE_WINDOW_WAYLAND
-   if (type & GST_VULKAN_DISPLAY_TYPE_WAYLAND)
-     return VK_KHR_WAYLAND_SURFACE_EXTENSION_NAME;
-+#endif
- 
-   return NULL;
- }
--- 
-2.13.2
-
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0002-vulkan-Use-the-generated-version-of-vkconfig.h.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0002-vulkan-Use-the-generated-version-of-vkconfig.h.patch
deleted file mode 100644
index 0df145d..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0002-vulkan-Use-the-generated-version-of-vkconfig.h.patch
+++ /dev/null
@@ -1,64 +0,0 @@
-From c23e1dc22deb495561cffb877edb2746b740a1fa Mon Sep 17 00:00:00 2001
-From: Jussi Kukkonen <jussi.kukkonen@intel.com>
-Date: Wed, 5 Jul 2017 11:07:05 +0300
-Subject: [PATCH 2/2] vulkan: Use the generated version of vkconfig.h
-
-Build fails in ext/vulkan/xcb and ext/vulkan/wayland when:
-* building from tarball
-* building out-of-tree
-* Only one WSI integration (xcb or wayland) is enabled by configure.ac
-This is because vkconfig.h from source directory gets used instead
-of the generated one.
-
-Add the correct build directory to "-I". Use angle bracket
-include in vkapi.h so that it actually looks in the include search
-path instead of defaulting to the same (source tree) directory.
-
-Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
-Upstream-Status: Submitted [https://bugzilla.gnome.org/show_bug.cgi?id=784539]
----
- ext/vulkan/vkapi.h             | 2 +-
- ext/vulkan/wayland/Makefile.am | 1 +
- ext/vulkan/xcb/Makefile.am     | 1 +
- 3 files changed, 3 insertions(+), 1 deletion(-)
-
-diff --git a/ext/vulkan/vkapi.h b/ext/vulkan/vkapi.h
-index e9c23aa92..a37c29d0f 100644
---- a/ext/vulkan/vkapi.h
-+++ b/ext/vulkan/vkapi.h
-@@ -23,7 +23,7 @@
- 
- #define VK_PROTOTYPES
- 
--#include "vkconfig.h"
-+#include <vkconfig.h>
- #include "vk_fwd.h"
- #include "vkmacros.h"
- 
-diff --git a/ext/vulkan/wayland/Makefile.am b/ext/vulkan/wayland/Makefile.am
-index f92d85e2c..10cfb70e6 100644
---- a/ext/vulkan/wayland/Makefile.am
-+++ b/ext/vulkan/wayland/Makefile.am
-@@ -14,6 +14,7 @@ noinst_HEADERS = \
- 
- libgstvulkan_wayland_la_CFLAGS = \
- 	-I$(top_srcdir)/gst-libs \
-+	-I$(top_builddir)/ext/vulkan \
- 	-I$(top_srcdir)/ext/vulkan \
- 	-I$(top_builddir)/gst-libs \
- 	$(GST_PLUGINS_BASE_CFLAGS) \
-diff --git a/ext/vulkan/xcb/Makefile.am b/ext/vulkan/xcb/Makefile.am
-index 7debcff9e..b5103551b 100644
---- a/ext/vulkan/xcb/Makefile.am
-+++ b/ext/vulkan/xcb/Makefile.am
-@@ -14,6 +14,7 @@ noinst_HEADERS = \
- 
- libgstvulkan_xcb_la_CFLAGS = \
- 	-I$(top_srcdir)/gst-libs \
-+	-I$(top_builddir)/ext/vulkan \
- 	-I$(top_srcdir)/ext/vulkan \
- 	-I$(top_builddir)/gst-libs \
- 	$(GST_PLUGINS_BASE_CFLAGS) \
--- 
-2.13.2
-
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/link-with-libvchostif.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/link-with-libvchostif.patch
deleted file mode 100644
index c382b17..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/link-with-libvchostif.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-Add -lvchostif to link when using -lEGL on rpi
-
-This is required because libEGL from userland uses sybols
-from this library.
-
-lib/libEGL.so.1.0.0                                                                                                                                                                                                                              121: 00000000     0 FUNC    GLOBAL DEFAULT  UND vc_dispmanx_element_add
-  1552: 00000000     0 FUNC    GLOBAL DEFAULT  UND vc_dispmanx_element_add
-
-These symbols are provided by libvchostif as seen below
-
-lib/libvchostif.so
-   252: 0000b161   192 FUNC    GLOBAL DEFAULT    9 vc_dispmanx_element_add
-   809: 0000b161   192 FUNC    GLOBAL DEFAULT    9 vc_dispmanx_element_add
-
-With this explicit link, plugins fail during runtime
-
-(gst-plugin-scanner:571): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-1.0/libgstomx.so': Error relocating /usr/lib/libgstgl-1.0.so.0: vc_dispmanx_element_add: symbol not found
-(gst-plugin-scanner:571): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-1.0/libgstopengl.so': Error relocating /usr/lib/libgstgl-1.0.so.0: vc_dispmanx_element_add: symbol not found
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
-Index: gst-plugins-bad-1.10.4/configure.ac
-===================================================================
---- gst-plugins-bad-1.10.4.orig/configure.ac
-+++ gst-plugins-bad-1.10.4/configure.ac
-@@ -785,7 +785,7 @@ case $host in
-                             HAVE_EGL=yes
-                             HAVE_GLES2=yes
-                             HAVE_EGL_RPI=yes
--                            EGL_LIBS="-lbcm_host -lvcos -lvchiq_arm"
-+                            EGL_LIBS="-lbcm_host -lvchostif -lvcos -lvchiq_arm"
-                             EGL_CFLAGS=""
-                             AC_DEFINE(USE_EGL_RPI, [1], [Use RPi platform])
-                           ])
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_1.12.4.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_1.12.4.bb
deleted file mode 100644
index 82c7ffc..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_1.12.4.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-require gstreamer1.0-plugins-bad.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=73a5855a8119deb017f5f13cf327095d \
-                    file://COPYING.LIB;md5=21682e4e8fea52413fd26c60acb907e5 "
-
-SRC_URI = " \
-    http://gstreamer.freedesktop.org/src/gst-plugins-bad/gst-plugins-bad-${PV}.tar.xz \
-    file://configure-allow-to-disable-libssh2.patch \
-    file://fix-maybe-uninitialized-warnings-when-compiling-with-Os.patch \
-    file://avoid-including-sys-poll.h-directly.patch \
-    file://ensure-valid-sentinels-for-gst_structure_get-etc.patch \
-    file://0001-gstreamer-gl.pc.in-don-t-append-GL_CFLAGS-to-CFLAGS.patch \
-    file://0009-glimagesink-Downrank-to-marginal.patch \
-    file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch \
-    file://link-with-libvchostif.patch \
-    file://0001-vkdisplay-Use-ifdef-for-platform-specific-defines.patch \
-    file://0002-vulkan-Use-the-generated-version-of-vkconfig.h.patch \
-"
-SRC_URI[md5sum] = "64bf16cf15edaab1c0e02c8dee7170d0"
-SRC_URI[sha256sum] = "0c7857be16686d5c1ba6e34bd338664d3d4599d32714a8eca5c8a41a101e2d08"
-
-S = "${WORKDIR}/gst-plugins-bad-${PV}"
-
-
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_1.14.2.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_1.14.2.bb
new file mode 100644
index 0000000..39546b8
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_1.14.2.bb
@@ -0,0 +1,148 @@
+require gstreamer1.0-plugins.inc
+
+SRC_URI = " \
+    http://gstreamer.freedesktop.org/src/gst-plugins-bad/gst-plugins-bad-${PV}.tar.xz \
+    file://configure-allow-to-disable-libssh2.patch \
+    file://fix-maybe-uninitialized-warnings-when-compiling-with-Os.patch \
+    file://avoid-including-sys-poll.h-directly.patch \
+    file://ensure-valid-sentinels-for-gst_structure_get-etc.patch \
+    file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch \
+    file://0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch \
+"
+SRC_URI[md5sum] = "76826c564bed5511982d7fb6137d9875"
+SRC_URI[sha256sum] = "34fab7da70994465a64468330b2168a4a0ed90a7de7e4c499b6d127c6c1b1eaf"
+
+S = "${WORKDIR}/gst-plugins-bad-${PV}"
+
+LICENSE = "GPLv2+ & LGPLv2+ & LGPLv2.1+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=73a5855a8119deb017f5f13cf327095d \
+                    file://COPYING.LIB;md5=21682e4e8fea52413fd26c60acb907e5 "
+
+DEPENDS += "gstreamer1.0-plugins-base jpeg"
+
+inherit gettext bluetooth
+
+PACKAGECONFIG ??= " \
+    ${GSTREAMER_ORC} \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', 'bluez', '', d)} \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'directfb vulkan', d)} \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'wayland', '', d)} \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'gl', '', d)} \
+    bz2 curl dash dtls hls rsvg sbc smoothstreaming sndfile ttml uvch264 webp \
+"
+
+# the gl packageconfig enables OpenGL elements that haven't been ported
+# to -base yet. They depend on the gstgl library in -base, so we do
+# not add GL dependencies here, since these are taken care of in -base.
+
+PACKAGECONFIG[assrender]       = "--enable-assrender,--disable-assrender,libass"
+PACKAGECONFIG[bluez]           = "--enable-bluez,--disable-bluez,${BLUEZ}"
+PACKAGECONFIG[bz2]             = "--enable-bz2,--disable-bz2,bzip2"
+PACKAGECONFIG[curl]            = "--enable-curl,--disable-curl,curl"
+PACKAGECONFIG[dash]            = "--enable-dash,--disable-dash,libxml2"
+PACKAGECONFIG[dc1394]          = "--enable-dc1394,--disable-dc1394,libdc1394"
+PACKAGECONFIG[directfb]        = "--enable-directfb,--disable-directfb,directfb"
+PACKAGECONFIG[dtls]            = "--enable-dtls,--disable-dtls,openssl"
+PACKAGECONFIG[faac]            = "--enable-faac,--disable-faac,faac"
+PACKAGECONFIG[faad]            = "--enable-faad,--disable-faad,faad2"
+PACKAGECONFIG[flite]           = "--enable-flite,--disable-flite,flite-alsa"
+PACKAGECONFIG[fluidsynth]      = "--enable-fluidsynth,--disable-fluidsynth,fluidsynth"
+PACKAGECONFIG[hls]             = "--enable-hls --with-hls-crypto=nettle,--disable-hls,nettle"
+PACKAGECONFIG[gl]              = "--enable-gl,--disable-gl,"
+PACKAGECONFIG[kms]             = "--enable-kms,--disable-kms,libdrm"
+PACKAGECONFIG[libde265]        = "--enable-libde265,--disable-libde265,libde265"
+PACKAGECONFIG[libmms]          = "--enable-libmms,--disable-libmms,libmms"
+PACKAGECONFIG[libssh2]         = "--enable-libssh2,--disable-libssh2,libssh2"
+PACKAGECONFIG[lcms2]           = "--enable-lcms2,--disable-lcms2,lcms"
+PACKAGECONFIG[modplug]         = "--enable-modplug,--disable-modplug,libmodplug"
+PACKAGECONFIG[neon]            = "--enable-neon,--disable-neon,neon"
+PACKAGECONFIG[openal]          = "--enable-openal,--disable-openal,openal-soft"
+PACKAGECONFIG[opencv]          = "--enable-opencv,--disable-opencv,opencv"
+PACKAGECONFIG[openh264]        = "--enable-openh264,--disable-openh264,openh264"
+PACKAGECONFIG[openjpeg]        = "--enable-openjpeg,--disable-openjpeg,openjpeg"
+PACKAGECONFIG[openmpt]         = "--enable-openmpt,--disable-openmpt,libopenmpt"
+# the opus encoder/decoder elements are now in the -base package,
+# but the opus parser remains in -bad
+PACKAGECONFIG[opusparse]       = "--enable-opus,--disable-opus,libopus"
+PACKAGECONFIG[resindvd]        = "--enable-resindvd,--disable-resindvd,libdvdread libdvdnav"
+PACKAGECONFIG[rsvg]            = "--enable-rsvg,--disable-rsvg,librsvg"
+PACKAGECONFIG[rtmp]            = "--enable-rtmp,--disable-rtmp,rtmpdump"
+PACKAGECONFIG[sbc]             = "--enable-sbc,--disable-sbc,sbc"
+PACKAGECONFIG[smoothstreaming] = "--enable-smoothstreaming,--disable-smoothstreaming,libxml2"
+PACKAGECONFIG[sndfile]         = "--enable-sndfile,--disable-sndfile,libsndfile1"
+PACKAGECONFIG[srtp]            = "--enable-srtp,--disable-srtp,libsrtp"
+PACKAGECONFIG[tinyalsa]        = "--enable-tinyalsa,--disable-tinyalsa,tinyalsa"
+PACKAGECONFIG[ttml]            = "--enable-ttml,--disable-ttml,libxml2 pango cairo"
+PACKAGECONFIG[uvch264]         = "--enable-uvch264,--disable-uvch264,libusb1 libgudev"
+PACKAGECONFIG[voaacenc]        = "--enable-voaacenc,--disable-voaacenc,vo-aacenc"
+PACKAGECONFIG[voamrwbenc]      = "--enable-voamrwbenc,--disable-voamrwbenc,vo-amrwbenc"
+PACKAGECONFIG[vulkan]          = "--enable-vulkan,--disable-vulkan,vulkan"
+PACKAGECONFIG[wayland]         = "--enable-wayland,--disable-wayland,wayland-native wayland wayland-protocols libdrm"
+PACKAGECONFIG[webp]            = "--enable-webp,--disable-webp,libwebp"
+PACKAGECONFIG[webrtc]          = "--enable-webrtc,--disable-webrtc,libnice"
+PACKAGECONFIG[webrtcdsp]       = "--enable-webrtcdsp,--disable-webrtcdsp,webrtc-audio-processing"
+
+# these plugins have no corresponding library in OE-core or meta-openembedded:
+#   openni2 winks direct3d directsound winscreencap acm apple_media iqa
+#   android_media avc bs2b chromaprint daala dts fdkaac gme gsm kate ladspa
+#   lv2 mpeg2enc mplex msdk musepack nvenc ofa opensles soundtouch
+#   spandsp spc teletextdec vdpau wasapi x265 zbar
+
+EXTRA_OECONF += " \
+    --enable-decklink \
+    --enable-dvb \
+    --enable-fbdev \
+    --enable-ipcpipeline \
+    --enable-netsim \
+    --enable-shm \
+    --enable-vcd \
+    --disable-acm \
+    --disable-android_media \
+    --disable-aom \
+    --disable-apple_media \
+    --disable-avc \
+    --disable-bs2b \
+    --disable-chromaprint \
+    --disable-daala \
+    --disable-direct3d \
+    --disable-directsound \
+    --disable-dts \
+    --disable-fdk_aac \
+    --disable-gme \
+    --disable-gsm \
+    --disable-iqa \
+    --disable-kate \
+    --disable-ladspa \
+    --disable-lv2 \
+    --disable-mpeg2enc \
+    --disable-mplex \
+    --disable-msdk \
+    --disable-musepack \
+    --disable-nvenc \
+    --disable-ofa \
+    --disable-openexr \
+    --disable-openni2 \
+    --disable-opensles \
+    --disable-soundtouch \
+    --disable-spandsp \
+    --disable-spc \
+    --disable-srt \
+    --disable-teletextdec \
+    --disable-vdpau \
+    --disable-wasapi \
+    --disable-wildmidi \
+    --disable-winks \
+    --disable-winscreencap \
+    --disable-x265 \
+    --disable-zbar \
+    ${@bb.utils.contains("TUNE_FEATURES", "mx32", "--disable-yadif", "", d)} \
+"
+
+export OPENCV_PREFIX = "${STAGING_DIR_TARGET}${prefix}"
+
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
+
+FILES_${PN}-freeverb += "${datadir}/gstreamer-${LIBV}/presets/GstFreeverb.prs"
+FILES_${PN}-opencv += "${datadir}/gst-plugins-bad/${LIBV}/opencv*"
+FILES_${PN}-voamrwbenc += "${datadir}/gstreamer-${LIBV}/presets/GstVoAmrwbEnc.prs"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base.inc b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base.inc
deleted file mode 100644
index 08130c1..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base.inc
+++ /dev/null
@@ -1,50 +0,0 @@
-require gstreamer1.0-plugins.inc
-
-SRC_URI_append = "\
-    file://0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch \
-    file://0002-Makefile.am-prefix-calls-to-pkg-config-with-PKG_CONF.patch \
-    file://0003-riff-add-missing-include-directories-when-calling-in.patch \
-    file://0004-rtsp-drop-incorrect-reference-to-gstreamer-sdp-in-Ma.patch \
-"
-
-LICENSE = "GPLv2+ & LGPLv2+"
-
-DEPENDS += "iso-codes util-linux zlib"
-
-inherit gettext
-
-PACKAGES_DYNAMIC =+ "^libgst.*"
-
-PACKAGECONFIG ??= " \
-    ${GSTREAMER_ORC} \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'alsa x11', d)} \
-    gio-unix-2.0 ogg pango theora vorbis \
-"
-
-X11DEPENDS = "virtual/libx11 libsm libxrender libxv"
-X11ENABLEOPTS = "--enable-x --enable-xvideo --enable-xshm"
-X11DISABLEOPTS = "--disable-x --disable-xvideo --disable-xshm"
-
-PACKAGECONFIG[alsa]         = "--enable-alsa,--disable-alsa,alsa-lib"
-PACKAGECONFIG[cdparanoia]   = "--enable-cdparanoia,--disable-cdparanoia,cdparanoia"
-PACKAGECONFIG[gio-unix-2.0] = "--enable-gio_unix_2_0,--disable-gio_unix_2_0,glib-2.0"
-PACKAGECONFIG[ivorbis]      = "--enable-ivorbis,--disable-ivorbis,tremor"
-PACKAGECONFIG[ogg]          = "--enable-ogg,--disable-ogg,libogg"
-PACKAGECONFIG[opus]         = "--enable-opus,--disable-opus,libopus"
-PACKAGECONFIG[pango]        = "--enable-pango,--disable-pango,pango"
-PACKAGECONFIG[theora]       = "--enable-theora,--disable-theora,libtheora"
-PACKAGECONFIG[visual]       = "--enable-libvisual,--disable-libvisual,libvisual"
-PACKAGECONFIG[vorbis]       = "--enable-vorbis,--disable-vorbis,libvorbis"
-PACKAGECONFIG[x11]          = "${X11ENABLEOPTS},${X11DISABLEOPTS},${X11DEPENDS}"
-
-EXTRA_OECONF += " \
-    --enable-zlib \
-"
-
-CACHED_CONFIGUREVARS_append_x86 = " ac_cv_header_emmintrin_h=no ac_cv_header_xmmintrin_h=no"
-
-FILES_${MLPREFIX}libgsttag-1.0 += "${datadir}/gst-plugins-base/1.0/license-translations.dict"
-
-do_compile_prepend() {
-        export GIR_EXTRA_LIBS_PATH="${B}/gst-libs/gst/tag/.libs:${B}/gst-libs/gst/video/.libs:${B}/gst-libs/gst/audio/.libs:${B}/gst-libs/gst/rtp/.libs"
-}
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch
index 094bdac..bcada34 100644
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch
@@ -1,16 +1,18 @@
-From f1d9652351e7754c63003104eceb526af424c7e0 Mon Sep 17 00:00:00 2001
+From 7022b87353a37b78bae7cf0106a4e47913bb5c97 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Fri, 20 Nov 2015 16:53:04 +0200
-Subject: [PATCH 1/4] Makefile.am: don't hardcode libtool name when running
+Date: Thu, 5 Apr 2018 10:15:08 +0800
+Subject: [PATCH] Makefile.am: don't hardcode libtool name when running
  introspection tools
 
 Upstream-Status: Pending [review on oe-core maillist]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+
 ---
  gst-libs/gst/allocators/Makefile.am | 2 +-
  gst-libs/gst/app/Makefile.am        | 2 +-
  gst-libs/gst/audio/Makefile.am      | 2 +-
- gst-libs/gst/fft/Makefile.am        | 2 +-
+ gst-libs/gst/gl/Makefile.am         | 2 +-
  gst-libs/gst/pbutils/Makefile.am    | 2 +-
  gst-libs/gst/riff/Makefile.am       | 2 +-
  gst-libs/gst/rtp/Makefile.am        | 2 +-
@@ -21,10 +23,10 @@
  11 files changed, 11 insertions(+), 11 deletions(-)
 
 diff --git a/gst-libs/gst/allocators/Makefile.am b/gst-libs/gst/allocators/Makefile.am
-index 9361bf9..bc7f53a 100644
+index 1957d28..1ecc950 100644
 --- a/gst-libs/gst/allocators/Makefile.am
 +++ b/gst-libs/gst/allocators/Makefile.am
-@@ -38,7 +38,7 @@ GstAllocators-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstallocators-@
+@@ -42,7 +42,7 @@ GstAllocators-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstallocators-@
  		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
  		--library=libgstallocators-@GST_API_VERSION@.la \
  		--include=Gst-@GST_API_VERSION@ \
@@ -34,10 +36,10 @@
  		--pkg-export gstreamer-allocators-@GST_API_VERSION@ \
  		--output $@ \
 diff --git a/gst-libs/gst/app/Makefile.am b/gst-libs/gst/app/Makefile.am
-index 6d6de8d..dcc2fe0 100644
+index 52f6ad3..5bfd606 100644
 --- a/gst-libs/gst/app/Makefile.am
 +++ b/gst-libs/gst/app/Makefile.am
-@@ -53,7 +53,7 @@ GstApp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstapp-@GST_API_VERSIO
+@@ -56,7 +56,7 @@ GstApp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstapp-@GST_API_VERSIO
  		--library=libgstapp-@GST_API_VERSION@.la \
  		--include=Gst-@GST_API_VERSION@ \
  		--include=GstBase-@GST_API_VERSION@ \
@@ -47,10 +49,10 @@
  		--pkg gstreamer-base-@GST_API_VERSION@ \
  		--pkg-export gstreamer-app-@GST_API_VERSION@ \
 diff --git a/gst-libs/gst/audio/Makefile.am b/gst-libs/gst/audio/Makefile.am
-index 275d222..2374196 100644
+index 2922245..7fb65f2 100644
 --- a/gst-libs/gst/audio/Makefile.am
 +++ b/gst-libs/gst/audio/Makefile.am
-@@ -116,7 +116,7 @@ GstAudio-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstaudio-@GST_API_VE
+@@ -184,7 +184,7 @@ GstAudio-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstaudio-@GST_API_VE
  		--include=Gst-@GST_API_VERSION@ \
  		--include=GstBase-@GST_API_VERSION@ \
  		--include=GstTag-@GST_API_VERSION@ \
@@ -59,24 +61,24 @@
  		--pkg gstreamer-@GST_API_VERSION@ \
  		--pkg gstreamer-base-@GST_API_VERSION@ \
  		--pkg-export gstreamer-audio-@GST_API_VERSION@ \
-diff --git a/gst-libs/gst/fft/Makefile.am b/gst-libs/gst/fft/Makefile.am
-index 09b3d68..f545354 100644
---- a/gst-libs/gst/fft/Makefile.am
-+++ b/gst-libs/gst/fft/Makefile.am
-@@ -65,7 +65,7 @@ GstFft-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstfft-@GST_API_VERSIO
- 		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
- 		--library=libgstfft-@GST_API_VERSION@.la \
+diff --git a/gst-libs/gst/gl/Makefile.am b/gst-libs/gst/gl/Makefile.am
+index 4e77e8c..3276d7f 100644
+--- a/gst-libs/gst/gl/Makefile.am
++++ b/gst-libs/gst/gl/Makefile.am
+@@ -193,7 +193,7 @@ GstGL-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstgl-@GST_API_VERSION@
  		--include=Gst-@GST_API_VERSION@ \
--		--libtool="$(top_builddir)/libtool" \
+ 		--include=GstBase-@GST_API_VERSION@ \
+ 		--include=GstVideo-@GST_API_VERSION@ \
+-		--libtool="${LIBTOOL}" \
 +		--libtool="$(LIBTOOL)" \
  		--pkg gstreamer-@GST_API_VERSION@ \
- 		--pkg-export gstreamer-fft-@GST_API_VERSION@ \
- 		--output $@ \
+ 		--pkg gstreamer-base-@GST_API_VERSION@ \
+ 		--pkg gstreamer-video-@GST_API_VERSION@ \
 diff --git a/gst-libs/gst/pbutils/Makefile.am b/gst-libs/gst/pbutils/Makefile.am
-index 64d5eb0..91dc214 100644
+index ae51993..35a6e44 100644
 --- a/gst-libs/gst/pbutils/Makefile.am
 +++ b/gst-libs/gst/pbutils/Makefile.am
-@@ -99,7 +99,7 @@ GstPbutils-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstpbutils-@GST_AP
+@@ -103,7 +103,7 @@ GstPbutils-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstpbutils-@GST_AP
  		--include=GstTag-@GST_API_VERSION@ \
  		--include=GstVideo-@GST_API_VERSION@ \
  		--include=GstAudio-@GST_API_VERSION@ \
@@ -86,10 +88,10 @@
  		--pkg gstreamer-tag-@GST_API_VERSION@ \
  		--pkg gstreamer-video-@GST_API_VERSION@ \
 diff --git a/gst-libs/gst/riff/Makefile.am b/gst-libs/gst/riff/Makefile.am
-index 83d83cb..3bd8fc0 100644
+index fb53f06..e66ef4f 100644
 --- a/gst-libs/gst/riff/Makefile.am
 +++ b/gst-libs/gst/riff/Makefile.am
-@@ -47,7 +47,7 @@ libgstriff_@GST_API_VERSION@_la_LDFLAGS = $(GST_LIB_LDFLAGS) $(GST_ALL_LDFLAGS)
+@@ -49,7 +49,7 @@ libgstriff_@GST_API_VERSION@_la_LDFLAGS = $(GST_LIB_LDFLAGS) $(GST_ALL_LDFLAGS)
  #		--include=GstAudio-@GST_API_VERSION@ \
  #		--include=GstTag-@GST_API_VERSION@ \
  #		--include=Gst-@GST_API_VERSION@ \
@@ -99,10 +101,10 @@
  #		--pkg gstreamer-tag-@GST_API_VERSION@ \
  #		--pkg gstreamer-audio-@GST_API_VERSION@ \
 diff --git a/gst-libs/gst/rtp/Makefile.am b/gst-libs/gst/rtp/Makefile.am
-index fdd01c1..f5445c1 100644
+index a6f971d..77ebeeb 100644
 --- a/gst-libs/gst/rtp/Makefile.am
 +++ b/gst-libs/gst/rtp/Makefile.am
-@@ -65,7 +65,7 @@ GstRtp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstrtp-@GST_API_VERSIO
+@@ -69,7 +69,7 @@ GstRtp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstrtp-@GST_API_VERSIO
  		--library=libgstrtp-@GST_API_VERSION@.la \
  		--include=Gst-@GST_API_VERSION@ \
  		--include=GstBase-@GST_API_VERSION@ \
@@ -112,10 +114,10 @@
  		--pkg gstreamer-base-@GST_API_VERSION@ \
  		--pkg-export gstreamer-rtp-@GST_API_VERSION@ \
 diff --git a/gst-libs/gst/rtsp/Makefile.am b/gst-libs/gst/rtsp/Makefile.am
-index ede5706..9b0b258 100644
+index ceb07f4..db9d0fd 100644
 --- a/gst-libs/gst/rtsp/Makefile.am
 +++ b/gst-libs/gst/rtsp/Makefile.am
-@@ -72,7 +72,7 @@ GstRtsp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstrtsp-@GST_API_VERS
+@@ -76,7 +76,7 @@ GstRtsp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstrtsp-@GST_API_VERS
  		--include=Gio-2.0 \
  		--include=Gst-@GST_API_VERSION@ \
  		--include=GstSdp-@GST_API_VERSION@ \
@@ -125,10 +127,10 @@
  		--pkg gstreamer-@GST_API_VERSION@ \
  		--pkg gstreamer-sdp-@GST_API_VERSION@ \
 diff --git a/gst-libs/gst/sdp/Makefile.am b/gst-libs/gst/sdp/Makefile.am
-index a90f30b..0e149b8 100644
+index e197e9b..6e05cc7 100644
 --- a/gst-libs/gst/sdp/Makefile.am
 +++ b/gst-libs/gst/sdp/Makefile.am
-@@ -32,7 +32,7 @@ GstSdp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstsdp-@GST_API_VERSIO
+@@ -34,7 +34,7 @@ GstSdp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstsdp-@GST_API_VERSIO
  		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
  		--library=libgstsdp-@GST_API_VERSION@.la \
  		--include=Gst-@GST_API_VERSION@ \
@@ -138,10 +140,10 @@
  		--pkg-export gstreamer-sdp-@GST_API_VERSION@ \
  		--output $@ \
 diff --git a/gst-libs/gst/tag/Makefile.am b/gst-libs/gst/tag/Makefile.am
-index c534a4d..cafafd3 100644
+index 0247c33..c86515b 100644
 --- a/gst-libs/gst/tag/Makefile.am
 +++ b/gst-libs/gst/tag/Makefile.am
-@@ -45,7 +45,7 @@ GstTag-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgsttag-@GST_API_VERSIO
+@@ -66,7 +66,7 @@ GstTag-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgsttag-@GST_API_VERSIO
  		--library=libgsttag-@GST_API_VERSION@.la \
  		--include=Gst-@GST_API_VERSION@ \
  		--include=GstBase-@GST_API_VERSION@ \
@@ -151,10 +153,10 @@
  		--pkg gstreamer-base-@GST_API_VERSION@ \
  		--pkg-export gstreamer-tag-@GST_API_VERSION@ \
 diff --git a/gst-libs/gst/video/Makefile.am b/gst-libs/gst/video/Makefile.am
-index 5d31fa1..ac64eb3 100644
+index 9fc1ccf..0f8455f 100644
 --- a/gst-libs/gst/video/Makefile.am
 +++ b/gst-libs/gst/video/Makefile.am
-@@ -116,7 +116,7 @@ GstVideo-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstvideo-@GST_API_VE
+@@ -124,7 +124,7 @@ GstVideo-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstvideo-@GST_API_VE
  		--library=libgstvideo-@GST_API_VERSION@.la \
  		--include=Gst-@GST_API_VERSION@ \
  		--include=GstBase-@GST_API_VERSION@ \
@@ -163,6 +165,3 @@
  		--pkg gstreamer-@GST_API_VERSION@ \
  		--pkg gstreamer-base-@GST_API_VERSION@ \
  		--pkg-export gstreamer-video-@GST_API_VERSION@ \
--- 
-2.6.2
-
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0001-gstreamer-gl.pc.in-don-t-append-GL_CFLAGS-to-CFLAGS.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0001-gstreamer-gl.pc.in-don-t-append-GL_CFLAGS-to-CFLAGS.patch
new file mode 100644
index 0000000..251dc17
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0001-gstreamer-gl.pc.in-don-t-append-GL_CFLAGS-to-CFLAGS.patch
@@ -0,0 +1,29 @@
+From 61a672e79c8cb1aeeeda4c968997c577ac73a8f3 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Fri, 12 May 2017 16:47:12 +0300
+Subject: [PATCH] gstreamer-gl.pc.in: don't append GL_CFLAGS to CFLAGS
+
+Dependencies' include directories should not be added in this way;
+it causes problems when cross-compiling in sysroot environments.
+
+Upstream-Status: Pending
+
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+Signed-off-by: Maxin B. John <maxin.john@intel.com>
+---
+ pkgconfig/gstreamer-gl.pc.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/pkgconfig/gstreamer-gl.pc.in b/pkgconfig/gstreamer-gl.pc.in
+index dc672a9..8c290ba 100644
+--- a/pkgconfig/gstreamer-gl.pc.in
++++ b/pkgconfig/gstreamer-gl.pc.in
+@@ -13,4 +13,4 @@ Version: @VERSION@
+ Requires: gstreamer-video-@GST_API_VERSION@ gstreamer-base-@GST_API_VERSION@ gstreamer-@GST_API_VERSION@
+ 
+ Libs: -L${libdir} -lgstgl-@GST_API_VERSION@
+-Cflags: -I${includedir} -I${libdir}/gstreamer-@GST_API_VERSION@/include @GL_CFLAGS@
++Cflags: -I${includedir} -I${libdir}/gstreamer-@GST_API_VERSION@/include
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0002-Makefile.am-prefix-calls-to-pkg-config-with-PKG_CONF.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0002-Makefile.am-prefix-calls-to-pkg-config-with-PKG_CONF.patch
index 6616e2c..2e1190b 100644
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0002-Makefile.am-prefix-calls-to-pkg-config-with-PKG_CONF.patch
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0002-Makefile.am-prefix-calls-to-pkg-config-with-PKG_CONF.patch
@@ -1,16 +1,18 @@
-From 990b653c7b6de1937ec759019982d6c5f15770f7 Mon Sep 17 00:00:00 2001
+From 9601fc0cd6751a1affdc8717217b95931db31d7f Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Mon, 26 Oct 2015 16:38:18 +0200
-Subject: [PATCH 2/4] Makefile.am: prefix calls to pkg-config with
+Date: Thu, 5 Apr 2018 10:26:25 +0800
+Subject: [PATCH] Makefile.am: prefix calls to pkg-config with
  PKG_CONFIG_SYSROOT_DIR
 
 Upstream-Status: Pending [review on oe-core maillist]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+
 ---
  gst-libs/gst/allocators/Makefile.am |  4 ++--
  gst-libs/gst/app/Makefile.am        |  4 ++--
  gst-libs/gst/audio/Makefile.am      | 12 ++++++------
- gst-libs/gst/fft/Makefile.am        |  4 ++--
+ gst-libs/gst/gl/Makefile.am         |  8 ++++----
  gst-libs/gst/pbutils/Makefile.am    | 12 ++++++------
  gst-libs/gst/riff/Makefile.am       |  8 ++++----
  gst-libs/gst/rtp/Makefile.am        |  8 ++++----
@@ -18,13 +20,13 @@
  gst-libs/gst/sdp/Makefile.am        |  4 ++--
  gst-libs/gst/tag/Makefile.am        |  8 ++++----
  gst-libs/gst/video/Makefile.am      |  8 ++++----
- 11 files changed, 38 insertions(+), 38 deletions(-)
+ 11 files changed, 40 insertions(+), 40 deletions(-)
 
-Index: gst-plugins-base-1.12.3/gst-libs/gst/allocators/Makefile.am
-===================================================================
---- gst-plugins-base-1.12.3.orig/gst-libs/gst/allocators/Makefile.am
-+++ gst-plugins-base-1.12.3/gst-libs/gst/allocators/Makefile.am
-@@ -36,7 +36,7 @@ GstAllocators-@GST_API_VERSION@.gir: $(I
+diff --git a/gst-libs/gst/allocators/Makefile.am b/gst-libs/gst/allocators/Makefile.am
+index 1ecc950..d6417ac 100644
+--- a/gst-libs/gst/allocators/Makefile.am
++++ b/gst-libs/gst/allocators/Makefile.am
+@@ -39,7 +39,7 @@ GstAllocators-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstallocators-@
  		--c-include "gst/allocators/allocators.h" \
  		-I$(top_srcdir)/gst-libs \
  		-I$(top_builddir)/gst-libs \
@@ -33,7 +35,7 @@
  		--library=libgstallocators-@GST_API_VERSION@.la \
  		--include=Gst-@GST_API_VERSION@ \
  		--libtool="$(LIBTOOL)" \
-@@ -60,7 +60,7 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=
+@@ -63,7 +63,7 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
  		$(INTROSPECTION_COMPILER) \
  		--includedir=$(srcdir) \
  		--includedir=$(builddir) \
@@ -42,11 +44,11 @@
  		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
  
  CLEANFILES = $(BUILT_GIRSOURCES) $(typelibs_DATA)
-Index: gst-plugins-base-1.12.3/gst-libs/gst/app/Makefile.am
-===================================================================
---- gst-plugins-base-1.12.3.orig/gst-libs/gst/app/Makefile.am
-+++ gst-plugins-base-1.12.3/gst-libs/gst/app/Makefile.am
-@@ -48,8 +48,8 @@ GstApp-@GST_API_VERSION@.gir: $(INTROSPE
+diff --git a/gst-libs/gst/app/Makefile.am b/gst-libs/gst/app/Makefile.am
+index 5bfd606..6441674 100644
+--- a/gst-libs/gst/app/Makefile.am
++++ b/gst-libs/gst/app/Makefile.am
+@@ -51,8 +51,8 @@ GstApp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstapp-@GST_API_VERSIO
  		--c-include "gst/app/app.h" \
  		-I$(top_srcdir)/gst-libs \
  		-I$(top_builddir)/gst-libs \
@@ -57,11 +59,11 @@
  		--library=libgstapp-@GST_API_VERSION@.la \
  		--include=Gst-@GST_API_VERSION@ \
  		--include=GstBase-@GST_API_VERSION@ \
-Index: gst-plugins-base-1.12.3/gst-libs/gst/audio/Makefile.am
-===================================================================
---- gst-plugins-base-1.12.3.orig/gst-libs/gst/audio/Makefile.am
-+++ gst-plugins-base-1.12.3/gst-libs/gst/audio/Makefile.am
-@@ -167,12 +167,12 @@ GstAudio-@GST_API_VERSION@.gir: $(INTROS
+diff --git a/gst-libs/gst/audio/Makefile.am b/gst-libs/gst/audio/Makefile.am
+index 7fb65f2..5379f79 100644
+--- a/gst-libs/gst/audio/Makefile.am
++++ b/gst-libs/gst/audio/Makefile.am
+@@ -174,12 +174,12 @@ GstAudio-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstaudio-@GST_API_VE
  		-I$(top_srcdir)/gst-libs \
  		-I$(top_builddir)/gst-libs \
  		--c-include "gst/audio/audio.h" \
@@ -78,7 +80,7 @@
  		--library-path="$(top_builddir)/gst-libs/gst/tag/" \
  		--include=Gst-@GST_API_VERSION@ \
  		--include=GstBase-@GST_API_VERSION@ \
-@@ -201,8 +201,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=
+@@ -208,8 +208,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
  		--includedir=$(srcdir) \
  		--includedir=$(builddir) \
  		--includedir="$(top_builddir)/gst-libs/gst/tag/" \
@@ -89,33 +91,38 @@
  		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
  
  CLEANFILES += $(BUILT_GIRSOURCES) $(typelibs_DATA)
-Index: gst-plugins-base-1.12.3/gst-libs/gst/fft/Makefile.am
-===================================================================
---- gst-plugins-base-1.12.3.orig/gst-libs/gst/fft/Makefile.am
-+++ gst-plugins-base-1.12.3/gst-libs/gst/fft/Makefile.am
-@@ -63,7 +63,7 @@ GstFft-@GST_API_VERSION@.gir: $(INTROSPE
- 		--c-include "gst/fft/fft.h" \
- 		-I$(top_srcdir)/gst-libs \
- 		-I$(top_builddir)/gst-libs \
+diff --git a/gst-libs/gst/gl/Makefile.am b/gst-libs/gst/gl/Makefile.am
+index 3276d7f..0cdfe26 100644
+--- a/gst-libs/gst/gl/Makefile.am
++++ b/gst-libs/gst/gl/Makefile.am
+@@ -186,9 +186,9 @@ GstGL-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstgl-@GST_API_VERSION@
+ 		$(GST_PLUGINS_BASE_CFLAGS) \
+ 		$(GL_CFLAGS) \
+ 		--add-include-path="$(top_builddir)/gst-libs/gst/video/" \
 -		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
+ 		--library-path="$(top_builddir)/gst-libs/gst/video/" \
 +		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
- 		--library=libgstfft-@GST_API_VERSION@.la \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
+ 		--library=libgstgl-@GST_API_VERSION@.la \
  		--include=Gst-@GST_API_VERSION@ \
- 		--libtool="$(LIBTOOL)" \
-@@ -87,7 +87,7 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=
- 		$(INTROSPECTION_COMPILER) \
+ 		--include=GstBase-@GST_API_VERSION@ \
+@@ -218,8 +218,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
  		--includedir=$(srcdir) \
  		--includedir=$(builddir) \
+ 		--includedir="$(top_builddir)/gst-libs/gst/video/" \
 -		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+-		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
 +		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
  		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
  
  CLEANFILES = $(BUILT_GIRSOURCES) $(typelibs_DATA)
-Index: gst-plugins-base-1.12.3/gst-libs/gst/pbutils/Makefile.am
-===================================================================
---- gst-plugins-base-1.12.3.orig/gst-libs/gst/pbutils/Makefile.am
-+++ gst-plugins-base-1.12.3/gst-libs/gst/pbutils/Makefile.am
-@@ -85,14 +85,14 @@ GstPbutils-@GST_API_VERSION@.gir: $(INTR
+diff --git a/gst-libs/gst/pbutils/Makefile.am b/gst-libs/gst/pbutils/Makefile.am
+index 35a6e44..49d6894 100644
+--- a/gst-libs/gst/pbutils/Makefile.am
++++ b/gst-libs/gst/pbutils/Makefile.am
+@@ -88,14 +88,14 @@ GstPbutils-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstpbutils-@GST_AP
  		--c-include "gst/pbutils/pbutils.h" \
  		-I$(top_srcdir)/gst-libs \
  		-I$(top_builddir)/gst-libs \
@@ -134,7 +141,7 @@
  		--library-path="$(top_builddir)/gst-libs/gst/tag/" \
  		--library-path="$(top_builddir)/gst-libs/gst/video/" \
  		--library-path="$(top_builddir)/gst-libs/gst/audio/" \
-@@ -125,8 +125,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=
+@@ -128,8 +128,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
  		$(INTROSPECTION_COMPILER) \
  		--includedir=$(srcdir) \
  		--includedir=$(builddir) \
@@ -145,11 +152,11 @@
  		--includedir="$(top_builddir)/gst-libs/gst/tag/" \
  		--includedir="$(top_builddir)/gst-libs/gst/video/" \
  		--includedir="$(top_builddir)/gst-libs/gst/audio/" \
-Index: gst-plugins-base-1.12.3/gst-libs/gst/riff/Makefile.am
-===================================================================
---- gst-plugins-base-1.12.3.orig/gst-libs/gst/riff/Makefile.am
-+++ gst-plugins-base-1.12.3/gst-libs/gst/riff/Makefile.am
-@@ -42,8 +42,8 @@ libgstriff_@GST_API_VERSION@_la_LDFLAGS
+diff --git a/gst-libs/gst/riff/Makefile.am b/gst-libs/gst/riff/Makefile.am
+index e66ef4f..c8c588a 100644
+--- a/gst-libs/gst/riff/Makefile.am
++++ b/gst-libs/gst/riff/Makefile.am
+@@ -43,8 +43,8 @@ libgstriff_@GST_API_VERSION@_la_LDFLAGS = $(GST_LIB_LDFLAGS) $(GST_ALL_LDFLAGS)
  #		--c-include "gst/riff/riff.h" \
  #		--add-include-path=$(builddir)/../tag \
  #		--add-include-path=$(builddir)/../audio \
@@ -160,7 +167,7 @@
  #		--library=libgstriff-@GST_API_VERSION@.la \
  #		--include=GstAudio-@GST_API_VERSION@ \
  #		--include=GstTag-@GST_API_VERSION@ \
-@@ -74,8 +74,8 @@ libgstriff_@GST_API_VERSION@_la_LDFLAGS
+@@ -75,8 +75,8 @@ libgstriff_@GST_API_VERSION@_la_LDFLAGS = $(GST_LIB_LDFLAGS) $(GST_ALL_LDFLAGS)
  #		--includedir=$(builddir) \
  #		--includedir=$(builddir)/../tag \
  #		--includedir=$(builddir)/../audio \
@@ -171,11 +178,11 @@
  #		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
  #
  #CLEANFILES = $(BUILT_GIRSOURCES) $(typelibs_DATA)
-Index: gst-plugins-base-1.12.3/gst-libs/gst/rtp/Makefile.am
-===================================================================
---- gst-plugins-base-1.12.3.orig/gst-libs/gst/rtp/Makefile.am
-+++ gst-plugins-base-1.12.3/gst-libs/gst/rtp/Makefile.am
-@@ -61,8 +61,8 @@ GstRtp-@GST_API_VERSION@.gir: $(INTROSPE
+diff --git a/gst-libs/gst/rtp/Makefile.am b/gst-libs/gst/rtp/Makefile.am
+index 77ebeeb..9aee788 100644
+--- a/gst-libs/gst/rtp/Makefile.am
++++ b/gst-libs/gst/rtp/Makefile.am
+@@ -64,8 +64,8 @@ GstRtp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstrtp-@GST_API_VERSIO
  		--c-include "gst/rtp/rtp.h" \
  		-I$(top_builddir)/gst-libs \
  		-I$(top_srcdir)/gst-libs \
@@ -186,7 +193,7 @@
  		--library=libgstrtp-@GST_API_VERSION@.la \
  		--include=Gst-@GST_API_VERSION@ \
  		--include=GstBase-@GST_API_VERSION@ \
-@@ -89,8 +89,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=
+@@ -92,8 +92,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
  		$(INTROSPECTION_COMPILER) \
  		--includedir=$(srcdir) \
  		--includedir=$(builddir) \
@@ -197,11 +204,11 @@
  		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
  
  CLEANFILES += $(BUILT_GIRSOURCES) $(typelibs_DATA)
-Index: gst-plugins-base-1.12.3/gst-libs/gst/rtsp/Makefile.am
-===================================================================
---- gst-plugins-base-1.12.3.orig/gst-libs/gst/rtsp/Makefile.am
-+++ gst-plugins-base-1.12.3/gst-libs/gst/rtsp/Makefile.am
-@@ -68,7 +68,7 @@ GstRtsp-@GST_API_VERSION@.gir: $(INTROSP
+diff --git a/gst-libs/gst/rtsp/Makefile.am b/gst-libs/gst/rtsp/Makefile.am
+index db9d0fd..79027cb 100644
+--- a/gst-libs/gst/rtsp/Makefile.am
++++ b/gst-libs/gst/rtsp/Makefile.am
+@@ -71,7 +71,7 @@ GstRtsp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstrtsp-@GST_API_VERS
  		-I$(top_builddir)/gst-libs \
  		-I$(top_srcdir)/gst-libs \
  		--add-include-path=$(builddir)/../sdp \
@@ -210,7 +217,7 @@
  		--library=libgstrtsp-@GST_API_VERSION@.la \
  		--include=Gio-2.0 \
  		--include=Gst-@GST_API_VERSION@ \
-@@ -98,7 +98,7 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=
+@@ -101,7 +101,7 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
  		--includedir=$(srcdir) \
  		--includedir=$(builddir) \
  		--includedir=$(builddir)/../sdp \
@@ -219,11 +226,11 @@
  		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
  
  CLEANFILES += $(BUILT_GIRSOURCES) $(typelibs_DATA)
-Index: gst-plugins-base-1.12.3/gst-libs/gst/sdp/Makefile.am
-===================================================================
---- gst-plugins-base-1.12.3.orig/gst-libs/gst/sdp/Makefile.am
-+++ gst-plugins-base-1.12.3/gst-libs/gst/sdp/Makefile.am
-@@ -30,7 +30,7 @@ GstSdp-@GST_API_VERSION@.gir: $(INTROSPE
+diff --git a/gst-libs/gst/sdp/Makefile.am b/gst-libs/gst/sdp/Makefile.am
+index 6e05cc7..c7cf514 100644
+--- a/gst-libs/gst/sdp/Makefile.am
++++ b/gst-libs/gst/sdp/Makefile.am
+@@ -31,7 +31,7 @@ GstSdp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstsdp-@GST_API_VERSIO
  		--warn-all \
  		--c-include "gst/sdp/sdp.h" \
  		-I$(top_srcdir)/gst-libs \
@@ -232,7 +239,7 @@
  		--library=libgstsdp-@GST_API_VERSION@.la \
  		--include=Gst-@GST_API_VERSION@ \
  		--libtool="$(LIBTOOL)" \
-@@ -54,7 +54,7 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=
+@@ -55,7 +55,7 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
  		$(INTROSPECTION_COMPILER) \
  		--includedir=$(srcdir) \
  		--includedir=$(builddir) \
@@ -241,11 +248,11 @@
  		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
  
  CLEANFILES = $(BUILT_GIRSOURCES) $(typelibs_DATA)
-Index: gst-plugins-base-1.12.3/gst-libs/gst/tag/Makefile.am
-===================================================================
---- gst-plugins-base-1.12.3.orig/gst-libs/gst/tag/Makefile.am
-+++ gst-plugins-base-1.12.3/gst-libs/gst/tag/Makefile.am
-@@ -59,8 +59,8 @@ GstTag-@GST_API_VERSION@.gir: $(INTROSPE
+diff --git a/gst-libs/gst/tag/Makefile.am b/gst-libs/gst/tag/Makefile.am
+index c86515b..363e6d2 100644
+--- a/gst-libs/gst/tag/Makefile.am
++++ b/gst-libs/gst/tag/Makefile.am
+@@ -61,8 +61,8 @@ GstTag-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgsttag-@GST_API_VERSIO
  		--c-include "gst/tag/tag.h" \
  		-I$(top_srcdir)/gst-libs \
  		-I$(top_builddir)/gst-libs \
@@ -256,7 +263,7 @@
  		--library=libgsttag-@GST_API_VERSION@.la \
  		--include=Gst-@GST_API_VERSION@ \
  		--include=GstBase-@GST_API_VERSION@ \
-@@ -87,8 +87,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=
+@@ -89,8 +89,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
  		$(INTROSPECTION_COMPILER) \
  		--includedir=$(srcdir) \
  		--includedir=$(builddir) \
@@ -267,11 +274,11 @@
  		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
  
  CLEANFILES += $(BUILT_GIRSOURCES) $(typelibs_DATA)
-Index: gst-plugins-base-1.12.3/gst-libs/gst/video/Makefile.am
-===================================================================
---- gst-plugins-base-1.12.3.orig/gst-libs/gst/video/Makefile.am
-+++ gst-plugins-base-1.12.3/gst-libs/gst/video/Makefile.am
-@@ -116,8 +116,8 @@ GstVideo-@GST_API_VERSION@.gir: $(INTROS
+diff --git a/gst-libs/gst/video/Makefile.am b/gst-libs/gst/video/Makefile.am
+index 0f8455f..8c9955c 100644
+--- a/gst-libs/gst/video/Makefile.am
++++ b/gst-libs/gst/video/Makefile.am
+@@ -119,8 +119,8 @@ GstVideo-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstvideo-@GST_API_VE
  		--c-include "gst/video/video.h" \
  		-I$(top_srcdir)/gst-libs \
  		-I$(top_builddir)/gst-libs \
@@ -282,7 +289,7 @@
  		--library=libgstvideo-@GST_API_VERSION@.la \
  		--include=Gst-@GST_API_VERSION@ \
  		--include=GstBase-@GST_API_VERSION@ \
-@@ -144,8 +144,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=
+@@ -147,8 +147,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
  		$(INTROSPECTION_COMPILER) \
  		--includedir=$(srcdir) \
  		--includedir=$(builddir) \
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0003-riff-add-missing-include-directories-when-calling-in.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0003-riff-add-missing-include-directories-when-calling-in.patch
index 9b66f7f..98ffdb1 100644
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0003-riff-add-missing-include-directories-when-calling-in.patch
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0003-riff-add-missing-include-directories-when-calling-in.patch
@@ -1,20 +1,21 @@
-From 3c2c2d5dd08aa30ed0e8acd8566ec99412bb8209 Mon Sep 17 00:00:00 2001
+From b9765efb1696e3e2e79f2955f759be199fe34882 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Mon, 26 Oct 2015 17:29:37 +0200
-Subject: [PATCH 3/4] riff: add missing include directories when calling
+Subject: [PATCH] riff: add missing include directories when calling
  introspection scanner
 
 Upstream-Status: Pending [review on oe-core maillist]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
 ---
  gst-libs/gst/riff/Makefile.am | 2 ++
  1 file changed, 2 insertions(+)
 
 diff --git a/gst-libs/gst/riff/Makefile.am b/gst-libs/gst/riff/Makefile.am
-index 0a115cc..5057a58 100644
+index c8c588a..c096453 100644
 --- a/gst-libs/gst/riff/Makefile.am
 +++ b/gst-libs/gst/riff/Makefile.am
-@@ -39,6 +39,8 @@ libgstriff_@GST_API_VERSION@_la_LDFLAGS = $(GST_LIB_LDFLAGS) $(GST_ALL_LDFLAGS)
+@@ -41,6 +41,8 @@ libgstriff_@GST_API_VERSION@_la_LDFLAGS = $(GST_LIB_LDFLAGS) $(GST_ALL_LDFLAGS)
  #		--strip-prefix=Gst \
  #		--warn-all \
  #		--c-include "gst/riff/riff.h" \
@@ -23,6 +24,3 @@
  #		--add-include-path=$(builddir)/../tag \
  #		--add-include-path=$(builddir)/../audio \
  #		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
--- 
-2.6.2
-
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0003-ssaparse-enhance-SSA-text-lines-parsing.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0003-ssaparse-enhance-SSA-text-lines-parsing.patch
index 9fbebd5..9e95524 100644
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0003-ssaparse-enhance-SSA-text-lines-parsing.patch
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0003-ssaparse-enhance-SSA-text-lines-parsing.patch
@@ -1,7 +1,7 @@
-From be6163cfa3a255493f9d75bad9541cbfe1723fee Mon Sep 17 00:00:00 2001
+From 918c96b24d10f61b7455b4cef3bab490849d0d77 Mon Sep 17 00:00:00 2001
 From: Mingke Wang <mingke.wang@freescale.com>
 Date: Thu, 19 Mar 2015 14:17:10 +0800
-Subject: [PATCH 3/4] ssaparse: enhance SSA text lines parsing.
+Subject: [PATCH] ssaparse: enhance SSA text lines parsing.
 
 some parser will pass in the original ssa text line which starts with "Dialog:"
 and there's are maybe multiple Dialog lines in one input buffer.
@@ -10,13 +10,18 @@
 
 Signed-off-by: Mingke Wang <mingke.wang@freescale.com>
 
+---
+ gst/subparse/gstssaparse.c | 150 ++++++++++++++++++++++++++++++++++++++++-----
+ 1 file changed, 134 insertions(+), 16 deletions(-)
+ mode change 100644 => 100755 gst/subparse/gstssaparse.c
+
 diff --git a/gst/subparse/gstssaparse.c b/gst/subparse/gstssaparse.c
 old mode 100644
 new mode 100755
-index 06ecef9..0ab5dce
+index c849c08..4b9636c
 --- a/gst/subparse/gstssaparse.c
 +++ b/gst/subparse/gstssaparse.c
-@@ -260,6 +260,7 @@ gst_ssa_parse_remove_override_codes (GstSsaParse * parse, gchar * txt)
+@@ -262,6 +262,7 @@ gst_ssa_parse_remove_override_codes (GstSsaParse * parse, gchar * txt)
   * gst_ssa_parse_push_line:
   * @parse: caller element
   * @txt: text to push
@@ -24,7 +29,7 @@
   * @start: timestamp for the buffer
   * @duration: duration for the buffer
   *
-@@ -269,27 +270,133 @@ gst_ssa_parse_remove_override_codes (GstSsaParse * parse, gchar * txt)
+@@ -271,27 +272,133 @@ gst_ssa_parse_remove_override_codes (GstSsaParse * parse, gchar * txt)
   * Returns: result of the push of the created buffer
   */
  static GstFlowReturn
@@ -169,7 +174,7 @@
    GST_LOG_OBJECT (parse, "Text : %s", t);
  
    if (gst_ssa_parse_remove_override_codes (parse, t)) {
-@@ -307,13 +414,22 @@ gst_ssa_parse_push_line (GstSsaParse * parse, gchar * txt,
+@@ -309,13 +416,22 @@ gst_ssa_parse_push_line (GstSsaParse * parse, gchar * txt,
    gst_buffer_fill (buf, 0, escaped, len + 1);
    gst_buffer_set_size (buf, len);
    g_free (escaped);
@@ -196,7 +201,7 @@
  
    ret = gst_pad_push (parse->srcpad, buf);
  
-@@ -333,6 +449,7 @@ gst_ssa_parse_chain (GstPad * sinkpad, GstObject * parent, GstBuffer * buf)
+@@ -335,6 +451,7 @@ gst_ssa_parse_chain (GstPad * sinkpad, GstObject * parent, GstBuffer * buf)
    GstClockTime ts;
    gchar *txt;
    GstMapInfo map;
@@ -204,7 +209,7 @@
  
    if (G_UNLIKELY (!parse->framed))
      goto not_framed;
-@@ -350,13 +467,14 @@ gst_ssa_parse_chain (GstPad * sinkpad, GstObject * parent, GstBuffer * buf)
+@@ -352,13 +469,14 @@ gst_ssa_parse_chain (GstPad * sinkpad, GstObject * parent, GstBuffer * buf)
    /* make double-sure it's 0-terminated and all */
    gst_buffer_map (buf, &map, GST_MAP_READ);
    txt = g_strndup ((gchar *) map.data, map.size);
@@ -220,6 +225,3 @@
  
    if (ret != GST_FLOW_OK && GST_CLOCK_TIME_IS_VALID (ts)) {
      GstSegment segment;
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0004-rtsp-drop-incorrect-reference-to-gstreamer-sdp-in-Ma.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0004-rtsp-drop-incorrect-reference-to-gstreamer-sdp-in-Ma.patch
index 4adf605..aaeb611 100644
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0004-rtsp-drop-incorrect-reference-to-gstreamer-sdp-in-Ma.patch
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0004-rtsp-drop-incorrect-reference-to-gstreamer-sdp-in-Ma.patch
@@ -1,20 +1,21 @@
-From 4330915d88dc4dd46eb4c28d756482b767c2747f Mon Sep 17 00:00:00 2001
+From 53b5868491cf99ee797192395dbfeb69df23edd2 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Mon, 26 Oct 2015 17:30:14 +0200
-Subject: [PATCH 4/4] rtsp: drop incorrect reference to gstreamer-sdp in
+Subject: [PATCH] rtsp: drop incorrect reference to gstreamer-sdp in
  Makefile.am
 
 Upstream-Status: Pending [review on oe-core maillist]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
 ---
  gst-libs/gst/rtsp/Makefile.am | 1 -
  1 file changed, 1 deletion(-)
 
 diff --git a/gst-libs/gst/rtsp/Makefile.am b/gst-libs/gst/rtsp/Makefile.am
-index 4f6d9f8..0afa370 100644
+index 79027cb..2987e23 100644
 --- a/gst-libs/gst/rtsp/Makefile.am
 +++ b/gst-libs/gst/rtsp/Makefile.am
-@@ -75,7 +75,6 @@ GstRtsp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstrtsp-@GST_API_VERS
+@@ -79,7 +79,6 @@ GstRtsp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstrtsp-@GST_API_VERS
  		--libtool="$(LIBTOOL)" \
  		--pkg gio-2.0 \
  		--pkg gstreamer-@GST_API_VERSION@ \
@@ -22,6 +23,3 @@
  		--pkg-export gstreamer-rtsp-@GST_API_VERSION@ \
  		--add-init-section="$(INTROSPECTION_INIT)" \
  		--output $@ \
--- 
-2.6.2
-
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0004-subparse-set-need_segment-after-sink-pad-received-GS.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0004-subparse-set-need_segment-after-sink-pad-received-GS.patch
deleted file mode 100644
index b924e38..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0004-subparse-set-need_segment-after-sink-pad-received-GS.patch
+++ /dev/null
@@ -1,69 +0,0 @@
-From ed09c8fd2c9c2b5384b72cc70af3728be6694e64 Mon Sep 17 00:00:00 2001
-From: Mingke Wang <mingke.wang@freescale.com>
-Date: Thu, 19 Mar 2015 14:20:26 +0800
-Subject: [PATCH 4/4] subparse: set need_segment after sink pad received
- GST_EVENT_SEGMENT
-
-subparse works in push mode, chain funciton will be called once
-up stream element finished the seeking and flushing.
-if set need_segment flag in src pad event handler, the segment
-event will be pushed earlier, result in the subtitle text will
-be send out to down stream from the beginning.
-
-Upstream-Status: Submitted [https://bugzilla.gnome.org/show_bug.cgi?id=747498]
-
-Signed-off-by: Mingke Wang <mingke.wang@freescale.com>
-
-diff --git a/gst/subparse/gstsubparse.c b/gst/subparse/gstsubparse.c
-old mode 100644
-new mode 100755
-index b565e93..7741ccc
---- a/gst/subparse/gstsubparse.c
-+++ b/gst/subparse/gstsubparse.c
-@@ -266,22 +266,20 @@ gst_sub_parse_src_event (GstPad * pad, GstObject * parent, GstEvent * event)
-         goto beach;
-       }
- 
-+      /* Apply the seek to our segment */
-+      gst_segment_do_seek (&self->segment, rate, format, flags,
-+          start_type, start, stop_type, stop, &update);
-+
-+      GST_DEBUG_OBJECT (self, "segment after seek: %" GST_SEGMENT_FORMAT,
-+          &self->segment);
-+
-       /* Convert that seek to a seeking in bytes at position 0,
-          FIXME: could use an index */
-       ret = gst_pad_push_event (self->sinkpad,
-           gst_event_new_seek (rate, GST_FORMAT_BYTES, flags,
-               GST_SEEK_TYPE_SET, 0, GST_SEEK_TYPE_NONE, 0));
- 
--      if (ret) {
--        /* Apply the seek to our segment */
--        gst_segment_do_seek (&self->segment, rate, format, flags,
--            start_type, start, stop_type, stop, &update);
--
--        GST_DEBUG_OBJECT (self, "segment after seek: %" GST_SEGMENT_FORMAT,
--            &self->segment);
--
--        self->need_segment = TRUE;
--      } else {
-+      if (!ret) {
-         GST_WARNING_OBJECT (self, "seek to 0 bytes failed");
-       }
- 
-@@ -1641,8 +1639,10 @@ gst_sub_parse_sink_event (GstPad * pad, GstObject * parent, GstEvent * event)
-       gst_event_parse_segment (event, &s);
-       if (s->format == GST_FORMAT_TIME)
-         gst_event_copy_segment (event, &self->segment);
--      GST_DEBUG_OBJECT (self, "newsegment (%s)",
--          gst_format_get_name (self->segment.format));
-+      GST_DEBUG_OBJECT (self, "newsegment (%s) %" GST_SEGMENT_FORMAT,
-+          gst_format_get_name (self->segment.format), &self->segment);
-+
-+      self->need_segment = TRUE;
- 
-       /* if not time format, we'll either start with a 0 timestamp anyway or
-        * it's following a seek in which case we'll have saved the requested
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0009-glimagesink-Downrank-to-marginal.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0009-glimagesink-Downrank-to-marginal.patch
similarity index 100%
rename from poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0009-glimagesink-Downrank-to-marginal.patch
rename to poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0009-glimagesink-Downrank-to-marginal.patch
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0010-gl-Add-switch-for-explicitely-enabling-disabling-GBM.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0010-gl-Add-switch-for-explicitely-enabling-disabling-GBM.patch
new file mode 100644
index 0000000..45ba507
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0010-gl-Add-switch-for-explicitely-enabling-disabling-GBM.patch
@@ -0,0 +1,70 @@
+From a1b59ca6b1781442f37ffc1b697635db126b3a22 Mon Sep 17 00:00:00 2001
+From: Carlos Rafael Giani <dv@pseudoterminal.org>
+Date: Thu, 19 Jul 2018 10:30:54 +0200
+Subject: [PATCH] gl: Add switch for explicitely enabling/disabling GBM support
+
+Upstream-Status: Submitted [https://bugzilla.gnome.org/show_bug.cgi?id=796833]
+
+Signed-off-by: Carlos Rafael Giani <dv@pseudoterminal.org>
+---
+ m4/gst-gl.m4 | 30 ++++++++++++++++++++++++++++--
+ 1 file changed, 28 insertions(+), 2 deletions(-)
+
+diff --git a/m4/gst-gl.m4 b/m4/gst-gl.m4
+index 1e9724094..aca5295cc 100644
+--- a/m4/gst-gl.m4
++++ b/m4/gst-gl.m4
+@@ -117,6 +117,15 @@ AC_ARG_ENABLE([dispmanx],
+        *) AC_MSG_ERROR([bad value ${enableval} for --enable-dispmanx]) ;;
+      esac],[NEED_DISPMANX=auto])
+ 
++AC_ARG_ENABLE([gbm],
++     [  --enable-gbm        Enable Mesa3D GBM support (requires EGL) @<:@default=auto@:>@],
++     [case "${enableval}" in
++       yes)  NEED_GBM=yes ;;
++       no)   NEED_GBM=no ;;
++       auto) NEED_GBM=auto ;;
++       *) AC_MSG_ERROR([bad value ${enableval} for --enable-gbm]) ;;
++     esac],[NEED_GBM=auto])
++
+ AG_GST_PKG_CHECK_MODULES(X11_XCB, x11-xcb)
+ save_CPPFLAGS="$CPPFLAGS"
+ save_LIBS="$LIBS"
+@@ -172,15 +181,32 @@ case $host in
+         AC_CHECK_LIB([EGL], [fbGetDisplay], [HAVE_VIV_FB_EGL=yes])
+     fi
+ 
+-    if test "x$HAVE_EGL" = "xyes"; then
++    if test "x$NEED_GBM" != "xno"; then
++      if test "x$HAVE_EGL" = "xyes"; then
+         PKG_CHECK_MODULES(DRM, libdrm >= 2.4.55, HAVE_DRM=yes, HAVE_DRM=no)
+         AC_SUBST(DRM_CFLAGS)
+         AC_SUBST(DRM_LIBS)
++        if test "x$NEED_GBM" = "xyes"; then
++          if test "x$HAVE_DRM" = "xno"; then
++            AC_MSG_ERROR([GBM support requested but libdrm is not available])
++          fi
++          if test "x$HAVE_GUDEV" = "xno"; then
++            AC_MSG_ERROR([GBM support requested but gudev is not available])
++          fi
++        fi
+         if test "x$HAVE_DRM" = "xyes" -a "x$HAVE_GUDEV" = "xyes"; then
+           PKG_CHECK_MODULES(GBM, gbm, HAVE_GBM_EGL=yes, HAVE_GBM_EGL=no)
++          if test "x$HAVE_GBM_EGL" = "xno" -a "x$NEED_GBM" = "xyes"; then
++            AC_MSG_ERROR([GBM support requested but gbm library is not available])
++          fi
+           AC_SUBST(GBM_CFLAGS)
+           AC_SUBST(GBM_LIBS)
+-       fi
++        fi
++      elif test "x$NEED_GBM" = "xyes"; then
++        AC_MSG_ERROR([GBM support requested but EGL is not available])
++      else
++        AC_MSG_NOTICE([GBM support requested but EGL is not available; not enabling GBM support])
++      fi
+     fi
+ 
+     dnl FIXME: Mali EGL depends on GLESv1 or GLESv2
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0011-gl-Add-switches-for-explicitely-enabling-disabling-P.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0011-gl-Add-switches-for-explicitely-enabling-disabling-P.patch
new file mode 100644
index 0000000..65d191a
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0011-gl-Add-switches-for-explicitely-enabling-disabling-P.patch
@@ -0,0 +1,109 @@
+From 092aadfc1df69c46d920b0cd39f98d363d6988b3 Mon Sep 17 00:00:00 2001
+From: Carlos Rafael Giani <dv@pseudoterminal.org>
+Date: Thu, 19 Jul 2018 11:16:05 +0200
+Subject: [PATCH] gl: Add switches for explicitely enabling/disabling PNG and
+ JPEG support
+
+Upstream-Status: Submitted [https://bugzilla.gnome.org/show_bug.cgi?id=796833]
+
+Signed-off-by: Carlos Rafael Giani <dv@pseudoterminal.org>
+---
+ m4/gst-gl.m4 | 66 ++++++++++++++++++++++++++++++++++++----------------
+ 1 file changed, 46 insertions(+), 20 deletions(-)
+
+diff --git a/m4/gst-gl.m4 b/m4/gst-gl.m4
+index 20b2233de..f8809981c 100644
+--- a/m4/gst-gl.m4
++++ b/m4/gst-gl.m4
+@@ -126,6 +126,24 @@ AC_ARG_ENABLE([gbm],
+        *) AC_MSG_ERROR([bad value ${enableval} for --enable-gbm]) ;;
+      esac],[NEED_GBM=auto])
+ 
++AC_ARG_ENABLE([png],
++     [  --enable-png        Enable libpng support @<:@default=auto@:>@],
++     [case "${enableval}" in
++       yes)  NEED_PNG=yes ;;
++       no)   NEED_PNG=no ;;
++       auto) NEED_PNG=auto ;;
++       *) AC_MSG_ERROR([bad value ${enableval} for --enable-png]) ;;
++     esac],[NEED_PNG=auto])
++
++AC_ARG_ENABLE([jpeg],
++     [  --enable-jpeg        Enable libjpeg support @<:@default=auto@:>@],
++     [case "${enableval}" in
++       yes)  NEED_JPEG=yes ;;
++       no)   NEED_JPEG=no ;;
++       auto) NEED_JPEG=auto ;;
++       *) AC_MSG_ERROR([bad value ${enableval} for --enable-jpeg]) ;;
++     esac],[NEED_JPEG=auto])
++
+ AG_GST_PKG_CHECK_MODULES(X11_XCB, x11-xcb)
+ save_CPPFLAGS="$CPPFLAGS"
+ save_LIBS="$LIBS"
+@@ -1043,9 +1061,13 @@ dnl Needed by plugins that use g_module_*() API
+ PKG_CHECK_MODULES(GMODULE_NO_EXPORT, gmodule-no-export-2.0)
+ 
+ dnl libpng is optional
+-PKG_CHECK_MODULES(LIBPNG, libpng >= 1.0, HAVE_PNG=yes, HAVE_PNG=no)
+-if test "x$HAVE_PNG" = "xyes"; then
+-  AC_DEFINE(HAVE_PNG, [1] , [Use libpng])
++if test "x$NEED_PNG" != "xno"; then
++  PKG_CHECK_MODULES(LIBPNG, libpng >= 1.0, HAVE_PNG=yes, HAVE_PNG=no)
++  if test "x$HAVE_PNG" = "xyes"; then
++    AC_DEFINE(HAVE_PNG, [1] , [Use libpng])
++  elif test "x$NEED_PNG" = "xyes"; then
++    AC_MSG_ERROR([libpng support requested but libpng is not available])
++  fi
+ fi
+ AC_SUBST(HAVE_PNG)
+ AC_SUBST(LIBPNG_LIBS)
+@@ -1053,25 +1075,29 @@ AC_SUBST(LIBPNG_CFLAGS)
+ 
+ dnl libjpeg is optional
+ AC_ARG_WITH(jpeg-mmx, [  --with-jpeg-mmx, path to MMX'ified JPEG library])
+-OLD_LIBS="$LIBS"
+-if test x$with_jpeg_mmx != x; then
+-  LIBS="$LIBS -L$with_jpeg_mmx"
+-fi
+-AC_CHECK_LIB(jpeg-mmx, jpeg_set_defaults, HAVE_JPEG="yes", HAVE_JPEG="no")
+-JPEG_LIBS="$LIBS -ljpeg-mmx"
+-LIBS="$OLD_LIBS"
+-if test x$HAVE_JPEG != xyes; then
+-  JPEG_LIBS="-ljpeg"
+-  AC_CHECK_LIB(jpeg, jpeg_set_defaults, HAVE_JPEG="yes", HAVE_JPEG="no")
+-fi
++if test "x$NEED_JPEG" != "xno"; then
++  OLD_LIBS="$LIBS"
++  if test x$with_jpeg_mmx != x; then
++    LIBS="$LIBS -L$with_jpeg_mmx"
++  fi
++  AC_CHECK_LIB(jpeg-mmx, jpeg_set_defaults, HAVE_JPEG="yes", HAVE_JPEG="no")
++  JPEG_LIBS="$LIBS -ljpeg-mmx"
++  LIBS="$OLD_LIBS"
++  if test x$HAVE_JPEG != xyes; then
++    JPEG_LIBS="-ljpeg"
++    AC_CHECK_LIB(jpeg, jpeg_set_defaults, HAVE_JPEG="yes", HAVE_JPEG="no")
++  fi
+ 
+-if test x$HAVE_JPEG = xyes; then
+-  AC_DEFINE(HAVE_JPEG, [1], [Use libjpeg])
+-else
+-  JPEG_LIBS=
++  if test x$HAVE_JPEG = xyes; then
++    AC_DEFINE(HAVE_JPEG, [1], [Use libjpeg])
++  elif test "x$NEED_JPEG" = "xyes"; then
++    AC_MSG_ERROR([libjpeg support requested but libjpeg is not available])
++  else
++    JPEG_LIBS=
++  fi
++  AC_SUBST(JPEG_LIBS)
++  AC_SUBST(HAVE_JPEG)
+ fi
+-AC_SUBST(JPEG_LIBS)
+-AC_SUBST(HAVE_JPEG)
+ ])
+ 
+ dnl --------------------------------------------------------------------------
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/get-caps-from-src-pad-when-query-caps.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/get-caps-from-src-pad-when-query-caps.patch
index c8e6287..a4727e2 100644
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/get-caps-from-src-pad-when-query-caps.patch
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/get-caps-from-src-pad-when-query-caps.patch
@@ -1,4 +1,4 @@
-From af0dac26f62aaceb4bf266720911953793e0fc5d Mon Sep 17 00:00:00 2001
+From 41de2ec64ab06bb58c82c1659adaa3811bc5bcf8 Mon Sep 17 00:00:00 2001
 From: zhouming <b42586@freescale.com>
 Date: Wed, 14 May 2014 10:16:20 +0800
 Subject: [PATCH] ENGR00312515: get caps from src pad when query caps
@@ -8,18 +8,19 @@
 Upstream-Status: Pending
 
 Signed-off-by: zhouming <b42586@freescale.com>
+
 ---
- gst-libs/gst/tag/gsttagdemux.c |   13 +++++++++++++
+ gst-libs/gst/tag/gsttagdemux.c | 13 +++++++++++++
  1 file changed, 13 insertions(+)
  mode change 100644 => 100755 gst-libs/gst/tag/gsttagdemux.c
 
 diff --git a/gst-libs/gst/tag/gsttagdemux.c b/gst-libs/gst/tag/gsttagdemux.c
 old mode 100644
 new mode 100755
-index 9b6c478..ae2294a
+index 8a127c8..71c5d78
 --- a/gst-libs/gst/tag/gsttagdemux.c
 +++ b/gst-libs/gst/tag/gsttagdemux.c
-@@ -1769,6 +1769,19 @@ gst_tag_demux_pad_query (GstPad * pad, GstObject * parent, GstQuery * query)
+@@ -1759,6 +1759,19 @@ gst_tag_demux_pad_query (GstPad * pad, GstObject * parent, GstQuery * query)
        }
        break;
      }
@@ -39,6 +40,3 @@
      default:
        res = gst_pad_query_default (pad, parent, query);
        break;
--- 
-1.7.9.5
-
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/link-with-libvchostif.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/link-with-libvchostif.patch
new file mode 100644
index 0000000..d5a7f6b
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/link-with-libvchostif.patch
@@ -0,0 +1,45 @@
+From 9866f51e5e0913f1e453eb574618bf7432f38cb6 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 11 Apr 2018 10:46:33 +0800
+Subject: [PATCH] Add -lvchostif to link when using -lEGL on rpi
+
+This is required because libEGL from userland uses sybols
+from this library.
+
+lib/libEGL.so.1.0.0                                                                                                                                                                                                                              121: 00000000     0 FUNC    GLOBAL DEFAULT  UND vc_dispmanx_element_add
+  1552: 00000000     0 FUNC    GLOBAL DEFAULT  UND vc_dispmanx_element_add
+
+These symbols are provided by libvchostif as seen below
+
+lib/libvchostif.so
+   252: 0000b161   192 FUNC    GLOBAL DEFAULT    9 vc_dispmanx_element_add
+   809: 0000b161   192 FUNC    GLOBAL DEFAULT    9 vc_dispmanx_element_add
+
+With this explicit link, plugins fail during runtime
+
+(gst-plugin-scanner:571): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-1.0/libgstomx.so': Error relocating /usr/lib/libgstgl-1.0.so.0: vc_dispmanx_element_add: symbol not found
+(gst-plugin-scanner:571): GStreamer-WARNING **: Failed to load plugin '/usr/lib/gstreamer-1.0/libgstopengl.so': Error relocating /usr/lib/libgstgl-1.0.so.0: vc_dispmanx_element_add: symbol not found
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+---
+ m4/gst-gl.m4 | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/m4/gst-gl.m4 b/m4/gst-gl.m4
+index 1e97240..ab7774c 100644
+--- a/m4/gst-gl.m4
++++ b/m4/gst-gl.m4
+@@ -231,7 +231,7 @@ case $host in
+                             HAVE_EGL=yes
+                             HAVE_GLES2=yes
+                             HAVE_EGL_RPI=yes
+-                            EGL_LIBS="-lbcm_host -lvcos -lvchiq_arm"
++                            EGL_LIBS="-lbcm_host -lvchostif -lvcos -lvchiq_arm"
+                             EGL_CFLAGS=""
+                             AC_DEFINE(USE_EGL_RPI, [1], [Use RPi platform])
+                           ])
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/make-gio_unix_2_0-dependency-configurable.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/make-gio_unix_2_0-dependency-configurable.patch
index 413eff0..23950b6 100644
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/make-gio_unix_2_0-dependency-configurable.patch
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/make-gio_unix_2_0-dependency-configurable.patch
@@ -1,4 +1,4 @@
-From 10d2a977ee1d469f0bf9059bb2d0b55fd2eecbac Mon Sep 17 00:00:00 2001
+From 7ffa6e3d00e1d8a060f3f4c2bb9a72691af05d79 Mon Sep 17 00:00:00 2001
 From: Andre McCurdy <armccurdy@gmail.com>
 Date: Wed, 20 Jan 2016 13:00:00 -0800
 Subject: [PATCH] make gio_unix_2_0 dependency configurable
@@ -17,16 +17,17 @@
 Upstream-Status: Pending
 
 Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
+
 ---
  configure.ac | 7 +++++++
  1 file changed, 7 insertions(+)
 
 diff --git a/configure.ac b/configure.ac
-index 9c52aeb..26cacd6 100644
+index 12807bc..35a0bf3 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -752,9 +752,16 @@ AC_SUBST(FT2_CFLAGS)
- fi dnl of EXT plugins
+@@ -806,9 +806,16 @@ AM_CONDITIONAL(HAVE_PNG, test "x$HAVE_PNG" = "xyes")
+ AM_CONDITIONAL(HAVE_JPEG, test "x$HAVE_JPEG" = "xyes")
  
  dnl *** gio-unix-2.0 for tests/check/pipelines/tcp.c ***
 +AC_ARG_ENABLE([gio_unix_2_0],
@@ -42,6 +43,3 @@
  AM_CONDITIONAL(USE_GIO_UNIX_2_0, test "x$HAVE_GIO_UNIX_2_0" = "xyes")
  
  dnl *** finalize CFLAGS, LDFLAGS, LIBS
--- 
-1.9.1
-
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.12.4.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.12.4.bb
deleted file mode 100644
index dd895bb..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.12.4.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-require gstreamer1.0-plugins-base.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=c54ce9345727175ff66d17b67ff51f58 \
-                    file://COPYING.LIB;md5=6762ed442b3822387a51c92d928ead0d \
-                    file://common/coverage/coverage-report.pl;beginline=2;endline=17;md5=a4e1830fce078028c8f0974161272607"
-
-SRC_URI = " \
-    http://gstreamer.freedesktop.org/src/gst-plugins-base/gst-plugins-base-${PV}.tar.xz \
-    file://get-caps-from-src-pad-when-query-caps.patch \
-    file://0003-ssaparse-enhance-SSA-text-lines-parsing.patch \
-    file://0004-subparse-set-need_segment-after-sink-pad-received-GS.patch \
-    file://make-gio_unix_2_0-dependency-configurable.patch \
-    file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch \
-"
-SRC_URI[md5sum] = "b35b04071f69b8ab69a7f3a497ff0131"
-SRC_URI[sha256sum] = "4c306b03df0212f1b8903784e29bb3493319ba19ebebf13b0c56a17870292282"
-
-S = "${WORKDIR}/gst-plugins-base-${PV}"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.14.2.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.14.2.bb
new file mode 100644
index 0000000..dcea789
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.14.2.bb
@@ -0,0 +1,76 @@
+require gstreamer1.0-plugins.inc
+
+LICENSE = "GPLv2+ & LGPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=c54ce9345727175ff66d17b67ff51f58 \
+                    file://COPYING.LIB;md5=6762ed442b3822387a51c92d928ead0d \
+                    file://common/coverage/coverage-report.pl;beginline=2;endline=17;md5=a4e1830fce078028c8f0974161272607"
+
+SRC_URI = " \
+            http://gstreamer.freedesktop.org/src/gst-plugins-base/gst-plugins-base-${PV}.tar.xz \
+            file://get-caps-from-src-pad-when-query-caps.patch \
+            file://0003-ssaparse-enhance-SSA-text-lines-parsing.patch \
+            file://make-gio_unix_2_0-dependency-configurable.patch \
+            file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch \
+            file://0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch \
+            file://0002-Makefile.am-prefix-calls-to-pkg-config-with-PKG_CONF.patch \
+            file://0003-riff-add-missing-include-directories-when-calling-in.patch \
+            file://0004-rtsp-drop-incorrect-reference-to-gstreamer-sdp-in-Ma.patch \
+            file://0009-glimagesink-Downrank-to-marginal.patch \
+            file://0001-gstreamer-gl.pc.in-don-t-append-GL_CFLAGS-to-CFLAGS.patch \
+            file://0010-gl-Add-switch-for-explicitely-enabling-disabling-GBM.patch \
+            file://0011-gl-Add-switches-for-explicitely-enabling-disabling-P.patch \
+            file://link-with-libvchostif.patch \
+            "
+SRC_URI[md5sum] = "8bc790d623350cd8eac68d3a13d79f7d"
+SRC_URI[sha256sum] = "a4b7e80ba869f599307449b17c9e00b5d1e94d3ba1d8a1a386b8770b2ef01c7c"
+
+S = "${WORKDIR}/gst-plugins-base-${PV}"
+
+DEPENDS += "iso-codes util-linux"
+
+inherit gettext
+
+PACKAGES_DYNAMIC =+ "^libgst.*"
+
+# opengl packageconfig factored out to make it easy for distros
+# and BSP layers to pick either (desktop) opengl, gles2, or no GL
+PACKAGECONFIG_GL ?= "${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'gles2 egl', '', d)}"
+
+PACKAGECONFIG ??= " \
+    ${GSTREAMER_ORC} \
+    ${PACKAGECONFIG_GL} \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'alsa x11', d)} \
+    gio-unix-2.0 jpeg ogg pango png theora vorbis zlib \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'wayland egl', '', d)} \
+"
+
+X11DEPENDS = "virtual/libx11 libsm libxrender libxv"
+X11ENABLEOPTS = "--enable-x --enable-xvideo --enable-xshm"
+X11DISABLEOPTS = "--disable-x --disable-xvideo --disable-xshm"
+
+PACKAGECONFIG[alsa]         = "--enable-alsa,--disable-alsa,alsa-lib"
+PACKAGECONFIG[cdparanoia]   = "--enable-cdparanoia,--disable-cdparanoia,cdparanoia"
+PACKAGECONFIG[egl]          = "--enable-egl,--disable-egl,virtual/egl"
+PACKAGECONFIG[gbm]          = "--enable-gbm,--disable-gbm,virtual/libgbm libgudev libdrm"
+PACKAGECONFIG[gio-unix-2.0] = "--enable-gio_unix_2_0,--disable-gio_unix_2_0,glib-2.0"
+PACKAGECONFIG[gles2]        = "--enable-gles2,--disable-gles2,virtual/libgles2"
+PACKAGECONFIG[ivorbis]      = "--enable-ivorbis,--disable-ivorbis,tremor"
+PACKAGECONFIG[jpeg]         = "--enable-jpeg,--disable-jpeg,jpeg"
+PACKAGECONFIG[ogg]          = "--enable-ogg,--disable-ogg,libogg"
+PACKAGECONFIG[opengl]       = "--enable-opengl,--disable-opengl,virtual/libgl libglu"
+PACKAGECONFIG[opus]         = "--enable-opus,--disable-opus,libopus"
+PACKAGECONFIG[pango]        = "--enable-pango,--disable-pango,pango"
+PACKAGECONFIG[png]          = "--enable-png,--disable-png,libpng"
+PACKAGECONFIG[theora]       = "--enable-theora,--disable-theora,libtheora"
+PACKAGECONFIG[visual]       = "--enable-libvisual,--disable-libvisual,libvisual"
+PACKAGECONFIG[vorbis]       = "--enable-vorbis,--disable-vorbis,libvorbis"
+PACKAGECONFIG[x11]          = "${X11ENABLEOPTS},${X11DISABLEOPTS},${X11DEPENDS}"
+PACKAGECONFIG[wayland]      = "--enable-wayland,--disable-wayland,wayland-native wayland wayland-protocols libdrm"
+PACKAGECONFIG[zlib]         = "--enable-zlib,--disable-zlib,zlib"
+
+FILES_${PN}-dev += "${libdir}/gstreamer-${LIBV}/include/gst/gl/gstglconfig.h"
+FILES_${MLPREFIX}libgsttag-1.0 += "${datadir}/gst-plugins-base/1.0/license-translations.dict"
+
+do_compile_prepend() {
+        export GIR_EXTRA_LIBS_PATH="${B}/gst-libs/gst/tag/.libs:${B}/gst-libs/gst/video/.libs:${B}/gst-libs/gst/audio/.libs:${B}/gst-libs/gst/rtp/.libs:${B}/gst-libs/gst/allocators/.libs"
+}
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-good.inc b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-good.inc
deleted file mode 100644
index 14c3d61..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-good.inc
+++ /dev/null
@@ -1,52 +0,0 @@
-require gstreamer1.0-plugins.inc
-
-LICENSE = "GPLv2+ & LGPLv2.1+"
-
-DEPENDS += "gstreamer1.0-plugins-base libcap zlib bzip2"
-
-inherit gettext
-
-PACKAGECONFIG ??= " \
-    ${GSTREAMER_ORC} \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'pulseaudio x11', d)} \
-    cairo flac gdk-pixbuf gudev jpeg libpng soup speex taglib v4l2 \
-"
-
-X11DEPENDS = "virtual/libx11 libsm libxrender libxfixes libxdamage"
-
-PACKAGECONFIG[cairo]      = "--enable-cairo,--disable-cairo,cairo"
-PACKAGECONFIG[dv1394]     = "--enable-dv1394,--disable-dv1394,libiec61883 libavc1394 libraw1394"
-PACKAGECONFIG[flac]       = "--enable-flac,--disable-flac,flac"
-PACKAGECONFIG[gdk-pixbuf] = "--enable-gdk_pixbuf,--disable-gdk_pixbuf,gdk-pixbuf"
-PACKAGECONFIG[gudev]      = "--with-gudev,--without-gudev,libgudev"
-PACKAGECONFIG[jack]       = "--enable-jack,--disable-jack,jack"
-PACKAGECONFIG[jpeg]       = "--enable-jpeg,--disable-jpeg,jpeg"
-PACKAGECONFIG[libpng]     = "--enable-libpng,--disable-libpng,libpng"
-PACKAGECONFIG[libv4l2]    = "--with-libv4l2,--without-libv4l2,v4l-utils"
-PACKAGECONFIG[pulseaudio] = "--enable-pulse,--disable-pulse,pulseaudio"
-PACKAGECONFIG[soup]       = "--enable-soup,--disable-soup,libsoup-2.4"
-PACKAGECONFIG[speex]      = "--enable-speex,--disable-speex,speex"
-PACKAGECONFIG[taglib]     = "--enable-taglib,--disable-taglib,taglib"
-PACKAGECONFIG[v4l2]       = "--enable-gst_v4l2 --enable-v4l2-probe,--disable-gst_v4l2"
-PACKAGECONFIG[vpx]        = "--enable-vpx,--disable-vpx,libvpx"
-PACKAGECONFIG[wavpack]    = "--enable-wavpack,--disable-wavpack,wavpack"
-PACKAGECONFIG[x11]        = "--enable-x,--disable-x,${X11DEPENDS}"
-
-EXTRA_OECONF += " \
-    --enable-bz2 \
-    --enable-oss \
-    --enable-zlib \
-    --disable-aalib \
-    --disable-aalibtest \
-    --disable-directsound \
-    --disable-libcaca \
-    --disable-libdv \
-    --disable-oss4 \
-    --disable-osx_audio \
-    --disable-osx_video \
-    --disable-shout2 \
-    --disable-sunaudio \
-    --disable-waveform \
-"
-
-FILES_${PN}-equalizer += "${datadir}/gstreamer-1.0/presets/*.prs"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-good_1.12.4.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-good_1.12.4.bb
deleted file mode 100644
index a060964..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-good_1.12.4.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-require gstreamer1.0-plugins-good.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=a6f89e2100d9b6cdffcea4f398e37343 \
-                    file://common/coverage/coverage-report.pl;beginline=2;endline=17;md5=a4e1830fce078028c8f0974161272607 \
-                    file://gst/replaygain/rganalysis.c;beginline=1;endline=23;md5=b60ebefd5b2f5a8e0cab6bfee391a5fe"
-
-SRC_URI = " \
-    http://gstreamer.freedesktop.org/src/gst-plugins-good/gst-plugins-good-${PV}.tar.xz \
-    file://0001-gstrtpmp4gpay-set-dafault-value-for-MPEG4-without-co.patch \
-    file://avoid-including-sys-poll.h-directly.patch \
-    file://ensure-valid-sentinel-for-gst_structure_get.patch \
-    file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch \
-"
-SRC_URI[md5sum] = "bdf4791a2b788ec6a149b81ff4032038"
-SRC_URI[sha256sum] = "649f49bec60892d47ee6731b92266974c723554da1c6649f21296097715eb957"
-
-S = "${WORKDIR}/gst-plugins-good-${PV}"
-
-RPROVIDES_${PN}-pulseaudio += "${PN}-pulse"
-RPROVIDES_${PN}-soup += "${PN}-souphttpsrc"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-good_1.14.2.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-good_1.14.2.bb
new file mode 100644
index 0000000..e035cc0
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-good_1.14.2.bb
@@ -0,0 +1,79 @@
+require gstreamer1.0-plugins.inc
+
+SRC_URI = " \
+            http://gstreamer.freedesktop.org/src/gst-plugins-good/gst-plugins-good-${PV}.tar.xz \
+            file://0001-gstrtpmp4gpay-set-dafault-value-for-MPEG4-without-co.patch \
+            file://avoid-including-sys-poll.h-directly.patch \
+            file://ensure-valid-sentinel-for-gst_structure_get.patch \
+            file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch \
+            "
+
+SRC_URI[md5sum] = "5b83b2828e31ce5b4a5c03c71e707ae7"
+SRC_URI[sha256sum] = "c0575e2811860bfff59b865b8d125153859a01f0615fa41e279b64d88d25caad"
+
+S = "${WORKDIR}/gst-plugins-good-${PV}"
+
+LICENSE = "GPLv2+ & LGPLv2.1+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=a6f89e2100d9b6cdffcea4f398e37343 \
+                    file://common/coverage/coverage-report.pl;beginline=2;endline=17;md5=a4e1830fce078028c8f0974161272607 \
+                    file://gst/replaygain/rganalysis.c;beginline=1;endline=23;md5=b60ebefd5b2f5a8e0cab6bfee391a5fe"
+
+DEPENDS += "gstreamer1.0-plugins-base libcap"
+RPROVIDES_${PN}-pulseaudio += "${PN}-pulse"
+RPROVIDES_${PN}-soup += "${PN}-souphttpsrc"
+
+inherit gettext
+
+PACKAGECONFIG ??= " \
+    ${GSTREAMER_ORC} \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'pulseaudio x11', d)} \
+    bz2 cairo flac gdk-pixbuf gudev jpeg lame libpng mpg123 soup speex taglib v4l2 zlib \
+"
+
+X11DEPENDS = "virtual/libx11 libsm libxrender libxfixes libxdamage"
+
+PACKAGECONFIG[bz2]        = "--enable-bz2,--disable-bz2,bzip2"
+PACKAGECONFIG[cairo]      = "--enable-cairo,--disable-cairo,cairo"
+PACKAGECONFIG[dv1394]     = "--enable-dv1394,--disable-dv1394,libiec61883 libavc1394 libraw1394"
+PACKAGECONFIG[flac]       = "--enable-flac,--disable-flac,flac"
+PACKAGECONFIG[gdk-pixbuf] = "--enable-gdk_pixbuf,--disable-gdk_pixbuf,gdk-pixbuf"
+PACKAGECONFIG[gtk]        = "--enable-gtk3,--disable-gtk3,gtk+3"
+PACKAGECONFIG[gudev]      = "--with-gudev,--without-gudev,libgudev"
+PACKAGECONFIG[jack]       = "--enable-jack,--disable-jack,jack"
+PACKAGECONFIG[jpeg]       = "--enable-jpeg,--disable-jpeg,jpeg"
+PACKAGECONFIG[lame]       = "--enable-lame,--disable-lame,lame"
+PACKAGECONFIG[libpng]     = "--enable-libpng,--disable-libpng,libpng"
+PACKAGECONFIG[libv4l2]    = "--with-libv4l2,--without-libv4l2,v4l-utils"
+PACKAGECONFIG[mpg123]     = "--enable-mpg123,--disable-mpg123,mpg123"
+PACKAGECONFIG[pulseaudio] = "--enable-pulse,--disable-pulse,pulseaudio"
+PACKAGECONFIG[soup]       = "--enable-soup,--disable-soup,libsoup-2.4"
+PACKAGECONFIG[speex]      = "--enable-speex,--disable-speex,speex"
+PACKAGECONFIG[taglib]     = "--enable-taglib,--disable-taglib,taglib"
+PACKAGECONFIG[v4l2]       = "--enable-gst_v4l2 --enable-v4l2-probe,--disable-gst_v4l2"
+PACKAGECONFIG[vpx]        = "--enable-vpx,--disable-vpx,libvpx"
+PACKAGECONFIG[wavpack]    = "--enable-wavpack,--disable-wavpack,wavpack"
+PACKAGECONFIG[x11]        = "--enable-x,--disable-x,${X11DEPENDS}"
+PACKAGECONFIG[zlib]       = "--enable-zlib,--disable-zlib,zlib"
+
+# qt5 support is disabled, because it is not present in OE core, and requires more work than
+# just adding a packageconfig (it requires access to moc, uic, rcc, and qmake paths).
+# This is better done in a separate qt5 layer (which then should add a "qt5" packageconfig
+# in a gstreamer1.0-plugins-good bbappend).
+
+EXTRA_OECONF += " \
+    --enable-oss \
+    --disable-aalib \
+    --disable-aalibtest \
+    --disable-directsound \
+    --disable-libcaca \
+    --disable-libdv \
+    --disable-oss4 \
+    --disable-osx_audio \
+    --disable-osx_video \
+    --disable-qt \
+    --disable-shout2 \
+    --disable-twolame \
+    --disable-waveform \
+"
+
+FILES_${PN}-equalizer += "${datadir}/gstreamer-1.0/presets/*.prs"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-ugly.inc b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-ugly.inc
deleted file mode 100644
index 60aa968..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-ugly.inc
+++ /dev/null
@@ -1,31 +0,0 @@
-require gstreamer1.0-plugins.inc
-
-LICENSE = "GPLv2+ & LGPLv2.1+ & LGPLv2+"
-LICENSE_FLAGS = "commercial"
-
-DEPENDS += "gstreamer1.0-plugins-base libid3tag"
-
-inherit gettext
-
-PACKAGECONFIG ??= " \
-    ${GSTREAMER_ORC} \
-    a52dec lame mpg123 mpeg2dec \
-"
-
-PACKAGECONFIG[a52dec]   = "--enable-a52dec,--disable-a52dec,liba52"
-PACKAGECONFIG[amrnb]    = "--enable-amrnb,--disable-amrnb,opencore-amr"
-PACKAGECONFIG[amrwb]    = "--enable-amrwb,--disable-amrwb,opencore-amr"
-PACKAGECONFIG[cdio]     = "--enable-cdio,--disable-cdio,libcdio"
-PACKAGECONFIG[dvdread]  = "--enable-dvdread,--disable-dvdread,libdvdread"
-PACKAGECONFIG[lame]     = "--enable-lame,--disable-lame,lame"
-PACKAGECONFIG[mpeg2dec] = "--enable-mpeg2dec,--disable-mpeg2dec,mpeg2dec"
-PACKAGECONFIG[mpg123]   = "--enable-mpg123,--disable-mpg123,mpg123"
-PACKAGECONFIG[x264]     = "--enable-x264,--disable-x264,x264"
-
-EXTRA_OECONF += " \
-    --disable-sidplay \
-    --disable-twolame \
-"
-
-FILES_${PN}-amrnb += "${datadir}/gstreamer-1.0/presets/GstAmrnbEnc.prs"
-FILES_${PN}-x264 += "${datadir}/gstreamer-1.0/presets/GstX264Enc.prs"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-ugly_1.12.4.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-ugly_1.12.4.bb
deleted file mode 100644
index f833351..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-ugly_1.12.4.bb
+++ /dev/null
@@ -1,13 +0,0 @@
-require gstreamer1.0-plugins-ugly.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=a6f89e2100d9b6cdffcea4f398e37343 \
-                    file://tests/check/elements/xingmux.c;beginline=1;endline=21;md5=4c771b8af188724855cb99cadd390068"
-
-SRC_URI = " \
-    http://gstreamer.freedesktop.org/src/gst-plugins-ugly/gst-plugins-ugly-${PV}.tar.xz \
-    file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch \
-"
-SRC_URI[md5sum] = "e2b836fb2747f6ae3a1a6f33a9d8c952"
-SRC_URI[sha256sum] = "1c165b8d888ed350acd8e6ac9f6fe06508e6fcc0a3afc6ccc9fbeb30df9be522"
-
-S = "${WORKDIR}/gst-plugins-ugly-${PV}"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-ugly_1.14.2.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-ugly_1.14.2.bb
new file mode 100644
index 0000000..0197269
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-ugly_1.14.2.bb
@@ -0,0 +1,40 @@
+require gstreamer1.0-plugins.inc
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=a6f89e2100d9b6cdffcea4f398e37343 \
+                    file://tests/check/elements/xingmux.c;beginline=1;endline=21;md5=4c771b8af188724855cb99cadd390068"
+
+LICENSE = "GPLv2+ & LGPLv2.1+ & LGPLv2+"
+LICENSE_FLAGS = "commercial"
+
+SRC_URI = " \
+            http://gstreamer.freedesktop.org/src/gst-plugins-ugly/gst-plugins-ugly-${PV}.tar.xz \
+            file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch \
+            "
+SRC_URI[md5sum] = "ea0a800c6421c3c3cdbed3d040b8ffd3"
+SRC_URI[sha256sum] = "55e097d9d93921fdcf7abb0ff92d23b21dd9098e632f1ba433603b3bd1cf3d69"
+
+S = "${WORKDIR}/gst-plugins-ugly-${PV}"
+
+DEPENDS += "gstreamer1.0-plugins-base libid3tag"
+
+inherit gettext
+
+PACKAGECONFIG ??= " \
+    ${GSTREAMER_ORC} \
+    a52dec mpeg2dec \
+"
+
+PACKAGECONFIG[a52dec]   = "--enable-a52dec,--disable-a52dec,liba52"
+PACKAGECONFIG[amrnb]    = "--enable-amrnb,--disable-amrnb,opencore-amr"
+PACKAGECONFIG[amrwb]    = "--enable-amrwb,--disable-amrwb,opencore-amr"
+PACKAGECONFIG[cdio]     = "--enable-cdio,--disable-cdio,libcdio"
+PACKAGECONFIG[dvdread]  = "--enable-dvdread,--disable-dvdread,libdvdread"
+PACKAGECONFIG[mpeg2dec] = "--enable-mpeg2dec,--disable-mpeg2dec,mpeg2dec"
+PACKAGECONFIG[x264]     = "--enable-x264,--disable-x264,x264"
+
+EXTRA_OECONF += " \
+    --disable-sidplay \
+"
+
+FILES_${PN}-amrnb += "${datadir}/gstreamer-1.0/presets/GstAmrnbEnc.prs"
+FILES_${PN}-x264 += "${datadir}/gstreamer-1.0/presets/GstX264Enc.prs"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-python.inc b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-python.inc
deleted file mode 100644
index 361f0bc..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-python.inc
+++ /dev/null
@@ -1,33 +0,0 @@
-SUMMARY = "Python bindings for GStreamer 1.0"
-HOMEPAGE = "http://cgit.freedesktop.org/gstreamer/gst-python/"
-SECTION = "multimedia"
-LICENSE = "LGPLv2.1"
-
-DEPENDS = "gstreamer1.0 python3-pygobject"
-RDEPENDS_${PN} += "gstreamer1.0 python3-pygobject"
-
-PNREAL = "gst-python"
-
-S = "${WORKDIR}/${PNREAL}-${PV}"
-
-inherit autotools pkgconfig distutils3-base upstream-version-is-even gobject-introspection
-
-do_install_append() {
-    # gstpythonplugin hardcodes the location of the libpython from the build
-    # workspace and then fails at runtime. We can override it using
-    # --with-libpython-dir=${libdir}, but it still fails because it looks for a
-    # symlinked library ending in .so instead of the actually library with
-    # LIBNAME.so.MAJOR.MINOR. Although we could patch the code to use the path
-    # we want, it will break again if the library version ever changes. We need
-    # to think about the best way of handling this and possibly consult
-    # upstream.
-    #
-    # Note that this particular find line is taken from the Debian packaging for
-    # gst-python1.0.
-    find "${D}" \
-        -name '*.pyc' -o \
-        -name '*.pyo' -o \
-        -name '*.la' -o \
-        -name 'libgstpythonplugin*' \
-        -delete
-}
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-python_1.12.4.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-python_1.12.4.bb
deleted file mode 100644
index faec356..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-python_1.12.4.bb
+++ /dev/null
@@ -1,7 +0,0 @@
-require gstreamer1.0-python.inc
-
-SRC_URI = "http://gstreamer.freedesktop.org/src/${PNREAL}/${PNREAL}-${PV}.tar.xz"
-SRC_URI[md5sum] = "f1fd046ea781736a794f9f552d77c50d"
-SRC_URI[sha256sum] = "20ce6af6615c9a440c1928c31259a78226516d06bf1a65f888c6d109826fa3ea"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=c34deae4e395ca07e725ab0076a5f740"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-python_1.14.2.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-python_1.14.2.bb
new file mode 100644
index 0000000..78c0046
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-python_1.14.2.bb
@@ -0,0 +1,39 @@
+SUMMARY = "Python bindings for GStreamer 1.0"
+HOMEPAGE = "http://cgit.freedesktop.org/gstreamer/gst-python/"
+SECTION = "multimedia"
+
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=c34deae4e395ca07e725ab0076a5f740"
+
+SRC_URI = "http://gstreamer.freedesktop.org/src/${PNREAL}/${PNREAL}-${PV}.tar.xz"
+SRC_URI[md5sum] = "5b0af1bd490d79a7d435b2be47568f8e"
+SRC_URI[sha256sum] = "dc40be5ab4f1a433ff3f0af2b3d2d79a363009020c41ec10f9747ba64200cb22"
+
+DEPENDS = "gstreamer1.0 python3-pygobject"
+RDEPENDS_${PN} += "gstreamer1.0 python3-pygobject"
+
+PNREAL = "gst-python"
+
+S = "${WORKDIR}/${PNREAL}-${PV}"
+
+inherit autotools pkgconfig distutils3-base upstream-version-is-even gobject-introspection
+
+do_install_append() {
+    # gstpythonplugin hardcodes the location of the libpython from the build
+    # workspace and then fails at runtime. We can override it using
+    # --with-libpython-dir=${libdir}, but it still fails because it looks for a
+    # symlinked library ending in .so instead of the actually library with
+    # LIBNAME.so.MAJOR.MINOR. Although we could patch the code to use the path
+    # we want, it will break again if the library version ever changes. We need
+    # to think about the best way of handling this and possibly consult
+    # upstream.
+    #
+    # Note that this particular find line is taken from the Debian packaging for
+    # gst-python1.0.
+    find "${D}" \
+        -name '*.pyc' -o \
+        -name '*.pyo' -o \
+        -name '*.la' -o \
+        -name 'libgstpythonplugin*' \
+        -delete
+}
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server.inc b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server.inc
deleted file mode 100644
index 3776f92..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server.inc
+++ /dev/null
@@ -1,31 +0,0 @@
-SUMMARY = "A library on top of GStreamer for building an RTSP server"
-HOMEPAGE = "http://cgit.freedesktop.org/gstreamer/gst-rtsp-server/"
-SECTION = "multimedia"
-LICENSE = "LGPLv2"
-
-DEPENDS = "gstreamer1.0 gstreamer1.0-plugins-base"
-
-PNREAL = "gst-rtsp-server"
-
-SRC_URI = "http://gstreamer.freedesktop.org/src/${PNREAL}/${PNREAL}-${PV}.tar.xz \
-           file://0001-Don-t-hardcode-libtool-name-when-using-introspection.patch \
-           file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch \
-           file://gtk-doc-tweaks.patch"
-
-S = "${WORKDIR}/${PNREAL}-${PV}"
-
-inherit autotools pkgconfig upstream-version-is-even gobject-introspection gtk-doc
-
-EXTRA_OECONF = "--disable-examples --disable-tests"
-
-# Starting with 1.8.0 gst-rtsp-server includes dependency-less plugins as well
-LIBV = "1.0"
-require gst-plugins-package.inc
-
-delete_pkg_m4_file() {
-        # This m4 file is out of date and is missing PKG_CONFIG_SYSROOT_PATH tweaks which we need for introspection
-        rm "${S}/common/m4/pkg.m4" || true
-}
-
-do_configure[prefuncs] += " delete_pkg_m4_file"
-
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server_1.12.4.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server_1.12.4.bb
deleted file mode 100644
index da68dcb..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server_1.12.4.bb
+++ /dev/null
@@ -1,6 +0,0 @@
-require gstreamer1.0-rtsp-server.inc
-
-SRC_URI[md5sum] = "ad70a9735f58da21d0f5cedf48ccadd3"
-SRC_URI[sha256sum] = "7660112ebd59838f1054796b38109dcbe32f0a040e3a252a68a81055aeaa56a9"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=6762ed442b3822387a51c92d928ead0d"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server_1.14.2.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server_1.14.2.bb
new file mode 100644
index 0000000..6766e25
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server_1.14.2.bb
@@ -0,0 +1,35 @@
+SUMMARY = "A library on top of GStreamer for building an RTSP server"
+HOMEPAGE = "http://cgit.freedesktop.org/gstreamer/gst-rtsp-server/"
+SECTION = "multimedia"
+LICENSE = "LGPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=6762ed442b3822387a51c92d928ead0d"
+
+DEPENDS = "gstreamer1.0 gstreamer1.0-plugins-base"
+
+PNREAL = "gst-rtsp-server"
+
+SRC_URI = "http://gstreamer.freedesktop.org/src/${PNREAL}/${PNREAL}-${PV}.tar.xz \
+           file://0001-Don-t-hardcode-libtool-name-when-using-introspection.patch \
+           file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch \
+           file://gtk-doc-tweaks.patch \
+           "
+
+SRC_URI[md5sum] = "c26b59dd2ea8b1a4a25e9f7e0f57a50e"
+SRC_URI[sha256sum] = "f7387755cf6ac5f334d4610f1f5aa7da4ff396a487dd5b789bb707f160222c98"
+
+S = "${WORKDIR}/${PNREAL}-${PV}"
+
+inherit autotools pkgconfig upstream-version-is-even gobject-introspection gtk-doc
+
+EXTRA_OECONF = "--disable-examples --disable-tests"
+
+# Starting with 1.8.0 gst-rtsp-server includes dependency-less plugins as well
+LIBV = "1.0"
+require gst-plugins-package.inc
+
+delete_pkg_m4_file() {
+        # This m4 file is out of date and is missing PKG_CONFIG_SYSROOT_PATH tweaks which we need for introspection
+        rm "${S}/common/m4/pkg.m4" || true
+}
+
+do_configure[prefuncs] += " delete_pkg_m4_file"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-vaapi.inc b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-vaapi.inc
deleted file mode 100644
index abfcc65..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-vaapi.inc
+++ /dev/null
@@ -1,46 +0,0 @@
-SUMMARY = "VA-API support to GStreamer"
-DESCRIPTION = "gstreamer-vaapi consists of a collection of VA-API \
-based plugins for GStreamer and helper libraries: `vaapidecode', \
-`vaapiconvert', and `vaapisink'."
-
-REALPN = "gstreamer-vaapi"
-FILESPATH = "${@base_set_filespath(["${FILE_DIRNAME}/${REALPN}", "${FILE_DIRNAME}/${REALPN}"], d)}"
-
-LICENSE = "LGPLv2.1+"
-LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c"
-
-DEPENDS = "libva"
-
-SRC_URI = "https://gstreamer.freedesktop.org/src/${REALPN}/${REALPN}-${PV}.tar.xz \
-          "
-
-S = "${WORKDIR}/${REALPN}-${PV}"
-
-inherit autotools pkgconfig gtk-doc distro_features_check upstream-version-is-even
-
-REQUIRED_DISTRO_FEATURES ?= "opengl"
-
-PACKAGES =+ "${PN}-tests"
-
-# OpenGL packageconfig factored out to make it easy for distros
-# and BSP layers to pick either glx, egl, or no GL. By default,
-# try detecting X11 first, and if found (with OpenGL), use GLX,
-# otherwise try to check if EGL can be used.
-PACKAGECONFIG_GL ?= "${@bb.utils.contains('DISTRO_FEATURES', 'x11 opengl', 'glx', \
-                        bb.utils.contains('DISTRO_FEATURES',     'opengl', 'egl', \
-                                                                       '', d), d)}"
-
-PACKAGECONFIG ??= "drm \
-                   ${PACKAGECONFIG_GL} \
-                   ${@bb.utils.filter('DISTRO_FEATURES', 'wayland x11', d)}"
-
-PACKAGECONFIG[drm] = "--enable-drm,--disable-drm,udev libdrm"
-PACKAGECONFIG[egl] = "--enable-egl,--disable-egl,virtual/egl"
-PACKAGECONFIG[glx] = "--enable-glx,--disable-glx,virtual/libgl"
-PACKAGECONFIG[wayland] = "--enable-wayland,--disable-wayland,wayland"
-PACKAGECONFIG[x11] = "--enable-x11,--disable-x11,virtual/libx11 libxrandr libxrender"
-
-FILES_${PN} += "${libdir}/gstreamer-*/*.so"
-FILES_${PN}-dbg += "${libdir}/gstreamer-*/.debug"
-FILES_${PN}-dev += "${libdir}/gstreamer-*/*.la ${libdir}/gstreamer-*/*.a"
-FILES_${PN}-tests = "${bindir}/*"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-vaapi/0001-gst-vaapi-Makefile.am-Add-EGL_CFLAGS-to-libgstvaapi-.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-vaapi/0001-gst-vaapi-Makefile.am-Add-EGL_CFLAGS-to-libgstvaapi-.patch
new file mode 100644
index 0000000..d7b8984
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-vaapi/0001-gst-vaapi-Makefile.am-Add-EGL_CFLAGS-to-libgstvaapi-.patch
@@ -0,0 +1,33 @@
+From 5403a89e6a7ac72a23e0221075c0c19b5f85a021 Mon Sep 17 00:00:00 2001
+From: Fabio Berton <fabio.berton@ossystems.com.br>
+Date: Wed, 13 Jun 2018 09:09:25 -0300
+Subject: [PATCH] gst/vaapi/Makefile.am: Add EGL_CFLAGS to libgstvaapi CFLAGS
+Organization: O.S. Systems Software LTDA.
+
+We need this to pass correctly EGL CFLAGS when building with EGL support.
+
+Upstream-Status: Pending
+
+Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br>
+---
+ gst/vaapi/Makefile.am | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/gst/vaapi/Makefile.am b/gst/vaapi/Makefile.am
+index b299ac98..d6cab71f 100644
+--- a/gst/vaapi/Makefile.am
++++ b/gst/vaapi/Makefile.am
+@@ -24,6 +24,10 @@ libgstvaapi_LIBS += $(top_builddir)/gst-libs/gst/vaapi/libgstvaapi-glx.la
+ endif
+ 
+ if USE_EGL
++libgstvaapi_CFLAGS += \
++	$(EGL_CFLAGS)	\
++	$(NULL)
++
+ libgstvaapi_LIBS += $(top_builddir)/gst-libs/gst/vaapi/libgstvaapi-egl.la
+ endif
+ 
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-vaapi/0001-vaapsink-downgrade-to-marginal.patch b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-vaapi/0001-vaapsink-downgrade-to-marginal.patch
new file mode 100644
index 0000000..c861f3b
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-vaapi/0001-vaapsink-downgrade-to-marginal.patch
@@ -0,0 +1,46 @@
+From 0c28cf7bfa90f8947833722cddf23d513490c6c3 Mon Sep 17 00:00:00 2001
+From: Anuj Mittal <anuj.mittal@intel.com>
+Date: Wed, 28 Nov 2018 15:08:48 +0800
+Subject: [PATCH] vaapsink: downgrade to marginal
+
+Using vaapisink with default poky configuration results in an
+unresponsive display as of today because DRI2 rendering is currently broken
+in non composited environments [1] and libva doesn't support DRI3 [2].
+
+Downgrade vaapisink to marginal for now so playbin (and in turn gst-play
+and gtk-play examples) use xvimagesink or others out of box.
+
+[1] https://gitlab.freedesktop.org/xorg/xserver/issues/13
+[2] https://github.com/intel/libva/issues/122
+
+Upstream-Status: Pending
+
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+---
+ gst/vaapi/gstvaapi.c | 6 +-----
+ 1 file changed, 1 insertion(+), 5 deletions(-)
+
+diff --git a/gst/vaapi/gstvaapi.c b/gst/vaapi/gstvaapi.c
+index 9a82454..4d94f2b 100644
+--- a/gst/vaapi/gstvaapi.c
++++ b/gst/vaapi/gstvaapi.c
+@@ -210,7 +210,6 @@ plugin_init (GstPlugin * plugin)
+ {
+   GstVaapiDisplay *display;
+   GArray *decoders;
+-  guint rank;
+ 
+   plugin_add_dependencies (plugin);
+ 
+@@ -235,10 +234,7 @@ plugin_init (GstPlugin * plugin)
+   gst_element_register (plugin, "vaapidecodebin",
+       GST_RANK_PRIMARY + 2, GST_TYPE_VAAPI_DECODE_BIN);
+ 
+-  rank = GST_RANK_PRIMARY;
+-  if (g_getenv ("WAYLAND_DISPLAY"))
+-    rank = GST_RANK_MARGINAL;
+-  gst_element_register (plugin, "vaapisink", rank, GST_TYPE_VAAPISINK);
++  gst_element_register (plugin, "vaapisink", GST_RANK_MARGINAL, GST_TYPE_VAAPISINK);
+ 
+ #if USE_ENCODERS
+   gst_vaapiencode_register (plugin, display);
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-vaapi_1.12.4.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-vaapi_1.12.4.bb
deleted file mode 100644
index 1df2301..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-vaapi_1.12.4.bb
+++ /dev/null
@@ -1,5 +0,0 @@
-require gstreamer1.0-vaapi.inc
-SRC_URI[md5sum] = "2149982cdb348139bca946bb63766f4c"
-SRC_URI[sha256sum] = "1c2d77242e1f30c4d1394636cae9f6877228a017960fca96881e0080d8b6e9c9"
-
-DEPENDS += "gstreamer1.0 gstreamer1.0-plugins-base gstreamer1.0-plugins-bad"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-vaapi_1.14.2.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-vaapi_1.14.2.bb
new file mode 100644
index 0000000..f0ed2fa
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0-vaapi_1.14.2.bb
@@ -0,0 +1,49 @@
+SUMMARY = "VA-API support to GStreamer"
+DESCRIPTION = "gstreamer-vaapi consists of a collection of VA-API \
+based plugins for GStreamer and helper libraries: `vaapidecode', \
+`vaapiconvert', and `vaapisink'."
+
+REALPN = "gstreamer-vaapi"
+
+LICENSE = "LGPLv2.1+"
+LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c"
+
+SRC_URI = "https://gstreamer.freedesktop.org/src/${REALPN}/${REALPN}-${PV}.tar.xz \
+           file://0001-gst-vaapi-Makefile.am-Add-EGL_CFLAGS-to-libgstvaapi-.patch \
+           file://0001-vaapsink-downgrade-to-marginal.patch \
+           "
+
+SRC_URI[md5sum] = "12ee9c16dfa0bb1808c76683e1c9a328"
+SRC_URI[sha256sum] = "7f1064e27f5abd3a42ef66b425f1a2b9dbae7748c81bd9d090ce52a1aaf30d8a"
+
+S = "${WORKDIR}/${REALPN}-${PV}"
+DEPENDS = "libva gstreamer1.0 gstreamer1.0-plugins-base gstreamer1.0-plugins-bad"
+
+inherit autotools pkgconfig gtk-doc distro_features_check upstream-version-is-even
+
+REQUIRED_DISTRO_FEATURES ?= "opengl"
+
+PACKAGES =+ "${PN}-tests"
+
+# OpenGL packageconfig factored out to make it easy for distros
+# and BSP layers to pick either glx, egl, or no GL. By default,
+# try detecting X11 first, and if found (with OpenGL), use GLX,
+# otherwise try to check if EGL can be used.
+PACKAGECONFIG_GL ?= "${@bb.utils.contains('DISTRO_FEATURES', 'x11 opengl', 'glx', \
+                        bb.utils.contains('DISTRO_FEATURES',     'opengl', 'egl', \
+                                                                       '', d), d)}"
+
+PACKAGECONFIG ??= "drm \
+                   ${PACKAGECONFIG_GL} \
+                   ${@bb.utils.filter('DISTRO_FEATURES', 'wayland x11', d)}"
+
+PACKAGECONFIG[drm] = "--enable-drm,--disable-drm,udev libdrm"
+PACKAGECONFIG[egl] = "--enable-egl,--disable-egl,virtual/egl"
+PACKAGECONFIG[glx] = "--enable-glx,--disable-glx,virtual/libgl"
+PACKAGECONFIG[wayland] = "--enable-wayland,--disable-wayland,wayland"
+PACKAGECONFIG[x11] = "--enable-x11,--disable-x11,virtual/libx11 libxrandr libxrender"
+
+FILES_${PN} += "${libdir}/gstreamer-*/*.so"
+FILES_${PN}-dbg += "${libdir}/gstreamer-*/.debug"
+FILES_${PN}-dev += "${libdir}/gstreamer-*/*.la ${libdir}/gstreamer-*/*.a"
+FILES_${PN}-tests = "${bindir}/*"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0.inc b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0.inc
deleted file mode 100644
index c2df1f3..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0.inc
+++ /dev/null
@@ -1,61 +0,0 @@
-SUMMARY = "GStreamer 1.0 multimedia framework"
-DESCRIPTION = "GStreamer is a multimedia framework for encoding and decoding video and sound. \
-It supports a wide range of formats including mp3, ogg, avi, mpeg and quicktime."
-HOMEPAGE = "http://gstreamer.freedesktop.org/"
-BUGTRACKER = "https://bugzilla.gnome.org/enter_bug.cgi?product=Gstreamer"
-SECTION = "multimedia"
-LICENSE = "LGPLv2+"
-
-DEPENDS = "glib-2.0 glib-2.0-native libcap libxml2 bison-native flex-native"
-
-inherit autotools pkgconfig gettext upstream-version-is-even gobject-introspection gtk-doc
-
-# This way common/m4/introspection.m4 will come first
-# (it has a custom INTROSPECTION_INIT macro, and so must be used instead of our common introspection.m4 file)
-acpaths = "-I ${S}/common/m4 -I ${S}/m4"
-
-SRC_URI_append = " \
-    file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch \
-    file://gtk-doc-tweaks.patch \
-    file://0001-gst-gstpluginloader.c-when-env-var-is-set-do-not-fal.patch \
-"
-
-PACKAGECONFIG ??= ""
-
-PACKAGECONFIG[debug] = "--enable-debug,--disable-debug"
-PACKAGECONFIG[tests] = "--enable-tests,--disable-tests"
-PACKAGECONFIG[valgrind] = "--enable-valgrind,--disable-valgrind,valgrind,"
-PACKAGECONFIG[gst-tracer-hooks] = "--enable-gst-tracer-hooks,--disable-gst-tracer-hooks,"
-PACKAGECONFIG[unwind] = "--with-unwind,--without-unwind,libunwind"
-PACKAGECONFIG[dw] = "--with-dw,--without-dw,elfutils"
-
-EXTRA_OECONF = " \
-    --disable-dependency-tracking \
-    --disable-examples \
-"
-
-CACHED_CONFIGUREVARS += "ac_cv_header_valgrind_valgrind_h=no"
-
-# musl libc generates warnings if <sys/poll.h> is included directly
-CACHED_CONFIGUREVARS += "ac_cv_header_sys_poll_h=no"
-
-PACKAGES += "${PN}-bash-completion"
-
-FILES_${PN} += "${libdir}/gstreamer-1.0/*.so"
-FILES_${PN}-dev += "${libdir}/gstreamer-1.0/*.la ${libdir}/gstreamer-1.0/*.a ${libdir}/gstreamer-1.0/include"
-FILES_${PN}-bash-completion += "${datadir}/bash-completion/completions/ ${datadir}/bash-completion/helpers/gst*"
-
-RRECOMMENDS_${PN}_qemux86 += "kernel-module-snd-ens1370 kernel-module-snd-rawmidi"
-RRECOMMENDS_${PN}_qemux86-64 += "kernel-module-snd-ens1370 kernel-module-snd-rawmidi"
-
-delete_pkg_m4_file() {
-        # This m4 file is out of date and is missing PKG_CONFIG_SYSROOT_PATH tweaks which we need for introspection
-        rm "${S}/common/m4/pkg.m4" || true
-        rm -f "${S}/common/m4/gtk-doc.m4"
-}
-
-do_configure[prefuncs] += "delete_pkg_m4_file"
-
-do_compile_prepend() {
-        export GIR_EXTRA_LIBS_PATH="${B}/gst/.libs:${B}/libs/gst/base/.libs"
-}
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0_1.12.4.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0_1.12.4.bb
deleted file mode 100644
index 01b2396..0000000
--- a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0_1.12.4.bb
+++ /dev/null
@@ -1,14 +0,0 @@
-require gstreamer1.0.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=6762ed442b3822387a51c92d928ead0d \
-                    file://gst/gst.h;beginline=1;endline=21;md5=e059138481205ee2c6fc1c079c016d0d"
-
-SRC_URI = " \
-    http://gstreamer.freedesktop.org/src/gstreamer/gstreamer-${PV}.tar.xz \
-"
-SRC_URI[md5sum] = "9d268f2e891cce1ac0832f1cc467d4ea"
-SRC_URI[sha256sum] = "5a8704aa4c2eeb04da192c4a9942f94f860ac1a585de90d9f914bac26a970674"
-
-S = "${WORKDIR}/gstreamer-${PV}"
-
-CVE_PRODUCT = "gstreamer"
diff --git a/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0_1.14.2.bb b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0_1.14.2.bb
new file mode 100644
index 0000000..3a6e53d
--- /dev/null
+++ b/poky/meta/recipes-multimedia/gstreamer/gstreamer1.0_1.14.2.bb
@@ -0,0 +1,90 @@
+SUMMARY = "GStreamer 1.0 multimedia framework"
+DESCRIPTION = "GStreamer is a multimedia framework for encoding and decoding video and sound. \
+It supports a wide range of formats including mp3, ogg, avi, mpeg and quicktime."
+HOMEPAGE = "http://gstreamer.freedesktop.org/"
+BUGTRACKER = "https://bugzilla.gnome.org/enter_bug.cgi?product=Gstreamer"
+SECTION = "multimedia"
+LICENSE = "LGPLv2+"
+
+DEPENDS = "glib-2.0 glib-2.0-native libcap libxml2 bison-native flex-native"
+
+inherit autotools pkgconfig gettext upstream-version-is-even gobject-introspection gtk-doc ptest
+
+# This way common/m4/introspection.m4 will come first
+# (it has a custom INTROSPECTION_INIT macro, and so must be used instead of our common introspection.m4 file)
+acpaths = "-I ${S}/common/m4 -I ${S}/m4"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=6762ed442b3822387a51c92d928ead0d \
+                    file://gst/gst.h;beginline=1;endline=21;md5=e059138481205ee2c6fc1c079c016d0d"
+
+S = "${WORKDIR}/gstreamer-${PV}"
+
+SRC_URI = " \
+    http://gstreamer.freedesktop.org/src/gstreamer/gstreamer-${PV}.tar.xz \
+    file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch \
+    file://gtk-doc-tweaks.patch \
+    file://0001-gst-gstpluginloader.c-when-env-var-is-set-do-not-fal.patch \
+    file://add-a-target-to-compile-tests.patch \
+    file://run-ptest \
+"
+SRC_URI[md5sum] = "9f4177c1752e44cbd72f6311ee61e1ba"
+SRC_URI[sha256sum] = "4bd6127299f3f29379046bbd58a526e6353b569e0e72f7b4df2ae70df6882e09"
+
+PACKAGECONFIG ??= "${@bb.utils.contains('PTEST_ENABLED', '1', 'tests', '', d)} \
+                   "
+
+PACKAGECONFIG[debug] = "--enable-debug,--disable-debug"
+PACKAGECONFIG[tests] = "--enable-tests,--disable-tests"
+PACKAGECONFIG[valgrind] = "--enable-valgrind,--disable-valgrind,valgrind,"
+PACKAGECONFIG[gst-tracer-hooks] = "--enable-gst-tracer-hooks,--disable-gst-tracer-hooks,"
+PACKAGECONFIG[unwind] = "--with-unwind,--without-unwind,libunwind"
+PACKAGECONFIG[dw] = "--with-dw,--without-dw,elfutils"
+
+EXTRA_OECONF = " \
+    --disable-examples \
+"
+
+CACHED_CONFIGUREVARS += "ac_cv_header_valgrind_valgrind_h=no"
+
+# musl libc generates warnings if <sys/poll.h> is included directly
+CACHED_CONFIGUREVARS += "ac_cv_header_sys_poll_h=no"
+
+PACKAGES += "${PN}-bash-completion"
+
+FILES_${PN} += "${libdir}/gstreamer-1.0/*.so"
+FILES_${PN}-dev += "${libdir}/gstreamer-1.0/*.la ${libdir}/gstreamer-1.0/*.a ${libdir}/gstreamer-1.0/include"
+FILES_${PN}-bash-completion += "${datadir}/bash-completion/completions/ ${datadir}/bash-completion/helpers/gst*"
+
+RDEPENDS_${PN}-ptest += "make"
+
+delete_pkg_m4_file() {
+        # This m4 file is out of date and is missing PKG_CONFIG_SYSROOT_PATH tweaks which we need for introspection
+        rm "${S}/common/m4/pkg.m4" || true
+        rm -f "${S}/common/m4/gtk-doc.m4"
+}
+
+do_configure[prefuncs] += "delete_pkg_m4_file"
+
+do_compile_prepend() {
+        export GIR_EXTRA_LIBS_PATH="${B}/gst/.libs:${B}/libs/gst/base/.libs"
+}
+
+do_compile_ptest() {
+        oe_runmake build-checks
+}
+
+do_install_ptest() {
+        oe_runmake -C tests/check DESTDIR=${D}${PTEST_PATH} install-ptest
+        install -m 644 ${B}/tests/check/Makefile ${D}${PTEST_PATH}
+        install -m 755 ${S}/test-driver ${D}${PTEST_PATH}
+        sed -e 's,--sysroot=${STAGING_DIR_TARGET},,g' \
+            -e 's|${DEBUG_PREFIX_MAP}||g' \
+            -e 's:${HOSTTOOLS_DIR}/::g' \
+            -e 's:${RECIPE_SYSROOT_NATIVE}::g' \
+            -e 's:${BASE_WORKDIR}/${MULTIMACH_TARGET_SYS}::g' \-e 's/^Makefile:/_Makefile:/' \
+            -e 's/^srcdir = \(.*\)/srcdir = ./' -e 's/^top_srcdir = \(.*\)/top_srcdir = ./' \
+            -e 's/^builddir = \(.*\)/builddir = ./' -e 's/^top_builddir = \(.*\)/top_builddir = ./' \
+            -i ${D}${PTEST_PATH}/Makefile
+}
+
+CVE_PRODUCT = "gstreamer"
diff --git a/poky/meta/recipes-multimedia/libpng/files/CVE-2018-13785.patch b/poky/meta/recipes-multimedia/libpng/files/CVE-2018-13785.patch
deleted file mode 100644
index 84b1af1..0000000
--- a/poky/meta/recipes-multimedia/libpng/files/CVE-2018-13785.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From 8a05766cb74af05c04c53e6c9d60c13fc4d59bf2 Mon Sep 17 00:00:00 2001
-From: Cosmin Truta <ctruta@gmail.com>
-Date: Sun, 17 Jun 2018 22:56:29 -0400
-Subject: [PATCH] [libpng16] Fix the calculation of row_factor in
- png_check_chunk_length
-
-(Bug report by Thuan Pham, SourceForge issue #278)
-Upstream-Status: Backport [https://github.com/glennrp/libpng/commit/8a05766cb74af05c04c53e6c9d60c13fc4d59bf2]
-Signed-off-by: Sinan Kaya <okaya@kernel.org>
----
- pngrutil.c | 9 ++++++---
- 1 file changed, 6 insertions(+), 3 deletions(-)
-
-diff --git a/pngrutil.c b/pngrutil.c
-index 95571b517..5ba995abf 100644
---- a/pngrutil.c
-+++ b/pngrutil.c
-@@ -3167,10 +3167,13 @@ png_check_chunk_length(png_const_structrp png_ptr, const png_uint_32 length)
-    {
-       png_alloc_size_t idat_limit = PNG_UINT_31_MAX;
-       size_t row_factor =
--         (png_ptr->width * png_ptr->channels * (png_ptr->bit_depth > 8? 2: 1)
--          + 1 + (png_ptr->interlaced? 6: 0));
-+         (size_t)png_ptr->width
-+         * (size_t)png_ptr->channels
-+         * (png_ptr->bit_depth > 8? 2: 1)
-+         + 1
-+         + (png_ptr->interlaced? 6: 0);
-       if (png_ptr->height > PNG_UINT_32_MAX/row_factor)
--         idat_limit=PNG_UINT_31_MAX;
-+         idat_limit = PNG_UINT_31_MAX;
-       else
-          idat_limit = png_ptr->height * row_factor;
-       row_factor = row_factor > 32566? 32566 : row_factor;
--- 
-2.19.0
-
diff --git a/poky/meta/recipes-multimedia/libpng/libpng_1.6.34.bb b/poky/meta/recipes-multimedia/libpng/libpng_1.6.34.bb
deleted file mode 100644
index 3877d6c..0000000
--- a/poky/meta/recipes-multimedia/libpng/libpng_1.6.34.bb
+++ /dev/null
@@ -1,32 +0,0 @@
-SUMMARY = "PNG image format decoding library"
-HOMEPAGE = "http://www.libpng.org/"
-SECTION = "libs"
-LICENSE = "Libpng"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=2db717a05a20e36f2fa673265bd31568 \
-                    file://png.h;endline=144;md5=3ac9fd250a8786ae581e34254bf79429"
-DEPENDS = "zlib"
-
-LIBV = "16"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/project/${BPN}/${BPN}${LIBV}/${PV}/${BP}.tar.xz \
-           file://CVE-2018-13785.patch \
-"
-SRC_URI[md5sum] = "c05b6ca7190a5e387b78657dbe5536b2"
-SRC_URI[sha256sum] = "2f1e960d92ce3b3abd03d06dfec9637dfbd22febf107a536b44f7a47c60659f6"
-
-MIRRORS += "${SOURCEFORGE_MIRROR}/project/${BPN}/${BPN}${LIBV}/${PV}/ ${SOURCEFORGE_MIRROR}/project/${BPN}/${BPN}${LIBV}/older-releases/${PV}/"
-
-UPSTREAM_CHECK_URI = "http://libpng.org/pub/png/libpng.html"
-
-BINCONFIG = "${bindir}/libpng-config ${bindir}/libpng16-config"
-
-inherit autotools binconfig-disabled pkgconfig
-
-# Work around missing symbols
-EXTRA_OECONF_append_class-target = " ${@bb.utils.contains("TUNE_FEATURES", "neon", "--enable-arm-neon=on", "--enable-arm-neon=off" ,d)}"
-
-PACKAGES =+ "${PN}-tools"
-
-FILES_${PN}-tools = "${bindir}/png-fix-itxt ${bindir}/pngfix ${bindir}/pngcp"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-multimedia/libpng/libpng_1.6.35.bb b/poky/meta/recipes-multimedia/libpng/libpng_1.6.35.bb
new file mode 100644
index 0000000..5ae0a91
--- /dev/null
+++ b/poky/meta/recipes-multimedia/libpng/libpng_1.6.35.bb
@@ -0,0 +1,31 @@
+SUMMARY = "PNG image format decoding library"
+HOMEPAGE = "http://www.libpng.org/"
+SECTION = "libs"
+LICENSE = "Libpng"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=4791381a76f106ac4699f6261c65ee29 \
+                    file://png.h;endline=144;md5=090ba5769782e8a1663a45fab1c2b36c \
+                    "
+DEPENDS = "zlib"
+
+LIBV = "16"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/project/${BPN}/${BPN}${LIBV}/${PV}/${BP}.tar.xz"
+SRC_URI[md5sum] = "678b7e696a62a193ed3503b04bf449d6"
+SRC_URI[sha256sum] = "23912ec8c9584917ed9b09c5023465d71709dce089be503c7867fec68a93bcd7"
+
+MIRRORS += "${SOURCEFORGE_MIRROR}/project/${BPN}/${BPN}${LIBV}/${PV}/ ${SOURCEFORGE_MIRROR}/project/${BPN}/${BPN}${LIBV}/older-releases/${PV}/"
+
+UPSTREAM_CHECK_URI = "http://libpng.org/pub/png/libpng.html"
+
+BINCONFIG = "${bindir}/libpng-config ${bindir}/libpng16-config"
+
+inherit autotools binconfig-disabled pkgconfig
+
+# Work around missing symbols
+EXTRA_OECONF_append_class-target = " ${@bb.utils.contains("TUNE_FEATURES", "neon", "--enable-arm-neon=on", "--enable-arm-neon=off" ,d)}"
+
+PACKAGES =+ "${PN}-tools"
+
+FILES_${PN}-tools = "${bindir}/png-fix-itxt ${bindir}/pngfix ${bindir}/pngcp"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-multimedia/libvorbis/libvorbis/0001-configure-Check-for-clang.patch b/poky/meta/recipes-multimedia/libvorbis/libvorbis/0001-configure-Check-for-clang.patch
index 7dad0cd..b06029b 100644
--- a/poky/meta/recipes-multimedia/libvorbis/libvorbis/0001-configure-Check-for-clang.patch
+++ b/poky/meta/recipes-multimedia/libvorbis/libvorbis/0001-configure-Check-for-clang.patch
@@ -1,4 +1,4 @@
-From 44b4511784f9b51c514dff4ceb3cbeaf9c374d08 Mon Sep 17 00:00:00 2001
+From d619ccf6c11ab574466914c57994a82fb99401af Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Wed, 22 Mar 2017 16:06:55 +0000
 Subject: [PATCH] configure: Check for clang
@@ -13,12 +13,12 @@
  1 file changed, 17 insertions(+), 2 deletions(-)
 
 diff --git a/configure.ac b/configure.ac
-index eddd02d..00ecba5 100644
+index 28b0a14..2d4e984 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -93,6 +93,16 @@ AC_ARG_ENABLE(examples,
-  	
- AM_CONDITIONAL(BUILD_EXAMPLES, [test "x$enable_examples" = xyes]) 
+@@ -98,6 +98,16 @@ AC_ARG_ENABLE(examples,
+ 
+ AM_CONDITIONAL(BUILD_EXAMPLES, [test "x$enable_examples" = xyes])
  
 +AC_MSG_CHECKING([whether C compiler is clang])
 +$CC -x c /dev/null -dM -E > conftest.txt 2>&1
@@ -33,9 +33,9 @@
  dnl --------------------------------------------------
  dnl Set build flags based on environment
  dnl --------------------------------------------------
-@@ -127,10 +137,15 @@ else
+@@ -132,10 +142,15 @@ else
  	AC_MSG_RESULT([$GCC_VERSION])
- 	case $host in 
+ 	case $host in
  	*86-*-linux*)
 +		if test "$CC_CLANG" = "1"; then
 +			ieeefp=""
@@ -43,8 +43,8 @@
 +			ieefp="-mno-ieee-fp"
 +		fi
  		DEBUG="-g -Wall -Wextra -D_REENTRANT -D__NO_MATH_INLINES -fsigned-char"
--		CFLAGS="-O3 -ffast-math -mno-ieee-fp -D_REENTRANT -fsigned-char"
-+		CFLAGS="-O3 -ffast-math -D_REENTRANT -fsigned-char ${ieefp}"
+-		CFLAGS="-O3 -Wall -Wextra -ffast-math -mno-ieee-fp -D_REENTRANT -fsigned-char"
++		CFLAGS="-O3 -Wall -Wextra -ffast-math -D_REENTRANT -fsigned-char ${ieefp}"
  #              	PROFILE="-Wall -Wextra -pg -g -O3 -ffast-math -D_REENTRANT -fsigned-char -fno-inline -static"
 -		PROFILE="-Wall -Wextra -pg -g -O3 -ffast-math -mno-ieee-fp -D_REENTRANT -fsigned-char -fno-inline"
 +		PROFILE="-Wall -Wextra -pg -g -O3 -ffast-math ${ieefp} -D_REENTRANT -fsigned-char -fno-inline"
@@ -52,5 +52,5 @@
  		# glibc < 2.1.3 has a serious FP bug in the math inline header
  		# that will cripple Vorbis.  Look to see if the magic FP stack
 -- 
-1.8.3.1
+2.17.0
 
diff --git a/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2017-14160.patch b/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2017-14160.patch
index 7564d92..b7603c3 100644
--- a/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2017-14160.patch
+++ b/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2017-14160.patch
@@ -3,14 +3,15 @@
 Date: Wed, 9 May 2018 14:56:59 -0700
 Subject: [PATCH] CVE-2017-14160: fix bounds check on very low sample rates.
 
-CVE: CVE-2017-14160
-CVE: CVE-2018-10393
-Upstream-Status: Backport from https://gitlab.xiph.org/xiph/vorbis/commit/018ca26dece618457dd13585cad52941193c4a25
-
-Signed-off-by: Thomas Daede <daede003@umn.edu>
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
 ---
- lib/psy.c | 3 ++-
+CVE: CVE-2017-14160 CVE-2018-10393
+
+Upstream-Status: Backport [gitlab.com/Xiph.Org/Vorbis/Commits/018ca26d...]
+
+Signed-off-by: Joe Slater <joe.slater@windriver.com>
+---
+---
+ lib/psy.c |    3 ++-
  1 file changed, 2 insertions(+), 1 deletion(-)
 
 diff --git a/lib/psy.c b/lib/psy.c
@@ -29,5 +30,5 @@
      tN = N[hi] + N[-lo];
      tX = X[hi] - X[-lo];
 -- 
-2.7.4
+1.7.9.5
 
diff --git a/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2017-14632.patch b/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2017-14632.patch
deleted file mode 100644
index 4036b96..0000000
--- a/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2017-14632.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-From 39704ce16835e5c019bb03f6a94dc1f0677406c5 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Guido=20G=C3=BCnther?= <agx@sigxcpu.org>
-Date: Wed, 15 Nov 2017 18:22:59 +0100
-Subject: [PATCH] CVE-2017-14632: vorbis_analysis_header_out: Don't clear opb
- if not initialized
-
-If the number of channels is not within the allowed range
-we call oggback_writeclear altough it's not initialized yet.
-
-This fixes
-
-    =23371== Invalid free() / delete / delete[] / realloc()
-    ==23371==    at 0x4C2CE1B: free (vg_replace_malloc.c:530)
-    ==23371==    by 0x829CA31: oggpack_writeclear (in /usr/lib/x86_64-linux-gnu/libogg.so.0.8.2)
-    ==23371==    by 0x84B96EE: vorbis_analysis_headerout (info.c:652)
-    ==23371==    by 0x9FBCBCC: ??? (in /usr/lib/x86_64-linux-gnu/sox/libsox_fmt_vorbis.so)
-    ==23371==    by 0x4E524F1: ??? (in /usr/lib/x86_64-linux-gnu/libsox.so.2.0.1)
-    ==23371==    by 0x4E52CCA: sox_open_write (in /usr/lib/x86_64-linux-gnu/libsox.so.2.0.1)
-    ==23371==    by 0x10D82A: open_output_file (sox.c:1556)
-    ==23371==    by 0x10D82A: process (sox.c:1753)
-    ==23371==    by 0x10D82A: main (sox.c:3012)
-    ==23371==  Address 0x68768c8 is 488 bytes inside a block of size 880 alloc'd
-    ==23371==    at 0x4C2BB1F: malloc (vg_replace_malloc.c:298)
-    ==23371==    by 0x4C2DE9F: realloc (vg_replace_malloc.c:785)
-    ==23371==    by 0x4E545C2: lsx_realloc (in /usr/lib/x86_64-linux-gnu/libsox.so.2.0.1)
-    ==23371==    by 0x9FBC9A0: ??? (in /usr/lib/x86_64-linux-gnu/sox/libsox_fmt_vorbis.so)
-    ==23371==    by 0x4E524F1: ??? (in /usr/lib/x86_64-linux-gnu/libsox.so.2.0.1)
-    ==23371==    by 0x4E52CCA: sox_open_write (in /usr/lib/x86_64-linux-gnu/libsox.so.2.0.1)
-    ==23371==    by 0x10D82A: open_output_file (sox.c:1556)
-    ==23371==    by 0x10D82A: process (sox.c:1753)
-    ==23371==    by 0x10D82A: main (sox.c:3012)
-
-as seen when using the testcase from CVE-2017-11333 with
-008d23b782be09c8d75ba8190b1794abd66c7121 applied. However the error was
-there before.
-
-Upstream-Status: Backport
-CVE: CVE-2017-14632
-
-Reference to upstream patch:
-https://git.xiph.org/?p=vorbis.git;a=commitdiff;h=c1c2831fc7306d5fbd7bc800324efd12b28d327f
-
-Signed-off-by: Tanu Kaskinen <tanuk@iki.fi>
----
- lib/info.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/lib/info.c b/lib/info.c
-index 81b7557..4d82568 100644
---- a/lib/info.c
-+++ b/lib/info.c
-@@ -584,6 +584,7 @@ int vorbis_analysis_headerout(vorbis_dsp_state *v,
-   private_state *b=v->backend_state;
- 
-   if(!b||vi->channels<=0||vi->channels>256){
-+    b = NULL;
-     ret=OV_EFAULT;
-     goto err_out;
-   }
--- 
-2.16.2
-
diff --git a/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2017-14633.patch b/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2017-14633.patch
deleted file mode 100644
index 9c9e688..0000000
--- a/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2017-14633.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From 07eda55f336e5c44dfc0e4a1e21628faed7255fa Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Guido=20G=C3=BCnther?= <agx@sigxcpu.org>
-Date: Tue, 31 Oct 2017 18:32:46 +0100
-Subject: [PATCH] CVE-2017-14633: Don't allow for more than 256 channels
-
-Otherwise
-
- for(i=0;i<vi->channels;i++){
-      /* the encoder setup assumes that all the modes used by any
-         specific bitrate tweaking use the same floor */
-      int submap=info->chmuxlist[i];
-
-overreads later in mapping0_forward since chmuxlist is a fixed array of
-256 elements max.
-
-Upstream-Status: Backport
-CVE: CVE-2017-14633
-
-Reference to upstream patch:
-https://git.xiph.org/?p=vorbis.git;a=commitdiff;h=667ceb4aab60c1f74060143bb24e5f427b3cce5f
-
-Signed-off-by: Tanu Kaskinen <tanuk@iki.fi>
----
- lib/info.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/lib/info.c b/lib/info.c
-index e447a0c..81b7557 100644
---- a/lib/info.c
-+++ b/lib/info.c
-@@ -583,7 +583,7 @@ int vorbis_analysis_headerout(vorbis_dsp_state *v,
-   oggpack_buffer opb;
-   private_state *b=v->backend_state;
- 
--  if(!b||vi->channels<=0){
-+  if(!b||vi->channels<=0||vi->channels>256){
-     ret=OV_EFAULT;
-     goto err_out;
-   }
--- 
-2.16.2
-
diff --git a/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2018-10392.patch b/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2018-10392.patch
index f1ef6fb..b7936b4 100644
--- a/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2018-10392.patch
+++ b/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2018-10392.patch
@@ -4,14 +4,19 @@
 Subject: [PATCH] Sanity check number of channels in setup.
 
 Fixes #2335.
-CVE: CVE-2018-10392
-Upstream-Status: Backport [https://gitlab.xiph.org/xiph/vorbis/commit/112d3bd0aaacad51305e1464d4b381dabad0e88b]
 
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
 ---
- lib/vorbisenc.c | 1 +
+CVE: CVE-2018-10392
+
+Upstream-Status: Backport [gitlab.com/Xiph.Org/Vorbis/Commits/112d3bd...]
+
+Signed-off-by: Joe Slater <joe.slater@windriver.com>
+---
+
+ lib/vorbisenc.c |    1 +
  1 file changed, 1 insertion(+)
 
+
 diff --git a/lib/vorbisenc.c b/lib/vorbisenc.c
 index 4fc7b62..64a51b5 100644
 --- a/lib/vorbisenc.c
@@ -25,5 +30,5 @@
  
    /* too low/high an ATH floater is nonsensical, but doesn't break anything */
 -- 
-2.13.3
+1.7.9.5
 
diff --git a/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2018-5146.patch b/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2018-5146.patch
deleted file mode 100644
index 6d4052a..0000000
--- a/poky/meta/recipes-multimedia/libvorbis/libvorbis/CVE-2018-5146.patch
+++ /dev/null
@@ -1,100 +0,0 @@
-From 3a017f591457bf6e80231b563bf83ee583fdbca8 Mon Sep 17 00:00:00 2001
-From: Thomas Daede <daede003@umn.edu>
-Date: Thu, 15 Mar 2018 14:15:31 -0700
-Subject: [PATCH] CVE-2018-5146: Prevent out-of-bounds write in codebook
- decoding.
-
-Codebooks that are not an exact divisor of the partition size are now
-truncated to fit within the partition.
-
-Upstream-Status: Backport
-CVE: CVE-2018-5146
-
-Reference to upstream patch:
-https://git.xiph.org/?p=vorbis.git;a=commitdiff;h=667ceb4aab60c1f74060143bb24e5f427b3cce5f
-
-Signed-off-by: Tanu Kaskinen <tanuk@iki.fi>
----
- lib/codebook.c | 48 ++++++++++--------------------------------------
- 1 file changed, 10 insertions(+), 38 deletions(-)
-
-diff --git a/lib/codebook.c b/lib/codebook.c
-index 8b766e8..7022fd2 100644
---- a/lib/codebook.c
-+++ b/lib/codebook.c
-@@ -387,7 +387,7 @@ long vorbis_book_decodevs_add(codebook *book,float *a,oggpack_buffer *b,int n){
-       t[i] = book->valuelist+entry[i]*book->dim;
-     }
-     for(i=0,o=0;i<book->dim;i++,o+=step)
--      for (j=0;j<step;j++)
-+      for (j=0;o+j<n && j<step;j++)
-         a[o+j]+=t[j][i];
-   }
-   return(0);
-@@ -399,41 +399,12 @@ long vorbis_book_decodev_add(codebook *book,float *a,oggpack_buffer *b,int n){
-     int i,j,entry;
-     float *t;
- 
--    if(book->dim>8){
--      for(i=0;i<n;){
--        entry = decode_packed_entry_number(book,b);
--        if(entry==-1)return(-1);
--        t     = book->valuelist+entry*book->dim;
--        for (j=0;j<book->dim;)
--          a[i++]+=t[j++];
--      }
--    }else{
--      for(i=0;i<n;){
--        entry = decode_packed_entry_number(book,b);
--        if(entry==-1)return(-1);
--        t     = book->valuelist+entry*book->dim;
--        j=0;
--        switch((int)book->dim){
--        case 8:
--          a[i++]+=t[j++];
--        case 7:
--          a[i++]+=t[j++];
--        case 6:
--          a[i++]+=t[j++];
--        case 5:
--          a[i++]+=t[j++];
--        case 4:
--          a[i++]+=t[j++];
--        case 3:
--          a[i++]+=t[j++];
--        case 2:
--          a[i++]+=t[j++];
--        case 1:
--          a[i++]+=t[j++];
--        case 0:
--          break;
--        }
--      }
-+    for(i=0;i<n;){
-+      entry = decode_packed_entry_number(book,b);
-+      if(entry==-1)return(-1);
-+      t     = book->valuelist+entry*book->dim;
-+      for(j=0;i<n && j<book->dim;)
-+        a[i++]+=t[j++];
-     }
-   }
-   return(0);
-@@ -471,12 +442,13 @@ long vorbis_book_decodevv_add(codebook *book,float **a,long offset,int ch,
-   long i,j,entry;
-   int chptr=0;
-   if(book->used_entries>0){
--    for(i=offset/ch;i<(offset+n)/ch;){
-+    int m=(offset+n)/ch;
-+    for(i=offset/ch;i<m;){
-       entry = decode_packed_entry_number(book,b);
-       if(entry==-1)return(-1);
-       {
-         const float *t = book->valuelist+entry*book->dim;
--        for (j=0;j<book->dim;j++){
-+        for (j=0;i<m && j<book->dim;j++){
-           a[chptr++][i]+=t[j];
-           if(chptr==ch){
-             chptr=0;
--- 
-2.16.2
-
diff --git a/poky/meta/recipes-multimedia/libvorbis/libvorbis_1.3.5.bb b/poky/meta/recipes-multimedia/libvorbis/libvorbis_1.3.5.bb
deleted file mode 100644
index 615b539..0000000
--- a/poky/meta/recipes-multimedia/libvorbis/libvorbis_1.3.5.bb
+++ /dev/null
@@ -1,25 +0,0 @@
-SUMMARY = "Ogg Vorbis Audio Codec"
-DESCRIPTION = "Ogg Vorbis is a high-quality lossy audio codec \
-that is free of intellectual property restrictions. libvorbis \
-is the main vorbis codec library."
-HOMEPAGE = "http://www.vorbis.com/"
-BUGTRACKER = "https://trac.xiph.org"
-SECTION = "libs"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=7d2c487d2fc7dd3e3c7c465a5b7f6217 \
-                    file://include/vorbis/vorbisenc.h;beginline=1;endline=11;md5=d1c1d138863d6315131193d4046d81cb"
-DEPENDS = "libogg"
-PR = "r1"
-
-SRC_URI = "http://downloads.xiph.org/releases/vorbis/${BP}.tar.xz \
-           file://0001-configure-Check-for-clang.patch \
-           file://CVE-2017-14633.patch \
-           file://CVE-2017-14632.patch \
-           file://CVE-2018-5146.patch \
-           file://CVE-2017-14160.patch \
-           file://CVE-2018-10392.patch \
-          "
-SRC_URI[md5sum] = "28cb28097c07a735d6af56e598e1c90f"
-SRC_URI[sha256sum] = "54f94a9527ff0a88477be0a71c0bab09a4c3febe0ed878b24824906cd4b0e1d1"
-
-inherit autotools pkgconfig
diff --git a/poky/meta/recipes-multimedia/libvorbis/libvorbis_1.3.6.bb b/poky/meta/recipes-multimedia/libvorbis/libvorbis_1.3.6.bb
new file mode 100644
index 0000000..cbda6dc
--- /dev/null
+++ b/poky/meta/recipes-multimedia/libvorbis/libvorbis_1.3.6.bb
@@ -0,0 +1,21 @@
+SUMMARY = "Ogg Vorbis Audio Codec"
+DESCRIPTION = "Ogg Vorbis is a high-quality lossy audio codec \
+that is free of intellectual property restrictions. libvorbis \
+is the main vorbis codec library."
+HOMEPAGE = "http://www.vorbis.com/"
+BUGTRACKER = "https://trac.xiph.org"
+SECTION = "libs"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=70c7063491d2d9f76a098d62ed5134f1 \
+                    file://include/vorbis/vorbisenc.h;beginline=1;endline=11;md5=d1c1d138863d6315131193d4046d81cb"
+DEPENDS = "libogg"
+
+SRC_URI = "http://downloads.xiph.org/releases/vorbis/${BP}.tar.xz \
+           file://0001-configure-Check-for-clang.patch \
+           file://CVE-2018-10392.patch \
+           file://CVE-2017-14160.patch \
+          "
+SRC_URI[md5sum] = "b7d1692f275c73e7833ed1cc2697cd65"
+SRC_URI[sha256sum] = "af00bb5a784e7c9e69f56823de4637c350643deedaf333d0fa86ecdba6fcb415"
+
+inherit autotools pkgconfig
diff --git a/poky/meta/recipes-multimedia/pulseaudio/pulseaudio.inc b/poky/meta/recipes-multimedia/pulseaudio/pulseaudio.inc
index 8189a56..f526690 100644
--- a/poky/meta/recipes-multimedia/pulseaudio/pulseaudio.inc
+++ b/poky/meta/recipes-multimedia/pulseaudio/pulseaudio.inc
@@ -16,9 +16,6 @@
 # The src/pulsecore/filter/ directory contains code under the 3-clause BSD
 # license.
 #
-# src/utils/qpaeq is licensed under AGPL. qpaeq is not installed by this
-# recipe, however, which is why AGPL is not mentioned in LICENSE.
-#
 # People who distribute PulseAudio binaries need to also consider that there
 # are some dependencies to GPL libraries. LGPL code that depends on GPL
 # libraries probably becomes effectively GPL-licensed (at compile-time? or at
@@ -47,16 +44,14 @@
 # section 3, and therefore libdbus's GPL license doesn't affect PulseAudio.
 LICENSE = "LGPLv2.1+ & MIT & BSD-3-Clause"
 
-LIC_FILES_CHKSUM = "file://LICENSE;md5=a848e8d03f04976778eab2348b59ed2b \
+LIC_FILES_CHKSUM = "file://LICENSE;md5=0e5cd938de1a7a53ea5adac38cc10c39 \
                     file://GPL;md5=4325afd396febcb659c36b49533135d4 \
                     file://LGPL;md5=2d5025d4aa3495befef8f17206a5b0a1 \
-                    file://AGPL;md5=73f1eb20517c55bf9493b7dd6e480788 \
                     file://src/modules/echo-cancel/adrian-license.txt;md5=abbab006a561fbffccedf1c3531f34ab \
                     file://src/pulsecore/filter/LICENSE.WEBKIT;md5=49defbaffddf8c51faf606ff7fc3b1f7 \
                     file://src/pulsecore/resampler.h;beginline=4;endline=21;md5=09794012ae16912c0270f3280cc8ff84 \
                     file://src/modules/reserve.h;beginline=6;endline=28;md5=0e23094760367d51b6609750e9b31fbb \
                     file://src/pulsecore/rtkit.h;beginline=6;endline=29;md5=3f00ff966716ae0817c31576d1473528 \
-                    file://src/utils/qpaeq;beginline=2;endline=16;md5=7f62515a4762f0c3fc3d4201858bb964 \
                     file://src/modules/echo-cancel/adrian-aec.h;beginline=3;endline=12;md5=d3ed4fad1c073f8b06f37495dc5d1026 \
                     file://src/pulsecore/filter/biquad.h;beginline=1;endline=4;md5=6d46d1365206528a20137355924233c1 \
 "
@@ -93,10 +88,6 @@
 # ddbd713293 without explaining why it was not made a PACKAGECONFIG item
 # instead. Oh well, let's keep it disabled until someone expresses some
 # interest in having it enabled.
-#
-# One nice thing about disabling this is that it also prevents qpaeq from
-# being installed, so we avoid adding AGPL to the list of licenses (nothing
-# else in PulseAudio is licensed under AGPL).
 EXTRA_OECONF += "--without-fftw"
 
 # The "adrian" echo canceller implementation has a non-standard license
@@ -106,6 +97,10 @@
 # very good anyway, better alternatives exist (such as the webrtc canceller).
 EXTRA_OECONF += "--disable-adrian-aec"
 
+# FIXME: The gsettings module is temporarily disabled, because adding support
+# for it is a bit complicated.
+EXTRA_OECONF += "--disable-gsettings"
+
 PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', '${BLUEZ}', '', d)} \
                    ${@bb.utils.contains('DISTRO_FEATURES', 'zeroconf', 'avahi', '', d)} \
                    ${@bb.utils.contains('DISTRO_FEATURES', '3g', 'ofono', '', d)} \
diff --git a/poky/meta/recipes-multimedia/pulseaudio/pulseaudio/0001-memfd-wrappers-only-define-memfd_create-if-not-alrea.patch b/poky/meta/recipes-multimedia/pulseaudio/pulseaudio/0001-memfd-wrappers-only-define-memfd_create-if-not-alrea.patch
deleted file mode 100644
index 0391f37..0000000
--- a/poky/meta/recipes-multimedia/pulseaudio/pulseaudio/0001-memfd-wrappers-only-define-memfd_create-if-not-alrea.patch
+++ /dev/null
@@ -1,66 +0,0 @@
-From 0cb66c0c5aafd48b63a755860746e70afb332c8d Mon Sep 17 00:00:00 2001
-From: Tanu Kaskinen <tanuk@iki.fi>
-Date: Wed, 24 Jan 2018 03:51:49 +0200
-Subject: [PATCH] memfd-wrappers: only define memfd_create() if not already
- defined
-
-glibc 2.27 is to be released soon, and it will provide memfd_create().
-If glibc provides the function, we must not define it ourselves,
-otherwise building fails due to conflict between the two implementations
-of the same function.
-
-BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=104733
----
-Upstream-Status: Submitted [https://bugs.freedesktop.org/attachment.cgi?id=136927]
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
- configure.ac                   | 3 +++
- src/pulsecore/memfd-wrappers.h | 7 ++++---
- 2 files changed, 7 insertions(+), 3 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index 77b5ff5..3a71fd8 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -607,6 +607,9 @@ AS_IF([test "x$enable_memfd" = "xyes" && test "x$HAVE_MEMFD" = "x0"],
-     [AC_MSG_ERROR([*** Your Linux kernel does not support memfd shared memory.
-                   *** Use linux v3.17 or higher for such a feature.])])
- 
-+AS_IF([test "x$HAVE_MEMFD" = "x1"],
-+    AC_CHECK_FUNCS([memfd_create]))
-+
- AC_SUBST(HAVE_MEMFD)
- AM_CONDITIONAL([HAVE_MEMFD], [test "x$HAVE_MEMFD" = x1])
- AS_IF([test "x$HAVE_MEMFD" = "x1"], AC_DEFINE([HAVE_MEMFD], 1, [Have memfd shared memory.]))
-diff --git a/src/pulsecore/memfd-wrappers.h b/src/pulsecore/memfd-wrappers.h
-index 3bed9b2..c7aadfd 100644
---- a/src/pulsecore/memfd-wrappers.h
-+++ b/src/pulsecore/memfd-wrappers.h
-@@ -20,13 +20,14 @@
-   License along with PulseAudio; if not, see <http://www.gnu.org/licenses/>.
- ***/
- 
--#ifdef HAVE_MEMFD
-+#if defined(HAVE_MEMFD) && !defined(HAVE_MEMFD_CREATE)
- 
- #include <sys/syscall.h>
- #include <fcntl.h>
- 
- /*
-- * No glibc wrappers exist for memfd_create(2), so provide our own.
-+ * Before glibc version 2.27 there was no wrapper for memfd_create(2),
-+ * so we have to provide our own.
-  *
-  * Also define memfd fcntl sealing macros. While they are already
-  * defined in the kernel header file <linux/fcntl.h>, that file as
-@@ -63,6 +64,6 @@ static inline int memfd_create(const char *name, unsigned int flags) {
- #define F_SEAL_WRITE    0x0008  /* prevent writes */
- #endif
- 
--#endif /* HAVE_MEMFD */
-+#endif /* HAVE_MEMFD && !HAVE_MEMFD_CREATE */
- 
- #endif
--- 
-2.16.1
-
diff --git a/poky/meta/recipes-multimedia/pulseaudio/pulseaudio/0001-padsp-Make-it-compile-on-musl.patch b/poky/meta/recipes-multimedia/pulseaudio/pulseaudio/0001-padsp-Make-it-compile-on-musl.patch
deleted file mode 100644
index 8555995..0000000
--- a/poky/meta/recipes-multimedia/pulseaudio/pulseaudio/0001-padsp-Make-it-compile-on-musl.patch
+++ /dev/null
@@ -1,70 +0,0 @@
-From f6ab3c3aa7a1841c8add04828029356d2a8c88e7 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 6 Apr 2015 21:56:31 -0700
-Subject: [PATCH] padsp: Make it compile on musl
-
-break assumptions on glibc and there is no stat64 on non
-glibc C libraries
-
-See pulseaudio bug
-
-https://bugs.freedesktop.org/show_bug.cgi?id=85319
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/utils/padsp.c | 15 +++++++++------
- 1 file changed, 9 insertions(+), 6 deletions(-)
-
-diff --git a/src/utils/padsp.c b/src/utils/padsp.c
-index e61373c..684721a 100644
---- a/src/utils/padsp.c
-+++ b/src/utils/padsp.c
-@@ -2368,7 +2368,7 @@ fail:
-     return ret;
- }
- 
--#ifdef sun
-+#ifndef __GLIBC__
- int ioctl(int fd, int request, ...) {
- #else
- int ioctl(int fd, unsigned long request, ...) {
-@@ -2508,10 +2508,13 @@ int stat(const char *pathname, struct stat *buf) {
- 
-     return 0;
- }
--
- #ifdef HAVE_OPEN64
--
-+#undef stat64
-+#ifdef __GLIBC__
- int stat64(const char *pathname, struct stat64 *buf) {
-+#else
-+int stat64(const char *pathname, struct stat *buf) {
-+#endif
-     struct stat oldbuf;
-     int ret;
- 
-@@ -2544,7 +2547,7 @@ int stat64(const char *pathname, struct stat64 *buf) {
- 
-     return 0;
- }
--
-+#undef open64
- int open64(const char *filename, int flags, ...) {
-     va_list args;
-     mode_t mode = 0;
-@@ -2670,8 +2673,8 @@ FILE* fopen(const char *filename, const char *mode) {
- }
- 
- #ifdef HAVE_OPEN64
--
--FILE *fopen64(const char *filename, const char *mode) {
-+#undef fopen64
-+FILE *fopen64(const char *__restrict filename, const char *__restrict mode) {
- 
-     debug(DEBUG_LEVEL_VERBOSE, __FILE__": fopen64(%s)\n", filename?filename:"NULL");
- 
--- 
-2.1.4
-
diff --git a/poky/meta/recipes-multimedia/pulseaudio/pulseaudio_11.1.bb b/poky/meta/recipes-multimedia/pulseaudio/pulseaudio_11.1.bb
deleted file mode 100644
index 245302d..0000000
--- a/poky/meta/recipes-multimedia/pulseaudio/pulseaudio_11.1.bb
+++ /dev/null
@@ -1,15 +0,0 @@
-require pulseaudio.inc
-
-SRC_URI = "http://freedesktop.org/software/pulseaudio/releases/${BP}.tar.xz \
-           file://0001-padsp-Make-it-compile-on-musl.patch \
-           file://0001-client-conf-Add-allow-autospawn-for-root.patch \
-           file://volatiles.04_pulse \
-           file://0001-memfd-wrappers-only-define-memfd_create-if-not-alrea.patch \
-           "
-SRC_URI[md5sum] = "390de38231d5cdd6b43ada8939eb74f1"
-SRC_URI[sha256sum] = "f2521c525a77166189e3cb9169f75c2ee2b82fa3fcf9476024fbc2c3a6c9cd9e"
-
-do_compile_prepend() {
-    mkdir -p ${S}/libltdl
-    cp ${STAGING_LIBDIR}/libltdl* ${S}/libltdl
-}
diff --git a/poky/meta/recipes-multimedia/pulseaudio/pulseaudio_12.2.bb b/poky/meta/recipes-multimedia/pulseaudio/pulseaudio_12.2.bb
new file mode 100644
index 0000000..36d92bc
--- /dev/null
+++ b/poky/meta/recipes-multimedia/pulseaudio/pulseaudio_12.2.bb
@@ -0,0 +1,13 @@
+require pulseaudio.inc
+
+SRC_URI = "http://freedesktop.org/software/pulseaudio/releases/${BP}.tar.xz \
+           file://0001-client-conf-Add-allow-autospawn-for-root.patch \
+           file://volatiles.04_pulse \
+           "
+SRC_URI[md5sum] = "c42f1f1465e8df9859d023dc184734bf"
+SRC_URI[sha256sum] = "809668ffc296043779c984f53461c2b3987a45b7a25eb2f0a1d11d9f23ba4055"
+
+do_compile_prepend() {
+    mkdir -p ${S}/libltdl
+    cp ${STAGING_LIBDIR}/libltdl* ${S}/libltdl
+}
diff --git a/poky/meta/recipes-multimedia/webp/libwebp_0.6.1.bb b/poky/meta/recipes-multimedia/webp/libwebp_0.6.1.bb
deleted file mode 100644
index e9d4d78..0000000
--- a/poky/meta/recipes-multimedia/webp/libwebp_0.6.1.bb
+++ /dev/null
@@ -1,54 +0,0 @@
-SUMMARY = "WebP is an image format designed for the Web"
-DESCRIPTION = "WebP is a method of lossy and lossless compression that can be \
-               used on a large variety of photographic, translucent and \
-               graphical images found on the web. The degree of lossy \
-               compression is adjustable so a user can choose the trade-off \
-               between file size and image quality. WebP typically achieves \
-               an average of 30% more compression than JPEG and JPEG 2000, \
-               without loss of image quality."
-HOMEPAGE = "https://developers.google.com/speed/webp/"
-SECTION = "libs"
-
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=6e8dee932c26f2dab503abf70c96d8bb \
-                    file://PATENTS;md5=c6926d0cb07d296f886ab6e0cc5a85b7"
-
-SRC_URI = "http://downloads.webmproject.org/releases/webp/${BP}.tar.gz"
-SRC_URI[md5sum] = "b49ce9c3e3e9acae4d91bca44bb85a72"
-SRC_URI[sha256sum] = "06503c782d9f151baa325591c3579c68ed700ffc62d4f5a32feead0ff017d8ab"
-
-UPSTREAM_CHECK_URI = "http://downloads.webmproject.org/releases/webp/index.html"
-
-EXTRA_OECONF = " \
-    --disable-experimental \
-    --disable-wic \
-    --enable-libwebpmux \
-    --enable-libwebpdemux \
-    --enable-threading \
-"
-# Do not trust configure to determine if neon is available.
-#
-EXTRA_OECONF_append_arm = " \
-    ${@bb.utils.contains("TUNE_FEATURES","neon","--enable-neon","--disable-neon",d)} \
-"
-
-inherit autotools lib_package
-
-PACKAGECONFIG ??= ""
-
-# libwebpdecoder is a subset of libwebp, don't build it unless requested
-PACKAGECONFIG[decoder] = "--enable-libwebpdecoder,--disable-libwebpdecoder"
-
-# Apply for examples programs: cwebp and dwebp
-PACKAGECONFIG[gif] = "--enable-gif,--disable-gif,giflib"
-PACKAGECONFIG[jpeg] = "--enable-jpeg,--disable-jpeg,jpeg"
-PACKAGECONFIG[png] = "--enable-png,--disable-png,,libpng"
-PACKAGECONFIG[tiff] = "--enable-tiff,--disable-tiff,tiff"
-
-# Apply only for example program vwebp
-PACKAGECONFIG[gl] = "--enable-gl,--disable-gl,mesa-glut"
-
-PACKAGES =+ "${PN}-gif2webp"
-
-DESCRIPTION_${PN}-gif2webp = "Simple tool to convert animated GIFs to WebP"
-FILES_${PN}-gif2webp = "${bindir}/gif2webp"
diff --git a/poky/meta/recipes-multimedia/webp/libwebp_1.0.0.bb b/poky/meta/recipes-multimedia/webp/libwebp_1.0.0.bb
new file mode 100644
index 0000000..1a9679f
--- /dev/null
+++ b/poky/meta/recipes-multimedia/webp/libwebp_1.0.0.bb
@@ -0,0 +1,53 @@
+SUMMARY = "WebP is an image format designed for the Web"
+DESCRIPTION = "WebP is a method of lossy and lossless compression that can be \
+               used on a large variety of photographic, translucent and \
+               graphical images found on the web. The degree of lossy \
+               compression is adjustable so a user can choose the trade-off \
+               between file size and image quality. WebP typically achieves \
+               an average of 30% more compression than JPEG and JPEG 2000, \
+               without loss of image quality."
+HOMEPAGE = "https://developers.google.com/speed/webp/"
+SECTION = "libs"
+
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=6e8dee932c26f2dab503abf70c96d8bb \
+                    file://PATENTS;md5=c6926d0cb07d296f886ab6e0cc5a85b7"
+
+SRC_URI = "http://downloads.webmproject.org/releases/webp/${BP}.tar.gz"
+SRC_URI[md5sum] = "967b8f087cb392e6cc94d5e116a120c0"
+SRC_URI[sha256sum] = "84259c4388f18637af3c5a6361536d754a5394492f91be1abc2e981d4983225b"
+
+UPSTREAM_CHECK_URI = "http://downloads.webmproject.org/releases/webp/index.html"
+
+EXTRA_OECONF = " \
+    --disable-wic \
+    --enable-libwebpmux \
+    --enable-libwebpdemux \
+    --enable-threading \
+"
+# Do not trust configure to determine if neon is available.
+#
+EXTRA_OECONF_append_arm = " \
+    ${@bb.utils.contains("TUNE_FEATURES","neon","--enable-neon","--disable-neon",d)} \
+"
+
+inherit autotools lib_package
+
+PACKAGECONFIG ??= ""
+
+# libwebpdecoder is a subset of libwebp, don't build it unless requested
+PACKAGECONFIG[decoder] = "--enable-libwebpdecoder,--disable-libwebpdecoder"
+
+# Apply for examples programs: cwebp and dwebp
+PACKAGECONFIG[gif] = "--enable-gif,--disable-gif,giflib"
+PACKAGECONFIG[jpeg] = "--enable-jpeg,--disable-jpeg,jpeg"
+PACKAGECONFIG[png] = "--enable-png,--disable-png,,libpng"
+PACKAGECONFIG[tiff] = "--enable-tiff,--disable-tiff,tiff"
+
+# Apply only for example program vwebp
+PACKAGECONFIG[gl] = "--enable-gl,--disable-gl,mesa-glut"
+
+PACKAGES =+ "${PN}-gif2webp"
+
+DESCRIPTION_${PN}-gif2webp = "Simple tool to convert animated GIFs to WebP"
+FILES_${PN}-gif2webp = "${bindir}/gif2webp"
diff --git a/poky/meta/recipes-rt/rt-tests/rt-tests.inc b/poky/meta/recipes-rt/rt-tests/rt-tests.inc
index 5606d8e..f87952e 100644
--- a/poky/meta/recipes-rt/rt-tests/rt-tests.inc
+++ b/poky/meta/recipes-rt/rt-tests/rt-tests.inc
@@ -3,6 +3,8 @@
 PE = "1"
 
 SRC_URI = "git://git.kernel.org/pub/scm/utils/rt-tests/rt-tests.git"
+# 1.2 and 1.3 seem to be development versions
+UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>(?!1\.2)(?!1\.3)(\d+(\.\d+)+))"
 
 S = "${WORKDIR}/git"
 
diff --git a/poky/meta/recipes-sato/matchbox-sato/matchbox-session-sato/session b/poky/meta/recipes-sato/matchbox-sato/matchbox-session-sato/session
index f6313bd..3a70574 100644
--- a/poky/meta/recipes-sato/matchbox-sato/matchbox-session-sato/session
+++ b/poky/meta/recipes-sato/matchbox-sato/matchbox-session-sato/session
@@ -20,7 +20,10 @@
 # doesn't have the feature "foo".
 
 START_APPLETS=showdesktop,windowselector
-END_APPLETS=clock,battery,$KEYBOARD_APPLET,systray,startup-notify,notify
+END_APPLETS=$KEYBOARD_APPLET,systray,startup-notify,notify
+END_APPLETS=battery,$END_APPLETS # feature-acpi
+END_APPLETS=battery,$END_APPLETS # feature-apm
+END_APPLETS=clock,$END_APPLETS
 END_APPLETS=openmoko-panel-gsm,$END_APPLETS # feature-phone
 
 matchbox-panel --start-applets $START_APPLETS --end-applets $END_APPLETS &
diff --git a/poky/meta/recipes-sato/matchbox-sato/matchbox-session-sato_0.1.bb b/poky/meta/recipes-sato/matchbox-sato/matchbox-session-sato_0.1.bb
index d146e83..8230e95 100644
--- a/poky/meta/recipes-sato/matchbox-sato/matchbox-session-sato_0.1.bb
+++ b/poky/meta/recipes-sato/matchbox-sato/matchbox-session-sato_0.1.bb
@@ -26,7 +26,7 @@
 
 do_install() {
 	# This is the set of machine features that the script has markers for
-	FEATURES="phone"
+	FEATURES="acpi apm phone"
 	SCRIPT="${S}/sedder"
 	rm -f $SCRIPT
 	touch $SCRIPT
diff --git a/poky/meta/recipes-sato/matchbox-terminal/matchbox-terminal_0.1.bb b/poky/meta/recipes-sato/matchbox-terminal/matchbox-terminal_0.1.bb
deleted file mode 100644
index 4488191..0000000
--- a/poky/meta/recipes-sato/matchbox-terminal/matchbox-terminal_0.1.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-SUMMARY = "Lightweight GTK+ terminal application"
-HOMEPAGE = "http://www.matchbox-project.org/"
-BUGTRACKER = "http://bugzilla.yoctoproject.org/"
-
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
-                    file://main.c;endline=20;md5=96e39176d9e355639a0b8b1c7a840820"
-
-DEPENDS = "gtk+3 vte"
-SECTION = "x11/utils"
-
-#SRCREV tagged 0.1
-SRCREV = "3ad357db2302760b8a8817b5f4478dd87479442f"
-SRC_URI = "git://git.yoctoproject.org/${BPN}"
-UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>(\d+(\.\d+)+))"
-
-S = "${WORKDIR}/git"
-
-inherit autotools pkgconfig distro_features_check
-
-ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
diff --git a/poky/meta/recipes-sato/matchbox-terminal/matchbox-terminal_0.2.bb b/poky/meta/recipes-sato/matchbox-terminal/matchbox-terminal_0.2.bb
new file mode 100644
index 0000000..7f5eda3
--- /dev/null
+++ b/poky/meta/recipes-sato/matchbox-terminal/matchbox-terminal_0.2.bb
@@ -0,0 +1,21 @@
+SUMMARY = "Lightweight GTK+ terminal application"
+HOMEPAGE = "http://www.matchbox-project.org/"
+BUGTRACKER = "http://bugzilla.yoctoproject.org/"
+
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
+                    file://main.c;endline=20;md5=96e39176d9e355639a0b8b1c7a840820"
+
+DEPENDS = "gtk+3 vte"
+SECTION = "x11/utils"
+
+#SRCREV tagged 0.2
+SRCREV = "161276d0f5d1be8187010fd0d9581a6feca70ea5"
+SRC_URI = "git://git.yoctoproject.org/${BPN}"
+UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>(\d+(\.\d+)+))"
+
+S = "${WORKDIR}/git"
+
+inherit autotools pkgconfig distro_features_check
+
+ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
diff --git a/poky/meta/recipes-sato/packagegroups/packagegroup-core-x11-sato.bb b/poky/meta/recipes-sato/packagegroups/packagegroup-core-x11-sato.bb
index 224428d..7e14ece 100644
--- a/poky/meta/recipes-sato/packagegroups/packagegroup-core-x11-sato.bb
+++ b/poky/meta/recipes-sato/packagegroups/packagegroup-core-x11-sato.bb
@@ -32,9 +32,8 @@
     adwaita-icon-theme \
     settings-daemon \
     shutdown-desktop \
-    libsdl \
     ${NETWORK_MANAGER} \
-    udev-extraconf \
+    ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '', 'udev-extraconf', d)} \
     ${@bb.utils.contains('DISTRO_FEATURES', 'pulseaudio', 'pulseaudio-server pulseaudio-client-conf-sato pulseaudio-misc', '', d)} \
     "
 
@@ -43,13 +42,16 @@
 WEB ?= ""
 #WEB = "epiphany"
 
+GSTEXAMPLES ?= "gst-examples"
+GSTEXAMPLES_riscv64 = ""
+
 SUMMARY_${PN}-apps = "Sato desktop - applications"
 RDEPENDS_${PN}-apps = "\
     l3afpad \
-    gst-examples \
     matchbox-terminal \
     sato-screenshot \
     ${FILEMANAGER} \
+    ${GSTEXAMPLES} \
     ${WEB} \
     "
 
diff --git a/poky/meta/recipes-sato/pcmanfm/pcmanfm_1.2.5.bb b/poky/meta/recipes-sato/pcmanfm/pcmanfm_1.2.5.bb
deleted file mode 100644
index 4127a07..0000000
--- a/poky/meta/recipes-sato/pcmanfm/pcmanfm_1.2.5.bb
+++ /dev/null
@@ -1,40 +0,0 @@
-SUMMARY = "Fast lightweight tabbed filemanager"
-HOMEPAGE = "http://pcmanfm.sourceforge.net/"
-
-LICENSE = "GPLv2 & GPLv2+ & LGPLv2.1+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
-                    file://src/pcmanfm.h;endline=22;md5=417b3855771a3a87f8ad753d994491f0 \
-                    file://src/gseal-gtk-compat.h;endline=21;md5=46922c8691f58d124f9420fe16149ce2"
-
-SECTION = "x11"
-DEPENDS = "gtk+3 startup-notification libfm intltool-native gettext-native glib-2.0-native"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/pcmanfm/pcmanfm-${PV}.tar.xz \
-	   file://gnome-fs-directory.png \
-	   file://gnome-fs-regular.png \
-	   file://gnome-mime-text-plain.png \
-	   file://emblem-symbolic-link.png \
-	   file://no-desktop.patch"
-
-SRC_URI[md5sum] = "b4d1f8ce08d87e4f27805a246fc51ac2"
-SRC_URI[sha256sum] = "0c86cac028b705ff314c7464d814c2cf7ff604c17491c20aa204b1ef1a80ad67"
-
-UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/pcmanfm/files/PCManFM%20%2B%20Libfm%20%28tarball%20release%29/PCManFM/"
-
-inherit autotools pkgconfig distro_features_check
-
-# The startup-notification requires x11 in DISTRO_FEATURES
-REQUIRED_DISTRO_FEATURES = "x11"
-
-EXTRA_OECONF = "--with-gtk=3"
-
-do_install_append () {
-	install -d ${D}/${datadir}
-	install -d ${D}/${datadir}/pixmaps/
-
-	install -m 0644 ${WORKDIR}/*.png ${D}/${datadir}/pixmaps
-}
-
-FILES_${PN} += "${libdir}/pcmanfm"
-
-RRECOMMENDS_${PN} += "adwaita-icon-theme"
diff --git a/poky/meta/recipes-sato/pcmanfm/pcmanfm_1.3.0.bb b/poky/meta/recipes-sato/pcmanfm/pcmanfm_1.3.0.bb
new file mode 100644
index 0000000..356da02
--- /dev/null
+++ b/poky/meta/recipes-sato/pcmanfm/pcmanfm_1.3.0.bb
@@ -0,0 +1,40 @@
+SUMMARY = "Fast lightweight tabbed filemanager"
+HOMEPAGE = "http://pcmanfm.sourceforge.net/"
+
+LICENSE = "GPLv2 & GPLv2+ & LGPLv2.1+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
+                    file://src/pcmanfm.h;endline=22;md5=417b3855771a3a87f8ad753d994491f0 \
+                    file://src/gseal-gtk-compat.h;endline=21;md5=46922c8691f58d124f9420fe16149ce2"
+
+SECTION = "x11"
+DEPENDS = "gtk+3 startup-notification libfm intltool-native gettext-native glib-2.0-native"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/pcmanfm/pcmanfm-${PV}.tar.xz \
+	   file://gnome-fs-directory.png \
+	   file://gnome-fs-regular.png \
+	   file://gnome-mime-text-plain.png \
+	   file://emblem-symbolic-link.png \
+	   file://no-desktop.patch"
+
+SRC_URI[md5sum] = "827838f7f6b17dc97e1690c07da8fdb3"
+SRC_URI[sha256sum] = "5a693e9bf3f3294f0ee7264c1c1a600a88ee27d1572e7dd5c4b0e84aa7778ffb"
+
+UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/pcmanfm/files/PCManFM%20%2B%20Libfm%20%28tarball%20release%29/PCManFM/"
+
+inherit autotools pkgconfig distro_features_check
+
+# The startup-notification requires x11 in DISTRO_FEATURES
+REQUIRED_DISTRO_FEATURES = "x11"
+
+EXTRA_OECONF = "--with-gtk=3"
+
+do_install_append () {
+	install -d ${D}/${datadir}
+	install -d ${D}/${datadir}/pixmaps/
+
+	install -m 0644 ${WORKDIR}/*.png ${D}/${datadir}/pixmaps
+}
+
+FILES_${PN} += "${libdir}/pcmanfm"
+
+RRECOMMENDS_${PN} += "adwaita-icon-theme"
diff --git a/poky/meta/recipes-sato/puzzles/puzzles_git.bb b/poky/meta/recipes-sato/puzzles/puzzles_git.bb
index bfd8177..7d08b96 100644
--- a/poky/meta/recipes-sato/puzzles/puzzles_git.bb
+++ b/poky/meta/recipes-sato/puzzles/puzzles_git.bb
@@ -1,22 +1,22 @@
 SUMMARY = "Simon Tatham's Portable Puzzle Collection"
 HOMEPAGE = "http://www.chiark.greenend.org.uk/~sgtatham/puzzles/"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENCE;md5=da6110d4ed1225a287eab2bf0ac0193b"
 
 DEPENDS = "libxt"
 
 # The libxt requires x11 in DISTRO_FEATURES
 REQUIRED_DISTRO_FEATURES = "x11"
 
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://LICENCE;md5=da6110d4ed1225a287eab2bf0ac0193b"
-
 SRC_URI = "git://git.tartarus.org/simon/puzzles.git \
            file://fix-compiling-failure-with-option-g-O.patch \
            file://0001-Use-labs-instead-of-abs.patch \
            file://0001-palisade-Fix-warnings-with-clang-on-arm.patch \
            file://0001-Use-Wno-error-format-overflow-if-the-compiler-suppor.patch \
            "
+
 UPSTREAM_CHECK_COMMITS = "1"
-SRCREV = "2adf0052d66eae88c7a5e55e67fe16e13f7018b5"
+SRCREV = "c6e0161dd475415316ed66dc82794d68e52f0025"
 PE = "2"
 PV = "0.0+git${SRCPV}"
 
@@ -24,24 +24,13 @@
 
 inherit autotools distro_features_check pkgconfig
 
-CFLAGS_append = " -Wno-deprecated-declarations"
-
 PACKAGECONFIG ??= "gtk3"
 PACKAGECONFIG[gtk2] = "--with-gtk=2,,gtk+,"
 PACKAGECONFIG[gtk3] = "--with-gtk=3,,gtk+3,"
 
-PACKAGES += "${PN}-extra"
-FILES_${PN} = ""
-FILES_${PN}-extra = "${prefix}/bin ${datadir}/applications"
+CFLAGS_append = " -Wno-deprecated-declarations"
 
-python __anonymous () {
-    var = d.expand("FILES_${PN}")
-    data = d.getVar(var, False)
-    for name in ("bridges", "fifteen", "inertia", "map", "samegame", "slant"):
-        data = data + " ${bindir}/%s" % name
-        data = data + " ${datadir}/applications/%s.desktop" % name
-    d.setVar(var, data)
-}
+ASNEEDED = ""
 
 do_configure_prepend () {
     cd ${S}
@@ -74,3 +63,17 @@
         fi
     done
 }
+
+PACKAGES += "${PN}-extra"
+
+FILES_${PN} = ""
+FILES_${PN}-extra = "${prefix}/bin ${datadir}/applications"
+
+python __anonymous () {
+    var = d.expand("FILES_${PN}")
+    data = d.getVar(var, False)
+    for name in ("bridges", "fifteen", "inertia", "map", "samegame", "slant"):
+        data = data + " ${bindir}/%s" % name
+        data = data + " ${datadir}/applications/%s.desktop" % name
+    d.setVar(var, data)
+}
diff --git a/poky/meta/recipes-sato/webkit/webkitgtk/0001-Fix-PaintingData-has-no-member-named-lightVector-on-.patch b/poky/meta/recipes-sato/webkit/webkitgtk/0001-Fix-PaintingData-has-no-member-named-lightVector-on-.patch
new file mode 100644
index 0000000..25f4846
--- /dev/null
+++ b/poky/meta/recipes-sato/webkit/webkitgtk/0001-Fix-PaintingData-has-no-member-named-lightVector-on-.patch
@@ -0,0 +1,37 @@
+From a5d4e038268ae23486fecc1966fd2e16a7f40ce8 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Wed, 25 Jul 2018 00:23:48 -0700
+Subject: [PATCH] Fix PaintingData' has no member named 'lightVector' on
+ ARM_NEON
+
+* platform/graphics/cpu/arm/filters/FELightingNEON.h:
+(WebCore::FELighting::platformApplyNeon):
+
+Upstream-Status: Submitted
+https://bugs.webkit.org/show_bug.cgi?id=187991
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ Source/WebCore/platform/graphics/cpu/arm/filters/FELightingNEON.h | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/Source/WebCore/platform/graphics/cpu/arm/filters/FELightingNEON.h b/Source/WebCore/platform/graphics/cpu/arm/filters/FELightingNEON.h
+index 42af922..b542a4c 100644
+--- a/Source/WebCore/platform/graphics/cpu/arm/filters/FELightingNEON.h
++++ b/Source/WebCore/platform/graphics/cpu/arm/filters/FELightingNEON.h
+@@ -144,9 +144,9 @@ inline void FELighting::platformApplyNeon(const LightingData& data, const LightS
+             neonData.flags |= FLAG_CONE_EXPONENT_IS_1;
+     } else {
+         ASSERT(m_lightSource->type() == LS_DISTANT);
+-        floatArguments.lightX = paintingData.lightVector.x();
+-        floatArguments.lightY = paintingData.lightVector.y();
+-        floatArguments.lightZ = paintingData.lightVector.z();
++        floatArguments.lightX = paintingData.initialLightingData.lightVector.x();
++        floatArguments.lightY = paintingData.initialLightingData.lightVector.y();
++        floatArguments.lightZ = paintingData.initialLightingData.lightVector.z();
+         floatArguments.padding2 = 1;
+     }
+ 
+-- 
+2.10.2
+
diff --git a/poky/meta/recipes-sato/webkit/webkitgtk/0001-Fix-build-with-musl.patch b/poky/meta/recipes-sato/webkit/webkitgtk/0001-Fix-build-with-musl.patch
index 7cc4514..041ec46 100644
--- a/poky/meta/recipes-sato/webkit/webkitgtk/0001-Fix-build-with-musl.patch
+++ b/poky/meta/recipes-sato/webkit/webkitgtk/0001-Fix-build-with-musl.patch
@@ -1,24 +1,25 @@
-From 415e31bd5444fa360af58b069f1b9db6607fca7d Mon Sep 17 00:00:00 2001
+From 4f9d736e0458ed33cd161cd164ad0acdac939f44 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Fri, 6 Oct 2017 17:00:08 +0300
 Subject: [PATCH] Fix build with musl
 
 Upstream-Status: Pending
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
 ---
- Source/JavaScriptCore/runtime/MachineContext.h | 10 +++++-----
+ Source/JavaScriptCore/runtime/MachineContext.h | 18 +++++++++++++++++-
  Source/WTF/wtf/Platform.h                      |  2 +-
- 2 files changed, 6 insertions(+), 6 deletions(-)
+ 2 files changed, 18 insertions(+), 2 deletions(-)
 
 diff --git a/Source/JavaScriptCore/runtime/MachineContext.h b/Source/JavaScriptCore/runtime/MachineContext.h
-index 95080b9..2bb689c 100644
+index bf0bdc7..84b8a8a 100644
 --- a/Source/JavaScriptCore/runtime/MachineContext.h
 +++ b/Source/JavaScriptCore/runtime/MachineContext.h
 @@ -146,7 +146,7 @@ inline void*& stackPointer(mcontext_t& machineContext)
  #error Unknown Architecture
  #endif
  
--#elif defined(__GLIBC__)
+-#elif defined(__GLIBC__) || defined(__BIONIC__)
 +#elif defined(__linux__)
  
  #if CPU(X86)
@@ -27,7 +28,7 @@
  #error Unknown Architecture
  #endif
  
--#elif defined(__GLIBC__)
+-#elif defined(__GLIBC__) || defined(__BIONIC__)
 +#elif defined(__linux__)
  
  // The following sequence depends on glibc's sys/ucontext.h.
@@ -36,7 +37,7 @@
  #error Unknown Architecture
  #endif
  
--#elif defined(__GLIBC__)
+-#elif defined(__GLIBC__) || defined(__BIONIC__)
 +#elif defined(__linux__)
  
  // The following sequence depends on glibc's sys/ucontext.h.
@@ -45,7 +46,7 @@
  #error Unknown Architecture
  #endif
  
--#elif defined(__GLIBC__)
+-#elif defined(__GLIBC__) || defined(__BIONIC__)
 +#elif defined(__linux__)
  
  // The following sequence depends on glibc's sys/ucontext.h.
@@ -54,24 +55,21 @@
  #error Unknown Architecture
  #endif
  
--#elif defined(__GLIBC__)
+-#elif defined(__GLIBC__) || defined(__BIONIC__)
 +#elif defined(__linux__)
  
  // The following sequence depends on glibc's sys/ucontext.h.
  #if CPU(X86)
 diff --git a/Source/WTF/wtf/Platform.h b/Source/WTF/wtf/Platform.h
-index 5a2863b..b36c3ff 100644
+index 551c047..e50b05a 100644
 --- a/Source/WTF/wtf/Platform.h
 +++ b/Source/WTF/wtf/Platform.h
-@@ -680,7 +680,7 @@
+@@ -683,7 +683,7 @@
  #define HAVE_CFNETWORK_STORAGE_PARTITIONING 1
  #endif
  
--#if OS(DARWIN) || ((OS(FREEBSD) || defined(__GLIBC__)) && (CPU(X86) || CPU(X86_64) || CPU(ARM) || CPU(ARM64) || CPU(MIPS)))
+-#if OS(DARWIN) || ((OS(FREEBSD) || defined(__GLIBC__) || defined(__BIONIC__)) && (CPU(X86) || CPU(X86_64) || CPU(ARM) || CPU(ARM64) || CPU(MIPS)))
 +#if OS(DARWIN) || ((OS(FREEBSD) || defined(__linux__)) && (CPU(X86) || CPU(X86_64) || CPU(ARM) || CPU(ARM64) || CPU(MIPS)))
  #define HAVE_MACHINE_CONTEXT 1
  #endif
  
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-sato/webkit/webkitgtk/0001-Fix-gles3-header-when-gles2-is-enabled.patch b/poky/meta/recipes-sato/webkit/webkitgtk/0001-Fix-gles3-header-when-gles2-is-enabled.patch
deleted file mode 100644
index 2157407..0000000
--- a/poky/meta/recipes-sato/webkit/webkitgtk/0001-Fix-gles3-header-when-gles2-is-enabled.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-From adf3d4c9d4133bd6995590d921c0ccaec5254da9 Mon Sep 17 00:00:00 2001
-From: Bhargava Sreekantappa Gayathri
- <bhargava.sreekantappa-gayathri@xilinx.com>
-Date: Tue, 27 Feb 2018 16:09:31 -0800
-Subject: [PATCH] Fix gles3 header when gles2 is enabled
-
-A GLES 2 application should not use gl3.h.
-Fix the gles3 header failure while compiling webkitgtk.
-
-FAILED:
-Source/WebCore/CMakeFiles/WebCore.dir/platform/graphics/GLContext.cpp.o
-           ^~~~~~~~~~~~~
-compilation terminated.
-
-Upstream-Status: Backport
-Imported patch from: https://bugs.webkit.org/show_bug.cgi?id=183008
-
-Signed-off-by: Bhargava Sreekantappa Gayathri <bhargava.sreekantappa-gayathri@xilinx.com>
-Signed-off-by: Manjukumar Matha <manjukumar.harthikote-matha@xilinx.com>
----
- Source/WebCore/platform/graphics/GLContext.cpp | 1 -
- 1 file changed, 1 deletion(-)
-
-diff --git a/Source/WebCore/platform/graphics/GLContext.cpp b/Source/WebCore/platform/graphics/GLContext.cpp
-index 599dcc0..46d2fd4 100644
---- a/Source/WebCore/platform/graphics/GLContext.cpp
-+++ b/Source/WebCore/platform/graphics/GLContext.cpp
-@@ -31,7 +31,6 @@
- #elif USE(OPENGL_ES_2)
- #define GL_GLEXT_PROTOTYPES 1
- #include <GLES2/gl2.h>
--#include <GLES3/gl3.h>
- #endif
-
- #if USE(GLX)
---
-2.7.4
-
diff --git a/poky/meta/recipes-sato/webkit/webkitgtk/0001-Fix-racy-parallel-build-of-WebKit2-4.0.gir.patch b/poky/meta/recipes-sato/webkit/webkitgtk/0001-Fix-racy-parallel-build-of-WebKit2-4.0.gir.patch
index 896890b..aa9a067 100644
--- a/poky/meta/recipes-sato/webkit/webkitgtk/0001-Fix-racy-parallel-build-of-WebKit2-4.0.gir.patch
+++ b/poky/meta/recipes-sato/webkit/webkitgtk/0001-Fix-racy-parallel-build-of-WebKit2-4.0.gir.patch
@@ -1,7 +1,7 @@
-From b7f40eceef0f23bf88090789d4c5845c35f048ae Mon Sep 17 00:00:00 2001
+From 0afc194c6446e6c3242f1d706b4564e3a9cb2cee Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Mon, 29 Aug 2016 16:38:11 +0300
-Subject: [PATCH 4/9] Fix racy parallel build of WebKit2-4.0.gir
+Subject: [PATCH] Fix racy parallel build of WebKit2-4.0.gir
 
 Upstream-Status: Pending
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
@@ -11,39 +11,36 @@
  1 file changed, 5 insertions(+), 4 deletions(-)
 
 diff --git a/Source/WebKit/PlatformGTK.cmake b/Source/WebKit/PlatformGTK.cmake
-index a33c6a86..d83a2e77 100644
+index a074a80..8c6ebb5 100644
 --- a/Source/WebKit/PlatformGTK.cmake
 +++ b/Source/WebKit/PlatformGTK.cmake
-@@ -1122,8 +1122,9 @@ endif ()
- string(REGEX MATCHALL "-L[^ ]*"
-     INTROSPECTION_ADDITIONAL_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS}")
+@@ -728,8 +728,9 @@ if (ENABLE_INTROSPECTION)
+     string(REGEX MATCHALL "-L[^ ]*"
+         INTROSPECTION_ADDITIONAL_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS}")
  
--add_custom_command(
--    OUTPUT ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
-+# This is a target and not a command because it's used to build another .gir
-+# and a .typelib, which would trigger two racy parallel builds when using command
-+add_custom_target(WebKit2-${WEBKITGTK_API_VERSION}-gir
-     DEPENDS WebKit2
-     DEPENDS ${CMAKE_BINARY_DIR}/JavaScriptCore-${WEBKITGTK_API_VERSION}.gir
-     COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations\ ${CMAKE_C_FLAGS} LDFLAGS=
-@@ -1168,7 +1169,7 @@ add_custom_command(
- add_custom_command(
-     OUTPUT ${CMAKE_BINARY_DIR}/WebKit2WebExtension-${WEBKITGTK_API_VERSION}.gir
-     DEPENDS ${CMAKE_BINARY_DIR}/JavaScriptCore-${WEBKITGTK_API_VERSION}.gir
--    DEPENDS ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
-+    DEPENDS WebKit2-${WEBKITGTK_API_VERSION}-gir
-     COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations\ ${CMAKE_C_FLAGS}
-         LDFLAGS="${INTROSPECTION_ADDITIONAL_LDFLAGS}"
-         ${LOADER_LIBRARY_PATH_VAR}="${INTROSPECTION_ADDITIONAL_LIBRARY_PATH}"
-@@ -1225,7 +1226,7 @@ add_custom_command(
+-    add_custom_command(
+-        OUTPUT ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
++    # This is a target and not a command because it's used to build another .gir
++    # and a .typelib, which would trigger two racy parallel builds when using command
++    add_custom_target(WebKit2-${WEBKITGTK_API_VERSION}-gir
+         DEPENDS WebKit
+         DEPENDS ${CMAKE_BINARY_DIR}/JavaScriptCore-${WEBKITGTK_API_VERSION}.gir
+         COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations\ ${CMAKE_C_FLAGS} LDFLAGS=
+@@ -773,7 +774,7 @@ if (ENABLE_INTROSPECTION)
+     add_custom_command(
+         OUTPUT ${CMAKE_BINARY_DIR}/WebKit2WebExtension-${WEBKITGTK_API_VERSION}.gir
+         DEPENDS ${CMAKE_BINARY_DIR}/JavaScriptCore-${WEBKITGTK_API_VERSION}.gir
+-        DEPENDS ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
++        DEPENDS WebKit2-${WEBKITGTK_API_VERSION}-gir
+         COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations\ ${CMAKE_C_FLAGS}
+             LDFLAGS="${INTROSPECTION_ADDITIONAL_LDFLAGS}"
+             ${LOADER_LIBRARY_PATH_VAR}="${INTROSPECTION_ADDITIONAL_LIBRARY_PATH}"
+@@ -828,7 +829,7 @@ if (ENABLE_INTROSPECTION)
  
- add_custom_command(
-     OUTPUT ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.typelib
--    DEPENDS ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
-+    DEPENDS WebKit2-${WEBKITGTK_API_VERSION}-gir
-     COMMAND ${INTROSPECTION_COMPILER} --includedir=${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir -o ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.typelib
- )
+     add_custom_command(
+         OUTPUT ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.typelib
+-        DEPENDS ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
++        DEPENDS WebKit2-${WEBKITGTK_API_VERSION}-gir
+         COMMAND ${INTROSPECTION_COMPILER} --includedir=${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir -o ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.typelib
+     )
  
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-sato/webkit/webkitgtk/0001-OptionsGTK.cmake-drop-the-hardcoded-introspection-gt.patch b/poky/meta/recipes-sato/webkit/webkitgtk/0001-OptionsGTK.cmake-drop-the-hardcoded-introspection-gt.patch
index 0f6eeed..e8d1d8c 100644
--- a/poky/meta/recipes-sato/webkit/webkitgtk/0001-OptionsGTK.cmake-drop-the-hardcoded-introspection-gt.patch
+++ b/poky/meta/recipes-sato/webkit/webkitgtk/0001-OptionsGTK.cmake-drop-the-hardcoded-introspection-gt.patch
@@ -1,4 +1,4 @@
-From 48648570e449cf7f84a26dc03c1e3f620fa69757 Mon Sep 17 00:00:00 2001
+From bed4cf4aaa6aad4172ec9942e9039fb8e1ef68a4 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Mon, 29 Feb 2016 18:13:39 +0200
 Subject: [PATCH] OptionsGTK.cmake: drop the hardcoded introspection/gtkdoc
@@ -11,16 +11,17 @@
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
 
 Upstream-Status: Pending
+
 ---
  Source/cmake/OptionsGTK.cmake | 6 ------
  1 file changed, 6 deletions(-)
 
-Index: webkitgtk-2.12.1/Source/cmake/OptionsGTK.cmake
-===================================================================
---- webkitgtk-2.12.1.orig/Source/cmake/OptionsGTK.cmake
-+++ webkitgtk-2.12.1/Source/cmake/OptionsGTK.cmake
-@@ -424,12 +424,6 @@ if (USE_LIBHYPHEN)
-     endif ()
+diff --git a/Source/cmake/OptionsGTK.cmake b/Source/cmake/OptionsGTK.cmake
+index 661b40e..404441b 100644
+--- a/Source/cmake/OptionsGTK.cmake
++++ b/Source/cmake/OptionsGTK.cmake
+@@ -352,12 +352,6 @@ if (ENABLED_COMPILER_SANITIZERS)
+     set(ENABLE_INTROSPECTION OFF)
  endif ()
  
 -# Override the cached variables, gtk-doc and gobject-introspection do not really work when cross-building.
diff --git a/poky/meta/recipes-sato/webkit/webkitgtk/0001-WebKitMacros-Append-to-I-and-not-to-isystem.patch b/poky/meta/recipes-sato/webkit/webkitgtk/0001-WebKitMacros-Append-to-I-and-not-to-isystem.patch
index 9fc1421..b310264 100644
--- a/poky/meta/recipes-sato/webkit/webkitgtk/0001-WebKitMacros-Append-to-I-and-not-to-isystem.patch
+++ b/poky/meta/recipes-sato/webkit/webkitgtk/0001-WebKitMacros-Append-to-I-and-not-to-isystem.patch
@@ -1,7 +1,7 @@
-From ef832a115b40861c08df333339b1366da49e5393 Mon Sep 17 00:00:00 2001
+From e1c6540f7984bd48e1e2d80d965fa82c70de3c20 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sun, 17 Apr 2016 12:35:41 -0700
-Subject: [PATCH 9/9] WebKitMacros: Append to -I and not to -isystem
+Subject: [PATCH] WebKitMacros: Append to -I and not to -isystem
 
 gcc-6 has now introduced stdlib.h in libstdc++ for better
 compliance and its including the C library stdlib.h using
@@ -17,6 +17,7 @@
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
 Upstream-Status: Pending
+
 ---
  Source/JavaScriptCore/shell/CMakeLists.txt | 2 +-
  Source/WebCore/PlatformGTK.cmake           | 6 +++---
@@ -27,32 +28,32 @@
  6 files changed, 8 insertions(+), 8 deletions(-)
 
 diff --git a/Source/JavaScriptCore/shell/CMakeLists.txt b/Source/JavaScriptCore/shell/CMakeLists.txt
-index bc37dd31..4e49871f 100644
+index b3c7e0b..88446de 100644
 --- a/Source/JavaScriptCore/shell/CMakeLists.txt
 +++ b/Source/JavaScriptCore/shell/CMakeLists.txt
 @@ -35,7 +35,7 @@ WEBKIT_INCLUDE_CONFIG_FILES_IF_EXISTS()
  WEBKIT_WRAP_SOURCELIST(${JSC_SOURCES})
  WEBKIT_WRAP_SOURCELIST(${TESTAPI_SOURCES})
- include_directories(./ ${JavaScriptCore_INCLUDE_DIRECTORIES})
+ include_directories(./ ${JavaScriptCore_INCLUDE_DIRECTORIES} ${JavaScriptCore_PRIVATE_INCLUDE_DIRECTORIES})
 -include_directories(SYSTEM ${JavaScriptCore_SYSTEM_INCLUDE_DIRECTORIES})
 +include_directories(${JavaScriptCore_SYSTEM_INCLUDE_DIRECTORIES})
  add_executable(jsc ${JSC_SOURCES})
  target_link_libraries(jsc ${JSC_LIBRARIES})
  
 diff --git a/Source/WebCore/PlatformGTK.cmake b/Source/WebCore/PlatformGTK.cmake
-index 73506c74..8eb8b415 100644
+index f7d8d70a..3c27b8bc 100644
 --- a/Source/WebCore/PlatformGTK.cmake
 +++ b/Source/WebCore/PlatformGTK.cmake
-@@ -281,7 +281,7 @@ if (ENABLE_PLUGIN_PROCESS_GTK2)
-         ${GTK2_INCLUDE_DIRS}
-         ${GDK2_INCLUDE_DIRS}
+@@ -157,7 +157,7 @@ if (ENABLE_PLUGIN_PROCESS_GTK2)
+     target_include_directories(WebCorePlatformGTK2 PRIVATE
+         ${WebCore_INCLUDE_DIRECTORIES}
      )
 -    target_include_directories(WebCorePlatformGTK2 SYSTEM PRIVATE
 +    target_include_directories(WebCorePlatformGTK2 PRIVATE
          ${WebCore_SYSTEM_INCLUDE_DIRECTORIES}
-     )
-     target_link_libraries(WebCorePlatformGTK2
-@@ -305,7 +305,7 @@ add_dependencies(WebCorePlatformGTK WebCore)
+         ${GTK2_INCLUDE_DIRS}
+         ${GDK2_INCLUDE_DIRS}
+@@ -183,7 +183,7 @@ add_dependencies(WebCorePlatformGTK WebCore)
  target_include_directories(WebCorePlatformGTK PRIVATE
      ${WebCore_INCLUDE_DIRECTORIES}
  )
@@ -61,7 +62,7 @@
      ${WebCore_SYSTEM_INCLUDE_DIRECTORIES}
      ${GTK_INCLUDE_DIRS}
      ${GDK_INCLUDE_DIRS}
-@@ -321,7 +321,7 @@ include_directories(
+@@ -199,7 +199,7 @@ include_directories(
      "${WEBCORE_DIR}/bindings/gobject/"
  )
  
@@ -71,33 +72,33 @@
  )
  
 diff --git a/Source/WebKit/PlatformGTK.cmake b/Source/WebKit/PlatformGTK.cmake
-index d83a2e77..401246f4 100644
+index 8c6ebb5..772c243 100644
 --- a/Source/WebKit/PlatformGTK.cmake
 +++ b/Source/WebKit/PlatformGTK.cmake
-@@ -1050,7 +1050,7 @@ if (ENABLE_PLUGIN_PROCESS_GTK2)
+@@ -655,7 +655,7 @@ if (ENABLE_PLUGIN_PROCESS_GTK2)
      target_include_directories(WebKitPluginProcess2 PRIVATE
-         ${WebKit2CommonIncludeDirectories}
+         ${WebKitCommonIncludeDirectories}
      )
 -    target_include_directories(WebKitPluginProcess2 SYSTEM PRIVATE
 +    target_include_directories(WebKitPluginProcess2 PRIVATE
-          ${WebKit2CommonSystemIncludeDirectories}
+          ${WebKitCommonSystemIncludeDirectories}
           ${GTK2_INCLUDE_DIRS}
           ${GDK2_INCLUDE_DIRS}
 diff --git a/Source/cmake/WebKitMacros.cmake b/Source/cmake/WebKitMacros.cmake
-index 7bc89543..d9818fa4 100644
+index a1e7e8f..ce24274 100644
 --- a/Source/cmake/WebKitMacros.cmake
 +++ b/Source/cmake/WebKitMacros.cmake
-@@ -78,7 +78,7 @@ macro(WEBKIT_FRAMEWORK_DECLARE _target)
- endmacro()
- 
- macro(WEBKIT_FRAMEWORK _target)
--    include_directories(SYSTEM ${${_target}_SYSTEM_INCLUDE_DIRECTORIES})
-+    include_directories(${${_target}_SYSTEM_INCLUDE_DIRECTORIES})
-     target_sources(${_target} PRIVATE
-         ${${_target}_HEADERS}
+@@ -134,7 +134,7 @@ macro(WEBKIT_FRAMEWORK _target)
          ${${_target}_SOURCES}
+     )
+     target_include_directories(${_target} PUBLIC "$<BUILD_INTERFACE:${${_target}_INCLUDE_DIRECTORIES}>")
+-    target_include_directories(${_target} SYSTEM PRIVATE "$<BUILD_INTERFACE:${${_target}_SYSTEM_INCLUDE_DIRECTORIES}>")
++    target_include_directories(${_target} PRIVATE "$<BUILD_INTERFACE:${${_target}_SYSTEM_INCLUDE_DIRECTORIES}>")
+     target_include_directories(${_target} PRIVATE "$<BUILD_INTERFACE:${${_target}_PRIVATE_INCLUDE_DIRECTORIES}>")
+     target_link_libraries(${_target} ${${_target}_LIBRARIES})
+     set_target_properties(${_target} PROPERTIES COMPILE_DEFINITIONS "BUILDING_${_target}")
 diff --git a/Tools/MiniBrowser/gtk/CMakeLists.txt b/Tools/MiniBrowser/gtk/CMakeLists.txt
-index e832a86d..ce92c864 100644
+index dc2b61e..0128dca 100644
 --- a/Tools/MiniBrowser/gtk/CMakeLists.txt
 +++ b/Tools/MiniBrowser/gtk/CMakeLists.txt
 @@ -57,7 +57,7 @@ endif ()
@@ -110,11 +111,11 @@
  target_link_libraries(MiniBrowser ${MiniBrowser_LIBRARIES})
  
 diff --git a/Tools/TestWebKitAPI/PlatformGTK.cmake b/Tools/TestWebKitAPI/PlatformGTK.cmake
-index 1be3dd52..7bdddf37 100644
+index 4aef695..a14b163 100644
 --- a/Tools/TestWebKitAPI/PlatformGTK.cmake
 +++ b/Tools/TestWebKitAPI/PlatformGTK.cmake
 @@ -20,7 +20,7 @@ include_directories(
-     ${WEBKIT2_DIR}/UIProcess/API/gtk
+     ${WEBKIT_DIR}/UIProcess/API/gtk
  )
  
 -include_directories(SYSTEM
@@ -122,6 +123,3 @@
      ${GDK3_INCLUDE_DIRS}
      ${GLIB_INCLUDE_DIRS}
      ${GTK3_INCLUDE_DIRS}
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-sato/webkit/webkitgtk/0001-When-building-introspection-files-add-CMAKE_C_FLAGS-.patch b/poky/meta/recipes-sato/webkit/webkitgtk/0001-When-building-introspection-files-add-CMAKE_C_FLAGS-.patch
index fb4c4dc..923d00c 100644
--- a/poky/meta/recipes-sato/webkit/webkitgtk/0001-When-building-introspection-files-add-CMAKE_C_FLAGS-.patch
+++ b/poky/meta/recipes-sato/webkit/webkitgtk/0001-When-building-introspection-files-add-CMAKE_C_FLAGS-.patch
@@ -1,8 +1,8 @@
-From 98b1359a0cd87bbdb22cef98ba594440f4c57d92 Mon Sep 17 00:00:00 2001
+From f9767a479111f9c6f280c43176c33de50aee7f66 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Wed, 28 Oct 2015 14:18:57 +0200
-Subject: [PATCH 2/9] When building introspection files, add CMAKE_C_FLAGS to
- the compiler flags.
+Subject: [PATCH] When building introspection files, add CMAKE_C_FLAGS to the
+ compiler flags.
 
 g-ir-compiler is using a C compiler internally, so it needs to set
 the proper flags for it.
@@ -15,27 +15,24 @@
  1 file changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/Source/WebKit/PlatformGTK.cmake b/Source/WebKit/PlatformGTK.cmake
-index 7f92ae72..a33c6a86 100644
+index dc6b306..a074a80 100644
 --- a/Source/WebKit/PlatformGTK.cmake
 +++ b/Source/WebKit/PlatformGTK.cmake
-@@ -1126,7 +1126,7 @@ add_custom_command(
-     OUTPUT ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
-     DEPENDS WebKit2
-     DEPENDS ${CMAKE_BINARY_DIR}/JavaScriptCore-${WEBKITGTK_API_VERSION}.gir
--    COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations LDFLAGS=
-+    COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations\ ${CMAKE_C_FLAGS} LDFLAGS=
-         ${LOADER_LIBRARY_PATH_VAR}="${INTROSPECTION_ADDITIONAL_LIBRARY_PATH}"
-         ${INTROSPECTION_SCANNER}
-         --quiet
-@@ -1169,7 +1169,7 @@ add_custom_command(
-     OUTPUT ${CMAKE_BINARY_DIR}/WebKit2WebExtension-${WEBKITGTK_API_VERSION}.gir
-     DEPENDS ${CMAKE_BINARY_DIR}/JavaScriptCore-${WEBKITGTK_API_VERSION}.gir
-     DEPENDS ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
--    COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations
-+    COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations\ ${CMAKE_C_FLAGS}
-         LDFLAGS="${INTROSPECTION_ADDITIONAL_LDFLAGS}"
-         ${LOADER_LIBRARY_PATH_VAR}="${INTROSPECTION_ADDITIONAL_LIBRARY_PATH}"
-         ${INTROSPECTION_SCANNER}
--- 
-2.14.1
-
+@@ -732,7 +732,7 @@ if (ENABLE_INTROSPECTION)
+         OUTPUT ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
+         DEPENDS WebKit
+         DEPENDS ${CMAKE_BINARY_DIR}/JavaScriptCore-${WEBKITGTK_API_VERSION}.gir
+-        COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations LDFLAGS=
++        COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations\ ${CMAKE_C_FLAGS} LDFLAGS=
+             ${LOADER_LIBRARY_PATH_VAR}="${INTROSPECTION_ADDITIONAL_LIBRARY_PATH}"
+             ${INTROSPECTION_SCANNER}
+             --quiet
+@@ -774,7 +774,7 @@ if (ENABLE_INTROSPECTION)
+         OUTPUT ${CMAKE_BINARY_DIR}/WebKit2WebExtension-${WEBKITGTK_API_VERSION}.gir
+         DEPENDS ${CMAKE_BINARY_DIR}/JavaScriptCore-${WEBKITGTK_API_VERSION}.gir
+         DEPENDS ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
+-        COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations
++        COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations\ ${CMAKE_C_FLAGS}
+             LDFLAGS="${INTROSPECTION_ADDITIONAL_LDFLAGS}"
+             ${LOADER_LIBRARY_PATH_VAR}="${INTROSPECTION_ADDITIONAL_LIBRARY_PATH}"
+             ${INTROSPECTION_SCANNER}
diff --git a/poky/meta/recipes-sato/webkit/webkitgtk/0001-webkitgtk-fix-CVE-2017-17821.patch b/poky/meta/recipes-sato/webkit/webkitgtk/0001-webkitgtk-fix-CVE-2017-17821.patch
new file mode 100644
index 0000000..a3f7599
--- /dev/null
+++ b/poky/meta/recipes-sato/webkit/webkitgtk/0001-webkitgtk-fix-CVE-2017-17821.patch
@@ -0,0 +1,44 @@
+Backport patch to fix CVE-2017-17821. Refer to
+https://security-tracker.debian.org/tracker/CVE-2017-17821.
+
+Upstream-Status: Backport [https://trac.webkit.org/changeset/232119/webkit]
+CVE: CVE-2017-17821
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+
+From 2a17b15297eb886b0bfb7d098ef607cfad6c3da0 Mon Sep 17 00:00:00 2001
+From: "mcatanzaro@igalia.com"
+ <mcatanzaro@igalia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
+Date: Wed, 23 May 2018 17:54:01 +0000
+Subject: [PATCH] Prohibit shrinking the FastBitVector
+ https://bugs.webkit.org/show_bug.cgi?id=181020
+
+Reviewed by Oliver Hunt.
+
+Prohibit shrinking the FastBitVector. It's not prepared for this and the current usage does
+not require it.
+
+* wtf/FastBitVector.cpp:
+(WTF::FastBitVectorWordOwner::resizeSlow):
+
+git-svn-id: http://svn.webkit.org/repository/webkit/trunk@232119 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+---
+ Source/WTF/wtf/FastBitVector.cpp |  2 ++
+ 2 files changed, 15 insertions(+)
+
+diff --git a/Source/WTF/wtf/FastBitVector.cpp b/Source/WTF/wtf/FastBitVector.cpp
+index eed316975f4..8b019aaa3ed 100644
+--- a/Source/WTF/wtf/FastBitVector.cpp
++++ b/Source/WTF/wtf/FastBitVector.cpp
+@@ -42,6 +42,8 @@ void FastBitVectorWordOwner::setEqualsSlow(const FastBitVectorWordOwner& other)
+ void FastBitVectorWordOwner::resizeSlow(size_t numBits)
+ {
+     size_t newLength = fastBitVectorArrayLength(numBits);
++
++    RELEASE_ASSERT(newLength >= arrayLength());
+     
+     // Use fastCalloc instead of fastRealloc because we expect the common
+     // use case for this method to be initializing the size of the bitvector.
+-- 
+2.17.0
+
diff --git a/poky/meta/recipes-sato/webkit/webkitgtk/0012-soup-Forward-declare-URL-class.patch b/poky/meta/recipes-sato/webkit/webkitgtk/0012-soup-Forward-declare-URL-class.patch
new file mode 100644
index 0000000..78fd4dc
--- /dev/null
+++ b/poky/meta/recipes-sato/webkit/webkitgtk/0012-soup-Forward-declare-URL-class.patch
@@ -0,0 +1,31 @@
+From 59f6903ad96f3213f248b672d5fd526cc0d666ce Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 20 May 2018 14:28:27 -0700
+Subject: [PATCH] soup: Forward declare URL class
+
+This helps getting away with compiler errors seen with clang
+
+/mnt/a/oe/workspace/sources/webkitgtk/Source/WebCore/platform/network/soup/SoupNetworkSession.h:68:62:
+error: unknown type name 'URL'
+    static std::optional<ResourceError> checkTLSErrors(const URL&,
+GTlsCertificate*, GTlsCertificateFlags);
+                                                             ^
+Upstream-Status: Backport [https://trac.webkit.org/changeset/231876/webkit]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ Source/WebCore/platform/network/soup/SoupNetworkSession.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/Source/WebCore/platform/network/soup/SoupNetworkSession.h b/Source/WebCore/platform/network/soup/SoupNetworkSession.h
+index 03bd72ba..7ca8792d 100644
+--- a/Source/WebCore/platform/network/soup/SoupNetworkSession.h
++++ b/Source/WebCore/platform/network/soup/SoupNetworkSession.h
+@@ -43,6 +43,7 @@ namespace WebCore {
+ 
+ class CertificateInfo;
+ class ResourceError;
++class URL;
+ struct SoupNetworkProxySettings;
+ 
+ class SoupNetworkSession {
diff --git a/poky/meta/recipes-sato/webkit/webkitgtk/detect-atomics-during-configure.patch b/poky/meta/recipes-sato/webkit/webkitgtk/detect-atomics-during-configure.patch
deleted file mode 100644
index c6157e1..0000000
--- a/poky/meta/recipes-sato/webkit/webkitgtk/detect-atomics-during-configure.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-From 0b3811771ae6385503f2d949f9433d8f810d2ff9 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 17 May 2017 22:34:24 -0700
-Subject: [PATCH 8/9] webkitgtk: Fix build for armv5
-
-Taken from
-https://bugs.webkit.org/show_bug.cgi?id=161900
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
----
- Source/WTF/wtf/CMakeLists.txt | 10 +++++++++-
- 1 file changed, 9 insertions(+), 1 deletion(-)
-
-diff --git a/Source/WTF/wtf/CMakeLists.txt b/Source/WTF/wtf/CMakeLists.txt
-index 6b5e45b9..46ee3c22 100644
---- a/Source/WTF/wtf/CMakeLists.txt
-+++ b/Source/WTF/wtf/CMakeLists.txt
-@@ -205,7 +205,6 @@ set(WTF_HEADERS
- 
- set(WTF_SOURCES
-     Assertions.cpp
--    Atomics.cpp
-     AutomaticThread.cpp
-     BitVector.cpp
-     CPUTime.cpp
-@@ -336,6 +335,15 @@ if (NOT USE_SYSTEM_MALLOC)
-     list(APPEND WTF_LIBRARIES bmalloc)
- endif ()
- 
-+file(WRITE ${CMAKE_BINARY_DIR}/test_atomics.cpp
-+     "int main(void)\n"
-+     "{ long long x = 1; return (int) __sync_add_and_fetch_8(&x, 1); }\n")
-+try_compile(ATOMICS_BUILD_SUCCEEDED ${CMAKE_BINARY_DIR} ${CMAKE_BINARY_DIR}/test_atomics.cpp)
-+if (NOT ATOMICS_BUILD_SUCCEEDED)
-+    list(APPEND WTF_SOURCES Atomics.cpp)
-+endif ()
-+file(REMOVE ${CMAKE_BINARY_DIR}/test_atomics.cpp)
-+
- list(APPEND WTF_SOURCES
-     unicode/icu/CollatorICU.cpp
- )
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-sato/webkit/webkitgtk/detect-gstreamer-gl.patch b/poky/meta/recipes-sato/webkit/webkitgtk/detect-gstreamer-gl.patch
new file mode 100644
index 0000000..57ae48c
--- /dev/null
+++ b/poky/meta/recipes-sato/webkit/webkitgtk/detect-gstreamer-gl.patch
@@ -0,0 +1,20 @@
+From: Alberto Garcia <berto@igalia.com>
+Subject: Disable USE_GSTREAMER_GL is the package is not found
+Forwarded: no
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Index: webkitgtk/Source/cmake/GStreamerChecks.cmake
+===================================================================
+--- webkitgtk.orig/Source/cmake/GStreamerChecks.cmake
++++ webkitgtk/Source/cmake/GStreamerChecks.cmake
+@@ -43,7 +43,8 @@ if (ENABLE_VIDEO OR ENABLE_WEB_AUDIO)
+             message(FATAL_ERROR "GStreamer 1.10 is needed for USE_GSTREAMER_GL.")
+         else ()
+             if (NOT PC_GSTREAMER_GL_FOUND)
+-                message(FATAL_ERROR "GStreamerGL is needed for USE_GSTREAMER_GL.")
++                set(USE_GSTREAMER_GL OFF)
++                message(STATUS "GStreamerGL is needed for USE_GSTREAMER_GL.")
+             endif ()
+         endif ()
+     endif ()
diff --git a/poky/meta/recipes-sato/webkit/webkitgtk/fix-configure-failure-aarch64.patch b/poky/meta/recipes-sato/webkit/webkitgtk/fix-configure-failure-aarch64.patch
deleted file mode 100644
index 4a6ab54..0000000
--- a/poky/meta/recipes-sato/webkit/webkitgtk/fix-configure-failure-aarch64.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-Fix configure failure for aarch64
-
-| -- Performing Test CXX_COMPILER_SUPPORTS_-fcolor-diagnostics - Failed
-| -- Performing Test CXX_COMPILER_SUPPORTS_-fdiagnostics-color=always
-| -- Performing Test CXX_COMPILER_SUPPORTS_-fdiagnostics-color=always - Success
-| CMake Error at Source/cmake/OptionsCommon.cmake:42 (WEBKIT_PREPEND_GLOBAL_COMPILER_FLAG):
-|   Unknown CMake command "WEBKIT_PREPEND_GLOBAL_COMPILER_FLAG".
-| Call Stack (most recent call first):
-|   Source/cmake/WebKitCommon.cmake:58 (include)
-|   CMakeLists.txt:166 (include)
-|
-
-Upstream-Status: Pending
-
-Signed-off-by: Manjukumar Matha <manjukumar.harthikote-matha@xilinx.com>
-
-Index: webkitgtk-2.14.6/Source/cmake/OptionsCommon.cmake
-===================================================================
---- webkitgtk-2.14.6.orig/Source/cmake/OptionsCommon.cmake     2018-02-15 18:56:29.315238564 -0800
-+++ webkitgtk-2.14.6/Source/cmake/OptionsCommon.cmake  2018-02-15 18:54:57.469518064 -0800
-@@ -39,7 +39,7 @@
-     if (NOT WTF_CPU_ARM64)
-         message(FATAL_ERROR "WTF_CPU_ARM64_CORTEXA53 set without WTF_CPU_ARM64")
-     endif ()
--    WEBKIT_PREPEND_GLOBAL_COMPILER_FLAG(-mfix-cortex-a53-835769)
-+    WEBKIT_PREPEND_GLOBAL_COMPILER_FLAGS(-mfix-cortex-a53-835769)
- endif ()
-
- EXPOSE_VARIABLE_TO_BUILD(WTF_CPU_ARM64_CORTEXA53)
diff --git a/poky/meta/recipes-sato/webkit/webkitgtk/x32_support.patch b/poky/meta/recipes-sato/webkit/webkitgtk/x32_support.patch
index 5f23837..85d281e 100644
--- a/poky/meta/recipes-sato/webkit/webkitgtk/x32_support.patch
+++ b/poky/meta/recipes-sato/webkit/webkitgtk/x32_support.patch
@@ -1,13 +1,22 @@
-From: Daniel Schepler <dschepler@gmail.com>
-Subject: Fix FTBFS in x32
-Bug-Debian: https://bugs.debian.org/700795
-Upstream-Status: Pending
 Signed-off-by: Christopher Larson <chris_larson@mentor.com>
-Index: webkitgtk-2.16.1/Source/WTF/wtf/Platform.h
+Upstream-Status: Pending
+
+From 897563a0397266d8ceb058f172e16b06419b2593 Mon Sep 17 00:00:00 2001
+From: Daniel Schepler <dschepler@gmail.com>
+Date: Mon, 26 Mar 2018 17:48:34 +0300
+Subject: [PATCH] Fix FTBFS in x32
+
 ===================================================================
---- webkitgtk-2.16.1.orig/Source/WTF/wtf/Platform.h
-+++ webkitgtk-2.16.1/Source/WTF/wtf/Platform.h
-@@ -172,7 +172,11 @@
+
+---
+ Source/WTF/wtf/Platform.h | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/Source/WTF/wtf/Platform.h b/Source/WTF/wtf/Platform.h
+index 850e298..551c047 100644
+--- a/Source/WTF/wtf/Platform.h
++++ b/Source/WTF/wtf/Platform.h
+@@ -132,7 +132,11 @@
  /* CPU(X86_64) - AMD64 / Intel64 / x86_64 64-bit */
  #if   defined(__x86_64__) \
      || defined(_M_X64)
@@ -17,5 +26,5 @@
  #define WTF_CPU_X86_64 1
 +#endif
  #define WTF_CPU_X86_SSE2 1
+ #define WTF_CPU_KNOWN 1
  #endif
- 
diff --git a/poky/meta/recipes-sato/webkit/webkitgtk_2.18.6.bb b/poky/meta/recipes-sato/webkit/webkitgtk_2.18.6.bb
deleted file mode 100644
index c29fa7f..0000000
--- a/poky/meta/recipes-sato/webkit/webkitgtk_2.18.6.bb
+++ /dev/null
@@ -1,123 +0,0 @@
-SUMMARY = "WebKit web rendering engine for the GTK+ platform"
-HOMEPAGE = "http://www.webkitgtk.org/"
-BUGTRACKER = "http://bugs.webkit.org/"
-
-LICENSE = "BSD & LGPLv2+"
-LIC_FILES_CHKSUM = "file://Source/JavaScriptCore/COPYING.LIB;md5=d0c6d6397a5d84286dda758da57bd691 \
-                    file://Source/WebCore/LICENSE-APPLE;md5=4646f90082c40bcf298c285f8bab0b12 \
-		    file://Source/WebCore/LICENSE-LGPL-2;md5=36357ffde2b64ae177b2494445b79d21 \
-		    file://Source/WebCore/LICENSE-LGPL-2.1;md5=a778a33ef338abbaf8b8a7c36b6eec80 \
-		   "
-
-SRC_URI = "http://www.webkitgtk.org/releases/${BPN}-${PV}.tar.xz \
-           file://0001-FindGObjectIntrospection.cmake-prefix-variables-obta.patch \
-           file://0001-When-building-introspection-files-add-CMAKE_C_FLAGS-.patch \
-           file://0001-OptionsGTK.cmake-drop-the-hardcoded-introspection-gt.patch \
-           file://0001-Fix-racy-parallel-build-of-WebKit2-4.0.gir.patch \
-           file://0001-Tweak-gtkdoc-settings-so-that-gtkdoc-generation-work.patch \
-           file://x32_support.patch \
-           file://cross-compile.patch \
-           file://detect-atomics-during-configure.patch \
-           file://0001-WebKitMacros-Append-to-I-and-not-to-isystem.patch \
-           file://0001-Fix-build-with-musl.patch \
-           file://fix-configure-failure-aarch64.patch \
-           file://0001-Fix-gles3-header-when-gles2-is-enabled.patch \
-           "
-
-SRC_URI[md5sum] = "c1a548595135ee75ad3bf2e18ac83112"
-SRC_URI[sha256sum] = "93912cc2f40f12e452be1ca4babdbdaac0ec4f828d441257a6b06c2963bbac3c"
-
-inherit cmake pkgconfig gobject-introspection perlnative distro_features_check upstream-version-is-even gtk-doc
-
-# depends on libxt
-REQUIRED_DISTRO_FEATURES = "x11"
-
-DEPENDS = "zlib libsoup-2.4 curl libxml2 cairo libxslt libxt libidn libgcrypt \
-           gtk+3 gstreamer1.0 gstreamer1.0-plugins-base flex-native gperf-native sqlite3 \
-	   pango icu bison-native gawk intltool-native libwebp \
-	   atk udev harfbuzz jpeg libpng pulseaudio librsvg libtheora libvorbis libxcomposite libxtst \
-	   ruby-native libnotify gstreamer1.0-plugins-bad \
-	   gettext-native glib-2.0 glib-2.0-native libtasn1 \
-          "
-
-PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', 'wayland' ,d)} \
-                   ${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'webgl opengl', '' ,d)} \
-                   enchant \
-                   libsecret \
-                  "
-
-PACKAGECONFIG[wayland] = "-DENABLE_WAYLAND_TARGET=ON,-DENABLE_WAYLAND_TARGET=OFF,wayland"
-PACKAGECONFIG[x11] = "-DENABLE_X11_TARGET=ON,-DENABLE_X11_TARGET=OFF,virtual/libx11"
-PACKAGECONFIG[geoclue] = "-DENABLE_GEOLOCATION=ON,-DENABLE_GEOLOCATION=OFF,geoclue"
-PACKAGECONFIG[enchant] = "-DENABLE_SPELLCHECK=ON,-DENABLE_SPELLCHECK=OFF,enchant"
-PACKAGECONFIG[gtk2] = "-DENABLE_PLUGIN_PROCESS_GTK2=ON,-DENABLE_PLUGIN_PROCESS_GTK2=OFF,gtk+"
-PACKAGECONFIG[gles2] = "-DENABLE_GLES2=ON,-DENABLE_GLES2=OFF,virtual/libgles2"
-PACKAGECONFIG[webgl] = "-DENABLE_WEBGL=ON,-DENABLE_WEBGL=OFF,virtual/libgl"
-PACKAGECONFIG[opengl] = "-DENABLE_OPENGL=ON,-DENABLE_OPENGL=OFF,virtual/libgl"
-PACKAGECONFIG[libsecret] = "-DUSE_LIBSECRET=ON,-DUSE_LIBSECRET=OFF,libsecret"
-PACKAGECONFIG[libhyphen] = "-DUSE_LIBHYPHEN=ON,-DUSE_LIBHYPHEN=OFF,libhyphen"
-
-EXTRA_OECMAKE = " \
-		-DPORT=GTK \
-		-DCMAKE_BUILD_TYPE=Release \
-		${@bb.utils.contains('GI_DATA_ENABLED', 'True', '-DENABLE_INTROSPECTION=ON', '-DENABLE_INTROSPECTION=OFF', d)} \
-		${@bb.utils.contains('GTKDOC_ENABLED', 'True', '-DENABLE_GTKDOC=ON', '-DENABLE_GTKDOC=OFF', d)} \
-		-DENABLE_MINIBROWSER=ON \
-                -DPYTHON_EXECUTABLE=`which python` \
-		"
-
-# GL/GLES header clash: both define the same thing, differently, on 32 bit x86
-EXTRA_OECMAKE_append_x86 = " -DUSE_GSTREAMER_GL=OFF "
-EXTRA_OECMAKE_append_x86-x32 = " -DUSE_GSTREAMER_GL=OFF "
-
-# Javascript JIT is not supported on powerpc
-EXTRA_OECMAKE_append_powerpc = " -DENABLE_JIT=OFF "
-EXTRA_OECMAKE_append_powerpc64 = " -DENABLE_JIT=OFF "
-
-# ARM JIT code does not build on ARMv4/5/6 anymore
-EXTRA_OECMAKE_append_armv5 = " -DENABLE_JIT=OFF "
-EXTRA_OECMAKE_append_armv6 = " -DENABLE_JIT=OFF "
-EXTRA_OECMAKE_append_armv4 = " -DENABLE_JIT=OFF "
-
-# binutils 2.25.1 has a bug on aarch64:
-# https://sourceware.org/bugzilla/show_bug.cgi?id=18430
-EXTRA_OECMAKE_append_aarch64 = " -DUSE_LD_GOLD=OFF "
-EXTRA_OECMAKE_append_mipsarch = " -DUSE_LD_GOLD=OFF "
-EXTRA_OECMAKE_append_powerpc = " -DUSE_LD_GOLD=OFF "
-EXTRA_OECMAKE_append_toolchain-clang = " -DUSE_LD_GOLD=OFF "
-
-EXTRA_OECMAKE_append_aarch64 = " -DWTF_CPU_ARM64_CORTEXA53=ON"
-
-# JIT not supported on MIPS either
-EXTRA_OECMAKE_append_mipsarch = " -DENABLE_JIT=OFF "
-
-# JIT not supported on X32
-# An attempt was made to upstream JIT support for x32 in
-# https://bugs.webkit.org/show_bug.cgi?id=100450, but this was closed as
-# unresolved due to limited X32 adoption.
-EXTRA_OECMAKE_append_x86-x32 = " -DENABLE_JIT=OFF "
-
-SECURITY_CFLAGS_remove_aarch64 = "-fpie"
-SECURITY_CFLAGS_append_aarch64 = " -fPIE"
-
-FILES_${PN} += "${libdir}/webkit2gtk-4.0/injected-bundle/libwebkit2gtkinjectedbundle.so"
-
-RRECOMMENDS_${PN} += "ca-certificates shared-mime-info"
-
-# http://errors.yoctoproject.org/Errors/Details/20370/
-ARM_INSTRUCTION_SET_armv4 = "arm"
-ARM_INSTRUCTION_SET_armv5 = "arm"
-ARM_INSTRUCTION_SET_armv6 = "arm"
-
-# https://bugzilla.yoctoproject.org/show_bug.cgi?id=9474
-# https://bugs.webkit.org/show_bug.cgi?id=159880
-# JSC JIT can build on ARMv7 with -marm, but doesn't work on runtime.
-# Upstream only tests regularly the JSC JIT on ARMv7 with Thumb2 (-mthumb).
-ARM_INSTRUCTION_SET_armv7a = "thumb"
-ARM_INSTRUCTION_SET_armv7r = "thumb"
-ARM_INSTRUCTION_SET_armv7ve = "thumb"
-
-# qemu: uncaught target signal 11 (Segmentation fault) - core dumped
-# Segmentation fault
-GI_DATA_ENABLED_armv7a = "False"
-GI_DATA_ENABLED_armv7ve = "False"
diff --git a/poky/meta/recipes-sato/webkit/webkitgtk_2.20.5.bb b/poky/meta/recipes-sato/webkit/webkitgtk_2.20.5.bb
new file mode 100644
index 0000000..7f1ffce
--- /dev/null
+++ b/poky/meta/recipes-sato/webkit/webkitgtk_2.20.5.bb
@@ -0,0 +1,124 @@
+SUMMARY = "WebKit web rendering engine for the GTK+ platform"
+HOMEPAGE = "http://www.webkitgtk.org/"
+BUGTRACKER = "http://bugs.webkit.org/"
+
+LICENSE = "BSD & LGPLv2+"
+LIC_FILES_CHKSUM = "file://Source/JavaScriptCore/COPYING.LIB;md5=d0c6d6397a5d84286dda758da57bd691 \
+                    file://Source/WebCore/LICENSE-APPLE;md5=4646f90082c40bcf298c285f8bab0b12 \
+		    file://Source/WebCore/LICENSE-LGPL-2;md5=36357ffde2b64ae177b2494445b79d21 \
+		    file://Source/WebCore/LICENSE-LGPL-2.1;md5=a778a33ef338abbaf8b8a7c36b6eec80 \
+		   "
+
+SRC_URI = "http://www.webkitgtk.org/releases/${BPN}-${PV}.tar.xz \
+           file://0001-FindGObjectIntrospection.cmake-prefix-variables-obta.patch \
+           file://0001-When-building-introspection-files-add-CMAKE_C_FLAGS-.patch \
+           file://0001-OptionsGTK.cmake-drop-the-hardcoded-introspection-gt.patch \
+           file://0001-Fix-racy-parallel-build-of-WebKit2-4.0.gir.patch \
+           file://0001-Tweak-gtkdoc-settings-so-that-gtkdoc-generation-work.patch \
+           file://x32_support.patch \
+           file://cross-compile.patch \
+           file://0001-WebKitMacros-Append-to-I-and-not-to-isystem.patch \
+           file://0001-Fix-build-with-musl.patch \
+           file://detect-gstreamer-gl.patch \
+           file://0012-soup-Forward-declare-URL-class.patch \
+           file://0001-Fix-PaintingData-has-no-member-named-lightVector-on-.patch \
+           file://0001-webkitgtk-fix-CVE-2017-17821.patch \
+           "
+
+SRC_URI[md5sum] = "72a05f6a4dc1c78b079590a8fd280401"
+SRC_URI[sha256sum] = "15c0f8d26e9605afe0948d161ba5fd82efee8eda2debd409fd40a440ac3af990"
+
+inherit cmake pkgconfig gobject-introspection perlnative distro_features_check upstream-version-is-even gtk-doc
+
+REQUIRED_DISTRO_FEATURES = "x11 opengl"
+
+DEPENDS = "zlib libsoup-2.4 curl libxml2 cairo libxslt libxt libidn libgcrypt \
+           gtk+3 gstreamer1.0 gstreamer1.0-plugins-base flex-native gperf-native sqlite3 \
+	   pango icu bison-native gawk intltool-native libwebp \
+	   atk udev harfbuzz jpeg libpng pulseaudio librsvg libtheora libvorbis libxcomposite libxtst \
+	   ruby-native libnotify gstreamer1.0-plugins-bad \
+	   gettext-native glib-2.0 glib-2.0-native libtasn1 \
+          "
+
+PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', 'wayland' ,d)} \
+                   ${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'webgl opengl', '' ,d)} \
+                   enchant \
+                   libsecret \
+                  "
+
+PACKAGECONFIG[wayland] = "-DENABLE_WAYLAND_TARGET=ON,-DENABLE_WAYLAND_TARGET=OFF,wayland"
+PACKAGECONFIG[x11] = "-DENABLE_X11_TARGET=ON,-DENABLE_X11_TARGET=OFF,virtual/libx11"
+PACKAGECONFIG[geoclue] = "-DENABLE_GEOLOCATION=ON,-DENABLE_GEOLOCATION=OFF,geoclue"
+PACKAGECONFIG[enchant] = "-DENABLE_SPELLCHECK=ON,-DENABLE_SPELLCHECK=OFF,enchant"
+PACKAGECONFIG[gtk2] = "-DENABLE_PLUGIN_PROCESS_GTK2=ON,-DENABLE_PLUGIN_PROCESS_GTK2=OFF,gtk+"
+PACKAGECONFIG[gles2] = "-DENABLE_GLES2=ON,-DENABLE_GLES2=OFF,virtual/libgles2"
+PACKAGECONFIG[webgl] = "-DENABLE_WEBGL=ON,-DENABLE_WEBGL=OFF,virtual/libgl"
+PACKAGECONFIG[opengl] = "-DENABLE_OPENGL=ON,-DENABLE_OPENGL=OFF,virtual/libgl"
+PACKAGECONFIG[libsecret] = "-DUSE_LIBSECRET=ON,-DUSE_LIBSECRET=OFF,libsecret"
+PACKAGECONFIG[libhyphen] = "-DUSE_LIBHYPHEN=ON,-DUSE_LIBHYPHEN=OFF,libhyphen"
+# Source is at https://github.com/google/woff2
+PACKAGECONFIG[woff2] = "-DUSE_WOFF2=ON,-DUSE_WOFF2=OFF,woff2"
+
+EXTRA_OECMAKE = " \
+		-DPORT=GTK \
+		-DCMAKE_BUILD_TYPE=Release \
+		${@bb.utils.contains('GI_DATA_ENABLED', 'True', '-DENABLE_INTROSPECTION=ON', '-DENABLE_INTROSPECTION=OFF', d)} \
+		${@bb.utils.contains('GTKDOC_ENABLED', 'True', '-DENABLE_GTKDOC=ON', '-DENABLE_GTKDOC=OFF', d)} \
+		-DENABLE_MINIBROWSER=ON \
+                -DPYTHON_EXECUTABLE=`which python` \
+		"
+
+# GL/GLES header clash: both define the same thing, differently, on 32 bit x86
+EXTRA_OECMAKE_append_x86 = " -DUSE_GSTREAMER_GL=OFF "
+EXTRA_OECMAKE_append_x86-x32 = " -DUSE_GSTREAMER_GL=OFF "
+
+# Javascript JIT is not supported on powerpc
+EXTRA_OECMAKE_append_powerpc = " -DENABLE_JIT=OFF "
+EXTRA_OECMAKE_append_powerpc64 = " -DENABLE_JIT=OFF "
+
+# ARM JIT code does not build on ARMv4/5/6 anymore
+EXTRA_OECMAKE_append_armv5 = " -DENABLE_JIT=OFF "
+EXTRA_OECMAKE_append_armv6 = " -DENABLE_JIT=OFF "
+EXTRA_OECMAKE_append_armv4 = " -DENABLE_JIT=OFF "
+
+# binutils 2.25.1 has a bug on aarch64:
+# https://sourceware.org/bugzilla/show_bug.cgi?id=18430
+EXTRA_OECMAKE_append_aarch64 = " -DUSE_LD_GOLD=OFF "
+EXTRA_OECMAKE_append_mipsarch = " -DUSE_LD_GOLD=OFF "
+EXTRA_OECMAKE_append_powerpc = " -DUSE_LD_GOLD=OFF "
+
+EXTRA_OECMAKE_append_aarch64 = " -DWTF_CPU_ARM64_CORTEXA53=ON"
+
+# JIT not supported on MIPS either
+EXTRA_OECMAKE_append_mipsarch = " -DENABLE_JIT=OFF "
+
+# JIT not supported on X32
+# An attempt was made to upstream JIT support for x32 in
+# https://bugs.webkit.org/show_bug.cgi?id=100450, but this was closed as
+# unresolved due to limited X32 adoption.
+EXTRA_OECMAKE_append_x86-x32 = " -DENABLE_JIT=OFF "
+
+SECURITY_CFLAGS_remove_aarch64 = "-fpie"
+SECURITY_CFLAGS_append_aarch64 = " -fPIE"
+
+FILES_${PN} += "${libdir}/webkit2gtk-4.0/injected-bundle/libwebkit2gtkinjectedbundle.so"
+
+RRECOMMENDS_${PN} += "ca-certificates shared-mime-info"
+
+# http://errors.yoctoproject.org/Errors/Details/20370/
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
+ARM_INSTRUCTION_SET_armv6 = "arm"
+
+# https://bugzilla.yoctoproject.org/show_bug.cgi?id=9474
+# https://bugs.webkit.org/show_bug.cgi?id=159880
+# JSC JIT can build on ARMv7 with -marm, but doesn't work on runtime.
+# Upstream only tests regularly the JSC JIT on ARMv7 with Thumb2 (-mthumb).
+ARM_INSTRUCTION_SET_armv7a = "thumb"
+ARM_INSTRUCTION_SET_armv7r = "thumb"
+ARM_INSTRUCTION_SET_armv7ve = "thumb"
+
+# qemu: uncaught target signal 11 (Segmentation fault) - core dumped
+# Segmentation fault
+GI_DATA_ENABLED_armv7a = "False"
+GI_DATA_ENABLED_armv7ve = "False"
diff --git a/poky/meta/recipes-support/apr/apr/0008-apr-fix-ptest-hang-in-teststr.patch b/poky/meta/recipes-support/apr/apr/0008-apr-fix-ptest-hang-in-teststr.patch
new file mode 100644
index 0000000..6809fa6
--- /dev/null
+++ b/poky/meta/recipes-support/apr/apr/0008-apr-fix-ptest-hang-in-teststr.patch
@@ -0,0 +1,32 @@
+From 036f90748247417dbfa714b1b912ca7dd4053f04 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Mon, 23 Jul 2018 14:12:35 +0800
+Subject: [PATCH] apr: fix ptest hang in teststr
+
+ptest hang in teststr since turns into a non-terminating loop,
+fix by below backported patch.
+
+Upstream-Status: Backport[https://github.com/apache/apr/commit/
+         2e8fbff4ecf82d0decf6baf774c209948f2f4998?diff=unified]
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ test/teststr.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/test/teststr.c b/test/teststr.c
+index d9a5054..951a830 100644
+--- a/test/teststr.c
++++ b/test/teststr.c
+@@ -307,7 +307,7 @@ static void overflow_strfsize(abts_case *tc, void *data)
+     for (; off < 999999999; off += 999) {
+         apr_strfsize(off, buf);
+     }
+-    for (off = 1; off < LONG_MAX && off > 0; off *= 2) {
++    for (off = LONG_MAX; off > 1; off /= 2) {
+         apr_strfsize(off, buf);
+         apr_strfsize(off + 1, buf);
+         apr_strfsize(off - 1, buf);
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-support/apr/apr_1.6.3.bb b/poky/meta/recipes-support/apr/apr_1.6.3.bb
index 7563a38..7bfb698 100644
--- a/poky/meta/recipes-support/apr/apr_1.6.3.bb
+++ b/poky/meta/recipes-support/apr/apr_1.6.3.bb
@@ -18,6 +18,7 @@
            file://0005-configure.in-fix-LTFLAGS-to-make-it-work-with-ccache.patch \
            file://0006-apr-fix-off_t-size-doesn-t-match-in-glibc-when-cross.patch \
            file://0007-explicitly-link-libapr-against-phtread-to-make-gold-.patch \
+           file://0008-apr-fix-ptest-hang-in-teststr.patch \
 "
 
 SRC_URI[md5sum] = "12f2a349483ad6f12db49ba01fbfdbfa"
diff --git a/poky/meta/recipes-support/aspell/aspell_0.60.6.1.bb b/poky/meta/recipes-support/aspell/aspell_0.60.6.1.bb
index 19a7155..161bb5c 100644
--- a/poky/meta/recipes-support/aspell/aspell_0.60.6.1.bb
+++ b/poky/meta/recipes-support/aspell/aspell_0.60.6.1.bb
@@ -25,7 +25,10 @@
 FILES_libpspell = "${libdir}/libpspell.so.*"
 FILES_${PN}-dev += "${bindir}/pspell-config"
 
-ARM_INSTRUCTION_SET = "arm"
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
+ARM_INSTRUCTION_SET_armv6 = "arm"
+
 inherit autotools-brokensep gettext texinfo binconfig-disabled
 
 BINCONFIG = "${bindir}/pspell-config"
diff --git a/poky/meta/recipes-support/atk/at-spi2-atk_2.26.1.bb b/poky/meta/recipes-support/atk/at-spi2-atk_2.26.1.bb
deleted file mode 100644
index 8617bb8..0000000
--- a/poky/meta/recipes-support/atk/at-spi2-atk_2.26.1.bb
+++ /dev/null
@@ -1,22 +0,0 @@
-SUMMARY = "AT-SPI 2 Toolkit Bridge"
-HOMEPAGE = "https://wiki.linuxfoundation.org/accessibility/d-bus"
-LICENSE = "LGPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=e9f288ba982d60518f375b5898283886"
-
-MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}"
-
-SRC_URI = "${GNOME_MIRROR}/${BPN}/${MAJ_VER}/${BPN}-${PV}.tar.xz"
-SRC_URI[md5sum] = "eeec6cead3350dca48a235271c105b3e"
-SRC_URI[sha256sum] = "b4f0c27b61dbffba7a5b5ba2ff88c8cee10ff8dac774fa5b79ce906853623b75"
-
-DEPENDS = "dbus glib-2.0 glib-2.0-native atk at-spi2-core"
-
-inherit autotools pkgconfig distro_features_check upstream-version-is-even
-
-# The at-spi2-core requires x11 in DISTRO_FEATURES
-REQUIRED_DISTRO_FEATURES = "x11"
-
-PACKAGES =+ "${PN}-gnome ${PN}-gtk2"
-
-FILES_${PN}-gnome = "${libdir}/gnome-settings-daemon-3.0/gtk-modules"
-FILES_${PN}-gtk2 = "${libdir}/gtk-2.0/modules/libatk-bridge.*"
diff --git a/poky/meta/recipes-support/atk/at-spi2-atk_2.26.2.bb b/poky/meta/recipes-support/atk/at-spi2-atk_2.26.2.bb
new file mode 100644
index 0000000..16d8e45
--- /dev/null
+++ b/poky/meta/recipes-support/atk/at-spi2-atk_2.26.2.bb
@@ -0,0 +1,20 @@
+SUMMARY = "AT-SPI 2 Toolkit Bridge"
+HOMEPAGE = "https://wiki.linuxfoundation.org/accessibility/d-bus"
+LICENSE = "LGPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=e9f288ba982d60518f375b5898283886"
+
+SRC_URI[archive.md5sum] = "355c7916a69513490cb83ad34016b169"
+SRC_URI[archive.sha256sum] = "61891f0abae1689f6617a963105a3f1dcdab5970c4a36ded9c79a7a544b16a6e"
+
+DEPENDS = "dbus glib-2.0 glib-2.0-native atk at-spi2-core libxml2"
+
+GNOMEBASEBUILDCLASS = "meson"
+inherit gnomebase distro_features_check upstream-version-is-even
+
+# The at-spi2-core requires x11 in DISTRO_FEATURES
+REQUIRED_DISTRO_FEATURES = "x11"
+
+PACKAGES =+ "${PN}-gnome ${PN}-gtk2"
+
+FILES_${PN}-gnome = "${libdir}/gnome-settings-daemon-3.0/gtk-modules"
+FILES_${PN}-gtk2 = "${libdir}/gtk-2.0/modules/libatk-bridge.*"
diff --git a/poky/meta/recipes-support/atk/at-spi2-core/0001-build-Add-with-systemduserunitdir.patch b/poky/meta/recipes-support/atk/at-spi2-core/0001-build-Add-with-systemduserunitdir.patch
deleted file mode 100644
index 1f8c9f3..0000000
--- a/poky/meta/recipes-support/atk/at-spi2-core/0001-build-Add-with-systemduserunitdir.patch
+++ /dev/null
@@ -1,52 +0,0 @@
-From fa376762b92404b9e3c430054b8c3341ca0fdd8b Mon Sep 17 00:00:00 2001
-From: Jussi Kukkonen <jussi.kukkonen@intel.com>
-Date: Tue, 21 Jun 2016 16:00:02 +0300
-Subject: [PATCH] build: Add --with-systemduserunitdir
-
-Default to "pkg-config --variable=systemduserunitdir systemd" but
-allow overriding the value.
-
-Upstream-Status: Submitted [https://bugzilla.gnome.org/show_bug.cgi?id=767911]
-Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
-
----
- bus/Makefile.am | 2 +-
- configure.ac    | 9 +++++++++
- 2 files changed, 10 insertions(+), 1 deletion(-)
-
-diff --git a/bus/Makefile.am b/bus/Makefile.am
-index 688f82a..10cde62 100644
---- a/bus/Makefile.am
-+++ b/bus/Makefile.am
-@@ -29,7 +29,7 @@ org.a11y.Bus.service: org.a11y.Bus.service.in
- EXTRA_DIST += org.a11y.Bus.service.in
- CLEANFILES += org.a11y.Bus.service
- 
--systemd_userdir = $(prefix)/lib/systemd/user
-+systemd_userdir = $(systemduserunitdir)
- systemd_user_DATA = at-spi-dbus-bus.service
- at-spi-dbus-bus.service: at-spi-dbus-bus.service.in Makefile
- 	$(AM_V_GEN) $(SED) -e $(substitutions) $< > $@.tmp && mv $@.tmp $@
-diff --git a/configure.ac b/configure.ac
-index 8c4fca2..1415cca 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -146,6 +146,15 @@ else
- fi
- AC_SUBST(DBUS_SERVICES_DIR)
- 
-+AC_ARG_WITH([systemduserunitdir],
-+            AS_HELP_STRING([--with-systemduserunitdir=DIR],
-+                           [Directory for systemd service files]),
-+            [],
-+            [with_systemduserunitdir=$($PKG_CONFIG --variable=systemduserunitdir systemd)])
-+AC_SUBST([systemduserunitdir], [$with_systemduserunitdir])
-+
-+AC_PATH_PROG(GLIB_MKENUMS, glib-mkenums)
-+
- GOBJECT_INTROSPECTION_CHECK([1.32.0])
- 
- AC_SUBST(LIBTOOL_EXPORT_OPTIONS)
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-support/atk/at-spi2-core_2.26.2.bb b/poky/meta/recipes-support/atk/at-spi2-core_2.26.2.bb
deleted file mode 100644
index 521ee3b..0000000
--- a/poky/meta/recipes-support/atk/at-spi2-core_2.26.2.bb
+++ /dev/null
@@ -1,29 +0,0 @@
-SUMMARY = "Assistive Technology Service Provider Interface (dbus core)"
-HOMEPAGE = "https://wiki.linuxfoundation.org/accessibility/d-bus"
-LICENSE = "LGPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=e9f288ba982d60518f375b5898283886"
-
-MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}"
-
-SRC_URI = "${GNOME_MIRROR}/${BPN}/${MAJ_VER}/${BPN}-${PV}.tar.xz \
-           file://0001-build-Add-with-systemduserunitdir.patch \
-           "
-
-SRC_URI[md5sum] = "4a042e4c801fdb793788b749eab21485"
-SRC_URI[sha256sum] = "c80e0cdf5e3d713400315b63c7deffa561032a6c37289211d8afcfaa267c2615"
-
-DEPENDS = "dbus glib-2.0 virtual/libx11 libxi libxtst"
-
-inherit autotools gtk-doc gettext systemd pkgconfig distro_features_check upstream-version-is-even gobject-introspection
-# depends on virtual/libx11
-REQUIRED_DISTRO_FEATURES = "x11"
-
-EXTRA_OECONF = " \
-                --with-systemduserunitdir=${systemd_user_unitdir} \
-                --with-dbus-daemondir=${bindir}"
-
-FILES_${PN} += "${datadir}/dbus-1/services/*.service \
-                ${datadir}/dbus-1/accessibility-services/*.service \
-                ${datadir}/defaults/at-spi2 \
-                ${systemd_user_unitdir}/at-spi-dbus-bus.service \
-                "
diff --git a/poky/meta/recipes-support/atk/at-spi2-core_2.28.0.bb b/poky/meta/recipes-support/atk/at-spi2-core_2.28.0.bb
new file mode 100644
index 0000000..7975f58
--- /dev/null
+++ b/poky/meta/recipes-support/atk/at-spi2-core_2.28.0.bb
@@ -0,0 +1,39 @@
+SUMMARY = "Assistive Technology Service Provider Interface (dbus core)"
+HOMEPAGE = "https://wiki.linuxfoundation.org/accessibility/d-bus"
+LICENSE = "LGPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=e9f288ba982d60518f375b5898283886"
+
+MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}"
+
+SRC_URI = "${GNOME_MIRROR}/${BPN}/${MAJ_VER}/${BPN}-${PV}.tar.xz \
+           "
+
+SRC_URI[md5sum] = "9c42f79636ed1c0e908b7483d789b32e"
+SRC_URI[sha256sum] = "42a2487ab11ce43c288e73b2668ef8b1ab40a0e2b4f94e80fca04ad27b6f1c87"
+
+DEPENDS = "dbus glib-2.0 virtual/libx11 libxi libxtst"
+
+inherit meson gtk-doc gettext systemd pkgconfig distro_features_check upstream-version-is-even gobject-introspection
+# depends on virtual/libx11
+REQUIRED_DISTRO_FEATURES = "x11"
+
+EXTRA_OEMESON = " -Dsystemd_user_dir=${systemd_user_unitdir} \
+                  -Ddbus_daemon=${bindir}"
+
+GTKDOC_ENABLE_FLAG = "-Denable_docs=true"
+GTKDOC_DISABLE_FLAG = "-Denable_docs=false"
+
+GI_ENABLE_FLAG = "-Denable-introspection=yes"
+GI_DISABLE_FLAG = "-Denable-introspection=no"
+
+EXTRA_OEMESON_append_class-target = " ${@bb.utils.contains('GI_DATA_ENABLED', 'True', '${GI_ENABLE_FLAG}', \
+                                                                                       '${GI_DISABLE_FLAG}', d)} "
+
+EXTRA_OEMESON_append_class-target = " ${@bb.utils.contains('GTKDOC_ENABLED', 'True', '${GTKDOC_ENABLE_FLAG}', \
+                                                                                     '${GTKDOC_DISABLE_FLAG}', d)} "
+
+FILES_${PN} += "${datadir}/dbus-1/services/*.service \
+                ${datadir}/dbus-1/accessibility-services/*.service \
+                ${datadir}/defaults/at-spi2 \
+                ${systemd_user_unitdir}/at-spi-dbus-bus.service \
+                "
diff --git a/poky/meta/recipes-support/atk/atk/0001-Switch-from-filename-to-basename.patch b/poky/meta/recipes-support/atk/atk/0001-Switch-from-filename-to-basename.patch
new file mode 100644
index 0000000..047e81f
--- /dev/null
+++ b/poky/meta/recipes-support/atk/atk/0001-Switch-from-filename-to-basename.patch
@@ -0,0 +1,38 @@
+Upstream-Status: Submitted
+
+From 0330251715fee908f2f162565d4fa1df5030d0c0 Mon Sep 17 00:00:00 2001
+From: Jeremy Puhlman <jpuhlman@mvista.com>
+Date: Thu, 14 Jun 2018 17:21:49 +0000
+Subject: [PATCH] Switch from filename to basename
+
+When atk-enum-types.h is installed in to a system, the user likely has
+no access to the location where the headers were built, especially if
+the software was built in a sysroot environment. If the headers were
+built for a mulitlib environment, the build pathing may be different.
+Subsequently, if two mulitlib variants of atk are installed together the
+headers conflict for no other reason then they were built in two
+different locations. Switching from filename to basename, still should
+provide sufficient information on the providence of the enums, while not
+conflicting for really no good reason.
+
+Signed-off-by: Jeremy Puhlman <jpuhlman@mvista.com>
+---
+ atk/atk-enum-types.h.template | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/atk/atk-enum-types.h.template b/atk/atk-enum-types.h.template
+index 7b4cec4..8321c24 100644
+--- a/atk/atk-enum-types.h.template
++++ b/atk/atk-enum-types.h.template
+@@ -14,7 +14,7 @@ G_BEGIN_DECLS
+ 
+ /*** BEGIN file-production ***/
+ 
+-/* enumerations from "@filename@" */
++/* enumerations from "@basename@" */
+ /*** END file-production ***/
+ 
+ /*** BEGIN value-header ***/
+-- 
+2.14.1.459.g238e487
+
diff --git a/poky/meta/recipes-support/atk/atk/0001-meson.build-enable-introspection-for-cross-compile.patch b/poky/meta/recipes-support/atk/atk/0001-meson.build-enable-introspection-for-cross-compile.patch
new file mode 100644
index 0000000..c604a98
--- /dev/null
+++ b/poky/meta/recipes-support/atk/atk/0001-meson.build-enable-introspection-for-cross-compile.patch
@@ -0,0 +1,28 @@
+From 3838757d29590cc1ef99c97f7268377322fc17e9 Mon Sep 17 00:00:00 2001
+From: Anuj Mittal <anuj.mittal@intel.com>
+Date: Fri, 6 Apr 2018 12:04:00 +0800
+Subject: [PATCH] meson.build: enable introspection for cross-compile
+
+It works fine in OE-core and doesn't need to be disabled. Let the user decide
+if it should be disabled or not.
+
+Upstream-Status: Pending
+
+Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
+---
+ atk/meson.build | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/atk/meson.build b/atk/meson.build
+index 7b5a683..855e28f 100644
+--- a/atk/meson.build
++++ b/atk/meson.build
+@@ -139,7 +139,7 @@ libatk_dep = declare_dependency(link_with: libatk,
+ 
+ disable_introspection = get_option('disable_introspection')
+ 
+-if not meson.is_cross_build() and not disable_introspection
++if not disable_introspection
+   gnome.generate_gir(libatk,
+                      sources: atk_sources + atk_headers + [ atk_enum_h ] + [ atk_version_h ],
+                      namespace: 'Atk',
diff --git a/poky/meta/recipes-support/atk/atk_2.26.1.bb b/poky/meta/recipes-support/atk/atk_2.26.1.bb
deleted file mode 100644
index 685b599..0000000
--- a/poky/meta/recipes-support/atk/atk_2.26.1.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-SUMMARY = "Accessibility toolkit for GNOME"
-HOMEPAGE = "http://live.gnome.org/GAP/"
-BUGTRACKER = "https://bugzilla.gnome.org/"
-SECTION = "x11/libs"
-
-LICENSE = "GPLv2+ & LGPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=3bf50002aefd002f49e7bb854063f7e7 \
-                    file://atk/atkutil.c;endline=18;md5=6fd31cd2fdc9b30f619ca8d819bc12d3 \
-                    file://atk/atk.h;endline=18;md5=fcd7710187e0eae485e356c30d1b0c3b"
-
-DEPENDS = "glib-2.0"
-
-inherit gnomebase gtk-doc gettext upstream-version-is-even gobject-introspection
-
-SRC_URI[archive.md5sum] = "7cddcc313b9a3efd19b2ddf079ba68f5"
-SRC_URI[archive.sha256sum] = "ef00ff6b83851dddc8db38b4d9faeffb99572ba150b0664ee02e46f015ea97cb"
-
-BBCLASSEXTEND = "native"
-
diff --git a/poky/meta/recipes-support/atk/atk_2.28.1.bb b/poky/meta/recipes-support/atk/atk_2.28.1.bb
new file mode 100644
index 0000000..26b13b6
--- /dev/null
+++ b/poky/meta/recipes-support/atk/atk_2.28.1.bb
@@ -0,0 +1,37 @@
+SUMMARY = "Accessibility toolkit for GNOME"
+HOMEPAGE = "http://live.gnome.org/GAP/"
+BUGTRACKER = "https://bugzilla.gnome.org/"
+SECTION = "x11/libs"
+
+LICENSE = "GPLv2+ & LGPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=3bf50002aefd002f49e7bb854063f7e7 \
+                    file://atk/atkutil.c;endline=18;md5=6fd31cd2fdc9b30f619ca8d819bc12d3 \
+                    file://atk/atk.h;endline=18;md5=fcd7710187e0eae485e356c30d1b0c3b"
+
+# Need gettext-native as Meson can't turn off i18n
+DEPENDS = "gettext-native glib-2.0"
+
+GNOMEBASEBUILDCLASS = "meson"
+inherit gnomebase gtk-doc gettext upstream-version-is-even gobject-introspection
+
+GTKDOC_ENABLE_FLAG = "-Denable_docs=true"
+GTKDOC_DISABLE_FLAG = "-Denable_docs=false"
+
+GI_ENABLE_FLAG = "-Ddisable_introspection=false"
+GI_DISABLE_FLAG = "-Ddisable_introspection=true"
+
+EXTRA_OEMESON_append_class-target = " ${@bb.utils.contains('GI_DATA_ENABLED', 'True', '${GI_ENABLE_FLAG}', \
+                                                                                       '${GI_DISABLE_FLAG}', d)} "
+
+EXTRA_OEMESON_append_class-target = " ${@bb.utils.contains('GTKDOC_ENABLED', 'True', '${GTKDOC_ENABLE_FLAG}', \
+                                                                                     '${GTKDOC_DISABLE_FLAG}', d)} "
+
+SRC_URI_append = " \
+                   file://0001-meson.build-enable-introspection-for-cross-compile.patch \
+                   file://0001-Switch-from-filename-to-basename.patch \
+                   "
+SRC_URI[archive.md5sum] = "dfb5e7474220afa3f4ca7e45af9f3a11"
+SRC_URI[archive.sha256sum] = "cd3a1ea6ecc268a2497f0cd018e970860de24a6d42086919d6bf6c8e8d53f4fc"
+
+BBCLASSEXTEND = "native"
+
diff --git a/poky/meta/recipes-support/attr/acl_2.2.52.bb b/poky/meta/recipes-support/attr/acl_2.2.52.bb
index 8f3dc45..8b89de9 100644
--- a/poky/meta/recipes-support/attr/acl_2.2.52.bb
+++ b/poky/meta/recipes-support/attr/acl_2.2.52.bb
@@ -11,7 +11,7 @@
 DEPENDS = "attr"
 
 SRC_URI = "${SAVANNAH_GNU_MIRROR}/acl/${BP}.src.tar.gz \
-           file://configure.ac;subdir=${S} \
+           file://configure.ac;subdir=${BP} \
            file://run-ptest \
            file://acl-fix-the-order-of-expected-output-of-getfacl.patch \
            file://test-fix-insufficient-quoting-of.patch \
diff --git a/poky/meta/recipes-support/attr/attr.inc b/poky/meta/recipes-support/attr/attr.inc
index 24ef5ad..9fc0f33 100644
--- a/poky/meta/recipes-support/attr/attr.inc
+++ b/poky/meta/recipes-support/attr/attr.inc
@@ -23,7 +23,11 @@
 	    s,^libdir=\'${base_libdir}\'$,libdir=\'${libdir}\',
 }
 
-inherit ptest
+inherit ptest update-alternatives
+
+ALTERNATIVE_PRIORITY = "100"
+ALTERNATIVE_${PN} = "setfattr"
+ALTERNATIVE_TARGET[setfattr] = "${bindir}/setfattr"
 
 do_install_ptest() {
 	tar -c --exclude=ext test/ | ( cd ${D}${PTEST_PATH} && tar -xf - )
diff --git a/poky/meta/recipes-support/bash-completion/bash-completion_2.7.bb b/poky/meta/recipes-support/bash-completion/bash-completion_2.7.bb
deleted file mode 100644
index f519b3f..0000000
--- a/poky/meta/recipes-support/bash-completion/bash-completion_2.7.bb
+++ /dev/null
@@ -1,42 +0,0 @@
-SUMMARY = "Programmable Completion for Bash 4"
-HOMEPAGE = "http://bash-completion.alioth.debian.org/"
-BUGTRACKER = "https://alioth.debian.org/projects/bash-completion/"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
-
-SECTION = "console/utils"
-
-SRC_URI = "https://github.com/scop/bash-completion/releases/download/${PV}/${BPN}-${PV}.tar.xz"
-
-SRC_URI[md5sum] = "28117492bdc9408438e6041683a423ce"
-SRC_URI[sha256sum] = "41ba892d3f427d4a686de32673f35401bc947a7801f684127120cdb13641441e"
-UPSTREAM_CHECK_REGEX = "bash-completion-(?P<pver>(?!2008).+)\.tar"
-UPSTREAM_CHECK_URI = "https://github.com/scop/bash-completion/releases"
-
-PARALLEL_MAKE = ""
-
-inherit autotools
-
-do_install_append() {
-	# compatdir
-	install -d ${D}${sysconfdir}/bash_completion.d/
-	echo '. ${datadir}/${BPN}/bash_completion' >${D}${sysconfdir}/bash_completion
-
-	# Delete files already provided by util-linux
-	local i
-	for i in mount umount rfkill; do
-		rm ${D}${datadir}/${BPN}/completions/$i
-	done
-}
-
-RDEPENDS_${PN} = "bash"
-
-# Some recipes are providing ${PN}-bash-completion packages
-PACKAGES =+ "${PN}-extra"
-FILES_${PN}-extra = "${datadir}/${BPN}/completions/ \
-    ${datadir}/${BPN}/helpers/"
-
-FILES_${PN}-dev += "${datadir}/cmake"
-
-BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-support/bash-completion/bash-completion_2.8.bb b/poky/meta/recipes-support/bash-completion/bash-completion_2.8.bb
new file mode 100644
index 0000000..8506434
--- /dev/null
+++ b/poky/meta/recipes-support/bash-completion/bash-completion_2.8.bb
@@ -0,0 +1,42 @@
+SUMMARY = "Programmable Completion for Bash 4"
+HOMEPAGE = "http://bash-completion.alioth.debian.org/"
+BUGTRACKER = "https://alioth.debian.org/projects/bash-completion/"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
+
+SECTION = "console/utils"
+
+SRC_URI = "https://github.com/scop/bash-completion/releases/download/${PV}/${BPN}-${PV}.tar.xz"
+
+SRC_URI[md5sum] = "201b6ae62f7d5fb5b1b25e34427db919"
+SRC_URI[sha256sum] = "c01f5570f5698a0dda8dc9cfb2a83744daa1ec54758373a6e349bd903375f54d"
+UPSTREAM_CHECK_REGEX = "bash-completion-(?P<pver>(?!2008).+)\.tar"
+UPSTREAM_CHECK_URI = "https://github.com/scop/bash-completion/releases"
+
+PARALLEL_MAKE = ""
+
+inherit autotools
+
+do_install_append() {
+	# compatdir
+	install -d ${D}${sysconfdir}/bash_completion.d/
+	echo '. ${datadir}/${BPN}/bash_completion' >${D}${sysconfdir}/bash_completion
+
+	# Delete files already provided by util-linux
+	local i
+	for i in mount umount; do
+		rm ${D}${datadir}/${BPN}/completions/$i
+	done
+}
+
+RDEPENDS_${PN} = "bash"
+
+# Some recipes are providing ${PN}-bash-completion packages
+PACKAGES =+ "${PN}-extra"
+FILES_${PN}-extra = "${datadir}/${BPN}/completions/ \
+    ${datadir}/${BPN}/helpers/"
+
+FILES_${PN}-dev += "${datadir}/cmake"
+
+BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-support/beecrypt/beecrypt/add-option-dev-dsp.patch b/poky/meta/recipes-support/beecrypt/beecrypt/add-option-dev-dsp.patch
deleted file mode 100644
index b3298ce..0000000
--- a/poky/meta/recipes-support/beecrypt/beecrypt/add-option-dev-dsp.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-Add config option --with-dev-dsp.
-
-Upstream-Status: Pending
-
-Signed-off-by: Zhang Xiao <xiao.zhang@windriver.com>
----
---- a/configure.ac
-+++ b/configure.ac
-@@ -106,6 +106,16 @@ AC_ARG_WITH(python,[  --with-python[[=AR
-   fi
-   ])
- 
-+AC_ARG_WITH(dev-dsp,[  --with-dev-dsp          enables dev/dsp for entropy producing. auto for auto-detecting dev/dep on host. [[default=no]]],[
-+  if test "$withval" = yes; then
-+    AC_DEFINE([HAVE_DEV_DSP], 1)
-+  else
-+    if test "$withval" = auto;  then
-+      ac_detect_dev_dsp=yes
-+    fi
-+  fi
-+  ],[ac_detect_dev_dsp=no])
-+
- # Check for expert mode
- if test "$ac_enable_expert_mode" = yes; then
-   BEE_EXPERT_MODE
-@@ -464,7 +474,7 @@ linux*)
-       ac_cv_have_dev_dsp=no
-     fi
-     ])
--  if test "$ac_cv_have_dev_dsp" = yes; then
-+  if test "$ac_cv_have_dev_dsp" = yes && test "$ac_detect_dev_dsp" = yes; then
-     AC_DEFINE([HAVE_DEV_DSP], 1)
-   fi
-   ;;
diff --git a/poky/meta/recipes-support/beecrypt/beecrypt/beecrypt-enable-ptest-support.patch b/poky/meta/recipes-support/beecrypt/beecrypt/beecrypt-enable-ptest-support.patch
deleted file mode 100644
index 3e5513f..0000000
--- a/poky/meta/recipes-support/beecrypt/beecrypt/beecrypt-enable-ptest-support.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-beecrypt: enable ptest support
-
-Upstream-Status: Inappropriate [embedded specific]
-
-Add install-ptest rules.
-
-Signed-off-by: Chong Lu <Chong.Lu@windriver.com>
----
- Makefile.am       | 3 +++
- tests/Makefile.am | 3 +++
- 2 files changed, 6 insertions(+)
-
-diff --git a/Makefile.am b/Makefile.am
-index b7e7869..5076f59 100644
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -73,3 +73,6 @@ DISTCLEANFILES = mpopt.s blowfishopt.s sha1opt.s
- 
- bench:
- 	(cd tests && $(MAKE) $(AM_MAKEFLAGS) bench)
-+
-+install-ptest:
-+	(cd tests && $(MAKE) $(AM_MAKEFLAGS) check_PROGRAMS)
-diff --git a/tests/Makefile.am b/tests/Makefile.am
-index 1604e5e..d8db8d8 100644
---- a/tests/Makefile.am
-+++ b/tests/Makefile.am
-@@ -101,3 +101,6 @@ bench: benchme benchrsa benchhf benchbc
- 	./benchbc AES 128
- 	./benchbc Blowfish 128
- 	./benchbc Blowfish 128
-+
-+check_PROGRAMS:
-+	$(MAKE) $(AM_MAKEFLAGS) $(check_PROGRAMS)
--- 
-1.8.1.2
-
diff --git a/poky/meta/recipes-support/beecrypt/beecrypt/disable-icu-check.patch b/poky/meta/recipes-support/beecrypt/beecrypt/disable-icu-check.patch
deleted file mode 100644
index 91b1fa6..0000000
--- a/poky/meta/recipes-support/beecrypt/beecrypt/disable-icu-check.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-We are unable to run code at configure time in a cross environemnt, but as we
-control the build we can be fairly certain this dependency is met.
-
-Upstream-Status: Inappropriate [embedded specific]
-
-JL 05/07/10
-Index: beecrypt-4.2.1/configure.ac
-===================================================================
---- beecrypt-4.2.1.orig/configure.ac	2010-11-26 17:12:25.000000000 +0800
-+++ beecrypt-4.2.1/configure.ac	2010-11-26 17:12:30.000000000 +0800
-@@ -292,32 +292,6 @@
- # Predefines and checks for C++ API support
- AH_TEMPLATE([CPPGLUE],[Define to 1 if you want to include the C++ code])
- 
--if test "$ac_with_cplusplus" = yes; then
--  AC_MSG_CHECKING([for IBM's ICU library version >= 2.8])
--  AC_LANG_PUSH(C)
--  AC_RUN_IFELSE([
--    AC_LANG_PROGRAM([[#include <unicode/uversion.h>]],[[
--      #if U_ICU_VERSION_MAJOR_NUM < 2
--      exit(1);
--      #elif U_ICU_VERSION_MAJOR_NUM == 2
--      # if U_ICU_VERSION_MINOR_NUM < 8
--      exit(1);
--      # else
--      exit(0);
--      # endif
--      #else
--      exit(0);
--      #endif
--    ]])],[
--    AC_MSG_RESULT([yes])
--    ],[
--    AC_MSG_RESULT([no])
--    AC_MSG_WARN([disabling cplusplus])
--    ac_with_cplusplus=no
--    ])
--  AC_LANG_POP(C)
--fi
--
- AM_CONDITIONAL([WITH_CPLUSPLUS],[test "$ac_with_cplusplus" = yes])
- 
- if test "$ac_with_cplusplus" = yes ; then
diff --git a/poky/meta/recipes-support/beecrypt/beecrypt/fix-for-gcc-4.7.patch b/poky/meta/recipes-support/beecrypt/beecrypt/fix-for-gcc-4.7.patch
deleted file mode 100644
index 8144e39..0000000
--- a/poky/meta/recipes-support/beecrypt/beecrypt/fix-for-gcc-4.7.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-
-gcc-4.7 seems to be stricter about some things, so follow
-the suggestion from the error/note information.
-
-    ../../x86_64-linux-libtool --tag=CXX   --mode=compile g++ -DHAVE_CONFIG_H -I. -I../.. 
-    x86_64-linux-libtool: compile:  g++ -DHAVE_CONFIG_H -I. -I../.. -I../../include -isyst
-    In file included from ../../include/beecrypt/c++/util/Hashtable.h:42:0,
-                     from ../../include/beecrypt/c++/util/Properties.h:36,
-                     from Properties.cxx:25:
-    ../../include/beecrypt/c++/util/AbstractSet.h: In instantiation of 'bool beecrypt::uti
-    Properties.cxx:228:1:   required from here
-    ../../include/beecrypt/c++/util/AbstractSet.h:59:27: error: 'containsAll' was not decl
-    ../../include/beecrypt/c++/util/AbstractSet.h:59:27: note: declarations in dependent b
-    ../../include/beecrypt/c++/util/AbstractSet.h:59:27: note: use 'this->containsAll' ins
-    ../../include/beecrypt/c++/util/AbstractSet.h: In instantiation of 'bool beecrypt::uti
-    Properties.cxx:228:1:   required from here
-    ../../include/beecrypt/c++/util/AbstractSet.h:59:27: error: 'containsAll' was not decl
-    ../../include/beecrypt/c++/util/AbstractSet.h:59:27: note: declarations in dependent b
-    ../../include/beecrypt/c++/util/AbstractSet.h:59:27: note: use 'this->containsAll' ins
-    
-
-Upstream-Status: Pending
-
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
-
-
-Index: beecrypt-4.2.1/include/beecrypt/c++/util/AbstractSet.h
-===================================================================
---- beecrypt-4.2.1.orig/include/beecrypt/c++/util/AbstractSet.h
-+++ beecrypt-4.2.1/include/beecrypt/c++/util/AbstractSet.h
-@@ -56,7 +56,7 @@ namespace beecrypt {
- 					if (c->size() != size())
- 						return false;
- 
--					return containsAll(*c);
-+					return this->containsAll(*c);
- 				}
- 				return false;
- 			}
diff --git a/poky/meta/recipes-support/beecrypt/beecrypt/fix-security.patch b/poky/meta/recipes-support/beecrypt/beecrypt/fix-security.patch
deleted file mode 100644
index 6cb0c00..0000000
--- a/poky/meta/recipes-support/beecrypt/beecrypt/fix-security.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-Fix visibility of various C++ functions, inspired by a similar patch in the Fink
-project: 
-http://www.mail-archive.com/fink-commits@lists.sourceforge.net/msg75742.html
-
-JL 05/07/10 
-
-Upstream-Status: Pending
-
-Index: beecrypt-4.2.1/include/beecrypt/c++/beeyond/BeeCertificate.h
-===================================================================
---- beecrypt-4.2.1.orig/include/beecrypt/c++/beeyond/BeeCertificate.h	2010-11-26 17:22:57.000000000 +0800
-+++ beecrypt-4.2.1/include/beecrypt/c++/beeyond/BeeCertificate.h	2010-11-26 17:23:01.000000000 +0800
-@@ -147,13 +147,13 @@
- 			mutable bytearray* enc;
- 
- 			BeeCertificate();
--			BeeCertificate(InputStream& in) throw (IOException);
- 
- 			void encodeTBS(DataOutputStream& out) const throw (IOException);
- 
- 			bytearray* encodeTBS() const throw (CertificateEncodingException);
- 
- 		public:
-+			BeeCertificate(InputStream& in) throw (IOException);
- 			BeeCertificate(const BeeCertificate&) throw (CloneNotSupportedException);
- 			virtual ~BeeCertificate();
- 
-Index: beecrypt-4.2.1/include/beecrypt/c++/security/Security.h
-===================================================================
---- beecrypt-4.2.1.orig/include/beecrypt/c++/security/Security.h	2010-11-26 17:20:55.000000000 +0800
-+++ beecrypt-4.2.1/include/beecrypt/c++/security/Security.h	2010-11-26 17:21:36.000000000 +0800
-@@ -61,7 +61,6 @@
- 			friend class SecureRandom;
- 			friend class Signature;
- 
--		private:
- 			struct spi
- 			{
- 				Object* cspi;
-@@ -76,6 +75,7 @@
- 			static spi* getSpi(const String& algo, const String& type, const Provider&) throw (NoSuchAlgorithmException);
- 			static spi* getFirstSpi(const String& type);
- 
-+		private:
- 			static const String& getKeyStoreDefault();
- 
- 			static bool _init;
diff --git a/poky/meta/recipes-support/beecrypt/beecrypt/run-ptest b/poky/meta/recipes-support/beecrypt/beecrypt/run-ptest
deleted file mode 100644
index 2ee294d..0000000
--- a/poky/meta/recipes-support/beecrypt/beecrypt/run-ptest
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/bin/sh
-
-cd tests
-for i in `ls`; do ./$i; if [ $? -eq 0 ]; then echo "PASS: $i"; \
-    else echo "FAIL: $i"; fi; done
diff --git a/poky/meta/recipes-support/beecrypt/beecrypt_4.2.1.bb b/poky/meta/recipes-support/beecrypt/beecrypt_4.2.1.bb
deleted file mode 100644
index 1e626f1..0000000
--- a/poky/meta/recipes-support/beecrypt/beecrypt_4.2.1.bb
+++ /dev/null
@@ -1,48 +0,0 @@
-# Beecrypt OE build file
-# Copyright (C) 2004-2005, Advanced Micro Devices, Inc.  All Rights Reserved
-# Released under the MIT license (see packages/COPYING)
-
-SUMMARY = "A general-purpose cryptography library"
-HOMEPAGE = "http://sourceforge.net/projects/beecrypt"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/beecrypt/beecrypt-${PV}.tar.gz \
-           file://disable-icu-check.patch \
-           file://fix-security.patch \
-           file://fix-for-gcc-4.7.patch \
-           file://run-ptest \
-           file://beecrypt-enable-ptest-support.patch \
-           file://add-option-dev-dsp.patch \
-          "
-
-SRC_URI[md5sum] = "8441c014170823f2dff97e33df55af1e"
-SRC_URI[sha256sum] = "286f1f56080d1a6b1d024003a5fa2158f4ff82cae0c6829d3c476a4b5898c55d"
-
-LICENSE = "GPLv2 & LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=9894370afd5dfe7d02b8d14319e729a1 \
-                    file://COPYING.LIB;md5=dcf3c825659e82539645da41a7908589 \
-                    file://include/beecrypt/beecrypt.h;endline=20;md5=47a93eef539aac237eef86297a4d71c1"
-
-PR = "r3"
-
-inherit autotools multilib_header ptest
-acpaths=""
-
-do_install_append() {
-	oe_multilib_header beecrypt/gnu.h
-}
-
-EXTRA_OECONF = "--without-python --enable-shared --enable-static --disable-openmp --with-java=no"
-
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[cplusplus] = "--with-cplusplus,--without-cplusplus,icu"
-
-FILES_${PN} = "${sysconfdir} ${libdir}/*.so.* ${libdir}/${BPN}/*.so.*"
-FILES_${PN}-dev += "${libdir}/${BPN}/*.so ${libdir}/${BPN}/*.la"
-FILES_${PN}-staticdev += "${libdir}/${BPN}/*.a"
-
-BBCLASSEXTEND = "native nativesdk"
-
-do_install_ptest () {
-	mkdir ${D}${PTEST_PATH}/tests
-	cp -r ${B}/tests/.libs/test* ${D}${PTEST_PATH}/tests
-}
diff --git a/poky/meta/recipes-support/boost/bjam-native_1.66.0.bb b/poky/meta/recipes-support/boost/bjam-native_1.66.0.bb
deleted file mode 100644
index 92c86a3..0000000
--- a/poky/meta/recipes-support/boost/bjam-native_1.66.0.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-require boost-${PV}.inc
-
-SUMMARY = "Portable Boost.Jam build tool for boost"
-SECTION = "devel"
-
-inherit native
-
-SRC_URI += "file://bjam-native-build-bjam.debug.patch \
-            file://0001-Fix-a-strange-assert-typo-how-was-this-released-with.patch"
-
-do_compile() {
-    ./bootstrap.sh --with-toolset=gcc
-}
-
-do_install() {
-    install -d ${D}${bindir}/
-    # install unstripped version for bjam
-    install -c -m 755 bjam.debug ${D}${bindir}/bjam
-}
diff --git a/poky/meta/recipes-support/boost/bjam-native_1.68.0.bb b/poky/meta/recipes-support/boost/bjam-native_1.68.0.bb
new file mode 100644
index 0000000..94f96e6
--- /dev/null
+++ b/poky/meta/recipes-support/boost/bjam-native_1.68.0.bb
@@ -0,0 +1,19 @@
+require boost-${PV}.inc
+
+SUMMARY = "Portable Boost.Jam build tool for boost"
+SECTION = "devel"
+
+inherit native
+
+SRC_URI += "file://bjam-native-build-bjam.debug.patch \
+"
+
+do_compile() {
+    ./bootstrap.sh --with-toolset=gcc
+}
+
+do_install() {
+    install -d ${D}${bindir}/
+    # install unstripped version for bjam
+    install -c -m 755 bjam.debug ${D}${bindir}/bjam
+}
diff --git a/poky/meta/recipes-support/boost/boost-1.66.0.inc b/poky/meta/recipes-support/boost/boost-1.66.0.inc
deleted file mode 100644
index fe2b863..0000000
--- a/poky/meta/recipes-support/boost/boost-1.66.0.inc
+++ /dev/null
@@ -1,21 +0,0 @@
-# The Boost web site provides free peer-reviewed portable
-# C++ source libraries. The emphasis is on libraries which
-# work well with the C++ Standard Library. The libraries are
-# intended to be widely useful, and are in regular use by
-# thousands of programmers across a broad spectrum of applications.
-HOMEPAGE = "http://www.boost.org/"
-LICENSE = "BSL-1.0 & MIT & Python-2.0"
-LIC_FILES_CHKSUM = "file://LICENSE_1_0.txt;md5=e4224ccaecb14d942c71d31bef20d78c"
-
-BOOST_VER = "${@"_".join(d.getVar("PV").split("."))}"
-BOOST_MAJ = "${@"_".join(d.getVar("PV").split(".")[0:2])}"
-BOOST_P = "boost_${BOOST_VER}"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/project/boost/boost/${PV}/${BOOST_P}.tar.bz2"
-SRC_URI[md5sum] = "b2dfbd6c717be4a7bb2d88018eaccf75"
-SRC_URI[sha256sum] = "5721818253e6a0989583192f96782c4a98eb6204965316df9f5ad75819225ca9"
-
-UPSTREAM_CHECK_URI = "http://www.boost.org/users/download/"
-UPSTREAM_CHECK_REGEX = "boostorg/release/(?P<pver>.*)/source/"
-
-S = "${WORKDIR}/${BOOST_P}"
diff --git a/poky/meta/recipes-support/boost/boost-1.68.0.inc b/poky/meta/recipes-support/boost/boost-1.68.0.inc
new file mode 100644
index 0000000..b367a80
--- /dev/null
+++ b/poky/meta/recipes-support/boost/boost-1.68.0.inc
@@ -0,0 +1,21 @@
+# The Boost web site provides free peer-reviewed portable
+# C++ source libraries. The emphasis is on libraries which
+# work well with the C++ Standard Library. The libraries are
+# intended to be widely useful, and are in regular use by
+# thousands of programmers across a broad spectrum of applications.
+HOMEPAGE = "http://www.boost.org/"
+LICENSE = "BSL-1.0 & MIT & Python-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE_1_0.txt;md5=e4224ccaecb14d942c71d31bef20d78c"
+
+BOOST_VER = "${@"_".join(d.getVar("PV").split("."))}"
+BOOST_MAJ = "${@"_".join(d.getVar("PV").split(".")[0:2])}"
+BOOST_P = "boost_${BOOST_VER}"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/project/boost/boost/${PV}/${BOOST_P}.tar.bz2"
+SRC_URI[md5sum] = "7fbd1890f571051f2a209681d57d486a"
+SRC_URI[sha256sum] = "7f6130bc3cf65f56a618888ce9d5ea704fa10b462be126ad053e80e553d6d8b7"
+
+UPSTREAM_CHECK_URI = "http://www.boost.org/users/download/"
+UPSTREAM_CHECK_REGEX = "boostorg/release/(?P<pver>.*)/source/"
+
+S = "${WORKDIR}/${BOOST_P}"
diff --git a/poky/meta/recipes-support/boost/boost.inc b/poky/meta/recipes-support/boost/boost.inc
index 0ff5b7a..c4faea2 100644
--- a/poky/meta/recipes-support/boost/boost.inc
+++ b/poky/meta/recipes-support/boost/boost.inc
@@ -9,6 +9,7 @@
 	atomic \
 	chrono \
 	container \
+	contract \
 	date_time \
 	exception \
 	filesystem \
@@ -134,9 +135,8 @@
 		'--layout=system' \
 		"
 
-# use PARALLEL_MAKE to speed up the build, but limit it by -j 64, greater parallelism causes bjam to segfault or to ignore -j
-# https://svn.boost.org/trac/boost/ticket/7634
-BOOST_PARALLEL_MAKE = "${@oe.utils.parallel_make_argument(d, '-j%d', limit=64)}"
+# use PARALLEL_MAKE to speed up the build
+BOOST_PARALLEL_MAKE = "${@oe.utils.parallel_make_argument(d, '-j%d')}"
 BJAM_OPTS    = '${BOOST_PARALLEL_MAKE} -d+2 -q \
 		${BJAM_TOOLS} \
 		-sBOOST_BUILD_USER_CONFIG=${WORKDIR}/user-config.jam \
diff --git a/poky/meta/recipes-support/boost/boost/0001-make_x86_64_sysv_elf_gas.S-set-.file-section.patch b/poky/meta/recipes-support/boost/boost/0001-make_x86_64_sysv_elf_gas.S-set-.file-section.patch
new file mode 100644
index 0000000..c2ac49e
--- /dev/null
+++ b/poky/meta/recipes-support/boost/boost/0001-make_x86_64_sysv_elf_gas.S-set-.file-section.patch
@@ -0,0 +1,48 @@
+From c99f798407e44c86e9f64f5b1adf3b4d0549eef2 Mon Sep 17 00:00:00 2001
+From: Mingli Yu <Mingli.Yu@windriver.com>
+Date: Fri, 15 Jun 2018 16:21:56 +0800
+Subject: [PATCH] make_x86_64_sysv_elf_gas.S: set .file section
+
+Set .file section explicitly for .S files to avoid
+the linker introduces the host path in symbols for
+object files whose source file is .S
+Otherwise, there is a host path in the symbols as below:
+$ readelf --wide --symbols /my-build/boost/1.67.0-r0/boost_1_67_0/x86_64-poky-linux/boost/bin.v2/libs/context/build/aca09349fdb84d131321425f6c3a38ed/libboost_context.so.1.67.0
+
+42: 0000000000000000 0 FILE LOCAL DEFAULT ABS /my-build/boost/1.67.0-r0/boost_1_67_0/x86_64-poky-linux/boost/bin.v2/libs/context/build/aca09349fdb84d131321425f6c3a38ed/asm/make_x86_64_sysv_elf_gas.o
+
+Upstream-Status: Pending
+
+Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
+---
+ libs/context/src/asm/make_i386_sysv_elf_gas.S   | 1 +
+ libs/context/src/asm/make_x86_64_sysv_elf_gas.S | 1 +
+ 2 files changed, 2 insertions(+)
+
+diff --git a/libs/context/src/asm/make_i386_sysv_elf_gas.S b/libs/context/src/asm/make_i386_sysv_elf_gas.S
+index de77e88..b76de26 100644
+--- a/libs/context/src/asm/make_i386_sysv_elf_gas.S
++++ b/libs/context/src/asm/make_i386_sysv_elf_gas.S
+@@ -24,6 +24,7 @@
+  *                                                                                      *
+  ****************************************************************************************/
+ 
++.file "make_i386_sysv_elf_gas.S"
+ .text
+ .globl make_fcontext
+ .align 2
+diff --git a/libs/context/src/asm/make_x86_64_sysv_elf_gas.S b/libs/context/src/asm/make_x86_64_sysv_elf_gas.S
+index 25a0c00..0ef3756 100644
+--- a/libs/context/src/asm/make_x86_64_sysv_elf_gas.S
++++ b/libs/context/src/asm/make_x86_64_sysv_elf_gas.S
+@@ -24,6 +24,7 @@
+  *                                                                                      *
+  ****************************************************************************************/
+ 
++.file "make_x86_64_sysv_elf_gas.S"
+ .text
+ .globl make_fcontext
+ .type make_fcontext,@function
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-support/boost/boost/0002-Don-t-set-up-m32-m64-we-do-that-ourselves.patch b/poky/meta/recipes-support/boost/boost/0002-Don-t-set-up-m32-m64-we-do-that-ourselves.patch
deleted file mode 100644
index 26f3cbb..0000000
--- a/poky/meta/recipes-support/boost/boost/0002-Don-t-set-up-m32-m64-we-do-that-ourselves.patch
+++ /dev/null
@@ -1,65 +0,0 @@
-From e4d3a7470b307693660d0412732e7266d1738d8c Mon Sep 17 00:00:00 2001
-From: Christopher Larson <chris_larson@mentor.com>
-Date: Tue, 13 Dec 2016 10:29:17 -0700
-Subject: [PATCH 6/6] Don't set up -m32/-m64, we do that ourselves
-
-Upstream-Status: Inappropriate
-Signed-off-by: Christopher Larson <chris_larson@mentor.com>
-
----
- tools/build/src/tools/gcc.jam | 39 ---------------------------------------
- 1 file changed, 39 deletions(-)
-
-diff --git a/tools/build/src/tools/gcc.jam b/tools/build/src/tools/gcc.jam
-index e4fc6c32..37914fd0 100644
---- a/tools/build/src/tools/gcc.jam
-+++ b/tools/build/src/tools/gcc.jam
-@@ -337,45 +337,6 @@ rule set-address-model-options ( targets * : sources * : properties * )
-     {
-         local option ;
-         local target-os = [ feature.get-values target-os : $(properties) ] ;
--        if $(target-os) = aix
--        {
--            if $(model) = 32
--            {
--                option = -maix32 ;
--            }
--            else
--            {
--                option = -maix64 ;
--            }
--        }
--        else if $(target-os) = hpux
--        {
--            if $(model) = 32
--            {
--                option = -milp32 ;
--            }
--            else
--            {
--                option = -mlp64 ;
--            }
--        }
--        else
--        {
--            local arch = [ feature.get-values architecture : $(properties) ] ;
--            if $(arch) = power || $(arch) = sparc || $(arch) = x86
--            {
--                if $(model) = 32
--                {
--                    option = -m32 ;
--                }
--                else if $(model) = 64
--                {
--                    option = -m64 ;
--                }
--            }
--            # For darwin, the model can be 32_64. darwin.jam will handle that
--            # on its own.
--        }
-         OPTIONS on $(targets) += $(option) ;
-     }
- }
--- 
-2.15.1
-
diff --git a/poky/meta/recipes-support/boost/boost_1.66.0.bb b/poky/meta/recipes-support/boost/boost_1.66.0.bb
deleted file mode 100644
index 63b82a5..0000000
--- a/poky/meta/recipes-support/boost/boost_1.66.0.bb
+++ /dev/null
@@ -1,11 +0,0 @@
-require boost-${PV}.inc
-require boost.inc
-
-SRC_URI += "\
-    file://arm-intrinsics.patch \
-    file://boost-CVE-2012-2677.patch \
-    file://boost-math-disable-pch-for-gcc.patch \
-    file://0001-Apply-boost-1.62.0-no-forced-flags.patch.patch \
-    file://0003-Don-t-set-up-arch-instruction-set-flags-we-do-that-o.patch \
-    file://0002-Don-t-set-up-m32-m64-we-do-that-ourselves.patch \
-"
diff --git a/poky/meta/recipes-support/boost/boost_1.68.0.bb b/poky/meta/recipes-support/boost/boost_1.68.0.bb
new file mode 100644
index 0000000..c7958a4
--- /dev/null
+++ b/poky/meta/recipes-support/boost/boost_1.68.0.bb
@@ -0,0 +1,11 @@
+require boost-${PV}.inc
+require boost.inc
+
+SRC_URI += "\
+           file://arm-intrinsics.patch \
+           file://boost-CVE-2012-2677.patch \
+           file://boost-math-disable-pch-for-gcc.patch \
+           file://0001-Apply-boost-1.62.0-no-forced-flags.patch.patch \
+           file://0003-Don-t-set-up-arch-instruction-set-flags-we-do-that-o.patch \
+           file://0001-make_x86_64_sysv_elf_gas.S-set-.file-section.patch \
+           "
diff --git a/poky/meta/recipes-support/boost/files/0001-Fix-a-strange-assert-typo-how-was-this-released-with.patch b/poky/meta/recipes-support/boost/files/0001-Fix-a-strange-assert-typo-how-was-this-released-with.patch
deleted file mode 100644
index a75133d..0000000
--- a/poky/meta/recipes-support/boost/files/0001-Fix-a-strange-assert-typo-how-was-this-released-with.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From 5685527364198597f25fc1c6236cb64cbc3de44f Mon Sep 17 00:00:00 2001
-From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Wed, 4 Oct 2017 18:16:08 +0300
-Subject: [PATCH] Fix a strange assert typo; how was this released without
- noticing?
-
-Upstream-Status: Pending
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
----
- tools/build/src/engine/debugger.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/tools/build/src/engine/debugger.c b/tools/build/src/engine/debugger.c
-index 802f262..152a7e6 100644
---- a/tools/build/src/engine/debugger.c
-+++ b/tools/build/src/engine/debugger.c
-@@ -1092,7 +1092,7 @@ static void debug_start_child( int argc, const char * * argv )
-     PROCESS_INFORMATION pi = { NULL, NULL, 0, 0 };
-     STARTUPINFO si = { sizeof( STARTUPINFO ), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
-         0, 0, 0, 0, 0, 0 };
--    assert( DEBUG_STATE == DEBUG_NO_CHILD );
-+    assert( debug_state == DEBUG_NO_CHILD );
-     if ( ! CreatePipe( &pipe1[ 0 ], &pipe1[ 1 ], &sa, 0 ) )
-     {
-         printf("internal error\n");
-@@ -1176,7 +1176,7 @@ static void debug_start_child( int argc, const char * * argv )
-     int read_fd;
-     int pid;
-     int i;
--    assert( DEBUG_STATE == DEBUG_NO_CHILD );
-+    assert( debug_state == DEBUG_NO_CHILD );
-     pipe(pipe1);
-     pipe(pipe2);
-     pid = fork();
--- 
-2.14.1
-
diff --git a/poky/meta/recipes-support/ca-certificates/ca-certificates_20170717.bb b/poky/meta/recipes-support/ca-certificates/ca-certificates_20170717.bb
deleted file mode 100644
index 3502948..0000000
--- a/poky/meta/recipes-support/ca-certificates/ca-certificates_20170717.bb
+++ /dev/null
@@ -1,88 +0,0 @@
-SUMMARY = "Common CA certificates"
-DESCRIPTION = "This package includes PEM files of CA certificates to allow \
-SSL-based applications to check for the authenticity of SSL connections. \
-This derived from Debian's CA Certificates."
-HOMEPAGE = "http://packages.debian.org/sid/ca-certificates"
-SECTION = "misc"
-LICENSE = "GPL-2.0+ & MPL-2.0"
-LIC_FILES_CHKSUM = "file://debian/copyright;md5=e7358b9541ccf3029e9705ed8de57968"
-
-# This is needed to ensure we can run the postinst at image creation time
-DEPENDS = ""
-DEPENDS_class-native = "openssl-native"
-DEPENDS_class-nativesdk = "openssl-native"
-# Need c_rehash from openssl and run-parts from debianutils
-PACKAGE_WRITE_DEPS += "openssl-native debianutils-native"
-
-SRCREV = "34b8e19e541b8af4076616b2e170c7a70cdaded0"
-
-SRC_URI = "git://salsa.debian.org/debian/ca-certificates.git;protocol=https \
-           file://0002-update-ca-certificates-use-SYSROOT.patch \
-           file://0001-update-ca-certificates-don-t-use-Debianisms-in-run-p.patch \
-           file://update-ca-certificates-support-Toybox.patch \
-           file://default-sysroot.patch \
-           file://sbindir.patch \
-           file://0003-update-ca-certificates-use-relative-symlinks-from-ET.patch \
-           "
-
-S = "${WORKDIR}/git"
-SYSROOT_DIRS_class-native += "${sysconfdir} ${datadir}/ca-certificates"
-
-inherit allarch
-
-EXTRA_OEMAKE = "\
-    'CERTSDIR=${datadir}/ca-certificates' \
-    'SBINDIR=${sbindir}' \
-"
-
-do_compile_prepend() {
-    oe_runmake clean
-}
-
-do_install () {
-    install -d ${D}${datadir}/ca-certificates \
-               ${D}${sysconfdir}/ssl/certs \
-               ${D}${sysconfdir}/ca-certificates/update.d
-    oe_runmake 'DESTDIR=${D}' install
-
-    install -d ${D}${mandir}/man8
-    install -m 0644 sbin/update-ca-certificates.8 ${D}${mandir}/man8/
-
-    install -d ${D}${sysconfdir}
-    {
-        echo "# Lines starting with # will be ignored"
-        echo "# Lines starting with ! will remove certificate on next update"
-        echo "#"
-        find ${D}${datadir}/ca-certificates -type f -name '*.crt' | \
-            sed 's,^${D}${datadir}/ca-certificates/,,'
-    } >${D}${sysconfdir}/ca-certificates.conf
-}
-
-do_install_append_class-target () {
-    sed -i -e 's,/etc/,${sysconfdir}/,' \
-           -e 's,/usr/share/,${datadir}/,' \
-           -e 's,/usr/local,${prefix}/local,' \
-        ${D}${sbindir}/update-ca-certificates \
-        ${D}${mandir}/man8/update-ca-certificates.8
-}
-
-pkg_postinst_${PN}_class-target () {
-    SYSROOT="$D" $D${sbindir}/update-ca-certificates
-}
-
-CONFFILES_${PN} += "${sysconfdir}/ca-certificates.conf"
-
-# Rather than make a postinst script that works for both target and nativesdk,
-# we just run update-ca-certificate from do_install() for nativesdk.
-CONFFILES_${PN}_append_class-nativesdk = " ${sysconfdir}/ssl/certs/ca-certificates.crt"
-do_install_append_class-nativesdk () {
-    SYSROOT="${D}${SDKPATHNATIVE}" ${D}${sbindir}/update-ca-certificates
-}
-
-do_install_append_class-native () {
-    SYSROOT="${D}${base_prefix}" ${D}${sbindir}/update-ca-certificates
-}
-
-RDEPENDS_${PN} += "openssl"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/ca-certificates/ca-certificates_20180409.bb b/poky/meta/recipes-support/ca-certificates/ca-certificates_20180409.bb
new file mode 100644
index 0000000..0d57083
--- /dev/null
+++ b/poky/meta/recipes-support/ca-certificates/ca-certificates_20180409.bb
@@ -0,0 +1,87 @@
+SUMMARY = "Common CA certificates"
+DESCRIPTION = "This package includes PEM files of CA certificates to allow \
+SSL-based applications to check for the authenticity of SSL connections. \
+This derived from Debian's CA Certificates."
+HOMEPAGE = "http://packages.debian.org/sid/ca-certificates"
+SECTION = "misc"
+LICENSE = "GPL-2.0+ & MPL-2.0"
+LIC_FILES_CHKSUM = "file://debian/copyright;md5=aeb420429b1659507e0a5a1b123e8308"
+
+# This is needed to ensure we can run the postinst at image creation time
+DEPENDS = ""
+DEPENDS_class-native = "openssl-native"
+DEPENDS_class-nativesdk = "openssl-native"
+# Need c_rehash from openssl and run-parts from debianutils
+PACKAGE_WRITE_DEPS += "openssl-native debianutils-native"
+
+SRCREV = "dbbd11e56af93bb79f21d0ee6059a901f83f70a5"
+
+SRC_URI = "git://salsa.debian.org/debian/ca-certificates.git;protocol=https \
+           file://0002-update-ca-certificates-use-SYSROOT.patch \
+           file://0001-update-ca-certificates-don-t-use-Debianisms-in-run-p.patch \
+           file://update-ca-certificates-support-Toybox.patch \
+           file://default-sysroot.patch \
+           file://sbindir.patch \
+           file://0003-update-ca-certificates-use-relative-symlinks-from-ET.patch \
+           "
+
+S = "${WORKDIR}/git"
+
+inherit allarch
+
+EXTRA_OEMAKE = "\
+    'CERTSDIR=${datadir}/ca-certificates' \
+    'SBINDIR=${sbindir}' \
+"
+
+do_compile_prepend() {
+    oe_runmake clean
+}
+
+do_install () {
+    install -d ${D}${datadir}/ca-certificates \
+               ${D}${sysconfdir}/ssl/certs \
+               ${D}${sysconfdir}/ca-certificates/update.d
+    oe_runmake 'DESTDIR=${D}' install
+
+    install -d ${D}${mandir}/man8
+    install -m 0644 sbin/update-ca-certificates.8 ${D}${mandir}/man8/
+
+    install -d ${D}${sysconfdir}
+    {
+        echo "# Lines starting with # will be ignored"
+        echo "# Lines starting with ! will remove certificate on next update"
+        echo "#"
+        find ${D}${datadir}/ca-certificates -type f -name '*.crt' | \
+            sed 's,^${D}${datadir}/ca-certificates/,,'
+    } >${D}${sysconfdir}/ca-certificates.conf
+}
+
+do_install_append_class-target () {
+    sed -i -e 's,/etc/,${sysconfdir}/,' \
+           -e 's,/usr/share/,${datadir}/,' \
+           -e 's,/usr/local,${prefix}/local,' \
+        ${D}${sbindir}/update-ca-certificates \
+        ${D}${mandir}/man8/update-ca-certificates.8
+}
+
+pkg_postinst_${PN}_class-target () {
+    SYSROOT="$D" $D${sbindir}/update-ca-certificates
+}
+
+CONFFILES_${PN} += "${sysconfdir}/ca-certificates.conf"
+
+# Rather than make a postinst script that works for both target and nativesdk,
+# we just run update-ca-certificate from do_install() for nativesdk.
+CONFFILES_${PN}_append_class-nativesdk = " ${sysconfdir}/ssl/certs/ca-certificates.crt"
+do_install_append_class-nativesdk () {
+    SYSROOT="${D}${SDKPATHNATIVE}" ${D}${sbindir}/update-ca-certificates
+}
+
+do_install_append_class-native () {
+    SYSROOT="${D}${base_prefix}" ${D}${sbindir}/update-ca-certificates
+}
+
+RDEPENDS_${PN} += "openssl"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/curl/curl_7.61.0.bb b/poky/meta/recipes-support/curl/curl_7.61.0.bb
index 2078379..56327a6 100644
--- a/poky/meta/recipes-support/curl/curl_7.61.0.bb
+++ b/poky/meta/recipes-support/curl/curl_7.61.0.bb
@@ -19,12 +19,14 @@
 CVE_PRODUCT = "curl libcurl"
 inherit autotools pkgconfig binconfig multilib_header
 
-PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} gnutls proxy threaded-resolver zlib"
-PACKAGECONFIG_class-native = "ipv6 proxy ssl threaded-resolver zlib"
-PACKAGECONFIG_class-nativesdk = "ipv6 proxy ssl threaded-resolver zlib"
+PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} gnutls libidn proxy threaded-resolver verbose zlib"
+PACKAGECONFIG_class-native = "ipv6 proxy ssl threaded-resolver verbose zlib"
+PACKAGECONFIG_class-nativesdk = "ipv6 proxy ssl threaded-resolver verbose zlib"
 
 # 'ares' and 'threaded-resolver' are mutually exclusive
 PACKAGECONFIG[ares] = "--enable-ares,--disable-ares,c-ares"
+PACKAGECONFIG[brotli] = "--with-brotli,--without-brotli,brotli"
+PACKAGECONFIG[builtinmanual] = "--enable-manual,--disable-manual"
 PACKAGECONFIG[dict] = "--enable-dict,--disable-dict,"
 PACKAGECONFIG[gnutls] = "--with-gnutls,--without-gnutls,gnutls"
 PACKAGECONFIG[gopher] = "--enable-gopher,--disable-gopher,"
@@ -35,6 +37,7 @@
 PACKAGECONFIG[ldaps] = "--enable-ldaps,--disable-ldaps,"
 PACKAGECONFIG[libidn] = "--with-libidn2,--without-libidn2,libidn2"
 PACKAGECONFIG[libssh2] = "--with-libssh2,--without-libssh2,libssh2"
+PACKAGECONFIG[mbedtls] = "--with-mbedtls=${STAGING_DIR_TARGET},--without-mbedtls,mbedtls"
 PACKAGECONFIG[nghttp2] = "--with-nghttp2,--without-nghttp2,nghttp2"
 PACKAGECONFIG[pop3] = "--enable-pop3,--disable-pop3,"
 PACKAGECONFIG[proxy] = "--enable-proxy,--disable-proxy,"
@@ -46,9 +49,12 @@
 PACKAGECONFIG[telnet] = "--enable-telnet,--disable-telnet,"
 PACKAGECONFIG[tftp] = "--enable-tftp,--disable-tftp,"
 PACKAGECONFIG[threaded-resolver] = "--enable-threaded-resolver,--disable-threaded-resolver"
+PACKAGECONFIG[verbose] = "--enable-verbose,--disable-verbose"
 PACKAGECONFIG[zlib] = "--with-zlib=${STAGING_LIBDIR}/../,--without-zlib,zlib"
 
 EXTRA_OECONF = " \
+    --disable-libcurl-option \
+    --disable-ntlm-wb \
     --enable-crypto-auth \
     --with-ca-bundle=${sysconfdir}/ssl/certs/ca-certificates.crt \
     --without-libmetalink \
@@ -71,4 +77,7 @@
 
 FILES_${PN} += "${datadir}/zsh"
 
+inherit multilib_script
+MULTILIB_SCRIPTS = "${PN}-dev:${bindir}/curl-config"
+
 BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/db/db/arm-thumb-mutex_db5.patch b/poky/meta/recipes-support/db/db/arm-thumb-mutex_db5.patch
deleted file mode 100644
index 6a8eada..0000000
--- a/poky/meta/recipes-support/db/db/arm-thumb-mutex_db5.patch
+++ /dev/null
@@ -1,50 +0,0 @@
-Original patch submitted by jbowler@nslu2-linux.org on 2005-11-17:
-
-db: fix thumb uclibc operation in 4.3.29
-  - uclibc thumb builds were using libpthread to implement mutexes, the
-  - uclibc version seems to be a stub (at least on thumb).  This commit
-  - fixes the ARM/gcc-assembly mutex implementation so that it has thumb
-  - support and the resultant db4 works (tested on LE Thumb uclibc)
-
-Upstream-Status: Inappropriate [embedded specific]
-
-Author: jbowler@nslu2-linux.org
-
-Index: db-6.0.30/src/dbinc/mutex_int.h
-===================================================================
---- db-6.0.30.orig/src/dbinc/mutex_int.h
-+++ db-6.0.30/src/dbinc/mutex_int.h
-@@ -474,6 +474,25 @@ typedef unsigned char tsl_t;
- 
- #ifdef LOAD_ACTUAL_MUTEX_CODE
- /* gcc/arm: 0 is clear, 1 is set. */
-+#if defined __thumb__
-+#define	MUTEX_SET(tsl) ({						\
-+	int __r, __p;							\
-+	__asm__ volatile(						\
-+		".align 2\n\t"                                          \
-+		"bx     pc\n\t"                                         \
-+		"nop\n\t"                                               \
-+		".arm\n\t"                                              \
-+		"swpb   %0, %2, [%3]\n\t"                               \
-+		"eor    %0, %0, #1\n\t"                                 \
-+		"orr    %1, pc, #1\n\t"                                 \
-+		"bx     %1\n\t"                                         \
-+		".force_thumb"                                          \
-+	    : "=&r" (__r), "=r" (__p)                                   \
-+	    : "r" (1), "r" (tsl)                                        \
-+	    );                                                          \
-+	__r & 1;							\
-+})
-+#else
- #define	MUTEX_SET(tsl) ({						\
- 	int __r;							\
- 	__asm__ volatile(						\
-@@ -484,6 +503,7 @@ typedef unsigned char tsl_t;
- 	    );								\
- 	__r & 1;							\
- })
-+#endif
- 
- #define	MUTEX_UNSET(tsl)	(*(volatile tsl_t *)(tsl) = 0)
- #define	MUTEX_INIT(tsl)         (MUTEX_UNSET(tsl), 0)
diff --git a/poky/meta/recipes-support/db/db_5.3.28.bb b/poky/meta/recipes-support/db/db_5.3.28.bb
index 093ee44..b7ed2c7 100644
--- a/poky/meta/recipes-support/db/db_5.3.28.bb
+++ b/poky/meta/recipes-support/db/db_5.3.28.bb
@@ -21,8 +21,7 @@
 PE = "1"
 
 SRC_URI = "http://download.oracle.com/berkeley-db/db-${PV}.tar.gz"
-SRC_URI += "file://arm-thumb-mutex_db5.patch \
-            file://fix-parallel-build.patch \
+SRC_URI += "file://fix-parallel-build.patch \
             file://0001-atomic-Rename-local-__atomic_compare_exchange-to-avo.patch \
             file://0001-configure-Add-explicit-tag-options-to-libtool-invoca.patch \
             file://sequence-type.patch \
@@ -47,7 +46,6 @@
 PACKAGES =+ "${PN}-cxx"
 FILES_${PN}-cxx = "${libdir}/*cxx*so"
 
-
 # The dev package has the .so link (as in db3) and the .a's -
 # it is therefore incompatible (cannot be installed at the
 # same time) as the db3 package
@@ -59,18 +57,8 @@
 # All the --disable-* options replace --enable-smallbuild, which breaks a bunch of stuff (eg. postfix)
 DB5_CONFIG ?= "--enable-o_direct --disable-cryptography --disable-queue --disable-replication --disable-verify --disable-compat185 --disable-sql"
 
-EXTRA_OECONF = "${DB5_CONFIG} --enable-shared --enable-cxx --with-sysroot"
+EXTRA_OECONF = "${DB5_CONFIG} --enable-shared --enable-cxx --with-sysroot STRIP=true"
 
-# Override the MUTEX setting here, the POSIX library is
-# the default - "POSIX/pthreads/library".
-# Don't ignore the nice SWP instruction on the ARM:
-# These enable the ARM assembler mutex code, this won't
-# work with thumb compilation...
-ARM_MUTEX = "--with-mutex=ARM/gcc-assembly"
-MUTEX = ""
-MUTEX_arm = "${ARM_MUTEX}"
-MUTEX_armeb = "${ARM_MUTEX}"
-EXTRA_OECONF += "${MUTEX} STRIP=true"
 EXTRA_OEMAKE += "LIBTOOL='./${HOST_SYS}-libtool'"
 
 EXTRA_AUTORECONF += "--exclude=autoheader  -I ${S}/dist/aclocal -I${S}/dist/aclocal_java"
diff --git a/poky/meta/recipes-support/debianutils/debianutils_4.8.4.bb b/poky/meta/recipes-support/debianutils/debianutils_4.8.4.bb
deleted file mode 100644
index 300e6f1..0000000
--- a/poky/meta/recipes-support/debianutils/debianutils_4.8.4.bb
+++ /dev/null
@@ -1,57 +0,0 @@
-SUMMARY = "Miscellaneous utilities specific to Debian"
-SECTION = "base"
-LICENSE = "GPLv2 & SMAIL_GPL"
-LIC_FILES_CHKSUM = "file://debian/copyright;md5=f01a5203d50512fc4830b4332b696a9f"
-
-SRC_URI = "http://snapshot.debian.org/archive/debian/20180129T164727Z/pool/main/d/${BPN}/${BPN}_${PV}.tar.xz"
-# the package is taken from snapshots.debian.org; that source is static and goes stale
-# so we check the latest upstream from a directory that does get updated
-UPSTREAM_CHECK_URI = "${DEBIAN_MIRROR}/main/d/${BPN}/"
-
-SRC_URI[md5sum] = "a6dcd496b4f79b3c452c3a74c2d3f89c"
-SRC_URI[sha256sum] = "c061ab99aea61f892043b7624b021ab5b193e9c6bbfd474da0fbcdd506be1eb2"
-
-S = "${WORKDIR}/${BPN}"
-
-inherit autotools update-alternatives
-
-do_configure_prepend() {
-    sed -i -e 's:tempfile.1 which.1:which.1:g' ${S}/Makefile.am
-}
-
-do_install_append() {
-    if [ "${base_bindir}" != "${bindir}" ]; then
-        # Debian places some utils into ${base_bindir} as does busybox
-        install -d ${D}${base_bindir}
-        for app in run-parts tempfile; do
-            mv ${D}${bindir}/$app ${D}${base_bindir}/$app
-        done
-    fi
-}
-
-# Note that we package the update-alternatives name.
-#
-PACKAGES =+ "${PN}-run-parts"
-FILES_${PN}-run-parts = "${base_bindir}/run-parts.debianutils"
-
-RDEPENDS_${PN} += "${PN}-run-parts"
-RDEPENDS_${PN}_class-native = ""
-
-ALTERNATIVE_PRIORITY="30"
-ALTERNATIVE_${PN} = "add-shell installkernel remove-shell savelog tempfile which"
-
-ALTERNATIVE_PRIORITY_${PN}-run-parts = "60"
-ALTERNATIVE_${PN}-run-parts = "run-parts"
-
-ALTERNATIVE_${PN}-doc = "which.1"
-ALTERNATIVE_LINK_NAME[which.1] = "${mandir}/man1/which.1"
-
-ALTERNATIVE_LINK_NAME[add-shell]="${sbindir}/add-shell"
-ALTERNATIVE_LINK_NAME[installkernel]="${sbindir}/installkernel"
-ALTERNATIVE_LINK_NAME[remove-shell]="${sbindir}/remove-shell"
-ALTERNATIVE_LINK_NAME[run-parts]="${base_bindir}/run-parts"
-ALTERNATIVE_LINK_NAME[savelog]="${bindir}/savelog"
-ALTERNATIVE_LINK_NAME[tempfile]="${base_bindir}/tempfile"
-ALTERNATIVE_LINK_NAME[which]="${bindir}/which"
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-support/debianutils/debianutils_4.8.6.bb b/poky/meta/recipes-support/debianutils/debianutils_4.8.6.bb
new file mode 100644
index 0000000..c37e842
--- /dev/null
+++ b/poky/meta/recipes-support/debianutils/debianutils_4.8.6.bb
@@ -0,0 +1,55 @@
+SUMMARY = "Miscellaneous utilities specific to Debian"
+SECTION = "base"
+LICENSE = "GPLv2 & SMAIL_GPL"
+LIC_FILES_CHKSUM = "file://debian/copyright;md5=f01a5203d50512fc4830b4332b696a9f"
+
+SRC_URI = "http://snapshot.debian.org/archive/debian/20180626T205238Z/pool/main/d/${BPN}/${BPN}_${PV}.tar.xz"
+# the package is taken from snapshots.debian.org; that source is static and goes stale
+# so we check the latest upstream from a directory that does get updated
+UPSTREAM_CHECK_URI = "${DEBIAN_MIRROR}/main/d/${BPN}/"
+
+SRC_URI[md5sum] = "f0f1fa39383815fb7950dcee52be4361"
+SRC_URI[sha256sum] = "db09047144dadf6a35d0f28977fbef83b0dd60ca32e6c8512cce2444a6423f73"
+
+inherit autotools update-alternatives
+
+do_configure_prepend() {
+    sed -i -e 's:tempfile.1 which.1:which.1:g' ${S}/Makefile.am
+}
+
+do_install_append() {
+    if [ "${base_bindir}" != "${bindir}" ]; then
+        # Debian places some utils into ${base_bindir} as does busybox
+        install -d ${D}${base_bindir}
+        for app in run-parts tempfile; do
+            mv ${D}${bindir}/$app ${D}${base_bindir}/$app
+        done
+    fi
+}
+
+# Note that we package the update-alternatives name.
+#
+PACKAGES =+ "${PN}-run-parts"
+FILES_${PN}-run-parts = "${base_bindir}/run-parts.debianutils"
+
+RDEPENDS_${PN} += "${PN}-run-parts"
+RDEPENDS_${PN}_class-native = ""
+
+ALTERNATIVE_PRIORITY="30"
+ALTERNATIVE_${PN} = "add-shell installkernel remove-shell savelog tempfile which"
+
+ALTERNATIVE_PRIORITY_${PN}-run-parts = "60"
+ALTERNATIVE_${PN}-run-parts = "run-parts"
+
+ALTERNATIVE_${PN}-doc = "which.1"
+ALTERNATIVE_LINK_NAME[which.1] = "${mandir}/man1/which.1"
+
+ALTERNATIVE_LINK_NAME[add-shell]="${sbindir}/add-shell"
+ALTERNATIVE_LINK_NAME[installkernel]="${sbindir}/installkernel"
+ALTERNATIVE_LINK_NAME[remove-shell]="${sbindir}/remove-shell"
+ALTERNATIVE_LINK_NAME[run-parts]="${base_bindir}/run-parts"
+ALTERNATIVE_LINK_NAME[savelog]="${bindir}/savelog"
+ALTERNATIVE_LINK_NAME[tempfile]="${base_bindir}/tempfile"
+ALTERNATIVE_LINK_NAME[which]="${bindir}/which"
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-support/dos2unix/dos2unix_7.4.0.bb b/poky/meta/recipes-support/dos2unix/dos2unix_7.4.0.bb
new file mode 100644
index 0000000..9a71270
--- /dev/null
+++ b/poky/meta/recipes-support/dos2unix/dos2unix_7.4.0.bb
@@ -0,0 +1,35 @@
+SUMMARY = "Convert text file line endings between CRLF and LF"
+DESCRIPTION = "The Dos2unix package includes utilities dos2unix and \
+unix2dos to convert plain text files in DOS or Mac format to Unix \
+format and vice versa."
+HOMEPAGE = "http://waterlan.home.xs4all.nl/dos2unix.html"
+SECTION = "support"
+
+LICENSE = "BSD-2-Clause"
+LIC_FILES_CHKSUM = "file://COPYING.txt;md5=1b78fca784db24f4a40e30b300787f3f"
+
+SRC_URI = "git://git.code.sf.net/p/dos2unix/dos2unix"
+UPSTREAM_CHECK_GITTAGREGEX = "dos2unix-(?P<pver>(\d+(\.\d+)+))"
+
+# Release 7.4.0
+SRCREV = "1182533bde3c1fe65be2ead465e87671faa2c027"
+
+S = "${WORKDIR}/git/dos2unix"
+
+inherit gettext perlnative
+
+# The dos2unix NLS relies on po4a-native, while po4a recipe is
+# provided by meta-perl layer, so make it optional here, you
+# need have meta-perl in bblayers.conf before enabling nls in
+# PACKAGECONFIG.
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[nls] = "ENABLE_NLS=1,ENABLE_NLS=,po4a-native"
+
+EXTRA_OEMAKE = "${PACKAGECONFIG_CONFARGS} LDFLAGS_USER='${LDFLAGS}'"
+EXTRA_OEMAKE_class-native = "ENABLE_NLS="
+
+do_install () {
+	oe_runmake DESTDIR="${D}${base_prefix}" install
+}
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/fribidi/fribidi/meson.patch b/poky/meta/recipes-support/fribidi/fribidi/meson.patch
new file mode 100644
index 0000000..8b3c4a9
--- /dev/null
+++ b/poky/meta/recipes-support/fribidi/fribidi/meson.patch
@@ -0,0 +1,44 @@
+Upstream-Status: Backport
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+From f5feb6c599adb52f24656f8589868039b0d14272 Mon Sep 17 00:00:00 2001
+From: Heiko Becker <heirecka@exherbo.org>
+Date: Fri, 7 Sep 2018 20:57:11 +0200
+Subject: [PATCH] Build generator executables natively
+
+They are run during the build and not installed in the end. Without
+this one gets the following error from meson: "ERROR: Can not use
+target gen-unicode-version as a generator because it is cross-built
+and no exe wrapper is defined. You might want to set it to native
+instead."
+
+Closes #87.
+
+---
+ gen.tab/meson.build | 6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/gen.tab/meson.build b/gen.tab/meson.build
+index 6006d98..8c21e98 100644
+--- a/gen.tab/meson.build
++++ b/gen.tab/meson.build
+@@ -33,7 +33,8 @@ gen_unicode_version = executable('gen-unicode-version',
+   'gen-unicode-version.c',
+   include_directories: incs,
+   c_args: native_args,
+-  install: false)
++  install: false,
++  native: true)
+ 
+ fribidi_unicode_version_h = custom_target('fribidi-unicode-version.h',
+   input: files('unidata/ReadMe.txt', 'unidata/BidiMirroring.txt'),
+@@ -67,7 +68,8 @@ foreach tab : tabs
+     gen_prog_src, 'packtab.c',
+     include_directories: incs,
+     c_args: native_args,
+-    install: false)
++    install: false,
++    native: true)
+ 
+   tab_inc_file = custom_target(gen_prog_name,
+     input: gen_prog_inputs,
diff --git a/poky/meta/recipes-support/fribidi/fribidi_1.0.5.bb b/poky/meta/recipes-support/fribidi/fribidi_1.0.5.bb
new file mode 100644
index 0000000..63b2da6
--- /dev/null
+++ b/poky/meta/recipes-support/fribidi/fribidi_1.0.5.bb
@@ -0,0 +1,17 @@
+SUMMARY = "Free Implementation of the Unicode Bidirectional Algorithm"
+SECTION = "libs"
+LICENSE = "LGPLv2.1+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=a916467b91076e631dd8edb7424769c7"
+
+SRC_URI = "https://github.com/${BPN}/${BPN}/releases/download/v${PV}/${BP}.tar.bz2 \
+           file://meson.patch"
+SRC_URI[md5sum] = "0f97f65038545340316ec0f4bd53df0b"
+SRC_URI[sha256sum] = "6a64f2a687f5c4f203a46fa659f43dd43d1f8b845df8d723107e8a7e6158e4ce"
+
+UPSTREAM_CHECK_URI = "https://github.com/${BPN}/${BPN}/releases"
+
+inherit meson lib_package pkgconfig
+
+CVE_PRODUCT = "gnu_fribidi"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/gdbm/files/ptest.patch b/poky/meta/recipes-support/gdbm/files/ptest.patch
index b9461be..1e67dbd 100644
--- a/poky/meta/recipes-support/gdbm/files/ptest.patch
+++ b/poky/meta/recipes-support/gdbm/files/ptest.patch
@@ -1,4 +1,4 @@
-From 4e4b70a4a3dcf1fdbee9e68bed3b62f42b197a3a Mon Sep 17 00:00:00 2001
+From 41448708e163c8ec1f980464e7dd6741db427c8a Mon Sep 17 00:00:00 2001
 From: Josep Puigdemont <josep.puigdemont@enea.com>
 Date: Sun, 4 May 2014 16:02:07 +0200
 Subject: [PATCH] Add install-ptest rules.
@@ -9,14 +9,14 @@
 
 ---
  Makefile.am       |  5 +++++
- tests/Makefile.am | 12 +++++++++++-
- 2 files changed, 16 insertions(+), 1 deletion(-)
+ tests/Makefile.am | 11 +++++++++++
+ 2 files changed, 16 insertions(+)
 
 diff --git a/Makefile.am b/Makefile.am
-index 4cdc734..24b99f0 100644
+index ecc03df..9fbbda5 100644
 --- a/Makefile.am
 +++ b/Makefile.am
-@@ -45,3 +45,8 @@ ChangeLog:
+@@ -55,3 +55,8 @@ ChangeLog:
                  awk -f $(top_srcdir)/git2chg.awk                            \
                      -v append=$(top_srcdir)/$(prev_change_log) > ChangeLog; \
          fi
@@ -26,14 +26,13 @@
 +		$(MAKE) -C $$subdir DESTDIR=$(DESTDIR)/$$subdir $@; \
 +	done
 diff --git a/tests/Makefile.am b/tests/Makefile.am
-index 3dbb580..22ffc44 100644
+index dbe17dd..06f537f 100644
 --- a/tests/Makefile.am
 +++ b/tests/Makefile.am
-@@ -130,4 +130,14 @@ dtfetch_LDADD = ../src/libgdbm.la ../compat/libgdbm_compat.la
- dtdel_LDADD = ../src/libgdbm.la ../compat/libgdbm_compat.la
- d_creat_ce_LDADD = ../src/libgdbm.la ../compat/libgdbm_compat.la
+@@ -169,3 +169,14 @@ EXTRA_DIST += \
+   gdbmtool/base.exp\
+   config/default.exp
  
--
 +buildtests: $(check_PROGRAMS) $(TESTSUITE)
 +
 +install-ptest: $(check_PROGRAMS) $(TESTSUITE)
@@ -45,6 +44,3 @@
 +			$(INSTALL_PROGRAM) $$file $(DESTDIR) ; \
 +		fi \
 +	done
--- 
-2.11.0
-
diff --git a/poky/meta/recipes-support/gdbm/gdbm_1.14.1.bb b/poky/meta/recipes-support/gdbm/gdbm_1.14.1.bb
deleted file mode 100644
index 54e5696..0000000
--- a/poky/meta/recipes-support/gdbm/gdbm_1.14.1.bb
+++ /dev/null
@@ -1,43 +0,0 @@
-SUMMARY = "Key/value database library with extensible hashing"
-HOMEPAGE = "http://www.gnu.org/software/gdbm/"
-SECTION = "libs"
-LICENSE = "GPLv3"
-LIC_FILES_CHKSUM = "file://COPYING;md5=241da1b9fe42e642cbb2c24d5e0c4d24"
-
-
-SRC_URI = "${GNU_MIRROR}/gdbm/gdbm-${PV}.tar.gz \
-           file://run-ptest \
-           file://ptest.patch \
-          "
-
-SRC_URI[md5sum] = "c2ddcb3897efa0f57484af2bd4f4f848"
-SRC_URI[sha256sum] = "cdceff00ffe014495bed3aed71c7910aa88bf29379f795abc0f46d4ee5f8bc5f"
-
-inherit autotools gettext texinfo lib_package ptest
-
-# Needed for dbm python module
-EXTRA_OECONF = "-enable-libgdbm-compat"
-
-# Stop presence of dbm/nbdm on the host contaminating builds
-CACHED_CONFIGUREVARS += "ac_cv_lib_ndbm_main=no ac_cv_lib_dbm_main=no"
-
-BBCLASSEXTEND = "native nativesdk"
-
-do_install_append () {
-    # Create a symlink to ndbm.h and gdbm.h in include/gdbm to let other packages to find
-    # these headers
-    install -d ${D}${includedir}/gdbm
-    ln -sf ../ndbm.h ${D}/${includedir}/gdbm/ndbm.h
-    ln -sf ../gdbm.h ${D}/${includedir}/gdbm/gdbm.h
-}
-
-RDEPENDS_${PN}-ptest += "diffutils"
-
-do_compile_ptest() {
-    oe_runmake -C tests buildtests
-}
-
-PACKAGES =+ "${PN}-compat \
-            "
-FILES_${PN}-compat = "${libdir}/libgdbm_compat${SOLIBS} \
-                     "
diff --git a/poky/meta/recipes-support/gdbm/gdbm_1.18.bb b/poky/meta/recipes-support/gdbm/gdbm_1.18.bb
new file mode 100644
index 0000000..aad4300
--- /dev/null
+++ b/poky/meta/recipes-support/gdbm/gdbm_1.18.bb
@@ -0,0 +1,43 @@
+SUMMARY = "Key/value database library with extensible hashing"
+HOMEPAGE = "http://www.gnu.org/software/gdbm/"
+SECTION = "libs"
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=241da1b9fe42e642cbb2c24d5e0c4d24"
+
+
+SRC_URI = "${GNU_MIRROR}/gdbm/gdbm-${PV}.tar.gz \
+           file://run-ptest \
+           file://ptest.patch \
+          "
+
+SRC_URI[md5sum] = "e316f8e4a3e7e4f23955be65d54fec48"
+SRC_URI[sha256sum] = "b8822cb4769e2d759c828c06f196614936c88c141c3132b18252fe25c2b635ce"
+
+inherit autotools gettext texinfo lib_package ptest
+
+# Needed for dbm python module
+EXTRA_OECONF = "-enable-libgdbm-compat"
+
+# Stop presence of dbm/nbdm on the host contaminating builds
+CACHED_CONFIGUREVARS += "ac_cv_lib_ndbm_main=no ac_cv_lib_dbm_main=no"
+
+BBCLASSEXTEND = "native nativesdk"
+
+do_install_append () {
+    # Create a symlink to ndbm.h and gdbm.h in include/gdbm to let other packages to find
+    # these headers
+    install -d ${D}${includedir}/gdbm
+    ln -sf ../ndbm.h ${D}/${includedir}/gdbm/ndbm.h
+    ln -sf ../gdbm.h ${D}/${includedir}/gdbm/gdbm.h
+}
+
+RDEPENDS_${PN}-ptest += "diffutils ${PN}-bin"
+
+do_compile_ptest() {
+    oe_runmake -C tests buildtests
+}
+
+PACKAGES =+ "${PN}-compat \
+            "
+FILES_${PN}-compat = "${libdir}/libgdbm_compat${SOLIBS} \
+                     "
diff --git a/poky/meta/recipes-support/gmp/gmp.inc b/poky/meta/recipes-support/gmp/gmp.inc
index abac8cf..948b892 100644
--- a/poky/meta/recipes-support/gmp/gmp.inc
+++ b/poky/meta/recipes-support/gmp/gmp.inc
@@ -3,7 +3,7 @@
 HOMEPAGE = "http://gmplib.org/"
 SECTION = "devel"
 
-inherit autotools texinfo
+inherit autotools texinfo multilib_header
 
 PACKAGECONFIG ??= ""
 PACKAGECONFIG[readline] = "--with-readline=yes,--with-readline=no,readline"
diff --git a/poky/meta/recipes-support/gmp/gmp_6.1.2.bb b/poky/meta/recipes-support/gmp/gmp_6.1.2.bb
index b008710..c745dbb 100644
--- a/poky/meta/recipes-support/gmp/gmp_6.1.2.bb
+++ b/poky/meta/recipes-support/gmp/gmp_6.1.2.bb
@@ -25,6 +25,10 @@
 PACKAGES =+ "libgmpxx"
 FILES_libgmpxx = "${libdir}/libgmpxx${SOLIBS}"
 
+do_install_append() {
+	oe_multilib_header gmp.h
+}
+
 do_install_prepend_class-target() {
         sed -i \
         -e "s|--sysroot=${STAGING_DIR_HOST}||g" \
diff --git a/poky/meta/recipes-support/gnupg/gnupg/0001-configure.ac-use-a-custom-value-for-the-location-of-.patch b/poky/meta/recipes-support/gnupg/gnupg/0001-configure.ac-use-a-custom-value-for-the-location-of-.patch
index 3e3a64d..5f1dd30 100644
--- a/poky/meta/recipes-support/gnupg/gnupg/0001-configure.ac-use-a-custom-value-for-the-location-of-.patch
+++ b/poky/meta/recipes-support/gnupg/gnupg/0001-configure.ac-use-a-custom-value-for-the-location-of-.patch
@@ -1,4 +1,4 @@
-From 0b97148c3aad0993a9aeb088596fa63a2fec5328 Mon Sep 17 00:00:00 2001
+From 7eb7efb9ce89c66e14c194773c4dcf6478a6ca4d Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Mon, 22 Jan 2018 18:00:21 +0200
 Subject: [PATCH] configure.ac: use a custom value for the location of
@@ -8,15 +8,16 @@
 
 Upstream-Status: Inappropriate [oe-core specific, and only for -native]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
 ---
  configure.ac | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/configure.ac b/configure.ac
-index 382ef1d..0570d7c 100644
+index 59a2e60..12d390b 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -1818,7 +1818,7 @@ AC_DEFINE_UNQUOTED(GPGCONF_DISP_NAME, "GPGConf",
+@@ -1841,7 +1841,7 @@ AC_DEFINE_UNQUOTED(GPGCONF_DISP_NAME, "GPGConf",
  
  AC_DEFINE_UNQUOTED(GPGTAR_NAME, "gpgtar", [The name of the gpgtar tool])
  
@@ -25,6 +26,3 @@
                     [The name of the agent socket])
  AC_DEFINE_UNQUOTED(GPG_AGENT_EXTRA_SOCK_NAME, "S.gpg-agent.extra",
                     [The name of the agent socket for remote access])
--- 
-2.15.1
-
diff --git a/poky/meta/recipes-support/gnupg/gnupg/CVE-2018-12020.patch b/poky/meta/recipes-support/gnupg/gnupg/CVE-2018-12020.patch
deleted file mode 100644
index 14698db..0000000
--- a/poky/meta/recipes-support/gnupg/gnupg/CVE-2018-12020.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From 13f135c7a252cc46cff96e75968d92b6dc8dce1b Mon Sep 17 00:00:00 2001
-From: Werner Koch <wk@gnupg.org>
-Date: Fri, 8 Jun 2018 10:45:21 +0200
-Subject: [PATCH] gpg: Sanitize diagnostic with the original file name.
-
-* g10/mainproc.c (proc_plaintext): Sanitize verbose output.
---
-
-This fixes a forgotten sanitation of user supplied data in a verbose
-mode diagnostic.  The mention CVE is about using this to inject
-status-fd lines into the stderr output.  Other harm good as well be
-done.  Note that GPGME based applications are not affected because
-GPGME does not fold status output into stderr.
-
-CVE-id: CVE-2018-12020
-GnuPG-bug-id: 4012
-
-Upstream-Status: Backport [https://git.gnupg.org/cgi-bin/gitweb.cgi?p=gnupg.git;a=commit;h=13f135c7a252cc46cff96e75968d92b6dc8dce1b]
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- g10/mainproc.c | 9 ++++++++-
- 1 file changed, 8 insertions(+), 1 deletion(-)
-
-diff --git a/g10/mainproc.c b/g10/mainproc.c
-index d2ceec2fd..a9da08f74 100644
---- a/g10/mainproc.c
-+++ b/g10/mainproc.c
-@@ -851,7 +851,14 @@ proc_plaintext( CTX c, PACKET *pkt )
-   if (pt->namelen == 8 && !memcmp( pt->name, "_CONSOLE", 8))
-     log_info (_("Note: sender requested \"for-your-eyes-only\"\n"));
-   else if (opt.verbose)
--    log_info (_("original file name='%.*s'\n"), pt->namelen, pt->name);
-+    {
-+      /* We don't use print_utf8_buffer because that would require a
-+       * string change which we don't want in 2.2.  It is also not
-+       * clear whether the filename is always utf-8 encoded.  */
-+      char *tmp = make_printable_string (pt->name, pt->namelen, 0);
-+      log_info (_("original file name='%.*s'\n"), (int)strlen (tmp), tmp);
-+      xfree (tmp);
-+    }
- 
-   free_md_filter_context (&c->mfx);
-   if (gcry_md_open (&c->mfx.md, 0, 0))
--- 
-2.13.3
-
diff --git a/poky/meta/recipes-support/gnupg/gnupg/CVE-2018-9234.patch b/poky/meta/recipes-support/gnupg/gnupg/CVE-2018-9234.patch
deleted file mode 100644
index d4ba1d8..0000000
--- a/poky/meta/recipes-support/gnupg/gnupg/CVE-2018-9234.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From ce055269c80f6e7c1393c0deec7bc5f0d37895ea Mon Sep 17 00:00:00 2001
-From: Sinan Kaya <okaya@kernel.org>
-Date: Sun, 23 Sep 2018 04:05:47 +0000
-Subject: [PATCH] g10: Fix filtering by PK->REQ_USAGE
-
-Upstream-Status: Backport [https://dev.gnupg.org/rGa17d2d1f690ebe5d005b4589a5fe378b6487c657]
-CVE: CVE-2018-9234
-Signed-off-by: Sinan Kaya <okaya@kernel.org>
----
- g10/getkey.c | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/g10/getkey.c b/g10/getkey.c
-index e31e023..ca2500c 100644
---- a/g10/getkey.c
-+++ b/g10/getkey.c
-@@ -1810,6 +1810,8 @@ get_pubkey_byfprint (ctrl_t ctrl, PKT_public_key *pk, kbnode_t *r_keyblock,
-       ctx.items[0].mode = fprint_len == 16 ? KEYDB_SEARCH_MODE_FPR16
- 	: KEYDB_SEARCH_MODE_FPR20;
-       memcpy (ctx.items[0].u.fpr, fprint, fprint_len);
-+      if (pk)
-+        ctx.req_usage = pk->req_usage;
-       rc = lookup (ctrl, &ctx, 0, &kb, &found_key);
-       if (!rc && pk)
- 	pk_from_block (pk, kb, found_key);
--- 
-2.19.0
-
diff --git a/poky/meta/recipes-support/gnupg/gnupg_2.2.4.bb b/poky/meta/recipes-support/gnupg/gnupg_2.2.4.bb
deleted file mode 100644
index 5a3688a..0000000
--- a/poky/meta/recipes-support/gnupg/gnupg_2.2.4.bb
+++ /dev/null
@@ -1,57 +0,0 @@
-SUMMARY = "GNU Privacy Guard - encryption and signing tools (2.x)"
-HOMEPAGE = "http://www.gnupg.org/"
-LICENSE = "GPLv3 & LGPLv3"
-LIC_FILES_CHKSUM = "file://COPYING;md5=189af8afca6d6075ba6c9e0aa8077626 \
-                    file://COPYING.LGPL3;md5=a2b6bf2cb38ee52619e60f30a1fc7257"
-
-DEPENDS = "npth libassuan libksba zlib bzip2 readline libgcrypt"
-
-inherit autotools gettext texinfo pkgconfig
-
-UPSTREAM_CHECK_URI = "https://gnupg.org/download/index.html"
-SRC_URI = "${GNUPG_MIRROR}/${BPN}/${BPN}-${PV}.tar.bz2 \
-           file://0001-Use-pkg-config-to-find-pth-instead-of-pth-config.patch \
-           file://0002-use-pkgconfig-instead-of-npth-config.patch \
-           file://0003-dirmngr-uses-libgpg-error.patch \
-           file://0004-autogen.sh-fix-find-version-for-beta-checking.patch \
-           file://CVE-2018-12020.patch \
-           file://CVE-2018-9234.patch \
-          "
-SRC_URI_append_class-native = " file://0001-configure.ac-use-a-custom-value-for-the-location-of-.patch \
-                                file://relocate.patch"
-
-
-SRC_URI[md5sum] = "709e5af5bba84d251c520222e720972f"
-SRC_URI[sha256sum] = "401a3e64780fdfa6d7670de0880aa5c9d589b3db7a7098979d7606cec546f2ec"
-
-EXTRA_OECONF = "--disable-ldap \
-		--disable-ccid-driver \
-		--with-zlib=${STAGING_LIBDIR}/.. \
-		--with-bzip2=${STAGING_LIBDIR}/.. \
-		--with-readline=${STAGING_LIBDIR}/.. \
-		--enable-gpg-is-gpg2 \
-               "
-RRECOMMENDS_${PN} = "pinentry"
-
-do_configure_prepend () {
-	# Else these could be used in prefernce to those in aclocal-copy
-	rm -f ${S}/m4/gpg-error.m4
-	rm -f ${S}/m4/libassuan.m4
-	rm -f ${S}/m4/ksba.m4
-	rm -f ${S}/m4/libgcrypt.m4
-}
-
-do_install_append() {
-	ln -sf gpg2 ${D}${bindir}/gpg
-	ln -sf gpgv2 ${D}${bindir}/gpgv
-}
-
-do_install_append_class-native() {
-	create_wrapper ${D}${bindir}/gpg2 GNUPG_BINDIR=${STAGING_BINDIR_NATIVE}
-}
-
-PACKAGECONFIG ??= "gnutls"
-PACKAGECONFIG[gnutls] = "--enable-gnutls, --disable-gnutls, gnutls"
-PACKAGECONFIG[sqlite3] = "--enable-sqlite, --disable-sqlite, sqlite3"
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-support/gnupg/gnupg_2.2.9.bb b/poky/meta/recipes-support/gnupg/gnupg_2.2.9.bb
new file mode 100644
index 0000000..b7d23b8
--- /dev/null
+++ b/poky/meta/recipes-support/gnupg/gnupg_2.2.9.bb
@@ -0,0 +1,55 @@
+SUMMARY = "GNU Privacy Guard - encryption and signing tools (2.x)"
+HOMEPAGE = "http://www.gnupg.org/"
+LICENSE = "GPLv3 & LGPLv3"
+LIC_FILES_CHKSUM = "file://COPYING;md5=189af8afca6d6075ba6c9e0aa8077626 \
+                    file://COPYING.LGPL3;md5=a2b6bf2cb38ee52619e60f30a1fc7257"
+
+DEPENDS = "npth libassuan libksba zlib bzip2 readline libgcrypt"
+
+inherit autotools gettext texinfo pkgconfig
+
+UPSTREAM_CHECK_URI = "https://gnupg.org/download/index.html"
+SRC_URI = "${GNUPG_MIRROR}/${BPN}/${BPN}-${PV}.tar.bz2 \
+           file://0001-Use-pkg-config-to-find-pth-instead-of-pth-config.patch \
+           file://0002-use-pkgconfig-instead-of-npth-config.patch \
+           file://0003-dirmngr-uses-libgpg-error.patch \
+           file://0004-autogen.sh-fix-find-version-for-beta-checking.patch \
+          "
+SRC_URI_append_class-native = " file://0001-configure.ac-use-a-custom-value-for-the-location-of-.patch \
+                                file://relocate.patch"
+
+
+SRC_URI[md5sum] = "52c895a81f514a65e08923736c38654a"
+SRC_URI[sha256sum] = "6278eaabffa1ebc9fa2ceb3dc53eea9a1505ab02a668a86dd6fec06951af2164"
+
+EXTRA_OECONF = "--disable-ldap \
+		--disable-ccid-driver \
+		--with-zlib=${STAGING_LIBDIR}/.. \
+		--with-bzip2=${STAGING_LIBDIR}/.. \
+		--with-readline=${STAGING_LIBDIR}/.. \
+		--enable-gpg-is-gpg2 \
+               "
+RRECOMMENDS_${PN} = "pinentry"
+
+do_configure_prepend () {
+	# Else these could be used in prefernce to those in aclocal-copy
+	rm -f ${S}/m4/gpg-error.m4
+	rm -f ${S}/m4/libassuan.m4
+	rm -f ${S}/m4/ksba.m4
+	rm -f ${S}/m4/libgcrypt.m4
+}
+
+do_install_append() {
+	ln -sf gpg2 ${D}${bindir}/gpg
+	ln -sf gpgv2 ${D}${bindir}/gpgv
+}
+
+do_install_append_class-native() {
+	create_wrapper ${D}${bindir}/gpg2 GNUPG_BINDIR=${STAGING_BINDIR_NATIVE}
+}
+
+PACKAGECONFIG ??= "gnutls"
+PACKAGECONFIG[gnutls] = "--enable-gnutls, --disable-gnutls, gnutls"
+PACKAGECONFIG[sqlite3] = "--enable-sqlite, --disable-sqlite, sqlite3"
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-support/gnutls/gnutls.inc b/poky/meta/recipes-support/gnutls/gnutls.inc
deleted file mode 100644
index 98ec8d9..0000000
--- a/poky/meta/recipes-support/gnutls/gnutls.inc
+++ /dev/null
@@ -1,59 +0,0 @@
-SUMMARY = "GNU Transport Layer Security Library"
-HOMEPAGE = "http://www.gnu.org/software/gnutls/"
-BUGTRACKER = "https://savannah.gnu.org/support/?group=gnutls"
-
-LICENSE = "GPLv3+ & LGPLv2.1+"
-LICENSE_${PN} = "LGPLv2.1+"
-LICENSE_${PN}-xx = "LGPLv2.1+"
-LICENSE_${PN}-bin = "GPLv3+"
-LICENSE_${PN}-openssl = "GPLv3+"
-
-LIC_FILES_CHKSUM = "file://LICENSE;md5=71391c8e0c1cfe68077e7fce3b586283 \
-                    file://doc/COPYING;md5=d32239bcb673463ab874e80d47fae504 \
-                    file://doc/COPYING.LESSER;md5=a6f89e2100d9b6cdffcea4f398e37343"
-
-DEPENDS = "nettle gmp virtual/libiconv libunistring"
-DEPENDS_append_libc-musl = " argp-standalone"
-
-SHRT_VER = "${@d.getVar('PV').split('.')[0]}.${@d.getVar('PV').split('.')[1]}"
-
-SRC_URI = "https://www.gnupg.org/ftp/gcrypt/gnutls/v${SHRT_VER}/gnutls-${PV}.tar.xz"
-
-inherit autotools texinfo binconfig pkgconfig gettext lib_package gtk-doc
-
-PACKAGECONFIG ??= "libidn"
-
-# You must also have CONFIG_SECCOMP enabled in the kernel for
-# seccomp to work.
-#
-PACKAGECONFIG[seccomp] = "ac_cv_libseccomp=yes,ac_cv_libseccomp=no,libseccomp"
-
-PACKAGECONFIG[libidn] = "--with-idn,--without-idn,libidn"
-PACKAGECONFIG[libtasn1] = "--with-included-libtasn1=no,--with-included-libtasn1,libtasn1"
-PACKAGECONFIG[p11-kit] = "--with-p11-kit,--without-p11-kit,p11-kit"
-PACKAGECONFIG[tpm] = "--with-tpm,--without-tpm,trousers"
-
-EXTRA_OECONF = " \
-    --enable-doc \
-    --disable-libdane \
-    --disable-guile \
-    --disable-rpath \
-    --enable-local-libopts \
-    --enable-openssl-compatibility \
-    --with-libpthread-prefix=${STAGING_DIR_HOST}${prefix} \
-    --without-libunistring-prefix \
-"
-
-LDFLAGS_append_libc-musl = " -largp"
-
-do_configure_prepend() {
-	for dir in . lib; do
-		rm -f ${dir}/aclocal.m4 ${dir}/m4/libtool.m4 ${dir}/m4/lt*.m4
-	done
-}
-
-PACKAGES =+ "${PN}-openssl ${PN}-xx"
-
-FILES_${PN}-dev += "${bindir}/gnutls-cli-debug"
-FILES_${PN}-openssl = "${libdir}/libgnutls-openssl.so.*"
-FILES_${PN}-xx = "${libdir}/libgnutlsxx.so.*"
diff --git a/poky/meta/recipes-support/gnutls/gnutls/0001-configure.ac-fix-sed-command.patch b/poky/meta/recipes-support/gnutls/gnutls/0001-configure.ac-fix-sed-command.patch
deleted file mode 100644
index b6e7bc9..0000000
--- a/poky/meta/recipes-support/gnutls/gnutls/0001-configure.ac-fix-sed-command.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From eaab55bb6d48643163eebbc9ca575a9ca2a8e03f Mon Sep 17 00:00:00 2001
-From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Tue, 21 Feb 2017 17:10:07 +0200
-Subject: [PATCH] configure.ac: fix sed command
-
-The "sed 's/.bak//g'" matchs "bitbake", which would cause strange errors
-when the S contains "bitbake", fix to "sed 's/\.bak$//'`"
-
-Upstream-Status: Pending
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
----
- configure.ac | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-Index: gnutls-3.5.16/configure.ac
-===================================================================
---- gnutls-3.5.16.orig/configure.ac
-+++ gnutls-3.5.16/configure.ac
-@@ -955,7 +955,7 @@ YEAR=`date +%Y`
- AC_SUBST([YEAR], $YEAR)
- 
- for i in ${srcdir}/src/*-args.c.bak ${srcdir}/src/*-args.h.bak; do
--	nam=$(basename $i|sed 's/.bak//g')
-+	nam=$(basename $i|sed 's/\.bak$//')
- 	if test "$create_libopts_links" = "yes";then
- 		rm -f "src/$nam.stamp"
- 		rm -f "src/$nam"
diff --git a/poky/meta/recipes-support/gnutls/gnutls_3.6.1.bb b/poky/meta/recipes-support/gnutls/gnutls_3.6.1.bb
deleted file mode 100644
index 7624a20..0000000
--- a/poky/meta/recipes-support/gnutls/gnutls_3.6.1.bb
+++ /dev/null
@@ -1,9 +0,0 @@
-require gnutls.inc
-
-SRC_URI += "file://0001-configure.ac-fix-sed-command.patch \
-            file://arm_eabi.patch \
-           "
-SRC_URI[md5sum] = "4b65ae3ffef59f3eeed51a6166ff12b3"
-SRC_URI[sha256sum] = "20b10d2c9994bc032824314714d0e84c0f19bdb3d715d8ed55beb7364a8ebaed"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/gnutls/gnutls_3.6.3.bb b/poky/meta/recipes-support/gnutls/gnutls_3.6.3.bb
new file mode 100644
index 0000000..441bbec
--- /dev/null
+++ b/poky/meta/recipes-support/gnutls/gnutls_3.6.3.bb
@@ -0,0 +1,64 @@
+SUMMARY = "GNU Transport Layer Security Library"
+HOMEPAGE = "http://www.gnu.org/software/gnutls/"
+BUGTRACKER = "https://savannah.gnu.org/support/?group=gnutls"
+
+LICENSE = "GPLv3+ & LGPLv2.1+"
+LICENSE_${PN} = "LGPLv2.1+"
+LICENSE_${PN}-xx = "LGPLv2.1+"
+LICENSE_${PN}-bin = "GPLv3+"
+LICENSE_${PN}-openssl = "GPLv3+"
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=71391c8e0c1cfe68077e7fce3b586283 \
+                    file://doc/COPYING;md5=d32239bcb673463ab874e80d47fae504 \
+                    file://doc/COPYING.LESSER;md5=a6f89e2100d9b6cdffcea4f398e37343"
+
+DEPENDS = "nettle gmp virtual/libiconv libunistring"
+DEPENDS_append_libc-musl = " argp-standalone"
+
+SHRT_VER = "${@d.getVar('PV').split('.')[0]}.${@d.getVar('PV').split('.')[1]}"
+
+SRC_URI = "https://www.gnupg.org/ftp/gcrypt/gnutls/v${SHRT_VER}/gnutls-${PV}.tar.xz \
+           file://arm_eabi.patch \
+"
+
+SRC_URI[md5sum] = "d3b1b05c2546b80832101a423a80faf8"
+SRC_URI[sha256sum] = "ed642b66a4ecf4851ab2d809cd1475c297b6201d8e8bd14b4d1c08b53ffca993"
+
+inherit autotools texinfo binconfig pkgconfig gettext lib_package gtk-doc
+
+PACKAGECONFIG ??= "libidn"
+
+# You must also have CONFIG_SECCOMP enabled in the kernel for
+# seccomp to work.
+PACKAGECONFIG[seccomp] = "ac_cv_libseccomp=yes,ac_cv_libseccomp=no,libseccomp"
+PACKAGECONFIG[libidn] = "--with-idn,--without-idn,libidn2"
+PACKAGECONFIG[libtasn1] = "--with-included-libtasn1=no,--with-included-libtasn1,libtasn1"
+PACKAGECONFIG[p11-kit] = "--with-p11-kit,--without-p11-kit,p11-kit"
+PACKAGECONFIG[tpm] = "--with-tpm,--without-tpm,trousers"
+
+EXTRA_OECONF = " \
+    --enable-doc \
+    --disable-libdane \
+    --disable-guile \
+    --disable-rpath \
+    --enable-local-libopts \
+    --enable-openssl-compatibility \
+    --with-libpthread-prefix=${STAGING_DIR_HOST}${prefix} \
+    --without-libunistring-prefix \
+"
+
+LDFLAGS_append_libc-musl = " -largp"
+
+do_configure_prepend() {
+	for dir in . lib; do
+		rm -f ${dir}/aclocal.m4 ${dir}/m4/libtool.m4 ${dir}/m4/lt*.m4
+	done
+}
+
+PACKAGES =+ "${PN}-openssl ${PN}-xx"
+
+FILES_${PN}-dev += "${bindir}/gnutls-cli-debug"
+FILES_${PN}-openssl = "${libdir}/libgnutls-openssl.so.*"
+FILES_${PN}-xx = "${libdir}/libgnutlsxx.so.*"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/gpgme/gpgme/0001-pkgconfig.patch b/poky/meta/recipes-support/gpgme/gpgme/0001-pkgconfig.patch
index f1997e1..ae9a46e 100644
--- a/poky/meta/recipes-support/gpgme/gpgme/0001-pkgconfig.patch
+++ b/poky/meta/recipes-support/gpgme/gpgme/0001-pkgconfig.patch
@@ -1,7 +1,7 @@
-From 265faf8fe0acaca2043a248a4df02b0868ffa6de Mon Sep 17 00:00:00 2001
+From c452ba58dd2f99d6e624421697417cc018f9a67a Mon Sep 17 00:00:00 2001
 From: Richard Purdie <richard.purdie@linuxfoundation.org>
-Date: Wed, 16 Aug 2017 02:00:08 -0400
-Subject: [PATCH 1/4] pkgconfig
+Date: Fri, 29 Jun 2018 14:35:41 +0800
+Subject: [PATCH 1/7] pkgconfig
 
 Update gpgme to use pkgconfig instead of -config files since its
 simpler and less error prone when cross compiling.
@@ -11,7 +11,7 @@
 
 Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
 
-Rebase to 1.9.0
+Rebase to 1.11.1
 
 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
@@ -25,10 +25,10 @@
  create mode 100644 src/gpgme.pc.in
 
 diff --git a/configure.ac b/configure.ac
-index 6ea4bcd..2a0d528 100644
+index 2a35404..7485cdf 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -887,6 +887,7 @@ AC_CONFIG_FILES(Makefile src/Makefile
+@@ -886,6 +886,7 @@ AC_CONFIG_FILES(Makefile src/Makefile
                  src/versioninfo.rc
                  src/gpgme.h)
  AC_CONFIG_FILES(src/gpgme-config, chmod +x src/gpgme-config)
@@ -37,7 +37,7 @@
  AC_CONFIG_FILES(lang/cpp/src/GpgmeppConfig-w32.cmake.in)
  AC_CONFIG_FILES(lang/cpp/src/GpgmeppConfig.cmake.in)
 diff --git a/src/Makefile.am b/src/Makefile.am
-index ce6f1d4..5f38fee 100644
+index 0a196e0..cecaf8f 100644
 --- a/src/Makefile.am
 +++ b/src/Makefile.am
 @@ -19,12 +19,14 @@
@@ -54,7 +54,7 @@
 +pkgconfigdir = $(libdir)/pkgconfig
 +pkgconfig_DATA = gpgme.pc gpgme-pthread.pc
  
- bin_PROGRAMS = gpgme-tool
+ bin_PROGRAMS = gpgme-tool gpgme-json
  
 diff --git a/src/gpgme-pthread.pc.in b/src/gpgme-pthread.pc.in
 new file mode 100644
@@ -299,5 +299,5 @@
 +Requires: libassuan gpg-error
 \ No newline at end of file
 -- 
-1.8.3.1
+2.7.4
 
diff --git a/poky/meta/recipes-support/gpgme/gpgme/0002-gpgme-lang-python-gpg-error-config-should-not-be-use.patch b/poky/meta/recipes-support/gpgme/gpgme/0002-gpgme-lang-python-gpg-error-config-should-not-be-use.patch
index d20271e..4f5ceda 100644
--- a/poky/meta/recipes-support/gpgme/gpgme/0002-gpgme-lang-python-gpg-error-config-should-not-be-use.patch
+++ b/poky/meta/recipes-support/gpgme/gpgme/0002-gpgme-lang-python-gpg-error-config-should-not-be-use.patch
@@ -1,7 +1,7 @@
-From 30f7a694cc4568ecb24f77c83a6123ed3f4075fa Mon Sep 17 00:00:00 2001
+From 45d828356efc140a1492befb1e6dc59a9f4e16b5 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Wed, 31 Jan 2018 10:44:19 +0800
-Subject: [PATCH] gpgme/lang/python: gpg-error-config should not be used
+Subject: [PATCH 2/7] gpgme/lang/python: gpg-error-config should not be used
 
 gpg-error-config was modified by OE to always return an error.
 So we want to find an alternative way to retrieve whatever it
@@ -19,7 +19,7 @@
  1 file changed, 1 insertion(+), 9 deletions(-)
 
 diff --git a/lang/python/setup.py.in b/lang/python/setup.py.in
-index f9dda20..9f5d61f 100755
+index 2595073..60b5257 100755
 --- a/lang/python/setup.py.in
 +++ b/lang/python/setup.py.in
 @@ -26,7 +26,6 @@ import shutil
@@ -30,7 +30,7 @@
  gpgme_config_flags = ["--thread=pthread"]
  gpgme_config = ["gpgme-config"] + gpgme_config_flags
  gpgme_h = ""
-@@ -174,14 +173,7 @@ class BuildExtFirstHack(build):
+@@ -157,14 +156,7 @@ class BuildExtFirstHack(build):
  
      def _generate_errors_i(self):
  
@@ -47,5 +47,5 @@
          filter_re = re.compile(r'GPG_ERR_[^ ]* =')
          rewrite_re = re.compile(r' *(.*) = .*')
 -- 
-1.8.3.1
+2.7.4
 
diff --git a/poky/meta/recipes-support/gpgme/gpgme/0003-Correctly-install-python-modules.patch b/poky/meta/recipes-support/gpgme/gpgme/0003-Correctly-install-python-modules.patch
index 7c9cccc..330bec6 100644
--- a/poky/meta/recipes-support/gpgme/gpgme/0003-Correctly-install-python-modules.patch
+++ b/poky/meta/recipes-support/gpgme/gpgme/0003-Correctly-install-python-modules.patch
@@ -1,7 +1,7 @@
-From 93aae34ee70b8d50b31a19a65d6ac8290cb148ae Mon Sep 17 00:00:00 2001
+From 60baf9ebf30bed0e2ee3c7c5a74d5b6d50035862 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Tue, 30 Jan 2018 15:28:49 +0800
-Subject: [PATCH 2/4] Correctly install python modules
+Subject: [PATCH 3/7] Correctly install python modules
 
 Upstream-Status: Inappropriate [oe-core specific]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
@@ -29,5 +29,5 @@
  	done
  
 -- 
-1.8.3.1
+2.7.4
 
diff --git a/poky/meta/recipes-support/gpgme/gpgme/0004-python-import.patch b/poky/meta/recipes-support/gpgme/gpgme/0004-python-import.patch
index d2b039d..1a60f79 100644
--- a/poky/meta/recipes-support/gpgme/gpgme/0004-python-import.patch
+++ b/poky/meta/recipes-support/gpgme/gpgme/0004-python-import.patch
@@ -1,7 +1,7 @@
-From 32ecc3f058307060e40af86127cd226248a73c41 Mon Sep 17 00:00:00 2001
+From fd7dcceeee439eb479edbb418bab635343414ee6 Mon Sep 17 00:00:00 2001
 From: Ross Burton <ross.burton@intel.com>
 Date: Wed, 16 Aug 2017 02:06:45 -0400
-Subject: [PATCH 3/4] python import
+Subject: [PATCH 4/7] python import
 
 Don't check for output on stderr to know if an import worked, host inputrc and
 sysroot readline can cause warnings on stderr.
@@ -30,5 +30,5 @@
  	else
  		AC_MSG_RESULT([no])
 -- 
-1.8.3.1
+2.7.4
 
diff --git a/poky/meta/recipes-support/gpgme/gpgme/0005-gpgme-config-skip-all-lib-or-usr-lib-directories-in-.patch b/poky/meta/recipes-support/gpgme/gpgme/0005-gpgme-config-skip-all-lib-or-usr-lib-directories-in-.patch
index 963ae87..2da7904 100644
--- a/poky/meta/recipes-support/gpgme/gpgme/0005-gpgme-config-skip-all-lib-or-usr-lib-directories-in-.patch
+++ b/poky/meta/recipes-support/gpgme/gpgme/0005-gpgme-config-skip-all-lib-or-usr-lib-directories-in-.patch
@@ -1,7 +1,7 @@
-From 6dcedc4dd055af902719b1a1cb10daa935a27f58 Mon Sep 17 00:00:00 2001
+From a58d90632a9907be3e8001800a143ac19075241a Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Thu, 13 Apr 2017 16:40:27 +0300
-Subject: [PATCH 4/4] gpgme-config: skip all /lib* or /usr/lib* directories in
+Subject: [PATCH 5/7] gpgme-config: skip all /lib* or /usr/lib* directories in
  output
 
 The logic was not working in multilib setups which use other
@@ -27,5 +27,5 @@
                        ;;
                    -L*|-l*)
 -- 
-1.8.3.1
+2.7.4
 
diff --git a/poky/meta/recipes-support/gpgme/gpgme/0006-fix-build-path-issue.patch b/poky/meta/recipes-support/gpgme/gpgme/0006-fix-build-path-issue.patch
index 8cc8983..26ff472 100644
--- a/poky/meta/recipes-support/gpgme/gpgme/0006-fix-build-path-issue.patch
+++ b/poky/meta/recipes-support/gpgme/gpgme/0006-fix-build-path-issue.patch
@@ -1,7 +1,7 @@
-From 180a5669e4a13a550b1b0dcef1689b6c0470fe54 Mon Sep 17 00:00:00 2001
+From 4f83750ce402b65d16cc09f8a0274a7ec76fc634 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Wed, 31 Jan 2018 11:01:09 +0800
-Subject: [PATCH] fix build path issue
+Subject: [PATCH 6/7] fix build path issue
 
 Get the "--root" directory supplied to the "install" command,
 and use it as a prefix to strip off the purported filename
@@ -33,5 +33,5 @@
  	done
  
 -- 
-1.8.3.1
+2.7.4
 
diff --git a/poky/meta/recipes-support/gpgme/gpgme/0007-qt-python-Add-variables-to-tests.patch b/poky/meta/recipes-support/gpgme/gpgme/0007-qt-python-Add-variables-to-tests.patch
index ce3745c..63eeacf 100644
--- a/poky/meta/recipes-support/gpgme/gpgme/0007-qt-python-Add-variables-to-tests.patch
+++ b/poky/meta/recipes-support/gpgme/gpgme/0007-qt-python-Add-variables-to-tests.patch
@@ -1,7 +1,7 @@
-From f47e8c6f9e461803468a64581d3640d873352eaa Mon Sep 17 00:00:00 2001
+From d3087348348b4a7fcfb05bf2a75b4a63453e1c77 Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Thu, 1 Feb 2018 10:14:30 +0800
-Subject: [PATCH] qt/python: Add variables to tests
+Subject: [PATCH 7/7] qt/python: Add variables to tests
 
 * configure.ac, lang/python/Makefile.am:
   New variable to `lang/python', set to `lang/python' if RUN_LANG_PYTHON_TESTS
@@ -19,10 +19,10 @@
  3 files changed, 21 insertions(+), 1 deletion(-)
 
 diff --git a/configure.ac b/configure.ac
-index 608c376..fad7467 100644
+index 7485cdf..4aa216d 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -536,6 +536,17 @@ AC_ARG_ENABLE(g13-test,
+@@ -535,6 +535,17 @@ AC_ARG_ENABLE(g13-test,
           run_g13_test=$enableval)
  AM_CONDITIONAL(RUN_G13_TESTS, test "$run_g13_test" = "yes")
  
@@ -41,7 +41,7 @@
  # Checks for header files.
  AC_CHECK_HEADERS_ONCE([locale.h sys/select.h sys/uio.h argp.h
 diff --git a/lang/python/Makefile.am b/lang/python/Makefile.am
-index 8d74cbd..43b5d1e 100644
+index 5a468f1..43b9788 100644
 --- a/lang/python/Makefile.am
 +++ b/lang/python/Makefile.am
 @@ -24,7 +24,10 @@ EXTRA_DIST = \
@@ -74,5 +74,5 @@
  
  EXTRA_DIST = README
 -- 
-1.8.3.1
+2.7.4
 
diff --git a/poky/meta/recipes-support/gpgme/gpgme_1.10.0.bb b/poky/meta/recipes-support/gpgme/gpgme_1.10.0.bb
deleted file mode 100644
index f015f3a..0000000
--- a/poky/meta/recipes-support/gpgme/gpgme_1.10.0.bb
+++ /dev/null
@@ -1,86 +0,0 @@
-SUMMARY = "High-level GnuPG encryption/signing API"
-DESCRIPTION = "GnuPG Made Easy (GPGME) is a library designed to make access to GnuPG easier for applications. It provides a High-Level Crypto API for encryption, decryption, signing, signature verification and key management"
-HOMEPAGE = "http://www.gnupg.org/gpgme.html"
-BUGTRACKER = "https://bugs.g10code.com/gnupg/index"
-
-LICENSE = "GPLv2+ & LGPLv2.1+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
-                    file://COPYING.LESSER;md5=bbb461211a33b134d42ed5ee802b37ff \
-                    file://src/gpgme.h.in;endline=23;md5=9d157d08a69059344e6f82abd2d25781 \
-                    file://src/engine.h;endline=22;md5=4b6d8ba313d9b564cc4d4cfb1640af9d"
-
-UPSTREAM_CHECK_URI = "https://gnupg.org/download/index.html"
-SRC_URI = "${GNUPG_MIRROR}/gpgme/${BP}.tar.bz2 \
-           file://0001-pkgconfig.patch \
-           file://0002-gpgme-lang-python-gpg-error-config-should-not-be-use.patch \
-           file://0003-Correctly-install-python-modules.patch \
-           file://0004-python-import.patch \
-           file://0005-gpgme-config-skip-all-lib-or-usr-lib-directories-in-.patch \
-           file://0006-fix-build-path-issue.patch \
-           file://0007-qt-python-Add-variables-to-tests.patch \
-          "
-
-SRC_URI[md5sum] = "78b1533c593478982ee2fc548260c563"
-SRC_URI[sha256sum] = "1a8fed1197c3b99c35f403066bb344a26224d292afc048cfdfc4ccd5690a0693"
-
-DEPENDS = "libgpg-error libassuan"
-RDEPENDS_${PN}-cpp += "libstdc++"
-
-RDEPENDS_python2-gpg += "python-unixadmin"
-RDEPENDS_python3-gpg += "python3-unixadmin"
-
-BINCONFIG = "${bindir}/gpgme-config"
-
-# Note select python2 or python3, but you can't select both at the same time
-PACKAGECONFIG ??= "python3"
-PACKAGECONFIG[python2] = ",,python swig-native,"
-PACKAGECONFIG[python3] = ",,python3 swig-native,"
-
-# Default in configure.ac: "cl cpp python qt"
-# Supported: "cl cpp python python2 python3 qt"
-# python says 'search and find python2 or python3'
-
-# Building the C++ bindings for native requires a C++ compiler with C++11
-# support. Since these bindings are currently not needed, we can disable them.
-DEFAULT_LANGUAGES = ""
-DEFAULT_LANGUAGES_class-target = "cpp"
-LANGUAGES ?= "${DEFAULT_LANGUAGES}"
-LANGUAGES .= "${@bb.utils.contains('PACKAGECONFIG', 'python2', ' python2', '', d)}"
-LANGUAGES .= "${@bb.utils.contains('PACKAGECONFIG', 'python3', ' python3', '', d)}"
-
-PYTHON_INHERIT = "${@bb.utils.contains('PACKAGECONFIG', 'python2', 'pythonnative', '', d)}"
-PYTHON_INHERIT .= "${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3native', '', d)}"
-
-EXTRA_OECONF += '--enable-languages="${LANGUAGES}" \
-                 --disable-gpgconf-test \
-                 --disable-gpg-test \
-                 --disable-gpgsm-test \
-                 --disable-g13-test \
-                 --disable-lang-qt-test \
-                 --disable-lang-python-test \
-'
-
-inherit autotools texinfo binconfig-disabled pkgconfig ${PYTHON_INHERIT}
-
-export PKG_CONFIG='pkg-config'
-
-BBCLASSEXTEND = "native nativesdk"
-
-PACKAGES =+ "${PN}-cpp"
-PACKAGES =. "${@bb.utils.contains('PACKAGECONFIG', 'python2', 'python2-gpg ', '', d)}"
-PACKAGES =. "${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3-gpg ', '', d)}"
-
-FILES_${PN}-cpp = "${libdir}/libgpgmepp.so.*"
-FILES_python2-gpg = "${PYTHON_SITEPACKAGES_DIR}/*"
-FILES_python3-gpg = "${PYTHON_SITEPACKAGES_DIR}/*"
-FILES_${PN}-dev += "${datadir}/common-lisp/source/gpgme/* \
-                    ${libdir}/cmake/* \
-"
-
-CFLAGS_append_libc-musl = " -D__error_t_defined "
-do_configure_prepend () {
-	# Else these could be used in preference to those in aclocal-copy
-	rm -f ${S}/m4/gpg-error.m4
-	rm -f ${S}/m4/libassuan.m4
-	rm -f ${S}/m4/python.m4
-}
diff --git a/poky/meta/recipes-support/gpgme/gpgme_1.11.1.bb b/poky/meta/recipes-support/gpgme/gpgme_1.11.1.bb
new file mode 100644
index 0000000..86fae94
--- /dev/null
+++ b/poky/meta/recipes-support/gpgme/gpgme_1.11.1.bb
@@ -0,0 +1,86 @@
+SUMMARY = "High-level GnuPG encryption/signing API"
+DESCRIPTION = "GnuPG Made Easy (GPGME) is a library designed to make access to GnuPG easier for applications. It provides a High-Level Crypto API for encryption, decryption, signing, signature verification and key management"
+HOMEPAGE = "http://www.gnupg.org/gpgme.html"
+BUGTRACKER = "https://bugs.g10code.com/gnupg/index"
+
+LICENSE = "GPLv2+ & LGPLv2.1+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
+                    file://COPYING.LESSER;md5=bbb461211a33b134d42ed5ee802b37ff \
+                    file://src/gpgme.h.in;endline=23;md5=4d6319e587fd944adfe61a41a8f15b36 \
+                    file://src/engine.h;endline=22;md5=4b6d8ba313d9b564cc4d4cfb1640af9d"
+
+UPSTREAM_CHECK_URI = "https://gnupg.org/download/index.html"
+SRC_URI = "${GNUPG_MIRROR}/gpgme/${BP}.tar.bz2 \
+           file://0001-pkgconfig.patch \
+           file://0002-gpgme-lang-python-gpg-error-config-should-not-be-use.patch \
+           file://0003-Correctly-install-python-modules.patch \
+           file://0004-python-import.patch \
+           file://0005-gpgme-config-skip-all-lib-or-usr-lib-directories-in-.patch \
+           file://0006-fix-build-path-issue.patch \
+           file://0007-qt-python-Add-variables-to-tests.patch \
+          "
+
+SRC_URI[md5sum] = "129c46fb85a7ffa41e43345e48aee884"
+SRC_URI[sha256sum] = "2d1b111774d2e3dd26dcd7c251819ce4ef774ec5e566251eb9308fa7542fbd6f"
+
+DEPENDS = "libgpg-error libassuan"
+RDEPENDS_${PN}-cpp += "libstdc++"
+
+RDEPENDS_python2-gpg += "python-unixadmin"
+RDEPENDS_python3-gpg += "python3-unixadmin"
+
+BINCONFIG = "${bindir}/gpgme-config"
+
+# Note select python2 or python3, but you can't select both at the same time
+PACKAGECONFIG ??= "python3"
+PACKAGECONFIG[python2] = ",,python swig-native,"
+PACKAGECONFIG[python3] = ",,python3 swig-native,"
+
+# Default in configure.ac: "cl cpp python qt"
+# Supported: "cl cpp python python2 python3 qt"
+# python says 'search and find python2 or python3'
+
+# Building the C++ bindings for native requires a C++ compiler with C++11
+# support. Since these bindings are currently not needed, we can disable them.
+DEFAULT_LANGUAGES = ""
+DEFAULT_LANGUAGES_class-target = "cpp"
+LANGUAGES ?= "${DEFAULT_LANGUAGES}"
+LANGUAGES .= "${@bb.utils.contains('PACKAGECONFIG', 'python2', ' python2', '', d)}"
+LANGUAGES .= "${@bb.utils.contains('PACKAGECONFIG', 'python3', ' python3', '', d)}"
+
+PYTHON_INHERIT = "${@bb.utils.contains('PACKAGECONFIG', 'python2', 'pythonnative', '', d)}"
+PYTHON_INHERIT .= "${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3native', '', d)}"
+
+EXTRA_OECONF += '--enable-languages="${LANGUAGES}" \
+                 --disable-gpgconf-test \
+                 --disable-gpg-test \
+                 --disable-gpgsm-test \
+                 --disable-g13-test \
+                 --disable-lang-qt-test \
+                 --disable-lang-python-test \
+'
+
+inherit autotools texinfo binconfig-disabled pkgconfig distutils-common-base ${PYTHON_INHERIT}
+
+export PKG_CONFIG='pkg-config'
+
+BBCLASSEXTEND = "native nativesdk"
+
+PACKAGES =+ "${PN}-cpp"
+PACKAGES =. "${@bb.utils.contains('PACKAGECONFIG', 'python2', 'python2-gpg ', '', d)}"
+PACKAGES =. "${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3-gpg ', '', d)}"
+
+FILES_${PN}-cpp = "${libdir}/libgpgmepp.so.*"
+FILES_python2-gpg = "${PYTHON_SITEPACKAGES_DIR}/*"
+FILES_python3-gpg = "${PYTHON_SITEPACKAGES_DIR}/*"
+FILES_${PN}-dev += "${datadir}/common-lisp/source/gpgme/* \
+                    ${libdir}/cmake/* \
+"
+
+CFLAGS_append_libc-musl = " -D__error_t_defined "
+do_configure_prepend () {
+	# Else these could be used in preference to those in aclocal-copy
+	rm -f ${S}/m4/gpg-error.m4
+	rm -f ${S}/m4/libassuan.m4
+	rm -f ${S}/m4/python.m4
+}
diff --git a/poky/meta/recipes-support/icu/icu.inc b/poky/meta/recipes-support/icu/icu.inc
index 983118c..e20085f 100644
--- a/poky/meta/recipes-support/icu/icu.inc
+++ b/poky/meta/recipes-support/icu/icu.inc
@@ -19,7 +19,9 @@
 
 ICU_MAJOR_VER = "${@d.getVar('PV').split('.')[0]}"
 
-inherit autotools pkgconfig binconfig
+inherit autotools pkgconfig binconfig multilib_script
+
+MULTILIB_SCRIPTS = "${PN}-dev:${bindir}/icu-config"
 
 # ICU needs the native build directory as an argument to its --with-cross-build option when
 # cross-compiling. Taken the situation that different builds may share a common sstate-cache
@@ -31,6 +33,8 @@
 EXTRA_OECONF_append_class-target = "${@oe.utils.conditional('SITEINFO_ENDIANNESS', 'be', ' --with-data-packaging=archive', '', d)}"
 TARGET_CXXFLAGS_append = "${@oe.utils.conditional('SITEINFO_ENDIANNESS', 'be', ' -DICU_DATA_DIR=\\""${datadir}/${BPN}/${PV}\\""', '', d)}"
 
+ASNEEDED = ""
+
 # strtod_l() is not supported by musl; also xlocale.h is missing
 # It is not possible to disable its use via configure switches or env vars
 # so monkey patching is needed.
diff --git a/poky/meta/recipes-support/icu/icu/0001-i18n-Drop-include-xlocale.h.patch b/poky/meta/recipes-support/icu/icu/0001-i18n-Drop-include-xlocale.h.patch
deleted file mode 100644
index f0c49e1..0000000
--- a/poky/meta/recipes-support/icu/icu/0001-i18n-Drop-include-xlocale.h.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From d6b57c1b4eb9a24d9d95342a961c93946539c93b Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 24 Jun 2017 22:52:40 -0700
-Subject: [PATCH 3/4] i18n: Drop include <xlocale.h>
-
-glibc 2.26 drops this header
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
----
- source/i18n/digitlst.cpp | 6 +-----
- 1 file changed, 1 insertion(+), 5 deletions(-)
-
-diff --git a/source/i18n/digitlst.cpp b/source/i18n/digitlst.cpp
-index 8e86fa7..0bdbb2c 100644
---- a/i18n/digitlst.cpp
-+++ b/i18n/digitlst.cpp
-@@ -62,11 +62,7 @@
- #endif
- 
- #if U_USE_STRTOD_L
--# if U_HAVE_XLOCALE_H
--#   include <xlocale.h>
--# else
--#   include <locale.h>
--# endif
-+# include <locale.h>
- #endif
- 
- // ***************************************************************************
--- 
-2.14.2
-
diff --git a/poky/meta/recipes-support/icu/icu/0002-Add-ARC-support.patch b/poky/meta/recipes-support/icu/icu/0002-Add-ARC-support.patch
new file mode 100644
index 0000000..20e3d83
--- /dev/null
+++ b/poky/meta/recipes-support/icu/icu/0002-Add-ARC-support.patch
@@ -0,0 +1,27 @@
+From fcfd57105b4bdb30d906df152ef01748fa95daff Mon Sep 17 00:00:00 2001
+From: Alexey Brodkin <abrodkin@synopsys.com>
+Date: Thu, 13 Sep 2018 17:13:20 +0300
+Subject: [PATCH] icu: Add ARC support
+
+Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
+
+Upstream-Status: Submitted [ https://github.com/unicode-org/icu/pull/149 ]
+---
+ i18n/double-conversion-utils.h                 | 2 +-
+ 1 files changed, 1 insertions(+), 1 deletions(-)
+
+diff --git a/i18n/double-conversion-utils.h b/i18n/double-conversion-utils.h
+index 57fc49b231a3..0bd3e8340673 100644
+--- a/i18n/double-conversion-utils.h
++++ b/i18n/double-conversion-utils.h
+@@ -86,7 +86,7 @@ inline void abort_noreturn() { abort(); }
+     defined(__SH4__) || defined(__alpha__) || \
+     defined(_MIPS_ARCH_MIPS32R2) || \
+     defined(__AARCH64EL__) || defined(__aarch64__) || \
+-    defined(__riscv)
++    defined(__riscv) || defined(__arc__)
+ #define DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS 1
+ #elif defined(__mc68000__)
+ #undef DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS
+2.17.1
+
diff --git a/poky/meta/recipes-support/icu/icu_60.2.bb b/poky/meta/recipes-support/icu/icu_60.2.bb
deleted file mode 100644
index 585a92b..0000000
--- a/poky/meta/recipes-support/icu/icu_60.2.bb
+++ /dev/null
@@ -1,29 +0,0 @@
-require icu.inc
-
-LIC_FILES_CHKSUM = "file://../LICENSE;md5=675f2d069434d8a1e4e6b0dcf4379226"
-
-def icu_download_version(d):
-    pvsplit = d.getVar('PV').split('.')
-    return pvsplit[0] + "_" + pvsplit[1]
-
-ICU_PV = "${@icu_download_version(d)}"
-
-# http://errors.yoctoproject.org/Errors/Details/20486/
-ARM_INSTRUCTION_SET_armv4 = "arm"
-ARM_INSTRUCTION_SET_armv5 = "arm"
-
-BASE_SRC_URI = "http://download.icu-project.org/files/icu4c/${PV}/icu4c-${ICU_PV}-src.tgz"
-SRC_URI = "${BASE_SRC_URI} \
-           file://icu-pkgdata-large-cmd.patch \
-           file://fix-install-manx.patch \
-           file://0001-i18n-Drop-include-xlocale.h.patch \
-           "
-
-SRC_URI_append_class-target = "\
-           file://0001-Disable-LDFLAGSICUDT-for-Linux.patch \
-          "
-SRC_URI[md5sum] = "43861b127744b3c0b9d7f386f4b9fa40"
-SRC_URI[sha256sum] = "f073ea8f35b926d70bb33e6577508aa642a8b316a803f11be20af384811db418"
-
-UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)/"
-UPSTREAM_CHECK_URI = "http://download.icu-project.org/files/icu4c/"
diff --git a/poky/meta/recipes-support/icu/icu_62.1.bb b/poky/meta/recipes-support/icu/icu_62.1.bb
new file mode 100644
index 0000000..4e3750b
--- /dev/null
+++ b/poky/meta/recipes-support/icu/icu_62.1.bb
@@ -0,0 +1,29 @@
+require icu.inc
+
+LIC_FILES_CHKSUM = "file://../LICENSE;md5=63752c57bd0b365c9af9f427ef79c819"
+
+def icu_download_version(d):
+    pvsplit = d.getVar('PV').split('.')
+    return pvsplit[0] + "_" + pvsplit[1]
+
+ICU_PV = "${@icu_download_version(d)}"
+
+# http://errors.yoctoproject.org/Errors/Details/20486/
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
+
+BASE_SRC_URI = "http://download.icu-project.org/files/icu4c/${PV}/icu4c-${ICU_PV}-src.tgz"
+SRC_URI = "${BASE_SRC_URI} \
+           file://icu-pkgdata-large-cmd.patch \
+           file://fix-install-manx.patch \
+           file://0002-Add-ARC-support.patch \
+           "
+
+SRC_URI_append_class-target = "\
+           file://0001-Disable-LDFLAGSICUDT-for-Linux.patch \
+          "
+SRC_URI[md5sum] = "490ad9d920158e0314e10ba74ae9a150"
+SRC_URI[sha256sum] = "3dd9868d666350dda66a6e305eecde9d479fb70b30d5b55d78a1deffb97d5aa3"
+
+UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)/"
+UPSTREAM_CHECK_URI = "http://download.icu-project.org/files/icu4c/"
diff --git a/poky/meta/recipes-support/iso-codes/iso-codes_3.77.bb b/poky/meta/recipes-support/iso-codes/iso-codes_3.77.bb
deleted file mode 100644
index 52e56ca..0000000
--- a/poky/meta/recipes-support/iso-codes/iso-codes_3.77.bb
+++ /dev/null
@@ -1,16 +0,0 @@
-SUMMARY = "ISO language, territory, currency, script codes and their translations"
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
-
-SRC_URI = "git://salsa.debian.org/iso-codes-team/iso-codes.git;protocol=http"
-SRCREV = "0a932d3e1e6d9058a6ef874c8ff1dc4a193bc030"
-
-# inherit gettext cannot be used, because it adds gettext-native to BASEDEPENDS which
-# are inhibited by allarch
-DEPENDS = "gettext-native"
-
-S = "${WORKDIR}/git"
-
-inherit allarch autotools
-
-FILES_${PN} += "${datadir}/xml/"
diff --git a/poky/meta/recipes-support/iso-codes/iso-codes_4.1.bb b/poky/meta/recipes-support/iso-codes/iso-codes_4.1.bb
new file mode 100644
index 0000000..1761ded
--- /dev/null
+++ b/poky/meta/recipes-support/iso-codes/iso-codes_4.1.bb
@@ -0,0 +1,19 @@
+SUMMARY = "ISO language, territory, currency, script codes and their translations"
+HOMEPAGE = "https://salsa.debian.org/iso-codes-team/iso-codes"
+BUGTRACKER = "https://salsa.debian.org/iso-codes-team/iso-codes/issues"
+
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
+
+SRC_URI = "git://salsa.debian.org/iso-codes-team/iso-codes.git;protocol=http"
+SRCREV = "164802d5fd8c7a8167816fd86a62b286680619f0"
+
+# inherit gettext cannot be used, because it adds gettext-native to BASEDEPENDS which
+# are inhibited by allarch
+DEPENDS = "gettext-native"
+
+S = "${WORKDIR}/git"
+
+inherit allarch autotools
+
+FILES_${PN} += "${datadir}/xml/"
diff --git a/poky/meta/recipes-support/libatomic-ops/libatomic-ops_7.6.2.bb b/poky/meta/recipes-support/libatomic-ops/libatomic-ops_7.6.2.bb
deleted file mode 100644
index f7b4163..0000000
--- a/poky/meta/recipes-support/libatomic-ops/libatomic-ops_7.6.2.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-SUMMARY = "A library for atomic integer operations"
-HOMEPAGE = "https://github.com/ivmai/libatomic_ops/"
-SECTION = "optional"
-PROVIDES += "libatomics-ops"
-LICENSE = "GPLv2 & MIT"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
-                    file://doc/LICENSING.txt;md5=e00dd5c8ac03a14c5ae5225a4525fa2d \
-		   "
-PV .= "+git${SRCPV}"
-SRCBRANCH ?= "release-7_6"
-
-SRCREV = "5ae4b4aeea2baf13752d07e3038c47f70f06dcac"
-SRC_URI = "git://github.com/ivmai/libatomic_ops;branch=${SRCBRANCH}"
-
-S = "${WORKDIR}/git"
-
-ALLOW_EMPTY_${PN} = "1"
-
-inherit autotools pkgconfig
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/libatomic-ops/libatomic-ops_7.6.6.bb b/poky/meta/recipes-support/libatomic-ops/libatomic-ops_7.6.6.bb
new file mode 100644
index 0000000..32d26a3
--- /dev/null
+++ b/poky/meta/recipes-support/libatomic-ops/libatomic-ops_7.6.6.bb
@@ -0,0 +1,21 @@
+SUMMARY = "A library for atomic integer operations"
+HOMEPAGE = "https://github.com/ivmai/libatomic_ops/"
+SECTION = "optional"
+PROVIDES += "libatomics-ops"
+LICENSE = "GPLv2 & MIT"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                    file://doc/LICENSING.txt;md5=e00dd5c8ac03a14c5ae5225a4525fa2d \
+                    "
+PV .= "+git${SRCPV}"
+SRCBRANCH ?= "release-7_6"
+
+SRCREV = "76ffb3b87946e4c372d112d8d00786632deab934"
+SRC_URI = "git://github.com/ivmai/libatomic_ops;branch=${SRCBRANCH}"
+
+S = "${WORKDIR}/git"
+
+ALLOW_EMPTY_${PN} = "1"
+
+inherit autotools pkgconfig
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/libbsd/libbsd/0001-Replace-__BEGIN_DECLS-and-__END_DECLS.patch b/poky/meta/recipes-support/libbsd/libbsd/0001-Replace-__BEGIN_DECLS-and-__END_DECLS.patch
deleted file mode 100644
index 54617b5..0000000
--- a/poky/meta/recipes-support/libbsd/libbsd/0001-Replace-__BEGIN_DECLS-and-__END_DECLS.patch
+++ /dev/null
@@ -1,376 +0,0 @@
-From 88adbe1a855b7aa95bd925c80ed83c86f3fc42e3 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 6 Nov 2016 09:39:31 -0800
-Subject: [PATCH 1/3] Replace __BEGIN_DECLS and __END_DECLS
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
----
-Upstream-Status: Pending
-
- include/bsd/err.h            | 10 ++++++++--
- include/bsd/libutil.h        | 10 ++++++++--
- include/bsd/md5.h            | 10 ++++++++--
- include/bsd/nlist.h          | 10 ++++++++--
- include/bsd/readpassphrase.h | 10 ++++++++--
- include/bsd/stdio.h          | 10 ++++++++--
- include/bsd/stdlib.h         | 12 +++++++++---
- include/bsd/string.h         | 12 +++++++++---
- include/bsd/stringlist.h     | 10 ++++++++--
- include/bsd/unistd.h         | 10 ++++++++--
- include/bsd/vis.h            | 10 ++++++++--
- include/bsd/wchar.h          | 10 ++++++++--
- src/hash/sha512.h            | 10 ++++++++--
- 13 files changed, 106 insertions(+), 28 deletions(-)
-
-diff --git a/include/bsd/err.h b/include/bsd/err.h
-index 12fd051..43dfc32 100644
---- a/include/bsd/err.h
-+++ b/include/bsd/err.h
-@@ -42,7 +42,10 @@
- 
- #include <stdarg.h>
- 
--__BEGIN_DECLS
-+/* __BEGIN_DECLS */
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
- void warnc(int code, const char *format, ...)
- 	__printflike(2, 3);
- void vwarnc(int code, const char *format, va_list ap)
-@@ -51,6 +54,9 @@ void errc(int status, int code, const char *format, ...)
- 	__printflike(3, 4);
- void verrc(int status, int code, const char *format, va_list ap)
- 	__printflike(3, 0);
--__END_DECLS
-+#ifdef __cplusplus
-+}
-+#endif
-+/* __END_DECLS */
- 
- #endif
-diff --git a/include/bsd/libutil.h b/include/bsd/libutil.h
-index 45b3b15..9c936e5 100644
---- a/include/bsd/libutil.h
-+++ b/include/bsd/libutil.h
-@@ -53,7 +53,10 @@ struct pidfh {
- 	ino_t	pf_ino;
- };
- 
--__BEGIN_DECLS
-+/* __BEGIN_DECLS */
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
- int humanize_number(char *buf, size_t len, int64_t bytes,
-     const char *suffix, int scale, int flags);
- int expand_number(const char *_buf, uint64_t *_num);
-@@ -66,7 +69,10 @@ int pidfile_close(struct pidfh *pfh);
- int pidfile_remove(struct pidfh *pfh);
- 
- char   *fparseln(FILE *, size_t *, size_t *, const char[3], int);
--__END_DECLS
-+#ifdef __cplusplus
-+}
-+#endif
-+/* __END_DECLS */
- 
- /* humanize_number(3) */
- #define HN_DECIMAL              0x01
-diff --git a/include/bsd/md5.h b/include/bsd/md5.h
-index 5f3ae46..5d80e5c 100644
---- a/include/bsd/md5.h
-+++ b/include/bsd/md5.h
-@@ -30,7 +30,10 @@ typedef struct MD5Context {
- #include <sys/cdefs.h>
- #include <sys/types.h>
- 
--__BEGIN_DECLS
-+/* __BEGIN_DECLS */
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
- void	 MD5Init(MD5_CTX *);
- void	 MD5Update(MD5_CTX *, const uint8_t *, size_t)
- 		__attribute__((__bounded__(__string__,2,3)));
-@@ -49,6 +52,9 @@ char	*MD5FileChunk(const char *, char *, off_t, off_t)
- char	*MD5Data(const uint8_t *, size_t, char *)
- 		__attribute__((__bounded__(__string__,1,2)))
- 		__attribute__((__bounded__(__minbytes__,3,MD5_DIGEST_STRING_LENGTH)));
--__END_DECLS
-+#ifdef __cplusplus
-+}
-+#endif
-+/* __END_DECLS */
- 
- #endif /* LIBBSD_MD5_H */
-diff --git a/include/bsd/nlist.h b/include/bsd/nlist.h
-index cb297e8..e63bbbd 100644
---- a/include/bsd/nlist.h
-+++ b/include/bsd/nlist.h
-@@ -88,8 +88,14 @@ struct nlist {
- 
- #define N_FORMAT	"%08x"	/* namelist value format; XXX */
- 
--__BEGIN_DECLS
-+/* __BEGIN_DECLS */
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
- extern int nlist(const char *filename, struct nlist *list);
--__END_DECLS
-+#ifdef __cplusplus
-+}
-+#endif
-+/* __END_DECLS */
- 
- #endif
-diff --git a/include/bsd/readpassphrase.h b/include/bsd/readpassphrase.h
-index 14744b8..fa73361 100644
---- a/include/bsd/readpassphrase.h
-+++ b/include/bsd/readpassphrase.h
-@@ -34,8 +34,14 @@
- #include <sys/cdefs.h>
- #include <sys/types.h>
- 
--__BEGIN_DECLS
-+/* __BEGIN_DECLS */
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
- char * readpassphrase(const char *, char *, size_t, int);
--__END_DECLS
-+#ifdef __cplusplus
-+}
-+#endif
-+/* __END_DECLS */
- 
- #endif /* !LIBBSD_READPASSPHRASE_H */
-diff --git a/include/bsd/stdio.h b/include/bsd/stdio.h
-index 4b69983..18645b7 100644
---- a/include/bsd/stdio.h
-+++ b/include/bsd/stdio.h
-@@ -45,7 +45,10 @@
- #endif
- #include <sys/types.h>
- 
--__BEGIN_DECLS
-+/* __BEGIN_DECLS */
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
- const char *fmtcheck(const char *, const char *);
- 
- /* XXX: The function requires cooperation from the system libc to store the
-@@ -73,7 +76,10 @@ FILE *funopen(const void *cookie,
- #define fwopen(cookie, fn) funopen(cookie, NULL, fn, NULL, NULL)
- 
- int fpurge(FILE *fp);
--__END_DECLS
-+#ifdef __cplusplus
-+}
-+#endif
-+/* __END_DECLS */
- 
- #endif
- #endif
-diff --git a/include/bsd/stdlib.h b/include/bsd/stdlib.h
-index ebc9638..c4b54b6 100644
---- a/include/bsd/stdlib.h
-+++ b/include/bsd/stdlib.h
-@@ -46,7 +46,10 @@
- #include <sys/stat.h>
- #include <stdint.h>
- 
--__BEGIN_DECLS
-+/* __BEGIN_DECLS */
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
- uint32_t arc4random(void);
- void arc4random_stir(void);
- void arc4random_addrandom(unsigned char *dat, int datlen);
-@@ -67,7 +70,7 @@ int sradixsort(const unsigned char **base, int nmemb,
-                const unsigned char *table, unsigned endbyte);
- 
- void *reallocf(void *ptr, size_t size);
--#if defined(_GNU_SOURCE) && defined(__GLIBC__) && !__GLIBC_PREREQ(2, 26)
-+#if defined(_GNU_SOURCE) && defined(__GLIBC__)
- void *reallocarray(void *ptr, size_t nmemb, size_t size);
- #endif
- 
-@@ -75,6 +78,9 @@ long long strtonum(const char *nptr, long long minval, long long maxval,
-                    const char **errstr);
- 
- char *getbsize(int *headerlenp, long *blocksizep);
--__END_DECLS
-+#ifdef __cplusplus
-+}
-+#endif
-+/* __END_DECLS */
- 
- #endif
-diff --git a/include/bsd/string.h b/include/bsd/string.h
-index 6798bf6..fa1193f 100644
---- a/include/bsd/string.h
-+++ b/include/bsd/string.h
-@@ -36,15 +36,21 @@
- #include <sys/cdefs.h>
- #include <sys/types.h>
- 
--__BEGIN_DECLS
-+/* __BEGIN_DECLS */
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
- size_t strlcpy(char *dst, const char *src, size_t siz);
- size_t strlcat(char *dst, const char *src, size_t siz);
- char *strnstr(const char *str, const char *find, size_t str_len);
- void strmode(mode_t mode, char *str);
- 
--#if defined(_GNU_SOURCE) && defined(__GLIBC__) && !__GLIBC_PREREQ(2, 25)
-+#if defined(_GNU_SOURCE) && defined(__GLIBC__)
- void explicit_bzero(void *buf, size_t len);
- #endif
--__END_DECLS
-+#ifdef __cplusplus
-+}
-+#endif
-+/* __END_DECLS */
- 
- #endif
-diff --git a/include/bsd/stringlist.h b/include/bsd/stringlist.h
-index ff30cac..4600f6b 100644
---- a/include/bsd/stringlist.h
-+++ b/include/bsd/stringlist.h
-@@ -43,12 +43,18 @@ typedef struct _stringlist {
- 	size_t	  sl_cur;
- } StringList;
- 
--__BEGIN_DECLS
-+/* __BEGIN_DECLS */
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
- StringList	*sl_init(void);
- int		 sl_add(StringList *, char *);
- void		 sl_free(StringList *, int);
- char		*sl_find(StringList *, const char *);
- int		 sl_delete(StringList *, const char *, int);
--__END_DECLS
-+#ifdef __cplusplus
-+}
-+#endif
-+/* __END_DECLS */
- 
- #endif /* LIBBSD_STRINGLIST_H */
-diff --git a/include/bsd/unistd.h b/include/bsd/unistd.h
-index 1f9c5f8..5b2f4c7 100644
---- a/include/bsd/unistd.h
-+++ b/include/bsd/unistd.h
-@@ -45,7 +45,10 @@
- #define S_ISTXT S_ISVTX
- #endif
- 
--__BEGIN_DECLS
-+/* __BEGIN_DECLS */
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
- extern int optreset;
- 
- #ifdef LIBBSD_OVERLAY
-@@ -68,6 +71,9 @@ void setproctitle(const char *fmt, ...)
- 	__printflike(1, 2);
- 
- int getpeereid(int s, uid_t *euid, gid_t *egid);
--__END_DECLS
-+#ifdef __cplusplus
-+}
-+#endif
-+/* __END_DECLS */
- 
- #endif
-diff --git a/include/bsd/vis.h b/include/bsd/vis.h
-index 970dfdd..621d3c6 100644
---- a/include/bsd/vis.h
-+++ b/include/bsd/vis.h
-@@ -74,7 +74,10 @@
- 
- #include <sys/cdefs.h>
- 
--__BEGIN_DECLS
-+/* __BEGIN_DECLS */
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
- char	*vis(char *, int, int, int);
- int	strvis(char *, const char *, int);
- int	strvisx(char *, const char *, size_t, int);
-@@ -83,6 +86,9 @@ int	strunvis(char *, const char *);
- int	strunvisx(char *, const char *, int);
- ssize_t strnunvis(char *, const char *, size_t);
- int	unvis(char *, int, int *, int);
--__END_DECLS
-+#ifdef __cplusplus
-+}
-+#endif
-+/* __END_DECLS */
- 
- #endif /* !LIBBSD_VIS_H */
-diff --git a/include/bsd/wchar.h b/include/bsd/wchar.h
-index 33a500e..aa70742 100644
---- a/include/bsd/wchar.h
-+++ b/include/bsd/wchar.h
-@@ -43,12 +43,18 @@
- #include <sys/cdefs.h>
- #include <sys/types.h>
- 
--__BEGIN_DECLS
-+/* __BEGIN_DECLS */
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
- wchar_t *fgetwln(FILE *stream, size_t *len);
- 
- size_t wcslcat(wchar_t *dst, const wchar_t *src, size_t size);
- size_t wcslcpy(wchar_t *dst, const wchar_t *src, size_t size);
--__END_DECLS
-+#ifdef __cplusplus
-+}
-+#endif
-+/* __END_DECLS */
- 
- #endif
- #endif
-diff --git a/src/hash/sha512.h b/src/hash/sha512.h
-index 4f368a1..27ddc24 100644
---- a/src/hash/sha512.h
-+++ b/src/hash/sha512.h
-@@ -39,7 +39,10 @@ typedef struct SHA512Context {
- 	unsigned char buf[128];
- } SHA512_CTX;
- 
--__BEGIN_DECLS
-+/* __BEGIN_DECLS */
-+#ifdef __cplusplus
-+extern "C" {
-+#endif
- 
- void	SHA512_Init(SHA512_CTX *);
- void	SHA512_Update(SHA512_CTX *, const void *, size_t);
-@@ -48,6 +51,9 @@ char   *SHA512_End(SHA512_CTX *, char *);
- char   *SHA512_File(const char *, char *);
- char   *SHA512_FileChunk(const char *, char *, off_t, off_t);
- char   *SHA512_Data(const void *, unsigned int, char *);
--__END_DECLS
-+#ifdef __cplusplus
-+}
-+#endif
-+/* __END_DECLS */
- 
- #endif /* !_SHA512_H_ */
--- 
-1.9.1
-
diff --git a/poky/meta/recipes-support/libbsd/libbsd/0001-flopen-Add-missing-fcntl.h-include.patch b/poky/meta/recipes-support/libbsd/libbsd/0001-flopen-Add-missing-fcntl.h-include.patch
new file mode 100644
index 0000000..8abb876
--- /dev/null
+++ b/poky/meta/recipes-support/libbsd/libbsd/0001-flopen-Add-missing-fcntl.h-include.patch
@@ -0,0 +1,46 @@
+From 13c32916b4baab58d93940d57fea9ff0777f1931 Mon Sep 17 00:00:00 2001
+From: Baruch Siach <baruch@tkos.co.il>
+Date: Tue, 5 Jun 2018 19:21:46 +0300
+Subject: [PATCH] flopen: Add missing <fcntl.h> include
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Commit 993828d84ee (Add flopenat() function from FreeBSD) dropped the
+fcntl.h header. This breaks the build with musl libc:
+
+flopen.c: In function ‘vflopenat’:
+flopen.c:60:14: error: ‘O_CREAT’ undeclared (first use in this function)
+  if (flags & O_CREAT) {
+              ^~~~~~~
+
+Restore the fcntl.h header include to fix the build.
+
+Fixes: commit 993828d84eed0468c6c15b2818e534e6b134b8e4
+Submitted-also-by: parazyd <parazyd@dyne.org>
+Signed-off-by: Baruch Siach <baruch@tkos.co.il>
+Signed-off-by: Guillem Jover <guillem@hadrons.org>
+
+Upstream-Status: Backport
+[https://gitlab.freedesktop.org/libbsd/libbsd/commit/13c32916b4baab58d93940d57fea9ff0777f1931]
+
+Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
+---
+ src/flopen.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/flopen.c b/src/flopen.c
+index b9972c9..ff20d07 100644
+--- a/src/flopen.c
++++ b/src/flopen.c
+@@ -32,6 +32,7 @@
+ #include <sys/stat.h>
+ 
+ #include <errno.h>
++#include <fcntl.h>
+ #include <stdarg.h>
+ #include <unistd.h>
+ 
+-- 
+2.7.4
+
diff --git a/poky/meta/recipes-support/libbsd/libbsd/0001-src-libbsd-overlay.pc.in-Set-Cflags-to-use-I-instead.patch b/poky/meta/recipes-support/libbsd/libbsd/0001-src-libbsd-overlay.pc.in-Set-Cflags-to-use-I-instead.patch
deleted file mode 100644
index 7e3a5b3..0000000
--- a/poky/meta/recipes-support/libbsd/libbsd/0001-src-libbsd-overlay.pc.in-Set-Cflags-to-use-I-instead.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From b6972f1c29ebf073cbe19a4a669ee093259792a0 Mon Sep 17 00:00:00 2001
-From: Fabio Berton <fabio.berton@ossystems.com.br>
-Date: Mon, 30 Jan 2017 12:00:33 -0200
-Subject: [PATCH] src/libbsd-overlay.pc.in: Set Cflags to use -I instead of
- -isystem
-Organization: O.S. Systems Software LTDA.
-
-pkg-config currently only handles -I and -L correctly, but misses
--isystem, so we need to do this workaround to fix this issue.
-
-There's a open bug in:
-https://bugzilla.freedesktop.org/show_bug.cgi?id=99516
-
-Upstream-Status: Pending
-
-Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br>
----
- src/libbsd-overlay.pc.in | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/libbsd-overlay.pc.in b/src/libbsd-overlay.pc.in
-index ac8bf89..65dc3ae 100644
---- a/src/libbsd-overlay.pc.in
-+++ b/src/libbsd-overlay.pc.in
-@@ -8,4 +8,4 @@ Description: Utility functions from BSD systems (overlay)
- Version: @VERSION@
- URL: https://libbsd.freedesktop.org/
- Libs: -L${libdir} -lbsd
--Cflags: -isystem ${includedir}/bsd -DLIBBSD_OVERLAY
-+Cflags: -I${includedir}/bsd -DLIBBSD_OVERLAY
--- 
-2.11.0
-
diff --git a/poky/meta/recipes-support/libbsd/libbsd/0002-Remove-funopen.patch b/poky/meta/recipes-support/libbsd/libbsd/0002-Remove-funopen.patch
deleted file mode 100644
index 60da15e..0000000
--- a/poky/meta/recipes-support/libbsd/libbsd/0002-Remove-funopen.patch
+++ /dev/null
@@ -1,52 +0,0 @@
-From 28fc66e8b848709a2e69dba7f07694248e0154e8 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 6 Nov 2016 09:40:43 -0800
-Subject: [PATCH 2/3] Remove funopen()
-
-Musl doesnt have prerequisites for it.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Inappropriate [musl specific]
-
- man/Makefile.am  | 1 -
- src/Makefile.am  | 1 -
- test/Makefile.am | 1 -
- 3 files changed, 3 deletions(-)
-
-diff --git a/man/Makefile.am b/man/Makefile.am
-index 28192c0..a22787d 100644
---- a/man/Makefile.am
-+++ b/man/Makefile.am
-@@ -168,7 +168,6 @@ dist_man_MANS = \
- 	fmtcheck.3bsd \
- 	fparseln.3bsd \
- 	fpurge.3bsd \
--	funopen.3bsd \
- 	getbsize.3bsd \
- 	getmode.3bsd \
- 	getpeereid.3bsd \
-diff --git a/src/Makefile.am b/src/Makefile.am
-index ad83dbf..13225a3 100644
---- a/src/Makefile.am
-+++ b/src/Makefile.am
-@@ -76,7 +76,6 @@ libbsd_la_SOURCES = \
- 	fmtcheck.c \
- 	fparseln.c \
- 	fpurge.c \
--	funopen.c \
- 	getbsize.c \
- 	getpeereid.c \
- 	hash/md5.c \
-diff --git a/test/Makefile.am b/test/Makefile.am
-index d86539a..b32ed2e 100644
---- a/test/Makefile.am
-+++ b/test/Makefile.am
-@@ -36,7 +36,6 @@ check_PROGRAMS = \
- 	endian \
- 	humanize \
- 	fgetln \
--	funopen \
- 	fparseln \
- 	fpurge \
- 	md5 \
diff --git a/poky/meta/recipes-support/libbsd/libbsd_0.8.7.bb b/poky/meta/recipes-support/libbsd/libbsd_0.8.7.bb
deleted file mode 100644
index 552a85c..0000000
--- a/poky/meta/recipes-support/libbsd/libbsd_0.8.7.bb
+++ /dev/null
@@ -1,50 +0,0 @@
-# Copyright (C) 2013 Khem Raj <raj.khem@gmail.com>
-# Released under the MIT license (see COPYING.MIT for the terms)
-
-SUMMARY = "Library of utility functions from BSD systems"
-DESCRIPTION = "This library provides useful functions commonly found on BSD systems, \
-               and lacking on others like GNU systems, thus making it easier to port \
-               projects with strong BSD origins, without needing to embed the same \
-               code over and over again on each project."
-
-HOMEPAGE = "http://libbsd.freedesktop.org/wiki/"
-# There seems to be more licenses used in the code, I don't think we want to list them all here, complete list:
-# OE @ ~/projects/libbsd $ grep ^License: COPYING  | sort
-# License: BSD-2-clause
-# License: BSD-2-clause
-# License: BSD-2-clause-NetBSD
-# License: BSD-2-clause-author
-# License: BSD-2-clause-verbatim
-# License: BSD-3-clause
-# License: BSD-3-clause
-# License: BSD-3-clause
-# License: BSD-3-clause-Peter-Wemm
-# License: BSD-3-clause-Regents
-# License: BSD-4-clause-Christopher-G-Demetriou
-# License: BSD-4-clause-Niels-Provos
-# License: BSD-5-clause-Peter-Wemm
-# License: Beerware
-# License: Expat
-# License: ISC
-# License: ISC-Original
-# License: public-domain
-# License: public-domain-Colin-Plumb
-LICENSE = "BSD-4-Clause & ISC & PD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=08fc4e66be4526715dab09c5fba5e9e8"
-SECTION = "libs"
-
-SRC_URI = " \
-    http://libbsd.freedesktop.org/releases/${BPN}-${PV}.tar.xz \
-    file://0001-src-libbsd-overlay.pc.in-Set-Cflags-to-use-I-instead.patch \
-"
-SRC_URI_append_libc-musl  = " \
-    file://0001-Replace-__BEGIN_DECLS-and-__END_DECLS.patch \
-    file://0002-Remove-funopen.patch \
-"
-
-SRC_URI[md5sum] = "d9e6980fbfe44f94fd92b89a33cce67d"
-SRC_URI[sha256sum] = "f548f10e5af5a08b1e22889ce84315b1ebe41505b015c9596bad03fd13a12b31"
-
-inherit autotools pkgconfig
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/libbsd/libbsd_0.9.1.bb b/poky/meta/recipes-support/libbsd/libbsd_0.9.1.bb
new file mode 100644
index 0000000..2b75cdf
--- /dev/null
+++ b/poky/meta/recipes-support/libbsd/libbsd_0.9.1.bb
@@ -0,0 +1,44 @@
+# Copyright (C) 2013 Khem Raj <raj.khem@gmail.com>
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+SUMMARY = "Library of utility functions from BSD systems"
+DESCRIPTION = "This library provides useful functions commonly found on BSD systems, \
+               and lacking on others like GNU systems, thus making it easier to port \
+               projects with strong BSD origins, without needing to embed the same \
+               code over and over again on each project."
+
+HOMEPAGE = "http://libbsd.freedesktop.org/wiki/"
+# There seems to be more licenses used in the code, I don't think we want to list them all here, complete list:
+# OE @ ~/projects/libbsd $ grep ^License: COPYING  | sort -u
+# License: BSD-2-clause
+# License: BSD-2-clause-NetBSD
+# License: BSD-2-clause-author
+# License: BSD-2-clause-verbatim
+# License: BSD-3-clause
+# License: BSD-3-clause-author
+# License: BSD-3-clause-John-Birrell
+# License: BSD-3-clause-Regents
+# License: BSD-4-clause-Christopher-G-Demetriou
+# License: BSD-4-clause-Niels-Provos
+# License: BSD-5-clause-Peter-Wemm
+# License: Beerware
+# License: Expat
+# License: ISC
+# License: ISC-Original
+# License: public-domain
+# License: public-domain-Colin-Plumb
+LICENSE = "BSD-4-Clause & ISC & PD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b552602fda69e34c753d26de383f33c5"
+SECTION = "libs"
+
+SRC_URI = " \
+    http://libbsd.freedesktop.org/releases/${BPN}-${PV}.tar.xz \
+    file://0001-flopen-Add-missing-fcntl.h-include.patch \
+"
+
+SRC_URI[md5sum] = "a74b80c4143afa032c90226a4518fffe"
+SRC_URI[sha256sum] = "56d835742327d69faccd16955a60b6dcf30684a8da518c4eca0ac713b9e0a7a4"
+
+inherit autotools pkgconfig
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/libcap-ng/libcap-ng/python.patch b/poky/meta/recipes-support/libcap-ng/libcap-ng/python.patch
index 59591eb..d60a0a3 100644
--- a/poky/meta/recipes-support/libcap-ng/libcap-ng/python.patch
+++ b/poky/meta/recipes-support/libcap-ng/libcap-ng/python.patch
@@ -1,4 +1,4 @@
-From b01bb2694f66cd981e6d61523433dc3eb5ed32f2 Mon Sep 17 00:00:00 2001
+From b4a354ae8d4f7c2ec3ec421c7d8a790cc57e77a9 Mon Sep 17 00:00:00 2001
 From: Li xin <lixin.fnst@cn.fujitsu.com>
 Date: Sat, 18 Jul 2015 23:03:30 +0900
 Subject: [PATCH] configure.ac - Avoid an incorrect check for python.
@@ -8,30 +8,32 @@
 
 Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 Signed-off-by: Li Xin <lixin.fnst@cn.fujitsu.com>
+Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
 ---
- bindings/python/Makefile.am |  3 ++-
- configure.ac                | 15 ++-------------
- 2 files changed, 4 insertions(+), 14 deletions(-)
+ bindings/python/Makefile.am |  4 +++-
+ configure.ac                | 17 ++---------------
+ 2 files changed, 5 insertions(+), 16 deletions(-)
 
 diff --git a/bindings/python/Makefile.am b/bindings/python/Makefile.am
-index 82b9bb8..f9fe7a8 100644
+index 999b184..c8e49db 100644
 --- a/bindings/python/Makefile.am
 +++ b/bindings/python/Makefile.am
-@@ -23,7 +23,8 @@ SUBDIRS = test
+@@ -23,7 +23,9 @@
+ SUBDIRS = test
  CONFIG_CLEAN_FILES = *.loT *.rej *.orig
  AM_CFLAGS = -fPIC -DPIC
- PYLIBVER ?= python$(PYTHON_VERSION)
 -AM_CPPFLAGS = -I. -I$(top_builddir) -I@PYINCLUDEDIR@
++PYLIBVER ?= python$(PYTHON_VERSION)
 +PYINC ?= /usr/include/$(PYLIBVER)
 +AM_CPPFLAGS = -I. -I$(top_builddir) -I$(PYINC)
- LIBS = $(top_builddir)/src/libcap-ng.la
  SWIG_FLAGS = -python
  SWIG_INCLUDES = ${AM_CPPFLAGS}
+ pyexec_PYTHON = capng.py
 diff --git a/configure.ac b/configure.ac
-index 1d777d5..9d90f64 100644
+index 7f66179..079d026 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -123,19 +123,8 @@ if test x$use_python = xno ; then
+@@ -123,21 +123,8 @@ if test x$use_python = xno ; then
  else
  AC_MSG_RESULT(testing)
  AM_PATH_PYTHON
@@ -39,11 +41,13 @@
 -if test -f ${PYINCLUDEDIR}/Python.h ; then
 -	python_found="yes"
 -	AC_SUBST(PYINCLUDEDIR)
+-	pybind_dir="python"
+-	AC_SUBST(pybind_dir)
 -	AC_MSG_NOTICE(Python bindings will be built)
 -else
 -	python_found="no"
 -	if test x$use_python = xyes ; then
--		AC_MSG_ERROR([Python explicitly required and python headers found])
+-		AC_MSG_ERROR([Python explicitly requested and python headers were not found])
 -	else
 -		AC_MSG_WARN("Python headers not found - python bindings will not be made")
 -	fi
@@ -54,5 +58,5 @@
  AM_CONDITIONAL(HAVE_PYTHON, test ${python_found} = "yes")
  
 -- 
-1.8.4.2
+2.7.4
 
diff --git a/poky/meta/recipes-support/libcap-ng/libcap-ng_0.7.8.bb b/poky/meta/recipes-support/libcap-ng/libcap-ng_0.7.8.bb
deleted file mode 100644
index 3583194..0000000
--- a/poky/meta/recipes-support/libcap-ng/libcap-ng_0.7.8.bb
+++ /dev/null
@@ -1,37 +0,0 @@
-SUMMARY = "An alternate posix capabilities library"
-DESCRIPTION = "The libcap-ng library is intended to make programming \
-with POSIX capabilities much easier than the traditional libcap library."
-HOMEPAGE = "http://freecode.com/projects/libcap-ng"
-SECTION = "base"
-LICENSE = "GPLv2+ & LGPLv2.1+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
-		    file://COPYING.LIB;md5=e3eda01d9815f8d24aae2dbd89b68b06"
-
-SRC_URI = "http://people.redhat.com/sgrubb/libcap-ng/libcap-ng-${PV}.tar.gz \
-           file://python.patch"
-
-inherit lib_package autotools python3native
-
-SRC_URI[md5sum] = "0dece96644bd798020e170fbf7663802"
-SRC_URI[sha256sum] = "c21af997445cd4107a55d386f955c5ea6f6e96ead693e9151277c0ab5f97d05f"
-
-DEPENDS += "swig-native python3"
-
-EXTRA_OECONF += "--with-python --with-python3"
-EXTRA_OEMAKE += "PYLIBVER='python${PYTHON_BASEVERSION}${PYTHON_ABI}' PYINC='${STAGING_INCDIR}/${PYLIBVER}'"
-
-PACKAGES += "${PN}-python"
-
-FILES_${PN}-python = "${libdir}/python${PYTHON_BASEVERSION}"
-
-BBCLASSEXTEND = "native"
-
-do_install_append() {
-	# Moving libcap-ng to base_libdir
-	if [ ! ${D}${libdir} -ef ${D}${base_libdir} ]; then
-		mkdir -p ${D}/${base_libdir}/
-		mv -f ${D}${libdir}/libcap-ng.so.* ${D}${base_libdir}/
-		relpath=${@os.path.relpath("${base_libdir}", "${libdir}")}
-		ln -sf ${relpath}/libcap-ng.so.0.0.0 ${D}${libdir}/libcap-ng.so
-	fi
-}
diff --git a/poky/meta/recipes-support/libcap-ng/libcap-ng_0.7.9.bb b/poky/meta/recipes-support/libcap-ng/libcap-ng_0.7.9.bb
new file mode 100644
index 0000000..aff6259
--- /dev/null
+++ b/poky/meta/recipes-support/libcap-ng/libcap-ng_0.7.9.bb
@@ -0,0 +1,37 @@
+SUMMARY = "An alternate posix capabilities library"
+DESCRIPTION = "The libcap-ng library is intended to make programming \
+with POSIX capabilities much easier than the traditional libcap library."
+HOMEPAGE = "http://freecode.com/projects/libcap-ng"
+SECTION = "base"
+LICENSE = "GPLv2+ & LGPLv2.1+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
+		    file://COPYING.LIB;md5=e3eda01d9815f8d24aae2dbd89b68b06"
+
+SRC_URI = "http://people.redhat.com/sgrubb/libcap-ng/libcap-ng-${PV}.tar.gz \
+           file://python.patch"
+
+inherit lib_package autotools python3native
+
+SRC_URI[md5sum] = "2398d695508fab9ce33668c53a89b0e9"
+SRC_URI[sha256sum] = "4a1532bcf3731aade40936f6d6a586ed5a66ca4c7455e1338d1f6c3e09221328"
+
+DEPENDS += "swig-native python3"
+
+EXTRA_OECONF += "--with-python --with-python3"
+EXTRA_OEMAKE += "PYLIBVER='python${PYTHON_BASEVERSION}${PYTHON_ABI}' PYINC='${STAGING_INCDIR}/${PYLIBVER}'"
+
+PACKAGES += "${PN}-python"
+
+FILES_${PN}-python = "${libdir}/python${PYTHON_BASEVERSION}"
+
+BBCLASSEXTEND = "native"
+
+do_install_append() {
+	# Moving libcap-ng to base_libdir
+	if [ ! ${D}${libdir} -ef ${D}${base_libdir} ]; then
+		mkdir -p ${D}/${base_libdir}/
+		mv -f ${D}${libdir}/libcap-ng.so.* ${D}${base_libdir}/
+		relpath=${@os.path.relpath("${base_libdir}", "${libdir}")}
+		ln -sf ${relpath}/libcap-ng.so.0.0.0 ${D}${libdir}/libcap-ng.so
+	fi
+}
diff --git a/poky/meta/recipes-support/libcap/libcap_2.25.bb b/poky/meta/recipes-support/libcap/libcap_2.25.bb
index d619a2e..6df6745 100644
--- a/poky/meta/recipes-support/libcap/libcap_2.25.bb
+++ b/poky/meta/recipes-support/libcap/libcap_2.25.bb
@@ -32,7 +32,7 @@
 
 EXTRA_OEMAKE = " \
   INDENT=  \
-  lib=${@os.path.basename('${libdir}')} \
+  lib='${baselib}' \
   RAISE_SETFCAP=no \
   DYNAMIC=yes \
   BUILD_GPERF=yes \
diff --git a/poky/meta/recipes-support/libcheck/libcheck/not-echo-compiler-info-to-check_stdint.h.patch b/poky/meta/recipes-support/libcheck/libcheck/not-echo-compiler-info-to-check_stdint.h.patch
new file mode 100644
index 0000000..3c75727
--- /dev/null
+++ b/poky/meta/recipes-support/libcheck/libcheck/not-echo-compiler-info-to-check_stdint.h.patch
@@ -0,0 +1,19 @@
+Do not echo compiler info in a comment line to check_stdint.h which causes
+multilib install file conflict.
+
+Upstream-Status: Pending
+
+Signed-off-by: Kai Kang <kai.kang@windriver.com>
+
+diff --git a/m4/ax_create_stdint_h.m4 b/m4/ax_create_stdint_h.m4
+index 33a21f8..eacc37a 100644
+--- a/m4/ax_create_stdint_h.m4
++++ b/m4/ax_create_stdint_h.m4
+@@ -272,7 +272,6 @@ echo "#ifndef" $_ac_stdint_h >$ac_stdint
+ echo "#define" $_ac_stdint_h "1" >>$ac_stdint
+ echo "#ifndef" _GENERATED_STDINT_H >>$ac_stdint
+ echo "#define" _GENERATED_STDINT_H '"'$PACKAGE $VERSION'"' >>$ac_stdint
+-echo "/* generated $ac_cv_stdint_message */" >>$ac_stdint
+ if test "_$ac_cv_header_stdint_t" != "_" ; then
+ echo "#define _STDINT_HAVE_STDINT_H" "1" >>$ac_stdint
+ echo "#include <stdint.h>" >>$ac_stdint
diff --git a/poky/meta/recipes-support/libcheck/libcheck_0.12.0.bb b/poky/meta/recipes-support/libcheck/libcheck_0.12.0.bb
index e646d43..3bb48a7 100644
--- a/poky/meta/recipes-support/libcheck/libcheck_0.12.0.bb
+++ b/poky/meta/recipes-support/libcheck/libcheck_0.12.0.bb
@@ -5,7 +5,8 @@
 LICENSE  = "LGPLv2.1+"
 LIC_FILES_CHKSUM = "file://COPYING.LESSER;md5=2d5025d4aa3495befef8f17206a5b0a1"
 
-SRC_URI = "https://github.com/${BPN}/check/releases/download/${PV}/check-${PV}.tar.gz"
+SRC_URI = "https://github.com/${BPN}/check/releases/download/${PV}/check-${PV}.tar.gz \
+           file://not-echo-compiler-info-to-check_stdint.h.patch"
 SRC_URI[md5sum] = "31b17c6075820a434119592941186f70"
 SRC_URI[sha256sum] = "464201098bee00e90f5c4bdfa94a5d3ead8d641f9025b560a27755a83b824234"
 UPSTREAM_CHECK_URI = "https://github.com/libcheck/check/releases/"
diff --git a/poky/meta/recipes-support/libcroco/libcroco/CVE-2017-7961.patch b/poky/meta/recipes-support/libcroco/libcroco/CVE-2017-7961.patch
deleted file mode 100644
index 8ac11ec..0000000
--- a/poky/meta/recipes-support/libcroco/libcroco/CVE-2017-7961.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-From 5fa3165613b77b516e2b0dc128f73b673bd3ec8b Mon Sep 17 00:00:00 2001
-From: Ignacio Casal Quinteiro <qignacio@amazon.com>
-Date: Sun, 16 Apr 2017 13:56:09 +0200
-Subject: [PATCH] tknzr: support only max long rgb values
-
-This fixes a possible out of bound when reading rgbs which
-are longer than the support MAXLONG
-
-Upstream-Status: Backport [https://git.gnome.org/browse/libcroco/patch/?id=9ad72875e9f08e4c519ef63d44cdbd94aa9504f7]
-CVE: CVE-2017-7961
-Signed-off-by: Sinan Kaya <okaya@kernel.org>
----
- src/cr-tknzr.c | 10 ++++++++++
- 1 file changed, 10 insertions(+)
-
-diff --git a/src/cr-tknzr.c b/src/cr-tknzr.c
-index e3af0ee..76886ec 100644
---- a/src/cr-tknzr.c
-+++ b/src/cr-tknzr.c
-@@ -1280,6 +1280,11 @@ cr_tknzr_parse_rgb (CRTknzr * a_this, CRRgb ** a_rgb)
-         status = cr_tknzr_parse_num (a_this, &num);
-         ENSURE_PARSING_COND ((status == CR_OK) && (num != NULL));
- 
-+        if (num->val > G_MAXLONG) {
-+                status = CR_PARSING_ERROR;
-+                goto error;
-+        }
-+
-         red = num->val;
-         cr_num_destroy (num);
-         num = NULL;
-@@ -1299,6 +1304,11 @@ cr_tknzr_parse_rgb (CRTknzr * a_this, CRRgb ** a_rgb)
-                 status = cr_tknzr_parse_num (a_this, &num);
-                 ENSURE_PARSING_COND ((status == CR_OK) && (num != NULL));
- 
-+                if (num->val > G_MAXLONG) {
-+                        status = CR_PARSING_ERROR;
-+                        goto error;
-+                }
-+
-                 PEEK_BYTE (a_this, 1, &next_bytes[0]);
-                 if (next_bytes[0] == '%') {
-                         SKIP_CHARS (a_this, 1);
--- 
-2.19.0
-
diff --git a/poky/meta/recipes-support/libcroco/libcroco_0.6.12.bb b/poky/meta/recipes-support/libcroco/libcroco_0.6.12.bb
index c7507e0..5b962ee 100644
--- a/poky/meta/recipes-support/libcroco/libcroco_0.6.12.bb
+++ b/poky/meta/recipes-support/libcroco/libcroco_0.6.12.bb
@@ -16,8 +16,7 @@
 
 inherit gnomebase gtk-doc binconfig-disabled
 
-SRC_URI += "file://CVE-2017-7960.patch \
-            file://CVE-2017-7961.patch "
+SRC_URI += "file://CVE-2017-7960.patch"
 
 SRC_URI[archive.md5sum] = "bc0984fce078ba2ce29f9500c6b9ddce"
 SRC_URI[archive.sha256sum] = "ddc4b5546c9fb4280a5017e2707fbd4839034ed1aba5b7d4372212f34f84f860"
diff --git a/poky/meta/recipes-support/libevdev/libevdev_1.5.8.bb b/poky/meta/recipes-support/libevdev/libevdev_1.5.8.bb
deleted file mode 100644
index c138014..0000000
--- a/poky/meta/recipes-support/libevdev/libevdev_1.5.8.bb
+++ /dev/null
@@ -1,14 +0,0 @@
-SUMMARY = "Wrapper library for evdev devices"
-HOMEPAGE = "http://www.freedesktop.org/wiki/Software/libevdev/"
-SECTION = "libs"
-
-LICENSE = "MIT-X"
-LIC_FILES_CHKSUM = "file://COPYING;md5=75aae0d38feea6fda97ca381cb9132eb \
-                    file://libevdev/libevdev.h;endline=21;md5=7ff4f0b5113252c2f1a828e0bbad98d1"
-
-SRC_URI = "http://www.freedesktop.org/software/libevdev/${BP}.tar.xz"
-
-SRC_URI[md5sum] = "c25a8c3939e4ad59a5e9e5e1e354832d"
-SRC_URI[sha256sum] = "6083d81e46609da8ba80cb826c02d9080764a6dec33c8267ccb7e158833d4c6d"
-
-inherit autotools pkgconfig
diff --git a/poky/meta/recipes-support/libevdev/libevdev_1.5.9.bb b/poky/meta/recipes-support/libevdev/libevdev_1.5.9.bb
new file mode 100644
index 0000000..f59c60e
--- /dev/null
+++ b/poky/meta/recipes-support/libevdev/libevdev_1.5.9.bb
@@ -0,0 +1,14 @@
+SUMMARY = "Wrapper library for evdev devices"
+HOMEPAGE = "http://www.freedesktop.org/wiki/Software/libevdev/"
+SECTION = "libs"
+
+LICENSE = "MIT-X"
+LIC_FILES_CHKSUM = "file://COPYING;md5=75aae0d38feea6fda97ca381cb9132eb \
+                    file://libevdev/libevdev.h;endline=21;md5=7ff4f0b5113252c2f1a828e0bbad98d1"
+
+SRC_URI = "http://www.freedesktop.org/software/libevdev/${BP}.tar.xz"
+
+SRC_URI[md5sum] = "a1ca11e961c1efed720fac4130881904"
+SRC_URI[sha256sum] = "e1663751443bed9d3e76a4fe2caf6fa866a79705d91cacad815c04e706198a75"
+
+inherit autotools pkgconfig
diff --git a/poky/meta/recipes-support/libevent/libevent_2.1.8.bb b/poky/meta/recipes-support/libevent/libevent_2.1.8.bb
index 83ce464..0f91e05 100644
--- a/poky/meta/recipes-support/libevent/libevent_2.1.8.bb
+++ b/poky/meta/recipes-support/libevent/libevent_2.1.8.bb
@@ -28,12 +28,16 @@
 # Needed for Debian packaging
 LEAD_SONAME = "libevent-2.1.so"
 
-inherit ptest
+inherit ptest multilib_header
 
 DEPENDS = "zlib"
 
 BBCLASSEXTEND = "native nativesdk"
 
+do_install_append() {
+        oe_multilib_header event2/event-config.h
+}
+
 do_install_ptest() {
 	install -d ${D}${PTEST_PATH}/test
 	for file in ${B}/test/.libs/regress ${B}/test/.libs/test*
diff --git a/poky/meta/recipes-support/libfm/libfm-extra_1.2.5.bb b/poky/meta/recipes-support/libfm/libfm-extra_1.2.5.bb
deleted file mode 100644
index c0fd83e..0000000
--- a/poky/meta/recipes-support/libfm/libfm-extra_1.2.5.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-SUMMARY = "Library for file management"
-HOMEPAGE = "http://pcmanfm.sourceforge.net/"
-
-LICENSE = "LGPLv2+"
-LIC_FILES_CHKSUM = "file://src/fm-extra.h;beginline=8;endline=21;md5=ef1f84da64b3c01cca447212f7ef6007"
-
-SECTION = "x11/libs"
-DEPENDS = "glib-2.0-native glib-2.0 intltool-native"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/pcmanfm/libfm-${PV}.tar.xz \
-           file://0001-nls.m4-Take-it-from-gettext-0.15.patch \
-          "
-
-SRC_URI[md5sum] = "a1ba9ae5e920f38b647dd511edd6c807"
-SRC_URI[sha256sum] = "c706bb1020cf5f2d6f5a9226f692ce1985947134dcf2bde64278bd0420779b5a"
-
-S = "${WORKDIR}/libfm-${PV}"
-
-EXTRA_OECONF = "--with-extra-only --with-gtk=no"
-
-inherit autotools pkgconfig gtk-doc gettext
-
-do_configure[dirs] =+ "${S}/m4"
diff --git a/poky/meta/recipes-support/libfm/libfm-extra_1.3.0.2.bb b/poky/meta/recipes-support/libfm/libfm-extra_1.3.0.2.bb
new file mode 100644
index 0000000..734d010
--- /dev/null
+++ b/poky/meta/recipes-support/libfm/libfm-extra_1.3.0.2.bb
@@ -0,0 +1,23 @@
+SUMMARY = "Library for file management"
+HOMEPAGE = "http://pcmanfm.sourceforge.net/"
+
+LICENSE = "LGPLv2+"
+LIC_FILES_CHKSUM = "file://src/fm-extra.h;beginline=8;endline=21;md5=ef1f84da64b3c01cca447212f7ef6007"
+
+SECTION = "x11/libs"
+DEPENDS = "glib-2.0-native glib-2.0 intltool-native"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/pcmanfm/libfm-${PV}.tar.xz \
+           file://0001-nls.m4-Take-it-from-gettext-0.15.patch \
+          "
+
+SRC_URI[md5sum] = "02a024714d51e0d37afc7bd596a44f3b"
+SRC_URI[sha256sum] = "18d06f7996ce1cf8947df6e106bc0338c6ae0c4138c316f2501f6f6f435c7c72"
+
+S = "${WORKDIR}/libfm-${PV}"
+
+EXTRA_OECONF = "--with-extra-only --with-gtk=no"
+
+inherit autotools pkgconfig gtk-doc gettext
+
+do_configure[dirs] =+ "${S}/m4"
diff --git a/poky/meta/recipes-support/libfm/libfm/0001-Do-not-add-library-path-to-avoid-host-contamination.patch b/poky/meta/recipes-support/libfm/libfm/0001-Do-not-add-library-path-to-avoid-host-contamination.patch
new file mode 100644
index 0000000..f4c8912
--- /dev/null
+++ b/poky/meta/recipes-support/libfm/libfm/0001-Do-not-add-library-path-to-avoid-host-contamination.patch
@@ -0,0 +1,23 @@
+From 07260295e031e845e38ba874fa6ab500790c4aaf Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Wed, 2 May 2018 16:48:47 +0300
+Subject: [PATCH] Do not add library path to avoid host contamination
+
+Upstream-Status: Pending
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ src/modules/Makefile.am | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/src/modules/Makefile.am b/src/modules/Makefile.am
+index e61f4e0..01c15bd 100644
+--- a/src/modules/Makefile.am
++++ b/src/modules/Makefile.am
+@@ -11,7 +11,6 @@ AM_CPPFLAGS = \
+ # tell libtool we compile module not library
+ AM_LDFLAGS = \
+ 	-no-undefined -module -avoid-version -shared -export-dynamic \
+-	-L$(libdir) \
+ 	$(GIO_LIBS)
+ 
+ # the module should be linked only with libfm, not libfm-gtk or whatever
diff --git a/poky/meta/recipes-support/libfm/libfm/0001-Enclose-text-in-programlisting-into-CDATA.patch b/poky/meta/recipes-support/libfm/libfm/0001-Enclose-text-in-programlisting-into-CDATA.patch
deleted file mode 100644
index 40e5329..0000000
--- a/poky/meta/recipes-support/libfm/libfm/0001-Enclose-text-in-programlisting-into-CDATA.patch
+++ /dev/null
@@ -1,76 +0,0 @@
-From ed4ca8c0b17ff5d3c768b92409c1787e3f3f1841 Mon Sep 17 00:00:00 2001
-From: Andriy Grytsenko <andrej@rep.kiev.ua>
-Date: Sun, 26 Nov 2017 22:30:15 +0200
-Subject: [PATCH 2/2] Enclose text in <programlisting> into <![CDATA[
-
-New gtk-doc fails on tag-like data in it.
-See https://bugs.freedesktop.org/show_bug.cgi?id=101585
-That is definitely bug of gtk-doc but let workaround it.
-
-Upstream-Status: Backport [https://git.lxde.org/gitweb/?p=lxde/libfm.git;a=commit;h=b072ee0400432d72fdf86ba9fed74a7e0ec11ec1]
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
----
- src/base/fm-module.c | 12 ++++++------
- 1 file changed, 6 insertions(+), 6 deletions(-)
-
-diff --git a/src/base/fm-module.c b/src/base/fm-module.c
-index d364b2d..2e8c978 100644
---- a/src/base/fm-module.c
-+++ b/src/base/fm-module.c
-@@ -44,7 +44,7 @@
-  * of that type should include:
-  * <example id="example-fm-dummy-h">
-  * <title>Sample of fm-dummy.h</title>
-- * <programlisting>
-+ * <programlisting><![CDATA[
-  * #include <libfm/fm.h>
-  *
-  * #define FM_MODULE_dummy_VERSION 1
-@@ -54,7 +54,7 @@
-  * } FmDummyInit;
-  *
-  * extern FmDummyInit fm_module_init_dummy;
-- * </programlisting>
-+ * ]]></programlisting>
-  * </example>
-  * The FM_MODULE_dummy_VERSION is a number which should be increased each
-  * time something in FmDummyInit structure is changed. The FmDummyInit
-@@ -65,7 +65,7 @@
-  * module handling in your code:
-  * <example id="example-fm-dummy-widget-c">
-  * <title>Sample of fm-dummy-widget.c</title>
-- * <programlisting>
-+ * <programlisting><![CDATA[
-  * #include "fm-dummy.h"
-  *
-  * FM_MODULE_DEFINE_TYPE(dummy, FmDummyInit, 1)
-@@ -87,7 +87,7 @@
-  *         result = module->get_new("test sample");
-  *     return result;
-  * }
-- * </programlisting>
-+ * ]]></programlisting>
-  * </example>
-  *
-  * Third thing application should do is to register module type on the
-@@ -108,7 +108,7 @@
-  * interface (see the fm-dummy.h header example above):
-  * <example id="example-fm-dummy-test-c">
-  * <title>Sample of module dummy/test</title>
-- * <programlisting>
-+ * <programlisting><![CDATA[
-  * #include "fm-dummy.h"
-  *
-  * FM_DEFINE_MODULE(dummy, test)
-@@ -121,7 +121,7 @@
-  * FmDummyInit fm_module_init_dummy = {
-  *     fm_dummy_test_get_new;
-  * };
-- * </programlisting>
-+ * ]]></programlisting>
-  * </example>
-  * The fm_module_init_dummy should be exactly the same structure that is
-  * defined in the header file above.
--- 
-2.15.1
-
diff --git a/poky/meta/recipes-support/libfm/libfm_1.2.5.bb b/poky/meta/recipes-support/libfm/libfm_1.2.5.bb
deleted file mode 100644
index 5964083..0000000
--- a/poky/meta/recipes-support/libfm/libfm_1.2.5.bb
+++ /dev/null
@@ -1,54 +0,0 @@
-SUMMARY = "Library for file management"
-HOMEPAGE = "http://pcmanfm.sourceforge.net/"
-
-LICENSE = "GPLv2+ & LGPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=4641e94ec96f98fabc56ff9cc48be14b \
-                    file://src/fm.h;beginline=8;endline=21;md5=ef1f84da64b3c01cca447212f7ef6007 \
-                    file://src/base/fm-config.h;beginline=10;endline=23;md5=ef1f84da64b3c01cca447212f7ef6007 \
-                    file://src/fm-gtk.h;beginline=6;endline=19;md5=646baa4955c04fe768f2ca27b92ac8dd"
-
-
-SECTION = "x11/libs"
-DEPENDS = "glib-2.0 glib-2.0-native pango gtk+3 menu-cache intltool-native libexif libfm-extra"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/pcmanfm/libfm-${PV}.tar.xz \
-           file://0001-Correctly-check-the-stamp-file-that-indicates-if-we-.patch \
-           file://0001-Enclose-text-in-programlisting-into-CDATA.patch \
-           "
-
-SRC_URI[md5sum] = "a1ba9ae5e920f38b647dd511edd6c807"
-SRC_URI[sha256sum] = "c706bb1020cf5f2d6f5a9226f692ce1985947134dcf2bde64278bd0420779b5a"
-
-inherit autotools pkgconfig gtk-doc gettext distro_features_check
-ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
-
-EXTRA_OECONF = "--with-gtk=3"
-
-do_configure[dirs] =+ "${S}/m4"
-
-PACKAGES =+ "libfm-gtk"
-PACKAGES += "${PN}-mime"
-FILES_libfm-gtk = " \
-    ${libdir}/libfm-gtk*so.* \
-    ${libdir}/libfm/modules/gtk* \
-    ${bindir}/libfm-pref-apps \
-    ${bindir}/lxshortcut \
-    ${datadir}/applications/libfm-pref-apps.desktop \
-    ${datadir}/applications/lxshortcut.desktop \
-    ${datadir}/libfm/images/folder.png \
-    ${datadir}/libfm/images/unknown.png \
-    ${datadir}/libfm/ui/*.ui \
-"
-FILES_${PN}-mime = "${datadir}/mime/"
-
-do_install_append () {
-    # remove files which are part of libfm-extra
-    rm -f ${D}${includedir}/libfm-1.0/fm-xml-file.h
-    rm -f ${D}${includedir}/libfm-1.0/fm-version.h
-    rm -f ${D}${includedir}/libfm-1.0/fm-extra.h
-    rm -f ${D}${includedir}/libfm
-    rm -f ${D}${libdir}/pkgconfig/libfm-extra.pc
-    rm -f ${D}${libdir}/libfm-extra.so*
-    rm -f ${D}${libdir}/libfm-extra.a
-    rm -f ${D}${libdir}/libfm-extra.la
-}
diff --git a/poky/meta/recipes-support/libfm/libfm_1.3.0.2.bb b/poky/meta/recipes-support/libfm/libfm_1.3.0.2.bb
new file mode 100644
index 0000000..62d6a51
--- /dev/null
+++ b/poky/meta/recipes-support/libfm/libfm_1.3.0.2.bb
@@ -0,0 +1,54 @@
+SUMMARY = "Library for file management"
+HOMEPAGE = "http://pcmanfm.sourceforge.net/"
+
+LICENSE = "GPLv2+ & LGPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=4641e94ec96f98fabc56ff9cc48be14b \
+                    file://src/fm.h;beginline=8;endline=21;md5=ef1f84da64b3c01cca447212f7ef6007 \
+                    file://src/base/fm-config.h;beginline=10;endline=23;md5=ef1f84da64b3c01cca447212f7ef6007 \
+                    file://src/fm-gtk.h;beginline=6;endline=19;md5=646baa4955c04fe768f2ca27b92ac8dd"
+
+
+SECTION = "x11/libs"
+DEPENDS = "glib-2.0 glib-2.0-native pango gtk+3 menu-cache intltool-native libexif libfm-extra"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/pcmanfm/libfm-${PV}.tar.xz \
+           file://0001-Correctly-check-the-stamp-file-that-indicates-if-we-.patch \
+           file://0001-Do-not-add-library-path-to-avoid-host-contamination.patch \
+           "
+
+SRC_URI[md5sum] = "02a024714d51e0d37afc7bd596a44f3b"
+SRC_URI[sha256sum] = "18d06f7996ce1cf8947df6e106bc0338c6ae0c4138c316f2501f6f6f435c7c72"
+
+inherit autotools pkgconfig gtk-doc gettext distro_features_check
+ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
+
+EXTRA_OECONF = "--with-gtk=3"
+
+do_configure[dirs] =+ "${S}/m4"
+
+PACKAGES =+ "libfm-gtk"
+PACKAGES += "${PN}-mime"
+FILES_libfm-gtk = " \
+    ${libdir}/libfm-gtk*so.* \
+    ${libdir}/libfm/modules/gtk* \
+    ${bindir}/libfm-pref-apps \
+    ${bindir}/lxshortcut \
+    ${datadir}/applications/libfm-pref-apps.desktop \
+    ${datadir}/applications/lxshortcut.desktop \
+    ${datadir}/libfm/images/folder.png \
+    ${datadir}/libfm/images/unknown.png \
+    ${datadir}/libfm/ui/*.ui \
+"
+FILES_${PN}-mime = "${datadir}/mime/"
+
+do_install_append () {
+    # remove files which are part of libfm-extra
+    rm -f ${D}${includedir}/libfm-1.0/fm-xml-file.h
+    rm -f ${D}${includedir}/libfm-1.0/fm-version.h
+    rm -f ${D}${includedir}/libfm-1.0/fm-extra.h
+    rm -f ${D}${includedir}/libfm
+    rm -f ${D}${libdir}/pkgconfig/libfm-extra.pc
+    rm -f ${D}${libdir}/libfm-extra.so*
+    rm -f ${D}${libdir}/libfm-extra.a
+    rm -f ${D}${libdir}/libfm-extra.la
+}
diff --git a/poky/meta/recipes-support/libgcrypt/files/CVE-2018-0495.patch b/poky/meta/recipes-support/libgcrypt/files/CVE-2018-0495.patch
deleted file mode 100644
index c16bd3a..0000000
--- a/poky/meta/recipes-support/libgcrypt/files/CVE-2018-0495.patch
+++ /dev/null
@@ -1,76 +0,0 @@
-From 9010d1576e278a4274ad3f4aa15776c28f6ba965 Mon Sep 17 00:00:00 2001
-From: NIIBE Yutaka <gniibe@fsij.org>
-Date: Wed, 13 Jun 2018 15:28:58 +0900
-Subject: [PATCH] ecc: Add blinding for ECDSA.
-
-* cipher/ecc-ecdsa.c (_gcry_ecc_ecdsa_sign): Blind secret D with
-randomized nonce B.
-
---
-
-Reported-by: Keegan Ryan <Keegan.Ryan@nccgroup.trust>
-CVE-id: CVE-2018-0495
-
-Upstream-Status: Backport [http://git.gnupg.org/cgi-bin/gitweb.cgi?p=libgcrypt.git;a=commit;h=9010d1576e278a4274ad3f4aa15776c28f6ba965]
-
-Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
----
- cipher/ecc-ecdsa.c | 20 ++++++++++++++++++--
- 1 file changed, 18 insertions(+), 2 deletions(-)
-
-diff --git a/cipher/ecc-ecdsa.c b/cipher/ecc-ecdsa.c
-index 1484830b..140e8c09 100644
---- a/cipher/ecc-ecdsa.c
-+++ b/cipher/ecc-ecdsa.c
-@@ -50,6 +50,8 @@ _gcry_ecc_ecdsa_sign (gcry_mpi_t input, ECC_secret_key *skey,
-   const void *abuf;
-   unsigned int abits, qbits;
-   mpi_ec_t ctx;
-+  gcry_mpi_t b;                /* Random number needed for blinding.  */
-+  gcry_mpi_t bi;               /* multiplicative inverse of B.        */
- 
-   if (DBG_CIPHER)
-     log_mpidump ("ecdsa sign hash  ", input );
-@@ -61,6 +63,15 @@ _gcry_ecc_ecdsa_sign (gcry_mpi_t input, ECC_secret_key *skey,
-   if (rc)
-     return rc;
- 
-+  b  = mpi_snew (qbits);
-+  bi = mpi_snew (qbits);
-+  do
-+    {
-+      _gcry_mpi_randomize (b, qbits, GCRY_WEAK_RANDOM);
-+      mpi_mod (b, b, skey->E.n);
-+    }
-+  while (!mpi_invm (bi, b, skey->E.n));
-+
-   k = NULL;
-   dr = mpi_alloc (0);
-   sum = mpi_alloc (0);
-@@ -115,8 +126,11 @@ _gcry_ecc_ecdsa_sign (gcry_mpi_t input, ECC_secret_key *skey,
-         }
-       while (!mpi_cmp_ui (r, 0));
- 
--      mpi_mulm (dr, skey->d, r, skey->E.n); /* dr = d*r mod n  */
--      mpi_addm (sum, hash, dr, skey->E.n);  /* sum = hash + (d*r) mod n  */
-+      mpi_mulm (dr, b, skey->d, skey->E.n);
-+      mpi_mulm (dr, dr, r, skey->E.n);      /* dr = d*r mod n (blinded with b) */
-+      mpi_mulm (sum, b, hash, skey->E.n);
-+      mpi_addm (sum, sum, dr, skey->E.n);   /* sum = hash + (d*r) mod n  (blinded with b) */
-+      mpi_mulm (sum, bi, sum, skey->E.n);   /* undo blinding by b^-1 */
-       mpi_invm (k_1, k, skey->E.n);         /* k_1 = k^(-1) mod n  */
-       mpi_mulm (s, k_1, sum, skey->E.n);    /* s = k^(-1)*(hash+(d*r)) mod n */
-     }
-@@ -129,6 +143,8 @@ _gcry_ecc_ecdsa_sign (gcry_mpi_t input, ECC_secret_key *skey,
-     }
- 
-  leave:
-+  mpi_free (b);
-+  mpi_free (bi);
-   _gcry_mpi_ec_free (ctx);
-   point_free (&I);
-   mpi_free (x);
--- 
-2.13.3
-
diff --git a/poky/meta/recipes-support/libgcrypt/libgcrypt_1.8.2.bb b/poky/meta/recipes-support/libgcrypt/libgcrypt_1.8.2.bb
deleted file mode 100644
index 9d036c8..0000000
--- a/poky/meta/recipes-support/libgcrypt/libgcrypt_1.8.2.bb
+++ /dev/null
@@ -1,54 +0,0 @@
-SUMMARY = "General purpose cryptographic library based on the code from GnuPG"
-HOMEPAGE = "http://directory.fsf.org/project/libgcrypt/"
-BUGTRACKER = "https://bugs.g10code.com/gnupg/index"
-SECTION = "libs"
-
-# helper program gcryptrnd and getrandom are under GPL, rest LGPL
-LICENSE = "GPLv2+ & LGPLv2.1+ & GPLv3+"
-LICENSE_${PN} = "LGPLv2.1+"
-LICENSE_${PN}-dev = "GPLv2+ & LGPLv2.1+"
-LICENSE_dumpsexp-dev = "GPLv3+"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
-                    file://COPYING.LIB;md5=bbb461211a33b134d42ed5ee802b37ff"
-
-DEPENDS = "libgpg-error"
-
-UPSTREAM_CHECK_URI = "https://gnupg.org/download/index.html"
-SRC_URI = "${GNUPG_MIRROR}/libgcrypt/libgcrypt-${PV}.tar.bz2 \
-           file://0001-Add-and-use-pkg-config-for-libgcrypt-instead-of-conf.patch \
-           file://0003-tests-bench-slope.c-workaround-ICE-failure-on-mips-w.patch \
-           file://0002-libgcrypt-fix-building-error-with-O2-in-sysroot-path.patch \
-           file://0004-tests-Makefile.am-fix-undefined-reference-to-pthread.patch \
-           file://CVE-2018-0495.patch \
-"
-SRC_URI[md5sum] = "cfb0b5c79eab07686b6898160a407139"
-SRC_URI[sha256sum] = "c8064cae7558144b13ef0eb87093412380efa16c4ee30ad12ecb54886a524c07"
-
-BINCONFIG = "${bindir}/libgcrypt-config"
-
-inherit autotools texinfo binconfig-disabled pkgconfig
-
-EXTRA_OECONF = "--disable-asm"
-EXTRA_OEMAKE_class-target = "LIBTOOLFLAGS='--tag=CC'"
-
-PACKAGECONFIG ??= "capabilities"
-PACKAGECONFIG[capabilities] = "--with-capabilities,--without-capabilities,libcap"
-
-do_configure_prepend () {
-	# Else this could be used in preference to the one in aclocal-copy
-	rm -f ${S}/m4/gpg-error.m4
-}
-
-# libgcrypt.pc is added locally and thus installed here
-do_install_append() {
-	install -d ${D}/${libdir}/pkgconfig
-	install -m 0644 ${B}/src/libgcrypt.pc ${D}/${libdir}/pkgconfig/
-}
-
-PACKAGES =+ "dumpsexp-dev"
-
-FILES_${PN}-dev += "${bindir}/hmac256"
-FILES_dumpsexp-dev += "${bindir}/dumpsexp"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/libgcrypt/libgcrypt_1.8.3.bb b/poky/meta/recipes-support/libgcrypt/libgcrypt_1.8.3.bb
new file mode 100644
index 0000000..cefa836
--- /dev/null
+++ b/poky/meta/recipes-support/libgcrypt/libgcrypt_1.8.3.bb
@@ -0,0 +1,54 @@
+SUMMARY = "General purpose cryptographic library based on the code from GnuPG"
+HOMEPAGE = "http://directory.fsf.org/project/libgcrypt/"
+BUGTRACKER = "https://bugs.g10code.com/gnupg/index"
+SECTION = "libs"
+
+# helper program gcryptrnd and getrandom are under GPL, rest LGPL
+LICENSE = "GPLv2+ & LGPLv2.1+ & GPLv3+"
+LICENSE_${PN} = "LGPLv2.1+"
+LICENSE_${PN}-dev = "GPLv2+ & LGPLv2.1+"
+LICENSE_dumpsexp-dev = "GPLv3+"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
+                    file://COPYING.LIB;md5=bbb461211a33b134d42ed5ee802b37ff \
+                    file://LICENSES;md5=840e3bcb754e5046ffeda7619034cbd8"
+
+DEPENDS = "libgpg-error"
+
+UPSTREAM_CHECK_URI = "https://gnupg.org/download/index.html"
+SRC_URI = "${GNUPG_MIRROR}/libgcrypt/libgcrypt-${PV}.tar.bz2 \
+           file://0001-Add-and-use-pkg-config-for-libgcrypt-instead-of-conf.patch \
+           file://0003-tests-bench-slope.c-workaround-ICE-failure-on-mips-w.patch \
+           file://0002-libgcrypt-fix-building-error-with-O2-in-sysroot-path.patch \
+           file://0004-tests-Makefile.am-fix-undefined-reference-to-pthread.patch \
+"
+SRC_URI[md5sum] = "3139c2402e844985a67fb288a930534d"
+SRC_URI[sha256sum] = "66ec90be036747602f2b48f98312361a9180c97c68a690a5f376fa0f67d0af7c"
+
+BINCONFIG = "${bindir}/libgcrypt-config"
+
+inherit autotools texinfo binconfig-disabled pkgconfig
+
+EXTRA_OECONF = "--disable-asm"
+EXTRA_OEMAKE_class-target = "LIBTOOLFLAGS='--tag=CC'"
+
+PACKAGECONFIG ??= "capabilities"
+PACKAGECONFIG[capabilities] = "--with-capabilities,--without-capabilities,libcap"
+
+do_configure_prepend () {
+	# Else this could be used in preference to the one in aclocal-copy
+	rm -f ${S}/m4/gpg-error.m4
+}
+
+# libgcrypt.pc is added locally and thus installed here
+do_install_append() {
+	install -d ${D}/${libdir}/pkgconfig
+	install -m 0644 ${B}/src/libgcrypt.pc ${D}/${libdir}/pkgconfig/
+}
+
+PACKAGES =+ "dumpsexp-dev"
+
+FILES_${PN}-dev += "${bindir}/hmac256"
+FILES_dumpsexp-dev += "${bindir}/dumpsexp"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/libgpg-error/libgpg-error/0001-syscfg-Support-ARC-CPUs-and-simplify-aliasing-table.patch b/poky/meta/recipes-support/libgpg-error/libgpg-error/0001-syscfg-Support-ARC-CPUs-and-simplify-aliasing-table.patch
new file mode 100644
index 0000000..03b0ce7
--- /dev/null
+++ b/poky/meta/recipes-support/libgpg-error/libgpg-error/0001-syscfg-Support-ARC-CPUs-and-simplify-aliasing-table.patch
@@ -0,0 +1,298 @@
+From d4fd6975671477721936060771aa4d7d07fb0910 Mon Sep 17 00:00:00 2001
+From: Werner Koch <wk@gnupg.org>
+Date: Tue, 18 Sep 2018 14:54:08 +0200
+Subject: [PATCH libgpg-error] syscfg: Support ARC CPUs and simplify aliasing
+ table.
+
+* src/mkheader.c (xmalloc): New.
+(xstrdup): Implement using xmalloc.
+(canon_host_triplet): Add supporr for arc CPU.  Adjust alias table to
+also alias *-pc-*.  Rename ibm to unknown. Add internal arg.  Add
+unknown vendor hack.
+(main): New mode to just print the canonicalized form.
+* src/Makefile.am (lock_obj_pub): s/-(pc|ibm)-/-unknown/.  Also rename
+files accordingly.
+--
+
+config.sub does no real aliasing and thus we would need to add several
+vendors to the alising tables despite that this has no technical
+meanding.  Instead we now replace the vendor with "unknown" for the
+4-part-"triplets".  This change will make maintenace easier.
+
+Signed-off-by: Werner Koch <wk@gnupg.org>
+
+Upstream-Status: Backport [ http://git.gnupg.org/cgi-bin/gitweb.cgi?p=libgpg-error.git;a=commit;h=48c8f8ddfc80 ]
+---
+ src/Makefile.am                               | 16 ++--
+ src/mkheader.c                                | 92 ++++++++++++++++---
+ ...-gnu.h => lock-obj-pub.i686-unknown-gnu.h} |  0
+ ... lock-obj-pub.i686-unknown-kfreebsd-gnu.h} |  0
+ ... => lock-obj-pub.i686-unknown-linux-gnu.h} |  0
+ ...=> lock-obj-pub.s390x-unknown-linux-gnu.h} |  0
+ ...ock-obj-pub.x86_64-unknown-kfreebsd-gnu.h} |  0
+ ...> lock-obj-pub.x86_64-unknown-linux-gnu.h} |  0
+ ...ock-obj-pub.x86_64-unknown-linux-gnux32.h} |  0
+ ... lock-obj-pub.x86_64-unknown-linux-musl.h} |  0
+ 10 files changed, 85 insertions(+), 23 deletions(-)
+ rename src/syscfg/{lock-obj-pub.i686-pc-gnu.h => lock-obj-pub.i686-unknown-gnu.h} (100%)
+ rename src/syscfg/{lock-obj-pub.i686-pc-kfreebsd-gnu.h => lock-obj-pub.i686-unknown-kfreebsd-gnu.h} (100%)
+ rename src/syscfg/{lock-obj-pub.i686-pc-linux-gnu.h => lock-obj-pub.i686-unknown-linux-gnu.h} (100%)
+ rename src/syscfg/{lock-obj-pub.s390x-ibm-linux-gnu.h => lock-obj-pub.s390x-unknown-linux-gnu.h} (100%)
+ rename src/syscfg/{lock-obj-pub.x86_64-pc-kfreebsd-gnu.h => lock-obj-pub.x86_64-unknown-kfreebsd-gnu.h} (100%)
+ rename src/syscfg/{lock-obj-pub.x86_64-pc-linux-gnu.h => lock-obj-pub.x86_64-unknown-linux-gnu.h} (100%)
+ rename src/syscfg/{lock-obj-pub.x86_64-pc-linux-gnux32.h => lock-obj-pub.x86_64-unknown-linux-gnux32.h} (100%)
+ rename src/syscfg/{lock-obj-pub.x86_64-pc-linux-musl.h => lock-obj-pub.x86_64-unknown-linux-musl.h} (100%)
+
+diff --git a/src/Makefile.am b/src/Makefile.am
+index 42998e46a3bc..8ec582ef99fb 100644
+--- a/src/Makefile.am
++++ b/src/Makefile.am
+@@ -52,9 +52,9 @@ lock_obj_pub = \
+ 	syscfg/lock-obj-pub.arm-apple-darwin.h              \
+         syscfg/lock-obj-pub.hppa-unknown-linux-gnu.h        \
+ 	syscfg/lock-obj-pub.i386-apple-darwin.h             \
+-        syscfg/lock-obj-pub.i686-pc-gnu.h                   \
+-        syscfg/lock-obj-pub.i686-pc-kfreebsd-gnu.h          \
+-        syscfg/lock-obj-pub.i686-pc-linux-gnu.h             \
++        syscfg/lock-obj-pub.i686-unknown-gnu.h              \
++        syscfg/lock-obj-pub.i686-unknown-kfreebsd-gnu.h     \
++        syscfg/lock-obj-pub.i686-unknown-linux-gnu.h        \
+         syscfg/lock-obj-pub.m68k-unknown-linux-gnu.h        \
+         syscfg/lock-obj-pub.mips-unknown-linux-gnu.h        \
+         syscfg/lock-obj-pub.mips64el-unknown-linux-gnuabi64.h \
+@@ -66,16 +66,16 @@ lock_obj_pub = \
+ 	syscfg/lock-obj-pub.powerpc64le-unknown-linux-gnu.h \
+ 	syscfg/lock-obj-pub.powerpc-unknown-linux-gnuspe.h  \
+ 	syscfg/lock-obj-pub.riscv64-unknown-linux-gnu.h     \
+-        syscfg/lock-obj-pub.s390x-ibm-linux-gnu.h           \
++        syscfg/lock-obj-pub.s390x-unknown-linux-gnu.h       \
+         syscfg/lock-obj-pub.sh3-unknown-linux-gnu.h         \
+         syscfg/lock-obj-pub.sh4-unknown-linux-gnu.h         \
+         syscfg/lock-obj-pub.sparc-unknown-linux-gnu.h       \
+         syscfg/lock-obj-pub.sparc64-unknown-linux-gnu.h     \
+ 	syscfg/lock-obj-pub.x86_64-apple-darwin.h           \
+-        syscfg/lock-obj-pub.x86_64-pc-kfreebsd-gnu.h        \
+-        syscfg/lock-obj-pub.x86_64-pc-linux-gnu.h           \
+-        syscfg/lock-obj-pub.x86_64-pc-linux-gnux32.h        \
+-        syscfg/lock-obj-pub.x86_64-pc-linux-musl.h          \
++        syscfg/lock-obj-pub.x86_64-unknown-kfreebsd-gnu.h   \
++        syscfg/lock-obj-pub.x86_64-unknown-linux-gnu.h      \
++        syscfg/lock-obj-pub.x86_64-unknown-linux-gnux32.h   \
++        syscfg/lock-obj-pub.x86_64-unknown-linux-musl.h     \
+ 	syscfg/lock-obj-pub.tilegx-unknown-linux-gnu.h      \
+ 	syscfg/lock-obj-pub.ia64-unknown-linux-gnu.h        \
+ 	syscfg/lock-obj-pub.mingw32.h
+diff --git a/src/mkheader.c b/src/mkheader.c
+index 2fc5fada66a4..7a38a1bec1a4 100644
+--- a/src/mkheader.c
++++ b/src/mkheader.c
+@@ -51,17 +51,27 @@ xfree (void *a)
+ 
+ 
+ static char *
+-xstrdup (const char *string)
++xmalloc (size_t n)
+ {
+   char *p;
+-  size_t len = strlen (string) + 1;
+ 
+-  p = malloc (len);
++  p = malloc (n);
+   if (!p)
+     {
+       fputs (PGM ": out of core\n", stderr);
+       exit (1);
+     }
++  return p;
++}
++
++
++static char *
++xstrdup (const char *string)
++{
++  char *p;
++  size_t len = strlen (string) + 1;
++
++  p = xmalloc (len);
+   memcpy (p, string, len);
+   return p;
+ }
+@@ -69,23 +79,31 @@ xstrdup (const char *string)
+ 
+ /* Return a malloced string with TRIPLET.  If TRIPLET has an alias
+    return that instead.  In general build-aux/config.sub should do the
+-   aliasing but some returned triplets are anyway identical and thus we
+-   use this function to map it to the canonical form.  */
++   aliasing but some returned triplets are anyway identical and thus
++   we use this function to map it to the canonical form.
++   NO_VENDOR_HACK is for internal use; caller must call with 0. */
+ static char *
+-canon_host_triplet (const char *triplet)
++canon_host_triplet (const char *triplet, int no_vendor_hack)
+ {
+   struct {
+     const char *name;
+     const char *alias;
+   } tbl[] = {
+-    {"i486-pc-linux-gnu", "i686-pc-linux-gnu" },
++    {"i486-pc-linux-gnu", "i686-unknown-linux-gnu" },
+     {"i586-pc-linux-gnu" },
+-    {"i486-pc-gnu", "i686-pc-gnu"},
++    {"i686-pc-linux-gnu" },
++    {"arc-oe-linux-uclibc" }, /* Other CPU but same struct.  */
++
++    {"i486-pc-gnu", "i686-unknown-gnu"},
+     {"i586-pc-gnu"},
+-    {"i486-pc-kfreebsd-gnu", "i686-pc-kfreebsd-gnu"},
++    {"i686-pc-gnu"},
++
++    {"i486-pc-kfreebsd-gnu", "i686-unknown-kfreebsd-gnu"},
+     {"i586-pc-kfreebsd-gnu"},
++    {"i686-pc-kfreebsd-gnu"},
+ 
+-    {"x86_64-pc-linux-gnuhardened1", "x86_64-pc-linux-gnu" },
++    {"x86_64-pc-linux-gnuhardened1", "x86_64-unknown-linux-gnu" },
++    {"x86_64-pc-linux-gnu" },
+ 
+     {"powerpc-unknown-linux-gnuspe", "powerpc-unknown-linux-gnu" },
+ 
+@@ -98,6 +116,7 @@ canon_host_triplet (const char *triplet)
+   };
+   int i;
+   const char *lastalias = NULL;
++  const char *s;
+ 
+   for (i=0; tbl[i].name; i++)
+     {
+@@ -110,6 +129,36 @@ canon_host_triplet (const char *triplet)
+           return xstrdup (lastalias);
+         }
+     }
++  for (i=0, s=triplet; *s; s++)
++    if (*s == '-')
++      i++;
++  if (i > 2 && !no_vendor_hack)
++    {
++      /* We have a 4 part "triplet": CPU-VENDOR-KERNEL-SYSTEM where
++       * the last two parts replace the OS part of a real triplet.
++       * The VENDOR part is then in general useless because
++       * KERNEL-SYSTEM is specific enough.  We now do a second pass by
++       * replacing VENDOR with "unknown".  */
++      char *p;
++      char *buf = xmalloc (strlen (triplet) + 7 + 1);
++
++      for (p=buf,s=triplet,i=0; *s; s++)
++        {
++          *p++ = *s;
++          if (*s == '-' && ++i == 1)
++            {
++              memcpy (p, "unknown-",8);
++              p += 8;
++              for (s++; *s != '-'; s++)
++                ;
++            }
++        }
++      *p = 0;
++      p = canon_host_triplet (buf, 1);
++      xfree (buf);
++      return p;
++    }
++
+   return xstrdup (triplet);
+ }
+ 
+@@ -558,7 +607,7 @@ write_special (const char *fname, int lnr, const char *tag)
+ int
+ main (int argc, char **argv)
+ {
+-  FILE *fp;
++  FILE *fp = NULL;
+   char line[LINESIZE];
+   int lnr = 0;
+   const char *fname, *s;
+@@ -571,11 +620,22 @@ main (int argc, char **argv)
+       argc--; argv++;
+     }
+ 
+-  if (argc != 6)
++  if (argc == 1)
++    {
++      /* Print just the canonicalized host triplet.  */
++      host_triplet = canon_host_triplet (argv[0], 0);
++      printf ("%s\n", host_triplet);
++      goto leave;
++    }
++  else if (argc == 6)
++    ; /* Standard operation.  */
++  else
+     {
+       fputs ("usage: " PGM
+              " host_os host_triplet template.h config.h"
+-             " version version_number\n",
++             " version version_number\n"
++             "       " PGM
++             " host_triplet\n",
+              stderr);
+       return 1;
+     }
+@@ -586,7 +646,7 @@ main (int argc, char **argv)
+   hdr_version = argv[4];
+   hdr_version_number = argv[5];
+ 
+-  host_triplet = canon_host_triplet (host_triplet_raw);
++  host_triplet = canon_host_triplet (host_triplet_raw, 0);
+ 
+   srcdir = malloc (strlen (fname) + 2 + 1);
+   if (!srcdir)
+@@ -677,13 +737,15 @@ main (int argc, char **argv)
+          "End:\n"
+          "*/\n", stdout);
+ 
++ leave:
+   if (ferror (stdout))
+     {
+       fprintf (stderr, PGM ": error writing to stdout: %s\n", strerror (errno));
+       return 1;
+     }
+ 
+-  fclose (fp);
++  if (fp)
++    fclose (fp);
+ 
+   xfree (host_triplet);
+   return 0;
+diff --git a/src/syscfg/lock-obj-pub.i686-pc-gnu.h b/src/syscfg/lock-obj-pub.i686-unknown-gnu.h
+similarity index 100%
+rename from src/syscfg/lock-obj-pub.i686-pc-gnu.h
+rename to src/syscfg/lock-obj-pub.i686-unknown-gnu.h
+diff --git a/src/syscfg/lock-obj-pub.i686-pc-kfreebsd-gnu.h b/src/syscfg/lock-obj-pub.i686-unknown-kfreebsd-gnu.h
+similarity index 100%
+rename from src/syscfg/lock-obj-pub.i686-pc-kfreebsd-gnu.h
+rename to src/syscfg/lock-obj-pub.i686-unknown-kfreebsd-gnu.h
+diff --git a/src/syscfg/lock-obj-pub.i686-pc-linux-gnu.h b/src/syscfg/lock-obj-pub.i686-unknown-linux-gnu.h
+similarity index 100%
+rename from src/syscfg/lock-obj-pub.i686-pc-linux-gnu.h
+rename to src/syscfg/lock-obj-pub.i686-unknown-linux-gnu.h
+diff --git a/src/syscfg/lock-obj-pub.s390x-ibm-linux-gnu.h b/src/syscfg/lock-obj-pub.s390x-unknown-linux-gnu.h
+similarity index 100%
+rename from src/syscfg/lock-obj-pub.s390x-ibm-linux-gnu.h
+rename to src/syscfg/lock-obj-pub.s390x-unknown-linux-gnu.h
+diff --git a/src/syscfg/lock-obj-pub.x86_64-pc-kfreebsd-gnu.h b/src/syscfg/lock-obj-pub.x86_64-unknown-kfreebsd-gnu.h
+similarity index 100%
+rename from src/syscfg/lock-obj-pub.x86_64-pc-kfreebsd-gnu.h
+rename to src/syscfg/lock-obj-pub.x86_64-unknown-kfreebsd-gnu.h
+diff --git a/src/syscfg/lock-obj-pub.x86_64-pc-linux-gnu.h b/src/syscfg/lock-obj-pub.x86_64-unknown-linux-gnu.h
+similarity index 100%
+rename from src/syscfg/lock-obj-pub.x86_64-pc-linux-gnu.h
+rename to src/syscfg/lock-obj-pub.x86_64-unknown-linux-gnu.h
+diff --git a/src/syscfg/lock-obj-pub.x86_64-pc-linux-gnux32.h b/src/syscfg/lock-obj-pub.x86_64-unknown-linux-gnux32.h
+similarity index 100%
+rename from src/syscfg/lock-obj-pub.x86_64-pc-linux-gnux32.h
+rename to src/syscfg/lock-obj-pub.x86_64-unknown-linux-gnux32.h
+diff --git a/src/syscfg/lock-obj-pub.x86_64-pc-linux-musl.h b/src/syscfg/lock-obj-pub.x86_64-unknown-linux-musl.h
+similarity index 100%
+rename from src/syscfg/lock-obj-pub.x86_64-pc-linux-musl.h
+rename to src/syscfg/lock-obj-pub.x86_64-unknown-linux-musl.h
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-support/libgpg-error/libgpg-error/0002-syscfg-Add-support-for-arc-unknown-linux-gnu.patch b/poky/meta/recipes-support/libgpg-error/libgpg-error/0002-syscfg-Add-support-for-arc-unknown-linux-gnu.patch
new file mode 100644
index 0000000..197652f
--- /dev/null
+++ b/poky/meta/recipes-support/libgpg-error/libgpg-error/0002-syscfg-Add-support-for-arc-unknown-linux-gnu.patch
@@ -0,0 +1,35 @@
+From ae6a3f20345dac4b9daab8c39ac2d3fb3f2c21e3 Mon Sep 17 00:00:00 2001
+From: Werner Koch <wk@gnupg.org>
+Date: Fri, 21 Sep 2018 14:37:21 +0200
+Subject: [PATCH Libgpg-error] syscfg: Add support for arc-unknown-linux-gnu
+
+* src/mkheader.c (canon_host_triplet): Add to table.
+--
+
+Note that unknown in the above triplet is actually a wildcard for 4
+part triplets.
+
+Signed-off-by: Werner Koch <wk@gnupg.org>
+
+Upstream-Status: Backport [http://git.gnupg.org/cgi-bin/gitweb.cgi?p=libgpg-error.git;a=commit;h=f4f0da74f526d7e35cedbc2e93454df6440dbfa5]
+---
+ src/mkheader.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/src/mkheader.c b/src/mkheader.c
+index 7a38a1bec1a4..a4866e96ef43 100644
+--- a/src/mkheader.c
++++ b/src/mkheader.c
+@@ -92,7 +92,8 @@ canon_host_triplet (const char *triplet, int no_vendor_hack)
+     {"i486-pc-linux-gnu", "i686-unknown-linux-gnu" },
+     {"i586-pc-linux-gnu" },
+     {"i686-pc-linux-gnu" },
+-    {"arc-oe-linux-uclibc" }, /* Other CPU but same struct.  */
++    {"arc-oe-linux-gnu"    }, /* Other CPU but same struct.  */
++    {"arc-oe-linux-uclibc" }, /* and uclibc is also the same.  */
+ 
+     {"i486-pc-gnu", "i686-unknown-gnu"},
+     {"i586-pc-gnu"},
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-support/libgpg-error/libgpg-error/pkgconfig.patch b/poky/meta/recipes-support/libgpg-error/libgpg-error/pkgconfig.patch
index 9ffeedb..3066613 100644
--- a/poky/meta/recipes-support/libgpg-error/libgpg-error/pkgconfig.patch
+++ b/poky/meta/recipes-support/libgpg-error/libgpg-error/pkgconfig.patch
@@ -1,15 +1,26 @@
-
-#
-# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher
-#
+From ec309e20b5a27d42a5fb915c328d61e924ab5f19 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 29 Mar 2018 15:12:17 +0800
+Subject: [PATCH] support pkgconfig
 
 Upstream-Status: Pending
 
-Index: libgpg-error-1.17/configure.ac
-===================================================================
---- libgpg-error-1.17.orig/configure.ac
-+++ libgpg-error-1.17/configure.ac
-@@ -529,6 +529,7 @@ AC_CONFIG_FILES([src/Makefile tests/Make
+Rebase to 1.28
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ configure.ac        |  1 +
+ src/Makefile.am     |  4 ++-
+ src/gpg-error.m4    | 71 +++--------------------------------------------------
+ src/gpg-error.pc.in | 11 +++++++++
+ 4 files changed, 18 insertions(+), 69 deletions(-)
+ create mode 100644 src/gpg-error.pc.in
+
+diff --git a/configure.ac b/configure.ac
+index aca9300..f7794e9 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -621,6 +621,7 @@ AC_CONFIG_FILES([src/Makefile tests/Makefile])
  AC_CONFIG_FILES([lang/Makefile lang/cl/Makefile lang/cl/gpg-error.asd])
  AC_CONFIG_FILES([src/versioninfo.rc src/gpg-error.w32-manifest])
  AC_CONFIG_FILES([src/gpg-error-config], [chmod +x src/gpg-error-config])
@@ -17,33 +28,33 @@
  
  AC_OUTPUT
  
-Index: libgpg-error-1.17/src/Makefile.am
-===================================================================
---- libgpg-error-1.17.orig/src/Makefile.am
-+++ libgpg-error-1.17/src/Makefile.am
-@@ -75,6 +75,8 @@ nodist_include_HEADERS = gpg-error.h
- bin_SCRIPTS = gpg-error-config
+diff --git a/src/Makefile.am b/src/Makefile.am
+index 268c2ab..95f8459 100644
+--- a/src/Makefile.am
++++ b/src/Makefile.am
+@@ -87,6 +87,8 @@ bin_SCRIPTS = gpg-error-config
+ nodist_bin_SCRIPTS = gpgrt-config
  m4datadir = $(datadir)/aclocal
- m4data_DATA = gpg-error.m4
+ m4data_DATA = gpg-error.m4 gpgrt.m4
 +pkgconfigdir = $(libdir)/pkgconfig
 +pkgconfig_DATA = gpg-error.pc
  
  EXTRA_DIST = mkstrtable.awk err-sources.h.in err-codes.h.in \
  	mkerrnos.awk errnos.in README \
-@@ -82,7 +84,7 @@ EXTRA_DIST = mkstrtable.awk err-sources.
+@@ -94,7 +96,7 @@ EXTRA_DIST = mkstrtable.awk err-sources.h.in err-codes.h.in \
  	mkheader.c gpg-error.h.in mkw32errmap.c w32-add.h w32ce-add.h \
- 	err-sources.h err-codes.h gpg-error-config.in gpg-error.m4 \
+ 	err-sources.h err-codes.h gpg-error-config.in gpg-error.m4 gpgrt.m4 \
  	gpg-error.vers gpg-error.def.in \
 -        versioninfo.rc.in gpg-error.w32-manifest.in \
 +        versioninfo.rc.in gpg-error.w32-manifest.in gpg-error.pc \
  	$(lock_obj_pub)
  
  BUILT_SOURCES = err-sources.h err-codes.h code-to-errno.h code-from-errno.h \
-Index: libgpg-error-1.17/src/gpg-error.m4
-===================================================================
---- libgpg-error-1.17.orig/src/gpg-error.m4
-+++ libgpg-error-1.17/src/gpg-error.m4
-@@ -26,73 +26,13 @@ dnl is added to the gpg_config_script_wa
+diff --git a/src/gpg-error.m4 b/src/gpg-error.m4
+index 60c88d8..2ef7e3e 100644
+--- a/src/gpg-error.m4
++++ b/src/gpg-error.m4
+@@ -26,73 +26,13 @@ dnl is added to the gpg_config_script_warn variable.
  dnl
  AC_DEFUN([AM_PATH_GPG_ERROR],
  [ AC_REQUIRE([AC_CANONICAL_HOST])
@@ -132,10 +143,11 @@
      ifelse([$3], , :, [$3])
    fi
    AC_SUBST(GPG_ERROR_CFLAGS)
-Index: libgpg-error-1.17/src/gpg-error.pc.in
-===================================================================
+diff --git a/src/gpg-error.pc.in b/src/gpg-error.pc.in
+new file mode 100644
+index 0000000..bc0b174
 --- /dev/null
-+++ libgpg-error-1.17/src/gpg-error.pc.in
++++ b/src/gpg-error.pc.in
 @@ -0,0 +1,11 @@
 +prefix=@prefix@
 +exec_prefix=@exec_prefix@
@@ -148,3 +160,6 @@
 +Version: @VERSION@
 +Libs: -L${libdir} -lgpg-error
 +Cflags: -I${includedir}
+-- 
+1.8.3.1
+
diff --git a/poky/meta/recipes-support/libgpg-error/libgpg-error_1.27.bb b/poky/meta/recipes-support/libgpg-error/libgpg-error_1.27.bb
deleted file mode 100644
index b74f079..0000000
--- a/poky/meta/recipes-support/libgpg-error/libgpg-error_1.27.bb
+++ /dev/null
@@ -1,62 +0,0 @@
-SUMMARY = "Small library that defines common error values for all GnuPG components"
-HOMEPAGE = "http://www.gnupg.org/related_software/libgpg-error/"
-BUGTRACKER = "https://bugs.g10code.com/gnupg/index"
-
-LICENSE = "GPLv2+ & LGPLv2.1+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
-                    file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1 \
-                    file://src/gpg-error.h.in;endline=23;md5=beae1e44d8d5c265d194760276033a7c \
-                    file://src/init.c;endline=20;md5=872b2389fe9bae7ffb80d2b91225afbc"
-
-
-SECTION = "libs"
-
-UPSTREAM_CHECK_URI = "https://gnupg.org/download/index.html"
-SRC_URI = "${GNUPG_MIRROR}/libgpg-error/libgpg-error-${PV}.tar.bz2 \
-           file://pkgconfig.patch \
-	  "
-
-SRC_URI[md5sum] = "5217ef3e76a7275a2a3b569a12ddc989"
-SRC_URI[sha256sum] = "4f93aac6fecb7da2b92871bb9ee33032be6a87b174f54abf8ddf0911a22d29d2"
-
-BINCONFIG = "${bindir}/gpg-error-config"
-
-inherit autotools binconfig-disabled pkgconfig gettext multilib_header
-CPPFLAGS += "-P"
-do_compile_prepend() {
-	TARGET_FILE=linux-gnu
-	if [ ${TARGET_OS} = "mingw32" ]; then
-		# There are no arch specific syscfg files for mingw32
-		TARGET_FILE=
-	elif [ ${TARGET_OS} != "linux" ]; then
-		TARGET_FILE=${TARGET_OS}
-	fi
-
-	case ${TARGET_ARCH} in
-	  aarch64_be) TUPLE=aarch64-unknown-linux-gnu ;;
-	  arm)	      TUPLE=arm-unknown-linux-gnueabi ;;
-	  armeb)      TUPLE=arm-unknown-linux-gnueabi ;;
-	  i586|i686)  TUPLE=i686-pc-linux-gnu ;;
-	  mips64*)    TUPLE=mips64el-unknown-linux-gnuabi64 ;;
-	  mips*el)    TUPLE=mipsel-unknown-linux-gnu ;;
-	  mips*)      TUPLE=mips-unknown-linux-gnu ;;
-	  x86_64)     TUPLE=x86_64-pc-linux-gnu ;;
-	  *)          TUPLE=${TARGET_ARCH}-unknown-linux-gnu ;; 
-	esac
-
-	if [ -n "$TARGET_FILE" ]; then
-		cp ${S}/src/syscfg/lock-obj-pub.$TUPLE.h \
-			${S}/src/syscfg/lock-obj-pub.$TARGET_FILE.h
-	fi
-}
-
-do_install_append() {
-	# we don't have common lisp in OE
-	rm -rf "${D}${datadir}/common-lisp/"
-	oe_multilib_header gpg-error.h gpgrt.h
-}
-
-FILES_${PN}-dev += "${bindir}/gpg-error"
-FILES_${PN}-doc += "${datadir}/libgpg-error/errorref.txt"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/libgpg-error/libgpg-error_1.32.bb b/poky/meta/recipes-support/libgpg-error/libgpg-error_1.32.bb
new file mode 100644
index 0000000..e552001
--- /dev/null
+++ b/poky/meta/recipes-support/libgpg-error/libgpg-error_1.32.bb
@@ -0,0 +1,71 @@
+SUMMARY = "Small library that defines common error values for all GnuPG components"
+HOMEPAGE = "http://www.gnupg.org/related_software/libgpg-error/"
+BUGTRACKER = "https://bugs.g10code.com/gnupg/index"
+
+LICENSE = "GPLv2+ & LGPLv2.1+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
+                    file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1 \
+                    file://src/gpg-error.h.in;beginline=2;endline=18;md5=524d4e810c4dcdc38e4fa28e70a13bf8 \
+                    file://src/init.c;beginline=2;endline=17;md5=f01cdfcf747af5380590cfd9bbfeaaf7"
+
+
+SECTION = "libs"
+
+UPSTREAM_CHECK_URI = "https://gnupg.org/download/index.html"
+SRC_URI = "${GNUPG_MIRROR}/libgpg-error/libgpg-error-${PV}.tar.bz2 \
+           file://pkgconfig.patch \
+           file://0001-syscfg-Support-ARC-CPUs-and-simplify-aliasing-table.patch \
+           file://0002-syscfg-Add-support-for-arc-unknown-linux-gnu.patch \
+	  "
+SRC_URI[md5sum] = "ef3d928a5a453fa701ecc3bb22be1c64"
+SRC_URI[sha256sum] = "c345c5e73cc2332f8d50db84a2280abfb1d8f6d4f1858b9daa30404db44540ca"
+
+BINCONFIG = "${bindir}/gpg-error-config"
+
+inherit autotools binconfig-disabled pkgconfig gettext multilib_header multilib_script
+
+MULTILIB_SCRIPTS = "${PN}-dev:${bindir}/gpgrt-config"
+
+CPPFLAGS += "-P"
+do_compile_prepend() {
+	TARGET_FILE=linux-gnu
+	if [ ${TARGET_OS} = "mingw32" ]; then
+		# There are no arch specific syscfg files for mingw32
+		TARGET_FILE=
+	elif [ ${TARGET_ARCH} = "arc" ]; then
+		# ARC syscfg file is automatically aliased to i686-pc-linux-gnu
+		TARGET_FILE=
+	elif [ ${TARGET_OS} != "linux" ]; then
+		TARGET_FILE=${TARGET_OS}
+	fi
+
+	case ${TARGET_ARCH} in
+	  aarch64_be) TUPLE=aarch64-unknown-linux-gnu ;;
+	  arm)	      TUPLE=arm-unknown-linux-gnueabi ;;
+	  armeb)      TUPLE=arm-unknown-linux-gnueabi ;;
+	  i586|i686)  TUPLE=i686-unknown-linux-gnu;;
+	  mips64*)    TUPLE=mips64el-unknown-linux-gnuabi64 ;;
+	  mips*el)    TUPLE=mipsel-unknown-linux-gnu ;;
+	  mips*)      TUPLE=mips-unknown-linux-gnu ;;
+	  x86_64)     TUPLE=x86_64-unknown-linux-gnu ;;
+	  ppc64)      TUPLE=powerpc64-unknown-linux-gnu ;;
+	  ppc64le)    TUPLE=powerpc64le-unknown-linux-gnu ;;
+	  *)          TUPLE=${TARGET_ARCH}-unknown-linux-gnu ;;
+	esac
+
+	if [ -n "$TARGET_FILE" ]; then
+		cp ${S}/src/syscfg/lock-obj-pub.$TUPLE.h \
+			${S}/src/syscfg/lock-obj-pub.$TARGET_FILE.h
+	fi
+}
+
+do_install_append() {
+	# we don't have common lisp in OE
+	rm -rf "${D}${datadir}/common-lisp/"
+	oe_multilib_header gpg-error.h gpgrt.h
+}
+
+FILES_${PN}-dev += "${bindir}/gpg-error"
+FILES_${PN}-doc += "${datadir}/libgpg-error/errorref.txt"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/libical/libical_2.0.0.bb b/poky/meta/recipes-support/libical/libical_2.0.0.bb
index dcc21cc..daa47ab 100644
--- a/poky/meta/recipes-support/libical/libical_2.0.0.bb
+++ b/poky/meta/recipes-support/libical/libical_2.0.0.bb
@@ -17,3 +17,10 @@
 UPSTREAM_CHECK_URI = "https://github.com/libical/libical/releases"
 
 inherit cmake pkgconfig
+
+do_install_append_class-target () {
+    # Remove build host references
+    sed -i \
+       -e 's,${STAGING_LIBDIR},${libdir},g' \
+       ${D}${libdir}/cmake/LibIcal/LibIcalTargets-noconfig.cmake
+}
diff --git a/poky/meta/recipes-support/libpcre/libpcre2_10.30.bb b/poky/meta/recipes-support/libpcre/libpcre2_10.30.bb
deleted file mode 100644
index 46c2d63..0000000
--- a/poky/meta/recipes-support/libpcre/libpcre2_10.30.bb
+++ /dev/null
@@ -1,61 +0,0 @@
-DESCRIPTION = "There are two major versions of the PCRE library. The \
-newest version is PCRE2, which is a re-working of the original PCRE \
-library to provide an entirely new API. The original, very widely \
-deployed PCRE library's API and feature are stable, future releases \
- will be for bugfixes only. All new future features will be to PCRE2, \
-not the original PCRE 8.x series."
-SUMMARY = "Perl Compatible Regular Expressions version 2"
-HOMEPAGE = "http://www.pcre.org"
-SECTION = "devel"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://LICENCE;md5=12d55e15a0c6da5c645ba40382bd3293"
-
-SRC_URI = "https://ftp.pcre.org/pub/pcre/pcre2-${PV}.tar.bz2 \
-           file://pcre-cross.patch \
-"
-
-SRC_URI[md5sum] = "d3adf4b130eed854a530390f00020a65"
-SRC_URI[sha256sum] = "90bd41c605d30e3745771eb81928d779f158081a51b2f314bbcc1f73de5773db"
-
-CVE_PRODUCT = "pcre2"
-
-S = "${WORKDIR}/pcre2-${PV}"
-
-PROVIDES += "pcre2"
-DEPENDS += "bzip2 zlib"
-
-BINCONFIG = "${bindir}/pcre2-config"
-
-inherit autotools binconfig-disabled
-
-EXTRA_OECONF = "\
-    --enable-newline-is-lf \
-    --enable-rebuild-chartables \
-    --with-link-size=2 \
-    --with-match-limit=10000000 \
-    --enable-pcre2-16 \
-    --enable-pcre2-32 \
-"
-# Set LINK_SIZE in BUILD_CFLAGS given that the autotools bbclass use it to
-# set CFLAGS_FOR_BUILD, required for the libpcre build.
-BUILD_CFLAGS =+ "-DLINK_SIZE=2 -I${B}/src"
-CFLAGS += "-D_REENTRANT"
-CXXFLAGS_append_powerpc = " -lstdc++"
-
-export CCLD_FOR_BUILD ="${BUILD_CCLD}"
-
-PACKAGES =+ "libpcre2-16 libpcre2-32 pcre2grep pcre2grep-doc pcre2test pcre2test-doc"
-
-SUMMARY_pcre2grep = "grep utility that uses perl 5 compatible regexes"
-SUMMARY_pcre2grep-doc = "grep utility that uses perl 5 compatible regexes - docs"
-SUMMARY_pcre2test = "program for testing Perl-comatible regular expressions"
-SUMMARY_pcre2test-doc = "program for testing Perl-comatible regular expressions - docs"
-
-FILES_libpcre2-16 = "${libdir}/libpcre2-16.so.*"
-FILES_libpcre2-32 = "${libdir}/libpcre2-32.so.*"
-FILES_pcre2grep = "${bindir}/pcre2grep"
-FILES_pcre2grep-doc = "${mandir}/man1/pcre2grep.1"
-FILES_pcre2test = "${bindir}/pcre2test"
-FILES_pcre2test-doc = "${mandir}/man1/pcre2test.1"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/libpcre/libpcre2_10.31.bb b/poky/meta/recipes-support/libpcre/libpcre2_10.31.bb
new file mode 100644
index 0000000..a10c312
--- /dev/null
+++ b/poky/meta/recipes-support/libpcre/libpcre2_10.31.bb
@@ -0,0 +1,61 @@
+DESCRIPTION = "There are two major versions of the PCRE library. The \
+newest version is PCRE2, which is a re-working of the original PCRE \
+library to provide an entirely new API. The original, very widely \
+deployed PCRE library's API and feature are stable, future releases \
+ will be for bugfixes only. All new future features will be to PCRE2, \
+not the original PCRE 8.x series."
+SUMMARY = "Perl Compatible Regular Expressions version 2"
+HOMEPAGE = "http://www.pcre.org"
+SECTION = "devel"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://LICENCE;md5=f5e4bde9fd0493d0967b4dba9899590f"
+
+SRC_URI = "https://ftp.pcre.org/pub/pcre/pcre2-${PV}.tar.bz2 \
+           file://pcre-cross.patch \
+"
+
+SRC_URI[md5sum] = "e0b91c891a3c49050f7fd15de33d0ba4"
+SRC_URI[sha256sum] = "e07d538704aa65e477b6a392b32ff9fc5edf75ab9a40ddfc876186c4ff4d68ac"
+
+CVE_PRODUCT = "pcre2"
+
+S = "${WORKDIR}/pcre2-${PV}"
+
+PROVIDES += "pcre2"
+DEPENDS += "bzip2 zlib"
+
+BINCONFIG = "${bindir}/pcre2-config"
+
+inherit autotools binconfig-disabled
+
+EXTRA_OECONF = "\
+    --enable-newline-is-lf \
+    --enable-rebuild-chartables \
+    --with-link-size=2 \
+    --with-match-limit=10000000 \
+    --enable-pcre2-16 \
+    --enable-pcre2-32 \
+"
+# Set LINK_SIZE in BUILD_CFLAGS given that the autotools bbclass use it to
+# set CFLAGS_FOR_BUILD, required for the libpcre build.
+BUILD_CFLAGS =+ "-DLINK_SIZE=2 -I${B}/src"
+CFLAGS += "-D_REENTRANT"
+CXXFLAGS_append_powerpc = " -lstdc++"
+
+export CCLD_FOR_BUILD ="${BUILD_CCLD}"
+
+PACKAGES =+ "libpcre2-16 libpcre2-32 pcre2grep pcre2grep-doc pcre2test pcre2test-doc"
+
+SUMMARY_pcre2grep = "grep utility that uses perl 5 compatible regexes"
+SUMMARY_pcre2grep-doc = "grep utility that uses perl 5 compatible regexes - docs"
+SUMMARY_pcre2test = "program for testing Perl-comatible regular expressions"
+SUMMARY_pcre2test-doc = "program for testing Perl-comatible regular expressions - docs"
+
+FILES_libpcre2-16 = "${libdir}/libpcre2-16.so.*"
+FILES_libpcre2-32 = "${libdir}/libpcre2-32.so.*"
+FILES_pcre2grep = "${bindir}/pcre2grep"
+FILES_pcre2grep-doc = "${mandir}/man1/pcre2grep.1"
+FILES_pcre2test = "${bindir}/pcre2test"
+FILES_pcre2test-doc = "${mandir}/man1/pcre2test.1"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/libpcre/libpcre_8.41.bb b/poky/meta/recipes-support/libpcre/libpcre_8.41.bb
deleted file mode 100644
index 0187c08..0000000
--- a/poky/meta/recipes-support/libpcre/libpcre_8.41.bb
+++ /dev/null
@@ -1,87 +0,0 @@
-DESCRIPTION = "The PCRE library is a set of functions that implement regular \
-expression pattern matching using the same syntax and semantics as Perl 5. PCRE \
-has its own native API, as well as a set of wrapper functions that correspond \
-to the POSIX regular expression API."
-SUMMARY = "Perl Compatible Regular Expressions"
-HOMEPAGE = "http://www.pcre.org"
-SECTION = "devel"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://LICENCE;md5=60da32d84d067f53e22071c4ecb4384d"
-SRC_URI = "https://ftp.pcre.org/pub/pcre/pcre-${PV}.tar.bz2 \
-           file://pcre-cross.patch \
-           file://fix-pcre-name-collision.patch \
-           file://run-ptest \
-           file://Makefile \
-"
-
-SRC_URI[md5sum] = "c160d22723b1670447341b08c58981c1"
-SRC_URI[sha256sum] = "e62c7eac5ae7c0e7286db61ff82912e1c0b7a0c13706616e94a7dd729321b530"
-
-CVE_PRODUCT = "pcre"
-
-S = "${WORKDIR}/pcre-${PV}"
-
-PROVIDES += "pcre"
-DEPENDS += "bzip2 zlib"
-
-PACKAGECONFIG ??= "pcre8 unicode-properties"
-
-PACKAGECONFIG[pcre8] = "--enable-pcre8,--disable-pcre8"
-PACKAGECONFIG[pcre16] = "--enable-pcre16,--disable-pcre16"
-PACKAGECONFIG[pcre32] = "--enable-pcre32,--disable-pcre32"
-PACKAGECONFIG[pcretest-readline] = "--enable-pcretest-libreadline,--disable-pcretest-libreadline,readline,"
-PACKAGECONFIG[unicode-properties] = "--enable-unicode-properties,--disable-unicode-properties"
-
-BINCONFIG = "${bindir}/pcre-config"
-
-inherit autotools binconfig-disabled ptest
-
-EXTRA_OECONF = "\
-    --enable-newline-is-lf \
-    --enable-rebuild-chartables \
-    --enable-utf \
-    --with-link-size=2 \
-    --with-match-limit=10000000 \
-"
-
-# Set LINK_SIZE in BUILD_CFLAGS given that the autotools bbclass use it to
-# set CFLAGS_FOR_BUILD, required for the libpcre build.
-BUILD_CFLAGS =+ "-DLINK_SIZE=2 -I${B}"
-CFLAGS += "-D_REENTRANT"
-CXXFLAGS_append_powerpc = " -lstdc++"
-
-export CCLD_FOR_BUILD ="${BUILD_CCLD}"
-
-PACKAGES =+ "libpcrecpp libpcreposix pcregrep pcregrep-doc pcretest pcretest-doc"
-
-SUMMARY_libpcrecpp = "${SUMMARY} - C++ wrapper functions"
-SUMMARY_libpcreposix = "${SUMMARY} - C wrapper functions based on the POSIX regex API"
-SUMMARY_pcregrep = "grep utility that uses perl 5 compatible regexes"
-SUMMARY_pcregrep-doc = "grep utility that uses perl 5 compatible regexes - docs"
-SUMMARY_pcretest = "program for testing Perl-comatible regular expressions"
-SUMMARY_pcretest-doc = "program for testing Perl-comatible regular expressions - docs"
-
-FILES_libpcrecpp = "${libdir}/libpcrecpp.so.*"
-FILES_libpcreposix = "${libdir}/libpcreposix.so.*"
-FILES_pcregrep = "${bindir}/pcregrep"
-FILES_pcregrep-doc = "${mandir}/man1/pcregrep.1"
-FILES_pcretest = "${bindir}/pcretest"
-FILES_pcretest-doc = "${mandir}/man1/pcretest.1"
-
-BBCLASSEXTEND = "native nativesdk"
-
-do_install_ptest() {
-	t=${D}${PTEST_PATH}
-	cp ${WORKDIR}/Makefile $t
-	cp -r ${S}/testdata $t
-	for i in pcre_stringpiece_unittest pcregrep pcretest; \
-	  do cp ${B}/.libs/$i $t; \
-	done
-	for i in RunTest RunGrepTest test-driver; \
-	  do cp ${S}/$i $t; \
-	done
-	# Skip the fr_FR locale test. If the locale fr_FR is found, it is tested.
-	# If not found, the test is skipped. The test program assumes fr_FR is non-UTF-8
-	# locale so the test fails if fr_FR is UTF-8 locale.
-	sed -i -e 's:do3=yes:do3=no:g' ${D}${PTEST_PATH}/RunTest 
-}
diff --git a/poky/meta/recipes-support/libpcre/libpcre_8.42.bb b/poky/meta/recipes-support/libpcre/libpcre_8.42.bb
new file mode 100644
index 0000000..3a488c0
--- /dev/null
+++ b/poky/meta/recipes-support/libpcre/libpcre_8.42.bb
@@ -0,0 +1,87 @@
+DESCRIPTION = "The PCRE library is a set of functions that implement regular \
+expression pattern matching using the same syntax and semantics as Perl 5. PCRE \
+has its own native API, as well as a set of wrapper functions that correspond \
+to the POSIX regular expression API."
+SUMMARY = "Perl Compatible Regular Expressions"
+HOMEPAGE = "http://www.pcre.org"
+SECTION = "devel"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://LICENCE;md5=fc5026403b44c868c25fc9546f7feb05"
+SRC_URI = "https://ftp.pcre.org/pub/pcre/pcre-${PV}.tar.bz2 \
+           file://pcre-cross.patch \
+           file://fix-pcre-name-collision.patch \
+           file://run-ptest \
+           file://Makefile \
+"
+
+SRC_URI[md5sum] = "085b6aa253e0f91cae70b3cdbe8c1ac2"
+SRC_URI[sha256sum] = "2cd04b7c887808be030254e8d77de11d3fe9d4505c39d4b15d2664ffe8bf9301"
+
+CVE_PRODUCT = "pcre"
+
+S = "${WORKDIR}/pcre-${PV}"
+
+PROVIDES += "pcre"
+DEPENDS += "bzip2 zlib"
+
+PACKAGECONFIG ??= "pcre8 unicode-properties"
+
+PACKAGECONFIG[pcre8] = "--enable-pcre8,--disable-pcre8"
+PACKAGECONFIG[pcre16] = "--enable-pcre16,--disable-pcre16"
+PACKAGECONFIG[pcre32] = "--enable-pcre32,--disable-pcre32"
+PACKAGECONFIG[pcretest-readline] = "--enable-pcretest-libreadline,--disable-pcretest-libreadline,readline,"
+PACKAGECONFIG[unicode-properties] = "--enable-unicode-properties,--disable-unicode-properties"
+
+BINCONFIG = "${bindir}/pcre-config"
+
+inherit autotools binconfig-disabled ptest
+
+EXTRA_OECONF = "\
+    --enable-newline-is-lf \
+    --enable-rebuild-chartables \
+    --enable-utf \
+    --with-link-size=2 \
+    --with-match-limit=10000000 \
+"
+
+# Set LINK_SIZE in BUILD_CFLAGS given that the autotools bbclass use it to
+# set CFLAGS_FOR_BUILD, required for the libpcre build.
+BUILD_CFLAGS =+ "-DLINK_SIZE=2 -I${B}"
+CFLAGS += "-D_REENTRANT"
+CXXFLAGS_append_powerpc = " -lstdc++"
+
+export CCLD_FOR_BUILD ="${BUILD_CCLD}"
+
+PACKAGES =+ "libpcrecpp libpcreposix pcregrep pcregrep-doc pcretest pcretest-doc"
+
+SUMMARY_libpcrecpp = "${SUMMARY} - C++ wrapper functions"
+SUMMARY_libpcreposix = "${SUMMARY} - C wrapper functions based on the POSIX regex API"
+SUMMARY_pcregrep = "grep utility that uses perl 5 compatible regexes"
+SUMMARY_pcregrep-doc = "grep utility that uses perl 5 compatible regexes - docs"
+SUMMARY_pcretest = "program for testing Perl-comatible regular expressions"
+SUMMARY_pcretest-doc = "program for testing Perl-comatible regular expressions - docs"
+
+FILES_libpcrecpp = "${libdir}/libpcrecpp.so.*"
+FILES_libpcreposix = "${libdir}/libpcreposix.so.*"
+FILES_pcregrep = "${bindir}/pcregrep"
+FILES_pcregrep-doc = "${mandir}/man1/pcregrep.1"
+FILES_pcretest = "${bindir}/pcretest"
+FILES_pcretest-doc = "${mandir}/man1/pcretest.1"
+
+BBCLASSEXTEND = "native nativesdk"
+
+do_install_ptest() {
+	t=${D}${PTEST_PATH}
+	cp ${WORKDIR}/Makefile $t
+	cp -r ${S}/testdata $t
+	for i in pcre_stringpiece_unittest pcregrep pcretest; \
+	  do cp ${B}/.libs/$i $t; \
+	done
+	for i in RunTest RunGrepTest test-driver; \
+	  do cp ${S}/$i $t; \
+	done
+	# Skip the fr_FR locale test. If the locale fr_FR is found, it is tested.
+	# If not found, the test is skipped. The test program assumes fr_FR is non-UTF-8
+	# locale so the test fails if fr_FR is UTF-8 locale.
+	sed -i -e 's:do3=yes:do3=no:g' ${D}${PTEST_PATH}/RunTest 
+}
diff --git a/poky/meta/recipes-support/libproxy/libproxy_0.4.15.bb b/poky/meta/recipes-support/libproxy/libproxy_0.4.15.bb
index 991c9d8..dd7ad92 100644
--- a/poky/meta/recipes-support/libproxy/libproxy_0.4.15.bb
+++ b/poky/meta/recipes-support/libproxy/libproxy_0.4.15.bb
@@ -22,11 +22,12 @@
 PACKAGECONFIG[gnome3] = "-DWITH_GNOME3=yes,-DWITH_GNOME3=no"
 
 EXTRA_OECMAKE += " \
-    -DWITH_KDE4=no \
+    -DWITH_KDE=no \
     -DWITH_MOZJS=no \
     -DWITH_NM=no \
     -DWITH_PERL=no \
-    -DWITH_PYTHON=no \
+    -DWITH_PYTHON2=no \
+    -DWITH_PYTHON3=no \
     -DWITH_WEBKIT=no \
     -DLIB_INSTALL_DIR=${libdir} \
     -DLIBEXEC_INSTALL_DIR=${libexecdir} \
diff --git a/poky/meta/recipes-support/libsoup/libsoup-2.4_2.60.3.bb b/poky/meta/recipes-support/libsoup/libsoup-2.4_2.60.3.bb
deleted file mode 100644
index e2e7ff4..0000000
--- a/poky/meta/recipes-support/libsoup/libsoup-2.4_2.60.3.bb
+++ /dev/null
@@ -1,35 +0,0 @@
-SUMMARY = "An HTTP library implementation in C"
-HOMEPAGE = "https://wiki.gnome.org/Projects/libsoup"
-BUGTRACKER = "https://bugzilla.gnome.org/"
-SECTION = "x11/gnome/libs"
-LICENSE = "LGPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2"
-
-DEPENDS = "glib-2.0 glib-2.0-native libxml2 sqlite3 intltool-native"
-
-SHRT_VER = "${@d.getVar('PV').split('.')[0]}.${@d.getVar('PV').split('.')[1]}"
-
-SRC_URI = "${GNOME_MIRROR}/libsoup/${SHRT_VER}/libsoup-${PV}.tar.xz"
-
-SRC_URI[md5sum] = "4cf8937d161d3dd71a65f1684e317824"
-SRC_URI[sha256sum] = "1b0dc762f23abe4e0d29b77370e539fd35f31d8e8e0318d6ddccff395be68a22"
-
-S = "${WORKDIR}/libsoup-${PV}"
-
-inherit autotools gettext pkgconfig upstream-version-is-even gobject-introspection gtk-doc
-
-# libsoup-gnome is entirely deprecated and just stubs in 2.42 onwards. Disable by default.
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[gnome] = "--with-gnome,--without-gnome"
-PACKAGECONFIG[gssapi] = "--with-gssapi,--without-gssapi,krb5"
-
-EXTRA_OECONF = "--disable-vala"
-
-# When built without gnome support, libsoup-2.4 will contain only one shared lib
-# and will therefore become subject to renaming by debian.bbclass. Prevent
-# renaming in order to keep the package name consistent regardless of whether
-# gnome support is enabled or disabled.
-DEBIAN_NOAUTONAME_${PN} = "1"
-
-# glib-networking is needed for SSL, proxies, etc.
-RRECOMMENDS_${PN} = "glib-networking"
diff --git a/poky/meta/recipes-support/libsoup/libsoup-2.4_2.62.3.bb b/poky/meta/recipes-support/libsoup/libsoup-2.4_2.62.3.bb
new file mode 100644
index 0000000..aaa3cc5
--- /dev/null
+++ b/poky/meta/recipes-support/libsoup/libsoup-2.4_2.62.3.bb
@@ -0,0 +1,34 @@
+SUMMARY = "An HTTP library implementation in C"
+HOMEPAGE = "https://wiki.gnome.org/Projects/libsoup"
+BUGTRACKER = "https://bugzilla.gnome.org/"
+SECTION = "x11/gnome/libs"
+LICENSE = "LGPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2"
+
+DEPENDS = "glib-2.0 glib-2.0-native libxml2 sqlite3 intltool-native"
+
+SHRT_VER = "${@d.getVar('PV').split('.')[0]}.${@d.getVar('PV').split('.')[1]}"
+
+SRC_URI = "${GNOME_MIRROR}/libsoup/${SHRT_VER}/libsoup-${PV}.tar.xz"
+SRC_URI[md5sum] = "dfbf30af5fb6190bfafc5aa6abcc9dce"
+SRC_URI[sha256sum] = "d312ade547495c2093ff8bda61f9b9727a98cfdae339f3263277dd39c0451172"
+
+S = "${WORKDIR}/libsoup-${PV}"
+
+inherit autotools gettext pkgconfig upstream-version-is-even gobject-introspection gtk-doc
+
+# libsoup-gnome is entirely deprecated and just stubs in 2.42 onwards. Disable by default.
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[gnome] = "--with-gnome,--without-gnome"
+PACKAGECONFIG[gssapi] = "--with-gssapi,--without-gssapi,krb5"
+
+EXTRA_OECONF = "--disable-vala"
+
+# When built without gnome support, libsoup-2.4 will contain only one shared lib
+# and will therefore become subject to renaming by debian.bbclass. Prevent
+# renaming in order to keep the package name consistent regardless of whether
+# gnome support is enabled or disabled.
+DEBIAN_NOAUTONAME_${PN} = "1"
+
+# glib-networking is needed for SSL, proxies, etc.
+RRECOMMENDS_${PN} = "glib-networking"
diff --git a/poky/meta/recipes-support/libunistring/libunistring_0.9.10.bb b/poky/meta/recipes-support/libunistring/libunistring_0.9.10.bb
new file mode 100644
index 0000000..97fac4e
--- /dev/null
+++ b/poky/meta/recipes-support/libunistring/libunistring_0.9.10.bb
@@ -0,0 +1,30 @@
+SUMMARY = "Library for manipulating C and Unicode strings"
+
+DESCRIPTION = "Text files are nowadays usually encoded in Unicode, and may\
+ consist of very different scripts from Latin letters to Chinese Hanzi\
+ with many kinds of special characters accents, right-to-left writing\
+ marks, hyphens, Roman numbers, and much more. But the POSIX platform\
+ APIs for text do not contain adequate functions for dealing with\
+ particular properties of many Unicode characters. In fact, the POSIX\
+ APIs for text have several assumptions at their base which don't hold\
+ for Unicode text.  This library provides functions for manipulating\
+ Unicode strings and for manipulating C strings according to the Unicode\
+ standard.  This package contains documentation."
+
+HOMEPAGE = "http://www.gnu.org/software/libunistring/"
+SECTION = "devel"
+LICENSE = "LGPLv3+ | GPLv2"
+LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=6a6a8e020838b23406c81b19c1d46df6 \
+                    file://README;beginline=45;endline=65;md5=08287d16ba8d839faed8d2dc14d7d6a5 \
+                    file://doc/libunistring.texi;md5=287fa6075f78a3c85c1a52b0a92547cd \
+                   "
+
+SRC_URI = "${GNU_MIRROR}/libunistring/libunistring-${PV}.tar.gz \
+           file://iconv-m4-remove-the-test-to-convert-euc-jp.patch \
+           file://0001-Unset-need_charset_alias-when-building-for-musl.patch \
+"
+SRC_URI[md5sum] = "0d3274e9838396b12200f8b54ddaf43b"
+SRC_URI[sha256sum] = "a82e5b333339a88ea4608e4635479a1cfb2e01aafb925e1290b65710d43f610b"
+
+inherit autotools texinfo
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/libunistring/libunistring_0.9.9.bb b/poky/meta/recipes-support/libunistring/libunistring_0.9.9.bb
deleted file mode 100644
index ab7cba5..0000000
--- a/poky/meta/recipes-support/libunistring/libunistring_0.9.9.bb
+++ /dev/null
@@ -1,30 +0,0 @@
-SUMMARY = "Library for manipulating C and Unicode strings"
-
-DESCRIPTION = "Text files are nowadays usually encoded in Unicode, and may\
- consist of very different scripts from Latin letters to Chinese Hanzi\
- with many kinds of special characters accents, right-to-left writing\
- marks, hyphens, Roman numbers, and much more. But the POSIX platform\
- APIs for text do not contain adequate functions for dealing with\
- particular properties of many Unicode characters. In fact, the POSIX\
- APIs for text have several assumptions at their base which don't hold\
- for Unicode text.  This library provides functions for manipulating\
- Unicode strings and for manipulating C strings according to the Unicode\
- standard.  This package contains documentation."
-
-HOMEPAGE = "http://www.gnu.org/software/libunistring/"
-SECTION = "devel"
-LICENSE = "LGPLv3+ | GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=6a6a8e020838b23406c81b19c1d46df6 \
-                    file://README;beginline=45;endline=65;md5=08287d16ba8d839faed8d2dc14d7d6a5 \
-                    file://doc/libunistring.texi;md5=efb80a3799a60f95feaf80661d4f204c \
-                   "
-
-SRC_URI = "${GNU_MIRROR}/libunistring/libunistring-${PV}.tar.gz \
-           file://iconv-m4-remove-the-test-to-convert-euc-jp.patch \
-           file://0001-Unset-need_charset_alias-when-building-for-musl.patch \
-"
-SRC_URI[md5sum] = "4f689e37e4c3bd67de5786aa51d98b13"
-SRC_URI[sha256sum] = "f5e90c08f9e5427ca3a2c0c53f19aa38b25c500913510ad25afef86448bea84a"
-
-inherit autotools texinfo
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/libunwind/libunwind.inc b/poky/meta/recipes-support/libunwind/libunwind.inc
index b9c532d..36851d0 100644
--- a/poky/meta/recipes-support/libunwind/libunwind.inc
+++ b/poky/meta/recipes-support/libunwind/libunwind.inc
@@ -14,8 +14,6 @@
 EXTRA_OECONF_arm = "--enable-debug-frame"
 EXTRA_OECONF_aarch64 = "--enable-debug-frame"
 
-SECURITY_LDFLAGS_append_libc-musl = " -lssp_nonshared -lssp"
-
 do_install_append () {
 	oe_multilib_header libunwind.h
 }
diff --git a/poky/meta/recipes-support/libunwind/libunwind_1.2.1.bb b/poky/meta/recipes-support/libunwind/libunwind_1.2.1.bb
index 37a7624..e7fb2b2 100644
--- a/poky/meta/recipes-support/libunwind/libunwind_1.2.1.bb
+++ b/poky/meta/recipes-support/libunwind/libunwind_1.2.1.bb
@@ -21,3 +21,5 @@
 ARM_INSTRUCTION_SET_armv5 = "arm"
 
 LDFLAGS += "-Wl,-z,relro,-z,now ${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-gold', ' -fuse-ld=bfd ', '', d)}"
+
+SECURITY_LDFLAGS_append_libc-musl = " -lssp_nonshared"
diff --git a/poky/meta/recipes-support/liburcu/files/Add-support-for-the-RISC-V-architecture.patch b/poky/meta/recipes-support/liburcu/files/Add-support-for-the-RISC-V-architecture.patch
new file mode 100644
index 0000000..b026782
--- /dev/null
+++ b/poky/meta/recipes-support/liburcu/files/Add-support-for-the-RISC-V-architecture.patch
@@ -0,0 +1,157 @@
+From fdfad81006c2c964781b616f0a75578507be809c Mon Sep 17 00:00:00 2001
+From: Michael Jeanson <mjeanson@efficios.com>
+Date: Wed, 21 Mar 2018 17:38:41 -0400
+Subject: [PATCH] Add support for the RISC-V architecture
+
+Tested in QEMU 2.12.0-rc0, requires --disable-compiler-tls to go
+through the benchmarks reliably.
+
+Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
+Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
+Upstream-Status: Backport
+---
+ configure.ac                 |  1 +
+ include/Makefile.am          |  2 ++
+ include/urcu/arch/riscv.h    | 49 ++++++++++++++++++++++++++++++++++++++++++++
+ include/urcu/uatomic/riscv.h | 44 +++++++++++++++++++++++++++++++++++++++
+ 4 files changed, 96 insertions(+)
+ create mode 100644 include/urcu/arch/riscv.h
+ create mode 100644 include/urcu/uatomic/riscv.h
+
+diff --git a/configure.ac b/configure.ac
+index d0b4a9ac..9145081a 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -151,6 +151,7 @@ AS_CASE([$host_cpu],
+ 	[tile*], [ARCHTYPE="tile"],
+ 	[hppa*], [ARCHTYPE="hppa"],
+ 	[m68k], [ARCHTYPE="m68k"],
++	[riscv*], [ARCHTYPE="riscv"],
+ 	[ARCHTYPE="unknown"]
+ )
+ 
+diff --git a/include/Makefile.am b/include/Makefile.am
+index dcdf304b..36667b43 100644
+--- a/include/Makefile.am
++++ b/include/Makefile.am
+@@ -27,6 +27,7 @@ EXTRA_DIST = urcu/arch/aarch64.h \
+ 	urcu/arch/mips.h \
+ 	urcu/arch/nios2.h \
+ 	urcu/arch/ppc.h \
++	urcu/arch/riscv.h \
+ 	urcu/arch/s390.h \
+ 	urcu/arch/sparc64.h \
+ 	urcu/arch/tile.h \
+@@ -43,6 +44,7 @@ EXTRA_DIST = urcu/arch/aarch64.h \
+ 	urcu/uatomic/mips.h \
+ 	urcu/uatomic/nios2.h \
+ 	urcu/uatomic/ppc.h \
++	urcu/uatomic/riscv.h \
+ 	urcu/uatomic/s390.h \
+ 	urcu/uatomic/sparc64.h \
+ 	urcu/uatomic/tile.h \
+diff --git a/include/urcu/arch/riscv.h b/include/urcu/arch/riscv.h
+new file mode 100644
+index 00000000..1fd7d62b
+--- /dev/null
++++ b/include/urcu/arch/riscv.h
+@@ -0,0 +1,49 @@
++#ifndef _URCU_ARCH_RISCV_H
++#define _URCU_ARCH_RISCV_H
++
++/*
++ * arch/riscv.h: definitions for the RISC-V architecture
++ *
++ * Copyright (c) 2018 Michael Jeanson <mjeanson@efficios.com>
++ *
++ * This library is free software; you can redistribute it and/or
++ * modify it under the terms of the GNU Lesser General Public
++ * License as published by the Free Software Foundation; either
++ * version 2.1 of the License, or (at your option) any later version.
++ *
++ * This library is distributed in the hope that it will be useful,
++ * but WITHOUT ANY WARRANTY; without even the implied warranty of
++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
++ * Lesser General Public License for more details.
++ *
++ * You should have received a copy of the GNU Lesser General Public
++ * License along with this library; if not, write to the Free Software
++ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
++ */
++
++#include <urcu/compiler.h>
++#include <urcu/config.h>
++#include <urcu/syscall-compat.h>
++
++#ifdef __cplusplus
++extern "C" {
++#endif
++
++#include <stdlib.h>
++#include <sys/time.h>
++
++/*
++ * On Linux, define the membarrier system call number if not yet available in
++ * the system headers.
++ */
++#if (defined(__linux__) && !defined(__NR_membarrier))
++#define __NR_membarrier		283
++#endif
++
++#ifdef __cplusplus
++}
++#endif
++
++#include <urcu/arch/generic.h>
++
++#endif /* _URCU_ARCH_RISCV_H */
+diff --git a/include/urcu/uatomic/riscv.h b/include/urcu/uatomic/riscv.h
+new file mode 100644
+index 00000000..a6700e17
+--- /dev/null
++++ b/include/urcu/uatomic/riscv.h
+@@ -0,0 +1,44 @@
++/*
++ * Atomic exchange operations for the RISC-V architecture. Let GCC do it.
++ *
++ * Copyright (c) 2018 Michael Jeanson <mjeanson@efficios.com>
++ *
++ * Permission is hereby granted, free of charge, to any person obtaining a copy
++ * of this software and associated documentation files (the "Software"), to
++ * deal in the Software without restriction, including without limitation the
++ * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
++ * sell copies of the Software, and to permit persons to whom the Software is
++ * furnished to do so, subject to the following conditions:
++ *
++ * The above copyright notice and this permission notice shall be included in
++ * all copies or substantial portions of the Software.
++ *
++ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
++ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
++ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
++ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
++ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
++ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
++ * IN THE SOFTWARE.
++ */
++
++#ifndef _URCU_ARCH_UATOMIC_RISCV_H
++#define _URCU_ARCH_UATOMIC_RISCV_H
++
++#include <urcu/compiler.h>
++#include <urcu/system.h>
++
++#ifdef __cplusplus
++extern "C" {
++#endif
++
++#define UATOMIC_HAS_ATOMIC_BYTE
++#define UATOMIC_HAS_ATOMIC_SHORT
++
++#ifdef __cplusplus
++}
++#endif
++
++#include <urcu/uatomic/generic.h>
++
++#endif /* _URCU_ARCH_UATOMIC_RISCV_H */
diff --git a/poky/meta/recipes-support/liburcu/liburcu_0.10.1.bb b/poky/meta/recipes-support/liburcu/liburcu_0.10.1.bb
index 459c04a..5eb91e1 100644
--- a/poky/meta/recipes-support/liburcu/liburcu_0.10.1.bb
+++ b/poky/meta/recipes-support/liburcu/liburcu_0.10.1.bb
@@ -8,12 +8,17 @@
                     file://include/urcu/uatomic/x86.h;beginline=4;endline=21;md5=58e50bbd8a2f073bb5500e6554af0d0b"
 
 SRC_URI = "http://lttng.org/files/urcu/userspace-rcu-${PV}.tar.bz2 \
+           file://Add-support-for-the-RISC-V-architecture.patch \
            "
 
 SRC_URI[md5sum] = "281a2f92fdc39c40ad6b76f6631fdbd7"
 SRC_URI[sha256sum] = "9c09220be4435dc27fcd22d291707b94b97f159e0c442fbcd60c168f8f79eb06"
 
 S = "${WORKDIR}/userspace-rcu-${PV}"
-inherit autotools
+inherit autotools multilib_header
 
 CPPFLAGS_append_riscv64  = " -pthread -D_REENTRANT"
+
+do_install_append() {
+    oe_multilib_header urcu/config.h
+}
diff --git a/poky/meta/recipes-support/libusb/libusb1/run-ptest b/poky/meta/recipes-support/libusb/libusb1/run-ptest
new file mode 100755
index 0000000..eaa47a2
--- /dev/null
+++ b/poky/meta/recipes-support/libusb/libusb1/run-ptest
@@ -0,0 +1,29 @@
+#!/bin/sh
+
+echo
+echo "---------------------------- libusb1 tests ---------------------------"
+echo
+
+./stress | { \
+while read -r str
+do
+	echo "$str"
+	if [ "${str#*Starting test run:}" != "$str" ]
+	then
+		name="${str#Starting test run: }"
+		name="${name%...}"
+	else
+		case "$str" in
+			"Success (0)")
+				echo "PASS: $name"
+			;;
+			"Failure (1)" | "Error (2)")
+				echo "FAIL: $name"
+			;;
+			"Skip (3)")
+				echo "SKIP: $name"
+			;;
+		esac
+	fi
+done
+}
diff --git a/poky/meta/recipes-support/libusb/libusb1_1.0.21.bb b/poky/meta/recipes-support/libusb/libusb1_1.0.21.bb
deleted file mode 100644
index 1fefd14..0000000
--- a/poky/meta/recipes-support/libusb/libusb1_1.0.21.bb
+++ /dev/null
@@ -1,35 +0,0 @@
-SUMMARY = "Userspace library to access USB (version 1.0)"
-HOMEPAGE = "http://libusb.sf.net"
-BUGTRACKER = "http://www.libusb.org/report"
-SECTION = "libs"
-
-LICENSE = "LGPLv2.1+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=fbc093901857fcd118f065f900982c24"
-
-BBCLASSEXTEND = "native nativesdk"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/libusb/libusb-${PV}.tar.bz2 \
-           file://no-dll.patch \
-          "
-
-SRC_URI[md5sum] = "1da9ea3c27b3858fa85c5f4466003e44"
-SRC_URI[sha256sum] = "7dce9cce9a81194b7065ee912bcd55eeffebab694ea403ffb91b67db66b1824b"
-
-S = "${WORKDIR}/libusb-${PV}"
-
-inherit autotools pkgconfig
-
-# Don't configure udev by default since it will cause a circular
-# dependecy with udev package, which depends on libusb
-EXTRA_OECONF = "--libdir=${base_libdir} --disable-udev"
-
-do_install_append() {
-	install -d ${D}${libdir}
-	if [ ! ${D}${libdir} -ef ${D}${base_libdir} ]; then
-		mv ${D}${base_libdir}/pkgconfig ${D}${libdir}
-	fi
-}
-
-FILES_${PN} += "${base_libdir}/*.so.*"
-
-FILES_${PN}-dev += "${base_libdir}/*.so ${base_libdir}/*.la"
diff --git a/poky/meta/recipes-support/libusb/libusb1_1.0.22.bb b/poky/meta/recipes-support/libusb/libusb1_1.0.22.bb
new file mode 100644
index 0000000..0c6e116
--- /dev/null
+++ b/poky/meta/recipes-support/libusb/libusb1_1.0.22.bb
@@ -0,0 +1,44 @@
+SUMMARY = "Userspace library to access USB (version 1.0)"
+HOMEPAGE = "http://libusb.sf.net"
+BUGTRACKER = "http://www.libusb.org/report"
+SECTION = "libs"
+
+LICENSE = "LGPLv2.1+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=fbc093901857fcd118f065f900982c24"
+
+BBCLASSEXTEND = "native nativesdk"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/libusb/libusb-${PV}.tar.bz2 \
+           file://no-dll.patch \
+           file://run-ptest \
+          "
+
+SRC_URI[md5sum] = "466267889daead47674df933cea9cacb"
+SRC_URI[sha256sum] = "75aeb9d59a4fdb800d329a545c2e6799f732362193b465ea198f2aa275518157"
+
+S = "${WORKDIR}/libusb-${PV}"
+
+inherit autotools pkgconfig ptest
+
+# Don't configure udev by default since it will cause a circular
+# dependecy with udev package, which depends on libusb
+EXTRA_OECONF = "--libdir=${base_libdir} --disable-udev"
+
+do_install_append() {
+	install -d ${D}${libdir}
+	if [ ! ${D}${libdir} -ef ${D}${base_libdir} ]; then
+		mv ${D}${base_libdir}/pkgconfig ${D}${libdir}
+	fi
+}
+
+do_compile_ptest() {                                                             
+    oe_runmake -C tests stress                                                   
+}                                                                                
+                                                                                 
+do_install_ptest() {                                                             
+    install -m 755 ${B}/tests/.libs/stress ${D}${PTEST_PATH}         
+}
+
+FILES_${PN} += "${base_libdir}/*.so.*"
+
+FILES_${PN}-dev += "${base_libdir}/*.so ${base_libdir}/*.la"
diff --git a/poky/meta/recipes-support/libxslt/libxslt/fix-rvts-handling.patch b/poky/meta/recipes-support/libxslt/libxslt/fix-rvts-handling.patch
new file mode 100644
index 0000000..ea3ae51
--- /dev/null
+++ b/poky/meta/recipes-support/libxslt/libxslt/fix-rvts-handling.patch
@@ -0,0 +1,80 @@
+libxslt-1.1.32: Fix handling of RVTs returned from nested EXSLT functions
+
+[No upstream tracking] -- https://bugzilla.gnome.org/show_bug.cgi?id=792580
+
+Set the context variable to NULL when evaluating EXSLT functions.
+Fixes potential use-after-free errors or memory leaks.
+
+Upstream-Status: Backport [https://gitlab.gnome.org/GNOME/libxslt/commit/8bd32f7753ac253a54279a0b6a88d15a57076bb0]
+bug: 792580
+Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
+
+diff --git a/libexslt/functions.c b/libexslt/functions.c
+index dc794e3..8511cb0 100644
+--- a/libexslt/functions.c
++++ b/libexslt/functions.c
+@@ -280,6 +280,7 @@ exsltFuncFunctionFunction (xmlXPathParserContextPtr ctxt, int nargs) {
+     exsltFuncFunctionData *func;
+     xmlNodePtr paramNode, oldInsert, fake;
+     int oldBase;
++    void *oldCtxtVar;
+     xsltStackElemPtr params = NULL, param;
+     xsltTransformContextPtr tctxt = xsltXPathGetTransformContext(ctxt);
+     int i, notSet;
+@@ -418,11 +419,14 @@ exsltFuncFunctionFunction (xmlXPathParserContextPtr ctxt, int nargs) {
+     fake = xmlNewDocNode(tctxt->output, NULL,
+ 			 (const xmlChar *)"fake", NULL);
+     oldInsert = tctxt->insert;
++    oldCtxtVar = tctxt->contextVariable;
+     tctxt->insert = fake;
++    tctxt->contextVariable = NULL;
+     xsltApplyOneTemplate (tctxt, tctxt->node,
+ 			  func->content, NULL, NULL);
+     xsltLocalVariablePop(tctxt, tctxt->varsBase, -2);
+     tctxt->insert = oldInsert;
++    tctxt->contextVariable = oldCtxtVar;
+     tctxt->varsBase = oldBase;	/* restore original scope */
+     if (params != NULL)
+ 	xsltFreeStackElemList(params);
+diff --git a/tests/docs/bug-209.xml b/tests/docs/bug-209.xml
+new file mode 100644
+index 0000000..69d62f2
+--- /dev/null
++++ b/tests/docs/bug-209.xml
+@@ -0,0 +1 @@
++<doc/>
+diff --git a/tests/general/bug-209.out b/tests/general/bug-209.out
+new file mode 100644
+index 0000000..e829790
+--- /dev/null
++++ b/tests/general/bug-209.out
+@@ -0,0 +1,2 @@
++<?xml version="1.0"?>
++<result/>
+diff --git a/tests/general/bug-209.xsl b/tests/general/bug-209.xsl
+new file mode 100644
+index 0000000..fe69ac6
+--- /dev/null
++++ b/tests/general/bug-209.xsl
+@@ -0,0 +1,21 @@
++<xsl:stylesheet
++    version="1.0"
++    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
++    xmlns:func="http://exslt.org/functions"
++    extension-element-prefixes="func">
++
++    <xsl:template match="/">
++        <xsl:variable name="v" select="func:a()" />
++        <xsl:copy-of select="$v"/>
++    </xsl:template>
++
++    <func:function name="func:a">
++        <func:result select="func:b()" />
++    </func:function>
++
++    <func:function name="func:b">
++        <func:result>
++            <result/>
++        </func:result>
++    </func:function>
++</xsl:stylesheet>
diff --git a/poky/meta/recipes-support/libxslt/libxslt_1.1.32.bb b/poky/meta/recipes-support/libxslt/libxslt_1.1.32.bb
index 6a03f77..f0fa5e7 100644
--- a/poky/meta/recipes-support/libxslt/libxslt_1.1.32.bb
+++ b/poky/meta/recipes-support/libxslt/libxslt_1.1.32.bb
@@ -8,7 +8,10 @@
 SECTION = "libs"
 DEPENDS = "libxml2"
 
-SRC_URI = "http://xmlsoft.org/sources/libxslt-${PV}.tar.gz"
+SRC_URI = "http://xmlsoft.org/sources/libxslt-${PV}.tar.gz \
+           file://fix-rvts-handling.patch \
+           "
+
 SRC_URI[md5sum] = "1fc72f98e98bf4443f1651165f3aa146"
 SRC_URI[sha256sum] = "526ecd0abaf4a7789041622c3950c0e7f2c4c8835471515fd77eec684a355460"
 
diff --git a/poky/meta/recipes-support/libyaml/libyaml_0.1.7.bb b/poky/meta/recipes-support/libyaml/libyaml_0.1.7.bb
deleted file mode 100644
index b167f03..0000000
--- a/poky/meta/recipes-support/libyaml/libyaml_0.1.7.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-SUMMARY = "LibYAML is a YAML 1.1 parser and emitter written in C."
-DESCRIPTION = "LibYAML is a C library for parsing and emitting data in YAML 1.1, \
-a human-readable data serialization format. "
-HOMEPAGE = "http://pyyaml.org/wiki/LibYAML"
-SECTION = "libs/devel"
-
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=6015f088759b10e0bc2bf64898d4ae17"
-
-SRC_URI = "http://pyyaml.org/download/libyaml/yaml-${PV}.tar.gz \
-          "
-
-SRC_URI[md5sum] = "1abf45bd3a96374fa55ca63b32f9f2f9"
-SRC_URI[sha256sum] = "8088e457264a98ba451a90b8661fcb4f9d6f478f7265d48322a196cec2480729"
-
-S = "${WORKDIR}/yaml-${PV}"
-
-inherit autotools
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/libyaml/libyaml_0.2.1.bb b/poky/meta/recipes-support/libyaml/libyaml_0.2.1.bb
new file mode 100644
index 0000000..d778918
--- /dev/null
+++ b/poky/meta/recipes-support/libyaml/libyaml_0.2.1.bb
@@ -0,0 +1,18 @@
+SUMMARY = "LibYAML is a YAML 1.1 parser and emitter written in C."
+DESCRIPTION = "LibYAML is a C library for parsing and emitting data in YAML 1.1, \
+a human-readable data serialization format. "
+HOMEPAGE = "http://pyyaml.org/wiki/LibYAML"
+SECTION = "libs/devel"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=5591701d32590f9fa94f3bfee820b634"
+
+SRC_URI = "http://pyyaml.org/download/libyaml/yaml-${PV}.tar.gz"
+SRC_URI[md5sum] = "72724b9736923c517e5a8fc6757ef03d"
+SRC_URI[sha256sum] = "78281145641a080fb32d6e7a87b9c0664d611dcb4d542e90baf731f51cbb59cd"
+
+S = "${WORKDIR}/yaml-${PV}"
+
+inherit autotools
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/lz4/files/0001-tests-Makefile-don-t-use-LIBDIR-as-variable.patch b/poky/meta/recipes-support/lz4/files/0001-tests-Makefile-don-t-use-LIBDIR-as-variable.patch
deleted file mode 100644
index 00494e8..0000000
--- a/poky/meta/recipes-support/lz4/files/0001-tests-Makefile-don-t-use-LIBDIR-as-variable.patch
+++ /dev/null
@@ -1,82 +0,0 @@
-From d4768d9e29b805096a86aa13c0d30ee8215af4df Mon Sep 17 00:00:00 2001
-From: Jussi Kukkonen <jussi.kukkonen@intel.com>
-Date: Mon, 26 Jun 2017 12:07:09 +0300
-Subject: [PATCH] tests/Makefile: don't use LIBDIR as variable
-
-LIBDIR may be overriden with a environment variable: In this case make
-clean breaks. Use another variable name.
-
-Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com>
-Upstream-Status: Backport
----
- tests/Makefile | 26 +++++++++++++-------------
- 1 file changed, 13 insertions(+), 13 deletions(-)
-
-diff --git a/tests/Makefile b/tests/Makefile
-index 97fa782..51dd038 100644
---- a/tests/Makefile
-+++ b/tests/Makefile
-@@ -32,7 +32,7 @@ DESTDIR ?=
- PREFIX  ?= /usr/local
- BINDIR  := $(PREFIX)/bin
- MANDIR  := $(PREFIX)/share/man/man1
--LIBDIR  := ../lib
-+LZ4DIR  := ../lib
- PRGDIR  := ../programs
- VOID    := /dev/null
- TESTDIR := versionsTest
-@@ -43,7 +43,7 @@ CFLAGS  += -g -Wall -Wextra -Wundef -Wcast-qual -Wcast-align -Wshadow -Wswitch-e
-            -Wdeclaration-after-statement -Wstrict-prototypes \
-            -Wpointer-arith -Wstrict-aliasing=1
- CFLAGS  += $(MOREFLAGS)
--CPPFLAGS:= -I$(LIBDIR) -I$(PRGDIR) -DXXH_NAMESPACE=LZ4_
-+CPPFLAGS:= -I$(LZ4DIR) -I$(PRGDIR) -DXXH_NAMESPACE=LZ4_
- FLAGS    = $(CFLAGS) $(CPPFLAGS) $(LDFLAGS)
- 
- 
-@@ -79,31 +79,31 @@ lz4c32:   # create a 32-bits version for 32/64 interop tests
- 	$(MAKE) -C $(PRGDIR) clean $@ CFLAGS="-m32 $(CFLAGS)"
- 	cp $(LZ4) $(LZ4)c32
- 
--fullbench  : $(LIBDIR)/lz4.o $(LIBDIR)/lz4hc.o $(LIBDIR)/lz4frame.o $(LIBDIR)/xxhash.o fullbench.c
-+fullbench  : $(LZ4DIR)/lz4.o $(LZ4DIR)/lz4hc.o $(LZ4DIR)/lz4frame.o $(LZ4DIR)/xxhash.o fullbench.c
- 	$(CC) $(FLAGS) $^ -o $@$(EXT)
- 
--fullbench-lib: fullbench.c $(LIBDIR)/xxhash.c
--	$(MAKE) -C $(LIBDIR) liblz4.a
--	$(CC) $(FLAGS) $^ -o $@$(EXT) $(LIBDIR)/liblz4.a
-+fullbench-lib: fullbench.c $(LZ4DIR)/xxhash.c
-+	$(MAKE) -C $(LZ4DIR) liblz4.a
-+	$(CC) $(FLAGS) $^ -o $@$(EXT) $(LZ4DIR)/liblz4.a
- 
--fullbench-dll: fullbench.c $(LIBDIR)/xxhash.c
--	$(MAKE) -C $(LIBDIR) liblz4
--	$(CC) $(FLAGS) $^ -o $@$(EXT) -DLZ4_DLL_IMPORT=1 $(LIBDIR)/dll/liblz4.dll
-+fullbench-dll: fullbench.c $(LZ4DIR)/xxhash.c
-+	$(MAKE) -C $(LZ4DIR) liblz4
-+	$(CC) $(FLAGS) $^ -o $@$(EXT) -DLZ4_DLL_IMPORT=1 $(LZ4DIR)/dll/liblz4.dll
- 
--fuzzer  : $(LIBDIR)/lz4.o $(LIBDIR)/lz4hc.o $(LIBDIR)/xxhash.o fuzzer.c
-+fuzzer  : $(LZ4DIR)/lz4.o $(LZ4DIR)/lz4hc.o $(LZ4DIR)/xxhash.o fuzzer.c
- 	$(CC) $(FLAGS) $^ -o $@$(EXT)
- 
--frametest: $(LIBDIR)/lz4frame.o $(LIBDIR)/lz4.o $(LIBDIR)/lz4hc.o $(LIBDIR)/xxhash.o frametest.c
-+frametest: $(LZ4DIR)/lz4frame.o $(LZ4DIR)/lz4.o $(LZ4DIR)/lz4hc.o $(LZ4DIR)/xxhash.o frametest.c
- 	$(CC) $(FLAGS) $^ -o $@$(EXT)
- 
--fasttest: $(LIBDIR)/lz4.o fasttest.c
-+fasttest: $(LZ4DIR)/lz4.o fasttest.c
- 	$(CC) $(FLAGS) $^ -o $@$(EXT)
- 
- datagen : $(PRGDIR)/datagen.c datagencli.c
- 	$(CC) $(FLAGS) -I$(PRGDIR) $^ -o $@$(EXT)
- 
- clean:
--	@$(MAKE) -C $(LIBDIR) $@ > $(VOID)
-+	@$(MAKE) -C $(LZ4DIR) $@ > $(VOID)
- 	@$(MAKE) -C $(PRGDIR) $@ > $(VOID)
- 	@$(RM) core *.o *.test tmp* \
-         fullbench-dll$(EXT) fullbench-lib$(EXT) \
--- 
-2.1.4
-
diff --git a/poky/meta/recipes-support/lz4/lz4_1.7.4.bb b/poky/meta/recipes-support/lz4/lz4_1.7.4.bb
deleted file mode 100644
index 86a1ab9..0000000
--- a/poky/meta/recipes-support/lz4/lz4_1.7.4.bb
+++ /dev/null
@@ -1,27 +0,0 @@
-SUMMARY = "Extremely Fast Compression algorithm"
-DESCRIPTION = "LZ4 is a very fast lossless compression algorithm, providing compression speed at 400 MB/s per core, scalable with multi-cores CPU. It also features an extremely fast decoder, with speed in multiple GB/s per core, typically reaching RAM speed limits on multi-core systems."
-
-LICENSE = "BSD | BSD-2-Clause | GPL-2.0"
-LIC_FILES_CHKSUM = "file://lib/LICENSE;md5=ebc2ea4814a64de7708f1571904b32cc\
-                    file://programs/COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
-                    file://LICENSE;md5=7f2857d58beff6d04137bf9b09e5ffb6"
-
-PE = "1"
-
-SRCREV = "7bb64ff2b69a9f8367de9ab483cdadf42b4c1b65"
-
-SRC_URI = "git://github.com/lz4/lz4.git \
-           file://0001-tests-Makefile-don-t-use-LIBDIR-as-variable.patch \
-           file://run-ptest \
-"
-UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>.*)"
-
-S = "${WORKDIR}/git"
-
-EXTRA_OEMAKE = "PREFIX=${prefix} CC='${CC}' DESTDIR=${D} LIBDIR=${libdir} INCLUDEDIR=${includedir}"
-
-do_install() {
-	oe_runmake install
-}
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/lz4/lz4_1.8.2.bb b/poky/meta/recipes-support/lz4/lz4_1.8.2.bb
new file mode 100644
index 0000000..5ad17e1
--- /dev/null
+++ b/poky/meta/recipes-support/lz4/lz4_1.8.2.bb
@@ -0,0 +1,27 @@
+SUMMARY = "Extremely Fast Compression algorithm"
+DESCRIPTION = "LZ4 is a very fast lossless compression algorithm, providing compression speed at 400 MB/s per core, scalable with multi-cores CPU. It also features an extremely fast decoder, with speed in multiple GB/s per core, typically reaching RAM speed limits on multi-core systems."
+
+LICENSE = "BSD | BSD-2-Clause | GPL-2.0"
+LIC_FILES_CHKSUM = "file://lib/LICENSE;md5=ebc2ea4814a64de7708f1571904b32cc \
+                    file://programs/COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                    file://LICENSE;md5=d57c0d21cb917fb4e0af2454aa48b956 \
+                    "
+
+PE = "1"
+
+SRCREV = "b3692db46d2b23a7c0af2d5e69988c94f126e10a"
+
+SRC_URI = "git://github.com/lz4/lz4.git \
+           file://run-ptest \
+           "
+UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>.*)"
+
+S = "${WORKDIR}/git"
+
+EXTRA_OEMAKE = "PREFIX=${prefix} CC='${CC}' DESTDIR=${D} LIBDIR=${libdir} INCLUDEDIR=${includedir}"
+
+do_install() {
+	oe_runmake install
+}
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/mpfr/mpfr/0001-Fix-obsolete-ARC-asm-constraints.patch b/poky/meta/recipes-support/mpfr/mpfr/0001-Fix-obsolete-ARC-asm-constraints.patch
new file mode 100644
index 0000000..59d1b0d
--- /dev/null
+++ b/poky/meta/recipes-support/mpfr/mpfr/0001-Fix-obsolete-ARC-asm-constraints.patch
@@ -0,0 +1,45 @@
+mpfr-longlong.h: Fix obsolete ARC asm constraints
+
+This patch replaces obsolete ARC "J" asm constraint with
+up-to-date "Cal" constraint.
+
+"J" constraint only existed in pre-upstream GCC port for ARC.
+In current upstream port "Cal" constraint is used which leads
+to compile-time error.
+
+Proposed fix is known to work in Buildroot, Crosstool-NG etc.
+
+[1] https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=09cb6a17e71bd40d2fbfaf82a1502fc210e33c87
+
+Signed-off-by: Claudiu Zissulescu <claziss@synopsys.com>
+Signed-off-by: Vlad Zakharov <vzakhar@synopsys.com>
+Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
+
+Upstream-Status: Backport [https://gforge.inria.fr/scm/viewvc.php/mpfr?view=revision&revision=13251]
+---
+Index: src/mpfr-longlong.h
+===================================================================
+--- a/src/mpfr-longlong.h	(revision 10963)
++++ b/src/mpfr-longlong.h	(working copy)
+@@ -416,17 +416,17 @@
+ 	   : "=r" (sh),							\
+ 	     "=&r" (sl)							\
+ 	   : "r"  ((USItype) (ah)),					\
+-	     "rIJ" ((USItype) (bh)),					\
++	     "rICal" ((USItype) (bh)),					\
+ 	     "%r" ((USItype) (al)),					\
+-	     "rIJ" ((USItype) (bl)))
++	     "rICal" ((USItype) (bl)))
+ #define sub_ddmmss(sh, sl, ah, al, bh, bl) \
+   __asm__ ("sub.f\t%1, %4, %5\n\tsbc\t%0, %2, %3"			\
+ 	   : "=r" (sh),							\
+ 	     "=&r" (sl)							\
+ 	   : "r" ((USItype) (ah)),					\
+-	     "rIJ" ((USItype) (bh)),					\
++	     "rICal" ((USItype) (bh)),					\
+ 	     "r" ((USItype) (al)),					\
+-	     "rIJ" ((USItype) (bl)))
++	     "rICal" ((USItype) (bl)))
+ #endif
+ 
+ #if defined (__arm__) && (defined (__thumb2__) || !defined (__thumb__)) \
diff --git a/poky/meta/recipes-support/mpfr/mpfr/long-long-thumb.patch b/poky/meta/recipes-support/mpfr/mpfr/long-long-thumb.patch
deleted file mode 100644
index ca7100e..0000000
--- a/poky/meta/recipes-support/mpfr/mpfr/long-long-thumb.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From 84021b1e236508169be65e802a9c0a25fc9a8827 Mon Sep 17 00:00:00 2001
-From: Phil Blundell <philb@gnu.org>
-Date: Mon, 27 Oct 2008 22:26:35 +0000
-Subject: [PATCH] mpfr: crusade against inline assembler
-
-Without this, build fails for thumb:
-| {standard input}: Assembler messages:
-| {standard input}:199: Error: selected processor does not support Thumb mode `umull sl,r0,r2,r1'
-| {standard input}:214: Error: selected processor does not support Thumb mode `umull sl,r2,r1,fp'
-| {standard input}:219: Error: instruction not supported in Thumb16 mode -- `adds fp,r0,sl'
-| {standard input}:220: Error: unshifted register required -- `adc r2,r2,#0'
-| {standard input}:235: Error: selected processor does not support Thumb mode `umull r0,sl,r1,r3'
-| {standard input}:244: Error: selected processor does not support Thumb mode `umull fp,ip,r1,r3'
-| {standard input}:253: Error: instruction not supported in Thumb16 mode -- `adds r3,sl,fp'
-| {standard input}:254: Error: unshifted register required -- `adc ip,ip,#0'
-| {standard input}:259: Error: instruction not supported in Thumb16 mode -- `adds sl,r1,r0'
-| {standard input}:642: Error: selected processor does not support Thumb mode `umull r0,r2,r3,r1'
-| ../arm-oe-linux-gnueabi-libtool --tag=CC   --mode=compile arm-oe-linux-gnueabi-gcc  -march=armv5te  -mthumb -mthumb-interwork  -mtune=xscale --sysroot=/OE/shr-core/tmp-eglibc/sysroots/spitz -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DTIME_WITH_SYS_TIME=1 -DHAVE_LOCALE_H=1 -DHAVE_WCHAR_H=1 -DHAVE_STDARG=1 -DHAVE_SYS_TIME_H=1 -DHAVE_ALLOCA_H=1 -DHAVE_STDINT_H=1 -DHAVE_VA_COPY=1 -DHAVE_SETLOCALE=1 -DHAVE_GETTIMEOFDAY=1 -DHAVE_LONG_LONG=1 -DHAVE_INTMAX_T=1 -DMPFR_HAVE_INTMAX_MAX=1 -DMPFR_HAVE_FESETROUND=1 -DHAVE_ROUND=1 -DHAVE_TRUNC=1 -DHAVE_FLOOR=1 -DHAVE_CEIL=1 -DHAVE_NEARBYINT=1 -DLT_OBJDIR=\".libs/\" -DHAVE_ATTRIBUTE_MODE=1 -DHAVE___GMPN_ROOTREM=1 -DHAVE___GMPN_SBPI1_DIVAPPR_Q=1 -I.     -O2 -pipe -g -feliminate-unused-debug-types -ffloat-store -c -o pow.lo pow.c
-| {standard input}:1154: Error: selected processor does not support Thumb mode `umull r0,r1,sl,ip'
-| {standard input}:1166: Error: selected processor does not support Thumb mode `umull r3,r2,ip,r0'
-| {standard input}:1171: Error: instruction not supported in Thumb16 mode -- `adds r0,r1,r3'
-| {standard input}:1172: Error: unshifted register required -- `adc r2,r2,#0'
-| make[2]: *** [mul.lo] Error 1
-
-Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
-
-Upstream-Status: Pending
-
---- mpfr.old/src/mpfr-longlong.h	2008-01-01 03:29:09.000000000 +0000
-+++ mpfr/src/mpfr-longlong.h	2008-10-27 21:46:44.000000000 +0000
-@@ -406,7 +406,7 @@
- 	     "rIJ" ((USItype) (bl)))
- #endif
- 
--#if defined (__arm__) && W_TYPE_SIZE == 32
-+#if defined (__arm__) && W_TYPE_SIZE == 32 && !defined(__thumb__)
- #define add_ssaaaa(sh, sl, ah, al, bh, bl) \
-   __asm__ ("adds\t%1, %4, %5\n\tadc\t%0, %2, %3"			\
- 	   : "=r" (sh), "=&r" (sl)					\
diff --git a/poky/meta/recipes-support/mpfr/mpfr_3.1.5.bb b/poky/meta/recipes-support/mpfr/mpfr_3.1.5.bb
deleted file mode 100644
index a78c0bd..0000000
--- a/poky/meta/recipes-support/mpfr/mpfr_3.1.5.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-SUMMARY = "C library for multiple-precision floating-point computations with exact rounding"
-HOMEPAGE = "http://www.mpfr.org/"
-LICENSE = "LGPLv3+"
-SECTION = "devel"
-
-inherit autotools texinfo
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
-		    file://COPYING.LESSER;md5=6a6a8e020838b23406c81b19c1d46df6"
-DEPENDS = "gmp"
-
-SRC_URI = "http://www.mpfr.org/mpfr-${PV}/mpfr-${PV}.tar.xz \
-           file://long-long-thumb.patch \
-           "
-SRC_URI[md5sum] = "c4ac246cf9795a4491e7766002cd528f"
-SRC_URI[sha256sum] = "015fde82b3979fbe5f83501986d328331ba8ddf008c1ff3da3c238f49ca062bc"
-
-UPSTREAM_CHECK_URI = "http://www.mpfr.org/mpfr-current/"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/mpfr/mpfr_4.0.1.bb b/poky/meta/recipes-support/mpfr/mpfr_4.0.1.bb
new file mode 100644
index 0000000..2eee76a
--- /dev/null
+++ b/poky/meta/recipes-support/mpfr/mpfr_4.0.1.bb
@@ -0,0 +1,19 @@
+SUMMARY = "C library for multiple-precision floating-point computations with exact rounding"
+HOMEPAGE = "http://www.mpfr.org/"
+LICENSE = "LGPLv3+"
+SECTION = "devel"
+
+inherit autotools texinfo
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
+		    file://COPYING.LESSER;md5=6a6a8e020838b23406c81b19c1d46df6"
+DEPENDS = "gmp autoconf-archive"
+
+SRC_URI = "http://www.mpfr.org/mpfr-${PV}/mpfr-${PV}.tar.xz \
+           file://0001-Fix-obsolete-ARC-asm-constraints.patch"
+SRC_URI[md5sum] = "b8dd19bd9bb1ec8831a6a582a7308073"
+SRC_URI[sha256sum] = "67874a60826303ee2fb6affc6dc0ddd3e749e9bfcb4c8655e3953d0458a6e16e"
+
+UPSTREAM_CHECK_URI = "http://www.mpfr.org/mpfr-current/"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/poky/meta/recipes-support/npth/npth_1.5.bb b/poky/meta/recipes-support/npth/npth_1.5.bb
deleted file mode 100644
index e7db6ae..0000000
--- a/poky/meta/recipes-support/npth/npth_1.5.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-SUMMARY = "New GNU Portable Threads library"
-HOMEPAGE = "http://www.gnupg.org/software/pth/"
-SECTION = "libs"
-LICENSE = "LGPLv2+"
-LIC_FILES_CHKSUM = "\
-    file://COPYING.LIB;md5=2caced0b25dfefd4c601d92bd15116de\
-    "
-UPSTREAM_CHECK_URI = "https://gnupg.org/download/index.html"
-SRC_URI = "${GNUPG_MIRROR}/npth/npth-${PV}.tar.bz2 \
-           file://pkgconfig.patch \
-          "
-
-SRC_URI[md5sum] = "9ba2dc4302d2f32c66737c43ed191b1b"
-SRC_URI[sha256sum] = "294a690c1f537b92ed829d867bee537e46be93fbd60b16c04630fbbfcd9db3c2"
-
-BINCONFIG = "${bindir}/npth-config"
-
-inherit autotools binconfig-disabled
-
-FILES_${PN} = "${libdir}/libnpth.so.*"
-FILES_${PN}-dev += "${bindir}/npth-config"
-
-BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-support/npth/npth_1.6.bb b/poky/meta/recipes-support/npth/npth_1.6.bb
new file mode 100644
index 0000000..8310efb
--- /dev/null
+++ b/poky/meta/recipes-support/npth/npth_1.6.bb
@@ -0,0 +1,27 @@
+SUMMARY = "New GNU Portable Threads library"
+HOMEPAGE = "http://www.gnupg.org/software/pth/"
+SECTION = "libs"
+LICENSE = "LGPLv2+"
+LIC_FILES_CHKSUM = "\
+    file://COPYING.LIB;md5=2caced0b25dfefd4c601d92bd15116de\
+    "
+UPSTREAM_CHECK_URI = "https://gnupg.org/download/index.html"
+SRC_URI = "${GNUPG_MIRROR}/npth/npth-${PV}.tar.bz2 \
+           file://pkgconfig.patch \
+          "
+
+SRC_URI[md5sum] = "375d1a15ad969f32d25f1a7630929854"
+SRC_URI[sha256sum] = "1393abd9adcf0762d34798dc34fdcf4d0d22a8410721e76f1e3afcd1daa4e2d1"
+
+BINCONFIG = "${bindir}/npth-config"
+
+inherit autotools binconfig-disabled multilib_header 
+
+FILES_${PN} = "${libdir}/libnpth.so.*"
+FILES_${PN}-dev += "${bindir}/npth-config"
+
+do_install_append() {
+    oe_multilib_header npth.h
+}
+
+BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-support/nspr/nspr/0003-Add-type-definitions-for-the-RISC-V-architecture.patch b/poky/meta/recipes-support/nspr/nspr/0003-Add-type-definitions-for-the-RISC-V-architecture.patch
new file mode 100644
index 0000000..47e1475
--- /dev/null
+++ b/poky/meta/recipes-support/nspr/nspr/0003-Add-type-definitions-for-the-RISC-V-architecture.patch
@@ -0,0 +1,150 @@
+# HG changeset patch
+# User Karsten Merker <merker@debian.org>
+# Date 1523974333 -7200
+# Node ID f47871e2aeb16b39d4f516690e25c81b04d6d05a
+# Parent  776db96f834cb86e8863052201d55f60a2da91cb
+Bug 1308584, Add type definitions for the RISC-V architecture, r=kaie
+
+Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
+[ Changes by AF:
+ - Rebase on other Yocto patches
+]
+Upstream-Status: Backport [ https://hg.mozilla.org/projects/nspr/rev/f47871e2aeb1 ]
+
+diff --git a/pr/include/md/_linux.cfg b/pr/include/md/_linux.cfg
+--- a/pr/include/md/_linux.cfg
++++ b/pr/include/md/_linux.cfg
+@@ -1015,16 +1015,108 @@
+ #define PR_ALIGN_OF_FLOAT   4
+ #define PR_ALIGN_OF_DOUBLE  4
+ #define PR_ALIGN_OF_POINTER 4
+ #define PR_ALIGN_OF_WORD    4
+ 
+ #define PR_BYTES_PER_WORD_LOG2   2
+ #define PR_BYTES_PER_DWORD_LOG2  3
+ 
++#elif defined(__riscv) && (__riscv_xlen == 32)
++
++#undef  IS_BIG_ENDIAN
++#define IS_LITTLE_ENDIAN 1
++#undef  IS_64
++
++#define PR_BYTES_PER_BYTE   1
++#define PR_BYTES_PER_SHORT  2
++#define PR_BYTES_PER_INT    4
++#define PR_BYTES_PER_INT64  8
++#define PR_BYTES_PER_LONG   4
++#define PR_BYTES_PER_FLOAT  4
++#define PR_BYTES_PER_DOUBLE 8
++#define PR_BYTES_PER_WORD   4
++#define PR_BYTES_PER_DWORD  8
++
++#define PR_BITS_PER_BYTE    8
++#define PR_BITS_PER_SHORT   16
++#define PR_BITS_PER_INT     32
++#define PR_BITS_PER_INT64   64
++#define PR_BITS_PER_LONG    32
++#define PR_BITS_PER_FLOAT   32
++#define PR_BITS_PER_DOUBLE  64
++#define PR_BITS_PER_WORD    32
++
++#define PR_BITS_PER_BYTE_LOG2   3
++#define PR_BITS_PER_SHORT_LOG2  4
++#define PR_BITS_PER_INT_LOG2    5
++#define PR_BITS_PER_INT64_LOG2  6
++#define PR_BITS_PER_LONG_LOG2   5
++#define PR_BITS_PER_FLOAT_LOG2  5
++#define PR_BITS_PER_DOUBLE_LOG2 6
++#define PR_BITS_PER_WORD_LOG2   5
++
++#define PR_ALIGN_OF_SHORT   2
++#define PR_ALIGN_OF_INT     4
++#define PR_ALIGN_OF_LONG    4
++#define PR_ALIGN_OF_INT64   8
++#define PR_ALIGN_OF_FLOAT   4
++#define PR_ALIGN_OF_DOUBLE  8
++#define PR_ALIGN_OF_POINTER 4
++#define PR_ALIGN_OF_WORD    4
++
++#define PR_BYTES_PER_WORD_LOG2  2
++#define PR_BYTES_PER_DWORD_LOG2 3
++
++#elif defined(__riscv) && (__riscv_xlen == 64)
++
++#undef  IS_BIG_ENDIAN
++#define IS_LITTLE_ENDIAN 1
++#define IS_64
++
++#define PR_BYTES_PER_BYTE   1
++#define PR_BYTES_PER_SHORT  2
++#define PR_BYTES_PER_INT    4
++#define PR_BYTES_PER_INT64  8
++#define PR_BYTES_PER_LONG   8
++#define PR_BYTES_PER_FLOAT  4
++#define PR_BYTES_PER_DOUBLE 8
++#define PR_BYTES_PER_WORD   8
++#define PR_BYTES_PER_DWORD  8
++
++#define PR_BITS_PER_BYTE    8
++#define PR_BITS_PER_SHORT   16
++#define PR_BITS_PER_INT     32
++#define PR_BITS_PER_INT64   64
++#define PR_BITS_PER_LONG    64
++#define PR_BITS_PER_FLOAT   32
++#define PR_BITS_PER_DOUBLE  64
++#define PR_BITS_PER_WORD    64
++
++#define PR_BITS_PER_BYTE_LOG2   3
++#define PR_BITS_PER_SHORT_LOG2  4
++#define PR_BITS_PER_INT_LOG2    5
++#define PR_BITS_PER_INT64_LOG2  6
++#define PR_BITS_PER_LONG_LOG2   6
++#define PR_BITS_PER_FLOAT_LOG2  5
++#define PR_BITS_PER_DOUBLE_LOG2 6
++#define PR_BITS_PER_WORD_LOG2   6
++
++#define PR_ALIGN_OF_SHORT   2
++#define PR_ALIGN_OF_INT     4
++#define PR_ALIGN_OF_LONG    8
++#define PR_ALIGN_OF_INT64   8
++#define PR_ALIGN_OF_FLOAT   4
++#define PR_ALIGN_OF_DOUBLE  8
++#define PR_ALIGN_OF_POINTER 8
++#define PR_ALIGN_OF_WORD    8
++
++#define PR_BYTES_PER_WORD_LOG2  3
++#define PR_BYTES_PER_DWORD_LOG2 3
++
+ #else
+ 
+ #error "Unknown CPU architecture"
+ 
+ #endif
+ 
+ #ifndef HAVE_LONG_LONG
+ #define	HAVE_LONG_LONG
+diff --git a/pr/include/md/_linux.h b/pr/include/md/_linux.h
+--- a/pr/include/md/_linux.h
++++ b/pr/include/md/_linux.h
+@@ -54,16 +54,20 @@
+ #elif defined(__avr32__)
+ #define _PR_SI_ARCHITECTURE "avr32"
+ #elif defined(__m32r__)
+ #define _PR_SI_ARCHITECTURE "m32r"
+ #elif defined(__nios2__)
+ #define _PR_SI_ARCHITECTURE "nios2"
+ #elif defined(__or1k__)
+ #define _PR_SI_ARCHITECTURE "or1k"
++#elif defined(__riscv) && (__riscv_xlen == 32)
++#define _PR_SI_ARCHITECTURE "riscv32"
++#elif defined(__riscv) && (__riscv_xlen == 64)
++#define _PR_SI_ARCHITECTURE "riscv64"
+ #else
+ #error "Unknown CPU architecture"
+ #endif
+ #define PR_DLL_SUFFIX		".so"
+ 
+ #define _PR_VMBASE              0x30000000
+ #define _PR_STACK_VMBASE	0x50000000
+ #define _MD_DEFAULT_STACK_SIZE	65536L
+
diff --git a/poky/meta/recipes-support/nspr/nspr/0004-Add-ARC-support.patch b/poky/meta/recipes-support/nspr/nspr/0004-Add-ARC-support.patch
new file mode 100644
index 0000000..9d68601
--- /dev/null
+++ b/poky/meta/recipes-support/nspr/nspr/0004-Add-ARC-support.patch
@@ -0,0 +1,88 @@
+From 6cb5b0be8837222a1e01745f2cf57cd0e593186d Mon Sep 17 00:00:00 2001
+From: Antoine Tenart <antoine.tenart@free-electrons.com>
+Date: Mon, 23 Oct 2017 10:28:20 +0200
+Subject: [PATCH] Add ARC support
+
+[Alexey: Rebased on top of other patches like RiscV, NIOS2 etc].
+
+Signed-off-by: Antoine Tenart <antoine.tenart@bootlin.com>
+Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
+
+Upstream-Status: Submitted [ https://bugzilla.mozilla.org/show_bug.cgi?id=1492378 ]
+---
+ pr/include/md/_linux.cfg | 45 ++++++++++++++++++++++++++++++++++++++++
+ pr/include/md/_linux.h   |  2 ++
+ 2 files changed, 47 insertions(+)
+
+diff --git a/pr/include/md/_linux.cfg b/pr/include/md/_linux.cfg
+index fec8525378dc..5f4fa0eac783 100644
+--- a/pr/include/md/_linux.cfg
++++ b/pr/include/md/_linux.cfg
+@@ -1157,6 +1157,51 @@
+ #define PR_BYTES_PER_WORD_LOG2  3
+ #define PR_BYTES_PER_DWORD_LOG2 3
+ 
++#elif defined(__arc__)
++
++#define IS_LITTLE_ENDIAN 1
++#undef  IS_BIG_ENDIAN
++
++#define PR_BYTES_PER_BYTE   1
++#define PR_BYTES_PER_SHORT  2
++#define PR_BYTES_PER_INT    4
++#define PR_BYTES_PER_INT64  8
++#define PR_BYTES_PER_LONG   4
++#define PR_BYTES_PER_FLOAT  4
++#define PR_BYTES_PER_DOUBLE 8
++#define PR_BYTES_PER_WORD   4
++#define PR_BYTES_PER_DWORD  8
++
++#define PR_BITS_PER_BYTE    8
++#define PR_BITS_PER_SHORT   16
++#define PR_BITS_PER_INT     32
++#define PR_BITS_PER_INT64   64
++#define PR_BITS_PER_LONG    32
++#define PR_BITS_PER_FLOAT   32
++#define PR_BITS_PER_DOUBLE  64
++#define PR_BITS_PER_WORD    32
++
++#define PR_BITS_PER_BYTE_LOG2   3
++#define PR_BITS_PER_SHORT_LOG2  4
++#define PR_BITS_PER_INT_LOG2    5
++#define PR_BITS_PER_INT64_LOG2  6
++#define PR_BITS_PER_LONG_LOG2   5
++#define PR_BITS_PER_FLOAT_LOG2  5
++#define PR_BITS_PER_DOUBLE_LOG2 6
++#define PR_BITS_PER_WORD_LOG2   5
++
++#define PR_ALIGN_OF_SHORT   2
++#define PR_ALIGN_OF_INT     4
++#define PR_ALIGN_OF_LONG    4
++#define PR_ALIGN_OF_INT64   4
++#define PR_ALIGN_OF_FLOAT   4
++#define PR_ALIGN_OF_DOUBLE  4
++#define PR_ALIGN_OF_POINTER 4
++#define PR_ALIGN_OF_WORD    4
++
++#define PR_BYTES_PER_WORD_LOG2   2
++#define PR_BYTES_PER_DWORD_LOG2  3
++
+ #else
+ 
+ #error "Unknown CPU architecture"
+diff --git a/pr/include/md/_linux.h b/pr/include/md/_linux.h
+index 8e04fad479a1..628b1217e9c8 100644
+--- a/pr/include/md/_linux.h
++++ b/pr/include/md/_linux.h
+@@ -63,6 +63,8 @@
+ #define _PR_SI_ARCHITECTURE "riscv32"
+ #elif defined(__riscv) && (__riscv_xlen == 64)
+ #define _PR_SI_ARCHITECTURE "riscv64"
++#elif defined(__arc__)
++#define _PR_SI_ARCHITECTURE "arc"
+ #else
+ #error "Unknown CPU architecture"
+ #endif
+-- 
+2.17.1
+
diff --git a/poky/meta/recipes-support/nspr/nspr_4.19.bb b/poky/meta/recipes-support/nspr/nspr_4.19.bb
index de2c871..0212be7 100644
--- a/poky/meta/recipes-support/nspr/nspr_4.19.bb
+++ b/poky/meta/recipes-support/nspr/nspr_4.19.bb
@@ -11,6 +11,8 @@
            file://remove-srcdir-from-configure-in.patch \
            file://0002-Add-nios2-support.patch \
            file://0001-md-Fix-build-with-musl.patch \
+           file://0003-Add-type-definitions-for-the-RISC-V-architecture.patch \
+           file://0004-Add-ARC-support.patch \
            file://nspr.pc.in \
 "
 
@@ -148,7 +150,9 @@
     xnotify \
     zerolen"
 
-inherit autotools
+inherit autotools multilib_script
+
+MULTILIB_SCRIPTS = "${PN}-dev:${bindir}/nspr-config"
 
 PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}"
 PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
diff --git a/poky/meta/recipes-support/nss/nss/0001-Bug-1437734-Use-snprintf-in-sign.c-r-ttaubert.patch b/poky/meta/recipes-support/nss/nss/0001-Bug-1437734-Use-snprintf-in-sign.c-r-ttaubert.patch
deleted file mode 100644
index bc10f33..0000000
--- a/poky/meta/recipes-support/nss/nss/0001-Bug-1437734-Use-snprintf-in-sign.c-r-ttaubert.patch
+++ /dev/null
@@ -1,119 +0,0 @@
-From 6f7d7be9997ba6727a5ad7c3800df9051160dc12 Mon Sep 17 00:00:00 2001
-From: Martin Thomson <martin.thomson@gmail.com>
-Date: Tue, 13 Feb 2018 12:30:58 +1100
-Subject: [PATCH] Bug 1437734 - Use snprintf in sign.c, r=ttaubert
-
---HG--
-extra : rebase_source : 97921ece71ff86b18d32b891591608290eed4d83
----
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Upstream-Status: Backport [https://github.com/nss-dev/nss/commit/0a9078b3cde97add7c825c9d13467a8401ad0c88#diff-b42512151dc137537091f823f7701804.patch]
-
- nss/cmd/signtool/sign.c | 58 ++++++++++++++++++++++++++++++++++++++++---------
- 1 file changed, 48 insertions(+), 10 deletions(-)
-
-diff --git a/nss/cmd/signtool/sign.c b/nss/cmd/signtool/sign.c
-index 6e776069a..6f8e43946 100644
---- a/nss/cmd/signtool/sign.c
-+++ b/nss/cmd/signtool/sign.c
-@@ -43,6 +43,7 @@ SignArchive(char *tree, char *keyName, char *zip_file, int javascript,
-     int status;
-     char tempfn[FNSIZE], fullfn[FNSIZE];
-     int keyType = rsaKey;
-+    int count;
- 
-     metafile = meta_file;
-     optimize = _optimize;
-@@ -81,9 +82,18 @@ SignArchive(char *tree, char *keyName, char *zip_file, int javascript,
-         }
- 
-         /* rsa/dsa to zip */
--        sprintf(tempfn, "META-INF/%s.%s", base, (keyType == dsaKey ? "dsa"
--                                                                   : "rsa"));
--        sprintf(fullfn, "%s/%s", tree, tempfn);
-+        count = snprintf(tempfn, sizeof(tempfn), "META-INF/%s.%s", base, (keyType == dsaKey ? "dsa" : "rsa"));
-+        if (count >= sizeof(tempfn)) {
-+            PR_fprintf(errorFD, "unable to write key metadata\n");
-+            errorCount++;
-+            exit(ERRX);
-+        }
-+        count = snprintf(fullfn, sizeof(fullfn), "%s/%s", tree, tempfn);
-+        if (count >= sizeof(fullfn)) {
-+            PR_fprintf(errorFD, "unable to write key metadata\n");
-+            errorCount++;
-+            exit(ERRX);
-+        }
-         JzipAdd(fullfn, tempfn, zipfile, compression_level);
- 
-         /* Loop through all files & subdirectories, add to archive */
-@@ -93,20 +103,44 @@ SignArchive(char *tree, char *keyName, char *zip_file, int javascript,
-     }
-     /* mf to zip */
-     strcpy(tempfn, "META-INF/manifest.mf");
--    sprintf(fullfn, "%s/%s", tree, tempfn);
-+    count = snprintf(fullfn, sizeof(fullfn), "%s/%s", tree, tempfn);
-+    if (count >= sizeof(fullfn)) {
-+        PR_fprintf(errorFD, "unable to write manifest\n");
-+        errorCount++;
-+        exit(ERRX);
-+    }
-     JzipAdd(fullfn, tempfn, zipfile, compression_level);
- 
-     /* sf to zip */
--    sprintf(tempfn, "META-INF/%s.sf", base);
--    sprintf(fullfn, "%s/%s", tree, tempfn);
-+    count = snprintf(tempfn, sizeof(tempfn), "META-INF/%s.sf", base);
-+    if (count >= sizeof(tempfn)) {
-+        PR_fprintf(errorFD, "unable to write sf metadata\n");
-+        errorCount++;
-+        exit(ERRX);
-+    }
-+    count = snprintf(fullfn, sizeof(fullfn), "%s/%s", tree, tempfn);
-+    if (count >= sizeof(fullfn)) {
-+        PR_fprintf(errorFD, "unable to write sf metadata\n");
-+        errorCount++;
-+        exit(ERRX);
-+    }
-     JzipAdd(fullfn, tempfn, zipfile, compression_level);
- 
-     /* Add the rsa/dsa file to the zip archive normally */
-     if (!xpi_arc) {
-         /* rsa/dsa to zip */
--        sprintf(tempfn, "META-INF/%s.%s", base, (keyType == dsaKey ? "dsa"
--                                                                   : "rsa"));
--        sprintf(fullfn, "%s/%s", tree, tempfn);
-+        count = snprintf(tempfn, sizeof(tempfn), "META-INF/%s.%s", base, (keyType == dsaKey ? "dsa" : "rsa"));
-+        if (count >= sizeof(tempfn)) {
-+            PR_fprintf(errorFD, "unable to write key metadata\n");
-+            errorCount++;
-+            exit(ERRX);
-+        }
-+        count = snprintf(fullfn, sizeof(fullfn), "%s/%s", tree, tempfn);
-+        if (count >= sizeof(fullfn)) {
-+            PR_fprintf(errorFD, "unable to write key metadata\n");
-+            errorCount++;
-+            exit(ERRX);
-+        }
-         JzipAdd(fullfn, tempfn, zipfile, compression_level);
-     }
- 
-@@ -408,6 +442,7 @@ static int
- manifesto_xpi_fn(char *relpath, char *basedir, char *reldir, char *filename, void *arg)
- {
-     char fullname[FNSIZE];
-+    int count;
- 
-     if (verbosity >= 0) {
-         PR_fprintf(outputFD, "--> %s\n", relpath);
-@@ -421,7 +456,10 @@ manifesto_xpi_fn(char *relpath, char *basedir, char *reldir, char *filename, voi
-         if (!PL_HashTableLookup(extensions, ext))
-             return 0;
-     }
--    sprintf(fullname, "%s/%s", basedir, relpath);
-+    count = snprintf(fullname, sizeof(fullname), "%s/%s", basedir, relpath);
-+    if (count >= sizeof(fullname)) {
-+        return 1;
-+    }
-     JzipAdd(fullname, relpath, zipfile, compression_level);
- 
-     return 0;
diff --git a/poky/meta/recipes-support/nss/nss/Fix-compilation-for-X32.patch b/poky/meta/recipes-support/nss/nss/Fix-compilation-for-X32.patch
deleted file mode 100644
index 80b8690..0000000
--- a/poky/meta/recipes-support/nss/nss/Fix-compilation-for-X32.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From c8eadfcdfbc1d5a4799e9a264b0f859cb5954c05 Mon Sep 17 00:00:00 2001
-From: Christopher Larson <chris_larson@mentor.com>
-Date: Tue, 13 Dec 2016 11:40:47 -0700
-Subject: [PATCH 7/7] Fix compilation for X32
-
-X32 uses 32-bit pointers, not 64-bit.
-
-Signed-off-by: Christopher Larson <chris_larson@mentor.com>
-
-Upstream-Status: Pending
----
- nss/lib/freebl/poly1305-donna-x64-sse2-incremental-source.c | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/nss/lib/freebl/poly1305-donna-x64-sse2-incremental-source.c b/nss/lib/freebl/poly1305-donna-x64-sse2-incremental-source.c
-index 2a3301e..d4ade41 100644
---- a/nss/lib/freebl/poly1305-donna-x64-sse2-incremental-source.c
-+++ b/nss/lib/freebl/poly1305-donna-x64-sse2-incremental-source.c
-@@ -87,7 +87,11 @@ static poly1305_state_internal INLINE
-     *
-     poly1305_aligned_state(poly1305_state *state)
- {
-+#ifdef __ILP32__
-+    return (poly1305_state_internal *)(((uint32_t)state + 63) & ~63);
-+#else
-     return (poly1305_state_internal *)(((uint64_t)state + 63) & ~63);
-+#endif
- }
- 
- /* copy 0-63 bytes */
--- 
-2.8.0
-
diff --git a/poky/meta/recipes-support/nss/nss/blank-cert9.db b/poky/meta/recipes-support/nss/nss/blank-cert9.db
new file mode 100644
index 0000000..7d4bcf2
--- /dev/null
+++ b/poky/meta/recipes-support/nss/nss/blank-cert9.db
Binary files differ
diff --git a/poky/meta/recipes-support/nss/nss/blank-key4.db b/poky/meta/recipes-support/nss/nss/blank-key4.db
new file mode 100644
index 0000000..d47f08d
--- /dev/null
+++ b/poky/meta/recipes-support/nss/nss/blank-key4.db
Binary files differ
diff --git a/poky/meta/recipes-support/nss/nss/disable-Wvarargs-with-clang.patch b/poky/meta/recipes-support/nss/nss/disable-Wvarargs-with-clang.patch
index 86b1b60..de812d2 100644
--- a/poky/meta/recipes-support/nss/nss/disable-Wvarargs-with-clang.patch
+++ b/poky/meta/recipes-support/nss/nss/disable-Wvarargs-with-clang.patch
@@ -18,11 +18,11 @@
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 Upstream-Status: Pending
 
-Index: nss-3.24/nss/coreconf/Werror.mk
+Index: nss-3.37.1/nss/coreconf/Werror.mk
 ===================================================================
---- nss-3.24.orig/nss/coreconf/Werror.mk
-+++ nss-3.24/nss/coreconf/Werror.mk
-@@ -54,7 +54,7 @@ ifndef WARNING_CFLAGS
+--- nss-3.37.1.orig/nss/coreconf/Werror.mk
++++ nss-3.37.1/nss/coreconf/Werror.mk
+@@ -56,7 +56,7 @@ ifndef WARNING_CFLAGS
      ifdef CC_IS_CLANG
        # -Qunused-arguments : clang objects to arguments that it doesn't understand
        #    and fixing this would require rearchitecture
diff --git a/poky/meta/recipes-support/nss/nss/nss-build-hacl-poly1305-aarch64.patch b/poky/meta/recipes-support/nss/nss/nss-build-hacl-poly1305-aarch64.patch
deleted file mode 100644
index 8276f89..0000000
--- a/poky/meta/recipes-support/nss/nss/nss-build-hacl-poly1305-aarch64.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-# HG changeset patch
-# User Daiki Ueno <dueno@redhat.com>
-# Date 1516710574 -3600
-#      Tue Jan 23 13:29:34 2018 +0100
-# Node ID 27f27ce21c2c6ff5a47fa9e17c438b000366c9c9
-# Parent  be1dca5ac80541d3b81a8da9d42854d8b1cceefb
-Build Hacl_Poly1305_64.o on aarch64 even with make
-
-Upstream-Status: Backport
-https://bug1432455.bmoattachments.org/attachment.cgi?id=8944691
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
-Index: nss-3.35/nss/lib/freebl/Makefile
-===================================================================
---- nss-3.35.orig/nss/lib/freebl/Makefile
-+++ nss-3.35/nss/lib/freebl/Makefile
-@@ -533,7 +533,12 @@ ifndef NSS_DISABLE_CHACHAPOLY
-             EXTRA_SRCS += chacha20_vec.c
-         endif
-     else
--        EXTRA_SRCS += poly1305.c
-+        ifeq ($(CPU_ARCH),aarch64)
-+            EXTRA_SRCS += Hacl_Poly1305_64.c
-+        else
-+            EXTRA_SRCS += poly1305.c
-+        endif
-+
-         EXTRA_SRCS += chacha20.c
-         VERIFIED_SRCS += Hacl_Chacha20.c
-     endif # x86_64
diff --git a/poky/meta/recipes-support/nss/nss/pqg.c-ULL_addend.patch b/poky/meta/recipes-support/nss/nss/pqg.c-ULL_addend.patch
index 9942bf1..3a817fa 100644
--- a/poky/meta/recipes-support/nss/nss/pqg.c-ULL_addend.patch
+++ b/poky/meta/recipes-support/nss/nss/pqg.c-ULL_addend.patch
@@ -6,11 +6,11 @@
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 Upstream-Status: Pending
-Index: nss-3.24/nss/lib/freebl/pqg.c
+Index: nss-3.37.1/nss/lib/freebl/pqg.c
 ===================================================================
---- nss-3.24.orig/nss/lib/freebl/pqg.c
-+++ nss-3.24/nss/lib/freebl/pqg.c
-@@ -322,8 +322,8 @@ generate_h_candidate(SECItem *hit, mp_in
+--- nss-3.37.1.orig/nss/lib/freebl/pqg.c
++++ nss-3.37.1/nss/lib/freebl/pqg.c
+@@ -326,8 +326,8 @@ generate_h_candidate(SECItem *hit, mp_in
  
  static SECStatus
  addToSeed(const SECItem *seed,
diff --git a/poky/meta/recipes-support/nss/nss/system-pkcs11.txt b/poky/meta/recipes-support/nss/nss/system-pkcs11.txt
new file mode 100644
index 0000000..1a264e9
--- /dev/null
+++ b/poky/meta/recipes-support/nss/nss/system-pkcs11.txt
@@ -0,0 +1,5 @@
+library=
+name=NSS Internal PKCS #11 Module
+parameters=configdir='sql:/etc/pki/nssdb' certPrefix='' keyPrefix='' secmod='secmod.db' flags= updatedir='' updateCertPrefix='' updateKeyPrefix='' updateid='' updateTokenDescription='' 
+NSS=Flags=internal,critical trustOrder=75 cipherOrder=100 slotParams=(1={slotFlags=[ECC,RSA,DSA,DH,RC2,RC4,DES,RANDOM,SHA1,MD5,MD2,SSL,TLS,AES,Camellia,SEED,SHA256,SHA512] askpw=any timeout=30})
+
diff --git a/poky/meta/recipes-support/nss/nss_3.35.bb b/poky/meta/recipes-support/nss/nss_3.35.bb
deleted file mode 100644
index 84f1916..0000000
--- a/poky/meta/recipes-support/nss/nss_3.35.bb
+++ /dev/null
@@ -1,255 +0,0 @@
-SUMMARY = "Mozilla's SSL and TLS implementation"
-DESCRIPTION = "Network Security Services (NSS) is a set of libraries \
-designed to support cross-platform development of \
-security-enabled client and server applications. \
-Applications built with NSS can support SSL v2 and v3, \
-TLS, PKCS 5, PKCS 7, PKCS 11, PKCS 12, S/MIME, X.509 \
-v3 certificates, and other security standards."
-HOMEPAGE = "http://www.mozilla.org/projects/security/pki/nss/"
-SECTION = "libs"
-
-LICENSE = "MPL-2.0 | (MPL-2.0 & GPL-2.0+) | (MPL-2.0 & LGPL-2.1+)"
-
-LIC_FILES_CHKSUM = "file://nss/COPYING;md5=3b1e88e1b9c0b5a4b2881d46cce06a18 \
-                    file://nss/lib/freebl/mpi/doc/LICENSE;md5=491f158d09d948466afce85d6f1fe18f \
-                    file://nss/lib/freebl/mpi/doc/LICENSE-MPL;md5=5d425c8f3157dbf212db2ec53d9e5132"
-
-VERSION_DIR = "${@d.getVar('BP').upper().replace('-', '_').replace('.', '_') + '_RTM'}"
-
-SRC_URI = "http://ftp.mozilla.org/pub/mozilla.org/security/nss/releases/${VERSION_DIR}/src/${BP}.tar.gz \
-           file://nss.pc.in \
-           file://signlibs.sh \
-           file://0001-nss-fix-support-cross-compiling.patch \
-           file://nss-no-rpath-for-cross-compiling.patch \
-           file://nss-fix-incorrect-shebang-of-perl.patch \
-           file://nss-fix-nsinstall-build.patch \
-           file://disable-Wvarargs-with-clang.patch \
-           file://pqg.c-ULL_addend.patch \
-           file://Fix-compilation-for-X32.patch \
-           file://nss-build-hacl-poly1305-aarch64.patch \
-           file://0001-Bug-1437734-Use-snprintf-in-sign.c-r-ttaubert.patch \
-           "
-
-SRC_URI[md5sum] = "9467ec9e65c5aeb3254a50250490f5f7"
-SRC_URI[sha256sum] = "f4127de09bede39f5fd0f789d33c3504c5d261e69ea03022d46b319b3e32f6fa"
-
-UPSTREAM_CHECK_URI = "https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/NSS_Releases"
-UPSTREAM_CHECK_REGEX = "NSS_(?P<pver>.+)_release_notes"
-
-inherit siteinfo
-
-DEPENDS = "sqlite3 nspr zlib nss-native"
-DEPENDS_class-native = "sqlite3-native nspr-native zlib-native"
-RDEPENDS_${PN}-smime = "perl"
-
-TD = "${S}/tentative-dist"
-TDS = "${S}/tentative-dist-staging"
-
-TARGET_CC_ARCH += "${LDFLAGS}"
-
-do_configure_prepend_libc-musl () {
-    sed -i -e '/-DHAVE_SYS_CDEFS_H/d' ${S}/nss/lib/dbm/config/config.mk
-}
-
-do_compile_prepend_class-native() {
-    export NSPR_INCLUDE_DIR=${STAGING_INCDIR_NATIVE}
-    export NSPR_LIB_DIR=${STAGING_LIBDIR_NATIVE}
-    export NSS_ENABLE_WERROR=0
-}
-
-do_compile_prepend_class-nativesdk() {
-    export LDFLAGS=""
-}
-
-do_compile_prepend_class-native() {
-    # Need to set RPATH so that chrpath will do its job correctly
-    RPATH="-Wl,-rpath-link,${STAGING_LIBDIR_NATIVE} -Wl,-rpath-link,${STAGING_BASE_LIBDIR_NATIVE} -Wl,-rpath,${STAGING_LIBDIR_NATIVE} -Wl,-rpath,${STAGING_BASE_LIBDIR_NATIVE}"
-}
-
-do_compile() {
-    export CROSS_COMPILE=1
-    export NATIVE_CC="${BUILD_CC}"
-    export NATIVE_FLAGS="${BUILD_CFLAGS}"
-    export BUILD_OPT=1
-
-    export FREEBL_NO_DEPEND=1
-    export FREEBL_LOWHASH=1
-
-    export LIBDIR=${libdir}
-    export MOZILLA_CLIENT=1
-    export NS_USE_GCC=1
-    export NSS_USE_SYSTEM_SQLITE=1
-    export NSS_ENABLE_ECC=1
-
-    export OS_RELEASE=3.4
-    export OS_TARGET=Linux
-    export OS_ARCH=Linux
-
-    if [ "${TARGET_ARCH}" = "powerpc" ]; then
-        OS_TEST=ppc
-    elif [ "${TARGET_ARCH}" = "powerpc64" ]; then
-        OS_TEST=ppc64
-    elif [ "${TARGET_ARCH}" = "mips" -o "${TARGET_ARCH}" = "mipsel" -o "${TARGET_ARCH}" = "mips64" -o "${TARGET_ARCH}" = "mips64el" ]; then
-        OS_TEST=mips
-    else
-        OS_TEST="${TARGET_ARCH}"
-    fi
-
-    if [ "${SITEINFO_BITS}" = "64" ]; then
-        export USE_64=1
-    elif [ "${TARGET_ARCH}" = "x86_64" -a "${SITEINFO_BITS}" = "32" ]; then
-        export USE_X32=1
-    fi
-
-    export NSS_DISABLE_GTESTS=1
-
-    # We can modify CC in the environment, but if we set it via an
-    # argument to make, nsinstall, a host program, will also build with it!
-    #
-    # nss pretty much does its own thing with CFLAGS, so we put them into CC.
-    # Optimization will get clobbered, but most of the stuff will survive.
-    # The motivation for this is to point to the correct place for debug
-    # source files and CFLAGS does that.  Nothing uses CCC.
-    #
-    export CC="${CC} ${CFLAGS}"
-    make -C ./nss CCC="${CXX} -g" \
-        OS_TEST=${OS_TEST} \
-        RPATH="${RPATH}"
-}
-do_compile[vardepsexclude] += "SITEINFO_BITS"
-
-
-do_install_prepend_class-nativesdk() {
-    export LDFLAGS=""
-}
-
-do_install() {
-    export CROSS_COMPILE=1
-    export NATIVE_CC="${BUILD_CC}"
-    export BUILD_OPT=1
-
-    export FREEBL_NO_DEPEND=1
-
-    export LIBDIR=${libdir}
-    export MOZILLA_CLIENT=1
-    export NS_USE_GCC=1
-    export NSS_USE_SYSTEM_SQLITE=1
-    export NSS_ENABLE_ECC=1
-
-    export OS_RELEASE=3.4
-    export OS_TARGET=Linux
-    export OS_ARCH=Linux
-
-    if [ "${TARGET_ARCH}" = "powerpc" ]; then
-        OS_TEST=ppc
-    elif [ "${TARGET_ARCH}" = "powerpc64" ]; then
-        OS_TEST=ppc64
-    elif [ "${TARGET_ARCH}" = "mips" -o "${TARGET_ARCH}" = "mipsel" -o "${TARGET_ARCH}" = "mips64" -o "${TARGET_ARCH}" = "mips64el" ]; then
-        OS_TEST=mips
-    else
-        OS_TEST="${TARGET_ARCH}"
-    fi
-    if [ "${SITEINFO_BITS}" = "64" ]; then
-        export USE_64=1
-    elif [ "${TARGET_ARCH}" = "x86_64" -a "${SITEINFO_BITS}" = "32" ]; then
-        export USE_X32=1
-    fi
-
-    export NSS_DISABLE_GTESTS=1
-
-    make -C ./nss \
-        CCC="${CXX}" \
-        OS_TEST=${OS_TEST} \
-        SOURCE_LIB_DIR="${TD}/${libdir}" \
-        SOURCE_BIN_DIR="${TD}/${bindir}" \
-        install
-
-    install -d ${D}/${libdir}/
-    for file in ${S}/dist/*.OBJ/lib/*.so; do
-        echo "Installing `basename $file`..."
-        cp $file  ${D}/${libdir}/
-    done
-
-    for shared_lib in ${TD}/${libdir}/*.so.*; do
-        if [ -f $shared_lib ]; then
-            cp $shared_lib ${D}/${libdir}
-            ln -sf $(basename $shared_lib) ${D}/${libdir}/$(basename $shared_lib .1oe)
-        fi
-    done
-    for shared_lib in ${TD}/${libdir}/*.so; do
-        if [ -f $shared_lib -a ! -e ${D}/${libdir}/$shared_lib ]; then
-            cp $shared_lib ${D}/${libdir}
-        fi
-    done
-
-    install -d ${D}/${includedir}/nss3
-    install -m 644 -t ${D}/${includedir}/nss3 dist/public/nss/*
-
-    install -d ${D}/${bindir}
-    for binary in ${TD}/${bindir}/*; do
-        install -m 755 -t ${D}/${bindir} $binary
-    done
-}
-do_install[vardepsexclude] += "SITEINFO_BITS"
-
-do_install_append() {
-    # Create empty .chk files for the NSS libraries at build time. They could
-    # be regenerated at target's boot time.
-    for file in libsoftokn3.chk libfreebl3.chk libnssdbm3.chk; do
-        touch ${D}/${libdir}/$file
-        chmod 755 ${D}/${libdir}/$file
-    done
-    install -D -m 755 ${WORKDIR}/signlibs.sh ${D}/${bindir}/signlibs.sh
-
-    install -d ${D}${libdir}/pkgconfig/
-    sed 's/%NSS_VERSION%/${PV}/' ${WORKDIR}/nss.pc.in | sed 's/%NSPR_VERSION%/4.9.2/' > ${D}${libdir}/pkgconfig/nss.pc
-    sed -i s:OEPREFIX:${prefix}:g ${D}${libdir}/pkgconfig/nss.pc
-    sed -i s:OEEXECPREFIX:${exec_prefix}:g ${D}${libdir}/pkgconfig/nss.pc
-    sed -i s:OELIBDIR:${libdir}:g ${D}${libdir}/pkgconfig/nss.pc
-    sed -i s:OEINCDIR:${includedir}/nss3:g ${D}${libdir}/pkgconfig/nss.pc
-}
-
-do_install_append_class-target() {
-    # Create a blank certificate
-    mkdir -p ${D}${sysconfdir}/pki/nssdb/
-    touch ./empty_password
-    certutil -N -d ${D}${sysconfdir}/pki/nssdb/ -f ./empty_password
-    chmod 644 ${D}${sysconfdir}/pki/nssdb/*.db
-    rm ./empty_password
-}
-
-PACKAGE_WRITE_DEPS += "nss-native"
-pkg_postinst_${PN} () {
-    if [ -n "$D" ]; then
-        for I in $D${libdir}/lib*.chk; do
-            DN=`dirname $I`
-            BN=`basename $I .chk`
-            FN=$DN/$BN.so
-            shlibsign -i $FN
-            if [ $? -ne 0 ]; then
-                exit 1
-            fi
-        done
-    else
-        signlibs.sh
-    fi
-}
-
-PACKAGES =+ "${PN}-smime"
-FILES_${PN}-smime = "\
-    ${bindir}/smime \
-"
-FILES_${PN} = "\
-    ${sysconfdir} \
-    ${bindir} \
-    ${libdir}/lib*.chk \
-    ${libdir}/lib*.so \
-    "
-FILES_${PN}-dev = "\
-    ${libdir}/nss \
-    ${libdir}/pkgconfig/* \
-    ${includedir}/* \
-    "
-
-BBCLASSEXTEND = "native nativesdk"
-
diff --git a/poky/meta/recipes-support/nss/nss_3.39.bb b/poky/meta/recipes-support/nss/nss_3.39.bb
new file mode 100644
index 0000000..cdc95c6
--- /dev/null
+++ b/poky/meta/recipes-support/nss/nss_3.39.bb
@@ -0,0 +1,264 @@
+SUMMARY = "Mozilla's SSL and TLS implementation"
+DESCRIPTION = "Network Security Services (NSS) is a set of libraries \
+designed to support cross-platform development of \
+security-enabled client and server applications. \
+Applications built with NSS can support SSL v2 and v3, \
+TLS, PKCS 5, PKCS 7, PKCS 11, PKCS 12, S/MIME, X.509 \
+v3 certificates, and other security standards."
+HOMEPAGE = "http://www.mozilla.org/projects/security/pki/nss/"
+SECTION = "libs"
+
+LICENSE = "MPL-2.0 | (MPL-2.0 & GPL-2.0+) | (MPL-2.0 & LGPL-2.1+)"
+
+LIC_FILES_CHKSUM = "file://nss/COPYING;md5=3b1e88e1b9c0b5a4b2881d46cce06a18 \
+                    file://nss/lib/freebl/mpi/doc/LICENSE;md5=491f158d09d948466afce85d6f1fe18f \
+                    file://nss/lib/freebl/mpi/doc/LICENSE-MPL;md5=5d425c8f3157dbf212db2ec53d9e5132"
+
+VERSION_DIR = "${@d.getVar('BP').upper().replace('-', '_').replace('.', '_') + '_RTM'}"
+
+SRC_URI = "http://ftp.mozilla.org/pub/mozilla.org/security/nss/releases/${VERSION_DIR}/src/${BP}.tar.gz \
+           file://nss.pc.in \
+           file://signlibs.sh \
+           file://0001-nss-fix-support-cross-compiling.patch \
+           file://nss-no-rpath-for-cross-compiling.patch \
+           file://nss-fix-incorrect-shebang-of-perl.patch \
+           file://nss-fix-nsinstall-build.patch \
+           file://disable-Wvarargs-with-clang.patch \
+           file://pqg.c-ULL_addend.patch \
+           file://blank-cert9.db \
+           file://blank-key4.db \
+           file://system-pkcs11.txt \
+           "
+
+SRC_URI[md5sum] = "10720fc70fd483de1b085402fb10ed59"
+SRC_URI[sha256sum] = "6be64dd76f212415cc8bc34343ac1e7389048db4db9a023a84873c411dc5864b"
+
+UPSTREAM_CHECK_URI = "https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/NSS_Releases"
+UPSTREAM_CHECK_REGEX = "NSS_(?P<pver>.+)_release_notes"
+
+inherit siteinfo
+
+DEPENDS = "sqlite3 nspr zlib nss-native"
+DEPENDS_class-native = "sqlite3-native nspr-native zlib-native"
+RDEPENDS_${PN}-smime = "perl"
+
+TD = "${S}/tentative-dist"
+TDS = "${S}/tentative-dist-staging"
+
+TARGET_CC_ARCH += "${LDFLAGS}"
+
+do_configure_prepend_libc-musl () {
+    sed -i -e '/-DHAVE_SYS_CDEFS_H/d' ${S}/nss/lib/dbm/config/config.mk
+}
+
+do_compile_prepend_class-native() {
+    export NSPR_INCLUDE_DIR=${STAGING_INCDIR_NATIVE}
+    export NSPR_LIB_DIR=${STAGING_LIBDIR_NATIVE}
+    export NSS_ENABLE_WERROR=0
+}
+
+do_compile_prepend_class-nativesdk() {
+    export LDFLAGS=""
+}
+
+do_compile_prepend_class-native() {
+    # Need to set RPATH so that chrpath will do its job correctly
+    RPATH="-Wl,-rpath-link,${STAGING_LIBDIR_NATIVE} -Wl,-rpath-link,${STAGING_BASE_LIBDIR_NATIVE} -Wl,-rpath,${STAGING_LIBDIR_NATIVE} -Wl,-rpath,${STAGING_BASE_LIBDIR_NATIVE}"
+}
+
+do_compile() {
+    export CROSS_COMPILE=1
+    export NATIVE_CC="${BUILD_CC}"
+    export NATIVE_FLAGS="${BUILD_CFLAGS}"
+    export BUILD_OPT=1
+
+    export FREEBL_NO_DEPEND=1
+    export FREEBL_LOWHASH=1
+
+    export LIBDIR=${libdir}
+    export MOZILLA_CLIENT=1
+    export NS_USE_GCC=1
+    export NSS_USE_SYSTEM_SQLITE=1
+    export NSS_ENABLE_ECC=1
+
+    export OS_RELEASE=3.4
+    export OS_TARGET=Linux
+    export OS_ARCH=Linux
+
+    if [ "${TARGET_ARCH}" = "powerpc" ]; then
+        OS_TEST=ppc
+    elif [ "${TARGET_ARCH}" = "powerpc64" ]; then
+        OS_TEST=ppc64
+    elif [ "${TARGET_ARCH}" = "mips" -o "${TARGET_ARCH}" = "mipsel" -o "${TARGET_ARCH}" = "mips64" -o "${TARGET_ARCH}" = "mips64el" ]; then
+        OS_TEST=mips
+    elif [ "${TARGET_ARCH}" = "aarch64_be" ]; then
+        OS_TEST="aarch64"
+    else
+        OS_TEST="${TARGET_ARCH}"
+    fi
+
+    if [ "${SITEINFO_BITS}" = "64" ]; then
+        export USE_64=1
+    elif [ "${TARGET_ARCH}" = "x86_64" -a "${SITEINFO_BITS}" = "32" ]; then
+        export USE_X32=1
+    fi
+
+    export NSS_DISABLE_GTESTS=1
+
+    # We can modify CC in the environment, but if we set it via an
+    # argument to make, nsinstall, a host program, will also build with it!
+    #
+    # nss pretty much does its own thing with CFLAGS, so we put them into CC.
+    # Optimization will get clobbered, but most of the stuff will survive.
+    # The motivation for this is to point to the correct place for debug
+    # source files and CFLAGS does that.  Nothing uses CCC.
+    #
+    export CC="${CC} ${CFLAGS}"
+    make -C ./nss CCC="${CXX} -g" \
+        OS_TEST=${OS_TEST} \
+        RPATH="${RPATH}"
+}
+do_compile[vardepsexclude] += "SITEINFO_BITS"
+
+
+do_install_prepend_class-nativesdk() {
+    export LDFLAGS=""
+}
+
+do_install() {
+    export CROSS_COMPILE=1
+    export NATIVE_CC="${BUILD_CC}"
+    export BUILD_OPT=1
+
+    export FREEBL_NO_DEPEND=1
+
+    export LIBDIR=${libdir}
+    export MOZILLA_CLIENT=1
+    export NS_USE_GCC=1
+    export NSS_USE_SYSTEM_SQLITE=1
+    export NSS_ENABLE_ECC=1
+
+    export OS_RELEASE=3.4
+    export OS_TARGET=Linux
+    export OS_ARCH=Linux
+
+    if [ "${TARGET_ARCH}" = "powerpc" ]; then
+        OS_TEST=ppc
+    elif [ "${TARGET_ARCH}" = "powerpc64" ]; then
+        OS_TEST=ppc64
+    elif [ "${TARGET_ARCH}" = "mips" -o "${TARGET_ARCH}" = "mipsel" -o "${TARGET_ARCH}" = "mips64" -o "${TARGET_ARCH}" = "mips64el" ]; then
+        OS_TEST=mips
+    elif [ "${TARGET_ARCH}" = "aarch64_be" ]; then
+        CPU_ARCH=aarch64
+        OS_TEST="aarch64"
+    else
+        OS_TEST="${TARGET_ARCH}"
+    fi
+    if [ "${SITEINFO_BITS}" = "64" ]; then
+        export USE_64=1
+    elif [ "${TARGET_ARCH}" = "x86_64" -a "${SITEINFO_BITS}" = "32" ]; then
+        export USE_X32=1
+    fi
+
+    export NSS_DISABLE_GTESTS=1
+
+    make -C ./nss \
+        CCC="${CXX}" \
+        OS_TEST=${OS_TEST} \
+        SOURCE_LIB_DIR="${TD}/${libdir}" \
+        SOURCE_BIN_DIR="${TD}/${bindir}" \
+        install
+
+    install -d ${D}/${libdir}/
+    for file in ${S}/dist/*.OBJ/lib/*.so; do
+        echo "Installing `basename $file`..."
+        cp $file  ${D}/${libdir}/
+    done
+
+    for shared_lib in ${TD}/${libdir}/*.so.*; do
+        if [ -f $shared_lib ]; then
+            cp $shared_lib ${D}/${libdir}
+            ln -sf $(basename $shared_lib) ${D}/${libdir}/$(basename $shared_lib .1oe)
+        fi
+    done
+    for shared_lib in ${TD}/${libdir}/*.so; do
+        if [ -f $shared_lib -a ! -e ${D}/${libdir}/$shared_lib ]; then
+            cp $shared_lib ${D}/${libdir}
+        fi
+    done
+
+    install -d ${D}/${includedir}/nss3
+    install -m 644 -t ${D}/${includedir}/nss3 dist/public/nss/*
+
+    install -d ${D}/${bindir}
+    for binary in ${TD}/${bindir}/*; do
+        install -m 755 -t ${D}/${bindir} $binary
+    done
+}
+do_install[vardepsexclude] += "SITEINFO_BITS"
+
+do_install_append() {
+    # Create empty .chk files for the NSS libraries at build time. They could
+    # be regenerated at target's boot time.
+    for file in libsoftokn3.chk libfreebl3.chk libnssdbm3.chk; do
+        touch ${D}/${libdir}/$file
+        chmod 755 ${D}/${libdir}/$file
+    done
+    install -D -m 755 ${WORKDIR}/signlibs.sh ${D}/${bindir}/signlibs.sh
+
+    install -d ${D}${libdir}/pkgconfig/
+    sed 's/%NSS_VERSION%/${PV}/' ${WORKDIR}/nss.pc.in | sed 's/%NSPR_VERSION%/4.9.2/' > ${D}${libdir}/pkgconfig/nss.pc
+    sed -i s:OEPREFIX:${prefix}:g ${D}${libdir}/pkgconfig/nss.pc
+    sed -i s:OEEXECPREFIX:${exec_prefix}:g ${D}${libdir}/pkgconfig/nss.pc
+    sed -i s:OELIBDIR:${libdir}:g ${D}${libdir}/pkgconfig/nss.pc
+    sed -i s:OEINCDIR:${includedir}/nss3:g ${D}${libdir}/pkgconfig/nss.pc
+}
+
+do_install_append_class-target() {
+    # It used to call certutil to create a blank certificate with empty password at
+    # build time, but the checksum of key4.db changes every time when certutil is called.
+    # It causes non-determinism issue, so provide databases with a blank certificate
+    # which are originally from output of nss in qemux86-64 build. You can get these
+    # databases by:
+    # certutil -N -d sql:/database/path/ --empty-password
+    install -d ${D}${sysconfdir}/pki/nssdb/
+    install -m 0644 ${WORKDIR}/blank-cert9.db ${D}${sysconfdir}/pki/nssdb/cert9.db
+    install -m 0644 ${WORKDIR}/blank-key4.db ${D}${sysconfdir}/pki/nssdb/key4.db
+    install -m 0644 ${WORKDIR}/system-pkcs11.txt ${D}${sysconfdir}/pki/nssdb/pkcs11.txt
+}
+
+PACKAGE_WRITE_DEPS += "nss-native"
+pkg_postinst_${PN} () {
+    if [ -n "$D" ]; then
+        for I in $D${libdir}/lib*.chk; do
+            DN=`dirname $I`
+            BN=`basename $I .chk`
+            FN=$DN/$BN.so
+            shlibsign -i $FN
+            if [ $? -ne 0 ]; then
+                exit 1
+            fi
+        done
+    else
+        signlibs.sh
+    fi
+}
+
+PACKAGES =+ "${PN}-smime"
+FILES_${PN}-smime = "\
+    ${bindir}/smime \
+"
+FILES_${PN} = "\
+    ${sysconfdir} \
+    ${bindir} \
+    ${libdir}/lib*.chk \
+    ${libdir}/lib*.so \
+    "
+FILES_${PN}-dev = "\
+    ${libdir}/nss \
+    ${libdir}/pkgconfig/* \
+    ${includedir}/* \
+    "
+
+BBCLASSEXTEND = "native nativesdk"
+
diff --git a/poky/meta/recipes-support/p11-kit/p11-kit/0001-LINGUAS-drop-the-languages-for-which-upstream-does-n.patch b/poky/meta/recipes-support/p11-kit/p11-kit/0001-LINGUAS-drop-the-languages-for-which-upstream-does-n.patch
index 2fda9df..e902b0b 100644
--- a/poky/meta/recipes-support/p11-kit/p11-kit/0001-LINGUAS-drop-the-languages-for-which-upstream-does-n.patch
+++ b/poky/meta/recipes-support/p11-kit/p11-kit/0001-LINGUAS-drop-the-languages-for-which-upstream-does-n.patch
@@ -1,4 +1,4 @@
-From c3aa4aae5e9f4adafd9e10d9466f1bc481e0aae6 Mon Sep 17 00:00:00 2001
+From c6bb4b99af39daa3221c3bdc0686987ae0f31693 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Wed, 31 Jan 2018 16:47:44 +0200
 Subject: [PATCH] LINGUAS: drop the languages for which upstream does not
@@ -9,24 +9,21 @@
 
 Upstream-Status: Inappropriate [missing upstream distribution files]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
 ---
  po/LINGUAS | 2 --
  1 file changed, 2 deletions(-)
 
 diff --git a/po/LINGUAS b/po/LINGUAS
-index 1fc4d53..e9cc5a7 100644
+index 767a806c2e20..6ab48001c409 100644
 --- a/po/LINGUAS
 +++ b/po/LINGUAS
-@@ -11,9 +11,7 @@ cy
+@@ -12,8 +12,6 @@ cy
  da
  de
  el
 -en@boldquot
- en_GB
 -en@quot
+ en_GB
  eo
  es
- es_CL
--- 
-2.15.1
-
diff --git a/poky/meta/recipes-support/p11-kit/p11-kit_0.22.1.bb b/poky/meta/recipes-support/p11-kit/p11-kit_0.22.1.bb
deleted file mode 100644
index 57798f4..0000000
--- a/poky/meta/recipes-support/p11-kit/p11-kit_0.22.1.bb
+++ /dev/null
@@ -1,46 +0,0 @@
-SUMMARY = "Provides a way to load and enumerate PKCS#11 modules"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=02933887f609807fbb57aa4237d14a50"
-
-inherit autotools gettext pkgconfig gtk-doc
-
-DEPENDS = "libtasn1 libffi"
-
-SRC_URI = "git://github.com/p11-glue/p11-kit \
-           file://0001-LINGUAS-drop-the-languages-for-which-upstream-does-n.patch \
-           "
-SRCREV = "bfb3bd47aa48983f5349479bca598403097ff81c"
-S = "${WORKDIR}/git"
-# exclude odd minor versions, which are development releases
-UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+\.(\d*[02468])+(\.\d+)+)"
-
-AUTOTOOLS_AUXDIR = "${S}/build/litter"
-EXTRA_OECONF = "--without-trust-paths"
-
-# This recipe does not use the standard gtk-doc m4 macros, and so the ./configure flags
-# that control gtk-doc build are non-standard
-EXTRA_OECONF_prepend_class-target = "${@bb.utils.contains('GTKDOC_ENABLED', 'True', '--enable-doc --enable-doc-html --disable-doc-pdf', \
-                                                                                    '--disable-doc', d)} "
-
-# When building native recipes, disable gtkdoc, as it is not necessary,
-# pulls in additional dependencies, and makes build times longer
-EXTRA_OECONF_prepend_class-native = "--disable-doc "
-EXTRA_OECONF_prepend_class-nativesdk = "--disable-doc "
-
-UNKNOWN_CONFIGURE_WHITELIST_append = " --enable-gtk-doc-html --disable-gtk-doc-pdf --enable-gtk-doc --disable-gtk-doc"
-
-# p11-kit relies on these two being copied from source tree
-# instead of being regenerated by gtkdoc-scan, but doesn't setup
-# dependencies correctly when there is a parallel build. Let's pre-copy
-# them instead.
-do_compile_prepend () {
-        cp ${S}/doc/manual/p11-kit-overrides.txt ${S}/doc/manual/p11-kit-sections.txt ${B}/doc/manual/
-}
-
-FILES_${PN} += " \
-    ${libdir}/p11-kit-proxy.so \
-    ${libdir}/pkcs11/*.so \
-    ${libdir}/pkcs11/*.la"
-
-# PN contains p11-kit-proxy.so, a symlink to a loadable module
-INSANE_SKIP_${PN} = "dev-so"
diff --git a/poky/meta/recipes-support/p11-kit/p11-kit_0.23.14.bb b/poky/meta/recipes-support/p11-kit/p11-kit_0.23.14.bb
new file mode 100644
index 0000000..dd25c38
--- /dev/null
+++ b/poky/meta/recipes-support/p11-kit/p11-kit_0.23.14.bb
@@ -0,0 +1,46 @@
+SUMMARY = "Provides a way to load and enumerate PKCS#11 modules"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=02933887f609807fbb57aa4237d14a50"
+
+inherit autotools gettext pkgconfig gtk-doc
+
+DEPENDS = "libtasn1 libffi"
+
+SRC_URI = "git://github.com/p11-glue/p11-kit \
+           file://0001-LINGUAS-drop-the-languages-for-which-upstream-does-n.patch \
+           "
+SRCREV = "3770793f026e46a000d2d8816d56122598289d5c"
+S = "${WORKDIR}/git"
+
+AUTOTOOLS_AUXDIR = "${S}/build/litter"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[trust-paths] = "--with-trust-paths=/etc/ssl/certs/ca-certificates.crt,--without-trust-paths,,ca-certificates"
+
+# This recipe does not use the standard gtk-doc m4 macros, and so the ./configure flags
+# that control gtk-doc build are non-standard
+EXTRA_OECONF_prepend_class-target = "${@bb.utils.contains('GTKDOC_ENABLED', 'True', '--enable-doc --enable-doc-html --disable-doc-pdf', \
+                                                                                    '--disable-doc', d)} "
+
+# When building native recipes, disable gtkdoc, as it is not necessary,
+# pulls in additional dependencies, and makes build times longer
+EXTRA_OECONF_prepend_class-native = "--disable-doc "
+EXTRA_OECONF_prepend_class-nativesdk = "--disable-doc "
+
+UNKNOWN_CONFIGURE_WHITELIST_append = " --enable-gtk-doc-html --disable-gtk-doc-pdf --enable-gtk-doc --disable-gtk-doc"
+
+# p11-kit relies on these two being copied from source tree
+# instead of being regenerated by gtkdoc-scan, but doesn't setup
+# dependencies correctly when there is a parallel build. Let's pre-copy
+# them instead.
+do_compile_prepend () {
+        cp ${S}/doc/manual/p11-kit-overrides.txt ${S}/doc/manual/p11-kit-sections.txt ${B}/doc/manual/
+}
+
+FILES_${PN} += " \
+    ${libdir}/p11-kit-proxy.so \
+    ${libdir}/pkcs11/*.so \
+    ${libdir}/pkcs11/*.la"
+
+# PN contains p11-kit-proxy.so, a symlink to a loadable module
+INSANE_SKIP_${PN} = "dev-so"
diff --git a/poky/meta/recipes-support/pinentry/pinentry_1.1.0.bb b/poky/meta/recipes-support/pinentry/pinentry_1.1.0.bb
index 1eaa261..4116efc 100644
--- a/poky/meta/recipes-support/pinentry/pinentry_1.1.0.bb
+++ b/poky/meta/recipes-support/pinentry/pinentry_1.1.0.bb
@@ -8,8 +8,6 @@
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING;md5=cbbd794e2a0a289b9dfcc9f513d1996e"
 
-inherit autotools pkgconfig
-
 DEPENDS = "gettext-native libassuan libgpg-error"
 
 UPSTREAM_CHECK_URI = "https://gnupg.org/download/index.html"
@@ -21,9 +19,7 @@
 SRC_URI[md5sum] = "3829315cb0a1e9cedc05ffe6def7a2c6"
 SRC_URI[sha256sum] = "68076686fa724a290ea49cdf0d1c0c1500907d1b759a3bcbfbec0293e8f56570"
 
-EXTRA_OECONF = "--disable-rpath --disable-dependency-tracking \
-                --disable-pinentry-qt5  \
-"
+inherit autotools pkgconfig
 
 PACKAGECONFIG ??= "ncurses libcap"
 
@@ -35,4 +31,9 @@
 #To use libsecret, add meta-gnome
 PACKAGECONFIG[secret] = "--enable-libsecret, --disable-libsecret, libsecret"
 
+EXTRA_OECONF = " \
+    --disable-rpath \
+    --disable-pinentry-qt5 \
+"
+
 BBCLASSEXTEND = "native"
diff --git a/poky/meta/recipes-support/ptest-runner/ptest-runner_2.1.1.bb b/poky/meta/recipes-support/ptest-runner/ptest-runner_2.1.1.bb
deleted file mode 100644
index e5b71c0..0000000
--- a/poky/meta/recipes-support/ptest-runner/ptest-runner_2.1.1.bb
+++ /dev/null
@@ -1,26 +0,0 @@
-SUMMARY = "A C program to run all installed ptests"
-DESCRIPTION = "The ptest-runner2 package installs a ptest-runner \
-program which loops through all installed ptest test suites and \
-runs them in sequence."
-HOMEPAGE = "http://git.yoctoproject.org/cgit/cgit.cgi/ptest-runner2/about/"
-
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=751419260aa954499f7abaabaa882bbe"
-
-SRCREV = "16413d71cc06b02a6d859c35a017cc49b88283f7"
-PV = "2.1.1+git${SRCPV}"
-
-SRC_URI = "git://git.yoctoproject.org/ptest-runner2"
-S = "${WORKDIR}/git"
-
-FILES_${PN} = "${bindir}/ptest-runner"
-
-EXTRA_OEMAKE = "-e MAKEFLAGS="
-
-do_compile () {
-	oe_runmake
-}
-
-do_install () {
-	install -D -m 0755 ${S}/ptest-runner ${D}${bindir}/ptest-runner
-}
diff --git a/poky/meta/recipes-support/ptest-runner/ptest-runner_2.2.bb b/poky/meta/recipes-support/ptest-runner/ptest-runner_2.2.bb
new file mode 100644
index 0000000..622d23b
--- /dev/null
+++ b/poky/meta/recipes-support/ptest-runner/ptest-runner_2.2.bb
@@ -0,0 +1,26 @@
+SUMMARY = "A C program to run all installed ptests"
+DESCRIPTION = "The ptest-runner2 package installs a ptest-runner \
+program which loops through all installed ptest test suites and \
+runs them in sequence."
+HOMEPAGE = "http://git.yoctoproject.org/cgit/cgit.cgi/ptest-runner2/about/"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=751419260aa954499f7abaabaa882bbe"
+
+SRCREV = "49956f65bb53ea2a2c1b394e5e59ffdfcdcc490f"
+PV = "2.2+git${SRCPV}"
+
+SRC_URI = "git://git.yoctoproject.org/ptest-runner2"
+S = "${WORKDIR}/git"
+
+FILES_${PN} = "${bindir}/ptest-runner"
+
+EXTRA_OEMAKE = "-e MAKEFLAGS="
+
+do_compile () {
+	oe_runmake
+}
+
+do_install () {
+	install -D -m 0755 ${S}/ptest-runner ${D}${bindir}/ptest-runner
+}
diff --git a/poky/meta/recipes-support/re2c/re2c/mkdir.patch b/poky/meta/recipes-support/re2c/re2c/mkdir.patch
deleted file mode 100644
index d59f01b..0000000
--- a/poky/meta/recipes-support/re2c/re2c/mkdir.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-Upstream-Status: Submitted (https://github.com/skvadrik/re2c/pull/191)
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
-From bccc10c60523f88c8f81413151cdcd612eb16198 Mon Sep 17 00:00:00 2001
-From: Ross Burton <ross.burton@intel.com>
-Date: Mon, 31 Jul 2017 15:43:41 +0100
-Subject: [PATCH] Makefile.am: create target directory before writing into it
-
-In some situations src/parse/ may not exist before a file is copied into the
-directory. Ensure that this doesn't happen by creating the directory first.
----
- re2c/Makefile.am | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/re2c/Makefile.am b/re2c/Makefile.am
-index 3b3b2c5e..0707fc5a 100644
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -187,6 +187,7 @@ CLEANFILES = \
- 	$(DOC)
- 
- $(AUTOGEN_PARSER): $(CUSTOM_PARSER)
-+	$(AM_V_at)$(MKDIR_P) $(dir $@)
- 	$(AM_V_GEN) if test $(BISON) = "no"; \
- 	then \
- 		cp $(top_srcdir)/$(BOOTSTRAP_PARSER) $@ && \
-@@ -211,6 +212,7 @@ $(BOOTSTRAP_PARSER): $(CUSTOM_PARSER)
- 		$(top_srcdir)/$(CUSTOM_PARSER);
- 
- .re.cc:
-+	$(AM_V_at)$(MKDIR_P) $(dir $@)
- 	$(AM_V_GEN) if test -x $(RE2C); \
- 	then \
- 		$(top_builddir)/$(RE2C) $(RE2CFLAGS) -o $@ $< && \
--- 
-2.11.0
diff --git a/poky/meta/recipes-support/re2c/re2c_0.16.bb b/poky/meta/recipes-support/re2c/re2c_0.16.bb
deleted file mode 100644
index 50dd7b7..0000000
--- a/poky/meta/recipes-support/re2c/re2c_0.16.bb
+++ /dev/null
@@ -1,15 +0,0 @@
-SUMMARY = "Tool for writing very fast and very flexible scanners"
-HOMEPAGE = "http://re2c.sourceforge.net/"
-AUTHOR = "Marcus Börger <helly@users.sourceforge.net>"
-SECTION = "devel"
-LICENSE = "PD"
-LIC_FILES_CHKSUM = "file://README;beginline=146;md5=881056c9add17f8019ccd8c382ba963a"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BPN}-${PV}.tar.gz \
-           file://mkdir.patch"
-SRC_URI[md5sum] = "3bf508fabd52ed7334647d0ccb956e8d"
-SRC_URI[sha256sum] = "48c12564297641cceb5ff05aead57f28118db6277f31e2262437feba89069e84"
-
-BBCLASSEXTEND = "native"
-
-inherit autotools
diff --git a/poky/meta/recipes-support/re2c/re2c_1.0.1.bb b/poky/meta/recipes-support/re2c/re2c_1.0.1.bb
new file mode 100644
index 0000000..4ed8d25
--- /dev/null
+++ b/poky/meta/recipes-support/re2c/re2c_1.0.1.bb
@@ -0,0 +1,14 @@
+SUMMARY = "Tool for writing very fast and very flexible scanners"
+HOMEPAGE = "http://re2c.sourceforge.net/"
+AUTHOR = "Marcus Börger <helly@users.sourceforge.net>"
+SECTION = "devel"
+LICENSE = "PD"
+LIC_FILES_CHKSUM = "file://README;beginline=146;md5=881056c9add17f8019ccd8c382ba963a"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BPN}-${PV}.tar.gz"
+SRC_URI[md5sum] = "e2c6cf52fc6a21595f21bc82db5324f8"
+SRC_URI[sha256sum] = "605058d18a00e01bfc32aebf83af35ed5b13180b4e9f279c90843afab2c66c7c"
+
+BBCLASSEXTEND = "native"
+
+inherit autotools
diff --git a/poky/meta/recipes-support/rng-tools/rng-tools/rngd.service b/poky/meta/recipes-support/rng-tools/rng-tools/rngd.service
index b94ad50..cb81024 100644
--- a/poky/meta/recipes-support/rng-tools/rng-tools/rngd.service
+++ b/poky/meta/recipes-support/rng-tools/rng-tools/rngd.service
@@ -1,5 +1,8 @@
 [Unit]
 Description=Hardware RNG Entropy Gatherer Daemon
+DefaultDependencies=no
+After=systemd-udev-settle.service
+Before=sysinit.target
 
 [Service]
 ExecStart=@SBINDIR@/rngd -f -r /dev/urandom
diff --git a/poky/meta/recipes-support/rng-tools/rng-tools_5.bb b/poky/meta/recipes-support/rng-tools/rng-tools_5.bb
index b3c9fd9..6765667 100644
--- a/poky/meta/recipes-support/rng-tools/rng-tools_5.bb
+++ b/poky/meta/recipes-support/rng-tools/rng-tools_5.bb
@@ -16,13 +16,6 @@
 SRC_URI[md5sum] = "6726cdc6fae1f5122463f24ae980dd68"
 SRC_URI[sha256sum] = "60a102b6603bbcce2da341470cad42eeaa9564a16b4490e7867026ca11a3078e"
 
-# As the recipe doesn't inherit systemd.bbclass, we need to set this variable
-# manually to avoid unnecessary postinst/preinst generated.
-python () {
-    if not bb.utils.contains('DISTRO_FEATURES', 'sysvinit', True, False, d):
-        d.setVar("INHIBIT_UPDATERCD_BBCLASS", "1")
-}
-
 inherit autotools update-rc.d systemd
 
 PACKAGECONFIG = "libgcrypt"
@@ -50,6 +43,6 @@
 }
 
 INITSCRIPT_NAME = "rng-tools"
-INITSCRIPT_PARAMS = "start 30 2 3 4 5 . stop 30 0 6 1 ."
+INITSCRIPT_PARAMS = "start 03 2 3 4 5 . stop 30 0 6 1 ."
 
 SYSTEMD_SERVICE_${PN} = "rngd.service"
diff --git a/poky/meta/recipes-support/serf/serf/0003-gen_def.patch b/poky/meta/recipes-support/serf/serf/0003-gen_def.patch
index e37e903..0ea2cca 100644
--- a/poky/meta/recipes-support/serf/serf/0003-gen_def.patch
+++ b/poky/meta/recipes-support/serf/serf/0003-gen_def.patch
@@ -3,6 +3,11 @@
 Date: Mon, 3 Sep 2018 11:12:27 -0700
 Subject: [PATCH] gen_def
 
+This is partial port because half of this patch is already present in our
+patches
+
+Upstream-Status: Backport [https://github.com/apache/serf/commit/8f07c9626106873a594fd07e7c257e9080d8660b]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
 ---
  SConstruct | 2 ++
  1 file changed, 2 insertions(+)
diff --git a/poky/meta/recipes-support/shared-mime-info/shared-mime-info_1.10.bb b/poky/meta/recipes-support/shared-mime-info/shared-mime-info_1.10.bb
new file mode 100644
index 0000000..9fc210b
--- /dev/null
+++ b/poky/meta/recipes-support/shared-mime-info/shared-mime-info_1.10.bb
@@ -0,0 +1,7 @@
+require shared-mime-info.inc
+
+SRC_URI += "file://parallelmake.patch \
+	    file://install-data-hook.patch"
+
+SRC_URI[md5sum] = "418c2ced9dc4dd5ca8b06a755e6d64e9"
+SRC_URI[sha256sum] = "c625a83b4838befc8cafcd54e3619946515d9e44d63d61c4adf7f5513ddfbebf"
diff --git a/poky/meta/recipes-support/shared-mime-info/shared-mime-info_1.9.bb b/poky/meta/recipes-support/shared-mime-info/shared-mime-info_1.9.bb
deleted file mode 100644
index f9b273e..0000000
--- a/poky/meta/recipes-support/shared-mime-info/shared-mime-info_1.9.bb
+++ /dev/null
@@ -1,7 +0,0 @@
-require shared-mime-info.inc
-
-SRC_URI += "file://parallelmake.patch \
-	    file://install-data-hook.patch"
-
-SRC_URI[md5sum] = "45103889b91242850aa47f09325e798b"
-SRC_URI[sha256sum] = "5c0133ec4e228e41bdf52f726d271a2d821499c2ab97afd3aa3d6cf43efcdc83"
diff --git a/poky/meta/recipes-support/sqlite/files/CVE-2018-8740.patch b/poky/meta/recipes-support/sqlite/files/CVE-2018-8740.patch
deleted file mode 100644
index 5d95e37..0000000
--- a/poky/meta/recipes-support/sqlite/files/CVE-2018-8740.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From 19aed4d2be46c4516caf2bee31f79044bbd1d57d Mon Sep 17 00:00:00 2001
-From: Sinan Kaya <okaya@kernel.org>
-Date: Fri, 21 Sep 2018 16:22:01 +0000
-Subject: [PATCH] Detect databases whose schema is corrupted using a CREATE TABLE AS statement and issue an appropriate error message
-
-Upstream-Status: Backport [ https://www.sqlite.org/cgi/src/vdiff?from=1774f1c3baf0bc3d&to=d75e67654aa9620b&diff=1&w]
-Signed-off-by: Sinan Kaya <okaya@kernel.org>
----
- sqlite3.c | 8 +++++---
- 1 file changed, 5 insertions(+), 3 deletions(-)
-
-diff --git a/sqlite3.c b/sqlite3.c
-index 73c69ef..6863bc6 100644
---- a/sqlite3.c
-+++ b/sqlite3.c
-@@ -103474,8 +103474,6 @@ SQLITE_PRIVATE void sqlite3EndTable(
-   p = pParse->pNewTable;
-   if( p==0 ) return;
- 
--  assert( !db->init.busy || !pSelect );
--
-   /* If the db->init.busy is 1 it means we are reading the SQL off the
-   ** "sqlite_master" or "sqlite_temp_master" table on the disk.
-   ** So do not write to the disk again.  Extract the root page number
-@@ -103486,6 +103484,10 @@ SQLITE_PRIVATE void sqlite3EndTable(
-   ** table itself.  So mark it read-only.
-   */
-   if( db->init.busy ){
-+    if( pSelect ){
-+     sqlite3ErrorMsg(pParse, "");
-+     return;
-+    }
-     p->tnum = db->init.newTnum;
-     if( p->tnum==1 ) p->tabFlags |= TF_Readonly;
-   }
-@@ -117813,7 +117815,7 @@ static void corruptSchema(
-     char *z;
-     if( zObj==0 ) zObj = "?";
-     z = sqlite3MPrintf(db, "malformed database schema (%s)", zObj);
--    if( zExtra ) z = sqlite3MPrintf(db, "%z - %s", z, zExtra);
-+    if( zExtra && zExtra[0] ) z = sqlite3MPrintf(db, "%z - %s", z, zExtra);
-     sqlite3DbFree(db, *pData->pzErrMsg);
-     *pData->pzErrMsg = z;
-   }
--- 
-2.19.0
-
diff --git a/poky/meta/recipes-support/sqlite/sqlite3.inc b/poky/meta/recipes-support/sqlite/sqlite3.inc
index 30847b9..1834867 100644
--- a/poky/meta/recipes-support/sqlite/sqlite3.inc
+++ b/poky/meta/recipes-support/sqlite/sqlite3.inc
@@ -36,14 +36,10 @@
 CFLAGS_append = " -fPIC"
 
 # pread() is in POSIX.1-2001 so any reasonable system must surely support it
-BUILD_CFLAGS += "-DUSE_PREAD"
-BUILDSDK_CFLAGS += "-DUSE_PREAD"
-TARGET_CFLAGS += "-DUSE_PREAD"
+CFLAGS += "-DUSE_PREAD"
 
 # Provide column meta-data API
-BUILD_CFLAGS += "-DSQLITE_ENABLE_COLUMN_METADATA"
-BUILDSDK_CFLAGS += "-DSQLITE_ENABLE_COLUMN_METADATA"
-TARGET_CFLAGS += "-DSQLITE_ENABLE_COLUMN_METADATA"
+CFLAGS += "-DSQLITE_ENABLE_COLUMN_METADATA"
 
 PACKAGES = "lib${BPN} lib${BPN}-dev lib${BPN}-doc ${PN}-dbg lib${BPN}-staticdev ${PN}"
 
diff --git a/poky/meta/recipes-support/sqlite/sqlite3_3.22.0.bb b/poky/meta/recipes-support/sqlite/sqlite3_3.22.0.bb
deleted file mode 100644
index b90f898..0000000
--- a/poky/meta/recipes-support/sqlite/sqlite3_3.22.0.bb
+++ /dev/null
@@ -1,11 +0,0 @@
-require sqlite3.inc
-
-LICENSE = "PD"
-LIC_FILES_CHKSUM = "file://sqlite3.h;endline=11;md5=786d3dc581eff03f4fd9e4a77ed00c66"
-
-SRC_URI = "\
-  http://www.sqlite.org/2018/sqlite-autoconf-${SQLITE_PV}.tar.gz \
-  file://CVE-2018-8740.patch \
-  "
-SRC_URI[md5sum] = "96b5648d542e8afa6ab7ffb8db8ddc3d"
-SRC_URI[sha256sum] = "2824ab1238b706bc66127320afbdffb096361130e23291f26928a027b885c612"
diff --git a/poky/meta/recipes-support/sqlite/sqlite3_3.23.1.bb b/poky/meta/recipes-support/sqlite/sqlite3_3.23.1.bb
new file mode 100644
index 0000000..3755761
--- /dev/null
+++ b/poky/meta/recipes-support/sqlite/sqlite3_3.23.1.bb
@@ -0,0 +1,10 @@
+require sqlite3.inc
+
+LICENSE = "PD"
+LIC_FILES_CHKSUM = "file://sqlite3.h;endline=11;md5=786d3dc581eff03f4fd9e4a77ed00c66"
+
+SRC_URI = "\
+  http://www.sqlite.org/2018/sqlite-autoconf-${SQLITE_PV}.tar.gz \
+  "
+SRC_URI[md5sum] = "99a51b40a66872872a91c92f6d0134fa"
+SRC_URI[sha256sum] = "92842b283e5e744eff5da29ed3c69391de7368fccc4d0ee6bf62490ce555ef25"
diff --git a/poky/meta/recipes-support/vte/vte_0.50.2.bb b/poky/meta/recipes-support/vte/vte_0.50.2.bb
deleted file mode 100644
index 8b9ee33..0000000
--- a/poky/meta/recipes-support/vte/vte_0.50.2.bb
+++ /dev/null
@@ -1,48 +0,0 @@
-SUMMARY = "Virtual terminal emulator GTK+ widget library"
-BUGTRACKER = "https://bugzilla.gnome.org/buglist.cgi?product=vte"
-LICENSE = "LGPLv2.1+"
-DEPENDS = "glib-2.0 gtk+3 libpcre2 intltool-native libxml2-native gperf-native"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
-
-inherit gnomebase gtk-doc distro_features_check upstream-version-is-even gobject-introspection
-
-# vapigen.m4 is required when vala is not present (but the one from vala should be used normally)
-SRC_URI += "file://0001-Don-t-enable-stack-protection-by-default.patch \
-            ${@bb.utils.contains('PACKAGECONFIG', 'vala', '', 'file://0001-Add-m4-vapigen.m4.patch', d) } \
-            "
-SRC_URI[archive.md5sum] = "1912cfd1d9cdd30cebeb908507acadc5"
-SRC_URI[archive.sha256sum] = "79dd316bfaff48f2fb74d066baae0d830e1f44436796fe410a57297e5c5f09cf"
-
-ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
-
-# Instead of "inherit vala" we do the relevant settings here so we can
-# set DEPENDS based on PACKAGECONFIG.
-
-# Our patched version of Vala looks in STAGING_DATADIR for .vapi files
-export STAGING_DATADIR
-# Upstream Vala >= 0.11 looks in XDG_DATA_DIRS for .vapi files
-export XDG_DATA_DIRS = "${STAGING_DATADIR}"
-
-# Help g-ir-scanner find the .so for linking
-do_compile_prepend() {
-        export GIR_EXTRA_LIBS_PATH="${B}/src/.libs"
-}
-
-# Package additional files
-FILES_${PN}-dev += "${datadir}/vala/vapi/*"
-
-PACKAGECONFIG ??= "gnutls"
-PACKAGECONFIG[vala] = "--enable-vala,--disable-vala,vala-native vala"
-PACKAGECONFIG[gnutls] = "--with-gnutls,--without-gnutls,gnutls"
-
-CFLAGS += "-D_GNU_SOURCE"
-
-EXTRA_OECONF = "--disable-test-application"
-
-# libtool adds "-nostdlib" when g++ is used. This breaks PIE builds.
-# Use libtool-cross (which has a hack to prevent that) instead.
-EXTRA_OEMAKE_class-target = "LIBTOOL=${STAGING_BINDIR_CROSS}/${HOST_SYS}-libtool"
-
-PACKAGES =+ "libvte"
-FILES_libvte = "${libdir}/*.so.* ${libdir}/girepository-1.0/*"
diff --git a/poky/meta/recipes-support/vte/vte_0.52.2.bb b/poky/meta/recipes-support/vte/vte_0.52.2.bb
new file mode 100644
index 0000000..7324c9c
--- /dev/null
+++ b/poky/meta/recipes-support/vte/vte_0.52.2.bb
@@ -0,0 +1,46 @@
+SUMMARY = "Virtual terminal emulator GTK+ widget library"
+BUGTRACKER = "https://bugzilla.gnome.org/buglist.cgi?product=vte"
+LICENSE = "LGPLv2.1+"
+DEPENDS = "glib-2.0 gtk+3 libpcre2 intltool-native libxml2-native gperf-native"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
+
+inherit gnomebase gtk-doc distro_features_check upstream-version-is-even gobject-introspection
+
+# vapigen.m4 is required when vala is not present (but the one from vala should be used normally)
+SRC_URI += "file://0001-Don-t-enable-stack-protection-by-default.patch \
+            ${@bb.utils.contains('PACKAGECONFIG', 'vala', '', 'file://0001-Add-m4-vapigen.m4.patch', d) } \
+            "
+SRC_URI[archive.md5sum] = "de8181350dccb010e915e366bdd06d18"
+SRC_URI[archive.sha256sum] = "0f2657cef52accbfe56feede553155552d7c1984b1291838af3cb8cfc19b26af"
+
+ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
+
+# Instead of "inherit vala" we do the relevant settings here so we can
+# set DEPENDS based on PACKAGECONFIG.
+
+# Our patched version of Vala looks in STAGING_DATADIR for .vapi files
+export STAGING_DATADIR
+# Upstream Vala >= 0.11 looks in XDG_DATA_DIRS for .vapi files
+export XDG_DATA_DIRS = "${STAGING_DATADIR}"
+
+# Help g-ir-scanner find the .so for linking
+do_compile_prepend() {
+        export GIR_EXTRA_LIBS_PATH="${B}/src/.libs"
+}
+
+# Package additional files
+FILES_${PN}-dev += "${datadir}/vala/vapi/*"
+
+PACKAGECONFIG ??= "gnutls"
+PACKAGECONFIG[vala] = "--enable-vala,--disable-vala,vala-native vala"
+PACKAGECONFIG[gnutls] = "--with-gnutls,--without-gnutls,gnutls"
+
+CFLAGS += "-D_GNU_SOURCE"
+
+# libtool adds "-nostdlib" when g++ is used. This breaks PIE builds.
+# Use libtool-cross (which has a hack to prevent that) instead.
+EXTRA_OEMAKE_class-target = "LIBTOOL=${STAGING_BINDIR_CROSS}/${HOST_SYS}-libtool"
+
+PACKAGES =+ "libvte"
+FILES_libvte = "${libdir}/*.so.* ${libdir}/girepository-1.0/*"
diff --git a/poky/meta/site/arc-common b/poky/meta/site/arc-common
new file mode 100644
index 0000000..d3c721a
--- /dev/null
+++ b/poky/meta/site/arc-common
@@ -0,0 +1,11 @@
+# general
+ac_cv_alignof_guint32=4
+ac_cv_alignof_guint64=4
+ac_cv_alignof_unsigned_long=4
+
+# glib-2.0
+glib_cv_stack_grows=${glib_cv_stack_grows=no}
+glib_cv_uscore=${glib_cv_uscore=no}
+
+# startup-notification
+lf_cv_sane_realloc=${lf_cv_sane_realloc=yes}
diff --git a/poky/scripts/autobuilder-worker-prereq-tests b/poky/scripts/autobuilder-worker-prereq-tests
new file mode 100755
index 0000000..bb46c69
--- /dev/null
+++ b/poky/scripts/autobuilder-worker-prereq-tests
@@ -0,0 +1,65 @@
+#!/bin/bash
+#
+# Script which can be run on new autobuilder workers to check all needed configuration is present.
+# Designed to be run in a repo where bitbake/oe-core are already present.
+#
+
+#
+# Todo
+# Add testtools/subunit import test
+# Add python3-git test
+# Add pigz test
+# vnc tests/checkvnc?
+# test sendmail works (for QA email notification)
+# test error report submission works
+# test buildistory git repo works?
+#
+
+. ./oe-init-build-env > /dev/null
+if [ "$?" != "0" ]; then
+    exit 1
+fi
+git config --global user.name > /dev/null
+if [ "$?" != "0" ]; then
+    echo "Please set git config --global user.name"
+    exit 1
+fi
+git config --global user.email > /dev/null
+if [ "$?" != "0" ]; then
+    echo "Please set git config --global user.email"
+    exit 1
+fi
+bitbake -p
+if [ "$?" != "0" ]; then
+    echo "Bitbake parsing failed"
+    exit 1
+fi
+
+WATCHES=$(PATH="/sbin:/usr/sbin:$PATH" sysctl fs.inotify.max_user_watches -n)
+if (( $WATCHES < 65000 )); then
+    echo 'Need to increase watches (echo fs.inotify.max_user_watches=65536 | sudo tee -a /etc/sysctl.conf'
+    exit 1
+fi
+mkdir -p tmp/deploy/images/qemux86-64
+pushd tmp/deploy/images/qemux86-64
+if [ ! -e core-image-minimal-qemux86-64.ext4 ]; then
+    wget http://downloads.yoctoproject.org/releases/yocto/yocto-2.5.1/machines/qemu/qemux86-64/core-image-minimal-qemux86-64.ext4
+fi
+if [ ! -e core-image-minimal-qemux86-64.qemuboot.conf ]; then
+    wget http://downloads.yoctoproject.org/releases/yocto/yocto-2.5.1/machines/qemu/qemux86-64/core-image-minimal-qemux86-64.qemuboot.conf
+fi
+if [ ! -e bzImage-qemux86-64.bin ]; then
+    wget http://downloads.yoctoproject.org/releases/yocto/yocto-2.5.1/machines/qemu/qemux86-64/bzImage-qemux86-64.bin
+fi
+popd
+bitbake qemu-helper-native
+runqemu qemux86-64
+if [ "$?" != "0" ]; then
+    echo "Unable to use runqemu"
+    exit 1
+fi
+runqemu qemux86-64 kvm
+if [ "$?" != "0" ]; then
+    echo "Unable to use runqemu with kvm"
+    exit 1
+fi
diff --git a/poky/scripts/combo-layer b/poky/scripts/combo-layer
index d04d88b..dc40e72 100755
--- a/poky/scripts/combo-layer
+++ b/poky/scripts/combo-layer
@@ -246,7 +246,7 @@
                         # traditional behavior from "git archive" (preserved
                         # here) it to choose the first one. This might not be
                         # intended, so at least warn about it.
-                        logger.warn("%s: initial revision '%s' not unique, picking result of rev-parse = %s" %
+                        logger.warning("%s: initial revision '%s' not unique, picking result of rev-parse = %s" %
                                     (name, initialrev, refs[0]))
                         initialrev = rev
                 except:
diff --git a/poky/scripts/contrib/mkefidisk.sh b/poky/scripts/contrib/mkefidisk.sh
deleted file mode 100755
index 39e4bcf..0000000
--- a/poky/scripts/contrib/mkefidisk.sh
+++ /dev/null
@@ -1,472 +0,0 @@
-#!/bin/sh
-#
-# Copyright (c) 2012, Intel Corporation.
-# All rights reserved.
-#
-# This program is free software;  you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY;  without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See
-# the GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program;  if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-#
-
-LANG=C
-
-echo
-echo "WARNING: This script is deprecated and will be removed soon."
-echo "Please consider using wic EFI images instead."
-echo
-
-# Set to 1 to enable additional output
-DEBUG=0
-OUT="/dev/null"
-
-#
-# Defaults
-#
-# 20 Mb for the boot partition
-BOOT_SIZE=20
-# 5% for swap
-SWAP_RATIO=5
-
-# Cleanup after die()
-cleanup() {
-	debug "Syncing and unmounting devices"
-	# Unmount anything we mounted
-	unmount $ROOTFS_MNT || error "Failed to unmount $ROOTFS_MNT"
-	unmount $BOOTFS_MNT || error "Failed to unmount $BOOTFS_MNT"
-	unmount $HDDIMG_ROOTFS_MNT || error "Failed to unmount $HDDIMG_ROOTFS_MNT"
-	unmount $HDDIMG_MNT || error "Failed to unmount $HDDIMG_MNT"
-
-	# Remove the TMPDIR
-	debug "Removing temporary files"
-	if [ -d "$TMPDIR" ]; then
-		rm -rf $TMPDIR || error "Failed to remove $TMPDIR"
-	fi
-}
-
-trap 'die "Signal Received, Aborting..."' HUP INT TERM
-
-# Logging routines
-WARNINGS=0
-ERRORS=0
-CLEAR="$(tput sgr0)"
-INFO="$(tput bold)"
-RED="$(tput setaf 1)$(tput bold)"
-GREEN="$(tput setaf 2)$(tput bold)"
-YELLOW="$(tput setaf 3)$(tput bold)"
-info() {
-	echo "${INFO}$1${CLEAR}"
-}
-error() {
-	ERRORS=$((ERRORS+1))
-	echo "${RED}$1${CLEAR}"
-}
-warn() {
-	WARNINGS=$((WARNINGS+1))
-	echo "${YELLOW}$1${CLEAR}"
-}
-success() {
-	echo "${GREEN}$1${CLEAR}"
-}
-die() {
-	error "$1"
-	cleanup
-	exit 1
-}
-debug() {
-	if [ $DEBUG -eq 1 ]; then
-		echo "$1"
-	fi
-}
-
-usage() {
-	echo "Usage: $(basename $0) [-v] DEVICE HDDIMG TARGET_DEVICE"
-	echo "       -v: Verbose debug"
-	echo "       DEVICE: The device to write the image to, e.g. /dev/sdh"
-	echo "       HDDIMG: The hddimg file to generate the efi disk from"
-	echo "       TARGET_DEVICE: The device the target will boot from, e.g.  /dev/mmcblk0"
-}
-
-image_details() {
-	IMG=$1
-	info "Image details"
-	echo "    image: $(stat --printf '%N\n' $IMG)"
-	echo "     size: $(stat -L --printf '%s bytes\n' $IMG)"
-	echo " modified: $(stat -L --printf '%y\n' $IMG)"
-	echo "     type: $(file -L -b $IMG)"
-	echo ""
-}
-
-device_details() {
-	DEV=$1
-	BLOCK_SIZE=512
-
-	info "Device details"
-	echo "  device: $DEVICE"
-	if [ -f "/sys/class/block/$DEV/device/vendor" ]; then
-		echo "  vendor: $(cat /sys/class/block/$DEV/device/vendor)"
-	else
-		echo "  vendor: UNKOWN"
-	fi
-	if [ -f "/sys/class/block/$DEV/device/model" ]; then
-		echo "   model: $(cat /sys/class/block/$DEV/device/model)"
-	else
-		echo "   model: UNKNOWN"
-	fi
-	if [ -f "/sys/class/block/$DEV/size" ]; then
-		echo "    size: $(($(cat /sys/class/block/$DEV/size) * $BLOCK_SIZE)) bytes"
-	else
-		echo "    size: UNKNOWN"
-	fi
-	echo ""
-}
-
-unmount_device() {
-	grep -q $DEVICE /proc/mounts
-	if [ $? -eq 0 ]; then
-		warn "$DEVICE listed in /proc/mounts, attempting to unmount"
-		umount $DEVICE* 2>/dev/null
-		return $?
-	fi
-	return 0
-}
-
-unmount() {
-	if [ "$1" = "" ] ; then
-		return 0
-	fi
-	grep -q $1 /proc/mounts
-	if [ $? -eq 0 ]; then
-		debug "Unmounting $1"
-		umount $1
-		return $?
-	fi
-	return 0
-}
-
-#
-# Parse and validate arguments
-#
-if [ $# -lt 3 ] || [ $# -gt 4 ]; then
-    if [ $# -eq 1 ]; then
-        AVAILABLE_DISK=`lsblk | grep "disk" | cut -f 1 -d " "`
-        X=0
-        for disk in `echo $AVAILABLE_DISK`; do
-            mounted=`lsblk /dev/$disk | awk {'print $7'} | sed "s/MOUNTPOINT//"`
-            if [ -z "$mounted" ]; then
-                UNMOUNTED_AVAILABLES="$UNMOUNTED_AVAILABLES /dev/$disk"
-                info "$X - /dev/$disk"
-                X=`expr $X + 1`
-            fi
-        done
-        if [ $X -eq 0 ]; then
-            die "No unmounted device found."
-        fi
-        read -p "Choose unmounted device number: " DISK_NUMBER
-        X=0
-        for line in `echo $UNMOUNTED_AVAILABLES`; do
-            if [ $DISK_NUMBER -eq $X ]; then
-                DISK_TO_BE_FLASHED=$line
-                break
-            else
-                X=`expr $X + 1`
-            fi
-        done
-        if [ -z "$DISK_TO_BE_FLASHED" ]; then
-            die "Option \"$DISK_NUMBER\" is invalid. Choose a valid option"
-        else
-            if [ -z `echo $DISK_TO_BE_FLASHED | grep "mmc"` ]; then
-                TARGET_TO_BE_BOOT="/dev/sda"
-            else
-                TARGET_TO_BE_BOOT="/dev/mmcblk0"
-            fi
-        fi
-        echo ""
-        echo "Choose a name of the device that will be boot from"
-        echo -n "Recommended name is: "
-        info "$TARGET_TO_BE_BOOT"
-        read -p "Is target device okay? [y/N]: " RESPONSE
-        if [ "$RESPONSE" != "y" ]; then
-            read -p "Choose target device name: " TARGET_TO_BE_BOOT
-        fi
-        echo ""
-        if [ -z "$TARGET_TO_BE_BOOT" ]; then
-            die "Error: choose a valid target name"
-        fi
-    else
-        usage
-	    exit 1
-    fi
-fi
-
-if [ "$1" = "-v" ]; then
-	DEBUG=1
-	OUT="1"
-	shift
-fi
-
-if [ -z "$AVAILABLE_DISK" ]; then
-    DEVICE=$1
-    HDDIMG=$2
-    TARGET_DEVICE=$3
-else
-    DEVICE=$DISK_TO_BE_FLASHED
-    HDDIMG=$1
-    TARGET_DEVICE=$TARGET_TO_BE_BOOT
-fi
-
-LINK=$(readlink $DEVICE)
-if [ $? -eq 0 ]; then
-	DEVICE="$LINK"
-fi
-
-if [ ! -w "$DEVICE" ]; then
-	usage
-	if [ ! -e "${DEVICE}" ] ; then
-		die "Device $DEVICE cannot be found"
-	else
-		die "Device $DEVICE is not writable (need to run under sudo?)"
-	fi
-fi
-
-if [ ! -e "$HDDIMG" ]; then
-	usage
-	die "HDDIMG $HDDIMG does not exist"
-fi
-
-#
-# Ensure the hddimg is not mounted
-#
-unmount "$HDDIMG" || die "Failed to unmount $HDDIMG"
-
-#
-# Check if any $DEVICE partitions are mounted
-#
-unmount_device || die "Failed to unmount $DEVICE"
-
-#
-# Confirm device with user
-#
-image_details $HDDIMG
-device_details $(basename $DEVICE)
-echo -n "${INFO}Prepare EFI image on $DEVICE [y/N]?${CLEAR} "
-read RESPONSE
-if [ "$RESPONSE" != "y" ]; then
-	echo "Image creation aborted"
-	exit 0
-fi
-
-
-#
-# Prepare the temporary working space
-#
-TMPDIR=$(mktemp -d mkefidisk-XXX) || die "Failed to create temporary mounting directory."
-HDDIMG_MNT=$TMPDIR/hddimg
-HDDIMG_ROOTFS_MNT=$TMPDIR/hddimg_rootfs
-ROOTFS_MNT=$TMPDIR/rootfs
-BOOTFS_MNT=$TMPDIR/bootfs
-mkdir $HDDIMG_MNT || die "Failed to create $HDDIMG_MNT"
-mkdir $HDDIMG_ROOTFS_MNT || die "Failed to create $HDDIMG_ROOTFS_MNT"
-mkdir $ROOTFS_MNT || die "Failed to create $ROOTFS_MNT"
-mkdir $BOOTFS_MNT || die "Failed to create $BOOTFS_MNT"
-
-
-#
-# Partition $DEVICE
-#
-DEVICE_SIZE=$(parted -s $DEVICE unit mb print | grep ^Disk | cut -d" " -f 3 | sed -e "s/MB//")
-# If the device size is not reported there may not be a valid label
-if [ "$DEVICE_SIZE" = "" ] ; then
-	parted -s $DEVICE mklabel msdos || die "Failed to create MSDOS partition table"
-	DEVICE_SIZE=$(parted -s $DEVICE unit mb print | grep ^Disk | cut -d" " -f 3 | sed -e "s/MB//")
-fi
-SWAP_SIZE=$((DEVICE_SIZE*SWAP_RATIO/100))
-ROOTFS_SIZE=$((DEVICE_SIZE-BOOT_SIZE-SWAP_SIZE))
-ROOTFS_START=$((BOOT_SIZE))
-ROOTFS_END=$((ROOTFS_START+ROOTFS_SIZE))
-SWAP_START=$((ROOTFS_END))
-
-# MMC devices use a partition prefix character 'p'
-PART_PREFIX=""
-if [ ! "${DEVICE#/dev/mmcblk}" = "${DEVICE}" ] || [ ! "${DEVICE#/dev/loop}" = "${DEVICE}" ]; then
-	PART_PREFIX="p"
-fi
-BOOTFS=$DEVICE${PART_PREFIX}1
-ROOTFS=$DEVICE${PART_PREFIX}2
-SWAP=$DEVICE${PART_PREFIX}3
-
-TARGET_PART_PREFIX=""
-if [ ! "${TARGET_DEVICE#/dev/mmcblk}" = "${TARGET_DEVICE}" ]; then
-	TARGET_PART_PREFIX="p"
-fi
-TARGET_ROOTFS=$TARGET_DEVICE${TARGET_PART_PREFIX}2
-TARGET_SWAP=$TARGET_DEVICE${TARGET_PART_PREFIX}3
-
-echo ""
-info "Boot partition size:   $BOOT_SIZE MB ($BOOTFS)"
-info "ROOTFS partition size: $ROOTFS_SIZE MB ($ROOTFS)"
-info "Swap partition size:   $SWAP_SIZE MB ($SWAP)"
-echo ""
-
-# Use MSDOS by default as GPT cannot be reliably distributed in disk image form
-# as it requires the backup table to be on the last block of the device, which
-# of course varies from device to device.
-
-info "Partitioning installation media ($DEVICE)"
-
-debug "Deleting partition table on $DEVICE"
-dd if=/dev/zero of=$DEVICE bs=512 count=2 >$OUT 2>&1 || die "Failed to zero beginning of $DEVICE"
-
-debug "Creating new partition table (MSDOS) on $DEVICE"
-parted -s $DEVICE mklabel msdos >$OUT 2>&1 || die "Failed to create MSDOS partition table"
-
-debug "Creating boot partition on $BOOTFS"
-parted -s $DEVICE mkpart primary 0% $BOOT_SIZE >$OUT 2>&1 || die "Failed to create BOOT partition"
-
-debug "Enabling boot flag on $BOOTFS"
-parted -s $DEVICE set 1 boot on >$OUT 2>&1 || die "Failed to enable boot flag"
-
-debug "Creating ROOTFS partition on $ROOTFS"
-parted -s $DEVICE mkpart primary $ROOTFS_START $ROOTFS_END >$OUT 2>&1 || die "Failed to create ROOTFS partition"
-
-debug "Creating swap partition on $SWAP"
-parted -s $DEVICE mkpart primary $SWAP_START 100% >$OUT 2>&1 || die "Failed to create SWAP partition"
-
-if [ $DEBUG -eq 1 ]; then
-	parted -s $DEVICE print
-fi
-
-
-#
-# Check if any $DEVICE partitions are mounted after partitioning
-#
-unmount_device || die "Failed to unmount $DEVICE partitions"
-
-
-#
-# Format $DEVICE partitions
-#
-info "Formatting partitions"
-debug "Formatting $BOOTFS as vfat"
-if [ ! "${DEVICE#/dev/loop}" = "${DEVICE}" ]; then
-	mkfs.vfat -I $BOOTFS -n "EFI" >$OUT 2>&1 || die "Failed to format $BOOTFS"
-else
-	mkfs.vfat $BOOTFS -n "EFI" >$OUT 2>&1 || die "Failed to format $BOOTFS"
-fi
-
-debug "Formatting $ROOTFS as ext3"
-mkfs.ext3 -F $ROOTFS -L "ROOT" >$OUT 2>&1 || die "Failed to format $ROOTFS"
-
-debug "Formatting swap partition ($SWAP)"
-mkswap $SWAP >$OUT 2>&1 || die "Failed to prepare swap"
-
-
-#
-# Installing to $DEVICE
-#
-debug "Mounting images and device in preparation for installation"
-mount -o ro,loop $HDDIMG $HDDIMG_MNT >$OUT 2>&1 || error "Failed to mount $HDDIMG"
-mount -o ro,loop $HDDIMG_MNT/rootfs.img $HDDIMG_ROOTFS_MNT >$OUT 2>&1 || error "Failed to mount rootfs.img"
-mount $ROOTFS $ROOTFS_MNT >$OUT 2>&1 || error "Failed to mount $ROOTFS on $ROOTFS_MNT"
-mount $BOOTFS $BOOTFS_MNT >$OUT 2>&1 || error "Failed to mount $BOOTFS on $BOOTFS_MNT"
-
-info "Preparing boot partition"
-EFIDIR="$BOOTFS_MNT/EFI/BOOT"
-# Get kernel image name
-if [ -e "$HDDIMG_MNT/vmlinuz" ]; then
-	kernel_image="vmlinuz"
-elif [ "$HDDIMG_MNT/bzImage" ]; then
-	kernel_image="bzImage"
-else
-	die "No kernel image found"
-fi
-cp $HDDIMG_MNT/${kernel_image} $BOOTFS_MNT >$OUT 2>&1 || error "Failed to copy ${kernel_image}"
-# Copy the efi loader and configs (booti*.efi and grub.cfg if it exists)
-cp -r $HDDIMG_MNT/EFI $BOOTFS_MNT >$OUT 2>&1 || error "Failed to copy EFI dir"
-# Silently ignore a missing systemd-boot loader dir (we might just be a GRUB image)
-cp -r $HDDIMG_MNT/loader $BOOTFS_MNT >$OUT 2>&1
-
-# Update the boot loaders configurations for an installed image
-# Remove any existing root= kernel parameters and:
-# o Add a root= parameter with the target rootfs
-# o Specify ro so fsck can be run during boot
-# o Specify rootwait in case the target media is an asyncronous block device
-#   such as MMC or USB disks
-# o Specify "quiet" to minimize boot time when using slow serial consoles
-
-# Look for a GRUB installation
-GRUB_CFG="$EFIDIR/grub.cfg"
-if [ -e "$GRUB_CFG" ]; then
-	info "Configuring GRUB"
-	# Delete the install entry
-	sed -i "/menuentry 'install'/,/^}/d" $GRUB_CFG
-	# Delete the initrd lines
-	sed -i "/initrd /d" $GRUB_CFG
-	# Delete any LABEL= strings
-	sed -i "s/ LABEL=[^ ]*/ /" $GRUB_CFG
-
-	sed -i "s@ root=[^ ]*@ @" $GRUB_CFG
-	sed -i "s@${kernel_image} @${kernel_image} root=$TARGET_ROOTFS ro rootwait console=ttyS0 console=tty0 @" $GRUB_CFG
-fi
-
-# Look for a systemd-boot installation
-SYSTEMD_BOOT_ENTRIES="$BOOTFS_MNT/loader/entries"
-SYSTEMD_BOOT_CFG="$SYSTEMD_BOOT_ENTRIES/boot.conf"
-if [ -d "$SYSTEMD_BOOT_ENTRIES" ]; then
-	info "Configuring SystemD-boot"
-	# remove the install target if it exists
-	rm $SYSTEMD_BOOT_ENTRIES/install.conf >$OUT 2>&1
-
-	if [ ! -e "$SYSTEMD_BOOT_CFG" ]; then
-		echo "ERROR: $SYSTEMD_BOOT_CFG not found"
-	fi
-
-	sed -i "/initrd /d" $SYSTEMD_BOOT_CFG
-	sed -i "s@ root=[^ ]*@ @" $SYSTEMD_BOOT_CFG
-	sed -i "s@options *LABEL=boot @options LABEL=Boot root=$TARGET_ROOTFS ro rootwait console=ttyS0 console=tty0 @" $SYSTEMD_BOOT_CFG
-fi
-
-# Ensure we have at least one EFI bootloader configured
-if [ ! -e $GRUB_CFG ] && [ ! -e $SYSTEMD_BOOT_CFG ]; then
-	die "No EFI bootloader configuration found"
-fi
-
-
-info "Copying ROOTFS files (this may take a while)"
-cp -a $HDDIMG_ROOTFS_MNT/* $ROOTFS_MNT >$OUT 2>&1 || die "Root FS copy failed"
-
-echo "$TARGET_SWAP     swap             swap       defaults              0 0" >> $ROOTFS_MNT/etc/fstab
-
-# We dont want udev to mount our root device while we're booting...
-if [ -d $ROOTFS_MNT/etc/udev/ ] ; then
-	echo "$TARGET_DEVICE" >> $ROOTFS_MNT/etc/udev/mount.blacklist
-fi
-
-# Add startup.nsh script for automated boot
-printf "fs0:\%s\BOOT\%s\n" "EFI" "bootx64.efi" > $BOOTFS_MNT/startup.nsh
-
-
-# Call cleanup to unmount devices and images and remove the TMPDIR
-cleanup
-
-echo ""
-if [ $WARNINGS -ne 0 ] && [ $ERRORS -eq 0 ]; then
-	echo "${YELLOW}Installation completed with warnings${CLEAR}"
-	echo "${YELLOW}Warnings: $WARNINGS${CLEAR}"
-elif [ $ERRORS -ne 0 ]; then
-	echo "${RED}Installation encountered errors${CLEAR}"
-	echo "${RED}Errors: $ERRORS${CLEAR}"
-	echo "${YELLOW}Warnings: $WARNINGS${CLEAR}"
-else
-	success "Installation completed successfully"
-fi
-echo ""
diff --git a/poky/scripts/contrib/patchreview.py b/poky/scripts/contrib/patchreview.py
index 4e3e73c..a4d5ba6 100755
--- a/poky/scripts/contrib/patchreview.py
+++ b/poky/scripts/contrib/patchreview.py
@@ -132,8 +132,8 @@
             need_blame = True
             if verbose:
                 print("Missing Signed-off-by tag (%s)" % patch)
-        # TODO: disable this for now as too much fails
-        if False and r.malformed_sob:
+
+        if r.malformed_sob:
             need_blame = True
             if verbose:
                 print("Malformed Signed-off-by '%s' (%s)" % (r.malformed_sob, patch))
@@ -203,7 +203,7 @@
 
     if args.directory:
         os.chdir(args.directory)
-    patches = subprocess.check_output(("git", "ls-files", "*.patch", "*.diff")).decode("utf-8").split()
+    patches = subprocess.check_output(("git", "ls-files", "recipes-*/**/*.patch", "recipes-*/**/*.diff")).decode("utf-8").split()
     results = patchreview(patches)
     analyse(results, want_blame=args.blame, verbose=args.verbose)
     if args.histogram:
diff --git a/poky/scripts/contrib/verify-homepage.py b/poky/scripts/contrib/verify-homepage.py
index 76f1749..cc6e797 100755
--- a/poky/scripts/contrib/verify-homepage.py
+++ b/poky/scripts/contrib/verify-homepage.py
@@ -27,7 +27,7 @@
 def wgetHomepage(pn, homepage):
     result = subprocess.call('wget ' + '-q -T 5 -t 1 --spider ' + homepage, shell = True)
     if result:
-        logger.warn("%s: failed to verify HOMEPAGE: %s " % (pn, homepage))
+        logger.warning("%s: failed to verify HOMEPAGE: %s " % (pn, homepage))
         return 1
     else:
         return 0
diff --git a/poky/scripts/devtool b/poky/scripts/devtool
index d681a19..0e578c0 100755
--- a/poky/scripts/devtool
+++ b/poky/scripts/devtool
@@ -51,7 +51,7 @@
 
     def __init__(self, filename):
         self.config_file = filename
-        self.config_obj = configparser.SafeConfigParser()
+        self.config_obj = configparser.ConfigParser()
 
     def get(self, section, option, default=None):
         try:
diff --git a/poky/scripts/lib/build_perf/html/report.html b/poky/scripts/lib/build_perf/html/report.html
index 291ad9d..d1ba6f2 100644
--- a/poky/scripts/lib/build_perf/html/report.html
+++ b/poky/scripts/lib/build_perf/html/report.html
@@ -136,10 +136,13 @@
             {% else %}
               {% set result_style = "color: orange" %}
             {%endif %}
+            {% if measurement.reldiff|abs > 2 %}
+              {% set result_style = result_style + "; font-weight: bold" %}
+            {% endif %}
             <td>{{ measurement.description }}</td>
             <td style="font-weight: bold">{{ measurement.value.mean }}</td>
             <td style="{{ result_style }}">{{ measurement.absdiff_str }}</td>
-            <td style="{{ result_style }}">{{ measurement.reldiff }}</td>
+            <td style="{{ result_style }}">{{ measurement.reldiff_str }}</td>
           </tr>
         {% endfor %}
       {% else %}
@@ -167,7 +170,7 @@
             {% else %}
             <span style="color: orange">
             {% endif %}
-            {{ measurement.absdiff_str }} ({{measurement.reldiff}})
+            {{ measurement.absdiff_str }} ({{measurement.reldiff_str}})
             </span></span>
           </div>
           {# Table for trendchart and the statistics #}
diff --git a/poky/scripts/lib/devtool/build.py b/poky/scripts/lib/devtool/build.py
index 252379e..ba9593f 100644
--- a/poky/scripts/lib/devtool/build.py
+++ b/poky/scripts/lib/devtool/build.py
@@ -54,7 +54,11 @@
     """Entry point for the devtool 'build' subcommand"""
     workspacepn = check_workspace_recipe(workspace, args.recipename, bbclassextend=True)
 
-    build_tasks = _get_build_tasks(config)
+    if args.clean:
+        # use clean instead of cleansstate to avoid messing things up in eSDK
+        build_tasks = ['do_clean']
+    else:
+        build_tasks = _get_build_tasks(config)
 
     bbappend = workspace[workspacepn]['bbappend']
     if args.disable_parallel_make:
@@ -83,4 +87,5 @@
                                          group='working', order=50)
     parser_build.add_argument('recipename', help='Recipe to build')
     parser_build.add_argument('-s', '--disable-parallel-make', action="store_true", help='Disable make parallelism')
+    parser_build.add_argument('-c', '--clean', action='store_true', help='clean up recipe building results')
     parser_build.set_defaults(func=build)
diff --git a/poky/scripts/lib/devtool/export.py b/poky/scripts/lib/devtool/export.py
index 13ee258..35349e2 100644
--- a/poky/scripts/lib/devtool/export.py
+++ b/poky/scripts/lib/devtool/export.py
@@ -84,7 +84,7 @@
 
     # if all workspace is excluded, quit
     if not len(set(workspace.keys()).difference(set(args.exclude))):
-        logger.warn('All recipes in workspace excluded, nothing to export')
+        logger.warning('All recipes in workspace excluded, nothing to export')
         return 0
 
     exported = []
diff --git a/poky/scripts/lib/devtool/import.py b/poky/scripts/lib/devtool/import.py
index c13a180..4264b7d 100644
--- a/poky/scripts/lib/devtool/import.py
+++ b/poky/scripts/lib/devtool/import.py
@@ -81,7 +81,7 @@
                     break
             else:
                 non_importables.append(fn)
-                logger.warn('No recipe to append %s.bbapppend, skipping' % fn)
+                logger.warning('No recipe to append %s.bbapppend, skipping' % fn)
 
         # Extract
         imported = []
@@ -104,9 +104,9 @@
                         try:
                             tar.extract(member, path=config.workspace_path)
                         except PermissionError as pe:
-                            logger.warn(pe)
+                            logger.warning(pe)
                     else:
-                        logger.warn('File already present. Use --overwrite/-o to overwrite it: %s' % member.name)
+                        logger.warning('File already present. Use --overwrite/-o to overwrite it: %s' % member.name)
                         continue
                 else:
                     tar.extract(member, path=config.workspace_path)
@@ -129,7 +129,7 @@
     if imported:
         logger.info('Imported recipes into workspace %s: %s' % (config.workspace_path, ', '.join(imported)))
     else:
-        logger.warn('No recipes imported into the workspace')
+        logger.warning('No recipes imported into the workspace')
 
     return 0
 
diff --git a/poky/scripts/lib/devtool/standard.py b/poky/scripts/lib/devtool/standard.py
index a1e8e1d..d14b7a6 100644
--- a/poky/scripts/lib/devtool/standard.py
+++ b/poky/scripts/lib/devtool/standard.py
@@ -66,7 +66,7 @@
             args.srctree = args.recipename
             args.recipename = None
         elif os.path.isdir(args.recipename):
-            logger.warn('Ambiguous argument "%s" - assuming you mean it to be the recipe name' % args.recipename)
+            logger.warning('Ambiguous argument "%s" - assuming you mean it to be the recipe name' % args.recipename)
 
     if not args.fetchuri:
         if args.srcrev:
@@ -82,7 +82,7 @@
         if args.fetchuri:
             raise DevtoolError('URI specified as positional argument as well as -f/--fetch')
         else:
-            logger.warn('-f/--fetch option is deprecated - you can now simply specify the URL to fetch as a positional argument instead')
+            logger.warning('-f/--fetch option is deprecated - you can now simply specify the URL to fetch as a positional argument instead')
             args.fetchuri = args.fetch
 
     if args.recipename:
@@ -217,7 +217,7 @@
             raise DevtoolError('Command \'%s\' did not create any recipe file:\n%s' % (e.command, e.stdout))
         attic_recipe = os.path.join(config.workspace_path, 'attic', recipename, os.path.basename(recipefile))
         if os.path.exists(attic_recipe):
-            logger.warn('A modified recipe from a previous invocation exists in %s - you may wish to move this over the top of the new recipe if you had changes in it that you want to continue with' % attic_recipe)
+            logger.warning('A modified recipe from a previous invocation exists in %s - you may wish to move this over the top of the new recipe if you had changes in it that you want to continue with' % attic_recipe)
     finally:
         if tmpsrcdir and os.path.exists(tmpsrcdir):
             shutil.rmtree(tmpsrcdir)
@@ -295,7 +295,7 @@
                     with open(layerconf_file, 'a') as f:
                         f.write('%s = "%s"\n' % (preferred_provider, recipe_name))
                 else:
-                    logger.warn('Set \'%s\' in order to use the recipe' % preferred_provider)
+                    logger.warning('Set \'%s\' in order to use the recipe' % preferred_provider)
                 break
 
         _add_md5(config, recipename, appendfile)
@@ -704,7 +704,7 @@
                     if splitline[2] != md5:
                         bb.utils.mkdirhier(preservepath)
                         preservefile = os.path.basename(removefile)
-                        logger.warn('File %s modified since it was written, preserving in %s' % (preservefile, preservepath))
+                        logger.warning('File %s modified since it was written, preserving in %s' % (preservefile, preservepath))
                         shutil.move(removefile, os.path.join(preservepath, preservefile))
                     else:
                         os.remove(removefile)
@@ -795,7 +795,7 @@
                 if branchname.startswith(override_branch_prefix):
                     branches.append(branchname)
             if branches:
-                logger.warn('SRC_URI is conditionally overridden in this recipe, thus several %s* branches have been created, one for each override that makes changes to SRC_URI. It is recommended that you make changes to the %s branch first, then checkout and rebase each %s* branch and update any unique patches there (duplicates on those branches will be ignored by devtool finish/update-recipe)' % (override_branch_prefix, args.branch, override_branch_prefix))
+                logger.warning('SRC_URI is conditionally overridden in this recipe, thus several %s* branches have been created, one for each override that makes changes to SRC_URI. It is recommended that you make changes to the %s branch first, then checkout and rebase each %s* branch and update any unique patches there (duplicates on those branches will be ignored by devtool finish/update-recipe)' % (override_branch_prefix, args.branch, override_branch_prefix))
             branches.insert(0, args.branch)
             seen_patches = []
             for branch in branches:
@@ -1720,7 +1720,7 @@
         if updated:
             rf = rd.getVar('FILE')
             if rf.startswith(config.workspace_path):
-                logger.warn('Recipe file %s has been updated but is inside the workspace - you will need to move it (and any associated files next to it) out to the desired layer before using "devtool reset" in order to keep any changes' % rf)
+                logger.warning('Recipe file %s has been updated but is inside the workspace - you will need to move it (and any associated files next to it) out to the desired layer before using "devtool reset" in order to keep any changes' % rf)
     finally:
         tinfoil.shutdown()
 
@@ -1803,7 +1803,7 @@
             if os.path.exists(origdir):
                 for root, dirs, files in os.walk(origdir):
                     for fn in files:
-                        logger.warn('Preserving %s in %s' % (fn, preservepath))
+                        logger.warning('Preserving %s in %s' % (fn, preservepath))
                         _move_file(os.path.join(origdir, fn),
                                    os.path.join(preservepath, fn))
                     for dn in dirs:
diff --git a/poky/scripts/lib/devtool/upgrade.py b/poky/scripts/lib/devtool/upgrade.py
index c3fd866..2020077 100644
--- a/poky/scripts/lib/devtool/upgrade.py
+++ b/poky/scripts/lib/devtool/upgrade.py
@@ -264,7 +264,7 @@
     if no_patch:
         patches = oe.recipeutils.get_recipe_patches(crd)
         if patches:
-            logger.warn('By user choice, the following patches will NOT be applied to the new source tree:\n  %s' % '\n  '.join([os.path.basename(patch) for patch in patches]))
+            logger.warning('By user choice, the following patches will NOT be applied to the new source tree:\n  %s' % '\n  '.join([os.path.basename(patch) for patch in patches]))
     else:
         __run('git checkout devtool-patched -b %s' % branch)
         skiptag = False
@@ -273,9 +273,9 @@
         except bb.process.ExecutionError as e:
             skiptag = True
             if 'conflict' in e.stdout:
-                logger.warn('Command \'%s\' failed:\n%s\n\nYou will need to resolve conflicts in order to complete the upgrade.' % (e.command, e.stdout.rstrip()))
+                logger.warning('Command \'%s\' failed:\n%s\n\nYou will need to resolve conflicts in order to complete the upgrade.' % (e.command, e.stdout.rstrip()))
             else:
-                logger.warn('Command \'%s\' failed:\n%s' % (e.command, e.stdout))
+                logger.warning('Command \'%s\' failed:\n%s' % (e.command, e.stdout))
         if not skiptag:
             if uri.startswith('git://'):
                 suffix = 'new'
@@ -420,7 +420,10 @@
                 logger.info('Source subdirectory has changed, updating S value')
 
     if license_diff:
-        newlicchksum = " ".join(["file://{};md5={}".format(l["path"], l["actual_md5"]) + (";beginline={}".format(l["beginline"]) if l["beginline"] else "") + (";endline={}".format(l["endline"]) if l["endline"] else "") for l in new_licenses])
+        newlicchksum = " ".join(["file://{}".format(l['path']) +
+                                 (";beginline={}".format(l['beginline']) if l['beginline'] else "") +
+                                 (";endline={}".format(l['endline']) if l['endline'] else "") +
+                                 (";md5={}".format(l['actual_md5'])) for l in new_licenses])
         newvalues["LIC_FILES_CHKSUM"] = newlicchksum
         _add_license_diff_to_recipe(fullpath, license_diff)
 
diff --git a/poky/scripts/lib/recipetool/append.py b/poky/scripts/lib/recipetool/append.py
index 69c8bb7..3f2c134 100644
--- a/poky/scripts/lib/recipetool/append.py
+++ b/poky/scripts/lib/recipetool/append.py
@@ -238,7 +238,7 @@
     if stdout:
         logger.debug('file command output: %s' % stdout.rstrip())
         if ('executable' in stdout and not 'shell script' in stdout) or 'shared object' in stdout:
-            logger.warn('This file looks like it is a binary or otherwise the output of compilation. If it is, you should consider building it properly instead of substituting a binary file directly.')
+            logger.warning('This file looks like it is a binary or otherwise the output of compilation. If it is, you should consider building it properly instead of substituting a binary file directly.')
 
     if args.recipe:
         recipes = {args.targetpath: [args.recipe],}
@@ -275,7 +275,7 @@
     if selectpn:
         logger.debug('Selecting recipe %s for file %s' % (selectpn, args.targetpath))
         if postinst_pns:
-            logger.warn('%s be modified by postinstall scripts for the following recipes:\n  %s\nThis may or may not be an issue depending on what modifications these postinstall scripts make.' % (args.targetpath, '\n  '.join(postinst_pns)))
+            logger.warning('%s be modified by postinstall scripts for the following recipes:\n  %s\nThis may or may not be an issue depending on what modifications these postinstall scripts make.' % (args.targetpath, '\n  '.join(postinst_pns)))
         rd = _parse_recipe(selectpn, tinfoil)
         if not rd:
             # Error message already shown
@@ -286,12 +286,12 @@
             sourcetype, sourcepath = sourcefile.split('://', 1)
             logger.debug('Original source file is %s (%s)' % (sourcepath, sourcetype))
             if sourcetype == 'patch':
-                logger.warn('File %s is added by the patch %s - you may need to remove or replace this patch in order to replace the file.' % (args.targetpath, sourcepath))
+                logger.warning('File %s is added by the patch %s - you may need to remove or replace this patch in order to replace the file.' % (args.targetpath, sourcepath))
                 sourcepath = None
         else:
             logger.debug('Unable to determine source file, proceeding anyway')
         if modpatches:
-            logger.warn('File %s is modified by the following patches:\n  %s' % (args.targetpath, '\n  '.join(modpatches)))
+            logger.warning('File %s is modified by the following patches:\n  %s' % (args.targetpath, '\n  '.join(modpatches)))
 
         if instelements and sourcepath:
             install = None
@@ -343,7 +343,7 @@
             if rd.getVar('S') == rd.getVar('STAGING_KERNEL_DIR'):
                 srcdir = os.path.join(workdir, 'git')
                 if not bb.data.inherits_class('kernel-yocto', rd):
-                    logger.warn('S == STAGING_KERNEL_DIR and non-kernel-yocto, unable to determine path to srcdir, defaulting to ${WORKDIR}/git')
+                    logger.warning('S == STAGING_KERNEL_DIR and non-kernel-yocto, unable to determine path to srcdir, defaulting to ${WORKDIR}/git')
             src_destdir = os.path.join(os.path.relpath(srcdir, workdir), src_destdir)
         src_destdir = os.path.normpath(src_destdir)
 
@@ -357,9 +357,9 @@
         if simple_str in simplified:
             existing = simplified[simple_str]
             if source_uri != existing:
-                logger.warn('{0!r} is already in SRC_URI, with different parameters: {1!r}, not adding'.format(source_uri, existing))
+                logger.warning('{0!r} is already in SRC_URI, with different parameters: {1!r}, not adding'.format(source_uri, existing))
             else:
-                logger.warn('{0!r} is already in SRC_URI, not adding'.format(source_uri))
+                logger.warning('{0!r} is already in SRC_URI, not adding'.format(source_uri))
         else:
             extralines.append('SRC_URI += {0}'.format(source_uri))
         copyfiles[newfile] = srcfile
diff --git a/poky/scripts/lib/recipetool/create.py b/poky/scripts/lib/recipetool/create.py
index a371028..1810c70 100644
--- a/poky/scripts/lib/recipetool/create.py
+++ b/poky/scripts/lib/recipetool/create.py
@@ -98,7 +98,7 @@
                             break
             except IOError as ioe:
                 if ioe.errno == 2:
-                    logger.warn('unable to find a pkgdata file for package %s' % pkg)
+                    logger.warning('unable to find a pkgdata file for package %s' % pkg)
                 else:
                     raise
 
@@ -437,7 +437,7 @@
     if scriptutils.is_src_url(source):
         # Warn about github archive URLs
         if re.match('https?://github.com/[^/]+/[^/]+/archive/.+(\.tar\..*|\.zip)$', source):
-            logger.warn('github archive files are not guaranteed to be stable and may be re-generated over time. If the latter occurs, the checksums will likely change and the recipe will fail at do_fetch. It is recommended that you point to an actual commit or tag in the repository instead (using the repository URL in conjunction with the -S/--srcrev option).')
+            logger.warning('github archive files are not guaranteed to be stable and may be re-generated over time. If the latter occurs, the checksums will likely change and the recipe will fail at do_fetch. It is recommended that you point to an actual commit or tag in the repository instead (using the repository URL in conjunction with the -S/--srcrev option).')
         # Fetch a URL
         fetchuri = reformat_git_uri(urldefrag(source)[0])
         if args.binary:
diff --git a/poky/scripts/lib/recipetool/create_kmod.py b/poky/scripts/lib/recipetool/create_kmod.py
index 4569b53..3982537 100644
--- a/poky/scripts/lib/recipetool/create_kmod.py
+++ b/poky/scripts/lib/recipetool/create_kmod.py
@@ -141,7 +141,7 @@
                 warnmsg = 'Unable to find means of passing kernel path into install makefile - if kernel path is hardcoded you will need to patch the makefile'
             if warnmsg:
                 warnmsg += '. Note that the variable KERNEL_SRC will be passed in as the kernel source path.'
-                logger.warn(warnmsg)
+                logger.warning(warnmsg)
                 lines_after.append('# %s' % warnmsg)
 
             return True
diff --git a/poky/scripts/lib/recipetool/create_npm.py b/poky/scripts/lib/recipetool/create_npm.py
index bb42a5c..0366788 100644
--- a/poky/scripts/lib/recipetool/create_npm.py
+++ b/poky/scripts/lib/recipetool/create_npm.py
@@ -90,7 +90,7 @@
             runenv = dict(os.environ, PATH=d.getVar('PATH'))
             bb.process.run('npm shrinkwrap', cwd=srctree, stderr=subprocess.STDOUT, env=runenv, shell=True)
         except bb.process.ExecutionError as e:
-            logger.warn('npm shrinkwrap failed:\n%s' % e.stdout)
+            logger.warning('npm shrinkwrap failed:\n%s' % e.stdout)
             return
 
         tmpfile = os.path.join(localfilesdir, 'npm-shrinkwrap.json')
@@ -107,12 +107,12 @@
                            cwd=srctree, stderr=subprocess.STDOUT, env=runenv, shell=True)
         relockbin = os.path.join(NpmRecipeHandler.lockdownpath, 'node_modules', 'lockdown', 'relock.js')
         if not os.path.exists(relockbin):
-            logger.warn('Could not find relock.js within lockdown directory; skipping lockdown')
+            logger.warning('Could not find relock.js within lockdown directory; skipping lockdown')
             return
         try:
             bb.process.run('node %s' % relockbin, cwd=srctree, stderr=subprocess.STDOUT, env=runenv, shell=True)
         except bb.process.ExecutionError as e:
-            logger.warn('lockdown-relock failed:\n%s' % e.stdout)
+            logger.warning('lockdown-relock failed:\n%s' % e.stdout)
             return
 
         tmpfile = os.path.join(localfilesdir, 'lockdown.json')
diff --git a/poky/scripts/lib/recipetool/edit.py b/poky/scripts/lib/recipetool/edit.py
new file mode 100644
index 0000000..c4789a9
--- /dev/null
+++ b/poky/scripts/lib/recipetool/edit.py
@@ -0,0 +1,54 @@
+# Recipe creation tool - edit plugin
+#
+# This sub-command edits the recipe and appends for the specified target
+#
+# Example: recipetool edit busybox
+#
+# Copyright (C) 2018 Mentor Graphics Corporation
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License version 2 as
+# published by the Free Software Foundation.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License along
+# with this program; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+import argparse
+import errno
+import logging
+import os
+import re
+import subprocess
+import sys
+import scriptutils
+
+
+logger = logging.getLogger('recipetool')
+tinfoil = None
+
+
+def tinfoil_init(instance):
+    global tinfoil
+    tinfoil = instance
+
+
+def edit(args):
+    import oe.recipeutils
+
+    recipe_path = tinfoil.get_recipe_file(args.target)
+    appends = tinfoil.get_file_appends(recipe_path)
+
+    return scriptutils.run_editor([recipe_path] + appends, logger)
+
+
+def register_commands(subparsers):
+    parser = subparsers.add_parser('edit',
+                                   help='Edit the recipe and appends for the specified target. This obeys $VISUAL if set, otherwise $EDITOR, otherwise vi.')
+    parser.add_argument('target', help='Target recipe/provide to edit')
+    parser.set_defaults(func=edit, parserecipes=True)
diff --git a/poky/scripts/lib/recipetool/newappend.py b/poky/scripts/lib/recipetool/newappend.py
index decce83..76707b4 100644
--- a/poky/scripts/lib/recipetool/newappend.py
+++ b/poky/scripts/lib/recipetool/newappend.py
@@ -58,11 +58,11 @@
         return 1
 
     if not path_ok:
-        logger.warn('Unable to determine correct subdirectory path for bbappend file - check that what %s adds to BBFILES also matches .bbappend files. Using %s for now, but until you fix this the bbappend will not be applied.', os.path.join(args.destlayer, 'conf', 'layer.conf'), os.path.dirname(append_path))
+        logger.warning('Unable to determine correct subdirectory path for bbappend file - check that what %s adds to BBFILES also matches .bbappend files. Using %s for now, but until you fix this the bbappend will not be applied.', os.path.join(args.destlayer, 'conf', 'layer.conf'), os.path.dirname(append_path))
 
     layerdirs = [os.path.abspath(layerdir) for layerdir in rd.getVar('BBLAYERS').split()]
     if not os.path.abspath(args.destlayer) in layerdirs:
-        logger.warn('Specified layer is not currently enabled in bblayers.conf, you will need to add it before this bbappend will be active')
+        logger.warning('Specified layer is not currently enabled in bblayers.conf, you will need to add it before this bbappend will be active')
 
     if not os.path.exists(append_path):
         bb.utils.mkdirhier(os.path.dirname(append_path))
diff --git a/poky/scripts/lib/scriptutils.py b/poky/scripts/lib/scriptutils.py
index 85b1c94..31e48ea 100644
--- a/poky/scripts/lib/scriptutils.py
+++ b/poky/scripts/lib/scriptutils.py
@@ -15,16 +15,17 @@
 # with this program; if not, write to the Free Software Foundation, Inc.,
 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
 
-import sys
-import os
-import logging
-import glob
 import argparse
-import subprocess
-import tempfile
-import shutil
+import glob
+import logging
+import os
 import random
+import shlex
+import shutil
 import string
+import subprocess
+import sys
+import tempfile
 
 def logger_create(name, stream=None):
     logger = logging.getLogger(name)
@@ -214,15 +215,14 @@
 
 def run_editor(fn, logger=None):
     if isinstance(fn, str):
-        params = '"%s"' % fn
+        files = [fn]
     else:
-        params = ''
-        for fnitem in fn:
-            params += ' "%s"' % fnitem
+        files = fn
 
     editor = os.getenv('VISUAL', os.getenv('EDITOR', 'vi'))
     try:
-        return subprocess.check_call('%s %s' % (editor, params), shell=True)
+        #print(shlex.split(editor) + files)
+        return subprocess.check_call(shlex.split(editor) + files)
     except subprocess.CalledProcessError as exc:
         logger.error("Execution of '%s' failed: %s" % (editor, exc))
         return 1
diff --git a/poky/scripts/lib/wic/canned-wks/mkhybridiso.wks b/poky/scripts/lib/wic/canned-wks/mkhybridiso.wks
index 9d34e9b..48c5ac4 100644
--- a/poky/scripts/lib/wic/canned-wks/mkhybridiso.wks
+++ b/poky/scripts/lib/wic/canned-wks/mkhybridiso.wks
@@ -2,6 +2,6 @@
 # long-description: Creates an EFI and legacy bootable hybrid ISO image
 # which can be used on optical media as well as USB media.
 
-part /boot --source isoimage-isohybrid --sourceparams="loader=grub-efi,image_name=HYBRID_ISO_IMG" --ondisk cd --label HYBRIDISO --fstype=ext4
+part /boot --source isoimage-isohybrid --sourceparams="loader=grub-efi,image_name=HYBRID_ISO_IMG" --ondisk cd --label HYBRIDISO
 
 bootloader  --timeout=15  --append=""
diff --git a/poky/scripts/lib/wic/engine.py b/poky/scripts/lib/wic/engine.py
index f0c5ff0..4662c66 100644
--- a/poky/scripts/lib/wic/engine.py
+++ b/poky/scripts/lib/wic/engine.py
@@ -191,7 +191,7 @@
     if not os.path.exists(options.outdir):
         os.makedirs(options.outdir)
 
-    pname = 'direct'
+    pname = options.imager
     plugin_class = PluginMgr.get_plugins('imager').get(pname)
     if not plugin_class:
         raise WicError('Unknown plugin: %s' % pname)
@@ -266,10 +266,15 @@
             out = exec_cmd("%s -sm %s unit B print" % (self.parted, self.imagepath))
             parttype = namedtuple("Part", "pnum start end size fstype")
             splitted = out.splitlines()
-            lsector_size, psector_size, self._ptable_format = splitted[1].split(":")[3:6]
+            # skip over possible errors in exec_cmd output
+            try:
+                idx =splitted.index("BYT;")
+            except ValueError:
+                raise WicError("Error getting partition information from %s" % (self.parted))
+            lsector_size, psector_size, self._ptable_format = splitted[idx + 1].split(":")[3:6]
             self._lsector_size = int(lsector_size)
             self._psector_size = int(psector_size)
-            for line in splitted[2:]:
+            for line in splitted[idx + 2:]:
                 pnum, start, end, size, fstype = line.split(':')[:5]
                 partition = parttype(int(pnum), int(start[:-1]), int(end[:-1]),
                                      int(size[:-1]), fstype)
@@ -340,9 +345,21 @@
         """Remove files/dirs from the partition."""
         partimg = self._get_part_image(pnum)
         if self.partitions[pnum].fstype.startswith('ext'):
-            exec_cmd("{} {} -wR 'rm {}'".format(self.debugfs,
+            cmd = "{} {} -wR 'rm {}'".format(self.debugfs,
                                                 self._get_part_image(pnum),
-                                                path), as_shell=True)
+                                                path)
+            out = exec_cmd(cmd , as_shell=True)
+            for line in out.splitlines():
+                if line.startswith("rm:"):
+                    if "file is a directory" in line:
+                        # Try rmdir to see if this is an empty directory. This won't delete
+                        # any non empty directory so let user know about any error that this might
+                        # generate.
+                        print(exec_cmd("{} {} -wR 'rmdir {}'".format(self.debugfs,
+                                                    self._get_part_image(pnum),
+                                                    path), as_shell=True))
+                    else:
+                        raise WicError("Could not complete operation: wic %s" % str(line))
         else: # fat
             cmd = "{} -i {} ::{}".format(self.mdel, partimg, path)
             try:
@@ -494,7 +511,7 @@
                     sparse_copy(partfname, target, seek=part['start'] * self._lsector_size)
                     os.unlink(partfname)
                 elif part['type'] != 'f':
-                    logger.warn("skipping partition {}: unsupported fstype {}".format(pnum, fstype))
+                    logger.warning("skipping partition {}: unsupported fstype {}".format(pnum, fstype))
 
 def wic_ls(args, native_sysroot):
     """List contents of partitioned image or vfat partition."""
diff --git a/poky/scripts/lib/wic/filemap.py b/poky/scripts/lib/wic/filemap.py
index a72fa09..abbf958 100644
--- a/poky/scripts/lib/wic/filemap.py
+++ b/poky/scripts/lib/wic/filemap.py
@@ -22,6 +22,7 @@
 #   * Too many instance attributes (R0902)
 # pylint: disable=R0902
 
+import errno
 import os
 import struct
 import array
@@ -189,9 +190,9 @@
     except OSError as err:
         # The 'lseek' system call returns the ENXIO if there is no data or
         # hole starting from the specified offset.
-        if err.errno == os.errno.ENXIO:
+        if err.errno == errno.ENXIO:
             return -1
-        elif err.errno == os.errno.EINVAL:
+        elif err.errno == errno.EINVAL:
             raise ErrorNotSupp("the kernel or file-system does not support "
                                "\"SEEK_HOLE\" and \"SEEK_DATA\"")
         else:
@@ -394,12 +395,12 @@
         except IOError as err:
             # Note, the FIEMAP ioctl is supported by the Linux kernel starting
             # from version 2.6.28 (year 2008).
-            if err.errno == os.errno.EOPNOTSUPP:
+            if err.errno == errno.EOPNOTSUPP:
                 errstr = "FilemapFiemap: the FIEMAP ioctl is not supported " \
                          "by the file-system"
                 self._log.debug(errstr)
                 raise ErrorNotSupp(errstr)
-            if err.errno == os.errno.ENOTTY:
+            if err.errno == errno.ENOTTY:
                 errstr = "FilemapFiemap: the FIEMAP ioctl is not supported " \
                          "by the kernel"
                 self._log.debug(errstr)
diff --git a/poky/scripts/lib/wic/help.py b/poky/scripts/lib/wic/help.py
index 842b868..64f0805 100644
--- a/poky/scripts/lib/wic/help.py
+++ b/poky/scripts/lib/wic/help.py
@@ -866,11 +866,11 @@
        Partitions with a <mountpoint> specified will be automatically mounted.
        This is achieved by wic adding entries to the fstab during image
        generation. In order for a valid fstab to be generated one of the
-       --ondrive, --ondisk or --use-uuid partition options must be used for
-       each partition that specifies a mountpoint.  Note that with --use-uuid
-       and non-root <mountpoint>, including swap, the mount program must
-       understand the PARTUUID syntax.  This currently excludes the busybox
-       versions of these applications.
+       --ondrive, --ondisk, --use-uuid or --use-label partition options must
+       be used for each partition that specifies a mountpoint.  Note that with
+       --use-{uuid,label} and non-root <mountpoint>, including swap, the mount
+       program must understand the PARTUUID or LABEL syntax.  This currently
+       excludes the busybox versions of these applications.
 
 
        The following are supported 'part' options:
@@ -945,6 +945,14 @@
                         label is already in use by another filesystem,
                         a new label is created for the partition.
 
+         --use-label: This option is specific to wic. It makes wic to use the
+                      label in /etc/fstab to specify a partition. If the
+                      --use-label and --use-uuid are used at the same time,
+                      we prefer the uuid because it is less likely to cause
+                      name confliction. We don't support using this parameter
+                      on the root partition since it requires an initramfs to
+                      parse this value and we do not currently support that.
+
          --active: Marks the partition as active.
 
          --align (in KBytes): This option is specific to wic and says
diff --git a/poky/scripts/lib/wic/ksparser.py b/poky/scripts/lib/wic/ksparser.py
index e590b2f..7e5a9c5 100644
--- a/poky/scripts/lib/wic/ksparser.py
+++ b/poky/scripts/lib/wic/ksparser.py
@@ -141,6 +141,7 @@
                                    'squashfs', 'vfat', 'msdos', 'swap'))
         part.add_argument('--mkfs-extraopts', default='')
         part.add_argument('--label')
+        part.add_argument('--use-label', action='store_true')
         part.add_argument('--no-table', action='store_true')
         part.add_argument('--ondisk', '--ondrive', dest='disk', default='sda')
         part.add_argument("--overhead-factor", type=overheadtype)
@@ -196,9 +197,18 @@
                         raise KickStartError('%s:%d: %s' % \
                                              (confpath, lineno, err))
                     if line.startswith('part'):
-                        # SquashFS does not support UUID
-                        if parsed.fstype == 'squashfs' and parsed.use_uuid:
-                            err = "%s:%d: SquashFS does not support UUID" \
+                        # SquashFS does not support filesystem UUID
+                        if parsed.fstype == 'squashfs':
+                            if parsed.fsuuid:
+                                err = "%s:%d: SquashFS does not support UUID" \
+                                       % (confpath, lineno)
+                                raise KickStartError(err)
+                            if parsed.label:
+                                err = "%s:%d: SquashFS does not support LABEL" \
+                                       % (confpath, lineno)
+                                raise KickStartError(err)
+                        if parsed.use_label and not parsed.label:
+                            err = "%s:%d: Must set the label with --label" \
                                   % (confpath, lineno)
                             raise KickStartError(err)
                         # using ArgumentParser one cannot easily tell if option
diff --git a/poky/scripts/lib/wic/partition.py b/poky/scripts/lib/wic/partition.py
index 3fe5c4e..3da7e23 100644
--- a/poky/scripts/lib/wic/partition.py
+++ b/poky/scripts/lib/wic/partition.py
@@ -47,6 +47,7 @@
         self.fsopts = args.fsopts
         self.fstype = args.fstype
         self.label = args.label
+        self.use_label = args.use_label
         self.mkfs_extraopts = args.mkfs_extraopts
         self.mountpoint = args.mountpoint
         self.no_table = args.no_table
@@ -66,7 +67,6 @@
 
         self.lineno = lineno
         self.source_file = ""
-        self.sourceparams_dict = {}
 
     def get_extra_block_count(self, current_blocks):
         """
@@ -211,7 +211,7 @@
         """
         p_prefix = os.environ.get("PSEUDO_PREFIX", "%s/usr" % native_sysroot)
         p_localstatedir = os.environ.get("PSEUDO_LOCALSTATEDIR",
-                                         "%s/../pseudo" %  get_bitbake_var("IMAGE_ROOTFS"))
+                                         "%s/../pseudo" %  rootfs_dir)
         p_passwd = os.environ.get("PSEUDO_PASSWD", rootfs_dir)
         p_nosymlinkexp = os.environ.get("PSEUDO_NOSYMLINKEXP", "1")
         pseudo = "export PSEUDO_PREFIX=%s;" % p_prefix
diff --git a/poky/scripts/lib/wic/plugins/imager/direct.py b/poky/scripts/lib/wic/plugins/imager/direct.py
index 1fa6b91..bb14a33 100644
--- a/poky/scripts/lib/wic/plugins/imager/direct.py
+++ b/poky/scripts/lib/wic/plugins/imager/direct.py
@@ -122,6 +122,10 @@
         if self._update_fstab(fstab_lines, self.parts):
             # copy rootfs dir to workdir to update fstab
             # as rootfs can be used by other tasks and can't be modified
+            new_pseudo = os.path.realpath(os.path.join(self.workdir, "pseudo"))
+            from_dir = os.path.join(os.path.join(image_rootfs, ".."), "pseudo")
+            from_dir = os.path.realpath(from_dir)
+            copyhardlinktree(from_dir, new_pseudo)
             new_rootfs = os.path.realpath(os.path.join(self.workdir, "rootfs_copy"))
             copyhardlinktree(image_rootfs, new_rootfs)
             fstab_path = os.path.join(new_rootfs, 'etc/fstab')
@@ -151,6 +155,8 @@
                         device_name = "UUID=%s" % part.fsuuid
                 else:
                     device_name = "PARTUUID=%s" % part.uuid
+            elif part.use_label:
+                device_name = "LABEL=%s" % part.label
             else:
                 # mmc device partitions are named mmcblk0p1, mmcblk0p2..
                 prefix = 'p' if  part.disk.startswith('mmcblk') else ''
diff --git a/poky/scripts/lib/wic/plugins/source/bootimg-partition.py b/poky/scripts/lib/wic/plugins/source/bootimg-partition.py
index b239fc0..ddc880b 100644
--- a/poky/scripts/lib/wic/plugins/source/bootimg-partition.py
+++ b/poky/scripts/lib/wic/plugins/source/bootimg-partition.py
@@ -30,6 +30,7 @@
 from glob import glob
 
 from wic import WicError
+from wic.engine import get_custom_config
 from wic.pluginbase import SourcePlugin
 from wic.misc import exec_cmd, get_bitbake_var
 
@@ -44,15 +45,11 @@
     name = 'bootimg-partition'
 
     @classmethod
-    def do_prepare_partition(cls, part, source_params, cr, cr_workdir,
+    def do_configure_partition(cls, part, source_params, cr, cr_workdir,
                              oe_builddir, bootimg_dir, kernel_dir,
-                             rootfs_dir, native_sysroot):
+                             native_sysroot):
         """
-        Called to do the actual content population for a partition i.e. it
-        'prepares' the partition to be incorporated into the image.
-        In this case, does the following:
-        - sets up a vfat partition
-        - copies all files listed in IMAGE_BOOT_FILES variable
+        Called before do_prepare_partition(), create u-boot specific boot config
         """
         hdddir = "%s/boot.%d" % (cr_workdir, part.lineno)
         install_cmd = "install -d %s" % hdddir
@@ -63,8 +60,6 @@
             if not kernel_dir:
                 raise WicError("Couldn't find DEPLOY_DIR_IMAGE, exiting")
 
-        logger.debug('Kernel dir: %s', bootimg_dir)
-
         boot_files = None
         for (fmt, id) in (("_uuid-%s", part.uuid), ("_label-%s", part.label), (None, None)):
             if fmt:
@@ -94,9 +89,9 @@
             logger.debug('Destination entry: %r', dst_entry)
             deploy_files.append(dst_entry)
 
+        cls.install_task = [];
         for deploy_entry in deploy_files:
             src, dst = deploy_entry
-            install_task = []
             if '*' in src:
                 # by default install files under their basename
                 entry_name_fn = os.path.basename
@@ -111,21 +106,101 @@
 
                 logger.debug('Globbed sources: %s', ', '.join(srcs))
                 for entry in srcs:
+                    src = os.path.relpath(entry, kernel_dir)
                     entry_dst_name = entry_name_fn(entry)
-                    install_task.append((entry,
-                                         os.path.join(hdddir,
-                                                      entry_dst_name)))
+                    cls.install_task.append((src, entry_dst_name))
             else:
-                install_task = [(os.path.join(kernel_dir, src),
-                                 os.path.join(hdddir, dst))]
+                cls.install_task.append((src, dst))
 
-            for task in install_task:
-                src_path, dst_path = task
-                logger.debug('Install %s as %s',
-                             os.path.basename(src_path), dst_path)
-                install_cmd = "install -m 0644 -D %s %s" \
-                              % (src_path, dst_path)
-                exec_cmd(install_cmd)
+        if source_params.get('loader') != "u-boot":
+            return
+
+        configfile = cr.ks.bootloader.configfile
+        custom_cfg = None
+        if configfile:
+            custom_cfg = get_custom_config(configfile)
+            if custom_cfg:
+                # Use a custom configuration for extlinux.conf
+                extlinux_conf = custom_cfg
+                logger.debug("Using custom configuration file "
+                             "%s for extlinux.cfg", configfile)
+            else:
+                raise WicError("configfile is specified but failed to "
+                               "get it from %s." % configfile)
+
+        if not custom_cfg:
+            # The kernel types supported by the sysboot of u-boot
+            kernel_types = ["zImage", "Image", "fitImage", "uImage", "vmlinux"]
+            has_dtb = False
+            fdt_dir = '/'
+            kernel_name = None
+
+            # Find the kernel image name, from the highest precedence to lowest
+            for image in kernel_types:
+                for task in cls.install_task:
+                    src, dst = task
+                    if re.match(image, src):
+                        kernel_name = os.path.join('/', dst)
+                        break
+                if kernel_name:
+                    break
+
+            for task in cls.install_task:
+                src, dst = task
+                # We suppose that all the dtb are in the same directory
+                if re.search(r'\.dtb', src) and fdt_dir == '/':
+                    has_dtb = True
+                    fdt_dir = os.path.join(fdt_dir, os.path.dirname(dst))
+                    break
+
+            if not kernel_name:
+                raise WicError('No kernel file founded')
+
+            # Compose the extlinux.conf
+            extlinux_conf = "default Yocto\n"
+            extlinux_conf += "label Yocto\n"
+            extlinux_conf += "   kernel %s\n" % kernel_name
+            if has_dtb:
+                extlinux_conf += "   fdtdir %s\n" % fdt_dir
+            bootloader = cr.ks.bootloader
+            extlinux_conf += "append root=%s rootwait %s\n" \
+                             % (cr.rootdev, bootloader.append if bootloader.append else '')
+
+        install_cmd = "install -d %s/extlinux/" % hdddir
+        exec_cmd(install_cmd)
+        cfg = open("%s/extlinux/extlinux.conf" % hdddir, "w")
+        cfg.write(extlinux_conf)
+        cfg.close()
+
+
+    @classmethod
+    def do_prepare_partition(cls, part, source_params, cr, cr_workdir,
+                             oe_builddir, bootimg_dir, kernel_dir,
+                             rootfs_dir, native_sysroot):
+        """
+        Called to do the actual content population for a partition i.e. it
+        'prepares' the partition to be incorporated into the image.
+        In this case, does the following:
+        - sets up a vfat partition
+        - copies all files listed in IMAGE_BOOT_FILES variable
+        """
+        hdddir = "%s/boot.%d" % (cr_workdir, part.lineno)
+
+        if not kernel_dir:
+            kernel_dir = get_bitbake_var("DEPLOY_DIR_IMAGE")
+            if not kernel_dir:
+                raise WicError("Couldn't find DEPLOY_DIR_IMAGE, exiting")
+
+        logger.debug('Kernel dir: %s', bootimg_dir)
+
+
+        for task in cls.install_task:
+            src_path, dst_path = task
+            logger.debug('Install %s as %s', src_path, dst_path)
+            install_cmd = "install -m 0644 -D %s %s" \
+                          % (os.path.join(kernel_dir, src_path),
+                             os.path.join(hdddir, dst_path))
+            exec_cmd(install_cmd)
 
         logger.debug('Prepare boot partition using rootfs in %s', hdddir)
         part.prepare_rootfs(cr_workdir, oe_builddir, hdddir,
diff --git a/poky/scripts/lib/wic/plugins/source/bootimg-pcbios.py b/poky/scripts/lib/wic/plugins/source/bootimg-pcbios.py
index d599112..9347aa7 100644
--- a/poky/scripts/lib/wic/plugins/source/bootimg-pcbios.py
+++ b/poky/scripts/lib/wic/plugins/source/bootimg-pcbios.py
@@ -26,6 +26,7 @@
 
 import logging
 import os
+import re
 
 from wic import WicError
 from wic.engine import get_custom_config
@@ -47,10 +48,17 @@
         """
         Check if dirname exists in default bootimg_dir or in STAGING_DIR.
         """
-        for result in (bootimg_dir, get_bitbake_var("STAGING_DATADIR")):
+        staging_datadir = get_bitbake_var("STAGING_DATADIR")
+        for result in (bootimg_dir, staging_datadir):
             if os.path.exists("%s/%s" % (result, dirname)):
                 return result
 
+        # STAGING_DATADIR is expanded with MLPREFIX if multilib is enabled
+        # but dependency syslinux is still populated to original STAGING_DATADIR
+        nonarch_datadir = re.sub('/[^/]*recipe-sysroot', '/recipe-sysroot', staging_datadir)
+        if os.path.exists(os.path.join(nonarch_datadir, dirname)):
+            return nonarch_datadir
+
         raise WicError("Couldn't find correct bootimg_dir, exiting")
 
     @classmethod
diff --git a/poky/scripts/lib/wic/plugins/source/isoimage-isohybrid.py b/poky/scripts/lib/wic/plugins/source/isoimage-isohybrid.py
index b119c9c..170077c 100644
--- a/poky/scripts/lib/wic/plugins/source/isoimage-isohybrid.py
+++ b/poky/scripts/lib/wic/plugins/source/isoimage-isohybrid.py
@@ -47,7 +47,7 @@
 
     Example kickstart file:
     part /boot --source isoimage-isohybrid --sourceparams="loader=grub-efi, \\
-    image_name= IsoImage" --ondisk cd --label LIVECD --fstype=ext2
+    image_name= IsoImage" --ondisk cd --label LIVECD
     bootloader  --timeout=10  --append=" "
 
     In --sourceparams "loader" specifies the bootloader used for booting in EFI
@@ -191,10 +191,9 @@
             else:
                 raise WicError("Couldn't find or build initrd, exiting.")
 
-            exec_cmd("cd %s && find . | cpio -o -H newc -R +0:+0 >./initrd.cpio " \
-                    % initrd_dir, as_shell=True)
-            exec_cmd("gzip -f -9 -c %s/initrd.cpio > %s" \
-                    % (cr_workdir, initrd), as_shell=True)
+            exec_cmd("cd %s && find . | cpio -o -H newc -R root:root >%s/initrd.cpio " \
+                     % (initrd_dir, cr_workdir), as_shell=True)
+            exec_cmd("gzip -f -9 %s/initrd.cpio" % cr_workdir, as_shell=True)
             shutil.rmtree(initrd_dir)
 
         return initrd
@@ -253,33 +252,8 @@
             raise WicError("Couldn't find IMAGE_ROOTFS, exiting.")
 
         part.rootfs_dir = rootfs_dir
-
-        # Prepare rootfs.img
         deploy_dir = get_bitbake_var("DEPLOY_DIR_IMAGE")
         img_iso_dir = get_bitbake_var("ISODIR")
-        rootfs_img = "%s/rootfs.img" % img_iso_dir
-        if not os.path.isfile(rootfs_img):
-            # check if rootfs.img is in deploydir
-            deploy_dir = get_bitbake_var("DEPLOY_DIR_IMAGE")
-            image_name = get_bitbake_var("IMAGE_LINK_NAME")
-            rootfs_img = "%s/%s.%s" \
-                % (deploy_dir, image_name, part.fstype)
-
-        if not os.path.isfile(rootfs_img):
-            # create image file with type specified by --fstype
-            # which contains rootfs
-            du_cmd = "du -bks %s" % rootfs_dir
-            out = exec_cmd(du_cmd)
-            part.size = int(out.split()[0])
-            part.extra_space = 0
-            part.overhead_factor = 1.2
-            part.prepare_rootfs(cr_workdir, oe_builddir, rootfs_dir, \
-                                native_sysroot)
-            rootfs_img = part.source_file
-
-        install_cmd = "install -m 0644 %s %s/rootfs.img" \
-            % (rootfs_img, isodir)
-        exec_cmd(install_cmd)
 
         # Remove the temporary file created by part.prepare_rootfs()
         if os.path.isfile(part.source_file):
@@ -342,7 +316,7 @@
                     grub_src = os.path.join(deploy_dir, grub_src_image)
                     if not os.path.exists(grub_src):
                         raise WicError("Grub loader %s is not found in %s. "
-                                       "Please build grub-efi first" % (grub_image, deploy_dir))
+                                       "Please build grub-efi first" % (grub_src_image, deploy_dir))
                     shutil.copy(grub_src, grub_target)
 
                 if not os.path.isfile(os.path.join(target_dir, "boot.cfg")):
diff --git a/poky/scripts/oe-build-perf-report b/poky/scripts/oe-build-perf-report
index dc999c4..0bd05f4 100755
--- a/poky/scripts/oe-build-perf-report
+++ b/poky/scripts/oe-build-perf-report
@@ -416,9 +416,11 @@
                 samples[-1]['commit_num'] = commit_num
 
             absdiff = samples[-1]['val_cls'](samples[-1]['mean'] - samples[id_comp]['mean'])
+            reldiff = absdiff * 100 / samples[id_comp]['mean']
             new_meas['absdiff'] = absdiff
             new_meas['absdiff_str'] = str(absdiff) if absdiff < 0 else '+' + str(absdiff)
-            new_meas['reldiff'] = "{:+.1f} %".format(absdiff * 100 / samples[id_comp]['mean'])
+            new_meas['reldiff'] = reldiff
+            new_meas['reldiff_str'] = "{:+.1f} %".format(reldiff)
             new_meas['samples'] = samples
             new_meas['value'] = samples[-1]
             new_meas['value_type'] = samples[-1]['val_cls']
diff --git a/poky/scripts/oe-buildenv-internal b/poky/scripts/oe-buildenv-internal
index 6773872..52ce329 100755
--- a/poky/scripts/oe-buildenv-internal
+++ b/poky/scripts/oe-buildenv-internal
@@ -40,16 +40,7 @@
     return 1
 fi
 
-# Make sure we're not using python v3.x as 'python', we don't support it.
-py_v2_check=$(/usr/bin/env python --version 2>&1 | grep "Python 3")
-if [ -n "$py_v2_check" ]; then
-    echo >&2 "OpenEmbedded requires 'python' to be python v2 (>= 2.7.3), not python v3."
-    echo >&2 "Please set up python v2 as your default 'python' interpreter."
-    return 1
-fi
-unset py_v2_check
-
-py_v27_check=$(python -c 'import sys; print sys.version_info >= (2,7,3)')
+py_v27_check=$(python2 -c 'import sys; print sys.version_info >= (2,7,3)')
 if [ "$py_v27_check" != "True" ]; then
     echo >&2 "OpenEmbedded requires 'python' to be python v2 (>= 2.7.3), not python v3."
     echo >&2 "Please upgrade your python v2."
diff --git a/poky/scripts/oe-depends-dot b/poky/scripts/oe-depends-dot
index 5cec23b..6c7e9d3 100755
--- a/poky/scripts/oe-depends-dot
+++ b/poky/scripts/oe-depends-dot
@@ -47,6 +47,51 @@
         if len(sys.argv) != 3 and len(sys.argv) < 5:
             print('ERROR: Not enough args, see --help for usage')
 
+    @staticmethod
+    def insert_dep_chain(chain, rdeps, alldeps):
+        """
+        insert elements to chain from rdeps, according to alldeps
+        """
+        # chain should at least contain one element
+        if len(chain) == 0:
+            raise
+
+        inserted_elements = []
+        for rdep in rdeps:
+            if rdep in chain:
+                continue
+            else:
+                for i in range(0, len(chain)-1):
+                    if chain[i] in alldeps[rdep] and rdep in alldeps[chain[i+1]]:
+                        chain.insert(i+1, rdep)
+                        inserted_elements.append(rdep)
+                        break
+                if chain[-1] in alldeps[rdep] and rdep not in chain:
+                    chain.append(rdep)
+                    inserted_elements.append(rdep)
+        return inserted_elements
+
+    @staticmethod
+    def print_dep_chains(key, rdeps, alldeps):
+        rlist = rdeps.copy()
+        chain = []
+        removed_rdeps = [] # hold rdeps removed from rlist
+
+        chain.append(key)
+        while (len(rlist) != 0):
+            # insert chain from rlist
+            inserted_elements = Dot.insert_dep_chain(chain, rlist, alldeps)
+            if not inserted_elements:
+                if chain[-1] in rlist:
+                    rlist.remove(chain[-1])
+                    removed_rdeps.append(chain[-1])
+                chain.pop()
+                continue
+            else:
+                # insert chain from removed_rdeps
+                Dot.insert_dep_chain(chain, removed_rdeps, alldeps)
+                print(' -> '.join(list(reversed(chain))))
+
     def main(self):
         #print(self.args.dotfile[0])
         # The format is {key: depends}
@@ -109,6 +154,7 @@
                 if self.args.key in v and not k in reverse_deps:
                     reverse_deps.append(k)
             print('Because: %s' % ' '.join(reverse_deps))
+            Dot.print_dep_chains(self.args.key, reverse_deps, depends)
 
 if __name__ == "__main__":
     try:
diff --git a/poky/scripts/oe-find-native-sysroot b/poky/scripts/oe-find-native-sysroot
index 350ea21..cc146b3 100755
--- a/poky/scripts/oe-find-native-sysroot
+++ b/poky/scripts/oe-find-native-sysroot
@@ -110,6 +110,4 @@
 if [ -e "$pseudo" ]; then
     echo "PSEUDO=$pseudo"
     PSEUDO="$pseudo"
-else
-    echo "PSEUDO $pseudo is not found."
 fi
diff --git a/poky/scripts/oe-pkgdata-util b/poky/scripts/oe-pkgdata-util
index e6c9df9..53739b0 100755
--- a/poky/scripts/oe-pkgdata-util
+++ b/poky/scripts/oe-pkgdata-util
@@ -279,10 +279,14 @@
                 parse_pkgdatafile(pkgdatafile)
             continue
         pkgdatafile = os.path.join(args.pkgdata_dir, 'runtime-reverse', pkg)
-        if not os.path.exists(pkgdatafile):
-            logger.error("The following packages could not be found: %s" % pkg)
-            sys.exit(1)
-        parse_pkgdatafile(pkgdatafile)
+        if os.path.exists(pkgdatafile):
+            parse_pkgdatafile(pkgdatafile)
+        else:
+            if args.carryon:
+                print("The following packages could not be found: %s" % pkg)
+            else:
+                logger.error("The following packages could not be found: %s" % pkg)
+                sys.exit(1)
 
 def package_info(args):
     def parse_pkgdatafile(pkgdatafile):
@@ -558,6 +562,7 @@
                                           help='Find recipe producing one or more packages',
                                           description='Looks up the specified runtime package(s) to see which recipe they were produced by')
     parser_lookup_recipe.add_argument('pkg', nargs='+', help='Runtime package name to look up')
+    parser_lookup_recipe.add_argument('-c', '--continue', dest="carryon", help='Continue looking up recipes even if we can not find one', action='store_true')
     parser_lookup_recipe.set_defaults(func=lookup_recipe)
 
     parser_package_info = subparsers.add_parser('package-info',
diff --git a/poky/scripts/oe-run-native b/poky/scripts/oe-run-native
index 1131122..a29e994 100755
--- a/poky/scripts/oe-run-native
+++ b/poky/scripts/oe-run-native
@@ -55,12 +55,12 @@
 OLD_PATH=$PATH
 
 # look for a tool only in native sysroot
-PATH=$OECORE_NATIVE_SYSROOT/usr/bin:$OECORE_NATIVE_SYSROOT/bin:$OECORE_NATIVE_SYSROOT/usr/sbin:$OECORE_NATIVE_SYSROOT/sbin
+PATH=$OECORE_NATIVE_SYSROOT/usr/bin:$OECORE_NATIVE_SYSROOT/bin:$OECORE_NATIVE_SYSROOT/usr/sbin:$OECORE_NATIVE_SYSROOT/sbin$(find $OECORE_NATIVE_SYSROOT/usr/bin/*-native -maxdepth 1 -type d -printf ":%p")
 tool_find=`/usr/bin/which $tool 2>/dev/null`
 
 if [ -n "$tool_find" ] ; then
     # add old path to allow usage of host tools
-    PATH=$PATH:$OLD_PATH $@
+    PATH=$PATH:$OLD_PATH "$@"
 else
     echo "Error: Unable to find '$tool' in $PATH"
     echo "Error: Have you run 'bitbake $native_recipe -caddto_recipe_sysroot'?"
diff --git a/poky/scripts/postinst-intercepts/update_font_cache b/poky/scripts/postinst-intercepts/update_font_cache
index bf65e19..e0ec471 100644
--- a/poky/scripts/postinst-intercepts/update_font_cache
+++ b/poky/scripts/postinst-intercepts/update_font_cache
@@ -2,6 +2,5 @@
 
 set -e
 
-PSEUDO_UNLOAD=1 qemuwrapper -L $D -E LD_LIBRARY_PATH=$D/${libdir}:$D/${base_libdir} \
-					-E ${fontconfigcacheenv} $D${bindir}/fc-cache --sysroot=$D --system-only ${fontconfigcacheparams}
+PSEUDO_UNLOAD=1 ${binprefix}qemuwrapper -L $D -E ${fontconfigcacheenv} $D${libexecdir}/${binprefix}fc-cache --sysroot=$D --system-only ${fontconfigcacheparams}
 chown -R root:root $D${fontconfigcachedir}
diff --git a/poky/scripts/postinst-intercepts/update_gio_module_cache b/poky/scripts/postinst-intercepts/update_gio_module_cache
index fc3f9d0..d1f0140 100644
--- a/poky/scripts/postinst-intercepts/update_gio_module_cache
+++ b/poky/scripts/postinst-intercepts/update_gio_module_cache
@@ -2,8 +2,7 @@
 
 set -e
 
-PSEUDO_UNLOAD=1 qemuwrapper -L $D -E LD_LIBRARY_PATH=$D${libdir}:$D${base_libdir} \
-	$D${libexecdir}/${binprefix}gio-querymodules $D${libdir}/gio/modules/
+PSEUDO_UNLOAD=1 ${binprefix}qemuwrapper -L $D $D${libexecdir}/${binprefix}gio-querymodules $D${libdir}/gio/modules/
 
 [ ! -e $D${libdir}/gio/modules/giomodule.cache ] ||
 	chown root:root $D${libdir}/gio/modules/giomodule.cache
diff --git a/poky/scripts/postinst-intercepts/update_gtk_immodules_cache b/poky/scripts/postinst-intercepts/update_gtk_immodules_cache
new file mode 100644
index 0000000..3955169
--- /dev/null
+++ b/poky/scripts/postinst-intercepts/update_gtk_immodules_cache
@@ -0,0 +1,16 @@
+#!/bin/sh
+
+set -e
+
+if [ -x $D${libexecdir}/${binprefix}gtk-query-immodules-2.0 ]; then
+    PSEUDO_UNLOAD=1 ${binprefix}qemuwrapper -L $D $D${libexecdir}/${binprefix}gtk-query-immodules-2.0 \
+        > $D${libdir}/gtk-2.0/2.10.0/immodules.cache &&
+        sed -i -e "s:$D::" $D${libdir}/gtk-2.0/2.10.0/immodules.cache
+        chown root:root $D${libdir}/gtk-2.0/2.10.0/immodules.cache
+fi
+if [ -x $D${libexecdir}/${binprefix}gtk-query-immodules-3.0 ]; then
+    PSEUDO_UNLOAD=1 ${binprefix}qemuwrapper -L $D $D${libexecdir}/${binprefix}gtk-query-immodules-3.0 \
+        > $D${libdir}/gtk-3.0/3.0.0/immodules.cache &&
+        sed -i -e "s:$D::" $D${libdir}/gtk-3.0/3.0.0/immodules.cache
+        chown root:root $D${libdir}/gtk-3.0/3.0.0/immodules.cache
+fi
diff --git a/poky/scripts/postinst-intercepts/update_pixbuf_cache b/poky/scripts/postinst-intercepts/update_pixbuf_cache
index 5d44075..ebea07c 100644
--- a/poky/scripts/postinst-intercepts/update_pixbuf_cache
+++ b/poky/scripts/postinst-intercepts/update_pixbuf_cache
@@ -5,7 +5,6 @@
 export GDK_PIXBUF_MODULEDIR=$D${libdir}/gdk-pixbuf-2.0/2.10.0/loaders
 export GDK_PIXBUF_FATAL_LOADER=1
 
-PSEUDO_UNLOAD=1 qemuwrapper -L $D -E LD_LIBRARY_PATH=$D/${libdir}:$D/${base_libdir}\
-    $D${libdir}/gdk-pixbuf-2.0/gdk-pixbuf-query-loaders \
+PSEUDO_UNLOAD=1 ${binprefix}qemuwrapper -L $D $D${libdir}/gdk-pixbuf-2.0/gdk-pixbuf-query-loaders \
     >$GDK_PIXBUF_MODULEDIR/../loaders.cache && \
     sed -i -e "s:$D::g" $GDK_PIXBUF_MODULEDIR/../loaders.cache
diff --git a/poky/scripts/postinst-intercepts/update_udev_hwdb b/poky/scripts/postinst-intercepts/update_udev_hwdb
new file mode 100644
index 0000000..b5cce0a
--- /dev/null
+++ b/poky/scripts/postinst-intercepts/update_udev_hwdb
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+set -e
+
+PSEUDO_UNLOAD=1 ${binprefix}qemuwrapper -L $D $D${libexecdir}/${binprefix}udevadm hwdb --update --root $D
+chown root:root $D${sysconfdir}/udev/hwdb.bin
diff --git a/poky/scripts/runqemu b/poky/scripts/runqemu
index c6b7580..295c8b1 100755
--- a/poky/scripts/runqemu
+++ b/poky/scripts/runqemu
@@ -290,7 +290,7 @@
     def check_arg_fstype(self, fst):
         """Check and set FSTYPE"""
         if fst not in self.fstypes + self.vmtypes:
-            logger.warn("Maybe unsupported FSTYPE: %s" % fst)
+            logger.warning("Maybe unsupported FSTYPE: %s" % fst)
         if not self.fstype or self.fstype == fst:
             if fst == 'ramfs':
                 fst = 'cpio.gz'
@@ -352,7 +352,7 @@
                     self.qemuboot = qb
                     self.qbconfload = True
                 else:
-                    logger.warn("%s doesn't exist" % qb)
+                    logger.warning("%s doesn't exist" % qb)
             else:
                 raise RunQemuError("Can't find FSTYPE from: %s" % p)
 
@@ -672,7 +672,10 @@
             logger.info('QB_MEM is not set, use 512M by default')
             self.set('QB_MEM', '-m 512')
 
-        self.kernel_cmdline_script += ' mem=%s' % self.get('QB_MEM').replace('-m','').strip() + 'M'
+        mach = self.get('MACHINE')
+        if not mach.startswith('qemumips'):
+            self.kernel_cmdline_script += ' mem=%s' % self.get('QB_MEM').replace('-m','').strip() + 'M'
+
         self.qemu_opt_script += ' %s' % self.get('QB_MEM')
 
     def check_tcpserial(self):
@@ -692,7 +695,7 @@
             if not self.get('QB_AUDIO_DRV'):
                 raise RunQemuError("QB_AUDIO_DRV is NULL, this board doesn't support audio")
             if not self.get('QB_AUDIO_OPT'):
-                logger.warn('QB_AUDIO_OPT is NULL, you may need define it to make audio work')
+                logger.warning('QB_AUDIO_OPT is NULL, you may need define it to make audio work')
             else:
                 self.qemu_opt_script += ' %s' % self.get('QB_AUDIO_OPT')
             os.putenv('QEMU_AUDIO_DRV', self.get('QB_AUDIO_DRV'))
@@ -714,7 +717,7 @@
             if self.get('DEPLOY_DIR_IMAGE'):
                 deploy_dir_image = self.get('DEPLOY_DIR_IMAGE')
             else:
-                logger.warn("Can't find qemuboot conf file, DEPLOY_DIR_IMAGE is NULL!")
+                logger.warning("Can't find qemuboot conf file, DEPLOY_DIR_IMAGE is NULL!")
                 return
 
             if self.rootfs and not os.path.exists(self.rootfs):
@@ -1061,9 +1064,9 @@
                         # virtio might have been selected explicitly (just use it), or
                         # is used as fallback (then warn about that).
                         if not drive_type.startswith("/dev/vd"):
-                            logger.warn("Unknown QB_DRIVE_TYPE: %s" % drive_type)
-                            logger.warn("Failed to figure out drive type, consider define or fix QB_DRIVE_TYPE")
-                            logger.warn('Trying to use virtio block drive')
+                            logger.warning("Unknown QB_DRIVE_TYPE: %s" % drive_type)
+                            logger.warning("Failed to figure out drive type, consider define or fix QB_DRIVE_TYPE")
+                            logger.warning('Trying to use virtio block drive')
                         vm_drive = '-drive if=virtio,file=%s,format=%s' % (self.rootfs, rootfs_format)
 
                 # All branches above set vm_drive.
@@ -1279,7 +1282,7 @@
             self.bitbake_e = subprocess.check_output(cmd, shell=True).decode('utf-8')
         except subprocess.CalledProcessError as err:
             self.bitbake_e = ''
-            logger.warn("Couldn't run 'bitbake -e' to gather environment information:\n%s" % err.output.decode('utf-8'))
+            logger.warning("Couldn't run 'bitbake -e' to gather environment information:\n%s" % err.output.decode('utf-8'))
 
     def validate_combos(self):
         if (self.fstype in self.vmtypes) and self.kernel:
diff --git a/poky/scripts/runqemu-extract-sdk b/poky/scripts/runqemu-extract-sdk
index f4286ef..4da3eb1 100755
--- a/poky/scripts/runqemu-extract-sdk
+++ b/poky/scripts/runqemu-extract-sdk
@@ -31,9 +31,9 @@
 
 SYSROOT_SETUP_SCRIPT=`which oe-find-native-sysroot 2> /dev/null`
 if [ -z "$SYSROOT_SETUP_SCRIPT" ]; then
-    echo "Error: Unable to find the oe-find-native-sysroot script"
-    echo "Did you forget to source your build system environment setup script?"
-    exit 1
+	echo "Error: Unable to find the oe-find-native-sysroot script"
+	echo "Did you forget to source your build system environment setup script?"
+	exit 1
 fi
 . $SYSROOT_SETUP_SCRIPT meta-ide-support
 PSEUDO_OPTS="-P $OECORE_NATIVE_SYSROOT/usr"
@@ -42,9 +42,9 @@
 SDK_ROOTFS_DIR=$2
 
 if [ ! -e "$ROOTFS_TARBALL" ]; then
-   	echo "Error: sdk tarball '$ROOTFS_TARBALL' does not exist"
-   	usage
-   	exit 1
+	echo "Error: sdk tarball '$ROOTFS_TARBALL' does not exist"
+	usage
+	exit 1
 fi
 
 # Convert SDK_ROOTFS_DIR to a full pathname
@@ -53,6 +53,9 @@
 fi
 
 TAR_OPTS=""
+if [[ "$ROOTFS_TARBALL" =~ tar\.xz$ ]]; then
+	TAR_OPTS="--numeric-owner -xJf"
+fi
 if [[ "$ROOTFS_TARBALL" =~ tar\.bz2$ ]]; then
 	TAR_OPTS="--numeric-owner -xjf"
 fi
@@ -64,7 +67,7 @@
 fi
 if [ -z "$TAR_OPTS" ]; then
 	echo "Error: Unable to determine sdk tarball format"
-	echo "Accepted types: .tar / .tar.gz / .tar.bz2"
+	echo "Accepted types: .tar / .tar.gz / .tar.bz2 / .tar.xz"
 	exit 1
 fi
 
@@ -81,7 +84,7 @@
 if [ -e "$pseudo_state_dir" -a -z "$debug_image" ]; then
 	echo "Error: $pseudo_state_dir already exists!"
 	echo "Please delete the rootfs tree and pseudo directory manually"
-        echo "if this is really what you want."
+	echo "if this is really what you want."
 	exit 1
 fi
 
diff --git a/poky/scripts/runqemu-ifdown b/poky/scripts/runqemu-ifdown
index ffbc9de..2486968 100755
--- a/poky/scripts/runqemu-ifdown
+++ b/poky/scripts/runqemu-ifdown
@@ -51,6 +51,16 @@
 
 $TUNCTL -d $TAP
 
+IFCONFIG=`which ip 2> /dev/null`
+if [ "x$IFCONFIG" = "x" ]; then
+	# better than nothing...
+	IFCONFIG=/sbin/ip
+fi
+if [ -x "$IFCONFIG" ]; then
+	if `$IFCONFIG link show $TAP > /dev/null 2>&1`; then
+		$IFCONFIG link del $TAP
+	fi
+fi
 # cleanup the remaining iptables rules
 IPTABLES=`which iptables 2> /dev/null`
 if [ "x$IPTABLES" = "x" ]; then
diff --git a/poky/scripts/send-error-report b/poky/scripts/send-error-report
index cd2e7f4..8939f5f 100755
--- a/poky/scripts/send-error-report
+++ b/poky/scripts/send-error-report
@@ -88,7 +88,7 @@
         log.error("Name needs to be provided either via "+userfile+" or as an argument (-n).")
         sys.exit(1)
 
-    while len(args.name) <= 0 and len(args.name) < 50:
+    while len(args.name) <= 0 or len(args.name) > 50:
         print("\nName needs to be given and must not more than 50 characters.")
         args.name, args.email = ask_for_contactdetails()
 
@@ -140,7 +140,7 @@
     try:
         response = urllib.request.urlopen(req)
     except urllib.error.HTTPError as e:
-        logging.error(e.reason)
+        logging.error(str(e))
         sys.exit(1)
 
     print(response.read().decode('utf-8'))
diff --git a/poky/scripts/wic b/poky/scripts/wic
index 7392bc4..37dfe2d 100755
--- a/poky/scripts/wic
+++ b/poky/scripts/wic
@@ -362,6 +362,8 @@
                            "bitbake variables")
     subparser.add_argument("-D", "--debug", dest="debug", action="store_true",
                       default=False, help="output debug information")
+    subparser.add_argument("-i", "--imager", dest="imager",
+                      default="direct", help="the wic imager plugin")
     return
 
 
diff --git a/poky/scripts/yocto-check-layer b/poky/scripts/yocto-check-layer
index 5a4fd75..9b7e536 100755
--- a/poky/scripts/yocto-check-layer
+++ b/poky/scripts/yocto-check-layer
@@ -169,7 +169,14 @@
         td['bbvars'] = get_bb_vars()
         logger.info('Getting initial signatures ...')
         td['builddir'] = builddir
-        td['sigs'], td['tunetasks'] = get_signatures(td['builddir'])
+        try:
+            td['sigs'], td['tunetasks'] = get_signatures(td['builddir'])
+        except RuntimeError as e:
+            logger.info(str(e))
+            results[layer['name']] = None
+            results_status[layer['name']] = 'FAIL (Generating world signatures)'
+            layers_tested = layers_tested + 1
+            continue
         td['machines'] = args.machines
 
         if not add_layer(bblayersconf, layer, dep_layers, logger):